@open-tender/store 0.3.95 → 0.3.96
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.
|
@@ -133,27 +133,27 @@ var makeNetOrder = function (order, refunds) {
|
|
|
133
133
|
// copy = adjustAmounts(copy, lookup, 'discounts')
|
|
134
134
|
// copy = adjustAmounts(copy, lookup, 'taxes')
|
|
135
135
|
// copy = adjustAmounts(copy, lookup, 'tenders', 'tender_index')
|
|
136
|
-
|
|
136
|
+
copy.gift_cards.forEach(function (i) {
|
|
137
137
|
var amount = i.code ? lookup.gift_cards[i.code] : null;
|
|
138
138
|
if (amount)
|
|
139
139
|
i.amount = adjustAmount(i.amount, amount);
|
|
140
140
|
});
|
|
141
|
-
|
|
141
|
+
copy.surcharges.forEach(function (i) {
|
|
142
142
|
var amount = lookup.surcharges[i.id];
|
|
143
143
|
if (amount)
|
|
144
144
|
i.amount = adjustAmount(i.amount, amount);
|
|
145
145
|
});
|
|
146
|
-
|
|
146
|
+
copy.discounts.forEach(function (i) {
|
|
147
147
|
var amount = lookup.discounts[i.id];
|
|
148
148
|
if (amount)
|
|
149
149
|
i.amount = adjustAmount(i.amount, amount);
|
|
150
150
|
});
|
|
151
|
-
|
|
151
|
+
copy.taxes.forEach(function (i) {
|
|
152
152
|
var amount = lookup.taxes[i.id];
|
|
153
153
|
if (amount)
|
|
154
154
|
i.amount = adjustAmount(i.amount, amount);
|
|
155
155
|
});
|
|
156
|
-
|
|
156
|
+
copy.tenders.forEach(function (i, idx) {
|
|
157
157
|
var amount = lookup.tenders[i.tender_index || idx];
|
|
158
158
|
if (amount)
|
|
159
159
|
i.amount = adjustAmount(i.amount, amount);
|
|
@@ -127,27 +127,27 @@ export var makeNetOrder = function (order, refunds) {
|
|
|
127
127
|
// copy = adjustAmounts(copy, lookup, 'discounts')
|
|
128
128
|
// copy = adjustAmounts(copy, lookup, 'taxes')
|
|
129
129
|
// copy = adjustAmounts(copy, lookup, 'tenders', 'tender_index')
|
|
130
|
-
|
|
130
|
+
copy.gift_cards.forEach(function (i) {
|
|
131
131
|
var amount = i.code ? lookup.gift_cards[i.code] : null;
|
|
132
132
|
if (amount)
|
|
133
133
|
i.amount = adjustAmount(i.amount, amount);
|
|
134
134
|
});
|
|
135
|
-
|
|
135
|
+
copy.surcharges.forEach(function (i) {
|
|
136
136
|
var amount = lookup.surcharges[i.id];
|
|
137
137
|
if (amount)
|
|
138
138
|
i.amount = adjustAmount(i.amount, amount);
|
|
139
139
|
});
|
|
140
|
-
|
|
140
|
+
copy.discounts.forEach(function (i) {
|
|
141
141
|
var amount = lookup.discounts[i.id];
|
|
142
142
|
if (amount)
|
|
143
143
|
i.amount = adjustAmount(i.amount, amount);
|
|
144
144
|
});
|
|
145
|
-
|
|
145
|
+
copy.taxes.forEach(function (i) {
|
|
146
146
|
var amount = lookup.taxes[i.id];
|
|
147
147
|
if (amount)
|
|
148
148
|
i.amount = adjustAmount(i.amount, amount);
|
|
149
149
|
});
|
|
150
|
-
|
|
150
|
+
copy.tenders.forEach(function (i, idx) {
|
|
151
151
|
var amount = lookup.tenders[i.tender_index || idx];
|
|
152
152
|
if (amount)
|
|
153
153
|
i.amount = adjustAmount(i.amount, amount);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@open-tender/store",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.96",
|
|
4
4
|
"description": "A library of hooks, reducers, utility functions, and types for use with Open Tender applications that utilize our in-store POS API",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|