Преглед на файлове

fix:更新生产订单详情信息表

hmc преди 6 месеца
родител
ревизия
9125210cf0

+ 4 - 4
zkqy-admin/src/main/resources/application.yml

@@ -106,7 +106,7 @@ token:
   # 令牌密钥
   secret: abcdefghijklmnopqrstuvwxyz
   # 令牌有效期(默认30分钟)3000000
-  expireTime: 144000000
+  expireTime: 3000000
 
 # MyBatis配置
 mybatis:
@@ -201,12 +201,12 @@ projectDownloadZip:
 OpenAuthorization2:
   MES:
     # 单点获取code、token、userinfo主机地址
-    URL: http://192.168.2.127:8066/oauth2
+    URL: http://192.168.1.249:8066/oauth2
     # 系统标识
     BASIC: mes
     # 重定向本系统主机地址
-    REDIRECT_URL: http://192.168.2.127:1025
+    REDIRECT_URL: http://192.168.1.249:1025
     # 回调地址
-    CALLBACK: http://192.168.2.127:8066/oauth/callback
+    CALLBACK: http://192.168.1.249:8066/oauth/callback
     #
     NAME: hmc

+ 0 - 18
zkqy-admin/src/main/resources/kdwebapi.properties

@@ -1,18 +0,0 @@
-# ????????????ID
-X-KDApi-AcctID = 61c7dd2d0ff564
-# ????????????
-X-KDApi-UserName= ???
-# ????????????ID
-X-KDApi-AppID = 291472_5Z6q2/Ho6roeQaXv0d5PS61FQrTa0PNs
-# ??????????????
-X-KDApi-AppSec = 18d80a2709c7446ea44aa14b7d94e86e
-# ??Url??(????????sdk?????????X-KDApi-ServerUrl,????????)X-KDApi-ServerUrl =http://192.168.2.134/K3Cloud/
-X-KDApi-ServerUrl =http://192.168.2.134/K3Cloud/
-# ???????2052
-X-KDApi-LCID = 2052
-# ???????????????????????
-# X-KDApi-OrgNum = 100
-# ??????????????
-X-KDApi-ConnectTimeout=10000000
-# ??????????????
-X-KDApi-RequestTimeout=10000000

+ 53 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/jd/domain/JdProductionOrder.java

@@ -27,6 +27,29 @@ public class JdProductionOrder extends BaseEntity
     @Excel(name = "单据编号")
     @JSONField(name = "FBillNo")
     private String documentNumber;
+
+    /** 单据编号 */
+    @Excel(name = "单据编号")
+    @JSONField(name = "FBillNo")
+    private String fbillno;
+
+
+    /** 单据编号 */
+    @Excel(name = "单据主键")
+    @JSONField(name = "fid")
+    private String fid;
+
+
+    /** 订单号 */
+    @Excel(name = "订单号")
+    @JSONField(name = "FSrcBillNo")
+    private String fsrcbillno;
+
+    /** 订单号 */
+    @Excel(name = "源单分录内码")
+    @JSONField(name = "FTreeEntity.FEntryId")
+    private String ftreeEntityFentryid;
+
     @Excel(name = "需求日期")
     @JSONField(name = "F.PONP.XQRQ")
     private String   completionTime;
@@ -231,7 +254,37 @@ public class JdProductionOrder extends BaseEntity
         this.creationtimeString = creationtimeString;
     }
 
+    public String getFbillno() {
+        return fbillno;
+    }
 
