| | |
| | | |
| | | async function handleAuthorize(selectedMenuIds: string[], resourceIds: string[]) { |
| | | try { |
| | | // let params: API.SaveRoleCommand = { |
| | | // ...authorizeForm.detail, |
| | | // menuIds: selectedMenuIds, |
| | | // resources: resourceIds.map((x) => ({ |
| | | // resourceId: x, |
| | | // dataPower: EnumRoleWebApiDataPower.All, |
| | | // })), |
| | | // }; |
| | | // let res = await roleServices.saveRole(params); |
| | | // if (res) { |
| | | // Message.successMessage('操作成功'); |
| | | // getList(paginationState.pageIndex); |
| | | // } |
| | | let params: API.SaveRoleCommand = { |
| | | ...authorizeForm.detail, |
| | | menuIds: selectedMenuIds, |
| | | // resources: resourceIds.map((x) => ({ |
| | | // resourceId: x, |
| | | // dataPower: EnumRoleWebApiDataPower.All, |
| | | // })), |
| | | }; |
| | | let res = await roleServices.saveRole(params); |
| | | if (res) { |
| | | Message.successMessage('操作成功'); |
| | | getList(paginationState.pageIndex); |
| | | } |
| | | } catch (error) {} |
| | | } |
| | | |