|
|
@ -26,6 +26,7 @@ import au.com.royalpay.payment.manage.device.core.DeviceManager;
|
|
|
|
import au.com.royalpay.payment.manage.management.sysconfig.core.impls.PermissionPartnerManagerImpl;
|
|
|
|
import au.com.royalpay.payment.manage.management.sysconfig.core.impls.PermissionPartnerManagerImpl;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.financial.FinancialBDConfigMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.financial.FinancialBDConfigMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.log.*;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.log.*;
|
|
|
|
|
|
|
|
import au.com.royalpay.payment.manage.mappers.payment.CommonSubMerchantIdMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.payment.TransactionMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.payment.TransactionMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.redpack.ActClientInvitationCodeMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.redpack.ActClientInvitationCodeMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.risk.RiskAttentionMerchantsMapper;
|
|
|
|
import au.com.royalpay.payment.manage.mappers.risk.RiskAttentionMerchantsMapper;
|
|
|
@ -277,6 +278,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
@Resource
|
|
|
|
@Resource
|
|
|
|
private MerchantSignInfoMapper merchantSignInfoMapper;
|
|
|
|
private MerchantSignInfoMapper merchantSignInfoMapper;
|
|
|
|
@Resource
|
|
|
|
@Resource
|
|
|
|
|
|
|
|
private CommonSubMerchantIdMapper commonSubMerchantIdMapper;
|
|
|
|
|
|
|
|
@Resource
|
|
|
|
private Locker locker;
|
|
|
|
private Locker locker;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -372,12 +375,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!StringUtils.equalsIgnoreCase(clientMoniker, PlatformEnvironment.getEnv().getTestMoniker())) {
|
|
|
|
if (!StringUtils.equalsIgnoreCase(clientMoniker, PlatformEnvironment.getEnv().getTestMoniker())) {
|
|
|
|
String subMerchantId = client.getString("sub_merchant_id");
|
|
|
|
String subMerchantId = client.getString("sub_merchant_id");
|
|
|
|
String tempSubMerchantIds = sysConfigManager.getSysConfig().getString("temp_sub_mch_id");
|
|
|
|
if (subMerchantId != null) {
|
|
|
|
String tempSubMchSource = sysConfigManager.getSysConfig().getString("temp_sub_mch_id_source");
|
|
|
|
client.put("temp_sub_merchant", checkSubMerchantIdInCommonPool(subMerchantId));
|
|
|
|
tempSubMchSource = tempSubMchSource == null ? "" : tempSubMchSource;
|
|
|
|
|
|
|
|
if (subMerchantId != null && tempSubMerchantIds != null && tempSubMerchantIds.contains(subMerchantId)
|
|
|
|
|
|
|
|
&& !tempSubMchSource.contains(client.getString("client_moniker"))) {
|
|
|
|
|
|
|
|
client.put("temp_sub_merchant", true);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (client.getIntValue("approve_result") == 1
|
|
|
|
if (client.getIntValue("approve_result") == 1
|
|
|
@ -526,9 +525,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
int authDays = PlatformEnvironment.getEnv().authDays();// 快速自助开通申请有效期
|
|
|
|
int authDays = PlatformEnvironment.getEnv().authDays();// 快速自助开通申请有效期
|
|
|
|
for (JSONObject partner : partners) {
|
|
|
|
for (JSONObject partner : partners) {
|
|
|
|
String subMerchantId = partner.getString("sub_merchant_id");
|
|
|
|
String subMerchantId = partner.getString("sub_merchant_id");
|
|
|
|
if (subMerchantId != null && tempSubMchId != null && tempSubMchId.contains(subMerchantId)
|
|
|
|
if (subMerchantId != null ) {
|
|
|
|
&& !tempSubMchSource.contains(partner.getString("client_moniker"))) {
|
|
|
|
partner.put("temp_sub_merchant", checkSubMerchantIdInCommonPool(subMerchantId));
|
|
|
|
partner.put("temp_sub_merchant", true);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (partner.getIntValue("approve_result") == 2) {
|
|
|
|
if (partner.getIntValue("approve_result") == 2) {
|
|
|
|
partner.put("expiry_time", DateUtils.addDays(partner.getDate("approve_time"), authDays));
|
|
|
|
partner.put("expiry_time", DateUtils.addDays(partner.getDate("approve_time"), authDays));
|
|
|
@ -4911,6 +4909,12 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Cacheable("common_sub_mch_id:")
|
|
|
|
|
|
|
|
public boolean checkSubMerchantIdInCommonPool(String subMerchantId) {
|
|
|
|
|
|
|
|
JSONObject json = commonSubMerchantIdMapper.find(subMerchantId);
|
|
|
|
|
|
|
|
return json != null;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
@Override
|
|
|
|
public JSONObject comListPartnerSelection(JSONObject manager, PartnerQuery query) {
|
|
|
|
public JSONObject comListPartnerSelection(JSONObject manager, PartnerQuery query) {
|
|
|
|
JSONObject params = query.toJsonParam();
|
|
|
|
JSONObject params = query.toJsonParam();
|
|
|
@ -4926,9 +4930,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
|
|
|
|
int authDays = PlatformEnvironment.getEnv().authDays();// 快速自助开通申请有效期
|
|
|
|
int authDays = PlatformEnvironment.getEnv().authDays();// 快速自助开通申请有效期
|
|
|
|
for (JSONObject partner : partners) {
|
|
|
|
for (JSONObject partner : partners) {
|
|
|
|
String subMerchantId = partner.getString("sub_merchant_id");
|
|
|
|
String subMerchantId = partner.getString("sub_merchant_id");
|
|
|
|
if (subMerchantId != null && tempSubMchId != null && tempSubMchId.contains(subMerchantId)
|
|
|
|
if (subMerchantId != null) {
|
|
|
|
&& !tempSubMchSource.contains(partner.getString("client_moniker"))) {
|
|
|
|
partner.put("temp_sub_merchant", checkSubMerchantIdInCommonPool(subMerchantId));
|
|
|
|
partner.put("temp_sub_merchant", true);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (partner.getIntValue("approve_result") == 2) {
|
|
|
|
if (partner.getIntValue("approve_result") == 2) {
|
|
|
|
partner.put("expiry_time", DateUtils.addDays(partner.getDate("approve_time"), authDays));
|
|
|
|
partner.put("expiry_time", DateUtils.addDays(partner.getDate("approve_time"), authDays));
|
|
|
|