Revision 60927
Added by Konstantinos Triantafyllou about 3 years ago
invite.component.ts | ||
---|---|---|
171 | 171 |
} |
172 | 172 |
|
173 | 173 |
})); |
174 |
HelperFunctions.scroll(); |
|
175 | 174 |
} |
176 | 175 |
|
177 | 176 |
private getPageContents() { |
... | ... | |
200 | 199 |
this.subs.push(this._emailService.sendEmail(this.properties, this.email).subscribe( |
201 | 200 |
res => { |
202 | 201 |
this.status = this.errorCodes.DONE; |
203 |
//console.log("Emails Sent: ",res); |
|
204 |
/*if(res == 0) { |
|
205 |
|
|
206 |
} else if(res > 1) { |
|
207 |
this.successfulSentMessage = res + " emails sent successfully!"; |
|
208 |
} else { |
|
209 |
this.successfulSentMessage = res + " email sent successfully!"; |
|
210 |
}*/ |
|
211 |
|
|
212 | 202 |
if (res['success']) { |
213 | 203 |
this.successfulSentMessage = "Email sent successfully to: "; |
214 | 204 |
this.successfulSentRecipients = res['success']; |
... | ... | |
240 | 230 |
} |
241 | 231 |
|
242 | 232 |
public isEmpty(data: string): boolean { |
243 |
if (data != undefined && !data.replace(/\s/g, '').length) |
|
244 |
return true; |
|
245 |
else |
|
246 |
return false; |
|
233 |
return data != undefined && !data.replace(/\s/g, '').length; |
|
247 | 234 |
} |
248 | 235 |
|
249 | 236 |
public resetMessages() { |
... | ... | |
284 | 271 |
public composeEmail() { |
285 | 272 |
this.email.body = Composer.formatEmailBodyForInvitation(this.body); |
286 | 273 |
} |
287 |
|
|
288 |
/* |
|
289 |
public handleError(error) { |
|
290 |
if(error.status == '401') { |
|
291 |
this.status = this.errorCodes.FORBIDDEN; |
|
292 |
} else if(error.status == '403') { |
|
293 |
this.status = this.errorCodes.FORBIDDEN; |
|
294 |
} else if(error.status == '404') { |
|
295 |
this.status = this.errorCodes.NOT_FOUND; |
|
296 |
} else if(error.status == '500') { |
|
297 |
this.status = this.errorCodes.ERROR; |
|
298 |
} else { |
|
299 |
this.status = this.errorCodes.NOT_AVAILABLE; |
|
300 |
} |
|
301 |
console.log('Server responded: ' + error); |
|
302 |
} |
|
303 |
*/ |
|
274 |
|
|
304 | 275 |
allowEdit() { |
305 | 276 |
if (!this.user) { |
306 | 277 |
return false; |
Also available in: Unified diff
[Connect | Trunk]: Add smooth scroll service