@managesome/eposmatic-toolkit 0.2.246 → 0.2.248

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.
@@ -416,7 +416,8 @@ export interface IXReportAnalytics {
416
416
  }
417
417
  export declare enum REPORT_SALE_TYPE_ENUM {
418
418
  TOTAL_SALES = "TOTAL_SALES",
419
- AMOUNT_COLLECTED = "AMOUNT_COLLECTED"
419
+ AMOUNT_COLLECTED = "AMOUNT_COLLECTED",
420
+ OPEN_ORDERS = "OPEN_ORDERS"
420
421
  }
421
422
  export declare const ALL_REPORT_SALE_TYPES: REPORT_SALE_TYPE_ENUM[];
422
423
  export declare enum REPORT_TIME_BIAS_ENUM {
@@ -126,6 +126,7 @@ var REPORT_SALE_TYPE_ENUM;
126
126
  (function (REPORT_SALE_TYPE_ENUM) {
127
127
  REPORT_SALE_TYPE_ENUM["TOTAL_SALES"] = "TOTAL_SALES";
128
128
  REPORT_SALE_TYPE_ENUM["AMOUNT_COLLECTED"] = "AMOUNT_COLLECTED";
129
+ REPORT_SALE_TYPE_ENUM["OPEN_ORDERS"] = "OPEN_ORDERS";
129
130
  })(REPORT_SALE_TYPE_ENUM || (exports.REPORT_SALE_TYPE_ENUM = REPORT_SALE_TYPE_ENUM = {}));
130
131
  exports.ALL_REPORT_SALE_TYPES = Object.values(REPORT_SALE_TYPE_ENUM);
131
132
  // ==================><=================
@@ -7,6 +7,7 @@ export interface IItemReportProps {
7
7
  itemsChannels?: IItemChannelMap[];
8
8
  modifiersChannel?: IReportChannelData[];
9
9
  showRevenue?: boolean;
10
+ hideModifiersDescription?: boolean;
10
11
  count: number;
11
12
  itemAmount: number;
12
13
  itemGstAmount: number;
@@ -880,9 +880,10 @@ const getLegacyItemReportHead = ({ monochrome, width, zeroPadding }) => {
880
880
  <title>Item Sales Report</title>
881
881
  </head>`;
882
882
  };
883
- function getLegacyItemReportBody({ categoriesChannel, itemsChannels, modifiersChannel, currency_symbol, from, to, tenantName, menuName, itemNetAmount, count, isFilterApplied, monochrome, showRevenue, }) {
883
+ function getLegacyItemReportBody({ categoriesChannel, itemsChannels, modifiersChannel, currency_symbol, from, to, tenantName, menuName, itemNetAmount, count, isFilterApplied, monochrome, showRevenue, hideModifiersDescription, }) {
884
884
  // ======================>>>><<<<=====================
885
885
  const shouldShowRevenue = showRevenue ?? true;
886
+ const shouldHideModifiersDescription = hideModifiersDescription ?? false;
886
887
  const dealTextColor = monochrome ? '#000000' : '#9e9e9e';
887
888
  const dealBadgeColor = monochrome ? '#000000' : '#f1c24a';
888
889
  const dealMetaColor = monochrome ? '#000000' : '#777';
@@ -897,6 +898,9 @@ function getLegacyItemReportBody({ categoriesChannel, itemsChannels, modifiersCh
897
898
  const individualCount = Math.max(0, item.count - dealCount);
898
899
  const hasDeal = dealCount > 0;
899
900
  for (const subItem of item.subChannels) {
901
+ if (shouldHideModifiersDescription) {
902
+ continue;
903
+ }
900
904
  const isReferenced = subItem.referenceId != null;
901
905
  const subDealCount = subItem.dealCount ?? 0;
902
906
  const subIndividualCount = subItem.individualCount ?? Math.max(0, subItem.count - subDealCount);
@@ -2156,9 +2160,10 @@ const getNewItemReportHead = ({ zeroPadding, monochrome }) => {
2156
2160
  <title>Item Sales Report</title>
2157
2161
  </head>`;
2158
2162
  };
2159
- function getNewItemReportBody({ categoriesChannel, itemsChannels, modifiersChannel, currency_symbol, from, to, tenantName, menuName, itemNetAmount, count, itemAmount, itemDiscountAmount, itemGrossAmount, itemGstAmount, gstTitle, isFilterApplied, showRevenue, }) {
2163
+ function getNewItemReportBody({ categoriesChannel, itemsChannels, modifiersChannel, currency_symbol, from, to, tenantName, menuName, itemNetAmount, count, itemAmount, itemDiscountAmount, itemGrossAmount, itemGstAmount, gstTitle, isFilterApplied, showRevenue, hideModifiersDescription, }) {
2160
2164
  // ======================>>>><<<<=====================
2161
2165
  const shouldShowRevenue = showRevenue ?? true;
2166
+ const shouldHideModifiersDescription = hideModifiersDescription ?? false;
2162
2167
  const itemTableColumns = shouldShowRevenue ? 7 : 1;
2163
2168
  let itemSales = '';
2164
2169
  if (itemsChannels != null && itemsChannels.length > 0) {
@@ -2171,6 +2176,9 @@ function getNewItemReportBody({ categoriesChannel, itemsChannels, modifiersChann
2171
2176
  const individualCount = Math.max(0, item.count - dealCount);
2172
2177
  const hasDeal = dealCount > 0;
2173
2178
  for (const subItem of item.subChannels) {
2179
+ if (shouldHideModifiersDescription) {
2180
+ continue;
2181
+ }
2174
2182
  const isReferenced = subItem.referenceId != null;
2175
2183
  const subDealCount = subItem.dealCount ?? 0;
2176
2184
  const subIndividualCount = subItem.individualCount ?? Math.max(0, subItem.count - subDealCount);
@@ -151,6 +151,7 @@ export declare const CustomersSchema: Schema<any, import("mongoose").Model<any,
151
151
  card_id: string;
152
152
  }>;
153
153
  order_ids: import("mongoose").Types.ObjectId[];
154
+ is_disabled?: boolean | null | undefined;
154
155
  }, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
155
156
  createdAt: NativeDate;
156
157
  updatedAt: NativeDate;
@@ -299,6 +300,7 @@ export declare const CustomersSchema: Schema<any, import("mongoose").Model<any,
299
300
  card_id: string;
300
301
  }>;
301
302
  order_ids: import("mongoose").Types.ObjectId[];
303
+ is_disabled?: boolean | null | undefined;
302
304
  }>> & import("mongoose").FlatRecord<{
303
305
  createdAt: NativeDate;
304
306
  updatedAt: NativeDate;
@@ -447,6 +449,7 @@ export declare const CustomersSchema: Schema<any, import("mongoose").Model<any,
447
449
  card_id: string;
448
450
  }>;
449
451
  order_ids: import("mongoose").Types.ObjectId[];
452
+ is_disabled?: boolean | null | undefined;
450
453
  }> & Required<{
451
454
  _id: import("mongoose").Types.ObjectId;
452
455
  }> & {
@@ -134,6 +134,10 @@ exports.CustomersSchema = new mongoose_1.Schema({
134
134
  type: Boolean,
135
135
  default: true,
136
136
  },
137
+ is_disabled: {
138
+ type: Boolean,
139
+ required: false,
140
+ },
137
141
  gender: {
138
142
  type: String,
139
143
  default: null,
@@ -17,8 +17,8 @@ export declare const WarehouseStaffSchema: Schema<any, import("mongoose").Model<
17
17
  email: string;
18
18
  email_verified: boolean;
19
19
  phone_number_verified: boolean;
20
- warehouse_id: string;
21
20
  is_disabled: boolean;
21
+ warehouse_id: string;
22
22
  staff_auth_code: string;
23
23
  role: import("../../constants").USER_ROLES_ENUM;
24
24
  }, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
@@ -35,8 +35,8 @@ export declare const WarehouseStaffSchema: Schema<any, import("mongoose").Model<
35
35
  email: string;
36
36
  email_verified: boolean;
37
37
  phone_number_verified: boolean;
38
- warehouse_id: string;
39
38
  is_disabled: boolean;
39
+ warehouse_id: string;
40
40
  staff_auth_code: string;
41
41
  role: import("../../constants").USER_ROLES_ENUM;
42
42
  }>> & import("mongoose").FlatRecord<{
@@ -53,8 +53,8 @@ export declare const WarehouseStaffSchema: Schema<any, import("mongoose").Model<
53
53
  email: string;
54
54
  email_verified: boolean;
55
55
  phone_number_verified: boolean;
56
- warehouse_id: string;
57
56
  is_disabled: boolean;
57
+ warehouse_id: string;
58
58
  staff_auth_code: string;
59
59
  role: import("../../constants").USER_ROLES_ENUM;
60
60
  }> & Required<{
@@ -34,6 +34,7 @@ export interface ICustomer {
34
34
  phone_number_verified: boolean;
35
35
  image_url: string | null;
36
36
  active: boolean;
37
+ is_disabled?: boolean;
37
38
  gender: string | null;
38
39
  total_orders_per_platform_type: Partial<IPlatformNumber>;
39
40
  total_spent_per_platform_type: Partial<IPlatformNumber>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@managesome/eposmatic-toolkit",
3
- "version": "0.2.246",
3
+ "version": "0.2.248",
4
4
  "description": "A Toolkit Library for Eposmatic",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",