IO-974 Close bill drawer on return.
This commit is contained in:
@@ -173,7 +173,9 @@ export function BillDetailEditcontainer({ setPartsOrderContext }) {
|
||||
<Space>
|
||||
<Button
|
||||
disabled={data.bills_by_pk.is_credit_memo}
|
||||
onClick={() =>
|
||||
onClick={() => {
|
||||
delete search.billid;
|
||||
history.push({ search: queryString.stringify(search) });
|
||||
setPartsOrderContext({
|
||||
actions: {},
|
||||
context: {
|
||||
@@ -193,8 +195,8 @@ export function BillDetailEditcontainer({ setPartsOrderContext }) {
|
||||
}),
|
||||
isReturn: true,
|
||||
},
|
||||
})
|
||||
}
|
||||
});
|
||||
}}
|
||||
>
|
||||
{t("bills.actions.return")}
|
||||
</Button>
|
||||
|
||||
@@ -202,24 +202,27 @@ export function BillFormComponent({
|
||||
</LayoutFormRow>
|
||||
<LayoutFormRow>
|
||||
<Form.Item
|
||||
span={3}
|
||||
label={t("bills.fields.federal_tax_rate")}
|
||||
name="federal_tax_rate"
|
||||
>
|
||||
<CurrencyInput min={0} disabled={disabled} />
|
||||
</Form.Item>
|
||||
<Form.Item
|
||||
span={3}
|
||||
label={t("bills.fields.state_tax_rate")}
|
||||
name="state_tax_rate"
|
||||
>
|
||||
<CurrencyInput min={0} disabled={disabled} />
|
||||
</Form.Item>
|
||||
<Form.Item
|
||||
span={3}
|
||||
label={t("bills.fields.local_tax_rate")}
|
||||
name="local_tax_rate"
|
||||
>
|
||||
<CurrencyInput min={0} />
|
||||
</Form.Item>
|
||||
<Form.Item shouldUpdate grow>
|
||||
<Form.Item shouldUpdate span={15}>
|
||||
{() => {
|
||||
const values = form.getFieldsValue([
|
||||
"billlines",
|
||||
@@ -238,7 +241,7 @@ export function BillFormComponent({
|
||||
if (!!totals)
|
||||
return (
|
||||
<div>
|
||||
<Space split={<Divider type="vertical" />} wrap>
|
||||
<Space wrap>
|
||||
<Statistic
|
||||
title={t("bills.labels.subtotal")}
|
||||
value={totals.subtotal.toFormat()}
|
||||
|
||||
Reference in New Issue
Block a user