|
@@ -1,48 +0,0 @@
|
|
|
-package com.fjhx.common.service.flow.impl;
|
|
|
-
|
|
|
-import com.baomidou.dynamic.datasource.toolkit.DynamicDataSourceContextHolder;
|
|
|
-import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
|
-import com.fjhx.common.constant.SourceConstant;
|
|
|
-import com.fjhx.common.entity.flow.vo.FlowExampleVoByWdly;
|
|
|
-import com.fjhx.common.mapper.flow.FlowExampleByWdlyMapper;
|
|
|
-import com.fjhx.common.service.flow.FlowExampleByWdlyService;
|
|
|
-import com.fjhx.flow.entity.flow.dto.FlowExampleSelectDto;
|
|
|
-import com.fjhx.flow.entity.flow.po.FlowDefinition;
|
|
|
-import com.fjhx.flow.entity.flow.po.FlowExample;
|
|
|
-import com.fjhx.flow.entity.flow.vo.FlowExampleVo;
|
|
|
-import com.ruoyi.common.core.domain.BasePo;
|
|
|
-import com.ruoyi.common.utils.SecurityUtils;
|
|
|
-import com.ruoyi.common.utils.wrapper.IWrapper;
|
|
|
-import com.ruoyi.common.utils.wrapper.SqlField;
|
|
|
-import com.ruoyi.system.utils.UserUtil;
|
|
|
-import org.springframework.stereotype.Service;
|
|
|
-
|
|
|
-import java.util.List;
|
|
|
-
|
|
|
-@Service
|
|
|
-public class FlowExampleByWdlyServiceImpl extends ServiceImpl<FlowExampleByWdlyMapper, FlowExample> implements FlowExampleByWdlyService {
|
|
|
-
|
|
|
- @Override
|
|
|
- public Page<FlowExampleVoByWdly> getToBeProcessedPage(FlowExampleSelectDto dto) {
|
|
|
- IWrapper<FlowExample> wrapper = IWrapper.getWrapper();
|
|
|
- wrapper.lt("fe", FlowExample::getStatus, 2);
|
|
|
- wrapper.eq("fe", FlowExample::getHandleUserId, SecurityUtils.getUserId());
|
|
|
-
|
|
|
- wrapper.eq("fd", FlowDefinition::getFlowInfoId, dto.getFlowInfoId())
|
|
|
- .keyword(dto,
|
|
|
- new SqlField("fe", FlowExample::getTitle),
|
|
|
- new SqlField("json_unquote( p.victoriatourist_json -> '$.contractCode' )")
|
|
|
- )
|
|
|
- .orderByDesc("fe", FlowExample::getId);
|
|
|
-
|
|
|
- DynamicDataSourceContextHolder.push(SourceConstant.BASE);
|
|
|
- Page<FlowExampleVoByWdly> page = baseMapper.selectExample(dto.getPage(), wrapper);
|
|
|
- DynamicDataSourceContextHolder.poll();
|
|
|
- List<FlowExampleVoByWdly> records = page.getRecords();
|
|
|
-
|
|
|
- // 赋值流程发起人名称
|
|
|
- UserUtil.assignmentNickName(records, BasePo::getCreateUser, FlowExampleVo::setCreateUserName);
|
|
|
- return page;
|
|
|
- }
|
|
|
-}
|