This repository has been archived on 2025-03-30. You can view files and clone it, but cannot push or open issues or pull requests.
hymenobacterdotinfo/app/pods/measurements/route.js
2015-06-11 11:19:13 -08:00

21 lines
737 B
JavaScript

import Ember from 'ember';
import AuthenticatedRouteMixin from 'simple-auth/mixins/authenticated-route-mixin';
export default Ember.Route.extend(AuthenticatedRouteMixin, {
model: function() {
return Ember.RSVP.hash({
measurements: this.store.findAll('measurement'),
species: this.store.findAll('species')
});
},
setupController: function(controller, models) {
var tableAttrs = [
{ name: 'Strain', attr: 'strain.strainName' },
{ name: 'Characteristic', attr: 'characteristic.CharacteristicName' },
{ name: 'Value', attr: 'computedValue'}
];
controller.set('model', models);
controller.set('tableAttrs', tableAttrs);
controller.set('row', 'measurement-index-row');
},
});