[Trunk|Library]:

communities.component: Error message for fetching subscribed info only for development (now commented)
	bug fix in setting 'loading' (set it when checking all communities for subscription
	align search-form to left with input variable 'setFormCentered'
	use class 'uk-text-bold' instead of <b> tags


git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@55372 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
konstantina.galouni 2019-04-16 10:31:30 +00:00
parent 315991cd36
commit 8d47d1c992
2 changed files with 19 additions and 7 deletions

View File

@ -95,8 +95,8 @@
<h3>Search, share, link results of your research community</h3>
</div>
<div class="uk-container">
<h5 class=" uk-width-expand uk-margin-remove-bottom"><b>Start by locating your community</b></h5>
<search-form class="uk-align-left" placeholderText="Start by locating your community" link="/search/find/communities"></search-form>
<h5 class=" uk-width-expand uk-margin-remove-bottom uk-text-bold">Start by locating your community</h5>
<search-form [setFormCentered]=false placeholderText="Start by locating your community" link="/search/find/communities"></search-form>
</div>
<div class="uk-container">
@ -104,7 +104,7 @@
</div>
<div *ngIf= "researchCommunities.length > 0" class="uk-container uk-margin-medium-top">
<h5 class="uk-width-expand"><b>Browse Research Communities</b></h5>
<h5 class="uk-width-expand uk-text-bold">Browse Research Communities</h5>
<div [class]="'uk-container uk-margin-top' + (researchCommunities.length <= 5 ? ' uk-margin-medium-bottom' : '')">
<div class="uk-grid-match uk-grid-small uk-child-width-1-5@m uk-child-width-1-2@s uk-child-width-1-1@xs uk-text-center" uk-grid uk-height-match=".community-main">

View File

@ -108,6 +108,7 @@ export class CommunitiesComponent {
//console.log(communitiesResults);
this.sort(communitiesResults);
var subscribedLoading = communitiesResults.length;
var mail = Session.getUserEmail();
communitiesResults.forEach((community, index) => {
let showCommunity: boolean = true;
@ -154,16 +155,27 @@ export class CommunitiesComponent {
}
}
subscribedLoading--;
if(subscribedLoading == 0) {
this.loading = false;
}
},
error => {
this.subscriberErrorMessage = "Error fetching communities you are subscribed to";
// if(this.properties.environment == "development") {
// this.subscriberErrorMessage = "Error fetching communities you are subscribed to";
// }
this.handleError("Error getting response if email: "+mail+" is subscribed to community with id: "+community.communityId, error);
subscribedLoading--;
if(subscribedLoading == 0) {
this.loading = false;
}
});
} else {
subscribedLoading--;
if(subscribedLoading == 0) {
this.loading = false;
}
}
});
},
error => {