ss-component-new 1.3.421 → 1.3.424
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{MTLLoader-BJ1r0nij.cjs → MTLLoader-C1qSZuWT.cjs} +1 -1
- package/dist/{MTLLoader-1LCfWDIN.js → MTLLoader-DBXJU4gy.js} +1 -1
- package/dist/{OrbitControls-BI1MijP-.cjs → OrbitControls-BFwyCnTH.cjs} +1 -1
- package/dist/{OrbitControls-DmwRVj4H.js → OrbitControls-BK6rha_f.js} +1 -1
- package/dist/{URDFLoader-zXHnUuDb.js → URDFLoader-B4rOIDHb.js} +2 -2
- package/dist/{URDFLoader-DbITJ-FE.cjs → URDFLoader-CTaB1j6-.cjs} +1 -1
- package/dist/{animationData-CxG7Qmzl.js → animationData-Bfdz_yNt.js} +2 -2
- package/dist/{animationData-CNXbKt_k.cjs → animationData-DugoMERO.cjs} +1 -1
- package/dist/{array-Ctuf3DOG.js → array-BPirA4Cc.js} +5 -5
- package/dist/{array-DwjaSl70.cjs → array-D4Rx9WHR.cjs} +1 -1
- package/dist/{iconfont-ZM4Mv0Mj.cjs → iconfont-B8J8hnDJ.cjs} +1 -1
- package/dist/{iconfont-B7bT4X1w.js → iconfont-C4b-8B6C.js} +2 -2
- package/dist/{index-DN1FQ4lC.cjs → index-A9g99oCn.cjs} +1 -1
- package/dist/{index-Cmw1O7M3.cjs → index-B3D67GZq.cjs} +1 -1
- package/dist/{index-B3JW2M3W.cjs → index-B8RqhWoJ.cjs} +1 -1
- package/dist/{index-CxEgTjYQ.js → index-BB-4fswu.js} +1 -1
- package/dist/{index-mJFCoPsK.js → index-BK6-AVLE.js} +1 -1
- package/dist/{index-BfETnuY2.cjs → index-BMAjqhNr.cjs} +13 -13
- package/dist/{index-D2iC0RdT.js → index-BWtc895B.js} +81 -75
- package/dist/{index-reJmxzkK.cjs → index-Bn4g3hXz.cjs} +20 -20
- package/dist/{index-Bo8c-hpl.js → index-BnIQk5T3.js} +1 -1
- package/dist/{index-D9T-hj7J.js → index-BosTIy2F.js} +2 -2
- package/dist/{index-fGwDUF0a.cjs → index-Bu5lDLj_.cjs} +1 -1
- package/dist/{index-BOB41C4i.js → index-BzTL89_A.js} +7 -7
- package/dist/{index-DpNuo8iO.cjs → index-C1jFiukZ.cjs} +1 -1
- package/dist/index-C5Pf4k8t.cjs +2 -0
- package/dist/{index-Bd9GpNbZ.cjs → index-C772JVG0.cjs} +1 -1
- package/dist/{index-tdECjK2J.js → index-C9aMOwfq.js} +5 -5
- package/dist/{index-XaM10GFH.js → index-CPLGtgqY.js} +2161 -2158
- package/dist/{index-MPNdMwkX.cjs → index-CVWmCMHh.cjs} +1 -1
- package/dist/{index-BGOXytSm.js → index-CdsqSTRI.js} +1 -1
- package/dist/{index-C2UiLe43.js → index-ChNfRlIP.js} +6 -6
- package/dist/{index-CrXDGlUY.js → index-CjSJE_W_.js} +3 -3
- package/dist/{index-Bo4dSR3m.cjs → index-CnsDmHXo.cjs} +1 -1
- package/dist/{index-DshXKN2f.js → index-D38qJHp0.js} +1 -1
- package/dist/{index-CItyXwKR.js → index-DJsef_j_.js} +4 -4
- package/dist/index-DKh4EyHV.cjs +1 -0
- package/dist/{index-Cdsro90y.cjs → index-DOcUitv0.cjs} +1 -1
- package/dist/{index-BNQrzEfh.js → index-DOhwoePd.js} +1167 -1166
- package/dist/{index-KUIk6_-7.cjs → index-DPYpdz4-.cjs} +1 -1
- package/dist/{index-BxwNVYrj.js → index-DPooN16T.js} +1 -1
- package/dist/{index-4VkWVb4x.js → index-DX6ztcs4.js} +1 -1
- package/dist/{index-F7ilz1xi.cjs → index-D_zk9En4.cjs} +1 -1
- package/dist/{index-zpFkli-r.cjs → index-DaiB_qqV.cjs} +1 -1
- package/dist/{index-D3Ik6E9u.cjs → index-DgpEgbFi.cjs} +1 -1
- package/dist/{index-C9cUuEAp.cjs → index-DhD0tnVr.cjs} +1 -1
- package/dist/{index-BVFUG_jG.js → index-DlXwTcJ9.js} +1 -1
- package/dist/index-GSbBamu4.js +23403 -0
- package/dist/{index-DcuqAO7V.js → index-L3ZBKT8o.js} +3 -3
- package/dist/{index-ND4SQdF3.js → index-TDwSq2BF.js} +1 -1
- package/dist/{index-Bsq8-oqc.cjs → index-eE62vN8n.cjs} +1 -1
- package/dist/{index-BdndCl1P.js → index-ss_5hS2p.js} +1 -1
- package/dist/{index-DloRcfY8.cjs → index-wnEIPRYs.cjs} +1 -1
- package/dist/index-zg0q697-.cjs +26 -0
- package/dist/{index.vue_vue_type_style_index_0_scoped_6b92e250_lang-DMzXQmLy.cjs → index.vue_vue_type_style_index_0_scoped_6b92e250_lang-Bk-thOPD.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_6b92e250_lang-BhSYtqu1.js → index.vue_vue_type_style_index_0_scoped_6b92e250_lang-EOt2_XRY.js} +1 -1
- package/dist/{main-D6vPtVzF.cjs → main-CE-zxQmp.cjs} +1 -1
- package/dist/{main-B_egGqbG.js → main-DPoBb_O1.js} +3 -3
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +2 -2
- package/dist/ss-component.js +10 -10
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +10 -10
- package/dist/{threeModel-Cjo7-QZS.cjs → threeModel-CiR7lpoR.cjs} +1 -1
- package/dist/{threeModel-BSyYeQZu.js → threeModel-Cj67vfAN.js} +5 -5
- package/dist/{threePreview-vl6uhbHM.cjs → threePreview-CbKggw3I.cjs} +1 -1
- package/dist/{threePreview-C6KQqoXZ.js → threePreview-GizvH53S.js} +3 -3
- package/dist/{threeSceneView-BSdMrsfM.js → threeSceneView-2wRxUPkw.js} +10 -10
- package/dist/{threeSceneView-DmFm6Q-S.cjs → threeSceneView-DWuPWq3V.cjs} +1 -1
- package/dist/{threeSceneViewForCPMPIP-CQP66XwY.cjs → threeSceneViewForCPMPIP-BzbKluFb.cjs} +1 -1
- package/dist/{threeSceneViewForCPMPIP-Da0YmvCt.js → threeSceneViewForCPMPIP-DxkeanTl.js} +7 -7
- package/dist/{threeTrackPathView-BvmhaG0W.js → threeTrackPathView-DSHB2LWA.js} +3 -3
- package/dist/{threeTrackPathView-BjwtoU5M.cjs → threeTrackPathView-ZqSjOtFS.cjs} +1 -1
- package/dist/{threeViewerHost-BKNIqrfT.js → threeViewerHost-BAksiU_r.js} +2 -2
- package/dist/{threeViewerHost-lhCLFuMH.cjs → threeViewerHost-Bi3OIwqG.cjs} +1 -1
- package/dist/{urdfTree-CUyckHTO.js → urdfTree-DEWAJ5kl.js} +27 -27
- package/dist/{urdfTree-DD12pYQE.cjs → urdfTree-DnkBJIj6.cjs} +1 -1
- package/dist/{workpieceTreePanel-mmroz89S.cjs → workpieceTreePanel-DzpjPYZ9.cjs} +1 -1
- package/dist/{workpieceTreePanel-BLUYvcFc.js → workpieceTreePanel-XOSlhouq.js} +4 -4
- package/package.json +1 -1
- package/dist/index-2VatFDli.js +0 -23246
- package/dist/index-DE_58kwC.cjs +0 -26
- package/dist/index-DwSzah5b.cjs +0 -2
- package/dist/index-RoXicHV9.cjs +0 -1
package/dist/index-DE_58kwC.cjs
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
"use strict";var Iu=Object.defineProperty;var Ou=(a,l,n)=>l in a?Iu(a,l,{enumerable:!0,configurable:!0,writable:!0,value:n}):a[l]=n;var tn=(a,l,n)=>Ou(a,typeof l!="symbol"?l+"":l,n);const e=require("vue"),Wa=require("./request-Dl8yi2iS.cjs"),A=require("./index-ClvA5-wg.cjs"),cl=require("./index-BfETnuY2.cjs"),oe=require("./index-reJmxzkK.cjs"),ar=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Al=require("./index.vue_vue_type_style_index_0_scoped_6b92e250_lang-DMzXQmLy.cjs"),Ar=require("./index-BOkUwKV5.cjs"),Bo=require("./threeViewerHost-lhCLFuMH.cjs"),Rr=require("./index-DmwxzDGW.cjs"),ts=require("./index-B3JW2M3W.cjs"),ec=require("./index-C9cUuEAp.cjs");;/* empty css */const No=require("./isString-CGrvcmBw.cjs"),ss=require("./index.vue_vue_type_script_setup_true_lang-BKTJR2th.cjs"),ac=require("./index-BVaHwt5f.cjs"),Lu=require("./index-Bo4dSR3m.cjs"),$n=require("./MTLLoader-BJ1r0nij.cjs"),Ru=require("./URDFLoader-DbITJ-FE.cjs");var $u="[object Boolean]";function lc(a){return a===!0||a===!1||Wa.isObjectLike(a)&&Wa.baseGetTag(a)==$u}function Vu(a){return a===void 0}const Pu=a=>a.match(/\((.*)\)/)[1],Fu={__name:"index",props:{isVisible:{type:Boolean,default:!1},title:{type:String,default:""},placement:{type:String,default:"bottom"},width:{type:Number,default:200},trigger:{type:String,default:"click"}},setup(a){const l=a,n=e.ref(null),r=e.ref(!1),i=e.ref(null);return e.watch(()=>l==null?void 0:l.isVisible,()=>{r.value=l==null?void 0:l.isVisible},{deep:!0,immediate:!0}),e.watch(()=>i.value,()=>{e.nextTick(()=>{var s,h;(h=(s=n.value)==null?void 0:s.updatePopper)==null||h.call(s)})},{deep:!0,immediate:!0}),(s,h)=>{const c=e.resolveComponent("el-popover");return e.openBlock(),e.createBlock(c,{visible:r.value,"onUpdate:visible":h[0]||(h[0]=d=>r.value=d),trigger:l.trigger,title:l==null?void 0:l.title,placement:l==null?void 0:l.placement,width:l==null?void 0:l.width,ref_key:"popOverRef",ref:n,"trigger-keys":"[]"},{reference:e.withCtx(()=>[e.createElementVNode("div",null,[e.renderSlot(s.$slots,"reference",{ref_key:"referenceRef",ref:i})])]),default:e.withCtx(()=>[e.createElementVNode("div",null,[e.renderSlot(s.$slots,"content")])]),_:3},8,["visible","trigger","title","placement","width"])}}},ju=e.defineComponent({__name:"index",props:{value:{type:[String,Number],default:""},columnContent:{type:Object,default:{}}},setup(a){const l=a,n=e.computed(()=>{var d,m,b,u,C,M;const r=l.value??"";let i=(d=l==null?void 0:l.columnContent)==null?void 0:d.filter;if(i=(m=oe.analyzeSplitToContent(i,","))==null?void 0:m.map(k=>((k==null?void 0:k[(k==null?void 0:k.length)-1])===","&&(k=k==null?void 0:k.slice(0,(k==null?void 0:k.length)-1)),k)),i=i==null?void 0:i.find(k=>(k==null?void 0:k[0])==="("),(i==null?void 0:i[0])==="("&&(i=i==null?void 0:i.slice(1,(i==null?void 0:i.length)-1)),i=i==null?void 0:i.split("||"),!i)return{backgroundColor:void 0,color:void 0};let s=(u=(b=l==null?void 0:l.columnContent)==null?void 0:b.options)==null?void 0:u.findIndex(k=>(k==null?void 0:k.value)===r);s=i==null?void 0:i[s],s=oe.analyzeSplitToContent(s,","),s=s==null?void 0:s.map(k=>((k==null?void 0:k[(k==null?void 0:k.length)-1])===","&&(k=k==null?void 0:k.slice(0,(k==null?void 0:k.length)-1)),k));let h=s==null?void 0:s.find(k=>k==null?void 0:k.includes("@TextBackRGBA"));h?h=oe.rgbaToColor((C=h==null?void 0:h.split("="))==null?void 0:C[1]):h=void 0;let c=s==null?void 0:s.find(k=>k==null?void 0:k.includes("@TextRGBA"));return c?c=oe.rgbaToColor((M=c==null?void 0:c.split("="))==null?void 0:M[1]):c=void 0,{backgroundColor:h,color:c}});return(r,i)=>a.value!==void 0&&a.value!==null?(e.openBlock(),e.createElementBlock("span",{key:0,class:"task-status-tag",style:e.normalizeStyle(n.value)},e.toDisplayString(a.value===0?"0":a.value),5)):e.createCommentVNode("",!0)}}),Hu=ar._export_sfc(ju,[["__scopeId","data-v-3290070b"]]);function Uu(a,l,n,r={}){if(!a||!l||!n||n.length!==4)return;const i=a.getContext("2d");if(!i)return;const{color:s="rgba(255, 235, 59, 0.3)",strokeWidth:h=2,fillOpacity:c=.2}=r,d=a.getBoundingClientRect(),m=l.getBoundingClientRect(),b=l.naturalWidth,u=l.naturalHeight,C=m.width/b,M=m.height/u,k=Math.min(C,M),W=b*k,O=u*k,j=(d.width-W)/2,L=(d.height-O)/2,_=n.map(([w,g])=>{const E=j+w*W,P=L+g*O;return{x:E,y:P}});i.clearRect(0,0,a.width,a.height),i.beginPath(),i.moveTo(_[0].x,_[0].y);for(let w=1;w<_.length;w++)i.lineTo(_[w].x,_[w].y);i.closePath();const x=s.replace(/[\d.]+\)$/,`${c})`);i.fillStyle=x,i.fill(),i.strokeStyle=s.replace(/[\d.]+\)$/,"1)"),i.lineWidth=h,i.stroke()}function Si(a){if(!a)return;const l=a.getContext("2d");l&&l.clearRect(0,0,a.width,a.height)}function cs(a,l){if(!a||!l)return null;const n=a[l];return!n||!n.bboxNorm||!Array.isArray(n.bboxNorm)||n.bboxNorm.length!==4?null:{bboxNorm:n.bboxNorm,imageName:n.imageName||""}}const qu={key:0,class:"ocr-img-preview-root"},Wu={class:"ocr-img-preview-window"},Ku={key:0,class:"img-preview-body"},Gu={class:"img-preview-header"},Yu={class:"img-header-left"},Ju={class:"img-name"},Xu={key:0,class:"img-header-right"},Zu={class:"img-index"},Qu={key:0,class:"img-thumb-list"},ed=["onClick"],ad={key:1,class:"thumb-placeholder"},ld={class:"thumb-name"},rd={class:"img-preview-container"},nd={key:0,class:"img-placeholder"},id={key:2,class:"img-placeholder"},od={key:0},td={key:1},sd={key:1,class:"img-placeholder"},cd=e.defineComponent({__name:"imgPreview",props:{visible:{type:Boolean,default:!1},images:{type:Array,default:()=>[]},defaultImageName:{type:String,default:""},fieldMeta:{type:Object,default:()=>({})},focusedFieldName:{type:String,default:""}},emits:["update:visible","close"],setup(a,{emit:l}){const n=a,r=l,i=e.computed({get:()=>n.visible,set:T=>r("update:visible",T)});let s=!1,h="",c=0,d=0,m=0,b=0,u=0,C=0,M=null;const k=T=>{var U,ge;const ie=(ge=(U=T==null?void 0:T.target)==null?void 0:U.closest)==null?void 0:ge.call(U,".ocr-img-preview-window");return ie||document.querySelector(".ocr-img-preview-window")},W=T=>{if(!T||T==="none")return{tx:0,ty:0};let ie=T.match(/matrix\(([^)]+)\)/);if(ie){const U=ie[1].split(",").map(ge=>Number(ge.trim()));return{tx:(U==null?void 0:U[4])||0,ty:(U==null?void 0:U[5])||0}}if(ie=T.match(/matrix3d\(([^)]+)\)/),ie){const U=ie[1].split(",").map(ge=>Number(ge.trim()));return{tx:(U==null?void 0:U[12])||0,ty:(U==null?void 0:U[13])||0}}return ie=T.match(/translate\(\s*([-\d.]+)px\s*,\s*([-\d.]+)px\s*\)/),ie?{tx:Number(ie[1])||0,ty:Number(ie[2])||0}:{tx:0,ty:0}},O=(T,ie,U)=>{T.style.transform=`translate(${ie}px, ${U}px)`},j=T=>{const ie=k(T);if(!ie)return;s=!0,M=ie,h="move",c=T.clientX,d=T.clientY;const U=window.getComputedStyle(ie),{tx:ge,ty:ze}=W(U.transform);u=ge,C=ze,document.addEventListener("mousemove",_),document.addEventListener("mouseup",x)},L=(T,ie)=>{const U=k(T);if(!U)return;s=!0,M=U,h=ie,c=T.clientX,d=T.clientY;const ge=U.getBoundingClientRect();m=ge.width,b=ge.height;const ze=window.getComputedStyle(U),{tx:Le,ty:ra}=W(ze.transform);u=Le,C=ra,document.addEventListener("mousemove",_),document.addEventListener("mouseup",x)},_=T=>{if(!s||!M)return;const ie=T.clientX-c,U=T.clientY-d,ge=360,ze=420;let Le=m,ra=b,Ca=u,Q=C;if(h==="move"){Ca=u+ie,Q=C+U,O(M,Ca,Q);return}if(h.includes("right")&&(Le=Math.max(ge,m+ie)),h.includes("bottom")&&(ra=Math.max(ze,b+U)),h.includes("left")){const ca=m-ie;ca<ge?(Le=ge,Ca=u+(m-ge)):(Le=ca,Ca=u+ie)}if(h.includes("top")){const ca=b-U;ca<ze?(ra=ze,Q=C+(b-ze)):(ra=ca,Q=C+U)}M.style.width=`${Le}px`,M.style.height=`${ra}px`,O(M,Ca,Q)},x=()=>{s=!1,h="",M=null,document.removeEventListener("mousemove",_),document.removeEventListener("mouseup",x)},w=e.ref([]),g=e.ref(!1);e.watch(()=>n.images,async T=>{if(!Array.isArray(T)||T.length===0){w.value=[];return}g.value=!0;const ie=[];for(const U of T)if(U.url&&!U.url.startsWith("blob:")&&!U.url.startsWith("http"))try{const ge=await Al.downloadFile(U.url),ze=URL.createObjectURL(ge);ie.push({...U,blobUrl:ze})}catch(ge){console.error(`Failed to load image for preview: ${U.url}`,ge),ie.push({...U,blobUrl:""})}else ie.push({...U,blobUrl:U.url});w.value=ie,g.value=!1},{deep:!0,immediate:!0});const E=e.ref(0),P=e.ref(null),V=e.ref(null),ee=e.computed(()=>w.value[E.value]||null),J=()=>{if(!w.value.length){E.value=0;return}if(n.defaultImageName){const T=w.value.findIndex(ie=>(ie==null?void 0:ie.name)===n.defaultImageName);E.value=T>=0?T:0}else E.value=0},me=T=>{if(!w.value.length)return;const ie=Math.max(0,Math.min(T,w.value.length-1));E.value=ie},_e=()=>me(E.value-1),z=()=>me(E.value+1),ne=T=>{if(!T)return;const ie=w.value.findIndex(U=>(U==null?void 0:U.name)===T);ie>=0&&(E.value=ie)},Y=()=>{if(!V.value)return;const T=V.value.parentElement;if(!T)return;const ie=T.getBoundingClientRect();V.value.width=ie.width,V.value.height=ie.height},te=()=>{var ge,ze;if(!V.value||!P.value||!n.focusedFieldName){V.value&&Si(V.value);return}const T=(ge=P.value.$el)==null?void 0:ge.querySelector("img");if(!T)return;if(!T.complete||T.naturalWidth===0){T.onload=()=>{e.nextTick(()=>{te()})};return}const ie=((ze=ee.value)==null?void 0:ze.name)||"",U=cs(n.fieldMeta,n.focusedFieldName);if(!U){Si(V.value);return}if(U.imageName!==ie){Si(V.value);return}Y(),Uu(V.value,T,U.bboxNorm)},ye=()=>{e.nextTick(()=>{Y(),te()})};e.watch(()=>n.focusedFieldName,()=>{if(!i.value)return;const T=cs(n.fieldMeta,n.focusedFieldName);T!=null&&T.imageName&&ne(T.imageName),e.nextTick(()=>{te()})}),e.watch(()=>{var T;return(T=ee.value)==null?void 0:T.name},()=>{i.value&&e.nextTick(()=>{V.value&&Si(V.value),te()})}),e.watch(()=>n.visible,T=>{T?(J(),e.nextTick(()=>{Y(),te()})):V.value&&Si(V.value)}),e.watch(()=>n.defaultImageName,()=>{i.value&&J()});let $e=null;e.onMounted(()=>{var T;typeof ResizeObserver<"u"&&($e=new ResizeObserver(()=>{Y(),e.nextTick(()=>{te()})}),(T=V.value)!=null&&T.parentElement&&$e.observe(V.value.parentElement))}),e.onUnmounted(()=>{$e&&($e.disconnect(),$e=null),document.removeEventListener("mousemove",_),document.removeEventListener("mouseup",x)});const de=()=>{V.value&&Si(V.value),r("update:visible",!1),r("close")};return(T,ie)=>{var ra,Ca;const U=e.resolveComponent("el-button"),ge=e.resolveComponent("el-image"),ze=e.resolveComponent("Loading"),Le=e.resolveComponent("el-icon");return i.value?(e.openBlock(),e.createElementBlock("div",qu,[ie[12]||(ie[12]=e.createElementVNode("div",{class:"ocr-img-preview-backdrop"},null,-1)),e.createElementVNode("div",Wu,[e.createElementVNode("div",{class:"ocr-img-preview-header",onMousedown:e.withModifiers(j,["stop"])},[ie[8]||(ie[8]=e.createElementVNode("span",{class:"ocr-img-preview-title"},"文件预览",-1)),e.createElementVNode("button",{type:"button",class:"ocr-img-preview-close",onClick:de},"×")],32),e.createElementVNode("div",{class:"resizable-handle top",onMousedown:ie[0]||(ie[0]=e.withModifiers(Q=>L(Q,"top"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle right",onMousedown:ie[1]||(ie[1]=e.withModifiers(Q=>L(Q,"right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom",onMousedown:ie[2]||(ie[2]=e.withModifiers(Q=>L(Q,"bottom"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle left",onMousedown:ie[3]||(ie[3]=e.withModifiers(Q=>L(Q,"left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-left",onMousedown:ie[4]||(ie[4]=e.withModifiers(Q=>L(Q,"top-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-right",onMousedown:ie[5]||(ie[5]=e.withModifiers(Q=>L(Q,"top-right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-left",onMousedown:ie[6]||(ie[6]=e.withModifiers(Q=>L(Q,"bottom-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-right",onMousedown:ie[7]||(ie[7]=e.withModifiers(Q=>L(Q,"bottom-right"),["stop"]))},null,32),ee.value?(e.openBlock(),e.createElementBlock("div",Ku,[e.createElementVNode("div",Gu,[e.createElementVNode("div",Yu,[e.createElementVNode("span",Ju,e.toDisplayString(ee.value.name?ee.value.name+(ee.value.url&&ee.value.url.lastIndexOf(".")!==-1?ee.value.url.substring(ee.value.url.lastIndexOf(".")):""):""),1)]),w.value.length>1?(e.openBlock(),e.createElementBlock("div",Xu,[e.createVNode(U,{size:"small",disabled:E.value===0,onClick:_e},{default:e.withCtx(()=>ie[9]||(ie[9]=[e.createTextVNode("上一张")])),_:1,__:[9]},8,["disabled"]),e.createElementVNode("span",Zu,e.toDisplayString(E.value+1)+" / "+e.toDisplayString(w.value.length),1),e.createVNode(U,{size:"small",disabled:E.value===w.value.length-1,onClick:z},{default:e.withCtx(()=>ie[10]||(ie[10]=[e.createTextVNode("下一张")])),_:1,__:[10]},8,["disabled"])])):e.createCommentVNode("",!0)]),w.value.length>1?(e.openBlock(),e.createElementBlock("div",Qu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(Q,ca)=>(e.openBlock(),e.createElementBlock("div",{key:(Q.name||"")+"-"+ca,class:e.normalizeClass(["img-thumb-item",{active:ca===E.value}]),onClick:ue=>me(ca)},[Q!=null&&Q.blobUrl?(e.openBlock(),e.createBlock(ge,{key:0,src:Q.blobUrl,fit:"cover",class:"thumb-image","preview-src-list":[Q.blobUrl],"initial-index":0},null,8,["src","preview-src-list"])):(e.openBlock(),e.createElementBlock("div",ad,"加载失败")),e.createElementVNode("div",ld,e.toDisplayString(Q.name||"-"),1)],10,ed))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",rd,[g.value?(e.openBlock(),e.createElementBlock("div",nd,[e.createVNode(Le,{class:"is-loading"},{default:e.withCtx(()=>[e.createVNode(ze)]),_:1}),ie[11]||(ie[11]=e.createElementVNode("span",null,"图片加载中...",-1))])):(ra=ee.value)!=null&&ra.blobUrl?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(ge,{ref_key:"imageRef",ref:P,src:ee.value.blobUrl,fit:"contain",class:"preview-image","preview-src-list":[ee.value.blobUrl],onLoad:ye},null,8,["src","preview-src-list"]),e.createElementVNode("canvas",{ref_key:"canvasRef",ref:V,class:"highlight-canvas"},null,512)],64)):(e.openBlock(),e.createElementBlock("div",id,[(Ca=ee.value)!=null&&Ca.url?(e.openBlock(),e.createElementBlock("span",od,"图片加载失败")):(e.openBlock(),e.createElementBlock("span",td,"暂无图片"))]))])])):(e.openBlock(),e.createElementBlock("div",sd,"暂无图片"))])])):e.createCommentVNode("",!0)}}}),ud=ar._export_sfc(cd,[["__scopeId","data-v-48a4ecb1"]]),dd={class:"cert-preview-body"},pd={key:0,class:"pdf-preview-container"},fd={class:"thumbs"},hd=["onClick"],vd={class:"thumb-img"},md=["src"],yd={key:1,class:"thumb-loading"},gd={class:"thumb-title"},bd={class:"viewer"},kd={key:0,class:"viewer-img-wrap"},xd=["src"],wd={key:1,class:"viewer-loading"},_d=e.defineComponent({__name:"CertificatePreview",props:{visible:{type:Boolean},versions:{}},emits:["update:visible"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(""),s=e.ref(""),h=e.computed(()=>(n.versions||[]).find(k=>String(k.versionId)===String(i.value))),c=e.ref({}),d=e.ref(""),m=e.ref("证书附件.pdf"),b=()=>{try{Object.values(c.value||{}).forEach(k=>{k&&URL.revokeObjectURL(k)}),d.value&&URL.revokeObjectURL(d.value)}catch{}c.value={},d.value=""},u=async k=>{if(!k||k.fileType==="pdf")return;const W=Array.isArray(k.images)?k.images:[];for(const O of W){const j=O==null?void 0:O.url;if(!(!j||c.value[j]))try{const L=await A.platformDownloadFile({url:j}),_=URL.createObjectURL(L.data);c.value={...c.value,[j]:_}}catch{}}},C=async k=>{var O;if(!k||k.fileType!=="pdf"){d.value="";return}const W=k.sourceUrl||"";if(!W){d.value="";return}if(d.value){try{URL.revokeObjectURL(d.value)}catch{}d.value=""}try{console.log("[CertificatePreview] 下载PDF附件:",{url:W,versionId:k==null?void 0:k.versionId,certNo:k==null?void 0:k.certNo});const j=await A.platformDownloadFile({url:W});console.log("[CertificatePreview] PDF响应:",{url:W,status:j==null?void 0:j.status,size:(O=j==null?void 0:j.data)==null?void 0:O.size});const L=URL.createObjectURL(j.data);d.value=L;const _=k.certNo?String(k.certNo):"";m.value=_?`${_}.pdf`:"证书附件.pdf"}catch(j){console.error("[CertificatePreview] PDF加载失败:",{url:W,error:j}),d.value=""}};e.watch(()=>n.visible,async k=>{var O;if(!k){b();return}const W=(O=n.versions)==null?void 0:O[0];i.value=(W==null?void 0:W.versionId)||"",await u(W),await C(W)},{immediate:!0}),e.watch(()=>i.value,async()=>{var W,O;const k=h.value;if(!k){s.value="",d.value="";return}if(k.fileType==="pdf"){s.value="",await C(k);return}d.value="",s.value=((O=(W=k.images)==null?void 0:W[0])==null?void 0:O.url)||"",await u(k)},{immediate:!0});const M=()=>{r("update:visible",!1),b()};return e.onBeforeUnmount(()=>{b()}),(k,W)=>{const O=e.resolveComponent("el-empty"),j=e.resolveComponent("el-tab-pane"),L=e.resolveComponent("el-tabs"),_=e.resolveComponent("el-button"),x=e.resolveComponent("el-dialog");return e.openBlock(),e.createBlock(x,{"model-value":k.visible,title:"证书附件预览",width:"1100px","close-on-click-modal":!1,onClose:M},{footer:e.withCtx(()=>[e.createVNode(_,{id:"themeBorderButton",onClick:M},{default:e.withCtx(()=>W[1]||(W[1]=[e.createTextVNode("关闭")])),_:1,__:[1]})]),default:e.withCtx(()=>[k.versions&&k.versions.length>0?(e.openBlock(),e.createBlock(L,{key:0,modelValue:i.value,"onUpdate:modelValue":W[0]||(W[0]=w=>i.value=w),type:"card",class:"cert-version-tabs"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.versions,w=>(e.openBlock(),e.createBlock(j,{key:w.versionId,name:w.versionId,label:w.label},{default:e.withCtx(()=>[e.createElementVNode("div",dd,[w.fileType==="pdf"?(e.openBlock(),e.createElementBlock("div",pd,[d.value?(e.openBlock(),e.createBlock(cl.SsFilePreview,{key:1,fileName:m.value,blobUrl:d.value},null,8,["fileName","blobUrl"])):(e.openBlock(),e.createBlock(O,{key:0,description:"加载中"}))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",fd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.images||[],g=>(e.openBlock(),e.createElementBlock("div",{key:g.url,class:e.normalizeClass(["thumb",{active:g.url===s.value}]),onClick:E=>s.value=g.url},[e.createElementVNode("div",vd,[c.value[g.url]?(e.openBlock(),e.createElementBlock("img",{key:0,src:c.value[g.url]},null,8,md)):(e.openBlock(),e.createElementBlock("div",yd,"加载中"))]),e.createElementVNode("div",gd,e.toDisplayString(g.name),1)],10,hd))),128))]),e.createElementVNode("div",bd,[s.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[c.value[s.value]?(e.openBlock(),e.createElementBlock("div",kd,[e.createElementVNode("img",{class:"viewer-img",src:c.value[s.value]},null,8,xd)])):(e.openBlock(),e.createElementBlock("div",wd,"加载中"))],64)):(e.openBlock(),e.createBlock(O,{key:0,description:"暂无图片"}))])],64))])]),_:2},1032,["name","label"]))),128))]),_:1},8,["modelValue"])):(e.openBlock(),e.createBlock(O,{key:1,description:"暂无可预览的证书附件"}))]),_:1},8,["model-value"])}}}),Sd=ar._export_sfc(_d,[["__scopeId","data-v-220703c0"]]),Ed={class:"ocr-candidate-wrap"},Cd={class:"ocr-candidate-left"},Dd={key:1},Td={key:0},Bd={key:1},Nd={key:2},Ad={key:3},zd={key:0,class:"ocr-candidate-right"},Md={class:"ocr-candidate-actions"},Id={key:1},Od={class:"dialog-footer"},Ld={__name:"OCRCandidateDialog",props:{visible:{type:Boolean,default:!1},candidates:{type:Array,default:()=>[]},columns:{type:Array,default:()=>[]},nameProp:{type:String,default:""},mfrProp:{type:String,default:""}},emits:["update:visible","submit","preview-file"],setup(a,{emit:l}){const n=(E=[])=>{const P=[],V=ee=>{(ee||[]).forEach(J=>{if(!J)return;const me=J.children||J.childrens||J.columns;Array.isArray(me)&&me.length>0?V(me):P.push(J)})};return V(E),P},r=a,i=l,s=e.computed(()=>{var E;return((E=C.value)==null?void 0:E.allowAdd)!==!1}),h=e.computed(()=>{var E;return((E=C.value)==null?void 0:E.allowReplace)!==!1}),c=E=>{if(!E)return[];if(Array.isArray(E))return E;if(typeof E=="string")try{const P=JSON.parse(E);return Array.isArray(P)?P:[]}catch{return[]}return[]},d=E=>{i("preview-file",E)},m=e.ref([]),b=e.ref(0),u=e.ref("");e.watch(()=>r.candidates,E=>{var P,V;m.value=(E||[]).map(ee=>({...ee,...(ee==null?void 0:ee.ocrRow)||{},selectedTargetId:(ee==null?void 0:ee.selectedTargetId)||"",__decision:ee==null?void 0:ee.__decision})),b.value=0,u.value=((V=(P=m.value)==null?void 0:P[0])==null?void 0:V.selectedTargetId)||""},{immediate:!0,deep:!0}),e.watch(()=>r.visible,E=>{var P,V;E&&(b.value=0,u.value=((V=(P=m.value)==null?void 0:P[0])==null?void 0:V.selectedTargetId)||"")});const C=e.computed(()=>{var P;const E=Number(b.value||0);return((P=m.value||[])==null?void 0:P[E])||null}),M=e.computed(()=>(n(r.columns||[])||[]).filter(V=>V&&V.prop).filter(V=>V.type!=="operate"&&V.label!=="操作"&&V.prop!=="operate")),k=e.computed(()=>M.value.filter(E=>E.label!=="证书附件"&&E.prop!=="证书附件")),W=E=>{if(!E)return;const P=(m.value||[]).findIndex(V=>(V==null?void 0:V.idx)===(E==null?void 0:E.idx));P>-1&&(b.value=P,u.value=(E==null?void 0:E.selectedTargetId)||"")},O=E=>{if(!E){u.value="";return}u.value=String((E==null?void 0:E.id)??"")},j=(E,P="")=>{const V=Number(b.value||0),ee=m.value||[],J=ee[V];J&&(J.__decision=E,J.selectedTargetId=P,u.value=P,m.value=[...ee])},L=()=>j("skip",""),_=()=>j("add",""),x=()=>{if(!u.value){Wa.ElMessage.warning("请先选择要替换的目标记录");return}j("replace",u.value)},w=()=>{i("update:visible",!1)},g=()=>{const E=m.value||[];if(E.find(V=>(V==null?void 0:V.__decision)==="replace"&&!(V!=null&&V.selectedTargetId))){Wa.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}i("submit",E),i("update:visible",!1)};return(E,P)=>{const V=e.resolveComponent("el-table-column"),ee=e.resolveComponent("svg-icon"),J=e.resolveComponent("el-table"),me=e.resolveComponent("el-button"),_e=e.resolveComponent("el-alert");return e.openBlock(),e.createBlock(Ar.ssDialog,{title:"OCR候选匹配",visible:a.visible,"close-on-click-modal":!1,width:"90%",style:{maxWidth:"1200px"},onBeforeDestroy:w},{default:e.withCtx(()=>{var z,ne;return[e.createElementVNode("div",Ed,[e.createElementVNode("div",Cd,[P[0]||(P[0]=e.createElementVNode("div",{class:"ocr-candidate-title"},"待处理OCR行(可跳过)",-1)),e.createVNode(J,{data:m.value,border:"",stripe:"","max-height":"300",style:{width:"100%"},"highlight-current-row":"",onCurrentChange:W},{default:e.withCtx(()=>[e.createVNode(V,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,Y=>(e.openBlock(),e.createBlock(V,{key:Y.prop,label:Y.label,prop:Y.prop,"min-width":Y.minWidth||160},{default:e.withCtx(({row:te})=>[Y.label==="证书附件"||Y.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(te==null?void 0:te[Y.prop]).length>0?(e.openBlock(),e.createBlock(ee,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(ye=>d({row:te,prop:Y.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Dd,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((te==null?void 0:te[Y.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128)),e.createVNode(V,{label:"候选数",width:"90",fixed:"right"},{default:e.withCtx(({row:Y})=>[e.createTextVNode(e.toDisplayString(((Y==null?void 0:Y.candidates)||[]).length),1)]),_:1}),e.createVNode(V,{label:"处理状态",width:"120",fixed:"right"},{default:e.withCtx(({row:Y})=>[(Y==null?void 0:Y.__decision)==="replace"?(e.openBlock(),e.createElementBlock("span",Td,"替换")):(Y==null?void 0:Y.__decision)==="add"?(e.openBlock(),e.createElementBlock("span",Bd,"新增")):(Y==null?void 0:Y.__decision)==="skip"?(e.openBlock(),e.createElementBlock("span",Nd,"跳过")):(e.openBlock(),e.createElementBlock("span",Ad,"未处理"))]),_:1})]),_:1},8,["data"])]),m.value&&m.value.length>0?(e.openBlock(),e.createElementBlock("div",zd,[P[4]||(P[4]=e.createElementVNode("div",{class:"ocr-candidate-title"},"当前行候选记录(同编号)",-1)),e.createElementVNode("div",Md,[e.createVNode(me,{id:"themeBorderButton",onClick:L},{default:e.withCtx(()=>P[1]||(P[1]=[e.createTextVNode("跳过本行")])),_:1,__:[1]}),e.createVNode(me,{id:"themeBorderButton",onClick:_,disabled:!s.value},{default:e.withCtx(()=>P[2]||(P[2]=[e.createTextVNode("新增本行")])),_:1,__:[2]},8,["disabled"]),e.createVNode(me,{class:"ok-button",id:"themeButton",onClick:x,disabled:!h.value||!u.value},{default:e.withCtx(()=>P[3]||(P[3]=[e.createTextVNode("替换选中记录")])),_:1,__:[3]},8,["disabled"])]),(((z=C.value)==null?void 0:z.candidates)||[]).length===0?(e.openBlock(),e.createBlock(_e,{key:0,title:"该编号暂无候选记录,可选择“新增本行”或“跳过本行”。",type:"info",closable:!1,"show-icon":"",style:{margin:"8px 0"}})):e.createCommentVNode("",!0),e.createVNode(J,{data:((ne=C.value)==null?void 0:ne.candidates)||[],border:"",stripe:"","max-height":"300",style:{width:"100%"},onCurrentChange:O,"highlight-current-row":""},{default:e.withCtx(()=>[e.createVNode(V,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(M.value,Y=>(e.openBlock(),e.createBlock(V,{key:Y.prop,label:Y.label,prop:Y.prop,"min-width":Y.minWidth||160},{default:e.withCtx(({row:te})=>[Y.label==="证书附件"||Y.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(te==null?void 0:te[Y.prop]).length>0?(e.openBlock(),e.createBlock(ee,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(ye=>d({row:te,prop:Y.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Id,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((te==null?void 0:te[Y.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128))]),_:1},8,["data"])])):e.createCommentVNode("",!0)])]}),footer:e.withCtx(()=>[e.createElementVNode("div",Od,[e.createVNode(me,{id:"themeBorderButton",onClick:w},{default:e.withCtx(()=>P[5]||(P[5]=[e.createTextVNode("取消")])),_:1,__:[5]}),e.createVNode(me,{class:"ok-button",id:"themeButton",onClick:g},{default:e.withCtx(()=>P[6]||(P[6]=[e.createTextVNode("提交已处理")])),_:1,__:[6]})])]),_:1},8,["visible"])}}},Rd=ar._export_sfc(Ld,[["__scopeId","data-v-89e0489c"]]),$d={class:"ocr-preview-content"},Vd={class:"ocr-preview-tip"},Pd={class:"ocr-preview-table"},Fd={style:{display:"flex","align-items":"center",gap:"8px"}},jd={class:"dialog-footer"},Hd={__name:"OCRResultPreviewDialog",props:{visible:{type:Boolean,default:!1},ocrPreviewData:{type:Array,default:()=>[]},ocrPreviewColumns:{type:Array,default:()=>[]},ocrSelectedFields:{type:Array,default:()=>[]}},emits:["update:visible","update:ocrPreviewData","update:ocrSelectedFields","confirm","fieldChange"],setup(a,{emit:l}){const n=a,r=l,i=e.ref([]),s=e.ref([]),h=e.ref([]);e.watch(()=>n.visible,M=>{M&&(i.value=JSON.parse(JSON.stringify(n.ocrPreviewData)),s.value=JSON.parse(JSON.stringify(n.ocrPreviewColumns)),h.value=[...n.ocrSelectedFields])});const c=(M,k)=>{const W=[...h.value];if(k)W.includes(M)||W.push(M);else{const O=W.indexOf(M);O>-1&&W.splice(O,1)}h.value=W,r("update:ocrSelectedFields",W)},d=(M,k,W)=>{r("fieldChange",{rowIndex:M,prop:k,value:W})},m=()=>{r("update:ocrPreviewData",i.value),r("confirm",i.value),r("update:visible",!1)},b=()=>{r("update:visible",!1)},u=M=>typeof M!="number"?"-":`${(M*100).toFixed(1)}%`,C=M=>typeof M!="number"?"#606266":M>=.9?"#67c23a":M>=.7?"#e6a23c":"#f56c6c";return(M,k)=>{const W=e.resolveComponent("el-alert"),O=e.resolveComponent("el-table-column"),j=e.resolveComponent("el-checkbox"),L=e.resolveComponent("el-input"),_=e.resolveComponent("el-table"),x=e.resolveComponent("el-button");return e.openBlock(),e.createBlock(Ar.ssDialog,{title:"OCR识别结果预览",visible:a.visible,onBeforeDestroy:b,width:"90%",style:{maxWidth:"1200px"}},{default:e.withCtx(()=>[e.createElementVNode("div",$d,[e.createElementVNode("div",Vd,[e.createVNode(W,{title:"请核对识别结果。系统将按 编号+名称+制造厂 规则匹配并替换;未唯一命中但有编号的,将进入候选选择;无编号则直接新增。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",Pd,[e.createVNode(_,{data:i.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(O,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,w=>(e.openBlock(),e.createBlock(O,{key:w.prop,prop:w.prop,"min-width":w.minWidth||230,"class-name":w.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",Fd,[w.isAccuracy?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(j,{key:0,"model-value":h.value.includes(w.prop),onChange:g=>c(w.prop,g),onClick:k[0]||(k[0]=e.withModifiers(()=>{},["stop"]))},null,8,["model-value","onChange"])),e.createElementVNode("span",null,e.toDisplayString(w.label),1)])]),default:e.withCtx(({row:g,$index:E})=>[w.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:C(g[w.prop]),fontWeight:500})},e.toDisplayString(u(g[w.prop])),5)):(e.openBlock(),e.createBlock(L,{key:1,modelValue:g[w.prop],"onUpdate:modelValue":P=>g[w.prop]=P,size:"small",placeholder:"请输入"+w.label,onChange:P=>d(E,w.prop,P)},null,8,["modelValue","onUpdate:modelValue","placeholder","onChange"]))]),_:2},1032,["prop","min-width","class-name"]))),128))]),_:1},8,["data"])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",jd,[e.createVNode(x,{onClick:b,id:"themeBorderButton"},{default:e.withCtx(()=>k[1]||(k[1]=[e.createTextVNode("取消")])),_:1,__:[1]}),e.createVNode(x,{class:"ok-button",onClick:m,id:"themeButton"},{default:e.withCtx(()=>k[2]||(k[2]=[e.createTextVNode("确认")])),_:1,__:[2]})])]),_:1},8,["visible"])}}},Ud=ar._export_sfc(Hd,[["__scopeId","data-v-df66eb1f"]]),ci=a=>{var r;let l=a;(l==null?void 0:l[0])==="("&&(l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1));let n=(r=oe.analyzeSplitToContent(l,","))==null?void 0:r.map(i=>((i==null?void 0:i[(i==null?void 0:i.length)-1])===","&&(i=i==null?void 0:i.slice(0,(i==null?void 0:i.length)-1)),gn(i)));return n=n==null?void 0:n.join(","),n};function rc(a){return Wa.axios.post("http://222.92.178.198:8000/api/v1/excel-chat",a)}function qd(a){return Wa.axios.get(a,{responseType:"blob"})}let Xl="$R",Wd="http://222.92.178.198:55002/AIRobot",ft=["Form","BarChart","FormText","FormBlock"];const nc=a=>{var n,r;let l=(r=oe.analyzeSplitToContent(a,"@"))==null?void 0:r[((n=oe.analyzeSplitToContent(a,"@"))==null?void 0:n.length)-1];return!!(ft!=null&&ft.some(i=>l==null?void 0:l.includes(i)))},Kd=async(a,l,n,r)=>{var s,h,c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca;let i=a;if(nc(i==null?void 0:i[0])){let ue=ep(i),pa=(s=ue==null?void 0:ue.filter)==null?void 0:s.join(","),Se=[];(h=ue==null?void 0:ue.hideContents)==null||h.forEach(Ke=>{if(Ke){const ua=Ke;ua&&Se.push(`(HideGroup=Yes, prop=${ua})`)}});let ce=(c=ue==null?void 0:ue.formContents)==null?void 0:c.filter(Ke=>{var ua;return(ua=Ke==null?void 0:Ke.filters)==null?void 0:ua.includes("@ShowHide=Hide")});(ce==null?void 0:ce.length)>0&&(ce==null||ce.forEach(Ke=>{if(Ke){const ua=Ke==null?void 0:Ke.prop;ua&&Se.push(`(Hide=Yes, prop=${ua})`)}}));let De=(r==null?void 0:r.menuFilter)??[];return Array.isArray(De)||(De=De?[De]:[]),De=[...De,...Se],{key:"Form",name:ue==null?void 0:ue.groupName,value:ue==null?void 0:ue.formContents,contents:Array.isArray((d=ue==null?void 0:ue.contents)==null?void 0:d[0])&&((b=(m=ue==null?void 0:ue.contents)==null?void 0:m[0])!=null&&b.every(Ke=>Array.isArray(Ke)))?[(C=(u=ue==null?void 0:ue.contents)==null?void 0:u[0])==null?void 0:C[n]]:[ue==null?void 0:ue.contents],filter:"("+pa+")",menuFilter:De,groupFilter:ue==null?void 0:ue.groupFilters}}else if(((M=i==null?void 0:i[0])==null?void 0:M[0])!=="&"){let ue=tc(i,r),pa="";(k=ue==null?void 0:ue.tableFilter)!=null&&k.includes(Xl)?ue.tableFilter=(W=ue==null?void 0:ue.tableFilter)==null?void 0:W.replace(Xl,""):pa=(L=(j=(O=ue==null?void 0:ue.tableFilter)==null?void 0:O.replace("(",Xl))==null?void 0:j.split(Xl))==null?void 0:L[0];let Se=[];ue!=null&&ue.tableFilter&&((_=oe.analyzeSplitToContent(ue==null?void 0:ue.tableFilter,","))==null||_.forEach(De=>{De!=null&&De.includes("@ShowHide=Hide")&&Se.push("HideGroup=Yes")}));let ce=(r==null?void 0:r.menuFilter)??[];return Array.isArray(ce)||(ce=ce?[ce]:[]),ce=[...ce,...Se],{key:"Table",name:ue==null?void 0:ue.groupName,tableColumns:ue==null?void 0:ue.tableColumns,assistColumn:ue==null?void 0:ue.columns,tableContents:l===1?ue==null?void 0:ue.tableContents:(w=(x=ue==null?void 0:ue.tableContents)==null?void 0:x[n])!=null&&w.every(De=>Array.isArray(De))?(g=ue==null?void 0:ue.tableContents)==null?void 0:g[n]:[(E=ue==null?void 0:ue.tableContents)==null?void 0:E[n]],filter:ue==null?void 0:ue.tableFilter,menuFilter:ce,quotePage:pa!==""?((ee=(V=(P=pa==null?void 0:pa.replace("*",Xl))==null?void 0:P.split(Xl))==null?void 0:V[0])==null?void 0:ee.replaceAll(":","/"))??"":void 0,quoteGroup:pa!==""?((te=(Y=(ne=(z=(_e=(me=(J=pa==null?void 0:pa.replace("*",Xl))==null?void 0:J.split(Xl))==null?void 0:me[1])==null?void 0:_e.replace("{",Xl))==null?void 0:z.split(Xl))==null?void 0:ne[0])==null?void 0:Y.split(":"))==null?void 0:te.filter(De=>De!==""))??[]:[],relatedQuotes:ue==null?void 0:ue.relatedQuotes,fatherSyncContents:ue==null?void 0:ue.fatherSyncContents,sonSyncContents:ue==null?void 0:ue.sonSyncContents}}else{let ue=[{label:"序号",prop:"sort"},{label:"函数名称",prop:"函数名称"},{label:"函数关联名",prop:"函数关联名"},{label:"函数参数",prop:"函数参数"},{label:"输出值",prop:"输出值"},{label:"导入文件",prop:"导入文件",formType:"Upload"}],pa=i==null?void 0:i[0];pa=pa==null?void 0:pa.slice(1,pa==null?void 0:pa.length),pa=oe.analyzeSplitToContent(pa,":"),pa=pa==null?void 0:pa[(pa==null?void 0:pa.length)-1];let Se=[];Se.push("1");let ce=pa==null?void 0:pa.replace("(",Xl);ce=(ye=ce==null?void 0:ce.split(Xl))==null?void 0:ye[0],Se.push(ce);let De=pa==null?void 0:pa.replace("(",Xl);if(De=($e=De==null?void 0:De.split(Xl))==null?void 0:$e[1],De=(T=(de=De==null?void 0:De.replace(")",Xl))==null?void 0:de.split(Xl))==null?void 0:T[0],(U=(ie=De==null?void 0:De.replace(",",Xl))==null?void 0:ie.split(Xl))==null||U.forEach(Ke=>{Se.push(Ke)}),Se.push(""),Se.push(""),(ge=Se==null?void 0:Se[2])!=null&&ge.includes(".xlsx")||(ze=Se==null?void 0:Se[2])!=null&&ze.includes(".xls"))try{let Ke=Wd+"/"+(Se==null?void 0:Se[2]),ua=await qd(Ke),Za=`生成js函数名称为${Se==null?void 0:Se[1]}的函数,规则为:`+(Se==null?void 0:Se[3])+"。根据上述描述获取对应的总结性详细可运行js函数,不需要任何注释。";if((ua==null?void 0:ua.status)===200){let $=ua==null?void 0:ua.data;const H=new FormData;H.append("file",$,Se==null?void 0:Se[2]),H.append("query",Za);let X=await rc(H);X=(Ca=(ra=(Le=X==null?void 0:X.data)==null?void 0:Le.data)==null?void 0:ra.response)==null?void 0:Ca.replace("generateResult",Se==null?void 0:Se[1]),Se[Se.length-2]=X,Se[Se.length-1]=[{name:(ca=(Q=Se==null?void 0:Se[2])==null?void 0:Q.split("."))==null?void 0:ca[0],url:Ke}]}}catch{}return Se=[Se],{key:"Method",name:[],tableContents:Se,tableColumns:ue}}},Gd=(a,l)=>{var r,i,s,h,c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se;let n=(i=(r=oe.analyzeSplitToContent(a,"="))==null?void 0:r.filter(ce=>ce!=="="))==null?void 0:i.map(ce=>((ce==null?void 0:ce[(ce==null?void 0:ce.length)-1])==="="&&(ce=ce==null?void 0:ce.slice(0,(ce==null?void 0:ce.length)-1)),ce));if(nc(n==null?void 0:n[1])){let ce=Qd(n),De=(c=(h=(s=ce==null?void 0:ce.filter)==null?void 0:s.replace("@",Xl))==null?void 0:h.split(Xl))==null?void 0:c[0],Ke=(b=(m=(d=ce==null?void 0:ce.filter)==null?void 0:d.replace("(",Xl))==null?void 0:m.split(Xl))==null?void 0:b[1],ua=(M=(C=(u=ce==null?void 0:ce.filter)==null?void 0:u.replace("(",Xl))==null?void 0:C.split(Xl))==null?void 0:M[0];ua="@"+((k=ua==null?void 0:ua.split("@"))==null?void 0:k[1]),Ke=Ke==null?void 0:Ke.slice(0,(Ke==null?void 0:Ke.length)-1),Ke=(O=(W=oe.analyzeSplitToContent(Ke,","))==null?void 0:W.map($=>($=ua+$,$)))==null?void 0:O.join("");let Za=De+"("+Ke+")";return{key:"Form",name:ce==null?void 0:ce.group,filter:Za,formPage:((_=(L=(j=De==null?void 0:De.replace("*",Xl))==null?void 0:j.split(Xl))==null?void 0:L[0])==null?void 0:_.replaceAll(":","/"))??"",formGroup:((ee=(V=(P=(E=(g=(w=(x=De==null?void 0:De.replace("*",Xl))==null?void 0:x.split(Xl))==null?void 0:w[1])==null?void 0:g.replace("{",Xl))==null?void 0:E.split(Xl))==null?void 0:P[0])==null?void 0:V.split(":"))==null?void 0:ee.filter($=>$!==""))??[],value:[],menuFilter:l==null?void 0:l.menuFilter}}else{let ce=tc(n,l,n==null?void 0:n[1]),De="";(J=ce==null?void 0:ce.tableFilter)!=null&&J.includes(Xl)?ce.tableFilter=(me=ce==null?void 0:ce.tableFilter)==null?void 0:me.replace(Xl,""):De=(ne=(z=(_e=ce==null?void 0:ce.tableFilter)==null?void 0:_e.replace("(",Xl))==null?void 0:z.split(Xl))==null?void 0:ne[0];let Ke=(ye=(te=(Y=ce==null?void 0:ce.tableFilter)==null?void 0:Y.replace("(",Xl))==null?void 0:te.split(Xl))==null?void 0:ye[0];Ke=[{menus:(de=($e=Ke==null?void 0:Ke.split("*"))==null?void 0:$e[0])==null?void 0:de.replaceAll(":","/"),groups:((ie=(T=Ke==null?void 0:Ke.split("*"))==null?void 0:T[1])==null?void 0:ie.split(":"))??[]}];let ua=(ze=(ge=(U=ce==null?void 0:ce.tableFilter)==null?void 0:U.replace("(",Xl))==null?void 0:ge.split(Xl))==null?void 0:ze[1];(ua==null?void 0:ua[(ua==null?void 0:ua.length)-1])===")"&&(ua=ua==null?void 0:ua.slice(0,(ua==null?void 0:ua.length)-1));let Za=[];ce!=null&&ce.tableFilter&&((Le=oe.analyzeSplitToContent(ce==null?void 0:ce.tableFilter,","))==null||Le.forEach(H=>{H!=null&&H.includes("@ShowHide=Hide")&&Za.push("HideGroup=Yes")}));let $=(l==null?void 0:l.menuFilter)??[];return Array.isArray($)||($=$?[$]:[]),$=[...$,...Za],{key:"Table",name:ce==null?void 0:ce.groupName,filter:ce==null?void 0:ce.tableFilter,tableColumns:ce==null?void 0:ce.tableColumns,quotePage:De!==""?((Q=(Ca=(ra=De==null?void 0:De.replace("*",Xl))==null?void 0:ra.split(Xl))==null?void 0:Ca[0])==null?void 0:Q.replaceAll(":","/"))??"":void 0,quoteGroup:De!==""?((Se=(pa=(ue=(ca=De==null?void 0:De.replace("*",Xl))==null?void 0:ca.split(Xl))==null?void 0:ue[1])==null?void 0:pa.split(":"))==null?void 0:Se.filter(H=>H!==""))??[]:[],menuFilter:$,relatedQuotes:Ke,fatherSyncContents:(ce==null?void 0:ce.fatherSyncContents)??[],sonSyncContents:(ce==null?void 0:ce.sonSyncContents)??[]}}},Yd=async(a,l)=>{let n=[],r=l==null?void 0:l.length;return l=l==null?void 0:l.map(async(i,s)=>{let h=[];i=i==null?void 0:i.map(async c=>{var d,m;if(h.push(c),((d=oe.analyzeSplitToContent(a,"="))==null?void 0:d.length)<=2){if(((m=oe.analyzeSplitToContent(a,"="))==null?void 0:m.length)!==0){const b=await Kd(oe.analyzeSplitToContent(a,"="),r,s,c);h.push(b)}}else h.push(Gd(a,c))}),await Promise.all(i),n.push(h)}),await Promise.all(l),n};let qi="/",Jd="$",Sn="$R";const ic=a=>{var n,r,i;let l="";if((a==null?void 0:a.length)>1){let s=a==null?void 0:a.filter((h,c)=>c!==0);s=s==null?void 0:s.join(""),s=oe.analyzerSplitToWord(s,")"),(s==null?void 0:s.length)!==1?(s==null?void 0:s[(s==null?void 0:s.length)-1])===")"?s=s==null?void 0:s.join(""):s=(n=s==null?void 0:s.filter((h,c)=>c!==(s==null?void 0:s.length)-1))==null?void 0:n.join(""):s=s==null?void 0:s[0],l="("+s,((i=a==null?void 0:a[0])==null?void 0:i[((r=a==null?void 0:a[0])==null?void 0:r.length)-2])==="@"&&(l="@"+l)}return{filter:l}},oc=(a,l=[])=>{let n=(a==null?void 0:a.map(s=>{var h,c;return(c=s==null?void 0:s.key)==null?void 0:c.slice(1,(h=s==null?void 0:s.key)==null?void 0:h.length)}))??[],r=[];n==null||n.forEach(s=>{var h,c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me;if(s===""&&(s="算法库:通用算法"),s!=null&&s.includes(Jd)){let _e="",z=!0,ne=oe.analyzerSplitToWord(s,"(");(ne==null?void 0:ne.length)>1&&(_e="("+((h=oe.analyzerSplitToWord(ne==null?void 0:ne[1],")"))==null?void 0:h[0]),((d=ne==null?void 0:ne[0])==null?void 0:d[((c=ne==null?void 0:ne[0])==null?void 0:c.length)-2])==="@"&&(_e="@"+_e));let Y=s;Y=Y==null?void 0:Y.replace(_e,""),_e=gn(_e),_e=(m=oe.analyzeSplitToContent(_e,","))==null?void 0:m.map(ie=>((ie==null?void 0:ie[(ie==null?void 0:ie.length)-1])===","&&(ie=ie==null?void 0:ie.slice(0,(ie==null?void 0:ie.length)-1)),ie)),_e!=null&&_e.includes("@ShowHide=Hide")&&(z=!1);let te=(b=Y==null?void 0:Y.replace("$",Sn))==null?void 0:b.split(Sn),ye=te==null?void 0:te[1],$e=te==null?void 0:te[0];$e!=null&&$e.includes("[")&&($e=(C=(u=$e==null?void 0:$e.replace("[",Sn))==null?void 0:u.split(Sn))==null?void 0:C[0],ye=ye+":["+((W=(k=(M=te==null?void 0:te[0])==null?void 0:M.replace("[",Sn))==null?void 0:k.split(Sn))==null?void 0:W[1])),$e=(j=(O=$e==null?void 0:$e.replaceAll(":","/"))==null?void 0:O.replaceAll("{",""))==null?void 0:j.replaceAll("}",""),($e==null?void 0:$e[($e==null?void 0:$e.length)-1])!=="/"&&($e=$e+"/"),ye=((L=$e==null?void 0:$e.split("/"))==null?void 0:L[0])+":"+ye;let T="";if(!(ye!=null&&ye.includes("[")))T=ye==null?void 0:ye.replaceAll(":","/"),r==null||r.push({path:T,isShow:z,filter:_e,fatherPath:$e});else{let ie=(x=(_=ye==null?void 0:ye.replace("[",Sn))==null?void 0:_.split(Sn))==null?void 0:x[1];ie=ie==null?void 0:ie.slice(0,(ie==null?void 0:ie.length)-1),ie=(w=oe.analyzeSplitToContent(ie,","))==null?void 0:w.map(U=>((U==null?void 0:U[(U==null?void 0:U.length)-1])===","&&(U=U==null?void 0:U.slice(0,(U==null?void 0:U.length)-1)),U)),ie==null||ie.forEach(U=>{var ge,ze;T=((ze=(ge=ye==null?void 0:ye.replace("[",Sn))==null?void 0:ge.split(Sn))==null?void 0:ze[0])+U,T=T==null?void 0:T.replaceAll(":","/"),r==null||r.push({path:T,isShow:z,filter:_e,fatherPath:$e})})}}else{let _e="",z=!0,ne=oe.analyzerSplitToWord(s,"(");(ne==null?void 0:ne.length)>1&&(_e=(g=ic(ne))==null?void 0:g.filter);let Y=s;if(Y=Y==null?void 0:Y.replace(_e,""),(_e==null?void 0:_e[0])==="("){_e=_e==null?void 0:_e.slice(1,(_e==null?void 0:_e.length)-1);let ye=[];(E=oe.analyzeSplitToContent(_e,","))==null||E.forEach($e=>{($e==null?void 0:$e[($e==null?void 0:$e.length)-1])===","&&($e=$e==null?void 0:$e.slice(0,($e==null?void 0:$e.length)-1)),($e==null?void 0:$e[0])==="("&&($e=$e==null?void 0:$e.slice(1,($e==null?void 0:$e.length)-1)),($e==null?void 0:$e[0])!=="@"&&($e="@"+$e),ye.push(gn($e))}),_e=ye==null?void 0:ye.join(",")}else _e=gn(_e);_e=(P=oe.analyzeSplitToContent(_e,","))==null?void 0:P.map(ye=>((ye==null?void 0:ye[(ye==null?void 0:ye.length)-1])===","&&(ye=ye==null?void 0:ye.slice(0,(ye==null?void 0:ye.length)-1)),ye)),_e!=null&&_e.includes("@ShowHide=Hide")&&(z=!1),(Y==null?void 0:Y[(Y==null?void 0:Y.length)-1])==="}"&&(Y=Y+":"),Y=(V=Y==null?void 0:Y.replaceAll("{",""))==null?void 0:V.replaceAll("}","");let te="";if(Y!=null&&Y.includes("[")){let ye=(ee=Y==null?void 0:Y.replace("[",Sn))==null?void 0:ee.split(Sn),$e=ye==null?void 0:ye[1];$e=$e==null?void 0:$e.slice(0,($e==null?void 0:$e.length)-1),(me=(J=oe.analyzeSplitToContent($e,","))==null?void 0:J.map(de=>((de==null?void 0:de[(de==null?void 0:de.length)-1])===","&&(de=de==null?void 0:de.slice(0,(de==null?void 0:de.length)-1)),de)))==null||me.forEach(de=>{te=(ye==null?void 0:ye[0])+de,te=te==null?void 0:te.replaceAll(":","/"),r==null||r.push({path:te,isShow:z,filter:_e})})}else te=Y==null?void 0:Y.replaceAll(":","/"),r==null||r.push({path:te,isShow:z,filter:_e})}});let i=A.cloneDeep(r);return(l==null?void 0:l.length)>0&&(i=l),i=i==null?void 0:i.filter(s=>{var h,c,d,m;return!(s!=null&&s.fatherPath)&&((c=(h=s==null?void 0:s.path)==null?void 0:h.split(qi))==null?void 0:c.length)>1&&((m=(d=s==null?void 0:s.path)==null?void 0:d.split(qi))==null?void 0:m[1])===""}),i=i==null?void 0:i.map(s=>{var h;return s.path=(h=s.path)==null?void 0:h.replace(qi,""),s.path}),(i==null?void 0:i.length)>0&&(r=r==null?void 0:r.map(s=>{var c,d,m,b,u,C,M;let h=i==null?void 0:i.find(k=>{var W;return(W=s==null?void 0:s.path)==null?void 0:W.includes(k)});return!(s!=null&&s.fatherPath)&&h&&!((c=s==null?void 0:s.path)!=null&&c.includes(qi))&&!(i!=null&&i.find(k=>(s==null?void 0:s.path)===k))&&(s.path=h+qi+((M=(m=(d=s==null?void 0:s.path)==null?void 0:d.split(h))==null?void 0:m[1])==null?void 0:M.slice(1,(C=(u=(b=s==null?void 0:s.path)==null?void 0:b.split(h))==null?void 0:u[1])==null?void 0:C.length))),s})),r},Xd=(a,l)=>oc([{key:a}],l),Zd=async(a,l)=>{const n=[],r=Xd(a==null?void 0:a.key,l);return r&&(r==null?void 0:r.length)>0&&(r==null||r.forEach(s=>{n.push([{key:"path",value:s==null?void 0:s.path,parentPath:(s==null?void 0:s.parentPath)??"",isShow:s==null?void 0:s.isShow,menuFilter:s==null?void 0:s.filter}])})),await Yd(a==null?void 0:a.value,n)};let yl="$R",Ki="[Any]";const Qd=a=>{var h,c;let l={},r=a==null?void 0:a[0];(r==null?void 0:r[0])==="*"&&(r=r==null?void 0:r.slice(1,r==null?void 0:r.length)),r=r==null?void 0:r.split(":"),l.group=r;let i=a==null?void 0:a[1],s;return i!=null&&i.includes("{")?s=(c=(h=i==null?void 0:i.replaceAll("{",""))==null?void 0:h.replaceAll("}",""))==null?void 0:c.replaceAll(Ki,""):s=i==null?void 0:i.replaceAll(Ki,""),(s==null?void 0:s[0])==="$"&&(s=s==null?void 0:s.slice(1,s==null?void 0:s.length)),l.filter=s,l},ep=a=>{var C,M,k,W,O,j;let l=[],n=[],r=[],i=[],s=[],h=[],c="",d=a==null?void 0:a[0];(d==null?void 0:d[0])==="*"&&(d=d==null?void 0:d.slice(1,d==null?void 0:d.length));let m=oe.analyzeSplitToContent(d,":");(C=m==null?void 0:m.filter(L=>(L==null?void 0:L[0])!=="{"&&(L==null?void 0:L[0])!=="["))==null||C.forEach(L=>{var x,w,g;(L==null?void 0:L[(L==null?void 0:L.length)-1])===":"&&(L=L==null?void 0:L.slice(0,(L==null?void 0:L.length)-1));let _=oe.analyzerSplitToWord(L,"(");if((_==null?void 0:_.length)>1){c=(x=ic(_))==null?void 0:x.filter;let E=L==null?void 0:L.replace(c,"");if(r.push(E),(c==null?void 0:c[0])==="("){c=c==null?void 0:c.slice(1,(c==null?void 0:c.length)-1);let P=[];(w=oe.analyzeSplitToContent(c,","))==null||w.forEach(V=>{(V==null?void 0:V[(V==null?void 0:V.length)-1])===","&&(V=V==null?void 0:V.slice(0,(V==null?void 0:V.length)-1)),(V==null?void 0:V[0])==="("&&(V=V==null?void 0:V.slice(1,(V==null?void 0:V.length)-1)),(V==null?void 0:V[0])!=="@"&&(V="@"+V),P.push(gn(V))}),c=P==null?void 0:P.join(",")}else c=gn(c);c=(g=oe.analyzeSplitToContent(c,","))==null?void 0:g.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===","&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P)),c!=null&&c.includes("@ShowHide=Hide")&&h.push(E),i=[...i,...c]}else r.push(_==null?void 0:_[0])});let b=(M=m==null?void 0:m.filter(L=>(L==null?void 0:L[0])==="{"))==null?void 0:M[0],u=(k=m==null?void 0:m.filter(L=>(L==null?void 0:L[0])==="["))==null?void 0:k[0];return l=Ni(u??""),l!=null&&l.every(L=>Array.isArray(L))&&(l=[l]),(b==null?void 0:b[(b==null?void 0:b.length)-1])===":"&&(b=b==null?void 0:b.slice(0,(b==null?void 0:b.length)-1)),s=(W=oe.analyzeSplitToContent(b,"@"))==null?void 0:W[1],s="@"+s,b=b==null?void 0:b.replace(s,""),s=gn(s),s=(O=oe.analyzeSplitToContent(s,","))==null?void 0:O.map(L=>((L==null?void 0:L[(L==null?void 0:L.length)-1])===","&&(L=L==null?void 0:L.slice(0,(L==null?void 0:L.length)-1)),L)),(b==null?void 0:b[0])==="{"&&(b=b==null?void 0:b.slice(1,(b==null?void 0:b.length)-1)),b=(j=oe.analyzeSplitToContent(b,","))==null?void 0:j.map(L=>((L==null?void 0:L[(L==null?void 0:L.length)-1])===","&&(L=L==null?void 0:L.slice(0,(L==null?void 0:L.length)-1)),L)),b==null||b.forEach((L,_)=>{var te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa;let x=[],w=[],g=[],E="",P="",V=!1,ee,J=[],me=[],_e=[],z="Input",ne=[],Y=[];if(L!=null&&L.includes("==")){ee=(te=L==null?void 0:L.split("=="))==null?void 0:te[0];let Ba=(ye=L==null?void 0:L.split("=="))==null?void 0:ye[1],Te="";(($e=oe.analyzeSplitToContent(Ba,"$"))==null?void 0:$e.length)>1&&((de=oe.analyzeSplitToContent(Ba,"$"))==null?void 0:de[0])!=="$"?(Te=(T=oe.analyzeSplitToContent(Ba,"$"))==null?void 0:T[0],Te=Te==null?void 0:Te.slice(0,(Te==null?void 0:Te.length)-1)):((ie=oe.analyzeSplitToContent(Ba,"}"))==null?void 0:ie.length)>1&&(Te=(U=oe.analyzeSplitToContent(Ba,"}"))==null?void 0:U[1]);let be=Ba==null?void 0:Ba.replace(Te,"");if((Te==null?void 0:Te[0])==="("&&(Te=Te==null?void 0:Te.slice(1,(Te==null?void 0:Te.length)-1)),(ge=oe.analyzeSplitToContent(Te,","))==null||ge.forEach(Be=>{var se;(Be==null?void 0:Be[0])!=="@"&&(Be="@"+Be),(Be==null?void 0:Be[(Be==null?void 0:Be.length)-1])===","&&(Be=Be==null?void 0:Be.slice(0,(Be==null?void 0:Be.length)-1));let ae=gn(Be);(se=oe.analyzeSplitToContent(ae,","))==null||se.forEach(Xe=>{(Xe==null?void 0:Xe[(Xe==null?void 0:Xe.length)-1])===","&&(Xe=Xe==null?void 0:Xe.slice(0,(Xe==null?void 0:Xe.length)-1)),x.push(Xe)})}),(be==null?void 0:be[0])==="$"&&(be=be==null?void 0:be.slice(1,be==null?void 0:be.length)),be!=null&&be.includes("&")){let Be=be;if((be==null?void 0:be[0])==="("){let se=(ze=oe.analyzeSplitToContent(be,"&"))==null?void 0:ze.map(Xe=>((Xe==null?void 0:Xe[(Xe==null?void 0:Xe.length)-1])==="&"&&(Xe=Xe==null?void 0:Xe.slice(0,(Xe==null?void 0:Xe.length)-1)),Xe));Be=se==null?void 0:se[1],se=se==null?void 0:se[0],(se==null?void 0:se[0])!=="@"&&(se="@"+se),E=gn(se)}(Be==null?void 0:Be[0])==="&"&&(Be=Be==null?void 0:Be.slice(1,Be==null?void 0:Be.length)),P=(ra=(Le=Be==null?void 0:Be.replace("(",yl))==null?void 0:Le.split(yl))==null?void 0:ra[0],g=(Q=(Ca=Be==null?void 0:Be.replace("(",yl))==null?void 0:Ca.split(yl))==null?void 0:Q[1],g=[g==null?void 0:g.slice(0,(g==null?void 0:g.length)-1)],z="Input"}else{let Be=(ca=be==null?void 0:be.replace("*",yl))==null?void 0:ca.split(yl);J=(ue=Be==null?void 0:Be[0])==null?void 0:ue.split(":"),me=(Se=(pa=oe.analyzeSplitToContent(Be==null?void 0:Be[1],":"))==null?void 0:pa.filter((ae,se)=>{var Xe,Ze;return se!==((Ze=(Xe=Be==null?void 0:Be[1])==null?void 0:Xe.split(":"))==null?void 0:Ze.length)-1}))==null?void 0:Se.map(ae=>((ae==null?void 0:ae[(ae==null?void 0:ae.length)-1])===":"&&(ae=ae==null?void 0:ae.slice(0,(ae==null?void 0:ae.length)-1)),ae)),_e=(De=(ce=oe.analyzeSplitToContent(Be==null?void 0:Be[1],":"))==null?void 0:ce.filter((ae,se)=>{var Xe,Ze;return se===((Ze=(Xe=Be==null?void 0:Be[1])==null?void 0:Xe.split(":"))==null?void 0:Ze.length)-1}))==null?void 0:De[0],_e=(ua=(Ke=_e==null?void 0:_e.replaceAll("{",""))==null?void 0:Ke.replaceAll("}",""))==null?void 0:ua.split(":"),z="Select"}}else if(((Za=oe.analyzeSplitToContent(L,"="))==null?void 0:Za.length)>1)if(z="Select",ee=(H=($=L==null?void 0:L.replace("=",yl))==null?void 0:$.split(yl))==null?void 0:H[0],!(L!=null&&L.includes("If")))ne=(he=(X=L==null?void 0:L.replace("=",yl))==null?void 0:X.split(yl))==null?void 0:he[1],ne=ne==null?void 0:ne.split("||");else{let Ba=(ha=(fe=L==null?void 0:L.replace("=",yl))==null?void 0:fe.split(yl))==null?void 0:ha[1];Y=(ta=oe.analyzeSplitToContent(Ba,")"))==null?void 0:ta.filter(Te=>!(Te!=null&&Te.includes("If"))),Y=Y==null?void 0:Y.map(Te=>((Te==null?void 0:Te[0])==="("&&(Te=Te==null?void 0:Te.slice(1,(Te==null?void 0:Te.length)-1)),Te=Te==null?void 0:Te.split("||"),Te)),w=(Fe=oe.analyzeSplitToContent(Ba,")"))==null?void 0:Fe.filter(Te=>Te==null?void 0:Te.includes("If")),w=w==null?void 0:w.map(Te=>((Te==null?void 0:Te[0])==="|"&&(Te=Te==null?void 0:Te.slice(2,Te==null?void 0:Te.length)),(Te==null?void 0:Te[0])==="("&&(Te=Te==null?void 0:Te.slice(1,(Te==null?void 0:Te.length)-1)),(Te==null?void 0:Te[0])!=="@"&&(Te="@"+Te),Te))}else if(((xa=oe.analyzeSplitToContent(L,"@"))==null?void 0:xa.length)>1){ee=(Ae=oe.analyzeSplitToContent(L,"@"))==null?void 0:Ae[0],(ee==null?void 0:ee[(ee==null?void 0:ee.length)-1])==="@"&&(ee=ee==null?void 0:ee.slice(0,(ee==null?void 0:ee.length)-1));let Ba="@"+((va=oe.analyzeSplitToContent(L,"@"))==null?void 0:va[1]);Ba=gn(Ba),x=(La=oe.analyzeSplitToContent(Ba,","))==null?void 0:La.map(Te=>((Te==null?void 0:Te[(Te==null?void 0:Te.length)-1])===","&&(Te=Te==null?void 0:Te.slice(0,(Te==null?void 0:Te.length)-1)),Te)),x!=null&&x.find(Te=>Te==null?void 0:Te.includes("@Type"))&&(z=(fa=(Ia=x==null?void 0:x.find(Te=>Te==null?void 0:Te.includes("@Type")))==null?void 0:Ia.split("="))==null?void 0:fa[1])}else ee=L;x!=null&&x.includes("@ShowHide=Hide")&&(V=!0),n.push({prop:ee,label:ee,value:"",menuPath:J,groups:me,columns:_e,type:z,options:ne,allContents:Y,filters:x,width:b==null?void 0:b.length,isFormColHidden:V,filterContents:w,functionName:P,functionRelatedWords:g,calculatorFilter:E})}),{groupName:r,groupFilters:i,formContents:n,contents:l,filter:s,hideContents:h}},Ni=a=>{var r,i;if(!a||typeof a!="string")return[];let l=[],n=a.slice(1,(a==null?void 0:a.length)-1);if((n==null?void 0:n[0])!=="[")(r=oe.analyzeSplitToContent(n,","))==null||r.forEach(s=>{(s==null?void 0:s[(s==null?void 0:s.length)-1])===","&&(s=s.slice(0,(s==null?void 0:s.length)-1)),l.push(s??"")}),(n==null?void 0:n[(n==null?void 0:n.length)-1])===","&&l.push("");else{let s=[];(i=oe.analyzeSplitToContent(n,","))==null||i.forEach(h=>{(h==null?void 0:h[(h==null?void 0:h.length)-1])===","&&(h=h==null?void 0:h.slice(0,(h==null?void 0:h.length)-1)),s.push(Ni(h))}),l=s}return l},kt=(a,l)=>{var j,L,_,x,w,g,E,P,V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae,se,Xe,Ze,Ha,_a,Qa;let n,r=[],i=[],s=[],h=[],c=[],d=[],m=[],b="Input",u,C="",M="",k="",W=[],O="";if(a!=null&&a.includes("==")||a!=null&&a.includes("=")||a!=null&&a.includes("@")||a!=null&&a.includes("||"))if(n=(j=a==null?void 0:a.split("=="))==null?void 0:j[0],u=(L=a==null?void 0:a.split("=="))==null?void 0:L[0],b="Select",a!=null&&a.includes("=")&&!(a!=null&&a.includes("=="))&&!((w=(x=(_=a==null?void 0:a.replace("=",yl))==null?void 0:_.split(yl))==null?void 0:x[1])!=null&&w.includes("If")))if(n=oe.analyzeSplitToContent(a,"@"),n=n==null?void 0:n[0],(n==null?void 0:n[(n==null?void 0:n.length)-1])==="@"&&(n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1)),n=(E=(g=n==null?void 0:n.replace("=",yl))==null?void 0:g.split(yl))==null?void 0:E[0],n!=null&&n.includes("&")&&(n=(V=(P=n==null?void 0:n.replace("&",yl))==null?void 0:P.split(yl))==null?void 0:V[0]),u=n,((ee=oe.analyzeSplitToContent(a,"@"))==null?void 0:ee.length)>1&&!(a!=null&&a.includes("||"))){if(!(a!=null&&a.includes("&"))){let Pe=(J=oe.analyzeSplitToContent(a,"@"))==null?void 0:J[1];if((Pe==null?void 0:Pe[0])!=="@"&&(Pe="@"+Pe),Pe=gn(Pe),M=Pe,M!=null&&M.includes("@Type")){let Re=oe.analyzeSplitToContent(M,",");Re=Re==null?void 0:Re.map(Ue=>((Ue==null?void 0:Ue[(Ue==null?void 0:Ue.length)-1])===","&&(Ue=Ue==null?void 0:Ue.slice(0,(Ue==null?void 0:Ue.length)-1)),Ue)),Re=(me=Re==null?void 0:Re.filter(Ue=>Ue==null?void 0:Ue.includes("@Type")))==null?void 0:me[0],b=(_e=Re==null?void 0:Re.split("="))==null?void 0:_e[1],b==="File"&&(b="Upload")}else b="Input"}}else if(a!=null&&a.includes("||")){let Pe=[];r=(Y=(ne=(z=oe.analyzeSplitToContent(a,"="))==null?void 0:z[1])==null?void 0:ne.split("||"))==null?void 0:Y.map(Ue=>{var Ie,ul,_l,Tl;let Ne=Ue;if(Ne!=null&&Ne.includes("@")){let jl="@"+((ul=(Ie=Ne==null?void 0:Ne.replace("@",yl))==null?void 0:Ie.split(yl))==null?void 0:ul[1]);Ne=(Tl=(_l=Ne==null?void 0:Ne.replace("@",yl))==null?void 0:_l.split(yl))==null?void 0:Tl[0],jl=ci(jl),Pe.push(jl)}return{label:Ne==null?void 0:Ne.replaceAll("'",""),value:Ne==null?void 0:Ne.replaceAll("'","")}}),(Pe==null?void 0:Pe.length)>0&&(M="("+(Pe==null?void 0:Pe.join("||"))+")");let Re=(te=oe.analyzeSplitToContent(a,"="))==null?void 0:te[0];if(Re!=null&&Re.includes("@")){(Re==null?void 0:Re[(Re==null?void 0:Re.length)-1])==="="&&(Re=Re==null?void 0:Re.slice(0,(Re==null?void 0:Re.length)-1));let Ue=(ye=oe.analyzeSplitToContent(Re,"@"))==null?void 0:ye[1];Ue="@"+Ue,Ue=ci(Ue),M=M===""?Ue:Ue+","+M}}else b="Input",C=(T=(de=($e=a==null?void 0:a.replace("=",yl))==null?void 0:$e.split(yl))==null?void 0:de[1])==null?void 0:T.replaceAll("'","");else if((U=(ie=oe.analyzeSplitToContent(a,"="))==null?void 0:ie[1])!=null&&U.includes("||")){let Pe=(ge=oe.analyzeSplitToContent(a,"="))==null?void 0:ge[0];if((Pe==null?void 0:Pe[(Pe==null?void 0:Pe.length)-1])==="="&&(Pe=Pe==null?void 0:Pe.slice(0,(Pe==null?void 0:Pe.length)-1)),Pe!=null&&Pe.includes("@")){let Ie=(ze=oe.analyzeSplitToContent(Pe,"@"))==null?void 0:ze[1];Ie="@"+Ie,M=ci(Ie),n=(Q=(Le=oe.analyzeSplitToContent(Pe,"@"))==null?void 0:Le[0])==null?void 0:Q.slice(0,((Ca=(ra=oe.analyzeSplitToContent(Pe,"@"))==null?void 0:ra[0])==null?void 0:Ca.length)-1),u=(Se=(ca=oe.analyzeSplitToContent(Pe,"@"))==null?void 0:ca[0])==null?void 0:Se.slice(0,((pa=(ue=oe.analyzeSplitToContent(Pe,"@"))==null?void 0:ue[0])==null?void 0:pa.length)-1)}else n=Pe,u=Pe;let Re=(ce=oe.analyzeSplitToContent(a,"="))==null?void 0:ce[1];Re=oe.analyzeSplitToContent(Re,")");let Ue=Re==null?void 0:Re.filter(Ie=>!(Ie!=null&&Ie.includes("If")));Ue==null||Ue.forEach(Ie=>{(Ie==null?void 0:Ie[0])==="("&&(Ie=Ie==null?void 0:Ie.slice(1,(Ie==null?void 0:Ie.length)-1)),i==null||i.push(Ie==null?void 0:Ie.split("||"))});let Ne=Re==null?void 0:Re.filter(Ie=>Ie==null?void 0:Ie.includes("If"));Ne=Ne==null?void 0:Ne.map(Ie=>((Ie==null?void 0:Ie[0])==="|"&&(Ie==null?void 0:Ie[1])==="|"&&(Ie=Ie==null?void 0:Ie.slice(2,Ie==null?void 0:Ie.length)),(Ie==null?void 0:Ie[0])==="("&&(Ie=Ie==null?void 0:Ie.slice(1,(Ie==null?void 0:Ie.length)-1)),(Ie==null?void 0:Ie[0])!=="@"&&(Ie="@"+Ie),Ie)),s=Ne}else{let Pe=a==null?void 0:a.split("=="),Re=(De=Pe==null?void 0:Pe.filter(Ue=>(Ue==null?void 0:Ue.includes("$"))&&(Ue==null?void 0:Ue[0])!=="{"))==null?void 0:De[0];if(Re&&!(Re!=null&&Re.includes("&"))){let Ue=(ua=oe.analyzeSplitToContent(Re,")"))==null?void 0:ua[((Ke=oe.analyzeSplitToContent(Re,")"))==null?void 0:Ke.length)-1],Ne=(Za=Ue==null?void 0:Ue.replace("*",yl))==null?void 0:Za.split(yl),Ie=(Ne==null?void 0:Ne[0])===""?l==null?void 0:l.value:Ne==null?void 0:Ne[0];(Ie==null?void 0:Ie[0])==="("&&(Ie=($=oe.analyzeSplitToContent(Ie,")"))==null?void 0:$[1]),Ie=(X=(H=Ie==null?void 0:Ie.replaceAll("{",""))==null?void 0:H.replaceAll("}",""))==null?void 0:X.replaceAll(Ki,""),(Ie==null?void 0:Ie[0])==="$"&&(Ie=(he=Ie==null?void 0:Ie.slice(1,Ie==null?void 0:Ie.length))==null?void 0:he.replaceAll(":","/")),h=Ie==null?void 0:Ie.split("/");let ul=(ha=(fe=Ne==null?void 0:Ne[1])==null?void 0:fe.replace("{",yl))==null?void 0:ha.split(yl),_l=ul==null?void 0:ul[0];(_l==null?void 0:_l[(_l==null?void 0:_l.length)-1])===":"&&(_l=_l==null?void 0:_l.slice(0,(_l==null?void 0:_l.length)-1)),c=_l==null?void 0:_l.split(":"),d=(Ae=(xa=(Fe=(ta=ul==null?void 0:ul[1])==null?void 0:ta.replace("}",yl))==null?void 0:Fe.split(yl))==null?void 0:xa[0])==null?void 0:Ae.split(":");let Tl="";((va=oe.analyzeSplitToContent(Re,")"))==null?void 0:va.length)>1&&(Tl=(La=oe.analyzeSplitToContent(Re,")"))==null?void 0:La[0]),Tl&&Tl!==""&&((Tl==null?void 0:Tl[0])!=="@"&&(Tl="@"+Tl),M=ci(Tl))}if(Pe!=null&&Pe.some(Ue=>Ue==null?void 0:Ue.includes("&"))){let Ue=(Ia=Pe==null?void 0:Pe.filter(ul=>ul==null?void 0:ul.includes("&")))==null?void 0:Ia[0];Ue=(fa=oe.analyzeSplitToContent(Ue,"&"))==null?void 0:fa.map(ul=>((ul==null?void 0:ul[(ul==null?void 0:ul.length)-1])==="&"&&(ul=ul==null?void 0:ul.slice(0,(ul==null?void 0:ul.length)-1)),ul)),k=(be=(Te=(Ba=Ue==null?void 0:Ue[1])==null?void 0:Ba.replace("(",yl))==null?void 0:Te.split(yl))==null?void 0:be[0];let Ne=(Be=oe.analyzeSplitToContent(Ue==null?void 0:Ue[1],")"))==null?void 0:Be[0];Ne=(se=(ae=Ne==null?void 0:Ne.replace("(",yl))==null?void 0:ae.split(yl))==null?void 0:se[1],Ne=Ne==null?void 0:Ne.slice(0,(Ne==null?void 0:Ne.length)-1),(Ne==null?void 0:Ne[0])==="{"&&(Ne=Ne==null?void 0:Ne.slice(1,Ne==null?void 0:Ne.length)),(Ne==null?void 0:Ne[(Ne==null?void 0:Ne.length)-1])==="}"&&(Ne=Ne==null?void 0:Ne.slice(0,(Ne==null?void 0:Ne.length)-1)),W=Ne==null?void 0:Ne.split(",");let Ie=Ue==null?void 0:Ue[0];Ie&&Ie!==""&&((Ie==null?void 0:Ie[0])!=="@"&&(Ie="@"+Ie),O=ci(Ie))}else if(!Re&&((Xe=Pe==null?void 0:Pe.filter(Ue=>(Ue==null?void 0:Ue[0])==="{"))==null?void 0:Xe.length)>0){let Ue=Pe==null?void 0:Pe[(Pe==null?void 0:Pe.length)-1];Ue=Ue==null?void 0:Ue.slice(1,(Ue==null?void 0:Ue.length)-1),Ue=oe.analyzeSplitToContent(Ue,","),Ue=Ue==null?void 0:Ue.map(Ne=>((Ne==null?void 0:Ne[(Ne==null?void 0:Ne.length)-1])===","&&(Ne=Ne==null?void 0:Ne.slice(0,(Ne==null?void 0:Ne.length)-1)),Ne)),Ue=Ue==null?void 0:Ue.map(Ne=>{var Ie,ul,_l,Tl;if(Ne=Ne==null?void 0:Ne.replaceAll("$",""),Ne!=null&&Ne.includes("{")){let jl="";Ne=Ne==null?void 0:Ne.replaceAll("{","");let Cl=Ne==null?void 0:Ne.split("}");jl=((ul=(Ie=Cl==null?void 0:Cl[0])==null?void 0:Ie.split(":"))==null?void 0:ul[0])+":"+(Cl==null?void 0:Cl[1]),Ne=jl,Ne=Ne+":"}if(Ne!=null&&Ne.includes(Ki)){let jl="",Cl=Ne==null?void 0:Ne.split(Ki);jl=((Tl=(_l=Cl==null?void 0:Cl[0])==null?void 0:_l.split(":"))==null?void 0:Tl[0])+":"+(Cl==null?void 0:Cl[1]),Ne=jl,Ne=Ne+":"}return Ne=Ne==null?void 0:Ne.replaceAll(":","/"),Ne}),m=Ue}else!((Ze=Pe==null?void 0:Pe[1])!=null&&Ze.includes("$"))&&((Ha=Pe==null?void 0:Pe[1])==null?void 0:Ha[0])!=="("&&d.push(Pe==null?void 0:Pe[1])}else n=(_a=a==null?void 0:a.split("&"))==null?void 0:_a[0],u=(Qa=a==null?void 0:a.split("&"))==null?void 0:Qa[0];return(r==null?void 0:r.length)===0&&(i==null?void 0:i.length)===0&&(h==null?void 0:h.length)===0&&b==="Select"&&(b="Input"),{label:n,prop:u,options:r,allContents:i,filterContents:s,menus:h,groups:c,words:d,align:"center",formType:b,filter:M,functionName:k,functionRelatedWords:W,calculatorFilter:O,relatedPages:m,value:C}},Ao=(a,l)=>{var r,i,s,h,c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me,_e,z,ne,Y;let n=[];if((a==null?void 0:a[0])==="{"&&(a==null?void 0:a[(a==null?void 0:a.length)-1])==="}"&&!((h=(s=(i=(r=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1))==null?void 0:r.replace(":",yl))==null?void 0:i.split(yl))==null?void 0:s[0])!=null&&h.includes(","))){let te=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1),ye=(c=te==null?void 0:te.replace(":",yl))==null?void 0:c.split(yl);if(((d=oe.analyzeSplitToContent(ye==null?void 0:ye[1],"="))==null?void 0:d.length)===1){let $e=ye==null?void 0:ye[0],de=[];(u=oe.analyzeSplitToContent((b=ye==null?void 0:ye[1])==null?void 0:b.slice(1,((m=ye==null?void 0:ye[1])==null?void 0:m.length)-1),","))==null||u.forEach(T=>{var ie,U;((ie=oe.analyzeSplitToContent(T,"="))==null?void 0:ie.length)>1?((T==null?void 0:T[(T==null?void 0:T.length)-1])===","&&(T=T==null?void 0:T.slice(0,(T==null?void 0:T.length)-1)),de=[...de,...Ao(T,l)]):((T==null?void 0:T[(T==null?void 0:T.length)-1])===","&&(T=T==null?void 0:T.slice(0,(T==null?void 0:T.length)-1)),de.push((U=Ao(T,l))==null?void 0:U[0]))}),n==null||n.push({label:$e,prop:$e,children:de,align:"center"})}else{let $e=[];if(((C=oe.analyzeSplitToContent(te,"="))==null?void 0:C.length)>=2){let T=(M=oe.analyzeSplitToContent(te,"="))==null?void 0:M[1],ie=(k=oe.analyzeSplitToContent(T,"/"))==null?void 0:k.map(U=>((U==null?void 0:U[(U==null?void 0:U.length)-1])==="/"&&(U=U==null?void 0:U.slice(0,(U==null?void 0:U.length)-1)),U));$e=ie==null?void 0:ie.map(U=>(U=Ni(U),U))}let de=(x=(_=(L=(j=(O=(W=te==null?void 0:te.replace("{",yl))==null?void 0:W.split(yl))==null?void 0:O[1])==null?void 0:j.replace("}",yl))==null?void 0:L.split(yl))==null?void 0:_[0])==null?void 0:x.split(",");de==null||de.forEach((T,ie)=>{($e==null?void 0:$e.length)>0&&ie===0?n==null||n.push({label:T,prop:T,align:"center",formType:"Select",relatedContents:$e==null?void 0:$e.map(U=>{let ge={};return de==null||de.forEach((ze,Le)=>{ge[ze]=U==null?void 0:U[Le]}),ge}),options:$e==null?void 0:$e.map(U=>({label:U==null?void 0:U[0],value:U==null?void 0:U[0]})),mainKey:!0}):n==null||n.push({label:T,prop:T,align:"center"})})}}else if((a==null?void 0:a[0])==="{")if(((w=oe.analyzeSplitToContent(a,"="))==null?void 0:w.length)===2&&((E=(g=oe.analyzeSplitToContent(a,"="))==null?void 0:g[1])==null?void 0:E[0])==="["){let te=[];if(((P=oe.analyzeSplitToContent(a,"="))==null?void 0:P.length)>=2){let $e=(V=oe.analyzeSplitToContent(a,"="))==null?void 0:V[1],de=(J=(ee=oe.analyzeSplitToContent($e,"|"))==null?void 0:ee.filter(T=>T!=="|"))==null?void 0:J.map(T=>((T==null?void 0:T[(T==null?void 0:T.length)-1])==="|"&&(T=T==null?void 0:T.slice(0,(T==null?void 0:T.length)-1)),T));te=de==null?void 0:de.map(T=>(T=Ni(T),T))}let ye=(_e=(me=a==null?void 0:a.replace("}",yl))==null?void 0:me.split(yl))==null?void 0:_e[0];ye=(z=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length))==null?void 0:z.split(","),ye==null||ye.forEach(($e,de)=>{(te==null?void 0:te.length)>0&&de===0?n==null||n.push({label:$e,prop:$e,align:"center",formType:"Select",relatedContents:te==null?void 0:te.map(T=>{let ie={};return ye==null||ye.forEach((U,ge)=>{ie[U]=T==null?void 0:T[ge]}),ie}),options:te==null?void 0:te.map(T=>({label:T==null?void 0:T[0],value:T==null?void 0:T[0]})),mainKey:!0}):n==null||n.push({label:$e,prop:$e,align:"center"})})}else(ne=oe.analyzeSplitToContent(a,","))==null||ne.forEach(te=>{var ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae;if((te==null?void 0:te[(te==null?void 0:te.length)-1])===","&&(te=te==null?void 0:te.slice(0,(te==null?void 0:te.length)-1)),(te==null?void 0:te[0])==="{"){let se=oe.analyzeSplitToContent(te,"="),Xe=se==null?void 0:se[(se==null?void 0:se.length)-1],Ze=[],Ha=[],_a=[],Qa="",Pe="",Re=[],Ue=[],Ne=(ye=Xe==null?void 0:Xe.replace("*",yl))==null?void 0:ye.split(yl),Ie=(Ne==null?void 0:Ne[0])===""?l==null?void 0:l.value:Ne==null?void 0:Ne[0];Ie=oe.analyzeSplitToContent(Ie,")");let ul="";if((Ie==null?void 0:Ie.length)>1&&(($e=Ie==null?void 0:Ie[0])==null?void 0:$e[0])!=="&"&&(ul=Ie==null?void 0:Ie[0],(ul==null?void 0:ul[0])!=="@"&&(ul="@"+ul),Pe=ul??""),Ie=(de=Ie==null?void 0:Ie.filter(aa=>(aa==null?void 0:aa[0])==="$"))==null?void 0:de[0],((T=oe.analyzeSplitToContent(Ie,"}"))==null?void 0:T.length)>1&&((U=(ie=oe.analyzeSplitToContent(Ie,"}"))==null?void 0:ie[1])==null?void 0:U[0])==="("&&(ul=(ge=oe.analyzeSplitToContent(Ie,"}"))==null?void 0:ge[1],(ul==null?void 0:ul[0])!=="@"&&(ul="@"+ul),Pe!==""&&(Pe=Pe+","),Pe=Pe+ul),(ze=Ie==null?void 0:Ie.slice(1,(Ie==null?void 0:Ie.length)-1))!=null&&ze.includes("$")||(Ie=(Le=oe.analyzeSplitToContent(Ie,"}"))==null?void 0:Le[0]),(Ie==null?void 0:Ie[0])==="$"&&(Ie=(ra=Ie==null?void 0:Ie.replace("{",""))==null?void 0:ra.replace("}",":"),Ie=(Ca=Ie==null?void 0:Ie.slice(1,Ie==null?void 0:Ie.length))==null?void 0:Ca.replaceAll(":","/")),Ie!=null&&Ie.includes("$")){let aa=(Q=Ie==null?void 0:Ie.split("$"))==null?void 0:Q[0];aa=(ca=aa==null?void 0:aa.split("/"))==null?void 0:ca[0],Ie=aa+"/"+((ue=Ie==null?void 0:Ie.split("$"))==null?void 0:ue[1])+"/"}Ze=(Ie==null?void 0:Ie.split("/"))??[];let _l=(Se=(pa=Ne==null?void 0:Ne[1])==null?void 0:pa.replace("{",yl))==null?void 0:Se.split(yl);if((Ke=(De=(ce=Ne==null?void 0:Ne[1])==null?void 0:ce.split("(@"))==null?void 0:De[0])!=null&&Ke.includes("&&")||($=(Za=(ua=Ne==null?void 0:Ne[1])==null?void 0:ua.split("@"))==null?void 0:Za[0])!=null&&$.includes("&&")){let aa=(H=Ne==null?void 0:Ne[1])!=null&&H.includes("(@")?(fe=(he=(X=Ne==null?void 0:Ne[1])==null?void 0:X.split("(@"))==null?void 0:he[0])==null?void 0:fe.split("&&"):(Fe=(ta=(ha=Ne==null?void 0:Ne[1])==null?void 0:ha.split("@"))==null?void 0:ta[0])==null?void 0:Fe.split("&&");Re=aa==null?void 0:aa.map(ma=>{var il,Aa;return(ma==null?void 0:ma[0])==="*"&&(ma=ma==null?void 0:ma.slice(1,ma==null?void 0:ma.length)),ma=(Aa=(il=ma==null?void 0:ma.replace("{",yl))==null?void 0:il.split(yl))==null?void 0:Aa[0],(ma==null?void 0:ma[(ma==null?void 0:ma.length)-1])===":"&&(ma=ma==null?void 0:ma.slice(0,(ma==null?void 0:ma.length)-1)),ma=ma==null?void 0:ma.split(":"),ma});let Ka=[];aa==null||aa.forEach((ma,il)=>{var Aa,sl;(ma==null?void 0:ma[0])==="*"&&(ma=ma==null?void 0:ma.slice(1,ma==null?void 0:ma.length)),ma=(sl=(Aa=ma==null?void 0:ma.replace("{",yl))==null?void 0:Aa.split(yl))==null?void 0:sl[1],(ma==null?void 0:ma[(ma==null?void 0:ma.length)-1])==="}"&&(ma=ma==null?void 0:ma.slice(0,(ma==null?void 0:ma.length)-1)),ma=ma==null?void 0:ma.split(","),Ka.push(il===0?(ma==null?void 0:ma.length)-1:ma==null?void 0:ma.length),Ue=[...Ue,...ma]}),Ka=(xa=oe.prefixSum(Ka))==null?void 0:xa.map(ma=>ma==null?void 0:ma.total),Re=Re==null?void 0:Re.map((ma,il)=>({number:Ka==null?void 0:Ka[il],contents:ma}))}let Tl=_l==null?void 0:_l[0];(Tl==null?void 0:Tl[(Tl==null?void 0:Tl.length)-1])===":"&&(Tl=Tl==null?void 0:Tl.slice(0,(Tl==null?void 0:Tl.length)-1)),Ha=(Tl==null?void 0:Tl.split(":"))??[],_a=((Ia=(La=(va=(Ae=_l==null?void 0:_l[1])==null?void 0:Ae.replace("}",yl))==null?void 0:va.split(yl))==null?void 0:La[0])==null?void 0:Ia.split(","))??[];let jl=(Ba=se==null?void 0:se[0])==null?void 0:Ba.slice(1,((fa=se==null?void 0:se[0])==null?void 0:fa.length)-2);Pe&&Pe!==""&&(Qa=ci(Pe));let Cl=(Te=oe.analyzeSplitToContent(Qa,","))==null?void 0:Te.map(aa=>((aa==null?void 0:aa[(aa==null?void 0:aa.length)-1])===","&&(aa=aa==null?void 0:aa.slice(0,(aa==null?void 0:aa.length)-1)),aa)),Yl=[];Cl!=null&&Cl.find(aa=>aa==null?void 0:aa.includes("@MainParam"))&&(Cl=Cl==null?void 0:Cl.find(aa=>aa==null?void 0:aa.includes("@MainParam")),Cl=(Be=(be=Cl==null?void 0:Cl.replace("=",yl))==null?void 0:be.split(yl))==null?void 0:Be[1],Cl=Cl==null?void 0:Cl.slice(1,(Cl==null?void 0:Cl.length)-1),Yl=oe.analyzeSplitToContent(Cl,",")),(ae=jl==null?void 0:jl.split(","))==null||ae.forEach((aa,Ka)=>{var ma,il,Aa,sl,rl;((ma=oe.analyzeSplitToContent(aa,"@"))==null?void 0:ma.length)>1&&(aa=(il=oe.analyzeSplitToContent(aa,"@"))==null?void 0:il[0],(aa==null?void 0:aa[(aa==null?void 0:aa.length)-1])==="@"&&(aa=aa==null?void 0:aa.slice(0,(aa==null?void 0:aa.length)-1))),n.push({label:aa,prop:aa,align:"center",menus:Ze,groups:(Re==null?void 0:Re.length)===0?Ha:(Aa=Re==null?void 0:Re.find(qe=>(qe==null?void 0:qe.number)>=Ka))==null?void 0:Aa.contents,words:(Ue==null?void 0:Ue.length)===0?(sl=_a==null?void 0:_a[Ka])==null?void 0:sl.split(":"):(rl=Ue==null?void 0:Ue[Ka])==null?void 0:rl.split(":"),formType:(Ze==null?void 0:Ze.length)>0?"Select":"Input",mainKey:!!(Ka===0||Yl!=null&&Yl.find(qe=>qe===aa)),filter:Qa,isMainPath:(Re==null?void 0:Re.findIndex(qe=>(qe==null?void 0:qe.number)>=Ka))===0})})}else n.push({label:te,prop:te,align:"center"})});else{let te=(Y=oe.analyzeSplitToContent(a,","))==null?void 0:Y.map(ye=>((ye==null?void 0:ye[(ye==null?void 0:ye.length)-1])===","&&(ye=ye==null?void 0:ye.slice(0,(ye==null?void 0:ye.length)-1)),ye));te==null||te.forEach(ye=>{n.push(kt(ye,l))})}return n},ap=(a,l)=>{var h,c,d,m,b;let n=a;if(!a)return;let r="";((h=oe.analyzeSplitToContent(a,"}"))==null?void 0:h.length)>1&&(n=(c=oe.analyzeSplitToContent(a,"}"))==null?void 0:c[0],r=(d=oe.analyzeSplitToContent(a,"}"))==null?void 0:d[1]),(a==null?void 0:a[0])==="{"&&(a==null?void 0:a[(a==null?void 0:a.length)-1])==="}"&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1));let i=[],s=[];return i.push({label:"排序",prop:"sort"}),i.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(m=oe.analyzeSplitToContent(n,","))==null||m.forEach(u=>{var C;(u==null?void 0:u[(u==null?void 0:u.length)-1])===","&&(u=u==null?void 0:u.slice(0,(u==null?void 0:u.length)-1)),(u==null?void 0:u[0])==="{"?(C=Ao(u,l))==null||C.forEach(M=>{i.push(M)}):i.push(kt(u,l))}),i!=null&&i.some(u=>{var C;return(C=u==null?void 0:u.prop)==null?void 0:C.includes("@")})&&(i=i==null?void 0:i.filter(u=>{var C;return!((C=u==null?void 0:u.prop)!=null&&C.includes("@"))})),r!==""&&((r==null?void 0:r[0])=="{"&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1)),(b=oe.analyzeSplitToContent(r,","))==null||b.forEach(u=>{var C;(u==null?void 0:u[(u==null?void 0:u.length)-1])===","&&(u=u==null?void 0:u.slice(0,(u==null?void 0:u.length)-1)),(u==null?void 0:u[0])==="{"?(C=Ao(u,l))==null||C.forEach(M=>{s.push(M)}):s.push(kt(u,l))})),{columns:i,secondColumns:s}},gn=a=>{var l,n,r,i,s;if(a!=null&&a.includes("@Filter")||a!=null&&a.includes("@Condition")||a!=null&&a.includes("@If"))return a;{let h=(n=(l=a==null?void 0:a.replace("(",yl))==null?void 0:l.split(yl))==null?void 0:n[1],c=(i=(r=a==null?void 0:a.replace("(",yl))==null?void 0:r.split(yl))==null?void 0:i[0];return h=h==null?void 0:h.slice(0,(h==null?void 0:h.length)-1),h=(s=oe.analyzeSplitToContent(h,","))==null?void 0:s.map(d=>((d==null?void 0:d[(d==null?void 0:d.length)-1])===","&&(d=d==null?void 0:d.slice(0,(d==null?void 0:d.length)-1)),(d==null?void 0:d[0])==="("&&(d=d==null?void 0:d.slice(1,(d==null?void 0:d.length)-1)),c+d)),h=h==null?void 0:h.join(","),a!=null&&a.includes("@Quote")&&(h!=null&&h.includes("@QuoteType")||(h=h===""?h+"@QuoteType=Manual":h+",@QuoteType=Manual"),h!=null&&h.includes("@QuoteSonSync")||(h=h===""?h+"@QuoteSonSync=No":h+",@QuoteSonSync=No"),h!=null&&h.includes("@QuoteFatherSync")||(h=h===""?h+"@QuoteFatherSync=Yes":h+",@QuoteFatherSync=Yes")),h}},us=a=>{let l=a==null?void 0:a.map(n=>{var r,i;return{menus:n==null?void 0:n.menus,content:((r=n==null?void 0:n.menus)==null?void 0:r.join("/"))+yl+((i=n==null?void 0:n.groups)==null?void 0:i.join("/"))}});return l=l==null?void 0:l.filter(n=>{var r;return(n==null?void 0:n.menus)&&((r=n==null?void 0:n.menus)==null?void 0:r.length)>0}),l=l==null?void 0:l.map(n=>n==null?void 0:n.content),l=[...new Set(l)],l=l==null?void 0:l.map(n=>{var r,i;return{menus:(r=n==null?void 0:n.split(yl))==null?void 0:r[0],groups:((i=n==null?void 0:n.split(yl))==null?void 0:i[1])??[]}}),l},ds=a=>{var n;let l=a;return(l==null?void 0:l[0])==="("&&(l==null?void 0:l[1])==="("&&(l=l.slice(1,(l==null?void 0:l.length)-1)),l=(n=oe.analyzeSplitToContent(l,","))==null?void 0:n.map(r=>((r==null?void 0:r[(r==null?void 0:r.length)-1])===","&&(r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1)),(r==null?void 0:r[0])!=="@"&&(r="@"+r),(r==null?void 0:r[1])==="("&&(r=gn(r)),r)),l==null?void 0:l.join(",")},tc=(a,l,n="")=>{var L,_,x,w,g,E,P,V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba,Te;let r=[],i=[],s=[],h="",c="",d="",m=[],b=[],u=[],C="";if(((L=a==null?void 0:a[0])==null?void 0:L[0])!=="*"&&((_=a==null?void 0:a[0])==null?void 0:_[0])!=="$"&&!((x=a==null?void 0:a[0])!=null&&x.includes("$")))return;((w=a==null?void 0:a[0])==null?void 0:w[0])!=="*"&&((g=a==null?void 0:a[0])==null?void 0:g[0])!=="$"&&(h=(E=oe.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:E[0],(h==null?void 0:h[0])!=="@"&&(h="@"+h),h=ci(h),d=(P=oe.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:P[1],(d==null?void 0:d[0])==="$"&&(d=d==null?void 0:d.slice(1,d==null?void 0:d.length)),d=d==null?void 0:d.replaceAll(":","/"));let k=oe.analyzeSplitToContent(a==null?void 0:a[0],":");if(r=(V=k==null?void 0:k.filter(be=>(be==null?void 0:be[0])!=="{"&&(be==null?void 0:be[0])!=="["))==null?void 0:V.join(""),c=(ee=a==null?void 0:a[0])==null?void 0:ee.replace(r,""),(r==null?void 0:r[0])==="("&&(r=""),C=(J=k==null?void 0:k.filter(be=>(be==null?void 0:be[0])!=="["))==null?void 0:J.join(""),C=(me=a==null?void 0:a[0])==null?void 0:me.replace(C,""),c=c==null?void 0:c.replace(C,""),(r==null?void 0:r[0])==="*"&&(r=r==null?void 0:r.slice(1,r==null?void 0:r.length)),(r==null?void 0:r[(r==null?void 0:r.length)-1])===":"&&(r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1)),((_e=oe.analyzeSplitToContent(c,"@"))==null?void 0:_e.length)>1&&(h=(z=oe.analyzeSplitToContent(c,"@"))==null?void 0:z[1],(h==null?void 0:h[(h==null?void 0:h.length)-1])===":"&&(h=h==null?void 0:h.slice(0,(h==null?void 0:h.length)-1)),h="@"+h,h=gn(h),c=(ne=oe.analyzeSplitToContent(c,"@"))==null?void 0:ne[0],c=c==null?void 0:c.slice(0,(c==null?void 0:c.length)-1)),((Y=oe.analyzeSplitToContent(r,"@"))==null?void 0:Y.length)>1){h!==""&&(h=h+",");let be=(te=oe.analyzeSplitToContent(r,"@"))==null?void 0:te[1];be="@"+be,be=gn(be),h=h+be,r=(ye=oe.analyzeSplitToContent(r,"@"))==null?void 0:ye[0]}if((r==null?void 0:r[(r==null?void 0:r.length)-1])==="@"&&(r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1)),r=r===""?[]:r==null?void 0:r.split(":"),(c==null?void 0:c[(c==null?void 0:c.length)-1])===":"&&(c=c==null?void 0:c.slice(0,(c==null?void 0:c.length)-1)),n!==""){let be=($e=oe.analyzeSplitToContent(n,")"))==null?void 0:$e[0],Be=(de=oe.analyzeSplitToContent(n,"@"))==null?void 0:de[1];d=(ie=(T=oe.analyzeSplitToContent(n,"@"))==null?void 0:T[0])==null?void 0:ie.replace(be,""),(d==null?void 0:d[(d==null?void 0:d.length)-1])==="@"&&(d=d==null?void 0:d.slice(0,(d==null?void 0:d.length)-1)),be=ds(be),Be=ds(Be);let ae=be??"";if(ae!==""&&(ae=ae+","),ae=ae+Be,(ae==null?void 0:ae[(ae==null?void 0:ae.length)-1])===","&&(ae=ae==null?void 0:ae.slice(0,(ae==null?void 0:ae.length)-1)),ae!==""&&h!==""&&(h=h+","),h=h+ae,(d==null?void 0:d[0])==="$"&&(d=d==null?void 0:d.slice(1,d==null?void 0:d.length)),d=(U=oe.analyzeSplitToContent(d,":"))==null?void 0:U.filter((se,Xe)=>{var Ze;return!((se==null?void 0:se[0])==="{"&&Xe===((Ze=oe.analyzeSplitToContent(d,":"))==null?void 0:Ze.length)-1)}),d=d==null?void 0:d.join(""),(d==null?void 0:d[(d==null?void 0:d.length)-1])===":"&&(d=d==null?void 0:d.slice(0,(d==null?void 0:d.length)-1)),h!=null&&h.includes("@Sync")||(h=h===""?h+"@Sync=(Yes,Yes)":h+",@Sync=(Yes,Yes)"),d!=null&&d.includes("$")){let se=(ze=(ge=d==null?void 0:d.replace("*",yl))==null?void 0:ge.split(yl))==null?void 0:ze[1],Xe=(ra=(Le=d==null?void 0:d.replace("*",yl))==null?void 0:Le.split(yl))==null?void 0:ra[0];Xe=Xe==null?void 0:Xe.split("$"),Xe=((Q=(Ca=Xe==null?void 0:Xe[0])==null?void 0:Ca.split(":"))==null?void 0:Q[0])+":"+(Xe==null?void 0:Xe[1])+":",d=Xe+"*"+se}else d=(ca=d==null?void 0:d.replaceAll("{",""))==null?void 0:ca.replaceAll("}","")}h!==""&&h&&(h="("+h+")"),h=d+h,((ue=oe.analyzeSplitToContent(c,"}"))==null?void 0:ue.length)>1&&(c=(pa=oe.analyzeSplitToContent(c,"}"))==null?void 0:pa.filter(be=>(be==null?void 0:be[0])!=="@"),c=c==null?void 0:c.join(""));let W=ap(c,l);s=c===""?[]:(W==null?void 0:W.columns)??[],u=oe.getColumnChild(s);let O=oe.getColumnChild(s);s!=null&&s.some(be=>{var Be;return Array.isArray(be==null?void 0:be.children)&&((Be=be==null?void 0:be.children)==null?void 0:Be.length)>0})&&(s=[s]),i=C?Ni(C):[],!(i!=null&&i.every(be=>Array.isArray(be)))&&(i==null?void 0:i.length)>0&&(i=[i]),(i==null?void 0:i.length)>0&&(Array.isArray(i==null?void 0:i[0])&&((Se=i==null?void 0:i[0])!=null&&Se.every(be=>Array.isArray(be)))?i=i==null?void 0:i.map((be,Be)=>(be=be.map((ae,se)=>(ae.unshift("{}"),ae.unshift((se+1).toString()),ae)),be)):i=i==null?void 0:i.map((be,Be)=>(be.unshift("{}"),be.unshift((Be+1).toString()),be))),W!=null&&W.secondColumns&&((ce=W==null?void 0:W.secondColumns)==null?void 0:ce.length)>0&&((i==null?void 0:i.length)>0?i=i==null?void 0:i.map((be,Be)=>{var ae,se;return Array.isArray(be==null?void 0:be[0])?be=be==null?void 0:be.map((Xe,Ze)=>{var Ha,_a;return Xe.unshift((_a=(Ha=W==null?void 0:W.secondColumns)==null?void 0:Ha[Ze])==null?void 0:_a.prop),Xe}):be.unshift((se=(ae=W==null?void 0:W.secondColumns)==null?void 0:ae[Be])==null?void 0:se.prop),be}):i=(De=W==null?void 0:W.secondColumns)==null?void 0:De.map((be,Be)=>(be=[be==null?void 0:be.label],be.push(Be),be)),s.unshift({label:"",prop:"disabled",sortable:!1})),u=u==null?void 0:u.map(be=>{var Be,ae;return{menus:be==null?void 0:be.menus,content:((Be=be==null?void 0:be.menus)==null?void 0:Be.join("/"))+yl+((ae=be==null?void 0:be.groups)==null?void 0:ae.join("/"))}});let j=[];if(((ua=(Ke=h==null?void 0:h.replace("(",yl))==null?void 0:Ke.split(yl))==null?void 0:ua[0])!==""&&(j=($=(Za=h==null?void 0:h.replace("(",yl))==null?void 0:Za.split(yl))==null?void 0:$[0],j=[j],j=j==null?void 0:j.map(be=>{var ae,se,Xe;let Be=be==null?void 0:be.split("*");return{menus:(ae=Be==null?void 0:Be[0])==null?void 0:ae.split(":"),content:((se=Be==null?void 0:Be[0])==null?void 0:se.replaceAll(":","/"))+yl+((Xe=Be==null?void 0:Be[1])==null?void 0:Xe.replaceAll(":","/"))}}),u=[...u,...j]),u=u==null?void 0:u.filter(be=>{var Be;return(be==null?void 0:be.menus)&&((Be=be==null?void 0:be.menus)==null?void 0:Be.length)>0}),u=u==null?void 0:u.map(be=>be==null?void 0:be.content),u=[...new Set(u)],u=u==null?void 0:u.map(be=>{var Be,ae;return{menus:(Be=be==null?void 0:be.split(yl))==null?void 0:Be[0],groups:((ae=be==null?void 0:be.split(yl))==null?void 0:ae[1])??[]}}),m=O==null?void 0:O.filter(be=>{var Be;return(be==null?void 0:be.filter)&&((Be=be==null?void 0:be.filter)==null?void 0:Be.includes("@Sync"))}),(m==null?void 0:m.length)>0&&(m=m==null?void 0:m.filter(be=>{var Be,ae,se,Xe;return(Xe=(se=(ae=(Be=oe.analyzeSplitToContent(be==null?void 0:be.filter,","))==null?void 0:Be.find(Ze=>Ze==null?void 0:Ze.includes("@Sync")))==null?void 0:ae.split(","))==null?void 0:se[0])==null?void 0:Xe.includes("Yes")}),m=us(m)),b=O==null?void 0:O.filter(be=>{var Be;return(be==null?void 0:be.filter)&&((Be=be==null?void 0:be.filter)==null?void 0:Be.includes("@Sync"))}),(b==null?void 0:b.length)>0&&(b=b==null?void 0:b.filter(be=>{var Be,ae,se,Xe;return(Xe=(se=(ae=(Be=oe.analyzeSplitToContent(be==null?void 0:be.filter,","))==null?void 0:Be.find(Ze=>Ze==null?void 0:Ze.includes("@Sync")))==null?void 0:ae.split(","))==null?void 0:se[1])==null?void 0:Xe.includes("Yes")}),b=us(b)),h!==""&&(h!=null&&h.includes("@Sync"))&&(h==null?void 0:h[0])!=="("){let be=(H=h==null?void 0:h.replace("(",yl))==null?void 0:H.split(yl),Be=be==null?void 0:be[1];if(Be=Be==null?void 0:Be.slice(0,(Be==null?void 0:Be.length)-1),Be=oe.analyzeSplitToContent(Be,","),(fe=(he=(X=Be==null?void 0:Be.find(ae=>ae==null?void 0:ae.includes("@Sync")))==null?void 0:X.split(","))==null?void 0:he[0])!=null&&fe.includes("Yes")){let ae=be==null?void 0:be[0];ae=[{menus:(ta=(ha=ae==null?void 0:ae.split("*"))==null?void 0:ha[0])==null?void 0:ta.replaceAll(":","/"),groups:((xa=(Fe=ae==null?void 0:ae.split("*"))==null?void 0:Fe[1])==null?void 0:xa.split(":"))??[]}],m=[...m,...ae]}if((La=(va=(Ae=Be==null?void 0:Be.find(ae=>ae==null?void 0:ae.includes("@Sync")))==null?void 0:Ae.split(","))==null?void 0:va[1])!=null&&La.includes("Yes")){let ae=be==null?void 0:be[0];ae=[{menus:(fa=(Ia=ae==null?void 0:ae.split("*"))==null?void 0:Ia[0])==null?void 0:fa.replaceAll(":","/"),groups:((Te=(Ba=ae==null?void 0:ae.split("*"))==null?void 0:Ba[1])==null?void 0:Te.split(":"))??[]}],b=[...b,...ae]}}return{groupName:r,tableColumns:s,tableFilter:h,tableContents:i,columns:(W==null?void 0:W.secondColumns)??[],relatedQuotes:u,fatherSyncContents:m,sonSyncContents:b}},sc=(a,l)=>(a=a==null?void 0:a.map((n,r)=>{var i,s,h,c;if(Array.isArray(n))n=n==null?void 0:n.map(d=>{var m,b,u,C;return d!=null&&d.isMainPath||(((m=d==null?void 0:d.children)==null?void 0:m.length)>0?d.children=sc(d.children,l):((b=d==null?void 0:d.menus)==null?void 0:b.length)>0&&!((u=n==null?void 0:n[0])!=null&&u.isMainPath)&&(d.menus=(C=d.menus)==null?void 0:C.map((M,k)=>{var W,O;return((W=d.menus)==null?void 0:W.length)-1===k&&M===""&&(l==null?void 0:l.parentContent)+"/"!==((O=d.menus)==null?void 0:O.join("/"))&&(M=l==null?void 0:l.value),d}),d.bindMenus=d.menus)),d});else{if(r===0&&((i=n.menus)==null?void 0:i.length)>0&&(n.mainKey=!0),n!=null&&n.isMainPath)return n;((s=n.menus)==null?void 0:s.length)>0&&!((h=a==null?void 0:a[0])!=null&&h.isMainPath)&&(n.menus=(c=n.menus)==null?void 0:c.map((d,m)=>{var b,u;return((b=n.menus)==null?void 0:b.length)-1===m&&d===""&&(l==null?void 0:l.parentContent)+"/"!==((u=n.menus)==null?void 0:u.join("/"))&&(d=l==null?void 0:l.value),d}),n.bindMenus=n.menus)}return n}),a),lp=(a,l)=>(a=a==null?void 0:a.map(n=>((n==null?void 0:n.key)==="header"&&(n.contents=sc(n.contents,l)),n)),a),xt=(a,l)=>{let n=a;return Array.isArray(n==null?void 0:n[0])?n=n==null?void 0:n.map(r=>(r=xt(r,l),r)):n=n==null?void 0:n.map(r=>{var i,s;return r!=null&&r.children&&((i=r==null?void 0:r.children)==null?void 0:i.length)>0?r.children=xt(r==null?void 0:r.children,l):r!=null&&r.words&&((s=r==null?void 0:r.words)==null?void 0:s.length)>0&&(l!=null&&l.find(h=>{var c,d,m,b;return((b=(c=r==null?void 0:r.prop)==null?void 0:c.split("."))==null?void 0:b[((m=(d=r==null?void 0:r.prop)==null?void 0:d.split("."))==null?void 0:m.length)-1])===h}))&&(r.mainKey=!0),r}),n};let yr="$R";const rp=A.useUnit(A.pinia),{selectTitle:pn}=A.storeToRefs(rp),np=A.useMenuState(A.pinia),{localFiles:ip}=A.storeToRefs(np),op=A.useLoginState(A.pinia),{loginUserInfo:ht}=A.storeToRefs(op),En=[{key:"@MaxRow",value:"onNumSlice",order:1},{key:"@MaxColumn",value:"onMaxColumn",order:1},{key:"@EditRead",value:"onEditRead",order:1},{key:"@ShowHide",value:"onShowHide",order:1},{key:"@Type",value:"onRandomContents",order:2},{key:"@SubType",value:"onInterfaceTypeContents",order:2},{key:"@If",value:"onConditionContents",order:4},{key:"@QuoteFatherSync",value:"onFatherPaceContents",order:1},{key:"@QuoteSonSync",value:"onPaceContents",order:1},{key:"@MainParam",value:"onMainTagContents",order:3},{key:"@Button",value:"onButtonContents",order:1},{key:"@Related",value:"onRelated",order:1},{key:"@RowNum",value:"onRowNum",order:1},{key:"@FixColumn",value:"onFixRow",order:1},{key:"@ReqItem",value:"onReqItem",order:1},{key:"@Condition",value:"onConditionContent",order:1},{key:"@Tab",value:"onTabs",order:1},{key:"@SinChoice",value:"onSinChoice",order:1},{key:"@TextSize",value:"onTextSize",order:1},{key:"@TextRGBA",value:"onTextRGBA",order:1},{key:"@Position",value:"onPosition",order:4},{key:"@Size",value:"onSize",order:4},{key:"@ShowType",value:"onShowType",order:1},{key:"@StepName",value:"onStepName",order:1},{key:"@Step",value:"onStep",order:1},{key:"@BackGround",value:"onBackGround",order:1}];var si=(a=>(a[a.ORDINARY=1]="ORDINARY",a[a.BLOCK=2]="BLOCK",a[a.TEXT=3]="TEXT",a))(si||{});const tp=async a=>{var n,r,i,s,h,c,d,m,b,u,C,M,k,W,O,j,L;let l=oe.analyzeSplitToContent((a==null?void 0:a.filter)??"",")");if((l==null?void 0:l.length)>1){let _=l==null?void 0:l[0];_=_==null?void 0:_.slice(1,(_==null?void 0:_.length)-1),_=(r=(n=_==null?void 0:_.replace("(",yr))==null?void 0:n.split(yr))==null?void 0:r[1],_="("+((i=_==null?void 0:_.replaceAll("{",""))==null?void 0:i.replaceAll("}",""));let x=oe.calculatorAndToOr(_),w=Object.keys(x==null?void 0:x[0]);if(_=x,((s=w==null?void 0:w[0])==null?void 0:s[0])==="$"){let g=(c=w==null?void 0:w[0])==null?void 0:c.slice(1,((h=w==null?void 0:w[0])==null?void 0:h.length)-1),E=(m=(d=g==null?void 0:g.split("*"))==null?void 0:d[0])==null?void 0:m.replaceAll(".","/"),P=(C=(u=(b=g==null?void 0:g.split("*"))==null?void 0:b[1])==null?void 0:u.split("."))==null?void 0:C[0],V=await Jr(E,!1);V=(M=V==null?void 0:V.filter(z=>(z==null?void 0:z.name)===P))==null?void 0:M[0];let ee=(W=(k=V==null?void 0:V.compData)==null?void 0:k.find(z=>(z==null?void 0:z.key)==="tableContents"))==null?void 0:W.contents;_=_==null?void 0:_.map(z=>{var Y,te;let ne={};for(let ye in z)if((ye==null?void 0:ye[0])==="$"){let $e=(te=ye==null?void 0:ye.split("."))==null?void 0:te[((Y=ye==null?void 0:ye.split("."))==null?void 0:Y.length)-1];ne[$e]=z==null?void 0:z[ye]}else ne[ye]=z==null?void 0:z[ye];return ne});let J=(j=(O=V==null?void 0:V.compData)==null?void 0:O.find(z=>(z==null?void 0:z.key)==="header"))==null?void 0:j.contents;J=(L=oe.getEqualChild(J))==null?void 0:L.filter(z=>(z==null?void 0:z.label)!=="操作");let _e=oe.tableToForm(ee,J);if(_==null||_.forEach(z=>{var ne,Y,te,ye,$e;for(let de in z)(z==null?void 0:z[de])==="LoginUser"&&(z[de]=((ne=ht.value)==null?void 0:ne.姓名)||((Y=ht.value)==null?void 0:Y.account)||((te=ht.value)==null?void 0:te.账号)),!((ye=_e==null?void 0:_e[0])!=null&&ye.find(T=>{var ie;return(T==null?void 0:T.key)===de||((ie=T==null?void 0:T.key)==null?void 0:ie.includes(de))}))&&!(_e!=null&&_e.find(T=>{var ie;return(T==null?void 0:T.key)===de||((ie=T==null?void 0:T.key)==null?void 0:ie.includes(de))}))||((($e=z[de])==null?void 0:$e[0])!=="!"?_e=_e==null?void 0:_e.filter(T=>{var ie,U;return((ie=T==null?void 0:T.find(ge=>{var ze;return(ge==null?void 0:ge.key)===de||((ze=ge==null?void 0:ge.key)==null?void 0:ze.includes(de))}))==null?void 0:ie.value)===z[de]||Array.isArray(z==null?void 0:z[de])&&((U=z==null?void 0:z[de])==null?void 0:U.find(ge=>{var ze;return((ze=T==null?void 0:T.find(Le=>{var ra;return(Le==null?void 0:Le.key)===de||((ra=Le==null?void 0:Le.key)==null?void 0:ra.includes(de))}))==null?void 0:ze.value)===ge}))}):_e=_e==null?void 0:_e.filter(T=>{var ie;return((ie=T==null?void 0:T.find(U=>{var ge;return(U==null?void 0:U.key)===de||((ge=U==null?void 0:U.key)==null?void 0:ge.includes(de))}))==null?void 0:ie.value)!==z[de]}))}),(_e==null?void 0:_e.length)===0){let z=a==null?void 0:a.contents;return z.push({key:"hideContents",contents:!0}),z}}}return a==null?void 0:a.contents},sp=a=>{var l,n,r,i,s;if((a==null?void 0:a.filter)!==void 0&&(a==null?void 0:a.filter)!==null&&(a==null?void 0:a.filter)!==""){let h=a==null?void 0:a.contents,c=a==null?void 0:a.filter;(c==null?void 0:c[0])==="("&&(c=c==null?void 0:c.slice(1,(c==null?void 0:c.length)-1)),c=(l=oe.analyzeSplitToContent(c,","))==null?void 0:l.map(m=>((m==null?void 0:m[(m==null?void 0:m.length)-1])===","&&(m=m==null?void 0:m.slice(0,(m==null?void 0:m.length)-1)),m)),c=c==null?void 0:c[1],(c==null?void 0:c[0])==="("&&(c=c==null?void 0:c.slice(1,(c==null?void 0:c.length)-1)),c=(n=oe.analyzeSplitToContent(c,","))==null?void 0:n.map(m=>((m==null?void 0:m[(m==null?void 0:m.length)-1])===","&&(m=m==null?void 0:m.slice(0,(m==null?void 0:m.length)-1)),m));let d=(s=(i=(r=ip.value)==null?void 0:r.filter(m=>{var b;return(m==null?void 0:m.path)===((b=a==null?void 0:a.groupName)==null?void 0:b[0])}))==null?void 0:i[0])==null?void 0:s.children;return d=(d==null?void 0:d.filter(m=>c==null?void 0:c.find(b=>b===(m==null?void 0:m.name))))??[],(c==null?void 0:c.length)>0&&(d==null?void 0:d.length)===0&&(c==null||c.forEach(m=>{d.push({url:"file:///"+(m==null?void 0:m.replaceAll("\\","/"))})})),h.push({key:"backGround",contents:d}),h}return a==null?void 0:a.contents},cp=a=>{const l=uc(a==null?void 0:a.filter);return l?dc(a==null?void 0:a.contents,{position:l}):a==null?void 0:a.contents},up=a=>{const l=uc(a==null?void 0:a.filter);return l?dc(a==null?void 0:a.contents,{size:l}):a==null?void 0:a.contents},dp=a=>{if((a==null?void 0:a.filter)!==void 0&&(a==null?void 0:a.filter)!==null&&(a==null?void 0:a.filter)!==""){let l=a==null?void 0:a.contents;const n=Number(a==null?void 0:a.filter);return l.push({key:"textSize",contents:Number.isNaN(n)?a==null?void 0:a.filter:n}),l}return a==null?void 0:a.contents},pp=a=>{if((a==null?void 0:a.filter)!==void 0&&(a==null?void 0:a.filter)!==null&&(a==null?void 0:a.filter)!==""){let l=a==null?void 0:a.contents;return l.push({key:"textRGBA",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},fp=a=>{var n;return(a==null?void 0:a.filter.toUpperCase())==="ALL"||(a==null?void 0:a.filter.toUpperCase())==="NONE"?a==null?void 0:a.contents:(n=a==null?void 0:a.contents)==null?void 0:n.map(r=>{var i;return(r==null?void 0:r.key)==="tableContents"&&(r.contents=(i=r.contents)==null?void 0:i.slice(0,parseInt(a==null?void 0:a.filter))),r})},hp=async a=>{var l,n,r,i,s,h,c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me,_e,z;if((a==null?void 0:a.filter)==="Random")return(l=a==null?void 0:a.contents)==null?void 0:l.map(Y=>((Y==null?void 0:Y.key)==="tableContents"&&(Y.contents=oe.shuffle(Y.contents)),Y));if((a==null?void 0:a.filter)==="Auto"){let ne=(r=(n=a==null?void 0:a.contents)==null?void 0:n.find(ge=>(ge==null?void 0:ge.key)==="header"))==null?void 0:r.contents;Array.isArray(ne==null?void 0:ne[0])&&(ne=ne==null?void 0:ne[0]),ne=oe.getColumnChild(ne);let Y=ne==null?void 0:ne.filter(ge=>(ge==null?void 0:ge.filter)&&(ge==null?void 0:ge.filter)!==""),te=new Map,ye=[];Y==null||Y.forEach(ge=>{var ze,Le;te.get((ze=ge==null?void 0:ge.menus)==null?void 0:ze.join("/"))||(te.set((Le=ge==null?void 0:ge.menus)==null?void 0:Le.join("/"),ge),ye.push(ge))});let $e=(s=(i=pn==null?void 0:pn.value)==null?void 0:i.find(ge=>(ge==null?void 0:ge.condition)==="child"))==null?void 0:s.value,de=ye==null?void 0:ye.map(ge=>{var ze,Le,ra;return ge=(ze=ge==null?void 0:ge.menus)==null?void 0:ze.join("/"),(ge==null?void 0:ge[(ge==null?void 0:ge.length)-1])==="/"&&((ra=(Le=pn==null?void 0:pn.value)==null?void 0:Le.find(Ca=>(Ca==null?void 0:Ca.condition)==="child"))==null?void 0:ra.parentContent)+"/"!==ge?ge=ge+$e:(ge==null?void 0:ge[(ge==null?void 0:ge.length)-1])==="/"&&(ge=ge==null?void 0:ge.slice(0,(ge==null?void 0:ge.length)-1)),ge}),T=ye==null?void 0:ye.map(ge=>ge==null?void 0:ge.groups),ie=de==null?void 0:de.map(async ge=>{let ze=await Jr(ge,!1);return{path:ge,contents:ze}});ie=await Promise.all(ie);let U=ie==null?void 0:ie.map((ge,ze)=>{var ra,Ca,Q,ca,ue,pa,Se;let Le=(ra=ge==null?void 0:ge.contents)==null?void 0:ra.filter(ce=>{var De,Ke;return(ce==null?void 0:ce.name)===((Ke=T==null?void 0:T[ze])==null?void 0:Ke[((De=T==null?void 0:T[ze])==null?void 0:De.length)-1])});return Le=(ca=(Q=(Ca=Le==null?void 0:Le[0])==null?void 0:Ca.compData)==null?void 0:Q.find(ce=>(ce==null?void 0:ce.key)==="tableContents"))==null?void 0:ca.contents,(ge==null?void 0:ge.path)===((pa=(ue=pn==null?void 0:pn.value)==null?void 0:ue.find(ce=>(ce==null?void 0:ce.condition)==="child"))==null?void 0:pa.parentContent)&&(Le=((Se=Le==null?void 0:Le.map(ce=>{for(let De in ce)if(ce[De]===$e)return ce}))==null?void 0:Se.filter(ce=>ce))??[]),Le??[]});if(U=U==null?void 0:U.map(ge=>(ge=ge==null?void 0:ge.map(ze=>{var ra;let Le={};for(let Ca in ze)if(Y!=null&&Y.find(Q=>{var ca,ue;return((ue=(ca=Q==null?void 0:Q.words)==null?void 0:ca[0])==null?void 0:ue.replaceAll("'",""))===Ca})){let Q=(ra=Y==null?void 0:Y.find(ca=>{var ue,pa;return((pa=(ue=ca==null?void 0:ca.words)==null?void 0:ue[0])==null?void 0:pa.replaceAll("'",""))===Ca}))==null?void 0:ra.prop;Le[Q]=ze==null?void 0:ze[Ca]}return Le}),ge)),U=oe.cartesianProduct(U),Array.isArray(U==null?void 0:U[0])&&(U=U==null?void 0:U[0]),(U==null?void 0:U.length)>0&&((u=(c=(h=Y==null?void 0:Y[0])==null?void 0:h.menus)==null?void 0:c.join("/"))==null?void 0:u[((b=(m=(d=Y==null?void 0:Y[0])==null?void 0:d.menus)==null?void 0:m.join("/"))==null?void 0:b.length)-1])==="/")return(C=a==null?void 0:a.contents)==null?void 0:C.map(ze=>{var Le;return(ze==null?void 0:ze.key)==="tableContents"&&(U==null?void 0:U.length)>0&&(ze.contents=((Le=ze.contents)==null?void 0:Le.length)>0?ze.contents:U),ze})}if((a==null?void 0:a.filter)==="Manual"){let ne=[],Y=[],te=(k=(M=a==null?void 0:a.contents)==null?void 0:M.find(T=>(T==null?void 0:T.key)==="filter"))==null?void 0:k.contents;(te==null?void 0:te[(te==null?void 0:te.length)-1])===")"?te=(O=(W=te==null?void 0:te.replace("(",yr))==null?void 0:W.split(yr))==null?void 0:O[0]:te="",te!==""&&(ne=((L=(j=te==null?void 0:te.split("*"))==null?void 0:j[0])==null?void 0:L.split(":"))??[],Y=((E=(g=(w=(x=(_=te==null?void 0:te.split("*"))==null?void 0:_[1])==null?void 0:x.replace("{",yr))==null?void 0:w.split(yr))==null?void 0:g[0])==null?void 0:E.split(":"))??[]);let ye=(V=(P=a==null?void 0:a.contents)==null?void 0:P.find(T=>(T==null?void 0:T.key)==="filter"))==null?void 0:V.contents;ye=(J=(ee=ye==null?void 0:ye.replace("(",yr))==null?void 0:ee.split(yr))==null?void 0:J[1],ye=ye==null?void 0:ye.slice(0,(ye==null?void 0:ye.length)-1);let $e=(me=a==null?void 0:a.contents)==null?void 0:me.map(T=>{var ie,U,ge,ze,Le,ra,Ca,Q,ca;return(T==null?void 0:T.key)==="header"&&((ie=T==null?void 0:T.contents)!=null&&ie.every(ue=>(ue==null?void 0:ue.mainKey)!==!0)&&Array.isArray(T==null?void 0:T.contents)&&!Array.isArray((U=T==null?void 0:T.contents)==null?void 0:U[0])?T.contents=(ge=T==null?void 0:T.contents)==null?void 0:ge.map((ue,pa)=>{var Se,ce,De;return ue!=null&&ue.isMainPath||(pa===0?(ue.mainKey=!0,ue.formType="Select",ue.bindMenus=ne,ue.groups=((Se=ue.groups)==null?void 0:Se.length)===0?Y:ue.groups,ue.words=((ce=ue.words)==null?void 0:ce.length)===0?[ue==null?void 0:ue.prop]:ue.words,ue.filter=ye,(!(ue!=null&&ue.menus)||((De=ue==null?void 0:ue.menus)==null?void 0:De.length)===0)&&(ue.menus=ne)):(ue.mainKey=!1,ue.bindMenus=ne)),ue}):Array.isArray((ze=T==null?void 0:T.contents)==null?void 0:ze[0])&&((Ca=(ra=(Le=T==null?void 0:T.contents)==null?void 0:Le[0])==null?void 0:ra.filter(()=>(ne==null?void 0:ne.length)>0))==null?void 0:Ca.length)>0&&(T.contents[0]=(ca=(Q=T==null?void 0:T.contents)==null?void 0:Q[0])==null?void 0:ca.map((ue,pa)=>{var Se,ce,De;return ue!=null&&ue.isMainPath||(pa===0?(ue.mainKey=!0,ue.formType="Select",ue.bindMenus=ne,ue.groups=((Se=ue.groups)==null?void 0:Se.length)===0?Y:ue.groups,ue.words=((ce=ue.words)==null?void 0:ce.length)===0?[ue==null?void 0:ue.prop]:ue.words,ue.filter=ye,(!(ue!=null&&ue.menus)||Array.isArray(ue==null?void 0:ue.menus)&&((De=ue==null?void 0:ue.menus)==null?void 0:De.length)===0)&&(ne==null?void 0:ne.length)>0&&(ue.menus=ne)):(ue.mainKey=!1,ue.bindMenus=ne)),ue}))),T}),de=(_e=$e==null?void 0:$e.find(T=>(T==null?void 0:T.key)==="header"))==null?void 0:_e.contents;if(Array.isArray(de==null?void 0:de[0])&&(de=de==null?void 0:de[0]),de=oe.getColumnChild(de),de!=null&&de.some(T=>{var ie,U;return((U=T==null?void 0:T.menus)==null?void 0:U[((ie=T==null?void 0:T.menus)==null?void 0:ie.length)-1])===""})){let T=(z=pn==null?void 0:pn.value)==null?void 0:z.find(ie=>(ie==null?void 0:ie.condition)==="child");$e=lp($e,T)}return $e}if((a==null?void 0:a.filter)==="Chart"){let ne=a==null?void 0:a.contents;return ne.push({key:"newType",contents:"Chart"}),ne}if((a==null?void 0:a.filter)==="Carousel"){let ne=a==null?void 0:a.contents;return ne.push({key:"newType",contents:"Carousel"}),ne}return a==null?void 0:a.contents},vp=a=>{if((a==null?void 0:a.filter)==="Ordin"){let l=a==null?void 0:a.contents;return l.push({key:"enableWrap",contents:1}),l}if((a==null?void 0:a.filter)==="Block"){let l=a==null?void 0:a.contents;return l.push({key:"enableWrap",contents:2}),l}if((a==null?void 0:a.filter)==="Text"){let l=a==null?void 0:a.contents;return l.push({key:"enableWrap",contents:3}),l}if((a==null?void 0:a.filter)==="Bar"||(a==null?void 0:a.filter)==="Pie"||(a==null?void 0:a.filter)==="Line"||(a==null?void 0:a.filter)==="Histogram"||(a==null?void 0:a.filter)==="Scatter"){let l=a==null?void 0:a.contents;return l.push({key:"ChartType",contents:{type:a==null?void 0:a.filter,title:""}}),l}return a==null?void 0:a.contents},mp=a=>{var r,i,s,h,c,d,m,b,u,C,M,k;let l=a==null?void 0:a.filter;if(l!=null&&l.includes("*")&&(l="({"+((i=(r=l==null?void 0:l.replace(":",yr))==null?void 0:r.split(yr))==null?void 0:i[1])),l=(s=l==null?void 0:l.replaceAll("{",""))==null?void 0:s.replaceAll("}",""),(c=(h=l==null?void 0:l.split("="))==null?void 0:h[1])!=null&&c.includes("$")){(l==null?void 0:l[0])==="("&&(l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1));let W=(d=l==null?void 0:l.split("="))==null?void 0:d[0],O=(m=l==null?void 0:l.split("="))==null?void 0:m[1];(b=O==null?void 0:O.slice(1,O==null?void 0:O.length))!=null&&b.includes("$")&&(O=(M=(C=(u=pn==null?void 0:pn.value)==null?void 0:u.filter(j=>(j==null?void 0:j.condition)==="child"))==null?void 0:C[0])==null?void 0:M.value),l=W+"="+O}if((l==null?void 0:l[0])!=="("&&(l="("+l+")"),l.slice(1,(l==null?void 0:l.length)-1)==="undefined")return a==null?void 0:a.contents;let n=oe.calculatorAndToOr(l);if((n==null?void 0:n.length)>0){let W=[];return n==null||n.forEach(j=>{let L={};for(let _ in j){let x=_;x!=null&&x.includes("[")||(L[x]=j[_])}W.push(L)}),(k=a==null?void 0:a.contents)==null?void 0:k.map(j=>{var _,x,w;let L=(x=(_=a==null?void 0:a.contents)==null?void 0:_.find(g=>(g==null?void 0:g.key)==="header"))==null?void 0:x.contents;if(L=(w=oe.getEqualChild(L))==null?void 0:w.filter(g=>(g==null?void 0:g.label)!=="操作"),(j==null?void 0:j.key)==="tableContents"){let E=oe.tableToForm(j==null?void 0:j.contents,L);W==null||W.forEach(P=>{var V,ee;for(let J in P)!((V=E==null?void 0:E[0])!=null&&V.find(me=>{var _e;return(me==null?void 0:me.key)===J||((_e=me==null?void 0:me.key)==null?void 0:_e.includes(J))}))&&!(E!=null&&E.find(me=>{var _e;return(me==null?void 0:me.key)===J||((_e=me==null?void 0:me.key)==null?void 0:_e.includes(J))}))||(((ee=P[J])==null?void 0:ee[0])!=="!"?E=E==null?void 0:E.filter(me=>{var _e,z;return((_e=me==null?void 0:me.find(ne=>{var Y;return(ne==null?void 0:ne.key)===J||((Y=ne==null?void 0:ne.key)==null?void 0:Y.includes(J))}))==null?void 0:_e.value)===P[J]||Array.isArray(P==null?void 0:P[J])&&((z=P==null?void 0:P[J])==null?void 0:z.find(ne=>{var Y;return((Y=me==null?void 0:me.find(te=>{var ye;return(te==null?void 0:te.key)===J||((ye=te==null?void 0:te.key)==null?void 0:ye.includes(J))}))==null?void 0:Y.value)===ne}))}):E=E==null?void 0:E.filter(me=>{var _e;return((_e=me==null?void 0:me.find(z=>{var ne;return(z==null?void 0:z.key)===J||((ne=z==null?void 0:z.key)==null?void 0:ne.includes(J))}))==null?void 0:_e.value)!==P[J]}))}),(E==null?void 0:E.length)===0?j.contents=[]:j.contents=E==null?void 0:E.map(P=>{let V={};return P==null||P.forEach(ee=>{V[ee==null?void 0:ee.key]=ee==null?void 0:ee.value}),V})}return j})}return a==null?void 0:a.contents},yp=a=>a==null?void 0:a.contents,gp=a=>a==null?void 0:a.contents,bp=a=>{var l,n,r,i;if((a==null?void 0:a.filter)!==""&&(a!=null&&a.filter)){let s=(r=(n=a==null?void 0:a.filter)==null?void 0:n.slice(1,((l=a==null?void 0:a.filter)==null?void 0:l.length)-1))==null?void 0:r.split(",");return(i=a==null?void 0:a.contents)==null?void 0:i.map(c=>((c==null?void 0:c.key)==="header"&&(c.contents=xt(c.contents,s)),c))}return a==null?void 0:a.contents},kp=a=>{var n,r,i,s,h;let l=(a==null?void 0:a.filter)??"";if(l!==""){let c=(r=(n=l==null?void 0:l.replace("(",yr))==null?void 0:n.split(yr))==null?void 0:r[1];c=c==null?void 0:c.slice(0,(c==null?void 0:c.length)-1),(c==null?void 0:c[(c==null?void 0:c.length)-1])===")"&&(c=c==null?void 0:c.slice(1,(c==null?void 0:c.length)-1)),c=(i=oe.analyzeSplitToContent(c,","))==null?void 0:i.map(u=>((u==null?void 0:u[(u==null?void 0:u.length)-1])===","&&(u=u==null?void 0:u.slice(0,(u==null?void 0:u.length)-1)),u));let d=c==null?void 0:c[0];(d==null?void 0:d[0])==="("&&(d=d==null?void 0:d.slice(1,(d==null?void 0:d.length)-1));let m=(c==null?void 0:c[1])??"Up",b=(s=a==null?void 0:a.contents)==null?void 0:s.map(u=>{var C,M;if(m==="Up"){if((u==null?void 0:u.key)==="extraButton"){let k=(C=d==null?void 0:d.split(","))==null?void 0:C.map(W=>({label:W,prop:W}));u.contents=[...k??[],...u.contents]}}else if(m==="Line"&&(u==null?void 0:u.key)==="rowButton"){let k=(M=d==null?void 0:d.split(","))==null?void 0:M.map(W=>({label:W,prop:W}));u.contents=[...k??[],...u.contents]}return u});if(m==="Bottom"||m==="Down"){let u=(h=d==null?void 0:d.split(","))==null?void 0:h.map(C=>({label:C,prop:C}));b.push({key:"bottomButton",contents:u})}return b}return a==null?void 0:a.contents},xp=a=>a==null?void 0:a.contents,wp=a=>{var n;let l=(a==null?void 0:a.filter)??"";return(l==null?void 0:l[0])==="{"&&(l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1)),l!==""?(n=a==null?void 0:a.contents)==null?void 0:n.map(i=>{var s;return(i==null?void 0:i.key)==="rowButton"&&(i.contents=(s=l==null?void 0:l.split(","))==null?void 0:s.map(h=>({label:h,prop:h}))),i}):a==null?void 0:a.contents},_p=a=>{var n;let l=(a==null?void 0:a.filter)??"";if((l==null?void 0:l[0])==="{"&&(l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1)),l!==""){let r=a==null?void 0:a.contents,i=(n=l==null?void 0:l.split(","))==null?void 0:n.map(s=>({label:s,prop:s}));return r.push({key:"bottomButton",contents:i}),r}return a==null?void 0:a.contents},Sp=a=>{if((a==null?void 0:a.filter)==="Read"){let l=a==null?void 0:a.contents;return l=l==null?void 0:l.map(n=>{var r;return(n==null?void 0:n.key)==="formContent"&&(n.contents=(r=n.contents)==null?void 0:r.map(i=>(i.isNoClick=!0,i))),n}),l!=null&&l.find(n=>(n==null?void 0:n.key)==="tableContents")&&(l==null||l.push({key:"isEdit",contents:!1}),l=l==null?void 0:l.filter(n=>(n==null?void 0:n.key)!=="extraButton"&&(n==null?void 0:n.key)!=="rowButton")),l}return a==null?void 0:a.contents},Ep=a=>{var l;if(a!=null&&a.filter){const n=parseInt(a==null?void 0:a.filter);return!n||Number.isNaN(n)?a==null?void 0:a.contents:(l=a==null?void 0:a.contents)==null?void 0:l.map(i=>{var s;return(i==null?void 0:i.key)==="formContent"&&(i.contents=(s=i.contents)==null?void 0:s.map(h=>(h.width=n,h))),i})}return a==null?void 0:a.contents},Cp=a=>{var l,n,r,i;if(((l=a==null?void 0:a.filter)==null?void 0:l[0])!=="["){const s=parseInt(a==null?void 0:a.filter);return!s||Number.isNaN(s)?a==null?void 0:a.contents:(n=a==null?void 0:a.contents)==null?void 0:n.map(c=>{var d;return(c==null?void 0:c.key)==="formContent"&&(c.contents=(d=c.contents)==null?void 0:d.map(m=>(m.width=s,m))),c})}if(((r=a==null?void 0:a.filter)==null?void 0:r[0])==="["){let s=Ni(a==null?void 0:a.filter),h=Array.isArray(s)?s.map(d=>parseInt(d)).filter(d=>!!d&&!Number.isNaN(d)):[];return h.length?(i=a==null?void 0:a.contents)==null?void 0:i.map(d=>{if((d==null?void 0:d.key)==="formContent"){const m=d.contents??[];d.contents=m.map((b,u)=>{const C=u+1;let M=0,k=0;for(let O=0;O<h.length;O++){if(k+=h[O],C<=k){M=O;break}O===h.length-1&&(M=h.length-1)}const W=h[M]||h[h.length-1]||1;return b.width=W,b})}return d}):a==null?void 0:a.contents}return a==null?void 0:a.contents},Dp=a=>{var l;if((a==null?void 0:a.filter)!==""){let n=a==null?void 0:a.filter;return(n==null?void 0:n[0])==="("&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1)),n=n==null?void 0:n.split(","),(l=a==null?void 0:a.contents)==null?void 0:l.map(i=>{var s,h,c;return(i==null?void 0:i.key)==="header"&&(Array.isArray((s=i==null?void 0:i.contents)==null?void 0:s[0])?i.contents[0]=(c=i.contents[0])==null?void 0:c.map(d=>(n!=null&&n.find(m=>m===(d==null?void 0:d.prop))&&(d.fixed="left"),d)):i.contents=(h=i.contents)==null?void 0:h.map(d=>(n!=null&&n.find(m=>m===(d==null?void 0:d.prop))&&(d.fixed="left"),d))),i})}return a==null?void 0:a.contents},Tp=a=>{var l;if((a==null?void 0:a.filter)!==""){let n=a==null?void 0:a.filter;(n==null?void 0:n[0])==="("&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1)),n=n==null?void 0:n.split(",");const r=s=>(n!=null&&n.find(h=>h===(s==null?void 0:s.prop))&&(s.required=!0),s!=null&&s.children&&Array.isArray(s.children)&&(s.children=s.children.map(h=>r(h))),s);return(l=a==null?void 0:a.contents)==null?void 0:l.map(s=>{var h,c,d;return(s==null?void 0:s.key)==="header"&&(Array.isArray((h=s==null?void 0:s.contents)==null?void 0:h[0])?s.contents[0]=(d=s.contents[0])==null?void 0:d.map(m=>r(m)):s.contents=(c=s.contents)==null?void 0:c.map(m=>r(m))),s})}return a==null?void 0:a.contents},Bp=async a=>{var r,i,s,h,c,d,m,b,u,C,M,k,W,O,j,L,_;const l=A.useUnit(A.pinia),{chooseTitle:n}=A.storeToRefs(l);if((a==null?void 0:a.filter)==="true"){let x=await Jr(((i=(r=n==null?void 0:n.value)==null?void 0:r[0])==null?void 0:i.parentContent)??((h=(s=n==null?void 0:n.value)==null?void 0:s[0])==null?void 0:h.relatedContent),!1),w=(d=(c=n==null?void 0:n.value)==null?void 0:c[0])==null?void 0:d.value;(b=(m=x==null?void 0:x[0])==null?void 0:m.compData)!=null&&b.find(V=>(V==null?void 0:V.key)==="header")?x=(u=x==null?void 0:x[0])==null?void 0:u.compData:x=(M=(C=x==null?void 0:x.filter(V=>{var ee;return(ee=V==null?void 0:V.compData)==null?void 0:ee.find(J=>(J==null?void 0:J.key)==="header")}))==null?void 0:C[0])==null?void 0:M.compData;let g=(k=x==null?void 0:x.find(V=>(V==null?void 0:V.key)==="header"))==null?void 0:k.contents;Array.isArray(g==null?void 0:g[0])&&(g=g==null?void 0:g[0]),g=((W=g==null?void 0:g.find(V=>V==null?void 0:V.isMainKey))==null?void 0:W.prop)??((O=g==null?void 0:g[0])==null?void 0:O.prop);let E=(L=(j=x==null?void 0:x.find(V=>(V==null?void 0:V.key)==="tableContents"))==null?void 0:j.contents)==null?void 0:L.find(V=>(V==null?void 0:V[g])===w);return(_=a==null?void 0:a.contents)==null?void 0:_.map(V=>{var ee;return(V==null?void 0:V.key)==="formContent"&&(V.contents=(ee=V.contents)==null?void 0:ee.map(J=>(J.value=E==null?void 0:E[J==null?void 0:J.prop],J))),V})}return a==null?void 0:a.contents},Np=a=>{var l,n,r,i,s;if((l=a==null?void 0:a.extra)!=null&&l.row){let h=a==null?void 0:a.filter;if(h!=null&&h.includes("*")&&(h="({"+((r=(n=h==null?void 0:h.replace("{",yr))==null?void 0:n.split(yr))==null?void 0:r[1])),h=(i=h==null?void 0:h.replaceAll("{",""))==null?void 0:i.replaceAll("}",""),(h==null?void 0:h[0])!=="("&&(h="("+h+")"),h.slice(1,(h==null?void 0:h.length)-1)==="undefined")return a==null?void 0:a.contents;let c=oe.calculatorAndToOr(h),d=c==null?void 0:c[0],m=(s=a==null?void 0:a.extra)==null?void 0:s.row,b=[];for(let u in d)(d==null?void 0:d[u])===(m==null?void 0:m[u])?b.push(!0):b.push(!1);return b!=null&&b.every(u=>u===!0)?a==null?void 0:a.contents:[]}else return a==null?void 0:a.contents},Ap=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"tab",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},zp=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"choice",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Mp=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"fixType",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Ip=a=>{var l;if(a!=null&&a.filter){let n=a==null?void 0:a.contents,r=a==null?void 0:a.filter;return(r==null?void 0:r[0])==="("&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1)),r=(l=oe.analyzeSplitToContent(r,","))==null?void 0:l.map(i=>((i==null?void 0:i[(i==null?void 0:i.length)-1])===","&&(i=i==null?void 0:i.slice(0,(i==null?void 0:i.length)-1)),i)),n.push({key:"stepName",contents:r}),n}return a==null?void 0:a.contents},Op=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"step",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},cc={onNumSlice:fp,onRandomContents:hp,onConditionContents:mp,onFatherPaceContents:yp,onPaceContents:gp,onMainTagContents:bp,onButtonContents:kp,onPamButtonContents:xp,onRowButtonContents:wp,onRelated:Bp,onRowNum:Cp,onFixRow:Dp,onReqItem:Tp,onBottomButtonContents:_p,onConditionContent:Np,onTabs:Ap,onSinChoice:zp,onTextSize:dp,onTextRGBA:pp,onPosition:cp,onSize:up,onShowType:Mp,onStepName:Ip,onStep:Op,onInterfaceTypeContents:vp,onBackGround:sp,onMaxColumn:Ep,onEditRead:Sp,onShowHide:tp},Lp=async(a,l,n="")=>{var h,c,d,m,b,u,C,M,k,W,O,j;let r="";if(((h=a==null?void 0:a.find(L=>(L==null?void 0:L.key)==="filter"))==null?void 0:h.contents)!==""&&(r=(c=a==null?void 0:a.find(L=>(L==null?void 0:L.key)==="filter"))==null?void 0:c.contents),r===""||!r)return a;(r==null?void 0:r[0])==="("?r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1):(r=(m=(d=r==null?void 0:r.replace("(",yr))==null?void 0:d.split(yr))==null?void 0:m[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1));let i=(b=oe.analyzeSplitToContent(r,","))==null?void 0:b.map(L=>((L==null?void 0:L[(L==null?void 0:L.length)-1])===","&&(L=L==null?void 0:L.slice(0,(L==null?void 0:L.length)-1)),L!=null&&L.includes("(")||(L=L==null?void 0:L.replaceAll(":","=")),L)),s=a;for(let L in i){let _,x="";_=(M=(C=(u=i==null?void 0:i[L])==null?void 0:u.replace("=",yr))==null?void 0:C.split(yr))==null?void 0:M[0],x=(O=(W=(k=i==null?void 0:i[L])==null?void 0:k.replace("=",yr))==null?void 0:W.split(yr))==null?void 0:O[1];let w=(j=En==null?void 0:En.find(g=>(g==null?void 0:g.key)===_))==null?void 0:j.value;if(w){const g=cc[w];s=await g({contents:s,filter:x,extra:l,groupName:n})}}return s},Po=async(a,l,n="")=>{var c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee;let r="";if(((c=a==null?void 0:a.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:c.contents)!==""&&(r=(d=a==null?void 0:a.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:d.contents),r===""||!r)return a;(r==null?void 0:r[0])===","&&(r=r==null?void 0:r.slice(1,r==null?void 0:r.length)),(r==null?void 0:r[0])==="("?r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1):(r==null?void 0:r[0])==="@"||(r=(b=(m=r==null?void 0:r.replace("(",yr))==null?void 0:m.split(yr))==null?void 0:b[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1));let i=(u=oe.analyzeSplitToContent(r,","))==null?void 0:u.map(J=>((J==null?void 0:J[(J==null?void 0:J.length)-1])===","&&(J=J==null?void 0:J.slice(0,(J==null?void 0:J.length)-1)),J!=null&&J.includes("(")||(J=J==null?void 0:J.replaceAll(":","=")),J)),s=a,h=new Map;i==null||i.forEach(J=>{var _e,z,ne;let me=(_e=J==null?void 0:J.split("="))==null?void 0:_e[0];if(me==="@MainParam"&&h.get(me)){let Y=h.get(me);Y=Y==null?void 0:Y.slice(0,(Y==null?void 0:Y.length)-1);let te=(ne=(z=J==null?void 0:J.replace("{",yr))==null?void 0:z.split(yr))==null?void 0:ne[1];te=Y+","+te,h.set(me,te)}else me==="@Button"&&h.get(me)?h.set(J,J):h.set(me,J)}),i=Array.from(h.values()),i=i==null?void 0:i.sort((J,me)=>{var _e,z;return((_e=En==null?void 0:En.find(ne=>me==null?void 0:me.includes(ne==null?void 0:ne.key)))==null?void 0:_e.order)-((z=En==null?void 0:En.find(ne=>J==null?void 0:J.includes(ne==null?void 0:ne.key)))==null?void 0:z.order)});for(let J in i){let me,_e="";(C=i==null?void 0:i[J])!=null&&C.includes("(")&&((M=i==null?void 0:i[J])!=null&&M.includes("@If"))?(me=(O=(W=(k=i==null?void 0:i[J])==null?void 0:k.replace("(",yr))==null?void 0:W.split(yr))==null?void 0:O[0],_e="("+((_=(L=(j=i==null?void 0:i[J])==null?void 0:j.replace("(",yr))==null?void 0:L.split(yr))==null?void 0:_[1])):(me=(g=(w=(x=i==null?void 0:i[J])==null?void 0:x.replace("=",yr))==null?void 0:w.split(yr))==null?void 0:g[0],_e=(V=(P=(E=i==null?void 0:i[J])==null?void 0:E.replace("=",yr))==null?void 0:P.split(yr))==null?void 0:V[1]);let z=(ee=En==null?void 0:En.find(ne=>(ne==null?void 0:ne.key)===me))==null?void 0:ee.value;if(z){const ne=cc[z];s=await ne({contents:s,filter:_e,extra:l,groupName:n})}}return s},uc=a=>{if(a==null)return null;const l=String(a).trim();if(!l.startsWith("(")||!l.endsWith(")"))return null;const n=l.slice(1,-1).split(",").map(r=>Number(r.trim()));return n.length<2||n.some(r=>Number.isNaN(r))?null:[n[0],n[1]]},dc=(a,l)=>{var W,O,j,L,_;const n=Array.isArray(a)?a:[],r=n.find(x=>(x==null?void 0:x.key)==="formContent"),i=Array.isArray(r==null?void 0:r.contents)?r.contents:[],s=((W=n.find(x=>(x==null?void 0:x.key)==="_gridLayoutMeta"))==null?void 0:W.contents)??{},h=(i==null?void 0:i[0])??{};let c=((O=l==null?void 0:l.position)==null?void 0:O[0])??(s==null?void 0:s._positionStartRow)??(h==null?void 0:h._positionStartRow),d=((j=l==null?void 0:l.position)==null?void 0:j[1])??(s==null?void 0:s._positionRowSpan)??(h==null?void 0:h._positionRowSpan);(!c||Number.isNaN(c)||c<1)&&(c=1),(!d||Number.isNaN(d)||d<1)&&(d=1);let m=((L=l==null?void 0:l.size)==null?void 0:L[0])??(s==null?void 0:s._sizeStart)??(h==null?void 0:h._sizeStart),b=((_=l==null?void 0:l.size)==null?void 0:_[1])??(s==null?void 0:s._sizeEnd)??(h==null?void 0:h._sizeEnd);(m===void 0||Number.isNaN(m))&&(m=0),(b===void 0||Number.isNaN(b))&&(b=1),m=Math.max(0,Math.min(1,m)),b=Math.max(0,Math.min(1,b)),b<=m&&(m=0,b=1);const u=b-m,C=Math.max(1,Math.round(1/u));let M=n.map(x=>{if((x==null?void 0:x.key)!=="formContent")return x;const w=Array.isArray(x==null?void 0:x.contents)?x.contents:[];return{...x,contents:w.map(g=>({...g,width:C,_positionStartRow:c,_positionRowSpan:d,_sizeStart:m,_sizeEnd:b}))}});const k={_positionStartRow:c,_positionRowSpan:d,_sizeStart:m,_sizeEnd:b};return M.some(x=>(x==null?void 0:x.key)==="_gridLayoutMeta")?M=M.map(x=>(x==null?void 0:x.key)==="_gridLayoutMeta"?{...x,contents:k}:x):M.push({key:"_gridLayoutMeta",contents:k}),M};let yo="$R";const Rp=A.useUnit(A.pinia),{selectTitle:$p}=A.storeToRefs(Rp);let Vp=[{label:"新增",prop:"新增"},{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],Pp=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"},{label:"复制新增",prop:"复制新增"},{label:"删除",prop:"删除"}],Fp=[{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],jp=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"}];const ps=async(a,l,n=!0)=>{let r=[],i=a==null?void 0:a.map(async s=>{var u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae,se,Xe,Ze,Ha,_a,Qa,Pe,Re,Ue,Ne,Ie,ul,_l,Tl,jl,Cl,Yl,aa,Ka,ma,il,Aa,sl,rl,qe,Ga,hl,pe,na,Sa;let h=(k=(M=(C=(u=s==null?void 0:s.contents)==null?void 0:u.find(la=>{var nl;return(nl=la==null?void 0:la.key)==null?void 0:nl.includes("struct")}))==null?void 0:C.value)==null?void 0:M[0])==null?void 0:k.类型,c=Object.values(s==null?void 0:s.name);c=c==null?void 0:c.reverse();let d=(W=s==null?void 0:s.contents)==null?void 0:W.map(la=>la==null?void 0:la.key),m={comp:h,isShow:s==null?void 0:s.is_show,name:c==null?void 0:c[0],id:s==null?void 0:s.object_id,order_no:s==null?void 0:s.order_no,relatedTables:d,menuFilter:(O=s==null?void 0:s.filter)==null?void 0:O.menuFilter,status:s==null?void 0:s.status,fatherSyncContents:(j=s==null?void 0:s.filter)==null?void 0:j.fatherSyncs,relatedQuotes:(L=s==null?void 0:s.filter)==null?void 0:L.quotes,sonSyncContents:(_=s==null?void 0:s.filter)==null?void 0:_.sonSyncs,nameContents:(x=A.cloneDeep(c))==null?void 0:x.reverse(),isHidden:!1};for(let la in c)parseInt(la)>=1&&(m[`name${parseInt(la)-1}`]=c[la]);let b=Array.isArray((w=s==null?void 0:s.filter)==null?void 0:w.menuFilter)?(g=s==null?void 0:s.filter)==null?void 0:g.menuFilter:[];if(((E=b==null?void 0:b.filter(la=>la==null?void 0:la.includes("@If")))==null?void 0:E.length)>0){let la=b==null?void 0:b.filter(Me=>Me==null?void 0:Me.includes("@If"));la=la==null?void 0:la[0],la=(V=(P=la==null?void 0:la.replace("(",yo))==null?void 0:P.split(yo))==null?void 0:V[1],la=la==null?void 0:la.slice(0,(la==null?void 0:la.length)-1),la!=null&&la.includes("*")&&(la=(J=(ee=la==null?void 0:la.replace("{",yo))==null?void 0:ee.split(yo))==null?void 0:J[1],la=la==null?void 0:la.replace("}","")),la=oe.calculatorAndToOr(la);let nl=(l==null?void 0:l.originPath)??"";(nl==null?void 0:nl[(nl==null?void 0:nl.length)-1])==="/"&&(nl=nl==null?void 0:nl.slice(0,(nl==null?void 0:nl.length)-1));let Je=await Jr(nl,!1),Fa=(me=Je==null?void 0:Je.filter(Me=>(Me==null?void 0:Me.comp)==="Table"))==null?void 0:me[0];Fa=(z=(_e=Fa==null?void 0:Fa.compData)==null?void 0:_e.find(Me=>(Me==null?void 0:Me.key)==="tableContents"))==null?void 0:z.contents;let wa=(Y=(ne=$p.value)==null?void 0:ne.find(Me=>(Me==null?void 0:Me.condition)==="child"))==null?void 0:Y.value;Fa=(te=Fa==null?void 0:Fa.map(Me=>{for(let Ra in Me)if((Me==null?void 0:Me[Ra])===wa)return Me}))==null?void 0:te.filter(Me=>Me),Fa=Fa==null?void 0:Fa[0],la=la==null?void 0:la[0];let Oa=[];for(let Me in la){let Ra="";Wa.isObject(Fa)&&(Ra=($e=(ye=Object.keys(Fa))==null?void 0:ye.filter(Va=>Va==null?void 0:Va.includes("."+Me)))==null?void 0:$e[0]),Ra!==""&&(Fa!=null&&Fa[Ra])&&(la==null?void 0:la[Me])===(Fa==null?void 0:Fa[Ra])||Fa!=null&&Fa[Me]&&(la==null?void 0:la[Me])===(Fa==null?void 0:Fa[Me])?Oa.push(!0):Oa.push(!1)}if(Oa!=null&&Oa.some(Me=>Me===!1)&&((T=l==null?void 0:l.originPath)==null?void 0:T[((de=l==null?void 0:l.originPath)==null?void 0:de.length)-1])!=="/")return}if(h==="Table"||h==="Method"){!n&&((ie=m==null?void 0:m.fatherSyncContents)==null?void 0:ie.length)>0;let la=((U=s==null?void 0:s.contents)==null?void 0:U.find(We=>{var Ma;return(Ma=We==null?void 0:We.key)==null?void 0:Ma.includes("content")}))||[],nl=[];m.comp="Table",la.value=(ge=la==null?void 0:la.value)==null?void 0:ge.sort((We,Ma)=>parseInt(We==null?void 0:We.id)-parseInt(Ma==null?void 0:Ma.id)),la.value=(ze=la==null?void 0:la.value)==null?void 0:ze.map(We=>{let Ma={};for(let Sl in We)JSON.stringify(We==null?void 0:We[Sl])==="{}"?Ma[Sl]="":Ma[Sl]=We==null?void 0:We[Sl];return Ma}),nl.push({key:"tableContents",contents:la==null?void 0:la.value});let Je=(ca=(Q=(Ca=(ra=(Le=s==null?void 0:s.contents)==null?void 0:Le.find(We=>{var Ma;return(Ma=We==null?void 0:We.key)==null?void 0:Ma.includes("struct")}))==null?void 0:ra.value)==null?void 0:Ca[0])==null?void 0:Q.结构)==null?void 0:ca.contents;Array.isArray(Je==null?void 0:Je[0])?Je[0]=(ue=Je==null?void 0:Je[0])==null?void 0:ue.filter(We=>(We==null?void 0:We.prop)!=="sort"&&(We==null?void 0:We.prop)!=="relatedId"):Je=Je==null?void 0:Je.filter(We=>(We==null?void 0:We.prop)!=="sort"&&(We==null?void 0:We.prop)!=="relatedId"),nl.push({key:"header",contents:Je}),nl.push({key:"filter",contents:(Ke=(De=(ce=(Se=(pa=s==null?void 0:s.contents)==null?void 0:pa.find(We=>{var Ma;return(Ma=We==null?void 0:We.key)==null?void 0:Ma.includes("struct")}))==null?void 0:Se.value)==null?void 0:ce[0])==null?void 0:De.引用)==null?void 0:Ke.contents});let Fa=Vp,wa=A.cloneDeep(Pp);h==="Method"&&wa.push({label:"生成方法",prop:"生成方法"}),!Array.isArray(Je==null?void 0:Je[0])&&((ua=Je==null?void 0:Je[0])==null?void 0:ua.prop)==="disabled"&&(Fa=Fp,wa=jp);const Oa=["推力","真空","压力","温度","流量"],Me=m.name;Me&&Oa.includes(Me)&&(Fa=[...Fa],Fa.push({label:"导出paraform",prop:"导出paraform",type:"methodButton"}));let Ra=[];if(!Array.isArray(Je==null?void 0:Je[0])&&(Je!=null&&Je.some(We=>{var Ma;return(We==null?void 0:We.calculatorFilter)&&((Ma=We==null?void 0:We.calculatorFilter)==null?void 0:Ma.includes("Manual"))}))){let We=(Za=Je==null?void 0:Je.map(Ma=>Ma==null?void 0:Ma.calculatorFilter))==null?void 0:Za.filter(Ma=>Ma&&(Ma==null?void 0:Ma.includes("Manual")));We==null||We.forEach(Ma=>{var pr;let Sl=oe.analyzeSplitToContent(Ma,",");if(Sl=Sl==null?void 0:Sl.map(ga=>((ga==null?void 0:ga[(ga==null?void 0:ga.length)-1])===","&&(ga=ga==null?void 0:ga.slice(0,(ga==null?void 0:ga.length)-1)),ga)),Sl!=null&&Sl.find(ga=>(ga==null?void 0:ga.includes("Extent"))&&(ga==null?void 0:ga.includes("Row")))&&(Sl!=null&&Sl.find(ga=>(ga==null?void 0:ga.includes("Button"))&&(ga==null?void 0:ga.includes(","))))){let ga=Sl==null?void 0:Sl.find(Zl=>Zl==null?void 0:Zl.includes("@FunctionButton"));ga=(pr=ga==null?void 0:ga.split("="))==null?void 0:pr[1],ga=ga==null?void 0:ga.slice(1,(ga==null?void 0:ga.length)-1),ga=ga==null?void 0:ga.split(","),ga=ga==null?void 0:ga[(ga==null?void 0:ga.length)-1],Ra.push(ga)}}),Ra=[...new Set(Ra)],Ra=Ra==null?void 0:Ra.map(Ma=>({label:Ma,prop:Ma,type:"methodButton"}))}else if(Array.isArray(Je==null?void 0:Je[0])&&(($=oe.getColumnChild(Je==null?void 0:Je[0]))!=null&&$.some(We=>{var Ma;return(We==null?void 0:We.calculatorFilter)&&((Ma=We==null?void 0:We.calculatorFilter)==null?void 0:Ma.includes("Manual"))}))){let We=(X=(H=oe.getColumnChild(Je==null?void 0:Je[0]))==null?void 0:H.map(Ma=>Ma==null?void 0:Ma.calculatorFilter))==null?void 0:X.filter(Ma=>Ma&&(Ma==null?void 0:Ma.includes("Manual")));We==null||We.forEach(Ma=>{var pr;let Sl=oe.analyzeSplitToContent(Ma,",");if(Sl=Sl==null?void 0:Sl.map(ga=>((ga==null?void 0:ga[(ga==null?void 0:ga.length)-1])===","&&(ga=ga==null?void 0:ga.slice(0,(ga==null?void 0:ga.length)-1)),ga)),Sl!=null&&Sl.find(ga=>(ga==null?void 0:ga.includes("Extent"))&&(ga==null?void 0:ga.includes("Row")))&&(Sl!=null&&Sl.find(ga=>(ga==null?void 0:ga.includes("Button"))&&(ga==null?void 0:ga.includes(","))))){let ga=Sl==null?void 0:Sl.find(Zl=>Zl==null?void 0:Zl.includes("@FunctionButton"));ga=(pr=ga==null?void 0:ga.split("="))==null?void 0:pr[1],ga=ga==null?void 0:ga.slice(1,(ga==null?void 0:ga.length)-1),ga=ga==null?void 0:ga.split(","),ga=ga==null?void 0:ga[(ga==null?void 0:ga.length)-1],Ra.push(ga)}}),Ra=[...new Set(Ra)],Ra=Ra==null?void 0:Ra.map(Ma=>({label:Ma,prop:Ma,type:"methodButton"}))}if(nl.push({key:"extraButton",contents:Fa}),nl.push({key:"rowButton",contents:[...wa,...Ra]}),m.compData=await Po(nl,l,m==null?void 0:m.nameContents),(he=m.compData)!=null&&he.find(We=>(We==null?void 0:We.key)==="tab")&&(m.tab=(ha=(fe=m.compData)==null?void 0:fe.find(We=>(We==null?void 0:We.key)==="tab"))==null?void 0:ha.contents),(ta=m.compData)!=null&&ta.find(We=>(We==null?void 0:We.key)==="step")&&(m.step=(xa=(Fe=m.compData)==null?void 0:Fe.find(We=>(We==null?void 0:We.key)==="step"))==null?void 0:xa.contents),(Ae=m.compData)!=null&&Ae.find(We=>(We==null?void 0:We.key)==="choice")&&(m.choice=(La=(va=m.compData)==null?void 0:va.find(We=>(We==null?void 0:We.key)==="choice"))==null?void 0:La.contents),(Ia=m.compData)!=null&&Ia.find(We=>(We==null?void 0:We.key)==="hideContents")&&(m.isHidden=((Ba=(fa=m.compData)==null?void 0:fa.find(We=>(We==null?void 0:We.key)==="hideContents"))==null?void 0:Ba.contents)??!1),(Te=m.compData)!=null&&Te.find(We=>(We==null?void 0:We.key)==="newType")){let We=(Be=(be=m.compData)==null?void 0:be.find(Ma=>(Ma==null?void 0:Ma.key)==="newType"))==null?void 0:Be.contents;m.comp=We,m.compData=(ae=m.compData)==null?void 0:ae.filter(Ma=>(Ma==null?void 0:Ma.key)!=="newType")}let Va="",Bl=(se=m==null?void 0:m.compData)==null?void 0:se.filter(We=>(We==null?void 0:We.key)==="fixType");(Bl==null?void 0:Bl.length)>0&&n&&(Va=(Xe=Bl==null?void 0:Bl[0])==null?void 0:Xe.contents,m.comp=Va)}else if(h==="Form"){let la=[],nl=(_a=(Ha=(Ze=s==null?void 0:s.contents)==null?void 0:Ze.find(Me=>{var Ra;return(Ra=Me==null?void 0:Me.key)==null?void 0:Ra.includes("content")}))==null?void 0:Ha.value)==null?void 0:_a[0],Je=[],Fa=Array.isArray((Qa=s==null?void 0:s.filter)==null?void 0:Qa.menuFilter)?(Pe=s==null?void 0:s.filter)==null?void 0:Pe.menuFilter:[];Fa==null||Fa.forEach(Me=>{if(Me!=null&&Me.includes("@Param(Hide=Yes, prop=")||Me!=null&&Me.includes("(Hide=Yes, prop=")){const Ra=Me==null?void 0:Me.match(/prop=([^,)]+)/);Ra!=null&&Ra[1]&&Je.push(Ra==null?void 0:Ra[1])}});let wa=(ul=(Ie=(Ne=(Ue=(Re=s==null?void 0:s.contents)==null?void 0:Re.find(Me=>{var Ra;return(Ra=Me==null?void 0:Me.key)==null?void 0:Ra.includes("struct")}))==null?void 0:Ue.value)==null?void 0:Ne[0])==null?void 0:Ie.结构)==null?void 0:ul.contents,Oa=(_l=wa==null?void 0:wa.map(Me=>(Me.value=nl==null?void 0:nl[Me==null?void 0:Me.prop],Me)))==null?void 0:_l.filter(Me=>(Me==null?void 0:Me.prop)!=="sort"&&(Me==null?void 0:Me.prop)!=="relatedId");Oa=Oa==null?void 0:Oa.map(Me=>(Je!=null&&Je.includes(Me==null?void 0:Me.prop)&&(Me.isHideInForm=!0),Me)),la.push({key:"filter",contents:(aa=(Yl=(Cl=(jl=(Tl=s==null?void 0:s.contents)==null?void 0:Tl.find(Me=>{var Ra;return(Ra=Me==null?void 0:Me.key)==null?void 0:Ra.includes("struct")}))==null?void 0:jl.value)==null?void 0:Cl[0])==null?void 0:Yl.引用)==null?void 0:aa.contents}),la.push({key:"formContent",contents:Oa}),la.push({key:"paramHideProps",contents:Je}),m.compData=await Lp(la,l,m==null?void 0:m.nameContents),(Ka=m.compData)!=null&&Ka.find(Me=>(Me==null?void 0:Me.key)==="tab")&&(m.tab=(il=(ma=m.compData)==null?void 0:ma.find(Me=>(Me==null?void 0:Me.key)==="tab"))==null?void 0:il.contents),(Aa=m.compData)!=null&&Aa.find(Me=>(Me==null?void 0:Me.key)==="step")&&(m.step=(rl=(sl=m.compData)==null?void 0:sl.find(Me=>(Me==null?void 0:Me.key)==="step"))==null?void 0:rl.contents),(qe=m.compData)!=null&&qe.find(Me=>(Me==null?void 0:Me.key)==="choice")&&(m.choice=(hl=(Ga=m.compData)==null?void 0:Ga.find(Me=>(Me==null?void 0:Me.key)==="choice"))==null?void 0:hl.contents),(pe=m.compData)!=null&&pe.find(Me=>(Me==null?void 0:Me.key)==="hideContents")&&(m.isHidden=((Sa=(na=m.compData)==null?void 0:na.find(Me=>(Me==null?void 0:Me.key)==="hideContents"))==null?void 0:Sa.contents)??!1)}return m});return r=await Promise.all(i),r=r==null?void 0:r.filter(s=>!(s!=null&&s.isHidden)),r},Hp=A.useLoginState(A.pinia),{loginUserInfo:Ei}=A.storeToRefs(Hp),Up=async(a,l="Manual",n=[])=>{var h;let r=a,i=(h=r==null?void 0:r.filter(c=>{var d;return(c==null?void 0:c.functionName)&&(l==="Manual"&&((d=c==null?void 0:c.calculatorFilter)==null?void 0:d.includes(l))||l!=="Manual")}))==null?void 0:h.map(c=>({prop:c==null?void 0:c.prop,label:c==null?void 0:c.label,methods:c==null?void 0:c.calculatorFilter,functionName:c==null?void 0:c.functionName,functionRelatedWords:c==null?void 0:c.functionRelatedWords})),s=r==null?void 0:r.map(async c=>{let d=i==null?void 0:i.filter(m=>(m==null?void 0:m.prop)===(c==null?void 0:c.prop));return c=await pc(c,d,r,l,r,n),c});return s=await Promise.all(s),s},wt=async(a,l,n="Manual",r=[])=>{var d;let i=a,s;Array.isArray(l==null?void 0:l[0])?s=oe.getColumnChild(l==null?void 0:l[0]):s=l;let h=(d=s==null?void 0:s.filter(m=>{var b;return(m==null?void 0:m.calculatorFilter)&&((b=m==null?void 0:m.calculatorFilter)==null?void 0:b.includes(n))||(m==null?void 0:m.calculatorFilter)===""&&(m==null?void 0:m.functionName)}))==null?void 0:d.map(m=>({prop:m==null?void 0:m.prop,label:m==null?void 0:m.label,methods:m==null?void 0:m.calculatorFilter,functionName:m==null?void 0:m.functionName,functionRelatedWords:m==null?void 0:m.functionRelatedWords})),c=i==null?void 0:i.map(async m=>(m=await pc(m,h,s,n,i,r),m));return c=await Promise.all(c),c},qp=a=>{let l=a==null?void 0:a.contents,n=a==null?void 0:a.valueString,r=a==null?void 0:a.prop,i=a==null?void 0:a.headers,s;return Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=oe.getValueToObjectValue(l,oe.getColumnContents(i))),n==null||n.forEach(h=>{var c;if(l!=null&&l[h]){let d=l==null?void 0:l[h];s=s?d?Al.isEqual(d.toString(),s.toString()):void 0:d}else{let d=(c=i==null?void 0:i.find(b=>(b==null?void 0:b.label)===h))==null?void 0:c.prop,m=(l==null?void 0:l[d])??0;s=s?m?Al.isEqual(m.toString(),s.toString()):void 0:m}}),l[r]=s===void 0?void 0:s?1:0,l},Br=a=>{const[l,n,r]=A.cloneDeep(a).split(":").map(Number);let i=+a;return!a||!(a!=null&&a.includes(":"))?i:(l??0)*3600+(n??0)*60+(r??0)},Kn=a=>{const l=s=>s.toString().padStart(2,"0"),n=Math.floor(a/3600),r=Math.floor(a%3600/60),i=a%60;return`${l(n)}:${l(r)}:${parseInt(l(i))}`},Wp=a=>{let l=a==null?void 0:a.contents,n=a==null?void 0:a.valueString,r=a==null?void 0:a.prop,i=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,h=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=oe.getValueToObjectValue(l,oe.getColumnContents(i))),n==null||n.forEach(d=>{var m,b,u,C,M,k,W,O,j;if(l!=null&&l[d]){if(s==="Row")if(!((b=((m=l==null?void 0:l[d])==null?void 0:m.toString())??"")!=null&&b.includes(":"))&&!((u=c==null?void 0:c.toString())!=null&&u.includes(":"))){let L=+(l==null?void 0:l[d]);c=c+L}else c=Br(c.toString())+Br((C=l==null?void 0:l[d])==null?void 0:C.toString()),c=Kn(c)}else if(s==="Row"){let L=(M=i==null?void 0:i.find(_=>(_==null?void 0:_.label)===d))==null?void 0:M.prop;if(!((W=Number.isNaN(l==null?void 0:l[L])?"":(k=l==null?void 0:l[L])==null?void 0:k.toString())!=null&&W.includes(":"))&&!((O=c==null?void 0:c.toString())!=null&&O.includes(":"))){let _=+((l==null?void 0:l[L])??0);c=c+_}else c=Br(c==null?void 0:c.toString())+Br((j=(l==null?void 0:l[L])??0)==null?void 0:j.toString()),c=Kn(c)}}),s==="Column"){let d=[];n==null||n.forEach(m=>{let b=h==null?void 0:h.map(u=>{var C;return(u==null?void 0:u[m])??(u==null?void 0:u[(C=i==null?void 0:i.find(M=>(M==null?void 0:M.label)===m))==null?void 0:C.prop])});d=[...d,...b]}),c=d.reduce((m,b)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(b)||(C=+b),u+C},0)}return l[r]=c,l},Kp=a=>{let l=a==null?void 0:a.contents,n=a==null?void 0:a.valueString,r=a==null?void 0:a.prop,i=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,h=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=oe.getValueToObjectValue(l,oe.getColumnContents(i))),n==null||n.forEach(d=>{var m,b,u,C,M,k,W;if(l!=null&&l[d]){if(s==="Row")if(!((b=(m=l==null?void 0:l[d])==null?void 0:m.toString())!=null&&b.includes(":"))&&!((u=c==null?void 0:c.toString())!=null&&u.includes(":"))){let O=+(l==null?void 0:l[d]);c=c===0?c+O:c-O}else c=c===0?Br(c.toString())+Br(l==null?void 0:l[d].toString()):Br(c.toString())-Br(l==null?void 0:l[d].toString()),c=Kn(c)}else if(s==="Row"){let O=(C=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===d))==null?void 0:C.prop;if(!((k=Number.isNaN(l==null?void 0:l[O])?"":(M=l==null?void 0:l[O])==null?void 0:M.toString())!=null&&k.includes(":"))&&!((W=c==null?void 0:c.toString())!=null&&W.includes(":"))){let j=+((l==null?void 0:l[O])??0);c=c===0?c+j:c-j}else c=c===0?Br(c.toString())+Br(((l==null?void 0:l[O])??0).toString()):Br(c.toString())-Br(((l==null?void 0:l[O])??0).toString()),c=Kn(c)}}),s==="Column"){let d=[];n==null||n.forEach(m=>{let b=h==null?void 0:h.map(u=>{var C;return(u==null?void 0:u[m])??(u==null?void 0:u[(C=i==null?void 0:i.find(M=>(M==null?void 0:M.label)===m))==null?void 0:C.prop])});d=[...d,...b]}),c=d.reduce((m,b)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(b)||(C=+b),u-C},0)}return l[r]=c,l},Gp=a=>{let l=a==null?void 0:a.contents,n=a==null?void 0:a.valueString,r=a==null?void 0:a.prop,i=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,h=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=oe.getValueToObjectValue(l,oe.getColumnContents(i))),n==null||n.forEach(d=>{var m,b,u,C,M,k,W;if(l!=null&&l[d]){if(s==="Row")if(!((b=(m=l==null?void 0:l[d])==null?void 0:m.toString())!=null&&b.includes(":"))&&!((u=c==null?void 0:c.toString())!=null&&u.includes(":"))){let O=+(l==null?void 0:l[d]);c=c===0?c+O:c*O}else c=c===0?Br(c.toString())+Br(l==null?void 0:l[d].toString()):Br(c.toString())*Br(l==null?void 0:l[d].toString()),c=Kn(c)}else if(s==="Row"){let O=(C=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===d))==null?void 0:C.prop;if(!(l!=null&&l[O]))c=void 0;else if(!((k=Number.isNaN(l==null?void 0:l[O])?"":(M=l==null?void 0:l[O])==null?void 0:M.toString())!=null&&k.includes(":"))&&!((W=c==null?void 0:c.toString())!=null&&W.includes(":"))){let j=+((l==null?void 0:l[O])??0);c=c===0?c+j:c*j}else c=c===0?Br(c.toString())+Br(((l==null?void 0:l[O])??0).toString()):Br(c.toString())*Br(((l==null?void 0:l[O])??0).toString()),c=Kn(c)}}),s==="Column"){let d=[];n==null||n.forEach(m=>{let b=h==null?void 0:h.map(u=>{var C;return(u==null?void 0:u[m])??(u==null?void 0:u[(C=i==null?void 0:i.find(M=>(M==null?void 0:M.label)===m))==null?void 0:C.prop])});d=[...d,...b]}),c=d.reduce((m,b)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(b)||(C=+b),u*C},0)}return l[r]=c,l},Yp=a=>{let l=a==null?void 0:a.contents,n=a==null?void 0:a.valueString,r=a==null?void 0:a.prop,i=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,h=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=oe.getValueToObjectValue(l,oe.getColumnContents(i))),n==null||n.forEach(d=>{var m,b,u,C,M,k,W;if(l!=null&&l[d]){if(s==="Row")if(!((b=(m=l==null?void 0:l[d])==null?void 0:m.toString())!=null&&b.includes(":"))&&!((u=c==null?void 0:c.toString())!=null&&u.includes(":"))){let O=+(l==null?void 0:l[d]);c=c===0?c+O:c/O}else c=c===0?Br(c.toString())+Br(l==null?void 0:l[d].toString()):Br(c.toString())/Br(l==null?void 0:l[d].toString()),c=Kn(c)}else if(s==="Row"){let O=(C=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===d))==null?void 0:C.prop;if(!((k=Number.isNaN(l==null?void 0:l[O])?"":(M=l==null?void 0:l[O])==null?void 0:M.toString())!=null&&k.includes(":"))&&!((W=c==null?void 0:c.toString())!=null&&W.includes(":"))){let j=+((l==null?void 0:l[O])??0);c=c===0?c+j:c/j}else c=c===0?Br(c.toString())+Br(((l==null?void 0:l[O])??0).toString()):Br(c.toString())/Br(((l==null?void 0:l[O])??0).toString()),c=Kn(c)}}),s==="Column"){let d=[];n==null||n.forEach(m=>{let b=h==null?void 0:h.map(u=>{var C;return(u==null?void 0:u[m])??(u==null?void 0:u[(C=i==null?void 0:i.find(M=>(M==null?void 0:M.label)===m))==null?void 0:C.prop])});d=[...d,...b]}),c=d.reduce((m,b)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(b)||(C=+b),u/C},0)}return l[r]=c.toFixed(2),l},Jp=async a=>{var s,h,c,d,m,b,u,C,M,k,W;let l=(s=a==null?void 0:a.valueString)==null?void 0:s[0],n=(h=a==null?void 0:a.contents)==null?void 0:h.calculatorFilter,r=0,i=a==null?void 0:a.contents;if(l!=null&&l.includes("$")&&!(l!=null&&l.includes("{"))){(l==null?void 0:l[0])==="$"&&(l=l==null?void 0:l.slice(1,l==null?void 0:l.length));let O=(d=(c=l==null?void 0:l.split("*"))==null?void 0:c[0])==null?void 0:d.replaceAll(":","/"),j=await Jr(O,!1),L=(m=l==null?void 0:l.split("*"))==null?void 0:m[1];if(j=(b=j==null?void 0:j.filter(_=>(_==null?void 0:_.name)===L))==null?void 0:b[0],n!==""){let _=j.compData;_=_==null?void 0:_.filter(x=>(x==null?void 0:x.key)!=="filter"),_.push({key:"filter",contents:"("+n+")"}),_=await Po(_,{}),r=(C=(u=_==null?void 0:_.find(x=>(x==null?void 0:x.key)==="tableContents"))==null?void 0:u.contents)==null?void 0:C.length}else r=(W=(k=(M=j==null?void 0:j.compData)==null?void 0:M.find(_=>(_==null?void 0:_.key)==="tableContents"))==null?void 0:k.contents)==null?void 0:W.length}return i.value=r,i},go={Sum:Wp,Substract:Kp,Multiple:Gp,Divide:Yp,Compare:qp,VecDimCount:Jp},pc=async(a,l,n,r="Auto",i,s=[])=>{var b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me,_e,z;let h=a,c=[],d=await A.getPageDataApi({platId:parseInt((b=Ei==null?void 0:Ei.value)==null?void 0:b.plat_id),pageName:"menu"});d=(M=(C=(u=d==null?void 0:d.data)==null?void 0:u.result)==null?void 0:C.filter(ne=>(ne==null?void 0:ne.property_name)===""))==null?void 0:M[0];let m=[];if(d!=null&&d.object_name){d=d==null?void 0:d.object_name;let ne=await A.getPageDataApi({platId:parseInt((k=Ei==null?void 0:Ei.value)==null?void 0:k.plat_id),pageName:d});ne=(_=(L=(j=(O=(W=ne==null?void 0:ne.data)==null?void 0:W.result)==null?void 0:O[0])==null?void 0:j.contents)==null?void 0:L.find(Y=>{var te;return(te=Y==null?void 0:Y.key)==null?void 0:te.includes("content")}))==null?void 0:_.value,c=(x=ne==null?void 0:ne.map(Y=>({functionName:Y==null?void 0:Y.函数名称,functionContent:Y==null?void 0:Y.输出值})))==null?void 0:x.filter(Y=>(Y==null?void 0:Y.functionContent)!==""),c==null||c.forEach(Y=>{m.push(Y.functionName),go[Y.functionName]=new Function("return "+Y.functionContent)()})}if((l==null?void 0:l.length)===0)return h;for(let ne in l){let Y=(w=l==null?void 0:l[ne])==null?void 0:w.functionName;const te=go==null?void 0:go[Y];let ye=(g=l==null?void 0:l[ne])==null?void 0:g.methods;if(ye=oe.analyzeSplitToContent(ye,","),(E=ye==null?void 0:ye.find($e=>$e==null?void 0:$e.includes("@FunctionType")))!=null&&E.includes(r)||r==="Auto"||(ye==null?void 0:ye.length)===0){let $e=((ee=(V=(P=ye==null?void 0:ye.find(de=>de==null?void 0:de.includes("@FunctionExtent")))==null?void 0:P.replace(":","="))==null?void 0:V.split("="))==null?void 0:ee[1])??[];if(await new Function("return ")(),(m==null?void 0:m.length)>0&&m.find(de=>de===Y)){let de="";try{let ie=(J=l==null?void 0:l[ne])==null?void 0:J.functionRelatedWords,U=(s==null?void 0:s.length)>0?s==null?void 0:s.map(ze=>{var Le;return ze==null?void 0:ze[(Le=l==null?void 0:l[ne])==null?void 0:Le.prop]}):["0"];U=U==null?void 0:U.map(ze=>ze==null?void 0:ze.slice((ze==null?void 0:ze.length)-5,ze==null?void 0:ze.length)),U=U==null?void 0:U.map(ze=>oe.isNumber(parseInt(ze))&&parseInt(ze)?parseInt(ze):0);let ge=Math.max(...U);ie=ie==null?void 0:ie.map(ze=>{if(ze!=null&&ze.includes("'"))return ze==null?void 0:ze.replaceAll("'","");if(ze!=null&&ze.includes("@"))return ge+1;{let Le=Object.keys(h);return ze=(h==null?void 0:h[ze])??(h==null?void 0:h[Le==null?void 0:Le.find(ra=>ra==null?void 0:ra.includes("."+ze))]),ze}}),de=te(...ie)}catch(ie){Wa.ElMessage.warning("关联数据出现错误,"+ie.message)}let T=(me=l==null?void 0:l[ne])==null?void 0:me.prop;h[T]=de}else h=await te({contents:h,valueString:(_e=l==null?void 0:l[ne])==null?void 0:_e.functionRelatedWords,prop:(z=l==null?void 0:l[ne])==null?void 0:z.prop,headers:n,typeString:$e,allContents:i})}}return h},Xp=A.useLoginState(A.pinia),{loginUserInfo:fn}=A.storeToRefs(Xp),Zp=A.useMenuState(A.pinia),{activeMenuPath:fs,currentMenuPath:bo}=A.storeToRefs(Zp),fc=A.useUnit(A.pinia);let hs="$R";const{selectTitle:Ti}=A.storeToRefs(fc),hc=async(a,l)=>{var h,c,d,m,b,u,C,M,k,W,O,j,L;let n=fs.value,r="",i=((h=Ti==null?void 0:Ti.value)==null?void 0:h.find(_=>(_==null?void 0:_.condition)==="child"&&!(_!=null&&_.relatedContent)))??void 0;(a==null?void 0:a.length)===0||(n=l?n:(c=a==null?void 0:a[0])==null?void 0:c.object_name,r=(d=a==null?void 0:a[0])==null?void 0:d.father_name);let s=[];if(r!==""){let _=r;(_==null?void 0:_[(_==null?void 0:_.length)-1])==="/"&&(_=_==null?void 0:_.slice(0,(_==null?void 0:_.length)-1));let x=await Jr(_,!1);x=(m=x==null?void 0:x[0])==null?void 0:m.compData;let w=(b=x==null?void 0:x.find(E=>(E==null?void 0:E.key)==="header"))==null?void 0:b.contents;w=((u=w==null?void 0:w.find(E=>E==null?void 0:E.isMainKey))==null?void 0:u.prop)??((C=w==null?void 0:w[0])==null?void 0:C.prop);let g=(k=(M=x==null?void 0:x.find(E=>(E==null?void 0:E.key)==="tableContents"))==null?void 0:M.contents)==null?void 0:k.map(E=>({label:E==null?void 0:E[w],value:E==null?void 0:E[w]}));s=(W=r==null?void 0:r.split("/"))==null?void 0:W.map(E=>(E===""?i?(i.isShow=!0,E=i):E={value:E,condition:"child",options:g,parentContent:(r==null?void 0:r[(r==null?void 0:r.length)-1])==="/"?r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1):r,isShow:!0}:E={condition:"parent",value:E.trim(),isShow:!0},E))}if(n!==""){let _=(O=n==null?void 0:n.split("/"))==null?void 0:O.map(x=>(x={condition:"normal",value:x.trim(),isShow:!0},x));((j=_==null?void 0:_[0])==null?void 0:j.value)===((L=s==null?void 0:s[0])==null?void 0:L.value)&&(_=_==null?void 0:_.filter((x,w)=>w!==0)),s=[...s??[],..._??[]]}r===""&&i&&((i==null?void 0:i.parentContent)!==fs.value&&(i.isShow=!1),(i==null?void 0:i.value)!==""&&s.push(i)),fc.setSelectTitle(s)},Qp=async a=>{var s,h,c,d,m,b,u,C,M;let l=await A.getPageDataApi({platId:parseInt((s=fn==null?void 0:fn.value)==null?void 0:s.plat_id),pageName:"menu"}),n=(h=l==null?void 0:l.data)==null?void 0:h.result,r=(b=(m=(d=(c=a==null?void 0:a.filter(k=>(k==null?void 0:k.comp)==="Table"))==null?void 0:c[0])==null?void 0:d.compData)==null?void 0:m.find(k=>(k==null?void 0:k.key)==="filter"))==null?void 0:b.contents;r=(M=(C=(u=r==null?void 0:r.replace("(",hs))==null?void 0:u.split(hs))==null?void 0:C[0])==null?void 0:M.replaceAll(":","/");let i=n==null?void 0:n.filter(k=>{var W;return(k==null?void 0:k.object_name)===bo.value+"/"||((W=bo.value)==null?void 0:W.includes(r))&&r+"/"===(k==null?void 0:k.object_name)||r===(k==null?void 0:k.object_name)});return(i==null?void 0:i.length)>0&&(a=a==null?void 0:a.map(k=>{var W;return(k==null?void 0:k.comp)==="Table"&&(k.compData=(W=k==null?void 0:k.compData)==null?void 0:W.map(O=>{var j,L,_;return(O==null?void 0:O.key)==="header"&&(Array.isArray((j=O.contents)==null?void 0:j[0])?O.contents[0]=(_=O.contents[0])==null?void 0:_.map((x,w)=>{var g;return w===0&&(x.isExistChild=!0,((g=bo.value)!=null&&g.includes(r)||r)&&(x.fatherPath=r)),x}):O.contents=(L=O.contents)==null?void 0:L.map((x,w)=>{var g;return w===0&&(x.isExistChild=!0,((g=bo.value)!=null&&g.includes(r)||r)&&(x.fatherPath=r)),x})),O})),k})),a},Jr=async(a,l,n={})=>{var h,c,d,m,b,u,C,M,k,W,O,j;let r=await A.getPageDataApi({platId:parseInt((h=fn==null?void 0:fn.value)==null?void 0:h.plat_id),pageName:a}),i=(c=r==null?void 0:r.data)==null?void 0:c.result;if((i==null?void 0:i.length)===0&&(n!=null&&n.originPath)&&(n==null?void 0:n.originPath)!==a){let L=await A.getPageDataApi({platId:parseInt((d=fn==null?void 0:fn.value)==null?void 0:d.plat_id),pageName:n==null?void 0:n.originPath});if(((b=(m=L==null?void 0:L.data)==null?void 0:m.result)==null?void 0:b.length)>0){let _=await ps((u=L==null?void 0:L.data)==null?void 0:u.result,n,!1);_=_==null?void 0:_.map(async g=>{var V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za;let E=[],P=(V=Object.keys(g))==null?void 0:V.filter($=>($==null?void 0:$.includes("name"))&&$!=="nameContents");for(let $ in g)P!=null&&P.find(H=>H===$)&&E.push(g==null?void 0:g[$]);if(E=E.reverse(),(g==null?void 0:g.comp)==="Table"){let $=(me=(J=(ee=g==null?void 0:g.compData)==null?void 0:ee.find(X=>(X==null?void 0:X.key)==="tableContents"))==null?void 0:J.contents)==null?void 0:me.map(X=>{let he={};for(let fe in X)fe!=="id"&&fe!=="create_time"&&fe!=="update_time"&&fe!=="sort"&&fe!=="create_user_id"&&fe!=="update_user_id"&&fe!=="department_id"&&fe!=="relatedId"&&(he[fe]=X==null?void 0:X[fe]);return X=Object.values(he),X}),H=(z=(_e=g==null?void 0:g.compData)==null?void 0:_e.find(X=>(X==null?void 0:X.key)==="header"))==null?void 0:z.contents;if(Array.isArray(H==null?void 0:H[0])?(H[0].push({label:"排序",prop:"sort"}),H[0].push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(ne=H[0])!=null&&ne.find(X=>(X==null?void 0:X.prop)==="disabled")&&(H[0]=(Y=H[0])==null?void 0:Y.filter(X=>(X==null?void 0:X.prop)!=="disabled"),H[0].unshift({label:"",prop:"disabled",sortable:!1}))):(H||(H=[]),H.push({label:"排序",prop:"sort"}),H.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),H!=null&&H.find(X=>(X==null?void 0:X.prop)==="disabled")&&(H=H==null?void 0:H.filter(X=>(X==null?void 0:X.prop)!=="disabled"),H.unshift({label:"",prop:"disabled",sortable:!1}))),H!=null&&H.some(X=>{var he;return(X==null?void 0:X.calculatorFilter)&&((he=X==null?void 0:X.calculatorFilter)==null?void 0:he.includes("Auto"))})&&($=await wt($,H,"Auto"),$=$==null?void 0:$.map(X=>Object.values(X))),g!=null&&g.fatherSyncContents){Array.isArray((te=g==null?void 0:g.fatherSyncContents)==null?void 0:te[0])&&(g.fatherSyncContents=(ye=g==null?void 0:g.fatherSyncContents)==null?void 0:ye[0]);let X=($e=Ti.value)==null?void 0:$e.find(he=>(he==null?void 0:he.condition)==="child");g.fatherSyncContents=(de=g==null?void 0:g.fatherSyncContents)==null?void 0:de.map(he=>{var fe,ha,ta,Fe,xa,Ae;return((ha=he==null?void 0:he.menus)==null?void 0:ha[((fe=he==null?void 0:he.menus)==null?void 0:fe.length)-1])==="/"&&(X==null?void 0:X.parentContent)+"/"!==(he==null?void 0:he.menus)?he.menus=(he==null?void 0:he.menus)+(X==null?void 0:X.value):((Fe=he==null?void 0:he.menus)==null?void 0:Fe[((ta=he==null?void 0:he.menus)==null?void 0:ta.length)-1])==="/"&&(X==null?void 0:X.parentContent)+"/"===(he==null?void 0:he.menus)&&(he.menus=(Ae=he.menus)==null?void 0:Ae.slice(0,((xa=he.menus)==null?void 0:xa.length)-1)),he})}if(g!=null&&g.sonSyncContents){Array.isArray((T=g==null?void 0:g.sonSyncContents)==null?void 0:T[0])&&(g.sonSyncContents=(ie=g==null?void 0:g.sonSyncContents)==null?void 0:ie[0]);let X=(U=Ti.value)==null?void 0:U.find(he=>(he==null?void 0:he.condition)==="child");g.sonSyncContents=(ge=g==null?void 0:g.sonSyncContents)==null?void 0:ge.map(he=>{var fe,ha,ta,Fe,xa,Ae;return((ha=he==null?void 0:he.menus)==null?void 0:ha[((fe=he==null?void 0:he.menus)==null?void 0:fe.length)-1])==="/"&&(X==null?void 0:X.parentContent)+"/"!==(he==null?void 0:he.menus)?he.menus=(he==null?void 0:he.menus)+(X==null?void 0:X.value):((Fe=he==null?void 0:he.menus)==null?void 0:Fe[((ta=he==null?void 0:he.menus)==null?void 0:ta.length)-1])==="/"&&(X==null?void 0:X.parentContent)+"/"===(he==null?void 0:he.menus)&&(he.menus=(Ae=he.menus)==null?void 0:Ae.slice(0,((xa=he.menus)==null?void 0:xa.length)-1)),he})}if(g!=null&&g.relatedQuotes){Array.isArray((ze=g==null?void 0:g.relatedQuotes)==null?void 0:ze[0])&&(g.relatedQuotes=(Le=g==null?void 0:g.relatedQuotes)==null?void 0:Le[0]);let X=(ra=Ti.value)==null?void 0:ra.find(he=>(he==null?void 0:he.condition)==="child");g.relatedQuotes=(Ca=g==null?void 0:g.relatedQuotes)==null?void 0:Ca.map(he=>{var fe,ha,ta,Fe,xa,Ae;return((ha=he==null?void 0:he.menus)==null?void 0:ha[((fe=he==null?void 0:he.menus)==null?void 0:fe.length)-1])==="/"&&(X==null?void 0:X.parentContent)+"/"!==(he==null?void 0:he.menus)?he.menus=(he==null?void 0:he.menus)+(X==null?void 0:X.value):((Fe=he==null?void 0:he.menus)==null?void 0:Fe[((ta=he==null?void 0:he.menus)==null?void 0:ta.length)-1])==="/"&&(X==null?void 0:X.parentContent)+"/"===(he==null?void 0:he.menus)&&(he.menus=(Ae=he.menus)==null?void 0:Ae.slice(0,((xa=he.menus)==null?void 0:xa.length)-1)),he})}g={filter:(ca=(Q=g==null?void 0:g.compData)==null?void 0:Q.find(X=>(X==null?void 0:X.key)==="filter"))==null?void 0:ca.contents,key:g==null?void 0:g.comp,name:E,tableColumns:H,tableContents:$,menuFilter:g==null?void 0:g.menuFilter,fatherSyncContents:g==null?void 0:g.fatherSyncContents,relatedQuotes:g==null?void 0:g.relatedQuotes,sonSyncContents:g==null?void 0:g.sonSyncContents}}else{let $=(Se=(pa=(ue=g==null?void 0:g.compData)==null?void 0:ue.find(X=>(X==null?void 0:X.key)==="formContent"))==null?void 0:pa.contents)==null?void 0:Se.map(X=>(X==null?void 0:X.value)??"");$=[$];let H=(Ke=(De=(ce=g==null?void 0:g.compData)==null?void 0:ce.find(X=>(X==null?void 0:X.key)==="formContent"))==null?void 0:De.contents)==null?void 0:Ke.map(X=>(X.value="",X));g={contents:$,filter:(Za=(ua=g==null?void 0:g.compData)==null?void 0:ua.find(X=>(X==null?void 0:X.key)==="filter"))==null?void 0:Za.contents,key:g==null?void 0:g.comp,name:E,value:H,fatherSyncContents:g==null?void 0:g.fatherSyncContents,relatedQuotes:g==null?void 0:g.relatedQuotes,sonSyncContents:g==null?void 0:g.sonSyncContents}}return g.isShow=!1,g}),_=await Promise.all(_);let x=[{key:"menuPath",contents:[{path:a,fatherPath:(k=(M=(C=L==null?void 0:L.data)==null?void 0:C.result)==null?void 0:M[0])==null?void 0:k.father_name,isShow:!1}]},{key:a,contents:_}];await A.createPlatFormDataApi({platId:parseInt((W=fn==null?void 0:fn.value)==null?void 0:W.plat_id),changeData:x});let w=await A.getPageDataApi({platId:parseInt((O=fn==null?void 0:fn.value)==null?void 0:O.plat_id),pageName:a});i=(j=w==null?void 0:w.data)==null?void 0:j.result}}l&&await hc(i,!!(n!=null&&n.originPath));let s=await ps(i,n);return l&&(s=await Qp(s)),s==null?void 0:s.filter(L=>L)},vs=async a=>{var r,i,s,h,c,d,m,b,u,C,M;let l=(r=a==null?void 0:a.menus)==null?void 0:r.join("/");a!=null&&a.endChildMenu&&(a==null?void 0:a.endChildMenu)!==""&&(l==null?void 0:l[(l==null?void 0:l.length)-1])==="/"&&(l=l+(a==null?void 0:a.endChildMenu)),(l==null?void 0:l[(l==null?void 0:l.length)-1])==="/"&&(l=l+((s=(i=a.value)==null?void 0:i.split(" "))==null?void 0:s[0]));let n=await Jr(l,!1);if(n=(h=n==null?void 0:n.filter(k=>{var W,O;return(k==null?void 0:k.name)===((O=a==null?void 0:a.groups)==null?void 0:O[((W=a==null?void 0:a.groups)==null?void 0:W.length)-1])}))==null?void 0:h[0],(d=(c=n==null?void 0:n.compData)==null?void 0:c.find(k=>(k==null?void 0:k.key)==="tableContents"))!=null&&d.contents){n=(b=(m=n==null?void 0:n.compData)==null?void 0:m.find(W=>(W==null?void 0:W.key)==="tableContents"))==null?void 0:b.contents;let k=((u=a==null?void 0:a.words)==null?void 0:u[0])??(a==null?void 0:a.prop);return n=n==null?void 0:n.filter(W=>{var O,j,L,_;return(W==null?void 0:W[a!=null&&a.endChildMenu?k:(O=a==null?void 0:a.words)==null?void 0:O[0]])===(a!=null&&a.relatedWords&&((j=a==null?void 0:a.relatedWords)==null?void 0:j.length)>0?(_=(L=a.value)==null?void 0:L.split(" "))==null?void 0:_[0]:a.value)}),n==null?void 0:n[0]}else{let k=(M=(C=n==null?void 0:n.compData)==null?void 0:C.find(O=>(O==null?void 0:O.key)==="formContent"))==null?void 0:M.contents,W={};return k==null||k.forEach(O=>{W[O.prop]=O.value}),W}},ef={key:0,class:"extra-button-content"},af={class:"table-operator-wrap"},lf={key:0,class:"extra-button-filter"},rf={key:1,class:"extra-header"},nf=["onClick"],of={class:"table-op-text"},tf={class:"table-op-text"},sf={class:"drop-menu",style:{width:"120px"}},cf=["onClick"],uf={key:0},df={key:1},pf=["onClick"],ff={class:"table-op-text"},hf={key:1,class:"extra-button-content tabs-button-wrapper"},vf={class:"table-operator-wrap"},mf={class:"extra-button-filter"},yf={key:0,class:"extra-header"},gf={class:"table-op-action"},bf={class:"table-op-text"},kf={class:"drop-menu",style:{width:"120px"}},xf={key:0},wf={key:1},_f=["onClick"],Sf={class:"table-op-text"},Ef={__name:"header",props:{pageLayout:{type:String,default:"vertical"},lockingPage:Boolean,level:{type:Number,default:1},compName:{type:String,default:"表格名称",required:!1},filterShow:{type:Boolean,default:!1},isDevMode:Boolean,selectNums:Number,dataNums:Number,filterValues:Array,buttons:{type:Array,default:()=>[]},columns:{type:Array,default:()=>[]},menuFilter:{type:Array,default:()=>[]}},emits:["buttonClick","filter","getImportData"],setup(a,{emit:l}){const n=l,r=a,i=()=>{const P=(r==null?void 0:r.menuFilter)||[];return Array.isArray(P)&&(P==null?void 0:P.some(V=>{const ee=typeof V=="string"?V:JSON.stringify(V);return ee==null?void 0:ee.includes("HideGroup=Yes")}))},s=e.ref(""),h=e.ref(!1),c=e.ref(!1),d=e.ref([]),m=e.ref([{label:"清空",background:"#999999"},{label:"确认"}]),b=[{label:"新增",icon:"new"},{label:"导入",icon:"import_101"},{label:"导出",icon:"export_101"},{label:"导出paraform",icon:"export_101"},{label:"OCR识别",icon:"OCR识别"},{label:"切换视图",icon:"cardViewport_101"}];function u(P,V){return P.map(ee=>{const J={...ee};return V.forEach(me=>{delete J[me]}),J})}function C(P){if(!P||P.t!=="n")return(P==null?void 0:P.v)??"";const V=P.v;if(P.z){const ee=String(P.z).toLowerCase(),J=["yyyy/mm/dd","yyyy-mm-dd","yyyy.mm.dd","yy/mm/dd","yy-mm-dd","yy.mm.dd","mm/dd/yy","mm-dd-yy","mm.dd.yy","dd/mm/yy","dd-mm-yy","dd.mm.yy","m/d/yy","m/d/yyyy","d/m/yy","d/m/yyyy","yyyy年","yy年","m月","d日","yyyy年m月d日","yy年m月d日","[$-f800]","[$-f400]"];for(const z of J)if(ee.includes(z))return M(V);const me=/[ymdhms]/.test(ee),_e=/^[0#\.\,\s]+$/.test(ee.replace(/[\\\/\-:]/g,""));if(me&&!_e)return M(V)}if(V>=1&&V<=73050){if(V<5e3)return V;if(V>=5e3&&V<4e4){const ee=Math.floor((V-25569)/365.25)+1970;return ee>=1970&&ee<=2e3&&P.z&&/[ymd]/.test(String(P.z).toLowerCase())?M(V):V}if(V>=4e4)return M(V)}return V}function M(P){if(typeof P!="number")return P;try{const V=new Date((P-25569)*86400*1e3);if(isNaN(V.getTime()))return P;const ee=V.getFullYear(),J=String(V.getMonth()+1).padStart(2,"0"),me=String(V.getDate()).padStart(2,"0");return`${ee}-${J}-${me}`}catch{return P}}const k=P=>{const V=P.raw;if(!V)return;const ee=new FileReader;ee.onload=J=>{try{const me=new Uint8Array(J.target.result),_e=oe.readSync(me,{type:"array"}),z=_e.SheetNames[0],ne=_e.Sheets[z],te=oe.utils.decode_range(ne["!ref"]).e.c+1,ye=new Array(te).fill(""),$e=[];for(const ge in ne){if(ge[0]==="!")continue;const{r:ze,c:Le}=oe.utils.decode_cell(ge),ra=ne[ge];let Ca=C(ra);if((Ca==null||Ca==="")&&(Ca=""),ze===0)ye[Le]=Ca;else{if(!$e[ze-1]){$e[ze-1]={};for(let Q=0;Q<te;Q++)$e[ze-1][`col_${Q}`]=""}$e[ze-1][`col_${Le}`]=Ca}}for(let ge=0;ge<te;ge++)ye[ge]===void 0&&(ye[ge]="");const de=[];for(let ge=0;ge<ye.length;ge++)(!ye[ge]||ye[ge].toString().trim()==="")&&de.push(ge);let T,ie;(de==null?void 0:de.length)>0?(Wa.ElMessage.warning("存在键为空的列,已自动过滤,请检查补充"),T=ye.filter((ge,ze)=>!de.includes(ze)),ie=u($e,de==null?void 0:de.map(ge=>`col_${ge}`))):(T=ye,ie=$e);const U=$e==null?void 0:$e[0];if(!(U!=null&&U.hasOwnProperty("col_0")))return Wa.ElMessage.error("导入的数据列不匹配,请检查是否错位");n("getImportData",T,ie)}catch(me){throw Wa.ElMessage.error(me.message),new Error(me.message)}},ee.readAsArrayBuffer(V)},W=P=>{var ee;const V=(ee=d.value)==null?void 0:ee.reduce((J,me,_e)=>(_e===0?J[me.label]=P:J[me.label]=me==null?void 0:me.value,J),{});n("filter",V,P,!0)},O=(P,V={})=>{n("buttonClick",P,"",V)},j=P=>{var V,ee;d.value=(ee=(V=oe.getColumnChild(A.cloneDeep(P)))==null?void 0:V.filter(J=>(J==null?void 0:J.label)!==""&&(J==null?void 0:J.label)!=="操作"))==null?void 0:ee.map(J=>({label:(J==null?void 0:J.label)??"",value:"",name:(J==null?void 0:J.prop)??"",isFormColHidden:J==null?void 0:J.isTableColHidden,width:2,prop:(J==null?void 0:J.prop)??""}))},L=e.ref(!1),_=P=>{var V;if((P==null?void 0:P.buttonName)==="确认"&&(n("filter",P==null?void 0:P.content),L.value=(P==null?void 0:P.content)&&Object.values(P==null?void 0:P.content).length>0),(P==null?void 0:P.buttonName)==="清空"){const ee=A.cloneDeep(P==null?void 0:P.content);for(const J in ee)ee[J]="";d.value=(V=d.value)==null?void 0:V.map(J=>({...J,value:""})),n("filter",ee),L.value=!1}h.value=!1},x=()=>{h.value=!h.value,c.value=!0},w=()=>{var V,ee;d.value=(V=d.value)==null?void 0:V.map(J=>({...J,value:""}));const P=(ee=d.value)==null?void 0:ee.reduce((J,me)=>(J[me.label]=me.value,J),{});n("filter",P)},g=e.ref(null);let E;return E=P=>{var me;if(!h.value)return;const V=(me=g==null?void 0:g.value)==null?void 0:me.$el,ee=V==null?void 0:V.contains(P.target);let J=!1;document.querySelectorAll(".el-popover, .el-popper").forEach(_e=>{_e.contains(P.target)&&(J=!0)}),!ee&&!J&&(h.value=!1)},e.onMounted(()=>{document.addEventListener("click",E),j(r.columns)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",E)}),e.watch(()=>r.columns,()=>{j(r.columns)},{deep:!0,immediate:!0}),(P,V)=>{var ne,Y,te,ye,$e,de,T,ie;const ee=e.resolveComponent("el-icon"),J=e.resolveComponent("svg-icon"),me=e.resolveComponent("el-input"),_e=e.resolveComponent("el-upload"),z=e.resolveComponent("el-button");return a.pageLayout==="vertical"?(e.openBlock(),e.createElementBlock("div",ef,[i()?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(a.compName?"table-name-wrap":""),style:e.normalizeStyle({background:(r==null?void 0:r.level)>1?"transparent":"var(--ssgroup-background)",paddingLeft:((r==null?void 0:r.level)-1)*12+"px",fontWeight:600-((r==null?void 0:r.level)-1)*100>=400?600-((r==null?void 0:r.level)-1)*100:400,fontSize:17-(r==null?void 0:r.level)>=14?17-(r==null?void 0:r.level)+"px":"14px"})},e.toDisplayString(a.compName),7)),e.createElementVNode("div",af,[r!=null&&r.filterShow?(e.openBlock(),e.createElementBlock("div",lf,[e.createVNode(Fu,{trigger:"contextmenu",ref_key:"popOverRef",ref:g,title:"",width:800,placement:"bottom-start",isVisible:h.value,"onUpdate:isVisible":V[4]||(V[4]=U=>h.value=U)},{reference:e.withCtx(()=>{var U,ge,ze,Le;return[e.createVNode(me,{modelValue:s.value,"onUpdate:modelValue":V[0]||(V[0]=ra=>s.value=ra),style:{"min-width":"80px"},placeholder:L.value?(ze=(ge=(U=a.filterValues)==null?void 0:U.filter(ra=>ra))==null?void 0:ge.slice(0,3))==null?void 0:ze.join("/"):"搜索","prefix-icon":e.unref(Wa.search_default),clearable:"",onInput:W,disabled:((Le=d.value)==null?void 0:Le.length)===0},{suffix:e.withCtx(()=>{var ra,Ca;return[!s.value&&((Ca=(ra=a.filterValues)==null?void 0:ra.filter(Q=>Q))!=null&&Ca.join("/"))?(e.openBlock(),e.createBlock(ee,{key:0,style:{cursor:"pointer"},onClick:w},{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.circle_close_default))]),_:1})):e.createCommentVNode("",!0)]}),append:e.withCtx(()=>[e.createElementVNode("span",{title:"条件查询",onClick:e.withModifiers(x,["stop"])},[e.createVNode(J,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]}),content:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-content-value",onKeydown:V[1]||(V[1]=e.withModifiers(()=>{},["stop"])),onKeyup:V[2]||(V[2]=e.withModifiers(()=>{},["stop"])),onKeypress:V[3]||(V[3]=e.withModifiers(()=>{},["stop"]))},[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:d.value,buttonValue:m.value,isRowFlex:!0,isEnableWrap:!1,isButtonRow:!1,key:m.value,isStartJustify:!1,onOnButtonClick:_},null,8,["rowContents","buttonValue"]))],32)):e.createCommentVNode("",!0)]),_:1},8,["isVisible"])])):e.createCommentVNode("",!0),a.buttons&&((ne=a.buttons)==null?void 0:ne.length)>0?(e.openBlock(),e.createElementBlock("div",rf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Y=a.buttons)==null?void 0:Y.filter(U=>a.isDevMode||(U==null?void 0:U.label)!=="修改模板"),(U,ge)=>{var ze;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:ge},[(U==null?void 0:U.type)==="upload"?(e.openBlock(),e.createBlock(_e,{key:0,class:"upload-button-wrap","on-change":k,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1,disabled:!!a.lockingPage},{default:e.withCtx(()=>{var Le;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:ra=>O(U==null?void 0:U.label)},[e.createVNode(J,{class:"table-op-icon",name:(Le=b==null?void 0:b.find(ra=>(ra==null?void 0:ra.label)===(U==null?void 0:U.label)))==null?void 0:Le.icon},null,8,["name"]),e.createElementVNode("span",of,e.toDisplayString(U==null?void 0:U.label),1)],10,nf)]}),_:2},1032,["disabled"])):e.createCommentVNode("",!0),(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(cl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>{var Le;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}])},[e.createVNode(J,{class:"table-op-icon",name:(Le=b==null?void 0:b.find(ra=>(ra==null?void 0:ra.label)===(U==null?void 0:U.label)))==null?void 0:Le.icon},null,8,["name"]),e.createElementVNode("span",tf,e.toDisplayString(U==null?void 0:U.label),1)],2)]}),dropMenu:e.withCtx(()=>[e.createElementVNode("div",sf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U==null?void 0:U.contents,Le=>{var ra,Ca;return e.openBlock(),e.createElementBlock("div",{key:Le==null?void 0:Le.label,class:e.normalizeClass(["table-op-drop-item",{"is-disabled":!!a.lockingPage}]),onClick:Q=>!a.lockingPage&&O(Le==null?void 0:Le.label)},[e.createTextVNode(e.toDisplayString(Le==null?void 0:Le.label),1),(ra=Le==null?void 0:Le.label)!=null&&ra.includes("选中")?(e.openBlock(),e.createElementBlock("span",uf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(Ca=Le==null?void 0:Le.label)!=null&&Ca.includes("全部")?(e.openBlock(),e.createElementBlock("span",df,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)],10,cf)}),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(U!=null&&U.type)||(U==null?void 0:U.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,id:"themeButton",class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:Le=>!a.lockingPage&&O(U==null?void 0:U.label,U)},[e.createVNode(J,{class:"table-op-icon",name:((ze=b==null?void 0:b.find(Le=>(Le==null?void 0:Le.label)===(U==null?void 0:U.label)))==null?void 0:ze.icon)??"normal"},null,8,["name"]),e.createElementVNode("span",ff,e.toDisplayString(U==null?void 0:U.label),1)],10,pf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createElementBlock("div",hf,[e.createElementVNode("div",vf,[e.createElementVNode("div",mf,[e.createVNode(me,{modelValue:s.value,"onUpdate:modelValue":V[5]||(V[5]=U=>s.value=U),style:{"min-width":"80px"},placeholder:L.value?($e=(ye=(te=a.filterValues)==null?void 0:te.filter(U=>U))==null?void 0:ye.slice(0,3))==null?void 0:$e.join("/"):"搜索","prefix-icon":e.unref(Wa.search_default),clearable:"",onInput:W,disabled:((de=d.value)==null?void 0:de.length)===0},{suffix:e.withCtx(()=>{var U,ge;return[!s.value&&((ge=(U=a.filterValues)==null?void 0:U.filter(ze=>ze))!=null&&ge.join("/"))?(e.openBlock(),e.createBlock(ee,{key:0,style:{cursor:"pointer"},onClick:w},{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.circle_close_default))]),_:1})):e.createCommentVNode("",!0)]}),append:e.withCtx(()=>[e.createElementVNode("span",{title:"条件查询",onClick:e.withModifiers(x,["stop"])},[e.createVNode(J,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]),a.buttons&&((T=a.buttons)==null?void 0:T.length)>0?(e.openBlock(),e.createElementBlock("div",yf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((ie=a.buttons)==null?void 0:ie.filter(U=>a.isDevMode||(U==null?void 0:U.label)!=="修改模板"),(U,ge)=>{var ze;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:ge},[(U==null?void 0:U.type)==="upload"?(e.openBlock(),e.createBlock(_e,{key:0,class:"upload-button-wrap","on-change":k,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1},{default:e.withCtx(()=>{var Le;return[e.createElementVNode("div",gf,[e.createVNode(J,{class:"table-op-icon",name:(Le=b==null?void 0:b.find(ra=>(ra==null?void 0:ra.label)===(U==null?void 0:U.label)))==null?void 0:Le.icon},null,8,["name"]),e.createElementVNode("span",bf,e.toDisplayString(U==null?void 0:U.label),1)])]}),_:2},1024)):e.createCommentVNode("",!0),(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(cl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>[(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(z,{key:0,style:{background:"transparent",color:"#000000"}},{icon:e.withCtx(()=>{var Le;return[e.createVNode(J,{class:"table-op-icon",name:(Le=b==null?void 0:b.find(ra=>(ra==null?void 0:ra.label)===(U==null?void 0:U.label)))==null?void 0:Le.icon},null,8,["name"])]}),default:e.withCtx(()=>[e.createTextVNode(" "+e.toDisplayString(U==null?void 0:U.label),1)]),_:2},1024)):e.createCommentVNode("",!0)]),dropMenu:e.withCtx(()=>[e.createElementVNode("div",kf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U==null?void 0:U.contents,Le=>(e.openBlock(),e.createBlock(z,{key:Le==null?void 0:Le.label,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:ra=>O(Le==null?void 0:Le.label)},{default:e.withCtx(()=>{var ra,Ca;return[e.createTextVNode(e.toDisplayString(Le==null?void 0:Le.label),1),(ra=Le==null?void 0:Le.label)!=null&&ra.includes("选中")?(e.openBlock(),e.createElementBlock("span",xf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(Ca=Le==null?void 0:Le.label)!=null&&Ca.includes("全部")?(e.openBlock(),e.createElementBlock("span",wf,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)]}),_:2},1032,["onClick"]))),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(U!=null&&U.type)||(U==null?void 0:U.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),id:"themeButton",onClick:Le=>!a.lockingPage&&O(U==null?void 0:U.label,U)},[e.createVNode(J,{class:"table-op-icon",name:(ze=b==null?void 0:b.find(Le=>(Le==null?void 0:Le.label)===(U==null?void 0:U.label)))==null?void 0:ze.icon},null,8,["name"]),e.createElementVNode("span",Sf,e.toDisplayString(U==null?void 0:U.label),1)],10,_f)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])]))}}},Cf=ar._export_sfc(Ef,[["__scopeId","data-v-44a17652"]]),Df={__name:"index",props:{columns:Array,tableData:Array},setup(a){return(l,n)=>{const r=e.resolveComponent("el-table-column"),i=e.resolveComponent("el-table");return e.openBlock(),e.createBlock(i,{data:a.tableData,style:{width:"100%"},stripe:"","max-height":"500"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.columns,s=>{var h;return e.openBlock(),e.createBlock(r,{key:s==null?void 0:s.prop,label:s==null?void 0:s.label,prop:s==null?void 0:s.prop,fixed:(s==null?void 0:s.prop)==="operate"?"right":s==null?void 0:s.fixed,align:(s==null?void 0:s.align)??"left","show-overflow-tooltip":(s==null?void 0:s.showOverflowTooltip)??!0,width:s==null?void 0:s.width,"min-width":(s==null?void 0:s.minWidth)||((s==null?void 0:s.prop)==="operate"?80:(((h=s==null?void 0:s.label)==null?void 0:h.length)*2||4)*27)},{default:e.withCtx(c=>[e.renderSlot(l.$slots,"content",{row:c.row,column:c.column,$index:c.$index,scope:c}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.children,(d,m)=>(e.openBlock(),e.createBlock(cl._sfc_main$2,{key:m,column:d,tableData:a.tableData},e.createSlots({_:2},[e.renderList(l.$slots,(b,u)=>({name:u,fn:e.withCtx(({row:C,slotData:M,item:k,column:W})=>[e.renderSlot(l.$slots,u,e.mergeProps({ref_for:!0},M??C,{item:k??d,slotData:M??C,row:C,column:W,columnProp:d}))])}))]),1032,["column","tableData"]))),128))]),_:2},1032,["label","prop","fixed","align","show-overflow-tooltip","width","min-width"])}),128))]),_:3},8,["data"])}}};class Tf extends Al.Loader{constructor(l){super(l),this.littleEndian=!0}load(l,n,r,i){const s=this,h=new Al.FileLoader(s.manager);h.setPath(s.path),h.setResponseType("arraybuffer"),h.setRequestHeader(s.requestHeader),h.setWithCredentials(s.withCredentials),h.load(l,function(c){try{n(s.parse(c))}catch(d){i?i(d):console.error(d),s.manager.itemError(l)}},r,i)}_getDataView(l,n,r,i){switch(r){case"F":return i===8?l.getFloat64(n,this.littleEndian):l.getFloat32(n,this.littleEndian);case"I":return i===1?l.getInt8(n):i===2?l.getInt16(n,this.littleEndian):l.getInt32(n,this.littleEndian);case"U":return i===1?l.getUint8(n):i===2?l.getUint16(n,this.littleEndian):l.getUint32(n,this.littleEndian)}}parse(l){function n(M,k){const W=M.length,O=new Uint8Array(k);let j=0,L=0,_,x,w;do if(_=M[j++],_<32){if(_++,L+_>k)throw new Error("Output buffer is not large enough");if(j+_>W)throw new Error("Invalid compressed data");do O[L++]=M[j++];while(--_)}else{if(x=_>>5,w=L-((_&31)<<8)-1,j>=W)throw new Error("Invalid compressed data");if(x===7&&(x+=M[j++],j>=W))throw new Error("Invalid compressed data");if(w-=M[j++],L+x+2>k)throw new Error("Output buffer is not large enough");if(w<0)throw new Error("Invalid compressed data");if(w>=L)throw new Error("Invalid compressed data");do O[L++]=O[w++];while(--x+2)}while(j<W);return O}function r(M){const k={},W=new Uint8Array(M);let O="",j="",L=0,_=!1;const x=W.length;for(;L<x&&_===!1;){const P=String.fromCharCode(W[L++]);P===`
|
|
2
|
-
`||P==="\r"?(j.trim().toLowerCase().startsWith("data")&&(_=!0),j=""):j+=P,O+=P}const w=O.search(/[\r\n]DATA\s(\S*)\s/i),g=/[\r\n]DATA\s(\S*)\s/i.exec(O.slice(w-1));if(k.data=g[1],k.headerLen=g[0].length+w,k.str=O.slice(0,k.headerLen),k.str=k.str.replace(/#.*/gi,""),k.version=/^VERSION (.*)/im.exec(k.str),k.fields=/^FIELDS (.*)/im.exec(k.str),k.size=/^SIZE (.*)/im.exec(k.str),k.type=/^TYPE (.*)/im.exec(k.str),k.count=/^COUNT (.*)/im.exec(k.str),k.width=/^WIDTH (.*)/im.exec(k.str),k.height=/^HEIGHT (.*)/im.exec(k.str),k.viewpoint=/^VIEWPOINT (.*)/im.exec(k.str),k.points=/^POINTS (.*)/im.exec(k.str),k.version!==null&&(k.version=parseFloat(k.version[1])),k.fields=k.fields!==null?k.fields[1].split(" "):[],k.type!==null&&(k.type=k.type[1].split(" ")),k.width!==null&&(k.width=parseInt(k.width[1])),k.height!==null&&(k.height=parseInt(k.height[1])),k.viewpoint!==null&&(k.viewpoint=k.viewpoint[1]),k.points!==null&&(k.points=parseInt(k.points[1],10)),k.points===null&&(k.points=k.width*k.height),k.size!==null&&(k.size=k.size[1].split(" ").map(function(P){return parseInt(P,10)})),k.count!==null)k.count=k.count[1].split(" ").map(function(P){return parseInt(P,10)});else{k.count=[];for(let P=0,V=k.fields.length;P<V;P++)k.count.push(1)}k.offset={};let E=0;for(let P=0,V=k.fields.length;P<V;P++)k.data==="ascii"?k.offset[k.fields[P]]=P:(k.offset[k.fields[P]]=E,E+=k.size[P]*k.count[P]);return k.rowSize=E,k}const i=r(l),s=[],h=[],c=[],d=[],m=[],b=new Al.Color;if(i.data==="ascii"){const M=i.offset,O=new TextDecoder().decode(l).slice(i.headerLen).split(`
|
|
3
|
-
`);for(let j=0,L=O.length;j<L;j++){if(O[j]==="")continue;const _=O[j].split(" ");if(M.x!==void 0&&(s.push(parseFloat(_[M.x])),s.push(parseFloat(_[M.y])),s.push(parseFloat(_[M.z]))),M.rgb!==void 0){const x=i.fields.findIndex(J=>J==="rgb"),w=i.type[x],g=parseFloat(_[M.rgb]);let E=g;if(w==="F"){const J=new Float32Array(1);J[0]=g,E=new Int32Array(J.buffer)[0]}const P=(E>>16&255)/255,V=(E>>8&255)/255,ee=(E>>0&255)/255;b.setRGB(P,V,ee,Al.SRGBColorSpace),c.push(b.r,b.g,b.b)}M.normal_x!==void 0&&(h.push(parseFloat(_[M.normal_x])),h.push(parseFloat(_[M.normal_y])),h.push(parseFloat(_[M.normal_z]))),M.intensity!==void 0&&d.push(parseFloat(_[M.intensity])),M.label!==void 0&&m.push(parseInt(_[M.label]))}}if(i.data==="binary_compressed"){const M=new Uint32Array(l.slice(i.headerLen,i.headerLen+8)),k=M[0],W=M[1],O=n(new Uint8Array(l,i.headerLen+8,k),W),j=new DataView(O.buffer),L=i.offset;for(let _=0;_<i.points;_++){if(L.x!==void 0){const x=i.fields.indexOf("x"),w=i.fields.indexOf("y"),g=i.fields.indexOf("z");s.push(this._getDataView(j,i.points*L.x+i.size[x]*_,i.type[x],i.size[x])),s.push(this._getDataView(j,i.points*L.y+i.size[w]*_,i.type[w],i.size[w])),s.push(this._getDataView(j,i.points*L.z+i.size[g]*_,i.type[g],i.size[g]))}if(L.rgb!==void 0){const x=i.fields.indexOf("rgb"),w=j.getUint8(i.points*L.rgb+i.size[x]*_+2)/255,g=j.getUint8(i.points*L.rgb+i.size[x]*_+1)/255,E=j.getUint8(i.points*L.rgb+i.size[x]*_+0)/255;b.setRGB(w,g,E,Al.SRGBColorSpace),c.push(b.r,b.g,b.b)}if(L.normal_x!==void 0){const x=i.fields.indexOf("normal_x"),w=i.fields.indexOf("normal_y"),g=i.fields.indexOf("normal_z");h.push(this._getDataView(j,i.points*L.normal_x+i.size[x]*_,i.type[x],i.size[x])),h.push(this._getDataView(j,i.points*L.normal_y+i.size[w]*_,i.type[w],i.size[w])),h.push(this._getDataView(j,i.points*L.normal_z+i.size[g]*_,i.type[g],i.size[g]))}if(L.intensity!==void 0){const x=i.fields.indexOf("intensity");d.push(this._getDataView(j,i.points*L.intensity+i.size[x]*_,i.type[x],i.size[x]))}if(L.label!==void 0){const x=i.fields.indexOf("label");m.push(j.getInt32(i.points*L.label+i.size[x]*_,this.littleEndian))}}}if(i.data==="binary"){const M=new DataView(l,i.headerLen),k=i.offset;for(let W=0,O=0;W<i.points;W++,O+=i.rowSize){if(k.x!==void 0){const j=i.fields.indexOf("x"),L=i.fields.indexOf("y"),_=i.fields.indexOf("z");s.push(this._getDataView(M,O+k.x,i.type[j],i.size[j])),s.push(this._getDataView(M,O+k.y,i.type[L],i.size[L])),s.push(this._getDataView(M,O+k.z,i.type[_],i.size[_]))}if(k.rgb!==void 0){const j=M.getUint8(O+k.rgb+2)/255,L=M.getUint8(O+k.rgb+1)/255,_=M.getUint8(O+k.rgb+0)/255;b.setRGB(j,L,_,Al.SRGBColorSpace),c.push(b.r,b.g,b.b)}if(k.normal_x!==void 0){const j=i.fields.indexOf("normal_x"),L=i.fields.indexOf("normal_y"),_=i.fields.indexOf("normal_z");h.push(this._getDataView(M,O+k.normal_x,i.type[j],i.size[j])),h.push(this._getDataView(M,O+k.normal_y,i.type[L],i.size[L])),h.push(this._getDataView(M,O+k.normal_z,i.type[_],i.size[_]))}if(k.intensity!==void 0){const j=i.fields.indexOf("intensity");d.push(this._getDataView(M,O+k.intensity,i.type[j],i.size[j]))}k.label!==void 0&&m.push(M.getInt32(O+k.label,this.littleEndian))}}const u=new Al.BufferGeometry;s.length>0&&u.setAttribute("position",new Al.Float32BufferAttribute(s,3)),h.length>0&&u.setAttribute("normal",new Al.Float32BufferAttribute(h,3)),c.length>0&&u.setAttribute("color",new Al.Float32BufferAttribute(c,3)),d.length>0&&u.setAttribute("intensity",new Al.Float32BufferAttribute(d,1)),m.length>0&&u.setAttribute("label",new Al.Int32BufferAttribute(m,1)),u.computeBoundingSphere();const C=new Al.PointsMaterial({size:.005});return c.length>0&&(C.vertexColors=!0),new Al.Points(u,C)}}const Bf=A.useModelComp(A.pinia),{systemPath:ms}=A.storeToRefs(Bf),ko=e.ref(),ys=new WeakMap;function Nf(a,l,n,r,i){const s=async C=>{try{const M=await A.platformDownloadFile({url:C});if(M.status!==200)throw new Error(`下载失败: ${M.status}`);return M.data}catch(M){throw console.error("addModelFromUrl失败:",M),M}},h=C=>new Promise((M,k)=>{const W=new FileReader;W.onload=O=>{try{const j=O.target.result,_=new $n.MTLLoader().parse(j);_.preload(),M(_)}catch(j){k(j)}},W.onerror=()=>{k(new Error("MTL文件读取失败"))},W.readAsText(C)}),c=async C=>{const M={materials:{},create:function(k){return this.materials[k]?this.materials[k]:(console.warn(`Material '${k}' not found, using default material`),new Al.MeshPhongMaterial({color:8947848,side:Al.DoubleSide}))},getAsArray:function(){const k=[];for(const W in this.materials)k.push(this.materials[W]);return k},preload:function(){for(const k in this.materials)this.materials[k].map&&(this.materials[k].map.needsUpdate=!0)}};for(const k of C){const W=await h(k);Object.assign(M.materials,W.materials)}return M.preload(),M},d=async(C,M=[])=>new Promise((k,W)=>{const O=new FileReader;O.onload=async j=>{try{const L=j.target.result;let _=null;M&&M.length>0&&(M.length===1?_=await h(M[0]):_=await c(M));const x=new $n.OBJLoader;_&&x.setMaterials(_);const w=x.parse(L);_||w.traverse(g=>{g.isMesh&&(g.material=new Al.MeshPhongMaterial({color:8947848,side:Al.DoubleSide}))}),k(w)}catch(L){W(L)}},O.onerror=()=>{W(new Error("OBJ文件读取失败"))},O.readAsText(C)}),m=async C=>{var M;try{n.value=!0;const{scene:k}=a();if(!k)throw new Error("Scene not initialized");i();const W=[];for(let O=0;O<C.length;O++){const j=C[O];r.value=`正在加载模型 ${O+1}/${C.length}...`;const L=await s(j.objUrl),_=((M=j.objUrl)==null?void 0:M.split("/").pop())||`model_${O}.obj`,x=new File([L],_,{type:L.type});let w=[];if(j.mtlUrls){const E=Array.isArray(j.mtlUrls)?j.mtlUrls:[j.mtlUrls];for(let P=0;P<E.length;P++){const V=E[P],ee=await s(V),J=(V==null?void 0:V.split("/").pop())||`material_${O}_${P}.mtl`,me=new File([ee],J,{type:ee.type});w.push(me)}}const g=await d(x,w);k.add(g),l.value.push(g),W.push(g)}return n.value=!1,W}catch(k){throw console.error("加载模型失败:",k),n.value=!1,k}},b=async(C,M,k=[],W=[])=>{let O;const j=C.toLowerCase();switch(j){case".txt":case".cpt":case".obj":const L=await M.text();if(j===".txt"||j===".cpt"){const Q=/^(?!.*\bf\b)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?$/gm,ue=[...L.matchAll(Q)].map(ce=>({x:parseFloat(ce[1]),y:parseFloat(ce[2]),z:parseFloat(ce[3])})),pa=new Al.BufferGeometry,Se=ue.flatMap(ce=>[ce.x,ce.y,ce.z]);if(pa.setAttribute("position",new Al.Float32BufferAttribute(Se,3)),j===".txt"){const ce=new Al.PointsMaterial({color:"#5B5C99",size:1,sizeAttenuation:!1});O=new Al.Points(pa,ce)}else if(j===".cpt"){const ce=new Al.LineBasicMaterial({color:"#5B5C99",linewidth:100});O=new Al.Line(pa,ce)}}else if(j===".obj"){const Q=new $n.OBJLoader;if(k&&k.length>0){const ca=new $n.MTLLoader;for(const ue of k){const pa=await ue.text(),Se=ca.parse(pa);Se.preload(),Q.setMaterials(Se);break}}O=Q.parse(L),(!k||k.length===0)&&O.traverse(ca=>{ca.isMesh&&(ca.material=new Al.MeshPhongMaterial({color:"#B3B3D4"})),ca instanceof Al.Mesh&&(ca.material.side=Al.DoubleSide)})}break;case".stl":const _=await M.arrayBuffer(),w=new $n.STLLoader().parse(_),g=new Al.MeshPhongMaterial({color:"#B3B3D4",side:Al.DoubleSide});O=new Al.Mesh(w,g);break;case".nc":const E=["Mach_B_Axis_0.STL","Mach_C_Axis_0.STL","Mach_X_Axis_0.STL","Mach_Y_Axis_0.STL","Mach_Z_Axis_0.STL","Mach_Spindle_0.STL"],P={"Mach_Y_Axis_0.STL":"rgb(128,118,152)","Mach_B_Axis_0.STL":"rgb(204,143,89)","Mach_C_Axis_0.STL":"rgb(145,245,251)","Mach_X_Axis_0.STL":"rgb(125,158,192)","Mach_Z_Axis_0.STL":"rgb(248,228,118)","Mach_Spindle_0.STL":"rgb(145,145,145)"},V=new Al.Group,ee=E.map(Q=>new Promise((ca,ue)=>{new $n.STLLoader().load(ms.value===""?`/model/${Q}`:`${ms.value}\\${Q}`,Se=>{const ce=new Al.MeshPhongMaterial({color:P[Q]||"#B3B3D4",side:Al.DoubleSide}),De=new Al.Mesh(Se,ce);ca(De)},void 0,ue)}));try{(await Promise.all(ee)).forEach(ca=>V.add(ca)),O=V}catch(Q){throw console.error("加载NC文件对应的STL文件失败:",Q),new Error("无法加载.NC文件对应的STL文件")}break;case".pcd":const J=new Tf,me=new Al.Group;try{const Q=await Wa.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/target.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),ca=new Blob([Q.data],{type:"application/octet-stream;charset=UTF-8"}),ue=await Wa.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/final.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),pa=new Blob([ue.data],{type:"application/octet-stream;charset=UTF-8"}),Se=await new Promise((De,Ke)=>{const ua=URL.createObjectURL(ca);J.load(ua,Za=>{const $=new Float32Array(Za.geometry.attributes.position.count*3);for(let H=0;H<Za.geometry.attributes.position.count;H++)$[H*3]=1,$[H*3+1]=0,$[H*3+2]=0;Za.geometry.setAttribute("color",new Al.BufferAttribute($,3)),Za.material.vertexColors=!0,Za.scale.set(.3,.3,.3),URL.revokeObjectURL(ua),De(Za)},void 0,Ke)}),ce=await new Promise((De,Ke)=>{const ua=URL.createObjectURL(pa);J.load(ua,Za=>{const $=new Float32Array(Za.geometry.attributes.position.count*3);for(let H=0;H<Za.geometry.attributes.position.count;H++)$[H*3]=0,$[H*3+1]=1,$[H*3+2]=0;Za.geometry.setAttribute("color",new Al.BufferAttribute($,3)),Za.material.vertexColors=!0,Za.scale.set(.3,.3,.3),URL.revokeObjectURL(ua),De(Za)},void 0,Ke)});me.add(Se),me.add(ce),O=me}catch(Q){throw console.error("PCD文件加载失败:",Q),new Error("无法加载PCD文件")}break;case".urdf":const _e=URL.createObjectURL(M),z=new Ru.URDFLoader,ne="http://139.196.154.85:20026/chfs/shared/机器人/urdf/SmallBender_R-2000iC-165F/meshes",Y={maxConcurrentLoads:4,enableCache:!0,enableLOD:!0,simplifyGeometry:!0,shareMaterials:!0,enableInstancing:!0},te=new WeakMap,ye=new WeakMap,$e=new WeakMap,de=async Q=>{if(te.has(Q))return console.log(`从缓存加载: ${Q}`),te.get(Q);try{const ca=await Wa.axios.get(`${ne}/${Q}`,{responseType:"blob",headers:{"Content-Type":"application/json"},timeout:6e5}),ue=new Blob([ca.data],{type:"application/octet-stream;charset=UTF-8"});return Y.enableCache&&te.set(Q,ue),ue}catch(ca){throw console.error(`加载文件失败: ${Q}`,ca),new Error(`无法加载文件: ${Q}`)}},T=(Q="default")=>{if(ye.has(Q))return ye.get(Q);const ca=new Al.MeshPhongMaterial({color:12303291,shininess:30,transparent:!1,alphaTest:.1,side:Al.FrontSide});return ye.set(Q,ca),ca},ie=Q=>{try{Q.isBufferGeometry&&Q.mergeVertices&&Q.mergeVertices(),Q.computeVertexNormals&&Q.computeVertexNormals(),Q.computeBoundingSphere&&Q.computeBoundingSphere(),Q.deleteAttribute&&Q.deleteAttribute("uv2")}catch(ca){console.warn("几何体优化失败,使用原始几何体:",ca)}return Q},U=async(Q,ca,ue)=>{const pa=`stl_${ca}`;if($e.has(pa)){const Ke=$e.get(pa);return new Al.Mesh(Ke,T())}const Se=await Q.arrayBuffer();let De=new $n.STLLoader(ue).parse(Se);return De=ie(De),$e.set(pa,De),new Al.Mesh(De,T())},ge=async(Q,ca,ue)=>{const pa=`obj_${ca}`;if(te.has(pa))return te.get(pa).clone();const Se=await Q.text(),ce=new $n.OBJLoader(ue),De=ca.replace(".obj",".mtl");try{const Za=await(await de(De)).text(),H=new $n.MTLLoader(ue).parse(Za);H.preload(),ce.setMaterials(H)}catch{console.warn(`MTL文件加载失败,使用默认材质: ${De}`)}const Ke=ce.parse(Se);return Ke.traverse(ua=>{ua.isMesh&&(ua.geometry=ie(ua.geometry),ua.castShadow=!0,ua.receiveShadow=!0,ua.renderOrder=1)}),te.set(pa,Ke),Ke},ze=(Q,ca)=>{const ue=new Al.LOD;if(ue.addLevel(Q,0),Q.geometry){const pa=Q.geometry.clone(),Se=new Al.Mesh(pa,Q.material);ue.addLevel(Se,50)}return ue};let Le=0,ra=0;const Ca=[];z.loadMeshCb=async(Q,ca,ue,pa,Se)=>{const ce=Q.split("/").pop(),De=ue||(()=>{});Le++;const Ke=new Promise(async(ua,Za)=>{try{const $=await de(ce);if(!$||$.size===0)throw new Error(`文件为空: ${ce}`);const H=ce.split(".").pop().toLowerCase();let X;switch(H){case"stl":X=await U($,ce,ca);break;case"obj":X=await ge($,ce,ca);break;default:throw new Error(`不支持的文件格式: ${H}`)}Y.enableLOD&&X.isMesh&&(X=ze(X,ce)),De(X),ra++,pa&&pa({loaded:ra,total:Le,progress:ra/Le}),ua(X)}catch($){console.error(`mesh文件加载失败: ${ce}`,$);const H=new Al.Group;De(H),ua(H);const X=new Al.BoxGeometry(.1,.1,.1),he=new Al.MeshStandardMaterial({color:16711680,wireframe:!0});return new Al.Mesh(X,he)}});Ca.push(Ke)};try{if(!_e){ko.value=void 0;break}if(O=await z.loadAsync(_e),console.log(`URDF文件加载完成,等待${Le}个mesh文件加载...`),Ca.length>0)try{await Promise.allSettled(Ca),console.log(`所有mesh文件处理完成,成功加载: ${ra}/${Le}`)}catch(ue){console.warn("部分mesh文件加载失败,但继续显示模型",ue)}O.traverse(ue=>{ue.isMesh&&(ue.castShadow=!0,ue.receiveShadow=!0,ue.renderOrder=1,ue.material&&(ue.material.needsUpdate=!0))}),console.time("计算包围盒");const Q=new Al.Box3;Q.expandByObject(O);const ca=`urdf_${Date.now()}`;O.userData.boundingBox=Q.clone(),O.userData.modelId=ca,ys.set(ca,{box:Q.clone(),center:Q.getCenter(new Al.Vector3),size:Q.getSize(new Al.Vector3),maxSize:Math.max(...Q.getSize(new Al.Vector3).toArray())}),ko.value=O,console.log("URDF模型加载完成并优化")}catch(Q){console.error("URDF加载失败:",Q),ko.value=void 0}finally{_e&&URL.revokeObjectURL(_e)}break;default:throw new Error(`不支持的文件格式: ${C}`)}return O};return{addModelsFromUrls:m,loadModelByDefaultPath:async C=>{console.log(C);try{n.value=!0,r.value="正在加载模型...";const{scene:M}=a();if(!M)throw new Error("Scene not initialized");i(),await new Promise(W=>setTimeout(W,100));const k=[];for(let W=0;W<C.length;W++){const O=C[W],j=await b(O.suffix,O.blob,O.mtlBlobs||[],O.meshFiles||[]);j&&(M.add(j),l.value.push(j),k.push(j))}return n.value=!1,r.value="",k}catch(M){throw console.error("加载模型失败:",M),n.value=!1,r.value="",M}},urdfModel:ko,modelBoundingBoxes:ys}}window._iconfont_svg_string_4827314='<svg><symbol id="icon-chart-new" viewBox="0 0 1024 1024"><path d="M960 768V448h-64v320h-64v64H192v-64h-64V256h64v-64h256v-64H192V64H0v192h64v512H0v192h192v-64h640v64h192V768h-64zM64 128h64v64H64v-64z m0 768v-64h64v64H64z m896 0h-64v-64h64v64zM256 768V256h128v512H256z m192-320h128v320H448V448z m192 192h128v128H640V640zM512 288c0-17.664 14.336-32 32-32h160V96c0-17.664 14.336-32 32-32s32 14.336 32 32v160h160c17.664 0 32 14.336 32 32s-14.336 32-32 32H768v160c0 17.664-14.336 32-32 32s-32-14.336-32-32V320H544c-17.664 0-32-14.336-32-32z" ></path></symbol><symbol id="icon-ai13" viewBox="0 0 1024 1024"><path d="M863.719038 159.366637l-705.295378 0c-48.443315 0-88.129176 39.690978-88.129176 88.161922l0 528.943904c0 48.474015 39.685861 88.161922 88.129176 88.161922l705.295378 0c48.443315 0 88.134293-39.687908 88.134293-88.161922l0-528.943904C951.853331 199.056592 912.162354 159.366637 863.719038 159.366637M643.272277 776.472464l-484.84964 0 0-176.324868 484.84964 0L643.272277 776.472464zM643.272277 556.053332l-484.84964 0 0-176.296215 484.84964 0L643.272277 556.053332zM863.719038 776.472464 687.394171 776.472464l0-396.659065 176.324868 0L863.719038 776.472464z" ></path></symbol><symbol id="icon-qiehuanwenjianjia" viewBox="0 0 1024 1024"><path d="M409.6 102.4L512 204.8h307.2a102.4 102.4 0 0 1 102.144 94.72l0.256 7.68v512a102.4 102.4 0 0 1-94.72 102.144l-7.68 0.256H512v-76.8h281.6a51.2 51.2 0 0 0 50.842-45.21l0.358-5.99V332.8a51.2 51.2 0 0 0-45.21-50.842l-5.99-0.358H486.4L384 179.2H230.4a51.2 51.2 0 0 0-50.842 45.21l-0.358 5.99v179.2h-76.8V204.8a102.4 102.4 0 0 1 94.72-102.144l7.68-0.256h204.8z m217.6 588.8a38.4 38.4 0 1 1 0 76.8H358.4v99.584a25.6 25.6 0 0 1-41.83 19.814L132.3 736.614a25.6 25.6 0 0 1 16.231-45.414zM447.59 389.99l3.84 2.612L635.7 543.386a25.6 25.6 0 0 1-11.623 45.004l-4.608 0.41H140.8a38.4 38.4 0 0 1-5.222-76.442L140.8 512h268.8v-99.584a25.6 25.6 0 0 1 37.99-22.426z" ></path></symbol><symbol id="icon-baogao" viewBox="0 0 1104 1024"><path d="M265.401 1024a174.066 174.066 0 0 1-173.56-173.56V315.3a4.194 4.194 0 0 0-4.338-4.34H41.22A39.63 39.63 0 0 1 0 273.356V123.66C0 55.684 59.3 0 132.339 0h648.678a132.411 132.411 0 0 1 132.339 132.339v553.22a4.194 4.194 0 0 0 4.339 4.34h146.079a40.714 40.714 0 0 1 41.22 41.22v159.819a132.411 132.411 0 0 1-132.339 132.339l-707.254 0.723z m653.017-260.339A4.194 4.194 0 0 0 914.08 768v123.661a59.3 59.3 0 0 0 118.599 0V768a4.194 4.194 0 0 0-4.339-4.339z m-749.198-452.7a4.194 4.194 0 0 0-4.339 4.338v534.419a100.737 100.737 0 0 0 100.52 100.52h582.147a3.977 3.977 0 0 0 3.616-2.17 4.628 4.628 0 0 0 0-4.34 132.7 132.7 0 0 1-10.848-52.79V133.062a59.3 59.3 0 0 0-118.598 0v140.294a39.195 39.195 0 0 1-41.22 37.604zM132.34 73.762c-32.542 0-59.3 22.418-59.3 49.898v109.92a4.194 4.194 0 0 0 4.34 4.34h566.237a4.194 4.194 0 0 0 4.339-4.34V133.063a132.7 132.7 0 0 1 10.847-52.79c0.723-1.447 0-2.893 0-4.34a3.977 3.977 0 0 0-3.616-2.17z m169.22 692.068a36.881 36.881 0 0 1 0-73.763h402.08a36.881 36.881 0 0 1 0 73.763z m0-196.701a36.881 36.881 0 1 1 0-73.763h402.08a36.881 36.881 0 1 1 0 73.763z" ></path></symbol><symbol id="icon-xinghao" viewBox="0 0 1024 1024"><path d="M580.583 425.004c52.988-24.574 104.44-49.276 152.82-73.594 48.381-24.703 87.034-42.877 115.704-54.268 28.67-11.136 51.58-17.023 69.115-17.023a104.952 104.952 0 0 1 74.235 28.798 93.177 93.177 0 0 1 31.485 71.802c0 16.383-5.12 33.534-15.358 51.069-10.24 17.534-21.247 28.926-32.638 33.79-105.976 41.468-222.832 72.058-350.054 90.872 23.038 20.99 51.452 49.405 85.113 84.474 33.79 35.582 51.453 54.268 52.86 56.7 12.416 17.023 29.566 38.397 51.837 63.74 22.142 25.597 37.501 45.18 46.076 59.643a99.833 99.833 0 0 1 13.055 52.092 93.817 93.817 0 0 1-29.693 68.731 103.16 103.16 0 0 1-76.41 29.694c-31.23 0-66.172-24.318-105.337-72.443-39.037-48.124-89.465-135.158-151.029-260.46A12540.003 12540.003 0 0 1 386.677 862.22a387.3 387.3 0 0 1-61.563 81.53 96.889 96.889 0 0 1-67.835 27.774 101.625 101.625 0 0 1-76.026-31.358c-19.711-20.862-30.078-43.517-30.078-66.939 0-22.142 4.095-38.909 12.287-50.172 75.514-102.393 154.356-191.602 236.782-266.605a2401.103 2401.103 0 0 1-184.818-35.709 1163.818 1163.818 0 0 1-172.531-57.724c-9.984-5.12-19.583-16.382-29.054-33.917A104.696 104.696 0 0 1 0.018 380.72a93.433 93.433 0 0 1 31.358-71.675 102.648 102.648 0 0 1 72.186-28.926c19.839 0 44.285 5.887 73.979 17.79 29.438 11.904 67.067 29.054 112.632 51.453 45.564 22.526 97.656 47.74 155.892 75.514a1833.849 1833.849 0 0 1-26.494-177.267 1574.54 1574.54 0 0 1-10.367-137.078c0-30.205 9.599-56.06 28.798-78.074A95.481 95.481 0 0 1 512.62 0.076c29.822 0 54.012 10.75 73.339 32.51 19.454 21.886 29.054 50.683 29.054 86.649 0 9.855-1.664 29.182-4.48 58.491-2.56 29.182-7.04 64.252-12.16 105.465-5.375 41.34-11.39 88.697-17.79 141.813z" fill="#FF4444" ></path></symbol><symbol id="icon-mima" viewBox="0 0 1024 1024"><path d="M776.86 376.04c-22.05 0-40.16-16.24-43.91-37.98-18.08-104.98-109.79-185.1-219.84-185.1s-201.76 80.13-219.84 185.1c-3.74 21.73-21.85 37.98-43.91 37.98-27.05 0-48.82-24.04-44.44-50.73 24.3-148.16 153.25-261.58 308.19-261.58S796.99 177.15 821.3 325.31c4.38 26.69-17.39 50.73-44.44 50.73zM850.18 418.32H180.33c-37.98 0-68.76 30.79-68.76 68.76v403.71c0 37.98 30.79 68.76 68.76 68.76h665.36c37.97 0 68.75-30.77 68.77-68.74l0.19-408c0.02-35.61-28.85-64.49-64.47-64.49zM557.73 762.56c0 24.64-19.97 44.62-44.62 44.62-24.64 0-44.62-19.97-44.62-44.62v-89.23c0-24.64 19.97-44.62 44.62-44.62 24.64 0 44.62 19.98 44.62 44.62v89.23z" ></path></symbol><symbol id="icon-zhanghao" viewBox="0 0 1024 1024"><path d="M407.61 578.87c-174.46 0-304.73 113.04-304.73 277.2v17.69c0 85.81 139.6 85.81 316.37 85.81h187.73c169.75 0 316.37 0 316.37-85.81v-17.69c0-164.16-130.28-277.2-304.73-277.2H407.61zM503.71 535.67c138.19 0 250.63-105.81 250.63-235.94 0-130.06-112.44-235.86-250.63-235.86-138.11 0-250.56 105.81-250.56 235.86 0 130.13 112.45 235.94 250.56 235.94z" ></path></symbol><symbol id="icon-xiangqingye-37" viewBox="0 0 1024 1024"><path d="M368.64 34.133333H112.64C68.266667 34.133333 34.133333 68.266667 34.133333 112.64v256c0 23.893333 17.066667 40.96 40.96 40.96s40.96-17.066667 40.96-40.96V116.053333h252.586667c23.893333 0 40.96-17.066667 40.96-40.96S389.12 34.133333 368.64 34.133333zM911.36 34.133333h-256c-23.893333 0-40.96 17.066667-40.96 40.96s17.066667 40.96 40.96 40.96h252.586667v252.586667c0 23.893333 17.066667 40.96 40.96 40.96s40.96-17.066667 40.96-40.96V112.64C989.866667 68.266667 955.733333 34.133333 911.36 34.133333zM368.64 907.946667H116.053333v-252.586667c0-23.893333-17.066667-40.96-40.96-40.96S34.133333 634.88 34.133333 655.36v256C34.133333 955.733333 68.266667 989.866667 112.64 989.866667h256c23.893333 0 40.96-17.066667 40.96-40.96s-20.48-40.96-40.96-40.96zM948.906667 617.813333c-23.893333 0-40.96 17.066667-40.96 40.96v252.586667h-252.586667c-23.893333 0-40.96 17.066667-40.96 40.96s17.066667 40.96 40.96 40.96h256c40.96 0 78.506667-34.133333 78.506667-78.506667v-256c0-23.893333-17.066667-40.96-40.96-40.96z" fill="#3366CC" ></path><path d="M416.426667 488.106667L307.2 344.746667c-13.653333-17.066667-34.133333-20.48-51.2-6.826667-17.066667 13.653333-20.48 34.133333-6.826667 51.2L337.92 512l-95.573333 126.293333c-13.653333 17.066667-10.24 37.546667 6.826666 51.2 6.826667 3.413333 13.653333 6.826667 20.48 6.826667 10.24 0 23.893333-6.826667 30.72-13.653333l112.64-146.773334c10.24-17.066667 10.24-34.133333 3.413334-47.786666z" fill="#F4A914" ></path><path d="M597.333333 488.106667L488.106667 341.333333c-13.653333-17.066667-34.133333-20.48-51.2-6.826666-17.066667 13.653333-20.48 34.133333-6.826667 51.2l92.16 122.88-95.573333 126.293333c-13.653333 17.066667-10.24 37.546667 6.826666 51.2 6.826667 3.413333 13.653333 6.826667 20.48 6.826667 10.24 0 23.893333-6.826667 30.72-13.653334l112.64-146.773333c10.24-13.653333 10.24-30.72 0-44.373333z" fill="#F4A914" ></path><path d="M778.24 488.106667L669.013333 341.333333c-13.653333-17.066667-34.133333-20.48-51.2-6.826666-17.066667 13.653333-20.48 34.133333-6.826666 51.2l92.16 122.88-95.573334 126.293333c-6.826667 6.826667-6.826667 17.066667-6.826666 27.306667 0 10.24 6.826667 17.066667 13.653333 23.893333 6.826667 3.413333 13.653333 6.826667 23.893333 6.826667 10.24 0 23.893333-6.826667 30.72-13.653334l112.64-146.773333c6.826667-13.653333 6.826667-30.72-3.413333-44.373333z" fill="#F4A914" ></path></symbol><symbol id="icon-gongzhuangmoju" viewBox="0 0 1024 1024"><path d="M192 170.666667A106.965333 106.965333 0 0 0 85.333333 277.333333V426.666667h256l42.666667 85.333333h256l42.666667-85.333333h256V277.333333A106.965333 106.965333 0 0 0 832 170.666667z" fill="#3B709C" ></path><path d="M384 512l-42.666667-85.333333h341.333334l-42.666667 85.333333z m-298.666667-85.333333V256a85.333333 85.333333 0 0 1 85.333334-85.333333h682.666666a85.333333 85.333333 0 0 1 85.333334 85.333333v170.666667zM853.333333 853.333333H170.666667a85.333333 85.333333 0 0 1-85.333334-85.333333v-256h213.333334l42.666666 85.333333h341.333334l42.666666-85.333333h213.333334v256a85.333333 85.333333 0 0 1-85.333334 85.333333z" fill="#2C6798" ></path></symbol><symbol id="icon-jiagongguochengxinxi" viewBox="0 0 1024 1024"><path d="M345.216 664.192a315.84 315.84 0 0 1 93.12-224.64 315.84 315.84 0 0 1 100.992-68.16 315.392 315.392 0 0 1 123.648-24.96 315.392 315.392 0 0 1 158.72 42.368v-264a24.768 24.768 0 0 0-24.768-24.768H559.296a32.64 32.64 0 0 1 0.704 6.976v133.184c0 19.2-15.616 34.816-34.816 34.816H395.072a34.816 34.816 0 0 1-34.752-34.816v-133.12a32.64 32.64 0 0 1 0.64-6.976H123.456a24.768 24.768 0 0 0-24.768 24.832v676.544c0 13.76 11.072 24.832 24.768 24.832h266.24a316.224 316.224 0 0 1-44.416-162.112zM662.976 406.4a257.792 257.792 0 1 0 0 515.52 257.792 257.792 0 0 0 0-515.52z m112.256 293.376a104.704 104.704 0 0 1-107.328 25.216l-68.48 68.48a46.528 46.528 0 0 1-65.728-65.664l68.48-68.48a104.512 104.512 0 0 1 140.8-129.28l-67.072 67.072 10.88 42.88 43.328 11.328 67.072-67.136c16.64 38.336 9.216 84.416-21.952 115.584z m-220.16 51.456a20.928 20.928 0 1 0 41.856 0 20.928 20.928 0 0 0-41.856 0z" ></path></symbol><symbol id="icon-pingtaiguanli" viewBox="0 0 1024 1024"><path d="M1024 806.4V25.6c0-12.8-12.8-25.6-25.6-25.6H25.6C12.8 0 0 12.8 0 25.6v780.8h435.2v166.4H236.8v51.2h556.8v-51.2H588.8v-166.4H1024zM320 281.6c-12.8-12.8-19.2-25.6-32-32l44.8-76.8c44.8 25.6 96 12.8 121.6-32 12.8-12.8 12.8-32 12.8-44.8h89.6c0 51.2 38.4 83.2 89.6 83.2 12.8 0 32-6.4 44.8-12.8l44.8 76.8c-44.8 25.6-57.6 76.8-32 115.2 12.8 12.8 19.2 25.6 32 32l-44.8 76.8c-44.8-19.2-96-6.4-121.6 38.4-12.8 12.8-12.8 25.6-12.8 44.8H467.2c0-44.8-38.4-83.2-89.6-83.2-12.8 0-32 6.4-44.8 12.8l-44.8-83.2c38.4-25.6 51.2-76.8 32-115.2zM102.4 704v-51.2h825.6v51.2H102.4zM512 416c51.2 0 96-38.4 96-89.6S569.6 236.8 512 236.8c-51.2 0-96 38.4-96 89.6 0 51.2 44.8 89.6 96 89.6z" ></path></symbol><symbol id="icon-zhucaidanguanli" viewBox="0 0 1169 1024"><path d="M787.333831 588.946093a75.189984 75.189984 0 0 0-75.093984 75.092984 75.189984 75.189984 0 0 0 75.093984 75.093984 75.165984 75.165984 0 0 0 75.067984-75.093984 75.165984 75.165984 0 0 0-75.067984-75.092984m0 222.841953a147.919968 147.919968 0 0 1-147.748968-147.748969c0-81.455982 66.291986-147.747968 147.748968-147.747968 81.431983 0 147.747968 66.291986 147.747968 147.747968 0 81.480982-66.315986 147.748968-147.747968 147.748969m89.452981 102.106978c0.342 0.244 1.317 0.585 2.315999 0.585h0.122l71.484985-39.496992c-1.706-4.022999-9.605998-23.478995-9.605998-43.739991a113.858976 113.858976 0 0 1 107.739977-113.613975c0.853-4.729999 5.557999-31.524993 5.557998-51.639989s-4.704999-46.88399-5.558998-51.637989a113.858976 113.858976 0 0 1-107.738977-113.565976c0-20.357996 7.923998-39.813991 9.605998-43.81299l-70.313985-39.057992-0.293-0.025a5.339999 5.339999 0 0 0-2.706 0.732 196.753958 196.753958 0 0 1-26.014994 21.819995c-21.698995 15.238997-42.153991 22.967995-60.951987 22.967995-18.919996 0-39.594991-7.874998-61.390987-23.405995a194.705958 194.705958 0 0 1-26.160994-22.283995 5.777999 5.777999 0 0 0-2.729999-0.707h-0.245l-72.824985 40.032992c1.706 4.046999 9.580998 23.479995 9.580998 43.73999A113.858976 113.858976 0 0 1 528.895886 614.350088c-0.854 4.729999-5.509999 31.524993-5.509998 51.638989s4.655999 46.90899 5.533998 51.662989a113.858976 113.858976 0 0 1 107.763977 113.589975c0 20.334996-7.972998 39.863991-9.679998 43.788991l68.973985 38.545992h0.146c1.024 0 1.95-0.365 2.317-0.585a200.849957 200.849957 0 0 1 26.428994-23.161995c22.088995-16.188997 43.079991-24.429995 62.414987-24.429995 19.552996 0 40.715991 8.387998 62.950986 24.917995 14.920997 11.068998 25.258995 22.185995 26.550995 23.575995m22.673995 108.397976c-13.774997-0.025-27.135994-5.704999-35.765993-15.213996-11.775997-12.896997-49.005989-46.44599-79.530982-46.44599-30.280993 0-68.119985 33.767993-78.993984 45.54399-8.606998 9.386998-21.869995 14.969997-35.498992 14.969997-6.484999 0-12.604997-1.243-18.187996-3.706l-0.975-0.414-92.69698-51.833988-0.926-0.683a44.46999 44.46999 0 0 1-14.920996-53.735989c0.049-0.146 8.532998-19.699996 8.532998-37.594992a98.376979 98.376979 0 0 0-98.254979-98.254978h-3.900999c-15.505997 0-28.159994-13.799997-32.182993-35.108993-0.341-1.706-7.923998-42.178991-7.923999-74.044984 0-31.913993 7.557998-72.361984 7.899999-74.117984 4.119999-21.576995 16.992996-35.449992 32.816993-35.083993h3.266999a98.400979 98.400979 0 0 0 98.279979-98.303978c0-17.846996-8.484998-37.399992-8.558998-37.619992a44.34899 44.34899 0 0 1 15.067996-53.661989l0.95-0.658 97.840979-53.759988 1.024-0.415c5.485999-2.364999 11.507998-3.534999 17.895996-3.534999 13.604997 0 26.891994 5.436999 35.595992 14.628997 11.580998 12.116997 48.17699 43.641991 77.774984 43.64199 29.354994 0 65.755986-30.914993 77.287983-42.812991 8.654998-8.996998 21.844995-14.335997 35.302992-14.335997 6.509999 0 12.653997 1.219 18.285997 3.657l0.974999 0.414 94.47698 52.516988 0.95 0.658c16.895996 11.751997 23.332995 34.889993 14.945997 53.735989-0.049 0.146-8.532998 19.699996-8.532999 37.545992a98.400979 98.400979 0 0 0 98.254979 98.279978h3.291c15.774997-0.341 28.719994 13.506997 32.816993 35.107993 0.317 1.707 7.899998 42.203991 7.899998 74.069984 0 31.889993-7.582998 72.410984-7.948998 74.117984-4.046999 21.551995-16.992996 35.424992-32.767993 35.059993h-3.291a98.400979 98.400979 0 0 0-98.254979 98.278978c0 17.846996 8.483998 37.449992 8.556999 37.619992a44.42199 44.42199 0 0 1-15.017997 53.710989l-0.927 0.683-96.133979 53.100988-0.975 0.415a44.88499 44.88499 0 0 1-17.846996 3.583999z m222.061952-705.339848a48.76199 48.76199 0 1 1-97.523979 0V121.977194c0-13.457997-10.873998-24.453995-24.307995-24.453995h-877.859811c-13.262997 0-24.306995 10.970998-24.306995 24.453995v584.995874c0 13.457997 10.873998 24.453995 24.307995 24.453995h219.500953a48.76199 48.76199 0 1 1 0 97.523979H48.907989A48.76199 48.76199 0 0 1 0 780.190052V48.76221C0 21.822215 21.893995 0.00022 48.907989 0.00022h1023.706781a48.76199 48.76199 0 0 1 48.907989 48.76199v268.189942zM219.427953 975.23701c0-26.940994 21.991995-48.76199 48.981989-48.761989h194.607959a48.76199 48.76199 0 1 1 0 97.523979H268.433942a48.76199 48.76199 0 0 1-49.005989-48.76199z" ></path></symbol><symbol id="icon-caidanguanli" viewBox="0 0 1024 1024"><path d="M414.2 78H158.6c-41.5 0-75.3 33.8-75.3 75.3v255.5c0 41.5 33.8 75.3 75.3 75.3h255.5c41.5 0 75.3-33.8 75.3-75.3V153.3c0-41.5-33.7-75.3-75.2-75.3z m5.2 330.8c0 2.9-2.4 5.3-5.3 5.3H158.6c-2.9 0-5.3-2.4-5.3-5.3V153.3c0-2.9 2.4-5.3 5.3-5.3h255.5c2.9 0 5.3 2.4 5.3 5.3v255.5zM414.2 544.8H158.6c-41.5 0-75.3 33.8-75.3 75.3v255.5c0 41.5 33.8 75.3 75.3 75.3h255.5c41.5 0 75.3-33.8 75.3-75.3V620.1c0-41.5-33.7-75.3-75.2-75.3z m5.2 330.8c0 2.9-2.4 5.3-5.3 5.3H158.6c-2.9 0-5.3-2.4-5.3-5.3V620.1c0-2.9 2.4-5.3 5.3-5.3h255.5c2.9 0 5.3 2.4 5.3 5.3v255.5zM908.8 119.3H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35zM908.8 343.8H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35zM908.8 568.3H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35zM908.8 792.8H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35z" ></path></symbol><symbol id="icon-jueseguanli" viewBox="0 0 1024 1024"><path d="M874.9 577.3c-26.1-27.2-56.8-48.9-90.3-64.1 5.4-4.6 10.6-9.6 15.5-14.8 32.3-34.7 50.1-79.8 50.1-127.2 0-102.9-83.7-186.7-186.7-186.7-11 0-21.8 0.9-32.5 2.8-7.1-9.6-14.9-18.7-23.4-27.2-44.6-44.6-103.9-69.2-167-69.2s-122.4 24.6-167 69.2-69.2 103.9-69.2 167 24.6 122.4 69.2 167c10.8 10.8 22.4 20.4 34.8 28.7-4.9 1.8-9.7 3.8-14.5 5.8-44.9 19-85.2 46.2-119.9 80.8-34.6 34.6-61.8 75-80.8 119.9-19.7 46.5-29.6 95.9-29.6 146.8 0 17.7 1.2 35.5 3.7 52.9l69.3-9.7c-2-14.2-3-28.7-3-43.1 0-169.4 137.8-307.1 307.1-307.1s307.1 137.8 307.1 307.1c0 14.4-1 28.9-3 43.1l69.3 9.7c2.4-17.4 3.7-35.2 3.7-52.9 0-50.9-10-100.3-29.6-146.8-19-44.9-46.2-85.2-80.8-119.9-34.6-34.6-74.9-61.8-119.9-80.8-4.8-2-9.7-4-14.6-5.8 12.3-8.4 24-18 34.8-28.7 44.6-44.6 69.2-103.9 69.2-167 0-25-3.9-49.4-11.3-72.6 63.4 1.1 114.7 53 114.7 116.6 0 45.5-26.6 85.6-65.3 104.7-16.3 8.1-26.8 24.4-26.8 42.6v1c0 21.2 14.1 40 34.6 45.5 94.9 25.8 163.8 112.4 163.8 215 0 10.5-0.7 21-2.2 31.3l69.3 9.7c1.9-13.5 2.9-27.3 2.9-41-0.1-75.8-29.1-147.8-81.7-202.6z m-434.3-84c-91.6 0-166.2-74.6-166.2-166.2S349 160.9 440.6 160.9s166.2 74.6 166.2 166.2-74.5 166.2-166.2 166.2z" ></path></symbol><symbol id="icon-zhiweiguanli" viewBox="0 0 1024 1024"><path d="M878.4 243.5h-91.2v-41.2c0-58.6-47.7-106.2-106.2-106.2H354.2c-58.6 0-106.2 47.7-106.2 106.2v41.2h-91.2c-43.2 0-78.4 35.1-78.4 78.4V856c0 43.2 35.1 78.4 78.4 78.4h721.5c43.2 0 78.4-35.1 78.4-78.4V321.8c0-43.2-35.1-78.3-78.3-78.3zM318 202.3c0-20 16.2-36.2 36.2-36.2H681c20 0 36.2 16.3 36.2 36.2v41.2H318v-41.2zM156.8 313.5h721.5c4.6 0 8.4 3.7 8.4 8.4V554H692.4c-14.8-45.3-57.4-78.2-107.6-78.2H450.4c-50.2 0-92.9 32.9-107.6 78.2H148.5V321.8c0-4.6 3.7-8.3 8.3-8.3zM628 588.9c0 23.8-19.4 43.2-43.2 43.2H450.4c-23.8 0-43.2-19.4-43.2-43.2 0-23.8 19.4-43.2 43.2-43.2h134.3c23.9 0 43.3 19.4 43.3 43.2z m250.4 275.5H156.8c-4.6 0-8.4-3.7-8.4-8.4V623.9h194.3c14.8 45.3 57.4 78.2 107.6 78.2h134.3c50.2 0 92.9-32.9 107.6-78.2h194.3V856c0.2 4.6-3.5 8.4-8.1 8.4z" ></path></symbol><symbol id="icon-bumenguanli" viewBox="0 0 1024 1024"><path d="M322.5 62h384.6v70H322.5z" ></path><path d="M870.2 62h-59.3v70h59.3c7.2 0 13 5.8 13 13v733.9c0 7.2-5.8 13-13 13h-720c-7.2 0-13-5.8-13-13V145c0-7.2 5.8-13 13-13h68.6V62h-68.6c-45.8 0-83 37.2-83 83v733.9c0 45.8 37.2 83 83 83h720c45.8 0 83-37.2 83-83V145c0-45.8-37.3-83-83-83z" ></path><path d="M295 806.2c-0.5-5.7-0.7-11.6-0.7-17.3 0-119 96.8-215.8 215.8-215.8S726 669.8 726 788.8c0 5.8-0.2 11.6-0.7 17.3l69.8 5.6c0.6-7.6 0.9-15.3 0.9-22.9 0-76.4-29.7-148.1-83.7-202.1-29.7-29.8-64.9-52.1-103.3-66.2 45.6-31.5 75.5-84.1 75.5-143.5 0-96.1-78.2-174.4-174.4-174.4-96.1 0-174.4 78.2-174.4 174.4 0 59.5 29.9 112 75.5 143.5C373 534.6 337.8 557 308 586.7c-54 54-83.7 125.8-83.7 202.1 0 7.6 0.3 15.3 0.9 22.9l69.8-5.5z m215.2-533.6c57.5 0 104.4 46.8 104.4 104.4 0 57.5-46.8 104.4-104.4 104.4-57.5 0-104.4-46.8-104.4-104.4 0-57.6 46.8-104.4 104.4-104.4z" ></path></symbol><symbol id="icon-gerenzhongxin" viewBox="0 0 1024 1024"><path d="M930.4 337.3c-22.7-53.7-55.2-101.9-96.6-143.3-41.4-41.4-89.6-73.9-143.3-96.6C634.9 73.9 575.9 62 515.1 62c-60.8 0-119.9 11.9-175.5 35.4-53.7 22.7-101.9 55.2-143.3 96.6-41.4 41.4-73.9 89.6-96.6 143.3-23.5 55.6-35.4 114.6-35.4 175.5 0 50.5 8.3 100.1 24.7 147.4l66.1-22.9c-13.8-39.9-20.8-81.8-20.8-124.5 0-209.9 170.8-380.7 380.7-380.7 209.9 0 380.8 170.8 380.8 380.7 0 41.6-6.7 82.5-19.8 121.5l66.3 22.3c15.6-46.2 23.5-94.7 23.5-143.9 0-60.8-11.9-119.8-35.4-175.4z" ></path><path d="M656.9 422.2c0-76.9-62.6-139.5-139.5-139.5s-139.5 62.6-139.5 139.5 62.6 139.5 139.5 139.5 139.5-62.6 139.5-139.5z m-209 0c0-38.3 31.2-69.5 69.5-69.5s69.5 31.2 69.5 69.5-31.2 69.5-69.5 69.5-69.5-31.2-69.5-69.5zM713.8 627.8c-62-27.2-128.1-40.9-196.4-40.9-69 0-135.7 14-198.2 41.7-60.4 26.7-114.1 64.9-159.5 113.3l-20.3 21.7 18.1 23.6c41.2 53.6 94.8 98 155 128.3 63.2 31.8 131.3 48 202.6 48 71.9 0 140.6-16.4 204.2-48.8 60.7-30.9 114.5-76 155.6-130.4l17.9-23.7-20.5-21.6c-45.3-47.6-98.6-85-158.5-111.2zM515.1 893.5c-109 0-210.3-45.3-282.5-125.4 77.7-71.9 177.7-111.2 284.8-111.2 105.8 0 204.9 38.4 282.2 108.8-72.2 81.6-174.3 127.8-284.5 127.8z" ></path></symbol><symbol id="icon-yonghuguanli" viewBox="0 0 1024 1024"><path d="M751.4 553.2c-42.5-38.5-92.1-67.1-145.5-84.6 53.2-38.9 87.8-101.8 87.8-172.7C693.7 178 597.7 82 479.8 82c-57.1 0-110.8 22.2-151.2 62.6C288.2 185 266 238.7 266 295.8s22.2 110.8 62.6 151.2c7.8 7.8 16.2 15 25 21.4-10.5 3.5-20.9 7.3-31.2 11.7-48.2 20.4-91.4 49.5-128.5 86.7s-66.3 80.4-86.7 128.5c-21.1 49.9-31.8 102.9-31.8 157.4 0 24.8 2.3 49.7 6.8 73.9l68.8-12.7c-3.7-20-5.6-40.6-5.6-61.2 0-184.4 150-334.4 334.4-334.4 83.2 0 163 30.8 224.5 86.6l47.1-51.7zM479.8 152c79.3 0 143.9 64.5 143.9 143.9s-64.5 143.9-143.9 143.9S336 375.2 336 295.9 400.5 152 479.8 152zM726.3 665.3h213.8v70H726.3zM503 831.6h437.1v70H503z" ></path></symbol><symbol id="icon-app" viewBox="0 0 1024 1024"><path d="M363.485867 865.117867h305.5616c21.6576 0 39.2192-17.194667 39.2192-38.4s-17.5616-38.4-39.2192-38.4H363.485867c-21.6576 0-39.2192 17.194667-39.2192 38.4s17.5616 38.4 39.2192 38.4z" fill="#A6ADB4" ></path><path d="M945.288533 699.835733a40.448 40.448 0 0 0-43.195733 43.1872v147.037867a46.865067 46.865067 0 0 1-45.960533 48.708267H166.766933a46.882133 46.882133 0 0 1-45.038933-48.708267v-147.029333a40.439467 40.439467 0 1 0-80.887467 0v147.029333a125.883733 125.883733 0 0 0 125.9264 128.657067h693.0432c70.203733-1.006933 126.4384-58.461867 125.9264-128.657067v-147.029333a40.430933 40.430933 0 0 0-40.448-43.195734zM40.840533 127.735467v147.959466a39.517867 39.517867 0 0 0 79.044267 0V127.735467a45.943467 45.943467 0 0 1 46.882133-47.786667h693.0432a46.882133 46.882133 0 0 1 45.960534 47.786667v147.959466a39.509333 39.509333 0 0 0 39.517866 39.509334 40.448 40.448 0 0 0 40.448-39.509334V127.735467C986.248533 58.052267 930.423467 1.024 860.7232 0H166.775467A125.934933 125.934933 0 0 0 40.840533 127.744z m168.4992 427.972266H326.229333L357.316267 640H418.133333L295.150933 315.733333h-52.701866L119.466667 640h60.817066l29.056-84.292267zM269.124267 392.533333L307.2 503.466667h-76.8l38.724267-110.933334z m231.552 131.959467h32.631466a123.246933 123.246933 0 0 0 88.192-28.535467c23.389867-19.959467 36.394667-49.134933 35.413334-79.488 1.6384-28.245333-9.838933-55.722667-31.249067-74.743466a127.573333 127.573333 0 0 0-84.0192-25.813334H443.733333V640h56.942934V524.4928zM503.466667 366.933333h32.136533c42.180267 0 61.602133 17.493333 61.602133 53.162667 1.092267 16.0256-4.8128 31.701333-16.068266 42.666667a71.364267 71.364267 0 0 1-51.5584 14.677333H503.466667V366.933333z m286.293333-51.0976H691.2V640h57.3184V524.4672h32.853333c31.837867 1.928533 63.189333-8.311467 87.381334-28.544 23.543467-19.959467 36.625067-49.152 35.643733-79.505067 1.536-28.100267-9.710933-55.441067-30.754133-74.752a131.84 131.84 0 0 0-83.882667-25.8304z m39.4752 147.131734a73.813333 73.813333 0 0 1-49.527467 14.72H750.933333V366.933333h32.119467c42.1632 0 61.576533 17.527467 61.576533 53.2736 1.262933 15.957333-4.394667 31.650133-15.394133 42.752z" fill="#A6ADB4" ></path></symbol><symbol id="icon-yepian" viewBox="0 0 1024 1024"><path d="M807.936 99.328c-17.408 0-32.256 9.216-40.448 23.552h-348.16L284.672 355.84l35.84 35.84 126.976-219.648h321.536c8.192 12.8 22.528 20.992 38.912 20.992 25.6 0 46.592-20.992 46.592-46.592s-20.992-47.104-46.592-47.104z" ></path><path d="M301.056 50.688c-8.704 14.848-7.68 32.768 0 46.592L127.488 399.36l134.656 232.448 48.64-13.312L183.808 399.36l160.256-279.04c15.36-1.024 29.696-9.216 37.888-23.04 12.8-22.528 5.12-50.688-17.408-63.488s-50.688-5.632-63.488 16.896z" ></path><path d="M15.872 467.456c8.704 14.848 24.064 23.552 40.448 23.552L228.352 793.6l268.8 1.536 13.312-48.64-253.44-1.536-159.232-279.552c6.656-13.312 7.168-30.208-1.024-44.032-12.8-22.528-40.96-30.208-63.488-17.408-22.528 12.8-30.208 40.96-17.408 63.488z" ></path><path d="M216.064 924.672c17.408 0 32.256-9.216 40.448-23.552h348.16l134.144-232.448-35.84-35.84-126.976 219.648H254.976c-8.192-12.8-22.528-20.992-38.912-20.992-25.6 0-46.592 20.992-46.592 46.592s20.992 46.592 46.592 46.592z" ></path><path d="M722.944 973.312c8.704-14.848 7.68-32.768 0-46.592l173.568-302.08-134.656-232.448-48.64 13.312 127.488 219.136-160.256 279.04c-15.36 1.024-29.696 9.216-37.888 23.04-12.8 22.528-5.12 50.688 17.408 63.488 22.016 13.312 50.176 5.632 62.976-16.896z" ></path><path d="M1008.128 556.544c-8.704-14.848-24.064-23.552-40.448-23.552L795.648 230.4l-268.8-1.536-13.312 48.64 253.44 1.536 159.232 279.552c-6.656 13.312-7.168 30.208 1.024 44.032 12.8 22.528 40.96 30.208 63.488 17.408 22.528-12.8 30.208-40.96 17.408-63.488zM512 391.168C445.44 391.168 391.168 445.44 391.168 512S445.44 632.832 512 632.832s120.832-54.272 120.832-120.832S578.56 391.168 512 391.168z m0 196.096c-41.472 0-75.264-33.792-75.264-75.264s33.792-75.264 75.264-75.264 75.264 33.792 75.264 75.264-33.792 75.264-75.264 75.264z" ></path></symbol><symbol id="icon-left-circle-fill" viewBox="0 0 1024 1024"><path d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64z m104 316.9c0 10.2-4.9 19.9-13.2 25.9L457.4 512l145.4 105.2c8.3 6 13.2 15.6 13.2 25.9V690c0 6.5-7.4 10.3-12.7 6.5l-246-178c-4.4-3.2-4.4-9.7 0-12.9l246-178c5.3-3.8 12.7-0.1 12.7 6.5v46.8z" ></path></symbol><symbol id="icon-right-circle-fill" viewBox="0 0 1024 1024"><path d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64z m154.7 454.5l-246 178c-5.3 3.8-12.7 0-12.7-6.5v-46.9c0-10.2 4.9-19.9 13.2-25.9L566.6 512 421.2 406.8c-8.3-6-13.2-15.6-13.2-25.9V334c0-6.5 7.4-10.3 12.7-6.5l246 178c4.4 3.2 4.4 9.8 0 13z" ></path></symbol><symbol id="icon-xitongguanli" viewBox="0 0 1026 1024"><path d="M400.896 67.072H140.8c-24.064 0-46.592 11.264-59.392 29.696-9.216 12.8-14.848 27.648-14.848 44.544v259.584c0 40.96 33.28 74.24 74.24 74.24h259.584c40.96 0 74.24-33.28 74.24-74.24V141.312c0.512-40.96-33.28-74.24-73.728-74.24z m0 361.984v9.216-9.216z m335.872 83.456c18.432 0 35.328-7.168 48.128-20.48L939.008 337.92c12.8-12.8 20.48-29.696 20.48-48.128s-7.168-35.328-20.48-48.128l-154.112-155.648c-26.112-26.112-70.656-26.112-96.256 0l-154.112 154.112c-12.8 12.8-20.48 29.696-20.48 48.128 0 18.432 7.168 35.328 20.48 48.128l154.112 154.112c12.8 14.336 29.184 22.016 48.128 22.016z m0-369.152l146.432 146.432-146.432 146.432-144.896-146.432L736.768 143.36z m-335.872 406.016H140.8c-40.96 0-74.24 33.28-74.24 74.24v259.584c0 40.96 33.28 74.24 74.24 74.24h259.584c40.96 0 74.24-33.28 74.24-74.24v-259.584c0.512-40.448-33.28-74.24-73.728-74.24z m0 352.768v18.432-18.432z m484.352-352.768h-259.584c-40.96 0-74.24 33.28-74.24 74.24v259.584c0 40.96 33.28 74.24 74.24 74.24h259.584c40.96 0 74.24-33.28 74.24-74.24v-259.584c0-40.448-33.792-74.24-74.24-74.24z" ></path></symbol><symbol id="icon-gongjianku" viewBox="0 0 1024 1024"><path d="M798.72 320v446.976H223.232V320H63.488v532.48c0 41.472 33.792 75.264 75.264 75.264h745.472c41.472 0 75.264-33.792 75.264-75.264v-532.48H798.72z" ></path><path d="M608.256 494.592z m-10.24-4.608z" ></path><path d="M819.2 96.256H203.776c-41.472 0-75.264 33.792-75.264 75.264V286.72h128v448h510.464V286.72h128V171.008c-0.512-41.472-34.304-74.752-75.776-74.752z m-154.112 493.056l-12.8 12.8c-12.8 12.8-33.28 12.8-46.08 0L477.184 473.088c-33.792 11.776-72.704 4.608-99.328-22.528-27.136-27.136-34.304-66.048-22.528-99.84l38.4 38.4c12.8 12.8 33.28 12.8 46.08 0l12.8-12.8c12.8-12.8 12.8-33.28 0-46.08L414.208 291.84c33.792-11.776 72.704-4.096 99.84 22.528 27.136 27.136 34.304 66.048 22.528 99.84l128.512 128.512c12.288 13.312 12.288 33.792 0 46.592z" ></path></symbol><symbol id="icon-fangfaku" viewBox="0 0 1024 1024"><path d="M256 170.496v170.496h512V170.496h85.504c23.552 0 42.496 18.944 42.496 42.496V896c0 23.552-18.944 42.496-42.496 42.496H170.496c-23.552 0-42.496-18.944-42.496-42.496V212.992c0-23.552 18.944-42.496 42.496-42.496H256z m256 513.024H256v83.456h256v-83.456zM768 491.52H256v83.456h512V491.52zM341.504 85.504h341.504V256H341.504V85.504z" ></path></symbol><symbol id="icon-shebeiku" viewBox="0 0 1024 1024"><path d="M960 491.52v380.416c0 26.112-23.04 47.616-52.224 47.616H116.224c-29.184 0-52.224-21.504-52.224-47.616V491.52c0-26.112 23.04-47.616 52.224-47.616h791.552c28.672 0 52.224 21.504 52.224 47.616z m-149.504 156.16H213.504V783.36h596.992v-135.68z m149.504-500.736v186.88c0 23.04-20.992 42.496-46.592 42.496H110.592c-25.6 0-46.592-18.944-46.592-42.496V146.944c0-23.04 20.992-42.496 46.592-42.496h802.304c26.112 0 47.104 18.944 47.104 42.496z m-671.744 25.6c-41.472 0-74.752 30.208-74.752 68.096s33.792 68.096 74.752 68.096S363.008 278.528 363.008 240.64s-33.792-68.096-74.752-68.096z m224.256 0c-41.472 0-74.752 30.208-74.752 68.096s33.792 68.096 74.752 68.096 74.752-30.208 74.752-68.096-33.792-68.096-74.752-68.096z" ></path></symbol><symbol id="icon-wenjian" viewBox="0 0 1024 1024"><path d="M273.54647 325.996013h476.395357c19.444708-2.046811 36.842605 11.769166 39.40112 30.702171 2.046811 19.444708-11.769166 36.330903-31.213874 38.377714-2.558514 0.511703-5.117029 0.511703-7.675543 0H273.54647c-10.234057-0.511703-19.956411-4.605326-26.608548-11.257463-6.652137-6.652137-10.74576-15.351086-10.74576-24.561737 0.511703-19.956411 17.397897-35.307497 37.866011-34.284091v1.023406z m0 209.286467h476.395357c19.444708-2.046811 36.842605 11.769166 39.40112 30.702171 2.046811 19.444708-11.769166 36.330903-31.213874 38.377714-2.558514 0.511703-5.117029 0.511703-7.675543 0H273.54647c-9.722354 0-19.444708-3.58192-26.608548-10.234057-6.652137-6.652137-10.74576-15.351086-10.74576-24.561737 0.511703-19.444708 17.397897-35.307497 37.354308-34.284091z m0 185.748136h324.931312c19.444708 0 35.307497 15.862788 35.307497 34.795794 0 19.444708-15.862788 34.795794-35.307497 34.795794H273.54647c-9.722354-0.511703-19.444708-4.093623-26.608548-10.74576-6.652137-6.140434-10.74576-14.839383-10.74576-24.050034 0.511703-19.444708 17.397897-35.307497 37.354308-34.795794zM135.898402 0.041294h96.71184c17.397897-0.511703 33.772388 8.187246 43.494742 22.514926l53.217097 82.38416c4.605326 7.16384 12.792571 11.769166 20.979817 11.257462h322.884501c8.698949 0 16.886194-4.093623 21.49152-11.257462l53.217097-82.38416c9.722354-14.32768 26.096846-23.026628 43.494742-22.514926h97.223543c53.7288-1.535109 98.246948 39.912823 100.293759 93.12992v837.657572c-2.046811 52.705394-46.56496 94.153325-100.293759 93.12992h-752.203196c-53.7288 1.535109-98.758651-39.912823-100.293759-92.618217V93.171214C37.139751 39.954117 82.169603-1.493814 135.898402 0.041294z m82.895863 70.103291H135.898402c-6.652137 0-13.304274 2.558514-18.421303 6.652138-4.605326 4.093623-7.16384 10.234057-7.16384 16.374491v837.657572c0.511703 13.304274 11.769166 23.538331 25.07344 23.026629h752.203196c6.652137 0 13.304274-2.558514 18.421303-6.652138 4.605326-4.093623 7.16384-10.234057 7.16384-16.374491V93.171214c0.511703-6.140434-2.046811-12.280868-7.16384-16.374491-5.117029-4.605326-11.257463-6.652137-18.421303-6.652138h-82.895862l-46.053257 70.614994c-18.933006 28.65536-51.681988 45.541554-86.477783 45.029851H350.813601c-34.795794 0.511703-67.544777-16.374491-86.477782-45.029851l-45.541554-70.614994zM399.425372 0.041294h225.149256c19.956411-0.511703 36.842605 15.351086 37.866011 34.795795-0.511703 19.956411-17.397897 35.307497-37.866011 34.795794H399.425372c-10.234057-0.511703-19.956411-4.093623-27.120251-10.74576-6.652137-6.140434-10.74576-15.351086-10.234057-24.050034C362.582767 15.39238 378.957258-0.470408 399.425372 0.041294z" ></path></symbol><symbol id="icon-bianjimoban" viewBox="0 0 1025 1024"><path d="M127.110228 701.648461q0 26.438928 18.812314 45.251241t46.268123 18.812314l253.203575 0 0 128.12711-318.284012 0q-26.438928 0-49.82721-9.660377t-40.675273-26.947368-26.947368-40.675273-9.660377-50.844091l0-637.584906q0-26.438928 9.660377-49.82721t26.947368-40.675273 40.675273-27.455809 49.82721-10.168818l766.728898 0q26.438928 0 49.82721 10.168818t40.675273 27.455809 27.455809 40.675273 10.168818 49.82721l0 187.106256-128.12711 1.016882q-2.033764-25.422046-19.829196-43.217478t-44.234359-17.795432l-637.584906 0q-27.455809 0-46.268123 18.812314t-18.812314 45.251241l0 382.347567zM1016.881827 501.322741q6.101291 9.151936 7.626614 23.388282t-10.677259 28.472691q-11.1857 14.236346-18.303873 21.354518l-8.135055 8.135055-105.75571-95.586892q5.084409-6.101291 14.236346-14.744786t14.236346-13.727905q14.236346-14.236346 30.506455-12.711023t27.455809 6.609732q12.202582 5.084409 26.438928 18.812314t22.3714 29.998014zM613.179742 789.100298q3.050645-3.050645 14.236346-16.270109t27.96425-32.540218 37.116187-42.200596 40.675273-46.268123q48.810328-54.911619 108.806356-122.025819l107.789474 95.586892q-59.996028 68.131082-108.806356 123.042701-20.337637 23.388282-40.675273 46.268123t-37.116187 41.183714-27.455809 29.998014-12.711023 13.727905q-9.151936 12.202582-25.422046 20.337637-7.118173 5.084409-21.354518 11.1857t-29.998014 12.202582-29.489573 10.677259-20.846077 5.59285q-26.438928 5.084409-23.388282-22.3714 1.016882-7.118173 4.067527-21.862959t6.609732-30.506455 7.118173-28.981132 5.59285-18.303873q5.084409-13.219464 17.286991-28.472691z" ></path></symbol><symbol id="icon-shanchu1" viewBox="0 0 1024 1024"><path d="M78.768011 168.230165c0-30.999918 24.230644-56.076722 54.15419-56.076722L403.692131 112.153443 403.692131 56.076722c0-30.999918 24.230644-56.076722 54.15419-56.076722l108.306335 0c29.923546 0 54.155214 25.076803 54.155214 56.076722l0 56.077745 270.768906 0c29.923546 0 54.15419 25.076803 54.15419 56.076722l0 56.076722L78.768011 224.307909 78.768011 168.230165zM891.076776 336.461352l0 112.153443 0 519.30746c0 30.923181-24.231667 56.077745-54.153167 56.077745L187.076392 1024c-29.923546 0-54.15419-25.154564-54.15419-56.077745L132.922201 448.614796 132.922201 336.461352l0-56.077745 758.154574 0L891.076776 336.461352zM349.53794 448.614796c0-30.923181-24.230644-56.076722-54.15419-56.076722-29.922523 0-54.153167 25.153541-54.153167 56.076722l0 407.154017c0 30.923181 24.230644 56.077745 54.153167 56.077745 29.923546 0 54.15419-25.154564 54.15419-56.077745L349.53794 448.614796zM566.153679 448.614796c0-30.923181-24.230644-56.076722-54.15419-56.076722-29.922523 0-54.153167 25.153541-54.153167 56.076722l0 407.154017c0 30.923181 24.230644 56.077745 54.153167 56.077745 29.923546 0 54.15419-25.154564 54.15419-56.077745L566.153679 448.614796zM782.770441 448.614796c0-30.923181-24.231667-56.076722-54.155214-56.076722s-54.15419 25.153541-54.15419 56.076722l0 407.154017c0 30.923181 24.230644 56.077745 54.15419 56.077745s54.155214-25.154564 54.155214-56.077745L782.770441 448.614796z" ></path></symbol><symbol id="icon-edit" viewBox="0 0 1024 1024"><path d="M923.9 335.8c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.8-35.2-174.3-35.2S392.2 74.1 337 97.5c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3C75.3 391 63.5 449.7 63.5 510.1c0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c35.9-15.2 69.3-34.8 99.8-58.5l-0.1-0.1c9.1-7.4 14.8-18.6 14.8-31.2 0-22.3-18-40.3-40.3-40.3-9.2 0-17.7 3.1-24.5 8.3l-0.2-0.3c-62 47.9-139.7 76.4-223.9 76.4-202.3 0-366.9-164.6-366.9-366.9s164.7-366.9 367-366.9 366.9 164.6 366.9 366.9c0 66.2-17.6 128.3-48.4 182l0.4 0.2c-4.4 6.5-7 14.2-7 22.6 0 22.3 18 40.3 40.3 40.3 16 0 29.8-9.3 36.3-22.8l0.2 0.1c8.9-15.5 16.8-31.5 23.8-48.1 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.7-119.1-35.1-174.3z" ></path><path d="M693.7 626.5H507.6l-57.1 66.1h243.2zM663.2 411.4c7.5-7.6 7.5-23.5 0-31.3l-45.4-46.8c-7.7-7.6-22.9-7.6-30.4 0l-45.7 46.8 76.1 78.1 45.4-46.8zM328.8 614.5v78.1h76.1l197.5-218.7-76-77.9z" ></path></symbol><symbol id="icon-new" viewBox="0 0 1024 1024"><path d="M926.3 337.9c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.9-35.2-174.3-35.2S394.6 76.2 339.3 99.6c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3-23.4 55.2-35.2 113.9-35.2 174.3 0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c53.3-22.6 101.2-54.8 142.3-96 41.1-41.1 73.4-89 96-142.3 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.8-119.1-35.1-174.3zM513.7 879.1c-202.3 0-366.9-164.6-366.9-366.9s164.6-366.9 366.9-366.9c202.3 0 366.9 164.6 366.9 366.9S716 879.1 513.7 879.1z" ></path><path d="M695.7 469.2h-139v-139c0-23.6-19.3-43-43-43-23.6 0-43 19.3-43 43v139h-139c-23.6 0-43 19.3-43 43s19.3 43 43 43h139v139c0 23.7 19.3 43 43 43 23.6 0 43-19.3 43-43v-139h139c23.6 0 43-19.3 43-43s-19.4-43-43-43z" ></path></symbol><symbol id="icon-biaoqianye1" viewBox="0 0 1024 1024"><path d="M345.557333 128l110.677334 168.405333H938.666667V896H85.333333V128h260.224zM299.52 213.333333H170.666667v597.333334h682.666666V381.738667H410.197333L299.52 213.333333z" fill="#222222" ></path><path d="M597.333333 136.533333c0-4.693333 3.541333-8.533333 7.893334-8.533333h325.546666c4.352 0 7.893333 3.84 7.893334 8.533333v68.266667c0 4.693333-3.541333 8.533333-7.893334 8.533333h-325.546666C600.874667 213.333333 597.333333 209.493333 597.333333 204.8V136.533333z" fill="#222222" ></path></symbol><symbol id="icon-biaoqianye" viewBox="0 0 1024 1024"><path d="M376.6 494.8c5.1 4.8 7.9 11.7 7.6 18.7 0.4 7.1-2.5 14-7.6 18.7-5.3 4.7-12.3 7.2-19.3 6.9h-69.6v235.1c0.2 7.4-2.9 14.4-8.4 19.1-5.5 5.4-12.9 8.3-20.5 8.1-7.6 0.3-15.1-2.7-20.5-8.1-5.3-4.9-8.2-11.9-8.1-19.1v-235H161c-7.2 0.3-14.2-2.3-19.3-7.3-5.2-4.8-8-11.7-7.6-18.7-0.3-7 2.5-13.7 7.6-18.3 5.3-4.8 12.2-7.3 19.3-7h198.4c6.3 0 12.4 2.5 17.2 6.9z m215.7 70.1c5.2 5.1 8 12.2 7.7 19.6v189.9c0.3 7.2-2.5 14.2-7.7 19.1-4.8 5.3-11.7 8.3-18.9 8.1-7.1 0.1-13.9-2.7-18.9-7.7-4.8-5.2-7.6-12-7.6-19.1-18 19.5-42.9 30.8-69.2 31.4-19.7 0.3-38.9-5.3-55.5-15.9-17.2-10.7-31.2-26.1-40.3-44.4-19.3-40.4-19.3-87.6 0-128 8.9-18.4 22.9-33.8 40.3-44.4 16-10.5 34.8-16.1 53.9-15.9 26.3-0.1 51.8 9.8 71.2 27.7-0.2-7.3 2.6-14.4 7.7-19.6 10.6-10.2 27.2-10.2 37.8 0l-0.5-0.8z m-61.2 168.7c24.1-31.6 24.1-75.6 0-107.2-11.5-14.3-28.9-22.3-47.1-21.6-17.9-0.5-35.1 7.4-46.3 21.6-12.1 15-18.5 34-18.1 53.4-0.6 19.5 5.7 38.6 17.7 53.8 11.6 13.9 28.8 21.7 46.7 21.2 18.1 0.4 35.3-7.4 47.1-21.2zM835.4 573c17.1 10.7 31 25.9 40.3 44 9.9 19.8 14.9 41.8 14.5 64 0.4 22.3-4.6 44.4-14.5 64.4-9 18.3-23 33.7-40.3 44.4-16 10.6-34.8 16.1-53.9 15.9-13.9 0.2-27.7-2.9-40.3-9-11.6-5-22.1-12.2-31-21.2v2.8c0.2 7.2-2.5 14.2-7.5 19.4-5 5.1-11.9 8-19.1 7.9-7.1 0.3-14-2.5-18.9-7.7-5.2-5.1-8-12.2-7.6-19.6V497.2c-0.2-7.3 2.5-14.4 7.6-19.6 10.6-10.3 27.2-10.3 37.8 0 5.1 5.2 7.9 12.2 7.6 19.6v93.3c8-9.8 18-17.7 29.4-23.2 12.4-6.8 26.2-10.3 40.3-10.2 19.7-0.2 39 5.3 55.6 15.9z m-15.7 163c12.2-15.1 18.6-34.3 18.1-53.8 0.6-19.4-5.7-38.3-17.7-53.4-12-13.4-29-21.1-46.9-21.1s-34.9 7.7-46.9 21.1c-24.1 31.6-24.1 75.6 0 107.2 11.6 14.1 29 22.1 47.1 21.6 18.3-0.2 35.4-9.1 46.3-24v2.4zM708.1 253.5c-15.5 0-28-12.5-28-28V113.4c-0.1-8 0-15.9 0-23.8V77.9c0-15.5 12.5-28 28-28H886c17 0 32.9 6.6 45 18.6 11.3 11.3 17.8 26 18.6 41.8 0.1 0.7 0.1 1.4 0.1 2.1v113.2c0 15.5-12.5 28-28 28H708.1z m28-56h157.4v-84.1c0-2-0.8-3.9-2.2-5.4-1.4-1.4-3.4-2.2-5.4-2.2H736.1v91.7zM371.9 254.6c-15.5 0-28-12.5-28-28V78.9c0-15.4 12.5-27.9 27.9-28l213.4-1.1h0.1c17 0 32.9 6.6 45 18.6 12 12.1 18.6 28 18.6 45v113.2c0 15.5-12.5 28-28 28h-249z m28-56.1h193v-85.2c0-2-0.8-3.9-2.2-5.4-1.4-1.4-3.3-2.2-5.3-2.2l-185.5 0.9v91.9z" fill="#595959" ></path><path d="M72.4 974.2c-17.3 0-33.5-6.7-45.7-18.7-12.2-12.1-18.9-28.1-18.9-45.1V113.6c0-35.2 29-63.8 64.6-63.8h169c17.3 0 33.5 6.6 45.7 18.7 12.2 12 18.9 28.1 18.9 45.1V283c0 2 0.8 3.9 2.3 5.4 1.5 1.4 3.4 2.2 5.4 2.2h637.9c17.3 0 33.5 6.6 45.7 18.7 12.2 12 18.9 28 18.9 45.1v556c0 17.1-6.7 33.1-18.9 45.1s-28.4 18.7-45.7 18.7H72.4z m7.7-860.6c-4.3 0-7.7 3.4-7.7 7.6v788.7c0 2 0.8 4 2.3 5.4 1.4 1.4 3.4 2.2 5.4 2.2h871.5c2.1 0 4-0.8 5.4-2.2 1.5-1.4 2.3-3.3 2.3-5.4V350.6c0-2-0.8-3.9-2.2-5.3-1.5-1.5-3.4-2.3-5.4-2.3h-638c-17.3 0-33.5-6.7-45.7-18.7-12.2-12-18.9-28.1-18.9-45.1V121.1c0-2-0.8-3.9-2.3-5.4-1.4-1.4-3.4-2.2-5.4-2.2H80.1z" fill="#595959" ></path></symbol><symbol id="icon-buzhou" viewBox="0 0 1024 1024"><path d="M488.106667 792.462222h257.137777a28.444444 28.444444 0 0 0 28.444445-28.444444 28.444444 28.444444 0 0 0-28.444445-28.444445H488.106667a28.444444 28.444444 0 0 0-28.444445 28.444445 28.444444 28.444444 0 0 0 28.444445 28.444444zM242.346667 764.017778A80.782222 80.782222 0 1 0 341.333333 686.08v-96.142222a80.213333 80.213333 0 0 0 0-155.875556V337.92a80.782222 80.782222 0 1 0-39.822222 0v96.142222a80.213333 80.213333 0 0 0 0 155.875556v96.142222a80.782222 80.782222 0 0 0-59.164444 77.937778zM284.444444 259.982222a40.96 40.96 0 0 1 81.92 0 40.391111 40.391111 0 0 1-40.391111 40.96 40.391111 40.391111 0 0 1-41.528889-40.96zM284.444444 512a40.96 40.96 0 1 1 40.96 40.96A40.96 40.96 0 0 1 284.444444 512z m40.391112 211.057778a40.391111 40.391111 0 0 1 40.391111 40.96 40.96 40.96 0 0 1-81.92 0 40.391111 40.391111 0 0 1 39.253333-40.96zM488.106667 540.444444h257.137777a28.444444 28.444444 0 1 0 0-56.888888H488.106667a28.444444 28.444444 0 1 0 0 56.888888zM488.106667 288.426667h257.137777a28.444444 28.444444 0 0 0 28.444445-28.444445 28.444444 28.444444 0 0 0-28.444445-28.444444H488.106667a28.444444 28.444444 0 0 0-28.444445 28.444444 28.444444 28.444444 0 0 0 28.444445 28.444445z" fill="#151515" ></path><path d="M859.022222 79.644444H164.977778a22.755556 22.755556 0 0 0-22.755556 22.755556v819.2a22.755556 22.755556 0 0 0 22.755556 22.755556h694.044444a22.755556 22.755556 0 0 0 22.755556-22.755556V102.4a22.755556 22.755556 0 0 0-22.755556-22.755556z m-22.755555 819.2H187.733333V125.155556h648.533334z" fill="#151515" ></path></symbol><symbol id="icon-ok" viewBox="0 0 1024 1024"><path d="M926.3 337.9c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.9-35.2-174.3-35.2S394.6 76.2 339.3 99.6c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3-23.4 55.2-35.2 113.9-35.2 174.3 0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c53.3-22.6 101.2-54.8 142.3-96 41.1-41.1 73.4-89 96-142.3 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.8-119.1-35.1-174.3zM513.7 879.1c-202.3 0-366.9-164.6-366.9-366.9s164.6-366.9 366.9-366.9c202.3 0 366.9 164.6 366.9 366.9S716 879.1 513.7 879.1z" ></path><path d="M715.6 371.6c-15.7-15.7-41.4-15.7-57 0l-196 196-95.9-95.9c-15.7-15.7-41.4-15.7-57 0-15.7 15.7-15.7 41.4 0 57l124.5 124.5c15.7 15.7 41.4 15.7 57 0l224.5-224.5c15.6-15.7 15.6-41.4-0.1-57.1z" ></path></symbol><symbol id="icon-cancel" viewBox="0 0 1024 1024"><path d="M926.3 337.9c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.9-35.2-174.3-35.2S394.6 76.2 339.3 99.6c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3-23.4 55.2-35.2 113.9-35.2 174.3 0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c53.3-22.6 101.2-54.8 142.3-96 41.1-41.1 73.4-89 96-142.3 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.8-119.1-35.1-174.3zM513.7 879.1c-202.3 0-366.9-164.6-366.9-366.9s164.6-366.9 366.9-366.9c202.3 0 366.9 164.6 366.9 366.9S716 879.1 513.7 879.1z" ></path><path d="M697.9 329.1c-15.6-15.6-41-15.6-56.6 0L513 457.4 384.7 329.1c-15.6-15.6-41-15.6-56.6 0-15.6 15.6-15.6 41 0 56.6L456.4 514 328.1 642.3c-15.6 15.6-15.6 41 0 56.6 15.6 15.6 41 15.6 56.6 0L513 570.6l128.3 128.3c15.6 15.6 41 15.6 56.6 0 15.6-15.6 15.6-41 0-56.6L569.6 514l128.3-128.3c15.6-15.6 15.6-41.1 0-56.6z" ></path></symbol><symbol id="icon-savebaocun" viewBox="0 0 1024 1024"><path d="M778.7 97.2H247.3C165 97.2 98 164.3 98 246.7v532.2c0 82.4 67 149.4 149.3 149.4h531.5c82.3 0 149.3-67 149.3-149.4V246.7C928 164.3 861 97.2 778.7 97.2z m-452.2 79.9h373.1v83.7H331.9c-2.9 0-5.5-2.6-5.5-5.5v-78.2z m373 671.3h-373v-225h373.1v225z m148.7-69.6c0 38.1-30.8 69.2-68.8 69.5V612.9c0-38.3-31.1-69.4-69.3-69.4H316c-38.2 0-69.3 31.1-69.3 69.4v235.4c-38-0.3-68.8-31.4-68.8-69.5V246.7c0-38.1 30.8-69.2 68.8-69.5v78.2c0 47.1 38.3 85.4 85.3 85.4h378c38.2 0 69.3-31.1 69.3-69.4v-94.2c38 0.3 68.8 31.4 68.8 69.5v532.1z" ></path></symbol><symbol id="icon-shijianxian2" viewBox="0 0 1024 1024"><path d="M171.52 924.16v-107.52c0-19.968 15.872-35.84 35.84-35.84s35.84 15.872 35.84 35.84v107.52c0 19.968-15.872 35.84-35.84 35.84s-35.84-15.872-35.84-35.84z m0-322.56v-107.52c0-19.968 15.872-35.84 35.84-35.84s35.84 15.872 35.84 35.84v107.52c0 19.968-15.872 35.84-35.84 35.84s-35.84-15.872-35.84-35.84z m0-394.24v-107.52c0-19.968 15.872-35.84 35.84-35.84s35.84 15.872 35.84 35.84v107.52c0 19.968-15.872 35.84-35.84 35.84s-35.84-15.872-35.84-35.84z" ></path><path d="M350.72 350.72c0 79.36-64 143.36-143.36 143.36s-143.36-64-143.36-143.36 64-143.36 143.36-143.36 143.36 64 143.36 143.36z m-143.36-71.68c-39.424 0-71.68 32.256-71.68 71.68s32.256 71.68 71.68 71.68 71.68-32.256 71.68-71.68-32.256-71.68-71.68-71.68z m143.36 430.08c0 79.36-64 143.36-143.36 143.36s-143.36-64-143.36-143.36 64-143.36 143.36-143.36 143.36 64 143.36 143.36z m-143.36-71.68c-39.424 0-71.68 32.256-71.68 71.68s32.256 71.68 71.68 71.68 71.68-32.256 71.68-71.68-32.256-71.68-71.68-71.68z m716.8-286.72h-501.76c-19.968 0-35.84-15.872-35.84-35.84s15.872-35.84 35.84-35.84h501.76c19.968 0 35.84 15.872 35.84 35.84s-15.872 35.84-35.84 35.84z m-284.672 107.52H420.352c-18.432 0-33.792-15.36-33.792-33.792v-4.096c0-18.432 15.36-33.792 33.792-33.792h219.136c18.432 0 33.792 15.36 33.792 33.792v4.096c0 18.432-15.36 33.792-33.792 33.792z m284.672 250.88h-501.76c-19.968 0-35.84-15.872-35.84-35.84s15.872-35.84 35.84-35.84h501.76c19.968 0 35.84 15.872 35.84 35.84s-15.872 35.84-35.84 35.84z m-284.672 107.52H420.352c-18.432 0-33.792-15.36-33.792-33.792v-4.096c0-18.432 15.36-33.792 33.792-33.792h219.136c18.432 0 33.792 15.36 33.792 33.792v4.096c0 18.432-15.36 33.792-33.792 33.792z" ></path></symbol><symbol id="icon-buzhoutiao" viewBox="0 0 1024 1024"><path d="M0 0h1024v1024H0z" fill="#FFFFFF" fill-opacity="0" ></path><path d="M204 372c66.31 0 121.852 46.1 136.326 108h137.53c12.901-33.907 45.71-58 84.144-58 38.435 0 71.243 24.093 84.145 58h139.71c12.902-33.907 45.71-58 84.145-58 49.706 0 90 40.294 90 90s-40.294 90-90 90c-38.434 0-71.242-24.092-84.144-57.998H646.144C633.242 577.908 600.434 602 562 602c-38.434 0-71.242-24.092-84.144-57.998h-137.53C325.852 605.9 270.309 652 204 652c-77.32 0-140-62.68-140-140s62.68-140 140-140z m0 64c-41.974 0-76 34.026-76 76s34.026 76 76 76 76-34.026 76-76-34.026-76-76-76z m358 50c-14.36 0-26 11.64-26 26s11.64 26 26 26 26-11.64 26-26-11.64-26-26-26z m308 0c-14.36 0-26 11.64-26 26s11.64 26 26 26 26-11.64 26-26-11.64-26-26-26z" fill="#666666" ></path></symbol><symbol id="icon-m-qianming" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M573.44 646.656l-3.072 6.144c-8.192 12.288-14.336 25.088-19.456 38.912-6.656 18.944-3.072 36.352 16.896 43.008 34.816 11.264 72.704 9.216 106.496-4.608 9.216-3.072 11.264-4.096 34.304-12.8 16.384-6.656 33.792-12.8 51.2-17.408 1.024 0 2.048-0.512 3.072-1.024 10.24-2.048 6.656-5.632 16.896 1.024 3.584 3.072 8.704 4.096 13.312 3.072 4.608-1.024 5.632-3.072 8.192-7.68 5.632-8.192 3.584-19.456-4.608-25.088-18.944-12.8-22.528-10.24-41.472-6.144-1.536 0.512-3.072 0.512-4.096 1.024-18.944 5.12-37.376 11.264-55.808 18.432-22.016 8.704-24.064 9.728-32.768 12.288-24.576 10.24-52.224 12.8-78.336 6.144 4.608-11.264 10.24-22.016 16.896-32.256 1.536-2.048 2.56-4.096 3.584-6.144 8.704-13.824 15.36-29.184 18.432-45.056 4.096-19.456-7.68-38.4-27.136-42.496-0.512 0-1.536-0.512-2.048-0.512-27.648-6.656-59.392 3.072-148.992 37.888-81.92 32.256-117.76 41.984-129.024 35.84-4.096-2.56-8.704-3.072-13.312-1.536-9.728 2.56-15.36 12.8-12.8 22.016 1.024 4.608 4.096 8.192 8.192 10.752 23.04 8.704 48.64 7.68 71.168-2.048 29.696-9.216 59.392-19.456 88.064-32.256 77.824-30.72 111.104-40.448 126.976-36.352 3.072 1.024 3.072 0 2.56 3.072-2.56 12.288-7.168 23.552-13.312 33.792zM665.088 235.52c-19.456-17.92-49.664-17.408-68.608 1.024L312.32 519.68c-2.048 2.048-3.584 4.608-4.608 7.68l-22.528 80.896c-2.56 9.728 3.072 19.456 12.8 21.504 3.584 1.024 7.68 0.512 11.264-0.512l71.168-29.696c5.632-2.56 10.752-5.632 15.36-10.24l283.648-269.824 2.56-2.56c18.432-19.456 17.92-50.176-2.048-68.608l-1.024-1.024-13.824-11.776z" ></path></symbol><symbol id="icon-touxiang_avatar" viewBox="0 0 1024 1024"><path d="M925.866667 797.866667c-12.8-25.6-34.133333-46.933333-64-64-29.866667-21.333333-68.266667-34.133333-119.466667-42.666667-4.266667 0-29.866667-4.266667-59.733333-12.8-21.333333-4.266667-34.133333-8.533333-38.4-12.8v-17.066667c4.266667-51.2 29.866667-76.8 55.466666-106.666666 8.533333-8.533333 17.066667-21.333333 25.6-29.866667 29.866667-42.666667 34.133333-89.6 34.133334-98.133333 0-8.533333 0-17.066667-4.266667-21.333334-4.266667-8.533333-8.533333-12.8-12.8-21.333333 0-12.8 4.266667-21.333333 4.266667-29.866667 0-21.333333 4.266667-55.466667-4.266667-89.6 0-8.533333-4.266667-12.8-4.266667-21.333333-8.533333-25.6-17.066667-46.933333-34.133333-68.266667-4.266667-12.8-64-72.533333-234.666667-85.333333H401.066667c-4.266667 0-17.066667 0-25.6 4.266667-21.333333 4.266667-38.4 21.333333-42.666667 42.666666v21.333334c-8.533333 8.533333-55.466667 51.2-55.466667 102.4-4.266667 34.133333-4.266667 85.333333 0 123.733333-8.533333 8.533333-17.066667 21.333333-12.8 42.666667 0 12.8 4.266667 55.466667 34.133334 98.133333 8.533333 8.533333 17.066667 17.066667 25.6 29.866667 25.6 29.866667 51.2 55.466667 55.466666 106.666666v17.066667c-4.266667 4.266667-17.066667 8.533333-38.4 12.8-29.866667 8.533333-59.733333 12.8-64 12.8-46.933333 8.533333-85.333333 21.333333-115.2 42.666667-25.6 17.066667-46.933333 38.4-64 64-25.6 38.4-25.6 76.8-25.6 85.333333v21.333333c0 25.6 21.333333 46.933333 46.933334 46.933334H896c25.6 0 46.933333-21.333333 46.933333-46.933334v-17.066666c8.533333-12.8 8.533333-51.2-17.066666-89.6z m-546.133334-128c0 4.266667 0 4.266667 0 0v4.266666c-4.266667 0-4.266667 0 0-4.266666z m503.466667 213.333333l-742.4 4.266667v-4.266667s0-25.6 12.8-51.2c8.533333-17.066667 25.6-29.866667 42.666667-42.666667 25.6-17.066667 55.466667-25.6 89.6-34.133333 4.266667 0 34.133333-4.266667 68.266666-12.8 51.2-12.8 76.8-29.866667 85.333334-46.933333 0-4.266667 0-4.266667 4.266666-8.533334v-42.666666c-8.533333-72.533333-42.666667-115.2-72.533333-145.066667-8.533333-8.533333-12.8-17.066667-21.333333-21.333333-21.333333-29.866667-21.333333-59.733333-21.333334-64l4.266667-4.266667 8.533333-8.533333c4.266667-17.066667 0-25.6 0-29.866667-4.266667-34.133333-4.266667-81.066667 0-119.466667 0-29.866667 29.866667-55.466667 29.866667-55.466666 8.533333-4.266667 17.066667-12.8 21.333333-21.333334 0-4.266667 4.266667-4.266667 4.266667-8.533333v-25.6H465.066667c140.8 8.533333 192 59.733333 192 59.733333 8.533333 12.8 17.066667 25.6 21.333333 42.666667 4.266667 4.266667 4.266667 8.533333 4.266667 12.8 4.266667 29.866667 4.266667 55.466667 4.266666 76.8 0 12.8 0 21.333333-4.266666 38.4 0 12.8 0 25.6 8.533333 29.866667l4.266667 4.266666 4.266666 4.266667s0 34.133333-21.333333 64c-4.266667 8.533333-12.8 12.8-21.333333 21.333333-29.866667 29.866667-64 72.533333-72.533334 145.066667v42.666667c0 4.266667 0 4.266667 4.266667 8.533333 8.533333 21.333333 34.133333 34.133333 85.333333 46.933333 34.133333 8.533333 64 12.8 68.266667 12.8 38.4 8.533333 68.266667 17.066667 93.866667 34.133334 17.066667 12.8 34.133333 25.6 42.666666 42.666666 8.533333 25.6 8.533333 51.2 4.266667 55.466667z" ></path></symbol><symbol id="icon-m-mianban" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M884.15744 348.01152v49.152h-745.984v-49.152z" ></path><path d="M356.43392 846.99136h-49.152v-450.048h49.152z" ></path></symbol><symbol id="icon-m-xialakuang" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M510.464 639.488l207.872-254.976H302.08z" ></path></symbol><symbol id="icon-m-biaodan" viewBox="0 0 1024 1024"><path d="M122.88 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384H122.88c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H137.216c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M244.224 279.04h142.848v49.152H244.224zM244.224 425.472h142.848v49.152H244.224zM436.736 279.04h342.528v49.152H436.736zM436.736 425.472h342.528v49.152H436.736zM244.224 572.416h142.848v49.152H244.224zM436.736 572.416h342.528v172.544H436.736z" ></path></symbol><symbol id="icon-m-biaoge" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M249.344 347.648h49.152v499.2h-49.152zM584.704 347.648h49.152v499.2h-49.152zM137.728 165.888h746.496v181.76H137.728z" ></path><path d="M137.728 481.792h746.496v49.152H137.728zM137.728 664.576h746.496v49.152H137.728z" ></path></symbol><symbol id="icon-dashboard-o" viewBox="0 0 1024 1024"><path d="M880 622c17.673 0 32 14.327 32 32v226c0 17.673-14.327 32-32 32H582c-17.673 0-32-14.327-32-32V654c0-17.673 14.327-32 32-32h298zM442 476c17.673 0 32 14.327 32 32v372c0 17.673-14.327 32-32 32H144c-17.673 0-32-14.327-32-32V508c0-17.673 14.327-32 32-32h298z m406 210H614v162h234V686zM410 540H176v308h234V540z m470-428c17.673 0 32 14.327 32 32v372c0 17.673-14.327 32-32 32H582c-17.673 0-32-14.327-32-32V144c0-17.673 14.327-32 32-32h298z m-32 64H614v308h234V176z m-406-64c17.673 0 32 14.327 32 32v226c0 17.673-14.327 32-32 32H144c-17.673 0-32-14.327-32-32V144c0-17.673 14.327-32 32-32h298z m-32 64H176v162h234V176z" fill="#000000" fill-opacity=".65" ></path></symbol><symbol id="icon-line-layoutmasonryfensanbuju" viewBox="0 0 1024 1024"><path d="M896 128H128c-25.6 0-42.666667 17.066667-42.666667 42.666667v682.666666c0 25.6 17.066667 42.666667 42.666667 42.666667h768c25.6 0 42.666667-17.066667 42.666667-42.666667V170.666667c0-25.6-17.066667-42.666667-42.666667-42.666667zM170.666667 213.333333h298.666666v341.333334H170.666667V213.333333z m0 597.333334v-170.666667h298.666666v170.666667H170.666667z m682.666666 0h-298.666666v-341.333334h298.666666v341.333334z m0-426.666667h-298.666666V213.333333h298.666666v170.666667z" fill="#09121F" ></path></symbol><symbol id="icon-zidingyibuju" viewBox="0 0 1024 1024"><path d="M0 0v256h1024V0z m960 192H64V64h896zM0 1024h512V320H0z m64-640h384v576H64zM576 576h448v-256H576z m64-192h320v128H640zM576 1024h448V640H576z m64-320h320v256H640z" fill="#575869" ></path></symbol><symbol id="icon-daochu" viewBox="0 0 1024 1024"><path d="M394.6 689.8c-13.2 3.2-27.4-9.5-31.7-23.2-8.4-28.5-12.7-58.6-12.7-88.1 0-159.4 151.5-325.1 314.1-352.1v-5.3c0-1.6 0-3.7 0.5-5.3l0.5-2.1c1.6-11.6 5.8-38.5 32.2-55.4 10.6-6.9 22.2-10 34.3-10 14.8 0 26.9 5.3 34.3 9.5 1.6 0.5 2.6 1.6 4.2 2.6L929.2 286c17.4 13.2 28 34.8 28 57 0 22.7-10.6 44.3-28.5 57.5L770.5 525.7c-11.6 9-25.3 13.7-39.1 13.7-12.1 0-23.8-3.7-34.8-10.6-21.1-13.7-31.7-34.8-31.7-64.4v-1.1C559.3 475 442.2 569 416.3 657.6c-4.8 14.3-13.7 32.2-21.7 32.2z m335.7-466.6V256c0 17.4-13.7 31.7-31.1 32.7-125.6 6.9-257.6 131.4-279.7 254.4C486 458.7 595.2 390 699.7 397.4c17.4 1.1 30.6 15.3 30.6 32.7V465c0 4.7 0.5 6.9 0.5 7.9l157.3-124.6c2.1-1.6 2.6-3.2 2.6-5.3 0-2.1-1.1-4.2-2.6-5.3L731.9 214.3c-1.1 1.6-1.6 5.8-2.1 8.4l0.5 0.5z m0 0" ></path><path d="M715.6 916.3H188.3c-67 0-121.9-54.9-121.9-121.9v-568c0-67 54.9-121.9 121.9-121.9h436.5v69.7H188.3c-28.5 0-52.3 23.2-52.3 52.3V795c0 28.5 23.2 52.3 52.3 52.3h527.3c28.5 0 52.3-23.2 52.3-52.3V593.2H837v201.6c0 66.6-54.4 121.5-121.4 121.5z m0 0" ></path><path d="M183 566.9h112.4V626H183v-59.1z m0 154.1h296.1v59.1H183V721z m0-425.4h237v59.1H183v-59.1z m0 140.9h112.4v59.1H183v-59.1z m0 0" ></path></symbol><symbol id="icon-daoru" viewBox="0 0 1024 1024"><path d="M111.6 148.8c7.9 0 16.9 17.9 21.6 32.2 25.9 88.7 143 182.6 248.6 194.2v-1.1c0-29.6 10.6-50.7 31.7-64.4 11.1-6.9 22.7-10.6 34.8-10.6 13.7 0 27.4 4.8 39.1 13.7L645.8 438c17.9 13.2 28.5 34.8 28.5 57.5 0 22.2-10.6 43.8-28 57L487.4 678.2c-1.6 1.1-2.6 2.1-4.2 2.6-7.4 4.2-19.5 9.5-34.3 9.5-12.1 0-23.7-3.2-34.3-10-26.4-16.9-30.6-43.8-32.2-55.4l-0.5-2.1c-0.5-1.6-0.5-3.7-0.5-5.3v-5.3c-162.6-26.9-314.1-192.6-314.1-352 0-29.6 4.2-59.6 12.7-88.1 4.2-13.8 18.4-26.5 31.6-23.3z m335.2 467.1c0.5 2.6 1.1 6.9 2.1 8.4l156.2-123.5c1.6-1.1 2.6-3.2 2.6-5.3 0-2.1-0.5-3.7-2.6-5.3L447.8 365.7c0 1.1-0.5 3.2-0.5 7.9v34.8c0 17.4-13.2 31.7-30.6 32.7-104.5 7.4-213.8-61.2-280.3-145.7 22.2 123 154.1 247.5 279.7 254.4 17.4 1.1 31.1 15.3 31.1 32.7v32.7l-0.4 0.7z m0.5-0.5" ></path><path d="M309 916.3c-67 0-121.4-54.9-121.4-121.4V593.2h69.1v201.6c0 29 23.8 52.3 52.3 52.3h527.3c29 0 52.3-23.8 52.3-52.3V226.4c0-29-23.8-52.3-52.3-52.3H399.8v-69.7h436.5c67 0 121.9 54.9 121.9 121.9v567.9c0 67-54.9 121.9-121.9 121.9H309v0.2z m0 0" ></path><path d="M841.6 626H729.1v-59.1h112.4V626z m0 154.1H545.5V721h296.1v59.1z m0-425.4h-237v-59.1h237v59.1z m0 140.9H729.1v-59.1h112.4v59.1z m0-59.1" ></path></symbol><symbol id="icon-a-juxing1851" viewBox="0 0 1024 1024"><path d="M0 0h438.857143v1024H0V0z m512 0h512v438.857143H512V0z m0 512h219.428571v219.428571H512V512z m292.571429 0h219.428571v219.428571h-219.428571V512z m-292.571429 292.571429h73.142857v73.142857H512v-73.142857z m146.285714 0h73.142857v73.142857H658.285714v-73.142857z m-146.285714 146.285714h73.142857v73.142857H512v-73.142857z m146.285714 0h73.142857v73.142857H658.285714v-73.142857z m146.285715 0h73.142857v73.142857h-73.142857v-73.142857z m146.285714 0h73.142857v73.142857h-73.142857v-73.142857z m-146.285714-146.285714h73.142857v73.142857h-73.142857v-73.142857z m146.285714 0h73.142857v73.142857h-73.142857v-73.142857z" ></path></symbol><symbol id="icon-sxsz" viewBox="0 0 1024 1024"><path d="M304.5 152.6h415L927 512 719.5 871.4h-415L97 512z" fill="#386BF3" ></path><path d="M512 512m-145.25 0a145.25 145.25 0 1 0 290.5 0 145.25 145.25 0 1 0-290.5 0Z" fill="#3D4265" ></path></symbol><symbol id="icon-mx" viewBox="0 0 1024 1024"><path d="M511.9 325.12v248.55L727.15 449.4l-0.01-248.55z" fill="#C3D2FB" ></path><path d="M296.65 200.85L511.9 325.12v248.56L296.65 449.4z" fill="#3D4265" ></path><path d="M511.9 325.12l215.25-124.27L511.9 76.57 296.65 200.85z" fill="#386BF3" ></path><path d="M296.62 698.02v248.55L511.87 822.3l-0.01-248.56z" fill="#C3D2FB" ></path><path d="M81.37 573.74l215.25 124.28v248.55L81.37 822.3z" fill="#3D4265" ></path><path d="M296.62 698.02l215.25-124.28-215.25-124.27L81.37 573.74z" fill="#386BF3" ></path><path d="M727.03 698.02v248.55L942.28 822.3l-0.01-248.56z" fill="#C3D2FB" ></path><path d="M511.78 573.74l215.25 124.28v248.55L511.78 822.3z" fill="#3D4265" ></path><path d="M727.03 698.02l215.25-124.28-215.25-124.27-215.25 124.27z" fill="#386BF3" ></path></symbol><symbol id="icon-al" viewBox="0 0 1024 1024"><path d="M192 132h440v640H192z" fill="#386BF3" ></path><path d="M632 260h200v512H632z" fill="#C3D2FB" ></path><path d="M398.86 612L512 725.14 625.14 612H912v280H112V612z" fill="#3D4265" ></path></symbol><symbol id="icon-sf" viewBox="0 0 1024 1024"><path d="M511.82 512.5v435L888.54 730l-0.02-435z" fill="#C3D2FB" ></path><path d="M135.1 295l376.72 217.5v435L135.1 730z" fill="#3D4265" ></path><path d="M511.82 512.5L888.54 295 511.82 77.5 135.1 295z" fill="#386BF3" ></path></symbol><symbol id="icon-moxing" viewBox="0 0 1061 1024"><path d="M447.122 467.332L49.24 268.162A33.501 33.501 0 0 0 0.136 300.745v441.02a33.042 33.042 0 0 0 16.062 27.994l396.965 248.275a33.96 33.96 0 0 0 17.438 5.507 33.042 33.042 0 0 0 33.043-33.042V497.162a33.042 33.042 0 0 0-16.522-29.83z m598.889-203.76a33.042 33.042 0 0 0-31.666 0l-463.507 203.76a33.042 33.042 0 0 0-19.733 30.289v493.337a33.042 33.042 0 0 0 49.563 28.453l463.048-265.255a33.042 33.042 0 0 0 16.521-28.453V291.566a33.042 33.042 0 0 0-14.226-27.994z m-54.611-84.9a33.042 33.042 0 0 0-22.487-29.83L550.838 1.53a32.583 32.583 0 0 0-19.733 0L83.659 158.021a33.042 33.042 0 0 0-4.13 61.036l397.882 199.17a33.501 33.501 0 0 0 14.685 3.213 33.96 33.96 0 0 0 13.31 0L969.37 215.845a33.042 33.042 0 0 0 22.029-37.173z" fill="#5E5C5C" ></path></symbol><symbol id="icon-yanzhengyanzhengma" viewBox="0 0 1024 1024"><path d="M943.1 172c-2.4-0.2-245.1-25.3-413.8-147.8-5.1-3.7-11-5.6-17.3-5.6-6.2 0-12.2 1.9-17.3 5.6C326.9 146 83.3 171.8 80.9 172c-15.2 1.4-26.6 14.1-26.6 29.3 0 6.7 0.6 165.8 54.8 344.4 32.1 105.8 76.4 196.4 131.9 269.2 70.3 92.3 158.5 156 262 189.2 2.9 0.9 5.9 1.4 9 1.4s6.1-0.5 8.9-1.4c103.6-33.2 191.7-96.8 262-189.2 55.4-72.7 99.8-163.2 131.9-269.2 54.1-178.6 54.8-337.7 54.8-344.4C969.7 186.1 958.3 173.5 943.1 172zM910.1 227.2l-0.1 1.6c-2.9 58.1-13.4 174.4-51.4 299.9-66.7 220.1-183.1 360.1-346 416.1L512 945l-0.6-0.2C349 888.9 232.7 749.4 165.8 530.1c-39.8-130.5-49.4-254.2-51.8-301.4l-0.1-1.6 1.5-0.2c70.6-10.3 250.5-44.8 395.5-142.4l0.9-0.7 1 0.7C658 182.1 837.9 216.6 908.5 227L910.1 227.2z" ></path><path d="M641.8 351 467 580.3l-89-76.1c-5.3-4.5-12.1-7-19.1-7-8.6 0-16.8 3.7-22.4 10.3-10.5 12.3-9.1 31 3.3 41.5l112.7 96.4c5.2 4.4 12.4 7 19.6 7 0.9 0 1.8 0 2.7-0.1 8-0.8 15.4-5 20.3-11.4l193.7-254c4.8-6.3 6.8-14 5.7-21.8-1-7.8-5.1-14.7-11.3-19.5C670.1 335.6 651.6 338.1 641.8 351z" ></path></symbol><symbol id="icon-verify" viewBox="0 0 1024 1024"><path d="M713.856 93.44c44.672 9.344 79.36 15.488 105.024 18.944a332.8 332.8 0 0 0 28.864 3.008A110.08 110.08 0 0 1 944 223.36v348.672c0 71.232-36.288 168.32-80.704 219.328a737.216 737.216 0 0 1-100.672 106.496C683.264 966.208 599.232 1008 512 1008s-171.328-41.792-250.624-110.144c-26.88-23.168-51.2-47.808-72.832-72.512a409.152 409.152 0 0 1-24.768-30.208c-47.68-52.928-83.776-150.4-83.776-223.104V223.36c0-54.72 42.752-102.528 99.264-108.096 5.76-0.32 17.536-1.408 34.432-3.648a953.6 953.6 0 0 0 95.168-17.92c19.392-4.608 34.944-12.16 65.92-30.4l9.984-5.888C434.048 28.416 466.432 16 512 16c39.296 0 68.288 11.84 127.488 43.968l2.304 1.28c38.784 21.056 55.296 28.672 72.064 32.192z m-19.712 93.952c-29.376-6.144-50.688-16-98.176-41.856l-2.304-1.216C549.312 120.32 529.088 112 512 112c-24.192 0-42.88 7.168-78.656 28.16-4.736 2.88-4.736 2.88-9.728 5.76-38.784 22.912-61.12 33.664-92.48 41.216-37.76 8.96-72.96 15.36-104.768 19.648a556.8 556.8 0 0 1-39.68 4.16c-5.12 0.512-10.688 6.784-10.688 12.416v348.672c0 49.344 27.52 123.84 62.08 162.56a642.176 642.176 0 0 0 85.952 90.56c63.552 54.72 128.192 86.848 187.968 86.848 59.776 0 124.416-32.128 187.968-86.848a642.176 642.176 0 0 0 88.32-93.632c31.808-36.608 59.712-111.36 59.712-159.488V223.36c0-5.44-5.888-12.032-6.656-12.288-20.288-0.448-66.112-6.72-147.2-23.68zM400.128 488.704L487.68 576.256l185.088-185.088a48 48 0 0 1 67.84 67.84L521.6 678.144a48 48 0 0 1-67.84 0l-121.6-121.536a48 48 0 1 1 67.968-67.84z" fill="#768893" ></path></symbol><symbol id="icon-preview" viewBox="0 0 1024 1024"><path d="M854.36155804 32.02835121a114.60838884 114.60838884 0 0 1 114.21544637 105.17775738l0.39294247 9.43063278v170.60277392a49.1178817 49.1178817 0 0 1-97.77732893 6.68003145l-0.45843311-6.68003145V146.63674137a16.37262679 16.37262679 0 0 0-12.63966726-15.9796843l-3.73295954-0.39294246H130.1675186a16.37262679 16.37262679 0 0 0-15.91419368 12.57417659l-0.45843312 3.79845017v732.18388095a16.37262679 16.37262679 0 0 0 12.63966859 15.91419369l3.73295821 0.4584331h275.4530781a49.1178817 49.1178817 0 0 1 6.68003143 97.77732894l-6.68003143 0.4584331H130.1675186a114.60838884 114.60838884 0 0 1-114.21544639-105.24324667l-0.39294246-9.36514216V146.63674137a114.60838884 114.60838884 0 0 1 105.24324669-114.28093698l9.36514216-0.32745318h724.19403944z m-286.32450218 495.1082417a235.76582919 235.76582919 0 0 1 358.88798459 303.35203402l80.61881587 80.55332523a39.29430509 39.29430509 0 0 1-55.53595059 55.66693187l-80.61881589-80.61881587a235.83131983 235.83131983 0 0 1-303.35203398-358.88798459z m277.87622625 55.60144257a157.17721902 157.17721902 0 1 0-222.27478502 222.2747837 157.17721902 157.17721902 0 0 0 222.27478502-222.2747837z m-450.70567639-33.26917864a42.56883017 42.56883017 0 1 1 0 85.13766035H210.39339064a42.56883017 42.56883017 0 1 1 0-85.13766035h184.81421508z m0-158.68350096a42.56883017 42.56883017 0 1 1 0 85.13766036H210.39339064a42.56883017 42.56883017 0 1 1 0-85.13766036h184.81421508z m233.67013285-158.68350095a42.56883017 42.56883017 0 1 1 0 85.13766036h-418.48434793a42.56883017 42.56883017 0 1 1 0-85.13766036h418.48434793z" fill="#7f7f7f" ></path></symbol><symbol id="icon-yunshangchuan-xian" viewBox="0 0 1039 1024"><path d="M711.40656 345.248C667.88656 248.448 594.91056 208 481.83856 208c-118.848 0-219.328 96.512-256.736 267.76l-4.96 22.752-23.2 2.256c-83.744 8.192-120.176 54.176-131.36 144.4C54.30256 736.528 103.18256 816 193.85456 816h190.672a32 32 0 1 1 0 64H193.83856C58.68656 880-13.44144 762.72 2.07856 637.296 15.61456 528 65.80656 458.416 167.75856 440.224 215.27856 254.704 335.99856 144 481.83856 144c143.072 0 241.184 58.72 294.24 189.808 3.328-0.176 6.576-0.272 9.76-0.272 125.184 0 223.68 93.696 239.84 252.768 0.896 8.96 1.36 17.952 1.36 26.96C1027.03856 760.576 907.61456 880 760.30256 880h-120.064a32 32 0 1 1 0-64h120.064c111.968 0 202.72-90.768 202.72-202.736 0-6.848-0.32-13.68-1.024-20.48-12.912-127.088-84.544-195.248-176.16-195.248-23.136 0-55.68 7.232-96.928 22.032a32 32 0 1 1-21.616-60.224c15.584-5.6 30.288-10.304 44.112-14.08zM544.23856 598.512V848a32 32 0 0 1-64 0V598.512l-39.712 46.32a32 32 0 1 1-48.592-41.664l95.632-111.552a32.032 32.032 0 0 1 49.344 0l95.616 111.552a32 32 0 0 1-48.592 41.664l-39.696-46.32z" ></path></symbol><symbol id="icon-yulan" viewBox="0 0 1024 1024"><path d="M897.28 85.333333h-750.933333c-28.16 0-51.2 23.04-51.2 51.2v750.933334c0 28.16 23.04 51.2 51.2 51.2h276.906666c18.773333 0 34.133333-15.36 34.133334-34.133334s-15.36-34.133333-34.133334-34.133333H163.413333V153.6h716.8v275.626667c0 18.773333 15.36 34.133333 34.133334 34.133333s34.133333-15.36 34.133333-34.133333V136.533333c0-28.16-22.613333-51.2-51.2-51.2z" fill="#4C4C4C" ></path><path d="M649.813333 315.733333h-324.266666c-18.773333 0-34.133333-15.36-34.133334-34.133333s15.36-34.133333 34.133334-34.133333h324.266666c18.773333 0 34.133333 15.36 34.133334 34.133333s-14.933333 34.133333-34.133334 34.133333zM564.48 452.266667h-238.933333c-18.773333 0-34.133333-15.36-34.133334-34.133334s15.36-34.133333 34.133334-34.133333h238.933333c18.773333 0 34.133333 15.36 34.133333 34.133333s-14.933333 34.133333-34.133333 34.133334zM479.146667 588.8h-153.6c-18.773333 0-34.133333-15.36-34.133334-34.133333s15.36-34.133333 34.133334-34.133334h153.6c18.773333 0 34.133333 15.36 34.133333 34.133334s-14.933333 34.133333-34.133333 34.133333zM724.48 544c-94.293333 0-170.666667 76.373333-170.666667 170.666667s76.373333 170.666667 170.666667 170.666666 170.666667-76.373333 170.666667-170.666666-76.373333-170.666667-170.666667-170.666667z m0 273.066667c-56.32 0-102.4-46.08-102.4-102.4s46.08-102.4 102.4-102.4 102.4 46.08 102.4 102.4-45.653333 102.4-102.4 102.4z" fill="#4C4C4C" ></path><path d="M938.666667 928.853333c-13.226667 13.226667-34.986667 13.226667-48.213334 0l-72.533333-72.533333c-13.226667-13.226667-13.226667-34.986667 0-48.213333 13.226667-13.226667 34.986667-13.226667 48.213333 0l72.533334 72.533333c13.226667 13.226667 13.226667 34.56 0 48.213333z" fill="#4C4C4C" ></path></symbol><symbol id="icon-sousuo" viewBox="0 0 1024 1024"><path d="M1004.8 915.2l-243.2-243.2c0 0-6.4-6.4-6.4-6.4C800 595.2 832 505.6 832 416 832 185.6 646.4 0 416 0S0 185.6 0 416 185.6 832 416 832c89.6 0 179.2-32 243.2-83.2 0 6.4 6.4 6.4 6.4 6.4l243.2 243.2c25.6 25.6 70.4 25.6 96 6.4C1030.4 979.2 1030.4 940.8 1004.8 915.2zM64 416C64 224 224 64 416 64S768 224 768 416 608 768 416 768 64 608 64 416z" fill="#231815" ></path></symbol><symbol id="icon-ziliucheng" viewBox="0 0 1024 1024"><path d="M212.992 526.336 212.992 526.336 212.992 526.336 215.04 526.336 212.992 526.336Z" ></path><path d="M813.056 768l96.256 0c20.48 0 38.912 16.384 38.912 38.912l0 96.256c0 20.48-16.384 38.912-38.912 38.912l-96.256 0c-20.48 0-38.912-16.384-38.912-38.912l0-38.912-18.432 0c-53.248 0-96.256-43.008-96.256-96.256L659.456 614.4l-96.256 0 0 192.512c0 20.48-16.384 38.912-38.912 38.912L120.832 845.824c-20.48 0-38.912-16.384-38.912-38.912L81.92 401.408c0-20.48 16.384-38.912 38.912-38.912l192.512 0L313.344 190.464 120.832 190.464C98.304 190.464 81.92 174.08 81.92 151.552L81.92 112.64c0-20.48 16.384-38.912 38.912-38.912l788.48 0c20.48 0 38.912 16.384 38.912 38.912l0 38.912c0 20.48-16.384 38.912-38.912 38.912L331.776 190.464l0 174.08 192.512 0c20.48 0 38.912 16.384 38.912 38.912L563.2 593.92l96.256 0 0-153.6c0-53.248 43.008-96.256 96.256-96.256l18.432 0 0-38.912c0-20.48 16.384-38.912 38.912-38.912l96.256 0c20.48 0 38.912 16.384 38.912 38.912l0 96.256c0 20.48-16.384 38.912-38.912 38.912l-96.256 0c-20.48 0-38.912-16.384-38.912-38.912l0-38.912-18.432 0c-43.008 0-77.824 34.816-77.824 77.824L677.888 593.92l96.256 0 0-38.912c0-20.48 16.384-38.912 38.912-38.912l96.256 0c20.48 0 38.912 16.384 38.912 38.912l0 96.256c0 20.48-16.384 38.912-38.912 38.912l-96.256 0c-20.48 0-38.912-16.384-38.912-38.912L774.144 614.4l-96.256 0 0 153.6c0 43.008 34.816 77.824 77.824 77.824l18.432 0 0-38.912C774.144 784.384 792.576 768 813.056 768z" ></path></symbol><symbol id="icon-danyuange" viewBox="0 0 1024 1024"><path d="M467.970999 661.248453h-184.831769a70.655912 70.655912 0 0 0-54.527932 25.599968A82.431897 82.431897 0 0 0 204.803328 744.19235v196.607754A82.687897 82.687897 0 0 0 228.611298 998.400032a71.423911 71.423911 0 0 0 54.527932 25.599968h184.831769a73.727908 73.727908 0 0 0 55.039931-25.599968 81.919898 81.919898 0 0 0 23.551971-58.623927v-195.583755a81.919898 81.919898 0 0 0-23.551971-58.367927 72.959909 72.959909 0 0 0-55.039931-25.599968z m5.887993-84.991893A118.015852 118.015852 0 0 0 512.002944 549.376593 127.99984 127.99984 0 0 0 545.538902 460.800704V126.465122A133.119834 133.119834 0 0 0 537.602912 76.801184a123.391846 123.391846 0 0 0-25.599968-40.447949 118.015852 118.015852 0 0 0-37.119954-25.599968A104.703869 104.703869 0 0 0 428.547048 0.00128H116.995438A105.471868 105.471868 0 0 0 71.683494 9.985268a121.087849 121.087849 0 0 0-37.119953 25.599968A127.99984 127.99984 0 0 0 9.219572 76.801184 133.119834 133.119834 0 0 0 0.003584 126.465122V460.800704a127.99984 127.99984 0 0 0 34.559957 88.31989 121.087849 121.087849 0 0 0 37.119953 27.135966 105.471868 105.471868 0 0 0 45.311944 9.983987h311.55161a106.239867 106.239867 0 0 0 45.311944-9.983987z m527.35934-329.215589a71.67991 71.67991 0 0 0-54.783931-25.599968h-184.575769a72.959909 72.959909 0 0 0-55.295931 25.599968 81.919898 81.919898 0 0 0-23.551971 58.367927v195.583756a83.199896 83.199896 0 0 0 23.551971 59.647925 73.983908 73.983908 0 0 0 55.295931 25.599968H947.2024a72.447909 72.447909 0 0 0 54.783932-25.599968 84.991894 84.991894 0 0 0 22.015972-59.647925v-195.583756a82.943896 82.943896 0 0 0-22.783972-58.367927zM947.2024 661.248453h-185.343768a72.959909 72.959909 0 0 0-55.295931 25.599968 81.919898 81.919898 0 0 0-23.551971 58.367927v196.607755A81.919898 81.919898 0 0 0 706.562701 998.400032a73.983908 73.983908 0 0 0 55.295931 25.599968H947.2024a72.447909 72.447909 0 0 0 54.783932-25.599968 83.455896 83.455896 0 0 0 22.015972-57.599928v-196.607754a83.199896 83.199896 0 0 0-22.783972-58.367927 71.67991 71.67991 0 0 0-54.783931-25.599968z m0 0" ></path></symbol><symbol id="icon-rengongzhineng_filledbeifen" viewBox="0 0 1024 1024"><path d="M913.678222 374.556444c0-175.431111-160.782222-317.653333-359.139555-317.653333a382.577778 382.577778 0 0 0-254.663111 93.767111 270.108444 270.108444 0 0 0-91.335112 118.840889 318.350222 318.350222 0 0 0-20.849777 98.773333c-0.597333 38.840889 18.389333 76.871111 1.664 114.688-11.633778 26.453333-41.870222 48.824889-61.312 69.916445 0 0-54.442667 36.224 49.436444 41.173333 2.929778 0.142222 16.071111 62.222222 19.342222 76.430222a16.753778 16.753778 0 0 0-3.271111 10.752c0 11.904 15.004444 21.617778 33.450667 21.617778h11.278222c-24.362667 3.313778-41.955556 12.8-41.955555 26.026667 0 9.102222 11.562667 21.105778 28.842666 28.302222 0 0-21.333333 66.744889 10.296889 81.962667a36.977778 36.977778 0 0 0 21.333333 1.564444c44.856889 2.446222 125.155556-0.739556 169.784889-0.739555 0-0.810667 23.466667 127.146667 23.466667 127.146666h403.299556c0 0.64-38.769778-289.265778-38.769778-289.265777 70.968889-101.632 95.544889-192.611556 96.881778-268.643556 1.422222-11.491556 2.161778-23.068444 2.176-34.659556h0.042666zM701.155556 320.711111a72.632889 72.632889 0 0 1-65.706667-42.055111l-54.471111 31.544889a108.344889 108.344889 0 0 1-7.509334 107.975111l102.172445 59.192889a36.508444 36.508444 0 1 1-10.894222 25.984 35.555556 35.555556 0 0 1 2.019555-10.026667L561.777778 432.512a109.511111 109.511111 0 1 1 10.168889-138.154667l57.728-33.422222a72.718222 72.718222 0 1 1 71.466666 59.733333v0.042667z" fill="#323233" ></path></symbol><symbol id="icon-fuhao-huizhi" viewBox="0 0 1024 1024"><path d="M254.4 82.624L82.624 254.4a60.704 60.704 0 0 0 0 85.92L254.4 512l128.8-128.8-42.88-42.88-85.92 85.888-42.88-42.88 85.888-85.92-42.88-42.88-85.92 85.888-42.88-42.88 171.776-171.84 171.584 171.616L512 254.4l-171.776-171.84a60.576 60.576 0 0 0-85.76 0z m644.096 644.064l-171.808 171.808-42.88-42.912 85.888-85.888-42.88-42.88-85.92 85.856-42.88-42.88 85.888-85.888-42.912-42.912L512 769.6l171.776 171.776a60.704 60.704 0 0 0 85.92 0l171.776-171.776a60.704 60.704 0 0 0 0-85.92L769.6 512l-42.912 42.88 171.808 171.808zM680.8 211.328l131.968 131.872-43.968 44L636.8 255.2l44-43.872zM240.96 650.976l131.968 131.872-44 44-131.968-131.872 44-44zM680.704 123.424a124.544 124.544 0 0 1 176.288 0.096l43.584 43.52a124.704 124.704 0 0 1 0.096 176.16L355.264 888.416l-268.352 48.384 48.384-268.288L680.704 123.424zM334.4 821.344L857.472 298.656c23.84-23.872 23.552-63.264-0.8-87.52L813.12 167.616c-24.544-24.544-63.552-24.832-87.584-0.8L202.432 689.6l-27.52 159.424 159.52-27.616z" fill="#0A8CF0" ></path></symbol><symbol id="icon-shanchu" viewBox="0 0 1024 1024"><path d="M799.2 874.4c0 34.4-28.001 62.4-62.4 62.4H287.2c-34.4 0-62.4-28-62.4-62.4V212h574.4v662.4zM349.6 100c0-7.2 5.6-12.8 12.8-12.8h300c7.2 0 12.8 5.6 12.8 12.8v37.6H349.6V100z m636.8 37.6H749.6V100c0-48.001-39.2-87.2-87.2-87.2h-300c-48 0-87.2 39.199-87.2 87.2v37.6H37.6C16.8 137.6 0 154.4 0 175.2s16.8 37.6 37.6 37.6h112v661.6c0 76 61.6 137.6 137.6 137.6h449.6c76 0 137.6-61.6 137.6-137.6V212h112c20.8 0 37.6-16.8 37.6-37.6s-16.8-36.8-37.6-36.8zM512 824c20.8 0 37.6-16.8 37.6-37.6v-400c0-20.8-16.8-37.6-37.6-37.6s-37.6 16.8-37.6 37.6v400c0 20.8 16.8 37.6 37.6 37.6m-175.2 0c20.8 0 37.6-16.8 37.6-37.6v-400c0-20.8-16.8-37.6-37.6-37.6s-37.6 16.8-37.6 37.6v400c0.8 20.8 17.6 37.6 37.6 37.6m350.4 0c20.8 0 37.6-16.8 37.6-37.6v-400c0-20.8-16.8-37.6-37.6-37.6s-37.6 16.8-37.6 37.6v400c0 20.8 16.8 37.6 37.6 37.6" fill="#8A8A8A" ></path></symbol><symbol id="icon-jurassic_import-form" viewBox="0 0 1024 1024"><path d="M764.9 64H225.4l1.4 224.2 64-0.4-1-159.8h383.6v224H896v544H289.8l1-159.8-64-0.4-1.4 224.2H960V277.7L764.9 64z m-27.6 64.7L882.8 288H737.3V128.7z" fill="#707070" ></path><path d="M356.5 224h255.9v64H356.5z" fill="#707070" ></path><path d="M576.4 416h255.9v64H576.4zM512.5 576h319.8v64H512.5zM384.5 736h447.8v64H384.5z" fill="#707070" ></path><path d="M336.9 349H198.6l98.9 98.9H64v128.2h233.5L198.6 675h138.3l162.9-163z" fill="#707070" ></path></symbol><symbol id="icon-kaoheweidufenxi" viewBox="0 0 1024 1024"><path d="M815.542857 212.943238l118.296381 68.266667v168.033524l-201.532952 116.345904-0.487619-163.352381-125.366857-72.46019 209.091047-116.833524z m-89.673143-51.736381L519.314286 279.454476 305.785905 156.233143 511.561143 37.449143l214.308571 123.757714zM294.619429 887.466667L89.234286 768.877714V546.133333l205.677714 118.00381-0.292571 223.329524z m85.333333 49.249523l-0.097524-223.914666 133.607619 76.653714 132.632381-76.604952-1.024 222.744381-133.558857 77.043809-131.510857-75.922286zM434.468571 328.021333L295.253333 407.747048l-0.195047 156.672L89.234286 444.318476V281.258667l132.047238-76.263619 213.089524 123.026285z m86.113524 49.737143l126.780953 73.191619-0.780191 164.08381-133.12 76.897524-133.656381-78.019048-0.097524-157.403429 140.921905-78.750476z m413.257143 169.008762v222.110476l-200.655238 115.809524-0.633905-221.769143 201.289143-116.150857z" fill="#82529d" ></path></symbol><symbol id="icon-wenjianjia" viewBox="0 0 1024 1024"><path d="M855.04 385.024q19.456 2.048 38.912 10.24t33.792 23.04 21.504 37.376 2.048 54.272q-2.048 8.192-8.192 40.448t-14.336 74.24-18.432 86.528-19.456 76.288q-5.12 18.432-14.848 37.888t-25.088 35.328-36.864 26.112-51.2 10.24l-567.296 0q-21.504 0-44.544-9.216t-42.496-26.112-31.744-40.96-12.288-53.76l0-439.296q0-62.464 33.792-97.792t95.232-35.328l503.808 0q22.528 0 46.592 8.704t43.52 24.064 31.744 35.84 12.288 44.032l0 11.264-53.248 0q-40.96 0-95.744-0.512t-116.736-0.512-115.712-0.512-92.672-0.512l-47.104 0q-26.624 0-41.472 16.896t-23.04 44.544q-8.192 29.696-18.432 62.976t-18.432 61.952q-10.24 33.792-20.48 65.536-2.048 8.192-2.048 13.312 0 17.408 11.776 29.184t29.184 11.776q31.744 0 43.008-39.936l54.272-198.656q133.12 1.024 243.712 1.024l286.72 0z" ></path></symbol><symbol id="icon-biaoqian" viewBox="0 0 1024 1024"><path d="M934.912 516.096q23.552 26.624 19.456 49.664t-26.624 46.592l-324.608 327.68q-8.192 7.168-19.456 11.264t-23.04 4.608-23.04-2.56-18.432-10.24q-121.856-122.88-218.112-220.16l-80.896-80.896q-39.936-39.936-71.168-71.68t-51.2-51.2-20.992-21.504q-3.072-4.096-10.752-14.848t-6.656-25.088l0-19.456 0-40.96q0-23.552 0.512-52.736t0.512-58.88q1.024-70.656 2.048-156.672 2.048-13.312 6.144-24.064t15.36-22.016q10.24-11.264 22.016-16.384t22.016-5.12l329.728 0q2.048 0 9.216 0.512t10.24 1.536q6.144 2.048 11.264 5.12t10.24 8.192zM217.088 317.44q40.96 0 69.12-28.672t28.16-69.632-28.16-69.632-69.12-28.672q-20.48 0-37.888 7.68t-30.72 20.992-20.992 31.232-7.68 38.4 7.68 38.4 20.992 31.232 30.72 20.992 37.888 7.68z" fill="#ea9518" ></path></symbol><symbol id="icon-wenben" viewBox="0 0 1024 1024"><path d="M823.296 60.416q65.536 0 99.328 38.4t33.792 93.696l0 543.744q0 25.6-21.504 46.08l-171.008 163.84q-13.312 11.264-22.528 14.336t-23.552 3.072l-459.776 0q-23.552 0-47.104-9.728t-41.984-27.648-30.208-43.008-11.776-55.808l0-634.88q0-60.416 33.28-96.256t94.72-35.84l568.32 0zM608.256 702.464q13.312 0 22.528-9.216t9.216-22.528q0-14.336-9.216-23.04t-22.528-8.704l-320.512 0q-13.312 0-22.528 8.704t-9.216 23.04q0 13.312 9.216 22.528t22.528 9.216l320.512 0zM736.256 509.952q13.312 0 22.528-9.216t9.216-22.528-9.216-22.528-22.528-9.216l-448.512 0q-13.312 0-22.528 9.216t-9.216 22.528 9.216 22.528 22.528 9.216l448.512 0zM799.744 318.464q13.312 0 22.528-9.216t9.216-23.552q0-13.312-9.216-22.528t-22.528-9.216l-512 0q-13.312 0-22.528 9.216t-9.216 22.528q0 14.336 9.216 23.552t22.528 9.216l512 0z" fill="#db639b" ></path></symbol><symbol id="icon-yingyong" viewBox="0 0 1026 1024"><path d="M371.732817 94.172314q25.773475 0 44.112294 17.843175t18.338819 43.616651l0 247.821878q0 25.773475-18.338819 44.112294t-44.112294 18.338819l-247.821878 0q-25.773475 0-43.616651-18.338819t-17.843175-44.112294l0-247.821878q0-25.773475 17.843175-43.616651t43.616651-17.843175l247.821878 0zM371.732817 589.81607q25.773475 0 44.112294 17.843175t18.338819 43.616651l0 248.813166q0 25.773475-18.338819 43.616651t-44.112294 17.843175l-247.821878 0q-25.773475 0-43.616651-17.843175t-17.843175-43.616651l0-248.813166q0-25.773475 17.843175-43.616651t43.616651-17.843175l247.821878 0zM868.367861 589.81607q25.773475 0 43.616651 17.843175t17.843175 43.616651l0 248.813166q0 25.773475-17.843175 43.616651t-43.616651 17.843175l-247.821878 0q-25.773475 0-44.112294-17.843175t-18.338819-43.616651l0-248.813166q0-25.773475 18.338819-43.616651t44.112294-17.843175l247.821878 0zM1006.156825 203.21394q19.82575 19.82575 19.82575 46.590513t-19.82575 45.599226l-184.379477 184.379477q-19.82575 19.82575-46.094869 19.82575t-46.094869-19.82575l-184.379477-184.379477q-18.834463-18.834463-18.834463-45.599226t18.834463-46.590513l184.379477-184.379477q19.82575-18.834463 46.094869-18.834463t46.094869 18.834463z" fill="#0061b2" ></path></symbol><symbol id="icon-wenjianjia-copy" viewBox="0 0 1024 1024"><path d="M855.04 385.024q19.456 2.048 38.912 10.24t33.792 23.04 21.504 37.376 2.048 54.272q-2.048 8.192-8.192 40.448t-14.336 74.24-18.432 86.528-19.456 76.288q-5.12 18.432-14.848 37.888t-25.088 35.328-36.864 26.112-51.2 10.24l-567.296 0q-21.504 0-44.544-9.216t-42.496-26.112-31.744-40.96-12.288-53.76l0-439.296q0-62.464 33.792-97.792t95.232-35.328l503.808 0q22.528 0 46.592 8.704t43.52 24.064 31.744 35.84 12.288 44.032l0 11.264-53.248 0q-40.96 0-95.744-0.512t-116.736-0.512-115.712-0.512-92.672-0.512l-47.104 0q-26.624 0-41.472 16.896t-23.04 44.544q-8.192 29.696-18.432 62.976t-18.432 61.952q-10.24 33.792-20.48 65.536-2.048 8.192-2.048 13.312 0 17.408 11.776 29.184t29.184 11.776q31.744 0 43.008-39.936l54.272-198.656q133.12 1.024 243.712 1.024l286.72 0z" ></path></symbol></svg>',(a=>{var l=(n=(n=document.getElementsByTagName("script"))[n.length-1]).getAttribute("data-injectcss"),n=n.getAttribute("data-disable-injectsvg");if(!n){var r,i,s,h,c,d=function(u,C){C.parentNode.insertBefore(u,C)};if(l&&!a.__iconfont__svg__cssinject__){a.__iconfont__svg__cssinject__=!0;try{document.write("<style>.svgfont {display: inline-block;width: 1em;height: 1em;fill: currentColor;vertical-align: -0.1em;font-size:16px;}</style>")}catch(u){console&&console.log(u)}}r=function(){var u,C=document.createElement("div");C.innerHTML=a._iconfont_svg_string_4827314,(C=C.getElementsByTagName("svg")[0])&&(C.setAttribute("aria-hidden","true"),C.style.position="absolute",C.style.width=0,C.style.height=0,C.style.overflow="hidden",C=C,(u=document.body).firstChild?d(C,u.firstChild):u.appendChild(C))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(r,0):(i=function(){document.removeEventListener("DOMContentLoaded",i,!1),r()},document.addEventListener("DOMContentLoaded",i,!1)):document.attachEvent&&(s=r,h=a.document,c=!1,b(),h.onreadystatechange=function(){h.readyState=="complete"&&(h.onreadystatechange=null,m())})}function m(){c||(c=!0,s())}function b(){try{h.documentElement.doScroll("left")}catch{return void setTimeout(b,50)}m()}})(window);const Af=["onClick"],zf=e.defineComponent({__name:"index",props:{items:{default:()=>[]},disabled:{type:Boolean,default:!1},textSize:{default:void 0},textColor:{default:void 0},backGround:{default:void 0},backGroundImage:{default:void 0},backgroundUrl:{default:""}},emits:["update:backGroundImage"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(null),s=e.ref(null),h=e.computed(()=>{const x=Number(n==null?void 0:n.textSize),w=oe.rgbaToColor(n==null?void 0:n.textColor),g={},E={};return!Number.isNaN(x)&&x&&(g.fontSize=`${x}px`,E.fontSize=`${x}px`),w&&(g.color=w,E.color=w),{label:g,value:E}}),c=e.ref(""),d=e.ref(""),m=e.ref(!1),b=async x=>{if(x){d.value&&(URL.revokeObjectURL(d.value),d.value="");try{const w=await A.platformDownloadFile({url:x}),g=new Blob([w==null?void 0:w.data],{type:(w==null?void 0:w.headers["content-type"])||"image/*"});d.value=URL.createObjectURL(g)}catch{d.value=""}}};e.watch(()=>n==null?void 0:n.backGroundImage,x=>{x&&(c.value=x)},{immediate:!0}),e.watch(c,x=>{b(x)},{immediate:!0});const u=()=>{var x;(x=s.value)==null||x.click()},C=async x=>{var E,P,V;const w=x.target,g=(E=w==null?void 0:w.files)==null?void 0:E[0];if(!g){w.value="";return}m.value=!0;try{const ee=new FormData;ee.append("file",g);const J=await A.platformUploadFile(ee),me=(V=(P=J==null?void 0:J.data)==null?void 0:P.result)==null?void 0:V.url;me?(c.value=me,r("update:backGroundImage",me),b(me),Wa.ElMessage.success("背景图片上传成功")):Wa.ElMessage.error("背景图片上传失败")}catch{Wa.ElMessage.error("背景图片上传失败")}finally{m.value=!1,w.value=""}},M=e.computed(()=>{var x;return d.value||(n==null?void 0:n.backgroundUrl)!==""?{backgroundImage:`url("${(x=n==null?void 0:n.backgroundUrl)==null?void 0:x.replace(/\\/g,"/")}")`,backgroundSize:"cover",backgroundPosition:"center",backgroundRepeat:"no-repeat"}:{}}),k=x=>cl.getComponent(x),W=x=>{if(!x)return;const w=x.querySelector("input, textarea, .el-input__inner");w&&typeof w.focus=="function"&&w.focus()},O=(x,w,g)=>{n.disabled||x.field&&(i.value=w,e.nextTick(()=>{W(g.currentTarget)}))},j=()=>{i.value=null},L=x=>{var g;const w=((g=x==null?void 0:x.field)==null?void 0:g.value)??(x==null?void 0:x.value);return w==null||w===""?"-":w},_=x=>{const w=x!=null&&x.width&&x.width>0?x.width:1,E=`calc((100% - ${(w-1)*16}px) / ${w})`;return{flex:`0 0 ${E}`,maxWidth:E,minWidth:"140px",boxSizing:"border-box"}};return(x,w)=>(e.openBlock(),e.createElementBlock("div",{class:"statistics-cards-container",style:e.normalizeStyle(M.value),onClick:w[2]||(w[2]=g=>(n==null?void 0:n.backGround)&&u())},[n!=null&&n.backGround?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-backGround-upload",onClick:w[0]||(w[0]=e.withModifiers(g=>u(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:s,type:"file",accept:"image/*",style:{display:"none"},onChange:C},null,544),w[3]||(w[3]=e.createElementVNode("img",{src:cl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.items,(g,E)=>{var P,V,ee,J,me,_e,z,ne;return e.openBlock(),e.createElementBlock("div",{class:"statistics-card",key:E,style:e.normalizeStyle(_(g)),onClick:w[1]||(w[1]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",{class:"statistics-label",style:e.normalizeStyle(h.value.label)},e.toDisplayString(g==null?void 0:g.label),5),e.createElementVNode("div",{class:"statistics-value",style:e.normalizeStyle(h.value.value),onClick:Y=>{var te;return(te=g.field)!=null&&te.isNoClick?null:O(g,E,Y)}},[i.value===E&&g.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(k(((P=g.field)==null?void 0:P.type)??"Input")),{key:0,modelValue:g.field.value,"onUpdate:modelValue":Y=>g.field.value=Y,isEdit:!0,disabled:(V=g.field)==null?void 0:V.disabled,content:((ee=g.field)==null?void 0:ee.contents)??[],optionUrl:g.field,originalValue:(J=g.field)==null?void 0:J.value,config:(me=g.field)==null?void 0:me.config,configModel:((_e=g.field)==null?void 0:_e.prop)??((z=g.field)==null?void 0:z.name),selectedTagList:((ne=g.field)==null?void 0:ne.selectValue)??[],onBlur:j,onBlurChange:j},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(L(g)),1)],64))],12,Af)],4)}),128))],4))}}),Mf=ar._export_sfc(zf,[["__scopeId","data-v-af63fc22"]]),vc=A.defineStore("formToTableComp",{state:()=>({selectArray:[],selectString:""}),actions:{setSelectArray(a){this.selectArray=a},setSelectString(a){this.selectString=a}}}),If={class:"calculator-content"},Of={class:"calculator-child"},Lf={class:"calculator-child"},Rf=e.defineComponent({__name:"calculator",setup(a){const l=e.ref(),n=e.ref();return e.onMounted(()=>{l.value=[{type:"Upload",label:"输入",name:"input"}],n.value=[{type:"Upload",label:"输出",name:"output"}]}),(r,i)=>(e.openBlock(),e.createElementBlock("div",If,[e.createElementVNode("div",Of,[e.createVNode(cl.ssForm,{rowContents:l.value,isRowFlex:!0},null,8,["rowContents"])]),e.createElementVNode("div",Lf,[e.createVNode(cl.ssForm,{rowContents:n.value,isEdit:!1,isRowFlex:!0},null,8,["rowContents"])])]))}}),$f=ar._export_sfc(Rf,[["__scopeId","data-v-73db0fe7"]]),_t=(a,l)=>{let n=a,r=l;return Array.isArray(n)&&(n=n==null?void 0:n.map((i,s)=>{if(Array.isArray(i)){let h={};return i=i==null?void 0:i.forEach((c,d)=>{var m;(m=r==null?void 0:r[d])!=null&&m.prop?h[r[d].prop]=c:Array.isArray(c)&&(h.children=_t(c,r))}),Object.assign(h,{id:s})}else return i})),n},mc=(a,l,n)=>{let r=a,i=l;return r=r==null?void 0:r.map((s,h)=>{var c,d;return!Array.isArray(s)||!((c=i==null?void 0:i[h])!=null&&c.label)&&!n||(s.unshift(((d=i==null?void 0:i[h])==null?void 0:d.label)??""),s.some(m=>Array.isArray(m))&&(s=s==null?void 0:s.map(m=>{var b;return Array.isArray(m)&&(m=mc(m,(b=i==null?void 0:i[h])==null?void 0:b.children,n)),m}))),s}),r},Vf=(a,l,n)=>{if(l==="")return a==null?void 0:a.filter(r=>(r==null?void 0:r.id)!==n);{const r=l.split("-");return Pf(a,r,n)}},Pf=(a,l,n)=>{let r=a,i=l;return(i==null?void 0:i.length)===0?r=r==null?void 0:r.filter(s=>s.id!==n):r=r==null?void 0:r.map(s=>(s.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),s=yc(s,i,n)),s)),r},yc=(a,l,n)=>{var s,h;let r=a,i=l;return(i==null?void 0:i.length)===0?r.children=(s=r.children)==null?void 0:s.filter(c=>c.id!==n):r.children=(h=r.children)==null?void 0:h.map(c=>(c.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),c=yc(c,i,n)),c)),r},Ff=(a,l,n)=>{if(l==="")return n;{const r=l.split("-");return jf(a,r,n)}},jf=(a,l,n)=>{let r=a,i=l;return(i==null?void 0:i.length)===0?r=n:r=r==null?void 0:r.map(s=>(s.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),s=gc(s,i,n)),s)),r},gc=(a,l,n)=>{var s;let r=a,i=l;return(i==null?void 0:i.length)===0?r.children=n:r.children=(s=r.children)==null?void 0:s.map(h=>(h.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),h=gc(h,i,n)),h)),r};class Hf{constructor(l={}){tn(this,"url");tn(this,"heartbeatInterval");tn(this,"socket",null);tn(this,"isConnected",!1);tn(this,"heartTimer",null);tn(this,"canvas",null);tn(this,"ctx",null);tn(this,"mainCamCutMode",0);tn(this,"pMainShowStartX",0);tn(this,"pMainShowStartY",0);tn(this,"onLog");tn(this,"onDevCount");tn(this,"onResolution");tn(this,"onCameraStatus");tn(this,"onPhoto");this.url=l.url??"ws://127.0.0.1:22225",this.heartbeatInterval=l.heartbeatInterval??3e3}init(l,n,r){var h;(h=this.canvas)!=null&&h.parentNode&&this.canvas.parentNode.removeChild(this.canvas);const i=document.createElement("canvas");i.style.border="solid 1px #A0A0A0",i.id="MainCamCanvas",i.width=n,i.height=r;const s=i.getContext("2d");if(!s)throw new Error("无法获取 CanvasRenderingContext2D");l.appendChild(i),this.canvas=i,this.ctx=s}async connect(){this.socket&&(this.socket.readyState===WebSocket.OPEN||this.socket.readyState===WebSocket.CONNECTING)||await new Promise((l,n)=>{const r=new WebSocket(this.url);r.binaryType="arraybuffer",r.onopen=()=>{this.socket=r,this.isConnected=!0,this.startHeartbeat(),this.log("socket.onopen"),l()},r.onerror=i=>{this.isConnected=!1,this.log("socket.onerror"),n(i)},r.onclose=()=>{this.isConnected=!1,this.stopHeartbeat(),this.log("socket.onclose")},r.onmessage=i=>{this.handleMessage(i)}})}destroy(){var l;this.stopHeartbeat();try{this.closeCamera()}catch{}if(this.socket){try{this.socket.onmessage=null}catch{}try{this.socket.onopen=null}catch{}try{this.socket.onerror=null}catch{}try{this.socket.onclose=null}catch{}try{this.socket.close()}catch{}this.socket=null}this.isConnected=!1,(l=this.canvas)!=null&&l.parentNode&&this.canvas.parentNode.removeChild(this.canvas),this.canvas=null,this.ctx=null}getDevCount(){this.sendBytes(new Uint8Array([119,136,80]))}getResolution(l=0){this.sendBytes(new Uint8Array([119,136,81,l]))}chooseResolution(l){if(!Array.isArray(l)||l.length===0)return null;const n=l.find(i=>i.width===2592&&i.height===1944);return n||[...l].sort((i,s)=>s.width*s.height-i.width*i.height)[0]||null}openCamera(l=0,n=1280,r=720){if(!this.canvas)throw new Error("请先 init() 传入容器并创建 canvas");const i=new Uint8Array(12);i[0]=119,i[1]=136,i[2]=1,i[3]=l,i[4]=this.canvas.width>>8&255,i[5]=this.canvas.width&255,i[6]=this.canvas.height>>8&255,i[7]=this.canvas.height&255,i[8]=n>>8&255,i[9]=n&255,i[10]=r>>8&255,i[11]=r&255,this.sendBytes(i)}closeCamera(){this.sendBytes(new Uint8Array([119,136,2,0]))}photo(){const i=new Uint8Array(12);i[0]=119,i[1]=136,i[2]=16,i[3]=0,i[4]=0,i[5]=0,i[6]=0,i[7]=0,i[8]=1,i[9]=0,i[10]=0,i[11]=0,this.sendBytes(i)}bestSize(){this.sendBytes(new Uint8Array([119,136,5,0]))}rotateLeft(){this.sendBytes(new Uint8Array([119,136,7,0]))}rotateRight(){this.sendBytes(new Uint8Array([119,136,8,0]))}focus(){this.sendBytes(new Uint8Array([119,136,48,0]))}log(l){var n;(n=this.onLog)==null||n.call(this,l)}sendBytes(l){if(!this.socket||this.socket.readyState!==WebSocket.OPEN||!this.isConnected)throw new Error("socket 未连接");this.socket.send(l.buffer)}startHeartbeat(){this.stopHeartbeat(),this.heartTimer=window.setInterval(()=>{this.log("heartCheck...........")},this.heartbeatInterval)}stopHeartbeat(){this.heartTimer&&(clearInterval(this.heartTimer),this.heartTimer=null)}handleMessage(l){var i,s,h,c,d,m;const n=new Uint8Array(l.data);if(n.length<=0)return;if(n[0]===17&&n[1]===17&&n[2]===17){this.log("heart socket!!!!");return}if(n[0]!==85||n[1]!==102)return;const r=n[2];if(r===80){const b=n[3],u=n.length-4,C=new Uint8Array(u);for(let W=0;W<u;W++)C[W]=n[4+W];const k=decodeURIComponent(this.byteToString(C)).split("|");(i=this.onDevCount)==null||i.call(this,b,k);return}if(r===81){const b=n[3]||0,u=[];for(let C=0;C<b;C++){const M=(n[4+C*4+0]||0)*256+(n[4+C*4+1]||0),k=(n[4+C*4+2]||0)*256+(n[4+C*4+3]||0);u.push({width:M,height:k,text:`${M}*${k}`})}(s=this.onResolution)==null||s.call(this,b,u);return}if(r===1){n[3]===1&&((h=this.onCameraStatus)==null||h.call(this,"opened")),n[3]===3&&((c=this.onCameraStatus)==null||c.call(this,"closed"));return}if(r===16){if(n[3]===1){const u=n[4]*256+n[5],C=n[6]*65536+n[7]*256+n[8];let M="";if(u>0){const O=new Uint8Array(u);for(let j=0;j<u;j++)O[j]=n[9+j];M=decodeURIComponent(this.byteToString(O))}const k=new Uint8Array(C);for(let O=0;O<C;O++)k[O]=n[9+u+O];const W=this.uint8ArrayToString(k);(d=this.onPhoto)==null||d.call(this,{flag:0,imgPath:M,base64:W})}n[3]===2&&((m=this.onPhoto)==null||m.call(this,{flag:2,imgPath:"",base64:""}));return}if(r===204){if(!this.canvas||!this.ctx)return;const b=n[3]*256+n[4],u=n[5]*256+n[6];this.pMainShowStartX=n[7]*256+n[8],this.pMainShowStartY=n[9]*256+n[10],this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height);const C=this.ctx.createImageData(b,u);let M=11;for(let k=0;k<C.data.length;k+=4)C.data[k+0]=n[M],C.data[k+1]=n[M+1],C.data[k+2]=n[M+2],C.data[k+3]=255,M+=3;this.ctx.putImageData(C,this.pMainShowStartX,this.pMainShowStartY),this.mainCamCutMode;return}}uint8ArrayToString(l){let n="";for(let r=0;r<l.length;r++)n+=String.fromCharCode(l[r]);return n}byteToString(l){let n="";for(let r=0;r<l.length;r++)n+=String.fromCharCode(l[r]);return n}}const Uf={style:{display:"flex",gap:"16px",height:"100%"}},qf={key:0,style:{color:"var(--el-text-color-secondary)"}},Wf={style:{width:"420px",display:"flex","flex-direction":"column",gap:"16px"}},Kf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px"}},Gf={ref:"pictureBox",style:{height:"220px",border:"1px dashed var(--el-border-color)","border-radius":"4px",background:"var(--el-fill-color-lighter)",position:"relative",overflow:"auto",padding:"8px"}},Yf={key:0,style:{height:"100%",display:"flex","align-items":"center","justify-content":"center",color:"var(--el-text-color-secondary)"}},Jf={key:1,style:{display:"grid","grid-template-columns":"repeat(2, minmax(0, 1fr))",gap:"8px"}},Xf=["src","onClick"],Zf=["onClick"],Qf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px",flex:"1","min-height":"0",display:"flex","flex-direction":"column"}},e0={class:"dialog-footer"},a0=e.defineComponent({__name:"index",props:{visible:{type:Boolean,default:!1}},emits:["confirm","cancel"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(null),s=e.ref(!1),h=e.ref([]),c=e.ref(""),d=e.ref(!1),m=e.ref([]),b=new Hf({url:"ws://127.0.0.1:22225"});function u(V,ee){var Y;const J=V.split(","),me=((Y=J[0].match(/:(.*?);/))==null?void 0:Y[1])??"image/jpeg",_e=atob(J[1]);let z=_e.length;const ne=new Uint8Array(z);for(;z--;)ne[z]=_e.charCodeAt(z);return new File([ne],ee,{type:me})}function C(){b.onLog=V=>{console.log("[GPY]",V)},b.onDevCount=(V,ee)=>{if(c.value+=`设备数量=${V},设备=${ee.join(",")}
|
|
4
|
-
`,V>0){c.value+=`检测到设备,正在获取分辨率...
|
|
5
|
-
`;try{b.getResolution(0)}catch(J){c.value+=`获取分辨率失败:${(J==null?void 0:J.message)??J}
|
|
6
|
-
`}}else c.value+=`未检测到高拍仪设备!
|
|
7
|
-
`},b.onResolution=(V,ee)=>{if(V<=0||!Array.isArray(ee)||ee.length===0){c.value+=`未获取到可用分辨率,回退使用 1280*720 打开...
|
|
8
|
-
`;try{b.openCamera(0,1280,720)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
|
|
9
|
-
`}return}const J=b.chooseResolution(ee);if(!J){c.value+=`分辨率选择失败,回退使用 1280*720 打开...
|
|
10
|
-
`;try{b.openCamera(0,1280,720)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
|
|
11
|
-
`}return}c.value+=`获取分辨率 ${J.text}成功,打开摄像头...
|
|
12
|
-
`;try{b.closeCamera(),setTimeout(()=>{try{b.openCamera(0,J.width,J.height)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
|
|
13
|
-
`}},100)}catch{try{b.openCamera(0,J.width,J.height)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
|
|
14
|
-
`}}},b.onCameraStatus=V=>{V==="opened"?(s.value=!0,c.value+=`摄像头已打开
|
|
15
|
-
`):(s.value=!1,c.value+=`摄像头已关闭
|
|
16
|
-
`)},b.onPhoto=V=>{if(V.flag===0&&V.base64){const ee=`data:image/jpeg;base64,${V.base64}`,J=u(ee,`gpy-capture-${Date.now()}.jpg`);h.value.push({uid:`${Date.now()}_${Math.random().toString(16).slice(2)}`,url:ee,file:J}),c.value+=`拍照完成,已接收图片(当前 ${h.value.length} 张)
|
|
17
|
-
`}else c.value+=`拍照失败 flag=${V.flag}
|
|
18
|
-
`}}const M=async()=>{if(await e.nextTick(),!i.value)return;k(),C();const V=i.value.getBoundingClientRect();b.init(i.value,Math.floor(V.width),Math.floor(V.height)),c.value+=`正在连接设备服务...
|
|
19
|
-
`,await b.connect(),c.value+=`正在获取设备数量...
|
|
20
|
-
`,b.getDevCount()},k=()=>{try{b.destroy()}catch(V){console.error(V)}s.value=!1,h.value=[],c.value="",d.value=!1,m.value=[]};e.watch(()=>n.visible,V=>{V?M():k()});const W=()=>{try{b.bestSize()}catch(V){console.error(V)}},O=()=>{try{b.rotateLeft()}catch(V){console.error(V)}},j=()=>{try{b.rotateRight()}catch(V){console.error(V)}},L=()=>{try{b.focus()}catch(V){console.error(V)}},_=()=>{c.value+=`正在拍照...
|
|
21
|
-
`;try{b.photo()}catch(V){c.value+=`拍照调用失败:${(V==null?void 0:V.message)??V}
|
|
22
|
-
`}},x=()=>{h.value.length>0?r("confirm",h.value.map(V=>V.file)):r("confirm",[])},w=V=>{V<0||V>=h.value.length||(h.value.splice(V,1),c.value+=`已删除一张图片(剩余 ${h.value.length} 张)
|
|
23
|
-
`)},g=V=>{if(!V)return;const ee=`gpy-preview-${Date.now()}.jpg`;m.value=[{name:ee,blobUrl:V}],d.value=!0},E=()=>{d.value=!1},P=()=>{k(),r("cancel")};return(V,ee)=>{const J=e.resolveComponent("el-input"),me=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(Ar.ssDialog,{title:"扫描录入",visible:n.visible,onBeforeDestroy:P,width:"1200px",style:{height:"80%"}},{default:e.withCtx(()=>[e.createElementVNode("div",Uf,[e.createElementVNode("div",{ref_key:"cameraBox",ref:i,style:{flex:"1","min-width":"0",border:"1px solid var(--el-border-color)","border-radius":"4px",position:"relative",overflow:"hidden",display:"flex","align-items":"center","justify-content":"center",background:"var(--el-fill-color-lighter)"}},[s.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",qf,"初始化摄像头..."))],512),e.createElementVNode("div",Wf,[e.createElementVNode("div",Kf,[ee[0]||(ee[0]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"拍照图片",-1)),e.createElementVNode("div",Gf,[h.value.length===0?(e.openBlock(),e.createElementBlock("div",Yf,"暂无图片")):(e.openBlock(),e.createElementBlock("div",Jf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(_e,z)=>(e.openBlock(),e.createElementBlock("div",{key:_e.uid,style:{position:"relative",border:"1px solid var(--el-border-color)","border-radius":"4px",overflow:"hidden",background:"#fafafa"}},[e.createElementVNode("img",{src:_e.url,onClick:ne=>g(_e.url),style:{width:"100%",height:"94px","object-fit":"contain",display:"block",background:"#fafafa",cursor:"zoom-in"},alt:"captured image",title:"点击放大"},null,8,Xf),e.createElementVNode("div",{onClick:ne=>w(z),style:{position:"absolute",top:"4px",right:"4px",width:"18px",height:"18px","border-radius":"50%",background:"rgba(0,0,0,0.55)",color:"#fff",display:"flex","align-items":"center","justify-content":"center",cursor:"pointer","font-size":"12px"},title:"删除"},"×",8,Zf)]))),128))]))],512)]),e.createElementVNode("div",Qf,[ee[1]||(ee[1]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"操作记录",-1)),e.createVNode(J,{type:"textarea",value:c.value,readonly:"",rows:10,placeholder:"设备操作记录...",style:{flex:"1"}},null,8,["value"])])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",e0,[e.createVNode(me,{onClick:W,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>ee[2]||(ee[2]=[e.createTextVNode("适屏")])),_:1,__:[2]},8,["disabled"]),e.createVNode(me,{onClick:O,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>ee[3]||(ee[3]=[e.createTextVNode("左旋")])),_:1,__:[3]},8,["disabled"]),e.createVNode(me,{onClick:j,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>ee[4]||(ee[4]=[e.createTextVNode("右旋")])),_:1,__:[4]},8,["disabled"]),e.createVNode(me,{onClick:L,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>ee[5]||(ee[5]=[e.createTextVNode("对焦")])),_:1,__:[5]},8,["disabled"]),e.createVNode(me,{onClick:_,disabled:!s.value,id:"themeButton"},{default:e.withCtx(()=>ee[6]||(ee[6]=[e.createTextVNode("拍照")])),_:1,__:[6]},8,["disabled"]),ee[9]||(ee[9]=e.createElementVNode("div",{style:{flex:"1"}},null,-1)),e.createVNode(me,{onClick:x,disabled:h.value.length===0,id:"themeButton"},{default:e.withCtx(()=>ee[7]||(ee[7]=[e.createTextVNode("确认")])),_:1,__:[7]},8,["disabled"]),e.createVNode(me,{onClick:P,id:"themeBorderButton"},{default:e.withCtx(()=>ee[8]||(ee[8]=[e.createTextVNode("取消")])),_:1,__:[8]})])]),_:1},8,["visible"]),d.value?(e.openBlock(),e.createBlock(cl.ssFilePreview,{key:0,fileDataList:m.value,onDestroy:E},null,8,["fileDataList"])):e.createCommentVNode("",!0)],64)}}}),l0=ar._export_sfc(a0,[["__scopeId","data-v-24a2050a"]]),gs=A.useMenuState(A.pinia),r0=async a=>{var s,h,c,d,m,b;let l=a==null?void 0:a.导入文件,n=a==null?void 0:a.函数参数,r=(s=l==null?void 0:l[0])==null?void 0:s.url,i="";if(!(r!=null&&r.includes("http"))||!(r!=null&&r.includes("https"))){gs.setContentLoading(!0);const u=await A.platformDownloadFile({url:r});let C=u==null?void 0:u.data;const M=new FormData;M.append("file",C,((h=l==null?void 0:l[0])==null?void 0:h.name)+"."+((c=r==null?void 0:r.split("."))==null?void 0:c[1])),M.append("query",n);let k=await rc(M);k=(b=(m=(d=k==null?void 0:k.data)==null?void 0:d.data)==null?void 0:m.response)==null?void 0:b.replace("generateResult",a==null?void 0:a.函数名称),i=k,gs.setContentLoading(!1)}return i},zt=A.defineStore("formComp",{state:()=>({objUrl:[],blobUrls:[]}),actions:{setObjUrl(a){this.objUrl=a},setBlobUrls(a){this.blobUrls=a}}}),n0=A.useModelComp(A.pinia),{extraContents:yv}=A.storeToRefs(n0),i0=A.useLoginState(A.pinia),{extraUrl:ui}=A.storeToRefs(i0);let bc=ui.value===""||!ui.value?"http://139.196.154.85:20015":ui.value;e.watch(()=>ui.value,()=>{bc=ui.value===""||!ui.value?"http://139.196.154.85:20015":ui.value},{deep:!0,immediate:!0});const zo={检校类型:["检校类型","证书类别"],证书编号:["证书编号"],设备名称:["设备名称","器具名称","样品名称","仪器名称","被校设备"],型号规格:["型号规格","型号/规格","型号"],出厂编号:["出厂编号","器具/管理编号","器具编号","管理编号","仪器编号"],制造厂:["制造厂","制造单位","制造厂商","制造商"],检校结果:["检校结果","检定结论","校准结果","校准/检定结果","检定结果"],依据文件:["依据文件","检定依据","检定所依据的技术文件","所依据/参照技术文件(代号/名称)","检定所依据的技术文件(编号/名称)","检定方法说明"],检校日期:["检校日期","校准日期","校验日期","检定日期","发证日期","发布日期","接收日期","签证日期"],有效日期:["有效日期","有效期","有效期至"]},bs={columnName:"OCR图片",acceptTypes:"image/*",maxSize:10,maxFiles:20,apiUrl:bc+"/api/public/paddleOCR"};class o0{constructor(l){tn(this,"config");this.config={...bs,...l}}updateConfig(l){this.config={...this.config,...l}}getConfig(){return{...this.config}}validateFileSize(l){const n=this.config.maxSize*1024*1024;return l.size<=n}validateFileType(l){return l.type.startsWith("image/")||l.type==="application/pdf"}getAuthorizationToken(){const l=Wa.Local.get(Wa.accessTokenKey);return l?`Bearer ${l}`:""}buildOCRRequest(l,n){return{title:n,form:{OCR图片文件:l}}}async recognize(l,n){const r=this.getAuthorizationToken(),i=this.buildOCRRequest(l,n),s=this.config.apiUrl||bs.apiUrl||"";return(await Wa.axios.post(s,i,{headers:{"Content-Type":"application/json",Authorization:r}})).data}getFieldAliases(l){return zo[l]?zo[l]:[l]}extractTableHeaders(l){const n=[],r=new Set,i=h=>{const c=h==null?void 0:h.label;return!(!c||c==="操作"||c===this.config.columnName||(h==null?void 0:h.type)==="operate"||(h==null?void 0:h.prop)==="operate")},s=h=>{(h||[]).forEach(c=>{if(!c)return;const d=(c==null?void 0:c.children)||(c==null?void 0:c.child)||(c==null?void 0:c.columns);if(Array.isArray(d)&&d.length>0){s(d);return}if(i(c)){const m=c.label;if(!r.has(m)){r.add(m);const b=this.getFieldAliases(m);n.push(b)}}})};return s(l||[]),n}}function kc(a){return new o0(a)}kc();const St=async(a,l)=>{var h,c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g;let n=(c=(h=A.cloneDeep(a))==null?void 0:h.optionUrl)==null?void 0:c.menuSelect,r=[];n==null||n.forEach(E=>{});let i="",s=await oe.menuToParent(n);if(s==null||s.forEach(E=>{var P,V,ee,J;(E==null?void 0:E.name)===(((J=(ee=(V=(P=A.cloneDeep(a))==null?void 0:P.optionUrl)==null?void 0:V.groupSelect)==null?void 0:ee[0])==null?void 0:J.replaceAll("'",""))??"")&&(i=E==null?void 0:E.id)}),l){i=l;const E=await Rr.getInsofDataApi({id:i}),P=(u=(b=(m=(d=E==null?void 0:E.data)==null?void 0:d.result)==null?void 0:m[0])==null?void 0:b.key)==null?void 0:u.pageKey;s=await oe.getItemData(P,sessionStorage.getItem("systemKey"),"")}if(i!==""){let E;l?E=(C=s==null?void 0:s.find(ee=>(ee==null?void 0:ee.id)===l))==null?void 0:C.compData:E=(M=s==null?void 0:s.find(ee=>{var J,me,_e,z;return(ee==null?void 0:ee.name)===(((me=(J=a==null?void 0:a.groupSelect)==null?void 0:J.split(":"))==null?void 0:me[0])||((z=(_e=a==null?void 0:a.optionUrl)==null?void 0:_e.groupSelect)==null?void 0:z[0]))}))==null?void 0:M.compData;let P=(W=(k=E==null?void 0:E.find(ee=>(ee==null?void 0:ee.key)==="header"))==null?void 0:k.contents)==null?void 0:W.map(ee=>ee==null?void 0:ee.label);(j=(O=E==null?void 0:E.find(ee=>(ee==null?void 0:ee.key)==="header"))==null?void 0:O.contents)!=null&&j.every(ee=>Array.isArray(ee))&&(P=(x=oe.getColumnChild((_=(L=E==null?void 0:E.find(ee=>(ee==null?void 0:ee.key)==="header"))==null?void 0:L.contents)==null?void 0:_[0]))==null?void 0:x.map(ee=>ee==null?void 0:ee.prop));let V=(g=(w=E==null?void 0:E.find(ee=>(ee==null?void 0:ee.key)==="tableContents"))==null?void 0:w.contents)==null?void 0:g.map(ee=>{if(Array.isArray(ee))ee=ee==null?void 0:ee.filter(J=>!(J!=null&&J.id));else{let J={};for(let me in ee)me!=="id"&&(J[me]=ee==null?void 0:ee[me]);ee=J}return ee});V==null||V.forEach(ee=>{Array.isArray(ee)?r.push(oe.getValueToObjectValue(ee,P)):r.push(ee)})}return r},t0=A.useMenuState(A.pinia),{activeMenuPath:gv}=A.storeToRefs(t0),s0=A.useUnit(A.pinia),{chooseTitle:bv}=A.storeToRefs(s0),c0="col-operate",xc=a=>`${c0}-${a}`,u0=(a,l)=>{const n=new Map;a.forEach(i=>{const{prop:s}=i;n.set(s,i)});const r=i=>{Array.isArray(i)&&i.forEach(s=>{const{prop:h}=s||{},c=n.get(h);d0(c,s),Array.isArray(s==null?void 0:s.children)&&s.children.length>0&&r(s.children)})};return r(l),l},d0=(a,l)=>(a&&(l.sortable=a==null?void 0:a.sortable,l.filterable=a==null?void 0:a.filterable,l.showSummary=a==null?void 0:a.showSummary,l.operable=a==null?void 0:a.operable,l.fixed=a==null?void 0:a.fixed),l),p0=(a,l)=>{const{sortable:n=!1,filterable:r=!1,showSummary:i=!1,operable:s=!1,fixed:h=!1}=l||{};return{prop:a,sortable:n,filterable:r,showSummary:i,operable:s,fixed:h}},f0=async a=>{var s,h;if(!a)return;const l=xc(a),n=await Rr.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:l}}),r=(s=n==null?void 0:n.data)==null?void 0:s.code,i=(h=n==null?void 0:n.data)==null?void 0:h.result;if(r==200)return i==null?void 0:i[0]},h0=async a=>{if(a)return[]},v0=async(a,l)=>{if(!a||!l)return;const n=xc(a);return await Rr.createInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:n},value:{columns:l}})},m0=async(a,l)=>!a||!l?void 0:await Rr.updateInsofDataApi({id:a,value:{columns:l}}),ks=async(a,l)=>{const n=sessionStorage.getItem("systemKey");if(!a||!l||!n)return;const r=await f0(a);return r?await m0(r==null?void 0:r.id,l):await v0(a,l)};var Co={exports:{}},y0=Co.exports,xs;function g0(){return xs||(xs=1,function(a,l){(function(n,r){r()})(y0,function(){function n(m,b){return typeof b>"u"?b={autoBom:!1}:typeof b!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),b={autoBom:!b}),b.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(m.type)?new Blob(["\uFEFF",m],{type:m.type}):m}function r(m,b,u){var C=new XMLHttpRequest;C.open("GET",m),C.responseType="blob",C.onload=function(){d(C.response,b,u)},C.onerror=function(){console.error("could not download file")},C.send()}function i(m){var b=new XMLHttpRequest;b.open("HEAD",m,!1);try{b.send()}catch{}return 200<=b.status&&299>=b.status}function s(m){try{m.dispatchEvent(new MouseEvent("click"))}catch{var b=document.createEvent("MouseEvents");b.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),m.dispatchEvent(b)}}var h=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof A.commonjsGlobal=="object"&&A.commonjsGlobal.global===A.commonjsGlobal?A.commonjsGlobal:void 0,c=h.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),d=h.saveAs||(typeof window!="object"||window!==h?function(){}:"download"in HTMLAnchorElement.prototype&&!c?function(m,b,u){var C=h.URL||h.webkitURL,M=document.createElement("a");b=b||m.name||"download",M.download=b,M.rel="noopener",typeof m=="string"?(M.href=m,M.origin===location.origin?s(M):i(M.href)?r(m,b,u):s(M,M.target="_blank")):(M.href=C.createObjectURL(m),setTimeout(function(){C.revokeObjectURL(M.href)},4e4),setTimeout(function(){s(M)},0))}:"msSaveOrOpenBlob"in navigator?function(m,b,u){if(b=b||m.name||"download",typeof m!="string")navigator.msSaveOrOpenBlob(n(m,u),b);else if(i(m))r(m,b,u);else{var C=document.createElement("a");C.href=m,C.target="_blank",setTimeout(function(){s(C)})}}:function(m,b,u,C){if(C=C||open("","_blank"),C&&(C.document.title=C.document.body.innerText="downloading..."),typeof m=="string")return r(m,b,u);var M=m.type==="application/octet-stream",k=/constructor/i.test(h.HTMLElement)||h.safari,W=/CriOS\/[\d]+/.test(navigator.userAgent);if((W||M&&k||c)&&typeof FileReader<"u"){var O=new FileReader;O.onloadend=function(){var _=O.result;_=W?_:_.replace(/^data:[^;]*;/,"data:attachment/file;"),C?C.location.href=_:location=_,C=null},O.readAsDataURL(m)}else{var j=h.URL||h.webkitURL,L=j.createObjectURL(m);C?C.location=L:location.href=L,C=null,setTimeout(function(){j.revokeObjectURL(L)},4e4)}});h.saveAs=d.saveAs=d,a.exports=d})}(Co)),Co.exports}g0();const Yn=A.defineStore("tabComp",{state:()=>({itemData:[],originalData:[],extraContents:[],nodeDev:"",isEdit:"view",isRefreshCurStructure:!1,isSubmitCurStructure:!1,curStructureCompIds:[],itemGridData:[],itemExtendData:void 0,payloadTypes:"",lockingPage:"",systemPath:void 0,pageMapState:void 0,cacheUpdatingData:void 0,freshContent:!1,tableLoading:!1,routeToChildPath:"",tableViewContents:[],activeItemIndex:0,fixMenuStatus:!1,refreshTable:!1,selectTab:""}),actions:{setItemData(a){this.itemData=a},setCurStructureCompIds(a){this.curStructureCompIds=a},setRefreshCurStructure(a){this.isRefreshCurStructure=a},setOriginalData(a){this.originalData=a},setExtraContents(a){this.extraContents=a},setNodeDev(a){this.nodeDev=a},setIsEdit(a){this.isEdit=a},setSelectTab(a){this.selectTab=a}}}),b0=A.useLoginState(A.pinia),{loginUserInfo:vt}=A.storeToRefs(b0),k0=async a=>{var r,i,s;let l=await A.getAllTables({platId:parseInt((r=vt==null?void 0:vt.value)==null?void 0:r.plat_id),tableNames:[a]});return l=(s=(i=l==null?void 0:l.data)==null?void 0:i.result)==null?void 0:s[0],await hc(l,!1),[{comp:"Table",isShow:!0,name:"日志管理",compData:[{key:"extraButton",contents:[]},{key:"rowButton",contents:[]},{key:"header",contents:[{label:"请求类型",prop:"request_method",formType:"Input",align:"center"},{label:"请求路径",prop:"request_url",formType:"Input",align:"center"},{label:"请求参数",prop:"request_param",formType:"Upload",align:"center"},{label:"返回结果",prop:"request_result",formType:"Upload",align:"center"},{label:"返回信息",prop:"request_message",formType:"Input",align:"center"},{label:"请求表格",prop:"request_table",formType:"Input",align:"center"},{label:"请求种类",prop:"request_type",formType:"Input",align:"center"},{label:"请求创建时间",prop:"create_time",formType:"Date",align:"center"},{label:"请求创建人",prop:"create_user_id",formType:"Input",align:"center"}]},{key:"tableContents",contents:l}]}]},x0=A.useLoginState(),{loginUserInfo:gl}=A.storeToRefs(x0);let xo="$R";const Or=A.useModelComp(A.pinia),wc=e.ref(!1),{itemData:w0,itemGridData:ti,curStructureCompIds:ws,isSubmitCurStructure:_0,routeToChildPath:S0,pageMapState:Et,itemExtendData:wo,refreshTable:_s,refreshCurrentPageInform:E0}=A.storeToRefs(Or),Fo=Yn(A.pinia),Hr=A.useMenuState(A.pinia),dr=e.shallowRef([]),{asideMenus:C0,activeTopMenuPath:D0,activeMenuPath:xl,platform:kv,buttonTriggerType:T0,currentMenuPath:hn}=A.storeToRefs(Hr),wn=A.useUnit(A.pinia),{selectTitle:Wn,chooseTitle:Mo}=A.storeToRefs(wn);e.ref();const Ai=e.ref(!0),Gn=e.ref(0),Ct=e.ref([]);e.ref(!1);const Mt=e.ref(!1),Xi=e.ref(),_c=e.ref(),Sc=e.ref(),B0=()=>{Or.setItemGridData([]),Or.setIsEdit("edit"),Or.setSubmitCurStructure(xl.value!=="/平台管理/菜单管理")},N0=()=>{Or.setIsEdit("view"),Or.setRefreshCurStructure(!0)},A0=async a=>{var i;let l=Wn.value,n=l==null?void 0:l.findIndex(s=>(s==null?void 0:s.value)===(a==null?void 0:a.value)),r=l==null?void 0:l.filter((s,h)=>h<=n);wn.setSelectTitle(cl.safeClone(r)),r=(i=r==null?void 0:r.map(s=>s==null?void 0:s.value))==null?void 0:i.join("/"),Hr.setActiveMenuPath(null),Hr.setActiveMenuPath(r)},mt=async(a,l,n,r="contentConfig")=>{var i;try{if(!Array.isArray(a))return;let s,h;l==="create"?(s={dataList:a==null?void 0:a.map(d=>{var m;return{key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:n!=null&&n.startsWith("/")?n==null?void 0:n.substring(1):n,type:"structure",structureBelong:r,parentTable:"",version:1},value:{pageData:{...d,compData:(m=d==null?void 0:d.compData)==null?void 0:m.filter(b=>(b==null?void 0:b.key)!=="tableContents")}}}})},h=Rr.batchAddInsofDataApi):l==="update"?(s={dataList:a==null?void 0:a.map(d=>{var m;return{id:d==null?void 0:d.id,value:{pageData:{...d,compData:(m=d==null?void 0:d.compData)==null?void 0:m.filter(b=>(b==null?void 0:b.key)!=="tableContents")}}}})},h=Rr.batchUpdateInsofDataApi):l==="delete"&&(s={ids:a},h=Rr.batchDeleteInsofDataApi);const c=await h(s);if(((i=c==null?void 0:c.data)==null?void 0:i.code)===200)return c.data.result;throw Wa.ElMessage.error("保存响应失败"),new Error("保存响应失败")}catch{Wa.ElMessage.error("保存响应失败")}},Ss=async(a,l,n,r)=>{var i,s,h,c,d,m,b,u,C,M,k;try{const W=(s=(i=a==null?void 0:a.results)==null?void 0:i.filter(w=>!(w!=null&&w.id)||typeof(w==null?void 0:w.id)=="string"))==null?void 0:s.map(w=>({key:{pageKey:a==null?void 0:a.pageKey,systemKey:sessionStorage.getItem("systemKey"),type:l,relatedInfo:n},value:{tableData:w}})),O=(c=(h=a==null?void 0:a.results)==null?void 0:h.filter(w=>(w==null?void 0:w.id)&&typeof(w==null?void 0:w.id)=="number"))==null?void 0:c.map(w=>({id:w==null?void 0:w.id,value:{tableData:w}})),j=JSON.parse(JSON.stringify(a)),L=(d=j==null?void 0:j.results)==null?void 0:d.map(w=>w.id);let _;n?_=(u=(b=(m=Et.value)==null?void 0:m[xl.value])==null?void 0:b.filter(w=>{var g,E,P;return((g=w==null?void 0:w.key)==null?void 0:g.type)===l&&((P=(E=w==null?void 0:w.key)==null?void 0:E.relatedInfo)==null?void 0:P.target)===r}))==null?void 0:u.map(w=>w==null?void 0:w.id):_=(k=(M=(C=Et.value)==null?void 0:C[xl.value])==null?void 0:M.filter(w=>{var g;return((g=w==null?void 0:w.key)==null?void 0:g.type)===l}))==null?void 0:k.map(w=>w==null?void 0:w.id);const x=_==null?void 0:_.filter(w=>!(L!=null&&L.includes(w))&&typeof w=="number");(W==null?void 0:W.length)>0&&await Rr.batchAddInsofDataApi({dataList:W}),(O==null?void 0:O.length)>0&&await Rr.batchUpdateInsofDataApi({dataList:O}),(x==null?void 0:x.length)>0&&await Rr.batchDeleteInsofDataApi({ids:x})}catch(W){throw new Error(W)}},z0=async a=>{var m,b,u,C,M,k,W,O,j,L;Hr.setContentLoading(!0);const l=JSON.parse(JSON.stringify(w0.value));if(!_0.value)return Hr.setCacheStructures({key:T0.value,data:l}),Wa.ElMessage.success("已暂存");const n=l==null?void 0:l.map(_=>_.id),r=n.filter(_=>{var x;return!((x=ws.value)!=null&&x.includes(_))}),i=(m=ws.value)==null?void 0:m.filter(_=>!n.includes(_)),s=[...r,...i].filter(_=>typeof _!==null&&typeof _<"u"),h=l==null?void 0:l.filter(_=>!_.id),c=l==null?void 0:l.filter(_=>_.id);let d=[];if(s&&(s==null?void 0:s.length)>0&&d.push(mt(s,"delete",a)),h&&(h==null?void 0:h.length)>0&&d.push(mt(h,"create",a)),c&&(c==null?void 0:c.length)>0&&d.push(mt(c,"update",a)),ti.value&&((b=ti.value)!=null&&b.isDelete&&((C=(u=ti.value)==null?void 0:u.results)==null?void 0:C.length)>0&&((k=(M=ti.value)==null?void 0:M.results)!=null&&k.every(_=>typeof _=="number"))?await Rr.batchDeleteInsofDataApi({ids:(W=ti.value)==null?void 0:W.results}):(console.log("itemGridData.value",ti.value),d.push(await Ss(ti.value,"gridLayout")))),wo.value)for(const _ in wo.value)d.push(await Ss((O=wo.value)==null?void 0:O[_],"extend",{target:_,compId:(L=(j=wo.value)==null?void 0:j[_])==null?void 0:L.compId},_));await Promise.all(d).then(()=>{Wa.ElMessage.success("保存成功"),Or.setRefreshCurStructure(!0)}).catch(_=>{Wa.ElMessage.success(_)}),Hr.setContentLoading(!1)},Zi=a=>zi(a),M0=e.computed(()=>{var a;return(a=dr.value)==null?void 0:a.filter(l=>(l==null?void 0:l.affix)&&(l==null?void 0:l.affix)!=="default")}),Ec=e.computed(()=>{var a;return(a=dr.value)==null?void 0:a.filter(l=>!(l!=null&&l.affix&&(l==null?void 0:l.affix)!=="default"))}),Cc=e.ref(0),Dc=e.ref(null),I0="ocr_committed_temp_ids_v1",O0=(a,l)=>`${I0}:${String(a??"")}:${String(l??"")}`,L0=(a,l,n)=>{try{const r=O0(a,l),i=sessionStorage.getItem(r),s=i?JSON.parse(i):[],h=Array.isArray(s)?s:[],c=Array.from(new Set([...h,...n||[]].map(d=>String(d)))).slice(-200);sessionStorage.setItem(r,JSON.stringify(c))}catch{}},Io=async(a,l="data",n)=>{var i,s,h,c,d,m,b,u,C,M,k,W,O,j,L,_,x,w,g,E,P,V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae,se,Xe,Ze,Ha,_a,Qa,Pe,Re,Ue,Ne,Ie,ul,_l,Tl,jl,Cl,Yl;let r=((h=(s=(i=Wn.value)==null?void 0:i.filter(aa=>(aa==null?void 0:aa.condition)==="child"))==null?void 0:s[0])==null?void 0:h.value)??"";if((a==null?void 0:a.buttonName)==="新增"){let aa=(c=a==null?void 0:a.fixContent)==null?void 0:c.map(qe=>{let Ga={};for(let hl in qe)Array.isArray(qe==null?void 0:qe[hl])?Ga[hl]=JSON.stringify(qe==null?void 0:qe[hl]):Ga[hl]=qe==null?void 0:qe[hl];return Ga}),Ka=await A.quoteApi({platId:parseInt((d=gl==null?void 0:gl.value)==null?void 0:d.plat_id),type:"fatherSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});Ka=(m=Ka==null?void 0:Ka.data)==null?void 0:m.result,Ka=Ka==null?void 0:Ka.filter(qe=>{var Ga,hl;return!((qe==null?void 0:qe.fatherPath)!==""&&((hl=(Ga=qe==null?void 0:qe.quote)==null?void 0:Ga[0])==null?void 0:hl.menus)===(xl==null?void 0:xl.value))});let ma=Ka==null?void 0:Ka.map(qe=>{var na,Sa;let Ga={},hl=aa==null?void 0:aa[0],pe;return Array.isArray((na=qe==null?void 0:qe.struct)==null?void 0:na[0])?pe=oe.getColumnChild((Sa=qe==null?void 0:qe.struct)==null?void 0:Sa[0]):pe=qe==null?void 0:qe.struct,pe=pe==null?void 0:pe.filter(la=>(la==null?void 0:la.prop)!=="relatedId"),pe==null||pe.forEach(la=>{var nl,Je;Ga[la.prop]=((nl=la==null?void 0:la.words)!=null&&nl[0]?(hl==null?void 0:hl[(Je=la==null?void 0:la.words)==null?void 0:Je[0]])??(hl==null?void 0:hl[la==null?void 0:la.prop]):hl==null?void 0:hl[la==null?void 0:la.prop])??""}),Ga.id="1",Ga.relatedId=`[${Ga.id}]`,delete Ga.sort,{tableName:"content_"+(qe==null?void 0:qe.id),tableContents:[Ga]}}),il=[{tableName:(b=a==null?void 0:a.relatedContents)==null?void 0:b.find(qe=>qe==null?void 0:qe.includes("content")),tableContents:aa}];il=[...il,...ma];let Aa=await A.quoteApi({platId:parseInt((u=gl==null?void 0:gl.value)==null?void 0:u.plat_id),type:"sonSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});Aa=(M=(C=Aa==null?void 0:Aa.data)==null?void 0:C.result)==null?void 0:M.filter(qe=>!(il!=null&&il.find(Ga=>(Ga==null?void 0:Ga.tableName)==="content_"+(qe==null?void 0:qe.id)))),Aa=Aa==null?void 0:Aa.filter(qe=>{var Ga,hl;return!((qe==null?void 0:qe.fatherPath)!==""&&((hl=(Ga=qe==null?void 0:qe.quote)==null?void 0:Ga[0])==null?void 0:hl.menus)===(xl==null?void 0:xl.value))});let sl=Aa==null?void 0:Aa.map(qe=>{var na,Sa,la,nl,Je,Fa,wa;let Ga={},hl=aa==null?void 0:aa[0],pe;return Array.isArray((na=qe==null?void 0:qe.struct)==null?void 0:na[0])?pe=oe.getColumnChild((Sa=qe==null?void 0:qe.struct)==null?void 0:Sa[0]):pe=qe==null?void 0:qe.struct,pe=pe==null?void 0:pe.filter(Oa=>(Oa==null?void 0:Oa.prop)!=="relatedId"),((nl=(la=pe==null?void 0:pe[0])==null?void 0:la.words)!=null&&nl[0]?hl!=null&&hl[(Fa=(Je=pe==null?void 0:pe[0])==null?void 0:Je.words)==null?void 0:Fa[0]]:hl!=null&&hl[(wa=pe==null?void 0:pe[0])==null?void 0:wa.prop])?(pe==null||pe.forEach(Oa=>{var Me,Ra;Ga[Oa.prop]=((Me=Oa==null?void 0:Oa.words)!=null&&Me[0]?(hl==null?void 0:hl[(Ra=Oa==null?void 0:Oa.words)==null?void 0:Ra[0]])??(hl==null?void 0:hl[Oa==null?void 0:Oa.prop]):hl==null?void 0:hl[Oa==null?void 0:Oa.prop])??""}),Ga.id="1",Ga.relatedId=`[${Ga.id}]`,delete Ga.sort):Ga=void 0,{tableName:"content_"+(qe==null?void 0:qe.id),tableContents:[Ga]}});sl=sl==null?void 0:sl.filter(qe=>{var Ga;return!((Ga=qe==null?void 0:qe.tableContents)!=null&&Ga.every(hl=>hl===void 0))}),il=[...il,...sl],await A.pageBatchAddApi({platId:parseInt((k=gl==null?void 0:gl.value)==null?void 0:k.plat_id),changeContents:il});let rl=[];il==null||il.forEach(qe=>{var Ga;(Ga=qe==null?void 0:qe.tableContents)==null||Ga.forEach(hl=>{rl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(hl),request_result:"{}",is_delete:!1,request_table:qe==null?void 0:qe.tableName,request_type:"add"})})}),await A.pageBatchAddApi({platId:parseInt((W=gl==null?void 0:gl.value)==null?void 0:W.plat_id),changeContents:[{tableName:"log",tableContents:rl}]})}if((a==null?void 0:a.buttonName)==="OCR批量新增"){const aa=((a==null?void 0:a.ocrRows)||[]).map(Aa=>Aa==null?void 0:Aa.id).filter(Aa=>Aa!=null),Ka=((a==null?void 0:a.ocrRows)||[]).map(Aa=>{const sl={...Aa};return delete sl._isOCRRow,delete sl._ocrTableId,Object.keys(sl).forEach(rl=>{/(^|\.)证书附件$/.test(rl)&&Array.isArray(sl[rl])&&(sl[rl]=JSON.stringify(sl[rl].map(qe=>({url:(qe==null?void 0:qe.url)||"",name:(qe==null?void 0:qe.name)||(qe==null?void 0:qe.fileName)||"",fileName:(qe==null?void 0:qe.fileName)||(qe==null?void 0:qe.name)||""})).filter(qe=>qe.url||qe.name)))}),sl});let ma=[{tableName:(O=a==null?void 0:a.relatedContents)==null?void 0:O.find(Aa=>Aa==null?void 0:Aa.includes("content")),tableContents:Ka}];await A.pageBatchAddApi({platId:parseInt((j=gl==null?void 0:gl.value)==null?void 0:j.plat_id),changeContents:ma});let il=[];ma==null||ma.forEach(Aa=>{var sl;(sl=Aa==null?void 0:Aa.tableContents)==null||sl.forEach(rl=>{il.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(rl),request_result:"{}",is_delete:!1,request_table:Aa==null?void 0:Aa.tableName,request_type:"ocrBatchAdd"})})}),await A.pageBatchAddApi({platId:parseInt((L=gl==null?void 0:gl.value)==null?void 0:L.plat_id),changeContents:[{tableName:"log",tableContents:il}]}),L0(a==null?void 0:a.parentTableId,a==null?void 0:a.index,aa)}if((a==null?void 0:a.buttonName)==="编辑"){const Ka=((a==null?void 0:a.fixContent)||(a==null?void 0:a.singleContent)||[]||[]).map(pe=>{const na={...pe};return delete na._isOCRRow,delete na._ocrTableId,delete na._isTemp,delete na.tableEditType,delete na.index,na});let ma=Ka==null?void 0:Ka.map(pe=>{let na={};for(let Sa in pe)Array.isArray(pe==null?void 0:pe[Sa])?na[Sa]=JSON.stringify(pe==null?void 0:pe[Sa]):na[Sa]=pe==null?void 0:pe[Sa];return na}),il=await A.quoteApi({platId:parseInt((_=gl==null?void 0:gl.value)==null?void 0:_.plat_id),type:"fatherSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});il=(x=il==null?void 0:il.data)==null?void 0:x.result,il=il==null?void 0:il.filter(pe=>{var na,Sa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Sa=(na=pe==null?void 0:pe.quote)==null?void 0:na[0])==null?void 0:Sa.menus)===(xl==null?void 0:xl.value))});let Aa=(w=ma==null?void 0:ma[0])==null?void 0:w.id,sl=[{tableName:(g=a==null?void 0:a.relatedContents)==null?void 0:g.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:ma}],rl=(E=il==null?void 0:il.map(pe=>{var Sa,la,nl,Je,Fa;let na=(Sa=pe==null?void 0:pe.contents)==null?void 0:Sa.filter(wa=>{var Oa,Me;return JSON.stringify(wa==null?void 0:wa.relatedId)!=="{}"&&(wa==null?void 0:wa.relatedId)!==""&&(wa!=null&&wa.relatedId)?(Oa=wa==null?void 0:wa.relatedId)==null?void 0:Oa.includes(parseInt(Aa)):(wa==null?void 0:wa.sort)===((Me=ma==null?void 0:ma[0])==null?void 0:Me.sort)});if((na==null?void 0:na.length)>0){let wa=ma==null?void 0:ma[0];wa={...wa,id:(la=na==null?void 0:na[0])==null?void 0:la.id};let Oa={},Me=wa,Ra;return Array.isArray((nl=pe==null?void 0:pe.struct)==null?void 0:nl[0])?Ra=oe.getColumnChild((Je=pe==null?void 0:pe.struct)==null?void 0:Je[0]):Ra=pe==null?void 0:pe.struct,Ra=Ra==null?void 0:Ra.filter(Va=>(Va==null?void 0:Va.prop)!=="relatedId"),Ra==null||Ra.forEach(Va=>{var Bl,We;Oa[Va.prop]=((Bl=Va==null?void 0:Va.words)!=null&&Bl[0]?(Me==null?void 0:Me[(We=Va==null?void 0:Va.words)==null?void 0:We[0]])??(Me==null?void 0:Me[Va==null?void 0:Va.prop]):Me==null?void 0:Me[Va==null?void 0:Va.prop])??""}),Oa.id=(Fa=na==null?void 0:na[0])==null?void 0:Fa.id,delete Oa.sort,delete Oa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Oa]}}else return}))==null?void 0:E.filter(pe=>pe);sl=[...sl,...rl];let qe=await A.quoteApi({platId:parseInt((P=gl==null?void 0:gl.value)==null?void 0:P.plat_id),type:"sonSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});qe=(ee=(V=qe==null?void 0:qe.data)==null?void 0:V.result)==null?void 0:ee.filter(pe=>!(sl!=null&&sl.find(na=>(na==null?void 0:na.tableName)==="content_"+(pe==null?void 0:pe.id)))),qe=qe==null?void 0:qe.filter(pe=>{var na,Sa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Sa=(na=pe==null?void 0:pe.quote)==null?void 0:na[0])==null?void 0:Sa.menus)===(xl==null?void 0:xl.value))});let Ga=(J=qe==null?void 0:qe.map(pe=>{var Sa,la,nl,Je,Fa;let na=(Sa=pe==null?void 0:pe.contents)==null?void 0:Sa.filter(wa=>{var Oa,Me,Ra;return JSON.stringify(wa==null?void 0:wa.relatedId)!=="{}"&&(wa==null?void 0:wa.relatedId)!==""&&(wa!=null&&wa.relatedId)?(Oa=wa==null?void 0:wa.relatedId)==null?void 0:Oa.includes(parseInt(Aa)):(wa==null?void 0:wa.sort)===((Me=ma==null?void 0:ma[0])==null?void 0:Me.sort)||(wa==null?void 0:wa.sort)===(parseInt(((Ra=ma==null?void 0:ma[0])==null?void 0:Ra.sort)??"0")+1).toString()});if((na==null?void 0:na.length)>0){let wa=ma==null?void 0:ma[0];wa={...wa,id:(la=na==null?void 0:na[0])==null?void 0:la.id};let Oa={},Me=wa,Ra;return Array.isArray((nl=pe==null?void 0:pe.struct)==null?void 0:nl[0])?Ra=oe.getColumnChild((Je=pe==null?void 0:pe.struct)==null?void 0:Je[0]):Ra=pe==null?void 0:pe.struct,Ra=Ra==null?void 0:Ra.filter(Va=>(Va==null?void 0:Va.prop)!=="relatedId"),Ra==null||Ra.forEach(Va=>{var Bl,We,Ma,Sl;((Bl=Va==null?void 0:Va.words)!=null&&Bl[0]?(Me==null?void 0:Me[(We=Va==null?void 0:Va.words)==null?void 0:We[0]])??(Me==null?void 0:Me[Va==null?void 0:Va.prop]):Me!=null&&Me[Va==null?void 0:Va.prop])&&(Oa[Va.prop]=((Ma=Va==null?void 0:Va.words)!=null&&Ma[0]?(Me==null?void 0:Me[(Sl=Va==null?void 0:Va.words)==null?void 0:Sl[0]])??(Me==null?void 0:Me[Va==null?void 0:Va.prop]):Me==null?void 0:Me[Va==null?void 0:Va.prop])??"")}),Oa.id=(Fa=na==null?void 0:na[0])==null?void 0:Fa.id,delete Oa.sort,delete Oa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Oa]}}else return}))==null?void 0:J.filter(pe=>pe);sl=[...sl,...Ga],await A.pageBatchUpdateApi({platId:parseInt((me=gl==null?void 0:gl.value)==null?void 0:me.plat_id),changeContents:sl});let hl=[];sl==null||sl.forEach(pe=>{var na;(na=pe==null?void 0:pe.tableContents)==null||na.forEach(Sa=>{hl.push({id:"1",request_method:"Post",request_url:"/platform/page/update",request_param:JSON.stringify(Sa),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"update"})})}),await A.pageBatchAddApi({platId:parseInt((_e=gl==null?void 0:gl.value)==null?void 0:_e.plat_id),changeContents:[{tableName:"log",tableContents:hl}]})}if((a==null?void 0:a.buttonName)==="删除"){let aa=[{tableName:(z=a==null?void 0:a.relatedContents)==null?void 0:z.find(qe=>qe==null?void 0:qe.includes("content")),tableContents:a==null?void 0:a.fixContent}],Ka=await A.quoteApi({platId:parseInt((ne=gl==null?void 0:gl.value)==null?void 0:ne.plat_id),type:"fatherSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});Ka=(Y=Ka==null?void 0:Ka.data)==null?void 0:Y.result,Ka=Ka==null?void 0:Ka.filter(qe=>{var Ga,hl;return!((qe==null?void 0:qe.fatherPath)!==""&&((hl=(Ga=qe==null?void 0:qe.quote)==null?void 0:Ga[0])==null?void 0:hl.menus)===(xl==null?void 0:xl.value))});let ma=(ye=(te=a==null?void 0:a.fixContent)==null?void 0:te[0])==null?void 0:ye.id,il=($e=Ka==null?void 0:Ka.map(qe=>{var hl,pe,na,Sa,la,nl;let Ga=(hl=qe==null?void 0:qe.contents)==null?void 0:hl.filter(Je=>{var Fa,wa,Oa;return JSON.stringify(Je==null?void 0:Je.relatedId)!=="{}"&&(Je==null?void 0:Je.relatedId)!==""&&(Je!=null&&Je.relatedId)?(Fa=Je==null?void 0:Je.relatedId)==null?void 0:Fa.includes(parseInt(ma)):(Je==null?void 0:Je.sort)===((Oa=(wa=a==null?void 0:a.fixContent)==null?void 0:wa[0])==null?void 0:Oa.sort)});if((Ga==null?void 0:Ga.length)>0){let Je=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];Je={...Je,id:(na=Ga==null?void 0:Ga[0])==null?void 0:na.id};let Fa={},wa=Je,Oa;return Array.isArray((Sa=qe==null?void 0:qe.struct)==null?void 0:Sa[0])?Oa=oe.getColumnChild((la=qe==null?void 0:qe.struct)==null?void 0:la[0]):Oa=qe==null?void 0:qe.struct,Oa=Oa==null?void 0:Oa.filter(Me=>(Me==null?void 0:Me.prop)!=="relatedId"),Oa==null||Oa.forEach(Me=>{var Ra,Va;Fa[Me.prop]=((Ra=Me==null?void 0:Me.words)!=null&&Ra[0]?(wa==null?void 0:wa[(Va=Me==null?void 0:Me.words)==null?void 0:Va[0]])??(wa==null?void 0:wa[Me==null?void 0:Me.prop]):wa==null?void 0:wa[Me==null?void 0:Me.prop])??""}),Fa.id=(nl=Ga==null?void 0:Ga[0])==null?void 0:nl.id,delete Fa.sort,delete Fa.relatedId,{tableName:"content_"+(qe==null?void 0:qe.id),tableContents:[Fa]}}else return}))==null?void 0:$e.filter(qe=>qe);aa=[...aa,...il];let Aa=await A.quoteApi({platId:parseInt((de=gl==null?void 0:gl.value)==null?void 0:de.plat_id),type:"sonSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});Aa=(ie=(T=Aa==null?void 0:Aa.data)==null?void 0:T.result)==null?void 0:ie.filter(qe=>!(aa!=null&&aa.find(Ga=>(Ga==null?void 0:Ga.tableName)==="content_"+(qe==null?void 0:qe.id)))),Aa=Aa==null?void 0:Aa.filter(qe=>{var Ga,hl;return!((qe==null?void 0:qe.fatherPath)!==""&&((hl=(Ga=qe==null?void 0:qe.quote)==null?void 0:Ga[0])==null?void 0:hl.menus)===(xl==null?void 0:xl.value))});let sl=(U=Aa==null?void 0:Aa.map(qe=>{var hl,pe,na,Sa,la,nl;let Ga=(hl=qe==null?void 0:qe.contents)==null?void 0:hl.filter(Je=>{var Fa,wa,Oa;return JSON.stringify(Je==null?void 0:Je.relatedId)!=="{}"&&(Je==null?void 0:Je.relatedId)!==""&&(Je!=null&&Je.relatedId)?(Fa=Je==null?void 0:Je.relatedId)==null?void 0:Fa.includes(parseInt(ma)):(Je==null?void 0:Je.sort)===((Oa=(wa=a==null?void 0:a.fixContent)==null?void 0:wa[0])==null?void 0:Oa.sort)});if((Ga==null?void 0:Ga.length)>0){let Je=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];Je={...Je,id:(na=Ga==null?void 0:Ga[0])==null?void 0:na.id};let Fa={},wa=Je,Oa;return Array.isArray((Sa=qe==null?void 0:qe.struct)==null?void 0:Sa[0])?Oa=oe.getColumnChild((la=qe==null?void 0:qe.struct)==null?void 0:la[0]):Oa=qe==null?void 0:qe.struct,Oa=Oa==null?void 0:Oa.filter(Me=>(Me==null?void 0:Me.prop)!=="relatedId"),Oa==null||Oa.forEach(Me=>{var Ra,Va;Fa[Me.prop]=((Ra=Me==null?void 0:Me.words)!=null&&Ra[0]?(wa==null?void 0:wa[(Va=Me==null?void 0:Me.words)==null?void 0:Va[0]])??(wa==null?void 0:wa[Me==null?void 0:Me.prop]):wa==null?void 0:wa[Me==null?void 0:Me.prop])??""}),Fa.id=(nl=Ga==null?void 0:Ga[0])==null?void 0:nl.id,delete Fa.sort,delete Fa.relatedId,{tableName:"content_"+(qe==null?void 0:qe.id),tableContents:[Fa]}}else return}))==null?void 0:U.filter(qe=>qe);aa=[...aa,...sl],await A.pageBatchDeleteApi({platId:parseInt((ge=gl==null?void 0:gl.value)==null?void 0:ge.plat_id),changeContents:aa});let rl=[];aa==null||aa.forEach(qe=>{var Ga;(Ga=qe==null?void 0:qe.tableContents)==null||Ga.forEach(hl=>{rl.push({id:"1",request_method:"Post",request_url:"/platform/page/delete",request_param:JSON.stringify(hl),request_result:"{}",is_delete:!1,request_table:qe==null?void 0:qe.tableName,request_type:"delete"})})}),await A.pageBatchAddApi({platId:parseInt((ze=gl==null?void 0:gl.value)==null?void 0:ze.plat_id),changeContents:[{tableName:"log",tableContents:rl}]})}if((a==null?void 0:a.buttonName)==="复制新增"){let aa=await A.getPageDataApi({platId:parseInt((Le=gl==null?void 0:gl.value)==null?void 0:Le.plat_id),pageName:"menu"});if(aa=(ra=aa==null?void 0:aa.data)==null?void 0:ra.result,aa!=null&&aa.find(Ka=>(Ka==null?void 0:Ka.father_name)===xl.value+"/")){Sc.value=a,_c.value=aa==null?void 0:aa.filter(il=>(il==null?void 0:il.father_name)===xl.value+"/");let Ka=(Q=(Ca=a==null?void 0:a.columns)==null?void 0:Ca.find(il=>il==null?void 0:il.mainKey))==null?void 0:Q.prop,ma=(ue=(ca=a==null?void 0:a.fixContent)==null?void 0:ca[0])==null?void 0:ue[Ka];Mt.value=!0,Xi.value=[{prop:Ka,label:Ka,name:Ka,value:ma}]}else{let Ka=(pa=a==null?void 0:a.fixContent)==null?void 0:pa.map(Aa=>{let sl={};for(let rl in Aa)Array.isArray(Aa==null?void 0:Aa[rl])?sl[rl]=JSON.stringify(Aa==null?void 0:Aa[rl]):sl[rl]=Aa==null?void 0:Aa[rl];return sl.relatedId="",sl}),ma=[{tableName:(Se=a==null?void 0:a.relatedContents)==null?void 0:Se.find(Aa=>Aa==null?void 0:Aa.includes("content")),tableContents:Ka}];await A.pageBatchAddApi({platId:parseInt((ce=gl==null?void 0:gl.value)==null?void 0:ce.plat_id),changeContents:ma});let il=[];ma==null||ma.forEach(Aa=>{var sl;(sl=Aa==null?void 0:Aa.tableContents)==null||sl.forEach(rl=>{il.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(rl),request_result:"{}",is_delete:!1,request_table:Aa==null?void 0:Aa.tableName,request_type:"copyAdd"})})}),await A.pageBatchAddApi({platId:parseInt((De=gl==null?void 0:gl.value)==null?void 0:De.plat_id),changeContents:[{tableName:"log",tableContents:il}]})}}if((a==null?void 0:a.buttonName)==="methodButton"){let aa=((Za=(ua=(Ke=a==null?void 0:a.columns)==null?void 0:Ke.map(pe=>pe==null?void 0:pe.filter))==null?void 0:ua.filter(pe=>pe!==""))==null?void 0:Za[0])??"";aa=oe.analyzeSplitToContent(aa,","),aa=(aa==null?void 0:aa.find(pe=>pe==null?void 0:pe.includes("@Filter")))??"";let Ka=($=a==null?void 0:a.fixContent)==null?void 0:$.map(pe=>{let na={};for(let Sa in pe)Array.isArray(pe==null?void 0:pe[Sa])?na[Sa]=JSON.stringify(pe==null?void 0:pe[Sa]):na[Sa]=pe==null?void 0:pe[Sa];return na}),ma=await A.quoteApi({platId:parseInt((H=gl==null?void 0:gl.value)==null?void 0:H.plat_id),type:"fatherSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});ma=(X=ma==null?void 0:ma.data)==null?void 0:X.result,ma=ma==null?void 0:ma.filter(pe=>{var na,Sa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Sa=(na=pe==null?void 0:pe.quote)==null?void 0:na[0])==null?void 0:Sa.menus)===(xl==null?void 0:xl.value))});let il=(fe=(he=a==null?void 0:a.columns)==null?void 0:he[0])==null?void 0:fe.prop,Aa=(ha=Ka==null?void 0:Ka[0])==null?void 0:ha[il],sl=[{tableName:(ta=a==null?void 0:a.relatedContents)==null?void 0:ta.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:Ka}],rl=(Fe=ma==null?void 0:ma.map(pe=>{var Sa,la,nl,Je,Fa;let na=(Sa=pe==null?void 0:pe.contents)==null?void 0:Sa.filter(wa=>{var Oa;return(Oa=Object.values(wa))==null?void 0:Oa.find(Me=>Me===Aa)});if((na==null?void 0:na.length)>0){let wa=Ka==null?void 0:Ka[0];wa={...wa,id:(la=na==null?void 0:na[0])==null?void 0:la.id};let Oa={},Me=wa,Ra;return Array.isArray((nl=pe==null?void 0:pe.struct)==null?void 0:nl[0])?Ra=oe.getColumnChild((Je=pe==null?void 0:pe.struct)==null?void 0:Je[0]):Ra=pe==null?void 0:pe.struct,Ra=Ra==null?void 0:Ra.filter(Va=>(Va==null?void 0:Va.prop)!=="relatedId"),Ra==null||Ra.forEach(Va=>{var Bl,We;Oa[Va.prop]=((Bl=Va==null?void 0:Va.words)!=null&&Bl[0]?(Me==null?void 0:Me[(We=Va==null?void 0:Va.words)==null?void 0:We[0]])??(Me==null?void 0:Me[Va==null?void 0:Va.prop]):Me==null?void 0:Me[Va==null?void 0:Va.prop])??""}),Oa.id=(Fa=na==null?void 0:na[0])==null?void 0:Fa.id,delete Oa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Oa]}}else return}))==null?void 0:Fe.filter(pe=>pe);sl=[...sl,...rl];let qe=await A.quoteApi({platId:parseInt((xa=gl==null?void 0:gl.value)==null?void 0:xa.plat_id),type:"sonSyncs",related:[{menus:r!==""?xl.value+"/"+r:xl.value,groups:a==null?void 0:a.name}]});if(qe=(va=(Ae=qe==null?void 0:qe.data)==null?void 0:Ae.result)==null?void 0:va.filter(pe=>!(sl!=null&&sl.find(na=>(na==null?void 0:na.tableName)==="content_"+(pe==null?void 0:pe.id)))),qe=qe==null?void 0:qe.filter(pe=>{var na,Sa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Sa=(na=pe==null?void 0:pe.quote)==null?void 0:na[0])==null?void 0:Sa.menus)===(xl==null?void 0:xl.value))}),aa&&aa!==""){(aa==null?void 0:aa[(aa==null?void 0:aa.length)-1])===","&&(aa=aa==null?void 0:aa.slice(0,(aa==null?void 0:aa.length)-1)),aa=(Ia=(La=aa==null?void 0:aa.replace("(",xo))==null?void 0:La.split(xo))==null?void 0:Ia[1],aa=aa==null?void 0:aa.slice(0,(aa==null?void 0:aa.length)-1),(aa==null?void 0:aa[0])==="*"&&(aa="{"+((Ba=(fa=aa==null?void 0:aa.replace("{",xo))==null?void 0:fa.split(xo))==null?void 0:Ba[1])),aa=(Te=aa==null?void 0:aa.replaceAll("{",""))==null?void 0:Te.replaceAll("}","");let pe=oe.calculatorAndToOr(aa);pe=pe==null?void 0:pe[0];let na;if((be=Object.values(pe))!=null&&be.some(Sa=>(Sa==null?void 0:Sa[0])==="*")){let Sa=(ae=(Be=Wn.value)==null?void 0:Be.find(la=>(la==null?void 0:la.condition)==="child"))!=null&&ae.value?(hn==null?void 0:hn.value)+"/"+((Xe=(se=Wn.value)==null?void 0:se.find(la=>(la==null?void 0:la.condition)==="child"))==null?void 0:Xe.value):hn==null?void 0:hn.value;na=await Jr(Sa,!1)}for(let Sa in pe)if(((Ze=pe==null?void 0:pe[Sa])==null?void 0:Ze[0])==="*"){let la=(Pe=(Qa=(_a=pe[Sa])==null?void 0:_a.slice(1,(Ha=pe[Sa])==null?void 0:Ha.length))==null?void 0:Qa.split(":"))==null?void 0:Pe[0],nl=(Ue=(Re=pe[Sa])==null?void 0:Re.split(":"))==null?void 0:Ue[1],Je=(Ne=na==null?void 0:na.filter(Fa=>(Fa==null?void 0:Fa.name)===la))==null?void 0:Ne[0];Je=(ul=(Ie=Je==null?void 0:Je.compData)==null?void 0:Ie.find(Fa=>(Fa==null?void 0:Fa.key)==="tableContents"))==null?void 0:ul.contents,Je=(_l=Je==null?void 0:Je[0])==null?void 0:_l[nl],pe[Sa]=Je}aa=((Tl=Object.values(pe))==null?void 0:Tl[0])??""}let Ga=(jl=qe==null?void 0:qe.map(pe=>{var Sa,la,nl,Je,Fa;let na=(Sa=pe==null?void 0:pe.contents)==null?void 0:Sa.filter(wa=>{var Oa;return(Oa=Object.values(wa))==null?void 0:Oa.find(Me=>Me===(aa===""?Aa:aa))});if((na==null?void 0:na.length)>0){let wa=Ka==null?void 0:Ka[0];wa={...wa,id:(la=na==null?void 0:na[0])==null?void 0:la.id};let Oa={},Me=wa,Ra;return Array.isArray((nl=pe==null?void 0:pe.struct)==null?void 0:nl[0])?Ra=oe.getColumnChild((Je=pe==null?void 0:pe.struct)==null?void 0:Je[0]):Ra=pe==null?void 0:pe.struct,Ra=Ra==null?void 0:Ra.filter(Va=>(Va==null?void 0:Va.prop)!=="relatedId"),Ra==null||Ra.forEach(Va=>{var We,Ma,Sl,pr;let Bl=(We=a==null?void 0:a.columns)==null?void 0:We.find(ga=>{var Zl,Sr,Cr;return((Sr=(Zl=ga==null?void 0:ga.words)==null?void 0:Zl[0])==null?void 0:Sr.replaceAll("'",""))===(Va==null?void 0:Va.prop)&&((Cr=ga==null?void 0:ga.functionRelatedWords)==null?void 0:Cr.length)>0});Bl=(Ma=Bl==null?void 0:Bl.prop)==null?void 0:Ma.replaceAll("'",""),Oa[Va.prop]=((Sl=Va==null?void 0:Va.words)!=null&&Sl[0]?(Me==null?void 0:Me[(pr=Va==null?void 0:Va.words)==null?void 0:pr[0]])??(Me==null?void 0:Me[Va==null?void 0:Va.prop])??(Me==null?void 0:Me[Bl]):(Me==null?void 0:Me[Va==null?void 0:Va.prop])??(Me==null?void 0:Me[Bl]))??void 0}),Oa.id=(Fa=na==null?void 0:na[0])==null?void 0:Fa.id,delete Oa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Oa]}}else return}))==null?void 0:jl.filter(pe=>pe);sl=[...sl,...Ga],await A.pageBatchUpdateApi({platId:parseInt((Cl=gl==null?void 0:gl.value)==null?void 0:Cl.plat_id),changeContents:sl});let hl=[];sl==null||sl.forEach(pe=>{var na;(na=pe==null?void 0:pe.tableContents)==null||na.forEach(Sa=>{hl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Sa),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"method"})})}),await A.pageBatchAddApi({platId:parseInt((Yl=gl==null?void 0:gl.value)==null?void 0:Yl.plat_id),changeContents:[{tableName:"log",tableContents:hl}]})}Or.setRefreshCurStructure(!0),Or.setRefreshCurrentPageInform(E0.value++),await Tt(a)},Dt=async(a,l,n)=>{var i;let r=a==null?void 0:a.find(s=>(s==null?void 0:s.id)===l);if(r){let s=(i=r.compData)==null?void 0:i.map(h=>{var c;if((h==null?void 0:h.key)==="tableContents"){let d={...h,contents:n};return d.contents=(c=(d==null?void 0:d.contents)??[])==null?void 0:c.map(m=>{let b={};for(let u in m)JSON.stringify(m==null?void 0:m[u])==="{}"?b[u]="":b[u]=m==null?void 0:m[u];return b}),d}return h});return r.compData=await Po(s,{}),a=a==null?void 0:a.map(h=>((h==null?void 0:h.id)===(r==null?void 0:r.id)&&(h=r),h)),a}else{let s=a==null?void 0:a.filter(c=>{var d;return(c==null?void 0:c.children)&&((d=c==null?void 0:c.children)==null?void 0:d.length)>0||(c==null?void 0:c.comp)==="Tabs"}),h=s==null?void 0:s.map(async c=>{var d;return c!=null&&c.children&&((d=c==null?void 0:c.children)==null?void 0:d.length)>0?c.children=await Dt(c==null?void 0:c.children,l,n):c.compData=await Dt(c==null?void 0:c.compData,l,n),c});return s=await Promise.all(h),s}},Tt=async a=>{var s,h,c,d,m,b,u;let l=(s=a==null?void 0:a.relatedContents)==null?void 0:s.filter(C=>C==null?void 0:C.includes("content_"));if(!l)return;let n=await A.getAllTables({platId:parseInt((h=gl==null?void 0:gl.value)==null?void 0:h.plat_id),tableNames:l??[]});if(n=(d=(c=n==null?void 0:n.data)==null?void 0:c.result)==null?void 0:d[0],!n||!Array.isArray(n))return;n=n==null?void 0:n.map(C=>{C==null||delete C.source_table;const M={};for(let k in C){const W=C==null?void 0:C[k],O=W&&Object.prototype.toString.call(W)==="[object Object]"&&Object.keys(W).length===0,j=Array.isArray(W)&&W.length===0;W==null||W==="{}"||O||j?M[k]="":M[k]=W}return M});let r=(b=(m=l==null?void 0:l[0])==null?void 0:m.split("_"))==null?void 0:b[1],i=await Dt(dr.value,r,n);dr.value=(u=dr.value)==null?void 0:u.map(C=>{var M,k;return(M=i==null?void 0:i[0])!=null&&M.tabInform&&((k=i==null?void 0:i[0])==null?void 0:k.tabInform)===(C==null?void 0:C.tabInform)?C=i==null?void 0:i[0]:(C!=null&&C.name?(C==null?void 0:C.name)===(i==null?void 0:i.name):(C==null?void 0:C.id)===(i==null?void 0:i.id))&&(C=i),C})},R0=a=>{let l=Xi.value;Xi.value=l==null?void 0:l.map(n=>(n.value=a==null?void 0:a[n==null?void 0:n.prop],n))},$0=async()=>{var C,M,k,W,O,j,L,_,x,w;let a=Sc.value,l=_c.value,n=(M=(C=a==null?void 0:a.columns)==null?void 0:C.find(g=>g==null?void 0:g.mainKey))==null?void 0:M.prop,r=(W=(k=Xi.value)==null?void 0:k[0])==null?void 0:W.value,i=(O=a==null?void 0:a.fixContent)==null?void 0:O.map(g=>{var P;let E={};for(let V in g)Array.isArray(g==null?void 0:g[V])?E[V]=JSON.stringify(g==null?void 0:g[V]):E[V]=g==null?void 0:g[V];return(P=a==null?void 0:a.columns)==null||P.forEach(V=>{(V==null?void 0:V.formType)==="Upload"&&(E==null?void 0:E[V==null?void 0:V.prop])===""&&(E[V==null?void 0:V.prop]="{}")}),E[n]=r,E}),s=[{tableName:(j=a==null?void 0:a.relatedContents)==null?void 0:j.find(g=>g==null?void 0:g.includes("content")),tableContents:i}];await A.pageBatchAddApi({platId:parseInt((L=gl==null?void 0:gl.value)==null?void 0:L.plat_id),changeContents:s}),l=l==null?void 0:l.filter(g=>{var E,P,V;return(V=g==null?void 0:g.object_name)==null?void 0:V.includes((P=(E=a==null?void 0:a.fixContent)==null?void 0:E[0])==null?void 0:P[n])});let h=[],c=new Map;l==null||l.forEach(g=>{h.push(`content_${g==null?void 0:g.object_id}`),h.push(`struct_${g==null?void 0:g.object_id}`),c.set(g==null?void 0:g.object_id,g)});let d=await A.getAllTables({platId:parseInt((_=gl==null?void 0:gl.value)==null?void 0:_.plat_id),tableNames:h??[]});d=(x=d==null?void 0:d.data)==null?void 0:x.result;let m=[],b=[];d=oe.chunk(d,2),d==null||d.forEach(g=>{var V,ee,J,me,_e,z,ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca,Q;let E=c.get((me=(J=(ee=(V=g==null?void 0:g[1])==null?void 0:V[0])==null?void 0:ee.source_table)==null?void 0:J.split("_"))==null?void 0:me[1]),P=(ne=(z=(_e=E==null?void 0:E.object_name)==null?void 0:_e.split("/"))==null?void 0:z.filter((ca,ue)=>{var pa,Se;return((Se=(pa=E==null?void 0:E.object_name)==null?void 0:pa.split("/"))==null?void 0:Se.length)-1!==ue}))==null?void 0:ne.join("/");if(P=P+"/"+r,b!=null&&b.find(ca=>(ca==null?void 0:ca.path)===P)||b.push({fatherPath:E==null?void 0:E.father_name,isShow:E==null?void 0:E.is_show,path:P}),((te=(Y=g==null?void 0:g[1])==null?void 0:Y[0])==null?void 0:te.类型)==="Table"){let ca=((de=($e=(ye=g==null?void 0:g[1])==null?void 0:ye[0])==null?void 0:$e.结构)==null?void 0:de.contents)??[],ue=cl.safeClone(ca);Array.isArray(ue==null?void 0:ue[0])&&(ue=oe.getColumnChild(ue==null?void 0:ue[0]));let pa=[];if(((T=g==null?void 0:g[0])==null?void 0:T.length)>0&&(pa=(ie=g==null?void 0:g[0])==null?void 0:ie.map(Se=>ue==null?void 0:ue.map(De=>(De=(Se==null?void 0:Se[De==null?void 0:De.prop])??"",De)))),m!=null&&m.find(Se=>(Se==null?void 0:Se.key)===P)){let Se=(U=m==null?void 0:m.find(De=>(De==null?void 0:De.key)===P))==null?void 0:U.contents;Se.push({isShow:E==null?void 0:E.is_show,filter:((Le=(ze=(ge=g==null?void 0:g[1])==null?void 0:ge[0])==null?void 0:ze.引用)==null?void 0:Le.contents)??"",key:"Table",name:Object.values(E==null?void 0:E.name),tableColumns:ca,tableContents:pa});let ce=m==null?void 0:m.findIndex(De=>(De==null?void 0:De.key)===P);m[ce].contents=Se}else m.push({key:P,contents:[{isShow:E==null?void 0:E.is_show,filter:((Q=(Ca=(ra=g==null?void 0:g[1])==null?void 0:ra[0])==null?void 0:Ca.引用)==null?void 0:Q.contents)??"",key:"Table",name:Object.values(E==null?void 0:E.name),tableColumns:ca,tableContents:pa}]})}});let u=[];u.push({key:"menuPath",contents:b}),u=[...u,...m],await A.createPlatFormDataApi({platId:parseInt((w=gl==null?void 0:gl.value)==null?void 0:w.plat_id),changeData:u}),Mt.value=!1,Or.setRefreshTable(!0)},Oo=async(a,l)=>{},Lo=async a=>{dr.value=await oe.getDeepDiffItems(a),Or.setItemData(dr.value),Or.setOriginalData(dr.value)};e.ref();const V0=e.ref(null),P0=()=>{var a,l;console.log("倒计时结束时"),A.ElMessageBox.alert(`超时未提交,【${(l=(a=xl.value)==null?void 0:a.split("/"))==null?void 0:l[0]}】失败`,"告警",{confirmButtonText:"确认",type:"error"})},Tc=e.ref([]),F0=e.computed(()=>{var a,l;return(l=(a=Et.value)==null?void 0:a[xl.value])==null?void 0:l.filter(n=>{var r;return((r=n==null?void 0:n.key)==null?void 0:r.type)==="gridLayout"})});e.watch(()=>[D0.value],()=>{wn.setSelectTitle([]),wn.setChooseTitle([])},{deep:!0});e.watch(()=>Mo.value,async(a,l)=>{var r,i,s,h,c,d;let n=(r=Mo.value)==null?void 0:r.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==hn.value);if((n==null?void 0:n.length)>0){Hr.setContentLoading(!0);let m=((i=n==null?void 0:n[0])==null?void 0:i.relatedContent)??(xl==null?void 0:xl.value),b=m+"/"+((s=n==null?void 0:n[0])==null?void 0:s.value),u=!!((h=n==null?void 0:n[0])!=null&&h.parentContent),C=await Jr(b,u,{originPath:m});C=(c=C==null?void 0:C.filter(W=>W))==null?void 0:c.map(W=>(W.isShow=!0,W)),console.log(C,"loadingContents");let M=await oe.getDeepDiffItems(C),k=M==null?void 0:M.filter(W=>W==null?void 0:W.choice);Fo.setSelectTab((d=k==null?void 0:k[0])==null?void 0:d.choiceName),M=M==null?void 0:M.filter(W=>{var O;return!(W!=null&&W.choiceName)||(W==null?void 0:W.choiceName)===((O=k==null?void 0:k[0])==null?void 0:O.choiceName)}),dr.value=M,Hr.setContentLoading(!1)}});const j0=(a,l)=>{setTimeout(async()=>{var c,d,m;let n=(c=Mo.value)==null?void 0:c.filter(b=>(b==null?void 0:b.condition)==="child"&&(b==null?void 0:b.value)!==""&&(b==null?void 0:b.parentContent)!==hn.value),r=xl==null?void 0:xl.value,i=xl==null?void 0:xl.value;(n==null?void 0:n.length)>0&&(i=((d=n==null?void 0:n[0])==null?void 0:d.relatedContent)??(xl==null?void 0:xl.value),r=i+"/"+((m=n==null?void 0:n[0])==null?void 0:m.value));let s=await Jr(r,!1,{originPath:i});s=s==null?void 0:s.map(b=>(b.isShow=!0,b));let h=await oe.getDeepDiffItems(s);dr.value=h==null?void 0:h.filter(b=>!(b!=null&&b.step)||(b==null?void 0:b.step)===(a==null?void 0:a.title))},10)},H0=a=>{setTimeout(async()=>{var h,c,d;let l=(h=Mo.value)==null?void 0:h.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==hn.value),n=xl==null?void 0:xl.value,r=xl==null?void 0:xl.value;(l==null?void 0:l.length)>0&&(r=((c=l==null?void 0:l[0])==null?void 0:c.relatedContent)??(xl==null?void 0:xl.value),n=r+"/"+((d=l==null?void 0:l[0])==null?void 0:d.value));let i=await Jr(n,!1,{originPath:r});i=i==null?void 0:i.map(m=>(m.isShow=!0,m)),Fo.setSelectTab(a);let s=await oe.getDeepDiffItems(i);dr.value=s==null?void 0:s.filter(m=>!(m!=null&&m.choiceName)||(m==null?void 0:m.choiceName)===a)},10)};e.watch(()=>C0.value,a=>{a!=null&&a.length||(dr.value=[])},{immediate:!0});e.watch(()=>[xl.value],async a=>{var s,h,c,d;if(!xl.value)return;if(xl.value==="/"){dr.value=[];return}Hr.setCurrentMenuPath(xl.value),Or.setLockingPage(""),dr.value=[];let l=e.getCurrentInstance();(s=l==null?void 0:l.scope)==null||s.stop(),l=null,Ai.value=!1,Hr.setContentLoading(!0),wc.value=!0;let n=a==null?void 0:a[0],r=n,i=(h=Wn.value)==null?void 0:h.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==xl.value&&!(m!=null&&m.relatedContent));if((i==null?void 0:i.length)>0&&(n=n+"/"+((c=i==null?void 0:i[0])==null?void 0:c.value)),n==="系统管理/日志管理")dr.value=await k0("log");else{let m=await Jr(n,!0,{originPath:r});m=m==null?void 0:m.map(C=>(C.isShow=!0,C));let b=await oe.getDeepDiffItems(m),u=b==null?void 0:b.filter(C=>C==null?void 0:C.choice);Fo.setSelectTab((d=u==null?void 0:u[0])==null?void 0:d.choiceName),dr.value=b==null?void 0:b.filter(C=>{var M;return!(C!=null&&C.choiceName)||(C==null?void 0:C.choiceName)===((M=u==null?void 0:u[0])==null?void 0:M.choiceName)})}Hr.setContentLoading(!1),Or.setExtraContents([]),wn.setSelectIndex(""),wn.setSelectMenu(""),Or.setItemData(dr.value),Or.setOriginalData(dr.value),Or.setRefreshTable(!1),e.nextTick(()=>{Gn.value=Gn.value++,Ai.value=!0})},{immediate:!0});e.watch(()=>[_s.value],async()=>{var a,l,n,r;if(_s.value){dr.value=[];let i=e.getCurrentInstance();(a=i==null?void 0:i.scope)==null||a.stop(),i=null,Ai.value=!1,Hr.setContentLoading(!0),wc.value=!0;let s=hn==null?void 0:hn.value,h=s,c=(l=Wn.value)==null?void 0:l.filter(u=>(u==null?void 0:u.condition)==="child"&&(u==null?void 0:u.value)!==""&&(u==null?void 0:u.parentContent)!==(hn==null?void 0:hn.value));(c==null?void 0:c.length)>0&&(s=s+"/"+((n=c==null?void 0:c[0])==null?void 0:n.value));let d=await Jr(s,!0,{originPath:h});d=d==null?void 0:d.map(u=>(u.isShow=!0,u));let m=await oe.getDeepDiffItems(d),b=m==null?void 0:m.filter(u=>u==null?void 0:u.choice);if(Fo.setSelectTab((r=b==null?void 0:b[0])==null?void 0:r.choiceName),dr.value=m==null?void 0:m.filter(u=>{var C;return!(u!=null&&u.choiceName)||(u==null?void 0:u.choiceName)===((C=b==null?void 0:b[0])==null?void 0:C.choiceName)}),Hr.setContentLoading(!1),Or.setExtraContents([]),wn.setSelectIndex(""),wn.setSelectMenu(""),Or.setItemData(dr.value),Or.setOriginalData(dr.value),Or.setRefreshTable(!1),(c==null?void 0:c.length)>0){let u=[...Wn.value,...c];wn.setSelectTitle(u)}e.nextTick(()=>{Gn.value=Gn.value++,Ai.value=!0})}},{immediate:!0,deep:!0});const U0=async()=>{Hr.setLinkMenuInfo(null),Hr.setActiveMenuPath(S0.value),dr.value=null,Or.setRouteToChildPath(""),Hr.setChildMenu("")},q0=a=>new RegExp("button","i").test(a),W0=a=>/^[\u4e00-\u9fa5]+\/[\u4e00-\u9fa5]+\^(.+)$/.test(a),Bc=a=>{if(W0(a)){const l=a==null?void 0:a.split("^");(l==null?void 0:l.length)>0&&(l!=null&&l[0])&&Hr.setLinkMenuInfo({path:l==null?void 0:l[0],data:l==null?void 0:l[1]})}},Nc=async(a,l,n)=>{var C,M,k,W,O,j,L,_,x,w,g,E;let r="",i="";for(let P in l)(l==null?void 0:l[P])===a&&(i=P);n==null||n.forEach(P=>{(P==null?void 0:P.prop)===i&&(r=P==null?void 0:P.fatherPath)});let s=r===""?xl.value:r;r!==""&&Hr.setCurrentMenuPath(s),Hr.setCurrentMenuPath(s+"/"+a),Hr.setContentLoading(!0),dr.value=await Jr(s+"/"+a,!0,{originPath:s+"/",row:l});let h=await Jr(s,!1),c=(C=h==null?void 0:h.filter(P=>(P==null?void 0:P.comp)==="Table"))==null?void 0:C[0],d=((O=(W=(k=(M=c==null?void 0:c.compData)==null?void 0:M.find(P=>(P==null?void 0:P.key)==="header"))==null?void 0:k.contents)==null?void 0:W[0])==null?void 0:O.prop)??((w=(x=(_=(L=(j=c==null?void 0:c.compData)==null?void 0:j.find(P=>(P==null?void 0:P.key)==="header"))==null?void 0:L.contents)==null?void 0:_[0])==null?void 0:x[0])==null?void 0:w.prop),m=(E=(g=c==null?void 0:c.compData)==null?void 0:g.find(P=>(P==null?void 0:P.key)==="tableContents"))==null?void 0:E.contents;m=m==null?void 0:m.map(P=>({label:P==null?void 0:P[d],value:P==null?void 0:P[d]}));let b=Wn.value,u={value:a,condition:"child",options:m,relatedContent:s,isShow:!0};b=b==null?void 0:b.filter(P=>(P==null?void 0:P.condition)!=="child"),b.push(u),wn.setSelectTitle(b),wn.setChooseTitle([u]),Hr.setContentLoading(!1),Or.setExtraContents([]),wn.setSelectIndex(""),wn.setSelectMenu(""),Or.setItemData(dr.value),Or.setOriginalData(dr.value)},K0=a=>{Cc.value=a},Di=e.reactive({index:0,comp:null}),G0=e.computed(()=>{var a;return(a=dr.value)==null?void 0:a.map((l,n)=>({id:l.id,name:l.name,status:Y0(l,n)}))}),Ac=(a,l)=>{var d,m,b,u,C;const n=l?a:a-2,r=(d=dr.value)==null?void 0:d[n],i=(b=(m=r==null?void 0:r.compData)==null?void 0:m.find(M=>(M==null?void 0:M.key)==="header"))==null?void 0:b.contents,s=i==null?void 0:i.findIndex(M=>(M==null?void 0:M.isMainKey)&&(M==null?void 0:M.label)!=="操作"),h=s===-1?0:s,c=(C=(u=r==null?void 0:r.compData)==null?void 0:u.find(M=>(M==null?void 0:M.key)==="tableContents"))==null?void 0:C.contents;return{valid:c==null?void 0:c.every(M=>M==null?void 0:M[h+1]),length:(c==null?void 0:c.length)||0}},Y0=(a,l)=>{var r;let n="process";if(((r=a==null?void 0:a.comp)==null?void 0:r.toUpperCase())==="TABLE"){const{valid:i,length:s}=Ac(l,!0);Di.index===l?n="process":s===0?n="wait":n=i?"success":"error"}return n},zc=a=>{var n,r,i,s,h;const l=a+1;if(l>1&&((i=(r=(n=dr.value)==null?void 0:n[a])==null?void 0:r.comp)==null?void 0:i.toUpperCase())==="TABLE"){const{valid:c}=Ac(l);c?(Di.index=l,Di.comp=(s=dr.value)==null?void 0:s[a]):Wa.ElMessage({showClose:!0,type:"warning",message:"当前流程有输入未完成"})}else Di.index=l,Di.comp=(h=dr.value)==null?void 0:h[a]},Mc=e.computed(()=>{var a,l;return(l=(a=Ec.value)==null?void 0:a[0])==null?void 0:l.isStepLayout});e.watch(()=>Mc.value,a=>{a&&zc(0)},{immediate:!0});const J0={class:"table-content"},X0={class:"menu-config-wrap"},Z0=["onClick"],Q0={key:0,class:"viewport-wrap"},e3=["onClick"],a3={title:"选择显示列信息"},l3={key:0,class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},r3=["title"],n3={class:"col-operate-wrap"},i3={key:0,class:"col-operate-radio-wrapper"},o3={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},t3={key:0,style:{display:"flex","justify-content":"center","align-items":"center"}},s3={class:"pop-view"},c3={class:"pop-wrapper"},u3={class:"file-list-pop"},d3=["title","onClick"],p3=["onClick"],f3=["onClick"],h3={key:1,style:{display:"flex","justify-content":"flex-end",gap:"8px","margin-top":"8px"}},v3={class:"form-content"},m3={key:0,class:"dialog-footer"},y3={class:"dialog-footer"},g3={class:"ocr-dialog-content"},b3={class:"ocr-steps"},k3={key:0,class:"ocr-action-buttons"},x3={key:1,class:"ocr-preview-area"},w3={class:"ocr-file-grid"},_3={class:"file-thumbnail"},S3=["src"],E3={key:1,class:"thumbnail-placeholder"},C3={class:"progress-svg",viewBox:"0 0 36 36"},D3=["stroke","stroke-width","stroke-dasharray"],T3={key:0,class:"progress-icon"},B3={key:1,class:"progress-icon"},N3=["onClick"],A3={class:"file-name"},z3={key:0,class:"ocr-recognize-button"},M3={key:2,class:"ocr-progress-section"},I3={key:3,class:"ocr-confirm-area"},O3={class:"ocr-preview-tip"},L3={class:"ocr-preview-table"},R3={style:{display:"flex","align-items":"center",gap:"8px"}},$3={key:0},V3={key:4,class:"ocr-success-area"},P3={key:0,class:"ocr-dialog-footer"},F3={class:"form-content"},j3={style:{width:"100%",margin:"0","font-size":"14px","font-weight":"600"}},H3={style:{display:"flex","justify-content":"space-between",gap:"8px"}},U3={style:{display:"flex"}},Es="ss-ocr-upload-history",q3="ss-ocr-cert-history-v1",W3={__name:"index",props:{pageLayout:{type:String,default:"vertical"},related:{type:Array,default:[]},level:{type:Number,default:1},compName:{type:String,default:"",required:!1},compNames:{type:Array,default:()=>[],required:!1},groupNames:{type:Array,default:()=>[],required:!1},compItem:{type:Object,default:()=>{}},operatingForm:{type:Object,default:()=>{}},cacheNewData:{type:Object,default:()=>{}},config:Object,parentTableId:{type:Number,default:0},itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,isDevMode:Boolean,changedContent:{type:Object,default:()=>{}},showHeader:{type:Boolean,default:!0},allowSelect:{type:Boolean,default:!0},allowOperate:{type:Boolean,default:!0},allMapContents:{type:Object,default:()=>{}}},emits:["getSliceContLength","clickMainKey","change","contentChange","onButtonClick","contentClick","pageChange","rowClick","routeUrl"],setup(a,{emit:l}){var qt;const n=e.ref([]),r=zt(A.pinia),i=e.ref(null),s=e.ref(new Set),h=e.ref(new Map),c=e.ref(!1),d=e.ref(new Map),m=new Map,b=e.ref(new Map),u=a,C=e.ref((u==null?void 0:u.allowSelect)??!0),M=e.ref(((qt=u==null?void 0:u.config)==null?void 0:qt.showIndex)??!0),k=e.ref(),W=e.ref(!0),O=e.ref(!1),j=e.ref([]),L={sortable:"switch",filterable:"switch",showSummary:"switch",operable:"switch",fixed:"radio"},_=e.ref([{label:"排序",value:"sortable",checked:!1},{label:"合计",value:"showSummary",checked:!1},{type:"radio",label:"固定",value:"fixed",checked:"",options:[{label:"无",value:!1},{label:"左",value:"left"},{label:"右",value:"right"}]}]),x=oe.useOriginalState(A.pinia);let w="$R";const{originalPath:g}=A.storeToRefs(x),E=g.value,P=e.computed(()=>{var v;const p=(v=oe.getAllLeafNodes(z.value)||[])==null?void 0:v.filter(B=>(B==null?void 0:B.type)!=="operate"&&(B==null?void 0:B.label)!=="操作"&&(B==null?void 0:B.prop)!=="operate");return p.length>0?p.every(B=>!!(B!=null&&B.sortable)):!1});e.computed(()=>{var v;return(v=z.value)==null?void 0:v.every(B=>B==null?void 0:B.filterable)}),e.computed(()=>{var v;return(v=z.value)==null?void 0:v.every(B=>B==null?void 0:B.operable)});const V=e.ref(!0),ee=e.ref([]),J=e.reactive({column:{},status:!1,text:"合计"}),me=e.reactive({currentPage:1,pageSize:10,total:0,pageSizes:[5,10,20]}),_e=l,z=e.ref([]),ne=e.ref([]),Y=e.ref([]),te=e.reactive({prop:"",order:null}),ye=e.ref([]),$e=e.ref(!1),de=e.ref(!1),T=e.ref(null),{isUseBackdrop:ie,initTrackFileType:U,getFileExtension:ge,setData:ze,getFileInfo:Le,getFilesInfo:ra}=Bo.useThreeSystem(),Ca=e.ref([]),Q=e.ref(!1),ca=e.ref(),ue=A.useMenuState(),{importLoading:pa,activeMenuPath:Se,contentLoading:ce,linkMenuInfo:De}=A.storeToRefs(ue),Ke=oe.useTableComp(A.pinia),ua=A.useModelComp(A.pinia),Za=Yn(A.pinia),{extraContents:$,cacheUpdatingData:H,tableViewContents:X,tableLoading:he,pageMapState:fe,lockingPage:ha}=A.storeToRefs(ua),{selectTab:ta}=A.storeToRefs(Za),{compType:Fe,hasEditable:xa}=ec.useRole(),Ae=e.ref([]),va=e.ref([]),La=e.ref(new Map);e.ref(!1);const Ia=e.ref("");e.ref();const fa=e.ref(!0),Ba=e.ref(0),Te=e.ref(!0),be=e.ref(""),Be=e.ref(!1),ae=e.ref(null);e.ref([]);const se=e.ref({label:"查看三维模型"}),Xe=e.ref(!1),Ze=e.ref(),Ha=e.ref([]),_a=e.ref([]),Qa=e.ref(!1),Pe=e.ref([]),Re=e.ref([]),Ue=e.ref([]),Ne=e.ref([]),Ie=e.ref([]),ul=()=>{try{const p=localStorage.getItem(Es),v=p?JSON.parse(p):[];Ie.value=Array.isArray(v)?v:[]}catch{Ie.value=[]}},_l=()=>{try{localStorage.setItem(Es,JSON.stringify(Ie.value||[]))}catch{}},Tl=p=>{var re,le,q;if(!p)return;const v=p.url||((re=p==null?void 0:p.uploadResult)==null?void 0:re.url)||"",B=p.name||((le=p==null?void 0:p.uploadResult)==null?void 0:le.name)||((q=p==null?void 0:p.uploadResult)==null?void 0:q.fileName)||"";if(!v&&!B)return;const I={name:B,url:v,ts:Date.now()},F=String(I.name||"").trim().toLowerCase(),D=(Ie.value||[]).findIndex(xe=>String((xe==null?void 0:xe.name)||"").trim().toLowerCase()===F);D>-1&&Ie.value.splice(D,1),Ie.value.unshift(I),Ie.value.length>20&&(Ie.value=Ie.value.slice(0,20)),_l()};ul();const jl=(p,v)=>`${q3}:${String(p??"")}:${String(v??"")}`,Cl=(p,v)=>{try{const B=sessionStorage.getItem(jl(p,v)),I=B?JSON.parse(B):[];return Array.isArray(I)?I:[]}catch{return[]}},Yl=(p,v,B)=>{try{sessionStorage.setItem(jl(p,v),JSON.stringify(Array.isArray(B)?B:[]))}catch{}},aa=(p,v,B)=>{if(!v)return;const I=Cl(p,v),F=[B,...I||[]].filter(Boolean).slice(0,1);return Yl(p,v,F),F},Ka=(p,v,B)=>{if(!v||!B)return;const I=jl(p,v),F=jl(p,B);try{const D=sessionStorage.getItem(I);if(!D)return;const re=(()=>{try{const xe=JSON.parse(D);return Array.isArray(xe)?xe:[]}catch{return[]}})(),le=Cl(p,B),q=[...re,...le||[]].filter(Boolean).sort((xe,Ce)=>Number((Ce==null?void 0:Ce.ts)||0)-Number((xe==null?void 0:xe.ts)||0)).slice(0,1);sessionStorage.setItem(F,JSON.stringify(q)),sessionStorage.removeItem(I)}catch{}},ma=e.ref(!1),il=e.ref(!1),Aa=e.ref([]),sl=e.ref(null);e.ref(!1),e.ref([]),e.ref(""),e.ref("");const rl=e.ref(!1),qe=e.ref([]),Ga=e.ref(1),hl=e.ref(new Map),pe=e.ref(new Map),na=e.ref(0),Sa=e.ref(!1),la=e.ref([]),nl=e.ref([]),Je=p=>{var v;try{const B=(v=oe.getAllLeafNodes(z.value)||[])==null?void 0:v.filter(I=>(I==null?void 0:I.type)!=="operate"&&(I==null?void 0:I.label)!=="操作"&&(I==null?void 0:I.prop)!=="operate");return(B==null?void 0:B.find(I=>(I==null?void 0:I.prop)===p||(I==null?void 0:I.label)===p))||null}catch{return null}},Fa=p=>{const v=Je(p),B=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"Input";return cl.getComponent(B)||cl.getComponent("Input")},wa=e.ref([]),Oa=e.ref(null),Me=e.ref([]),Ra=e.ref(null),Va=e.ref(""),Bl=e.ref(!1),We=e.ref([]),Ma=e.ref(""),Sl=e.ref(!1),pr=e.ref([]),ga=e.ref([]),Zl=e.ref([]),Sr=e.ref(null),Cr=e.ref([]),Oe=e.ref("");e.computed(()=>{var p;try{const v=(p=oe.getAllLeafNodes(z.value)||[])==null?void 0:p.filter(I=>(I==null?void 0:I.type)!=="operate"&&(I==null?void 0:I.label)!=="操作"&&(I==null?void 0:I.prop)!=="operate"),B=new Map;return v==null||v.forEach(I=>{I!=null&&I.label&&(I!=null&&I.prop)&&B.set(I.label,I.prop)}),B.get("编号")||""}catch{return""}});const lr=e.computed(()=>{var p;try{const v=(p=oe.getAllLeafNodes(z.value)||[])==null?void 0:p.filter(I=>(I==null?void 0:I.type)!=="operate"&&(I==null?void 0:I.label)!=="操作"&&(I==null?void 0:I.prop)!=="operate"),B=new Map;return v==null||v.forEach(I=>{I!=null&&I.label&&(I!=null&&I.prop)&&B.set(I.label,I.prop)}),B.get("名称")||""}catch{return""}}),br=e.computed(()=>{var p;try{const v=(p=oe.getAllLeafNodes(z.value)||[])==null?void 0:p.filter(I=>(I==null?void 0:I.type)!=="operate"&&(I==null?void 0:I.label)!=="操作"&&(I==null?void 0:I.prop)!=="operate"),B=new Map;return v==null||v.forEach(I=>{I!=null&&I.label&&(I!=null&&I.prop)&&B.set(I.label,I.prop)}),B.get("制造厂")||""}catch{return""}}),Dr=()=>{Sl.value=!1,pr.value=[],ga.value=[],Zl.value=[],Sr.value=null,Cr.value=[],Oe.value=""},zl=p=>p==null?!1:typeof p=="string"?p.trim()!=="":Array.isArray(p)?p.length>0:!0,$r=(p,v)=>{const B=(p==null?void 0:p.ocrRow)||{};for(const F of Object.keys(B))F==="id"||F==="_isOCRRow"||F==="_ocrTableId"||zl(B[F])&&(v[F]=B[F]);const I=va.value.find(F=>F.id===v.id);if(I)for(const F of Object.keys(B))F==="id"||F==="_isOCRRow"||F==="_ocrTableId"||zl(B[F])&&(I[F]=B[F]);La.value&&La.value.set(v.id,v),aa(u==null?void 0:u.index,v.id,p==null?void 0:p.versionItem),ga.value=[...ga.value||[],JSON.parse(JSON.stringify(v))]},Ur=async(p,v=null)=>{var B,I,F,D,re,le,q;try{const xe=(B=oe.getAllLeafNodes(z.value)||[])==null?void 0:B.filter(ba=>(ba==null?void 0:ba.type)!=="operate"&&(ba==null?void 0:ba.label)!=="操作"&&(ba==null?void 0:ba.prop)!=="operate"),Ce=new Map;xe==null||xe.forEach(ba=>{ba!=null&&ba.label&&(ba!=null&&ba.prop)&&Ce.set(ba.label,ba.prop)});const Ge=Ce.get("系统编号")||Ce.get("编号");if(!Ge){console.warn("未找到系统编号字段,跳过向检校记录表插入数据");return}const He=v||Sr.value;if((Array.isArray(He==null?void 0:He.result)?He.result:[]).length===0){console.warn("OCR识别结果为空,跳过向检校记录表插入数据");return}for(let ba=0;ba<p.length;ba++){const za=p[ba],$a=za[Ge];if(!$a){console.warn(`第 ${ba+1} 条匹配行缺少系统编号,跳过`);continue}const ea=`设备管理/试验设备/${$a}`,al=await A.getPageDataApi({platId:parseInt((I=ml.value)==null?void 0:I.plat_id),pageName:ea});if(!((F=al==null?void 0:al.data)!=null&&F.result)||!Array.isArray(al.data.result)){console.warn(`未找到详情页数据: ${ea}`);continue}const ka=al.data.result.find(sa=>(sa==null?void 0:sa.property_name)==="校检记录");if(!ka){console.warn(`详情页 ${ea} 中未找到校检记录表`);continue}const ll=(D=ka.contents)==null?void 0:D.find(sa=>(sa==null?void 0:sa.key)&&sa.key.startsWith("content_"));if(!ll||!ll.key){console.warn("校检记录表中未找到 content item");continue}const ve=ll.key,Pa=Array.isArray(ll.value)?ll.value:[];if(Pa.length>=5){const we=[...Pa].sort((da,Na)=>{const tl=Number((da==null?void 0:da.create_time)||0),Ya=Number((Na==null?void 0:Na.create_time)||0);return tl-Ya})[0];we!=null&&we.id&&await A.pageBatchDeleteApi({platId:parseInt((re=ml.value)==null?void 0:re.plat_id),changeContents:[{tableName:ve,tableContents:[{id:we.id}]}]})}const ya=(le=xe==null?void 0:xe.find(sa=>(sa==null?void 0:sa.label)==="证书附件"))==null?void 0:le.prop,Da=String(Date.now()),Ea={id:Da},N=Pa[0]||{},G=new Date().toISOString().split("T")[0];if(Object.keys(N||{}).forEach(sa=>{if(sa!=="id"){if(sa==="证书附件"){Ea[sa]="";return}if(sa==="校检日期"||sa==="检校日期"){Ea[sa]=za[sa]||za.校检日期||za.检校日期||G;return}if(["校检周期","检校周期","校检结果","检校结果","计量状态","依据文件","证书编号"].includes(sa)){Ea[sa]=za[sa]??"";return}Ea[sa]=za[sa]??""}}),ya&&za[ya]){const sa=za[ya];if(Array.isArray(sa)&&sa.length>0)Ea.证书附件=JSON.stringify(sa.map(we=>({url:(we==null?void 0:we.url)||"",name:(we==null?void 0:we.name)||(we==null?void 0:we.fileName)||"",fileName:(we==null?void 0:we.fileName)||(we==null?void 0:we.name)||""})).filter(we=>we.url||we.name));else if(typeof sa=="string")try{const we=JSON.parse(sa);Ea.证书附件=sa}catch{Ea.证书附件=JSON.stringify([{url:sa,name:sa,fileName:sa}])}}console.log(ve,"tableName","inspectionRecordRow",Ea),await A.pageBatchAddApi({platId:parseInt((q=ml.value)==null?void 0:q.plat_id),changeContents:[{tableName:ve,tableContents:[Ea]}]});const Ve=ka==null?void 0:ka.object_id;if(Ve&&Da){const sa=ya&&za[ya]?za[ya]:null;let we=[],da="",Na=!1;if(Array.isArray(sa)&&sa.length>0){we=sa.map(vl=>({name:(vl==null?void 0:vl.name)||(vl==null?void 0:vl.fileName)||"",url:(vl==null?void 0:vl.url)||""})).filter(vl=>vl.url||vl.name);const Ya=sa[0];da=(Ya==null?void 0:Ya.url)||"";const fl=(Ya==null?void 0:Ya.name)||(Ya==null?void 0:Ya.fileName)||"";Na=String(fl).toLowerCase().endsWith(".pdf")||String(da).toLowerCase().endsWith(".pdf")}else if(typeof sa=="string")try{const Ya=JSON.parse(sa);Array.isArray(Ya)?(we=Ya.map(fl=>({name:(fl==null?void 0:fl.name)||(fl==null?void 0:fl.fileName)||"",url:(fl==null?void 0:fl.url)||""})).filter(fl=>fl.url||fl.name),we.length>0&&(da=we[0].url||"",Na=String(we[0].name).toLowerCase().endsWith(".pdf")||String(da).toLowerCase().endsWith(".pdf"))):(da=sa,Na=String(sa).toLowerCase().endsWith(".pdf"))}catch{da=sa,Na=String(sa).toLowerCase().endsWith(".pdf")}const tl={ts:Date.now(),versionId:String(Date.now())+"_"+String(ba),label:new Date().toLocaleString(),certType:za.证书类型||"",certNo:za.证书编号||"",fileType:Na?"pdf":"image",sourceUrl:Na?da:"",images:we};aa(Ve,Da,tl)}}}catch(xe){console.error("向校检记录表插入OCR识别结果失败:",xe),Wa.ElMessage.error("向校检记录表插入数据失败,请查看控制台")}},Ul=p=>{const v=Array.isArray(p)?p:pr.value||[];if(v.length===0){Dr();return}if(v.find(D=>(D==null?void 0:D.__decision)==="replace"&&!(D!=null&&D.selectedTargetId))){Wa.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}v.forEach(D=>{var le;const re=D==null?void 0:D.__decision;if(!(!re||re==="skip")){if(re==="add"){aa(u==null?void 0:u.index,(le=D==null?void 0:D.ocrRow)==null?void 0:le.id,D==null?void 0:D.versionItem),Zl.value=[...Zl.value||[],D.ocrRow];return}if(re==="replace"){const q=D==null?void 0:D.selectedTargetId,xe=(Ae.value||[]).find(Ce=>String(Ce==null?void 0:Ce.id)===String(q));if(!xe)return;$r(D,xe)}}}),(ga.value||[]).length>0&&(Ae.value=[...Ae.value||[]]),(Zl.value||[]).length>0&&(Ae.value=[...Ae.value||[],...Zl.value||[]],va.value=[...va.value||[],...Zl.value||[]],(Zl.value||[]).forEach(D=>{var re,le;return(le=(re=La.value)==null?void 0:re.set)==null?void 0:le.call(re,D.id,D)})),jr.value=Ae.value;const I=ga.value||[],F=Zl.value||[];if(I.length>0&&(_e("change",{buttonName:"编辑",singleContent:I,content:Ae.value,relatedContents:u==null?void 0:u.related,index:u==null?void 0:u.index,parentTableId:u==null?void 0:u.parentTableId,columns:z.value,name:u==null?void 0:u.compName}),Ur(I)),F.length>0){const D=Sr.value;_e("change",{buttonName:"OCR批量新增",content:Ae.value,index:u==null?void 0:u.index,parentTableId:u==null?void 0:u.parentTableId,column:z.value,ocrRows:F,relatedContents:u==null?void 0:u.related,uploadedFiles:(Array.isArray(D==null?void 0:D.result)?D.result:[]).map(re=>(Array.isArray(re==null?void 0:re.图片信息)?re.图片信息:[]).map(le=>({url:(le==null?void 0:le.url)||"",name:(le==null?void 0:le.name)||"",fileName:(le==null?void 0:le.name)||""})).filter(le=>le.url)),ocrResult:D,matchedCount:(I||[]).length,newCount:(F||[]).length})}Wa.ElMessage.success("已提交候选处理结果"),Dr()},gr=kc(),vn=e.computed(()=>gr.getConfig()),vr=e.ref(),Il=e.ref(),sn=vc(A.pinia),jr=e.ref(),qr=e.ref(0),Kr=A.useUnit(A.pinia),{selectIndex:Xr,selectMenu:Wr,selectTitle:rr}=A.storeToRefs(Kr),{selectString:nr}=A.storeToRefs(sn),Zr=A.useLoginState(A.pinia),{loginUserInfo:ml}=A.storeToRefs(Zr),or=e.ref(720),Fl=e.ref(!1),Er=e.ref(!1),Wl=e.ref([]),hr=e.ref(),Vr=e.ref(!0),kr=e.ref(!0);e.ref([]);const cn=e.inject("contentRef");e.provide("contentRef",cn),e.provide("getSuggestListForCell",Bu),e.provide("getSuggestLoadingForCell",(p,v)=>{const B=`${p==null?void 0:p.id}:${(v==null?void 0:v.prop)||(v==null?void 0:v.property)}`;return b.value.get(B)||!1}),e.watch(()=>{var p;return(p=Ae.value)==null?void 0:p.length},p=>{me.total=p}),e.watch(()=>X.value,async()=>{var v,B,I,F,D,re,le,q,xe,Ce,Ge,He,Qe,ba,za,$a,ea;if(((v=X.value)==null?void 0:v.length)===0||!((B=u==null?void 0:u.itemData)!=null&&B.find(al=>(al==null?void 0:al.key)==="columnPath"))||!((I=u==null?void 0:u.itemData)!=null&&I.find(al=>(al==null?void 0:al.key)==="pageColumn")))return;let p=(xe=(q=(le=(re=(D=(F=u==null?void 0:u.itemData)==null?void 0:F.find(al=>(al==null?void 0:al.key)==="pageColumn"))==null?void 0:D.contents)==null?void 0:re.split("["))==null?void 0:le[1])==null?void 0:q.split("]"))==null?void 0:xe[0];((Qe=(He=(Ge=(Ce=u==null?void 0:u.itemData)==null?void 0:Ce.find(al=>(al==null?void 0:al.key)==="pageColumn"))==null?void 0:Ge.contents)==null?void 0:He.split("["))==null?void 0:Qe[0])+((za=(ba=X.value)==null?void 0:ba.find(al=>(al==null?void 0:al.key)===p))==null?void 0:za.value),(ea=($a=u==null?void 0:u.itemData)==null?void 0:$a.find(al=>(al==null?void 0:al.key)==="pageGroup"))==null||ea.contents,Ut(compData,u.allMapContents)},{deep:!0});const Qr=p=>{var B,I,F,D,re;const v=(I=(B=z.value)==null?void 0:B.filter(le=>le==null?void 0:le.mainKey))==null?void 0:I.map(le=>le==null?void 0:le.prop);if(v.length===0){const le=(F=z.value)==null?void 0:F.map(q=>q==null?void 0:q.prop);return(D=le==null?void 0:le.map(q=>p==null?void 0:p[q]))==null?void 0:D.join("|")}return(re=v==null?void 0:v.map(le=>p==null?void 0:p[le]))==null?void 0:re.join("|")},Jn=p=>{var le,q,xe,Ce,Ge;const v=(q=(le=z.value)==null?void 0:le.filter(He=>He==null?void 0:He.required))==null?void 0:q.map(He=>He==null?void 0:He.prop),B=[];if(p==null||p.forEach(He=>{v==null||v.forEach(Qe=>{const ba=He[Qe];(ba==null||ba==="")&&(B.includes(Qe)||B.push(Qe))})}),B.length>0)return Wa.ElMessage.warning(`请填写必填项:${B.join("、")}`);const I=new Map,F=new Map;(xe=Ae.value)==null||xe.forEach(He=>{const Qe=Qr(He);I.set(Qe,He)}),p==null||p.forEach(He=>{const Qe=Qr(He);F.set(Qe,He)});const D=p==null?void 0:p.filter(He=>I.has(Qr(He))),re=(Ce=Ae.value)==null?void 0:Ce.filter(He=>F.has(Qr(He)));return(D==null?void 0:D.length)>0&&(y.columns=(Ge=z.value)==null?void 0:Ge.filter(He=>(He==null?void 0:He.label)!=="操作"),y.existRows=re,y.tableData=D,y.show=!0),y.newRows=p==null?void 0:p.filter(He=>{const Qe=Qr(He);return!I.has(Qe)}),y.newRows},Fn=e.ref(""),Dn=e.ref(null),In=async()=>{var p,v,B,I,F,D;try{const re=await A.quoteApi({related:[{menus:Se.value,groups:u==null?void 0:u.compName}],platId:parseInt((p=ml.value)==null?void 0:p.plat_id)});if(((v=re==null?void 0:re.data)==null?void 0:v.code)===200){Dn.value=(B=re==null?void 0:re.data)==null?void 0:B.result;const le=(I=z.value)==null?void 0:I.map(Ce=>(Ce==null?void 0:Ce.prop)||(Ce==null?void 0:Ce.label)),q=jn(le,(F=re==null?void 0:re.data)==null?void 0:F.result),xe=q==null?void 0:q.flatMap(Ce=>Ce==null?void 0:Ce.quote);(xe==null?void 0:xe.length)>0&&(Fn.value=(D=xe==null?void 0:xe.map(Ce=>Ce==null?void 0:Ce.menus))==null?void 0:D.join("、"))}}catch(re){throw new Error(re)}};function jn(p,v){var B;return(B=v.filter(I=>I.struct&&Array.isArray(I.struct)?I.struct.some(F=>F.words&&Array.isArray(F.words)?F.words.some(D=>p.includes(D)):!1):!1))==null?void 0:B.map(I=>{const F={...I};return F.struct&&Array.isArray(F.struct)&&(F.struct=F.struct.filter(D=>D.words&&Array.isArray(D.words)?D.words.some(re=>p.includes(re)):!1)),F})}const mn=async(p,v)=>{var B,I;try{Dn.value||await In();const F=v==null?void 0:v.map(re=>{const le=Object.keys(re),q={};return le.forEach((xe,Ce)=>{q[p[Ce]]=re[xe]}),q}),D=Jn(F);if(!D||(D==null?void 0:D.length)===0)return;y.show||await R(D)}catch(F){throw Wa.ElMessage.error("数据导入处理失败"),await A.pageBatchAddApi({platId:parseInt((B=ml==null?void 0:ml.value)==null?void 0:B.plat_id),changeContents:[{tableName:"log",tableContents:[{id:"1",request_method:"Post",request_url:"",request_param:JSON.stringify(t1),request_result:JSON.stringify(F),is_delete:!1,request_table:(I=u==null?void 0:u.related)==null?void 0:I.find(D=>D==null?void 0:D.includes("content")),request_type:"error"}]}]}),new Error(F)}},On=async p=>{var D,re,le,q,xe,Ce,Ge;let v=Y.value;v!=null&&v.find(He=>(p==null?void 0:p.key)===(He==null?void 0:He.key))&&(v=v==null?void 0:v.filter(He=>(p==null?void 0:p.key)!==(He==null?void 0:He.key))),v.push({key:p==null?void 0:p.key,value:[(re=p==null?void 0:p.value)==null?void 0:re[((D=p==null?void 0:p.value)==null?void 0:D.length)-1]]});let B=Ne.value;B=B==null?void 0:B.map(He=>{var Qe,ba;return(He==null?void 0:He.type)==="Select"&&(p==null?void 0:p.key)===(He==null?void 0:He.prop)&&Array.isArray(He.value)&&(Qe=He.value)!=null&&Qe.every(za=>typeof za=="string")&&(He.selectValue=(ba=v==null?void 0:v.find(za=>(za==null?void 0:za.key)===(He==null?void 0:He.prop)))==null?void 0:ba.value),He});let I=(q=(le=B==null?void 0:B.find(He=>(He==null?void 0:He.prop)===(p==null?void 0:p.key)))==null?void 0:le.optionUrl)==null?void 0:q.menuId,F=B==null?void 0:B.find(He=>(He==null?void 0:He.prop)===(p==null?void 0:p.key));if(I){let He=await St(F==null?void 0:F.optionUrl,I),Qe,ba=ee.value,za=(Ge=(Ce=(xe=Ne.value)==null?void 0:xe.find($a=>{var ea;return(ea=F==null?void 0:F.optionUrl)==null?void 0:ea.menuId}))==null?void 0:Ce.selectValue)==null?void 0:Ge[0];if(He==null||He.forEach($a=>{var ea,al,ka,ll,ve,Pa,ya,Da,Ea,N;if(I){let G=(al=(ea=Ne.value)==null?void 0:ea.find(sa=>{var we,da;return((we=F==null?void 0:F.optionUrl)==null?void 0:we.menuId)===((da=sa==null?void 0:sa.optionUrl)==null?void 0:da.menuId)}))==null?void 0:al.prop,Ve=(ll=(ka=B==null?void 0:B.find(sa=>(sa==null?void 0:sa.prop)===G))==null?void 0:ka.selectValue)==null?void 0:ll[0];G!=null&&G.includes("·")&&(G=(ve=G==null?void 0:G.split("·"))==null?void 0:ve[0],Ve=(Ea=(Da=(ya=p==null?void 0:p.value)==null?void 0:ya[((Pa=p==null?void 0:p.value)==null?void 0:Pa.length)-1])==null?void 0:Da.split(" "))==null?void 0:Ea[0]),ba!=null&&ba.find(sa=>(sa==null?void 0:sa.value)===za)?Qe=(N=ba==null?void 0:ba.find(sa=>(sa==null?void 0:sa.value)===za))==null?void 0:N.objectValue:$a[G]===Ve&&(Qe=$a)}}),Qe){let $a=B;$a=$a==null?void 0:$a.map(ea=>{var al,ka,ll,ve,Pa,ya;return I&&(Qe!=null&&Qe[ea==null?void 0:ea.prop])&&be.value==="新增"&&(ea==null?void 0:ea.prop)!==(F==null?void 0:F.prop)?ea.value=(Qe==null?void 0:Qe[ea==null?void 0:ea.prop])||(Qe==null?void 0:Qe[(ve=(ll=(ka=(al=ea==null?void 0:ea.optionUrl)==null?void 0:al.groupSelect)==null?void 0:ka[1])==null?void 0:ll.replaceAll("[",""))==null?void 0:ve.replaceAll("]","")]):ea.value=(ya=(Pa=Ne.value)==null?void 0:Pa.find(Da=>(Da==null?void 0:Da.prop)===(ea==null?void 0:ea.prop)))==null?void 0:ya.value,ea}),Ne.value=$a}}Y.value=v},Xn=async(p,v)=>{var B,I,F,D,re;if((B=p==null?void 0:p.toString())!=null&&B.includes(".txt")||(I=p==null?void 0:p.toString())!=null&&I.includes(".cpt")||(F=p==null?void 0:p.toString())!=null&&F.includes(".cyd")){const le=await Wa.axios.get(p,{responseType:"blob",headers:{"Content-Type":"application/json"}}),q=new Blob([le.data],{type:"application/octet-stream;charset=UTF-8"});let xe=URL.createObjectURL(q);ca.value=[{name:(re=p==null?void 0:p.split("/"))==null?void 0:re[((D=p==null?void 0:p.split("/"))==null?void 0:D.length)-1],blobUrl:xe}],Q.value=!0}else Array.isArray(v)&&(v==null?void 0:v.length)>0&&_e("routeUrl",{isEdit:!1,routerUrl:v})};e.onBeforeUnmount(()=>{kr.value=!1;let p=qr.value;qr.value=p+1});const Gr=e.reactive({prop:"",order:null}),Zn=e.computed(()=>{const p=(Ae.value??[]).slice(),v=Gr.prop||te.prop,B=Gr.order||te.order;if(!v||!B)return p;const I=B==="ascending",F=re=>{if(v)return re&&Object.prototype.hasOwnProperty.call(re,v)?re[v]:v.includes(".")?v.split(".").reduce((le,q)=>le==null?le:le[q],re):re==null?void 0:re[v]},D=re=>{if(re==null)return{ok:!1,value:NaN};if(typeof re=="number")return{ok:Number.isFinite(re),value:re};const le=String(re).trim();if(le==="")return{ok:!1,value:NaN};const q=le.replace(/[,\s]/g,"");if(!/^[+-]?(\d+\.?\d*|\.\d+)$/.test(q))return{ok:!1,value:NaN};const xe=Number(q);return{ok:Number.isFinite(xe),value:xe}};return p.sort((re,le)=>{const q=F(re),xe=F(le);if(q==null&&xe==null)return 0;if(q==null)return I?-1:1;if(xe==null)return I?1:-1;const Ce=D(q),Ge=D(xe);if(Ce.ok&&Ge.ok)return I?Ce.value-Ge.value:Ge.value-Ce.value;const He=ve=>{if(ve==null)return{ok:!1,value:NaN};const Pa=String(ve).trim();if(Pa==="")return{ok:!1,value:NaN};const ya=Pa.match(/^(-)?(\d+):(\d{1,2}):(\d{1,2})$/);if(!ya)return{ok:!1,value:NaN};const Da=ya[1]?-1:1,Ea=Number(ya[2]),N=Number(ya[3]),G=Number(ya[4]);return[Ea,N,G].some(Ve=>Number.isNaN(Ve))?{ok:!1,value:NaN}:N>=60||G>=60?{ok:!1,value:NaN}:{ok:!0,value:Da*(Ea*3600+N*60+G)}},Qe=He(q),ba=He(xe);if(Qe.ok&&ba.ok)return I?Qe.value-ba.value:ba.value-Qe.value;const za=new Date(q).getTime(),$a=new Date(xe).getTime(),ea=!Number.isNaN(za),al=!Number.isNaN($a);if(ea&&al)return I?za-$a:$a-za;const ka=String(q),ll=String(xe);return I?ka.localeCompare(ll):ll.localeCompare(ka)})}),_n=e.computed(()=>{var B;const p=(me.currentPage-1)*me.pageSize,v=p+me.pageSize;return _e("getSliceContLength",me),(B=Zn.value)==null?void 0:B.slice(p,v)}),Mi=p=>{me.currentPage=p,_e("getSliceContLength",me)},jo=p=>{var I;me.pageSize=p;const v=((I=Ae.value)==null?void 0:I.length)??0,B=p>0?Math.ceil(v/p):1;me.currentPage>B&&(me.currentPage=B||1,Wa.ElMessage.warning("当前页超出范围,已自动跳转到最后一页")),_e("getSliceContLength",me)},Ho=({prop:p,order:v})=>{Gr.prop=p,Gr.order=v,me.currentPage=1};function Nn(p){const v=[];function B(I,F=""){I.forEach(D=>{D.children&&D.children.length>0?B(D.children,D.prop):v.push(D.prop)})}return B(p),v}const Uo=(p,v)=>{var le,q,xe,Ce;let B=(q=(le=z.value)==null?void 0:le.map(Ge=>Ge==null?void 0:Ge.prop))==null?void 0:q.filter(Ge=>Ge!=="operate");((xe=z.value)==null?void 0:xe.some(Ge=>{var He;return((He=Ge==null?void 0:Ge.children)==null?void 0:He.length)>0}))&&(B=Nn((Ce=z.value)==null?void 0:Ce.filter(Ge=>(Ge==null?void 0:Ge.prop)!=="operate")));let F;if(F=(p==null?void 0:p.length)===(B==null?void 0:B.length)?p:p.slice(0,B==null?void 0:B.length),!(F==null?void 0:F.every(Ge=>B==null?void 0:B.find(He=>Ge===He))))return Wa.ElMessage.error("导入的数据表头不匹配");mn(F,v)},qo=(p,v)=>{var F;const B=p==null?void 0:p.filter(D=>D!=="序号"),I=v==null?void 0:v.map(D=>{const re=Object.entries(D);return re.shift(),Object.fromEntries(re)});ua.setRefreshCurStructure(!1),((F=z.value)==null?void 0:F.length)===0||Uo(B,I)},Wo=(p,v,B,I)=>{const F=[],D=[],re=xe=>Object.keys(xe).length;for(const xe in p)if(p[xe]!==void 0){const Ce=p[xe],Ge=[];for(const[He,Qe]of Object.entries(Ce))Ge.push(Qe),D.length<re(Ce)&&D.push(He);F.push(Ge)}F.unshift(D);const le=oe.utils.aoa_to_sheet(F),q=oe.utils.book_new();oe.utils.book_append_sheet(q,le,I),oe.writeFileSync(q,`${v}.xlsx`),Wl.value=[]},Ii=async(p,v,B,I=!1,F)=>{try{ua.setRefreshCurStructure(!1)}catch(D){Wa.ElMessage.error(D)}},eo=async(p,v)=>{await Ii()},ln=async(p,v)=>{await Ii("columnType",v,p,!1)},Ko=async({newRow:p,targetIndex:v})=>{var F;if(!xa(u.config,{type:Fe.TABLE}))return;const I=(me.currentPage-1)*me.pageSize+(v??0);p._isTemp=!0;try{(p.sort===void 0||p.sort===null||String(p.sort).trim()==="")&&(p.sort=ri(I,Ae.value||[]))}catch{}Ae.value.splice(I,0,p),await e.nextTick(),h.value.has(p.id)||h.value.set(p.id,A.cloneDeep(p)),Ae.value=(F=Ae.value)==null?void 0:F.map(D=>({...D,tableEditType:(D==null?void 0:D.id)===p.id?"edit":(D==null?void 0:D.tableEditType)??"text"})),s.value.add(p.id),Fl.value=!0},Go=(p,v,B,I=[])=>(!Array.isArray(v)||v.length===0||v.forEach(F=>{const D=F==null?void 0:F.prop;if(!D)return;let re=p==null?void 0:p[D];if(re==null||String(re).trim()==="")return;re=String(re);const le=new Set([...(Array.isArray(B)?B:[]).filter(Ce=>(Ce==null?void 0:Ce.id)!==(p==null?void 0:p.id)).map(Ce=>Ce==null?void 0:Ce[D]).filter(Ce=>Ce!=null).map(Ce=>String(Ce)),...(Array.isArray(I)?I:[]).map(Ce=>Ce==null?void 0:Ce[D]).filter(Ce=>Ce!=null).map(Ce=>String(Ce))]);if(!le.has(re))return;let q=1,xe="";for(;xe=`${re}(${q})`,!!le.has(xe);)q++;p[D]=xe}),p),Oi=async()=>{var F,D,re,le,q,xe,Ce,Ge;const p=Array.from(s.value||[]);if(p.length===0)return;const v=(D=oe.getColumnChild((F=A.cloneDeep(z.value))==null?void 0:F.filter(He=>(He==null?void 0:He.label)!=="操作")))==null?void 0:D.filter(He=>(He==null?void 0:He.required)===!0);if((v==null?void 0:v.length)>0)for(let He=0;He<p.length;He++){const Qe=p[He],ba=(re=Ae.value)==null?void 0:re.find(za=>(za==null?void 0:za.id)===Qe);if(ba)for(let za=0;za<v.length;za++){const $a=v[za],ea=$a==null?void 0:$a.prop,al=($a==null?void 0:$a.label)??ea,ka=ba==null?void 0:ba[ea];if(ka===""||ka===null||ka===void 0||Array.isArray(ka)&&ka.length===0){Wa.ElMessage.error(`${al}不能为空`);let ve={};ve.id=ba==null?void 0:ba.id;const Pa={fixContent:[ve],buttonName:"修改",relatedContents:u==null?void 0:u.related,name:u==null?void 0:u.compName,columns:z.value};_e("change",Pa);return}}}const B=[],I=[];if(p.forEach(He=>{var al;const Qe=(al=Ae.value)==null?void 0:al.find(ka=>(ka==null?void 0:ka.id)===He);if(!Qe)return;if(Qe!=null&&Qe._isTemp){const ll=(oe.getAllLeafNodes(z.value)||[]).filter(N=>(N==null?void 0:N.mainKey)===!0||(N==null?void 0:N.isMainKey)===!0),ve=Ae.value.findIndex(N=>(N==null?void 0:N.id)===He),Pa=ve>=0?ve+1:Ae.value.length+1;Go(Qe,ll,Ae.value,B);const ya={id:Pa.toString()};(Qe==null?void 0:Qe.sort)!==void 0&&(Qe==null?void 0:Qe.sort)!==null&&String(Qe.sort).trim()!==""?ya.sort=String(Qe.sort):ya.sort=ri(ve>=0?ve:Ae.value.length-1,Ae.value||[]),(oe.getAllLeafNodes(z.value)||[]).filter(N=>(N==null?void 0:N.type)!=="operate"&&(N==null?void 0:N.label)!=="操作"&&(N==null?void 0:N.prop)!=="operate").forEach(N=>{const G=N==null?void 0:N.prop;if(G){const Ve=Qe[G];Ve!==void 0?ya[G]=Ve??"":ya[G]=""}}),B.push(ya);return}const za=(oe.getAllLeafNodes(z.value)||[]).filter(ka=>(ka==null?void 0:ka.type)!=="operate"&&(ka==null?void 0:ka.label)!=="操作"&&(ka==null?void 0:ka.prop)!=="operate"),$a=new Set(za.map(ka=>ka==null?void 0:ka.prop).filter(Boolean)),ea={};for(const ka of $a)Object.prototype.hasOwnProperty.call(Qe,ka)&&(ea[ka]=Qe[ka]);I.push({id:Qe.id,value:{tableData:ea}})}),ua.setTableLoading(u==null?void 0:u.index),I.length>0){const He=I.map(ba=>{const za={id:ba.id,...ba.value.tableData};return delete za._isOCRRow,delete za._ocrTableId,delete za._isTemp,delete za.tableEditType,delete za.index,za}),Qe=[{tableName:((le=u==null?void 0:u.related)==null?void 0:le.find(ba=>ba==null?void 0:ba.includes("content")))??"content_"+(u==null?void 0:u.index),tableContents:He}];try{await A.pageBatchUpdateApi({platId:parseInt((q=ml.value)==null?void 0:q.plat_id),changeContents:Qe})}catch(ba){Wa.ElMessage.error(((Ce=(xe=ba==null?void 0:ba.response)==null?void 0:xe.data)==null?void 0:Ce.message)||(ba==null?void 0:ba.message)||"保存失败"),ua.setTableLoading(!1);return}}if(B.length>0){const He={fixContent:B,buttonName:"新增",relatedContents:u==null?void 0:u.related,name:u==null?void 0:u.compName,columns:z.value};_e("change",He)}Wa.ElMessage.success("保存成功"),s.value.clear(),h.value.clear(),Ae.value=(Ge=Ae.value)==null?void 0:Ge.map(He=>({...He,tableEditType:"text"})),Fl.value=!1,ua.setRefreshCurStructure(!0)},Yo=()=>{var v;const p=Array.from(s.value||[]);if(p.length===0){Fl.value=!1;return}p.forEach(B=>{var D,re;const I=h.value.get(B),F=(D=Ae.value)==null?void 0:D.find(le=>(le==null?void 0:le.id)===B);if(F!=null&&F._isTemp){Ae.value=Ae.value.filter(le=>(le==null?void 0:le.id)!==F.id);return}if(I){const le=(re=Ae.value)==null?void 0:re.findIndex(q=>(q==null?void 0:q.id)===B);le!==-1&&(Ae.value[le]={...Ae.value[le],...I})}}),s.value.clear(),h.value.clear(),Ae.value=(v=Ae.value)==null?void 0:v.map(B=>({...B,tableEditType:"text"})),Fl.value=!1},Li=e.ref(!1),ao=async p=>{var F,D,re,le;if(!Fl.value||p!=null&&p.isComposing||(p==null?void 0:p.key)!=="Enter")return;const v=p==null?void 0:p.target;if(((D=(F=v==null?void 0:v.tagName)==null?void 0:F.toLowerCase)==null?void 0:D.call(F))==="textarea")return;const I=document.getElementById("excel-table");I&&!I.contains(v)||((re=v==null?void 0:v.blur)==null||re.call(v),(le=p.preventDefault)==null||le.call(p),await e.nextTick(),await lo())},lo=async()=>{if(H.value){Fl.value=!1;return}if(!Li.value){Li.value=!0;try{Array.from(s.value||[]).length>0?await Oi():Fl.value=!1}finally{Promise.resolve().then(()=>{Li.value=!1})}}},Jo=p=>{Wl.value=p},ro=(p,v)=>{hr.value===v?Vr.value=!1:Vr.value=!0,hr.value=v==null?void 0:v.changeProp},hi=p=>{if(!p)return;const{item:v,value:B}=p,I=Ne.value.find(F=>F.prop==v.prop);I&&I.contents.push({label:B,value:B})},bn=e.computed(()=>{var B,I,F;const p=(B=z.value)==null?void 0:B.some(D=>D==null?void 0:D.filterable);return document.documentElement.style.setProperty("--ssTable-header-filter-display",p?"inline-block":"none"),(F=(I=z.value)==null?void 0:I.filter(D=>(D==null?void 0:D.label)!=="操作"))==null?void 0:F.map(D=>({...D,filterable:!!(D!=null&&D.filterable),showSummary:!!(D!=null&&D.showSummary),operable:!!(D!=null&&D.operable),fixed:D==null?void 0:D.fixed}))}),Qn=async(p,v,B)=>{const I=A.cloneDeep(z.value);await e.nextTick();const F=I==null?void 0:I.map(re=>(B==null?void 0:B.label)===(re==null?void 0:re.label)?{...re,[v]:p}:re),D=Ri(F);await ks(u.index,D),z.value=F,ne.value=D},Ri=p=>{var F;const v=p||[];return((F=oe.getAllLeafNodes(v)||[])==null?void 0:F.filter(D=>(D==null?void 0:D.prop)&&(D==null?void 0:D.type)!=="operate"&&(D==null?void 0:D.label)!=="操作"&&(D==null?void 0:D.prop)!=="operate")).map(D=>{const{prop:re}=D;return p0(re,D)})},no=async p=>{let v=await h0(u.index);v||(v=Ri(p)),ne.value=v},io=async(p,v)=>{const B=A.cloneDeep(z.value),I=re=>Array.isArray(re)?re.map(le=>{const q=Array.isArray(le==null?void 0:le.children)&&le.children.length>0,xe={...le};return(xe==null?void 0:xe.prop)==="operate"||(xe==null?void 0:xe.label)==="操作"||(xe==null?void 0:xe.type)==="operate"?(xe.sortable=!1,xe.filterable=!1,xe.operable=!1):xe.sortable=q?!1:!!p,q&&(xe.children=I(xe.children)),xe}):re,F=I(B),D=Ri(F);await ks(u.index,D),z.value=F,ne.value=D,await e.nextTick(),qr.value=qr.value+1},oo=()=>{Be.value=!1},ei=p=>{_e("clickTrigger",p)},to=async p=>{var D,re,le,q,xe,Ce,Ge,He,Qe,ba,za,$a,ea,al,ka;const v=p==null?void 0:p.row,B=p==null?void 0:p.rowData,I=p==null?void 0:p.suffix;if((D=v==null?void 0:v.toString())!=null&&D.includes(".urdf")||p!=null&&p.isUrdf||I!=null&&I.includes(".urdf")){if(v.includes(",")){Wa.ElMessage.error("当前版本仅允许单个urdf预览!");return}if(ie(v)){const ve={files:[Le(v)],data:{}};ze(ve);return}Pe.value=[{url:v,extension:ge(v)}],de.value=!0,T.value={data:A.cloneDeep(B)},$e.value=!0;return}let F=[];if((re=v==null?void 0:v.toString())!=null&&re.includes(".stl")||(le=v==null?void 0:v.toString())!=null&&le.includes(".STL")||(q=v==null?void 0:v.toString())!=null&&q.includes(".obj")||(xe=v==null?void 0:v.toString())!=null&&xe.includes(".mtl")){const ll=(Ce=v==null?void 0:v.toString())==null?void 0:Ce.split(","),ve=ra(ll),Pa=ve==null?void 0:ve[0];if(ie(Pa==null?void 0:Pa.extension)){ze({files:ve,data:{}});return}Pe.value=ve,de.value=!1,$e.value=!0;return}if((Ge=v==null?void 0:v.toString())!=null&&Ge.includes(".stl")||(He=v==null?void 0:v.toString())!=null&&He.includes(".STL")||(Qe=v==null?void 0:v.toString())!=null&&Qe.includes(".obj")||(ba=v==null?void 0:v.toString())!=null&&ba.includes(".mtl")||I!=null&&I.includes(".stl")||I!=null&&I.includes(".STL")||I!=null&&I.includes(".obj")||I!=null&&I.includes(".mtl")){let ll,ve=[],Pa={};if(Array.isArray(v)?ll=v:ll=v==null?void 0:v.split(","),ll==null||ll.forEach(ya=>{ya.includes(".mtl")?ve.push(ya):Pa.blob=Pa.blob?Pa.blob+","+ya:ya}),(ve==null?void 0:ve.length)>0&&(Pa.mtlBlobs=ve),I&&(Pa.suffix=I),($a=(za=Object.values(Pa))==null?void 0:za[0])!=null&&$a.includes("http:"))F.push(Pa);else{const ya=new Blob([Pa.blob],{type:"application/octet-stream;charset=UTF-8"});let Da=URL.createObjectURL(ya),Ea="";(ea=v==null?void 0:v.split("/"))==null||ea.forEach((N,G)=>{var Ve;G===((Ve=v==null?void 0:v.split("/"))==null?void 0:Ve.length)-1&&(Ea=N)}),(al=Pa.blob)!=null&&al.includes(".stl")&&(Ea=(Ea==null?void 0:Ea.replaceAll(">",""))+".urdf"),ca.value=[{name:Ea,blobUrl:Da}],Q.value=!0}}else{const ll=await Wa.axios.get(v,{responseType:"blob",headers:{"Content-Type":"application/json"}}),ve=new Blob([ll.data],{type:"application/octet-stream;charset=UTF-8"});let Pa=URL.createObjectURL(ve),ya="";if((ka=v==null?void 0:v.split("/"))==null||ka.forEach((Da,Ea)=>{var N;Ea===((N=v==null?void 0:v.split("/"))==null?void 0:N.length)-1&&(ya=Da)}),ie(ya)){const Da=U(ya),Ea=Le(v);ze({files:[Ea],data:{trackFileType:Da}});return}ca.value=[{name:ya,blobUrl:Pa}],Q.value=!0}(F==null?void 0:F.length)>0&&r.setBlobUrls(F)},ai=p=>{var I,F,D,re;if(p!=null&&p.downloadUrl)return p==null?void 0:p.name;const v=(re=(I=p==null?void 0:p.url)==null?void 0:I.split("."))==null?void 0:re[((D=(F=p==null?void 0:p.url)==null?void 0:F.split("."))==null?void 0:D.length)-1];return(p==null?void 0:p.name)+"."+v},so=p=>{if(!p)return"未知文件";try{const I=ai(p);if(typeof I=="string"&&I.includes("."))return I}catch{}const v=(p==null?void 0:p.fileName)||(p==null?void 0:p.name)||"未知文件",B=(p==null?void 0:p.suffix)||"";return v.includes(".")?v:`${v}${B}`},co=p=>{if(p==null||typeof p=="number"||typeof p!="string")return p;const v=p.match(/^(\d+)\_(\d+)$/);if(!v)return p;const B=Number(v[1]),I=Number(v[2]);return!Number.isFinite(B)||!Number.isFinite(I)?p:String(B*1e3+I)},li=p=>{if(p==null)return null;const v=String(p).trim();if(!v)return null;const B=Number(v);return Number.isFinite(B)?B:null},Xo=p=>{if(p==null)return null;const v=String(p).trim();if(!v)return null;if(/^\d+$/.test(v)){const F=Number(v);return Number.isFinite(F)?v.length<=10?F*1e3:F:null}const B=v.includes("T")?v:v.replace(" ","T"),I=Date.parse(B);return Number.isFinite(I)?I:null},vi=(p,v=[])=>{const B=Array.isArray(p)?p.slice():[];if(B.length<=1)return B;const I=new Map((v||[]).map((re,le)=>[String(re),le])),F=B.some(re=>li(re==null?void 0:re.sort)!==null),D=B.map((re,le)=>({r:re,idx:le,id:String((re==null?void 0:re.id)??""),sortVal:li(re==null?void 0:re.sort),createTimeMs:Xo(re==null?void 0:re.create_time),prevIdx:I.has(String(re==null?void 0:re.id))?I.get(String(re==null?void 0:re.id)):Number.POSITIVE_INFINITY}));return D.sort((re,le)=>{if(F){const Ce=re.sortVal,Ge=le.sortVal;if(Ce===null&&Ge!==null)return 1;if(Ce!==null&&Ge===null)return-1;if(Ce!==null&&Ge!==null&&Ce!==Ge)return Ce-Ge}const q=re.createTimeMs,xe=le.createTimeMs;return q!==null&&xe!==null&&q!==xe?xe-q:q!==null&&xe===null?-1:q===null&&xe!==null?1:re.prevIdx!==le.prevIdx?re.prevIdx-le.prevIdx:re.idx-le.idx}),D.map(re=>re.r)},ri=(p,v=[])=>{const B=v==null?void 0:v[p-1],I=v==null?void 0:v[p],F=li(B==null?void 0:B.sort),D=li(I==null?void 0:I.sort);let re=null;F!==null&&D!==null&&D>F?re=(F+D)/2:F!==null?re=F+1:D!==null?re=Math.max(D-1,0):re=(p??0)+1;const le=Number(re.toFixed(6));return String(Number.isFinite(le)?le:re)},mi=async p=>{let v=null,B=null;if(p!=null&&p.id){const F=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});try{const D=await A.platformDownloadFile(p);v=URL.createObjectURL(D.data),B=so(p)}finally{F.close()}}else if(p!=null&&p.downloadUrl){const F=await yi(),D=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),re=await Wa.axios.post(p==null?void 0:p.url,null,{responseType:"blob",headers:{Authorization:F,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}).finally(()=>{D.close()}),le=new Blob([re.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(le),B=p==null?void 0:p.name}else{const F=await A.platformDownloadFile({url:p==null?void 0:p.url});!p.url.toUpperCase().includes(".OBJ")&&!p.url.toUpperCase().includes(".STL")&&!p.url.toUpperCase().includes(".MTL")&&!p.url.toUpperCase().includes(".URDF")?(v=URL.createObjectURL(F.data),B=ai(p)):v=p==null?void 0:p.url}if(ie(v)){const F={row:`${v}`,suffix:ge(B)};to(F);return}const I={name:B,blobUrl:v};ca.value=[I],Q.value=!0},Zo=async p=>{let v=null,B=null;if(p!=null&&p.id){const D=await A.platformDownloadFile(p);v=URL.createObjectURL(D.data),B=so(p)}else if(p!=null&&p.downloadUrl){const D=await yi(),re=await Wa.axios.post(p==null?void 0:p.url,null,{responseType:"blob",headers:{Authorization:D,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}),le=new Blob([re.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(le),B=p==null?void 0:p.name}else{const D=await A.platformDownloadFile({url:p==null?void 0:p.url});v=URL.createObjectURL(D.data),B=ai(p)}const I={name:B,blobUrl:v},F=document.createElement("a");F.href=I.blobUrl,F.download=I.name,F.style.display="none",document.body.appendChild(F),F.click(),setTimeout(()=>{document.body.removeChild(F)},100)},$i=(p,v)=>{var I;if(Object.values(v).length===0)return;let B=p;return Object.values(v).find(F=>{var D,re,le;return((D=F==null?void 0:F.toString())==null?void 0:D.includes(".txt"))||((re=F==null?void 0:F.toString())==null?void 0:re.includes(".cpt"))||((le=F==null?void 0:F.toString())==null?void 0:le.includes(".obj"))})?B=[...p,se.value]:(I=u==null?void 0:u.config)!=null&&I.allowMove&&(B=[...p,{label:"迁移"}]),B},Qo=()=>{O.value=!0},et=e.ref([]),uo=async(p,v,B=!1)=>{var re,le,q,xe;if(!p)return;if(B){Ae.value=[...La.value.values()].filter(Ce=>Object.values(Ce).some(Ge=>typeof Ge=="string"?Ge==null?void 0:Ge.toLowerCase().includes(v==null?void 0:v.toLowerCase()):!1));return}let I={};for(let Ce in p)(p==null?void 0:p[Ce])!==""&&(I[Ce]=p==null?void 0:p[Ce]);if(JSON.stringify(I)==="{}"){Ae.value=Array.from(((re=La.value)==null?void 0:re.values())??[]);return}let F=(le=u==null?void 0:u.related)==null?void 0:le.find(Ce=>Ce==null?void 0:Ce.includes("content_")),D=await A.getFillFind({platId:parseInt((q=ml==null?void 0:ml.value)==null?void 0:q.plat_id),tableName:F,params:I});D=(xe=D==null?void 0:D.data)==null?void 0:xe.result,Ae.value=D,ua.setTableLoading(!1)},ni=e.computed(()=>{var v,B;return((B=(v=u==null?void 0:u.itemData)==null?void 0:v.find(I=>(I==null?void 0:I.key)==="isEdit"))==null?void 0:B.contents)??!0}),An=async p=>{var I,F,D,re;if(!xa(u.config,{type:Fe.TABLE})||!(((F=(I=u==null?void 0:u.itemData)==null?void 0:I.find(le=>(le==null?void 0:le.key)==="isEdit"))==null?void 0:F.contents)??!0)||!p)return;((D=Array.from(s.value))==null?void 0:D.length)>0&&await Oi();const B=p==null?void 0:p.id;B!=null&&(s.value.clear(),h.value.clear(),h.value.has(B)||h.value.set(B,A.cloneDeep(p)),Ae.value=(re=Ae.value)==null?void 0:re.map(le=>({...le,tableEditType:(le==null?void 0:le.id)===B?"edit":"text"})),s.value.add(B),Fl.value=!0)},Vi=async(p,v,B,I)=>{I!=null&&I.isExistChild&&_e("clickMainKey",p,B,z.value)},Pi=()=>{Q.value=!1},at=p=>{_e("rowClick",p)};e.watch(()=>u.changedContent,()=>{var B,I;if(!u.changedContent)return;let p=(B=Ae.value)==null?void 0:B.map(F=>{var D;return F.id===((D=u.changedContent)==null?void 0:D.id)&&(F={...u.changedContent,id:u.changedContent.newId?u.changedContent.newId:u.changedContent.id},delete F.newId),F});const v=(I=u.itemData)==null?void 0:I.map(F=>((F==null?void 0:F.key)==="tableContents"&&(F.contents=p),F));Ae.value=p,_e("contentChange",{contents:v,index:u.index}),_e("change",{content:p,index:u==null?void 0:u.index,buttonName:"",id:u==null?void 0:u.index})},{deep:!0,immediate:!0});const lt=()=>{},rt=async()=>{const p=Se.value,v=sessionStorage.getItem("systemKey"),B=await oe.getItemData(p,v,""),I=(B==null?void 0:B.find(le=>(le==null?void 0:le.name)==="方法明细"))||(B==null?void 0:B[0]),F=(I==null?void 0:I.compData)||[],D=F==null?void 0:F.find(le=>{const q=le==null?void 0:le.key;return q==="formContent"||q==="tableContents"});return D==null?void 0:D.contents},yi=async()=>{const v=Wa.Local.get("access-token");return v?`Bearer ${v}`:""},nt=async(p,{token:v,inputData:B}={})=>await Wa.axios.post(p,B,{headers:{Authorization:v}}).catch(F=>(ue.setImportLoading(!1),Promise.reject(F))),it=p=>{var I;let v={};const B=[];return v.form={},(I=A.cloneDeep(p))==null||I.forEach((F,D)=>{var re,le,q,xe,Ce,Ge,He,Qe,ba,za,$a,ea,al,ka;if((F==null?void 0:F.comp)==="Table"){(le=(re=F==null?void 0:F.compData)==null?void 0:re.find(ya=>(ya==null?void 0:ya.key)==="header"))==null||le.contents;let ll=(Ce=(xe=(q=F==null?void 0:F.compData)==null?void 0:q.find(ya=>(ya==null?void 0:ya.key)==="tableContents"))==null?void 0:xe.contents)==null?void 0:Ce.map(ya=>ya.slice(1));(za=(ba=(Qe=(He=(Ge=F==null?void 0:F.compData)==null?void 0:Ge.find(ya=>(ya==null?void 0:ya.key)==="header"))==null?void 0:He.contents)==null?void 0:Qe[0])==null?void 0:ba[0])==null||za.label;let ve=(ea=($a=F==null?void 0:F.compData)==null?void 0:$a.find(ya=>(ya==null?void 0:ya.key)==="header"))==null?void 0:ea.contents,Pa=[];ll==null||ll.forEach(ya=>{let Da=[];ya==null||ya.forEach((Ea,N)=>{var Ve;let G={};((Ve=ve[N])==null?void 0:Ve.label)!=="操作"&&(G[ve[N].label]=Ea,Da.push(G))}),Pa.push(Da)}),v[F.name]=Pa}else{const ll=(ka=(al=F.compData)==null?void 0:al.find(ve=>(ve==null?void 0:ve.key)==="formContent"))==null?void 0:ka.contents;ll==null||ll.forEach(ve=>{var Pa,ya;if(ve.prop!==""){let Da=ve==null?void 0:ve.value;Array.isArray(Da)?Da=((Pa=Da==null?void 0:Da[0])==null?void 0:Pa.oldUrl)||"http://222.92.178.198:62001/"+((ya=Da==null?void 0:Da[0])==null?void 0:ya.url):Da=Da.toString(),ve={key:(ve==null?void 0:ve.prop)??(ve==null?void 0:ve.label),value:Da},B.push(ve)}})}}),v.form=oe.getFormContents(B),v},ot=p=>{const v=[],B=I=>{I&&typeof I=="object"&&!Array.isArray(I)?Object.values(I).forEach(B):v.push(I)};return B(p),v},tt=async(p,v,B)=>{var ve,Pa,ya,Da,Ea,N,G,Ve,sa,we,da,Na,tl,Ya,fl,vl,ql;ue.setImportLoading(!0),ua.setFreshContent(!1);let I=await rt().catch(Ua=>(ue.setImportLoading(!1),Promise.reject(Ua)));I=I==null?void 0:I.filter(Ua=>{var kl;return((kl=Ua==null?void 0:Ua.find(ja=>ja==null?void 0:ja.id))==null?void 0:kl.id)===(v==null?void 0:v.id)});let F=oe.getEqualChild([(ve=z.value)==null?void 0:ve.filter(Ua=>(Ua==null?void 0:Ua.label)!=="操作")]);const D=(ya=(Pa=oe.tableToForm(I,F))==null?void 0:Pa[0])==null?void 0:ya.find(Ua=>{const kl=Ua==null?void 0:Ua.key;return kl==="Interface"||kl==="方法体"}),re=D==null?void 0:D.value;if(!re){console.log("未搜索到isMain, 缺少算法执行接口"),ue.setImportLoading(!1);return}const le=z.value?oe.getEqualChild([z.value]):[],q=le.find(Ua=>{const kl=Ua==null?void 0:Ua.prop;return kl==="Input1"||kl==="输入数据.输入1"||kl==="样本输入数据"}),xe=q==null?void 0:q.prop;let Ce=v==null?void 0:v[xe];const Ge=await yi().catch(Ua=>(ue.setImportLoading(!1),Promise.reject(Ua)));let He=!0,Qe="";(Da=z.value)==null||Da.forEach(Ua=>{(Ua==null?void 0:Ua.prop)===xe&&(He=!!(Ua!=null&&Ua.childPath),Qe=Ua==null?void 0:Ua.childPath)});let ba="";if(He){let Ua=(N=(Ea=z.value)==null?void 0:Ea.find(pl=>(pl==null?void 0:pl.isMainKey)===!0))==null?void 0:N.prop;ba=v==null?void 0:v[Ua];let kl=Qe==null?void 0:Qe.split(E),ja=[];kl==null||kl.forEach((pl,Nl)=>{(kl==null?void 0:kl.length)-1===Nl&&ja.push(ba),ja.push(pl)}),ja=ja==null?void 0:ja[0];let dl=await oe.getItemData(ja,sessionStorage.getItem("systemKey"),""),Xa=dl==null?void 0:dl.filter(pl=>(pl==null?void 0:pl.name)===xe);Xa=Xa==null?void 0:Xa.map(pl=>{var Nl;return pl.compData=(Nl=pl==null?void 0:pl.compData)==null?void 0:Nl.map(Ll=>{var Nr;return(Ll==null?void 0:Ll.key)==="tableContents"&&(Ll.contents=(Nr=Ll==null?void 0:Ll.contents)==null?void 0:Nr.filter(Hl=>(Hl==null?void 0:Hl[1])===(v==null?void 0:v[xe]))),Ll}),pl}),(!Xa||(Xa==null?void 0:Xa.length)===0)&&(Xa=dl,Xa=Xa==null?void 0:Xa.map(pl=>{var Nl;return pl.compData=(Nl=pl==null?void 0:pl.compData)==null?void 0:Nl.map(Ll=>{var Nr;return(Ll==null?void 0:Ll.key)==="tableContents"&&(Ll.contents=(Nr=Ll==null?void 0:Ll.contents)==null?void 0:Nr.filter(Hl=>{var wl,$l;return(Hl==null?void 0:Hl[1])===(v==null?void 0:v[($l=(wl=z==null?void 0:z.value)==null?void 0:wl[0])==null?void 0:$l.prop])})),Ll}),pl})),Ce=it(Xa)}const za=await nt(re,{token:Ge,inputData:Ce}).catch(Ua=>(ue.setImportLoading(!1),Promise.reject(Ua))),$a=(G=za==null?void 0:za.data)==null?void 0:G.data,ea=le.find(Ua=>(Ua==null?void 0:Ua.prop)==="Output1"),al=ea==null?void 0:ea.prop;let ka=[],ll=[];if($a&&((Ve=Object.values($a))==null?void 0:Ve.length)>0){let Ua=[];const kl=new FormData,ja=(sa=ot($a))==null?void 0:sa.map(async Xa=>{var pl,Nl;if(!Array.isArray(Xa)&&(Xa!=null&&Xa.includes("http"))){let Ll=await Wa.axios.get(Xa,{responseType:"blob"}),Nr=(Nl=Xa==null?void 0:Xa.split("/"))==null?void 0:Nl[((pl=Xa==null?void 0:Xa.split("/"))==null?void 0:pl.length)-1];kl.append("files",Ll.data,Nr)}else Ua.push(Xa)});if(await Promise.all(ja),!oe.isFormDataEmpty(kl)){let Xa=await A.uploadAmountApi(kl),pl=(da=(we=Xa==null?void 0:Xa.data)==null?void 0:we.result)==null?void 0:da.map(Nl=>{var Ll,Nr,Hl,wl,$l,er;return{name:(er=($l=(wl=(Ll=Nl==null?void 0:Nl.url)==null?void 0:Ll.split("/"))==null?void 0:wl[((Hl=(Nr=Nl==null?void 0:Nl.url)==null?void 0:Nr.split("/"))==null?void 0:Hl.length)-1])==null?void 0:$l.split("."))==null?void 0:er[0],url:Nl==null?void 0:Nl.url}});Ua=[...Ua,...pl]}let dl={};for(let Xa in v)Xa!=="id"&&(dl[Xa]=v[Xa]);dl[al]=Ua,ll.push({id:v==null?void 0:v.id,value:{tableData:dl}})}if((ll==null?void 0:ll.length)>0){const Ua=ll.map(ja=>{const dl={id:ja.id,...ja.value.tableData};return delete dl._isOCRRow,delete dl._ocrTableId,delete dl._isTemp,delete dl.tableEditType,delete dl.index,dl}),kl=[{tableName:(Na=u==null?void 0:u.related)==null?void 0:Na.find(ja=>ja==null?void 0:ja.includes("content")),tableContents:Ua}];await A.pageBatchUpdateApi({platId:parseInt((tl=ml.value)==null?void 0:tl.plat_id),changeContents:kl})}if((ka==null?void 0:ka.length)>0)try{await A.pageBatchAddApi({platId:parseInt((Ya=ml.value)==null?void 0:Ya.plat_id),changeContents:[{tableName:(fl=u==null?void 0:u.related)==null?void 0:fl.find(Ua=>Ua==null?void 0:Ua.includes("content")),tableContents:ka.map(Ua=>{var ja,dl,Xa;const kl={id:((ja=Ua==null?void 0:Ua.key)==null?void 0:ja.id)??((dl=Ua==null?void 0:Ua.key)==null?void 0:dl.rowId)??(Ua==null?void 0:Ua.id),...((Xa=Ua==null?void 0:Ua.value)==null?void 0:Xa.tableData)||{}};return delete kl._isOCRRow,delete kl._ocrTableId,delete kl._isTemp,delete kl.tableEditType,delete kl.index,Object.keys(kl).forEach(pl=>{pl==="证书附件"&&Array.isArray(kl[pl])&&(kl[pl]=JSON.stringify(kl[pl]))}),kl})}]})}catch(Ua){Wa.ElMessage.error(((ql=(vl=Ua==null?void 0:Ua.response)==null?void 0:vl.data)==null?void 0:ql.message)||(Ua==null?void 0:Ua.message)||"保存失败"),ua.setTableLoading(!1);return}Hi(!0),ue.setImportLoading(!1),ua.setFreshContent(!0)},po=(p,v)=>(p=p==null?void 0:p.map(B=>{var I,F;return B!=null&&B.children&&((I=B.children)!=null&&I.find(D=>D.id===(v==null?void 0:v.id))?B.children=(F=B.children)==null?void 0:F.filter(D=>(D==null?void 0:D.id)!==(v==null?void 0:v.id)):B.children=po(B.children,v)),B}),p),gi=e.ref(!1),t=()=>{gi.value=!0},o=async p=>{var B,I,F,D;gi.value=!1;const v=Array.isArray(p)?p:p?[p]:[];if(v.length!==0)for(const re of v){const le={name:re.name||`capture-${Date.now()}.jpg`,url:URL.createObjectURL(re),raw:re,uid:Date.now()+Math.random()};Aa.value.push(le),tr(le,"uploading"),Vl(le,0);try{const q=new FormData;q.append("file",re,le.name);const xe=await A.platformUploadFile(q);le.uploadResult=((B=xe==null?void 0:xe.data)==null?void 0:B.result)||{name:le.name,url:"",fileName:le.name},Tl({name:((I=le.uploadResult)==null?void 0:I.name)||le.name,url:((F=le.uploadResult)==null?void 0:F.url)||"",id:(D=le.uploadResult)==null?void 0:D.id}),tr(le,"uploaded"),Vl(le,100)}catch(q){console.error("文件上传失败:",q),Wa.ElMessage.error(`文件 ${le.name} 上传失败,请重试`),tr(le,"pending"),Vl(le,0);const xe=Aa.value.findIndex(Ce=>Ce.uid===le.uid);xe>-1&&Aa.value.splice(xe,1)}}},f=e.reactive({title:"迁移至",show:!1,width:"20%",selectRow:null,from:u==null?void 0:u.index,to:null,contents:[],formRules:{groupName:[{required:!0,message:"输入不能为空",trigger:"blur"},{validator:(p,v,B)=>{v===(u==null?void 0:u.index)?B(new Error("选择源不能和目标源一致")):B()}}]},buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"确认",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]}),y=e.reactive({title:"温馨提示:检测到导入的以下数据,系统中已存在,请选择操作",show:!1,width:"70%",columns:[],tableData:[],existRows:[],newRows:[],buttonValue:[{label:"跳过",value:"cancel",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"覆盖",render:"popover",value:"replace",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}],result:""}),S=()=>{y.show=!1},R=async p=>{var v,B,I,F,D,re,le,q;try{const xe=[];let Ce=(v=Ae.value||[])==null?void 0:v.slice();(p||[]).forEach(za=>{const $a={...za};try{$a.sort=ri(0,Ce)}catch{}xe.push($a),Ce.unshift($a)});let Ge=await A.quoteApi({platId:parseInt((B=ml==null?void 0:ml.value)==null?void 0:B.plat_id),type:"fatherSyncs",related:[{menus:Se.value,groups:""},{menus:Se.value,groups:u==null?void 0:u.compName}]});Ge=(I=Ge==null?void 0:Ge.data)==null?void 0:I.result;let He=Ge==null?void 0:Ge.map(za=>({tableName:"content_"+(za==null?void 0:za.id),tableContents:xe==null?void 0:xe.map(($a,ea)=>({id:ea,...$a}))})),Qe=[{tableName:(F=u==null?void 0:u.related)==null?void 0:F.find(za=>za==null?void 0:za.includes("content")),tableContents:xe==null?void 0:xe.map((za,$a)=>({id:$a,...za}))}];Qe=[...Qe,...He];const ba=await A.pageBatchAddApi({platId:parseInt((D=ml.value)==null?void 0:D.plat_id),changeContents:Qe});if(((re=ba==null?void 0:ba.data)==null?void 0:re.code)===200){const za={buttonName:"新增",columns:z.value,fixContent:xe==null?void 0:xe.map((ea,al)=>({id:al,...ea})),relatedContents:u==null?void 0:u.related};await Tt(za),Wa.ElMessage.success("数据导入成功");let $a=[];Qe==null||Qe.forEach(ea=>{var al;(al=ea==null?void 0:ea.tableContents)==null||al.forEach(ka=>{$a.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ka),request_result:"{}",is_delete:!1,request_table:ea==null?void 0:ea.tableName,request_type:"export"})})}),await A.pageBatchAddApi({platId:parseInt((le=ml==null?void 0:ml.value)==null?void 0:le.plat_id),changeContents:[{tableName:"log",tableContents:$a}]})}else{let za=[];Qe==null||Qe.forEach($a=>{var ea;(ea=$a==null?void 0:$a.tableContents)==null||ea.forEach(al=>{za.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(al),request_result:"{}",is_delete:!1,request_table:$a==null?void 0:$a.tableName,request_type:"error"})})}),await A.pageBatchAddApi({platId:parseInt((q=ml==null?void 0:ml.value)==null?void 0:q.plat_id),changeContents:[{tableName:"log",tableContents:za}]}),Wa.ElMessage.error("数据导入响应失败")}}catch(xe){throw new Error(xe)}},K=async p=>{var v,B,I,F,D,re,le,q,xe,Ce;try{if(p==="cancel"&&(y.show=!1),p==="replace"&&((v=y==null?void 0:y.existRows)==null?void 0:v.length)>0){await A.pageBatchDeleteApi({platId:parseInt((B=ml.value)==null?void 0:B.plat_id),changeContents:[{tableName:((I=u==null?void 0:u.related)==null?void 0:I.find(He=>He==null?void 0:He.includes("content_")))||((F=u==null?void 0:u.related)==null?void 0:F.find(He=>He==null?void 0:He.includes("content"))),tableContents:y==null?void 0:y.existRows}]});const Ge=await A.pageBatchAddApi({platId:parseInt((D=ml.value)==null?void 0:D.plat_id),changeContents:[{tableName:(re=u==null?void 0:u.related)==null?void 0:re.find(He=>He==null?void 0:He.includes("content")),tableContents:(()=>{const He=(Ae.value||[]).filter($a=>!((y==null?void 0:y.existRows)||[]).some(ea=>String(ea==null?void 0:ea.id)===String($a==null?void 0:$a.id))),Qe=(y==null?void 0:y.tableData)||[],ba=[];let za=He.slice();return Qe.forEach($a=>{const ea={...$a};try{ea.sort=ri(0,za)}catch{}ba.push(ea),za.unshift(ea)}),ba.map(($a,ea)=>({id:ea,...$a}))})()}]});if(((le=Ge==null?void 0:Ge.data)==null?void 0:le.code)!==200)return;(q=y.newRows)!=null&&q.length&&await R(y.newRows),await Tt({buttonName:"新增",columns:z.value,fixContent:(xe=y==null?void 0:y.tableData)==null?void 0:xe.map((He,Qe)=>({id:Qe,...He})),relatedContents:u==null?void 0:u.related}),(Ce=y.newRows)!=null&&Ce.length||Wa.ElMessage.success("数据导入成功")}}catch(Ge){throw new Error(Ge)}finally{y.show=!1,y.columns=[],y.tableData=[],y.existRows=[]}},Z=()=>{f.show=!1},ke=p=>{var v,B;if((p==null?void 0:p.buttonName)==="取消")return f.show=!1;f.to=p==null?void 0:p.content,!(!(u!=null&&u.index)||!((v=f.to)!=null&&v.groupName))&&(u==null?void 0:u.index)!==((B=f.to)==null?void 0:B.groupName)&&(_e("change",{buttonName:"迁移",value:{from:f.from,to:f.to,data:f.selectRow}}),f.show=!1)},je=async p=>{var v,B,I,F;if(p){if(!gr.validateFileSize(p.raw)){Wa.ElMessage.warning(`文件大小不能超过 ${vn.value.maxSize}MB`);const D=Aa.value.findIndex(re=>re.uid===p.uid);D>-1&&Aa.value.splice(D,1),Ee();return}if(!gr.validateFileType(p.raw)){Wa.ElMessage.warning("请上传图片文件");const D=Aa.value.findIndex(re=>re.uid===p.uid);D>-1&&Aa.value.splice(D,1),Ee();return}tr(p,"uploading"),Vl(p,0);try{const D=new FormData;D.append("file",p.raw,p.name);const re=await A.platformUploadFile(D);p.uploadResult=((v=re==null?void 0:re.data)==null?void 0:v.result)||{name:p.name,url:"",fileName:p.name},Tl({name:((B=p.uploadResult)==null?void 0:B.name)||p.name,url:((I=p.uploadResult)==null?void 0:I.url)||"",id:(F=p.uploadResult)==null?void 0:F.id}),tr(p,"uploaded"),Vl(p,100)}catch(D){console.error("文件上传失败:",D),Wa.ElMessage.error(`文件 ${p.name} 上传失败,请重试`),tr(p,"pending"),Vl(p,0);const re=Aa.value.findIndex(le=>le.uid===p.uid);re>-1&&Aa.value.splice(re,1)}finally{Ee()}}},Ee=()=>{e.nextTick(()=>{const p=document.querySelector('.ocr-upload-input input[type="file"]');p&&(p.value="")})},ia=async()=>{var B,I;if(sessionStorage.setItem("ocr_root_table_id",String((u==null?void 0:u.index)??"")),Aa.value.length===0){Wa.ElMessage.warning("请先选择要上传的图片");return}if(Aa.value.filter(F=>{const D=Ol(F);return D!=="uploaded"&&D!=="completed"&&D!=="failed"}).length>0){Wa.ElMessage.warning("请等待所有文件上传完成后再开始识别");return}il.value=!0,na.value=0;let v=null;try{Aa.value.forEach(ea=>{tr(ea,"processing")});const F=Math.floor(Math.random()*10)+90;v=setInterval(()=>{na.value<F?na.value+=1:clearInterval(v)},50);const D=Aa.value.map(ea=>{var al,ka,ll;return{name:((al=ea.uploadResult)==null?void 0:al.name)||ea.name,url:((ka=ea.uploadResult)==null?void 0:ka.url)||"",fileName:((ll=ea.uploadResult)==null?void 0:ll.fileName)||ea.name}}),re=gr.extractTableHeaders(z.value),le=D.map(ea=>({name:(ea==null?void 0:ea.fileName)||(ea==null?void 0:ea.name),url:(ea==null?void 0:ea.url)||""})),q=await gr.recognize(le,re);if(console.log(q,"ocrResult"),clearInterval(v),v=null,(q==null?void 0:q.code)===500||(q==null?void 0:q.type)==="error"||!(q!=null&&q.result)){na.value=0,Aa.value.forEach(ea=>{tr(ea,"failed"),Vl(ea,0)}),Wa.ElMessage.error((q==null?void 0:q.message)||"OCR识别失败,请重试"),il.value=!1;return}na.value=F;const xe=Array.isArray(q==null?void 0:q.result)?q.result:[];if(xe.length===0){na.value=0,Aa.value.forEach(ea=>{tr(ea,"failed"),Vl(ea,0)}),Wa.ElMessage.warning("OCR识别未返回有效数据"),il.value=!1;return}const Ce=new Set,Ge=[];xe.forEach((ea,al)=>{const ka=ea!=null&&ea.数据&&typeof(ea==null?void 0:ea.数据)=="object"?ea.数据:{},ll=Array.isArray(ea==null?void 0:ea.图片信息)?ea.图片信息:[],ve=new Map;ll.forEach(ya=>{ya!=null&&ya.name&&ve.set(ya.name,ya.url||"")});const Pa={_index:al,_certType:(ea==null?void 0:ea.证书类型)||"",_certNo:(ea==null?void 0:ea.证书编号)||"",_ocrImages:ll,__ocrFieldMeta:{}};Object.entries(ka).forEach(([ya,Da])=>{let Ea="",N=0,G=[],Ve="";Da&&typeof Da=="object"&&!Array.isArray(Da)?(Ea=(Da==null?void 0:Da.value)??"",N=(Da==null?void 0:Da.score)??0,G=Array.isArray(Da==null?void 0:Da.bboxNorm)?Da==null?void 0:Da.bboxNorm:[],Ve=(Da==null?void 0:Da.imageName)||""):Array.isArray(Da)&&Da.length>=2?(Ea=Da[0]??"",N=Da[1]??0):(Ea=Da??"",N=0),Pa[ya]=Ea,Pa[`${ya}_accuracy`]=N,Ce.add(ya),Pa.__ocrFieldMeta[ya]={value:Ea,score:N,bboxNorm:G,imageName:Ve,imageUrl:Ve&&ve.get(Ve)||"",images:ll}}),Ge.push(Pa)});const He=[],Qe=new Set;Ge.forEach(ea=>{ea&&Ce.forEach(al=>{const ka=ea[`${al}_accuracy`];(typeof ka=="number"?ka>0:ka!=null&&String(ka).trim()!==""&&String(ka)!=="0")&&Qe.add(al)})}),Ce.forEach(ea=>{He.push({prop:ea,label:ea,editable:!0,minWidth:230}),Qe.has(ea)&&He.push({prop:`${ea}_accuracy`,label:"准确率",editable:!1,minWidth:100,isAccuracy:!0})}),Aa.value.forEach(ea=>{tr(ea,"completed")}),na.value=100,nl.value=He,la.value=Ge,wa.value=D,Oa.value=q;const ba=["出厂编号","设备名称","制造厂"],za=He.filter(ea=>ea&&!ea.isAccuracy&&typeof ea.prop=="string").map(ea=>ea.prop),$a=["出厂编号","设备名称","制造厂"];Me.value=za.filter(ea=>$a.includes(ea)),console.log("[OCR] 默认勾选字段 props:",Me.value),Ga.value=2,il.value=!1,Sa.value=!1}catch(F){console.error("OCR处理失败:",F),v&&(clearInterval(v),v=null),Wa.ElMessage.error(((I=(B=F==null?void 0:F.response)==null?void 0:B.data)==null?void 0:I.message)||"OCR识别失败,请重试"),il.value=!1,na.value=0,Aa.value.forEach(D=>{tr(D,"pending"),Vl(D,0)})}},Ta=p=>{if(p==null)return"";let v=String(p);return v=v.replace(/\s+/g," ").trim(),v=v.replace(/[!-~]/g,B=>String.fromCharCode(B.charCodeAt(0)-65248)),v=v.replace(/ /g," "),v=v.replace(/^(编号|No\.?|NO\.?|no\.?|SN\.?|sn\.?|序列号)\s*[::]?\s*/i,""),v},el=()=>{var ea,al;const p=wa.value,v=Oa.value,B=la.value;if(!B||B.length===0){Wa.ElMessage.warning("暂无数据可添加");return}const I=(ea=oe.getAllLeafNodes(z.value)||[])==null?void 0:ea.filter(ka=>(ka==null?void 0:ka.type)!=="operate"&&(ka==null?void 0:ka.label)!=="操作"&&(ka==null?void 0:ka.prop)!=="operate"),F=new Map,D=new Map,re=(al=I==null?void 0:I.find(ka=>(ka==null?void 0:ka.label)==="证书附件"))==null?void 0:al.prop;I==null||I.forEach(ka=>{ka!=null&&ka.label&&(ka!=null&&ka.prop)&&(F.set(ka.label,ka.prop),D.set(ka.prop,ka.label))});const le=Date.now(),q=ka=>String(le*1e3+ka),xe=[],Ce=[],Ge=ka=>{const ll=zo&&zo[ka]||[ka];for(const ve of ll){const Pa=F.get(ve);if(Pa)return Pa}return""},He=Ge("出厂编号"),Qe=Ge("设备名称"),ba=Ge("制造厂"),za=[],$a=ka=>{var Ea,N;if(!re)return[];const ll=(Array.isArray(p)?p[ka]:null)||null,ve=(ll==null?void 0:ll.url)||"",Pa=(ll==null?void 0:ll.fileName)||(ll==null?void 0:ll.name)||"";return(String(Pa).toLowerCase().endsWith(".pdf")||String(ve).toLowerCase().endsWith(".pdf"))&&ve?[{url:ve,name:Pa,fileName:Pa}]:(Array.isArray((N=(Ea=v==null?void 0:v.result)==null?void 0:Ea[ka])==null?void 0:N.图片信息)?v.result[ka].图片信息:[]).map(G=>({url:(G==null?void 0:G.url)||"",name:(G==null?void 0:G.name)||"",fileName:(G==null?void 0:G.name)||""})).filter(G=>G.url)};if(B.forEach((ka,ll)=>{var tl;const ve={id:q(ll),_isOCRRow:!0,_ocrTableId:u==null?void 0:u.index};for(const[Ya,fl]of F.entries())Object.prototype.hasOwnProperty.call(ka,Ya)&&(ve[fl]=ka[Ya]);re&&(ve[re]=$a(ll));const Pa=(Array.isArray(v==null?void 0:v.result)?v.result[ll]:null)||null,ya=(Array.isArray(p)?p[ll]:null)||null,Da=(ya==null?void 0:ya.url)||"",Ea=(ya==null?void 0:ya.fileName)||(ya==null?void 0:ya.name)||"",N=String(Ea).toLowerCase().endsWith(".pdf")||String(Da).toLowerCase().endsWith(".pdf"),G={ts:Date.now(),versionId:String(Date.now())+"_"+String(ll),label:new Date().toLocaleString(),certType:(Pa==null?void 0:Pa.证书类型)||"",certNo:(Pa==null?void 0:Pa.证书编号)||"",fileType:N?"pdf":"image",sourceUrl:N?Da:"",images:Array.isArray(Pa==null?void 0:Pa.图片信息)?Pa.图片信息.map(Ya=>({name:(Ya==null?void 0:Ya.name)||"",url:(Ya==null?void 0:Ya.url)||""})).filter(Ya=>Ya.url):[]},Ve=Ya=>Ta(Ya?ve==null?void 0:ve[Ya]:""),sa=Ve(He),we=Ve(Qe),da=Ve(ba);if(!!(He&&Qe&&ba&&sa&&we&&da)){const Ya=(Ae.value||[]).find(fl=>{const vl=Ta(He?fl==null?void 0:fl[He]:""),ql=Ta(Qe?fl==null?void 0:fl[Qe]:""),Ua=Ta(ba?fl==null?void 0:fl[ba]:"");return vl&&ql&&Ua&&vl===sa&&ql===we&&Ua===da});if(Ya){za.push({idx:ll,ocrRow:ve,versionItem:G,ocrNo:sa,candidates:[Ya],selectedTargetId:String((Ya==null?void 0:Ya.id)??""),__decision:"replace",allowAdd:!1,allowReplace:!0});return}}if(sa&&He){const Ya=(Ae.value||[]).filter(fl=>{const vl=Ta(He?fl==null?void 0:fl[He]:"");return vl&&vl===sa});if(Ya.length>0){za.push({idx:ll,ocrRow:ve,versionItem:G,ocrNo:sa,candidates:Ya,selectedTargetId:"",__decision:"",allowAdd:!0,allowReplace:!0});return}}try{if(ve.sort===void 0||ve.sort===null||String(ve.sort).trim()===""){const Ya=(Ae.value||[]).map(vl=>li(vl==null?void 0:vl.sort)).filter(vl=>vl!==null),fl=Ya.length>0?Math.max(...Ya):((tl=Ae.value)==null?void 0:tl.length)??0;ve.sort=String(Number((fl+1).toFixed(6)))}}catch{}aa(u==null?void 0:u.index,ve.id,G),za.push({idx:ll,ocrRow:ve,versionItem:G,ocrNo:sa,candidates:[],selectedTargetId:"",__decision:"add",allowAdd:!0,allowReplace:!1})}),(za||[]).length>0){pr.value=(za||[]).map(ka=>({...ka,selectedTargetId:(ka==null?void 0:ka.selectedTargetId)||""})),Sl.value=!0,ga.value=Ce,Zl.value=xe,Sr.value=v,Cr.value=p,Oe.value=re||"";return}},Ja=(p,v,B)=>{la.value[p]&&(la.value[p][v]=B)},ol=p=>p==null||p===0?"-":`${(Number(p)*100).toFixed(1)}%`,El=p=>{if(p==null||p===0)return"#909399";const v=Number(p);return v>=.9?"#67c23a":v>=.7?"#e6a23c":"#f56c6c"},bl=p=>{var B,I,F,D;if(Ra.value===p){Ra.value=null,Bl.value=!1,Va.value="";return}Ra.value=p,Va.value="";const v=(B=la.value)==null?void 0:B[p];if(v&&Array.isArray(v._ocrImages)&&v._ocrImages.length>0){We.value=v._ocrImages.map(q=>({name:(q==null?void 0:q.name)||"",url:(q==null?void 0:q.url)||""})).filter(q=>q.name||q.url);const re=v.__ocrFieldMeta||{},le=(I=Object.values(re))==null?void 0:I.find(q=>q==null?void 0:q.imageName);Ma.value=(le==null?void 0:le.imageName)||((D=(F=We.value)==null?void 0:F[0])==null?void 0:D.name)||"",Bl.value=We.value.length>0}else We.value=[],Bl.value=!1,Ma.value=""},Ml=()=>{ma.value=!1,Aa.value=[],sl.value=null,Ga.value=1,hl.value.clear(),pe.value.clear(),na.value=0,Bl.value=!1},Kl=p=>p.raw?URL.createObjectURL(p.raw):p.url?p.url:"",Ol=p=>{const v=p.uid||p.name;return hl.value.get(v)||"pending"},Pl=p=>{const v=p.uid||p.name;return pe.value.get(v)||0},Vl=(p,v)=>{const B=p.uid||p.name;pe.value.set(B,Math.min(100,Math.max(0,v)))},rn=p=>{const v=Ol(p),B=100.53;if(v==="completed"||v==="uploaded")return`${B} ${B}`;if(v==="failed")return`${B} ${B}`;if(v==="uploading"){const I=Pl(p);return`${B*(I/100)} ${B}`}else if(v==="processing")return`${B*.5} ${B}`;return`0 ${B}`},tr=(p,v)=>{const B=p.uid||p.name;hl.value.set(B,v),(v==="completed"||v==="uploaded")&&Vl(p,100)},un=()=>{e.nextTick(()=>{const p=document.querySelector('.ocr-upload-input input[type="file"]');if(p)p.value="",p.click();else{const v=document.createElement("input");v.type="file",v.multiple=!0,v.accept="image/*,application/pdf",v.style.display="none",v.onchange=async B=>{const I=Array.from(B.target.files||[]);for(const F of I){const D={name:F.name,raw:F,uid:Date.now()+Math.random()};Aa.value.push(D),await je(D)}B.target.value="",document.body.removeChild(v)},document.body.appendChild(v),v.click()}})},kn=()=>{Ga.value>1&&Ga.value--},Tn=()=>{Ga.value===1?Aa.value.length>0&&!il.value&&ia():Ga.value===2&&(el(),Ga.value=3)},bi=async p=>{await Ot(p==null?void 0:p.row)},ii=async({row:p,prop:v})=>{!p||!v||await Ot(p,v)},Ot=async(p,v)=>{var F,D;const B=p==null?void 0:p.id;if(!B){Wa.ElMessage.warning("暂无可预览数据");return}let I=Cl(u==null?void 0:u.index,B);if(!I||I.length===0){const re=sessionStorage.getItem("ocr_root_table_id"),le=re!==null?Number(re):null;if(le!=null&&le!==""&&!Number.isNaN(le)){const q=Cl(le,B);Array.isArray(q)&&q.length>0&&(Yl(u==null?void 0:u.index,B,q),I=q)}}if(!I||I.length===0){const re=(F=oe.getAllLeafNodes(z.value)||[])==null?void 0:F.filter(q=>(q==null?void 0:q.type)!=="operate"&&(q==null?void 0:q.label)!=="操作"&&(q==null?void 0:q.prop)!=="operate"),le=v||((D=re==null?void 0:re.find(q=>(q==null?void 0:q.label)==="证书附件"))==null?void 0:D.prop);if(le&&p[le]){const q=p[le];let xe=[],Ce="",Ge=!1;if(typeof q=="string")try{const He=JSON.parse(q);Array.isArray(He)&&(xe=He.map(Qe=>({name:(Qe==null?void 0:Qe.name)||(Qe==null?void 0:Qe.fileName)||"",url:(Qe==null?void 0:Qe.url)||""})).filter(Qe=>Qe.url||Qe.name),xe.length>0&&(Ce=xe[0].url||"",Ge=String(xe[0].name).toLowerCase().endsWith(".pdf")||String(Ce).toLowerCase().endsWith(".pdf")))}catch{Ce=q,Ge=String(q).toLowerCase().endsWith(".pdf"),xe=[{name:q,url:q}]}else Array.isArray(q)&&(xe=q.map(He=>({name:(He==null?void 0:He.name)||(He==null?void 0:He.fileName)||"",url:(He==null?void 0:He.url)||""})).filter(He=>He.url||He.name),xe.length>0&&(Ce=xe[0].url||"",Ge=String(xe[0].name).toLowerCase().endsWith(".pdf")||String(Ce).toLowerCase().endsWith(".pdf")));if(xe.length>0||Ce){const He={ts:Date.now(),versionId:String(Date.now()),label:new Date().toLocaleString(),certType:p.证书类型||"",certNo:p.证书编号||"",fileType:Ge?"pdf":"image",sourceUrl:Ge?Ce:"",images:xe};I=[He],aa(u==null?void 0:u.index,B,He)}}}if(!I||I.length===0){Wa.ElMessage.warning("暂无可预览数据");return}qe.value=I,rl.value=!0},uu=p=>{Aa.value=Aa.value.filter((v,B)=>B!==p)},st=async(p,v,B)=>{var I,F,D,re,le,q,xe,Ce,Ge,He,Qe,ba,za,$a,ea,al,ka,ll,ve,Pa,ya;if(xa(u.config,{type:Fe.TABLE,tableOperate:p})){if(Ia.value="",Qa.value=!0,fa.value=!0,_e("onButtonClick",p,v),ee.value=[],p==="删除")A.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var Da,Ea,N,G;(Da=Ae.value)!=null&&Da.find(Ve=>(Ve==null?void 0:Ve.id)===(v==null?void 0:v.id))?Ae.value=(Ea=A.cloneDeep(Ae.value))==null?void 0:Ea.filter(Ve=>(Ve==null?void 0:Ve.id)!==(v==null?void 0:v.id)):Ae.value=po(A.cloneDeep(Ae.value),v);try{v!=null&&v.id&&((G=(N=La.value)==null?void 0:N.has)!=null&&G.call(N,v==null?void 0:v.id))&&La.value.delete(v.id)}catch{}Vf(jr.value,Wr.value,v==null?void 0:v.id),ua.setTableLoading(u==null?void 0:u.index),_e("change",{content:Ae.value,fixContent:[v],index:u==null?void 0:u.index,type:"delete",name:u==null?void 0:u.groupNames,buttonName:p,columns:z.value,relatedContents:u==null?void 0:u.related}),console.log(v,"item")});else if(p==="批量删除"){if(((I=Wl.value)==null?void 0:I.length)===0)return Wa.ElMessage.warning("请先勾选操作的数据");A.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(async()=>{var N,G,Ve,sa,we;const Da=(N=Wl.value)==null?void 0:N.map(da=>da.id);Ae.value=(G=A.cloneDeep(Ae.value))==null?void 0:G.filter(da=>!(Da!=null&&Da.includes(da.id))),ua.setTableLoading(u==null?void 0:u.index),_e("change",{content:Ae.value,fixContent:Wl.value,index:u==null?void 0:u.index,type:"delete",name:u==null?void 0:u.compName,buttonName:p,relatedContents:u==null?void 0:u.related,columns:z.value});const Ea=(Da||[]).filter(Boolean);if(Ea.length>0&&Ea.every(da=>da!=null&&da!=="")){const da=(Wl.value||[]).map(Na=>{const tl={...Na};return delete tl._isOCRRow,delete tl._ocrTableId,delete tl._isTemp,delete tl.tableEditType,delete tl.index,tl});await A.pageBatchDeleteApi({platId:parseInt((Ve=ml.value)==null?void 0:Ve.plat_id),changeContents:[{tableName:((sa=u==null?void 0:u.related)==null?void 0:sa.find(Na=>Na==null?void 0:Na.includes("content_")))||((we=u==null?void 0:u.related)==null?void 0:we.find(Na=>Na==null?void 0:Na.includes("content"))),tableContents:da}]})}})}else if(p==="复制新增"){be.value="复制新增",A.cloneDeep(v);const Da=(F=z.value)==null?void 0:F.find(Ea=>Ea==null?void 0:Ea.isMainKey);Da||((D=z.value)==null||D[0]),Il.value=v,Hi(!0)}else if(p==="新增")be.value="新增",Fi(""),Be.value=!0;else if(p==="编辑")be.value="编辑",Fi(v),Be.value=!0;else if(p==="查看")be.value="查看",Fi(v),Qa.value=!1,fa.value=!1,Be.value=!0;else if(p==="查看三维模型"){const Da={};for(let N in v)N!=="id"&&(Da[N]=v[N]);let Ea=(re=Object.values(Da))==null?void 0:re[1];Ke.setTableShowThree(Ea)}else if(p==="切换视图")_u();else if(((le=B==null?void 0:B.extra)==null?void 0:le.type)==="modelExample")be.value=p,Xe.value=!0;else if(p==="新建"){let Da=fe.value,Ea=[];for(let we in Da)we!=null&&we.includes(`loading${((q=ml.value)==null?void 0:q.account)||((xe=ml.value)==null?void 0:xe.账号)}`)&&(Ea=[...Ea,...we]);let N=[];for(let we in Da)we!=null&&we.includes(`updateLoading${((Ce=ml.value)==null?void 0:Ce.account)||((Ge=ml.value)==null?void 0:Ge.账号)}`)&&(N=[...N,...we]);let G=Ea==null?void 0:Ea.map(we=>we==null?void 0:we.id);const Ve=N==null?void 0:N.map(we=>we==null?void 0:we.id);G=[...A.cloneDeep(G),...Ve],(G==null?void 0:G.length)>0&&(G!=null&&G.every(we=>we!==null&&we))&&await Rr.batchDeleteInsofDataApi({ids:G});const sa=(He=Ue.value)==null?void 0:He.find(we=>(we==null?void 0:we.label)==="新建");await fu(!1,sa)}else if(p==="修改模板"){let Da=A.cloneDeep(Se).value;ua.setRouteToChildPath(Da),ue.setActiveMenuPath(Da+E)}else if(p==="执行")tt(p,v);else if(p==="导出paraform"){const Da=A.ElLoading.service({lock:!0,text:"正在导出paraform...",background:"rgba(0, 0, 0, 0.7)"});try{const Ea=["推力","真空","压力","温度","流量"],N=wl=>{var $l,er,Rl;return wl?typeof(wl==null?void 0:wl.value)=="string"?wl.value:((Rl=(er=($l=wl==null?void 0:wl._custom)==null?void 0:$l.value)==null?void 0:er.value)==null?void 0:Rl.value)||"":""},G=Array.isArray(rr.value)?rr.value:[],Ve=N(G.find(wl=>(wl==null?void 0:wl.condition)==="child")),sa=String(Ve||"").slice(0,8),we=wl=>{if(wl==null)return"";const $l=String(wl).trim();if(!$l)return"";if(/^\d{8}$/.test($l))return $l;const er=$l.match(/^(\d{4})[-\/.](\d{1,2})[-\/.](\d{1,2})$/);if(er){const Ql=er[1],sr=er[2].padStart(2,"0"),Jl=er[3].padStart(2,"0");return`${Ql}${sr}${Jl}`}const Rl=$l.replace(/\D/g,"");return Rl.length>=8?Rl.slice(0,8):""},da=async wl=>{var $l,er;if(!wl)return"";try{const Rl=await Jr("试验任务/任务管理",!1),Ql=(wr,fr=[])=>{if(!Array.isArray(wr))return fr;for(const mr of wr)(mr==null?void 0:mr.comp)==="Table"&&(mr!=null&&mr.name)&&fr.push(mr),Array.isArray(mr==null?void 0:mr.children)&&Ql(mr.children,fr),Array.isArray(mr==null?void 0:mr.tab)&&Ql(mr.tab,fr),Array.isArray(mr==null?void 0:mr.choice)&&Ql(mr.choice,fr);return fr},Jl=Ql(Rl||[]).find(wr=>(wr==null?void 0:wr.name)==="任务列表"),xr=((er=($l=Jl==null?void 0:Jl.compData)==null?void 0:$l.find(wr=>(wr==null?void 0:wr.key)==="tableContents"))==null?void 0:er.contents)||[];if(!Array.isArray(xr)||xr.length===0)return"";const on=xr.find(wr=>String((wr==null?void 0:wr["试验代号(名称)"])||"").slice(0,8)===wl);return we(on==null?void 0:on.计划试验时间)}catch(Rl){return console.warn("获取任务列表计划试验时间失败:",Rl),""}},Na=(Se.value||"").replace(/\/+$/,""),tl=Ve?`${Na}/${Ve}`:Na,Ya=await Jr(tl||Se.value,!1),fl=String(ta.value||"").trim(),vl=wl=>String(wl||"").trim(),ql=(wl,$l=[],er="")=>{if(!Array.isArray(wl))return $l;for(const Rl of wl){const Ql=vl((Rl==null?void 0:Rl.choiceName)||(Rl==null?void 0:Rl.name0)||er);(Rl==null?void 0:Rl.comp)==="Table"&&(Rl==null?void 0:Rl.name)&&Ea.includes(Rl.name)&&(!fl||Ql===fl)&&$l.push(Rl),Array.isArray(Rl==null?void 0:Rl.children)&&ql(Rl.children,$l,Ql),Array.isArray(Rl==null?void 0:Rl.tab)&&ql(Rl.tab,$l,Ql),Array.isArray(Rl==null?void 0:Rl.choice)&&ql(Rl.choice,$l,Ql)}return $l},Ua=ql(Ya||[]),kl=new Map;for(const wl of Ua)wl!=null&&wl.name&&!kl.has(wl.name)&&kl.set(wl.name,wl);const ja=Ea.map(wl=>kl.get(wl)).filter(Boolean);if(!ja||ja.length===0)return Wa.ElMessage.warning("未找到需要导出的表(推力、真空、压力、温度、流量)");const dl=wl=>{const $l=new Map,er=(Rl,Ql=[])=>{if(Array.isArray(Rl))for(const sr of Rl){const Jl=((sr==null?void 0:sr.label)??"").toString().trim(),xr=Jl?[...Ql,Jl]:[...Ql];if(Array.isArray(sr==null?void 0:sr.children)&&sr.children.length>0)er(sr.children,xr);else{const wr=((sr==null?void 0:sr.prop)??"").toString();if(!wr)continue;const fr=Jl||wr,mr=(xr.length>0?[...Ql,fr]:[fr]).join(".");$l.set(wr,mr)}}};return er(wl,[]),$l},Xa=(wl,$l)=>{const er=dl(wl||[]),Ql=(oe.getAllLeafNodes(wl||[])||[]).filter(Jl=>(Jl==null?void 0:Jl.prop)&&(Jl==null?void 0:Jl.type)!=="operate"&&(Jl==null?void 0:Jl.label)!=="操作"&&(Jl==null?void 0:Jl.prop)!=="operate"),sr=Array.isArray($l)?$l:[];return sr.length===0?[]:sr.map(Jl=>{const xr={};return Ql.forEach(on=>{const wr=String(on.prop),fr=er.get(wr)||String(on.label||on.prop);xr[fr]=(Jl==null?void 0:Jl[wr])??""}),xr})},pl=ja.map(wl=>{var sr,Jl;const $l=(wl==null?void 0:wl.compData)||[];let er=(sr=$l==null?void 0:$l.find(xr=>(xr==null?void 0:xr.key)==="header"))==null?void 0:sr.contents;Array.isArray(er==null?void 0:er[0])&&(er=er[0]);const Rl=((Jl=$l==null?void 0:$l.find(xr=>(xr==null?void 0:xr.key)==="tableContents"))==null?void 0:Jl.contents)||[];if(!Array.isArray(er)||er.length===0||!Array.isArray(Rl)||Rl.length===0)return null;const Ql=Xa(er||[],Rl||[]);return!Array.isArray(Ql)||Ql.length===0?null:{类型:wl==null?void 0:wl.name,数据:Ql}}).filter(Boolean);if(!pl||pl.length===0)return Wa.ElMessage.warning("没有可导出的数据(推力、真空、压力、温度、流量均为空)");const Nl=await da(sa),Ll={试验代号:sa,试验日期:Nl,ParaForm:pl},Nr=await yi().catch(()=>""),Hl=await A.exportParaformApi(Ll,Nr);if(((Qe=Hl==null?void 0:Hl.data)==null?void 0:Qe.code)===200&&((za=(ba=Hl==null?void 0:Hl.data)==null?void 0:ba.result)!=null&&za.Excel文件)){const wl=Hl.data.result.Excel文件,$l=await A.platformDownloadFile({url:wl}),er=new Blob([$l.data],{type:"application/vnd.ms-excel"}),Rl=URL.createObjectURL(er),Ql=A.dayjs().format("YYYYMMDD"),Jl=`${(sa||"UNKNOWN").trim()||"UNKNOWN"}_${Ql}_paraform.xls`,xr=document.createElement("a");xr.href=Rl,xr.download=Jl,xr.style.display="none",document.body.appendChild(xr),xr.click(),setTimeout(()=>{document.body.removeChild(xr),URL.revokeObjectURL(Rl)},100);const on=Array.isArray((ea=($a=Hl==null?void 0:Hl.data)==null?void 0:$a.result)==null?void 0:ea.warnings)?Hl.data.result.warnings:[];if(on.length>0){const wr=on.map((fr,mr)=>`${mr+1}. ${(fr==null?void 0:fr.field)||"未知字段"}:${(fr==null?void 0:fr.message)||""}`).join(`
|
|
24
|
-
`);Wa.ElMessage.warning({message:`导出成功,但存在以下提示:
|
|
25
|
-
${wr}`,duration:5e3,showClose:!0})}else Wa.ElMessage.success("导出成功")}else Wa.ElMessage.error(((al=Hl==null?void 0:Hl.data)==null?void 0:al.message)||"导出失败")}catch(Ea){console.error("导出paraform失败:",Ea),Wa.ElMessage.error("导出失败:"+((Ea==null?void 0:Ea.message)||"未知错误"))}finally{Da.close()}}else if(p!=null&&p.includes("导出")&&p!=="导出paraform"){if(p==="导出选中"&&((ka=Wl.value)==null?void 0:ka.length)===0)return Wa.ElMessage.warning(`请先勾选${p}的数据`);if(p==="导出全部"&&((ll=Ae.value)==null?void 0:ll.length)===0)return Wa.ElMessage.warning("暂无数据导出");let Da=["序号",...(Pa=(ve=z.value)==null?void 0:ve.map(Ve=>Ve==null?void 0:Ve.prop))==null?void 0:Pa.filter(Ve=>Ve!=="操作")],Ea=p==="导出全部"?Ae.value:Wl.value;const N=["id","sort","tableEditType","create_time","update_time","source_table","create_user_id","update_user_id","department_id","relatedId"];Ea=Ea==null?void 0:Ea.map(Ve=>Object.fromEntries(Object.entries(Ve).filter(([sa])=>!N.includes(sa)))),Da=["序号",...Da],Ea=Ea==null?void 0:Ea.map((Ve,sa)=>({序号:sa+1,...Ve}));let G=(u==null?void 0:u.compName)||"表格信息";Wo(Ea,G,Da,G)}else if(p==="OCR识别")ma.value=!0,Aa.value=[],Ga.value=1,hl.value.clear(),pe.value.clear(),na.value=0;else if(p==="迁移")f.selectRow=v,f.show=!0;else if(p==="生成方法"){let Da=await r0(v),Ea;v!==""?Ea=[v]:Ea=A.cloneDeep(Ae.value),Ea=Ea==null?void 0:Ea.map(G=>(G.输出值=Da,G));const N={fixContent:Ea,buttonName:"编辑",relatedContents:u==null?void 0:u.related,columns:z.value,name:u==null?void 0:u.groupNames};_e("change",N)}else if(((ya=B==null?void 0:B.extra)==null?void 0:ya.type)==="methodButton"){let Da;v!==""?Da=[v]:Da=A.cloneDeep(Ae.value);const N={fixContent:await wt(Da,z==null?void 0:z.value,"Manual",Ae.value),buttonName:"methodButton",relatedContents:u==null?void 0:u.related,columns:z.value,name:u==null?void 0:u.groupNames};_e("change",N)}}},du=async(p,v)=>{var B,I,F,D,re,le,q,xe,Ce,Ge,He,Qe,ba,za,$a,ea,al,ka,ll,ve;try{let Pa,ya;const Da=(B=fe.value[Se.value+E])==null?void 0:B.filter(Na=>{var tl;return((tl=Na==null?void 0:Na.key)==null?void 0:tl.type)==="structureMethod"}),Ea=(I=fe.value[Se.value+E])==null?void 0:I.filter(Na=>{var tl;return((tl=Na==null?void 0:Na.key)==null?void 0:tl.type)==="structure"}),N=Da==null?void 0:Da.find(Na=>{var tl,Ya;return((Ya=(tl=Na==null?void 0:Na.value)==null?void 0:tl.pageData)==null?void 0:Ya.method)==="保存"});if(!N)return;const G=(le=(re=fe.value[(D=(F=N==null?void 0:N.value)==null?void 0:F.pageData)==null?void 0:D.path])==null?void 0:re.filter(Na=>{var tl;return((tl=Na==null?void 0:Na.key)==null?void 0:tl.type)==="data"}))==null?void 0:le.find(Na=>{var tl,Ya,fl,vl;return((Ya=(tl=Na==null?void 0:Na.value)==null?void 0:tl.tableData)==null?void 0:Ya.算法名称)===((vl=(fl=N==null?void 0:N.value)==null?void 0:fl.pageData)==null?void 0:vl.method)});if(!G)return;const Ve={buttonName:(xe=(q=N==null?void 0:N.value)==null?void 0:q.pageData)==null?void 0:xe.method,api:(Ge=(Ce=G==null?void 0:G.value)==null?void 0:Ce.tableData)==null?void 0:Ge.算法体,content:Ea==null?void 0:Ea.map(Na=>{var tl;return(tl=Na==null?void 0:Na.value)==null?void 0:tl.pageData}),extraContent:[],extraValues:(Qe=(He=N==null?void 0:N.value)==null?void 0:He.pageData)==null?void 0:Qe.data,methodName:(za=(ba=N==null?void 0:N.value)==null?void 0:ba.pageData)==null?void 0:za.path};if(!p)return;const sa={...p,compData:($a=p==null?void 0:p.compData)==null?void 0:$a.map(Na=>{var tl;return(Na==null?void 0:Na.key)==="formContent"?{...Na,contents:(tl=Na==null?void 0:Na.contents)==null?void 0:tl.map(Ya=>(Ya==null?void 0:Ya.prop)===v?{...Ya,value:""}:Ya)}:Na})},we={key:{pageKey:Se.value+E,parentTable:"",systemKey:sessionStorage.getItem("systemKey"),type:"structure"},value:{pageData:sa}},da=await Wa.axios.post(Ve.api,we,{headers:{"Content-Type":"application/json"}});return((ea=da==null?void 0:da.data)==null?void 0:ea.code)===200&&(Pa=(ka=(al=da==null?void 0:da.data)==null?void 0:al.result)==null?void 0:ka.latestReportCode,ya=(ve=(ll=da==null?void 0:da.data)==null?void 0:ll.result)==null?void 0:ve.status),{newMainKeyValue:Pa,newStatus:ya}}catch(Pa){throw Wa.ElMessage.error(Pa),new Error(Pa)}},Lt=e.reactive({prop:"状态",value:""});e.ref(["系统自动生成信息","审批意见"]);const pu=async(p,v,B)=>{var q,xe;let I=p==null?void 0:p[v==null?void 0:v.prop],F=1,D,re;const le=A.cloneDeep(Se).value+E+I;if(le){Lt.value="",D=(q=fe.value[le])==null?void 0:q.filter(He=>{var Qe;return((Qe=He==null?void 0:He.key)==null?void 0:Qe.type)==="structure"});const Ce=D==null?void 0:D.find(He=>{var Qe,ba,za;return((za=(ba=(Qe=He==null?void 0:He.value)==null?void 0:Qe.pageData)==null?void 0:ba.comp)==null?void 0:za.toUpperCase())==="FORM"});re={...(xe=Ce==null?void 0:Ce.value)==null?void 0:xe.pageData,id:Ce==null?void 0:Ce.id};const Ge=await du(re,v==null?void 0:v.prop);if(Lt.value=Ge==null?void 0:Ge.newStatus,Ge!=null&&Ge.newMainKeyValue)return Ge==null?void 0:Ge.newMainKeyValue}if(Ae.value.some(Ce=>(Ce==null?void 0:Ce[v==null?void 0:v.prop])===I)){const Ce=I;for(;Ae.value.some(Ge=>(Ge==null?void 0:Ge[v==null?void 0:v.prop])===`${Ce}(${F})`);)F++;I=`${Ce}(${F})`}return I},fu=async(p,v,B)=>{var D,re,le,q;let I,F;if(await pu(B==null?void 0:B.data,B==null?void 0:B.firstCol),I=A.cloneDeep(Se).value+E,F=A.cloneDeep(I)+`loading${((D=ml.value)==null?void 0:D.account)||((re=ml.value)==null?void 0:re.账号)}`,v){const xe=(q=(le=fe.value[F])==null?void 0:le.filter(Ce=>{var Ge;return((Ge=Ce==null?void 0:Ce.key)==null?void 0:Ge.parentTable)===""}))==null?void 0:q.map(Ce=>{var Ge;return{id:Ce==null?void 0:Ce.id,...(Ge=Ce==null?void 0:Ce.value)==null?void 0:Ge.pageData}});(xe==null?void 0:xe.length)>0||await oe.loadingConstruct(I,F,null,null,null),ua.setRouteToChildPath(A.cloneDeep(Se).value),ue.setActiveMenuPath(F)}else ua.setRouteToChildPath(A.cloneDeep(Se).value),ue.setActiveMenuPath(F)},hu=()=>{$e.value=!1,Pe.value=[],de.value=!1},Fi=p=>{var D,re,le,q,xe,Ce,Ge,He,Qe,ba,za,$a,ea,al,ka,ll,ve,Pa,ya,Da,Ea;const v=[];ye.value=A.cloneDeep(z.value),(re=oe.getColumnChild((D=A.cloneDeep(z.value))==null?void 0:D.filter(N=>(N==null?void 0:N.label)!=="操作")))==null||re.forEach((N,G)=>{var Ve,sa,we;N!=null&&N.formType&&((Ve=N==null?void 0:N.formType)==null?void 0:Ve.toUpperCase())==="SELECT"||N!=null&&N.menuId?v.push({label:(sa=N==null?void 0:N.prop)!=null&&sa.includes(".")?N==null?void 0:N.prop:(N==null?void 0:N.label)??(N==null?void 0:N.prop)??"",name:(N==null?void 0:N.prop)??"t"+G,prop:N==null?void 0:N.prop,type:"Select",value:(p==null?void 0:p[N==null?void 0:N.prop])??(N==null?void 0:N.value)??"",id:(N==null?void 0:N.id)??G,contents:(N==null?void 0:N.options)??[],multiple:(N==null?void 0:N.multiple)??!1,multipleLimit:N==null?void 0:N.multipleLimit,width:1,isFormColHidden:N==null?void 0:N.isFormColHidden,relatedValueId:N==null?void 0:N.relatedValueId,disabled:N==null?void 0:N.disabled,menus:N==null?void 0:N.menus,groups:N==null?void 0:N.groups,words:N==null?void 0:N.words,allSelectionContents:(N==null?void 0:N.allSelectionContents)??[],filterContent:N==null?void 0:N.filterContent,disabled:(N==null?void 0:N.prop)==="disabled"?!0:N==null?void 0:N.disabled,filter:N==null?void 0:N.filter,bindMenus:N==null?void 0:N.bindMenus,isMainPath:N==null?void 0:N.isMainPath,required:(N==null?void 0:N.required)??!1,relatedContents:N==null?void 0:N.relatedContents,mainKey:N==null?void 0:N.mainKey,relatedContents:N==null?void 0:N.relatedContents,functionName:N==null?void 0:N.functionName,functionRelatedWords:N==null?void 0:N.functionRelatedWords,calculatorFilter:N==null?void 0:N.calculatorFilter,isReadonly:N==null?void 0:N.isReadonly}):v.push({label:(we=N==null?void 0:N.prop)!=null&&we.includes(".")?N==null?void 0:N.prop:(N==null?void 0:N.label)??(N==null?void 0:N.prop)??"",prop:N==null?void 0:N.prop,name:(N==null?void 0:N.prop)??"t"+G,type:!(N!=null&&N.formType)||(N==null?void 0:N.formType)===""?"Input":N==null?void 0:N.formType,value:(N==null?void 0:N.formType)==="Upload"?(p==null?void 0:p[N==null?void 0:N.prop])??"{}":(p==null?void 0:p[N==null?void 0:N.prop])??(N==null?void 0:N.value)??"",id:(N==null?void 0:N.id)??G,contents:(N==null?void 0:N.options)??[],multiple:(N==null?void 0:N.multiple)??!1,width:1,isFormColHidden:N==null?void 0:N.isFormColHidden,disabled:(N==null?void 0:N.prop)==="disabled"?!0:N==null?void 0:N.disabled,relatedValueId:N==null?void 0:N.relatedValueId,menus:N==null?void 0:N.menus,groups:N==null?void 0:N.groups,words:N==null?void 0:N.words,filter:N==null?void 0:N.filter,bindMenus:N==null?void 0:N.bindMenus,isMainPath:N==null?void 0:N.isMainPath,required:(N==null?void 0:N.required)??!1,relatedContents:N==null?void 0:N.relatedContents,mainKey:N==null?void 0:N.mainKey,relatedContents:N==null?void 0:N.relatedContents,functionName:N==null?void 0:N.functionName,functionRelatedWords:N==null?void 0:N.functionRelatedWords,calculatorFilter:N==null?void 0:N.calculatorFilter,isReadonly:N==null?void 0:N.isReadonly})}),p===""||!p||(Ia.value=(p==null?void 0:p.id)??"");let B=oe.getColumnChild((le=A.cloneDeep(z.value))==null?void 0:le.filter(N=>(N==null?void 0:N.label)!=="操作"));Ha.value&&((q=Ha.value)==null?void 0:q.length)>0&&(Ha.value=(xe=A.cloneDeep(Ha).value)==null?void 0:xe.map(N=>{var Ve;let G=(N==null?void 0:N.prop)||((Ve=B==null?void 0:B.find(sa=>(sa==null?void 0:sa.label)===(N==null?void 0:N.label)))==null?void 0:Ve.prop);return G&&(N.value=p[G]),N})),Ne.value=Ha.value&&((Ce=Ha.value)==null?void 0:Ce.length)>0?oe.getTableFormToForm(Ha.value):v,Ne.value=((Ge=Ne.value)==null?void 0:Ge.map(N=>({...N,disabled:(N==null?void 0:N.prop)==="disabled"?!0:N==null?void 0:N.disabled})))??Ne.value;let I=[],F=((ba=(Qe=(He=u.itemData)==null?void 0:He.filter(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:Qe[0])==null?void 0:ba.contents)??"";if(F=oe.analyzeSplitToContent(F,","),(F==null?void 0:F.length)>0&&(I=F.flat()),(I==null?void 0:I.length)>0){let N=I==null?void 0:I.filter(da=>da==null?void 0:da.includes("@Type"));if(N=N==null?void 0:N[(N==null?void 0:N.length)-1],(N==null?void 0:N[(N==null?void 0:N.length)-1])===","&&(N=N==null?void 0:N.slice(0,(N==null?void 0:N.length)-1)),N){let da=($a=(za=N==null?void 0:N.replace("=",w))==null?void 0:za.split(w))==null?void 0:$a[1];((ea=da==null?void 0:da.trim())==null?void 0:ea.toUpperCase())==="MANUAL"&&(u==null||u.index,Ne.value=(al=Ne.value)==null?void 0:al.map((Na,tl)=>Na))}let G=(ka=Ne.value)==null?void 0:ka.filter(da=>da==null?void 0:da.mainKey),Ve;G==null||G.forEach(da=>{var tl;if(Ve!==void 0)return;let Na=da==null?void 0:da.menus;((tl=G==null?void 0:G.filter(Ya=>Ya==null?void 0:Ya.mainKey))==null?void 0:tl.length)>1&&(Ve=Na,da==null||da.groups)});let sa=[],we=new Map;if(G==null||G.forEach(da=>{var Na,tl,Ya,fl,vl,ql,Ua,kl,ja,dl,Xa,pl,Nl;if((Na=da==null?void 0:da.prop)!=null&&Na.includes(".")){let Ll=[];we.get(((Ya=(tl=da==null?void 0:da.prop)==null?void 0:tl.split("."))==null?void 0:Ya[0])+(da!=null&&da.isMainPath?0:1)+((fl=da==null?void 0:da.groups)==null?void 0:fl[0]))&&(Ll=we.get(((ql=(vl=da==null?void 0:da.prop)==null?void 0:vl.split("."))==null?void 0:ql[0])+(da!=null&&da.isMainPath?0:1)+((Ua=da==null?void 0:da.groups)==null?void 0:Ua[0]))),Ll.push(da),we.set(((ja=(kl=da==null?void 0:da.prop)==null?void 0:kl.split("."))==null?void 0:ja[0])+(da!=null&&da.isMainPath?0:1)+((dl=da==null?void 0:da.groups)==null?void 0:dl[0]),Ll)}else{let Ll=[];we.get("normal"+(da!=null&&da.isMainPath?0:1)+((Xa=da==null?void 0:da.groups)==null?void 0:Xa[0]))&&(Ll=we.get("normal"+(da!=null&&da.isMainPath?0:1)+((pl=da==null?void 0:da.groups)==null?void 0:pl[0]))),Ll.push(da),we.set("normal"+(da!=null&&da.isMainPath?0:1)+((Nl=da==null?void 0:da.groups)==null?void 0:Nl[0]),Ll)}}),sa=Array.from(we.values()),(sa==null?void 0:sa.length)>0)for(let da in sa){let Na=sa==null?void 0:sa[da];if((Na==null?void 0:Na.length)!==1){if((Na==null?void 0:Na.length)>1){let tl=Na==null?void 0:Na.map(dl=>dl==null?void 0:dl.prop),Ya=Na==null?void 0:Na.map(dl=>dl==null?void 0:dl.label),fl=Na==null?void 0:Na.map(dl=>dl==null?void 0:dl.value),vl=(ll=A.cloneDeep(Na))==null?void 0:ll[0],ql=(ve=Ne.value)==null?void 0:ve.findIndex(dl=>(dl==null?void 0:dl.prop)===(vl==null?void 0:vl.prop)),Ua=(Pa=Ne.value)==null?void 0:Pa.slice(0,ql),kl=(Da=Ne.value)==null?void 0:Da.slice(ql,(ya=Ne.value)==null?void 0:ya.length);vl.label=Ya==null?void 0:Ya.join("·"),vl.value=fl==null?void 0:fl.join(" "),vl.value.trim()===""&&(vl.value=""),vl.prop=tl==null?void 0:tl.join("·");let ja=Na==null?void 0:Na.map(dl=>{var Xa;return(Xa=dl==null?void 0:dl.words)==null?void 0:Xa.join(".")});vl.relatedWords=ja,vl.usingType="parent",kl.unshift(vl),Ne.value=[...Ua,...kl],Ne.value=(Ea=Ne.value)==null?void 0:Ea.map(dl=>(tl!=null&&tl.find(Xa=>Xa===(dl==null?void 0:dl.prop))&&(dl.isFormColHidden=!0,dl.relatedWords=ja),dl))}}}}},vu=()=>{var v;const p=(v=i.value)==null?void 0:v.$el;p&&Al.Sortable.create(p,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:B=>{var re;const{oldIndex:I,newIndex:F}=B;if(I===F)return;const D=bn.value.splice(I,1)[0];bn.value.splice(F,0,D),z.value=(re=z.value)==null?void 0:re.slice().sort((le,q)=>{if(le.label==="操作")return 1;if(q.label==="操作")return-1;const xe=bn.value.findIndex(Ge=>Ge.label===le.label),Ce=bn.value.findIndex(Ge=>Ge.label===q.label);return xe-Ce})}})};e.onMounted(()=>{Ze.value=window.innerWidth-240*2,window.addEventListener("keydown",ao)});const mu=()=>{e.nextTick(()=>{vu()})},yu=()=>{c.value=!0},ct=(p,v)=>{var I;if(!p&&!(p!=null&&p.children))return{contents:p,currentSelectContents:void 0};let B;return p.children=(I=p.children)==null?void 0:I.map(F=>{var D,re;if((F==null?void 0:F.id)===Ia.value){let le={};for(let q in F){let xe=(D=v==null?void 0:v.find(Ce=>(Ce==null?void 0:Ce.prop)===q))==null?void 0:D.label;xe?le[q]=(re=Il.value)==null?void 0:re[xe]:le[q]=F[q]??""}F=Object.assign(le,Il.value),B=F}else{let le=ct(F,v);F=le==null?void 0:le.contents,B=le==null?void 0:le.currentSelectContents}return F}),{contents:p,currentSelectContents:B}},Rt=(p,v)=>{let B,I;return p!=null&&p.find(F=>(F==null?void 0:F.id)===Ia.value)?B=p==null?void 0:p.map(F=>{var D,re,le;if((F==null?void 0:F.id)===Ia.value){let q={};for(let Ce in F){let Ge=(D=v==null?void 0:v.find(He=>(He==null?void 0:He.prop)===Ce))==null?void 0:D.label;Ge?q[Ce]=((re=Il.value)==null?void 0:re[Ge])??"":q[Ce]=F[Ce]??""}let xe=Il.value;for(let Ce in q)(le=Il.value)!=null&&le[Ce]||(xe[Ce]=(q==null?void 0:q[Ce])??"");F=xe,I=F}return F}):B=p==null?void 0:p.map(F=>{var D,re,le,q;if((F==null?void 0:F.id)===Ia.value){let xe={};for(let Ce in F){let Ge=(D=v==null?void 0:v.find(He=>(He==null?void 0:He.prop)===Ce))==null?void 0:D.label;Ge?xe[Ce]=(re=Il.value)==null?void 0:re[Ge]:xe[Ce]=F[Ce]??""}F=Object.assign(xe,Il.value),I=F}else F=(le=ct(F,v))==null?void 0:le.contents,I=(q=ct(F,v))==null?void 0:q.currentSelectContents;return F}),{newContents:B,currentSelectContents:I}},$t=(p,v,B)=>{var I,F;return p[v==null?void 0:v.prop]=B,typeof p.id=="number"&&(p.id=(I=p.id)==null?void 0:I.toString()),p.children&&((F=p.children)==null?void 0:F.length)>0&&(p.children=p.children.map($t)),p},Vt=p=>{var B;const v=[];return v.push({...p}),p!=null&&p.children&&Array.isArray(p.children)&&((B=p.children)==null||B.forEach(I=>{v.push(...Vt(I))})),(v==null?void 0:v.length)>0?v==null?void 0:v.map(I=>{const F={...I};return delete F.children,F}):[]},fo=["Pacific6000数据采集装置.通道号","通道号"],ji=p=>{if(!p)return"";const v=fo.map(B=>p==null?void 0:p[B]).find(B=>B!=null&&String(B).trim()!=="");return v==null?"":String(v).trim()},ut=async(p,v=void 0)=>{if(!p)return!1;try{const B=Qe=>{var ba,za,$a;return Qe?typeof(Qe==null?void 0:Qe.value)=="string"?Qe.value:(($a=(za=(ba=Qe==null?void 0:Qe._custom)==null?void 0:ba.value)==null?void 0:za.value)==null?void 0:$a.value)||"":""},I=Array.isArray(rr.value)?rr.value:[],F=B(I.find(Qe=>(Qe==null?void 0:Qe.condition)==="child")),D=(Se.value||"").replace(/\/+$/,""),re=F?`${D}/${F}`:D,le=await Jr(re||Se.value,!1),q=String(ta.value||"").trim(),xe=Qe=>String(Qe||"").trim(),Ce=(Qe,ba=[],za="")=>{if(!Array.isArray(Qe))return ba;for(const $a of Qe){const ea=xe(($a==null?void 0:$a.choiceName)||($a==null?void 0:$a.name0)||za);($a==null?void 0:$a.comp)==="Table"&&(!q||ea===q)&&ba.push($a),Array.isArray($a==null?void 0:$a.children)&&Ce($a.children,ba,ea),Array.isArray($a==null?void 0:$a.tab)&&Ce($a.tab,ba,ea),Array.isArray($a==null?void 0:$a.choice)&&Ce($a.choice,ba,ea)}return ba},Ge=Ce(le||[]),He=String((u==null?void 0:u.compName)||"");return Ge.some(Qe=>{var za,$a;const ba=(($a=(za=Qe==null?void 0:Qe.compData)==null?void 0:za.find(ea=>(ea==null?void 0:ea.key)==="tableContents"))==null?void 0:$a.contents)||[];return!Array.isArray(ba)||ba.length===0?!1:ba.some(ea=>{if(String((Qe==null?void 0:Qe.name)||"")===He&&(ea==null?void 0:ea.id)===v)return!1;const ka=ji(ea);return!!ka&&ka===p})})}catch{return(Ae.value||[]).some(I=>{if((I==null?void 0:I.id)===v)return!1;const F=ji(I);return!!F&&F===p})}},Hi=async(p=!0,v,B)=>{var xe,Ce,Ge,He,Qe,ba,za,$a,ea,al,ka,ll,ve,Pa,ya,Da,Ea,N,G,Ve,sa,we,da,Na,tl,Ya,fl,vl,ql,Ua,kl;if(Il.value){const ja=(Ce=oe.getColumnChild((xe=A.cloneDeep(z.value))==null?void 0:xe.filter(Xa=>(Xa==null?void 0:Xa.label)!=="操作")))==null?void 0:Ce.filter(Xa=>(Xa==null?void 0:Xa.required)===!0);for(let Xa=0;Xa<((ja==null?void 0:ja.length)??0);Xa++){const pl=ja[Xa],Nl=pl==null?void 0:pl.prop,Ll=(pl==null?void 0:pl.label)??Nl,Nr=(Ge=Il.value)==null?void 0:Ge[Nl];if(Nr===""||Nr===null||Nr===void 0||Array.isArray(Nr)&&Nr.length===0){Wa.ElMessage.error(`${Ll}不能为空`);return}}const dl=ji(Il.value);if(dl&&await ut(dl,Ia.value||void 0)){Wa.ElMessage.warning("当前任务下通道号不能重复,请重新选择");return}}let I=oe.getColumnChild((He=A.cloneDeep(z.value))==null?void 0:He.filter(ja=>(ja==null?void 0:ja.label)!=="操作")),F,D=A.cloneDeep(Ae.value);if(!Il.value){Be.value=!1;return}if(Ia.value===""){Ba.value++;let ja;ja={id:Ba.value.toString()};try{ja.sort=ri(0,Ae.value||[])}catch{}ja!=null&&ja.children&&(ja={...ja,children:(Qe=ja.children)==null?void 0:Qe.map(Xa=>$t(Xa,v,B))});const dl=Object.assign(Il.value,ja);D.unshift(dl),F=dl}else D=(ba=Rt(D,I))==null?void 0:ba.newContents,F=(za=Rt(D,I))==null?void 0:za.currentSelectContents;const re=($a=u.itemData)==null?void 0:$a.filter(ja=>(ja==null?void 0:ja.key)==="childTree")[0];if(((ea=re==null?void 0:re.contents)==null?void 0:ea.length)>0){be.value="编辑";const ja=[];D==null||D.forEach((pl,Nl)=>{var Nr;let Ll={};if(Array.isArray(pl)){let Hl=[];pl==null||pl.filter(wl=>!(wl!=null&&wl.id)).forEach((wl,$l)=>{var er,Rl,Ql,sr,Jl,xr,on;if((Rl=(er=vr.value)==null?void 0:er[$l])!=null&&Rl.prop&&!Array.isArray(wl)){let wr={};wr[vr.value[$l].column]=wl,$!=null&&$.value&&((Ql=$==null?void 0:$.value)==null?void 0:Ql.length)>0&&((sr=$==null?void 0:$.value)!=null&&sr.find(fr=>JSON.stringify(fr==null?void 0:fr[0])===JSON.stringify(wr)))&&(Hl=(Jl=$==null?void 0:$.value)==null?void 0:Jl.find(fr=>JSON.stringify(fr==null?void 0:fr[0])===JSON.stringify(wr))),Hl&&Hl.length>0?Ll[vr.value[$l].prop]=Hl!=null&&Hl.find(fr=>{var mr;return((mr=Object.keys(fr))==null?void 0:mr[0])===vr.value[$l].column})?(xr=Hl==null?void 0:Hl.find(fr=>{var mr;return((mr=Object.keys(fr))==null?void 0:mr[0])===vr.value[$l].column}))==null?void 0:xr[vr.value[$l].column]:wl:Ll[vr.value[$l].prop]=wl}else Array.isArray(wl)&&((on=vr.value[$l])!=null&&on.prop?Ll[vr.value[$l].prop]=wl:Ll.children=_t(wl,vr.value))})}else Ll=pl;if(Array.isArray(pl)&&pl.some(Hl=>Hl==null?void 0:Hl.id)){const Hl=(Nr=pl==null?void 0:pl.find(wl=>wl.id))==null?void 0:Nr.id;ja.push(Object.assign(Ll,{id:co(Hl)}))}else Ll.id?ja.push(Ll):ja.push(Object.assign(Ll,{id:Nl.toString()}))});const dl=(Ae.value||[]).map(pl=>String(pl==null?void 0:pl.id)),Xa=vi(ja,dl);Ae.value=Ht(Xa,re,z.value)}Ft(Ae.value),jr.value=Ae.value;const le=Ff(jr.value,Wr.value,D);let q=[];if(H.value?(q=(al=A.cloneDeep(H).value.singleContent)==null?void 0:al.filter(ja=>(ja==null?void 0:ja.id)!==(F==null?void 0:F.id)),q.push(F)):q=[F],Fl.value){const ja={content:le,singleContent:((ka=re==null?void 0:re.contents)==null?void 0:ka.length)>0?q==null?void 0:q.flatMap(Vt):q,index:u==null?void 0:u.index,buttonName:"编辑",column:z.value,parentTableId:u==null?void 0:u.parentTableId};ua.setCacheUpdatingData(ja)}if((ll=z.value)==null||ll.forEach(ja=>{(ja==null?void 0:ja.formType)==="Upload"&&(F[ja.prop]=F[ja.prop]===""?"{}":typeof F[ja.prop]!="string"?JSON.stringify(F[ja.prop]):F[ja.prop])}),p){(Da=(ya=(Pa=(ve=u.itemData)==null?void 0:ve.find(Xa=>(Xa==null?void 0:Xa.key)==="filterAllType"))==null?void 0:Pa.value)==null?void 0:ya.find(Xa=>(Xa==null?void 0:Xa.value)==="onConditionContents"))==null||Da.content;let ja=(Ea=u.itemData)==null?void 0:Ea.filter(Xa=>(Xa==null?void 0:Xa.key)==="filterAllType");ja=Array.from(new Map(ja.filter(Boolean).map((Xa,pl)=>[Xa.value,{...Xa,_idx:pl}])).values()).sort((Xa,pl)=>Xa._idx-pl._idx).map(({_idx:Xa,...pl})=>pl),ja=(N=ja==null?void 0:ja[(ja==null?void 0:ja.length)-1])==null?void 0:N.value;const dl={fixContent:[F],buttonName:be.value,relatedContents:u==null?void 0:u.related,columns:z.value,name:u==null?void 0:u.groupNames};ua.setTableLoading(u==null?void 0:u.index),Be.value=!1,Il.value=void 0,_e("change",dl)}if((sa=(Ve=(G=Ne.value)==null?void 0:G[0])==null?void 0:Ve.optionUrl)!=null&&sa.menuId){Be.value=!1;let ja=(we=u.itemData)==null?void 0:we.filter(dl=>(dl==null?void 0:dl.key)==="filterAllType");if((ja==null?void 0:ja.length)>0){let dl=ja==null?void 0:ja.map(Nl=>Nl==null?void 0:Nl.value),Xa=(tl=(Na=(da=dl.flat().find(Nl=>{var Ll;return(Ll=Nl==null?void 0:Nl.content)==null?void 0:Ll.includes("@Num")}))==null?void 0:da.content)==null?void 0:Na.split(":"))==null?void 0:tl[1];((vl=(fl=(Ya=dl.flat().find(Nl=>{var Ll;return(Ll=Nl==null?void 0:Nl.content)==null?void 0:Ll.includes("@Type:")}))==null?void 0:Ya.content)==null?void 0:fl.split(":"))==null?void 0:vl[1])!=="Manual"&&(Xa=parseInt(Xa),Ae.value=(kl=Ae.value)==null?void 0:kl.slice(((ql=Ae.value)==null?void 0:ql.length)-Xa,(Ua=Ae.value)==null?void 0:Ua.length))}}};e.onUnmounted(()=>{window.removeEventListener("keydown",ao),z.value=[],Ae.value=[],ye.value=[],Ca.value=[],Ha.value=[],_a.value=[],Pe.value=[],Re.value=[],Ne.value=[],Wl.value=[],i.value=null,Fn.value=""});const ho=async(p,v,B)=>{var Qe,ba,za,$a,ea,al,ka,ll,ve,Pa,ya,Da,Ea;hr.value=(B==null?void 0:B.prop)??(B==null?void 0:B.property);const I=A.cloneDeep(u.itemData),F=((Qe=I==null?void 0:I.find(N=>(N==null?void 0:N.key)==="header"))==null?void 0:Qe.contents)??[];let D=F==null?void 0:F.find((N,G)=>{var Ve,sa,we;return(N==null?void 0:N.prop)===hr.value||(N==null?void 0:N.label)===hr.value||(G==null?void 0:G.toString())===((we=(sa=(Ve=hr.value)==null?void 0:Ve.split("a"))==null?void 0:sa[1])==null?void 0:we.toString())});const re=oe.getColumnChild((ba=A.cloneDeep(z.value))==null?void 0:ba.filter(N=>(N==null?void 0:N.label)!=="操作"));if(D||(D=re==null?void 0:re.find(N=>(N==null?void 0:N.prop)===hr.value||(N==null?void 0:N.label)===hr.value)),D&&!((za=D==null?void 0:D.menus)!=null&&za.length)&&!(($a=D==null?void 0:D.groups)!=null&&$a.length)&&!((ea=D==null?void 0:D.words)!=null&&ea.length)){const N=(al=Ne.value)==null?void 0:al.find(G=>(G==null?void 0:G.prop)===hr.value);N&&(D={...D,menus:(N==null?void 0:N.menus)??(D==null?void 0:D.menus),groups:(N==null?void 0:N.groups)??(D==null?void 0:D.groups),words:(N==null?void 0:N.words)??(D==null?void 0:D.words),bindMenus:(N==null?void 0:N.bindMenus)??(D==null?void 0:D.bindMenus),isMainPath:(N==null?void 0:N.isMainPath)??(D==null?void 0:D.isMainPath),relatedContents:(N==null?void 0:N.relatedContents)??(D==null?void 0:D.relatedContents),endChildMenu:(N==null?void 0:N.endChildMenu)??(D==null?void 0:D.endChildMenu)})}if(D&&((ka=Ne==null?void 0:Ne.value)==null||ka.forEach(N=>{var G,Ve,sa,we,da;(N==null?void 0:N.prop)===(D==null?void 0:D.prop)&&(N!=null&&N.endChildMenu)&&((G=D==null?void 0:D.prop)!=null&&G.includes(".")&&((sa=(Ve=D==null?void 0:D.prop)==null?void 0:Ve.split("."))==null?void 0:sa[0])!==((da=(we=N==null?void 0:N.prop)==null?void 0:we.split("."))==null?void 0:da[0])?D.endChildMenu=N==null?void 0:N.value:D.endChildMenu=N==null?void 0:N.endChildMenu)})),!D)return;const le=hr.value,q=(ll=Ae.value)==null?void 0:ll.findIndex(N=>(N==null?void 0:N.id)===(v==null?void 0:v.id));q!==-1&&le&&(Ae.value[q]={...Ae.value[q],[le]:p});const xe=N=>{Array.isArray(N)&&N.forEach(G=>{Array.isArray(G==null?void 0:G.allSelectionContents)&&G.allSelectionContents.length>0&&(G.contactValue=Ae.value[q]??v),Array.isArray(G==null?void 0:G.children)&&G.children.length>0&&xe(G.children)})};xe(z.value),D.value=p,D.endChildMenu=D.endChildMenu||"";let Ce=D!=null&&D.isMainPath&&(D!=null&&D.mainKey)?D==null?void 0:D.value:"";const Ge=N=>{Array.isArray(N)&&N.forEach(G=>{var sa,we;if(((G==null?void 0:G.type)==="Select"||(G==null?void 0:G.formType)&&G.formType.toUpperCase()==="SELECT"||(G==null?void 0:G.columnType)&&G.columnType.toUpperCase()==="SELECT")&&Array.isArray(G==null?void 0:G.menus)&&G.menus.length>0&&G.menus[G.menus.length-1]===""&&(D!=null&&D.isMainPath)&&(D!=null&&D.mainKey)){const da=(sa=G==null?void 0:G.prop)!=null&&sa.includes(".")?G.prop.split(".")[0]:null,Na=(we=D==null?void 0:D.prop)!=null&&we.includes(".")?D.prop.split(".")[0]:null;(!da||!Na||da===Na)&&(G.endChildMenu=Ce)}Array.isArray(G==null?void 0:G.children)&&G.children.length>0&&Ge(G.children)})};if(Ge(z.value),!!(D!=null&&D.mainKey)&&Array.isArray(D==null?void 0:D.menus)&&(D==null?void 0:D.menus.length)>0&&(D!=null&&D.value)&&(D==null?void 0:D.value)!==""){let N=D!=null&&D.relatedContents&&((ve=D==null?void 0:D.relatedContents)==null?void 0:ve.length)>0?(Pa=D==null?void 0:D.relatedContents)==null?void 0:Pa.find(G=>{var Ve,sa,we,da;return(G==null?void 0:G[(da=(Ve=D==null?void 0:D.prop)==null?void 0:Ve.split("."))==null?void 0:da[((we=(sa=D==null?void 0:D.prop)==null?void 0:sa.split("."))==null?void 0:we.length)-1]])===(D==null?void 0:D.value)}):await vs(D);if(N){const G={...v};re==null||re.forEach(Ve=>{var sa,we,da,Na,tl,Ya,fl,vl,ql,Ua,kl,ja,dl,Xa,pl,Nl;(Ve==null?void 0:Ve.prop)!==(D==null?void 0:D.prop)&&(D!=null&&D.relatedContents&&((sa=D==null?void 0:D.relatedContents)==null?void 0:sa.length)>0?(we=Ve==null?void 0:Ve.prop)!=null&&we.includes(".")&&((Na=(da=Ve==null?void 0:Ve.prop)==null?void 0:da.split("."))==null?void 0:Na[0])===((Ya=(tl=D==null?void 0:D.prop)==null?void 0:tl.split("."))==null?void 0:Ya[0])?G[Ve.prop]=N[(Ua=(fl=Ve==null?void 0:Ve.prop)==null?void 0:fl.split("."))==null?void 0:Ua[((ql=(vl=Ve==null?void 0:Ve.prop)==null?void 0:vl.split("."))==null?void 0:ql.length)-1]]??G[Ve.prop]:G[Ve.prop]=(N==null?void 0:N[Ve.prop])??G[Ve.prop]:oe.same((D==null?void 0:D.menus)??[],(Ve==null?void 0:Ve.menus)??[])&&oe.same((D==null?void 0:D.groups)??[],(Ve==null?void 0:Ve.groups)??[])&&!oe.same((D==null?void 0:D.words)??[],(Ve==null?void 0:Ve.words)??[])?(kl=Ve==null?void 0:Ve.prop)!=null&&kl.includes(".")&&((dl=(ja=Ve==null?void 0:Ve.prop)==null?void 0:ja.split("."))==null?void 0:dl[0])!==((pl=(Xa=D==null?void 0:D.prop)==null?void 0:Xa.split("."))==null?void 0:pl[0])||(G[Ve.prop]=(N==null?void 0:N[(Nl=Ve==null?void 0:Ve.words)==null?void 0:Nl.join(".")])??(N==null?void 0:N[Ve.prop])??G[Ve.prop]):(!(Ve!=null&&Ve.isMainPath)&&oe.same((D==null?void 0:D.bindMenus)??[],(Ve==null?void 0:Ve.bindMenus)??[]),G[Ve.prop]=(N==null?void 0:N[Ve.prop])??G[Ve.prop]))}),Ae.value=(ya=A.cloneDeep(Ae.value))==null?void 0:ya.map(Ve=>(Ve==null?void 0:Ve.id)===(v==null?void 0:v.id)?{...G,id:Ve==null?void 0:Ve.id}:Ve)}}if((Da=D==null?void 0:D.optionUrl)!=null&&Da.menuSelect){let N="";re==null||re.forEach(sa=>{var we,da,Na,tl,Ya;N===""&&((Na=(da=(we=sa==null?void 0:sa.optionUrl)==null?void 0:we.groupSelect)==null?void 0:da[1])!=null&&Na.includes("["))&&(N=(Ya=(tl=sa==null?void 0:sa.optionUrl)==null?void 0:tl.groupSelect)==null?void 0:Ya[1])});let G=await St(D),Ve;if(G==null||G.forEach(sa=>{var we,da,Na,tl,Ya,fl,vl,ql,Ua,kl;N===((da=(we=D==null?void 0:D.optionUrl)==null?void 0:we.groupSelect)==null?void 0:da[1])&&((Ya=(tl=(Na=D==null?void 0:D.optionUrl)==null?void 0:Na.groupSelect)==null?void 0:tl[1])!=null&&Ya.includes("["))&&((kl=A.cloneDeep(sa))==null?void 0:kl[(Ua=(ql=(vl=(fl=D==null?void 0:D.optionUrl)==null?void 0:fl.groupSelect)==null?void 0:vl[1])==null?void 0:ql.replaceAll("[",""))==null?void 0:Ua.replaceAll("]","")])===(D==null?void 0:D.value)&&(Ve=sa)}),Ve){const sa={...v};re==null||re.forEach(we=>{var da,Na,tl,Ya,fl,vl,ql,Ua,kl,ja,dl;(Ve!=null&&Ve[we==null?void 0:we.label]||Ve!=null&&Ve[(Ya=(tl=(Na=(da=we==null?void 0:we.optionUrl)==null?void 0:da.groupSelect)==null?void 0:Na[1])==null?void 0:tl.replaceAll("[",""))==null?void 0:Ya.replaceAll("]","")])&&((ql=(vl=(fl=we==null?void 0:we.optionUrl)==null?void 0:fl.groupSelect)==null?void 0:vl[1])!=null&&ql.includes("["))&&(sa[we.prop]=(Ve==null?void 0:Ve[we==null?void 0:we.label])||(Ve==null?void 0:Ve[(dl=(ja=(kl=(Ua=we==null?void 0:we.optionUrl)==null?void 0:Ua.groupSelect)==null?void 0:kl[1])==null?void 0:ja.replaceAll("[",""))==null?void 0:dl.replaceAll("]","")]))}),Ae.value=(Ea=A.cloneDeep(Ae.value))==null?void 0:Ea.map(we=>(we==null?void 0:we.id)===(v==null?void 0:v.id)?{...sa,id:we==null?void 0:we.id}:we)}}},gu=async p=>{var Qe,ba,za,$a,ea,al,ka,ll,ve,Pa,ya,Da,Ea,N;if(!p)return;const v=A.cloneDeep(Il.value||{});Il.value=p;const B=ji(v),I=ji(Il.value);if(I&&I!==B&&await ut(I,Ia.value||void 0)){Wa.ElMessage.warning("当前任务下通道号不能重复,请重新选择"),fo.forEach(Ve=>{if(Object.prototype.hasOwnProperty.call(Il.value||{},Ve)||Object.prototype.hasOwnProperty.call(v||{},Ve)){const sa=(v==null?void 0:v[Ve])??"";Il.value[Ve]=sa,p[Ve]=sa}}),Ne.value=(Ne.value||[]).map(Ve=>{if(!(Ve!=null&&Ve.prop)||!fo.includes(Ve.prop))return Ve;const sa=(v==null?void 0:v[Ve.prop])??"";return{...Ve,value:sa,selectValue:sa===""?[]:[sa]}});return}let F=A.cloneDeep(u.itemData);F==null||F.map(G=>{var Ve,sa,we,da;return(G==null?void 0:G.key)==="header"&&(Array.isArray((Ve=G.contents)==null?void 0:Ve[0])?G.contents=(we=oe.getColumnChild((sa=G.contents)==null?void 0:sa[0]))==null?void 0:we.map((Na,tl)=>{var Ya,fl,vl,ql,Ua,kl;return((vl=(fl=(Ya=Ne.value)==null?void 0:Ya.find(ja=>(ja==null?void 0:ja.prop)===(Na==null?void 0:Na.prop)))==null?void 0:fl.optionUrl)==null?void 0:vl.multiple)===!0&&!Array.isArray((ql=Object.values(p))==null?void 0:ql[tl])?Na.value=[(Ua=Object.values(p))==null?void 0:Ua[tl]]:Na.value=(kl=Object.values(p))==null?void 0:kl[tl],Na}):G.contents=(da=G.contents)==null?void 0:da.map((Na,tl)=>{var Ya,fl,vl,ql,Ua,kl;return((vl=(fl=(Ya=Ne.value)==null?void 0:Ya.find(ja=>(ja==null?void 0:ja.prop)===(Na==null?void 0:Na.prop)))==null?void 0:fl.optionUrl)==null?void 0:vl.multiple)===!0&&!Array.isArray((ql=Object.values(p))==null?void 0:ql[tl])?Na.value=[(Ua=Object.values(p))==null?void 0:Ua[tl]]:Na.value=(kl=Object.values(p))==null?void 0:kl[tl],Na})),G});let D=Ne.value,re=(Qe=F==null?void 0:F.find(G=>(G==null?void 0:G.key)==="header"))==null?void 0:Qe.contents;if(hr.value||(D=D==null?void 0:D.map(G=>{var Ve;return G.value=G.value??((Ve=re==null?void 0:re.find((sa,we)=>(sa==null?void 0:sa.prop)===(G==null?void 0:G.name)))==null?void 0:Ve.value),G})),!Vr.value)return;let le=A.cloneDeep(hr.value);(ba=hr.value)!=null&&ba.includes("·")&&(hr.value=($a=(za=hr.value)==null?void 0:za.split("·"))==null?void 0:$a[0]);let q=(al=(ea=F==null?void 0:F.find(G=>(G==null?void 0:G.key)==="header"))==null?void 0:ea.contents)==null?void 0:al.find((G,Ve)=>(G==null?void 0:G.prop)===hr.value);(ka=Ne==null?void 0:Ne.value)==null||ka.forEach(G=>{var Ve,sa,we,da,Na,tl,Ya,fl,vl;(G==null?void 0:G.prop)===(q==null?void 0:q.prop)&&(G!=null&&G.endChildMenu)&&((Ve=q==null?void 0:q.prop)!=null&&Ve.includes(".")&&((we=(sa=q==null?void 0:q.prop)==null?void 0:sa.split("."))==null?void 0:we[0])!==((Na=(da=G==null?void 0:G.prop)==null?void 0:da.split("."))==null?void 0:Na[0])?q.endChildMenu=(Ya=(tl=G==null?void 0:G.value)==null?void 0:tl.split(" "))==null?void 0:Ya[0]:q.endChildMenu=(vl=(fl=G==null?void 0:G.endChildMenu)==null?void 0:fl.split(" "))==null?void 0:vl[0])});let xe=q!=null&&q.isMainPath&&(q!=null&&q.mainKey)?q==null?void 0:q.value:"",Ce=D,Ge=Y.value;if(Ge!=null&&Ge.find(G=>(q==null?void 0:q.prop)===(G==null?void 0:G.key))&&(Ge=Ge==null?void 0:Ge.filter(G=>(q==null?void 0:q.prop)!==(G==null?void 0:G.key))),Ge!=null&&Ge.find(G=>le===(G==null?void 0:G.key))&&(Ge=Ge==null?void 0:Ge.filter(G=>le!==(G==null?void 0:G.key))),(q==null?void 0:q.formType)==="Select"?Ce=Ce==null?void 0:Ce.map(G=>{var Ve,sa,we,da,Na,tl,Ya,fl,vl,ql,Ua,kl,ja,dl,Xa,pl;return(G==null?void 0:G.type)==="Select"&&(((Ve=G==null?void 0:G.allSelectionContents)==null?void 0:Ve.length)>0&&(G.contactValue=p),((q==null?void 0:q.prop)===(G==null?void 0:G.prop)||le===(G==null?void 0:G.prop))&&q&&(Array.isArray(q.value)&&((sa=q.value)==null?void 0:sa.length)>0&&((we=q.value)!=null&&we.every(Nl=>typeof Nl=="string"))?(Ge.push({key:G==null?void 0:G.prop,value:[(Na=q.value)==null?void 0:Na[((da=q.value)==null?void 0:da.length)-1]]}),G.selectValue=(tl=Ge==null?void 0:Ge.find(Nl=>(Nl==null?void 0:Nl.key)===(G==null?void 0:G.prop)))==null?void 0:tl.value):Array.isArray(q.value)&&((Ya=q.value)==null?void 0:Ya.length)===0?(Ge=[],G.selectValue=[],p[G==null?void 0:G.prop]=""):Array.isArray(G.value)&&Ge.push({key:G==null?void 0:G.prop,value:[(fl=G.value)==null?void 0:fl[(G==null?void 0:G.length)-1]]})),((ql=G==null?void 0:G.menus)==null?void 0:ql[((vl=G==null?void 0:G.menus)==null?void 0:vl.length)-1])===""&&(q!=null&&q.isMainPath)&&(q!=null&&q.mainKey)&&((Ua=G==null?void 0:G.prop)!=null&&Ua.includes(".")&&((ja=(kl=G==null?void 0:G.prop)==null?void 0:kl.split("."))==null?void 0:ja[0])!==((Xa=(dl=q==null?void 0:q.prop)==null?void 0:dl.split("."))==null?void 0:Xa[0])||(G.endChildMenu=(pl=xe==null?void 0:xe.split(" "))==null?void 0:pl[0]))),G.value=(p==null?void 0:p[G==null?void 0:G.prop])??(G==null?void 0:G.value),G}):(q==null?void 0:q.formType)!=="Input"&&(Ce=Ce==null?void 0:Ce.map(G=>(G.value=(p==null?void 0:p[G==null?void 0:G.prop])??(G==null?void 0:G.value),G))),Y.value=Ge,Ce!=null&&Ce.some(G=>(G==null?void 0:G.functionName)&&(G==null?void 0:G.functionName)!=="")){let G=await wt([p],z==null?void 0:z.value,"Auto",Ae.value),Ve=[];(ll=Ce==null?void 0:Ce.filter(we=>(we==null?void 0:we.functionName)&&(we==null?void 0:we.functionName)!==""))==null||ll.forEach(we=>{var da;((da=we==null?void 0:we.functionRelatedWords)==null?void 0:da.length)>0&&(Ve=[...Ve,...we==null?void 0:we.functionRelatedWords])}),Ve=Ve==null?void 0:Ve.filter(we=>(we==null?void 0:we[0])!=="@");let sa=[];for(let we in G==null?void 0:G[0])Ve!=null&&Ve.find(da=>we===da||(we==null?void 0:we.includes("."+da)))&&sa.push(((ve=G==null?void 0:G[0])==null?void 0:ve[we])!=="");(G==null?void 0:G.length)>0&&sa.every(we=>we)&&(Ce=Ce==null?void 0:Ce.map(we=>{var da;return we.value=((da=G==null?void 0:G[0])==null?void 0:da[we==null?void 0:we.prop])??we.value,we})),Il.value=G==null?void 0:G[0]}if(Ne.value=Ce,q=Object.assign({},q??{},{relatedWords:(ya=(Pa=Ne==null?void 0:Ne.value)==null?void 0:Pa.find(G=>(G==null?void 0:G.prop)===(q==null?void 0:q.prop)))==null?void 0:ya.relatedWords}),(q==null?void 0:q.mainKey)&&(q!=null&&q.value)&&(q==null?void 0:q.value)!==""){let G=q!=null&&q.relatedContents&&((Da=q==null?void 0:q.relatedContents)==null?void 0:Da.length)>0?(Ea=q==null?void 0:q.relatedContents)==null?void 0:Ea.find(Ve=>{var sa,we,da,Na;return(Ve==null?void 0:Ve[(Na=(sa=q==null?void 0:q.prop)==null?void 0:sa.split("."))==null?void 0:Na[((da=(we=q==null?void 0:q.prop)==null?void 0:we.split("."))==null?void 0:da.length)-1]])===(q==null?void 0:q.value)}):await vs(q);if(G&&JSON.stringify(G)!=="{}"){let Ve=Ce;Ve=Ve==null?void 0:Ve.map(we=>{var da,Na,tl,Ya,fl,vl,ql,Ua,kl,ja,dl,Xa,pl,Nl,Ll,Nr,Hl,wl,$l,er,Rl;if((q==null?void 0:q.prop)===(we==null?void 0:we.prop))we.value=(G==null?void 0:G[(da=we==null?void 0:we.words)==null?void 0:da.join(".")])??(G==null?void 0:G[we==null?void 0:we.prop])??G[(fl=(Na=we==null?void 0:we.prop)==null?void 0:Na.split("."))==null?void 0:fl[((Ya=(tl=we==null?void 0:we.prop)==null?void 0:tl.split("."))==null?void 0:Ya.length)-1]];else if(q!=null&&q.relatedContents&&((vl=q==null?void 0:q.relatedContents)==null?void 0:vl.length)>0)we.value=(ql=we==null?void 0:we.prop)!=null&&ql.includes(".")&&((kl=(Ua=we==null?void 0:we.prop)==null?void 0:Ua.split("."))==null?void 0:kl[0])===((dl=(ja=q==null?void 0:q.prop)==null?void 0:ja.split("."))==null?void 0:dl[0])?G[(Ll=(Xa=we==null?void 0:we.prop)==null?void 0:Xa.split("."))==null?void 0:Ll[((Nl=(pl=we==null?void 0:we.prop)==null?void 0:pl.split("."))==null?void 0:Nl.length)-1]]:(G==null?void 0:G[we==null?void 0:we.prop])??(we==null?void 0:we.value);else if(oe.same((q==null?void 0:q.menus)??[],(we==null?void 0:we.menus)??[])&&oe.same((q==null?void 0:q.groups)??[],(we==null?void 0:we.groups)??[])&&!oe.same((q==null?void 0:q.words)??[],(we==null?void 0:we.words)??[]))if((Nr=we==null?void 0:we.prop)!=null&&Nr.includes(".")&&((wl=(Hl=we==null?void 0:we.prop)==null?void 0:Hl.split("."))==null?void 0:wl[0])!==((er=($l=q==null?void 0:q.prop)==null?void 0:$l.split("."))==null?void 0:er[0])){let Ql=Object.keys(G);Ql=Ql==null?void 0:Ql.find(sr=>{var Jl;return sr==null?void 0:sr.includes("."+((Jl=we==null?void 0:we.words)==null?void 0:Jl.join(".")))}),we.value=(G==null?void 0:G[Ql])??(G==null?void 0:G[we==null?void 0:we.prop])??we.value}else{let Ql=Object.keys(G);Ql=Ql==null?void 0:Ql.find(sr=>{var Jl;return sr==null?void 0:sr.includes("."+((Jl=we==null?void 0:we.words)==null?void 0:Jl.join(".")))}),we.value=(G==null?void 0:G[(Rl=we==null?void 0:we.words)==null?void 0:Rl.join(".")])??(G==null?void 0:G[Ql])??(G==null?void 0:G[we==null?void 0:we.prop])??we.value}else!(we!=null&&we.isMainPath)&&oe.same((q==null?void 0:q.bindMenus)??[],(we==null?void 0:we.bindMenus)??[]),we.value=(G==null?void 0:G[we==null?void 0:we.prop])??we.value;return we}),Ne.value=Ve;let sa={};(N=Ne.value)==null||N.forEach(we=>{sa[we.prop]=we==null?void 0:we.value}),Il.value=sa}}Vr.value=!0,O.value=!1},bu=p=>p?(p==null?void 0:p.toUpperCase())==="INPUT"?"TEXTAREA":p:"TEXTAREA",ku=p=>{var D,re;const v=(re=(D=Ha.value)==null?void 0:D.find(le=>(le==null?void 0:le.label)===(p==null?void 0:p.label)))==null?void 0:re.multiple,B=p==null?void 0:p.prop;if((p==null?void 0:p.formType)!="Select")return;Ae.value.forEach(le=>{const q=le==null?void 0:le[B];v&&No.isString(q)&&(le[B]=[q]),!v&&!No.isString(q)&&(le[B]="")})},Pt=(p,v)=>{var B;return v==null||v.forEach(I=>{p[I==null?void 0:I.prop]=I==null?void 0:I.value}),p.children&&((B=p.children)==null?void 0:B.length)>0&&(p.children=p.children.map(I=>Pt(I,v))),p},dt=p=>{var B,I,F,D,re,le;Fi("");const v=(B=Ne.value)==null?void 0:B.reduce((q,xe)=>(q[xe.name]=xe.value,q),{});if(((I=Object.keys(v))==null?void 0:I.length)>0){Il.value=v,Ia.value="",Ba.value=(F=Ae.value)==null?void 0:F.length,Re.value=(D=Ue.value)==null?void 0:D.filter(xe=>(xe==null?void 0:xe.label)!=="新增");const q=(le=(re=ye.value)==null?void 0:re.filter(xe=>(xe==null?void 0:xe.label)!=="操作"))==null?void 0:le.map(xe=>{var Ge,He,Qe;const Ce=(He=(Ge=Ha.value)==null?void 0:Ge.find(ba=>(ba==null?void 0:ba.label)===(xe==null?void 0:xe.label)))==null?void 0:He.multiple;return ku(xe),{...xe,contents:(xe==null?void 0:xe.options)??[],optionUrl:xe!=null&&xe.formMenuSelect&&((Qe=xe==null?void 0:xe.formMenuSelect)==null?void 0:Qe.length)>0?{groupSelect:xe==null?void 0:xe.groupSelect,menuSelect:xe==null?void 0:xe.formMenuSelect,selectRelateType:"",type:xe==null?void 0:xe.formType,multiple:Ce}:null}});z.value=q==null?void 0:q.map(xe=>Pt(xe,[{prop:"type",value:"edit"},{prop:"columnType",value:bu(xe==null?void 0:xe.formType)||(xe==null?void 0:xe.columnType)}])),p==="createClick"&&(be.value="新增",Hi(!0))}},ki={START:"开始时间",END:"结束时间",HOURS:"工时"},xu=(p,v)=>Number(A.dayjs(v).diff(A.dayjs(p),"day",!0).toFixed(1)),Ft=p=>{var D;const v=u.itemData,B=(D=v==null?void 0:v.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:D.contents,I=new Map;return B==null||B.forEach((re,le)=>{const{label:q}=re;I.set(q,le)}),!I.has(ki.START)||!I.has(ki.END)||!I.has(ki.HOURS)?p:p==null?void 0:p.map(re=>{const le=re==null?void 0:re[ki.START],q=re==null?void 0:re[ki.END],xe=xu(le,q);return le&&q&&(re[ki.HOURS]=`${xe}天`),re})},jt=(p,v,B=0)=>{if(B>((v==null?void 0:v.length)??""))return p;const I=v==null?void 0:v[B],F=new Map;for(const re of p){const le=re[I];F.has(le)||F.set(le,[]),F.get(le)&&F.get(le).push(re)}const D=[];for(const[re,le]of F){const[q,...xe]=le,Ce={...q};B+1===((v==null?void 0:v.length)??"")?Ce.children=le==null?void 0:le.map(Ge=>(Ge.level=A.cloneDeep(B)+1,Ge)).filter((Ge,He)=>He!==0):xe.length>0&&(Ce.children=jt(xe,v,B+1)),Ce.level=B,D.push(Ce)}return D},Ht=(p,v,B)=>{var F;if(!(v!=null&&v.contents)||((F=v==null?void 0:v.contents)==null?void 0:F.length)===0)return p;let I=[];return I=jt(p,v==null?void 0:v.contents,0),I},Ut=async(p,v)=>{var ea,al,ka,ll,ve,Pa,ya,Da,Ea,N,G,Ve,sa,we,da,Na,tl,Ya,fl,vl,ql,Ua,kl,ja,dl,Xa,pl,Nl,Ll,Nr,Hl,wl,$l,er,Rl,Ql,sr,Jl,xr,on,wr,fr,mr,Wt,Kt,Gt,Yt,Jt;const B=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="header");p==null||p.filter(oa=>(oa==null?void 0:oa.key)==="tableIndexColumn")[0];const I=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="childTree")[0];let F=!0;if((ka=(al=(ea=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="filterAllType"))==null?void 0:ea.value)==null?void 0:al.find(oa=>(oa==null?void 0:oa.value)==="onPamButtonContents"))!=null&&ka.content){let oa=(Pa=(ve=(ll=p==null?void 0:p.find(Dl=>(Dl==null?void 0:Dl.key)==="filterAllType"))==null?void 0:ll.value)==null?void 0:ve.find(Dl=>(Dl==null?void 0:Dl.value)==="onPamButtonContents"))==null?void 0:Pa.content;oa=(ya=oa==null?void 0:oa.split(":"))==null?void 0:ya[1],oa=(Da=oa.slice(1,(oa==null?void 0:oa.length)-1))==null?void 0:Da.split(","),F=!!(oa!=null&&oa.find(Dl=>Dl==="操作"))}const D=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="page"),re=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="rowButton"),le=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="extraButton"),q=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="tableContents"),xe=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="bottomButton");let Ce=[];const Ge=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="tableIndex");Ha.value=(N=(Ea=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="tableToForm"))==null?void 0:Ea[0])==null?void 0:N.contents,Te.value=(D==null?void 0:D.contents)??!0;let He=[];nr.value===""?He=B==null?void 0:B[0]:He=(B==null?void 0:B.find(oa=>(oa==null?void 0:oa.selectLabel)==="("+nr.value+")"))??(B==null?void 0:B.find(oa=>!(oa!=null&&oa.selectLabel)));let Qe=[];nr.value===""?Qe=Ge==null?void 0:Ge[0]:Qe=(Ge==null?void 0:Ge.find(oa=>(oa==null?void 0:oa.selectLabel)==="("+nr.value+")"))??(Ge==null?void 0:Ge.find(oa=>!(oa!=null&&oa.selectLabel)));let ba=[],za=[];if(((G=He==null?void 0:He.contents)==null?void 0:G.length)>0){let oa=[],Dl=He==null?void 0:He.contents;if(Array.isArray(Dl==null?void 0:Dl[0])&&((Ve=Dl==null?void 0:Dl[0])!=null&&Ve.every(qa=>!(qa!=null&&qa.children)))&&(Dl=Dl==null?void 0:Dl[0]),Dl.some(qa=>Array.isArray(qa)&&(qa==null?void 0:qa.find(Ye=>Ye.children))))oa=(sa=oe.getGradeColumns(Dl,F))==null?void 0:sa[0],oa!=null&&oa.find(qa=>(qa==null?void 0:qa.label)==="操作")||oa.push({label:"操作",prop:"operate",type:"operate"});else{let qa=Dl.some(Ye=>Array.isArray(Ye))?Dl==null?void 0:Dl[0]:Dl;qa!=null&&qa.find(Ye=>(Ye==null?void 0:Ye.label)==="操作")||qa.push({label:"操作",prop:"operate",type:"operate"}),qa==null||qa.forEach((Ye,ir)=>{var Fr,Yr,Ir,oi,xi,wi,Tr,Bn,Un,_i,yn,qn,Xt,Zt,Qt,es,as,ls,rs,ns,is;if((Yr=(Fr=Se.value)==null?void 0:Fr.split("/"))==null||Yr.forEach(cr=>{var _r,zn,os;cr!==""&&((os=(zn=(_r=cr==null?void 0:cr.split(E+"updateLoading"))==null?void 0:_r[0])==null?void 0:zn.split(E+"loading"))==null||os[0])}),Ye!=null&&Ye.methodContent){let cr=(xi=(oi=(Ir=Ye==null?void 0:Ye.methodContent)==null?void 0:Ir.replace("@","%%#"))==null?void 0:oi.split("%%#"))==null?void 0:xi[1];if(cr=cr==null?void 0:cr.slice(0,(cr==null?void 0:cr.length)-1),cr=oe.contentTransArrayToAllNoExtra(cr??"",","),(wi=cr==null?void 0:cr.find(_r=>_r==null?void 0:_r.includes("@Button")))!=null&&wi.includes("Prop")&&((Tr=cr==null?void 0:cr.find(_r=>_r==null?void 0:_r.includes("Type")))!=null&&Tr.includes("Manual"))){let _r=(Un=(Bn=cr==null?void 0:cr.find(zn=>zn==null?void 0:zn.includes("@Button")))==null?void 0:Bn.split(":"))==null?void 0:Un[1];_r=((qn=(yn=(_i=_r==null?void 0:_r.replaceAll("[",""))==null?void 0:_i.replaceAll("]",""))==null?void 0:yn.split(","))==null?void 0:qn[1])??"算法执行",ba.push(_r)}else if((Xt=cr==null?void 0:cr.find(_r=>_r==null?void 0:_r.includes("@Button")))!=null&&Xt.includes("Row")&&((Zt=cr==null?void 0:cr.find(_r=>_r==null?void 0:_r.includes("Type")))!=null&&Zt.includes("Manual"))){let _r=(es=(Qt=cr==null?void 0:cr.find(zn=>zn==null?void 0:zn.includes("@Button")))==null?void 0:Qt.split(":"))==null?void 0:es[1];_r=((rs=(ls=(as=_r==null?void 0:_r.replaceAll("[",""))==null?void 0:as.replaceAll("]",""))==null?void 0:ls.split(","))==null?void 0:rs[1])??"算法执行",za.push(_r)}}(ns=Ha.value)==null||ns.find(cr=>(cr==null?void 0:cr.prop)===(Ye==null?void 0:Ye.prop));let an=((is=Ye==null?void 0:Ye.filter)==null?void 0:is.includes("@EditRead=Read"))??!1;oa.push({label:(Ye==null?void 0:Ye.label)==="操作"?F?"操作":"":(Ye==null?void 0:Ye.label)??"",prop:(Ye==null?void 0:Ye.label)==="操作"?"operate":(Ye==null?void 0:Ye.prop)??"a"+ir,width:Ye!=null&&Ye.width?parseInt(Ye.width):"",fixed:(Ye==null?void 0:Ye.fixed)??void 0,sortable:(Ye==null?void 0:Ye.sortable)??!1,filterable:(Ye==null?void 0:Ye.filterable)??!1,operable:(Ye==null?void 0:Ye.operable)??!1,showSummary:(Ye==null?void 0:Ye.showSummary)??!1,align:(Ye==null?void 0:Ye.align)??"left",showOverflowTooltip:(Ye==null?void 0:Ye.showOverflowTooltip)??!0,isNotDrag:(Ye==null?void 0:Ye.isNotDrag)??!1,isEditCol:(Ye==null?void 0:Ye.isEditCol)??!1,isOperate:(Ye==null?void 0:Ye.isOperate)??!1,id:(Ye==null?void 0:Ye.id)??ir,type:(Ye==null?void 0:Ye.label)==="操作"?"operate":void 0,formType:(Ye==null?void 0:Ye.formType)??(Ye!=null&&Ye.groupSelect?"Select":""),disabled:Ye==null?void 0:Ye.disabled,options:(Ye==null?void 0:Ye.options)??[],value:(Ye==null?void 0:Ye.value)??"",isExistChild:(Ye==null?void 0:Ye.isExistChild)??!1,mainKey:(Ye==null?void 0:Ye.mainKey)??ir===0,allSelectionContents:(Ye==null?void 0:Ye.allContents)??[],filterContent:Ye==null?void 0:Ye.filterContents,menus:Ye==null?void 0:Ye.menus,groups:Ye==null?void 0:Ye.groups,words:Ye==null?void 0:Ye.words,filter:Ye==null?void 0:Ye.filter,bindMenus:Ye==null?void 0:Ye.bindMenus,fatherPath:Ye==null?void 0:Ye.fatherPath,isMainPath:Ye==null?void 0:Ye.isMainPath,required:(Ye==null?void 0:Ye.required)??!1,relatedContents:Ye==null?void 0:Ye.relatedContents,functionName:Ye==null?void 0:Ye.functionName,functionRelatedWords:Ye==null?void 0:Ye.functionRelatedWords,calculatorFilter:Ye==null?void 0:Ye.calculatorFilter,relatedPages:Ye==null?void 0:Ye.relatedPages,multiple:(Ye==null?void 0:Ye.multiple)??!1,multipleLimit:Ye==null?void 0:Ye.multipleLimit,isReadonly:an})})}oa=oa==null?void 0:oa.filter(qa=>{var Ye;return!((Ye=qa==null?void 0:qa.filter)!=null&&Ye.includes("@ShowHide=Hide"))}),j.value=(we=xe==null?void 0:xe[0])==null?void 0:we.contents;const en=oe.getNewColumnChild(oa);Ce=oe.getColumnChild(en);const Hn=qa=>Array.isArray(qa)?qa.map(Ye=>(Array.isArray(Ye==null?void 0:Ye.children)&&Ye.children.length>0?(Ye.sortable=!1,Hn(Ye.children)):(Ye==null?void 0:Ye.prop)==="operate"||(Ye==null?void 0:Ye.label)==="操作"||(Ye==null?void 0:Ye.type)==="operate"||(Ye.sortable=!1),Ye)):qa;Hn(en),await no(en),u0(ne.value,en),z.value=en,Ca.value=en,n.value=(da=z.value)==null?void 0:da.map(qa=>qa==null?void 0:qa.label);let zr=(tl=(Na=oe.getAllLeafNodes(z.value))==null?void 0:Na.filter(qa=>(qa==null?void 0:qa.type)!=="operate"))==null?void 0:tl.map((qa,Ye)=>({prop:(qa==null?void 0:qa.prop)??"a"+Ye,column:qa.label}));vr.value=zr;let Lr=[];nr.value===""?Lr=q==null?void 0:q[0]:Lr=(q==null?void 0:q.find(qa=>(qa==null?void 0:qa.selectLabel)==="("+nr.value+")"))??(q==null?void 0:q.find(qa=>!(qa!=null&&qa.selectLabel)));let Mr=Array.isArray((Ya=Lr==null?void 0:Lr.contents)==null?void 0:Ya[0])&&((fl=Lr==null?void 0:Lr.contents)!=null&&fl[0].every(qa=>Array.isArray(qa)))?(vl=Lr==null?void 0:Lr.contents)==null?void 0:vl[0]:Lr==null?void 0:Lr.contents;Qe!=null&&Qe.contents&&((ql=Qe==null?void 0:Qe.contents)==null?void 0:ql.length)!==0&&(Mr=(Ua=A.cloneDeep(Mr))==null?void 0:Ua.map((qa,Ye)=>{if(!Array.isArray(qa)){let ir={};for(let an in qa)an!=="id"&&an!=="index"&&(ir[an]=qa[an]);qa=Object.values(ir)}return qa}));const vo=!!((kl=z.value)!=null&&kl.find(qa=>qa.prop==="index"));Mr=mc(Mr,Qe==null?void 0:Qe.contents,vo);const Ln=[];Mr==null||Mr.forEach((qa,Ye)=>{var an;let ir={};if(Array.isArray(qa)){let Fr=[];qa==null||qa.filter(Yr=>!(Yr!=null&&Yr.id)).forEach((Yr,Ir)=>{var oi,xi,wi,Tr,Bn,Un;if((oi=zr==null?void 0:zr[Ir])!=null&&oi.prop&&!Array.isArray(Yr)){let _i={};_i[zr[Ir].column]=Yr,$!=null&&$.value&&((xi=$==null?void 0:$.value)==null?void 0:xi.length)>0&&((wi=$==null?void 0:$.value)!=null&&wi.find(yn=>JSON.stringify(yn==null?void 0:yn[0])===JSON.stringify(_i)))&&(Fr=(Tr=$==null?void 0:$.value)==null?void 0:Tr.find(yn=>JSON.stringify(yn==null?void 0:yn[0])===JSON.stringify(_i))),Fr&&Fr.length>0?ir[zr[Ir].prop]=Fr!=null&&Fr.find(yn=>{var qn;return((qn=Object.keys(yn))==null?void 0:qn[0])===zr[Ir].column})?(Bn=Fr==null?void 0:Fr.find(yn=>{var qn;return((qn=Object.keys(yn))==null?void 0:qn[0])===zr[Ir].column}))==null?void 0:Bn[zr[Ir].column]:Yr:ir[zr[Ir].prop]=Yr}else Array.isArray(Yr)&&((Un=zr[Ir])!=null&&Un.prop?ir[zr[Ir].prop]=Yr:ir.children=_t(Yr,zr))})}else ir=qa;if(Array.isArray(qa)&&qa.some(Fr=>Fr==null?void 0:Fr.id)){const Fr=(an=qa==null?void 0:qa.find(Yr=>Yr.id))==null?void 0:an.id;Ln.push(Object.assign(ir,{id:co(Fr)}))}else ir.id?Ln.push(ir):Ln.push(Object.assign(ir,{id:Ye.toString()}))});try{const qa=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),Ye=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null"),ir=qa==null?void 0:qa.tableId,an=qa==null?void 0:qa.compIndex;if(ir&&Array.isArray(Ye)&&Ye.length>0&&String(ir)===String(u==null?void 0:u.parentTableId)&&String(an)===String(u==null?void 0:u.index)){const Fr=new Set(Ln.map(Ir=>String(Ir==null?void 0:Ir.id))),Yr=Ye.filter(Ir=>!Fr.has(String(Ir)));if(Yr.length>0){const Ir=qa==null?void 0:qa.pageKey,oi=Ir!=null&&Ir.startsWith("/")?Ir.substring(1):Ir;((v==null?void 0:v[Ir])||(v==null?void 0:v[oi])||[]).filter(Tr=>{var Bn,Un;return((Bn=Tr==null?void 0:Tr.key)==null?void 0:Bn.type)==="data"&&String((Un=Tr==null?void 0:Tr.key)==null?void 0:Un.tableId)===String(ir)&&Yr.includes(Tr==null?void 0:Tr.id)}).forEach(Tr=>{var Bn;Fr.has(String(Tr==null?void 0:Tr.id))||(Ln.push({id:Tr==null?void 0:Tr.id,...((Bn=Tr==null?void 0:Tr.value)==null?void 0:Bn.tableData)||{}}),Fr.add(String(Tr==null?void 0:Tr.id)))})}}}catch{}let Rn=null;try{const qa=`ocr_committed_temp_ids_v1:${String((u==null?void 0:u.parentTableId)??"")}:${String((u==null?void 0:u.index)??"")}`,Ye=JSON.parse(sessionStorage.getItem(qa)||"null");Array.isArray(Ye)&&Ye.length>0&&(Rn=new Set(Ye.map(ir=>String(ir))))}catch{}const Ui=Array.from(((ja=La.value)==null?void 0:ja.values())||[]).filter(qa=>!(!(qa!=null&&qa._isOCRRow&&(qa==null?void 0:qa._ocrTableId)===(u==null?void 0:u.index))||Rn&&Rn.has(String(qa==null?void 0:qa.id)))),mo=(Ae.value||[]).map(qa=>String(qa==null?void 0:qa.id)),Gl=vi(Ln,mo);if(Ae.value=Ht(Gl,I,z.value),va.value=Gl,(dl=va.value)==null||dl.forEach(qa=>{var Ye;(Ye=La.value)==null||Ye.set(qa.id,qa)}),Rn&&Rn.size>0)try{const qa=new Set(Array.from(Rn.values()));Ae.value=(Ae.value||[]).filter(Ye=>!qa.has(String(Ye==null?void 0:Ye.id))),va.value=(va.value||[]).filter(Ye=>!qa.has(String(Ye==null?void 0:Ye.id))),qa.forEach(Ye=>{var ir,an;try{(an=(ir=La.value)==null?void 0:ir.delete)==null||an.call(ir,Ye)}catch{}})}catch{}const Pr=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),pt=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null");if(Pr&&Array.isArray(pt)&&pt.length>0&&String(Pr==null?void 0:Pr.compIndex)===String(u==null?void 0:u.index)){const qa=new Set((va.value||[]).map(Ye=>String(Ye==null?void 0:Ye.id)));pt.filter(Ye=>!qa.has(String(Ye)))}if(Ui.length>0){const qa=new Set((Ae.value||[]).map(ir=>ir==null?void 0:ir.id)),Ye=Ui.filter(ir=>!qa.has(ir.id));Ye.length>0&&(Ae.value=[...Ae.value||[],...Ye],va.value=[...va.value||[],...Ye],Ye.forEach(ir=>{var an;return(an=La.value)==null?void 0:an.set(ir.id,ir)}))}}else z.value=[],ye.value=[],Ae.value=[],va.value=[],La.value=new Map;if(za=[...new Set(za)],za=za==null?void 0:za.map(oa=>({label:oa,type:"methodButton"})),((Xa=re==null?void 0:re.contents)==null?void 0:Xa.length)>0?_a.value=re==null?void 0:re.contents:_a.value=[],_a.value=[..._a.value,...za],ba=[...new Set(ba)],ba=ba==null?void 0:ba.map(oa=>({label:oa,type:"methodButton"})),((pl=le==null?void 0:le.contents)==null?void 0:pl.length)>0)if((Nr=(Ll=(Nl=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="filterAllType"))==null?void 0:Nl.value)==null?void 0:Ll.find(oa=>(oa==null?void 0:oa.value)==="onButtonContents"))!=null&&Nr.content){let oa=($l=(wl=(Hl=p==null?void 0:p.find(Dl=>(Dl==null?void 0:Dl.key)==="filterAllType"))==null?void 0:Hl.value)==null?void 0:wl.find(Dl=>(Dl==null?void 0:Dl.value)==="onButtonContents"))==null?void 0:$l.content;if(oa=(er=oa==null?void 0:oa.split(":"))==null?void 0:er[1],oa=(Rl=oa.slice(1,(oa==null?void 0:oa.length)-1))==null?void 0:Rl.split(","),Re.value=(Ql=le==null?void 0:le.contents)==null?void 0:Ql.filter(Dl=>oa==null?void 0:oa.find(en=>en===(Dl==null?void 0:Dl.label))),Ue.value=(sr=le==null?void 0:le.contents)==null?void 0:sr.filter(Dl=>oa==null?void 0:oa.find(en=>en===(Dl==null?void 0:Dl.label))),(Jl=le==null?void 0:le.contents)!=null&&Jl.some(Dl=>(Dl==null?void 0:Dl.label)==="OCR识别")&&!((xr=Re.value)!=null&&xr.some(Dl=>(Dl==null?void 0:Dl.label)==="OCR识别"))){const Dl=(on=le==null?void 0:le.contents)==null?void 0:on.find(en=>(en==null?void 0:en.label)==="OCR识别");Re.value=[...Re.value,Dl],Ue.value=[...Ue.value,Dl]}W.value=!!(oa!=null&&oa.find(Dl=>Dl==="搜索")),V.value=!!(oa!=null&&oa.find(Dl=>Dl==="块状显示"))}else Re.value=le==null?void 0:le.contents,Ue.value=le==null?void 0:le.contents;else Re.value=[],Ue.value=[];if(Re.value=[...Re.value,...ba],Ue.value=[...Ue.value,...ba],typeof Se.value=="string"&&Se.value==="设备管理/试验设备"&&(u==null?void 0:u.compName)==="设备列表"?((wr=Re.value)!=null&&wr.some(oa=>(oa==null?void 0:oa.label)==="OCR识别")||(Re.value=[...Re.value||[],{label:"OCR识别"}]),(fr=Ue.value)!=null&&fr.some(oa=>(oa==null?void 0:oa.label)==="OCR识别")||(Ue.value=[...Ue.value||[],{label:"OCR识别"}])):(Re.value=(Re.value||[]).filter(oa=>(oa==null?void 0:oa.label)!=="OCR识别"),Ue.value=(Ue.value||[]).filter(oa=>(oa==null?void 0:oa.label)!=="OCR识别")),(mr=Re.value)!=null&&mr.some(oa=>(oa==null?void 0:oa.label)==="切换视图")||(Re.value=[...Re.value||[],{label:"切换视图"}]),(Wt=Ue.value)!=null&&Wt.some(oa=>(oa==null?void 0:oa.label)==="切换视图")||(Ue.value=[...Ue.value||[],{label:"切换视图"}]),Ce!=null&&Ce.some(oa=>{var Dl;return(oa==null?void 0:oa.calculatorFilter)&&((Dl=oa==null?void 0:oa.calculatorFilter)==null?void 0:Dl.includes("@Button"))})){let oa=(Kt=Ce==null?void 0:Ce.filter(zr=>{var Lr;return(zr==null?void 0:zr.calculatorFilter)&&((Lr=zr==null?void 0:zr.calculatorFilter)==null?void 0:Lr.includes("@Button"))}))==null?void 0:Kt.map(zr=>zr==null?void 0:zr.calculatorFilter),Dl=[],en=[],Hn=[];oa==null||oa.forEach(zr=>{var vo,Ln,Rn,Ui,mo;let Lr=(vo=oe.analyzeSplitToContent(zr,","))==null?void 0:vo.map(Gl=>((Gl==null?void 0:Gl[(Gl==null?void 0:Gl.length)-1])===","&&(Gl=Gl==null?void 0:Gl.slice(0,(Gl==null?void 0:Gl.length)-1)),Gl)),Mr=Lr==null?void 0:Lr.find(Gl=>Gl==null?void 0:Gl.includes("@Button"));if(Lr!=null&&Lr.find(Gl=>Gl==null?void 0:Gl.includes("Manual"))){Mr=(Rn=(Ln=Mr==null?void 0:Mr.replace("=","$R"))==null?void 0:Ln.split("$R"))==null?void 0:Rn[1],Mr=Mr==null?void 0:Mr.slice(1,(Mr==null?void 0:Mr.length)-1);let Gl=(Ui=oe.analyzeSplitToContent(Mr,","))==null?void 0:Ui.map(Pr=>((Pr==null?void 0:Pr[(Pr==null?void 0:Pr.length)-1])===","&&(Pr=Pr==null?void 0:Pr.slice(0,(Pr==null?void 0:Pr.length)-1)),Pr));Gl=Gl==null?void 0:Gl[0],Gl=Gl==null?void 0:Gl.slice(1,(Gl==null?void 0:Gl.length)-1),Gl=(mo=Gl==null?void 0:Gl.split(","))==null?void 0:mo.map(Pr=>({label:Pr,prop:Pr})),Mr!=null&&Mr.includes("Up")?Dl=[...Dl,...Gl??[]]:Mr!=null&&Mr.includes("Line")?en=[...en,...Gl??[]]:Hn=[...Hn,...Gl??[]]}}),Re.value=[...Dl,...Re.value??[]],_a.value=[...en,..._a.value??[]],Hn.value=[...Hn,...Hn.value??[]]}Ba.value=((Gt=Ae==null?void 0:Ae.value)==null?void 0:Gt.length)??0,Ft(Ae.value),jr.value=Ae.value,Fl.value&&(z.value=(Jt=(Yt=ye.value)==null?void 0:Yt.filter(oa=>(oa==null?void 0:oa.label)!=="操作"))==null?void 0:Jt.map(oa=>{var Dl;return{...oa,type:"edit",optionUrl:oa!=null&&oa.formMenuSelect&&((Dl=oa==null?void 0:oa.formMenuSelect)==null?void 0:Dl.length)>0?{groupSelect:oa==null?void 0:oa.groupSelect,menuSelect:oa==null?void 0:oa.formMenuSelect,selectRelateType:"",type:oa==null?void 0:oa.formType}:null}}),dt())};e.watch(()=>[u.itemData,nr.value,Xr.value,Wr.value,$==null?void 0:$.value],async()=>{var p,v,B,I,F,D;if((p=u==null?void 0:u.itemData)!=null&&p.find(re=>(re==null?void 0:re.key)==="columnPath")&&!((v=X.value)!=null&&v.find(re=>{var le,q;return(re==null?void 0:re.key)===((q=(le=u==null?void 0:u.itemData)==null?void 0:le.find(xe=>(xe==null?void 0:xe.key)==="columnPath"))==null?void 0:q.contents)}))){let re=X.value,le={key:(I=(B=u==null?void 0:u.itemData)==null?void 0:B.find(q=>(q==null?void 0:q.key)==="columnPath"))==null?void 0:I.contents,value:(D=(F=u==null?void 0:u.itemData)==null?void 0:F.find(q=>(q==null?void 0:q.key)==="columnUsingPath"))==null?void 0:D.contents};re!=null&&re.find(q=>(q==null?void 0:q.key)===(le==null?void 0:le.key))?re=re==null?void 0:re.map(q=>((q==null?void 0:q.key)===(le==null?void 0:le.key)&&(q.value=le.value),q)):re.push(le),ua.setTableViewContents(re)}await Ut(u.itemData,u.allMapContents)},{deep:!0,immediate:!0}),e.watch(()=>u==null?void 0:u.operatingForm,p=>{p!=null&&p.form&&(Fi(p==null?void 0:p.form),be.value=p==null?void 0:p.dialogTitle,Qa.value=!0,Be.value=!0)},{immediate:!0,deep:!0});const wu=()=>{var p;(p=k.value)!=null&&p.includes("read")&&(Fl.value=!Fl.value)},_u=()=>{Er.value=!Er.value};e.watch(()=>{var p;return(p=u==null?void 0:u.config)==null?void 0:p.viewport},p=>{var v;k.value=p,(p==null?void 0:p.length)===0?Fl.value=!1:(p!=null&&p.includes("read")||(Fl.value=!0),p!=null&&p.includes("edit")||(Fl.value=!1)),M.value=((v=u==null?void 0:u.config)==null?void 0:v.showIndex)||Fl.value},{immediate:!0}),e.watch(()=>Fl.value,p=>{var v;p?(dt("viewChange"),ua.setCacheUpdatingData(null)):(Re.value=Ue.value,z.value=Ca.value,H.value&&(ua.setTableLoading(u==null?void 0:u.index),_e("change",H.value))),M.value=p||((v=u==null?void 0:u.config)==null?void 0:v.showIndex),Wl.value=[]},{immediate:!0}),e.watch(()=>{var p;return(p=_n.value)==null?void 0:p.length},p=>{p===0&&(me.currentPage=1)}),e.watch(()=>u==null?void 0:u.compNames,p=>{f.contents=[{label:"列表名",prop:"groupName",name:"列表名",type:"select",value:"",id:0,contents:p||[],width:1}]},{immediate:!0}),e.ref(!1);const Su=(p,v)=>{var B;dt("createClick"),v===me.pageSize&&(me.currentPage=Math.ceil(((B=Ae.value)==null?void 0:B.length)/me.pageSize))},Eu=async(p,v,B)=>{var F,D,re,le,q;const I=(v==null?void 0:v.property)??(v==null?void 0:v.prop);if(I&&fo.includes(I)&&B!==void 0&&B!==null&&String(B).trim()!==""){const xe=String(B).trim();if(await ut(xe,p==null?void 0:p.id)){Wa.ElMessage.warning("当前任务下通道号不能重复,请重新选择");const Ge=(F=Ae.value)==null?void 0:F.findIndex(Qe=>(Qe==null?void 0:Qe.id)===(p==null?void 0:p.id)),He=Ge!==-1?(re=(D=Ae.value)==null?void 0:D[Ge])==null?void 0:re[I]:void 0;I&&(p[I]=He??"");return}}if(Fl.value){const xe=p==null?void 0:p.id;xe!=null&&(h.value.has(xe)||h.value.set(xe,A.cloneDeep(p)),s.value.add(xe));const Ce=(le=Ae.value)==null?void 0:le.findIndex(Ge=>(Ge==null?void 0:Ge.id)===(p==null?void 0:p.id));Ce!==-1&&I&&(Ae.value[Ce]={...Ae.value[Ce],[I]:B}),ho(B,p,v);return}ho(B,p,v),Il.value=A.cloneDeep(p),Ia.value=p==null?void 0:p.id,Ba.value=(q=Ae.value)==null?void 0:q.length,be.value=p!=null&&p._isTemp?"新增":"编辑",Hi(!1)},Cu=async()=>{var p,v;try{const B=[];if(u!=null&&u.related&&Array.isArray(u.related)&&(console.log("props.related",u.related),u.related.forEach(I=>{if(typeof I=="string"&&I.includes("content_")){const F=I.split("_")[1];F&&(B.push(`content_${F}`),B.push(`struct_${F}`))}})),B.length===0&&(u!=null&&u.itemData)){const I=(v=(p=u.itemData)==null?void 0:p.find(F=>(F==null?void 0:F.key)==="contentTableId"))==null?void 0:v.contents;I&&(B.push(`content_${I}`),B.push(`struct_${I}`))}return B}catch(B){return console.error("获取 tableNames 失败:",B),[]}},Du=async(p,v,B)=>{var D,re;if(!B||typeof B!="string"||B.trim()===""){const le=(v==null?void 0:v.property)??(v==null?void 0:v.prop),q=`${p==null?void 0:p.id}:${le}`;d.value.delete(q),b.value.set(q,!1);return}const I=(v==null?void 0:v.property)??(v==null?void 0:v.prop),F=`${p==null?void 0:p.id}:${I}`;b.value.set(F,!0);try{const le=await Cu();if(le.length===0){console.warn("未找到同名表,跳过全局搜索"),d.value.delete(F),b.value.set(F,!1);return}const q=parseInt((D=ml.value)==null?void 0:D.plat_id);if(!q){console.warn("platId 无效,跳过全局搜索"),d.value.delete(F),b.value.set(F,!1);return}const xe=await A.getAllTables({platId:q,tableNames:le??[]}),Ce=((re=xe==null?void 0:xe.data)==null?void 0:re.result)||[],Ge=[],He=[];for(let Qe=0;Qe<Ce.length;Qe+=2)Qe+1<Ce.length&&He.push([Ce[Qe],Ce[Qe+1]]);He.forEach(([Qe,ba])=>{var ll;if(!Array.isArray(Qe)||Qe.length===0||!Array.isArray(ba)||ba.length===0)return;const za=ba[0];let $a=((ll=za==null?void 0:za.结构)==null?void 0:ll.contents)??[];if(!Array.isArray($a)||$a.length===0)return;let ea=A.cloneDeep($a);if(Array.isArray(ea==null?void 0:ea[0])&&(ea=oe.getColumnChild(ea[0])),!Array.isArray(ea)||ea.length===0||!ea.some(ve=>(ve==null?void 0:ve.prop)===I))return;[...Qe].sort((ve,Pa)=>{const ya=Number((ve==null?void 0:ve.update_time)??0);return Number((Pa==null?void 0:Pa.update_time)??0)-ya}).slice(0,20).forEach(ve=>{const Pa=ve[I];if(Pa!=null){const ya=String(Pa);ya.toLowerCase().includes(B.toLowerCase())&&Ge.findIndex(Ea=>{var N;return ve.id&&((N=Ea.rowData)==null?void 0:N.id)===ve.id?!0:Ea.label===ya})===-1&&Ge.push({label:ya,rowData:A.cloneDeep(ve),sourceTable:(za==null?void 0:za.source_table)||""})}})}),d.value.set(F,Ge)}catch(le){console.error("全局搜索建议失败:",le),d.value.delete(F)}finally{b.value.set(F,!1)}},Tu=(p,v,B)=>{if(!Fl.value)return;const I=(v==null?void 0:v.property)??(v==null?void 0:v.prop),F=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"";if(F&&F.toUpperCase()!=="INPUT"&&F!=="")return;const D=`${p==null?void 0:p.id}:${I}`;if(m.has(D)&&clearTimeout(m.get(D)),!B||B.trim()===""){d.value.delete(D),b.value.set(D,!1);return}const re=setTimeout(()=>{Du(p,{prop:I,property:I},B),m.delete(D)},300);m.set(D,re)};function Bu(p,v){const B=`${p==null?void 0:p.id}:${(v==null?void 0:v.property)??(v==null?void 0:v.prop)}`;return d.value.get(B)||[]}const Nu=(p,v,B)=>{var xe;if(!B||!B.rowData)return;const I=B.rowData,F=p==null?void 0:p.id,D=(v==null?void 0:v.property)??(v==null?void 0:v.prop);(oe.getAllLeafNodes(z.value)||[]).filter(Ce=>(Ce==null?void 0:Ce.type)!=="operate"&&(Ce==null?void 0:Ce.label)!=="操作"&&(Ce==null?void 0:Ce.prop)!=="operate").forEach(Ce=>{const Ge=Ce==null?void 0:Ce.prop;Ge&&I[Ge]!==void 0&&(p[Ge]=I[Ge])}),(xe=Ae.value)==null||xe.findIndex(Ce=>(Ce==null?void 0:Ce.id)===F),F!=null&&(h.value.has(F)||h.value.set(F,A.cloneDeep(p)),s.value.add(F));const q=`${F}:${D}`;d.value.delete(q),b.value.set(q,!1),ho(p[D],p,v)},nn=p=>{var q,xe,Ce,Ge,He,Qe,ba,za,$a,ea,al;const{row:v,column:B,item:I,slotData:F}=p;let D=v!=null&&v[B==null?void 0:B.prop]||(v==null?void 0:v[B==null?void 0:B.prop])===0?((xe=(q=v==null?void 0:v[B==null?void 0:B.prop])==null?void 0:q[0])==null?void 0:xe.contents)??((v==null?void 0:v[B==null?void 0:B.prop])===0?"0":v==null?void 0:v[B==null?void 0:B.prop]):((Ge=(Ce=v==null?void 0:v[I==null?void 0:I.prop])==null?void 0:Ce[0])==null?void 0:Ge.contents)??(v==null?void 0:v[I==null?void 0:I.prop])??((Qe=(He=F==null?void 0:F[I==null?void 0:I.prop])==null?void 0:He[0])==null?void 0:Qe.contents)??(F==null?void 0:F[I==null?void 0:I.prop])??(($a=(za=v==null?void 0:v[(ba=I==null?void 0:I.child)==null?void 0:ba.prop])==null?void 0:za[0])==null?void 0:$a.contents)??(v==null?void 0:v[(ea=I==null?void 0:I.child)==null?void 0:ea.prop]),le=Array.isArray(D)&&!(D!=null&&D.every(ka=>typeof ka=="string"||typeof ka=="number"))?"查看":D;if(le=Array.isArray(le)?le.join(","):le,(B==null?void 0:B.formType)==="Date")if(!le||le===""||le===null||le===void 0)le="";else{const ka=A.dayjs(le,["YYYY-MM-DD","YYYY/MM/DD","YYYY年MM月DD日","YYYYMMDD"],!0);le=ka.isValid()?ka.format("YYYYMMDD"):le??""}return Array.isArray(B==null?void 0:B.relatedPages)&&((al=B==null?void 0:B.relatedPages)==null?void 0:al.length)>0&&(le="详情页"),le},Au=p=>{var xe,Ce,Ge,He,Qe,ba,za,$a,ea,al;const{row:v,column:B,item:I,slotData:F}=p;let D=v!=null&&v[B==null?void 0:B.prop]?((Ce=(xe=v==null?void 0:v[B==null?void 0:B.prop])==null?void 0:xe[0])==null?void 0:Ce.contents)??(v==null?void 0:v[B==null?void 0:B.prop]):((He=(Ge=v==null?void 0:v[I==null?void 0:I.prop])==null?void 0:Ge[0])==null?void 0:He.contents)??(v==null?void 0:v[I==null?void 0:I.prop])??((ba=(Qe=F==null?void 0:F[I==null?void 0:I.prop])==null?void 0:Qe[0])==null?void 0:ba.contents)??(F==null?void 0:F[I==null?void 0:I.prop])??((ea=($a=v==null?void 0:v[(za=I==null?void 0:I.child)==null?void 0:za.prop])==null?void 0:$a[0])==null?void 0:ea.contents)??(v==null?void 0:v[(al=I==null?void 0:I.child)==null?void 0:al.prop]);const le=Array.isArray(D)&&!(D!=null&&D.every(ka=>typeof ka=="string"||typeof ka=="number")),q=Array.isArray(D)&&(D==null?void 0:D.find(ka=>ka==null?void 0:ka.url));return le&&q},zu=p=>{var F,D,re,le;if(!(p!=null&&p.column))return!1;const v=Se.value==="试验任务/任务管理",B=(u==null?void 0:u.compName)==="任务列表",I=((D=(F=p==null?void 0:p.column)==null?void 0:F.filter)==null?void 0:D.includes("@TextRGBA"))||((le=(re=p==null?void 0:p.column)==null?void 0:re.filter)==null?void 0:le.includes("@TextBackRGBA"));return v&&B&&I},Mu=(p,v)=>p.find(B=>Object.values(B).some(I=>I===v));return e.watch(()=>De.value,async p=>{if(p){ue.setContentLoading(!0),await e.nextTick();const v=Mu(Ae.value,p==null?void 0:p.data);if(!v)return ue.setContentLoading(!1);await Vi(p==null?void 0:p.data,null,v,{data:p==null?void 0:p.data}),ue.setContentLoading(!1)}},{deep:!0,immediate:!0}),e.watch(()=>u==null?void 0:u.cacheNewData,p=>{var v;p&&(Array.isArray(p)?p.forEach(B=>{var I,F,D,re,le;if(换,String(B==null?void 0:B.compId)===String(u==null?void 0:u.index)&&(B!=null&&B.resId)&&((I=B==null?void 0:B.data)!=null&&I.id)){const q=(F=B==null?void 0:B.data)==null?void 0:F.id,xe=B==null?void 0:B.resId;if(Ae.value=(D=Ae.value)==null?void 0:D.map(Ce=>{if((Ce==null?void 0:Ce.id)===q){const Ge={...Ce,id:xe};return delete Ge._isOCRRow,delete Ge._ocrTableId,Ge}return Ce}),(le=(re=La.value)==null?void 0:re.has)!=null&&le.call(re,q)){const Ge={...La.value.get(q)||{},id:xe};delete Ge._isOCRRow,delete Ge._ocrTableId,La.value.delete(q),La.value.set(xe,Ge)}Ka(u==null?void 0:u.index,q,xe)}}):String(p==null?void 0:p.compId)===String(u==null?void 0:u.index)&&(Ae.value=(v=Ae.value)==null?void 0:v.map(B=>{var I;if((B==null?void 0:B.id)===((I=p==null?void 0:p.data)==null?void 0:I.id)){const F={...B,id:p==null?void 0:p.resId};return delete F._isOCRRow,delete F._ocrTableId,F}return B})))},{immediate:!0,deep:!0}),(p,v)=>{var ea,al,ka,ll;const B=e.resolveComponent("svg-icon"),I=e.resolveComponent("el-popover"),F=e.resolveComponent("el-switch"),D=e.resolveComponent("el-checkbox"),re=e.resolveComponent("el-radio"),le=e.resolveComponent("el-radio-group"),q=e.resolveComponent("el-checkbox-group"),xe=e.resolveComponent("el-button"),Ce=e.resolveComponent("el-icon"),Ge=e.resolveComponent("el-progress"),He=e.resolveComponent("el-alert"),Qe=e.resolveComponent("el-table-column"),ba=e.resolveComponent("el-table"),za=e.resolveComponent("el-upload"),$a=e.resolveComponent("el-text");return e.openBlock(),e.createElementBlock("div",J0,[kr.value?(e.openBlock(),e.createBlock(cl.ssTable,{id:"excel-table",pageObj:me,showIndex:M.value,isTree:(ea=a.compItem)==null?void 0:ea.isTree,summaryInfo:J,columns:z.value,defaultSort:te,isCardViewport:Er.value,checkedColumns:n.value,key:qr.value+JSON.stringify(z.value),tableData:_n.value,isEditViewport:Fl.value,isShowPagination:Te.value,isShowEdit:!1,isShowDelete:!1,allowSelect:C.value,onDbClickRow:An,extraButton:Re.value,rowButton:_a.value,cacheExtraButtons:Ue.value,isClearSelection:((al=Wl.value)==null?void 0:al.length)===0,onDoCurrentChange:Mi,onDoSizeChange:jo,onSortChange:Ho,onContentClick:Vi,onRowClick:at,onSelectChange:Jo,onCellChange:Eu,onCellInput:Tu,onSelectSuggest:Nu,onChange:ho,onPreview:to,onSubmitEditingTable:lo,onHandleColEditChange:eo,onHandleColTypeChange:ln,onClickButton:st,onAddNewRow:Ko,bottomButton:j.value,allowRowAddOrDelete:ni.value},e.createSlots({headerButton:e.withCtx(ve=>{var Pa,ya,Da,Ea;return[a.showHeader?(e.openBlock(),e.createBlock(Cf,{key:0,id:"tableHeaderButton",pageLayout:a.pageLayout,lockingPage:e.unref(ha)===e.unref(Se),filterValues:et.value,selectNums:(Pa=Wl.value)==null?void 0:Pa.length,dataNums:(ya=Ae.value)==null?void 0:ya.length,compName:a.compName,isDevMode:a.isDevMode,buttons:ve.buttons,menuFilter:(Ea=(Da=a.compItem)==null?void 0:Da.component)==null?void 0:Ea.menuFilter,onButtonClick:v[1]||(v[1]=(N,G,Ve)=>st(N,G,{extra:Ve})),columns:z.value,onFilter:uo,onGetImportData:qo,level:a.level,filterShow:W.value},null,8,["pageLayout","lockingPage","filterValues","selectNums","dataNums","compName","isDevMode","buttons","menuFilter","columns","level","filterShow"])):e.createCommentVNode("",!0)]}),viewport:e.withCtx(()=>{var ve,Pa,ya,Da;return[((ve=Ae.value)==null?void 0:ve.length)>0&&a.allowOperate&&V.value?(e.openBlock(),e.createElementBlock("div",Q0,[(Pa=k.value)!=null&&Pa.includes("read")&&((ya=k.value)!=null&&ya.includes("edit"))&&((Da=_a.value)!=null&&Da.some(Ea=>(Ea==null?void 0:Ea.label)==="编辑"))&&!Er.value&&e.unref(ha)!==e.unref(Se)?(e.openBlock(),e.createElementBlock("span",{key:0,title:"编辑表格",onClick:wu},[e.createVNode(B,{name:"editTable",class:"view-icon"})])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]}),rowCreate:e.withCtx(({row:ve,index:Pa})=>[e.createElementVNode("span",{title:"新增",class:"row-create-wrap",onClick:ya=>Su(ve,Pa)},[e.createVNode(B,{name:"rowCreate",style:{width:"10px",height:"10px"}})],8,e3)]),operateCol:e.withCtx(()=>[e.createVNode(I,{title:"选择显示列信息",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:mu,onBeforeEnter:yu},{reference:e.withCtx(()=>[e.createElementVNode("span",a3,[e.createVNode(B,{name:"operate",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",l3,[v[20]||(v[20]=e.createElementVNode("div",{class:"group-title"},"表格操作",-1)),e.createVNode(F,{"model-value":P.value,"active-text":"排序","inactive-text":"",style:{"margin-right":"8px"},onChange:v[2]||(v[2]=ve=>io(ve))},null,8,["model-value"]),v[21]||(v[21]=e.createElementVNode("div",{class:"group-title"},"表格列操作",-1)),e.createVNode(q,{modelValue:n.value,"onUpdate:modelValue":v[3]||(v[3]=ve=>n.value=ve),style:{height:"100%"},min:2,ref_key:"checkboxGroupRef",ref:i},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(bn.value,ve=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:ve.label},[e.createVNode(D,{value:ve.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",{title:ve.label,style:{display:"inline-block",width:"250px",overflow:"hidden","text-overflow":"ellipsis","white-space":"nowrap"}},e.toDisplayString(ve.label),9,r3)]),_:2},1032,["value"]),e.createVNode(I,{"popper-class":"col-operate-popover",title:"列操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(B,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Pa;return[e.createElementVNode("div",n3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Pa=Object.keys(ve))==null?void 0:Pa.filter(ya=>{var Da;return(Da=_.value)==null?void 0:Da.find(Ea=>(Ea==null?void 0:Ea.value)===ya)}),ya=>{var Da,Ea;return e.openBlock(),e.createElementBlock("div",{key:ya},[L[ya]=="radio"?(e.openBlock(),e.createElementBlock("div",i3,[v[19]||(v[19]=e.createElementVNode("div",null,"固定:",-1)),e.createVNode(le,{"model-value":ve==null?void 0:ve[ya],onChange:N=>Qn(N,ya,ve)},{default:e.withCtx(()=>{var N,G;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((G=(N=_.value)==null?void 0:N.find(Ve=>(Ve==null?void 0:Ve.value)===ya))==null?void 0:G.options,Ve=>(e.openBlock(),e.createBlock(re,{key:Ve==null?void 0:Ve.value,label:Ve==null?void 0:Ve.value,value:Ve==null?void 0:Ve.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(Ve==null?void 0:Ve.label),1)]),_:2},1032,["label","value"]))),128))]}),_:2},1032,["model-value","onChange"])])):e.createCommentVNode("",!0),L[ya]=="switch"?(e.openBlock(),e.createBlock(F,{key:1,"model-value":ve==null?void 0:ve[ya],"active-text":(Ea=(Da=_.value)==null?void 0:Da.find(N=>(N==null?void 0:N.value)===ya))==null?void 0:Ea.label,onChange:N=>Qn(N,ya,ve)},null,8,["model-value","active-text","onChange"])):e.createCommentVNode("",!0)])}),128))])]}),_:2},1024),e.createElementVNode("span",o3,[e.createVNode(B,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:1},8,["modelValue"])])):e.createCommentVNode("",!0)]),_:1})]),content:e.withCtx(ve=>{var Pa,ya,Da,Ea,N,G,Ve,sa,we,da,Na,tl,Ya,fl,vl,ql,Ua,kl,ja,dl;return[((Pa=ve==null?void 0:ve.column)==null?void 0:Pa.label)==="证书附件"||((ya=ve==null?void 0:ve.column)==null?void 0:ya.prop)==="证书附件"?(e.openBlock(),e.createElementBlock("div",t3,[e.createVNode(B,{name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(Xa=>bi(ve),["stop"]),title:"查看OCR图片"},null,8,["onClick"])])):Au(ve)?(e.openBlock(),e.createBlock(I,{key:1,"popper-class":"file-popover",placement:"right",trigger:"hover",effect:"light",width:"auto"},{reference:e.withCtx(()=>[e.createElementVNode("span",s3,e.toDisplayString(nn(ve)),1)]),default:e.withCtx(()=>{var Xa,pl;return[e.createElementVNode("div",c3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((pl=ve==null?void 0:ve.row)==null?void 0:pl[(Xa=ve==null?void 0:ve.column)==null?void 0:Xa.prop],Nl=>(e.openBlock(),e.createElementBlock("div",u3,[e.createElementVNode("div",{class:"prop-url",title:ai(Nl),onClick:Ll=>mi(Nl)},e.toDisplayString(ai(Nl)),9,d3),e.createElementVNode("div",{class:"prop-download",onClick:Ll=>Zo(Nl)}," 下载 ",8,p3)]))),256))])]}),_:2},1024)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[zu(ve)?(e.openBlock(),e.createBlock(Hu,{key:0,value:nn(ve),columnContent:ve==null?void 0:ve.column},null,8,["value","columnContent"])):(e.openBlock(),e.createElementBlock("div",{key:1,class:"table-cell-content",style:e.normalizeStyle({color:!Array.isArray(nn(ve))&&((Ea=(Da=nn(ve))==null?void 0:Da.toString())!=null&&Ea.includes(".txt")||(G=(N=nn(ve))==null?void 0:N.toString())!=null&&G.includes(".cpt")||(sa=(Ve=nn(ve))==null?void 0:Ve.toString())!=null&&sa.includes(".cyd"))?"var(--vertical-menuitem-active-bg)":"",textDecoration:!Array.isArray(nn(ve))&&((da=(we=nn(ve))==null?void 0:we.toString())!=null&&da.includes(".txt")||(tl=(Na=nn(ve))==null?void 0:Na.toString())!=null&&tl.includes(".cpt")||(fl=(Ya=nn(ve))==null?void 0:Ya.toString())!=null&&fl.includes(".cyd"))?"underline":"",cursor:!Array.isArray(nn(ve))&&((ql=(vl=nn(ve))==null?void 0:vl.toString())!=null&&ql.includes(".txt")||(kl=(Ua=nn(ve))==null?void 0:Ua.toString())!=null&&kl.includes(".cpt")||(dl=(ja=nn(ve))==null?void 0:ja.toString())!=null&&dl.includes(".cyd"))?"pointer":"",marginLeft:(ve==null?void 0:ve.colIndex)===0?`${((ve==null?void 0:ve.level)??0)*20}px`:0}),onClick:Xa=>{var pl;return Xn(nn(ve),((pl=ve==null?void 0:ve.column)==null?void 0:pl.relatedPages)??[])}},e.toDisplayString(nn(ve)===0?"0":nn(ve)),13,f3))],64))]}),_:2},[((ka=_a.value)==null?void 0:ka.length)>0?{name:"actions",fn:e.withCtx(({item:ve,fIndex:Pa})=>[e.createVNode(I,{title:"",placement:"left-start","popper-class":"menu-operate-popover"},{reference:e.withCtx(()=>[e.createVNode(B,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"},onClick:v[0]||(v[0]=e.withModifiers(()=>{},["stop"]))})]),default:e.withCtx(()=>[e.createElementVNode("div",X0,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($i(_a.value,ve),(ya,Da)=>(e.openBlock(),e.createElementBlock("div",{class:"menu-config-item",key:Da,onClick:e.withModifiers(Ea=>st(ya==null?void 0:ya.label,ve,{extra:ya}),["stop"])},[e.createElementVNode("div",{style:e.normalizeStyle({color:ya==null?void 0:ya.textColor}),class:"extra-button-label"},e.toDisplayString(ya==null?void 0:ya.label),5)],8,Z0))),128))])]),_:2},1024)]),key:"0"}:void 0]),1032,["pageObj","showIndex","isTree","summaryInfo","columns","defaultSort","isCardViewport","checkedColumns","tableData","isEditViewport","isShowPagination","allowSelect","extraButton","rowButton","cacheExtraButtons","isClearSelection","bottomButton","allowRowAddOrDelete"])):e.createCommentVNode("",!0),Fl.value?(e.openBlock(),e.createElementBlock("div",h3,[e.createVNode(xe,{id:"themeBorderButton",onClick:Yo},{default:e.withCtx(()=>v[22]||(v[22]=[e.createTextVNode("取消")])),_:1,__:[22]}),e.createVNode(xe,{class:"ok-button",id:"themeButton",onClick:Oi},{default:e.withCtx(()=>v[23]||(v[23]=[e.createTextVNode("保存")])),_:1,__:[23]})])):e.createCommentVNode("",!0),e.createVNode(Ar.ssDialog,{title:be.value,visible:Be.value,width:or.value,onBeforeDestroy:oo,style:{height:"74%"}},{default:e.withCtx(()=>[e.createElementVNode("div",v3,[e.createVNode(cl.ssForm,{ref_key:"formRef",ref:ae,rowContents:Ne.value,showOperator:!1,onChange:gu,isEnableWrap:!1,onFixChangeValue:Qo,onClickTrigger:ei,isEdit:fa.value,onBlurChange:ro,onCreate:hi,onTagChange:On},null,8,["rowContents","isEdit"])])]),footer:e.withCtx(()=>[Qa.value?(e.openBlock(),e.createElementBlock("div",m3,[e.createVNode(xe,{onClick:v[4]||(v[4]=ve=>Be.value=!1),id:"themeBorderButton"},{default:e.withCtx(()=>v[24]||(v[24]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[24]}),e.createVNode(xe,{class:"ok-button",onClick:v[5]||(v[5]=ve=>Hi(!0)),id:"themeButton"},{default:e.withCtx(()=>v[25]||(v[25]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[25]})])):e.createCommentVNode("",!0)]),_:1},8,["title","visible","width"]),e.createVNode(Ar.ssDialog,{title:be.value,visible:Xe.value,width:Ze.value,onBeforeDestroy:v[7]||(v[7]=ve=>Xe.value=!1)},{default:e.withCtx(()=>[e.createVNode($f)]),footer:e.withCtx(()=>[e.createElementVNode("div",y3,[e.createVNode(xe,{onClick:v[6]||(v[6]=ve=>Xe.value=!1),class:"cancel-button",id:"themeBorderButton"},{default:e.withCtx(()=>v[26]||(v[26]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[26]}),e.createVNode(xe,{class:"ok-button",onClick:lt,id:"themeButton"},{default:e.withCtx(()=>v[27]||(v[27]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[27]})])]),_:1},8,["title","visible","width"]),Q.value?(e.openBlock(),e.createBlock(cl.ssFilePreview,{key:2,fileDataList:ca.value,onDestroy:Pi},null,8,["fileDataList"])):e.createCommentVNode("",!0),$e.value?(e.openBlock(),e.createBlock(Ar.ssDialog,{key:3,visible:$e.value,onBeforeDestroy:hu,style:{height:"80vh",width:"80vw"},"body-class":"three-dialog-body","footer-class":"three-dialog-footer"},{default:e.withCtx(()=>[e.createVNode(Bo.ThreeViewerHost,{files:Pe.value,threeData:T.value},null,8,["files","threeData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0),e.createVNode(Ar.ssDialog,{title:"OCR扫描录入",visible:ma.value,"close-on-click-modal":!1,onBeforeDestroy:Ml,width:"1000px",dialogHeight:700,minWidth:900,minHeight:600,class:"ocr-upload-dialog",resizable:!0},{default:e.withCtx(()=>[v[38]||(v[38]=e.createElementVNode("div",{class:"ocr-header-bg"},null,-1)),e.createElementVNode("div",g3,[e.createElementVNode("div",b3,[e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:Ga.value===1}])},v[28]||(v[28]=[e.createElementVNode("div",{class:"step-circle"},"1",-1),e.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件识别",-1)]),2),v[31]||(v[31]=e.createElementVNode("div",{class:"ocr-step-connector"},null,-1)),e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:Ga.value===2}])},v[29]||(v[29]=[e.createElementVNode("div",{class:"step-circle"},"2",-1),e.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件确认",-1)]),2),v[32]||(v[32]=e.createElementVNode("div",{class:"ocr-step-connector"},null,-1)),e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:Ga.value===3}])},v[30]||(v[30]=[e.createElementVNode("div",{class:"step-circle"},"3",-1),e.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件提交",-1)]),2)]),Ga.value===1?(e.openBlock(),e.createElementBlock("div",k3,[e.createVNode(xe,{onClick:t,class:"ocr-action-btn",disabled:il.value,size:"default"},{default:e.withCtx(()=>v[33]||(v[33]=[e.createTextVNode("扫描文件 ")])),_:1,__:[33]},8,["disabled"]),e.createVNode(xe,{onClick:un,class:"ocr-action-btn",disabled:il.value,size:"default"},{default:e.withCtx(()=>v[34]||(v[34]=[e.createTextVNode("上传文件 ")])),_:1,__:[34]},8,["disabled"])])):e.createCommentVNode("",!0),Ga.value===1?(e.openBlock(),e.createElementBlock("div",x3,[e.createElementVNode("div",w3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Aa.value,(ve,Pa)=>{var ya;return e.openBlock(),e.createElementBlock("div",{key:Pa,class:"ocr-file-item"},[e.createElementVNode("div",_3,[ve.raw&&((ya=ve.raw.type)!=null&&ya.startsWith("image/"))?(e.openBlock(),e.createElementBlock("img",{key:0,src:Kl(ve),alt:"预览",class:"thumbnail-image"},null,8,S3)):(e.openBlock(),e.createElementBlock("div",E3,[e.createVNode(Ce,{size:40},{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.document_default))]),_:1})])),e.createElementVNode("div",{class:e.normalizeClass(["file-progress-ring",{uploading:Ol(ve)==="uploading",processing:Ol(ve)==="processing",completed:Ol(ve)==="completed"||Ol(ve)==="uploaded",failed:Ol(ve)==="failed"}])},[(e.openBlock(),e.createElementBlock("svg",C3,[v[35]||(v[35]=e.createElementVNode("circle",{class:"progress-ring-bg",cx:"18",cy:"18",r:"16",fill:"none",stroke:"#e4e7ed","stroke-width":"2"},null,-1)),e.createElementVNode("circle",{class:e.normalizeClass(["progress-ring-fill",{completed:Ol(ve)==="completed"||Ol(ve)==="uploaded",uploading:Ol(ve)==="uploading",processing:Ol(ve)==="processing",failed:Ol(ve)==="failed"}]),cx:"18",cy:"18",r:"16",fill:"none",stroke:Ol(ve)==="failed"?"#f56c6c":Ol(ve)==="completed"||Ol(ve)==="uploaded"?"#67c23a":"#409eff","stroke-width":Ol(ve)==="completed"||Ol(ve)==="uploaded"||Ol(ve)==="failed"?3:2,"stroke-dasharray":rn(ve),"stroke-dashoffset":"0","stroke-linecap":"round",transform:"rotate(-90 18 18)"},null,10,D3)])),Ol(ve)==="completed"||Ol(ve)==="uploaded"?(e.openBlock(),e.createElementBlock("div",T3,[e.createVNode(Ce,{class:"check-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.check_default))]),_:1})])):e.createCommentVNode("",!0),Ol(ve)==="failed"?(e.openBlock(),e.createElementBlock("div",B3,[e.createVNode(Ce,{class:"error-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.close_default))]),_:1})])):e.createCommentVNode("",!0)],2),e.createElementVNode("div",{class:"file-delete-btn",onClick:Da=>uu(Pa)},[e.createVNode(Ce,null,{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.close_default))]),_:1})],8,N3)]),e.createElementVNode("div",A3,e.toDisplayString(ve.name||"文件名123"),1)])}),128))]),Aa.value.length>0?(e.openBlock(),e.createElementBlock("div",z3,[e.createVNode(xe,{onClick:ia,class:"ocr-start-recognize-btn",disabled:il.value||Aa.value.length===0,size:"default"},{default:e.withCtx(()=>v[36]||(v[36]=[e.createTextVNode("开始识别 ")])),_:1,__:[36]},8,["disabled"])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),Ga.value===1?(e.openBlock(),e.createElementBlock("div",M3,[e.createVNode(Ge,{percentage:na.value,"stroke-width":8},null,8,["percentage"])])):e.createCommentVNode("",!0),Ga.value===2?(e.openBlock(),e.createElementBlock("div",I3,[e.createElementVNode("div",O3,[e.createVNode(He,{title:"请核对识别结果。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",L3,[e.createVNode(ba,{data:la.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(Qe,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(nl.value,ve=>(e.openBlock(),e.createBlock(Qe,{key:ve.prop,prop:ve.prop,"min-width":ve.minWidth||230,"class-name":ve.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",R3,[e.createElementVNode("span",null,e.toDisplayString(ve.label),1)])]),default:e.withCtx(({row:Pa,$index:ya})=>{var Da,Ea,N;return[ve.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:El(Pa[ve.prop]),fontWeight:500})},e.toDisplayString(ol(Pa[ve.prop])),5)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[Ra.value!==ya?(e.openBlock(),e.createElementBlock("span",$3,e.toDisplayString(Pa[ve.prop]),1)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(Fa(ve.prop)),{key:1,modelValue:Pa[ve.prop],"onUpdate:modelValue":G=>Pa[ve.prop]=G,size:"small",placeholder:"请输入"+ve.label,content:((Da=Je(ve.prop))==null?void 0:Da.contents)??((Ea=Je(ve.prop))==null?void 0:Ea.options)??[],optionUrl:(N=Je(ve.prop))==null?void 0:N.optionUrl,onChange:G=>Ja(ya,ve.prop,G),onFocus:G=>Va.value=ve.prop,onBlur:v[8]||(v[8]=G=>Va.value="")},null,40,["modelValue","onUpdate:modelValue","placeholder","content","optionUrl","onChange","onFocus"]))],64))]}),_:2},1032,["prop","min-width","class-name"]))),128)),e.createVNode(Qe,{label:"编辑",width:"80",fixed:"right"},{default:e.withCtx(({$index:ve})=>[Ra.value===ve?(e.openBlock(),e.createBlock(Ce,{key:0,class:"ocr-edit-icon editing",style:{"margin-left":"12px"},onClick:e.withModifiers(Pa=>bl(ve),["stop"])},{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.check_default))]),_:2},1032,["onClick"])):(e.openBlock(),e.createBlock(B,{key:1,name:"edit_101",class:"ocr-edit-icon",onClick:e.withModifiers(Pa=>bl(ve),["stop"])},null,8,["onClick"]))]),_:1})]),_:1},8,["data"])])])):e.createCommentVNode("",!0),Ga.value===3?(e.openBlock(),e.createElementBlock("div",V3,[e.createVNode(Ce,{size:"32",class:"ocr-success-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(Wa.check_default))]),_:1}),v[37]||(v[37]=e.createElementVNode("div",{class:"ocr-success-text"},"文件提交成功",-1))])):e.createCommentVNode("",!0)]),e.createVNode(za,{ref:"ocrUploadRef","file-list":Aa.value,"onUpdate:fileList":v[9]||(v[9]=ve=>Aa.value=ve),multiple:"",action:"","auto-upload":!1,limit:20,accept:"image/*,application/pdf","on-change":je,"show-file-list":!1,class:"ocr-upload-input",style:{display:"none"}},null,8,["file-list"])]),footer:e.withCtx(()=>[Ga.value!==3?(e.openBlock(),e.createElementBlock("div",P3,[e.createVNode(xe,{onClick:kn,class:"ocr-start-recognize-btn",disabled:Ga.value===1||il.value},{default:e.withCtx(()=>v[39]||(v[39]=[e.createTextVNode(" 上一步 ")])),_:1,__:[39]},8,["disabled"]),e.createVNode(xe,{onClick:Tn,class:"ocr-start-recognize-btn",disabled:il.value},{default:e.withCtx(()=>v[40]||(v[40]=[e.createTextVNode(" 下一步 ")])),_:1,__:[40]},8,["disabled"])])):e.createCommentVNode("",!0)]),_:1},8,["visible"]),e.createVNode(l0,{visible:gi.value,onConfirm:o,onCancel:v[10]||(v[10]=ve=>gi.value=!1)},null,8,["visible"]),e.createVNode(Sd,{visible:rl.value,"onUpdate:visible":v[11]||(v[11]=ve=>rl.value=ve),versions:qe.value},null,8,["visible","versions"]),e.createVNode(ud,{visible:Bl.value,"onUpdate:visible":v[12]||(v[12]=ve=>Bl.value=ve),images:We.value,"default-image-name":Ma.value,"field-meta":Ra.value!==null?((ll=la.value[Ra.value])==null?void 0:ll.__ocrFieldMeta)||{}:{},"focused-field-name":Va.value,onClose:v[13]||(v[13]=ve=>Bl.value=!1),class:"ocr-img-preview-dialog"},null,8,["visible","images","default-image-name","field-meta","focused-field-name"]),e.createVNode(Rd,{visible:Sl.value,"onUpdate:visible":v[14]||(v[14]=ve=>Sl.value=ve),candidates:pr.value,"name-prop":lr.value,"mfr-prop":br.value,columns:z.value,onSubmit:Ul,onPreviewFile:ii},null,8,["visible","candidates","name-prop","mfr-prop","columns"]),e.createVNode(Ud,{visible:Sa.value,"onUpdate:visible":v[15]||(v[15]=ve=>Sa.value=ve),ocrPreviewData:la.value,"onUpdate:ocrPreviewData":v[16]||(v[16]=ve=>la.value=ve),ocrSelectedFields:Me.value,"onUpdate:ocrSelectedFields":v[17]||(v[17]=ve=>Me.value=ve),ocrPreviewColumns:nl.value,onConfirm:el,onFieldChange:v[18]||(v[18]=({rowIndex:ve,prop:Pa,value:ya})=>Ja(ve,Pa,ya))},null,8,["visible","ocrPreviewData","ocrSelectedFields","ocrPreviewColumns"]),e.createVNode(Ar.ssDialog,{title:f.title,visible:f.show,width:f.width,onBeforeDestroy:Z},{default:e.withCtx(()=>[e.createElementVNode("div",F3,[e.createVNode(cl.ssForm,{rowContents:f==null?void 0:f.contents,formRules:f==null?void 0:f.formRules,showOperator:!1,buttonValue:f.buttonValue,isEdit:fa.value,isStartJustify:!1,onOnButtonClick:ke},null,8,["rowContents","formRules","buttonValue","isEdit"])])]),_:1},8,["title","visible","width"]),e.createVNode(Ar.ssDialog,{title:"",visible:y.show,width:y.width,alignCenter:!0,onBeforeDestroy:S},{header:e.withCtx(()=>[e.createElementVNode("div",null,[e.createElementVNode("div",j3,e.toDisplayString(y.title),1),e.createVNode($a,{size:"small",type:"danger",style:{width:"100%"}},{default:e.withCtx(()=>v[41]||(v[41]=[e.createTextVNode(" (选择【覆盖】,可能会影响到原数据的引用关系;选择【跳过】将会放弃重复数据的导入。请谨慎操作!) ")])),_:1,__:[41]})])]),footer:e.withCtx(()=>[e.createElementVNode("div",H3,[e.createVNode($a,{size:"small",style:{width:"100%","text-align":"left"},type:"info"},{default:e.withCtx(()=>[e.createTextVNode("引用模块:"+e.toDisplayString(Fn.value||"暂无"),1)]),_:1}),e.createElementVNode("div",U3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y==null?void 0:y.buttonValue,ve=>(e.openBlock(),e.createBlock(xe,{key:ve==null?void 0:ve.label,style:e.normalizeStyle({background:ve==null?void 0:ve.background,color:ve==null?void 0:ve.color}),onClick:Pa=>K(ve==null?void 0:ve.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(ve==null?void 0:ve.label),1)]),_:2},1032,["style","onClick"]))),128))])])]),default:e.withCtx(()=>[e.createVNode(Df,{columns:y==null?void 0:y.columns,tableData:y==null?void 0:y.tableData},{content:e.withCtx(({row:ve,item:Pa,slotData:ya,scope:Da,column:Ea,columnProp:N,$index:G})=>[e.createTextVNode(e.toDisplayString((ve==null?void 0:ve[Ea==null?void 0:Ea.prop])||(ve==null?void 0:ve[Ea==null?void 0:Ea.label])||(ve==null?void 0:ve[Ea==null?void 0:Ea.property])||(ya==null?void 0:ya[Ea==null?void 0:Ea.property])),1)]),_:1},8,["columns","tableData"])]),_:1},8,["visible","width"])])}}},Ic=ar._export_sfc(W3,[["__scopeId","data-v-55d5ec5e"]]),K3={key:1,class:"static-form-body"},G3=["onClick"],Y3={key:1},J3=e.defineComponent({__name:"index",props:{itemData:{default:()=>[]},fields:{default:()=>[]},compName:{default:""},title:{default:""},disabled:{type:Boolean,default:!1},textSize:{default:void 0},textColor:{default:void 0},backGround:{default:void 0},backGroundImage:{default:void 0},backgroundUrl:{default:void 0}},emits:["update:backGroundImage"],setup(a,{emit:l}){const n=a,r=l,i=w=>{switch(w){case"占用":return"warning";case"注销":return"info";case"损坏":return"danger";case"可用":return"success";default:return""}},s=e.computed(()=>{var P;const w=(P=n.itemData)==null?void 0:P.find(V=>(V==null?void 0:V.key)==="formContent"),g=(w==null?void 0:w.contents)||[];return(n.fields&&n.fields.length>0?n.fields:g).filter(V=>(V==null?void 0:V.label)||(V==null?void 0:V.isHideInForm)).map(V=>{let ee=V==null?void 0:V.value;Array.isArray(ee)&&(ee=ee.map(z=>z==null?"":typeof z=="object"?z.label??z.value??z.name??JSON.stringify(z):String(z)).filter(Boolean).join(",")),ee!=null&&typeof ee=="object"&&(ee=ee.label??ee.value??ee.name??JSON.stringify(ee));const J=V.isHideInForm?"":V.label??"",me=ee==null||ee===""?"-":String(ee),_e=J==="使用状态";return{label:J,value:me,isStatus:_e,tagType:_e?i(me):"",width:V.width??1,field:V}})}),h=e.ref(null),c=e.ref(null),d=e.computed(()=>{const w=Number(n==null?void 0:n.textSize),g=oe.rgbaToColor(n==null?void 0:n.textColor),E={},P={},V={},ee={};return!Number.isNaN(w)&&w&&(E.fontSize=`${w}px`,P.fontSize=`${w+1}px`,V.fontSize=`${w}px`,ee.fontSize=`${w}px`),g&&(P.color=g,V.color=g,ee.color=g),{item:E,label:P,value:V,empty:ee}}),m=e.ref(""),b=e.ref(""),u=e.ref(!1),C=async w=>{if(w){b.value&&(URL.revokeObjectURL(b.value),b.value="");try{const g=await A.platformDownloadFile({url:w}),E=new Blob([g==null?void 0:g.data],{type:(g==null?void 0:g.headers["content-type"])||"image/*"});b.value=URL.createObjectURL(E)}catch{b.value=""}}};e.watch(()=>n==null?void 0:n.backGroundImage,w=>{w&&(m.value=w)},{immediate:!0}),e.watch(m,w=>{C(w)},{immediate:!0});const M=()=>{var w;(w=c.value)==null||w.click()},k=async w=>{var P,V,ee;const g=w.target,E=(P=g==null?void 0:g.files)==null?void 0:P[0];if(!E){g.value="";return}u.value=!0;try{const J=new FormData;J.append("file",E);const me=await A.platformUploadFile(J),_e=(ee=(V=me==null?void 0:me.data)==null?void 0:V.result)==null?void 0:ee.url;_e?(m.value=_e,r("update:backGroundImage",_e),C(_e),Wa.ElMessage.success("背景图片上传成功")):Wa.ElMessage.error("背景图片上传失败")}catch{Wa.ElMessage.error("背景图片上传失败")}finally{u.value=!1,g.value=""}},W=e.computed(()=>{var w;return b.value||(n==null?void 0:n.backgroundUrl)!==""?{backgroundImage:`url("${(w=n==null?void 0:n.backgroundUrl)==null?void 0:w.replace(/\\/g,"/")}")`,backgroundSize:"contain",backgroundPosition:"center",backgroundRepeat:"no-repeat"}:{}}),O=w=>cl.getComponent(w),j=w=>{if(!w)return;const g=w.querySelector("input, textarea, .el-input__inner");g&&typeof g.focus=="function"&&g.focus()},L=(w,g,E)=>{n.disabled||(h.value=g,e.nextTick(()=>{j(E.currentTarget)}))},_=()=>{h.value=null},x=w=>{const g=w!=null&&w.width&&w.width>0?w.width:1,P=`calc((100% - ${(g-1)*48}px) / ${g})`;return{flex:`0 0 ${P}`,maxWidth:P,minWidth:"0",boxSizing:"border-box"}};return(w,g)=>{const E=e.resolveComponent("el-tag");return e.openBlock(),e.createElementBlock("div",{class:"static-form-card",style:e.normalizeStyle(W.value),onClick:g[2]||(g[2]=P=>(n==null?void 0:n.backGround)==="Yes"&&M())},[(n==null?void 0:n.backGround)==="Yes"?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-backGround-upload",onClick:g[0]||(g[0]=e.withModifiers(P=>M(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:c,type:"file",accept:"image/*",style:{display:"none"},onChange:k},null,544),g[3]||(g[3]=e.createElementVNode("img",{src:cl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),s.value.length?(e.openBlock(),e.createElementBlock("div",K3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(P,V)=>{var ee,J,me,_e,z,ne,Y,te,ye;return e.openBlock(),e.createElementBlock("div",{key:V,class:"static-form-item",style:e.normalizeStyle({...x(P),...d.value.item}),onClick:g[1]||(g[1]=e.withModifiers(()=>{},["stop"]))},[P.label&&!((ee=P==null?void 0:P.field)!=null&&ee.isHideInForm)?(e.openBlock(),e.createElementBlock("div",{key:0,class:"static-form-label",style:e.normalizeStyle(d.value.label)},e.toDisplayString(P.label)+": ",5)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"static-form-value",style:e.normalizeStyle(d.value.value),onClick:$e=>{var de;return(de=P.field)!=null&&de.isNoClick?null:L(P,V,$e)}},[h.value===V&&P.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(O(((J=P.field)==null?void 0:J.type)??"Input")),{key:0,modelValue:P.field.value,"onUpdate:modelValue":$e=>P.field.value=$e,isEdit:!0,disabled:(me=P.field)==null?void 0:me.disabled,content:((_e=P.field)==null?void 0:_e.contents)??[],optionUrl:P.field,originalValue:(z=P.field)==null?void 0:z.value,config:(ne=P.field)==null?void 0:ne.config,configModel:((Y=P.field)==null?void 0:Y.prop)??((te=P.field)==null?void 0:te.name),selectedTagList:((ye=P.field)==null?void 0:ye.selectValue)??[],onBlur:_,onBlurChange:_},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[P.isStatus?(e.openBlock(),e.createBlock(E,{key:0,type:P.tagType,size:"Default",effect:"plain"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(P.value??"-"),1)]),_:2},1032,["type"])):(e.openBlock(),e.createElementBlock("span",Y3,e.toDisplayString(P.value??"-"),1))],64))],12,G3)],4)}),128))])):(e.openBlock(),e.createElementBlock("div",{key:2,class:"static-form-empty",style:e.normalizeStyle(d.value.empty)}," 暂无数据 ",4))],4)}}}),Oc=ar._export_sfc(J3,[["__scopeId","data-v-5937a104"]]),X3={class:"form-content"},Z3={title:"选择标签"},Q3={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},eh={class:"col-operate-wrap"},ah={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},lh={__name:"index",props:{formRules:Object,itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,compName:{type:String,default:""},allMapContents:{type:Object},config:{type:Object,default:()=>{}}},emits:["change","contentChange","routeUrl","clickTrigger"],setup(a,{emit:l}){const n=()=>{c.value=!1,d.value=!1,m.value=[]},r=a;e.computed(()=>{var Xe;const ae=(Xe=Ca.value)==null?void 0:Xe.split("/");return(ae==null?void 0:ae.some(Ze=>(Ze==null?void 0:Ze.includes("updateLoading"))||(Ze==null?void 0:Ze.includes("loading"))))?!1:$e.value==="view"});const i=l,s=e.ref(""),h=e.ref([]),c=e.ref(!1),d=e.ref(!1),m=e.ref([]),{getFileExtension:b}=Bo.useThreeSystem(),u=e.ref(),C=e.ref(!1),M=e.ref(!1),k=A.useUnit(A.pinia),{chooseTitle:W}=A.storeToRefs(k),O=e.ref([]),j=e.ref(),L=e.ref(!1),_=e.ref([]),x=vc(A.pinia),w=zt(A.pinia),g=e.ref(!1),E=e.ref(),P=e.ref(),V=e.ref(),ee=e.ref(),J=e.ref(),me=A.useLoginState(A.pinia),{loginUserInfo:_e}=A.storeToRefs(me),z=e.ref(),ne=e.ref(!0),Y=A.useModelComp(A.pinia),{tableViewContents:te,itemData:ye,isEdit:$e,routeToChildPath:de,lockingPage:T,homepageBackgroundTableId:ie,refreshCurrentPageInform:U}=A.storeToRefs(Y),ge=e.ref(null),ze=e.ref(!1),Le=e.ref(!1),ra=A.useMenuState(),{activeMenuPath:Ca}=A.storeToRefs(ra),Q=oe.useOriginalState(A.pinia),{originalPath:ca}=A.storeToRefs(Q),{compType:ue,hasEditable:pa}=ec.useRole(),Se=()=>!pa(r.config,{type:ue.FORM});e.computed(()=>Ca.value==="设备管理/试验设备"&&r.compName==="设备概要");const ce=async()=>{var Xe,Ze,Ha;const ae=ie==null?void 0:ie.value,se=(Xe=_e==null?void 0:_e.value)==null?void 0:Xe.plat_id;if(!(!ae||!se))try{const _a=await A.getAllTables({platId:parseInt(se),tableNames:[`content_${ae}`,`struct_${ae}`],user_unique_id:"0"}),Qa=((Ha=(Ze=_a==null?void 0:_a.data)==null?void 0:Ze.result)==null?void 0:Ha[0])??[],Pe=String((r==null?void 0:r.index)??""),Re=Qa==null?void 0:Qa.find(Ue=>String(Ue==null?void 0:Ue.relatedForm_id)===Pe);Re!=null&&Re.backgroundImg_url&&(ee.value=Re.backgroundImg_url)}catch(_a){console.error("获取首页背景图片表数据失败:",_a)}},De=e.ref([]),Ke=e.ref([{label:"编辑",value:"operable",checked:!1},{label:"禁用",value:"disabled",checked:!1}]),ua=async ae=>{Le.value=ae,await ha("disabled",null,ae,!0)},Za=async ae=>{await ha("operable",null,ae,!0)};e.watch(()=>Ca.value,async()=>{h.value=[],m.value=[]},{deep:!0,immediate:!0});const $=()=>{e.nextTick(()=>{fe()})},H=ae=>{var se;h.value=(se=h.value)==null?void 0:se.map(Xe=>({...Xe,isFormColHidden:!(ae!=null&&ae.includes(Xe.label))}))};e.onUnmounted(()=>{ge.value=null});const X=ae=>{i("clickTrigger",ae)},he=async ae=>{var se,Xe,Ze,Ha,_a,Qa;if(ae===""){let Pe="";(se=h.value)==null||se.forEach(Ie=>{Ie!=null&&Ie.isMain&&(Pe=Ie==null?void 0:Ie.value)});let Re=await oe.getItemData(de.value,sessionStorage.getItem("systemKey"),"");Pe=((Qa=(_a=(Ha=(Ze=(Xe=Re==null?void 0:Re[0])==null?void 0:Xe.compData)==null?void 0:Ze.find(Ie=>(Ie==null?void 0:Ie.key)==="mainRouters"))==null?void 0:Ha.contents)==null?void 0:_a[0])==null?void 0:Qa.routerContent)+ca.value+Pe;let Ne=await oe.getItemData(Pe,sessionStorage.getItem("systemKey"),"");L.value=!0,_.value=Ne==null?void 0:Ne.filter(Ie=>(Ie==null?void 0:Ie.comp)!=="methodButton"),i("routeUrl",_.value)}},fe=()=>{var se;const ae=(se=ge.value)==null?void 0:se.$el;ae&&Al.Sortable.create(ae,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:Xe=>{const{oldIndex:Ze,newIndex:Ha}=Xe;if(Ze===Ha)return;const _a=h.value.splice(Ze,1)[0];h.value.splice(Ha,0,_a)}})},ha=async(ae,se,Xe,Ze=!1)=>{try{Y.setRefreshCurStructure(!1)}catch{Wa.ElMessage.error("编辑处理失败")}},ta=async(ae,se)=>{await ha()},Fe=async(ae,se)=>{ae&&await ha()},xa=async(ae,se,Xe)=>{await ha(se,Xe,ae,!1)},Ae=(ae,se)=>{z.value===se?ne.value=!1:ne.value=!0,z.value=se==null?void 0:se.changeProp},va=async ae=>{var Qa;ee.value=ae;const se=r.itemData,Xe=se==null?void 0:se.find(Pe=>(Pe==null?void 0:Pe.key)==="backGroundImage");Xe?Xe.contents=ae:se==null||se.push({key:"backGroundImage",contents:ae}),i("change",{key:"backGroundImage",contents:ae});const Ze=ie==null?void 0:ie.value,Ha=r==null?void 0:r.index,_a=(Qa=_e==null?void 0:_e.value)==null?void 0:Qa.plat_id;if(!(!Ze||!_a||!Ha||!ae))try{await A.pageBatchAddApi({platId:parseInt(_a),changeContents:[{tableName:`content_${Ze}`,tableContents:[{backgroundImg_url:ae,relatedForm_id:String(Ha)}]}],user_unique_id:"0"})}catch(Pe){console.error("保存背景图片记录失败:",Pe),Wa.ElMessage.error("背景图片记录保存失败")}},La=async ae=>{var Xe,Ze,Ha,_a,Qa,Pe,Re,Ue,Ne,Ie,ul,_l,Tl,jl,Cl;let se=[];if((Xe=ae==null?void 0:ae.toString())!=null&&Xe.includes(".urdf")){if(ae.includes(",")){Wa.ElMessage.error("当前版本仅允许单个urdf预览!");return}m.value=[{url:ae,extension:b(ae)}],d.value=!0,c.value=!0;return}if((Ze=ae==null?void 0:ae.toString())!=null&&Ze.includes(".stl")||(Ha=ae==null?void 0:ae.toString())!=null&&Ha.includes(".STL")||(_a=ae==null?void 0:ae.toString())!=null&&_a.includes(".obj")||(Qa=ae==null?void 0:ae.toString())!=null&&Qa.includes(".mtl")){const aa=((Pe=ae==null?void 0:ae.toString())==null?void 0:Pe.split(",")).map(Ka=>({url:Ka,extension:b(Ka)}));m.value=aa,d.value=!1,c.value=!0;return}if((Re=ae==null?void 0:ae.toString())!=null&&Re.includes(".stl")||(Ue=ae==null?void 0:ae.toString())!=null&&Ue.includes(".STL")||(Ne=ae==null?void 0:ae.toString())!=null&&Ne.includes(".obj")||(Ie=ae==null?void 0:ae.toString())!=null&&Ie.includes(".mtl")){let Yl,aa=[],Ka={};if(Array.isArray(ae)?Yl=ae:Yl=ae==null?void 0:ae.split(","),Yl==null||Yl.forEach(ma=>{ma.includes(".mtl")?aa.push(ma):Ka.blob=Ka.blob?Ka.blob+","+ma:ma}),(aa==null?void 0:aa.length)>0&&(Ka.mtlBlobs=aa),(_l=(ul=Object.values(Ka))==null?void 0:ul[0])!=null&&_l.includes("http:"))se.push(Ka);else{const ma=new Blob([Ka.blob],{type:"application/octet-stream;charset=UTF-8"});let il=URL.createObjectURL(ma),Aa="";(Tl=ae==null?void 0:ae.split("/"))==null||Tl.forEach((sl,rl)=>{var qe;rl===((qe=ae==null?void 0:ae.split("/"))==null?void 0:qe.length)-1&&(Aa=sl)}),(jl=Ka.blob)!=null&&jl.includes(".stl")&&(Aa=(Aa==null?void 0:Aa.replaceAll(">",""))+".urdf"),j.value=[{name:Aa,blobUrl:il}],M.value=!0}}else{const Yl=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),aa=await Wa.axios.get(ae,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{Yl.close()}),Ka=new Blob([aa.data],{type:"application/octet-stream;charset=UTF-8"});let ma=URL.createObjectURL(Ka),il="";(Cl=ae==null?void 0:ae.split("/"))==null||Cl.forEach((Aa,sl)=>{var rl;sl===((rl=ae==null?void 0:ae.split("/"))==null?void 0:rl.length)-1&&(il=Aa)}),j.value=[{name:il,blobUrl:ma}],M.value=!0}(se==null?void 0:se.length)>0&&w.setBlobUrls(se)},Ia=()=>{M.value=!1},fa=ae=>{var _a,Qa,Pe,Re;const se=(Qa=(_a=cl.safeClone(r.itemData))==null?void 0:_a.find(Ue=>(Ue==null?void 0:Ue.key)==="formContent"))==null?void 0:Qa.contents,Xe=cl.safeClone(ae.content);let Ze={};Xe&&((Pe=Object.values(Xe))==null?void 0:Pe.length)>0&&((Re=Object.values(Xe))==null||Re.forEach((Ue,Ne)=>{Ze[se[Ne].key]=Ue}));const Ha={content:Ze,index:r==null?void 0:r.index,buttonName:ae==null?void 0:ae.buttonName};i("change",Ha)};e.computed(()=>"http://222.92.178.198:62001");const Ba=async ae=>{var ul,_l,Tl,jl,Cl,Yl,aa,Ka,ma,il,Aa,sl,rl,qe,Ga,hl;if(!ae)return;(_l=(ul=r==null?void 0:r.itemData)==null?void 0:ul.find(pe=>(pe==null?void 0:pe.key)==="parentFormPath"))==null||_l.contents;let se=te.value;(se==null?void 0:se.length)>0&&(se=se==null?void 0:se.map(pe=>{var Sa,la,nl,Je;let na=(Sa=pe==null?void 0:pe.key)==null?void 0:Sa.split("/");return(r==null?void 0:r.compName)===(na==null?void 0:na[0])&&(la=h.value)!=null&&la.find(Fa=>(Fa==null?void 0:Fa.prop)===(na==null?void 0:na[1]))&&(pe.value=(Je=(nl=h.value)==null?void 0:nl.find(Fa=>(Fa==null?void 0:Fa.prop)===(na==null?void 0:na[1])))==null?void 0:Je.value),pe}),Y.setTableViewContents(se));const Xe=cl.safeClone(r.itemData);let Ze=Xe==null?void 0:Xe.map(pe=>{var na;return(pe==null?void 0:pe.key)==="formContent"&&((na=pe.contents)==null||na.map((Sa,la)=>{var nl,Je,Fa,wa,Oa,Me,Ra,Va,Bl,We,Ma,Sl,pr,ga,Zl,Sr,Cr,Oe,lr,br,Dr;return Sa.type=(Je=(nl=h.value)==null?void 0:nl.find(zl=>(zl==null?void 0:zl.prop)===(Sa==null?void 0:Sa.prop)))==null?void 0:Je.type,Sa.options=Sa!=null&&Sa.options?Sa.options:((Oa=(wa=(Fa=Sa==null?void 0:Sa.key)==null?void 0:Fa.split("$"))==null?void 0:wa[1])==null?void 0:Oa.length)>0?(Bl=(Va=Pu((Ra=(Me=Sa==null?void 0:Sa.key)==null?void 0:Me.split("$"))==null?void 0:Ra[1]))==null?void 0:Va.split(","))==null?void 0:Bl.map(zl=>({label:zl,value:zl})):[],(We=Sa==null?void 0:Sa.key)!=null&&We.includes("$")&&(Sa.key=(Sl=(Ma=Sa==null?void 0:Sa.key)==null?void 0:Ma.split("$"))==null?void 0:Sl[0]),Sa.signature=(ga=(pr=h.value)==null?void 0:pr.find(zl=>(zl==null?void 0:zl.prop)===(Sa==null?void 0:Sa.prop)))==null?void 0:ga.signature,Sa.isLoginUser=(Sr=(Zl=h.value)==null?void 0:Zl.find(zl=>(zl==null?void 0:zl.prop)===(Sa==null?void 0:Sa.prop)))==null?void 0:Sr.isLoginUser,Sa.value=(Cr=Object.values(ae))==null?void 0:Cr[la],Sa.isFormColHidden=(lr=(Oe=h.value)==null?void 0:Oe.find(zl=>(zl==null?void 0:zl.prop)===(Sa==null?void 0:Sa.prop)))==null?void 0:lr.isFormColHidden,Sa.isHideInForm=(Dr=(br=h.value)==null?void 0:br.find(zl=>(zl==null?void 0:zl.prop)===(Sa==null?void 0:Sa.prop)))==null?void 0:Dr.isHideInForm,Sa})),pe}),Ha=h.value,_a=(jl=(Tl=cl.safeClone(Ze))==null?void 0:Tl.find(pe=>(pe==null?void 0:pe.key)==="formContent"))==null?void 0:jl.contents;if(Ha=Ha==null?void 0:Ha.map(pe=>{var na,Sa;return(pe==null?void 0:pe.type)==="Select"&&((na=pe==null?void 0:pe.allSelectionContents)==null?void 0:na.length)>0&&(pe.contactValue=ae),pe.value=(Sa=_a==null?void 0:_a.find((la,nl)=>((la==null?void 0:la.id)??nl)===(pe==null?void 0:pe.id)))==null?void 0:Sa.value,pe}),!ne.value){i("contentChange",{contents:Ze,index:r.index});return}let Qa="",Pe=(aa=(Yl=(Cl=cl.safeClone(Ze))==null?void 0:Cl.find(pe=>(pe==null?void 0:pe.key)==="formContent"))==null?void 0:Yl.contents)==null?void 0:aa.find((pe,na)=>{var Sa,la,nl;return(pe==null?void 0:pe.label)===z.value||na.toString()===((nl=(la=(Sa=z.value)==null?void 0:Sa.split("t"))==null?void 0:la[1])==null?void 0:nl.toString())}),Re=(Ka=Pe==null?void 0:Pe.optionUrl)==null?void 0:Ka.menuSelect,Ue=!0;if((Aa=(il=(ma=cl.safeClone(Ze))==null?void 0:ma.find(pe=>(pe==null?void 0:pe.key)==="formContent"))==null?void 0:il.contents)==null||Aa.forEach(pe=>{var na,Sa,la,nl,Je,Fa;Ue&&((la=(Sa=(na=pe==null?void 0:pe.optionUrl)==null?void 0:na.groupSelect)==null?void 0:Sa[1])!=null&&la.includes("["))&&(Qa=(Je=(nl=pe==null?void 0:pe.optionUrl)==null?void 0:nl.groupSelect)==null?void 0:Je[1],JSON.stringify(Re)===JSON.stringify((Fa=pe==null?void 0:pe.optionUrl)==null?void 0:Fa.menuSelect)&&(Ue=!1))}),(sl=Pe==null?void 0:Pe.optionUrl)!=null&&sl.menuSelect&&ne.value){let pe=await St(Pe),na,Sa=(rl=Pe==null?void 0:Pe.optionUrl)==null?void 0:rl.menuSelect;if(pe==null||pe.forEach(la=>{var nl,Je,Fa,wa,Oa,Me,Ra,Va,Bl,We;Qa===((Je=(nl=Pe==null?void 0:Pe.optionUrl)==null?void 0:nl.groupSelect)==null?void 0:Je[1])&&((Oa=(wa=(Fa=Pe==null?void 0:Pe.optionUrl)==null?void 0:Fa.groupSelect)==null?void 0:wa[1])!=null&&Oa.includes("["))&&((We=cl.safeClone(la))==null?void 0:We[(Bl=(Va=(Ra=(Me=Pe==null?void 0:Pe.optionUrl)==null?void 0:Me.groupSelect)==null?void 0:Ra[1])==null?void 0:Va.replaceAll("[",""))==null?void 0:Bl.replaceAll("]","")])===(Pe==null?void 0:Pe.value)&&(na=la)}),na){let la=cl.safeClone(Ha);la=la==null?void 0:la.map(Je=>{var Fa,wa,Oa,Me,Ra,Va,Bl,We,Ma,Sl,pr;return(na!=null&&na[Je==null?void 0:Je.label]||na!=null&&na[(Me=(Oa=(wa=(Fa=Je==null?void 0:Je.optionUrl)==null?void 0:Fa.groupSelect)==null?void 0:wa[1])==null?void 0:Oa.replaceAll("[",""))==null?void 0:Me.replaceAll("]","")])&&((Bl=(Va=(Ra=Je==null?void 0:Je.optionUrl)==null?void 0:Ra.groupSelect)==null?void 0:Va[1])!=null&&Bl.includes("["))&&Sa!=null&&Sa.every(ga=>{var Zl,Sr;return(Sr=(Zl=Je==null?void 0:Je.optionUrl)==null?void 0:Zl.menuSelect)==null?void 0:Sr.includes(ga)})&&(Je.value=(na==null?void 0:na[Je==null?void 0:Je.label])||(na==null?void 0:na[(pr=(Sl=(Ma=(We=Je==null?void 0:Je.optionUrl)==null?void 0:We.groupSelect)==null?void 0:Ma[1])==null?void 0:Sl.replaceAll("[",""))==null?void 0:pr.replaceAll("]","")]),Array.isArray(Je.value)&&Je.value.every(ga=>(ga==null?void 0:ga.url)&&(ga==null?void 0:ga.name))&&(Je.type="Upload")),Je}),la=la==null?void 0:la.map(Je=>{var Fa,wa,Oa;return(Fa=Je==null?void 0:Je.optionUrl)!=null&&Fa.oldMenuSelect&&(Je.optionUrl.menuSelect=(Oa=(wa=cl.safeClone(Je))==null?void 0:wa.optionUrl)==null?void 0:Oa.oldMenuSelect),Je}),h.value=cl.safeClone(la);let nl=cl.safeClone(la);nl=nl==null?void 0:nl.map(Je=>{var Fa,wa,Oa,Me,Ra,Va;return(wa=(Fa=Je==null?void 0:Je.optionUrl)==null?void 0:Fa.menuSelect)!=null&&wa.some(Bl=>Bl==null?void 0:Bl.includes("["))&&(Je.optionUrl.oldMenuSelect=(Me=(Oa=cl.safeClone(Je))==null?void 0:Oa.optionUrl)==null?void 0:Me.menuSelect,Je.optionUrl.menuSelect=(Va=(Ra=Je==null?void 0:Je.optionUrl)==null?void 0:Ra.menuSelect)==null?void 0:Va.map(Bl=>{var We,Ma,Sl,pr;if(Bl!=null&&Bl.includes("[")){let ga=(Ma=(We=Bl==null?void 0:Bl.replaceAll("[","").replaceAll("]",""))==null?void 0:We.split(":"))==null?void 0:Ma[1];Bl=(pr=(Sl=cl.safeClone(la))==null?void 0:Sl.find(Zl=>(Zl==null?void 0:Zl.label)===ga))==null?void 0:pr.value}return Bl})),Je}),h.value=nl}else h.value=Ha;Ze=Ze==null?void 0:Ze.map(la=>{var nl;return(la==null?void 0:la.key)==="formContent"&&(la.contents=(nl=la.contents)==null?void 0:nl.map(Je=>{var Fa,wa,Oa,Me;return Je.value=((wa=(Fa=h.value)==null?void 0:Fa.find(Ra=>(Ra==null?void 0:Ra.label)===(Je==null?void 0:Je.key)))==null?void 0:wa.value)??(Je==null?void 0:Je.value),Je.type=((Me=(Oa=h.value)==null?void 0:Oa.find(Ra=>(Ra==null?void 0:Ra.prop)===(Je==null?void 0:Je.key)))==null?void 0:Me.type)??(Je==null?void 0:Je.type),Je})),la})}ne.value=!1,i("contentChange",{contents:Ze,index:r.index});let Ne=[],Ie=[];if((Ga=cl.safeClone((qe=Ze==null?void 0:Ze.find(pe=>(pe==null?void 0:pe.key)==="formContent"))==null?void 0:qe.contents))==null||Ga.forEach(pe=>{var na;Array.isArray(pe==null?void 0:pe.value)&&((na=pe==null?void 0:pe.value)!=null&&na.find(Sa=>{var la;return(la=Sa==null?void 0:Sa.url)==null?void 0:la.includes(".obj")}))&&(Ie=pe==null?void 0:pe.value)}),(Ie==null?void 0:Ie.length)>0){const pe=(hl=cl.safeClone(Ie))==null?void 0:hl.filter(na=>{var Sa;return(Sa=na==null?void 0:na.url)==null?void 0:Sa.includes(".obj")});pe==null||pe.forEach(na=>{var la,nl,Je,Fa;const Sa=(la=Ie==null?void 0:Ie.filter(wa=>{var Oa;return(wa==null?void 0:wa.name)===(na==null?void 0:na.name)&&((Oa=wa==null?void 0:wa.url)==null?void 0:Oa.includes(".mtl"))}))==null?void 0:la.map(wa=>wa==null?void 0:wa.url);Ne.push({objUrl:na==null?void 0:na.url,mtlUrls:((nl=Ie==null?void 0:Ie.filter(wa=>{var Oa;return(wa==null?void 0:wa.name)===(na==null?void 0:na.name)&&((Oa=wa==null?void 0:wa.url)==null?void 0:Oa.includes(".mtl"))}))==null?void 0:nl.length)===1?(Fa=(Je=Ie==null?void 0:Ie.filter(wa=>{var Oa;return(wa==null?void 0:wa.name)===(na==null?void 0:na.name)&&((Oa=wa==null?void 0:wa.url)==null?void 0:Oa.includes(".mtl"))}))==null?void 0:Je[0])==null?void 0:Fa.url:Sa})}),w.setObjUrl(Ne)}},Te=(ae,se,Xe)=>{let Ze="";const Ha=se==null?void 0:se.map(_a=>{var Qa;return(Qa=_a==null?void 0:_a.value)==null?void 0:Qa.pageData});return Ha==null||Ha.forEach(_a=>{var Qa;(_a==null?void 0:_a.name)===(ae==null?void 0:ae[0])&&((Qa=_a==null?void 0:_a.compData)==null||Qa.forEach(Pe=>{var Re;(Pe==null?void 0:Pe.key)==="formContent"&&((Re=Pe==null?void 0:Pe.contents)==null||Re.forEach(Ue=>{var Ne;(Ue==null?void 0:Ue.prop)===(ae==null?void 0:ae[1])&&(Ze=(Ue==null?void 0:Ue.value)===""?oe.judgeContents((Ne=cl.safeClone(Ue))==null?void 0:Ne.optionUrl,Xe):Ue==null?void 0:Ue.value)}))}))}),Ze},be=(ae,se,Xe,Ze)=>{var Pe,Re;let Ha="",_a="";(Pe=cl.safeClone(se))==null||Pe.forEach((Ue,Ne)=>{Ue!=null&&Ue.includes("[")?_a=_a+ca.value+ae[Ne]:_a=_a===""?_a+Ue:_a+"/"+Ue});let Qa=(Re=Ze[_a])==null?void 0:Re.map(Ue=>{var Ne;return(Ne=Ue==null?void 0:Ue.value)==null?void 0:Ne.pageData});return Qa==null||Qa.forEach(Ue=>{var Ne;(Ue==null?void 0:Ue.name)===(Xe==null?void 0:Xe[0])&&((Ne=Ue==null?void 0:Ue.compData)==null||Ne.forEach(Ie=>{var ul;(Ie==null?void 0:Ie.key)==="formContent"&&((ul=Ie==null?void 0:Ie.contents)==null||ul.forEach(_l=>{(_l==null?void 0:_l.prop)===(Xe==null?void 0:Xe[1])&&(Ha=_l==null?void 0:_l.value)}))}))}),Ha};e.watch(()=>ie==null?void 0:ie.value,async()=>{await ce()},{immediate:!0});const Be=async ae=>await Up(ae,"Auto");return e.watch(()=>U.value,async()=>{var ae;(ae=h.value)!=null&&ae.some(se=>(se==null?void 0:se.functionName)&&(se==null?void 0:se.functionName)!=="")&&(h.value=await Be(h.value))},{immediate:!0,deep:!0}),e.watch(()=>r.itemData,async()=>{var _l,Tl,jl,Cl,Yl,aa,Ka,ma,il,Aa,sl,rl,qe,Ga,hl,pe,na,Sa,la,nl,Je,Fa,wa,Oa,Me,Ra,Va,Bl;const ae=(_l=r.itemData)==null?void 0:_l.find(We=>(We==null?void 0:We.key)==="formContent");let se=(Tl=r.itemData)==null?void 0:Tl.find(We=>(We==null?void 0:We.key)==="backGround");se&&((jl=se==null?void 0:se.contents)==null?void 0:jl.length)>0&&(s.value=((Yl=(Cl=se==null?void 0:se.contents)==null?void 0:Cl[0])==null?void 0:Yl.url)??"");const Xe=(aa=cl.safeClone(r.itemData))==null?void 0:aa.find(We=>(We==null?void 0:We.key)==="formButton"),Ze=(Ka=cl.safeClone(r.itemData))==null?void 0:Ka.find(We=>(We==null?void 0:We.key)==="formFlex"),Ha=(ma=cl.safeClone(r.itemData))==null?void 0:ma.find(We=>(We==null?void 0:We.key)==="formWrap"),_a=(il=cl.safeClone(r.itemData))==null?void 0:il.find(We=>(We==null?void 0:We.key)==="enableWrap"),Qa=(Aa=cl.safeClone(r.itemData))==null?void 0:Aa.find(We=>(We==null?void 0:We.key)==="textSize"),Pe=(sl=cl.safeClone(r.itemData))==null?void 0:sl.find(We=>(We==null?void 0:We.key)==="textRGBA"),Re=(rl=cl.safeClone(r.itemData))==null?void 0:rl.find(We=>(We==null?void 0:We.key)==="backGround"),Ue=(qe=cl.safeClone(r.itemData))==null?void 0:qe.find(We=>(We==null?void 0:We.key)==="backGroundImage");(Ha==null?void 0:Ha.contents)==="纵向"?C.value=!1:C.value=!0;const Ne=Number(Qa==null?void 0:Qa.contents);E.value=Number.isNaN(Ne)?void 0:Ne,P.value=Pe==null?void 0:Pe.contents,V.value=Re==null?void 0:Re.contents,ee.value=Ue==null?void 0:Ue.contents;const Ie=_a==null?void 0:_a.contents;if(Ie===void 0?g.value=si.BLOCK:typeof Ie=="boolean"?g.value=Ie?si.ORDINARY:si.BLOCK:g.value=Ie,J.value=typeof(Ze==null?void 0:Ze.contents)!="boolean"?!(!(Ze!=null&&Ze.contents)===""||((Ga=Ze==null?void 0:Ze.contents)==null?void 0:Ga.toUpperCase())==="VERTICAL"):Ze==null?void 0:Ze.contents,((hl=ae==null?void 0:ae.contents)==null?void 0:hl.length)>0&&Array.isArray(ae==null?void 0:ae.contents)){let We=r.allMapContents;const Ma=(na=(pe=cl.safeClone(ae))==null?void 0:pe.contents)==null?void 0:na.map((Oe,lr)=>{var Kr,Xr,Wr,rr,nr,Zr,ml,or,Fl,Er,Wl,hr,Vr;let br=(Oe==null?void 0:Oe.label)??(Oe==null?void 0:Oe.key)??"";Oe==null||Oe.type;let Dr=(Oe==null?void 0:Oe.options)??[];if((Kr=Oe==null?void 0:Oe.key)!=null&&Kr.includes("$")&&(br=(Xr=cl.safeClone(Oe==null?void 0:Oe.key).split("$"))==null?void 0:Xr[0],((rr=(Wr=cl.safeClone(Oe==null?void 0:Oe.key).split("$"))==null?void 0:Wr[1])==null?void 0:rr.length)>0)){const[kr,cn]=(Zr=(nr=cl.safeClone(Oe==null?void 0:Oe.key).split("$"))==null?void 0:nr[1])==null?void 0:Zr.split(/[()]/);(ml=oe.FormType.find(Qr=>(Qr==null?void 0:Qr.key)===kr))==null||ml.value,((or=cn==null?void 0:cn.split(","))==null?void 0:or.length)>0&&(Dr=(Fl=cn==null?void 0:cn.split(","))==null?void 0:Fl.map(Qr=>({label:Qr,value:Qr})))}let zl=Oe==null?void 0:Oe.options;((Er=Oe==null?void 0:Oe.optionUrl)==null?void 0:Er.selectRelateType)==="自定义绑定"&&(zl=(hr=(Wl=Oe==null?void 0:Oe.optionUrl)==null?void 0:Wl.defaultSelect)==null?void 0:hr.map(kr=>({label:kr,value:kr})));let $r=(Oe==null?void 0:Oe.menuPath)??[],Ur=(Oe==null?void 0:Oe.groups)??[],Ul=(Oe==null?void 0:Oe.columns)??[],gr=!1,vn=(Oe==null?void 0:Oe.isFormColHidden)??!1,vr="",Il=Oe!=null&&Oe.value?Oe.value:(zl==null?void 0:zl.length)>0?(Vr=zl==null?void 0:zl[0])==null?void 0:Vr.value:(Oe==null?void 0:Oe.value)??"",sn=!1,jr="Input";return((zl==null?void 0:zl.length)>0||($r==null?void 0:$r.length)>0)&&(jr="Select"),(Array.isArray(vr)&&(vr!=null&&vr.every(kr=>(kr==null?void 0:kr.name)&&(kr==null?void 0:kr.url)))||Array.isArray(Il)&&(Il!=null&&Il.every(kr=>(kr==null?void 0:kr.name)&&(kr==null?void 0:kr.url))))&&(jr="upload"),Oe!=null&&Oe.isMainUrl&&(jr="Url"),{label:br??"",name:br??"t"+lr,prop:br??cl.safeClone(Oe==null?void 0:Oe.key),type:(Oe==null?void 0:Oe.type)??jr,value:(Oe==null?void 0:Oe.type)==="Date"&&Il===""?new Date:Il,id:(Oe==null?void 0:Oe.id)??lr,contents:(zl==null?void 0:zl.length)>0?zl:Dr??[],width:(Oe==null?void 0:Oe.width)??1,isLoginUser:gr,config:Oe==null?void 0:Oe.config,optionUrl:(Oe==null?void 0:Oe.optionUrl)??Oe,isFormColHidden:vn,isHideInForm:(Oe==null?void 0:Oe.isHideInForm)??!1,signature:sn,isMain:Oe==null?void 0:Oe.isMain,required:(Oe==null?void 0:Oe.required)??!1,isMainUrl:Oe==null?void 0:Oe.isMainUrl,operable:(Oe==null?void 0:Oe.operable)??!1,disabled:(Oe==null?void 0:Oe.disabled)??!1,isSync:Oe==null?void 0:Oe.isSync,menus:$r,groups:Ur,words:Ul,allSelectionContents:Oe==null?void 0:Oe.allContents,filterContent:Oe==null?void 0:Oe.filterContents,isNoClick:(Oe==null?void 0:Oe.isNoClick)??!1,functionName:Oe==null?void 0:Oe.functionName,functionRelatedWords:Oe==null?void 0:Oe.functionRelatedWords,calculatorFilter:Oe==null?void 0:Oe.calculatorFilter}}),Sl=Ma==null?void 0:Ma.map(Oe=>Oe==null?void 0:Oe.value);let pr="";Sl==null||Sl.forEach(Oe=>{Oe!==""&&Oe!==void 0&&(pr=pr===""?Oe:pr+"/"+Oe)}),x.setSelectArray(Sl),x.setSelectString(pr);let ga=(Sa=cl.safeClone(Ma))==null?void 0:Sa.map(Oe=>(Oe!=null&&Oe.value&&oe.IsJson(Oe==null?void 0:Oe.value)&&Array.isArray(JSON.parse(Oe==null?void 0:Oe.value))&&(Oe.value=JSON.parse(Oe.value)),Oe)),Zl={};ga==null||ga.forEach(Oe=>{Zl[Oe.label]=Oe==null?void 0:Oe.value}),ga=ga==null?void 0:ga.map(Oe=>{var lr,br,Dr,zl,$r,Ur,Ul,gr,vn;if((Oe==null?void 0:Oe.type)==="Select"&&((lr=Oe==null?void 0:Oe.allSelectionContents)==null?void 0:lr.length)>0&&(Oe.contactValue=Zl),(Dr=(br=Oe==null?void 0:Oe.optionUrl)==null?void 0:br.menuSelect)!=null&&Dr.some(vr=>vr==null?void 0:vr.includes("["))){let vr="";Oe.optionUrl.oldMenuSelect=($r=(zl=cl.safeClone(Oe))==null?void 0:zl.optionUrl)==null?void 0:$r.menuSelect,Oe.optionUrl.menuSelect=(Ul=(Ur=Oe==null?void 0:Oe.optionUrl)==null?void 0:Ur.menuSelect)==null?void 0:Ul.map(Il=>{var sn,jr,qr,Kr,Xr,Wr;if(Il!=null&&Il.includes("[")){let rr=(jr=(sn=Il==null?void 0:Il.replaceAll("[","").replaceAll("]",""))==null?void 0:sn.split(":"))==null?void 0:jr[1];vr=Te((qr=Il==null?void 0:Il.replaceAll("[","").replaceAll("]",""))==null?void 0:qr.split(":"),We==null?void 0:We[Ca.value],We),Il=((Xr=(Kr=cl.safeClone(ga))==null?void 0:Kr.find(nr=>(nr==null?void 0:nr.label)===rr))==null?void 0:Xr.value)||Te((Wr=Il==null?void 0:Il.replaceAll("[","").replaceAll("]",""))==null?void 0:Wr.split(":"),We==null?void 0:We[Ca.value],We)}return Il}),vr!==""&&Oe.value===""&&(Oe.value=be(Oe.optionUrl.menuSelect,Oe.optionUrl.oldMenuSelect,(gr=Oe==null?void 0:Oe.optionUrl)==null?void 0:gr.groupSelect,We),Array.isArray(Oe.value)&&((vn=Oe.value)!=null&&vn.every(Il=>Il==null?void 0:Il.url))&&(Oe.type="UPLOAD"))}return Oe}),h.value=ga,Le.value=((la=h.value)==null?void 0:la.every(Oe=>Oe==null?void 0:Oe.disabled))||T.value===Ca.value,ze.value=(nl=h.value)==null?void 0:nl.every(Oe=>Oe==null?void 0:Oe.operable),De.value=(Je=h.value)==null?void 0:Je.map(Oe=>Oe==null?void 0:Oe.label);let Sr=[],Cr=[];if((Fa=cl.safeClone(h.value))==null||Fa.forEach(Oe=>{var lr;Array.isArray(Oe==null?void 0:Oe.value)&&((lr=Oe==null?void 0:Oe.value)!=null&&lr.find(br=>{var Dr;return(Dr=br==null?void 0:br.url)==null?void 0:Dr.includes(".obj")}))&&(Cr=Oe==null?void 0:Oe.value)}),(Cr==null?void 0:Cr.length)>0){const Oe=(wa=cl.safeClone(Cr))==null?void 0:wa.filter(lr=>{var br;return(br=lr==null?void 0:lr.url)==null?void 0:br.includes(".obj")});Oe==null||Oe.forEach(lr=>{var Dr,zl,$r,Ur;const br=(Dr=Cr==null?void 0:Cr.filter(Ul=>{var gr;return(Ul==null?void 0:Ul.name)===(lr==null?void 0:lr.name)&&((gr=Ul==null?void 0:Ul.url)==null?void 0:gr.includes(".mtl"))}))==null?void 0:Dr.map(Ul=>Ul==null?void 0:Ul.url);Sr.push({objUrl:lr==null?void 0:lr.url,mtlUrls:((zl=Cr==null?void 0:Cr.filter(Ul=>{var gr;return(Ul==null?void 0:Ul.name)===(lr==null?void 0:lr.name)&&((gr=Ul==null?void 0:Ul.url)==null?void 0:gr.includes(".mtl"))}))==null?void 0:zl.length)===1?(Ur=($r=Cr==null?void 0:Cr.filter(Ul=>{var gr;return(Ul==null?void 0:Ul.name)===(lr==null?void 0:lr.name)&&((gr=Ul==null?void 0:Ul.url)==null?void 0:gr.includes(".mtl"))}))==null?void 0:$r[0])==null?void 0:Ur.url:br})}),w.setObjUrl(Sr)}(Oa=cl.safeClone(h.value))==null||Oa.forEach(Oe=>{var lr,br,Dr,zl,$r,Ur,Ul,gr,vn,vr,Il,sn,jr;if((br=(lr=Oe==null?void 0:Oe.value)==null?void 0:lr.toString())!=null&&br.includes(".stl")||(zl=(Dr=Oe==null?void 0:Oe.value)==null?void 0:Dr.toString())!=null&&zl.includes(".STL")||(Ur=($r=Oe==null?void 0:Oe.value)==null?void 0:$r.toString())!=null&&Ur.includes(".obj")||(gr=(Ul=Oe==null?void 0:Oe.value)==null?void 0:Ul.toString())!=null&&gr.includes(".mtl")||(vr=(vn=Oe==null?void 0:Oe.value)==null?void 0:vn.toString())!=null&&vr.includes(".urdf")){let qr={},Kr=[],Xr;Array.isArray(Oe==null?void 0:Oe.value)?Xr=Oe==null?void 0:Oe.value:Xr=(Il=Oe==null?void 0:Oe.value)==null?void 0:Il.split(","),Xr==null||Xr.forEach(Wr=>{Wr.includes(".mtl")?Kr.push(Wr):qr.blob=qr.blob==="undefined"?Wr:qr.blob+","+Wr}),(Kr==null?void 0:Kr.length)>0&&(qr.mtlBlobs=Kr),(jr=(sn=Object.values(qr))==null?void 0:sn[0])!=null&&jr.includes("http:")}})}else h.value=[];let ul=te.value;if((ul==null?void 0:ul.length)>0&&(ul=ul==null?void 0:ul.map(We=>{var Sl,pr,ga,Zl;let Ma=(Sl=We==null?void 0:We.key)==null?void 0:Sl.split("/");return(r==null?void 0:r.compName)===(Ma==null?void 0:Ma[0])&&(pr=h.value)!=null&&pr.find(Sr=>(Sr==null?void 0:Sr.prop)===(Ma==null?void 0:Ma[1]))&&(We.value=(Zl=(ga=h.value)==null?void 0:ga.find(Sr=>(Sr==null?void 0:Sr.prop)===(Ma==null?void 0:Ma[1])))==null?void 0:Zl.value),We}),Y.setTableViewContents(ul)),r!=null&&r.formRules)u.value=r==null?void 0:r.formRules;else{let We={};(Me=cl.safeClone(h).value)==null||Me.forEach(Ma=>{((Ma==null?void 0:Ma.isMain)===!0||(Ma==null?void 0:Ma.required)===!0)&&(We[(Ma==null?void 0:Ma.prop)??(Ma==null?void 0:Ma.name)]=[{required:!0,message:`${(Ma==null?void 0:Ma.label)||(Ma==null?void 0:Ma.prop)||(Ma==null?void 0:Ma.name)}不能为空`}])}),u.value=We}if(((Ra=Xe==null?void 0:Xe.contents)==null?void 0:Ra.length)>0){const We=[];(Va=Xe==null?void 0:Xe.contents)==null||Va.forEach((Ma,Sl)=>{(Ma==null?void 0:Ma.label)!==""&&We.push({label:(Ma==null?void 0:Ma.label)??"",id:(Ma==null?void 0:Ma.id)??Sl,type:(Ma==null?void 0:Ma.type)??"",background:Ma==null?void 0:Ma.background})}),O.value=We}else O.value=[];(Bl=h.value)!=null&&Bl.some(We=>(We==null?void 0:We.functionName)&&(We==null?void 0:We.functionName)!=="")&&(h.value=await Be(h.value))},{deep:!0,immediate:!0}),e.watch(()=>T.value,ae=>{Le.value=ae===Ca.value},{immediate:!0}),(ae,se)=>{var Pe;const Xe=e.resolveComponent("svg-icon"),Ze=e.resolveComponent("el-switch"),Ha=e.resolveComponent("el-checkbox"),_a=e.resolveComponent("el-popover"),Qa=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",X3,[g.value===e.unref(si).TEXT?(e.openBlock(),e.createBlock(Oc,{key:0,itemData:a.itemData,compName:a.compName,fields:h.value,textSize:E.value,textColor:P.value,backGround:V.value,backGroundImage:ee.value,disabled:Le.value||Se(),"onUpdate:backGroundImage":va,backgroundUrl:s.value},null,8,["itemData","compName","fields","textSize","textColor","backGround","backGroundImage","disabled","backgroundUrl"])):g.value===e.unref(si).BLOCK?(e.openBlock(),e.createBlock(Mf,{key:1,items:(Pe=h.value)==null?void 0:Pe.map(Re=>({label:Re!=null&&Re.isHideInForm?"":Re==null?void 0:Re.label,value:Re==null?void 0:Re.value,width:(Re==null?void 0:Re.width)??1,field:Re})),textSize:E.value,textColor:P.value,backGround:V.value,backGroundImage:ee.value,disabled:Le.value||Se(),"onUpdate:backGroundImage":va,backgroundUrl:s.value},null,8,["items","textSize","textColor","backGround","backGroundImage","disabled","backgroundUrl"])):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass({"form-shadow-box":g.value===e.unref(si).ORDINARY})},[e.createVNode(cl.ssForm,{rowContents:h.value,formRules:u.value,buttonValue:O.value,isRowFlex:!1,isEnableWrap:!0,textSize:E.value,textColor:P.value,backGround:V.value,backGroundImage:ee.value,onOnButtonClick:fa,onChange:Ba,formDisabled:Le.value||Se(),formLabelsOperable:ze.value,isButtonRow:C.value,onPreview:La,onBlurChange:Ae,style:e.normalizeStyle({backGroundImage:s.value!==""?`url("${s.value}")`:void 0}),onHandleColEditChange:ta,onHandleColTypeChange:Fe,onRouteUrl:he,onClickTrigger:X,"onUpdate:backGroundImage":va},{operateCol:e.withCtx(({renderColumns:Re,formDisabled:Ue,formLabelsOperable:Ne})=>[e.createVNode(_a,{title:"选择操作的标签",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:$},{reference:e.withCtx(()=>[e.createElementVNode("span",Z3,[e.createVNode(Xe,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"}})])]),default:e.withCtx(()=>[e.createElementVNode("div",Q3,[se[1]||(se[1]=e.createElementVNode("div",{class:"group-title"},"表单操作",-1)),e.createVNode(Ze,{"model-value":Ue,"active-text":"禁用","inactive-text":"",onChange:ua,style:{"margin-right":"8px"}},null,8,["model-value"]),e.createVNode(Ze,{"model-value":Ne,"active-text":"编辑所有标签","inactive-text":"",onChange:Za},null,8,["model-value"]),se[2]||(se[2]=e.createElementVNode("div",{class:"group-title"},"表单列操作",-1)),e.createVNode(Qa,{modelValue:De.value,"onUpdate:modelValue":se[0]||(se[0]=Ie=>De.value=Ie),style:{height:"100%"},ref_key:"checkboxGroupRef",ref:ge,onChange:H},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Re,Ie=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:Ie.label},[e.createVNode(Ha,{value:Ie.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(Ie.label),1)]),_:2},1032,["value"]),e.createVNode(_a,{title:"标签操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(Xe,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var ul;return[e.createElementVNode("div",eh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((ul=Object.keys(Ie))==null?void 0:ul.filter(_l=>{var Tl;return(Tl=Ke.value)==null?void 0:Tl.find(jl=>(jl==null?void 0:jl.value)===_l)}),_l=>{var Tl,jl;return e.openBlock(),e.createElementBlock("div",{key:_l},[e.createVNode(cl._sfc_main$1,{value:Ie==null?void 0:Ie[_l],"active-text":(jl=(Tl=Ke.value)==null?void 0:Tl.find(Cl=>(Cl==null?void 0:Cl.value)===_l))==null?void 0:jl.label,inactiveText:"",onChange:Cl=>xa(Cl,_l,Ie)},null,8,["value","active-text","onChange"])])}),128))])]}),_:2},1024),e.createElementVNode("span",ah,[e.createVNode(Xe,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:2},1032,["modelValue"])])]),_:2},1024)]),_:1},8,["rowContents","formRules","buttonValue","textSize","textColor","backGround","backGroundImage","formDisabled","formLabelsOperable","isButtonRow","style"])],2)),M.value?(e.openBlock(),e.createBlock(cl.ssFilePreview,{key:3,fileDataList:j.value,onDestroy:Ia},null,8,["fileDataList"])):e.createCommentVNode("",!0),c.value?(e.openBlock(),e.createBlock(Ar.ssDialog,{key:4,visible:c.value,onBeforeDestroy:n,style:{height:"700px",width:"1000px"}},{default:e.withCtx(()=>[e.createVNode(Bo.ThreeViewerHost,{files:m.value,onGetAnimationData:ae.onAnimationData},null,8,["files","onGetAnimationData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0)])}}},Cs=ar._export_sfc(lh,[["__scopeId","data-v-4eb80a57"]]),Ro=e.ref(0),Lc=a=>{var l;return!a||(a==null?void 0:a.length)===0?[]:(l=A.cloneDeep(a))==null?void 0:l.map(r=>(Ro.value++,r={label:(r==null?void 0:r.label)??"",prop:(r==null?void 0:r.label)==="操作"?"operate":r==null?void 0:r.prop,width:r!=null&&r.width?parseInt(r.width):"",fixed:(r==null?void 0:r.fixed)??void 0,sortable:(r==null?void 0:r.sortable)??!1,align:(r==null?void 0:r.align)??"left",showOverflowTooltip:(r==null?void 0:r.showOverflowTooltip)??!0,isNotDrag:(r==null?void 0:r.isNotDrag)??!1,isEditCol:(r==null?void 0:r.isEditCol)??!1,isOperate:(r==null?void 0:r.isOperate)??!1,id:(r==null?void 0:r.id)??Ro.value,children:Lc(r==null?void 0:r.children)},r))},rh=a=>{var n;return(n=A.cloneDeep(a))==null?void 0:n.map(r=>(Ro.value++,r={label:(r==null?void 0:r.label)??"",prop:(r==null?void 0:r.label)==="操作"?"operate":r==null?void 0:r.prop,width:r!=null&&r.width?parseInt(r.width):"",fixed:(r==null?void 0:r.fixed)??void 0,sortable:(r==null?void 0:r.sortable)??!1,align:(r==null?void 0:r.align)??"left",showOverflowTooltip:(r==null?void 0:r.showOverflowTooltip)??!0,isNotDrag:(r==null?void 0:r.isNotDrag)??!1,isEditCol:(r==null?void 0:r.isEditCol)??!1,isOperate:(r==null?void 0:r.isOperate)??!1,id:(r==null?void 0:r.id)??Ro.value,children:Lc(r==null?void 0:r.children)},r))},Rc=(a,l)=>{var n;return a!=null&&a.find(r=>(r==null?void 0:r.id)===l)?(n=A.cloneDeep(a))==null?void 0:n.filter(i=>(i==null?void 0:i.id)!==l):(a=a==null?void 0:a.map(r=>(r.children=Rc(r==null?void 0:r.children,l),r)),a)},$c=(a,l)=>{var n;return a!=null&&a.find(r=>(r==null?void 0:r.id)===(l==null?void 0:l.id))?(n=A.cloneDeep(a))==null?void 0:n.map(i=>((i==null?void 0:i.id)===(l==null?void 0:l.id)&&(i=l),i)):(a=a==null?void 0:a.map(r=>(r.children=$c(r==null?void 0:r.children,l),r)),a)},Vc=(a,l)=>{var n;return a!=null&&a.find(r=>{var i;return(r==null?void 0:r.id)===((i=l==null?void 0:l.contents)==null?void 0:i.id)})?(n=A.cloneDeep(a))==null?void 0:n.map(i=>{var s;return(i==null?void 0:i.id)===((s=l==null?void 0:l.contents)==null?void 0:s.id)&&(i=l==null?void 0:l.contents),i}):(a=a==null?void 0:a.map(r=>(r.children=Vc(r==null?void 0:r.children,l),r)),a)},Pc=(a,l)=>{var n;return a!=null&&a.find(r=>(r==null?void 0:r.id)===(l==null?void 0:l.id))?(n=A.cloneDeep(a))==null?void 0:n.map(i=>((i==null?void 0:i.id)===(l==null?void 0:l.id)&&(i!=null&&i.children||(i.children=[]),i.children.push(l.contents)),i)):(a=a==null?void 0:a.map(r=>(r.children=Pc(r==null?void 0:r.children,l),r)),a)},ur=[{key:"label",label:"标签名",type:"Input"},{key:"prop",label:"属性名",type:"Input"},{key:"width",label:"宽度",type:"Input"},{key:"sortable",label:"是否支持排序",type:"Switch"},{key:"align",label:"文本所在位置",type:"Radio",options:[{label:"left",value:"左"},{label:"center",value:"中"},{label:"right",value:"右"}]},{key:"fixed",label:"是否固定列",type:"Switch"}],nh=[{label:"查看",value:"view"},{label:"修改",value:"fix"},{label:"删除",value:"delete"},{label:"三维算例",value:"modelExample"}],ih=[{label:"新增",value:"add"}],Vn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:ih},{key:"background",label:"按钮背景色",type:"Color"}],Pn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:nh},{key:"textColor",label:"按钮颜色",type:"Color"}],oh={class:"table-header-child"},th={class:"table-header-child-main"},sh={class:"table-header-child-content"},ch={class:"table-header-child-content-item"},uh={class:"fix-button"},dh={key:0},ph={class:"form-content"},fh={__name:"tableNewChild",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(!1),s=e.ref(""),h=oe.useTableComp(A.pinia),{tableIndex:c}=A.storeToRefs(h);e.ref(0);const d=e.ref(""),m=e.ref([]),b=e.ref([]),u=_=>{var w;i.value=!0;let x=[];ur==null||ur.forEach(g=>{let E=A.cloneDeep(c.value)+1;h.setTableIndex(E),x.push({label:g==null?void 0:g.label,name:g==null?void 0:g.label,type:g.type,value:_[g.key],id:c.value,contents:g==null?void 0:g.options})}),_!=null&&_.children&&((w=_==null?void 0:_.children)==null?void 0:w.length)>0&&x.push({children:_==null?void 0:_.children,isFormColHidden:!0}),d.value=_==null?void 0:_.id,m.value=x,b.value=x},C=_=>{r("fixChange",A.cloneDeep(_))},M=_=>{r("deleteChange",A.cloneDeep(_))},k=_=>{i.value=!0;let x=[];ur==null||ur.forEach(w=>{let g=A.cloneDeep(c.value)+1;h.setTableIndex(g),x.push({label:w==null?void 0:w.label,name:w==null?void 0:w.label,type:w.type,value:"",id:c.value,contents:w==null?void 0:w.options})}),s.value=_==null?void 0:_.id,m.value=x,b.value=x},W=_=>{let x=A.cloneDeep(b.value);x=x==null?void 0:x.map(w=>(w.children||(w.value=_==null?void 0:_[w.name]),w)),b.value=x},O=()=>{var x,w;m.value=b.value;let _={};if(d.value!=="")_.id=d.value,(x=m.value)==null||x.forEach(g=>{const E=ur==null?void 0:ur.find(P=>(P==null?void 0:P.label)===(g==null?void 0:g.label));E?_[E.key]=g.value:g!=null&&g.children&&g.children.length>0&&(_.children=g.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(_),id:s.value,type:"fix"});else{let g=A.cloneDeep(c.value)+1;h.setTableIndex(g),_.id="id"+c.value,(w=m.value)==null||w.forEach(E=>{const P=ur==null?void 0:ur.find(V=>(V==null?void 0:V.label)===(E==null?void 0:E.label));P?_[P.key]=E.value:E!=null&&E.children&&E.children.length>0&&(_.children=E.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(_),id:s.value,type:"add"})}d.value="",m.value=[],b.value=[]},j=()=>{i.value=!1,d.value="",s.value="",m.value=[],b.value=[]},L=_=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{r("deleteChange",_),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(_,x)=>{const w=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",oh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n==null?void 0:n.tableChildContents,(g,E)=>(e.openBlock(),e.createElementBlock("div",th,[e.createElementVNode("div",sh,[e.createElementVNode("div",ch,e.toDisplayString(g.label),1),e.createElementVNode("div",uh,[e.createVNode(w,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:P=>k(g)},null,8,["onClick"]),e.createVNode(w,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:P=>u(g)},null,8,["onClick"]),e.createVNode(w,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:P=>L(g)},null,8,["onClick"])])]),g!=null&&g.children&&g.children.length>0?(e.openBlock(),e.createElementBlock("div",dh,[e.createVNode(Fc,{tableChildContents:g==null?void 0:g.children,onDeleteChange:M,onFixChange:C},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode(Ar.ssDialog,{visible:i.value,onBeforeDestroy:j,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",ph,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:W},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:j,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:O},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},hh=ar._export_sfc(fh,[["__scopeId","data-v-e0fef72d"]]),vh={class:"table-header-child"},mh={class:"table-header-child-main"},yh={class:"table-header-child-content"},gh={class:"table-header-child-content-item"},bh={class:"fix-button"},kh={key:0},xh={class:"form-content"},wh={class:"dialog-footer"},_h={__name:"tableChildren",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(!1),s=e.ref(""),h=oe.useTableComp(A.pinia),{tableIndex:c}=A.storeToRefs(h),d=e.ref(""),m=e.ref([]),b=e.ref([]),u=_=>{r("fixChange",A.cloneDeep(_))},C=_=>{var w;i.value=!0;let x=[];ur==null||ur.forEach(g=>{let E=A.cloneDeep(c.value)+1;h.setTableIndex(E),x.push({label:g==null?void 0:g.label,name:g==null?void 0:g.label,type:g.type,value:_[g.key],id:c.value,contents:g==null?void 0:g.options})}),_!=null&&_.children&&((w=_==null?void 0:_.children)==null?void 0:w.length)>0&&x.push({children:_==null?void 0:_.children,isFormColHidden:!0}),d.value=_==null?void 0:_.id,m.value=x,b.value=x},M=_=>{i.value=!0;let x=[];ur==null||ur.forEach(w=>{let g=A.cloneDeep(c.value)+1;h.setTableIndex(g),x.push({label:w==null?void 0:w.label,name:w==null?void 0:w.label,type:w.type,value:"",id:c.value,contents:w==null?void 0:w.options})}),s.value=_==null?void 0:_.id,m.value=x,b.value=x},k=_=>{let x=A.cloneDeep(b.value);x=x==null?void 0:x.map(w=>(w.children||(w.value=_==null?void 0:_[w.name]),w)),b.value=x},W=()=>{var x,w;m.value=b.value;let _={};if(d.value!=="")_.id=d.value,(x=m.value)==null||x.forEach(g=>{const E=ur==null?void 0:ur.find(P=>(P==null?void 0:P.label)===(g==null?void 0:g.label));E?_[E.key]=g.value:g!=null&&g.children&&g.children.length>0&&(_.children=g.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(_),id:s.value,type:"fix"});else{let g=A.cloneDeep(c.value)+1;h.setTableIndex(g),_.id="idChild"+c.value,(w=m.value)==null||w.forEach(E=>{const P=ur==null?void 0:ur.find(V=>(V==null?void 0:V.label)===(E==null?void 0:E.label));P?_[P.key]=E.value:E!=null&&E.children&&E.children.length>0&&(_.children=E.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(_),id:s.value,type:"add"})}d.value="",m.value=[],b.value=[]},O=()=>{i.value=!1,d.value="",s.value="",m.value=[],b.value=[]},j=_=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{r("deleteChange",_),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},L=_=>{r("deleteChange",_)};return(_,x)=>{const w=e.resolveComponent("svg-icon"),g=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",vh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n==null?void 0:n.tableChildContents,(E,P)=>(e.openBlock(),e.createElementBlock("div",mh,[e.createElementVNode("div",yh,[e.createElementVNode("div",gh,e.toDisplayString(E.label),1),e.createElementVNode("div",bh,[e.createVNode(w,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:V=>M(E)},null,8,["onClick"]),e.createVNode(w,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:V=>C(E)},null,8,["onClick"]),e.createVNode(w,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:V=>j(E)},null,8,["onClick"])])]),E!=null&&E.children&&E.children.length>0?(e.openBlock(),e.createElementBlock("div",kh,[e.createVNode(hh,{tableChildContents:E==null?void 0:E.children,onDeleteChange:L,onFixChange:u},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode(Ar.ssDialog,{visible:i.value,onBeforeDestroy:O,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",xh,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:k},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",wh,[e.createVNode(g,{onClick:O,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>x[0]||(x[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(g,{class:"ok-button button",onClick:W,id:"themeButton"},{default:e.withCtx(()=>x[1]||(x[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},Fc=ar._export_sfc(_h,[["__scopeId","data-v-ebd68fa1"]]),Sh={class:"table-operate-content"},Eh={class:"table-operate-item"},Ch={class:"operate-title"},Dh={class:"operate-content"},Th={class:"fix-content"},Bh={class:"fix-content-label"},Nh={class:"fix-button"},Ah={key:0},zh={class:"operate-title"},Mh={class:"operate-content"},Ih={class:"fix-content"},Oh={class:"fix-content-label"},Lh={class:"fix-button"},Rh={class:"operate-title"},$h={class:"operate-content"},Vh={class:"fix-content"},Ph={class:"fix-content-label"},Fh={class:"fix-button"},jh={class:"operate-title"},Hh={class:"operate-content"},Uh={class:"fix-content"},qh={class:"fix-content-label"},Wh={class:"fix-button"},Kh={class:"operate-content"},Gh={style:{display:"flex","justify-content":"space-between"}},Yh={class:"form-content"},Jh={class:"dialog-footer"},Xh={class:"form-content"},Zh={class:"dialog-footer"},Qh={class:"form-content"},e6={class:"dialog-footer"},a6={class:"form-content"},l6={class:"dialog-footer"},r6={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.ref([]),s=e.ref(!1),h=e.ref(!1),c=e.ref([]),d=e.ref(!1),m=e.ref([]),b=e.ref(!1),u=e.ref([]),C=e.ref(""),M=e.ref(""),k=e.ref([]),W=e.ref([]),O=e.ref([]),j=e.ref([]),L=e.ref(!1),_=e.ref([]),x=e.ref([]),w=e.ref(0),g=e.ref([]),E=e.ref([]),P=e.ref([]),V=()=>{L.value=!0;let $=[];Vn==null||Vn.forEach(H=>{w.value++,$.push({label:H==null?void 0:H.label,name:H==null?void 0:H.label,type:H.type,value:(H==null?void 0:H.key)==="background"?"var(--ssComponent-primary-color)":"",id:w.value,contents:H==null?void 0:H.options})}),_.value=$,x.value=$},ee=()=>{var H,X,he;h.value=!0;let $=[];(he=(X=(H=oe.FormContent)==null?void 0:H.find(fe=>(fe==null?void 0:fe.key)==="Input"))==null?void 0:X.value)==null||he.forEach(fe=>{w.value++,$.push({label:fe==null?void 0:fe.label,name:(fe==null?void 0:fe.name)||(fe==null?void 0:fe.label),type:fe.type,value:(fe==null?void 0:fe.label)==="类型"?"Input":"",id:w.value,contents:fe==null?void 0:fe.options})}),g.value=$,E.value=$},J=$=>{$||(g.value=E.value)},me=async $=>{var H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia;if(($==null?void 0:$.类型)!==((X=(H=E.value)==null?void 0:H.find(fa=>(fa==null?void 0:fa.label)==="类型"))==null?void 0:X.value)){let fa=[],Ba=await((ha=(fe=(he=oe.FormContent)==null?void 0:he.find(Te=>(Te==null?void 0:Te.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:fe.value)==null?void 0:ha.value)?await((va=(Ae=(xa=oe.FormContent)==null?void 0:xa.find(Te=>(Te==null?void 0:Te.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:Ae.value)==null?void 0:va.value):(Fe=(ta=oe.FormContent)==null?void 0:ta.find(Te=>(Te==null?void 0:Te.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:Fe.value;if(Ba==null||Ba.forEach(Te=>{w.value++,fa.push({label:Te==null?void 0:Te.label,name:(Te==null?void 0:Te.name)||(Te==null?void 0:Te.label),type:Te.type,value:Te!=null&&Te.属性名?($==null?void 0:$.prop)||($==null?void 0:$.name)||($==null?void 0:$.label):($==null?void 0:$[Te.label])??"",id:w.value,contents:Te==null?void 0:Te.options,prop:(Te==null?void 0:Te.prop)||(Te==null?void 0:Te.name)||(Te==null?void 0:Te.label)})}),$!=null&&$.菜单选项&&((La=$==null?void 0:$.菜单选项)==null?void 0:La.length)>0){const Te=await oe.menuToContentType($==null?void 0:$.菜单选项);fa=fa==null?void 0:fa.map(be=>((be==null?void 0:be.name)==="组信息选项"&&(be.contents=Te),be))}E.value=await oe.selectToBase(A.cloneDeep(fa)),g.value=await oe.selectToBase(A.cloneDeep(fa))}else{let fa=A.cloneDeep(g.value);if(fa=fa==null?void 0:fa.map(Ba=>(Ba.value=$==null?void 0:$[Ba.name],Ba)),$!=null&&$.菜单选项&&((Ia=$==null?void 0:$.菜单选项)==null?void 0:Ia.length)>0){const Ba=await oe.menuToContentType($==null?void 0:$.菜单选项);fa=fa==null?void 0:fa.map(Te=>((Te==null?void 0:Te.name)==="组信息选项"&&(Te.contents=Ba),Te))}fa=oe.formToOptionsContents(fa),E.value=await oe.selectToBase(A.cloneDeep(fa))}},_e=async $=>{await me($),g.value=E.value},z=($,H)=>{if((H==null?void 0:H.type)=="Select"&&($==null?void 0:$.key)==="selectRelateType"){const X=H==null?void 0:H.optionUrl;return(X==null?void 0:X.selectRelateType)||H[$.key]}if((H==null?void 0:H.type)=="Select"&&($==null?void 0:$.key)==="menuSelect"){const X=H==null?void 0:H.optionUrl;return(X==null?void 0:X.menuSelect)||H[$.key]}if((H==null?void 0:H.type)=="Select"&&($==null?void 0:$.key)==="groupSelect"){const X=H==null?void 0:H.optionUrl;return(X==null?void 0:X.groupSelect)||H[$.key]}if((H==null?void 0:H.type)=="Select"&&($==null?void 0:$.key)==="originalContent")return(H==null?void 0:H.value)||H[$.key];if((H==null?void 0:H.type)=="Select"&&($==null?void 0:$.key)==="multiple"){const X=H[$.key];return lc(X)?X:$.default}return($==null?void 0:$.label)==="类型"&&H[$.key]===""?"Input":($==null?void 0:$.key)==="isFormColHidden"&&!H[$.key]?!1:H[$.key]},ne=async $=>{var he,fe,ha,ta,Fe,xa,Ae,va,La;h.value=!0;let H=[];const X=await((ha=(fe=(he=oe.FormContent)==null?void 0:he.find(Ia=>(Ia==null?void 0:Ia.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:fe.value)==null?void 0:ha.value)?await((va=(Ae=(xa=oe.FormContent)==null?void 0:xa.find(Ia=>(Ia==null?void 0:Ia.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:Ae.value)==null?void 0:va.value):(Fe=(ta=oe.FormContent)==null?void 0:ta.find(Ia=>(Ia==null?void 0:Ia.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:Fe.value;if(X==null||X.forEach(Ia=>{w.value++,H.push({label:Ia==null?void 0:Ia.label,name:(Ia==null?void 0:Ia.name)||(Ia==null?void 0:Ia.label),type:Ia.type,value:(Ia==null?void 0:Ia.label)==="属性名"?($==null?void 0:$.prop)||($==null?void 0:$.name)||($==null?void 0:$.label):z(Ia,$),id:w.value,contents:Ia==null?void 0:Ia.options})}),$!=null&&$.menuSelect&&((La=$==null?void 0:$.menuSelect)==null?void 0:La.length)>0){const Ia=await oe.menuToContentType($==null?void 0:$.menuSelect);H=H==null?void 0:H.map(fa=>((fa==null?void 0:fa.name)==="组信息选项"&&(fa.contents=Ia),fa))}C.value=$==null?void 0:$.id,g.value=await oe.selectToBase(oe.formToOptionsContents(H)),E.value=await oe.selectToBase(oe.formToOptionsContents(H))},Y=$=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,X;P.value=(H=A.cloneDeep(P.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==($==null?void 0:$.id)),r("change",(X=A.cloneDeep(n.originalItemContents))==null?void 0:X.map(he=>((he==null?void 0:he.key)==="tableToForm"&&(he.contents=P.value),he))),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},te=()=>{h.value=!1,g.value=[],C.value=""},ye=async()=>{var he,fe,ha,ta,Fe,xa,Ae,va,La,Ia;g.value=E.value;let $={};C.value!==""?$.id=C.value:(w.value++,$.id="id"+w.value);let H=await((ha=(fe=(he=oe.FormContent)==null?void 0:he.find(fa=>{var Ba,Te;return(fa==null?void 0:fa.key)===(((Te=(Ba=g.value)==null?void 0:Ba.find(be=>(be==null?void 0:be.label)==="类型"))==null?void 0:Te.value)??"label")}))==null?void 0:fe.value)==null?void 0:ha.value)??((Fe=(ta=oe.FormContent)==null?void 0:ta.find(fa=>{var Ba,Te;return(fa==null?void 0:fa.key)===(((Te=(Ba=g.value)==null?void 0:Ba.find(be=>(be==null?void 0:be.label)==="类型"))==null?void 0:Te.value)??"label")}))==null?void 0:Fe.value);if((xa=g.value)==null||xa.forEach(fa=>{const Ba=H==null?void 0:H.find(Te=>(Te==null?void 0:Te.label)===(fa==null?void 0:fa.label));Ba&&($[Ba.key]=fa.value)}),$.name=$.label,(Ae=P.value)!=null&&Ae.find(fa=>fa.id===$.id))P.value=(va=P.value)==null?void 0:va.map(fa=>(fa.id===$.id&&(fa=$),fa));else{let fa=A.cloneDeep(P.value);P.value||(P.value=[]),fa.push($),P.value=fa}P.value=P.value.map(({id:fa,...Ba})=>Ba),h.value=!1,C.value="";let X=A.cloneDeep(n.originalItemContents);(La=A.cloneDeep(n.originalItemContents))!=null&&La.find(fa=>(fa==null?void 0:fa.key)==="tableToForm")?X=(Ia=A.cloneDeep(n.originalItemContents))==null?void 0:Ia.map(fa=>((fa==null?void 0:fa.key)==="tableToForm"&&(fa.contents=P.value),fa)):X.push({key:"tableToForm",contents:P.value}),r("change",X)},$e=$=>{L.value=!0;let H=[];Vn==null||Vn.forEach(X=>{w.value++,H.push({label:X==null?void 0:X.label,name:X==null?void 0:X.label,type:X.type,value:$[X.key],id:w.value,contents:X==null?void 0:X.options})}),C.value=$==null?void 0:$.id,_.value=H,x.value=H};e.watch(()=>b.value,()=>{var H,X;let $=A.cloneDeep(n.originalItemContents);(H=A.cloneDeep(n.originalItemContents))!=null&&H.find(he=>(he==null?void 0:he.key)==="page")?$=(X=A.cloneDeep(n.originalItemContents))==null?void 0:X.map(he=>((he==null?void 0:he.key)==="page"&&(he.contents=b.value),he)):$.push({key:"page",contents:b.value}),r("change",$)},{deep:!0});const de=$=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,X;W.value=(H=A.cloneDeep(W.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==($==null?void 0:$.id)),r("change",(X=A.cloneDeep(n.originalItemContents))==null?void 0:X.map(he=>((he==null?void 0:he.key)==="extraButton"&&(he.contents=W.value),he))),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},T=()=>{var X,he,fe,ha,ta;_.value=x.value;let $={};if(C.value!==""?$.id=C.value:(w.value++,$.id="id"+w.value),(X=_.value)==null||X.forEach(Fe=>{const xa=Vn==null?void 0:Vn.find(Ae=>(Ae==null?void 0:Ae.label)===(Fe==null?void 0:Fe.label));xa?$[xa.key]=Fe.value:Fe!=null&&Fe.children&&Fe.children.length>0&&($.children=Fe.children)}),(he=W.value)!=null&&he.find(Fe=>Fe.id===$.id))W.value=(fe=W.value)==null?void 0:fe.map(Fe=>(Fe.id===$.id&&(Fe=$),Fe));else{let Fe=A.cloneDeep(W.value)??[];Fe.push($),W.value=Fe}L.value=!1,C.value="";let H=A.cloneDeep(n.originalItemContents);(ha=A.cloneDeep(n.originalItemContents))!=null&&ha.find(Fe=>(Fe==null?void 0:Fe.key)==="extraButton")?H=(ta=A.cloneDeep(n.originalItemContents))==null?void 0:ta.map(Fe=>((Fe==null?void 0:Fe.key)==="extraButton"&&(Fe.contents=W.value),Fe)):H.push({key:"extraButton",contents:W.value}),r("change",H)},ie=$=>{let H=A.cloneDeep(x.value);H=H==null?void 0:H.map(X=>(X.children||(X.value=$==null?void 0:$[X.name]),X)),x.value=H},U=()=>{L.value=!1,_.value=[],C.value=""},ge=$=>{d.value=!0;let H=[];Pn==null||Pn.forEach(X=>{w.value++,H.push({label:X==null?void 0:X.label,name:X==null?void 0:X.label,type:X.type,value:$[X.key],id:w.value,contents:X==null?void 0:X.options})}),C.value=$==null?void 0:$.id,O.value=H,j.value=H},ze=$=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,X;k.value=(H=A.cloneDeep(k.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==($==null?void 0:$.id)),r("change",(X=A.cloneDeep(n.originalItemContents))==null?void 0:X.map(he=>((he==null?void 0:he.key)==="rowButton"&&(he.contents=k.value),he))),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},Le=()=>{s.value=!0;let $=[];ur==null||ur.forEach(H=>{w.value++,$.push({label:H==null?void 0:H.label,name:H==null?void 0:H.label,type:H.type,value:"",id:w.value,contents:H==null?void 0:H.options})}),m.value=$,u.value=$},ra=()=>{d.value=!0;let $=[];Pn==null||Pn.forEach(H=>{w.value++,$.push({label:H==null?void 0:H.label,name:H==null?void 0:H.label,type:H.type,value:"",id:w.value,contents:H==null?void 0:H.options})}),O.value=$,j.value=$},Ca=$=>{let H=A.cloneDeep(j.value);H=H==null?void 0:H.map(X=>(X.children||(X.value=$==null?void 0:$[X.name]),X)),j.value=H},Q=()=>{var X,he,fe,ha,ta;O.value=j.value;let $={};if(C.value!==""?$.id=C.value:(w.value++,$.id="id"+w.value),(X=O.value)==null||X.forEach(Fe=>{const xa=Pn==null?void 0:Pn.find(Ae=>(Ae==null?void 0:Ae.label)===(Fe==null?void 0:Fe.label));xa?$[xa.key]=Fe.value:Fe!=null&&Fe.children&&Fe.children.length>0&&($.children=Fe.children)}),(he=k.value)!=null&&he.find(Fe=>Fe.id===$.id))k.value=(fe=k.value)==null?void 0:fe.map(Fe=>(Fe.id===$.id&&(Fe=$),Fe));else{let Fe=A.cloneDeep(k.value);Fe.push($),k.value=Fe}d.value=!1,C.value="";let H=A.cloneDeep(n.originalItemContents);(ha=A.cloneDeep(n.originalItemContents))!=null&&ha.find(Fe=>(Fe==null?void 0:Fe.key)==="rowButton")?H=(ta=A.cloneDeep(n.originalItemContents))==null?void 0:ta.map(Fe=>((Fe==null?void 0:Fe.key)==="rowButton"&&(Fe.contents=k.value),Fe)):H.push({key:"rowButton",contents:k.value}),r("change",H)},ca=()=>{d.value=!1,C.value="",j.value=[],O.value=[]},ue=$=>{s.value=!0;let H=[];ur==null||ur.forEach(X=>{w.value++,H.push({label:X==null?void 0:X.label,name:X==null?void 0:X.label,type:X.type,value:"",id:w.value,contents:X==null?void 0:X.options})}),m.value=H,M.value=$==null?void 0:$.id,u.value=H},pa=$=>{var H;c.value=Rc(A.cloneDeep(c.value),$==null?void 0:$.id),r("change",(H=A.cloneDeep(n.originalItemContents))==null?void 0:H.map(X=>{var he;return(X==null?void 0:X.key)==="header"&&(X.contents=(he=c.value)!=null&&he.some(fe=>fe==null?void 0:fe.children)?[c.value]:c.value),X}))},Se=$=>{var X,he,fe;$.type==="fix"?$.id!==""?c.value=Vc(c.value,$):c.value=$c(c.value,$==null?void 0:$.contents):c.value=Pc(c.value,$),c.value=(X=c.value)!=null&&X.some(ha=>ha==null?void 0:ha.children)?[c.value]:c.value,C.value="";let H=A.cloneDeep(n.originalItemContents);(he=A.cloneDeep(n.originalItemContents))!=null&&he.find(ha=>(ha==null?void 0:ha.key)==="header")?H=(fe=A.cloneDeep(n.originalItemContents))==null?void 0:fe.map(ha=>((ha==null?void 0:ha.key)==="header"&&(ha.contents=c.value),ha)):H.push({key:"header",contents:c.value}),r("change",H)},ce=$=>{var X;s.value=!0;let H=[];ur==null||ur.forEach(he=>{w.value++,H.push({label:he==null?void 0:he.label,name:he==null?void 0:he.label,type:he.type,value:$[he.key],id:w.value,contents:he==null?void 0:he.options})}),$!=null&&$.children&&((X=$==null?void 0:$.children)==null?void 0:X.length)>0&&H.push({children:$==null?void 0:$.children,isFormColHidden:!0}),C.value=$==null?void 0:$.id,M.value="",m.value=H,u.value=H},De=$=>{let H=A.cloneDeep(u.value);H=H==null?void 0:H.map(X=>(X.children||(X.value=$==null?void 0:$[X.name]),X)),u.value=H},Ke=()=>{s.value=!1,C.value="",M.value="",u.value=[]},ua=()=>{var X,he,fe,ha,ta,Fe;m.value=u.value;let $={};if(C.value!==""?$.id=C.value:(w.value++,$.id="id"+w.value),(X=m.value)==null||X.forEach(xa=>{const Ae=ur==null?void 0:ur.find(va=>(va==null?void 0:va.label)===(xa==null?void 0:xa.label));Ae?$[Ae.key]=xa.value:xa!=null&&xa.children&&xa.children.length>0&&($.children=xa.children)}),(he=c.value)!=null&&he.find(xa=>xa.id===$.id))c.value=(fe=c.value)==null?void 0:fe.map(xa=>(xa.id===$.id&&(xa=$),xa));else{let xa=A.cloneDeep(c.value)??[];M.value===""?xa.push($):xa=xa==null?void 0:xa.map(Ae=>(Ae.id===M.value&&(Ae.children||(Ae.children=[]),Ae.children.push($)),Ae)),c.value=xa}c.value=(ha=c.value)!=null&&ha.some(xa=>xa==null?void 0:xa.children)?[c.value]:c.value,s.value=!1,C.value="",M.value="";let H=A.cloneDeep(n.originalItemContents);(ta=A.cloneDeep(n.originalItemContents))!=null&&ta.find(xa=>(xa==null?void 0:xa.key)==="header")?H=(Fe=A.cloneDeep(n.originalItemContents))==null?void 0:Fe.map(xa=>((xa==null?void 0:xa.key)==="header"&&(xa.contents=c.value),xa)):H.push({key:"header",contents:c.value}),r("change",H)},Za=$=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,X;c.value=(H=A.cloneDeep(c.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==($==null?void 0:$.id)),r("change",(X=A.cloneDeep(n.originalItemContents))==null?void 0:X.map(he=>{var fe;return(he==null?void 0:he.key)==="header"&&(he.contents=(fe=c.value)!=null&&fe.some(ha=>ha==null?void 0:ha.children)?[c.value]:c.value),he})),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return e.watch(()=>n.originalItemContents,()=>{var $,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae;if(!(!n.originalItemContents||n.originalItemContents.length===0))if(i.value=A.cloneDeep(n.originalItemContents),c.value=(H=($=i.value)==null?void 0:$.find(se=>(se==null?void 0:se.key)==="header"))==null?void 0:H.contents,k.value=(he=(X=i.value)==null?void 0:X.find(se=>(se==null?void 0:se.key)==="rowButton"))==null?void 0:he.contents,W.value=(ha=(fe=i.value)==null?void 0:fe.find(se=>(se==null?void 0:se.key)==="extraButton"))==null?void 0:ha.contents,b.value=(Fe=(ta=i.value)==null?void 0:ta.find(se=>(se==null?void 0:se.key)==="page"))!=null&&Fe.contents?!!((Ae=(xa=i.value)==null?void 0:xa.find(se=>(se==null?void 0:se.key)==="page"))!=null&&Ae.contents):!1,P.value=(La=(va=i.value)==null?void 0:va.find(se=>(se==null?void 0:se.key)==="tableToForm"))==null?void 0:La.contents,c.value=(Ia=c.value)==null?void 0:Ia.map((se,Xe)=>(Array.isArray(se)?se=rh(se):se={label:(se==null?void 0:se.label)??"",prop:(se==null?void 0:se.label)==="操作"?"operate":se==null?void 0:se.prop,width:se!=null&&se.width?parseInt(se.width):"",fixed:(se==null?void 0:se.fixed)??void 0,sortable:(se==null?void 0:se.sortable)??!1,align:(se==null?void 0:se.align)??"left",showOverflowTooltip:(se==null?void 0:se.showOverflowTooltip)??!0,isNotDrag:(se==null?void 0:se.isNotDrag)??!1,isEditCol:(se==null?void 0:se.isEditCol)??!1,isOperate:(se==null?void 0:se.isOperate)??!1,id:(se==null?void 0:se.id)??Xe,formMenuSelect:(se==null?void 0:se.formMenuSelect)??void 0,groupSelect:(se==null?void 0:se.groupSelect)??void 0},se)),c.value=(fa=c.value)!=null&&fa.every(se=>Array.isArray(se))?(Ba=c.value)==null?void 0:Ba[0]:c.value,k.value=(Te=k.value)==null?void 0:Te.map((se,Xe)=>se={label:(se==null?void 0:se.label)??"",type:(se==null?void 0:se.type)??"",textColor:(se==null?void 0:se.textColor)??"#000000",id:(se==null?void 0:se.id)??Xe}),W.value=(be=W.value)==null?void 0:be.map((se,Xe)=>se={label:(se==null?void 0:se.label)??"",type:(se==null?void 0:se.type)??"",background:(se==null?void 0:se.background)??"var(--ssComponent-primary-color)",id:(se==null?void 0:se.id)??Xe}),P.value)P.value=(ae=P.value)==null?void 0:ae.map(se=>{w.value++;let Xe=se;return Xe.id=w.value,Xe});else{let se=[];const Xe=(Be=oe.getColumnChild(A.cloneDeep(c.value)))==null?void 0:Be.filter(Ze=>(Ze==null?void 0:Ze.prop)!=="operate");Xe==null||Xe.forEach(Ze=>{var Ha;w.value++,se.push({label:Ze==null?void 0:Ze.label,name:(Ze==null?void 0:Ze.prop)||(Ze==null?void 0:Ze.label),type:Ze!=null&&Ze.groupSelect?"Select":"Input",value:"",id:w.value,contents:Ze==null?void 0:Ze.options,menuSelect:Ze==null?void 0:Ze.formMenuSelect,groupSelect:(Ha=Ze==null?void 0:Ze.groupSelect)==null?void 0:Ha.split(":"),selectRelateType:"关联绑定列"})}),P.value=se}},{deep:!0,immediate:!0}),($,H)=>{const X=e.resolveComponent("svg-icon"),he=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",Sh,[e.createElementVNode("div",Eh,[e.createElementVNode("div",Ch,[H[2]||(H[2]=e.createElementVNode("div",null,e.toDisplayString("表头"),-1)),e.createVNode(he,{class:"icon-content",onClick:Le,id:"themeButton"},{icon:e.withCtx(()=>[e.createVNode(X,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[1]||(H[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",Dh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(fe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",Th,[e.createElementVNode("div",Bh,e.toDisplayString(fe==null?void 0:fe.label),1),e.createElementVNode("div",Nh,[e.createVNode(X,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>ue(fe)},null,8,["onClick"]),e.createVNode(X,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>ce(fe)},null,8,["onClick"]),e.createVNode(X,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>Za(fe)},null,8,["onClick"])])]),fe!=null&&fe.children&&fe.children.length>0?(e.openBlock(),e.createElementBlock("div",Ah,[e.createVNode(Fc,{tableChildContents:fe==null?void 0:fe.children,onDeleteChange:pa,onFixChange:Se},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),128))]),e.createElementVNode("div",zh,[H[4]||(H[4]=e.createElementVNode("div",null,e.toDisplayString("行内按钮"),-1)),e.createVNode(he,{class:"icon-content",id:"themeButton",onClick:ra},{icon:e.withCtx(()=>[e.createVNode(X,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[3]||(H[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",Mh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,(fe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",Ih,[e.createElementVNode("div",Oh,e.toDisplayString(fe==null?void 0:fe.label),1),e.createElementVNode("div",Lh,[e.createVNode(X,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ta=>ge(fe)},null,8,["onClick"]),e.createVNode(X,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>ze(fe)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Rh,[H[6]||(H[6]=e.createElementVNode("div",null,e.toDisplayString("表外按钮"),-1)),e.createVNode(he,{class:"icon-content",id:"themeButton",onClick:V},{icon:e.withCtx(()=>[e.createVNode(X,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[5]||(H[5]=e.createTextVNode(" 新增 "))]),_:1,__:[5]})]),e.createElementVNode("div",$h,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(W.value,(fe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",Vh,[e.createElementVNode("div",Ph,e.toDisplayString(fe==null?void 0:fe.label),1),e.createElementVNode("div",Fh,[e.createVNode(X,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ta=>$e(fe)},null,8,["onClick"]),e.createVNode(X,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>de(fe)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",jh,[H[8]||(H[8]=e.createElementVNode("div",null,e.toDisplayString("表格弹框字段设置"),-1)),e.createVNode(he,{class:"icon-content",id:"themeButton",onClick:ee},{icon:e.withCtx(()=>[e.createVNode(X,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[7]||(H[7]=e.createTextVNode(" 新增 "))]),_:1,__:[7]})]),e.createElementVNode("div",Hh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(P.value,(fe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",Uh,[e.createElementVNode("div",qh,e.toDisplayString(fe==null?void 0:fe.label),1),e.createElementVNode("div",Wh,[e.createVNode(X,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ta=>ne(fe)},null,8,["onClick"]),e.createVNode(X,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>Y(fe)},null,8,["onClick"])])])]))),128))]),H[10]||(H[10]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("分页"))],-1)),e.createElementVNode("div",Kh,[e.createElementVNode("div",Gh,[H[9]||(H[9]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否分页"),-1)),e.createVNode(cl._sfc_main$1,{modelValue:b.value,"onUpdate:modelValue":H[0]||(H[0]=fe=>b.value=fe)},null,8,["modelValue"])])])]),e.createVNode(Ar.ssDialog,{visible:s.value,onBeforeDestroy:Ke,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Yh,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:De},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Jh,[e.createVNode(he,{onClick:Ke,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[11]||(H[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(he,{class:"ok-button button",onClick:ua,id:"themeButton"},{default:e.withCtx(()=>H[12]||(H[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible"]),e.createVNode(Ar.ssDialog,{visible:d.value,onBeforeDestroy:ca,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Xh,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:O.value,key:O.value,isEnableWrap:!0,onChange:Ca},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Zh,[e.createVNode(he,{onClick:ca,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[13]||(H[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(he,{class:"ok-button button",onClick:Q,id:"themeButton"},{default:e.withCtx(()=>H[14]||(H[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible"]),e.createVNode(Ar.ssDialog,{visible:L.value,onBeforeDestroy:U,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Qh,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:_.value,key:_.value,isEnableWrap:!0,onChange:ie},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",e6,[e.createVNode(he,{onClick:U,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[15]||(H[15]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[15]}),e.createVNode(he,{class:"ok-button button",onClick:T,id:"themeButton"},{default:e.withCtx(()=>H[16]||(H[16]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[16]})])]),_:1},8,["visible"]),e.createVNode(Ar.ssDialog,{visible:h.value,onBeforeDestroy:te,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",a6,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:g.value,key:g.value,isEnableWrap:!0,onChange:me,onChangeVisible:J,onBlurChange:_e},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",l6,[e.createVNode(he,{onClick:te,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[17]||(H[17]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[17]}),e.createVNode(he,{class:"ok-button button",onClick:ye,id:"themeButton"},{default:e.withCtx(()=>H[18]||(H[18]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[18]})])]),_:1},8,["visible"])])}}},n6=ar._export_sfc(r6,[["__scopeId","data-v-7a6b87b5"]]),i6=A.useModelComp(A.pinia),{pageMapState:o6}=A.storeToRefs(i6),t6=A.useMenuState(A.pinia),{activeMenuPath:s6}=A.storeToRefs(t6),c6=e.ref(24),u6=e.ref(6),d6=e.ref(10),p6=e.ref(70),f6=e.ref(.18),h6=e.ref(45),v6=(a,l,n,r)=>{var i,s,h,c,d,m,b,u,C,M,k,W,O,j,L,_;return{x:((s=(i=a==null?void 0:a.value)==null?void 0:i.tableData)==null?void 0:s.x)||l%2*12,y:((c=(h=a==null?void 0:a.value)==null?void 0:h.tableData)==null?void 0:c.y)||l,w:((m=(d=a==null?void 0:a.value)==null?void 0:d.tableData)==null?void 0:m.w)||c6.value,h:((u=(b=a==null?void 0:a.value)==null?void 0:b.tableData)==null?void 0:u.h)||n,minW:((M=(C=a==null?void 0:a.value)==null?void 0:C.tableData)==null?void 0:M.minW)||u6.value,minH:((W=(k=a==null?void 0:a.value)==null?void 0:k.tableData)==null?void 0:W.minH)||f6.value,maxH:((j=(O=a==null?void 0:a.value)==null?void 0:O.tableData)==null?void 0:j.maxH)||h6.value,i:((_=(L=a==null?void 0:a.value)==null?void 0:L.tableData)==null?void 0:_.i)||l,id:(a==null?void 0:a.id)||l+"",component:r}},m6=(a,l)=>{var r,i,s,h,c,d,m,b;let n=1;if(a!=null&&a.compData&&Array.isArray(a==null?void 0:a.compData))if(((r=a==null?void 0:a.comp)==null?void 0:r.toUpperCase())==="TABLE"){if(((h=(s=(i=a==null?void 0:a.compData)==null?void 0:i.find(C=>(C==null?void 0:C.key)==="tableContents"))==null?void 0:s.contents)==null?void 0:h.length)===0)return 2}else((c=a==null?void 0:a.comp)==null?void 0:c.toUpperCase())==="FORM"&&(n=((b=(m=(d=a==null?void 0:a.compData)==null?void 0:d.find(C=>(C==null?void 0:C.key)==="formContent"))==null?void 0:m.contents)==null?void 0:b.length)/5);return n*2},jc=(a,l,n)=>{var h,c;const r=(c=(h=o6.value)==null?void 0:h[s6.value])==null?void 0:c.filter(d=>{var m;return((m=d==null?void 0:d.key)==null?void 0:m.type)==="gridLayout"}),i=r==null?void 0:r.find(d=>{var m,b,u;return((u=(b=(m=d==null?void 0:d.value)==null?void 0:m.tableData)==null?void 0:b.component)==null?void 0:u.id)===a.id}),s=m6(a);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((d,m)=>jc(d,m))),{...v6(i,l,s,a)}},y6=(a,l)=>{if((a==null?void 0:a.length)===0)return[];const n=A.cloneDeep(a);return Array.isArray(a)?n==null?void 0:n.map((r,i)=>jc(r,i)):[]},g6=a=>({TABLE:{overall:[{label:"栅格布局",prop:"isGridLayout",type:"switch",value:!1,disabled:!1,activeText:"启用",inactiveText:"默认"},{label:"界面布局",prop:"layout",type:"radio",value:"vertical",options:[{label:"垂直",value:"vertical"},{label:"水平",value:"horizontal"}]},{label:"流程式布局",prop:"isStepLayout",type:"radio",value:!1,options:[{label:"启用",value:!0,disabled:!1},{label:"禁用",value:!1,disabled:!1}]}],alone:[{label:"默认显示序号",prop:"showIndex",type:"radio",value:!1,options:[{label:"是",value:!0},{label:"否",value:!1}]},{label:"浏览视图配置",prop:"viewport",type:"checkbox",value:["read"],options:[{label:"只读视图",value:"read"},{label:"编辑视图",value:"edit"}]},{label:"是否选择迁移",prop:"allowMove",type:"radio",value:!1,options:[{label:"是",value:!0},{label:"否",value:!1}]}]}}),b6=(a,l)=>a==null?void 0:a.map(n=>{for(const r in l)if(r===(n==null?void 0:n.prop))return{...n,value:l[r]};return n}),k6=e.defineComponent({__name:"index",props:{compType:String,comp:Object,target:{type:String,default:"alone"},optionItems:Array},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.ref([]);e.watch(()=>n.compType,c=>{var b;const d=g6(n==null?void 0:n.optionItems),m=c?(b=d[c==null?void 0:c.toUpperCase()])==null?void 0:b[n==null?void 0:n.target]:[];i.value=m==null?void 0:m.map(u=>{for(const[C,M]of Object.entries((n==null?void 0:n.comp)||{}))if((u==null?void 0:u.prop)===C)return{...u,value:M};return u})},{immediate:!0});const s=c=>cl.getComponent(c),h=c=>{var d,m;(c==null?void 0:c.prop)==="layout"&&(c==null?void 0:c.value)==="horizontal"?i.value=(d=i.value)==null?void 0:d.map(b=>{var u;return(b==null?void 0:b.prop)==="isStepLayout"?{...b,options:(u=b==null?void 0:b.options)==null?void 0:u.map(C=>({...C,disabled:!0}))}:(b==null?void 0:b.prop)==="isGridLayout"?{...b,disabled:!0}:b}):i.value=(m=i.value)==null?void 0:m.map(b=>{var u;return(b==null?void 0:b.prop)==="isStepLayout"?{...b,options:(u=b==null?void 0:b.options)==null?void 0:u.map(C=>({...C,disabled:!1}))}:(b==null?void 0:b.prop)==="isGridLayout"?{...b,disabled:!1}:b}),r("change",{target:n==null?void 0:n.target,styleConfigs:i.value,prop:c==null?void 0:c.prop})};return(c,d)=>{const m=e.resolveComponent("el-col"),b=e.resolveComponent("el-row");return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,u=>(e.openBlock(),e.createBlock(b,{class:"style-row",key:u==null?void 0:u.prop},{default:e.withCtx(()=>[e.createVNode(m,{span:6,class:"style-row-title"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(u==null?void 0:u.label)+":",1)]),_:2},1024),e.createVNode(m,{span:18,style:{display:"flex"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(s(u.type)),{modelValue:u.value,"onUpdate:modelValue":C=>u.value=C,content:u==null?void 0:u.options,optionUrl:u==null?void 0:u.optionUrl,disabled:u==null?void 0:u.disabled,activeText:u==null?void 0:u.activeText,inactiveText:u==null?void 0:u.inactiveText,onChange:C=>h(u)},null,40,["modelValue","onUpdate:modelValue","content","optionUrl","disabled","activeText","inactiveText","onChange"]))]),_:2},1024)]),_:2},1024))),128)}}}),x6=ar._export_sfc(k6,[["__scopeId","data-v-6c233914"]]),w6=e.defineComponent({__name:"index",props:{compType:String,activeTabName:String,comp:Object,extendItem:{type:Object,default:{}},target:{type:String,default:"alone"},relatedData:Array},emits:["change","onButtonClick"],setup(a,{emit:l}){const n=a,r=l,i=[{required:!0,message:"输入不能为空",trigger:"blur"}],s=e.ref([]),h=j=>j==null?void 0:j.reduce((L,_)=>(L[_==null?void 0:_.prop]=_==null?void 0:_.rule,L),{}),c=e.computed(()=>({formRules:h(s.value),buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"保存",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]})),d=e.ref([]),m=e.ref(""),b=(j,L,_)=>{var g;let x=[];(n==null?void 0:n.activeTabName)==="任务配置"?(x=[{label:"任务名称",prop:"任务名称",key:"任务名称",value:"",width:1,isFormColHidden:!1},{label:"任务关键词",prop:"任务关键词",key:"任务关键词",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"列名称",value:"列名称",children:j},{label:"按钮名称",value:"按钮名称",children:L}]},{label:"执行任务",prop:"执行任务",key:"执行任务",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"进度设置",value:"进度设置",children:[{label:"计时",value:"计时",children:[{label:"倒计时",value:"倒计时"},{label:"进行时",value:"进行时"}]},{label:"进度条",value:"进度条"}]},{label:"统计",value:"统计",children:[{label:"统计规则",value:"统计规则",children:[{label:"求和",value:"求和"},{label:"自定义",value:"自定义"}]}]}]},{label:"执行动作",prop:"执行动作",key:"执行动作",type:"select",value:[],width:1,isFormColHidden:!1,contents:[{label:"点击时",value:"点击时"},{label:"页面加载时",value:"页面加载时"}]},{label:"执行交互",prop:"执行交互",key:"执行交互",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"界面显示",value:"界面显示",children:[{label:"主页",value:"主页"},{label:"详情页",value:"详情页"}]},{label:"弹窗提示",value:"弹窗提示"},{label:"后台提交",value:"后台提交"}]},{label:"任务状态",prop:"任务状态",key:"任务状态",type:"radio",value:"启动",width:1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],s.value=[{prop:"任务名称",rule:i},{prop:"任务关键词",rule:i},{prop:"执行任务",rule:i},{prop:"执行动作",rule:i},{prop:"执行交互",rule:i}]):(n==null?void 0:n.activeTabName)==="任务关联"&&(x=[{prop:"关联名称",label:"关联名称",key:"关联名称",type:"input",value:"",isTableColHidden:!1,isFormColHidden:!1},{label:"关联形式",prop:"关联形式",key:"关联形式",type:"select",value:"流程式",width:1,isFormColHidden:!1,contents:[{label:"流程式",value:"流程式"}]},{label:"关联任务集合",prop:"关联任务集合",key:"关联任务集合",type:"tag",value:[],width:1,isFormColHidden:!1,contents:(g=n==null?void 0:n.relatedData)==null?void 0:g.map(E=>({label:E==null?void 0:E.任务名称,value:E==null?void 0:E.任务名称}))},{prop:"关联状态",label:"关联状态",key:"关联状态",type:"radio",value:"启动",isTableColHidden:!1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],s.value=[{prop:"关联名称",rule:i},{prop:"关联状态",rule:i},{prop:"关联形式",rule:i},{prop:"关联任务集合",rule:i}]);let w;return _&&(_==null?void 0:_.length)>0?w=[...x,...u(j,L,_)]:w=x,w},u=(j,L,_)=>{const x=[{label:"进度关键词",prop:"进度关键词",key:"进度关键词",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计算法源",prop:"统计算法源",key:"统计算法源",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计是否获取错误集",prop:"统计是否获取错误集",key:"统计是否获取错误集",type:"radio",value:!1,width:2,isFormColHidden:!1,contents:[{label:"是",value:!0},{label:"否",value:!1}]}];return _?x==null?void 0:x.filter(w=>_==null?void 0:_.includes(w==null?void 0:w.prop)):x},C=(j,L)=>{var E,P,V,ee,J,me,_e,z,ne;const _=((J=(ee=(V=(P=(E=n==null?void 0:n.comp)==null?void 0:E.compData)==null?void 0:P.find(Y=>(Y==null?void 0:Y.key)==="header"))==null?void 0:V.contents)==null?void 0:ee.filter(Y=>(Y==null?void 0:Y.label)!=="操作"))==null?void 0:J.map(Y=>({value:Y==null?void 0:Y.prop,label:Y.label})))||[],x=/button/i,w=((ne=(z=(_e=(me=n==null?void 0:n.comp)==null?void 0:me.compData)==null?void 0:_e.filter(Y=>x.test(Y==null?void 0:Y.key)))==null?void 0:z.flatMap(Y=>Y==null?void 0:Y.contents))==null?void 0:ne.map(Y=>({value:Y==null?void 0:Y.label,label:Y.label})))||[],g=b(_,w,j);d.value=L?b6(g,L):g,j&&(j==null?void 0:j.length)>0&&s.value.push(...j==null?void 0:j.map(Y=>({prop:Y,rule:i})))};e.onMounted(()=>{C(null,n==null?void 0:n.extendItem)});const M=j=>{const L=j==null?void 0:j[m.value];if(m.value==="执行任务"){if(!(L!=null&&L.join("/")))return;const _=L==null?void 0:L.join("/");C(_==="统计/统计规则/自定义"?["统计算法源","统计是否获取错误集"]:_==="进度设置/进度条"?["进度关键词"]:null,j)}},k=j=>{r("change",{target:n==null?void 0:n.target,extendConfigs:j})},W=(j,L)=>{m.value=L==null?void 0:L.changeProp,M(j)},O=j=>{r("onButtonClick",j)};return(j,L)=>(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:d.value,key:d.value,isStartJustify:!1,isEnableWrap:!1,formRules:c.value.formRules,buttonValue:c.value.buttonValue,onChange:k,onBlurChange:W,onOnButtonClick:O},null,8,["rowContents","formRules","buttonValue"]))}}),_6=ar._export_sfc(w6,[["__scopeId","data-v-7c660c1f"]]),S6={};function E6(a,l){return null}const C6=ar._export_sfc(S6,[["render",E6]]),D6={class:"form-operate-content"},T6={class:"form-operate-item"},B6={class:"operate-title"},N6={class:"operate-content"},A6={class:"fix-content"},z6={class:"fix-button"},M6={class:"operate-title"},I6={class:"operate-content"},O6={class:"fix-content"},L6={class:"fix-button"},R6={style:{display:"flex","justify-content":"space-between"}},$6={class:"form-content"},V6={class:"dialog-footer"},P6={class:"form-content"},F6={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(!1),s=e.ref([]),h=e.ref([]),c=e.ref(!1),d=e.ref([]),m=e.ref([]),b=e.ref(""),u=e.ref(!1),C=e.ref(0),M=e.ref([]),k=e.ref([]),W=(z,ne)=>{if((ne==null?void 0:ne.type)=="Select"&&(z==null?void 0:z.key)==="selectRelateType"){const Y=ne==null?void 0:ne.optionUrl;return(Y==null?void 0:Y.selectRelateType)||ne[z.key]}if((ne==null?void 0:ne.type)=="Select"&&(z==null?void 0:z.key)==="menuSelect"){const Y=ne==null?void 0:ne.optionUrl;return(Y==null?void 0:Y.menuSelect)||ne[z.key]}if((ne==null?void 0:ne.type)=="Select"&&(z==null?void 0:z.key)==="groupSelect"){const Y=ne==null?void 0:ne.optionUrl;return(Y==null?void 0:Y.groupSelect)||ne[z.key]}if((ne==null?void 0:ne.type)=="Select"&&(z==null?void 0:z.key)==="originalContent")return(ne==null?void 0:ne.value)||ne[z.key];if((ne==null?void 0:ne.type)=="Select"&&(z==null?void 0:z.key)==="multiple"){const Y=ne[z.key];return lc(Y)?Y:z.default}return(z==null?void 0:z.label)==="类型"&&ne[z.key]===""?"Input":(z==null?void 0:z.key)==="isFormColHidden"&&!ne[z.key]?!1:ne[z.key]},O=async z=>{var te,ye,$e,de,T,ie;i.value=!0;let ne=[];const Y=await(($e=(ye=(te=oe.FormContent)==null?void 0:te.find(U=>(U==null?void 0:U.key)===((z==null?void 0:z.type)===""?"Input":z==null?void 0:z.type)))==null?void 0:ye.value)==null?void 0:$e.value)??((T=(de=oe.FormContent)==null?void 0:de.find(U=>(U==null?void 0:U.key)===((z==null?void 0:z.type)===""?"Input":z==null?void 0:z.type)))==null?void 0:T.value);if(Y==null||Y.forEach(U=>{C.value++,ne.push({label:U==null?void 0:U.label,name:U==null?void 0:U.label,type:U.type,prop:U==null?void 0:U.prop,value:W(U,z),id:C.value,contents:U==null?void 0:U.options,width:(z==null?void 0:z.width)??1})}),z!=null&&z.menuSelect&&((ie=z==null?void 0:z.menuSelect)==null?void 0:ie.length)>0){const U=await oe.menuToContentType(z==null?void 0:z.menuSelect);ne=ne==null?void 0:ne.map(ge=>((ge==null?void 0:ge.name)==="组信息选项"&&(ge.contents=U),ge))}b.value=z==null?void 0:z.id,s.value=await oe.selectToBase(oe.formToOptionsContents(ne)),h.value=await oe.selectToBase(oe.formToOptionsContents(ne))},j=z=>{var Y;c.value=!0;let ne=[];(Y=oe.FormButton)==null||Y.forEach(te=>{C.value++,ne.push({label:te==null?void 0:te.label,name:te==null?void 0:te.label,type:te.type,value:(te==null?void 0:te.label)==="类型"&&z[te.key]===""?"normal":z[te.key],id:C.value,contents:te==null?void 0:te.options})}),M.value=ne,k.value=ne,b.value=z==null?void 0:z.id};e.watch(()=>u.value,()=>{var ne,Y;let z=A.cloneDeep(n.originalItemContents);(ne=A.cloneDeep(n.originalItemContents))!=null&&ne.find(te=>(te==null?void 0:te.key)==="enableWrap")?z=(Y=A.cloneDeep(n.originalItemContents))==null?void 0:Y.map(te=>((te==null?void 0:te.key)==="enableWrap"&&(te.contents=!u.value),te)):z.push({key:"enableWrap",contents:!u.value}),r("change",z)},{deep:!0});const L=()=>{var Y,te,ye,$e,de;M.value=k.value;let z={};if(b.value!==""?z.id=b.value:(C.value++,z.id="id"+C.value),(Y=M.value)==null||Y.forEach(T=>{var U;const ie=(U=oe.FormButton)==null?void 0:U.find(ge=>(ge==null?void 0:ge.label)===(T==null?void 0:T.label));ie&&(z[ie.key]=T.value)}),(te=d.value)!=null&&te.find(T=>T.id===z.id))d.value=(ye=d.value)==null?void 0:ye.map(T=>(T.id===z.id&&(T=z),T));else{let T=A.cloneDeep(d.value);d.value||(d.value=[]),T.push(z),d.value=T}c.value=!1,b.value="";let ne=A.cloneDeep(n.originalItemContents);($e=A.cloneDeep(n.originalItemContents))!=null&&$e.find(T=>(T==null?void 0:T.key)==="formButton")?ne=(de=A.cloneDeep(n.originalItemContents))==null?void 0:de.map(T=>((T==null?void 0:T.key)==="formButton"&&(T.contents=d.value),T)):ne.push({key:"formButton",contents:d.value}),r("change",ne)},_=z=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var ne,Y;m.value=(ne=A.cloneDeep(m.value))==null?void 0:ne.filter(te=>(te==null?void 0:te.id)!==(z==null?void 0:z.id)),r("change",(Y=A.cloneDeep(n.originalItemContents))==null?void 0:Y.map(te=>((te==null?void 0:te.key)==="formContent"&&(te.contents=m.value),te))),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=z=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var ne,Y;d.value=(ne=A.cloneDeep(d.value))==null?void 0:ne.filter(te=>(te==null?void 0:te.id)!==(z==null?void 0:z.id)),r("change",(Y=A.cloneDeep(n.originalItemContents))==null?void 0:Y.map(te=>((te==null?void 0:te.key)==="formButton"&&(te.contents=d.value),te))),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},w=()=>{var ne;c.value=!0;let z=[];(ne=oe.FormButton)==null||ne.forEach(Y=>{C.value++,z.push({label:Y==null?void 0:Y.label,name:Y==null?void 0:Y.label,type:Y.type,value:(Y==null?void 0:Y.label)==="类型"?"normal":"",id:C.value,contents:Y==null?void 0:Y.options})}),M.value=z,k.value=z},g=()=>{var ne,Y,te;i.value=!0;let z=[];(te=(Y=(ne=oe.FormContent)==null?void 0:ne.find(ye=>(ye==null?void 0:ye.key)==="Input"))==null?void 0:Y.value)==null||te.forEach(ye=>{C.value++,z.push({label:ye==null?void 0:ye.label,name:ye==null?void 0:ye.label,type:ye.type,value:(ye==null?void 0:ye.label)==="类型"?"Input":"",id:C.value,contents:ye==null?void 0:ye.options})}),s.value=z,h.value=z},E=z=>{let ne=A.cloneDeep(k.value);ne=ne==null?void 0:ne.map(Y=>(Y.value=z==null?void 0:z[Y.name],Y)),k.value=ne},P=z=>{const ne=z.find(ye=>(ye==null?void 0:ye.name)==="类型");if((ne==null?void 0:ne.value)!="Select")return;const Y=z.find(ye=>(ye==null?void 0:ye.name)==="多选"),te=z.find(ye=>(ye==null?void 0:ye.name)==="初始值");Y!=null&&Y.value&&No.isString(te.value)&&(te.value=[te.value]),!(Y!=null&&Y.value)&&!No.isString(te.value)&&(te.value="")},V=async z=>{var ne,Y,te,ye,$e,de,T,ie,U,ge,ze,Le;if((z==null?void 0:z.类型)!==((Y=(ne=h.value)==null?void 0:ne.find(ra=>(ra==null?void 0:ra.label)==="类型"))==null?void 0:Y.value)){let ra=[];const Ca=await(($e=(ye=(te=oe.FormContent)==null?void 0:te.find(Q=>(Q==null?void 0:Q.key)===((z==null?void 0:z.类型)===""?"Input":z==null?void 0:z.类型)))==null?void 0:ye.value)==null?void 0:$e.value)?await((ge=(U=(ie=oe.FormContent)==null?void 0:ie.find(Q=>(Q==null?void 0:Q.key)===((z==null?void 0:z.类型)===""?"Input":z==null?void 0:z.类型)))==null?void 0:U.value)==null?void 0:ge.value):(T=(de=oe.FormContent)==null?void 0:de.find(Q=>(Q==null?void 0:Q.key)===((z==null?void 0:z.类型)===""?"Input":z==null?void 0:z.类型)))==null?void 0:T.value;if(Ca==null||Ca.forEach(Q=>{var ue,pa;C.value++;const ca=Vu(Q==null?void 0:Q.default)?(z==null?void 0:z[Q.label])??Q.value??"":Q==null?void 0:Q.default;ra.push({label:Q==null?void 0:Q.label,name:Q==null?void 0:Q.label,type:Q.type,value:ca,prop:Q==null?void 0:Q.prop,id:C.value,contents:Q==null?void 0:Q.options,width:((pa=(ue=h.value)==null?void 0:ue[0])==null?void 0:pa.width)??1})}),z!=null&&z.菜单选项&&((ze=z==null?void 0:z.菜单选项)==null?void 0:ze.length)>0){const Q=await oe.menuToContentType(z==null?void 0:z.菜单选项);ra=ra==null?void 0:ra.map(ca=>((ca==null?void 0:ca.name)==="组信息选项"&&(ca.contents=Q),ca))}P(ra),h.value=await oe.selectToBase(A.cloneDeep(ra)),s.value=await oe.selectToBase(A.cloneDeep(ra))}else{let ra=A.cloneDeep(h.value);if(ra=ra==null?void 0:ra.map(Ca=>(Ca.value=z==null?void 0:z[Ca.name],Ca)),z!=null&&z.菜单选项&&((Le=z==null?void 0:z.菜单选项)==null?void 0:Le.length)>0){const Ca=await oe.menuToContentType(z==null?void 0:z.菜单选项);ra=ra==null?void 0:ra.map(Q=>((Q==null?void 0:Q.name)==="组信息选项"&&(Q.contents=Ca),Q))}ra=oe.formToOptionsContents(ra),P(ra),h.value=await oe.selectToBase(A.cloneDeep(ra))}},ee=z=>{z||(s.value=h.value)},J=async z=>{await V(z),s.value=h.value},me=Al.debounce(async()=>{var te,ye,$e,de,T,ie,U,ge,ze,Le,ra,Ca;s.value=h.value;let z={};z.width=((ye=(te=s.value)==null?void 0:te[0])==null?void 0:ye.width)??1,b.value!==""?z.id=b.value:(C.value++,z.id="id"+C.value);let ne=await((T=(de=($e=oe.FormContent)==null?void 0:$e.find(Q=>{var ca,ue;return(Q==null?void 0:Q.key)===(((ue=(ca=s.value)==null?void 0:ca.find(pa=>(pa==null?void 0:pa.label)==="类型"))==null?void 0:ue.value)??"label")}))==null?void 0:de.value)==null?void 0:T.value)??((U=(ie=oe.FormContent)==null?void 0:ie.find(Q=>{var ca,ue;return(Q==null?void 0:Q.key)===(((ue=(ca=s.value)==null?void 0:ca.find(pa=>(pa==null?void 0:pa.label)==="类型"))==null?void 0:ue.value)??"label")}))==null?void 0:U.value);if((ge=s.value)==null||ge.forEach(Q=>{const ca=ne==null?void 0:ne.find(ue=>(ue==null?void 0:ue.label)===(Q==null?void 0:Q.label));ca&&(z[ca.key]=Q.value)}),z.width=z.width?z.width:1,z.key=z==null?void 0:z.label,z.isFormColHidden=z==null?void 0:z.isFormColHidden,(ze=m.value)!=null&&ze.find(Q=>Q.id===z.id))m.value=(Le=m.value)==null?void 0:Le.map(Q=>(Q.id===z.id&&(Q=z),Q));else{let Q=A.cloneDeep(m.value);Q.push(z),m.value=Q}m.value=m.value.map(({id:Q,...ca})=>ca),i.value=!1,b.value="";let Y=A.cloneDeep(n.originalItemContents);(ra=A.cloneDeep(n.originalItemContents))!=null&&ra.find(Q=>(Q==null?void 0:Q.key)==="formContent")?Y=(Ca=A.cloneDeep(n.originalItemContents))==null?void 0:Ca.map(Q=>((Q==null?void 0:Q.key)==="formContent"&&(Q.contents=m.value),Q)):Y.push({key:"formContent",contents:m.value}),r("change",Y)},300),_e=()=>{i.value=!1,c.value=!1,b.value="",h.value=[],k.value=[]};return e.watch(()=>n.originalItemContents,()=>{var ne,Y,te,ye,$e,de;if(!n.originalItemContents||n.originalItemContents.length===0)return;const z=A.cloneDeep(n.originalItemContents);m.value=((ne=z==null?void 0:z.find(T=>(T==null?void 0:T.key)==="formContent"))==null?void 0:ne.contents)??[],d.value=((Y=z==null?void 0:z.find(T=>(T==null?void 0:T.key)==="formButton"))==null?void 0:Y.contents)??[],u.value=(te=z==null?void 0:z.find(T=>(T==null?void 0:T.key)==="enableWrap"))!=null&&te.contents?!((ye=z==null?void 0:z.find(T=>(T==null?void 0:T.key)==="enableWrap"))!=null&&ye.contents):!0,m.value=($e=A.cloneDeep(m.value))==null?void 0:$e.map((T,ie)=>{var ge;let U=T;return U.id=(T==null?void 0:T.id)??ie,T!=null&&T.label||(T.label=(T==null?void 0:T.key)??(T==null?void 0:T.label)??""),T!=null&&T.type||(T.type=(T==null?void 0:T.type)??""),T.contents=((ge=T==null?void 0:T.options)==null?void 0:ge.length)===0?(T==null?void 0:T.contents)??"":T==null?void 0:T.options,U}),m.value=oe.formToOptionsContents(m.value),d.value=(de=d.value)==null?void 0:de.map((T,ie)=>T={label:(T==null?void 0:T.label)??"",type:(T==null?void 0:T.type)??"",background:(T==null?void 0:T.background)??"var(--ssComponent-primary-color)",id:ie})},{deep:!0,immediate:!0}),(z,ne)=>{const Y=e.resolveComponent("svg-icon"),te=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",D6,[e.createElementVNode("div",T6,[e.createElementVNode("div",B6,[ne[2]||(ne[2]=e.createElementVNode("div",null,e.toDisplayString("表单内容"),-1)),e.createVNode(te,{class:"icon-content",id:"themeButton",onClick:g},{icon:e.withCtx(()=>[e.createVNode(Y,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[ne[1]||(ne[1]=e.createElementVNode("div",null,e.toDisplayString("新增"),-1))]),_:1,__:[1]})]),e.createElementVNode("div",N6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(ye,$e)=>(e.openBlock(),e.createElementBlock("div",{key:$e},[e.createElementVNode("div",A6,[e.createElementVNode("div",null,e.toDisplayString(ye.label),1),e.createElementVNode("div",z6,[e.createVNode(Y,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:de=>O(ye)},null,8,["onClick"]),e.createVNode(Y,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:de=>_(ye)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",M6,[ne[4]||(ne[4]=e.createElementVNode("div",null,e.toDisplayString("表单按钮"),-1)),e.createVNode(te,{class:"icon-content",id:"themeButton",onClick:w},{icon:e.withCtx(()=>[e.createVNode(Y,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[ne[3]||(ne[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",I6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(ye,$e)=>(e.openBlock(),e.createElementBlock("div",{key:$e},[e.createElementVNode("div",O6,[e.createElementVNode("div",null,e.toDisplayString(ye.label),1),e.createElementVNode("div",L6,[e.createVNode(Y,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:de=>j(ye)},null,8,["onClick"]),e.createVNode(Y,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:de=>x(ye)},null,8,["onClick"])])])]))),128))]),ne[6]||(ne[6]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("表单布局"))],-1)),e.createElementVNode("div",R6,[ne[5]||(ne[5]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否自动撑宽"),-1)),e.createVNode(cl._sfc_main$1,{modelValue:u.value,"onUpdate:modelValue":ne[0]||(ne[0]=ye=>u.value=ye)},null,8,["modelValue"])])]),e.createVNode(Ar.ssDialog,{visible:i.value,onBeforeDestroy:_e,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",$6,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!0,onChange:V,onChangeVisible:ee,onBlurChange:J},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",V6,[e.createVNode(te,{onClick:_e,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>ne[7]||(ne[7]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[7]}),e.createVNode(te,{class:"ok-button button",onClick:e.unref(me),id:"themeButton"},{default:e.withCtx(()=>ne[8]||(ne[8]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[8]},8,["onClick"])])]),_:1},8,["visible"]),e.createVNode(Ar.ssDialog,{visible:c.value,onBeforeDestroy:_e,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",P6,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:M.value,key:M.value,isEnableWrap:!0,onChange:E},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:_e,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:L},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},Ds=ar._export_sfc(F6,[["__scopeId","data-v-20850524"]]),j6={class:"step-module content"},H6={class:"module-data"},U6={class:"step-module layout"},q6={class:"form-content"},W6=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.ref([{label:"方向:",prop:"direction",type:"RADIO",contents:[{label:"水平",value:"horizontal"},{label:"垂直",value:"vertical"}],value:"horizontal"},{label:"是否居中:",prop:"alignCenter",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0},{label:"应用简洁风格",prop:"simple",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!1}]),s=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"标题",prop:"title",type:"input",value:""},{label:"描述",prop:"description",type:"input",value:""}]),h=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),c=e.reactive({visible:!1,width:"40%",title:"步骤条"}),d=e.ref("create"),m=e.ref({}),b=e.ref([]),u=O=>{var j;m.value=O,r("change",(j=k())==null?void 0:j.compData)},C=(O,j)=>{var L,_;switch(O){case"create":(L=s.value)==null||L.forEach(x=>{x.value=""}),d.value="create",c.visible=!0;break;case"update":(_=s.value)==null||_.forEach(x=>{x.value=j[x==null?void 0:x.prop]}),d.value="update",c.visible=!0;break;case"delete":b.value.splice(j,1),d.value="delete";break}},M=O=>{var j,L,_;if((O==null?void 0:O.buttonName)==="确认"){const x=A.cloneDeep(O==null?void 0:O.content);switch(Object.keys(x).forEach(w=>{x[w]===""&&delete x[w]}),d.value){case"create":b.value.push({...x,index:((j=b.value)==null?void 0:j.length)+1});break;case"update":b.value=(L=b.value)==null?void 0:L.map(w=>w.index===(x==null?void 0:x.index)?{...w,title:x==null?void 0:x.title,description:x==null?void 0:x.description}:w);break}r("change",(_=k())==null?void 0:_.compData),c.visible=!1}else c.visible=!1},k=()=>({comp:"Step",compData:[{key:"stepList",contents:b.value},{key:"stepConfig",contents:m.value}]}),W=()=>{c.visible=!1};return e.watch(()=>n==null?void 0:n.itemContents,O=>{var j,L;O&&(m.value=((j=O==null?void 0:O.find(_=>_.key==="stepConfig"))==null?void 0:j.contents)??{},b.value=((L=O==null?void 0:O.find(_=>_.key==="stepList"))==null?void 0:L.contents)??[])},{immediate:!0}),(O,j)=>{const L=e.resolveComponent("svg-icon"),_=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",j6,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(_,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=x=>C("create"))},{icon:e.withCtx(()=>[e.createVNode(L,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",H6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(x,w)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:w},[e.createElementVNode("span",null,e.toDisplayString(x==null?void 0:x.title),1),e.createElementVNode("div",null,[e.createVNode(_,{type:"primary",size:"small",onClick:g=>C("update",{...x,index:w+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(_,{type:"danger",size:"small",onClick:g=>C("delete",w)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",U6,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(cl.ssForm,{rowContents:i.value,onChange:u},null,8,["rowContents"])])]),e.createVNode(Ar.ssDialog,{visible:c.visible,title:c.title,onBeforeDestroy:W,width:c.width},{default:e.withCtx(()=>[e.createElementVNode("div",q6,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:h.value,onOnButtonClick:M},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),K6=ar._export_sfc(W6,[["__scopeId","data-v-7dbd17f2"]]),G6={class:"step-module content"},Y6={class:"module-data"},J6={class:"step-module layout"},X6={class:"form-content"},Z6=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.ref("create"),s=e.ref({}),h=e.ref([]),c=e.ref([{label:"方向:",prop:"placement",type:"radio",contents:[{label:"底部",value:"bottom"},{label:"顶部",value:"top"}],value:"bottom"},{label:"节点类型:",prop:"type",type:"select",contents:[{label:"primary",value:"primary"},{label:"success",value:"success"},{label:"warning",value:"warning"},{label:"danger",value:"danger"},{label:"info",value:"info"}],value:"primary"},{label:"颜色:",prop:"color",type:"color",value:""},{label:"尺寸:",prop:"size",type:"radio",contents:[{label:"normal",value:"normal"},{label:"large",value:"large"}],value:"normal"},{label:"是否空心",prop:"isHollow",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0},{label:"是否居中",prop:"isCenter",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0}]),d=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"内容",prop:"content",type:"input",value:""},{label:"时间戳",prop:"timestamp",type:"datetime",value:""}]),m=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),b=e.reactive({visible:!1,width:"40%",title:"时间线"}),u=O=>{var j;s.value=O,r("change",(j=k())==null?void 0:j.compData)},C=(O,j)=>{var L,_;switch(O){case"create":(L=d.value)==null||L.forEach(x=>{x.value=""}),i.value="create",b.visible=!0;break;case"update":(_=d.value)==null||_.forEach(x=>{x.value=j[x==null?void 0:x.prop]}),i.value="update",b.visible=!0;break;case"delete":h.value.splice(j,1),i.value="delete";break}},M=O=>{var j,L,_,x;if((O==null?void 0:O.buttonName)==="确认"){const w=A.cloneDeep(O==null?void 0:O.content);switch(Object.keys(w).forEach(g=>{w[g]===""&&delete w[g]}),i.value){case"create":(L=h.value)==null||L.push({...w,index:((j=h.value)==null?void 0:j.length)+1});break;case"update":h.value=(_=h.value)==null?void 0:_.map(g=>g.index===(w==null?void 0:w.index)?{...g,content:w==null?void 0:w.content,timestamp:w==null?void 0:w.timestamp}:g);break}r("change",(x=k())==null?void 0:x.compData),b.visible=!1}else b.visible=!1},k=()=>({comp:"TimeLine",compData:[{key:"timeLineList",contents:h.value},{key:"timeLineConfig",contents:s.value}]}),W=()=>{b.visible=!1};return e.watch(()=>n==null?void 0:n.itemContents,O=>{var j,L;O&&(s.value=((j=O==null?void 0:O.find(_=>_.key==="timeLineConfig"))==null?void 0:j.contents)??{},h.value=((L=O==null?void 0:O.find(_=>_.key==="timeLineList"))==null?void 0:L.contents)??[])},{immediate:!0}),(O,j)=>{const L=e.resolveComponent("svg-icon"),_=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",G6,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(_,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=x=>C("create"))},{icon:e.withCtx(()=>[e.createVNode(L,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",Y6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(x,w)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:w},[e.createElementVNode("span",null,e.toDisplayString(x==null?void 0:x.content),1),e.createElementVNode("div",null,[e.createVNode(_,{type:"primary",size:"small",onClick:g=>C("update",{...x,index:w+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(_,{type:"danger",size:"small",onClick:g=>C("delete",w)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",J6,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(cl.ssForm,{rowContents:c.value,onChange:u},null,8,["rowContents"])])]),e.createVNode(Ar.ssDialog,{visible:b.visible,title:b.title,onBeforeDestroy:W,width:b.width},{default:e.withCtx(()=>[e.createElementVNode("div",X6,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:d.value,key:d.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:m.value,onOnButtonClick:M},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),Q6=ar._export_sfc(Z6,[["__scopeId","data-v-39ffc861"]]),e4={};function a4(a,l){return e.openBlock(),e.createElementBlock("div")}const l4=ar._export_sfc(e4,[["render",a4]]),r4={class:"extra-content"},n4={key:0},i4={key:1},o4={class:"dialog-footer"},t4={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},emits:["change"],setup(a,{emit:l}){const n=a,r=e.ref(0),i=e.ref(),s=e.ref(),h=l,c=e.ref(!1),d=e.ref({}),m=e.ref({}),b=e.ref();e.watch(()=>[n.itemData],()=>{var x;const _=A.cloneDeep(n.itemData);i.value=(x=A.cloneDeep(_))==null?void 0:x.map(w=>{var g;if(w.key==="extra"){let E=[];(g=w.value)==null||g.forEach(P=>{var V;E.push((V=Object.values(P))==null?void 0:V[0])}),w.value=E}return w})},{deep:!0,immediate:!0});const u=(_,x,w,g)=>{var P;let E={};((P=_==null?void 0:_[0])==null?void 0:P.contents)==="详情"&&(c.value=!0,E[x]=_,s.value=_==null?void 0:_.filter(V=>(V==null?void 0:V.key)!=="tableContentName"),d.value=E,m.value=w,b.value=g.id)},C=_=>{var V,ee,J,me;const x=(ee=(V=Object.values(A.cloneDeep(d.value)))==null?void 0:V[0])==null?void 0:ee.filter(_e=>(_e==null?void 0:_e.key)==="tableContentName"),w=(me=(J=Object.values(A.cloneDeep(d.value)))==null?void 0:J[0])==null?void 0:me.filter(_e=>(_e==null?void 0:_e.key)!=="tableContentName"),g=w==null?void 0:w.map((_e,z)=>{var ne;return z===_.index&&(_e==null?void 0:_e.comp)==="Table"&&(_e.compData=(ne=_e.compData)==null?void 0:ne.map(Y=>{var te,ye;return(Y==null?void 0:Y.key)==="tableContents"&&(Y.contents=(ye=(te=_.content)==null?void 0:te.map($e=>{let de={};for(let T in $e)T!=="id"&&(de[T]=$e[T]);return de}))==null?void 0:ye.map($e=>Object.values($e))),Y})),_e});g.unshift(x==null?void 0:x[0]);let E=A.cloneDeep(d.value),P={};for(let _e in E)P[_e]=g;d.value=P},M=()=>{c.value=!1,d.value={},m.value={},b.value=void 0,r.value++},k=_=>{var V,ee,J,me;const x=(ee=(V=Object.values(A.cloneDeep(d.value)))==null?void 0:V[0])==null?void 0:ee.filter(_e=>(_e==null?void 0:_e.key)==="tableContentName"),w=(me=(J=Object.values(A.cloneDeep(d.value)))==null?void 0:J[0])==null?void 0:me.filter(_e=>(_e==null?void 0:_e.key)!=="tableContentName"),g=w==null?void 0:w.map((_e,z)=>(z===_.index&&(_e.compData=_.contents),_e));g.unshift(x==null?void 0:x[0]);let E=A.cloneDeep(d.value),P={};for(let _e in E)P[_e]=g;d.value=P},W=()=>{var x,w;let _={};for(let g in m.value)g===((x=Object.keys(d.value))==null?void 0:x[0])?_[g]=(w=Object.values(d.value))==null?void 0:w[0]:_[g]=m.value[g];h("change",{buttonName:"编辑",index:b.value,singleContent:_},"methodData"),c.value=!1,d.value={},m.value={},b.value=void 0},O=()=>{c.value=!1,d.value={},m.value={},b.value=void 0},j=_=>{h("change",_,"methodData")},L=_=>zi(_);return(_,x)=>{const w=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",r4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(g,E)=>(e.openBlock(),e.createElementBlock("div",{key:r.value},[(g==null?void 0:g.key)==="extra"?(e.openBlock(),e.createElementBlock("div",n4)):(e.openBlock(),e.createElementBlock("div",i4,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(L(g.comp)),{itemData:g==null?void 0:g.compData,childItemData:g==null?void 0:g.itemChildData,key:E,index:(g==null?void 0:g.id)??E,onContentClick:u,onChange:j},null,40,["itemData","childItemData","index"]))]))]))),128)),e.createVNode(Ar.ssDialog,{visible:c.value,onBeforeDestroy:O},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(g,E)=>(e.openBlock(),e.createElementBlock("div",{key:E,class:"extra-dialog"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(L(g.comp)),{itemData:g==null?void 0:g.compData,onChange:C,childItemData:g==null?void 0:g.itemChildData,key:E,onContentChange:k,index:(g==null?void 0:g.id)??E,class:"extra-component"},null,40,["itemData","childItemData","index"]))]))),128))]),footer:e.withCtx(()=>[e.createElementVNode("div",o4,[e.createVNode(w,{class:"cancel-button footer-button",onClick:M,id:"themeBorderButton"},{default:e.withCtx(()=>x[0]||(x[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(w,{class:"confirm-button footer-button",onClick:W,id:"themeButton"},{default:e.withCtx(()=>x[1]||(x[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},s4=ar._export_sfc(t4,[["__scopeId","data-v-2d9c5ab2"]]),c4={key:0,class:"method-content"},u4={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},setup(a){const l=e.ref([]),n=oe.useOriginalState(A.pinia),{originalPath:r}=A.storeToRefs(n),i=a,s=e.ref(!1),h=e.ref(),c=oe.useTableComp(A.pinia),{multipleTableConst:d}=A.storeToRefs(c),m=A.useModelComp(A.pinia),b=e.ref(!1),u=A.useMenuState(A.pinia),C=A.useLoginState(A.pinia),{itemData:M,isEdit:k,routeToChildPath:W,tableViewContents:O,lockingPage:j,payloadTypes:L}=A.storeToRefs(m),{activeMenuPath:_,platform:x,childMenu:w}=A.storeToRefs(u),{loginUserInfo:g}=A.storeToRefs(C),E=e.ref(!1),P=async()=>{var de,T;(de=l.value)!=null&&de.find(ie=>(ie==null?void 0:ie.buttonName)==="保存")&&await Y((T=l.value)==null?void 0:T.find(ie=>(ie==null?void 0:ie.buttonName)==="保存")),await oe.onSaveBack()};e.watch(()=>M.value,async()=>{k.value==="view"&&!E.value&&await $e(A.cloneDeep(i.itemData)),E.value=!1},{deep:!0});const V=()=>{s.value=!1,h.value=void 0},ee=de=>de.map(T=>{const ie={};for(const U in T){const ge=T[U];if(U.includes(d.value)){const ze=U.split(d.value);let Le=ie;ze.forEach((ra,Ca)=>{Ca===ze.length-1?Le[ra]=ge:(Le[ra]||(Le[ra]={}),Le=Le[ra])})}else ie[U]=ge}return ie}),J=async(de,T,ie=[])=>{var ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za;let U=(ge=A.cloneDeep(T))==null?void 0:ge.filter($=>($==null?void 0:$.comp)!=="methodButton");if(de!=null&&de.includes("[")){let $=(Q=(Ca=(ra=(Le=(ze=A.cloneDeep(de))==null?void 0:ze.split("["))==null?void 0:Le[1])==null?void 0:ra.split("]"))==null?void 0:Ca[0])==null?void 0:Q.split(":"),H="";if($!=null&&$[0]){let X=(ca=U==null?void 0:U.find(he=>(he==null?void 0:he.name)===($==null?void 0:$[0])))==null?void 0:ca.compData;if(!X){let he=(ue=de==null?void 0:de.split("["))==null?void 0:ue[0],fe=await oe.getItemData(he,sessionStorage.getItem("systemKey"),"",!1,"","",ie);X=(pa=fe==null?void 0:fe.find(ha=>(ha==null?void 0:ha.name)===($==null?void 0:$[0])))==null?void 0:pa.compData}X==null||X.forEach(he=>{var fe,ha,ta,Fe,xa,Ae;if((he==null?void 0:he.key)==="formContent")(fe=he==null?void 0:he.contents)==null||fe.forEach(va=>{var La;(va==null?void 0:va.key)===($==null?void 0:$[1])&&(Array.isArray(va==null?void 0:va.value)?H=va==null?void 0:va.value:H=(La=va==null?void 0:va.value)==null?void 0:La.toString())});else if((he==null?void 0:he.key)==="tableContents"){let va=[],La=(ha=X==null?void 0:X.find(fa=>(fa==null?void 0:fa.key)==="header"))==null?void 0:ha.contents,Ia=($==null?void 0:$[1])??"";if(La!=null&&La.every(fa=>Array.isArray(fa))){let fa=oe.getColumnChild((xa=La==null?void 0:La[0])==null?void 0:xa.filter(Ba=>(Ba==null?void 0:Ba.label)!=="操作"));(Ae=he.contents)==null||Ae.forEach(Ba=>{let Te={};Ba=Ba==null?void 0:Ba.filter(be=>!(be!=null&&be.id)),fa==null||fa.forEach((be,Be)=>{let ae=Ba[Be];typeof Ba[Be]=="number"&&(ae=Ba[Be].toString()),(Ia===""||Ia===be.prop)&&(Te[be.prop]=ae)}),va.push(Te)}),va=ee(va)}else{let fa=(ta=La==null?void 0:La.map(Ba=>Ba==null?void 0:Ba.label))==null?void 0:ta.filter(Ba=>Ba!=="操作");(Fe=he.contents)==null||Fe.forEach(Ba=>{let Te={};Ba=Ba==null?void 0:Ba.filter(be=>!(be!=null&&be.id)),fa==null||fa.forEach((be,Be)=>{let ae=Ba[Be];typeof Ba[Be]=="number"&&(ae=Ba[Be].toString()),(Ia===""||Ia===be)&&(Te[be]=ae)}),va.push(Te)})}H=va}})}return H}else if(de!=null&&de.includes("/")){let $={};return(Se=A.cloneDeep(U))==null||Se.forEach((H,X)=>{var he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae,se,Xe,Ze;if((H==null?void 0:H.comp)==="Table"){let Ha=Array.isArray((ha=(fe=(he=H==null?void 0:H.compData)==null?void 0:he.find(Re=>(Re==null?void 0:Re.key)==="header"))==null?void 0:fe.contents)==null?void 0:ha[0])?(Ae=(xa=(Fe=(ta=H==null?void 0:H.compData)==null?void 0:ta.find(Re=>(Re==null?void 0:Re.key)==="header"))==null?void 0:Fe.contents)==null?void 0:xa[0])==null?void 0:Ae.some(Re=>Re==null?void 0:Re.children):[],_a=(Ia=(La=(va=H==null?void 0:H.compData)==null?void 0:va.find(Re=>(Re==null?void 0:Re.key)==="tableContents"))==null?void 0:La.contents)==null?void 0:Ia.map(Re=>(Re!=null&&Re.find(Ue=>Ue==null?void 0:Ue.id)&&(Re=Re.slice(1)),Re)),Qa=(Be=(be=(Te=(Ba=(fa=H==null?void 0:H.compData)==null?void 0:fa.find(Re=>(Re==null?void 0:Re.key)==="header"))==null?void 0:Ba.contents)==null?void 0:Te[0])==null?void 0:be[0])==null?void 0:Be.label,Pe=(se=(ae=H==null?void 0:H.compData)==null?void 0:ae.find(Re=>(Re==null?void 0:Re.key)==="header"))==null?void 0:se.contents;if(Ha)(Ha==null?void 0:Ha.length)===0?$[H.name]=$!=null&&$[H.name]?$[H.name]:oe.tableToForm(_a,Pe):$[Qa]=oe.tableToForm(_a,Pe);else{const Re=[];Pe=Pe.slice(1,Pe.length-1),Pe==null||Pe.forEach((Ue,Ne)=>{_a==null||_a.forEach(Ie=>{Re.push({key:Ue.label+Ie[0],value:Ie[Ne+1]})})}),$["form"+X]=Re}}else{const Ha=(Ze=(Xe=H.compData)==null?void 0:Xe.find(Qa=>(Qa==null?void 0:Qa.key)==="formContent"))==null?void 0:Ze.contents;$!=null&&$.form||($.form=[]);const _a=[];Ha==null||Ha.forEach(Qa=>{Qa.key!==""&&(Qa={key:(Qa==null?void 0:Qa.key)??(Qa==null?void 0:Qa.label),value:Qa==null?void 0:Qa.value},_a.push(Qa))}),$.form=[..._a,...A.cloneDeep($==null?void 0:$.form)]}}),$}else{if(de==="createInsofDataApi"){let $=(ce=A.cloneDeep(T))==null?void 0:ce[0];return $={comp:(De=A.cloneDeep($))==null?void 0:De.comp,compData:(Ke=A.cloneDeep($))==null?void 0:Ke.compData,name:(ua=A.cloneDeep($))==null?void 0:ua.name,isShow:(Za=A.cloneDeep($))==null?void 0:Za.isShow},{key:{type:"structure",systemKey:sessionStorage.getItem("systemKey"),parentTable:"",pageKey:_.value},value:{pageData:$}}}return de}},me=async(de,T,ie)=>{var ze,Le,ra;let U=await oe.getItemData(T,sessionStorage.getItem("systemKey"),""),ge=U==null?void 0:U.find(Ca=>(Ca==null?void 0:Ca.name)===(ie==null?void 0:ie[0]));if(ge){if((ge==null?void 0:ge.comp)==="Table"){let Ca={};for(let De in A.cloneDeep(de))A.cloneDeep(de)[De]!=="loginUser"?Ca[De]=A.cloneDeep(de)[De]:Ca[De]=((ze=g.value)==null?void 0:ze.account)||((Le=g.value)==null?void 0:Le.账号);let Q=[],ca=Ca;Array.isArray(de)||(ca=[Ca]),ca==null||ca.forEach(De=>{Q.push({[De[ie[1]]]:De})});let ue=[],pa=Q==null?void 0:Q.map(De=>{var Ke;return(Ke=Object.keys(De))==null?void 0:Ke[0]});U==null||U.forEach(De=>{var Ke;(De==null?void 0:De.name)===(ie==null?void 0:ie[0])&&((Ke=De==null?void 0:De.compData)==null||Ke.forEach(ua=>{var Za;(ua==null?void 0:ua.key)==="tableContents"&&((Za=ua==null?void 0:ua.contents)==null||Za.forEach($=>{$!=null&&$.some(H=>pa.includes(H))&&ue.push({[$.find(H=>H.id).id]:$.find(H=>pa.includes(H))})}))}))});let Se=ue==null?void 0:ue.map(De=>{var Ke;return(Ke=Object.keys(De))==null?void 0:Ke[0]}),ce=[];if(Se==null||Se.forEach(De=>{var Za;let Ke=(Za=ue==null?void 0:ue.find($=>{var H;return((H=Object.keys($))==null?void 0:H[0].toString())===De.toString()}))==null?void 0:Za[De],ua=Q==null?void 0:Q.find($=>{var H;return((H=Object.keys($))==null?void 0:H[0])===Ke});ce.push({id:parseInt(De),value:{tableData:ua[Ke]}})}),(ce==null?void 0:ce.length)>0)return ce}else if((ge==null?void 0:ge.comp)==="Form"){let Ca=A.cloneDeep(ge);Ca.compData=(ra=Ca.compData)==null?void 0:ra.map(ue=>{var pa;return(ue==null?void 0:ue.key)==="formContent"&&(ue.contents=(pa=ue.contents)==null?void 0:pa.map(Se=>((Se==null?void 0:Se.key)===(ie==null?void 0:ie[1])&&(Se.value=(de==null?void 0:de[Se==null?void 0:Se.prop])||de),Se))),ue});let Q={};for(let ue in Ca)ue!=="id"&&(Q[ue]=Ca[ue]);let ca=[];if(ca.push({id:ge==null?void 0:ge.id,keyType:ie==null?void 0:ie[1],value:{pageData:Q}}),(ca==null?void 0:ca.length)>0)return ca}}},_e=async(de,T,ie)=>{var ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce;let U=await oe.getItemData(T,sessionStorage.getItem("systemKey"),""),ge=U==null?void 0:U.find(De=>(De==null?void 0:De.name)===(ie==null?void 0:ie[0]));if(ge){if((ge==null?void 0:ge.comp)==="Table"){let De={};for(let Ke in A.cloneDeep(de))A.cloneDeep(de)[Ke]!=="loginUser"?De[Ke]=A.cloneDeep(de)[Ke]:De[Ke]=((ze=g.value)==null?void 0:ze.account)||((Le=g.value)==null?void 0:Le.账号);await Rr.createInsofDataApi({key:{type:"data",pageKey:T,tableId:ge==null?void 0:ge.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:De}})}else if((ge==null?void 0:ge.comp)==="Form"){let De=A.cloneDeep(ge),Ke=Object.keys(de),ua="";(Ca=(ra=A.cloneDeep(De))==null?void 0:ra.compData)==null||Ca.forEach(fe=>{var ha,ta;(fe==null?void 0:fe.key)==="formContent"&&((ta=(ha=A.cloneDeep(fe))==null?void 0:ha.contents)==null||ta.forEach(Fe=>{var xa;Ke.includes(Fe==null?void 0:Fe.key)&&(Fe==null?void 0:Fe.value)===((xa=g.value)==null?void 0:xa.姓名)&&(ua=Fe==null?void 0:Fe.key)}))});let Za=[];(Q=Object.values(de[ua]))==null||Q.forEach(fe=>{fe!=null&&fe.includes("(")&&Za.push(fe)}),Za=[...new Set(Za)];const $=Za==null?void 0:Za.map(async fe=>{var Ae,va,La,Ia,fa,Ba,Te,be,Be,ae,se,Xe;let ha="";(Ba=(fa=(Ia=(La=(va=(Ae=A.cloneDeep(fe))==null?void 0:Ae.split("("))==null?void 0:va[1])==null?void 0:La.split(")"))==null?void 0:Ia[0])==null?void 0:fa.split(":"))==null||Ba.forEach(Ze=>{ha=ha===""?ha+Ze.replaceAll("'",""):ha+"/"+Ze.replaceAll("'","")});let ta=[];(Xe=(se=(ae=(Be=(be=(Te=A.cloneDeep(fe))==null?void 0:Te.split("<"))==null?void 0:be[1])==null?void 0:Be.split(">"))==null?void 0:ae[0])==null?void 0:se.split(":"))==null||Xe.forEach(Ze=>{ta.push(Ze.replaceAll("'",""))});const Fe=await oe.getItemData(ha,sessionStorage.getItem("systemKey"),"");let xa="";return Fe==null||Fe.forEach(Ze=>{var Ha;Ze.name===(ta==null?void 0:ta[0])&&((Ha=Ze==null?void 0:Ze.compData)==null||Ha.forEach(_a=>{var Qa;(_a==null?void 0:_a.key)==="formContent"&&((Qa=_a.contents)==null||Qa.forEach(Pe=>{(Pe==null?void 0:Pe.key)===(ta==null?void 0:ta[1])&&(xa=Pe==null?void 0:Pe.value)}))}))}),{[fe]:xa}}),H=await Promise.all($);De.compData=(ue=(ca=A.cloneDeep(De))==null?void 0:ca.compData)==null?void 0:ue.map(fe=>{var ha,ta;return(fe==null?void 0:fe.key)==="formContent"&&(fe.contents=(ta=(ha=A.cloneDeep(fe))==null?void 0:ha.contents)==null?void 0:ta.map(Fe=>{var xa,Ae,va,La;return(xa=de[ua])!=null&&xa[Fe==null?void 0:Fe.key]&&(de[ua][Fe==null?void 0:Fe.key].includes("(")?Fe.value=(Ae=H==null?void 0:H.find(Ia=>{var fa;return((fa=Object.keys(Ia))==null?void 0:fa[0])===de[ua][Fe==null?void 0:Fe.key]}))==null?void 0:Ae[de[ua][Fe==null?void 0:Fe.key]]:Fe.value=(La=(va=A.cloneDeep(de))==null?void 0:va[ua])==null?void 0:La[Fe==null?void 0:Fe.key]),Fe})),fe});const X=await Rr.getInsofDataApi({key:{type:"structure",pageKey:T,systemKey:sessionStorage.getItem("systemKey")}});let he="";((pa=X==null?void 0:X.data)==null?void 0:pa.type)==="success"&&((ce=(Se=X==null?void 0:X.data)==null?void 0:Se.result)==null||ce.forEach(fe=>{var ha,ta;((ta=(ha=fe==null?void 0:fe.value)==null?void 0:ha.pageData)==null?void 0:ta.name)===(ie==null?void 0:ie[0])&&(he=fe.id)}),await Rr.updateInsofDataApi({id:he,value:{pageData:De}}))}}},z=(de,T="",ie={})=>{for(const[U,ge]of Object.entries(de)){const ze=T?`${T}.${U}`:U;ge!==null&&typeof ge=="object"&&!Array.isArray(ge)&&Object.prototype.toString.call(ge)!=="[object Date]"?z(ge,ze,ie):ie[ze]=ge}return ie},ne=async(de,T,ie,U)=>{var Le,ra,Ca,Q,ca,ue,pa,Se,ce,De,Ke,ua,Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La;let ge=await oe.getItemData(T,sessionStorage.getItem("systemKey"),""),ze=ge==null?void 0:ge.find(Ia=>(Ia==null?void 0:Ia.name)===(ie==null?void 0:ie[0]));if(ze){if(!(ie!=null&&ie[1])&&(ze==null?void 0:ze.comp)==="Table"){let Ia={},fa=[],Ba=(ra=(Le=ze==null?void 0:ze.compData)==null?void 0:Le.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:ra.contents;Ba!=null&&Ba.every(Be=>Array.isArray(Be))?fa=(Q=oe.getColumnChild((Ca=Ba==null?void 0:Ba[0])==null?void 0:Ca.filter(Be=>(Be==null?void 0:Be.label)!=="操作")))==null?void 0:Q.map(Be=>Be==null?void 0:Be.prop):fa=Ba==null?void 0:Ba.map(Be=>Be==null?void 0:Be.label);for(let Be in A.cloneDeep(de))if(A.cloneDeep(de)[Be]!=="loginUser"){let ae=z(A.cloneDeep(de)[Be]),se={};for(let Xe in ae)if(fa!=null&&fa.find(Ze=>Ze===Xe))se[Xe]=ae[Xe];else if(fa!=null&&fa.find(Ze=>(Ze==null?void 0:Ze.toUpperCase())===(Xe==null?void 0:Xe.toUpperCase()))){let Ze=fa==null?void 0:fa.find(Ha=>(Ha==null?void 0:Ha.toUpperCase())===(Xe==null?void 0:Xe.toUpperCase()));se[Ze]=ae[Xe]}Ia[Be]=se}else Ia[Be]=((ca=g.value)==null?void 0:ca.account)||((ue=g.value)==null?void 0:ue.账号);let Te=await Rr.getInsofDataApi({keyLikes:{tableId:ze==null?void 0:ze.id}});if(((Se=(pa=Te==null?void 0:Te.data)==null?void 0:pa.result)==null?void 0:Se.length)>0){let Be=(De=(ce=Te==null?void 0:Te.data)==null?void 0:ce.result)==null?void 0:De.map(ae=>ae==null?void 0:ae.id);(Be==null?void 0:Be.length)>0&&await Rr.batchDeleteInsofDataApi({ids:Be})}let be=[];if((Ke=ze==null?void 0:ze.compData)!=null&&Ke.find(Be=>(Be==null?void 0:Be.key)==="pageColumn")&&(($=(Za=(ua=ze==null?void 0:ze.compData)==null?void 0:ua.find(Be=>(Be==null?void 0:Be.key)==="pageColumn"))==null?void 0:Za.contents)!=null&&$.includes("["))){const Be=await Rr.getInsofDataApi({id:ze==null?void 0:ze.tableId});let ae=((fe=(he=(X=(H=Be==null?void 0:Be.data)==null?void 0:H.result)==null?void 0:X[0])==null?void 0:he.key)==null?void 0:fe.pageKey)??"";(ha=Object.values(Ia))==null||ha.forEach(se=>{be.push({key:{type:"data",pageKey:ae,tableId:ze==null?void 0:ze.tableId,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:se}})})}else(ta=Object.values(Ia))==null||ta.forEach(Be=>{be.push({key:{type:"data",pageKey:T,tableId:ze==null?void 0:ze.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Be}})});(be==null?void 0:be.length)>0&&await Rr.batchAddInsofDataApi({dataList:be})}else if(!(ie!=null&&ie[1])&&(ze==null?void 0:ze.comp)==="Form"){let Ia=A.cloneDeep(ze);Ia.compData=(xa=(Fe=A.cloneDeep(Ia))==null?void 0:Fe.compData)==null?void 0:xa.map(Te=>{var be,Be;return(Te==null?void 0:Te.key)==="formContent"&&(Te.contents=(Be=(be=A.cloneDeep(Te))==null?void 0:be.contents)==null?void 0:Be.map(ae=>{var se,Xe;return(se=A.cloneDeep(de))!=null&&se[ae==null?void 0:ae.key]&&(ae.value=(Xe=A.cloneDeep(de))==null?void 0:Xe[ae==null?void 0:ae.key]),ae})),Te});const fa=await Rr.getInsofDataApi({key:{type:"structure",pageKey:T,systemKey:sessionStorage.getItem("systemKey")}});let Ba="";((Ae=fa==null?void 0:fa.data)==null?void 0:Ae.type)==="success"&&((La=(va=fa==null?void 0:fa.data)==null?void 0:va.result)==null||La.forEach(Te=>{var be,Be;((Be=(be=Te==null?void 0:Te.value)==null?void 0:be.pageData)==null?void 0:Be.name)===(ie==null?void 0:ie[0])&&(Ba=Te.id)}),await Rr.updateInsofDataApi({id:Ba,value:{pageData:Ia}}))}}},Y=async de=>{var T,ie,U,ge,ze,Le,ra,Ca,Q,ca,ue,pa,Se,ce;u.setImportLoading(!0);try{if(de.api){let De=new WeakMap,Ke=await oe.getItemData((w==null?void 0:w.value)===""?_.value:w==null?void 0:w.value,sessionStorage.getItem("systemKey"),"",!1,"","",De),ua="";if(Ke=Ke==null?void 0:Ke.map(ta=>{var Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae;if((ta==null?void 0:ta.comp)==="Form")ta.compData=(Fe=ta.compData)==null?void 0:Fe.map(se=>{var Xe;return(se==null?void 0:se.key)==="formContent"&&(se.contents=(Xe=se.contents)==null?void 0:Xe.map(Ze=>{var Ha;if((Ze==null?void 0:Ze.value)===""&&(Ze==null?void 0:Ze.type)==="Select"){let _a=oe.judgeContents((Ha=A.cloneDeep(Ze))==null?void 0:Ha.optionUrl,De);Ze.value=Ze.value||_a}return Ze})),se});else if((ta==null?void 0:ta.comp)==="Table"&&(xa=ta.compData)!=null&&xa.find(se=>(se==null?void 0:se.key)==="pageColumn")){let se=(va=(Ae=ta.compData)==null?void 0:Ae.find(_a=>(_a==null?void 0:_a.key)==="pageColumn"))==null?void 0:va.contents,Xe=((Ia=(La=ta.compData)==null?void 0:La.find(_a=>(_a==null?void 0:_a.key)==="pageGroup"))==null?void 0:Ia.contents)??"",Ze=(Te=(Ba=(fa=se==null?void 0:se.split("["))==null?void 0:fa[1])==null?void 0:Ba.split("]"))==null?void 0:Te[0];ua=((be=se==null?void 0:se.split("["))==null?void 0:be[0])+((ae=(Be=O.value)==null?void 0:Be.find(_a=>(_a==null?void 0:_a.key)===Ze))==null?void 0:ae.value)}return ta}),!(ua===""||ua==="")){const ta=await oe.getItemData(ua,sessionStorage.getItem("systemKey"),"",!1,"","",De);Ke=Ke==null?void 0:Ke.map(Fe=>{var xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae,se,Xe;if((Fe==null?void 0:Fe.comp)==="Table"&&(xa=Fe.compData)!=null&&xa.find(Ze=>(Ze==null?void 0:Ze.key)==="pageColumn")){let Ze=(va=(Ae=Fe.compData)==null?void 0:Ae.find(Re=>(Re==null?void 0:Re.key)==="pageColumn"))==null?void 0:va.contents,Ha=((Ia=(La=Fe.compData)==null?void 0:La.find(Re=>(Re==null?void 0:Re.key)==="pageGroup"))==null?void 0:Ia.contents)??"",_a=(Te=(Ba=(fa=Ze==null?void 0:Ze.split("["))==null?void 0:fa[1])==null?void 0:Ba.split("]"))==null?void 0:Te[0],Qa=((be=Ze==null?void 0:Ze.split("["))==null?void 0:be[0])+((ae=(Be=O.value)==null?void 0:Be.find(Re=>(Re==null?void 0:Re.key)===_a))==null?void 0:ae.value),Pe=(se=ta==null?void 0:ta.find(Re=>(Re==null?void 0:Re.name)===(Ha===""?i==null?void 0:i.compName:Ha)))==null?void 0:se.compData;Fe.compData=(Xe=Fe.compData)==null?void 0:Xe.map(Re=>{var Ue;return(Re==null?void 0:Re.key)==="tableContents"&&(Re.contents=(Ue=Pe==null?void 0:Pe.find(Ne=>(Ne==null?void 0:Ne.key)==="tableContents"))==null?void 0:Ue.contents),Re})}return Fe})}let Za={};if(((ie=(T=de==null?void 0:de.extraValues)==null?void 0:T.input)==null?void 0:ie.length)>0){const ta=(ge=(U=de==null?void 0:de.extraValues)==null?void 0:U.input)==null?void 0:ge.map(async Fe=>{var xa;te!=null&&te.find(Ae=>Ae===Fe)?Za=await J(Fe,Ke):Za[Object.keys(Fe)[0]]=await J((xa=Object.values(Fe))==null?void 0:xa[0],Ke,De)});await Promise.all(ta)}else Za=await J("/",Ke);let $=!1;(Le=(ze=de==null?void 0:de.extraValues)==null?void 0:ze.output)==null||Le.forEach(ta=>{var Fe,xa;(xa=(Fe=Object.values(ta))==null?void 0:Fe[0])!=null&&xa.includes(".doc")&&($=!0)});let H;if($){const ta=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});H=await Wa.axios.post(de.api,Za,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{ta.close()})}else H=await Wa.axios.post(de.api,Za,{headers:{"Content-Type":"application/json"}});let X=(ca=(Q=(Ca=(ra=A.cloneDeep(de))==null?void 0:ra.extraValues)==null?void 0:Ca.output)==null?void 0:Q.map(ta=>{var Fe,xa,Ae,va,La,Ia,fa,Ba,Te,be,Be,ae,se,Xe,Ze,Ha;if(!((xa=(Fe=Object.values(ta))==null?void 0:Fe[0])!=null&&xa.includes(".doc"))){let _a=(be=(Te=(Ba=(va=A.cloneDeep((Ae=Object.values(ta))==null?void 0:Ae[0]))==null?void 0:va.split("["))==null?void 0:Ba[((fa=(Ia=A.cloneDeep((La=Object.values(ta))==null?void 0:La[0]))==null?void 0:Ia.split("["))==null?void 0:fa.length)-1])==null?void 0:Te.split("]"))==null?void 0:be[0],Qa=_a==null?void 0:_a.split(":"),Pe=(se=A.cloneDeep((Be=Object.values(ta))==null?void 0:Be[0]))==null?void 0:se.substring(0,A.cloneDeep((ae=Object.values(ta))==null?void 0:ae[0]).lastIndexOf("["));if(Pe=(Ze=A.cloneDeep(Pe))==null?void 0:Ze.slice(0,((Xe=A.cloneDeep(Pe))==null?void 0:Xe.length)-1),Pe!=null&&Pe.includes("[")){let Re="";if((Ha=oe.contentTransArrayToAll(Pe,"/"))==null||Ha.forEach(Ue=>{var Ne,Ie,ul,_l,Tl,jl,Cl;if(!(Ue!=null&&Ue.includes("[")))Re=Re===""?Re+Ue.replaceAll("/",""):Re+"/"+Ue.replaceAll("/","");else{let Yl=A.cloneDeep(Ue).slice(1,((Ne=A.cloneDeep(Ue))==null?void 0:Ne.length)-1),aa=(jl=(Tl=(_l=(ul=(Ie=A.cloneDeep(Yl))==null?void 0:Ie.split("["))==null?void 0:ul[1])==null?void 0:_l.split("]"))==null?void 0:Tl[0])==null?void 0:jl.split(":"),Ka="",ma=(Cl=Ke==null?void 0:Ke.find(il=>(il==null?void 0:il.name)===(aa==null?void 0:aa[0])))==null?void 0:Cl.compData;ma==null||ma.forEach(il=>{var Aa;(il==null?void 0:il.key)==="formContent"&&((Aa=il==null?void 0:il.contents)==null||Aa.forEach(sl=>{(sl==null?void 0:sl.key)===(aa==null?void 0:aa[1])&&(Ka=sl==null?void 0:sl.value)}))}),Re=Re===""?Re+Ka.replaceAll("/",""):Re+"/"+Ka.replaceAll("/","")}}),Pe=Re,Pe[(Pe==null?void 0:Pe.length)-1]!=="/")return Pe}}}))==null?void 0:ca.filter(ta=>ta);X=[...new Set(A.cloneDeep(X))];let he=X==null?void 0:X.map(async ta=>{let Fe=await oe.getItemData(ta,sessionStorage.getItem("systemKey"),"",!1,"","",De);if((Fe==null?void 0:Fe.length)===0)return await oe.getParentContents(ta)});await Promise.all(he);let fe=[],ha=(Se=(pa=(ue=A.cloneDeep(de))==null?void 0:ue.extraValues)==null?void 0:pa.output)==null?void 0:Se.map(async ta=>{var Ba,Te,be,Be,ae,se,Xe,Ze,Ha,_a,Qa,Pe,Re,Ue,Ne,Ie,ul,_l,Tl,jl,Cl,Yl,aa,Ka,ma,il,Aa,sl,rl,qe,Ga,hl,pe,na,Sa,la,nl,Je,Fa,wa,Oa,Me,Ra,Va,Bl,We,Ma,Sl,pr,ga,Zl,Sr,Cr,Oe,lr,br,Dr,zl,$r,Ur,Ul,gr,vn,vr,Il,sn,jr,qr,Kr,Xr;if((Te=(Ba=Object.values(ta))==null?void 0:Ba[0])!=null&&Te.includes(".doc")){var Fe=new Blob([H.data],{type:"application/octet-stream;charset=UTF-8"}),xa=H.headers["content-disposition"],Ae=new RegExp("filename=([^;]+\\.[^\\.;]+);*"),va=Ae.exec(xa),La=va==null?void 0:va[1],Ia=document.createElement("a"),fa=window.URL.createObjectURL(Fe);h.value=[{name:La,blobUrl:fa}],s.value=!0}else{let Wr=(_a=(Ha=(Ze=(Be=A.cloneDeep((be=Object.values(ta))==null?void 0:be[0]))==null?void 0:Be.split("["))==null?void 0:Ze[((Xe=(se=A.cloneDeep((ae=Object.values(ta))==null?void 0:ae[0]))==null?void 0:se.split("["))==null?void 0:Xe.length)-1])==null?void 0:Ha.split("]"))==null?void 0:_a[0],rr=Wr==null?void 0:Wr.split(":"),nr=(Re=A.cloneDeep((Qa=Object.values(ta))==null?void 0:Qa[0]))==null?void 0:Re.substring(0,A.cloneDeep((Pe=Object.values(ta))==null?void 0:Pe[0]).lastIndexOf("["));if(nr!=null&&nr.includes("[")?nr=(Ne=A.cloneDeep(nr))==null?void 0:Ne.slice(0,((Ue=A.cloneDeep(nr))==null?void 0:Ue.length)-1):nr===""&&(nr=_.value),nr=nr.replaceAll("<","[").replaceAll(">","]"),nr!=null&&nr.includes("[")){let ml="";(Ie=oe.contentTransArrayToAll(nr,"/"))==null||Ie.forEach((or,Fl)=>{var Er,Wl,hr,Vr,kr,cn,Qr,Jn,Fn,Dn,In;if(!(or!=null&&or.includes("[")))ml=ml===""?ml+or.replaceAll("/",""):ml+"/"+or.replaceAll("/","");else{let jn="",mn="";(Er=A.cloneDeep(or))!=null&&Er.includes("]")?(jn=A.cloneDeep(or).slice(1,((Wl=A.cloneDeep(or))==null?void 0:Wl.length)-1),mn=(Qr=(cn=(kr=(Vr=(hr=A.cloneDeep(jn))==null?void 0:hr.split("["))==null?void 0:Vr[1])==null?void 0:kr.split("]"))==null?void 0:cn[0])==null?void 0:Qr.split(":")):(jn=A.cloneDeep(or).slice(1,(Jn=A.cloneDeep(or))==null?void 0:Jn.length),mn=(Fn=A.cloneDeep(jn))==null?void 0:Fn.split("/"));let On="",Xn=(Dn=Ke==null?void 0:Ke.find(Gr=>(Gr==null?void 0:Gr.name)===(mn==null?void 0:mn[0])))==null?void 0:Dn.compData;Xn==null||Xn.forEach(Gr=>{var Zn;(Gr==null?void 0:Gr.key)==="formContent"&&((Zn=Gr==null?void 0:Gr.contents)==null||Zn.forEach(_n=>{(_n==null?void 0:_n.key)===(mn==null?void 0:mn[1])&&(On=_n==null?void 0:_n.value)}))}),((In=oe.contentTransArrayToAll(nr,"/"))==null?void 0:In.length)-1!==Fl?ml=ml===""?ml+On.replaceAll("/",""):ml+"/"+On.replaceAll("/",""):ml=ml+r.value+On.replaceAll("/","")}}),(ul=_.value)!=null&&ul.includes(ml)?nr=_.value:nr=ml}let Zr=A.cloneDeep((_l=Object.keys(ta))==null?void 0:_l[0]);if(((Tl=H==null?void 0:H.data)==null?void 0:Tl.statusCode)===200||((jl=H==null?void 0:H.data)==null?void 0:jl.code)===200){if(((Yl=(Cl=H==null?void 0:H.data)==null?void 0:Cl.data)!=null&&Yl[Zr]||(Ka=(aa=H==null?void 0:H.data)==null?void 0:aa.result)!=null&&Ka[Zr])&&(rr==null?void 0:rr.length)===1)return await ne(((il=(ma=H==null?void 0:H.data)==null?void 0:ma.data)==null?void 0:il[Zr])||((sl=(Aa=H==null?void 0:H.data)==null?void 0:Aa.result)==null?void 0:sl[Zr]),A.cloneDeep(nr),rr,ua);if((qe=(rl=H==null?void 0:H.data)==null?void 0:rl.data)!=null&&qe[Zr]||(hl=(Ga=H==null?void 0:H.data)==null?void 0:Ga.result)!=null&&hl[Zr]){let ml=await me(((na=(pe=H==null?void 0:H.data)==null?void 0:pe.data)==null?void 0:na[Zr])||((la=(Sa=H==null?void 0:H.data)==null?void 0:Sa.result)==null?void 0:la[Zr]),A.cloneDeep(nr),rr);return ml&&(fe=[...fe,...ml]),ml}else{if(!((nl=H==null?void 0:H.data)!=null&&nl.data)){let ml=await oe.getItemData(_.value,sessionStorage.getItem("systemKey"),"",!1,"","",De);ml=ml==null?void 0:ml.map(Fl=>{var Er;return(Fl==null?void 0:Fl.name)===(rr==null?void 0:rr[0])&&(Fl.compData=(Er=Fl.compData)==null?void 0:Er.map(Wl=>{var hr;return(Wl==null?void 0:Wl.key)==="formContent"&&(Wl.contents=(hr=Wl.contents)==null?void 0:hr.map(Vr=>{var kr,cn;return(Vr==null?void 0:Vr.key)===(rr==null?void 0:rr[1])&&(Vr.value=(cn=(kr=H==null?void 0:H.data)==null?void 0:kr.result)==null?void 0:cn[Zr==null?void 0:Zr.replaceAll(":","")]),Vr})),Wl})),Fl});let or=[];(Je=ml==null?void 0:ml.filter(Fl=>(Fl==null?void 0:Fl.comp)==="Form"))==null||Je.forEach(async Fl=>{let Er={};for(let Wl in Fl)Wl!=="id"&&(Er[Wl]=Fl[Wl]);or.push({id:Fl==null?void 0:Fl.id,value:{pageData:Er}})}),(or==null?void 0:or.length)>0&&await Rr.batchUpdateInsofDataApi({dataList:or});return}if((rr==null?void 0:rr.length)===1){const ml=(Oa=(wa=(Fa=H==null?void 0:H.data)==null?void 0:Fa.data)==null?void 0:wa.path)==null?void 0:Oa.path;let or="";(We=(Bl=(Va=(Ra=(Me=ml==null?void 0:ml.split("("))==null?void 0:Me[1])==null?void 0:Ra.split(")"))==null?void 0:Va[0])==null?void 0:Bl.split(":"))==null||We.forEach(Wl=>{var hr,Vr;or=or===""?or+((hr=Wl==null?void 0:Wl.replaceAll("'",""))==null?void 0:hr.trim()):or+"/"+((Vr=Wl==null?void 0:Wl.replaceAll("'",""))==null?void 0:Vr.trim())});let Fl=[(Zl=(ga=(pr=(Sl=(Ma=ml==null?void 0:ml.split("<"))==null?void 0:Ma[1])==null?void 0:Sl.split(">"))==null?void 0:pr[0])==null?void 0:ga.replaceAll("'",""))==null?void 0:Zl.trim()],Er;return(Oe=(Cr=(Sr=H==null?void 0:H.data)==null?void 0:Sr.data)==null?void 0:Cr.data)!=null&&Oe[rr==null?void 0:rr[0]]?Er=await ne((Dr=(br=(lr=H==null?void 0:H.data)==null?void 0:lr.data)==null?void 0:br.data)==null?void 0:Dr[rr==null?void 0:rr[0]],or,rr,ua):Er=await _e(($r=(zl=H==null?void 0:H.data)==null?void 0:zl.data)==null?void 0:$r.data,or,Fl,De),Er}else{const ml=(gr=(Ul=(Ur=H==null?void 0:H.data)==null?void 0:Ur.data)==null?void 0:Ul.path)==null?void 0:gr.path;let or="";return(jr=(sn=(Il=(vr=(vn=ml==null?void 0:ml.split("("))==null?void 0:vn[1])==null?void 0:vr.split(")"))==null?void 0:Il[0])==null?void 0:sn.split(":"))==null||jr.forEach(Er=>{var Wl,hr;or=or===""?or+((Wl=Er==null?void 0:Er.replaceAll("'",""))==null?void 0:Wl.trim()):or+"/"+((hr=Er==null?void 0:Er.replaceAll("'",""))==null?void 0:hr.trim())}),await me((Xr=(Kr=(qr=H==null?void 0:H.data)==null?void 0:qr.data)==null?void 0:Kr.data)==null?void 0:Xr[rr==null?void 0:rr[0]],or,rr)}}}}});if(await Promise.all(ha),(fe==null?void 0:fe.length)>0){let ta=[];fe==null||fe.forEach(Ae=>{ta!=null&&ta.find(va=>{var La,Ia,fa,Ba;return((Ia=(La=va==null?void 0:va.value)==null?void 0:La.pageData)==null?void 0:Ia.name)===((Ba=(fa=Ae==null?void 0:Ae.value)==null?void 0:fa.pageData)==null?void 0:Ba.name)})||ta.push(Ae)});let Fe=[];ta==null||ta.forEach(Ae=>{var Ia,fa,Ba,Te;let va=A.cloneDeep(Ae);va.value.pageData.compData=(Ia=va.value.pageData.compData)==null?void 0:Ia.map(be=>{var Be;return(be==null?void 0:be.key)==="formContent"&&(be.contents=(Be=be.contents)==null?void 0:Be.map(ae=>{var Xe,Ze,Ha,_a;let se=(Xe=A.cloneDeep(fe))==null?void 0:Xe.find(Qa=>(Qa==null?void 0:Qa.keyType)===(ae==null?void 0:ae.key));if(se){let Qa=(_a=(Ha=(Ze=se.value.pageData.compData)==null?void 0:Ze.find(Pe=>(Pe==null?void 0:Pe.key)==="formContent"))==null?void 0:Ha.contents)==null?void 0:_a.find(Pe=>(Pe==null?void 0:Pe.key)===(ae==null?void 0:ae.key));ae.value=Qa==null?void 0:Qa.value}return ae})),be}),Fe.push({id:va==null?void 0:va.id,value:va==null?void 0:va.value});let La=[];(Te=(Ba=(fa=va==null?void 0:va.value)==null?void 0:fa.pageData)==null?void 0:Ba.compData)==null||Te.forEach(be=>{var Be;(be==null?void 0:be.key)==="formContent"&&((Be=be==null?void 0:be.contents)==null||Be.forEach(ae=>{var se,Xe,Ze,Ha,_a,Qa;if((Xe=(se=ae==null?void 0:ae.optionUrl)==null?void 0:se.menuSelect)!=null&&Xe.find(Pe=>Pe==null?void 0:Pe.includes("[")))if(La!=null&&La.find(Pe=>{var Re,Ue,Ne;return((Re=Pe==null?void 0:Pe.key)==null?void 0:Re.join(","))===((Ne=(Ue=ae==null?void 0:ae.optionUrl)==null?void 0:Ue.menuSelect)==null?void 0:Ne.join(","))})){let Pe=(Ze=La==null?void 0:La.find(Re=>{var Ue,Ne,Ie;return((Ue=Re==null?void 0:Re.key)==null?void 0:Ue.join(","))===((Ie=(Ne=ae==null?void 0:ae.optionUrl)==null?void 0:Ne.menuSelect)==null?void 0:Ie.join(","))}))==null?void 0:Ze.value;Pe.push({key:ae==null?void 0:ae.prop,groups:(Ha=ae==null?void 0:ae.optionUrl)==null?void 0:Ha.groupSelect,value:ae==null?void 0:ae.value}),La=La==null?void 0:La.map(Re=>{var Ue,Ne,Ie;return((Ue=Re==null?void 0:Re.key)==null?void 0:Ue.join(","))===((Ie=(Ne=ae==null?void 0:ae.optionUrl)==null?void 0:Ne.menuSelect)==null?void 0:Ie.join(","))&&(Re.value=Pe),Re})}else La.push({key:(_a=ae==null?void 0:ae.optionUrl)==null?void 0:_a.menuSelect,value:[{key:ae==null?void 0:ae.prop,groups:(Qa=ae==null?void 0:ae.optionUrl)==null?void 0:Qa.groupSelect,value:ae==null?void 0:ae.value}]})}))}),(La==null?void 0:La.length)>0&&(La=La==null?void 0:La.map(be=>{var ae;let Be="";return(ae=be==null?void 0:be.key)==null||ae.forEach(se=>{var Xe;if(!(se!=null&&se.includes("[")))Be=Be===""?Be+se:Be+"/"+se;else{let Ze="",Ha=(Xe=se==null?void 0:se.replaceAll("[","").replaceAll("]",""))==null?void 0:Xe.split(":");Ke==null||Ke.forEach(_a=>{var Qa;(_a==null?void 0:_a.name)===(Ha==null?void 0:Ha[0])&&((Qa=_a==null?void 0:_a.compData)==null||Qa.forEach(Pe=>{var Re;(Pe==null?void 0:Pe.key)==="formContent"&&((Re=Pe==null?void 0:Pe.contents)==null||Re.forEach(Ue=>{(Ue==null?void 0:Ue.prop)===(Ha==null?void 0:Ha[1])&&(Ze=Ue==null?void 0:Ue.value)}))}))}),Be=Be+r.value+Ze}}),be.key=Be,be})),La==null||La.forEach(be=>{var Xe,Ze,Ha;let Be=(Xe=De[be.key])==null?void 0:Xe.find(_a=>{var Qa,Pe,Re,Ue,Ne,Ie,ul;return((Pe=(Qa=_a==null?void 0:_a.value)==null?void 0:Qa.pageData)==null?void 0:Pe.name)===((Ne=(Ue=(Re=be==null?void 0:be.value)==null?void 0:Re[0])==null?void 0:Ue.groups)==null?void 0:Ne[0])&&((ul=(Ie=_a==null?void 0:_a.value)==null?void 0:Ie.pageData)==null?void 0:ul.name)!==void 0}),ae=Be==null?void 0:Be.id,se=(Ze=Be==null?void 0:Be.value)==null?void 0:Ze.pageData;se.compData=(Ha=se.compData)==null?void 0:Ha.map(_a=>{var Qa;return(_a==null?void 0:_a.key)==="formContent"&&(_a.contents=(Qa=_a.contents)==null?void 0:Qa.map(Pe=>{var Ue;let Re=(Ue=be.value)==null?void 0:Ue.find(Ne=>(Ne==null?void 0:Ne.key)===(Pe==null?void 0:Pe.prop));return Re&&(Pe.value=Re.value),Pe})),_a}),Fe.push({id:ae,value:{pageData:se}})})});let xa=(ce=A.cloneDeep(fe))==null?void 0:ce[0];(Fe==null?void 0:Fe.length)>0&&await Rr.batchUpdateInsofDataApi({dataList:Fe})}m.setFreshContent(!0)}u.setImportLoading(!1)}catch{Wa.ElMessage.error("方法执行错误,请查看方法!"),u.setImportLoading(!1)}E.value=!0},te=["createInsofDataApi"],ye=Al.debounce(async de=>{Y(de)},100),$e=async de=>{var Le,ra,Ca;const T=A.cloneDeep(de);let ie,U=new WeakMap;de!=null&&de[0].path&&(ie=await(T==null?void 0:T.map(async(Q,ca)=>{var Za,$,H,X,he,fe,ha,ta,Fe,xa,Ae,va,La,Ia,fa,Ba;const pa=(Za=U[Q==null?void 0:Q.path])==null?void 0:Za.filter(Te=>{var be;return((be=Te==null?void 0:Te.key)==null?void 0:be.type)==="data"});let Se="";const ce=await oe.getItemData(_.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,U);pa==null||pa.forEach(Te=>{var be,Be,ae,se,Xe;((Be=(be=Te==null?void 0:Te.value)==null?void 0:be.tableData)==null?void 0:Be.算法名称)===((ae=T==null?void 0:T[ca])==null?void 0:ae.method)&&(Se=(Xe=(se=Te==null?void 0:Te.value)==null?void 0:se.tableData)==null?void 0:Xe.算法体)});const De=await oe.getItemData(Q==null?void 0:Q.path,sessionStorage.getItem("systemKey"),"",!1,[],!1,U);let Ke="",ua=(he=(X=(H=($=De==null?void 0:De[0])==null?void 0:$.compData)==null?void 0:H.find(Te=>(Te==null?void 0:Te.key)==="header"))==null?void 0:X.contents)==null?void 0:he.findIndex(Te=>(Te==null?void 0:Te.prop)==="算法体");return(ha=(fe=De==null?void 0:De[0])==null?void 0:fe.compData)==null||ha.forEach(Te=>{var be;(Te==null?void 0:Te.key)==="tableContents"&&((be=Te==null?void 0:Te.contents)==null||be.forEach(Be=>{Be!=null&&Be.find(ae=>ae===(Q==null?void 0:Q.method))&&(Ke=Be[ua])}))}),{buttonName:((ta=T==null?void 0:T[ca])==null?void 0:ta.method)||((Ae=(xa=(Fe=pa==null?void 0:pa[0])==null?void 0:Fe.value)==null?void 0:xa.tableData)==null?void 0:Ae.算法名称),api:(Se===""?(Ia=(La=(va=pa==null?void 0:pa[0])==null?void 0:va.value)==null?void 0:La.tableData)==null?void 0:Ia.算法体:Se)||Ke,content:ce==null?void 0:ce.filter(Te=>Te.comp!=="methodButton"),extraContent:(fa=A.cloneDeep(Q.value))==null?void 0:fa.slice(1),methodName:(Q==null?void 0:Q.path)??"",extraValues:(Ba=T==null?void 0:T[ca])==null?void 0:Ba.data}})));const ge=T==null?void 0:T.map(async Q=>{var De,Ke,ua,Za,$,H;const ca=(De=resAll.data.result)==null?void 0:De.filter(X=>{var he,fe,ha;return((he=X==null?void 0:X.key)==null?void 0:he.parentTable)===""&&((fe=X==null?void 0:X.key)==null?void 0:fe.type)==="method"&&((ha=X==null?void 0:X.key)==null?void 0:ha.methodName)===X.method}),ue=ca==null?void 0:ca[0],pa=(Ke=resAll.data.result)==null?void 0:Ke.filter(X=>{var he,fe;return((he=X==null?void 0:X.key)==null?void 0:he.type)==="methodData"&&((fe=X==null?void 0:X.key)==null?void 0:fe.tableId)===(ue==null?void 0:ue.id)}),Se=await oe.getItemData(_.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,U),ce=pa==null?void 0:pa[0];return{buttonName:(ua=ue==null?void 0:ue.key)==null?void 0:ua.methodKey,api:($=(Za=ce==null?void 0:ce.value)==null?void 0:Za.tableData)==null?void 0:$[0],content:Se==null?void 0:Se.filter(X=>X.comp!=="methodButton"),extraContent:(H=A.cloneDeep(Q.value))==null?void 0:H.slice(1),methodName:(Q==null?void 0:Q.method)??""}}),ze=(Le=de==null?void 0:de[0])!=null&&Le.path&&((ra=de==null?void 0:de[0])==null?void 0:ra.path)!==""?await Promise.all(ie):await Promise.all(ge);l.value=ze==null?void 0:ze.filter(Q=>Q==null?void 0:Q.extraContent),(Ca=l.value)==null||Ca.forEach(Q=>{var ca;Q.api===""&&((ca=Q.content)==null||ca.forEach(ue=>{var pa;ue.comp=="Table"&&m.setExtraContents(oe.methodTableToContent(ue.compData,(pa=Q.extraContent)==null?void 0:pa[0]))}))})};return e.watch(()=>i.itemData,async()=>{k.value=="view"&&!E.value&&await $e(A.cloneDeep(i.itemData)),E.value=!1},{immediate:!0,deep:!0}),(de,T)=>{var ie,U,ge;return e.unref(k)!=="edit"?(e.openBlock(),e.createElementBlock("div",c4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((ie=l.value)==null?void 0:ie.filter(ze=>(ze==null?void 0:ze.buttonName)!=="保存"),ze=>{var Le;return e.openBlock(),e.createElementBlock("div",null,[ze.api!==""?(e.openBlock(),e.createBlock(e.unref(ss._sfc_main),{key:0,disabled:e.unref(j)===e.unref(_)&&!((Le=ze==null?void 0:ze.buttonName)!=null&&Le.includes("预览")),class:"calculator-content",modelValue:ze.buttonName,onClickTrigger:ra=>e.unref(ye)(ze),loading:b.value},null,8,["disabled","modelValue","onClickTrigger","loading"])):e.createCommentVNode("",!0)])}),256)),e.createElementVNode("div",null,[e.unref(W)!==""&&((ge=e.unref(_))==null?void 0:ge[((U=e.unref(_))==null?void 0:U.length)-1])!==e.unref(r)?(e.openBlock(),e.createBlock(e.unref(ss._sfc_main),{key:0,class:"calculator-content",onClickTrigger:P,modelValue:"保存"})):e.createCommentVNode("",!0)]),s.value?(e.openBlock(),e.createBlock(cl.ssFilePreview,{key:0,fileDataList:h.value,onDestroy:V},null,8,["fileDataList"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},d4=ar._export_sfc(u4,[["__scopeId","data-v-063aa9af"]]),p4={};function f4(a,l){return" 567 "}const h4=ar._export_sfc(p4,[["render",f4]]),v4={class:"module content"},m4={class:"module data"},y4={class:"module layout"},g4={class:"form-content"},b4=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.reactive({visible:!1,width:"40%",title:"签名配置"}),s=e.ref("create"),h=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),c=e.ref([{label:"宽度(%):",prop:"signPadWidth",type:"number",value:"30"},{label:"弹窗名称:",prop:"dialogTitle",type:"input",value:""},{label:"弹窗宽度(%):",prop:"dialogWidth",type:"number",value:"30"},{label:"弹窗显示:",prop:"dialogShow",type:"radio",contents:[{label:"显示",value:!0},{label:"隐藏",value:!1}],value:!1,isFormColHidden:!0},{label:"路径:",prop:"url",type:"input",value:"",isFormColHidden:!0}]),d=e.computed(()=>[{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"类型:",prop:"label",type:"select",contents:[{label:"电子签名",value:"电子签名"},{label:"签字版",value:"签字版"},{label:"上传签名",value:"上传签名"}],value:""},{label:"图标",prop:"icon",type:"inputPopover",value:""}]),m=e.ref({}),b=e.ref([]),u=()=>({comp:"Signature",compData:[{key:"signTypeList",contents:b.value},{key:"signConfig",contents:m.value}]}),C=O=>{var j;m.value=A.cloneDeep(O),r("change",(j=u())==null?void 0:j.compData)},M=O=>{var j,L;if((O==null?void 0:O.buttonName)==="确认"){const _=A.cloneDeep(O==null?void 0:O.content);switch(s.value){case"create":b.value.push({..._,index:((j=b.value)==null?void 0:j.length)+1});break}r("change",(L=u())==null?void 0:L.compData),i.visible=!1}else i.visible=!1},k=(O,j)=>{var L,_;switch(O){case"create":(L=d.value)==null||L.forEach(x=>{x.value=""}),s.value="create",i.visible=!0;break;case"update":(_=d.value)==null||_.forEach(x=>{x.value=j[x==null?void 0:x.prop]}),s.value="update",i.visible=!0;break;case"delete":b.value.splice(j,1),s.value="delete";break}},W=()=>{i.visible=!1};return e.watch(()=>n==null?void 0:n.itemContents,O=>{var j,L;O&&(m.value=((j=O==null?void 0:O.find(_=>_.key==="signConfig"))==null?void 0:j.contents)??{},b.value=((L=O==null?void 0:O.find(_=>_.key==="signTypeList"))==null?void 0:L.contents)??[])},{immediate:!0}),(O,j)=>{const L=e.resolveComponent("svg-icon"),_=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",v4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"签名类型",-1)),e.createVNode(_,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=x=>k("create"))},{icon:e.withCtx(()=>[e.createVNode(L,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",m4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(x,w)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:w},[e.createElementVNode("span",null,e.toDisplayString(x==null?void 0:x.label),1),e.createElementVNode("div",null,[e.createVNode(_,{type:"primary",size:"small",onClick:g=>k("update",{...x,index:w+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(_,{type:"danger",size:"small",onClick:g=>k("delete",w)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",y4,[e.createVNode(cl.ssForm,{rowContents:c.value,onChange:C},null,8,["rowContents"])])]),e.createVNode(Ar.ssDialog,{visible:i.visible,title:i.title,onBeforeDestroy:W,width:i.width},{default:e.withCtx(()=>[e.createElementVNode("div",g4,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:d.value,key:d.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:h.value,onOnButtonClick:M},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),k4=ar._export_sfc(b4,[["__scopeId","data-v-487e0536"]]),x4=e.defineComponent({__name:"index",props:{stepConfig:{type:Object,default:{}},stepList:{type:Array,default:()=>[]}},emits:["clickStep","clickTrigger","changeTrigger"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(0),s=e.computed(()=>{var u,C;return(u=n==null?void 0:n.stepConfig)!=null&&u.allowTrigger?i.value:(C=n==null?void 0:n.stepConfig)==null?void 0:C.active}),h=(u,C)=>{i.value=C-1,r("clickStep",u,C)};e.onMounted(()=>{var u;r("clickStep",(u=n==null?void 0:n.stepList)==null?void 0:u[0],0)});const c=u=>cl.getComponent(u),d=()=>{var C;const u=(C=n==null?void 0:n.stepList)==null?void 0:C.find((M,k)=>k+1===s.value);return console.log("findStep",u),u?u==null?void 0:u.children:[]},m=u=>{r("clickTrigger",u)},b=u=>{r("changeTrigger",u)};return(u,C)=>{var W,O,j,L,_;const M=e.resolveComponent("el-step"),k=e.resolveComponent("el-steps");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(k,{direction:(W=a.stepConfig)==null?void 0:W.direction,active:s.value,"finish-status":"success",simple:(O=a.stepConfig)==null?void 0:O.simple,"align-center":((j=a.stepConfig)==null?void 0:j.alignCenter)??!0},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.stepList,(x,w)=>(e.openBlock(),e.createBlock(M,{key:w,class:"step-item",onClick:g=>h(x,w+1)},{title:e.withCtx(()=>[e.renderSlot(u.$slots,"title",{title:x==null?void 0:x.title},void 0,!0)]),description:e.withCtx(()=>[e.renderSlot(u.$slots,"description",{descriptions:x==null?void 0:x.description},void 0,!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["direction","active","simple","align-center"]),(L=a.stepConfig)!=null&&L.allowTrigger&&((_=a.stepConfig)!=null&&_.active)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(d(),(x,w)=>(e.openBlock(),e.createElementBlock("div",{key:w,class:"step-cont-wrap"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(c(x==null?void 0:x.type)),{modelValue:x.value,"onUpdate:modelValue":g=>x.value=g,onClickTrigger:m,onChangeTrigger:b,content:x==null?void 0:x.content},e.createSlots({_:2},[e.renderList(u.$slots,(g,E)=>({name:E,fn:e.withCtx(P=>[e.renderSlot(u.$slots,E,e.mergeProps({ref_for:!0},P||{}),void 0,!0)])}))]),1064,["modelValue","onUpdate:modelValue","content"]))]))),128)):e.createCommentVNode("",!0)],64)}}}),w4=ar._export_sfc(x4,[["__scopeId","data-v-a30ff621"]]),_4=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]}},emits:["clickStep"],setup(a,{emit:l}){const n=a,r=l,i=e.ref({}),s=e.ref([]),h=(c,d)=>{r("clickStep",c,d)};return e.watch(()=>n==null?void 0:n.itemData,c=>{var u,C,M,k;i.value={direction:"horizontal",simple:!1,alignCenter:!0,allowTrigger:!0};let d=((u=c==null?void 0:c.find(W=>(W==null?void 0:W.key)==="stepName"))==null?void 0:u.contents)??[],m=[];(M=(C=c==null?void 0:c.find(W=>(W==null?void 0:W.key)==="header"))==null?void 0:C.contents)==null||M.forEach(W=>{m.push({label:W==null?void 0:W.label,prop:W==null?void 0:W.prop,name:W==null?void 0:W.prop,type:"text",disabled:!0})});let b=((k=c==null?void 0:c.find(W=>(W==null?void 0:W.key)==="tableContents"))==null?void 0:k.contents)??[];d=d==null?void 0:d.map((W,O)=>{let j=m==null?void 0:m.map(L=>{var _;return{...L,value:(_=b==null?void 0:b[O])==null?void 0:_[L==null?void 0:L.prop]}});return{title:W,description:j}}),s.value=d},{immediate:!0,deep:!0}),(c,d)=>{const m=e.resolveComponent("svg-icon");return e.openBlock(),e.createBlock(w4,{stepConfig:i.value,stepList:s.value,onClickStep:h},{icon:e.withCtx(()=>[e.createVNode(m,{name:"import"})]),title:e.withCtx(({title:b})=>[e.createTextVNode(e.toDisplayString(b),1)]),description:e.withCtx(({descriptions:b})=>[e.createVNode(cl.ssForm,{ref:"formRef",rowContents:b,showOperator:!0,isEnableWrap:!1,isEdit:!1},null,8,["rowContents"])]),_:1},8,["stepConfig","stepList"])}}}),S4=e.defineComponent({__name:"index",props:{activities:{type:Array,default:()=>[]},timeLineConfig:{type:Object,default:()=>{}}},setup(a){return(l,n)=>{const r=e.resolveComponent("el-timeline-item"),i=e.resolveComponent("el-timeline");return e.openBlock(),e.createBlock(i,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.activities,(s,h)=>(e.openBlock(),e.createBlock(r,{key:h,timestamp:s.timestamp,placement:a.timeLineConfig.placement,center:a.timeLineConfig.isCenter,"hide-timestamp":!0,type:a.timeLineConfig.type,color:a.timeLineConfig.color,size:a.timeLineConfig.size,icon:a.timeLineConfig.icon,hollow:a.timeLineConfig.isHollow},{default:e.withCtx(()=>[e.renderSlot(l.$slots,"content",{content:s==null?void 0:s.content,timestamp:s==null?void 0:s.timestamp},void 0,!0)]),_:2},1032,["timestamp","placement","center","type","color","size","icon","hollow"]))),128))]),_:3})}}}),E4=ar._export_sfc(S4,[["__scopeId","data-v-4172a886"]]),C4={class:"line-content"},D4={class:"line-time"},T4=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(a){const l=a,n=e.ref({}),r=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,i=>{var s,h;r.value=(s=i==null?void 0:i.find(c=>(c==null?void 0:c.key)==="timeLineList"))==null?void 0:s.contents,n.value=(h=i==null?void 0:i.find(c=>(c==null?void 0:c.key)==="timeLineConfig"))==null?void 0:h.contents},{immediate:!0}),(i,s)=>(e.openBlock(),e.createBlock(E4,{activities:r.value,timeLineConfig:n.value},{content:e.withCtx(({content:h,timestamp:c})=>[e.createElementVNode("span",C4,e.toDisplayString(h),1),e.createElementVNode("span",D4,e.toDisplayString(c),1)]),_:1},8,["activities","timeLineConfig"]))}}),B4=ar._export_sfc(T4,[["__scopeId","data-v-b4d9deed"]]),N4={class:"tabs-content"},A4=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},tabsData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,compNames:{type:String,default:""},cacheNewData:{type:Object},isDevMode:{type:Boolean},allMapContents:{type:Array,default:()=>[]}},emits:["change","contentChange","pageChange","rowClick","routeUrl","clickTrigger","clickMainKey"],setup(a,{emit:l}){const n=a,r=l,i=e.ref();e.watch(()=>n==null?void 0:n.itemData,()=>{i.value=n==null?void 0:n.itemData},{immediate:!0,deep:!0});const s=C=>{r("change",C)},h=(C,M)=>{r("contentChange",C,M)},c=C=>{r("pageChange",C)},d=C=>{r("rowClick",C)},m=(C,M)=>{r("routeUrl",C,M)},b=C=>{r("clickTrigger",C)},u=(C,M)=>{r("clickMainKey",C,M)};return(C,M)=>{var k,W;return e.openBlock(),e.createElementBlock("div",N4,[(k=i.value)!=null&&k.length?(e.openBlock(),e.createBlock(cl.ssTab,{tabsContents:i.value,key:(W=i.value)==null?void 0:W.length},{pane:e.withCtx(({tab:O,index:j})=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Zi)(O==null?void 0:O.comp)),{related:O==null?void 0:O.relatedTables,compNames:n==null?void 0:n.compNames,compName:O==null?void 0:O.name,cacheNewData:n==null?void 0:n.cacheNewData,isDevMode:a.isDevMode,itemData:O==null?void 0:O.compData,childItemData:O==null?void 0:O.itemChildData,onChange:s,index:(O==null?void 0:O.id)??j,config:{showIndex:O==null?void 0:O.showIndex,allowMove:O==null?void 0:O.allowMove,viewport:O==null?void 0:O.viewport,status:O==null?void 0:O.status},onContentChange:h,onPageChange:c,onRowClick:d,onRouteUrl:m,parentTableId:O==null?void 0:O.tableId,allMapContents:a.allMapContents,children:O==null?void 0:O.children,level:1,onClickTrigger:b,onClickMainKey:u},null,40,["related","compNames","compName","cacheNewData","isDevMode","itemData","childItemData","index","config","parentTableId","allMapContents","children"]))]),_:1},8,["tabsContents"])):e.createCommentVNode("",!0)])}}}),z4=ar._export_sfc(A4,[["__scopeId","data-v-1ea318b4"]]),M4={class:"type-select"},I4=["onClick"],O4={class:"list-icon"},L4={__name:"modelSelect",setup(a){const l=Yn(A.pinia),{itemData:n}=A.storeToRefs(l),r=i=>{const s=A.cloneDeep(n.value);s.push({comp:i.comp,name:i.name,compData:[]}),l.setItemData(s)};return(i,s)=>{const h=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",M4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(cu),(c,d)=>(e.openBlock(),e.createElementBlock("div",{class:"type-list",key:d},[e.createElementVNode("div",{class:"list-content",onClick:m=>r(c)},[e.createElementVNode("div",O4,[e.createVNode(h,{name:c.icon},null,8,["name"])]),e.createElementVNode("div",null,e.toDisplayString(c.name),1)],8,I4)]))),128))])}}},R4=ar._export_sfc(L4,[["__scopeId","data-v-91799bf8"]]),$4={class:"fill-content"},V4={class:"operate-content"},P4={class:"collapse-title-content"},F4={class:"collapse-title-item"},j4={key:1},H4=["onClick"],U4={class:"icon-content"},q4={key:0,class:"edit-content"},W4=["onClick"],K4={class:"comp-child"},G4={__name:"modelFill",setup(a){const l=Yn(A.pinia),{itemData:n,originalData:r}=A.storeToRefs(l),i=e.ref([]);e.ref([]);const s=e.ref([]),h=e.ref([]),c=M=>{var W;let k=(W=A.cloneDeep(h.value))==null?void 0:W.map((O,j)=>(M===j&&(O.content=!0),O));h.value=k},d=M=>{var W;let k=(W=A.cloneDeep(h.value))==null?void 0:W.map((O,j)=>(M===j&&(O.content=!1),O));h.value=k,i.value=A.cloneDeep(n.value)},m=(M,k)=>{var L;let W=(L=A.cloneDeep(h.value))==null?void 0:L.map((_,x)=>(M===x&&(_.content=!1),_));h.value=W;const O=A.cloneDeep(n.value),j=O==null?void 0:O.filter((_,x)=>(x===M&&(_.name=k),_));l.setOriginalData(j),l.setItemData(j)};e.watch(()=>n.value,()=>{var M,k,W;!n.value||((M=n.value)==null?void 0:M.length)===0?i.value=[]:i.value=(k=A.cloneDeep(n.value))==null?void 0:k.filter(O=>(O==null?void 0:O.comp)!=="methodButton"),s.value=i.value,h.value=(W=A.cloneDeep(s.value))==null?void 0:W.map((O,j)=>({id:j,content:!1}))},{deep:!0,immediate:!0});const b=M=>zi(M),u=(M,k,W)=>{var j,L;if(!M)return;let O=A.cloneDeep(n.value);O=(j=O==null?void 0:O.map((_,x)=>(x===W&&(_.compData=M),_)))==null?void 0:j.filter(_=>(_==null?void 0:_.comp)!=="methodButton"),h.value=(L=A.cloneDeep(O))==null?void 0:L.map((_,x)=>({id:x,content:!1})),l.setOriginalData(O),l.setItemData(O)},C=M=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const k=A.cloneDeep(n.value),W=k==null?void 0:k.filter((O,j)=>j!==M);l.setOriginalData(W),l.setItemData(W),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(M,k)=>{const W=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",$4,[k[1]||(k[1]=e.createElementVNode("div",{class:"fill-operate"},e.toDisplayString("操作栏"),-1)),e.createElementVNode("div",V4,[e.createVNode(ac.default,{class:"collapse-content",collapseContents:i.value},{title:e.withCtx(({item:O,index:j})=>{var L,_,x,w,g,E,P,V,ee,J;return[e.createElementVNode("div",P4,[e.createElementVNode("div",F4,[(_=(L=h.value)==null?void 0:L.find(me=>me.id===j))!=null&&_.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"collapse-title",style:e.normalizeStyle({marginRight:O.name&&O.name!==""?"8px":"0px"})},e.toDisplayString(O.name),5)),(w=(x=h.value)==null?void 0:x.find(me=>me.id===j))!=null&&w.content?(e.openBlock(),e.createElementBlock("div",j4,[e.createVNode(cl.ssInput,{modelValue:O.name,"onUpdate:modelValue":me=>O.name=me,onClick:k[0]||(k[0]=e.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):e.createCommentVNode("",!0),(E=(g=h.value)==null?void 0:g.find(me=>me.id===j))!=null&&E.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:2,onClick:e.withModifiers(me=>c(j),["stop"]),class:"icon-content"},[e.createVNode(W,{name:"Edit",style:{width:"16px",height:"16px"}})],8,H4))]),e.createElementVNode("div",U4,[(V=(P=h.value)==null?void 0:P.find(me=>me.id===j))!=null&&V.content?(e.openBlock(),e.createElementBlock("div",q4,[e.createVNode(W,{name:"Cancel",style:{width:"16px",height:"16px"},class:"icon-content",onClick:e.withModifiers(me=>d(j),["stop"])},null,8,["onClick"]),e.createVNode(W,{name:"Save",onClick:e.withModifiers(me=>m(j,O.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):e.createCommentVNode("",!0),(J=(ee=h.value)==null?void 0:ee.find(me=>me.id===j))!=null&&J.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,onClick:e.withModifiers(me=>C(j),["stop"]),class:"icon-content"},[e.createVNode(W,{name:"Delete",style:{width:"16px",height:"16px"}})],8,W4))])])]}),content:e.withCtx(({item:O,index:j})=>{var L,_;return[e.createElementVNode("div",K4,[e.createTextVNode(e.toDisplayString(b(O.comp+"Operate"))+" ",1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b(O.comp+"Operate")),{itemContents:O==null?void 0:O.compData,originalItemContents:(_=(L=s.value)==null?void 0:L.find((x,w)=>w===j))==null?void 0:_.compData,onChange:x=>u(x,O,j)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},Y4=ar._export_sfc(G4,[["__scopeId","data-v-a46a44b9"]]),J4={key:0,class:"show-content"},X4={style:{display:"flex"}},Z4={__name:"modelShow",setup(a){const l=Yn(A.pinia),{itemData:n}=A.storeToRefs(l),r=e.ref([]);e.watch(()=>n.value,()=>{var s;!n.value||((s=n.value)==null?void 0:s.length)===0?r.value=[]:r.value=A.cloneDeep(n.value)},{deep:!0,immediate:!0});const i=s=>zi(s);return(s,h)=>{var c;return((c=r.value)==null?void 0:c.length)>0?(e.openBlock(),e.createElementBlock("div",J4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(d,m)=>(e.openBlock(),e.createElementBlock("div",{class:"item-content",key:m},[e.createElementVNode("div",X4,e.toDisplayString(d.name),1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i(d.comp)),{itemData:d==null?void 0:d.compData,childItemData:d==null?void 0:d.itemChildData,key:m},null,8,["itemData","childItemData"]))]))),128))])):e.createCommentVNode("",!0)}}},Q4=ar._export_sfc(Z4,[["__scopeId","data-v-3f3e863e"]]),e2={class:"tabs-header"},a2={class:"tabs-list"},l2={class:"tab-name"},r2={class:"tab-actions"},n2=["onClick"],i2=["onClick"],o2=["onClick"],t2={class:"model-operate"},s2={class:"model-select",style:{display:"unset"}},c2={class:"existing-components"},u2={class:"component-list"},d2=["onClick"],p2={class:"component-info"},f2={class:"component-type"},h2={class:"component-name"},v2={class:"model-fill"},m2={__name:"operate",props:{itemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.ref([]),s=e.ref(!1),h=e.ref(""),c=e.ref({title:""}),d=e.ref(-1),m=e.ref(!1),b=e.ref(-1),u=e.ref(new WeakMap),C=e.ref(null),M=Yn(A.pinia),{itemData:k}=A.storeToRefs(M),W=()=>{h.value="新增标签页",c.value.title="",d.value=-1,s.value=!0},O=de=>{h.value="修改标签页",c.value.title=i.value[de].title,d.value=de,s.value=!0},j=de=>{const T=x(de);u.value.delete(T),i.value.splice(de,1),$e()},L=()=>{if(c.value.title.trim()){if(d.value===-1){const de={title:c.value.title,value:c.value.title,label:c.value.title,children:[],id:_()};i.value.push(de)}else i.value[d.value].title=c.value.title,i.value[d.value].value=c.value.title,i.value[d.value].label=c.value.title;s.value=!1,$e()}},_=()=>`tab_${Date.now()}_${Math.random().toString(36).substr(2,9)}`,x=de=>{const T=i.value[de];return T.id||(T.id=_()),T.id},w=de=>{var U;b.value=de;const T=x(de);C.value=A.cloneDeep(k.value);let ie=u.value.get(T);!ie&&((U=i.value[de].children)==null?void 0:U.length)>0&&(ie=V(i.value[de].children)),ie?M.setItemData(A.cloneDeep(ie)):M.setItemData([]),m.value=!0},g=e.computed(()=>{const de=A.useModelComp(A.pinia),T=A.storeToRefs(de).itemData.value;return console.log("可用组件数据",T),!T||!Array.isArray(T)?[]:T.filter(ie=>{var U;if(ie.comp==="Tabs"&&b.value>=0){const ge=x(b.value);if((U=ie.compData)==null?void 0:U.some(Le=>{var ra;return Le.key==="stepList"&&((ra=Le.contents)==null?void 0:ra.some(Ca=>Ca.id===ge))}))return!1}return!0})}),E=de=>({Table:"表格",Form:"表单",Tabs:"标签页",Chart:"图表",Card:"卡片"})[de]||de,P=de=>{var T;try{const ie=A.cloneDeep(de);ie.id=Date.now()+Math.random(),ie.comp==="Tabs"&&((T=ie.compData)==null||T.forEach(ge=>{ge.key==="stepList"&&ge.contents&&ge.contents.forEach(ze=>{ze.id=_()})}));const U=A.cloneDeep(k.value);U.push(ie),M.setItemData(U)}catch(ie){console.error("添加组件失败:",ie)}},V=de=>de.map(T=>{var ie;switch(T.type){case"form":return{comp:"Form",name:T.value||"表单",compData:ee(T.content)};case"table":return{comp:"Table",name:T.value||"表格",compData:J(T.content)};default:return{comp:"Unknown",name:T.value||"",compData:((ie=T.content)==null?void 0:ie.originalData)||[]}}}),ee=de=>{if(!de)return[];const T=[];return de.rowContents&&T.push({key:"formContent",contents:de.rowContents}),de.buttonValue&&T.push({key:"formButton",contents:de.buttonValue}),typeof de.isEnableWrap<"u"&&T.push({key:"enableWrap",contents:de.isEnableWrap}),T},J=de=>[],me=()=>{if(b.value>=0&&b.value<i.value.length){const de=x(b.value);u.value.set(de,A.cloneDeep(k.value)),i.value[b.value].children=ne(k.value),console.log("保存后的数据",ne(k.value))}m.value=!1,b.value=-1,C.value=null,$e()},_e=()=>{C.value&&M.setItemData(A.cloneDeep(C.value)),m.value=!1,b.value=-1,C.value=null},z=()=>{m.value&&_e()},ne=de=>{if(!Array.isArray(de))throw new Error("sourceData must be an array");return de.map((T,ie)=>{if(!T||typeof T!="object")return T;const{comp:U,name:ge,compData:ze}=T;switch(U){case"Form":return{type:"form",content:Y(ze||[]),value:"表单"};case"Table":return{type:"table",content:te(ze||[]),value:"表格"};default:return{type:"xxx",content:ye(ze||[]),value:""}}})},Y=de=>{const T={formRules:{},rowContents:[],buttonValue:[],rowValues:[],isEnableWrap:!0,isRowFlex:!0,isButtonRow:!0,isEdit:!0,isStartJustify:!0},ie={formContent:"rowContents",enableWrap:"isEnableWrap",formButton:"buttonValue"};return de.forEach((U,ge)=>{if(!U||typeof U!="object"){console.warn(`Invalid config at index ${ge}:`,U);return}const{key:ze,contents:Le}=U,ra=ie[ze];if(!ra){console.warn(`Unknown Form config key: ${ze}`);return}ze==="enableWrap"?T[ra]=!!Le:T[ra]=Array.isArray(Le)?Le:[]}),T},te=de=>{const T={columns:[],tableData:[],extraButton:[],rowButton:[],currentPage:0,total:0,pageSize:0,isShowPagination:!0,isShowEdit:!0,isMoveColumn:!0,isShowDelete:!0},ie={header:"columns",tableContents:"tableData"};return de.forEach((U,ge)=>{if(!U||typeof U!="object"){console.warn(`Invalid config at index ${ge}:`,U);return}const{key:ze,contents:Le}=U,ra=ie[ze];if(!ra){console.warn(`Unknown Table config key: ${ze}`);return}T[ra]=Array.isArray(Le)?Le:[]}),T},ye=de=>(console.log("Default conversion logic - to be implemented"),{originalData:de,processed:!1,componentType:"unknown"}),$e=()=>{const de=[{key:"stepList",contents:i.value}];r("change",de)};return e.watch(()=>n.itemContents,de=>{if(de&&de.length>0){const T=de.find(ie=>ie.key==="stepList");T&&T.contents&&(i.value=T.contents.map(ie=>({title:ie.title||"",value:ie.value||ie.title||"",label:ie.label||ie.title||"",children:ie.children||[],id:ie.id||_()})))}},{immediate:!0,deep:!0}),(de,T)=>{const ie=e.resolveComponent("svg-icon"),U=e.resolveComponent("el-input"),ge=e.resolveComponent("el-form-item"),ze=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",e2,[T[6]||(T[6]=e.createElementVNode("h4",null,"标签页管理",-1)),e.createElementVNode("button",{onClick:W},[e.createVNode(ie,{name:"Plus",style:{width:"14px",height:"14px","margin-right":"4px"}}),T[5]||(T[5]=e.createTextVNode(" 新增标签页 "))])]),e.createElementVNode("div",a2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(Le,ra)=>(e.openBlock(),e.createElementBlock("div",{class:"tab-item",key:ra},[e.createElementVNode("span",l2,e.toDisplayString(Le.title),1),e.createElementVNode("div",r2,[e.createElementVNode("button",{onClick:Ca=>O(ra)},"修改标题",8,n2),e.createElementVNode("button",{onClick:Ca=>w(ra)},"布局调整",8,i2),e.createElementVNode("button",{onClick:Ca=>j(ra)},"删除",8,o2)])]))),128))]),e.createVNode(Ar.ssDialog,{modelValue:s.value,"onUpdate:modelValue":T[2]||(T[2]=Le=>s.value=Le),title:h.value,onBeforeDestroy:T[3]||(T[3]=Le=>s.value=!1)},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:T[1]||(T[1]=Le=>s.value=!1)},"取消"),e.createElementVNode("button",{type:"primary",onClick:L},"确定")]),default:e.withCtx(()=>[e.createVNode(ze,{model:c.value,"label-width":"80px"},{default:e.withCtx(()=>[e.createVNode(ge,{label:"标签名称",required:""},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:c.value.title,"onUpdate:modelValue":T[0]||(T[0]=Le=>c.value.title=Le),placeholder:"请输入标签页名称"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue","title"]),e.createVNode(Ar.ssDialog,{modelValue:m.value,"onUpdate:modelValue":T[4]||(T[4]=Le=>m.value=Le),title:"布局调整",fullScreen:"",onBeforeDestroy:z},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:_e},"取消"),e.createElementVNode("button",{onClick:me},"确定")]),default:e.withCtx(()=>[e.createElementVNode("div",t2,[e.createElementVNode("div",s2,[e.createVNode(R4),e.createElementVNode("div",c2,[T[8]||(T[8]=e.createElementVNode("h5",null,"添加已有组件",-1)),e.createElementVNode("div",u2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,Le=>(e.openBlock(),e.createElementBlock("div",{key:Le.id,class:"component-item",onClick:ra=>P(Le)},[e.createElementVNode("div",p2,[e.createElementVNode("span",f2,e.toDisplayString(E(Le.comp)),1),e.createElementVNode("span",h2,e.toDisplayString(Le.name),1)]),T[7]||(T[7]=e.createElementVNode("button",{class:"add-btn"},"添加",-1))],8,d2))),128))])])]),(e.openBlock(),e.createElementBlock("div",{class:"model-show",key:de.innerWidth},[e.createVNode(Q4)])),e.createElementVNode("div",v2,[e.createVNode(Y4)])])]),_:1},8,["modelValue"])])}}},y2=ar._export_sfc(m2,[["__scopeId","data-v-9096ed0d"]]);function g2(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis"},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",axisLabel:{interval:0},data:[]},yAxis:{type:"value"},series:[]}}function b2(a){return{type:"line",color:["#5070DD","#B6D634","#505372","#FF994E","#0CA8DF","#FFD10A","#FB628B","#8466C1","#3EBE95"],...a}}function k2(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",data:[]},yAxis:[{type:"value"}],series:[]}}function x2(a){return{type:"bar",barWidth:"60%",showBackground:!0,backgroundStyle:{color:"rgba(180, 180, 180, 0.1)"},itemStyle:{color:new Al.LinearGradient(0,0,0,1,[{offset:0,color:"#94C2FD"},{offset:.7,color:"#6491E1"},{offset:1,color:"#3264C8"}])},emphasis:{itemStyle:{color:new Al.LinearGradient(0,0,0,1,[{offset:0,color:"#3264C8"},{offset:.7,color:"#6491E1"},{offset:1,color:"#94C2FD"}])}},...a}}function w2(){return{title:{text:"",left:"center"},tooltip:{trigger:"item"},series:[]}}function _2(a){return{type:"pie",color:["#5070DD","#B6D634","#505372","#FF994E","#0CA8DF","#FFD10A","#FB628B","#8466C1","#3EBE95"],radius:["40%","70%"],itemStyle:{borderRadius:6,borderColor:"#fff",borderWidth:2},label:{show:!0,formatter:function(l){return"{b|"+l.name+`}
|
|
26
|
-
{c|`+l.value+"}"},rich:{b:{fontFamily:"SourceHanSansSC",fontWeight:"bold",fontSize:14,color:"#333"},c:{fontFamily:"SourceHanSansSC",fontSize:12,color:"#666"},d:{fontFamily:"SourceHanSansSC",fontSize:12,color:"#999"}}},emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},...a}}const S2=()=>({title:{text:"",left:"center"},tooltip:{trigger:"item"},xAxis:{scale:!0},yAxis:{scale:!0},series:[]}),E2=a=>({type:"scatter",symbolSize:20,...a}),Cn={Line:{initBaseoptions:g2,initSeries:b2},Bar:{initBaseoptions:k2,initSeries:x2},Pie:{initBaseoptions:w2,initSeries:_2},Scatter:{initBaseoptions:S2,initSeries:E2}},C2=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:n})=>{const{type:r,title:i}=a||{},s=Cn==null?void 0:Cn[r];if(!s)return;const{initBaseoptions:h,initSeries:c}=s,d=h();d.title.text=i??"";const m=l==null?void 0:l.map(C=>C==null?void 0:C.prop);let b=[];if(m==null||m.forEach(C=>{var M;b.push((M=n==null?void 0:n[0])==null?void 0:M[C])}),!m||!b)return d;d.xAxis.data=m;const u=c({data:b});return d.series.push(u),d},D2=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:n})=>{const{type:r,title:i}=a||{},s=Cn==null?void 0:Cn[r];if(!s)return;const{initBaseoptions:h,initSeries:c}=s,d=h();d.title.text=i??"";const m=l==null?void 0:l.map(C=>C==null?void 0:C.prop);let b=[];if(m==null||m.forEach(C=>{var M;b.push((M=n==null?void 0:n[0])==null?void 0:M[C])}),!m||!b)return d;d.xAxis.data=m;const u=c({data:b});return d.series.push(u),d},T2=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:n})=>{const{type:r,title:i}=a||{},s=Cn==null?void 0:Cn[r];if(!s)return;const{initBaseoptions:h,initSeries:c}=s,d=h();d.title.text=i??"";const m=l==null?void 0:l.map(M=>M==null?void 0:M.prop);let b=[];if(m==null||m.forEach(M=>{var k;b.push((k=n==null?void 0:n[0])==null?void 0:k[M])}),!m||!b)return d;const u=[];for(let M=0;M<m.length;M++){const k=m[M],W=b[M];u.push({name:k,value:W})}const C=c({data:u});return d.series.push(C),d},B2=({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:n})=>{const{type:r,title:i}=a||{},s=Cn==null?void 0:Cn[r];if(!s)return;const{initBaseoptions:h,initSeries:c}=s,d=h();d.title.text=i??"";let m=[];const b=l==null?void 0:l.map(M=>M==null?void 0:M.prop);if(m=b==null?void 0:b.map(M=>{var W;let k=[];return k.push(M),k.push((W=n==null?void 0:n[0])==null?void 0:W[M]),k}),!m)return d;const C=c({data:m});return d.series.push(C),d},N2=async(a=[])=>{var h,c,d;const l=((h=a==null?void 0:a.find(m=>m.key==="ChartType"))==null?void 0:h.contents)??{},n=((c=a==null?void 0:a.find(m=>m.key==="header"))==null?void 0:c.contents)??[],r=((d=a==null?void 0:a.find(m=>m.key==="tableContents"))==null?void 0:d.contents)??[];let{type:i}=l,s={};return i==="Line"&&(s=await C2({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),i==="Bar"&&(s=await D2({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),i==="Pie"&&(s=await T2({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),i==="Scatter"&&(s=await B2({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),s},A2=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}},height:{type:String,default:"300px"}},setup(a){const l=a,n=e.ref({});e.onMounted(async()=>{const i=l==null?void 0:l.itemData;n.value=await N2(i)});const r=e.computed(()=>(l==null?void 0:l.height)||"300px");return(i,s)=>(e.openBlock(),e.createElementBlock("div",{class:"eCharts",style:e.normalizeStyle({height:r.value})},[e.createVNode(Lu.ssChart,{optionContents:n.value},null,8,["optionContents"])],4))}}),z2=ar._export_sfc(A2,[["__scopeId","data-v-d4c081e8"]]),M2={class:"chart-module layout"},I2={class:"chart-module content"},O2={class:"chart-module content"},L2={class:"form-content"},R2={class:"dialog-footer"},$2={class:"form-content"},V2={class:"dialog-footer"},P2={class:"form-content"},F2={class:"dialog-footer"},j2=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l,i=e.reactive({visible:!1,width:"840",title:"基础配置"}),s=e.ref([]),h=()=>[{label:"类型",prop:"type",type:"select",contents:[{label:"柱状图",value:"bar"},{label:"饼图",value:"pie"},{label:"折线图",value:"line"}],value:""},{label:"标题",prop:"title",type:"input",value:""}],c=e.ref({}),d=()=>{var Se;s.value=h(),(Se=s.value)==null||Se.forEach(ce=>{var Ke;const De=ce==null?void 0:ce.prop;ce.value=(Ke=c==null?void 0:c.value)==null?void 0:Ke[De]}),i.visible=!0},m=Se=>{c.value=Se},b=()=>{var Se;i.visible=!1,r("change",(Se=ue())==null?void 0:Se.compData)},u=e.reactive({visible:!1,width:"840",title:"数据配置"}),C=e.ref([]),M=()=>[{label:"菜单选项",prop:"menu",type:"cascader",contents:[]},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],k=e.ref({}),W=()=>{const Se=C.value,ce=A.cloneDeep(Se);return ce==null||ce.forEach(De=>{var ua;const Ke=De==null?void 0:De.prop;De.value=(ua=k.value)==null?void 0:ua[Ke]}),ce},O=Se=>{var De;k.value=Se;const ce=W();C.value=ce,r("change",(De=ue())==null?void 0:De.compData)},j=async()=>{const Se=await oe.getMenusContent(),ce=W();ce==null||ce.forEach(De=>{(De==null?void 0:De.prop)==="menu"&&(De.contents=Se)}),C.value=ce,u.visible=!0,await Le(k.value.menu),await Q(k.value.group)},L=e.reactive({visible:!1,width:"840",title:"详情页配置"}),_=e.ref([]),x=()=>[{label:"详情页主键",prop:"mainKey",type:"select",contents:[]},{label:"使用当前详情页内容",prop:"isSelfDetail",type:"switch"},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],w=e.ref({}),g=()=>{const Se=_.value,ce=A.cloneDeep(Se);return ce==null||ce.forEach(De=>{var ua;const Ke=De==null?void 0:De.prop;De.value=(ua=w.value)==null?void 0:ua[Ke]}),ce},E=Se=>{var De;w.value=Se;const ce=g();_.value=ce,r("change",(De=ue())==null?void 0:De.compData)},P=async()=>{await z();const Se=A.cloneDeep(V.value),ce=g();ce==null||ce.forEach(De=>{var ua;const Ke=De==null?void 0:De.prop;De.value=(ua=w==null?void 0:w.value)==null?void 0:ua[Ke],Ke==="mainKey"&&(De.contents=Se)}),_.value=ce,L.visible=!0},V=e.ref([]),ee=e.ref([]),J=e.ref({}),me=e.ref({}),_e=()=>{const{compData:Se}=U.value||{},ce=Se==null?void 0:Se.find(X=>{const{key:he}=X;return he==="header"}),De=(ce==null?void 0:ce.contents)||[],Ke=De==null?void 0:De.filter((X,he)=>{const{label:fe}=X;return fe!=="操作"}),ua=Ke==null?void 0:Ke.findIndex((X,he)=>{const{isMainKey:fe}=X;return fe});if(ua<0)return[];const Za=Se==null?void 0:Se.find(X=>{const{key:he}=X;return he==="tableContents"}),$=(Za==null?void 0:Za.contents)||[];return $==null?void 0:$.map(X=>{const he=X==null?void 0:X[0];let fe=ua;Wa.isObject(he)&&(he!=null&&he.id)&&(fe=fe+1);const ha=X==null?void 0:X[fe];return{label:ha,value:ha}})},z=async()=>{const Se=await _e();V.value=Se},ne=async Se=>{const ce=sessionStorage.getItem("systemKey");return await oe.getItemData(Se,ce,"")},Y=async Se=>{const ce=Se;ee.value=ce==null?void 0:ce.map(De=>{const{name:Ke}=De;return J.value[Ke]=De,{label:Ke,value:Ke}})},te=Se=>{const{comp:ce,compData:De}=me.value||{};if(ce==="Table"){let Ke=g();Ke=Ke.filter(ua=>{const{prop:Za}=ua;return Za!=="formItems"}),ra(Ke,De),_.value=Ke}},ye=async()=>{var De,Ke;const Se=(De=w==null?void 0:w.value)==null?void 0:De.mainKey,ce=(Ke=k==null?void 0:k.value)==null?void 0:Ke.menu;if(Se){const Za=`${ce==null?void 0:ce.join("/")}^${Se}`,$=await ne(Za);await Y($);const H=g();H==null||H.forEach(X=>{(X==null?void 0:X.prop)==="group"&&(X.contents=ee.value)}),_.value=H}};e.watch(()=>{var Se;return(Se=w==null?void 0:w.value)==null?void 0:Se.mainKey},async(Se,ce)=>{Se!=ce&&Se&&await ye()});const $e=async Se=>{const ce=J.value[Se];me.value=ce,await te()};e.watch(()=>{var Se;return(Se=w==null?void 0:w.value)==null?void 0:Se.group},async(Se,ce)=>{Se!=ce&&Se&&$e(Se)});const de=async()=>{var ce;await ye();const Se=(ce=w.value)==null?void 0:ce.group;await $e(Se)},T=e.ref([]),ie=e.ref({}),U=e.ref({}),ge=async Se=>{const ce=Se==null?void 0:Se.join("/"),De=sessionStorage.getItem("systemKey");return await oe.getItemData(ce,De,"")},ze=async Se=>{const ce=await ge(Se);T.value=ce==null?void 0:ce.map(De=>{const{name:Ke}=De;return ie.value[Ke]=De,{label:Ke,value:Ke}})},Le=async(Se,ce)=>{await ze(Se);const De=W();De==null||De.forEach(Ke=>{(Ke==null?void 0:Ke.prop)==="group"&&(Ke.contents=T.value)}),C.value=De};e.watch(()=>{var Se;return(Se=k==null?void 0:k.value)==null?void 0:Se.menu},async(Se,ce)=>{const De=Se==null?void 0:Se.join("/"),Ke=ce==null?void 0:ce.join("/");De!=Ke&&await Le(Se)});const ra=(Se,ce)=>{const De=ce==null?void 0:ce.find($=>{const{key:H}=$;return H==="header"}),Ke=(De==null?void 0:De.contents)||[],ua=Ke==null?void 0:Ke.filter(($,H)=>{const{label:X}=$;return X!=="操作"}),Za=ua==null?void 0:ua.map(($,H)=>{const{label:X}=$;return{label:X,value:H}});Se==null||Se.forEach($=>{const H=$==null?void 0:$.prop;(H==="nameCol"||H==="valueCol")&&($.contents=Za)})},Ca=Se=>{const{comp:ce,compData:De}=U.value||{};if(ce==="Table"){k.value.formItems=[];let Ke=W();Ke=Ke.filter(ua=>{const{prop:Za}=ua;return Za!=="formItems"}),ra(Ke,De),C.value=Ke}},Q=async Se=>{const ce=ie.value[Se];U.value=ce,await Ca()};e.watch(()=>{var Se;return(Se=k==null?void 0:k.value)==null?void 0:Se.group},async(Se,ce)=>{Se!=ce&&Q(Se)});const ca=async()=>{var De,Ke;const Se=(De=k.value)==null?void 0:De.menu;await Le(Se);const ce=(Ke=k.value)==null?void 0:Ke.group;await Q(ce)},ue=()=>({comp:"chart",compData:[{key:"chartBaseConfig",contents:c.value},{key:"chartDataConfig",contents:k.value},{key:"chartDetailConfig",contents:w.value}]}),pa=()=>{i.visible=!1,u.visible=!1,L.visible=!1};return e.onMounted(async()=>{var ce,De,Ke;C.value=M(),_.value=x();const Se=n==null?void 0:n.itemContents;c.value=((ce=Se==null?void 0:Se.find(ua=>ua.key==="chartBaseConfig"))==null?void 0:ce.contents)??{},k.value=((De=Se==null?void 0:Se.find(ua=>ua.key==="chartDataConfig"))==null?void 0:De.contents)??{},await ca(),w.value=((Ke=Se==null?void 0:Se.find(ua=>ua.key==="chartDetailConfig"))==null?void 0:Ke.contents)??{},await de()}),(Se,ce)=>{const De=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",M2,[ce[4]||(ce[4]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createVNode(De,{id:"themeButton",onClick:ce[0]||(ce[0]=Ke=>d())},{default:e.withCtx(()=>ce[3]||(ce[3]=[e.createTextVNode(" 修改 ")])),_:1,__:[3]})]),e.createElementVNode("div",I2,[ce[6]||(ce[6]=e.createElementVNode("h4",{class:"module-title"},"数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:ce[1]||(ce[1]=Ke=>j())},{default:e.withCtx(()=>ce[5]||(ce[5]=[e.createTextVNode(" 修改 ")])),_:1,__:[5]})]),e.createElementVNode("div",O2,[ce[8]||(ce[8]=e.createElementVNode("h4",{class:"module-title"},"详情数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:ce[2]||(ce[2]=Ke=>P())},{default:e.withCtx(()=>ce[7]||(ce[7]=[e.createTextVNode(" 修改 ")])),_:1,__:[7]})])]),e.createVNode(Ar.ssDialog,{visible:i.visible,title:i.title,onBeforeDestroy:pa,width:i.width},{default:e.withCtx(()=>[e.createElementVNode("div",L2,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!0,onChange:m},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",R2,[e.createVNode(De,{class:"cancel-button button",onClick:pa,id:"themeBorderButton"},{default:e.withCtx(()=>ce[9]||(ce[9]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[9]}),e.createVNode(De,{class:"ok-button button",onClick:b,id:"themeButton"},{default:e.withCtx(()=>ce[10]||(ce[10]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[10]})])]),_:1},8,["visible","title","width"]),e.createVNode(Ar.ssDialog,{visible:u.visible,title:u.title,onBeforeDestroy:pa,width:u.width},{default:e.withCtx(()=>[e.createElementVNode("div",$2,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:C.value,key:C.value,isEnableWrap:!0,onChange:O},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",V2,[e.createVNode(De,{class:"cancel-button button",onClick:pa,id:"themeBorderButton"},{default:e.withCtx(()=>ce[11]||(ce[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(De,{class:"ok-button button",onClick:pa,id:"themeButton"},{default:e.withCtx(()=>ce[12]||(ce[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible","title","width"]),e.createVNode(Ar.ssDialog,{visible:L.visible,title:L.title,onBeforeDestroy:pa,width:L.width},{default:e.withCtx(()=>[e.createElementVNode("div",P2,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:_.value,key:_.value,isEnableWrap:!0,onChange:E},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",F2,[e.createVNode(De,{class:"cancel-button button",onClick:pa,id:"themeBorderButton"},{default:e.withCtx(()=>ce[13]||(ce[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(De,{class:"ok-button button",onClick:pa,id:"themeButton"},{default:e.withCtx(()=>ce[14]||(ce[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible","title","width"])],64)}}}),H2=ar._export_sfc(j2,[["__scopeId","data-v-fe119645"]]),U2={class:"layout"},q2=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}}},emits:["rowClick"],setup(a,{emit:l}){const n=l,r=a;e.onMounted(async()=>{});const i=e.computed(()=>A.cloneDeep(r==null?void 0:r.itemData)||[]),s=e.computed(()=>{var b;const m=(b=i==null?void 0:i.value)==null?void 0:b.find(u=>{const{key:C}=u;return C==="baseConfig"});return m==null?void 0:m.contents}),h=e.computed(()=>{var b;const m=(b=i==null?void 0:i.value)==null?void 0:b.find(u=>{const{key:C}=u;return C==="children"});return m==null?void 0:m.contents}),c=e.computed(()=>{let m=A.cloneDeep(h.value)||[];const b=m.length;let u=0;const C=[];if(m=m.map(M=>{const k=M.span;return k?(M.span=Number(k),u=u+M.span):C.push(M),M}),u<24){const M=Math.floor((24-u)/b);C.forEach(k=>{k.span=M})}return m}),d=m=>{n("rowClick",m)};return(m,b)=>{var M;const u=e.resolveComponent("el-col"),C=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",U2,[e.createVNode(C,{style:e.normalizeStyle({height:(M=s.value)==null?void 0:M.height})},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(k,W)=>(e.openBlock(),e.createBlock(u,{span:k==null?void 0:k.span},{default:e.withCtx(()=>{var O;return[e.unref(Ai)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Zi)(k.comp)),{key:e.unref(Gn),compName:k.name,index:(k==null?void 0:k.id)??W,height:(O=s.value)==null?void 0:O.height,itemData:k==null?void 0:k.compData,childItemData:k==null?void 0:k.itemChildData,onChange:e.unref(Io),onContentChange:e.unref(Oo),onPageChange:e.unref(Lo),onRowClick:d},null,40,["compName","index","height","itemData","childItemData","onChange","onContentChange","onPageChange"])):e.createCommentVNode("",!0)]}),_:2},1032,["span"]))),256))]),_:1},8,["style"])])}}}),W2=ar._export_sfc(q2,[["__scopeId","data-v-ab9a36ed"]]),K2={class:"layout-operate"},G2={class:"layout-module"},Y2={class:"collapse-title-item"},J2={class:"collapse-title"},X2={class:"icon-content"},Z2=["onClick"],Q2={class:"comp-child"},e1=e.defineComponent({__name:"operate",props:{itemContents:{type:Object,default:()=>{}},originalItemContents:{type:Array,default:()=>[]},itemChildData:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const n=a,r=l;e.onMounted(()=>{W()});const i=e.ref({}),s=e.ref({}),h=e.ref([]),c=w=>[{label:"高度",prop:"height",type:"input",value:w==null?void 0:w.height}],d=w=>{s.value=w,r("change",x(),!0)},m=e.ref([]),b=e.ref([]),u=w=>[{label:"占比",prop:"span",type:"input",value:w==null?void 0:w.span}],C=e.computed(()=>{const w=n==null?void 0:n.itemContents;return A.cloneDeep(w)}),M=e.computed(()=>{const w=C==null?void 0:C.value,g=w==null?void 0:w.find(E=>{const{key:P}=E;return P==="baseConfig"});return g==null?void 0:g.contents}),k=e.computed(()=>{const w=C==null?void 0:C.value,g=w==null?void 0:w.find(E=>{const{key:P}=E;return P==="children"});return g==null?void 0:g.contents}),W=()=>{var w;i.value=C.value||{},m.value=(k==null?void 0:k.value)||[],h.value=c(),h.value=(w=h.value)==null?void 0:w.map(g=>{var P;const{prop:E}=g;return g.value=(P=M.value)==null?void 0:P[E],g})};e.watch(()=>{var w;return(w=k==null?void 0:k.value)==null?void 0:w.length},()=>{var w;m.value=(k==null?void 0:k.value)||[],b.value=(w=k.value)==null?void 0:w.map(g=>u(g))},{immediate:!0});const O=(w,g)=>{const E=A.cloneDeep(k==null?void 0:k.value);E[g].span=w.span,m.value=E,r("change",x(),!0)},j=w=>zi(w),L=(w,g,E)=>{if(!w)return;const P=A.cloneDeep(k==null?void 0:k.value);P[E]&&(P[E].compData=w,m.value=P,r("change",x(),!0))},_=w=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{let g=A.cloneDeep(k==null?void 0:k.value);g=g==null?void 0:g.filter((E,P)=>w!==P),m.value=g,r("change",x(),!0),Wa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=()=>({compData:[{key:"baseConfig",contents:s.value},{key:"children",contents:m==null?void 0:m.value}]});return(w,g)=>{const E=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",K2,[e.createElementVNode("div",G2,[g[1]||(g[1]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createElementVNode("div",null,[e.createVNode(cl.ssForm,{rowContents:h.value,isEnableWrap:!0,onChange:g[0]||(g[0]=P=>d(P))},null,8,["rowContents"])])]),e.createVNode(ac.default,{class:"collapse-content",collapseContents:k.value},{title:e.withCtx(({item:P,index:V})=>[e.createElementVNode("div",Y2,[e.createElementVNode("div",J2,e.toDisplayString(P.name),1),e.createElementVNode("div",X2,[e.createElementVNode("div",{onClick:e.withModifiers(ee=>_(V),["stop"]),class:"icon-content"},[e.createVNode(E,{name:"Delete",style:{width:"16px",height:"16px"}})],8,Z2)])])]),content:e.withCtx(({item:P,index:V})=>[e.createElementVNode("div",Q2,[e.createElementVNode("div",null,[(e.openBlock(),e.createBlock(cl.ssForm,{rowContents:b.value[V],key:V,isEnableWrap:!0,onChange:ee=>O(ee,V)},null,8,["rowContents","onChange"]))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(j(P.comp+"Operate")),{itemContents:P==null?void 0:P.compData,originalItemContents:P.compData,onChange:ee=>L(ee,P,V)},null,40,["itemContents","originalItemContents","onChange"]))])]),_:1},8,["collapseContents"])])}}}),a1=ar._export_sfc(e1,[["__scopeId","data-v-ba05456e"]]),l1=typeof window<"u";var Ts;l1&&((Ts=window==null?void 0:window.navigator)!=null&&Ts.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function xn(a){return a==null}function Hc(){}const r1=Object.freeze({aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"});Object.freeze(new Set(Object.keys(r1)));function n1(){const a=new Map;return{on(l,n){const r=a.get(l);r!=null&&r.add(n)||a.set(l,new Set([n]))},off(l,n){const r=a.get(l);r&&r.delete(n)},clear(l){const n=a.get(l);n&&n.clear()},clearAll(){a.clear()},emit(l,...n){const r=a.get(l);r&&r.forEach(i=>{i(...n)})}}}function Bs(a,l=16){if(typeof a!="function")return Hc;const n=(...s)=>{a(...s)};if(l<=0)return Uc(n);let r=0,i;return function(...s){const h=Date.now(),c=h-r;clearTimeout(i),c>=l?(r=h,n(...s)):i=setTimeout(()=>{r=Date.now(),n(...s)},Math.max(0,l-c))}}function i1(a,l=100){if(typeof a!="function")return Hc;const n=(...i)=>{a(...i)};if(l<=0)return Uc(n);let r;return function(...i){clearTimeout(r),r=setTimeout(()=>{n(...i)},l)}}function Uc(a){if(typeof a!="function")return a;let l=!1,n,r;return function(...i){return n=i,l||(l=!0,r=Promise.resolve().then(()=>(l=!1,r=void 0,a(...n)))),r}}const Gi=new Set,qc=new WeakMap;function o1(){Gi.forEach(a=>{a(...qc.get(a))}),Gi.clear()}function dn(a,...l){if(typeof a!="function")return a;qc.set(a,l),!Gi.has(a)&&(Gi.add(a),Gi.size===1&&Promise.resolve().then(o1))}const Wc=Symbol("LAYOUT_KEY"),Kc=Symbol("EMITTER_KEY");function s1(a){let l=0,n;for(let r=0,i=a.length;r<i;r++)n=a[r].y+a[r].h,n>l&&(l=n);return l}function Bt(a){const l=Array(a.length);for(let n=0,r=a.length;n<r;n++)l[n]=c1(a[n]);return l}function c1(a){return{...a}}function Gc(a,l){return!(a===l||a.x+a.w<=l.x||a.x>=l.x+l.w||a.y+a.h<=l.y||a.y>=l.y+l.h)}function Ci(a,l,n){const r=Jc(a),i=Xc(a),s=Array(a.length);for(let h=0,c=i.length;h<c;h++){let d=i[h];d.static||(d=u1(r,d,l,n),r.push(d)),s[a.findIndex(m=>m.i===d.i)]=d,d.moved=!1}return s}function u1(a,l,n,r){if(n)for(;l.y>0&&!Yi(a,l);)l.y--;else if(r){const s=r[l.i].y;for(;l.y>s&&!Yi(a,l);)l.y--}let i;for(;i=Yi(a,l);)l.y=i.y+i.h;return l}function d1(a,l){const n=Jc(a);for(let r=0,i=a.length;r<i;r++){const s=a[r];if(s.x+s.w>l.cols&&(s.x=l.cols-s.w),s.x<0&&(s.x=0,s.w=l.cols),!s.static)n.push(s);else for(;Yi(n,s);)s.y++}return a}function Ns(a,l){for(let n=0,r=a.length;n<r;n++)if(a[n].i===l)return a[n]}function Yi(a,l){for(let n=0,r=a.length;n<r;n++)if(Gc(a[n],l))return a[n]}function Yc(a,l){return a.filter(n=>Gc(n,l))}function Jc(a){return a.filter(l=>l.static)}function Nt(a,l,n,r,i=!1,s=!1){if(l.static)return a;const h=l.x,c=l.y,d=r&&l.y>r;typeof n=="number"&&(l.x=n),typeof r=="number"&&(l.y=r),l.moved=!0;let m=Xc(a);d&&(m=m.reverse());const b=Yc(m,l);if(s&&b.length)return l.x=h,l.y=c,l.moved=!1,a;for(let u=0,C=b.length;u<C;u++){const M=b[u];M.moved||l.y>M.y&&l.y-M.y>M.h/4||(M.static?a=As(a,M,l,i):a=As(a,l,M,i))}return a}function As(a,l,n,r){if(r){const i={x:n.x,y:n.y,w:n.w,h:n.h};if(i.y=Math.max(l.y-n.h,0),!Yi(a,i))return Nt(a,n,void 0,i.y,!1)}return Nt(a,n,void 0,n.y+1,!1)}function p1(a,l,n,r){const i="translate3d("+l+"px,"+a+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:n+"px",height:r+"px",position:"absolute"}}function f1(a,l,n,r){const i="translate3d("+l*-1+"px,"+a+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:n+"px",height:r+"px",position:"absolute"}}function h1(a,l,n,r){return{top:a+"px",left:l+"px",width:n+"px",height:r+"px",position:"absolute"}}function v1(a,l,n,r){return{top:a+"px",right:l+"px",width:n+"px",height:r+"px",position:"absolute"}}function Xc(a){return Array.from(a).sort(function(l,n){return l.y===n.y&&l.x===n.x?0:l.y>n.y||l.y===n.y&&l.x>n.x?1:-1})}function m1(a,l){l=l||"Layout";const n=["x","y","w","h"],r=[];if(!Array.isArray(a))throw new Error(l+" must be an array!");for(let i=0,s=a.length;i<s;i++){const h=a[i];for(let c=0;c<n.length;c++)if(typeof h[n[c]]!="number")throw new Error("VueGridLayout: "+l+"["+i+"]."+n[c]+" must be a number!");if(h.i===void 0||h.i===null)throw new Error("VueGridLayout: "+l+"["+i+"].i cannot be null!");if(typeof h.i!="number"&&typeof h.i!="string")throw new Error("VueGridLayout: "+l+"["+i+"].i must be a string or number!");if(r.indexOf(h.i)>=0)throw new Error("VueGridLayout: "+l+"["+i+"].i must be unique!");if(r.push(h.i),h.static!==void 0&&typeof h.static!="boolean")throw new Error("VueGridLayout: "+l+"["+i+"].static must be a boolean!")}}function y1(a,l="vgl"){const n=()=>`${l}-${a}`;return{b:n,be:r=>`${n()}__${r}`,bm:r=>`${n()}--${r}`,bem:(r,i)=>`${n()}__${r}--${i}`}}function zs(a){return g1(a)}function g1(a){var l;const n=((l=a.target)==null?void 0:l.offsetParent)||document.body,r=a.offsetParent===document.body?{left:0,top:0}:n.getBoundingClientRect(),i=a.clientX+n.scrollLeft-r.left,s=a.clientY+n.scrollTop-r.top;return{x:i,y:s}}function Ms(a,l,n,r){return b1(a)?{deltaX:n-a,deltaY:r-l,lastX:a,lastY:l,x:n,y:r}:{deltaX:0,deltaY:0,lastX:n,lastY:r,x:n,y:r}}function b1(a){return typeof a=="number"&&!Number.isNaN(a)}function k1(a,l){const n=Qc(a);let r=n[0];for(let i=1,s=n.length;i<s;i++){const h=n[i];l>a[h]&&(r=h)}return r}function Zc(a,l){if(!l[a])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+a+" is missing!");return l[a]}function x1(a,l,n,r,i,s,h){if(l[r])return Bt(l[r]);let c=a;const d=Qc(n),m=d.slice(d.indexOf(r));for(let b=0,u=m.length;b<u;b++){const C=m[b];if(l[C]){c=l[C];break}}return c=Bt(c||[]),Ci(d1(c,{cols:s}),h)}function Qc(a){return Object.keys(a).sort((l,n)=>a[l]-a[n])}let w1="auto";function _1(){return typeof document<"u"}function Is(){return _1()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir"):w1}var Wi={exports:{}},S1=Wi.exports,Os;function E1(){return Os||(Os=1,function(a,l){(function(n,r){a.exports=r()})(S1,function(){function n(t,o){var f=Object.keys(t);if(Object.getOwnPropertySymbols){var y=Object.getOwnPropertySymbols(t);o&&(y=y.filter(function(S){return Object.getOwnPropertyDescriptor(t,S).enumerable})),f.push.apply(f,y)}return f}function r(t){for(var o=1;o<arguments.length;o++){var f=arguments[o]!=null?arguments[o]:{};o%2?n(Object(f),!0).forEach(function(y){d(t,y,f[y])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(f)):n(Object(f)).forEach(function(y){Object.defineProperty(t,y,Object.getOwnPropertyDescriptor(f,y))})}return t}function i(t){return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(o){return typeof o}:function(o){return o&&typeof Symbol=="function"&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},i(t)}function s(t,o){if(!(t instanceof o))throw new TypeError("Cannot call a class as a function")}function h(t,o){for(var f=0;f<o.length;f++){var y=o[f];y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y&&(y.writable=!0),Object.defineProperty(t,W(y.key),y)}}function c(t,o,f){return o&&h(t.prototype,o),Object.defineProperty(t,"prototype",{writable:!1}),t}function d(t,o,f){return(o=W(o))in t?Object.defineProperty(t,o,{value:f,enumerable:!0,configurable:!0,writable:!0}):t[o]=f,t}function m(t,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(o&&o.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),o&&u(t,o)}function b(t){return b=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(o){return o.__proto__||Object.getPrototypeOf(o)},b(t)}function u(t,o){return u=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,y){return f.__proto__=y,f},u(t,o)}function C(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function M(t){var o=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}();return function(){var f,y=b(t);if(o){var S=b(this).constructor;f=Reflect.construct(y,arguments,S)}else f=y.apply(this,arguments);return function(R,K){if(K&&(typeof K=="object"||typeof K=="function"))return K;if(K!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return C(R)}(this,f)}}function k(){return k=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(t,o,f){var y=function(R,K){for(;!Object.prototype.hasOwnProperty.call(R,K)&&(R=b(R))!==null;);return R}(t,o);if(y){var S=Object.getOwnPropertyDescriptor(y,o);return S.get?S.get.call(arguments.length<3?t:f):S.value}},k.apply(this,arguments)}function W(t){var o=function(f,y){if(typeof f!="object"||f===null)return f;var S=f[Symbol.toPrimitive];if(S!==void 0){var R=S.call(f,y);if(typeof R!="object")return R;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(f)}(t,"string");return typeof o=="symbol"?o:o+""}var O=function(t){return!(!t||!t.Window)&&t instanceof t.Window},j=void 0,L=void 0;function _(t){j=t;var o=t.document.createTextNode("");o.ownerDocument!==t.document&&typeof t.wrap=="function"&&t.wrap(o)===o&&(t=t.wrap(t)),L=t}function x(t){return O(t)?t:(t.ownerDocument||t).defaultView||L.window}typeof window<"u"&&window&&_(window);var w=function(t){return!!t&&i(t)==="object"},g=function(t){return typeof t=="function"},E={window:function(t){return t===L||O(t)},docFrag:function(t){return w(t)&&t.nodeType===11},object:w,func:g,number:function(t){return typeof t=="number"},bool:function(t){return typeof t=="boolean"},string:function(t){return typeof t=="string"},element:function(t){if(!t||i(t)!=="object")return!1;var o=x(t)||L;return/object|function/.test(typeof Element>"u"?"undefined":i(Element))?t instanceof Element||t instanceof o.Element:t.nodeType===1&&typeof t.nodeName=="string"},plainObject:function(t){return w(t)&&!!t.constructor&&/function Object\b/.test(t.constructor.toString())},array:function(t){return w(t)&&t.length!==void 0&&g(t.splice)}};function P(t){var o=t.interaction;if(o.prepared.name==="drag"){var f=o.prepared.axis;f==="x"?(o.coords.cur.page.y=o.coords.start.page.y,o.coords.cur.client.y=o.coords.start.client.y,o.coords.velocity.client.y=0,o.coords.velocity.page.y=0):f==="y"&&(o.coords.cur.page.x=o.coords.start.page.x,o.coords.cur.client.x=o.coords.start.client.x,o.coords.velocity.client.x=0,o.coords.velocity.page.x=0)}}function V(t){var o=t.iEvent,f=t.interaction;if(f.prepared.name==="drag"){var y=f.prepared.axis;if(y==="x"||y==="y"){var S=y==="x"?"y":"x";o.page[S]=f.coords.start.page[S],o.client[S]=f.coords.start.client[S],o.delta[S]=0}}}var ee={id:"actions/drag",install:function(t){var o=t.actions,f=t.Interactable,y=t.defaults;f.prototype.draggable=ee.draggable,o.map.drag=ee,o.methodDict.drag="draggable",y.actions.drag=ee.defaults},listeners:{"interactions:before-action-move":P,"interactions:action-resume":P,"interactions:action-move":V,"auto-start:check":function(t){var o=t.interaction,f=t.interactable,y=t.buttons,S=f.options.drag;if(S&&S.enabled&&(!o.pointerIsDown||!/mouse|pointer/.test(o.pointerType)||(y&f.options.drag.mouseButtons)!=0))return t.action={name:"drag",axis:S.lockAxis==="start"?S.startAxis:S.lockAxis},!1}},draggable:function(t){return E.object(t)?(this.options.drag.enabled=t.enabled!==!1,this.setPerAction("drag",t),this.setOnEvents("drag",t),/^(xy|x|y|start)$/.test(t.lockAxis)&&(this.options.drag.lockAxis=t.lockAxis),/^(xy|x|y)$/.test(t.startAxis)&&(this.options.drag.startAxis=t.startAxis),this):E.bool(t)?(this.options.drag.enabled=t,this):this.options.drag},beforeMove:P,move:V,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor:function(){return"move"},filterEventType:function(t){return t.search("drag")===0}},J=ee,me={init:function(t){var o=t;me.document=o.document,me.DocumentFragment=o.DocumentFragment||_e,me.SVGElement=o.SVGElement||_e,me.SVGSVGElement=o.SVGSVGElement||_e,me.SVGElementInstance=o.SVGElementInstance||_e,me.Element=o.Element||_e,me.HTMLElement=o.HTMLElement||me.Element,me.Event=o.Event,me.Touch=o.Touch||_e,me.PointerEvent=o.PointerEvent||o.MSPointerEvent},document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function _e(){}var z=me,ne={init:function(t){var o=z.Element,f=t.navigator||{};ne.supportsTouch="ontouchstart"in t||E.func(t.DocumentTouch)&&z.document instanceof t.DocumentTouch,ne.supportsPointerEvent=f.pointerEnabled!==!1&&!!z.PointerEvent,ne.isIOS=/iP(hone|od|ad)/.test(f.platform),ne.isIOS7=/iP(hone|od|ad)/.test(f.platform)&&/OS 7[^\d]/.test(f.appVersion),ne.isIe9=/MSIE 9/.test(f.userAgent),ne.isOperaMobile=f.appName==="Opera"&&ne.supportsTouch&&/Presto/.test(f.userAgent),ne.prefixedMatchesSelector="matches"in o.prototype?"matches":"webkitMatchesSelector"in o.prototype?"webkitMatchesSelector":"mozMatchesSelector"in o.prototype?"mozMatchesSelector":"oMatchesSelector"in o.prototype?"oMatchesSelector":"msMatchesSelector",ne.pEventTypes=ne.supportsPointerEvent?z.PointerEvent===t.MSPointerEvent?{up:"MSPointerUp",down:"MSPointerDown",over:"mouseover",out:"mouseout",move:"MSPointerMove",cancel:"MSPointerCancel"}:{up:"pointerup",down:"pointerdown",over:"pointerover",out:"pointerout",move:"pointermove",cancel:"pointercancel"}:null,ne.wheelEvent=z.document&&"onmousewheel"in z.document?"mousewheel":"wheel"},supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null},Y=ne;function te(t,o){if(t.contains)return t.contains(o);for(;o;){if(o===t)return!0;o=o.parentNode}return!1}function ye(t,o){for(;E.element(t);){if(de(t,o))return t;t=$e(t)}return null}function $e(t){var o=t.parentNode;if(E.docFrag(o)){for(;(o=o.host)&&E.docFrag(o););return o}return o}function de(t,o){return L!==j&&(o=o.replace(/\/deep\//g," ")),t[Y.prefixedMatchesSelector](o)}var T=function(t){return t.parentNode||t.host};function ie(t,o){for(var f,y=[],S=t;(f=T(S))&&S!==o&&f!==S.ownerDocument;)y.unshift(S),S=f;return y}function U(t,o,f){for(;E.element(t);){if(de(t,o))return!0;if((t=$e(t))===f)return de(t,o)}return!1}function ge(t){return t.correspondingUseElement||t}function ze(t){var o=t instanceof z.SVGElement?t.getBoundingClientRect():t.getClientRects()[0];return o&&{left:o.left,right:o.right,top:o.top,bottom:o.bottom,width:o.width||o.right-o.left,height:o.height||o.bottom-o.top}}function Le(t){var o,f=ze(t);if(!Y.isIOS7&&f){var y={x:(o=(o=x(t))||L).scrollX||o.document.documentElement.scrollLeft,y:o.scrollY||o.document.documentElement.scrollTop};f.left+=y.x,f.right+=y.x,f.top+=y.y,f.bottom+=y.y}return f}function ra(t){for(var o=[];t;)o.push(t),t=$e(t);return o}function Ca(t){return!!E.string(t)&&(z.document.querySelector(t),!0)}function Q(t,o){for(var f in o)t[f]=o[f];return t}function ca(t,o,f){return t==="parent"?$e(f):t==="self"?o.getRect(f):ye(f,t)}function ue(t,o,f,y){var S=t;return E.string(S)?S=ca(S,o,f):E.func(S)&&(S=S.apply(void 0,y)),E.element(S)&&(S=Le(S)),S}function pa(t){return t&&{x:"x"in t?t.x:t.left,y:"y"in t?t.y:t.top}}function Se(t){return!t||"x"in t&&"y"in t||((t=Q({},t)).x=t.left||0,t.y=t.top||0,t.width=t.width||(t.right||0)-t.x,t.height=t.height||(t.bottom||0)-t.y),t}function ce(t,o,f){t.left&&(o.left+=f.x),t.right&&(o.right+=f.x),t.top&&(o.top+=f.y),t.bottom&&(o.bottom+=f.y),o.width=o.right-o.left,o.height=o.bottom-o.top}function De(t,o,f){var y=f&&t.options[f];return pa(ue(y&&y.origin||t.options.origin,t,o,[t&&o]))||{x:0,y:0}}function Ke(t,o){var f=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(ke){return!0},y=arguments.length>3?arguments[3]:void 0;if(y=y||{},E.string(t)&&t.search(" ")!==-1&&(t=ua(t)),E.array(t))return t.forEach(function(ke){return Ke(ke,o,f,y)}),y;if(E.object(t)&&(o=t,t=""),E.func(o)&&f(t))y[t]=y[t]||[],y[t].push(o);else if(E.array(o))for(var S=0,R=o;S<R.length;S++){var K=R[S];Ke(t,K,f,y)}else if(E.object(o))for(var Z in o)Ke(ua(Z).map(function(ke){return"".concat(t).concat(ke)}),o[Z],f,y);return y}function ua(t){return t.trim().split(/ +/)}var Za=function(t,o){return Math.sqrt(t*t+o*o)},$=["webkit","moz"];function H(t,o){t.__set||(t.__set={});var f=function(S){if($.some(function(R){return S.indexOf(R)===0}))return 1;typeof t[S]!="function"&&S!=="__set"&&Object.defineProperty(t,S,{get:function(){return S in t.__set?t.__set[S]:t.__set[S]=o[S]},set:function(R){t.__set[S]=R},configurable:!0})};for(var y in o)f(y);return t}function X(t,o){t.page=t.page||{},t.page.x=o.page.x,t.page.y=o.page.y,t.client=t.client||{},t.client.x=o.client.x,t.client.y=o.client.y,t.timeStamp=o.timeStamp}function he(t){t.page.x=0,t.page.y=0,t.client.x=0,t.client.y=0}function fe(t){return t instanceof z.Event||t instanceof z.Touch}function ha(t,o,f){return t=t||"page",(f=f||{}).x=o[t+"X"],f.y=o[t+"Y"],f}function ta(t,o){return o=o||{x:0,y:0},Y.isOperaMobile&&fe(t)?(ha("screen",t,o),o.x+=window.scrollX,o.y+=window.scrollY):ha("page",t,o),o}function Fe(t){return E.number(t.pointerId)?t.pointerId:t.identifier}function xa(t,o,f){var y=o.length>1?va(o):o[0];ta(y,t.page),function(S,R){R=R||{},Y.isOperaMobile&&fe(S)?ha("screen",S,R):ha("client",S,R)}(y,t.client),t.timeStamp=f}function Ae(t){var o=[];return E.array(t)?(o[0]=t[0],o[1]=t[1]):t.type==="touchend"?t.touches.length===1?(o[0]=t.touches[0],o[1]=t.changedTouches[0]):t.touches.length===0&&(o[0]=t.changedTouches[0],o[1]=t.changedTouches[1]):(o[0]=t.touches[0],o[1]=t.touches[1]),o}function va(t){for(var o={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0},f=0;f<t.length;f++){var y=t[f];for(var S in o)o[S]+=y[S]}for(var R in o)o[R]/=t.length;return o}function La(t){if(!t.length)return null;var o=Ae(t),f=Math.min(o[0].pageX,o[1].pageX),y=Math.min(o[0].pageY,o[1].pageY),S=Math.max(o[0].pageX,o[1].pageX),R=Math.max(o[0].pageY,o[1].pageY);return{x:f,y,left:f,top:y,right:S,bottom:R,width:S-f,height:R-y}}function Ia(t,o){var f=o+"X",y=o+"Y",S=Ae(t),R=S[0][f]-S[1][f],K=S[0][y]-S[1][y];return Za(R,K)}function fa(t,o){var f=o+"X",y=o+"Y",S=Ae(t),R=S[1][f]-S[0][f],K=S[1][y]-S[0][y];return 180*Math.atan2(K,R)/Math.PI}function Ba(t){return E.string(t.pointerType)?t.pointerType:E.number(t.pointerType)?[void 0,void 0,"touch","pen","mouse"][t.pointerType]:/touch/.test(t.type||"")||t instanceof z.Touch?"touch":"mouse"}function Te(t){var o=E.func(t.composedPath)?t.composedPath():t.path;return[ge(o?o[0]:t.target),ge(t.currentTarget)]}var be=function(){function t(o){s(this,t),this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=o}return c(t,[{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),t}();Object.defineProperty(be.prototype,"interaction",{get:function(){return this._interaction._proxy},set:function(){}});var Be=function(t,o){for(var f=0;f<o.length;f++){var y=o[f];t.push(y)}return t},ae=function(t){return Be([],t)},se=function(t,o){for(var f=0;f<t.length;f++)if(o(t[f],f,t))return f;return-1},Xe=function(t,o){return t[se(t,o)]},Ze=function(t){m(f,t);var o=M(f);function f(y,S,R){var K;s(this,f),(K=o.call(this,S._interaction)).dropzone=void 0,K.dragEvent=void 0,K.relatedTarget=void 0,K.draggable=void 0,K.propagationStopped=!1,K.immediatePropagationStopped=!1;var Z=R==="dragleave"?y.prev:y.cur,ke=Z.element,je=Z.dropzone;return K.type=R,K.target=ke,K.currentTarget=ke,K.dropzone=je,K.dragEvent=S,K.relatedTarget=S.target,K.draggable=S.interactable,K.timeStamp=S.timeStamp,K}return c(f,[{key:"reject",value:function(){var y=this,S=this._interaction.dropState;if(this.type==="dropactivate"||this.dropzone&&S.cur.dropzone===this.dropzone&&S.cur.element===this.target)if(S.prev.dropzone=this.dropzone,S.prev.element=this.target,S.rejected=!0,S.events.enter=null,this.stopImmediatePropagation(),this.type==="dropactivate"){var R=S.activeDrops,K=se(R,function(ke){var je=ke.dropzone,Ee=ke.element;return je===y.dropzone&&Ee===y.target});S.activeDrops.splice(K,1);var Z=new f(S,this.dragEvent,"dropdeactivate");Z.dropzone=this.dropzone,Z.target=this.target,this.dropzone.fire(Z)}else this.dropzone.fire(new f(S,this.dragEvent,"dragleave"))}},{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),f}(be);function Ha(t,o){for(var f=0,y=t.slice();f<y.length;f++){var S=y[f],R=S.dropzone,K=S.element;o.dropzone=R,o.target=K,R.fire(o),o.propagationStopped=o.immediatePropagationStopped=!1}}function _a(t,o){for(var f=function(R,K){for(var Z=[],ke=0,je=R.interactables.list;ke<je.length;ke++){var Ee=je[ke];if(Ee.options.drop.enabled){var ia=Ee.options.drop.accept;if(!(E.element(ia)&&ia!==K||E.string(ia)&&!de(K,ia)||E.func(ia)&&!ia({dropzone:Ee,draggableElement:K})))for(var Ta=0,el=Ee.getAllElements();Ta<el.length;Ta++){var Ja=el[Ta];Ja!==K&&Z.push({dropzone:Ee,element:Ja,rect:Ee.getRect(Ja)})}}}return Z}(t,o),y=0;y<f.length;y++){var S=f[y];S.rect=S.dropzone.getRect(S.element)}return f}function Qa(t,o,f){for(var y=t.dropState,S=t.interactable,R=t.element,K=[],Z=0,ke=y.activeDrops;Z<ke.length;Z++){var je=ke[Z],Ee=je.dropzone,ia=je.element,Ta=je.rect,el=Ee.dropCheck(o,f,S,R,ia,Ta);K.push(el?ia:null)}var Ja=function(ol){for(var El,bl,Ml,Kl=[],Ol=0;Ol<ol.length;Ol++){var Pl=ol[Ol],Vl=ol[El];if(Pl&&Ol!==El)if(Vl){var rn=T(Pl),tr=T(Vl);if(rn!==Pl.ownerDocument)if(tr!==Pl.ownerDocument)if(rn!==tr){Kl=Kl.length?Kl:ie(Vl);var un=void 0;if(Vl instanceof z.HTMLElement&&Pl instanceof z.SVGElement&&!(Pl instanceof z.SVGSVGElement)){if(Pl===tr)continue;un=Pl.ownerSVGElement}else un=Pl;for(var kn=ie(un,Vl.ownerDocument),Tn=0;kn[Tn]&&kn[Tn]===Kl[Tn];)Tn++;var bi=[kn[Tn-1],kn[Tn],Kl[Tn]];if(bi[0])for(var ii=bi[0].lastChild;ii;){if(ii===bi[1]){El=Ol,Kl=kn;break}if(ii===bi[2])break;ii=ii.previousSibling}}else Ml=Vl,(parseInt(x(bl=Pl).getComputedStyle(bl).zIndex,10)||0)>=(parseInt(x(Ml).getComputedStyle(Ml).zIndex,10)||0)&&(El=Ol);else El=Ol}else El=Ol}return El}(K);return y.activeDrops[Ja]||null}function Pe(t,o,f){var y=t.dropState,S={enter:null,leave:null,activate:null,deactivate:null,move:null,drop:null};return f.type==="dragstart"&&(S.activate=new Ze(y,f,"dropactivate"),S.activate.target=null,S.activate.dropzone=null),f.type==="dragend"&&(S.deactivate=new Ze(y,f,"dropdeactivate"),S.deactivate.target=null,S.deactivate.dropzone=null),y.rejected||(y.cur.element!==y.prev.element&&(y.prev.dropzone&&(S.leave=new Ze(y,f,"dragleave"),f.dragLeave=S.leave.target=y.prev.element,f.prevDropzone=S.leave.dropzone=y.prev.dropzone),y.cur.dropzone&&(S.enter=new Ze(y,f,"dragenter"),f.dragEnter=y.cur.element,f.dropzone=y.cur.dropzone)),f.type==="dragend"&&y.cur.dropzone&&(S.drop=new Ze(y,f,"drop"),f.dropzone=y.cur.dropzone,f.relatedTarget=y.cur.element),f.type==="dragmove"&&y.cur.dropzone&&(S.move=new Ze(y,f,"dropmove"),f.dropzone=y.cur.dropzone)),S}function Re(t,o){var f=t.dropState,y=f.activeDrops,S=f.cur,R=f.prev;o.leave&&R.dropzone.fire(o.leave),o.enter&&S.dropzone.fire(o.enter),o.move&&S.dropzone.fire(o.move),o.drop&&S.dropzone.fire(o.drop),o.deactivate&&Ha(y,o.deactivate),f.prev.dropzone=S.dropzone,f.prev.element=S.element}function Ue(t,o){var f=t.interaction,y=t.iEvent,S=t.event;if(y.type==="dragmove"||y.type==="dragend"){var R=f.dropState;o.dynamicDrop&&(R.activeDrops=_a(o,f.element));var K=y,Z=Qa(f,K,S);R.rejected=R.rejected&&!!Z&&Z.dropzone===R.cur.dropzone&&Z.element===R.cur.element,R.cur.dropzone=Z&&Z.dropzone,R.cur.element=Z&&Z.element,R.events=Pe(f,0,K)}}var Ne={id:"actions/drop",install:function(t){var o=t.actions,f=t.interactStatic,y=t.Interactable,S=t.defaults;t.usePlugin(J),y.prototype.dropzone=function(R){return function(K,Z){if(E.object(Z)){if(K.options.drop.enabled=Z.enabled!==!1,Z.listeners){var ke=Ke(Z.listeners),je=Object.keys(ke).reduce(function(ia,Ta){return ia[/^(enter|leave)/.test(Ta)?"drag".concat(Ta):/^(activate|deactivate|move)/.test(Ta)?"drop".concat(Ta):Ta]=ke[Ta],ia},{}),Ee=K.options.drop.listeners;Ee&&K.off(Ee),K.on(je),K.options.drop.listeners=je}return E.func(Z.ondrop)&&K.on("drop",Z.ondrop),E.func(Z.ondropactivate)&&K.on("dropactivate",Z.ondropactivate),E.func(Z.ondropdeactivate)&&K.on("dropdeactivate",Z.ondropdeactivate),E.func(Z.ondragenter)&&K.on("dragenter",Z.ondragenter),E.func(Z.ondragleave)&&K.on("dragleave",Z.ondragleave),E.func(Z.ondropmove)&&K.on("dropmove",Z.ondropmove),/^(pointer|center)$/.test(Z.overlap)?K.options.drop.overlap=Z.overlap:E.number(Z.overlap)&&(K.options.drop.overlap=Math.max(Math.min(1,Z.overlap),0)),"accept"in Z&&(K.options.drop.accept=Z.accept),"checker"in Z&&(K.options.drop.checker=Z.checker),K}return E.bool(Z)?(K.options.drop.enabled=Z,K):K.options.drop}(this,R)},y.prototype.dropCheck=function(R,K,Z,ke,je,Ee){return function(ia,Ta,el,Ja,ol,El,bl){var Ml=!1;if(!(bl=bl||ia.getRect(El)))return!!ia.options.drop.checker&&ia.options.drop.checker(Ta,el,Ml,ia,El,Ja,ol);var Kl=ia.options.drop.overlap;if(Kl==="pointer"){var Ol=De(Ja,ol,"drag"),Pl=ta(Ta);Pl.x+=Ol.x,Pl.y+=Ol.y;var Vl=Pl.x>bl.left&&Pl.x<bl.right,rn=Pl.y>bl.top&&Pl.y<bl.bottom;Ml=Vl&&rn}var tr=Ja.getRect(ol);if(tr&&Kl==="center"){var un=tr.left+tr.width/2,kn=tr.top+tr.height/2;Ml=un>=bl.left&&un<=bl.right&&kn>=bl.top&&kn<=bl.bottom}return tr&&E.number(Kl)&&(Ml=Math.max(0,Math.min(bl.right,tr.right)-Math.max(bl.left,tr.left))*Math.max(0,Math.min(bl.bottom,tr.bottom)-Math.max(bl.top,tr.top))/(tr.width*tr.height)>=Kl),ia.options.drop.checker&&(Ml=ia.options.drop.checker(Ta,el,Ml,ia,El,Ja,ol)),Ml}(this,R,K,Z,ke,je,Ee)},f.dynamicDrop=function(R){return E.bool(R)?(t.dynamicDrop=R,f):t.dynamicDrop},Q(o.phaselessTypes,{dragenter:!0,dragleave:!0,dropactivate:!0,dropdeactivate:!0,dropmove:!0,drop:!0}),o.methodDict.drop="dropzone",t.dynamicDrop=!1,S.actions.drop=Ne.defaults},listeners:{"interactions:before-action-start":function(t){var o=t.interaction;o.prepared.name==="drag"&&(o.dropState={cur:{dropzone:null,element:null},prev:{dropzone:null,element:null},rejected:null,events:null,activeDrops:[]})},"interactions:after-action-start":function(t,o){var f=t.interaction,y=(t.event,t.iEvent);if(f.prepared.name==="drag"){var S=f.dropState;S.activeDrops=[],S.events={},S.activeDrops=_a(o,f.element),S.events=Pe(f,0,y),S.events.activate&&(Ha(S.activeDrops,S.events.activate),o.fire("actions/drop:start",{interaction:f,dragEvent:y}))}},"interactions:action-move":Ue,"interactions:after-action-move":function(t,o){var f=t.interaction,y=t.iEvent;if(f.prepared.name==="drag"){var S=f.dropState;Re(f,S.events),o.fire("actions/drop:move",{interaction:f,dragEvent:y}),S.events={}}},"interactions:action-end":function(t,o){if(t.interaction.prepared.name==="drag"){var f=t.interaction,y=t.iEvent;Ue(t,o),Re(f,f.dropState.events),o.fire("actions/drop:end",{interaction:f,dragEvent:y})}},"interactions:stop":function(t){var o=t.interaction;if(o.prepared.name==="drag"){var f=o.dropState;f&&(f.activeDrops=null,f.events=null,f.cur.dropzone=null,f.cur.element=null,f.prev.dropzone=null,f.prev.element=null,f.rejected=!1)}}},getActiveDrops:_a,getDrop:Qa,getDropEvents:Pe,fireDropEvents:Re,filterEventType:function(t){return t.search("drag")===0||t.search("drop")===0},defaults:{enabled:!1,accept:null,overlap:"pointer"}},Ie=Ne;function ul(t){var o=t.interaction,f=t.iEvent,y=t.phase;if(o.prepared.name==="gesture"){var S=o.pointers.map(function(je){return je.pointer}),R=y==="start",K=y==="end",Z=o.interactable.options.deltaSource;if(f.touches=[S[0],S[1]],R)f.distance=Ia(S,Z),f.box=La(S),f.scale=1,f.ds=0,f.angle=fa(S,Z),f.da=0,o.gesture.startDistance=f.distance,o.gesture.startAngle=f.angle;else if(K||o.pointers.length<2){var ke=o.prevEvent;f.distance=ke.distance,f.box=ke.box,f.scale=ke.scale,f.ds=0,f.angle=ke.angle,f.da=0}else f.distance=Ia(S,Z),f.box=La(S),f.scale=f.distance/o.gesture.startDistance,f.angle=fa(S,Z),f.ds=f.scale-o.gesture.scale,f.da=f.angle-o.gesture.angle;o.gesture.distance=f.distance,o.gesture.angle=f.angle,E.number(f.scale)&&f.scale!==1/0&&!isNaN(f.scale)&&(o.gesture.scale=f.scale)}}var _l={id:"actions/gesture",before:["actions/drag","actions/resize"],install:function(t){var o=t.actions,f=t.Interactable,y=t.defaults;f.prototype.gesturable=function(S){return E.object(S)?(this.options.gesture.enabled=S.enabled!==!1,this.setPerAction("gesture",S),this.setOnEvents("gesture",S),this):E.bool(S)?(this.options.gesture.enabled=S,this):this.options.gesture},o.map.gesture=_l,o.methodDict.gesture="gesturable",y.actions.gesture=_l.defaults},listeners:{"interactions:action-start":ul,"interactions:action-move":ul,"interactions:action-end":ul,"interactions:new":function(t){t.interaction.gesture={angle:0,distance:0,scale:1,startAngle:0,startDistance:0}},"auto-start:check":function(t){if(!(t.interaction.pointers.length<2)){var o=t.interactable.options.gesture;if(o&&o.enabled)return t.action={name:"gesture"},!1}}},defaults:{},getCursor:function(){return""},filterEventType:function(t){return t.search("gesture")===0}},Tl=_l;function jl(t,o,f,y,S,R,K){if(!o)return!1;if(o===!0){var Z=E.number(R.width)?R.width:R.right-R.left,ke=E.number(R.height)?R.height:R.bottom-R.top;if(K=Math.min(K,Math.abs((t==="left"||t==="right"?Z:ke)/2)),Z<0&&(t==="left"?t="right":t==="right"&&(t="left")),ke<0&&(t==="top"?t="bottom":t==="bottom"&&(t="top")),t==="left"){var je=Z>=0?R.left:R.right;return f.x<je+K}if(t==="top"){var Ee=ke>=0?R.top:R.bottom;return f.y<Ee+K}if(t==="right")return f.x>(Z>=0?R.right:R.left)-K;if(t==="bottom")return f.y>(ke>=0?R.bottom:R.top)-K}return!!E.element(y)&&(E.element(o)?o===y:U(y,o,S))}function Cl(t){var o=t.iEvent,f=t.interaction;if(f.prepared.name==="resize"&&f.resizeAxes){var y=o;f.interactable.options.resize.square?(f.resizeAxes==="y"?y.delta.x=y.delta.y:y.delta.y=y.delta.x,y.axes="xy"):(y.axes=f.resizeAxes,f.resizeAxes==="x"?y.delta.y=0:f.resizeAxes==="y"&&(y.delta.x=0))}}var Yl,aa,Ka={id:"actions/resize",before:["actions/drag"],install:function(t){var o=t.actions,f=t.browser,y=t.Interactable,S=t.defaults;Ka.cursors=function(R){return R.isIe9?{x:"e-resize",y:"s-resize",xy:"se-resize",top:"n-resize",left:"w-resize",bottom:"s-resize",right:"e-resize",topleft:"se-resize",bottomright:"se-resize",topright:"ne-resize",bottomleft:"ne-resize"}:{x:"ew-resize",y:"ns-resize",xy:"nwse-resize",top:"ns-resize",left:"ew-resize",bottom:"ns-resize",right:"ew-resize",topleft:"nwse-resize",bottomright:"nwse-resize",topright:"nesw-resize",bottomleft:"nesw-resize"}}(f),Ka.defaultMargin=f.supportsTouch||f.supportsPointerEvent?20:10,y.prototype.resizable=function(R){return function(K,Z,ke){return E.object(Z)?(K.options.resize.enabled=Z.enabled!==!1,K.setPerAction("resize",Z),K.setOnEvents("resize",Z),E.string(Z.axis)&&/^x$|^y$|^xy$/.test(Z.axis)?K.options.resize.axis=Z.axis:Z.axis===null&&(K.options.resize.axis=ke.defaults.actions.resize.axis),E.bool(Z.preserveAspectRatio)?K.options.resize.preserveAspectRatio=Z.preserveAspectRatio:E.bool(Z.square)&&(K.options.resize.square=Z.square),K):E.bool(Z)?(K.options.resize.enabled=Z,K):K.options.resize}(this,R,t)},o.map.resize=Ka,o.methodDict.resize="resizable",S.actions.resize=Ka.defaults},listeners:{"interactions:new":function(t){t.interaction.resizeAxes="xy"},"interactions:action-start":function(t){(function(o){var f=o.iEvent,y=o.interaction;if(y.prepared.name==="resize"&&y.prepared.edges){var S=f,R=y.rect;y._rects={start:Q({},R),corrected:Q({},R),previous:Q({},R),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},S.edges=y.prepared.edges,S.rect=y._rects.corrected,S.deltaRect=y._rects.delta}})(t),Cl(t)},"interactions:action-move":function(t){(function(o){var f=o.iEvent,y=o.interaction;if(y.prepared.name==="resize"&&y.prepared.edges){var S=f,R=y.interactable.options.resize.invert,K=R==="reposition"||R==="negate",Z=y.rect,ke=y._rects,je=ke.start,Ee=ke.corrected,ia=ke.delta,Ta=ke.previous;if(Q(Ta,Ee),K){if(Q(Ee,Z),R==="reposition"){if(Ee.top>Ee.bottom){var el=Ee.top;Ee.top=Ee.bottom,Ee.bottom=el}if(Ee.left>Ee.right){var Ja=Ee.left;Ee.left=Ee.right,Ee.right=Ja}}}else Ee.top=Math.min(Z.top,je.bottom),Ee.bottom=Math.max(Z.bottom,je.top),Ee.left=Math.min(Z.left,je.right),Ee.right=Math.max(Z.right,je.left);for(var ol in Ee.width=Ee.right-Ee.left,Ee.height=Ee.bottom-Ee.top,Ee)ia[ol]=Ee[ol]-Ta[ol];S.edges=y.prepared.edges,S.rect=Ee,S.deltaRect=ia}})(t),Cl(t)},"interactions:action-end":function(t){var o=t.iEvent,f=t.interaction;if(f.prepared.name==="resize"&&f.prepared.edges){var y=o;y.edges=f.prepared.edges,y.rect=f._rects.corrected,y.deltaRect=f._rects.delta}},"auto-start:check":function(t){var o=t.interaction,f=t.interactable,y=t.element,S=t.rect,R=t.buttons;if(S){var K=Q({},o.coords.cur.page),Z=f.options.resize;if(Z&&Z.enabled&&(!o.pointerIsDown||!/mouse|pointer/.test(o.pointerType)||(R&Z.mouseButtons)!=0)){if(E.object(Z.edges)){var ke={left:!1,right:!1,top:!1,bottom:!1};for(var je in ke)ke[je]=jl(je,Z.edges[je],K,o._latestPointer.eventTarget,y,S,Z.margin||Ka.defaultMargin);ke.left=ke.left&&!ke.right,ke.top=ke.top&&!ke.bottom,(ke.left||ke.right||ke.top||ke.bottom)&&(t.action={name:"resize",edges:ke})}else{var Ee=Z.axis!=="y"&&K.x>S.right-Ka.defaultMargin,ia=Z.axis!=="x"&&K.y>S.bottom-Ka.defaultMargin;(Ee||ia)&&(t.action={name:"resize",axes:(Ee?"x":"")+(ia?"y":"")})}return!t.action&&void 0}}}},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor:function(t){var o=t.edges,f=t.axis,y=t.name,S=Ka.cursors,R=null;if(f)R=S[y+f];else if(o){for(var K="",Z=0,ke=["top","bottom","left","right"];Z<ke.length;Z++){var je=ke[Z];o[je]&&(K+=je)}R=S[K]}return R},filterEventType:function(t){return t.search("resize")===0},defaultMargin:null},ma=Ka,il={id:"actions",install:function(t){t.usePlugin(Tl),t.usePlugin(ma),t.usePlugin(J),t.usePlugin(Ie)}},Aa=0,sl={request:function(t){return Yl(t)},cancel:function(t){return aa(t)},init:function(t){if(Yl=t.requestAnimationFrame,aa=t.cancelAnimationFrame,!Yl)for(var o=["ms","moz","webkit","o"],f=0;f<o.length;f++){var y=o[f];Yl=t["".concat(y,"RequestAnimationFrame")],aa=t["".concat(y,"CancelAnimationFrame")]||t["".concat(y,"CancelRequestAnimationFrame")]}Yl=Yl&&Yl.bind(t),aa=aa&&aa.bind(t),Yl||(Yl=function(S){var R=Date.now(),K=Math.max(0,16-(R-Aa)),Z=t.setTimeout(function(){S(R+K)},K);return Aa=R+K,Z},aa=function(S){return clearTimeout(S)})}},rl={defaults:{enabled:!1,margin:60,container:null,speed:300},now:Date.now,interaction:null,i:0,x:0,y:0,isScrolling:!1,prevTime:0,margin:0,speed:0,start:function(t){rl.isScrolling=!0,sl.cancel(rl.i),t.autoScroll=rl,rl.interaction=t,rl.prevTime=rl.now(),rl.i=sl.request(rl.scroll)},stop:function(){rl.isScrolling=!1,rl.interaction&&(rl.interaction.autoScroll=null),sl.cancel(rl.i)},scroll:function(){var t=rl.interaction,o=t.interactable,f=t.element,y=t.prepared.name,S=o.options[y].autoScroll,R=qe(S.container,o,f),K=rl.now(),Z=(K-rl.prevTime)/1e3,ke=S.speed*Z;if(ke>=1){var je={x:rl.x*ke,y:rl.y*ke};if(je.x||je.y){var Ee=Ga(R);E.window(R)?R.scrollBy(je.x,je.y):R&&(R.scrollLeft+=je.x,R.scrollTop+=je.y);var ia=Ga(R),Ta={x:ia.x-Ee.x,y:ia.y-Ee.y};(Ta.x||Ta.y)&&o.fire({type:"autoscroll",target:f,interactable:o,delta:Ta,interaction:t,container:R})}rl.prevTime=K}rl.isScrolling&&(sl.cancel(rl.i),rl.i=sl.request(rl.scroll))},check:function(t,o){var f;return(f=t.options[o].autoScroll)==null?void 0:f.enabled},onInteractionMove:function(t){var o=t.interaction,f=t.pointer;if(o.interacting()&&rl.check(o.interactable,o.prepared.name))if(o.simulation)rl.x=rl.y=0;else{var y,S,R,K,Z=o.interactable,ke=o.element,je=o.prepared.name,Ee=Z.options[je].autoScroll,ia=qe(Ee.container,Z,ke);if(E.window(ia))K=f.clientX<rl.margin,y=f.clientY<rl.margin,S=f.clientX>ia.innerWidth-rl.margin,R=f.clientY>ia.innerHeight-rl.margin;else{var Ta=ze(ia);K=f.clientX<Ta.left+rl.margin,y=f.clientY<Ta.top+rl.margin,S=f.clientX>Ta.right-rl.margin,R=f.clientY>Ta.bottom-rl.margin}rl.x=S?1:K?-1:0,rl.y=R?1:y?-1:0,rl.isScrolling||(rl.margin=Ee.margin,rl.speed=Ee.speed,rl.start(o))}}};function qe(t,o,f){return(E.string(t)?ca(t,o,f):t)||x(f)}function Ga(t){return E.window(t)&&(t=window.document.body),{x:t.scrollLeft,y:t.scrollTop}}var hl={id:"auto-scroll",install:function(t){var o=t.defaults,f=t.actions;t.autoScroll=rl,rl.now=function(){return t.now()},f.phaselessTypes.autoscroll=!0,o.perAction.autoScroll=rl.defaults},listeners:{"interactions:new":function(t){t.interaction.autoScroll=null},"interactions:destroy":function(t){t.interaction.autoScroll=null,rl.stop(),rl.interaction&&(rl.interaction=null)},"interactions:stop":rl.stop,"interactions:action-move":function(t){return rl.onInteractionMove(t)}}},pe=hl;function na(t,o){var f=!1;return function(){return f||(L.console.warn(o),f=!0),t.apply(this,arguments)}}function Sa(t,o){return t.name=o.name,t.axis=o.axis,t.edges=o.edges,t}function la(t){return E.bool(t)?(this.options.styleCursor=t,this):t===null?(delete this.options.styleCursor,this):this.options.styleCursor}function nl(t){return E.func(t)?(this.options.actionChecker=t,this):t===null?(delete this.options.actionChecker,this):this.options.actionChecker}var Je={id:"auto-start/interactableMethods",install:function(t){var o=t.Interactable;o.prototype.getAction=function(f,y,S,R){var K=function(Z,ke,je,Ee,ia){var Ta=Z.getRect(Ee),el=ke.buttons||{0:1,1:4,3:8,4:16}[ke.button],Ja={action:null,interactable:Z,interaction:je,element:Ee,rect:Ta,buttons:el};return ia.fire("auto-start:check",Ja),Ja.action}(this,y,S,R,t);return this.options.actionChecker?this.options.actionChecker(f,y,K,this,R,S):K},o.prototype.ignoreFrom=na(function(f){return this._backCompatOption("ignoreFrom",f)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),o.prototype.allowFrom=na(function(f){return this._backCompatOption("allowFrom",f)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),o.prototype.actionChecker=nl,o.prototype.styleCursor=la}};function Fa(t,o,f,y,S){return o.testIgnoreAllow(o.options[t.name],f,y)&&o.options[t.name].enabled&&Ra(o,f,t,S)?t:null}function wa(t,o,f,y,S,R,K){for(var Z=0,ke=y.length;Z<ke;Z++){var je=y[Z],Ee=S[Z],ia=je.getAction(o,f,t,Ee);if(ia){var Ta=Fa(ia,je,Ee,R,K);if(Ta)return{action:Ta,interactable:je,element:Ee}}}return{action:null,interactable:null,element:null}}function Oa(t,o,f,y,S){var R=[],K=[],Z=y;function ke(Ee){R.push(Ee),K.push(Z)}for(;E.element(Z);){R=[],K=[],S.interactables.forEachMatch(Z,ke);var je=wa(t,o,f,R,K,y,S);if(je.action&&!je.interactable.options[je.action.name].manualStart)return je;Z=$e(Z)}return{action:null,interactable:null,element:null}}function Me(t,o,f){var y=o.action,S=o.interactable,R=o.element;y=y||{name:null},t.interactable=S,t.element=R,Sa(t.prepared,y),t.rect=S&&y.name?S.getRect(R):null,We(t,f),f.fire("autoStart:prepared",{interaction:t})}function Ra(t,o,f,y){var S=t.options,R=S[f.name].max,K=S[f.name].maxPerElement,Z=y.autoStart.maxInteractions,ke=0,je=0,Ee=0;if(!(R&&K&&Z))return!1;for(var ia=0,Ta=y.interactions.list;ia<Ta.length;ia++){var el=Ta[ia],Ja=el.prepared.name;if(el.interacting()&&(++ke>=Z||el.interactable===t&&((je+=Ja===f.name?1:0)>=R||el.element===o&&(Ee++,Ja===f.name&&Ee>=K))))return!1}return Z>0}function Va(t,o){return E.number(t)?(o.autoStart.maxInteractions=t,this):o.autoStart.maxInteractions}function Bl(t,o,f){var y=f.autoStart.cursorElement;y&&y!==t&&(y.style.cursor=""),t.ownerDocument.documentElement.style.cursor=o,t.style.cursor=o,f.autoStart.cursorElement=o?t:null}function We(t,o){var f=t.interactable,y=t.element,S=t.prepared;if(t.pointerType==="mouse"&&f&&f.options.styleCursor){var R="";if(S.name){var K=f.options[S.name].cursorChecker;R=E.func(K)?K(S,f,y,t._interacting):o.actions.map[S.name].getCursor(S)}Bl(t.element,R||"",o)}else o.autoStart.cursorElement&&Bl(o.autoStart.cursorElement,"",o)}var Ma={id:"auto-start/base",before:["actions"],install:function(t){var o=t.interactStatic,f=t.defaults;t.usePlugin(Je),f.base.actionChecker=null,f.base.styleCursor=!0,Q(f.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),o.maxInteractions=function(y){return Va(y,t)},t.autoStart={maxInteractions:1/0,withinInteractionLimit:Ra,cursorElement:null}},listeners:{"interactions:down":function(t,o){var f=t.interaction,y=t.pointer,S=t.event,R=t.eventTarget;f.interacting()||Me(f,Oa(f,y,S,R,o),o)},"interactions:move":function(t,o){(function(f,y){var S=f.interaction,R=f.pointer,K=f.event,Z=f.eventTarget;S.pointerType!=="mouse"||S.pointerIsDown||S.interacting()||Me(S,Oa(S,R,K,Z,y),y)})(t,o),function(f,y){var S=f.interaction;if(S.pointerIsDown&&!S.interacting()&&S.pointerWasMoved&&S.prepared.name){y.fire("autoStart:before-start",f);var R=S.interactable,K=S.prepared.name;K&&R&&(R.options[K].manualStart||!Ra(R,S.element,S.prepared,y)?S.stop():(S.start(S.prepared,R,S.element),We(S,y)))}}(t,o)},"interactions:stop":function(t,o){var f=t.interaction,y=f.interactable;y&&y.options.styleCursor&&Bl(f.element,"",o)}},maxInteractions:Va,withinInteractionLimit:Ra,validateAction:Fa},Sl=Ma,pr={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":function(t,o){var f=t.interaction,y=t.eventTarget,S=t.dx,R=t.dy;if(f.prepared.name==="drag"){var K=Math.abs(S),Z=Math.abs(R),ke=f.interactable.options.drag,je=ke.startAxis,Ee=K>Z?"x":K<Z?"y":"xy";if(f.prepared.axis=ke.lockAxis==="start"?Ee[0]:ke.lockAxis,Ee!=="xy"&&je!=="xy"&&je!==Ee){f.prepared.name=null;for(var ia=y,Ta=function(Ja){if(Ja!==f.interactable){var ol=f.interactable.options.drag;if(!ol.manualStart&&Ja.testIgnoreAllow(ol,ia,y)){var El=Ja.getAction(f.downPointer,f.downEvent,f,ia);if(El&&El.name==="drag"&&function(bl,Ml){if(!Ml)return!1;var Kl=Ml.options.drag.startAxis;return bl==="xy"||Kl==="xy"||Kl===bl}(Ee,Ja)&&Sl.validateAction(El,Ja,ia,y,o))return Ja}}};E.element(ia);){var el=o.interactables.forEachMatch(ia,Ta);if(el){f.prepared.name="drag",f.interactable=el,f.element=ia;break}ia=$e(ia)}}}}}};function ga(t){var o=t.prepared&&t.prepared.name;if(!o)return null;var f=t.interactable.options;return f[o].hold||f[o].delay}var Zl={id:"auto-start/hold",install:function(t){var o=t.defaults;t.usePlugin(Sl),o.perAction.hold=0,o.perAction.delay=0},listeners:{"interactions:new":function(t){t.interaction.autoStartHoldTimer=null},"autoStart:prepared":function(t){var o=t.interaction,f=ga(o);f>0&&(o.autoStartHoldTimer=setTimeout(function(){o.start(o.prepared,o.interactable,o.element)},f))},"interactions:move":function(t){var o=t.interaction,f=t.duplicate;o.autoStartHoldTimer&&o.pointerWasMoved&&!f&&(clearTimeout(o.autoStartHoldTimer),o.autoStartHoldTimer=null)},"autoStart:before-start":function(t){var o=t.interaction;ga(o)>0&&(o.prepared.name=null)}},getHoldDuration:ga},Sr=Zl,Cr={id:"auto-start",install:function(t){t.usePlugin(Sl),t.usePlugin(Sr),t.usePlugin(pr)}},Oe=function(t){return/^(always|never|auto)$/.test(t)?(this.options.preventDefault=t,this):E.bool(t)?(this.options.preventDefault=t?"always":"never",this):this.options.preventDefault};function lr(t){var o=t.interaction,f=t.event;o.interactable&&o.interactable.checkAndPreventDefault(f)}var br={id:"core/interactablePreventDefault",install:function(t){var o=t.Interactable;o.prototype.preventDefault=Oe,o.prototype.checkAndPreventDefault=function(f){return function(y,S,R){var K=y.options.preventDefault;if(K!=="never")if(K!=="always"){if(S.events.supportsPassive&&/^touch(start|move)$/.test(R.type)){var Z=x(R.target).document,ke=S.getDocOptions(Z);if(!ke||!ke.events||ke.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(R.type)||E.element(R.target)&&de(R.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||R.preventDefault()}else R.preventDefault()}(this,t,f)},t.interactions.docEvents.push({type:"dragstart",listener:function(f){for(var y=0,S=t.interactions.list;y<S.length;y++){var R=S[y];if(R.element&&(R.element===f.target||te(R.element,f.target)))return void R.interactable.checkAndPreventDefault(f)}}})},listeners:["down","move","up","cancel"].reduce(function(t,o){return t["interactions:".concat(o)]=lr,t},{})};function Dr(t,o){if(o.phaselessTypes[t])return!0;for(var f in o.map)if(t.indexOf(f)===0&&t.substr(f.length)in o.phases)return!0;return!1}function zl(t){var o={};for(var f in t){var y=t[f];E.plainObject(y)?o[f]=zl(y):E.array(y)?o[f]=ae(y):o[f]=y}return o}var $r=function(){function t(o){s(this,t),this.states=[],this.startOffset={left:0,right:0,top:0,bottom:0},this.startDelta=void 0,this.result=void 0,this.endResult=void 0,this.startEdges=void 0,this.edges=void 0,this.interaction=void 0,this.interaction=o,this.result=Ur(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}return c(t,[{key:"start",value:function(o,f){var y,S,R=o.phase,K=this.interaction,Z=function(je){var Ee=je.interactable.options[je.prepared.name],ia=Ee.modifiers;return ia&&ia.length?ia:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(function(Ta){var el=Ee[Ta];return el&&el.enabled&&{options:el,methods:el._methods}}).filter(function(Ta){return!!Ta})}(K);this.prepareStates(Z),this.startEdges=Q({},K.edges),this.edges=Q({},this.startEdges),this.startOffset=(y=K.rect,S=f,y?{left:S.x-y.left,top:S.y-y.top,right:y.right-S.x,bottom:y.bottom-S.y}:{left:0,top:0,right:0,bottom:0}),this.startDelta={x:0,y:0};var ke=this.fillArg({phase:R,pageCoords:f,preEnd:!1});return this.result=Ur(),this.startAll(ke),this.result=this.setAll(ke)}},{key:"fillArg",value:function(o){var f=this.interaction;return o.interaction=f,o.interactable=f.interactable,o.element=f.element,o.rect||(o.rect=f.rect),o.edges||(o.edges=this.startEdges),o.startOffset=this.startOffset,o}},{key:"startAll",value:function(o){for(var f=0,y=this.states;f<y.length;f++){var S=y[f];S.methods.start&&(o.state=S,S.methods.start(o))}}},{key:"setAll",value:function(o){var f=o.phase,y=o.preEnd,S=o.skipModifiers,R=o.rect,K=o.edges;o.coords=Q({},o.pageCoords),o.rect=Q({},R),o.edges=Q({},K);for(var Z=S?this.states.slice(S):this.states,ke=Ur(o.coords,o.rect),je=0;je<Z.length;je++){var Ee,ia=Z[je],Ta=ia.options,el=Q({},o.coords),Ja=null;(Ee=ia.methods)!=null&&Ee.set&&this.shouldDo(Ta,y,f)&&(o.state=ia,Ja=ia.methods.set(o),ce(o.edges,o.rect,{x:o.coords.x-el.x,y:o.coords.y-el.y})),ke.eventProps.push(Ja)}Q(this.edges,o.edges),ke.delta.x=o.coords.x-o.pageCoords.x,ke.delta.y=o.coords.y-o.pageCoords.y,ke.rectDelta.left=o.rect.left-R.left,ke.rectDelta.right=o.rect.right-R.right,ke.rectDelta.top=o.rect.top-R.top,ke.rectDelta.bottom=o.rect.bottom-R.bottom;var ol=this.result.coords,El=this.result.rect;if(ol&&El){var bl=ke.rect.left!==El.left||ke.rect.right!==El.right||ke.rect.top!==El.top||ke.rect.bottom!==El.bottom;ke.changed=bl||ol.x!==ke.coords.x||ol.y!==ke.coords.y}return ke}},{key:"applyToInteraction",value:function(o){var f=this.interaction,y=o.phase,S=f.coords.cur,R=f.coords.start,K=this.result,Z=this.startDelta,ke=K.delta;y==="start"&&Q(this.startDelta,K.delta);for(var je=0,Ee=[[R,Z],[S,ke]];je<Ee.length;je++){var ia=Ee[je],Ta=ia[0],el=ia[1];Ta.page.x+=el.x,Ta.page.y+=el.y,Ta.client.x+=el.x,Ta.client.y+=el.y}var Ja=this.result.rectDelta,ol=o.rect||f.rect;ol.left+=Ja.left,ol.right+=Ja.right,ol.top+=Ja.top,ol.bottom+=Ja.bottom,ol.width=ol.right-ol.left,ol.height=ol.bottom-ol.top}},{key:"setAndApply",value:function(o){var f=this.interaction,y=o.phase,S=o.preEnd,R=o.skipModifiers,K=this.setAll(this.fillArg({preEnd:S,phase:y,pageCoords:o.modifiedCoords||f.coords.cur.page}));if(this.result=K,!K.changed&&(!R||R<this.states.length)&&f.interacting())return!1;if(o.modifiedCoords){var Z=f.coords.cur.page,ke={x:o.modifiedCoords.x-Z.x,y:o.modifiedCoords.y-Z.y};K.coords.x+=ke.x,K.coords.y+=ke.y,K.delta.x+=ke.x,K.delta.y+=ke.y}this.applyToInteraction(o)}},{key:"beforeEnd",value:function(o){var f=o.interaction,y=o.event,S=this.states;if(S&&S.length){for(var R=!1,K=0;K<S.length;K++){var Z=S[K];o.state=Z;var ke=Z.options,je=Z.methods,Ee=je.beforeEnd&&je.beforeEnd(o);if(Ee)return this.endResult=Ee,!1;R=R||!R&&this.shouldDo(ke,!0,o.phase,!0)}R&&f.move({event:y,preEnd:!0})}}},{key:"stop",value:function(o){var f=o.interaction;if(this.states&&this.states.length){var y=Q({states:this.states,interactable:f.interactable,element:f.element,rect:null},o);this.fillArg(y);for(var S=0,R=this.states;S<R.length;S++){var K=R[S];y.state=K,K.methods.stop&&K.methods.stop(y)}this.states=null,this.endResult=null}}},{key:"prepareStates",value:function(o){this.states=[];for(var f=0;f<o.length;f++){var y=o[f],S=y.options,R=y.methods,K=y.name;this.states.push({options:S,methods:R,index:f,name:K})}return this.states}},{key:"restoreInteractionCoords",value:function(o){var f=o.interaction,y=f.coords,S=f.rect,R=f.modification;if(R.result){for(var K=R.startDelta,Z=R.result,ke=Z.delta,je=Z.rectDelta,Ee=0,ia=[[y.start,K],[y.cur,ke]];Ee<ia.length;Ee++){var Ta=ia[Ee],el=Ta[0],Ja=Ta[1];el.page.x-=Ja.x,el.page.y-=Ja.y,el.client.x-=Ja.x,el.client.y-=Ja.y}S.left-=je.left,S.right-=je.right,S.top-=je.top,S.bottom-=je.bottom}}},{key:"shouldDo",value:function(o,f,y,S){return!(!o||o.enabled===!1||S&&!o.endOnly||o.endOnly&&!f||y==="start"&&!o.setStart)}},{key:"copyFrom",value:function(o){this.startOffset=o.startOffset,this.startDelta=o.startDelta,this.startEdges=o.startEdges,this.edges=o.edges,this.states=o.states.map(function(f){return zl(f)}),this.result=Ur(Q({},o.result.coords),Q({},o.result.rect))}},{key:"destroy",value:function(){for(var o in this)this[o]=null}}]),t}();function Ur(t,o){return{rect:o,coords:t,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function Ul(t,o){var f=t.defaults,y={start:t.start,set:t.set,beforeEnd:t.beforeEnd,stop:t.stop},S=function(R){var K=R||{};for(var Z in K.enabled=K.enabled!==!1,f)Z in K||(K[Z]=f[Z]);var ke={options:K,methods:y,name:o,enable:function(){return K.enabled=!0,ke},disable:function(){return K.enabled=!1,ke}};return ke};return o&&typeof o=="string"&&(S._defaults=f,S._methods=y),S}function gr(t){var o=t.iEvent,f=t.interaction.modification.result;f&&(o.modifiers=f.eventProps)}var vn={id:"modifiers/base",before:["actions"],install:function(t){t.defaults.perAction.modifiers=[]},listeners:{"interactions:new":function(t){var o=t.interaction;o.modification=new $r(o)},"interactions:before-action-start":function(t){var o=t.interaction,f=t.interaction.modification;f.start(t,o.coords.start.page),o.edges=f.edges,f.applyToInteraction(t)},"interactions:before-action-move":function(t){var o=t.interaction,f=o.modification,y=f.setAndApply(t);return o.edges=f.edges,y},"interactions:before-action-end":function(t){var o=t.interaction,f=o.modification,y=f.beforeEnd(t);return o.edges=f.startEdges,y},"interactions:action-start":gr,"interactions:action-move":gr,"interactions:action-end":gr,"interactions:after-action-start":function(t){return t.interaction.modification.restoreInteractionCoords(t)},"interactions:after-action-move":function(t){return t.interaction.modification.restoreInteractionCoords(t)},"interactions:stop":function(t){return t.interaction.modification.stop(t)}}},vr=vn,Il={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}},sn=function(t){m(f,t);var o=M(f);function f(y,S,R,K,Z,ke,je){var Ee;s(this,f),(Ee=o.call(this,y)).relatedTarget=null,Ee.screenX=void 0,Ee.screenY=void 0,Ee.button=void 0,Ee.buttons=void 0,Ee.ctrlKey=void 0,Ee.shiftKey=void 0,Ee.altKey=void 0,Ee.metaKey=void 0,Ee.page=void 0,Ee.client=void 0,Ee.delta=void 0,Ee.rect=void 0,Ee.x0=void 0,Ee.y0=void 0,Ee.t0=void 0,Ee.dt=void 0,Ee.duration=void 0,Ee.clientX0=void 0,Ee.clientY0=void 0,Ee.velocity=void 0,Ee.speed=void 0,Ee.swipe=void 0,Ee.axes=void 0,Ee.preEnd=void 0,Z=Z||y.element;var ia=y.interactable,Ta=(ia&&ia.options||Il).deltaSource,el=De(ia,Z,R),Ja=K==="start",ol=K==="end",El=Ja?C(Ee):y.prevEvent,bl=Ja?y.coords.start:ol?{page:El.page,client:El.client,timeStamp:y.coords.cur.timeStamp}:y.coords.cur;return Ee.page=Q({},bl.page),Ee.client=Q({},bl.client),Ee.rect=Q({},y.rect),Ee.timeStamp=bl.timeStamp,ol||(Ee.page.x-=el.x,Ee.page.y-=el.y,Ee.client.x-=el.x,Ee.client.y-=el.y),Ee.ctrlKey=S.ctrlKey,Ee.altKey=S.altKey,Ee.shiftKey=S.shiftKey,Ee.metaKey=S.metaKey,Ee.button=S.button,Ee.buttons=S.buttons,Ee.target=Z,Ee.currentTarget=Z,Ee.preEnd=ke,Ee.type=je||R+(K||""),Ee.interactable=ia,Ee.t0=Ja?y.pointers[y.pointers.length-1].downTime:El.t0,Ee.x0=y.coords.start.page.x-el.x,Ee.y0=y.coords.start.page.y-el.y,Ee.clientX0=y.coords.start.client.x-el.x,Ee.clientY0=y.coords.start.client.y-el.y,Ee.delta=Ja||ol?{x:0,y:0}:{x:Ee[Ta].x-El[Ta].x,y:Ee[Ta].y-El[Ta].y},Ee.dt=y.coords.delta.timeStamp,Ee.duration=Ee.timeStamp-Ee.t0,Ee.velocity=Q({},y.coords.velocity[Ta]),Ee.speed=Za(Ee.velocity.x,Ee.velocity.y),Ee.swipe=ol||K==="inertiastart"?Ee.getSwipe():null,Ee}return c(f,[{key:"getSwipe",value:function(){var y=this._interaction;if(y.prevEvent.speed<600||this.timeStamp-y.prevEvent.timeStamp>150)return null;var S=180*Math.atan2(y.prevEvent.velocityY,y.prevEvent.velocityX)/Math.PI;S<0&&(S+=360);var R=112.5<=S&&S<247.5,K=202.5<=S&&S<337.5;return{up:K,down:!K&&22.5<=S&&S<157.5,left:R,right:!R&&(292.5<=S||S<67.5),angle:S,speed:y.prevEvent.speed,velocity:{x:y.prevEvent.velocityX,y:y.prevEvent.velocityY}}}},{key:"preventDefault",value:function(){}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}}]),f}(be);Object.defineProperties(sn.prototype,{pageX:{get:function(){return this.page.x},set:function(t){this.page.x=t}},pageY:{get:function(){return this.page.y},set:function(t){this.page.y=t}},clientX:{get:function(){return this.client.x},set:function(t){this.client.x=t}},clientY:{get:function(){return this.client.y},set:function(t){this.client.y=t}},dx:{get:function(){return this.delta.x},set:function(t){this.delta.x=t}},dy:{get:function(){return this.delta.y},set:function(t){this.delta.y=t}},velocityX:{get:function(){return this.velocity.x},set:function(t){this.velocity.x=t}},velocityY:{get:function(){return this.velocity.y},set:function(t){this.velocity.y=t}}});var jr=c(function t(o,f,y,S,R){s(this,t),this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=o,this.pointer=f,this.event=y,this.downTime=S,this.downTarget=R}),qr=function(t){return t.interactable="",t.element="",t.prepared="",t.pointerIsDown="",t.pointerWasMoved="",t._proxy="",t}({}),Kr=function(t){return t.start="",t.move="",t.end="",t.stop="",t.interacting="",t}({}),Xr=0,Wr=function(){function t(o){var f=this,y=o.pointerType,S=o.scopeFire;s(this,t),this.interactable=null,this.element=null,this.rect=null,this._rects=void 0,this.edges=null,this._scopeFire=void 0,this.prepared={name:null,axis:null,edges:null},this.pointerType=void 0,this.pointers=[],this.downEvent=null,this.downPointer={},this._latestPointer={pointer:null,event:null,eventTarget:null},this.prevEvent=null,this.pointerIsDown=!1,this.pointerWasMoved=!1,this._interacting=!1,this._ending=!1,this._stopped=!0,this._proxy=void 0,this.simulation=null,this.doMove=na(function(Ee){this.move(Ee)},"The interaction.doMove() method has been renamed to interaction.move()"),this.coords={start:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},prev:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},cur:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},delta:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},velocity:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0}},this._id=Xr++,this._scopeFire=S,this.pointerType=y;var R=this;this._proxy={};var K=function(Ee){Object.defineProperty(f._proxy,Ee,{get:function(){return R[Ee]}})};for(var Z in qr)K(Z);var ke=function(Ee){Object.defineProperty(f._proxy,Ee,{value:function(){return R[Ee].apply(R,arguments)}})};for(var je in Kr)ke(je);this._scopeFire("interactions:new",{interaction:this})}return c(t,[{key:"pointerMoveTolerance",get:function(){return 1}},{key:"pointerDown",value:function(o,f,y){var S=this.updatePointer(o,f,y,!0),R=this.pointers[S];this._scopeFire("interactions:down",{pointer:o,event:f,eventTarget:y,pointerIndex:S,pointerInfo:R,type:"down",interaction:this})}},{key:"start",value:function(o,f,y){return!(this.interacting()||!this.pointerIsDown||this.pointers.length<(o.name==="gesture"?2:1)||!f.options[o.name].enabled)&&(Sa(this.prepared,o),this.interactable=f,this.element=y,this.rect=f.getRect(y),this.edges=this.prepared.edges?Q({},this.prepared.edges):{left:!0,right:!0,top:!0,bottom:!0},this._stopped=!1,this._interacting=this._doPhase({interaction:this,event:this.downEvent,phase:"start"})&&!this._stopped,this._interacting)}},{key:"pointerMove",value:function(o,f,y){this.simulation||this.modification&&this.modification.endResult||this.updatePointer(o,f,y,!1);var S,R,K=this.coords.cur.page.x===this.coords.prev.page.x&&this.coords.cur.page.y===this.coords.prev.page.y&&this.coords.cur.client.x===this.coords.prev.client.x&&this.coords.cur.client.y===this.coords.prev.client.y;this.pointerIsDown&&!this.pointerWasMoved&&(S=this.coords.cur.client.x-this.coords.start.client.x,R=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=Za(S,R)>this.pointerMoveTolerance);var Z,ke,je,Ee=this.getPointerIndex(o),ia={pointer:o,pointerIndex:Ee,pointerInfo:this.pointers[Ee],event:f,type:"move",eventTarget:y,dx:S,dy:R,duplicate:K,interaction:this};K||(Z=this.coords.velocity,ke=this.coords.delta,je=Math.max(ke.timeStamp/1e3,.001),Z.page.x=ke.page.x/je,Z.page.y=ke.page.y/je,Z.client.x=ke.client.x/je,Z.client.y=ke.client.y/je,Z.timeStamp=je),this._scopeFire("interactions:move",ia),K||this.simulation||(this.interacting()&&(ia.type=null,this.move(ia)),this.pointerWasMoved&&X(this.coords.prev,this.coords.cur))}},{key:"move",value:function(o){o&&o.event||he(this.coords.delta),(o=Q({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},o||{})).phase="move",this._doPhase(o)}},{key:"pointerUp",value:function(o,f,y,S){var R=this.getPointerIndex(o);R===-1&&(R=this.updatePointer(o,f,y,!1));var K=/cancel$/i.test(f.type)?"cancel":"up";this._scopeFire("interactions:".concat(K),{pointer:o,pointerIndex:R,pointerInfo:this.pointers[R],event:f,eventTarget:y,type:K,curEventTarget:S,interaction:this}),this.simulation||this.end(f),this.removePointer(o,f)}},{key:"documentBlur",value:function(o){this.end(o),this._scopeFire("interactions:blur",{event:o,type:"blur",interaction:this})}},{key:"end",value:function(o){var f;this._ending=!0,o=o||this._latestPointer.event,this.interacting()&&(f=this._doPhase({event:o,interaction:this,phase:"end"})),this._ending=!1,f===!0&&this.stop()}},{key:"currentAction",value:function(){return this._interacting?this.prepared.name:null}},{key:"interacting",value:function(){return this._interacting}},{key:"stop",value:function(){this._scopeFire("interactions:stop",{interaction:this}),this.interactable=this.element=null,this._interacting=!1,this._stopped=!0,this.prepared.name=this.prevEvent=null}},{key:"getPointerIndex",value:function(o){var f=Fe(o);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:se(this.pointers,function(y){return y.id===f})}},{key:"getPointerInfo",value:function(o){return this.pointers[this.getPointerIndex(o)]}},{key:"updatePointer",value:function(o,f,y,S){var R,K,Z,ke=Fe(o),je=this.getPointerIndex(o),Ee=this.pointers[je];return S=S!==!1&&(S||/(down|start)$/i.test(f.type)),Ee?Ee.pointer=o:(Ee=new jr(ke,o,f,null,null),je=this.pointers.length,this.pointers.push(Ee)),xa(this.coords.cur,this.pointers.map(function(ia){return ia.pointer}),this._now()),R=this.coords.delta,K=this.coords.prev,Z=this.coords.cur,R.page.x=Z.page.x-K.page.x,R.page.y=Z.page.y-K.page.y,R.client.x=Z.client.x-K.client.x,R.client.y=Z.client.y-K.client.y,R.timeStamp=Z.timeStamp-K.timeStamp,S&&(this.pointerIsDown=!0,Ee.downTime=this.coords.cur.timeStamp,Ee.downTarget=y,H(this.downPointer,o),this.interacting()||(X(this.coords.start,this.coords.cur),X(this.coords.prev,this.coords.cur),this.downEvent=f,this.pointerWasMoved=!1)),this._updateLatestPointer(o,f,y),this._scopeFire("interactions:update-pointer",{pointer:o,event:f,eventTarget:y,down:S,pointerInfo:Ee,pointerIndex:je,interaction:this}),je}},{key:"removePointer",value:function(o,f){var y=this.getPointerIndex(o);if(y!==-1){var S=this.pointers[y];this._scopeFire("interactions:remove-pointer",{pointer:o,event:f,eventTarget:null,pointerIndex:y,pointerInfo:S,interaction:this}),this.pointers.splice(y,1),this.pointerIsDown=!1}}},{key:"_updateLatestPointer",value:function(o,f,y){this._latestPointer.pointer=o,this._latestPointer.event=f,this._latestPointer.eventTarget=y}},{key:"destroy",value:function(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}},{key:"_createPreparedEvent",value:function(o,f,y,S){return new sn(this,o,this.prepared.name,f,this.element,y,S)}},{key:"_fireEvent",value:function(o){var f;(f=this.interactable)==null||f.fire(o),(!this.prevEvent||o.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=o)}},{key:"_doPhase",value:function(o){var f=o.event,y=o.phase,S=o.preEnd,R=o.type,K=this.rect;if(K&&y==="move"&&(ce(this.edges,K,this.coords.delta[this.interactable.options.deltaSource]),K.width=K.right-K.left,K.height=K.bottom-K.top),this._scopeFire("interactions:before-action-".concat(y),o)===!1)return!1;var Z=o.iEvent=this._createPreparedEvent(f,y,S,R);return this._scopeFire("interactions:action-".concat(y),o),y==="start"&&(this.prevEvent=Z),this._fireEvent(Z),this._scopeFire("interactions:after-action-".concat(y),o),!0}},{key:"_now",value:function(){return Date.now()}}]),t}();function rr(t){nr(t.interaction)}function nr(t){if(!function(f){return!(!f.offset.pending.x&&!f.offset.pending.y)}(t))return!1;var o=t.offset.pending;return ml(t.coords.cur,o),ml(t.coords.delta,o),ce(t.edges,t.rect,o),o.x=0,o.y=0,!0}function Zr(t){var o=t.x,f=t.y;this.offset.pending.x+=o,this.offset.pending.y+=f,this.offset.total.x+=o,this.offset.total.y+=f}function ml(t,o){var f=t.page,y=t.client,S=o.x,R=o.y;f.x+=S,f.y+=R,y.x+=S,y.y+=R}Kr.offsetBy="";var or={id:"offset",before:["modifiers","pointer-events","actions","inertia"],install:function(t){t.Interaction.prototype.offsetBy=Zr},listeners:{"interactions:new":function(t){t.interaction.offset={total:{x:0,y:0},pending:{x:0,y:0}}},"interactions:update-pointer":function(t){return function(o){o.pointerIsDown&&(ml(o.coords.cur,o.offset.total),o.offset.pending.x=0,o.offset.pending.y=0)}(t.interaction)},"interactions:before-action-start":rr,"interactions:before-action-move":rr,"interactions:before-action-end":function(t){var o=t.interaction;if(nr(o))return o.move({offset:!0}),o.end(),!1},"interactions:stop":function(t){var o=t.interaction;o.offset.total.x=0,o.offset.total.y=0,o.offset.pending.x=0,o.offset.pending.y=0}}},Fl=or,Er=function(){function t(o){s(this,t),this.active=!1,this.isModified=!1,this.smoothEnd=!1,this.allowResume=!1,this.modification=void 0,this.modifierCount=0,this.modifierArg=void 0,this.startCoords=void 0,this.t0=0,this.v0=0,this.te=0,this.targetOffset=void 0,this.modifiedOffset=void 0,this.currentOffset=void 0,this.lambda_v0=0,this.one_ve_v0=0,this.timeout=void 0,this.interaction=void 0,this.interaction=o}return c(t,[{key:"start",value:function(o){var f=this.interaction,y=Wl(f);if(!y||!y.enabled)return!1;var S=f.coords.velocity.client,R=Za(S.x,S.y),K=this.modification||(this.modification=new $r(f));if(K.copyFrom(f.modification),this.t0=f._now(),this.allowResume=y.allowResume,this.v0=R,this.currentOffset={x:0,y:0},this.startCoords=f.coords.cur.page,this.modifierArg=K.fillArg({pageCoords:this.startCoords,preEnd:!0,phase:"inertiastart"}),this.t0-f.coords.cur.timeStamp<50&&R>y.minSpeed&&R>y.endSpeed)this.startInertia();else{if(K.result=K.setAll(this.modifierArg),!K.result.changed)return!1;this.startSmoothEnd()}return f.modification.result.rect=null,f.offsetBy(this.targetOffset),f._doPhase({interaction:f,event:o,phase:"inertiastart"}),f.offsetBy({x:-this.targetOffset.x,y:-this.targetOffset.y}),f.modification.result.rect=null,this.active=!0,f.simulation=this,!0}},{key:"startInertia",value:function(){var o=this,f=this.interaction.coords.velocity.client,y=Wl(this.interaction),S=y.resistance,R=-Math.log(y.endSpeed/this.v0)/S;this.targetOffset={x:(f.x-R)/S,y:(f.y-R)/S},this.te=R,this.lambda_v0=S/this.v0,this.one_ve_v0=1-y.endSpeed/this.v0;var K=this.modification,Z=this.modifierArg;Z.pageCoords={x:this.startCoords.x+this.targetOffset.x,y:this.startCoords.y+this.targetOffset.y},K.result=K.setAll(Z),K.result.changed&&(this.isModified=!0,this.modifiedOffset={x:this.targetOffset.x+K.result.delta.x,y:this.targetOffset.y+K.result.delta.y}),this.onNextFrame(function(){return o.inertiaTick()})}},{key:"startSmoothEnd",value:function(){var o=this;this.smoothEnd=!0,this.isModified=!0,this.targetOffset={x:this.modification.result.delta.x,y:this.modification.result.delta.y},this.onNextFrame(function(){return o.smoothEndTick()})}},{key:"onNextFrame",value:function(o){var f=this;this.timeout=sl.request(function(){f.active&&o()})}},{key:"inertiaTick",value:function(){var o,f,y,S,R,K,Z,ke=this,je=this.interaction,Ee=Wl(je).resistance,ia=(je._now()-this.t0)/1e3;if(ia<this.te){var Ta,el=1-(Math.exp(-Ee*ia)-this.lambda_v0)/this.one_ve_v0;this.isModified?(o=0,f=0,y=this.targetOffset.x,S=this.targetOffset.y,R=this.modifiedOffset.x,K=this.modifiedOffset.y,Ta={x:Vr(Z=el,o,y,R),y:Vr(Z,f,S,K)}):Ta={x:this.targetOffset.x*el,y:this.targetOffset.y*el};var Ja={x:Ta.x-this.currentOffset.x,y:Ta.y-this.currentOffset.y};this.currentOffset.x+=Ja.x,this.currentOffset.y+=Ja.y,je.offsetBy(Ja),je.move(),this.onNextFrame(function(){return ke.inertiaTick()})}else je.offsetBy({x:this.modifiedOffset.x-this.currentOffset.x,y:this.modifiedOffset.y-this.currentOffset.y}),this.end()}},{key:"smoothEndTick",value:function(){var o=this,f=this.interaction,y=f._now()-this.t0,S=Wl(f).smoothEndDuration;if(y<S){var R={x:kr(y,0,this.targetOffset.x,S),y:kr(y,0,this.targetOffset.y,S)},K={x:R.x-this.currentOffset.x,y:R.y-this.currentOffset.y};this.currentOffset.x+=K.x,this.currentOffset.y+=K.y,f.offsetBy(K),f.move({skipModifiers:this.modifierCount}),this.onNextFrame(function(){return o.smoothEndTick()})}else f.offsetBy({x:this.targetOffset.x-this.currentOffset.x,y:this.targetOffset.y-this.currentOffset.y}),this.end()}},{key:"resume",value:function(o){var f=o.pointer,y=o.event,S=o.eventTarget,R=this.interaction;R.offsetBy({x:-this.currentOffset.x,y:-this.currentOffset.y}),R.updatePointer(f,y,S,!0),R._doPhase({interaction:R,event:y,phase:"resume"}),X(R.coords.prev,R.coords.cur),this.stop()}},{key:"end",value:function(){this.interaction.move(),this.interaction.end(),this.stop()}},{key:"stop",value:function(){this.active=this.smoothEnd=!1,this.interaction.simulation=null,sl.cancel(this.timeout)}}]),t}();function Wl(t){var o=t.interactable,f=t.prepared;return o&&o.options&&f.name&&o.options[f.name].inertia}var hr={id:"inertia",before:["modifiers","actions"],install:function(t){var o=t.defaults;t.usePlugin(Fl),t.usePlugin(vr),t.actions.phases.inertiastart=!0,t.actions.phases.resume=!0,o.perAction.inertia={enabled:!1,resistance:10,minSpeed:100,endSpeed:10,allowResume:!0,smoothEndDuration:300}},listeners:{"interactions:new":function(t){var o=t.interaction;o.inertia=new Er(o)},"interactions:before-action-end":function(t){var o=t.interaction,f=t.event;return(!o._interacting||o.simulation||!o.inertia.start(f))&&null},"interactions:down":function(t){var o=t.interaction,f=t.eventTarget,y=o.inertia;if(y.active)for(var S=f;E.element(S);){if(S===o.element){y.resume(t);break}S=$e(S)}},"interactions:stop":function(t){var o=t.interaction.inertia;o.active&&o.stop()},"interactions:before-action-resume":function(t){var o=t.interaction.modification;o.stop(t),o.start(t,t.interaction.coords.cur.page),o.applyToInteraction(t)},"interactions:before-action-inertiastart":function(t){return t.interaction.modification.setAndApply(t)},"interactions:action-resume":gr,"interactions:action-inertiastart":gr,"interactions:after-action-inertiastart":function(t){return t.interaction.modification.restoreInteractionCoords(t)},"interactions:after-action-resume":function(t){return t.interaction.modification.restoreInteractionCoords(t)}}};function Vr(t,o,f,y){var S=1-t;return S*S*o+2*S*t*f+t*t*y}function kr(t,o,f,y){return-f*(t/=y)*(t-2)+o}var cn=hr;function Qr(t,o){for(var f=0;f<o.length;f++){var y=o[f];if(t.immediatePropagationStopped)break;y(t)}}var Jn=function(){function t(o){s(this,t),this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=Q({},o||{})}return c(t,[{key:"fire",value:function(o){var f,y=this.global;(f=this.types[o.type])&&Qr(o,f),!o.propagationStopped&&y&&(f=y[o.type])&&Qr(o,f)}},{key:"on",value:function(o,f){var y=Ke(o,f);for(o in y)this.types[o]=Be(this.types[o]||[],y[o])}},{key:"off",value:function(o,f){var y=Ke(o,f);for(o in y){var S=this.types[o];if(S&&S.length)for(var R=0,K=y[o];R<K.length;R++){var Z=K[R],ke=S.indexOf(Z);ke!==-1&&S.splice(ke,1)}}}},{key:"getRect",value:function(o){return null}}]),t}(),Fn=function(){function t(o){s(this,t),this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=o,H(this,o)}return c(t,[{key:"preventOriginalDefault",value:function(){this.originalEvent.preventDefault()}},{key:"stopPropagation",value:function(){this.originalEvent.stopPropagation()}},{key:"stopImmediatePropagation",value:function(){this.originalEvent.stopImmediatePropagation()}}]),t}();function Dn(t){return E.object(t)?{capture:!!t.capture,passive:!!t.passive}:{capture:!!t,passive:!1}}function In(t,o){return t===o||(typeof t=="boolean"?!!o.capture===t&&!o.passive:!!t.capture==!!o.capture&&!!t.passive==!!o.passive)}var jn={id:"events",install:function(t){var o,f=[],y={},S=[],R={add:K,remove:Z,addDelegate:function(Ee,ia,Ta,el,Ja){var ol=Dn(Ja);if(!y[Ta]){y[Ta]=[];for(var El=0;El<S.length;El++){var bl=S[El];K(bl,Ta,ke),K(bl,Ta,je,!0)}}var Ml=y[Ta],Kl=Xe(Ml,function(Ol){return Ol.selector===Ee&&Ol.context===ia});Kl||(Kl={selector:Ee,context:ia,listeners:[]},Ml.push(Kl)),Kl.listeners.push({func:el,options:ol})},removeDelegate:function(Ee,ia,Ta,el,Ja){var ol,El=Dn(Ja),bl=y[Ta],Ml=!1;if(bl)for(ol=bl.length-1;ol>=0;ol--){var Kl=bl[ol];if(Kl.selector===Ee&&Kl.context===ia){for(var Ol=Kl.listeners,Pl=Ol.length-1;Pl>=0;Pl--){var Vl=Ol[Pl];if(Vl.func===el&&In(Vl.options,El)){Ol.splice(Pl,1),Ol.length||(bl.splice(ol,1),Z(ia,Ta,ke),Z(ia,Ta,je,!0)),Ml=!0;break}}if(Ml)break}}},delegateListener:ke,delegateUseCapture:je,delegatedEvents:y,documents:S,targets:f,supportsOptions:!1,supportsPassive:!1};function K(Ee,ia,Ta,el){if(Ee.addEventListener){var Ja=Dn(el),ol=Xe(f,function(El){return El.eventTarget===Ee});ol||(ol={eventTarget:Ee,events:{}},f.push(ol)),ol.events[ia]||(ol.events[ia]=[]),Xe(ol.events[ia],function(El){return El.func===Ta&&In(El.options,Ja)})||(Ee.addEventListener(ia,Ta,R.supportsOptions?Ja:Ja.capture),ol.events[ia].push({func:Ta,options:Ja}))}}function Z(Ee,ia,Ta,el){if(Ee.addEventListener&&Ee.removeEventListener){var Ja=se(f,function(rn){return rn.eventTarget===Ee}),ol=f[Ja];if(ol&&ol.events)if(ia!=="all"){var El=!1,bl=ol.events[ia];if(bl){if(Ta==="all"){for(var Ml=bl.length-1;Ml>=0;Ml--){var Kl=bl[Ml];Z(Ee,ia,Kl.func,Kl.options)}return}for(var Ol=Dn(el),Pl=0;Pl<bl.length;Pl++){var Vl=bl[Pl];if(Vl.func===Ta&&In(Vl.options,Ol)){Ee.removeEventListener(ia,Ta,R.supportsOptions?Ol:Ol.capture),bl.splice(Pl,1),bl.length===0&&(delete ol.events[ia],El=!0);break}}}El&&!Object.keys(ol.events).length&&f.splice(Ja,1)}else for(ia in ol.events)ol.events.hasOwnProperty(ia)&&Z(Ee,ia,"all")}}function ke(Ee,ia){for(var Ta=Dn(ia),el=new Fn(Ee),Ja=y[Ee.type],ol=Te(Ee)[0],El=ol;E.element(El);){for(var bl=0;bl<Ja.length;bl++){var Ml=Ja[bl],Kl=Ml.selector,Ol=Ml.context;if(de(El,Kl)&&te(Ol,ol)&&te(Ol,El)){var Pl=Ml.listeners;el.currentTarget=El;for(var Vl=0;Vl<Pl.length;Vl++){var rn=Pl[Vl];In(rn.options,Ta)&&rn.func(el)}}}El=$e(El)}}function je(Ee){return ke(Ee,!0)}return(o=t.document)==null||o.createElement("div").addEventListener("test",null,{get capture(){return R.supportsOptions=!0},get passive(){return R.supportsPassive=!0}}),t.events=R,R}},mn={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search:function(t){for(var o=0,f=mn.methodOrder;o<f.length;o++){var y=f[o],S=mn[y](t);if(S)return S}return null},simulationResume:function(t){var o=t.pointerType,f=t.eventType,y=t.eventTarget,S=t.scope;if(!/down|start/i.test(f))return null;for(var R=0,K=S.interactions.list;R<K.length;R++){var Z=K[R],ke=y;if(Z.simulation&&Z.simulation.allowResume&&Z.pointerType===o)for(;ke;){if(ke===Z.element)return Z;ke=$e(ke)}}return null},mouseOrPen:function(t){var o,f=t.pointerId,y=t.pointerType,S=t.eventType,R=t.scope;if(y!=="mouse"&&y!=="pen")return null;for(var K=0,Z=R.interactions.list;K<Z.length;K++){var ke=Z[K];if(ke.pointerType===y){if(ke.simulation&&!On(ke,f))continue;if(ke.interacting())return ke;o||(o=ke)}}if(o)return o;for(var je=0,Ee=R.interactions.list;je<Ee.length;je++){var ia=Ee[je];if(!(ia.pointerType!==y||/down/i.test(S)&&ia.simulation))return ia}return null},hasPointer:function(t){for(var o=t.pointerId,f=0,y=t.scope.interactions.list;f<y.length;f++){var S=y[f];if(On(S,o))return S}return null},idle:function(t){for(var o=t.pointerType,f=0,y=t.scope.interactions.list;f<y.length;f++){var S=y[f];if(S.pointers.length===1){var R=S.interactable;if(R&&(!R.options.gesture||!R.options.gesture.enabled))continue}else if(S.pointers.length>=2)continue;if(!S.interacting()&&o===S.pointerType)return S}return null}};function On(t,o){return t.pointers.some(function(f){return f.id===o})}var Xn=mn,Gr=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function Zn(t,o){return function(f){var y=o.interactions.list,S=Ba(f),R=Te(f),K=R[0],Z=R[1],ke=[];if(/^touch/.test(f.type)){o.prevTouchTime=o.now();for(var je=0,Ee=f.changedTouches;je<Ee.length;je++){var ia=Ee[je],Ta={pointer:ia,pointerId:Fe(ia),pointerType:S,eventType:f.type,eventTarget:K,curEventTarget:Z,scope:o},el=_n(Ta);ke.push([Ta.pointer,Ta.eventTarget,Ta.curEventTarget,el])}}else{var Ja=!1;if(!Y.supportsPointerEvent&&/mouse/.test(f.type)){for(var ol=0;ol<y.length&&!Ja;ol++)Ja=y[ol].pointerType!=="mouse"&&y[ol].pointerIsDown;Ja=Ja||o.now()-o.prevTouchTime<500||f.timeStamp===0}if(!Ja){var El={pointer:f,pointerId:Fe(f),pointerType:S,eventType:f.type,curEventTarget:Z,eventTarget:K,scope:o},bl=_n(El);ke.push([El.pointer,El.eventTarget,El.curEventTarget,bl])}}for(var Ml=0;Ml<ke.length;Ml++){var Kl=ke[Ml],Ol=Kl[0],Pl=Kl[1],Vl=Kl[2];Kl[3][t](Ol,f,Pl,Vl)}}}function _n(t){var o=t.pointerType,f=t.scope,y={interaction:Xn.search(t),searchDetails:t};return f.fire("interactions:find",y),y.interaction||f.interactions.new({pointerType:o})}function Mi(t,o){var f=t.doc,y=t.scope,S=t.options,R=y.interactions.docEvents,K=y.events,Z=K[o];for(var ke in y.browser.isIOS&&!S.events&&(S.events={passive:!1}),K.delegatedEvents)Z(f,ke,K.delegateListener),Z(f,ke,K.delegateUseCapture,!0);for(var je=S&&S.events,Ee=0;Ee<R.length;Ee++){var ia=R[Ee];Z(f,ia.type,ia.listener,je)}}var jo={id:"core/interactions",install:function(t){for(var o={},f=0;f<Gr.length;f++){var y=Gr[f];o[y]=Zn(y,t)}var S,R=Y.pEventTypes;function K(){for(var Z=0,ke=t.interactions.list;Z<ke.length;Z++){var je=ke[Z];if(je.pointerIsDown&&je.pointerType==="touch"&&!je._interacting)for(var Ee=function(){var el=Ta[ia];t.documents.some(function(Ja){return te(Ja.doc,el.downTarget)})||je.removePointer(el.pointer,el.event)},ia=0,Ta=je.pointers;ia<Ta.length;ia++)Ee()}}(S=z.PointerEvent?[{type:R.down,listener:K},{type:R.down,listener:o.pointerDown},{type:R.move,listener:o.pointerMove},{type:R.up,listener:o.pointerUp},{type:R.cancel,listener:o.pointerUp}]:[{type:"mousedown",listener:o.pointerDown},{type:"mousemove",listener:o.pointerMove},{type:"mouseup",listener:o.pointerUp},{type:"touchstart",listener:K},{type:"touchstart",listener:o.pointerDown},{type:"touchmove",listener:o.pointerMove},{type:"touchend",listener:o.pointerUp},{type:"touchcancel",listener:o.pointerUp}]).push({type:"blur",listener:function(Z){for(var ke=0,je=t.interactions.list;ke<je.length;ke++)je[ke].documentBlur(Z)}}),t.prevTouchTime=0,t.Interaction=function(Z){m(je,Z);var ke=M(je);function je(){return s(this,je),ke.apply(this,arguments)}return c(je,[{key:"pointerMoveTolerance",get:function(){return t.interactions.pointerMoveTolerance},set:function(Ee){t.interactions.pointerMoveTolerance=Ee}},{key:"_now",value:function(){return t.now()}}]),je}(Wr),t.interactions={list:[],new:function(Z){Z.scopeFire=function(je,Ee){return t.fire(je,Ee)};var ke=new t.Interaction(Z);return t.interactions.list.push(ke),ke},listeners:o,docEvents:S,pointerMoveTolerance:1},t.usePlugin(br)},listeners:{"scope:add-document":function(t){return Mi(t,"add")},"scope:remove-document":function(t){return Mi(t,"remove")},"interactable:unset":function(t,o){for(var f=t.interactable,y=o.interactions.list.length-1;y>=0;y--){var S=o.interactions.list[y];S.interactable===f&&(S.stop(),o.fire("interactions:destroy",{interaction:S}),S.destroy(),o.interactions.list.length>2&&o.interactions.list.splice(y,1))}}},onDocSignal:Mi,doOnInteractions:Zn,methodNames:Gr},Ho=jo,Nn=function(t){return t[t.On=0]="On",t[t.Off=1]="Off",t}(Nn||{}),Uo=function(){function t(o,f,y,S){s(this,t),this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new Jn,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=f.actions,this.target=o,this._context=f.context||y,this._win=x(Ca(o)?this._context:o),this._doc=this._win.document,this._scopeEvents=S,this.set(f)}return c(t,[{key:"_defaults",get:function(){return{base:{},perAction:{},actions:{}}}},{key:"setOnEvents",value:function(o,f){return E.func(f.onstart)&&this.on("".concat(o,"start"),f.onstart),E.func(f.onmove)&&this.on("".concat(o,"move"),f.onmove),E.func(f.onend)&&this.on("".concat(o,"end"),f.onend),E.func(f.oninertiastart)&&this.on("".concat(o,"inertiastart"),f.oninertiastart),this}},{key:"updatePerActionListeners",value:function(o,f,y){var S,R=this,K=(S=this._actions.map[o])==null?void 0:S.filterEventType,Z=function(ke){return(K==null||K(ke))&&Dr(ke,R._actions)};(E.array(f)||E.object(f))&&this._onOff(Nn.Off,o,f,void 0,Z),(E.array(y)||E.object(y))&&this._onOff(Nn.On,o,y,void 0,Z)}},{key:"setPerAction",value:function(o,f){var y=this._defaults;for(var S in f){var R=S,K=this.options[o],Z=f[R];R==="listeners"&&this.updatePerActionListeners(o,K.listeners,Z),E.array(Z)?K[R]=ae(Z):E.plainObject(Z)?(K[R]=Q(K[R]||{},zl(Z)),E.object(y.perAction[R])&&"enabled"in y.perAction[R]&&(K[R].enabled=Z.enabled!==!1)):E.bool(Z)&&E.object(y.perAction[R])?K[R].enabled=Z:K[R]=Z}}},{key:"getRect",value:function(o){return o=o||(E.element(this.target)?this.target:null),E.string(this.target)&&(o=o||this._context.querySelector(this.target)),Le(o)}},{key:"rectChecker",value:function(o){var f=this;return E.func(o)?(this.getRect=function(y){var S=Q({},o.apply(f,y));return"width"in S||(S.width=S.right-S.left,S.height=S.bottom-S.top),S},this):o===null?(delete this.getRect,this):this.getRect}},{key:"_backCompatOption",value:function(o,f){if(Ca(f)||E.object(f)){for(var y in this.options[o]=f,this._actions.map)this.options[y][o]=f;return this}return this.options[o]}},{key:"origin",value:function(o){return this._backCompatOption("origin",o)}},{key:"deltaSource",value:function(o){return o==="page"||o==="client"?(this.options.deltaSource=o,this):this.options.deltaSource}},{key:"getAllElements",value:function(){var o=this.target;return E.string(o)?Array.from(this._context.querySelectorAll(o)):E.func(o)&&o.getAllElements?o.getAllElements():E.element(o)?[o]:[]}},{key:"context",value:function(){return this._context}},{key:"inContext",value:function(o){return this._context===o.ownerDocument||te(this._context,o)}},{key:"testIgnoreAllow",value:function(o,f,y){return!this.testIgnore(o.ignoreFrom,f,y)&&this.testAllow(o.allowFrom,f,y)}},{key:"testAllow",value:function(o,f,y){return!o||!!E.element(y)&&(E.string(o)?U(y,o,f):!!E.element(o)&&te(o,y))}},{key:"testIgnore",value:function(o,f,y){return!(!o||!E.element(y))&&(E.string(o)?U(y,o,f):!!E.element(o)&&te(o,y))}},{key:"fire",value:function(o){return this.events.fire(o),this}},{key:"_onOff",value:function(o,f,y,S,R){E.object(f)&&!E.array(f)&&(S=y,y=null);var K=Ke(f,y,R);for(var Z in K){Z==="wheel"&&(Z=Y.wheelEvent);for(var ke=0,je=K[Z];ke<je.length;ke++){var Ee=je[ke];Dr(Z,this._actions)?this.events[o===Nn.On?"on":"off"](Z,Ee):E.string(this.target)?this._scopeEvents[o===Nn.On?"addDelegate":"removeDelegate"](this.target,this._context,Z,Ee,S):this._scopeEvents[o===Nn.On?"add":"remove"](this.target,Z,Ee,S)}}return this}},{key:"on",value:function(o,f,y){return this._onOff(Nn.On,o,f,y)}},{key:"off",value:function(o,f,y){return this._onOff(Nn.Off,o,f,y)}},{key:"set",value:function(o){var f=this._defaults;for(var y in E.object(o)||(o={}),this.options=zl(f.base),this._actions.methodDict){var S=y,R=this._actions.methodDict[S];this.options[S]={},this.setPerAction(S,Q(Q({},f.perAction),f.actions[S])),this[R](o[S])}for(var K in o)K!=="getRect"?E.func(this[K])&&this[K](o[K]):this.rectChecker(o.getRect);return this}},{key:"unset",value:function(){if(E.string(this.target))for(var o in this._scopeEvents.delegatedEvents)for(var f=this._scopeEvents.delegatedEvents[o],y=f.length-1;y>=0;y--){var S=f[y],R=S.selector,K=S.context,Z=S.listeners;R===this.target&&K===this._context&&f.splice(y,1);for(var ke=Z.length-1;ke>=0;ke--)this._scopeEvents.removeDelegate(this.target,this._context,o,Z[ke][0],Z[ke][1])}else this._scopeEvents.remove(this.target,"all")}}]),t}(),qo=function(){function t(o){var f=this;s(this,t),this.list=[],this.selectorMap={},this.scope=void 0,this.scope=o,o.addListeners({"interactable:unset":function(y){var S=y.interactable,R=S.target,K=E.string(R)?f.selectorMap[R]:R[f.scope.id],Z=se(K,function(ke){return ke===S});K.splice(Z,1)}})}return c(t,[{key:"new",value:function(o,f){f=Q(f||{},{actions:this.scope.actions});var y=new this.scope.Interactable(o,f,this.scope.document,this.scope.events);return this.scope.addDocument(y._doc),this.list.push(y),E.string(o)?(this.selectorMap[o]||(this.selectorMap[o]=[]),this.selectorMap[o].push(y)):(y.target[this.scope.id]||Object.defineProperty(o,this.scope.id,{value:[],configurable:!0}),o[this.scope.id].push(y)),this.scope.fire("interactable:new",{target:o,options:f,interactable:y,win:this.scope._win}),y}},{key:"getExisting",value:function(o,f){var y=f&&f.context||this.scope.document,S=E.string(o),R=S?this.selectorMap[o]:o[this.scope.id];if(R)return Xe(R,function(K){return K._context===y&&(S||K.inContext(o))})}},{key:"forEachMatch",value:function(o,f){for(var y=0,S=this.list;y<S.length;y++){var R=S[y],K=void 0;if((E.string(R.target)?E.element(o)&&de(o,R.target):o===R.target)&&R.inContext(o)&&(K=f(R)),K!==void 0)return K}}}]),t}(),Wo=function(){function t(){var o=this;s(this,t),this.id="__interact_scope_".concat(Math.floor(100*Math.random())),this.isInitialized=!1,this.listenerMaps=[],this.browser=Y,this.defaults=zl(Il),this.Eventable=Jn,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=function(y){var S=function R(K,Z){var ke=y.interactables.getExisting(K,Z);return ke||((ke=y.interactables.new(K,Z)).events.global=R.globalEvents),ke};return S.getPointerAverage=va,S.getTouchBBox=La,S.getTouchDistance=Ia,S.getTouchAngle=fa,S.getElementRect=Le,S.getElementClientRect=ze,S.matchesSelector=de,S.closest=ye,S.globalEvents={},S.version="1.10.27",S.scope=y,S.use=function(R,K){return this.scope.usePlugin(R,K),this},S.isSet=function(R,K){return!!this.scope.interactables.get(R,K&&K.context)},S.on=na(function(R,K,Z){if(E.string(R)&&R.search(" ")!==-1&&(R=R.trim().split(/ +/)),E.array(R)){for(var ke=0,je=R;ke<je.length;ke++){var Ee=je[ke];this.on(Ee,K,Z)}return this}if(E.object(R)){for(var ia in R)this.on(ia,R[ia],K);return this}return Dr(R,this.scope.actions)?this.globalEvents[R]?this.globalEvents[R].push(K):this.globalEvents[R]=[K]:this.scope.events.add(this.scope.document,R,K,{options:Z}),this},"The interact.on() method is being deprecated"),S.off=na(function(R,K,Z){if(E.string(R)&&R.search(" ")!==-1&&(R=R.trim().split(/ +/)),E.array(R)){for(var ke=0,je=R;ke<je.length;ke++){var Ee=je[ke];this.off(Ee,K,Z)}return this}if(E.object(R)){for(var ia in R)this.off(ia,R[ia],K);return this}var Ta;return Dr(R,this.scope.actions)?R in this.globalEvents&&(Ta=this.globalEvents[R].indexOf(K))!==-1&&this.globalEvents[R].splice(Ta,1):this.scope.events.remove(this.scope.document,R,K,Z),this},"The interact.off() method is being deprecated"),S.debug=function(){return this.scope},S.supportsTouch=function(){return Y.supportsTouch},S.supportsPointerEvent=function(){return Y.supportsPointerEvent},S.stop=function(){for(var R=0,K=this.scope.interactions.list;R<K.length;R++)K[R].stop();return this},S.pointerMoveTolerance=function(R){return E.number(R)?(this.scope.interactions.pointerMoveTolerance=R,this):this.scope.interactions.pointerMoveTolerance},S.addDocument=function(R,K){this.scope.addDocument(R,K)},S.removeDocument=function(R){this.scope.removeDocument(R)},S}(this),this.InteractEvent=sn,this.Interactable=void 0,this.interactables=new qo(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=function(y){return o.removeDocument(y.target)};var f=this;this.Interactable=function(y){m(R,y);var S=M(R);function R(){return s(this,R),S.apply(this,arguments)}return c(R,[{key:"_defaults",get:function(){return f.defaults}},{key:"set",value:function(K){return k(b(R.prototype),"set",this).call(this,K),f.fire("interactable:set",{options:K,interactable:this}),this}},{key:"unset",value:function(){k(b(R.prototype),"unset",this).call(this);var K=f.interactables.list.indexOf(this);K<0||(f.interactables.list.splice(K,1),f.fire("interactable:unset",{interactable:this}))}}]),R}(Uo)}return c(t,[{key:"addListeners",value:function(o,f){this.listenerMaps.push({id:f,map:o})}},{key:"fire",value:function(o,f){for(var y=0,S=this.listenerMaps;y<S.length;y++){var R=S[y].map[o];if(R&&R(f,this,o)===!1)return!1}}},{key:"init",value:function(o){return this.isInitialized?this:function(f,y){return f.isInitialized=!0,E.window(y)&&_(y),z.init(y),Y.init(y),sl.init(y),f.window=y,f.document=y.document,f.usePlugin(Ho),f.usePlugin(jn),f}(this,o)}},{key:"pluginIsInstalled",value:function(o){var f=o.id;return f?!!this._plugins.map[f]:this._plugins.list.indexOf(o)!==-1}},{key:"usePlugin",value:function(o,f){if(!this.isInitialized)return this;if(this.pluginIsInstalled(o))return this;if(o.id&&(this._plugins.map[o.id]=o),this._plugins.list.push(o),o.install&&o.install(this,f),o.listeners&&o.before){for(var y=0,S=this.listenerMaps.length,R=o.before.reduce(function(Z,ke){return Z[ke]=!0,Z[Ii(ke)]=!0,Z},{});y<S;y++){var K=this.listenerMaps[y].id;if(K&&(R[K]||R[Ii(K)]))break}this.listenerMaps.splice(y,0,{id:o.id,map:o.listeners})}else o.listeners&&this.listenerMaps.push({id:o.id,map:o.listeners});return this}},{key:"addDocument",value:function(o,f){if(this.getDocIndex(o)!==-1)return!1;var y=x(o);f=f?Q({},f):{},this.documents.push({doc:o,options:f}),this.events.documents.push(o),o!==this.document&&this.events.add(y,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:o,window:y,scope:this,options:f})}},{key:"removeDocument",value:function(o){var f=this.getDocIndex(o),y=x(o),S=this.documents[f].options;this.events.remove(y,"unload",this.onWindowUnload),this.documents.splice(f,1),this.events.documents.splice(f,1),this.fire("scope:remove-document",{doc:o,window:y,scope:this,options:S})}},{key:"getDocIndex",value:function(o){for(var f=0;f<this.documents.length;f++)if(this.documents[f].doc===o)return f;return-1}},{key:"getDocOptions",value:function(o){var f=this.getDocIndex(o);return f===-1?null:this.documents[f].options}},{key:"now",value:function(){return(this.window.Date||Date).now()}}]),t}();function Ii(t){return t&&t.replace(/\/.*$/,"")}var eo=new Wo,ln=eo.interactStatic,Ko=typeof globalThis<"u"?globalThis:window;eo.init(Ko);var Go=Object.freeze({__proto__:null,edgeTarget:function(){},elements:function(){},grid:function(t){var o=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(function(y){var S=y[0],R=y[1];return S in t||R in t}),f=function(y,S){for(var R=t.range,K=t.limits,Z=K===void 0?{left:-1/0,right:1/0,top:-1/0,bottom:1/0}:K,ke=t.offset,je=ke===void 0?{x:0,y:0}:ke,Ee={range:R,grid:t,x:null,y:null},ia=0;ia<o.length;ia++){var Ta=o[ia],el=Ta[0],Ja=Ta[1],ol=Math.round((y-je.x)/t[el]),El=Math.round((S-je.y)/t[Ja]);Ee[el]=Math.max(Z.left,Math.min(Z.right,ol*t[el]+je.x)),Ee[Ja]=Math.max(Z.top,Math.min(Z.bottom,El*t[Ja]+je.y))}return Ee};return f.grid=t,f.coordFields=o,f}}),Oi={id:"snappers",install:function(t){var o=t.interactStatic;o.snappers=Q(o.snappers||{},Go),o.createSnapGrid=o.snappers.grid}},Yo=Oi,Li={start:function(t){var o=t.state,f=t.rect,y=t.edges,S=t.pageCoords,R=o.options,K=R.ratio,Z=R.enabled,ke=o.options,je=ke.equalDelta,Ee=ke.modifiers;K==="preserve"&&(K=f.width/f.height),o.startCoords=Q({},S),o.startRect=Q({},f),o.ratio=K,o.equalDelta=je;var ia=o.linkedEdges={top:y.top||y.left&&!y.bottom,left:y.left||y.top&&!y.right,bottom:y.bottom||y.right&&!y.top,right:y.right||y.bottom&&!y.left};if(o.xIsPrimaryAxis=!(!y.left&&!y.right),o.equalDelta){var Ta=(ia.left?1:-1)*(ia.top?1:-1);o.edgeSign={x:Ta,y:Ta}}else o.edgeSign={x:ia.left?-1:1,y:ia.top?-1:1};if(Z!==!1&&Q(y,ia),Ee!=null&&Ee.length){var el=new $r(t.interaction);el.copyFrom(t.interaction.modification),el.prepareStates(Ee),o.subModification=el,el.startAll(r({},t))}},set:function(t){var o=t.state,f=t.rect,y=t.coords,S=o.linkedEdges,R=Q({},y),K=o.equalDelta?ao:lo;if(Q(t.edges,S),K(o,o.xIsPrimaryAxis,y,f),!o.subModification)return null;var Z=Q({},f);ce(S,Z,{x:y.x-R.x,y:y.y-R.y});var ke=o.subModification.setAll(r(r({},t),{},{rect:Z,edges:S,pageCoords:y,prevCoords:y,prevRect:Z})),je=ke.delta;return ke.changed&&(K(o,Math.abs(je.x)>Math.abs(je.y),ke.coords,ke.rect),Q(y,ke.coords)),ke.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function ao(t,o,f){var y=t.startCoords,S=t.edgeSign;o?f.y=y.y+(f.x-y.x)*S.y:f.x=y.x+(f.y-y.y)*S.x}function lo(t,o,f,y){var S=t.startRect,R=t.startCoords,K=t.ratio,Z=t.edgeSign;if(o){var ke=y.width/K;f.y=R.y+(ke-S.height)*Z.y}else{var je=y.height*K;f.x=R.x+(je-S.width)*Z.x}}var Jo=Ul(Li,"aspectRatio"),ro=function(){};ro._defaults={};var hi=ro;function bn(t,o,f){return E.func(t)?ue(t,o.interactable,o.element,[f.x,f.y,o]):ue(t,o.interactable,o.element)}var Qn={start:function(t){var o=t.rect,f=t.startOffset,y=t.state,S=t.interaction,R=t.pageCoords,K=y.options,Z=K.elementRect,ke=Q({left:0,top:0,right:0,bottom:0},K.offset||{});if(o&&Z){var je=bn(K.restriction,S,R);if(je){var Ee=je.right-je.left-o.width,ia=je.bottom-je.top-o.height;Ee<0&&(ke.left+=Ee,ke.right+=Ee),ia<0&&(ke.top+=ia,ke.bottom+=ia)}ke.left+=f.left-o.width*Z.left,ke.top+=f.top-o.height*Z.top,ke.right+=f.right-o.width*(1-Z.right),ke.bottom+=f.bottom-o.height*(1-Z.bottom)}y.offset=ke},set:function(t){var o=t.coords,f=t.interaction,y=t.state,S=y.options,R=y.offset,K=bn(S.restriction,f,o);if(K){var Z=function(ke){return!ke||"left"in ke&&"top"in ke||((ke=Q({},ke)).left=ke.x||0,ke.top=ke.y||0,ke.right=ke.right||ke.left+ke.width,ke.bottom=ke.bottom||ke.top+ke.height),ke}(K);o.x=Math.max(Math.min(Z.right-R.right,o.x),Z.left+R.left),o.y=Math.max(Math.min(Z.bottom-R.bottom,o.y),Z.top+R.top)}},defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}},Ri=Ul(Qn,"restrict"),no={top:1/0,left:1/0,bottom:-1/0,right:-1/0},io={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function oo(t,o){for(var f=0,y=["top","left","bottom","right"];f<y.length;f++){var S=y[f];S in t||(t[S]=o[S])}return t}var ei={noInner:no,noOuter:io,start:function(t){var o,f=t.interaction,y=t.startOffset,S=t.state,R=S.options;R&&(o=pa(bn(R.offset,f,f.coords.start.page))),o=o||{x:0,y:0},S.offset={top:o.y+y.top,left:o.x+y.left,bottom:o.y-y.bottom,right:o.x-y.right}},set:function(t){var o=t.coords,f=t.edges,y=t.interaction,S=t.state,R=S.offset,K=S.options;if(f){var Z=Q({},o),ke=bn(K.inner,y,Z)||{},je=bn(K.outer,y,Z)||{};oo(ke,no),oo(je,io),f.top?o.y=Math.min(Math.max(je.top+R.top,Z.y),ke.top+R.top):f.bottom&&(o.y=Math.max(Math.min(je.bottom+R.bottom,Z.y),ke.bottom+R.bottom)),f.left?o.x=Math.min(Math.max(je.left+R.left,Z.x),ke.left+R.left):f.right&&(o.x=Math.max(Math.min(je.right+R.right,Z.x),ke.right+R.right))}},defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}},to=Ul(ei,"restrictEdges"),ai=Q({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(t){}},Qn.defaults),so=Ul({start:Qn.start,set:Qn.set,defaults:ai},"restrictRect"),co={width:-1/0,height:-1/0},li={width:1/0,height:1/0},Xo=Ul({start:function(t){return ei.start(t)},set:function(t){var o=t.interaction,f=t.state,y=t.rect,S=t.edges,R=f.options;if(S){var K=Se(bn(R.min,o,t.coords))||co,Z=Se(bn(R.max,o,t.coords))||li;f.options={endOnly:R.endOnly,inner:Q({},ei.noInner),outer:Q({},ei.noOuter)},S.top?(f.options.inner.top=y.bottom-K.height,f.options.outer.top=y.bottom-Z.height):S.bottom&&(f.options.inner.bottom=y.top+K.height,f.options.outer.bottom=y.top+Z.height),S.left?(f.options.inner.left=y.right-K.width,f.options.outer.left=y.right-Z.width):S.right&&(f.options.inner.right=y.left+K.width,f.options.outer.right=y.left+Z.width),ei.set(t),f.options=R}},defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize"),vi={start:function(t){var o,f=t.interaction,y=t.interactable,S=t.element,R=t.rect,K=t.state,Z=t.startOffset,ke=K.options,je=ke.offsetWithOrigin?function(Ta){var el=Ta.interaction.element,Ja=pa(ue(Ta.state.options.origin,null,null,[el])),ol=Ja||De(Ta.interactable,el,Ta.interaction.prepared.name);return ol}(t):{x:0,y:0};if(ke.offset==="startCoords")o={x:f.coords.start.page.x,y:f.coords.start.page.y};else{var Ee=ue(ke.offset,y,S,[f]);(o=pa(Ee)||{x:0,y:0}).x+=je.x,o.y+=je.y}var ia=ke.relativePoints;K.offsets=R&&ia&&ia.length?ia.map(function(Ta,el){return{index:el,relativePoint:Ta,x:Z.left-R.width*Ta.x+o.x,y:Z.top-R.height*Ta.y+o.y}}):[{index:0,relativePoint:null,x:o.x,y:o.y}]},set:function(t){var o=t.interaction,f=t.coords,y=t.state,S=y.options,R=y.offsets,K=De(o.interactable,o.element,o.prepared.name),Z=Q({},f),ke=[];S.offsetWithOrigin||(Z.x-=K.x,Z.y-=K.y);for(var je=0,Ee=R;je<Ee.length;je++)for(var ia=Ee[je],Ta=Z.x-ia.x,el=Z.y-ia.y,Ja=0,ol=S.targets.length;Ja<ol;Ja++){var El=S.targets[Ja],bl=void 0;(bl=E.func(El)?El(Ta,el,o._proxy,ia,Ja):El)&&ke.push({x:(E.number(bl.x)?bl.x:Ta)+ia.x,y:(E.number(bl.y)?bl.y:el)+ia.y,range:E.number(bl.range)?bl.range:S.range,source:El,index:Ja,offset:ia})}for(var Ml={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}},Kl=0;Kl<ke.length;Kl++){var Ol=ke[Kl],Pl=Ol.range,Vl=Ol.x-Z.x,rn=Ol.y-Z.y,tr=Za(Vl,rn),un=tr<=Pl;Pl===1/0&&Ml.inRange&&Ml.range!==1/0&&(un=!1),Ml.target&&!(un?Ml.inRange&&Pl!==1/0?tr/Pl<Ml.distance/Ml.range:Pl===1/0&&Ml.range!==1/0||tr<Ml.distance:!Ml.inRange&&tr<Ml.distance)||(Ml.target=Ol,Ml.distance=tr,Ml.range=Pl,Ml.inRange=un,Ml.delta.x=Vl,Ml.delta.y=rn)}return Ml.inRange&&(f.x=Ml.target.x,f.y=Ml.target.y),y.closest=Ml,Ml},defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}},ri=Ul(vi,"snap"),mi={start:function(t){var o=t.state,f=t.edges,y=o.options;if(!f)return null;t.state={options:{targets:null,relativePoints:[{x:f.left?0:1,y:f.top?0:1}],offset:y.offset||"self",origin:{x:0,y:0},range:y.range}},o.targetFields=o.targetFields||[["width","height"],["x","y"]],vi.start(t),o.offsets=t.state.offsets,t.state=o},set:function(t){var o=t.interaction,f=t.state,y=t.coords,S=f.options,R=f.offsets,K={x:y.x-R[0].x,y:y.y-R[0].y};f.options=Q({},S),f.options.targets=[];for(var Z=0,ke=S.targets||[];Z<ke.length;Z++){var je=ke[Z],Ee=void 0;if(Ee=E.func(je)?je(K.x,K.y,o):je){for(var ia=0,Ta=f.targetFields;ia<Ta.length;ia++){var el=Ta[ia],Ja=el[0],ol=el[1];if(Ja in Ee||ol in Ee){Ee.x=Ee[Ja],Ee.y=Ee[ol];break}}f.options.targets.push(Ee)}}var El=vi.set(t);return f.options=S,El},defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}},Zo=Ul(mi,"snapSize"),$i={aspectRatio:Jo,restrictEdges:to,restrict:Ri,restrictRect:so,restrictSize:Xo,snapEdges:Ul({start:function(t){var o=t.edges;return o?(t.state.targetFields=t.state.targetFields||[[o.left?"left":"right",o.top?"top":"bottom"]],mi.start(t)):null},set:mi.set,defaults:Q(zl(mi.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})},"snapEdges"),snap:ri,snapSize:Zo,spring:hi,avoid:hi,transform:hi,rubberband:hi},Qo={id:"modifiers",install:function(t){var o=t.interactStatic;for(var f in t.usePlugin(vr),t.usePlugin(Yo),o.modifiers=$i,$i){var y=$i[f],S=y._defaults,R=y._methods;S._methods=R,t.defaults.perAction[f]=S}}},et=Qo,uo=function(t){m(f,t);var o=M(f);function f(y,S,R,K,Z,ke){var je;if(s(this,f),H(C(je=o.call(this,Z)),R),R!==S&&H(C(je),S),je.timeStamp=ke,je.originalEvent=R,je.type=y,je.pointerId=Fe(S),je.pointerType=Ba(S),je.target=K,je.currentTarget=null,y==="tap"){var Ee=Z.getPointerIndex(S);je.dt=je.timeStamp-Z.pointers[Ee].downTime;var ia=je.timeStamp-Z.tapTime;je.double=!!Z.prevTap&&Z.prevTap.type!=="doubletap"&&Z.prevTap.target===je.target&&ia<500}else y==="doubletap"&&(je.dt=S.timeStamp-Z.tapTime,je.double=!0);return je}return c(f,[{key:"_subtractOrigin",value:function(y){var S=y.x,R=y.y;return this.pageX-=S,this.pageY-=R,this.clientX-=S,this.clientY-=R,this}},{key:"_addOrigin",value:function(y){var S=y.x,R=y.y;return this.pageX+=S,this.pageY+=R,this.clientX+=S,this.clientY+=R,this}},{key:"preventDefault",value:function(){this.originalEvent.preventDefault()}}]),f}(be),ni={id:"pointer-events/base",before:["inertia","modifiers","auto-start","actions"],install:function(t){t.pointerEvents=ni,t.defaults.actions.pointerEvents=ni.defaults,Q(t.actions.phaselessTypes,ni.types)},listeners:{"interactions:new":function(t){var o=t.interaction;o.prevTap=null,o.tapTime=0},"interactions:update-pointer":function(t){var o=t.down,f=t.pointerInfo;!o&&f.hold||(f.hold={duration:1/0,timeout:null})},"interactions:move":function(t,o){var f=t.interaction,y=t.pointer,S=t.event,R=t.eventTarget;t.duplicate||f.pointerIsDown&&!f.pointerWasMoved||(f.pointerIsDown&&Pi(t),An({interaction:f,pointer:y,event:S,eventTarget:R,type:"move"},o))},"interactions:down":function(t,o){(function(f,y){for(var S=f.interaction,R=f.pointer,K=f.event,Z=f.eventTarget,ke=f.pointerIndex,je=S.pointers[ke].hold,Ee=ra(Z),ia={interaction:S,pointer:R,event:K,eventTarget:Z,type:"hold",targets:[],path:Ee,node:null},Ta=0;Ta<Ee.length;Ta++){var el=Ee[Ta];ia.node=el,y.fire("pointerEvents:collect-targets",ia)}if(ia.targets.length){for(var Ja=1/0,ol=0,El=ia.targets;ol<El.length;ol++){var bl=El[ol].eventable.options.holdDuration;bl<Ja&&(Ja=bl)}je.duration=Ja,je.timeout=setTimeout(function(){An({interaction:S,eventTarget:Z,pointer:R,event:K,type:"hold"},y)},Ja)}})(t,o),An(t,o)},"interactions:up":function(t,o){Pi(t),An(t,o),function(f,y){var S=f.interaction,R=f.pointer,K=f.event,Z=f.eventTarget;S.pointerWasMoved||An({interaction:S,eventTarget:Z,pointer:R,event:K,type:"tap"},y)}(t,o)},"interactions:cancel":function(t,o){Pi(t),An(t,o)}},PointerEvent:uo,fire:An,collectEventTargets:Vi,defaults:{holdDuration:600,ignoreFrom:null,allowFrom:null,origin:{x:0,y:0}},types:{down:!0,move:!0,up:!0,cancel:!0,tap:!0,doubletap:!0,hold:!0}};function An(t,o){var f=t.interaction,y=t.pointer,S=t.event,R=t.eventTarget,K=t.type,Z=t.targets,ke=Z===void 0?Vi(t,o):Z,je=new uo(K,y,S,R,f,o.now());o.fire("pointerEvents:new",{pointerEvent:je});for(var Ee={interaction:f,pointer:y,event:S,eventTarget:R,targets:ke,type:K,pointerEvent:je},ia=0;ia<ke.length;ia++){var Ta=ke[ia];for(var el in Ta.props||{})je[el]=Ta.props[el];var Ja=De(Ta.eventable,Ta.node);if(je._subtractOrigin(Ja),je.eventable=Ta.eventable,je.currentTarget=Ta.node,Ta.eventable.fire(je),je._addOrigin(Ja),je.immediatePropagationStopped||je.propagationStopped&&ia+1<ke.length&&ke[ia+1].node!==je.currentTarget)break}if(o.fire("pointerEvents:fired",Ee),K==="tap"){var ol=je.double?An({interaction:f,pointer:y,event:S,eventTarget:R,type:"doubletap"},o):je;f.prevTap=ol,f.tapTime=ol.timeStamp}return je}function Vi(t,o){var f=t.interaction,y=t.pointer,S=t.event,R=t.eventTarget,K=t.type,Z=f.getPointerIndex(y),ke=f.pointers[Z];if(K==="tap"&&(f.pointerWasMoved||!ke||ke.downTarget!==R))return[];for(var je=ra(R),Ee={interaction:f,pointer:y,event:S,eventTarget:R,type:K,path:je,targets:[],node:null},ia=0;ia<je.length;ia++){var Ta=je[ia];Ee.node=Ta,o.fire("pointerEvents:collect-targets",Ee)}return K==="hold"&&(Ee.targets=Ee.targets.filter(function(el){var Ja,ol;return el.eventable.options.holdDuration===((Ja=f.pointers[Z])==null||(ol=Ja.hold)==null?void 0:ol.duration)})),Ee.targets}function Pi(t){var o=t.interaction,f=t.pointerIndex,y=o.pointers[f].hold;y&&y.timeout&&(clearTimeout(y.timeout),y.timeout=null)}var at=Object.freeze({__proto__:null,default:ni});function lt(t){var o=t.interaction;o.holdIntervalHandle&&(clearInterval(o.holdIntervalHandle),o.holdIntervalHandle=null)}var rt={id:"pointer-events/holdRepeat",install:function(t){t.usePlugin(ni);var o=t.pointerEvents;o.defaults.holdRepeatInterval=0,o.types.holdrepeat=t.actions.phaselessTypes.holdrepeat=!0},listeners:["move","up","cancel","endall"].reduce(function(t,o){return t["pointerEvents:".concat(o)]=lt,t},{"pointerEvents:new":function(t){var o=t.pointerEvent;o.type==="hold"&&(o.count=(o.count||0)+1)},"pointerEvents:fired":function(t,o){var f=t.interaction,y=t.pointerEvent,S=t.eventTarget,R=t.targets;if(y.type==="hold"&&R.length){var K=R[0].eventable.options.holdRepeatInterval;K<=0||(f.holdIntervalHandle=setTimeout(function(){o.pointerEvents.fire({interaction:f,eventTarget:S,type:"hold",pointer:y,event:y},o)},K))}}})},yi=rt,nt={id:"pointer-events/interactableTargets",install:function(t){var o=t.Interactable;o.prototype.pointerEvents=function(y){return Q(this.events.options,y),this};var f=o.prototype._backCompatOption;o.prototype._backCompatOption=function(y,S){var R=f.call(this,y,S);return R===this&&(this.events.options[y]=S),R}},listeners:{"pointerEvents:collect-targets":function(t,o){var f=t.targets,y=t.node,S=t.type,R=t.eventTarget;o.interactables.forEachMatch(y,function(K){var Z=K.events,ke=Z.options;Z.types[S]&&Z.types[S].length&&K.testIgnoreAllow(ke,y,R)&&f.push({node:y,eventable:Z,props:{interactable:K}})})},"interactable:new":function(t){var o=t.interactable;o.events.getRect=function(f){return o.getRect(f)}},"interactable:set":function(t,o){var f=t.interactable,y=t.options;Q(f.events.options,o.pointerEvents.defaults),Q(f.events.options,y.pointerEvents||{})}}},it=nt,ot={id:"pointer-events",install:function(t){t.usePlugin(at),t.usePlugin(yi),t.usePlugin(it)}},tt=ot,po={id:"reflow",install:function(t){var o=t.Interactable;t.actions.phases.reflow=!0,o.prototype.reflow=function(f){return function(y,S,R){for(var K=y.getAllElements(),Z=R.window.Promise,ke=Z?[]:null,je=function(){var ia=K[Ee],Ta=y.getRect(ia);if(!Ta)return 1;var el,Ja=Xe(R.interactions.list,function(bl){return bl.interacting()&&bl.interactable===y&&bl.element===ia&&bl.prepared.name===S.name});if(Ja)Ja.move(),ke&&(el=Ja._reflowPromise||new Z(function(bl){Ja._reflowResolve=bl}));else{var ol=Se(Ta),El=function(bl){return{coords:bl,get page(){return this.coords.page},get client(){return this.coords.client},get timeStamp(){return this.coords.timeStamp},get pageX(){return this.coords.page.x},get pageY(){return this.coords.page.y},get clientX(){return this.coords.client.x},get clientY(){return this.coords.client.y},get pointerId(){return this.coords.pointerId},get target(){return this.coords.target},get type(){return this.coords.type},get pointerType(){return this.coords.pointerType},get buttons(){return this.coords.buttons},preventDefault:function(){}}}({page:{x:ol.x,y:ol.y},client:{x:ol.x,y:ol.y},timeStamp:R.now()});el=function(bl,Ml,Kl,Ol,Pl){var Vl=bl.interactions.new({pointerType:"reflow"}),rn={interaction:Vl,event:Pl,pointer:Pl,eventTarget:Kl,phase:"reflow"};Vl.interactable=Ml,Vl.element=Kl,Vl.prevEvent=Pl,Vl.updatePointer(Pl,Pl,Kl,!0),he(Vl.coords.delta),Sa(Vl.prepared,Ol),Vl._doPhase(rn);var tr=bl.window,un=tr.Promise,kn=un?new un(function(Tn){Vl._reflowResolve=Tn}):void 0;return Vl._reflowPromise=kn,Vl.start(Ol,Ml,Kl),Vl._interacting?(Vl.move(rn),Vl.end(Pl)):(Vl.stop(),Vl._reflowResolve()),Vl.removePointer(Pl,Pl),kn}(R,y,ia,S,El)}ke&&ke.push(el)},Ee=0;Ee<K.length&&!je();Ee++);return ke&&Z.all(ke).then(function(){return y})}(this,f,t)}},listeners:{"interactions:stop":function(t,o){var f=t.interaction;f.pointerType==="reflow"&&(f._reflowResolve&&f._reflowResolve(),function(y,S){y.splice(y.indexOf(S),1)}(o.interactions.list,f))}}},gi=po;if(ln.use(br),ln.use(Fl),ln.use(tt),ln.use(cn),ln.use(et),ln.use(Cr),ln.use(il),ln.use(pe),ln.use(gi),ln.default=ln,i(a)==="object"&&a)try{a.exports=ln}catch{}return ln.default=ln,ln})}(Wi,Wi.exports)),Wi.exports}var C1=E1();const Ls=A.getDefaultExportFromCjs(C1),$o=e.defineComponent({__name:"grid-item",props:{isDraggable:{type:Boolean,default:void 0},isResizable:{type:Boolean,default:void 0},isBounded:{type:Boolean,default:void 0},static:{type:Boolean,default:!1},minH:{default:1},minW:{default:1},maxH:{default:1/0},maxW:{default:1/0},x:{},y:{},w:{},h:{},i:{},dragIgnoreFrom:{default:"a, button"},dragAllowFrom:{default:void 0},resizeIgnoreFrom:{default:"a, button"},preserveAspectRatio:{type:Boolean,default:!1},dragOption:{default:()=>({})},resizeOption:{default:()=>({})}},emits:["container-resized","resize","resized","move","moved"],setup(a,{expose:l,emit:n}){const r=a,i=n,s=e.inject(Wc),h=e.inject(Kc);if(!s)throw new Error("[grid-layout-plus]: missing layout store, GridItem must under a GridLayout.");const c=e.shallowRef(null),d=e.reactive({cols:1,containerWidth:100,rowHeight:30,margin:[10,10],maxRows:1/0,draggable:void 0,resizable:void 0,bounded:void 0,transformScale:1,useCssTransforms:!0,useStyleCursor:!0,isDragging:!1,dragging:{top:-1,left:-1},isResizing:!1,resizing:{width:-1,height:-1},style:{},rtl:!1});let m=!1,b=!1,u=NaN,C=NaN,M=NaN,k=NaN,W=-1,O=-1,j=-1,L=-1,_=r.x,x=r.y,w=r.w,g=r.h;const E=e.ref(),P=e.reactive({i:e.toRef(r,"i"),state:d,wrapper:E,calcXY:ue});function V(fe){Ke(fe)}function ee(){ua()}function J(fe){xn(r.isDraggable)&&(d.draggable=fe)}function me(fe){xn(r.isResizable)&&(d.resizable=fe)}function _e(fe){xn(r.isBounded)&&(d.bounded=fe)}function z(fe){d.transformScale=fe}function ne(fe){d.rowHeight=fe}function Y(fe){d.maxRows=fe}function te(){d.rtl=Is()==="rtl",ua()}function ye(fe){d.cols=Math.floor(fe)}s.increaseItem(P),e.onBeforeMount(()=>{d.rtl=Is()==="rtl"}),e.onMounted(()=>{s.responsive&&s.lastBreakpoint?d.cols=Zc(s.lastBreakpoint,s.cols):d.cols=s.colNum,d.rowHeight=s.rowHeight,d.containerWidth=s.width!==null?s.width:100,d.margin=s.margin!==void 0?s.margin.map(Number):[10,10],d.maxRows=s.maxRows,xn(r.isDraggable)?d.draggable=s.isDraggable:d.draggable=r.isDraggable,xn(r.isResizable)?d.resizable=s.isResizable:d.resizable=r.isResizable,xn(r.isBounded)?d.bounded=s.isBounded:d.bounded=r.isBounded,d.transformScale=s.transformScale,d.useCssTransforms=s.useCssTransforms,d.useStyleCursor=s.useStyleCursor,e.watchEffect(()=>{_=r.x,x=r.y,g=r.h,w=r.w,dn(Le)}),h.on("updateWidth",V),h.on("compact",ee),h.on("setDraggable",J),h.on("setResizable",me),h.on("setBounded",_e),h.on("setTransformScale",z),h.on("setRowHeight",ne),h.on("setMaxRows",Y),h.on("directionchange",te),h.on("setColNum",ye)}),e.onBeforeUnmount(()=>{h.off("updateWidth",V),h.off("compact",ee),h.off("setDraggable",J),h.off("setResizable",me),h.off("setBounded",_e),h.off("setTransformScale",z),h.off("setRowHeight",ne),h.off("setMaxRows",Y),h.off("directionchange",te),h.off("setColNum",ye),c.value&&(c.value.unset(),c.value=null),s.decreaseItem(P)}),l({state:d,wrapper:E});const $e=typeof navigator<"u"?navigator.userAgent.toLowerCase().includes("android"):!1,de=e.computed(()=>d.resizable&&!r.static),T=e.computed(()=>s.isMirrored?!d.rtl:d.rtl),ie=e.computed(()=>(d.draggable||d.resizable)&&!r.static),U=y1("item"),ge=e.computed(()=>({[U.b()]:!0,[U.bm("resizable")]:de.value,[U.bm("static")]:r.static,[U.bm("resizing")]:d.isResizing,[U.bm("dragging")]:d.isDragging,[U.bm("transform")]:d.useCssTransforms,[U.bm("rtl")]:T.value,[U.bm("no-touch")]:$e&&ie.value})),ze=e.computed(()=>[U.be("resizer"),T.value&&U.bem("resizer","rtl")].filter(Boolean));e.watch(()=>r.isDraggable,fe=>{d.draggable=fe}),e.watch(()=>r.static,()=>{dn(H),dn(he)}),e.watch(()=>d.draggable,()=>{dn(H)}),e.watch(()=>r.isResizable,fe=>{d.resizable=fe}),e.watch(()=>r.isBounded,fe=>{d.bounded=fe}),e.watch(()=>d.resizable,()=>{dn(he)}),e.watch(()=>d.rowHeight,()=>{dn(Le),dn(ra)}),e.watch([()=>d.cols,()=>d.containerWidth],()=>{dn(he),dn(Le),dn(ra)}),e.watch([()=>r.minH,()=>r.maxH,()=>r.minW,()=>r.maxW],()=>{dn(he)}),e.watch(T,()=>{dn(he),dn(Le)}),e.watch([()=>s.margin,()=>s.margin[0],()=>s.margin[1]],()=>{const fe=s.margin;!fe||fe[0]===d.margin[0]&&fe[1]===d.margin[1]||(d.margin=fe.map(Number),dn(Le),dn(ra))});function Le(){r.x+r.w>d.cols?(_=0,w=r.w>d.cols?d.cols:r.w):(_=r.x,w=r.w);const fe=ca(_,x,w,g);d.isDragging&&(fe.top=d.dragging.top,T.value?fe.right=d.dragging.left:fe.left=d.dragging.left),d.isResizing&&(fe.width=d.resizing.width,fe.height=d.resizing.height);let ha;d.useCssTransforms?T.value?ha=f1(fe.top,fe.right,fe.width,fe.height):ha=p1(fe.top,fe.left,fe.width,fe.height):T.value?ha=v1(fe.top,fe.right,fe.width,fe.height):ha=h1(fe.top,fe.left,fe.width,fe.height),d.style=ha}function ra(){const fe={};for(const ha of["width","height"]){const ta=d.style[ha].match(/^(\d+)px$/);if(!ta)return;fe[ha]=ta[1]}i("container-resized",r.i,r.h,r.w,fe.height,fe.width)}function Ca(fe){if(r.static)return;const ha=fe.type;if(ha==="resizestart"&&d.isResizing||ha!=="resizestart"&&!d.isResizing)return;const ta=zs(fe);if(xn(ta))return;const{x:Fe,y:xa}=ta,Ae={width:0,height:0};let va;switch(ha){case"resizestart":{he(),W=w,O=g,va=ca(_,x,w,g),Ae.width=va.width,Ae.height=va.height,d.resizing=Ae,d.isResizing=!0;break}case"resizemove":{!fe.edges.right&&!fe.edges.left&&(M=Fe),!fe.edges.top&&!fe.edges.bottom&&(k=xa);const La=Ms(M,k,Fe,xa);T.value?Ae.width=d.resizing.width-La.deltaX/d.transformScale:Ae.width=d.resizing.width+La.deltaX/d.transformScale,Ae.height=d.resizing.height+La.deltaY/d.transformScale,d.resizing=Ae;break}case"resizeend":{va=ca(_,x,w,g),Ae.width=va.width,Ae.height=va.height,d.resizing={width:-1,height:-1},d.isResizing=!1;break}}va=De(Ae.height,Ae.width),va.w<r.minW&&(va.w=r.minW),va.w>r.maxW&&(va.w=r.maxW),va.h<r.minH&&(va.h=r.minH),va.h>r.maxH&&(va.h=r.maxH),va.h<1&&(va.h=1),va.w<1&&(va.w=1),M=Fe,k=xa,(w!==va.w||g!==va.h)&&i("resize",r.i,va.h,va.w,Ae.height,Ae.width),fe.type==="resizeend"&&(W!==w||O!==g)&&i("resized",r.i,va.h,va.w,Ae.height,Ae.width),h.emit("resizeEvent",fe.type,r.i,_,x,va.h,va.w)}function Q(fe){if(r.static||d.isResizing)return;const ha=fe.type;if(ha==="dragstart"&&d.isDragging||ha!=="dragstart"&&!d.isDragging)return;const ta=zs(fe);if(xn(ta))return;const{x:Fe,y:xa}=ta,Ae=fe.target;if(!Ae.offsetParent)return;const va={top:0,left:0};switch(ha){case"dragstart":{j=_,L=x;const Ia=Ae.offsetParent.getBoundingClientRect(),fa=Ae.getBoundingClientRect(),Ba=fa.left/d.transformScale,Te=Ia.left/d.transformScale,be=fa.right/d.transformScale,Be=Ia.right/d.transformScale,ae=fa.top/d.transformScale,se=Ia.top/d.transformScale;T.value?va.left=(be-Be)*-1:va.left=Ba-Te,va.top=ae-se,d.dragging=va,d.isDragging=!0;break}case"dragmove":{const Ia=Ms(u,C,Fe,xa);if(T.value?va.left=d.dragging.left-Ia.deltaX/d.transformScale:va.left=d.dragging.left+Ia.deltaX/d.transformScale,va.top=d.dragging.top+Ia.deltaY/d.transformScale,d.bounded){const fa=Ae.offsetParent.clientHeight-Se(r.h,d.rowHeight,d.margin[1]);va.top=ce(va.top,0,fa);const Ba=pa(),Te=d.containerWidth-Se(r.w,Ba,d.margin[0]);va.left=ce(va.left,0,Te)}d.dragging=va;break}case"dragend":{const Ia=Ae.offsetParent.getBoundingClientRect(),fa=Ae.getBoundingClientRect(),Ba=fa.left/d.transformScale,Te=Ia.left/d.transformScale,be=fa.right/d.transformScale,Be=Ia.right/d.transformScale,ae=fa.top/d.transformScale,se=Ia.top/d.transformScale;T.value?va.left=(be-Be)*-1:va.left=Ba-Te,va.top=ae-se,d.dragging={top:-1,left:-1},d.isDragging=!1;break}}let La;T.value,La=ue(va.top,va.left),u=Fe,C=xa,(_!==La.x||x!==La.y)&&i("move",r.i,La.x,La.y),fe.type==="dragend"&&(j!==_||L!==x)&&i("moved",r.i,La.x,La.y),h.emit("dragEvent",fe.type,r.i,La.x,La.y,g,w)}function ca(fe,ha,ta,Fe){const xa=pa();let Ae;return T.value?Ae={right:Math.round(xa*fe+(fe+1)*d.margin[0]),top:Math.round(d.rowHeight*ha+(ha+1)*d.margin[1]),width:ta===1/0?ta:Math.round(xa*ta+Math.max(0,ta-1)*d.margin[0]),height:Fe===1/0?Fe:Math.round(d.rowHeight*Fe+Math.max(0,Fe-1)*d.margin[1])}:Ae={left:Math.round(xa*fe+(fe+1)*d.margin[0]),top:Math.round(d.rowHeight*ha+(ha+1)*d.margin[1]),width:ta===1/0?ta:Math.round(xa*ta+Math.max(0,ta-1)*d.margin[0]),height:Fe===1/0?Fe:Math.round(d.rowHeight*Fe+Math.max(0,Fe-1)*d.margin[1])},Ae}function ue(fe,ha){const ta=pa();let Fe=Math.round((ha-d.margin[0])/(ta+d.margin[0])),xa=Math.round((fe-d.margin[1])/(d.rowHeight+d.margin[1]));return Fe=Math.max(Math.min(Fe,d.cols-w),0),xa=Math.max(Math.min(xa,d.maxRows-g),0),{x:Fe,y:xa}}function pa(){return(d.containerWidth-d.margin[0]*(d.cols+1))/d.cols}function Se(fe,ha,ta){return Number.isFinite(fe)?Math.round(ha*fe+Math.max(0,fe-1)*ta):fe}function ce(fe,ha,ta){return Math.max(Math.min(fe,ta),ha)}function De(fe,ha,ta=!1){const Fe=pa();let xa=Math.round((ha+d.margin[0])/(Fe+d.margin[0])),Ae=0;return ta?Ae=Math.ceil((fe+d.margin[1])/(d.rowHeight+d.margin[1])):Ae=Math.round((fe+d.margin[1])/(d.rowHeight+d.margin[1])),xa=Math.max(Math.min(xa,d.cols-_),0),Ae=Math.max(Math.min(Ae,d.maxRows-x),0),{w:xa,h:Ae}}function Ke(fe,ha){d.containerWidth=fe}function ua(){Le()}function Za(){!c.value&&E.value&&(c.value=Ls(E.value),d.useStyleCursor||c.value.styleCursor(!1))}const $=Bs(Q);function H(){if(Za(),!!c.value)if(d.draggable&&!r.static){const fe={ignoreFrom:r.dragIgnoreFrom,allowFrom:r.dragAllowFrom,...r.dragOption};c.value.draggable(fe),m||(m=!0,c.value.on("dragstart dragmove dragend",ha=>{ha.type==="dragmove"?$(ha):Q(ha)}))}else c.value.draggable({enabled:!1})}const X=Bs(Ca);function he(){if(Za(),!!c.value)if(d.resizable&&!r.static){const fe=ca(0,0,r.maxW,r.maxH),ha=ca(0,0,r.minW,r.minH),ta={edges:{left:T.value?`.${ze.value[0]}`:!1,right:T.value?!1:`.${ze.value[0]}`,bottom:`.${ze.value[0]}`,top:!1},ignoreFrom:r.resizeIgnoreFrom,restrictSize:{min:{height:ha.height*d.transformScale,width:ha.width*d.transformScale},max:{height:fe.height*d.transformScale,width:fe.width*d.transformScale}},...r.resizeOption};r.preserveAspectRatio&&(ta.modifiers=[Ls.modifiers.aspectRatio({ratio:"preserve"})]),c.value.resizable(ta),b||(b=!0,c.value.on("resizestart resizemove resizeend",Fe=>{Fe.type==="resizemove"?X(Fe):Ca(Fe)}))}else c.value.resizable({enabled:!1})}return(fe,ha)=>(e.openBlock(),e.createElementBlock("section",{ref_key:"wrapper",ref:E,class:e.normalizeClass(ge.value),style:e.normalizeStyle(d.style)},[e.renderSlot(fe.$slots,"default"),de.value?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(ze.value)},null,2)):e.createCommentVNode("",!0)],6))}}),fi=typeof window<"u";var Rs;fi&&(Rs=window==null?void 0:window.navigator)!=null&&Rs.userAgent&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function $s(a){return a!=null}function Vs(){}const D1=Object.freeze({aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"});Object.freeze(new Set(Object.keys(D1)));const T1=fi&&("ontouchstart"in window||N1()>0),B1=T1?"pointerdown":"click";function N1(){return typeof navigator<"u"&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)||0}function A1(a,l,n=window.Event){const{type:r,bubbles:i=!1,cancelable:s=!1,...h}=l;if(!$s(r)||r==="")return!1;let c;return $s(n)?c=new n(r,{bubbles:i,cancelable:s}):(c=document.createEvent("HTMLEvents"),c.initEvent(r,i,s)),Object.assign(c,h),a.dispatchEvent(c)}const z1="clickoutside",M1=new Set;fi&&document.addEventListener(B1,a=>{const l=a.target,n=a.composedPath&&a.composedPath();M1.forEach(r=>{r!==l&&(n?!n.includes(r):!r.contains(l))&&(!r.__transferElement||r.__transferElement!==l&&!r.__transferElement.contains(l))&&A1(r,{type:z1})})},!0);const I1=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]];let Do;if(fi){for(const a of I1)if(a[1]in document){Do=a;break}}e.computed(()=>!1);const O1=new Set,L1=new WeakMap;if(fi&&Do){const a=Do[2],l=Do[4];document.addEventListener(l,()=>{if(O1.forEach(n=>{n.value=!1}),document[a]){const n=L1.get(document[a]);n&&(n.value=!0)}},!1)}const eu=new Map;eu.set("x",0);eu.set("y",0);var di=[],R1=function(){return di.some(function(a){return a.activeTargets.length>0})},$1=function(){return di.some(function(a){return a.skippedTargets.length>0})},Ps="ResizeObserver loop completed with undelivered notifications.",V1=function(){var a;typeof ErrorEvent=="function"?a=new ErrorEvent("error",{message:Ps}):(a=document.createEvent("Event"),a.initEvent("error",!1,!1),a.message=Ps),window.dispatchEvent(a)},Qi;(function(a){a.BORDER_BOX="border-box",a.CONTENT_BOX="content-box",a.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(Qi||(Qi={}));var pi=function(a){return Object.freeze(a)},P1=function(){function a(l,n){this.inlineSize=l,this.blockSize=n,pi(this)}return a}(),au=function(){function a(l,n,r,i){return this.x=l,this.y=n,this.width=r,this.height=i,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,pi(this)}return a.prototype.toJSON=function(){var l=this,n=l.x,r=l.y,i=l.top,s=l.right,h=l.bottom,c=l.left,d=l.width,m=l.height;return{x:n,y:r,top:i,right:s,bottom:h,left:c,width:d,height:m}},a.fromRect=function(l){return new a(l.x,l.y,l.width,l.height)},a}(),It=function(a){return a instanceof SVGElement&&"getBBox"in a},lu=function(a){if(It(a)){var l=a.getBBox(),n=l.width,r=l.height;return!n&&!r}var i=a,s=i.offsetWidth,h=i.offsetHeight;return!(s||h||a.getClientRects().length)},Fs=function(a){var l;if(a instanceof Element)return!0;var n=(l=a==null?void 0:a.ownerDocument)===null||l===void 0?void 0:l.defaultView;return!!(n&&a instanceof n.Element)},F1=function(a){switch(a.tagName){case"INPUT":if(a.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},Ji=typeof window<"u"?window:{},_o=new WeakMap,js=/auto|scroll/,j1=/^tb|vertical/,H1=/msie|trident/i.test(Ji.navigator&&Ji.navigator.userAgent),Mn=function(a){return parseFloat(a||"0")},Bi=function(a,l,n){return a===void 0&&(a=0),l===void 0&&(l=0),n===void 0&&(n=!1),new P1((n?l:a)||0,(n?a:l)||0)},Hs=pi({devicePixelContentBoxSize:Bi(),borderBoxSize:Bi(),contentBoxSize:Bi(),contentRect:new au(0,0,0,0)}),ru=function(a,l){if(l===void 0&&(l=!1),_o.has(a)&&!l)return _o.get(a);if(lu(a))return _o.set(a,Hs),Hs;var n=getComputedStyle(a),r=It(a)&&a.ownerSVGElement&&a.getBBox(),i=!H1&&n.boxSizing==="border-box",s=j1.test(n.writingMode||""),h=!r&&js.test(n.overflowY||""),c=!r&&js.test(n.overflowX||""),d=r?0:Mn(n.paddingTop),m=r?0:Mn(n.paddingRight),b=r?0:Mn(n.paddingBottom),u=r?0:Mn(n.paddingLeft),C=r?0:Mn(n.borderTopWidth),M=r?0:Mn(n.borderRightWidth),k=r?0:Mn(n.borderBottomWidth),W=r?0:Mn(n.borderLeftWidth),O=u+m,j=d+b,L=W+M,_=C+k,x=c?a.offsetHeight-_-a.clientHeight:0,w=h?a.offsetWidth-L-a.clientWidth:0,g=i?O+L:0,E=i?j+_:0,P=r?r.width:Mn(n.width)-g-w,V=r?r.height:Mn(n.height)-E-x,ee=P+O+w+L,J=V+j+x+_,me=pi({devicePixelContentBoxSize:Bi(Math.round(P*devicePixelRatio),Math.round(V*devicePixelRatio),s),borderBoxSize:Bi(ee,J,s),contentBoxSize:Bi(P,V,s),contentRect:new au(u,d,P,V)});return _o.set(a,me),me},nu=function(a,l,n){var r=ru(a,n),i=r.borderBoxSize,s=r.contentBoxSize,h=r.devicePixelContentBoxSize;switch(l){case Qi.DEVICE_PIXEL_CONTENT_BOX:return h;case Qi.BORDER_BOX:return i;default:return s}},U1=function(){function a(l){var n=ru(l);this.target=l,this.contentRect=n.contentRect,this.borderBoxSize=pi([n.borderBoxSize]),this.contentBoxSize=pi([n.contentBoxSize]),this.devicePixelContentBoxSize=pi([n.devicePixelContentBoxSize])}return a}(),iu=function(a){if(lu(a))return 1/0;for(var l=0,n=a.parentNode;n;)l+=1,n=n.parentNode;return l},q1=function(){var a=1/0,l=[];di.forEach(function(s){if(s.activeTargets.length!==0){var h=[];s.activeTargets.forEach(function(c){var d=new U1(c.target),m=iu(c.target);h.push(d),c.lastReportedSize=nu(c.target,c.observedBox),m<a&&(a=m)}),l.push(function(){s.callback.call(s.observer,h,s.observer)}),s.activeTargets.splice(0,s.activeTargets.length)}});for(var n=0,r=l;n<r.length;n++){var i=r[n];i()}return a},Us=function(a){di.forEach(function(l){l.activeTargets.splice(0,l.activeTargets.length),l.skippedTargets.splice(0,l.skippedTargets.length),l.observationTargets.forEach(function(n){n.isActive()&&(iu(n.target)>a?l.activeTargets.push(n):l.skippedTargets.push(n))})})},W1=function(){var a=0;for(Us(a);R1();)a=q1(),Us(a);return $1()&&V1(),a>0},yt,ou=[],K1=function(){return ou.splice(0).forEach(function(a){return a()})},G1=function(a){if(!yt){var l=0,n=document.createTextNode(""),r={characterData:!0};new MutationObserver(function(){return K1()}).observe(n,r),yt=function(){n.textContent="".concat(l?l--:l++)}}ou.push(a),yt()},Y1=function(a){G1(function(){requestAnimationFrame(a)})},To=0,J1=function(){return!!To},X1=250,Z1={attributes:!0,characterData:!0,childList:!0,subtree:!0},qs=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],Ws=function(a){return a===void 0&&(a=0),Date.now()+a},gt=!1,Q1=function(){function a(){var l=this;this.stopped=!0,this.listener=function(){return l.schedule()}}return a.prototype.run=function(l){var n=this;if(l===void 0&&(l=X1),!gt){gt=!0;var r=Ws(l);Y1(function(){var i=!1;try{i=W1()}finally{if(gt=!1,l=r-Ws(),!J1())return;i?n.run(1e3):l>0?n.run(l):n.start()}})}},a.prototype.schedule=function(){this.stop(),this.run()},a.prototype.observe=function(){var l=this,n=function(){return l.observer&&l.observer.observe(document.body,Z1)};document.body?n():Ji.addEventListener("DOMContentLoaded",n)},a.prototype.start=function(){var l=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),qs.forEach(function(n){return Ji.addEventListener(n,l.listener,!0)}))},a.prototype.stop=function(){var l=this;this.stopped||(this.observer&&this.observer.disconnect(),qs.forEach(function(n){return Ji.removeEventListener(n,l.listener,!0)}),this.stopped=!0)},a}(),At=new Q1,Ks=function(a){!To&&a>0&&At.start(),To+=a,!To&&At.stop()},ev=function(a){return!It(a)&&!F1(a)&&getComputedStyle(a).display==="inline"},av=function(){function a(l,n){this.target=l,this.observedBox=n||Qi.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return a.prototype.isActive=function(){var l=nu(this.target,this.observedBox,!0);return ev(this.target)&&(this.lastReportedSize=l),this.lastReportedSize.inlineSize!==l.inlineSize||this.lastReportedSize.blockSize!==l.blockSize},a}(),lv=function(){function a(l,n){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=l,this.callback=n}return a}(),So=new WeakMap,Gs=function(a,l){for(var n=0;n<a.length;n+=1)if(a[n].target===l)return n;return-1},Eo=function(){function a(){}return a.connect=function(l,n){var r=new lv(l,n);So.set(l,r)},a.observe=function(l,n,r){var i=So.get(l),s=i.observationTargets.length===0;Gs(i.observationTargets,n)<0&&(s&&di.push(i),i.observationTargets.push(new av(n,r&&r.box)),Ks(1),At.schedule())},a.unobserve=function(l,n){var r=So.get(l),i=Gs(r.observationTargets,n),s=r.observationTargets.length===1;i>=0&&(s&&di.splice(di.indexOf(r),1),r.observationTargets.splice(i,1),Ks(-1))},a.disconnect=function(l){var n=this,r=So.get(l);r.observationTargets.slice().forEach(function(i){return n.unobserve(l,i.target)}),r.activeTargets.splice(0,r.activeTargets.length)},a}(),rv=function(){function a(l){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof l!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Eo.connect(this,l)}return a.prototype.observe=function(l,n){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Fs(l))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Eo.observe(this,l,n)},a.prototype.unobserve=function(l){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Fs(l))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Eo.unobserve(this,l)},a.prototype.disconnect=function(){Eo.disconnect(this)},a.toString=function(){return"function ResizeObserver () { [polyfill code] }"},a}();const Vo=new WeakMap;function nv(a){var l;for(let n=0,r=a.length;n<r;++n){const i=a[n],s=Vo.get(i.target);if(typeof s=="function"){const{inlineSize:h,blockSize:c}=((l=i.borderBoxSize)==null?void 0:l[0])??{},{offsetWidth:d,offsetHeight:m}=i.target;s(Object.assign(i,{offsetWidth:d,offsetHeight:m,width:h??d,height:c??m}))}}}const tu=new(fi&&window.ResizeObserver||rv)(nv);function Ys(a,l){Vo.set(a,l),tu.observe(a)}function Js(a){Vo.has(a)&&(tu.unobserve(a),Vo.delete(a))}function iv(a={}){let l=Vs;const n=e.watch(()=>e.unref(a.target),i=>{l(),!(!i||typeof a.onResize!="function")&&(Ys(i,a.onResize),l=()=>{Js(i),l=Vs})},{immediate:!0}),r=()=>{n(),l()};return e.getCurrentScope()&&e.onScopeDispose(r),{observeResize:Ys,unobserveResize:Js,unobserve:r}}const ov=e.ref(!1);e.computed(()=>ov.value);const Xs="__theme_style__",bt="__theme_observer__",Zs=e.reactive(new Map),Qs=new Map;e.watch(Zs,()=>{if(!fi)return;Qs.clear();const a=document.head.querySelector(`#${Xs}`);a&&document.head.removeChild(a);const l=document.createElement("style");let n=`.${bt} { width: 1px }`,r=1;for(const[i,[s,h]]of Zs.entries())n+=` html.${s} .${bt}, .${h} .${bt} { width: ${++r}px }`,Qs.set(r,i);l.textContent=n,l.id=Xs,document.head.appendChild(l)});const su=e.defineComponent({__name:"grid-layout",props:{autoSize:{type:Boolean,default:!0},colNum:{default:12},rowHeight:{default:150},maxRows:{default:1/0},margin:{default:()=>[10,10]},isDraggable:{type:Boolean,default:!0},isResizable:{type:Boolean,default:!0},isMirrored:{type:Boolean,default:!1},isBounded:{type:Boolean,default:!1},useCssTransforms:{type:Boolean,default:!0},verticalCompact:{type:Boolean,default:!0},restoreOnDrag:{type:Boolean,default:!1},layout:{},responsive:{type:Boolean,default:!1},responsiveLayouts:{default:()=>({})},transformScale:{default:1},breakpoints:{default:()=>({lg:1200,md:996,sm:768,xs:480,xxs:0})},cols:{default:()=>({lg:12,md:10,sm:6,xs:4,xxs:2})},preventCollision:{type:Boolean,default:!1},useStyleCursor:{type:Boolean,default:!0}},emits:["layout-before-mount","layout-mounted","layout-updated","breakpoint-changed","update:layout","layout-ready"],setup(a,{expose:l,emit:n}){const r=a,i=n,s=e.reactive({width:-1,mergedStyle:{},lastLayoutLength:0,isDragging:!1,placeholder:{x:0,y:0,w:0,h:0,i:""},layouts:{},lastBreakpoint:null,originalLayout:null}),h=new Map,c=e.ref(r.layout),d=e.ref(),{observeResize:m,unobserveResize:b}=iv(),u=n1();u.on("resizeEvent",C),u.on("dragEvent",M),e.onBeforeMount(()=>{i("layout-before-mount",c.value)}),e.onMounted(()=>{i("layout-mounted",c.value),e.nextTick(()=>{m1(c.value),s.originalLayout=c.value,e.nextTick(()=>{V(),d.value&&m(d.value,i1(_,16)),Ci(c.value,r.verticalCompact),i("layout-updated",c.value),L(),_()})})}),e.onBeforeUnmount(()=>{u.clearAll(),d.value&&b(d.value)});function C(J,me,_e,z,ne,Y){E(J,me,_e,z,ne,Y)}function M(J,me,_e,z,ne,Y){g(J,me,_e,z,ne,Y)}e.watch(()=>s.width,(J,me)=>{e.nextTick(()=>{u.emit("updateWidth",J),me===-1&&e.nextTick(()=>{i("layout-ready",c.value)}),L()})}),e.watch(()=>[r.layout,r.layout.length],()=>{c.value=r.layout,j()}),e.watch(()=>r.colNum,J=>{u.emit("setColNum",J)}),e.watch(()=>r.rowHeight,J=>{u.emit("setRowHeight",J)}),e.watch(()=>r.isDraggable,J=>{u.emit("setDraggable",J)}),e.watch(()=>r.isResizable,J=>{u.emit("setResizable",J)}),e.watch(()=>r.isBounded,J=>{u.emit("setBounded",J)}),e.watch(()=>r.transformScale,J=>{u.emit("setTransformScale",J)}),e.watch(()=>r.responsive,J=>{J||(i("update:layout",s.originalLayout),u.emit("setColNum",r.colNum)),_()}),e.watch(()=>r.maxRows,J=>{u.emit("setMaxRows",J)}),e.watch([()=>r.margin,()=>r.margin[1]],L),e.provide(Wc,e.reactive({...e.toRefs(r),...e.toRefs(s),increaseItem:k,decreaseItem:W})),e.provide(Kc,u),l({state:s,getItem:O,resizeEvent:E,dragEvent:g,layoutUpdate:j});function k(J){h.set(J.i,J)}function W(J){h.delete(J.i)}function O(J){return h.get(J)}function j(){if(!xn(c.value)&&!xn(s.originalLayout)){if(c.value.length!==s.originalLayout.length){const J=ee(c.value,s.originalLayout);if(J.length>0)if(c.value.length>s.originalLayout.length)s.originalLayout=s.originalLayout.concat(J);else{const me=new Set(J.map(_e=>_e.i));s.originalLayout=s.originalLayout.filter(_e=>!me.has(_e.i))}s.lastLayoutLength=c.value.length,V()}Ci(c.value,r.verticalCompact),u.emit("updateWidth",s.width),L(),i("layout-updated",c.value)}}function L(){s.mergedStyle={height:x()}}function _(){d.value&&(s.width=d.value.offsetWidth),u.emit("resizeEvent")}function x(){if(!r.autoSize)return;const J=parseFloat(r.margin[1]);return s1(c.value)*(r.rowHeight+J)+J+"px"}let w;function g(J,me,_e,z,ne,Y){let te=Ns(c.value,me);xn(te)&&(te={h:0,w:0,x:0,y:0,i:""}),J==="dragstart"&&!r.verticalCompact&&(w=c.value.reduce((ye,{i:$e,x:de,y:T})=>({...ye,[$e]:{x:de,y:T}}),{})),J==="dragmove"||J==="dragstart"?(s.placeholder.i=me,s.placeholder.x=te.x,s.placeholder.y=te.y,s.placeholder.w=Y,s.placeholder.h=ne,e.nextTick(()=>{s.isDragging=!0}),u.emit("updateWidth",s.width)):e.nextTick(()=>{s.isDragging=!1}),c.value=Nt(c.value,te,_e,z,!0,r.preventCollision),r.restoreOnDrag?(te.static=!0,Ci(c.value,r.verticalCompact,w),te.static=!1):Ci(c.value,r.verticalCompact),u.emit("compact"),L(),J==="dragend"&&(w=void 0,i("layout-updated",c.value))}function E(J,me,_e,z,ne,Y){let te=Ns(c.value,me);xn(te)&&(te={h:0,w:0,x:0,y:0,i:""});let ye;if(r.preventCollision){const $e=Yc(c.value,{...te,w:Y,h:ne}).filter(de=>de.i!==te.i);if(ye=$e.length>0,ye){let de=1/0,T=1/0;$e.forEach(ie=>{ie.x>te.x&&(de=Math.min(de,ie.x)),ie.y>te.y&&(T=Math.min(T,ie.y))}),Number.isFinite(de)&&(te.w=de-te.x),Number.isFinite(T)&&(te.h=T-te.y)}}ye||(te.w=Y,te.h=ne),J==="resizestart"||J==="resizemove"?(s.placeholder.i=me,s.placeholder.x=_e,s.placeholder.y=z,s.placeholder.w=te.w,s.placeholder.h=te.h,e.nextTick(()=>{s.isDragging=!0}),u.emit("updateWidth",s.width)):J&&e.nextTick(()=>{s.isDragging=!1}),r.responsive&&P(),Ci(c.value,r.verticalCompact),u.emit("compact"),L(),J==="resizeend"&&i("layout-updated",c.value)}function P(){const J=k1(r.breakpoints,s.width);if(J===s.lastBreakpoint)return;const me=Zc(J,r.cols);!xn(s.lastBreakpoint)&&!s.layouts[s.lastBreakpoint]&&(s.layouts[s.lastBreakpoint]=Bt(c.value));const _e=x1(s.originalLayout,s.layouts,r.breakpoints,J,s.lastBreakpoint,me,r.verticalCompact);s.layouts[J]=_e,s.lastBreakpoint!==J&&i("breakpoint-changed",J,_e),c.value=_e,i("update:layout",_e),s.lastBreakpoint=J,u.emit("setColNum",me)}function V(){s.layouts=Object.assign({},r.responsiveLayouts)}function ee(J,me){const _e=new Set(me.map(te=>te.i)),z=new Set(J.map(te=>te.i)),ne=J.filter(te=>!_e.has(te.i)),Y=me.filter(te=>!z.has(te.i));return ne.concat(Y)}return(J,me)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"wrapper",ref:d,class:"vgl-layout",style:e.normalizeStyle(s.mergedStyle)},[J.$slots.default?e.renderSlot(J.$slots,"default",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(c.value,_e=>(e.openBlock(),e.createBlock($o,e.mergeProps({key:_e.i,ref_for:!0},_e),{default:e.withCtx(()=>[e.renderSlot(J.$slots,"item",{item:_e})]),_:2},1040))),128)),e.withDirectives(e.createVNode($o,{class:"vgl-item--placeholder",x:s.placeholder.x,y:s.placeholder.y,w:s.placeholder.w,h:s.placeholder.h,i:s.placeholder.i},null,8,["x","y","w","h","i"]),[[e.vShow,s.isDragging]])],4))}});(function(){try{if(typeof document<"u"){var a=document.createElement("style");a.appendChild(document.createTextNode('.vgl-layout{--vgl-placeholder-bg: red;--vgl-placeholder-opacity: 20%;--vgl-placeholder-z-index: 2;--vgl-item-resizing-z-index: 3;--vgl-item-resizing-opacity: 60%;--vgl-item-dragging-z-index: 3;--vgl-item-dragging-opacity: 100%;--vgl-resizer-size: 10px;--vgl-resizer-border-color: #444;--vgl-resizer-border-width: 2px;position:relative;box-sizing:border-box;transition:height .2s ease}.vgl-item{position:absolute;box-sizing:border-box;transition:.2s ease;transition-property:left,top,right}.vgl-item--placeholder{z-index:var(--vgl-placeholder-z-index, 2);-webkit-user-select:none;-moz-user-select:none;user-select:none;background-color:var(--vgl-placeholder-bg, red);opacity:var(--vgl-placeholder-opacity, 20%);transition-duration:.1s}.vgl-item--no-touch{touch-action:none}.vgl-item--transform{right:auto;left:0;transition-property:transform}.vgl-item--transform.vgl-item--rtl{right:0;left:auto}.vgl-item--resizing{z-index:var(--vgl-item-resizing-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-resizing-opacity, 60%)}.vgl-item--dragging{z-index:var(--vgl-item-dragging-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-dragging-opacity, 100%);transition:none}.vgl-item__resizer{position:absolute;right:0;bottom:0;box-sizing:border-box;width:var(--vgl-resizer-size);height:var(--vgl-resizer-size);cursor:se-resize}.vgl-item__resizer:before{position:absolute;top:0;right:3px;bottom:3px;left:0;content:"";border:0 solid var(--vgl-resizer-border-color);border-right-width:var(--vgl-resizer-border-width);border-bottom-width:var(--vgl-resizer-border-width)}.vgl-item__resizer--rtl{right:auto;left:0;cursor:sw-resize}.vgl-item__resizer--rtl:before{top:0;right:0;bottom:3px;left:3px;border-right-width:0;border-bottom-width:var(--vgl-resizer-border-width);border-left-width:var(--vgl-resizer-border-width)}')),document.head.appendChild(a)}}catch(l){console.error("vite-plugin-css-injected-by-js",l)}})();const tv={key:0,class:"item-view-group"},sv={key:0,class:"item-view-group"},cv=e.defineComponent({__name:"index",props:{children:{type:Object,default:()=>{}},level:{type:Number,default:1}},emits:["rowClick","routeUrl","radioChange"],setup(a,{emit:l}){const n=A.useModelComp(A.pinia),{isEdit:r}=A.storeToRefs(n),i=Yn(A.pinia),s=l,h=a,c=e.ref(""),d=e.computed(()=>h==null?void 0:h.children),m=e.computed(()=>{var L,_,x,w;return((L=h==null?void 0:h.children)==null?void 0:L.length)>0&&((_=h==null?void 0:h.children)!=null&&_.every(g=>g==null?void 0:g.layout))?(w=(x=h==null?void 0:h.children)==null?void 0:x[0])==null?void 0:w.layout:"vertical"}),b=L=>{c.value=L,s("radioChange",L)},u=e.computed(()=>{var L,_;return((_=(L=h==null?void 0:h.children)==null?void 0:L[0])==null?void 0:_.isGridLayout)||!1}),C=e.ref((h==null?void 0:h.level)+1),M=e.computed(()=>{if(!(h!=null&&h.children)||!Array.isArray(h.children)||h.children.length<2)return!1;const L=h.children.some(x=>(x==null?void 0:x.name)==="测量系统配置表"&&(x==null?void 0:x.comp)==="ParentItem"),_=h.children.some(x=>(x==null?void 0:x.name)==="测量系统传递表"&&(x==null?void 0:x.comp)==="ParentItem");return L&&_}),k=e.computed(()=>{var _,x,w,g,E,P;let L=(_=h==null?void 0:h.children)==null?void 0:_.filter(V=>V==null?void 0:V.choice);if(i.setSelectTab((x=L==null?void 0:L[0])==null?void 0:x.choiceName),(c==null?void 0:c.value)!=="")return(w=h==null?void 0:h.children)==null?void 0:w.filter(V=>!(V!=null&&V.choiceName)||(V==null?void 0:V.choiceName)===(c==null?void 0:c.value));{let V=(E=(g=h==null?void 0:h.children)==null?void 0:g.find(ee=>ee==null?void 0:ee.choice))==null?void 0:E.choiceName;return(P=h==null?void 0:h.children)==null?void 0:P.filter(ee=>!(ee!=null&&ee.choiceName)||(ee==null?void 0:ee.choiceName)===V)}}),W=L=>{const _=(L==null?void 0:L.menuFilter)||[];return Array.isArray(_)&&(_==null?void 0:_.some(x=>{const w=typeof x=="string"?x:JSON.stringify(x);return w==null?void 0:w.includes("HideGroup=Yes")}))};e.watch(()=>h==null?void 0:h.children,()=>{M.value},{deep:!0});const O=L=>{s("rowClick",L)},j=(L,_)=>{s("routeUrl",L,_)};return(L,_)=>u.value?(e.openBlock(),e.createBlock(e.unref(su),{key:0,layout:d.value,"onUpdate:layout":_[0]||(_[0]=x=>d.value=x),"is-draggable":e.unref(r)==="edit","is-resizable":e.unref(r)==="edit","col-num":24,margin:[8,16]},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(x,w)=>(e.openBlock(),e.createBlock(e.unref($o),{key:x.i,x:x.x,y:x.y,"min-h":x.minH,"max-h":x.maxH,"min-w":x.minW,w:x.w,h:x.h,i:x.i},{default:e.withCtx(()=>{var g,E,P,V,ee,J,me,_e,z,ne,Y,te,ye,$e;return[e.createElementVNode("div",{style:e.normalizeStyle({gap:"16px",display:"flex",flexDirection:"column",paddingBottom:w===((g=h==null?void 0:h.children)==null?void 0:g.length)-1?"0px":"24px"})},[((P=(E=x==null?void 0:x.component)==null?void 0:E.comp)==null?void 0:P.toUpperCase())!=="TABLE"&&((V=x==null?void 0:x.component)!=null&&V.name)?(e.openBlock(),e.createElementBlock("div",tv,[e.createElementVNode("div",{class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:(parseInt(C.value.toString())-1)*12+"px",fontWeight:600-(C.value-1)*100>=400?600-(C.value-1)*100:400,fontSize:17-C.value>=14?17-C.value+"px":"14px"})},e.toDisplayString((ee=x==null?void 0:x.component)==null?void 0:ee.name),5)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Zi)((J=x==null?void 0:x.component)==null?void 0:J.comp)),{pageLayout:m.value,config:{showIndex:(me=e.unref(dr)[w])==null?void 0:me.showIndex,allowMove:(_e=e.unref(dr)[w])==null?void 0:_e.allowMove,viewport:(z=e.unref(dr)[w])==null?void 0:z.viewport,status:(ne=e.unref(dr)[w])==null?void 0:ne.status},related:x==null?void 0:x.relatedTables,compName:x==null?void 0:x.component.name,compNames:e.unref(Tc),itemData:(Y=x==null?void 0:x.component)==null?void 0:Y.compData,childItemData:(te=x==null?void 0:x.component)==null?void 0:te.itemChildData,key:e.unref(Gn),cacheNewData:e.unref(Dc),onChange:e.unref(Io),index:(x==null?void 0:x.id)??w,onContentChange:e.unref(Oo),onPageChange:e.unref(Lo),parentTableId:(ye=x==null?void 0:x.component)==null?void 0:ye.tableId,allMapContents:e.unref(Ct),children:($e=x==null?void 0:x.component)==null?void 0:$e.children,level:C.value,onRowClick:O,onRouteUrl:j,onClickTrigger:e.unref(Bc),onClickMainKey:e.unref(Nc),onRadioChange:b},null,40,["pageLayout","config","related","compName","compNames","itemData","childItemData","cacheNewData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level","onClickTrigger","onClickMainKey"]))],4)]}),_:2},1032,["x","y","min-h","max-h","min-w","w","h","i"]))),128))]),_:1},8,["layout","is-draggable","is-resizable"])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(k.value,(x,w)=>{var g,E;return e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({gap:"16px",display:(x==null?void 0:x.isShow)===!1?"none":"flex",flexDirection:"column",paddingBottom:parseInt(w)===((g=h==null?void 0:h.children)==null?void 0:g.length)-1?"0px":"24px"})},[((E=x==null?void 0:x.comp)==null?void 0:E.toUpperCase())!=="TABLE"&&x.name?(e.openBlock(),e.createElementBlock("div",sv,[W(x)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:parseInt(C.value.toString())>1?"12px":"0px",fontWeight:600-(C.value-1)*100>=400?600-(C.value-1)*100:400,fontSize:17-C.value>=14?17-C.value+"px":"14px"})},e.toDisplayString(x.name),5))])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Zi)(x.comp)),{compName:x.name,groupNames:x==null?void 0:x.nameContents,config:{showIndex:x==null?void 0:x.showIndex,allowMove:x==null?void 0:x.allowMove,viewport:x==null?void 0:x.viewport,status:x==null?void 0:x.status},itemData:x==null?void 0:x.compData,related:x==null?void 0:x.relatedTables,childItemData:x==null?void 0:x.itemChildData,key:e.unref(Gn),onChange:e.unref(Io),index:(x==null?void 0:x.id)??w,onContentChange:e.unref(Oo),onPageChange:e.unref(Lo),parentTableId:x==null?void 0:x.tableId,allMapContents:e.unref(Ct),children:x==null?void 0:x.children,level:C.value,onRowClick:O,onRouteUrl:j,onRadioChange:b},null,40,["compName","groupNames","config","itemData","related","childItemData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level"]))],4)}),256))}}),uv=ar._export_sfc(cv,[["__scopeId","data-v-bafbdd45"]]),dv={class:"radio-group-container"},pv=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},emits:["radioChange"],setup(a,{emit:l}){const n=a,r=l,i=e.ref(),s=Yn(A.pinia),{selectTab:h}=A.storeToRefs(s);e.watch(()=>n==null?void 0:n.itemData,()=>{i.value=h.value},{immediate:!0,deep:!0});const c=d=>{i.value=d,r("radioChange",i.value)};return(d,m)=>(e.openBlock(),e.createElementBlock("div",dv,[e.createVNode(cl.ssRadio,{modelValue:i.value,"onUpdate:modelValue":m[0]||(m[0]=b=>i.value=b),content:n==null?void 0:n.itemData,onChange:c},null,8,["modelValue","content"])]))}}),fv=ar._export_sfc(pv,[["__scopeId","data-v-177d64c3"]]),hv=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(a){const l=a,n=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,()=>{var r,i;n.value=((i=(r=l==null?void 0:l.itemData)==null?void 0:r.find(s=>(s==null?void 0:s.key)==="backGround"))==null?void 0:i.contents)??[]},{deep:!0,immediate:!0}),(r,i)=>(e.openBlock(),e.createElementBlock("div",null,[e.createVNode(cl.ssCarousel,{carouselList:n.value},null,8,["carouselList"])]))}}),cu=e.ref([{name:"表格",type:"table",comp:"Table",icon:"Table"},{name:"表单",type:"form",comp:"Form",icon:"Form"},{name:"折叠",type:"fold",comp:"Fold",icon:"Fold"},{name:"头像",type:"avatar",comp:"AvatarUpload",icon:"Avatar"},{name:"签名",type:"signature",comp:"Signature",icon:"Signature"},{name:"步骤条",type:"step",comp:"Step",icon:"Step"},{name:"时间线",type:"timeLine",comp:"TimeLine",icon:"TimeLine"},{name:"标签页",type:"tabs",comp:"Tabs",icon:"Tabs"},{name:"图表",type:"chart",comp:"Chart",icon:"chart-new"},{name:"行内布局",type:"layout",comp:"Layout",icon:"ai13"}]),vv={TABLE:Ic,FORM:Cs,STATICFORM:Oc,TABLEOPERATE:n6,TABLESTYLE:x6,TABLEEXTEND:_6,TABLEINTERACTION:C6,FORMOPERATE:Ds,FOLD:l4,CALCULATOR:s4,METHODBUTTON:d4,AVATARUPLOAD:ts.ssAvatar,SIGNATURE:ts.ssSignature,FORMTOP:Cs,STEP:_4,STEPOPERATE:K6,TIMELINE:B4,TIMELINEOPERATE:Q6,FORMTOPOPERATE:Ds,SIGNATUREOPERATE:k4,AVATARUPLOADOPERATE:h4,TABS:z4,TABSOPERATE:y2,CHART:z2,CHARTOPERATE:H2,LAYOUT:W2,LAYOUTOPERATE:a1,PARENTITEM:uv,RADIO:fv,CAROUSEL:hv};function zi(a){return vv[a==null?void 0:a.toUpperCase()]||null}exports.De=su;exports.activeStepInfo=Di;exports.addContents=Xi;exports.addVisibleDialog=Mt;exports.affixItems=M0;exports.allMapContents=Ct;exports.analyzeMenu=oc;exports.cacheNewData=Dc;exports.clickMainKey=Nc;exports.clickSavePage=z0;exports.clickStep=zc;exports.clickTrigger=Bc;exports.compId=Gn;exports.compNames=Tc;exports.compShow=Ai;exports.existLayouts=F0;exports.fixChangeValue=Po;exports.generateLayouts=y6;exports.getComponent=zi;exports.getComponents=Zi;exports.getPageConstruct=Zd;exports.getPageData=Jr;exports.getSliceContLength=K0;exports.gridRowHeight=p6;exports.gridRowHeightHmPg=d6;exports.isStepLayout=Mc;exports.onBack=N0;exports.onButtonChange=R0;exports.onChange=Io;exports.onClick=A0;exports.onClickStep=j0;exports.onContentChange=Oo;exports.onExtendTaskEnd=P0;exports.onOk=$0;exports.onPageBack=U0;exports.onPageChange=Lo;exports.onSelectFixContent=B0;exports.renderShowItems=Ec;exports.showItems=dr;exports.sliceTableLength=Cc;exports.slotContent=cu;exports.ssTable=Ic;exports.st=$o;exports.stepItems=G0;exports.tabChange=H0;exports.toolBar=V0;exports.useFormComp=zt;exports.useModelLoader=Nf;exports.verifyButton=q0;
|