Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
attendance-performance-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
attendance-performance-platform
Commits
72bd19ac
Commit
72bd19ac
authored
Mar 12, 2024
by
廖旭伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
绩效分数汇总问题修改
parent
ee6f93c4
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
51 additions
and
11 deletions
+51
-11
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckAttendRecordServiceImpl.java
...dule/check/service/impl/CheckAttendRecordServiceImpl.java
+23
-2
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckComplainRecordServiceImpl.java
...le/check/service/impl/CheckComplainRecordServiceImpl.java
+2
-1
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckEffectRecordServiceImpl.java
...dule/check/service/impl/CheckEffectRecordServiceImpl.java
+5
-1
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckGoworkRecordServiceImpl.java
...dule/check/service/impl/CheckGoworkRecordServiceImpl.java
+5
-1
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckOtherRecordServiceImpl.java
...odule/check/service/impl/CheckOtherRecordServiceImpl.java
+2
-1
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckReviewRecordServiceImpl.java
...dule/check/service/impl/CheckReviewRecordServiceImpl.java
+5
-1
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckWindowWorkmanPerformServiceImpl.java
...ck/service/impl/CheckWindowWorkmanPerformServiceImpl.java
+7
-2
attendance-performance-manager/src/main/resources/sqlmap/module/check/CheckWindowWorkmanPerformMapperExt.xml
...qlmap/module/check/CheckWindowWorkmanPerformMapperExt.xml
+2
-2
No files found.
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckAttendRecordServiceImpl.java
View file @
72bd19ac
...
...
@@ -261,7 +261,8 @@ public class CheckAttendRecordServiceImpl extends AbstractCRUDServiceImpl<CheckA
BigDecimal
erro
=
new
BigDecimal
(
0
);
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getOtherScore
());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
erro
=
erro
.
add
(
Score100
.
subtract
(
staffPerformSummaryEntity
.
getOtherScore
()));
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getEffectScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getComplainScore
());
...
...
@@ -436,13 +437,16 @@ public class CheckAttendRecordServiceImpl extends AbstractCRUDServiceImpl<CheckA
statEntity
.
setTotalScore
(
totalScore
);
}
private
void
computeSummary
(
StaffPerformSummaryEntity
staffPerformSummaryEntity
,
WeightPdu
weightPdu
){
private
static
void
computeSummary
(
StaffPerformSummaryEntity
staffPerformSummaryEntity
,
WeightPdu
weightPdu
){
BigDecimal
total
=
new
BigDecimal
(
100
);
BigDecimal
reviewScore
=
total
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
//评价
reviewScore
=
reviewScore
.
multiply
(
weightPdu
.
reviewWeight
());
BigDecimal
attendScore
=
total
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
//考勤
attendScore
=
attendScore
.
multiply
(
weightPdu
.
attendWeight
());
BigDecimal
otherScore
=
staffPerformSummaryEntity
.
getOtherScore
();
//自评不用加100
if
(
otherScore
.
compareTo
(
BigDecimal
.
ZERO
)==
0
){
otherScore
=
new
BigDecimal
(
100
);
}
otherScore
=
otherScore
.
multiply
(
weightPdu
.
selfWeight
());
BigDecimal
goworkScore
=
total
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
//办件
goworkScore
=
goworkScore
.
multiply
(
weightPdu
.
goworkWeight
());
...
...
@@ -457,4 +461,21 @@ public class CheckAttendRecordServiceImpl extends AbstractCRUDServiceImpl<CheckA
summary
=
summary
.
add
(
effectScore
);
staffPerformSummaryEntity
.
setTotalScore
(
summary
);
}
public
static
void
main
(
String
[]
args
)
{
StaffPerformSummaryEntity
staffPerformSummaryEntity
=
new
StaffPerformSummaryEntity
();
staffPerformSummaryEntity
.
initAttrValue
();
staffPerformSummaryEntity
.
setAttendScore
(
new
BigDecimal
(-
0.4
));
String
ss
=
"{\"attendWeight\":10,\"effectWeight\":20,\"goworkWeight\":20,\"reviewWeight\":0,\"selfWeight\":50}"
;
WeightPdu
weightPdu
=
JSONObject
.
parseObject
(
ss
,
WeightPdu
.
class
);
System
.
out
.
println
(
JSONObject
.
toJSONString
(
weightPdu
));
// BigDecimal total = new BigDecimal(100);
// BigDecimal reviewScore = total.add(staffPerformSummaryEntity.getReviewScore()); //评价
// System.out.println(reviewScore);
// reviewScore = reviewScore.multiply(weightPdu.attendWeight());
// System.out.println(weightPdu.reviewWeight());
// System.out.println(reviewScore);
computeSummary
(
staffPerformSummaryEntity
,
weightPdu
);
System
.
out
.
println
(
JSONObject
.
toJSONString
(
staffPerformSummaryEntity
));
}
}
\ No newline at end of file
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckComplainRecordServiceImpl.java
View file @
72bd19ac
...
...
@@ -228,7 +228,8 @@ public class CheckComplainRecordServiceImpl extends AbstractCRUDServiceImpl<Chec
BigDecimal
erro
=
new
BigDecimal
(
0
);
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getOtherScore
());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
erro
=
erro
.
add
(
Score100
.
subtract
(
staffPerformSummaryEntity
.
getOtherScore
()));
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getEffectScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getComplainScore
());
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckEffectRecordServiceImpl.java
View file @
72bd19ac
...
...
@@ -253,7 +253,8 @@ public class CheckEffectRecordServiceImpl extends AbstractCRUDServiceImpl<CheckE
BigDecimal
erro
=
new
BigDecimal
(
0
);
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getOtherScore
());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
erro
=
erro
.
add
(
Score100
.
subtract
(
staffPerformSummaryEntity
.
getOtherScore
()));
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getEffectScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getComplainScore
());
...
...
@@ -438,6 +439,9 @@ public class CheckEffectRecordServiceImpl extends AbstractCRUDServiceImpl<CheckE
BigDecimal
attendScore
=
total
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
//考勤
attendScore
=
attendScore
.
multiply
(
weightPdu
.
attendWeight
());
BigDecimal
otherScore
=
staffPerformSummaryEntity
.
getOtherScore
();
//自评不用加100
if
(
otherScore
.
compareTo
(
BigDecimal
.
ZERO
)==
0
){
otherScore
=
new
BigDecimal
(
100
);
}
otherScore
=
otherScore
.
multiply
(
weightPdu
.
selfWeight
());
BigDecimal
goworkScore
=
total
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
//办件
goworkScore
=
goworkScore
.
multiply
(
weightPdu
.
goworkWeight
());
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckGoworkRecordServiceImpl.java
View file @
72bd19ac
...
...
@@ -250,7 +250,8 @@ public class CheckGoworkRecordServiceImpl extends AbstractCRUDServiceImpl<CheckG
BigDecimal
erro
=
new
BigDecimal
(
0
);
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getOtherScore
());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
erro
=
erro
.
add
(
Score100
.
subtract
(
staffPerformSummaryEntity
.
getOtherScore
()));
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getEffectScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getComplainScore
());
...
...
@@ -435,6 +436,9 @@ public class CheckGoworkRecordServiceImpl extends AbstractCRUDServiceImpl<CheckG
BigDecimal
attendScore
=
total
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
//考勤
attendScore
=
attendScore
.
multiply
(
weightPdu
.
attendWeight
());
BigDecimal
otherScore
=
staffPerformSummaryEntity
.
getOtherScore
();
//自评不用加100
if
(
otherScore
.
compareTo
(
BigDecimal
.
ZERO
)==
0
){
otherScore
=
new
BigDecimal
(
100
);
}
otherScore
=
otherScore
.
multiply
(
weightPdu
.
selfWeight
());
BigDecimal
goworkScore
=
total
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
//办件
goworkScore
=
goworkScore
.
multiply
(
weightPdu
.
goworkWeight
());
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckOtherRecordServiceImpl.java
View file @
72bd19ac
...
...
@@ -234,7 +234,8 @@ public class CheckOtherRecordServiceImpl extends AbstractCRUDServiceImpl<CheckOt
BigDecimal
erro
=
new
BigDecimal
(
0
);
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getOtherScore
());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
erro
=
erro
.
add
(
Score100
.
subtract
(
staffPerformSummaryEntity
.
getOtherScore
()));
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getEffectScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getComplainScore
());
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckReviewRecordServiceImpl.java
View file @
72bd19ac
...
...
@@ -255,7 +255,8 @@ public class CheckReviewRecordServiceImpl extends AbstractCRUDServiceImpl<CheckR
BigDecimal
erro
=
new
BigDecimal
(
0
);
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getOtherScore
());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
erro
=
erro
.
add
(
Score100
.
subtract
(
staffPerformSummaryEntity
.
getOtherScore
()));
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getEffectScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getComplainScore
());
...
...
@@ -440,6 +441,9 @@ public class CheckReviewRecordServiceImpl extends AbstractCRUDServiceImpl<CheckR
BigDecimal
attendScore
=
total
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
//考勤
attendScore
=
attendScore
.
multiply
(
weightPdu
.
attendWeight
());
BigDecimal
otherScore
=
staffPerformSummaryEntity
.
getOtherScore
();
//自评不用加100
if
(
otherScore
.
compareTo
(
BigDecimal
.
ZERO
)==
0
){
otherScore
=
new
BigDecimal
(
100
);
}
otherScore
=
otherScore
.
multiply
(
weightPdu
.
selfWeight
());
BigDecimal
goworkScore
=
total
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
//办件
goworkScore
=
goworkScore
.
multiply
(
weightPdu
.
goworkWeight
());
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/check/service/impl/CheckWindowWorkmanPerformServiceImpl.java
View file @
72bd19ac
...
...
@@ -127,7 +127,8 @@ public class CheckWindowWorkmanPerformServiceImpl extends AbstractCRUDServiceImp
BigDecimal
erro
=
new
BigDecimal
(
0
);
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getReviewScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
//erro = erro.add(staffPerformSummaryEntity.getOtherScore());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
erro
=
erro
.
add
(
Score100
.
subtract
(
staffPerformSummaryEntity
.
getOtherScore
()));
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getEffectScore
());
erro
=
erro
.
add
(
staffPerformSummaryEntity
.
getComplainScore
());
...
...
@@ -145,7 +146,8 @@ public class CheckWindowWorkmanPerformServiceImpl extends AbstractCRUDServiceImp
staffPerformSummaryEntity
.
setGoworkScore
(
new
BigDecimal
(
0
));
staffPerformSummaryEntity
.
setEffectScore
(
new
BigDecimal
(
0
));
staffPerformSummaryEntity
.
setComplainScore
(
new
BigDecimal
(
0
));
staffPerformSummaryEntity
.
setErrorScore
(
vo
.
getSumScore
());
BigDecimal
Score100
=
new
BigDecimal
(
100
);
staffPerformSummaryEntity
.
setErrorScore
(
Score100
.
subtract
(
vo
.
getSumScore
()));
computeSummary
(
staffPerformSummaryEntity
,
weightPdu
);
staffPerformSummaryEntity
.
setCreateUserId
(
1
l
);
staffPerformSummaryEntity
.
setCreateTime
(
new
Date
());
...
...
@@ -164,6 +166,9 @@ public class CheckWindowWorkmanPerformServiceImpl extends AbstractCRUDServiceImp
BigDecimal
attendScore
=
total
.
add
(
staffPerformSummaryEntity
.
getAttendScore
());
//考勤
attendScore
=
attendScore
.
multiply
(
weightPdu
.
attendWeight
());
BigDecimal
otherScore
=
staffPerformSummaryEntity
.
getOtherScore
();
//自评不用加100
if
(
otherScore
.
compareTo
(
BigDecimal
.
ZERO
)==
0
){
otherScore
=
new
BigDecimal
(
100
);
}
otherScore
=
otherScore
.
multiply
(
weightPdu
.
selfWeight
());
BigDecimal
goworkScore
=
total
.
add
(
staffPerformSummaryEntity
.
getGoworkScore
());
//办件
goworkScore
=
goworkScore
.
multiply
(
weightPdu
.
goworkWeight
());
...
...
attendance-performance-manager/src/main/resources/sqlmap/module/check/CheckWindowWorkmanPerformMapperExt.xml
View file @
72bd19ac
...
...
@@ -5,7 +5,7 @@
<!-- 汇总已审核的核查记录 -->
<select
id=
"getSummaryCheckList"
parameterType=
"com.mortals.xhx.module.check.model.vo.StaffCheckSummaryQuery"
resultType=
"com.mortals.xhx.module.check.model.vo.StaffCheckSummaryVo"
>
SELECT
p.`year`,p.`month`,d.staffId,d.staffName,s.deptId,s.deptName,sum(d.sumScore) as sumScore
p.`year`,p.`month`,d.staffId,d.staffName,s.
salaId,s.salaName,s.
deptId,s.deptName,sum(d.sumScore) as sumScore
FROM
mortals_xhx_check_window_workman_perform p,
mortals_xhx_window_workman_perform w,
...
...
@@ -20,7 +20,7 @@
<if
test=
"recordId != null and recordId!=''"
>
AND p.recordId = #{recordId}
</if>
<if
test=
"year != null and year!=''"
>
AND p.`year` = #{year}
</if>
<if
test=
"month != null and month!=''"
>
AND p.`month` = #{month}
</if>
GROUP BY p.`year`,p.`month`,d.staffId,d.staffName,s.deptId,s.deptName
GROUP BY p.`year`,p.`month`,d.staffId,d.staffName,s.
salaId,s.salaName,s.
deptId,s.deptName
</select>
</mapper>
\ No newline at end of file
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