|
@@ -1,6 +1,5 @@
|
|
package com.platform.service.repair.strategy.impl;
|
|
package com.platform.service.repair.strategy.impl;
|
|
|
|
|
|
-import com.alibaba.fastjson.JSONArray;
|
|
|
|
import com.platform.common.cache.ConfigCache;
|
|
import com.platform.common.cache.ConfigCache;
|
|
import com.platform.common.constant.CommonConstants;
|
|
import com.platform.common.constant.CommonConstants;
|
|
import com.platform.common.exception.DeniedException;
|
|
import com.platform.common.exception.DeniedException;
|
|
@@ -29,9 +28,7 @@ import tk.mybatis.mapper.weekend.Weekend;
|
|
import tk.mybatis.mapper.weekend.WeekendCriteria;
|
|
import tk.mybatis.mapper.weekend.WeekendCriteria;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
import javax.annotation.Resource;
|
|
-import java.time.DayOfWeek;
|
|
|
|
import java.time.LocalDateTime;
|
|
import java.time.LocalDateTime;
|
|
-import java.time.temporal.TemporalField;
|
|
|
|
import java.util.HashMap;
|
|
import java.util.HashMap;
|
|
import java.util.List;
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
import java.util.Map;
|
|
@@ -623,11 +620,6 @@ public class LongYanRepairStrategy extends AbstractRepairBaseStrategy {
|
|
|
|
|
|
}
|
|
}
|
|
|
|
|
|
- @Override
|
|
|
|
- public void nonPlanTransferToPlan(RepairApplicationFormDTO model) {
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
@Override
|
|
@Override
|
|
public void recoverRepair(RepairApplicationFormDTO model) {
|
|
public void recoverRepair(RepairApplicationFormDTO model) {
|
|
// 判断是否具有权限
|
|
// 判断是否具有权限
|
|
@@ -675,6 +667,9 @@ public class LongYanRepairStrategy extends AbstractRepairBaseStrategy {
|
|
updForm.setId(form.getId());
|
|
updForm.setId(form.getId());
|
|
updForm.setProduceVerifyUserId(model.getProduceVerifyUserId());
|
|
updForm.setProduceVerifyUserId(model.getProduceVerifyUserId());
|
|
updForm.setStatus(RepairApplicationFormStatusEnum.BIG_REPAIR_VERIFYING.getValue());
|
|
updForm.setStatus(RepairApplicationFormStatusEnum.BIG_REPAIR_VERIFYING.getValue());
|
|
|
|
+ if(StringUtils.isBlank(form.getDispatchUserId())){
|
|
|
|
+ updForm.setDispatchUserId(SecurityUtils.getUserInfo().getUserId());
|
|
|
|
+ }
|
|
repairApplicationFormMapper.updateByPrimaryKeySelective(updForm);
|
|
repairApplicationFormMapper.updateByPrimaryKeySelective(updForm);
|
|
// 通知生产审核
|
|
// 通知生产审核
|
|
List<SysUser> users = ListUtils.newArrayList();
|
|
List<SysUser> users = ListUtils.newArrayList();
|
|
@@ -683,6 +678,29 @@ public class LongYanRepairStrategy extends AbstractRepairBaseStrategy {
|
|
sendMessageToProducer(model,CommonConstants.SB_APPLY_BIG_REPAIR,users);
|
|
sendMessageToProducer(model,CommonConstants.SB_APPLY_BIG_REPAIR,users);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ @Override
|
|
|
|
+ public void verifyBigRepair(RepairApplicationFormDTO model) {
|
|
|
|
+ RepairApplicationForm form = repairApplicationFormMapper.selectByPrimaryKey(model.getId());
|
|
|
|
+ if(StringUtils.isBlank(form.getDispatchUserId())){
|
|
|
|
+ throw new DeniedException("所属工程师不能为空");
|
|
|
|
+ }
|
|
|
|
+ RepairApplicationForm updForm = new RepairApplicationForm();
|
|
|
|
+ updForm.setId(form.getId());
|
|
|
|
+ updForm.setStatus(RepairApplicationFormStatusEnum.RECEIVED.getValue());
|
|
|
|
+ String type = CommonConstants.CALL_REPAIR_FAIL;
|
|
|
|
+ if(model.getVerifyStatus() == CommonConstants.STATUS_VERIFY_PASS){
|
|
|
|
+ // 同意转大修,将工作优先权修改为转大修
|
|
|
|
+ updForm.setLevel(RepairApplicationFormLevelEnum.MRO.getValue());
|
|
|
|
+ type = CommonConstants.CALL_REPAIR_FINISH;
|
|
|
|
+ }
|
|
|
|
+ // 审核记录
|
|
|
|
+ addRepairVerifyRecord(model,model.getVerifyStatus(),CommonConstants.TYPE_MOR_VERIFY);
|
|
|
|
+ // 通知工程师
|
|
|
|
+ List<SysUserVO> users = ListUtils.newArrayList();
|
|
|
|
+ users.add(sysUserService.selectUserVO(form.getDispatchUserId()));
|
|
|
|
+ sendMessageToRepairManger(form,users,type);
|
|
|
|
+ }
|
|
|
|
+
|
|
/**
|
|
/**
|
|
* 维修人提交维修完成
|
|
* 维修人提交维修完成
|
|
* @param dto
|
|
* @param dto
|