增加租户的功能
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.jsh.erp.datasource.mappers.MaterialCategoryMapper">
|
||||
<resultMap id="BaseResultMap" type="com.jsh.erp.datasource.entities.MaterialCategory">
|
||||
<!--
|
||||
@@ -18,6 +18,7 @@
|
||||
<result column="creator" jdbcType="BIGINT" property="creator" />
|
||||
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
||||
<result column="updater" jdbcType="BIGINT" property="updater" />
|
||||
<result column="tenant_id" jdbcType="BIGINT" property="tenantId" />
|
||||
</resultMap>
|
||||
<sql id="Example_Where_Clause">
|
||||
<!--
|
||||
@@ -91,7 +92,7 @@
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
Id, Name, CategoryLevel, ParentId, sort, status, serial_no, remark, create_time,
|
||||
creator, update_time, updater
|
||||
creator, update_time, updater, tenant_id
|
||||
</sql>
|
||||
<select id="selectByExample" parameterType="com.jsh.erp.datasource.entities.MaterialCategoryExample" resultMap="BaseResultMap">
|
||||
<!--
|
||||
@@ -147,13 +148,13 @@
|
||||
insert into jsh_materialcategory (Id, Name, CategoryLevel,
|
||||
ParentId, sort, status,
|
||||
serial_no, remark, create_time,
|
||||
creator, update_time, updater
|
||||
)
|
||||
creator, update_time, updater,
|
||||
tenant_id)
|
||||
values (#{id,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, #{categorylevel,jdbcType=SMALLINT},
|
||||
#{parentid,jdbcType=BIGINT}, #{sort,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR},
|
||||
#{serialNo,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
|
||||
#{creator,jdbcType=BIGINT}, #{updateTime,jdbcType=TIMESTAMP}, #{updater,jdbcType=BIGINT}
|
||||
)
|
||||
#{creator,jdbcType=BIGINT}, #{updateTime,jdbcType=TIMESTAMP}, #{updater,jdbcType=BIGINT},
|
||||
#{tenantId,jdbcType=BIGINT})
|
||||
</insert>
|
||||
<insert id="insertSelective" parameterType="com.jsh.erp.datasource.entities.MaterialCategory">
|
||||
<!--
|
||||
@@ -198,6 +199,9 @@
|
||||
<if test="updater != null">
|
||||
updater,
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
tenant_id,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">
|
||||
@@ -236,6 +240,9 @@
|
||||
<if test="updater != null">
|
||||
#{updater,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
#{tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
<select id="countByExample" parameterType="com.jsh.erp.datasource.entities.MaterialCategoryExample" resultType="java.lang.Integer">
|
||||
@@ -291,6 +298,9 @@
|
||||
<if test="record.updater != null">
|
||||
updater = #{record.updater,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="record.tenantId != null">
|
||||
tenant_id = #{record.tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
</set>
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
@@ -313,7 +323,8 @@
|
||||
create_time = #{record.createTime,jdbcType=TIMESTAMP},
|
||||
creator = #{record.creator,jdbcType=BIGINT},
|
||||
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
|
||||
updater = #{record.updater,jdbcType=BIGINT}
|
||||
updater = #{record.updater,jdbcType=BIGINT},
|
||||
tenant_id = #{record.tenantId,jdbcType=BIGINT}
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
@@ -358,6 +369,9 @@
|
||||
<if test="updater != null">
|
||||
updater = #{updater,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
tenant_id = #{tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
</set>
|
||||
where Id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
@@ -377,7 +391,8 @@
|
||||
create_time = #{createTime,jdbcType=TIMESTAMP},
|
||||
creator = #{creator,jdbcType=BIGINT},
|
||||
update_time = #{updateTime,jdbcType=TIMESTAMP},
|
||||
updater = #{updater,jdbcType=BIGINT}
|
||||
updater = #{updater,jdbcType=BIGINT},
|
||||
tenant_id = #{tenantId,jdbcType=BIGINT}
|
||||
where Id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user