{"version":3,"sources":["webpack:///./src/components/ClientOrganization.vue","webpack:///./src/components/ClientOrganization.vue?b8f7","webpack:///./src/components/ClientOrganization.vue?218a","webpack:///./src/components/ClientOrganization.vue?353b","webpack:///../../../src/components/VWindow/VWindowItem.ts","webpack:///../../../src/components/VTabs/VTabItem.ts"],"names":["attrs","_vm","getSelectedClientName","_c","model","callback","$$v","tab","tabContent","key","item","on","setTabsNavHeight","staticStyle","value","expression","component","tag","closeDialog","staticRenderFns","ClientInfo","then","m","default","PersonsList","Vue","extend","name","data","componentKey","currentModulePath","CustomerEnum","CustomerPersons","parentModulePath","this","$router","currentRoute","path","split","parentName","clientTabs","minHeight","$refs","components","watch","$route","to","from","getSelectedClient","deep","handler","console","log","updateComponentKey","computed","$store","state","context","selectedClient","tabs","id","title","subtitle","methods","isLastMember","$emit","$children","forEach","$el","clientHeight","undefined","baseMixins","mixins","Bootable","GroupableFactory","directives","Touch","props","disabled","Boolean","reverseTransition","type","String","transition","required","isActive","inTransition","classes","groupClasses","computedTransition","windowGroup","internalReverse","genDefaultSlot","getSlot","genWindowItem","$createElement","staticClass","class","$listeners","onAfterTransition","transitionCount","transitionHeight","onBeforeTransition","convertToUnit","onTransitionCancelled","onEnter","el","$nextTick","render","h","beforeEnter","afterEnter","enterCancelled","beforeLeave","afterLeave","leaveCancelled","enter","showLazyContent","VWindowItem","options","call","domProps"],"mappings":"0MAA+H,EAAK,W,IAA+BA,EAAM,K,EAAC,EAAMC,MAAIC,GAAsB,QAAa,Y,OAAI,SAAG,IAAI,EAAG,cAAeF,GAAK,aAAC,iB,MAAC,CAAoB,4BAAIG,YAAY,MAAS,kBAAsBF,CAAyB,MAAE,CAACD,eAAM,KAAiB,SAAU,CAAG,OAAIG,aAAY,iC,MAAQ,CAAiC,UAAS,IAAC,cAAmCC,GAAK,OAAC,C,MAAM,CAAWC,mBAAmBC,c,KAAUC,GAAO,eAAC,oBAAiB,OAAGN,MAAQA,EAAIO,IAA2B,SAAU,SAAQ,GAACC,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HAxB,EAAKkB,KAAM6F,SAAW/G,EAAKkB,KAAM6F,UAAY,GAC7C/G,EAAKkB,KAAM6F,SAAS7D,GAAK1B,KAAK0B,IAAM1B,KAAKpB,MAElCJ","file":"js/chunk-cb783622.b8b6cb0e.js","sourcesContent":["var render = function render(){var _vm=this,_c=_vm._self._c,_setup=_vm._self._setupProxy;return _c('div',{key:_vm.componentKey},[_c('keep-alive',[_c('PageHeader',{attrs:{\"msg\":_vm.getSelectedClientName,\"noSelector\":true}})],1),_c('ClientInfo',{attrs:{\"clientPersons\":true}}),_c('v-card',{style:({'min-height': `calc(${_vm.minHeight}px + 50px)`}),attrs:{\"elevation\":\"0\",\"outlined\":\"\"}},[_c('v-tabs',{attrs:{\"background-color\":\"transparent\",\"grow\":\"\",\"active-class\":\"white dark--text\"},model:{value:(_vm.tab),callback:function ($$v) {_vm.tab=$$v},expression:\"tab\"}},_vm._l((_vm.tabContent),function(item){return _c('v-tab',{key:item.id,staticClass:\"flex-column\",on:{\"click\":function($event){return _vm.setTabsNavHeight()}}},[_c('b',{staticStyle:{\"padding-top\":\"2%\"}},[_vm._v(_vm._s(item.title))]),_c('p',{staticStyle:{\"text-transform\":\"none\"}},[_vm._v(\" \"+_vm._s(item.subtitle))])])}),1),_c('v-tabs-items',{ref:\"clientTabs\",model:{value:(_vm.tab),callback:function ($$v) {_vm.tab=$$v},expression:\"tab\"}},_vm._l((_vm.tabContent),function(item){return _c('v-tab-item',{key:item.id,staticClass:\"px-5\",attrs:{\"transition\":\"false\",\"reverse-transition\":\"false\"}},[_c(item.component,{tag:\"component\",attrs:{\"clientPersons\":true},on:{\"closeDialog\":_vm.closeDialog}})],1)}),1)],1)],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\nimport Vue from \"vue\"\nimport { aclWrapper } from \"@/utilities/aclWrapper\"\nimport { Client } from \"@/types/responses\"\n\nconst ClientInfo = () => import(\"@/components/customer/ClientInfo.vue\").then(m => m.default || m)\nconst PersonsList = () => import(\"@/components/customer/PersonsList.vue\").then(m => m.default || m)\n\nimport { CustomerEnum } from \"@/types/enums\"\nimport { Route } from \"vue-router\"\n\nexport default Vue.extend({\n\tname: \"ClientOrganization\",\n\tdata(): {\n componentKey: number\n\t\tcurrentModulePath: CustomerEnum.CustomerPersons\n\t\tparentModulePath: string\n\t\tparentName: string\n\t\t// eslint-disable-next-line\n tab: null | Record\n\t\t// eslint-disable-next-line\n clientTabs: null | Record\n minHeight: number | string\n\t} {\n\t\treturn {\n componentKey: 0,\n\t\t\tcurrentModulePath: CustomerEnum.CustomerPersons,\n\t\t\tparentModulePath: this.$router.currentRoute.path.split(\"/\")[1],\n\t\t\tparentName: this.$router.currentRoute.name ? this.$router.currentRoute.name : \"\",\n tab: null,\n\t\t\tclientTabs: null,\n minHeight: \"100%\"\n\t\t}\n\t},\n async mounted(){\n\t\tthis.clientTabs = (this.$refs as any).clientTabs;\n\t\tthis.setTabsNavHeight()\n },\n\tcomponents: {\n\t\tClientInfo\n\t},\n\twatch: {\n\t\t$route(to: Route, from: Route) {\n\t\t\tthis.parentModulePath = to.path.split(\"/\")[1]\n\t\t\tthis.parentName = to.name ? to.name : \"\"\n\t\t},\n\t\tgetSelectedClient: {\n deep: true,\n handler(){\n console.log(\"selected client has been updated\")\n this.updateComponentKey()\n }\n }\n\t},\n computed: {\n getSelectedClient(): Client | null {\n return this.$store.state.context.selectedClient\n },\n\t\tgetSelectedClientName(): string {\n\t\t\tif (this.$store.state.context.selectedClient) {\n\t\t\t\treturn this.$store.state.context.selectedClient.name\n\t\t\t} else {\n\t\t\t\treturn \"\"\n\t\t\t}\n\t\t},\n tabContent(): Array{\n const tabs = [\n {\n id: 1,\n title: \"CONTACTS\",\n subtitle:\"External contacts and employees with limited access\",\n component: PersonsList\n }\n ]\n\n return tabs;\n }\n\t},\n methods: {\n async updateComponentKey(): Promise {\n this.componentKey++;\n },\n closeDialog(isLastMember?: boolean): void{\n \n console.log(\"[ClientOrganization] Emitting closeDialog\")\n if(isLastMember){\n console.log(\"[ClientOrganization] Is Last member in ClientOrg.\")\n this.$emit('closeDialog', true)\n }else {\n \n this.$emit('closeDialog', null)\n }\n\n },\n\t\tsetTabsNavHeight(): number | string {\n if(this.clientTabs == null) {\n return 0\n }\n else {\n // eslint-disable-next-line\n this.clientTabs.$children.forEach((tab: any) => {\n if(\n tab.$el.clientHeight >= this.minHeight || \n this.minHeight == undefined || \n this.minHeight == \"100%\" \n ){\n this.minHeight = tab.$el.clientHeight;\n }\n });\n return this.minHeight\n }\n }\n }\n \n})\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--14-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--14-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ClientOrganization.vue?vue&type=script&lang=ts\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--14-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--14-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ClientOrganization.vue?vue&type=script&lang=ts\"","import { render, staticRenderFns } from \"./ClientOrganization.vue?vue&type=template&id=037cf0e7\"\nimport script from \"./ClientOrganization.vue?vue&type=script&lang=ts\"\nexport * from \"./ClientOrganization.vue?vue&type=script&lang=ts\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","// Components\nimport VWindow from './VWindow'\n\n// Mixins\nimport Bootable from '../../mixins/bootable'\nimport { factory as GroupableFactory } from '../../mixins/groupable'\n\n// Directives\nimport Touch from '../../directives/touch'\n\n// Utilities\nimport { convertToUnit, getSlot } from '../../util/helpers'\nimport mixins, { ExtractVue } from '../../util/mixins'\n\n// Types\nimport { VNode } from 'vue'\n\nconst baseMixins = mixins(\n Bootable,\n GroupableFactory('windowGroup', 'v-window-item', 'v-window')\n)\n\ninterface options extends ExtractVue {\n $el: HTMLElement\n windowGroup: InstanceType\n}\n\nexport default baseMixins.extend().extend(\n /* @vue/component */\n).extend({\n name: 'v-window-item',\n\n directives: {\n Touch,\n },\n\n props: {\n disabled: Boolean,\n reverseTransition: {\n type: [Boolean, String],\n default: undefined,\n },\n transition: {\n type: [Boolean, String],\n default: undefined,\n },\n value: {\n required: false,\n },\n },\n\n data () {\n return {\n isActive: false,\n inTransition: false,\n }\n },\n\n computed: {\n classes (): object {\n return this.groupClasses\n },\n computedTransition (): string | boolean {\n if (!this.windowGroup.internalReverse) {\n return typeof this.transition !== 'undefined'\n ? this.transition || ''\n : this.windowGroup.computedTransition\n }\n\n return typeof this.reverseTransition !== 'undefined'\n ? this.reverseTransition || ''\n : this.windowGroup.computedTransition\n },\n },\n\n methods: {\n genDefaultSlot () {\n return getSlot(this)\n },\n genWindowItem () {\n return this.$createElement('div', {\n staticClass: 'v-window-item',\n class: this.classes,\n directives: [{\n name: 'show',\n value: this.isActive,\n }],\n on: this.$listeners,\n }, this.genDefaultSlot())\n },\n onAfterTransition () {\n if (!this.inTransition) {\n return\n }\n\n // Finalize transition state.\n this.inTransition = false\n if (this.windowGroup.transitionCount > 0) {\n this.windowGroup.transitionCount--\n\n // Remove container height if we are out of transition.\n if (this.windowGroup.transitionCount === 0) {\n this.windowGroup.transitionHeight = undefined\n }\n }\n },\n onBeforeTransition () {\n if (this.inTransition) {\n return\n }\n\n // Initialize transition state here.\n this.inTransition = true\n if (this.windowGroup.transitionCount === 0) {\n // Set initial height for height transition.\n this.windowGroup.transitionHeight = convertToUnit(this.windowGroup.$el.clientHeight)\n }\n this.windowGroup.transitionCount++\n },\n onTransitionCancelled () {\n this.onAfterTransition() // This should have the same path as normal transition end.\n },\n onEnter (el: HTMLElement) {\n if (!this.inTransition) {\n return\n }\n\n this.$nextTick(() => {\n // Do not set height if no transition or cancelled.\n if (!this.computedTransition || !this.inTransition) {\n return\n }\n\n // Set transition target height.\n this.windowGroup.transitionHeight = convertToUnit(el.clientHeight)\n })\n },\n },\n\n render (h): VNode {\n return h('transition', {\n props: {\n name: this.computedTransition,\n },\n on: {\n // Handlers for enter windows.\n beforeEnter: this.onBeforeTransition,\n afterEnter: this.onAfterTransition,\n enterCancelled: this.onTransitionCancelled,\n\n // Handlers for leave windows.\n beforeLeave: this.onBeforeTransition,\n afterLeave: this.onAfterTransition,\n leaveCancelled: this.onTransitionCancelled,\n\n // Enter handler for height transition.\n enter: this.onEnter,\n },\n }, this.showLazyContent(() => [this.genWindowItem()]))\n },\n})\n","// Extensions\nimport VWindowItem from '../VWindow/VWindowItem'\n\n/* @vue/component */\nexport default VWindowItem.extend({\n name: 'v-tab-item',\n\n props: {\n id: String,\n },\n\n methods: {\n genWindowItem () {\n const item = VWindowItem.options.methods.genWindowItem.call(this)\n\n item.data!.domProps = item.data!.domProps || {}\n item.data!.domProps.id = this.id || this.value\n\n return item\n },\n },\n})\n"],"sourceRoot":""}