Skip to content

Conversation

@lexinor
Copy link

@lexinor lexinor commented Nov 6, 2022

Pull Request Description

  • Added some ordering paramters to properly fit usage. We are now showing the UNPAID and latest Invoices instead of showing the PAID and oldest
  • Changed default expiring date from TWO WEEKS to ONE WEEK

Pull Request Checklist:

  • Have you followed the guidelines in our contributing document and Code of Conduct?
  • Have you checked to ensure there aren't other open for the same update/change?
  • Have you built and tested the resource in-game after the relevant change?

- Added some ordering paramters to properly fit usage. We are now showing the UNPAID and latest Invoices instead of showing the PAID and oldest
- Changed default expiring date from TWO WEEKS to ONE WEEK
export class InvoiceDB {
async getAllInvoices(): Promise<InvoiceModel[]> {
return await InvoiceModel.findAll();
return await InvoiceModel.findAll({ order: [['status', 'DESC'], ['createdAt', 'DESC']]});
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What value does status have here again?

Copy link
Author

@lexinor lexinor Nov 17, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's to filter on the status which are "PAID", "PENDING", etc.. Like that we can view the pending invoices and the earliest ones instead of the oldest and paid ones

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants