From 7426badbf33c1ee4ba89e16bfbb4049a479e21ee Mon Sep 17 00:00:00 2001 From: mashuai Date: Wed, 15 May 2024 09:15:42 +0800 Subject: [PATCH] =?UTF-8?q?bug-=E9=A2=84=E6=8A=A5=E5=BA=9F=E5=AE=A1?= =?UTF-8?q?=E6=A0=B8=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sgzb/material/vo/ScrapApplyDetailsVO.java | 8 ++++++ .../material/ScrapApplyDetailsMapper.xml | 25 +++++++++++-------- 2 files changed, 23 insertions(+), 10 deletions(-) diff --git a/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/vo/ScrapApplyDetailsVO.java b/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/vo/ScrapApplyDetailsVO.java index f0244e40..32701ec8 100644 --- a/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/vo/ScrapApplyDetailsVO.java +++ b/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/vo/ScrapApplyDetailsVO.java @@ -59,6 +59,14 @@ public class ScrapApplyDetailsVO { */ @Excel(name = "维修单号",sort = 6) private String repairNum; + /** + * 单位id + */ + private String unitId; + /** + * 工程id + */ + private String projectId; /** * 审核状态 diff --git a/sgzb-modules/sgzb-material/src/main/resources/mapper/material/ScrapApplyDetailsMapper.xml b/sgzb-modules/sgzb-material/src/main/resources/mapper/material/ScrapApplyDetailsMapper.xml index b7860aaa..037bcc5c 100644 --- a/sgzb-modules/sgzb-material/src/main/resources/mapper/material/ScrapApplyDetailsMapper.xml +++ b/sgzb-modules/sgzb-material/src/main/resources/mapper/material/ScrapApplyDetailsMapper.xml @@ -428,7 +428,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" tk.CODE scrapNum, tk.task_status taskStatus, dic.NAME taskStatusName, + bui.unit_id unitId, bui.unit_name unitName, + bpl.lot_id projectId, bpl.lot_name projectName, su.nick_name createBy, tk.create_time createTime, @@ -464,18 +466,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" WHERE sad.scrap_source IN ( '1', '2' ) AND tk.task_type IN ('20' , '21') - - AND (locate(#{keyword}, tk.create_by) > 0 - or locate(#{keyword}, tk.CODE) > 0 - or locate(#{keyword}, bui.unit_name) > 0 - or locate(#{keyword}, bpl.lot_name) > 0 - or locate(#{keyword}, tk1.CODE) > 0) + + AND (locate(#{keywords}, tk.create_by) > 0 + or locate(#{keywords}, tk.CODE) > 0 + or locate(#{keywords}, bui.unit_name) > 0 + or locate(#{keywords}, bpl.lot_name) > 0 + or locate(#{keywords}, tk1.CODE) > 0) and bui.unit_id = #{backUnit} - - and tk.task_status = #{repairStatus} + + and tk.task_status = #{taskStatus} and tk.task_id in #{taskIdList} @@ -483,14 +485,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and bpl.lot_id = #{backPro} + + and sad.scrap_source = #{scrapSource} + and mt1.type_id = #{type} and locate(#{backCode}, tk.code) > 0 - - and tk.create_time between #{params.beginTime} and #{params.endTime} + + and DATE(tk.create_time) between #{beginTime} and #{endTime} GROUP BY tk.CODE order by tk.create_time desc