From 2a64b537e8e3bce9ce030585a3da17d48379c0ad Mon Sep 17 00:00:00 2001
From: sfd <sun.sunshine@163.com>
Date: 星期一, 26 五月 2025 15:04:45 +0800
Subject: [PATCH] 修改json类型转换错误
---
aps-modules/aps-core/src/main/resources/mapper/core/ApsPlate/ApsPlatePlanMapper.xml | 22 +++++++++++++---------
1 files changed, 13 insertions(+), 9 deletions(-)
diff --git a/aps-modules/aps-core/src/main/resources/mapper/core/ApsPlate/ApsPlatePlanMapper.xml b/aps-modules/aps-core/src/main/resources/mapper/core/ApsPlate/ApsPlatePlanMapper.xml
index 3a38efa..c075b48 100644
--- a/aps-modules/aps-core/src/main/resources/mapper/core/ApsPlate/ApsPlatePlanMapper.xml
+++ b/aps-modules/aps-core/src/main/resources/mapper/core/ApsPlate/ApsPlatePlanMapper.xml
@@ -277,15 +277,19 @@
</update>
<select id="selectPlatePlanByPlantMajor" parameterType="com.aps.core.domain.ApsPlate.ApsPlatePlan" resultMap="ApsPlatePlanResult">
- select id,document_number,main_part_number,item_number,plant,professional_affiliation,production_quantity,require_id,
- unmatched_quantity,version, production_base,plan_end_day,order_create_time,low_order_code
- from aps_plate_plan
- <where>
- <if test="plant != null "> and plant = #{plant} </if>
- <if test="professionalAffiliation != null "> and professional_affiliation = 'main' </if>
- and del_flag='0'
- </where>
- order by document_number asc,id asc
+ with rd as (
+ select doc_no,require_date from aps_plate_require_date where del_flag=0
+ )
+ select
+ app.id,app.document_number,app.main_part_number,app.item_number,app.plant,app.professional_affiliation,app.production_quantity,app.require_id,
+ app.unmatched_quantity,app.version, app.production_base,app.order_create_time,app.low_order_code,
+ app.plan_end_day as orign_end_day,
+ COALESCE(rd.require_date,app.plan_end_day) as plan_end_day
+ from aps_plate_plan as app
+ left join rd on app.document_number=rd.doc_no
+ where app.del_flag='0' and app.professional_affiliation = 'main'
+ <if test="plant != null "> and plant = #{plant} </if>
+ order by document_number ,id
</select>
<select id="selectUnMatchPlateSubPlan" parameterType="com.aps.core.domain.ApsPlate.ApsPlatePlan" resultMap="ApsPlatePlanResult">
--
Gitblit v1.9.3