From 7ce7861b02a6a4c4fe53d6292d3d216a65551371 Mon Sep 17 00:00:00 2001
From: 龚焕茏 <2842157468@qq.com>
Date: 星期二, 23 四月 2024 10:47:47 +0800
Subject: [PATCH] 合同导入模板

---
 ycl-server/src/main/resources/mapper/zgyw/TContractMapper.xml |   83 +----------------------------------------
 1 files changed, 2 insertions(+), 81 deletions(-)

diff --git a/ycl-server/src/main/resources/mapper/zgyw/TContractMapper.xml b/ycl-server/src/main/resources/mapper/zgyw/TContractMapper.xml
index 712d66b..18a9ccb 100644
--- a/ycl-server/src/main/resources/mapper/zgyw/TContractMapper.xml
+++ b/ycl-server/src/main/resources/mapper/zgyw/TContractMapper.xml
@@ -1,86 +1,7 @@
 <?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">
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.ycl.platform.mapper.TContractMapper">
-    
-    <resultMap type="com.ycl.platform.domain.entity.TContract" id="TContractResult">
-        <result property="id"    column="id"    />
-        <result property="companyId"    column="company_id"    />
-        <result property="companyName"    column="company_name"    />
-        <result property="deptId"    column="dept_id"    />
-        <result property="deptName"    column="dept_name"    />
-        <result property="detail"    column="detail"    />
-        <result property="startTime"    column="start_time"    />
-        <result property="endTime"    column="end_time"    />
-    </resultMap>
 
-    <sql id="selectTContractVo">
-        select id, company_id, company_name, dept_id, dept_name, detail ,start_time,end_time from t_contract
-    </sql>
-
-    <select id="selectTContractList" parameterType="com.ycl.platform.domain.entity.TContract" resultMap="TContractResult">
-        <include refid="selectTContractVo"/>
-        <where>  
-            <if test="companyId != null "> and company_id = #{companyId}</if>
-            <if test="companyName != null  and companyName != ''"> and company_name like concat('%', #{companyName}, '%')</if>
-            <if test="deptId != null "> and dept_id = #{deptId}</if>
-            <if test="deptName != null  and deptName != ''"> and dept_name like concat('%', #{deptName}, '%')</if>
-            <if test="detail != null  and detail != ''"> and detail = #{detail}</if>
-            <if test="startTime != null"> and start_time = #{startTime}</if>
-            <if test="endTime != null"> and end_time = #{endTime}</if>
-        </where>
-    </select>
-    
-    <select id="selectTContractById" parameterType="Long" resultMap="TContractResult">
-        <include refid="selectTContractVo"/>
-        where id = #{id}
-    </select>
-        
-    <insert id="insertTContract" parameterType="com.ycl.platform.domain.entity.TContract" useGeneratedKeys="true" keyProperty="id">
-        insert into t_contract
-        <trim prefix="(" suffix=")" suffixOverrides=",">
-            <if test="companyId != null">company_id,</if>
-            <if test="companyName != null">company_name,</if>
-            <if test="deptId != null">dept_id,</if>
-            <if test="deptName != null">dept_name,</if>
-            <if test="detail != null">detail,</if>
-            <if test="startTime != null">start_time,</if>
-            <if test="endTime != null">end_time,</if>
-         </trim>
-        <trim prefix="values (" suffix=")" suffixOverrides=",">
-            <if test="companyId != null">#{companyId},</if>
-            <if test="companyName != null">#{companyName},</if>
-            <if test="deptId != null">#{deptId},</if>
-            <if test="deptName != null">#{deptName},</if>
-            <if test="detail != null">#{detail},</if>
-            <if test="startTime != null">#{startTime},</if>
-            <if test="endTime != null">#{endTime},</if>
-         </trim>
-    </insert>
-
-    <update id="updateTContract" parameterType="com.ycl.platform.domain.entity.TContract">
-        update t_contract
-        <trim prefix="SET" suffixOverrides=",">
-            <if test="companyId != null">company_id = #{companyId},</if>
-            <if test="companyName != null">company_name = #{companyName},</if>
-            <if test="deptId != null">dept_id = #{deptId},</if>
-            <if test="deptName != null">dept_name = #{deptName},</if>
-            <if test="detail != null">detail = #{detail},</if>
-            <if test="startTime != null">start_time = #{startTime},</if>
-            <if test="endTime != null">end_time = #{endTime},</if>
-        </trim>
-        where id = #{id}
-    </update>
-
-    <delete id="deleteTContractById" parameterType="Long">
-        delete from t_contract where id = #{id}
-    </delete>
-
-    <delete id="deleteTContractByIds" parameterType="String">
-        delete from t_contract where id in 
-        <foreach item="id" collection="array" open="(" separator="," close=")">
-            #{id}
-        </foreach>
-    </delete>
 </mapper>
\ No newline at end of file

--
Gitblit v1.8.0