(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["c29f82f4"],{5177:function(t,e,r){"use strict";var a=r("1528"),s=a["a"].setScrollPosition,n=function(){var t=document.querySelector(".q-field-with-error");s(window,t.offsetTop,750)};e["a"]={methods:{scrollToError:function(){return window.setTimeout(function(){n()},250),!1}}}},"782e":function(t,e,r){"use strict";var a=r("9219"),s=r.n(a);s.a},9219:function(t,e,r){},fb4b5:function(t,e,r){"use strict";r.r(e);var a=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("q-page",{attrs:{"data-test":t.CypressTarget("SeatsNamePage"),padding:""}},[r("div",{staticClass:"row gutter-md"},[r("div",{staticClass:"col-xs-12 col-sm-12 col-md-12 col-lg-10"},[r("div",{staticClass:"row"},[r("div",{staticClass:"col-xs-12"},[r("h5",{staticClass:"q-mb-md q-mt-sm checkout-customFields-title"},[t._v("\n            "+t._s(t.$t("label.customFields"))+"\n          ")])])]),r("div",{staticClass:"row justify-start"},t._l(t.eventsFields,function(e,a){return r("div",{key:a,staticClass:"col-xs-12 col-md-6 q-pa-sm"},[r("product-group",{staticClass:"full-width checkout-customFields-group",attrs:{"group-title":e.name,"event-date":e.dateTime}},[r("form-dynamic",{ref:"dynamicForm",refInFor:!0,staticClass:"q-mr-sm q-ml-sm q-mb-sm",attrs:{value:t.eventValuesById(e.eventId),fields:e.customFields,"get-upload-url":t.getUploadUrl},on:{input:function(r){t.answerQuestions({eventId:e.eventId,responses:r})}}})],1)],1)}))])]),r("div",{staticClass:"row justify-end"},[r("div",{staticClass:"col-xs-12 col-md-4 col-lg-4"},[r("q-field",{staticClass:"full-width",attrs:{"data-test":t.CypressTarget("Buttons")}},[r("q-btn",{staticClass:"full-width",attrs:{color:t.SET_COLOR_BUTTON.primary,"text-color":t.SET_COLOR_BUTTON.text.primary,"data-test":t.CypressTarget("Identification"),label:t.advanceText,"icon-right":"fa fa-arrow-right",rounded:""},on:{click:t.advance}})],1)],1)])])},s=[];a._withStripped=!0;r("ac6a");var n=r("7936"),i=r.n(n),o=(r("a481"),r("96cf"),r("c973")),c=r.n(o),u=r("3156"),l=r.n(u),d=r("57d5"),m=r("2f62"),h=r("5177"),p={name:"CustomFieldsCheckout",components:{FormDynamic:function(){return Promise.all([r.e("vuelidate"),r.e("2d0aab74"),r.e("2d228866")]).then(r.bind(null,"da0c"))},ProductGroup:function(){return Promise.all([r.e("luxon"),r.e("2d226d26"),r.e("2d0a44aa"),r.e("2d0dacf8"),r.e("a4bdb444")]).then(r.bind(null,"9285"))}},mixins:[h["a"]],data:function(){return{}},computed:l()({},Object(m["c"])("customFields",["hasEventsFields","eventsFields","eventValuesById"]),Object(m["c"])("ticketShoppingCart",["cartOrderCode","cartFinalTotal","itemsInCart","seatsNamesGrouped"]),Object(m["c"])("user",["customerCode"]),Object(m["c"])("delivery",["hasDeliveryMethod"]),{advanceText:function(){return this.SET_CONFIG.checkout.seatName.active?this.$t("button.next"):this.hasDeliveryMethod?this.$t("button.delivery"):this.cartFinalTotal>0?this.$t("button.pay"):this.$t("button.concludeOrder")}}),created:function(){document.title="".concat(this.SET_PAGE_NAME," | ").concat(this.$t("page.checkoutInformation"))},beforeMount:function(){var t=c()(regeneratorRuntime.mark(function t(){return regeneratorRuntime.wrap(function(t){while(1)switch(t.prev=t.next){case 0:this.itemsInCart||this.customerCode||this.$router.replace({name:d["d"]});case 1:case"end":return t.stop()}},t,this)}));return function(){return t.apply(this,arguments)}}(),mounted:function(){this.$tracker.pageView({page:this.$route.path,title:this.$t("page.checkoutInformation")})},methods:l()({},Object(m["b"])("customFields",["answerQuestions","saveCustomFields","getUploadUrl"]),{validateForm:function(){var t=new i.a;return this.$refs.dynamicForm.forEach(function(e){t.add(e.validateForm())}),t.has(!1)},advance:function(){var t=c()(regeneratorRuntime.mark(function t(){return regeneratorRuntime.wrap(function(t){while(1)switch(t.prev=t.next){case 0:if(this.validateForm()){t.next=2;break}return t.abrupt("return",this.scrollToError());case 2:return t.prev=2,t.next=5,this.saveCustomFields({orderCode:this.cartOrderCode});case 5:if(!this.SET_CONFIG.checkout.seatName.active){t.next=7;break}return t.abrupt("return",this.$router.replace({name:d["w"]}));case 7:if(!this.hasDeliveryMethod){t.next=9;break}return t.abrupt("return",this.$router.replace({name:d["i"]}));case 9:return t.abrupt("return",this.$router.replace({name:d["n"]}));case 12:return t.prev=12,t.t0=t["catch"](2),t.next=16,this.dialogServerError(t.t0);case 16:return t.abrupt("return",t.t0);case 17:case"end":return t.stop()}},t,this,[[2,12]])}));return function(){return t.apply(this,arguments)}}()})},f=p,v=(r("782e"),r("2877")),b=Object(v["a"])(f,a,s,!1,null,null,null);b.options.__file="customFields.vue";e["default"]=b.exports}}]);
//# sourceMappingURL=c29f82f4.f10f2088.2024-10-22T18:36:13.257Z.js.map