turf-common 1.2.1-beta.70 → 1.2.1-beta.72

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.
@@ -9,3 +9,4 @@ export declare enum BookingHistoryOperationType {
9
9
  MERGED = "merged",
10
10
  DELETE_SLOT_EVENT = "delete_slot_event"
11
11
  }
12
+ export declare const OPERATION_TYPES: BookingHistoryOperationType[];
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BookingHistoryOperationType = void 0;
3
+ exports.OPERATION_TYPES = exports.BookingHistoryOperationType = void 0;
4
4
  var BookingHistoryOperationType;
5
5
  (function (BookingHistoryOperationType) {
6
6
  BookingHistoryOperationType["DELETE"] = "delete";
@@ -13,3 +13,8 @@ var BookingHistoryOperationType;
13
13
  BookingHistoryOperationType["MERGED"] = "merged";
14
14
  BookingHistoryOperationType["DELETE_SLOT_EVENT"] = "delete_slot_event";
15
15
  })(BookingHistoryOperationType || (exports.BookingHistoryOperationType = BookingHistoryOperationType = {}));
16
+ exports.OPERATION_TYPES = [
17
+ BookingHistoryOperationType.DELETE,
18
+ BookingHistoryOperationType.REFUND,
19
+ BookingHistoryOperationType.PAYMENT,
20
+ ];
@@ -1,5 +1,3 @@
1
- import { BookingHistoryOperationType } from "../@enum";
2
1
  export declare const SUBSCRIPTION_RENEWAL_THRESHOLD_DAYS = 7;
3
2
  export declare const DEFAULT_PASSWORD = "turf@#123";
4
3
  export declare const DELETED_SLOT_SEPARATOR = "d_";
5
- export declare const OPERATION_TYPES: BookingHistoryOperationType[];
@@ -1,12 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.OPERATION_TYPES = exports.DELETED_SLOT_SEPARATOR = exports.DEFAULT_PASSWORD = exports.SUBSCRIPTION_RENEWAL_THRESHOLD_DAYS = void 0;
4
- var _enum_1 = require("../@enum");
3
+ exports.DELETED_SLOT_SEPARATOR = exports.DEFAULT_PASSWORD = exports.SUBSCRIPTION_RENEWAL_THRESHOLD_DAYS = void 0;
5
4
  exports.SUBSCRIPTION_RENEWAL_THRESHOLD_DAYS = 7;
6
5
  exports.DEFAULT_PASSWORD = "turf@#123";
7
6
  exports.DELETED_SLOT_SEPARATOR = "d_";
8
- exports.OPERATION_TYPES = [
9
- _enum_1.BookingHistoryOperationType.DELETE,
10
- _enum_1.BookingHistoryOperationType.REFUND,
11
- _enum_1.BookingHistoryOperationType.PAYMENT,
12
- ];
@@ -44,5 +44,6 @@ export declare class DateUtilService {
44
44
  * @returns An array of booking date codes based on the provided date range and weekdays.
45
45
  */
46
46
  getBookingCodeByWeekDaysAndDateRange(startDateCode: string, endDateCode: string, weekdays: number[]): string[];
47
+ formatDate(date: Date, formatString: string): string;
47
48
  }
48
49
  export declare const dateUtilService: DateUtilService;
@@ -138,6 +138,9 @@ var DateUtilService = /** @class */ (function () {
138
138
  });
139
139
  return bookingDateCodes.map(Number).sort().map(String);
140
140
  };
141
+ DateUtilService.prototype.formatDate = function (date, formatString) {
142
+ return (0, date_fns_1.format)(date, formatString);
143
+ };
141
144
  return DateUtilService;
142
145
  }());
143
146
  exports.DateUtilService = DateUtilService;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "turf-common",
3
- "version": "1.2.1-beta.70",
3
+ "version": "1.2.1-beta.72",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",