3ad2115b40
refs #5315 - split setup into 3 screens - add gravatar fetching - add download counter - add button handling for invite users
25 lines
654 B
JavaScript
25 lines
654 B
JavaScript
import Ember from 'ember';
|
|
import ajax from 'ghost/utils/ajax';
|
|
|
|
var SetupOneRoute = Ember.Route.extend({
|
|
titleToken: 'Setup',
|
|
beforeModel: function () {
|
|
var self = this,
|
|
ctrl = this.controllerFor('setup.one');
|
|
|
|
if (!ctrl) {
|
|
this.generateController('setup.one');
|
|
ctrl = this.controllerFor('setup.one');
|
|
}
|
|
|
|
return ajax({
|
|
url: self.get('ghostPaths.count'),
|
|
type: 'GET'
|
|
}).then(function (data) {
|
|
ctrl.set('count', data.count.toLocaleString());
|
|
}).catch(function () { /* Do nothing */ });
|
|
}
|
|
});
|
|
|
|
export default SetupOneRoute;
|