diff --git a/bodyshop_translations.babel b/bodyshop_translations.babel index 2e39fa216..d987d9ac9 100644 --- a/bodyshop_translations.babel +++ b/bodyshop_translations.babel @@ -2527,6 +2527,27 @@ validation + + manualinhouse + false + + + + + + en-US + false + + + es-MX + false + + + fr-CA + false + + + unique_invoice_number false diff --git a/client/src/App/App.styles.scss b/client/src/App/App.styles.scss index e9c7200ca..7ee64f7f1 100644 --- a/client/src/App/App.styles.scss +++ b/client/src/App/App.styles.scss @@ -118,3 +118,9 @@ .production-list-min-height { min-height: 19px; } + +#noticeable-widget { + iframe { + z-index: 2 !important; + } +} diff --git a/client/src/components/bill-form/bill-form.component.jsx b/client/src/components/bill-form/bill-form.component.jsx index b5cfb9322..e8d8e4387 100644 --- a/client/src/components/bill-form/bill-form.component.jsx +++ b/client/src/components/bill-form/bill-form.component.jsx @@ -106,6 +106,18 @@ export function BillFormComponent({ required: true, //message: t("general.validation.required"), }, + ({ getFieldValue }) => ({ + validator(rule, value) { + if ( + value && + !getFieldValue(["isinhouse"]) && + value === bodyshop.inhousevendorid + ) { + return Promise.reject(t("bills.validation.manualinhouse")); + } + return Promise.resolve(); + }, + }), ]} > a.useremail === userEmail ); + if (authRecord[0] && authRecord[0].user.validemail) { + window.$crisp.push(["set", "user:email", [authRecord[0].user.email]]); + } + yield put(setAuthlevel(authRecord[0] ? authRecord[0].authlevel : 0)); yield put( updateUserDetailsSuccess( diff --git a/client/src/translations/en_us/common.json b/client/src/translations/en_us/common.json index dc6fb5aff..38855c824 100644 --- a/client/src/translations/en_us/common.json +++ b/client/src/translations/en_us/common.json @@ -167,6 +167,7 @@ "exported": "Bill exported successfully." }, "validation": { + "manualinhouse": "Manual posting to the in house vendor is restricted. ", "unique_invoice_number": "This invoice number has already been entered for this vendor." } }, diff --git a/client/src/translations/es/common.json b/client/src/translations/es/common.json index 277f15ecc..fbaf30da8 100644 --- a/client/src/translations/es/common.json +++ b/client/src/translations/es/common.json @@ -167,6 +167,7 @@ "exported": "" }, "validation": { + "manualinhouse": "", "unique_invoice_number": "" } }, diff --git a/client/src/translations/fr/common.json b/client/src/translations/fr/common.json index 69c4f524b..cc57c0222 100644 --- a/client/src/translations/fr/common.json +++ b/client/src/translations/fr/common.json @@ -167,6 +167,7 @@ "exported": "" }, "validation": { + "manualinhouse": "", "unique_invoice_number": "" } },