From 8c32b331adc38f255772a732f3b86c0d856aa864 Mon Sep 17 00:00:00 2001 From: luoyang Date: Thu, 25 Jul 2019 16:16:57 +0800 Subject: [PATCH] =?UTF-8?q?add=20alipay=20online=20=E5=85=A8=E9=87=8F?= =?UTF-8?q?=E5=A4=87=E4=BB=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 2 +- .../manage/dev/core/impl/AliforexcelServiceImpl.java | 10 +++++++++- .../payment/manage/mappers/system/ClientMapper.java | 3 +++ .../payment/manage/mappers/system/ClientMapper.xml | 3 +++ 4 files changed, 16 insertions(+), 2 deletions(-) diff --git a/pom.xml b/pom.xml index 55932b945..5f190c5ca 100644 --- a/pom.xml +++ b/pom.xml @@ -10,7 +10,7 @@ 4.0.0 manage - 1.0.26 + 1.0.27 UTF-8 diff --git a/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/AliforexcelServiceImpl.java b/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/AliforexcelServiceImpl.java index 46a94aec3..9e8a5a143 100644 --- a/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/AliforexcelServiceImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/AliforexcelServiceImpl.java @@ -21,6 +21,8 @@ import org.apache.poi.ss.usermodel.Cell; import org.apache.poi.ss.usermodel.Row; import org.apache.poi.ss.usermodel.Sheet; import org.dom4j.Element; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; import org.springframework.stereotype.Service; import javax.annotation.Resource; @@ -44,6 +46,8 @@ public class AliforexcelServiceImpl implements AliforexcelService { private AlipayClient alipayClient; @Resource private OrderMapper orderMapper; + private Logger logger = LoggerFactory.getLogger(getClass()); + @Override public JSONObject listClients(HttpServletResponse httpResponse,JSONObject manager, AliExcel query) { @@ -105,7 +109,7 @@ public class AliforexcelServiceImpl implements AliforexcelService { List registerSuccessMerchant = new ArrayList<>(); List registerFailMerchant = new ArrayList<>(); List lessInfoMerchant = new ArrayList<>(); - List useAlipayOnlineMerchant = transactionMapper.useAlipayOnlineClients(); + List useAlipayOnlineMerchant = clientMapper.listUseAlipayMerchant(); for (int clientId : useAlipayOnlineMerchant) { JSONObject client = clientMapper.findClient(clientId); if (client == null) { @@ -113,6 +117,9 @@ public class AliforexcelServiceImpl implements AliforexcelService { } try { needRegisterMerchant.add(client.getString("client_moniker")); + if (StringUtils.isBlank(client.getString("company_website"))) { + client.put("company_website", client.getString("ali_sub_merchant_id")+".royalpay.com.au"); + } checkPartnerInfo(client,"online"); } catch (InvalidParameterException e) { JSONObject exception = new JSONObject(); @@ -145,6 +152,7 @@ public class AliforexcelServiceImpl implements AliforexcelService { result.put("success_register_merchant", registerSuccessMerchant); result.put("fail_register_merchant", registerFailMerchant); result.put("less_info_merchant", lessInfoMerchant); + logger.info("-------AlipayOnline Gms end----fail_register_merchant"+registerFailMerchant.toString()); return result; } diff --git a/src/main/java/au/com/royalpay/payment/manage/mappers/system/ClientMapper.java b/src/main/java/au/com/royalpay/payment/manage/mappers/system/ClientMapper.java index a142120c2..062933a06 100644 --- a/src/main/java/au/com/royalpay/payment/manage/mappers/system/ClientMapper.java +++ b/src/main/java/au/com/royalpay/payment/manage/mappers/system/ClientMapper.java @@ -136,4 +136,7 @@ public interface ClientMapper { int getPartnercode(@Param("codes") String codes); JSONObject findCountByBd(@Param("bd_group") String bd_group, @Param("today") Date today, @Param("yesterday") Date yesterday, @Param("month") Date month); + + List listUseAlipayMerchant(); + } diff --git a/src/main/resources/au/com/royalpay/payment/manage/mappers/system/ClientMapper.xml b/src/main/resources/au/com/royalpay/payment/manage/mappers/system/ClientMapper.xml index 663dfd9f2..e38fbae78 100644 --- a/src/main/resources/au/com/royalpay/payment/manage/mappers/system/ClientMapper.xml +++ b/src/main/resources/au/com/royalpay/payment/manage/mappers/system/ClientMapper.xml @@ -735,6 +735,9 @@ WHERE address= #{address} GROUP BY address + +