linwei
2024-02-03 b87c9800541483108a40804c39be99f02a073e12
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<?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="org.springblade.modules.task.mapper.TaskLabelReportingEventMapper">
 
    <!-- 通用查询映射结果 -->
    <resultMap id="taskLabelReportingEventResultMap" type="org.springblade.modules.task.entity.TaskLabelReportingEventEntity">
        <result property="id"    column="id"    />
        <result property="taskId"    column="task_id"    />
        <result property="placeId"    column="place_id"    />
        <result property="districtName"    column="district_name"    />
        <result property="happenTime"    column="happen_time"    />
        <result property="userId"    column="user_id"    />
        <result property="owner"    column="owner"    />
        <result property="phoneNumber"    column="phone_number"    />
        <result property="imageUrls"    column="image_urls"    />
        <result property="localtion"    column="localtion"    />
        <result property="eventType"    column="event_type"    />
        <result property="confirmFlag"    column="confirm_flag"    />
        <result property="confirmUserId"    column="confirm_user_id"    />
        <result property="confirmTime"    column="confirm_time"    />
        <result property="confirmNotion"    column="confirm_notion"    />
        <result property="transactionObjectTel"    column="transaction_object_tel"    />
        <result property="transactionMoney"    column="transaction_money"    />
        <result property="goodsNums"    column="goods_nums"    />
        <result property="goodsImageUrls"    column="goods_image_urls"    />
        <result property="transactionObject"    column="transaction_object"    />
        <result property="transactionProcess"    column="transaction_process"    />
        <result property="labelName"    column="label_name"    />
        <result property="source"    column="source"    />
        <result property="createTime"    column="create_time"    />
        <result property="createUser"    column="create_user"    />
        <result property="updateTime"    column="update_time"    />
        <result property="updateUser"    column="update_user"    />
        <result property="isDeleted"    column="is_deleted"    />
        <result property="idCard"    column="id_card"    />
        <result property="receiptUrls"    column="receipt_urls"    />
    </resultMap>
 
 
    <select id="selectTaskLabelReportingEventPage" resultMap="taskLabelReportingEventResultMap">
        select * from jczz_task_label_reporting_event where is_deleted = 0
        <if test="taskLabelReportingEvent.userId != null and taskLabelReportingEvent.userId != ''">
            AND user_id = #{taskLabelReportingEvent.userId}
        </if>
        <if test="taskLabelReportingEvent.eventType != null and taskLabelReportingEvent.eventType != ''">
            AND event_type = #{taskLabelReportingEvent.eventType}
        </if>
    </select>
 
 
    <resultMap type="org.springblade.modules.task.dto.TaskLabelReportingEventDTO" id="TaskLabelReportingEventDTOResult">
        <result property="id"    column="id"    />
        <result property="taskId"    column="task_id"    />
        <result property="placeId"    column="place_id"    />
        <result property="districtName"    column="district_name"    />
        <result property="happenTime"    column="happen_time"    />
        <result property="userId"    column="user_id"    />
        <result property="owner"    column="owner"    />
        <result property="phoneNumber"    column="phone_number"    />
        <result property="imageUrls"    column="image_urls"    />
        <result property="localtion"    column="localtion"    />
        <result property="eventType"    column="event_type"    />
        <result property="confirmFlag"    column="confirm_flag"    />
        <result property="confirmUserId"    column="confirm_user_id"    />
        <result property="confirmTime"    column="confirm_time"    />
        <result property="confirmNotion"    column="confirm_notion"    />
        <result property="transactionObjectTel"    column="transaction_object_tel"    />
        <result property="transactionMoney"    column="transaction_money"    />
        <result property="goodsNums"    column="goods_nums"    />
        <result property="goodsImageUrls"    column="goods_image_urls"    />
        <result property="transactionObject"    column="transaction_object"    />
        <result property="transactionProcess"    column="transaction_process"    />
        <result property="labelName"    column="label_name"    />
        <result property="source"    column="source"    />
        <result property="createTime"    column="create_time"    />
        <result property="createUser"    column="create_user"    />
        <result property="updateTime"    column="update_time"    />
        <result property="updateUser"    column="update_user"    />
        <result property="isDeleted"    column="is_deleted"    />
        <result property="idCard"    column="id_card"    />
        <result property="receiptUrls"    column="receipt_urls"    />
    </resultMap>
 
    <sql id="selectTaskLabelReportingEvent">
        select
            id,
            task_id,
            place_id,
            district_name,
            happen_time,
            user_id,
            owner,
            phone_number,
            image_urls,
            localtion,
            event_type,
            confirm_flag,
            confirm_user_id,
            confirm_time,
            confirm_notion,
            transaction_object_tel,
            transaction_money,
            goods_nums,
            goods_image_urls,
            transaction_object,
            transaction_process,
            label_name,
            source,
            create_time,
            create_user,
            update_time,
            update_user,
            is_deleted,
            id_card,
            receipt_urls
        from
            jczz_task_label_reporting_event
    </sql>
 
    <select id="selectTaskLabelReportingEventById" parameterType="long" resultMap="TaskLabelReportingEventDTOResult">
        <include refid="selectTaskLabelReportingEvent"/>
        where
        id = #{id}
    </select>
 
    <select id="selectTaskLabelReportingEventList" parameterType="org.springblade.modules.task.dto.TaskLabelReportingEventDTO" resultMap="TaskLabelReportingEventDTOResult">
        <include refid="selectTaskLabelReportingEvent"/>
        <where>
            <if test="id != null "> and id = #{id}</if>
            <if test="taskId != null "> and task_id = #{taskId}</if>
            <if test="placeId != null "> and place_id = #{placeId}</if>
            <if test="districtName != null  and districtName != ''"> and district_name = #{districtName}</if>
            <if test="happenTime != null "> and happen_time = #{happenTime}</if>
            <if test="userId != null "> and user_id = #{userId}</if>
            <if test="owner != null  and owner != ''"> and owner = #{owner}</if>
            <if test="phoneNumber != null  and phoneNumber != ''"> and phone_number = #{phoneNumber}</if>
            <if test="imageUrls != null  and imageUrls != ''"> and image_urls = #{imageUrls}</if>
            <if test="localtion != null  and localtion != ''"> and localtion = #{localtion}</if>
            <if test="eventType != null  and eventType != ''"> and event_type = #{eventType}</if>
            <if test="confirmFlag != null  and confirmFlag != ''"> and confirm_flag = #{confirmFlag}</if>
            <if test="confirmUserId != null "> and confirm_user_id = #{confirmUserId}</if>
            <if test="confirmTime != null "> and confirm_time = #{confirmTime}</if>
            <if test="confirmNotion != null  and confirmNotion != ''"> and confirm_notion = #{confirmNotion}</if>
            <if test="transactionObjectTel != null  and transactionObjectTel != ''"> and transaction_object_tel = #{transactionObjectTel}</if>
            <if test="transactionMoney != null "> and transaction_money = #{transactionMoney}</if>
            <if test="goodsNums != null "> and goods_nums = #{goodsNums}</if>
            <if test="goodsImageUrls != null  and goodsImageUrls != ''"> and goods_image_urls = #{goodsImageUrls}</if>
            <if test="transactionObject != null  and transactionObject != ''"> and transaction_object = #{transactionObject}</if>
            <if test="transactionProcess != null  and transactionProcess != ''"> and transaction_process = #{transactionProcess}</if>
            <if test="labelName != null  and labelName != ''"> and label_name = #{labelName}</if>
            <if test="source != null "> and source = #{source}</if>
            <if test="createTime != null "> and create_time = #{createTime}</if>
            <if test="createUser != null "> and create_user = #{createUser}</if>
            <if test="updateTime != null "> and update_time = #{updateTime}</if>
            <if test="updateUser != null "> and update_user = #{updateUser}</if>
            <if test="isDeleted != null "> and is_deleted = #{isDeleted}</if>
            <if test="idCard != null  and idCard != ''"> and id_card = #{idCard}</if>
            <if test="receiptUrls != null  and receiptUrls != ''"> and receipt_urls = #{receiptUrls}</if>
        </where>
    </select>
 
 
</mapper>