dev:设备禁用不影响和MES进行接口对接,只影响AGV运行
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
package org.nl.modules.wql.core.engine.syntax;
|
package org.nl.modules.wql.core.engine.syntax;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.nl.modules.wql.WQLCore;
|
import org.nl.modules.wql.WQLCore;
|
||||||
import org.nl.modules.wql.core.DataType;
|
import org.nl.modules.wql.core.DataType;
|
||||||
@@ -370,10 +371,15 @@ public class wqlSELECT extends IWQL {
|
|||||||
//2.2、对分页进行处理
|
//2.2、对分页进行处理
|
||||||
Set keySettTempTable = WQLCore.tempTableMap.keySet();
|
Set keySettTempTable = WQLCore.tempTableMap.keySet();
|
||||||
if (this.isInQuery && this.isPageQuery) {
|
if (this.isInQuery && this.isPageQuery) {
|
||||||
if ((wo.wp.PAGE_PAGESTART != -99 && wo.wp.PAGE_PAGERECORDNUM != -99) && (wo.wp.SORT_ORDERBYFIELD.length() > 0)) {
|
if ((wo.wp.PAGE_PAGESTART != -99 && wo.wp.PAGE_PAGERECORDNUM != -99) ) {
|
||||||
// String sqlTmp = "select * from("+wo.wp.sSQL+") TOTALRECORDVIEW order by " + wo.wp.SORT_ORDERBYFIELD + " limit "+wo.wp.PAGE_PAGESTART+","+wo.wp.PAGE_PAGERECORDNUM;
|
// String sqlTmp = "select * from("+wo.wp.sSQL+") TOTALRECORDVIEW order by " + wo.wp.SORT_ORDERBYFIELD + " limit "+wo.wp.PAGE_PAGESTART+","+wo.wp.PAGE_PAGERECORDNUM;
|
||||||
String sqlTmp = wo.wp.sSQL + " order by " + wo.wp.SORT_ORDERBYFIELD + " limit " + wo.wp.PAGE_PAGESTART + "," + wo.wp.PAGE_PAGERECORDNUM;
|
String sqlTmp = wo.wp.sSQL + " order by " + wo.wp.SORT_ORDERBYFIELD + " limit " + wo.wp.PAGE_PAGESTART + "," + wo.wp.PAGE_PAGERECORDNUM;
|
||||||
|
|
||||||
|
if (StrUtil.isEmpty(wo.wp.SORT_ORDERBYFIELD)){
|
||||||
|
sqlTmp = wo.wp.sSQL + " limit " + wo.wp.PAGE_PAGESTART + "," + wo.wp.PAGE_PAGERECORDNUM;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
// String sqlTmp = "select * from (select PAGE_SRCRESULTSET_1.*, row_number() over(order by " + wo.wp.SORT_ORDERBYFIELD + ")"
|
// String sqlTmp = "select * from (select PAGE_SRCRESULTSET_1.*, row_number() over(order by " + wo.wp.SORT_ORDERBYFIELD + ")"
|
||||||
// + " as SORT_INDEXFIELDALIAS from ( "
|
// + " as SORT_INDEXFIELDALIAS from ( "
|
||||||
// + wo.wp.sSQL
|
// + wo.wp.sSQL
|
||||||
@@ -406,7 +412,7 @@ public class wqlSELECT extends IWQL {
|
|||||||
log.error("关闭st,rs出错" + e.toString());
|
log.error("关闭st,rs出错" + e.toString());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (wo.wp.SORT_ORDERBYFIELD.length() > 0) {
|
if (this.isPageQuery) {
|
||||||
//对sql进行特殊处理,找出和第一个select配对的from,并把中间全部换为1
|
//对sql进行特殊处理,找出和第一个select配对的from,并把中间全部换为1
|
||||||
// String page_sql = change_1(wo.wp.sSQL);
|
// String page_sql = change_1(wo.wp.sSQL);
|
||||||
String page_sql = wo.wp.sSQL;
|
String page_sql = wo.wp.sSQL;
|
||||||
|
|||||||
@@ -96,7 +96,11 @@ public class BakingServiceImpl implements BakingService {
|
|||||||
throw new BadRequestException("未查询到母卷号:" + container_name + "对应的生箔机台编号!");
|
throw new BadRequestException("未查询到母卷号:" + container_name + "对应的生箔机台编号!");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (StrUtil.equals("1", sb_jo.getString("is_used")) && !raw_jo.getString("is_baking").equals("1")) {
|
/*if (StrUtil.equals("1", sb_jo.getString("is_used")) && !raw_jo.getString("is_baking").equals("1")) {
|
||||||
|
throw new BadRequestException("该母卷在MES上未进行决策入烘箱,不允许进行入烘箱操作!");
|
||||||
|
}*/
|
||||||
|
|
||||||
|
if (!raw_jo.getString("is_baking").equals("1")) {
|
||||||
throw new BadRequestException("该母卷在MES上未进行决策入烘箱,不允许进行入烘箱操作!");
|
throw new BadRequestException("该母卷在MES上未进行决策入烘箱,不允许进行入烘箱操作!");
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -468,7 +472,11 @@ public class BakingServiceImpl implements BakingService {
|
|||||||
throw new BadRequestException("未查询到母卷号:" + container_name + "对应的生箔机台编号!");
|
throw new BadRequestException("未查询到母卷号:" + container_name + "对应的生箔机台编号!");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (StrUtil.equals("1", sb_jo.getString("is_used")) && !raw_jo.getString("is_instor").equals("1")) {
|
/*if (StrUtil.equals("1", sb_jo.getString("is_used")) && !raw_jo.getString("is_instor").equals("1")) {
|
||||||
|
throw new BadRequestException("该母卷在MES上未进行决策入半成品库,不允许进行入冷却操作!");
|
||||||
|
}*/
|
||||||
|
|
||||||
|
if (!raw_jo.getString("is_instor").equals("1")) {
|
||||||
throw new BadRequestException("该母卷在MES上未进行决策入半成品库,不允许进行入冷却操作!");
|
throw new BadRequestException("该母卷在MES上未进行决策入半成品库,不允许进行入冷却操作!");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -158,9 +158,9 @@ public class RawFoilServiceImpl implements RawFoilService {
|
|||||||
JSONObject jsonSb = sbTab.query("ext_code = '" + jsonRaw.getString("resource_name") + "'").uniqueResult(0);
|
JSONObject jsonSb = sbTab.query("ext_code = '" + jsonRaw.getString("resource_name") + "'").uniqueResult(0);
|
||||||
if (ObjectUtil.isEmpty(jsonSb)) throw new BadRequestException("点位:"+jsonRaw.getString("resource_name")+"生箔设备不存在");
|
if (ObjectUtil.isEmpty(jsonSb)) throw new BadRequestException("点位:"+jsonRaw.getString("resource_name")+"生箔设备不存在");
|
||||||
|
|
||||||
/*if (StrUtil.equals("0", jsonSb.getString("is_used"))) {
|
if (StrUtil.equals("0", jsonSb.getString("is_used"))) {
|
||||||
throw new BadRequestException("当前生箔机:"+jsonSb.getString("ext_code")+"未启用!");
|
throw new BadRequestException("当前生箔机:"+jsonSb.getString("ext_code")+"未启用!");
|
||||||
}*/
|
}
|
||||||
|
|
||||||
String start_pint_code = "";
|
String start_pint_code = "";
|
||||||
String point_code4 = "";
|
String point_code4 = "";
|
||||||
@@ -216,9 +216,9 @@ public class RawFoilServiceImpl implements RawFoilService {
|
|||||||
throw new BadRequestException("未查到相关的生箔机点位!");
|
throw new BadRequestException("未查到相关的生箔机点位!");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*if (StrUtil.equals("0", raw_jo.getString("is_used"))) {
|
if (StrUtil.equals("0", raw_jo.getString("is_used"))) {
|
||||||
throw new BadRequestException("当前生箔机:"+raw_jo.getString("ext_code")+"未启用!");
|
throw new BadRequestException("当前生箔机:"+raw_jo.getString("ext_code")+"未启用!");
|
||||||
}*/
|
}
|
||||||
|
|
||||||
// 2.根据就近原则查对应空卷抽
|
// 2.根据就近原则查对应空卷抽
|
||||||
JSONObject map = new JSONObject();
|
JSONObject map = new JSONObject();
|
||||||
|
|||||||
Reference in New Issue
Block a user