Browse Source

物料大更新

master
常熟吴彦祖 4 weeks ago
parent
commit
ebc4973ed9
  1. 3
      src/main/java/com/xujie/modules/order/service/Impl/PODetailServiceImpl.java
  2. 1
      src/main/java/com/xujie/modules/order/support/PoDetailAdvancedQuerySupport.java
  3. 6
      src/main/resources/mapper/order/PODetailMapper.xml

3
src/main/java/com/xujie/modules/order/service/Impl/PODetailServiceImpl.java

@ -842,7 +842,7 @@ public class PODetailServiceImpl extends ServiceImpl<PODetailMapper, PODetail> i
throw new RuntimeException("PO No 不能为空"); throw new RuntimeException("PO No 不能为空");
} }
if (!StringUtils.hasText(vo.getPartNo())) { if (!StringUtils.hasText(vo.getPartNo())) {
throw new RuntimeException("Item 不能为空");
throw new RuntimeException("Part No 不能为空");
} }
validateRequiredPriceAndQty(vo, null); validateRequiredPriceAndQty(vo, null);
@ -889,6 +889,7 @@ public class PODetailServiceImpl extends ServiceImpl<PODetailMapper, PODetail> i
assignOrderRefForCreate(poDetailVo, site, vo.getPoNo(), null); assignOrderRefForCreate(poDetailVo, site, vo.getPoNo(), null);
poDetailVo.setPartNo(vo.getPartNo()); poDetailVo.setPartNo(vo.getPartNo());
poDetailVo.setItem(vo.getItem());
poDetailVo.setPrice(vo.getPrice()); poDetailVo.setPrice(vo.getPrice());
poDetailVo.setQty(vo.getQty()); poDetailVo.setQty(vo.getQty());
poDetailVo.setShipQty(vo.getShipQty()); poDetailVo.setShipQty(vo.getShipQty());

1
src/main/java/com/xujie/modules/order/support/PoDetailAdvancedQuerySupport.java

