Commit df6f054e by 吕明尚

代码提交

parent bd84aef0
...@@ -9,12 +9,8 @@ import cn.hutool.core.util.StrUtil; ...@@ -9,12 +9,8 @@ import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.dianping.openapi.sdk.api.customerauth.session.entity.CustomerKeyShopScopeResponseEntity; import com.dianping.openapi.sdk.api.customerauth.session.entity.CustomerKeyShopScopeResponseEntity;
import lombok.var;
import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.ObjectUtils;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.apache.poi.hssf.record.DVALRecord;
import org.bouncycastle.util.Store;
import org.locationtech.spatial4j.context.SpatialContext; import org.locationtech.spatial4j.context.SpatialContext;
import org.locationtech.spatial4j.distance.DistanceUtils; import org.locationtech.spatial4j.distance.DistanceUtils;
import org.locationtech.spatial4j.shape.Point; import org.locationtech.spatial4j.shape.Point;
...@@ -393,7 +389,12 @@ public class SStoreServiceImpl extends ServiceImpl<SStoreMapper, SStore> impleme ...@@ -393,7 +389,12 @@ public class SStoreServiceImpl extends ServiceImpl<SStoreMapper, SStore> impleme
wrapper.orderByAsc(SOrder::getEndDate); wrapper.orderByAsc(SOrder::getEndDate);
List<SOrder> list = orderService.list(wrapper); List<SOrder> list = orderService.list(wrapper);
Optional.ofNullable(storeList).orElse(new ArrayList<>()).forEach(item -> { Optional.ofNullable(storeList).orElse(new ArrayList<>()).forEach(item -> {
item.setRoolList(roomMap.get(item.getId())); List<SRoomVo> sRoomVos = roomMap.get(item.getId());
if (CollectionUtils.isEmpty(sRoomVos)) {
item.setRoolList(new ArrayList<>());
return;
}
item.setRoolList(sRoomVos);
item.getRoolList().forEach(room -> { item.getRoolList().forEach(room -> {
if (CollectionUtils.isNotEmpty(sCleanRecordsList)) { if (CollectionUtils.isNotEmpty(sCleanRecordsList)) {
if (CollectionUtils.isNotEmpty(recordsMap.get(room.getId()))) { if (CollectionUtils.isNotEmpty(recordsMap.get(room.getId()))) {
......
...@@ -67,7 +67,7 @@ ...@@ -67,7 +67,7 @@
t1.free_amount, t1.total_times, t1.duration, t1.status, t1.pwd, t1.create_time, t1.last_login_time t1.free_amount, t1.total_times, t1.duration, t1.status, t1.pwd, t1.create_time, t1.last_login_time
from s_consumer t1 from s_consumer t1
where t1.role_type = '1' where t1.role_type = '1'
and t1.id not in (select consumer_id from s_store_consumer where store_id = #{storeId} and position = '2') and t1.id not in (select consumer_id from s_store_consumer where store_id = #{storeId} and position = '1')
<if test="nickName != null and nickName != ''"> <if test="nickName != null and nickName != ''">
AND t1.nick_name like concat('%', #{nickName}, '%') AND t1.nick_name like concat('%', #{nickName}, '%')
</if> </if>
...@@ -90,7 +90,8 @@ ...@@ -90,7 +90,8 @@
t1.free_amount, t1.total_times, t1.duration, t1.status, t1.pwd, t1.create_time, t1.last_login_time t1.free_amount, t1.total_times, t1.duration, t1.status, t1.pwd, t1.create_time, t1.last_login_time
from s_consumer t1 from s_consumer t1
left join s_store_consumer t2 on t2.consumer_id = t1.id left join s_store_consumer t2 on t2.consumer_id = t1.id
where t1.role_type = '1' and t1.id in (select consumer_id from s_store_consumer where store_id = #{storeId}) where t1.role_type = '1'
and t1.id in (select consumer_id from s_store_consumer where store_id = #{storeId} and position = '1')
</select> </select>
......
...@@ -18,7 +18,10 @@ ...@@ -18,7 +18,10 @@
select count(1) from s_store_consumer where store_id=#{storeId} select count(1) from s_store_consumer where store_id=#{storeId}
</select> </select>
<select id="selectByConsumerId" resultType="Long"> <select id="selectByConsumerId" resultType="Long">
select store_id from s_store_consumer where consumer_id=#{consumerId} select store_id
from s_store_consumer
where consumer_id = #{consumerId}
and position = '1'
</select> </select>
<delete id="deleteSStoreConsumer" parameterType="Long"> <delete id="deleteSStoreConsumer" parameterType="Long">
...@@ -29,9 +32,9 @@ ...@@ -29,9 +32,9 @@
</delete> </delete>
<insert id="batchSStoreConsumer"> <insert id="batchSStoreConsumer">
insert into s_store_consumer(consumer_id, store_id) values insert into s_store_consumer(consumer_id, store_id,position) values
<foreach item="item" index="index" collection="list" separator=","> <foreach item="item" index="index" collection="list" separator=",">
(#{item.consumerId},#{item.storeId}) (#{item.consumerId},#{item.storeId},#{item.position})
</foreach> </foreach>
</insert> </insert>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment