mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 22:30:31 +00:00
Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -103,7 +103,12 @@ function BillForm({
|
|||||||
.label(formatMessage({ id: 'note' })),
|
.label(formatMessage({ id: 'note' })),
|
||||||
entries: Yup.array().of(
|
entries: Yup.array().of(
|
||||||
Yup.object().shape({
|
Yup.object().shape({
|
||||||
quantity: Yup.number().nullable(),
|
quantity: Yup.number()
|
||||||
|
.nullable()
|
||||||
|
.when(['rate'], {
|
||||||
|
is: (rate) => rate,
|
||||||
|
then: Yup.number().required(),
|
||||||
|
}),
|
||||||
rate: Yup.number().nullable(),
|
rate: Yup.number().nullable(),
|
||||||
item_id: Yup.number()
|
item_id: Yup.number()
|
||||||
.nullable()
|
.nullable()
|
||||||
@@ -207,7 +212,7 @@ function BillForm({
|
|||||||
initialValues: {
|
initialValues: {
|
||||||
...initialValues,
|
...initialValues,
|
||||||
},
|
},
|
||||||
onSubmit: async (values, { setSubmitting, setErrors, resetForm }) => {
|
onSubmit: (values, { setSubmitting, setErrors, resetForm }) => {
|
||||||
setSubmitting(true);
|
setSubmitting(true);
|
||||||
|
|
||||||
const form = {
|
const form = {
|
||||||
|
|||||||
Reference in New Issue
Block a user