Add default sort to table

This commit is contained in:
Matthew Dillon 2015-06-09 14:28:56 -08:00
parent 15b31f7c8a
commit c8ffc95068
7 changed files with 25 additions and 3 deletions

View file

@ -13,5 +13,6 @@ export default Ember.Route.extend(AuthenticatedRouteMixin, {
controller.set('model', model);
controller.set('tableAttrs', tableAttrs);
controller.set('row', 'characteristic-index-row');
controller.set('sort', ['characteristicName']);
},
});

View file

@ -1,4 +1,10 @@
<h2>{{genus-name}} Characteristics</h2>
<h3>Total characteristics: {{model.length}}</h3>
{{sortable-table content=model tableAttrs=tableAttrs row=row}}
{{
sortable-table
content=model
tableAttrs=tableAttrs
row=row
sortProperties=sort
}}