From af751636b2230926584880d4d64c0fefa401b10a Mon Sep 17 00:00:00 2001 From: "k.triantafyllou" Date: Mon, 27 Mar 2023 15:00:12 +0300 Subject: [PATCH] Hide manage pages from menus. Remove header from admin pages --- src/app/app.component.ts | 16 +- src/app/general/general.component.html | 11 +- src/app/general/general.module.ts | 6 +- .../manageStakeholders.component.html | 17 +- .../manageStakeholders.module.ts | 8 +- src/app/openaireLibrary | 2 +- src/app/topic/topic.component.html | 285 ++++++++---------- src/app/topic/topic.module.ts | 5 +- src/app/users/users.component.html | 6 - 9 files changed, 155 insertions(+), 201 deletions(-) diff --git a/src/app/app.component.ts b/src/app/app.component.ts index 81085dc..ac26813 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -303,11 +303,11 @@ export class AppComponent implements OnInit, OnDestroy { } this.adminMenuItems = []; this.adminMenuItems.push(new MenuItem("general", "General", "", "/admin/" + this.stakeholder.alias, false, [], [], {}, {name: 'badge'})); - this.adminMenuItems.push(new MenuItem("indicators", "Indicators", "", "/admin/" + this.stakeholder.alias + '/indicators', false, [], [], {}, {name: 'bar_chart'})); + this.adminMenuItems.push(new MenuItem("indicators", "Indicators", "", "/admin/" + this.stakeholder.alias + '/indicators', false, [], [], {}, {name: 'bar_chart'}, null, "uk-visible@m")); if (this.stakeholder.defaultId) { - this.adminMenuItems.push(new MenuItem("users", "Users", "", "/admin/" + this.stakeholder.alias + "/users", false, [], [], {}, {name: 'group'}, null, null, "/admin/" + this.stakeholder.alias + "/users")); + this.adminMenuItems.push(new MenuItem("users", "Users", "", "/admin/" + this.stakeholder.alias + "/users", false, [], [], {}, {name: 'group'}, null, "uk-visible@m", "/admin/" + this.stakeholder.alias + "/users")); if (this.isCurator()) { - this.adminMenuItems.push(new MenuItem("admin-tools", "Pages & Entities", "", "/admin/" + this.stakeholder.alias + "/admin-tools/pages", false, [], [], {}, {name: 'description'}, null, null, "/admin/" + this.stakeholder.alias + "/admin-tools")); + this.adminMenuItems.push(new MenuItem("admin-tools", "Pages & Entities", "", "/admin/" + this.stakeholder.alias + "/admin-tools/pages", false, [], [], {}, {name: 'description'}, null, "uk-visible@m", "/admin/" + this.stakeholder.alias + "/admin-tools")); } } this.backItem = new MenuItem("back", "Manage profiles", "", "/admin", false, [], null, {}, {name: 'west'}); @@ -324,10 +324,10 @@ export class AppComponent implements OnInit, OnDestroy { "", "/admin", false, [], [], {})); } if (Session.isPortalAdministrator(this.user)) { - this.userMenuItems.push(new MenuItem("adminOptions", "Super Admin options", "", "/admin/admin-tools/portals", false, [], [], {})); + this.userMenuItems.push(new MenuItem("adminOptions", "Super Admin options", "", "/admin/admin-tools/portals", false, [], [], {},null, null, "uk-visible@m")); } if (this.isCurator()) { - this.userMenuItems.push(new MenuItem("monitorOptions", "Monitor options", "", "/admin/monitor/admin-tools/pages", false, [], [], {})); + this.userMenuItems.push(new MenuItem("monitorOptions", "Monitor options", "", "/admin/monitor/admin-tools/pages", false, [], [], {},null, null, "uk-visible@m")); } } if (this.stakeholder) { @@ -355,7 +355,7 @@ export class AppComponent implements OnInit, OnDestroy { this.menuItems.push( new MenuItem("manage", "Manage", "", "/admin/" + this.stakeholder.alias, false, [], null, {} - , null, null, null, null) + , null, null, "uk-visible@m", null) ); } if (!this.hasAdminMenu && this.isFrontPage) { @@ -413,10 +413,10 @@ export class AppComponent implements OnInit, OnDestroy { this.backItem = null; this.adminMenuItems.push(new MenuItem("stakeholders", "Manage profiles", "", "/admin", false, [], [], {}, {name: 'settings'})); if (Session.isPortalAdministrator(this.user)) { - this.adminMenuItems.push(new MenuItem("super_admin", "Super Admin options", "", "/admin/admin-tools/portals", false, [], [], {}, {name: 'settings'}, null, null, '/admin/admin-tools')); + this.adminMenuItems.push(new MenuItem("adminOptions", "Super Admin options", "", "/admin/admin-tools/portals", false, [], [], {}, {name: 'settings'}, null, "uk-visible@m", '/admin/admin-tools')); } if (Session.isPortalAdministrator(this.user) || Session.isMonitorCurator(this.user)) { - this.adminMenuItems.push(new MenuItem("monitor", "Monitor options", "", "/admin/monitor/admin-tools/pages", false, [], [], {}, {name: 'settings'}, null, null, '/admin/monitor/admin-tools')); + this.adminMenuItems.push(new MenuItem("monitorOptions", "Monitor options", "", "/admin/monitor/admin-tools/pages", false, [], [], {}, {name: 'settings'}, null, "uk-visible@m", '/admin/monitor/admin-tools')); } this.hasAdminMenu = this.hasAdminMenu && this.adminMenuItems.length > 1; } diff --git a/src/app/general/general.component.html b/src/app/general/general.component.html index 505a149..b6617a5 100644 --- a/src/app/general/general.component.html +++ b/src/app/general/general.component.html @@ -1,14 +1,7 @@
-
-
-
-
Manage Profile
-

{{stakeholder.name}} (unsaved changes)

-
-
-
-
+ +
+ - -
-
-
-
- + + + +
  • + + + Create new subcategory + +
  • +
    -
    -
    -
    Manage Users
    -

    {{stakeholder.name}}

    -
    -