Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions app/controllers/account/billing/invoices/list.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,11 +118,15 @@ export default class extends Controller.extend(EmberTableControllerMixin) {
name : 'Amount',
valuePath : 'amount',
extraValuePaths : ['event'],
cellComponent : 'ui-table/cell/events/cell-amount'
cellComponent : 'ui-table/cell/events/cell-amount',
isSortable : true,
headerComponent : 'tables/headers/sort'
},
{
name : 'Status',
valuePath : 'status'
name : 'Status',
valuePath : 'status',
isSortable : true,
headerComponent : 'tables/headers/sort'
},
{
name : 'Action',
Expand Down
4 changes: 2 additions & 2 deletions app/routes/account/billing/invoices/list.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default class extends Route.extend(EmberTableRouteMixin) {
}
async model(params) {
this.set('params', params);
const searchField = 'name';
const searchField = 'status';
let filterOptions = [];
if (params.invoice_status === 'paid' || params.invoice_status === 'due') {
filterOptions = [
Expand Down Expand Up @@ -59,7 +59,7 @@ export default class extends Route.extend(EmberTableRouteMixin) {

queryString = this.applySortFilters(queryString, params);
return {
eventInvoices: (await this.store.query('event-invoice', queryString)).toArray(),
eventInvoices: await this.asArray(this.store.query('event-invoice', queryString)),
params

};
Expand Down
2 changes: 1 addition & 1 deletion app/templates/account/billing/invoices/list.hbs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<div class="sixteen wide column">
{{tables/default columns=columns
rows=model.eventInvoices
rows=model.eventInvoices.data
currentPage=page
pageSize=per_page
searchQuery=search
Expand Down