绩效考核导出添加社区字段
This commit is contained in:
parent
b35498a75b
commit
ae19353c2d
@ -2,6 +2,8 @@ package com.cm.systemcity.pojo.dtos.assessment;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.ToString;
|
||||
|
||||
/**
|
||||
* When you feel like quitting. Think about why you started
|
||||
@ -14,6 +16,8 @@ import io.swagger.annotations.ApiModelProperty;
|
||||
* @Version: 1.0
|
||||
**/
|
||||
@ApiModel
|
||||
@Data
|
||||
@ToString
|
||||
public class AssessmentDTO {
|
||||
|
||||
@ApiModelProperty(name = "userId", value = "用户ID")
|
||||
@ -24,6 +28,8 @@ public class AssessmentDTO {
|
||||
private String positionNames;
|
||||
@ApiModelProperty(name = "departmentNames", value = "部门名称列表")
|
||||
private String departmentNames;
|
||||
@ApiModelProperty(name = "communityNames", value = "社区名称")
|
||||
private String communityNames;
|
||||
@ApiModelProperty(name = "shouldSigninCount", value = "应签到次数")
|
||||
private Integer shouldSigninCount;
|
||||
@ApiModelProperty(name = "signinCount", value = "签到次数")
|
||||
@ -52,191 +58,4 @@ public class AssessmentDTO {
|
||||
private Double workDistance;
|
||||
@ApiModelProperty(name = "deductionPercent", value = "绩效扣除百分比")
|
||||
private Double deductionPercent;
|
||||
|
||||
public String getUserId() {
|
||||
return userId == null ? "" : userId.trim();
|
||||
}
|
||||
|
||||
public void setUserId(String userId) {
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public String getUserName() {
|
||||
return userName == null ? "" : userName.trim();
|
||||
}
|
||||
|
||||
public void setUserName(String userName) {
|
||||
this.userName = userName;
|
||||
}
|
||||
|
||||
public String getPositionNames() {
|
||||
return positionNames == null ? "" : positionNames.trim();
|
||||
}
|
||||
|
||||
public void setPositionNames(String positionNames) {
|
||||
this.positionNames = positionNames;
|
||||
}
|
||||
|
||||
public String getDepartmentNames() {
|
||||
return departmentNames == null ? "" : departmentNames;
|
||||
}
|
||||
|
||||
public void setDepartmentNames(String departmentNames) {
|
||||
this.departmentNames = departmentNames;
|
||||
}
|
||||
|
||||
public Integer getSigninCount() {
|
||||
return signinCount;
|
||||
}
|
||||
|
||||
public void setSigninCount(Integer signinCount) {
|
||||
this.signinCount = signinCount;
|
||||
}
|
||||
|
||||
public Integer getSignoutCount() {
|
||||
return signoutCount;
|
||||
}
|
||||
|
||||
public void setSignoutCount(Integer signoutCount) {
|
||||
this.signoutCount = signoutCount;
|
||||
}
|
||||
|
||||
public Integer getUnSigninCount() {
|
||||
return unSigninCount;
|
||||
}
|
||||
|
||||
public void setUnSigninCount(Integer unSigninCount) {
|
||||
this.unSigninCount = unSigninCount;
|
||||
}
|
||||
|
||||
public Integer getUnSignoutCount() {
|
||||
return unSignoutCount;
|
||||
}
|
||||
|
||||
public void setUnSignoutCount(Integer unSignoutCount) {
|
||||
this.unSignoutCount = unSignoutCount;
|
||||
}
|
||||
|
||||
public Integer getAmDayLeaveCount() {
|
||||
return amDayLeaveCount;
|
||||
}
|
||||
|
||||
public void setAmDayLeaveCount(Integer amDayLeaveCount) {
|
||||
this.amDayLeaveCount = amDayLeaveCount;
|
||||
}
|
||||
|
||||
public Integer getPmDayLeaveCount() {
|
||||
return pmDayLeaveCount;
|
||||
}
|
||||
|
||||
public void setPmDayLeaveCount(Integer pmDayLeaveCount) {
|
||||
this.pmDayLeaveCount = pmDayLeaveCount;
|
||||
}
|
||||
|
||||
public Double getLeaveTimeSum() {
|
||||
return leaveTimeSum;
|
||||
}
|
||||
|
||||
public void setLeaveTimeSum(Double leaveTimeSum) {
|
||||
this.leaveTimeSum = leaveTimeSum;
|
||||
}
|
||||
|
||||
public Integer getAbsenteeismCount() {
|
||||
return absenteeismCount;
|
||||
}
|
||||
|
||||
public void setAbsenteeismCount(Integer absenteeismCount) {
|
||||
this.absenteeismCount = absenteeismCount;
|
||||
}
|
||||
|
||||
public Integer getOutOfContactOneHourCount() {
|
||||
return outOfContactOneHourCount;
|
||||
}
|
||||
|
||||
public void setOutOfContactOneHourCount(Integer outOfContactOneHourCount) {
|
||||
this.outOfContactOneHourCount = outOfContactOneHourCount;
|
||||
}
|
||||
|
||||
public Double getContactHour() {
|
||||
return contactHour;
|
||||
}
|
||||
|
||||
public void setContactHour(Double contactHour) {
|
||||
this.contactHour = contactHour;
|
||||
}
|
||||
|
||||
public Double getWorkDistance() {
|
||||
return workDistance;
|
||||
}
|
||||
|
||||
public void setWorkDistance(Double workDistance) {
|
||||
this.workDistance = workDistance;
|
||||
}
|
||||
|
||||
public Double getDeductionPercent() {
|
||||
return deductionPercent;
|
||||
}
|
||||
|
||||
public void setDeductionPercent(Double deductionPercent) {
|
||||
this.deductionPercent = deductionPercent;
|
||||
}
|
||||
|
||||
public Integer getShouldSigninCount() {
|
||||
return shouldSigninCount;
|
||||
}
|
||||
|
||||
public void setShouldSigninCount(Integer shouldSigninCount) {
|
||||
this.shouldSigninCount = shouldSigninCount;
|
||||
}
|
||||
|
||||
public Integer getShouldSignoutCount() {
|
||||
return shouldSignoutCount;
|
||||
}
|
||||
|
||||
public void setShouldSignoutCount(Integer shouldSignoutCount) {
|
||||
this.shouldSignoutCount = shouldSignoutCount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
final StringBuilder sb = new StringBuilder("{");
|
||||
sb.append("\"userId\":\"")
|
||||
.append(userId).append('\"');
|
||||
sb.append(",\"userName\":\"")
|
||||
.append(userName).append('\"');
|
||||
sb.append(",\"positionNames\":\"")
|
||||
.append(positionNames).append('\"');
|
||||
sb.append(",\"departmentNames\":\"")
|
||||
.append(departmentNames).append('\"');
|
||||
sb.append(",\"shouldSigninCount\":")
|
||||
.append(shouldSigninCount);
|
||||
sb.append(",\"signinCount\":")
|
||||
.append(signinCount);
|
||||
sb.append(",\"shouldSignoutCount\":")
|
||||
.append(shouldSignoutCount);
|
||||
sb.append(",\"signoutCount\":")
|
||||
.append(signoutCount);
|
||||
sb.append(",\"unSigninCount\":")
|
||||
.append(unSigninCount);
|
||||
sb.append(",\"unSignoutCount\":")
|
||||
.append(unSignoutCount);
|
||||
sb.append(",\"amDayLeaveCount\":")
|
||||
.append(amDayLeaveCount);
|
||||
sb.append(",\"pmDayLeaveCount\":")
|
||||
.append(pmDayLeaveCount);
|
||||
sb.append(",\"leaveTimeSum\":")
|
||||
.append(leaveTimeSum);
|
||||
sb.append(",\"absenteeismCount\":")
|
||||
.append(absenteeismCount);
|
||||
sb.append(",\"outOfContactOneHourCount\":")
|
||||
.append(outOfContactOneHourCount);
|
||||
sb.append(",\"contactHour\":")
|
||||
.append(contactHour);
|
||||
sb.append(",\"workDistance\":")
|
||||
.append(workDistance);
|
||||
sb.append(",\"deductionPercent\":")
|
||||
.append(deductionPercent);
|
||||
sb.append('}');
|
||||
return sb.toString();
|
||||
}
|
||||
}
|
||||
|
@ -22,6 +22,8 @@ public class AssessmentExcelDTO {
|
||||
private String userName;
|
||||
@ExcelProperty(value = "部门名称列表")
|
||||
private String departmentNames;
|
||||
@ExcelProperty(value = "社区名称列表")
|
||||
private String communityNames;
|
||||
@ExcelProperty(value = "应签到次数")
|
||||
private String shouldSignInCount;
|
||||
@ExcelProperty(value = "签到次数")
|
||||
|
@ -611,6 +611,7 @@ public class AssessmentServiceImpl extends BaseService implements IAssessmentSer
|
||||
AssessmentExcelDTO assessmentExcelDTO = new AssessmentExcelDTO();
|
||||
assessmentExcelDTO.setUserName(assessmentDTO.getUserName());
|
||||
assessmentExcelDTO.setDepartmentNames(assessmentDTO.getDepartmentNames());
|
||||
assessmentExcelDTO.setCommunityNames(assessmentDTO.getCommunityNames());
|
||||
assessmentExcelDTO.setShouldSignInCount(String.valueOf(assessmentDTO.getShouldSigninCount()));
|
||||
assessmentExcelDTO.setSignInCount(String.valueOf(assessmentDTO.getSigninCount()));
|
||||
assessmentExcelDTO.setShouldSignOutCount(String.valueOf(assessmentDTO.getShouldSignoutCount()));
|
||||
@ -623,7 +624,7 @@ public class AssessmentServiceImpl extends BaseService implements IAssessmentSer
|
||||
assessmentExcelDTO.setDeductionPercent(assessmentDTO.getDeductionPercent().toString());
|
||||
assessmentExcelDTOs.add(assessmentExcelDTO);
|
||||
}
|
||||
String[] excelHeaderNames = {"人员名称", "部门", "应签到次数", "签到次数", "应签退次数", "签退次数", "请假天数", "旷工次数", "失联1小时情况(次)", "工作时长(小时)", "工作里程(KM)", "绩效扣除比例(%)"};
|
||||
String[] excelHeaderNames = {"人员名称", "部门", "社区", "应签到次数", "签到次数", "应签退次数", "签退次数", "请假天数", "旷工次数", "失联1小时情况(次)", "工作时长(小时)", "工作里程(KM)", "绩效扣除比例(%)"};
|
||||
List<List<String>> excelHeaders = simpleExcelHeader(excelHeaderNames);
|
||||
EasyExcel.write(response.getOutputStream()).sheet("历史考勤统计").head(excelHeaders).doWrite(assessmentExcelDTOs);
|
||||
}
|
||||
|
@ -40,6 +40,7 @@
|
||||
<result property="userName" column="user_name"/>
|
||||
<result property="positionNames" column="position_names"/>
|
||||
<result property="departmentNames" column="department_names"/>
|
||||
<result property="communityNames" column="community_names"/>
|
||||
<result property="shouldSigninCount" column="should_signin_count"/>
|
||||
<result property="signinCount" column="signin_count"/>
|
||||
<result property="unSigninCount" column="unsignin_count"/>
|
||||
@ -200,6 +201,7 @@
|
||||
t1.user_name,
|
||||
t1.position_names,
|
||||
t1.department_names,
|
||||
t1.community_names,
|
||||
SUM(t1.should_signin_count) should_signin_count,
|
||||
SUM(t1.signin_count) signin_count,
|
||||
SUM(t1.unsignin_count) unsignin_count,
|
||||
|
Loading…
Reference in New Issue
Block a user