+    public void setFbillno(String fbillno) {
+        this.fbillno = fbillno;
+    }
+
+    public String getFid() {
+        return fid;
+    }
+
+    public void setFid(String fid) {
+        this.fid = fid;
+    }
+
+    public String getFsrcbillno() {
+        return fsrcbillno;
+    }
+
+    public void setFsrcbillno(String fsrcbillno) {
+        this.fsrcbillno = fsrcbillno;
+    }
+
+    public String getFtreeEntityFentryid() {
+        return ftreeEntityFentryid;
+    }
+
+    public void setFtreeEntityFentryid(String ftreeEntityFentryid) {
+        this.ftreeEntityFentryid = ftreeEntityFentryid;
+    }
 
     public String getCreationtimeString() {
         return creationtimeString;

+ 24 - 24
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/jd/service/impl/JdProductionOrderServiceImpl.java

@@ -152,25 +152,25 @@ public class JdProductionOrderServiceImpl implements JdProductionOrderService
     public AjaxResult jdProductionOrderPull() {
         Boolean aTrue = stringRedisTemplate.opsForValue().setIfAbsent("fjqy:ptd:pulled", "true");
         if (aTrue) {
-            AjaxResult ajaxResult = jdMaterialInfoService.pullMaterialBaseInfo();
-            //金蝶工具key
-            K3CloudApi api = new K3CloudApi();
-            //定义查询条件
-            String query = "{\n" +
-                    "    \"FormId\": \"PRD_MO\",\n" +
-                    "    \"FieldKeys\": \"FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
-                    "FProductType,FMaterialId,FWorkShopID0,FQty,FStatus,FSaleOrderNo,FPickMtrlStatus," +
-                    "FMaterialId.FNumber,FMaterialName,F_PONP_BaseProperty,FSpecification,FUnitId.FName,F_PONP_yanse,F_PONP_mingpai,F_PONP_hegezheng.FDataValue," +
-                    "F_PONP_shuomingshu.FDataValue,F_PONP_KaiGuanXiang,F_PONP_baozhuangxiang,F_PONP_GongLv,FPlanFinishDate,FPlanStartDate,F_PONP_XQRQ,FPlanStartDate,FPlanFinishDate\",\n" +
-                    "    \"FilterString\": [{\"Left\":\"\",\"FieldName\":\"FMaterialId.FNumber\",\"Compare\":\"34\",\"Value\":\"焊\",\"Right\":\"\",\"Logic\":0},{\"Left\":\"\",\"FieldName\":\"FStatus\",\"Compare\":\"105\",\"Value\":\"4\",\"Right\":\"\",\"Logic\":0}],\n" +
-                    "    \"OrderString\": \"\",\n" +
-                    "    \"TopRowCount\": 0,\n" +
-                    "    \"StartRow\": 0,\n" +
-                    "    \"Limit\": 5000,\n" +
-                    "    \"SubSystemId\": \"\"\n" +
-                    "}";
-            //
             try {
+                AjaxResult ajaxResult = jdMaterialInfoService.pullMaterialBaseInfo();
+                //金蝶工具key
+                K3CloudApi api = new K3CloudApi();
+                //定义查询条件
+                String query = "{\n" +
+                        "    \"FormId\": \"PRD_MO\",\n" +
+                        "    \"FieldKeys\": \"fid,FSrcBillNo,FTreeEntity_FEntryId,FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
+                        "FProductType,FMaterialId,FWorkShopID0,FQty,FStatus,FSaleOrderNo,FPickMtrlStatus," +
+                        "FMaterialId.FNumber,FMaterialName,F_PONP_BaseProperty,FSpecification,FUnitId.FName,F_PONP_yanse,F_PONP_mingpai,F_PONP_hegezheng.FDataValue," +
+                        "F_PONP_shuomingshu.FDataValue,F_PONP_KaiGuanXiang,F_PONP_baozhuangxiang,F_PONP_GongLv,FPlanFinishDate,FPlanStartDate,F_PONP_XQRQ,FPlanStartDate,FPlanFinishDate\",\n" +
+                        "    \"FilterString\": [{\"Left\":\"\",\"FieldName\":\"FMaterialId.FNumber\",\"Compare\":\"34\",\"Value\":\"焊\",\"Right\":\"\",\"Logic\":0},{\"Left\":\"\",\"FieldName\":\"FStatus\",\"Compare\":\"105\",\"Value\":\"4\",\"Right\":\"\",\"Logic\":0}],\n" +
+                        "    \"OrderString\": \"\",\n" +
+                        "    \"TopRowCount\": 0,\n" +
+                        "    \"StartRow\": 0,\n" +
+                        "    \"Limit\": 5000,\n" +
+                        "    \"SubSystemId\": \"\"\n" +
+                        "}";
+                //
                 //查询结果
                 String resultJson = api.billQuery(query);
                 //生产信息
@@ -289,10 +289,10 @@ public class JdProductionOrderServiceImpl implements JdProductionOrderService
                     });
                 }
             } catch (Exception e) {
-                stringRedisTemplate.delete("fjqy:ptd:pulled");
                 throw new RuntimeException(e);
+            }finally {
+                stringRedisTemplate.delete("fjqy:ptd:pulled");
             }
