소스 검색

Merge remote-tracking branch 'origin/mes_malata_prod' into mes_malata_prod

wuyx 6 년 전
부모
커밋
0783cf536b
1개의 변경된 파일6개의 추가작업 그리고 0개의 파일을 삭제
  1. 6 0
      src/com/uas/mes/common/service/impl/CommonSeriveImpl.java

+ 6 - 0
src/com/uas/mes/common/service/impl/CommonSeriveImpl.java

@@ -39,6 +39,12 @@ public class CommonSeriveImpl implements CommonService {
 		Map<Object, Object> store = FlexJsonUtil.fromJson(formStore);
 		// 执行保存前的其它逻辑
 		handlerService.beforeSave(caller, new Object[] { store });
+		if(caller.equals("SNProblemColl")){
+		 	Object sn=	store.get("spc_sncode");
+		 	if(!baseDao.checkIf("Makeserial","ms_sncode='"+sn.toString()+"'")){
+		 		BaseUtil.showError("SN"+sn.toString()+"不存在");
+			}
+		}
 		// 保存form
 		Object[] objs = baseDao.getFieldsDataByCondition("form", new String[] { "fo_table", "fo_keyfield", "fo_detailmainkeyfield" },
 				"fo_caller='" + caller + "'");// 先根据caller拿到对应table和主键