From cc5d3cbdb343690afeb99d8ae52adc1f903cd7b1 Mon Sep 17 00:00:00 2001 From: "k.triantafyllou" Date: Wed, 11 Oct 2023 12:55:11 +0300 Subject: [PATCH] Enable invite button for byInvitation commmunities with a link to admin portal. --- src/app/app.component.ts | 2 +- src/app/utils/subscribe/invite/invite.component.html | 6 +++++- src/app/utils/subscribe/invite/invite.component.ts | 9 +++++++-- src/assets/community.less | 2 +- 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/src/app/app.component.ts b/src/app/app.component.ts index c3ef039..dbdd84b 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -89,7 +89,7 @@ import {LayoutService} from "./openaireLibrary/dashboard/sharedComponents/sideba
- +
diff --git a/src/app/utils/subscribe/invite/invite.component.html b/src/app/utils/subscribe/invite/invite.component.html index e9bb6dd..c9632b2 100644 --- a/src/app/utils/subscribe/invite/invite.component.html +++ b/src/app/utils/subscribe/invite/invite.component.html @@ -30,8 +30,12 @@ diff --git a/src/app/utils/subscribe/invite/invite.component.ts b/src/app/utils/subscribe/invite/invite.component.ts index 935715f..c27780e 100644 --- a/src/app/utils/subscribe/invite/invite.component.ts +++ b/src/app/utils/subscribe/invite/invite.component.ts @@ -21,6 +21,7 @@ declare var UIkit; export class InviteComponent implements OnInit { @Input() longView: boolean = true; @Input() communityId = null; + @Input() isOpen: boolean = true; public properties: EnvProperties = properties; public pageTitle: string = "Invite"; public user: User; @@ -44,9 +45,9 @@ export class InviteComponent implements OnInit { user => { this.user = user; })); - this.getPageContents(); - this.url = this.properties.domain + this._router.url; if(this.longView) { + this.url = this.properties.domain + this._router.url; + this.getPageContents(); this.seoService.createLinkForCanonicalURL(this.url); this.updateUrl(this.url); this.updateTitle(this.pageTitle); @@ -88,6 +89,10 @@ export class InviteComponent implements OnInit { private updateUrl(url: string) { this._meta.updateTag({content: url}, "property='og:url'"); } + + get adminInviteURL() { + return this.properties.adminPortalURL + '/' + this.communityId + '/users/member'; + } close(element) { UIkit.dropdown(element).hide(); diff --git a/src/assets/community.less b/src/assets/community.less index 5a6b8da..adebe47 100644 --- a/src/assets/community.less +++ b/src/assets/community.less @@ -20,7 +20,7 @@ #joinAndInviteBtn #join, #joinAndInviteBtn #member, #joinAndInviteBtn #invite { - width: 140px; + width: 160px; line-height: 60px; height: 60px; padding: 0 20px;