|
|
|
@ -1216,9 +1216,6 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
|
int clientId = client.getIntValue("client_id");
|
|
|
|
|
isRiskyMerchant(client, clientBankAccountMapper.clientBankAccounts(clientId).get(0));
|
|
|
|
|
|
|
|
|
|
if (client.getString("sub_merchant_id") == null || client.getString("sub_merchant_id").equals("")) {
|
|
|
|
|
throw new BadRequestException("该商户未设置微信 Sub Merchant ID!");
|
|
|
|
|
}
|
|
|
|
|
JSONObject cardFlowInfo = clientCardFlowMapper.findClient(clientId);
|
|
|
|
|
client.putAll(clientConfigService.find(client.getIntValue("client_id")));
|
|
|
|
|
Integer open_status_to = cardFlowInfo != null? cardFlowInfo.getIntValue("open_status") : null;
|
|
|
|
@ -1229,20 +1226,13 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
|
if (pass == 1) {
|
|
|
|
|
createKycAuthStatus(manager, client);
|
|
|
|
|
clientModifySupport.processClientConfigModify(new SwitchPermissionModify(manager, clientMoniker, "skip_clearing", false));
|
|
|
|
|
if (client.getIntValue("source") == 4 || client.getIntValue("source") == 5) {
|
|
|
|
|
List<JSONObject> accounts = clientAccountMapper.listAdminAccounts(client.getIntValue("client_id"));
|
|
|
|
|
JSONObject account = accounts.get(0);
|
|
|
|
|
//TODO 发送卡支付开通邮件 1.判断商户是否已开通跨境支付,若没有开通,init账号
|
|
|
|
|
// sendInitEmail(client, account.getString("username"), "*****");
|
|
|
|
|
saveClientAuditProcess(client.getIntValue("client_id"), open_status_to, 5, "合规通过", manager,2);
|
|
|
|
|
|
|
|
|
|
clientModifySupport.processClientConfigModify(new SwitchPermissionModify(manager, clientMoniker, "skip_clearing", false));
|
|
|
|
|
// gatewayMerchantApply.notifyOrgMerchantStatus(client);
|
|
|
|
|
List<JSONObject> accounts = clientAccountMapper.listAdminAccounts(clientId);
|
|
|
|
|
if (accounts != null && accounts.size() > 0) {
|
|
|
|
|
sendInitEmail(client, accounts.get(0).getString("username"), "*******");
|
|
|
|
|
}else {
|
|
|
|
|
//TODO 发送卡支付开通邮件 1.判断商户是否已开通跨境支付,若没有开通,init账号
|
|
|
|
|
// initAdminUserAndSendEmail(manager, clientMoniker, client);
|
|
|
|
|
saveClientAuditProcess(client.getIntValue("client_id"), open_status_to, 5, "合规通过", manager,2);
|
|
|
|
|
initAdminUserAndSendEmail(manager, clientMoniker, client);
|
|
|
|
|
}
|
|
|
|
|
saveClientAuditProcess(client.getIntValue("client_id"), open_status_to, 5, "合规通过", manager,2);
|
|
|
|
|
}
|
|
|
|
|
clientInfoCacheSupport.clearClientCache(client.getIntValue("client_id"));
|
|
|
|
|
}
|
|
|
|
@ -1296,9 +1286,6 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void initAdminUserAndSendEmail(JSONObject manager, String clientMoniker, JSONObject client) {
|
|
|
|
|
if (StringUtils.isEmpty(client.getString("sub_merchant_id"))) {
|
|
|
|
|
throw new BadRequestException("Sub Merchant ID Can't be null ");
|
|
|
|
|
}
|
|
|
|
|
String username = clientMoniker;
|
|
|
|
|
boolean duplicated = true;
|
|
|
|
|
String pwd = RandomStringUtils.random(8, true, true);
|
|
|
|
|