BREAKING - Package upgrades + some WIP on invoice enter.
This commit is contained in:
@@ -6,7 +6,8 @@ export default function InvoiceAddLineButton({
|
||||
jobLine,
|
||||
invoiceLineState,
|
||||
form,
|
||||
discount
|
||||
discount,
|
||||
disabled
|
||||
}) {
|
||||
const [visibility, setVisibility] = useState(false);
|
||||
const { t } = useTranslation();
|
||||
@@ -41,7 +42,7 @@ export default function InvoiceAddLineButton({
|
||||
|
||||
return (
|
||||
<Popover content={popContent} visible={visibility}>
|
||||
<Button onClick={() => setVisibility(true)}>
|
||||
<Button onClick={() => setVisibility(true)} disabled={!disabled}>
|
||||
<Icon type="select" />
|
||||
</Button>
|
||||
</Popover>
|
||||
|
||||
@@ -32,7 +32,7 @@ export default function InvoiceEnterModalComponent({
|
||||
}) {
|
||||
const { t } = useTranslation();
|
||||
const { getFieldDecorator, resetFields } = form;
|
||||
|
||||
|
||||
return (
|
||||
<Modal
|
||||
title={
|
||||
@@ -128,7 +128,6 @@ export default function InvoiceEnterModalComponent({
|
||||
})(<InputNumber precision={2} min={0} name="total" />)}
|
||||
</Form.Item>
|
||||
</div>
|
||||
|
||||
<Row>
|
||||
<Col span={12}>
|
||||
<InvoiceEnterModalTableComponent
|
||||
@@ -140,6 +139,7 @@ export default function InvoiceEnterModalComponent({
|
||||
</Col>
|
||||
<Col span={12}>Table of added items.</Col>
|
||||
</Row>
|
||||
);
|
||||
</Form>
|
||||
</Modal>
|
||||
);
|
||||
|
||||
@@ -101,6 +101,7 @@ export default function InvoiceEnterModalTableComponent({
|
||||
jobLine={record}
|
||||
form={form}
|
||||
discount={vendor ? vendor.discount : null}
|
||||
disabled={vendor}
|
||||
/>
|
||||
</div>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user