diff --git a/coolstore-partner-model/src/main/java/com/cool/store/dto/ExportJoinShopDTO.java b/coolstore-partner-model/src/main/java/com/cool/store/dto/ExportJoinShopDTO.java index 2e6bef53f..8492cac05 100644 --- a/coolstore-partner-model/src/main/java/com/cool/store/dto/ExportJoinShopDTO.java +++ b/coolstore-partner-model/src/main/java/com/cool/store/dto/ExportJoinShopDTO.java @@ -76,95 +76,107 @@ public class ExportJoinShopDTO { @ColumnWidth(20) private String contractCode; - @ExcelProperty(value = "第一年加盟开始日期", order = 17) + @ExcelProperty(value = "合同签约时间", order = 17) @ColumnWidth(30) - private String firstYearStartTime; + private String contractSignTime; - @ExcelProperty(value = "第一年管理费到期日期", order = 18) + @ExcelProperty(value = "合同开始时间", order = 18) @ColumnWidth(30) - private String firstYearEndTime; + private String contractStartTime; - @ExcelProperty(value = "加盟费(含税)", order = 19) + @ExcelProperty(value = "合同结束时间", order = 19) + @ColumnWidth(30) + private String contractEndTime; + + @ExcelProperty(value = "第几家分店", order = 20) + @ColumnWidth(20) + private Integer partnershipSignatoryFirstWhichStore; + + @ExcelProperty(value = "保护距离", order = 21) + @ColumnWidth(20) + private Integer protectiveDistance; + + @ExcelProperty(value = "加盟费(含税)", order = 22) @ColumnWidth(20) private String franchiseFee; - @ExcelProperty(value = "第一年度管理费(含税)", order = 20) + @ExcelProperty(value = "第一年度管理费(含税)", order = 23) @ColumnWidth(40) private String firstYearManagementFee; - @ExcelProperty(value = "设计费(含税)", order = 21) + @ExcelProperty(value = "设计费(含税)", order = 24) @ColumnWidth(20) private String performanceBond; - @ExcelProperty(value = "保证金(含税)", order = 22) + @ExcelProperty(value = "保证金(含税)", order = 25) @ColumnWidth(20) private String loanMargin; - @ExcelProperty(value = "第一年度品牌使用费(含税)", order = 23) + @ExcelProperty(value = "第一年度品牌使用费(含税)", order = 26) @ColumnWidth(40) private String firstYearFee; - @ExcelProperty(value = "合计缴费金额(含税)", order = 24) + @ExcelProperty(value = "合计缴费金额(含税)", order = 27) @ColumnWidth(30) private String totalAmountContributions; - @ExcelProperty(value = "加盟费优惠原因", order = 25) + @ExcelProperty(value = "加盟费优惠原因", order = 28) @ColumnWidth(30) private String discountReason; - @ExcelProperty(value = "店面租金", order = 26) + @ExcelProperty(value = "店面租金", order = 29) @ColumnWidth(20) private String monthRent; - @ExcelProperty(value = "省", order = 27) + @ExcelProperty(value = "省", order = 30) @ColumnWidth(15) private String province; - @ExcelProperty(value = "市", order = 28) + @ExcelProperty(value = "市", order = 31) @ColumnWidth(15) private String city; - @ExcelProperty(value = "区", order = 29) + @ExcelProperty(value = "区", order = 32) @ColumnWidth(15) private String district; - @ExcelProperty(value = "场地实际面积", order = 30) + @ExcelProperty(value = "场地实际面积", order = 33) @ColumnWidth(15) private String area; - @ExcelProperty(value = "报货物流仓库", order = 31) + @ExcelProperty(value = "报货物流仓库", order = 34) @ColumnWidth(25) private String declareGoodsLogisticsWarehouseName; - @ExcelProperty(value = "报货类型", order = 32) + @ExcelProperty(value = "报货类型", order = 35) @ColumnWidth(20) private String declareGoodsType; - @ExcelProperty(value = "云流水报货时间", order = 33) + @ExcelProperty(value = "云流水报货时间", order = 36) @ColumnWidth(35) private String ylsDeclareGoodsTime; - @ExcelProperty(value = "仓库配送时间", order = 34) + @ExcelProperty(value = "仓库配送时间", order = 37) @ColumnWidth(35) private String warehouseDeliveryTime; - @ExcelProperty(value = "收款公司", order = 35) + @ExcelProperty(value = "收款公司", order = 38) @ColumnWidth(35) private String receivingFirmName; - @ExcelProperty(value = "收款公司民生银行账号", order = 36) + @ExcelProperty(value = "收款公司民生银行账号", order = 39) @ColumnWidth(35) private String receivingMsBankAccount; - @ExcelProperty(value = "店铺地址", order = 37) + @ExcelProperty(value = "店铺地址", order = 40) @ColumnWidth(40) private String shopAddress; - @ExcelProperty(value = "阶段状态-建店资料收集", order = 38) + @ExcelProperty(value = "阶段状态-建店资料收集", order = 41) @ColumnWidth(30) private String buildInformationStatus; - @ExcelProperty(value = "建店资料完成时间", order = 39) + @ExcelProperty(value = "建店资料完成时间", order = 42) @ColumnWidth(30) private String buildInformationEndTime; } \ No newline at end of file diff --git a/coolstore-partner-service/src/main/java/com/cool/store/service/impl/ExportRealizeServiceImpl.java b/coolstore-partner-service/src/main/java/com/cool/store/service/impl/ExportRealizeServiceImpl.java index 48fc90d0f..23ff4c1c9 100644 --- a/coolstore-partner-service/src/main/java/com/cool/store/service/impl/ExportRealizeServiceImpl.java +++ b/coolstore-partner-service/src/main/java/com/cool/store/service/impl/ExportRealizeServiceImpl.java @@ -412,6 +412,11 @@ public class ExportRealizeServiceImpl implements ExportRealizeService { Map buildStageMap = buildStages.stream().collect(Collectors.toMap(ShopStageInfoDO::getShopId, Function.identity())); Map franchiseFeeDTOMap = franchiseFees.stream().filter(o -> o.getShopId() != null) .collect(Collectors.toMap(FranchiseFeeDTO::getShopId, Function.identity())); + Set lineIds = list.stream().map(BranchShopResponse::getLineId).collect(Collectors.toSet()); + List lineInfoDOS = lineInfoDAO.getByLineIds( new ArrayList<>(lineIds)); + Map lineMap = lineInfoDOS.stream().collect(Collectors.toMap(LineInfoDO::getId, Function.identity())); + List qualificationsInfoDOList = qualificationsInfoDAO.getByLineIds(new ArrayList<>(lineIds)); + Map qualificationsInfoDOMap = qualificationsInfoDOList.stream().collect(Collectors.toMap(QualificationsInfoDO::getLineId, Function.identity())); Map signFranchiseMap = new HashMap<>(); if (signFranchises != null) { signFranchiseMap = signFranchises.stream().collect(Collectors.toMap(SignFranchiseDO::getShopId, Function.identity())); @@ -459,8 +464,6 @@ public class ExportRealizeServiceImpl implements ExportRealizeService { FranchiseFeeDTO franchiseFeeDTO = franchiseFeeDTOMap.get(response.getShopId()); dto.setStoreType(StoreTypeEnum.getMessage(response.getStoreType())); if (ObjectUtils.isNotEmpty(franchiseFeeDTO)) { - dto.setFirstYearStartTime(DateUtils.parseDateToStr(SPECIAL_DATE_START_1, franchiseFeeDTO.getFirstYearStartTime())); - dto.setFirstYearEndTime(DateUtils.parseDateToStr(SPECIAL_DATE_START_1, franchiseFeeDTO.getFirstYearEndTime())); String total = (new BigDecimal(franchiseFeeDTO.getPerformanceBond()).add(new BigDecimal(franchiseFeeDTO.getFirstYearFee())) .add(new BigDecimal(franchiseFeeDTO.getFirstYearManagementFee())) .add(new BigDecimal(franchiseFeeDTO.getYearFranchiseFee())) @@ -481,9 +484,15 @@ public class ExportRealizeServiceImpl implements ExportRealizeService { SignFranchiseDO signFranchiseDO = signFranchiseMap.get(response.getShopId()); if (signFranchiseDO != null) { dto.setContractCode(signFranchiseDO.getContractCode()); - dto.setPartnershipSignatoryFirst(signFranchiseDO.getPartnershipSignatoryFirst()); dto.setPartnershipSignatorySecond(signFranchiseDO.getPartnershipSignatorySecond()); + dto.setPartnershipSignatoryFirstMobile(signFranchiseDO.getPartnershipSignatorySecondMobile()); + dto.setPartnershipSignatorySecondIdCard(signFranchiseDO.getPartnershipSignatorySecondIdNumber()); dto.setSignType(SignTypeEnum.getDescByCode(signFranchiseDO.getSignType())); + dto.setProtectiveDistance(signFranchiseDO.getProtectiveDistance()); + dto.setPartnershipSignatoryFirstWhichStore(signFranchiseDO.getPartnershipSignatoryFirstWhichStore()); + dto.setContractSignTime(DateUtils.parseDateToStr(DateUtils.SPECIAL_DATE_START_1, signFranchiseDO.getCreateTime())); + dto.setContractStartTime(DateUtils.parseDateToStr(DateUtils.SPECIAL_DATE_START_1, signFranchiseDO.getContractStartTime())); + dto.setContractEndTime(DateUtils.parseDateToStr(DateUtils.SPECIAL_DATE_START_1, signFranchiseDO.getContractEndTime())); } ShopStageInfoDO buildStageInfoDO = buildStageMap.get(response.getShopId()); if (buildStageInfoDO != null) { @@ -493,6 +502,11 @@ public class ExportRealizeServiceImpl implements ExportRealizeService { dto.setBuildInformationEndTime(buildStageInfoDO.getActualCompleteTime()); } } + LineInfoDO lineInfoDO = lineMap.getOrDefault(response.getLineId(), new LineInfoDO()); + dto.setPartnershipSignatoryFirst(lineInfoDO.getUsername()); + dto.setPartnershipSignatoryFirstMobile(lineInfoDO.getMobile()); + QualificationsInfoDO qualificationsInfoDO = qualificationsInfoDOMap.getOrDefault(response.getLineId(), new QualificationsInfoDO()); + dto.setPartnershipSignatoryFirstIdCard(qualificationsInfoDO.getIdCardNo()); exportList.add(dto); } url = easyExcelUtil.exportExcel(ExportJoinShopDTO.class, exportList, null,