|
@@ -9,11 +9,14 @@ import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
|
|
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
import com.jeeplus.business.project.domain.JyProject;
|
|
|
+import com.jeeplus.business.project.domain.JyProjectAudit;
|
|
|
import com.jeeplus.business.project.domain.JyProjectOutinstance;
|
|
|
import com.jeeplus.business.project.mapper.JyProjectMapper;
|
|
|
import com.jeeplus.business.project.mapper.JyProjectOutinstanceMapper;
|
|
|
import com.jeeplus.business.project.mapper.JyProjectReportsSubmitMapper;
|
|
|
|
|
|
+import com.jeeplus.business.project.service.dto.JyProjectAuditDTO;
|
|
|
+import com.jeeplus.business.project.service.dto.JyProjectOutinstanceDTO;
|
|
|
import com.jeeplus.business.workContractInfo.mapper.JyWorkContractInfoMapper;
|
|
|
import com.jeeplus.common.TokenProvider;
|
|
|
import com.jeeplus.core.query.QueryWrapperGenerator;
|
|
@@ -552,4 +555,43 @@ public class SignetService {
|
|
|
signetMapper.deleteById(id);
|
|
|
return "删除成功";
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 根据id查询用印
|
|
|
+ * @param id
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public Map<String,Object> queryByProjectIdAndTypeStatus(String projectId, String typeStatus) {
|
|
|
+ Map<String,Object> map = new HashMap<>();
|
|
|
+ map.put("success",false);
|
|
|
+ map.put("message","未查询到项目信息");
|
|
|
+
|
|
|
+ if(StringUtils.isNotBlank(projectId) && StringUtils.isNotBlank(typeStatus)){
|
|
|
+
|
|
|
+ SignetDTO dto = signetMapper.queryByProjectIdAndTypeStatus(projectId,typeStatus);
|
|
|
+ if(null == dto){
|
|
|
+ //根据typeStatus 查询三级校审或者外审流程状态,若是已完成,则可以申请,否则 不可以申请
|
|
|
+ if("1".equals(typeStatus)){//参数为1 则表示申请选择的是报告签发,需要判定该项目得三级校审审核完成
|
|
|
+ //根据项目id查询
|
|
|
+ JyProjectAuditDTO projectAudit = signetMapper.getThirdProjectAuditByProjectId(projectId);
|
|
|
+ if(null != projectAudit){
|
|
|
+ map.put("success",true);
|
|
|
+ map.put("message","可进行报告签发");
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+
|
|
|
+ }else if("2".equals(typeStatus)){//参数为2 则表示申请选择的是报批签发,需要判定该项目得外审审核完成
|
|
|
+ //根据项目id查询外审信息
|
|
|
+ JyProjectOutinstanceDTO outinstance = signetMapper.getProjectOutinstanceByProjectId(projectId);
|
|
|
+ if(null != outinstance){
|
|
|
+ map.put("success",true);
|
|
|
+ map.put("message","可进行报批签发");
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
}
|