mirror of
https://github.com/pierre42100/ComunicWeb
synced 2024-11-25 21:39:21 +00:00
Can query the server to refresh only a single conversation.
This commit is contained in:
parent
92c7c80fbc
commit
7a473d1aa8
@ -343,6 +343,26 @@ ComunicWeb.components.conversations.interface = {
|
||||
ComunicWeb.common.api.makeAPIrequest(apiURI, params, true, callback);
|
||||
},
|
||||
|
||||
/**
|
||||
* Get the the lastest messages of a single conversation
|
||||
*
|
||||
* @param {Number} convID Target conversation ID
|
||||
* @param {Number} lastMessageID The ID of the last known message
|
||||
* @param {function} callback
|
||||
*/
|
||||
refreshSingleConversation: function(convID, lastMessageID, callback){
|
||||
|
||||
//Perform a request on the API
|
||||
var apiURI = "conversations/refresh_single";
|
||||
var params = {
|
||||
conversationID: convID,
|
||||
last_message_id: lastMessageID
|
||||
};
|
||||
|
||||
ComunicWeb.common.api.makeAPIrequest(apiURI, params, true, callback);
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* Empty conversations cache
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user