mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-17 05:10:31 +00:00
refactoring: WIP payment receive and made form.
This commit is contained in:
@@ -58,7 +58,7 @@ export function useEditPaymentReceive(props) {
|
||||
const client = useQueryClient();
|
||||
|
||||
return useMutation(
|
||||
(id, values) => ApiService.post(`sales/payment_receives/${id}`, values),
|
||||
([id, values]) => ApiService.post(`sales/payment_receives/${id}`, values),
|
||||
{
|
||||
onSuccess: () => {
|
||||
client.invalidateQueries('PAYMENT_RECEIVES');
|
||||
@@ -92,7 +92,10 @@ export function usePaymentReceive(id, props) {
|
||||
const states = useQuery(
|
||||
['PAYMENT_RECEIVE', id],
|
||||
() => ApiService.get(`sales/payment_receives/${id}`),
|
||||
props,
|
||||
{
|
||||
select: (res) => res.data.payment_receive,
|
||||
...props
|
||||
},
|
||||
);
|
||||
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user