| | |
| | | package cn.lili.modules.member.serviceimpl; |
| | | |
| | | import cn.lili.base.Result; |
| | | import cn.lili.common.security.context.UserContext; |
| | | import cn.lili.modules.goods.entity.dos.GoodsSku; |
| | | import cn.lili.modules.goods.service.GoodsSkuService; |
| | |
| | | } |
| | | |
| | | @Override |
| | | public boolean deleteByIds(List<String> ids) { |
| | | public boolean deleteByIds(List<String> ids, String viewType) { |
| | | LambdaQueryWrapper<FootPrint> lambdaQueryWrapper = Wrappers.lambdaQuery(); |
| | | lambdaQueryWrapper.eq(FootPrint::getMemberId, UserContext.getCurrentUser().getId()); |
| | | lambdaQueryWrapper.eq(FootPrint::getViewType, viewType); |
| | | lambdaQueryWrapper.in(FootPrint::getRefId, ids); |
| | | return this.remove(lambdaQueryWrapper); |
| | | } |
| | |
| | | return null; |
| | | } |
| | | Optional<FootPrint> first = |
| | | footPrintPages.getRecords().stream().filter(j -> j.getSkuId().equals(goodsSkuByIdFromCache.get(i).getId())).findFirst(); |
| | | footPrintPages.getRecords().stream().filter(j -> goodsSkuByIdFromCache.get(i).getId().equals(j.getSkuId())).findFirst(); |
| | | return first.map(footPrint -> new EsGoodsIndex(goodsSkuByIdFromCache.get(i), footPrint.getCreateTime())).orElseGet(() -> new EsGoodsIndex(goodsSkuByIdFromCache.get(i))); |
| | | }) |
| | | .collect(Collectors.toList()); |
| | |
| | | lambdaQueryWrapper.eq(FootPrint::getDeleteFlag, false); |
| | | return this.count(lambdaQueryWrapper); |
| | | } |
| | | |
| | | } |