weiximei 6 years ago
parent
commit
c11a630899

+ 17
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/dao/TpTransactionReplyMapper.java View File

@@ -0,0 +1,17 @@
1
+package com.community.huiju.dao;
2
+
3
+import com.community.huiju.model.TpTransactionReply;
4
+
5
+public interface TpTransactionReplyMapper {
6
+    int deleteByPrimaryKey(Integer id);
7
+
8
+    int insert(TpTransactionReply record);
9
+
10
+    int insertSelective(TpTransactionReply record);
11
+
12
+    TpTransactionReply selectByPrimaryKey(Integer id);
13
+
14
+    int updateByPrimaryKeySelective(TpTransactionReply record);
15
+
16
+    int updateByPrimaryKey(TpTransactionReply record);
17
+}

+ 95
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/model/TpTransactionReply.java View File

@@ -0,0 +1,95 @@
1
+package com.community.huiju.model;
2
+
3
+import java.util.Date;
4
+
5
+public class TpTransactionReply {
6
+    private Integer id;
7
+
8
+    private Integer communityId;
9
+
10
+    private Integer transactionId;
11
+
12
+    private Integer taUserId;
13
+
14
+    private String taUserName;
15
+
16
+    private String replyContent;
17
+
18
+    private Integer replyTaUserId;
19
+
20
+    private String replyTaUserName;
21
+
22
+    private Date createDate;
23
+
24
+    public Integer getId() {
25
+        return id;
26
+    }
27
+
28
+    public void setId(Integer id) {
29
+        this.id = id;
30
+    }
31
+
32
+    public Integer getCommunityId() {
33
+        return communityId;
34
+    }
35
+
36
+    public void setCommunityId(Integer communityId) {
37
+        this.communityId = communityId;
38
+    }
39
+
40
+    public Integer getTransactionId() {
41
+        return transactionId;
42
+    }
43
+
44
+    public void setTransactionId(Integer transactionId) {
45
+        this.transactionId = transactionId;
46
+    }
47
+
48
+    public Integer getTaUserId() {
49
+        return taUserId;
50
+    }
51
+
52
+    public void setTaUserId(Integer taUserId) {
53
+        this.taUserId = taUserId;
54
+    }
55
+
56
+    public String getTaUserName() {
57
+        return taUserName;
58
+    }
59
+
60
+    public void setTaUserName(String taUserName) {
61
+        this.taUserName = taUserName == null ? null : taUserName.trim();
62
+    }
63
+
64
+    public String getReplyContent() {
65
+        return replyContent;
66
+    }
67
+
68
+    public void setReplyContent(String replyContent) {
69
+        this.replyContent = replyContent == null ? null : replyContent.trim();
70
+    }
71
+
72
+    public Integer getReplyTaUserId() {
73
+        return replyTaUserId;
74
+    }
75
+
76
+    public void setReplyTaUserId(Integer replyTaUserId) {
77
+        this.replyTaUserId = replyTaUserId;
78
+    }
79
+
80
+    public String getReplyTaUserName() {
81
+        return replyTaUserName;
82
+    }
83
+
84
+    public void setReplyTaUserName(String replyTaUserName) {
85
+        this.replyTaUserName = replyTaUserName == null ? null : replyTaUserName.trim();
86
+    }
87
+
88
+    public Date getCreateDate() {
89
+        return createDate;
90
+    }
91
+
92
+    public void setCreateDate(Date createDate) {
93
+        this.createDate = createDate;
94
+    }
95
+}

+ 3
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/service/impl/SocialServiceImpl.java View File

@@ -712,6 +712,9 @@ public class SocialServiceImpl implements SocialServiceI {
712 712
         List<String> imgList = tdImagesList.stream().map(e->new String(e.getImageUrl())).collect(Collectors.toList());
713 713
         tpTransaction.setImgList(imgList);
714 714
 
715
+        // 查询回复信息
716
+
717
+
715 718
         return tpTransaction;
716 719
 
717 720
     }

+ 142
- 0
CODE/smart-community/app-api/src/main/resources/mapper/TpTransactionReplyMapper.xml View File

