Commit 4b4df225 authored by 廖旭伟's avatar 廖旭伟

若尔盖考勤汇总导表需求

parent b258a9f2
......@@ -32,7 +32,7 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 员工姓名
*/
@Excel(name = "员工姓名")
@Excel(name = "员工姓名",sort = 1)
private String staffName;
/**
* 所属大厅
......@@ -41,7 +41,7 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 所属大厅名称
*/
@Excel(name = "所属大厅")
@Excel(name = "所属大厅",sort = 2)
private String salaName;
/**
* 所属部门
......@@ -50,24 +50,25 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 所属部门名称
*/
@Excel(name = "部门名称")
@Excel(name = "部门名称",sort = 3)
private String deptName;
/**
* 手机号码
*/
private String phoneNumer;
@Excel(name = "出勤天数")
@Excel(name = "应出勤天数(天)",sort = 4)
private Integer workDays;
/**
* 出勤天数
* 实际正常天数
*/
@Excel(name = "实际出勤天数")
@Excel(name = "实际正常天数(天)",sort = 6)
private Integer goTimes;
/**
* 考勤汇总-出勤率(%)
*/
@Excel(name = "考勤汇总-出勤率",percentEnabled = true,suffix="%",scale=2)
@Excel(name = "考勤汇总-出勤率",percentEnabled = true,suffix="%",scale=2,sort = 7)
private BigDecimal attendanceRate;
/**
* 上午缺卡次数
......@@ -172,12 +173,12 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 考勤汇总-未按规定打卡(含忘记打卡)
*/
@Excel(name = "考勤汇总-未按规定打卡")
@Excel(name = "考勤汇总-未按规定打卡(缺卡次数(次))",sort = 9)
private BigDecimal nonCompliancePunch;
/**
* 考勤汇总-迟到(次)
*/
@Excel(name = "考勤汇总-迟到")
@Excel(name = "考勤汇总-迟到(次)",sort = 10)
private Integer lateTimes;
/**
* 考勤汇总-上网耍手机(次)
......@@ -187,7 +188,7 @@ public class AttendanceStatEntity extends AttendanceStatVo {
/**
* 考勤汇总-溜班(次)
*/
@Excel(name = "考勤汇总-溜班")
@Excel(name = "考勤汇总-溜班(次)",sort = 11)
private Integer overtimeTimes;
/**
* 考勤汇总-空岗
......@@ -251,6 +252,18 @@ public class AttendanceStatEntity extends AttendanceStatVo {
@Excel(name = "陪产假")
private BigDecimal paternityLeaveDays;
/**
* 实际出勤
*/
@Excel(name = "实际出勤(天)",sort = 5)
private Integer goWorks;
/**
* 请假总数(天)
*/
@Excel(name = "请假总数(天)",sort = 12)
private BigDecimal leaveTime;
@Override
public int hashCode() {
......@@ -363,6 +376,10 @@ public class AttendanceStatEntity extends AttendanceStatVo {
this.salaId = null;
this.salaName = "";
this.goWorks = 0;
this.leaveTime = BigDecimal.valueOf(0.0);
}
public static void main(String[] args) {
......
......@@ -23,4 +23,10 @@ public class AttendanceStatVo extends BaseEntityLong {
private String endTime;
private List <Long> idList;
/**
* 正常打卡次数
*/
@Excel(name = "正常次数(次)",sort = 8)
private Integer sumCheck;
}
\ No newline at end of file
......@@ -400,6 +400,9 @@ public class AttendanceStatServiceImpl extends AbstractCRUDServiceImpl<Attendanc
temp.setGoTimes(0); //默认只要有异常考勤,当天就不算全勤
if (item.getMorningTimes() > 0) {
temp.setNonCompliancePunch(new BigDecimal(item.getMorningTimes()));
if(item.getMorningTimes()>=4){
temp.setGoWorks(0); //缺卡4次以上不算全勤
}
}
//this.dao.update(temp);
temp.setStaffName(staffName);
......@@ -526,6 +529,7 @@ public class AttendanceStatServiceImpl extends AbstractCRUDServiceImpl<Attendanc
leaveTime = oneDay;
}
}
temp.setLeaveTime(leaveTime);
//temp.setGoTimes(0); //默认只要有请假,当天就不算全勤
//temp.setMorningTimes(0); //有请假则清空当天缺卡次数
//temp.setLateTimes(0);
......
......@@ -14,7 +14,9 @@
s.salaId,
s.salaName,
count(1) as workDays,
ROUND(IFNULL(sum(s.goTimes),0)/count(1),4) as attendanceRate,
sum(s.goWorks) AS goWorks,
ROUND(IFNULL(sum(s.goWorks),0)/count(1),4) as attendanceRate,
count(1)*4 as sumCheck,
sum(s.goTimes) AS goTimes,
sum(s.morningTimes) AS morningTimes,
sum(s.afternoonTimes) AS afternoonTimes,
......@@ -48,7 +50,8 @@
sum(s.nonStandardDressTimes) AS nonStandardDressTimes,
sum(s.unexcusedMeetingAbsence) AS unexcusedMeetingAbsence,
sum(s.earlyLeaveMeeting) AS earlyLeaveMeeting,
sum(s.lateTimes) AS lateTimes
sum(s.lateTimes) AS lateTimes,
sum(s.leaveTime) AS leaveTime
FROM
mortals_xhx_attendance_stat s
WHERE
......@@ -85,7 +88,10 @@
MAX(s.phoneNumer) as phoneNumer,
s.salaId,
s.salaName,
ROUND(IFNULL(sum(s.goTimes),0)/count(1),4) as attendanceRate,
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(s.goTimes) AS goTimes,
sum(s.morningTimes) AS morningTimes,
sum(s.afternoonTimes) AS afternoonTimes,
......@@ -118,7 +124,9 @@
sum(s.vacancy) AS vacancy,
sum(s.nonStandardDressTimes) AS nonStandardDressTimes,
sum(s.unexcusedMeetingAbsence) AS unexcusedMeetingAbsence,
sum(s.earlyLeaveMeeting) AS earlyLeaveMeeting
sum(s.earlyLeaveMeeting) AS earlyLeaveMeeting,
sum(s.lateTimes) AS lateTimes,
sum(s.leaveTime) AS leaveTime
FROM
mortals_xhx_attendance_stat s
WHERE
......
......@@ -1344,3 +1344,10 @@ ALTER TABLE `mortals_xhx_staff_perform_summary`
ADD COLUMN `sumScore` DECIMAL (10, 2) DEFAULT NULL COMMENT '合计得分' AFTER `addTotalScore`;
UPDATE `mortals_xhx_staff_perform_summary` SET sumScore=totalScore,addTotalScore=0;
-- ----------------------------
2024-09-02
-- ----------------------------
ALTER TABLE `mortals_xhx_attendance_stat`
ADD COLUMN `goWorks` int(9) DEFAULT '0' COMMENT '实际出勤天数',
ADD COLUMN `leaveTime` double(4,1) DEFAULT '0.0' COMMENT '请假天数';
\ No newline at end of file
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