@ -46,6 +46,7 @@ public final class PoDetailAdvancedQuerySupport {
map.put("poNo", new FieldMeta("poh.po_no", "string")); map.put("poNo", new FieldMeta("poh.po_no", "string"));
map.put("orderType", new FieldMeta("poh.order_type", "select")); map.put("orderType", new FieldMeta("poh.order_type", "select"));
map.put("partNo", new FieldMeta("pod.part_no", "string")); map.put("partNo", new FieldMeta("pod.part_no", "string"));
map.put("item", new FieldMeta("COALESCE(p.item, pod.item)", "string"));
map.put("categoryName", new FieldMeta("pf1.family_name", "string")); map.put("categoryName", new FieldMeta("pf1.family_name", "string"));
map.put("sku", new FieldMeta("p.sku", "string")); map.put("sku", new FieldMeta("p.sku", "string"));
map.put("price", new FieldMeta("pod.price", "number")); map.put("price", new FieldMeta("pod.price", "number"));

6
src/main/resources/mapper/order/PODetailMapper.xml

@ -182,7 +182,7 @@
<select id="myPage" resultType="com.xujie.modules.order.vo.PODetailVo"> <select id="myPage" resultType="com.xujie.modules.order.vo.PODetailVo">
select pod.po_header_id as poHeaderId, pod.order_no, pod.site, pod.item_no, pod.part_no, pod.status, pod.qty, pod.umid, pod.convert_factor, pod.price, pod.base_price, pod.want_receive_date, pod.tax_rate, pod.tax, pod.additional_cost, pod.freight, pod.duty, pod.arrive_qty, pod.receive_qty, pod.qty_returned, pod.qty_replace, pod.qty_scrapt, pod.invoice_qty, pod.approve_result, pod.need_inspect_flag, pod.remark, pod.iqc_qty, pod.last_update_by, pod.pr_convert_note, pod.inspect_type_db, pod.inspect_type, pod.inspect_qty, pod.inspect_percent, pod.inspection_level_no, pod.close_tolerance, pod.over_receive_tolerance select pod.po_header_id as poHeaderId, pod.order_no, pod.site, pod.item_no, pod.part_no, pod.status, pod.qty, pod.umid, pod.convert_factor, pod.price, pod.base_price, pod.want_receive_date, pod.tax_rate, pod.tax, pod.additional_cost, pod.freight, pod.duty, pod.arrive_qty, pod.receive_qty, pod.qty_returned, pod.qty_replace, pod.qty_scrapt, pod.invoice_qty, pod.approve_result, pod.need_inspect_flag, pod.remark, pod.iqc_qty, pod.last_update_by, pod.pr_convert_note, pod.inspect_type_db, pod.inspect_type, pod.inspect_qty, pod.inspect_percent, pod.inspection_level_no, pod.close_tolerance, pod.over_receive_tolerance
,pod.inspect_method_db, pod.to_inv_nofity_qty, pod.upload_date, pod.order_ref1, pod.order_ref5, pod.batch_no, pod.order_ref4, pod.pre_pay_amount, pod.upload_by, pod.pur_lead_time, pod.order_ref_type, pod.order_ref3, pod.need_receive_flag, pod.upload_flag, pod.id as id, pod.pre_pay_reverse_amount, pod.out_work_order_flag, pod.order_ref2, pod.qty_rbjs, pod.pre_pay_pay_amount, pod.need_date, pod.inspect_method, pod.inv_notify_qty, pod.standard_tt as standardTt ,pod.inspect_method_db, pod.to_inv_nofity_qty, pod.upload_date, pod.order_ref1, pod.order_ref5, pod.batch_no, pod.order_ref4, pod.pre_pay_amount, pod.upload_by, pod.pur_lead_time, pod.order_ref_type, pod.order_ref3, pod.need_receive_flag, pod.upload_flag, pod.id as id, pod.pre_pay_reverse_amount, pod.out_work_order_flag, pod.order_ref2, pod.qty_rbjs, pod.pre_pay_pay_amount, pod.need_date, pod.inspect_method, pod.inv_notify_qty, pod.standard_tt as standardTt
,pod.item as item
,COALESCE(p.item, pod.item) as item
,pod.c_value as value ,pod.c_value as value
,pod.c_ship_qty as shipQty ,pod.c_ship_qty as shipQty
,pod.c_sum_price as sumPrice ,pod.c_sum_price as sumPrice
@ -283,7 +283,7 @@
<if test="query.inspectionLevelNo != null and query.inspectionLevelNo != '' "> and pod.inspection_level_no like '%${query.inspectionLevelNo}%'</if> <if test="query.inspectionLevelNo != null and query.inspectionLevelNo != '' "> and pod.inspection_level_no like '%${query.inspectionLevelNo}%'</if>
<if test="query.closeTolerance != null and query.closeTolerance != '' "> and pod.close_tolerance like '%${query.closeTolerance}%'</if> <if test="query.closeTolerance != null and query.closeTolerance != '' "> and pod.close_tolerance like '%${query.closeTolerance}%'</if>
<if test="query.overReceiveTolerance != null and query.overReceiveTolerance != '' "> and pod.over_receive_tolerance like '%${query.overReceiveTolerance}%'</if> <if test="query.overReceiveTolerance != null and query.overReceiveTolerance != '' "> and pod.over_receive_tolerance like '%${query.overReceiveTolerance}%'</if>
<if test="query.item != null and query.item != '' "> and pod.item like '%${query.item}%'</if>
<if test="query.item != null and query.item != '' "> and COALESCE(p.item, pod.item) like '%${query.item}%'</if>
<if test="query.value != null and query.value != '' "> and pod.c_value like '%${query.value}%'</if> <if test="query.value != null and query.value != '' "> and pod.c_value like '%${query.value}%'</if>
<if test="query.shipQty != null "> and pod.c_ship_qty = '${query.shipQty}'</if> <if test="query.shipQty != null "> and pod.c_ship_qty = '${query.shipQty}'</if>
<if test="query.sumPrice != null and query.sumPrice != '' "> and pod.c_sum_price like '%${query.sumPrice}%'</if> <if test="query.sumPrice != null and query.sumPrice != '' "> and pod.c_sum_price like '%${query.sumPrice}%'</if>
@ -336,7 +336,7 @@
<select id="myPageAdvanced" resultType="com.xujie.modules.order.vo.PODetailVo"> <select id="myPageAdvanced" resultType="com.xujie.modules.order.vo.PODetailVo">
select pod.po_header_id as poHeaderId, pod.order_no, pod.site, pod.item_no, pod.part_no, pod.status, pod.qty, pod.umid, pod.convert_factor, pod.price, pod.base_price, pod.want_receive_date, pod.tax_rate, pod.tax, pod.additional_cost, pod.freight, pod.duty, pod.arrive_qty, pod.receive_qty, pod.qty_returned, pod.qty_replace, pod.qty_scrapt, pod.invoice_qty, pod.approve_result, pod.need_inspect_flag, pod.remark, pod.iqc_qty, pod.last_update_by, pod.pr_convert_note, pod.inspect_type_db, pod.inspect_type, pod.inspect_qty, pod.inspect_percent, pod.inspection_level_no, pod.close_tolerance, pod.over_receive_tolerance select pod.po_header_id as poHeaderId, pod.order_no, pod.site, pod.item_no, pod.part_no, pod.status, pod.qty, pod.umid, pod.convert_factor, pod.price, pod.base_price, pod.want_receive_date, pod.tax_rate, pod.tax, pod.additional_cost, pod.freight, pod.duty, pod.arrive_qty, pod.receive_qty, pod.qty_returned, pod.qty_replace, pod.qty_scrapt, pod.invoice_qty, pod.approve_result, pod.need_inspect_flag, pod.remark, pod.iqc_qty, pod.last_update_by, pod.pr_convert_note, pod.inspect_type_db, pod.inspect_type, pod.inspect_qty, pod.inspect_percent, pod.inspection_level_no, pod.close_tolerance, pod.over_receive_tolerance
,pod.inspect_method_db, pod.to_inv_nofity_qty, pod.upload_date, pod.order_ref1, pod.order_ref5, pod.batch_no, pod.order_ref4, pod.pre_pay_amount, pod.upload_by, pod.pur_lead_time, pod.order_ref_type, pod.order_ref3, pod.need_receive_flag, pod.upload_flag, pod.id as id, pod.pre_pay_reverse_amount, pod.out_work_order_flag, pod.order_ref2, pod.qty_rbjs, pod.pre_pay_pay_amount, pod.need_date, pod.inspect_method, pod.inv_notify_qty, pod.standard_tt as standardTt ,pod.inspect_method_db, pod.to_inv_nofity_qty, pod.upload_date, pod.order_ref1, pod.order_ref5, pod.batch_no, pod.order_ref4, pod.pre_pay_amount, pod.upload_by, pod.pur_lead_time, pod.order_ref_type, pod.order_ref3, pod.need_receive_flag, pod.upload_flag, pod.id as id, pod.pre_pay_reverse_amount, pod.out_work_order_flag, pod.order_ref2, pod.qty_rbjs, pod.pre_pay_pay_amount, pod.need_date, pod.inspect_method, pod.inv_notify_qty, pod.standard_tt as standardTt
,pod.item as item
,COALESCE(p.item, pod.item) as item
,pod.c_value as value ,pod.c_value as value
,pod.c_ship_qty as shipQty ,pod.c_ship_qty as shipQty
,pod.c_sum_price as sumPrice ,pod.c_sum_price as sumPrice

Loading…
Cancel
Save