Merge pull request #1352 from Gadha2311/integrate-modernpos

fix :  align ClassicPOS with missing ModernPOS features
This commit is contained in:
Able k Saju
2025-09-25 10:02:23 +05:30
committed by GitHub
7 changed files with 213 additions and 272 deletions
-2
View File
@@ -50,7 +50,6 @@ export class Defaults extends Doc {
cancelButtonColour?: string;
heldButtonColour?: string;
returnButtonColour?: string;
buyButtonColour?: string;
payButtonColour?: string;
payAndPrintButtonColour?: string;
@@ -127,7 +126,6 @@ export class Defaults extends Doc {
submitButtonColour: this.getPointOfSaleHidden(),
heldButtonColour: this.getPointOfSaleHidden(),
returnButtonColour: this.getPointOfSaleHidden(),
buyButtonColour: this.getPointOfSaleHidden(),
payButtonColour: this.getPointOfSaleHidden(),
payAndPrintButtonColour: this.getPointOfSaleHidden(),
};
+77 -127
View File
@@ -213,47 +213,47 @@
"label": "Save Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#9575cd",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Point of Sale"
@@ -263,47 +263,47 @@
"label": "Cancel Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#e86674",
"default": "#f98080",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Point of Sale"
@@ -313,47 +313,47 @@
"label": "Submit Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#00bcd4",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Point of Sale"
@@ -363,47 +363,47 @@
"label": "Held Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#ff9800",
"default": "#f98080",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Point of Sale"
@@ -413,97 +413,47 @@
"label": "Return Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#00bcd4",
"default": "#f98080",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
}
],
"section": "Point of Sale"
},
{
"fieldname": "buyButtonColour",
"label": "Buy Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#66bb6a",
"options": [
{
"label": "Red",
"value": "#e86674"
},
{
"label": "Orange",
"value": "#ff9800"
},
{
"label": "Yellow",
"value": "#ecc94b"
},
{
"label": "Green",
"value": "#66bb6a"
},
{
"label": "Teal",
"value": "#38b2ac"
},
{
"label": "Blue",
"value": "#00bcd4"
},
{
"label": "Indigo",
"value": "#667eea"
},
{
"label": "Purple",
"value": "#9575cd"
},
{
"label": "Pink",
"value": "#ed64a6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Point of Sale"
@@ -513,47 +463,47 @@
"label": "Pay Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#66bb6a",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Point of Sale"
@@ -563,47 +513,47 @@
"label": "Pay And Print Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#ff9800",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Point of Sale"
+77 -127
View File
@@ -107,47 +107,47 @@
"label": "Save Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#9575cd",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Colour"
@@ -157,47 +157,47 @@
"label": "Cancel Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#e86674",
"default": "#f98080",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Colour"
@@ -207,47 +207,47 @@
"label": "Submit Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#00bcd4",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Colour"
@@ -257,47 +257,47 @@
"label": "Held Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#ff9800",
"default": "#f98080",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Colour"
@@ -307,97 +307,47 @@
"label": "Return Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#00bcd4",
"default": "#f98080",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
}
],
"section": "Colour"
},
{
"fieldname": "buyButtonColour",
"label": "Buy Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#66bb6a",
"options": [
{
"label": "Red",
"value": "#e86674"
},
{
"label": "Orange",
"value": "#ff9800"
},
{
"label": "Yellow",
"value": "#ecc94b"
},
{
"label": "Green",
"value": "#66bb6a"
},
{
"label": "Teal",
"value": "#38b2ac"
},
{
"label": "Blue",
"value": "#00bcd4"
},
{
"label": "Indigo",
"value": "#667eea"
},
{
"label": "Purple",
"value": "#9575cd"
},
{
"label": "Pink",
"value": "#ed64a6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Colour"
@@ -407,47 +357,47 @@
"label": "Pay Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#66bb6a",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Colour"
@@ -457,47 +407,47 @@
"label": "Pay And Print Button Colour",
"placeholder": "Select Colour",
"fieldtype": "Color",
"default": "#ff9800",
"default": "#86efac",
"options": [
{
"label": "Red",
"value": "#e86674"
"value": "#f98080"
},
{
"label": "Orange",
"value": "#ff9800"
"value": "#fbbf70"
},
{
"label": "Yellow",
"value": "#ecc94b"
"value": "#fde047"
},
{
"label": "Green",
"value": "#66bb6a"
"value": "#86efac"
},
{
"label": "Teal",
"value": "#38b2ac"
"value": "#5eead4"
},
{
"label": "Blue",
"value": "#00bcd4"
"value": "#60a5fa"
},
{
"label": "Indigo",
"value": "#667eea"
"value": "#818cf8"
},
{
"label": "Purple",
"value": "#9575cd"
"value": "#a78bfa"
},
{
"label": "Pink",
"value": "#ed64a6"
"value": "#f472b6"
},
{
"label": "Black",
"value": "#112B42"
"value": "#9ca3af"
}
],
"section": "Colour"
@@ -295,7 +295,6 @@ import { InvoiceItem } from 'models/baseModels/InvoiceItem/InvoiceItem';
import { SalesInvoice } from 'models/baseModels/SalesInvoice/SalesInvoice';
import { showToast } from 'src/utils/interactive';
import { ModelNameEnum } from 'models/types';
import { POSProfile } from 'models/baseModels/POSProfile/PosProfile';
export default defineComponent({
name: 'SelectedItemRow',
@@ -187,6 +187,7 @@
fieldtype: 'Link',
target: 'Batch',
label: t`Batch`,
filters: { item: row.item as string},
}"
size="medium"
:value="row.batch"
@@ -254,6 +255,7 @@ export default defineComponent({
components: { Currency, Data, Float, Int, Link, Text },
props: {
row: { type: SalesInvoiceItem, required: true },
batchAdded: { type: Boolean, default: false },
},
emits: ['toggleModal', 'runSinvFormulas', 'selectedRow', 'applyPricingRule'],
@@ -270,10 +272,22 @@ export default defineComponent({
isExapanded: false,
batches: [] as string[],
availableQtyInBatch: 0,
itemVisibility: '',
defaultRate: this.row.rate as Money,
};
},
watch: {
'row.batch': {
async handler(newBatch) {
if (newBatch) {
this.availableQtyInBatch = await this.getAvailableQtyInBatch();
this.isExapanded = true;
}
},
immediate: true,
},
},
computed: {
isUOMConversionEnabled(): boolean {
return !!fyo.singles.InventorySettings?.enableUomConversions;
+40 -15
View File
@@ -19,6 +19,13 @@
@set-loyalty-points="(points) => emitEvent('setLoyaltyPoints', points)"
/>
<BatchSelectionModal
:open-modal="openBatchSelectionModal"
:item-code="selectedItemForBatch"
@toggle-modal="emitEvent('toggleModal', 'BatchSelection')"
@batch-selected="(batch) => emitEvent('batchSelected', batch)"
/>
<SavedInvoiceModal
:open-modal="openSavedInvoiceModal"
:modal-status="openSavedInvoiceModal"
@@ -40,6 +47,11 @@
@toggle-modal="emitEvent('toggleModal', 'PriceList')"
/>
<ItemEnquiryModal
:open-modal="openItemEnquiryModal"
@toggle-modal="emitEvent('toggleModal', 'ItemEnquiry')"
/>
<PaymentModal
:open-modal="openPaymentModal"
@toggle-modal="emitEvent('toggleModal', 'Payment')"
@@ -185,7 +197,7 @@
profile?.saveButtonColour ||
fyo.singles.Defaults?.saveButtonColour,
}"
:disabled="!sinvDoc?.party || !sinvDoc?.items?.length"
:class="`${isReturnInvoiceEnabledReturn ? 'py-5' : 'py-6'}`"
@click="$emit('saveInvoiceAction')"
>
<slot>
@@ -201,6 +213,7 @@
profile?.heldButtonColour ||
fyo.singles.Defaults?.heldButtonColour,
}"
:class="`${isReturnInvoiceEnabledReturn ? 'py-5' : 'py-6'}`"
@click="emitEvent('toggleModal', 'SavedInvoice', true)"
>
<slot>
@@ -218,7 +231,7 @@
profile?.cancelButtonColour ||
fyo.singles.Defaults?.cancelButtonColour,
}"
:disabled="!sinvDoc?.items?.length"
:class="`${isReturnInvoiceEnabledReturn ? 'py-5' : 'py-6'}`"
@click="() => $emit('clearValues')"
>
<slot>
@@ -248,15 +261,14 @@
class="mt-2 w-full py-5"
:style="{
backgroundColor:
profile?.buyButtonColour ||
fyo.singles.Defaults?.buyButtonColour,
profile?.payButtonColour ||
fyo.singles.Defaults?.payButtonColour,
}"
:disabled="disablePayButton"
@click="emitEvent('toggleModal', 'Payment', true)"
@click="emitEvent('handlePaymentAction')"
>
<slot>
<p class="uppercase text-lg text-white font-semibold">
{{ t`Buy` }}
{{ t`Pay` }}
</p>
</slot>
</Button>
@@ -267,15 +279,14 @@
class="mt-2 w-full py-5"
:style="{
backgroundColor:
profile?.buyButtonColour ||
fyo.singles.Defaults?.buyButtonColour,
profile?.payButtonColour ||
fyo.singles.Defaults?.payButtonColour,
}"
:disabled="disablePayButton"
@click="emitEvent('toggleModal', 'Payment', true)"
@click="emitEvent('handlePaymentAction')"
>
<slot>
<p class="uppercase text-lg text-white font-semibold">
{{ t`Buy` }}
{{ t`Pay` }}
</p>
</slot>
</Button>
@@ -311,9 +322,7 @@
:border="true"
:value="itemSearchTerm"
:show-clear-button="true"
@keyup.enter="(item) =>
emitEvent('handleItemSearch', item.target.value as string, true)
"
@keyup.enter="(event: KeyboardEvent) => emitEvent('handleItemSearch', (event.target as HTMLInputElement).value, true)"
@change="(item: string) => emitEvent('handleItemSearch', item)"
/>
@@ -374,6 +383,7 @@ import PaymentModal from './PaymentModal.vue';
import Button from 'src/components/Button.vue';
import KeyboardModal from './KeyboardModal.vue';
import PriceListModal from './PriceListModal.vue';
import ItemEnquiryModal from './ItemEnquiryModal.vue';
import { Item } from 'models/baseModels/Item/Item';
import Link from 'src/components/Controls/Link.vue';
import CouponCodeModal from './CouponCodeModal.vue';
@@ -394,6 +404,7 @@ import { SalesInvoiceItem } from 'models/baseModels/SalesInvoiceItem/SalesInvoic
import FloatingLabelCurrencyInput from 'src/components/POS/FloatingLabelCurrencyInput.vue';
import { AppliedCouponCodes } from 'models/baseModels/AppliedCouponCodes/AppliedCouponCodes';
import ModernPOSSelectedItemTable from 'src/components/POS/Modern/ModernPOSSelectedItemTable.vue';
import BatchSelectionModal from 'src/pages/POS/BatchSelectionModal.vue';
export default defineComponent({
name: 'ModernPos',
@@ -405,6 +416,7 @@ export default defineComponent({
KeyboardModal,
MultiLabelLink,
PriceListModal,
ItemEnquiryModal,
POSQuickActions,
CouponCodeModal,
OpenPOSShiftModal,
@@ -417,6 +429,7 @@ export default defineComponent({
ReturnSalesInvoiceModal,
FloatingLabelCurrencyInput,
ModernPOSSelectedItemTable,
BatchSelectionModal,
},
props: {
paidAmount: Money,
@@ -428,12 +441,14 @@ export default defineComponent({
openPaymentModal: Boolean,
openKeyboardModal: Boolean,
openPriceListModal: Boolean,
openItemEnquiryModal: Boolean,
openCouponCodeModal: Boolean,
openShiftCloseModal: Boolean,
openSavedInvoiceModal: Boolean,
openLoyaltyProgramModal: Boolean,
openAppliedCouponsModal: Boolean,
openReturnSalesInvoiceModal: Boolean,
openBatchSelectionModal: Boolean,
totalQuantity: {
type: Number,
default: 0,
@@ -479,6 +494,14 @@ export default defineComponent({
required: false,
default: null,
},
batchAddedItems: {
type: Array as () => string[],
default: () => [],
},
selectedItemForBatch: {
type: String,
default: '',
},
},
emits: [
'addItem',
@@ -502,7 +525,9 @@ export default defineComponent({
'selectedReturnInvoice',
'setTransferClearanceDate',
'saveAndContinue',
'handlePaymentAction',
'selectedRow',
'batchSelected',
],
data() {
return {
+5
View File
@@ -88,6 +88,7 @@
:item-discounts="(itemDiscounts as Money)"
:coupons="(coupons as AppliedCouponCodes)"
:open-price-list-modal="openPriceListModal"
:open-item-enquiry-modal="openItemEnquiryModal"
:applied-coupons-count="appliedCouponsCount"
:open-shift-close-modal="openShiftCloseModal"
:open-coupon-code-modal="openCouponCodeModal"
@@ -95,6 +96,8 @@
:open-loyalty-program-modal="openLoyaltyProgramModal"
:open-applied-coupons-modal="openAppliedCouponsModal"
:open-return-sales-invoice-modal="openReturnSalesInvoiceModal"
:open-batch-selection-modal="openBatchSelectionModal"
:selected-item-for-batch="selectedItemForBatch"
@add-item="addItem"
@toggle-view="toggleView"
@set-sinv-doc="setSinvDoc"
@@ -118,6 +121,8 @@
@save-and-continue="handleSaveAndContinue"
@set-transfer-clearance-date="setTransferClearanceDate"
@selected-row="setQuickQtySelectedRow"
@handle-payment-action="handlePaymentAction"
@batch-selected="handleBatchSelected"
/>
</div>
</template>