UNPKG

ember-cli-admin

Version:

Powerful admin dashboard for ember-cli projects, more in http://ember-admin.com

17 lines (15 loc) 503 B
import Ember from 'ember'; import Attributes from 'ember-cli-admin/dsl/attributes'; export default Ember.Mixin.create({ setupController: function(controller, model) { var type; this._setSiteTitle(controller, model); if (model) { this._setModel(controller, model); type = model.type || model.constructor; controller.set('modelAttributes', Attributes.detect(type)); controller.set('modelType', type); return controller.set('batches', Ember.A()); } } });