[umbrella | DONE]: Merge from develop
This commit is contained in:
commit
b75938eb10
|
@ -9,6 +9,10 @@ import {HelperFunctions} from "../openaireLibrary/utils/HelperFunctions.class";
|
|||
loadChildren: () => import('../openaireLibrary/monitor-admin/general/general.module').then(m => m.GeneralModule),
|
||||
pathMatch: 'full'
|
||||
},
|
||||
{
|
||||
path: 'users/links',
|
||||
loadChildren: () => import('../claims/claimsAdmin/claimsAdmin.module').then(m => m.LibClaimsAdminModule), pathMatch: 'full', data: {param: 'stakeholder', parentClass: 'monitor'}
|
||||
},
|
||||
{
|
||||
path: 'users',
|
||||
redirectTo: 'users/manager',
|
||||
|
@ -29,6 +33,11 @@ import {HelperFunctions} from "../openaireLibrary/utils/HelperFunctions.class";
|
|||
path: 'admin-tools',
|
||||
loadChildren: () => import('../admin-tools/admin-tools-routing.module').then(m => m.AdminToolsRoutingModule),
|
||||
data: {param: 'stakeholder', parentClass: 'monitor'}
|
||||
},
|
||||
{
|
||||
path: 'claims/link',
|
||||
loadChildren: () => import('../claims/directLinking/directLinking.module').then(m => m.LibDirectLinkingModule),
|
||||
data: {param: 'stakeholder', parentClass: 'monitor'}
|
||||
}
|
||||
])]
|
||||
})
|
||||
|
|
|
@ -322,6 +322,9 @@ export class AppComponent extends SidebarBaseComponent implements OnInit {
|
|||
if (this.isCurator()) {
|
||||
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"));
|
||||
}
|
||||
if(this.stakeholder.type == "organization") {
|
||||
this.adminMenuItems.push(new MenuItem("claim", "Link results", "", "/admin/" + this.stakeholder.alias + "/claims/link", false, [], [], {}, {name: 'link'}, null, "uk-visible@m", "/admin/" + this.stakeholder.alias + "/claims/link"));
|
||||
}
|
||||
}
|
||||
this.backItem = new MenuItem("back", "Manage profiles", "", "/admin", false, [], null, {}, {name: 'west'});
|
||||
this.sideBarItems = items;
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
import {NgModule} from '@angular/core';
|
||||
import {RouterModule} from '@angular/router';
|
||||
import {OpenaireClaimsAdminComponent} from './claimsAdmin.component';
|
||||
import {PreviousRouteRecorder} from '../../openaireLibrary/utils/piwik/previousRouteRecorder.guard';
|
||||
import {properties} from "../../../environments/environment";
|
||||
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
RouterModule.forChild([
|
||||
{ path: '', component: OpenaireClaimsAdminComponent, data: {
|
||||
redirect: properties.errorLink
|
||||
}, canDeactivate: [PreviousRouteRecorder]},
|
||||
|
||||
])
|
||||
]
|
||||
})
|
||||
export class ClaimsAdminRoutingModule { }
|
|
@ -0,0 +1,46 @@
|
|||
import {Component, OnInit} from '@angular/core';
|
||||
import {properties} from "../../../environments/environment";
|
||||
import {ActivatedRoute} from "@angular/router";
|
||||
import {StakeholderService} from "../../openaireLibrary/monitor/services/stakeholder.service";
|
||||
import {Title} from "@angular/platform-browser";
|
||||
|
||||
@Component({
|
||||
selector: 'openaire-claims-admin',
|
||||
template: `
|
||||
<div page-content>
|
||||
<div header>
|
||||
<ul class="uk-tab uk-margin-remove-bottom uk-margin-medium-top">
|
||||
<li><a routerLink="../../users/manager">Managers</a></li>
|
||||
<li ><a routerLink="../../users/member">Members</a></li>
|
||||
<li class="uk-active"><a >Links</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div inner>
|
||||
|
||||
<claims-admin *ngIf="claimsInfoURL" [claimsInfoURL]="claimsInfoURL" fetchBy="Organization"
|
||||
[fetchId]="fetchId" [isConnect]="true">
|
||||
</claims-admin>
|
||||
</div>
|
||||
</div>
|
||||
`,
|
||||
})
|
||||
export class OpenaireClaimsAdminComponent implements OnInit {
|
||||
claimsInfoURL: string;
|
||||
userInfoURL: string;
|
||||
subscriptions = []
|
||||
fetchId = null
|
||||
constructor( private route: ActivatedRoute, private stakeholderService: StakeholderService, private title: Title) {
|
||||
}
|
||||
|
||||
public ngOnInit() {
|
||||
this.claimsInfoURL = properties.claimsInformationLink;
|
||||
if(this.route.snapshot.data.param === 'stakeholder') {
|
||||
this.subscriptions.push(this.stakeholderService.getStakeholderAsObservable().subscribe(stakeholder => {
|
||||
if(stakeholder) {
|
||||
this.fetchId = stakeholder.index_id;
|
||||
this.title.setTitle(stakeholder.name + ' | Manage claims');
|
||||
}
|
||||
}));
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
import { NgModule } from '@angular/core';
|
||||
|
||||
import { SharedModule } from '../../openaireLibrary/shared/shared.module';
|
||||
import { OpenaireClaimsAdminComponent } from './claimsAdmin.component';
|
||||
import { ClaimsAdminRoutingModule } from './claimsAdmin-routing.module';
|
||||
import{ClaimsAdminModule } from '../../openaireLibrary/claims/claimsAdmin/claimsAdmin.module';
|
||||
import{ ClaimsCuratorGuard} from '../../openaireLibrary/login/claimsCuratorGuard.guard';
|
||||
import {PreviousRouteRecorder} from '../../openaireLibrary/utils/piwik/previousRouteRecorder.guard';
|
||||
import {IsRouteEnabled} from '../../openaireLibrary/error/isRouteEnabled.guard';
|
||||
import {PageContentModule} from "../../openaireLibrary/dashboard/sharedComponents/page-content/page-content.module";
|
||||
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
SharedModule,
|
||||
ClaimsAdminRoutingModule,
|
||||
ClaimsAdminModule,
|
||||
PageContentModule
|
||||
],
|
||||
providers:[ClaimsCuratorGuard, PreviousRouteRecorder,IsRouteEnabled],
|
||||
declarations: [
|
||||
OpenaireClaimsAdminComponent
|
||||
]
|
||||
})
|
||||
export class LibClaimsAdminModule { }
|
|
@ -0,0 +1,19 @@
|
|||
import {NgModule} from '@angular/core';
|
||||
import {RouterModule} from '@angular/router';
|
||||
|
||||
import {OpenaireDirectLinkingComponent} from './directLinking.component';
|
||||
import {PreviousRouteRecorder} from '../../openaireLibrary/utils/piwik/previousRouteRecorder.guard';
|
||||
import {properties} from "../../../environments/environment";
|
||||
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
RouterModule.forChild([
|
||||
{ path: '', component: OpenaireDirectLinkingComponent, data: {
|
||||
redirect: properties.errorLink, community : 'openaire'
|
||||
}, canDeactivate: [PreviousRouteRecorder]},
|
||||
|
||||
])
|
||||
]
|
||||
})
|
||||
export class DirectLinkingRoutingModule { }
|
|
@ -0,0 +1,46 @@
|
|||
import {Component, Input} from '@angular/core';
|
||||
import {ActivatedRoute} from "@angular/router";
|
||||
import {StakeholderService} from "../../openaireLibrary/monitor/services/stakeholder.service";
|
||||
import {Title} from "@angular/platform-browser";
|
||||
import {MonitorClaimsProperties} from "../monitorClaims.properties";
|
||||
|
||||
@Component({
|
||||
selector: 'openaire-directLinking',
|
||||
template: `
|
||||
<div page-content>
|
||||
<div header>
|
||||
<!-- <users-tabs tab="claims"></users-tabs>-->
|
||||
</div>
|
||||
<div inner>
|
||||
<directLinking *ngIf="claimsProperties" [organizationClaim]="true" [communityId]="alias" [id]="id" [claimsProperties]="claimsProperties" ></directLinking>
|
||||
</div>
|
||||
</div>
|
||||
`
|
||||
})
|
||||
export class OpenaireDirectLinkingComponent {
|
||||
id;
|
||||
alias;
|
||||
subscriptions = [];
|
||||
claimsProperties;
|
||||
|
||||
|
||||
constructor(private route: ActivatedRoute, private stakeholderService: StakeholderService, private title: Title) {
|
||||
this.claimsProperties = new MonitorClaimsProperties();
|
||||
|
||||
console.log(this.claimsProperties)
|
||||
}
|
||||
|
||||
public ngOnInit() {
|
||||
if (this.route.snapshot.data.param === 'stakeholder') {
|
||||
this.subscriptions.push(this.stakeholderService.getStakeholderAsObservable().subscribe(stakeholder => {
|
||||
if (stakeholder) {
|
||||
this.alias = stakeholder.alias;
|
||||
this.id = stakeholder.index_id;
|
||||
this.title.setTitle(stakeholder.name + ' | Claim Organization');
|
||||
}
|
||||
}));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
import { NgModule } from '@angular/core';
|
||||
|
||||
import { SharedModule } from '../../openaireLibrary/shared/shared.module';
|
||||
import { OpenaireDirectLinkingComponent } from './directLinking.component';
|
||||
import{ DirectLinkingModule} from '../../openaireLibrary/claims/directLinking/directLinking.module';
|
||||
import {DirectLinkingRoutingModule} from './directLinking-routing.module';
|
||||
import {LoginGuard} from '../../openaireLibrary/login/loginGuard.guard';
|
||||
import {PreviousRouteRecorder} from '../../openaireLibrary/utils/piwik/previousRouteRecorder.guard';
|
||||
import {IsRouteEnabled} from '../../openaireLibrary/error/isRouteEnabled.guard';
|
||||
import {PageContentModule} from "../../openaireLibrary/dashboard/sharedComponents/page-content/page-content.module";
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
SharedModule, DirectLinkingModule, DirectLinkingRoutingModule, PageContentModule
|
||||
],
|
||||
providers:[LoginGuard, PreviousRouteRecorder, IsRouteEnabled],
|
||||
declarations: [
|
||||
OpenaireDirectLinkingComponent
|
||||
], exports:[OpenaireDirectLinkingComponent]
|
||||
})
|
||||
export class LibDirectLinkingModule { }
|
|
@ -0,0 +1,14 @@
|
|||
import {ClaimsProperties} from "../openaireLibrary/claims/claim-utils/claims.properties";
|
||||
|
||||
export class MonitorClaimsProperties extends ClaimsProperties{
|
||||
constructor() {
|
||||
super();
|
||||
this.ALLOW_ORGANIZATION_LINKING = true;
|
||||
this.INLINE_ENTITY.show = false;
|
||||
this.INLINE_ENTITY.guideText = "Lorem ipsum";
|
||||
this.BASKET.target_title = "Link to";
|
||||
this.METADATA_PREVIEW.edit_target_icon = "west";
|
||||
this.METADATA_PREVIEW.edit_target_title = "Go to search for results"
|
||||
|
||||
}
|
||||
}
|
|
@ -185,19 +185,6 @@
|
|||
<h6 class="uk-margin-bottom chartTitle uk-flex uk-flex-bottom">
|
||||
{{indicator.name + " "}}
|
||||
</h6>
|
||||
<div *ngIf="indicator.indicatorPaths.length > 1" class="uk-button-group">
|
||||
<ul class="uk-subnav uk-subnav-pill uk-subnav-small">
|
||||
<li *ngFor="let indicatorPath of indicator.indicatorPaths; let i=index"
|
||||
class="uk-flex uk-margin-small-top"
|
||||
[class.uk-active]="(!indicator.activePath && i == 0) || indicator.activePath === i">
|
||||
<a (click)="indicator.activePath = i">
|
||||
<span>
|
||||
{{indicatorPath.parameters.title ? indicatorPath.parameters.title : '--' }}
|
||||
</span>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<iframe [class.uk-blend-multiply]="!isFullscreen"
|
||||
*ngIf=" !properties.disableFrameLoad && getActiveIndicatorPath(indicator).source !== 'image'"
|
||||
[src]="getActiveIndicatorPath(indicator).safeResourceUrl"
|
||||
|
@ -212,6 +199,13 @@
|
|||
[src]="getActiveIndicatorPath(indicator).safeResourceUrl"
|
||||
class="uk-width-1-1 uk-blend-multiply"
|
||||
[ngClass]="'uk-height-' + (indicator.height?indicator.height.toLowerCase():'medium')">
|
||||
<slider-tabs *ngIf="indicator.indicatorPaths.length > 1" [type]="'dynamic'" [flexPosition]="'right'" (activeEmitter)="indicator.activePath = $event"
|
||||
tabsClass="uk-subnav uk-subnav-pill uk-subnav-small" containerClass="uk-margin-top uk-margin-bottom" [border]="false">
|
||||
<slider-tab *ngFor="let indicatorPath of indicator.indicatorPaths; let i=index"
|
||||
[tabTitle]="indicatorPath.parameters.tab ? indicatorPath.parameters.tab : indicatorPath.parameters.title"
|
||||
[tabId]="i" [active]="(!indicator.activePath && i == 0) || indicator.activePath == i">
|
||||
</slider-tab>
|
||||
</slider-tabs>
|
||||
</div>
|
||||
<div class="uk-position-bottom-left uk-margin-left uk-margin-small-bottom uk-visible@m">
|
||||
<a *ngIf="indicator.description || indicator.additionalDescription"
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 18a415a535e503d75b096be5ee1df80f0bbc80a6
|
||||
Subproject commit 952054f4b4c63ae7a0a0ceaeba0b05dc4e529c99
|
|
@ -8,6 +8,7 @@
|
|||
<ul class="uk-tab uk-margin-remove-bottom uk-margin-medium-top">
|
||||
<li [class.uk-active]="tab === 'manager'"><a routerLink="../manager">Managers</a></li>
|
||||
<li [class.uk-active]="tab === 'member'"><a routerLink="../member">Members</a></li>
|
||||
<li ><a routerLink="../links">Links</a></li>
|
||||
</ul>
|
||||
</role-users>
|
||||
|
||||
|
|
|
@ -12,7 +12,9 @@ let props: EnvProperties = {
|
|||
adminToolsCommunity: "monitor",
|
||||
useHelpTexts:true,
|
||||
baseLink: "/dashboard",
|
||||
domain: "https://beta.monitor.openaire.eu"
|
||||
domain: "https://beta.monitor.openaire.eu",
|
||||
myClaimsLink: "../../users/links"
|
||||
|
||||
};
|
||||
|
||||
export let properties: EnvProperties = {
|
||||
|
|
|
@ -12,7 +12,9 @@ let props: EnvProperties = {
|
|||
adminToolsCommunity: "monitor",
|
||||
useHelpTexts: true,
|
||||
baseLink: "/dashboard",
|
||||
domain: "https://monitor.openaire.eu"
|
||||
domain: "https://monitor.openaire.eu",
|
||||
myClaimsLink: "../../users/links"
|
||||
|
||||
};
|
||||
|
||||
export let properties: EnvProperties = {
|
||||
|
|
|
@ -20,7 +20,7 @@ let props: EnvProperties = {
|
|||
useHelpTexts: true,
|
||||
baseLink: "/",
|
||||
domain: "http://mpagasas.di.uoa.gr:4600",
|
||||
monitorServiceAPIURL: "http://mpagasas.di.uoa.gr:8888/"
|
||||
myClaimsLink: "../../users/links"
|
||||
};
|
||||
|
||||
export let properties: EnvProperties = {
|
||||
|
|
|
@ -7,5 +7,6 @@
|
|||
@import "~src/assets/common-assets/less/dashboard";
|
||||
@import "~src/assets/common-assets/less/indicators";
|
||||
@import "~src/assets/common-assets/less/ckeditor";
|
||||
@import "~src/assets/common-assets/less/linking";
|
||||
@import "~src/assets/monitor-dashboard-custom";
|
||||
@import "assets/print.css";
|
||||
|
|
Loading…
Reference in New Issue