lyhzzz 1 year ago
parent
commit
dbdad7fc89

+ 0 - 5
src/main/java/com/fdkankan/manage_jp/controller/ProjectController.java

@@ -49,11 +49,6 @@ public class ProjectController extends BaseController{
         return Result.success();
     }
 
-    @PostMapping("/getScene")
-    public Result getScene(@RequestBody  ProjectParam param){
-        param.setUserId(getUser().getId());
-        return Result.success(projectService.getSceneByProjectId(param));
-    }
 
     @PostMapping("/addScene")
     public Result addScene(@RequestBody ProjectAddSceneParam param){

+ 0 - 1
src/main/java/com/fdkankan/manage_jp/service/IProjectService.java

@@ -31,5 +31,4 @@ public interface IProjectService extends IService<Project> {
 
     List<Project> listShow();
 
-    Object getSceneByProjectId( ProjectParam param);
 }

+ 2 - 18
src/main/java/com/fdkankan/manage_jp/service/impl/ProjectServiceImpl.java

@@ -112,9 +112,9 @@ public class ProjectServiceImpl extends ServiceImpl<IProjectMapper, Project> imp
         List<String> numList = param.getNumList();
 
         List<String> addNumList = numList.stream().filter(e -> !dbNumList.contains(e)).collect(Collectors.toList());
-        List<String> delNumList = dbNumList.stream().filter(e -> !numList.contains(e)).collect(Collectors.toList());
+        //List<String> delNumList = dbNumList.stream().filter(e -> !numList.contains(e)).collect(Collectors.toList());
 
-        projectNumService.delNumList(param.getProjectId(),delNumList);
+        //projectNumService.delNumList(param.getProjectId(),delNumList);
         projectNumService.addNumList(param.getProjectId(),addNumList);
 
     }
@@ -132,20 +132,4 @@ public class ProjectServiceImpl extends ServiceImpl<IProjectMapper, Project> imp
 
     }
 
-    @Override
-    public Object getSceneByProjectId( ProjectParam param) {
-        if(param.getProjectId() == null){
-            throw new BusinessException(ResultCode.PARAM_ERROR);
-        }
-        Project project = this.getById(param.getProjectId());
-        if(project == null){
-            return PageInfo.PageInfoEmpty(param.getPageNum(),param.getPageSize());
-        }
-        List<ProjectNum> projectNumList = projectNumService.getByProjectId(Arrays.asList(param.getProjectId()));
-        if(projectNumList== null || projectNumList.isEmpty()){
-            return PageInfo.PageInfoEmpty(param.getPageNum(),param.getPageSize());
-        }
-        List<String> numList = projectNumList.stream().map(ProjectNum::getNum).collect(Collectors.toList());
-        return numList;
-    }
 }