-            stringRedisTemplate.delete("fjqy:ptd:pulled");
             return AjaxResult.success("拉取成功");
         } else {
             return AjaxResult.success("定时任务正在执行请稍后在拉去");
@@ -439,7 +439,7 @@ public class JdProductionOrderServiceImpl implements JdProductionOrderService
                 LocalDateTime now = LocalDateTime.now();
                 System.out.println("当前时间: " + now);
                 // 减去三个月
-                LocalDateTime threeMonthsAgo = now.minusMonths(3);
+                LocalDateTime threeMonthsAgo = now.minusMonths(6);
                 System.out.println("三个月前的时间: " + threeMonthsAgo);
                 LocalDateTime localDateTime1 = threeMonthsAgo.withMinute(0).withSecond(0).withNano(0);
                 DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
@@ -447,7 +447,7 @@ public class JdProductionOrderServiceImpl implements JdProductionOrderService
                 //定义查询条件
                 String query="{\n" +
                         "    \"FormId\": \"PRD_MO\",\n" +
-                        "    \"FieldKeys\": \"FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
+                        "    \"FieldKeys\": \"fid,FSrcBillNo,FTreeEntity_FEntryId,FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
                         "FProductType,FMaterialId,FWorkShopID0,FQty,FStatus,,FSaleOrderNo,FPickMtrlStatus," +
                         "FMaterialId.FNumber,FMaterialName,F_PONP_BaseProperty,FSpecification,FUnitId.FName,F_PONP_yanse,F_PONP_mingpai,F_PONP_hegezheng.FDataValue," +
                         "F_PONP_shuomingshu.FDataValue,F_PONP_KaiGuanXiang,F_PONP_baozhuangxiang,F_PONP_GongLv,F_PONP_XQRQ,FDate,FPlanStartDate,FPlanFinishDate\",\n" +
@@ -574,10 +574,10 @@ public class JdProductionOrderServiceImpl implements JdProductionOrderService
                         }
                     } while (flag);
                 } catch (Exception e) {
-                    stringRedisTemplate.delete("fjqy:hjd:pulled");
                     throw new RuntimeException(e);
+                }finally {
+                    stringRedisTemplate.delete("fjqy:ptd:pulled");
                 }
-                stringRedisTemplate.delete("fjqy:hjd:pulled");
                 return  AjaxResult.success("焊接单拉取成功");
      }else {
             System.out.println("定时任务正在执行请稍后在拉去");

+ 7 - 6
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/scheduling/ScheduledBean.java

@@ -83,7 +83,7 @@ public class ScheduledBean {
             //定义查询条件
             String query="{\n" +
                     "    \"FormId\": \"PRD_MO\",\n" +
-                    "    \"FieldKeys\": \"FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
+                    "    \"FieldKeys\": \"fid,FSrcBillNo,FTreeEntity_FEntryId,FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
                     "FProductType,FMaterialId,FWorkShopID0,FQty,FStatus,FSaleOrderNo,FPickMtrlStatus," +
                     "FMaterialId.FNumber,FMaterialName,F_PONP_BaseProperty,FSpecification,FUnitId.FName,F_PONP_yanse,F_PONP_mingpai,F_PONP_hegezheng.FDataValue," +
                     "F_PONP_shuomingshu.FDataValue,F_PONP_KaiGuanXiang,F_PONP_baozhuangxiang,F_PONP_GongLv,FPlanFinishDate,FPlanStartDate,F_PONP_XQRQ,FPlanStartDate,FPlanFinishDate\",\n" +
@@ -214,10 +214,10 @@ public class ScheduledBean {
                     });
                 }
             } catch (Exception e) {
-                stringRedisTemplate.delete("fjqy:ptd:pulled");
                 throw new RuntimeException(e);
+            }finally {
+                stringRedisTemplate.delete("fjqy:ptd:pulled");
             }
