Browse Source

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

魏熙美 6 years ago
parent
commit
640f3f8c8d

+ 19
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/controller/TpTicketAndTransactionController.java View File

4
 import com.community.commom.mode.ResponseBean;
4
 import com.community.commom.mode.ResponseBean;
5
 import com.community.commom.session.UserElement;
5
 import com.community.commom.session.UserElement;
6
 import com.community.huiju.dao.TpTransactionMapper;
6
 import com.community.huiju.dao.TpTransactionMapper;
7
+import com.community.huiju.dao.TpUserMapper;
7
 import com.community.huiju.model.TpTransaction;
8
 import com.community.huiju.model.TpTransaction;
9
+import com.community.huiju.model.TpUser;
8
 import com.community.huiju.service.SocialServiceI;
10
 import com.community.huiju.service.SocialServiceI;
9
 import io.swagger.annotations.Api;
11
 import io.swagger.annotations.Api;
10
 import io.swagger.annotations.ApiImplicitParam;
12
 import io.swagger.annotations.ApiImplicitParam;
24
     @Autowired
26
     @Autowired
25
     private SocialServiceI socialServiceI;
27
     private SocialServiceI socialServiceI;
26
 
28
 
29
+    @Autowired
30
+    private TpUserMapper tpUserMapper;
31
+
27
     @ApiOperation(value = "app端话题管理", notes = "app端话题管理")
32
     @ApiOperation(value = "app端话题管理", notes = "app端话题管理")
28
     @ApiImplicitParams({
33
     @ApiImplicitParams({
29
             @ApiImplicitParam(paramType = "path",dataType = "String",name = "loginName",value = "电话号码"),
34
             @ApiImplicitParam(paramType = "path",dataType = "String",name = "loginName",value = "电话号码"),
155
         return responseBean;
160
         return responseBean;
156
     }
161
     }
157
 
162
 
163
+    @ApiOperation(value = "app端话题管理话题详情", notes = "app端话题管理话题详情")
164
+    @ApiImplicitParams({@ApiImplicitParam(paramType = "path", dataType = "integer", name = "communityId", value = "小区Id"),
165
+            @ApiImplicitParam(paramType = "query", dataType = "integer", name = "activityId", value = "帖子id"),
166
+            @ApiImplicitParam(paramType = "query", dataType = "String", name = "loginName", value = "手机号"),
167
+    })
168
+    @RequestMapping(value = "/getTransactionManage/{communityId}", method = RequestMethod.GET)
169
+    public ResponseBean findUsedDetails(@PathVariable(value = "communityId") Integer communityId, @RequestParam("activityId") Integer activityId,@RequestParam("loginName") String loginName) {
170
+        ResponseBean responseBean = new ResponseBean();
171
+        TpUser tpUser= tpUserMapper.selectLoginName(loginName,communityId);
172
+        TpTransaction activity = socialServiceI.findUsedDetails(activityId, communityId, tpUser.getId());
173
+        responseBean.addSuccess(activity);
174
+        return responseBean;
175
+    }
176
+
158
 }
177
 }

+ 9
- 9
CODE/smart-community/app-api/src/main/java/com/community/huiju/model/TpShopAppraisal.java View File

9
 
9
 
10
     private Integer shopId;
10
     private Integer shopId;
11
 
11
 
12
-    private String score;
12
+    private Integer score;
13
 
13
 
14
     private String content;
14
     private String content;
15
 
15
 
31
      */
31
      */
32
     private TpShopAppraisalReplay tpShopAppraisalReplay;
32
     private TpShopAppraisalReplay tpShopAppraisalReplay;
33
 
33
 
34
+    public Integer getScore() {
35
+        return score;
36
+    }
37
+
38
+    public void setScore(Integer score) {
39
+        this.score = score;
40
+    }
41
+
34
     public void setTpShopAppraisalReplay(TpShopAppraisalReplay tpShopAppraisalReplay) {
42
     public void setTpShopAppraisalReplay(TpShopAppraisalReplay tpShopAppraisalReplay) {
35
         this.tpShopAppraisalReplay = tpShopAppraisalReplay;
43
         this.tpShopAppraisalReplay = tpShopAppraisalReplay;
36
     }
44
     }
63
         this.shopId = shopId;
71
         this.shopId = shopId;
64
     }
72
     }
65
 
73
 
66
-    public String getScore() {
67
-        return score;
68
-    }
69
-
70
-    public void setScore(String score) {
71
-        this.score = score == null ? null : score.trim();
72
-    }
73
-
74
     public String getContent() {
74
     public String getContent() {
75
         return content;
75
         return content;
76
     }
76
     }

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

638
                 tdImagesMapper.insert(tdImages);
638
                 tdImagesMapper.insert(tdImages);
639
             }
639
             }
640
         }
640
         }
