Ver código fonte

垫款功能,添加端口类型逻辑

zhaoxian 2 anos atrás
pai
commit
6e0b575d7c

+ 13 - 0
jeecg-boot-module-system/src/main/java/cn/com/ctop/finance/payment/controller/FinancePaymentRechargeApplicationController.java

@@ -155,12 +155,25 @@ public class FinancePaymentRechargeApplicationController {
         if (financePaymentRechargeApplication == null) {
             result.error500("未找到对应实体");
         } else {
+            financePaymentRechargeApplication.setPortName(getName(financePaymentRechargeApplication.getPaymentPort()));
             result.setResult(financePaymentRechargeApplication);
             result.setSuccess(true);
         }
         return result;
     }
 
+    public String getName(String paymentPort) {
+        if ("1".equals(paymentPort)) {
+            return "汇创";
+        } else if ("2".equals(paymentPort)) {
+            return "骄阳";
+        } else if ("3".equals(paymentPort)) {
+            return "江西五七";
+        } else {
+            return "北京五六七";
+        }
+    }
+
     /**
      * 上传临时文件,更新状态
      */

+ 3 - 0
jeecg-boot-module-system/src/main/java/cn/com/ctop/finance/payment/entity/FinancePaymentRechargeApplication.java

@@ -179,4 +179,7 @@ public class FinancePaymentRechargeApplication {
      */
     @TableField(exist = false)
     private List<String> userIds;
+
+    @TableField(exist = false)
+    private String portName;
 }

+ 4 - 4
jeecg-boot-module-system/src/main/java/cn/com/ctop/finance/payment/mapper/xml/FinancePaymentApplicationMapper.xml

@@ -3,15 +3,15 @@
 <mapper namespace="cn.com.ctop.finance.payment.mapper.FinancePaymentApplicationMapper">
 
     <select id="getAdvertisers" resultType="com.alibaba.fastjson.JSONObject">
-        SELECT group_concat(DISTINCT t2.id) as 'advertiserIds', t1.advertiser_name as 'advertiserName'
-        FROM `ctop_cwjs_policy_info` t1
+        SELECT group_concat(DISTINCT t2.id) as 'advertiserIds', t2.name as 'advertiserName'
+        FROM ctop_advertiser t2
         LEFT JOIN
-        ctop_advertiser t2 ON t1.advertiser_name = t2.name
+        `ctop_cwjs_policy_info` t1 ON t1.advertiser_name = t2.name
         WHERE t2.id is not null
         <if test="mediaType != null and mediaType != '' ">
             AND media_type = #{mediaType}
         </if>
-        GROUP BY t1.advertiser_name
+        GROUP BY t2.name
     </select>
 
     <select id="getProductByAdvertiserIds" resultType="com.alibaba.fastjson.JSONObject">