| | |
| | | public List<AllocationFindVo> selectSmallRoutine(Integer state,String startTime,String endTime) { |
| | | ArrayList<AllocationFindVo> allocationFindVos = new ArrayList<>(); |
| | | LambdaQueryWrapper<Allocation> wrapper = new LambdaQueryWrapper<>(); |
| | | wrapper.orderByDesc(Allocation::getEscalationTime); |
| | | //获取用户信息 |
| | | List<Integer> list = unitResult(); |
| | | if (!ObjectUtils.isEmpty(list)){ |
| | |
| | | wrapper.between(Allocation::getEscalationTime,startTime,endTime); |
| | | } |
| | | wrapper.eq(Allocation::getIsDel,0).eq(Allocation::getIsInvalid,0); |
| | | wrapper.orderByDesc(Allocation::getEscalationTime); |
| | | List<Allocation> allocations = allocationMapper.selectList(wrapper); |
| | | for (Allocation allocation : allocations) { |
| | | AllocationFindVo allocationFindVo = new AllocationFindVo(); |
| | | BeanUtils.copyProperties(allocation,allocationFindVo); |
| | | Integer state1 = allocationFindVo.getState(); |
| | | if (integer==0 || integer==1){ |
| | | |
| | | if (state1==20){ |
| | | allocationFindVo.setStateName(AppAllocationStateEnum.TO_BE_PROCESSED.name); |
| | | }else if (state1==30){ |
| | | allocationFindVo.setStateName(AppAllocationStateEnum.TO_BE_PROCESSED.name); |
| | | }else if (state1==40 ||state1==50){ |
| | | allocationFindVo.setStateName(AppAllocationStateEnum.COMPLETED.name); |
| | | } |
| | | }else { |
| | | if (state1==20){ |
| | | allocationFindVo.setStateName(AppAllocationStateEnum.TO_BE_PROCESSED.name); |
| | | }else if (state1==30){ |
| | | allocationFindVo.setStateName(AppAllocationStateEnum.TO_BE_PROCESSED.name); |
| | | }else if (state1==40||state1==50){ |
| | | allocationFindVo.setStateName(AppAllocationStateEnum.COMPLETED.name); |
| | | } |
| | | } |
| | | allocationFindVos.add(allocationFindVo); |
| | | } |
| | | List<AllocationFindVo> allocationFindVo = allocationMapper.selectSmallRoutine(state,startTime,endTime); |
| | | return allocationFindVos; |
| | | } |
| | | |