641
-        // 推消
642
-        TpMessage  tpMessage = new TpMessage(null,userElement.getCommunityId(),"6","1","1", tpTransactionReply.getUuid(),"1","2",  userElement.getUserName()+":"+tpTransactionReply.getReplyContent(),
641
+        // 推消
642
+        TpMessage  tpMessage = new TpMessage(null,userElement.getCommunityId(),"6","1","1", tpTransactionReply.getReplyId(),"1","2",  userElement.getUserName()+":"+tpTransactionReply.getReplyContent(),
643
                                           "1",null,null,"0",userElement.getUserVerifyId(),new Date(),null,null,null,null,null,tpTransactionReply.getTransactionId());
643
                                           "1",null,null,"0",userElement.getUserVerifyId(),new Date(),null,null,null,null,null,tpTransactionReply.getTransactionId());
644
         tpMessageMapper.insertSelective(tpMessage);
644
         tpMessageMapper.insertSelective(tpMessage);
645
         response.addSuccess("成功");
645
         response.addSuccess("成功");
1103
 
1103
 
1104
         JSONArray tpTransactionIdId = parseObject.getJSONArray("id");
1104
         JSONArray tpTransactionIdId = parseObject.getJSONArray("id");
1105
         Integer[] tpTransactionReportArray = tpTransactionIdId.toArray(new Integer[]{});
1105
         Integer[] tpTransactionReportArray = tpTransactionIdId.toArray(new Integer[]{});
1106
-        for (Integer TpTransactionReport:tpTransactionReportArray){
1107
-            tpTransactionReportMapper.deleteTransactionReport(TpTransactionReport,tpUser.getCommunityId());
1106
+        for (Integer tpTransactionReportID:tpTransactionReportArray){
1107
+            tpTransactionReportMapper.deleteTransactionReport(tpTransactionReportID,tpUser.getCommunityId());
1108
+            TpTransaction tpTransaction= new TpTransaction();
1109
+            tpTransaction.setId(tpTransactionReportID);
1110
+            tpTransaction.setIsReported("0");
1111
+            tpTransactionMapper.updateByPrimaryKeySelective(tpTransaction);
1108
         }
1112
         }
1109
         response.addSuccess("成功");
1113
         response.addSuccess("成功");
1110
         return response;
1114
         return response;
1132
         tpTransaction.setViewCount(0);
1136
         tpTransaction.setViewCount(0);
1133
         tpTransaction.setIsReported("0");
1137
         tpTransaction.setIsReported("0");
1134
         tpTransaction.setReleaseIdentity("1");
1138
         tpTransaction.setReleaseIdentity("1");
1139
+        tpTransaction.setStatus("1");
1135
         tpTransactionMapper.insertSelective(tpTransaction);
1140
         tpTransactionMapper.insertSelective(tpTransaction);
1136
         JSONArray contentImg = jsonobject.getJSONArray("contentImg");
1141
         JSONArray contentImg = jsonobject.getJSONArray("contentImg");
1137
 
1142
 

+ 5
- 5
CODE/smart-community/app-api/src/main/resources/mapper/TpShopAppraisalMapper.xml View File

5
     <id column="id" jdbcType="INTEGER" property="id" />
5
     <id column="id" jdbcType="INTEGER" property="id" />
6
     <result column="community_id" jdbcType="INTEGER" property="communityId" />
6
     <result column="community_id" jdbcType="INTEGER" property="communityId" />
7
     <result column="shop_id" jdbcType="INTEGER" property="shopId" />
7
     <result column="shop_id" jdbcType="INTEGER" property="shopId" />
8
-    <result column="score" jdbcType="VARCHAR" property="score" />
8
+    <result column="score" jdbcType="INTEGER" property="score" />
9
     <result column="content" jdbcType="VARCHAR" property="content" />
9
     <result column="content" jdbcType="VARCHAR" property="content" />
10
     <result column="appraisal_people" jdbcType="VARCHAR" property="appraisalPeople" />
10
     <result column="appraisal_people" jdbcType="VARCHAR" property="appraisalPeople" />
11
     <result column="appraisal_tel" jdbcType="VARCHAR" property="appraisalTel" />
11
     <result column="appraisal_tel" jdbcType="VARCHAR" property="appraisalTel" />
36
       status, create_user, create_date
36
       status, create_user, create_date
37
       )
37
       )
