Skip to content

Commit

Permalink
Merge pull request #1460 from Orange-OpenSource/master-3.0
Browse files Browse the repository at this point in the history
Master 3.0, add privileges to role management
  • Loading branch information
grossmj authored Sep 20, 2023
2 parents bae7bcd + 39401f3 commit b106f31
Show file tree
Hide file tree
Showing 89 changed files with 445 additions and 2,481 deletions.
29 changes: 0 additions & 29 deletions src/app/app-routing.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,20 +60,15 @@ import { ImageManagerComponent } from './components/image-manager/image-manager.
import { UserDetailComponent } from "./components/user-management/user-detail/user-detail.component";
import { UserDetailResolver } from "./resolvers/user-detail.resolver";
import { ManagementComponent } from "./components/management/management.component";
import { PermissionResolver } from "./resolvers/permission.resolver";
import { UserGroupsResolver } from "./resolvers/user-groups.resolver";
import { UserPermissionsResolver } from "./resolvers/user-permissions.resolver";
import { GroupManagementComponent } from "./components/group-management/group-management.component";
import { RoleManagementComponent } from "./components/role-management/role-management.component";
import { PermissionsManagementComponent } from "./components/permissions-management/permissions-management.component";
import { GroupDetailsComponent } from "./components/group-details/group-details.component";
import { GroupMembersResolver } from "./resolvers/group-members.resolver";
import { GroupResolver } from "./resolvers/group.resolver";
import { GroupRoleResolver } from "./resolvers/group-role.resolver";
import { RoleDetailComponent } from "./components/role-management/role-detail/role-detail.component";
import { RoleDetailResolver } from "./resolvers/role-detail.resolver";
import { RolePermissionsComponent } from "./components/role-management/role-detail/role-permissions/role-permissions.component";
import { UserPermissionsComponent } from "./components/user-management/user-detail/user-permissions/user-permissions.component";

