Commit c27953eb authored by 赵啸非's avatar 赵啸非

Merge remote-tracking branch 'origin/reg' into reg

parents 36b2b609 614ccbaa
......@@ -73,7 +73,7 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 上午缺卡次数
*/
@Excel(name = "缺卡次数")
@Excel(name = "考勤汇总-未按规定打卡(缺卡次数(次))",sort = 9)
private Integer morningTimes;
/**
* 下午缺卡次数
......@@ -162,18 +162,18 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 考勤汇总-旷工(天)
*/
@Excel(name = "考勤汇总-旷工")
//@Excel(name = "考勤汇总-旷工")
private BigDecimal absenteeismDays;
/**
* 考勤汇总-其他(天)
*/
@Excel(name = "考勤汇总-其他")
//@Excel(name = "考勤汇总-其他")
private BigDecimal otherDays;
/**
* 考勤汇总-未按规定打卡(含忘记打卡)
*/
@Excel(name = "考勤汇总-未按规定打卡(缺卡次数(次))",sort = 9)
//@Excel(name = "考勤汇总-未按规定打卡(缺卡次数(次))",sort = 9)
private BigDecimal nonCompliancePunch;
/**
* 考勤汇总-迟到(次)
......@@ -183,7 +183,7 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 考勤汇总-上网耍手机(次)
*/
@Excel(name = "考勤汇总-上网耍手机")
//@Excel(name = "考勤汇总-上网耍手机")
private Integer surfingMobileTimes;
/**
* 考勤汇总-溜班(次)
......@@ -193,22 +193,22 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 考勤汇总-空岗
*/
@Excel(name = "考勤汇总-空岗")
//@Excel(name = "考勤汇总-空岗")
private BigDecimal vacancy;
/**
* 考勤汇总-未规范着装(次)
*/
@Excel(name = "考勤汇总-未规范着装")
//@Excel(name = "考勤汇总-未规范着装")
private Integer nonStandardDressTimes;
/**
* 考勤汇总-无故缺席会议
*/
@Excel(name = "考勤汇总-无故缺席会议")
//@Excel(name = "考勤汇总-无故缺席会议")
private BigDecimal unexcusedMeetingAbsence;
/**
* 考勤汇总-会议早退
*/
@Excel(name = "考勤汇总-会议早退")
//@Excel(name = "考勤汇总-会议早退")
private BigDecimal earlyLeaveMeeting;
/**
* 年
......
......@@ -411,24 +411,33 @@ public class AttendanceStatServiceImpl extends AbstractCRUDServiceImpl<Attendanc
updateList.add(temp);
}
String attendanceSummary = "";
int normal = 4; //正常次数
if (item.getMorningTimes() > 0) {
attendanceSummary += "缺卡*" + item.getMorningTimes() + "次;";
normal= normal-item.getMorningTimes();
}
if (item.getLateTimes() > 0) {
attendanceSummary += "迟到*" + item.getLateTimes() + "次;";
normal= normal-item.getLateTimes();
}
if (item.getOvertimeTimes() > 0) {
attendanceSummary += "早退*" + item.getOvertimeTimes() + "次;";
normal= normal-item.getOvertimeTimes();
}
if (item.getLeaveHalfDay() > 0) {
attendanceSummary += "事假半天*" + item.getLeaveHalfDay() + "次;";
normal = normal-2;
}
if (item.getLeaveDay() > 0) {
attendanceSummary += "事假全天*" + item.getLeaveDay() + "次;";
normal = 0;
}
AttendanceStaffStatEntity staffStat = new AttendanceStaffStatEntity();
staffStat.initAttrValue();
BeanUtils.copyProperties(item, staffStat, BeanUtil.getNullPropertyNames(item));
if(normal>0){
attendanceSummary = "正常*"+normal + "次;" + attendanceSummary;
}
staffStat.setAttendanceSummary(attendanceSummary);
if (!ObjectUtils.isEmpty(attendanceSummary)) {
......@@ -540,7 +549,7 @@ public class AttendanceStatServiceImpl extends AbstractCRUDServiceImpl<Attendanc
if (leaveTypeEnum == null) {
leaveTypeEnum = LeaveTypeEnum.事假; //默认为事假
}
attendanceSummary = leaveTypeEnum.getDesc() + "*1";
attendanceSummary = leaveTypeEnum.getDesc() + "*1";
switch (leaveTypeEnum) {
case 事假:
temp.setPersonalLeave(leaveTime);
......
......@@ -340,21 +340,21 @@ public class AttendanceStatController extends BaseCRUDJsonBodyMappingController<
if(isNull(entity.getNonCompliancePunch())){
entity.setNonCompliancePunch(null);
}
if(entity.getLateTimes()!=null && entity.getLateTimes()==0){
entity.setLateTimes(null);
}
if(entity.getSurfingMobileTimes()!=null && entity.getSurfingMobileTimes()==0){
entity.setSurfingMobileTimes(null);
}
if(entity.getOvertimeTimes()!=null && entity.getOvertimeTimes()==0){
entity.setOvertimeTimes(null);
}
// if(entity.getLateTimes()!=null && entity.getLateTimes()==0){
// entity.setLateTimes(null);
// }
// if(entity.getSurfingMobileTimes()!=null && entity.getSurfingMobileTimes()==0){
// entity.setSurfingMobileTimes(null);
// }
// if(entity.getOvertimeTimes()!=null && entity.getOvertimeTimes()==0){
// entity.setOvertimeTimes(null);
// }
if(isNull(entity.getVacancy())){
entity.setVacancy(null);
}
if(entity.getNonStandardDressTimes()!=null && entity.getNonStandardDressTimes()==0){
entity.setNonStandardDressTimes(null);
}
// if(entity.getNonStandardDressTimes()!=null && entity.getNonStandardDressTimes()==0){
// entity.setNonStandardDressTimes(null);
// }
if(isNull(entity.getUnexcusedMeetingAbsence())){
entity.setUnexcusedMeetingAbsence(null);
}
......
......@@ -16,7 +16,7 @@
count(1) as workDays,
sum(s.goWorks) AS goWorks,
ROUND(IFNULL(sum(s.goWorks),0)/count(1),4) as attendanceRate,
count(1)*4 as sumCheck,
sum(4-s.morningTimes-s.lateTimes-s.overtimeTimes) as sumCheck,
sum(s.goTimes) AS goTimes,
sum(s.morningTimes) AS morningTimes,
sum(s.afternoonTimes) AS afternoonTimes,
......@@ -45,12 +45,12 @@
sum(s.otherDays) AS otherDays,
sum(s.nonCompliancePunch) AS nonCompliancePunch,
sum(s.surfingMobileTimes) AS surfingMobileTimes,
sum(s.overtimeTimes) AS overtimeTimes,
sum(IFNULL(s.overtimeTimes,0)) AS overtimeTimes,
sum(s.vacancy) AS vacancy,
sum(s.nonStandardDressTimes) AS nonStandardDressTimes,
sum(s.unexcusedMeetingAbsence) AS unexcusedMeetingAbsence,
sum(s.earlyLeaveMeeting) AS earlyLeaveMeeting,
sum(s.lateTimes) AS lateTimes,
sum(IFNULL(s.lateTimes,0)) AS lateTimes,
sum(s.leaveTime) AS leaveTime
FROM
mortals_xhx_attendance_stat s
......@@ -91,7 +91,7 @@
count(1) as workDays,
sum(s.goWorks) AS goWorks,
ROUND(IFNULL(sum(s.goWorks),0)/count(1),4) as attendanceRate,
count(1)*4 as sumCheck,
sum(4-s.morningTimes-s.lateTimes-s.overtimeTimes) as sumCheck,
sum(s.goTimes) AS goTimes,
sum(s.morningTimes) AS morningTimes,
sum(s.afternoonTimes) AS afternoonTimes,
......@@ -120,12 +120,12 @@
sum(s.otherDays) AS otherDays,
sum(s.nonCompliancePunch) AS nonCompliancePunch,
sum(s.surfingMobileTimes) AS surfingMobileTimes,
sum(s.overtimeTimes) AS overtimeTimes,
sum(IFNULL(s.overtimeTimes,0)) AS overtimeTimes,
sum(s.vacancy) AS vacancy,
sum(s.nonStandardDressTimes) AS nonStandardDressTimes,
sum(s.unexcusedMeetingAbsence) AS unexcusedMeetingAbsence,
sum(s.earlyLeaveMeeting) AS earlyLeaveMeeting,
sum(s.lateTimes) AS lateTimes,
sum(IFNULL(s.lateTimes,0)) AS lateTimes,
sum(s.leaveTime) AS leaveTime
FROM
mortals_xhx_attendance_stat s
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment