@orderingstack/ordering-types 0.1.1 → 0.1.5

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.
@@ -1,3 +1,4 @@
1
+ export * from "./kiosk";
1
2
  export interface Restaurant {
2
3
  id: string;
3
4
  name: string;
@@ -269,9 +270,9 @@ export interface TaxSummary {
269
270
  brutto: number;
270
271
  }
271
272
  /**
272
- * IOrderExtra interface
273
+ * OrderExtra interface
273
274
  *
274
- * @interface IOrderExtra
275
+ * @interface OrderExtra
275
276
  * @manual-verify {string} order needs manual verification
276
277
  * @x-collect-time {string} estimated pickup time from aggregator
277
278
  * @courier-name {string} courier name from aggregator
@@ -296,6 +297,7 @@ export interface OrderExtra {
296
297
  allergies?: string;
297
298
  "x-agg-id"?: string;
298
299
  "support-order-id"?: string;
300
+ 'x-pos-id'?: string;
299
301
  }
300
302
  export interface OrderLog {
301
303
  timestamp?: string;
@@ -428,3 +430,35 @@ export interface VenueConfig {
428
430
  timeZone: string;
429
431
  warehouse: string;
430
432
  }
433
+ export interface IFiscalEntry {
434
+ discount: string;
435
+ item: string;
436
+ price: string;
437
+ qty: string;
438
+ total: string;
439
+ vat: string;
440
+ }
441
+ export interface IFiscalData {
442
+ amount: string;
443
+ entries: IFiscalEntry[];
444
+ payments: Partial<Record<OrderPaymentType, string>>;
445
+ timestamp: string;
446
+ }
447
+ /**
448
+ * @interface IFiscalizeData
449
+ * @timestamp {string} IsoString
450
+ *
451
+ */
452
+ export interface IFiscalizeData {
453
+ timestamp: string;
454
+ slip: string;
455
+ printer: string;
456
+ venue: string;
457
+ amount: number;
458
+ extra: {
459
+ FiscalReceiptId: string;
460
+ FiscalDateTime: string;
461
+ FiscalDeviceMemoryNo: string;
462
+ USN: string;
463
+ };
464
+ }
package/dist/cjs/index.js CHANGED
@@ -1,6 +1,21 @@
1
1
  "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
2
16
  Object.defineProperty(exports, "__esModule", { value: true });
3
17
  exports.EChannelName = exports.OrderProductKind = exports.OrderLineStatus = exports.OrderSource = exports.OrderPaymentType = exports.OrderStatus = exports.OrderType = exports.EProductKindBucket = exports.EProductKind = exports.CouponViewType = void 0;
18
+ __exportStar(require("./kiosk"), exports);
4
19
  var CouponViewType;
5
20
  (function (CouponViewType) {
6
21
  CouponViewType["CAROUSEL"] = "carousel";
@@ -0,0 +1,10 @@
1
+ export declare enum EPaymentStatus {
2
+ UNINITIALIZED = "UNINITIALIZED",
3
+ PROCESSING = "PROCESSING",
4
+ PAID = "PAID",
5
+ PRINTING_RECEIPT = "PRINTING_RECEIPT",
6
+ PRINTING_RECEIPT_SUCCESS = "PRINTING_RECEIPT_SUCCESS",
7
+ SENDING_RECEIPT = "SENDING_RECEIPT",
8
+ SENDING_RECEIPT_SUCCESS = "SENDING_RECEIPT_SUCCESS",
9
+ ERROR = "ERROR"
10
+ }
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.EPaymentStatus = void 0;
4
+ var EPaymentStatus;
5
+ (function (EPaymentStatus) {
6
+ EPaymentStatus["UNINITIALIZED"] = "UNINITIALIZED";
7
+ EPaymentStatus["PROCESSING"] = "PROCESSING";
8
+ EPaymentStatus["PAID"] = "PAID";
9
+ EPaymentStatus["PRINTING_RECEIPT"] = "PRINTING_RECEIPT";
10
+ EPaymentStatus["PRINTING_RECEIPT_SUCCESS"] = "PRINTING_RECEIPT_SUCCESS";
11
+ EPaymentStatus["SENDING_RECEIPT"] = "SENDING_RECEIPT";
12
+ EPaymentStatus["SENDING_RECEIPT_SUCCESS"] = "SENDING_RECEIPT_SUCCESS";
13
+ EPaymentStatus["ERROR"] = "ERROR";
14
+ })(EPaymentStatus = exports.EPaymentStatus || (exports.EPaymentStatus = {}));
@@ -1,3 +1,4 @@
1
+ export * from "./kiosk";
1
2
  export interface Restaurant {
2
3
  id: string;
3
4
  name: string;
@@ -269,9 +270,9 @@ export interface TaxSummary {
269
270
  brutto: number;
270
271
  }
271
272
  /**
272
- * IOrderExtra interface
273
+ * OrderExtra interface
273
274
  *
274
- * @interface IOrderExtra
275
+ * @interface OrderExtra
275
276
  * @manual-verify {string} order needs manual verification
276
277
  * @x-collect-time {string} estimated pickup time from aggregator
277
278
  * @courier-name {string} courier name from aggregator
@@ -296,6 +297,7 @@ export interface OrderExtra {
296
297
  allergies?: string;
297
298
  "x-agg-id"?: string;
298
299
  "support-order-id"?: string;
300
+ 'x-pos-id'?: string;
299
301
  }
300
302
  export interface OrderLog {
301
303
  timestamp?: string;
@@ -428,3 +430,35 @@ export interface VenueConfig {
428
430
  timeZone: string;
429
431
  warehouse: string;
430
432
  }
433
+ export interface IFiscalEntry {
434
+ discount: string;
435
+ item: string;
436
+ price: string;
437
+ qty: string;
438
+ total: string;
439
+ vat: string;
440
+ }
441
+ export interface IFiscalData {
442
+ amount: string;
443
+ entries: IFiscalEntry[];
444
+ payments: Partial<Record<OrderPaymentType, string>>;
445
+ timestamp: string;
446
+ }
447
+ /**
448
+ * @interface IFiscalizeData
449
+ * @timestamp {string} IsoString
450
+ *
451
+ */
452
+ export interface IFiscalizeData {
453
+ timestamp: string;
454
+ slip: string;
455
+ printer: string;
456
+ venue: string;
457
+ amount: number;
458
+ extra: {
459
+ FiscalReceiptId: string;
460
+ FiscalDateTime: string;
461
+ FiscalDeviceMemoryNo: string;
462
+ USN: string;
463
+ };
464
+ }
package/dist/esm/index.js CHANGED
@@ -1,3 +1,4 @@
1
+ export * from "./kiosk";
1
2
  export var CouponViewType;
2
3
  (function (CouponViewType) {
3
4
  CouponViewType["CAROUSEL"] = "carousel";
@@ -0,0 +1,10 @@
1
+ export declare enum EPaymentStatus {
2
+ UNINITIALIZED = "UNINITIALIZED",
3
+ PROCESSING = "PROCESSING",
4
+ PAID = "PAID",
5
+ PRINTING_RECEIPT = "PRINTING_RECEIPT",
6
+ PRINTING_RECEIPT_SUCCESS = "PRINTING_RECEIPT_SUCCESS",
7
+ SENDING_RECEIPT = "SENDING_RECEIPT",
8
+ SENDING_RECEIPT_SUCCESS = "SENDING_RECEIPT_SUCCESS",
9
+ ERROR = "ERROR"
10
+ }
@@ -0,0 +1,11 @@
1
+ export var EPaymentStatus;
2
+ (function (EPaymentStatus) {
3
+ EPaymentStatus["UNINITIALIZED"] = "UNINITIALIZED";
4
+ EPaymentStatus["PROCESSING"] = "PROCESSING";
5
+ EPaymentStatus["PAID"] = "PAID";
6
+ EPaymentStatus["PRINTING_RECEIPT"] = "PRINTING_RECEIPT";
7
+ EPaymentStatus["PRINTING_RECEIPT_SUCCESS"] = "PRINTING_RECEIPT_SUCCESS";
8
+ EPaymentStatus["SENDING_RECEIPT"] = "SENDING_RECEIPT";
9
+ EPaymentStatus["SENDING_RECEIPT_SUCCESS"] = "SENDING_RECEIPT_SUCCESS";
10
+ EPaymentStatus["ERROR"] = "ERROR";
11
+ })(EPaymentStatus || (EPaymentStatus = {}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@orderingstack/ordering-types",
3
- "version": "0.1.1",
3
+ "version": "0.1.5",
4
4
  "description": "Typescript types for @orderingstack",
5
5
  "types": "dist/esm/index.d.ts",
6
6
  "main": "dist/cjs/index.js",