add 新增aps组织的费率配置

master
Todking 3 years ago
parent a0d059ee9d
commit d68c514376

@ -1,6 +1,6 @@
package au.com.royalpay.payment.manage.merchants.core;
import au.com.royalpay.payment.manage.merchants.core.descriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.deacriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.entity.ApsConfigData;
import com.alibaba.fastjson.JSONObject;

@ -2,7 +2,7 @@ package au.com.royalpay.payment.manage.merchants.core.impls;
import au.com.royalpay.payment.manage.mappers.system.aps.ApsConfigMapper;
import au.com.royalpay.payment.manage.merchants.core.ApsConfigService;
import au.com.royalpay.payment.manage.merchants.core.descriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.deacriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.entity.ApsConfigData;
import com.alibaba.fastjson.JSONObject;
import org.springframework.stereotype.Service;

@ -62,7 +62,7 @@ import au.com.royalpay.payment.manage.merchants.core.*;
import au.com.royalpay.payment.manage.merchants.core.bank.AustraliaBank;
import au.com.royalpay.payment.manage.merchants.core.bank.AustraliaBankClientNullException;
import au.com.royalpay.payment.manage.merchants.core.bank.AustraliaBankInfo;
import au.com.royalpay.payment.manage.merchants.core.descriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.deacriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.entity.ApsConfigData;
import au.com.royalpay.payment.manage.merchants.entity.impls.*;
import au.com.royalpay.payment.manage.merchants.enums.UPayAuthFileEnum;
@ -564,7 +564,6 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
apsConfig = apsConfigService.saveApsConfigClientId(manager.getString("manager_id"), client.getString("client_id"), new ApsConfigDescriptor());
}
client.put("aps_config_id", apsConfig.getId());
client.put("enable_alipayaps", apsConfig.getEnableAlipayAps());
client.put("alipay_cn_switch", apsConfig.getAlipayCnSwitch());
return client;
}
@ -1594,17 +1593,11 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
if (client == null) {
throw new NotFoundException("Client Not Exists");
}
if (channelApi.channel().equalsIgnoreCase("alipayaps")) {
JSONObject jsonObject = new JSONObject();
jsonObject.put("enableAlipayAps", allow);
apsConfigService.updateApsConfigClientId(manager.getString("manager_id"), client.getString("client_id"), jsonObject);
} else {
merchantChannelPermissionManager.switchMerchantChannelPermission(channelApi.getMetadata().payChannel(), client.getIntValue("client_id"), allow);
try {
clientModifySupport.processModify(new SwitchPermissionModify(manager, clientMoniker, "enable_" + channel.toLowerCase(), allow));
} catch (Exception e) {
logger.error("Failed to change channel switch:{}", channel);
}
merchantChannelPermissionManager.switchMerchantChannelPermission(channelApi.getMetadata().payChannel(), client.getIntValue("client_id"), allow);
try {
clientModifySupport.processModify(new SwitchPermissionModify(manager, clientMoniker, "enable_" + channel.toLowerCase(), allow));
} catch (Exception e) {
logger.error("Failed to change channel switch:{}", channel);
}
logger.info("{}({}) switched client {} channel {} to {}", manager.getString("display_name"), manager.getString("manager_id"), clientMoniker, channel, allow);
if (allow && (StringUtils.equalsAnyIgnoreCase("Wechat", channel) || StringUtils.equalsAnyIgnoreCase("Alipay", channel))) {
@ -2085,8 +2078,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
if (newConfig.getBigDecimal("cb_bankpay_rate_value") != null) {
clientRateMapper.saveRate(newConfig);
}
} else if("AlipayAps".equalsIgnoreCase(channel)){
newConfig.put("transaction_fee",newConfig.getFloatValue("service_fee_value"));
} else if ("AlipayAps".equalsIgnoreCase(channel)) {
newConfig.put("transaction_fee", newConfig.getFloatValue("service_fee_value"));
clientRateMapper.saveRate(newConfig);
} else {
clientRateMapper.saveRate(newConfig);
@ -7091,6 +7084,7 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
/**
* alipayplus(aps)
*
* @param clientMoniker
* @param apsMerchantApplication
* @param manager
@ -7098,40 +7092,40 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
*/
@Override
public MerchantApplicationResult alipayPlusRegisterMerchant(String clientMoniker, ApsMerchantApplication apsMerchantApplication, JSONObject manager) {
logger.info("====>getWebsiteType:"+apsMerchantApplication.getWebsiteType());
logger.info("====>getProductCodes:"+apsMerchantApplication.getProductCodes().toString());
boolean offline = apsMerchantApplication.getProductCodes().stream().allMatch(s->s.equalsIgnoreCase(ProductCodeType.IN_STORE_PAYMENT.toString()));
logger.info("====>offline:"+offline);
if(offline){
logger.info("====>getWebsiteType:" + apsMerchantApplication.getWebsiteType());
logger.info("====>getProductCodes:" + apsMerchantApplication.getProductCodes().toString());
boolean offline = apsMerchantApplication.getProductCodes().stream().allMatch(s -> s.equalsIgnoreCase(ProductCodeType.IN_STORE_PAYMENT.toString()));
logger.info("====>offline:" + offline);
if (offline) {
//todo 测试需要 先都改成线上,上线此处需要改成线下
apsMerchantApplication.setPid( AlipayEnvironment.getEnv().getAlipayPlusApsRetailConfig().getPid());
}else{
apsMerchantApplication.setPid( AlipayEnvironment.getEnv().getAlipayPlusApsOnlineConfig().getPid());
}
apsMerchantApplication.setPid(AlipayEnvironment.getEnv().getAlipayPlusApsRetailConfig().getPid());
} else {
apsMerchantApplication.setPid(AlipayEnvironment.getEnv().getAlipayPlusApsOnlineConfig().getPid());
}
apsMerchantApplication.setRegion("AU");
JSONObject client= sysClientMapper.findClientByMoniker(clientMoniker);
JSONObject client = sysClientMapper.findClientByMoniker(clientMoniker);
AlipayApsMerchantRegister alipayApsMerchantRegister = Optional.ofNullable(merchantChannelApplicationManager.getRegister(AlipayApsMerchantRegister.class)).orElseThrow(() -> new ServerErrorException("No AlipayAps registry found"));
MerchantApplicationResult result=alipayApsMerchantRegister.apply(client,apsMerchantApplication,manager);
MerchantApplicationResult result = alipayApsMerchantRegister.apply(client, apsMerchantApplication, manager);
return result;
}
@Override
public String queryAlipayPlusOnlineStatus(boolean isRetail,String clientMoniker, JSONObject manager) {
JSONObject client= sysClientMapper.findClientByMoniker(clientMoniker);
client.put("isRetail",isRetail);
String pid="";
if(isRetail){
public String queryAlipayPlusOnlineStatus(boolean isRetail, String clientMoniker, JSONObject manager) {
JSONObject client = sysClientMapper.findClientByMoniker(clientMoniker);
client.put("isRetail", isRetail);
String pid = "";
if (isRetail) {
//todo 测试需要 先都改成线上,上线此处需要改成线下
pid= AlipayEnvironment.getEnv().getAlipayPlusApsRetailConfig().getPid();
}else{
pid= AlipayEnvironment.getEnv().getAlipayPlusApsOnlineConfig().getPid();
pid = AlipayEnvironment.getEnv().getAlipayPlusApsRetailConfig().getPid();
} else {
pid = AlipayEnvironment.getEnv().getAlipayPlusApsOnlineConfig().getPid();
}
client.put("pid",pid);
client.put("pid", pid);
AlipayApsMerchantRegister alipayApsMerchantRegister = Optional.ofNullable(merchantChannelApplicationManager.getRegister(AlipayApsMerchantRegister.class)).orElseThrow(() -> new ServerErrorException("No AlipayAps registry found"));
AlipayPlusRegisterResult alipayPlusRegisterResult= alipayApsMerchantRegister.findMerchant(client);
AlipayPlusRegisterResult alipayPlusRegisterResult = alipayApsMerchantRegister.findMerchant(client);
return alipayPlusRegisterResult.getRawResponse();
}

@ -1,4 +1,4 @@
package au.com.royalpay.payment.manage.merchants.core.descriptor;
package au.com.royalpay.payment.manage.merchants.deacriptor;
import lombok.AllArgsConstructor;
import lombok.Data;
@ -11,7 +11,5 @@ import lombok.experimental.Accessors;
@Accessors(chain = true)
public class ApsConfigDescriptor {
private Boolean enableAlipayAps = false;
private Boolean alipayCnSwitch = false;
}

@ -1,8 +1,7 @@
package au.com.royalpay.payment.manage.merchants.entity;
import au.com.royalpay.payment.manage.merchants.core.descriptor.ApsConfigDescriptor;
import com.alibaba.fastjson.JSONObject;
import au.com.royalpay.payment.manage.merchants.deacriptor.ApsConfigDescriptor;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
@ -39,7 +38,6 @@ public class ApsConfigData implements Serializable {
.setClientId(clientId)
.setId(UUID.randomUUID().toString().replace("-", ""))
.setAlipayCnSwitch(apsConfigDescriptor.getAlipayCnSwitch())
.setEnableAlipayAps(apsConfigDescriptor.getEnableAlipayAps())
.setCreator(managerId)
.setCreateTime(new Date());
}

@ -1,7 +1,7 @@
package au.com.royalpay.payment.manage.merchants.web;
import au.com.royalpay.payment.manage.merchants.core.ApsConfigService;
import au.com.royalpay.payment.manage.merchants.core.descriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.deacriptor.ApsConfigDescriptor;
import au.com.royalpay.payment.manage.merchants.entity.ApsConfigData;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
import au.com.royalpay.payment.tools.CommonConsts;
@ -36,7 +36,7 @@ public class ApsConfigController {
* @param apsConfigDescriptor
* @return
*/
@ManagerMapping(value = "/{clientId}", method = RequestMethod.POST, role = { ManagerRole.ADMIN,ManagerRole.OPERATOR,ManagerRole.SITE_MANAGER })
@ManagerMapping(value = "/{clientId}", method = RequestMethod.POST, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.SITE_MANAGER})
public ApsConfigData saveApsConfigClientId(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, @PathVariable("clientId") String clientId, @RequestBody ApsConfigDescriptor apsConfigDescriptor) {
return apsConfigService.saveApsConfigClientId(manager.getString("managerId"), clientId, apsConfigDescriptor);
}
@ -48,8 +48,8 @@ public class ApsConfigController {
* @param apsConfig
* @return
*/
@ManagerMapping(value = "/{clientId}", method = RequestMethod.PUT, role = { ManagerRole.ADMIN,ManagerRole.OPERATOR,ManagerRole.SITE_MANAGER })
public ApsConfigData updateApsConfigClientId(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager,@PathVariable("clientId") String clientId, @RequestBody JSONObject apsConfig) {
return apsConfigService.updateApsConfigClientId(manager.getString("managerId"),clientId, apsConfig);
@ManagerMapping(value = "/{clientId}", method = RequestMethod.PUT, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.SITE_MANAGER})
public ApsConfigData updateApsConfigClientId(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, @PathVariable("clientId") String clientId, @RequestBody JSONObject apsConfig) {
return apsConfigService.updateApsConfigClientId(manager.getString("managerId"), clientId, apsConfig);
}
}

@ -57,6 +57,11 @@ public class OrgInfo {
private Double min_rpaypmt_dd_rate;
private String state;
private String senior_parent_org_id;
private Double interchange_fee_value;
private Double min_interchange_fee_value;
private Double service_fee_value;
private Double min_service_fee_value;
public JSONObject toJsonParam() {
@ -417,4 +422,31 @@ public class OrgInfo {
this.min_rpaypmt_overseas_card_rate = min_rpaypmt_overseas_card_rate;
}
public Double getInterchange_fee_value(){ return interchange_fee_value; }
public void setInterchange_fee_value(Double interchange_fee_value){ this.interchange_fee_value = interchange_fee_value; }
public Double getMin_interchange_fee_value() {
return min_interchange_fee_value;
}
public void setMin_interchange_fee_value(Double min_interchange_fee_value) {
this.min_interchange_fee_value = min_interchange_fee_value;
}
public Double getService_fee_value() {
return service_fee_value;
}
public void setService_fee_value(Double service_fee_value) {
this.service_fee_value = service_fee_value;
}
public Double getMin_service_fee_value() {
return min_service_fee_value;
}
public void setMin_service_fee_value(Double min_service_fee_value) {
this.min_service_fee_value = min_service_fee_value;
}
}

@ -121,6 +121,40 @@
</div>
</div>
<!-- APS start -->
<div class="form-group">
<label class="control-label col-sm-2">A+(APS)</label>
</div>
<div class="form-group" ng-class="{'has-error':org_form.wechat_rate_value.$invalid && org_form.wechat_rate_value.$dirty}">
<label class="control-label col-sm-3" for="wechat_rate_value_input">Interchange Fee *</label>
<div class="col-sm-7">
<input class="form-control form-control-float" type="number" ng-model="org.interchange_fee_value" id="interchange_fee_value_input" name="interchange_fee_value" max="100" min="0" readonly>
<span class="input-group-addon form-control-span">%</span>
</div>
</div>
<div class="form-group" ng-class="{'has-error':org_form.service_fee_value.$invalid && org_form.service_fee_value.$dirty}">
<label class="control-label col-sm-3" for="service_fee_value_input">Service Fee *</label>
<div class="col-sm-7">
<input class="form-control form-control-float" type="number" ng-model="org.service_fee_value" id="service_fee_value_input" name="service_fee_value" max="100" min="0" readonly>
<span class="input-group-addon form-control-span">%</span>
</div>
</div>
<div class="form-group" ng-class="{'has-error':org_form.min_interchange_fee_value.$invalid && org_form.min_interchange_fee_value.$dirty}">
<label class="control-label col-sm-3" for="min_interchange_fee_value_input">Min Interchange Fee</label>
<div class="col-sm-7">
<input class="form-control form-control-float" type="number" ng-model="org.min_interchange_fee_value" id="min_interchange_fee_value_input" name="min_interchange_fee_value" max="100" min="0" readonly>
<span class="input-group-addon form-control-span">%</span>
</div>
</div>
<div class="form-group" ng-class="{'has-error':org_form.min_service_fee_value.$invalid && org_form.min_service_fee_value.$dirty}">
<label class="control-label col-sm-3" for="min_service_fee_value_input">Min Service Fee</label>
<div class="col-sm-7">
<input class="form-control form-control-float" type="number" ng-model="org.min_service_fee_value" id="min_service_fee_value_input" name="min_service_fee_value" max="100" min="0" readonly>
<span class="input-group-addon form-control-span">%</span>
</div>
</div>
<!-- APS end-->
<div class="form-group" ng-class="{'has-error':org_form.bestpay_rate_value.$invalid && org_form.bestpay_rate_value.$dirty}">
<label class="control-label col-sm-2" for="bestpay_rate_value_input">Bestpay Rate *</label>
<div class="col-sm-8">

@ -8,7 +8,7 @@
<div class="col-sm-12">
<h3>Bank Account
<a class="small" role="button" ng-click="bankCtrl.edit=true"
ng-if="!bankCtrl.edit && (('11'|withRole)||((!partner.approve_result||partner.approve_result>4) && ('111'|withRole)))">
ng-if="!bankCtrl.edit && (('11'|withRole)||((!partner.approve_result||partner.approve_result>4) && ('111'|withRole)))">
<i class="fa fa-edit"></i>
</a>
</h3>
@ -17,16 +17,16 @@
<div class="form-group" ng-if="partner.surcharge_mode=='distributed'">
<label class="col-sm-4">手续费账户余额</label>
<div class="col-sm-6" style="font-size: 25px">
<p>{{surcharge.balance|currency:'AUD'}}<i class="fa fa-bars"
style="font-size: 15px;color: #3c8dbc;cursor: pointer;padding-left: 15px"
ng-click="surchargeAccountDetail()"></i></p>
<p>{{surcharge.balance | currency:'AUD'}}<i class="fa fa-bars"
style="font-size: 15px;color: #3c8dbc;cursor: pointer;padding-left: 15px"
ng-click="surchargeAccountDetail()"></i></p>
</div>
</div>
<div class="form-group" ng-if="partner.surcharge_mode=='distributed'">
<label class="col-sm-4">允许手续费账户欠款</label>
<div class="col-sm-6">
<input type="checkbox" ng-model="partner.allow_surcharge_credit" bs-switch
switch-change="allowSurchargeCredit(partner.allow_surcharge_credit)">
switch-change="allowSurchargeCredit(partner.allow_surcharge_credit)">
</div>
</div>
<div class="form-group">
@ -35,11 +35,11 @@
<p>
<span ng-if="partner.surcharge_mode=='balance'">balance
<i class="fa fa-sort" style="color: #3c8dbc;cursor: pointer"
ng-click="switchSurchargeMode()"></i>
ng-click="switchSurchargeMode()"></i>
</span>
<span ng-if="partner.surcharge_mode=='distributed'">distributed
<i class="fa fa-sort" style="color: #3c8dbc;cursor: pointer"
ng-click="switchSurchargeMode()"></i>
ng-click="switchSurchargeMode()"></i>
</span>
<p class="text-info">
<i class="fa fa-info"></i>启用到收支分离(distributed)模式,将使消费者支付手续费模式失效<br>
@ -52,41 +52,41 @@
<label class="col-sm-4">RoyalPay Pay GST</label>
<div class="col-sm-6">
<input type="checkbox" ng-model="partner.tax_in_surcharge" bs-switch
switch-change="taxInSurcharge(partner.tax_in_surcharge)">
switch-change="taxInSurcharge(partner.tax_in_surcharge)">
</div>
</div>
<div class="form-group" ng-if="('10'|withRole)">
<label class="col-sm-4">Merchant Pay GST &ensp;<small><em>(消费者承担手续费时生效)</em></small></label>
<div class="col-sm-6">
<input type="checkbox" ng-model="partner.customer_tax_free" bs-switch
switch-change="customerTaxFree(partner.customer_tax_free)">
switch-change="customerTaxFree(partner.customer_tax_free)">
</div>
</div>
<div class="form-group" ng-if="'modify_skip_clear'|withFunc">
<label class="col-sm-4">Skip Clearing</label>
<div class="col-sm-6">
<input type="checkbox" ng-model="partner.skip_clearing" bs-switch
switch-change="skipClearing(partner.skip_clearing)">
switch-change="skipClearing(partner.skip_clearing)">
</div>
</div>
<div class="form-group" ng-if="'modify_skip_clear'|withFunc">
<label class="col-sm-4">Pre Settle</label>
<div class="col-sm-6">
<input type="checkbox" ng-model="partner.enable_presettle" bs-switch
switch-change="switchPreSettle(partner.enable_presettle)">
switch-change="switchPreSettle(partner.enable_presettle)">
</div>
</div>
<div class="form-group" ng-if="'modify_min_settle'|withFunc">
<label class="col-sm-4" for="minSettleEdit">Min Settle</label>
<div class="col-sm-6">
<p ng-if="!bankCtrl.modify_min_settle" class="form-control-static">
<span ng-if="partner.min_settle">AU$</span>{{partner.min_settle||'Not Configure'}}
<span ng-if="partner.min_settle">AU$</span>{{partner.min_settle || 'Not Configure'}}
<a role="button" ng-click="bankCtrl.modify_min_settle=true"><i class="fa fa-edit"></i></a>
</p>
<div class="input-group" ng-if="bankCtrl.modify_min_settle">
<div class="input-group-addon">AU$</div>
<input class="form-control" ng-model="partner.min_settle" type="number" id="minSettleEdit"
min="0">
min="0">
<div class="input-group-btn">
<button class="btn btn-danger" ng-click="bankCtrl.modify_min_settle=false"><i
class="fa fa-close"></i>
@ -114,26 +114,26 @@
<label class="col-sm-4">Settle Hour</label>
<div class="col-sm-6">
<select ng-model="partner.settle_hour" class="form-control"
ng-options="hour.value as hour.label for hour in settleHours"
ng-change="settleHourConfig()"></select>
ng-options="hour.value as hour.label for hour in settleHours"
ng-change="settleHourConfig()"></select>
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="swiftcode_input">Swift Code</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.swift_code" id="swiftcode_input"
required ng-readonly="!bankCtrl.edit">
required ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="bsb_no_input">BSB No</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.bsb_no" id="bsb_no_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
<div class="col-sm-2" ng-if="bankCtrl.edit">
<a class="btn btn-success" role="button" ng-click="getBankInfo(bankaccount.bsb_no)"><i
@ -144,81 +144,81 @@
<label class="col-sm-4" for="bank_input">Bank</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.bank" id="bank_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="city_input">City</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.city" id="city_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="address_input">Address</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.address" id="address_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="system_input">System</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.system" id="system_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="postcode_input">Postcode</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.postcode" id="postcode_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="state_input">State</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.state" id="state_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="branch_input">Branch</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.branch" id="branch_input" required
ng-readonly="!bankCtrl.edit">
ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="account_no_input">Account No</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" ng-model="bankaccount.account_no" id="account_no_input"
required ng-readonly="!bankCtrl.edit">
required ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="form-group">
<label class="col-sm-4" for="account_name_input">Account Name</label>
<div class="col-sm-6">
<i class="fa fa-check-square-o check-i" aria-hidden="true"
ng-if="$root.complianceCheck.bankAccount"></i>
ng-if="$root.complianceCheck.bankAccount"></i>
<input class="form-control bank-input" maxlength="50" ng-model="bankaccount.account_name"
id="account_name_input" required ng-readonly="!bankCtrl.edit">
id="account_name_input" required ng-readonly="!bankCtrl.edit">
</div>
</div>
<div class="btn-group">
@ -237,9 +237,9 @@
<div class="panel panel-info">
<div class="panel-heading">
<h3>Rates <a class="text-success" role="button"
ng-if="partner.rate_editable && (('11'|withRole)||((!partner.approve_result||partner.approve_result>4) && ('111'|withRole)))"
ng-click="newRate()">
<i class="fa fa-plus"></i></a>
ng-if="partner.rate_editable && (('11'|withRole)||((!partner.approve_result||partner.approve_result>4) && ('111'|withRole)))"
ng-click="newRate()">
<i class="fa fa-plus"></i></a>
</h3>
</div>
<div class="panel-body">
@ -247,16 +247,16 @@
<div class="col-sm-12">
<ul class="nav nav-pills margin-bottom">
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='Wechat'}"><a role="button"
ng-click="bankCtrl.rate_name='Wechat'">Wechat</a>
ng-click="bankCtrl.rate_name='Wechat'">Wechat</a>
</li>
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='Alipay'}"><a role="button"
ng-click="bankCtrl.rate_name='Alipay'">Alipay(Retail)</a>
ng-click="bankCtrl.rate_name='Alipay'">Alipay(Retail)</a>
</li>
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='AlipayOnline'}"><a role="button"
ng-click="bankCtrl.rate_name='AlipayOnline'">Alipay(Online)</a>
ng-click="bankCtrl.rate_name='AlipayOnline'">Alipay(Online)</a>
</li>
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='AlipayAps'}"><a role="button"
ng-click="bankCtrl.rate_name='AlipayAps'">A+(APS)</a>
ng-click="bankCtrl.rate_name='AlipayAps'">A+(APS)</a>
</li>
<!-- <li role="presentation" ng-class="{active:bankCtrl.rate_name=='Bestpay'}"><a role="button"
ng-click="bankCtrl.rate_name='Bestpay'">Bestpay</a>
@ -266,22 +266,22 @@
</li>-->
<!--<li role="presentation" ng-class="{active:bankCtrl.rate_name=='hf'}"><a role="button" ng-click="bankCtrl.rate_name='hf'">HFpay</a></li>-->
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='Rpay'}"><a role="button"
ng-click="bankCtrl.rate_name='Rpay'">Rpay+</a>
ng-click="bankCtrl.rate_name='Rpay'">Rpay+</a>
</li>
<!--<li role="presentation" ng-class="{active:bankCtrl.rate_name=='Yeepay'}"><a role="button" ng-click="bankCtrl.rate_name='Yeepay'">Yeepay</a></li>-->
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='CB_BankPay'}"><a role="button"
ng-click="bankCtrl.rate_name='CB_BankPay'"
ng-if="sysconfig.active_channels.indexOf('CB_BankPay')!=-1">CB_BankPay</a>
ng-click="bankCtrl.rate_name='CB_BankPay'"
ng-if="sysconfig.active_channels.indexOf('CB_BankPay')!=-1">CB_BankPay</a>
</li>
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='rpaypmt_card'}"><a role="button"
ng-click="bankCtrl.rate_name='rpaypmt_card'">Card
Payment</a></li>
ng-click="bankCtrl.rate_name='rpaypmt_card'">Card
Payment</a></li>
<li role="presentation" ng-class="{active:bankCtrl.rate_name=='rpaypmt_dd'}"><a role="button"
ng-click="bankCtrl.rate_name='rpaypmt_dd'">Direct
Debit</a></li>
ng-click="bankCtrl.rate_name='rpaypmt_dd'">Direct
Debit</a></li>
<a id="addCardPaymentRate" class="btn btn-warning" style="float: right" type="button"
ng-click="newCardPaymentRates()"
ng-if="(partner.card_rate_editable && ('100'|withRole)) || ('11'|withRole)">
ng-click="newCardPaymentRates()"
ng-if="(bankCtrl.rate_name=='rpaypmt_card'||bankCtrl.rate_name=='rpaypmt_dd') && ((partner.card_rate_editable && ('100'|withRole)) || ('11'|withRole))">
Add Card Payment Rates
</a>
<a id="addAlipayApsRate" class="btn btn-info" style="float: right;margin-right: 10px" type="button"
@ -293,23 +293,23 @@
<div class="table-responsive">
<table class="table table-bordered">
<thead ng-if="bankCtrl.rate_name != 'AlipayAps'">
<tr>
<th>Rate Name</th>
<th ng-if="bankCtrl.rate_name!='rpaypmt_card'">Rate Value</th>
<th ng-if="bankCtrl.rate_name=='rpaypmt_card'">Domestic Rate Value</th>
<th ng-if="bankCtrl.rate_name=='rpaypmt_card'">International Rate Value</th>
<th>Transaction Fee</th>
<th>Active Time</th>
<th>Expire Time</th>
<th
<tr>
<th>Rate Name</th>
<th ng-if="bankCtrl.rate_name!='rpaypmt_card'">Rate Value</th>
<th ng-if="bankCtrl.rate_name=='rpaypmt_card'">Domestic Rate Value</th>
<th ng-if="bankCtrl.rate_name=='rpaypmt_card'">International Rate Value</th>
<th>Transaction Fee</th>
<th>Active Time</th>
<th>Expire Time</th>
<th
ng-if="bankCtrl.rate_name=='Wechat' || bankCtrl.rate_name=='rpaypmt_card' ||bankCtrl.rate_name=='rpaypmt_dd'">
Clean Days
</th>
<th>Update Time</th>
<th>Operator</th>
<th>Remark</th>
<th style="text-align: center">Operation</th>
</tr>
Clean Days
</th>
<th>Update Time</th>
<th>Operator</th>
<th>Remark</th>
<th style="text-align: center">Operation</th>
</tr>
</thead>
<thead ng-if="bankCtrl.rate_name == 'AlipayAps'">
<tr>
@ -325,36 +325,36 @@
</tr>
</thead>
<tbody>
<tr ng-repeat="rate in rates|filter:{rate_name:bankCtrl.rate_name}:true"
ng-class="{'text-bold':rate.current,'success':rate.active}">
<td ng-bind="rate.rate_name"></td>
<td ng-if="bankCtrl.rate_name!='rpaypmt_card'" ng-bind="rate.rate_value + ' %'"></td>
<td ng-if="bankCtrl.rate_name=='rpaypmt_card'" ng-bind="rate.rate_value + ' %'"></td>
<td ng-if="bankCtrl.rate_name=='rpaypmt_card'"
ng-bind="rate.ext_rates.overseas_rate_value.rate + ' %/T+'+rate.ext_rates.overseas_rate_value.clean_days">
</td>
<td ng-if="bankCtrl.rate_name !='AlipayAps'" ng-bind="'$ '+rate.transaction_fee"></td>
<td ng-if="bankCtrl.rate_name =='AlipayAps'" ng-bind="rate.transaction_fee + ' %'"></td>
<td ng-bind="rate.active_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.expiry_time|date:'yyyy-MM-dd'"></td>
<td
<tr ng-repeat="rate in rates|filter:{rate_name:bankCtrl.rate_name}:true"
ng-class="{'text-bold':rate.current,'success':rate.active}">
<td ng-bind="rate.rate_name"></td>
<td ng-if="bankCtrl.rate_name!='rpaypmt_card'" ng-bind="rate.rate_value + ' %'"></td>
<td ng-if="bankCtrl.rate_name=='rpaypmt_card'" ng-bind="rate.rate_value + ' %'"></td>
<td ng-if="bankCtrl.rate_name=='rpaypmt_card'"
ng-bind="rate.ext_rates.overseas_rate_value.rate + ' %/T+'+rate.ext_rates.overseas_rate_value.clean_days">
</td>
<td ng-if="bankCtrl.rate_name !='AlipayAps'" ng-bind="'$ '+rate.transaction_fee"></td>
<td ng-if="bankCtrl.rate_name =='AlipayAps'" ng-bind="rate.transaction_fee + ' %'"></td>
<td ng-bind="rate.active_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.expiry_time|date:'yyyy-MM-dd'"></td>
<td
ng-if="rate.rate_name=='Wechat' || bankCtrl.rate_name=='rpaypmt_card' ||bankCtrl.rate_name=='rpaypmt_dd'">
T+{{rate.clean_days}}
</td>
<td ng-bind="rate.update_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.operator_name||'系统生成'"></td>
<td ng-bind="rate.remark|limitTo:20" title="{{rate.remark}}"></td>
<td style="text-align: center">
<a role="button" ng-click="editRate(rate)" style="padding-right: 10px;"
ng-if="'011'|withRole"><i class="fa fa-edit"></i></a>
<span ng-if="(bankCtrl.rate_name=='rpaypmt_card' ||bankCtrl.rate_name=='rpaypmt_dd')
T+{{rate.clean_days}}
</td>
<td ng-bind="rate.update_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.operator_name||'系统生成'"></td>
<td ng-bind="rate.remark|limitTo:20" title="{{rate.remark}}"></td>
<td style="text-align: center">
<a role="button" ng-click="editRate(rate)" style="padding-right: 10px;"
ng-if="'011'|withRole"><i class="fa fa-edit"></i></a>
<span ng-if="(bankCtrl.rate_name=='rpaypmt_card' ||bankCtrl.rate_name=='rpaypmt_dd')
&& partner.upay_approve_result">
<span style="color: orange">(Promotional Offer)</span>
<a class="fa fa-cloud-download" target="_blank"
ng-href="/sys/partners/{{partner.client_moniker}}/export/aggregate/card_promotion_agree_pdf?rateid={{rate.client_rate_id}}"></a>
ng-href="/sys/partners/{{partner.client_moniker}}/export/aggregate/card_promotion_agree_pdf?rateid={{rate.client_rate_id}}"></a>
</span>
</td>
</tr>
</td>
</tr>
</tbody>
</table>
</div>
@ -364,58 +364,59 @@
<div class="row" ng-if="false">
<div class="col-sm-12">
<h4>AlipayPlus Rates <a class="text-success" role="button"
ng-if="partner.rate_editable && (('11'|withRole)||((!partner.approve_result||partner.approve_result>4||(partner.approve_result==4&&partner.open_status==3)) && ('111'|withRole)))"
ng-click="newAlipayPlusRate()">
<i class="fa fa-plus"></i></a>
ng-if="partner.rate_editable && (('11'|withRole)||((!partner.approve_result||partner.approve_result>4||(partner.approve_result==4&&partner.open_status==3)) && ('111'|withRole)))"
ng-click="newAlipayPlusRate()">
<i class="fa fa-plus"></i></a>
</h4>
<ul class="nav nav-pills margin-bottom">
<li role="presentation" ng-class="{active:isAlipayCN}"><a role="button"
ng-click="changeAlipayPlusRateState(true)"
ng-if="sysconfig.active_channels.indexOf('AlipayPlus')!=-1">AlipayCN</a>
ng-click="changeAlipayPlusRateState(true)"
ng-if="sysconfig.active_channels.indexOf('AlipayPlus')!=-1">AlipayCN</a>
</li>
<li role="presentation" ng-class="{active:!isAlipayCN}"><a role="button"
ng-click="changeAlipayPlusRateState(false)">Other Wallets</a>
ng-click="changeAlipayPlusRateState(false)">Other
Wallets</a>
</li>
</ul>
<div class="table-responsive">
<table class="table table-bordered">
<thead>
<tr>
<th>Rate Name</th>
<th>Rate Value</th>
<th>Transaction Fee</th>
<th>Active Time</th>
<th>Expire Time</th>
<th>Clean Days</th>
<th>Update Time</th>
<th>Operator</th>
<th>Remark</th>
<th style="text-align: center">Operation</th>
</tr>
<tr>
<th>Rate Name</th>
<th>Rate Value</th>
<th>Transaction Fee</th>
<th>Active Time</th>
<th>Expire Time</th>
<th>Clean Days</th>
<th>Update Time</th>
<th>Operator</th>
<th>Remark</th>
<th style="text-align: center">Operation</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="rate in rates|filter:isAlipayPlus"
ng-class="{'text-bold':rate.current,'success':rate.active}">
<td ng-bind="rate.rate_name"></td>
<td ng-bind="rate.rate_value + ' %'"></td>
<td ng-bind="'$ '+rate.transaction_fee"></td>
<td ng-bind="rate.active_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.expiry_time|date:'yyyy-MM-dd'"></td>
<td>T+{{rate.clean_days}}</td>
<td ng-bind="rate.update_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.operator_name||'系统生成'"></td>
<td ng-bind="rate.remark|limitTo:20" title="{{rate.remark}}"></td>
<td style="text-align: center">
<a role="button" ng-click="editRate(rate)" style="padding-right: 10px;"
ng-if="'011'|withRole"><i class="fa fa-edit"></i></a>
<span ng-if="(bankCtrl.rate_name=='rpaypmt_card' ||bankCtrl.rate_name=='rpaypmt_dd')
<tr ng-repeat="rate in rates|filter:isAlipayPlus"
ng-class="{'text-bold':rate.current,'success':rate.active}">
<td ng-bind="rate.rate_name"></td>
<td ng-bind="rate.rate_value + ' %'"></td>
<td ng-bind="'$ '+rate.transaction_fee"></td>
<td ng-bind="rate.active_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.expiry_time|date:'yyyy-MM-dd'"></td>
<td>T+{{rate.clean_days}}</td>
<td ng-bind="rate.update_time|date:'yyyy-MM-dd'"></td>
<td ng-bind="rate.operator_name||'系统生成'"></td>
<td ng-bind="rate.remark|limitTo:20" title="{{rate.remark}}"></td>
<td style="text-align: center">
<a role="button" ng-click="editRate(rate)" style="padding-right: 10px;"
ng-if="'011'|withRole"><i class="fa fa-edit"></i></a>
<span ng-if="(bankCtrl.rate_name=='rpaypmt_card' ||bankCtrl.rate_name=='rpaypmt_dd')
&& partner.upay_approve_result">
<span style="color: orange">(Promotional Offer)</span>
<a class="fa fa-cloud-download" target="_blank"
ng-href="/sys/partners/{{partner.client_moniker}}/export/aggregate/card_promotion_agree_pdf?rateid={{rate.client_rate_id}}"></a>
ng-href="/sys/partners/{{partner.client_moniker}}/export/aggregate/card_promotion_agree_pdf?rateid={{rate.client_rate_id}}"></a>
</span>
</td>
</tr>
</td>
</tr>
</tbody>
</table>
</div>

Loading…
Cancel
Save