diff --git a/op-api/op-api-system/src/main/java/com/op/system/api/RemoteSapService.java b/op-api/op-api-system/src/main/java/com/op/system/api/RemoteSapService.java index 3b421369..5c12562d 100644 --- a/op-api/op-api-system/src/main/java/com/op/system/api/RemoteSapService.java +++ b/op-api/op-api-system/src/main/java/com/op/system/api/RemoteSapService.java @@ -27,8 +27,8 @@ public interface RemoteSapService { @PostMapping("/bomSync") public R bomSync(); - @PostMapping("/sap/sapProRouteProcess") - public R sapProRouteProcess(); + @PostMapping("/sap/sapRouterSync") + public R sapRouterSync(); @PostMapping("/sap/materialPreparation") public R>materialPreparation(@RequestParam("shopOrder") String shopOrder); diff --git a/op-api/op-api-system/src/main/java/com/op/system/api/factory/RemoteSapFallbackFactory.java b/op-api/op-api-system/src/main/java/com/op/system/api/factory/RemoteSapFallbackFactory.java index ff08195d..edeec565 100644 --- a/op-api/op-api-system/src/main/java/com/op/system/api/factory/RemoteSapFallbackFactory.java +++ b/op-api/op-api-system/src/main/java/com/op/system/api/factory/RemoteSapFallbackFactory.java @@ -30,7 +30,7 @@ public class RemoteSapFallbackFactory implements FallbackFactory sapProRouteProcess() { + public R sapRouterSync() { return null; } diff --git a/op-modules/op-job/src/main/java/com/op/job/task/RyTask.java b/op-modules/op-job/src/main/java/com/op/job/task/RyTask.java index 31f2d293..97edfb4a 100644 --- a/op-modules/op-job/src/main/java/com/op/job/task/RyTask.java +++ b/op-modules/op-job/src/main/java/com/op/job/task/RyTask.java @@ -59,7 +59,7 @@ public class RyTask { */ public void getRouteTask(){ System.out.println("++同步工艺+开始++getRouteTask+++++"); - remoteSapService.sapProRouteProcess(); + remoteSapService.sapRouterSync(); } /**每天21点00更新明日订单执行 diff --git a/op-modules/op-sap/src/main/java/com/op/sap/domain/SapMaterialPreparation.java b/op-modules/op-sap/src/main/java/com/op/sap/domain/SapMaterialPreparation.java deleted file mode 100644 index 2981cdd7..00000000 --- a/op-modules/op-sap/src/main/java/com/op/sap/domain/SapMaterialPreparation.java +++ /dev/null @@ -1,125 +0,0 @@ -package com.op.sap.domain; - - -public class SapMaterialPreparation { - //订单号 - private String AUFNR; - //预留/相关需求的项目编号 - private String RSPOS; - //物料号 - private String MATNR; - //物料描述(短文本) - private String MAKTX; - //工厂 - private String WERKS; - //库存地点 - private String LGORT; - //组件的需求日期 - private String BDTER; - //需求量 - private String BDMNG; - //欠料数量 - private String ZQLSL; - //基本计量单位 - private String MEINS; - //标识:反冲 - private String RGEKZ; - //直接采购标识 - private String DBSKZ; - - public String getAUFNR() { - return AUFNR; - } - - public void setAUFNR(String AUFNR) { - this.AUFNR = AUFNR; - } - - public String getRSPOS() { - return RSPOS; - } - - public void setRSPOS(String RSPOS) { - this.RSPOS = RSPOS; - } - - public String getMATNR() { - return MATNR; - } - - public void setMATNR(String MATNR) { - this.MATNR = MATNR; - } - - public String getMAKTX() { - return MAKTX; - } - - public void setMAKTX(String MAKTX) { - this.MAKTX = MAKTX; - } - - public String getWERKS() { - return WERKS; - } - - public void setWERKS(String WERKS) { - this.WERKS = WERKS; - } - - public String getLGORT() { - return LGORT; - } - - public void setLGORT(String LGORT) { - this.LGORT = LGORT; - } - - public String getBDTER() { - return BDTER; - } - - public void setBDTER(String BDTER) { - this.BDTER = BDTER; - } - - public String getBDMNG() { - return BDMNG; - } - - public void setBDMNG(String BDMNG) { - this.BDMNG = BDMNG; - } - - public String getZQLSL() { - return ZQLSL; - } - - public void setZQLSL(String ZQLSL) { - this.ZQLSL = ZQLSL; - } - - public String getMEINS() { - return MEINS; - } - - public void setMEINS(String MEINS) { - this.MEINS = MEINS; - } - - public String getRGEKZ() { - return RGEKZ; - } - - public void setRGEKZ(String RGEKZ) { - this.RGEKZ = RGEKZ; - } - - public String getDBSKZ() { - return DBSKZ; - } - - public void setDBSKZ(String DBSKZ) { - this.DBSKZ = DBSKZ; - } -} diff --git a/op-modules/op-sap/src/main/java/com/op/sap/mapper/SapProRouteProductMapper.java b/op-modules/op-sap/src/main/java/com/op/sap/mapper/SapProRouteProductMapper.java index b15e16a2..0ddfa243 100644 --- a/op-modules/op-sap/src/main/java/com/op/sap/mapper/SapProRouteProductMapper.java +++ b/op-modules/op-sap/src/main/java/com/op/sap/mapper/SapProRouteProductMapper.java @@ -1,7 +1,5 @@ package com.op.sap.mapper; - - import com.op.system.api.domain.sap.SapProRouteProduct; import org.apache.ibatis.annotations.Mapper; diff --git a/op-modules/op-sap/src/main/resources/mapper/SapBaseFileMapper.xml b/op-modules/op-sap/src/main/resources/mapper/SapBaseFileMapper.xml deleted file mode 100644 index 17144d6f..00000000 --- a/op-modules/op-sap/src/main/resources/mapper/SapBaseFileMapper.xml +++ /dev/null @@ -1,132 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - select file_id, file_name, file_address, source_id, remark, attr1, - attr2, attr3, attr4, create_by, create_time, update_by, - update_time from base_file - - - - - - - - - insert into base_file - - file_id, - file_name, - file_address, - source_id, - remark, - attr1, - attr2, - attr3, - attr4, - create_by, - create_time, - update_by, - update_time, - - - #{fileId}, - #{fileName}, - #{fileAddress}, - #{sourceId}, - #{remark}, - #{attr1}, - #{attr2}, - #{attr3}, - #{attr4}, - #{createBy}, - #{createTime}, - #{updateBy}, - #{updateTime}, - - - - INSERT INTO base_file(file_id, file_name, file_address, source_id, remark, create_by, create_time) - VALUES - - ( - #{baseFile.fileId}, - #{baseFile.fileName}, - #{baseFile.fileAddress}, - #{baseFile.sourceId}, - #{baseFile.remark}, - #{baseFile.createBy}, - #{baseFile.createTime} - ) - - - - - update base_file - - file_name = #{fileName}, - file_address = #{fileAddress}, - source_id = #{sourceId}, - remark = #{remark}, - attr1 = #{attr1}, - attr2 = #{attr2}, - attr3 = #{attr3}, - attr4 = #{attr4}, - create_by = #{createBy}, - create_time = #{createTime}, - update_by = #{updateBy}, - update_time = #{updateTime}, - - where file_id = #{fileId} - - - - delete from base_file where file_id = #{fileId} - - - - delete from base_file where file_id in - - #{fileId} - - - - delete from base_file where source_id = #{sourceId} - - diff --git a/op-modules/op-sap/src/main/resources/mapper/SapProRouteProductMapper.xml b/op-modules/op-sap/src/main/resources/mapper/SapProRouteProductMapper.xml index f63d3dbc..b9ab5942 100644 --- a/op-modules/op-sap/src/main/resources/mapper/SapProRouteProductMapper.xml +++ b/op-modules/op-sap/src/main/resources/mapper/SapProRouteProductMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -25,7 +25,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" select record_id, route_id, item_id, item_code, item_name, remark, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time from pro_route_product - and route_id = #{routeId} @@ -51,7 +51,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - select bp.product_code [key], bp.product_desc_zh label, bp.product_desc_zh itemName, @@ -68,7 +68,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - select pp.item_code [key], bp.product_desc_zh label from pro_route_product pp @@ -76,7 +76,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where pp.route_id = #{routeId} - + insert into pro_route_product record_id, @@ -112,7 +112,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update pro_route_product route_id = #{routeId}, diff --git a/op-modules/op-sap/src/main/resources/mapper/SapSysUserMapper.xml b/op-modules/op-sap/src/main/resources/mapper/SapSysUserMapper.xml index cad40a0d..fb3f086a 100644 --- a/op-modules/op-sap/src/main/resources/mapper/SapSysUserMapper.xml +++ b/op-modules/op-sap/src/main/resources/mapper/SapSysUserMapper.xml @@ -4,49 +4,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - + insert into base_bom_component id, @@ -120,7 +120,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update base_bom_component bom_code = #{bomCode}, diff --git a/op-modules/op-sap/src/main/resources/mapper/sap/SapBomMapper.xml b/op-modules/op-sap/src/main/resources/mapper/sap/SapBomMapper.xml index 47690900..d1cdb9e2 100644 --- a/op-modules/op-sap/src/main/resources/mapper/sap/SapBomMapper.xml +++ b/op-modules/op-sap/src/main/resources/mapper/sap/SapBomMapper.xml @@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -35,7 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" select factory_code, production_version, bom_code, optional_bom, optional_bom_text, pvvd, pved, bom_calculate_number, bom_calculate_unit, bom_base_number, bom_base_unit, component_unit, component_pro_flag, msi, sanka, attr1, attr2, attr3, create_by, create_time, update_by, update_time, remark, current_version from base_bom - and factory_code = #{factoryCode} @@ -65,7 +65,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where factory_code = #{factoryCode} - + insert into base_bom factory_code, @@ -121,7 +121,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - + update base_bom production_version = #{productionVersion}, diff --git a/op-modules/op-technology/src/main/java/com/op/technology/controller/ProRouteController.java b/op-modules/op-technology/src/main/java/com/op/technology/controller/ProRouteController.java index d65a3d2c..ec3f0b1a 100644 --- a/op-modules/op-technology/src/main/java/com/op/technology/controller/ProRouteController.java +++ b/op-modules/op-technology/src/main/java/com/op/technology/controller/ProRouteController.java @@ -138,7 +138,7 @@ public class ProRouteController extends BaseController { @Log(title = "手动执行同步SAP工艺路线", businessType = BusinessType.INSERT) @PostMapping("/sapProRouteProcess") public AjaxResult sapProRouteProcess() { - R r = remoteSapService.sapProRouteProcess(); + R r = remoteSapService.sapRouterSync(); if((Boolean) r.getData()){ return AjaxResult.success(); }