(window.webpackJsonpNewland_Toubiz_Poi_Neos=window.webpackJsonpNewland_Toubiz_Poi_Neos||[]).push([[199],{bhy5:function(t,e,i){"use strict";i.r(e);var n=function(){var t=this.$createElement,e=this._self._c||t;return null===this.event?e("tb-w-loader"):e("div",[e("tb-w-event-detail",{attrs:{event:this.event,host:this.host,location:this.location}})],1)};n._withStripped=!0;var o=i("Tm+q");const s=["media","price","contactInformation","fieldBlueprints","fieldValues","dates","client","files","seo"];var a={components:{TbWEventDetail:o.default},props:{id:{type:String,required:!0},globalConfiguration:{type:Object,required:!0}},data:()=>({event:null,location:null,host:null}),watch:{id:{immediate:!0,handler(t){this.fetchEvent(t)}}},methods:{async fetchEvent(t=this.id){this.event=null,this.location=null,this.host=null;const e=await this.eventRepository.fetch(t,{include:s});if(this.event=e.payload,this.event.fieldValues instanceof Array&&0===this.event.fieldValues.length&&(this.event.fieldValues={}),this.event.location){const t=await this.articleRepository.fetch(this.event.location.id,{include:["media","relatedArticles","openingTimes"]});this.location=t.payload,await this.articleRepository.enrichListWithIncludes(this.location.relatedArticles.connectedPoints,["openingTimes"])}if(this.event.host){const t=await this.articleRepository.fetch(this.event.host,{include:["phoneNumbers","emails","contactInformation","openingTimes"]});this.host={},this.host.id=t.payload.id,this.host.name=t.payload.name,this.host.primaryCategory=t.payload.primaryCategory,this.host.website=t.payload.contactInformation.website,this.host.emails=t.payload.emails,this.host.phoneNumbers=t.payload.phoneNumbers,this.host.openingTimes=t.payload.openingTimes}}}},l=i("KHd+"),h=Object(l.a)(a,n,[],!1,null,null,null);h.options.__file="node_modules/@newland/toubiz-widget/src/routes/event-detail.vue";e.default=h.exports}}]);