@vendit-dev/thirdparty-adapters 0.7.16 → 0.7.18

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.
@@ -122,11 +122,11 @@ function groupByRoomWithTotalCounts(roomAndRoomRateInformations, totalRoomCount)
122
122
  var groupedRooms = Array(totalRoomCount).fill([]);
123
123
  return roomAndRoomRateInformations.reduce(function (acc, curr) {
124
124
  var RoomTypeCode = curr.RoomInformation.RoomTypeCode, RoomDate = curr.RoomRateInformation.RoomDate;
125
- var existingRooms = acc.find(function (groupedRooms) {
125
+ var existingRooms = acc.find(function (groupedRoom) {
126
126
  var _a, _b;
127
- return groupedRooms.length > 0 &&
128
- ((_b = (_a = groupedRooms[0]) === null || _a === void 0 ? void 0 : _a.RoomInformation) === null || _b === void 0 ? void 0 : _b.RoomTypeCode) === RoomTypeCode &&
129
- !groupedRooms.some(function (room) { return room.RoomRateInformation.RoomDate === RoomDate; });
127
+ return groupedRoom.length > 0 &&
128
+ ((_b = (_a = groupedRoom[0]) === null || _a === void 0 ? void 0 : _a.RoomInformation) === null || _b === void 0 ? void 0 : _b.RoomTypeCode) === RoomTypeCode &&
129
+ !groupedRoom.some(function (room) { return room.RoomRateInformation.RoomDate === RoomDate; });
130
130
  });
131
131
  if (existingRooms) {
132
132
  existingRooms.push(curr);
@@ -341,7 +341,7 @@ var refineReservationData = function (infoTravelXML) {
341
341
  externalPlatformCode: SalesOfficeInformation === null || SalesOfficeInformation === void 0 ? void 0 : SalesOfficeInformation.SalesOfficeCode,
342
342
  externalPlatformName: (SalesOfficeInformation === null || SalesOfficeInformation === void 0 ? void 0 : SalesOfficeInformation.SalesOfficeCompanyName) ||
343
343
  (SalesOfficeInformation === null || SalesOfficeInformation === void 0 ? void 0 : SalesOfficeInformation.SalesOfficeName),
344
- cmsOtaNumber: "".concat(BasicInformation.TravelAgencyBookingNumber).concat(isGroupReservation ? "-v".concat(index + 1) : ''),
344
+ cmsOtaNumber: "".concat(BasicInformation.TravelAgencyBookingNumber).concat(isGroupReservation ? "v".concat(index + 1) : ''),
345
345
  cmsProductName: roomsSortedByDate[0].RoomInformation.RoomTypeName ||
346
346
  BasicInformation.PackagePlanName,
347
347
  platform: tl_lincoln_ota_1.TL_LINCOLN_TO_VENDIT_OTA_MAP[(SalesOfficeInformation === null || SalesOfficeInformation === void 0 ? void 0 : SalesOfficeInformation.SalesOfficeCompanyName) || 'ANONYMOUS'] || (SalesOfficeInformation === null || SalesOfficeInformation === void 0 ? void 0 : SalesOfficeInformation.SalesOfficeCompanyName),
@@ -274,7 +274,7 @@ export interface RoomInformation {
274
274
  RoomChildB50Count?: number;
275
275
  RoomChildC30Count?: number;
276
276
  RoomChildDNoneCount?: number;
277
- RoomTypeAgent?: number;
277
+ RoomTypeAgent?: number | string;
278
278
  RoomFrame?: string;
279
279
  NetRmTypeGroupCode?: string | number;
280
280
  PlanGroupCode?: number | string;
@@ -426,10 +426,10 @@ export interface BasicInformation {
426
426
  export interface SalesOfficeInformation {
427
427
  SalesOfficeCompanyName: string;
428
428
  SalesOfficeName?: string;
429
- SalesOfficeCode?: number;
429
+ SalesOfficeCode?: number | string;
430
430
  SalesOfficePersonInCharge?: string;
431
431
  SalesOfficeEmail?: string;
432
- SalesOfficePhoneNumber?: string;
432
+ SalesOfficePhoneNumber?: number | string;
433
433
  SalesOfficeStateProvidence?: string;
434
434
  SalesOfficeCityName?: string;
435
435
  SalesOfficeAddressLine?: string;
@@ -60,6 +60,7 @@ var TlLincolnOta;
60
60
  TlLincolnOta["YANOLJA"] = "Yanolja";
61
61
  TlLincolnOta["T_MON"] = "T-mon";
62
62
  TlLincolnOta["TRIPDOTCOM"] = "Trip.com Group(new)";
63
+ TlLincolnOta["TRIPDOTCOM_OLD"] = "Trip.com Group";
63
64
  TlLincolnOta["CHALET_KOREA"] = "CHALET KOREA";
64
65
  TlLincolnOta["SUITE"] = "SUITE";
65
66
  TlLincolnOta["SMART"] = "Smart";
@@ -121,6 +122,7 @@ exports.TL_LINCOLN_TO_VENDIT_OTA_MAP = (_a = {},
121
122
  _a[TlLincolnOta.YANOLJA] = 'YANOLJAHOTEL',
122
123
  _a[TlLincolnOta.T_MON] = 'TMON',
123
124
  _a[TlLincolnOta.TRIPDOTCOM] = 'TRIPDOTCOM',
125
+ _a[TlLincolnOta.TRIPDOTCOM_OLD] = 'TRIPDOTCOM',
124
126
  _a[TlLincolnOta.CHALET_KOREA] = 'CHALET_KOREA',
125
127
  _a[TlLincolnOta.SUITE] = 'SUITE',
126
128
  _a[TlLincolnOta.SMART] = 'SMART',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vendit-dev/thirdparty-adapters",
3
- "version": "0.7.16",
3
+ "version": "0.7.18",
4
4
  "description": "Third party adapters between v-cloud and other PMS/CMS providers.",
5
5
  "main": "lib/index.js",
6
6
  "scripts": {