@darkpos/pricing 1.0.156 → 1.0.158

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.
@@ -258,6 +258,7 @@ describe('addItem function', () => {
258
258
  quantity: 1,
259
259
  price: 50,
260
260
  modifiers: [],
261
+ autoSerial: true,
261
262
  };
262
263
 
263
264
  const result = addItem({
@@ -1085,7 +1085,7 @@ describe('Order actions', () => {
1085
1085
  expect(resultedOrder).toHaveProperty('subTotals', {
1086
1086
  '': 0,
1087
1087
  discount: -2.835,
1088
- null: 0,
1088
+ other: 0,
1089
1089
  tax: 0.675,
1090
1090
  });
1091
1091
 
@@ -230,7 +230,7 @@ module.exports = ({ _, utils, actions, modifierActions }) => {
230
230
  subTotals,
231
231
  amountToAdd: computedAmount,
232
232
  included,
233
- type,
233
+ type: type !== null ? type : `other`,
234
234
  direct,
235
235
  }));
236
236
 
@@ -150,6 +150,7 @@ module.exports = ({ actions, itemActions, modifierActions, settings, _ }) => {
150
150
 
151
151
  if (
152
152
  autoBarcode &&
153
+ !!item.autoSerial &&
153
154
  !orderItem.serial &&
154
155
  !itemActions.isRelatedItem(orderItem)
155
156
  ) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@darkpos/pricing",
3
- "version": "1.0.156",
3
+ "version": "1.0.158",
4
4
  "description": "Pricing calculator",
5
5
  "author": "Dark POS",
6
6
  "license": "ISC",
@@ -54,5 +54,5 @@
54
54
  "supertest": "^6.2.3",
55
55
  "supervisor": "^0.12.0"
56
56
  },
57
- "gitHead": "aa3707b920d84c4e8ad6066fb94120f22eee8f0a"
57
+ "gitHead": "e840d2d988ca8939b5492924588cb969c6f06424"
58
58
  }