From 591e3b8a10ed15023f3ad9e5a72a887ef89b0bb2 Mon Sep 17 00:00:00 2001 From: 刘小明 <liuxm_a@163.com> Date: 星期一, 26 八月 2024 20:47:46 +0800 Subject: [PATCH] 修改判空方式 --- pms-parent/pms-global/src/main/resources/mapper/PrScheduleRelMapper.xml | 34 +++++++++++++++++----------------- 1 files changed, 17 insertions(+), 17 deletions(-) diff --git a/pms-parent/pms-global/src/main/resources/mapper/PrScheduleRelMapper.xml b/pms-parent/pms-global/src/main/resources/mapper/PrScheduleRelMapper.xml index ef2a29f..cff337a 100644 --- a/pms-parent/pms-global/src/main/resources/mapper/PrScheduleRelMapper.xml +++ b/pms-parent/pms-global/src/main/resources/mapper/PrScheduleRelMapper.xml @@ -46,42 +46,42 @@ <!--@mbg.generated--> insert into pr_schedule_rel <trim prefix="(" suffix=")" suffixOverrides=","> - <if test="id != null"> + <if test="id != null and id !=''"> id, </if> - <if test="scheduleId != null"> + <if test="scheduleId!= null and scheduleId !=''"> schedule_id, </if> - <if test="planId != null"> + <if test="planId != null and planId !=''"> plan_id, </if> - <if test="nodeId != null"> + <if test="nodeId!= null and nodeId !=''"> node_id, </if> - <if test="stationId != null"> + <if test="stationId != null and stationId !=''"> station_id, </if> - <if test="workDetails != null"> + <if test="workDetails!= null and workDetails !=''"> work_details, </if> </trim> <trim prefix="values (" suffix=")" suffixOverrides=","> - <if test="id != null"> + <if test="id != null and id !=''"> #{id,jdbcType=BIGINT}, </if> - <if test="scheduleId != null"> + <if test="scheduleId!= null and scheduleId !=''"> #{scheduleId,jdbcType=BIGINT}, </if> - <if test="planId != null"> + <if test="planId != null and planId !=''"> #{planId,jdbcType=BIGINT}, </if> - <if test="nodeId != null"> + <if test="nodeId!= null and nodeId !=''"> #{nodeId,jdbcType=BIGINT}, </if> - <if test="stationId != null"> + <if test="stationId != null and stationId !=''"> #{stationId,jdbcType=BIGINT}, </if> - <if test="workDetails != null"> + <if test="workDetails!= null and workDetails !=''"> #{workDetails,jdbcType=VARCHAR}, </if> </trim> @@ -90,19 +90,19 @@ <!--@mbg.generated--> update pr_schedule_rel <set> - <if test="scheduleId != null"> + <if test="scheduleId!= null and scheduleId !=''"> schedule_id = #{scheduleId,jdbcType=BIGINT}, </if> - <if test="planId != null"> + <if test="planId != null and planId !=''"> plan_id = #{planId,jdbcType=BIGINT}, </if> - <if test="nodeId != null"> + <if test="nodeId!= null and nodeId !=''"> node_id = #{nodeId,jdbcType=BIGINT}, </if> - <if test="stationId != null"> + <if test="stationId != null and stationId !=''"> station_id = #{stationId,jdbcType=BIGINT}, </if> - <if test="workDetails != null"> + <if test="workDetails!= null and workDetails !=''"> work_details = #{workDetails,jdbcType=VARCHAR}, </if> </set> -- Gitblit v1.8.0