@managesome/eposmatic-toolkit 0.2.227 → 0.2.229

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.
Files changed (35) hide show
  1. package/lib/constants/ENUMS.d.ts +11 -0
  2. package/lib/constants/ENUMS.js +15 -1
  3. package/lib/helpers/order/generate-order.js +5 -5
  4. package/lib/helpers/store/cart-actions.d.ts +1 -1
  5. package/lib/helpers/store/cart-actions.js +47 -5
  6. package/lib/helpers/store/common-order-actions.js +2 -2
  7. package/lib/helpers/types/cart-helpers.d.ts +6 -1
  8. package/lib/helpers/utils/cash_in_hand_transactions.d.ts +3 -0
  9. package/lib/helpers/utils/cash_in_hand_transactions.js +35 -0
  10. package/lib/helpers/utils/index.d.ts +1 -0
  11. package/lib/helpers/utils/index.js +1 -0
  12. package/lib/helpers/utils/receipt-engine.js +4 -4
  13. package/lib/helpers/utils/simplified-tenant.d.ts +10 -6
  14. package/lib/helpers/utils/simplified-tenant.js +23 -11
  15. package/lib/schemas/models/cash_in_hand_transactions.d.ts +62 -0
  16. package/lib/schemas/models/cash_in_hand_transactions.js +72 -0
  17. package/lib/schemas/models/index.d.ts +1 -0
  18. package/lib/schemas/models/index.js +1 -0
  19. package/lib/schemas/models/inventory_transactions.d.ts +6 -6
  20. package/lib/schemas/models/item_transactions.d.ts +3 -3
  21. package/lib/schemas/models/order.d.ts +12 -12
  22. package/lib/schemas/models/order.js +2 -2
  23. package/lib/schemas/models/tenant.d.ts +21 -9
  24. package/lib/schemas/models/tenant.js +19 -3
  25. package/lib/schemas/models/tenant_staff.d.ts +3 -3
  26. package/lib/schemas/models/wallet_transactions.d.ts +3 -3
  27. package/lib/schemas/models/warehouse_inventory_transactions.d.ts +6 -6
  28. package/lib/schemas/models/warehouse_item_transactions.d.ts +3 -3
  29. package/lib/schemas/types/cash_in_hand_transactions.d.ts +16 -0
  30. package/lib/schemas/types/cash_in_hand_transactions.js +2 -0
  31. package/lib/schemas/types/index.d.ts +1 -0
  32. package/lib/schemas/types/index.js +1 -0
  33. package/lib/schemas/types/order.d.ts +1 -1
  34. package/lib/schemas/types/tenant.d.ts +15 -3
  35. package/package.json +1 -1
@@ -999,6 +999,17 @@ export declare enum CASH_IN_OUT_TYPE_ENUM {
999
999
  CASH_OUT = "CASH_OUT"
1000
1000
  }
1001
1001
  export declare const ALL_CASH_IN_OUT_TYPES: CASH_IN_OUT_TYPE_ENUM[];
