From 396011a458ae8a8f69c599c748198ad5fbd251c4 Mon Sep 17 00:00:00 2001 From: hurui <177768073@qq.com> Date: Tue, 6 Jun 2023 17:34:14 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/cweb/controller/BsMerController.java | 1 + .../com/hfkj/channel/saas/SaasMerService.java | 2 +- .../main/java/com/hfkj/dao/BsMerMapper.java | 81 ++++++++++--------- .../java/com/hfkj/dao/BsMerSqlProvider.java | 14 ++++ .../src/main/java/com/hfkj/entity/BsMer.java | 16 ++++ .../java/com/hfkj/entity/BsMerExample.java | 70 ++++++++++++++++ 6 files changed, 145 insertions(+), 39 deletions(-) diff --git a/cweb/src/main/java/com/cweb/controller/BsMerController.java b/cweb/src/main/java/com/cweb/controller/BsMerController.java index ba2f48b..a19c23a 100644 --- a/cweb/src/main/java/com/cweb/controller/BsMerController.java +++ b/cweb/src/main/java/com/cweb/controller/BsMerController.java @@ -176,6 +176,7 @@ public class BsMerController { } if (mer.getId() == null + || StringUtils.isBlank(mer.getOrgNo()) || mer.getMerType() == null || StringUtils.isBlank(mer.getMerName()) || StringUtils.isBlank(mer.getMerAbbreviate()) diff --git a/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java b/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java index f3ffafe..79d2696 100644 --- a/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java +++ b/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java @@ -97,7 +97,7 @@ public class SaasMerService { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到经营范围"); } Map body = new HashMap<>(); - body.put("userNo", SaasConfig.userNo); + body.put("userNo",basisModel.getOrgNo()); body.put("email", basisModel.getRegEmail()); body.put("busiCode", "WECHAT_PAY"); body.put("merRegName", basisModel.getMerName()); diff --git a/service/src/main/java/com/hfkj/dao/BsMerMapper.java b/service/src/main/java/com/hfkj/dao/BsMerMapper.java index ceff1a3..8dd043a 100644 --- a/service/src/main/java/com/hfkj/dao/BsMerMapper.java +++ b/service/src/main/java/com/hfkj/dao/BsMerMapper.java @@ -39,42 +39,44 @@ public interface BsMerMapper extends BsMerMapperExt { int deleteByPrimaryKey(Long id); @Insert({ - "insert into bs_mer (company_id, company_name, ", - "agent_id, agent_name, ", - "salesman_id, salesman_name, ", - "reg_phone, reg_name, ", - "reg_email, mer_type, ", - "mer_no, mer_name, ", - "mer_abbreviate, mer_mcc_code, ", - "mer_mcc_name, blis_url, ", - "blis_name, blis_no, ", - "blis_reg_address, blis_period_type, ", - "blis_period_start, blis_period_end, ", - "lar_name, lar_id_card, ", - "lar_id_card_portrait_img, lar_id_card_national_emblem_img, ", - "lar_id_card_address, lar_id_card_period_type, ", - "lar_id_card_period_start, lar_id_card_period_end, ", - "complete_status, mer_status, ", - "create_time, update_time, ", - "ext_1, ext_2, ext_3)", - "values (#{companyId,jdbcType=BIGINT}, #{companyName,jdbcType=VARCHAR}, ", - "#{agentId,jdbcType=BIGINT}, #{agentName,jdbcType=VARCHAR}, ", - "#{salesmanId,jdbcType=BIGINT}, #{salesmanName,jdbcType=VARCHAR}, ", - "#{regPhone,jdbcType=VARCHAR}, #{regName,jdbcType=VARCHAR}, ", - "#{regEmail,jdbcType=VARCHAR}, #{merType,jdbcType=INTEGER}, ", - "#{merNo,jdbcType=VARCHAR}, #{merName,jdbcType=VARCHAR}, ", - "#{merAbbreviate,jdbcType=VARCHAR}, #{merMccCode,jdbcType=VARCHAR}, ", - "#{merMccName,jdbcType=VARCHAR}, #{blisUrl,jdbcType=VARCHAR}, ", - "#{blisName,jdbcType=VARCHAR}, #{blisNo,jdbcType=VARCHAR}, ", - "#{blisRegAddress,jdbcType=VARCHAR}, #{blisPeriodType,jdbcType=INTEGER}, ", - "#{blisPeriodStart,jdbcType=VARCHAR}, #{blisPeriodEnd,jdbcType=VARCHAR}, ", - "#{larName,jdbcType=VARCHAR}, #{larIdCard,jdbcType=VARCHAR}, ", - "#{larIdCardPortraitImg,jdbcType=VARCHAR}, #{larIdCardNationalEmblemImg,jdbcType=VARCHAR}, ", - "#{larIdCardAddress,jdbcType=VARCHAR}, #{larIdCardPeriodType,jdbcType=INTEGER}, ", - "#{larIdCardPeriodStart,jdbcType=VARCHAR}, #{larIdCardPeriodEnd,jdbcType=VARCHAR}, ", - "#{completeStatus,jdbcType=INTEGER}, #{merStatus,jdbcType=INTEGER}, ", - "#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, ", - "#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" + "insert into bs_mer (org_no, company_id, ", + "company_name, agent_id, ", + "agent_name, salesman_id, ", + "salesman_name, reg_phone, ", + "reg_name, reg_email, ", + "mer_type, mer_no, ", + "mer_name, mer_abbreviate, ", + "mer_mcc_code, mer_mcc_name, ", + "blis_url, blis_name, ", + "blis_no, blis_reg_address, ", + "blis_period_type, blis_period_start, ", + "blis_period_end, lar_name, ", + "lar_id_card, lar_id_card_portrait_img, ", + "lar_id_card_national_emblem_img, lar_id_card_address, ", + "lar_id_card_period_type, lar_id_card_period_start, ", + "lar_id_card_period_end, complete_status, ", + "mer_status, create_time, ", + "update_time, ext_1, ", + "ext_2, ext_3)", + "values (#{orgNo,jdbcType=VARCHAR}, #{companyId,jdbcType=BIGINT}, ", + "#{companyName,jdbcType=VARCHAR}, #{agentId,jdbcType=BIGINT}, ", + "#{agentName,jdbcType=VARCHAR}, #{salesmanId,jdbcType=BIGINT}, ", + "#{salesmanName,jdbcType=VARCHAR}, #{regPhone,jdbcType=VARCHAR}, ", + "#{regName,jdbcType=VARCHAR}, #{regEmail,jdbcType=VARCHAR}, ", + "#{merType,jdbcType=INTEGER}, #{merNo,jdbcType=VARCHAR}, ", + "#{merName,jdbcType=VARCHAR}, #{merAbbreviate,jdbcType=VARCHAR}, ", + "#{merMccCode,jdbcType=VARCHAR}, #{merMccName,jdbcType=VARCHAR}, ", + "#{blisUrl,jdbcType=VARCHAR}, #{blisName,jdbcType=VARCHAR}, ", + "#{blisNo,jdbcType=VARCHAR}, #{blisRegAddress,jdbcType=VARCHAR}, ", + "#{blisPeriodType,jdbcType=INTEGER}, #{blisPeriodStart,jdbcType=VARCHAR}, ", + "#{blisPeriodEnd,jdbcType=VARCHAR}, #{larName,jdbcType=VARCHAR}, ", + "#{larIdCard,jdbcType=VARCHAR}, #{larIdCardPortraitImg,jdbcType=VARCHAR}, ", + "#{larIdCardNationalEmblemImg,jdbcType=VARCHAR}, #{larIdCardAddress,jdbcType=VARCHAR}, ", + "#{larIdCardPeriodType,jdbcType=INTEGER}, #{larIdCardPeriodStart,jdbcType=VARCHAR}, ", + "#{larIdCardPeriodEnd,jdbcType=VARCHAR}, #{completeStatus,jdbcType=INTEGER}, ", + "#{merStatus,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, ", + "#{updateTime,jdbcType=TIMESTAMP}, #{ext1,jdbcType=VARCHAR}, ", + "#{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" }) @Options(useGeneratedKeys=true,keyProperty="id") int insert(BsMer record); @@ -86,6 +88,7 @@ public interface BsMerMapper extends BsMerMapperExt { @SelectProvider(type=BsMerSqlProvider.class, method="selectByExample") @Results({ @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="org_no", property="orgNo", jdbcType=JdbcType.VARCHAR), @Result(column="company_id", property="companyId", jdbcType=JdbcType.BIGINT), @Result(column="company_name", property="companyName", jdbcType=JdbcType.VARCHAR), @Result(column="agent_id", property="agentId", jdbcType=JdbcType.BIGINT), @@ -128,7 +131,7 @@ public interface BsMerMapper extends BsMerMapperExt { @Select({ "select", - "id, company_id, company_name, agent_id, agent_name, salesman_id, salesman_name, ", + "id, org_no, company_id, company_name, agent_id, agent_name, salesman_id, salesman_name, ", "reg_phone, reg_name, reg_email, mer_type, mer_no, mer_name, mer_abbreviate, ", "mer_mcc_code, mer_mcc_name, blis_url, blis_name, blis_no, blis_reg_address, ", "blis_period_type, blis_period_start, blis_period_end, lar_name, lar_id_card, ", @@ -140,6 +143,7 @@ public interface BsMerMapper extends BsMerMapperExt { }) @Results({ @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="org_no", property="orgNo", jdbcType=JdbcType.VARCHAR), @Result(column="company_id", property="companyId", jdbcType=JdbcType.BIGINT), @Result(column="company_name", property="companyName", jdbcType=JdbcType.VARCHAR), @Result(column="agent_id", property="agentId", jdbcType=JdbcType.BIGINT), @@ -191,7 +195,8 @@ public interface BsMerMapper extends BsMerMapperExt { @Update({ "update bs_mer", - "set company_id = #{companyId,jdbcType=BIGINT},", + "set org_no = #{orgNo,jdbcType=VARCHAR},", + "company_id = #{companyId,jdbcType=BIGINT},", "company_name = #{companyName,jdbcType=VARCHAR},", "agent_id = #{agentId,jdbcType=BIGINT},", "agent_name = #{agentName,jdbcType=VARCHAR},", diff --git a/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java b/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java index b82e91b..a32ee5c 100644 --- a/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java +++ b/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java @@ -28,6 +28,10 @@ public class BsMerSqlProvider { SQL sql = new SQL(); sql.INSERT_INTO("bs_mer"); + if (record.getOrgNo() != null) { + sql.VALUES("org_no", "#{orgNo,jdbcType=VARCHAR}"); + } + if (record.getCompanyId() != null) { sql.VALUES("company_id", "#{companyId,jdbcType=BIGINT}"); } @@ -186,6 +190,7 @@ public class BsMerSqlProvider { } else { sql.SELECT("id"); } + sql.SELECT("org_no"); sql.SELECT("company_id"); sql.SELECT("company_name"); sql.SELECT("agent_id"); @@ -244,6 +249,10 @@ public class BsMerSqlProvider { sql.SET("id = #{record.id,jdbcType=BIGINT}"); } + if (record.getOrgNo() != null) { + sql.SET("org_no = #{record.orgNo,jdbcType=VARCHAR}"); + } + if (record.getCompanyId() != null) { sql.SET("company_id = #{record.companyId,jdbcType=BIGINT}"); } @@ -401,6 +410,7 @@ public class BsMerSqlProvider { sql.UPDATE("bs_mer"); sql.SET("id = #{record.id,jdbcType=BIGINT}"); + sql.SET("org_no = #{record.orgNo,jdbcType=VARCHAR}"); sql.SET("company_id = #{record.companyId,jdbcType=BIGINT}"); sql.SET("company_name = #{record.companyName,jdbcType=VARCHAR}"); sql.SET("agent_id = #{record.agentId,jdbcType=BIGINT}"); @@ -448,6 +458,10 @@ public class BsMerSqlProvider { SQL sql = new SQL(); sql.UPDATE("bs_mer"); + if (record.getOrgNo() != null) { + sql.SET("org_no = #{orgNo,jdbcType=VARCHAR}"); + } + if (record.getCompanyId() != null) { sql.SET("company_id = #{companyId,jdbcType=BIGINT}"); } diff --git a/service/src/main/java/com/hfkj/entity/BsMer.java b/service/src/main/java/com/hfkj/entity/BsMer.java index 3f65c97..d7ed83f 100644 --- a/service/src/main/java/com/hfkj/entity/BsMer.java +++ b/service/src/main/java/com/hfkj/entity/BsMer.java @@ -18,6 +18,11 @@ public class BsMer implements Serializable { */ private Long id; + /** + * 机构编号 + */ + private String orgNo; + /** * 公司id */ @@ -204,6 +209,14 @@ public class BsMer implements Serializable { this.id = id; } + public String getOrgNo() { + return orgNo; + } + + public void setOrgNo(String orgNo) { + this.orgNo = orgNo; + } + public Long getCompanyId() { return companyId; } @@ -513,6 +526,7 @@ public class BsMer implements Serializable { } BsMer other = (BsMer) that; return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) + && (this.getOrgNo() == null ? other.getOrgNo() == null : this.getOrgNo().equals(other.getOrgNo())) && (this.getCompanyId() == null ? other.getCompanyId() == null : this.getCompanyId().equals(other.getCompanyId())) && (this.getCompanyName() == null ? other.getCompanyName() == null : this.getCompanyName().equals(other.getCompanyName())) && (this.getAgentId() == null ? other.getAgentId() == null : this.getAgentId().equals(other.getAgentId())) @@ -557,6 +571,7 @@ public class BsMer implements Serializable { final int prime = 31; int result = 1; result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); + result = prime * result + ((getOrgNo() == null) ? 0 : getOrgNo().hashCode()); result = prime * result + ((getCompanyId() == null) ? 0 : getCompanyId().hashCode()); result = prime * result + ((getCompanyName() == null) ? 0 : getCompanyName().hashCode()); result = prime * result + ((getAgentId() == null) ? 0 : getAgentId().hashCode()); @@ -604,6 +619,7 @@ public class BsMer implements Serializable { sb.append(" ["); sb.append("Hash = ").append(hashCode()); sb.append(", id=").append(id); + sb.append(", orgNo=").append(orgNo); sb.append(", companyId=").append(companyId); sb.append(", companyName=").append(companyName); sb.append(", agentId=").append(agentId); diff --git a/service/src/main/java/com/hfkj/entity/BsMerExample.java b/service/src/main/java/com/hfkj/entity/BsMerExample.java index b4498a9..ca00d91 100644 --- a/service/src/main/java/com/hfkj/entity/BsMerExample.java +++ b/service/src/main/java/com/hfkj/entity/BsMerExample.java @@ -185,6 +185,76 @@ public class BsMerExample { return (Criteria) this; } + public Criteria andOrgNoIsNull() { + addCriterion("org_no is null"); + return (Criteria) this; + } + + public Criteria andOrgNoIsNotNull() { + addCriterion("org_no is not null"); + return (Criteria) this; + } + + public Criteria andOrgNoEqualTo(String value) { + addCriterion("org_no =", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoNotEqualTo(String value) { + addCriterion("org_no <>", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoGreaterThan(String value) { + addCriterion("org_no >", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoGreaterThanOrEqualTo(String value) { + addCriterion("org_no >=", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoLessThan(String value) { + addCriterion("org_no <", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoLessThanOrEqualTo(String value) { + addCriterion("org_no <=", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoLike(String value) { + addCriterion("org_no like", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoNotLike(String value) { + addCriterion("org_no not like", value, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoIn(List values) { + addCriterion("org_no in", values, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoNotIn(List values) { + addCriterion("org_no not in", values, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoBetween(String value1, String value2) { + addCriterion("org_no between", value1, value2, "orgNo"); + return (Criteria) this; + } + + public Criteria andOrgNoNotBetween(String value1, String value2) { + addCriterion("org_no not between", value1, value2, "orgNo"); + return (Criteria) this; + } + public Criteria andCompanyIdIsNull() { addCriterion("company_id is null"); return (Criteria) this; From c7b6a2eebd8672dc7804adfd32d173e2df95a463 Mon Sep 17 00:00:00 2001 From: hurui <177768073@qq.com> Date: Tue, 6 Jun 2023 18:21:45 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/cweb/controller/BsMerController.java | 2 + .../main/java/com/hfkj/dao/BsMerMapper.java | 83 ++++++++++--------- .../java/com/hfkj/dao/BsMerSqlProvider.java | 14 ++++ .../src/main/java/com/hfkj/entity/BsMer.java | 16 ++++ .../java/com/hfkj/entity/BsMerExample.java | 70 ++++++++++++++++ 5 files changed, 145 insertions(+), 40 deletions(-) diff --git a/cweb/src/main/java/com/cweb/controller/BsMerController.java b/cweb/src/main/java/com/cweb/controller/BsMerController.java index a19c23a..ba5dadc 100644 --- a/cweb/src/main/java/com/cweb/controller/BsMerController.java +++ b/cweb/src/main/java/com/cweb/controller/BsMerController.java @@ -263,6 +263,8 @@ public class BsMerController { mer.getMerRegion().setAreaCode(MapUtils.getObject(regionMap, "street").getRegionId()); mer.getMerRegion().setAreaName(MapUtils.getObject(regionMap, "street").getRegionName()); + bsMer.setOrgNo(mer.getOrgNo()); + bsMer.setOrgName(commonService.getDictionaryCodeName("ORG_NO", mer.getOrgNo())); bsMer.setMerType(mer.getMerType()); bsMer.setMerName(mer.getMerName()); bsMer.setMerAbbreviate(mer.getMerAbbreviate()); diff --git a/service/src/main/java/com/hfkj/dao/BsMerMapper.java b/service/src/main/java/com/hfkj/dao/BsMerMapper.java index 8dd043a..9ffd4aa 100644 --- a/service/src/main/java/com/hfkj/dao/BsMerMapper.java +++ b/service/src/main/java/com/hfkj/dao/BsMerMapper.java @@ -39,44 +39,44 @@ public interface BsMerMapper extends BsMerMapperExt { int deleteByPrimaryKey(Long id); @Insert({ - "insert into bs_mer (org_no, company_id, ", - "company_name, agent_id, ", - "agent_name, salesman_id, ", - "salesman_name, reg_phone, ", - "reg_name, reg_email, ", - "mer_type, mer_no, ", - "mer_name, mer_abbreviate, ", - "mer_mcc_code, mer_mcc_name, ", - "blis_url, blis_name, ", - "blis_no, blis_reg_address, ", - "blis_period_type, blis_period_start, ", - "blis_period_end, lar_name, ", - "lar_id_card, lar_id_card_portrait_img, ", - "lar_id_card_national_emblem_img, lar_id_card_address, ", - "lar_id_card_period_type, lar_id_card_period_start, ", - "lar_id_card_period_end, complete_status, ", - "mer_status, create_time, ", - "update_time, ext_1, ", - "ext_2, ext_3)", - "values (#{orgNo,jdbcType=VARCHAR}, #{companyId,jdbcType=BIGINT}, ", - "#{companyName,jdbcType=VARCHAR}, #{agentId,jdbcType=BIGINT}, ", - "#{agentName,jdbcType=VARCHAR}, #{salesmanId,jdbcType=BIGINT}, ", - "#{salesmanName,jdbcType=VARCHAR}, #{regPhone,jdbcType=VARCHAR}, ", - "#{regName,jdbcType=VARCHAR}, #{regEmail,jdbcType=VARCHAR}, ", - "#{merType,jdbcType=INTEGER}, #{merNo,jdbcType=VARCHAR}, ", - "#{merName,jdbcType=VARCHAR}, #{merAbbreviate,jdbcType=VARCHAR}, ", - "#{merMccCode,jdbcType=VARCHAR}, #{merMccName,jdbcType=VARCHAR}, ", - "#{blisUrl,jdbcType=VARCHAR}, #{blisName,jdbcType=VARCHAR}, ", - "#{blisNo,jdbcType=VARCHAR}, #{blisRegAddress,jdbcType=VARCHAR}, ", - "#{blisPeriodType,jdbcType=INTEGER}, #{blisPeriodStart,jdbcType=VARCHAR}, ", - "#{blisPeriodEnd,jdbcType=VARCHAR}, #{larName,jdbcType=VARCHAR}, ", - "#{larIdCard,jdbcType=VARCHAR}, #{larIdCardPortraitImg,jdbcType=VARCHAR}, ", - "#{larIdCardNationalEmblemImg,jdbcType=VARCHAR}, #{larIdCardAddress,jdbcType=VARCHAR}, ", - "#{larIdCardPeriodType,jdbcType=INTEGER}, #{larIdCardPeriodStart,jdbcType=VARCHAR}, ", - "#{larIdCardPeriodEnd,jdbcType=VARCHAR}, #{completeStatus,jdbcType=INTEGER}, ", - "#{merStatus,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, ", - "#{updateTime,jdbcType=TIMESTAMP}, #{ext1,jdbcType=VARCHAR}, ", - "#{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" + "insert into bs_mer (org_no, org_name, ", + "company_id, company_name, ", + "agent_id, agent_name, ", + "salesman_id, salesman_name, ", + "reg_phone, reg_name, ", + "reg_email, mer_type, ", + "mer_no, mer_name, ", + "mer_abbreviate, mer_mcc_code, ", + "mer_mcc_name, blis_url, ", + "blis_name, blis_no, ", + "blis_reg_address, blis_period_type, ", + "blis_period_start, blis_period_end, ", + "lar_name, lar_id_card, ", + "lar_id_card_portrait_img, lar_id_card_national_emblem_img, ", + "lar_id_card_address, lar_id_card_period_type, ", + "lar_id_card_period_start, lar_id_card_period_end, ", + "complete_status, mer_status, ", + "create_time, update_time, ", + "ext_1, ext_2, ext_3)", + "values (#{orgNo,jdbcType=VARCHAR}, #{orgName,jdbcType=VARCHAR}, ", + "#{companyId,jdbcType=BIGINT}, #{companyName,jdbcType=VARCHAR}, ", + "#{agentId,jdbcType=BIGINT}, #{agentName,jdbcType=VARCHAR}, ", + "#{salesmanId,jdbcType=BIGINT}, #{salesmanName,jdbcType=VARCHAR}, ", + "#{regPhone,jdbcType=VARCHAR}, #{regName,jdbcType=VARCHAR}, ", + "#{regEmail,jdbcType=VARCHAR}, #{merType,jdbcType=INTEGER}, ", + "#{merNo,jdbcType=VARCHAR}, #{merName,jdbcType=VARCHAR}, ", + "#{merAbbreviate,jdbcType=VARCHAR}, #{merMccCode,jdbcType=VARCHAR}, ", + "#{merMccName,jdbcType=VARCHAR}, #{blisUrl,jdbcType=VARCHAR}, ", + "#{blisName,jdbcType=VARCHAR}, #{blisNo,jdbcType=VARCHAR}, ", + "#{blisRegAddress,jdbcType=VARCHAR}, #{blisPeriodType,jdbcType=INTEGER}, ", + "#{blisPeriodStart,jdbcType=VARCHAR}, #{blisPeriodEnd,jdbcType=VARCHAR}, ", + "#{larName,jdbcType=VARCHAR}, #{larIdCard,jdbcType=VARCHAR}, ", + "#{larIdCardPortraitImg,jdbcType=VARCHAR}, #{larIdCardNationalEmblemImg,jdbcType=VARCHAR}, ", + "#{larIdCardAddress,jdbcType=VARCHAR}, #{larIdCardPeriodType,jdbcType=INTEGER}, ", + "#{larIdCardPeriodStart,jdbcType=VARCHAR}, #{larIdCardPeriodEnd,jdbcType=VARCHAR}, ", + "#{completeStatus,jdbcType=INTEGER}, #{merStatus,jdbcType=INTEGER}, ", + "#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, ", + "#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" }) @Options(useGeneratedKeys=true,keyProperty="id") int insert(BsMer record); @@ -89,6 +89,7 @@ public interface BsMerMapper extends BsMerMapperExt { @Results({ @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), @Result(column="org_no", property="orgNo", jdbcType=JdbcType.VARCHAR), + @Result(column="org_name", property="orgName", jdbcType=JdbcType.VARCHAR), @Result(column="company_id", property="companyId", jdbcType=JdbcType.BIGINT), @Result(column="company_name", property="companyName", jdbcType=JdbcType.VARCHAR), @Result(column="agent_id", property="agentId", jdbcType=JdbcType.BIGINT), @@ -131,8 +132,8 @@ public interface BsMerMapper extends BsMerMapperExt { @Select({ "select", - "id, org_no, company_id, company_name, agent_id, agent_name, salesman_id, salesman_name, ", - "reg_phone, reg_name, reg_email, mer_type, mer_no, mer_name, mer_abbreviate, ", + "id, org_no, org_name, company_id, company_name, agent_id, agent_name, salesman_id, ", + "salesman_name, reg_phone, reg_name, reg_email, mer_type, mer_no, mer_name, mer_abbreviate, ", "mer_mcc_code, mer_mcc_name, blis_url, blis_name, blis_no, blis_reg_address, ", "blis_period_type, blis_period_start, blis_period_end, lar_name, lar_id_card, ", "lar_id_card_portrait_img, lar_id_card_national_emblem_img, lar_id_card_address, ", @@ -144,6 +145,7 @@ public interface BsMerMapper extends BsMerMapperExt { @Results({ @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), @Result(column="org_no", property="orgNo", jdbcType=JdbcType.VARCHAR), + @Result(column="org_name", property="orgName", jdbcType=JdbcType.VARCHAR), @Result(column="company_id", property="companyId", jdbcType=JdbcType.BIGINT), @Result(column="company_name", property="companyName", jdbcType=JdbcType.VARCHAR), @Result(column="agent_id", property="agentId", jdbcType=JdbcType.BIGINT), @@ -196,6 +198,7 @@ public interface BsMerMapper extends BsMerMapperExt { @Update({ "update bs_mer", "set org_no = #{orgNo,jdbcType=VARCHAR},", + "org_name = #{orgName,jdbcType=VARCHAR},", "company_id = #{companyId,jdbcType=BIGINT},", "company_name = #{companyName,jdbcType=VARCHAR},", "agent_id = #{agentId,jdbcType=BIGINT},", diff --git a/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java b/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java index a32ee5c..038b251 100644 --- a/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java +++ b/service/src/main/java/com/hfkj/dao/BsMerSqlProvider.java @@ -32,6 +32,10 @@ public class BsMerSqlProvider { sql.VALUES("org_no", "#{orgNo,jdbcType=VARCHAR}"); } + if (record.getOrgName() != null) { + sql.VALUES("org_name", "#{orgName,jdbcType=VARCHAR}"); + } + if (record.getCompanyId() != null) { sql.VALUES("company_id", "#{companyId,jdbcType=BIGINT}"); } @@ -191,6 +195,7 @@ public class BsMerSqlProvider { sql.SELECT("id"); } sql.SELECT("org_no"); + sql.SELECT("org_name"); sql.SELECT("company_id"); sql.SELECT("company_name"); sql.SELECT("agent_id"); @@ -253,6 +258,10 @@ public class BsMerSqlProvider { sql.SET("org_no = #{record.orgNo,jdbcType=VARCHAR}"); } + if (record.getOrgName() != null) { + sql.SET("org_name = #{record.orgName,jdbcType=VARCHAR}"); + } + if (record.getCompanyId() != null) { sql.SET("company_id = #{record.companyId,jdbcType=BIGINT}"); } @@ -411,6 +420,7 @@ public class BsMerSqlProvider { sql.SET("id = #{record.id,jdbcType=BIGINT}"); sql.SET("org_no = #{record.orgNo,jdbcType=VARCHAR}"); + sql.SET("org_name = #{record.orgName,jdbcType=VARCHAR}"); sql.SET("company_id = #{record.companyId,jdbcType=BIGINT}"); sql.SET("company_name = #{record.companyName,jdbcType=VARCHAR}"); sql.SET("agent_id = #{record.agentId,jdbcType=BIGINT}"); @@ -462,6 +472,10 @@ public class BsMerSqlProvider { sql.SET("org_no = #{orgNo,jdbcType=VARCHAR}"); } + if (record.getOrgName() != null) { + sql.SET("org_name = #{orgName,jdbcType=VARCHAR}"); + } + if (record.getCompanyId() != null) { sql.SET("company_id = #{companyId,jdbcType=BIGINT}"); } diff --git a/service/src/main/java/com/hfkj/entity/BsMer.java b/service/src/main/java/com/hfkj/entity/BsMer.java index d7ed83f..866a407 100644 --- a/service/src/main/java/com/hfkj/entity/BsMer.java +++ b/service/src/main/java/com/hfkj/entity/BsMer.java @@ -23,6 +23,11 @@ public class BsMer implements Serializable { */ private String orgNo; + /** + * 机构名称 + */ + private String orgName; + /** * 公司id */ @@ -217,6 +222,14 @@ public class BsMer implements Serializable { this.orgNo = orgNo; } + public String getOrgName() { + return orgName; + } + + public void setOrgName(String orgName) { + this.orgName = orgName; + } + public Long getCompanyId() { return companyId; } @@ -527,6 +540,7 @@ public class BsMer implements Serializable { BsMer other = (BsMer) that; return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) && (this.getOrgNo() == null ? other.getOrgNo() == null : this.getOrgNo().equals(other.getOrgNo())) + && (this.getOrgName() == null ? other.getOrgName() == null : this.getOrgName().equals(other.getOrgName())) && (this.getCompanyId() == null ? other.getCompanyId() == null : this.getCompanyId().equals(other.getCompanyId())) && (this.getCompanyName() == null ? other.getCompanyName() == null : this.getCompanyName().equals(other.getCompanyName())) && (this.getAgentId() == null ? other.getAgentId() == null : this.getAgentId().equals(other.getAgentId())) @@ -572,6 +586,7 @@ public class BsMer implements Serializable { int result = 1; result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); result = prime * result + ((getOrgNo() == null) ? 0 : getOrgNo().hashCode()); + result = prime * result + ((getOrgName() == null) ? 0 : getOrgName().hashCode()); result = prime * result + ((getCompanyId() == null) ? 0 : getCompanyId().hashCode()); result = prime * result + ((getCompanyName() == null) ? 0 : getCompanyName().hashCode()); result = prime * result + ((getAgentId() == null) ? 0 : getAgentId().hashCode()); @@ -620,6 +635,7 @@ public class BsMer implements Serializable { sb.append("Hash = ").append(hashCode()); sb.append(", id=").append(id); sb.append(", orgNo=").append(orgNo); + sb.append(", orgName=").append(orgName); sb.append(", companyId=").append(companyId); sb.append(", companyName=").append(companyName); sb.append(", agentId=").append(agentId); diff --git a/service/src/main/java/com/hfkj/entity/BsMerExample.java b/service/src/main/java/com/hfkj/entity/BsMerExample.java index ca00d91..a8d4e6d 100644 --- a/service/src/main/java/com/hfkj/entity/BsMerExample.java +++ b/service/src/main/java/com/hfkj/entity/BsMerExample.java @@ -255,6 +255,76 @@ public class BsMerExample { return (Criteria) this; } + public Criteria andOrgNameIsNull() { + addCriterion("org_name is null"); + return (Criteria) this; + } + + public Criteria andOrgNameIsNotNull() { + addCriterion("org_name is not null"); + return (Criteria) this; + } + + public Criteria andOrgNameEqualTo(String value) { + addCriterion("org_name =", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameNotEqualTo(String value) { + addCriterion("org_name <>", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameGreaterThan(String value) { + addCriterion("org_name >", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameGreaterThanOrEqualTo(String value) { + addCriterion("org_name >=", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameLessThan(String value) { + addCriterion("org_name <", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameLessThanOrEqualTo(String value) { + addCriterion("org_name <=", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameLike(String value) { + addCriterion("org_name like", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameNotLike(String value) { + addCriterion("org_name not like", value, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameIn(List values) { + addCriterion("org_name in", values, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameNotIn(List values) { + addCriterion("org_name not in", values, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameBetween(String value1, String value2) { + addCriterion("org_name between", value1, value2, "orgName"); + return (Criteria) this; + } + + public Criteria andOrgNameNotBetween(String value1, String value2) { + addCriterion("org_name not between", value1, value2, "orgName"); + return (Criteria) this; + } + public Criteria andCompanyIdIsNull() { addCriterion("company_id is null"); return (Criteria) this; From 16d0a88fabbd1f747cc977293d0ae4d32aeced65 Mon Sep 17 00:00:00 2001 From: hurui <177768073@qq.com> Date: Wed, 7 Jun 2023 09:52:47 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../channel/lakala/LaKaLaLedgerService.java | 58 +++++++++++++------ .../lakala/LaKaLaTradeSeparateService.java | 7 ++- .../hfkj/service/BsMerPlatformNoService.java | 2 + .../impl/BsMerPlatformNoServiceImpl.java | 11 ++++ 4 files changed, 57 insertions(+), 21 deletions(-) diff --git a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaLedgerService.java b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaLedgerService.java index 32fc48a..1238883 100644 --- a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaLedgerService.java +++ b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaLedgerService.java @@ -44,6 +44,8 @@ public class LaKaLaLedgerService { private BsMerService merService; @Resource private BsMerAttachService merAttachService; + @Resource + private BsMerPlatformNoService merPlatformNoService; /** * 商户分账业务开通申请 @@ -57,8 +59,8 @@ public class LaKaLaLedgerService { throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); } // 商户 - MerBasisModel merDetail = merService.getMerDetail(merLedger.getMerId()); - if (merDetail == null) { + BsMer mer = merService.getMer(merLedger.getMerId()); + if (mer == null) { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); } @@ -71,9 +73,9 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", orderNo); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", mer.getOrgNo()); map.put("merCupNo", merLedger.getCupNo()); - map.put("contactMobile", merDetail.getRegPhone()); + map.put("contactMobile", mer.getRegPhone()); map.put("splitLowestRatio", merLedger.getSplitLowestRatio()); map.put("splitEntrustFileName", merLedger.getSplitEntrustFileName()); // 转换成bas64 @@ -118,11 +120,10 @@ public class LaKaLaLedgerService { throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); } // 商户 - MerBasisModel merDetail = merService.getMerDetail(merLedger.getMerId()); - if (merDetail == null) { + BsMer mer = merService.getMer(merLedger.getMerId()); + if (mer == null) { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); } - Map commonParam = new HashMap<>(); commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); commonParam.put("version", "1.0.0"); @@ -132,10 +133,10 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", orderNo); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", mer.getOrgNo()); map.put("receiverNo", merLedger.getReceiverNo()); map.put("merCupNo", merLedger.getCupNo()); - map.put("contactMobile", merDetail.getRegPhone()); + map.put("contactMobile", mer.getRegPhone()); map.put("splitLowestRatio", merLedger.getSplitLowestRatio()); map.put("splitEntrustFileName", merLedger.getSplitEntrustFileName()); // 转换成bas64 @@ -183,8 +184,8 @@ public class LaKaLaLedgerService { throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); } // 商户 - MerBasisModel merDetail = merService.getMerDetail(merLedger.getId()); - if (merDetail == null) { + BsMer mer = merService.getMer(merLedger.getId()); + if (mer == null) { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); } @@ -197,9 +198,9 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", orderNo); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", mer.getOrgNo()); map.put("merCupNo", merLedger.getCupNo()); - map.put("contactMobile", merDetail.getRegPhone()); + map.put("contactMobile", mer.getRegPhone()); map.put("splitLowestRatio", merLedger.getSplitLowestRatio()); map.put("splitEntrustFileName", merLedger.getSplitEntrustFileName()); // map.put("splitEntrustFilePath", saasCommon.fileUpload(new File(CommonSysConst.getSysConfig().getFile_url() +"/"+ merLedger.getSplitEntrustFilePath()), "SPLIT_ENTRUST_FILE", "0").getString("url")); @@ -244,6 +245,15 @@ public class LaKaLaLedgerService { * @return */ public JSONObject queryLedgerMer(String merCupNo) { + BsMerPlatformNo merPlatform = merPlatformNoService.getPlatformNoByCupNo(merCupNo); + if (merPlatform == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未知的商户号"); + } + // 商户 + BsMer mer = merService.getMer(merPlatform.getMerId()); + if (mer == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); + } Map commonParam = new HashMap<>(); commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); commonParam.put("version", "1.0.0"); @@ -253,7 +263,7 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", orderNo); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", mer.getOrgNo()); map.put("merCupNo", merCupNo); commonParam.put("reqData", map); @@ -290,7 +300,7 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", System.currentTimeMillis()+""); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", merDetail.getOrgNo()); map.put("receiverName", merDetail.getMerName()); map.put("contactMobile", merDetail.getRegPhone()); map.put("acctTypeCode", merDetail.getMerSettleAcct().getSettleType().equals(MerSettleType.status1.getNumber())?57:58);// 57:对公 58:对私 @@ -355,7 +365,7 @@ public class LaKaLaLedgerService { } /** - * 创建分账接收方 + * 修改分账接收方 */ public void updateLedgerReceiver(Long merId) { // 商户 @@ -371,7 +381,7 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", System.currentTimeMillis()+""); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", merDetail.getOrgNo()); map.put("receiverNo", "1"); map.put("receiverName", merDetail.getMerName()); map.put("contactMobile", merDetail.getRegPhone()); @@ -432,6 +442,11 @@ public class LaKaLaLedgerService { if (merLedgerReceiver == null) { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到分账关系"); } + // 商户 + BsMer mer = merService.getMer(merLedgerReceiver.getMerId()); + if (mer == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); + } Map commonParam = new HashMap<>(); commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); commonParam.put("version", "1.0.0"); @@ -440,7 +455,7 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", System.currentTimeMillis()+""); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", mer.getOrgNo()); map.put("merCupNo", merLedgerReceiver.getCupNo()); map.put("receiverNo", merLedgerReceiver.getReceiverNo()); @@ -488,6 +503,11 @@ public class LaKaLaLedgerService { if (merLedgerReceiver == null) { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到分账关系"); } + // 商户 + BsMer mer = merService.getMer(merLedgerReceiver.getMerId()); + if (mer == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); + } Map commonParam = new HashMap<>(); commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); commonParam.put("version", "1.0.0"); @@ -496,7 +516,7 @@ public class LaKaLaLedgerService { Map map = new HashMap<>(); map.put("version", "1.0"); map.put("orderNo", System.currentTimeMillis()+""); - map.put("orgCode", CommonSysConst.getSysConfig().getLkl_org_code()); + map.put("orgCode", mer.getOrgNo()); map.put("merCupNo", merLedgerReceiver.getCupNo()); map.put("receiverNo", merLedgerReceiver.getReceiverNo()); String base64ImgUrl = ImageUtils.getBase64ByImgUrl(CommonSysConst.getSysConfig().getObs_url() + merLedgerReceiver.getRelieveEntrustFilePath()); diff --git a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeSeparateService.java b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeSeparateService.java index 7cf0c99..3460df5 100644 --- a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeSeparateService.java +++ b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeSeparateService.java @@ -34,6 +34,8 @@ public class LaKaLaTradeSeparateService { private BsTradeOrderProfitSharingService tradeOrderProfitSharingService; @Resource private BsTradeOrderProfitSharingReceiverService tradeOrderProfitSharingReceiverService; + @Resource + private BsMerService merService; /** * 创建分账 @@ -51,7 +53,8 @@ public class LaKaLaTradeSeparateService { } // 查询交易详情 BsTradeOrder tradeOrder = tradeOrderService.getOrderByTradeNoId(tradeOrderProfitSharing.getTradeOrderId()); - + // 商户 + BsMer mer = merService.getMer(tradeOrder.getMerId()); // 分账接收方 List profitSharingReceiverList = tradeOrderProfitSharingReceiverService.getReceiverListByProfitSharingId(tradeOrderProfitSharing.getId()); @@ -65,7 +68,7 @@ public class LaKaLaTradeSeparateService { map.put("log_date", DateUtil.date2String(tradeOrder.getPayTime(), "yyyyMMdd")); map.put("out_separate_no", tradeOrderProfitSharing.getProfitSharingOrderNo()); map.put("total_amt", tradeOrderProfitSharing.getProfitSharingAmoun().multiply(new BigDecimal("100")).longValue()); - map.put("lkl_org_no", "1"); + map.put("lkl_org_no", mer.getOrgNo()); map.put("cal_type", "0"); List> recvDatasMapList = new ArrayList<>(); diff --git a/service/src/main/java/com/hfkj/service/BsMerPlatformNoService.java b/service/src/main/java/com/hfkj/service/BsMerPlatformNoService.java index 8239bf3..af3fd1f 100644 --- a/service/src/main/java/com/hfkj/service/BsMerPlatformNoService.java +++ b/service/src/main/java/com/hfkj/service/BsMerPlatformNoService.java @@ -26,6 +26,8 @@ public interface BsMerPlatformNoService { */ BsMerPlatformNo getPlatformNo(Long merId, PlatformTypeEnum type); + BsMerPlatformNo getPlatformNoByCupNo(String merCupNo); + /** * 查询商户号 * @param param diff --git a/service/src/main/java/com/hfkj/service/impl/BsMerPlatformNoServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsMerPlatformNoServiceImpl.java index c8d6190..bc703a2 100644 --- a/service/src/main/java/com/hfkj/service/impl/BsMerPlatformNoServiceImpl.java +++ b/service/src/main/java/com/hfkj/service/impl/BsMerPlatformNoServiceImpl.java @@ -43,6 +43,17 @@ public class BsMerPlatformNoServiceImpl implements BsMerPlatformNoService { return null; } + @Override + public BsMerPlatformNo getPlatformNoByCupNo(String merCupNo) { + BsMerPlatformNoExample example = new BsMerPlatformNoExample(); + example.createCriteria().andCupNoEqualTo(merCupNo).andStatusEqualTo(1); + List list = merPlatformNoMapper.selectByExample(example); + if (list.size() > 0) { + return list.get(0); + } + return null; + } + @Override public List getMerPlatformNoList(Map param) { BsMerPlatformNoExample example = new BsMerPlatformNoExample();