From d6488bbfb7a61b15b7020e4b6516371167b41719 Mon Sep 17 00:00:00 2001 From: "k.triantafyllou" Date: Thu, 6 Aug 2020 13:24:02 +0000 Subject: [PATCH] [Admin | Trunk]: Community edit form: Remove show show loading if form is invalid git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-admin-portal/trunk@59229 d315682c-612b-4755-9ff5-7f18f6832af3 --- .../community-edit-form/community-edit-form.component.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/app/pages/community/community-edit-form/community-edit-form.component.ts b/src/app/pages/community/community-edit-form/community-edit-form.component.ts index 9866b44..93229cd 100644 --- a/src/app/pages/community/community-edit-form/community-edit-form.component.ts +++ b/src/app/pages/community/community-edit-form/community-edit-form.component.ts @@ -154,13 +154,12 @@ export class CommunityEditFormComponent implements OnInit{ { 'errorCode': LoginErrorCodes.NOT_VALID, 'redirectUrl': this._router.url} }); } else { if (this.communityId != null && this.communityId !== '') { - this.showLoading = true; const community = this.parseUpdatedCommunity(); if (!Validator.hasValidEmails(community['managers']) || !this.hasFilled(community['name'])) { - this._router.navigate(['/community-edit-form'], { - queryParams: { 'communityId': this.communityId}}); + return; } else { + this.showLoading = true; const newManagers = this.getNewManagers(); this._communityService.updateCommunity( this.properties.communityAPI + this.communityId, community).subscribe(