提交 e33b955e authored 作者: 吕本才's avatar 吕本才

1、恢复权限标识符2、查询分组信息按照人员隔离开

上级 7f0df731
...@@ -3,6 +3,7 @@ package com.link.report.controller.core; ...@@ -3,6 +3,7 @@ package com.link.report.controller.core;
import com.link.report.pojo.request.CustomerReportAddVo; import com.link.report.pojo.request.CustomerReportAddVo;
import com.link.report.service.CustomerReportService; import com.link.report.service.CustomerReportService;
import com.sfa.common.core.domain.R; import com.sfa.common.core.domain.R;
import com.sfa.common.security.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
...@@ -21,7 +22,7 @@ public class CustomerReportCoreController { ...@@ -21,7 +22,7 @@ public class CustomerReportCoreController {
@Autowired @Autowired
CustomerReportService customerReportService; CustomerReportService customerReportService;
// @RequiresPermissions("bi:supply:list") @RequiresPermissions("bi:supply:list")
@PostMapping("/save") @PostMapping("/save")
public R save(@RequestBody CustomerReportAddVo customerReportAddVo) { public R save(@RequestBody CustomerReportAddVo customerReportAddVo) {
customerReportService.save(customerReportAddVo); customerReportService.save(customerReportAddVo);
......
...@@ -3,6 +3,7 @@ package com.link.report.controller.core; ...@@ -3,6 +3,7 @@ package com.link.report.controller.core;
import com.link.report.pojo.request.CustomerReportGroupVo; import com.link.report.pojo.request.CustomerReportGroupVo;
import com.link.report.service.CustomerReportGroupService; import com.link.report.service.CustomerReportGroupService;
import com.sfa.common.core.domain.R; import com.sfa.common.core.domain.R;
import com.sfa.common.security.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
...@@ -23,7 +24,7 @@ public class CustomerReportGroupCoreController { ...@@ -23,7 +24,7 @@ public class CustomerReportGroupCoreController {
@Autowired @Autowired
CustomerReportGroupService customerReportGroupService; CustomerReportGroupService customerReportGroupService;
// @RequiresPermissions("bi:supply:list") @RequiresPermissions("bi:supply:list")
@PostMapping("/group/save") @PostMapping("/group/save")
public R insertOrUpdate(@RequestBody List<CustomerReportGroupVo> vos) { public R insertOrUpdate(@RequestBody List<CustomerReportGroupVo> vos) {
customerReportGroupService.save(vos); customerReportGroupService.save(vos);
......
...@@ -4,6 +4,7 @@ import com.link.report.pojo.request.CustomerReportQueryListVo; ...@@ -4,6 +4,7 @@ import com.link.report.pojo.request.CustomerReportQueryListVo;
import com.link.report.pojo.response.CustomerReportGroupResDto; import com.link.report.pojo.response.CustomerReportGroupResDto;
import com.link.report.service.CustomerReportGroupService; import com.link.report.service.CustomerReportGroupService;
import com.sfa.common.core.domain.R; import com.sfa.common.core.domain.R;
import com.sfa.common.security.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
...@@ -23,7 +24,7 @@ public class CustomerReportGroupQueryController { ...@@ -23,7 +24,7 @@ public class CustomerReportGroupQueryController {
@Autowired @Autowired
CustomerReportGroupService customerReportGroupService; CustomerReportGroupService customerReportGroupService;
// @RequiresPermissions("bi:supply:list") @RequiresPermissions("bi:supply:list")
@GetMapping("/group/list") @GetMapping("/group/list")
public R<List<CustomerReportGroupResDto>> queryList(CustomerReportQueryListVo vo) { public R<List<CustomerReportGroupResDto>> queryList(CustomerReportQueryListVo vo) {
List<CustomerReportGroupResDto> dtos = customerReportGroupService.queryList(vo); List<CustomerReportGroupResDto> dtos = customerReportGroupService.queryList(vo);
......
...@@ -3,6 +3,7 @@ package com.link.report.controller.query; ...@@ -3,6 +3,7 @@ package com.link.report.controller.query;
import com.link.report.pojo.response.CustomerReportListDto; import com.link.report.pojo.response.CustomerReportListDto;
import com.link.report.service.CustomerReportService; import com.link.report.service.CustomerReportService;
import com.sfa.common.core.domain.R; import com.sfa.common.core.domain.R;
import com.sfa.common.security.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
...@@ -22,7 +23,7 @@ public class CustomerReportQueryController { ...@@ -22,7 +23,7 @@ public class CustomerReportQueryController {
@Autowired @Autowired
CustomerReportService customerReportService; CustomerReportService customerReportService;
// @RequiresPermissions("bi:supply:list") @RequiresPermissions("bi:supply:list")
@GetMapping("/list") @GetMapping("/list")
public R<List<CustomerReportListDto>> queryList() { public R<List<CustomerReportListDto>> queryList() {
List<CustomerReportListDto> customerReportListDtos = customerReportService.queryCustomerReportList(); List<CustomerReportListDto> customerReportListDtos = customerReportService.queryCustomerReportList();
......
...@@ -6,6 +6,7 @@ import com.link.report.service.ReportShareService; ...@@ -6,6 +6,7 @@ import com.link.report.service.ReportShareService;
import com.sfa.common.core.domain.R; import com.sfa.common.core.domain.R;
import com.sfa.common.core.web.controller.BaseController; import com.sfa.common.core.web.controller.BaseController;
import com.sfa.common.datascope.annotation.DataScope; import com.sfa.common.datascope.annotation.DataScope;
import com.sfa.common.security.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
...@@ -34,7 +35,7 @@ public class ReportShareQueryController extends BaseController { ...@@ -34,7 +35,7 @@ public class ReportShareQueryController extends BaseController {
*/ */
@DataScope(deptAlias = "d", userAlias = "u") @DataScope(deptAlias = "d", userAlias = "u")
@GetMapping("/list") @GetMapping("/list")
// @RequiresPermissions("bi:supply:list") @RequiresPermissions("bi:supply:list")
public R<List<ReportShareBiListDto>> selectList(ReportShareListVo reportShareListVo) { public R<List<ReportShareBiListDto>> selectList(ReportShareListVo reportShareListVo) {
List<ReportShareBiListDto> reportShareBiListDtos = reportShareService.selectList(reportShareListVo); List<ReportShareBiListDto> reportShareBiListDtos = reportShareService.selectList(reportShareListVo);
return R.ok(reportShareBiListDtos); return R.ok(reportShareBiListDtos);
......
...@@ -22,7 +22,7 @@ public class CustomerReportGroupDaoImpl implements CustomerReportGroupDao { ...@@ -22,7 +22,7 @@ public class CustomerReportGroupDaoImpl implements CustomerReportGroupDao {
@Override @Override
public List<CustomerReportGroupQueryListDto> queryList() { public List<CustomerReportGroupQueryListDto> queryList() {
// 更加登录人id查询 // 更加登录人id查询
Long userId = SecurityUtils.getUserId(); Long userId = SecurityUtils.getLoginUser().getUserid();
List<CustomerReportGroupQueryListDto> list = reportGroupMapper.queryReportGroupList(String.valueOf(userId)); List<CustomerReportGroupQueryListDto> list = reportGroupMapper.queryReportGroupList(String.valueOf(userId));
return list; return list;
......
...@@ -77,7 +77,8 @@ public class CustomerReportGroupServiceImpl implements CustomerReportGroupServic ...@@ -77,7 +77,8 @@ public class CustomerReportGroupServiceImpl implements CustomerReportGroupServic
@Override @Override
public void save(List<CustomerReportGroupVo> customerReportGroupVo) { public void save(List<CustomerReportGroupVo> customerReportGroupVo) {
// 新增或者修改 先删除后新增 // 新增或者修改 先删除后新增
Long userId = SecurityUtils.getUserId();
Long userId = SecurityUtils.getLoginUser().getUserid();
customerReportGroupDao.deleteByCreatorId(userId); customerReportGroupDao.deleteByCreatorId(userId);
// 新增 // 新增
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论