mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-14 18:52:05 +03:00
ba80e6ebaa
closes #5434 - remove transition away from team page to user page of authors - hide invite button from authors - hide invited users from authors - adjusted gh-user-can and renamed to gh-user-can-admin - hide password reset on owners profile from administrators - hide input field for owner email from administrators pending api fix - fix up tests
44 lines
1.1 KiB
JavaScript
44 lines
1.1 KiB
JavaScript
import AuthenticatedRoute from 'ghost/routes/authenticated';
|
|
import CurrentUserSettings from 'ghost/mixins/current-user-settings';
|
|
import PaginationRouteMixin from 'ghost/mixins/pagination-route';
|
|
import styleBody from 'ghost/mixins/style-body';
|
|
|
|
var paginationSettings;
|
|
|
|
paginationSettings = {
|
|
page: 1,
|
|
limit: 20,
|
|
status: 'active'
|
|
};
|
|
|
|
export default AuthenticatedRoute.extend(styleBody, CurrentUserSettings, PaginationRouteMixin, {
|
|
titleToken: 'Team',
|
|
|
|
classNames: ['view-team'],
|
|
|
|
setupController: function (controller, model) {
|
|
this._super(controller, model);
|
|
this.setupPagination(paginationSettings);
|
|
},
|
|
|
|
beforeModel: function (transition) {
|
|
this._super(transition);
|
|
},
|
|
|
|
model: function () {
|
|
var self = this;
|
|
|
|
return self.store.find('user', {limit: 'all', status: 'invited'}).then(function () {
|
|
return self.store.filter('user', paginationSettings, function () {
|
|
return true;
|
|
});
|
|
});
|
|
},
|
|
|
|
actions: {
|
|
reload: function () {
|
|
this.refresh();
|
|
}
|
|
}
|
|
});
|