From e9a121ab7b924f189959a936743fcf70cb99f7ae Mon Sep 17 00:00:00 2001 From: Vidhu Kant Sharma Date: Sun, 16 Oct 2022 20:46:57 +0530 Subject: added 'Invoice Headers' component (incomplete) --- src/views/invoice/new.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/views/invoice') diff --git a/src/views/invoice/new.js b/src/views/invoice/new.js index cacf8d3..717a772 100644 --- a/src/views/invoice/new.js +++ b/src/views/invoice/new.js @@ -24,6 +24,7 @@ import InvoiceSummary from '../../components/tables/invoice-summary'; import HeadersEditor from '../../components/editors/invoice-headers-editor'; import { InvoiceClient } from '../../classes/client'; +import { Transport, Transporter } from '../../classes/invoice'; import { calcSum, currency } from '../../classes/item'; import { useState, useEffect } from 'react'; @@ -43,6 +44,9 @@ const NewInvoicePage = () => { Quantity: currency(0) }); + const [transporter, setTransporter] = useState(new Transporter()); + const [transport, setTransport] = useState(new Transport()); + useEffect(() => setShippingAddressId(-1), [client]); useEffect(() => setSum(calcSum(items)), [items]); @@ -63,11 +67,9 @@ const NewInvoicePage = () => { isInterstate={isInterstate} sum={sum} />
-
- -
+