+
diff --git a/client/src/lib/axios/createAxiosDataProvider.ts b/client/src/lib/axios/createAxiosDataProvider.ts
index 4c69ab4..8b460d5 100644
--- a/client/src/lib/axios/createAxiosDataProvider.ts
+++ b/client/src/lib/axios/createAxiosDataProvider.ts
@@ -117,7 +117,7 @@ export const createAxiosDataProvider = (
},
custom: async (params: ICustomDataProviderParam): Promise => {
- const { url, method, responseType, headers, ...payload } = params;
+ const { url, method, responseType, headers, signal, ...payload } = params;
const requestUrl = `${url}?`;
/*if (sort) {
@@ -168,6 +168,7 @@ export const createAxiosDataProvider = (
default:
customResponse = await httpClient.get(requestUrl, {
responseType,
+ signal,
headers,
});
break;
diff --git a/client/src/lib/hooks/useDataSource/DataSource.ts b/client/src/lib/hooks/useDataSource/DataSource.ts
index c4026ee..45fc7e2 100644
--- a/client/src/lib/hooks/useDataSource/DataSource.ts
+++ b/client/src/lib/hooks/useDataSource/DataSource.ts
@@ -55,6 +55,7 @@ export interface IRemoveOneDataProviderParams {
export interface ICustomDataProviderParam {
url: string;
method: "get" | "delete" | "head" | "options" | "post" | "put" | "patch";
+ signal?: AbortSignal;
responseType?: ResponseType;
headers?: {
[key: string]: AxiosHeaderValue;
diff --git a/client/src/lib/hooks/useDataSource/useCustom.tsx b/client/src/lib/hooks/useDataSource/useCustom.tsx
index 77b7a33..5b27491 100644
--- a/client/src/lib/hooks/useDataSource/useCustom.tsx
+++ b/client/src/lib/hooks/useDataSource/useCustom.tsx
@@ -1,4 +1,4 @@
-import { UseQueryOptions, UseQueryResult, keepPreviousData, useQuery } from "@tanstack/react-query";
+import { UseQueryOptions, UseQueryResult, useQuery } from "@tanstack/react-query";
import { TDataSourceError, TDataSourceRecord } from "./types";
export const useCustom = <
@@ -9,7 +9,6 @@ export const useCustom = <
options: UseQueryOptions
): UseQueryResult => {
return useQuery({
- placeholderData: keepPreviousData,
...options,
});
};
diff --git a/client/src/locales/en.json b/client/src/locales/en.json
index cd7aea2..84efdd8 100644
--- a/client/src/locales/en.json
+++ b/client/src/locales/en.json
@@ -110,7 +110,8 @@
"status": "Status",
"customer_information": "Customer",
"total_price": "Imp. total"
- }
+ },
+ "quote": "Quote"
},
"create": {
"title": "New quote",