andrew 4 年前
父节点
当前提交
d68098235f

+ 4
- 57
src/main/java/com/huiju/estateagents/property/model/TpSocialView.java 查看文件

@@ -1,11 +1,14 @@
1 1
 package com.huiju.estateagents.property.model;
2 2
 
3
+import lombok.Data;
4
+
3 5
 import java.util.Date;
4 6
 
7
+@Data
5 8
 public class TpSocialView {
6 9
     private Integer id;
7 10
 
8
-    private Integer communityId;
11
+    private Integer orgId;
9 12
 
10 13
     private Integer uuid;
11 14
 
@@ -16,60 +19,4 @@ public class TpSocialView {
16 19
     private String remark;
17 20
 
18 21
     private Date createDate;
19
-
20
-    public Integer getId() {
21
-        return id;
22
-    }
23
-
24
-    public void setId(Integer id) {
25
-        this.id = id;
26
-    }
27
-
28
-    public Integer getCommunityId() {
29
-        return communityId;
30
-    }
31
-
32
-    public void setCommunityId(Integer communityId) {
33
-        this.communityId = communityId;
34
-    }
35
-
36
-    public Integer getUuid() {
37
-        return uuid;
38
-    }
39
-
40
-    public void setUuid(Integer uuid) {
41
-        this.uuid = uuid;
42
-    }
43
-
44
-    public String getSocialType() {
45
-        return socialType;
46
-    }
47
-
48
-    public void setSocialType(String socialType) {
49
-        this.socialType = socialType == null ? null : socialType.trim();
50
-    }
51
-
52
-    public Integer getTaUserId() {
53
-        return taUserId;
54
-    }
55
-
56
-    public void setTaUserId(Integer taUserId) {
57
-        this.taUserId = taUserId;
58
-    }
59
-
60
-    public String getRemark() {
61
-        return remark;
62
-    }
63
-
64
-    public void setRemark(String remark) {
65
-        this.remark = remark == null ? null : remark.trim();
66
-    }
67
-
68
-    public Date getCreateDate() {
69
-        return createDate;
70
-    }
71
-
72
-    public void setCreateDate(Date createDate) {
73
-        this.createDate = createDate;
74
-    }
75 22
 }

+ 1
- 1
src/main/java/com/huiju/estateagents/property/service/impl/SocialServiceImpl.java 查看文件

@@ -101,7 +101,7 @@ public class SocialServiceImpl implements SocialServiceI {
101 101
         TpSocialView tpSocialView = new TpSocialView();
102 102
         tpSocialView.setTaUserId(userId);
103 103
         tpSocialView.setSocialType(socialType);
104
-        tpSocialView.setCommunityId(orgId);
104
+        tpSocialView.setOrgId(orgId);
105 105
         tpSocialView.setUuid(uuid);
106 106
         Integer viewNum = tpSocialViewMapper.selectViewNum(tpSocialView);
107 107
 

+ 17
- 0
src/main/resources/mapper/property/TpAnnouncementMapper.xml 查看文件

@@ -101,4 +101,21 @@
101 101
     a.update_date DESC,
102 102
     a.create_date DESC
103 103
   </select>
104
+
105
+  <update id="updateByPrimaryKeySelective" >
106
+    update tp_announcement
107
+    <set >
108
+      <if test="viewCount != null" >
109
+        view_count = #{viewCount,jdbcType=INTEGER},
110
+      </if>
111
+    </set>
112
+    where id = #{id,jdbcType=INTEGER}
113
+  </update>
114
+
115
+  <select id="selectByPrimaryKey" resultType="com.huiju.estateagents.property.model.TpAnnouncement">
116
+    select
117
+    <include refid="Base_Column_List" />
118
+    from tp_announcement
119
+    where id = #{id,jdbcType=INTEGER} and org_id = #{orgId,jdbcType=INTEGER}
120
+  </select>
104 121
 </mapper>

+ 7
- 7
src/main/resources/mapper/property/TpSocialViewMapper.xml 查看文件

@@ -3,7 +3,7 @@
3 3
 <mapper namespace="com.huiju.estateagents.property.dao.TpSocialViewMapper" >
4 4
   <resultMap id="BaseResultMap" type="com.huiju.estateagents.property.model.TpSocialView" >
5 5
     <id column="id" property="id" jdbcType="INTEGER" />
6
-    <result column="community_id" property="communityId" jdbcType="INTEGER" />
6
+    <result column="org_id" property="orgId" jdbcType="INTEGER" />
7 7
     <result column="uuid" property="uuid" jdbcType="INTEGER" />
8 8
     <result column="social_type" property="socialType" jdbcType="VARCHAR" />
9 9
     <result column="ta_user_id" property="taUserId" jdbcType="INTEGER" />
@@ -11,7 +11,7 @@
11 11
     <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
12 12
   </resultMap>
13 13
   <sql id="Base_Column_List" >
14
-    id, community_id, uuid, social_type, ta_user_id, remark, create_date
14
+    id, org_id, uuid, social_type, ta_user_id, remark, create_date
15 15
   </sql>
16 16
   <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
17 17
     select 
@@ -37,8 +37,8 @@
37 37
       <if test="id != null" >
38 38
         id,
39 39
       </if>
40
-      <if test="communityId != null" >
41
-        community_id,
40
+      <if test="orgId != null" >
41
+        org_id,
42 42
       </if>
43 43
       <if test="uuid != null" >
44 44
         uuid,
@@ -60,8 +60,8 @@
60 60
       <if test="id != null" >
61 61
         #{id,jdbcType=INTEGER},
62 62
       </if>
63
-      <if test="communityId != null" >
64
-        #{communityId,jdbcType=INTEGER},
63
+      <if test="orgId != null" >
64
+        #{orgId,jdbcType=INTEGER},
65 65
       </if>
66 66
       <if test="uuid != null" >
67 67
         #{uuid,jdbcType=INTEGER},
@@ -122,7 +122,7 @@
122 122
       and ta_user_id = #{taUserId}
123 123
     </if>
124 124
     and uuid = #{uuid}
125
-    and community_id = #{communityId}
125
+    and org_id = #{orgId}
126 126
     and social_type = #{socialType}
127 127
   </select>
128 128
 </mapper>

+ 2
- 2
src/main/resources/mapper/property/TpTicketRecordMapper.xml 查看文件

@@ -45,7 +45,7 @@
45 45
         t.id,
46 46
         t.status,
47 47
         t.ticket_id AS ticketId,
48
-        t.community_id AS communityId,
48
+        t.org_id AS orgId,
49 49
         t.content AS content,
50 50
         t.create_date AS createDate,
51 51
         d.NAME AS ticketStatusName
@@ -54,7 +54,7 @@
54 54
         LEFT JOIN sys_dictionary d ON t.STATUS = d.CODE
55 55
         AND d.group_id = ( SELECT id FROM sys_dictionary WHERE CODE = "ticket_status" )
56 56
     WHERE
57
-        community_id = #{communityId,jdbcType=INTEGER}
57
+        org_id = #{orgId,jdbcType=INTEGER}
58 58
         AND ticket_id = #{ticketId,jdbcType=INTEGER}
59 59
     order by t.status
60 60
   </select>