|
@@ -1681,10 +1681,17 @@ public class MESHelperServiceImpl implements MESHelperService {
|
|
|
return rmap;
|
|
|
}
|
|
|
int mb_id = baseDao.getSeqId("makebad_seq");
|
|
|
+ String badlocation = null;
|
|
|
+ try {
|
|
|
+ badlocation = BadCode[i].split(";")[1];
|
|
|
+ }catch (Exception ex)
|
|
|
+ {
|
|
|
+ badlocation = "";
|
|
|
+ }
|
|
|
sql.setLength(0);
|
|
|
sql.append("insert into makebad(mb_id,mb_makecode,mb_mscode,mb_sncode,mb_inman,mb_indate,mb_stepcode");
|
|
|
sql.append(",mb_sourcecode,mb_badremark,mb_badcode,mb_badtable,mb_bgcode,mb_soncode,mb_status) select '" + mb_id + "'");
|
|
|
- sql.append(",ma_code,ms_code,ms_sncode,'" + iUserCode + "',sysdate,'" + CurrentStep + "','" + iSourceCode + "','"+BadCode[i].split(";")[1]+"','" + BadCode[i].split(";")[0] + "','',");
|
|
|
+ sql.append(",ma_code,ms_code,ms_sncode,'" + iUserCode + "',sysdate,'" + CurrentStep + "','" + iSourceCode + "','"+badlocation+"','" + BadCode[i].split(";")[0] + "','',");
|
|
|
sql.append("'" + BgCode + "',sp_soncode,'0' from make left join makeSerial on ms_makecode=ma_code left join stepProduct on ");
|
|
|
sql.append("sp_mothercode=ma_prodcode and sp_stepcode=ms_nextstepcode where ms_sncode='" + iSN + "' and ms_makecode='" + iMakeCode + "'");
|
|
|
baseDao.execute(sql.toString());
|