|
@@ -1,17 +1,27 @@
|
|
package com.ozs.base.service.impl;
|
|
package com.ozs.base.service.impl;
|
|
|
|
|
|
|
|
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
|
|
|
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
-import com.ozs.base.domain.BaseAgency;
|
|
|
|
|
|
+import com.github.pagehelper.PageHelper;
|
|
|
|
+import com.github.pagehelper.PageInfo;
|
|
import com.ozs.base.domain.BaseExpert;
|
|
import com.ozs.base.domain.BaseExpert;
|
|
import com.ozs.base.domain.BaseUnitInformation;
|
|
import com.ozs.base.domain.BaseUnitInformation;
|
|
|
|
+import com.ozs.base.domain.vo.BaseExpertVo;
|
|
import com.ozs.base.mapper.BaseExpertMapper;
|
|
import com.ozs.base.mapper.BaseExpertMapper;
|
|
-import com.ozs.base.mapper.BaseSupplierMapper;
|
|
|
|
import com.ozs.base.service.BaseExpertService;
|
|
import com.ozs.base.service.BaseExpertService;
|
|
-import com.ozs.common.core.domain.model.LoginUser;
|
|
|
|
|
|
+import com.ozs.common.core.domain.AjaxResult;
|
|
import com.ozs.common.utils.StringUtils;
|
|
import com.ozs.common.utils.StringUtils;
|
|
|
|
+import com.ozs.plan.doman.PlanQuarter;
|
|
|
|
+import com.ozs.plan.doman.ProvisionalPlan;
|
|
|
|
+import com.ozs.pm.doman.PmDemand;
|
|
|
|
+import com.ozs.pm.doman.PmDemandExpertRef;
|
|
|
|
+import com.ozs.pm.service.IPmDemandService;
|
|
|
|
+import com.ozs.pm.service.PmDemandExpertRefService;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
|
|
+import org.springframework.util.ObjectUtils;
|
|
|
|
|
|
import java.util.Date;
|
|
import java.util.Date;
|
|
import java.util.List;
|
|
import java.util.List;
|
|
@@ -21,6 +31,10 @@ public class BaseExpertServiceImpl extends ServiceImpl<BaseExpertMapper, BaseExp
|
|
|
|
|
|
@Autowired
|
|
@Autowired
|
|
private BaseExpertMapper baseExpertMapper;
|
|
private BaseExpertMapper baseExpertMapper;
|
|
|
|
+ @Autowired
|
|
|
|
+ private PmDemandExpertRefService pmDemandExpertRefService;
|
|
|
|
+ @Autowired
|
|
|
|
+ private IPmDemandService pmDemandService;
|
|
|
|
|
|
@Override
|
|
@Override
|
|
public int insertExpert(BaseExpert baseExpert) {
|
|
public int insertExpert(BaseExpert baseExpert) {
|
|
@@ -48,4 +62,17 @@ public class BaseExpertServiceImpl extends ServiceImpl<BaseExpertMapper, BaseExp
|
|
.set(BaseExpert::getStatus, baseExpert.getStatus());
|
|
.set(BaseExpert::getStatus, baseExpert.getStatus());
|
|
return baseExpertMapper.update(null, lambdaUpdateWrapper);
|
|
return baseExpertMapper.update(null, lambdaUpdateWrapper);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ public AjaxResult selectReviewProject(BaseExpertVo baseExpertVo) {
|
|
|
|
+ // 通过专家ID查询 与专家库关联的采购执行管理ID
|
|
|
|
+ List<Integer> demandIdList = pmDemandExpertRefService.selectByExpertId(baseExpertVo.getId());
|
|
|
|
+ if (StringUtils.isNull(demandIdList) && demandIdList.size() <=0) {
|
|
|
|
+ return AjaxResult.error("当前专家还有有被抽取!");
|
|
|
|
+ }
|
|
|
|
+ List<PmDemand> pmDemandList = pmDemandService.selectByDemandIdList(demandIdList);
|
|
|
|
+ PageHelper.startPage(baseExpertVo.getPageNum().intValue(), baseExpertVo.getPageSize().intValue());
|
|
|
|
+ PageInfo<PmDemand> pageInfo = new PageInfo<>(pmDemandList);
|
|
|
|
+ return AjaxResult.success(pageInfo);
|
|
|
|
+ }
|
|
}
|
|
}
|