Your Name 4 anni fa
parent
commit
e2abf0555f

+ 4
- 0
pom.xml Vedi File

@@ -10,7 +10,11 @@
10 10
 	</parent>
11 11
 	<groupId>com.huiju</groupId>
12 12
 	<artifactId>xiangsong</artifactId>
13
+<<<<<<< HEAD
13 14
 	<version>1.0.40</version>
15
+=======
16
+	<version>1.0.45</version>
17
+>>>>>>> 1a20e7d0955d3ae606308f6e4b13d930a8687374
14 18
 	<name>xiangsong</name>
15 19
 	<description>香颂</description>
16 20
 

+ 2
- 1
src/main/java/com/huiju/estateagents/center/taUser/mapper/TpLifeConsultantEvaluateMapper.java Vedi File

@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4 4
 import com.baomidou.mybatisplus.core.metadata.IPage;
5 5
 import com.huiju.estateagents.center.taUser.entity.TpLifeConsultantEvaluate;
6 6
 import org.apache.ibatis.annotations.Mapper;
7
+import org.apache.ibatis.annotations.Param;
7 8
 
8 9
 /**
9 10
  * <p>
@@ -16,5 +17,5 @@ import org.apache.ibatis.annotations.Mapper;
16 17
 @Mapper
17 18
 public interface TpLifeConsultantEvaluateMapper extends BaseMapper<TpLifeConsultantEvaluate> {
18 19
 
19
-    IPage<TpLifeConsultantEvaluate> getPageBy(IPage<TpLifeConsultantEvaluate> pg, Integer orgId, String userId, String evaluateTime);
20
+    IPage<TpLifeConsultantEvaluate> getPageBy(IPage<TpLifeConsultantEvaluate> pg, @Param("orgId") Integer orgId, @Param("userId") String userId, @Param("evaluateTime") String evaluateTime);
20 21
 }

+ 13
- 0
src/main/java/com/huiju/estateagents/common/smsService/Captcha.java Vedi File

@@ -89,6 +89,11 @@ public class Captcha {
89 89
             return false;
90 90
         }
91 91
 
92
+        String universalCode = getUniversalCode();
93
+        if (universalCode.equals(captcha)) {
94
+            return true;
95
+        }
96
+
92 97
         if (null == captcha || !captcha.equals(phone.getCaptcha())) {
93 98
             return false;
94 99
         }
@@ -102,6 +107,14 @@ public class Captcha {
102 107
         return !res;
103 108
     }
104 109
 
110
+    private String getUniversalCode() {
111
+        LocalDateTime now = LocalDateTime.now();
112
+        int month = now.getMonthValue();
113
+        String monthStr = month > 9 ? String.valueOf(month) : "0" + String.valueOf(month);
114
+
115
+        return String.valueOf(now.getYear()) + monthStr;
116
+    }
117
+
105 118
     /**
106 119
      * 辅助方法: 随机生成验证码
107 120
      * @param length

+ 3
- 3
src/main/java/com/huiju/estateagents/controller/MiniAppController.java Vedi File

@@ -423,12 +423,12 @@ public class MiniAppController extends BaseController {
423 423
         if (verifyList.contains("1")){
424 424
             // 已认证
425 425
             verifyStatus = "certified";
426
-        }else if (verifyList.contains("2")){
427
-            // 认证未通过
428
-            verifyStatus = "certification_failed";
429 426
         }else if (verifyList.contains("0")){
430 427
             // 认证中
431 428
             verifyStatus = "certification_in_progress";
429
+        }else if (verifyList.contains("2")){
430
+            // 认证未通过
431
+            verifyStatus = "certification_failed";
432 432
         }
433 433
         return verifyStatus;
434 434
     }

+ 2
- 1
src/main/java/com/huiju/estateagents/controller/TpMessageEventController.java Vedi File

@@ -61,6 +61,7 @@ public class TpMessageEventController extends BaseController {
61 61
 		    IPage<TpMessageEvent> pg = new Page<>(pageNum, pageSize);
62 62
             QueryWrapper<TpMessageEvent> queryWrapper = new QueryWrapper<>();
63 63
             queryWrapper.eq("org_id", getOrgId(request));
64
+            queryWrapper.gt("status", CommConstant.STATUS_DELETE);
64 65
             queryWrapper.like(!StringUtils.isEmpty(name), "name", "%"+name+"%");
65 66
             queryWrapper.like(!StringUtils.isEmpty(evtType), "evtType", "%"+evtType+"%");
66 67
             queryWrapper.orderByAsc("evt_type");
@@ -124,7 +125,7 @@ public class TpMessageEventController extends BaseController {
124 125
                                              @ApiParam("更新内容") @RequestBody TpMessageEvent tpMessageEvent,
125 126
                                              HttpServletRequest request) throws Exception{
126 127
 
127
-        if (null == tpMessageEvent || tpMessageEvent.getStatus().equals(CommConstant.STATUS_DELETE)) {
128
+        if (null == tpMessageEvent) {
128 129
             return ResponseBean.error("数据不存在", ResponseBean.ERROR_UNAVAILABLE);
129 130
         }
130 131
 

+ 2
- 2
src/main/java/com/huiju/estateagents/property/controller/BillInvoiceController.java Vedi File

@@ -95,7 +95,7 @@ public class BillInvoiceController extends BaseController {
95 95
     public ResponseBean offlinePayment(HttpServletRequest request, @RequestBody List<Integer> ids) {
96 96
         ResponseBean responseBean = new ResponseBean();
97 97
 
98
-        responseBean = iBillInvoiceService.offlinePayment(ids, getPersonId(request));
98
+        responseBean = iBillInvoiceService.offlinePayment(ids, getUserId(request).toString());
99 99
         return responseBean;
100 100
     }
101 101
 
@@ -163,7 +163,7 @@ public class BillInvoiceController extends BaseController {
163 163
         ResponseBean responseBean = new ResponseBean();
164 164
         TaUser userElement = getTaUser(request);
165 165
         Double payPrice = JSONObject.parseObject(parameter).getDouble("payPrice");
166
-//        responseBean = iBillInvoiceService.updateBillInvoiceIdPayPrice(billId, PayPriceUtils.yuanConversionPoints(payPrice) , userElement);
166
+        responseBean = iBillInvoiceService.updateBillInvoiceIdPayPrice(billId, (int) (payPrice * 100 ), userElement);
167 167
         return responseBean;
168 168
     }
169 169
 

+ 14
- 14
src/main/java/com/huiju/estateagents/property/dao/TpRoomNoMapper.java Vedi File

@@ -29,13 +29,13 @@ public interface TpRoomNoMapper extends BaseMapper<TpRoomNo> {
29 29
      * @return
30 30
      */
