diff --git a/src/main/java/com/yipin/liuwanr/controller/ProjectManagementController.java b/src/main/java/com/yipin/liuwanr/controller/ProjectManagementController.java
index 33e4df3..0ed47ce 100644
--- a/src/main/java/com/yipin/liuwanr/controller/ProjectManagementController.java
+++ b/src/main/java/com/yipin/liuwanr/controller/ProjectManagementController.java
@@ -58,7 +58,7 @@ public class ProjectManagementController {
@GetMapping("/queryAllManagements")
Response queryAllManagements(
@ApiParam(name = "projectPermissions", value = "项目权限(0、练习 1、考核 2、竞赛)", required = false) @RequestParam(required = false) Integer projectPermissions,
- @ApiParam(name = "founder", value = "项目创建人(0、系统 1、老师)", required = false) @RequestParam(required = false) Integer founder,
+ @ApiParam(name = "founder", value = "项目创建人(0、系统 1、老师)", required = false) @RequestParam(required = false) String founder,
@ApiParam(name = "state", value = "项目状态(0、草稿箱 1、已发布)", required = false) @RequestParam(required = false) Integer state,
@ApiParam(name = "projectName", value = "项目名称", required = false) @RequestParam(required = false) String projectName,
@ApiParam(name = "systemId", value = "系统id", required = true) @RequestParam Integer systemId,
@@ -68,7 +68,7 @@ public class ProjectManagementController {
if (null != projectPermissions) {
vo.setProjectPermissions(projectPermissions);
}
- if (null != founder) {
+ if (null != founder && founder !="") {
vo.setFounder(founder);
}
if (null != state) {
diff --git a/src/main/java/com/yipin/liuwanr/entity/ProjectManagement.java b/src/main/java/com/yipin/liuwanr/entity/ProjectManagement.java
index 70b3ca4..3e17a58 100644
--- a/src/main/java/com/yipin/liuwanr/entity/ProjectManagement.java
+++ b/src/main/java/com/yipin/liuwanr/entity/ProjectManagement.java
@@ -21,7 +21,7 @@ public class ProjectManagement {
private Integer projectPermissions;// 项目权限(0、练习 1、考核 2、竞赛)
@ApiModelProperty(value = "创建人(0、系统 1、老师)", name = "founder", example = "0", required = true)
- private Integer founder;// 创建人(0、系统 1、老师)
+ private String founder;// 创建人(0、系统 1、老师)
@ApiModelProperty(hidden = true)
private String creationTime;// 创建时间
@@ -154,11 +154,11 @@ public class ProjectManagement {
this.projectPermissions = projectPermissions;
}
- public Integer getFounder() {
+ public String getFounder() {
return founder;
}
- public void setFounder(Integer founder) {
+ public void setFounder(String founder) {
this.founder = founder;
}
diff --git a/src/main/java/com/yipin/liuwanr/mapper/ProjectManagementMapper.java b/src/main/java/com/yipin/liuwanr/mapper/ProjectManagementMapper.java
index 8f9ba21..67f7c73 100644
--- a/src/main/java/com/yipin/liuwanr/mapper/ProjectManagementMapper.java
+++ b/src/main/java/com/yipin/liuwanr/mapper/ProjectManagementMapper.java
@@ -46,7 +46,7 @@ public interface ProjectManagementMapper {
// "select projectId,projectName,projectPermissions,founder,creationTime,state,knowledgePoints,experimentIntroduction from hr_project_management where isdel=0",
"select * from hr_project_management where 1 = 1",// (roleId NOT LIKE '%3%' AND isdel = 0)",
" AND roleId NOT LIKE '%3%' AND isdel = 0",
- " AND ((roleId NOT LIKE '%3%' AND isdel = 0) OR ( isdel = 0 AND userId = #{userId} ))",//教师端,一开始进入项目管理,看见自己创建的和其他人看见的
+ " AND ((FIND_IN_SET(1,founder) AND isdel = 0) OR ( isdel = 0 AND userId = #{userId} ))",//教师端,一开始进入项目管理,看见自己创建的和其他人看见的
" and projectPermissions=#{projectPermissions}",
" and founder=#{founder}",//教师选择创建人为系统
" and state=#{state}",