|
|
@ -12,10 +12,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<result property="createBy" column="create_by" /> |
|
|
|
<result property="updateTime" column="update_time" /> |
|
|
|
<result property="updateBy" column="update_by" /> |
|
|
|
<result property="size" column="size" /> |
|
|
|
<result property="extension" column="extension" /> |
|
|
|
<result property="number" column="number" /> |
|
|
|
</resultMap> |
|
|
|
|
|
|
|
<sql id="selectDcFileDownloadVo"> |
|
|
|
select id, file_name, file_address, create_time, create_by, update_time, update_by from dc_file_download |
|
|
|
select id,number,size,extension, file_name, file_address, create_time, create_by, update_time, update_by from dc_file_download |
|
|
|
</sql> |
|
|
|
|
|
|
|
<select id="selectDcFileDownloadList" parameterType="DcFileDownload" resultMap="DcFileDownloadResult"> |
|
|
@ -41,6 +44,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="createBy != null">create_by,</if> |
|
|
|
<if test="updateTime != null">update_time,</if> |
|
|
|
<if test="updateBy != null">update_by,</if> |
|
|
|
<if test="size != null">size,</if> |
|
|
|
<if test="extension != null">extension,</if> |
|
|
|
</trim> |
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=","> |
|
|
|
<if test="fileName != null">#{fileName},</if> |
|
|
@ -49,6 +54,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="createBy != null">#{createBy},</if> |
|
|
|
<if test="updateTime != null">#{updateTime},</if> |
|
|
|
<if test="updateBy != null">#{updateBy},</if> |
|
|
|
<if test="size != null">#{size},</if> |
|
|
|
<if test="extension != null">#{extension},</if> |
|
|
|
</trim> |
|
|
|
</insert> |
|
|
|
|
|
|
@ -61,9 +68,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="createBy != null">create_by = #{createBy},</if> |
|
|
|
<if test="updateTime != null">update_time = #{updateTime},</if> |
|
|
|
<if test="updateBy != null">update_by = #{updateBy},</if> |
|
|
|
<if test="size != null">size = #{size},</if> |
|
|
|
<if test="extension != null">extension = #{extension},</if> |
|
|
|
</trim> |
|
|
|
where id = #{id} |
|
|
|
</update> |
|
|
|
<update id="downloadIncrease"> |
|
|
|
update dc_file_download set number=number+1 where id=#{id} |
|
|
|
</update> |
|
|
|
|
|
|
|
|
|
|
|
<delete id="deleteDcFileDownloadById" parameterType="Long"> |
|
|
|
delete from dc_file_download where id = #{id} |
|
|
|