Revision 55372
Added by Konstantina Galouni about 5 years ago
communities.component.ts | ||
---|---|---|
108 | 108 |
//console.log(communitiesResults); |
109 | 109 |
this.sort(communitiesResults); |
110 | 110 |
|
111 |
var subscribedLoading = communitiesResults.length; |
|
111 | 112 |
var mail = Session.getUserEmail(); |
112 | 113 |
communitiesResults.forEach((community, index) => { |
113 | 114 |
let showCommunity: boolean = true; |
... | ... | |
154 | 155 |
} |
155 | 156 |
} |
156 | 157 |
|
157 |
this.loading = false; |
|
158 |
subscribedLoading--; |
|
159 |
if(subscribedLoading == 0) { |
|
160 |
this.loading = false; |
|
161 |
} |
|
158 | 162 |
}, |
159 | 163 |
error => { |
160 |
this.subscriberErrorMessage = "Error fetching communities you are subscribed to"; |
|
164 |
// if(this.properties.environment == "development") { |
|
165 |
// this.subscriberErrorMessage = "Error fetching communities you are subscribed to"; |
|
166 |
// } |
|
161 | 167 |
this.handleError("Error getting response if email: "+mail+" is subscribed to community with id: "+community.communityId, error); |
162 |
this.loading = false; |
|
168 |
subscribedLoading--; |
|
169 |
if(subscribedLoading == 0) { |
|
170 |
this.loading = false; |
|
171 |
} |
|
163 | 172 |
}); |
164 | 173 |
} else { |
165 |
this.loading = false; |
|
174 |
subscribedLoading--; |
|
175 |
if(subscribedLoading == 0) { |
|
176 |
this.loading = false; |
|
177 |
} |
|
166 | 178 |
} |
167 | 179 |
}); |
168 | 180 |
}, |
Also available in: Unified diff
[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