1002
+ export declare enum CASH_IN_HAND_TRANSACTION_TYPE_ENUM {
1003
+ INBOUND = "INBOUND",
1004
+ OUTBOUND = "OUTBOUND"
1005
+ }
1006
+ export declare const ALL_CASH_IN_HAND_TRANSACTION_TYPES: CASH_IN_HAND_TRANSACTION_TYPE_ENUM[];
1007
+ export declare enum CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM {
1008
+ TOP_UP = "TOP_UP",
1009
+ DEPOSIT = "DEPOSIT",
1010
+ ADJUST = "ADJUST"
1011
+ }
1012
+ export declare const ALL_CASH_IN_HAND_TRANSACTION_CATEGORIES: CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM[];
1002
1013
  export declare enum CASH_DRAWER_STATUS_ENUM {
1003
1014
  IN_USE = "IN_USE",
1004
1015
  CLOSED = "CLOSED"
@@ -4,7 +4,7 @@ exports.ALL_CATEGORY_DISPLAY_TYPES = exports.CATEGORY_DISPLAY_TYPE_ENUM = export
4
4
  exports.PRINTING_PREFERENCE_ENUM = exports.ALL_PRINTER_BRAND_TYPES = exports.PRINTER_BRAND_TYPE_ENUM = exports.ALL_ORDER_ITEM_TYPES = exports.ORDER_ITEM_TYPE_ENUM = exports.ALL_PLATFORM_PROVIDER_IDS = exports.PLATFORM_PROVIDER_IDS_ENUM = exports.ALL_MARKETING_RECEIPIENT_TYPES = exports.MARKETING_RECEIPIENT_ENUM = exports.ALL_MARKETING_TYPES = exports.MARKETING_TYPE_ENUM = exports.ALL_TOKEN_TYPES = exports.TOKEN_TYPE_ENUM = exports.ALL_EMAIL_PROCESSING_PROVIDERS = exports.EMAIL_PROCESSING_PROVIDERS_ENUM = exports.ALL_SMS_PROCESSING_PROVIDERS = exports.SMS_PROCESSING_PROVIDERS_ENUM = exports.ALL_TERMINAL_TYPES = exports.TERMINAL_TYPE_ENUM = exports.ALL_TERMINAL_PROCESSING_PROVIDERS = exports.TERMINAL_PROCESSING_PROVIDERS_ENUM = exports.TRANSACTION_TYPE_ENUM = exports.ALL_CARD_PROCESSING_PROVIDERS = exports.CARD_PROCESSING_PROVIDERS_ENUM = exports.ALL_PAYMENT_PROVIDERS = exports.PAYMENT_PROVIDERS_ENUM = exports.ALL_SUPPORT_SPECIALIST_PERMISSIONS = exports.ALL_MODERATOR_PERMISSIONS = exports.ALL_USER_PERMISSIONS = exports.USER_PERMISSIONS_ENUM = exports.ALL_OFFER_TYPES = exports.OFFER_TYPE_ENUM = exports.ALL_OFFER_USE_TYPES = exports.OFFER_USE_TYPE_ENUM = exports.ALL_OFFER_CODE_USAGE_TYPES = exports.OFFER_CODE_USAGE_TYPE_ENUM = exports.ALL_PATHWAY_TO_UNLOCK_TYPES = exports.PATHWAY_TO_UNLOCK_TYPE_ENUM = exports.ALL_OFFER_REWARD_TYPES = exports.OFFER_REWARD_TYPE_ENUM = exports.ALL_USER_ROLES = exports.USER_ROLES_ENUM = exports.ALL_PLATFORM_TYPES = exports.PLATFORM_TYPE_ENUM = exports.ALL_ORDER_NUMBER_GROUPING_TYPES = exports.ORDER_NUMBER_GROUPING_TYPE_ENUM = exports.ALL_TRACK_ORDER_NUMBER_TYPES = exports.TRACK_ORDER_NUMBER_ENUM = exports.ALL_TABLE_TYPES = exports.TABLE_TYPE_ENUM = void 0;
5
5
  exports.ALL_MULTI_TENANT_WEBSITE_TYPES = exports.MULTI_TENANT_WEBSITE_TYPE_ENUM = exports.ALL_TIME_RANGE_ENUMS = exports.TIME_RANGE_ENUM = exports.ALL_ITEM_TRANSACTION_TYPES = exports.ITEM_TRANSACTION_TYPE_ENUM = exports.INVENTORY_OUTBOUND_TRANSACTIONS = exports.INVENTORY_INBOUND_TRANSACTIONS = exports.ALL_INVENTORY_TRANSACTION_CATEGORIES = exports.INVENTORY_TRANSACTION_CATEGORY_ENUM = exports.ALL_INVENTORY_TRANSACTION_TYPES = exports.INVENTORY_TRANSACTION_TYPE_ENUM = exports.ALL_GST_TYPES = exports.GST_TYPE_ENUM = exports.ALL_EXPENSE_REACCURING_TYPES = exports.EXPENSE_REACCURING_TYPE_ENUM = exports.PAYMENT_EXTENSION_ENUM = exports.ALL_PRINTER_INTERFACES = exports.PRINTER_INTERFACE_ENUM = exports.RECEIPT_WIDTHS = exports.ALL_NUM_OF_COLUMNS = exports.NUM_OF_COLUMNS_ENUM = exports.SPLIT_SYNC_SOURCE_ENUM = exports.ALL_SPLIT_BILL_TYPES = exports.SPLIT_BILL_TYPE_ENUM = exports.ALL_RIDER_FEE_TYPES = exports.RIDER_FEE_TYPE_ENUM = exports.ALL_DELIVERY_AREAS_SEARCH_TYPES = exports.DELIVERY_AREAS_SEARCH_TYPE_ENUM = exports.ALL_WEB_AUTH_TYPES = exports.WEB_AUTH_TYPE_ENUM = exports.KITCHEN_RECEIPT_TYPE_ENUM = exports.PRINTER_EVENT_TYPE_ENUM = exports.SORT_TYPE_ENUM = exports.BLACKLISTED_SMS_COUNTRY_CODES = exports.ALL_OTP_TYPES = exports.OTP_TYPE_ENUM = exports.ALL_TAX_INVOICE_PROVIDERS = exports.TAX_INVOICE_PROVIDER_ENUM = exports.ALL_RESERVATION_STATUS_TYPES = exports.RESERVATION_STATUS_ENUM = exports.TENANT_AMOUNT_DUE_TYPE_ENUM = exports.ALL_KITCHEN_DOCKET_FONT_TYPES = exports.KITCHEN_DOCKET_FONT_TYPE_ENUM = exports.ALL_SORT_ORDER_BY_TYPES = exports.SORT_ORDER_BY_ENUM = exports.RECEIPT_IMAGE_TYPE_ENUM = exports.ALL_RECEIPT_TYPES = exports.RECEIPT_TYPE_ENUM = exports.ALL_PRINTING_PREFERENCES = void 0;
6
6
  exports.ALL_CASH_IN_OUT_TYPES = exports.CASH_IN_OUT_TYPE_ENUM = exports.ALL_POS_SHIFT_STATUS = exports.POS_SHIFT_STATUS_ENUM = exports.ALL_POS_DAY_STATUS = exports.POS_DAY_STATUS_ENUM = exports.ALL_MODIFIER_OPTION_REF_TYPES = exports.MODIFIER_OPTION_REF_TYPE_ENUM = exports.ALL_WAREHOUSE_CLIENT_TYPES = exports.WAREHOUSE_CLIENT_TYPE_ENUM = exports.ALL_ONLINE_ORDERING_DESIGN_TYPES = exports.ONLINE_ORDERING_DESIGN_TYPE_ENUM = exports.ALL_NOTIFICATION_PROVIDERS = exports.NOTIFICATION_PROVIDER_ENUM = exports.ALL_ORDER_COMPLETION_TYPES = exports.ORDER_COMPLETION_TYPE_ENUM = exports.ITEM_COMPARISON_FIELD_ENUM = exports.VOID_ITEM_STAFF_REPORT_ENUM = exports.ALL_DISCOUNT_APPLICABILITY_TYPES = exports.DISCOUNT_APPLICABILITY_ENUM = exports.ALL_DISCOUNT_TYPES = exports.DISCOUNT_TYPE_ENUM = exports.EMAIL_TEMPLATES_TYPE_ENUM = exports.ALL_ALERT_NOTIFICATIONS_TYPES = exports.ALERT_NOTIFICATIONS_TYPE_ENUM = exports.ALL_WALLET_TRANSACTION_STATUS = exports.WALLET_TRANSACTION_STATUS_ENUM = exports.ALL_WALLET_TRANSACTION_CATEGORIES = exports.WALLET_TRANSACTION_CATEGORY_ENUM = exports.ALL_WALLET_TRANSACTION_TYPES = exports.WALLET_TRANSACTION_TYPE_ENUM = exports.ALL_WAREHOUSE_SUPPORT_SPECIALIST_PERMISSIONS = exports.ALL_WAREHOUSE_MODERATOR_PERMISSIONS = exports.ALL_WAREHOUSE_USER_PERMISSIONS = exports.WAREHOUSE_USER_PERMISSIONS_ENUM = exports.ALL_WAREHOUSE_INVOICE_STATUS_NAMES = exports.WAREHOUSE_INVOICE_STATUS_ENUM = exports.ALL_PURCHASE_ORDER_STATUS_NAMES = exports.PURCHASE_ORDER_STATUS_ENUM = exports.ALL_DELIVERY_STATUS = exports.DELIVERY_STATUS_ENUM = exports.ALL_INVENTORY_ITEM_TYPES = exports.INVENTORY_ITEM_TYPE_ENUM = exports.ALL_RATING_TYPES = exports.RATING_TYPE_ENUM = exports.ALL_SUBSCRIPTION_STATUS = exports.SUBSCRIPTION_STATUS_ENUM = exports.ALL_VOID_ORDER_ITEM_TYPES = exports.VOID_ORDER_ITEM_TYPE_ENUM = exports.COMPARISON_REPORT_TYPE_ENUM = void 0;
7
- exports.ALL_INTERNAL_LEAD_STATUS = exports.INTERNAL_LEAD_STATUS_ENUM = exports.ALL_INTERNAL_LEAD_SOURCES = exports.INTERNAL_LEAD_SOURCE_ENUM = exports.ALL_CASH_DRAWER_STATUS = exports.CASH_DRAWER_STATUS_ENUM = void 0;
7
+ exports.ALL_INTERNAL_LEAD_STATUS = exports.INTERNAL_LEAD_STATUS_ENUM = exports.ALL_INTERNAL_LEAD_SOURCES = exports.INTERNAL_LEAD_SOURCE_ENUM = exports.ALL_CASH_DRAWER_STATUS = exports.CASH_DRAWER_STATUS_ENUM = exports.ALL_CASH_IN_HAND_TRANSACTION_CATEGORIES = exports.CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM = exports.ALL_CASH_IN_HAND_TRANSACTION_TYPES = exports.CASH_IN_HAND_TRANSACTION_TYPE_ENUM = void 0;
8
8
  var ORDER_FROM_ENUM;
9
9
  (function (ORDER_FROM_ENUM) {
10
10
  ORDER_FROM_ENUM["WEB"] = "WEB";
@@ -1687,6 +1687,20 @@ var CASH_IN_OUT_TYPE_ENUM;
1687
1687
  })(CASH_IN_OUT_TYPE_ENUM || (exports.CASH_IN_OUT_TYPE_ENUM = CASH_IN_OUT_TYPE_ENUM = {}));
1688
1688
  exports.ALL_CASH_IN_OUT_TYPES = Object.values(CASH_IN_OUT_TYPE_ENUM);
1689
1689
  // ======================>> <<====================== //
1690
+ var CASH_IN_HAND_TRANSACTION_TYPE_ENUM;
1691
+ (function (CASH_IN_HAND_TRANSACTION_TYPE_ENUM) {
1692
+ CASH_IN_HAND_TRANSACTION_TYPE_ENUM["INBOUND"] = "INBOUND";
1693
+ CASH_IN_HAND_TRANSACTION_TYPE_ENUM["OUTBOUND"] = "OUTBOUND";
1694
+ })(CASH_IN_HAND_TRANSACTION_TYPE_ENUM || (exports.CASH_IN_HAND_TRANSACTION_TYPE_ENUM = CASH_IN_HAND_TRANSACTION_TYPE_ENUM = {}));
1695
+ exports.ALL_CASH_IN_HAND_TRANSACTION_TYPES = Object.values(CASH_IN_HAND_TRANSACTION_TYPE_ENUM);
1696
+ var CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM;
1697
+ (function (CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM) {
1698
+ CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM["TOP_UP"] = "TOP_UP";
1699
+ CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM["DEPOSIT"] = "DEPOSIT";
1700
+ CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM["ADJUST"] = "ADJUST";
1701
+ })(CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM || (exports.CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM = CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM = {}));
1702
+ exports.ALL_CASH_IN_HAND_TRANSACTION_CATEGORIES = Object.values(CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM);
1703
+ // ======================>> <<====================== //
1690
1704
  var CASH_DRAWER_STATUS_ENUM;
1691
1705
  (function (CASH_DRAWER_STATUS_ENUM) {
1692
1706
  CASH_DRAWER_STATUS_ENUM["IN_USE"] = "IN_USE";
@@ -204,8 +204,8 @@ function generateOrderOnCreate(order, withIterations) {
204
204
  if (!newOrder.tax_invoice_provider_charges) {
205
205
  delete newOrder.tax_invoice_provider_charges;
206
206
  }
207
- if (!newOrder.packaging_fee) {
208
- delete newOrder.packaging_fee;
207
+ if (!newOrder.packaging_charges) {
208
+ delete newOrder.packaging_charges;
209
209
  }
210
210
  if (!newOrder.adjustment_amount) {
211
211
  delete newOrder.adjustment_amount;
@@ -397,9 +397,9 @@ function generateOrderOnUpdate(partialUpdatedOrder) {
397
397
  delete set.tax_invoice_provider_charges;
398
398
  unset['tax_invoice_provider_charges'] = '';
399
399
  }
400
- if (set.packaging_fee === 0) {
401
- delete set.packaging_fee;
402
- unset['packaging_fee'] = '';
400
+ if (set.packaging_charges === 0) {
401
+ delete set.packaging_charges;
402
+ unset['packaging_charges'] = '';
403
403
  }
404
404
  if (set.adjustment_amount == null || set.adjustment_amount === 0) {
405
405
  delete set.adjustment_amount;
@@ -131,7 +131,7 @@ export declare function getChangeCourseStatusData(data: Partial<IOrder>, course_
131
131
  service_fee_amount?: number | undefined;
132
132
  gst?: number | undefined;
133
133
  gst_amount?: number | undefined;
134
- packaging_fee?: number | undefined;
134
+ packaging_charges?: number | undefined;
135
135
  adjustment_amount?: number | null | undefined;
136
136
  adjustment_reason?: string | null | undefined;
137
137
  tax_invoice_provider_charges?: number | undefined;
@@ -381,6 +381,46 @@ function calculateCartOrderInfoAndSyncData(data, courses, listnerSettings, calcu
381
381
  // A discount in this case can be both negative or positive
382
382
  // So in actual, payable price is the price of all items after applying all discounts and surcharges
383
383
  const payablePrice = subtotal - orderDiscount;
384
+ const isDineInOrder = constants_1.PLATFORMS_BY_ORDER_TYPE[constants_1.ORDER_TYPE_ENUM.DINE_IN].includes(data.platform);
385
+ const isDeliveryOrder = constants_1.PLATFORMS_BY_ORDER_TYPE.DELIVERY.includes(data.platform);
386
+ const isTakeawayOrder = constants_1.PLATFORMS_BY_ORDER_TYPE[constants_1.ORDER_TYPE_ENUM.TAKE_AWAY].includes(data.platform);
387
+ const isPackagingOrder = isDeliveryOrder || isTakeawayOrder;
388
+ let service_fee = data.service_fee ?? 0;
389
+ if (listnerSettings != null) {
390
+ if (!isDineInOrder) {
391
+ service_fee = 0;
392
+ }
393
+ else if (listnerSettings.min_service_fee_order_value > 0 &&
394
+ payablePrice < listnerSettings.min_service_fee_order_value) {
395
+ service_fee = 0;
396
+ }
397
+ else {
398
+ service_fee = listnerSettings.dinein_service_fee ?? service_fee;
399
+ }
400
+ }
401
+ else if (!isDineInOrder) {
402
+ service_fee = 0;
403
+ }
404
+ let packaging_charges = data.packaging_charges ?? 0;
405
+ if (listnerSettings != null) {
406
+ if (!isPackagingOrder) {
407
+ packaging_charges = 0;
408
+ }
409
+ else if (listnerSettings.min_packaging_charges_order_value > 0 &&
410
+ payablePrice < listnerSettings.min_packaging_charges_order_value) {
411
+ packaging_charges = 0;
412
+ }
413
+ else if (listnerSettings.packaging_charges_free_over > 0 &&
414
+ payablePrice >= listnerSettings.packaging_charges_free_over) {
415
+ packaging_charges = 0;
416
+ }
417
+ else {
418
+ packaging_charges = listnerSettings.packaging_charges ?? packaging_charges;
419
+ }
420
+ }
421
+ else if (!isPackagingOrder) {
422
+ packaging_charges = 0;
423
+ }
384
424
  // Original items price is the price of all items without any discount
385
425
  // A discount in this case can only be positive
386
426
  const originalItemsPrice = subtotal + totalItemsDiscount;
@@ -394,14 +434,14 @@ function calculateCartOrderInfoAndSyncData(data, courses, listnerSettings, calcu
394
434
  surcharge_amount = getSurchargeAmount(payablePrice, data.surcharge, data.is_surcharge_percentage);
395
435
  grand_total += surcharge_amount;
396
436
  }
397
- let service_fee_amount = data.service_fee;
437
+ let service_fee_amount = service_fee;
398
438
  if (data.is_service_fee_taxable) {
399
439
  const p = data.apply_service_fee_on_original_price ? originalItemsPrice : payablePrice;
400
440
  // Commented out because service fee does not apply on surcharge
401
441
  // if (surcharge_amount) {
402
442
  // p += surcharge_amount;
403
443
  // }
404
- service_fee_amount = getServiceFeeAmount(p, data.service_fee, data.is_service_fee_percentage);
444
+ service_fee_amount = getServiceFeeAmount(p, service_fee, data.is_service_fee_percentage);
405
445
  grand_total += service_fee_amount;
406
446
  }
407
447
  // GST is represented in percentage. We convert it to decimal
@@ -436,7 +476,7 @@ function calculateCartOrderInfoAndSyncData(data, courses, listnerSettings, calcu
436
476
  // if (surcharge_amount) {
437
477
  // p += surcharge_amount;
438
478
  // }
439
- service_fee_amount = getServiceFeeAmount(p, data.service_fee, data.is_service_fee_percentage);
479
+ service_fee_amount = getServiceFeeAmount(p, service_fee, data.is_service_fee_percentage);
440
480
  grand_total += service_fee_amount;
441
481
  }
442
482
  // ===============================><===============================
@@ -456,7 +496,7 @@ function calculateCartOrderInfoAndSyncData(data, courses, listnerSettings, calcu
456
496
  }
457
497
  grand_total += delivery_cost;
458
498
  // Add packaging fee to grand_total
459
- grand_total += data.packaging_fee ?? 0;
499
+ grand_total += packaging_charges;
460
500
  // Add adjustment amount (can be positive or negative)
461
501
  grand_total += data.adjustment_amount ?? 0;
462
502
  // TODO: We are not using tax_amount for now
@@ -527,7 +567,7 @@ function calculateCartOrderInfoAndSyncData(data, courses, listnerSettings, calcu
527
567
  originalItemsPrice,
528
568
  payablePrice,
529
569
  subtotal: item.subtotal,
530
- service_fee: data.service_fee,
570
+ service_fee,
531
571
  surcharge: data.surcharge,
532
572
  totalItemsDiscount: itemDiscountAmount,
533
573
  totalOrderDiscount: orderDiscountAmount,
@@ -568,6 +608,8 @@ function calculateCartOrderInfoAndSyncData(data, courses, listnerSettings, calcu
568
608
  tax_invoice_provider_charges,
569
609
  gst_amount,
570
610
  price: (0, utils_1.parseNum)(originalItemsPrice),
611
+ service_fee,
612
+ packaging_charges,
571
613
  grand_total,
572
614
  };
573
615
  // ===============================><===============================
@@ -145,7 +145,7 @@ function getOrderWithPrice(order, toCents) {
145
145
  ...(order.tip_amount != null ? { tip_amount: convertToPrice(order.tip_amount) } : {}),
146
146
  ...(order.service_fee != null ? { service_fee: convertToPrice(order.service_fee) } : {}),
147
147
  ...(order.service_fee_amount != null ? { service_fee_amount: convertToPrice(order.service_fee_amount) } : {}),
148
- ...(order.packaging_fee != null ? { packaging_fee: convertToPrice(order.packaging_fee) } : {}),
148
+ ...(order.packaging_charges != null ? { packaging_charges: convertToPrice(order.packaging_charges) } : {}),
149
149
  ...(order.adjustment_amount != null ? { adjustment_amount: convertToPrice(order.adjustment_amount) } : {}),
150
150
  ...(order.tax_amount != null ? { tax_amount: convertToPrice(order.tax_amount) } : {}),
151
151
  ...(order.gst != null ? { gst: convertToPrice(order.gst) } : {}),
@@ -231,7 +231,7 @@ function getCommonOptionalNumFields(order, partial) {
231
231
  service_fee_amount: order['service_fee_amount'] || defaultValue,
232
232
  gst: order['gst'] || defaultValue,
233
233
  gst_amount: order['gst_amount'] || defaultValue,
234
- packaging_fee: order['packaging_fee'] || defaultValue,
234
+ packaging_charges: order['packaging_charges'] || defaultValue,
235
235
  adjustment_amount: order['adjustment_amount'] || defaultValue,
236
236
  tax_invoice_provider_charges: order['tax_invoice_provider_charges'] || defaultValue,
237
237
  total_discount_applied: order['total_discount_applied'] || defaultValue,
@@ -1,7 +1,12 @@
1
1
  import { TAX_INVOICE_PROVIDER_ENUM } from '../../constants';
2
2
  export interface ICartListnerSettings {
3
+ tax_invoice_provider: TAX_INVOICE_PROVIDER_ENUM;
3
4
  delivery_free_over: number;
4
5
  delivery_min_cost: number;
5
6
  delivery_min_order_value: number;
6
- tax_invoice_provider: TAX_INVOICE_PROVIDER_ENUM;
7
+ dinein_service_fee: number;
8
+ min_service_fee_order_value: number;
9
+ packaging_charges: number;
10
+ min_packaging_charges_order_value: number;
11
+ packaging_charges_free_over: number;
7
12
  }
@@ -0,0 +1,3 @@
1
+ import { ICashInHandTransaction } from '../../schemas';
2
+ export declare function getCashInHandTransactionWithInt<T extends Partial<ICashInHandTransaction> | ICashInHandTransaction>(transaction: T): T;
3
+ export declare function getCashInHandTransactionWithDecimal<T extends Partial<ICashInHandTransaction> | ICashInHandTransaction>(transaction: T): T;
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getCashInHandTransactionWithInt = getCashInHandTransactionWithInt;
4
+ exports.getCashInHandTransactionWithDecimal = getCashInHandTransactionWithDecimal;
5
+ const price_conversion_1 = require("./price-conversion");
6
+ function getCashInHandTransactionWithInt(transaction) {
7
+ return {
8
+ ...transaction,
9
+ ...(typeof transaction.prev_cash_in_hand === 'number'
10
+ ? {
11
+ prev_cash_in_hand: (0, price_conversion_1.convertDecimalToInt)(transaction.prev_cash_in_hand),
12
+ }
13
+ : {}),
14
+ ...(typeof transaction.cash_in_hand === 'number'
15
+ ? {
16
+ cash_in_hand: (0, price_conversion_1.convertDecimalToInt)(transaction.cash_in_hand),
17
+ }
18
+ : {}),
19
+ };
20
+ }
21
+ function getCashInHandTransactionWithDecimal(transaction) {
22
+ return {
23
+ ...transaction,
24
+ ...(typeof transaction.prev_cash_in_hand === 'number'
25
+ ? {
26
+ prev_cash_in_hand: (0, price_conversion_1.convertIntToDecimal)(transaction.prev_cash_in_hand),
27
+ }
28
+ : {}),
29
+ ...(typeof transaction.cash_in_hand === 'number'
30
+ ? {
31
+ cash_in_hand: (0, price_conversion_1.convertIntToDecimal)(transaction.cash_in_hand),
32
+ }
33
+ : {}),
34
+ };
35
+ }
@@ -1,4 +1,5 @@
1
1
  export * from './cart-helpers';
2
+ export * from './cash_in_hand_transactions';
2
3
  export * from './catalog-conversion';
3
4
  export * from './color-helpers';
4
5
  export * from './common';
@@ -15,6 +15,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./cart-helpers"), exports);
18
+ __exportStar(require("./cash_in_hand_transactions"), exports);
18
19
  __exportStar(require("./catalog-conversion"), exports);
19
20
  __exportStar(require("./color-helpers"), exports);
20
21
  __exportStar(require("./common"), exports);
@@ -179,15 +179,15 @@ function getReceiptEngineFooterDetails(order, settings) {
179
179
  });
180
180
  }
181
181
  // 12. Packaging Fee
182
- if (order.packaging_fee != null && order.packaging_fee !== 0) {
183
- const right = (0, common_1.localeAmount)(currencySymbol, order.packaging_fee);
182
+ if (order.packaging_charges) {
183
+ const right = (0, common_1.localeAmount)(currencySymbol, order.packaging_charges);
184
184
  details.push({
185
- left: 'Packaging Fee',
185
+ left: 'Packaging Charges',
186
186
  right,
187
187
  });
188
188
  }
189
189
  // 13. Adjustment
190
- if (order.adjustment_amount != null && order.adjustment_amount !== 0) {
190
+ if (order.adjustment_amount) {
191
191
  const right = (0, common_1.localeAmount)(currencySymbol, order.adjustment_amount);
192
192
  let reason = '';
193
193
  if (order.adjustment_reason != null && order.adjustment_reason.length < 20) {
@@ -41,9 +41,9 @@ export interface ISettingsForWeb {
41
41
  delivery_cost_per_meter: ITenant['delivery_cost_per_meter'];
42
42
  delivery_free_over: ITenant['delivery_free_over'];
43
43
  min_service_fee_order_value: ITenant['min_service_fee_order_value'];
44
- packaging_fee: ITenant['packaging_fee'];
45
- min_packaging_fee_order_value: ITenant['min_packaging_fee_order_value'];
46
- free_packaging_over: ITenant['free_packaging_over'];
44
+ packaging_charges: ITenant['packaging_charges'];
45
+ min_packaging_charges_order_value: ITenant['min_packaging_charges_order_value'];
46
+ packaging_charges_free_over: ITenant['packaging_charges_free_over'];
47
47
  cash_in_hand_limit: ITenant['cash_in_hand_limit'];
48
48
  brand_color: ITenant['brand_color'];
49
49
  restaurant_address: ITenant['restaurant_address'];
@@ -100,6 +100,10 @@ export interface ISettingsForWeb {
100
100
  max_preorder_takeaway_minutes: ITenant['max_preorder_takeaway_minutes'];
101
101
  default_prep_minutes: ITenant['default_prep_minutes'];
102
102
  web_enable_pre_ordering: ITenant['web_enable_pre_ordering'];
103
+ fb_link?: ITenant['fb_link'];
104
+ instagram_link?: ITenant['instagram_link'];
105
+ twitter_link?: ITenant['twitter_link'];
106
+ tiktok_link?: ITenant['tiktok_link'];
103
107
  }
104
108
  export declare function getSettingsForWeb(settings: ITenant): ISettingsForWeb;
105
109
  export interface ISettingsForPOS {
@@ -144,9 +148,9 @@ export interface ISettingsForPOS {
144
148
  min_delivery_order_value: ITenant['min_delivery_order_value'];
145
149
  delivery_order_value_per_meter: ITenant['delivery_order_value_per_meter'];
146
150
  min_service_fee_order_value: ITenant['min_service_fee_order_value'];
147
- packaging_fee: ITenant['packaging_fee'];
148
- free_packaging_over: ITenant['free_packaging_over'];
149
- min_packaging_fee_order_value: ITenant['min_packaging_fee_order_value'];
151
+ packaging_charges: ITenant['packaging_charges'];
152
+ packaging_charges_free_over: ITenant['packaging_charges_free_over'];
153
+ min_packaging_charges_order_value: ITenant['min_packaging_charges_order_value'];
150
154
  cash_in_hand_limit: ITenant['cash_in_hand_limit'];
151
155
  delivery_areas_search_type: ITenant['delivery_areas_search_type'];
152
156
  static_delivery_cost_multiplier: ITenant['static_delivery_cost_multiplier'];
@@ -37,12 +37,12 @@ function getSettingsWithPrice(settings, writeable) {
37
37
  ...(settings.min_service_fee_order_value != null
38
38
  ? { min_service_fee_order_value: convertToPrice(settings.min_service_fee_order_value) }
39
39
  : {}),
40
- ...(settings.packaging_fee != null ? { packaging_fee: convertToPrice(settings.packaging_fee) } : {}),
41
- ...(settings.free_packaging_over != null
42
- ? { free_packaging_over: convertToPrice(settings.free_packaging_over) }
40
+ ...(settings.packaging_charges != null ? { packaging_charges: convertToPrice(settings.packaging_charges) } : {}),
41
+ ...(settings.packaging_charges_free_over != null
42
+ ? { packaging_charges_free_over: convertToPrice(settings.packaging_charges_free_over) }
43
43
  : {}),
44
- ...(settings.min_packaging_fee_order_value != null
45
- ? { min_packaging_fee_order_value: convertToPrice(settings.min_packaging_fee_order_value) }
44
+ ...(settings.min_packaging_charges_order_value != null
45
+ ? { min_packaging_charges_order_value: convertToPrice(settings.min_packaging_charges_order_value) }
46
46
  : {}),
47
47
  ...(settings.cash_in_hand_limit != null ? { cash_in_hand_limit: convertToPrice(settings.cash_in_hand_limit) } : {}),
48
48
  // ========================================
@@ -137,9 +137,9 @@ function getSettingsForWeb(settings) {
137
137
  delivery_cost_per_meter: settings.delivery_cost_per_meter,
138
138
  delivery_free_over: settings.delivery_free_over,
139
139
  min_service_fee_order_value: settings.min_service_fee_order_value,
140
- packaging_fee: settings.packaging_fee,
141
- free_packaging_over: settings.free_packaging_over,
142
- min_packaging_fee_order_value: settings.min_packaging_fee_order_value,
140
+ packaging_charges: settings.packaging_charges,
141
+ packaging_charges_free_over: settings.packaging_charges_free_over,
142
+ min_packaging_charges_order_value: settings.min_packaging_charges_order_value,
143
143
  cash_in_hand_limit: settings.cash_in_hand_limit,
144
144
  brand_color: settings.brand_color,
145
145
  restaurant_address: settings.restaurant_address,
@@ -196,6 +196,10 @@ function getSettingsForWeb(settings) {
196
196
  max_preorder_takeaway_minutes: settings.max_preorder_takeaway_minutes,
197
197
  default_prep_minutes: settings.default_prep_minutes,
198
198
  web_enable_pre_ordering: settings.web_enable_pre_ordering,
199
+ fb_link: settings.fb_link,
200
+ instagram_link: settings.instagram_link,
201
+ twitter_link: settings.twitter_link,
202
+ tiktok_link: settings.tiktok_link,
199
203
  };
200
204
  }
201
205
  function getSettingsForPOS(settings) {
@@ -241,9 +245,9 @@ function getSettingsForPOS(settings) {
241
245
  min_delivery_order_value: settings.min_delivery_order_value,
242
246
  delivery_order_value_per_meter: settings.delivery_order_value_per_meter,
243
247
  min_service_fee_order_value: settings.min_service_fee_order_value,
244
- packaging_fee: settings.packaging_fee,
245
- free_packaging_over: settings.free_packaging_over,
246
- min_packaging_fee_order_value: settings.min_packaging_fee_order_value,
248
+ packaging_charges: settings.packaging_charges,
249
+ packaging_charges_free_over: settings.packaging_charges_free_over,
250
+ min_packaging_charges_order_value: settings.min_packaging_charges_order_value,
247
251
  cash_in_hand_limit: settings.cash_in_hand_limit,
248
252
  delivery_areas_search_type: settings.delivery_areas_search_type,
249
253
  static_delivery_cost_multiplier: settings.static_delivery_cost_multiplier,
@@ -352,6 +356,10 @@ function getTenantOnlineOrderingMetadataFromTenant(tenant) {
352
356
  brand_color: tenant.brand_color,
353
357
  business_type: tenant.business_type,
354
358
  city: tenant.city,
359
+ fb_link: tenant.fb_link,
360
+ instagram_link: tenant.instagram_link,
361
+ twitter_link: tenant.twitter_link,
362
+ tiktok_link: tenant.tiktok_link,
355
363
  };
356
364
  }
357
365
  function getBrandOnlineOrderingMetadataFromTenant(brand, tenant) {
@@ -364,5 +372,9 @@ function getBrandOnlineOrderingMetadataFromTenant(brand, tenant) {
364
372
  business_type: tenant.business_type,
365
373
  store_description: tenant.store_description,
366
374
  web_favicon: tenant.web_favicon,
375
+ fb_link: tenant.fb_link,
376
+ instagram_link: tenant.instagram_link,
377
+ twitter_link: tenant.twitter_link,
378
+ tiktok_link: tenant.tiktok_link,
367
379
  };
368
380
  }
@@ -0,0 +1,62 @@
1
+ import { Schema } from 'mongoose';
2
+ export declare const CashInHandTransactionsSchema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, {
3
+ timestamps: true;
4
+ versionKey: false;
5
+ minimize: false;
6
+ }, {
7
+ createdAt: NativeDate;
8
+ updatedAt: NativeDate;
9
+ } & {
10
+ _id: import("mongoose").Types.ObjectId;
11
+ tenant_id: string;
12
+ staff_id: string;
13
+ staff_name: string;
14
+ createdAt: NativeDate;
15
+ updatedAt: NativeDate;
16
+ note: string;
17
+ processed_by_id: string;
18
+ processed_by_name: string;
19
+ prev_cash_in_hand: number;
20
+ cash_in_hand: number;
21
+ transaction_type: import("../../constants").CASH_IN_HAND_TRANSACTION_TYPE_ENUM;
22
+ transaction_category: import("../../constants").CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM;
23
+ }, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
24
+ createdAt: NativeDate;
25
+ updatedAt: NativeDate;
26
+ } & {
27
+ _id: import("mongoose").Types.ObjectId;
28
+ tenant_id: string;
29
+ staff_id: string;
30
+ staff_name: string;
31
+ createdAt: NativeDate;
32
+ updatedAt: NativeDate;
33
+ note: string;
34
+ processed_by_id: string;
35
+ processed_by_name: string;
36
+ prev_cash_in_hand: number;
37
+ cash_in_hand: number;
38
+ transaction_type: import("../../constants").CASH_IN_HAND_TRANSACTION_TYPE_ENUM;
39
+ transaction_category: import("../../constants").CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM;
40
+ }>> & import("mongoose").FlatRecord<{
41
+ createdAt: NativeDate;
42
+ updatedAt: NativeDate;
43
+ } & {
44
+ _id: import("mongoose").Types.ObjectId;
45
+ tenant_id: string;
46
+ staff_id: string;
47
+ staff_name: string;
48
+ createdAt: NativeDate;
49
+ updatedAt: NativeDate;
50
+ note: string;
51
+ processed_by_id: string;
52
+ processed_by_name: string;
53
+ prev_cash_in_hand: number;
54
+ cash_in_hand: number;
55
+ transaction_type: import("../../constants").CASH_IN_HAND_TRANSACTION_TYPE_ENUM;
56
+ transaction_category: import("../../constants").CASH_IN_HAND_TRANSACTION_CATEGORY_ENUM;
57
+ }> & Required<{
58
+ _id: import("mongoose").Types.ObjectId;
59
+ }> & {
60
+ __v: number;
61
+ }>;
62
+ export declare const CASH_IN_HAND_TRANSACTIONS_COLLECTION_NAME = "cash_in_hand_transactions";
@@ -0,0 +1,72 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CASH_IN_HAND_TRANSACTIONS_COLLECTION_NAME = exports.CashInHandTransactionsSchema = void 0;
4
+ const mongoose_1 = require("mongoose");
5
+ const constants_1 = require("../../constants");
6
+ exports.CashInHandTransactionsSchema = new mongoose_1.Schema({
7
+ _id: {
8
+ type: mongoose_1.Schema.Types.ObjectId,
9
+ required: true,
10
+ immutable: true,
11
+ },
12
+ tenant_id: {
13
+ type: String,
14
+ required: true,
15
+ immutable: true,
16
+ ref: 'tenants',
17
+ },
18
+ staff_id: {
19
+ type: String,
20
+ required: true,
21
+ },
22
+ staff_name: {
23
+ type: String,
24
+ required: true,
25
+ },
26
+ processed_by_id: {
27
+ type: String,
28
+ required: true,
29
+ },
30
+ processed_by_name: {
31
+ type: String,
32
+ required: true,
33
+ },
34
+ prev_cash_in_hand: {
35
+ type: Number,
36
+ required: true,
37
+ },
38
+ cash_in_hand: {
39
+ type: Number,
40
+ required: true,
41
+ },
42
+ transaction_type: {
43
+ type: String,
44
+ enum: constants_1.ALL_CASH_IN_HAND_TRANSACTION_TYPES,
45
+ required: true,
46
+ },
47
+ transaction_category: {
48
+ type: String,
49
+ enum: constants_1.ALL_CASH_IN_HAND_TRANSACTION_CATEGORIES,
50
+ required: true,
51
+ },
52
+ note: {
53
+ type: String,
54
+ default: '',
55
+ },
56
+ createdAt: {
57
+ type: mongoose_1.Schema.Types.Date,
58
+ required: true,
59
+ default: () => new Date(),
60
+ immutable: true,
61
+ },
62
+ updatedAt: {
63
+ type: mongoose_1.Schema.Types.Date,
64
+ required: true,
65
+ default: () => new Date(),
66
+ },
67
+ }, {
68
+ timestamps: true,
69
+ versionKey: false,
70
+ minimize: false,
71
+ });
72
+ exports.CASH_IN_HAND_TRANSACTIONS_COLLECTION_NAME = 'cash_in_hand_transactions';
@@ -3,6 +3,7 @@ export * from './applied-order-discounts';
3
3
  export * from './brand';
4
4
  export * from './cash_drawer_sessions';
5
5
  export * from './cash_drawers';
6
+ export * from './cash_in_hand_transactions';
6
7
  export * from './cash_in_out';
7
8
  export * from './category';
8
9
  export * from './close_dates';
@@ -19,6 +19,7 @@ __exportStar(require("./applied-order-discounts"), exports);
19
19
  __exportStar(require("./brand"), exports);
20
20
  __exportStar(require("./cash_drawer_sessions"), exports);
21
21
  __exportStar(require("./cash_drawers"), exports);
22
+ __exportStar(require("./cash_in_hand_transactions"), exports);
22
23
  __exportStar(require("./cash_in_out"), exports);
23
24
  __exportStar(require("./category"), exports);
24
25
  __exportStar(require("./close_dates"), exports);
@@ -12,6 +12,8 @@ export declare const InventoryTransactionsSchema: Schema<any, import("mongoose")
12
12
  createdAt_mins: number;
13
13
  createdAt: NativeDate;
14
14
  updatedAt: NativeDate;
15
+ transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
16
+ transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
15
17
  inventory_code: string;
16
18
  quantity_left: number;
17
19
  unit_price: number;
@@ -20,8 +22,6 @@ export declare const InventoryTransactionsSchema: Schema<any, import("mongoose")
20
22
  previous_quantity_left: number;
21
23
  previous_unit_price: number;
22
24
  previous_remaining_stock_price: number;
23
- transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
24
- transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
25
25
  order_id?: import("mongoose").Types.ObjectId | null | undefined;
26
26
  description?: string | null | undefined;
27
27
  order_number?: number | null | undefined;
@@ -36,6 +36,8 @@ export declare const InventoryTransactionsSchema: Schema<any, import("mongoose")
36
36
  createdAt_mins: number;
37
37
  createdAt: NativeDate;
38
38
  updatedAt: NativeDate;
39
+ transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
40
+ transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
39
41
  inventory_code: string;
40
42
  quantity_left: number;
41
43
  unit_price: number;
@@ -44,8 +46,6 @@ export declare const InventoryTransactionsSchema: Schema<any, import("mongoose")
44
46
  previous_quantity_left: number;
45
47
  previous_unit_price: number;
46
48
  previous_remaining_stock_price: number;
47
- transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
48
- transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
49
49
  order_id?: import("mongoose").Types.ObjectId | null | undefined;
50
50
  description?: string | null | undefined;
51
51
  order_number?: number | null | undefined;
@@ -60,6 +60,8 @@ export declare const InventoryTransactionsSchema: Schema<any, import("mongoose")
60
60
  createdAt_mins: number;
61
61
  createdAt: NativeDate;
62
62
  updatedAt: NativeDate;
63
+ transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
64
+ transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
63
65
  inventory_code: string;
64
66
  quantity_left: number;
65
67
  unit_price: number;
@@ -68,8 +70,6 @@ export declare const InventoryTransactionsSchema: Schema<any, import("mongoose")
68
70
  previous_quantity_left: number;
69
71
  previous_unit_price: number;
70
72
  previous_remaining_stock_price: number;
71
- transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
72
- transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
73
73
  order_id?: import("mongoose").Types.ObjectId | null | undefined;
74
74
  description?: string | null | undefined;
75
75
  order_number?: number | null | undefined;
@@ -13,10 +13,10 @@ export declare const ItemTransactionsSchema: Schema<any, import("mongoose").Mode
13
13
  createdAt: NativeDate;
14
14
  updatedAt: NativeDate;
15
15
  category_id: import("mongoose").Types.ObjectId;
16
+ transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
16
17
  order_number: number;
17
18
  item_id: import("mongoose").Types.ObjectId;
18
19
  quantity: number;
19
- transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
20
20
  item_name: string;
21
21
  category_name: string;
22
22
  selling_price: number;
@@ -33,10 +33,10 @@ export declare const ItemTransactionsSchema: Schema<any, import("mongoose").Mode
33
33
  createdAt: NativeDate;
34
34
  updatedAt: NativeDate;
35
35
  category_id: import("mongoose").Types.ObjectId;
36
+ transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
36
37
  order_number: number;
37
38
  item_id: import("mongoose").Types.ObjectId;
38
39
  quantity: number;
39
- transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
40
40
  item_name: string;
41
41
  category_name: string;
42
42
  selling_price: number;
@@ -53,10 +53,10 @@ export declare const ItemTransactionsSchema: Schema<any, import("mongoose").Mode
53
53
  createdAt: NativeDate;
54
54
  updatedAt: NativeDate;
55
55
  category_id: import("mongoose").Types.ObjectId;
56
+ transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
56
57
  order_number: number;
57
58
  item_id: import("mongoose").Types.ObjectId;
58
59
  quantity: number;
59
- transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
60
60
  item_name: string;
61
61
  category_name: string;
62
62
  selling_price: number;
@@ -2519,7 +2519,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
2519
2519
  gst?: number | null | undefined;
2520
2520
  exclude_discount_from_gst?: boolean | null | undefined;
2521
2521
  gst_amount?: number | null | undefined;
2522
- packaging_fee?: number | null | undefined;
2522
+ packaging_charges?: number | null | undefined;
2523
2523
  adjustment_amount?: number | null | undefined;
2524
2524
  adjustment_reason?: string | null | undefined;
2525
2525
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -3787,7 +3787,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
3787
3787
  gst?: number | null | undefined;
3788
3788
  exclude_discount_from_gst?: boolean | null | undefined;
3789
3789
  gst_amount?: number | null | undefined;
3790
- packaging_fee?: number | null | undefined;
3790
+ packaging_charges?: number | null | undefined;
3791
3791
  adjustment_amount?: number | null | undefined;
3792
3792
  adjustment_reason?: string | null | undefined;
3793
3793
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -5055,7 +5055,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
5055
5055
  gst?: number | null | undefined;
5056
5056
  exclude_discount_from_gst?: boolean | null | undefined;
5057
5057
  gst_amount?: number | null | undefined;
5058
- packaging_fee?: number | null | undefined;
5058
+ packaging_charges?: number | null | undefined;
5059
5059
  adjustment_amount?: number | null | undefined;
5060
5060
  adjustment_reason?: string | null | undefined;
5061
5061
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -5168,7 +5168,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
5168
5168
  gst?: number | null | undefined;
5169
5169
  exclude_discount_from_gst?: boolean | null | undefined;
5170
5170
  gst_amount?: number | null | undefined;
5171
- packaging_fee?: number | null | undefined;
5171
+ packaging_charges?: number | null | undefined;
5172
5172
  adjustment_amount?: number | null | undefined;
5173
5173
  adjustment_reason?: string | null | undefined;
5174
5174
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -7616,7 +7616,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
7616
7616
  gst?: number | null | undefined;
7617
7617
  exclude_discount_from_gst?: boolean | null | undefined;
7618
7618
  gst_amount?: number | null | undefined;
7619
- packaging_fee?: number | null | undefined;
7619
+ packaging_charges?: number | null | undefined;
7620
7620
  adjustment_amount?: number | null | undefined;
7621
7621
  adjustment_reason?: string | null | undefined;
7622
7622
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -8884,7 +8884,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
8884
8884
  gst?: number | null | undefined;
8885
8885
  exclude_discount_from_gst?: boolean | null | undefined;
8886
8886
  gst_amount?: number | null | undefined;
8887
- packaging_fee?: number | null | undefined;
8887
+ packaging_charges?: number | null | undefined;
8888
8888
  adjustment_amount?: number | null | undefined;
8889
8889
  adjustment_reason?: string | null | undefined;
8890
8890
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -10152,7 +10152,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
10152
10152
  gst?: number | null | undefined;
10153
10153
  exclude_discount_from_gst?: boolean | null | undefined;
10154
10154
  gst_amount?: number | null | undefined;
10155
- packaging_fee?: number | null | undefined;
10155
+ packaging_charges?: number | null | undefined;
10156
10156
  adjustment_amount?: number | null | undefined;
10157
10157
  adjustment_reason?: string | null | undefined;
10158
10158
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -10265,7 +10265,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
10265
10265
  gst?: number | null | undefined;
10266
10266
  exclude_discount_from_gst?: boolean | null | undefined;
10267
10267
  gst_amount?: number | null | undefined;
10268
- packaging_fee?: number | null | undefined;
10268
+ packaging_charges?: number | null | undefined;
10269
10269
  adjustment_amount?: number | null | undefined;
10270
10270
  adjustment_reason?: string | null | undefined;
10271
10271
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -12713,7 +12713,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
12713
12713
  gst?: number | null | undefined;
12714
12714
  exclude_discount_from_gst?: boolean | null | undefined;
12715
12715
  gst_amount?: number | null | undefined;
12716
- packaging_fee?: number | null | undefined;
12716
+ packaging_charges?: number | null | undefined;
12717
12717
  adjustment_amount?: number | null | undefined;
12718
12718
  adjustment_reason?: string | null | undefined;
12719
12719
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -13981,7 +13981,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
13981
13981
  gst?: number | null | undefined;
13982
13982
  exclude_discount_from_gst?: boolean | null | undefined;
13983
13983
  gst_amount?: number | null | undefined;
13984
- packaging_fee?: number | null | undefined;
13984
+ packaging_charges?: number | null | undefined;
13985
13985
  adjustment_amount?: number | null | undefined;
13986
13986
  adjustment_reason?: string | null | undefined;
13987
13987
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -15249,7 +15249,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
15249
15249
  gst?: number | null | undefined;
15250
15250
  exclude_discount_from_gst?: boolean | null | undefined;
15251
15251
  gst_amount?: number | null | undefined;
15252
- packaging_fee?: number | null | undefined;
15252
+ packaging_charges?: number | null | undefined;
15253
15253
  adjustment_amount?: number | null | undefined;
15254
15254
  adjustment_reason?: string | null | undefined;
15255
15255
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -15362,7 +15362,7 @@ export declare const OrderSchema: Schema<any, import("mongoose").Model<any, any,
15362
15362
  gst?: number | null | undefined;
15363
15363
  exclude_discount_from_gst?: boolean | null | undefined;
15364
15364
  gst_amount?: number | null | undefined;
15365
- packaging_fee?: number | null | undefined;
15365
+ packaging_charges?: number | null | undefined;
15366
15366
  adjustment_amount?: number | null | undefined;
15367
15367
  adjustment_reason?: string | null | undefined;
15368
15368
  apply_service_fee_on_original_price?: boolean | null | undefined;
@@ -530,7 +530,7 @@ const IterationsOrderSchema = new mongoose_1.Schema({
530
530
  min: 0,
531
531
  required: false,
532
532
  },
533
- packaging_fee: {
533
+ packaging_charges: {
534
534
  type: Number,
535
535
  min: 0,
536
536
  required: false,
@@ -749,7 +749,7 @@ exports.OrderSchema = new mongoose_1.Schema({
749
749
  min: 0,
750
750
  required: false,
751
751
  },
752
- packaging_fee: {
752
+ packaging_charges: {
753
753
  type: Number,
754
754
  min: 0,
755
755
  required: false,
@@ -19,7 +19,7 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
19
19
  country_code: COUNTRY_CODE_ENUM;
20
20
  delivery_free_over: number;
21
21
  provider_id: string;
22
- packaging_fee: number;
22
+ packaging_charges: number;
23
23
  public_business_name: string;
24
24
  support_email: string;
25
25
  public_phone_numbers: string[];
@@ -92,8 +92,8 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
92
92
  rider_revenue_per_meter: number;
93
93
  static_rider_revenue_multiplier: number;
94
94
  min_service_fee_order_value: number;
95
- free_packaging_over: number;
96
- min_packaging_fee_order_value: number;
95
+ packaging_charges_free_over: number;
96
+ min_packaging_charges_order_value: number;
97
97
  cash_in_hand_limit: number;
98
98
  restaurant_address: string;
99
99
  business_website: string;
@@ -166,6 +166,10 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
166
166
  digital_menu_images?: string[] | null | undefined;
167
167
  web_slider_images?: string[] | null | undefined;
168
168
  specials_name?: string | null | undefined;
169
+ twitter_link?: string | null | undefined;
170
+ instagram_link?: string | null | undefined;
171
+ fb_link?: string | null | undefined;
172
+ tiktok_link?: string | null | undefined;
169
173
  }, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
170
174
  createdAt: NativeDate;
171
175
  updatedAt: NativeDate;
@@ -181,7 +185,7 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
181
185
  country_code: COUNTRY_CODE_ENUM;
182
186
  delivery_free_over: number;
183
187
  provider_id: string;
184
- packaging_fee: number;
188
+ packaging_charges: number;
185
189
  public_business_name: string;
186
190
  support_email: string;
187
191
  public_phone_numbers: string[];
@@ -254,8 +258,8 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
254
258
  rider_revenue_per_meter: number;
255
259
  static_rider_revenue_multiplier: number;
256
260
  min_service_fee_order_value: number;
257
- free_packaging_over: number;
258
- min_packaging_fee_order_value: number;
261
+ packaging_charges_free_over: number;
262
+ min_packaging_charges_order_value: number;
259
263
  cash_in_hand_limit: number;
260
264
  restaurant_address: string;
261
265
  business_website: string;
@@ -328,6 +332,10 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
328
332
  digital_menu_images?: string[] | null | undefined;
329
333
  web_slider_images?: string[] | null | undefined;
330
334
  specials_name?: string | null | undefined;
335
+ twitter_link?: string | null | undefined;
336
+ instagram_link?: string | null | undefined;
337
+ fb_link?: string | null | undefined;
338
+ tiktok_link?: string | null | undefined;
331
339
  }>> & import("mongoose").FlatRecord<{
332
340
  createdAt: NativeDate;
333
341
  updatedAt: NativeDate;
@@ -343,7 +351,7 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
343
351
  country_code: COUNTRY_CODE_ENUM;
344
352
  delivery_free_over: number;
345
353
  provider_id: string;
346
- packaging_fee: number;
354
+ packaging_charges: number;
347
355
  public_business_name: string;
348
356
  support_email: string;
349
357
  public_phone_numbers: string[];
@@ -416,8 +424,8 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
416
424
  rider_revenue_per_meter: number;
417
425
  static_rider_revenue_multiplier: number;
418
426
  min_service_fee_order_value: number;
419
- free_packaging_over: number;
420
- min_packaging_fee_order_value: number;
427
+ packaging_charges_free_over: number;
428
+ min_packaging_charges_order_value: number;
421
429
  cash_in_hand_limit: number;
422
430
  restaurant_address: string;
423
431
  business_website: string;
@@ -490,6 +498,10 @@ export declare const TenantSchema: Schema<any, import("mongoose").Model<any, any
490
498
  digital_menu_images?: string[] | null | undefined;
491
499
  web_slider_images?: string[] | null | undefined;
492
500
  specials_name?: string | null | undefined;
501
+ twitter_link?: string | null | undefined;
502
+ instagram_link?: string | null | undefined;
503
+ fb_link?: string | null | undefined;
504
+ tiktok_link?: string | null | undefined;
493
505
  }> & Required<{
494
506
  _id: string;
495
507
  }> & {
@@ -329,15 +329,15 @@ exports.TenantSchema = new mongoose_1.Schema({
329
329
  type: Number,
330
330
  default: 0,
331
331
  },
332
- packaging_fee: {
332
+ packaging_charges: {
333
333
  type: Number,
334
334
  default: 0,
335
335
  },
336
- free_packaging_over: {
336
+ packaging_charges_free_over: {
337
337
  type: Number,
338
338
  default: 0,
339
339
  },
340
- min_packaging_fee_order_value: {
340
+ min_packaging_charges_order_value: {
341
341
  type: Number,
342
342
  default: 0,
343
343
  },
@@ -694,6 +694,22 @@ exports.TenantSchema = new mongoose_1.Schema({
694
694
  enum: constants_1.ALL_ORDER_COMPLETION_TYPES,
695
695
  default: constants_1.ORDER_COMPLETION_TYPE_ENUM.DEFAULT_ON,
696
696
  },
697
+ twitter_link: {
698
+ type: String,
699
+ required: false,
700
+ },
701
+ instagram_link: {
702
+ type: String,
703
+ required: false,
704
+ },
705
+ fb_link: {
706
+ type: String,
707
+ required: false,
708
+ },
709
+ tiktok_link: {
710
+ type: String,
711
+ required: false,
712
+ },
697
713
  // ====><====
698
714
  createdAt: {
699
715
  type: mongoose_1.Schema.Types.Date,
@@ -23,6 +23,7 @@ export declare const TenantStaffSchema: Schema<any, import("mongoose").Model<any
23
23
  role: import("../../constants").USER_ROLES_ENUM;
24
24
  allowed_platforms: import("../../constants").PLATFORM_TYPE_ENUM[];
25
25
  assigned_tables: string[];
26
+ cash_in_hand?: number | null | undefined;
26
27
  operational_hours?: import("mongoose").Types.DocumentArray<{
27
28
  days_index: import("../../constants").DAY_INDEX_ENUM[];
28
29
  disabled_outside_date_range: boolean;
@@ -309,7 +310,6 @@ export declare const TenantStaffSchema: Schema<any, import("mongoose").Model<any
309
310
  BASE_PRICE: number;
310
311
  } | null | undefined;
311
312
  }> | null | undefined;
312
- cash_in_hand?: number | null | undefined;
313
313
  }, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
314
314
  createdAt: NativeDate;
315
315
  updatedAt: NativeDate;
@@ -330,6 +330,7 @@ export declare const TenantStaffSchema: Schema<any, import("mongoose").Model<any
330
330
  role: import("../../constants").USER_ROLES_ENUM;
331
331
  allowed_platforms: import("../../constants").PLATFORM_TYPE_ENUM[];
332
332
  assigned_tables: string[];
333
+ cash_in_hand?: number | null | undefined;
333
334
  operational_hours?: import("mongoose").Types.DocumentArray<{
334
335
  days_index: import("../../constants").DAY_INDEX_ENUM[];
335
336
  disabled_outside_date_range: boolean;
@@ -616,7 +617,6 @@ export declare const TenantStaffSchema: Schema<any, import("mongoose").Model<any
616
617
  BASE_PRICE: number;
617
618
  } | null | undefined;
618
619
  }> | null | undefined;
619
- cash_in_hand?: number | null | undefined;
620
620
  }>> & import("mongoose").FlatRecord<{
621
621
  createdAt: NativeDate;
622
622
  updatedAt: NativeDate;
@@ -637,6 +637,7 @@ export declare const TenantStaffSchema: Schema<any, import("mongoose").Model<any
637
637
  role: import("../../constants").USER_ROLES_ENUM;
638
638
  allowed_platforms: import("../../constants").PLATFORM_TYPE_ENUM[];
639
639
  assigned_tables: string[];
640
+ cash_in_hand?: number | null | undefined;
640
641
  operational_hours?: import("mongoose").Types.DocumentArray<{
641
642
  days_index: import("../../constants").DAY_INDEX_ENUM[];
642
643
  disabled_outside_date_range: boolean;
@@ -923,7 +924,6 @@ export declare const TenantStaffSchema: Schema<any, import("mongoose").Model<any
923
924
  BASE_PRICE: number;
924
925
  } | null | undefined;
925
926
  }> | null | undefined;
926
- cash_in_hand?: number | null | undefined;
927
927
  }> & Required<{
928
928
  _id: import("mongoose").Types.ObjectId;
929
929
  }> & {
@@ -13,9 +13,9 @@ export declare const WalletTransactionsSchema: Schema<any, import("mongoose").Mo
13
13
  createdAt: NativeDate;
14
14
  updatedAt: NativeDate;
15
15
  payment_id: string;
16
- payment_method: string;
17
16
  transaction_type: import("../../constants").WALLET_TRANSACTION_TYPE_ENUM;
18
17
  transaction_category: import("../../constants").WALLET_TRANSACTION_CATEGORY_ENUM;
18
+ payment_method: string;
19
19
  previous_balance: number;
20
20
  transaction_amount: number;
21
21
  running_balance: number;
@@ -34,9 +34,9 @@ export declare const WalletTransactionsSchema: Schema<any, import("mongoose").Mo
34
34
  createdAt: NativeDate;
35
35
  updatedAt: NativeDate;
36
36
  payment_id: string;
37
- payment_method: string;
38
37
  transaction_type: import("../../constants").WALLET_TRANSACTION_TYPE_ENUM;
39
38
  transaction_category: import("../../constants").WALLET_TRANSACTION_CATEGORY_ENUM;
39
+ payment_method: string;
40
40
  previous_balance: number;
41
41
  transaction_amount: number;
42
42
  running_balance: number;
@@ -55,9 +55,9 @@ export declare const WalletTransactionsSchema: Schema<any, import("mongoose").Mo
55
55
  createdAt: NativeDate;
56
56
  updatedAt: NativeDate;
57
57
  payment_id: string;
58
- payment_method: string;
59
58
  transaction_type: import("../../constants").WALLET_TRANSACTION_TYPE_ENUM;
60
59
  transaction_category: import("../../constants").WALLET_TRANSACTION_CATEGORY_ENUM;
60
+ payment_method: string;
61
61
  previous_balance: number;
62
62
  transaction_amount: number;
63
63
  running_balance: number;
@@ -11,6 +11,8 @@ export declare const WarehouseInventoryTransactionsSchema: Schema<any, import("m
11
11
  createdAt_mins: number;
12
12
  createdAt: NativeDate;
13
13
  updatedAt: NativeDate;
14
+ transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
15
+ transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
14
16
  inventory_code: string;
15
17
  quantity_left: number;
16
18
  unit_price: number;
@@ -19,8 +21,6 @@ export declare const WarehouseInventoryTransactionsSchema: Schema<any, import("m
19
21
  previous_quantity_left: number;
20
22
  previous_unit_price: number;
21
23
  previous_remaining_stock_price: number;
22
- transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
23
- transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
24
24
  warehouse_id: string;
25
25
  order_id?: import("mongoose").Types.ObjectId | null | undefined;
26
26
  description?: string | null | undefined;
@@ -35,6 +35,8 @@ export declare const WarehouseInventoryTransactionsSchema: Schema<any, import("m
35
35
  createdAt_mins: number;
36
36
  createdAt: NativeDate;
37
37
  updatedAt: NativeDate;
38
+ transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
39
+ transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
38
40
  inventory_code: string;
39
41
  quantity_left: number;
40
42
  unit_price: number;
@@ -43,8 +45,6 @@ export declare const WarehouseInventoryTransactionsSchema: Schema<any, import("m
43
45
  previous_quantity_left: number;
44
46
  previous_unit_price: number;
45
47
  previous_remaining_stock_price: number;
46
- transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
47
- transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
48
48
  warehouse_id: string;
49
49
  order_id?: import("mongoose").Types.ObjectId | null | undefined;
50
50
  description?: string | null | undefined;
@@ -59,6 +59,8 @@ export declare const WarehouseInventoryTransactionsSchema: Schema<any, import("m
59
59
  createdAt_mins: number;
60
60
  createdAt: NativeDate;
61
61
  updatedAt: NativeDate;
62
+ transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
63
+ transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
62
64
  inventory_code: string;
63
65
  quantity_left: number;
64
66
  unit_price: number;
@@ -67,8 +69,6 @@ export declare const WarehouseInventoryTransactionsSchema: Schema<any, import("m
67
69
  previous_quantity_left: number;
68
70
  previous_unit_price: number;
69
71
  previous_remaining_stock_price: number;
70
- transaction_type: import("../../constants").INVENTORY_TRANSACTION_TYPE_ENUM;
71
- transaction_category: import("../../constants").INVENTORY_TRANSACTION_CATEGORY_ENUM;
72
72
  warehouse_id: string;
73
73
  order_id?: import("mongoose").Types.ObjectId | null | undefined;
74
74
  description?: string | null | undefined;
@@ -12,11 +12,11 @@ export declare const WarehouseItemTransactionsSchema: Schema<any, import("mongoo
12
12
  createdAt: NativeDate;
13
13
  updatedAt: NativeDate;
14
14
  category_id: import("mongoose").Types.ObjectId;
15
+ transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
15
16
  inventory_code: string;
16
17
  order_number: number;
17
18
  item_id: import("mongoose").Types.ObjectId;
18
19
  quantity: number;
19
- transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
20
20
  item_name: string;
21
21
  category_name: string;
22
22
  selling_price: number;
@@ -33,11 +33,11 @@ export declare const WarehouseItemTransactionsSchema: Schema<any, import("mongoo
33
33
  createdAt: NativeDate;
34
34
  updatedAt: NativeDate;
35
35
  category_id: import("mongoose").Types.ObjectId;
36
+ transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
36
37
  inventory_code: string;
37
38
  order_number: number;
38
39
  item_id: import("mongoose").Types.ObjectId;
39
40
  quantity: number;
40
- transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
41
41
  item_name: string;
42
42
  category_name: string;
43
43
  selling_price: number;
@@ -54,11 +54,11 @@ export declare const WarehouseItemTransactionsSchema: Schema<any, import("mongoo
54
54
  createdAt: NativeDate;
55
55
  updatedAt: NativeDate;
56
56
  category_id: import("mongoose").Types.ObjectId;
57
+ transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
57
58
  inventory_code: string;
58
59
  order_number: number;
59
60
  item_id: import("mongoose").Types.ObjectId;
60
61
  quantity: number;
61
- transaction_type: import("../../constants").ITEM_TRANSACTION_TYPE_ENUM;
62
62
  item_name: string;
63
63
  category_name: string;
64
64
  selling_price: number;
@@ -0,0 +1,16 @@
1
+ import { CASH_IN_HAND_TRANSACTION_TYPE_ENUM } from '../../constants';
2
+ export interface ICashInHandTransaction {
3
+ _id: string;
4
+ tenant_id: string;
5
+ staff_id: string;
6
+ staff_name: string;
7
+ processed_by_id: string;
8
+ processed_by_name: string;
9
+ prev_cash_in_hand: number;
10
+ cash_in_hand: number;
11
+ transaction_type: CASH_IN_HAND_TRANSACTION_TYPE_ENUM;
12
+ transaction_category: string;
13
+ note?: string | null;
14
+ createdAt: Date;
15
+ updatedAt: Date;
16
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -3,6 +3,7 @@ export * from './applied-order-discounts';
3
3
  export * from './brand';
4
4
  export * from './cash_drawer_sessions';
5
5
  export * from './cash_drawers';
6
+ export * from './cash_in_hand_transactions';
6
7
  export * from './cash_in_out';
7
8
  export * from './category';
8
9
  export * from './close_dates';
@@ -19,6 +19,7 @@ __exportStar(require("./applied-order-discounts"), exports);
19
19
  __exportStar(require("./brand"), exports);
20
20
  __exportStar(require("./cash_drawer_sessions"), exports);
21
21
  __exportStar(require("./cash_drawers"), exports);
22
+ __exportStar(require("./cash_in_hand_transactions"), exports);
22
23
  __exportStar(require("./cash_in_out"), exports);
23
24
  __exportStar(require("./category"), exports);
24
25
  __exportStar(require("./close_dates"), exports);
@@ -142,7 +142,7 @@ interface CommonOptionalFields {
142
142
  service_fee_amount?: number;
143
143
  gst?: number;
144
144
  gst_amount?: number;
145
- packaging_fee?: number;
145
+ packaging_charges?: number;
146
146
  adjustment_amount?: number | null;
147
147
  adjustment_reason?: string | null;
148
148
  tax_invoice_provider_charges?: number;
@@ -79,9 +79,9 @@ export interface ITenant {
79
79
  rider_revenue_per_meter: number;
80
80
  static_rider_revenue_multiplier: number;
81
81
  min_service_fee_order_value?: number;
82
- packaging_fee?: number;
83
- free_packaging_over?: number;
84
- min_packaging_fee_order_value?: number;
82
+ packaging_charges?: number;
83
+ packaging_charges_free_over?: number;
84
+ min_packaging_charges_order_value?: number;
85
85
  cash_in_hand_limit?: number;
86
86
  rider_pickup_food_image_mandatory?: boolean;
87
87
  rider_dropoff_food_image_mandatory?: boolean;
@@ -157,6 +157,10 @@ export interface ITenant {
157
157
  web_slider_images?: string[] | null;
158
158
  enabled_rating_types: RATING_TYPE_ENUM[];
159
159
  specials_name?: string | null;
160
+ fb_link?: string | null;
161
+ instagram_link?: string | null;
162
+ twitter_link?: string | null;
163
+ tiktok_link?: string | null;
160
164
  order_completion_type: ORDER_COMPLETION_TYPE_ENUM;
161
165
  createdAt: Date;
162
166
  updatedAt: Date;
@@ -172,6 +176,10 @@ export interface ITenantOnlineOrderingMetadata {
172
176
  brand_color: ITenant['brand_color'];
173
177
  business_type: ITenant['business_type'];
174
178
  city: ITenant['city'];
179
+ fb_link: ITenant['fb_link'];
180
+ instagram_link: ITenant['instagram_link'];
181
+ twitter_link: ITenant['twitter_link'];
182
+ tiktok_link: ITenant['tiktok_link'];
175
183
  }
176
184
  export interface IBrandOnlineOrderingMetadata {
177
185
  _id: string;
@@ -182,4 +190,8 @@ export interface IBrandOnlineOrderingMetadata {
182
190
  web_favicon: ITenant['web_favicon'];
183
191
  brand_color: ITenant['brand_color'];
184
192
  business_type: ITenant['business_type'];
193
+ fb_link: ITenant['fb_link'];
194
+ instagram_link: ITenant['instagram_link'];
195
+ twitter_link: ITenant['twitter_link'];
196
+ tiktok_link: ITenant['tiktok_link'];
185
197
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@managesome/eposmatic-toolkit",
3
- "version": "0.2.227",
3
+ "version": "0.2.229",
4
4
  "description": "A Toolkit Library for Eposmatic",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",