1(window.webpackJsonp=window.webpackJsonp||[]).push([[75],{1568:function(e,t,r){},1712:function(e,t,r){"use strict";r(1568)},909:function(e,t,r){"use strict";r.r(t);var a=r(180),n=r(11),i=r(156),o=r(853),s=r(17),l=r(15),c=r(982),u=r(40),d={name:"ReceiptModal",props:{otaUrl:{type:String,default:""}},data:function data(){return{seconds:3,timerInterval:null}},methods:{showModal:function showModal(){var e=this;this.timerInterval=setInterval((function(){e.seconds>0?e.seconds--:e.$emit("continue")}),1e3)},hideModal:function hideModal(){this.resetTimer()},resetTimer:function resetTimer(){clearInterval(this.timerInterval),this.seconds=3}}},m=r(33),b=Object(m.a)(d,(function render(){var e=this,t=e._self._c;return t("b-modal",{attrs:{id:"confirm-ota-modal",centered:"","footer-class":"single-btn","hide-footer":"","hide-header-close":"","no-close-on-backdrop":""},on:{show:e.showModal,hide:e.hideModal}},[t("h5",{staticClass:"font-weight-bold mb-3"},[e._v(e._s(e.$t("searchReservation.confirmReservation")))]),e._v(" "),t("i18n",{attrs:{tag:"p",path:"searchReservation.confirmReservationDesc"},scopedSlots:e._u([{key:"ota",fn:function fn(){return[t("a",{staticClass:"link",attrs:{href:e.otaUrl||"#",target:"_blank"}},[e._v(e._s(e.$t("base.triplaAi")))])]},proxy:!0},{key:"time",fn:function fn(){return[e._v(e._s(e.seconds))]},proxy:!0}])})],1)}),[],!1,null,null,null).exports,h=r(122),v=r(31),g=r(70);function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,a)}return r}function _defineProperty(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var p={name:"SearchReservation",components:{FormError:i.a,ConfirmOtaModal:b},props:{code:{type:String,required:!0}},data:function data(){return{isLoading:!1,email:null,reservationNumber:null,errors:null,otaUrl:""}},computed:function _objectSpread(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ownKeys(r,!0).forEach((function(t){_defineProperty(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ownKeys(r).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({},Object(u.d)({initialSetting:"setting/getInit"})),created:function created(){var e=this;return this.$store.dispatch("setting/setSetting",{code:this.code}),s.a.getData(Object(l.O)()).then((function(t){e.$store.dispatch("setting/setInit",{hotelBrand:t.hotel_brand,bookingWidgetSetting:t.booking_widget_setting_attributes,hotelBrandSetting:t.hotel_brand_setting,paymentGatewaySetting:t.payment_gateway_setting,mcpPaymentGatewaySetting:t.mcp_payment_gateway_setting,availableLanguages:t.available_languages,bwToOTAEnabled:null==t?void 0:t.bw_to_ota_enabled})})).catch((function(t){console.warn(t),e.$logger.error(t),e.$store.dispatch("error/setInitError",t.error)}))},methods:{submitForm:function submitForm(){var e=this;this.$v.$touch(),this.$v.$invalid||(this.isLoading=!0,a.a.search({email:this.email,reservationNumber:this.reservationNumber}).then((function(t){if(t.status===h.e.PAYMENT_PENDING)throw new Error(e.$t("searchReservation.searchFailed"));e.$store.dispatch("booking/setReservationDetails",t),e.otaUrl="".concat("https://tripla.ai","/reservation/confirmation/").concat(e.reservationNumber,"?bypass_token=").concat(t.bypass_token,"&code=").concat(t.triplabot_code);var r={code:t.triplabot_code};return e.$store.dispatch("setting/setSetting",r),s.a.getData(Object(l.O)()).then((function(a){t.booking_method===h.a.BOOKING_WIDGET_TO_TRIPLA_OTA?(e.$bvModal.show("confirm-ota-modal"),e.isLoading=!1,e.errors=null):(e.$store.dispatch("setting/setInit",{hotelBrand:a.hotel_brand,bookingWidgetSetting:a.booking_widget_setting_attributes,hotelBrandSetting:a.hotel_brand_setting,paymentGatewaySetting:a.payment_gateway_setting,mcpPaymentGatewaySetting:a.mcp_payment_gateway_setting,availableLanguages:a.available_languages,bwToOTAEnabled:null==a?void 0:a.bw_to_ota_enabled}),e.$store.dispatch("setting/setDefaultSearch",a.booking_widget_setting_attributes.default_search_setting),e.isLoading=!1,e.errors=null,e.$router.push({name:n.a.reservation.confirmation,params:{confirmationNumber:e.reservationNumber},query:{code:r.code,bypass_token:t.bypass_token}}))}))})).catch((function(){e.errors=e.$t("searchReservation.searchFailed"),e.isLoading=!1})))},goToOtaReservation:function goToOtaReservation(){Object(v.f)()?window.parent.location=this.otaUrl:Object(g.f)(this.otaUrl)}},validations:{email:{required:o.required,email:o.email},reservationNumber:{required:o.required,onlyEnAndNumber:c.l}}},_=(r(1712),Object(m.a)(p,(function render(){var e=this,t=e._self._c;return t("b-container",[t("form",{staticClass:"search-form",on:{submit:function submit(t){return t.preventDefault(),e.submitForm.apply(null,arguments)}}},[t("form-error",{attrs:{errors:e.errors,outline:""}}),e._v(" "),t("h3",[e._v(e._s(e.$t("searchReservation.manageBooking")))]),e._v(" "),t("p",{staticClass:"caption"},[e._v(e._s(e.$t("searchReservation.enterDetail")))]),e._v(" "),t("label",{staticClass:"form-label",attrs:{for:"email"}},[e._v(e._s(e.$t("guestDetail.email",{email:e.initialSetting&&e.initialSetting.email_send_from})))]),e._v(" "),t("b-form-input",{attrs:{id:"email","data-cy":"email-search",placeholder:e.$t("guestDetail.emailHelp"),maxlength:255,state:e.$v.email.$dirty?!e.$v.email.$error:null},on:{blur:function blur(t){return e.$v.email.$touch()}},model:{value:e.email,callback:function callback(t){e.email=t},expression:"email"}}),e._v(" "),t("label",{staticClass:"form-label",attrs:{for:"reservationNumber"}},[e._v(e._s(e.$t("reservationDetail.reservationNumber")))]),e._v(" "),t("b-form-input",{attrs:{id:"reservationNumber","data-cy":"reservation-number-search",placeholder:e.$t("searchReservation.enterReservationNumber"),state:e.$v.reservationNumber.$dirty?!e.$v.reservationNumber.$error:null,maxlength:20},on:{blur:function blur(t){return e.$v.reservationNumber.$touch()}},model:{value:e.reservationNumber,callback:function callback(t){e.reservationNumber=t},expression:"reservationNumber"}}),e._v(" "),t("b-button",{directives:[{name:"theme-btn",rawName:"v-theme-btn"}],staticClass:"w-100 mt-3",attrs:{type:"submit","data-cy":"continue-search",disabled:e.isLoading}},[t("b-spinner",{directives:[{name:"show",rawName:"v-show",value:e.isLoading,expression:"isLoading"}],staticClass:"btn-spinner",attrs:{small:""}}),e._v(e._s(e.$t("base.continue")))],1)],1),e._v(" "),t("confirm-ota-modal",{attrs:{"ota-url":e.otaUrl},on:{continue:e.goToOtaReservation}})],1)}),[],!1,null,"f826b65a",null));t.default=_.exports}}]); 2//# sourceMappingURL=page-SearchReservation-index-vue.3b7f1defcb62234b509a.js.map
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.