@@ -0,0 +1,142 @@
1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
3
+<mapper namespace="com.community.huiju.dao.TpTransactionReplyMapper" >
4
+  <resultMap id="BaseResultMap" type="com.community.huiju.model.TpTransactionReply" >
5
+    <id column="id" property="id" jdbcType="INTEGER" />
6
+    <result column="community_id" property="communityId" jdbcType="INTEGER" />
7
+    <result column="transaction_id" property="transactionId" jdbcType="INTEGER" />
8
+    <result column="ta_user_id" property="taUserId" jdbcType="INTEGER" />
9
+    <result column="ta_user_name" property="taUserName" jdbcType="VARCHAR" />
10
+    <result column="reply_content" property="replyContent" jdbcType="VARCHAR" />
11
+    <result column="reply_ta_user_id" property="replyTaUserId" jdbcType="INTEGER" />
12
+    <result column="reply_ta_user_name" property="replyTaUserName" jdbcType="VARCHAR" />
13
+    <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
14
+  </resultMap>
15
+  <sql id="Base_Column_List" >
16
+    id, community_id, transaction_id, ta_user_id, ta_user_name, reply_content, reply_ta_user_id, 
17
+    reply_ta_user_name, create_date
18
+  </sql>
19
+  <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
20
+    select 
21
+    <include refid="Base_Column_List" />
22
+    from tp_transaction_reply
23
+    where id = #{id,jdbcType=INTEGER}
24
+  </select>
25
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
26
+    delete from tp_transaction_reply
27
+    where id = #{id,jdbcType=INTEGER}
28
+  </delete>
29
+  <insert id="insert" parameterType="com.community.huiju.model.TpTransactionReply" >
30
+    insert into tp_transaction_reply (id, community_id, transaction_id, 
31
+      ta_user_id, ta_user_name, reply_content, 
32
+      reply_ta_user_id, reply_ta_user_name, create_date
33
+      )
34
+    values (#{id,jdbcType=INTEGER}, #{communityId,jdbcType=INTEGER}, #{transactionId,jdbcType=INTEGER}, 
35
+      #{taUserId,jdbcType=INTEGER}, #{taUserName,jdbcType=VARCHAR}, #{replyContent,jdbcType=VARCHAR}, 
36
+      #{replyTaUserId,jdbcType=INTEGER}, #{replyTaUserName,jdbcType=VARCHAR}, #{createDate,jdbcType=TIMESTAMP}
37
+      )
38
+  </insert>
39
+  <insert id="insertSelective" parameterType="com.community.huiju.model.TpTransactionReply" >
40
+    insert into tp_transaction_reply
41
+    <trim prefix="(" suffix=")" suffixOverrides="," >
42
+      <if test="id != null" >
43
+        id,
44
+      </if>
45
+      <if test="communityId != null" >
46
+        community_id,
47
+      </if>
48
+      <if test="transactionId != null" >
49
+        transaction_id,
50
+      </if>
51
+      <if test="taUserId != null" >
52
+        ta_user_id,
53
+      </if>
54
+      <if test="taUserName != null" >
55
+        ta_user_name,
56
+      </if>
57
+      <if test="replyContent != null" >
58
+        reply_content,
59
+      </if>
60
+      <if test="replyTaUserId != null" >
61
+        reply_ta_user_id,
62
+      </if>
63
+      <if test="replyTaUserName != null" >
64
+        reply_ta_user_name,
65
+      </if>
66
+      <if test="createDate != null" >
67
+        create_date,
68
+      </if>
69
+    </trim>
70
+    <trim prefix="values (" suffix=")" suffixOverrides="," >
71
+      <if test="id != null" >
72
+        #{id,jdbcType=INTEGER},
73
+      </if>
74
+      <if test="communityId != null" >
75
+        #{communityId,jdbcType=INTEGER},
76
+      </if>
77
+      <if test="transactionId != null" >
78
+        #{transactionId,jdbcType=INTEGER},
79
+      </if>
80
+      <if test="taUserId != null" >
81
+        #{taUserId,jdbcType=INTEGER},
82
+      </if>
83
+      <if test="taUserName != null" >
84
+        #{taUserName,jdbcType=VARCHAR},
85
+      </if>
86
+      <if test="replyContent != null" >
87
+        #{replyContent,jdbcType=VARCHAR},
88
+      </if>
89
+      <if test="replyTaUserId != null" >
90
+        #{replyTaUserId,jdbcType=INTEGER},
91
+      </if>
92
+      <if test="replyTaUserName != null" >
93
+        #{replyTaUserName,jdbcType=VARCHAR},
94
+      </if>
95
+      <if test="createDate != null" >
96
+        #{createDate,jdbcType=TIMESTAMP},
97
+      </if>
98
+    </trim>
99
+  </insert>
100
+  <update id="updateByPrimaryKeySelective" parameterType="com.community.huiju.model.TpTransactionReply" >
101
+    update tp_transaction_reply
102
+    <set >
103
+      <if test="communityId != null" >
104
+        community_id = #{communityId,jdbcType=INTEGER},
105
+      </if>
106
+      <if test="transactionId != null" >
107
+        transaction_id = #{transactionId,jdbcType=INTEGER},
108
+      </if>
109
+      <if test="taUserId != null" >
110
+        ta_user_id = #{taUserId,jdbcType=INTEGER},
111
+      </if>
112
+      <if test="taUserName != null" >
113
+        ta_user_name = #{taUserName,jdbcType=VARCHAR},
114
+      </if>
115
+      <if test="replyContent != null" >
116
+        reply_content = #{replyContent,jdbcType=VARCHAR},
117
+      </if>
118
+      <if test="replyTaUserId != null" >
119
+        reply_ta_user_id = #{replyTaUserId,jdbcType=INTEGER},
120
+      </if>
121
+      <if test="replyTaUserName != null" >
122
+        reply_ta_user_name = #{replyTaUserName,jdbcType=VARCHAR},
123
+      </if>
124
+      <if test="createDate != null" >
125
+        create_date = #{createDate,jdbcType=TIMESTAMP},
126
+      </if>
127
+    </set>
128
+    where id = #{id,jdbcType=INTEGER}
129
+  </update>
130
+  <update id="updateByPrimaryKey" parameterType="com.community.huiju.model.TpTransactionReply" >
131
+    update tp_transaction_reply
132
+    set community_id = #{communityId,jdbcType=INTEGER},
133
+      transaction_id = #{transactionId,jdbcType=INTEGER},
134
+      ta_user_id = #{taUserId,jdbcType=INTEGER},
135
+      ta_user_name = #{taUserName,jdbcType=VARCHAR},
136
+      reply_content = #{replyContent,jdbcType=VARCHAR},
137
+      reply_ta_user_id = #{replyTaUserId,jdbcType=INTEGER},
138
+      reply_ta_user_name = #{replyTaUserName,jdbcType=VARCHAR},
139
+      create_date = #{createDate,jdbcType=TIMESTAMP}
140
+    where id = #{id,jdbcType=INTEGER}
141
+  </update>
142
+</mapper>