[Connect|Trunk]: Curators, Affiliation and Invite componenents: On short View, title must not be changed.
git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@56894 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
parent
6e16d55032
commit
5b84ca8adc
|
@ -26,7 +26,7 @@
|
||||||
<div *ngIf="showLoading" class="uk-animation-fade uk-width-1-1" role="alert">
|
<div *ngIf="showLoading" class="uk-animation-fade uk-width-1-1" role="alert">
|
||||||
<span class="loading-gif uk-align-center"></span>
|
<span class="loading-gif uk-align-center"></span>
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="fullView"
|
<div *ngIf="longView"
|
||||||
class="uk-child-width-1-5@l uk-child-width-1-3@m uk-child-width-1-2@s
|
class="uk-child-width-1-5@l uk-child-width-1-3@m uk-child-width-1-2@s
|
||||||
uk-text-center uk-grid-match uk-grid-small uk-grid-margin uk-margin-remove"
|
uk-text-center uk-grid-match uk-grid-small uk-grid-margin uk-margin-remove"
|
||||||
uk-height-match="target: > div > .uk-card > .affiliation-content > .affiliation-logo"
|
uk-height-match="target: > div > .uk-card > .affiliation-content > .affiliation-logo"
|
||||||
|
@ -50,7 +50,7 @@
|
||||||
Related Organizations ({{affiliations.length}})
|
Related Organizations ({{affiliations.length}})
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div *ngIf="!fullView" [class]="'uk-position-relative uk-visible-toggle'" tabindex="-1"
|
<div *ngIf="!longView" [class]="'uk-position-relative uk-visible-toggle'" tabindex="-1"
|
||||||
[attr.uk-slider]="sliderOptions">
|
[attr.uk-slider]="sliderOptions">
|
||||||
<div
|
<div
|
||||||
[class]="'uk-align-center uk-width-'+(affiliations.length >= affiliationsInSlider ? affiliationsInSlider : affiliations.length)+'-'+affiliationsInSlider">
|
[class]="'uk-align-center uk-width-'+(affiliations.length >= affiliationsInSlider ? affiliationsInSlider : affiliations.length)+'-'+affiliationsInSlider">
|
||||||
|
@ -88,6 +88,6 @@
|
||||||
</div>
|
</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
|
||||||
<!--<div *ngIf="affiliations.length == 0 && fullView" class="uk-animation-fade uk-alert uk-alert-primary" role="alert">-->
|
<!--<div *ngIf="affiliations.length == 0 && longView" class="uk-animation-fade uk-alert uk-alert-primary" role="alert">-->
|
||||||
<!-- No affiliations available-->
|
<!-- No affiliations available-->
|
||||||
<!--</div>-->
|
<!--</div>-->
|
||||||
|
|
|
@ -15,7 +15,7 @@ import {PiwikHelper} from "../utils/piwikHelper";
|
||||||
})
|
})
|
||||||
export class AffiliationsComponent {
|
export class AffiliationsComponent {
|
||||||
@Input() getAffiliationsFromAPI: boolean = false;
|
@Input() getAffiliationsFromAPI: boolean = false;
|
||||||
@Input() fullView: boolean = false;
|
@Input() longView: boolean = false;
|
||||||
@Input() communityFirstPage: boolean = false;
|
@Input() communityFirstPage: boolean = false;
|
||||||
@Input() affiliationsInSlider: number = 5;
|
@Input() affiliationsInSlider: number = 5;
|
||||||
@Input() affiliations: Affiliation[] = [];
|
@Input() affiliations: Affiliation[] = [];
|
||||||
|
@ -49,16 +49,16 @@ export class AffiliationsComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
this.properties = data.envSpecific;
|
this.properties = data.envSpecific;
|
||||||
|
if(this.longView) {
|
||||||
if (this.properties.enablePiwikTrack && (typeof document !== 'undefined')) {
|
if (this.properties.enablePiwikTrack && (typeof document !== 'undefined')) {
|
||||||
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, PiwikHelper.getSiteId(this.communityId,this.properties.environment)).subscribe();
|
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, PiwikHelper.getSiteId(this.communityId, this.properties.environment)).subscribe();
|
||||||
|
}
|
||||||
|
this.url = this.properties.baseLink + this._router.url;
|
||||||
|
this.seoService.createLinkForCanonicalURL(this.url);
|
||||||
|
this.updateUrl(this.url);
|
||||||
|
this.updateTitle(this.pageTitle);
|
||||||
|
this.updateDescription("OpenAIRE - Connect, Community Gateway, research community, organizations");
|
||||||
}
|
}
|
||||||
this.url = this.properties.baseLink + this._router.url;
|
|
||||||
this.seoService.createLinkForCanonicalURL(this.url);
|
|
||||||
this.updateUrl(this.url);
|
|
||||||
this.updateTitle(this.pageTitle);
|
|
||||||
this.updateDescription("OpenAIRE - Connect, Community Gateway, research community, organizations");
|
|
||||||
|
|
||||||
if(this.getAffiliationsFromAPI) {
|
if(this.getAffiliationsFromAPI) {
|
||||||
this.showLoading = true;
|
this.showLoading = true;
|
||||||
this.affiliationService.initAffiliations(this.properties, this.properties.communityAPI + this.communityId + "/organizations");
|
this.affiliationService.initAffiliations(this.properties, this.properties.communityAPI + this.communityId + "/organizations");
|
||||||
|
|
|
@ -521,7 +521,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="isRouteEnabled('/curators')" class="uk-width-3-5@m uk-width-1-1@s uk-margin-top">
|
<div *ngIf="isRouteEnabled('/curators')" class="uk-width-3-5@m uk-width-1-1@s uk-margin-top">
|
||||||
<curators [main]="false" [managers]="community.managers" [communityId]="communityId"></curators>
|
<curators [longView]="false" [managers]="community.managers" [communityId]="communityId"></curators>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -532,7 +532,7 @@
|
||||||
<ng-container *ngIf=" isRouteEnabled('/organizations')">
|
<ng-container *ngIf=" isRouteEnabled('/organizations')">
|
||||||
<div class="uk-container uk-margin-bottom uk-grid">
|
<div class="uk-container uk-margin-bottom uk-grid">
|
||||||
<div class="uk-width-expand uk-padding-remove">
|
<div class="uk-width-expand uk-padding-remove">
|
||||||
<affiliations [fullView]="false" [getAffiliationsFromAPI]="true" [communityFirstPage]="true"></affiliations>
|
<affiliations [longView]="false" [getAffiliationsFromAPI]="true" [communityFirstPage]="true"></affiliations>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<schema2jsonld *ngIf="url" [URL]="url" [name]="pageTitle" type="other"></schema2jsonld>
|
<schema2jsonld *ngIf="url" [URL]="url" [name]="pageTitle" type="other"></schema2jsonld>
|
||||||
|
|
||||||
<ng-container *ngIf="main else child">
|
<ng-container *ngIf="longView else shortView">
|
||||||
<div class="image-front-topbar uk-section-default uk-position-relative"
|
<div class="image-front-topbar uk-section-default uk-position-relative"
|
||||||
uk-scrollspy="{"target":"[uk-scrollspy-class]","cls":"uk-animation-fade","delay":false}"
|
uk-scrollspy="{"target":"[uk-scrollspy-class]","cls":"uk-animation-fade","delay":false}"
|
||||||
tm-header-transparent="light">
|
tm-header-transparent="light">
|
||||||
|
@ -46,7 +46,7 @@
|
||||||
<div class="uk-width-expand uk-margin-left uk-text-meta uk-flex-first">
|
<div class="uk-width-expand uk-margin-left uk-text-meta uk-flex-first">
|
||||||
Affiliations
|
Affiliations
|
||||||
</div>
|
</div>
|
||||||
<affiliations [fullView]="false" [affiliations]="curator.affiliations"
|
<affiliations [longView]="false" [affiliations]="curator.affiliations"
|
||||||
[affiliationsInSlider]="curator.affiliations.length"
|
[affiliationsInSlider]="curator.affiliations.length"
|
||||||
class="uk-width-2-3"></affiliations>
|
class="uk-width-2-3"></affiliations>
|
||||||
</div>
|
</div>
|
||||||
|
@ -56,7 +56,7 @@
|
||||||
<div class="uk-text-meta uk-margin-small-bottom">
|
<div class="uk-text-meta uk-margin-small-bottom">
|
||||||
Affiliations
|
Affiliations
|
||||||
</div>
|
</div>
|
||||||
<affiliations [fullView]="false" [affiliations]="curator.affiliations"></affiliations>
|
<affiliations [longView]="false" [affiliations]="curator.affiliations"></affiliations>
|
||||||
</div>
|
</div>
|
||||||
<div class="uk-width-1-1 uk-first-column uk-margin-top uk-height-max-large uk-overflow-auto">
|
<div class="uk-width-1-1 uk-first-column uk-margin-top uk-height-max-large uk-overflow-auto">
|
||||||
<div class="uk-text-meta uk-margin-small-bottom">
|
<div class="uk-text-meta uk-margin-small-bottom">
|
||||||
|
@ -88,7 +88,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ng-template #child>
|
<ng-template #shortView>
|
||||||
<span *ngIf=" curators && curators.length > 0" class="lowOpacityColor uk-width-1-1">
|
<span *ngIf=" curators && curators.length > 0" class="lowOpacityColor uk-width-1-1">
|
||||||
Curators
|
Curators
|
||||||
</span>
|
</span>
|
||||||
|
|
|
@ -21,7 +21,7 @@ import {PiwikHelper} from "../utils/piwikHelper";
|
||||||
export class CuratorsComponent {
|
export class CuratorsComponent {
|
||||||
@Input() managers: string[];
|
@Input() managers: string[];
|
||||||
@Input() communityId = null;
|
@Input() communityId = null;
|
||||||
@Input() main = true;
|
@Input() longView = true;
|
||||||
public downloadUrl = null;
|
public downloadUrl = null;
|
||||||
public showLoading = true;
|
public showLoading = true;
|
||||||
|
|
||||||
|
@ -52,18 +52,18 @@ export class CuratorsComponent {
|
||||||
this.route.data.subscribe((data: { envSpecific: EnvProperties }) => {
|
this.route.data.subscribe((data: { envSpecific: EnvProperties }) => {
|
||||||
this.showLoading = true;
|
this.showLoading = true;
|
||||||
this.properties = data.envSpecific;
|
this.properties = data.envSpecific;
|
||||||
|
if(this.longView) {
|
||||||
if (this.properties.enablePiwikTrack && (typeof document !== 'undefined')) {
|
if (this.properties.enablePiwikTrack && (typeof document !== 'undefined')) {
|
||||||
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, PiwikHelper.getSiteId(this.communityId,this.properties.environment)).subscribe();
|
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, PiwikHelper.getSiteId(this.communityId, this.properties.environment)).subscribe();
|
||||||
|
}
|
||||||
|
this.url = this.properties.baseLink + this._router.url;
|
||||||
|
this.seoService.createLinkForCanonicalURL(this.url);
|
||||||
|
this.updateUrl(this.url);
|
||||||
|
this.updateTitle(this.pageTitle);
|
||||||
|
this.updateDescription("OpenAIRE - Connect, Community Gateway, research community");
|
||||||
}
|
}
|
||||||
this.url = this.properties.baseLink + this._router.url;
|
|
||||||
this.seoService.createLinkForCanonicalURL(this.url);
|
|
||||||
this.updateUrl(this.url);
|
|
||||||
this.updateTitle(this.pageTitle);
|
|
||||||
this.updateDescription("OpenAIRE - Connect, Community Gateway, research community");
|
|
||||||
|
|
||||||
this.downloadUrl = this.properties.utilsService + '/download/';
|
this.downloadUrl = this.properties.utilsService + '/download/';
|
||||||
if(!this.main) {
|
if(!this.longView) {
|
||||||
let emails = this.managers.join();
|
let emails = this.managers.join();
|
||||||
this.curatorsService.getCurators(this.properties,
|
this.curatorsService.getCurators(this.properties,
|
||||||
this.properties.adminToolsAPIURL + '/curator?emails=' + emails).subscribe(curators => {
|
this.properties.adminToolsAPIURL + '/curator?emails=' + emails).subscribe(curators => {
|
||||||
|
|
|
@ -10,12 +10,14 @@ import {ConnectHelper} from "../../openaireLibrary/connect/connectHelper";
|
||||||
template: `
|
template: `
|
||||||
<div class=" uk-section tm-middle uk-container uk-padding-remove-top uk-margin-top" id="tm-main">
|
<div class=" uk-section tm-middle uk-container uk-padding-remove-top uk-margin-top" id="tm-main">
|
||||||
<div class="uk-container uk-margin-bottom">
|
<div class="uk-container uk-margin-bottom">
|
||||||
<div class="uk-article-title custom-article-title uk-margin-bottom"> Organizations related to the community</div>
|
<div class="uk-article-title custom-article-title uk-margin-bottom"> Organizations related to the community
|
||||||
<helper *ngIf="pageContents && pageContents['top'] && pageContents['top'].length > 0" [texts]="pageContents['top']"></helper>
|
</div>
|
||||||
<affiliations [fullView]="true" [getAffiliationsFromAPI]="true"></affiliations>
|
<helper *ngIf="pageContents && pageContents['top'] && pageContents['top'].length > 0"
|
||||||
|
[texts]="pageContents['top']"></helper>
|
||||||
|
<affiliations [longView]="true" [getAffiliationsFromAPI]="true"></affiliations>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
`
|
`
|
||||||
})
|
})
|
||||||
export class OrganizationsPageComponent {
|
export class OrganizationsPageComponent {
|
||||||
properties:EnvProperties;
|
properties:EnvProperties;
|
||||||
|
|
|
@ -100,15 +100,16 @@ export class InviteComponent implements OnInit {
|
||||||
this.communityId = communityId['communityId'];
|
this.communityId = communityId['communityId'];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.properties.enablePiwikTrack && (typeof document !== 'undefined')) {
|
if(this.longView) {
|
||||||
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, PiwikHelper.getSiteId(this.communityId,this.properties.environment)).subscribe();
|
if (this.properties.enablePiwikTrack && (typeof document !== 'undefined')) {
|
||||||
|
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, PiwikHelper.getSiteId(this.communityId, this.properties.environment)).subscribe();
|
||||||
|
}
|
||||||
|
this.url = this.properties.baseLink + this._router.url;
|
||||||
|
this.seoService.createLinkForCanonicalURL(this.url);
|
||||||
|
this.updateUrl(this.url);
|
||||||
|
this.updateTitle(this.pageTitle);
|
||||||
|
this.updateDescription("OpenAIRE - Connect, Community Gateway, research community, invite");
|
||||||
}
|
}
|
||||||
this.url = this.properties.baseLink + this._router.url;
|
|
||||||
this.seoService.createLinkForCanonicalURL(this.url);
|
|
||||||
this.updateUrl(this.url);
|
|
||||||
this.updateTitle(this.pageTitle);
|
|
||||||
this.updateDescription("OpenAIRE - Connect, Community Gateway, research community, invite");
|
|
||||||
|
|
||||||
this.communityIdParam = (this.properties.environment != "development") ? {} : {communityId: this.communityId};
|
this.communityIdParam = (this.properties.environment != "development") ? {} : {communityId: this.communityId};
|
||||||
if (this.communityId != null && this.communityId != '') {
|
if (this.communityId != null && this.communityId != '') {
|
||||||
//this.getDivContents();
|
//this.getDivContents();
|
||||||
|
|
Loading…
Reference in New Issue