Merge #89 into master from cc_20260402_minor_req
fix:诸多小需求 * cc_20260402_minor_req: (6 commits squashed) - fix:PC端新增租赁合同相关接口 - fix:新发标签不过滤私域码 - fix:开店管理新增签约阶段完成时间筛选条件 - fix:删除多余接口 - fix:网商激活短链显示 - fix:开店管理导出去除限制 Signed-off-by: 王非凡 <accounts_67eba0c5fee9c49c80c8e2b4@mail.teambition.com> Merged-by: 正新 <accounts_6964c7bcd2a2c377c5bbd01b@mail.teambition.com> CR-link: https://codeup.aliyun.com/692ea314dec569489f6f167c/hangzhou/java/custom_zxjp/change/89
This commit is contained in:
@@ -4,7 +4,7 @@ import com.cool.store.utils.StringUtil;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
@@ -59,13 +59,13 @@ public enum FranchiseBrandEnum {
|
||||
if (StringUtils.isBlank(code)){
|
||||
return null;
|
||||
}
|
||||
int i = Integer.parseInt(code);
|
||||
for (FranchiseBrandEnum e : FranchiseBrandEnum.values()) {
|
||||
if (i == e.getCode()) {
|
||||
return e.getDesc();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
return Arrays.stream(code.split(","))
|
||||
.map(v -> {
|
||||
FranchiseBrandEnum brand = getEnumByCode(v);
|
||||
return Objects.nonNull(brand) ? brand.getDesc() : null;
|
||||
})
|
||||
.filter(StringUtils::isNotBlank)
|
||||
.collect(Collectors.joining(","));
|
||||
}
|
||||
|
||||
public static FranchiseBrandEnum getEnumByCode(String code) {
|
||||
|
||||
@@ -15,7 +15,9 @@ public enum SpecialTagEnum {
|
||||
ACTIVITY_CAROUSEL("活动轮播"),
|
||||
ACTIVITY_PACKAGE("活动套餐"),
|
||||
PROMOTIONAL_VIDEO("宣传视频"),
|
||||
CALLING_SCREEN("叫号屏");;
|
||||
CALLING_SCREEN("叫号屏"),
|
||||
PRIVATE_SPHERE_QR("私域码"),
|
||||
;
|
||||
|
||||
private final String tagName;
|
||||
|
||||
|
||||
@@ -324,6 +324,9 @@
|
||||
<if test="request.contractStartTime !=null and request.contractEndTime != null">
|
||||
left join xfsg_sign_franchise c on a.id = c.shop_id
|
||||
</if>
|
||||
<if test="request.signStageStartTime != null and request.signStageEndTime">
|
||||
left join xfsg_shop_stage_info d on a.id = d.shop_id and d.shop_stage = 2 and d.shop_sub_stage = 80
|
||||
</if>
|
||||
where a.deleted = 0
|
||||
<if test="request.contractStartTime !=null and request.contractEndTime !=null">
|
||||
and c.create_time between #{request.contractStartTime} and #{request.contractEndTime}
|
||||
@@ -394,6 +397,9 @@
|
||||
</foreach>
|
||||
)
|
||||
</if>
|
||||
<if test="request.signStageStartTime != null and request.signStageEndTime">
|
||||
and d.actual_complete_time between #{request.signStageStartTime} and #{request.signStageEndTime}
|
||||
</if>
|
||||
order by a.update_time desc
|
||||
</select>
|
||||
<select id="getShopListByRegion" resultType="com.cool.store.entity.ShopInfoDO">
|
||||
|
||||
@@ -86,4 +86,7 @@ public class AccountInfoDTO {
|
||||
|
||||
@ApiModelProperty("crm门店id")
|
||||
private String outStoreId;
|
||||
|
||||
@ApiModelProperty("网商激活短链(平安不返回),调用重新发送后会变")
|
||||
private String activityUrl;
|
||||
}
|
||||
|
||||
@@ -51,6 +51,12 @@ public class BranchShopRequest extends PageBasicInfo{
|
||||
private Date contractStartTime;
|
||||
@ApiModelProperty("合同结束时间")
|
||||
private Date contractEndTime;
|
||||
|
||||
@ApiModelProperty("签约阶段完成开始时间")
|
||||
private Date signStageStartTime;
|
||||
|
||||
@ApiModelProperty("签约阶段完成结束时间")
|
||||
private Date signStageEndTime;
|
||||
|
||||
@ApiModelProperty(value = "招商区域", hidden = true)
|
||||
private List<String> authInvestRegionIds;
|
||||
|
||||
@@ -51,4 +51,7 @@ public class AccountInfoVO {
|
||||
|
||||
@ApiModelProperty("工商类型 1.企业 2.个体工商户 3.小微商户(自然人)")
|
||||
private Integer businessType;
|
||||
|
||||
@ApiModelProperty("网商激活短链(平安不返回),调用重新发送后会变")
|
||||
private String activityUrl;
|
||||
}
|
||||
|
||||
@@ -55,6 +55,7 @@ import java.util.*;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.cool.store.utils.CommonUtil.convertToBig;
|
||||
import static com.cool.store.utils.poi.DateUtils.*;
|
||||
|
||||
/**
|
||||
@@ -170,10 +171,10 @@ public class ExportRealizeServiceImpl implements ExportRealizeService {
|
||||
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()))
|
||||
.add(new BigDecimal(franchiseFeeDTO.getLoanMargin())).toString());
|
||||
String total = (convertToBig(franchiseFeeDTO.getPerformanceBond()).add(convertToBig(franchiseFeeDTO.getFirstYearFee()))
|
||||
.add(convertToBig(franchiseFeeDTO.getFirstYearManagementFee()))
|
||||
.add(convertToBig(franchiseFeeDTO.getYearFranchiseFee()))
|
||||
.add(convertToBig(franchiseFeeDTO.getLoanMargin())).toString());
|
||||
dto.setTotalAmountContributions(total);
|
||||
dto.setFranchiseFeeBill(franchiseFeeDTO.getYearFranchiseFee());
|
||||
dto.setLoanMargin(franchiseFeeDTO.getLoanMargin());
|
||||
|
||||
@@ -94,17 +94,23 @@ public class ExportServiceImpl implements ExportService {
|
||||
|
||||
@Override
|
||||
public Long branchShopList(BranchShopRequest request, LoginUserInfo user) {
|
||||
request.setPageSize(CommonConstants.MAX_EXPORT_SIZE + 100);
|
||||
request.setPageNum(CommonConstants.ONE);
|
||||
PageInfo<BranchShopResponse> branchShopList = shopService.getBranchShopList(request, user.getUserId());
|
||||
long total = branchShopList.getTotal();
|
||||
request.setPageSize(1000);
|
||||
List<BranchShopResponse> exportList = new ArrayList<>();
|
||||
boolean hasNext = true;
|
||||
int pageNum = 1;
|
||||
long total = 0;
|
||||
while (hasNext) {
|
||||
request.setPageNum(pageNum++);
|
||||
PageInfo<BranchShopResponse> branchShopList = shopService.getBranchShopList(request, user.getUserId());
|
||||
if (CollectionUtils.isEmpty(branchShopList.getList())) {
|
||||
break;
|
||||
}
|
||||
hasNext = branchShopList.getList().size() >= request.getPageSize();
|
||||
total += branchShopList.getList().size();
|
||||
exportList.addAll(branchShopList.getList());
|
||||
}
|
||||
if (total == CommonConstants.ZERO) {
|
||||
return CommonConstants.ZERO_LONG;
|
||||
} else if (total > CommonConstants.MAX_EXPORT_SIZE) {
|
||||
exportList.addAll(branchShopList.getList().subList(0, CommonConstants.MAX_EXPORT_SIZE));
|
||||
} else {
|
||||
exportList.addAll(branchShopList.getList());
|
||||
}
|
||||
ImportTaskDO importTaskDO = new ImportTaskDO();
|
||||
importTaskDO.setStatus(ImportStatusEnum.Ongoing.getCode());
|
||||
@@ -115,7 +121,7 @@ public class ExportServiceImpl implements ExportService {
|
||||
importTaskDO.setCreateTime(new Date().getTime());
|
||||
importTaskDO.setCreateName(user.getName());
|
||||
importTaskMapper.insert(eid, importTaskDO);
|
||||
exportRealizeService.branchShopList(branchShopList.getList(), importTaskDO);
|
||||
exportRealizeService.branchShopList(exportList, importTaskDO);
|
||||
return total;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user