DracImConfigMapper.xml
4.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
<?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="cn.com.glsx.entmicro.mapper.DracImConfigMapper">
<resultMap id="BaseResultMap" type="cn.com.glsx.entmicro.entity.DracImConfig">
<!--
WARNING - @mbg.generated
-->
<id column="id" jdbcType="INTEGER" property="id"/>
<result column="merchant_id" jdbcType="INTEGER" property="merchantId"/>
<result column="config_type" jdbcType="INTEGER" property="configType"/>
<result column="staff_ids" jdbcType="VARCHAR" property="staffIds"/>
<result column="start_time" jdbcType="TIMESTAMP" property="startTime"/>
<result column="end_time" jdbcType="TIMESTAMP" property="endTime"/>
<result column="template_id" jdbcType="INTEGER" property="templateId"/>
<result column="marketing_id" jdbcType="INTEGER" property="marketingId"/>
<result column="marketing_type" jdbcType="INTEGER" property="marketingType"/>
<result column="marketing_url" jdbcType="VARCHAR" property="marketingUrl"/>
<result column="del_flag" jdbcType="INTEGER" property="delFlag"/>
<result column="created_by" jdbcType="INTEGER" property="createdBy"/>
<result column="created_time" jdbcType="TIMESTAMP" property="createdTime"/>
<result column="updated_by" jdbcType="INTEGER" property="updatedBy"/>
<result column="updated_time" jdbcType="TIMESTAMP" property="updatedTime"/>
<result column="content" jdbcType="LONGVARCHAR" property="content"/>
</resultMap>
<resultMap id="resultMap" type="cn.com.glsx.entmicro.model.response.DracImConfigResponse">
<!--
WARNING - @mbg.generated
-->
<id column="id" jdbcType="INTEGER" property="id"/>
<result column="merchant_id" jdbcType="INTEGER" property="merchantId"/>
<result column="config_type" jdbcType="INTEGER" property="configType"/>
<result column="staff_ids" jdbcType="VARCHAR" property="staffIds"/>
<result column="start_time" jdbcType="TIMESTAMP" property="startTime"/>
<result column="end_time" jdbcType="TIMESTAMP" property="endTime"/>
<result column="template_id" jdbcType="INTEGER" property="templateId"/>
<result column="marketing_id" jdbcType="INTEGER" property="marketingId"/>
<result column="marketing_type" jdbcType="INTEGER" property="marketingType"/>
<result column="marketing_url" jdbcType="VARCHAR" property="marketingUrl"/>
<result column="content" jdbcType="LONGVARCHAR" property="content"/>
<result column="del_flag" jdbcType="INTEGER" property="delFlag"/>
<result column="tagging" jdbcType="VARCHAR" property="tagging"/>
<result column="auto_welcome" jdbcType="VARCHAR" property="autoWelcome"/>
<result column="welcome_json" jdbcType="VARCHAR" property="welcomeJson"/>
</resultMap>
<sql id="Base_Column_List">
<!--
WARNING - @mbg.generated
-->
id, merchant_id, config_type, staff_ids, start_time, end_time, template_id, marketing_id,
marketing_type, marketing_url, del_flag, created_by, created_time, updated_by, updated_time
</sql>
<sql id="Blob_Column_List">
<!--
WARNING - @mbg.generated
-->
content
</sql>
<select id="findByTypeAndMerchantId" resultMap="resultMap">
select * from drac_im_config where 1=1 AND config_type in (1,2)
<if test="dracImConfigRequest.configType != null">
and config_type=#{dracImConfigRequest.configType}
</if>
<if test="dracImConfigRequest.merchantId != null">
and merchant_id=
#{dracImConfigRequest.merchantId}
</if>
</select>
<select id="findByTypeAndMerchantIds" resultMap="resultMap">
select * from drac_im_config where 1=1
<if test="dracImConfigRequest.configType != null">
and config_type=#{dracImConfigRequest.configType}
</if>
<if test="dracImConfigRequest.merchantId != null">
and merchant_id=
#{dracImConfigRequest.merchantId}
</if>
</select>
</mapper>