Pods, pods, everywhere

This commit is contained in:
Matthew Dillon 2015-06-04 12:18:59 -08:00
parent 33f783bc42
commit e623d52f34
66 changed files with 53 additions and 113 deletions

View file

@ -0,0 +1,5 @@
import SortableController from '../../controllers/sortable';
export default SortableController.extend({
sortBy: 'characteristicName',
});

View file

@ -0,0 +1,8 @@
import Ember from 'ember';
import AuthenticatedRouteMixin from 'simple-auth/mixins/authenticated-route-mixin';
export default Ember.Route.extend(AuthenticatedRouteMixin, {
model: function() {
return this.store.findAll('characteristic');
}
});

View file

@ -0,0 +1,19 @@
<h2>{{genus-name}} Characteristics</h2>
<h3>Total characteristics: {{controller.length}}</h3>
<table class="flakes-table">
<thead>
<tr>
<th {{action "setSortBy" "characteristicName"}}>Name</th>
<th {{action "setSortBy" "characteristicType"}}>Type</th>
</tr>
</thead>
<tbody>
{{#each characteristic in controller}}
<tr>
<td>{{characteristic.characteristicName}}</td>
<td>{{characteristic.characteristicType}}</td>
</tr>
{{/each}}
</tbody>
</table>