From 1004f3d16011f69894196bfd180ea539b76ba4e7 Mon Sep 17 00:00:00 2001
From: zj <1772600164@qq.com>
Date: Wed, 03 Jun 2026 15:27:26 +0800
Subject: [PATCH] 1

---
 trading-order-admin/src/main/java/com/yami/trading/api/controller/ApiBankCardController.java |   67 +++++++++++++++++----------------
 1 files changed, 34 insertions(+), 33 deletions(-)

diff --git a/trading-order-admin/src/main/java/com/yami/trading/api/controller/ApiBankCardController.java b/trading-order-admin/src/main/java/com/yami/trading/api/controller/ApiBankCardController.java
index 80de65c..1c48ad2 100644
--- a/trading-order-admin/src/main/java/com/yami/trading/api/controller/ApiBankCardController.java
+++ b/trading-order-admin/src/main/java/com/yami/trading/api/controller/ApiBankCardController.java
@@ -87,7 +87,7 @@
 
         if (null == cpmMap || 0 == cpmMap.size()) {
             // TODO: 2023/4/16
-            throw new YamiShopBindException("支付方式不存在");
+            throw new YamiShopBindException("Payment method does not exist");
         }
         List<String> cpmList = new ArrayList<String>();
         for (String key : cpmMap.keySet()) {
@@ -101,11 +101,11 @@
 
     private String verif(String direction, String nationality, String currency, String payment_method_id, String coin_amount, String img) {
         if (StringUtils.isEmptyString(direction) || !Arrays.asList("recharge", "withdraw").contains(direction)) {
-            return "充值或提现不正确";
+            return "Invalid recharge or withdrawal type";
         }
         Map<String, String> currencyMap = this.c2cPaymentMethodService.getCurrencyMap();
         if (StringUtils.isEmptyString(currency) || null == currencyMap || (null != currencyMap && !currencyMap.containsKey(currency))) {
-            return "支付币种不正确";
+            return "Invalid payment currency";
         }
         if (StringUtils.isEmptyString(payment_method_id)) {
             return "支付方式不正确";
@@ -121,7 +121,7 @@
             boolean bank_card_recharge_must_need_img = this.sysparaService.find("bank_card_recharge_must_need_img").getBoolean();
             if (bank_card_recharge_must_need_img) {
                 if (StringUtils.isEmptyString(img)) {
-                    return "请上传图片";
+                    return "Please upload an image";
                 }
             }
         }
@@ -150,7 +150,7 @@
             // 已用额度
             double weekWithdraw = this.weekWithdraw(user.getUserId());
             if (Arith.add(weekWithdraw, withdrawVolumn) > limit) {
-                throw new YamiShopBindException("提现不得大于限额");
+                throw new YamiShopBindException("Withdrawal amount cannot exceed the limit.");
             }
         }
     }
@@ -232,18 +232,18 @@
         Object object = this.sessionTokenService.cacheGet(session_token);
         this.sessionTokenService.del(session_token);
         if (null == object || !userId.equals((String) object)) {
-            throw new YamiShopBindException("请稍后再试");
+            throw new YamiShopBindException("Please try again later");
         }
         String partyId = SecurityUtils.getUser().getUserId();
         if (null == partyId) {
-            throw new YamiShopBindException("请重新登录");
+            throw new YamiShopBindException("Please log in again");
         }
         User party = userService.getById(partyId);
         if (Constants.SECURITY_ROLE_TEST.equals(party.getRoleName())) {
-            throw new YamiShopBindException("无权限");
+            throw new YamiShopBindException("Permission denied");
         }
         if (!party.isEnabled()) {
-            throw new YamiShopBindException("用户已锁定");
+            throw new YamiShopBindException("User is locked");
         }
         // 手续费
         double fee = 0;
@@ -272,7 +272,7 @@
                 party_kyc=new RealNameAuthRecord();
             }
             if (!(party_kyc.getStatus() == 2) && "true".equals(this.sysparaService.find("withdraw_by_kyc").getSvalue())) {
-                throw new YamiShopBindException("无权限");
+                throw new YamiShopBindException("Permission denied");
             }
             HighLevelAuthRecord party_kycHighLevel = highLevelAuthRecordService.findByUserId(partyId);
             if (party_kycHighLevel==null){
@@ -280,10 +280,10 @@
             }
             double withdraw_by_high_kyc = Double.valueOf(this.sysparaService.find("withdraw_by_high_kyc").getSvalue());
             if (withdraw_by_high_kyc > 0 && coin_amount_double > withdraw_by_high_kyc && !(party_kycHighLevel.getStatus() == 2)) {
-                throw new YamiShopBindException("请先通过高级认证");
+                throw new YamiShopBindException("Advanced verification required");
             }
 //                if (!party.getWithdraw_authority()) {
