报废驳回进维修
This commit is contained in:
parent
ae7afcde25
commit
21656e0515
|
|
@ -515,32 +515,32 @@ public class ScrapApplyDetailsServiceImpl implements IScrapApplyDetailsService {
|
|||
backApplyInfo.setMaId(bean.getMaId().intValue());
|
||||
backApplyInfo.setTypeId(String.valueOf(bean.getTypeId()));
|
||||
backApplyInfo.setCompanyId(String.valueOf(bean.getCompanyId()));
|
||||
backApplyInfo.setRepairedNum(String.valueOf(bean.getScrapNum()));
|
||||
backApplyInfo.setCreateBy(SecurityUtils.getLoginUser().getUsername());
|
||||
backApplyInfo.setUpdateBy(SecurityUtils.getLoginUser().getUsername());
|
||||
backApplyInfo.setBackNum(bean.getScrapNum().intValue());
|
||||
backApplyInfo.setId(bean.getParentId());
|
||||
backApplyInfo.setCreateBy(String.valueOf(SecurityUtils.getLoginUser().getUserid()));
|
||||
backApplyInfo.setUpdateBy(String.valueOf(SecurityUtils.getLoginUser().getUserid()));
|
||||
wxList.add(backApplyInfo);
|
||||
}
|
||||
}
|
||||
if (backList.size() > 0) {
|
||||
if (backList.get(0).getCompanyId() != null) {
|
||||
companyId = Math.toIntExact(backList.get(0).getCompanyId());
|
||||
}
|
||||
if (backList.get(0).getParentId() != null) {
|
||||
parentId = Math.toIntExact(backList.get(0).getParentId());
|
||||
}
|
||||
|
||||
//维修的创建维修任务,插入任务协议表
|
||||
if (wxList != null && wxList.size() > 0) {
|
||||
BackApplyInfo backApplyInfo = scrapApplyDetailsMapper.getBackApplyInfo(parentId);
|
||||
wxList = wxList.stream().peek(obj -> obj.setBackId(backApplyInfo.getBackId())).collect(Collectors.toList());
|
||||
//插入任务表tm_task
|
||||
int newTaskId = backReceiveService.insertTt(wxList, TaskTypeEnum.MAINTENANCE_TASK.getCode(), SecurityUtils.getLoginUser().getUsername());
|
||||
//插入协议任务表tm_task_agreement
|
||||
backReceiveService.insertTta(newTaskId, wxList);
|
||||
//插入维修记录表repair_apply_details
|
||||
backReceiveService.insertRad(newTaskId, wxList);
|
||||
}
|
||||
//维修的创建维修任务,插入任务协议表
|
||||
if (wxList != null && wxList.size() > 0) {
|
||||
//插入任务表tm_task
|
||||
int newTaskId = backReceiveService.insertTt(wxList, TaskTypeEnum.MAINTENANCE_TASK.getCode(), SecurityUtils.getLoginUser().getUsername());
|
||||
//插入协议任务表tm_task_agreement
|
||||
backReceiveService.insertTta(newTaskId, wxList);
|
||||
//插入维修记录表repair_apply_details
|
||||
backReceiveService.insertRad(newTaskId, wxList);
|
||||
}
|
||||
|
||||
|
||||
// if (backList.size() > 0) {
|
||||
// if (backList.get(0).getCompanyId() != null) {
|
||||
// companyId = Math.toIntExact(backList.get(0).getCompanyId());
|
||||
// }
|
||||
// if (backList.get(0).getParentId() != null) {
|
||||
// parentId = Math.toIntExact(backList.get(0).getParentId());
|
||||
// }
|
||||
// taskCode = purchaseCodeRule("T", 36);
|
||||
// taskStatus = 38;
|
||||
// taskType = 36;
|
||||
|
|
@ -558,7 +558,9 @@ public class ScrapApplyDetailsServiceImpl implements IScrapApplyDetailsService {
|
|||
// bean.setUpdateBy(String.valueOf(SecurityUtils.getLoginUser().getUserid()));
|
||||
// scrapApplyDetailsMapper.addBackDetails(bean);
|
||||
// }
|
||||
}
|
||||
// }
|
||||
|
||||
|
||||
if (repairList.size() > 0) {
|
||||
if (repairList.get(0).getCompanyId() != null) {
|
||||
companyId = Math.toIntExact(repairList.get(0).getCompanyId());
|
||||
|
|
|
|||
Loading…
Reference in New Issue