mirror of
http://192.168.1.205:9980/cf_devdept2/cf_imes_server.git
synced 2026-08-12 21:02:08 +08:00
贴皮分解获取板件列表、贴皮管理获取贴皮列表 订单/板材维度合为一个入口
This commit is contained in:
+1
@@ -217,6 +217,7 @@ public class ErrorCodeConstants {
|
|||||||
public static final ErrorCode VENEER_DECOMPOSE_GOODS_IDS_REQUIRED = new ErrorCode(1_003_009_054, "veneer.decompose.goods.ids.required");
|
public static final ErrorCode VENEER_DECOMPOSE_GOODS_IDS_REQUIRED = new ErrorCode(1_003_009_054, "veneer.decompose.goods.ids.required");
|
||||||
public static final ErrorCode ORDER_VENEER_GOODS_CREATE_FAILED = new ErrorCode(1_003_009_055, "order.veneer.goods.create.failed");
|
public static final ErrorCode ORDER_VENEER_GOODS_CREATE_FAILED = new ErrorCode(1_003_009_055, "order.veneer.goods.create.failed");
|
||||||
public static final ErrorCode ORDER_VENEER_GOODS_STATUS_CHANGED = new ErrorCode(1_003_009_056, "order.veneer.goods.status.changed");
|
public static final ErrorCode ORDER_VENEER_GOODS_STATUS_CHANGED = new ErrorCode(1_003_009_056, "order.veneer.goods.status.changed");
|
||||||
|
public static final ErrorCode VENEER_PLATE_QUERY_SCOPE_REQUIRED = new ErrorCode(1_003_009_057, "veneer.plate.query.scope.required");
|
||||||
|
|
||||||
//=========== 部件管理 1-003-010-000 ============
|
//=========== 部件管理 1-003-010-000 ============
|
||||||
public static final ErrorCode ORDER_COMPONENT_NOT_EXIST = new ErrorCode(1_003_010_000, "order.component.not.exist");
|
public static final ErrorCode ORDER_COMPONENT_NOT_EXIST = new ErrorCode(1_003_010_000, "order.component.not.exist");
|
||||||
|
|||||||
+6
-20
@@ -64,31 +64,17 @@ public class VeneerDecomposeController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 按订单查询未贴皮分解板件列表。
|
* 按订单和/或板材查询未贴皮分解板件及造型数据。
|
||||||
*
|
*
|
||||||
* @param req 查询条件,必须包含订单ID列表
|
* @param req 查询条件,订单ID列表和板材商品编码列表至少传入一项
|
||||||
* @return 板件及板件造型数据
|
* @return 板件及板件造型数据
|
||||||
*/
|
*/
|
||||||
@PostMapping("/order/plate/page")
|
@PostMapping("/plate/data")
|
||||||
@Operation(summary = "获取订单下待贴皮分解板件列表")
|
@Operation(summary = "获取待贴皮分解板件数据")
|
||||||
@PreAuthorize("@ss.hasPermission('unplannedOrders:query')")
|
@PreAuthorize("@ss.hasPermission('unplannedOrders:query')")
|
||||||
public CommonResult<VeneerDecomposePlateDataRespVO> getVeneerDecomposeOrderPlateData(
|
public CommonResult<VeneerDecomposePlateDataRespVO> getVeneerDecomposePlateData(
|
||||||
@Valid @RequestBody VeneerDecomposePlatePageReqVO req) {
|
@Valid @RequestBody VeneerDecomposePlatePageReqVO req) {
|
||||||
return success(veneerDecomposeService.getOrderPlateList(req));
|
return success(veneerDecomposeService.getPlateData(req));
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 按板材查询未贴皮分解板件列表。
|
|
||||||
*
|
|
||||||
* @param req 查询条件,必须包含商品编码列表
|
|
||||||
* @return 板件及板件造型数据
|
|
||||||
*/
|
|
||||||
@PostMapping("/goods/plate/page")
|
|
||||||
@Operation(summary = "获取材质下待贴皮分解板件列表")
|
|
||||||
@PreAuthorize("@ss.hasPermission('unplannedOrders:query')")
|
|
||||||
public CommonResult<VeneerDecomposePlateDataRespVO> getVeneerDecomposeGoodsPlateData(
|
|
||||||
@Valid @RequestBody VeneerDecomposePlatePageReqVO req) {
|
|
||||||
return success(veneerDecomposeService.getGoodsPlateList(req));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+6
-20
@@ -67,31 +67,17 @@ public class VeneerManageController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 按订单查询可维护的未排单板件贴皮列表。
|
* 按订单和/或贴皮商品查询可维护的未排单板件贴皮列表。
|
||||||
*
|
*
|
||||||
* @param req 查询条件,必须包含订单ID列表,可按房间和柜体筛选
|
* @param req 查询条件,订单ID列表和贴皮商品编码列表至少传入一项
|
||||||
* @return 未排单板件贴皮列表
|
* @return 未排单板件贴皮列表
|
||||||
*/
|
*/
|
||||||
@PostMapping("/order/plate/list")
|
@PostMapping("/plate/list")
|
||||||
@Operation(summary = "按订单获取可维护的未排单板件贴皮列表")
|
@Operation(summary = "获取可维护的未排单板件贴皮列表")
|
||||||
@PreAuthorize("@ss.hasPermission('unplannedOrders:query')")
|
@PreAuthorize("@ss.hasPermission('unplannedOrders:query')")
|
||||||
public CommonResult<List<VeneerManagePlateRespVO>> getVeneerManageOrderPlateList(
|
public CommonResult<List<VeneerManagePlateRespVO>> getVeneerManagePlateList(
|
||||||
@Valid @RequestBody VeneerManagePlateListReqVO req) {
|
@Valid @RequestBody VeneerManagePlateListReqVO req) {
|
||||||
return success(veneerManageService.getOrderPlateList(req));
|
return success(veneerManageService.getPlateList(req));
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 按贴皮商品查询可维护的未排单板件贴皮列表。
|
|
||||||
*
|
|
||||||
* @param req 查询条件,必须包含贴皮商品编码列表
|
|
||||||
* @return 未排单板件贴皮列表
|
|
||||||
*/
|
|
||||||
@PostMapping("/goods/plate/list")
|
|
||||||
@Operation(summary = "按贴皮商品获取可维护的未排单板件贴皮列表")
|
|
||||||
@PreAuthorize("@ss.hasPermission('unplannedOrders:query')")
|
|
||||||
public CommonResult<List<VeneerManagePlateRespVO>> getVeneerManageGoodsPlateList(
|
|
||||||
@Valid @RequestBody VeneerManagePlateListReqVO req) {
|
|
||||||
return success(veneerManageService.getGoodsPlateList(req));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+2
-2
@@ -11,7 +11,7 @@ import java.util.List;
|
|||||||
@Data
|
@Data
|
||||||
public class VeneerDecomposePlatePageReqVO {
|
public class VeneerDecomposePlatePageReqVO {
|
||||||
|
|
||||||
@Schema(description = "订单ID列表")
|
@Schema(description = "订单ID列表,与板材商品编码列表至少传入一项;同时传入时取交集")
|
||||||
private List<Long> orderIds;
|
private List<Long> orderIds;
|
||||||
|
|
||||||
@Schema(description = "房间ID列表")
|
@Schema(description = "房间ID列表")
|
||||||
@@ -20,6 +20,6 @@ public class VeneerDecomposePlatePageReqVO {
|
|||||||
@Schema(description = "柜体ID列表")
|
@Schema(description = "柜体ID列表")
|
||||||
private List<Long> bodyIds;
|
private List<Long> bodyIds;
|
||||||
|
|
||||||
@Schema(description = "板材商品编码列表")
|
@Schema(description = "板材商品编码列表,与订单ID列表至少传入一项;同时传入时取交集")
|
||||||
private List<String> goodsIds;
|
private List<String> goodsIds;
|
||||||
}
|
}
|
||||||
|
|||||||
+4
-4
@@ -11,15 +11,15 @@ import java.util.List;
|
|||||||
@Data
|
@Data
|
||||||
public class VeneerManagePlateListReqVO {
|
public class VeneerManagePlateListReqVO {
|
||||||
|
|
||||||
@Schema(description = "订单ID列表")
|
@Schema(description = "订单ID列表,与贴皮商品编码列表至少传入一项;同时传入时取交集")
|
||||||
private List<Long> orderIds;
|
private List<Long> orderIds;
|
||||||
|
|
||||||
@Schema(description = "房间ID列表,仅按订单查询时生效")
|
@Schema(description = "房间ID列表")
|
||||||
private List<Long> roomIds;
|
private List<Long> roomIds;
|
||||||
|
|
||||||
@Schema(description = "柜体ID列表,仅按订单查询时生效")
|
@Schema(description = "柜体ID列表")
|
||||||
private List<Long> bodyIds;
|
private List<Long> bodyIds;
|
||||||
|
|
||||||
@Schema(description = "贴皮商品编码列表")
|
@Schema(description = "贴皮商品编码列表,与订单ID列表至少传入一项;同时传入时取交集")
|
||||||
private List<String> goodsIds;
|
private List<String> goodsIds;
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-12
@@ -80,23 +80,13 @@ public interface VeneerDecomposeMapper {
|
|||||||
@Param("req") VeneerDecomposeGoodsPageReqVO req);
|
@Param("req") VeneerDecomposeGoodsPageReqVO req);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 按订单查询未贴皮分解板件原始列表。
|
* 按订单和/或板材查询未贴皮分解板件原始列表。
|
||||||
* 同一板件可能因多个加工组返回多条记录,由 Service 层按板件主键去重。
|
* 同一板件可能因多个加工组返回多条记录,由 Service 层按板件主键去重。
|
||||||
*
|
*
|
||||||
* @param req 查询条件
|
* @param req 查询条件
|
||||||
* @return 板件原始列表
|
* @return 板件原始列表
|
||||||
*/
|
*/
|
||||||
List<VeneerDecomposePlateRespVO> selectOrderPlateList(
|
List<VeneerDecomposePlateRespVO> selectPlateList(
|
||||||
@Param("req") VeneerDecomposePlatePageReqVO req);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 按板材查询未贴皮分解板件原始列表。
|
|
||||||
* 同一板件可能因多个加工组返回多条记录,由 Service 层按板件主键去重。
|
|
||||||
*
|
|
||||||
* @param req 查询条件
|
|
||||||
* @return 板件原始列表
|
|
||||||
*/
|
|
||||||
List<VeneerDecomposePlateRespVO> selectGoodsPlateList(
|
|
||||||
@Param("req") VeneerDecomposePlatePageReqVO req);
|
@Param("req") VeneerDecomposePlatePageReqVO req);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+2
-10
@@ -106,20 +106,12 @@ public interface VeneerManageMapper {
|
|||||||
@Param("orderDateTime") LocalDateTime[] orderDateTime);
|
@Param("orderDateTime") LocalDateTime[] orderDateTime);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 按订单查询可维护的未排单板件贴皮列表。
|
* 按订单和/或贴皮商品编码查询可维护的未排单板件贴皮列表。
|
||||||
*
|
|
||||||
* @param req 订单、房间及柜体查询条件
|
|
||||||
* @return 未排单板件贴皮列表
|
|
||||||
*/
|
|
||||||
List<VeneerManagePlateRespVO> selectOrderPlateList(@Param("req") VeneerManagePlateListReqVO req);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 按贴皮商品编码查询可维护的未排单板件贴皮列表。
|
|
||||||
*
|
*
|
||||||
* @param req 订单、贴皮商品、房间及柜体查询条件
|
* @param req 订单、贴皮商品、房间及柜体查询条件
|
||||||
* @return 未排单板件贴皮列表
|
* @return 未排单板件贴皮列表
|
||||||
*/
|
*/
|
||||||
List<VeneerManagePlateRespVO> selectGoodsPlateList(
|
List<VeneerManagePlateRespVO> selectPlateList(
|
||||||
@Param("req") VeneerManagePlateListReqVO req);
|
@Param("req") VeneerManagePlateListReqVO req);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+3
-11
@@ -33,20 +33,12 @@ public interface VeneerDecomposeService {
|
|||||||
PageResult<VeneerDecomposeGoodsRespVO> getGoodsPage(VeneerDecomposeGoodsPageReqVO req);
|
PageResult<VeneerDecomposeGoodsRespVO> getGoodsPage(VeneerDecomposeGoodsPageReqVO req);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 按订单查询未贴皮分解板件列表。
|
* 按订单和/或板材查询未贴皮分解板件列表。
|
||||||
*
|
*
|
||||||
* @param req 查询条件,必须包含订单 ID 列表
|
* @param req 订单、板材、房间及柜体查询条件
|
||||||
* @return 去重后的板件及板件造型数据
|
* @return 去重后的板件及板件造型数据
|
||||||
*/
|
*/
|
||||||
VeneerDecomposePlateDataRespVO getOrderPlateList(VeneerDecomposePlatePageReqVO req);
|
VeneerDecomposePlateDataRespVO getPlateData(VeneerDecomposePlatePageReqVO req);
|
||||||
|
|
||||||
/**
|
|
||||||
* 按板材查询未贴皮分解板件列表。
|
|
||||||
*
|
|
||||||
* @param req 查询条件,必须包含商品编码列表
|
|
||||||
* @return 去重后的板件及板件造型数据
|
|
||||||
*/
|
|
||||||
VeneerDecomposePlateDataRespVO getGoodsPlateList(VeneerDecomposePlatePageReqVO req);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 将原板件分解为 A 面和/或 B 面贴皮记录。
|
* 将原板件分解为 A 面和/或 B 面贴皮记录。
|
||||||
|
|||||||
+5
-12
@@ -61,6 +61,7 @@ import static com.cf.imes.module.executor.enums.ErrorCodeConstants.ORDER_PLATE_U
|
|||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_GOODS_IDS_REQUIRED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_GOODS_IDS_REQUIRED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_ORDER_IDS_REQUIRED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_ORDER_IDS_REQUIRED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_PLATE_SIZE_INVALID;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_PLATE_SIZE_INVALID;
|
||||||
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_PLATE_QUERY_SCOPE_REQUIRED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_PLATE_STATUS_CHANGED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_PLATE_STATUS_CHANGED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_RECORD_INSERT_FAILED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_RECORD_INSERT_FAILED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_SIDE_REQUIRED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_DECOMPOSE_SIDE_REQUIRED;
|
||||||
@@ -189,19 +190,11 @@ public class VeneerDecomposeServiceImpl implements VeneerDecomposeService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public VeneerDecomposePlateDataRespVO getOrderPlateList(VeneerDecomposePlatePageReqVO req) {
|
public VeneerDecomposePlateDataRespVO getPlateData(VeneerDecomposePlatePageReqVO req) {
|
||||||
if (CollUtil.isEmpty(req.getOrderIds())) {
|
if (CollUtil.isEmpty(req.getOrderIds()) && CollUtil.isEmpty(req.getGoodsIds())) {
|
||||||
return buildPlateData(List.of());
|
throw new ServiceException(VENEER_PLATE_QUERY_SCOPE_REQUIRED);
|
||||||
}
|
}
|
||||||
return buildPlateData(veneerDecomposeMapper.selectOrderPlateList(req));
|
return buildPlateData(veneerDecomposeMapper.selectPlateList(req));
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public VeneerDecomposePlateDataRespVO getGoodsPlateList(VeneerDecomposePlatePageReqVO req) {
|
|
||||||
if (CollUtil.isEmpty(req.getGoodsIds())) {
|
|
||||||
return buildPlateData(List.of());
|
|
||||||
}
|
|
||||||
return buildPlateData(veneerDecomposeMapper.selectGoodsPlateList(req));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+3
-11
@@ -52,20 +52,12 @@ public interface VeneerManageService {
|
|||||||
PageResult<VeneerManageGoodsRespVO> getUnplannedGoodsPage(VeneerManageGoodsPageReqVO req);
|
PageResult<VeneerManageGoodsRespVO> getUnplannedGoodsPage(VeneerManageGoodsPageReqVO req);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 按订单查询可维护的未排单板件贴皮列表。
|
* 按订单和/或贴皮商品查询可维护的未排单板件贴皮列表。
|
||||||
*
|
*
|
||||||
* @param req 查询条件,必须包含订单ID列表,可按房间和柜体筛选
|
* @param req 订单、贴皮商品、房间及柜体查询条件
|
||||||
* @return 未排单板件贴皮列表
|
* @return 未排单板件贴皮列表
|
||||||
*/
|
*/
|
||||||
List<VeneerManagePlateRespVO> getOrderPlateList(VeneerManagePlateListReqVO req);
|
List<VeneerManagePlateRespVO> getPlateList(VeneerManagePlateListReqVO req);
|
||||||
|
|
||||||
/**
|
|
||||||
* 按板材查询可维护的未排单板件贴皮列表。
|
|
||||||
*
|
|
||||||
* @param req 查询条件,必须包含板材商品编码列表
|
|
||||||
* @return 未排单板件贴皮列表
|
|
||||||
*/
|
|
||||||
List<VeneerManagePlateRespVO> getGoodsPlateList(VeneerManagePlateListReqVO req);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 按订单或板材查询未排贴皮、原板件及板件造型数据。
|
* 按订单或板材查询未排贴皮、原板件及板件造型数据。
|
||||||
|
|||||||
+5
-12
@@ -49,6 +49,7 @@ import java.util.Set;
|
|||||||
|
|
||||||
import static com.cf.imes.framework.common.pojo.PageParam.PAGE_SIZE_NONE;
|
import static com.cf.imes.framework.common.pojo.PageParam.PAGE_SIZE_NONE;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_NOT_EXIST;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_NOT_EXIST;
|
||||||
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_PLATE_QUERY_SCOPE_REQUIRED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_REMOVE_RECORD_REQUIRED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_REMOVE_RECORD_REQUIRED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_REMOVE_RECORD_STATUS_CHANGED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_REMOVE_RECORD_STATUS_CHANGED;
|
||||||
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_RESELECT_RECORD_REQUIRED;
|
import static com.cf.imes.module.executor.enums.ErrorCodeConstants.VENEER_RESELECT_RECORD_REQUIRED;
|
||||||
@@ -195,19 +196,11 @@ public class VeneerManageServiceImpl implements VeneerManageService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<VeneerManagePlateRespVO> getOrderPlateList(VeneerManagePlateListReqVO req) {
|
public List<VeneerManagePlateRespVO> getPlateList(VeneerManagePlateListReqVO req) {
|
||||||
if (CollUtil.isEmpty(req.getOrderIds())) {
|
if (CollUtil.isEmpty(req.getOrderIds()) && CollUtil.isEmpty(req.getGoodsIds())) {
|
||||||
return List.of();
|
throw new ServiceException(VENEER_PLATE_QUERY_SCOPE_REQUIRED);
|
||||||
}
|
}
|
||||||
return veneerManageMapper.selectOrderPlateList(req);
|
return veneerManageMapper.selectPlateList(req);
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<VeneerManagePlateRespVO> getGoodsPlateList(VeneerManagePlateListReqVO req) {
|
|
||||||
if (CollUtil.isEmpty(req.getGoodsIds())) {
|
|
||||||
return List.of();
|
|
||||||
}
|
|
||||||
return veneerManageMapper.selectGoodsPlateList(req);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
+1
-44
@@ -343,7 +343,7 @@
|
|||||||
op.model_data AS modelData
|
op.model_data AS modelData
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectOrderPlateList" resultMap="PlateMap">
|
<select id="selectPlateList" resultMap="PlateMap">
|
||||||
SELECT
|
SELECT
|
||||||
<include refid="PlateColumns"/>
|
<include refid="PlateColumns"/>
|
||||||
FROM order_plate op
|
FROM order_plate op
|
||||||
@@ -386,49 +386,6 @@
|
|||||||
ORDER BY op.id DESC, oi.group_id
|
ORDER BY op.id DESC, oi.group_id
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectGoodsPlateList" resultMap="PlateMap">
|
|
||||||
SELECT
|
|
||||||
<include refid="PlateColumns"/>
|
|
||||||
FROM order_plate op
|
|
||||||
JOIN order_goods og ON og.order_id = op.order_id
|
|
||||||
AND og.id = op.goods_id
|
|
||||||
JOIN order_item oi ON oi.order_id = op.order_id
|
|
||||||
AND oi.plate_id = op.id
|
|
||||||
AND oi.plate_id != 0
|
|
||||||
LEFT JOIN order_body ob ON ob.organ_id = op.organ_id
|
|
||||||
AND ob.order_id = op.order_id
|
|
||||||
AND ob.id = oi.body_id
|
|
||||||
LEFT JOIN order_group opg ON opg.order_id = op.order_id
|
|
||||||
AND opg.id = oi.group_id
|
|
||||||
WHERE op.deleted = false
|
|
||||||
AND op.is_decomposed = false
|
|
||||||
<if test="req.goodsIds != null and req.goodsIds.size() > 0">
|
|
||||||
AND og.goods_id IN
|
|
||||||
<foreach collection="req.goodsIds" item="goodsId" open="(" close=")" separator=",">
|
|
||||||
#{goodsId}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
<if test="req.orderIds != null and req.orderIds.size() > 0">
|
|
||||||
AND op.order_id IN
|
|
||||||
<foreach collection="req.orderIds" item="orderId" open="(" close=")" separator=",">
|
|
||||||
#{orderId}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
<if test="req.roomIds != null and req.roomIds.size() > 0">
|
|
||||||
AND oi.room_id IN
|
|
||||||
<foreach collection="req.roomIds" item="roomId" open="(" close=")" separator=",">
|
|
||||||
#{roomId}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
<if test="req.bodyIds != null and req.bodyIds.size() > 0">
|
|
||||||
AND oi.body_id IN
|
|
||||||
<foreach collection="req.bodyIds" item="bodyId" open="(" close=")" separator=",">
|
|
||||||
#{bodyId}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
ORDER BY op.id DESC, oi.group_id
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectUndecomposedPlateList"
|
<select id="selectUndecomposedPlateList"
|
||||||
resultType="com.cf.imes.module.executor.dal.dataobject.plate.PlateDO">
|
resultType="com.cf.imes.module.executor.dal.dataobject.plate.PlateDO">
|
||||||
SELECT op.id,
|
SELECT op.id,
|
||||||
|
|||||||
+3
-44
@@ -447,7 +447,7 @@
|
|||||||
ovg.material
|
ovg.material
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectOrderPlateList" resultMap="PlateVeneerMap">
|
<select id="selectPlateList" resultMap="PlateVeneerMap">
|
||||||
SELECT
|
SELECT
|
||||||
<include refid="PlateVeneerColumns"/>
|
<include refid="PlateVeneerColumns"/>
|
||||||
FROM order_plate_veneer opv
|
FROM order_plate_veneer opv
|
||||||
@@ -456,10 +456,12 @@
|
|||||||
WHERE opv.deleted = false
|
WHERE opv.deleted = false
|
||||||
AND opv.plan_id = 0
|
AND opv.plan_id = 0
|
||||||
AND ovg.deleted = false
|
AND ovg.deleted = false
|
||||||
|
<if test="req.orderIds != null and req.orderIds.size() > 0">
|
||||||
AND opv.order_id IN
|
AND opv.order_id IN
|
||||||
<foreach collection="req.orderIds" item="orderId" open="(" close=")" separator=",">
|
<foreach collection="req.orderIds" item="orderId" open="(" close=")" separator=",">
|
||||||
#{orderId}
|
#{orderId}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
</if>
|
||||||
<if test="req.goodsIds != null and req.goodsIds.size() > 0">
|
<if test="req.goodsIds != null and req.goodsIds.size() > 0">
|
||||||
AND ovg.goods_id IN
|
AND ovg.goods_id IN
|
||||||
<foreach collection="req.goodsIds" item="goodsId" open="(" close=")" separator=",">
|
<foreach collection="req.goodsIds" item="goodsId" open="(" close=")" separator=",">
|
||||||
@@ -491,49 +493,6 @@
|
|||||||
ORDER BY opv.order_plate_id DESC, opv.veneer_side ASC
|
ORDER BY opv.order_plate_id DESC, opv.veneer_side ASC
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectGoodsPlateList" resultMap="PlateVeneerMap">
|
|
||||||
SELECT
|
|
||||||
<include refid="PlateVeneerColumns"/>
|
|
||||||
FROM order_plate_veneer opv
|
|
||||||
JOIN order_veneer_goods ovg ON ovg.order_id = opv.order_id
|
|
||||||
AND ovg.id = opv.order_veneer_goods_id
|
|
||||||
WHERE opv.deleted = false
|
|
||||||
AND opv.plan_id = 0
|
|
||||||
AND ovg.deleted = false
|
|
||||||
AND ovg.goods_id IN
|
|
||||||
<foreach collection="req.goodsIds" item="goodsId" open="(" close=")" separator=",">
|
|
||||||
#{goodsId}
|
|
||||||
</foreach>
|
|
||||||
<if test="req.orderIds != null and req.orderIds.size() > 0">
|
|
||||||
AND opv.order_id IN
|
|
||||||
<foreach collection="req.orderIds" item="orderId" open="(" close=")" separator=",">
|
|
||||||
#{orderId}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
<if test="(req.roomIds != null and req.roomIds.size() > 0)
|
|
||||||
or (req.bodyIds != null and req.bodyIds.size() > 0)">
|
|
||||||
AND EXISTS (
|
|
||||||
SELECT 1 FROM order_item oi
|
|
||||||
WHERE oi.order_id = opv.order_id
|
|
||||||
AND oi.plate_id = opv.order_plate_id
|
|
||||||
AND oi.plate_id != 0
|
|
||||||
<if test="req.roomIds != null and req.roomIds.size() > 0">
|
|
||||||
AND oi.room_id IN
|
|
||||||
<foreach collection="req.roomIds" item="roomId" open="(" close=")" separator=",">
|
|
||||||
#{roomId}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
<if test="req.bodyIds != null and req.bodyIds.size() > 0">
|
|
||||||
AND oi.body_id IN
|
|
||||||
<foreach collection="req.bodyIds" item="bodyId" open="(" close=")" separator=",">
|
|
||||||
#{bodyId}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
)
|
|
||||||
</if>
|
|
||||||
ORDER BY opv.order_plate_id DESC, opv.veneer_side ASC
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<sql id="UnplannedPlateColumns">
|
<sql id="UnplannedPlateColumns">
|
||||||
opv.id,
|
opv.id,
|
||||||
opv.order_id AS orderId,
|
opv.order_id AS orderId,
|
||||||
|
|||||||
+1
@@ -154,3 +154,4 @@ parts.heapsplit.num.not.enough=配件可分堆數量不足,請重繪後再次
|
|||||||
parts.heapsplit.item.source.not.exist=配件分堆數據异常,請重繪後再次分堆
|
parts.heapsplit.item.source.not.exist=配件分堆數據异常,請重繪後再次分堆
|
||||||
|
|
||||||
plan.not.allow.delete=排單號:{0}已開料無法刪除
|
plan.not.allow.delete=排單號:{0}已開料無法刪除
|
||||||
|
veneer.plate.query.scope.required=訂單ID列表和商品編碼列表至少傳入一項
|
||||||
|
|||||||
+1
@@ -155,3 +155,4 @@ parts.heapsplit.item.source.not.exist=Abnormal accessory stacking data, please r
|
|||||||
|
|
||||||
plan.not.allow.delete=Plan number: {0} has been cut and cannot be deleted
|
plan.not.allow.delete=Plan number: {0} has been cut and cannot be deleted
|
||||||
producing.plan.order.sync.failed=Failed to synchronize component production plan order: {0}
|
producing.plan.order.sync.failed=Failed to synchronize component production plan order: {0}
|
||||||
|
veneer.plate.query.scope.required=At least one of the order ID list and goods code list must be provided
|
||||||
|
|||||||
+1
@@ -155,3 +155,4 @@ parts.heapsplit.item.source.not.exist=配件分堆数据异常,请刷新后再
|
|||||||
|
|
||||||
plan.not.allow.delete=排单号:{0}已开料无法删除
|
plan.not.allow.delete=排单号:{0}已开料无法删除
|
||||||
producing.plan.order.sync.failed=同步组件生产排单失败:{0}
|
producing.plan.order.sync.failed=同步组件生产排单失败:{0}
|
||||||
|
veneer.plate.query.scope.required=订单ID列表和商品编码列表至少传入一项
|
||||||
|
|||||||
Reference in New Issue
Block a user