Jelajahi Sumber

微浦MES,SMT 获取未上料前20条数据,增加返回字段psl_prodcode 物料编号

xiaost 1 bulan lalu
induk
melakukan
802e35fd54
1 mengubah file dengan 4 tambahan dan 4 penghapusan
  1. 4 4
      src/com/uas/mes/pda/service/impl/PdaSMTServiceImpl.java

+ 4 - 4
src/com/uas/mes/pda/service/impl/PdaSMTServiceImpl.java

@@ -400,10 +400,10 @@ public class PdaSMTServiceImpl implements PdaSMTService {
 		mapR.put("DSL_REMAINQTY", bar_remain);
 		mapR.put("DSL_FESPEC", rs.getString("psl_feeder"));
 
-		rs=baseDao.queryForRowSet("select * from (select psl_location from(select min(psl_detno)psl_detno,psl_location||'|'||PSL_PRODCODE  psl_location from productsmtlocation "
+		rs=baseDao.queryForRowSet("select * from (select psl_location,psl_prodcode from (select min(psl_detno)psl_detno,psl_location,PSL_PRODCODE from productsmtlocation "
 				+" where psl_psid=? and psl_table=? and  psl_location not in (select distinct dsl_location from devsmtlocation where "
 				+" dsl_linecode=? and dsl_makecode=? and dsl_table=?  and dsl_status=0) "
-				+" group by psl_location||'|'||PSL_PRODCODE  order by psl_detno)) where rownum<=20 ",ps_id,map.get("DL_TABLE"),linecode,dl_macode,map.get("DL_TABLE"));
+				+" group by psl_location,PSL_PRODCODE ) order by psl_detno ) where rownum<=20 ",ps_id,map.get("DL_TABLE"),linecode,dl_macode,map.get("DL_TABLE"));
 		if(rs.next()){
 			mapR.put("NotFeedLocation", rs.getResultList());
 		}else{
@@ -1738,10 +1738,10 @@ public class PdaSMTServiceImpl implements PdaSMTService {
 				ps_prodcode = rs.getString("dl_prodcode");
 			}
 			//未上料站位前二十条
-			rs=baseDao.queryForRowSet("select * from (select psl_location from(select min(psl_detno)psl_detno,psl_location||'|'||PSL_PRODCODE  psl_location from productsmtlocation left join productsmt on ps_id = psl_psid"
+			rs=baseDao.queryForRowSet("select * from (select psl_location,psl_prodcode from(select min(psl_detno)psl_detno,psl_location,PSL_PRODCODE from productsmtlocation left join productsmt on ps_id = psl_psid"
 					+" where ps_linecode=? and ps_prodcode = ? and psl_table=? and  psl_location not in (select distinct dsl_location from devsmtlocation where "
 					+" dsl_linecode=? and dsl_makecode=? and dsl_table=?  and dsl_status=0) "
-					+" group by psl_location||'|'||PSL_PRODCODE order by psl_detno asc)) where rownum<=20 ",StringUtil.hasText(mainline)?mainline:linecode,ps_prodcode,table,linecode,macode,table);
+					+" group by psl_location,psl_prodcode) order by psl_detno asc) where rownum<=20 ",StringUtil.hasText(mainline)?mainline:linecode,ps_prodcode,table,linecode,macode,table);
 				if(rs.next()){
 					mapR.put("NotFeedLocation", rs.getResultList());
 				}else{