From 3feb1a388762469e8e39e9e3f495752ef1a8afc2 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Mon, 6 Jun 2022 09:53:42 -0700 Subject: [PATCH] IO-1914 Add split tracking for inventory. --- .../bill-form/bill-form.lines.component.jsx | 23 ++++++++++++------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/client/src/components/bill-form/bill-form.lines.component.jsx b/client/src/components/bill-form/bill-form.lines.component.jsx index 5891741d7..18d996d5a 100644 --- a/client/src/components/bill-form/bill-form.lines.component.jsx +++ b/client/src/components/bill-form/bill-form.lines.component.jsx @@ -19,6 +19,7 @@ import CiecaSelect from "../../utils/Ciecaselect"; import BillLineSearchSelect from "../bill-line-search-select/bill-line-search-select.component"; import CurrencyInput from "../form-items-formatted/currency-form-item.component"; import BilllineAddInventory from "../billline-add-inventory/billline-add-inventory.component"; +import { useTreatments } from "@splitsoftware/splitio-react"; const mapStateToProps = createStructuredSelector({ //currentUser: selectCurrentUser @@ -40,7 +41,11 @@ export function BillEnterModalLinesComponent({ }) { const { t } = useTranslation(); const { setFieldsValue, getFieldsValue, getFieldValue } = form; - + const { Simple_Inventory } = useTreatments( + ["Simple_Inventory"], + {}, + bodyshop && bodyshop.imexshopid + ); const columns = (remove) => { return [ { @@ -485,13 +490,15 @@ export function BillEnterModalLinesComponent({ - {() => ( - - )} + {() => + Simple_Inventory.treatment === "on" && ( + + ) + } ),