From 7dc7748f7e18e29edbcbcd1ef807391f58f96e8e Mon Sep 17 00:00:00 2001 From: wangning <164851225@qq.com> Date: Mon, 2 Apr 2018 18:45:46 +0800 Subject: [PATCH] update contract --- .../merchants/web/PartnerManageController.java | 6 +++--- src/main/ui/static/payment/partner/partner-manage.js | 8 +++++++- .../partner/templates/partner_auth_files.html | 12 ++++++++++++ 3 files changed, 22 insertions(+), 4 deletions(-) diff --git a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java index 2ecab3a50..3f351db4d 100644 --- a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java +++ b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java @@ -534,9 +534,9 @@ public class PartnerManageController { clientContractService.confirmSourceAgreement(account.getIntValue("client_id"),account.getString("account_id"),"PC"); } - @ManagerMapping(value = "/{clientMoniker}/skip_contract", method = RequestMethod.PUT, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.FINANCIAL_STAFF}) - public void skipContract(@PathVariable String clientMoniker, @RequestBody JSONObject skip_clearing) { - clientManager.setSkipClearing(clientMoniker, skip_clearing.getBooleanValue("skip_contract")); + @ManagerMapping(value = "/{clientMoniker}/skip_contract", method = RequestMethod.PUT, role = {ManagerRole.ADMIN, ManagerRole.FINANCIAL_STAFF}) + public void skipContract(@PathVariable String clientMoniker, @RequestBody JSONObject skip_contract) { + clientManager.setSkipContract(clientMoniker, skip_contract.getBooleanValue("skip_contract")); } } diff --git a/src/main/ui/static/payment/partner/partner-manage.js b/src/main/ui/static/payment/partner/partner-manage.js index 696891f96..fad7cbb74 100644 --- a/src/main/ui/static/payment/partner/partner-manage.js +++ b/src/main/ui/static/payment/partner/partner-manage.js @@ -2350,7 +2350,13 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter $scope.downloadAsZip = function () { var url = '/sys/partners/' + $scope.partner.client_moniker + '/download/complianceAsZIP'; return url; - } + }; + + $scope.setSkipContract = function () { + $http.put('/sys/partners/' + $scope.partner.client_moniker + '/skip_contract',{skip_contract: $scope.partner.skip_contract}).then(function(){ + + }) + }; $scope.updateFile = function () { $http.put('/sys/partners/' + $scope.partner.client_moniker + '/file', $scope.file).then(function () { diff --git a/src/main/ui/static/payment/partner/templates/partner_auth_files.html b/src/main/ui/static/payment/partner/templates/partner_auth_files.html index b2e069690..e368df880 100644 --- a/src/main/ui/static/payment/partner/templates/partner_auth_files.html +++ b/src/main/ui/static/payment/partner/templates/partner_auth_files.html @@ -3,6 +3,18 @@ width: 100%; } +