fix: passing number format to reports

This commit is contained in:
Ahmed Bouhuolia
2025-12-11 00:19:55 +02:00
parent d006362be2
commit 340b78d968
20 changed files with 308 additions and 163 deletions

View File

@@ -22,6 +22,7 @@ export const getDefaultAPAgingSummaryQuery = () => {
filterByOption: 'without-zero-balance',
vendorsIds: [],
branchesIds: [],
numberFormat: {},
};
};

View File

@@ -21,6 +21,7 @@ export const getDefaultARAgingSummaryQuery = () => {
filterByOption: 'without-zero-balance',
customersIds: [],
branchesIds: [],
numberFormat: {},
};
};

View File

@@ -33,6 +33,7 @@ export const getDefaultBalanceSheetQuery = () => ({
percentageOfRow: false,
branchesIds: [],
numberFormat: {},
});
/**

View File

@@ -17,6 +17,7 @@ export const getDefaultCashFlowSheetQuery = () => {
displayColumnsType: 'total',
filterByOption: 'with-transactions',
branchesIds: [],
numberFormat: {},
};
};

View File

@@ -18,6 +18,7 @@ export const getInventoryItemDetailsDefaultQuery = () => ({
itemsIds: [],
warehousesIds: [],
branchesIds: [],
numberFormat: {},
});
/**

View File

@@ -35,6 +35,7 @@ export const getDefaultProfitLossQuery = () => ({
percentageExpense: false,
branchesIds: [],
numberFormat: {},
});
/**
@@ -50,7 +51,6 @@ const parseProfitLossQuery = (locationQuery) => {
return {
...transformed,
// Ensures the branches ids is always array.
branchesIds: castArray(transformed.branchesIds),
};

View File

@@ -17,6 +17,7 @@ export function getDefaultTrialBalanceQuery() {
basis: 'accrual',
filterByOption: 'with-transactions',
branchesIds: [],
numberFormat: {},
};
}

View File

@@ -42,7 +42,6 @@ export const transformAccountsFilter = (form) => {
*/
export const transformFilterFormToQuery = (form) => {
return R.compose(
R.curry(flatten)({ safe: true }),
transfromToSnakeCase,
transformAccountsFilter,
transformDisplayColumnsType,