-            stringRedisTemplate.delete("fjqy:ptd:pulled");
             System.out.println("删除了键");
         }else {
             System.out.println("数据正在拉取-本地定时不执行");
@@ -353,7 +353,7 @@ public class ScheduledBean {
             //定义查询条件
             String query = "{\n" +
                     "    \"FormId\": \"PRD_MO\",\n" +
-                    "    \"FieldKeys\": \"FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
+                    "    \"FieldKeys\": \"fid,FSrcBillNo,FTreeEntity_FEntryId,FDescription,F_PONP_teshuyaoqiu,FBillNo,FBillType,FDate,FDocumentStatus," +
                     "FProductType,FMaterialId,FWorkShopID0,FQty,FStatus,,FSaleOrderNo,FPickMtrlStatus," +
                     "FMaterialId.FNumber,FMaterialName,F_PONP_BaseProperty,FSpecification,FUnitId.FName,F_PONP_yanse,F_PONP_mingpai,F_PONP_hegezheng.FDataValue," +
                     "F_PONP_shuomingshu.FDataValue,F_PONP_KaiGuanXiang,F_PONP_baozhuangxiang,F_PONP_GongLv,F_PONP_XQRQ,FDate,FPlanStartDate,FPlanFinishDate\",\n" +
@@ -487,10 +487,11 @@ public class ScheduledBean {
                     }
                 } while (flag);
             } catch (Exception e) {
-                stringRedisTemplate.delete("fjqy:hjd:pulled");
                 System.out.println("出现了异常");
+                throw new RuntimeException(e);
+            }finally {
+                stringRedisTemplate.delete("fjqy:ptd:pulled");
             }
-            stringRedisTemplate.delete("fjqy:hjd:pulled");
         }else {
             System.out.println("正在手动拉取不能执行此次定时任务");
         }

+ 47 - 8
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/service/impl/StationInformationServiceImpl.java

@@ -1189,7 +1189,7 @@ public class StationInformationServiceImpl implements IStationInformationService
                 ringScanInformation.setStationName(stationInformations.get(0).getStationName());//工位名称
             }else {//当前没有绑定Mac地址直接返回
                 ringScanInformation.setExecutionMark("2");//成功
-                ringScanInformation.setExecutionMessage("扫描失败");
+                ringScanInformation.setExecutionMessage("未绑定-人员-扫描失败");
                 int i2 = ringScanInformationMapper.insertRingScanInformation(ringScanInformation);
                 return "未绑定-人员-扫描失败";
             }
@@ -1216,7 +1216,7 @@ public class StationInformationServiceImpl implements IStationInformationService
             }else {
                 System.out.println("erp未同步当前流转卡序列号");
                 ringScanInformation.setExecutionMark("2");//成功
-                ringScanInformation.setExecutionMessage("扫描失败");
+                ringScanInformation.setExecutionMessage("先同步-ERP数据-扫描失败");
                 int i2 = ringScanInformationMapper.insertRingScanInformation(ringScanInformation);
                 return "请先同步-ERP数据-扫描失败";
             }
@@ -1296,7 +1296,7 @@ public class StationInformationServiceImpl implements IStationInformationService
                         if(ringScanInformations1.size()<=0) {
                             RingScanInformationFirst newRingScanInformationFirst = getRingScanInformationFirst(ringScanInformationFirstNumber.getPackingQuantity(), ringScanInformation, "1");
                             ringScanInformationFirstMapper.updateRingScanInformationFirstByproductionOrderNumber(newRingScanInformationFirst);
-//                            this.generateWarehouseWarrant(ringScanInformation.getProductionOrderNumber());
+                            this.generateWarehouseWarrant2(ringScanInformation.getProductionOrderNumber());
                         }
                     }else if(materialId.startsWith("201")&&ringScanInformation.getProcessName().equals("试机")) {
                         //有关于这个产品的扫描信息就不更新数量了
@@ -1307,7 +1307,7 @@ public class StationInformationServiceImpl implements IStationInformationService
                         if(ringScanInformations1.size()<=0){
                             RingScanInformationFirst newRingScanInformationFirst = getRingScanInformationFirst(ringScanInformationFirstNumber.getInspectionQuantity(), ringScanInformation,"2");
                             ringScanInformationFirstMapper.updateRingScanInformationFirstByproductionOrderNumber(newRingScanInformationFirst);
-//                            this.generateWarehouseWarrant(ringScanInformation.getProductionOrderNumber());
+                            this.generateWarehouseWarrant2(ringScanInformation.getProductionOrderNumber());
                         }
                     }
                 }
