Merge remote-tracking branch 'origin/develop' into develop

master
luoyang 6 years ago
commit 47dbaed230

@ -10,6 +10,11 @@
<modelVersion>4.0.0</modelVersion>
<artifactId>manage</artifactId>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jib-maven-plugin.version>1.1.2</jib-maven-plugin.version>
<docker-image.version>1.0.1</docker-image.version>
</properties>
<dependencies>
<dependency>
@ -197,6 +202,28 @@
<executable>true</executable>
</configuration>
</plugin>
<plugin>
<groupId>com.google.cloud.tools</groupId>
<artifactId>jib-maven-plugin</artifactId>
<version>${jib-maven-plugin.version}</version>
<configuration>
<from>
<image>hkccr.ccs.tencentyun.com/cross-payment/base:v1.0</image>
</from>
<to>
<image>hkccr.ccs.tencentyun.com/cross-payment-dev/manage-dev:${docker-image.version}</image>
</to>
<allowInsecureRegistries>true</allowInsecureRegistries>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>build</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>

@ -422,4 +422,6 @@ public interface ClientManager {
void resetRefundPasswordByManage(String clientMoniker,JSONObject manage, JSONObject json);
List<Integer> listLevel3Client(int client_id);
void updateRefundCreditLine(JSONObject manager, String clientMoniker, JSONObject refundLineInfo);
}

@ -33,6 +33,7 @@ import au.com.royalpay.payment.manage.merchants.beans.*;
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.signin.beans.TodoNotice;
import au.com.royalpay.payment.manage.signin.core.ManagerTodoNoticeProvider;
import au.com.royalpay.payment.manage.signin.core.SignInAccountService;
@ -1877,6 +1878,22 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
return clientMapper.childClientId(clientId);
}
@Override
public void updateRefundCreditLine(JSONObject manager, String clientMoniker, JSONObject refundLineInfo) {
JSONObject client = getClientInfoByMoniker(clientMoniker);
if (client == null) {
throw new InvalidShortIdException();
}
OrgCheckUtils.checkOrgPermission(manager, client);
JSONObject update = new JSONObject();
int clientId = client.getIntValue("client_id");
BigDecimal refundCreditLine = refundLineInfo.getBigDecimal("refund_credit_line");
update.put("client_id", clientId);
update.put("refund_credit_line", refundCreditLine);
clientMapper.update(update);
clientInfoCacheSupport.clearClientCache(clientId);
}
@Override
@Transactional
public void updateClientBDUsers(JSONObject manager, String clientMoniker, JSONObject data) throws Exception {

@ -169,6 +169,11 @@ public class PartnerManageController {
clientManager.updateClientPaymentConfig(manager, clientMoniker, subMerchantInfo);
}
@ManagerMapping(value = "/{clientMoniker}/refund_credit_line", method = RequestMethod.PUT, role = {ManagerRole.OPERATOR, ManagerRole.BD_USER})
public void updateRefundCreditLine(@PathVariable String clientMoniker, @RequestBody JSONObject refundLineInfo, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
clientManager.updateRefundCreditLine(manager, clientMoniker, refundLineInfo);
}
@ManagerMapping(value = "/{clientMoniker}/rpay_payment_config", method = RequestMethod.PUT, role = {ManagerRole.OPERATOR, ManagerRole.BD_USER})
public void updatePartnerRpayPaymentConfig(@PathVariable String clientMoniker, @RequestBody JSONObject rpaySubMerchantInfo, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
clientManager.updateClientRpayPaymentConfig(manager, clientMoniker, rpaySubMerchantInfo);

@ -1422,6 +1422,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
$scope.ctrl.editMaxOrderAmount = false;
$scope.ctrl.editOrderExpiryConfig = false;
$scope.ctrl.editRefundPwd = false;
$scope.ctrl.editRefundCreditLine = false;
})
};
$scope.qrConfig = {currency: 'AUD'};
@ -1502,6 +1503,17 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
})
};
$scope.setRefundCreditLine = function () {
if (!$scope.paymentInfo) {
return;
}
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/refund_credit_line', {refund_credit_line: $scope.paymentInfo.refund_credit_line}).then(function (resp) {
$scope.loadPartnerPaymentInfo();
}, function (resp) {
commonDialog.alert({title: 'Error', content: resp.data.message, type: 'error'})
});
};
$scope.updateClientQRCodePaySurCharge = function () {
if (!$scope.paymentInfo) {
return;

@ -495,6 +495,33 @@
</div>
</div>
<!--授信退款额度-->
<div class="form-group" ng-if="('100000000'|withRole)&& paymentInfo.enable_pre_refund">
<label class="col-sm-2 control-label">Refund Credit Line</label>
<div class="col-sm-9">
<p ng-if="!ctrl.editRefundCreditLine" class="form-control-static">
{{paymentInfo.refund_credit_line||'Not Configure'}}
<a role="button" ng-click="ctrl.editRefundCreditLine=true" ng-if="'01'|withRole"><i
class="fa fa-edit"></i></a>
</p>
<div class="input-group" ng-if="ctrl.editRefundCreditLine">
<input type="number" maxlength="6" class="form-control"
ng-model="paymentInfo.refund_credit_line">
<div class="input-group-btn">
<button class="btn btn-success"
ng-click="setRefundCreditLine()">
<i class="fa fa-check"></i>
</button>
</div>
<div class="input-group-btn">
<button class="btn btn-danger" ng-click="ctrl.editRefundCreditLine=false">
<i class="fa fa-remove"></i>
</button>
</div>
</div>
</div>
</div>
<div class="form-group" ng-if="('100000000'|withRole)">
<label class="col-sm-2 control-label">Reset Refund Password</label>
<div class="col-sm-9">

Loading…
Cancel
Save