| | |
| | | |
| | | @GetMapping("list") |
| | | public FebsResponse list(AiProductRole dto, QueryRequest request) { |
| | | |
| | | String companyId = getCurrentUserCompanyId(); |
| | | dto.setCompanyId(companyId); |
| | | Map<String, Object> data = getDataTable(aiProductRoleService.listInPage(dto, request)); |
| | | return new FebsResponse().success().data(data); |
| | | } |
| | |
| | | @ControllerEndpoint(operation = "新增", exceptionMessage = "操作失败") |
| | | public FebsResponse add(@RequestBody @Valid AiProductRole dto) { |
| | | |
| | | String companyId = getCurrentUserCompanyId(); |
| | | dto.setCompanyId(companyId); |
| | | return aiProductRoleService.add(dto); |
| | | } |
| | | |
| | |
| | | |
| | | @GetMapping(value = "/productRoleTree") |
| | | public FebsResponse productRoleTree() { |
| | | |
| | | return new FebsResponse().success().data(aiProductRoleService.productRoleTree()); |
| | | String companyId = getCurrentUserCompanyId(); |
| | | return new FebsResponse().success().data(aiProductRoleService.productRoleTree(companyId)); |
| | | } |
| | | } |