From b20384f400e871009d68ae6837d16573e462f58a Mon Sep 17 00:00:00 2001 From: luoyang Date: Wed, 25 Mar 2020 16:41:46 +0800 Subject: [PATCH 1/3] fix search date range --- src/main/ui/static/analysis/transaction/analysis-transaction.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/ui/static/analysis/transaction/analysis-transaction.js b/src/main/ui/static/analysis/transaction/analysis-transaction.js index 54c1448dd..c813a898d 100644 --- a/src/main/ui/static/analysis/transaction/analysis-transaction.js +++ b/src/main/ui/static/analysis/transaction/analysis-transaction.js @@ -882,7 +882,7 @@ define(['angular', 'uiBootstrap', 'uiRouter', 'angularEcharts','echarts'], funct }); }; - $scope.chooseLast7Days(); + $scope.thisMonth(); $scope.loadTopTransPartners = function (page) { var requestParams = angular.copy($scope.params); if (requestParams.from) { From 698ec555775bcf64dcc5fd3cb7477b4b7fe6263b Mon Sep 17 00:00:00 2001 From: luoyang Date: Wed, 25 Mar 2020 17:04:48 +0800 Subject: [PATCH 2/3] =?UTF-8?q?fix=20echarts=20partner=E4=B8=BAfalse?= =?UTF-8?q?=E5=8A=A01=E6=83=85=E5=86=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 2 +- .../manage/dataAnalysis/core/DataAnalysisServiceImpl.java | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 2963cc568..d87fed4ea 100644 --- a/pom.xml +++ b/pom.xml @@ -9,7 +9,7 @@ 4.0.0 manage - 1.4.14 + 1.4.15 UTF-8 1.8.0 diff --git a/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/core/DataAnalysisServiceImpl.java b/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/core/DataAnalysisServiceImpl.java index bb30e94cf..23cc25d9c 100644 --- a/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/core/DataAnalysisServiceImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/core/DataAnalysisServiceImpl.java @@ -6,6 +6,7 @@ import au.com.royalpay.payment.tools.utils.PageListUtils; import com.alibaba.fastjson.JSONObject; import com.github.miemiedev.mybatis.paginator.domain.PageBounds; import com.github.miemiedev.mybatis.paginator.domain.PageList; +import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.time.DateFormatUtils; import org.apache.commons.lang3.time.DateUtils; import org.springframework.stereotype.Service; @@ -76,6 +77,10 @@ public class DataAnalysisServiceImpl implements DataAnalysisService { BigDecimal totalClients = new BigDecimal(clientAnalysisMapper.countValidClientsAll(industry)); for (JSONObject detail : data) { BigDecimal industryClients = detail.getBigDecimal("industry_trans_clients"); + if (!StringUtils.equalsIgnoreCase("0", industry)) { + industryClients = industryClients.subtract(new BigDecimal(1)); + detail.put("industry_trans_clients", industryClients.setScale(0, RoundingMode.DOWN)); + } detail.put("total_client", totalClients.setScale(0, RoundingMode.DOWN)); detail.put("in_total_pcent", industryClients.divide(totalClients, 4, RoundingMode.HALF_UP).multiply(new BigDecimal(100))); } From c65b6a257ded479c46f5d7b1664cc2fc7316d5e4 Mon Sep 17 00:00:00 2001 From: luoyang Date: Thu, 26 Mar 2020 14:18:15 +0800 Subject: [PATCH 3/3] =?UTF-8?q?fix=20=E4=BC=98=E5=8C=96=E5=95=86=E6=88=B7?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=A2=9E=E5=80=BC=E6=9C=8D=E5=8A=A1=EF=BC=8C?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=96=B0=E5=A2=9E=E4=BB=98=E8=B4=B9debit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 2 +- .../core/impls/ClientManagerImpl.java | 22 +++++++++-- .../rservices/core/RServicesApplyService.java | 2 + .../core/impl/RServicesApplyServiceImpl.java | 8 +++- .../static/payment/partner/partner-manage.js | 4 +- .../templates/incremental_service_dialog.html | 38 +++++++++++-------- 6 files changed, 51 insertions(+), 25 deletions(-) diff --git a/pom.xml b/pom.xml index d87fed4ea..bf87b9d42 100644 --- a/pom.xml +++ b/pom.xml @@ -9,7 +9,7 @@ 4.0.0 manage - 1.4.15 + 1.4.16 UTF-8 1.8.0 diff --git a/src/main/java/au/com/royalpay/payment/manage/merchants/core/impls/ClientManagerImpl.java b/src/main/java/au/com/royalpay/payment/manage/merchants/core/impls/ClientManagerImpl.java index 4fd1ec219..8aedaff3b 100644 --- a/src/main/java/au/com/royalpay/payment/manage/merchants/core/impls/ClientManagerImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/merchants/core/impls/ClientManagerImpl.java @@ -42,6 +42,7 @@ import au.com.royalpay.payment.manage.merchants.core.*; import au.com.royalpay.payment.manage.merchants.entity.impls.*; import au.com.royalpay.payment.manage.notice.core.MailService; import au.com.royalpay.payment.manage.permission.utils.OrgCheckUtils; +import au.com.royalpay.payment.manage.rservices.core.RServicesApplyService; import au.com.royalpay.payment.manage.signin.beans.TodoNotice; import au.com.royalpay.payment.manage.signin.core.ManagerTodoNoticeProvider; import au.com.royalpay.payment.manage.signin.core.SignInAccountService; @@ -310,6 +311,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid private GatewayMerchantApply gatewayMerchantApply; @Resource private RetailRSvcService retailRSvcService; + @Resource + private RServicesApplyService rServicesApplyService; @Resource @@ -6582,15 +6585,26 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid } saveIncrementalService.put("client_id", client.getInteger("client_id")); saveIncrementalService.put("operator", manager.getString("display_name")); - saveIncrementalService.put("incremental_mode", incrementalService.getInteger("incremental_mode")); - saveIncrementalService.put("incremental_rate_value", incrementalService.getInteger("incremental_mode") == 1 ? incrementalService.getString("incremental_rate_value") : 0); - saveIncrementalService.put("total_incremental_amount", incrementalService.getInteger("incremental_mode") != 1 ? incrementalService.getString("total_incremental_amount") : 0); + //增值模式1:固定手续费;2:固定金额扣款 + saveIncrementalService.put("incremental_mode", incrementalService.getIntValue("incremental_rate_value") == 0 ? 2 : 1); + saveIncrementalService.put("incremental_rate_value", incrementalService.getString("incremental_rate_value")); + saveIncrementalService.put("total_incremental_amount", incrementalService.getString("total_incremental_amount")); + saveIncrementalService.put("title", incrementalService.getString("title")); if (existIncrementalService == null) { clientIncrementalMapper.save(saveIncrementalService); + if (incrementalService.getBigDecimal("total_incremental_amount").compareTo(new BigDecimal(0)) > 0) { + saveIncrementalService.put("amount", incrementalService.getString("total_incremental_amount")); + saveIncrementalService.put("service_code", "RYCBSM"); + String title = incrementalService.getString("title"); + if (StringUtils.isBlank(title)) { + title = "RP跨境商城开通费用"; + } + saveIncrementalService.put("title", title); + rServicesApplyService.saveDebitDetail(saveIncrementalService, client); + } } else { clientIncrementalMapper.update(saveIncrementalService); } - } @Override diff --git a/src/main/java/au/com/royalpay/payment/manage/rservices/core/RServicesApplyService.java b/src/main/java/au/com/royalpay/payment/manage/rservices/core/RServicesApplyService.java index 15418afcf..f9a30854d 100644 --- a/src/main/java/au/com/royalpay/payment/manage/rservices/core/RServicesApplyService.java +++ b/src/main/java/au/com/royalpay/payment/manage/rservices/core/RServicesApplyService.java @@ -10,4 +10,6 @@ public interface RServicesApplyService { void passServicesApply(String applyId, JSONObject manager); void refuseServicesApply(String applyId, JSONObject manager); + + void saveDebitDetail(JSONObject applyInfo, JSONObject client); } diff --git a/src/main/java/au/com/royalpay/payment/manage/rservices/core/impl/RServicesApplyServiceImpl.java b/src/main/java/au/com/royalpay/payment/manage/rservices/core/impl/RServicesApplyServiceImpl.java index 5d7a07efa..a1f50a21c 100644 --- a/src/main/java/au/com/royalpay/payment/manage/rservices/core/impl/RServicesApplyServiceImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/rservices/core/impl/RServicesApplyServiceImpl.java @@ -141,6 +141,12 @@ public class RServicesApplyServiceImpl implements RServicesApplyService { private void afterPassProcessingApply(JSONObject applyInfo) { JSONObject client = clientManager.getClientInfo(applyInfo.getIntValue("client_id")); + saveDebitDetail(applyInfo, client); + sendNotify(applyInfo, client); + } + + @Override + public void saveDebitDetail(JSONObject applyInfo, JSONObject client) { String orderId = "R-" + client.getString("client_moniker") + "-" + applyInfo.getString("service_code") + "-" + DateFormatUtils.format(new Date(), "yyyyMMddHHmmssSSS") + "-" + RandomStringUtils.random(3, true, false).toUpperCase(); JSONObject transaction = new JSONObject(); transaction.put("org_id", client.getIntValue("org_id")); @@ -182,8 +188,6 @@ public class RServicesApplyServiceImpl implements RServicesApplyService { order.put("status", 7); order.put("channel", "System"); pmtOrderMapper.save(order); - - sendNotify(applyInfo, client); } private void sendNotify(JSONObject applyInfo, JSONObject client) { diff --git a/src/main/ui/static/payment/partner/partner-manage.js b/src/main/ui/static/payment/partner/partner-manage.js index 49d1cfb4c..c4b9dbebf 100644 --- a/src/main/ui/static/payment/partner/partner-manage.js +++ b/src/main/ui/static/payment/partner/partner-manage.js @@ -5759,13 +5759,11 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter $scope.isCreate = true; $scope.initData =function(){ $scope.isCreate = angular.copy(params.isCreate); - if($scope.isCreate ){ - $scope.model.incremental_mode = "1" + if($scope.isCreate){ $scope.model.channel= angular.copy(params.channelOptions[0]) $scope.model.channelOptions= angular.copy(params.channelOptions) }else{ $scope.model = angular.copy(params.serviceChannel); - $scope.model.incremental_mode = $scope.model.incremental_mode.toString() } } $scope.initData(); diff --git a/src/main/ui/static/payment/partner/templates/incremental_service_dialog.html b/src/main/ui/static/payment/partner/templates/incremental_service_dialog.html index 0c2de0935..c75da2ff5 100644 --- a/src/main/ui/static/payment/partner/templates/incremental_service_dialog.html +++ b/src/main/ui/static/payment/partner/templates/incremental_service_dialog.html @@ -18,19 +18,7 @@ -
- -
- - Required Field -
-
-
+
@@ -50,7 +38,8 @@
-
+
+
+ +
+ +
+
+
+ +
+ +
+
+ Required Field +
+
+
+
@@ -69,4 +77,4 @@ \ No newline at end of file +