@@ -1358,9 +1358,9 @@ public class StationInformationServiceImpl implements IStationInformationService
 //                        ringScanInformation.getProcessName(), ringScanInformation.getNativeNumbering());//工序     流转卡信息
 //                return s;
 //            }, threadPoolTaskExecutor);
-            String s = this.sweepingMaterial(ringScanInformation.getOrderNumber(), ringScanInformation.getProductionOrderNumber(), //订单号   生产订单号
-                        ringScanInformation.getProcessName(), ringScanInformation.getNativeNumbering());//工序     流转卡信息
-            System.out.println(s);
+//            String s = this.sweepingMaterial(ringScanInformation.getOrderNumber(), ringScanInformation.getProductionOrderNumber(), //订单号   生产订单号
+//                        ringScanInformation.getProcessName(), ringScanInformation.getNativeNumbering());//工序     流转卡信息
+//            System.out.println(s);
             //入库逻辑
             this.generateWarehouseWarrant(ringScanInformation.getProductionOrderNumber(),ringScanInformation.getProcessName());//生产订单号,工序名
             return ringScanInformation.getStationName()+"-"+ringScanInformation.getPersonnelName()+"-"+"扫描成功";
@@ -1439,7 +1439,46 @@ public class StationInformationServiceImpl implements IStationInformationService
         }
     }
 
