"use strict";(self["webpackChunkcarabi_x2"]=self["webpackChunkcarabi_x2"]||[]).push([[8356],{3625:function(t,e,i){i.r(e),i.d(e,{default:function(){return p}});var o=function(){var t=this,e=t._self._c;return t.structLoaded?e("DocPropList",{ref:"propList",attrs:{documentId:t.listDocumentId,docProp:t.docPropInfo,docModel:t.docModel},on:{create:function(e){t.loaded=!0},documentOpen:t.documentOpen,documentLink:t.documentLink,documentReload:function(e){return t.$emit("reload")},editorStart:function(e){return t.$emit("editing",!0)},editorChange:function(e){return t.$emit("editing",!1)},block:function(e){return t.$emit("block",e)}}}):e("div",{staticClass:"uk-flex uk-flex-middle uk-flex-center",staticStyle:{height:"100%"}},[e("div",{staticClass:"uk-text-large uk-text-muted"},[e("i",{staticClass:"uk-icon-refresh uk-icon-spin"}),t._v(" Загрузка...")])])},n=[],d=i(5512),s=i(725),c=i(3216),u=i(2643),r=i(6587),l={name:"CardPluginList",components:{DocPropList:()=>(0,s.A)(Promise.all([i.e(3230),i.e(2768)]).then(i.bind(i,912)))},props:{documentId:Number,info:Object,docModel:Object,pluginId:Number,height:Number},data(){return{loaded:!1,structLoaded:!1,fields:null,docPropInfo:null}},computed:{listDocumentId(){return this.fields?this.fields[0].DOCUMENT_ID?this.fields[0].DOCUMENT_ID:this.documentId:null}},watch:{},async mounted(){this.structLoaded=!1;r(this.$refs.container);if(this.fields=await c.vd.select("CARD_VIEW_PROPERTIES",{VIEW_GROUP_ID:this.pluginId,DOCUMENT_ID:this.documentId},1),0==this.fields.length)throw new u.yo(`В плагине карточки (VIEW_GROUP_ID=${this.pluginId}) - не привязано ссылочное поле`);this.docPropInfo=await c.vd.selectRow("CARD_GET_DOCPROP_PROPERTIES",{document_id:this.fields[0].DOCUMENT_ID,docprop_id:this.fields[0].DOCPROP_ID}),console.log("init height",this.height),this.structLoaded=!0},methods:{focus(){this.$refs.propList&&this.$refs.propList.focus()},refresh(){console.log("CardPluginList refresh",this.height)},reload(){},documentOpen(t){this.docModel.pushLinks([{type:"property",docPropId:this.fields[0].DOCPROP_ID,documentId:this.listDocumentId},{type:"document",documentId:t}])},documentLink(t){d.A.openDocument(t)}}},h=l,a=i(1656),f=(0,a.A)(h,o,n,!1,null,null,null),p=f.exports}}]);
//# sourceMappingURL=CardPluginList.f48e546c.js.map