增加租户的功能

This commit is contained in:
季圣华
2019-03-19 23:11:38 +08:00
parent d845b9dfbe
commit 54bf489723
103 changed files with 23174 additions and 21773 deletions

View File

@@ -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.SerialNumberMapper">
<resultMap id="BaseResultMap" type="com.jsh.erp.datasource.entities.SerialNumber">
<!--
@@ -17,6 +17,7 @@
<result column="update_Time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="updater" jdbcType="BIGINT" property="updater" />
<result column="depothead_Id" jdbcType="BIGINT" property="depotheadId" />
<result column="tenant_id" jdbcType="BIGINT" property="tenantId" />
</resultMap>
<sql id="Example_Where_Clause">
<!--
@@ -90,7 +91,7 @@
This element is automatically generated by MyBatis Generator, do not modify.
-->
id, material_Id, serial_Number, is_Sell, remark, delete_Flag, create_Time, creator,
update_Time, updater,depothead_Id
update_Time, updater, depothead_Id, tenant_id
</sql>
<select id="selectByExample" parameterType="com.jsh.erp.datasource.entities.SerialNumberExample" resultMap="BaseResultMap">
<!--
@@ -146,11 +147,13 @@
insert into jsh_serial_number (id, material_Id, serial_Number,
is_Sell, remark, delete_Flag,
create_Time, creator, update_Time,
updater,depothead_Id)
updater, depothead_Id, tenant_id
)
values (#{id,jdbcType=BIGINT}, #{materialId,jdbcType=BIGINT}, #{serialNumber,jdbcType=VARCHAR},
#{isSell,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{deleteFlag,jdbcType=VARCHAR},
#{isSell,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{deleteFlag,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{creator,jdbcType=BIGINT}, #{updateTime,jdbcType=TIMESTAMP},
#{updater,jdbcType=BIGINT},#{depotheadId,jdbcType=BIGINT})
#{updater,jdbcType=BIGINT}, #{depotheadId,jdbcType=BIGINT}, #{tenantId,jdbcType=BIGINT}
)
</insert>
<insert id="insertSelective" parameterType="com.jsh.erp.datasource.entities.SerialNumber">
<!--
@@ -192,6 +195,9 @@
<if test="depotheadId != null">
depothead_Id,
</if>
<if test="tenantId != null">
tenant_id,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
@@ -227,6 +233,9 @@
<if test="depotheadId != null">
#{depotheadId,jdbcType=BIGINT},
</if>
<if test="tenantId != null">
#{tenantId,jdbcType=BIGINT},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.jsh.erp.datasource.entities.SerialNumberExample" resultType="java.lang.Integer">
@@ -279,6 +288,9 @@
<if test="record.depotheadId != null">
depothead_Id = #{record.depotheadId,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" />
@@ -300,7 +312,8 @@
creator = #{record.creator,jdbcType=BIGINT},
update_Time = #{record.updateTime,jdbcType=TIMESTAMP},
updater = #{record.updater,jdbcType=BIGINT},
depothead_Id = #{record.depotheadId,jdbcType=BIGINT}
depothead_Id = #{record.depotheadId,jdbcType=BIGINT},
tenant_id = #{record.tenantId,jdbcType=BIGINT}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
@@ -342,6 +355,9 @@
<if test="depotheadId != null">
depothead_Id = #{depotheadId,jdbcType=BIGINT},
</if>
<if test="tenantId != null">
tenant_id = #{tenantId,jdbcType=BIGINT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
@@ -360,7 +376,8 @@
creator = #{creator,jdbcType=BIGINT},
update_Time = #{updateTime,jdbcType=TIMESTAMP},
updater = #{updater,jdbcType=BIGINT},
depothead_Id = #{depotheadId,jdbcType=BIGINT}
depothead_Id = #{depotheadId,jdbcType=BIGINT},
tenant_id = #{tenantId,jdbcType=BIGINT}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>