-    @Autowired
+
+
+
+    public  String  generateWarehouseWarrant2(String productionOrderNumber){
+        RingScanInformationFirst newRingScanInformationFirst = new RingScanInformationFirst();
+        newRingScanInformationFirst.setProductionOrderNumber(productionOrderNumber);;
+        List<RingScanInformationFirst> ringScanInformationFirsts1 = ringScanInformationFirstMapper.selectRingScanInformationFirstList(newRingScanInformationFirst);
+        if (ringScanInformationFirsts1.size()>0){
+            RingScanInformationFirst ringScanInformationFirst = ringScanInformationFirsts1.get(0);
+            String packingOrInspection = ringScanInformationFirst.getPackingOrInspection();
+            if(packingOrInspection.equals("1")){
+                //看包装跟当前生产订单总数量是否相等
+                if(ringScanInformationFirst.getPackingQuantity().equals(ringScanInformationFirst.getProductionOrderTotalQuantity())){
+                    //生成入库单
+                    System.out.println("包装生成入库单-入成品仓库");
+                    //入库这个生产订单下的所有产品信息
+
+                    //改当前生产订单的状态
+                    PlanTaskDetails planTaskDetails=new PlanTaskDetails();
+                    planTaskDetails.setDemandDocument(productionOrderNumber);
+                    planTaskDetails.setStatus("2");//生产完成
+                    int i = planTaskDetailsMapper.updatePlanTaskDetailsByDemandDocument(planTaskDetails);
+                }
+            }else if(packingOrInspection.equals("2")){
+                //看包装跟当前生产订单总数量是否相等
+                if(ringScanInformationFirst.getInspectionQuantity().equals(ringScanInformationFirst.getProductionOrderTotalQuantity())){
+                    //生成入库单
+                    System.out.println("包装生成入库单--入利庫");
+                    //入库这个生产订单下的所有产品信息
+                    PlanTaskDetails planTaskDetails=new PlanTaskDetails();
+                    planTaskDetails.setDemandDocument(productionOrderNumber);
+                    planTaskDetails.setStatus("2");//生产完成
+                    int i = planTaskDetailsMapper.updatePlanTaskDetailsByDemandDocument(planTaskDetails);
+                }
+            }
+        }
+        return "数量够了入库";
+    }
+
+   @Autowired
    SysDictDataMapper dictDataMapper;
     private  String  erpRk(PlanTaskDetails planTaskDetails2){
         //erp入库

+ 8 - 0
zkqy-fujian-amichi/src/main/resources/mapper/PlanTaskDetailsMapper.xml

@@ -183,6 +183,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="scheduledCommencement != null">scheduled_commencement,</if>
             <if test="scheduledCompletion != null">scheduled_completion,</if>
             <if test="status != null  and status != ''">status</if>
+            <if test="ftreeEntityFentryid != null  and ftreeEntityFentryid != ''">ftreeEntity_fentryid,</if>
+            <if test="fid != null  and fid != ''">fid,</if>
+            <if test="fbillno != null  and fbillno != ''">fbillno,</if>
+            <if test="fsrcbillno != null  and fsrcbillno != ''">fsrcbillno,</if>
          </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="taskId != null">#{taskId},</if>
@@ -229,6 +233,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="scheduledCommencement != null">#{scheduledCommencement},</if>
             <if test="scheduledCompletion != null">#{scheduledCompletion},</if>
             <if test="status != null  and status != ''">#{status},</if>
+            <if test="ftreeEntityFentryid != null  and ftreeEntityFentryid != ''">#{ftreeEntityFentryid},</if>
+            <if test="fid != null  and fid != ''">#{fid},</if>
+            <if test="fbillno != null  and fbillno != ''">#{fbillno},</if>
+            <if test="fsrcbillno != null  and fsrcbillno != ''">#{fsrcbillno},</if>
          </trim>
     </insert>
     <!--查询生产订单号 -->

+ 9 - 27
zkqy-fujian-amichi/src/main/resources/mapper/RingScanInformationMapper.xml

@@ -72,27 +72,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectRingScanInformationListVo" parameterType="com.zkqy.amichi.domain.RingScanInformation" resultMap="RingScanInformationResultNR">
         SELECT
-        pcf.production_order_list_id,
-        pcf.serial_number,
-        ptd.material_id,
-        ptd.material_name,
-        mbi.model,
-        ptd.power,
-        ptd.colour,
-        ptd.mingpai,
-        ptd.baozhuangxiang,
-        ptd.switch_box,
-        mbi.core_length,
-        mbi.voltage_frequency,
-        mbi.case_end_cover,
-        mbi.platter_interface,
-        CONCAT( IFNULL( mbi.data_info, '无' ), '/', IFNULL( mbi.phase_number, '无' ) ) AS data_info,
-        mbi.specification_book,
-        mbi.certificate_of_conformity,
-        ppm.special_requirements,
-        ppm.remark,
-        ptd.time_of_request AS timeOfRequest,
-        ptd.demand_document,
         rsi.id,
         rsi.device_number,
         rsi.device_name,
@@ -103,13 +82,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         rsi.process_name,
         rsi.station_name,
         rsi.execution_mark,
-        rsi.execution_message
+        rsi.execution_message,
+        ptd.demand_document,
+        ptd.material_id,
+        ptd.material_name,
+        ptd.model_number AS model,
+        ppm.order_number as production_order_list_id
         FROM
-        fjqydb.production_card_flow AS pcf
-        LEFT JOIN fjqydb.plan_task_details AS ptd ON ptd.demand_document = pcf.demand_document_number
-        LEFT JOIN fjqydb.material_base_info mbi ON ptd.material_id = mbi.material_code
-        LEFT JOIN fjqydb.production_planning_management AS ppm ON pcf.production_order_list_id = ppm.order_number
-        RIGHT JOIN fjqydb.ring_scan_information AS rsi ON pcf.serial_number = rsi.native_numbering
+        fjqydb.ring_scan_information as rsi
+        LEFT JOIN fjqydb.plan_task_details AS ptd ON ptd.demand_document = rsi.production_order_number
+        left join fjqydb.production_planning_management  as  ppm on ptd.plan_id=ppm.id
         <where>
             <if test="deviceNumber != null  and deviceNumber != ''"> and device_number = #{deviceNumber}</if>
             <if test="deviceName != null  and deviceName != ''"> and device_name like concat('%', #{deviceName}, '%')</if>

+ 2 - 2
zkqy-ui/.env.development

@@ -9,7 +9,7 @@ VUE_APP_BASE_API = '/dev-api'
 
 # 图片路径
 #VUE_APP_BASE_IMG_API = 'http://192.168.2.127:1024/dev-api'
-VUE_APP_BASE_IMG_API = 'http://192.168.2.127:1025/dev-api'
+VUE_APP_BASE_IMG_API = 'http://192.168.1.249:1025/dev-api'
 
 # 路由懒加载
 VUE_CLI_BABEL_TRANSPILE_MODULES = true
@@ -19,7 +19,7 @@ VUE_CLI_BABEL_TRANSPILE_MODULES = true
 # VUE_APP_BASE_API1 = 'http://192.168.110.120:8066/'
 # VUE_APP_BASE_API1 = 'http://192.168.110.76:8066/'
 #VUE_APP_BASE_API1 = 'http://192.168.2.127:8066/'
-VUE_APP_BASE_API1 = 'http://192.168.2.127:8066/'
+VUE_APP_BASE_API1 = 'http://192.168.1.249:8066/'
 
 # ws地址
 VUE_APP_BASE_WS_API = '//127.0.0.1:8721'

+ 1 - 1
zkqy-ui/src/permission.js

@@ -8,7 +8,7 @@ import {isRelogin} from '@/utils/request'
 
 NProgress.configure({showSpinner: false})
 
-const whiteList = ['/login', '/register', '/404', '/401','/redirectAuth',"/pageTransferPage"]
+const whiteList = ['/login', '/register', '/404', '/401','/redirectAuth',"/pageTransferPage","/amichi/dialogCompments/customizedVersion/processDisplay"]
 
 router.beforeEach((to, from, next) => {
   NProgress.start()

+ 7 - 0
zkqy-ui/src/router/index.js

@@ -87,6 +87,13 @@ export const constantRoutes = [
     },
     hidden: true
   },
+  {
+    path: '/amichi/dialogCompments/customizedVersion/processDisplay',
+    component: () => {
+      return import('@/views/amichi/dialogCompments/customizedVersion/processDisplay.vue')
+    },
+    hidden: true,
+  },
   {
     path: '/amichi/print/FlowCardPrint',
     component: () => {

+ 12 - 0
zkqy-ui/src/views/amichi/dialogCompments/customizedVersion/processDisplay.vue

@@ -71,6 +71,7 @@ export default {
       },
       tableData: {}, //列表数据
       loading: true,
+      intervalId: null, // 用于存储定时器 ID
     };
   },
   computed: {},
@@ -94,10 +95,21 @@ export default {
   },
   mounted() {
     this.getList();
+    // 每 30 分钟调用一次 API
+    this.intervalId = setInterval(() => {
+      this.getList();
+      console.log("我执行了")
+    }, 1 * 60 * 1000); // 30 分钟 = 30 * 60 * 1000 毫秒
   },
   activated() {
     this.getList();
   },
+  beforeDestroy() {
+    // 组件销毁前清除定时器,防止内存泄漏
+    if (this.intervalId) {
+      clearInterval(this.intervalId);
+    }
+  },
 };
 </script>
 

+ 1 - 1
zkqy-ui/src/views/login.vue

@@ -307,7 +307,7 @@ export default {
             Cookies.remove("rememberMe");
           }
           let form = {
-               uri: "?client_id=hmc&scope=basic&response_type=code&state=AB1357&redirect_uri=http://192.168.2.127:8066/oauth/callback",
+               uri: "?client_id=hmc&scope=basic&response_type=code&state=AB1357&redirect_uri=http://192.168.1.249:8066/oauth/callback",
                // uri:"?client_id=mestools&scope=basic&response_type=code&state=AB1357&redirect_uri=http://62.234.61.92:8055/oauth/callback",
                // uri:"?client_id=mestools&scope=basic&response_type=code&state=AB1357&redirect_uri=http://192.168.128.171:8066/oauth/callback",
               //  uri:"?client_id=mestools&scope=basic&response_type=code&state=AB1357&redirect_uri=http://192.168.2.135:8066/oauth/callback",

+ 1 - 1
zkqy-ui/vue.config.js

@@ -42,7 +42,7 @@ module.exports = {
         // target: `http://192.168.110.83:8066`,
         // target: `http://192.168.128.171:8066`,
         // target: `http://192.168.2.135:8066`, //铨一开发
-        target: `http://192.168.2.127:8066`,
+        target: `http://192.168.1.249:8066`,
         // target: `http://62.234.61.92:8055`,
         // target: `http://192.168.2.135:8066`,
         //  target: `http://192.168.128.171:8066`,