webpackJsonp([11],{325:function(e,t){e.exports=function(e,t,o,n,i,a){var s,r=e=e||{},l=typeof e.default;"object"!==l&&"function"!==l||(s=e,r=e.default);var c,d="function"==typeof r?r.options:r;if(t&&(d.render=t.render,d.staticRenderFns=t.staticRenderFns,d._compiled=!0),o&&(d.functional=!0),i&&(d._scopeId=i),a?(c=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),n&&n.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},d._ssrRegister=c):n&&(c=n),c){var m=d.functional,u=m?d.render:d.beforeCreate;m?(d._injectStyles=c,d.render=function(e,t){return c.call(t),u(e,t)}):d.beforeCreate=u?[].concat(u,c):[c]}return{esModule:s,exports:r,options:d}}},665:function(e,t,o){var n=o(325)(o(937),o(938),!1,null,null,null);e.exports=n.exports},674:function(e,t,o){"use strict";var n=o(1),i=o.n(n),a=o(687),s=o.n(a);t.a={data:function(){return{formatPHPtoMomentMap:{d:"DD",D:"ddd",j:"D",l:"dddd",N:"E",w:"d",W:"W",F:"MMMM",m:"MM",M:"MMM",n:"M",o:"GGGG",Y:"YYYY",y:"YY",a:"a",A:"A",g:"h",G:"H",h:"hh",H:"HH",i:"mm",s:"ss",O:"ZZ",P:"Z",c:"YYYY-MM-DD[T]HH:mm:ssZ",r:"ddd, DD MMM YYYY HH:mm:ss ZZ",U:"X",S:"o"},formatPHPtoDatePickerMap:{d:"dd",j:"d",M:"MMM",F:"MMMM",m:"MM",n:"M",y:"yy",Y:"yyyy",g:"HH",H:"HH",i:"mm",a:"A",A:"A",s:"ss"},formatEx:/[dDjlNwWFmMntoYyaAgGhHisOPcrUS]/g}},methods:{getNowDate:function(){return i()().toDate()},getDate:function(e){return i()(e,"YYYY-MM-DD").toDate()},getDatabaseFormattedDate:function(e){return i()(e,"YYYY-MM-DD").format("YYYY-MM-DD")},getFrontedFormattedDate:function(e){return i()(e,"YYYY-MM-DD").format(this.momentDateFormat)},getEventFrontedFormattedDate:function(e){return i()(e,"YYYY-MM-DD").format("MMM DD")},getDateString:function(e){return i()(e).format("YYYY-MM-DD")},getTimeString:function(e){return i()(e).format("HH:mm")},getFrontedFormattedDateTime:function(e){return i()(e,"YYYY-MM-DD HH:mm:ss").format(this.momentDateFormat+" "+this.momentTimeFormat)},getFrontedFormattedTime:function(e){return i()(e,"HH:mm:ss").format(this.momentTimeFormat)},getFrontedFormattedTimeFromDateTimeString:function(e){return i()(e,"YYYY-MM-DD HH:mm:ss").format(this.momentTimeFormat)},getDatePickerFirstDayOfWeek:function(){return this.$root.settings.wordpress.startOfWeek+1},getWordPressFirstDayOfWeek:function(){return this.$root.settings.wordpress.startOfWeek},getTimeSlotLength:function(){return this.$root.settings.general.timeSlotLength},getDatePickerInitRange:function(){var e=s.a.get("ameliaRangePast"),t=s.a.get("ameliaRangeFuture");return null!==e&&null!==t?{start:i()().subtract(e,"days").toDate(),end:i()().add(t,"days").toDate()}:{start:i()().toDate(),end:i()().add(6,"days").toDate()}},setDatePickerSelectedDaysCount:function(e,t){var o=i()().format("YYYY-MM-DD");s.a.set("ameliaRangePast",i()(o,"YYYY-MM-DD").diff(i()(e,"YYYY-MM-DD"),"days")),s.a.set("ameliaRangeFuture",i()(t,"YYYY-MM-DD").diff(i()(o,"YYYY-MM-DD"),"days"))},getDatePickerNegativeInitRange:function(){return{start:i()().subtract(6,"days").toDate(),end:i()().toDate()}},getFrontedFormattedTimeIncreased:function(e,t){return i()(e,"HH:mm:ss").add(t,"seconds").format(this.momentTimeFormat)},getTime:function(e){return i()(e,"YYYY-MM-DD HH:mm:ss").format("HH:mm:ss")},getClientUtcOffset:function(e){return e?i()(e,"YYYY-MM-DD HH:mm:ss").utcOffset():i()().utcOffset()},getMinutesToDays:function(e){var t=Math.floor(e/1440),o=Math.floor((e-1440*t)/60),n=Math.round(e%60);return(t>0?t+"d ":"")+(o>0?o+"h ":"")+(n>0?n+"m ":"")}},computed:{momentTimeFormat:function(){var e=this;return"G \\h i \\m\\i\\n"===this.$root.settings.wordpress.timeFormat?"HH:mm":this.$root.settings.wordpress.timeFormat.replace(this.formatEx,function(t){return e.formatPHPtoMomentMap[t]})},momentDateFormat:function(){var e=this;return this.$root.settings.wordpress.dateFormat.replace(this.formatEx,function(t){return e.formatPHPtoMomentMap[t]})},vCalendarFormats:function(){return{input:[this.momentDateFormat,"YYYY-MM-DD","YYYY/MM/DD"]}},timePickerFormat:function(){return"HH:mm"}}}},675:function(e,t,o){"use strict";t.a={data:function(){return{colors:["1788FB","4BBEC6","FBC22D","FA3C52","D696B8","689BCA","26CC2B","FD7E35","E38587","774DFB","31CDF3","6AB76C","FD5FA1","A697C5"],usedColors:[]}},methods:{inlineSVG:function(){var e=o(685);e.init({svgSelector:"img.svg",initClass:"js-inlinesvg"})},imageFromText:function(e){var t=this.getNameInitials(e),o=Math.floor(Math.random()*this.colors.length),n=this.colors[o];return this.usedColors.push(this.colors[o]),this.colors.splice(o,1),0===this.colors.length&&(this.colors=this.usedColors,this.usedColors=[]),location.protocol+"//via.placeholder.com/120/"+n+"/fff?text="+t},pictureLoad:function(e,t){if(null!==e){var o=!0===t?e.firstName+" "+e.lastName:e.name;if(void 0!==o)return e.pictureThumbPath=e.pictureThumbPath||this.imageFromText(o),e.pictureThumbPath}},imageLoadError:function(e,t){var o=!0===t?e.firstName+" "+e.lastName:e.name;void 0!==o&&(e.pictureThumbPath=this.imageFromText(o))},getNameInitials:function(e){return e.split(" ").map(function(e){return e.charAt(0)}).join("").toUpperCase().substring(0,3).replace(/[^\w\s]/g,"")}}}},678:function(e,t,o){"use strict";t.a={data:function(){return{currencies:[{symbol:"$",name:"US Dollar",symbol_native:"$",code:"USD",iso:"us"},{symbol:"€",name:"Euro",symbol_native:"€",code:"EUR",iso:"eu"},{symbol:"£",name:"British Pound Sterling",symbol_native:"£",code:"GBP",iso:"gb"},{symbol:"CA$",name:"Canadian Dollar",symbol_native:"$",code:"CAD",iso:"ca"},{symbol:"CHF",name:"Swiss Franc",symbol_native:"CHF",code:"CHF",iso:"ch"},{symbol:"RUB",name:"Russian Ruble",symbol_native:"руб.",code:"RUB",iso:"ru"},{symbol:"¥",name:"Japanese Yen",symbol_native:"¥",code:"JPY",iso:"jp"},{symbol:"Af",name:"Afghan Afghani",symbol_native:"؋",code:"AFN",iso:"af"},{symbol:"ALL",name:"Albanian Lek",symbol_native:"Lek",code:"ALL",iso:"al"},{symbol:"DA",name:"Algerian Dinar",symbol_native:"د.ج.‏",code:"DZD",iso:"dz"},{symbol:"AR$",name:"Argentine Peso",symbol_native:"$",code:"ARS",iso:"ar"},{symbol:"AMD",name:"Armenian Dram",symbol_native:"դր.",code:"AMD",iso:"am"},{symbol:"AU$",name:"Australian Dollar",symbol_native:"$",code:"AUD",iso:"au"},{symbol:"man.",name:"Azerbaijani Manat",symbol_native:"ман.",code:"AZN",iso:"az"},{symbol:"BD",name:"Bahraini Dinar",symbol_native:"د.ب.‏",code:"BHD",iso:"bh"},{symbol:"Tk",name:"Bangladeshi Taka",symbol_native:"৳",code:"BDT",iso:"bd"},{symbol:"BYR",name:"Belarusian Ruble",symbol_native:"BYR",code:"BYR",iso:"by"},{symbol:"BZ$",name:"Belize Dollar",symbol_native:"$",code:"BZD",iso:"bz"},{symbol:"Bs",name:"Bolivian Boliviano",symbol_native:"Bs",code:"BOB",iso:"bo"},{symbol:"KM",name:"Bosnia-Herzegovina Convertible Mark",symbol_native:"KM",code:"BAM",iso:"ba"},{symbol:"BWP",name:"Botswanan Pula",symbol_native:"P",code:"BWP",iso:"bw"},{symbol:"R$",name:"Brazilian Real",symbol_native:"R$",code:"BRL",iso:"br"},{symbol:"BN$",name:"Brunei Dollar",symbol_native:"$",code:"BND",iso:"bn"},{symbol:"BGN",name:"Bulgarian Lev",symbol_native:"лв.",code:"BGN",iso:"bg"},{symbol:"FBu",name:"Burundian Franc",symbol_native:"FBu",code:"BIF",iso:"bi"},{symbol:"CFA",name:"CFA Franc BCEAO",symbol_native:"CFA",code:"XOF",iso:"auto"},{symbol:"FCFA",name:"CFA Franc BEAC",symbol_native:"FCFA",code:"XAF",iso:"auto"},{symbol:"KHR",name:"Cambodian Riel",symbol_native:"៛",code:"KHR",iso:"kh"},{symbol:"CV$",name:"Cape Verdean Escudo",symbol_native:"CV$",code:"CVE",iso:"cv"},{symbol:"CL$",name:"Chilean Peso",symbol_native:"$",code:"CLP",iso:"cl"},{symbol:"CN¥",name:"Chinese Yuan",symbol_native:"CN¥",code:"CNY",iso:"cn"},{symbol:"CO$",name:"Colombian Peso",symbol_native:"$",code:"COP",iso:"co"},{symbol:"CF",name:"Comorian Franc",symbol_native:"FC",code:"KMF",iso:"km"},{symbol:"CDF",name:"Congolese Franc",symbol_native:"FrCD",code:"CDF",iso:"cd"},{symbol:"₡",name:"Costa Rican Colón",symbol_native:"₡",code:"CRC",iso:"cr"},{symbol:"kn",name:"Croatian Kuna",symbol_native:"kn",code:"HRK",iso:"hr"},{symbol:"Kč",name:"Czech Republic Koruna",symbol_native:"Kč",code:"CZK",iso:"cz"},{symbol:"Dkr",name:"Danish Krone",symbol_native:"kr",code:"DKK",iso:"dk"},{symbol:"Fdj",name:"Djiboutian Franc",symbol_native:"Fdj",code:"DJF",iso:"dj"},{symbol:"RD$",name:"Dominican Peso",symbol_native:"RD$",code:"DOP",iso:"do"},{symbol:"EGP",name:"Egyptian Pound",symbol_native:"ج.م.‏",code:"EGP",iso:"eg"},{symbol:"Nfk",name:"Eritrean Nakfa",symbol_native:"Nfk",code:"ERN",iso:"er"},{symbol:"Ekr",name:"Estonian Kroon",symbol_native:"kr",code:"EEK",iso:"ee"},{symbol:"Br",name:"Ethiopian Birr",symbol_native:"Br",code:"ETB",iso:"et"},{symbol:"GEL",name:"Georgian Lari",symbol_native:"GEL",code:"GEL",iso:"ge"},{symbol:"GH₵",name:"Ghanaian Cedi",symbol_native:"GH₵",code:"GHS",iso:"gh"},{symbol:"GTQ",name:"Guatemalan Quetzal",symbol_native:"Q",code:"GTQ",iso:"gt"},{symbol:"FG",name:"Guinean Franc",symbol_native:"FG",code:"GNF",iso:"gn"},{symbol:"HNL",name:"Honduran Lempira",symbol_native:"L",code:"HNL",iso:"hn"},{symbol:"HK$",name:"Hong Kong Dollar",symbol_native:"$",code:"HKD",iso:"hk"},{symbol:"Ft",name:"Hungarian Forint",symbol_native:"Ft",code:"HUF",iso:"hu"},{symbol:"Ikr",name:"Icelandic Króna",symbol_native:"kr",code:"ISK",iso:"is"},{symbol:"Rs",name:"Indian Rupee",symbol_native:"টকা",code:"INR",iso:"in"},{symbol:"Rp",name:"Indonesian Rupiah",symbol_native:"Rp",code:"IDR",iso:"id"},{symbol:"IRR",name:"Iranian Rial",symbol_native:"﷼",code:"IRR",iso:"ir"},{symbol:"IQD",name:"Iraqi Dinar",symbol_native:"د.ع.‏",code:"IQD",iso:"iq"},{symbol:"₪",name:"Israeli New Sheqel",symbol_native:"₪",code:"ILS",iso:"il"},{symbol:"J$",name:"Jamaican Dollar",symbol_native:"$",code:"JMD",iso:"jm"},{symbol:"JD",name:"Jordanian Dinar",symbol_native:"د.أ.‏",code:"JOD",iso:"jo"},{symbol:"KZT",name:"Kazakhstani Tenge",symbol_native:"тңг.",code:"KZT",iso:"kz"},{symbol:"Ksh",name:"Kenyan Shilling",symbol_native:"Ksh",code:"KES",iso:"ke"},{symbol:"KD",name:"Kuwaiti Dinar",symbol_native:"د.ك.‏",code:"KWD",iso:"kw"},{symbol:"Ls",name:"Latvian Lats",symbol_native:"Ls",code:"LVL",iso:"lv"},{symbol:"LB£",name:"Lebanese Pound",symbol_native:"ل.ل.‏",code:"LBP",iso:"lb"},{symbol:"LD",name:"Libyan Dinar",symbol_native:"د.ل.‏",code:"LYD",iso:"ly"},{symbol:"Lt",name:"Lithuanian Litas",symbol_native:"Lt",code:"LTL",iso:"lt"},{symbol:"MOP$",name:"Macanese Pataca",symbol_native:"MOP$",code:"MOP",iso:"mo"},{symbol:"MKD",name:"Macedonian Denar",symbol_native:"MKD",code:"MKD",iso:"mk"},{symbol:"MGA",name:"Malagasy Ariary",symbol_native:"MGA",code:"MGA",iso:"mg"},{symbol:"RM",name:"Malaysian Ringgit",symbol_native:"RM",code:"MYR",iso:"my"},{symbol:"MURs",name:"Mauritian Rupee",symbol_native:"MURs",code:"MUR",iso:"mu"},{symbol:"MX$",name:"Mexican Peso",symbol_native:"$",code:"MXN",iso:"mx"},{symbol:"MDL",name:"Moldovan Leu",symbol_native:"MDL",code:"MDL",iso:"md"},{symbol:"MAD",name:"Moroccan Dirham",symbol_native:"د.م.‏",code:"MAD",iso:"ma"},{symbol:"MTn",name:"Mozambican Metical",symbol_native:"MTn",code:"MZN",iso:"mz"},{symbol:"MMK",name:"Myanma Kyat",symbol_native:"K",code:"MMK",iso:"mm"},{symbol:"N$",name:"Namibian Dollar",symbol_native:"N$",code:"NAD",iso:"na"},{symbol:"NPRs",name:"Nepalese Rupee",symbol_native:"नेरू",code:"NPR",iso:"np"},{symbol:"NT$",name:"New Taiwan Dollar",symbol_native:"NT$",code:"TWD",iso:"tw"},{symbol:"NZ$",name:"New Zealand Dollar",symbol_native:"$",code:"NZD",iso:"nz"},{symbol:"C$",name:"Nicaraguan Córdoba",symbol_native:"C$",code:"NIO",iso:"ni"},{symbol:"₦",name:"Nigerian Naira",symbol_native:"₦",code:"NGN",iso:"ng"},{symbol:"kr",name:"Norwegian Krone",symbol_native:"kr",code:"NOK",iso:"no"},{symbol:"OMR",name:"Omani Rial",symbol_native:"ر.ع.‏",code:"OMR",iso:"om"},{symbol:"PKRs",name:"Pakistani Rupee",symbol_native:"₨",code:"PKR",iso:"pk"},{symbol:"B/.",name:"Panamanian Balboa",symbol_native:"B/.",code:"PAB",iso:"pa"},{symbol:"₲",name:"Paraguayan Guarani",symbol_native:"₲",code:"PYG",iso:"py"},{symbol:"S/.",name:"Peruvian Nuevo Sol",symbol_native:"S/.",code:"PEN",iso:"pe"},{symbol:"₱",name:"Philippine Peso",symbol_native:"₱",code:"PHP",iso:"ph"},{symbol:"zł",name:"Polish Zloty",symbol_native:"zł",code:"PLN",iso:"pl"},{symbol:"QR",name:"Qatari Rial",symbol_native:"ر.ق.‏",code:"QAR",iso:"qa"},{symbol:"RON",name:"Romanian Leu",symbol_native:"RON",code:"RON",iso:"ro"},{symbol:"RWF",name:"Rwandan Franc",symbol_native:"FR",code:"RWF",iso:"rw"},{symbol:"SR",name:"Saudi Riyal",symbol_native:"ر.س.‏",code:"SAR",iso:"sa"},{symbol:"din.",name:"Serbian Dinar",symbol_native:"дин.",code:"RSD",iso:"rs"},{symbol:"S$",name:"Singapore Dollar",symbol_native:"$",code:"SGD",iso:"sg"},{symbol:"Ssh",name:"Somali Shilling",symbol_native:"Ssh",code:"SOS",iso:"so"},{symbol:"R",name:"South African Rand",symbol_native:"R",code:"ZAR",iso:"za"},{symbol:"₩",name:"South Korean Won",symbol_native:"₩",code:"KRW",iso:"kr"},{symbol:"SLRs",name:"Sri Lankan Rupee",symbol_native:"SL Re",code:"LKR",iso:"lk"},{symbol:"SDG",name:"Sudanese Pound",symbol_native:"SDG",code:"SDG",iso:"sd"},{symbol:"kr",name:"Swedish Krona",symbol_native:"kr",code:"SEK",iso:"se"},{symbol:"SY£",name:"Syrian Pound",symbol_native:"ل.س.‏",code:"SYP",iso:"sy"},{symbol:"TSh",name:"Tanzanian Shilling",symbol_native:"TSh",code:"TZS",iso:"tz"},{symbol:"฿",name:"Thai Baht",symbol_native:"฿",code:"THB",iso:"th"},{symbol:"T$",name:"Tongan Paʻanga",symbol_native:"T$",code:"TOP",iso:"to"},{symbol:"TT$",name:"Trinidad and Tobago Dollar",symbol_native:"$",code:"TTD",iso:"tt"},{symbol:"DT",name:"Tunisian Dinar",symbol_native:"د.ت.‏",code:"TND",iso:"tn"},{symbol:"TL",name:"Turkish Lira",symbol_native:"TL",code:"TRY",iso:"tr"},{symbol:"USh",name:"Ugandan Shilling",symbol_native:"USh",code:"UGX",iso:"ug"},{symbol:"₴",name:"Ukrainian Hryvnia",symbol_native:"₴",code:"UAH",iso:"ua"},{symbol:"AED",name:"United Arab Emirates Dirham",symbol_native:"د.إ.‏",code:"AED",iso:"ae"},{symbol:"$U",name:"Uruguayan Peso",symbol_native:"$",code:"UYU",iso:"uy"},{symbol:"UZS",name:"Uzbekistan Som",symbol_native:"UZS",code:"UZS",iso:"uz"},{symbol:"Bs.S.",name:"Venezuelan Bolívar",symbol_native:"Bs.S.",code:"VES",iso:"ve"},{symbol:"₫",name:"Vietnamese Dong",symbol_native:"₫",code:"VND",iso:"vn"},{symbol:"YR",name:"Yemeni Rial",symbol_native:"ر.ي.‏",code:"YER",iso:"ye"},{symbol:"ZK",name:"Zambian Kwacha",symbol_native:"ZK",code:"ZMK",iso:"zm"}],thousandSeparatorMap:{1:",",2:".",3:" ",4:" "},decimalSeparatorMap:{1:".",2:",",3:".",4:","}}},methods:{getCurrencySymbol:function(){var e=this;return this.currencies.find(function(t){return t.code===e.$root.settings.payments.currency}).symbol},getPriceThousandSeparator:function(){return this.thousandSeparatorMap[this.$root.settings.payments.priceSeparator]},getPriceDecimalSeparator:function(){return this.decimalSeparatorMap[this.$root.settings.payments.priceSeparator]},getPriceNumberOfDecimalPlaces:function(){return this.$root.settings.payments.priceNumberOfDecimals},getPricePrefix:function(){return"after"===this.$root.settings.payments.priceSymbolPosition||"afterWithSpace"===this.$root.settings.payments.priceSymbolPosition?"":"before"===this.$root.settings.payments.priceSymbolPosition?this.getCurrencySymbol():this.getCurrencySymbol()+" "},getPriceSuffix:function(){return"before"===this.$root.settings.payments.priceSymbolPosition||"beforeWithSpace"===this.$root.settings.payments.priceSymbolPosition?"":"after"===this.$root.settings.payments.priceSymbolPosition?this.getCurrencySymbol():" "+this.getCurrencySymbol()},getFormattedPrice:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],o=this.getPriceNumberOfDecimalPlaces(),n=this.getPriceThousandSeparator(),i=this.getPriceDecimalSeparator(),a=this.getPricePrefix(),s=this.getPriceSuffix(),r=parseInt(e=Math.abs(+e||0).toFixed(o))+"",l=r.length>3?r.length%3:0;return(t?a:"")+(l?r.substr(0,l)+n:"")+r.substr(l).replace(/(\d{3})(?=\d)/g,"$1"+n)+(o?i+Math.abs(e-r).toFixed(o).slice(2):"")+(t?s:"")}},computed:{moneyComponentData:function(){return{decimal:this.getPriceDecimalSeparator(),thousands:this.getPriceThousandSeparator(),prefix:this.getPricePrefix(),suffix:this.getPriceSuffix(),precision:this.getPriceNumberOfDecimalPlaces(),masked:!1}}}}},685:function(e,t,o){(function(o){var n,i,a,s;s=void 0!==o?o:this.window||this.global,i=[],n=function(e){var t,o={},n=!!document.querySelector&&!!e.addEventListener,i={initClass:"js-inlinesvg",svgSelector:"img.svg"},a=function(){var e={},t=!1,o=0,n=arguments.length;"[object Boolean]"===Object.prototype.toString.call(arguments[0])&&(t=arguments[0],o++);for(var i=function(o){for(var n in o)Object.prototype.hasOwnProperty.call(o,n)&&(t&&"[object Object]"===Object.prototype.toString.call(o[n])?e[n]=a(!0,e[n],o[n]):e[n]=o[n])};n>o;o++){i(arguments[o])}return e},s=function(e){var o=document.querySelectorAll(t.svgSelector),n=function(e,t){return function(){return--e<1?t.apply(this,arguments):void 0}}(o.length,e);Array.prototype.forEach.call(o,function(e,o){var i=e.src||e.getAttribute("data-src"),a=e.attributes,s=new XMLHttpRequest;s.open("GET",i,!0),s.onload=function(){if(s.status>=200&&s.status<400){var o=(new DOMParser).parseFromString(s.responseText,"text/xml").getElementsByTagName("svg")[0];if(o.removeAttribute("xmlns:a"),o.removeAttribute("width"),o.removeAttribute("height"),o.removeAttribute("x"),o.removeAttribute("y"),o.removeAttribute("enable-background"),o.removeAttribute("xmlns:xlink"),o.removeAttribute("xml:space"),o.removeAttribute("version"),Array.prototype.slice.call(a).forEach(function(e){"src"!==e.name&&"alt"!==e.name&&o.setAttribute(e.name,e.value)}),o.classList?o.classList.add("inlined-svg"):o.className+=" inlined-svg",o.setAttribute("role","img"),a.longdesc){var i=document.createElementNS("http://www.w3.org/2000/svg","desc"),r=document.createTextNode(a.longdesc.value);i.appendChild(r),o.insertBefore(i,o.firstChild)}if(a.alt){o.setAttribute("aria-labelledby","title");var l=document.createElementNS("http://www.w3.org/2000/svg","title"),c=document.createTextNode(a.alt.value);l.appendChild(c),o.insertBefore(l,o.firstChild)}e.parentNode.replaceChild(o,e),n(t.svgSelector)}else console.error("There was an error retrieving the source of the SVG.")},s.onerror=function(){console.error("There was an error connecting to the origin server.")},s.send()})};return o.init=function(e,o){n&&(t=a(i,e||{}),s(o||function(){}),document.documentElement.className+=" "+t.initClass)},o}(s),void 0===(a="function"==typeof n?n.apply(t,i):n)||(e.exports=a)}).call(t,o(39))},686:function(e,t,o){"use strict";t.a={data:function(){return{}},methods:{scrollView:function(e){jQuery(window).width()<=600&&document.getElementById(e).scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})},getUrlQueryParams:function(e){var t=[],o={};return(e.indexOf("#")?e.substring(0,e.indexOf("#")).split("?")[1]:e.split("?")[1]).split("&").forEach(function(e){t=e.split("="),o[t[0]]=decodeURIComponent(t[1]).replace(/\+/g," ")}),o},removeURLParameter:function(e,t){var o=e.split("?");if(o.length>=2){for(var n=encodeURIComponent(t)+"=",i=o[1].split(/[&;]/g),a=i.length;a-- >0;)-1!==i[a].lastIndexOf(n,0)&&i.splice(a,1);return e=o[0]+(i.length>0?"?"+i.join("&"):"")}return e},capitalizeFirstLetter:function(e){return e.charAt(0).toUpperCase()+e.slice(1)}}}},687:function(e,t,o){var n,i;n={expires:"1d",path:"; path=/"},i={install:function(e){e.prototype.$cookies=this,e.cookies=this},config:function(e,t){e&&(n.expires=e),t&&(n.path="; path="+t)},get:function(e){var t=decodeURIComponent(document.cookie.replace(new RegExp("(?:(?:^|.*;)\\s*"+encodeURIComponent(e).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=\\s*([^;]*).*$)|^.*$"),"$1"))||null;if(t&&"{"===t.substring(0,1)&&"}"===t.substring(t.length-1,t.length))try{t=JSON.parse(t)}catch(e){return t}return t},set:function(e,t,o,i,a,s){if(!e)throw new Error("cookie name is not find in first argument");if(/^(?:expires|max\-age|path|domain|secure)$/i.test(e))throw new Error("cookie key name illegality ,Cannot be set to ['expires','max-age','path','domain','secure']\t","current key name: "+e);t&&t.constructor===Object&&(t=JSON.stringify(t));var r="";if((o=void 0===o?n.expires:o)&&0!=o)switch(o.constructor){case Number:r=o===1/0||-1===o?"; expires=Fri, 31 Dec 9999 23:59:59 GMT":"; max-age="+o;break;case String:if(/^(?:\d{1,}(y|m|d|h|min|s))$/i.test(o)){var l=o.replace(/^(\d{1,})(?:y|m|d|h|min|s)$/i,"$1");switch(o.replace(/^(?:\d{1,})(y|m|d|h|min|s)$/i,"$1").toLowerCase()){case"m":r="; max-age="+2592e3*+l;break;case"d":r="; max-age="+86400*+l;break;case"h":r="; max-age="+3600*+l;break;case"min":r="; max-age="+60*+l;break;case"s":r="; max-age="+l;break;case"y":r="; max-age="+31104e3*+l;break;default:new Error("unknown exception of 'set operation'")}}else r="; expires="+o;break;case Date:r="; expires="+o.toUTCString()}return document.cookie=encodeURIComponent(e)+"="+encodeURIComponent(t)+r+(a?"; domain="+a:"")+(i?"; path="+i:n.path)+(s?"; secure":""),this},remove:function(e,t,o){return!(!e||!this.isKey(e))&&(document.cookie=encodeURIComponent(e)+"=; expires=Thu, 01 Jan 1970 00:00:00 GMT"+(o?"; domain="+o:"")+(t?"; path="+t:n.path),this)},isKey:function(e){return new RegExp("(?:^|;\\s*)"+encodeURIComponent(e).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=").test(document.cookie)},keys:function(){if(!document.cookie)return[];for(var e=document.cookie.replace(/((?:^|\s*;)[^\=]+)(?=;|$)|^\s*|\s*(?:\=[^;]*)?(?:\1|$)/g,"").split(/\s*(?:\=[^;]*)?;\s*/),t=0;t1&&void 0!==arguments[1]?arguments[1]:84600,o=[],n=this.getTimeSlotLength();n<=t;n+=this.getTimeSlotLength())o.push(n);return e&&-1===o.indexOf(e)&&(o.push(e),o.sort(function(e,t){return e-t})),o},getTimeSelectOptionsWithLimits:function(e,t){return{start:"00:00",end:"24:00",step:this.secondsToTimeSelectStep(this.getTimeSlotLength()),minTime:e,maxTime:t}},getStringTimeInSeconds:function(e){return i()(e,"HH:mm").diff(i()().startOf("day"),"seconds")}}}},693:function(e,t,o){"use strict";t.a={data:function(){return{}},methods:{setEntitiesFilter:function(){var e=this,t={categories:{services:[],employees:[],locations:[]},locations:{services:[],employees:[],categories:[]},services:{categories:[],employees:[],locations:[]},employees:{categories:[],services:[],locations:[]}};for(var o in t)this.options.entitiesChoices[o]={selection:"",dependents:t[o]};var n=function(e,t,o){e[t]||(e[t]=[]),-1===e[t].indexOf(o)&&e[t].push(o)};this.options.entities.employees.forEach(function(t){t.serviceList.forEach(function(o){e.options.entities.services.forEach(function(i){i.id===o.id&&(n(e.options.entitiesChoices.categories.dependents.employees,i.categoryId,t.id),n(e.options.entitiesChoices.categories.dependents.locations,i.categoryId,t.locationId),n(e.options.entitiesChoices.categories.dependents.services,i.categoryId,i.id),n(e.options.entitiesChoices.employees.dependents.categories,t.id,i.categoryId),n(e.options.entitiesChoices.services.dependents.categories,i.id,i.categoryId),n(e.options.entitiesChoices.locations.dependents.categories,t.locationId,i.categoryId))}),n(e.options.entitiesChoices.employees.dependents.services,t.id,o.id),n(e.options.entitiesChoices.services.dependents.employees,o.id,t.id),n(e.options.entitiesChoices.services.dependents.locations,o.id,t.locationId),n(e.options.entitiesChoices.locations.dependents.services,t.locationId,o.id)}),n(e.options.entitiesChoices.employees.dependents.locations,t.id,t.locationId),n(e.options.entitiesChoices.locations.dependents.employees,t.locationId,t.id)})},resetEntitiesFilter:function(){var e=this;["employees","services","locations","categories"].forEach(function(t){e.options.entities[t].forEach(function(e){e.disabled=!1})})},getLocationById:function(e){return this.options.entities.locations.find(function(t){return t.id===e})||null},getCustomerById:function(e){return this.options.entities.customers.find(function(t){return t.id===e})||null},getProviderById:function(e){return this.options.entities.employees.find(function(t){return t.id===e})||null},getServiceById:function(e){return this.options.entities.services.find(function(t){return t.id===e})||null},getServiceProviders:function(e){return this.options.entities.employees.filter(function(t){return-1!==t.serviceList.map(function(e){return e.id}).indexOf(e)})},getServicesFromCategories:function(){var e=[];return this.options.entities.categories.map(function(e){return e.serviceList}).forEach(function(t){e=e.concat(t)}),e},getCategoryServices:function(e){return this.options.entities.categories.find(function(t){return t.id===e}).serviceList},getCustomerInfo:function(e){return e.info?JSON.parse(e.info):this.getCustomerById(e.customerId)}},computed:{visibleLocations:function(){return this.options.entities.locations.filter(function(e){return"visible"===e.status})},visibleEmployees:function(){return this.options.entities.employees.filter(function(e){return"visible"===e.status})},visibleCustomers:function(){return this.options.entities.customers.filter(function(e){return"visible"===e.status})},visibleServices:function(){return this.options.entities.services.filter(function(e){return"visible"===e.status})}}}},714:function(e,t,o){var n=o(325)(o(718),o(719),!1,null,null,null);e.exports=n.exports},715:function(e,t,o){"use strict";t.a={data:function(){return{countries:[{id:1,iso:"af",nicename:"Afghanistan",phonecode:93,format:"070 123 4567"},{id:2,iso:"al",nicename:"Albania",phonecode:355,format:"066 123 4567"},{id:3,iso:"dz",nicename:"Algeria",phonecode:213,format:"0551 23 45 67"},{id:4,iso:"as",nicename:"American Samoa",phonecode:1,format:"(684) 733 1234"},{id:5,iso:"ad",nicename:"Andorra",phonecode:376,format:"312 345"},{id:6,iso:"ao",nicename:"Angola",phonecode:244,format:"923 123 456"},{id:7,iso:"ai",nicename:"Anguilla",phonecode:1,format:"(264) 235 1234"},{id:8,iso:"ag",nicename:"Antigua and Barbuda",phonecode:1,format:"(268) 464 1234"},{id:9,iso:"ar",nicename:"Argentina",phonecode:54,format:"9 (11) 1234 567"},{id:10,iso:"am",nicename:"Armenia",phonecode:374,format:"077 123 456"},{id:11,iso:"aw",nicename:"Aruba",phonecode:297,format:"560 1234"},{id:12,iso:"au",nicename:"Australia",phonecode:61,format:"0412 345 678"},{id:13,iso:"at",nicename:"Austria",phonecode:43,format:"0664 123456"},{id:14,iso:"az",nicename:"Azerbaijan",phonecode:994,format:"040 123 45 67"},{id:15,iso:"bs",nicename:"Bahamas",phonecode:1,format:"(242) 359 1234"},{id:16,iso:"bh",nicename:"Bahrain",phonecode:973,format:"3600 1234"},{id:17,iso:"bd",nicename:"Bangladesh",phonecode:880,format:"018 1234 5678"},{id:18,iso:"bb",nicename:"Barbados",phonecode:1,format:"(246) 250 1234"},{id:19,iso:"by",nicename:"Belarus",phonecode:375,format:"029 491 1911"},{id:20,iso:"be",nicename:"Belgium",phonecode:32,format:"0470 123 456"},{id:21,iso:"bz",nicename:"Belize",phonecode:501,format:"622 1234"},{id:22,iso:"bj",nicename:"Benin",phonecode:229,format:"90 123 456"},{id:23,iso:"bm",nicename:"Bermuda",phonecode:1,format:"(441) 370 1234"},{id:24,iso:"bt",nicename:"Bhutan",phonecode:975,format:"17 123 456"},{id:25,iso:"bo",nicename:"Bolivia",phonecode:591,format:"7 123 4567"},{id:26,iso:"ba",nicename:"Bosnia and Herzegovina",phonecode:387,format:"061 123 456"},{id:27,iso:"bw",nicename:"Botswana",phonecode:267,format:"71 123 456"},{id:28,iso:"br",nicename:"Brazil",phonecode:55,format:"(11) 9 1234 5678"},{id:29,iso:"vg",nicename:"British Virgin Islands",phonecode:1,format:"(284) 300 1234"},{id:30,iso:"bn",nicename:"Brunei",phonecode:673,format:"712 3456"},{id:31,iso:"bg",nicename:"Bulgaria",phonecode:359,format:"087 123 4567"},{id:32,iso:"bf",nicename:"Burkina Faso",phonecode:226,format:"70 12 34 56"},{id:33,iso:"bi",nicename:"Burundi",phonecode:257,format:"79 56 12 34"},{id:34,iso:"kh",nicename:"Cambodia",phonecode:855,format:"091 234 567"},{id:35,iso:"cm",nicename:"Cameroon",phonecode:237,format:"6 71 23 45 67"},{id:36,iso:"ca",nicename:"Canada",phonecode:1,format:"(204) 123 4567"},{id:37,iso:"cv",nicename:"Cape Verde",phonecode:238,format:"991 12 34"},{id:38,iso:"ky",nicename:"Cayman Islands",phonecode:1,format:"(345) 323 1234"},{id:39,iso:"cf",nicename:"Central African Republic",phonecode:236,format:"70 01 23 45"},{id:40,iso:"td",nicename:"Chad",phonecode:235,format:"63 01 23 45"},{id:41,iso:"cl",nicename:"Chile",phonecode:56,format:"09 6123 4567"},{id:42,iso:"cn",nicename:"China",phonecode:86,format:"131 2345 6789"},{id:43,iso:"co",nicename:"Colombia",phonecode:57,format:"321 1234567"},{id:44,iso:"km",nicename:"Comoros",phonecode:269,format:"321 23 45"},{id:45,iso:"cd",nicename:"Congo (DRC)",phonecode:243,format:"0991 234 567"},{id:46,iso:"cg",nicename:"Congo (Republic)",phonecode:242,format:"06 123 4567"},{id:47,iso:"ck",nicename:"Cook Islands",phonecode:682,format:"71 234"},{id:48,iso:"cr",nicename:"Costa Rica",phonecode:506,format:"8312 3456"},{id:49,iso:"ci",nicename:"Cote D'Ivoire",phonecode:225,format:"01 23 45 67"},{id:50,iso:"hr",nicename:"Croatia",phonecode:385,format:"091 234 5678"},{id:51,iso:"cu",nicename:"Cuba",phonecode:53,format:"05 1234567"},{id:57,iso:"cy",nicename:"Cyprus",phonecode:357,format:"96 123456"},{id:58,iso:"cz",nicename:"Czech Republic",phonecode:420,format:"601 123 456"},{id:59,iso:"dk",nicename:"Denmark",phonecode:45,format:"20 12 34 56"},{id:60,iso:"dj",nicename:"Djibouti",phonecode:253,format:"77 83 10 01"},{id:61,iso:"dm",nicename:"Dominica",phonecode:1,format:"(767) 225 1234"},{id:62,iso:"do",nicename:"Dominican Republic",phonecode:1,format:"(809) 234 5678"},{id:63,iso:"ec",nicename:"Ecuador",phonecode:593,format:"099 123 4567"},{id:64,iso:"eg",nicename:"Egypt",phonecode:20,format:"0100 123 4567"},{id:65,iso:"sv",nicename:"El Salvador",phonecode:503,format:"7012 3456"},{id:66,iso:"gq",nicename:"Equatorial Guinea",phonecode:240,format:"222 123 456"},{id:67,iso:"er",nicename:"Eritrea",phonecode:291,format:"07 123 456"},{id:68,iso:"ee",nicename:"Estonia",phonecode:372,format:"5123 4567"},{id:69,iso:"et",nicename:"Ethiopia",phonecode:251,format:"091 123 4567"},{id:70,iso:"fk",nicename:"Falkland Islands (Malvinas)",phonecode:500,format:"51234"},{id:71,iso:"fo",nicename:"Faroe Islands",phonecode:298,format:"211234"},{id:72,iso:"fj",nicename:"Fiji",phonecode:679,format:"701 2345"},{id:73,iso:"fi",nicename:"Finland",phonecode:358,format:"041 2345678"},{id:74,iso:"fr",nicename:"France",phonecode:33,format:"06 12 34 56 78"},{id:75,iso:"gf",nicename:"French Guiana",phonecode:594,format:"0694 20 12 34"},{id:76,iso:"pf",nicename:"French Polynesia",phonecode:689,format:"87 12 34 56"},{id:77,iso:"ga",nicename:"Gabon",phonecode:241,format:"06 03 12 34"},{id:78,iso:"gm",nicename:"Gambia",phonecode:220,format:"301 2345"},{id:79,iso:"ge",nicename:"Georgia",phonecode:995,format:"555 12 34 56"},{id:80,iso:"de",nicename:"Germany",phonecode:49,format:"01512 3456789"},{id:81,iso:"gh",nicename:"Ghana",phonecode:233,format:"023 123 4567"},{id:82,iso:"gi",nicename:"Gibraltar",phonecode:350,format:"57123456"},{id:83,iso:"gr",nicename:"Greece",phonecode:30,format:"691 234 5678"},{id:84,iso:"gl",nicename:"Greenland",phonecode:299,format:"22 12 34"},{id:87,iso:"gu",nicename:"Guam",phonecode:1,format:"(671) 300 1234"},{id:88,iso:"gt",nicename:"Guatemala",phonecode:502,format:"5123 4567"},{id:89,iso:"gg",nicename:"Guernsey",phonecode:44,format:"07781 123456"},{id:90,iso:"gn",nicename:"Guinea",phonecode:224,format:"601 12 34 56"},{id:91,iso:"gw",nicename:"Guinea-Bissau",phonecode:245,format:"955 012 345"},{id:92,iso:"gy",nicename:"Guyana",phonecode:592,format:"609 1234"},{id:93,iso:"ht",nicename:"Haiti",phonecode:509,format:"34 10 1234"},{id:94,iso:"hn",nicename:"Honduras",phonecode:504,format:"9123 4567"},{id:95,iso:"hk",nicename:"Hong Kong",phonecode:852,format:"5123 4567"},{id:96,iso:"hu",nicename:"Hungary",phonecode:36,format:"(20) 123 4567"},{id:97,iso:"is",nicename:"Iceland",phonecode:354,format:"611 1234"},{id:98,iso:"in",nicename:"India",phonecode:91,format:"099876 54321"},{id:99,iso:"id",nicename:"Indonesia",phonecode:62,format:"0812 345 678"},{id:100,iso:"ir",nicename:"Iran",phonecode:98,format:"0912 345 6789"},{id:101,iso:"iq",nicename:"Iraq",phonecode:964,format:"0791 234 5678"},{id:102,iso:"ie",nicename:"Ireland",phonecode:353,format:"085 012 3456"},{id:103,iso:"im",nicename:"Isle of Man",phonecode:44,format:"07924 123456"},{id:104,iso:"il",nicename:"Israel",phonecode:972,format:"050 123 4567"},{id:105,iso:"it",nicename:"Italy",phonecode:39,format:"312 345 6789"},{id:106,iso:"jm",nicename:"Jamaica",phonecode:1,format:"(876) 210 1234"},{id:107,iso:"jp",nicename:"Japan",phonecode:81,format:"090 1234 5678"},{id:108,iso:"je",nicename:"Jersey",phonecode:44,format:"07797 123456"},{id:109,iso:"jo",nicename:"Jordan",phonecode:962,format:"07 9012 3456"},{id:110,iso:"kz",nicename:"Kazakhstan",phonecode:7,format:"(771) 123 4567"},{id:111,iso:"ke",nicename:"Kenya",phonecode:254,format:"0712 123456"},{id:112,iso:"ki",nicename:"Kiribati",phonecode:686,format:"72012345"},{id:113,iso:"kw",nicename:"Kuwait",phonecode:965,format:"500 12345"},{id:114,iso:"kg",nicename:"Kyrgyzstan",phonecode:996,format:"0700 123 456"},{id:115,iso:"la",nicename:"Laos",phonecode:856,format:"020 23 123 456"},{id:116,iso:"lv",nicename:"Latvia",phonecode:371,format:"21 234 567"},{id:117,iso:"lb",nicename:"Lebanon",phonecode:961,format:"71 123 456"},{id:118,iso:"ls",nicename:"Lesotho",phonecode:266,format:"5012 3456"},{id:119,iso:"lr",nicename:"Liberia",phonecode:231,format:"077 012 3456"},{id:120,iso:"ly",nicename:"Libya",phonecode:218,format:"091 2345678"},{id:121,iso:"li",nicename:"Liechtenstein",phonecode:423,format:"660 234 567"},{id:122,iso:"lt",nicename:"Lithuania",phonecode:370,format:"612 345 67"},{id:123,iso:"lu",nicename:"Luxembourg",phonecode:352,format:"628 123 456"},{id:124,iso:"mo",nicename:"Macao",phonecode:853,format:"6612 3456"},{id:125,iso:"mk",nicename:"Macedonia (FYROM)",phonecode:389,format:"072 345 678"},{id:126,iso:"mg",nicename:"Madagascar",phonecode:261,format:"032 12 345 67"},{id:127,iso:"mw",nicename:"Malawi",phonecode:265,format:"0991 23 45 67"},{id:128,iso:"my",nicename:"Malaysia",phonecode:60,format:"012 345 6789"},{id:129,iso:"mv",nicename:"Maldives",phonecode:960,format:"771 2345"},{id:130,iso:"ml",nicename:"Mali",phonecode:223,format:"65 01 23 45"},{id:131,iso:"mt",nicename:"Malta",phonecode:356,format:"9696 1234"},{id:132,iso:"mh",nicename:"Marshall Islands",phonecode:692,format:"235 1234"},{id:133,iso:"mq",nicename:"Martinique",phonecode:596,format:"0696 20 12 34"},{id:134,iso:"mr",nicename:"Mauritania",phonecode:222,format:"22 12 34 56"},{id:135,iso:"mu",nicename:"Mauritius",phonecode:230,format:"5251 2345"},{id:136,iso:"yt",nicename:"Mayotte",phonecode:269,format:"0639 12 34 56"},{id:137,iso:"mx",nicename:"Mexico",phonecode:52,format:"044 222 123 4567"},{id:138,iso:"fm",nicename:"Micronesia",phonecode:691,format:"350 1234"},{id:139,iso:"md",nicename:"Moldova",phonecode:373,format:"0621 12 345"},{id:140,iso:"mc",nicename:"Monaco",phonecode:377,format:"06 12 34 56 78"},{id:141,iso:"mn",nicename:"Mongolia",phonecode:976,format:"8812 3456"},{id:142,iso:"me",nicename:"Montenegro",phonecode:382,format:"067 622 901"},{id:143,iso:"ms",nicename:"Montserrat",phonecode:1,format:"(664) 492 3456"},{id:144,iso:"ma",nicename:"Morocco",phonecode:212,format:"0650 123456"},{id:145,iso:"mz",nicename:"Mozambique",phonecode:258,format:"82 123 4567"},{id:146,iso:"mm",nicename:"Myanmar",phonecode:95,format:"09 212 3456"},{id:147,iso:"na",nicename:"Namibia",phonecode:264,format:"081 123 4567"},{id:149,iso:"np",nicename:"Nepal",phonecode:977,format:"984 1234567"},{id:150,iso:"nl",nicename:"Netherlands",phonecode:31,format:"06 12345678"},{id:151,iso:"nc",nicename:"New Caledonia",phonecode:687,format:"75 12 34"},{id:152,iso:"nz",nicename:"New Zealand",phonecode:64,format:"021 123 4567"},{id:153,iso:"ni",nicename:"Nicaragua",phonecode:505,format:"8123 4567"},{id:154,iso:"ne",nicename:"Niger",phonecode:227,format:"93 12 34 56"},{id:155,iso:"ng",nicename:"Nigeria",phonecode:234,format:"0802 123 4567"},{id:156,iso:"nu",nicename:"Niue",phonecode:683,format:"1234"},{id:157,iso:"nf",nicename:"Norfolk Island",phonecode:672,format:"3 81234"},{id:160,iso:"no",nicename:"Norway",phonecode:47,format:"406 12 345"},{id:161,iso:"om",nicename:"Oman",phonecode:968,format:"9212 3456"},{id:162,iso:"pk",nicename:"Pakistan",phonecode:92,format:"0301 2345678"},{id:163,iso:"pw",nicename:"Palau",phonecode:680,format:"620 1234"},{id:164,iso:"ps",nicename:"Palestine",phonecode:970,format:"0599 123 456"},{id:165,iso:"pa",nicename:"Panama",phonecode:507,format:"6001 2345"},{id:166,iso:"pg",nicename:"Papua New Guinea",phonecode:675,format:"681 2345"},{id:167,iso:"py",nicename:"Paraguay",phonecode:595,format:"0961 456789"},{id:168,iso:"pe",nicename:"Peru",phonecode:51,format:"912 345 678"},{id:169,iso:"ph",nicename:"Philippines",phonecode:63,format:"0905 123 4567"},{id:170,iso:"pl",nicename:"Poland",phonecode:48,format:"512 345 678"},{id:171,iso:"pt",nicename:"Portugal",phonecode:351,format:"912 345 678"},{id:172,iso:"pr",nicename:"Puerto Rico",phonecode:1,format:"(787) 234 5678"},{id:173,iso:"qa",nicename:"Qatar",phonecode:974,format:"3312 3456"},{id:175,iso:"ro",nicename:"Romania",phonecode:40,format:"0712 345 678"},{id:176,iso:"ru",nicename:"Russia",phonecode:7,format:"(912) 123 4567",priority:1},{id:177,iso:"rw",nicename:"Rwanda",phonecode:250,format:"0720 123 456"},{id:180,iso:"kn",nicename:"Saint Kitts and Nevis",phonecode:1,format:"(869) 765 2917"},{id:181,iso:"lc",nicename:"Saint Lucia",phonecode:1,format:"(758) 284 5678"},{id:184,iso:"vc",nicename:"Saint Vincent and the Grenadines",phonecode:1,format:"(784) 430 1234"},{id:185,iso:"ws",nicename:"Samoa",phonecode:684,format:"601234"},{id:186,iso:"sm",nicename:"San Marino",phonecode:378,format:"66 66 12 12"},{id:187,iso:"st",nicename:"Sao Tome and Principe",phonecode:239,format:"981 2345"},{id:188,iso:"sa",nicename:"Saudi Arabia",phonecode:966,format:"051 234 5678"},{id:189,iso:"sn",nicename:"Senegal",phonecode:221,format:"70 123 45 67"},{id:190,iso:"rs",nicename:"Serbia",phonecode:381,format:"060 1234567"},{id:191,iso:"sc",nicename:"Seychelles",phonecode:248,format:"2 510 123"},{id:192,iso:"sl",nicename:"Sierra Leone",phonecode:232,format:"(025) 123456"},{id:193,iso:"sg",nicename:"Singapore",phonecode:65,format:"8123 4567"},{id:195,iso:"sk",nicename:"Slovakia",phonecode:421,format:"0912 123 456"},{id:196,iso:"si",nicename:"Slovenia",phonecode:386,format:"031 234 567"},{id:197,iso:"sb",nicename:"Solomon Islands",phonecode:677,format:"74 21234"},{id:198,iso:"so",nicename:"Somalia",phonecode:252,format:"7 1123456"},{id:199,iso:"za",nicename:"South Africa",phonecode:27,format:"071 123 4567"},{id:200,iso:"kr",nicename:"South Korea",phonecode:82,format:"010 1234 567"},{id:201,iso:"ss",nicename:"South Sudan",phonecode:211,format:"0977 123 456"},{id:202,iso:"es",nicename:"Spain",phonecode:34,format:"612 34 56 78"},{id:203,iso:"lk",nicename:"Sri Lanka",phonecode:94,format:"071 234 5678"},{id:204,iso:"sd",nicename:"Sudan",phonecode:249,format:"091 123 1234"},{id:205,iso:"sr",nicename:"Suriname",phonecode:597,format:"741 2345"},{id:207,iso:"sz",nicename:"Swaziland",phonecode:268,format:"7612 3456"},{id:208,iso:"se",nicename:"Sweden",phonecode:46,format:"070 123 45 67"},{id:209,iso:"ch",nicename:"Switzerland",phonecode:41,format:"078 123 45 67"},{id:210,iso:"sy",nicename:"Syria",phonecode:963,format:"0944 567 890"},{id:211,iso:"tw",nicename:"Taiwan",phonecode:886,format:"0912 345 678"},{id:212,iso:"tj",nicename:"Tajikistan",phonecode:992,format:"917 123 456"},{id:214,iso:"th",nicename:"Thailand",phonecode:66,format:"081 234 5678"},{id:215,iso:"tl",nicename:"Timor-Leste",phonecode:670,format:"7721 2345"},{id:216,iso:"tg",nicename:"Togo",phonecode:228,format:"90 11 23 45"},{id:218,iso:"to",nicename:"Tonga",phonecode:676,format:"771 5123"},{id:219,iso:"tt",nicename:"Trinidad and Tobago",phonecode:1,format:"(868) 291 1234"},{id:220,iso:"tn",nicename:"Tunisia",phonecode:216,format:"20 123 456"},{id:221,iso:"tr",nicename:"Turkey",phonecode:90,format:"0501 234 56 78"},{id:222,iso:"tm",nicename:"Turkmenistan",phonecode:7370,format:"8 66 123456"},{id:223,iso:"tc",nicename:"Turks and Caicos Islands",phonecode:1,format:"(649) 231 1234"},{id:224,iso:"tv",nicename:"Tuvalu",phonecode:688,format:"901234"},{id:225,iso:"ug",nicename:"Uganda",phonecode:256,format:"0712 345678"},{id:226,iso:"ua",nicename:"Ukraine",phonecode:380,format:"039 123 4567"},{id:227,iso:"ae",nicename:"United Arab Emirates",phonecode:971,format:"050 123 4567"},{id:228,iso:"gb",nicename:"United Kingdom",phonecode:44,format:"07400 123456",priority:1},{id:229,iso:"us",nicename:"United States",phonecode:1,format:"(201) 555 0123",priority:1},{id:230,iso:"uy",nicename:"Uruguay",phonecode:598,format:"094 231 234"},{id:231,iso:"uz",nicename:"Uzbekistan",phonecode:998,format:"8 91 234 56 78"},{id:232,iso:"vu",nicename:"Vanuatu",phonecode:678,format:"591 2345"},{id:234,iso:"ve",nicename:"Venezuela",phonecode:58,format:"0412 1234567"},{id:235,iso:"vn",nicename:"Vietnam",phonecode:84,format:"091 234 56 78"},{id:236,iso:"vi",nicename:"Virgin Islands, U.S.",phonecode:1,format:"(340) 642 1234"},{id:237,iso:"ye",nicename:"Yemen",phonecode:967,format:"0712 345 678"},{id:238,iso:"zm",nicename:"Zambia",phonecode:260,format:"095 5123456"},{id:239,iso:"zw",nicename:"Zimbabwe",phonecode:263,format:"071 123 4567"},{id:240,iso:"ax",nicename:"Åland Islands",phonecode:358,format:"041 2345678"}]}}}},718:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(715);t.default={mixins:[n.a],template:"#phone-input",props:{savedPhone:{default:"",type:String},disabled:{default:!1,type:Boolean}},data:function(){return{input:"",phone:"",value:this.$root.settings.general.phoneDefaultCountryCode,format:""}},mounted:function(){""!==this.value?this.savedPhone?this.fillInputWithSavedPhone():this.formatPhoneNumber():this.savedPhone&&this.fillInputWithSavedPhone()},methods:{onClear:function(){this.value="",this.phone="",this.$emit("phoneFormatted",this.phone)},changeCountry:function(){""!==this.value&&""!==this.input&&(this.input=""),this.formatPhoneNumber()},formatPhoneNumber:function(){var e=this;if(""!==this.value){var t=this.countries.find(function(t){return t.iso===e.value});this.format=!0===this.disabled?"":t.format}if(""!==this.input){if(this.input.startsWith("+")){var o=parseInt(this.input.slice(1)),n=this.countries.filter(function(e){return e.phonecode===o});if(n.length){var i=null;1===o?i=n.find(function(e){return 229===e.id}):44===o?i=n.find(function(e){return 228===e.id}):7===o&&(i=n.find(function(e){return 176===e.id})),void 0!==i&&null!==i||(i=n[0]),this.value=i.iso}this.phone=this.input}else this.phone=void 0!==t?!0===this.input.startsWith("0")?"+"+t.phonecode+this.input.slice(1).replace(/\D/g,""):"+"+t.phonecode+this.input.replace(/\D/g,""):this.input;this.$emit("phoneFormatted",this.phone)}else this.phone=this.input,this.$emit("phoneFormatted",this.phone)},fillInputWithSavedPhone:function(){for(var e=this,t=null,o=1;null===t&&o<5;)t=void 0!==(t=this.countries.find(function(t){return t.phonecode===parseInt(e.savedPhone.substr(1,o))&&1===t.priority}))?t:null,o++;if(!t)for(o=1;null===t&&o<5;)t=void 0!==(t=this.countries.find(function(t){return t.phonecode===parseInt(e.savedPhone.substr(1,o))}))?t:null,o++;null!==t&&(this.value=t.iso,this.input=this.savedPhone.replace("+"+t.phonecode,""),this.input=t.format.startsWith("0")?"0"+this.input:this.input)}},watch:{input:function(){this.formatPhoneNumber()}},components:{}}},719:function(e,t){e.exports={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("el-input",{attrs:{placeholder:e.format,disabled:e.disabled,clearable:""},on:{clear:e.onClear},model:{value:e.input,callback:function(t){e.input=t},expression:"input"}},[o("el-select",{class:"am-selected-flag am-selected-flag-"+e.value,attrs:{slot:"prepend",placeholder:"",disabled:e.disabled},on:{change:e.changeCountry},slot:"prepend",model:{value:e.value,callback:function(t){e.value=t},expression:"value"}},e._l(e.countries,function(t){return o("el-option",{key:t.id,attrs:{value:t.iso,label:" "}},[o("span",{class:"am-flag am-flag-"+t.iso}),e._v(" "),o("span",{staticClass:"am-phone-input-nicename"},[e._v(e._s(t.nicename))]),e._v(" "),o("span",{staticClass:"am-phone-input-phonecode"},[e._v("+"+e._s(t.phonecode))])])}),1)],1)},staticRenderFns:[]}},720:function(e,t,o){"use strict";t.a={data:function(){return{}},methods:{isCustomFieldVisible:function(e){return-1!==e.services.map(function(e){return e.id}).indexOf(this.appointment.serviceId)},setBookingCustomFields:function(){if(this.appointment.bookings.length)for(var e=0;e1?e+" "+this.$root.labels.persons+" x "+t+" = "+n:n},getExtrasPrice:function(){return 0},getSubtotalPrice:function(){return this.appointment.bookings[0].persons*this.bookable.price+this.getExtrasPrice()},getDiscountPrice:function(){return 0},getTotalPrice:function(){var e=this.getSubtotalPrice()-this.getDiscountPrice();return e>0?e:0},getSelectedExtraDetails:function(){},getSelectedExtraPrice:function(){},checkCoupon:function(){},getBookingData:function(){var e=this;this.appointment.payment.amount=this.getFormattedAmount();var t=JSON.parse(JSON.stringify(this.appointment.bookings));t[0].extras=JSON.parse(JSON.stringify(this.selectedExtras)),t[0].extras.forEach(function(e){e.extraId=e.id,e.id=null});var o={},n=function(n){var i=e.customFields.find(function(e){return e.id==n});e.isCustomFieldVisible(i)&&(o[n]=t[0].customFields[n])};for(var a in t[0].customFields)n(a);t[0].customFields=JSON.stringify(o);var s=this.appointment.bookingStart;t[0].utcOffset=null,this.$root.settings.general.showClientTimeZone&&(s=i()(s,"YYYY-MM-DD HH:mm").utc().format("YYYY-MM-DD HH:mm"),t[0].utcOffset=this.getClientUtcOffset(s));var r={type:this.bookableType,bookings:t,payment:this.appointment.payment,couponCode:this.coupon.code};switch(this.bookableType){case"appointment":return Object.assign(r,{bookingStart:s,notifyParticipants:this.appointment.notifyParticipants?1:0,providerId:this.appointment.providerId,serviceId:this.bookable.id});case"event":return Object.assign(r,{eventId:this.bookable.id})}},getFormattedAmount:function(){return this.getTotalPrice().toFixed(2).toString()},handleSaveBookingErrors:function(e){if("data"in e)if("customerAlreadyBooked"in e.data&&!0===e.data.customerAlreadyBooked&&(this.headerErrorShow=!0,this.headerErrorMessage=this.$root.labels.customer_already_booked),"timeSlotUnavailable"in e.data&&!0===e.data.timeSlotUnavailable)switch(this.headerErrorShow=!0,this.bookableType){case"appointment":this.headerErrorMessage=this.$root.labels.time_slot_unavailable;break;case"event":this.headerErrorMessage=this.$root.labels.maximum_capacity_reached}else"emailError"in e.data&&!0===e.data.emailError?this.errors.email=this.$root.labels.email_exist_error:"couponUnknown"in e.data&&!0===e.data.couponUnknown?this.errors.coupon=this.$root.labels.coupon_unknown:"couponInvalid"in e.data&&!0===e.data.couponInvalid?this.errors.coupon=this.$root.labels.coupon_invalid:"couponMissing"in e.data&&!0===e.data.couponMissing?this.errors.coupon=this.$root.labels.coupon_missing:"paymentSuccessful"in e.data&&!1===e.data.paymentSuccessful?(this.headerErrorShow=!0,this.headerErrorMessage=this.$root.labels.payment_error):"bookingAlreadyInWcCart"in e.data&&!0===e.data.bookingAlreadyInWcCart?(this.headerErrorShow=!0,this.headerErrorMessage=this.$root.labels.booking_already_in_wc_cart):"wcError"in e.data&&!0===e.data.wcError&&(this.headerErrorShow=!0,this.headerErrorMessage=this.$root.labels.wc_error);this.fetched=!0},validateFieldsForPayPal:function(){var e=this;if(null!==this.payPalActions&&"payPal"===this.appointment.payment.gateway){var t=!0,o=function(o){var n=e.customFields.find(function(e){return e.id==o});e.isCustomFieldVisible(n)&&n.required&&(Array.isArray(e.appointment.bookings[0].customFields[o].value)&&0===e.appointment.bookings[0].customFields[o].value.length||!Array.isArray(e.appointment.bookings[0].customFields[o].value)&&""===e.appointment.bookings[0].customFields[o].value.trim())&&(t=!1)};for(var n in this.appointment.bookings[0].customFields)o(n);""===this.appointment.bookings[0].customer.lastName||""===this.appointment.bookings[0].customer.firstName||""===this.appointment.bookings[0].customer.email||!/(.+)@(.+){2,}\.(.+){2,}/.test(this.appointment.bookings[0].customer.email)||this.$root.settings.general.requiredPhoneNumberField&&!this.appointment.bookings[0].customer.id&&""===this.appointment.bookings[0].customer.phone||!t?this.payPalActions.disable():this.payPalActions.enable()}},payPalInit:function(){},parseError:function(e){var t=e.toString(),o=JSON.parse(JSON.stringify(JSON.parse(t.substring(t.indexOf("{"),t.lastIndexOf("}")+1))));"object"===(void 0===o?"undefined":p(o))&&o.hasOwnProperty("data")?this.handleSaveBookingErrors(o):(this.headerErrorShow=!0,this.headerErrorMessage=this.$root.labels.payment_error),this.fetched=!0,this.inlineSVG()},getStripePublishableKey:function(){},setStripeOutcome:function(){},clearValidation:function(){this.validateFieldsForPayPal(),void 0!==this.$refs.booking&&this.$refs.booking.clearValidate(),void 0!==this.$refs.coupon&&this.$refs.coupon.clearValidate()},phoneFormatted:function(e){this.appointment.bookings[0].customer.phone=e,this.clearValidation()},handleResize:function(){document.getElementById("amelia-app-booking"+this.$root.shortcodeData.counter).offsetWidth<670&&(this.columnsLg=24)},addCustomFieldsValidationRules:function(){}},computed:{bookableConfirmStyle:function(){return this.hoverConfirm?{color:this.bookable.color,borderColor:this.bookable.color,backgroundColor:this.bookable.color,opacity:.8}:{color:"#ffffff",backgroundColor:this.bookable.color,borderColor:this.bookable.color,opacity:1}},bookableCancelStyle:function(){return this.hoverCancel?{color:this.bookable.color,borderColor:this.bookable.color,backgroundColor:"",opacity:.7}:{color:"",backgroundColor:"#ffffff",borderColor:"",opacity:1}},bookableCancelSpanStyle:function(){return this.hoverCancel?{color:this.bookable.color,borderColor:"",backgroundColor:"",opacity:.9}:{color:"",backgroundColor:"",borderColor:"",opacity:1}},selectedExtras:function(){return[]},paymentOptions:function(){var e=[];return!0===this.$root.settings.payments.onSite&&e.push({value:"onSite",label:this.$root.labels.on_site}),this.$root.settings.payments.payPal.enabled&&e.push({value:"payPal",label:this.$root.labels.pay_pal}),this.$root.settings.payments.stripe.enabled&&e.push({value:"stripe",label:this.$root.labels.credit_card}),this.$root.settings.payments.wc.enabled&&e.push({value:"wc",label:this.$root.labels.wc}),e},showConfirmBookingButton:function(){return"onSite"===this.appointment.payment.gateway||"wc"===this.appointment.payment.gateway||"stripe"===this.appointment.payment.gateway||"payPal"===this.appointment.payment.gateway&&0===this.getTotalPrice()}},components:{moment:i.a,PhoneInput:r.a,Card:d.Card}}},783:function(e,t,o){var n;n=function(){return function(e){function t(n){if(o[n])return o[n].exports;var i=o[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var o={};return t.m=e,t.c=o,t.i=function(e){return e},t.d=function(e,o,n){t.o(e,o)||Object.defineProperty(e,o,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var o=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(o,"a",o),o},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=16)}([function(e,t,o){var n=o(2)(o(15),o(18),null,null);n.options.__file="/Users/fromatob/Projects/vue-stripe-elements/src/StripeElement.vue",n.esModule&&Object.keys(n.esModule).some(function(e){return"default"!==e&&"__esModule"!==e})&&console.error("named exports are not supported in *.vue files."),n.options.functional&&console.error("[vue-loader] StripeElement.vue: functional components are not supported with templates, they should use render functions."),e.exports=n.exports},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default={stripe:{type:[String,Object],required:!0},value:{type:String,required:!1},options:{type:Object,required:!1}}},function(e,t){e.exports=function(e,t,o,n){var i,a=e=e||{},s=typeof e.default;"object"!==s&&"function"!==s||(i=e,a=e.default);var r="function"==typeof a?a.options:a;if(t&&(r.render=t.render,r.staticRenderFns=t.staticRenderFns),o&&(r._scopeId=o),n){var l=r.computed||(r.computed={});Object.keys(n).forEach(function(e){var t=n[e];l[e]=function(){return t}})}return{esModule:i,exports:a,options:r}}},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.create=function(e,t){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};"object"===(void 0===e?"undefined":n(e))&&"function"==typeof e.elements&&(i.instance=e),void 0===window.Stripe&&null===i.instance?console.error("Stripe V3 library not loaded!"):null===i.instance&&(i.instance=window.Stripe(e)),i.instance.elements?null===i.elements&&(i.elements=i.instance.elements(t)):console.error("Stripe V3 library not loaded!")})(t,o.elements||{}),o.style=Object.assign(a,o.style||{});var s=i.elements.create(e,o);return i.createToken=function(e){return i.instance.createToken(s,e)},i.createSource=function(e){return i.instance.createSource(s,e)},i.retrieveSource=function(e){return i.instance.retrieveSource(e)},s},t.destroy=function(){i.instance=null,i.elements=null,i.createToken=null,i.createSource=null,i.retrieveSource=null};var i=t.Stripe={instance:null,createToken:null,createSource:null,retrieveSource:null,elements:null},a=t.baseStyle={base:{color:"#32325d",lineHeight:"24px",fontFamily:"Helvetica Neue",fontSmoothing:"antialiased",fontSize:"16px","::placeholder":{color:"#aab7c4"}},invalid:{color:"#fa755a",iconColor:"#fa755a"}}},function(e,t,o){"use strict";"function"!=typeof Object.assign&&(Object.assign=function(e,t){if(null==e)throw new TypeError("Cannot convert undefined or null to object");for(var o=Object(e),n=1;n1,expression:"paymentOptions.length > 1"}],attrs:{sm:e.columnsLg}},[o("transition",{attrs:{name:"fade"}},[e.getTotalPrice()>0&&!this.$root.settings.payments.wc.enabled?o("el-form-item",{attrs:{label:e.$root.labels.payment_method_colon}},[o("el-select",{attrs:{placeholder:"",disabled:1===e.paymentOptions.length},on:{change:function(t){return e.clearValidation()}},model:{value:e.appointment.payment.gateway,callback:function(t){e.$set(e.appointment.payment,"gateway",t)},expression:"appointment.payment.gateway"}},e._l(e.paymentOptions,function(e){return o("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})}),1)],1):e._e()],1)],1),e._v(" "),o("el-col",{attrs:{sm:e.columnsLg}},[o("transition",{attrs:{name:"fade"}},["stripe"===e.appointment.payment.gateway&&e.getTotalPrice()>0?o("el-form-item",{attrs:{label:e.$root.labels.credit_or_debit_card_colon,error:e.errors.stripe}},[o("card",{staticClass:"am-stripe-card",attrs:{stripe:e.getStripePublishableKey(),options:e.stripeOptions},on:{change:function(t){return e.setStripeOutcome(t)}}})],1):e._e()],1)],1)],1),e._v(" "),o("el-row",[o("el-col",{attrs:{sm:24}},[o("div",{staticClass:"am-confirmation-booking-cost"},[e.bookable.maxCapacity>1?o("el-row",{attrs:{gutter:24}},[o("el-col",{attrs:{span:12}},[o("p",[e._v(e._s(e.$root.labels.total_number_of_persons))])]),e._v(" "),o("el-col",{attrs:{span:12}},[o("p",{staticClass:"am-semi-strong am-align-right"},[e._v("\n "+e._s(e.appointment.bookings[0].persons)+"\n ")])])],1):e._e(),e._v(" "),e.bookable.price?o("el-row",{attrs:{gutter:24}},[o("el-col",{attrs:{span:8}},[o("p",[e._v(e._s(e.$root.labels.base_price_colon))])]),e._v(" "),o("el-col",{attrs:{span:16}},[o("p",{staticClass:"am-semi-strong am-align-right"},[e._v("\n "+e._s(e.getBookingPrice())+"\n ")])])],1):e._e(),e._v(" "),e.appointment.bookings[0].extras.length>0&&e.getTotalPrice()>0?o("el-row",{staticClass:"am-confirmation-extras-cost",attrs:{gutter:24}},[e.selectedExtras.length>0?o("el-collapse",{attrs:{accordion:""}},[o("el-collapse-item",{attrs:{name:"1"}},[o("template",{slot:"title"},[o("div",{staticClass:"am-extras-title"},[e._v(e._s(e.$root.labels.extras_costs_colon))]),e._v(" "),o("div",{staticClass:"am-extras-total-cost am-semi-strong",style:"event"===e.bookableType?e.getBookableColor:{}},[e._v(e._s(e.getFormattedPrice(e.getExtrasPrice())))])]),e._v(" "),e._l(e.selectedExtras,function(t){return o("div",[o("div",{staticClass:"am-extras-details"},[e._v(" "+e._s(e.getSelectedExtraDetails(t)))]),e._v(" "),o("div",{staticClass:"am-extras-cost"},[e._v(e._s(e.getSelectedExtraPrice(t)))])])})],2)],1):o("div",[o("el-col",{attrs:{span:12}},[o("p",[e._v(e._s(e.$root.labels.extras_costs_colon))])]),e._v(" "),o("el-col",{attrs:{span:12}},[o("p",{staticClass:"am-semi-strong am-align-right"},[e._v(e._s(e.getFormattedPrice(e.getExtrasPrice())))])])],1)],1):e._e(),e._v(" "),e.appointment.bookings[0].extras.length>0&&e.bookable.price?o("el-row",{attrs:{gutter:24}},[o("el-col",{attrs:{span:8}},[o("p",[e._v(e._s(e.$root.labels.subtotal_colon))])]),e._v(" "),o("el-col",{attrs:{span:16}},[o("p",{staticClass:"am-semi-strong am-align-right"},[e._v("\n "+e._s(e.getFormattedPrice(e.getSubtotalPrice()))+"\n ")])])],1):e._e(),e._v(" "),e.$root.settings.payments.coupons&&e.bookable.price>0&&"appointment"===e.bookableType?o("el-row",{attrs:{gutter:24}},[o("el-col",{attrs:{span:8}},[o("p",[e._v(e._s(e.$root.labels.discount_amount_colon))])]),e._v(" "),o("el-col",{attrs:{span:16}},[o("p",{staticClass:"am-semi-strong am-align-right"},[e._v("\n "+e._s(e.getFormattedPrice(e.getDiscountPrice()))+"\n ")])])],1):e._e(),e._v(" "),e.$root.settings.payments.coupons&&e.bookable.price>0&&"appointment"===e.bookableType?o("el-row",{staticClass:"am-add-coupon am-flex-row-middle-align",attrs:{gutter:0}},[o("el-col",{attrs:{sm:10,xs:10}},[o("img",{staticClass:"svg",attrs:{src:e.$root.getUrl+"public/img/coupon.svg",alt:"add-coupon"}}),e._v(" "),o("span",[e._v(e._s(e.$root.labels.add_coupon))])]),e._v(" "),o("el-col",{attrs:{sm:14,xs:14}},[o("el-form",{ref:"coupon",attrs:{model:e.appointment.bookings[0].customer,rules:e.rules,"label-position":"top","status-icon":""},on:{submit:function(t){return t.preventDefault(),e.onSubmit(t)}}},[o("el-form-item",{attrs:{prop:"couponCode",error:e.errors.coupon}},[o("el-input",{staticClass:"am-add-coupon-field",attrs:{type:"text",size:"small"},on:{input:function(t){return e.clearValidation()}},model:{value:e.coupon.code,callback:function(t){e.$set(e.coupon,"code",t)},expression:"coupon.code"}},[o("el-button",{attrs:{slot:"append",size:"mini",icon:"el-icon-check",disabled:""===e.coupon.code},on:{click:e.checkCoupon},slot:"append"})],1)],1)],1)],1)],1):e._e(),e._v(" "),e.bookable.price>0?o("el-row",{staticClass:"am-confirmation-total",style:{color:e.bookable.color,"background-color":"event"===e.bookableType?"#E8E8E8":""},attrs:{gutter:24}},[o("el-col",{attrs:{span:12}},[o("p",[e._v("\n "+e._s(e.$root.labels.total_cost_colon)+"\n ")])]),e._v(" "),o("el-col",{attrs:{span:12}},[o("p",{staticClass:"am-semi-strong am-align-right",style:{color:e.bookable.color}},[e._v("\n "+e._s(e.getFormattedPrice(e.getTotalPrice()))+"\n ")])])],1):e._e()],1)])],1)],1),e._v(" "),o("div",{staticClass:"dialog-footer payment-dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("div",{staticClass:"el-button el-button--default",style:e.bookableCancelStyle,on:{mouseover:function(t){return e.setBookableCancelStyle(!0)},mouseleave:function(t){return e.setBookableCancelStyle(!1)},click:function(t){return e.cancelBooking()}}},[o("span",{style:e.bookableCancelSpanStyle},[e._v(e._s(e.$root.labels.cancel))])]),e._v(" "),o("div",{directives:[{name:"show",rawName:"v-show",value:e.$root.settings.payments.payPal.enabled&&"payPal"===e.appointment.payment.gateway&&e.getTotalPrice()>0,expression:"$root.settings.payments.payPal.enabled && appointment.payment.gateway === 'payPal' && getTotalPrice() > 0"}],staticClass:"paypal-button el-button el-button--primary",style:e.bookableConfirmStyle,on:{mouseover:function(t){return e.setBookableConfirmStyle(!0)},mouseleave:function(t){return e.setBookableConfirmStyle(!1)}}},[o("div",{attrs:{id:"am-paypal-button-container"}}),e._v(" "),o("span",[e._v(e._s(e.$root.labels.confirm))])]),e._v(" "),o("div",{directives:[{name:"show",rawName:"v-show",value:e.showConfirmBookingButton,expression:"showConfirmBookingButton"}],staticClass:"el-button el-button--primary",style:e.bookableConfirmStyle,on:{mouseover:function(t){return e.setBookableConfirmStyle(!0)},mouseleave:function(t){return e.setBookableConfirmStyle(!1)},click:function(t){return e.confirmBooking()}}},[o("span",[e._v(e._s(e.$root.labels.confirm))])])])],1),e._v(" "),o("div",{directives:[{name:"show",rawName:"v-show",value:!e.fetched,expression:"!fetched"}],staticClass:"am-booking-fetched",attrs:{id:"am-spinner"}},["payPal"===e.appointment.payment.gateway?o("h4",[e._v(e._s(e.$root.labels.waiting_for_payment))]):o("h4",[e._v(e._s(e.$root.labels.please_wait))]),e._v(" "),o("div",{staticClass:"am-svg-wrapper"},["event"===e.bookableType?o("span",[o("svg",{staticClass:"am-spin",attrs:{width:"160",height:"160",viewBox:"0 0 38 38",xmlns:"http://www.w3.org/2000/svg",stroke:"#7F8FA4"}},[o("g",{attrs:{fill:"none","fill-rule":"evenodd"}},[o("g",{attrs:{transform:"translate(1 1)","stroke-width":"2"}},[o("path",{style:{stroke:e.bookable.color},attrs:{d:"M36 18c0-9.94-8.06-18-18-18",stroke:e.bookable.color}},[o("animateTransform",{attrs:{attributeName:"transform",type:"rotate",from:"0 18 18",to:"360 18 18",dur:"1s",repeatCount:"indefinite"}})],1)])])]),e._v(" "),o("svg",{staticClass:"am-hourglass",attrs:{width:"12px",height:"16px",viewBox:"0 0 12 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg"}},[o("g",{attrs:{id:"Icons",stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd",transform:"translate(-2.000000, 0.000000)"}},[o("g",{attrs:{id:"sat",transform:"translate(2.000000, 0.000000)",fill:"#303C42"}},[o("path",{style:{fill:e.bookable.color},attrs:{fill:e.bookable.color,d:"M8.37968,4.8 L3.32848,4.8 C3.22074667,4.8 3.12368,4.86506667 3.08208,4.9648 C3.04101333,5.06453333 3.06394667,5.1792 3.14021333,5.25546667 L5.67834667,7.79093333 C5.72794667,7.84106667 5.79621333,7.86933333 5.86661333,7.86933333 C5.95941333,7.8672 6.00634667,7.84106667 6.05594667,7.7904 L8.56901333,5.2544 C8.64474667,5.1776 8.66714667,5.06346667 8.62554667,4.96426667 C8.58448,4.86453333 8.48741333,4.8 8.37968,4.8",id:"Fill-694"}}),e._v(" "),o("path",{style:{fill:e.bookable.color},attrs:{fill:e.bookable.color,d:"M6.82293333,7.62293333 C6.6144,7.83146667 6.6144,8.16853333 6.82293333,8.37706667 L9.04,10.5941333 C9.74506667,11.2992 10.1333333,12.2368 10.1333333,13.2341333 L10.1333333,14.4 L9.2,14.4 L6.08,10.24 C5.9792,10.1056 5.75413333,10.1056 5.65333333,10.24 L2.53333333,14.4 L1.6,14.4 L1.6,13.2341333 C1.6,12.2368 1.98826667,11.2992 2.69333333,10.5941333 L4.9104,8.37706667 C5.11893333,8.16853333 5.11893333,7.83146667 4.9104,7.62293333 L2.69333333,5.40586667 C1.98826667,4.7008 1.6,3.7632 1.6,2.7664 L1.6,1.6 L10.1333333,1.6 L10.1333333,2.7664 C10.1333333,3.7632 9.74506667,4.7008 9.04,5.40586667 L6.82293333,7.62293333 Z M11.2,2.7664 L11.2,1.45173333 C11.5173333,1.26666667 11.7333333,0.9264 11.7333333,0.533333333 L11.7333333,0.266666667 C11.7333333,0.119466667 11.6138667,0 11.4666667,0 L0.266666667,0 C0.119466667,0 0,0.119466667 0,0.266666667 L0,0.533333333 C0,0.9264 0.216,1.26666667 0.533333333,1.45173333 L0.533333333,2.7664 C0.533333333,4.048 1.03253333,5.25386667 1.9392,6.16 L3.7792,8 L1.9392,9.84 C1.03253333,10.7461333 0.533333333,11.952 0.533333333,13.2341333 L0.533333333,14.5482667 C0.216,14.7333333 0,15.0736 0,15.4666667 L0,15.7333333 C0,15.8805333 0.119466667,16 0.266666667,16 L11.4666667,16 C11.6138667,16 11.7333333,15.8805333 11.7333333,15.7333333 L11.7333333,15.4666667 C11.7333333,15.0736 11.5173333,14.7333333 11.2,14.5482667 L11.2,13.2341333 C11.2,11.952 10.7008,10.7461333 9.79413333,9.84 L7.95413333,8 L9.79413333,6.16 C10.7008,5.25386667 11.2,4.048 11.2,2.7664 L11.2,2.7664 Z",id:"Fill-696"}})])])])]):o("span",[o("img",{staticClass:"svg am-spin",attrs:{src:e.$root.getUrl+"public/img/oval-spinner.svg"}}),e._v(" "),o("img",{staticClass:"svg am-hourglass",attrs:{src:e.$root.getUrl+"public/img/hourglass.svg"}})])])])])},staticRenderFns:[]}},785:function(e,t,o){var n=o(325)(o(786),o(787),!1,null,null,null);e.exports=n.exports},786:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(675),i=o(686);t.default={mixins:[n.a,i.a],props:{bookableType:null,addToCalendarData:null},data:function(){return{hoverConfirm:!1,calendarIndex:null,calendars:[],redirectUrlAfterAppointment:this.$root.settings.general.redirectUrlAfterAppointment}},mounted:function(){"beforeAddToCalendarLoaded"in window&&window.beforeAddToCalendarLoaded(this.addToCalendarData),this.addToCalendarData.active&&this.showCalendar(),this.inlineSVG(),this.scrollView("am-add-to-calendar")},methods:{formatTime:function(){},getCalendarLinkData:function(){},executeIfMultipleLinks:function(){},setBookableConfirmStyle:function(){},showCalendar:function(){},closeDialog:function(){this.$emit("closeDialogAddToCalendar")}},computed:{bookableConfirmStyle:function(){return this.hoverConfirm?{color:this.addToCalendarData.color,borderColor:this.addToCalendarData.color,backgroundColor:this.addToCalendarData.color,opacity:.8}:{color:"#ffffff",backgroundColor:this.addToCalendarData.color,borderColor:this.addToCalendarData.color,opacity:1}}}}},787:function(e,t){e.exports={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",[o("div",{staticClass:"am-success-payment",attrs:{id:"am-add-to-calendar"}},[o("h4",[e._v(e._s(e.$root.labels.congratulations)+"!")]),e._v(" "),"event"===e.addToCalendarData.type?o("div",{staticClass:"am-svg-wrapper"},[o("svg",{attrs:{width:"93px",height:"75px",viewBox:"0 0 93 75",version:"1.1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"}},[o("desc",[e._v("Created with Sketch.")]),e._v(" "),o("defs"),e._v(" "),o("g",{attrs:{stroke:"none","stroke-width":"1",fill:e.addToCalendarData.color,"fill-rule":"evenodd"}},[o("g",{attrs:{id:"trophy-2",fill:e.addToCalendarData.color}},[o("path",{attrs:{d:"M60.4208496,70.6040039 L60.4208496,57.4158691 L32.5792969,57.4158691 L32.5792969,70.6040039 L27.4505859,70.6040039 L27.4505859,75 L65.5495605,75 L65.5495605,70.6040039 L60.4208496,70.6040039 Z M54.5595703,67.673291 L38.4407227,67.673291 L38.4407227,63.2772949 L54.5595703,63.2772949 L54.5595703,67.673291 Z",id:"Shape",fill:e.addToCalendarData.color,"fill-rule":"nonzero",opacity:"0.70165308"}}),e._v(" "),o("path",{attrs:{d:"M72.8176758,6.71499023 C72.9522949,5.34711914 73.0227539,3.97749023 73.0227539,2.61196289 C55.5124512,-0.870703125 37.4876953,-0.870703125 19.9772461,2.61196289 C19.9772461,3.97734375 20.0477051,5.34697266 20.1823242,6.71499023 L9.08979492,6.71499023 L9.39433594,9.18237305 C10.3132324,16.6252441 12.7149902,23.8586426 16.5328125,30.6815918 C16.809082,31.1752441 17.0958984,31.6718262 17.385498,32.1575684 C19.3458984,35.4452637 22.9558594,37.4874023 26.8066406,37.4874023 L35.8078125,37.4874023 C37.7727539,39.2396484 39.8791992,40.7935547 42.1040039,42.1038574 L42.1040039,53.0200195 L50.8959961,53.0200195 L50.8959961,42.1038574 C53.1208008,40.7935547 55.2272461,39.2396484 57.1921875,37.4874023 L66.1933594,37.4874023 C70.0439941,37.4874023 73.6539551,35.4451172 75.614502,32.1578613 C75.9041016,31.6724121 76.190918,31.1758301 76.4671875,30.6818848 C80.2851563,23.8587891 82.6869141,16.6252441 83.6056641,9.18251953 L83.9103516,6.71513672 C83.9102051,6.71499023 72.8176758,6.71499023 72.8176758,6.71499023 Z M26.8069336,33.0912598 C24.4962891,33.0912598 22.3331543,31.8706055 21.1614258,29.905957 C20.8924805,29.4549316 20.6260254,28.9937988 20.3693848,28.5351562 C17.2555664,22.9702148 15.1592285,17.1203613 14.1224121,11.1111328 L20.840332,11.1111328 C22.4507813,19.143457 26.2381348,26.8858887 31.5210938,33.0912598 L26.8069336,33.0912598 Z M72.6310547,28.5353027 C72.3742676,28.9940918 72.1081055,29.4552246 71.8391602,29.905957 C70.6674316,31.870752 68.5041504,33.0912598 66.1936523,33.0912598 L61.4794922,33.0912598 C66.7624512,26.8858887 70.5498047,19.1433105 72.1602539,11.1111328 L78.8780273,11.1111328 C77.8412109,17.1202148 75.7450195,22.9700684 72.6310547,28.5353027 Z",id:"Shape",fill:e.addToCalendarData.color,"fill-rule":"nonzero",opacity:"0.70165308"}}),e._v(" "),o("path",{attrs:{d:"M48.8443002,15.7224529 C45.5005423,6.20144843 46.3007112,6.42871364 43.03539,15.7224529 C32.8222466,15.9270203 33.3325159,15.2730941 41.2359437,21.2032508 C38.2829325,30.8598674 37.785305,30.199333 45.9401324,24.5849342 C54.312169,30.3481616 53.5240673,30.6147888 50.6431719,21.2032508 C58.7816224,15.0978327 58.7603612,15.9209867 48.8443002,15.7224529 L48.8443002,15.7224529 Z",id:"Shape",fill:"#FFFFFF"}}),e._v(" "),o("path",{attrs:{d:"M10.4665585,45.9585064 C7.95874007,38.817753 8.55886675,38.9882019 6.10987581,45.9585064 C-1.54998175,46.1119319 -1.16727978,45.6214873 4.76029109,50.0691048 C2.54553272,57.3115672 2.1723121,56.8161664 8.28843264,52.6053673 C14.5674601,56.9277878 13.9763838,57.1277582 11.8157123,50.0691048 C17.9195501,45.4900412 17.9036042,46.1074067 10.4665585,45.9585064 L10.4665585,45.9585064 Z",id:"Shape",fill:e.addToCalendarData.color,opacity:"0.145471014"}}),e._v(" "),o("path",{attrs:{d:"M87.4665585,45.9585064 C84.9587401,38.817753 85.5588668,38.9882019 83.1098758,45.9585064 C75.4500183,46.1119319 75.8327202,45.6214873 81.7602911,50.0691048 C79.5455327,57.3115672 79.1723121,56.8161664 85.2884326,52.6053673 C91.5674601,56.9277878 90.9763838,57.1277582 88.8157123,50.0691048 C94.9195501,45.4900412 94.9036042,46.1074067 87.4665585,45.9585064 L87.4665585,45.9585064 Z",id:"Shape-Copy",fill:e.addToCalendarData.color,opacity:"0.145471014"}})])])])]):o("div",{staticClass:"am-svg-wrapper"},[o("img",{staticClass:"svg am-congrats",attrs:{src:e.$root.getUrl+"public/img/trophy.svg"}})]),e._v(" "),o("div",["approved"===e.addToCalendarData.status?o("p",[e._v(e._s(e.$root.labels.booking_completed_approved))]):e._e(),e._v(" "),"pending"===e.addToCalendarData.status?o("p",[e._v(e._s(e.$root.labels.booking_completed_pending))]):e._e()]),e._v(" "),o("br"),e._v(" "),e.addToCalendarData.active?o("el-row",{attrs:{type:"flex",justify:"center"}},[o("el-col",{attrs:{sm:12}},[o("el-select",{attrs:{placeholder:e.$root.labels.select_calendar},model:{value:e.calendarIndex,callback:function(t){e.calendarIndex=t},expression:"calendarIndex"}},e._l(e.calendars,function(e,t){return o("el-option",{key:t,attrs:{label:e.label,value:t}})}),1)],1)],1):e._e(),e._v(" "),o("br"),e._v(" "),e.addToCalendarData.active?o("div",{staticClass:"el-button el-button--primary calendar-link",class:{"is-disabled":null===e.calendarIndex},style:e.bookableConfirmStyle,on:{mouseover:function(t){return e.setBookableConfirmStyle(!0)},mouseleave:function(t){return e.setBookableConfirmStyle(!1)}}},[null!==e.calendarIndex?o("a",{attrs:{href:e.calendars[e.calendarIndex].links[0],target:"ios"===e.calendars[e.calendarIndex].type||"outlook"===e.calendars[e.calendarIndex].type?"_self":"_blank"},on:{click:e.executeIfMultipleLinks}},[e._v("\n "+e._s(e.$root.labels.add_to_calendar)+"\n ")]):o("span",[e._v("\n "+e._s(e.$root.labels.add_to_calendar)+"\n ")])]):e._e(),e._v(" "),o("div",{staticClass:"el-button el-button--primary redirect-link",style:e.bookableConfirmStyle,on:{mouseover:function(t){return e.setBookableConfirmStyle(!0)},mouseleave:function(t){return e.setBookableConfirmStyle(!1)}}},[""!==e.redirectUrlAfterAppointment?o("a",{attrs:{href:e.redirectUrlAfterAppointment,target:"_self"}},[e._v("\n "+e._s(e.$root.labels.finish_appointment)+"\n ")]):o("a",{on:{click:function(t){return e.closeDialog()}}},[e._v("\n "+e._s(e.$root.labels.finish_appointment)+"\n ")])])],1)])},staticRenderFns:[]}},788:function(e,t,o){"use strict";var n=o(1),i=o.n(n);t.a={data:function(){return{}},methods:{getAppointmentDuration:function(e,t){return e.duration+t.filter(function(e){return e.selected}).map(function(e){return e.duration*e.quantity}).reduce(function(e,t){return e+t},0)},getCurrentUser:function(){var e=this;this.$http.get(this.$root.getAjaxUrl+"/users/current").then(function(t){e.currentUser=t.data.data.user,e.currentUser&&(e.appointment.bookings[0].customerId=e.currentUser.id,e.appointment.bookings[0].customer.id=e.currentUser.id,e.appointment.bookings[0].customer.externalId=e.currentUser.externalId,e.appointment.bookings[0].customer.email=e.currentUser.email,e.appointment.bookings[0].customer.firstName=e.currentUser.firstName,e.appointment.bookings[0].customer.lastName=e.currentUser.lastName,e.appointment.bookings[0].customer.phone=e.currentUser.phone||"")}).catch(function(e){console.log("getCurrentUser fail")})},getFormattedTimeSlot:function(e,t){return this.getFrontedFormattedTime(e)+" - "+i()(e,"HH:mm:ss").add(t,"seconds").format(this.momentTimeFormat)},getConvertedTimeSlots:function(e){var t={};for(var o in e)for(var n in e[o]){var a=i.a.utc(o+" "+n,"YYYY-MM-DD HH:mm").local().format("YYYY-MM-DD HH:mm").split(" ");a[0]in t||(t[a[0]]={}),t[a[0]][a[1]]=e[o][n]}return t},handleCapacity:function(){var e=this,t=!1,o=0,n=0;if(e.appointment.serviceId)if(e.appointment.providerId){var i=this.options.entities.employees.find(function(t){return t.id===e.appointment.providerId}).serviceList.find(function(t){return t.id===e.appointment.serviceId});t=i.maxCapacity>1&&(i.bringingAnyone||!this.$root.settings.appointments.allowBookingIfNotMin),o=i.maxCapacity,n=this.$root.settings.appointments.allowBookingIfNotMin?1:i.minCapacity}else this.options.entities.employees.forEach(function(i){i.serviceList.forEach(function(i){i.id===e.appointment.serviceId&&(i.maxCapacity>1&&i.bringingAnyone&&(t=!0),i.maxCapacity>o&&(o=i.maxCapacity),no&&(this.appointment.bookings[0].persons=o),(this.group.enabled||t&&!this.$root.settings.appointments.allowBookingIfNotMin)&&(this.group.enabled=t),t&&!this.$root.settings.appointments.allowBookingIfNotMin&&(this.appointment.bookings[0].persons=n),this.group.allowed=t&&this.$root.settings.appointments.allowBookingIfNotMin}}}},937:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(1),i=o.n(n),a=o(722),s=o(675),r=o(674),l=o(693),c=o(714),d=o.n(c),m=o(781),u=o.n(m),p=o(785),h=o.n(p),f=o(788),b=o(686),v=o(688),g=o(678),y=o(720);t.default={mixins:[a.a,s.a,r.a,l.a,f.a,b.a,v.a,g.a,y.a],props:{id:{default:"am-step-booking"},showService:{default:!0,type:Boolean},passedService:{default:function(){},type:Object}},data:function(){return{selectedMonth:i()().format("YYYY-MM"),isServiceChanged:!0,calendarId:"",activeConfirm:!1,activePicker:!1,addToCalendarData:null,appointment:{bookingStart:"",bookingStartTime:"",bookings:[{customer:{email:"",externalId:null,firstName:"",id:null,lastName:"",phone:""},customFields:{},customerId:0,extras:[],persons:1,status:this.$root.settings.general.defaultAppointmentStatus}],duration:0,group:!1,notifyParticipants:this.$root.settings.notifications.notifyCustomers,payment:{amount:0,gateway:"",data:{}},providerId:0,serviceId:null,locationId:null},availableDates:[],availableTimeSlots:[],calendar:"",calendarTimeSlots:{},calendarVisible:!1,customer:{name:"",email:"",phone:"",paymentMethod:""},customerRules:{name:[{required:!0,message:"Please input name",trigger:"submit"},{min:3,max:50,message:"Length should be 3 to 50",trigger:"submit"}],email:[{required:!0,message:"Please input name",trigger:"submit"},{min:3,max:5,message:"Length should be 3 to 5",trigger:"submit"}],phone:"",paymentMethod:""},disabledAttribute:{contentStyle:{color:"#ccc",opacity:.4,textDecoration:"line-through"}},disabledWeekdays:null,fetched:!1,fetchedSlots:!1,group:{allowed:!1,enabled:!1,count:1,options:[]},loadingTimeSlots:!1,options:{entities:{services:[],employees:[],locations:[],customFields:[]}},rules:{serviceId:[{required:!0,message:this.$root.labels.please_select+" "+this.$root.labels.service,trigger:"blur",type:"number"}]},selectedExtras:[],selectedDate:null,showAddToCalendar:!1,showExtras:!1,showFilters:!1,showTimes:!1,showServices:!1,showEmployees:!1,showLocations:!1,showCalendarBackButton:!1,showCalendarContinueButton:!1,times:""}},created:function(){this.calendarId="am-appointment-times"+this.$root.shortcodeData.counter,window.addEventListener("resize",this.handleResize)},mounted:function(){if(this.$root.shortcodeData.hasBookingShortcode&&this.$root.shortcodeData.hasCategoryShortcode||this.inlineBookingSVG(),"beforeBookingLoaded"in window&&window.beforeBookingLoaded(),!0===this.showService){var e=["categories","employees"];this.getEntities(e)}else{this.options.entities.services=[this.passedService];var t=["employees"];this.getEntities(t),this.appointment.serviceId=this.options.entities.services[0].id}this.getCurrentUser(),this.times=document.getElementById(this.calendarId)},updated:function(){this.handleResize()},methods:{getBookableData:function(){var e=this,t=this.getProviderById(this.appointment.providerId).serviceList.find(function(t){return t.id===e.appointment.serviceId});return{id:t.id,name:t.name,price:t.price,maxCapacity:t.maxCapacity,pictureThumbPath:t.pictureThumbPath}},changeMonth:function(e){this.selectedMonth=e?i()().year(e.year).month(e.month-1).date(1).format("YYYY-MM"):null},showCalendarOnly:function(e){var t=this,o=[];return this.appointment.serviceId&&this.appointment.providerId&&(o=this.getProviderById(this.appointment.providerId).serviceList.filter(function(e){return e.id===t.appointment.serviceId})),e&&!this.showServices&&!this.showEmployees&&o.length&&(1===o[0].maxCapacity||o[0].maxCapacity>1&&!o[0].bringingAnyone&&this.$root.settings.appointments.allowBookingIfNotMin)&&0===this.getServiceById(this.appointment.serviceId).extras.length},getEntities:function(e){var t=this;this.$http.get(this.$root.getAjaxUrl+"/entities",{params:{page:"appointments",types:e}}).then(function(o){t.filterResponseData(o);var n=[],i=[];if(o.data.data.employees.forEach(function(e){e.serviceList.forEach(function(e){i.push(e.id)}),e.serviceList.length&&n.push(e)}),t.options.entities.employees=n,t.options.entities.customFields=o.data.data.customFields,t.setBookingCustomFields(),-1!==e.indexOf("categories")&&(t.options.entities.categories=o.data.data.categories,t.options.entities.services=t.getServicesFromCategories().filter(function(e){return-1!==i.indexOf(e.id)})),t.options.entities.locations=o.data.data.locations,!1===t.showService&&t.$emit("entitiesFetched",t.options.entities),t.$root.shortcodeData.booking&&t.servicesFiltered.length&&t.employeesFiltered.length){var a=null,s=null,r=null,l=null;t.$root.shortcodeData.booking&&(a=t.$root.shortcodeData.booking.category&&t.options.entities.categories?t.options.entities.categories.find(function(e){return e.id===t.$root.shortcodeData.booking.category}):null,s=t.$root.shortcodeData.booking.service?t.servicesFiltered.find(function(e){return e.id===t.$root.shortcodeData.booking.service}):null,r=t.$root.shortcodeData.booking.employee?t.employeesFiltered.find(function(e){return e.id===t.$root.shortcodeData.booking.employee}):null,l=t.$root.shortcodeData.booking.location?t.locationsFiltered.find(function(e){return e.id===t.$root.shortcodeData.booking.location}):null);var c=!0;s&&r&&(c=r.serviceList.find(function(e){return e.id===s.id})),s&&l&&(c=t.employeesFiltered.filter(function(e){return e.locationId===l.id&&e.serviceList.find(function(e){return e.id===s.id})})),a&&r&&(c=t.employeesFiltered.filter(function(e){return e.id===r.id&&e.serviceList.find(function(e){return e.categoryId===a.id})})),a&&l&&(c=t.employeesFiltered.filter(function(e){return e.locationId===l.id&&e.serviceList.find(function(e){return e.categoryId===a.id})})),c&&(a&&(t.options.entities.categories=[a],t.options.entities.employees.forEach(function(e){e.serviceList=e.serviceList.filter(function(e){return e.categoryId===a.id})})),s&&(t.options.entities.services=[s]),r&&(t.options.entities.employees=[r]),l&&(t.options.entities.locations=[l]))}if(1===t.servicesFiltered.length)t.appointment.serviceId=t.servicesFiltered[0].id;else{if(!(t.servicesFiltered.length>1))return;t.showServices=!0}1===t.employeesFiltered.length?t.appointment.providerId=t.employeesFiltered[0].id:t.employeesFiltered.length>1&&(t.showEmployees=!0),1===t.locationsFiltered.length?t.appointment.locationId=t.locationsFiltered[0].id:t.locationsFiltered.length>1&&(t.showLocations=!0),t.handleCapacity(),t.showCalendarOnly(!0)?(document.getElementById(t.id+"-calendar").classList.remove("am-select-service-date-transition"),t.getTimeSlots()):t.fetched=!0}).catch(function(e){console.log(e.message)})},changeService:function(){this.isServiceChanged=!0,this.clearValidation(),this.appointment.bookings[0].extras=[],this.handleCapacity(),this.calendarVisible&&this.getTimeSlots()},changeEmployee:function(){this.clearValidation(),this.handleCapacity(),this.calendarVisible&&this.getTimeSlots()},enableGrouping:function(){!0===this.group.enabled?this.appointment.bookings[0].persons+=1:this.appointment.bookings[0].persons=1,this.handleCapacity(),this.calendarVisible&&this.getTimeSlots()},changeNumberOfPersons:function(){this.calendarVisible&&this.getTimeSlots()},getSelectedExtraMaxQuantity:function(e){var t=this.getServiceById(this.appointment.serviceId).extras.find(function(t){return t.id===e.id});return void 0!==t?t.maxQuantity:""},getAvailableExtras:function(e){var t=[],o=[];return this.selectedExtras.forEach(function(e){e.id&&t.push(e.id)}),this.getServiceById(this.appointment.serviceId).extras.forEach(function(n){-1!==t.indexOf(n.id)&&e.id!==n.id||o.push(n)}),o},addExtra:function(){this.selectedExtras.push({id:null,extraId:null,quantity:"",duration:0,name:""})},deleteExtra:function(e){this.calendarVisible&&this.selectedExtras[e].duration?(this.selectedExtras.splice(e,1),this.getTimeSlots()):this.selectedExtras.splice(e,1)},changeSelectedExtra:function(e){e.quantity=""===e.quantity?1:e.quantity;var t=this.getServiceById(this.appointment.serviceId).extras.find(function(t){return t.id===e.id});e.extraId=t.id,e.duration=t.duration,e.name=t.name,e.price=t.price,e.selected=!0,e.quantity>t.maxQuantity&&(e.quantity=t.maxQuantity),this.calendarVisible&&t.duration&&this.getTimeSlots()},getTimeSlots:function(){var e=this;if(this.$refs.booking.validate(function(e){if(!e)return!1}),this.appointment.serviceId){this.loadingTimeSlots=!0;var t=[];this.selectedExtras.forEach(function(e){e.id&&t.push({id:e.id,quantity:e.quantity})});var o=[],n=this;this.appointment.providerId||(n.group.enabled?this.employeesFiltered.forEach(function(e){void 0!==e.serviceList.find(function(e){return e.id===n.appointment.serviceId&&e.maxCapacity>=n.appointment.bookings[0].persons})&&o.push(e.id)}):this.employeesFiltered.forEach(function(e){void 0!==e.serviceList.find(function(e){return e.id===n.appointment.serviceId})&&o.push(e.id)})),"afterBookingSelectService"in window&&window.afterBookingSelectService(this.appointment,this.getServiceById(this.appointment.serviceId),this.getProviderById(this.appointment.providerId),this.getLocationById(this.appointment.locationId)),this.$http.get(this.$root.getAjaxUrl+"/slots",{params:{serviceId:this.appointment.serviceId,providerIds:this.appointment.providerId?[this.appointment.providerId]:o,extras:JSON.stringify(t),group:1,persons:this.appointment.bookings[0].persons}}).then(function(t){var o=e.$root.settings.general.showClientTimeZone?e.getConvertedTimeSlots(t.data.data.slots):t.data.data.slots;e.calendarVisible||(e.activePicker=!e.activePicker,document.getElementById(e.id).classList.toggle("am-active-picker",e.activePicker));var n=[],a=null;(Object.keys(o).forEach(function(e){null===a&&(a=e),n.push(i()(e).toDate())}),e.showFirstEventMonth(a),e.calendarTimeSlots=o,e.disabledWeekdays={weekdays:[]},e.disabledWeekdays=0===n.length?{weekdays:[1,2,3,4,5,6,7]}:null,e.availableDates=n,e.calendarVisible=!0,e.availableDates.length&&e.setTimeSlots(),e.availableDates.length&&e.isSelectedDateAvailable())||(e.showTimes=!1,document.getElementById(e.id).classList.remove("am-show-times"));var s=!e.availableDates.length||!e.isSelectedDateAvailable(),r=e.appointment.bookingStartTime&&-1===e.availableTimeSlots.indexOf(e.appointment.bookingStartTime);(s||r)&&(s&&(e.selectedDate=null),e.unSelectTime()),e.fetchedSlots=!0,e.fetched=!0,e.loadingTimeSlots=!1}).catch(function(t){console.log(t.message),e.fetchedSlots=!0,e.fetched=!0})}},showFirstEventMonth:function(e){if(this.isServiceChanged&&(null===this.selectedDate&&i()(this.selectedMonth).format("YYYY-MM")!==i()(e,"YYYY-MM-DD").format("YYYY-MM")||null!==this.selectedDate&&i()(this.selectedDate).format("YYYY-MM")!==i()(e,"YYYY-MM-DD").format("YYYY-MM"))){this.selectedDate=i()(e).toDate();var t=this;setTimeout(function(){t.selectedDate=null},100)}this.isServiceChanged=!1},selectDate:function(e){var t=this;this.unSelectTime();var o=!1;if(e.attributes.forEach(function(e){e.hasOwnProperty("key")&&"disabled"===e.key&&(o=!0)}),!o){this.showTimes=!1;var n=document.getElementById(this.id);n.classList.remove("am-show-times");var i=e.event.target.parentNode.parentNode.parentNode.parentNode.parentNode;i.classList.contains("c-week")||(i=e.event.target.parentNode.parentNode.parentNode.parentNode),i.classList.contains("c-week")||(i=e.event.target.parentNode.parentNode.parentNode),i.parentNode.insertBefore(this.times,i.nextSibling),setTimeout(function(){t.availableTimeSlots.length&&t.selectedDate&&(t.showTimes=!0,n.classList.add("am-show-times"))},200)}},isSelectedDateAvailable:function(){var e=i()(this.selectedDate);return this.calendarTimeSlots.hasOwnProperty(e.locale("en").format("YYYY-MM-DD"))},setTimeSlots:function(){var e=i()(this.selectedDate).locale("en").format("YYYY-MM-DD");this.isSelectedDateAvailable()&&(this.availableTimeSlots=Object.keys(this.calendarTimeSlots[e]),this.appointment.duration=this.getAppointmentDuration(this.getServiceById(this.appointment.serviceId),this.selectedExtras))},togglePicker:function(){this.calendarVisible=!1,this.activePicker=!this.activePicker,document.getElementById(this.id).classList.toggle("am-active-picker",this.activePicker)},selectTime:function(){this.appointment.bookingStart=i()(this.selectedDate).format("YYYY-MM-DD")+" "+this.appointment.bookingStartTime,this.showCalendarContinueButton=!0,this.scrollView("am-button-wrapper")},unSelectTime:function(){this.appointment.bookingStartTime=null,this.showCalendarContinueButton=!1},showConfirmBookingDialog:function(){var e=this;if(!this.appointment.providerId){var t=this.calendarTimeSlots[i()(this.selectedDate).format("YYYY-MM-DD")][this.appointment.bookingStartTime],o=Math.floor(Math.random()*t.length+1);this.appointment.providerId=this.calendarTimeSlots[i()(this.selectedDate).format("YYYY-MM-DD")][this.appointment.bookingStartTime][o-1]}this.appointment.bookings[0].extras=this.selectedExtras,"afterBookingSelectDateAndTime"in window&&window.afterBookingSelectDateAndTime(this.appointment,this.getServiceById(this.appointment.serviceId),this.getProviderById(this.appointment.providerId),this.getLocationById(this.appointment.locationId)),this.activeConfirm=!0;var n=document.getElementById(this.id);setTimeout(function(){n.classList.toggle("am-active-confirm",e.activeConfirm)},1e3)},cancelBooking:function(){this.activeConfirm=!1;var e=document.getElementById(this.id);e.classList.toggle("am-active-confirm",this.activeConfirm),this.showCalendarOnly(!0)&&(e.classList.add("am-mobile-collapsed"),e.classList.remove("am-desktop"))},inlineBookingSVG:function(){o(685).init({svgSelector:"img.svg-booking",initClass:"js-inlinesvg"})},handleResize:function(){var e=document.getElementById(this.id);if(this.showCalendarOnly(!0))return e.classList.add("am-mobile-collapsed"),e.classList.remove("am-desktop"),void(this.showCalendarBackButton=!1);if(e){var t=e.offsetWidth;this.showCalendarOnly(!1)?(e.classList.add("am-mobile-collapsed"),e.classList.remove("am-desktop"),this.showCalendarBackButton=!1):t<670?(e.classList.add("am-mobile-collapsed"),e.classList.remove("am-desktop"),this.showCalendarBackButton=!0):(e.classList.add("am-desktop"),e.classList.remove("am-mobile-collapsed"),this.showCalendarBackButton=!1)}},confirmedBooking:function(e){if(this.$http.post(this.$root.getAjaxUrl+"/bookings/success/"+e.booking.id,{type:"appointment",appointmentStatusChanged:e.appointmentStatusChanged}).then(function(e){}).catch(function(e){}),"beforeConfirmedBooking"in window)window.beforeConfirmedBooking();else{var t=[];e.utcTime.forEach(function(e){t.push({start:i.a.utc(e.start.replace(/ /g,"T")).toDate(),end:i.a.utc(e.end.replace(/ /g,"T")).toDate()})});var o=this.getServiceById(this.appointment.serviceId),n=this.getLocationById(this.getProviderById(this.appointment.providerId).locationId);this.addToCalendarData={title:o.name,dates:t,address:null!==n?n.address:"",description:o.description,id:e.booking.id,status:e.appointment.bookings[0].status,active:this.$root.settings.general.addToCalendar,color:e.color,type:e.type},this.showAddToCalendar=!0}},clearValidation:function(){void 0!==this.$refs.booking&&this.$refs.booking.clearValidate()},closeDialogAddToCalendar:function(){this.showAddToCalendar=!1,document.getElementsByClassName("amelia-app-booking")[0].style.display="none",window.location.reload()}},computed:{servicesFiltered:function(){var e=this,t=this.options.entities.services;if(this.appointment.providerId){var o=[];this.employeesFiltered.find(function(t){return t.id===e.appointment.providerId}).serviceList.map(function(e){return o.push(e.id)}),t=t.filter(function(e){return-1!==o.indexOf(e.id)})}if(this.appointment.locationId){var n=[];this.options.entities.employees.forEach(function(e){n=n.concat(e.serviceList.map(function(e){return e.id}))}),n=n.filter(function(e,t,o){return o.indexOf(e)===t}),t=t.filter(function(e){return-1!==n.indexOf(e.id)})}t=(t=(t=t.sort(function(e,t){return(e.position&&t.position?e.position>t.position:e.name>t.name)?1:-1})).filter(function(e){return"visible"===e.status})).filter(function(t){return e.getServiceProviders(t.id).filter(function(e){return"visible"===e.status}).length>0});var i=this.options.entities.locations.filter(function(e){return"hidden"===e.status});return this.options.entities.locations.length>0&&(t=t.filter(function(t){return e.getServiceProviders(t.id).filter(function(t){return"visible"===t.status&&null!==t.locationId&&(e.getLocationById(t.locationId)&&"visible"===e.getLocationById(t.locationId).status||i.length===e.options.entities.locations.length)}).length>0})),t},employeesFiltered:function(){var e=this,t=this.options.entities.employees;this.appointment.serviceId&&(t=t.filter(function(t){return t.serviceList.find(function(t){return t.id===e.appointment.serviceId})})),this.appointment.locationId&&(t=t.filter(function(t){return t.locationId===e.appointment.locationId})),t=t.filter(function(e){return e.serviceList.filter(function(e){return"visible"===e.status}).length>0});var o=this.options.entities.locations.filter(function(e){return"hidden"===e.status});return this.options.entities.locations.length>0&&(t=t.filter(function(t){return null!==t.locationId&&(e.getLocationById(t.locationId)&&"visible"===e.getLocationById(t.locationId).status||o.length===e.options.entities.locations.length)})),t.filter(function(e){return"visible"===e.status})},locationsFiltered:function(){var e=this,t=this.options.entities.locations;if(this.appointment.providerId){var o=this.employeesFiltered.find(function(t){return t.id===e.appointment.providerId});t=t.filter(function(e){return e.id===o.locationId})}if(this.appointment.serviceId){var n=this.employeesFiltered.filter(function(t){return t.serviceList.find(function(t){return t.id===e.appointment.serviceId})});t=t.filter(function(e){return-1!==n.map(function(e){return e.locationId}).indexOf(e.id)})}var i=this.employeesFiltered.map(function(e){return e.locationId}).filter(function(e,t,o){return o.indexOf(e)===t});return(t=t.filter(function(e){return-1!==i.indexOf(e.id)})).filter(function(e){return"visible"===e.status})}},components:{moment:i.a,PhoneInput:d.a,ConfirmBooking:u.a,AddToCalendar:h.a}}},938:function(e,t){e.exports={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"am-wrap"},[o("div",{directives:[{name:"show",rawName:"v-show",value:!e.fetched,expression:"!fetched"}],staticClass:"am-spinner am-section"},[o("img",{staticClass:"svg-booking am-spin",attrs:{src:e.$root.getUrl+"public/img/oval-spinner.svg"}}),e._v(" "),o("img",{staticClass:"svg-booking am-hourglass",attrs:{src:e.$root.getUrl+"public/img/hourglass.svg"}})]),e._v(" "),o("div",{directives:[{name:"show",rawName:"v-show",value:e.fetched,expression:"fetched"}],staticClass:"am-step-booking-catalog",attrs:{id:e.id}},[o("div",{staticClass:"am-select-service"},[o("p",{directives:[{name:"show",rawName:"v-show",value:e.showServices,expression:"showServices"}],staticClass:"am-select-service-title"},[e._v("\n "+e._s(e.$root.labels.please_select+" "+e.$root.labels.service)+":\n ")]),e._v(" "),o("p",{directives:[{name:"show",rawName:"v-show",value:!e.showServices,expression:"!showServices"}],staticClass:"am-select-service-title"},[e._v("\n "+e._s(e.$root.labels.book_appointment)+"\n ")]),e._v(" "),o("el-form",{ref:"booking",attrs:{model:e.appointment,rules:e.rules,"label-position":"top"}},[e.showServices?o("el-form-item",{staticClass:"am-select-service-option",attrs:{label:e.capitalizeFirstLetter(e.$root.labels.service)+":",prop:"serviceId"}},[o("el-select",{attrs:{placeholder:"",loading:!e.fetched},on:{change:e.changeService},model:{value:e.appointment.serviceId,callback:function(t){e.$set(e.appointment,"serviceId",t)},expression:"appointment.serviceId"}},e._l(e.servicesFiltered,function(e){return o("el-option",{key:e.id,attrs:{label:e.name,value:e.id}})}),1)],1):e._e(),e._v(" "),e.showLocations?o("el-form-item",{staticClass:"am-select-location-option",attrs:{label:e.$root.labels.location_colon}},[o("el-select",{attrs:{placeholder:"",clearable:"",loading:!e.fetched},model:{value:e.appointment.locationId,callback:function(t){e.$set(e.appointment,"locationId",t)},expression:"appointment.locationId"}},e._l(e.locationsFiltered,function(e){return o("el-option",{key:e.id,attrs:{disabled:e.disabled,label:e.name,value:e.id}})}),1)],1):e._e(),e._v(" "),e.showEmployees?o("el-form-item",{staticClass:"am-select-employee-option",attrs:{label:e.capitalizeFirstLetter(e.$root.labels.employee)+":"}},[o("el-select",{attrs:{placeholder:"",clearable:0!==e.appointment.providerId,loading:!e.fetched},on:{change:e.changeEmployee,clear:function(t){e.appointment.providerId=0}},model:{value:e.appointment.providerId,callback:function(t){e.$set(e.appointment,"providerId",t)},expression:"appointment.providerId"}},[o("el-option",{key:0,staticClass:"am-select-any-employee-option",attrs:{label:e.$root.settings.labels.enabled?e.$root.labels.any+" "+e.$root.labels.employee:e.$root.labels.any_employee,value:0}}),e._v(" "),e._l(e.employeesFiltered,function(e){return o("el-option",{key:e.id,attrs:{label:e.firstName+" "+e.lastName,value:e.id}})})],2)],1):e._e(),e._v(" "),o("el-form-item",{directives:[{name:"show",rawName:"v-show",value:e.group.allowed&&!e.$root.isLite,expression:"group.allowed && !$root.isLite"}],attrs:{label:""}},[o("el-row",[o("el-col",{attrs:{span:18}},[o("span",[e._v(e._s(e.$root.labels.bringing_anyone_with_you))])]),e._v(" "),o("el-col",{staticClass:"am-align-right",attrs:{span:6}},[o("el-switch",{on:{change:e.enableGrouping},model:{value:e.group.enabled,callback:function(t){e.$set(e.group,"enabled",t)},expression:"group.enabled"}})],1)],1)],1),e._v(" "),o("transition",{attrs:{name:"fade"}},[o("div",{directives:[{name:"show",rawName:"v-show",value:e.group.enabled&&!e.$root.isLite,expression:"group.enabled && !$root.isLite"}],staticClass:"am-grouped"},[o("el-form-item",{attrs:{label:e.$root.labels.number_of_additional_persons}},[o("el-select",{attrs:{placeholder:""},on:{change:e.changeNumberOfPersons},model:{value:e.appointment.bookings[0].persons,callback:function(t){e.$set(e.appointment.bookings[0],"persons",t)},expression:"appointment.bookings[0].persons"}},e._l(e.group.options,function(e){return o("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})}),1)],1)],1)]),e._v(" "),o("transition-group",{staticClass:"am-extras-add",attrs:{name:"fade"}},e._l(e.selectedExtras,function(t,n){return e.appointment.serviceId&&e.getServiceById(e.appointment.serviceId).extras.length>0?o("div",{key:n+1,staticClass:"am-extras"},[o("el-row",{staticClass:"am-flex-row-middle-align-mobile",attrs:{gutter:16}},[o("el-col",{attrs:{span:14}},[o("el-form-item",{attrs:{label:e.$root.labels.extra_colon}},[o("el-select",{attrs:{placeholder:""},on:{change:function(o){return e.changeSelectedExtra(t)}},model:{value:t.id,callback:function(o){e.$set(t,"id",o)},expression:"selectedExtra.id"}},e._l(e.getAvailableExtras(t),function(e){return o("el-option",{key:e.id,attrs:{label:e.name,value:e.id}})}),1)],1)],1),e._v(" "),o("el-col",{attrs:{span:7}},[o("el-form-item",{attrs:{label:e.$root.labels.qty_colon}},[o("el-select",{attrs:{disabled:null===t.id,placeholder:""},on:{change:function(o){return e.changeSelectedExtra(t)}},model:{value:t.quantity,callback:function(o){e.$set(t,"quantity",o)},expression:"selectedExtra.quantity"}},e._l(e.getSelectedExtraMaxQuantity(t),function(e){return o("el-option",{key:e,attrs:{label:e,value:e}})}),1)],1)],1),e._v(" "),o("el-col",{staticClass:"am-align-right",attrs:{span:3}},[o("div",{staticClass:"am-delete-element",on:{click:function(t){return e.deleteExtra(n)}}},[o("i",{staticClass:"el-icon-minus"})])])],1),e._v(" "),t.duration||t.price?o("el-row",{staticClass:"am-flex-row-middle-align-mobile",attrs:{gutter:16}},[o("el-col",{attrs:{span:14}},[o("el-form-item",{attrs:{label:e.$root.labels.duration_colon}},[o("span",[e._v("\n "+e._s(t.duration?e.secondsToNiceDuration(t.duration):"/"))])])],1),e._v(" "),o("el-col",{attrs:{span:10}},[o("el-form-item",{attrs:{label:e.$root.labels.price_colon}},[o("span",[e._v("\n "+e._s(e.getFormattedPrice(t.price)))])])],1)],1):e._e()],1):e._e()}),0),e._v(" "),o("div",{directives:[{name:"show",rawName:"v-show",value:e.appointment.serviceId&&e.selectedExtras.length