fix: increase the max items count.

This commit is contained in:
a.bouhuolia
2021-03-09 13:17:34 +02:00
parent 8f95b09649
commit 2494a33d21
6 changed files with 11 additions and 12 deletions

View File

@@ -23,13 +23,13 @@ function BillFormProvider({ billId, ...props }) {
const {
data: { vendors },
isFetching: isVendorsLoading,
} = useVendors();
} = useVendors({ page_size: 10000 });
// Handle fetch Items data table or list
const {
data: { items },
isFetching: isItemsLoading,
} = useItems();
} = useItems({ page_size: 10000 });
// Handle fetch bill details.
const { data: bill, isFetching: isBillLoading } = useBill(billId, {

View File

@@ -28,13 +28,13 @@ function PaymentMadeFormProvider({ paymentMadeId, ...props }) {
data: { items },
isFetching: isItemsFetching,
isLoading: isItemsLoading,
} = useItems();
} = useItems({ page_size: 10000 });
// Handle fetch venders data table or list.
const {
data: { vendors },
isFetching: isVendorsFetching,
} = useVendors();
} = useVendors({ page_size: 10000 });
// Handle fetch specific payment made details.
const {

View File

@@ -23,13 +23,13 @@ function EstimateFormProvider({ estimateId, ...props }) {
const {
data: { items },
isFetching: isItemsFetching,
} = useItems();
} = useItems({ page_size: 10000 });
// Handle fetch customers data table or list
const {
data: { customers },
isFetch: isCustomersFetching,
} = useCustomers();
} = useCustomers({ page_size: 10000 });
// Handle fetch settings.
useSettings();

View File

@@ -20,7 +20,6 @@ const InvoiceFormContext = createContext();
*/
function InvoiceFormProvider({ invoiceId, ...props }) {
const { state } = useLocation();
const estimateId = state?.action;
const { data: invoice, isLoading: isInvoiceLoading } = useInvoice(invoiceId, {
@@ -42,13 +41,13 @@ function InvoiceFormProvider({ invoiceId, ...props }) {
const {
data: { items },
isLoading: isItemsLoading,
} = useItems();
} = useItems({ page_size: 10000 });
// Handle fetch customers data table or list
const {
data: { customers },
isLoading: isCustomersLoading,
} = useCustomers();
} = useCustomers({ page_size: 10000 });
// Handle fetching settings.
const { isLoading: isSettingsLoading } = useSettingsInvoices();

View File

@@ -41,7 +41,7 @@ function PaymentReceiveFormProvider({ paymentReceiveId, ...props }) {
const {
data: { customers },
isFetching: isCustomersFetching,
} = useCustomers();
} = useCustomers({ page_size: 10000 });
// Detarmines whether the new mode.
const isNewMode = !paymentReceiveId;

View File

@@ -30,13 +30,13 @@ function ReceiptFormProvider({ receiptId, ...props }) {
const {
data: { customers },
isFetching: isCustomersLoading,
} = useCustomers();
} = useCustomers({ page_size: 10000 });
// Handle fetch Items data table or list
const {
data: { items },
isFetching: isItemsLoading,
} = useItems();
} = useItems({ page_size: 10000 });
// Fetch receipt settings.
const { isLoading: isSettingLoading } = useSettings();