Browse Source

修复支付宝提现时,显示微信渠道的问题

udream-cxs 4 years ago
parent
commit
24eac4390a

+ 1 - 1
lift-ud-service/src/main/java/cn/com/ty/lift/ud/chat/mapper/entity/LiftCaseEntity.java

@@ -205,7 +205,7 @@ public class LiftCaseEntity extends BaseEntity {
     /**
     /**
      * 支付方式 1:微信2:支付宝
      * 支付方式 1:微信2:支付宝
      */
      */
-    @ApiModelProperty("支付方式 1:微信2:支付宝")
+    @ApiModelProperty("支付方式 1:支付宝 2:微信")
     private Integer payType;
     private Integer payType;
 
 
     @ApiModelProperty("视频")
     @ApiModelProperty("视频")

+ 1 - 1
lift-ud-service/src/main/java/cn/com/ty/lift/ud/chat/service/impl/ChatSessionServiceImpl.java

@@ -150,7 +150,7 @@ public class ChatSessionServiceImpl extends ServiceImpl<ChatSessionMapper, ChatS
                 List<ChatMsgEntity> msgList = msgService.list(new QueryWrapper<ChatMsgEntity>().eq("sessionid", entity.getSessionid()).last("order by create_time limit 1"));
                 List<ChatMsgEntity> msgList = msgService.list(new QueryWrapper<ChatMsgEntity>().eq("sessionid", entity.getSessionid()).last("order by create_time limit 1"));
                 Optional<List<ChatMsgEntity>> msgListOption = Optional.ofNullable(msgList);
                 Optional<List<ChatMsgEntity>> msgListOption = Optional.ofNullable(msgList);
                 ChatMsgEntity lastMsg = null;
                 ChatMsgEntity lastMsg = null;
-                if (msgListOption.isPresent()){
+                if (msgListOption.isPresent() && msgListOption.get().size() > 0){
                     lastMsg = msgListOption.get().get(0);
                     lastMsg = msgListOption.get().get(0);
                 } else{
                 } else{
                     lastMsg = new ChatMsgEntity();
                     lastMsg = new ChatMsgEntity();

+ 1 - 1
lift-ud-service/src/main/java/cn/com/ty/lift/ud/payment/mapper/entity/UserWithdrawEntity.java

@@ -38,7 +38,7 @@ public class UserWithdrawEntity extends BaseEntity {
     /**
     /**
      * 支付宝微信 1:微信2:支付宝
      * 支付宝微信 1:微信2:支付宝
      */
      */
-    @ApiModelProperty("支付宝微信 1:微信2:支付宝")
+    @ApiModelProperty("支付宝微信 1:支付宝 2:微信")
     private Integer type;
     private Integer type;
 
 
     /**
     /**

+ 3 - 6
lift-ud-service/src/main/java/cn/com/ty/lift/ud/payment/service/impl/UserWithdrawServiceImpl.java

@@ -161,12 +161,9 @@ public class UserWithdrawServiceImpl extends ServiceImpl<UserWithdrawMapper, Use
         userBillEntity.setUserId(userId);
         userBillEntity.setUserId(userId);
         userBillEntity.setTargetUserId(1L);
         userBillEntity.setTargetUserId(1L);
         userBillEntity.setType(1);
         userBillEntity.setType(1);
-        //1:微信2:支付宝
-        if (req.getType()==1){
-            userBillEntity.setPayType(2);
-        } else {
-            userBillEntity.setPayType(1);
-        }
+        //1:支付宝 2:微信
+        userBillEntity.setPayType(req.getType());
+
         userBillEntity.setDescr("用户提现");
         userBillEntity.setDescr("用户提现");
         userBillEntity.setBusinessType(5);
         userBillEntity.setBusinessType(5);
         //此处不记录流水号,暂时记录订单号,等审批通过,支付宝返款了,再把那个流水号给他
         //此处不记录流水号,暂时记录订单号,等审批通过,支付宝返款了,再把那个流水号给他