PageSourceSearch

https://www.hrs.com/_next/static/chunks/61917-2c593fce03f3e45a.js?dpl=dpl_8AhHgfWTYWp17UKqJGwj6q7gMret

js hrs.com collected 2026-10-02 03:04:54 UTC 25,058 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[61917],{12942:(e,t,r)=>{r.d(t,{V:()=>s,I:()=>u});var i=r(16752),a=r(69406),o=r(84713);class l{static async get(e,t){let r=e;return(r.includes(t)&&(r=r.filter(e=>e!==t)),0===r.length||1===r.length&&r[0]===t)?{currency:t,exchangeRates:{}}:(r="EUR"===t||r.includes("EUR")?r:["EUR",...r],fetch("".concat(i.T.apiConfig.currencyEndpoint,"/v2/exchange-rates?source=").concat(r.join(","),"&target=").concat(t),{method:"GET",redirect:"follow",headers:{"Content-Type":"application/json","Accept-Encoding":"gzip","x-client-id":(0,o.Jf)()}}).then(e=>e.json()).then(e=>e).then(e=>this.map(e,t)).catch(e=>(a.Vy.error(e,{source:a._q.CurrencyService}),{currency:t,exchangeRates:{}})))}static map(e,t){return e.rates&&0!==e.rates.length?{currency:t,exchangeRates:Object.fromEntries(e.rates.map(e=>[e.source,e.exchangeRateAsk]))}:{currency:t,exchangeRates:{}}}}var n=r(51439);let s=e=>async(t,r)=>{let{exchangeRates:i}=r().context,{currency:a}=i,o=await l.get([a],e);t((0,n.HB)(o))};async function u(e,t,r){let{exchangeRates:i}=r().context,a=Object.keys(i.exchangeRates);if(0===e.filter(e=>!a.includes(e)).length)return;let o=await l.get(e,i.currency);t((0,n.HB)(o))}},20928:(e,t,r)=>{r.d(t,{S:()=>y});var i=r(32384),a=r(27560),o=r(69406),l=r(16752),n=r(80549),s=r(51125),u=r(19458),c=r(84713),d=r(8431),h=r(90897),m=r(79342);class f{static map(e){var t,r;let a=this.mapFindParameter(e),o={params:{abParam:"a",gaDeviceId:e.gaDeviceId},skipFallback:!0};if(a)return{requestParameter:{requestType:"ROOM",dateRange:{fromDate:e.arrival,toDate:e.departure},offerType:"NORMAL",roomRequests:this.mapRoomRequests(null!=(r=e.rooms)?r:[])},findParameter:a,recommendationParameter:e.idToken?{costCenterId:6012,distributionChannel:"SME",btc:o}:{costCenterId:6011,distributionChannel:"PRIVATE_WEB",btc:o},options:{offerServiceOptions:{crsTarget:"PRODUCTION",considerOnlyCrsByTypes:e.fastAvail?["HRS"]:e.crsType?[e.crsType]:h.jY,returnFailedHotelCauses:!0,buildAvgOffers:!1,strictRoomTypeHandling:!1,calculateCheaperOfferFromSecondaryRooms:!0,useNewTaxesAndFees:!0,provideNetAmount:!0,allowEconomyRoomSharedBath:!0,allowEconomyRoomWithBath:!0,skipBreakfastFilter:!1,flexOnly:null!=(t=e.amenities)&&!!t.includes(i.s.FREECANCELLATION)||void 0},dataServiceOptions:{pictureRequestParameter:{width:269,height:213}},useLegacyOa:!1,statusFilterType:"BOOKABLE",skipHotelsIfNoValidOffer:!e.requestHotelsWithoutAvailability}}}static mapRoomRequests(e){return e.map((e,t)=>this.mapRequest(e,t+1))}static mapRequest(e,t){let r=[];for(let t=1;t<=e.numberOfAdults;t+=1)r.push({extraBed:!1});let i=[];for(let t=0;t<e.children.length;t+=1)i.push({age:e.children[t].age,accommodation:this.mapChildAccommodationType(e.children[t].type)});return{roomNumber:t,roomType:e.type,occupancy:{adults:r,children:i}}}static mapChildAccommodationType(e){switch(e){case m.A.ExtraBed:return"EXTRA_BED";case m.A.ParentsBed:return"PARENTS_BED";case m.A.SeperateRoom:return"SEPARATE_ROOM";default:return"EXTRA_BED"}}static mapFindParameter(e){let t=(0,d.py)(e.language)===d.uf.miles?(0,d.ie)(e.vicinity):e.vicinity,r={matchGroup:"CITY",perimeter:0,maxPerimeter:1e3*t,matchType:"LOCATION"};if(e.hotelIds&&e.hotelIds.length>0)r.matchType="HOTEL_IDS",r.hotelIds=e.hotelIds;else if(e.poiId)r.matchGroup="POINT_OF_INTEREST",r.matchType="POI",r.poiId=e.poiId;else if(e.latitude&&e.longitude&&t>0)r.matchType="GEOCOORDINATE",r.geoCoordinate={latitude:e.latitude,longitude:e.longitude};else if(e.locationId)r.matchType="LOCATION",r.locationId=e.locationId;else if(e.latitude&&e.longitude&&t<=0)r.matchType="GEOCOORDINATE",r.geoCoordinate={latitude:e.latitude,longitude:e.longitude},r.maxPerimeter=3e4,JSON.stringify(e),o.Vy.error("Geocoordinates without vicinity",{source:o._q.SearchService,step:"RequestMapper",request:e,externalId:e.externalId});else{JSON.stringify(e),o.Vy.error("Invalid findParameters",{source:o._q.SearchService,step:"RequestMapper",request:e,externalId:e.externalId});return}return r}}var p=r(64549),v=r(28594),g=r(36159),R=r(18926);class A{static map(e,t,r,a,o){var l,n,s,u,c,d;let h=arguments.length>5&&void 0!==arguments[5]&&arguments[5],m=arguments.length>6&&void 0!==arguments[6]&&arguments[6],f=arguments.length>7&&void 0!==arguments[7]?arguments[7]:void 0,v=arguments.length>8&&void 0!==arguments[8]&&arguments[8],{hotelData:g,hotelOffer:R}=e,A=null==(l=g.parkingFeature)?void 0:l.parkingFree,T=(null==(n=g.parkingFeature)?void 0:n.parkingFree)||(null==(s=g.parkingFeature)?void 0:s.parkingAtTheHotelAvailable)||(null==(u=g.parkingFeature)?void 0:u.parkingHotelOwnedAvailable),E=null==(c=g.parkingFeature)?void 0:c.electricVehicleChargingAvailable,P=[];if(g.featureTypes&&g.featureTypes.length>0){let e=g.featureTypes;P=P.concat(e.map(e=>e.toUpperCase()))}return R&&R.roomCategories&&R.roomCategories.length>0&&(P=P.concat(R.roomCategories.map(e=>"ROOMCATEGORY_".concat(e.toUpperCase())))),E&&P.push(i.s.ELECTRICVEHICLECHARCHINGAVAILABLE),P.indexOf("INTERNET_WLANINROOM")>=0&&P.indexOf("INTERNET_FREEINTERNET_INROOM")>=0&&P.push(i.s.FREEWIFIINROOM),o||P.push(i.s.NOCREDITCARDREQUIRED),h&&P.pu
1sh(i.s.FREECANCELLATION),r===p.J.Inclusive&&P.push(i.s.BREAKFASTINCLUDED),!0===g.btcPaySupport&&("OPTIONAL"===g.btcPayStatus&&(P.push(i.s.BTCPAY_OPTIONAL),(null==R?void 0:R.crsType)==="HRS"&&(P.push(i.s.VOUCHER_ACCEPTED),P.push(i.s.VOUCHERS),P.push(i.s.PAYONLINE))),"MANDATORY"===g.btcPayStatus&&(P.push(i.s.BTCPAY_MANDATORY),P.push(i.s.VOUCHER_ACCEPTED),P.push(i.s.VOUCHERS),P.push(i.s.PAYONLINE))),A&&P.push(i.s.FREEPARKING),T&&P.push(i.s.PARKINGAVAILABLE),t.summaryAllHrs.ratingRatio&&t.summaryAllHrs.ratingRatio>=8==!0&&P.push(i.s.RATINGVERYGOOD),m&&P.push(i.s.NOPREPAYMENT),f&&P.push(i.s.PREPAYMENT),v&&P.push(i.s.BUSINESSTARIFF),(null==(d=g.receptionInfo)?void 0:d.find(e=>"MULTI_LINGUAL_PERSONAL_24H"===e||"RECEPTION_24H"===e))&&P.push(i.s.RECEPTION24H),a&&(a.cleanAndSafeExpertInspected&&P.push(i.s.CLEANANDSAFEEXPERT),a.cleanAndSafeSelfInspected&&P.push(i.s.CLEANANDSAFESELFINSPECTED),a.greenStay&&P.push(i.s.GREENSTAY)),P}}class T{static map(e,t){var r;let{geoCoordinate:i}=e,{distanceCityCenter:a,distanceRailway:o,distanceAirport:l}=e.hotelData,n=t.latitude&&t.longitude&&(null==i?void 0:i.latitude)&&i.longitude?(0,d.Yf)(t.latitude,t.longitude,i.latitude,i.longitude):void 0,s=this.mapDistance(o),u=this.mapDistance(l);return{toSubject:n,toCityCenter:(null==a||null==(r=a.distance)?void 0:r.distance)&&a.distance.distance>0?a.distance.distance:void 0,toTrainStations:s?[s]:[],toAirports:u?[u]:[],toHighways:[],toOtherPois:[]}}static mapDistance(e){var t;if((null==e||null==(t=e.distance)?void 0:t.distance)&&0!==e.distance.distance)return{distance:e.distance.distance,description:e.name,type:e.distanceNameType}}}var E=r(31732),P=r(57281);class N{static map(e,t,r,i,a){var o,l,n,s,u,c,d,h,m,f,p,v,g,R,A,T,N,O,y,I,S,C,D,b,L,_,H,B,U,F,M,w,G;let k=e>0,V=t>0,x=e+t,q=null==(o=i.avgOffers)?void 0:o.SINGLEROOM,Y=null==(l=i.avgOffers)?void 0:l.DOUBLEROOM,W=null==(n=i.businessTravellerPrices)?void 0:n.SINGLEROOM,K=null==(s=i.businessTravellerPrices)?void 0:s.DOUBLEROOM,j=null==q?void 0:q.wasPricePerNightAndRoom,J=null==Y?void 0:Y.wasPricePerNightAndRoom,X=(null==Y?void 0:Y.totalAvailCount)&&Y.totalAvailCount>0,z=!!(q&&q.totalAvailCount&&q.totalAvailCount>0&&e>q.totalAvailCount)&&X,Q=z&&q.totalAvailCount?q.totalAvailCount:e,$=z&&q.totalAvailCount&&q.totalAvailCount>0?e-q.totalAvailCount+t:t,Z=z||k&&V,ee={corporateDiscountPossible:!1,isDiscount:!1};if(k&&!V&&!Z&&(q&&(null==(g=q.pricePerNightAndRoom)?void 0:g.amount)&&q.pricePerNightAndRoom.amount>0?ee=this.mapOfferDetails(q,e,r,W,j):Y&&(null==(R=Y.pricePerNightAndRoom)?void 0:R.amount)&&Y.pricePerNightAndRoom.amount>0&&(ee=this.mapOfferDetails(Y,e,r,K,J))),!k&&V&&Y&&(null==(u=Y.pricePerNightAndRoom)?void 0:u.amount)&&Y.pricePerNightAndRoom.amount>0&&(ee=this.mapOfferDetails(Y,t,r,K,J)),Z&&Y&&(!q||(null==(c=q.pricePerNightAndRoom)?void 0:c.amount)&&q.pricePerNightAndRoom.amount>0)&&(null==(d=Y.pricePerNightAndRoom)?void 0:d.amount)&&Y.pricePerNightAndRoom.amount>0&&(!q||(null==(h=q.pricePerNightAndRoom)?void 0:h.currency)===Y.pricePerNightAndRoom.currency)){let i=Q*((null==q||null==(A=q.pricePerNightAndRoom)?void 0:A.amount)&&q.pricePerNightAndRoom.amount>0?q.pricePerNightAndRoom.amount:0),a=$*Y.pricePerNightAndRoom.amount;ee.averagePrice={amount:(i+a)/x,currency:Y.pricePerNightAndRoom.currency},(null==q||null==(T=q.meal)?void 0:T.availability)===(null==(N=Y.meal)?void 0:N.availability)&&(null==q||null==(I=q.meal)||null==(y=I.meal)||null==(O=y.price)?void 0:O.amount)===(null==(D=Y.meal)||null==(C=D.meal)||null==(S=C.price)?void 0:S.amount)&&(null==q||null==(_=q.meal)||null==(L=_.meal)||null==(b=L.price)?void 0:b.currency)===(null==(U=Y.meal)||null==(B=U.meal)||null==(H=B.price)?void 0:H.currency)&&(ee.meal=null==q?void 0:q.meal),((null==q||null==(F=q.offerLabel)?void 0:F.corporateDiscountPossible)||(null==(M=Y.offerLabel)?void 0:M.corporateDiscountPossible))&&(ee.corporateDiscountPossible=!0);let o=W&&K?this.mapMixedRoomBusinessTravellerPrices(W,K,Q,$,x,r):void 0;if(ee.businessTravellerPrice=null==o?void 0:o.businessTravellerPrice,ee.businessTravellerTotalPrice=null==o?void 0:o.businessTravellerTotalPrice,ee.businessTravellerTotalDiscountInPercentage=null==o?void 0:o.businessTravellerTotalDiscountInPercentage,j&&J&&(ee.strikeThroughTotalPrice={amount:(j.amount*e+J.amount*t)*r,currency:j.currency}),(null==(w=Y.offerLabel)?void 0:w.discountType)!==void 0&&(null==q||null==(G=q.offerLabel)?void 0:G.discountType)!==void 0&&Y.offerLabel.discountType===q.offerLabel.discountType&&Y.offerLabel.freenightsDurationDays===q.offerLabel.freenightsDurationDays&&Y.offerLabel.freenightsChargedDays===q.offerLabel.freenightsChargedDays){let e=this.mapDiscountType(Y.offerLabel.discountType);ee.isDiscount=void 0!==e,ee.discountType=e,e===P.o.FREE_NIGHTS&&Y.offerLabel.freenightsDurationDays&&Y.offerLabel.freenightsChargedDays&&(ee.freeNights=Y.offerLabel.freenightsDurationDays-Y.offerLabel.freenightsChargedDays)}}return ee.averageSingleRoomPricePerNightAndRoom=Q>0?null==q?void 0:q.pricePerNightAndRoom:void 0,ee.averageDoubleRoomPricePerNightAndRoom=$>0?null==Y?void 0:Y.pricePerNightAndRoom:void 0,ee.totalPrice=i.totalPrice,!ee.businessTravellerTotalDiscountInPercentage&&i.totalBusinessTravellerDiscount&&i.totalBusinessTravellerDiscount>0&&(ee.businessTravellerTotalDiscountInPercentage=i.totalBusinessTravellerDiscount),ee.totalAvailCountSingleRoom=null==(f=i.avgOffers)||null==(m
1=f.SINGLEROOM)?void 0:m.totalAvailCount,ee.totalAvailCountDoubleRoom=null==(v=i.avgOffers)||null==(p=v.DOUBLEROOM)?void 0:p.totalAvailCount,(0,E.v)(ee,a),ee}static mapMixedRoomBusinessTravellerPrices(e,t,r,i,a,o){var l,n;let s,u,c;if((e.businessTravellerDiscountPerNight>0||t.businessTravellerDiscountPerNight>0)&&(null==(l=e.businessTravellerPricePerNight)?void 0:l.amount)&&e.businessTravellerPricePerNight.amount>0&&(null==(n=t.businessTravellerPricePerNight)?void 0:n.amount)&&t.businessTravellerPricePerNight.amount>0&&e.businessTravellerPricePerNight.currency===t.businessTravellerPricePerNight.currency){let l=e.businessTravellerPrice.amount+t.businessTravellerPrice.amount;s={amount:l/a/o,currency:e.businessTravellerPricePerNight.currency},u={amount:l,currency:e.businessTravellerPricePerNight.currency},c=(e.businessTravellerDiscountPerNight*r+t.businessTravellerDiscountPerNight*i)/a}return{businessTravellerPrice:s,businessTravellerTotalPrice:u,businessTravellerTotalDiscountInPercentage:c}}static mapOfferDetails(e,t,r,i,a){var o,l,n,s;let u,c,d;e.pricePerNightAndRoom&&a&&e.pricePerNightAndRoom.amount<a.amount&&(u=a,c={amount:a.amount,currency:a.currency},c.amount*=r*t);let h=this.mapDiscountType(null==(o=e.offerLabel)?void 0:o.discountType);h===P.o.FREE_NIGHTS&&(null==(l=e.offerLabel)?void 0:l.freenightsDurationDays)&&e.offerLabel.freenightsChargedDays&&(d=e.offerLabel.freenightsDurationDays-e.offerLabel.freenightsChargedDays);let m=void 0!==h;return{averagePrice:e.pricePerNightAndRoom,meal:e.meal,corporateDiscountPossible:null!=(s=null==(n=e.offerLabel)?void 0:n.corporateDiscountPossible)&&s,businessTravellerPrice:i?this.mapBusinessTravellerPrice(i,t,m):void 0,businessTravellerTotalPrice:i?this.mapBusinessTravellerTotalPrice(i,m):void 0,strikeThroughPrice:u,strikeThroughTotalPrice:c,businessTravellerTotalDiscountInPercentage:i?i.businessTravellerDiscount:void 0,isDiscount:m,discountType:h,freeNights:d}}static mapDiscountType(e){if(e)switch(e){case"EARLY_BIRD":return P.o.EARLY_BIRD;case"LAST_MINUTE":return P.o.LAST_MINUTE;case"LONGTERM":return P.o.LONGTERM;case"FREE_NIGHTS":return P.o.FREE_NIGHTS;case"MOBILE":return P.o.MOBILE;default:return}}static mapBusinessTravellerPrice(e,t,r){var i,a,o,l;if(!(e.businessTravellerDiscountPerNight<=0)||r)return{amount:(null!=(o=null==(i=e.businessTravellerPricePerNight)?void 0:i.amount)?o:0)/t,currency:null!=(l=null==(a=e.businessTravellerPricePerNight)?void 0:a.currency)?l:""}}static mapBusinessTravellerTotalPrice(e,t){if(e&&(!(e.businessTravellerDiscountPerNight<=0)||t))return{amount:e.businessTravellerPrice.amount,currency:e.businessTravellerPrice.currency}}}class O{static map(e,t,r,i){let a=null==e?void 0:e.hotels;if(!a)return{offers:[],notAllHotelTeasersFound:!1,isIncompleteResult:t.fastAvail,transactionId:t.transactionId,filterCount:{countedAmenities:{},countedChains:{}},hrsTraceId:r,hrsRequestId:i};let o=[];for(let e=0;e<a.length;e+=1){let r,i=a[e];(i.hotelOffer||t.hotelTeaserKeys.includes(i.hotelId)||t.hotelTeaserByName&&i.hotelData.hotelName.toLocaleLowerCase().indexOf(t.hotelTeaserByName.toLocaleLowerCase())>=0)&&(r=i.hotelOffer?this.mapHotelWithOffer(i,t):this.mapHotelWithoutOffer(i,t)),void 0!==r&&(r.defaultSortOrder=e,o.push(r))}return{offers:o,notAllHotelTeasersFound:!1,isIncompleteResult:t.fastAvail,transactionId:t.transactionId,filterCount:{countedAmenities:{},countedChains:{}},hrsTraceId:r,hrsRequestId:i}}static mapHotelWithoutOffer(e,t){let r=this.mapHotelRatingSummaries(e.hotelData.averageRating),i=g.$.map(e.hotelData.hotelAuditData,e.hotelData.cleanAndSafeCertifications),a=A.map(e,r,p.J.Unknown,i,!0);return{hotel:this.mapHotel(e,t.language),distances:T.map(e,t),hotelRatingSummaries:r,amenities:a,mealAvailability:p.J.Unknown,mealType:v.o.UNKNOWN,corporateDiscountPossible:!1,showPromoLabel:!1,filtered:!1,isOfferUnavailable:!0,isBusinessTariff:!1,creationTime:new Date,hotelAudit:i,isDiscount:!1}}static mapHotelWithOffer(e,t){var r,i,a,l,s,c,d,h,m,f;let p=(0,n.TO)(t.arrival,t.departure);if(!e.hotelOffer)return;let{totalPrice:v,averagePrice:R,averageSingleRoomPricePerNightAndRoom:E,averageDoubleRoomPricePerNightAndRoom:P,meal:O,businessTravellerPrice:y,businessTravellerTotalPrice:I,businessTravellerTotalDiscountInPercentage:S,corporateDiscountPossible:C,strikeThroughPrice:D,strikeThroughTotalPrice:b,totalAvailCountSingleRoom:L,totalAvailCountDoubleRoom:_,isDiscount:H,discountType:B,freeNights:U}=N.map(null!=(l=t.rooms&&t.rooms.filter(e=>e.type===u.C.SINGLEROOM).length)?l:0,null!=(s=t.rooms&&t.rooms.filter(e=>e.type===u.C.DOUBLEROOM).length)?s:0,p,e.hotelOffer,void 0!==t.idToken);if(!R||!v)return;if("EUR"===R.currency&&R.amount>4e3)return void o.Vy.log({message:"Filtered too expensive offer",hotelName:e.hotelData.hotelName,city:e.hotelData.cityName,country:e.hotelData.country,chainHierarchy:null==(c=e.hotelData.chainHierarchy)?void 0:c.concat(", "),hotelId:e.hotelId,crs:e.hotelOffer.crsType,arrival:t.arrival,departure:t.departure,averagePrice:R.amount,averagePriceCurrency:R.currency,source:o._q.SearchServiceResponseMapper});let F=void 0!==t.idToken,M=["FLEX","BUSINESS_FLEX"].includes(null!=(d=e.hotelOffer.tariffType)?d:""),w="MANDATORY"===e.hotelData.btcPayStatus,G=e.hotelData.btcPaySupport&&w,k=!G&&M,V=!!G||void 0,x=!!G||!(null==(r=e.hotelOffer.reservationOptions)?void 0:r.includes("STANDARD")),q=null!=(h=null==O?void 0:O.availability)?h:"NOT_AVAILABLE",Y=null!=(m=null==O||null==(i=O.meal)?void 0:i.type)?m:"UNKNOWN",W=null!=(f=null==(a=e.hotelOffer.tariffType)?void 0:a.toLocaleUpperCase().includes("BUSINESS"))&&f,K=!0,j=!1;F?j=W:(j=void 0!==y||C||void 0!==S&&S>0,void 0!==S&&S<=0&&(K=!1));let J=this.mapHotelRatingSummaries(e.hotelData.averageRating),X=g.$.map(e.hotelData.hotelAuditData,e.hotelData.cleanAndSafeCertifications),z=A.map(e,J,q,X,x,M,k,V,j);return{hotel:this.mapHotel(e,t.language),totalPrice:this.mapPriceNotNull(v),pricePerNightAndRoom:this.mapPriceNotNull(R),pricePerNightAndSingleRoom:E?this.mapPriceNotNull(E):void 0,pricePerNightAndDoubleRoom:P?this.mapPriceNotNull(P):void 0,strikeThroughPrice:D?this.mapPriceNotNull(D):void 0,strikeThroughTotalPrice:b?this.mapPriceNotNull(b):void 0,businessTravellerPricePerNightAndRoom:y?this.mapPriceNotNull(y):void 0,businessTravellerTotalPrice:I?this.mapPriceNotNull(I):void 0,businessTravellerTotalDiscountInPercentage:S,isBusinessTariffCheaper:K,isBusinessTariff:W,corporateDiscountPossible:C,breakfastPrice:this.mapMealplan(O),showPromoLabel:!!(e.hotelOffer.topRankingBooster&&e.hotelOffer.topRankingBooster>0),mealAvailability:q,mealType:Y,distances:T.map(e,t),hotelRatingSummaries:J,amenities:z,noPrePaymentNeeded:k,prePaymentNeeded:V,isCancellableFreeOfCharge:M,filtered:!1,isOfferUnavailable:!1,tariffType:e.hotelOffer.tariffType,roomCategories:e.hotelOffer.roomCategories,crsType:e.hotelOffer.crsType,creationTime:new Date,hotelAudit:X,totalAvailCountSingleRoom:L&&L<=6&&L>0?L:void 0,totalAvailCountDoubleRoom:_&&_<=6&&_>0?_:void 0,isDiscount:H,discountType:B,creditCardRequired:x,freeNights:U}}static mapHotel(e,t){var r,i,a,o,l,n,s,u,c,d,h;let{hotelId:m,hotelData:f,geoCoordinate:p}=e,v=null!=(l=null==(r=f.thumbnailPicture)?void 0:r.picture.cachedPicturePath)?l:null==(i=R.S.map(f.thumbnailPicture,t,269,213))?void 0:i.url;return{id:m,name:f.hotelName,address:{cityWithDistrict:f.districtName?"".concat(f.locationName,", ").concat(f.districtName):f.locationName,city:f.locationName,country:f.country,postalCode:f.zipCode},imageUrl:v,latitude:null!=(n=null==p?void 0:p.latitude)?n:0,longitude:null!=(s=null==p?void 0:p.longitude)?s:0,numberOfStars:null!=(u=null==(a=f.hotelCategory)?void 0:a.hrsStars)?u:0,chains:null!=(c=f.chainHierarchy)?c:[],overlookHotel:f.overlookHotel,btcPaySupport:null!=(d=f.btcPaySupport)&&d,hasVeryGoodRating:null!=(h=(null==(o=f.averageRating)?void 0:o.ratings)&&f.averageRating.ratings.ALLHRS>=8)&&h,btcPayStatus:f.btcPayStatus}}static mapHotelRatingSummaries(e){if(!e)return{summaryAllHrs:{numberOfHotelRatings:0},summaryPrivate:{numberOfHotelRatings:0},summaryBusiness:{numberOfHotelRatings:0}};let{ratings:t,numberOfRatings:r}=e;return{summaryAllHrs:{ratingRatio:(null==t?void 0:t.ALLHRS)&&t.ALLHRS>0?t.ALLHRS:void 0,numberOfHotelRatings:r.ALLHRS},summaryPrivate:{ratingRatio:(null==t?void 0:t.PRIVATE)&&t.PRIVATE>0?t.PRIVATE:void 0,numberOfHotelRatings:r.PRIVATE},summaryBusiness:{ratingRatio:(null==t?void 0:t.BUSINESS)?t.BUSINESS:void 0,numberOfHotelRatings:r.BUSINESS}}}static mapPriceNotNull(e){return{amount:e.amount,currency:e.currency}}static mapMealplan(e){var t;if(null==e||null==(t=e.meal)?void 0:t.price)return this.mapPriceNotNull(e.meal.price)}}class y{static async get(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:29e3;e.rooms&&0!==e.rooms.length||(e.rooms=[{children:[],numberOfAdults:1,type:u.C.SINGLEROOM}],o.Vy.error("Rooms are not defined",{source:o._q.SearchService,request:e})),e.gaDeviceId=this.getGaCookie();let r=f.map(e),i={offers:[],filterCount:{countedAmenities:{},countedChains:{}},notAllHotelTeasersFound:!1,isIncompleteResult:e.fastAvail};if(!r)return i;let n="".concat(l.T.apiConfig.hotelListEndpoint,"/v2/hotel-search/hotels"),d=(0,a.A)(),h=new Headers;return h.append("Content-Type","application/json"),h.append("Accept-Encoding","gzip"),h.append("x-client-language",(0,c.Op)(e.language)),h.append("x-client-id",(0,c.Jf)(e.forceDevice)),h.append("x-hrs-session-id",d),e.idToken&&h.append("Authorization","Bearer ".concat(e.idToken)),(0,s.u)(n,{method:"POST",redirect:"follow",headers:h,body:JSON.stringify(r)},t).then(async t=>{let i=(0,c.df)(t);if(!t.ok){var a;return(0,c.YT)(t,n,{source:o._q.SearchService,request:r,isFastAvail:e.fastAvail.toString(),userAgent:window.navigator.userAgent.toLowerCase(),xsessionId:d,additionalInfo:null!=(a=t.headers.get("via"))?a:""}),{hotelSearchResponse:void 0,hrsTraceId:i.hrsTraceId,hrsRequestId:i.hrsRequestId}}return{hotelSearchResponse:await t.json(),hrsTraceId:i.hrsTraceId,hrsRequestId:i.hrsRequestId}}).then(e=>e).then(t=>{let i=O.map(t.hotelSearchResponse,e,t.hrsTraceId,t.hrsRequestId);
1return this.logNewrelicPageAction(t,e,i,r,n,d),i}).catch(t=>(this.logError(t,r,n,e,d),i))}static logNewrelicPageAction(e,t,r,a,o,l){try{if(window.newrelic){var s,c,d,h,m,f,p;let a=this.getAverageEuroPrices(r.offers),o=r.offers.slice(0,5),l=this.getAverageEuroPrices(o),v={locationId:t.locationId,language:t.language,fastAvail:t.fastAvail,requestHotelsWithoutAvailability:t.requestHotelsWithoutAvailability,arrivalDaysInFuture:t.arrival?(0,n.GS)((0,n.Ec)(),new Date(t.arrival)):void 0,lengthOfStay:t.arrival&&t.departure?(0,n.GS)(new Date(t.arrival),new Date(t.departure)):void 0,customerId:t.customerId,isLoggedIn:void 0!==t.idToken,numberOfAdults:null==(s=t.rooms)?void 0:s.reduce((e,t)=>e+t.numberOfAdults,0),numberOfChildren:null==(c=t.rooms)?void 0:c.reduce((e,t)=>e+t.children.length,0),numberOfSingleRooms:null==(d=t.rooms)?void 0:d.reduce((e,t)=>e+ +(t.type===u.C.SINGLEROOM),0),numberOfDoubleRooms:null==(h=t.rooms)?void 0:h.reduce((e,t)=>e+ +(t.type===u.C.DOUBLEROOM),0),numberOfHotels:null!=(p=null==(f=e.hotelSearchResponse)||null==(m=f.hotels)?void 0:m.length)?p:0,numberOfMappedHotels:r.offers.length,numberOfBusinessTariffs:r.offers.filter(e=>!0===e.isBusinessTariff).length,AVG_SINGLE_EUR:a.averageSingleRoomPriceInEuro,AVG_DOUBLE_EUR:a.averageDoubleRoomPriceInEuro,AVG_ALL_EUR:a.averagePriceInEuro,AVG_SINGLE_EUR_TOP5:l.averageSingleRoomPriceInEuro,AVG_DOUBLE_EUR_TOP5:l.averageDoubleRoomPriceInEuro,AVG_ALL_EUR_TOP5:l.averagePriceInEuro,A_C_BREAKFASTINCLUDED:r.offers.filter(e=>e.amenities.includes(i.s.BREAKFASTINCLUDED)).length,A_C_FREECANCELLATION:r.offers.filter(e=>e.amenities.includes(i.s.FREECANCELLATION)).length,A_C_PARKING:r.offers.filter(e=>e.amenities.includes(i.s.PARKING)).length,A_C_FREEWIFIINROOM:r.offers.filter(e=>e.amenities.includes(i.s.FREEWIFIINROOM)).length,A_C_RATINGVERYGOOD:r.offers.filter(e=>e.amenities.includes(i.s.RATINGVERYGOOD)).length,A_C_NOPREPAYMENT:r.offers.filter(e=>e.amenities.includes(i.s.NOPREPAYMENT)).length,A_C_PAYONLINE:r.offers.filter(e=>e.amenities.includes(i.s.PAYONLINE)).length,A_C_NOCREDITCARDREQUIRED:r.offers.filter(e=>e.amenities.includes(i.s.NOCREDITCARDREQUIRED)).length,A_C_VOUCHER_ACCEPTED:r.offers.filter(e=>e.amenities.includes(i.s.VOUCHER_ACCEPTED)).length,CRS_HRS:r.offers.filter(e=>"HRS"===e.crsType).length,CRS_EAN:r.offers.filter(e=>"EAN"===e.crsType).length,CRS_AMADEUS:r.offers.filter(e=>"AMADEUS"===e.crsType).length,CRS_IHG:r.offers.filter(e=>"IHG"===e.crsType).length,CRS_DERBYSOFT:r.offers.filter(e=>"DERBYSOFT"===e.crsType).length,CRS_SOLMELIA:r.offers.filter(e=>"SOLMELIA"===e.crsType).length,CRS_BCOM:r.offers.filter(e=>"BCOM"===e.crsType).length,CRS_OTHER:r.offers.filter(e=>void 0!==e.crsType&&!["HRS","EAN","AMADEUS","IHG","DERBYSOFT","SOLMELIA","BCOM"].includes(e.crsType)).length};window.newrelic.addPageAction("SearchService - new response received",v)}}catch(e){this.logError(e,a,o,t,l)}}static getAverageEuroPrices(e){if(!e||0===e.length)return{averagePriceInEuro:void 0,averageSingleRoomPriceInEuro:void 0,averageDoubleRoomPriceInEuro:void 0};let t=e.filter(e=>{var t,r;return["EUR"].includes(null!=(r=null==(t=e.pricePerNightAndRoom)?void 0:t.currency)?r:"")}),r=t.length,i=t.reduce((e,t)=>{var r,i;return e+(null!=(i=null==(r=t.pricePerNightAndDoubleRoom)?void 0:r.amount)?i:0)},0),a=e.filter(e=>{var t,r;return["EUR"].includes(null!=(r=null==(t=e.pricePerNightAndSingleRoom)?void 0:t.currency)?r:"")}),o=a.length,l=a.reduce((e,t)=>{var r,i;return e+(null!=(i=null==(r=t.pricePerNightAndSingleRoom)?void 0:r.amount)?i:0)},0),n=e.filter(e=>{var t,r;return["EUR"].includes(null!=(r=null==(t=e.pricePerNightAndDoubleRoom)?void 0:t.currency)?r:"")}),s=n.length,u=n.reduce((e,t)=>{var r,i;return e+(null!=(i=null==(r=t.pricePerNightAndDoubleRoom)?void 0:r.amount)?i:0)},0);return{averagePriceInEuro:i&&r>0?i/r:void 0,averageSingleRoomPriceInEuro:l&&o>0?l/o:void 0,averageDoubleRoomPriceInEuro:u&&s>0?u/s:void 0}}static logError(e,t,r,i,a){o.Vy.error(e,{source:o._q.SearchService,request:t,status:-2,url:r,xsessionId:a,isFastAvail:i.fastAvail.toString(),userAgent:window.navigator.userAgent.toLowerCase()})}}y.getGaCookie=()=>{try{if(void 0===window.document||void 0===window.document.cookie)return;let e=document.cookie.split("; ").find(e=>e.startsWith("".concat("_ga","=")));if(!e)return void o.Vy.log({source:o._q.SearchService,message:"No GA cookie found",cookieName:"_ga"});return decodeURIComponent(e.split("=")[1])}catch(e){o.Vy.error(e,{source:o._q.SearchService,message:"Error while getting GA cookie"});return}}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.