筹建列表 筹建详情
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
package com.cool.store.dao;
|
||||
|
||||
import com.cool.store.constants.CommonConstants;
|
||||
import com.cool.store.dto.Preparation.PreparationDTO;
|
||||
import com.cool.store.dto.openPreparation.OpenPlanShopInfoDTO;
|
||||
import com.cool.store.dto.point.LineCountDTO;
|
||||
import com.cool.store.entity.ShopInfoDO;
|
||||
import com.cool.store.enums.ErrorCodeEnum;
|
||||
import com.cool.store.exception.ServiceException;
|
||||
import com.cool.store.mapper.ShopInfoMapper;
|
||||
import com.cool.store.request.PreparationRequest;
|
||||
import com.cool.store.vo.shop.StageShopCountVO;
|
||||
import com.github.pagehelper.Page;
|
||||
import com.github.pagehelper.PageHelper;
|
||||
@@ -167,5 +169,11 @@ public class ShopInfoDAO {
|
||||
*/
|
||||
public List<OpenPlanShopInfoDTO> queryShopCodeListByid(@Param("shopIdList") List<Long> shopIdList){
|
||||
return shopInfoMapper.queryShopCodeListByid(shopIdList);
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
public List<PreparationDTO> ListByCondition(PreparationRequest request){
|
||||
return shopInfoMapper.ListByCondition(request);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package com.cool.store.dao;
|
||||
|
||||
import com.cool.store.constants.CommonConstants;
|
||||
import com.cool.store.dto.Preparation.ScheduleDTO;
|
||||
import com.cool.store.entity.ShopStageInfoDO;
|
||||
import com.cool.store.enums.point.ShopStageEnum;
|
||||
import com.cool.store.enums.point.ShopSubStageEnum;
|
||||
@@ -17,6 +18,7 @@ import org.springframework.stereotype.Repository;
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDate;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
@@ -176,4 +178,20 @@ public class ShopStageInfoDAO {
|
||||
PageHelper.startPage(pageNum, pageSize);
|
||||
return shopStageInfoMapper.getShopIdListByStageStatus();
|
||||
}
|
||||
|
||||
public List<ScheduleDTO> getScheduleList(List<Long> shopIdList){
|
||||
if (CollectionUtils.isEmpty(shopIdList)){
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return shopStageInfoMapper.getScheduleList(shopIdList);
|
||||
}
|
||||
|
||||
public List<ShopStageInfoDO> getShopContractActualCompletionTime(List<Long> shopIdList){
|
||||
if (CollectionUtils.isEmpty(shopIdList)){
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return shopStageInfoMapper.getShopContractActualCompletionTime(shopIdList);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,8 +1,10 @@
|
||||
package com.cool.store.mapper;
|
||||
|
||||
import com.cool.store.dto.Preparation.PreparationDTO;
|
||||
import com.cool.store.dto.openPreparation.OpenPlanShopInfoDTO;
|
||||
import com.cool.store.dto.point.LineCountDTO;
|
||||
import com.cool.store.entity.ShopInfoDO;
|
||||
import com.cool.store.request.PreparationRequest;
|
||||
import com.cool.store.vo.shop.StageShopCountVO;
|
||||
import com.github.pagehelper.Page;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
@@ -84,4 +86,8 @@ public interface ShopInfoMapper extends Mapper<ShopInfoDO> {
|
||||
List<OpenPlanShopInfoDTO> queryShopCodeListByid(@Param("shopIdList") List<Long> shopIdList);
|
||||
|
||||
List<LineCountDTO> getSelectedShopNum(@Param("lineIds") List<Long> lineIds);
|
||||
|
||||
|
||||
List<PreparationDTO> ListByCondition(@Param("request") PreparationRequest request);
|
||||
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.cool.store.mapper;
|
||||
|
||||
import com.cool.store.dto.Preparation.ScheduleDTO;
|
||||
import com.cool.store.entity.ShopStageInfoDO;
|
||||
import com.cool.store.vo.shop.RentInfoToDoVO;
|
||||
import com.github.pagehelper.Page;
|
||||
@@ -100,4 +101,8 @@ public interface ShopStageInfoMapper extends Mapper<ShopStageInfoDO> {
|
||||
* @description:获取处于订货金阶段的shopid
|
||||
*/
|
||||
Page<Long> getShopIdListByStageStatus();
|
||||
|
||||
List<ScheduleDTO> getScheduleList(@Param("shopIds") List<Long> shopIds);
|
||||
|
||||
List<ShopStageInfoDO> getShopContractActualCompletionTime(@Param("shopIds") List<Long> shopIds);
|
||||
}
|
||||
|
||||
@@ -128,5 +128,49 @@
|
||||
group by line_id
|
||||
</select>
|
||||
|
||||
<select id="ListByCondition" resultType="com.cool.store.dto.Preparation.PreparationDTO">
|
||||
select
|
||||
a.id as id,
|
||||
a.shop_name as shopName,
|
||||
a.store_num as storeNum,
|
||||
a.shop_manager_user_id as shopManagerUserId,
|
||||
a.region_id as regionId,
|
||||
a.plan_open_time as planOpenTime,
|
||||
b.username as username,
|
||||
b.mobile as mobile
|
||||
from xfsg_shop_info a left join xfsg_line_info b on a.line_id = b.id
|
||||
where a.deleted = 0
|
||||
<if test="request.keyword != null and request.keyword != ''">
|
||||
and (b.username like concat('%', #{request.keyword}, '%') or b.mobile like concat('%', #{request.keyword}, '%'))
|
||||
</if>
|
||||
<if test="request.shopName!=null and request.shopName!=''">
|
||||
and a.shop_name like concat('%', #{request.shopName}, '%')
|
||||
</if>
|
||||
<if test="request.investmentUserId != null and request.investmentUserId != ''">
|
||||
and b.investment_manager = #{request.investmentUserId}
|
||||
</if>
|
||||
<if test="request.supervisorUserId != null and request.supervisorUserId != ''">
|
||||
and a.supervisor_user_id = #{request.supervisorUserId}
|
||||
</if>
|
||||
<if test="request.planOpenStartTime != null and request.planOpenStartTime != ''">
|
||||
and a.plan_open_time >= #{request.planOpenStartTime}
|
||||
</if>
|
||||
<if test="request.planOpenEndTime != null and request.planOpenEndTime != ''">
|
||||
<![CDATA[and a.plan_open_time <= #{request.planOpenEndTime}]]>
|
||||
</if>
|
||||
<if test="request.regionIds != null and request.regionIds.size() > 0">
|
||||
and a.region_id in
|
||||
<foreach collection="request.regionIds" item="regionId" index="index" open="(" separator="," close=")">
|
||||
#{regionId}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="request.authRegionIds != null and request.authRegionIds.size() > 0">
|
||||
and a.region_id in
|
||||
<foreach collection="request.authRegionIds" item="regionId" index="index" open="(" separator="," close=")">
|
||||
#{regionId}
|
||||
</foreach>
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
</mapper>
|
||||
@@ -154,4 +154,33 @@
|
||||
where shop_stage = 2 and shop_sub_stage = 150 and shop_sub_stage_status= 1505 and is_terminated = 0
|
||||
</select>
|
||||
|
||||
<select id="getScheduleList" resultType="com.cool.store.dto.Preparation.ScheduleDTO">
|
||||
select
|
||||
shop_id as shopId,
|
||||
max(plan_complete_time) as planCompleteTime,
|
||||
count(1) as totalColumn,
|
||||
sum(if(is_terminated = 1, 1, 0)) as completionColumn
|
||||
from xfsg_shop_stage_info where shop_stage = 2
|
||||
<if test="shopIds != null and shopIds.size() > 0">
|
||||
and shop_id in
|
||||
<foreach collection="shopIds" item="shopId" index="index" open="(" separator="," close=")">
|
||||
#{shopId}
|
||||
</foreach>
|
||||
</if>
|
||||
group by shop_id
|
||||
</select>
|
||||
|
||||
|
||||
<select id="getShopContractActualCompletionTime" resultMap="BaseResultMap">
|
||||
select
|
||||
*
|
||||
from xfsg_shop_stage_info where shop_stage = 1 and shop_sub_stage = 20 and actual_complete_time is not null
|
||||
<if test="shopIds != null and shopIds.size() > 0">
|
||||
and shop_id in
|
||||
<foreach collection="shopIds" item="shopId" index="index" open="(" separator="," close=")">
|
||||
#{shopId}
|
||||
</foreach>
|
||||
</if>
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user