mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 05:16:07 +00:00
save
This commit is contained in:
@@ -576,9 +576,16 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
||||
var _this4 = this;
|
||||
|
||||
this.showLoader = true;
|
||||
this.result = this.chatService.getAllDirectMessages().subscribe(function (res) {
|
||||
_this4.userDirectMessages = res.ims;
|
||||
console.log(res);
|
||||
/* this.result = */
|
||||
|
||||
this.chatService.getAllDirectMessages().subscribe(function (res) {
|
||||
console.log(res.ims);
|
||||
_this4.userDirectMessages = res.ims.sort(function (a, b) {
|
||||
var dateA = new Date(a.lastMessage._updatedAt).getTime();
|
||||
var dateB = new Date(b.lastMessage._updatedAt).getTime();
|
||||
return dateB - dateB;
|
||||
});
|
||||
console.log(_this4.userDirectMessages);
|
||||
_this4.showLoader = false;
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user