代码更新
This commit is contained in:
@@ -44,6 +44,9 @@
|
||||
PAGEQUERY
|
||||
SELECT
|
||||
ivt.*,
|
||||
attr.sect_id,
|
||||
attr.sect_code,
|
||||
attr.sect_name,
|
||||
point.point_code,
|
||||
point.point_name,
|
||||
mater.material_code,
|
||||
@@ -53,6 +56,7 @@
|
||||
FROM
|
||||
ST_IVT_StructIvt ivt
|
||||
LEFT JOIN sch_base_point point ON ivt.struct_id = point.source_id
|
||||
LEFT JOIN st_ivt_structattr attr ON ivt.struct_id = attr.struct_id
|
||||
LEFT JOIN md_me_materialbase mater ON mater.material_id = ivt.material_id
|
||||
LEFT JOIN md_pb_measureunit unit ON unit.measure_unit_id = ivt.qty_unit_id
|
||||
LEFT JOIN SCH_BASE_Region region ON region.region_id = ivt.region_id
|
||||
|
||||
@@ -241,6 +241,7 @@ public class BakingServiceImpl implements BakingService {
|
||||
String point_code1 = whereJson.getString("point_code");
|
||||
if (ObjectUtil.isEmpty(point_code1)) throw new BadRequestException("出箱点位不能为空");
|
||||
JSONObject jsonHotIvt = hosIvtTab.query("point_code = '" + point_code1 + "'").uniqueResult(0);
|
||||
if (ObjectUtil.isEmpty(jsonHotIvt)) throw new BadRequestException("点位不存在");
|
||||
|
||||
// 1.查询暂存位有没有空位
|
||||
String product_area = jsonHotIvt.getString("product_area");
|
||||
@@ -328,6 +329,7 @@ public class BakingServiceImpl implements BakingService {
|
||||
|
||||
// 1.获取此暂存位的生产区域和上下位置
|
||||
JSONObject jsonPoint = pointTab.query("point_code = '" + point_code1 + "'").uniqueResult(0);
|
||||
if (ObjectUtil.isEmpty(jsonPoint)) throw new BadRequestException("点位不存在");
|
||||
|
||||
// 2.找冷却区空货位
|
||||
JSONObject map = new JSONObject();
|
||||
|
||||
@@ -38,7 +38,7 @@ public class CoolInServiceImpl implements CoolInService {
|
||||
map.put("flag", "1");
|
||||
if (ObjectUtil.isNotEmpty(container_name)) map.put("container_name", "%"+container_name+"%");
|
||||
|
||||
JSONObject jsonObject = WQL.getWO("PDA_COOLIN").addParamMap(map).pageQuery(ctx, "der.container_name ASC");
|
||||
JSONObject jsonObject = WQL.getWO("PDA_COOLIN").addParamMap(map).pageQuery(ctx, "container_name");
|
||||
JSONArray resultJSONArray = WQL.getWO("PDA_COOLIN").addParamMap(map).process().getResultJSONArray(0);
|
||||
|
||||
JSONObject jo = new JSONObject();
|
||||
|
||||
@@ -65,7 +65,6 @@
|
||||
der.product_area AS product_area,
|
||||
der.update_time AS update_time,
|
||||
ivt.point_location,
|
||||
ivt.product_area,
|
||||
der.workorder_id
|
||||
FROM
|
||||
PDM_BI_RawFoilWorkOrder der
|
||||
|
||||
@@ -2,9 +2,11 @@
|
||||
package org.nl.wms.pdm.bi.service.impl;
|
||||
|
||||
|
||||
import cn.hutool.core.map.MapUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.wms.pdm.bi.service.SubpackagerelationService;
|
||||
import org.nl.wms.pdm.bi.service.dto.SubpackagerelationDto;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -37,9 +39,21 @@ public class SubpackagerelationServiceImpl implements SubpackagerelationService
|
||||
|
||||
@Override
|
||||
public Map<String,Object> queryAll(Map whereJson, Pageable page){
|
||||
WQLObject wo = WQLObject.getWQLObject("pdm_bi_subpackagerelation");
|
||||
ResultBean rb = wo.pagequery(WqlUtil.getHttpContext(page), "1=1", "package_box_sn desc");
|
||||
final JSONObject json = rb.pageResult();
|
||||
String material_code = MapUtil.getStr(whereJson, "material_code");
|
||||
String material_name = MapUtil.getStr(whereJson, "material_name");
|
||||
String sale_order_name = MapUtil.getStr(whereJson, "sale_order_name");
|
||||
String customer_name = MapUtil.getStr(whereJson, "customer_name");
|
||||
String customer_description = MapUtil.getStr(whereJson, "customer_description");
|
||||
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "1");
|
||||
if (ObjectUtil.isNotEmpty(material_code)) map.put("material_code","%"+material_code+"%");
|
||||
if (ObjectUtil.isNotEmpty(material_name)) map.put("material_name","%"+material_name+"%");
|
||||
if (ObjectUtil.isNotEmpty(sale_order_name)) map.put("sale_order_name","%"+sale_order_name+"%");
|
||||
if (ObjectUtil.isNotEmpty(customer_name)) map.put("customer_name","%"+customer_name+"%");
|
||||
if (ObjectUtil.isNotEmpty(customer_description)) map.put("customer_description","%"+customer_description+"%");
|
||||
|
||||
JSONObject json = WQL.getWO("PDM_BI_SUBPACKAGER01").addParamMap(map).pageQuery(WqlUtil.getHttpContext(page), "create_time DESC");
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,76 @@
|
||||
[交易说明]
|
||||
交易名: 子卷包装
|
||||
所属模块:
|
||||
功能简述:
|
||||
版权所有:
|
||||
表引用:
|
||||
版本经历:
|
||||
|
||||
[数据库]
|
||||
--指定数据库,为空采用默认值,默认为db.properties中列出的第一个库
|
||||
|
||||
[IO定义]
|
||||
#################################################
|
||||
## 表字段对应输入参数
|
||||
#################################################
|
||||
输入.flag TYPEAS s_string
|
||||
输入.material_code TYPEAS s_string
|
||||
输入.material_name TYPEAS s_string
|
||||
输入.sale_order_name TYPEAS s_string
|
||||
输入.customer_name TYPEAS s_string
|
||||
输入.customer_description TYPEAS s_string
|
||||
|
||||
|
||||
[临时表]
|
||||
--这边列出来的临时表就会在运行期动态创建
|
||||
|
||||
[临时变量]
|
||||
--所有中间过程变量均可在此处定义
|
||||
|
||||
[业务过程]
|
||||
|
||||
##########################################
|
||||
# 1、输入输出检查 #
|
||||
##########################################
|
||||
|
||||
|
||||
##########################################
|
||||
# 2、主过程前处理 #
|
||||
##########################################
|
||||
|
||||
|
||||
##########################################
|
||||
# 3、业务主过程 #
|
||||
##########################################
|
||||
IF 输入.flag = "1"
|
||||
PAGEQUERY
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
pdm_bi_subpackagerelation
|
||||
WHERE
|
||||
1=1
|
||||
|
||||
OPTION 输入.material_code <> ""
|
||||
product_name LIKE 输入.material_code
|
||||
ENDOPTION
|
||||
|
||||
OPTION 输入.material_name <> ""
|
||||
product_description LIKE 输入.material_name
|
||||
ENDOPTION
|
||||
|
||||
OPTION 输入.sale_order_name <> ""
|
||||
sale_order_name LIKE 输入.sale_order_name
|
||||
ENDOPTION
|
||||
|
||||
OPTION 输入.customer_name <> ""
|
||||
customer_name LIKE 输入.customer_name
|
||||
ENDOPTION
|
||||
|
||||
OPTION 输入.customer_description <> ""
|
||||
customer_description LIKE 输入.customer_description
|
||||
ENDOPTION
|
||||
|
||||
ENDSELECT
|
||||
ENDPAGEQUERY
|
||||
ENDIF
|
||||
@@ -82,6 +82,7 @@
|
||||
PAGEQUERY
|
||||
SELECT
|
||||
mst.bill_code,
|
||||
mst.container_name,
|
||||
dtl.start_point_code,
|
||||
dtl.next_point_code,
|
||||
dtl.temperature,
|
||||
|
||||
@@ -67,20 +67,9 @@
|
||||
IF 输入.flag = "1"
|
||||
PAGEQUERY
|
||||
SELECT
|
||||
ios.*,
|
||||
dis.num
|
||||
ios.*
|
||||
FROM
|
||||
ST_IVT_IOStorInv ios
|
||||
LEFT JOIN (
|
||||
SELECT
|
||||
count(d.struct_id) AS num,
|
||||
MAX(d.iostorinv_id) AS iostorinv_id
|
||||
FROM
|
||||
ST_IVT_IOStorInvDis d
|
||||
WHERE
|
||||
1=1
|
||||
group by d.struct_id
|
||||
) AS dis ON ios.iostorinv_id = dis.iostorinv_id
|
||||
WHERE
|
||||
io_type = '1'
|
||||
and ios.is_delete='0'
|
||||
|
||||
Reference in New Issue
Block a user