framework/ember/app/routes/user.js

14 lines
260 B
JavaScript
Raw Normal View History

import Ember from 'ember';
export default Ember.Route.extend({
model: function(params) {
return this.store.find('user', params.username);
2015-03-12 10:29:32 +08:00
},
afterModel: function(model) {
if (!model.get('joinTime')) {
return model.reload();
}
}
});