From 84505818abde68b939d1d33952e86ac753c8174d Mon Sep 17 00:00:00 2001 From: luoyang Date: Fri, 26 Apr 2019 17:52:12 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E9=9A=90=E8=97=8F=E5=90=8E=E6=89=8B?= =?UTF-8?q?=E7=BB=AD=E8=B4=B9=E6=94=AF=E5=87=BA=E5=92=8C=E6=94=B6=E5=85=A5?= =?UTF-8?q?=E3=80=81=E6=9C=88=E5=BA=A6=E5=85=85=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../partner-surcharge-account.js | 48 +------------ .../templates/account_month_logs.html | 8 +-- ...artner_surcharge_account_month_dialog.html | 71 +++++++++++++++++++ 3 files changed, 76 insertions(+), 51 deletions(-) create mode 100644 src/main/ui/static/payment/surchargeaccount/templates/partner_surcharge_account_month_dialog.html diff --git a/src/main/ui/static/payment/surchargeaccount/partner-surcharge-account.js b/src/main/ui/static/payment/surchargeaccount/partner-surcharge-account.js index c122470b7..62010c891 100644 --- a/src/main/ui/static/payment/surchargeaccount/partner-surcharge-account.js +++ b/src/main/ui/static/payment/surchargeaccount/partner-surcharge-account.js @@ -49,27 +49,6 @@ define(['angular', 'decimal', 'uiBootstrap', 'uiRouter', 'angularEcharts'], func }) }; $scope.getDetailByMonths(); - $scope.surchargeAccountDetail = function (client_moniker,mon) { - $uibModal.open({ - templateUrl: '/static/payment/surchargeaccount/templates/client_surcharge_account_dialog.html', - controller: 'accountDetailCtrl', - size: 'lg', - resolve: { - client_moniker: function () { - return client_moniker; - }, - month: function () { - return mon; - }, - transactions: ['$http', function ($http) { - return $http.get('/client/partner_info/' + client_moniker + '/account/transactions/date?date=' + mon); - }] - } - }); - }; - - - }]); app.controller('surchargeAccountMonthCtrl', ['$scope', '$http', '$filter', '$timeout', '$uibModal', 'commonDialog', 'chartParser','$sce', function ($scope, $http, $filter, $timeout, $uibModal, commonDialog, chartParser, $sce) { @@ -100,7 +79,7 @@ define(['angular', 'decimal', 'uiBootstrap', 'uiRouter', 'angularEcharts'], func }; $scope.surchargeAccountDetail = function (client_moniker,mon) { $uibModal.open({ - templateUrl: '/static/payment/surchargeaccount/templates/partner_surcharge_account_dialog.html', + templateUrl: '/static/payment/surchargeaccount/templates/partner_surcharge_account_month_dialog.html', controller: 'accountDetailCtrl', size: 'lg', resolve: { @@ -145,11 +124,8 @@ define(['angular', 'decimal', 'uiBootstrap', 'uiRouter', 'angularEcharts'], func }]); app.controller('accountDetailCtrl', ['$scope','$http','transactions','client_moniker','commonDialog','month', function ($scope, $http, transactions,client_moniker,commonDialog,month) { $scope.transactions = angular.copy(transactions.data); - $scope.canAddDetail = false; $scope.params = {}; $scope.month = angular.copy(month); - - $scope.getBalance = function () { $http.get('/sys/partners/' + client_moniker + '/surcharge_account').then(function (resp) { $scope.surcharge = resp.data; @@ -157,33 +133,11 @@ define(['angular', 'decimal', 'uiBootstrap', 'uiRouter', 'angularEcharts'], func }; $scope.getBalance(); - $scope.getTransactions = function () { $http.get('/sys/partners/' + client_moniker + '/account/transactions/date?date=' + $scope.month).then(function (resp) { $scope.transactions = resp.data; }); } - - $scope.addDetail = function () { - $scope.canAddDetail = true; - }; - - $scope.cancel = function () { - $scope.canAddDetail = false; - $scope.params = {}; - } - $scope.save = function () { - $http.post('/sys/partners/' + client_moniker + '/account/save', {amount:$scope.params.amount,remark:$scope.params.remark}).then(function (resp) { - $scope.getTransactions(); - $scope.getBalance(); - $scope.canAddDetail = false; - $scope.params = {}; - }, function (resp) { - commonDialog.alert({title: 'Error', content: resp.data.message, type: 'error'}); - }); - } - - }]); diff --git a/src/main/ui/static/payment/surchargeaccount/templates/account_month_logs.html b/src/main/ui/static/payment/surchargeaccount/templates/account_month_logs.html index acc93428d..7cbc3b58e 100644 --- a/src/main/ui/static/payment/surchargeaccount/templates/account_month_logs.html +++ b/src/main/ui/static/payment/surchargeaccount/templates/account_month_logs.html @@ -47,8 +47,8 @@ 商户编号 Short Name Total Surcharge - 充值总额 - 支出总额 + + 是否结清 操作 @@ -63,8 +63,8 @@ - - + + 已结清 未付款 diff --git a/src/main/ui/static/payment/surchargeaccount/templates/partner_surcharge_account_month_dialog.html b/src/main/ui/static/payment/surchargeaccount/templates/partner_surcharge_account_month_dialog.html new file mode 100644 index 000000000..e3fc2fddd --- /dev/null +++ b/src/main/ui/static/payment/surchargeaccount/templates/partner_surcharge_account_month_dialog.html @@ -0,0 +1,71 @@ + +