Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
haoban3.0
haoban-manage3.0
Commits
4e787dd1
Commit
4e787dd1
authored
Nov 09, 2022
by
徐高华
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
群发
parent
f8c642ce
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
87 additions
and
0 deletions
+87
-0
TabHaobanMaterialContentMapper.xml
.../main/resources/mapper/TabHaobanMaterialContentMapper.xml
+87
-0
No files found.
haoban-manage3-service/src/main/resources/mapper/TabHaobanMaterialContentMapper.xml
0 → 100644
View file @
4e787dd1
<?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.gic.haoban.manage.service.dao.mapper.TabMaterialContentMapper"
>
<resultMap
type=
"com.gic.haoban.manage.service.entity.TabMaterialContent"
id=
"result-map-tabHaobanMaterialContent"
>
<result
column=
"material_id"
property=
"materialId"
/>
<result
column=
"material_type"
property=
"materialType"
/>
<result
column=
"wx_last_upload_time"
property=
"wxLastUploadTime"
/>
<result
column=
"media_id"
property=
"mediaId"
/>
<result
column=
"wx_enterprise_id"
property=
"wxEnterpriseId"
/>
<result
column=
"img_url"
property=
"imgUrl"
/>
<result
column=
"url_md5"
property=
"urlMd5"
/>
<result
column=
"status_flag"
property=
"statusFlag"
/>
<result
column=
"create_time"
property=
"createTime"
/>
<result
column=
"update_time"
property=
"updateTime"
/>
<result
column=
"media_type"
property=
"mediaType"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
material_id,
material_type,
wx_last_upload_time,
media_id,
wx_enterprise_id,
img_url,
url_md5,
status_flag,
create_time,
update_time , media_type
</sql>
<!-- ===================== 新增 ======================== -->
<insert
id=
"insert"
parameterType=
"com.gic.haoban.manage.service.entity.TabMaterialContent"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
<![CDATA[
INSERT INTO tab_haoban_material_content(
material_id,
material_type,
wx_last_upload_time,
media_id,
wx_enterprise_id,
img_url,
url_md5,
status_flag,
create_time,
update_time ,
media_type
)VALUES(
#{materialId,jdbcType=VARCHAR},
#{materialType,jdbcType=INTEGER},
#{wxLastUploadTime,jdbcType=TIMESTAMP},
#{mediaId,jdbcType=VARCHAR},
#{wxEnterpriseId,jdbcType=VARCHAR},
#{imgUrl,jdbcType=VARCHAR},
#{urlMd5,jdbcType=VARCHAR},
1,
now(),
now() , #{mediaType}
)
]]>
</insert>
<!-- ==================更新 ========== -->
<update
id=
"updateByPrimaryKey"
parameterType=
"com.gic.haoban.manage.service.entity.TabMaterialContent"
>
<![CDATA[
UPDATE tab_haoban_material_content SET
wx_last_upload_time=#{wxLastUploadTime,jdbcType=TIMESTAMP},
media_id=#{mediaId,jdbcType=VARCHAR},
wx_enterprise_id=#{wxEnterpriseId,jdbcType=VARCHAR},
status_flag=#{statusFlag,jdbcType=INTEGER},
update_time= now()
where material_id = #{materialId}
]]>
</update>
<!-- ============ 查询=============-->
<select
id=
"selectById"
parameterType=
"String"
resultMap=
"result-map-tabHaobanMaterialContent"
>
SELECT
<include
refid=
"Base_Column_List"
/>
FROM tab_haoban_material_content WHERE material_id=#{id} and status_flag = 1
</select>
<select
id=
"selectByUrl"
resultMap=
"result-map-tabHaobanMaterialContent"
>
SELECT
<include
refid=
"Base_Column_List"
/>
FROM tab_haoban_material_content WHERE wx_enterprise_id=#{wxEnterpriseId} and url_md5=#{urlMd5} and status_flag = 1
</select>
</mapper>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment