|
|
@@ -290,7 +290,7 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
updateMake.setMa_statuscode(Status.AUDITED.name());
|
|
|
updateMake.setUpdateTime(new Date());
|
|
|
updateMake.setUpdaterId(BaseContextHolder.getUserId());
|
|
|
- updateMake.setMa_auditman("");
|
|
|
+ updateMake.setMa_auditman(BaseContextHolder.getUserName());
|
|
|
updateMake.setMa_auditdate(new Date());
|
|
|
getMapper().updateByPrimaryKeySelective(updateMake);
|
|
|
DocBaseDTO docBaseDTO = generateMsgObj(make.getId(), make.getMa_code());
|
|
|
@@ -316,7 +316,8 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
makeListDTO.setItems(makeMaterials);
|
|
|
singleAudit(makeListDTO);
|
|
|
} catch (Exception e){
|
|
|
- errorMsg.append("编号:" + base.getCode() + "处理失败," + e.getMessage());
|
|
|
+ String msg = BizExceptionCode.DEAL_FAILED.getMessage();
|
|
|
+ errorMsg.append(String.format(msg, base.getCode(), e.getMessage()));
|
|
|
}
|
|
|
}
|
|
|
return errorMsg.toString();
|
|
|
@@ -348,7 +349,8 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
prodInOut.setPi_auditman(""); //审核人
|
|
|
prodInOut.setPi_status(Status.UNAUDITED.getDisplay()); //单据状态
|
|
|
prodInOut.setPi_statuscode(Status.UNAUDITED.name()); //单据状态码
|
|
|
- prodInOut.setPi_text1(make.getMa_code()); //自定义字段1 赋值为制造单号
|
|
|
+ prodInOut.setPi_macode(make.getMa_code()); //制造单号
|
|
|
+ prodInOut.setPi_maid(make.getId()); //制造单ID
|
|
|
prodInOut.setCompanyId(BaseContextHolder.getCompanyId()); //公司ID
|
|
|
prodInOut.setCreateTime(new Date());
|
|
|
prodInOut.setCreatorId(BaseContextHolder.getUserId()); //创建人ID
|
|
|
@@ -408,7 +410,8 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
prodInOut.setPi_auditman(""); //审核人
|
|
|
prodInOut.setPi_status(Status.UNAUDITED.getDisplay()); //单据状态
|
|
|
prodInOut.setPi_statuscode(Status.UNAUDITED.name()); //单据状态码
|
|
|
- prodInOut.setPi_text1(make.getMa_code()); //自定义字段1 赋值为制造单号
|
|
|
+ prodInOut.setPi_macode(make.getMa_code()); //制造单号
|
|
|
+ prodInOut.setPi_maid(make.getId()); //制造单ID
|
|
|
prodInOut.setCompanyId(BaseContextHolder.getCompanyId()); //公司ID
|
|
|
prodInOut.setCreateTime(new Date());
|
|
|
prodInOut.setCreatorId(BaseContextHolder.getUserId()); //创建人ID
|
|
|
@@ -459,7 +462,8 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
prodInOut.setPi_auditman(""); //审核人
|
|
|
prodInOut.setPi_status(Status.UNAUDITED.getDisplay()); //单据状态
|
|
|
prodInOut.setPi_statuscode(Status.UNAUDITED.name()); //单据状态码
|
|
|
- prodInOut.setPi_text1(make.getMa_code()); //自定义字段1 赋值为制造单号
|
|
|
+ prodInOut.setPi_macode(make.getMa_code()); //制造单号
|
|
|
+ prodInOut.setPi_maid(make.getId()); //制造单ID
|
|
|
prodInOut.setCompanyId(BaseContextHolder.getCompanyId()); //公司ID
|
|
|
prodInOut.setCreateTime(new Date());
|
|
|
prodInOut.setCreatorId(BaseContextHolder.getUserId()); //创建人ID
|
|
|
@@ -517,7 +521,8 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
prodInOut.setPi_auditman(""); //审核人
|
|
|
prodInOut.setPi_status(Status.UNAUDITED.getDisplay()); //单据状态
|
|
|
prodInOut.setPi_statuscode(Status.UNAUDITED.name()); //单据状态码
|
|
|
- prodInOut.setPi_text1(make.getMa_code()); //自定义字段1 赋值为制造单号
|
|
|
+ prodInOut.setPi_macode(make.getMa_code()); //制造单号
|
|
|
+ prodInOut.setPi_maid(make.getId()); //制造单ID
|
|
|
prodInOut.setCompanyId(BaseContextHolder.getCompanyId()); //公司ID
|
|
|
prodInOut.setCreateTime(new Date());
|
|
|
prodInOut.setCreatorId(BaseContextHolder.getUserId()); //创建人ID
|
|
|
@@ -612,7 +617,8 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
Long id = base.getId();
|
|
|
singleUnAudit(id);
|
|
|
}catch (Exception e) {
|
|
|
- errorMsg.append("编号:" + base.getCode() + "处理失败," + e.getMessage());
|
|
|
+ String msg = BizExceptionCode.DEAL_FAILED.getMessage();
|
|
|
+ errorMsg.append(String.format(msg, base.getCode(), e.getMessage()));
|
|
|
}
|
|
|
}
|
|
|
return errorMsg.toString();
|
|
|
@@ -687,8 +693,9 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
if(!StringUtils.isEmpty(map.get("result"))){
|
|
|
throw new BizException(76203, map.get("result").toString());
|
|
|
}
|
|
|
- prodInOutMapper.deleteByInOutNo(inCode, "完工入库单", BaseContextHolder.getCompanyId());
|
|
|
prodIODetailMapper.deleteByInOutNo(inCode, "完工入库单", BaseContextHolder.getCompanyId());
|
|
|
+ prodInOutMapper.deleteByInOutNo(inCode, "完工入库单", BaseContextHolder.getCompanyId());
|
|
|
+
|
|
|
|
|
|
if ("拆件".equals(type)){
|
|
|
map.put("class", "拆件领料单");
|
|
|
@@ -703,11 +710,11 @@ public class MakeServiceImpl extends CommonBaseServiceImpl<MakeMapper, Make> imp
|
|
|
throw new BizException(76204, map.get("result").toString());
|
|
|
}
|
|
|
if ("拆件".equals(type)){
|
|
|
- prodInOutMapper.deleteByInOutNo(outCode, "拆件领料单", BaseContextHolder.getCompanyId());
|
|
|
prodIODetailMapper.deleteByInOutNo(outCode, "拆件领料单", BaseContextHolder.getCompanyId());
|
|
|
+ prodInOutMapper.deleteByInOutNo(outCode, "拆件领料单", BaseContextHolder.getCompanyId());
|
|
|
}else if ("组装".equals(type)){
|
|
|
- prodInOutMapper.deleteByInOutNo(outCode, "生产领料单", BaseContextHolder.getCompanyId());
|
|
|
prodIODetailMapper.deleteByInOutNo(outCode, "生产领料单", BaseContextHolder.getCompanyId());
|
|
|
+ prodInOutMapper.deleteByInOutNo(outCode, "生产领料单", BaseContextHolder.getCompanyId());
|
|
|
}
|
|
|
}
|
|
|
|