新建考核根据权限查询项目修复

master
jiakun.lin 4 years ago
parent b843dcdbb8
commit 2c8febc6e5
  1. 4
      src/main/java/com/yipin/liuwanr/mapper/ProjectManagementMapper.java
  2. 4
      src/main/java/com/yipin/liuwanr/service/ProjectManagementService.java

@ -96,8 +96,8 @@ public interface ProjectManagementMapper {
@Select({"<script>",
"select * from hr_project_management where enable = 0",//(roleId NOT LIKE '%3%' AND isdel = 0 AND projectPermissions != 0)",
"<if test='userId==null'>AND roleId NOT LIKE '%3%' AND isdel = 0 AND projectPermissions != 0</if>",
" <if test='userId!=null'>AND ((roleId NOT LIKE '%3%' AND isdel = 0 AND projectPermissions != 0) OR ( isdel = 0 AND projectPermissions != 0 AND userId = #{userId} ))</if>",//教师端,一开始进入项目管理,看见自己创建的和其他人看见的
"<if test='userId==null'>AND isdel = 0 AND projectPermissions != 0</if>",
" <if test='userId!=null'>AND ((#{founder} != '14' AND isdel = 0 AND projectPermissions != 0) OR ( isdel = 0 AND projectPermissions != 0 AND userId = #{userId} ))</if>",//教师端,一开始进入项目管理,看见自己创建的和其他人看见的
" <if test='systemId!=null'> and systemId=#{systemId}</if>",
" <if test='queryName!=null'> and projectName LIKE '%' #{queryName} '%'</if>",
" ORDER BY creationTime desc",

@ -91,6 +91,10 @@ public class ProjectManagementService {
vo.setUserId(null);
}
}
//项目创建人暂存权限id 超管不存
if (!"1".equals(roleId)) {
vo.setFounder(roleId);
}
PageHelper.startPage(pageNo, pageSize);
//条件查询
List<ProjectManagement> list = mapper.queryManagementsExportTest(vo);

Loading…
Cancel
Save