-//                    throw new BusinessException(1, "无权限");
+//                    throw new BusinessException(1, "Permission denied");
 //                }
             // 手续费(USDT) 提现手续费类型,fixed是单笔固定金额,rate是百分比,part是分段
             String withdraw_fee_type = this.sysparaService.find("withdraw_fee_type").getSvalue();
@@ -312,11 +312,11 @@
             }
             String withdraw_limit = this.sysparaService.find("withdraw_limit").getSvalue();
             if (coin_amount_double < Double.valueOf(withdraw_limit)) {
-                throw new YamiShopBindException("提现不得小于限额");
+                throw new YamiShopBindException("Withdrawal amount must not be less than the limit.");
             }
             String withdraw_limit_max = this.sysparaService.find("withdraw_limit_max").getSvalue();
             if (coin_amount_double > Double.valueOf(withdraw_limit_max)) {
-                throw new YamiShopBindException("提现不得大于限额");
+                throw new YamiShopBindException("Withdrawal amount cannot exceed the limit.");
             }
             // 检测银行卡用户当日提现次数
             Object obj = this.sysparaService.find("bank_card_withdraw_limit_num");
@@ -328,7 +328,7 @@
 
                 if (bank_card_withdraw_limit_num > 0 && c2cOrders != null) {
                     if (c2cOrders.size() >= bank_card_withdraw_limit_num) {
-                        throw new YamiShopBindException("当日可提现次数不足");
+                        throw new YamiShopBindException("The number of times funds can be withdrawn on the same day is insufficient.");
                     }
                 }
             }
@@ -341,7 +341,7 @@
                 String[] withdraw_time = withdraw_limit_time.split("-");
                 String dateString = sdf.format(date);
                 if (dateString.compareTo(withdraw_time[0]) < 0 || dateString.compareTo(withdraw_time[1]) > 0) {
-                    throw new YamiShopBindException("不在可提现时间内");
+                    throw new YamiShopBindException("Not within the available withdrawal period");
                 }
             }
             // 周提现额度限制开关
@@ -387,10 +387,10 @@
                     }
                     double withdraw_limit_turnover_percent = Double.valueOf(this.sysparaService.find("withdraw_limit_turnover_percent").getSvalue());
                     party_withdraw = Arith.mul(party_withdraw, withdraw_limit_turnover_percent);
