From e0ea1f4a21321f145be79556896181f23f22b708 Mon Sep 17 00:00:00 2001
From: gongzuming <gongzuming>
Date: 星期四, 29 八月 2024 09:33:16 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master' into master-v2
---
src/main/resources/mapper/content/FeedbackMapper.xml | 45 +++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 45 insertions(+), 0 deletions(-)
diff --git a/src/main/resources/mapper/content/FeedbackMapper.xml b/src/main/resources/mapper/content/FeedbackMapper.xml
new file mode 100644
index 0000000..67497d6
--- /dev/null
+++ b/src/main/resources/mapper/content/FeedbackMapper.xml
@@ -0,0 +1,45 @@
+<?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.mzl.flower.mapper.content.FeedbackMapper">
+ <select id="queryPage" resultType="com.mzl.flower.dto.response.content.FeedbackDTO">
+ SELECT
+ f.*,
+ c.`name` AS customerName,
+ u.tel AS customerTel
+ FROM
+ t_feedback f
+ LEFT JOIN t_user u ON f.user_id = u.id
+ LEFT JOIN t_customer_info c ON f.user_id = c.user_id
+ WHERE
+ f.deleted = 0
+ <if test="dto.id != null and dto.name != 0">
+ and f.id = #{dto.id}
+ </if>
+ <if test="dto.name != null and dto.name != ''">
+ and c.name like concat('%', #{dto.name}, '%')
+ </if>
+ <if test="dto.tel != null and dto.tel != ''">
+ and u.tel like concat('%', #{dto.tel}, '%')
+ </if>
+ <if test="dto.handled != null and dto.handled">
+ and f.handled = 1
+ </if>
+ <if test="dto.handled != null and !dto.handled">
+ and f.handled = 0
+ </if>
+ <if test="dto.userId != null and dto.userId != ''">
+ and f.user_id = #{dto.userId}
+ </if>
+ <if test="dto.createDateBegin!=null ">
+ <![CDATA[
+ AND f.create_time >= #{dto.createDateBegin}
+ ]]>
+ </if>
+ <if test="dto.createDateEnd!=null ">
+ <![CDATA[
+ AND f.create_time <= #{dto.createDateEnd}
+ ]]>
+ </if>
+ order by f.create_time desc
+ </select>
+</mapper>
\ No newline at end of file
--
Gitblit v1.9.3