From 3ee36c8c8827ddd14db370728d1d125682285a31 Mon Sep 17 00:00:00 2001
From: liurunyu <lry9898@163.com>
Date: 星期四, 16 十一月 2023 16:33:55 +0800
Subject: [PATCH] 前端提交的都是json数据,所以条件查询,保存,更新操作都注解上@RequestBody
---
pipIrr-platform/pipIrr-global/src/main/resources/mapper/BaBlockMapper.xml | 34 ++++++++++++++++++----------------
1 files changed, 18 insertions(+), 16 deletions(-)
diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/BaBlockMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/BaBlockMapper.xml
index 67ccd91..46df3bd 100644
--- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/BaBlockMapper.xml
+++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/BaBlockMapper.xml
@@ -63,22 +63,12 @@
</trim>
order by id DESC
<trim prefix="limit " >
- <if test="queryStart != null and queryCount != null">
- #{queryStart}, #{queryCount}
+ <if test="start != null and count != null">
+ #{start}, #{count}
</if>
</trim>
</select>
- <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
- <!--@mbg.generated-->
- delete from ba_block
- where id = #{id,jdbcType=BIGINT}
- </delete>
- <delete id="deleteLogicById" parameterType="java.lang.Long">
- <!--@mbg.generated-->
- update ba_block set deleted = 1
- where id = #{id,jdbcType=BIGINT}
- </delete>
<insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoBa.BaBlock">
<!--@mbg.generated-->
insert into ba_block (id, `name`, `header`, phone, area, color, deleted)
@@ -88,7 +78,7 @@
#{phone,jdbcType=VARCHAR},
#{area,jdbcType=INTEGER},
#{color,jdbcType=VARCHAR},
- #{deleted,jdbcType=TINYINT})
+ #{deleted,typeHandler=com.dy.common.mybatis.envm.EnumCodeTypeHandler, jdbcType=TINYINT})
</insert>
<insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoBa.BaBlock">
<!--@mbg.generated-->
@@ -136,7 +126,7 @@
#{color,jdbcType=VARCHAR},
</if>
<if test="deleted != null">
- #{deleted,jdbcType=TINYINT},
+ #{deleted,typeHandler=com.dy.common.mybatis.envm.EnumCodeTypeHandler, jdbcType=TINYINT},
</if>
</trim>
</insert>
@@ -160,7 +150,7 @@
color = #{color,jdbcType=VARCHAR},
</if>
<if test="deleted != null">
- color = #{deleted,jdbcType=TINYINT},
+ color = #{deleted,typeHandler=com.dy.common.mybatis.envm.EnumCodeTypeHandler, jdbcType=TINYINT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
@@ -173,7 +163,19 @@
phone = #{phone,jdbcType=VARCHAR},
area = #{area,jdbcType=INTEGER},
color = #{color,jdbcType=VARCHAR},
- deleted = #{deleted,jdbcType=TINYINT}
+ deleted = #{deleted,typeHandler=com.dy.common.mybatis.envm.EnumCodeTypeHandler, jdbcType=TINYINT}
where id = #{id,jdbcType=BIGINT}
</update>
+
+ <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
+ <!--@mbg.generated-->
+ delete from ba_block
+ where id = #{id,jdbcType=BIGINT}
+ </delete>
+ <delete id="deleteLogicById" parameterType="java.lang.Long">
+ <!--@mbg.generated-->
+ update ba_block set deleted = 1
+ where id = #{id,jdbcType=BIGINT}
+ </delete>
+
</mapper>
\ No newline at end of file
--
Gitblit v1.8.0