-                    // 流水小于限额
+                    // Turnover below minimum limit
                     if (userdata_turnover < party_withdraw) {
                         fact_withdraw_amount = Arith.sub(party_withdraw, userdata_turnover);
-                        throw new YamiShopBindException("流水小于限额");
+                        throw new YamiShopBindException("Turnover below minimum limit");
                     }
                 }
                 if ("2".equals(withdraw_limit_open_use_type)) {
@@ -402,7 +402,7 @@
                     double userdata_turnover = party.getWithdrawLimitNowAmount().doubleValue();
                     double withdraw_limit_turnover_percent = Double.valueOf(this.sysparaService.find("withdraw_limit_turnover_percent").getSvalue());
                     party_withdraw = Arith.mul(party_withdraw, withdraw_limit_turnover_percent);
-                    // 流水小于限额
+                    // Turnover below minimum limit
                     if (userdata_turnover < party_withdraw) {
                         fact_withdraw_amount = Arith.sub(party_withdraw, userdata_turnover);
                         throw new YamiShopBindException(fact_withdraw_amount + "");
@@ -421,13 +421,13 @@
         Object obj1 = this.sysparaService.find("bank_card_order_cancel_day_times");
         if (null != obj1) {
             if (orderCancelDayTimes >= Integer.valueOf(this.sysparaService.find("bank_card_order_cancel_day_times").getSvalue()).intValue()) {
-                throw new YamiShopBindException("今日取消订单次数太多了,请明日再试");
+                throw new YamiShopBindException("Too many cancellations today, try again tomorrow");
             }
         }
         DecimalFormat df = new DecimalFormat("#.########");
         ExchangeRate ex = this.exchangeRateService.findBy(Constants.OUT_OR_IN_DEFAULT, currency.toUpperCase());
         if (null == ex) {
-            throw new YamiShopBindException("支付币种不正确");
+            throw new YamiShopBindException("Invalid payment currency");
         }
         C2cOrder c2cOrder = new C2cOrder();
         c2cOrder.setPartyId(party.getUserId());
@@ -458,20 +458,20 @@
     public Result orderCancel(String order_no, String remark) {
         User party = userService.getById(SecurityUtils.getUser().getUserId());
         if (Constants.SECURITY_ROLE_TEST.equals(party.getRoleName())) {
-            throw new YamiShopBindException("无权限");
+            throw new YamiShopBindException("Permission denied");
         }
         if (!party.isEnabled()) {
-            throw new YamiShopBindException("用户已锁定");
+            throw new YamiShopBindException("User is locked");
         }
         C2cOrder order = this.c2cOrderService.get(order_no);
         if (null == order || !order.getPartyId().equals(SecurityUtils.getUser().getUserId())) {
-            throw new YamiShopBindException("订单不存在");
+            throw new YamiShopBindException("Order does not exist");
         }
         order.setRemark(remark);
-        // 用户不能取消提现
+        // User cannot cancel this withdrawal
         if (SecurityUtils.getUser().getUserId().equals(order.getPartyId())) {
             if ("withdraw".equals(order.getDirection())) {
-                throw new YamiShopBindException("用户不能取消提现");
+                throw new YamiShopBindException("User cannot cancel this withdrawal");
             }
             this.c2cOrderService.saveOrderCancel(order, "user");
         }
@@ -486,7 +486,7 @@
     public Result get(@RequestParam String order_no, @RequestParam String language) {
         C2cOrder c2cOrder = this.c2cOrderService.get(order_no);
         if (null == c2cOrder) {
-            throw new YamiShopBindException("订单不存在");
+            throw new YamiShopBindException("Order does not exist");
         }
         List<String> nos = new ArrayList<String>();
         nos.add(c2cOrder.getOrderNo());
@@ -499,7 +499,8 @@
 //            c2cOrder.setUnreadMsg(unreadMsg.intValue());
 //        }
         if (StringUtils.isNotEmpty(c2cOrder.getMethodImg())) {
-            String path = Constants.WEB_URL + "/public/showimg!showImg.action?imagePath=" + c2cOrder.getMethodImg();
+            //String path = Constants.WEB_URL + "/public/showimg!showImg.action?imagePath=" + c2cOrder.getMethodImg();
+            String path = Constants.IMAGES_HTTP + c2cOrder.getMethodImg();
             c2cOrder.setMethodImg(path);
         }
         // 多语言
@@ -547,23 +548,23 @@
     public Result list(String page_no, String direction, String state) {
         String partyId = SecurityUtils.getUser().getUserId();
         if (null == partyId) {
-            throw new YamiShopBindException("请重新登录");
+            throw new YamiShopBindException("Please log in again");
         }
         if (StringUtils.isNullOrEmpty(page_no)) {
             page_no = "1";
         }
         if (!StringUtils.isInteger(page_no)) {
-            throw new YamiShopBindException("页码不是整数");
+            throw new YamiShopBindException("Page number must be an integer");
         }
         if (Integer.valueOf(page_no).intValue() <= 0) {
-            throw new YamiShopBindException("页码不能小于等于0");
+            throw new YamiShopBindException("Page number must be greater than 0");
         }
         int page_no_int = Integer.valueOf(page_no).intValue();
         if (StringUtils.isNotEmpty(direction) && !Arrays.asList("recharge", "withdraw").contains(direction)) {
-            throw new YamiShopBindException("充值或提现不正确");
+            throw new YamiShopBindException("Invalid recharge or withdrawal type");
         }
         if (StringUtils.isNotEmpty(state) && !Arrays.asList("0", "3", "4").contains(state)) {
-            throw new YamiShopBindException("订单状态不正确");
+            throw new YamiShopBindException("Invalid order status");
         }
         Page page = this.c2cOrderService.pagedQuery(page_no_int, 20, direction, state, partyId);
         if (null == page) {

--
Gitblit v1.9.3