diff --git a/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingEditQuantity/WeightCalculatePrice.jsx b/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingEditQuantity/WeightCalculatePrice.jsx
index ce68e60..c646c5e 100644
--- a/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingEditQuantity/WeightCalculatePrice.jsx
+++ b/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingEditQuantity/WeightCalculatePrice.jsx
@@ -9,7 +9,7 @@ const WeightCalculatePrice = ({ itemData, CartOrderDetails, onSubmit }) => {
const [enteredPrice, setEnteredPrice] = useState('');
const [enteredQty, setEnteredQty] = useState('');
const [calculatedQty, setCalculatedQty] = useState(0);
- const [calcMode, setCalcMode] = useState('amt');
+ const [calcMode, setCalcMode] = useState('kgs');
const priceInputRef = useRef(null);
const [form] = Form.useForm();
@@ -82,8 +82,8 @@ const WeightCalculatePrice = ({ itemData, CartOrderDetails, onSubmit }) => {
form.resetFields();
}}
>
-
diff --git a/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingTable3/BSBillingTable3.jsx b/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingTable3/BSBillingTable3.jsx index 298f997..5af7c1e 100644 --- a/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingTable3/BSBillingTable3.jsx +++ b/src/Pages/BookingScreen/Components/BSBillingTables/BSBillingTable3/BSBillingTable3.jsx @@ -241,15 +241,20 @@ const BSBillingTable3 = () => { // 👉 CTRL shortcuts if (!event.ctrlKey) return; - if (key === 'q') { - event.preventDefault(); - handleShortcut('qty'); - } - - if (key === 'e') { - event.preventDefault(); - handleShortcut('price'); - } + if (key === 'q') { + event.preventDefault(); + handleShortcut('qty'); + } else if (key === 'e') { + event.preventDefault(); + handleShortcut('price'); + } else if (key === 'y') { + event.preventDefault(); + handleShortcut('Parcel'); + } else if (key === 'b') { + event.preventDefault(); + handleShortcut('weightAmount'); + } + }; window.addEventListener('keydown', handleKeyDown); diff --git a/src/Pages/BookingScreen/Components/BSBillingTables/StandardTable/StandardTable.jsx b/src/Pages/BookingScreen/Components/BSBillingTables/StandardTable/StandardTable.jsx index 4708782..c4c9501 100644 --- a/src/Pages/BookingScreen/Components/BSBillingTables/StandardTable/StandardTable.jsx +++ b/src/Pages/BookingScreen/Components/BSBillingTables/StandardTable/StandardTable.jsx @@ -237,7 +237,7 @@ const StandardTable = () => { window.removeEventListener('keydown', handleKeyDown); }; }, [GetCustId, OrderCardDetail]); - + useEffect(() => { if (!preferenceshortcutkey) return; @@ -262,30 +262,40 @@ const StandardTable = () => { handleEditQuantity(item); setshortKeyMethod(method); }; - const handleKeyDown = (event) => { - const key = event.key.toLowerCase(); - // 👉 ALT + P → Open Edit Total Amount - if (event.altKey && key === 'p') { - event.preventDefault(); - if (OrderCardDetail?.length > 0) { - OpenEditTotalAmount(); + const handleKeyDown = (event) => { + const key = event.key.toLowerCase(); + // 👉 ALT + P → Open Edit Total Amount + if (event.altKey && key === 'p') { + event.preventDefault(); + if (OrderCardDetail?.length > 0) { + OpenEditTotalAmount(); + } + return; } - return; - } - // 👉 CTRL shortcuts - if (!event.ctrlKey) return; - - if (key === 'q') { - event.preventDefault(); - handleShortcut('qty'); - } - - if (key === 'e') { - event.preventDefault(); - handleShortcut('price'); - } - }; - + // 👉 CTRL shortcuts + if (!event.ctrlKey) return; + // if (key === 'q') { + // event.preventDefault(); + // handleShortcut('qty'); + // } + // if (key === 'e') { + // event.preventDefault(); + // handleShortcut('price'); + // } + if (key === 'q') { + event.preventDefault(); + handleShortcut('qty'); + } else if (key === 'e') { + event.preventDefault(); + handleShortcut('price'); + } else if (key === 'y') { + event.preventDefault(); + handleShortcut('Parcel'); + } else if (key === 'b') { + event.preventDefault(); + handleShortcut('weightAmount'); + } + }; window.addEventListener('keydown', handleKeyDown); return () => {