dingxin vor 6 Jahren
Ursprung
Commit
a8e4d3ed00

+ 16
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/controller/TpTicketAndTransactionController.java Datei anzeigen

@@ -174,4 +174,20 @@ public class TpTicketAndTransactionController {
174 174
         return responseBean;
175 175
     }
176 176
 
177
+    @ApiOperation(value = "app端个人中心话题管和工单管理是否展示", notes = "app端个人中心话题管和工单管理是否展示")
178
+    @ApiImplicitParams({@ApiImplicitParam(paramType = "path", dataType = "integer", name = "communityId", value = "小区Id"),
179
+            @ApiImplicitParam(paramType = "query", dataType = "String", name = "loginName", value = "手机号"),
180
+    })
181
+    @RequestMapping(value = "/accessAuthority/{communityId}", method = RequestMethod.GET)
182
+    public ResponseBean findUsedDetails(@PathVariable(value = "communityId") Integer communityId,@RequestParam("loginName") String loginName) {
183
+        ResponseBean responseBean = new ResponseBean();
184
+        TpUser tpUser= tpUserMapper.selectLoginName(loginName,communityId);
185
+         if (null == tpUser){
186
+             responseBean.addError("此号码无权限");
187
+             return responseBean;
188
+         }
189
+             responseBean.addSuccess("成功");
190
+        return responseBean;
191
+    }
192
+
177 193
 }

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

@@ -1158,6 +1158,7 @@ public class SocialServiceImpl implements SocialServiceI {
1158 1158
             tdImages.setCreateUser(id);
1159 1159
             tdImagesMapper.insert(tdImages);
1160 1160
         }
1161
+        response.addSuccess(String.valueOf(tpTransaction.getId()));
1161 1162
         return response;
1162 1163
     }
1163 1164
 

+ 22
- 18
CODE/smart-community/app-api/src/main/resources/mapper/TpTicketMapper.xml Datei anzeigen

@@ -279,31 +279,35 @@
279 279
 
280 280
   <select id="ticketList" resultMap="BaseResultMap">
281 281
     select
282
-    id,
283
-    community_id,
284
-    ta_user_id,
285
-    ticket_title,
286
-    ticket_content,
287
-    STATUS,
288
-    repair_type,
289
-    tp_user_id,
290
-    score,
291
-    COMMENT,
292
-    create_user,
293
-    create_date,
294
-    update_user,
295
-    update_date,
282
+    t.id,
283
+    t.community_id,
284
+    t.ta_user_id,
285
+    t.ticket_title,
286
+    t.ticket_content,
287
+    t.STATUS,
288
+    t.repair_type,
289
+    t.tp_user_id,
290
+    t.score,
291
+    t.COMMENT,
292
+    t.create_user,
293
+    t.create_date,
294
+    t.update_user,
295
+    t.update_date,
296 296
     (CASE type WHEN 1 THEN '投诉' WHEN 2 THEN '报修' WHEN 3 THEN '联系物业' ELSE	'未知' END) as type
297
-    from tp_ticket
297
+    from ta_user_verify uv
298
+    LEFT JOIN tp_ticket t on uv.id = t.create_user
298 299
     <where>
299 300
       <if test="status == 0 or status == 3 ">
300
-            status = #{status}
301
+        t.status = #{status}
301 302
       </if>
302 303
       <if test="status == 9 ">
303
-        and  `status` NOT in(0,3)
304
+        and  t.`status` NOT in(0,3)
304 305
       </if>
305
-      and community_id = #{communityId,jdbcType=INTEGER}
306
+      and t.id IS NOT NULL
307
+      and uv.community_id = #{communityId,jdbcType=INTEGER}
306 308
     </where>
309
+    GROUP BY t.id
310
+    order by  t.create_date desc
307 311
   </select>
308 312
 
309 313
   <select id="ticketDetails" resultType="com.community.huiju.vo.TpTicketVO">

+ 1
- 1
CODE/smart-community/app-api/src/main/resources/mapper/TpTransactionMapper.xml Datei anzeigen

@@ -345,7 +345,7 @@
345 345
                 and is_reported = 1
346 346
             </if>
347 347
             <if test="ManageStatus == 2">
348
-                (read_status IS NULL or read_status = 0)
348
+                and  (read_status IS NULL or read_status = 0)
349 349
             </if>
350 350
             <if test="ManageStatus == 3">
351 351
                 and  read_status= 1

+ 4
- 2
CODE/smart-community/property-api/src/main/java/com/community/huiju/service/impl/TpTicketServiceImpl.java Datei anzeigen

@@ -84,9 +84,11 @@ public class TpTicketServiceImpl extends ServiceImpl<TpTicketMapper, TpTicket> i
84 84
 
85 85
             /*查询当前工单创建人*/
86 86
             TaUserVerify taUserVerify= taUserVerifyMapper.selectById(tpTicket.getCreateUser());
87
+            if (null != taUserVerify ){
88
+                String createUserNmae=taUserMapper.selectLongNameAndcommunityId(taUserVerify.getUserId());
89
+                tpTicketVO.setCreateUserNmae(createUserNmae);
90
+            }
87 91
 
88
-            String createUserNmae=taUserMapper.selectLongNameAndcommunityId(taUserVerify.getUserId());
89
-            tpTicketVO.setCreateUserNmae(createUserNmae);
90 92
             tpTicketArrayList.add(tpTicketVO);
91 93
         }
92 94
         HashMap map=new HashMap<>();

+ 6
- 4
CODE/smart-community/property-api/src/main/resources/mapper/TpTicketMapper.xml Datei anzeigen

@@ -19,8 +19,8 @@
19 19
     p.update_user,
20 20
     p.update_date,
21 21
     us.user_name
22
-    FROM
23
-    tp_ticket p
22
+    from ta_user_verify uv
23
+    LEFT JOIN tp_ticket p on uv.id = p.create_user
24 24
     LEFT JOIN ta_user AS us ON p.create_user=us.id
25 25
     LEFT JOIN tp_user AS u ON p.tp_user_id = u.id
26 26
 <where>
@@ -42,9 +42,11 @@
42 42
     <if test="updateUserNmae != null and updateUserNmae !=''">
43 43
         and u.user_name like concat('%',#{ updateUserNmae,jdbcType=VARCHAR},'%')
44 44
     </if>
45
-    and p.community_id=#{communityId,jdbcType=INTEGER}
45
+    and p.id IS NOT NULL
46
+    and uv.community_id=#{communityId,jdbcType=INTEGER}
46 47
 </where>
47
-        order by  create_date desc
48
+        GROUP BY p.id
49
+        order by  p.create_date desc
48 50
     </select>
49 51
 
50 52
     <select id="ticketDetails" resultType="com.community.huiju.vo.TpTicketVO">