mapper date时间修改。

dev_0531
kevin jiang 5 years ago
parent 0d6eb8ad03
commit 847ef92b2d

@ -275,8 +275,8 @@
SELECT
sum( negative_feedback_cnt ) AS delCusNum
FROM poi_customer_contact_data_stat
WHERE stat_time >= #{startDate}
AND stat_time <= #{endDate}
WHERE date(stat_time) >= #{startDate}
AND date(stat_time) <= #{endDate}
group by region_id
</select>
@ -284,8 +284,8 @@
SELECT
sum( negative_feedback_cnt ) AS delCusNum
FROM poi_customer_contact_data_stat
WHERE stat_time &gt;= #{startDate}
AND stat_time &lt;= #{endDate}
WHERE date(stat_time) &gt;= #{startDate}
AND date(stat_time) &lt;= #{endDate}
group by store_id
</select>
@ -293,10 +293,10 @@
SELECT count(t.customer_id) from op_seller_customer_relation t
WHERE t.store_id = #{storeId}
<if test="startDate != null">
and t.create_time &gt;= #{startDate}
and date(t.create_time) &gt;= #{startDate}
</if>
<if test="endDate != null">
and t.create_time &lt;= #{endDate}
and date(t.create_time) &lt;= #{endDate}
</if>
group by t.store_id
</select>
@ -308,10 +308,10 @@
AND t2.user_id = #{userId}
</if>
<if test="startDate != null">
and t1.create_time &gt;= #{startDate}
and date(t1.create_time) &gt;= #{startDate}
</if>
<if test="endDate != null">
and t1.create_time &lt;= #{endDate}
and date(t1.create_time) &lt;= #{endDate}
</if>
group by t1.user_id
</select>
@ -329,10 +329,10 @@
WHERE
t. store_id = #{storeId}
<if test="startDate != null">
and t.create_time &gt;= #{startDate}
and date(t.create_time) &gt;= #{startDate}
</if>
<if test="endDate != null">
and t.create_time &lt;= #{endDate}
and date(t.create_time) &lt;= #{endDate}
</if>
GROUP BY
t.user_id
@ -368,10 +368,10 @@
`op_seller_customer_relation` t2
where 1=1
<if test="startDate != null">
and t2.create_time &gt;= #{startDate}
and date(t2.create_time) &gt;= #{startDate}
</if>
<if test="endDate != null">
and t2.create_time &lt;= #{endDate}
and date(t2.create_time) &lt;= #{endDate}
</if>
GROUP BY
t2.store_id
@ -390,10 +390,10 @@
poi_store_staff t1, `op_seller_customer_relation` t2
where t1.id = t2.user_id
<if test="startDate != null">
and t2.create_time &gt;= #{startDate}
and date(t2.create_time) &gt;= #{startDate}
</if>
<if test="endDate != null">
and t2.create_time &lt;= #{endDate}
and date(t2.create_time) &lt;= #{endDate}
</if>
and t1.store_id = #{storeId}
and t1.type = 4

Loading…
Cancel
Save