dingxin 6 years ago
parent
commit
80c8cffb12

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

@@ -4,7 +4,9 @@ import com.alibaba.fastjson.JSONObject;
4 4
 import com.community.commom.mode.ResponseBean;
5 5
 import com.community.commom.session.UserElement;
6 6
 import com.community.huiju.dao.TpTransactionMapper;
7
+import com.community.huiju.dao.TpUserMapper;
7 8
 import com.community.huiju.model.TpTransaction;
9
+import com.community.huiju.model.TpUser;
8 10
 import com.community.huiju.service.SocialServiceI;
9 11
 import io.swagger.annotations.Api;
10 12
 import io.swagger.annotations.ApiImplicitParam;
@@ -24,6 +26,9 @@ public class TpTicketAndTransactionController {
24 26
     @Autowired
25 27
     private SocialServiceI socialServiceI;
26 28
 
29
+    @Autowired
30
+    private TpUserMapper tpUserMapper;
31
+
27 32
     @ApiOperation(value = "app端话题管理", notes = "app端话题管理")
28 33
     @ApiImplicitParams({
29 34
             @ApiImplicitParam(paramType = "path",dataType = "String",name = "loginName",value = "电话号码"),
@@ -155,4 +160,18 @@ public class TpTicketAndTransactionController {
155 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,7 +9,7 @@ public class TpShopAppraisal {
9 9
 
10 10
     private Integer shopId;
11 11
 
12
-    private String score;
12
+    private Integer score;
13 13
 
14 14
     private String content;
15 15
 
@@ -31,6 +31,14 @@ public class TpShopAppraisal {
31 31
      */
32 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 42
     public void setTpShopAppraisalReplay(TpShopAppraisalReplay tpShopAppraisalReplay) {
35 43
         this.tpShopAppraisalReplay = tpShopAppraisalReplay;
36 44
     }
@@ -63,14 +71,6 @@ public class TpShopAppraisal {
63 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 74
     public String getContent() {
75 75
         return content;
76 76
     }

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

@@ -1136,6 +1136,7 @@ public class SocialServiceImpl implements SocialServiceI {
1136 1136
         tpTransaction.setViewCount(0);
1137 1137
         tpTransaction.setIsReported("0");
1138 1138
         tpTransaction.setReleaseIdentity("1");
1139
+        tpTransaction.setStatus("1");
1139 1140
         tpTransactionMapper.insertSelective(tpTransaction);
1140 1141
         JSONArray contentImg = jsonobject.getJSONArray("contentImg");
1141 1142
 

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

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