38
     values (#{id,jdbcType=INTEGER}, #{communityId,jdbcType=INTEGER}, #{shopId,jdbcType=INTEGER}, 
38
     values (#{id,jdbcType=INTEGER}, #{communityId,jdbcType=INTEGER}, #{shopId,jdbcType=INTEGER}, 
39
-      #{score,jdbcType=VARCHAR}, #{content,jdbcType=VARCHAR}, #{appraisalPeople,jdbcType=VARCHAR}, 
39
+      #{score,jdbcType=INTEGER}, #{content,jdbcType=VARCHAR}, #{appraisalPeople,jdbcType=VARCHAR},
40
       #{appraisalTel,jdbcType=VARCHAR}, #{appraisalAvatar,jdbcType=VARCHAR}, #{sort,jdbcType=INTEGER}, 
40
       #{appraisalTel,jdbcType=VARCHAR}, #{appraisalAvatar,jdbcType=VARCHAR}, #{sort,jdbcType=INTEGER}, 
41
       #{status,jdbcType=VARCHAR}, #{createUser,jdbcType=INTEGER}, #{createDate,jdbcType=TIMESTAMP}
41
       #{status,jdbcType=VARCHAR}, #{createUser,jdbcType=INTEGER}, #{createDate,jdbcType=TIMESTAMP}
42
       )
42
       )
92
         #{shopId,jdbcType=INTEGER},
92
         #{shopId,jdbcType=INTEGER},
93
       </if>
93
       </if>
94
       <if test="score != null">
94
       <if test="score != null">
95
-        #{score,jdbcType=VARCHAR},
95
+        #{score,jdbcType=INTEGER},
96
       </if>
96
       </if>
97
       <if test="content != null">
97
       <if test="content != null">
98
         #{content,jdbcType=VARCHAR},
98
         #{content,jdbcType=VARCHAR},
130
         shop_id = #{shopId,jdbcType=INTEGER},
130
         shop_id = #{shopId,jdbcType=INTEGER},
131
       </if>
131
       </if>
132
       <if test="score != null">
132
       <if test="score != null">
133
-        score = #{score,jdbcType=VARCHAR},
133
+        score = #{score,jdbcType=INTEGER},
134
       </if>
134
       </if>
135
       <if test="content != null">
135
       <if test="content != null">
136
         content = #{content,jdbcType=VARCHAR},
136
         content = #{content,jdbcType=VARCHAR},
163
     update tp_shop_appraisal
163
     update tp_shop_appraisal
164
     set community_id = #{communityId,jdbcType=INTEGER},
164
     set community_id = #{communityId,jdbcType=INTEGER},
165
       shop_id = #{shopId,jdbcType=INTEGER},
165
       shop_id = #{shopId,jdbcType=INTEGER},
166
-      score = #{score,jdbcType=VARCHAR},
166
+      score = #{score,jdbcType=INTEGER},
167
       content = #{content,jdbcType=VARCHAR},
167
       content = #{content,jdbcType=VARCHAR},
168
       appraisal_people = #{appraisalPeople,jdbcType=VARCHAR},
168
       appraisal_people = #{appraisalPeople,jdbcType=VARCHAR},
169
       appraisal_tel = #{appraisalTel,jdbcType=VARCHAR},
169
       appraisal_tel = #{appraisalTel,jdbcType=VARCHAR},

+ 1
- 1
CODE/smart-community/app-api/src/main/resources/mapper/TpTransactionReportMapper.xml View File

9
     <result column="reporter_id" property="reporterId" jdbcType="INTEGER" />
9
     <result column="reporter_id" property="reporterId" jdbcType="INTEGER" />
10
     <result column="reportName" property="reportName" jdbcType="VARCHAR" />
10
     <result column="reportName" property="reportName" jdbcType="VARCHAR" />
11
     <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
11
     <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
12
-    <result column="reportStringName" property="reportUserName" jdbcType="VARCHAR" />
12
+    <result column="reportUserName" property="reportUserName" jdbcType="VARCHAR" />
13
 
13
 
14
   </resultMap>
14
   </resultMap>
15
   <sql id="Base_Column_List" >
15
   <sql id="Base_Column_List" >

+ 2
- 2
CODE/smart-community/property-api/src/main/java/com/community/huiju/service/impl/TransactionServiceImpl.java View File

396
 			tdImages.setCreateUser(userElement.getId());
396
 			tdImages.setCreateUser(userElement.getId());
397
 			tdImagesMapper.insert(tdImages);
397
 			tdImagesMapper.insert(tdImages);
398
 		}
398
 		}
399
-		Message  tpMessage=new Message(null,userElement.getCommunityId(),"9","1","1", tpTransaction.getUuid(),"1","2",  userElement.getUserName()+":"+ replyContent,
400
-				"1",null,null,"0",userElement.getUserVerifyId(),LocalDateTime.now(),null,null,null,null,null,tpTransaction.getId());
399
+		Message  tpMessage=new Message(null,userElement.getCommunityId(),"6","1","1", transactionReply.getReplyUuid(),"1","2",  userElement.getUserName()+":"+ replyContent,
400
+				"1",null,null,"0",userElement.getUserVerifyId(),LocalDateTime.now(),null,null,null,null,null,transactionReply.getTransactionId());
401
 		tpMessageMapper.insert(tpMessage);
401
 		tpMessageMapper.insert(tpMessage);
402
 		response.addSuccess("成功");
402
 		response.addSuccess("成功");
403
 		return response;
403
 		return response;