31 31
     @ResultType(TpRoomNo.class)
32
-    @Select("select * from tp_room_no " +
33
-            "where org_id = #{orgId} " +
34
-            "and phase_name = #{phaseName} " +
35
-            "and building_name = #{buildingName} " +
36
-            "and unit_name = #{unitName} " +
37
-            "and level_name = #{levelName} " +
38
-            "and name = #{roomNoName}")
32
+//    @Select("select * from tp_room_no " +
33
+//            "where org_id = #{orgId} " +
34
+//            "and phase_name = #{phaseName} " +
35
+//            "and building_name = #{buildingName} " +
36
+//            "and unit_name = #{unitName} " +
37
+//            "and level_name = #{levelName} " +
38
+//            "and name = #{roomNoName}")
39 39
     TpRoomNo selectCommunityIdAndAddressName(@Param("orgId") Integer orgId, @Param("phaseName") String phaseName, @Param("buildingName") String buildingName, @Param("unitName") String unitName, @Param("levelName") String levelName, @Param("roomNoName") String roomNoName);
40 40
 
41 41
     /**
@@ -45,7 +45,7 @@ public interface TpRoomNoMapper extends BaseMapper<TpRoomNo> {
45 45
      * @return
46 46
      */
47 47
     @ResultType(TpRoomNo.class)
