diff --git a/mall-common/src/main/java/com/suisung/mall/common/modules/esign/EsignPlatformInfo.java b/mall-common/src/main/java/com/suisung/mall/common/modules/esign/EsignPlatformInfo.java index 3527672b..fa0adc35 100644 --- a/mall-common/src/main/java/com/suisung/mall/common/modules/esign/EsignPlatformInfo.java +++ b/mall-common/src/main/java/com/suisung/mall/common/modules/esign/EsignPlatformInfo.java @@ -47,6 +47,12 @@ public class EsignPlatformInfo implements Serializable { @ApiModelProperty(value = "平台方营业执照公司名称") private String license_company; + @ApiModelProperty(value = "代理商的省/市/区,如:广东省/深圳市/福田区") + private String license_area; + + @ApiModelProperty(value = "代理商的省id/市id/区id,如:11000/11100/11101") + private String license_district_id; + @ApiModelProperty(value = "平台方营业执照公司详细地址") private String license_address; @@ -74,7 +80,7 @@ public class EsignPlatformInfo implements Serializable { @ApiModelProperty(value = "收款账户名称") private String rec_acc_name; - @ApiModelProperty(value = "收款账户账户类型:1-个人;2-企业;") + @ApiModelProperty(value = "收款账户账户类型:1-个人(对私);2-企业(对公);") private Integer rec_acc_type; @ApiModelProperty(value = "收款账户证件号") @@ -95,17 +101,11 @@ public class EsignPlatformInfo implements Serializable { @ApiModelProperty(value = "平台方公司维度") private String latitude; - @ApiModelProperty(value = "平台方公司店铺所在的省") - private String province_id; + @ApiModelProperty(value = "代理商等级:0-平台方(只能一条记录);1-一级代理;2-二级代理;3-三级代理;4-四级代理;") + private Integer level; - @ApiModelProperty(value = "平台方公司所在的市") - private String city_id; - - @ApiModelProperty(value = "平台方公司所在的县区") - private String county_id; - - @ApiModelProperty(value = "类型:0-平台方(只能一条记录);1-一级代理;2-二级代理;3-三级代理;4-四级代理;") - private Integer type; + @ApiModelProperty(value = "邀请码,后期跟收益有关") + private String invite_code; @ApiModelProperty(value = "记录状态:1-有效;2-无效;") private Integer status; diff --git a/mall-common/src/main/java/com/suisung/mall/common/modules/merch/ShopMerchEntry.java b/mall-common/src/main/java/com/suisung/mall/common/modules/store/ShopMchEntry.java similarity index 95% rename from mall-common/src/main/java/com/suisung/mall/common/modules/merch/ShopMerchEntry.java rename to mall-common/src/main/java/com/suisung/mall/common/modules/store/ShopMchEntry.java index b6e32af2..2489279a 100644 --- a/mall-common/src/main/java/com/suisung/mall/common/modules/merch/ShopMerchEntry.java +++ b/mall-common/src/main/java/com/suisung/mall/common/modules/store/ShopMchEntry.java @@ -6,7 +6,7 @@ * Vestibulum commodo. Ut rhoncus gravida arcu. */ -package com.suisung.mall.common.modules.merch; +package com.suisung.mall.common.modules.store; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableId; @@ -25,8 +25,8 @@ import java.util.Date; @EqualsAndHashCode(callSuper = false) @Accessors(chain = true) @TableName("shop_mch_entry") -@ApiModel(value = "ShopMerchEntry 实体", description = "商家入驻信息表") -public class ShopMerchEntry implements Serializable { +@ApiModel(value = "ShopMchEntry 实体", description = "商家入驻信息表") +public class ShopMchEntry implements Serializable { private static final long serialVersionUID = 1L; @ApiModelProperty(value = "自增ID") @@ -192,13 +192,16 @@ public class ShopMerchEntry implements Serializable { @ApiModelProperty(value = "结算银行地区,格式: 省份/城市/乡县") private String bank_area; + @ApiModelProperty(value = "结算账号类型:57-对公 58-对私") + private String account_type; + @ApiModelProperty(value = "入驻商家的收款账户号码") private String account_number; @ApiModelProperty(value = "入驻商家的收款账户姓名") private String account_holder_name; - @ApiModelProperty(value = "入驻商家的审批状态:1-已通过;2-未通过;3-待审核;") + @ApiModelProperty(value = "入驻商家的审批状态:1-已通过;2-未通过;3-待审核;4-未申请过;5-已提交审核;") private Integer approval_status; @ApiModelProperty(value = "入驻商家审批时的备注信息") diff --git a/mall-shop/src/main/java/com/suisung/mall/shop/esign/service/impl/EsignContractFillingFileServiceImpl.java b/mall-shop/src/main/java/com/suisung/mall/shop/esign/service/impl/EsignContractFillingFileServiceImpl.java index 85865d9a..88ba9d90 100644 --- a/mall-shop/src/main/java/com/suisung/mall/shop/esign/service/impl/EsignContractFillingFileServiceImpl.java +++ b/mall-shop/src/main/java/com/suisung/mall/shop/esign/service/impl/EsignContractFillingFileServiceImpl.java @@ -20,7 +20,7 @@ import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; import com.suisung.mall.common.constant.CommonConstant; import com.suisung.mall.common.modules.esign.EsignContractFillingFile; import com.suisung.mall.common.modules.esign.EsignPlatformInfo; -import com.suisung.mall.common.modules.merch.ShopMerchEntry; +import com.suisung.mall.common.modules.store.ShopMchEntry; import com.suisung.mall.common.utils.StringUtils; import com.suisung.mall.core.web.service.impl.BaseServiceImpl; import com.suisung.mall.shop.esign.mapper.EsignContractFillingFileMapper; @@ -32,7 +32,7 @@ import com.suisung.mall.shop.esign.utils.comm.EsignHttpResponse; import com.suisung.mall.shop.esign.utils.enums.EsignRequestType; import com.suisung.mall.shop.esign.utils.exception.EsignDemoException; import com.suisung.mall.shop.page.service.OssService; -import com.suisung.mall.shop.store.service.ShopMerchEntryService; +import com.suisung.mall.shop.store.service.ShopMchEntryService; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Lazy; @@ -70,7 +70,7 @@ public class EsignContractFillingFileServiceImpl extends BaseServiceImpl() {{ put("componentKey", "mch_company17"); - put("componentValue", shopMerchEntry.getContact_name()); + put("componentValue", shopMchEntry.getContact_name()); }}); } } @@ -234,7 +234,7 @@ public class EsignContractFillingFileServiceImpl extends BaseServiceImpl() {{ put("componentKey", "mch_store_name1"); - put("componentValue", shopMerchEntry.getStore_name()); + put("componentValue", shopMchEntry.getStore_name()); }}); list.add(new HashMap() {{ @@ -244,27 +244,27 @@ public class EsignContractFillingFileServiceImpl extends BaseServiceImpl() {{ put("componentKey", "mch_ratio"); - put("componentValue", shopMerchEntry.getSplit_ratio()); + put("componentValue", shopMchEntry.getSplit_ratio()); }}); list.add(new HashMap() {{ put("componentKey", "settlement_method"); - put("componentValue", shopMerchEntry.getSettlement_method()); + put("componentValue", shopMchEntry.getSettlement_method()); }}); list.add(new HashMap() {{ put("componentKey", "mch_address1"); - put("componentValue", shopMerchEntry.getStore_address()); + put("componentValue", shopMchEntry.getStore_address()); }}); list.add(new HashMap() {{ put("componentKey", "mch_bank1"); - put("componentValue", shopMerchEntry.getBank_name()); + put("componentValue", shopMchEntry.getBank_name()); }}); list.add(new HashMap() {{ put("componentKey", "mch_account_number1"); - put("componentValue", shopMerchEntry.getAccount_number()); + put("componentValue", shopMchEntry.getAccount_number()); }}); // 乙方公司名称 @@ -407,9 +407,9 @@ public class EsignContractFillingFileServiceImpl extends BaseServiceImpl { log.debug("###更改同步合同审核状态和下载地址###"); // 更改同步合同审核状态和下载地址 - if (!shopMerchEntryService.updateMerchEntrySignedStatusAndContractDownloadUrl(esignContract.getMch_mobile(), signFlowStatus, localFileUrl)) { + if (!shopMchEntryService.updateMerchEntrySignedStatusAndContractDownloadUrl(esignContract.getMch_mobile(), signFlowStatus, localFileUrl)) { log.error("###更改同步合同审核状态和下载地址失败###"); } }); @@ -527,8 +527,8 @@ public class EsignContractServiceImpl extends BaseServiceImpl response = RestTemplateHttpUtil.sendPostBodyBackEntity("https://htkactvi.lakala.com/registration/file/upload", header, requestBody, JSONObject.class); - if (ObjectUtil.isEmpty(response) || response.getStatusCode() != HttpStatus.OK || response.getBody() == null) { - return null; + ResponseEntity response = RestTemplateHttpUtil.sendPostBodyBackEntity(buildLklServiceUrl(urlPath), header, requestBody, JSONObject.class); + if (ObjectUtil.isEmpty(response) + || response.getStatusCode() != HttpStatus.OK + || ObjectUtil.isEmpty(response.getBody())) { + return JSONUtil.createObj().set("code", 500).set("msg", "返回值有误!"); } + // {batchNo,status,url,showUrl,result{} } return response.getBody(); } @@ -204,77 +211,81 @@ public class LklTkServiceImpl { header.put("Authorization", getLklTkAuthorization()); // 获取商家入驻信息,组成请求参数 - ShopMerchEntry shopMerchEntry = shopMerchEntryService.getShopMerchEntryByCondition(mchMobile, null, CommonConstant.MCH_APPR_STA_PASS); - if (ObjectUtil.isEmpty(shopMerchEntry)) { + ShopMchEntry shopMchEntry = shopMchEntryService.getShopMerchEntryByCondition(mchMobile, null, CommonConstant.MCH_APPR_STA_PASS); + if (ObjectUtil.isEmpty(shopMchEntry)) { return Pair.of(false, "商家入驻信息不存在"); } JSONObject formData = new JSONObject(); formData.put("userNo", "29153396"); - formData.put("email", shopMerchEntry.getEmail()); - formData.put("busiCode", "B2B_SYT"); - formData.put("merRegName", shopMerchEntry.getStore_name()); - Boolean isQy = CommonConstant.MCH_ENTITY_TYPE_QY.equals(shopMerchEntry.getEntity_type()); + formData.put("busiCode", "WECHAT_PAY");// WECHAT_PAY:专业化扫码;B2B_SYT:B2B收银台; + formData.put("email", shopMchEntry.getEmail()); + formData.put("merRegName", shopMchEntry.getStore_name()); + formData.put("merName", shopMchEntry.getStore_name()); + formData.put("merAddr", StringUtils.removeProvinceCityDistrict(shopMchEntry.getStore_address())); + + // 是企业类型商家 + Boolean isQy = CommonConstant.MCH_ENTITY_TYPE_QY.equals(shopMchEntry.getEntity_type()); String merType = isQy ? "TP_MERCHANT" : "TP_PERSONAL"; formData.put("merType", merType); - formData.put("merName", shopMerchEntry.getStore_name()); - formData.put("merAddr", StringUtils.removeProvinceCityDistrict(shopMerchEntry.getStore_address())); - - Map areaCode = getAreaCode(shopMerchEntry.getStore_area(), false); + Map areaCode = getAreaCode(shopMchEntry.getStore_area(), false); if (ObjectUtil.isNotEmpty(areaCode)) { formData.put("provinceCode", areaCode.get("provinceCode")); formData.put("cityCode", areaCode.get("cityCode")); formData.put("countyCode", areaCode.get("countyCode")); } - formData.put("longtude", shopMerchEntry.getStore_longitude()); //longitude 经度 - formData.put("latitude", shopMerchEntry.getStore_latitude()); + formData.put("longtude", shopMchEntry.getStore_longitude()); //longitude 经度 + formData.put("latitude", shopMchEntry.getStore_latitude()); formData.put("source", "H5"); formData.put("larIdType", "01"); // 01 身份证 ,02 护照,03 港澳通行证,04 台胞证,10 外国人永久居留身份证,11 港妨澳居民居住证,12 台湾居民居住证,13 执行事务合伙人,99 其它证件 - String larName = isQy ? shopMerchEntry.getLegal_person_name() : shopMerchEntry.getContact_name(); - String larIdCard = isQy ? shopMerchEntry.getLegal_person_id_number() : shopMerchEntry.getIndividual_id_number(); - String larIdCardStart = isQy ? shopMerchEntry.getLegal_person_id_period_begin() : shopMerchEntry.getIndividual_id_period_begin(); - String larIdCardEnd = isQy ? shopMerchEntry.getLegal_person_id_period_end() : shopMerchEntry.getIndividual_id_period_end(); + String larName = isQy ? shopMchEntry.getLegal_person_name() : shopMchEntry.getContact_name(); + String larIdCard = isQy ? shopMchEntry.getLegal_person_id_number() : shopMchEntry.getIndividual_id_number(); + String larIdCardStart = isQy ? shopMchEntry.getLegal_person_id_period_begin() : shopMchEntry.getIndividual_id_period_begin(); + String larIdCardEnd = isQy ? shopMchEntry.getLegal_person_id_period_end() : shopMchEntry.getIndividual_id_period_end(); + + // 法人相关信息 formData.put("larName", larName); formData.put("larIdCard", larIdCard); formData.put("larIdCardStart", larIdCardStart); // 身份证有效期开始时间 formData.put("larIdCardEnd", larIdCardEnd); // 身份证有效期结束时间 - formData.put("businessContent", shopMerchEntry.getSales_info()); + // 营业执照上的经营内容 + formData.put("businessContent", shopMchEntry.getSales_info()); // 营业执照信息 if (isQy) { - formData.put("licenseName", shopMerchEntry.getBiz_license_company()); - formData.put("licenseNo", shopMerchEntry.getBiz_license_number()); - formData.put("licenseDtStart", shopMerchEntry.getBiz_license_period_begin()); - formData.put("licenseDtEnd", shopMerchEntry.getBiz_license_period_end()); + formData.put("licenseName", shopMchEntry.getBiz_license_company()); + formData.put("licenseNo", shopMchEntry.getBiz_license_number()); + formData.put("licenseDtStart", shopMchEntry.getBiz_license_period_begin()); + formData.put("licenseDtEnd", shopMchEntry.getBiz_license_period_end()); } formData.put("contactMobile", mchMobile); - formData.put("contactName", shopMerchEntry.getContact_name()); + formData.put("contactName", shopMchEntry.getContact_name()); - formData.put("openningBankCode", shopMerchEntry.getBank_code());//结算账户开户⾏号 - formData.put("openningBankName", shopMerchEntry.getBank_name());//结算账户开户⾏名称 - formData.put("clearingBankCode", shopMerchEntry.getClearing_bank_code());//结算账户清算⾏号 + formData.put("openningBankCode", shopMchEntry.getBank_code());//结算账户开户⾏号 + formData.put("openningBankName", shopMchEntry.getBank_name());//结算账户开户⾏名称 + formData.put("clearingBankCode", shopMchEntry.getClearing_bank_code());//结算账户清算⾏号 - formData.put("accountNo", shopMerchEntry.getAccount_number()); //结算人银行卡号 - formData.put("accountName", shopMerchEntry.getAccount_holder_name()); //结算人账户名称 - formData.put("accountIdCard", shopMerchEntry.getLegal_person_id_number());//结算⼈证件号码(身份证) + formData.put("accountType", isQy ? "57" : "58"); //结算账户类型: 57 对公 58 对私 + formData.put("accountNo", shopMchEntry.getAccount_number()); //结算人银行卡号 + formData.put("accountName", shopMchEntry.getAccount_holder_name()); //结算人账户名称 + formData.put("accountIdCard", shopMchEntry.getLegal_person_id_number());//结算⼈证件号码(身份证) formData.put("settleType", "D1"); //结算类型,D0秒到,D1次日结算 formData.put("settlementType", "AUTOMATIC"); // 结算方式:MANUAL:手动结算(结算至拉卡拉APP钱包),AUTOMATIC:自动结算到银行卡,REGULAR:定时结算(仅企业商户支持) - formData.put("accountType", isQy ? "57" : "58"); //结算账户类型: 57 对公 58 对私 //结算信息省份代码 - Map bankAreaCode = getAreaCode(shopMerchEntry.getBank_area(), true); + Map bankAreaCode = getAreaCode(shopMchEntry.getBank_area(), true); if (ObjectUtil.isNotEmpty(bankAreaCode)) { formData.put("settleProvinceCode", bankAreaCode.get("provinceCode")); formData.put("settleCityCode", bankAreaCode.get("cityCode")); - String[] bankAreaName = shopMerchEntry.getBank_area().split(","); + String[] bankAreaName = shopMchEntry.getBank_area().split(","); if (bankAreaName.length >= 2) { formData.put("settleProvinceName", bankAreaName[0]); formData.put("settleCityName", bankAreaName[1]); @@ -294,72 +305,69 @@ public class LklTkServiceImpl { }}); formData.put("bizContent", bizContent); - // 附件文件 + // 附件文件相关开始 JSONArray attachments = new JSONArray(); - JSONObject ID_CARD_FRONT = updatePhoto(shopMerchEntry.getIndividual_id_images(), "ID_CARD_FRONT", true); + JSONObject ID_CARD_FRONT = updatePhoto(shopMchEntry.getIndividual_id_images(), "ID_CARD_FRONT", true); if (ID_CARD_FRONT != null) { attachments.put(ID_CARD_FRONT); // 身份证正面 } - JSONObject ID_CARD_BEHIND = updatePhoto(shopMerchEntry.getIndividual_id_images2(), "ID_CARD_BEHIND", true); + JSONObject ID_CARD_BEHIND = updatePhoto(shopMchEntry.getIndividual_id_images2(), "ID_CARD_BEHIND", true); if (ID_CARD_BEHIND != null) { attachments.put(ID_CARD_BEHIND); // 身份证国徽面 } - JSONObject SETTLE_ID_CARD_FRONT = updatePhoto(shopMerchEntry.getLegal_person_id_images(), "SETTLE_ID_CARD_FRONT", true); + JSONObject SETTLE_ID_CARD_FRONT = updatePhoto(shopMchEntry.getLegal_person_id_images(), "SETTLE_ID_CARD_FRONT", true); if (SETTLE_ID_CARD_FRONT != null) { attachments.put(SETTLE_ID_CARD_FRONT); // 结算人身份证正面 } - JSONObject SETTLE_ID_CARD_BEHIND = updatePhoto(shopMerchEntry.getLegal_person_id_images2(), "SETTLE_ID_CARD_BEHIND", true); + JSONObject SETTLE_ID_CARD_BEHIND = updatePhoto(shopMchEntry.getLegal_person_id_images2(), "SETTLE_ID_CARD_BEHIND", true); if (SETTLE_ID_CARD_BEHIND != null) { attachments.put(SETTLE_ID_CARD_BEHIND); // 结算人身份证国徽面 } - JSONObject BUSINESS_LICENCE = updatePhoto(shopMerchEntry.getBiz_license_image(), "BUSINESS_LICENCE", true); + JSONObject BUSINESS_LICENCE = updatePhoto(shopMchEntry.getBiz_license_image(), "BUSINESS_LICENCE", true); if (BUSINESS_LICENCE != null) { attachments.put(BUSINESS_LICENCE); // 营业执照 } - JSONObject SHOP_OUTSIDE_IMG = updatePhoto(shopMerchEntry.getFront_facade_image(), "SHOP_OUTSIDE_IMG", false); + JSONObject SHOP_OUTSIDE_IMG = updatePhoto(shopMchEntry.getFront_facade_image(), "SHOP_OUTSIDE_IMG", false); if (SHOP_OUTSIDE_IMG != null) { attachments.put(SHOP_OUTSIDE_IMG); // 门店门面图片 } - JSONObject SHOP_INSIDE_IMG = updatePhoto(shopMerchEntry.getEnvironment_image(), "SHOP_INSIDE_IMG", false); + JSONObject SHOP_INSIDE_IMG = updatePhoto(shopMchEntry.getEnvironment_image(), "SHOP_INSIDE_IMG", false); if (SHOP_INSIDE_IMG != null) { attachments.put(SHOP_INSIDE_IMG); // 门店内部图片 } - JSONObject BANK_CARD = updatePhoto(shopMerchEntry.getBank_image(), "BANK_CARD", true); + JSONObject BANK_CARD = updatePhoto(shopMchEntry.getBank_image(), "BANK_CARD", true); if (BANK_CARD != null) { attachments.put(BANK_CARD); // 银行卡图片 } formData.put("attchments", attachments); + // 附件文件相关结束 - - String urlPath = "/sit/htkregistration/merchant"; - if (isProd()) { - urlPath = "/registration/merchant"; - } + String urlPath = isProd() ? "/registration/merchant" : "/sit/htkregistration/merchant"; ResponseEntity response = RestTemplateHttpUtil.sendPostFormDataBackEntity(buildLklTkUrl(urlPath), header, formData, JSONObject.class); if (ObjectUtil.isEmpty(response) || response.getStatusCode() != HttpStatus.OK) { - String errMsg = "请求分账系统出错!"; + String errMsg = "返回空或请求状态异常。"; if (ObjectUtil.isNotEmpty(response.getBody()) && ObjectUtil.isNotEmpty(response.getBody().getStr("message"))) { errMsg = response.getBody().getStr("message"); } return Pair.of(false, "进件失败:" + errMsg); } - // 根据入驻商家的代理商或平台方,顺便新增一个接收方记录 - - // 更改入驻记录的拉卡拉内部商户号和进件请求参数 String merchantNo = response.getBody().getStr("merchantNo"); //拉卡拉内部商户号 - shopMerchEntryService.updateMerchEntryLklMerCupNo(mchMobile, CommonConstant.Disable2, merchantNo, formData.toString()); + Boolean success = shopMchEntryService.updateMerchEntryLklMerCupNo(mchMobile, CommonConstant.Disable2, merchantNo, formData.toString()); + if (!success) { + return Pair.of(false, "提交进件成功,但更新商户号失败!"); + } - return Pair.of(true, "提交成功待审核!"); + return Pair.of(true, "提交进件成功,请等待审核!"); } /** @@ -386,45 +394,46 @@ public class LklTkServiceImpl { // 公钥解密出来的数据 String data = decryptNotifyData(notifyPubKeyPath, reqBodyJSON.getStr("data")); + log.debug("拉卡拉进件异步通知返回解密后的参数:{}", data); if (StrUtil.isBlank(data)) { return new JSONObject().set("code", "500").set("message", "参数解密出错"); } - log.debug("拉卡拉进件异步通知返回解密后的参数:{}", data); // 逻辑处理 JSONObject dataJSON = JSONUtil.parseObj(data); - if (respData.isEmpty() || StrUtil.isBlank(dataJSON.getStr("externalCustomerNo"))) { + if (dataJSON.isEmpty() || StrUtil.isBlank(dataJSON.getStr("externalCustomerNo"))) { return new JSONObject().set("code", "500").set("message", "参数解析出错"); } - String externalCustomerNo = dataJSON.getStr("externalCustomerNo"); //拉卡拉外部商户号 - shopMerchEntryService.updateMerchEntryLklAuditStatusByLklMerCupNo(externalCustomerNo, dataJSON.getStr("customerNo"), CommonConstant.Enable, data); + // 给商家入驻表增加拉卡拉的商户号和拉卡拉返回的数据 + String merCupNo = dataJSON.getStr("externalCustomerNo"); //拉卡拉外部商户号 + Boolean success = shopMchEntryService.updateMerchEntryLklAuditStatusByLklMerCupNo(merCupNo, dataJSON.getStr("customerNo"), CommonConstant.Enable, data); + if (!success) { + return new JSONObject().set("code", "500").set("message", "更新商户号失败"); + } + + // 根据入驻商家的代理商或平台方,顺便新增一个接收方记录 return new JSONObject().set("code", "200").set("message", "成功"); } /** - * 获取拉卡拉省市区编码 + * 获取拉卡拉店铺的(或银行的)省市区编码 * * @param areaName 省份/城市/乡县 * @return */ public Map getAreaCode(String areaName, Boolean isBankArea) { - if (StrUtil.isBlank(areaName)) { - return new HashMap() {{ - put("provinceCode", ""); - put("cityCode", ""); - put("countyCode", ""); - }}; - } + Map retMap = new HashMap() {{ + put("provinceCode", ""); + put("cityCode", ""); + put("countyCode", ""); + }}; + String[] areaNames = areaName.split("/"); - if (areaNames.length < 2) { - return new HashMap() {{ - put("provinceCode", ""); - put("cityCode", ""); - put("countyCode", ""); - }}; + if (StrUtil.isBlank(areaName) || areaNames.length < 2) { + return retMap; } String provinceName = areaNames[0]; @@ -434,29 +443,18 @@ public class LklTkServiceImpl { countryName = areaNames[2]; } - String urlPath = "/sit/htkregistration/organization"; - if (isProd()) { - urlPath = "/registration/organization"; - } - - if (isBankArea) { - urlPath += "/bank"; - } + String urlPath = isProd() ? "/registration/organization" : "/sit/htkregistration/organization"; + urlPath = isBankArea ? urlPath + "/bank" : urlPath; // 银行地区 String authorization = getLklTkAuthorization(); if (StrUtil.isBlank(authorization)) { log.error("获取拉卡拉token失败"); - return new HashMap() {{ - put("provinceCode", ""); - put("cityCode", ""); - put("countyCode", ""); - }}; + return retMap; } JSONObject header = new JSONObject(); header.put("Authorization", getLklTkAuthorization()); - Map areaCodeMap = new HashMap<>(); // 省份列表 ResponseEntity response = RestTemplateHttpUtil.sendGetWithHeader(buildLklTkUrl(urlPath + "/1"), header, JSONArray.class); @@ -467,10 +465,11 @@ public class LklTkServiceImpl { JSONArray jsonArray = response.getBody(); if (CollUtil.isNotEmpty(jsonArray)) { + // 省份列表 for (JSONObject jsonObject : jsonArray.jsonIter()) { if (StrUtil.contains(jsonObject.getStr("name"), provinceName)) { provinceCode = jsonObject.getStr("code"); - areaCodeMap.put("provinceCode", provinceCode); + retMap.put("provinceCode", provinceCode); break; } } @@ -483,15 +482,14 @@ public class LklTkServiceImpl { for (JSONObject jsonObject : jsonArray.jsonIter()) { if (StrUtil.contains(jsonObject.getStr("name"), cityName)) { cityCode = jsonObject.getStr("code"); - areaCodeMap.put("cityCode", cityCode); + retMap.put("cityCode", cityCode); break; } } } } - - // 乡列表 + // 乡县列表 if (StrUtil.isNotBlank(cityCode)) { response = RestTemplateHttpUtil.sendGetWithHeader(buildLklTkUrl(urlPath + "/" + cityCode), header, JSONArray.class); jsonArray = response.getBody(); @@ -499,7 +497,7 @@ public class LklTkServiceImpl { for (JSONObject jsonObject : jsonArray.jsonIter()) { if (StrUtil.contains(jsonObject.getStr("name"), countryName)) { countyCode = jsonObject.getStr("code"); - areaCodeMap.put("countyCode", countyCode); + retMap.put("countyCode", countyCode); break; } } @@ -508,8 +506,7 @@ public class LklTkServiceImpl { } } - - return areaCodeMap; + return retMap; } public JSONObject updatePhoto(String fileUrl, String imgType, Boolean isOcr) { diff --git a/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/admin/ShopMerchEntryAdminController.java b/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/admin/ShopMchEntryAdminController.java similarity index 75% rename from mall-shop/src/main/java/com/suisung/mall/shop/store/controller/admin/ShopMerchEntryAdminController.java rename to mall-shop/src/main/java/com/suisung/mall/shop/store/controller/admin/ShopMchEntryAdminController.java index bdf640be..564cc227 100644 --- a/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/admin/ShopMerchEntryAdminController.java +++ b/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/admin/ShopMchEntryAdminController.java @@ -11,7 +11,7 @@ package com.suisung.mall.shop.store.controller.admin; import cn.hutool.json.JSONObject; import com.suisung.mall.common.api.CommonResult; import com.suisung.mall.common.service.impl.BaseControllerImpl; -import com.suisung.mall.shop.store.service.ShopMerchEntryService; +import com.suisung.mall.shop.store.service.ShopMchEntryService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.web.bind.annotation.RequestBody; @@ -24,10 +24,10 @@ import javax.annotation.Resource; @Api(tags = "店铺基础信息表") @RestController @RequestMapping("/admin/shop/merch") -public class ShopMerchEntryAdminController extends BaseControllerImpl { +public class ShopMchEntryAdminController extends BaseControllerImpl { @Resource - private ShopMerchEntryService shopMerchEntryService; + private ShopMchEntryService shopMchEntryService; /** * 商家申请入驻商城平台 @@ -38,20 +38,20 @@ public class ShopMerchEntryAdminController extends BaseControllerImpl { @ApiOperation(value = "后台-商家申请入驻分页列表", notes = "商家申请入驻分页列表") @RequestMapping(value = "/list", method = RequestMethod.POST) public CommonResult shopMerchEntryList(@RequestBody JSONObject shopMerchEntryJSON) { - return shopMerchEntryService.shopMerchEntryList(shopMerchEntryJSON.getStr("keyword"), shopMerchEntryJSON.getInt("page"), shopMerchEntryJSON.getInt("pageSize")); + return shopMchEntryService.shopMerchEntryList(shopMerchEntryJSON.getStr("keyword"), shopMerchEntryJSON.getInt("page"), shopMerchEntryJSON.getInt("pageSize")); } @ApiOperation(value = "后台-获取商家入驻资料详情", notes = "后台-获取商家入驻资料详情") @RequestMapping(value = "/detail", method = RequestMethod.POST) public CommonResult shopMerchEntryDetail(@RequestBody JSONObject jsonParam) { - return shopMerchEntryService.shopMerchEntryDetail(jsonParam.getLong("id"), "", null); + return shopMchEntryService.shopMerchEntryDetail(jsonParam.getLong("id"), "", null); } @ApiOperation(value = "商家入驻审批", notes = "商家入驻审批") @RequestMapping(value = "/approval", method = RequestMethod.POST) public CommonResult shopMerchEntryApproval(@RequestBody JSONObject jsonParam) { // approvalStatus 入驻商家的审批状态:1-已通过;2-未通过;3-待审核; - return shopMerchEntryService.shopMerchEntryApproval(jsonParam.getLong("id"), jsonParam.getInt("approvalStatus"), jsonParam.getStr("approvalRemark"), jsonParam.getStr("approvalInvalidCol")); + return shopMchEntryService.shopMerchEntryApproval(jsonParam.getLong("id"), jsonParam.getInt("approvalStatus"), jsonParam.getStr("approvalRemark"), jsonParam.getStr("approvalInvalidCol")); } diff --git a/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/mobile/ShopMerchEntryController.java b/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/mobile/ShopMchEntryController.java similarity index 88% rename from mall-shop/src/main/java/com/suisung/mall/shop/store/controller/mobile/ShopMerchEntryController.java rename to mall-shop/src/main/java/com/suisung/mall/shop/store/controller/mobile/ShopMchEntryController.java index 7f6d8e32..976a4cab 100644 --- a/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/mobile/ShopMerchEntryController.java +++ b/mall-shop/src/main/java/com/suisung/mall/shop/store/controller/mobile/ShopMchEntryController.java @@ -10,11 +10,11 @@ package com.suisung.mall.shop.store.controller.mobile; import cn.hutool.json.JSONObject; import com.suisung.mall.common.api.CommonResult; -import com.suisung.mall.common.modules.merch.ShopMerchEntry; +import com.suisung.mall.common.modules.store.ShopMchEntry; import com.suisung.mall.common.service.impl.BaiduMapServiceImpl; import com.suisung.mall.common.service.impl.BaseControllerImpl; import com.suisung.mall.shop.esign.service.EsignContractFillingFileService; -import com.suisung.mall.shop.store.service.ShopMerchEntryService; +import com.suisung.mall.shop.store.service.ShopMchEntryService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.web.bind.annotation.*; @@ -26,10 +26,10 @@ import java.util.Map; @Api(tags = "店铺基础信息表") @RestController @RequestMapping("/mobile/shop/merch") -public class ShopMerchEntryController extends BaseControllerImpl { +public class ShopMchEntryController extends BaseControllerImpl { @Resource - private ShopMerchEntryService shopMerchEntryService; + private ShopMchEntryService shopMchEntryService; @Resource private EsignContractFillingFileService esignContractFillingFileService; @@ -47,26 +47,26 @@ public class ShopMerchEntryController extends BaseControllerImpl { @ApiOperation(value = "店铺主营分类(类目)", notes = "店铺主营分类(类目)") @RequestMapping(value = "/business/category", method = RequestMethod.POST) public CommonResult shopStoreBusinessCategoryList() { - return shopMerchEntryService.storeBusinessCategoryList(); + return shopMchEntryService.storeBusinessCategoryList(); } @ApiOperation(value = "商家申请入驻商城平台", notes = "商家申请入驻商城平台") @RequestMapping(value = "/apply", method = RequestMethod.POST) public CommonResult shopMerchEntryApply(@RequestBody JSONObject shopMerchEntryJSON) { - return shopMerchEntryService.shopMerchEntryApply(shopMerchEntryJSON); + return shopMchEntryService.shopMerchEntryApply(shopMerchEntryJSON); } @ApiOperation(value = "获取商家入驻资料详情", notes = "获取商家入驻资料详情") @RequestMapping(value = "/detail", method = RequestMethod.POST) public CommonResult shopMerchEntryDetail(@RequestBody JSONObject jsonParam) { - return shopMerchEntryService.shopMerchEntryDetail(null, jsonParam.getStr("mobile"), null); + return shopMchEntryService.shopMerchEntryDetail(null, jsonParam.getStr("mobile"), null); } @ApiOperation(value = "通过手机号mobile获取商家入驻审核状态", notes = "通过手机号获取商家入驻审核状态,远程调用用途") @RequestMapping(value = "/approval/status", method = RequestMethod.POST) public Integer shopMerchEntryApprovalStatus(@RequestBody JSONObject jsonParam) { // approvalStatus 入驻商家的审批状态:1-已通过;2-未通过;3-待审核;4-未申请; - ShopMerchEntry record = shopMerchEntryService.shopMerchEntryApprovalInfo(jsonParam.getStr("mobile")); + ShopMchEntry record = shopMchEntryService.shopMerchEntryApprovalInfo(jsonParam.getStr("mobile")); if (record == null || record.getApproval_status() == null) { return 4; } @@ -78,7 +78,7 @@ public class ShopMerchEntryController extends BaseControllerImpl { @RequestMapping(value = "/fresh/approval/status", method = RequestMethod.POST) public CommonResult shopMerchEntryApprovalStatus2(@RequestBody JSONObject jsonParam) { // approvalStatus 入驻商家的审批状态:1-已通过;2-未通过;3-待审核;4-未申请; - ShopMerchEntry record = shopMerchEntryService.shopMerchEntryApprovalInfo(jsonParam.getStr("mobile")); + ShopMchEntry record = shopMchEntryService.shopMerchEntryApprovalInfo(jsonParam.getStr("mobile")); Map result = new HashMap<>(); if (record == null || record.getApproval_status() == null) { // 配合前端的要求,没有申请过入驻商城平台的时候,返回未申请状态 @@ -103,7 +103,7 @@ public class ShopMerchEntryController extends BaseControllerImpl { @ApiOperation(value = "商家重新申请入驻商城平台", notes = "商家申请入驻材料被驳回的时候,修正材料,重新申请入驻") @RequestMapping(value = "/re-apply", method = RequestMethod.POST) public CommonResult shopMerchEntryReApply(@RequestBody JSONObject shopMerchEntryJSON) { - return shopMerchEntryService.shopMerchEntryReApply(shopMerchEntryJSON); + return shopMchEntryService.shopMerchEntryReApply(shopMerchEntryJSON); } /** diff --git a/mall-shop/src/main/java/com/suisung/mall/shop/store/mapper/ShopMerchEntryMapper.java b/mall-shop/src/main/java/com/suisung/mall/shop/store/mapper/ShopMchEntryMapper.java similarity index 80% rename from mall-shop/src/main/java/com/suisung/mall/shop/store/mapper/ShopMerchEntryMapper.java rename to mall-shop/src/main/java/com/suisung/mall/shop/store/mapper/ShopMchEntryMapper.java index 68c7a32f..a40c2a4e 100644 --- a/mall-shop/src/main/java/com/suisung/mall/shop/store/mapper/ShopMerchEntryMapper.java +++ b/mall-shop/src/main/java/com/suisung/mall/shop/store/mapper/ShopMchEntryMapper.java @@ -9,9 +9,9 @@ package com.suisung.mall.shop.store.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import com.suisung.mall.common.modules.merch.ShopMerchEntry; +import com.suisung.mall.common.modules.store.ShopMchEntry; import org.springframework.stereotype.Component; @Component -public interface ShopMerchEntryMapper extends BaseMapper { +public interface ShopMchEntryMapper extends BaseMapper { } diff --git a/mall-shop/src/main/java/com/suisung/mall/shop/store/service/ShopMerchEntryService.java b/mall-shop/src/main/java/com/suisung/mall/shop/store/service/ShopMchEntryService.java similarity index 93% rename from mall-shop/src/main/java/com/suisung/mall/shop/store/service/ShopMerchEntryService.java rename to mall-shop/src/main/java/com/suisung/mall/shop/store/service/ShopMchEntryService.java index d915c228..d3374586 100644 --- a/mall-shop/src/main/java/com/suisung/mall/shop/store/service/ShopMerchEntryService.java +++ b/mall-shop/src/main/java/com/suisung/mall/shop/store/service/ShopMchEntryService.java @@ -10,12 +10,12 @@ package com.suisung.mall.shop.store.service; import cn.hutool.json.JSONObject; import com.suisung.mall.common.api.CommonResult; -import com.suisung.mall.common.modules.merch.ShopMerchEntry; +import com.suisung.mall.common.modules.store.ShopMchEntry; import org.springframework.data.util.Pair; import java.util.List; -public interface ShopMerchEntryService { +public interface ShopMchEntryService { /** * 获取店铺的经营类目列表 @@ -96,7 +96,7 @@ public interface ShopMerchEntryService { * @param loginMobile * @return */ - ShopMerchEntry shopMerchEntryApprovalInfo(String loginMobile); + ShopMchEntry shopMerchEntryApprovalInfo(String loginMobile); /** * 根据商家手机号、营业执照、审批状态获取有效的商家入驻申请记录 @@ -106,7 +106,7 @@ public interface ShopMerchEntryService { * @param approvalStatus * @return */ - ShopMerchEntry getShopMerchEntryByCondition(String loginMobile, String bizLicenseNumber, Integer approvalStatus); + ShopMchEntry getShopMerchEntryByCondition(String loginMobile, String bizLicenseNumber, Integer approvalStatus); /** * 根据商家注册的手机号,更新合同签署状态和合同下载地址 diff --git a/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopMerchEntryServiceImpl.java b/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopMchEntryServiceImpl.java similarity index 92% rename from mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopMerchEntryServiceImpl.java rename to mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopMchEntryServiceImpl.java index d09bef9b..3c2b385c 100644 --- a/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopMerchEntryServiceImpl.java +++ b/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopMchEntryServiceImpl.java @@ -19,7 +19,7 @@ import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.suisung.mall.common.api.CommonResult; import com.suisung.mall.common.constant.CommonConstant; -import com.suisung.mall.common.modules.merch.ShopMerchEntry; +import com.suisung.mall.common.modules.store.ShopMchEntry; import com.suisung.mall.common.utils.BankUtil; import com.suisung.mall.common.utils.StringUtils; import com.suisung.mall.common.utils.phone.PhoneNumberUtils; @@ -31,8 +31,8 @@ import com.suisung.mall.shop.esign.service.EsignContractFillingFileService; import com.suisung.mall.shop.esign.service.EsignContractService; import com.suisung.mall.shop.esign.service.EsignPlatformInfoService; import com.suisung.mall.shop.message.service.ShopMessageTemplateService; -import com.suisung.mall.shop.store.mapper.ShopMerchEntryMapper; -import com.suisung.mall.shop.store.service.ShopMerchEntryService; +import com.suisung.mall.shop.store.mapper.ShopMchEntryMapper; +import com.suisung.mall.shop.store.service.ShopMchEntryService; import com.suisung.mall.shop.store.service.ShopStoreBaseService; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; @@ -51,7 +51,7 @@ import java.util.Map; */ @Slf4j @Service -public class ShopMerchEntryServiceImpl extends BaseServiceImpl implements ShopMerchEntryService { +public class ShopMchEntryServiceImpl extends BaseServiceImpl implements ShopMchEntryService { @Resource private AccountBaseConfigService accountBaseConfigService; @@ -127,7 +127,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl queryWrapper = new QueryWrapper<>(); + QueryWrapper queryWrapper = new QueryWrapper<>(); if (StrUtil.isNotBlank(keyword)) { queryWrapper.like("store_name", keyword); } @@ -353,7 +353,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl listPage = lists(queryWrapper, pageIndex, pageSize); + Page listPage = lists(queryWrapper, pageIndex, pageSize); return CommonResult.success(listPage); } @@ -375,7 +375,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl queryWrapper = new QueryWrapper<>(); + QueryWrapper queryWrapper = new QueryWrapper<>(); if (ObjectUtil.isNotEmpty(recordId)) { queryWrapper.eq("id", recordId); } @@ -389,12 +389,12 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl recordList = list(queryWrapper); + List recordList = list(queryWrapper); if (CollectionUtil.isEmpty(recordList)) { return CommonResult.success(null, "暂无申请记录!"); } - ShopMerchEntry record = recordList.get(0); + ShopMchEntry record = recordList.get(0); // 试试更新入驻表的合同下载地址和合同签署状态 updateMerchEntrySignedStatusAndContractDownloadUrl(record); @@ -407,7 +407,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl updateWrapper = new UpdateWrapper<>(); + UpdateWrapper updateWrapper = new UpdateWrapper<>(); if (approvalStatus.equals(CommonConstant.Enable) && StrUtil.isBlank(approvalRemark)) { // 审核通过 approvalRemark = "审核通过,后续将向您发起签署电子合同流程。"; @@ -524,7 +524,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl queryWrapper = new QueryWrapper<>(); + QueryWrapper queryWrapper = new QueryWrapper<>(); if (StrUtil.isNotBlank(mobile) && StrUtil.isBlank(bizLicenseNumber)) { queryWrapper.eq("login_mobile", mobile); boolean isApplied = count(queryWrapper) > 0; @@ -561,9 +561,9 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl queryWrapper = new QueryWrapper<>(); + QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.eq("login_mobile", mobile).select("approval_status").orderByAsc("id"); - List recordList = list(queryWrapper); + List recordList = list(queryWrapper); if (CollectionUtil.isEmpty(recordList)) { return 0; } @@ -579,22 +579,22 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl queryWrapper = new QueryWrapper<>(); + QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.eq("login_mobile", loginMobile) .select("id", "approval_status", "approval_remark", "login_mobile", "approval_invalid_col", "signed_status", "contract_download_url", "store_status") .orderByAsc("id"); - List recordList = list(queryWrapper); + List recordList = list(queryWrapper); if (CollectionUtil.isEmpty(recordList)) { return null; } - ShopMerchEntry record = recordList.get(0); + ShopMchEntry record = recordList.get(0); // 试试更新入驻表的合同下载地址和合同签署状态 updateMerchEntrySignedStatusAndContractDownloadUrl(record); @@ -611,12 +611,12 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl queryWrapper = new QueryWrapper<>(); + QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.eq("status", CommonConstant.Enable).orderByAsc("id"); if (StrUtil.isNotBlank(loginMobile)) { queryWrapper.eq("login_mobile", loginMobile); @@ -632,7 +632,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl recordList = list(queryWrapper); + List recordList = list(queryWrapper); if (CollectionUtil.isEmpty(recordList)) { return null; } @@ -654,7 +654,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl updateWrapper = new UpdateWrapper<>(); + UpdateWrapper updateWrapper = new UpdateWrapper<>(); updateWrapper.eq("login_mobile", loginMobile); if (ObjectUtil.isNotEmpty(signedStatus)) { @@ -681,7 +681,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl updateWrapper = new UpdateWrapper<>(); + UpdateWrapper updateWrapper = new UpdateWrapper<>(); updateWrapper.eq("login_mobile", loginMobile).set("store_status", storeStatus); return update(updateWrapper); } @@ -692,7 +692,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl updateWrapper = new UpdateWrapper<>(); + UpdateWrapper updateWrapper = new UpdateWrapper<>(); updateWrapper.eq("login_mobile", loginMobile); if (ObjectUtil.isNotEmpty(lklAuditStatus)) { updateWrapper.set("lkl_audit_status", lklAuditStatus); @@ -721,7 +721,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl updateWrapper = new UpdateWrapper<>(); + UpdateWrapper updateWrapper = new UpdateWrapper<>(); updateWrapper.eq("lkl_mer_cup_no", lklMerCupNo); if (ObjectUtil.isNotEmpty(lklAuditStatus)) { updateWrapper.set("lkl_audit_status", lklAuditStatus); @@ -748,7 +748,7 @@ public class ShopMerchEntryServiceImpl extends BaseServiceImpl() + return update(new UpdateWrapper() .eq("id", id) .set("store_id", storeId)); } diff --git a/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopStoreBaseServiceImpl.java b/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopStoreBaseServiceImpl.java index bc9312b4..2946ad80 100644 --- a/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopStoreBaseServiceImpl.java +++ b/mall-shop/src/main/java/com/suisung/mall/shop/store/service/impl/ShopStoreBaseServiceImpl.java @@ -35,7 +35,6 @@ import com.suisung.mall.common.modules.base.*; import com.suisung.mall.common.modules.distribution.ShopDistributionPlantformUser; import com.suisung.mall.common.modules.invoicing.InvoicingCustomerLevel; import com.suisung.mall.common.modules.invoicing.InvoicingWarehouseBase; -import com.suisung.mall.common.modules.merch.ShopMerchEntry; import com.suisung.mall.common.modules.page.ShopPageBase; import com.suisung.mall.common.modules.pay.PayUserResource; import com.suisung.mall.common.modules.plantform.ShopPlantformSubsite; @@ -171,7 +170,7 @@ public class ShopStoreBaseServiceImpl extends BaseServiceImpl districtList = shopBaseDistrictService.getFullDistrictByDistrictCode(shopMerchEntry.getCounty_id()); + List districtList = shopBaseDistrictService.getFullDistrictByDistrictCode(shopMchEntry.getCounty_id()); shopStoreBase.setStore_district_id(shopBaseDistrictService.joinDistrict(districtList, 1, true, "/")); shopStoreBase.setStore_area(shopBaseDistrictService.joinDistrict(districtList, 2, true, "/")); - shopStoreBase.setStore_address(shopMerchEntry.getStore_address()); - shopStoreBase.setStore_longitude(shopMerchEntry.getStore_longitude()); - shopStoreBase.setStore_latitude(shopMerchEntry.getStore_latitude()); + shopStoreBase.setStore_address(shopMchEntry.getStore_address()); + shopStoreBase.setStore_longitude(shopMchEntry.getStore_longitude()); + shopStoreBase.setStore_latitude(shopMchEntry.getStore_latitude()); shopStoreBase.setStore_grade_id(1001); // 店铺等级,默认为普通店铺 shopStoreBase.setStore_type(1);//店铺类型(ENUM): 1-卖家店铺; 2-供应商店铺 shopStoreBase.setStore_is_open(1); @@ -3062,7 +3061,7 @@ public class ShopStoreBaseServiceImpl extends BaseServiceImpl - + *