Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
fangxinjiang
yifu-mvp
Commits
0bd6e881
You need to sign in or sign up before continuing.
Commit
0bd6e881
authored
May 28, 2023
by
zhenbin wang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feature-wzb:最低工资bug修复
parent
a106eb90
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
205 additions
and
212 deletions
+205
-212
TMinSalaryServiceImpl.java
...us/v1/yifu/salary/service/impl/TMinSalaryServiceImpl.java
+205
-212
No files found.
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/service/impl/TMinSalaryServiceImpl.java
View file @
0bd6e881
...
@@ -171,7 +171,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -171,7 +171,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
if
(
Common
.
isEmpty
(
data
.
getLocation
())
&&
Common
.
isEmpty
(
data
.
getSalaryBase
())
&&
Common
.
isEmpty
(
data
.
getStatus
()))
{
if
(
Common
.
isEmpty
(
data
.
getLocation
())
&&
Common
.
isEmpty
(
data
.
getSalaryBase
())
&&
Common
.
isEmpty
(
data
.
getStatus
()))
{
data
.
setErrorFlag
(
true
);
data
.
setErrorFlag
(
true
);
errorMessage
.
append
(
"所在地、最低工资(元)、状态为空;"
);
errorMessage
.
append
(
"所在地、最低工资(元)、状态为空;"
);
}
if
(
null
!=
data
.
getLocation
())
{
if
(
null
!=
data
.
getLocation
())
{
if
(
data
.
getLocation
().
contains
(
"/"
))
{
if
(
data
.
getLocation
().
contains
(
"/"
))
{
...
@@ -209,7 +209,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -209,7 +209,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
if
(
Common
.
isNotNull
(
redisCityName
))
{
if
(
Common
.
isNotNull
(
redisCityName
))
{
query
.
eq
(
TMinSalary:
:
getCity
,
redisCityName
);
query
.
eq
(
TMinSalary:
:
getCity
,
redisCityName
);
}
}
query
.
ne
(
TMinSalary:
:
getId
,
data
.
getId
());
long
res
=
baseMapper
.
selectCount
(
query
);
long
res
=
baseMapper
.
selectCount
(
query
);
if
(
res
>
CommonConstants
.
ZERO_INT
)
{
if
(
res
>
CommonConstants
.
ZERO_INT
)
{
...
@@ -310,7 +310,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -310,7 +310,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
if
(
Common
.
isNotNull
(
redisCityName
))
{
if
(
Common
.
isNotNull
(
redisCityName
))
{
query
.
eq
(
TMinSalary:
:
getCity
,
redisCityName
);
query
.
eq
(
TMinSalary:
:
getCity
,
redisCityName
);
}
}
query
.
ne
(
TMinSalary:
:
getId
,
data
.
getId
());
long
res
=
baseMapper
.
selectCount
(
query
);
long
res
=
baseMapper
.
selectCount
(
query
);
if
(
res
>
CommonConstants
.
ZERO_INT
)
{
if
(
res
>
CommonConstants
.
ZERO_INT
)
{
...
@@ -367,7 +367,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -367,7 +367,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
errorMessage
.
append
(
"最低工资,请填写>0的两位小数;"
);
errorMessage
.
append
(
"最低工资,请填写>0的两位小数;"
);
}
}
}
}
if
(
null
!=
data
.
getStatus
())
{
if
(
null
!=
data
.
getStatus
())
{
if
(!(
CommonConstants
.
START
.
equals
(
data
.
getStatus
())
||
CommonConstants
.
STOP
.
equals
(
data
.
getStatus
())))
{
if
(!(
CommonConstants
.
START
.
equals
(
data
.
getStatus
())
||
CommonConstants
.
STOP
.
equals
(
data
.
getStatus
())))
{
data
.
setErrorFlag
(
true
);
data
.
setErrorFlag
(
true
);
errorMessage
.
append
(
"填写的状态不是启用或停用"
);
errorMessage
.
append
(
"填写的状态不是启用或停用"
);
...
@@ -376,7 +376,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -376,7 +376,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
}
}
}
}
}
}
}
if
(
data
.
isErrorFlag
())
{
if
(
data
.
isErrorFlag
())
{
data
.
setErrorMessage
(
errorMessage
.
toString
());
data
.
setErrorMessage
(
errorMessage
.
toString
());
}
}
...
@@ -398,6 +398,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -398,6 +398,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
salaryImportsSuccessList
.
stream
().
forEach
(
e
->
{
salaryImportsSuccessList
.
stream
().
forEach
(
e
->
{
TMinSalary
selectOne
=
new
TMinSalary
();
TMinSalary
selectOne
=
new
TMinSalary
();
selectOne
.
setId
(
e
.
getId
());
selectOne
.
setId
(
e
.
getId
());
if
(
null
!=
e
.
getLocation
())
{
if
(
e
.
getLocation
().
contains
(
"/"
))
{
if
(
e
.
getLocation
().
contains
(
"/"
))
{
String
location
[]
=
e
.
getLocation
().
split
(
"/"
);
String
location
[]
=
e
.
getLocation
().
split
(
"/"
);
if
(
location
.
length
>
1
)
{
if
(
location
.
length
>
1
)
{
...
@@ -413,19 +414,9 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -413,19 +414,9 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
if
(
i
==
CommonConstants
.
TWO_INT
)
{
if
(
i
==
CommonConstants
.
TWO_INT
)
{
int
town
=
baseMapper
.
selectByAreaName
(
location
[
i
]);
int
town
=
baseMapper
.
selectByAreaName
(
location
[
i
]);
selectOne
.
setTown
(
town
);
selectOne
.
setTown
(
town
);
;
}
}
}
}
if
(
CommonConstants
.
START
.
equals
(
e
.
getStatus
()))
{
selectOne
.
setStatus
(
CommonConstants
.
ONE_INT
);
}
}
if
(
CommonConstants
.
STOP
.
equals
(
e
.
getStatus
()))
{
selectOne
.
setStatus
(
CommonConstants
.
TWO_INT
);
}
}
selectOne
.
setSalaryBase
(
e
.
getSalaryBase
());
selectOne
.
setUpdateTime
(
LocalDateTime
.
now
());
baseMapper
.
updateById
(
selectOne
);
}
}
if
(
e
.
getLocation
().
contains
(
"-"
))
{
if
(
e
.
getLocation
().
contains
(
"-"
))
{
String
location
[]
=
e
.
getLocation
().
split
(
"-"
);
String
location
[]
=
e
.
getLocation
().
split
(
"-"
);
...
@@ -442,7 +433,9 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -442,7 +433,9 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
if
(
i
==
CommonConstants
.
TWO_INT
)
{
if
(
i
==
CommonConstants
.
TWO_INT
)
{
int
town
=
baseMapper
.
selectByAreaName
(
location
[
i
]);
int
town
=
baseMapper
.
selectByAreaName
(
location
[
i
]);
selectOne
.
setTown
(
town
);
selectOne
.
setTown
(
town
);
;
}
}
}
}
}
}
}
}
...
@@ -456,7 +449,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
...
@@ -456,7 +449,7 @@ public class TMinSalaryServiceImpl extends ServiceImpl<TMinSalaryMapper, TMinSal
selectOne
.
setUpdateTime
(
LocalDateTime
.
now
());
selectOne
.
setUpdateTime
(
LocalDateTime
.
now
());
baseMapper
.
updateById
(
selectOne
);
baseMapper
.
updateById
(
selectOne
);
}
}
}
);
);
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment