From 8f5de59e5cf92494b9cfb731b51c4678028a206b Mon Sep 17 00:00:00 2001 From: A0010407 Date: Wed, 27 Sep 2023 14:55:08 +0800 Subject: [PATCH] mes rfid --- .../api/domain/mes/ProRfidProcessDetail.java | 55 +++++++++++++++++++ .../mapper/mes/ProRfidProcessDetailMapper.xml | 41 ++++++++++++-- 2 files changed, 91 insertions(+), 5 deletions(-) diff --git a/op-api/op-api-system/src/main/java/com/op/system/api/domain/mes/ProRfidProcessDetail.java b/op-api/op-api-system/src/main/java/com/op/system/api/domain/mes/ProRfidProcessDetail.java index 65a44a10..4379d6f1 100644 --- a/op-api/op-api-system/src/main/java/com/op/system/api/domain/mes/ProRfidProcessDetail.java +++ b/op-api/op-api-system/src/main/java/com/op/system/api/domain/mes/ProRfidProcessDetail.java @@ -87,6 +87,61 @@ public class ProRfidProcessDetail extends BaseEntity { private String productCode; private String productModel; + /** 现在工序编码 */ + @Excel(name = "现在工序编码") + private String nowProcessCode; + + /** 现在工序名称 */ + @Excel(name = "现在工序名称") + private String nowProcessName; + + /** 下一步工序编码 */ + @Excel(name = "下一步工序编码") + private String nextProcessCode; + + /** 下一步工序名称 */ + @Excel(name = "下一步工序名称") + private String nextProcessName; + + /** 订单号 */ + @Excel(name = "订单号") + private String orderCode; + + public String getOrderCode() { + return orderCode; + } + public void setOrderCode(String orderCode) { + this.orderCode = orderCode; + } + + public String getNextProcessName() { + return nextProcessName; + } + public void setNextProcessName(String nextProcessName) { + this.nextProcessName = nextProcessName; + } + + public String getNextProcessCode() { + return nextProcessCode; + } + public void setNextProcessCode(String nextProcessCode) { + this.nextProcessCode = nextProcessCode; + } + + public String getNowProcessName() { + return nowProcessName; + } + public void setNowProcessName(String nowProcessName) { + this.nowProcessName = nowProcessName; + } + + public String getNowProcessCode() { + return nowProcessCode; + } + public void setNowProcessCode(String nowProcessCode) { + this.nowProcessCode = nowProcessCode; + } + public String getProdLineCode() { return prodLineCode; } diff --git a/op-modules/op-mes/src/main/resources/mapper/mes/ProRfidProcessDetailMapper.xml b/op-modules/op-mes/src/main/resources/mapper/mes/ProRfidProcessDetailMapper.xml index bb08b9a7..5ed1a4c7 100644 --- a/op-modules/op-mes/src/main/resources/mapper/mes/ProRfidProcessDetailMapper.xml +++ b/op-modules/op-mes/src/main/resources/mapper/mes/ProRfidProcessDetailMapper.xml @@ -36,13 +36,44 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" from pro_rfid_process_detail - + select + ppd.record_id as recordId, + ppd.workorder_code as workorderCode, + ppd.rfid, + ppd.factory_code as factoryCode, + ppd.machine_code as machineCode, + ppd.now_process_id as nowProcessId, + ppd.next_process_id as nextProcessId, + ppd.order_num as orderNum, + ppd.in_time as inTime, + ppd.out_time as outTime, + ppd.status, + ppd.remark, + ppd.attr1, + ppd.attr2, + ppd.attr3, + ppd.attr4, + ppd.create_by as createBy, + ppd.create_time as createTime, + ppd.update_by as updateBy, + ppd.update_time as updateTime, + ppd.work_batch_code as workBatchCode, + ppd.bind_status as bindStatus, + pp.process_code as nowProcessCode, + pp.process_name as nowProcessName, + ppp.process_code as nextProcessCode, + ppp.process_name as nextProcessName, + pow.order_code as orderCode + from pro_rfid_process_detail ppd + left join pro_process pp on pp.process_id = ppd.next_process_id + left join pro_process ppp on ppp.process_id = ppd.now_process_id + left join pro_order_workorder pow on pow.workorder_code = ppd.workorder_code - and workorder_code = #{workorderCode} - and rfid = #{rfid} + and ppd.workorder_code like concat('%', #{workorderCode}, '%') + and rfid like concat('%', #{rfid}, '%') and factory_code = #{factoryCode} - and machine_code = #{machineCode} + and machine_code like concat('%', #{machineCode}, '%') and now_process_id = #{nowProcessId} and next_process_id = #{nextProcessId} and order_num = #{orderNum}