[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
This commit is contained in:
parent
5731b3c952
commit
d6488bbfb7
|
@ -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(
|
||||
|
|
Loading…
Reference in New Issue