mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 22:30:31 +00:00
fix: BIG-148 items entries ordered by index.
This commit is contained in:
@@ -14,19 +14,12 @@ const PaymentMadeDetailContext = React.createContext();
|
||||
*/
|
||||
function PaymentMadeDetailProvider({ paymentMadeId, ...props }) {
|
||||
// Handle fetch specific payment made details.
|
||||
const { data: paymentMade, isLoading: isPaymentMadeLoading } =
|
||||
usePaymentMade(paymentMadeId, {
|
||||
const { data: paymentMade, isLoading: isPaymentMadeLoading } = usePaymentMade(
|
||||
paymentMadeId,
|
||||
{
|
||||
enabled: !!paymentMadeId,
|
||||
});
|
||||
|
||||
// Handle fetch specific payment made details.
|
||||
const {
|
||||
data: { entries: paymentEntries },
|
||||
isLoading: isPaymentLoading,
|
||||
} = usePaymentMadeEditPage(paymentMadeId, {
|
||||
enabled: !!paymentMadeId,
|
||||
});
|
||||
|
||||
},
|
||||
);
|
||||
// Handle fetch transaction by reference.
|
||||
const {
|
||||
data: { transactions },
|
||||
@@ -44,11 +37,9 @@ function PaymentMadeDetailProvider({ paymentMadeId, ...props }) {
|
||||
transactions,
|
||||
paymentMadeId,
|
||||
paymentMade,
|
||||
paymentEntries,
|
||||
};
|
||||
|
||||
const loading =
|
||||
isTransactionLoading || isPaymentMadeLoading || isPaymentLoading;
|
||||
const loading = isTransactionLoading || isPaymentMadeLoading;
|
||||
|
||||
return (
|
||||
<DrawerLoading loading={loading}>
|
||||
|
||||
Reference in New Issue
Block a user