const routes: Routes = [
{
Expand Down Expand Up @@ -102,7 +97,6 @@ const routes: Routes = [
resolve: {
user: UserDetailResolver,
groups: UserGroupsResolver,
permissions: UserPermissionsResolver,
controller: ControllerResolve},
},
{ path: 'installed-software', component: InstalledSoftwareComponent },
Expand Down Expand Up @@ -237,10 +231,6 @@ const routes: Routes = [
{
path: 'roles',
component: RoleManagementComponent
},
{
path: 'permissions',
component: PermissionsManagementComponent
}
]
},
Expand All @@ -262,25 +252,6 @@ const routes: Routes = [
controller: ControllerResolve
}
},
{
path: 'controller/:controller_id/management/roles/:role_id/permissions',
component: RolePermissionsComponent,
resolve: {
role: RoleDetailResolver,
controller: ControllerResolve,
permissions: PermissionResolver
}
},
{
path: 'controller/:controller_id/management/users/:user_id/permissions',
component: UserPermissionsComponent,
resolve: {
user: UserDetailResolver,
userPermissions: UserPermissionsResolver,
controller: ControllerResolve,
permissions: PermissionResolver
}
}
],
},
{
Expand Down
38 changes: 5 additions & 33 deletions src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -295,25 +295,10 @@ import { RoleFilterPipe } from './components/role-management/role-filter.pipe';
import { AddRoleDialogComponent } from './components/role-management/add-role-dialog/add-role-dialog.component';
import { DeleteRoleDialogComponent } from './components/role-management/delete-role-dialog/delete-role-dialog.component';
import { RoleDetailComponent } from './components/role-management/role-detail/role-detail.component';
import { PermissionEditorComponent } from './components/role-management/role-detail/permission-editor/permission-editor.component';
import { EditablePermissionComponent } from './components/role-management/role-detail/permission-editor/editable-permission/editable-permission.component';
import { PermissionEditorValidateDialogComponent } from './components/role-management/role-detail/permission-editor/permission-editor-validate-dialog/permission-editor-validate-dialog.component';
import { PermissionsManagementComponent } from './components/permissions-management/permissions-management.component';
import { PermissionEditLineComponent } from '@components/permissions-management/permission-edit-line/permission-edit-line.component';
import {MatSlideToggleModule} from '@angular/material/slide-toggle';
import { UserPermissionsComponent } from './components/user-management/user-detail/user-permissions/user-permissions.component';
import {MatAutocompleteModule} from "@angular/material/autocomplete";
import {PathAutoCompleteComponent} from './components/permissions-management/add-permission-line/path-auto-complete/path-auto-complete.component';
import {FilterCompletePipe} from './components/permissions-management/add-permission-line/path-auto-complete/filter-complete.pipe';
import { AddPermissionLineComponent } from './components/permissions-management/add-permission-line/add-permission-line.component';
import { MethodButtonComponent } from './components/permissions-management/method-button/method-button.component';
import { ActionButtonComponent } from './components/permissions-management/action-button/action-button.component';
import { DeletePermissionDialogComponent } from './components/permissions-management/delete-permission-dialog/delete-permission-dialog.component';
import {MatAutocompleteModule} from "@angular/material/autocomplete";;
import { AddRoleToGroupComponent } from './components/group-details/add-role-to-group/add-role-to-group.component';
import {MatFormFieldModule} from "@angular/material/form-field";
import { PermissionsFilterPipe } from './components/permissions-management/permissions-filter.pipe';
import { DisplayPathPipe } from './components/permissions-management/display-path.pipe';
import {RolePermissionsComponent} from "@components/role-management/role-detail/role-permissions/role-permissions.component";
import { ChangeUserPasswordComponent } from './components/user-management/user-detail/change-user-password/change-user-password.component';
import {MatMenuModule} from "@angular/material/menu";
import { ImageManagerComponent } from './components/image-manager/image-manager.component';
Expand All @@ -324,6 +309,8 @@ import { ExportPortableProjectComponent } from './components/export-portable-pro
import { NodesMenuConfirmationDialogComponent } from './components/project-map/nodes-menu/nodes-menu-confirmation-dialog/nodes-menu-confirmation-dialog.component';
import { ConfirmationDeleteAllProjectsComponent } from './components/projects/confirmation-delete-all-projects/confirmation-delete-all-projects.component';
import { ProjectMapLockConfirmationDialogComponent } from './components/project-map/project-map-menu/project-map-lock-confirmation-dialog/project-map-lock-confirmation-dialog.component';
import { PrivilegeComponent } from './components/role-management/role-detail/privilege/privilege.component';
import { GroupPrivilegesPipe } from './components/role-management/role-detail/privilege/group-privileges.pipe';

@NgModule({
declarations: [
Expand Down Expand Up @@ -533,26 +520,9 @@ import { ProjectMapLockConfirmationDialogComponent } from './components/project-
AddRoleDialogComponent,
DeleteRoleDialogComponent,
RoleDetailComponent,
PermissionEditorComponent,
EditablePermissionComponent,
PermissionEditorValidateDialogComponent,
RemoveToGroupDialogComponent,
PermissionsManagementComponent,
AddRoleToGroupComponent,
PermissionEditLineComponent,
AddPermissionLineComponent,
MethodButtonComponent,
ActionButtonComponent,
DeletePermissionDialogComponent,
PathAutoCompleteComponent,
FilterCompletePipe,
UserPermissionsComponent,
PermissionsFilterPipe,
RolePermissionsComponent,
DisplayPathPipe,
ChangeUserPasswordComponent,
FilterCompletePipe,
DisplayPathPipe,
ChangeUserPasswordComponent,
ProjectReadmeComponent,
ImageManagerComponent,
Expand All @@ -563,6 +533,8 @@ import { ProjectMapLockConfirmationDialogComponent } from './components/project-
NodesMenuConfirmationDialogComponent,
ConfirmationDeleteAllProjectsComponent,
ProjectMapLockConfirmationDialogComponent,
PrivilegeComponent,
GroupPrivilegesPipe,
],
imports: [
BrowserModule,
Expand Down
2 changes: 1 addition & 1 deletion src/app/components/management/management.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import {ControllerService} from "@services/controller.service";
export class ManagementComponent implements OnInit {

controller: Controller;
links = ['users', 'groups', 'roles', 'permissions'];
links = ['users', 'groups', 'roles'];
activeLink: string = this.links[0];

constructor(
Expand Down

This file was deleted.

This file was deleted.

Empty file.

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit b106f31

Please sign in to comment.