feat( contact duplicate): contact duplicate dialog.

This commit is contained in:
elforjani3
2021-03-03 16:38:57 +02:00
parent 57c2c7e269
commit 30f66480d0
11 changed files with 233 additions and 4 deletions

View File

@@ -0,0 +1,14 @@
import { useQuery } from 'react-query';
import useApiRequest from '../useRequest';
/**
* Retrieve the contact duplicate.
*/
export function useContact(id, props) {
const apiRequest = useApiRequest();
return useQuery(['CONTACT', id], () => apiRequest.get(`contacts/${id}`), {
select: (res) => res.data.customer,
...props,
});
}

View File

@@ -20,3 +20,4 @@ export * from './settings';
export * from './users';
export * from './invite';
export * from './exchangeRates';
export * from './contacts';