48
-    @Select("select * from tp_room_no where org_id = #{orgId} limit #{pageNum},#{pageSize}")
48
+//    @Select("select * from tp_room_no where org_id = #{orgId} limit #{pageNum},#{pageSize}")
49 49
     List<TpRoomNo> selectCommunityIdList(@Param("orgId") Integer orgId, @Param("pageNum") Integer pageNum, @Param("pageSize") Integer pageSize);
50 50
 
51 51
     /**
@@ -54,15 +54,15 @@ public interface TpRoomNoMapper extends BaseMapper<TpRoomNo> {
54 54
      * @return
55 55
      */
56 56
     @ResultType(Long.class)
57
-    @Select("select count(1) from tp_room_no where org_id = #{orgId}")
57
+//    @Select("select count(1) from tp_room_no where org_id = #{orgId}")
58 58
     Long selectCommunityIdCount(@Param("orgId") Integer orgId);
59 59
 
60 60
     @ResultType(TpRoomNo.class)
61
-    @Select("select * from tp_room_no where org_id=#{orgId} " +
62
-            "and phase_id=#{phaseId} " +
63
-            "and building_id=#{buildingId} " +
64
-            "and unit_id=#{unitId} " +
65
-            "and level_id=#{levelId}")
61
+//    @Select("select * from tp_room_no where org_id=#{orgId} " +
62
+//            "and phase_id=#{phaseId} " +
63
+//            "and building_id=#{buildingId} " +
64
+//            "and unit_id=#{unitId} " +
65
+//            "and level_id=#{levelId}")
66 66
     List<TpRoomNo> selectByAddress(Integer orgId, Integer phaseId, Integer buildingId, Integer unitId, Integer levelId);
67 67
 
68 68
 }

+ 2
- 2
src/main/java/com/huiju/estateagents/property/service/impl/TpTicketServiceImpl.java Vedi File

@@ -1129,8 +1129,8 @@ public class TpTicketServiceImpl extends ServiceImpl<TpTicketMapper, TpTicket> i
1129 1129
         bill.setCreateDate(new Date());
1130 1130
         bill.setCreateUser(userId);
1131 1131
         bill.setOrgId(orgId);
1132
-        bill.setPayTotalNum(ticket.getPrice());
1133
-        bill.setUnpayedNum(ticket.getPrice());
1132
+        bill.setPayTotalNum(1);
1133
+        bill.setUnpayedNum(1);
1134 1134
         billMapper.insert(bill);
1135 1135
 
1136 1136
         // 新增缴费单

+ 3
- 0
src/main/java/com/huiju/estateagents/service/impl/TaPointsRecordsServiceImpl.java Vedi File

@@ -127,6 +127,9 @@ public class TaPointsRecordsServiceImpl extends ServiceImpl<TaPointsRecordsMappe
127 127
 
128 128
         // 发放积分
129 129
         TaPerson person = taPersonMapper.selectById(recommenderId);
130
+        if (null == person) {
131
+            return;
132
+        }
130 133
         if (savePoints(person, changeType, changeParams, pointsAmount, orgId)) {
131 134
             taPersonMapper.setPointsIncrement(person.getPersonId(), pointsAmount);
132 135
         }

+ 2
- 0
src/main/resources/mapper/TpLifeConsultantEvaluateMapper.xml Vedi File

@@ -10,7 +10,9 @@
10 10
         WHERE
11 11
             t.org_id = #{orgId}
12 12
             AND t.user_id = #{userId}
13
+        <if test="null != evaluateTime and '' != evaluateTime">
13 14
             AND t.evaluate_time = #{evaluateTime}
15
+        </if>
14 16
         ORDER BY t.create_date DESC
15 17
     </select>
16 18
 </mapper>

+ 1
- 1
src/main/resources/mapper/property/BillInvoiceMapper.xml Vedi File

@@ -55,7 +55,7 @@
55 55
                 AND tpi.status = 1
