Merge branch 'develop'

# Conflicts:
#	pom.xml
master
taylor.dang 5 years ago
commit 9a332a3da0

Binary file not shown.

@ -5,12 +5,12 @@
<parent>
<groupId>au.com.royalpay.payment</groupId>
<artifactId>payment-parent</artifactId>
<version>1.0.4</version>
<version>1.0.6</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>manage</artifactId>
<version>1.0.33</version>
<version>1.0.34</version>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

@ -24,6 +24,9 @@ public interface ClientApplyMapper {
@AutoSql(type = SqlType.SELECT)
JSONObject findClientApplicationById(@Param("client_apply_id") String client_apply_id);
@AutoSql(type = SqlType.SELECT)
JSONObject findClientApplicationByClientMoniker(@Param("client_moniker") String client_moniker);
PageList<JSONObject> listPartnerApplications(JSONObject params, PageBounds pageBounds);
@AutoSql(type = SqlType.COUNT)

@ -218,8 +218,36 @@ public class ClientApplyImpl implements ClientApply, ApplicationEventPublisherAw
partner.put("bd_user", manager.getString("manager_id"));
partner.put("bd_user_name", manager.getString("display_name"));
if (clientMapper.findClientByMoniker(info.getClientMoniker()) != null) {
throw new BadRequestException("error.partner.valid.dumplicate_client_moniker");
JSONObject client;
if ((client = clientMapper.findClientByMoniker(info.getClientMoniker())) != null) {
if( manager.getString("manager_id").equals(client.getString("creator")) )
{
if(clientApplyMapper.findClientApplicationByClientMoniker(info.getClientMoniker()) != null)
{
throw new BadRequestException("无效,已关联商户");
}
JSONObject client_bd = new JSONObject();
client_bd.put("client_id", partner.getIntValue("client_id"));
client_bd.put("bd_id", manager.getString("manager_id"));
client_bd.put("bd_name", manager.getString("display_name"));
client_bd.put("create_time", new Date());
client_bd.put("create_id", manager.getString("manager_id"));
client_bd.put("start_date", new Date());
client_bd.put("proportion", 1);
clientBDMapper.saveBD(client_bd);
apply.put("client_apply_id", client_apply_id);
apply.put("client_id", partner.getIntValue("client_id"));
apply.put("client_moniker", info.getClientMoniker());
apply.put("apply_approve_result", 2);
apply.put("apply_approve_time", new Date());
clientApplyMapper.updatePartnerApplication(apply);
return partner;
}
throw new BadRequestException("您只能关联自己创建的商户");
//throw new BadRequestException("error.partner.valid.dumplicate_client_moniker");
}
partner.put("source", 2);//自主申请
partner.put("country", "AUS");//自主申请

@ -88,7 +88,7 @@ app.mail.appid=1
app.mail.host=https://mailsupport.royalpay.com.au
mail.send.credentialCode=Fd1aRfdjc9
spring.thymeleaf.mode=LEGACYHTML5
spring.thymeleaf.mode=HTML
app.mpsupport.host=https://mp.royalpay.com.au
app.foreign-currency=AUD

Loading…
Cancel
Save