Commit ccf1ac48 by 江和松

生产入库逻辑功能提交,bug修改

parent 8cd3aec4
......@@ -73,7 +73,7 @@ public class ServiceHGKC003 extends ServiceBase {
* @return
*/
@OperationLogAnnotation(operModul = "生产入库单", operType = "保存", operDesc = "保存")
public EiInfo save(EiInfo inInfo) {
public EiInfo update(EiInfo inInfo) {
try {
List<Map> resultRows = inInfo.getBlock(EiConstant.resultBlock).getRows();
// 写入数据
......@@ -108,7 +108,7 @@ public class ServiceHGKC003 extends ServiceBase {
for(Long id : ids){
HGKC003 hgkc003 = HGKCTools.HgKc003.getId(id);
//修改计划生产任务完工数量
HGSCTools.complete(hgkc003.getQualityId(),hgkc003.getInvQty().negate().intValue(),hgkc003.getRectificationId());
HGSCTools.hgkc003Delete(hgkc003.getQualityId(),hgkc003.getInvQty().negate().intValue(),hgkc003.getRectificationId());
DaoUtils.update(HGKC003.BATCH_DELETE, new HashMap<String,Object>(){{put("ids",ids);}});
}
......
......@@ -168,6 +168,21 @@ public class HGSCTools {
DaoUtils.update(HGSC005A.UPDATE,hgsc005A);
}
public static void hgkc003Delete(Long checkId, Integer completeNum, Long rectificationId){
HGZL002 hgzl002 = HGZLTools.THGZL002.get(checkId);
if(Objects.nonNull(rectificationId) && rectificationId.intValue() != 0){
//更新整改通知单状态,工序质检单与整改通知单是2条入库单数据
HGZL004 hgzl004 = HGZLTools.THGZL004.get(rectificationId);
hgzl004.setHandleStatus(HandleStatusEnum.UNPROCESS.getCode());
DaoUtils.update(HGZL004.UPDATE,hgzl004);
}else{
//整改通知单id为空的入库单才是工序质检单生成的入库单。
//更新工序质检单状态
hgzl002.setCheckStatus(CheckStatusEnum.CHECKING.getCode());
DaoUtils.update(HGZL002.UPDATE,hgzl002);
}
}
public static class Hgsc001 {
public static HGSC001 queryByCode(String code) {
AssertUtils.isNull(code, "项目Code不能为空!");
......
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