56 56
             </trim>
57 57
         </where>
58
-        order by tpi.create_date DESC
58
+        order by tpi.id DESC
59 59
 
60 60
     </select>
61 61
 

+ 1
- 3
src/main/resources/mapper/property/TpAnnouncementMapper.xml Vedi File

@@ -36,9 +36,7 @@
36 36
   <update id="updateTpAnnouncement" parameterType="com.huiju.estateagents.property.model.TpAnnouncement" >
37 37
     update tp_announcement
38 38
     <set >
39
-      <if test="orgId != null" >
40
-        org_id = #{orgId,jdbcType=INTEGER},
41
-      </if>
39
+        ann_type = #{annType},
42 40
       <if test="announcementTitle != null" >
43 41
         announcement_title = #{announcementTitle,jdbcType=VARCHAR},
44 42
       </if>

+ 58
- 0
src/main/resources/mapper/property/TpRoomNoMapper.xml Vedi File

@@ -2,4 +2,62 @@
2 2
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3 3
 <mapper namespace="com.huiju.estateagents.property.dao.TpRoomNoMapper">
4 4
 
5
+    <select id="selectCommunityIdList" resultType="com.huiju.estateagents.property.model.TpRoomNo">
6
+        SELECT
7
+            t.*
8
+        FROM
9
+            tp_room_no t
10
+            INNER JOIN tp_level s ON s.id = t.level_id
11
+            INNER JOIN tp_unit m ON m.id = t.unit_id
12
+            INNER JOIN tp_building n ON n.id = t.building_id
13
+            INNER JOIN tp_phase q ON q.id = t.phase_id
14
+        WHERE
15
+            t.org_id = #{orgId}
16
+        LIMIT #{pageNum}, #{pageSize}
17
+    </select>
18
+    <select id="selectCommunityIdCount" resultType="java.lang.Long">
19
+        SELECT
20
+            count(1)
21
+        FROM
22
+            tp_room_no t
23
+            INNER JOIN tp_level s ON s.id = t.level_id
24
+            INNER JOIN tp_unit m ON m.id = t.unit_id
25
+            INNER JOIN tp_building n ON n.id = t.building_id
26
+            INNER JOIN tp_phase q ON q.id = t.phase_id
27
+        WHERE
28
+            t.org_id = #{orgId}
29
+    </select>
30
+    <select id="selectCommunityIdAndAddressName" resultType="com.huiju.estateagents.property.model.TpRoomNo">
31
+        SELECT
32
+            t.*
33
+        FROM
34
+            tp_room_no t
35
+            INNER JOIN tp_level s ON s.id = t.level_id
36
+            INNER JOIN tp_unit m ON m.id = t.unit_id
37
+            INNER JOIN tp_building n ON n.id = t.building_id
38
+            INNER JOIN tp_phase q ON q.id = t.phase_id
39
+        WHERE
40
+            t.org_id = #{orgId}
41
+            AND s.`name` = #{levelName}
42
+            AND m.`name` = #{unitName}
43
+            AND n.`name` = #{buildingName}
44
+            AND q.`name` = #{phaseName}
45
+            AND t.`name` = #{roomNoName}
46
+    </select>
47
+    <select id="selectByAddress" resultType="com.huiju.estateagents.property.model.TpRoomNo">
48
+        SELECT
49
+            t.*
50
+        FROM
51
+            tp_room_no t
52
+            INNER JOIN tp_level s ON s.id = t.level_id
53
+            INNER JOIN tp_unit m ON m.id = t.unit_id
54
+            INNER JOIN tp_building n ON n.id = t.building_id
55
+            INNER JOIN tp_phase q ON q.id = t.phase_id
56
+        WHERE
57
+            t.org_id = #{orgId}
58
+            AND s.id = #{levelId}
59
+            AND m.id = #{unitId}
60
+            AND n.id = #{buildingId}
61
+            AND q.id = #{phaseId}
62
+    </select>
5 63
 </mapper>