mirror of
https://github.com/discourse/discourse.git
synced 2025-01-31 13:31:03 +08:00
FIX: use actions in user_stream_view.js
This commit is contained in:
parent
c8bc9bd5db
commit
6ea257d0b1
|
@ -12,14 +12,16 @@ Discourse.UserStreamView = Discourse.View.extend(Discourse.LoadMore, {
|
|||
eyelineSelector: '.user-stream .item',
|
||||
classNames: ['user-stream'],
|
||||
|
||||
loadMore: function() {
|
||||
var userStreamView = this;
|
||||
if (userStreamView.get('loading')) { return; }
|
||||
actions: {
|
||||
loadMore: function() {
|
||||
var userStreamView = this;
|
||||
if (userStreamView.get('loading')) { return; }
|
||||
|
||||
var stream = this.get('controller.model');
|
||||
stream.findItems().then(function() {
|
||||
userStreamView.set('loading', false);
|
||||
userStreamView.get('eyeline').flushRest();
|
||||
});
|
||||
var stream = this.get('controller.model');
|
||||
stream.findItems().then(function() {
|
||||
userStreamView.set('loading', false);
|
||||
userStreamView.get('eyeline').flushRest();
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue
Block a user