|
@@ -131,13 +131,8 @@
|
131
|
131
|
</select>
|
132
|
132
|
<select id="getNewCustomerDetail" resultType="com.yunzhi.marketing.xlk.vo.CustomerDetailVO">
|
133
|
133
|
SELECT
|
134
|
|
- <if test="params.type == 'day''">
|
135
|
|
- date_format( t.create_date, '%d' ) as coordinate,
|
136
|
|
- </if>
|
137
|
|
- <if test="params.type == 'month''">
|
138
|
|
- date_format( t.create_date, '%m' ) as coordinate,
|
139
|
|
- </if>
|
140
|
|
- COUNT(1) as customerNum
|
|
134
|
+ date_format( t.create_date, '%Y-%m-%d' ) as coordinate,
|
|
135
|
+ COUNT(1) as customerNum
|
141
|
136
|
FROM
|
142
|
137
|
xlk_channel_customer t
|
143
|
138
|
WHERE t.channel_id = #{params.channelId}
|
|
@@ -149,22 +144,17 @@
|
149
|
144
|
<if test="params.startDate == null or params.endDate == null">
|
150
|
145
|
AND t.create_date BETWEEN DATE_SUB(now(),INTERVAL 7 DAY) and now()
|
151
|
146
|
</if>
|
152
|
|
- <if test="params.type == 'day''">
|
|
147
|
+ <if test="params.type == 'day'">
|
153
|
148
|
group by date_format( t.create_date, '%Y-%m-%d' )
|
154
|
149
|
</if>
|
155
|
|
- <if test="params.type == 'month''">
|
|
150
|
+ <if test="params.type == 'month'">
|
156
|
151
|
group by date_format( t.create_date, '%Y-%m' )
|
157
|
152
|
</if>
|
158
|
153
|
</select>
|
159
|
154
|
<select id="getSuccessCustomerDetail" resultType="com.yunzhi.marketing.xlk.vo.CustomerDetailVO">
|
160
|
155
|
SELECT
|
161
|
|
- <if test="params.type == 'day''">
|
162
|
|
- date_format( t.create_date, '%d' ) as coordinate,
|
163
|
|
- </if>
|
164
|
|
- <if test="params.type == 'month''">
|
165
|
|
- date_format( t.create_date, '%m' ) as coordinate,
|
166
|
|
- </if>
|
167
|
|
- COUNT(1) as customerNum
|
|
156
|
+ date_format( t.create_date, '%%Y-%m-%d' ) as coordinate,
|
|
157
|
+ COUNT(1) as customerNum
|
168
|
158
|
FROM
|
169
|
159
|
xlk_channel_customer t
|
170
|
160
|
LEFT join ta_recommend_customer r on t.customer_id = r.customer_id
|
|
@@ -177,10 +167,10 @@
|
177
|
167
|
<if test="params.startDate == null or params.endDate == null">
|
178
|
168
|
AND t.create_date BETWEEN DATE_SUB(now(),INTERVAL 7 DAY) and now()
|
179
|
169
|
</if>
|
180
|
|
- <if test="params.type == 'day''">
|
|
170
|
+ <if test="params.type == 'day'">
|
181
|
171
|
group by date_format( t.create_date, '%Y-%m-%d' )
|
182
|
172
|
</if>
|
183
|
|
- <if test="params.type == 'month''">
|
|
173
|
+ <if test="params.type == 'month'">
|
184
|
174
|
group by date_format( t.create_date, '%Y-%m' )
|
185
|
175
|
</if>
|
186
|
176
|
</select>
|