Change menu items base on new items in monitor. Add Support in menu of a dashboard.

This commit is contained in:
Konstantinos Triantafyllou 2023-07-06 13:49:45 +03:00
parent f1e959d046
commit b543196a88
5 changed files with 9 additions and 13 deletions

View File

@ -1,4 +1,4 @@
import {ChangeDetectorRef, Component, HostListener, OnDestroy, OnInit} from '@angular/core';
import {ChangeDetectorRef, Component, OnDestroy, OnInit} from '@angular/core';
import {ActivatedRoute, Data, NavigationEnd, Params, Router} from '@angular/router';
import {EnvProperties} from './openaireLibrary/utils/properties/env-properties';
import {Role, Session, User} from './openaireLibrary/login/utils/helper.class';
@ -18,7 +18,6 @@ import {LinksResolver} from "./search/links-resolver";
import {Header} from "./openaireLibrary/sharedComponents/navigationBar.component";
import {properties} from "../environments/environment";
import {ConfigurationService} from "./openaireLibrary/utils/configuration/configuration.service";
import {Option} from "./openaireLibrary/sharedComponents/input/input.component";
import {StakeholderUtils} from "./utils/indicator-utils";
import {SmoothScroll} from "./openaireLibrary/utils/smooth-scroll";
import {ConnectHelper} from "./openaireLibrary/connect/connectHelper";
@ -344,6 +343,7 @@ export class AppComponent implements OnInit, OnDestroy {
null, null, null, null)
);
this.resourcesService.setResources(this.menuItems, '', this.monitorLink, '_blank');
this.menuItems.push(new MenuItem("support", "Support", this.monitorLink + '/support/', "", false, [], null, {}));
if (this.stakeholder.type === "funder") {
this.menuItems.push(
new MenuItem("develop", "Develop",
@ -402,12 +402,8 @@ export class AppComponent implements OnInit, OnDestroy {
this.monitorLink + '/browse', "", false, [], null, {}, null, null, null, null, "_self")
);
this.resourcesService.setResources(this.menuItems, '', this.monitorLink);
let about = new MenuItem("about", "About", "", "", false, [], null, {});
about.items = [
new MenuItem("how-it-works", "How it works", this.monitorLink + '/about/how-it-works', "", false, [], null, {}, null, null, null, null, "_self"),
new MenuItem("faqs", "FAQs", this.monitorLink + '/about/faqs',"", false, [], null, {}, null, null, null, null, "_self")
]
this.menuItems.push(about);
this.menuItems.push(new MenuItem("support", "Support", this.monitorLink + '/support/', "", false, [], null, {}, null, null, null, null, "_self"));
this.menuItems.push(new MenuItem("about", "About", this.monitorLink + '/about/', "", false, [], null, {}, null, null, null, null, "_self"));
if (this.hasAdminMenu) {
this.adminMenuItems = [];
this.backItem = null;

View File

@ -43,8 +43,8 @@ import {StatsProfilesService} from "../../utils/services/stats-profiles.service"
placeholder="Index Short Name"></div>
</div>
<div class="uk-width-1-2@m">
<div *ngIf="statsProfiles" input [formInput]="stakeholderFb.get('statsProfile')" [type]="'autocomplete'"
[options]="statsProfiles" [showOptionsOnEmpty]="true"
<div *ngIf="statsProfiles" input [formInput]="stakeholderFb.get('statsProfile')" [type]="'select'"
[options]="statsProfiles"
placeholder="Stats Profile"></div>
</div>
<div class="uk-width-1-2@m">

@ -1 +1 @@
Subproject commit 4bec61023736145debd4e8da5f6147798bd9a3f4
Subproject commit 76cb586ebd44c3b6aef3cf29ddc21b944398e26d

@ -1 +1 @@
Subproject commit 39cb4e56d0320975fbd08fb5e9c68b87b0c82a10
Subproject commit ad6883318d1268cd61871fb6dfb974639aa3a2fc

@ -1 +1 @@
Subproject commit d32bb1873621bf452bbc6528c3d92474bf826789
Subproject commit 66c6aae50223b0b378156e217ea3572e266eedc3