fix: Integrate multiple branches with expense resource

This commit is contained in:
Ahmed Bouhuolia
2024-09-02 15:02:02 +02:00
parent 0dd05493b2
commit 0812e3087e
5 changed files with 70 additions and 3 deletions

View File

@@ -15,12 +15,16 @@ export class ExpensesExportable extends Exportable {
* @returns
*/
public exportable(tenantId: number, query: IExpensesFilter) {
const filterQuery = (query) => {
query.withGraphFetched('branch');
};
const parsedQuery = {
sortOrder: 'desc',
columnSortBy: 'created_at',
...query,
page: 1,
pageSize: EXPORT_SIZE_LIMIT,
filterQuery,
} as IExpensesFilter;
return this.expensesApplication