OperationCustomerMapper.xml
1.77 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
<?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.OperationCustomerMapper">
<resultMap id="BaseResultMap" type="cn.com.glsx.entmicro.entity.OperationCustomer">
<!--
WARNING - @mbg.generated
-->
<id column="id" jdbcType="INTEGER" property="id" />
<result column="code_state" jdbcType="VARCHAR" property="codeState" />
<result column="operation_id" jdbcType="VARCHAR" property="operationId" />
<result column="merchant_id" jdbcType="INTEGER" property="merchantId" />
<result column="customer_phone" jdbcType="VARCHAR" property="customerPhone" />
<result column="order_id" jdbcType="VARCHAR" property="orderId" />
<result column="del_flag" jdbcType="INTEGER" property="delFlag" />
<result column="created_time" jdbcType="TIMESTAMP" property="createdTime" />
<result column="created_by" jdbcType="INTEGER" property="createdBy" />
<result column="updated_time" jdbcType="TIMESTAMP" property="updatedTime" />
<result column="updated_by" jdbcType="INTEGER" property="updatedBy" />
<result column="business_uuid" jdbcType="VARCHAR" property="businessUuid" />
</resultMap>
<sql id="Base_Column_List">
<!--
WARNING - @mbg.generated
-->
id, operation_id, code_state, merchant_id, customer_phone, order_id, del_flag, created_time, created_by,
updated_time, updated_by
</sql>
<select id= "getOperationCustomer" resultMap="BaseResultMap">
select t1.customer_phone,
t2.business_uuid
from scrm_operation_customer t1
left join scrm_operation_config t2 on t1.operation_id = t2.id
where t1.code_state = #{codeState}
group by t1.code_state
</select>
</mapper>