text: (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([[87],{e56b:function(t,e,n){"use strict";n.r(e);var c=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("q-page",{attrs:{padding:""}},[n("q-card",{staticClass:"border-radius row bg-white"},[n("div",{staticClass:"col-xs-12 q-pa-md"},[t.clientDetails?n("div",{class:(t.$q.screen.lt.sm,"col q-mx-lg")},[n("q-field",{staticClass:"q-py-xs",attrs:{borderless:"","stack-label":"",label:t.$t("client")}},[t._v("\n          "+t._s(t.clientDetails.lastName)+" "+t._s(t.clientDetails.firstName)+"\n        ")]),n("q-field",{staticClass:"q-py-xs",attrs:{borderless:"","stack-label":"",label:t.$t("field_sex")}},[t._v("\n          "+t._s(t.clientSexLabel)+"\n        ")]),n("div",{staticClass:"row q-my-sm"},[n("q-btn",{staticClass:"col-xs-12 col-sm-auto",class:t.$q.screen.lt.sm?"q-mb-sm":"q-mr-sm",attrs:{rounded:"",color:"secondary",label:t.$t("connect_to_client")}},[n("q-menu",{attrs:{"auto-close":""},on:{show:t.logConnectClient}},[n("social-popup",{attrs:{user:t.clientDetails}})],1)],1),n("q-btn",{staticClass:"col-xs-12 col-sm-auto",attrs:{rounded:"",label:t.$t("action_edit"),icon:"edit",color:"primary"},on:{click:function(e){return t.openForm(t.clientId)}}})],1)],1):t._e()]),t.companyId?n("company-client-form",{attrs:{companyId:t.companyId}}):t._e()],1),n("q-card",{staticClass:"border-radius q-mt-sm row bg-white"},[n("div",{staticClass:"col-xs-12 q-pa-sm"},[n("appoinmentList",{attrs:{"client-id":t.clientId,"company-id":t.companyId}})],1)])],1)},r=[],s=(n("8e6e"),n("8a81"),n("ac6a"),n("cadf"),n("06db"),n("456d"),n("96cf"),n("c973")),i=n.n(s),o=n("9523"),a=n.n(o),l=(n("c5f6"),n("1cb6")),u=n("2f62"),p=n("354f"),d=n("aa23"),m=n("42f8"),b=n("c684");function f(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(t);e&&(c=c.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,c)}return n}function h(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?f(Object(n),!0).forEach((function(e){a()(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}var y={name:"CompanyClientDetails",components:{appoinmentList:p["a"],SocialPopup:d["a"],CompanyClientForm:m["a"]},props:{companyId:{type:[Number,String],required:!0},clientId:{type:[Number,String],required:!0}},computed:h({},Object(u["c"])("client",["clientDetails"]),{clientSexLabel:function(){return this.$t(b["a"][this.clientDetails.sex])}}),mounted:function(){this.fetch()},beforeDestroy:function(){this.CLIENT_DETAILS_RESET()},methods:h({},Object(u["b"])("client",["fetchClientDetails"]),{},Object(u["d"])(h({showForm:function(t,e){return t("client/showForm",e)},setSelectedId:function(t,e){return t("client/setSelectedId",e)}},Object(u["d"])("client",["CLIENT_DETAILS_RESET"]))),{logConnectClient:function(){l["a"].logEvent("my-clients-page","connect-client",this.clientId,0,this.$router.currentRoute)},openForm:function(t){t&&this.setSelectedId(t),this.showForm(),l["a"].logEvent("my-clients-page","open-client-edit",t,0,this.$router.currentRoute)},fetch:function(){var t=i()(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,this.fetchClientDetails({variables:{id:+this.clientId}});case 2:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}()})},w=y,g=n("42e1"),O=Object(g["a"])(w,c,r,!1,null,null,null);e["default"]=O.exports}}]);