weiximei 6 лет назад
Родитель
Сommit
4af3b7b909

+ 27
- 5
CODE/smart-community/app-api/src/main/java/com/community/huiju/model/TpMessage.java Просмотреть файл

@@ -40,7 +40,13 @@ public class TpMessage {
40 40
     private Date updateDate;
41 41
 
42 42
     /** 缴费项ID **/
43
-    private Integer commonId;
43
+    private Integer billId;
44
+
45
+    /** 活动Id **/
46
+    private Integer activityId;
47
+
48
+    /** 公告Id **/
49
+    private Integer announcementId;
44 50
     
45 51
     /**
46 52
      * 工单状态
@@ -261,11 +267,27 @@ public class TpMessage {
261 267
         this.messageIconTitle = messageIconTitle;
262 268
     }
263 269
 
264
-    public Integer getCommonId() {
265
-        return commonId;
270
+    public Integer getBillId() {
271
+        return billId;
272
+    }
273
+
274
+    public void setBillId(Integer billId) {
275
+        this.billId = billId;
276
+    }
277
+
278
+    public Integer getActivityId() {
279
+        return activityId;
280
+    }
281
+
282
+    public void setActivityId(Integer activityId) {
283
+        this.activityId = activityId;
284
+    }
285
+
286
+    public Integer getAnnouncementId() {
287
+        return announcementId;
266 288
     }
267 289
 
268
-    public void setCommonId(Integer commonId) {
269
-        this.commonId = commonId;
290
+    public void setAnnouncementId(Integer announcementId) {
291
+        this.announcementId = announcementId;
270 292
     }
271 293
 }

+ 53
- 35
CODE/smart-community/app-api/src/main/resources/mapper/TpMessageMapper.xml Просмотреть файл

@@ -3,7 +3,7 @@
3 3
 <mapper namespace="com.community.huiju.dao.TpMessageMapper" >
4 4
   <resultMap id="BaseResultMap" type="com.community.huiju.model.TpMessage" >
5 5
     <id column="id" property="id" jdbcType="INTEGER" />
6
-    <id column="ticket_id" property="ticketId" jdbcType="INTEGER" />
6
+    <result column="ticket_id" property="ticketId" jdbcType="INTEGER" />
7 7
     <result column="community_id" property="communityId" jdbcType="INTEGER" />
8 8
     <result column="message_type" property="messageType" jdbcType="CHAR" />
9 9
     <result column="advice_type" property="adviceType" jdbcType="CHAR" />
@@ -20,21 +20,17 @@
20 20
     <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
21 21
     <result column="update_user" property="updateUser" jdbcType="INTEGER" />
22 22
     <result column="update_date" property="updateDate" jdbcType="TIMESTAMP" />
23
-    <result column="ticket_status" property="ticketStatus" jdbcType="VARCHAR" />
24
-    <result column="content" property="content" jdbcType="VARCHAR" />
25
-    <result column="read_message_icon" property="readMessageIcon" jdbcType="VARCHAR" />
26
-    <result column="unread_message_icon" property="unreadMessageIcon" jdbcType="VARCHAR" />
27
-    <result column="message_detail_url" property="messageDetailUrl" jdbcType="VARCHAR" />
28
-    <result column="message_icon_title" property="messageIconTitle" jdbcType="VARCHAR" />
29
-    <result column="common_id" property="commonId" jdbcType="INTEGER" />
23
+    <result column="bill_id" property="billId" jdbcType="INTEGER" />
24
+    <result column="activity_id" property="activityId" jdbcType="INTEGER" />
25
+    <result column="announcement_id" property="announcementId" jdbcType="INTEGER" />
30 26
   </resultMap>
31 27
   <sql id="Base_Column_List" >
32
-    id, ticket_id,community_id, message_type, advice_type, model_type, uuid, uuid_type, source,
33
-    message_content, status, result, meaasge_type_id, read_status, create_user, create_date, 
34
-    update_user, update_date, common_id
28
+    id, ticket_id, community_id, message_type, advice_type, model_type, uuid, uuid_type,
29
+    source, message_content, status, result, meaasge_type_id, read_status, create_user,
30
+    create_date, update_user, update_date, bill_id, activity_id, announcement_id
35 31
   </sql>
36 32
   <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
37
-    select 
33
+    select
38 34
     <include refid="Base_Column_List" />
39 35
     from tp_message
40 36
     where id = #{id,jdbcType=INTEGER}
@@ -44,26 +40,28 @@
44 40
     where id = #{id,jdbcType=INTEGER}
45 41
   </delete>
46 42
   <insert id="insert" parameterType="com.community.huiju.model.TpMessage" >
47
-    insert into tp_message (id, ticket_id, community_id, message_type,
48
-      advice_type, model_type, uuid, 
49
-      uuid_type, source, message_content, 
50
-      status, result, meaasge_type_id, 
51
-      read_status, create_user, create_date, 
52
-      update_user, update_date, common_id)
53
-    values (#{id,jdbcType=INTEGER}, #{ticketId,jdbcType=INTEGER},#{communityId,jdbcType=INTEGER}, #{messageType,jdbcType=CHAR},
54
-      #{adviceType,jdbcType=CHAR}, #{modelType,jdbcType=CHAR}, #{uuid,jdbcType=INTEGER}, 
55
-      #{uuidType,jdbcType=CHAR}, #{source,jdbcType=CHAR}, #{messageContent,jdbcType=VARCHAR}, 
56
-      #{status,jdbcType=CHAR}, #{result,jdbcType=VARCHAR}, #{meaasgeTypeId,jdbcType=VARCHAR}, 
57
-      #{readStatus,jdbcType=CHAR}, #{createUser,jdbcType=INTEGER}, #{createDate,jdbcType=TIMESTAMP}, 
58
-      #{updateUser,jdbcType=INTEGER}, #{updateDate,jdbcType=TIMESTAMP}, #{commonId,jdbcType=INTEGER})
43
+    insert into tp_message (id, ticket_id, community_id,
44
+      message_type, advice_type, model_type,
45
+      uuid, uuid_type, source, message_content,
46
+      status, result, meaasge_type_id,
47
+      read_status, create_user, create_date,
48
+      update_user, update_date, bill_id,
49
+      activity_id, announcement_id)
50
+    values (#{id,jdbcType=INTEGER}, #{ticketId,jdbcType=INTEGER}, #{communityId,jdbcType=INTEGER},
51
+      #{messageType,jdbcType=CHAR}, #{adviceType,jdbcType=CHAR}, #{modelType,jdbcType=CHAR},
52
+      #{uuid,jdbcType=INTEGER}, #{uuidType,jdbcType=CHAR}, #{source,jdbcType=CHAR}, #{messageContent,jdbcType=VARCHAR},
53
+      #{status,jdbcType=CHAR}, #{result,jdbcType=VARCHAR}, #{meaasgeTypeId,jdbcType=VARCHAR},
54
+      #{readStatus,jdbcType=CHAR}, #{createUser,jdbcType=INTEGER}, #{createDate,jdbcType=TIMESTAMP},
55
+      #{updateUser,jdbcType=INTEGER}, #{updateDate,jdbcType=TIMESTAMP}, #{billId,jdbcType=INTEGER},
56
+      #{activityId,jdbcType=INTEGER}, #{announcementId,jdbcType=INTEGER})
59 57
   </insert>
60
-  <insert id="insertSelective" parameterType="com.community.huiju.model.TpMessage" useGeneratedKeys="true" keyProperty="id" >
58
+  <insert id="insertSelective" parameterType="com.community.huiju.model.TpMessage" >
61 59
     insert into tp_message
62 60
     <trim prefix="(" suffix=")" suffixOverrides="," >
63 61
       <if test="id != null" >
64 62
         id,
65 63
       </if>
66
-      <if test="ticketId != null">
64
+      <if test="ticketId != null" >
67 65
         ticket_id,
68 66
       </if>
69 67
       <if test="communityId != null" >
@@ -114,15 +112,21 @@
114 112
       <if test="updateDate != null" >
115 113
         update_date,
116 114
       </if>
117
-      <if test="commonId != null">
118
-        common_id,
115
+      <if test="billId != null" >
116
+        bill_id,
117
+      </if>
118
+      <if test="activityId != null" >
119
+        activity_id,
120
+      </if>
121
+      <if test="announcementId != null" >
122
+        announcement_id,
119 123
       </if>
120 124
     </trim>
121 125
     <trim prefix="values (" suffix=")" suffixOverrides="," >
122 126
       <if test="id != null" >
123 127
         #{id,jdbcType=INTEGER},
124 128
       </if>
125
-      <if test="ticketId != null">
129
+      <if test="ticketId != null" >
126 130
         #{ticketId,jdbcType=INTEGER},
127 131
       </if>
128 132
       <if test="communityId != null" >
@@ -173,15 +177,21 @@
173 177
       <if test="updateDate != null" >
174 178
         #{updateDate,jdbcType=TIMESTAMP},
175 179
       </if>
176
-      <if test="commonId != null">
177
-        #{commonId,jdbcType=INTEGER},
180
+      <if test="billId != null" >
181
+        #{billId,jdbcType=INTEGER},
182
+      </if>
183
+      <if test="activityId != null" >
184
+        #{activityId,jdbcType=INTEGER},
185
+      </if>
186
+      <if test="announcementId != null" >
187
+        #{announcementId,jdbcType=INTEGER},
178 188
       </if>
179 189
     </trim>
180 190
   </insert>
181 191
   <update id="updateByPrimaryKeySelective" parameterType="com.community.huiju.model.TpMessage" >
182 192
     update tp_message
183 193
     <set >
184
-      <if test="ticketId != null">
194
+      <if test="ticketId != null" >
185 195
         ticket_id = #{ticketId,jdbcType=INTEGER},
186 196
       </if>
187 197
       <if test="communityId != null" >
@@ -232,8 +242,14 @@
232 242
       <if test="updateDate != null" >
233 243
         update_date = #{updateDate,jdbcType=TIMESTAMP},
234 244
       </if>
235
-      <if test="commonId != null">
236
-        common_id = #{commonId,jdbcType=INTEGER}
245
+      <if test="billId != null" >
246
+        bill_id = #{billId,jdbcType=INTEGER},
247
+      </if>
248
+      <if test="activityId != null" >
249
+        activity_id = #{activityId,jdbcType=INTEGER},
250
+      </if>
251
+      <if test="announcementId != null" >
252
+        announcement_id = #{announcementId,jdbcType=INTEGER},
237 253
       </if>
238 254
     </set>
239 255
     where id = #{id,jdbcType=INTEGER}
@@ -257,7 +273,9 @@
257 273
       create_date = #{createDate,jdbcType=TIMESTAMP},
258 274
       update_user = #{updateUser,jdbcType=INTEGER},
259 275
       update_date = #{updateDate,jdbcType=TIMESTAMP},
260
-      common_id = #{commonId,jdbcType=INTEGER}
276
+      bill_id = #{billId,jdbcType=INTEGER},
277
+      activity_id = #{activityId,jdbcType=INTEGER},
278
+      announcement_id = #{announcementId,jdbcType=INTEGER}
261 279
     where id = #{id,jdbcType=INTEGER}
262 280
   </update>
263 281