diff --git a/addon/classes/Table.js b/addon/classes/Table.js index a1a13a25..ed950723 100644 --- a/addon/classes/Table.js +++ b/addon/classes/Table.js @@ -73,19 +73,19 @@ export default class Table extends Ember.Object.extend({ * @property hideableColumns * @type {Ember.Array} */ - hideableColumns: computed.filterBy('flattenedColumns', 'hideable', true).readOnly(), + hideableColumns: computed.filterBy('allColumns', 'hideable', true).readOnly(), /** * @property hiddenColumns * @type {Ember.Array} */ - hiddenColumns: computed.filterBy('flattenedColumns', 'hidden', true).readOnly(), + hiddenColumns: computed.filterBy('allColumns', 'hidden', true).readOnly(), /** * @property visibleColumns * @type {Ember.Array} */ - visibleColumns: computed.filterBy('flattenedColumns', 'hidden', false).readOnly(), + visibleColumns: computed.filterBy('allColumns', 'hidden', false).readOnly(), /** * @property visibleColumnGroups @@ -109,10 +109,10 @@ export default class Table extends Ember.Object.extend({ }).readOnly(), /** - * @property flattenedColumns + * @property allColumns * @type {Ember.Array} */ - flattenedColumns: computed('columns.[]', 'columns.@each.subColumns', function() { + allColumns: computed('columns.[]', 'columns.@each.subColumns', function() { return emberArray(this.get('columns').reduce((arr, c) => { let subColumns = c.get('subColumns'); if (isEmpty(subColumns)) { diff --git a/tests/unit/classes/table-test.js b/tests/unit/classes/table-test.js index 89569c44..00e1d993 100644 --- a/tests/unit/classes/table-test.js +++ b/tests/unit/classes/table-test.js @@ -55,7 +55,7 @@ test('CP - visibleSubColumns', function(assert) { assert.equal(table.get('visibleSubColumns.length'), 2); }); -test('CP - flattenedColumns', function(assert) { +test('CP - allColumns', function(assert) { let table = new Table(); let col = new Column(); let group = new Column({ @@ -66,7 +66,7 @@ test('CP - flattenedColumns', function(assert) { }); table.setColumns([col, group, group2]); - assert.equal(table.get('flattenedColumns.length'), 5); + assert.equal(table.get('allColumns.length'), 5); });