| | |
| | | import com.ruoyi.shop.domain.pojo.task.MemberTaskRecord; |
| | | import com.ruoyi.shop.domain.pojo.task.TaskFile; |
| | | import com.ruoyi.shop.domain.vo.MerMemberTaskRecordPageVo; |
| | | import com.ruoyi.shop.domain.vo.MgtMemberFollowPageVo; |
| | | import com.ruoyi.shop.mapper.task.MemberTaskRecordMapper; |
| | | import com.ruoyi.shop.service.shop.ShopService; |
| | | import com.ruoyi.shop.service.task.MemberTaskRecordService; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.shop.service.task.TaskFileService; |
| | | import com.ruoyi.shop.util.FileConvertUtils; |
| | | import com.ruoyi.system.api.domain.poji.shop.Shop; |
| | | import com.ruoyi.system.api.service.RemoteShopService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | |
| | | @Resource |
| | | private TaskFileService taskFileService; |
| | | |
| | | |
| | | @Resource |
| | | private ShopService shopService; |
| | | /** |
| | | * |
| | | * 商户分页获取会员跟进任务 |
| | | * @param page |
| | | * @param merMemberTaskPageDto |
| | | * @return |
| | |
| | | return merMemberTaskRecordPageVoList; |
| | | } |
| | | |
| | | /** |
| | | * 平台分页获取会员跟进任务 |
| | | * @param page |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<MgtMemberFollowPageVo> pageMgtMemberFollow(Page page){ |
| | | List<MgtMemberFollowPageVo> mgtMemberFollowPageVoList = memberTaskRecordMapper.pageMgtMemberFollow(page); |
| | | if(mgtMemberFollowPageVoList!=null&&!mgtMemberFollowPageVoList.isEmpty()){ |
| | | Long followId; |
| | | List<TaskFile> taskFileList; |
| | | List<String> picture = new ArrayList<>(); |
| | | List<String> video = new ArrayList<>(); |
| | | List<String> audio = new ArrayList<>(); |
| | | Long shopId; |
| | | Shop shop; |
| | | for(MgtMemberFollowPageVo mgtMemberFollowPageVo : mgtMemberFollowPageVoList){ |
| | | followId = mgtMemberFollowPageVo.getFollowId(); |
| | | taskFileList = taskFileService.listByFollowIdAndFollowType(followId,1); |
| | | if(taskFileList!=null&&!taskFileList.isEmpty()){ |
| | | picture = taskFileList.stream().map(k->k.getFileUrl()).collect(Collectors.toList()); |
| | | } |
| | | taskFileList = taskFileService.listByFollowIdAndFollowType(followId,2); |
| | | if(taskFileList!=null&&!taskFileList.isEmpty()){ |
| | | video = taskFileList.stream().map(k->k.getFileUrl()).collect(Collectors.toList()); |
| | | } |
| | | taskFileList = taskFileService.listByFollowIdAndFollowType(followId,3); |
| | | if(taskFileList!=null&&!taskFileList.isEmpty()){ |
| | | audio = taskFileList.stream().map(k->k.getFileUrl()).collect(Collectors.toList()); |
| | | } |
| | | mgtMemberFollowPageVo.setPicture(picture); |
| | | mgtMemberFollowPageVo.setVideo(video); |
| | | mgtMemberFollowPageVo.setAudio(audio); |
| | | } |
| | | } |
| | | return mgtMemberFollowPageVoList; |
| | | } |
| | | } |