|
|
|
@ -3,46 +3,46 @@
|
|
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
|
|
<mapper namespace="com.ruoyi.zongzhi.mapper.TcQlzxxdsjMapper">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<resultMap type="TcQlzxxdsj" id="TcQlzxxdsjResult">
|
|
|
|
|
<result property="id" column="id" />
|
|
|
|
|
<result property="areaId" column="area_id" />
|
|
|
|
|
<result property="type" column="type" />
|
|
|
|
|
<result property="yearMonth" column="year_month" />
|
|
|
|
|
<result property="monthYear" column="month_year" />
|
|
|
|
|
<result property="count" column="count" />
|
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
|
|
<sql id="selectTcQlzxxdsjVo">
|
|
|
|
|
select id, area_id, type, year_month, count from tc_qlzxxdsj
|
|
|
|
|
select id, area_id, type, month_year, count from tc_qlzxxdsj
|
|
|
|
|
</sql>
|
|
|
|
|
|
|
|
|
|
<select id="selectTcQlzxxdsjList" parameterType="TcQlzxxdsj" resultMap="TcQlzxxdsjResult">
|
|
|
|
|
<include refid="selectTcQlzxxdsjVo"/>
|
|
|
|
|
<where>
|
|
|
|
|
<where>
|
|
|
|
|
<if test="areaId != null "> and area_id = #{areaId}</if>
|
|
|
|
|
<if test="type != null "> and type = #{type}</if>
|
|
|
|
|
<if test="yearMonth != null "> and year_month = #{yearMonth}</if>
|
|
|
|
|
<if test="monthYear != null "> and month_year = #{monthYear}</if>
|
|
|
|
|
<if test="count != null "> and count = #{count}</if>
|
|
|
|
|
</where>
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectTcQlzxxdsjById" parameterType="Long" resultMap="TcQlzxxdsjResult">
|
|
|
|
|
<include refid="selectTcQlzxxdsjVo"/>
|
|
|
|
|
where id = #{id}
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<insert id="insertTcQlzxxdsj" parameterType="TcQlzxxdsj" useGeneratedKeys="true" keyProperty="id">
|
|
|
|
|
insert into tc_qlzxxdsj
|
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
|
<if test="areaId != null">area_id,</if>
|
|
|
|
|
<if test="type != null">type,</if>
|
|
|
|
|
<if test="yearMonth != null">year_month,</if>
|
|
|
|
|
<if test="monthYear != null">month_year,</if>
|
|
|
|
|
<if test="count != null">count,</if>
|
|
|
|
|
</trim>
|
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
|
<if test="areaId != null">#{areaId},</if>
|
|
|
|
|
<if test="type != null">#{type},</if>
|
|
|
|
|
<if test="yearMonth != null">#{yearMonth},</if>
|
|
|
|
|
<if test="monthYear != null">#{monthYear},</if>
|
|
|
|
|
<if test="count != null">#{count},</if>
|
|
|
|
|
</trim>
|
|
|
|
|
</insert>
|
|
|
|
@ -52,7 +52,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
|
|
<if test="areaId != null">area_id = #{areaId},</if>
|
|
|
|
|
<if test="type != null">type = #{type},</if>
|
|
|
|
|
<if test="yearMonth != null">year_month = #{yearMonth},</if>
|
|
|
|
|
<if test="monthYear != null">month_year = #{monthYear},</if>
|
|
|
|
|
<if test="count != null">count = #{count},</if>
|
|
|
|
|
</trim>
|
|
|
|
|
where id = #{id}
|
|
|
|
@ -63,7 +63,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
</delete>
|
|
|
|
|
|
|
|
|
|
<delete id="deleteTcQlzxxdsjByIds" parameterType="String">
|
|
|
|
|
delete from tc_qlzxxdsj where id in
|
|
|
|
|
delete from tc_qlzxxdsj where id in
|
|
|
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
|
|
|
#{id}
|
|
|
|
|
</foreach>
|
|
|
|
|