rpaschoal / ng-chat

💬 A simple facebook/linkedin lookalike chat module for Angular applications.
MIT License
155 stars 92 forks source link

Chat history not loaded on chat window #93

Closed BelvedereHenrique closed 5 years ago

BelvedereHenrique commented 5 years ago

I'm trying to get the chat history to work. I've enable "[historyEnabled]" and "getMessageHistory" is being called properly.

This is my method:

getMessageHistory(userId: any): Observable<Message[]> {
   return this._chatService.getChatHistory(this.userId, userId);

}

"getChatHistory" is working fine, since I'm able to console.log() the messages.

Did I forget something?

Thanks

BelvedereHenrique commented 5 years ago

We've just noticed that the messages divs are being loaded at DOM, no message text though image

BelvedereHenrique commented 5 years ago

Fixed.

The problem was the MessageType. My api was returnig string "Text" instead of int "1";