diff --git a/src/main/java/au/com/royalpay/payment/manage/appclient/web/RetailAppController.java b/src/main/java/au/com/royalpay/payment/manage/appclient/web/RetailAppController.java index e3806f093..bc6589931 100644 --- a/src/main/java/au/com/royalpay/payment/manage/appclient/web/RetailAppController.java +++ b/src/main/java/au/com/royalpay/payment/manage/appclient/web/RetailAppController.java @@ -345,6 +345,6 @@ public class RetailAppController { @RequestMapping(value = "/file/agree/confirm", method = RequestMethod.POST) public void confirmSourceAgreeFile(@ModelAttribute(CommonConsts.RETAIL_DEVICE) JSONObject device) { - clientContractService.confirmSourceAgreement(device.getIntValue("client_id"),device.getString("account_id")); + clientContractService.confirmSourceAgreement(device.getIntValue("client_id"),device.getString("account_id"),"App"); } } diff --git a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java index 105b0aa42..0f929319f 100644 --- a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java +++ b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java @@ -20,7 +20,6 @@ import au.com.royalpay.payment.tools.env.SysConfigManager; import au.com.royalpay.payment.tools.http.HttpUtils; import au.com.royalpay.payment.tools.merchants.beans.QRCodeConfig; import au.com.royalpay.payment.tools.permission.enums.ManagerRole; -import au.com.royalpay.payment.tools.permission.enums.PartnerRole; import com.alibaba.fastjson.JSONObject; @@ -532,6 +531,6 @@ public class PartnerManageController { @PartnerMapping(value = "/agree/confirm", method = RequestMethod.POST) public void confirmSourceAgreeFile(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject account) { - clientContractService.confirmSourceAgreement(account.getIntValue("client_id"),account.getString("account_id")); + clientContractService.confirmSourceAgreement(account.getIntValue("client_id"),account.getString("account_id"),"PC"); } } diff --git a/src/main/java/au/com/royalpay/payment/manage/system/core/ClientContractService.java b/src/main/java/au/com/royalpay/payment/manage/system/core/ClientContractService.java index 83989dd62..9f57b23ea 100644 --- a/src/main/java/au/com/royalpay/payment/manage/system/core/ClientContractService.java +++ b/src/main/java/au/com/royalpay/payment/manage/system/core/ClientContractService.java @@ -6,7 +6,7 @@ public interface ClientContractService { JSONObject getOrGenerateSourceAgreement(int client_id,String channel); - void confirmSourceAgreement(int client_id,String account_id); + void confirmSourceAgreement(int client_id,String account_id,String channel); JSONObject getSourceAgreement(int client_id); diff --git a/src/main/java/au/com/royalpay/payment/manage/system/core/impl/ClientContractServiceImpl.java b/src/main/java/au/com/royalpay/payment/manage/system/core/impl/ClientContractServiceImpl.java index 400f5d8c1..df8c4a87b 100644 --- a/src/main/java/au/com/royalpay/payment/manage/system/core/impl/ClientContractServiceImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/system/core/impl/ClientContractServiceImpl.java @@ -87,7 +87,7 @@ public class ClientContractServiceImpl implements ClientContractService { @Override @Transactional - public void confirmSourceAgreement(int client_id,String account_id) { + public void confirmSourceAgreement(int client_id,String account_id,String channel) { JSONObject client = clientManager.getClientInfo(client_id); if (client == null) { throw new NotFoundException("merchant not found"); @@ -106,6 +106,7 @@ public class ClientContractServiceImpl implements ClientContractService { contract.put("has_sign", 1); contract.put("sign_account_id",account_id); + contract.put("sign_channel",channel); contract.put("signatory",account.getString("display_name")); clientsContractMapper.update(contract); Date now = new Date();