diff --git a/package.json b/package.json index 3a63672..fb72882 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "monitor", - "version": "1.0.3", + "version": "1.0.4", "scripts": { "ng": "ng", "start": " ng serve --port 4500 --disable-host-check --host 0.0.0.0", diff --git a/src/app/app-routing.module.ts b/src/app/app-routing.module.ts index 05f050b..1814f0d 100644 --- a/src/app/app-routing.module.ts +++ b/src/app/app-routing.module.ts @@ -9,6 +9,10 @@ const routes: Routes = [ path: 'about', loadChildren: () => import('./about/about.module').then(m => m.AboutModule) }, + { + path: 'subscriptions', + loadChildren: () => import('./subscriptions/subscriptions.module').then(m => m.SubscriptionsModule) + }, { path: 'support', loadChildren: () => import('./support/support.module').then(m => m.SupportModule), diff --git a/src/app/app.component.ts b/src/app/app.component.ts index 2708dc1..da1f30a 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -213,6 +213,9 @@ export class AppComponent { new MenuItem("", "Blog", "https://blogs.openaire.eu/", "", false, [], [], {}), new MenuItem("", "Contact us", "https://beta.openaire.eu/contact-us", "", false, [], [], {}) ]; + this.menuItems.push( + new MenuItem("subscriptions", "Subscriptions", "", "/subscriptions", false, [], null, {}, null, null) + ); this.menuItems.push( new MenuItem("contact-us", "Contact us", "", "/contact-us", false, [], null, {}, null, null, "uk-hidden@m") ); diff --git a/src/app/home/home.component.ts b/src/app/home/home.component.ts index 1e77269..9dcb3c2 100644 --- a/src/app/home/home.component.ts +++ b/src/app/home/home.component.ts @@ -249,7 +249,7 @@ export class HomeComponent implements OnInit, OnDestroy, AfterViewInit, IDeactiv public getStakeholders() { this.loading = true; this.status = this.errorCodes.LOADING; - this.subscriptions.push(this._stakeholderService.getStakeholders(this.properties.monitorServiceAPIURL).subscribe( + this.subscriptions.push(this._stakeholderService.getStakeholders().subscribe( stakeholders => { if (!stakeholders || stakeholders.length == 0) { this.status = this.errorCodes.NONE; diff --git a/src/app/my-stakeholders/my-stakeholders.component.ts b/src/app/my-stakeholders/my-stakeholders.component.ts index d6937b6..ff7c788 100644 --- a/src/app/my-stakeholders/my-stakeholders.component.ts +++ b/src/app/my-stakeholders/my-stakeholders.component.ts @@ -101,7 +101,7 @@ export class MyStakeholdersComponent { this.status = this.errorCodes.LOADING; this.subscriberErrorMessage = ""; this.stakeholders = []; - this.subscriptions.push(this.stakeholderService.getMyStakeholders(properties.monitorServiceAPIURL).subscribe( + this.subscriptions.push(this.stakeholderService.getMyStakeholders().subscribe( stakeholders => { this.stakeholders = StakeholderInfo.toStakeholderInfo(stakeholders.standalone.concat(stakeholders.umbrella), this.user); this.sort(this.stakeholders); diff --git a/src/app/openaireLibrary b/src/app/openaireLibrary index 9b1e662..59cb697 160000 --- a/src/app/openaireLibrary +++ b/src/app/openaireLibrary @@ -1 +1 @@ -Subproject commit 9b1e662f4b64d4f4c6eb7a4d82657a0fe3ea8391 +Subproject commit 59cb69736c4efdbdffa790e8da7a0c31171737a6 diff --git a/src/app/search-stakeholders/search-stakeholders.component.ts b/src/app/search-stakeholders/search-stakeholders.component.ts index ec636b8..6fc5740 100644 --- a/src/app/search-stakeholders/search-stakeholders.component.ts +++ b/src/app/search-stakeholders/search-stakeholders.component.ts @@ -136,7 +136,7 @@ export class SearchStakeholdersComponent { this.totalResults = StakeholderInfo.toStakeholderInfo(this.totalResults, this.user); this._getResults(params); } else { - this.subscriptions.push(this._stakeholderService.getStakeholders(this.properties.monitorServiceAPIURL).subscribe( + this.subscriptions.push(this._stakeholderService.getStakeholders().subscribe( data => { this.totalResults = StakeholderInfo.toStakeholderInfo(data, this.user); this._getResults(params); diff --git a/src/app/subscriptions/subscriptions.component.ts b/src/app/subscriptions/subscriptions.component.ts new file mode 100644 index 0000000..5edda76 --- /dev/null +++ b/src/app/subscriptions/subscriptions.component.ts @@ -0,0 +1,82 @@ +import {Component} from "@angular/core"; +import {Router} from '@angular/router'; +import {Meta, Title} from '@angular/platform-browser'; +import {PiwikService} from '../openaireLibrary/utils/piwik/piwik.service'; +import {SEOService} from "../openaireLibrary/sharedComponents/SEO/SEO.service"; +import {Subscriber} from "rxjs"; +import {Breadcrumb} from "../openaireLibrary/utils/breadcrumbs/breadcrumbs.component"; +import {EnvProperties} from "../openaireLibrary/utils/properties/env-properties"; +import {properties} from "../../environments/environment"; +import {BaseComponent} from "../openaireLibrary/sharedComponents/base/base.component"; +import {HelperService} from "../openaireLibrary/utils/helper/helper.service"; + +@Component({ + selector: 'subscriptions', + template: ` +