mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 16:16:04 -04:00
webclient: You can now paginate in rooms. Defaults to 10 messages, with a button to get more (needs to be hooked into infini-scrolling).
This commit is contained in:
parent
fef3183461
commit
30da8c81c7
4 changed files with 74 additions and 21 deletions
|
@ -212,6 +212,17 @@ angular.module('matrixService', [])
|
|||
path = path.replace("$room_id", room_id);
|
||||
return doRequest("GET", path);
|
||||
},
|
||||
|
||||
paginateBackMessages: function(room_id, from_token, limit) {
|
||||
var path = "/rooms/$room_id/messages/list";
|
||||
path = path.replace("$room_id", room_id);
|
||||
var params = {
|
||||
from: from_token,
|
||||
to: "START",
|
||||
limit: limit
|
||||
};
|
||||
return doRequest("GET", path, params);
|
||||
},
|
||||
|
||||
// get a list of public rooms on your home server
|
||||
publicRooms: function() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue