浏览代码

Merge branch '2.0.0' of http://git.ycjcjy.com/fuxingfan/smartCommunity into 2.0.0

魏熙美 6 年前
父节点
当前提交
4e6a675602

+ 2
- 2
CODE/smart-community/app-api/src/main/java/com/community/huiju/service/impl/SocialServiceImpl.java 查看文件

900
     public ResponseBean findUsedDetailsReply(Integer transactionId, UserElement userElement, String order, Integer pageNum, Integer pageSize, Integer type) {
900
     public ResponseBean findUsedDetailsReply(Integer transactionId, UserElement userElement, String order, Integer pageNum, Integer pageSize, Integer type) {
901
         ResponseBean responseBean = new ResponseBean();
901
         ResponseBean responseBean = new ResponseBean();
902
         //拿到当前帖子的创建人
902
         //拿到当前帖子的创建人
903
-        Integer CreateUser = tpTransactionMapper.getById(transactionId).getCreateUser();
903
+        TpTransaction tpTransaction= tpTransactionMapper.getById(transactionId);
904
 
904
 
905
         PageHelper.startPage(pageNum, pageSize, "create_date " + order);
905
         PageHelper.startPage(pageNum, pageSize, "create_date " + order);
906
-        List<TpTransactionReply> replies = tpTransactionReplyMapper.getCommunityIdAndTransactionId(userElement.getCommunityId(), transactionId, userElement.getUnitId(), CreateUser, type);
906
+        List<TpTransactionReply> replies = tpTransactionReplyMapper.getCommunityIdAndTransactionId(userElement.getCommunityId(), transactionId, userElement.getUnitId(), tpTransaction.getCreateUser(), type);
907
         for (TpTransactionReply tpTransactionReply : replies) {
907
         for (TpTransactionReply tpTransactionReply : replies) {
908
             List<TdImages> tdImagesList = tdImagesMapper.selectImages(tpTransactionReply.getId(), "reply");
908
             List<TdImages> tdImagesList = tdImagesMapper.selectImages(tpTransactionReply.getId(), "reply");
909
             List<String> list = new ArrayList<>();
909
             List<String> list = new ArrayList<>();

+ 6
- 3
CODE/smart-community/app-api/src/main/resources/mapper/TpTransactionReplyMapper.xml 查看文件

162
         tp_transaction_reply tr
162
         tp_transaction_reply tr
163
     WHERE
163
     WHERE
164
 	tr.community_id = #{communityId}
164
 	tr.community_id = #{communityId}
165
+    and tr.transaction_id=#{transactionId}
165
       <if test="type != null and type != '' and type == 2" >
166
       <if test="type != null and type != '' and type == 2" >
166
-      AND (tr.reply_ta_user_id = (SELECT r.id from tp_user r WHERE tr.ta_user_id = r.id )) OR (ta_user_id = (SELECT r.id from tp_user r WHERE tr.ta_user_id = r.id ))
167
+        AND release_identity=1
168
+--       AND (tr.reply_ta_user_id = (SELECT r.id from tp_user r WHERE tr.ta_user_id = r.id )) OR (ta_user_id = (SELECT r.id from tp_user r WHERE tr.ta_user_id = r.id ))
167
       </if>
169
       </if>
168
       <if test="type != null and type != '' and type == 1" >
170
       <if test="type != null and type != '' and type == 1" >
169
-      AND (tr.ta_user_id =#{userID}) OR (tr.reply_ta_user_id = #{userID})
171
+        AND  tr.ta_user_id = #{founderUserID}
170
       </if>
172
       </if>
171
       <if test="type != null and type != '' and type == 0" >
173
       <if test="type != null and type != '' and type == 0" >
172
-      AND (tr.ta_user_id =#{founderUserID}) OR (tr.reply_ta_user_id = #{founderUserID})
174
+        AND (tr.ta_user_id = #{founderUserID}) OR (tr.reply_ta_user_id = #{founderUserID})
175
+--       AND (tr.ta_user_id =#{founderUserID}) OR (tr.reply_ta_user_id = #{founderUserID})
173
       </if>
176
       </if>
174
    </select>
177
    </select>
175
    <select id="selectUserTransactionReply" resultMap="BaseResultMap">
178
    <select id="selectUserTransactionReply" resultMap="BaseResultMap">