@managesome/eposmatic-toolkit 0.2.307 → 0.2.309
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1286,6 +1286,8 @@ function getOffersWithStats({ offers, customer, vouchers, giftCards, customerOff
|
|
|
1286
1286
|
if (stats.claimable) {
|
|
1287
1287
|
totalClaimableOffers = totalClaimableOffers.filter((id) => id !== offer._id);
|
|
1288
1288
|
}
|
|
1289
|
+
stats.applicable_quantity = 0;
|
|
1290
|
+
unlockedOffersApplicableTimes[offer._id] = 0;
|
|
1289
1291
|
stats.claimable = false;
|
|
1290
1292
|
stats.message = '⛔️ You have reached your personal limit for this offer ⛔️';
|
|
1291
1293
|
}
|
|
@@ -1543,6 +1545,8 @@ function getOffersWithStats({ offers, customer, vouchers, giftCards, customerOff
|
|
|
1543
1545
|
if (stats.claimable) {
|
|
1544
1546
|
totalClaimableOffers = totalClaimableOffers.filter((id) => id !== offer._id);
|
|
1545
1547
|
}
|
|
1548
|
+
stats.applicable_quantity = 0;
|
|
1549
|
+
unlockedOffersApplicableTimes[offer._id] = 0;
|
|
1546
1550
|
stats.claimable = false;
|
|
1547
1551
|
stats.message = '⛔️ You have reached your personal limit for this offer ⛔️';
|
|
1548
1552
|
}
|
|
@@ -1807,6 +1811,8 @@ function getOffersWithStats({ offers, customer, vouchers, giftCards, customerOff
|
|
|
1807
1811
|
if (stats.claimable) {
|
|
1808
1812
|
totalClaimableOffers = totalClaimableOffers.filter((id) => id !== offer._id);
|
|
1809
1813
|
}
|
|
1814
|
+
stats.applicable_quantity = 0;
|
|
1815
|
+
unlockedOffersApplicableTimes[offer._id] = 0;
|
|
1810
1816
|
stats.claimable = false;
|
|
1811
1817
|
stats.message = '⛔️ You have reached your personal limit for this offer ⛔️';
|
|
1812
1818
|
}
|
|
@@ -2082,6 +2088,8 @@ function getOffersWithStats({ offers, customer, vouchers, giftCards, customerOff
|
|
|
2082
2088
|
if (stats.claimable) {
|
|
2083
2089
|
totalClaimableOffers = totalClaimableOffers.filter((id) => id !== offer._id);
|
|
2084
2090
|
}
|
|
2091
|
+
stats.applicable_quantity = 0;
|
|
2092
|
+
unlockedOffersApplicableTimes[offer._id] = 0;
|
|
2085
2093
|
stats.claimable = false;
|
|
2086
2094
|
stats.message = '⛔️ You have reached your personal limit for this offer ⛔️';
|
|
2087
2095
|
}
|
|
@@ -27,7 +27,7 @@ function getWarehouseReceiptEngineFooterDetails(order, settings) {
|
|
|
27
27
|
}
|
|
28
28
|
if (order.gst && !settings.hide_gst_value) {
|
|
29
29
|
if (order.is_gst_inclusive) {
|
|
30
|
-
const right = (0, common_1.localeAmount)(currencySymbol, (order.grand_total ?? 0) - (order.gst_amount ?? 0));
|
|
30
|
+
const right = (0, common_1.localeAmount)(currencySymbol, Math.max(0, (order.grand_total ?? 0) - (order.gst_amount ?? 0)));
|
|
31
31
|
details.push({
|
|
32
32
|
left: `Total before ${settings.gstName}`,
|
|
33
33
|
right,
|
|
@@ -125,7 +125,7 @@ function getReceiptEngineFooterDetails(order, settings) {
|
|
|
125
125
|
}
|
|
126
126
|
// 7. GST (Total before GST and GST amount)
|
|
127
127
|
if (order.gst && !settings.hide_gst_value && order.is_gst_inclusive) {
|
|
128
|
-
const right = (0, common_1.localeAmount)(currencySymbol, (order.grand_total ?? 0) - (order.gst_amount ?? 0));
|
|
128
|
+
const right = (0, common_1.localeAmount)(currencySymbol, Math.max(0, (order.grand_total ?? 0) - (order.gst_amount ?? 0)));
|
|
129
129
|
details.push({
|
|
130
130
|
left: `Total before ${settings.gstName}`,
|
|
131
131
|
right,
|