Commit 5ad449c7 by leialin

Merge branch 'tzq' into 'develop'

审批考勤业务

See merge request 8timerv2/8timerapiv200!227
parents 9c28781b 0ae2717d
...@@ -671,17 +671,18 @@ public class SpmkController { ...@@ -671,17 +671,18 @@ public class SpmkController {
SpmkApproveSummary.builder().id(asId).currentApprover(CommonEnum.NULL_STR.getDesc()).endTime(new Date()).sts(ApproveSummarySts.FINISH.ordinal()).build().updateById(); SpmkApproveSummary.builder().id(asId).currentApprover(CommonEnum.NULL_STR.getDesc()).endTime(new Date()).sts(ApproveSummarySts.FINISH.ordinal()).build().updateById();
JSONObject jSONObject = ObjectUtil.deserialize(ad.getRequestData()); JSONObject jSONObject = ObjectUtil.deserialize(ad.getRequestData());
jSONObject.set("approveId", FromData.builder().value(String.valueOf(asId))); jSONObject.set("approveId", FromData.builder().value(String.valueOf(asId)).build());
jSONObject.set("orgCode", userBean.getOrgCode()); jSONObject.set("orgCode", userBean.getOrgCode());
System.out.println("0----------"+ FromData.builder().value(String.valueOf(asId)));
System.out.println("1----------"+ aSummary.getAssoType()); System.out.println("1----------"+ aSummary.getAssoType());
System.out.println("2----------"+ ApproveEnum.getEnums(aSummary.getAssoType())); System.out.println("2----------"+ ApproveEnum.getEnums(aSummary.getAssoType()));
//审批完成后 业务 //审批完成后 业务
SpmkAssoBusiness sab = spmkAssoBusinessFactory.createSpmkService(ApproveEnum.getEnums(aSummary.getAssoType())); SpmkAssoBusiness sab = spmkAssoBusinessFactory.createSpmkService(ApproveEnum.getEnums(aSummary.getAssoType()));
if (sab != null) if (sab != null)
System.out.println("3----------"+ sab); System.out.println("3----------"+ sab);
System.out.println("4----------"+ jSONObject);
sab.handleApprove(jSONObject); sab.handleApprove(jSONObject);
System.out.println("4----------"+ aSummary.getAssoType());
} }
} }
......
...@@ -454,7 +454,12 @@ public class YgglController { ...@@ -454,7 +454,12 @@ public class YgglController {
break; break;
case 1: case 1:
String[] strs = IdcardUtil.isValidCard10(zjNum); String[] strs = IdcardUtil.isValidCard10(zjNum);
isvalid = "澳门/香港".contains(strs[0]) && "true".equals(strs[2]); if (strs == null) {
isvalid = false;
break;
}
String str2 = strs != null && strs.length > 2 ? strs[2] : "false";
isvalid = "澳门/香港".contains(strs[0]) && "true".equals(str2);
break; break;
case 2: case 2:
isvalid = IdcardUtil.isValidTWCard(zjNum); isvalid = IdcardUtil.isValidTWCard(zjNum);
......
...@@ -16,10 +16,12 @@ import cn.timer.api.bean.yggl.YgglMainEmp; ...@@ -16,10 +16,12 @@ import cn.timer.api.bean.yggl.YgglMainEmp;
import cn.timer.api.bean.yggl.YgglMainLzb; import cn.timer.api.bean.yggl.YgglMainLzb;
import cn.timer.api.bean.zzgl.ZzglBmgwM; import cn.timer.api.bean.zzgl.ZzglBmgwM;
import cn.timer.api.config.enuminterface.YgEnumInterface; import cn.timer.api.config.enuminterface.YgEnumInterface;
import cn.timer.api.config.enuminterface.YgEnumInterface.jobStatus;
import cn.timer.api.dao.yggl.YgglMainEmpMapper; import cn.timer.api.dao.yggl.YgglMainEmpMapper;
import cn.timer.api.dao.zzgl.ZzglBmgwMMapper; import cn.timer.api.dao.zzgl.ZzglBmgwMMapper;
import cn.timer.api.dto.yggl.LzygQueryDto; import cn.timer.api.dto.yggl.LzygQueryDto;
import cn.timer.api.dto.yggl.YgzzDto; import cn.timer.api.dto.yggl.YgzzDto;
import cn.timer.api.utils.ResultUtil;
@Service @Service
public class YgglServiceImpl implements YgglService { public class YgglServiceImpl implements YgglService {
...@@ -33,23 +35,36 @@ public class YgglServiceImpl implements YgglService { ...@@ -33,23 +35,36 @@ public class YgglServiceImpl implements YgglService {
@Override @Override
public void applicationResignation(LzygQueryDto lzygQueryDto) { public void applicationResignation(LzygQueryDto lzygQueryDto) {
// TODO Auto-generated method stub // TODO Auto-generated method stub
Integer empNum = lzygQueryDto.getEmpNum(); Integer empNum = lzygQueryDto.getEmpNum();
Integer orgCode = lzygQueryDto.getOrgCode();
YgglMainEmp ygglMainEmp = ygglMainEmpMapper.selectOne(new QueryWrapper<YgglMainEmp>().lambda()
.eq(YgglMainEmp::getEmpNum, empNum)
.eq(YgglMainEmp::getOrgCode, orgCode));
// if (ygglMainEmp.getJobStatus() == jobStatus.LIZHIZHONG.getType()) {
// return ResultUtil.success("你已在离职中");
// }
QueryWrapper<YgglMainEmp> queryWrapper = new QueryWrapper<YgglMainEmp>();
queryWrapper.eq("emp_num", empNum).eq("org_code", lzygQueryDto.getOrgCode());
YgglMainEmp ygglMainEmp = YgglMainEmp.builder().build().selectOne(queryWrapper);
YgglMainLzb ygglMainLzb = YgglMainLzb.builder().empNum(lzygQueryDto.getEmpNum()).build(); YgglMainLzb ygglMainLzb = YgglMainLzb.builder().empNum(lzygQueryDto.getEmpNum()).build();
// 移动员工表数据到离职表 // 移动员工表数据到离职表
BeanUtil.copyProperties(ygglMainEmp, ygglMainLzb); BeanUtil.copyProperties(ygglMainEmp, ygglMainLzb, "before_leaving_sts");
ygglMainLzb.insert(); ygglMainLzb.insert();
UpdateWrapper<YgglMainEmp> updateWrapper = new UpdateWrapper<YgglMainEmp>(); YgglMainEmp.builder().empNum(lzygQueryDto.getEmpNum()).jobStatus(jobStatus.LIZHIZHONG.getType())
updateWrapper.eq("emp_num", empNum); .beforeLeavingSts(ygglMainEmp.getJobStatus()).build()
UpdateWrapper<YgglMainLzb> updateWrapper1 = new UpdateWrapper<YgglMainLzb>(); .update(new UpdateWrapper<YgglMainEmp>().lambda()
updateWrapper1.eq("emp_num", empNum); .eq(YgglMainEmp::getEmpNum, empNum)
YgglMainEmp.builder().empNum(lzygQueryDto.getEmpNum()).jobStatus(YgEnumInterface.jobStatus.YILIZHI.getType()).build().update(updateWrapper); .eq(YgglMainEmp::getOrgCode, orgCode));
YgglMainLzb.builder().jobStatus(YgEnumInterface.jobStatus.LIZHIZHONG.getType()).lzTime(lzygQueryDto.getLzTime())
.lzyy(lzygQueryDto.getLzyy()).lzbz(lzygQueryDto.getLzbz()).build().update(updateWrapper1); YgglMainLzb.builder()
.jobStatus(jobStatus.LIZHIZHONG.getType())
.lzTime(lzygQueryDto.getLzTime())
.lzyy(lzygQueryDto.getLzyy()).lzbz(lzygQueryDto.getLzbz()).build()
.update(new UpdateWrapper<YgglMainLzb>().lambda()
.eq(YgglMainLzb::getEmpNum, empNum)
.eq(YgglMainLzb::getOrgCode, orgCode));
} }
@Override @Override
......
...@@ -31,7 +31,7 @@ public class EvectionBusiness extends SpmkAssoBusiness { ...@@ -31,7 +31,7 @@ public class EvectionBusiness extends SpmkAssoBusiness {
// 发起人企业id // 发起人企业id
Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode")); Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode"));
// 发起人id // 发起人id
String id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : jsonObj.get("id",FromData.class).getValue(); Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("id",FromData.class).getValue());
// 发起人名称 // 发起人名称
String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue(); String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue();
...@@ -50,6 +50,8 @@ public class EvectionBusiness extends SpmkAssoBusiness { ...@@ -50,6 +50,8 @@ public class EvectionBusiness extends SpmkAssoBusiness {
AttEvectionApprovalDto eaD = AttEvectionApprovalDto AttEvectionApprovalDto eaD = AttEvectionApprovalDto
.builder() .builder()
.userid(id)
.orgcode(orgCode)
.evectionid(Convert.toInt(approveId)) .evectionid(Convert.toInt(approveId))
.evectiontype(1) .evectiontype(1)
.starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm:ss")) .starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm:ss"))
......
...@@ -29,7 +29,7 @@ public class GoOutBusiness extends SpmkAssoBusiness { ...@@ -29,7 +29,7 @@ public class GoOutBusiness extends SpmkAssoBusiness {
// 发起人企业id // 发起人企业id
Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode")); Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode"));
// 发起人id // 发起人id
String id = jsonObj.get("id",FromData.class).getValue(); Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("id",FromData.class).getValue());
// 发起人名称 // 发起人名称
String initiator = jsonObj.get("initiator",FromData.class).getValue(); String initiator = jsonObj.get("initiator",FromData.class).getValue();
...@@ -48,6 +48,8 @@ public class GoOutBusiness extends SpmkAssoBusiness { ...@@ -48,6 +48,8 @@ public class GoOutBusiness extends SpmkAssoBusiness {
AttEvectionApprovalDto eaD = AttEvectionApprovalDto AttEvectionApprovalDto eaD = AttEvectionApprovalDto
.builder() .builder()
.userid(id)
.orgcode(orgCode)
.evectionid(Convert.toInt(approveId)) .evectionid(Convert.toInt(approveId))
.evectiontype(2) .evectiontype(2)
.starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm:ss")) .starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm:ss"))
......
...@@ -33,14 +33,14 @@ public class LeaveBusiness extends SpmkAssoBusiness { ...@@ -33,14 +33,14 @@ public class LeaveBusiness extends SpmkAssoBusiness {
// 发起人企业id // 发起人企业id
Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode")); Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode"));
// 发起人id // 发起人id
String id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : jsonObj.get("id",FromData.class).getValue(); Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("id",FromData.class).getValue());
// 发起人名称 // 发起人名称
String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue(); String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue();
// 审批汇总id // 审批汇总id
String approveId = ObjectUtil.isNull(jsonObj.get("approveId",FromData.class)) ? null : jsonObj.get("approveId",FromData.class).getValue(); String approveId = ObjectUtil.isNull(jsonObj.get("approveId",FromData.class)) ? null : jsonObj.get("approveId",FromData.class).getValue();
// 请假类型 // 请假类型 - 前端传中文
String LeaveType = ObjectUtil.isNull(jsonObj.get("__LeaveType",FromData.class)) ? null : jsonObj.get("__LeaveType",FromData.class).getValue(); String LeaveType = ObjectUtil.isNull(jsonObj.get("__LeaveType",FromData.class)) ? null : jsonObj.get("__LeaveType",FromData.class).getValue();
// 开始时间 // 开始时间
String startTime = ObjectUtil.isNull(jsonObj.get("__startTime",FromData.class)) ? null : jsonObj.get("__startTime",FromData.class).getValue(); String startTime = ObjectUtil.isNull(jsonObj.get("__startTime",FromData.class)) ? null : jsonObj.get("__startTime",FromData.class).getValue();
...@@ -55,8 +55,10 @@ public class LeaveBusiness extends SpmkAssoBusiness { ...@@ -55,8 +55,10 @@ public class LeaveBusiness extends SpmkAssoBusiness {
AttLeaveApprovalDto laD = AttLeaveApprovalDto AttLeaveApprovalDto laD = AttLeaveApprovalDto
.builder() .builder()
.userid(id)
.orgcode(orgCode)
.leaveid(Convert.toInt(approveId)) .leaveid(Convert.toInt(approveId))
.leavetype(Convert.toInt(LeaveType)) .leavetype(Convert.toInt(1))
.starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm:ss")) .starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm:ss"))
.endtime(DateUtil.getStringTime(endTime, "yyyy-MM-dd HH:mm:ss")) .endtime(DateUtil.getStringTime(endTime, "yyyy-MM-dd HH:mm:ss"))
.duration(Convert.toDouble(longTime)) .duration(Convert.toDouble(longTime))
......
...@@ -23,7 +23,7 @@ public class RecruitBusiness extends SpmkAssoBusiness { ...@@ -23,7 +23,7 @@ public class RecruitBusiness extends SpmkAssoBusiness {
// 发起人企业id // 发起人企业id
Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode")); Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode"));
// 发起人id // 发起人id
String id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : jsonObj.get("id",FromData.class).getValue(); Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("id",FromData.class).getValue());
// 发起人名称 // 发起人名称
String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue(); String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue();
......
...@@ -31,7 +31,7 @@ public class ReissueACardBusiness extends SpmkAssoBusiness { ...@@ -31,7 +31,7 @@ public class ReissueACardBusiness extends SpmkAssoBusiness {
// 发起人企业id // 发起人企业id
Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode")); Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode"));
// 发起人id // 发起人id
String id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : jsonObj.get("id",FromData.class).getValue(); Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("id",FromData.class).getValue());
// 发起人名称 // 发起人名称
String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue(); String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue();
...@@ -50,6 +50,8 @@ public class ReissueACardBusiness extends SpmkAssoBusiness { ...@@ -50,6 +50,8 @@ public class ReissueACardBusiness extends SpmkAssoBusiness {
AttRepairApprovalDto raD = AttRepairApprovalDto AttRepairApprovalDto raD = AttRepairApprovalDto
.builder() .builder()
.userid(id)
.orgcode(orgCode)
.repairid(Convert.toInt(approveId)) .repairid(Convert.toInt(approveId))
.cardrepltime(DateUtil.getStringTime(PatchCardTime, "yyyy-MM-dd HH:mm:ss")) .cardrepltime(DateUtil.getStringTime(PatchCardTime, "yyyy-MM-dd HH:mm:ss"))
.cardreplperiod(Convert.toInt(cardreplperiod)) .cardreplperiod(Convert.toInt(cardreplperiod))
......
...@@ -32,7 +32,7 @@ public class ResignationBusiness extends SpmkAssoBusiness { ...@@ -32,7 +32,7 @@ public class ResignationBusiness extends SpmkAssoBusiness {
// 发起人企业id // 发起人企业id
Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode")); Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode"));
// 发起人id // 发起人id
Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("",FromData.class).getValue()); Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("id",FromData.class).getValue());
// 发起人名称 // 发起人名称
String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue(); String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue();
......
...@@ -6,6 +6,7 @@ import org.springframework.stereotype.Service; ...@@ -6,6 +6,7 @@ import org.springframework.stereotype.Service;
import cn.hutool.core.convert.Convert; import cn.hutool.core.convert.Convert;
import cn.hutool.core.util.ObjectUtil; import cn.hutool.core.util.ObjectUtil;
import cn.hutool.json.JSONObject; import cn.hutool.json.JSONObject;
import cn.timer.api.config.exception.CustomException;
import cn.timer.api.controller.zzgl.service.ZzglBmgwMService; import cn.timer.api.controller.zzgl.service.ZzglBmgwMService;
import cn.timer.api.dto.spmk.FromData; import cn.timer.api.dto.spmk.FromData;
import cn.timer.api.dto.zzgl.UpEmpDeptDto; import cn.timer.api.dto.zzgl.UpEmpDeptDto;
...@@ -38,9 +39,12 @@ public class TransferPositionBusiness extends SpmkAssoBusiness { ...@@ -38,9 +39,12 @@ public class TransferPositionBusiness extends SpmkAssoBusiness {
// 申请原因 // 申请原因
String ReasonForApplication = ObjectUtil.isNull(jsonObj.get("__ReasonForApplication",FromData.class)) ? null : jsonObj.get("__ReasonForApplication",FromData.class).getValue(); String ReasonForApplication = ObjectUtil.isNull(jsonObj.get("__ReasonForApplication",FromData.class)) ? null : jsonObj.get("__ReasonForApplication",FromData.class).getValue();
// 调入部门 // 调入部门
Integer TransferInDepartment = ObjectUtil.isNull(jsonObj.get("__TransferInDepartment",FromData.class)) ? null : Integer.parseInt(jsonObj.get("__TransferInDepartment",FromData.class).getValue()); Integer TransferInDepartment = ObjectUtil.isNull(jsonObj.get("__TransferInDepartment",FromData.class)) ? null : Convert.toInt(jsonObj.get("__TransferInDepartment",FromData.class).getValue());
// 调入岗位 // 调入岗位
String TransferInPosition = ObjectUtil.isNull(jsonObj.get("__TransferInPosition",FromData.class)) ? null : jsonObj.get("__TransferInPosition",FromData.class).getValue(); Integer TransferInPosition = ObjectUtil.isNull(jsonObj.get("__TransferInPosition",FromData.class)) ? null : Integer.parseInt(jsonObj.get("__TransferInPosition",FromData.class).getValue());
if (TransferInDepartment == null || TransferInPosition == null) {
throw new CustomException("部门或岗位 未填写,审批失败");
}
// 生效日期 // 生效日期
String effectiveDate = ObjectUtil.isNull(jsonObj.get("__effectiveDate",FromData.class)) ? null : jsonObj.get("__effectiveDate",FromData.class).getValue(); String effectiveDate = ObjectUtil.isNull(jsonObj.get("__effectiveDate",FromData.class)) ? null : jsonObj.get("__effectiveDate",FromData.class).getValue();
// 备注 // 备注
......
...@@ -30,7 +30,7 @@ public class WorkOvertimeBusiness extends SpmkAssoBusiness { ...@@ -30,7 +30,7 @@ public class WorkOvertimeBusiness extends SpmkAssoBusiness {
// 发起人企业id // 发起人企业id
Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode")); Integer orgCode = ObjectUtil.isNull(jsonObj.get("orgCode")) ? null : Convert.toInt(jsonObj.get("orgCode"));
// 发起人id // 发起人id
String id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : jsonObj.get("id",FromData.class).getValue(); Integer id = ObjectUtil.isNull(jsonObj.get("id",FromData.class)) ? null : Integer.parseInt(jsonObj.get("id",FromData.class).getValue());
// 发起人名称 // 发起人名称
String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue(); String initiator = ObjectUtil.isNull(jsonObj.get("initiator",FromData.class)) ? null : jsonObj.get("initiator",FromData.class).getValue();
...@@ -43,23 +43,25 @@ public class WorkOvertimeBusiness extends SpmkAssoBusiness { ...@@ -43,23 +43,25 @@ public class WorkOvertimeBusiness extends SpmkAssoBusiness {
String endTime = ObjectUtil.isNull(jsonObj.get("__endTime",FromData.class)) ? null : jsonObj.get("__endTime",FromData.class).getValue(); String endTime = ObjectUtil.isNull(jsonObj.get("__endTime",FromData.class)) ? null : jsonObj.get("__endTime",FromData.class).getValue();
// 时长 // 时长
String timeLong = ObjectUtil.isNull(jsonObj.get("__timeLong",FromData.class)) ? null : jsonObj.get("__timeLong",FromData.class).getValue(); String timeLong = ObjectUtil.isNull(jsonObj.get("__timeLong",FromData.class)) ? null : jsonObj.get("__timeLong",FromData.class).getValue();
// 加班补偿方式 // 加班补偿方式 -前端传中文
String compensate = ObjectUtil.isNull(jsonObj.get("__compensate",FromData.class)) ? null : jsonObj.get("__compensate",FromData.class).getValue(); String compensate = ObjectUtil.isNull(jsonObj.get("__compensate",FromData.class)) ? null : jsonObj.get("__compensate",FromData.class).getValue();
// 加班原因 // 加班原因
String OvertimeReason = ObjectUtil.isNull(jsonObj.get("__OvertimeReason",FromData.class)) ? null : jsonObj.get("__OvertimeReason",FromData.class).getValue(); String OvertimeReason = ObjectUtil.isNull(jsonObj.get("__OvertimeReason",FromData.class)) ? null : jsonObj.get("__OvertimeReason",FromData.class).getValue();
// 加班类型-前端未给 // 加班类型-前端未给
String overtimetype = ObjectUtil.isNull(jsonObj.get("__overtimetype",FromData.class)) ? null : jsonObj.get("__overtimetype",FromData.class).getValue(); String workOvertimeType = ObjectUtil.isNull(jsonObj.get("__workOvertimeType",FromData.class)) ? null : jsonObj.get("__workOvertimeType",FromData.class).getValue();
// 上传文件 // 上传文件
String UploadAttachment = ObjectUtil.isNull(jsonObj.get("UploadAttachment",FromData.class)) ? null : jsonObj.get("UploadAttachment",FromData.class).getValue(); String UploadAttachment = ObjectUtil.isNull(jsonObj.get("UploadAttachment",FromData.class)) ? null : jsonObj.get("UploadAttachment",FromData.class).getValue();
AttOvertimeApprovalDto oaD = AttOvertimeApprovalDto AttOvertimeApprovalDto oaD = AttOvertimeApprovalDto
.builder() .builder()
.userid(id)
.orgcode(orgCode)
.overtimeid(Convert.toInt(approveId)) .overtimeid(Convert.toInt(approveId))
.overtimetype(Convert.toInt(overtimetype)) .overtimetype(Convert.toInt(1))
.starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm:ss")) .starttime(DateUtil.getStringTime(startTime, "yyyy-MM-dd HH:mm"))
.endtime(DateUtil.getStringTime(endTime, "yyyy-MM-dd HH:mm:ss")) .endtime(DateUtil.getStringTime(endTime, "yyyy-MM-dd HH:mm"))
.duration(Convert.toDouble(timeLong)) .duration(Convert.toDouble(timeLong))
.compensate(Convert.toInt(compensate)) .compensate(Convert.toInt(1))
.build(); .build();
System.out.println("加班:"+oaD); System.out.println("加班:"+oaD);
......
...@@ -211,6 +211,7 @@ ...@@ -211,6 +211,7 @@
FROM yggl_main_emp a FROM yggl_main_emp a
<where> <where>
AND a.org_code = #{param.orgCode} AND a.org_code = #{param.orgCode}
AND a.job_status IN (0,1,2)
<if test="param.jobType != null"> <if test="param.jobType != null">
AND a.job_type = #{param.jobType} AND a.job_type = #{param.jobType}
</if> </if>
......
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