Commit eada306d authored by 廖旭伟's avatar 廖旭伟

绩效核查确实时将核查时间改为绩效扣分发生时间

parent 76c4154f
...@@ -152,6 +152,10 @@ public class CheckAttendRecordServiceImpl extends AbstractCRUDServiceImpl<CheckA ...@@ -152,6 +152,10 @@ public class CheckAttendRecordServiceImpl extends AbstractCRUDServiceImpl<CheckA
if (entity.getId() == null) { if (entity.getId() == null) {
throw new AppException("核查记录ID不能为空"); throw new AppException("核查记录ID不能为空");
} }
CheckAttendRecordEntity temp = this.get(entity.getId());
if (temp == null) {
throw new AppException("核查记录ID不正确");
}
if (context != null && context.getUser() != null) { if (context != null && context.getUser() != null) {
IUser user = context.getUser(); IUser user = context.getUser();
entity.setUpdateUserId(user.getId()); entity.setUpdateUserId(user.getId());
...@@ -162,29 +166,26 @@ public class CheckAttendRecordServiceImpl extends AbstractCRUDServiceImpl<CheckA ...@@ -162,29 +166,26 @@ public class CheckAttendRecordServiceImpl extends AbstractCRUDServiceImpl<CheckA
AuditUtil.audit(entity); AuditUtil.audit(entity);
} }
entity.setCheckTime(new Date()); entity.setCheckTime(temp.getErrorTime());
entity.setUpdateTime(entity.getCheckTime()); entity.setUpdateTime(new Date());
entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理) entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理)
dao.update(entity); dao.update(entity);
try { try {
CheckAttendRecordEntity temp = this.get(entity.getId()); if (!ObjectUtils.isEmpty(entity.getRecordId())) {
if (temp != null) { PerformAttendRecordEntity performAttendRecordEntity = attendRecordService.get(entity.getRecordId());
if (!ObjectUtils.isEmpty(entity.getRecordId())) { if (!ObjectUtils.isEmpty(performAttendRecordEntity)) {
PerformAttendRecordEntity performAttendRecordEntity = attendRecordService.get(entity.getRecordId()); performAttendRecordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue());
if (!ObjectUtils.isEmpty(performAttendRecordEntity)) { performAttendRecordEntity.setUpdateTime(new Date());
performAttendRecordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue()); performAttendRecordEntity.setUpdateUserId(this.getContextUserId(context));
performAttendRecordEntity.setUpdateTime(new Date()); attendRecordService.update(performAttendRecordEntity);
performAttendRecordEntity.setUpdateUserId(this.getContextUserId(context));
attendRecordService.update(performAttendRecordEntity);
}
} }
}
/* AttendPostServiceThread attendPostServiceThread = new AttendPostServiceThread(entity); /* AttendPostServiceThread attendPostServiceThread = new AttendPostServiceThread(entity);
ThreadPool.getInstance().execute(attendPostServiceThread);*/ ThreadPool.getInstance().execute(attendPostServiceThread);*/
sendCheckDingTalk(temp); sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery(); StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId()); query.setStaffId(temp.getStaffId());
summaryCheck(query); summaryCheck(query);
}
} catch (Exception e) { } catch (Exception e) {
log.error("汇总已审核的核查记录出错", e); log.error("汇总已审核的核查记录出错", e);
} }
......
...@@ -150,6 +150,10 @@ public class CheckComplainRecordServiceImpl extends AbstractCRUDServiceImpl<Chec ...@@ -150,6 +150,10 @@ public class CheckComplainRecordServiceImpl extends AbstractCRUDServiceImpl<Chec
if (entity.getId() == null) { if (entity.getId() == null) {
throw new AppException("核查记录ID不能为空"); throw new AppException("核查记录ID不能为空");
} }
CheckComplainRecordEntity temp = this.get(entity.getId());
if (temp == null) {
throw new AppException("核查记录ID不正确");
}
if (context != null && context.getUser() != null) { if (context != null && context.getUser() != null) {
IUser user = context.getUser(); IUser user = context.getUser();
entity.setUpdateUserId(user.getId()); entity.setUpdateUserId(user.getId());
...@@ -158,27 +162,24 @@ public class CheckComplainRecordServiceImpl extends AbstractCRUDServiceImpl<Chec ...@@ -158,27 +162,24 @@ public class CheckComplainRecordServiceImpl extends AbstractCRUDServiceImpl<Chec
if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){ if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){
AuditUtil.audit(entity); AuditUtil.audit(entity);
} }
entity.setCheckTime(new Date()); entity.setCheckTime(temp.getComplainTime());
entity.setUpdateTime(entity.getCheckTime()); entity.setUpdateTime(new Date());
entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理) entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理)
dao.update(entity); dao.update(entity);
try { try {
CheckComplainRecordEntity temp = this.get(entity.getId()); if(!ObjectUtils.isEmpty(temp.getRecordId())){
if (temp != null) { PerformComplainRecordEntity recordEntity = recordService.get(temp.getRecordId());
if(!ObjectUtils.isEmpty(temp.getRecordId())){ if(!ObjectUtils.isEmpty(recordEntity)){
PerformComplainRecordEntity recordEntity = recordService.get(temp.getRecordId()); recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue());
if(!ObjectUtils.isEmpty(recordEntity)){ recordEntity.setUpdateTime(new Date());
recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue()); recordEntity.setUpdateUserId(this.getContextUserId(context));
recordEntity.setUpdateTime(new Date()); recordService.update(recordEntity);
recordEntity.setUpdateUserId(this.getContextUserId(context));
recordService.update(recordEntity);
}
} }
sendCheckDingTalk(entity);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} }
sendCheckDingTalk(entity);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} catch (Exception e) { } catch (Exception e) {
log.error("汇总已审核的核查记录出错", e); log.error("汇总已审核的核查记录出错", e);
} }
......
...@@ -150,6 +150,10 @@ public class CheckEffectRecordServiceImpl extends AbstractCRUDServiceImpl<CheckE ...@@ -150,6 +150,10 @@ public class CheckEffectRecordServiceImpl extends AbstractCRUDServiceImpl<CheckE
if(entity.getId()==null){ if(entity.getId()==null){
throw new AppException("核查记录ID不能为空"); throw new AppException("核查记录ID不能为空");
} }
CheckEffectRecordEntity temp = this.get(entity.getId());
if (temp == null) {
throw new AppException("核查记录ID不正确");
}
if (context != null && context.getUser()!=null) { if (context != null && context.getUser()!=null) {
IUser user = context.getUser(); IUser user = context.getUser();
entity.setUpdateUserId(user.getId()); entity.setUpdateUserId(user.getId());
...@@ -158,28 +162,25 @@ public class CheckEffectRecordServiceImpl extends AbstractCRUDServiceImpl<CheckE ...@@ -158,28 +162,25 @@ public class CheckEffectRecordServiceImpl extends AbstractCRUDServiceImpl<CheckE
if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){ if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){
AuditUtil.audit(entity); AuditUtil.audit(entity);
} }
entity.setCheckTime(new Date()); entity.setCheckTime(temp.getHappenTime());
entity.setUpdateTime(entity.getCheckTime()); entity.setUpdateTime(new Date());
entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理) entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理)
dao.update(entity); dao.update(entity);
try{ try{
CheckEffectRecordEntity temp = this.get(entity.getId()); if(!ObjectUtils.isEmpty(temp.getRecordId())){
if(temp!=null) { PerformEffectRecordEntity recordEntity = recordService.get(temp.getRecordId());
if(!ObjectUtils.isEmpty(temp.getRecordId())){ if(!ObjectUtils.isEmpty(recordEntity)){
PerformEffectRecordEntity recordEntity = recordService.get(temp.getRecordId()); recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue());
if(!ObjectUtils.isEmpty(recordEntity)){ recordEntity.setUpdateTime(new Date());
recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue()); recordEntity.setUpdateUserId(this.getContextUserId(context));
recordEntity.setUpdateTime(new Date()); recordService.update(recordEntity);
recordEntity.setUpdateUserId(this.getContextUserId(context));
recordService.update(recordEntity);
}
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
}catch (Exception e){ }catch (Exception e){
log.error("汇总已审核的核查记录出错",e); log.error("汇总已审核的核查记录出错",e);
} }
......
...@@ -147,6 +147,10 @@ public class CheckGoworkRecordServiceImpl extends AbstractCRUDServiceImpl<CheckG ...@@ -147,6 +147,10 @@ public class CheckGoworkRecordServiceImpl extends AbstractCRUDServiceImpl<CheckG
if(entity.getId()==null){ if(entity.getId()==null){
throw new AppException("核查记录ID不能为空"); throw new AppException("核查记录ID不能为空");
} }
CheckGoworkRecordEntity temp = this.get(entity.getId());
if (temp == null) {
throw new AppException("核查记录ID不正确");
}
if (context != null && context.getUser()!=null) { if (context != null && context.getUser()!=null) {
IUser user = context.getUser(); IUser user = context.getUser();
entity.setUpdateUserId(user.getId()); entity.setUpdateUserId(user.getId());
...@@ -155,28 +159,25 @@ public class CheckGoworkRecordServiceImpl extends AbstractCRUDServiceImpl<CheckG ...@@ -155,28 +159,25 @@ public class CheckGoworkRecordServiceImpl extends AbstractCRUDServiceImpl<CheckG
if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){ if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){
AuditUtil.audit(entity); AuditUtil.audit(entity);
} }
entity.setCheckTime(new Date()); entity.setCheckTime(temp.getGoworkTime());
entity.setUpdateTime(entity.getCheckTime()); entity.setUpdateTime(new Date());
entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理) entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理)
dao.update(entity); dao.update(entity);
//发送钉钉通知信息 //发送钉钉通知信息
try{ try{
CheckGoworkRecordEntity temp = this.get(entity.getId()); if(!ObjectUtils.isEmpty(temp.getRecordId())){
if(temp!=null) { PerformGoworkRecordEntity recordEntity = recordService.get(temp.getRecordId());
if(!ObjectUtils.isEmpty(temp.getRecordId())){ if(!ObjectUtils.isEmpty(recordEntity)){
PerformGoworkRecordEntity recordEntity = recordService.get(temp.getRecordId()); recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue());
if(!ObjectUtils.isEmpty(recordEntity)){ recordEntity.setUpdateTime(new Date());
recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue()); recordEntity.setUpdateUserId(this.getContextUserId(context));
recordEntity.setUpdateTime(new Date()); recordService.update(recordEntity);
recordEntity.setUpdateUserId(this.getContextUserId(context));
recordService.update(recordEntity);
}
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
}catch (Exception e){ }catch (Exception e){
log.error("汇总已审核的核查记录出错",e); log.error("汇总已审核的核查记录出错",e);
} }
......
...@@ -152,6 +152,10 @@ public class CheckOtherRecordServiceImpl extends AbstractCRUDServiceImpl<CheckOt ...@@ -152,6 +152,10 @@ public class CheckOtherRecordServiceImpl extends AbstractCRUDServiceImpl<CheckOt
if (entity.getId() == null) { if (entity.getId() == null) {
throw new AppException("核查记录ID不能为空"); throw new AppException("核查记录ID不能为空");
} }
CheckOtherRecordEntity temp = this.get(entity.getId());
if (temp == null) {
throw new AppException("核查记录ID不正确");
}
if (context != null && context.getUser() != null) { if (context != null && context.getUser() != null) {
IUser user = context.getUser(); IUser user = context.getUser();
entity.setUpdateUserId(user.getId()); entity.setUpdateUserId(user.getId());
...@@ -160,28 +164,26 @@ public class CheckOtherRecordServiceImpl extends AbstractCRUDServiceImpl<CheckOt ...@@ -160,28 +164,26 @@ public class CheckOtherRecordServiceImpl extends AbstractCRUDServiceImpl<CheckOt
if (!ObjectUtils.isEmpty(entity.getSubAddType()) && !ObjectUtils.isEmpty(entity.getCheckResult())) { if (!ObjectUtils.isEmpty(entity.getSubAddType()) && !ObjectUtils.isEmpty(entity.getCheckResult())) {
AuditUtil.audit(entity); AuditUtil.audit(entity);
} }
entity.setCheckTime(new Date());
entity.setUpdateTime(entity.getCheckTime()); entity.setCheckTime(temp.getHappenTime());
entity.setUpdateTime(new Date());
entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理) entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理)
dao.update(entity); dao.update(entity);
//发送钉钉通知信息 //发送钉钉通知信息
try { try {
CheckOtherRecordEntity temp = this.get(entity.getId()); if (!ObjectUtils.isEmpty(temp.getRecordId())) {
if (temp != null) { PerformOtherRecordEntity recordEntity = recordService.get(temp.getRecordId());
if (!ObjectUtils.isEmpty(temp.getRecordId())) { if (!ObjectUtils.isEmpty(recordEntity)) {
PerformOtherRecordEntity recordEntity = recordService.get(temp.getRecordId()); recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue());
if (!ObjectUtils.isEmpty(recordEntity)) { recordEntity.setUpdateTime(new Date());
recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue()); recordEntity.setUpdateUserId(this.getContextUserId(context));
recordEntity.setUpdateTime(new Date()); recordService.update(recordEntity);
recordEntity.setUpdateUserId(this.getContextUserId(context));
recordService.update(recordEntity);
}
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} catch (Exception e) { } catch (Exception e) {
log.error("汇总已审核的核查记录出错", e); log.error("汇总已审核的核查记录出错", e);
......
...@@ -152,6 +152,10 @@ public class CheckReviewRecordServiceImpl extends AbstractCRUDServiceImpl<CheckR ...@@ -152,6 +152,10 @@ public class CheckReviewRecordServiceImpl extends AbstractCRUDServiceImpl<CheckR
if (entity.getId() == null) { if (entity.getId() == null) {
throw new AppException("核查记录ID不能为空"); throw new AppException("核查记录ID不能为空");
} }
CheckReviewRecordEntity temp = this.get(entity.getId());
if (temp == null) {
throw new AppException("核查记录ID不正确");
}
if (context != null && context.getUser() != null) { if (context != null && context.getUser() != null) {
IUser user = context.getUser(); IUser user = context.getUser();
entity.setUpdateUserId(user.getId()); entity.setUpdateUserId(user.getId());
...@@ -160,28 +164,25 @@ public class CheckReviewRecordServiceImpl extends AbstractCRUDServiceImpl<CheckR ...@@ -160,28 +164,25 @@ public class CheckReviewRecordServiceImpl extends AbstractCRUDServiceImpl<CheckR
if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){ if(!ObjectUtils.isEmpty(entity.getSubAddType())&&!ObjectUtils.isEmpty(entity.getCheckResult())){
AuditUtil.audit(entity); AuditUtil.audit(entity);
} }
entity.setCheckTime(new Date()); entity.setCheckTime(temp.getReviewTime());
entity.setUpdateTime(entity.getCheckTime()); entity.setUpdateTime(new Date());
entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理) entity.setCheckStatus(CheckStatusEnum.已处理.getValue()); //处理状态(1.未处理,2.已处理)
dao.update(entity); dao.update(entity);
//发送钉钉通知信息 //发送钉钉通知信息
try { try {
CheckReviewRecordEntity temp = this.get(entity.getId()); if(!ObjectUtils.isEmpty(temp.getRecordId())){
if (temp != null) { PerformReviewRecordEntity recordEntity = recordService.get(temp.getRecordId());
if(!ObjectUtils.isEmpty(temp.getRecordId())){ if(!ObjectUtils.isEmpty(recordEntity)){
PerformReviewRecordEntity recordEntity = recordService.get(temp.getRecordId()); recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue());
if(!ObjectUtils.isEmpty(recordEntity)){ recordEntity.setUpdateTime(new Date());
recordEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue()); recordEntity.setUpdateUserId(this.getContextUserId(context));
recordEntity.setUpdateTime(new Date()); recordService.update(recordEntity);
recordEntity.setUpdateUserId(this.getContextUserId(context));
recordService.update(recordEntity);
}
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} }
sendCheckDingTalk(temp);
StaffCheckSummaryQuery query = new StaffCheckSummaryQuery();
query.setStaffId(temp.getStaffId());
summaryCheck(query);
} catch (Exception e) { } catch (Exception e) {
log.error("汇总已审核的核查记录出错", e); log.error("汇总已审核的核查记录出错", e);
} }
......
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