zhangnaisong
2024-07-06 775524110885e27fe860be1feb156ca78b5040b2
ard-work/src/main/java/com/ruoyi/alarmpoints/well/controller/ArdAlarmpointsWellController.java
@@ -193,11 +193,12 @@
    @PostMapping("/wellList")
    @ApiOperation("查询权限下所有兴趣点")
    public Results wellList() {
        String usersId = SecurityUtils.getUserId();
        /*String usersId = SecurityUtils.getUserId();
        //根据userId查询部门Id
        SysUser sysUser = sysUserService.selectUserById(usersId);
        //根据当前deptId或者当前及所属下级的所有deptId
        List<Long> deptList = sysDeptService.deptIdBySub(sysUser.getDeptId());
        List<Long> deptList = sysDeptService.deptIdBySub(sysUser.getDeptId());*/
        List<Long> deptList = sysDeptService.selectDeptIdBySubAndUserId(SecurityUtils.getDeptId(),SecurityUtils.getUserId());
        //根据deptId获取对应兴趣点数据
        List<ArdAlarmpointsWell> list = ardAlarmpointsWellService.wellList(deptList);
        return Results.succeed(list);
@@ -206,11 +207,12 @@
    @PostMapping("/conditionList")
    @ApiOperation("查看部门下筛选条件的兴趣点")
    public Results conditionList(ArdAlarmpointsWellParam ardAlarmpointsWellParam) {
        String usersId = SecurityUtils.getUserId();
        /*String usersId = SecurityUtils.getUserId();
        //根据userId查询部门Id
        SysUser sysUser = sysUserService.selectUserById(usersId);
        //根据当前deptId或者当前及所属下级的所有deptId
        List<Long> deptList = sysDeptService.deptIdBySub(sysUser.getDeptId());
        List<Long> deptList = sysDeptService.deptIdBySub(sysUser.getDeptId());*/
        List<Long> deptList = sysDeptService.selectDeptIdBySubAndUserId(SecurityUtils.getDeptId(),SecurityUtils.getUserId());
        ardAlarmpointsWellParam.setDeptList(deptList);
        //根据deptId获取对应兴趣点数据
        return Results.succeed(ardAlarmpointsWellService.conditionList(ardAlarmpointsWellParam));