ss-component-new 1.3.417 → 1.3.418

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.
Files changed (43) hide show
  1. package/dist/{array-7hDf8gIy.js → array-5_aN-RSg.js} +2 -2
  2. package/dist/{array-D58GsWzI.cjs → array-BCvH5saX.cjs} +1 -1
  3. package/dist/{index-DASn3fcI.cjs → index-BDhi_PcI.cjs} +1 -1
  4. package/dist/{index-B1HGCDOE.cjs → index-BeiLiIuF.cjs} +1 -1
  5. package/dist/{index-BJYL83ey.cjs → index-C-KB6T93.cjs} +1 -1
  6. package/dist/{index-9dTDi5Ge.js → index-C-kqu8jD.js} +1 -1
  7. package/dist/{index-BveIPT3h.js → index-C9MloMiN.js} +2 -2
  8. package/dist/{index-DFFIQ_d-.cjs → index-CAYpRdgT.cjs} +1 -1
  9. package/dist/{index-BYrnsdLj.js → index-CsZHscyC.js} +3 -3
  10. package/dist/{index-GYtcQn5r.cjs → index-CvqMXSiD.cjs} +1 -1
  11. package/dist/{index-B2t7cepm.cjs → index-D0wF8TiS.cjs} +1 -1
  12. package/dist/{index-CQ5krbf7.js → index-D5lQkdfc.js} +2 -2
  13. package/dist/{index-BGDb3E_p.cjs → index-DBmxk8Dg.cjs} +1 -1
  14. package/dist/{index-DtZ2ZKPO.js → index-DM51tAAH.js} +1 -1
  15. package/dist/{index-C1VlXmyp.cjs → index-DO0hJOkb.cjs} +1 -1
  16. package/dist/{index-CVG0c03e.cjs → index-DOT552KC.cjs} +1 -1
  17. package/dist/index-DUQdwsl1.cjs +25 -0
  18. package/dist/{index-CaPsaqj8.js → index-DXxKRoZz.js} +1 -1
  19. package/dist/{index-D41wgwXB.js → index-Dd9DSArU.js} +1 -1
  20. package/dist/{index-DUowomjd.js → index-DygiWiME.js} +1 -1
  21. package/dist/{index-BL6kRMh8.cjs → index-I0DByrV_.cjs} +1 -1
  22. package/dist/{index-BIWnTKR6.js → index-KnFXe8zy.js} +7 -7
  23. package/dist/{index-XcQTeHWK.js → index-LX83VKNp.js} +1 -1
  24. package/dist/{index-CPBH8dZD.js → index-OACzw1yi.js} +2 -2
  25. package/dist/{index-JxQEYRld.cjs → index-ZYYTejEI.cjs} +1 -1
  26. package/dist/{index-B9HWTvDz.js → index-xlUX68hj.js} +3217 -3203
  27. package/dist/{main-ib9UzP5g.js → main-BCV5wABr.js} +2 -2
  28. package/dist/{main-B9j-5uos.cjs → main-CVrSjdZa.cjs} +1 -1
  29. package/dist/ss-component.cjs +1 -1
  30. package/dist/ss-component.css +1 -1
  31. package/dist/ss-component.js +5 -5
  32. package/dist/ss-component2.cjs +1 -1
  33. package/dist/ss-component2.js +8 -8
  34. package/dist/{threeModel-DCxgIYS3.js → threeModel-CRP97nk3.js} +1 -1
  35. package/dist/{threeModel-lk0Dlios.cjs → threeModel-CTBU7hYz.cjs} +1 -1
  36. package/dist/{threeSceneView-CZ37DgpD.cjs → threeSceneView-CSLKtmO3.cjs} +1 -1
  37. package/dist/{threeSceneView-5BMcTrX1.js → threeSceneView-CxizgM5g.js} +3 -3
  38. package/dist/{threeSceneViewForCPMPIP-Dvherbb8.cjs → threeSceneViewForCPMPIP-D6-ggzVs.cjs} +1 -1
  39. package/dist/{threeSceneViewForCPMPIP-C46fmYy7.js → threeSceneViewForCPMPIP-SOJIx50B.js} +1 -1
  40. package/dist/{threeViewerHost-DPI9UfZQ.cjs → threeViewerHost-Cis2c2LQ.cjs} +1 -1
  41. package/dist/{threeViewerHost-DGiebSu-.js → threeViewerHost-Cv4psP7K.js} +1 -1
  42. package/package.json +1 -1
  43. package/dist/index-v5yXoQ5f.cjs +0 -25
@@ -0,0 +1,25 @@
1
+ "use strict";var Mu=Object.defineProperty;var Iu=(a,l,n)=>l in a?Mu(a,l,{enumerable:!0,configurable:!0,writable:!0,value:n}):a[l]=n;var tn=(a,l,n)=>Iu(a,typeof l!="symbol"?l+"":l,n);const e=require("vue"),ja=require("./request-Dl8yi2iS.cjs"),A=require("./index-ClvA5-wg.cjs"),sl=require("./index-CvqMXSiD.cjs"),te=require("./index-reJmxzkK.cjs"),Ql=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Il=require("./index.vue_vue_type_style_index_0_scoped_6b92e250_lang-Dg_y3QFE.cjs"),Ar=require("./index-BOkUwKV5.cjs"),Bo=require("./threeViewerHost-Cis2c2LQ.cjs"),Rr=require("./index-DmwxzDGW.cjs"),os=require("./index-I0DByrV_.cjs"),Qs=require("./index-C9cUuEAp.cjs");;/* empty css */const No=require("./isString-CGrvcmBw.cjs"),ts=require("./index.vue_vue_type_script_setup_true_lang-BKTJR2th.cjs"),ec=require("./index-BVaHwt5f.cjs"),Ou=require("./index-D7Mqm_K7.cjs"),$n=require("./MTLLoader-C9Y2XnL-.cjs"),Lu=require("./URDFLoader-BDJ4XpPA.cjs");var Ru="[object Boolean]";function ac(a){return a===!0||a===!1||ja.isObjectLike(a)&&ja.baseGetTag(a)==Ru}function $u(a){return a===void 0}const Vu=a=>a.match(/\((.*)\)/)[1],Pu={__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"])}}},Fu=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,g,u,C,M;const r=l.value??"";let i=(d=l==null?void 0:l.columnContent)==null?void 0:d.filter;if(i=(m=te.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=(g=l==null?void 0:l.columnContent)==null?void 0:g.options)==null?void 0:u.findIndex(k=>(k==null?void 0:k.value)===r);s=i==null?void 0:i[s],s=te.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=te.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=te.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)}}),ju=Ql._export_sfc(Fu,[["__scopeId","data-v-3290070b"]]);function Hu(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(),g=l.naturalWidth,u=l.naturalHeight,C=m.width/g,M=m.height/u,k=Math.min(C,M),W=g*k,I=u*k,j=(d.width-W)/2,L=(d.height-I)/2,E=n.map(([w,b])=>{const S=j+w*W,$=L+b*I;return{x:S,y:$}});i.clearRect(0,0,a.width,a.height),i.beginPath(),i.moveTo(E[0].x,E[0].y);for(let w=1;w<E.length;w++)i.lineTo(E[w].x,E[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 ss(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 Uu={key:0,class:"ocr-img-preview-root"},qu={class:"ocr-img-preview-window"},Wu={key:0,class:"img-preview-body"},Ku={class:"img-preview-header"},Gu={class:"img-header-left"},Yu={class:"img-name"},Ju={key:0,class:"img-header-right"},Xu={class:"img-index"},Zu={key:0,class:"img-thumb-list"},Qu=["onClick"],ed={key:1,class:"thumb-placeholder"},ad={class:"thumb-name"},ld={class:"img-preview-container"},rd={key:0,class:"img-placeholder"},nd={key:2,class:"img-placeholder"},id={key:0},od={key:1},td={key:1,class:"img-placeholder"},sd=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:N=>r("update:visible",N)});let s=!1,h="",c=0,d=0,m=0,g=0,u=0,C=0,M=null;const k=N=>{var U,_e;const se=(_e=(U=N==null?void 0:N.target)==null?void 0:U.closest)==null?void 0:_e.call(U,".ocr-img-preview-window");return se||document.querySelector(".ocr-img-preview-window")},W=N=>{if(!N||N==="none")return{tx:0,ty:0};let se=N.match(/matrix\(([^)]+)\)/);if(se){const U=se[1].split(",").map(_e=>Number(_e.trim()));return{tx:(U==null?void 0:U[4])||0,ty:(U==null?void 0:U[5])||0}}if(se=N.match(/matrix3d\(([^)]+)\)/),se){const U=se[1].split(",").map(_e=>Number(_e.trim()));return{tx:(U==null?void 0:U[12])||0,ty:(U==null?void 0:U[13])||0}}return se=N.match(/translate\(\s*([-\d.]+)px\s*,\s*([-\d.]+)px\s*\)/),se?{tx:Number(se[1])||0,ty:Number(se[2])||0}:{tx:0,ty:0}},I=(N,se,U)=>{N.style.transform=`translate(${se}px, ${U}px)`},j=N=>{const se=k(N);if(!se)return;s=!0,M=se,h="move",c=N.clientX,d=N.clientY;const U=window.getComputedStyle(se),{tx:_e,ty:Ie}=W(U.transform);u=_e,C=Ie,document.addEventListener("mousemove",E),document.addEventListener("mouseup",x)},L=(N,se)=>{const U=k(N);if(!U)return;s=!0,M=U,h=se,c=N.clientX,d=N.clientY;const _e=U.getBoundingClientRect();m=_e.width,g=_e.height;const Ie=window.getComputedStyle(U),{tx:je,ty:na}=W(Ie.transform);u=je,C=na,document.addEventListener("mousemove",E),document.addEventListener("mouseup",x)},E=N=>{if(!s||!M)return;const se=N.clientX-c,U=N.clientY-d,_e=360,Ie=420;let je=m,na=g,Ca=u,ee=C;if(h==="move"){Ca=u+se,ee=C+U,I(M,Ca,ee);return}if(h.includes("right")&&(je=Math.max(_e,m+se)),h.includes("bottom")&&(na=Math.max(Ie,g+U)),h.includes("left")){const ca=m-se;ca<_e?(je=_e,Ca=u+(m-_e)):(je=ca,Ca=u+se)}if(h.includes("top")){const ca=g-U;ca<Ie?(na=Ie,ee=C+(g-Ie)):(na=ca,ee=C+U)}M.style.width=`${je}px`,M.style.height=`${na}px`,I(M,Ca,ee)},x=()=>{s=!1,h="",M=null,document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",x)},w=e.ref([]),b=e.ref(!1);e.watch(()=>n.images,async N=>{if(!Array.isArray(N)||N.length===0){w.value=[];return}b.value=!0;const se=[];for(const U of N)if(U.url&&!U.url.startsWith("blob:")&&!U.url.startsWith("http"))try{const _e=await Il.downloadFile(U.url),Ie=URL.createObjectURL(_e);se.push({...U,blobUrl:Ie})}catch(_e){console.error(`Failed to load image for preview: ${U.url}`,_e),se.push({...U,blobUrl:""})}else se.push({...U,blobUrl:U.url});w.value=se,b.value=!1},{deep:!0,immediate:!0});const S=e.ref(0),$=e.ref(null),V=e.ref(null),le=e.computed(()=>w.value[S.value]||null),X=()=>{if(!w.value.length){S.value=0;return}if(n.defaultImageName){const N=w.value.findIndex(se=>(se==null?void 0:se.name)===n.defaultImageName);S.value=N>=0?N:0}else S.value=0},me=N=>{if(!w.value.length)return;const se=Math.max(0,Math.min(N,w.value.length-1));S.value=se},Be=()=>me(S.value-1),F=()=>me(S.value+1),ie=N=>{if(!N)return;const se=w.value.findIndex(U=>(U==null?void 0:U.name)===N);se>=0&&(S.value=se)},Y=()=>{if(!V.value)return;const N=V.value.parentElement;if(!N)return;const se=N.getBoundingClientRect();V.value.width=se.width,V.value.height=se.height},ce=()=>{var _e,Ie;if(!V.value||!$.value||!n.focusedFieldName){V.value&&Si(V.value);return}const N=(_e=$.value.$el)==null?void 0:_e.querySelector("img");if(!N)return;if(!N.complete||N.naturalWidth===0){N.onload=()=>{e.nextTick(()=>{ce()})};return}const se=((Ie=le.value)==null?void 0:Ie.name)||"",U=ss(n.fieldMeta,n.focusedFieldName);if(!U){Si(V.value);return}if(U.imageName!==se){Si(V.value);return}Y(),Hu(V.value,N,U.bboxNorm)},Ce=()=>{e.nextTick(()=>{Y(),ce()})};e.watch(()=>n.focusedFieldName,()=>{if(!i.value)return;const N=ss(n.fieldMeta,n.focusedFieldName);N!=null&&N.imageName&&ie(N.imageName),e.nextTick(()=>{ce()})}),e.watch(()=>{var N;return(N=le.value)==null?void 0:N.name},()=>{i.value&&e.nextTick(()=>{V.value&&Si(V.value),ce()})}),e.watch(()=>n.visible,N=>{N?(X(),e.nextTick(()=>{Y(),ce()})):V.value&&Si(V.value)}),e.watch(()=>n.defaultImageName,()=>{i.value&&X()});let Fe=null;e.onMounted(()=>{var N;typeof ResizeObserver<"u"&&(Fe=new ResizeObserver(()=>{Y(),e.nextTick(()=>{ce()})}),(N=V.value)!=null&&N.parentElement&&Fe.observe(V.value.parentElement))}),e.onUnmounted(()=>{Fe&&(Fe.disconnect(),Fe=null),document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",x)});const fe=()=>{V.value&&Si(V.value),r("update:visible",!1),r("close")};return(N,se)=>{var na,Ca;const U=e.resolveComponent("el-button"),_e=e.resolveComponent("el-image"),Ie=e.resolveComponent("Loading"),je=e.resolveComponent("el-icon");return i.value?(e.openBlock(),e.createElementBlock("div",Uu,[se[12]||(se[12]=e.createElementVNode("div",{class:"ocr-img-preview-backdrop"},null,-1)),e.createElementVNode("div",qu,[e.createElementVNode("div",{class:"ocr-img-preview-header",onMousedown:e.withModifiers(j,["stop"])},[se[8]||(se[8]=e.createElementVNode("span",{class:"ocr-img-preview-title"},"文件预览",-1)),e.createElementVNode("button",{type:"button",class:"ocr-img-preview-close",onClick:fe},"×")],32),e.createElementVNode("div",{class:"resizable-handle top",onMousedown:se[0]||(se[0]=e.withModifiers(ee=>L(ee,"top"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle right",onMousedown:se[1]||(se[1]=e.withModifiers(ee=>L(ee,"right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom",onMousedown:se[2]||(se[2]=e.withModifiers(ee=>L(ee,"bottom"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle left",onMousedown:se[3]||(se[3]=e.withModifiers(ee=>L(ee,"left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-left",onMousedown:se[4]||(se[4]=e.withModifiers(ee=>L(ee,"top-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-right",onMousedown:se[5]||(se[5]=e.withModifiers(ee=>L(ee,"top-right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-left",onMousedown:se[6]||(se[6]=e.withModifiers(ee=>L(ee,"bottom-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-right",onMousedown:se[7]||(se[7]=e.withModifiers(ee=>L(ee,"bottom-right"),["stop"]))},null,32),le.value?(e.openBlock(),e.createElementBlock("div",Wu,[e.createElementVNode("div",Ku,[e.createElementVNode("div",Gu,[e.createElementVNode("span",Yu,e.toDisplayString(le.value.name?le.value.name+(le.value.url&&le.value.url.lastIndexOf(".")!==-1?le.value.url.substring(le.value.url.lastIndexOf(".")):""):""),1)]),w.value.length>1?(e.openBlock(),e.createElementBlock("div",Ju,[e.createVNode(U,{size:"small",disabled:S.value===0,onClick:Be},{default:e.withCtx(()=>se[9]||(se[9]=[e.createTextVNode("上一张")])),_:1,__:[9]},8,["disabled"]),e.createElementVNode("span",Xu,e.toDisplayString(S.value+1)+" / "+e.toDisplayString(w.value.length),1),e.createVNode(U,{size:"small",disabled:S.value===w.value.length-1,onClick:F},{default:e.withCtx(()=>se[10]||(se[10]=[e.createTextVNode("下一张")])),_:1,__:[10]},8,["disabled"])])):e.createCommentVNode("",!0)]),w.value.length>1?(e.openBlock(),e.createElementBlock("div",Zu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(ee,ca)=>(e.openBlock(),e.createElementBlock("div",{key:(ee.name||"")+"-"+ca,class:e.normalizeClass(["img-thumb-item",{active:ca===S.value}]),onClick:de=>me(ca)},[ee!=null&&ee.blobUrl?(e.openBlock(),e.createBlock(_e,{key:0,src:ee.blobUrl,fit:"cover",class:"thumb-image","preview-src-list":[ee.blobUrl],"initial-index":0},null,8,["src","preview-src-list"])):(e.openBlock(),e.createElementBlock("div",ed,"加载失败")),e.createElementVNode("div",ad,e.toDisplayString(ee.name||"-"),1)],10,Qu))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",ld,[b.value?(e.openBlock(),e.createElementBlock("div",rd,[e.createVNode(je,{class:"is-loading"},{default:e.withCtx(()=>[e.createVNode(Ie)]),_:1}),se[11]||(se[11]=e.createElementVNode("span",null,"图片加载中...",-1))])):(na=le.value)!=null&&na.blobUrl?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(_e,{ref_key:"imageRef",ref:$,src:le.value.blobUrl,fit:"contain",class:"preview-image","preview-src-list":[le.value.blobUrl],onLoad:Ce},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",nd,[(Ca=le.value)!=null&&Ca.url?(e.openBlock(),e.createElementBlock("span",id,"图片加载失败")):(e.openBlock(),e.createElementBlock("span",od,"暂无图片"))]))])])):(e.openBlock(),e.createElementBlock("div",td,"暂无图片"))])])):e.createCommentVNode("",!0)}}}),cd=Ql._export_sfc(sd,[["__scopeId","data-v-48a4ecb1"]]),ud={class:"cert-preview-body"},dd={key:0,class:"pdf-preview-container"},pd={class:"thumbs"},fd=["onClick"],hd={class:"thumb-img"},vd=["src"],md={key:1,class:"thumb-loading"},yd={class:"thumb-title"},gd={class:"viewer"},bd={key:0,class:"viewer-img-wrap"},kd=["src"],xd={key:1,class:"viewer-loading"},wd=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"),g=()=>{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 I of W){const j=I==null?void 0:I.url;if(!(!j||c.value[j]))try{const L=await A.platformDownloadFile({url:j}),E=URL.createObjectURL(L.data);c.value={...c.value,[j]:E}}catch{}}},C=async k=>{var I;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:(I=j==null?void 0:j.data)==null?void 0:I.size});const L=URL.createObjectURL(j.data);d.value=L;const E=k.certNo?String(k.certNo):"";m.value=E?`${E}.pdf`:"证书附件.pdf"}catch(j){console.error("[CertificatePreview] PDF加载失败:",{url:W,error:j}),d.value=""}};e.watch(()=>n.visible,async k=>{var I;if(!k){g();return}const W=(I=n.versions)==null?void 0:I[0];i.value=(W==null?void 0:W.versionId)||"",await u(W),await C(W)},{immediate:!0}),e.watch(()=>i.value,async()=>{var W,I;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=((I=(W=k.images)==null?void 0:W[0])==null?void 0:I.url)||"",await u(k)},{immediate:!0});const M=()=>{r("update:visible",!1),g()};return e.onBeforeUnmount(()=>{g()}),(k,W)=>{const I=e.resolveComponent("el-empty"),j=e.resolveComponent("el-tab-pane"),L=e.resolveComponent("el-tabs"),E=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(E,{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",ud,[w.fileType==="pdf"?(e.openBlock(),e.createElementBlock("div",dd,[d.value?(e.openBlock(),e.createBlock(sl.SsFilePreview,{key:1,fileName:m.value,blobUrl:d.value},null,8,["fileName","blobUrl"])):(e.openBlock(),e.createBlock(I,{key:0,description:"加载中"}))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",pd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.images||[],b=>(e.openBlock(),e.createElementBlock("div",{key:b.url,class:e.normalizeClass(["thumb",{active:b.url===s.value}]),onClick:S=>s.value=b.url},[e.createElementVNode("div",hd,[c.value[b.url]?(e.openBlock(),e.createElementBlock("img",{key:0,src:c.value[b.url]},null,8,vd)):(e.openBlock(),e.createElementBlock("div",md,"加载中"))]),e.createElementVNode("div",yd,e.toDisplayString(b.name),1)],10,fd))),128))]),e.createElementVNode("div",gd,[s.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[c.value[s.value]?(e.openBlock(),e.createElementBlock("div",bd,[e.createElementVNode("img",{class:"viewer-img",src:c.value[s.value]},null,8,kd)])):(e.openBlock(),e.createElementBlock("div",xd,"加载中"))],64)):(e.openBlock(),e.createBlock(I,{key:0,description:"暂无图片"}))])],64))])]),_:2},1032,["name","label"]))),128))]),_:1},8,["modelValue"])):(e.openBlock(),e.createBlock(I,{key:1,description:"暂无可预览的证书附件"}))]),_:1},8,["model-value"])}}}),_d=Ql._export_sfc(wd,[["__scopeId","data-v-220703c0"]]),Sd={class:"ocr-candidate-wrap"},Ed={class:"ocr-candidate-left"},Cd={key:1},Dd={key:0},Td={key:1},Bd={key:2},Nd={key:3},Ad={key:0,class:"ocr-candidate-right"},zd={class:"ocr-candidate-actions"},Md={key:1},Id={class:"dialog-footer"},Od={__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=(S=[])=>{const $=[],V=le=>{(le||[]).forEach(X=>{if(!X)return;const me=X.children||X.childrens||X.columns;Array.isArray(me)&&me.length>0?V(me):$.push(X)})};return V(S),$},r=a,i=l,s=e.computed(()=>{var S;return((S=C.value)==null?void 0:S.allowAdd)!==!1}),h=e.computed(()=>{var S;return((S=C.value)==null?void 0:S.allowReplace)!==!1}),c=S=>{if(!S)return[];if(Array.isArray(S))return S;if(typeof S=="string")try{const $=JSON.parse(S);return Array.isArray($)?$:[]}catch{return[]}return[]},d=S=>{i("preview-file",S)},m=e.ref([]),g=e.ref(0),u=e.ref("");e.watch(()=>r.candidates,S=>{var $,V;m.value=(S||[]).map(le=>({...le,...(le==null?void 0:le.ocrRow)||{},selectedTargetId:(le==null?void 0:le.selectedTargetId)||"",__decision:le==null?void 0:le.__decision})),g.value=0,u.value=((V=($=m.value)==null?void 0:$[0])==null?void 0:V.selectedTargetId)||""},{immediate:!0,deep:!0}),e.watch(()=>r.visible,S=>{var $,V;S&&(g.value=0,u.value=((V=($=m.value)==null?void 0:$[0])==null?void 0:V.selectedTargetId)||"")});const C=e.computed(()=>{var $;const S=Number(g.value||0);return(($=m.value||[])==null?void 0:$[S])||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(S=>S.label!=="证书附件"&&S.prop!=="证书附件")),W=S=>{if(!S)return;const $=(m.value||[]).findIndex(V=>(V==null?void 0:V.idx)===(S==null?void 0:S.idx));$>-1&&(g.value=$,u.value=(S==null?void 0:S.selectedTargetId)||"")},I=S=>{if(!S){u.value="";return}u.value=String((S==null?void 0:S.id)??"")},j=(S,$="")=>{const V=Number(g.value||0),le=m.value||[],X=le[V];X&&(X.__decision=S,X.selectedTargetId=$,u.value=$,m.value=[...le])},L=()=>j("skip",""),E=()=>j("add",""),x=()=>{if(!u.value){ja.ElMessage.warning("请先选择要替换的目标记录");return}j("replace",u.value)},w=()=>{i("update:visible",!1)},b=()=>{const S=m.value||[];if(S.find(V=>(V==null?void 0:V.__decision)==="replace"&&!(V!=null&&V.selectedTargetId))){ja.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}i("submit",S),i("update:visible",!1)};return(S,$)=>{const V=e.resolveComponent("el-table-column"),le=e.resolveComponent("svg-icon"),X=e.resolveComponent("el-table"),me=e.resolveComponent("el-button"),Be=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 F,ie;return[e.createElementVNode("div",Sd,[e.createElementVNode("div",Ed,[$[0]||($[0]=e.createElementVNode("div",{class:"ocr-candidate-title"},"待处理OCR行(可跳过)",-1)),e.createVNode(X,{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:ce})=>[Y.label==="证书附件"||Y.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(ce==null?void 0:ce[Y.prop]).length>0?(e.openBlock(),e.createBlock(le,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(Ce=>d({row:ce,prop:Y.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Cd,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((ce==null?void 0:ce[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",Dd,"替换")):(Y==null?void 0:Y.__decision)==="add"?(e.openBlock(),e.createElementBlock("span",Td,"新增")):(Y==null?void 0:Y.__decision)==="skip"?(e.openBlock(),e.createElementBlock("span",Bd,"跳过")):(e.openBlock(),e.createElementBlock("span",Nd,"未处理"))]),_:1})]),_:1},8,["data"])]),m.value&&m.value.length>0?(e.openBlock(),e.createElementBlock("div",Ad,[$[4]||($[4]=e.createElementVNode("div",{class:"ocr-candidate-title"},"当前行候选记录(同编号)",-1)),e.createElementVNode("div",zd,[e.createVNode(me,{id:"themeBorderButton",onClick:L},{default:e.withCtx(()=>$[1]||($[1]=[e.createTextVNode("跳过本行")])),_:1,__:[1]}),e.createVNode(me,{id:"themeBorderButton",onClick:E,disabled:!s.value},{default:e.withCtx(()=>$[2]||($[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(()=>$[3]||($[3]=[e.createTextVNode("替换选中记录")])),_:1,__:[3]},8,["disabled"])]),(((F=C.value)==null?void 0:F.candidates)||[]).length===0?(e.openBlock(),e.createBlock(Be,{key:0,title:"该编号暂无候选记录,可选择“新增本行”或“跳过本行”。",type:"info",closable:!1,"show-icon":"",style:{margin:"8px 0"}})):e.createCommentVNode("",!0),e.createVNode(X,{data:((ie=C.value)==null?void 0:ie.candidates)||[],border:"",stripe:"","max-height":"300",style:{width:"100%"},onCurrentChange:I,"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:ce})=>[Y.label==="证书附件"||Y.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(ce==null?void 0:ce[Y.prop]).length>0?(e.openBlock(),e.createBlock(le,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(Ce=>d({row:ce,prop:Y.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Md,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((ce==null?void 0:ce[Y.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128))]),_:1},8,["data"])])):e.createCommentVNode("",!0)])]}),footer:e.withCtx(()=>[e.createElementVNode("div",Id,[e.createVNode(me,{id:"themeBorderButton",onClick:w},{default:e.withCtx(()=>$[5]||($[5]=[e.createTextVNode("取消")])),_:1,__:[5]}),e.createVNode(me,{class:"ok-button",id:"themeButton",onClick:b},{default:e.withCtx(()=>$[6]||($[6]=[e.createTextVNode("提交已处理")])),_:1,__:[6]})])]),_:1},8,["visible"])}}},Ld=Ql._export_sfc(Od,[["__scopeId","data-v-89e0489c"]]),Rd={class:"ocr-preview-content"},$d={class:"ocr-preview-tip"},Vd={class:"ocr-preview-table"},Pd={style:{display:"flex","align-items":"center",gap:"8px"}},Fd={class:"dialog-footer"},jd={__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 I=W.indexOf(M);I>-1&&W.splice(I,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)},g=()=>{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"),I=e.resolveComponent("el-table-column"),j=e.resolveComponent("el-checkbox"),L=e.resolveComponent("el-input"),E=e.resolveComponent("el-table"),x=e.resolveComponent("el-button");return e.openBlock(),e.createBlock(Ar.ssDialog,{title:"OCR识别结果预览",visible:a.visible,onBeforeDestroy:g,width:"90%",style:{maxWidth:"1200px"}},{default:e.withCtx(()=>[e.createElementVNode("div",Rd,[e.createElementVNode("div",$d,[e.createVNode(W,{title:"请核对识别结果。系统将按 编号+名称+制造厂 规则匹配并替换;未唯一命中但有编号的,将进入候选选择;无编号则直接新增。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",Vd,[e.createVNode(E,{data:i.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(I,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,w=>(e.openBlock(),e.createBlock(I,{key:w.prop,prop:w.prop,"min-width":w.minWidth||230,"class-name":w.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",Pd,[w.isAccuracy?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(j,{key:0,"model-value":h.value.includes(w.prop),onChange:b=>c(w.prop,b),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:b,$index:S})=>[w.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:C(b[w.prop]),fontWeight:500})},e.toDisplayString(u(b[w.prop])),5)):(e.openBlock(),e.createBlock(L,{key:1,modelValue:b[w.prop],"onUpdate:modelValue":$=>b[w.prop]=$,size:"small",placeholder:"请输入"+w.label,onChange:$=>d(S,w.prop,$)},null,8,["modelValue","onUpdate:modelValue","placeholder","onChange"]))]),_:2},1032,["prop","min-width","class-name"]))),128))]),_:1},8,["data"])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",Fd,[e.createVNode(x,{onClick:g,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"])}}},Hd=Ql._export_sfc(jd,[["__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=te.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 lc(a){return ja.axios.post("http://222.92.178.198:8000/api/v1/excel-chat",a)}function Ud(a){return ja.axios.get(a,{responseType:"blob"})}let Jl="$R",qd="http://222.92.178.198:55002/AIRobot",ft=["Form","BarChart","FormText","FormBlock"];const rc=a=>{var n,r;let l=(r=te.analyzeSplitToContent(a,"@"))==null?void 0:r[((n=te.analyzeSplitToContent(a,"@"))==null?void 0:n.length)-1];return!!(ft!=null&&ft.some(i=>l==null?void 0:l.includes(i)))},Wd=async(a,l,n,r)=>{var s,h,c,d,m,g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca;let i=a;if(rc(i==null?void 0:i[0])){let de=Qd(i),pa=(s=de==null?void 0:de.filter)==null?void 0:s.join(","),we=[];(h=de==null?void 0:de.hideContents)==null||h.forEach(Ge=>{if(Ge){const ua=Ge;ua&&we.push(`(HideGroup=Yes, prop=${ua})`)}});let ue=(c=de==null?void 0:de.formContents)==null?void 0:c.filter(Ge=>{var ua;return(ua=Ge==null?void 0:Ge.filters)==null?void 0:ua.includes("@ShowHide=Hide")});(ue==null?void 0:ue.length)>0&&(ue==null||ue.forEach(Ge=>{if(Ge){const ua=Ge==null?void 0:Ge.prop;ua&&we.push(`(Hide=Yes, prop=${ua})`)}}));let De=(r==null?void 0:r.menuFilter)??[];return Array.isArray(De)||(De=De?[De]:[]),De=[...De,...we],{key:"Form",name:de==null?void 0:de.groupName,value:de==null?void 0:de.formContents,contents:Array.isArray((d=de==null?void 0:de.contents)==null?void 0:d[0])&&((g=(m=de==null?void 0:de.contents)==null?void 0:m[0])!=null&&g.every(Ge=>Array.isArray(Ge)))?[(C=(u=de==null?void 0:de.contents)==null?void 0:u[0])==null?void 0:C[n]]:[de==null?void 0:de.contents],filter:"("+pa+")",menuFilter:De,groupFilter:de==null?void 0:de.groupFilters}}else if(((M=i==null?void 0:i[0])==null?void 0:M[0])!=="&"){let de=oc(i,r),pa="";(k=de==null?void 0:de.tableFilter)!=null&&k.includes(Jl)?de.tableFilter=(W=de==null?void 0:de.tableFilter)==null?void 0:W.replace(Jl,""):pa=(L=(j=(I=de==null?void 0:de.tableFilter)==null?void 0:I.replace("(",Jl))==null?void 0:j.split(Jl))==null?void 0:L[0];let we=[];de!=null&&de.tableFilter&&((E=te.analyzeSplitToContent(de==null?void 0:de.tableFilter,","))==null||E.forEach(De=>{De!=null&&De.includes("@ShowHide=Hide")&&we.push("HideGroup=Yes")}));let ue=(r==null?void 0:r.menuFilter)??[];return Array.isArray(ue)||(ue=ue?[ue]:[]),ue=[...ue,...we],{key:"Table",name:de==null?void 0:de.groupName,tableColumns:de==null?void 0:de.tableColumns,assistColumn:de==null?void 0:de.columns,tableContents:l===1?de==null?void 0:de.tableContents:(w=(x=de==null?void 0:de.tableContents)==null?void 0:x[n])!=null&&w.every(De=>Array.isArray(De))?(b=de==null?void 0:de.tableContents)==null?void 0:b[n]:[(S=de==null?void 0:de.tableContents)==null?void 0:S[n]],filter:de==null?void 0:de.tableFilter,menuFilter:ue,quotePage:pa!==""?((le=(V=($=pa==null?void 0:pa.replace("*",Jl))==null?void 0:$.split(Jl))==null?void 0:V[0])==null?void 0:le.replaceAll(":","/"))??"":void 0,quoteGroup:pa!==""?((ce=(Y=(ie=(F=(Be=(me=(X=pa==null?void 0:pa.replace("*",Jl))==null?void 0:X.split(Jl))==null?void 0:me[1])==null?void 0:Be.replace("{",Jl))==null?void 0:F.split(Jl))==null?void 0:ie[0])==null?void 0:Y.split(":"))==null?void 0:ce.filter(De=>De!==""))??[]:[],relatedQuotes:de==null?void 0:de.relatedQuotes,fatherSyncContents:de==null?void 0:de.fatherSyncContents,sonSyncContents:de==null?void 0:de.sonSyncContents}}else{let de=[{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=te.analyzeSplitToContent(pa,":"),pa=pa==null?void 0:pa[(pa==null?void 0:pa.length)-1];let we=[];we.push("1");let ue=pa==null?void 0:pa.replace("(",Jl);ue=(Ce=ue==null?void 0:ue.split(Jl))==null?void 0:Ce[0],we.push(ue);let De=pa==null?void 0:pa.replace("(",Jl);if(De=(Fe=De==null?void 0:De.split(Jl))==null?void 0:Fe[1],De=(N=(fe=De==null?void 0:De.replace(")",Jl))==null?void 0:fe.split(Jl))==null?void 0:N[0],(U=(se=De==null?void 0:De.replace(",",Jl))==null?void 0:se.split(Jl))==null||U.forEach(Ge=>{we.push(Ge)}),we.push(""),we.push(""),(_e=we==null?void 0:we[2])!=null&&_e.includes(".xlsx")||(Ie=we==null?void 0:we[2])!=null&&Ie.includes(".xls"))try{let Ge=qd+"/"+(we==null?void 0:we[2]),ua=await Ud(Ge),Ja=`生成js函数名称为${we==null?void 0:we[1]}的函数,规则为:`+(we==null?void 0:we[3])+"。根据上述描述获取对应的总结性详细可运行js函数,不需要任何注释。";if((ua==null?void 0:ua.status)===200){let R=ua==null?void 0:ua.data;const H=new FormData;H.append("file",R,we==null?void 0:we[2]),H.append("query",Ja);let J=await lc(H);J=(Ca=(na=(je=J==null?void 0:J.data)==null?void 0:je.data)==null?void 0:na.response)==null?void 0:Ca.replace("generateResult",we==null?void 0:we[1]),we[we.length-2]=J,we[we.length-1]=[{name:(ca=(ee=we==null?void 0:we[2])==null?void 0:ee.split("."))==null?void 0:ca[0],url:Ge}]}}catch{}return we=[we],{key:"Method",name:[],tableContents:we,tableColumns:de}}},Kd=(a,l)=>{var r,i,s,h,c,d,m,g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we;let n=(i=(r=te.analyzeSplitToContent(a,"="))==null?void 0:r.filter(ue=>ue!=="="))==null?void 0:i.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));if(rc(n==null?void 0:n[1])){let ue=Zd(n),De=(c=(h=(s=ue==null?void 0:ue.filter)==null?void 0:s.replace("@",Jl))==null?void 0:h.split(Jl))==null?void 0:c[0],Ge=(g=(m=(d=ue==null?void 0:ue.filter)==null?void 0:d.replace("(",Jl))==null?void 0:m.split(Jl))==null?void 0:g[1],ua=(M=(C=(u=ue==null?void 0:ue.filter)==null?void 0:u.replace("(",Jl))==null?void 0:C.split(Jl))==null?void 0:M[0];ua="@"+((k=ua==null?void 0:ua.split("@"))==null?void 0:k[1]),Ge=Ge==null?void 0:Ge.slice(0,(Ge==null?void 0:Ge.length)-1),Ge=(I=(W=te.analyzeSplitToContent(Ge,","))==null?void 0:W.map(R=>(R=ua+R,R)))==null?void 0:I.join("");let Ja=De+"("+Ge+")";return{key:"Form",name:ue==null?void 0:ue.group,filter:Ja,formPage:((E=(L=(j=De==null?void 0:De.replace("*",Jl))==null?void 0:j.split(Jl))==null?void 0:L[0])==null?void 0:E.replaceAll(":","/"))??"",formGroup:((le=(V=($=(S=(b=(w=(x=De==null?void 0:De.replace("*",Jl))==null?void 0:x.split(Jl))==null?void 0:w[1])==null?void 0:b.replace("{",Jl))==null?void 0:S.split(Jl))==null?void 0:$[0])==null?void 0:V.split(":"))==null?void 0:le.filter(R=>R!==""))??[],value:[],menuFilter:l==null?void 0:l.menuFilter}}else{let ue=oc(n,l,n==null?void 0:n[1]),De="";(X=ue==null?void 0:ue.tableFilter)!=null&&X.includes(Jl)?ue.tableFilter=(me=ue==null?void 0:ue.tableFilter)==null?void 0:me.replace(Jl,""):De=(ie=(F=(Be=ue==null?void 0:ue.tableFilter)==null?void 0:Be.replace("(",Jl))==null?void 0:F.split(Jl))==null?void 0:ie[0];let Ge=(Ce=(ce=(Y=ue==null?void 0:ue.tableFilter)==null?void 0:Y.replace("(",Jl))==null?void 0:ce.split(Jl))==null?void 0:Ce[0];Ge=[{menus:(fe=(Fe=Ge==null?void 0:Ge.split("*"))==null?void 0:Fe[0])==null?void 0:fe.replaceAll(":","/"),groups:((se=(N=Ge==null?void 0:Ge.split("*"))==null?void 0:N[1])==null?void 0:se.split(":"))??[]}];let ua=(Ie=(_e=(U=ue==null?void 0:ue.tableFilter)==null?void 0:U.replace("(",Jl))==null?void 0:_e.split(Jl))==null?void 0:Ie[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 Ja=[];ue!=null&&ue.tableFilter&&((je=te.analyzeSplitToContent(ue==null?void 0:ue.tableFilter,","))==null||je.forEach(H=>{H!=null&&H.includes("@ShowHide=Hide")&&Ja.push("HideGroup=Yes")}));let R=(l==null?void 0:l.menuFilter)??[];return Array.isArray(R)||(R=R?[R]:[]),R=[...R,...Ja],{key:"Table",name:ue==null?void 0:ue.groupName,filter:ue==null?void 0:ue.tableFilter,tableColumns:ue==null?void 0:ue.tableColumns,quotePage:De!==""?((ee=(Ca=(na=De==null?void 0:De.replace("*",Jl))==null?void 0:na.split(Jl))==null?void 0:Ca[0])==null?void 0:ee.replaceAll(":","/"))??"":void 0,quoteGroup:De!==""?((we=(pa=(de=(ca=De==null?void 0:De.replace("*",Jl))==null?void 0:ca.split(Jl))==null?void 0:de[1])==null?void 0:pa.split(":"))==null?void 0:we.filter(H=>H!==""))??[]:[],menuFilter:R,relatedQuotes:Ge,fatherSyncContents:(ue==null?void 0:ue.fatherSyncContents)??[],sonSyncContents:(ue==null?void 0:ue.sonSyncContents)??[]}}},Gd=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=te.analyzeSplitToContent(a,"="))==null?void 0:d.length)<=2){if(((m=te.analyzeSplitToContent(a,"="))==null?void 0:m.length)!==0){const g=await Wd(te.analyzeSplitToContent(a,"="),r,s,c);h.push(g)}}else h.push(Kd(a,c))}),await Promise.all(i),n.push(h)}),await Promise.all(l),n};let qi="/",Yd="$",Sn="$R";const nc=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=te.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}},ic=(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,g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me;if(s===""&&(s="算法库:通用算法"),s!=null&&s.includes(Yd)){let Be="",F=!0,ie=te.analyzerSplitToWord(s,"(");(ie==null?void 0:ie.length)>1&&(Be="("+((h=te.analyzerSplitToWord(ie==null?void 0:ie[1],")"))==null?void 0:h[0]),((d=ie==null?void 0:ie[0])==null?void 0:d[((c=ie==null?void 0:ie[0])==null?void 0:c.length)-2])==="@"&&(Be="@"+Be));let Y=s;Y=Y==null?void 0:Y.replace(Be,""),Be=gn(Be),Be=(m=te.analyzeSplitToContent(Be,","))==null?void 0:m.map(se=>((se==null?void 0:se[(se==null?void 0:se.length)-1])===","&&(se=se==null?void 0:se.slice(0,(se==null?void 0:se.length)-1)),se)),Be!=null&&Be.includes("@ShowHide=Hide")&&(F=!1);let ce=(g=Y==null?void 0:Y.replace("$",Sn))==null?void 0:g.split(Sn),Ce=ce==null?void 0:ce[1],Fe=ce==null?void 0:ce[0];Fe!=null&&Fe.includes("[")&&(Fe=(C=(u=Fe==null?void 0:Fe.replace("[",Sn))==null?void 0:u.split(Sn))==null?void 0:C[0],Ce=Ce+":["+((W=(k=(M=ce==null?void 0:ce[0])==null?void 0:M.replace("[",Sn))==null?void 0:k.split(Sn))==null?void 0:W[1])),Fe=(j=(I=Fe==null?void 0:Fe.replaceAll(":","/"))==null?void 0:I.replaceAll("{",""))==null?void 0:j.replaceAll("}",""),(Fe==null?void 0:Fe[(Fe==null?void 0:Fe.length)-1])!=="/"&&(Fe=Fe+"/"),Ce=((L=Fe==null?void 0:Fe.split("/"))==null?void 0:L[0])+":"+Ce;let N="";if(!(Ce!=null&&Ce.includes("[")))N=Ce==null?void 0:Ce.replaceAll(":","/"),r==null||r.push({path:N,isShow:F,filter:Be,fatherPath:Fe});else{let se=(x=(E=Ce==null?void 0:Ce.replace("[",Sn))==null?void 0:E.split(Sn))==null?void 0:x[1];se=se==null?void 0:se.slice(0,(se==null?void 0:se.length)-1),se=(w=te.analyzeSplitToContent(se,","))==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)),se==null||se.forEach(U=>{var _e,Ie;N=((Ie=(_e=Ce==null?void 0:Ce.replace("[",Sn))==null?void 0:_e.split(Sn))==null?void 0:Ie[0])+U,N=N==null?void 0:N.replaceAll(":","/"),r==null||r.push({path:N,isShow:F,filter:Be,fatherPath:Fe})})}}else{let Be="",F=!0,ie=te.analyzerSplitToWord(s,"(");(ie==null?void 0:ie.length)>1&&(Be=(b=nc(ie))==null?void 0:b.filter);let Y=s;if(Y=Y==null?void 0:Y.replace(Be,""),(Be==null?void 0:Be[0])==="("){Be=Be==null?void 0:Be.slice(1,(Be==null?void 0:Be.length)-1);let Ce=[];(S=te.analyzeSplitToContent(Be,","))==null||S.forEach(Fe=>{(Fe==null?void 0:Fe[(Fe==null?void 0:Fe.length)-1])===","&&(Fe=Fe==null?void 0:Fe.slice(0,(Fe==null?void 0:Fe.length)-1)),(Fe==null?void 0:Fe[0])==="("&&(Fe=Fe==null?void 0:Fe.slice(1,(Fe==null?void 0:Fe.length)-1)),(Fe==null?void 0:Fe[0])!=="@"&&(Fe="@"+Fe),Ce.push(gn(Fe))}),Be=Ce==null?void 0:Ce.join(",")}else Be=gn(Be);Be=($=te.analyzeSplitToContent(Be,","))==null?void 0:$.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)),Be!=null&&Be.includes("@ShowHide=Hide")&&(F=!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 ce="";if(Y!=null&&Y.includes("[")){let Ce=(le=Y==null?void 0:Y.replace("[",Sn))==null?void 0:le.split(Sn),Fe=Ce==null?void 0:Ce[1];Fe=Fe==null?void 0:Fe.slice(0,(Fe==null?void 0:Fe.length)-1),(me=(X=te.analyzeSplitToContent(Fe,","))==null?void 0:X.map(fe=>((fe==null?void 0:fe[(fe==null?void 0:fe.length)-1])===","&&(fe=fe==null?void 0:fe.slice(0,(fe==null?void 0:fe.length)-1)),fe)))==null||me.forEach(fe=>{ce=(Ce==null?void 0:Ce[0])+fe,ce=ce==null?void 0:ce.replaceAll(":","/"),r==null||r.push({path:ce,isShow:F,filter:Be})})}else ce=Y==null?void 0:Y.replaceAll(":","/"),r==null||r.push({path:ce,isShow:F,filter:Be})}});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,g,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=(g=s==null?void 0:s.path)==null?void 0:g.split(h))==null?void 0:u[1])==null?void 0:C.length))),s})),r},Jd=(a,l)=>ic([{key:a}],l),Xd=async(a,l)=>{const n=[],r=Jd(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 Gd(a==null?void 0:a.value,n)};let vl="$R",Ki="[Any]";const Zd=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},Qd=a=>{var C,M,k,W,I,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=te.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,b;(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 E=te.analyzerSplitToWord(L,"(");if((E==null?void 0:E.length)>1){c=(x=nc(E))==null?void 0:x.filter;let S=L==null?void 0:L.replace(c,"");if(r.push(S),(c==null?void 0:c[0])==="("){c=c==null?void 0:c.slice(1,(c==null?void 0:c.length)-1);let $=[];(w=te.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),$.push(gn(V))}),c=$==null?void 0:$.join(",")}else c=gn(c);c=(b=te.analyzeSplitToContent(c,","))==null?void 0:b.map($=>(($==null?void 0:$[($==null?void 0:$.length)-1])===","&&($=$==null?void 0:$.slice(0,($==null?void 0:$.length)-1)),$)),c!=null&&c.includes("@ShowHide=Hide")&&h.push(S),i=[...i,...c]}else r.push(E==null?void 0:E[0])});let g=(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]),(g==null?void 0:g[(g==null?void 0:g.length)-1])===":"&&(g=g==null?void 0:g.slice(0,(g==null?void 0:g.length)-1)),s=(W=te.analyzeSplitToContent(g,"@"))==null?void 0:W[1],s="@"+s,g=g==null?void 0:g.replace(s,""),s=gn(s),s=(I=te.analyzeSplitToContent(s,","))==null?void 0:I.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)),(g==null?void 0:g[0])==="{"&&(g=g==null?void 0:g.slice(1,(g==null?void 0:g.length)-1)),g=(j=te.analyzeSplitToContent(g,","))==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)),g==null||g.forEach((L,E)=>{var ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa;let x=[],w=[],b=[],S="",$="",V=!1,le,X=[],me=[],Be=[],F="Input",ie=[],Y=[];if(L!=null&&L.includes("==")){le=(ce=L==null?void 0:L.split("=="))==null?void 0:ce[0];let Ba=(Ce=L==null?void 0:L.split("=="))==null?void 0:Ce[1],Te="";((Fe=te.analyzeSplitToContent(Ba,"$"))==null?void 0:Fe.length)>1&&((fe=te.analyzeSplitToContent(Ba,"$"))==null?void 0:fe[0])!=="$"?(Te=(N=te.analyzeSplitToContent(Ba,"$"))==null?void 0:N[0],Te=Te==null?void 0:Te.slice(0,(Te==null?void 0:Te.length)-1)):((se=te.analyzeSplitToContent(Ba,"}"))==null?void 0:se.length)>1&&(Te=(U=te.analyzeSplitToContent(Ba,"}"))==null?void 0:U[1]);let ye=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)),(_e=te.analyzeSplitToContent(Te,","))==null||_e.forEach(Ne=>{var oe;(Ne==null?void 0:Ne[0])!=="@"&&(Ne="@"+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));let ae=gn(Ne);(oe=te.analyzeSplitToContent(ae,","))==null||oe.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)})}),(ye==null?void 0:ye[0])==="$"&&(ye=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length)),ye!=null&&ye.includes("&")){let Ne=ye;if((ye==null?void 0:ye[0])==="("){let oe=(Ie=te.analyzeSplitToContent(ye,"&"))==null?void 0:Ie.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));Ne=oe==null?void 0:oe[1],oe=oe==null?void 0:oe[0],(oe==null?void 0:oe[0])!=="@"&&(oe="@"+oe),S=gn(oe)}(Ne==null?void 0:Ne[0])==="&"&&(Ne=Ne==null?void 0:Ne.slice(1,Ne==null?void 0:Ne.length)),$=(na=(je=Ne==null?void 0:Ne.replace("(",vl))==null?void 0:je.split(vl))==null?void 0:na[0],b=(ee=(Ca=Ne==null?void 0:Ne.replace("(",vl))==null?void 0:Ca.split(vl))==null?void 0:ee[1],b=[b==null?void 0:b.slice(0,(b==null?void 0:b.length)-1)],F="Input"}else{let Ne=(ca=ye==null?void 0:ye.replace("*",vl))==null?void 0:ca.split(vl);X=(de=Ne==null?void 0:Ne[0])==null?void 0:de.split(":"),me=(we=(pa=te.analyzeSplitToContent(Ne==null?void 0:Ne[1],":"))==null?void 0:pa.filter((ae,oe)=>{var Xe,Ze;return oe!==((Ze=(Xe=Ne==null?void 0:Ne[1])==null?void 0:Xe.split(":"))==null?void 0:Ze.length)-1}))==null?void 0:we.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)),Be=(De=(ue=te.analyzeSplitToContent(Ne==null?void 0:Ne[1],":"))==null?void 0:ue.filter((ae,oe)=>{var Xe,Ze;return oe===((Ze=(Xe=Ne==null?void 0:Ne[1])==null?void 0:Xe.split(":"))==null?void 0:Ze.length)-1}))==null?void 0:De[0],Be=(ua=(Ge=Be==null?void 0:Be.replaceAll("{",""))==null?void 0:Ge.replaceAll("}",""))==null?void 0:ua.split(":"),F="Select"}}else if(((Ja=te.analyzeSplitToContent(L,"="))==null?void 0:Ja.length)>1)if(F="Select",le=(H=(R=L==null?void 0:L.replace("=",vl))==null?void 0:R.split(vl))==null?void 0:H[0],!(L!=null&&L.includes("If")))ie=(he=(J=L==null?void 0:L.replace("=",vl))==null?void 0:J.split(vl))==null?void 0:he[1],ie=ie==null?void 0:ie.split("||");else{let Ba=(ha=(pe=L==null?void 0:L.replace("=",vl))==null?void 0:pe.split(vl))==null?void 0:ha[1];Y=(ta=te.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=(He=te.analyzeSplitToContent(Ba,")"))==null?void 0:He.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(((_a=te.analyzeSplitToContent(L,"@"))==null?void 0:_a.length)>1){le=(ze=te.analyzeSplitToContent(L,"@"))==null?void 0:ze[0],(le==null?void 0:le[(le==null?void 0:le.length)-1])==="@"&&(le=le==null?void 0:le.slice(0,(le==null?void 0:le.length)-1));let Ba="@"+((ma=te.analyzeSplitToContent(L,"@"))==null?void 0:ma[1]);Ba=gn(Ba),x=(Oa=te.analyzeSplitToContent(Ba,","))==null?void 0:Oa.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"))&&(F=(fa=(Ma=x==null?void 0:x.find(Te=>Te==null?void 0:Te.includes("@Type")))==null?void 0:Ma.split("="))==null?void 0:fa[1])}else le=L;x!=null&&x.includes("@ShowHide=Hide")&&(V=!0),n.push({prop:le,label:le,value:"",menuPath:X,groups:me,columns:Be,type:F,options:ie,allContents:Y,filters:x,width:g==null?void 0:g.length,isFormColHidden:V,filterContents:w,functionName:$,functionRelatedWords:b,calculatorFilter:S})}),{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=te.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=te.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},bt=(a,l)=>{var j,L,E,x,w,b,S,$,V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae,oe,Xe,Ze,Pa,Sa,Xa;let n,r=[],i=[],s=[],h=[],c=[],d=[],m=[],g="Input",u,C="",M="",k="",W=[],I="";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],g="Select",a!=null&&a.includes("=")&&!(a!=null&&a.includes("=="))&&!((w=(x=(E=a==null?void 0:a.replace("=",vl))==null?void 0:E.split(vl))==null?void 0:x[1])!=null&&w.includes("If")))if(n=te.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=(S=(b=n==null?void 0:n.replace("=",vl))==null?void 0:b.split(vl))==null?void 0:S[0],n!=null&&n.includes("&")&&(n=(V=($=n==null?void 0:n.replace("&",vl))==null?void 0:$.split(vl))==null?void 0:V[0]),u=n,((le=te.analyzeSplitToContent(a,"@"))==null?void 0:le.length)>1&&!(a!=null&&a.includes("||"))){if(!(a!=null&&a.includes("&"))){let Ve=(X=te.analyzeSplitToContent(a,"@"))==null?void 0:X[1];if((Ve==null?void 0:Ve[0])!=="@"&&(Ve="@"+Ve),Ve=gn(Ve),M=Ve,M!=null&&M.includes("@Type")){let Re=te.analyzeSplitToContent(M,",");Re=Re==null?void 0:Re.map(We=>((We==null?void 0:We[(We==null?void 0:We.length)-1])===","&&(We=We==null?void 0:We.slice(0,(We==null?void 0:We.length)-1)),We)),Re=(me=Re==null?void 0:Re.filter(We=>We==null?void 0:We.includes("@Type")))==null?void 0:me[0],g=(Be=Re==null?void 0:Re.split("="))==null?void 0:Be[1],g==="File"&&(g="Upload")}else g="Input"}}else if(a!=null&&a.includes("||")){let Ve=[];r=(Y=(ie=(F=te.analyzeSplitToContent(a,"="))==null?void 0:F[1])==null?void 0:ie.split("||"))==null?void 0:Y.map(We=>{var Me,cl,wl,Cl;let Ae=We;if(Ae!=null&&Ae.includes("@")){let Pl="@"+((cl=(Me=Ae==null?void 0:Ae.replace("@",vl))==null?void 0:Me.split(vl))==null?void 0:cl[1]);Ae=(Cl=(wl=Ae==null?void 0:Ae.replace("@",vl))==null?void 0:wl.split(vl))==null?void 0:Cl[0],Pl=ci(Pl),Ve.push(Pl)}return{label:Ae==null?void 0:Ae.replaceAll("'",""),value:Ae==null?void 0:Ae.replaceAll("'","")}}),(Ve==null?void 0:Ve.length)>0&&(M="("+(Ve==null?void 0:Ve.join("||"))+")");let Re=(ce=te.analyzeSplitToContent(a,"="))==null?void 0:ce[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 We=(Ce=te.analyzeSplitToContent(Re,"@"))==null?void 0:Ce[1];We="@"+We,We=ci(We),M=M===""?We:We+","+M}}else g="Input",C=(N=(fe=(Fe=a==null?void 0:a.replace("=",vl))==null?void 0:Fe.split(vl))==null?void 0:fe[1])==null?void 0:N.replaceAll("'","");else if((U=(se=te.analyzeSplitToContent(a,"="))==null?void 0:se[1])!=null&&U.includes("||")){let Ve=(_e=te.analyzeSplitToContent(a,"="))==null?void 0:_e[0];if((Ve==null?void 0:Ve[(Ve==null?void 0:Ve.length)-1])==="="&&(Ve=Ve==null?void 0:Ve.slice(0,(Ve==null?void 0:Ve.length)-1)),Ve!=null&&Ve.includes("@")){let Me=(Ie=te.analyzeSplitToContent(Ve,"@"))==null?void 0:Ie[1];Me="@"+Me,M=ci(Me),n=(ee=(je=te.analyzeSplitToContent(Ve,"@"))==null?void 0:je[0])==null?void 0:ee.slice(0,((Ca=(na=te.analyzeSplitToContent(Ve,"@"))==null?void 0:na[0])==null?void 0:Ca.length)-1),u=(we=(ca=te.analyzeSplitToContent(Ve,"@"))==null?void 0:ca[0])==null?void 0:we.slice(0,((pa=(de=te.analyzeSplitToContent(Ve,"@"))==null?void 0:de[0])==null?void 0:pa.length)-1)}else n=Ve,u=Ve;let Re=(ue=te.analyzeSplitToContent(a,"="))==null?void 0:ue[1];Re=te.analyzeSplitToContent(Re,")");let We=Re==null?void 0:Re.filter(Me=>!(Me!=null&&Me.includes("If")));We==null||We.forEach(Me=>{(Me==null?void 0:Me[0])==="("&&(Me=Me==null?void 0:Me.slice(1,(Me==null?void 0:Me.length)-1)),i==null||i.push(Me==null?void 0:Me.split("||"))});let Ae=Re==null?void 0:Re.filter(Me=>Me==null?void 0:Me.includes("If"));Ae=Ae==null?void 0:Ae.map(Me=>((Me==null?void 0:Me[0])==="|"&&(Me==null?void 0:Me[1])==="|"&&(Me=Me==null?void 0:Me.slice(2,Me==null?void 0:Me.length)),(Me==null?void 0:Me[0])==="("&&(Me=Me==null?void 0:Me.slice(1,(Me==null?void 0:Me.length)-1)),(Me==null?void 0:Me[0])!=="@"&&(Me="@"+Me),Me)),s=Ae}else{let Ve=a==null?void 0:a.split("=="),Re=(De=Ve==null?void 0:Ve.filter(We=>(We==null?void 0:We.includes("$"))&&(We==null?void 0:We[0])!=="{"))==null?void 0:De[0];if(Re&&!(Re!=null&&Re.includes("&"))){let We=(ua=te.analyzeSplitToContent(Re,")"))==null?void 0:ua[((Ge=te.analyzeSplitToContent(Re,")"))==null?void 0:Ge.length)-1],Ae=(Ja=We==null?void 0:We.replace("*",vl))==null?void 0:Ja.split(vl),Me=(Ae==null?void 0:Ae[0])===""?l==null?void 0:l.value:Ae==null?void 0:Ae[0];(Me==null?void 0:Me[0])==="("&&(Me=(R=te.analyzeSplitToContent(Me,")"))==null?void 0:R[1]),Me=(J=(H=Me==null?void 0:Me.replaceAll("{",""))==null?void 0:H.replaceAll("}",""))==null?void 0:J.replaceAll(Ki,""),(Me==null?void 0:Me[0])==="$"&&(Me=(he=Me==null?void 0:Me.slice(1,Me==null?void 0:Me.length))==null?void 0:he.replaceAll(":","/")),h=Me==null?void 0:Me.split("/");let cl=(ha=(pe=Ae==null?void 0:Ae[1])==null?void 0:pe.replace("{",vl))==null?void 0:ha.split(vl),wl=cl==null?void 0:cl[0];(wl==null?void 0:wl[(wl==null?void 0:wl.length)-1])===":"&&(wl=wl==null?void 0:wl.slice(0,(wl==null?void 0:wl.length)-1)),c=wl==null?void 0:wl.split(":"),d=(ze=(_a=(He=(ta=cl==null?void 0:cl[1])==null?void 0:ta.replace("}",vl))==null?void 0:He.split(vl))==null?void 0:_a[0])==null?void 0:ze.split(":");let Cl="";((ma=te.analyzeSplitToContent(Re,")"))==null?void 0:ma.length)>1&&(Cl=(Oa=te.analyzeSplitToContent(Re,")"))==null?void 0:Oa[0]),Cl&&Cl!==""&&((Cl==null?void 0:Cl[0])!=="@"&&(Cl="@"+Cl),M=ci(Cl))}if(Ve!=null&&Ve.some(We=>We==null?void 0:We.includes("&"))){let We=(Ma=Ve==null?void 0:Ve.filter(cl=>cl==null?void 0:cl.includes("&")))==null?void 0:Ma[0];We=(fa=te.analyzeSplitToContent(We,"&"))==null?void 0:fa.map(cl=>((cl==null?void 0:cl[(cl==null?void 0:cl.length)-1])==="&"&&(cl=cl==null?void 0:cl.slice(0,(cl==null?void 0:cl.length)-1)),cl)),k=(ye=(Te=(Ba=We==null?void 0:We[1])==null?void 0:Ba.replace("(",vl))==null?void 0:Te.split(vl))==null?void 0:ye[0];let Ae=(Ne=te.analyzeSplitToContent(We==null?void 0:We[1],")"))==null?void 0:Ne[0];Ae=(oe=(ae=Ae==null?void 0:Ae.replace("(",vl))==null?void 0:ae.split(vl))==null?void 0:oe[1],Ae=Ae==null?void 0:Ae.slice(0,(Ae==null?void 0:Ae.length)-1),(Ae==null?void 0:Ae[0])==="{"&&(Ae=Ae==null?void 0:Ae.slice(1,Ae==null?void 0:Ae.length)),(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)),W=Ae==null?void 0:Ae.split(",");let Me=We==null?void 0:We[0];Me&&Me!==""&&((Me==null?void 0:Me[0])!=="@"&&(Me="@"+Me),I=ci(Me))}else if(!Re&&((Xe=Ve==null?void 0:Ve.filter(We=>(We==null?void 0:We[0])==="{"))==null?void 0:Xe.length)>0){let We=Ve==null?void 0:Ve[(Ve==null?void 0:Ve.length)-1];We=We==null?void 0:We.slice(1,(We==null?void 0:We.length)-1),We=te.analyzeSplitToContent(We,","),We=We==null?void 0:We.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)),We=We==null?void 0:We.map(Ae=>{var Me,cl,wl,Cl;if(Ae=Ae==null?void 0:Ae.replaceAll("$",""),Ae!=null&&Ae.includes("{")){let Pl="";Ae=Ae==null?void 0:Ae.replaceAll("{","");let Sl=Ae==null?void 0:Ae.split("}");Pl=((cl=(Me=Sl==null?void 0:Sl[0])==null?void 0:Me.split(":"))==null?void 0:cl[0])+":"+(Sl==null?void 0:Sl[1]),Ae=Pl,Ae=Ae+":"}if(Ae!=null&&Ae.includes(Ki)){let Pl="",Sl=Ae==null?void 0:Ae.split(Ki);Pl=((Cl=(wl=Sl==null?void 0:Sl[0])==null?void 0:wl.split(":"))==null?void 0:Cl[0])+":"+(Sl==null?void 0:Sl[1]),Ae=Pl,Ae=Ae+":"}return Ae=Ae==null?void 0:Ae.replaceAll(":","/"),Ae}),m=We}else!((Ze=Ve==null?void 0:Ve[1])!=null&&Ze.includes("$"))&&((Pa=Ve==null?void 0:Ve[1])==null?void 0:Pa[0])!=="("&&d.push(Ve==null?void 0:Ve[1])}else n=(Sa=a==null?void 0:a.split("&"))==null?void 0:Sa[0],u=(Xa=a==null?void 0:a.split("&"))==null?void 0:Xa[0];return(r==null?void 0:r.length)===0&&(i==null?void 0:i.length)===0&&(h==null?void 0:h.length)===0&&g==="Select"&&(g="Input"),{label:n,prop:u,options:r,allContents:i,filterContents:s,menus:h,groups:c,words:d,align:"center",formType:g,filter:M,functionName:k,functionRelatedWords:W,calculatorFilter:I,relatedPages:m,value:C}},Ao=(a,l)=>{var r,i,s,h,c,d,m,g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me,Be,F,ie,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(":",vl))==null?void 0:i.split(vl))==null?void 0:s[0])!=null&&h.includes(","))){let ce=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1),Ce=(c=ce==null?void 0:ce.replace(":",vl))==null?void 0:c.split(vl);if(((d=te.analyzeSplitToContent(Ce==null?void 0:Ce[1],"="))==null?void 0:d.length)===1){let Fe=Ce==null?void 0:Ce[0],fe=[];(u=te.analyzeSplitToContent((g=Ce==null?void 0:Ce[1])==null?void 0:g.slice(1,((m=Ce==null?void 0:Ce[1])==null?void 0:m.length)-1),","))==null||u.forEach(N=>{var se,U;((se=te.analyzeSplitToContent(N,"="))==null?void 0:se.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)),fe=[...fe,...Ao(N,l)]):((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)),fe.push((U=Ao(N,l))==null?void 0:U[0]))}),n==null||n.push({label:Fe,prop:Fe,children:fe,align:"center"})}else{let Fe=[];if(((C=te.analyzeSplitToContent(ce,"="))==null?void 0:C.length)>=2){let N=(M=te.analyzeSplitToContent(ce,"="))==null?void 0:M[1],se=(k=te.analyzeSplitToContent(N,"/"))==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));Fe=se==null?void 0:se.map(U=>(U=Ni(U),U))}let fe=(x=(E=(L=(j=(I=(W=ce==null?void 0:ce.replace("{",vl))==null?void 0:W.split(vl))==null?void 0:I[1])==null?void 0:j.replace("}",vl))==null?void 0:L.split(vl))==null?void 0:E[0])==null?void 0:x.split(",");fe==null||fe.forEach((N,se)=>{(Fe==null?void 0:Fe.length)>0&&se===0?n==null||n.push({label:N,prop:N,align:"center",formType:"Select",relatedContents:Fe==null?void 0:Fe.map(U=>{let _e={};return fe==null||fe.forEach((Ie,je)=>{_e[Ie]=U==null?void 0:U[je]}),_e}),options:Fe==null?void 0:Fe.map(U=>({label:U==null?void 0:U[0],value:U==null?void 0:U[0]})),mainKey:!0}):n==null||n.push({label:N,prop:N,align:"center"})})}}else if((a==null?void 0:a[0])==="{")if(((w=te.analyzeSplitToContent(a,"="))==null?void 0:w.length)===2&&((S=(b=te.analyzeSplitToContent(a,"="))==null?void 0:b[1])==null?void 0:S[0])==="["){let ce=[];if((($=te.analyzeSplitToContent(a,"="))==null?void 0:$.length)>=2){let Fe=(V=te.analyzeSplitToContent(a,"="))==null?void 0:V[1],fe=(X=(le=te.analyzeSplitToContent(Fe,"|"))==null?void 0:le.filter(N=>N!=="|"))==null?void 0:X.map(N=>((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));ce=fe==null?void 0:fe.map(N=>(N=Ni(N),N))}let Ce=(Be=(me=a==null?void 0:a.replace("}",vl))==null?void 0:me.split(vl))==null?void 0:Be[0];Ce=(F=Ce==null?void 0:Ce.slice(1,Ce==null?void 0:Ce.length))==null?void 0:F.split(","),Ce==null||Ce.forEach((Fe,fe)=>{(ce==null?void 0:ce.length)>0&&fe===0?n==null||n.push({label:Fe,prop:Fe,align:"center",formType:"Select",relatedContents:ce==null?void 0:ce.map(N=>{let se={};return Ce==null||Ce.forEach((U,_e)=>{se[U]=N==null?void 0:N[_e]}),se}),options:ce==null?void 0:ce.map(N=>({label:N==null?void 0:N[0],value:N==null?void 0:N[0]})),mainKey:!0}):n==null||n.push({label:Fe,prop:Fe,align:"center"})})}else(ie=te.analyzeSplitToContent(a,","))==null||ie.forEach(ce=>{var Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae;if((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==null?void 0:ce[0])==="{"){let oe=te.analyzeSplitToContent(ce,"="),Xe=oe==null?void 0:oe[(oe==null?void 0:oe.length)-1],Ze=[],Pa=[],Sa=[],Xa="",Ve="",Re=[],We=[],Ae=(Ce=Xe==null?void 0:Xe.replace("*",vl))==null?void 0:Ce.split(vl),Me=(Ae==null?void 0:Ae[0])===""?l==null?void 0:l.value:Ae==null?void 0:Ae[0];Me=te.analyzeSplitToContent(Me,")");let cl="";if((Me==null?void 0:Me.length)>1&&((Fe=Me==null?void 0:Me[0])==null?void 0:Fe[0])!=="&"&&(cl=Me==null?void 0:Me[0],(cl==null?void 0:cl[0])!=="@"&&(cl="@"+cl),Ve=cl??""),Me=(fe=Me==null?void 0:Me.filter(aa=>(aa==null?void 0:aa[0])==="$"))==null?void 0:fe[0],((N=te.analyzeSplitToContent(Me,"}"))==null?void 0:N.length)>1&&((U=(se=te.analyzeSplitToContent(Me,"}"))==null?void 0:se[1])==null?void 0:U[0])==="("&&(cl=(_e=te.analyzeSplitToContent(Me,"}"))==null?void 0:_e[1],(cl==null?void 0:cl[0])!=="@"&&(cl="@"+cl),Ve!==""&&(Ve=Ve+","),Ve=Ve+cl),(Ie=Me==null?void 0:Me.slice(1,(Me==null?void 0:Me.length)-1))!=null&&Ie.includes("$")||(Me=(je=te.analyzeSplitToContent(Me,"}"))==null?void 0:je[0]),(Me==null?void 0:Me[0])==="$"&&(Me=(na=Me==null?void 0:Me.replace("{",""))==null?void 0:na.replace("}",":"),Me=(Ca=Me==null?void 0:Me.slice(1,Me==null?void 0:Me.length))==null?void 0:Ca.replaceAll(":","/")),Me!=null&&Me.includes("$")){let aa=(ee=Me==null?void 0:Me.split("$"))==null?void 0:ee[0];aa=(ca=aa==null?void 0:aa.split("/"))==null?void 0:ca[0],Me=aa+"/"+((de=Me==null?void 0:Me.split("$"))==null?void 0:de[1])+"/"}Ze=(Me==null?void 0:Me.split("/"))??[];let wl=(we=(pa=Ae==null?void 0:Ae[1])==null?void 0:pa.replace("{",vl))==null?void 0:we.split(vl);if((Ge=(De=(ue=Ae==null?void 0:Ae[1])==null?void 0:ue.split("(@"))==null?void 0:De[0])!=null&&Ge.includes("&&")||(R=(Ja=(ua=Ae==null?void 0:Ae[1])==null?void 0:ua.split("@"))==null?void 0:Ja[0])!=null&&R.includes("&&")){let aa=(H=Ae==null?void 0:Ae[1])!=null&&H.includes("(@")?(pe=(he=(J=Ae==null?void 0:Ae[1])==null?void 0:J.split("(@"))==null?void 0:he[0])==null?void 0:pe.split("&&"):(He=(ta=(ha=Ae==null?void 0:Ae[1])==null?void 0:ha.split("@"))==null?void 0:ta[0])==null?void 0:He.split("&&");Re=aa==null?void 0:aa.map(ya=>{var rl,Aa;return(ya==null?void 0:ya[0])==="*"&&(ya=ya==null?void 0:ya.slice(1,ya==null?void 0:ya.length)),ya=(Aa=(rl=ya==null?void 0:ya.replace("{",vl))==null?void 0:rl.split(vl))==null?void 0:Aa[0],(ya==null?void 0:ya[(ya==null?void 0:ya.length)-1])===":"&&(ya=ya==null?void 0:ya.slice(0,(ya==null?void 0:ya.length)-1)),ya=ya==null?void 0:ya.split(":"),ya});let Ha=[];aa==null||aa.forEach((ya,rl)=>{var Aa,ol;(ya==null?void 0:ya[0])==="*"&&(ya=ya==null?void 0:ya.slice(1,ya==null?void 0:ya.length)),ya=(ol=(Aa=ya==null?void 0:ya.replace("{",vl))==null?void 0:Aa.split(vl))==null?void 0:ol[1],(ya==null?void 0:ya[(ya==null?void 0:ya.length)-1])==="}"&&(ya=ya==null?void 0:ya.slice(0,(ya==null?void 0:ya.length)-1)),ya=ya==null?void 0:ya.split(","),Ha.push(rl===0?(ya==null?void 0:ya.length)-1:ya==null?void 0:ya.length),We=[...We,...ya]}),Ha=(_a=te.prefixSum(Ha))==null?void 0:_a.map(ya=>ya==null?void 0:ya.total),Re=Re==null?void 0:Re.map((ya,rl)=>({number:Ha==null?void 0:Ha[rl],contents:ya}))}let Cl=wl==null?void 0:wl[0];(Cl==null?void 0:Cl[(Cl==null?void 0:Cl.length)-1])===":"&&(Cl=Cl==null?void 0:Cl.slice(0,(Cl==null?void 0:Cl.length)-1)),Pa=(Cl==null?void 0:Cl.split(":"))??[],Sa=((Ma=(Oa=(ma=(ze=wl==null?void 0:wl[1])==null?void 0:ze.replace("}",vl))==null?void 0:ma.split(vl))==null?void 0:Oa[0])==null?void 0:Ma.split(","))??[];let Pl=(Ba=oe==null?void 0:oe[0])==null?void 0:Ba.slice(1,((fa=oe==null?void 0:oe[0])==null?void 0:fa.length)-2);Ve&&Ve!==""&&(Xa=ci(Ve));let Sl=(Te=te.analyzeSplitToContent(Xa,","))==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)),Gl=[];Sl!=null&&Sl.find(aa=>aa==null?void 0:aa.includes("@MainParam"))&&(Sl=Sl==null?void 0:Sl.find(aa=>aa==null?void 0:aa.includes("@MainParam")),Sl=(Ne=(ye=Sl==null?void 0:Sl.replace("=",vl))==null?void 0:ye.split(vl))==null?void 0:Ne[1],Sl=Sl==null?void 0:Sl.slice(1,(Sl==null?void 0:Sl.length)-1),Gl=te.analyzeSplitToContent(Sl,",")),(ae=Pl==null?void 0:Pl.split(","))==null||ae.forEach((aa,Ha)=>{var ya,rl,Aa,ol,al;((ya=te.analyzeSplitToContent(aa,"@"))==null?void 0:ya.length)>1&&(aa=(rl=te.analyzeSplitToContent(aa,"@"))==null?void 0:rl[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?Pa:(Aa=Re==null?void 0:Re.find(ke=>(ke==null?void 0:ke.number)>=Ha))==null?void 0:Aa.contents,words:(We==null?void 0:We.length)===0?(ol=Sa==null?void 0:Sa[Ha])==null?void 0:ol.split(":"):(al=We==null?void 0:We[Ha])==null?void 0:al.split(":"),formType:(Ze==null?void 0:Ze.length)>0?"Select":"Input",mainKey:!!(Ha===0||Gl!=null&&Gl.find(ke=>ke===aa)),filter:Xa,isMainPath:(Re==null?void 0:Re.findIndex(ke=>(ke==null?void 0:ke.number)>=Ha))===0})})}else n.push({label:ce,prop:ce,align:"center"})});else{let ce=(Y=te.analyzeSplitToContent(a,","))==null?void 0:Y.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));ce==null||ce.forEach(Ce=>{n.push(bt(Ce,l))})}return n},ep=(a,l)=>{var h,c,d,m,g;let n=a;if(!a)return;let r="";((h=te.analyzeSplitToContent(a,"}"))==null?void 0:h.length)>1&&(n=(c=te.analyzeSplitToContent(a,"}"))==null?void 0:c[0],r=(d=te.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=te.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(bt(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)),(g=te.analyzeSplitToContent(r,","))==null||g.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(bt(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("(",vl))==null?void 0:l.split(vl))==null?void 0:n[1],c=(i=(r=a==null?void 0:a.replace("(",vl))==null?void 0:r.split(vl))==null?void 0:i[0];return h=h==null?void 0:h.slice(0,(h==null?void 0:h.length)-1),h=(s=te.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}},cs=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("/"))+vl+((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(vl))==null?void 0:r[0],groups:((i=n==null?void 0:n.split(vl))==null?void 0:i[1])??[]}}),l},us=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=te.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(",")},oc=(a,l,n="")=>{var L,E,x,w,b,S,$,V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba,Te;let r=[],i=[],s=[],h="",c="",d="",m=[],g=[],u=[],C="";if(((L=a==null?void 0:a[0])==null?void 0:L[0])!=="*"&&((E=a==null?void 0:a[0])==null?void 0:E[0])!=="$"&&!((x=a==null?void 0:a[0])!=null&&x.includes("$")))return;((w=a==null?void 0:a[0])==null?void 0:w[0])!=="*"&&((b=a==null?void 0:a[0])==null?void 0:b[0])!=="$"&&(h=(S=te.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:S[0],(h==null?void 0:h[0])!=="@"&&(h="@"+h),h=ci(h),d=($=te.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:$[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=te.analyzeSplitToContent(a==null?void 0:a[0],":");if(r=(V=k==null?void 0:k.filter(ye=>(ye==null?void 0:ye[0])!=="{"&&(ye==null?void 0:ye[0])!=="["))==null?void 0:V.join(""),c=(le=a==null?void 0:a[0])==null?void 0:le.replace(r,""),(r==null?void 0:r[0])==="("&&(r=""),C=(X=k==null?void 0:k.filter(ye=>(ye==null?void 0:ye[0])!=="["))==null?void 0:X.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)),((Be=te.analyzeSplitToContent(c,"@"))==null?void 0:Be.length)>1&&(h=(F=te.analyzeSplitToContent(c,"@"))==null?void 0:F[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=(ie=te.analyzeSplitToContent(c,"@"))==null?void 0:ie[0],c=c==null?void 0:c.slice(0,(c==null?void 0:c.length)-1)),((Y=te.analyzeSplitToContent(r,"@"))==null?void 0:Y.length)>1){h!==""&&(h=h+",");let ye=(ce=te.analyzeSplitToContent(r,"@"))==null?void 0:ce[1];ye="@"+ye,ye=gn(ye),h=h+ye,r=(Ce=te.analyzeSplitToContent(r,"@"))==null?void 0:Ce[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 ye=(Fe=te.analyzeSplitToContent(n,")"))==null?void 0:Fe[0],Ne=(fe=te.analyzeSplitToContent(n,"@"))==null?void 0:fe[1];d=(se=(N=te.analyzeSplitToContent(n,"@"))==null?void 0:N[0])==null?void 0:se.replace(ye,""),(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)),ye=us(ye),Ne=us(Ne);let ae=ye??"";if(ae!==""&&(ae=ae+","),ae=ae+Ne,(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=te.analyzeSplitToContent(d,":"))==null?void 0:U.filter((oe,Xe)=>{var Ze;return!((oe==null?void 0:oe[0])==="{"&&Xe===((Ze=te.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 oe=(Ie=(_e=d==null?void 0:d.replace("*",vl))==null?void 0:_e.split(vl))==null?void 0:Ie[1],Xe=(na=(je=d==null?void 0:d.replace("*",vl))==null?void 0:je.split(vl))==null?void 0:na[0];Xe=Xe==null?void 0:Xe.split("$"),Xe=((ee=(Ca=Xe==null?void 0:Xe[0])==null?void 0:Ca.split(":"))==null?void 0:ee[0])+":"+(Xe==null?void 0:Xe[1])+":",d=Xe+"*"+oe}else d=(ca=d==null?void 0:d.replaceAll("{",""))==null?void 0:ca.replaceAll("}","")}h!==""&&h&&(h="("+h+")"),h=d+h,((de=te.analyzeSplitToContent(c,"}"))==null?void 0:de.length)>1&&(c=(pa=te.analyzeSplitToContent(c,"}"))==null?void 0:pa.filter(ye=>(ye==null?void 0:ye[0])!=="@"),c=c==null?void 0:c.join(""));let W=ep(c,l);s=c===""?[]:(W==null?void 0:W.columns)??[],u=te.getColumnChild(s);let I=te.getColumnChild(s);s!=null&&s.some(ye=>{var Ne;return Array.isArray(ye==null?void 0:ye.children)&&((Ne=ye==null?void 0:ye.children)==null?void 0:Ne.length)>0})&&(s=[s]),i=C?Ni(C):[],!(i!=null&&i.every(ye=>Array.isArray(ye)))&&(i==null?void 0:i.length)>0&&(i=[i]),(i==null?void 0:i.length)>0&&(Array.isArray(i==null?void 0:i[0])&&((we=i==null?void 0:i[0])!=null&&we.every(ye=>Array.isArray(ye)))?i=i==null?void 0:i.map((ye,Ne)=>(ye=ye.map((ae,oe)=>(ae.unshift("{}"),ae.unshift((oe+1).toString()),ae)),ye)):i=i==null?void 0:i.map((ye,Ne)=>(ye.unshift("{}"),ye.unshift((Ne+1).toString()),ye))),W!=null&&W.secondColumns&&((ue=W==null?void 0:W.secondColumns)==null?void 0:ue.length)>0&&((i==null?void 0:i.length)>0?i=i==null?void 0:i.map((ye,Ne)=>{var ae,oe;return Array.isArray(ye==null?void 0:ye[0])?ye=ye==null?void 0:ye.map((Xe,Ze)=>{var Pa,Sa;return Xe.unshift((Sa=(Pa=W==null?void 0:W.secondColumns)==null?void 0:Pa[Ze])==null?void 0:Sa.prop),Xe}):ye.unshift((oe=(ae=W==null?void 0:W.secondColumns)==null?void 0:ae[Ne])==null?void 0:oe.prop),ye}):i=(De=W==null?void 0:W.secondColumns)==null?void 0:De.map((ye,Ne)=>(ye=[ye==null?void 0:ye.label],ye.push(Ne),ye)),s.unshift({label:"",prop:"disabled",sortable:!1})),u=u==null?void 0:u.map(ye=>{var Ne,ae;return{menus:ye==null?void 0:ye.menus,content:((Ne=ye==null?void 0:ye.menus)==null?void 0:Ne.join("/"))+vl+((ae=ye==null?void 0:ye.groups)==null?void 0:ae.join("/"))}});let j=[];if(((ua=(Ge=h==null?void 0:h.replace("(",vl))==null?void 0:Ge.split(vl))==null?void 0:ua[0])!==""&&(j=(R=(Ja=h==null?void 0:h.replace("(",vl))==null?void 0:Ja.split(vl))==null?void 0:R[0],j=[j],j=j==null?void 0:j.map(ye=>{var ae,oe,Xe;let Ne=ye==null?void 0:ye.split("*");return{menus:(ae=Ne==null?void 0:Ne[0])==null?void 0:ae.split(":"),content:((oe=Ne==null?void 0:Ne[0])==null?void 0:oe.replaceAll(":","/"))+vl+((Xe=Ne==null?void 0:Ne[1])==null?void 0:Xe.replaceAll(":","/"))}}),u=[...u,...j]),u=u==null?void 0:u.filter(ye=>{var Ne;return(ye==null?void 0:ye.menus)&&((Ne=ye==null?void 0:ye.menus)==null?void 0:Ne.length)>0}),u=u==null?void 0:u.map(ye=>ye==null?void 0:ye.content),u=[...new Set(u)],u=u==null?void 0:u.map(ye=>{var Ne,ae;return{menus:(Ne=ye==null?void 0:ye.split(vl))==null?void 0:Ne[0],groups:((ae=ye==null?void 0:ye.split(vl))==null?void 0:ae[1])??[]}}),m=I==null?void 0:I.filter(ye=>{var Ne;return(ye==null?void 0:ye.filter)&&((Ne=ye==null?void 0:ye.filter)==null?void 0:Ne.includes("@Sync"))}),(m==null?void 0:m.length)>0&&(m=m==null?void 0:m.filter(ye=>{var Ne,ae,oe,Xe;return(Xe=(oe=(ae=(Ne=te.analyzeSplitToContent(ye==null?void 0:ye.filter,","))==null?void 0:Ne.find(Ze=>Ze==null?void 0:Ze.includes("@Sync")))==null?void 0:ae.split(","))==null?void 0:oe[0])==null?void 0:Xe.includes("Yes")}),m=cs(m)),g=I==null?void 0:I.filter(ye=>{var Ne;return(ye==null?void 0:ye.filter)&&((Ne=ye==null?void 0:ye.filter)==null?void 0:Ne.includes("@Sync"))}),(g==null?void 0:g.length)>0&&(g=g==null?void 0:g.filter(ye=>{var Ne,ae,oe,Xe;return(Xe=(oe=(ae=(Ne=te.analyzeSplitToContent(ye==null?void 0:ye.filter,","))==null?void 0:Ne.find(Ze=>Ze==null?void 0:Ze.includes("@Sync")))==null?void 0:ae.split(","))==null?void 0:oe[1])==null?void 0:Xe.includes("Yes")}),g=cs(g)),h!==""&&(h!=null&&h.includes("@Sync"))&&(h==null?void 0:h[0])!=="("){let ye=(H=h==null?void 0:h.replace("(",vl))==null?void 0:H.split(vl),Ne=ye==null?void 0:ye[1];if(Ne=Ne==null?void 0:Ne.slice(0,(Ne==null?void 0:Ne.length)-1),Ne=te.analyzeSplitToContent(Ne,","),(pe=(he=(J=Ne==null?void 0:Ne.find(ae=>ae==null?void 0:ae.includes("@Sync")))==null?void 0:J.split(","))==null?void 0:he[0])!=null&&pe.includes("Yes")){let ae=ye==null?void 0:ye[0];ae=[{menus:(ta=(ha=ae==null?void 0:ae.split("*"))==null?void 0:ha[0])==null?void 0:ta.replaceAll(":","/"),groups:((_a=(He=ae==null?void 0:ae.split("*"))==null?void 0:He[1])==null?void 0:_a.split(":"))??[]}],m=[...m,...ae]}if((Oa=(ma=(ze=Ne==null?void 0:Ne.find(ae=>ae==null?void 0:ae.includes("@Sync")))==null?void 0:ze.split(","))==null?void 0:ma[1])!=null&&Oa.includes("Yes")){let ae=ye==null?void 0:ye[0];ae=[{menus:(fa=(Ma=ae==null?void 0:ae.split("*"))==null?void 0:Ma[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(":"))??[]}],g=[...g,...ae]}}return{groupName:r,tableColumns:s,tableFilter:h,tableContents:i,columns:(W==null?void 0:W.secondColumns)??[],relatedQuotes:u,fatherSyncContents:m,sonSyncContents:g}},tc=(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,g,u,C;return d!=null&&d.isMainPath||(((m=d==null?void 0:d.children)==null?void 0:m.length)>0?d.children=tc(d.children,l):((g=d==null?void 0:d.menus)==null?void 0:g.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,I;return((W=d.menus)==null?void 0:W.length)-1===k&&M===""&&(l==null?void 0:l.parentContent)+"/"!==((I=d.menus)==null?void 0:I.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 g,u;return((g=n.menus)==null?void 0:g.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),ap=(a,l)=>(a=a==null?void 0:a.map(n=>((n==null?void 0:n.key)==="header"&&(n.contents=tc(n.contents,l)),n)),a),kt=(a,l)=>{let n=a;return Array.isArray(n==null?void 0:n[0])?n=n==null?void 0:n.map(r=>(r=kt(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=kt(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,g;return((g=(c=r==null?void 0:r.prop)==null?void 0:c.split("."))==null?void 0:g[((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 mr="$R";const lp=A.useUnit(A.pinia),{selectTitle:pn}=A.storeToRefs(lp),rp=A.useMenuState(A.pinia),{localFiles:np}=A.storeToRefs(rp),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 ip=a=>{var n,r,i;let l=te.analyzeSplitToContent((a==null?void 0:a.filter)??"",")");if((l==null?void 0:l.length)>1){let s=l==null?void 0:l[0];s=s==null?void 0:s.slice(1,(s==null?void 0:s.length)-1),s=(r=(n=s==null?void 0:s.replace("(",mr))==null?void 0:n.split(mr))==null?void 0:r[1],s="("+((i=s==null?void 0:s.replaceAll("{",""))==null?void 0:i.replaceAll("}",""))}return a==null?void 0:a.contents},op=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=te.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=te.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=np.value)==null?void 0:r.filter(m=>{var g;return(m==null?void 0:m.path)===((g=a==null?void 0:a.groupName)==null?void 0:g[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(g=>g===(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},tp=a=>{const l=cc(a==null?void 0:a.filter);return l?uc(a==null?void 0:a.contents,{position:l}):a==null?void 0:a.contents},sp=a=>{const l=cc(a==null?void 0:a.filter);return l?uc(a==null?void 0:a.contents,{size:l}):a==null?void 0:a.contents},cp=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},up=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},dp=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})},pp=async a=>{var l,n,r,i,s,h,c,d,m,g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me,Be,F;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=te.shuffle(Y.contents)),Y));if((a==null?void 0:a.filter)==="Auto"){let ie=(r=(n=a==null?void 0:a.contents)==null?void 0:n.find(_e=>(_e==null?void 0:_e.key)==="header"))==null?void 0:r.contents;Array.isArray(ie==null?void 0:ie[0])&&(ie=ie==null?void 0:ie[0]),ie=te.getColumnChild(ie);let Y=ie==null?void 0:ie.filter(_e=>(_e==null?void 0:_e.filter)&&(_e==null?void 0:_e.filter)!==""),ce=new Map,Ce=[];Y==null||Y.forEach(_e=>{var Ie,je;ce.get((Ie=_e==null?void 0:_e.menus)==null?void 0:Ie.join("/"))||(ce.set((je=_e==null?void 0:_e.menus)==null?void 0:je.join("/"),_e),Ce.push(_e))});let Fe=(s=(i=pn==null?void 0:pn.value)==null?void 0:i.find(_e=>(_e==null?void 0:_e.condition)==="child"))==null?void 0:s.value,fe=Ce==null?void 0:Ce.map(_e=>{var Ie,je,na;return _e=(Ie=_e==null?void 0:_e.menus)==null?void 0:Ie.join("/"),(_e==null?void 0:_e[(_e==null?void 0:_e.length)-1])==="/"&&((na=(je=pn==null?void 0:pn.value)==null?void 0:je.find(Ca=>(Ca==null?void 0:Ca.condition)==="child"))==null?void 0:na.parentContent)+"/"!==_e?_e=_e+Fe:(_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}),N=Ce==null?void 0:Ce.map(_e=>_e==null?void 0:_e.groups),se=fe==null?void 0:fe.map(async _e=>{let Ie=await an(_e,!1);return{path:_e,contents:Ie}});se=await Promise.all(se);let U=se==null?void 0:se.map((_e,Ie)=>{var na,Ca,ee,ca,de,pa,we;let je=(na=_e==null?void 0:_e.contents)==null?void 0:na.filter(ue=>{var De,Ge;return(ue==null?void 0:ue.name)===((Ge=N==null?void 0:N[Ie])==null?void 0:Ge[((De=N==null?void 0:N[Ie])==null?void 0:De.length)-1])});return je=(ca=(ee=(Ca=je==null?void 0:je[0])==null?void 0:Ca.compData)==null?void 0:ee.find(ue=>(ue==null?void 0:ue.key)==="tableContents"))==null?void 0:ca.contents,(_e==null?void 0:_e.path)===((pa=(de=pn==null?void 0:pn.value)==null?void 0:de.find(ue=>(ue==null?void 0:ue.condition)==="child"))==null?void 0:pa.parentContent)&&(je=((we=je==null?void 0:je.map(ue=>{for(let De in ue)if(ue[De]===Fe)return ue}))==null?void 0:we.filter(ue=>ue))??[]),je??[]});if(U=U==null?void 0:U.map(_e=>(_e=_e==null?void 0:_e.map(Ie=>{var na;let je={};for(let Ca in Ie)if(Y!=null&&Y.find(ee=>{var ca,de;return((de=(ca=ee==null?void 0:ee.words)==null?void 0:ca[0])==null?void 0:de.replaceAll("'",""))===Ca})){let ee=(na=Y==null?void 0:Y.find(ca=>{var de,pa;return((pa=(de=ca==null?void 0:ca.words)==null?void 0:de[0])==null?void 0:pa.replaceAll("'",""))===Ca}))==null?void 0:na.prop;je[ee]=Ie==null?void 0:Ie[Ca]}return je}),_e)),U=te.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[((g=(m=(d=Y==null?void 0:Y[0])==null?void 0:d.menus)==null?void 0:m.join("/"))==null?void 0:g.length)-1])==="/")return(C=a==null?void 0:a.contents)==null?void 0:C.map(Ie=>{var je;return(Ie==null?void 0:Ie.key)==="tableContents"&&(U==null?void 0:U.length)>0&&(Ie.contents=((je=Ie.contents)==null?void 0:je.length)>0?Ie.contents:U),Ie})}if((a==null?void 0:a.filter)==="Manual"){let ie=[],Y=[],ce=(k=(M=a==null?void 0:a.contents)==null?void 0:M.find(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:k.contents;(ce==null?void 0:ce[(ce==null?void 0:ce.length)-1])===")"?ce=(I=(W=ce==null?void 0:ce.replace("(",mr))==null?void 0:W.split(mr))==null?void 0:I[0]:ce="",ce!==""&&(ie=((L=(j=ce==null?void 0:ce.split("*"))==null?void 0:j[0])==null?void 0:L.split(":"))??[],Y=((S=(b=(w=(x=(E=ce==null?void 0:ce.split("*"))==null?void 0:E[1])==null?void 0:x.replace("{",mr))==null?void 0:w.split(mr))==null?void 0:b[0])==null?void 0:S.split(":"))??[]);let Ce=(V=($=a==null?void 0:a.contents)==null?void 0:$.find(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:V.contents;Ce=(X=(le=Ce==null?void 0:Ce.replace("(",mr))==null?void 0:le.split(mr))==null?void 0:X[1],Ce=Ce==null?void 0:Ce.slice(0,(Ce==null?void 0:Ce.length)-1);let Fe=(me=a==null?void 0:a.contents)==null?void 0:me.map(N=>{var se,U,_e,Ie,je,na,Ca,ee,ca;return(N==null?void 0:N.key)==="header"&&((se=N==null?void 0:N.contents)!=null&&se.every(de=>(de==null?void 0:de.mainKey)!==!0)&&Array.isArray(N==null?void 0:N.contents)&&!Array.isArray((U=N==null?void 0:N.contents)==null?void 0:U[0])?N.contents=(_e=N==null?void 0:N.contents)==null?void 0:_e.map((de,pa)=>{var we,ue,De;return de!=null&&de.isMainPath||(pa===0?(de.mainKey=!0,de.formType="Select",de.bindMenus=ie,de.groups=((we=de.groups)==null?void 0:we.length)===0?Y:de.groups,de.words=((ue=de.words)==null?void 0:ue.length)===0?[de==null?void 0:de.prop]:de.words,de.filter=Ce,(!(de!=null&&de.menus)||((De=de==null?void 0:de.menus)==null?void 0:De.length)===0)&&(de.menus=ie)):(de.mainKey=!1,de.bindMenus=ie)),de}):Array.isArray((Ie=N==null?void 0:N.contents)==null?void 0:Ie[0])&&((Ca=(na=(je=N==null?void 0:N.contents)==null?void 0:je[0])==null?void 0:na.filter(()=>(ie==null?void 0:ie.length)>0))==null?void 0:Ca.length)>0&&(N.contents[0]=(ca=(ee=N==null?void 0:N.contents)==null?void 0:ee[0])==null?void 0:ca.map((de,pa)=>{var we,ue,De;return de!=null&&de.isMainPath||(pa===0?(de.mainKey=!0,de.formType="Select",de.bindMenus=ie,de.groups=((we=de.groups)==null?void 0:we.length)===0?Y:de.groups,de.words=((ue=de.words)==null?void 0:ue.length)===0?[de==null?void 0:de.prop]:de.words,de.filter=Ce,(!(de!=null&&de.menus)||Array.isArray(de==null?void 0:de.menus)&&((De=de==null?void 0:de.menus)==null?void 0:De.length)===0)&&(ie==null?void 0:ie.length)>0&&(de.menus=ie)):(de.mainKey=!1,de.bindMenus=ie)),de}))),N}),fe=(Be=Fe==null?void 0:Fe.find(N=>(N==null?void 0:N.key)==="header"))==null?void 0:Be.contents;if(Array.isArray(fe==null?void 0:fe[0])&&(fe=fe==null?void 0:fe[0]),fe=te.getColumnChild(fe),fe!=null&&fe.some(N=>{var se,U;return((U=N==null?void 0:N.menus)==null?void 0:U[((se=N==null?void 0:N.menus)==null?void 0:se.length)-1])===""})){let N=(F=pn==null?void 0:pn.value)==null?void 0:F.find(se=>(se==null?void 0:se.condition)==="child");Fe=ap(Fe,N)}return Fe}if((a==null?void 0:a.filter)==="Chart"){let ie=a==null?void 0:a.contents;return ie.push({key:"newType",contents:"Chart"}),ie}if((a==null?void 0:a.filter)==="Carousel"){let ie=a==null?void 0:a.contents;return ie.push({key:"newType",contents:"Carousel"}),ie}return a==null?void 0:a.contents},fp=async 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},hp=a=>{var r,i,s,h,c,d,m,g,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(":",mr))==null?void 0:r.split(mr))==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],I=(m=l==null?void 0:l.split("="))==null?void 0:m[1];(g=I==null?void 0:I.slice(1,I==null?void 0:I.length))!=null&&g.includes("$")&&(I=(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+"="+I}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=te.calculatorAndToOr(l);if((n==null?void 0:n.length)>0){let W=[];return n==null||n.forEach(j=>{let L={};for(let E in j){let x=E;x!=null&&x.includes("[")||(L[x]=j[E])}W.push(L)}),(k=a==null?void 0:a.contents)==null?void 0:k.map(j=>{var E,x,w;let L=(x=(E=a==null?void 0:a.contents)==null?void 0:E.find(b=>(b==null?void 0:b.key)==="header"))==null?void 0:x.contents;if(L=(w=te.getEqualChild(L))==null?void 0:w.filter(b=>(b==null?void 0:b.label)!=="操作"),(j==null?void 0:j.key)==="tableContents"){let S=te.tableToForm(j==null?void 0:j.contents,L);W==null||W.forEach($=>{var V,le;for(let X in $)!((V=S==null?void 0:S[0])!=null&&V.find(me=>{var Be;return(me==null?void 0:me.key)===X||((Be=me==null?void 0:me.key)==null?void 0:Be.includes(X))}))&&!(S!=null&&S.find(me=>{var Be;return(me==null?void 0:me.key)===X||((Be=me==null?void 0:me.key)==null?void 0:Be.includes(X))}))||(((le=$[X])==null?void 0:le[0])!=="!"?S=S==null?void 0:S.filter(me=>{var Be,F;return((Be=me==null?void 0:me.find(ie=>{var Y;return(ie==null?void 0:ie.key)===X||((Y=ie==null?void 0:ie.key)==null?void 0:Y.includes(X))}))==null?void 0:Be.value)===$[X]||Array.isArray($==null?void 0:$[X])&&((F=$==null?void 0:$[X])==null?void 0:F.find(ie=>{var Y;return((Y=me==null?void 0:me.find(ce=>{var Ce;return(ce==null?void 0:ce.key)===X||((Ce=ce==null?void 0:ce.key)==null?void 0:Ce.includes(X))}))==null?void 0:Y.value)===ie}))}):S=S==null?void 0:S.filter(me=>{var Be;return((Be=me==null?void 0:me.find(F=>{var ie;return(F==null?void 0:F.key)===X||((ie=F==null?void 0:F.key)==null?void 0:ie.includes(X))}))==null?void 0:Be.value)!==$[X]}))}),(S==null?void 0:S.length)===0?j.contents=[]:j.contents=S==null?void 0:S.map($=>{let V={};return $==null||$.forEach(le=>{V[le==null?void 0:le.key]=le==null?void 0:le.value}),V})}return j})}return a==null?void 0:a.contents},vp=a=>a==null?void 0:a.contents,mp=a=>a==null?void 0:a.contents,yp=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=kt(c.contents,s)),c))}return a==null?void 0:a.contents},gp=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("(",mr))==null?void 0:n.split(mr))==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=te.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",g=(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}));g.push({key:"bottomButton",contents:u})}return g}return a==null?void 0:a.contents},bp=a=>a==null?void 0:a.contents,kp=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},xp=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},wp=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},_p=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},Sp=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((g,u)=>{const C=u+1;let M=0,k=0;for(let I=0;I<h.length;I++){if(k+=h[I],C<=k){M=I;break}I===h.length-1&&(M=h.length-1)}const W=h[M]||h[h.length-1]||1;return g.width=W,g})}return d}):a==null?void 0:a.contents}return a==null?void 0:a.contents},Ep=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},Cp=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},Dp=async a=>{var r,i,s,h,c,d,m,g,u,C,M,k,W,I,j,L,E;const l=A.useUnit(A.pinia),{chooseTitle:n}=A.storeToRefs(l);if((a==null?void 0:a.filter)==="true"){let x=await an(((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;(g=(m=x==null?void 0:x[0])==null?void 0:m.compData)!=null&&g.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 le;return(le=V==null?void 0:V.compData)==null?void 0:le.find(X=>(X==null?void 0:X.key)==="header")}))==null?void 0:C[0])==null?void 0:M.compData;let b=(k=x==null?void 0:x.find(V=>(V==null?void 0:V.key)==="header"))==null?void 0:k.contents;Array.isArray(b==null?void 0:b[0])&&(b=b==null?void 0:b[0]),b=((W=b==null?void 0:b.find(V=>V==null?void 0:V.isMainKey))==null?void 0:W.prop)??((I=b==null?void 0:b[0])==null?void 0:I.prop);let S=(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[b])===w);return(E=a==null?void 0:a.contents)==null?void 0:E.map(V=>{var le;return(V==null?void 0:V.key)==="formContent"&&(V.contents=(le=V.contents)==null?void 0:le.map(X=>(X.value=S==null?void 0:S[X==null?void 0:X.prop],X))),V})}return a==null?void 0:a.contents},Tp=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("{",mr))==null?void 0:n.split(mr))==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=te.calculatorAndToOr(h),d=c==null?void 0:c[0],m=(s=a==null?void 0:a.extra)==null?void 0:s.row,g=[];for(let u in d)(d==null?void 0:d[u])===(m==null?void 0:m[u])?g.push(!0):g.push(!1);return g!=null&&g.every(u=>u===!0)?a==null?void 0:a.contents:[]}else return a==null?void 0:a.contents},Bp=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},Np=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},Ap=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},zp=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=te.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},Mp=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},sc={onNumSlice:dp,onRandomContents:pp,onConditionContents:hp,onFatherPaceContents:vp,onPaceContents:mp,onMainTagContents:yp,onButtonContents:gp,onPamButtonContents:bp,onRowButtonContents:kp,onRelated:Dp,onRowNum:Sp,onFixRow:Ep,onReqItem:Cp,onBottomButtonContents:xp,onConditionContent:Tp,onTabs:Bp,onSinChoice:Np,onTextSize:cp,onTextRGBA:up,onPosition:tp,onSize:sp,onShowType:Ap,onStepName:zp,onStep:Mp,onInterfaceTypeContents:fp,onBackGround:op,onMaxColumn:_p,onEditRead:wp,onShowHide:ip},Ip=async(a,l,n="")=>{var h,c,d,m,g,u,C,M,k,W,I,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("(",mr))==null?void 0:d.split(mr))==null?void 0:m[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1));let i=(g=te.analyzeSplitToContent(r,","))==null?void 0:g.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 E,x="";E=(M=(C=(u=i==null?void 0:i[L])==null?void 0:u.replace("=",mr))==null?void 0:C.split(mr))==null?void 0:M[0],x=(I=(W=(k=i==null?void 0:i[L])==null?void 0:k.replace("=",mr))==null?void 0:W.split(mr))==null?void 0:I[1];let w=(j=En==null?void 0:En.find(b=>(b==null?void 0:b.key)===E))==null?void 0:j.value;if(w){const b=sc[w];s=await b({contents:s,filter:x,extra:l,groupName:n})}}return s},Po=async(a,l,n="")=>{var c,d,m,g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le;let r="";if(((c=a==null?void 0:a.find(X=>(X==null?void 0:X.key)==="filter"))==null?void 0:c.contents)!==""&&(r=(d=a==null?void 0:a.find(X=>(X==null?void 0:X.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=(g=(m=r==null?void 0:r.replace("(",mr))==null?void 0:m.split(mr))==null?void 0:g[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1));let i=(u=te.analyzeSplitToContent(r,","))==null?void 0:u.map(X=>((X==null?void 0:X[(X==null?void 0:X.length)-1])===","&&(X=X==null?void 0:X.slice(0,(X==null?void 0:X.length)-1)),X!=null&&X.includes("(")||(X=X==null?void 0:X.replaceAll(":","=")),X)),s=a,h=new Map;i==null||i.forEach(X=>{var Be,F,ie;let me=(Be=X==null?void 0:X.split("="))==null?void 0:Be[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 ce=(ie=(F=X==null?void 0:X.replace("{",mr))==null?void 0:F.split(mr))==null?void 0:ie[1];ce=Y+","+ce,h.set(me,ce)}else me==="@Button"&&h.get(me)?h.set(X,X):h.set(me,X)}),i=Array.from(h.values()),i=i==null?void 0:i.sort((X,me)=>{var Be,F;return((Be=En==null?void 0:En.find(ie=>me==null?void 0:me.includes(ie==null?void 0:ie.key)))==null?void 0:Be.order)-((F=En==null?void 0:En.find(ie=>X==null?void 0:X.includes(ie==null?void 0:ie.key)))==null?void 0:F.order)});for(let X in i){let me,Be="";(C=i==null?void 0:i[X])!=null&&C.includes("(")&&((M=i==null?void 0:i[X])!=null&&M.includes("@If"))?(me=(I=(W=(k=i==null?void 0:i[X])==null?void 0:k.replace("(",mr))==null?void 0:W.split(mr))==null?void 0:I[0],Be="("+((E=(L=(j=i==null?void 0:i[X])==null?void 0:j.replace("(",mr))==null?void 0:L.split(mr))==null?void 0:E[1])):(me=(b=(w=(x=i==null?void 0:i[X])==null?void 0:x.replace("=",mr))==null?void 0:w.split(mr))==null?void 0:b[0],Be=(V=($=(S=i==null?void 0:i[X])==null?void 0:S.replace("=",mr))==null?void 0:$.split(mr))==null?void 0:V[1]);let F=(le=En==null?void 0:En.find(ie=>(ie==null?void 0:ie.key)===me))==null?void 0:le.value;if(F){const ie=sc[F];s=await ie({contents:s,filter:Be,extra:l,groupName:n})}}return s},cc=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]]},uc=(a,l)=>{var W,I,j,L,E;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=((I=l==null?void 0:l.position)==null?void 0:I[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),g=((E=l==null?void 0:l.size)==null?void 0:E[1])??(s==null?void 0:s._sizeEnd)??(h==null?void 0:h._sizeEnd);(m===void 0||Number.isNaN(m))&&(m=0),(g===void 0||Number.isNaN(g))&&(g=1),m=Math.max(0,Math.min(1,m)),g=Math.max(0,Math.min(1,g)),g<=m&&(m=0,g=1);const u=g-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(b=>({...b,width:C,_positionStartRow:c,_positionRowSpan:d,_sizeStart:m,_sizeEnd:g}))}});const k={_positionStartRow:c,_positionRowSpan:d,_sizeStart:m,_sizeEnd:g};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 Op=A.useUnit(A.pinia),{selectTitle:Lp}=A.storeToRefs(Op);let Rp=[{label:"新增",prop:"新增"},{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],$p=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"},{label:"复制新增",prop:"复制新增"},{label:"删除",prop:"删除"}],Vp=[{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],Pp=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"}];const ds=async(a,l,n=!0)=>{let r=[],i=a==null?void 0:a.map(async s=>{var u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae,oe,Xe,Ze,Pa,Sa,Xa,Ve,Re,We,Ae,Me,cl,wl,Cl,Pl,Sl,Gl,aa,Ha,ya,rl,Aa,ol,al;let h=(k=(M=(C=(u=s==null?void 0:s.contents)==null?void 0:u.find(ke=>{var Ia;return(Ia=ke==null?void 0:ke.key)==null?void 0:Ia.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(ke=>ke==null?void 0:ke.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:(I=s==null?void 0:s.filter)==null?void 0:I.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:(E=s==null?void 0:s.filter)==null?void 0:E.sonSyncs,nameContents:(x=A.cloneDeep(c))==null?void 0:x.reverse()};for(let ke in c)parseInt(ke)>=1&&(m[`name${parseInt(ke)-1}`]=c[ke]);let g=Array.isArray((w=s==null?void 0:s.filter)==null?void 0:w.menuFilter)?(b=s==null?void 0:s.filter)==null?void 0:b.menuFilter:[];if(((S=g==null?void 0:g.filter(ke=>ke==null?void 0:ke.includes("@If")))==null?void 0:S.length)>0){let ke=g==null?void 0:g.filter(Ke=>Ke==null?void 0:Ke.includes("@If"));ke=ke==null?void 0:ke[0],ke=(V=($=ke==null?void 0:ke.replace("(",yo))==null?void 0:$.split(yo))==null?void 0:V[1],ke=ke==null?void 0:ke.slice(0,(ke==null?void 0:ke.length)-1),ke!=null&&ke.includes("*")&&(ke=(X=(le=ke==null?void 0:ke.replace("{",yo))==null?void 0:le.split(yo))==null?void 0:X[1],ke=ke==null?void 0:ke.replace("}","")),ke=te.calculatorAndToOr(ke);let Ia=(l==null?void 0:l.originPath)??"";(Ia==null?void 0:Ia[(Ia==null?void 0:Ia.length)-1])==="/"&&(Ia=Ia==null?void 0:Ia.slice(0,(Ia==null?void 0:Ia.length)-1));let $a=await an(Ia,!1),Z=(me=$a==null?void 0:$a.filter(Ke=>(Ke==null?void 0:Ke.comp)==="Table"))==null?void 0:me[0];Z=(F=(Be=Z==null?void 0:Z.compData)==null?void 0:Be.find(Ke=>(Ke==null?void 0:Ke.key)==="tableContents"))==null?void 0:F.contents;let la=(Y=(ie=Lp.value)==null?void 0:ie.find(Ke=>(Ke==null?void 0:Ke.condition)==="child"))==null?void 0:Y.value;Z=(ce=Z==null?void 0:Z.map(Ke=>{for(let Ua in Ke)if((Ke==null?void 0:Ke[Ua])===la)return Ke}))==null?void 0:ce.filter(Ke=>Ke),Z=Z==null?void 0:Z[0],ke=ke==null?void 0:ke[0];let ba=[];for(let Ke in ke){let Ua="";ja.isObject(Z)&&(Ua=(Fe=(Ce=Object.keys(Z))==null?void 0:Ce.filter(ga=>ga==null?void 0:ga.includes("."+Ke)))==null?void 0:Fe[0]),Ua!==""&&(Z!=null&&Z[Ua])&&(ke==null?void 0:ke[Ke])===(Z==null?void 0:Z[Ua])||Z!=null&&Z[Ke]&&(ke==null?void 0:ke[Ke])===(Z==null?void 0:Z[Ke])?ba.push(!0):ba.push(!1)}if(ba!=null&&ba.some(Ke=>Ke===!1)&&((N=l==null?void 0:l.originPath)==null?void 0:N[((fe=l==null?void 0:l.originPath)==null?void 0:fe.length)-1])!=="/")return}if(h==="Table"||h==="Method"){!n&&((se=m==null?void 0:m.fatherSyncContents)==null?void 0:se.length)>0;let ke=((U=s==null?void 0:s.contents)==null?void 0:U.find(Le=>{var ia;return(ia=Le==null?void 0:Le.key)==null?void 0:ia.includes("content")}))||[],Ia=[];m.comp="Table",ke.value=(_e=ke==null?void 0:ke.value)==null?void 0:_e.sort((Le,ia)=>parseInt(Le==null?void 0:Le.id)-parseInt(ia==null?void 0:ia.id)),ke.value=(Ie=ke==null?void 0:ke.value)==null?void 0:Ie.map(Le=>{let ia={};for(let va in Le)JSON.stringify(Le==null?void 0:Le[va])==="{}"?ia[va]="":ia[va]=Le==null?void 0:Le[va];return ia}),Ia.push({key:"tableContents",contents:ke==null?void 0:ke.value});let $a=(ca=(ee=(Ca=(na=(je=s==null?void 0:s.contents)==null?void 0:je.find(Le=>{var ia;return(ia=Le==null?void 0:Le.key)==null?void 0:ia.includes("struct")}))==null?void 0:na.value)==null?void 0:Ca[0])==null?void 0:ee.结构)==null?void 0:ca.contents;Array.isArray($a==null?void 0:$a[0])?$a[0]=(de=$a==null?void 0:$a[0])==null?void 0:de.filter(Le=>(Le==null?void 0:Le.prop)!=="sort"&&(Le==null?void 0:Le.prop)!=="relatedId"):$a=$a==null?void 0:$a.filter(Le=>(Le==null?void 0:Le.prop)!=="sort"&&(Le==null?void 0:Le.prop)!=="relatedId"),Ia.push({key:"header",contents:$a}),Ia.push({key:"filter",contents:(Ge=(De=(ue=(we=(pa=s==null?void 0:s.contents)==null?void 0:pa.find(Le=>{var ia;return(ia=Le==null?void 0:Le.key)==null?void 0:ia.includes("struct")}))==null?void 0:we.value)==null?void 0:ue[0])==null?void 0:De.引用)==null?void 0:Ge.contents});let Z=Rp,la=A.cloneDeep($p);h==="Method"&&la.push({label:"生成方法",prop:"生成方法"}),!Array.isArray($a==null?void 0:$a[0])&&((ua=$a==null?void 0:$a[0])==null?void 0:ua.prop)==="disabled"&&(Z=Vp,la=Pp);const ba=["推力","真空","压力","温度","流量"],Ke=m.name;Ke&&ba.includes(Ke)&&(Z=[...Z],Z.push({label:"导出paraform",prop:"导出paraform",type:"methodButton"}));let Ua=[];if(!Array.isArray($a==null?void 0:$a[0])&&($a!=null&&$a.some(Le=>{var ia;return(Le==null?void 0:Le.calculatorFilter)&&((ia=Le==null?void 0:Le.calculatorFilter)==null?void 0:ia.includes("Manual"))}))){let Le=(Ja=$a==null?void 0:$a.map(ia=>ia==null?void 0:ia.calculatorFilter))==null?void 0:Ja.filter(ia=>ia&&(ia==null?void 0:ia.includes("Manual")));Le==null||Le.forEach(ia=>{var ll;let va=te.analyzeSplitToContent(ia,",");if(va=va==null?void 0:va.map(Pe=>((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)),va!=null&&va.find(Pe=>(Pe==null?void 0:Pe.includes("Extent"))&&(Pe==null?void 0:Pe.includes("Row")))&&(va!=null&&va.find(Pe=>(Pe==null?void 0:Pe.includes("Button"))&&(Pe==null?void 0:Pe.includes(","))))){let Pe=va==null?void 0:va.find(Dl=>Dl==null?void 0:Dl.includes("@FunctionButton"));Pe=(ll=Pe==null?void 0:Pe.split("="))==null?void 0:ll[1],Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1),Pe=Pe==null?void 0:Pe.split(","),Pe=Pe==null?void 0:Pe[(Pe==null?void 0:Pe.length)-1],Ua.push(Pe)}}),Ua=[...new Set(Ua)],Ua=Ua==null?void 0:Ua.map(ia=>({label:ia,prop:ia,type:"methodButton"}))}else if(Array.isArray($a==null?void 0:$a[0])&&((R=te.getColumnChild($a==null?void 0:$a[0]))!=null&&R.some(Le=>{var ia;return(Le==null?void 0:Le.calculatorFilter)&&((ia=Le==null?void 0:Le.calculatorFilter)==null?void 0:ia.includes("Manual"))}))){let Le=(J=(H=te.getColumnChild($a==null?void 0:$a[0]))==null?void 0:H.map(ia=>ia==null?void 0:ia.calculatorFilter))==null?void 0:J.filter(ia=>ia&&(ia==null?void 0:ia.includes("Manual")));Le==null||Le.forEach(ia=>{var ll;let va=te.analyzeSplitToContent(ia,",");if(va=va==null?void 0:va.map(Pe=>((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)),va!=null&&va.find(Pe=>(Pe==null?void 0:Pe.includes("Extent"))&&(Pe==null?void 0:Pe.includes("Row")))&&(va!=null&&va.find(Pe=>(Pe==null?void 0:Pe.includes("Button"))&&(Pe==null?void 0:Pe.includes(","))))){let Pe=va==null?void 0:va.find(Dl=>Dl==null?void 0:Dl.includes("@FunctionButton"));Pe=(ll=Pe==null?void 0:Pe.split("="))==null?void 0:ll[1],Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1),Pe=Pe==null?void 0:Pe.split(","),Pe=Pe==null?void 0:Pe[(Pe==null?void 0:Pe.length)-1],Ua.push(Pe)}}),Ua=[...new Set(Ua)],Ua=Ua==null?void 0:Ua.map(ia=>({label:ia,prop:ia,type:"methodButton"}))}if(Ia.push({key:"extraButton",contents:Z}),Ia.push({key:"rowButton",contents:[...la,...Ua]}),m.compData=await Po(Ia,l,m==null?void 0:m.nameContents),(he=m.compData)!=null&&he.find(Le=>(Le==null?void 0:Le.key)==="tab")&&(m.tab=(ha=(pe=m.compData)==null?void 0:pe.find(Le=>(Le==null?void 0:Le.key)==="tab"))==null?void 0:ha.contents),(ta=m.compData)!=null&&ta.find(Le=>(Le==null?void 0:Le.key)==="step")&&(m.step=(_a=(He=m.compData)==null?void 0:He.find(Le=>(Le==null?void 0:Le.key)==="step"))==null?void 0:_a.contents),(ze=m.compData)!=null&&ze.find(Le=>(Le==null?void 0:Le.key)==="choice")&&(m.choice=(Oa=(ma=m.compData)==null?void 0:ma.find(Le=>(Le==null?void 0:Le.key)==="choice"))==null?void 0:Oa.contents),(Ma=m.compData)!=null&&Ma.find(Le=>(Le==null?void 0:Le.key)==="newType")){let Le=(Ba=(fa=m.compData)==null?void 0:fa.find(ia=>(ia==null?void 0:ia.key)==="newType"))==null?void 0:Ba.contents;m.comp=Le,m.compData=(Te=m.compData)==null?void 0:Te.filter(ia=>(ia==null?void 0:ia.key)!=="newType")}let ga="",tl=(ye=m==null?void 0:m.compData)==null?void 0:ye.filter(Le=>(Le==null?void 0:Le.key)==="fixType");(tl==null?void 0:tl.length)>0&&n&&(ga=(Ne=tl==null?void 0:tl[0])==null?void 0:Ne.contents,m.comp=ga)}else if(h==="Form"){let ke=[],Ia=(Xe=(oe=(ae=s==null?void 0:s.contents)==null?void 0:ae.find(Ke=>{var Ua;return(Ua=Ke==null?void 0:Ke.key)==null?void 0:Ua.includes("content")}))==null?void 0:oe.value)==null?void 0:Xe[0],$a=[],Z=Array.isArray((Ze=s==null?void 0:s.filter)==null?void 0:Ze.menuFilter)?(Pa=s==null?void 0:s.filter)==null?void 0:Pa.menuFilter:[];Z==null||Z.forEach(Ke=>{if(Ke!=null&&Ke.includes("@Param(Hide=Yes, prop=")||Ke!=null&&Ke.includes("(Hide=Yes, prop=")){const Ua=Ke==null?void 0:Ke.match(/prop=([^,)]+)/);Ua!=null&&Ua[1]&&$a.push(Ua==null?void 0:Ua[1])}});let la=(We=(Re=(Ve=(Xa=(Sa=s==null?void 0:s.contents)==null?void 0:Sa.find(Ke=>{var Ua;return(Ua=Ke==null?void 0:Ke.key)==null?void 0:Ua.includes("struct")}))==null?void 0:Xa.value)==null?void 0:Ve[0])==null?void 0:Re.结构)==null?void 0:We.contents,ba=(Ae=la==null?void 0:la.map(Ke=>(Ke.value=Ia==null?void 0:Ia[Ke==null?void 0:Ke.prop],Ke)))==null?void 0:Ae.filter(Ke=>(Ke==null?void 0:Ke.prop)!=="sort"&&(Ke==null?void 0:Ke.prop)!=="relatedId");ba=ba==null?void 0:ba.map(Ke=>($a!=null&&$a.includes(Ke==null?void 0:Ke.prop)&&(Ke.isHideInForm=!0),Ke)),ke.push({key:"filter",contents:(Pl=(Cl=(wl=(cl=(Me=s==null?void 0:s.contents)==null?void 0:Me.find(Ke=>{var Ua;return(Ua=Ke==null?void 0:Ke.key)==null?void 0:Ua.includes("struct")}))==null?void 0:cl.value)==null?void 0:wl[0])==null?void 0:Cl.引用)==null?void 0:Pl.contents}),ke.push({key:"formContent",contents:ba}),ke.push({key:"paramHideProps",contents:$a}),m.compData=await Ip(ke,l,m==null?void 0:m.nameContents),(Sl=m.compData)!=null&&Sl.find(Ke=>(Ke==null?void 0:Ke.key)==="tab")&&(m.tab=(aa=(Gl=m.compData)==null?void 0:Gl.find(Ke=>(Ke==null?void 0:Ke.key)==="tab"))==null?void 0:aa.contents),(Ha=m.compData)!=null&&Ha.find(Ke=>(Ke==null?void 0:Ke.key)==="step")&&(m.step=(rl=(ya=m.compData)==null?void 0:ya.find(Ke=>(Ke==null?void 0:Ke.key)==="step"))==null?void 0:rl.contents),(Aa=m.compData)!=null&&Aa.find(Ke=>(Ke==null?void 0:Ke.key)==="choice")&&(m.choice=(al=(ol=m.compData)==null?void 0:ol.find(Ke=>(Ke==null?void 0:Ke.key)==="choice"))==null?void 0:al.contents)}return m});return r=await Promise.all(i),r},Fp=A.useLoginState(A.pinia),{loginUserInfo:Ei}=A.storeToRefs(Fp),jp=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 dc(c,d,r,l,r,n),c});return s=await Promise.all(s),s},xt=async(a,l,n="Manual",r=[])=>{var d;let i=a,s;Array.isArray(l==null?void 0:l[0])?s=te.getColumnChild(l==null?void 0:l[0]):s=l;let h=(d=s==null?void 0:s.filter(m=>{var g;return(m==null?void 0:m.calculatorFilter)&&((g=m==null?void 0:m.calculatorFilter)==null?void 0:g.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 dc(m,h,s,n,i,r),m));return c=await Promise.all(c),c},Hp=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=te.getValueToObjectValue(l,te.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?Il.isEqual(d.toString(),s.toString()):void 0:d}else{let d=(c=i==null?void 0:i.find(g=>(g==null?void 0:g.label)===h))==null?void 0:c.prop,m=(l==null?void 0:l[d])??0;s=s?m?Il.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))}`},Up=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=te.getValueToObjectValue(l,te.getColumnContents(i))),n==null||n.forEach(d=>{var m,g,u,C,M,k,W,I,j;if(l!=null&&l[d]){if(s==="Row")if(!((g=((m=l==null?void 0:l[d])==null?void 0:m.toString())??"")!=null&&g.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(E=>(E==null?void 0:E.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(":"))&&!((I=c==null?void 0:c.toString())!=null&&I.includes(":"))){let E=+((l==null?void 0:l[L])??0);c=c+E}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 g=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,...g]}),c=d.reduce((m,g)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(g)||(C=+g),u+C},0)}return l[r]=c,l},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=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=te.getValueToObjectValue(l,te.getColumnContents(i))),n==null||n.forEach(d=>{var m,g,u,C,M,k,W;if(l!=null&&l[d]){if(s==="Row")if(!((g=(m=l==null?void 0:l[d])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((u=c==null?void 0:c.toString())!=null&&u.includes(":"))){let I=+(l==null?void 0:l[d]);c=c===0?c+I:c-I}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 I=(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[I])?"":(M=l==null?void 0:l[I])==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[I])??0);c=c===0?c+j:c-j}else c=c===0?Br(c.toString())+Br(((l==null?void 0:l[I])??0).toString()):Br(c.toString())-Br(((l==null?void 0:l[I])??0).toString()),c=Kn(c)}}),s==="Column"){let d=[];n==null||n.forEach(m=>{let g=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,...g]}),c=d.reduce((m,g)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(g)||(C=+g),u-C},0)}return l[r]=c,l},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=te.getValueToObjectValue(l,te.getColumnContents(i))),n==null||n.forEach(d=>{var m,g,u,C,M,k,W;if(l!=null&&l[d]){if(s==="Row")if(!((g=(m=l==null?void 0:l[d])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((u=c==null?void 0:c.toString())!=null&&u.includes(":"))){let I=+(l==null?void 0:l[d]);c=c===0?c+I:c*I}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 I=(C=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===d))==null?void 0:C.prop;if(!(l!=null&&l[I]))c=void 0;else if(!((k=Number.isNaN(l==null?void 0:l[I])?"":(M=l==null?void 0:l[I])==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[I])??0);c=c===0?c+j:c*j}else c=c===0?Br(c.toString())+Br(((l==null?void 0:l[I])??0).toString()):Br(c.toString())*Br(((l==null?void 0:l[I])??0).toString()),c=Kn(c)}}),s==="Column"){let d=[];n==null||n.forEach(m=>{let g=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,...g]}),c=d.reduce((m,g)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(g)||(C=+g),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=te.getValueToObjectValue(l,te.getColumnContents(i))),n==null||n.forEach(d=>{var m,g,u,C,M,k,W;if(l!=null&&l[d]){if(s==="Row")if(!((g=(m=l==null?void 0:l[d])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((u=c==null?void 0:c.toString())!=null&&u.includes(":"))){let I=+(l==null?void 0:l[d]);c=c===0?c+I:c/I}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 I=(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[I])?"":(M=l==null?void 0:l[I])==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[I])??0);c=c===0?c+j:c/j}else c=c===0?Br(c.toString())+Br(((l==null?void 0:l[I])??0).toString()):Br(c.toString())/Br(((l==null?void 0:l[I])??0).toString()),c=Kn(c)}}),s==="Column"){let d=[];n==null||n.forEach(m=>{let g=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,...g]}),c=d.reduce((m,g)=>{let u=0;Number.isNaN(m)||(u=+m);let C=0;return Number.isNaN(g)||(C=+g),u/C},0)}return l[r]=c.toFixed(2),l},Gp=async a=>{var s,h,c,d,m,g,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 I=(d=(c=l==null?void 0:l.split("*"))==null?void 0:c[0])==null?void 0:d.replaceAll(":","/"),j=await an(I,!1),L=(m=l==null?void 0:l.split("*"))==null?void 0:m[1];if(j=(g=j==null?void 0:j.filter(E=>(E==null?void 0:E.name)===L))==null?void 0:g[0],n!==""){let E=j.compData;E=E==null?void 0:E.filter(x=>(x==null?void 0:x.key)!=="filter"),E.push({key:"filter",contents:"("+n+")"}),E=await Po(E,{}),r=(C=(u=E==null?void 0:E.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(E=>(E==null?void 0:E.key)==="tableContents"))==null?void 0:k.contents)==null?void 0:W.length}return i.value=r,i},go={Sum:Up,Substract:qp,Multiple:Wp,Divide:Kp,Compare:Hp,VecDimCount:Gp},dc=async(a,l,n,r="Auto",i,s=[])=>{var g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me,Be,F;let h=a,c=[],d=await A.getPageDataApi({platId:parseInt((g=Ei==null?void 0:Ei.value)==null?void 0:g.plat_id),pageName:"menu"});d=(M=(C=(u=d==null?void 0:d.data)==null?void 0:u.result)==null?void 0:C.filter(ie=>(ie==null?void 0:ie.property_name)===""))==null?void 0:M[0];let m=[];if(d!=null&&d.object_name){d=d==null?void 0:d.object_name;let ie=await A.getPageDataApi({platId:parseInt((k=Ei==null?void 0:Ei.value)==null?void 0:k.plat_id),pageName:d});ie=(E=(L=(j=(I=(W=ie==null?void 0:ie.data)==null?void 0:W.result)==null?void 0:I[0])==null?void 0:j.contents)==null?void 0:L.find(Y=>{var ce;return(ce=Y==null?void 0:Y.key)==null?void 0:ce.includes("content")}))==null?void 0:E.value,c=(x=ie==null?void 0:ie.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 ie in l){let Y=(w=l==null?void 0:l[ie])==null?void 0:w.functionName;const ce=go==null?void 0:go[Y];let Ce=(b=l==null?void 0:l[ie])==null?void 0:b.methods;if(Ce=te.analyzeSplitToContent(Ce,","),(S=Ce==null?void 0:Ce.find(Fe=>Fe==null?void 0:Fe.includes("@FunctionType")))!=null&&S.includes(r)||r==="Auto"||(Ce==null?void 0:Ce.length)===0){let Fe=((le=(V=($=Ce==null?void 0:Ce.find(fe=>fe==null?void 0:fe.includes("@FunctionExtent")))==null?void 0:$.replace(":","="))==null?void 0:V.split("="))==null?void 0:le[1])??[];if(await new Function("return ")(),(m==null?void 0:m.length)>0&&m.find(fe=>fe===Y)){let fe="";try{let se=(X=l==null?void 0:l[ie])==null?void 0:X.functionRelatedWords,U=(s==null?void 0:s.length)>0?s==null?void 0:s.map(Ie=>{var je;return Ie==null?void 0:Ie[(je=l==null?void 0:l[ie])==null?void 0:je.prop]}):["0"];U=U==null?void 0:U.map(Ie=>Ie==null?void 0:Ie.slice((Ie==null?void 0:Ie.length)-5,Ie==null?void 0:Ie.length)),U=U==null?void 0:U.map(Ie=>te.isNumber(parseInt(Ie))&&parseInt(Ie)?parseInt(Ie):0);let _e=Math.max(...U);se=se==null?void 0:se.map(Ie=>{if(Ie!=null&&Ie.includes("'"))return Ie==null?void 0:Ie.replaceAll("'","");if(Ie!=null&&Ie.includes("@"))return _e+1;{let je=Object.keys(h);return Ie=(h==null?void 0:h[Ie])??(h==null?void 0:h[je==null?void 0:je.find(na=>na==null?void 0:na.includes("."+Ie))]),Ie}}),fe=ce(...se)}catch(se){ja.ElMessage.warning("关联数据出现错误,"+se.message)}let N=(me=l==null?void 0:l[ie])==null?void 0:me.prop;h[N]=fe}else h=await ce({contents:h,valueString:(Be=l==null?void 0:l[ie])==null?void 0:Be.functionRelatedWords,prop:(F=l==null?void 0:l[ie])==null?void 0:F.prop,headers:n,typeString:Fe,allContents:i})}}return h},Yp=A.useLoginState(A.pinia),{loginUserInfo:fn}=A.storeToRefs(Yp),Jp=A.useMenuState(A.pinia),{activeMenuPath:ps,currentMenuPath:bo}=A.storeToRefs(Jp),pc=A.useUnit(A.pinia);let fs="$R";const{selectTitle:Ti}=A.storeToRefs(pc),fc=async(a,l)=>{var h,c,d,m,g,u,C,M,k,W,I,j,L;let n=ps.value,r="",i=((h=Ti==null?void 0:Ti.value)==null?void 0:h.find(E=>(E==null?void 0:E.condition)==="child"&&!(E!=null&&E.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 E=r;(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));let x=await an(E,!1);x=(m=x==null?void 0:x[0])==null?void 0:m.compData;let w=(g=x==null?void 0:x.find(S=>(S==null?void 0:S.key)==="header"))==null?void 0:g.contents;w=((u=w==null?void 0:w.find(S=>S==null?void 0:S.isMainKey))==null?void 0:u.prop)??((C=w==null?void 0:w[0])==null?void 0:C.prop);let b=(k=(M=x==null?void 0:x.find(S=>(S==null?void 0:S.key)==="tableContents"))==null?void 0:M.contents)==null?void 0:k.map(S=>({label:S==null?void 0:S[w],value:S==null?void 0:S[w]}));s=(W=r==null?void 0:r.split("/"))==null?void 0:W.map(S=>(S===""?i?(i.isShow=!0,S=i):S={value:S,condition:"child",options:b,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}:S={condition:"parent",value:S.trim(),isShow:!0},S))}if(n!==""){let E=(I=n==null?void 0:n.split("/"))==null?void 0:I.map(x=>(x={condition:"normal",value:x.trim(),isShow:!0},x));((j=E==null?void 0:E[0])==null?void 0:j.value)===((L=s==null?void 0:s[0])==null?void 0:L.value)&&(E=E==null?void 0:E.filter((x,w)=>w!==0)),s=[...s??[],...E??[]]}r===""&&i&&((i==null?void 0:i.parentContent)!==ps.value&&(i.isShow=!1),(i==null?void 0:i.value)!==""&&s.push(i)),pc.setSelectTitle(s)},Xp=async a=>{var s,h,c,d,m,g,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=(g=(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:g.contents;r=(M=(C=(u=r==null?void 0:r.replace("(",fs))==null?void 0:u.split(fs))==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(I=>{var j,L,E;return(I==null?void 0:I.key)==="header"&&(Array.isArray((j=I.contents)==null?void 0:j[0])?I.contents[0]=(E=I.contents[0])==null?void 0:E.map((x,w)=>{var b;return w===0&&(x.isExistChild=!0,((b=bo.value)!=null&&b.includes(r)||r)&&(x.fatherPath=r)),x}):I.contents=(L=I.contents)==null?void 0:L.map((x,w)=>{var b;return w===0&&(x.isExistChild=!0,((b=bo.value)!=null&&b.includes(r)||r)&&(x.fatherPath=r)),x})),I})),k})),a},an=async(a,l,n={})=>{var h,c,d,m,g,u,C,M,k,W,I,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(((g=(m=L==null?void 0:L.data)==null?void 0:m.result)==null?void 0:g.length)>0){let E=await ds((u=L==null?void 0:L.data)==null?void 0:u.result,n,!1);E=E==null?void 0:E.map(async b=>{var V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja;let S=[],$=(V=Object.keys(b))==null?void 0:V.filter(R=>(R==null?void 0:R.includes("name"))&&R!=="nameContents");for(let R in b)$!=null&&$.find(H=>H===R)&&S.push(b==null?void 0:b[R]);if(S=S.reverse(),(b==null?void 0:b.comp)==="Table"){let R=(me=(X=(le=b==null?void 0:b.compData)==null?void 0:le.find(J=>(J==null?void 0:J.key)==="tableContents"))==null?void 0:X.contents)==null?void 0:me.map(J=>{let he={};for(let pe in J)pe!=="id"&&pe!=="create_time"&&pe!=="update_time"&&pe!=="sort"&&pe!=="create_user_id"&&pe!=="update_user_id"&&pe!=="department_id"&&pe!=="relatedId"&&(he[pe]=J==null?void 0:J[pe]);return J=Object.values(he),J}),H=(F=(Be=b==null?void 0:b.compData)==null?void 0:Be.find(J=>(J==null?void 0:J.key)==="header"))==null?void 0:F.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"}),(ie=H[0])!=null&&ie.find(J=>(J==null?void 0:J.prop)==="disabled")&&(H[0]=(Y=H[0])==null?void 0:Y.filter(J=>(J==null?void 0:J.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(J=>(J==null?void 0:J.prop)==="disabled")&&(H=H==null?void 0:H.filter(J=>(J==null?void 0:J.prop)!=="disabled"),H.unshift({label:"",prop:"disabled",sortable:!1}))),H!=null&&H.some(J=>{var he;return(J==null?void 0:J.calculatorFilter)&&((he=J==null?void 0:J.calculatorFilter)==null?void 0:he.includes("Auto"))})&&(R=await xt(R,H,"Auto"),R=R==null?void 0:R.map(J=>Object.values(J))),b!=null&&b.fatherSyncContents){Array.isArray((ce=b==null?void 0:b.fatherSyncContents)==null?void 0:ce[0])&&(b.fatherSyncContents=(Ce=b==null?void 0:b.fatherSyncContents)==null?void 0:Ce[0]);let J=(Fe=Ti.value)==null?void 0:Fe.find(he=>(he==null?void 0:he.condition)==="child");b.fatherSyncContents=(fe=b==null?void 0:b.fatherSyncContents)==null?void 0:fe.map(he=>{var pe,ha,ta,He,_a,ze;return((ha=he==null?void 0:he.menus)==null?void 0:ha[((pe=he==null?void 0:he.menus)==null?void 0:pe.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"!==(he==null?void 0:he.menus)?he.menus=(he==null?void 0:he.menus)+(J==null?void 0:J.value):((He=he==null?void 0:he.menus)==null?void 0:He[((ta=he==null?void 0:he.menus)==null?void 0:ta.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"===(he==null?void 0:he.menus)&&(he.menus=(ze=he.menus)==null?void 0:ze.slice(0,((_a=he.menus)==null?void 0:_a.length)-1)),he})}if(b!=null&&b.sonSyncContents){Array.isArray((N=b==null?void 0:b.sonSyncContents)==null?void 0:N[0])&&(b.sonSyncContents=(se=b==null?void 0:b.sonSyncContents)==null?void 0:se[0]);let J=(U=Ti.value)==null?void 0:U.find(he=>(he==null?void 0:he.condition)==="child");b.sonSyncContents=(_e=b==null?void 0:b.sonSyncContents)==null?void 0:_e.map(he=>{var pe,ha,ta,He,_a,ze;return((ha=he==null?void 0:he.menus)==null?void 0:ha[((pe=he==null?void 0:he.menus)==null?void 0:pe.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"!==(he==null?void 0:he.menus)?he.menus=(he==null?void 0:he.menus)+(J==null?void 0:J.value):((He=he==null?void 0:he.menus)==null?void 0:He[((ta=he==null?void 0:he.menus)==null?void 0:ta.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"===(he==null?void 0:he.menus)&&(he.menus=(ze=he.menus)==null?void 0:ze.slice(0,((_a=he.menus)==null?void 0:_a.length)-1)),he})}if(b!=null&&b.relatedQuotes){Array.isArray((Ie=b==null?void 0:b.relatedQuotes)==null?void 0:Ie[0])&&(b.relatedQuotes=(je=b==null?void 0:b.relatedQuotes)==null?void 0:je[0]);let J=(na=Ti.value)==null?void 0:na.find(he=>(he==null?void 0:he.condition)==="child");b.relatedQuotes=(Ca=b==null?void 0:b.relatedQuotes)==null?void 0:Ca.map(he=>{var pe,ha,ta,He,_a,ze;return((ha=he==null?void 0:he.menus)==null?void 0:ha[((pe=he==null?void 0:he.menus)==null?void 0:pe.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"!==(he==null?void 0:he.menus)?he.menus=(he==null?void 0:he.menus)+(J==null?void 0:J.value):((He=he==null?void 0:he.menus)==null?void 0:He[((ta=he==null?void 0:he.menus)==null?void 0:ta.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"===(he==null?void 0:he.menus)&&(he.menus=(ze=he.menus)==null?void 0:ze.slice(0,((_a=he.menus)==null?void 0:_a.length)-1)),he})}b={filter:(ca=(ee=b==null?void 0:b.compData)==null?void 0:ee.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:ca.contents,key:b==null?void 0:b.comp,name:S,tableColumns:H,tableContents:R,menuFilter:b==null?void 0:b.menuFilter,fatherSyncContents:b==null?void 0:b.fatherSyncContents,relatedQuotes:b==null?void 0:b.relatedQuotes,sonSyncContents:b==null?void 0:b.sonSyncContents}}else{let R=(we=(pa=(de=b==null?void 0:b.compData)==null?void 0:de.find(J=>(J==null?void 0:J.key)==="formContent"))==null?void 0:pa.contents)==null?void 0:we.map(J=>(J==null?void 0:J.value)??"");R=[R];let H=(Ge=(De=(ue=b==null?void 0:b.compData)==null?void 0:ue.find(J=>(J==null?void 0:J.key)==="formContent"))==null?void 0:De.contents)==null?void 0:Ge.map(J=>(J.value="",J));b={contents:R,filter:(Ja=(ua=b==null?void 0:b.compData)==null?void 0:ua.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:Ja.contents,key:b==null?void 0:b.comp,name:S,value:H,fatherSyncContents:b==null?void 0:b.fatherSyncContents,relatedQuotes:b==null?void 0:b.relatedQuotes,sonSyncContents:b==null?void 0:b.sonSyncContents}}return b.isShow=!1,b}),E=await Promise.all(E);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:E}];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((I=fn==null?void 0:fn.value)==null?void 0:I.plat_id),pageName:a});i=(j=w==null?void 0:w.data)==null?void 0:j.result}}l&&await fc(i,!!(n!=null&&n.originPath));let s=await ds(i,n);return l&&(s=await Xp(s)),s==null?void 0:s.filter(L=>L)},hs=async a=>{var r,i,s,h,c,d,m,g,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 an(l,!1);if(n=(h=n==null?void 0:n.filter(k=>{var W,I;return(k==null?void 0:k.name)===((I=a==null?void 0:a.groups)==null?void 0:I[((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=(g=(m=n==null?void 0:n.compData)==null?void 0:m.find(W=>(W==null?void 0:W.key)==="tableContents"))==null?void 0:g.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 I,j,L,E;return(W==null?void 0:W[a!=null&&a.endChildMenu?k:(I=a==null?void 0:a.words)==null?void 0:I[0]])===(a!=null&&a.relatedWords&&((j=a==null?void 0:a.relatedWords)==null?void 0:j.length)>0?(E=(L=a.value)==null?void 0:L.split(" "))==null?void 0:E[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(I=>(I==null?void 0:I.key)==="formContent"))==null?void 0:M.contents,W={};return k==null||k.forEach(I=>{W[I.prop]=I.value}),W}},Zp={key:0,class:"extra-button-content"},Qp={class:"table-operator-wrap"},ef={key:0,class:"extra-button-filter"},af={key:1,class:"extra-header"},lf=["onClick"],rf={class:"table-op-text"},nf={class:"table-op-text"},of={class:"drop-menu",style:{width:"120px"}},tf=["onClick"],sf={key:0},cf={key:1},uf=["onClick"],df={class:"table-op-text"},pf={key:1,class:"extra-button-content tabs-button-wrapper"},ff={class:"table-operator-wrap"},hf={class:"extra-button-filter"},vf={key:0,class:"extra-header"},mf={class:"table-op-action"},yf={class:"table-op-text"},gf={class:"drop-menu",style:{width:"120px"}},bf={key:0},kf={key:1},xf=["onClick"],wf={class:"table-op-text"},_f={__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 $=(r==null?void 0:r.menuFilter)||[];return Array.isArray($)&&($==null?void 0:$.some(V=>{const le=typeof V=="string"?V:JSON.stringify(V);return le==null?void 0:le.includes("HideGroup=Yes")}))},s=e.ref(""),h=e.ref(!1),c=e.ref(!1),d=e.ref([]),m=e.ref([{label:"清空",background:"#999999"},{label:"确认"}]),g=[{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($,V){return $.map(le=>{const X={...le};return V.forEach(me=>{delete X[me]}),X})}function C($){if(!$||$.t!=="n")return($==null?void 0:$.v)??"";const V=$.v;if($.z){const le=String($.z).toLowerCase(),X=["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 F of X)if(le.includes(F))return M(V);const me=/[ymdhms]/.test(le),Be=/^[0#\.\,\s]+$/.test(le.replace(/[\\\/\-:]/g,""));if(me&&!Be)return M(V)}if(V>=1&&V<=73050){if(V<5e3)return V;if(V>=5e3&&V<4e4){const le=Math.floor((V-25569)/365.25)+1970;return le>=1970&&le<=2e3&&$.z&&/[ymd]/.test(String($.z).toLowerCase())?M(V):V}if(V>=4e4)return M(V)}return V}function M($){if(typeof $!="number")return $;try{const V=new Date(($-25569)*86400*1e3);if(isNaN(V.getTime()))return $;const le=V.getFullYear(),X=String(V.getMonth()+1).padStart(2,"0"),me=String(V.getDate()).padStart(2,"0");return`${le}-${X}-${me}`}catch{return $}}const k=$=>{const V=$.raw;if(!V)return;const le=new FileReader;le.onload=X=>{try{const me=new Uint8Array(X.target.result),Be=te.readSync(me,{type:"array"}),F=Be.SheetNames[0],ie=Be.Sheets[F],ce=te.utils.decode_range(ie["!ref"]).e.c+1,Ce=new Array(ce).fill(""),Fe=[];for(const _e in ie){if(_e[0]==="!")continue;const{r:Ie,c:je}=te.utils.decode_cell(_e),na=ie[_e];let Ca=C(na);if((Ca==null||Ca==="")&&(Ca=""),Ie===0)Ce[je]=Ca;else{if(!Fe[Ie-1]){Fe[Ie-1]={};for(let ee=0;ee<ce;ee++)Fe[Ie-1][`col_${ee}`]=""}Fe[Ie-1][`col_${je}`]=Ca}}for(let _e=0;_e<ce;_e++)Ce[_e]===void 0&&(Ce[_e]="");const fe=[];for(let _e=0;_e<Ce.length;_e++)(!Ce[_e]||Ce[_e].toString().trim()==="")&&fe.push(_e);let N,se;(fe==null?void 0:fe.length)>0?(ja.ElMessage.warning("存在键为空的列,已自动过滤,请检查补充"),N=Ce.filter((_e,Ie)=>!fe.includes(Ie)),se=u(Fe,fe==null?void 0:fe.map(_e=>`col_${_e}`))):(N=Ce,se=Fe);const U=Fe==null?void 0:Fe[0];if(!(U!=null&&U.hasOwnProperty("col_0")))return ja.ElMessage.error("导入的数据列不匹配,请检查是否错位");n("getImportData",N,se)}catch(me){throw ja.ElMessage.error(me.message),new Error(me.message)}},le.readAsArrayBuffer(V)},W=$=>{var le;const V=(le=d.value)==null?void 0:le.reduce((X,me,Be)=>(Be===0?X[me.label]=$:X[me.label]=me==null?void 0:me.value,X),{});n("filter",V,$,!0)},I=($,V={})=>{n("buttonClick",$,"",V)},j=$=>{var V,le;d.value=(le=(V=te.getColumnChild(A.cloneDeep($)))==null?void 0:V.filter(X=>(X==null?void 0:X.label)!==""&&(X==null?void 0:X.label)!=="操作"))==null?void 0:le.map(X=>({label:(X==null?void 0:X.label)??"",value:"",name:(X==null?void 0:X.prop)??"",isFormColHidden:X==null?void 0:X.isTableColHidden,width:2,prop:(X==null?void 0:X.prop)??""}))},L=e.ref(!1),E=$=>{var V;if(($==null?void 0:$.buttonName)==="确认"&&(n("filter",$==null?void 0:$.content),L.value=($==null?void 0:$.content)&&Object.values($==null?void 0:$.content).length>0),($==null?void 0:$.buttonName)==="清空"){const le=A.cloneDeep($==null?void 0:$.content);for(const X in le)le[X]="";d.value=(V=d.value)==null?void 0:V.map(X=>({...X,value:""})),n("filter",le),L.value=!1}h.value=!1},x=()=>{h.value=!h.value,c.value=!0},w=()=>{var V,le;d.value=(V=d.value)==null?void 0:V.map(X=>({...X,value:""}));const $=(le=d.value)==null?void 0:le.reduce((X,me)=>(X[me.label]=me.value,X),{});n("filter",$)},b=e.ref(null);let S;return S=$=>{var me;if(!h.value)return;const V=(me=b==null?void 0:b.value)==null?void 0:me.$el,le=V==null?void 0:V.contains($.target);let X=!1;document.querySelectorAll(".el-popover, .el-popper").forEach(Be=>{Be.contains($.target)&&(X=!0)}),!le&&!X&&(h.value=!1)},e.onMounted(()=>{document.addEventListener("click",S),j(r.columns)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",S)}),e.watch(()=>r.columns,()=>{j(r.columns)},{deep:!0,immediate:!0}),($,V)=>{var ie,Y,ce,Ce,Fe,fe,N,se;const le=e.resolveComponent("el-icon"),X=e.resolveComponent("svg-icon"),me=e.resolveComponent("el-input"),Be=e.resolveComponent("el-upload"),F=e.resolveComponent("el-button");return a.pageLayout==="vertical"?(e.openBlock(),e.createElementBlock("div",Zp,[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",Qp,[r!=null&&r.filterShow?(e.openBlock(),e.createElementBlock("div",ef,[e.createVNode(Pu,{trigger:"contextmenu",ref_key:"popOverRef",ref:b,title:"",width:800,placement:"bottom-start",isVisible:h.value,"onUpdate:isVisible":V[4]||(V[4]=U=>h.value=U)},{reference:e.withCtx(()=>{var U,_e,Ie,je;return[e.createVNode(me,{modelValue:s.value,"onUpdate:modelValue":V[0]||(V[0]=na=>s.value=na),style:{"min-width":"80px"},placeholder:L.value?(Ie=(_e=(U=a.filterValues)==null?void 0:U.filter(na=>na))==null?void 0:_e.slice(0,3))==null?void 0:Ie.join("/"):"搜索","prefix-icon":e.unref(ja.search_default),clearable:"",onInput:W,disabled:((je=d.value)==null?void 0:je.length)===0},{suffix:e.withCtx(()=>{var na,Ca;return[!s.value&&((Ca=(na=a.filterValues)==null?void 0:na.filter(ee=>ee))!=null&&Ca.join("/"))?(e.openBlock(),e.createBlock(le,{key:0,style:{cursor:"pointer"},onClick:w},{default:e.withCtx(()=>[e.createVNode(e.unref(ja.circle_close_default))]),_:1})):e.createCommentVNode("",!0)]}),append:e.withCtx(()=>[e.createElementVNode("span",{title:"条件查询",onClick:e.withModifiers(x,["stop"])},[e.createVNode(X,{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(sl.ssForm,{rowContents:d.value,buttonValue:m.value,isRowFlex:!0,isEnableWrap:!1,isButtonRow:!1,key:m.value,isStartJustify:!1,onOnButtonClick:E},null,8,["rowContents","buttonValue"]))],32)):e.createCommentVNode("",!0)]),_:1},8,["isVisible"])])):e.createCommentVNode("",!0),a.buttons&&((ie=a.buttons)==null?void 0:ie.length)>0?(e.openBlock(),e.createElementBlock("div",af,[(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,_e)=>{var Ie;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:_e},[(U==null?void 0:U.type)==="upload"?(e.openBlock(),e.createBlock(Be,{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 je;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:na=>I(U==null?void 0:U.label)},[e.createVNode(X,{class:"table-op-icon",name:(je=g==null?void 0:g.find(na=>(na==null?void 0:na.label)===(U==null?void 0:U.label)))==null?void 0:je.icon},null,8,["name"]),e.createElementVNode("span",rf,e.toDisplayString(U==null?void 0:U.label),1)],10,lf)]}),_:2},1032,["disabled"])):e.createCommentVNode("",!0),(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(sl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>{var je;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}])},[e.createVNode(X,{class:"table-op-icon",name:(je=g==null?void 0:g.find(na=>(na==null?void 0:na.label)===(U==null?void 0:U.label)))==null?void 0:je.icon},null,8,["name"]),e.createElementVNode("span",nf,e.toDisplayString(U==null?void 0:U.label),1)],2)]}),dropMenu:e.withCtx(()=>[e.createElementVNode("div",of,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U==null?void 0:U.contents,je=>{var na,Ca;return e.openBlock(),e.createElementBlock("div",{key:je==null?void 0:je.label,class:e.normalizeClass(["table-op-drop-item",{"is-disabled":!!a.lockingPage}]),onClick:ee=>!a.lockingPage&&I(je==null?void 0:je.label)},[e.createTextVNode(e.toDisplayString(je==null?void 0:je.label),1),(na=je==null?void 0:je.label)!=null&&na.includes("选中")?(e.openBlock(),e.createElementBlock("span",sf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(Ca=je==null?void 0:je.label)!=null&&Ca.includes("全部")?(e.openBlock(),e.createElementBlock("span",cf,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)],10,tf)}),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:je=>!a.lockingPage&&I(U==null?void 0:U.label,U)},[e.createVNode(X,{class:"table-op-icon",name:((Ie=g==null?void 0:g.find(je=>(je==null?void 0:je.label)===(U==null?void 0:U.label)))==null?void 0:Ie.icon)??"normal"},null,8,["name"]),e.createElementVNode("span",df,e.toDisplayString(U==null?void 0:U.label),1)],10,uf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createElementBlock("div",pf,[e.createElementVNode("div",ff,[e.createElementVNode("div",hf,[e.createVNode(me,{modelValue:s.value,"onUpdate:modelValue":V[5]||(V[5]=U=>s.value=U),style:{"min-width":"80px"},placeholder:L.value?(Fe=(Ce=(ce=a.filterValues)==null?void 0:ce.filter(U=>U))==null?void 0:Ce.slice(0,3))==null?void 0:Fe.join("/"):"搜索","prefix-icon":e.unref(ja.search_default),clearable:"",onInput:W,disabled:((fe=d.value)==null?void 0:fe.length)===0},{suffix:e.withCtx(()=>{var U,_e;return[!s.value&&((_e=(U=a.filterValues)==null?void 0:U.filter(Ie=>Ie))!=null&&_e.join("/"))?(e.openBlock(),e.createBlock(le,{key:0,style:{cursor:"pointer"},onClick:w},{default:e.withCtx(()=>[e.createVNode(e.unref(ja.circle_close_default))]),_:1})):e.createCommentVNode("",!0)]}),append:e.withCtx(()=>[e.createElementVNode("span",{title:"条件查询",onClick:e.withModifiers(x,["stop"])},[e.createVNode(X,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]),a.buttons&&((N=a.buttons)==null?void 0:N.length)>0?(e.openBlock(),e.createElementBlock("div",vf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((se=a.buttons)==null?void 0:se.filter(U=>a.isDevMode||(U==null?void 0:U.label)!=="修改模板"),(U,_e)=>{var Ie;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:_e},[(U==null?void 0:U.type)==="upload"?(e.openBlock(),e.createBlock(Be,{key:0,class:"upload-button-wrap","on-change":k,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1},{default:e.withCtx(()=>{var je;return[e.createElementVNode("div",mf,[e.createVNode(X,{class:"table-op-icon",name:(je=g==null?void 0:g.find(na=>(na==null?void 0:na.label)===(U==null?void 0:U.label)))==null?void 0:je.icon},null,8,["name"]),e.createElementVNode("span",yf,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(sl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>[(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(F,{key:0,style:{background:"transparent",color:"#000000"}},{icon:e.withCtx(()=>{var je;return[e.createVNode(X,{class:"table-op-icon",name:(je=g==null?void 0:g.find(na=>(na==null?void 0:na.label)===(U==null?void 0:U.label)))==null?void 0:je.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",gf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U==null?void 0:U.contents,je=>(e.openBlock(),e.createBlock(F,{key:je==null?void 0:je.label,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:na=>I(je==null?void 0:je.label)},{default:e.withCtx(()=>{var na,Ca;return[e.createTextVNode(e.toDisplayString(je==null?void 0:je.label),1),(na=je==null?void 0:je.label)!=null&&na.includes("选中")?(e.openBlock(),e.createElementBlock("span",bf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(Ca=je==null?void 0:je.label)!=null&&Ca.includes("全部")?(e.openBlock(),e.createElementBlock("span",kf,"("+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:je=>!a.lockingPage&&I(U==null?void 0:U.label,U)},[e.createVNode(X,{class:"table-op-icon",name:(Ie=g==null?void 0:g.find(je=>(je==null?void 0:je.label)===(U==null?void 0:U.label)))==null?void 0:Ie.icon},null,8,["name"]),e.createElementVNode("span",wf,e.toDisplayString(U==null?void 0:U.label),1)],10,xf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])]))}}},Sf=Ql._export_sfc(_f,[["__scopeId","data-v-44a17652"]]),Ef={__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(sl._sfc_main$2,{key:m,column:d,tableData:a.tableData},e.createSlots({_:2},[e.renderList(l.$slots,(g,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 Cf extends Il.Loader{constructor(l){super(l),this.littleEndian=!0}load(l,n,r,i){const s=this,h=new Il.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,I=new Uint8Array(k);let j=0,L=0,E,x,w;do if(E=M[j++],E<32){if(E++,L+E>k)throw new Error("Output buffer is not large enough");if(j+E>W)throw new Error("Invalid compressed data");do I[L++]=M[j++];while(--E)}else{if(x=E>>5,w=L-((E&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 I[L++]=I[w++];while(--x+2)}while(j<W);return I}function r(M){const k={},W=new Uint8Array(M);let I="",j="",L=0,E=!1;const x=W.length;for(;L<x&&E===!1;){const $=String.fromCharCode(W[L++]);$===`
2
+ `||$==="\r"?(j.trim().toLowerCase().startsWith("data")&&(E=!0),j=""):j+=$,I+=$}const w=I.search(/[\r\n]DATA\s(\S*)\s/i),b=/[\r\n]DATA\s(\S*)\s/i.exec(I.slice(w-1));if(k.data=b[1],k.headerLen=b[0].length+w,k.str=I.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($){return parseInt($,10)})),k.count!==null)k.count=k.count[1].split(" ").map(function($){return parseInt($,10)});else{k.count=[];for(let $=0,V=k.fields.length;$<V;$++)k.count.push(1)}k.offset={};let S=0;for(let $=0,V=k.fields.length;$<V;$++)k.data==="ascii"?k.offset[k.fields[$]]=$:(k.offset[k.fields[$]]=S,S+=k.size[$]*k.count[$]);return k.rowSize=S,k}const i=r(l),s=[],h=[],c=[],d=[],m=[],g=new Il.Color;if(i.data==="ascii"){const M=i.offset,I=new TextDecoder().decode(l).slice(i.headerLen).split(`
3
+ `);for(let j=0,L=I.length;j<L;j++){if(I[j]==="")continue;const E=I[j].split(" ");if(M.x!==void 0&&(s.push(parseFloat(E[M.x])),s.push(parseFloat(E[M.y])),s.push(parseFloat(E[M.z]))),M.rgb!==void 0){const x=i.fields.findIndex(X=>X==="rgb"),w=i.type[x],b=parseFloat(E[M.rgb]);let S=b;if(w==="F"){const X=new Float32Array(1);X[0]=b,S=new Int32Array(X.buffer)[0]}const $=(S>>16&255)/255,V=(S>>8&255)/255,le=(S>>0&255)/255;g.setRGB($,V,le,Il.SRGBColorSpace),c.push(g.r,g.g,g.b)}M.normal_x!==void 0&&(h.push(parseFloat(E[M.normal_x])),h.push(parseFloat(E[M.normal_y])),h.push(parseFloat(E[M.normal_z]))),M.intensity!==void 0&&d.push(parseFloat(E[M.intensity])),M.label!==void 0&&m.push(parseInt(E[M.label]))}}if(i.data==="binary_compressed"){const M=new Uint32Array(l.slice(i.headerLen,i.headerLen+8)),k=M[0],W=M[1],I=n(new Uint8Array(l,i.headerLen+8,k),W),j=new DataView(I.buffer),L=i.offset;for(let E=0;E<i.points;E++){if(L.x!==void 0){const x=i.fields.indexOf("x"),w=i.fields.indexOf("y"),b=i.fields.indexOf("z");s.push(this._getDataView(j,i.points*L.x+i.size[x]*E,i.type[x],i.size[x])),s.push(this._getDataView(j,i.points*L.y+i.size[w]*E,i.type[w],i.size[w])),s.push(this._getDataView(j,i.points*L.z+i.size[b]*E,i.type[b],i.size[b]))}if(L.rgb!==void 0){const x=i.fields.indexOf("rgb"),w=j.getUint8(i.points*L.rgb+i.size[x]*E+2)/255,b=j.getUint8(i.points*L.rgb+i.size[x]*E+1)/255,S=j.getUint8(i.points*L.rgb+i.size[x]*E+0)/255;g.setRGB(w,b,S,Il.SRGBColorSpace),c.push(g.r,g.g,g.b)}if(L.normal_x!==void 0){const x=i.fields.indexOf("normal_x"),w=i.fields.indexOf("normal_y"),b=i.fields.indexOf("normal_z");h.push(this._getDataView(j,i.points*L.normal_x+i.size[x]*E,i.type[x],i.size[x])),h.push(this._getDataView(j,i.points*L.normal_y+i.size[w]*E,i.type[w],i.size[w])),h.push(this._getDataView(j,i.points*L.normal_z+i.size[b]*E,i.type[b],i.size[b]))}if(L.intensity!==void 0){const x=i.fields.indexOf("intensity");d.push(this._getDataView(j,i.points*L.intensity+i.size[x]*E,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]*E,this.littleEndian))}}}if(i.data==="binary"){const M=new DataView(l,i.headerLen),k=i.offset;for(let W=0,I=0;W<i.points;W++,I+=i.rowSize){if(k.x!==void 0){const j=i.fields.indexOf("x"),L=i.fields.indexOf("y"),E=i.fields.indexOf("z");s.push(this._getDataView(M,I+k.x,i.type[j],i.size[j])),s.push(this._getDataView(M,I+k.y,i.type[L],i.size[L])),s.push(this._getDataView(M,I+k.z,i.type[E],i.size[E]))}if(k.rgb!==void 0){const j=M.getUint8(I+k.rgb+2)/255,L=M.getUint8(I+k.rgb+1)/255,E=M.getUint8(I+k.rgb+0)/255;g.setRGB(j,L,E,Il.SRGBColorSpace),c.push(g.r,g.g,g.b)}if(k.normal_x!==void 0){const j=i.fields.indexOf("normal_x"),L=i.fields.indexOf("normal_y"),E=i.fields.indexOf("normal_z");h.push(this._getDataView(M,I+k.normal_x,i.type[j],i.size[j])),h.push(this._getDataView(M,I+k.normal_y,i.type[L],i.size[L])),h.push(this._getDataView(M,I+k.normal_z,i.type[E],i.size[E]))}if(k.intensity!==void 0){const j=i.fields.indexOf("intensity");d.push(this._getDataView(M,I+k.intensity,i.type[j],i.size[j]))}k.label!==void 0&&m.push(M.getInt32(I+k.label,this.littleEndian))}}const u=new Il.BufferGeometry;s.length>0&&u.setAttribute("position",new Il.Float32BufferAttribute(s,3)),h.length>0&&u.setAttribute("normal",new Il.Float32BufferAttribute(h,3)),c.length>0&&u.setAttribute("color",new Il.Float32BufferAttribute(c,3)),d.length>0&&u.setAttribute("intensity",new Il.Float32BufferAttribute(d,1)),m.length>0&&u.setAttribute("label",new Il.Int32BufferAttribute(m,1)),u.computeBoundingSphere();const C=new Il.PointsMaterial({size:.005});return c.length>0&&(C.vertexColors=!0),new Il.Points(u,C)}}const Df=A.useModelComp(A.pinia),{systemPath:vs}=A.storeToRefs(Df),ko=e.ref(),ms=new WeakMap;function Tf(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=I=>{try{const j=I.target.result,E=new $n.MTLLoader().parse(j);E.preload(),M(E)}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 Il.MeshPhongMaterial({color:8947848,side:Il.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 I=new FileReader;I.onload=async j=>{try{const L=j.target.result;let E=null;M&&M.length>0&&(M.length===1?E=await h(M[0]):E=await c(M));const x=new $n.OBJLoader;E&&x.setMaterials(E);const w=x.parse(L);E||w.traverse(b=>{b.isMesh&&(b.material=new Il.MeshPhongMaterial({color:8947848,side:Il.DoubleSide}))}),k(w)}catch(L){W(L)}},I.onerror=()=>{W(new Error("OBJ文件读取失败"))},I.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 I=0;I<C.length;I++){const j=C[I];r.value=`正在加载模型 ${I+1}/${C.length}...`;const L=await s(j.objUrl),E=((M=j.objUrl)==null?void 0:M.split("/").pop())||`model_${I}.obj`,x=new File([L],E,{type:L.type});let w=[];if(j.mtlUrls){const S=Array.isArray(j.mtlUrls)?j.mtlUrls:[j.mtlUrls];for(let $=0;$<S.length;$++){const V=S[$],le=await s(V),X=(V==null?void 0:V.split("/").pop())||`material_${I}_${$}.mtl`,me=new File([le],X,{type:le.type});w.push(me)}}const b=await d(x,w);k.add(b),l.value.push(b),W.push(b)}return n.value=!1,W}catch(k){throw console.error("加载模型失败:",k),n.value=!1,k}},g=async(C,M,k=[],W=[])=>{let I;const j=C.toLowerCase();switch(j){case".txt":case".cpt":case".obj":const L=await M.text();if(j===".txt"||j===".cpt"){const ee=/^(?!.*\bf\b)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?$/gm,de=[...L.matchAll(ee)].map(ue=>({x:parseFloat(ue[1]),y:parseFloat(ue[2]),z:parseFloat(ue[3])})),pa=new Il.BufferGeometry,we=de.flatMap(ue=>[ue.x,ue.y,ue.z]);if(pa.setAttribute("position",new Il.Float32BufferAttribute(we,3)),j===".txt"){const ue=new Il.PointsMaterial({color:"#5B5C99",size:1,sizeAttenuation:!1});I=new Il.Points(pa,ue)}else if(j===".cpt"){const ue=new Il.LineBasicMaterial({color:"#5B5C99",linewidth:100});I=new Il.Line(pa,ue)}}else if(j===".obj"){const ee=new $n.OBJLoader;if(k&&k.length>0){const ca=new $n.MTLLoader;for(const de of k){const pa=await de.text(),we=ca.parse(pa);we.preload(),ee.setMaterials(we);break}}I=ee.parse(L),(!k||k.length===0)&&I.traverse(ca=>{ca.isMesh&&(ca.material=new Il.MeshPhongMaterial({color:"#B3B3D4"})),ca instanceof Il.Mesh&&(ca.material.side=Il.DoubleSide)})}break;case".stl":const E=await M.arrayBuffer(),w=new $n.STLLoader().parse(E),b=new Il.MeshPhongMaterial({color:"#B3B3D4",side:Il.DoubleSide});I=new Il.Mesh(w,b);break;case".nc":const S=["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"],$={"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 Il.Group,le=S.map(ee=>new Promise((ca,de)=>{new $n.STLLoader().load(vs.value===""?`/model/${ee}`:`${vs.value}\\${ee}`,we=>{const ue=new Il.MeshPhongMaterial({color:$[ee]||"#B3B3D4",side:Il.DoubleSide}),De=new Il.Mesh(we,ue);ca(De)},void 0,de)}));try{(await Promise.all(le)).forEach(ca=>V.add(ca)),I=V}catch(ee){throw console.error("加载NC文件对应的STL文件失败:",ee),new Error("无法加载.NC文件对应的STL文件")}break;case".pcd":const X=new Cf,me=new Il.Group;try{const ee=await ja.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/target.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),ca=new Blob([ee.data],{type:"application/octet-stream;charset=UTF-8"}),de=await ja.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/final.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),pa=new Blob([de.data],{type:"application/octet-stream;charset=UTF-8"}),we=await new Promise((De,Ge)=>{const ua=URL.createObjectURL(ca);X.load(ua,Ja=>{const R=new Float32Array(Ja.geometry.attributes.position.count*3);for(let H=0;H<Ja.geometry.attributes.position.count;H++)R[H*3]=1,R[H*3+1]=0,R[H*3+2]=0;Ja.geometry.setAttribute("color",new Il.BufferAttribute(R,3)),Ja.material.vertexColors=!0,Ja.scale.set(.3,.3,.3),URL.revokeObjectURL(ua),De(Ja)},void 0,Ge)}),ue=await new Promise((De,Ge)=>{const ua=URL.createObjectURL(pa);X.load(ua,Ja=>{const R=new Float32Array(Ja.geometry.attributes.position.count*3);for(let H=0;H<Ja.geometry.attributes.position.count;H++)R[H*3]=0,R[H*3+1]=1,R[H*3+2]=0;Ja.geometry.setAttribute("color",new Il.BufferAttribute(R,3)),Ja.material.vertexColors=!0,Ja.scale.set(.3,.3,.3),URL.revokeObjectURL(ua),De(Ja)},void 0,Ge)});me.add(we),me.add(ue),I=me}catch(ee){throw console.error("PCD文件加载失败:",ee),new Error("无法加载PCD文件")}break;case".urdf":const Be=URL.createObjectURL(M),F=new Lu.URDFLoader,ie="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},ce=new WeakMap,Ce=new WeakMap,Fe=new WeakMap,fe=async ee=>{if(ce.has(ee))return console.log(`从缓存加载: ${ee}`),ce.get(ee);try{const ca=await ja.axios.get(`${ie}/${ee}`,{responseType:"blob",headers:{"Content-Type":"application/json"},timeout:6e5}),de=new Blob([ca.data],{type:"application/octet-stream;charset=UTF-8"});return Y.enableCache&&ce.set(ee,de),de}catch(ca){throw console.error(`加载文件失败: ${ee}`,ca),new Error(`无法加载文件: ${ee}`)}},N=(ee="default")=>{if(Ce.has(ee))return Ce.get(ee);const ca=new Il.MeshPhongMaterial({color:12303291,shininess:30,transparent:!1,alphaTest:.1,side:Il.FrontSide});return Ce.set(ee,ca),ca},se=ee=>{try{ee.isBufferGeometry&&ee.mergeVertices&&ee.mergeVertices(),ee.computeVertexNormals&&ee.computeVertexNormals(),ee.computeBoundingSphere&&ee.computeBoundingSphere(),ee.deleteAttribute&&ee.deleteAttribute("uv2")}catch(ca){console.warn("几何体优化失败,使用原始几何体:",ca)}return ee},U=async(ee,ca,de)=>{const pa=`stl_${ca}`;if(Fe.has(pa)){const Ge=Fe.get(pa);return new Il.Mesh(Ge,N())}const we=await ee.arrayBuffer();let De=new $n.STLLoader(de).parse(we);return De=se(De),Fe.set(pa,De),new Il.Mesh(De,N())},_e=async(ee,ca,de)=>{const pa=`obj_${ca}`;if(ce.has(pa))return ce.get(pa).clone();const we=await ee.text(),ue=new $n.OBJLoader(de),De=ca.replace(".obj",".mtl");try{const Ja=await(await fe(De)).text(),H=new $n.MTLLoader(de).parse(Ja);H.preload(),ue.setMaterials(H)}catch{console.warn(`MTL文件加载失败,使用默认材质: ${De}`)}const Ge=ue.parse(we);return Ge.traverse(ua=>{ua.isMesh&&(ua.geometry=se(ua.geometry),ua.castShadow=!0,ua.receiveShadow=!0,ua.renderOrder=1)}),ce.set(pa,Ge),Ge},Ie=(ee,ca)=>{const de=new Il.LOD;if(de.addLevel(ee,0),ee.geometry){const pa=ee.geometry.clone(),we=new Il.Mesh(pa,ee.material);de.addLevel(we,50)}return de};let je=0,na=0;const Ca=[];F.loadMeshCb=async(ee,ca,de,pa,we)=>{const ue=ee.split("/").pop(),De=de||(()=>{});je++;const Ge=new Promise(async(ua,Ja)=>{try{const R=await fe(ue);if(!R||R.size===0)throw new Error(`文件为空: ${ue}`);const H=ue.split(".").pop().toLowerCase();let J;switch(H){case"stl":J=await U(R,ue,ca);break;case"obj":J=await _e(R,ue,ca);break;default:throw new Error(`不支持的文件格式: ${H}`)}Y.enableLOD&&J.isMesh&&(J=Ie(J,ue)),De(J),na++,pa&&pa({loaded:na,total:je,progress:na/je}),ua(J)}catch(R){console.error(`mesh文件加载失败: ${ue}`,R);const H=new Il.Group;De(H),ua(H);const J=new Il.BoxGeometry(.1,.1,.1),he=new Il.MeshStandardMaterial({color:16711680,wireframe:!0});return new Il.Mesh(J,he)}});Ca.push(Ge)};try{if(!Be){ko.value=void 0;break}if(I=await F.loadAsync(Be),console.log(`URDF文件加载完成,等待${je}个mesh文件加载...`),Ca.length>0)try{await Promise.allSettled(Ca),console.log(`所有mesh文件处理完成,成功加载: ${na}/${je}`)}catch(de){console.warn("部分mesh文件加载失败,但继续显示模型",de)}I.traverse(de=>{de.isMesh&&(de.castShadow=!0,de.receiveShadow=!0,de.renderOrder=1,de.material&&(de.material.needsUpdate=!0))}),console.time("计算包围盒");const ee=new Il.Box3;ee.expandByObject(I);const ca=`urdf_${Date.now()}`;I.userData.boundingBox=ee.clone(),I.userData.modelId=ca,ms.set(ca,{box:ee.clone(),center:ee.getCenter(new Il.Vector3),size:ee.getSize(new Il.Vector3),maxSize:Math.max(...ee.getSize(new Il.Vector3).toArray())}),ko.value=I,console.log("URDF模型加载完成并优化")}catch(ee){console.error("URDF加载失败:",ee),ko.value=void 0}finally{Be&&URL.revokeObjectURL(Be)}break;default:throw new Error(`不支持的文件格式: ${C}`)}return I};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 I=C[W],j=await g(I.suffix,I.blob,I.mtlBlobs||[],I.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:ms}}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,g(),h.onreadystatechange=function(){h.readyState=="complete"&&(h.onreadystatechange=null,m())})}function m(){c||(c=!0,s())}function g(){try{h.documentElement.doScroll("left")}catch{return void setTimeout(g,50)}m()}})(window);const Bf=["onClick"],Nf=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=te.rgbaToColor(n==null?void 0:n.textColor),b={},S={};return!Number.isNaN(x)&&x&&(b.fontSize=`${x}px`,S.fontSize=`${x}px`),w&&(b.color=w,S.color=w),{label:b,value:S}}),c=e.ref(""),d=e.ref(""),m=e.ref(!1),g=async x=>{if(x){d.value&&(URL.revokeObjectURL(d.value),d.value="");try{const w=await A.platformDownloadFile({url:x}),b=new Blob([w==null?void 0:w.data],{type:(w==null?void 0:w.headers["content-type"])||"image/*"});d.value=URL.createObjectURL(b)}catch{d.value=""}}};e.watch(()=>n==null?void 0:n.backGroundImage,x=>{x&&(c.value=x)},{immediate:!0}),e.watch(c,x=>{g(x)},{immediate:!0});const u=()=>{var x;(x=s.value)==null||x.click()},C=async x=>{var S,$,V;const w=x.target,b=(S=w==null?void 0:w.files)==null?void 0:S[0];if(!b){w.value="";return}m.value=!0;try{const le=new FormData;le.append("file",b);const X=await A.platformUploadFile(le),me=(V=($=X==null?void 0:X.data)==null?void 0:$.result)==null?void 0:V.url;me?(c.value=me,r("update:backGroundImage",me),g(me),ja.ElMessage.success("背景图片上传成功")):ja.ElMessage.error("背景图片上传失败")}catch{ja.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=>sl.getComponent(x),W=x=>{if(!x)return;const w=x.querySelector("input, textarea, .el-input__inner");w&&typeof w.focus=="function"&&w.focus()},I=(x,w,b)=>{n.disabled||x.field&&(i.value=w,e.nextTick(()=>{W(b.currentTarget)}))},j=()=>{i.value=null},L=x=>{var b;const w=((b=x==null?void 0:x.field)==null?void 0:b.value)??(x==null?void 0:x.value);return w==null||w===""?"-":w},E=x=>{const w=x!=null&&x.width&&x.width>0?x.width:1,S=`calc((100% - ${(w-1)*16}px) / ${w})`;return{flex:`0 0 ${S}`,maxWidth:S,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]=b=>(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(b=>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:sl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.items,(b,S)=>{var $,V,le,X,me,Be,F,ie;return e.openBlock(),e.createElementBlock("div",{class:"statistics-card",key:S,style:e.normalizeStyle(E(b)),onClick:w[1]||(w[1]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",{class:"statistics-label",style:e.normalizeStyle(h.value.label)},e.toDisplayString(b==null?void 0:b.label),5),e.createElementVNode("div",{class:"statistics-value",style:e.normalizeStyle(h.value.value),onClick:Y=>{var ce;return(ce=b.field)!=null&&ce.isNoClick?null:I(b,S,Y)}},[i.value===S&&b.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(k((($=b.field)==null?void 0:$.type)??"Input")),{key:0,modelValue:b.field.value,"onUpdate:modelValue":Y=>b.field.value=Y,isEdit:!0,disabled:(V=b.field)==null?void 0:V.disabled,content:((le=b.field)==null?void 0:le.contents)??[],optionUrl:b.field,originalValue:(X=b.field)==null?void 0:X.value,config:(me=b.field)==null?void 0:me.config,configModel:((Be=b.field)==null?void 0:Be.prop)??((F=b.field)==null?void 0:F.name),selectedTagList:((ie=b.field)==null?void 0:ie.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(b)),1)],64))],12,Bf)],4)}),128))],4))}}),Af=Ql._export_sfc(Nf,[["__scopeId","data-v-af63fc22"]]),hc=A.defineStore("formToTableComp",{state:()=>({selectArray:[],selectString:""}),actions:{setSelectArray(a){this.selectArray=a},setSelectString(a){this.selectString=a}}}),zf={class:"calculator-content"},Mf={class:"calculator-child"},If={class:"calculator-child"},Of=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",zf,[e.createElementVNode("div",Mf,[e.createVNode(sl.ssForm,{rowContents:l.value,isRowFlex:!0},null,8,["rowContents"])]),e.createElementVNode("div",If,[e.createVNode(sl.ssForm,{rowContents:n.value,isEdit:!1,isRowFlex:!0},null,8,["rowContents"])])]))}}),Lf=Ql._export_sfc(Of,[["__scopeId","data-v-73db0fe7"]]),wt=(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=wt(c,r))}),Object.assign(h,{id:s})}else return i})),n},vc=(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 g;return Array.isArray(m)&&(m=vc(m,(g=i==null?void 0:i[h])==null?void 0:g.children,n)),m}))),s}),r},Rf=(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 $f(a,r,n)}},$f=(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=mc(s,i,n)),s)),r},mc=(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=mc(c,i,n)),c)),r},Vf=(a,l,n)=>{if(l==="")return 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=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;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=yc(h,i,n)),h)),r};class Ff{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 g=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,g,k);return}if(r===81){const g=n[3]||0,u=[];for(let C=0;C<g;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,g,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 I=new Uint8Array(u);for(let j=0;j<u;j++)I[j]=n[9+j];M=decodeURIComponent(this.byteToString(I))}const k=new Uint8Array(C);for(let I=0;I<C;I++)k[I]=n[9+u+I];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 g=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(g,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 jf={style:{display:"flex",gap:"16px",height:"100%"}},Hf={key:0,style:{color:"var(--el-text-color-secondary)"}},Uf={style:{width:"420px",display:"flex","flex-direction":"column",gap:"16px"}},qf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px"}},Wf={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"}},Kf={key:0,style:{height:"100%",display:"flex","align-items":"center","justify-content":"center",color:"var(--el-text-color-secondary)"}},Gf={key:1,style:{display:"grid","grid-template-columns":"repeat(2, minmax(0, 1fr))",gap:"8px"}},Yf=["src","onClick"],Jf=["onClick"],Xf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px",flex:"1","min-height":"0",display:"flex","flex-direction":"column"}},Zf={class:"dialog-footer"},Qf=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([]),g=new Ff({url:"ws://127.0.0.1:22225"});function u(V,le){var Y;const X=V.split(","),me=((Y=X[0].match(/:(.*?);/))==null?void 0:Y[1])??"image/jpeg",Be=atob(X[1]);let F=Be.length;const ie=new Uint8Array(F);for(;F--;)ie[F]=Be.charCodeAt(F);return new File([ie],le,{type:me})}function C(){g.onLog=V=>{console.log("[GPY]",V)},g.onDevCount=(V,le)=>{if(c.value+=`设备数量=${V},设备=${le.join(",")}
4
+ `,V>0){c.value+=`检测到设备,正在获取分辨率...
5
+ `;try{g.getResolution(0)}catch(X){c.value+=`获取分辨率失败:${(X==null?void 0:X.message)??X}
6
+ `}}else c.value+=`未检测到高拍仪设备!
7
+ `},g.onResolution=(V,le)=>{if(V<=0||!Array.isArray(le)||le.length===0){c.value+=`未获取到可用分辨率,回退使用 1280*720 打开...
8
+ `;try{g.openCamera(0,1280,720)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
9
+ `}return}const X=g.chooseResolution(le);if(!X){c.value+=`分辨率选择失败,回退使用 1280*720 打开...
10
+ `;try{g.openCamera(0,1280,720)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
11
+ `}return}c.value+=`获取分辨率 ${X.text}成功,打开摄像头...
12
+ `;try{g.closeCamera(),setTimeout(()=>{try{g.openCamera(0,X.width,X.height)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
13
+ `}},100)}catch{try{g.openCamera(0,X.width,X.height)}catch(me){c.value+=`打开摄像头失败:${(me==null?void 0:me.message)??me}
14
+ `}}},g.onCameraStatus=V=>{V==="opened"?(s.value=!0,c.value+=`摄像头已打开
15
+ `):(s.value=!1,c.value+=`摄像头已关闭
16
+ `)},g.onPhoto=V=>{if(V.flag===0&&V.base64){const le=`data:image/jpeg;base64,${V.base64}`,X=u(le,`gpy-capture-${Date.now()}.jpg`);h.value.push({uid:`${Date.now()}_${Math.random().toString(16).slice(2)}`,url:le,file:X}),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();g.init(i.value,Math.floor(V.width),Math.floor(V.height)),c.value+=`正在连接设备服务...
19
+ `,await g.connect(),c.value+=`正在获取设备数量...
20
+ `,g.getDevCount()},k=()=>{try{g.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{g.bestSize()}catch(V){console.error(V)}},I=()=>{try{g.rotateLeft()}catch(V){console.error(V)}},j=()=>{try{g.rotateRight()}catch(V){console.error(V)}},L=()=>{try{g.focus()}catch(V){console.error(V)}},E=()=>{c.value+=`正在拍照...
21
+ `;try{g.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
+ `)},b=V=>{if(!V)return;const le=`gpy-preview-${Date.now()}.jpg`;m.value=[{name:le,blobUrl:V}],d.value=!0},S=()=>{d.value=!1},$=()=>{k(),r("cancel")};return(V,le)=>{const X=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:$,width:"1200px",style:{height:"80%"}},{default:e.withCtx(()=>[e.createElementVNode("div",jf,[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",Hf,"初始化摄像头..."))],512),e.createElementVNode("div",Uf,[e.createElementVNode("div",qf,[le[0]||(le[0]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"拍照图片",-1)),e.createElementVNode("div",Wf,[h.value.length===0?(e.openBlock(),e.createElementBlock("div",Kf,"暂无图片")):(e.openBlock(),e.createElementBlock("div",Gf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(Be,F)=>(e.openBlock(),e.createElementBlock("div",{key:Be.uid,style:{position:"relative",border:"1px solid var(--el-border-color)","border-radius":"4px",overflow:"hidden",background:"#fafafa"}},[e.createElementVNode("img",{src:Be.url,onClick:ie=>b(Be.url),style:{width:"100%",height:"94px","object-fit":"contain",display:"block",background:"#fafafa",cursor:"zoom-in"},alt:"captured image",title:"点击放大"},null,8,Yf),e.createElementVNode("div",{onClick:ie=>w(F),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,Jf)]))),128))]))],512)]),e.createElementVNode("div",Xf,[le[1]||(le[1]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"操作记录",-1)),e.createVNode(X,{type:"textarea",value:c.value,readonly:"",rows:10,placeholder:"设备操作记录...",style:{flex:"1"}},null,8,["value"])])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",Zf,[e.createVNode(me,{onClick:W,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>le[2]||(le[2]=[e.createTextVNode("适屏")])),_:1,__:[2]},8,["disabled"]),e.createVNode(me,{onClick:I,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>le[3]||(le[3]=[e.createTextVNode("左旋")])),_:1,__:[3]},8,["disabled"]),e.createVNode(me,{onClick:j,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>le[4]||(le[4]=[e.createTextVNode("右旋")])),_:1,__:[4]},8,["disabled"]),e.createVNode(me,{onClick:L,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>le[5]||(le[5]=[e.createTextVNode("对焦")])),_:1,__:[5]},8,["disabled"]),e.createVNode(me,{onClick:E,disabled:!s.value,id:"themeButton"},{default:e.withCtx(()=>le[6]||(le[6]=[e.createTextVNode("拍照")])),_:1,__:[6]},8,["disabled"]),le[9]||(le[9]=e.createElementVNode("div",{style:{flex:"1"}},null,-1)),e.createVNode(me,{onClick:x,disabled:h.value.length===0,id:"themeButton"},{default:e.withCtx(()=>le[7]||(le[7]=[e.createTextVNode("确认")])),_:1,__:[7]},8,["disabled"]),e.createVNode(me,{onClick:$,id:"themeBorderButton"},{default:e.withCtx(()=>le[8]||(le[8]=[e.createTextVNode("取消")])),_:1,__:[8]})])]),_:1},8,["visible"]),d.value?(e.openBlock(),e.createBlock(sl.ssFilePreview,{key:0,fileDataList:m.value,onDestroy:S},null,8,["fileDataList"])):e.createCommentVNode("",!0)],64)}}}),e0=Ql._export_sfc(Qf,[["__scopeId","data-v-24a2050a"]]),ys=A.useMenuState(A.pinia),a0=async a=>{var s,h,c,d,m,g;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"))){ys.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 lc(M);k=(g=(m=(d=k==null?void 0:k.data)==null?void 0:d.data)==null?void 0:m.response)==null?void 0:g.replace("generateResult",a==null?void 0:a.函数名称),i=k,ys.setContentLoading(!1)}return i},At=A.defineStore("formComp",{state:()=>({objUrl:[],blobUrls:[]}),actions:{setObjUrl(a){this.objUrl=a},setBlobUrls(a){this.blobUrls=a}}}),l0=A.useModelComp(A.pinia),{extraContents:vv}=A.storeToRefs(l0),r0=A.useLoginState(A.pinia),{extraUrl:ui}=A.storeToRefs(r0);let gc=ui.value===""||!ui.value?"http://139.196.154.85:20015":ui.value;e.watch(()=>ui.value,()=>{gc=ui.value===""||!ui.value?"http://139.196.154.85:20015":ui.value},{deep:!0,immediate:!0});const zo={检校类型:["检校类型","证书类别"],证书编号:["证书编号"],设备名称:["设备名称","器具名称","样品名称","仪器名称","被校设备"],型号规格:["型号规格","型号/规格","型号"],出厂编号:["出厂编号","器具/管理编号","器具编号","管理编号","仪器编号"],制造厂:["制造厂","制造单位","制造厂商","制造商"],检校结果:["检校结果","检定结论","校准结果","校准/检定结果","检定结果"],依据文件:["依据文件","检定依据","检定所依据的技术文件","所依据/参照技术文件(代号/名称)","检定所依据的技术文件(编号/名称)","检定方法说明"],检校日期:["检校日期","校准日期","校验日期","检定日期","发证日期","发布日期","接收日期","签证日期"],有效日期:["有效日期","有效期","有效期至"]},gs={columnName:"OCR图片",acceptTypes:"image/*",maxSize:10,maxFiles:20,apiUrl:gc+"/api/public/paddleOCR"};class n0{constructor(l){tn(this,"config");this.config={...gs,...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=ja.Local.get(ja.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||gs.apiUrl||"";return(await ja.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 g=this.getFieldAliases(m);n.push(g)}}})};return s(l||[]),n}}function bc(a){return new n0(a)}bc();const _t=async(a,l)=>{var h,c,d,m,g,u,C,M,k,W,I,j,L,E,x,w,b;let n=(c=(h=A.cloneDeep(a))==null?void 0:h.optionUrl)==null?void 0:c.menuSelect,r=[];n==null||n.forEach(S=>{});let i="",s=await te.menuToParent(n);if(s==null||s.forEach(S=>{var $,V,le,X;(S==null?void 0:S.name)===(((X=(le=(V=($=A.cloneDeep(a))==null?void 0:$.optionUrl)==null?void 0:V.groupSelect)==null?void 0:le[0])==null?void 0:X.replaceAll("'",""))??"")&&(i=S==null?void 0:S.id)}),l){i=l;const S=await Rr.getInsofDataApi({id:i}),$=(u=(g=(m=(d=S==null?void 0:S.data)==null?void 0:d.result)==null?void 0:m[0])==null?void 0:g.key)==null?void 0:u.pageKey;s=await te.getItemData($,sessionStorage.getItem("systemKey"),"")}if(i!==""){let S;l?S=(C=s==null?void 0:s.find(le=>(le==null?void 0:le.id)===l))==null?void 0:C.compData:S=(M=s==null?void 0:s.find(le=>{var X,me,Be,F;return(le==null?void 0:le.name)===(((me=(X=a==null?void 0:a.groupSelect)==null?void 0:X.split(":"))==null?void 0:me[0])||((F=(Be=a==null?void 0:a.optionUrl)==null?void 0:Be.groupSelect)==null?void 0:F[0]))}))==null?void 0:M.compData;let $=(W=(k=S==null?void 0:S.find(le=>(le==null?void 0:le.key)==="header"))==null?void 0:k.contents)==null?void 0:W.map(le=>le==null?void 0:le.label);(j=(I=S==null?void 0:S.find(le=>(le==null?void 0:le.key)==="header"))==null?void 0:I.contents)!=null&&j.every(le=>Array.isArray(le))&&($=(x=te.getColumnChild((E=(L=S==null?void 0:S.find(le=>(le==null?void 0:le.key)==="header"))==null?void 0:L.contents)==null?void 0:E[0]))==null?void 0:x.map(le=>le==null?void 0:le.prop));let V=(b=(w=S==null?void 0:S.find(le=>(le==null?void 0:le.key)==="tableContents"))==null?void 0:w.contents)==null?void 0:b.map(le=>{if(Array.isArray(le))le=le==null?void 0:le.filter(X=>!(X!=null&&X.id));else{let X={};for(let me in le)me!=="id"&&(X[me]=le==null?void 0:le[me]);le=X}return le});V==null||V.forEach(le=>{Array.isArray(le)?r.push(te.getValueToObjectValue(le,$)):r.push(le)})}return r},i0=A.useMenuState(A.pinia),{activeMenuPath:mv}=A.storeToRefs(i0),o0=A.useUnit(A.pinia),{chooseTitle:yv}=A.storeToRefs(o0),t0="col-operate",kc=a=>`${t0}-${a}`,s0=(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);c0(c,s),Array.isArray(s==null?void 0:s.children)&&s.children.length>0&&r(s.children)})};return r(l),l},c0=(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),u0=(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}},d0=async a=>{var s,h;if(!a)return;const l=kc(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]},p0=async a=>{if(a)return[]},f0=async(a,l)=>{if(!a||!l)return;const n=kc(a);return await Rr.createInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:n},value:{columns:l}})},h0=async(a,l)=>!a||!l?void 0:await Rr.updateInsofDataApi({id:a,value:{columns:l}}),bs=async(a,l)=>{const n=sessionStorage.getItem("systemKey");if(!a||!l||!n)return;const r=await d0(a);return r?await h0(r==null?void 0:r.id,l):await f0(a,l)};var Co={exports:{}},v0=Co.exports,ks;function m0(){return ks||(ks=1,function(a,l){(function(n,r){r()})(v0,function(){function n(m,g){return typeof g>"u"?g={autoBom:!1}:typeof g!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),g={autoBom:!g}),g.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,g,u){var C=new XMLHttpRequest;C.open("GET",m),C.responseType="blob",C.onload=function(){d(C.response,g,u)},C.onerror=function(){console.error("could not download file")},C.send()}function i(m){var g=new XMLHttpRequest;g.open("HEAD",m,!1);try{g.send()}catch{}return 200<=g.status&&299>=g.status}function s(m){try{m.dispatchEvent(new MouseEvent("click"))}catch{var g=document.createEvent("MouseEvents");g.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),m.dispatchEvent(g)}}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,g,u){var C=h.URL||h.webkitURL,M=document.createElement("a");g=g||m.name||"download",M.download=g,M.rel="noopener",typeof m=="string"?(M.href=m,M.origin===location.origin?s(M):i(M.href)?r(m,g,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,g,u){if(g=g||m.name||"download",typeof m!="string")navigator.msSaveOrOpenBlob(n(m,u),g);else if(i(m))r(m,g,u);else{var C=document.createElement("a");C.href=m,C.target="_blank",setTimeout(function(){s(C)})}}:function(m,g,u,C){if(C=C||open("","_blank"),C&&(C.document.title=C.document.body.innerText="downloading..."),typeof m=="string")return r(m,g,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 I=new FileReader;I.onloadend=function(){var E=I.result;E=W?E:E.replace(/^data:[^;]*;/,"data:attachment/file;"),C?C.location.href=E:location=E,C=null},I.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}m0();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}}}),y0=A.useLoginState(A.pinia),{loginUserInfo:ht}=A.storeToRefs(y0),g0=async a=>{var r,i,s;let l=await A.getAllTables({platId:parseInt((r=ht==null?void 0:ht.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 fc(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}]}]},b0=A.useLoginState(),{loginUserInfo:yl}=A.storeToRefs(b0);let xo="$R";const Or=A.useModelComp(A.pinia),xc=e.ref(!1),{itemData:k0,itemGridData:ti,curStructureCompIds:xs,isSubmitCurStructure:x0,routeToChildPath:w0,pageMapState:St,itemExtendData:wo,refreshTable:ws,refreshCurrentPageInform:_0}=A.storeToRefs(Or),Fo=Yn(A.pinia),Hr=A.useMenuState(A.pinia),ur=e.shallowRef([]),{asideMenus:S0,activeTopMenuPath:E0,activeMenuPath:kl,platform:gv,buttonTriggerType:C0,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),Et=e.ref([]);e.ref(!1);const zt=e.ref(!1),Xi=e.ref(),wc=e.ref(),_c=e.ref(),D0=()=>{Or.setItemGridData([]),Or.setIsEdit("edit"),Or.setSubmitCurStructure(kl.value!=="/平台管理/菜单管理")},T0=()=>{Or.setIsEdit("view"),Or.setRefreshCurStructure(!0)},B0=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(sl.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)},vt=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(g=>(g==null?void 0:g.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(g=>(g==null?void 0:g.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 ja.ElMessage.error("保存响应失败"),new Error("保存响应失败")}catch{ja.ElMessage.error("保存响应失败")}},_s=async(a,l,n,r)=>{var i,s,h,c,d,m,g,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}})),I=(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 E;n?E=(u=(g=(m=St.value)==null?void 0:m[kl.value])==null?void 0:g.filter(w=>{var b,S,$;return((b=w==null?void 0:w.key)==null?void 0:b.type)===l&&(($=(S=w==null?void 0:w.key)==null?void 0:S.relatedInfo)==null?void 0:$.target)===r}))==null?void 0:u.map(w=>w==null?void 0:w.id):E=(k=(M=(C=St.value)==null?void 0:C[kl.value])==null?void 0:M.filter(w=>{var b;return((b=w==null?void 0:w.key)==null?void 0:b.type)===l}))==null?void 0:k.map(w=>w==null?void 0:w.id);const x=E==null?void 0:E.filter(w=>!(L!=null&&L.includes(w))&&typeof w=="number");(W==null?void 0:W.length)>0&&await Rr.batchAddInsofDataApi({dataList:W}),(I==null?void 0:I.length)>0&&await Rr.batchUpdateInsofDataApi({dataList:I}),(x==null?void 0:x.length)>0&&await Rr.batchDeleteInsofDataApi({ids:x})}catch(W){throw new Error(W)}},N0=async a=>{var m,g,u,C,M,k,W,I,j,L;Hr.setContentLoading(!0);const l=JSON.parse(JSON.stringify(k0.value));if(!x0.value)return Hr.setCacheStructures({key:C0.value,data:l}),ja.ElMessage.success("已暂存");const n=l==null?void 0:l.map(E=>E.id),r=n.filter(E=>{var x;return!((x=xs.value)!=null&&x.includes(E))}),i=(m=xs.value)==null?void 0:m.filter(E=>!n.includes(E)),s=[...r,...i].filter(E=>typeof E!==null&&typeof E<"u"),h=l==null?void 0:l.filter(E=>!E.id),c=l==null?void 0:l.filter(E=>E.id);let d=[];if(s&&(s==null?void 0:s.length)>0&&d.push(vt(s,"delete",a)),h&&(h==null?void 0:h.length)>0&&d.push(vt(h,"create",a)),c&&(c==null?void 0:c.length)>0&&d.push(vt(c,"update",a)),ti.value&&((g=ti.value)!=null&&g.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(E=>typeof E=="number"))?await Rr.batchDeleteInsofDataApi({ids:(W=ti.value)==null?void 0:W.results}):(console.log("itemGridData.value",ti.value),d.push(await _s(ti.value,"gridLayout")))),wo.value)for(const E in wo.value)d.push(await _s((I=wo.value)==null?void 0:I[E],"extend",{target:E,compId:(L=(j=wo.value)==null?void 0:j[E])==null?void 0:L.compId},E));await Promise.all(d).then(()=>{ja.ElMessage.success("保存成功"),Or.setRefreshCurStructure(!0)}).catch(E=>{ja.ElMessage.success(E)}),Hr.setContentLoading(!1)},Zi=a=>zi(a),A0=e.computed(()=>{var a;return(a=ur.value)==null?void 0:a.filter(l=>(l==null?void 0:l.affix)&&(l==null?void 0:l.affix)!=="default")}),Sc=e.computed(()=>{var a;return(a=ur.value)==null?void 0:a.filter(l=>!(l!=null&&l.affix&&(l==null?void 0:l.affix)!=="default"))}),Ec=e.ref(0),Cc=e.ref(null),z0="ocr_committed_temp_ids_v1",M0=(a,l)=>`${z0}:${String(a??"")}:${String(l??"")}`,I0=(a,l,n)=>{try{const r=M0(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,g,u,C,M,k,W,I,j,L,E,x,w,b,S,$,V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae,oe,Xe,Ze,Pa,Sa,Xa,Ve,Re,We,Ae,Me,cl,wl,Cl,Pl,Sl,Gl;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(ke=>{let Ia={};for(let $a in ke)Array.isArray(ke==null?void 0:ke[$a])?Ia[$a]=JSON.stringify(ke==null?void 0:ke[$a]):Ia[$a]=ke==null?void 0:ke[$a];return Ia}),Ha=await A.quoteApi({platId:parseInt((d=yl==null?void 0:yl.value)==null?void 0:d.plat_id),type:"fatherSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.value,groups:a==null?void 0:a.name}]});Ha=(m=Ha==null?void 0:Ha.data)==null?void 0:m.result,Ha=Ha==null?void 0:Ha.filter(ke=>{var Ia,$a;return!((ke==null?void 0:ke.fatherPath)!==""&&(($a=(Ia=ke==null?void 0:ke.quote)==null?void 0:Ia[0])==null?void 0:$a.menus)===(kl==null?void 0:kl.value))});let ya=Ha==null?void 0:Ha.map(ke=>{var la,ba;let Ia={},$a=aa==null?void 0:aa[0],Z;return Array.isArray((la=ke==null?void 0:ke.struct)==null?void 0:la[0])?Z=te.getColumnChild((ba=ke==null?void 0:ke.struct)==null?void 0:ba[0]):Z=ke==null?void 0:ke.struct,Z=Z==null?void 0:Z.filter(Ke=>(Ke==null?void 0:Ke.prop)!=="relatedId"),Z==null||Z.forEach(Ke=>{var Ua,ga;Ia[Ke.prop]=((Ua=Ke==null?void 0:Ke.words)!=null&&Ua[0]?($a==null?void 0:$a[(ga=Ke==null?void 0:Ke.words)==null?void 0:ga[0]])??($a==null?void 0:$a[Ke==null?void 0:Ke.prop]):$a==null?void 0:$a[Ke==null?void 0:Ke.prop])??""}),Ia.id="1",Ia.relatedId=`[${Ia.id}]`,delete Ia.sort,{tableName:"content_"+(ke==null?void 0:ke.id),tableContents:[Ia]}}),rl=[{tableName:(g=a==null?void 0:a.relatedContents)==null?void 0:g.find(ke=>ke==null?void 0:ke.includes("content")),tableContents:aa}];rl=[...rl,...ya];let Aa=await A.quoteApi({platId:parseInt((u=yl==null?void 0:yl.value)==null?void 0:u.plat_id),type:"sonSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.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(ke=>!(rl!=null&&rl.find(Ia=>(Ia==null?void 0:Ia.tableName)==="content_"+(ke==null?void 0:ke.id)))),Aa=Aa==null?void 0:Aa.filter(ke=>{var Ia,$a;return!((ke==null?void 0:ke.fatherPath)!==""&&(($a=(Ia=ke==null?void 0:ke.quote)==null?void 0:Ia[0])==null?void 0:$a.menus)===(kl==null?void 0:kl.value))});let ol=Aa==null?void 0:Aa.map(ke=>{var la,ba,Ke,Ua,ga,tl,Le;let Ia={},$a=aa==null?void 0:aa[0],Z;return Array.isArray((la=ke==null?void 0:ke.struct)==null?void 0:la[0])?Z=te.getColumnChild((ba=ke==null?void 0:ke.struct)==null?void 0:ba[0]):Z=ke==null?void 0:ke.struct,Z=Z==null?void 0:Z.filter(ia=>(ia==null?void 0:ia.prop)!=="relatedId"),((Ua=(Ke=Z==null?void 0:Z[0])==null?void 0:Ke.words)!=null&&Ua[0]?$a!=null&&$a[(tl=(ga=Z==null?void 0:Z[0])==null?void 0:ga.words)==null?void 0:tl[0]]:$a!=null&&$a[(Le=Z==null?void 0:Z[0])==null?void 0:Le.prop])?(Z==null||Z.forEach(ia=>{var va,ll;Ia[ia.prop]=((va=ia==null?void 0:ia.words)!=null&&va[0]?($a==null?void 0:$a[(ll=ia==null?void 0:ia.words)==null?void 0:ll[0]])??($a==null?void 0:$a[ia==null?void 0:ia.prop]):$a==null?void 0:$a[ia==null?void 0:ia.prop])??""}),Ia.id="1",Ia.relatedId=`[${Ia.id}]`,delete Ia.sort):Ia=void 0,{tableName:"content_"+(ke==null?void 0:ke.id),tableContents:[Ia]}});ol=ol==null?void 0:ol.filter(ke=>{var Ia;return!((Ia=ke==null?void 0:ke.tableContents)!=null&&Ia.every($a=>$a===void 0))}),rl=[...rl,...ol],await A.pageBatchAddApi({platId:parseInt((k=yl==null?void 0:yl.value)==null?void 0:k.plat_id),changeContents:rl});let al=[];rl==null||rl.forEach(ke=>{var Ia;(Ia=ke==null?void 0:ke.tableContents)==null||Ia.forEach($a=>{al.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify($a),request_result:"{}",is_delete:!1,request_table:ke==null?void 0:ke.tableName,request_type:"add"})})}),await A.pageBatchAddApi({platId:parseInt((W=yl==null?void 0:yl.value)==null?void 0:W.plat_id),changeContents:[{tableName:"log",tableContents:al}]})}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),Ha=((a==null?void 0:a.ocrRows)||[]).map(Aa=>{const ol={...Aa};return delete ol._isOCRRow,delete ol._ocrTableId,Object.keys(ol).forEach(al=>{/(^|\.)证书附件$/.test(al)&&Array.isArray(ol[al])&&(ol[al]=JSON.stringify(ol[al].map(ke=>({url:(ke==null?void 0:ke.url)||"",name:(ke==null?void 0:ke.name)||(ke==null?void 0:ke.fileName)||"",fileName:(ke==null?void 0:ke.fileName)||(ke==null?void 0:ke.name)||""})).filter(ke=>ke.url||ke.name)))}),ol});let ya=[{tableName:(I=a==null?void 0:a.relatedContents)==null?void 0:I.find(Aa=>Aa==null?void 0:Aa.includes("content")),tableContents:Ha}];await A.pageBatchAddApi({platId:parseInt((j=yl==null?void 0:yl.value)==null?void 0:j.plat_id),changeContents:ya});let rl=[];ya==null||ya.forEach(Aa=>{var ol;(ol=Aa==null?void 0:Aa.tableContents)==null||ol.forEach(al=>{rl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(al),request_result:"{}",is_delete:!1,request_table:Aa==null?void 0:Aa.tableName,request_type:"ocrBatchAdd"})})}),await A.pageBatchAddApi({platId:parseInt((L=yl==null?void 0:yl.value)==null?void 0:L.plat_id),changeContents:[{tableName:"log",tableContents:rl}]}),I0(a==null?void 0:a.parentTableId,a==null?void 0:a.index,aa)}if((a==null?void 0:a.buttonName)==="编辑"){const Ha=((a==null?void 0:a.fixContent)||(a==null?void 0:a.singleContent)||[]||[]).map(Z=>{const la={...Z};return delete la._isOCRRow,delete la._ocrTableId,delete la._isTemp,delete la.tableEditType,delete la.index,la});let ya=Ha==null?void 0:Ha.map(Z=>{let la={};for(let ba in Z)Array.isArray(Z==null?void 0:Z[ba])?la[ba]=JSON.stringify(Z==null?void 0:Z[ba]):la[ba]=Z==null?void 0:Z[ba];return la}),rl=await A.quoteApi({platId:parseInt((E=yl==null?void 0:yl.value)==null?void 0:E.plat_id),type:"fatherSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.value,groups:a==null?void 0:a.name}]});rl=(x=rl==null?void 0:rl.data)==null?void 0:x.result,rl=rl==null?void 0:rl.filter(Z=>{var la,ba;return!((Z==null?void 0:Z.fatherPath)!==""&&((ba=(la=Z==null?void 0:Z.quote)==null?void 0:la[0])==null?void 0:ba.menus)===(kl==null?void 0:kl.value))});let Aa=(w=ya==null?void 0:ya[0])==null?void 0:w.id,ol=[{tableName:(b=a==null?void 0:a.relatedContents)==null?void 0:b.find(Z=>Z==null?void 0:Z.includes("content")),tableContents:ya}],al=(S=rl==null?void 0:rl.map(Z=>{var ba,Ke,Ua,ga,tl;let la=(ba=Z==null?void 0:Z.contents)==null?void 0:ba.filter(Le=>{var ia,va;return JSON.stringify(Le==null?void 0:Le.relatedId)!=="{}"&&(Le==null?void 0:Le.relatedId)!==""&&(Le!=null&&Le.relatedId)?(ia=Le==null?void 0:Le.relatedId)==null?void 0:ia.includes(parseInt(Aa)):(Le==null?void 0:Le.sort)===((va=ya==null?void 0:ya[0])==null?void 0:va.sort)});if((la==null?void 0:la.length)>0){let Le=ya==null?void 0:ya[0];Le={...Le,id:(Ke=la==null?void 0:la[0])==null?void 0:Ke.id};let ia={},va=Le,ll;return Array.isArray((Ua=Z==null?void 0:Z.struct)==null?void 0:Ua[0])?ll=te.getColumnChild((ga=Z==null?void 0:Z.struct)==null?void 0:ga[0]):ll=Z==null?void 0:Z.struct,ll=ll==null?void 0:ll.filter(Pe=>(Pe==null?void 0:Pe.prop)!=="relatedId"),ll==null||ll.forEach(Pe=>{var Dl,Wa;ia[Pe.prop]=((Dl=Pe==null?void 0:Pe.words)!=null&&Dl[0]?(va==null?void 0:va[(Wa=Pe==null?void 0:Pe.words)==null?void 0:Wa[0]])??(va==null?void 0:va[Pe==null?void 0:Pe.prop]):va==null?void 0:va[Pe==null?void 0:Pe.prop])??""}),ia.id=(tl=la==null?void 0:la[0])==null?void 0:tl.id,delete ia.sort,delete ia.relatedId,{tableName:"content_"+(Z==null?void 0:Z.id),tableContents:[ia]}}else return}))==null?void 0:S.filter(Z=>Z);ol=[...ol,...al];let ke=await A.quoteApi({platId:parseInt(($=yl==null?void 0:yl.value)==null?void 0:$.plat_id),type:"sonSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.value,groups:a==null?void 0:a.name}]});ke=(le=(V=ke==null?void 0:ke.data)==null?void 0:V.result)==null?void 0:le.filter(Z=>!(ol!=null&&ol.find(la=>(la==null?void 0:la.tableName)==="content_"+(Z==null?void 0:Z.id)))),ke=ke==null?void 0:ke.filter(Z=>{var la,ba;return!((Z==null?void 0:Z.fatherPath)!==""&&((ba=(la=Z==null?void 0:Z.quote)==null?void 0:la[0])==null?void 0:ba.menus)===(kl==null?void 0:kl.value))});let Ia=(X=ke==null?void 0:ke.map(Z=>{var ba,Ke,Ua,ga,tl;let la=(ba=Z==null?void 0:Z.contents)==null?void 0:ba.filter(Le=>{var ia,va,ll;return JSON.stringify(Le==null?void 0:Le.relatedId)!=="{}"&&(Le==null?void 0:Le.relatedId)!==""&&(Le!=null&&Le.relatedId)?(ia=Le==null?void 0:Le.relatedId)==null?void 0:ia.includes(parseInt(Aa)):(Le==null?void 0:Le.sort)===((va=ya==null?void 0:ya[0])==null?void 0:va.sort)||(Le==null?void 0:Le.sort)===(parseInt(((ll=ya==null?void 0:ya[0])==null?void 0:ll.sort)??"0")+1).toString()});if((la==null?void 0:la.length)>0){let Le=ya==null?void 0:ya[0];Le={...Le,id:(Ke=la==null?void 0:la[0])==null?void 0:Ke.id};let ia={},va=Le,ll;return Array.isArray((Ua=Z==null?void 0:Z.struct)==null?void 0:Ua[0])?ll=te.getColumnChild((ga=Z==null?void 0:Z.struct)==null?void 0:ga[0]):ll=Z==null?void 0:Z.struct,ll=ll==null?void 0:ll.filter(Pe=>(Pe==null?void 0:Pe.prop)!=="relatedId"),ll==null||ll.forEach(Pe=>{var Dl,Wa,ml,nr;((Dl=Pe==null?void 0:Pe.words)!=null&&Dl[0]?(va==null?void 0:va[(Wa=Pe==null?void 0:Pe.words)==null?void 0:Wa[0]])??(va==null?void 0:va[Pe==null?void 0:Pe.prop]):va!=null&&va[Pe==null?void 0:Pe.prop])&&(ia[Pe.prop]=((ml=Pe==null?void 0:Pe.words)!=null&&ml[0]?(va==null?void 0:va[(nr=Pe==null?void 0:Pe.words)==null?void 0:nr[0]])??(va==null?void 0:va[Pe==null?void 0:Pe.prop]):va==null?void 0:va[Pe==null?void 0:Pe.prop])??"")}),ia.id=(tl=la==null?void 0:la[0])==null?void 0:tl.id,delete ia.sort,delete ia.relatedId,{tableName:"content_"+(Z==null?void 0:Z.id),tableContents:[ia]}}else return}))==null?void 0:X.filter(Z=>Z);ol=[...ol,...Ia],await A.pageBatchUpdateApi({platId:parseInt((me=yl==null?void 0:yl.value)==null?void 0:me.plat_id),changeContents:ol});let $a=[];ol==null||ol.forEach(Z=>{var la;(la=Z==null?void 0:Z.tableContents)==null||la.forEach(ba=>{$a.push({id:"1",request_method:"Post",request_url:"/platform/page/update",request_param:JSON.stringify(ba),request_result:"{}",is_delete:!1,request_table:Z==null?void 0:Z.tableName,request_type:"update"})})}),await A.pageBatchAddApi({platId:parseInt((Be=yl==null?void 0:yl.value)==null?void 0:Be.plat_id),changeContents:[{tableName:"log",tableContents:$a}]})}if((a==null?void 0:a.buttonName)==="删除"){let aa=[{tableName:(F=a==null?void 0:a.relatedContents)==null?void 0:F.find(ke=>ke==null?void 0:ke.includes("content")),tableContents:a==null?void 0:a.fixContent}],Ha=await A.quoteApi({platId:parseInt((ie=yl==null?void 0:yl.value)==null?void 0:ie.plat_id),type:"fatherSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.value,groups:a==null?void 0:a.name}]});Ha=(Y=Ha==null?void 0:Ha.data)==null?void 0:Y.result,Ha=Ha==null?void 0:Ha.filter(ke=>{var Ia,$a;return!((ke==null?void 0:ke.fatherPath)!==""&&(($a=(Ia=ke==null?void 0:ke.quote)==null?void 0:Ia[0])==null?void 0:$a.menus)===(kl==null?void 0:kl.value))});let ya=(Ce=(ce=a==null?void 0:a.fixContent)==null?void 0:ce[0])==null?void 0:Ce.id,rl=(Fe=Ha==null?void 0:Ha.map(ke=>{var $a,Z,la,ba,Ke,Ua;let Ia=($a=ke==null?void 0:ke.contents)==null?void 0:$a.filter(ga=>{var tl,Le,ia;return JSON.stringify(ga==null?void 0:ga.relatedId)!=="{}"&&(ga==null?void 0:ga.relatedId)!==""&&(ga!=null&&ga.relatedId)?(tl=ga==null?void 0:ga.relatedId)==null?void 0:tl.includes(parseInt(ya)):(ga==null?void 0:ga.sort)===((ia=(Le=a==null?void 0:a.fixContent)==null?void 0:Le[0])==null?void 0:ia.sort)});if((Ia==null?void 0:Ia.length)>0){let ga=(Z=a==null?void 0:a.fixContent)==null?void 0:Z[0];ga={...ga,id:(la=Ia==null?void 0:Ia[0])==null?void 0:la.id};let tl={},Le=ga,ia;return Array.isArray((ba=ke==null?void 0:ke.struct)==null?void 0:ba[0])?ia=te.getColumnChild((Ke=ke==null?void 0:ke.struct)==null?void 0:Ke[0]):ia=ke==null?void 0:ke.struct,ia=ia==null?void 0:ia.filter(va=>(va==null?void 0:va.prop)!=="relatedId"),ia==null||ia.forEach(va=>{var ll,Pe;tl[va.prop]=((ll=va==null?void 0:va.words)!=null&&ll[0]?(Le==null?void 0:Le[(Pe=va==null?void 0:va.words)==null?void 0:Pe[0]])??(Le==null?void 0:Le[va==null?void 0:va.prop]):Le==null?void 0:Le[va==null?void 0:va.prop])??""}),tl.id=(Ua=Ia==null?void 0:Ia[0])==null?void 0:Ua.id,delete tl.sort,delete tl.relatedId,{tableName:"content_"+(ke==null?void 0:ke.id),tableContents:[tl]}}else return}))==null?void 0:Fe.filter(ke=>ke);aa=[...aa,...rl];let Aa=await A.quoteApi({platId:parseInt((fe=yl==null?void 0:yl.value)==null?void 0:fe.plat_id),type:"sonSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.value,groups:a==null?void 0:a.name}]});Aa=(se=(N=Aa==null?void 0:Aa.data)==null?void 0:N.result)==null?void 0:se.filter(ke=>!(aa!=null&&aa.find(Ia=>(Ia==null?void 0:Ia.tableName)==="content_"+(ke==null?void 0:ke.id)))),Aa=Aa==null?void 0:Aa.filter(ke=>{var Ia,$a;return!((ke==null?void 0:ke.fatherPath)!==""&&(($a=(Ia=ke==null?void 0:ke.quote)==null?void 0:Ia[0])==null?void 0:$a.menus)===(kl==null?void 0:kl.value))});let ol=(U=Aa==null?void 0:Aa.map(ke=>{var $a,Z,la,ba,Ke,Ua;let Ia=($a=ke==null?void 0:ke.contents)==null?void 0:$a.filter(ga=>{var tl,Le,ia;return JSON.stringify(ga==null?void 0:ga.relatedId)!=="{}"&&(ga==null?void 0:ga.relatedId)!==""&&(ga!=null&&ga.relatedId)?(tl=ga==null?void 0:ga.relatedId)==null?void 0:tl.includes(parseInt(ya)):(ga==null?void 0:ga.sort)===((ia=(Le=a==null?void 0:a.fixContent)==null?void 0:Le[0])==null?void 0:ia.sort)});if((Ia==null?void 0:Ia.length)>0){let ga=(Z=a==null?void 0:a.fixContent)==null?void 0:Z[0];ga={...ga,id:(la=Ia==null?void 0:Ia[0])==null?void 0:la.id};let tl={},Le=ga,ia;return Array.isArray((ba=ke==null?void 0:ke.struct)==null?void 0:ba[0])?ia=te.getColumnChild((Ke=ke==null?void 0:ke.struct)==null?void 0:Ke[0]):ia=ke==null?void 0:ke.struct,ia=ia==null?void 0:ia.filter(va=>(va==null?void 0:va.prop)!=="relatedId"),ia==null||ia.forEach(va=>{var ll,Pe;tl[va.prop]=((ll=va==null?void 0:va.words)!=null&&ll[0]?(Le==null?void 0:Le[(Pe=va==null?void 0:va.words)==null?void 0:Pe[0]])??(Le==null?void 0:Le[va==null?void 0:va.prop]):Le==null?void 0:Le[va==null?void 0:va.prop])??""}),tl.id=(Ua=Ia==null?void 0:Ia[0])==null?void 0:Ua.id,delete tl.sort,delete tl.relatedId,{tableName:"content_"+(ke==null?void 0:ke.id),tableContents:[tl]}}else return}))==null?void 0:U.filter(ke=>ke);aa=[...aa,...ol],await A.pageBatchDeleteApi({platId:parseInt((_e=yl==null?void 0:yl.value)==null?void 0:_e.plat_id),changeContents:aa});let al=[];aa==null||aa.forEach(ke=>{var Ia;(Ia=ke==null?void 0:ke.tableContents)==null||Ia.forEach($a=>{al.push({id:"1",request_method:"Post",request_url:"/platform/page/delete",request_param:JSON.stringify($a),request_result:"{}",is_delete:!1,request_table:ke==null?void 0:ke.tableName,request_type:"delete"})})}),await A.pageBatchAddApi({platId:parseInt((Ie=yl==null?void 0:yl.value)==null?void 0:Ie.plat_id),changeContents:[{tableName:"log",tableContents:al}]})}if((a==null?void 0:a.buttonName)==="复制新增"){let aa=await A.getPageDataApi({platId:parseInt((je=yl==null?void 0:yl.value)==null?void 0:je.plat_id),pageName:"menu"});if(aa=(na=aa==null?void 0:aa.data)==null?void 0:na.result,aa!=null&&aa.find(Ha=>(Ha==null?void 0:Ha.father_name)===kl.value+"/")){_c.value=a,wc.value=aa==null?void 0:aa.filter(rl=>(rl==null?void 0:rl.father_name)===kl.value+"/");let Ha=(ee=(Ca=a==null?void 0:a.columns)==null?void 0:Ca.find(rl=>rl==null?void 0:rl.mainKey))==null?void 0:ee.prop,ya=(de=(ca=a==null?void 0:a.fixContent)==null?void 0:ca[0])==null?void 0:de[Ha];zt.value=!0,Xi.value=[{prop:Ha,label:Ha,name:Ha,value:ya}]}else{let Ha=(pa=a==null?void 0:a.fixContent)==null?void 0:pa.map(Aa=>{let ol={};for(let al in Aa)Array.isArray(Aa==null?void 0:Aa[al])?ol[al]=JSON.stringify(Aa==null?void 0:Aa[al]):ol[al]=Aa==null?void 0:Aa[al];return ol.relatedId="",ol}),ya=[{tableName:(we=a==null?void 0:a.relatedContents)==null?void 0:we.find(Aa=>Aa==null?void 0:Aa.includes("content")),tableContents:Ha}];await A.pageBatchAddApi({platId:parseInt((ue=yl==null?void 0:yl.value)==null?void 0:ue.plat_id),changeContents:ya});let rl=[];ya==null||ya.forEach(Aa=>{var ol;(ol=Aa==null?void 0:Aa.tableContents)==null||ol.forEach(al=>{rl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(al),request_result:"{}",is_delete:!1,request_table:Aa==null?void 0:Aa.tableName,request_type:"copyAdd"})})}),await A.pageBatchAddApi({platId:parseInt((De=yl==null?void 0:yl.value)==null?void 0:De.plat_id),changeContents:[{tableName:"log",tableContents:rl}]})}}if((a==null?void 0:a.buttonName)==="methodButton"){let aa=((Ja=(ua=(Ge=a==null?void 0:a.columns)==null?void 0:Ge.map(Z=>Z==null?void 0:Z.filter))==null?void 0:ua.filter(Z=>Z!==""))==null?void 0:Ja[0])??"";aa=te.analyzeSplitToContent(aa,","),aa=(aa==null?void 0:aa.find(Z=>Z==null?void 0:Z.includes("@Filter")))??"";let Ha=(R=a==null?void 0:a.fixContent)==null?void 0:R.map(Z=>{let la={};for(let ba in Z)Array.isArray(Z==null?void 0:Z[ba])?la[ba]=JSON.stringify(Z==null?void 0:Z[ba]):la[ba]=Z==null?void 0:Z[ba];return la}),ya=await A.quoteApi({platId:parseInt((H=yl==null?void 0:yl.value)==null?void 0:H.plat_id),type:"fatherSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.value,groups:a==null?void 0:a.name}]});ya=(J=ya==null?void 0:ya.data)==null?void 0:J.result,ya=ya==null?void 0:ya.filter(Z=>{var la,ba;return!((Z==null?void 0:Z.fatherPath)!==""&&((ba=(la=Z==null?void 0:Z.quote)==null?void 0:la[0])==null?void 0:ba.menus)===(kl==null?void 0:kl.value))});let rl=(pe=(he=a==null?void 0:a.columns)==null?void 0:he[0])==null?void 0:pe.prop,Aa=(ha=Ha==null?void 0:Ha[0])==null?void 0:ha[rl],ol=[{tableName:(ta=a==null?void 0:a.relatedContents)==null?void 0:ta.find(Z=>Z==null?void 0:Z.includes("content")),tableContents:Ha}],al=(He=ya==null?void 0:ya.map(Z=>{var ba,Ke,Ua,ga,tl;let la=(ba=Z==null?void 0:Z.contents)==null?void 0:ba.filter(Le=>{var ia;return(ia=Object.values(Le))==null?void 0:ia.find(va=>va===Aa)});if((la==null?void 0:la.length)>0){let Le=Ha==null?void 0:Ha[0];Le={...Le,id:(Ke=la==null?void 0:la[0])==null?void 0:Ke.id};let ia={},va=Le,ll;return Array.isArray((Ua=Z==null?void 0:Z.struct)==null?void 0:Ua[0])?ll=te.getColumnChild((ga=Z==null?void 0:Z.struct)==null?void 0:ga[0]):ll=Z==null?void 0:Z.struct,ll=ll==null?void 0:ll.filter(Pe=>(Pe==null?void 0:Pe.prop)!=="relatedId"),ll==null||ll.forEach(Pe=>{var Dl,Wa;ia[Pe.prop]=((Dl=Pe==null?void 0:Pe.words)!=null&&Dl[0]?(va==null?void 0:va[(Wa=Pe==null?void 0:Pe.words)==null?void 0:Wa[0]])??(va==null?void 0:va[Pe==null?void 0:Pe.prop]):va==null?void 0:va[Pe==null?void 0:Pe.prop])??""}),ia.id=(tl=la==null?void 0:la[0])==null?void 0:tl.id,delete ia.sort,{tableName:"content_"+(Z==null?void 0:Z.id),tableContents:[ia]}}else return}))==null?void 0:He.filter(Z=>Z);ol=[...ol,...al];let ke=await A.quoteApi({platId:parseInt((_a=yl==null?void 0:yl.value)==null?void 0:_a.plat_id),type:"sonSyncs",related:[{menus:r!==""?kl.value+"/"+r:kl.value,groups:a==null?void 0:a.name}]});if(ke=(ma=(ze=ke==null?void 0:ke.data)==null?void 0:ze.result)==null?void 0:ma.filter(Z=>!(ol!=null&&ol.find(la=>(la==null?void 0:la.tableName)==="content_"+(Z==null?void 0:Z.id)))),ke=ke==null?void 0:ke.filter(Z=>{var la,ba;return!((Z==null?void 0:Z.fatherPath)!==""&&((ba=(la=Z==null?void 0:Z.quote)==null?void 0:la[0])==null?void 0:ba.menus)===(kl==null?void 0:kl.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=(Ma=(Oa=aa==null?void 0:aa.replace("(",xo))==null?void 0:Oa.split(xo))==null?void 0:Ma[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 Z=te.calculatorAndToOr(aa);Z=Z==null?void 0:Z[0];let la;if((ye=Object.values(Z))!=null&&ye.some(ba=>(ba==null?void 0:ba[0])==="*")){let ba=(ae=(Ne=Wn.value)==null?void 0:Ne.find(Ke=>(Ke==null?void 0:Ke.condition)==="child"))!=null&&ae.value?(hn==null?void 0:hn.value)+"/"+((Xe=(oe=Wn.value)==null?void 0:oe.find(Ke=>(Ke==null?void 0:Ke.condition)==="child"))==null?void 0:Xe.value):hn==null?void 0:hn.value;la=await an(ba,!1)}for(let ba in Z)if(((Ze=Z==null?void 0:Z[ba])==null?void 0:Ze[0])==="*"){let Ke=(Ve=(Xa=(Sa=Z[ba])==null?void 0:Sa.slice(1,(Pa=Z[ba])==null?void 0:Pa.length))==null?void 0:Xa.split(":"))==null?void 0:Ve[0],Ua=(We=(Re=Z[ba])==null?void 0:Re.split(":"))==null?void 0:We[1],ga=(Ae=la==null?void 0:la.filter(tl=>(tl==null?void 0:tl.name)===Ke))==null?void 0:Ae[0];ga=(cl=(Me=ga==null?void 0:ga.compData)==null?void 0:Me.find(tl=>(tl==null?void 0:tl.key)==="tableContents"))==null?void 0:cl.contents,ga=(wl=ga==null?void 0:ga[0])==null?void 0:wl[Ua],Z[ba]=ga}aa=((Cl=Object.values(Z))==null?void 0:Cl[0])??""}let Ia=(Pl=ke==null?void 0:ke.map(Z=>{var ba,Ke,Ua,ga,tl;let la=(ba=Z==null?void 0:Z.contents)==null?void 0:ba.filter(Le=>{var ia;return(ia=Object.values(Le))==null?void 0:ia.find(va=>va===(aa===""?Aa:aa))});if((la==null?void 0:la.length)>0){let Le=Ha==null?void 0:Ha[0];Le={...Le,id:(Ke=la==null?void 0:la[0])==null?void 0:Ke.id};let ia={},va=Le,ll;return Array.isArray((Ua=Z==null?void 0:Z.struct)==null?void 0:Ua[0])?ll=te.getColumnChild((ga=Z==null?void 0:Z.struct)==null?void 0:ga[0]):ll=Z==null?void 0:Z.struct,ll=ll==null?void 0:ll.filter(Pe=>(Pe==null?void 0:Pe.prop)!=="relatedId"),ll==null||ll.forEach(Pe=>{var Wa,ml,nr,_r;let Dl=(Wa=a==null?void 0:a.columns)==null?void 0:Wa.find(jl=>{var pr,Sr,Cr;return((Sr=(pr=jl==null?void 0:jl.words)==null?void 0:pr[0])==null?void 0:Sr.replaceAll("'",""))===(Pe==null?void 0:Pe.prop)&&((Cr=jl==null?void 0:jl.functionRelatedWords)==null?void 0:Cr.length)>0});Dl=(ml=Dl==null?void 0:Dl.prop)==null?void 0:ml.replaceAll("'",""),ia[Pe.prop]=((nr=Pe==null?void 0:Pe.words)!=null&&nr[0]?(va==null?void 0:va[(_r=Pe==null?void 0:Pe.words)==null?void 0:_r[0]])??(va==null?void 0:va[Pe==null?void 0:Pe.prop])??(va==null?void 0:va[Dl]):(va==null?void 0:va[Pe==null?void 0:Pe.prop])??(va==null?void 0:va[Dl]))??void 0}),ia.id=(tl=la==null?void 0:la[0])==null?void 0:tl.id,delete ia.sort,{tableName:"content_"+(Z==null?void 0:Z.id),tableContents:[ia]}}else return}))==null?void 0:Pl.filter(Z=>Z);ol=[...ol,...Ia],await A.pageBatchUpdateApi({platId:parseInt((Sl=yl==null?void 0:yl.value)==null?void 0:Sl.plat_id),changeContents:ol});let $a=[];ol==null||ol.forEach(Z=>{var la;(la=Z==null?void 0:Z.tableContents)==null||la.forEach(ba=>{$a.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ba),request_result:"{}",is_delete:!1,request_table:Z==null?void 0:Z.tableName,request_type:"method"})})}),await A.pageBatchAddApi({platId:parseInt((Gl=yl==null?void 0:yl.value)==null?void 0:Gl.plat_id),changeContents:[{tableName:"log",tableContents:$a}]})}Or.setRefreshCurStructure(!0),Or.setRefreshCurrentPageInform(_0.value++),await Dt(a)},Ct=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 g={};for(let u in m)JSON.stringify(m==null?void 0:m[u])==="{}"?g[u]="":g[u]=m==null?void 0:m[u];return g}),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 Ct(c==null?void 0:c.children,l,n):c.compData=await Ct(c==null?void 0:c.compData,l,n),c});return s=await Promise.all(h),s}},Dt=async a=>{var s,h,c,d,m,g,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=yl==null?void 0:yl.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],I=W&&Object.prototype.toString.call(W)==="[object Object]"&&Object.keys(W).length===0,j=Array.isArray(W)&&W.length===0;W==null||W==="{}"||I||j?M[k]="":M[k]=W}return M});let r=(g=(m=l==null?void 0:l[0])==null?void 0:m.split("_"))==null?void 0:g[1],i=await Ct(ur.value,r,n);ur.value=(u=ur.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})},O0=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))},L0=async()=>{var C,M,k,W,I,j,L,E,x,w;let a=_c.value,l=wc.value,n=(M=(C=a==null?void 0:a.columns)==null?void 0:C.find(b=>b==null?void 0:b.mainKey))==null?void 0:M.prop,r=(W=(k=Xi.value)==null?void 0:k[0])==null?void 0:W.value,i=(I=a==null?void 0:a.fixContent)==null?void 0:I.map(b=>{var $;let S={};for(let V in b)Array.isArray(b==null?void 0:b[V])?S[V]=JSON.stringify(b==null?void 0:b[V]):S[V]=b==null?void 0:b[V];return($=a==null?void 0:a.columns)==null||$.forEach(V=>{(V==null?void 0:V.formType)==="Upload"&&(S==null?void 0:S[V==null?void 0:V.prop])===""&&(S[V==null?void 0:V.prop]="{}")}),S[n]=r,S}),s=[{tableName:(j=a==null?void 0:a.relatedContents)==null?void 0:j.find(b=>b==null?void 0:b.includes("content")),tableContents:i}];await A.pageBatchAddApi({platId:parseInt((L=yl==null?void 0:yl.value)==null?void 0:L.plat_id),changeContents:s}),l=l==null?void 0:l.filter(b=>{var S,$,V;return(V=b==null?void 0:b.object_name)==null?void 0:V.includes(($=(S=a==null?void 0:a.fixContent)==null?void 0:S[0])==null?void 0:$[n])});let h=[],c=new Map;l==null||l.forEach(b=>{h.push(`content_${b==null?void 0:b.object_id}`),h.push(`struct_${b==null?void 0:b.object_id}`),c.set(b==null?void 0:b.object_id,b)});let d=await A.getAllTables({platId:parseInt((E=yl==null?void 0:yl.value)==null?void 0:E.plat_id),tableNames:h??[]});d=(x=d==null?void 0:d.data)==null?void 0:x.result;let m=[],g=[];d=te.chunk(d,2),d==null||d.forEach(b=>{var V,le,X,me,Be,F,ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca,ee;let S=c.get((me=(X=(le=(V=b==null?void 0:b[1])==null?void 0:V[0])==null?void 0:le.source_table)==null?void 0:X.split("_"))==null?void 0:me[1]),$=(ie=(F=(Be=S==null?void 0:S.object_name)==null?void 0:Be.split("/"))==null?void 0:F.filter((ca,de)=>{var pa,we;return((we=(pa=S==null?void 0:S.object_name)==null?void 0:pa.split("/"))==null?void 0:we.length)-1!==de}))==null?void 0:ie.join("/");if($=$+"/"+r,g!=null&&g.find(ca=>(ca==null?void 0:ca.path)===$)||g.push({fatherPath:S==null?void 0:S.father_name,isShow:S==null?void 0:S.is_show,path:$}),((ce=(Y=b==null?void 0:b[1])==null?void 0:Y[0])==null?void 0:ce.类型)==="Table"){let ca=((fe=(Fe=(Ce=b==null?void 0:b[1])==null?void 0:Ce[0])==null?void 0:Fe.结构)==null?void 0:fe.contents)??[],de=sl.safeClone(ca);Array.isArray(de==null?void 0:de[0])&&(de=te.getColumnChild(de==null?void 0:de[0]));let pa=[];if(((N=b==null?void 0:b[0])==null?void 0:N.length)>0&&(pa=(se=b==null?void 0:b[0])==null?void 0:se.map(we=>de==null?void 0:de.map(De=>(De=(we==null?void 0:we[De==null?void 0:De.prop])??"",De)))),m!=null&&m.find(we=>(we==null?void 0:we.key)===$)){let we=(U=m==null?void 0:m.find(De=>(De==null?void 0:De.key)===$))==null?void 0:U.contents;we.push({isShow:S==null?void 0:S.is_show,filter:((je=(Ie=(_e=b==null?void 0:b[1])==null?void 0:_e[0])==null?void 0:Ie.引用)==null?void 0:je.contents)??"",key:"Table",name:Object.values(S==null?void 0:S.name),tableColumns:ca,tableContents:pa});let ue=m==null?void 0:m.findIndex(De=>(De==null?void 0:De.key)===$);m[ue].contents=we}else m.push({key:$,contents:[{isShow:S==null?void 0:S.is_show,filter:((ee=(Ca=(na=b==null?void 0:b[1])==null?void 0:na[0])==null?void 0:Ca.引用)==null?void 0:ee.contents)??"",key:"Table",name:Object.values(S==null?void 0:S.name),tableColumns:ca,tableContents:pa}]})}});let u=[];u.push({key:"menuPath",contents:g}),u=[...u,...m],await A.createPlatFormDataApi({platId:parseInt((w=yl==null?void 0:yl.value)==null?void 0:w.plat_id),changeData:u}),zt.value=!1,Or.setRefreshTable(!0)},Oo=async(a,l)=>{},Lo=async a=>{ur.value=await te.getDeepDiffItems(a),Or.setItemData(ur.value),Or.setOriginalData(ur.value)};e.ref();const R0=e.ref(null),$0=()=>{var a,l;console.log("倒计时结束时"),A.ElMessageBox.alert(`超时未提交,【${(l=(a=kl.value)==null?void 0:a.split("/"))==null?void 0:l[0]}】失败`,"告警",{confirmButtonText:"确认",type:"error"})},Dc=e.ref([]),V0=e.computed(()=>{var a,l;return(l=(a=St.value)==null?void 0:a[kl.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(()=>[E0.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)??(kl==null?void 0:kl.value),g=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 an(g,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 te.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 I;return!(W!=null&&W.choiceName)||(W==null?void 0:W.choiceName)===((I=k==null?void 0:k[0])==null?void 0:I.choiceName)}),ur.value=M,Hr.setContentLoading(!1)}});const P0=(a,l)=>{setTimeout(async()=>{var c,d,m;let n=(c=Mo.value)==null?void 0:c.filter(g=>(g==null?void 0:g.condition)==="child"&&(g==null?void 0:g.value)!==""&&(g==null?void 0:g.parentContent)!==hn.value),r=kl==null?void 0:kl.value,i=kl==null?void 0:kl.value;(n==null?void 0:n.length)>0&&(i=((d=n==null?void 0:n[0])==null?void 0:d.relatedContent)??(kl==null?void 0:kl.value),r=i+"/"+((m=n==null?void 0:n[0])==null?void 0:m.value));let s=await an(r,!1,{originPath:i});s=s==null?void 0:s.map(g=>(g.isShow=!0,g));let h=await te.getDeepDiffItems(s);ur.value=h==null?void 0:h.filter(g=>!(g!=null&&g.step)||(g==null?void 0:g.step)===(a==null?void 0:a.title))},10)},F0=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=kl==null?void 0:kl.value,r=kl==null?void 0:kl.value;(l==null?void 0:l.length)>0&&(r=((c=l==null?void 0:l[0])==null?void 0:c.relatedContent)??(kl==null?void 0:kl.value),n=r+"/"+((d=l==null?void 0:l[0])==null?void 0:d.value));let i=await an(n,!1,{originPath:r});i=i==null?void 0:i.map(m=>(m.isShow=!0,m)),Fo.setSelectTab(a);let s=await te.getDeepDiffItems(i);ur.value=s==null?void 0:s.filter(m=>!(m!=null&&m.choiceName)||(m==null?void 0:m.choiceName)===a)},10)};e.watch(()=>S0.value,a=>{a!=null&&a.length||(ur.value=[])},{immediate:!0});e.watch(()=>[kl.value],async a=>{var s,h,c,d;if(!kl.value)return;if(kl.value==="/"){ur.value=[];return}Hr.setCurrentMenuPath(kl.value),Or.setLockingPage(""),ur.value=[];let l=e.getCurrentInstance();(s=l==null?void 0:l.scope)==null||s.stop(),l=null,Ai.value=!1,Hr.setContentLoading(!0),xc.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)!==kl.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==="系统管理/日志管理")ur.value=await g0("log");else{let m=await an(n,!0,{originPath:r});m=m==null?void 0:m.map(C=>(C.isShow=!0,C));let g=await te.getDeepDiffItems(m),u=g==null?void 0:g.filter(C=>C==null?void 0:C.choice);Fo.setSelectTab((d=u==null?void 0:u[0])==null?void 0:d.choiceName),ur.value=g==null?void 0:g.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(ur.value),Or.setOriginalData(ur.value),Or.setRefreshTable(!1),e.nextTick(()=>{Gn.value=Gn.value++,Ai.value=!0})},{immediate:!0});e.watch(()=>[ws.value],async()=>{var a,l,n,r;if(ws.value){ur.value=[];let i=e.getCurrentInstance();(a=i==null?void 0:i.scope)==null||a.stop(),i=null,Ai.value=!1,Hr.setContentLoading(!0),xc.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 an(s,!0,{originPath:h});d=d==null?void 0:d.map(u=>(u.isShow=!0,u));let m=await te.getDeepDiffItems(d),g=m==null?void 0:m.filter(u=>u==null?void 0:u.choice);if(Fo.setSelectTab((r=g==null?void 0:g[0])==null?void 0:r.choiceName),ur.value=m==null?void 0:m.filter(u=>{var C;return!(u!=null&&u.choiceName)||(u==null?void 0:u.choiceName)===((C=g==null?void 0:g[0])==null?void 0:C.choiceName)}),Hr.setContentLoading(!1),Or.setExtraContents([]),wn.setSelectIndex(""),wn.setSelectMenu(""),Or.setItemData(ur.value),Or.setOriginalData(ur.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 j0=async()=>{Hr.setLinkMenuInfo(null),Hr.setActiveMenuPath(w0.value),ur.value=null,Or.setRouteToChildPath(""),Hr.setChildMenu("")},H0=a=>new RegExp("button","i").test(a),U0=a=>/^[\u4e00-\u9fa5]+\/[\u4e00-\u9fa5]+\^(.+)$/.test(a),Tc=a=>{if(U0(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]})}},Bc=async(a,l,n)=>{var C,M,k,W,I,j,L,E,x,w,b,S;let r="",i="";for(let $ in l)(l==null?void 0:l[$])===a&&(i=$);n==null||n.forEach($=>{($==null?void 0:$.prop)===i&&(r=$==null?void 0:$.fatherPath)});let s=r===""?kl.value:r;r!==""&&Hr.setCurrentMenuPath(s),Hr.setCurrentMenuPath(s+"/"+a),Hr.setContentLoading(!0),ur.value=await an(s+"/"+a,!0,{originPath:s+"/",row:l});let h=await an(s,!1),c=(C=h==null?void 0:h.filter($=>($==null?void 0:$.comp)==="Table"))==null?void 0:C[0],d=((I=(W=(k=(M=c==null?void 0:c.compData)==null?void 0:M.find($=>($==null?void 0:$.key)==="header"))==null?void 0:k.contents)==null?void 0:W[0])==null?void 0:I.prop)??((w=(x=(E=(L=(j=c==null?void 0:c.compData)==null?void 0:j.find($=>($==null?void 0:$.key)==="header"))==null?void 0:L.contents)==null?void 0:E[0])==null?void 0:x[0])==null?void 0:w.prop),m=(S=(b=c==null?void 0:c.compData)==null?void 0:b.find($=>($==null?void 0:$.key)==="tableContents"))==null?void 0:S.contents;m=m==null?void 0:m.map($=>({label:$==null?void 0:$[d],value:$==null?void 0:$[d]}));let g=Wn.value,u={value:a,condition:"child",options:m,relatedContent:s,isShow:!0};g=g==null?void 0:g.filter($=>($==null?void 0:$.condition)!=="child"),g.push(u),wn.setSelectTitle(g),wn.setChooseTitle([u]),Hr.setContentLoading(!1),Or.setExtraContents([]),wn.setSelectIndex(""),wn.setSelectMenu(""),Or.setItemData(ur.value),Or.setOriginalData(ur.value)},q0=a=>{Ec.value=a},Di=e.reactive({index:0,comp:null}),W0=e.computed(()=>{var a;return(a=ur.value)==null?void 0:a.map((l,n)=>({id:l.id,name:l.name,status:K0(l,n)}))}),Nc=(a,l)=>{var d,m,g,u,C;const n=l?a:a-2,r=(d=ur.value)==null?void 0:d[n],i=(g=(m=r==null?void 0:r.compData)==null?void 0:m.find(M=>(M==null?void 0:M.key)==="header"))==null?void 0:g.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}},K0=(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}=Nc(l,!0);Di.index===l?n="process":s===0?n="wait":n=i?"success":"error"}return n},Ac=a=>{var n,r,i,s,h;const l=a+1;if(l>1&&((i=(r=(n=ur.value)==null?void 0:n[a])==null?void 0:r.comp)==null?void 0:i.toUpperCase())==="TABLE"){const{valid:c}=Nc(l);c?(Di.index=l,Di.comp=(s=ur.value)==null?void 0:s[a]):ja.ElMessage({showClose:!0,type:"warning",message:"当前流程有输入未完成"})}else Di.index=l,Di.comp=(h=ur.value)==null?void 0:h[a]},zc=e.computed(()=>{var a,l;return(l=(a=Sc.value)==null?void 0:a[0])==null?void 0:l.isStepLayout});e.watch(()=>zc.value,a=>{a&&Ac(0)},{immediate:!0});const G0={class:"table-content"},Y0={class:"menu-config-wrap"},J0=["onClick"],X0={key:0,class:"viewport-wrap"},Z0=["onClick"],Q0={title:"选择显示列信息"},e3={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"}},a3=["title"],l3={class:"col-operate-wrap"},r3={key:0,class:"col-operate-radio-wrapper"},n3={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},i3={key:0,style:{display:"flex","justify-content":"center","align-items":"center"}},o3={class:"pop-view"},t3={class:"pop-wrapper"},s3={class:"file-list-pop"},c3=["title","onClick"],u3=["onClick"],d3=["onClick"],p3={key:1,style:{display:"flex","justify-content":"flex-end",gap:"8px","margin-top":"8px"}},f3={class:"form-content"},h3={key:0,class:"dialog-footer"},v3={class:"dialog-footer"},m3={class:"ocr-dialog-content"},y3={class:"ocr-steps"},g3={key:0,class:"ocr-action-buttons"},b3={key:1,class:"ocr-preview-area"},k3={class:"ocr-file-grid"},x3={class:"file-thumbnail"},w3=["src"],_3={key:1,class:"thumbnail-placeholder"},S3={class:"progress-svg",viewBox:"0 0 36 36"},E3=["stroke","stroke-width","stroke-dasharray"],C3={key:0,class:"progress-icon"},D3={key:1,class:"progress-icon"},T3=["onClick"],B3={class:"file-name"},N3={key:0,class:"ocr-recognize-button"},A3={key:2,class:"ocr-progress-section"},z3={key:3,class:"ocr-confirm-area"},M3={class:"ocr-preview-tip"},I3={class:"ocr-preview-table"},O3={style:{display:"flex","align-items":"center",gap:"8px"}},L3={key:0},R3={key:4,class:"ocr-success-area"},$3={key:0,class:"ocr-dialog-footer"},V3={class:"form-content"},P3={style:{width:"100%",margin:"0","font-size":"14px","font-weight":"600"}},F3={style:{display:"flex","justify-content":"space-between",gap:"8px"}},j3={style:{display:"flex"}},Ss="ss-ocr-upload-history",H3="ss-ocr-cert-history-v1",U3={__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 Ut;const n=e.ref([]),r=At(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,g=e.ref(new Map),u=a,C=e.ref((u==null?void 0:u.allowSelect)??!0),M=e.ref(((Ut=u==null?void 0:u.config)==null?void 0:Ut.showIndex)??!0),k=e.ref(),W=e.ref(!0),I=e.ref(!1),j=e.ref([]),L={sortable:"switch",filterable:"switch",showSummary:"switch",operable:"switch",fixed:"radio"},E=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=te.useOriginalState(A.pinia);let w="$R";const{originalPath:b}=A.storeToRefs(x),S=b.value,$=e.computed(()=>{var v;const p=(v=te.getAllLeafNodes(F.value)||[])==null?void 0:v.filter(T=>(T==null?void 0:T.type)!=="operate"&&(T==null?void 0:T.label)!=="操作"&&(T==null?void 0:T.prop)!=="operate");return p.length>0?p.every(T=>!!(T!=null&&T.sortable)):!1});e.computed(()=>{var v;return(v=F.value)==null?void 0:v.every(T=>T==null?void 0:T.filterable)}),e.computed(()=>{var v;return(v=F.value)==null?void 0:v.every(T=>T==null?void 0:T.operable)});const V=e.ref(!0),le=e.ref([]),X=e.reactive({column:{},status:!1,text:"合计"}),me=e.reactive({currentPage:1,pageSize:10,total:0,pageSizes:[5,10,20]}),Be=l,F=e.ref([]),ie=e.ref([]),Y=e.ref([]),ce=e.reactive({prop:"",order:null}),Ce=e.ref([]),Fe=e.ref(!1),fe=e.ref(!1),N=e.ref(null),{isUseBackdrop:se,initTrackFileType:U,getFileExtension:_e,setData:Ie,getFileInfo:je,getFilesInfo:na}=Bo.useThreeSystem(),Ca=e.ref([]),ee=e.ref(!1),ca=e.ref(),de=A.useMenuState(),{importLoading:pa,activeMenuPath:we,contentLoading:ue,linkMenuInfo:De}=A.storeToRefs(de),Ge=te.useTableComp(A.pinia),ua=A.useModelComp(A.pinia),Ja=Yn(A.pinia),{extraContents:R,cacheUpdatingData:H,tableViewContents:J,tableLoading:he,pageMapState:pe,lockingPage:ha}=A.storeToRefs(ua),{selectTab:ta}=A.storeToRefs(Ja),{compType:He,hasEditable:_a}=Qs.useRole(),ze=e.ref([]),ma=e.ref([]),Oa=e.ref(new Map);e.ref(!1);const Ma=e.ref("");e.ref();const fa=e.ref(!0),Ba=e.ref(0),Te=e.ref(!0),ye=e.ref(""),Ne=e.ref(!1),ae=e.ref(null);e.ref([]);const oe=e.ref({label:"查看三维模型"}),Xe=e.ref(!1),Ze=e.ref(),Pa=e.ref([]),Sa=e.ref([]),Xa=e.ref(!1),Ve=e.ref([]),Re=e.ref([]),We=e.ref([]),Ae=e.ref([]),Me=e.ref([]),cl=()=>{try{const p=localStorage.getItem(Ss),v=p?JSON.parse(p):[];Me.value=Array.isArray(v)?v:[]}catch{Me.value=[]}},wl=()=>{try{localStorage.setItem(Ss,JSON.stringify(Me.value||[]))}catch{}},Cl=p=>{var ne,re,q;if(!p)return;const v=p.url||((ne=p==null?void 0:p.uploadResult)==null?void 0:ne.url)||"",T=p.name||((re=p==null?void 0:p.uploadResult)==null?void 0:re.name)||((q=p==null?void 0:p.uploadResult)==null?void 0:q.fileName)||"";if(!v&&!T)return;const z={name:T,url:v,ts:Date.now()},P=String(z.name||"").trim().toLowerCase(),D=(Me.value||[]).findIndex(be=>String((be==null?void 0:be.name)||"").trim().toLowerCase()===P);D>-1&&Me.value.splice(D,1),Me.value.unshift(z),Me.value.length>20&&(Me.value=Me.value.slice(0,20)),wl()};cl();const Pl=(p,v)=>`${H3}:${String(p??"")}:${String(v??"")}`,Sl=(p,v)=>{try{const T=sessionStorage.getItem(Pl(p,v)),z=T?JSON.parse(T):[];return Array.isArray(z)?z:[]}catch{return[]}},Gl=(p,v,T)=>{try{sessionStorage.setItem(Pl(p,v),JSON.stringify(Array.isArray(T)?T:[]))}catch{}},aa=(p,v,T)=>{if(!v)return;const z=Sl(p,v),P=[T,...z||[]].filter(Boolean).slice(0,1);return Gl(p,v,P),P},Ha=(p,v,T)=>{if(!v||!T)return;const z=Pl(p,v),P=Pl(p,T);try{const D=sessionStorage.getItem(z);if(!D)return;const ne=(()=>{try{const be=JSON.parse(D);return Array.isArray(be)?be:[]}catch{return[]}})(),re=Sl(p,T),q=[...ne,...re||[]].filter(Boolean).sort((be,Ee)=>Number((Ee==null?void 0:Ee.ts)||0)-Number((be==null?void 0:be.ts)||0)).slice(0,1);sessionStorage.setItem(P,JSON.stringify(q)),sessionStorage.removeItem(z)}catch{}},ya=e.ref(!1),rl=e.ref(!1),Aa=e.ref([]),ol=e.ref(null);e.ref(!1),e.ref([]),e.ref(""),e.ref("");const al=e.ref(!1),ke=e.ref([]),Ia=e.ref(1),$a=e.ref(new Map),Z=e.ref(new Map),la=e.ref(0),ba=e.ref(!1),Ke=e.ref([]),Ua=e.ref([]),ga=p=>{var v;try{const T=(v=te.getAllLeafNodes(F.value)||[])==null?void 0:v.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate");return(T==null?void 0:T.find(z=>(z==null?void 0:z.prop)===p||(z==null?void 0:z.label)===p))||null}catch{return null}},tl=p=>{const v=ga(p),T=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"Input";return sl.getComponent(T)||sl.getComponent("Input")},Le=e.ref([]),ia=e.ref(null),va=e.ref([]),ll=e.ref(null),Pe=e.ref(""),Dl=e.ref(!1),Wa=e.ref([]),ml=e.ref(""),nr=e.ref(!1),_r=e.ref([]),jl=e.ref([]),pr=e.ref([]),Sr=e.ref(null),Cr=e.ref([]),Oe=e.ref("");e.computed(()=>{var p;try{const v=(p=te.getAllLeafNodes(F.value)||[])==null?void 0:p.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate"),T=new Map;return v==null||v.forEach(z=>{z!=null&&z.label&&(z!=null&&z.prop)&&T.set(z.label,z.prop)}),T.get("编号")||""}catch{return""}});const er=e.computed(()=>{var p;try{const v=(p=te.getAllLeafNodes(F.value)||[])==null?void 0:p.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate"),T=new Map;return v==null||v.forEach(z=>{z!=null&&z.label&&(z!=null&&z.prop)&&T.set(z.label,z.prop)}),T.get("名称")||""}catch{return""}}),gr=e.computed(()=>{var p;try{const v=(p=te.getAllLeafNodes(F.value)||[])==null?void 0:p.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate"),T=new Map;return v==null||v.forEach(z=>{z!=null&&z.label&&(z!=null&&z.prop)&&T.set(z.label,z.prop)}),T.get("制造厂")||""}catch{return""}}),Dr=()=>{nr.value=!1,_r.value=[],jl.value=[],pr.value=[],Sr.value=null,Cr.value=[],Oe.value=""},Bl=p=>p==null?!1:typeof p=="string"?p.trim()!=="":Array.isArray(p)?p.length>0:!0,$r=(p,v)=>{const T=(p==null?void 0:p.ocrRow)||{};for(const P of Object.keys(T))P==="id"||P==="_isOCRRow"||P==="_ocrTableId"||Bl(T[P])&&(v[P]=T[P]);const z=ma.value.find(P=>P.id===v.id);if(z)for(const P of Object.keys(T))P==="id"||P==="_isOCRRow"||P==="_ocrTableId"||Bl(T[P])&&(z[P]=T[P]);Oa.value&&Oa.value.set(v.id,v),aa(u==null?void 0:u.index,v.id,p==null?void 0:p.versionItem),jl.value=[...jl.value||[],JSON.parse(JSON.stringify(v))]},Ur=async(p,v=null)=>{var T,z,P,D,ne,re,q;try{const be=(T=te.getAllLeafNodes(F.value)||[])==null?void 0:T.filter(xa=>(xa==null?void 0:xa.type)!=="operate"&&(xa==null?void 0:xa.label)!=="操作"&&(xa==null?void 0:xa.prop)!=="operate"),Ee=new Map;be==null||be.forEach(xa=>{xa!=null&&xa.label&&(xa!=null&&xa.prop)&&Ee.set(xa.label,xa.prop)});const Ye=Ee.get("系统编号")||Ee.get("编号");if(!Ye){console.warn("未找到系统编号字段,跳过向检校记录表插入数据");return}const qe=v||Sr.value;if((Array.isArray(qe==null?void 0:qe.result)?qe.result:[]).length===0){console.warn("OCR识别结果为空,跳过向检校记录表插入数据");return}for(let xa=0;xa<p.length;xa++){const za=p[xa],La=za[Ye];if(!La){console.warn(`第 ${xa+1} 条匹配行缺少系统编号,跳过`);continue}const ea=`设备管理/试验设备/${La}`,Qa=await A.getPageDataApi({platId:parseInt((z=hl.value)==null?void 0:z.plat_id),pageName:ea});if(!((P=Qa==null?void 0:Qa.data)!=null&&P.result)||!Array.isArray(Qa.data.result)){console.warn(`未找到详情页数据: ${ea}`);continue}const wa=Qa.data.result.find(sa=>(sa==null?void 0:sa.property_name)==="校检记录");if(!wa){console.warn(`详情页 ${ea} 中未找到校检记录表`);continue}const el=(D=wa.contents)==null?void 0:D.find(sa=>(sa==null?void 0:sa.key)&&sa.key.startsWith("content_"));if(!el||!el.key){console.warn("校检记录表中未找到 content item");continue}const ve=el.key,Ra=Array.isArray(el.value)?el.value:[];if(Ra.length>=5){const xe=[...Ra].sort((da,Na)=>{const il=Number((da==null?void 0:da.create_time)||0),qa=Number((Na==null?void 0:Na.create_time)||0);return il-qa})[0];xe!=null&&xe.id&&await A.pageBatchDeleteApi({platId:parseInt((ne=hl.value)==null?void 0:ne.plat_id),changeContents:[{tableName:ve,tableContents:[{id:xe.id}]}]})}const ka=(re=be==null?void 0:be.find(sa=>(sa==null?void 0:sa.label)==="证书附件"))==null?void 0:re.prop,Da=String(Date.now()),Ea={id:Da},B=Ra[0]||{},G=new Date().toISOString().split("T")[0];if(Object.keys(B||{}).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]??""}}),ka&&za[ka]){const sa=za[ka];if(Array.isArray(sa)&&sa.length>0)Ea.证书附件=JSON.stringify(sa.map(xe=>({url:(xe==null?void 0:xe.url)||"",name:(xe==null?void 0:xe.name)||(xe==null?void 0:xe.fileName)||"",fileName:(xe==null?void 0:xe.fileName)||(xe==null?void 0:xe.name)||""})).filter(xe=>xe.url||xe.name));else if(typeof sa=="string")try{const xe=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=hl.value)==null?void 0:q.plat_id),changeContents:[{tableName:ve,tableContents:[Ea]}]});const $e=wa==null?void 0:wa.object_id;if($e&&Da){const sa=ka&&za[ka]?za[ka]:null;let xe=[],da="",Na=!1;if(Array.isArray(sa)&&sa.length>0){xe=sa.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);const qa=sa[0];da=(qa==null?void 0:qa.url)||"";const pl=(qa==null?void 0:qa.name)||(qa==null?void 0:qa.fileName)||"";Na=String(pl).toLowerCase().endsWith(".pdf")||String(da).toLowerCase().endsWith(".pdf")}else if(typeof sa=="string")try{const qa=JSON.parse(sa);Array.isArray(qa)?(xe=qa.map(pl=>({name:(pl==null?void 0:pl.name)||(pl==null?void 0:pl.fileName)||"",url:(pl==null?void 0:pl.url)||""})).filter(pl=>pl.url||pl.name),xe.length>0&&(da=xe[0].url||"",Na=String(xe[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 il={ts:Date.now(),versionId:String(Date.now())+"_"+String(xa),label:new Date().toLocaleString(),certType:za.证书类型||"",certNo:za.证书编号||"",fileType:Na?"pdf":"image",sourceUrl:Na?da:"",images:xe};aa($e,Da,il)}}}catch(be){console.error("向校检记录表插入OCR识别结果失败:",be),ja.ElMessage.error("向校检记录表插入数据失败,请查看控制台")}},Hl=p=>{const v=Array.isArray(p)?p:_r.value||[];if(v.length===0){Dr();return}if(v.find(D=>(D==null?void 0:D.__decision)==="replace"&&!(D!=null&&D.selectedTargetId))){ja.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}v.forEach(D=>{var re;const ne=D==null?void 0:D.__decision;if(!(!ne||ne==="skip")){if(ne==="add"){aa(u==null?void 0:u.index,(re=D==null?void 0:D.ocrRow)==null?void 0:re.id,D==null?void 0:D.versionItem),pr.value=[...pr.value||[],D.ocrRow];return}if(ne==="replace"){const q=D==null?void 0:D.selectedTargetId,be=(ze.value||[]).find(Ee=>String(Ee==null?void 0:Ee.id)===String(q));if(!be)return;$r(D,be)}}}),(jl.value||[]).length>0&&(ze.value=[...ze.value||[]]),(pr.value||[]).length>0&&(ze.value=[...ze.value||[],...pr.value||[]],ma.value=[...ma.value||[],...pr.value||[]],(pr.value||[]).forEach(D=>{var ne,re;return(re=(ne=Oa.value)==null?void 0:ne.set)==null?void 0:re.call(ne,D.id,D)})),jr.value=ze.value;const z=jl.value||[],P=pr.value||[];if(z.length>0&&(Be("change",{buttonName:"编辑",singleContent:z,content:ze.value,relatedContents:u==null?void 0:u.related,index:u==null?void 0:u.index,parentTableId:u==null?void 0:u.parentTableId,columns:F.value,name:u==null?void 0:u.compName}),Ur(z)),P.length>0){const D=Sr.value;Be("change",{buttonName:"OCR批量新增",content:ze.value,index:u==null?void 0:u.index,parentTableId:u==null?void 0:u.parentTableId,column:F.value,ocrRows:P,relatedContents:u==null?void 0:u.related,uploadedFiles:(Array.isArray(D==null?void 0:D.result)?D.result:[]).map(ne=>(Array.isArray(ne==null?void 0:ne.图片信息)?ne.图片信息:[]).map(re=>({url:(re==null?void 0:re.url)||"",name:(re==null?void 0:re.name)||"",fileName:(re==null?void 0:re.name)||""})).filter(re=>re.url)),ocrResult:D,matchedCount:(z||[]).length,newCount:(P||[]).length})}ja.ElMessage.success("已提交候选处理结果"),Dr()},yr=bc(),vn=e.computed(()=>yr.getConfig()),hr=e.ref(),Al=e.ref(),sn=hc(A.pinia),jr=e.ref(),qr=e.ref(0),Kr=A.useUnit(A.pinia),{selectIndex:Jr,selectMenu:Wr,selectTitle:ar}=A.storeToRefs(Kr),{selectString:lr}=A.storeToRefs(sn),Xr=A.useLoginState(A.pinia),{loginUserInfo:hl}=A.storeToRefs(Xr),ir=e.ref(720),Vl=e.ref(!1),Er=e.ref(!1),ql=e.ref([]),fr=e.ref(),Vr=e.ref(!0),br=e.ref(!0);e.ref([]);const cn=e.inject("contentRef");e.provide("contentRef",cn),e.provide("getSuggestListForCell",Tu),e.provide("getSuggestLoadingForCell",(p,v)=>{const T=`${p==null?void 0:p.id}:${(v==null?void 0:v.prop)||(v==null?void 0:v.property)}`;return g.value.get(T)||!1}),e.watch(()=>{var p;return(p=ze.value)==null?void 0:p.length},p=>{me.total=p}),e.watch(()=>J.value,async()=>{var v,T,z,P,D,ne,re,q,be,Ee,Ye,qe,Qe,xa,za,La,ea;if(((v=J.value)==null?void 0:v.length)===0||!((T=u==null?void 0:u.itemData)!=null&&T.find(Qa=>(Qa==null?void 0:Qa.key)==="columnPath"))||!((z=u==null?void 0:u.itemData)!=null&&z.find(Qa=>(Qa==null?void 0:Qa.key)==="pageColumn")))return;let p=(be=(q=(re=(ne=(D=(P=u==null?void 0:u.itemData)==null?void 0:P.find(Qa=>(Qa==null?void 0:Qa.key)==="pageColumn"))==null?void 0:D.contents)==null?void 0:ne.split("["))==null?void 0:re[1])==null?void 0:q.split("]"))==null?void 0:be[0];((Qe=(qe=(Ye=(Ee=u==null?void 0:u.itemData)==null?void 0:Ee.find(Qa=>(Qa==null?void 0:Qa.key)==="pageColumn"))==null?void 0:Ye.contents)==null?void 0:qe.split("["))==null?void 0:Qe[0])+((za=(xa=J.value)==null?void 0:xa.find(Qa=>(Qa==null?void 0:Qa.key)===p))==null?void 0:za.value),(ea=(La=u==null?void 0:u.itemData)==null?void 0:La.find(Qa=>(Qa==null?void 0:Qa.key)==="pageGroup"))==null||ea.contents,Ht(compData,u.allMapContents)},{deep:!0});const Zr=p=>{var T,z,P,D,ne;const v=(z=(T=F.value)==null?void 0:T.filter(re=>re==null?void 0:re.mainKey))==null?void 0:z.map(re=>re==null?void 0:re.prop);if(v.length===0){const re=(P=F.value)==null?void 0:P.map(q=>q==null?void 0:q.prop);return(D=re==null?void 0:re.map(q=>p==null?void 0:p[q]))==null?void 0:D.join("|")}return(ne=v==null?void 0:v.map(re=>p==null?void 0:p[re]))==null?void 0:ne.join("|")},Jn=p=>{var re,q,be,Ee,Ye;const v=(q=(re=F.value)==null?void 0:re.filter(qe=>qe==null?void 0:qe.required))==null?void 0:q.map(qe=>qe==null?void 0:qe.prop),T=[];if(p==null||p.forEach(qe=>{v==null||v.forEach(Qe=>{const xa=qe[Qe];(xa==null||xa==="")&&(T.includes(Qe)||T.push(Qe))})}),T.length>0)return ja.ElMessage.warning(`请填写必填项:${T.join("、")}`);const z=new Map,P=new Map;(be=ze.value)==null||be.forEach(qe=>{const Qe=Zr(qe);z.set(Qe,qe)}),p==null||p.forEach(qe=>{const Qe=Zr(qe);P.set(Qe,qe)});const D=p==null?void 0:p.filter(qe=>z.has(Zr(qe))),ne=(Ee=ze.value)==null?void 0:Ee.filter(qe=>P.has(Zr(qe)));return(D==null?void 0:D.length)>0&&(y.columns=(Ye=F.value)==null?void 0:Ye.filter(qe=>(qe==null?void 0:qe.label)!=="操作"),y.existRows=ne,y.tableData=D,y.show=!0),y.newRows=p==null?void 0:p.filter(qe=>{const Qe=Zr(qe);return!z.has(Qe)}),y.newRows},Fn=e.ref(""),Dn=e.ref(null),In=async()=>{var p,v,T,z,P,D;try{const ne=await A.quoteApi({related:[{menus:we.value,groups:u==null?void 0:u.compName}],platId:parseInt((p=hl.value)==null?void 0:p.plat_id)});if(((v=ne==null?void 0:ne.data)==null?void 0:v.code)===200){Dn.value=(T=ne==null?void 0:ne.data)==null?void 0:T.result;const re=(z=F.value)==null?void 0:z.map(Ee=>(Ee==null?void 0:Ee.prop)||(Ee==null?void 0:Ee.label)),q=jn(re,(P=ne==null?void 0:ne.data)==null?void 0:P.result),be=q==null?void 0:q.flatMap(Ee=>Ee==null?void 0:Ee.quote);(be==null?void 0:be.length)>0&&(Fn.value=(D=be==null?void 0:be.map(Ee=>Ee==null?void 0:Ee.menus))==null?void 0:D.join("、"))}}catch(ne){throw new Error(ne)}};function jn(p,v){var T;return(T=v.filter(z=>z.struct&&Array.isArray(z.struct)?z.struct.some(P=>P.words&&Array.isArray(P.words)?P.words.some(D=>p.includes(D)):!1):!1))==null?void 0:T.map(z=>{const P={...z};return P.struct&&Array.isArray(P.struct)&&(P.struct=P.struct.filter(D=>D.words&&Array.isArray(D.words)?D.words.some(ne=>p.includes(ne)):!1)),P})}const mn=async(p,v)=>{var T,z;try{Dn.value||await In();const P=v==null?void 0:v.map(ne=>{const re=Object.keys(ne),q={};return re.forEach((be,Ee)=>{q[p[Ee]]=ne[be]}),q}),D=Jn(P);if(!D||(D==null?void 0:D.length)===0)return;y.show||await O(D)}catch(P){throw ja.ElMessage.error("数据导入处理失败"),await A.pageBatchAddApi({platId:parseInt((T=hl==null?void 0:hl.value)==null?void 0:T.plat_id),changeContents:[{tableName:"log",tableContents:[{id:"1",request_method:"Post",request_url:"",request_param:JSON.stringify(t1),request_result:JSON.stringify(P),is_delete:!1,request_table:(z=u==null?void 0:u.related)==null?void 0:z.find(D=>D==null?void 0:D.includes("content")),request_type:"error"}]}]}),new Error(P)}},On=async p=>{var D,ne,re,q,be,Ee,Ye;let v=Y.value;v!=null&&v.find(qe=>(p==null?void 0:p.key)===(qe==null?void 0:qe.key))&&(v=v==null?void 0:v.filter(qe=>(p==null?void 0:p.key)!==(qe==null?void 0:qe.key))),v.push({key:p==null?void 0:p.key,value:[(ne=p==null?void 0:p.value)==null?void 0:ne[((D=p==null?void 0:p.value)==null?void 0:D.length)-1]]});let T=Ae.value;T=T==null?void 0:T.map(qe=>{var Qe,xa;return(qe==null?void 0:qe.type)==="Select"&&(p==null?void 0:p.key)===(qe==null?void 0:qe.prop)&&Array.isArray(qe.value)&&(Qe=qe.value)!=null&&Qe.every(za=>typeof za=="string")&&(qe.selectValue=(xa=v==null?void 0:v.find(za=>(za==null?void 0:za.key)===(qe==null?void 0:qe.prop)))==null?void 0:xa.value),qe});let z=(q=(re=T==null?void 0:T.find(qe=>(qe==null?void 0:qe.prop)===(p==null?void 0:p.key)))==null?void 0:re.optionUrl)==null?void 0:q.menuId,P=T==null?void 0:T.find(qe=>(qe==null?void 0:qe.prop)===(p==null?void 0:p.key));if(z){let qe=await _t(P==null?void 0:P.optionUrl,z),Qe,xa=le.value,za=(Ye=(Ee=(be=Ae.value)==null?void 0:be.find(La=>{var ea;return(ea=P==null?void 0:P.optionUrl)==null?void 0:ea.menuId}))==null?void 0:Ee.selectValue)==null?void 0:Ye[0];if(qe==null||qe.forEach(La=>{var ea,Qa,wa,el,ve,Ra,ka,Da,Ea,B;if(z){let G=(Qa=(ea=Ae.value)==null?void 0:ea.find(sa=>{var xe,da;return((xe=P==null?void 0:P.optionUrl)==null?void 0:xe.menuId)===((da=sa==null?void 0:sa.optionUrl)==null?void 0:da.menuId)}))==null?void 0:Qa.prop,$e=(el=(wa=T==null?void 0:T.find(sa=>(sa==null?void 0:sa.prop)===G))==null?void 0:wa.selectValue)==null?void 0:el[0];G!=null&&G.includes("·")&&(G=(ve=G==null?void 0:G.split("·"))==null?void 0:ve[0],$e=(Ea=(Da=(ka=p==null?void 0:p.value)==null?void 0:ka[((Ra=p==null?void 0:p.value)==null?void 0:Ra.length)-1])==null?void 0:Da.split(" "))==null?void 0:Ea[0]),xa!=null&&xa.find(sa=>(sa==null?void 0:sa.value)===za)?Qe=(B=xa==null?void 0:xa.find(sa=>(sa==null?void 0:sa.value)===za))==null?void 0:B.objectValue:La[G]===$e&&(Qe=La)}}),Qe){let La=T;La=La==null?void 0:La.map(ea=>{var Qa,wa,el,ve,Ra,ka;return z&&(Qe!=null&&Qe[ea==null?void 0:ea.prop])&&ye.value==="新增"&&(ea==null?void 0:ea.prop)!==(P==null?void 0:P.prop)?ea.value=(Qe==null?void 0:Qe[ea==null?void 0:ea.prop])||(Qe==null?void 0:Qe[(ve=(el=(wa=(Qa=ea==null?void 0:ea.optionUrl)==null?void 0:Qa.groupSelect)==null?void 0:wa[1])==null?void 0:el.replaceAll("[",""))==null?void 0:ve.replaceAll("]","")]):ea.value=(ka=(Ra=Ae.value)==null?void 0:Ra.find(Da=>(Da==null?void 0:Da.prop)===(ea==null?void 0:ea.prop)))==null?void 0:ka.value,ea}),Ae.value=La}}Y.value=v},Xn=async(p,v)=>{var T,z,P,D,ne;if((T=p==null?void 0:p.toString())!=null&&T.includes(".txt")||(z=p==null?void 0:p.toString())!=null&&z.includes(".cpt")||(P=p==null?void 0:p.toString())!=null&&P.includes(".cyd")){const re=await ja.axios.get(p,{responseType:"blob",headers:{"Content-Type":"application/json"}}),q=new Blob([re.data],{type:"application/octet-stream;charset=UTF-8"});let be=URL.createObjectURL(q);ca.value=[{name:(ne=p==null?void 0:p.split("/"))==null?void 0:ne[((D=p==null?void 0:p.split("/"))==null?void 0:D.length)-1],blobUrl:be}],ee.value=!0}else Array.isArray(v)&&(v==null?void 0:v.length)>0&&Be("routeUrl",{isEdit:!1,routerUrl:v})};e.onBeforeUnmount(()=>{br.value=!1;let p=qr.value;qr.value=p+1});const Gr=e.reactive({prop:"",order:null}),Zn=e.computed(()=>{const p=(ze.value??[]).slice(),v=Gr.prop||ce.prop,T=Gr.order||ce.order;if(!v||!T)return p;const z=T==="ascending",P=ne=>{if(v)return ne&&Object.prototype.hasOwnProperty.call(ne,v)?ne[v]:v.includes(".")?v.split(".").reduce((re,q)=>re==null?re:re[q],ne):ne==null?void 0:ne[v]},D=ne=>{if(ne==null)return{ok:!1,value:NaN};if(typeof ne=="number")return{ok:Number.isFinite(ne),value:ne};const re=String(ne).trim();if(re==="")return{ok:!1,value:NaN};const q=re.replace(/[,\s]/g,"");if(!/^[+-]?(\d+\.?\d*|\.\d+)$/.test(q))return{ok:!1,value:NaN};const be=Number(q);return{ok:Number.isFinite(be),value:be}};return p.sort((ne,re)=>{const q=P(ne),be=P(re);if(q==null&&be==null)return 0;if(q==null)return z?-1:1;if(be==null)return z?1:-1;const Ee=D(q),Ye=D(be);if(Ee.ok&&Ye.ok)return z?Ee.value-Ye.value:Ye.value-Ee.value;const qe=ve=>{if(ve==null)return{ok:!1,value:NaN};const Ra=String(ve).trim();if(Ra==="")return{ok:!1,value:NaN};const ka=Ra.match(/^(-)?(\d+):(\d{1,2}):(\d{1,2})$/);if(!ka)return{ok:!1,value:NaN};const Da=ka[1]?-1:1,Ea=Number(ka[2]),B=Number(ka[3]),G=Number(ka[4]);return[Ea,B,G].some($e=>Number.isNaN($e))?{ok:!1,value:NaN}:B>=60||G>=60?{ok:!1,value:NaN}:{ok:!0,value:Da*(Ea*3600+B*60+G)}},Qe=qe(q),xa=qe(be);if(Qe.ok&&xa.ok)return z?Qe.value-xa.value:xa.value-Qe.value;const za=new Date(q).getTime(),La=new Date(be).getTime(),ea=!Number.isNaN(za),Qa=!Number.isNaN(La);if(ea&&Qa)return z?za-La:La-za;const wa=String(q),el=String(be);return z?wa.localeCompare(el):el.localeCompare(wa)})}),_n=e.computed(()=>{var T;const p=(me.currentPage-1)*me.pageSize,v=p+me.pageSize;return Be("getSliceContLength",me),(T=Zn.value)==null?void 0:T.slice(p,v)}),Mi=p=>{me.currentPage=p,Be("getSliceContLength",me)},jo=p=>{var z;me.pageSize=p;const v=((z=ze.value)==null?void 0:z.length)??0,T=p>0?Math.ceil(v/p):1;me.currentPage>T&&(me.currentPage=T||1,ja.ElMessage.warning("当前页超出范围,已自动跳转到最后一页")),Be("getSliceContLength",me)},Ho=({prop:p,order:v})=>{Gr.prop=p,Gr.order=v,me.currentPage=1};function Nn(p){const v=[];function T(z,P=""){z.forEach(D=>{D.children&&D.children.length>0?T(D.children,D.prop):v.push(D.prop)})}return T(p),v}const Uo=(p,v)=>{var re,q,be,Ee;let T=(q=(re=F.value)==null?void 0:re.map(Ye=>Ye==null?void 0:Ye.prop))==null?void 0:q.filter(Ye=>Ye!=="operate");((be=F.value)==null?void 0:be.some(Ye=>{var qe;return((qe=Ye==null?void 0:Ye.children)==null?void 0:qe.length)>0}))&&(T=Nn((Ee=F.value)==null?void 0:Ee.filter(Ye=>(Ye==null?void 0:Ye.prop)!=="operate")));let P;if(P=(p==null?void 0:p.length)===(T==null?void 0:T.length)?p:p.slice(0,T==null?void 0:T.length),!(P==null?void 0:P.every(Ye=>T==null?void 0:T.find(qe=>Ye===qe))))return ja.ElMessage.error("导入的数据表头不匹配");mn(P,v)},qo=(p,v)=>{var P;const T=p==null?void 0:p.filter(D=>D!=="序号"),z=v==null?void 0:v.map(D=>{const ne=Object.entries(D);return ne.shift(),Object.fromEntries(ne)});ua.setRefreshCurStructure(!1),((P=F.value)==null?void 0:P.length)===0||Uo(T,z)},Wo=(p,v,T,z)=>{const P=[],D=[],ne=be=>Object.keys(be).length;for(const be in p)if(p[be]!==void 0){const Ee=p[be],Ye=[];for(const[qe,Qe]of Object.entries(Ee))Ye.push(Qe),D.length<ne(Ee)&&D.push(qe);P.push(Ye)}P.unshift(D);const re=te.utils.aoa_to_sheet(P),q=te.utils.book_new();te.utils.book_append_sheet(q,re,z),te.writeFileSync(q,`${v}.xlsx`),ql.value=[]},Ii=async(p,v,T,z=!1,P)=>{try{ua.setRefreshCurStructure(!1)}catch(D){ja.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 P;if(!_a(u.config,{type:He.TABLE}))return;const z=(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(z,ze.value||[]))}catch{}ze.value.splice(z,0,p),await e.nextTick(),h.value.has(p.id)||h.value.set(p.id,A.cloneDeep(p)),ze.value=(P=ze.value)==null?void 0:P.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),Vl.value=!0},Go=(p,v,T,z=[])=>(!Array.isArray(v)||v.length===0||v.forEach(P=>{const D=P==null?void 0:P.prop;if(!D)return;let ne=p==null?void 0:p[D];if(ne==null||String(ne).trim()==="")return;ne=String(ne);const re=new Set([...(Array.isArray(T)?T:[]).filter(Ee=>(Ee==null?void 0:Ee.id)!==(p==null?void 0:p.id)).map(Ee=>Ee==null?void 0:Ee[D]).filter(Ee=>Ee!=null).map(Ee=>String(Ee)),...(Array.isArray(z)?z:[]).map(Ee=>Ee==null?void 0:Ee[D]).filter(Ee=>Ee!=null).map(Ee=>String(Ee))]);if(!re.has(ne))return;let q=1,be="";for(;be=`${ne}(${q})`,!!re.has(be);)q++;p[D]=be}),p),Oi=async()=>{var P,D,ne,re,q,be,Ee,Ye;const p=Array.from(s.value||[]);if(p.length===0)return;const v=(D=te.getColumnChild((P=A.cloneDeep(F.value))==null?void 0:P.filter(qe=>(qe==null?void 0:qe.label)!=="操作")))==null?void 0:D.filter(qe=>(qe==null?void 0:qe.required)===!0);if((v==null?void 0:v.length)>0)for(let qe=0;qe<p.length;qe++){const Qe=p[qe],xa=(ne=ze.value)==null?void 0:ne.find(za=>(za==null?void 0:za.id)===Qe);if(xa)for(let za=0;za<v.length;za++){const La=v[za],ea=La==null?void 0:La.prop,Qa=(La==null?void 0:La.label)??ea,wa=xa==null?void 0:xa[ea];if(wa===""||wa===null||wa===void 0||Array.isArray(wa)&&wa.length===0){ja.ElMessage.error(`${Qa}不能为空`);let ve={};ve.id=xa==null?void 0:xa.id;const Ra={fixContent:[ve],buttonName:"修改",relatedContents:u==null?void 0:u.related,name:u==null?void 0:u.compName,columns:F.value};Be("change",Ra);return}}}const T=[],z=[];if(p.forEach(qe=>{var Qa;const Qe=(Qa=ze.value)==null?void 0:Qa.find(wa=>(wa==null?void 0:wa.id)===qe);if(!Qe)return;if(Qe!=null&&Qe._isTemp){const el=(te.getAllLeafNodes(F.value)||[]).filter(B=>(B==null?void 0:B.mainKey)===!0||(B==null?void 0:B.isMainKey)===!0),ve=ze.value.findIndex(B=>(B==null?void 0:B.id)===qe),Ra=ve>=0?ve+1:ze.value.length+1;Go(Qe,el,ze.value,T);const ka={id:Ra.toString()};(Qe==null?void 0:Qe.sort)!==void 0&&(Qe==null?void 0:Qe.sort)!==null&&String(Qe.sort).trim()!==""?ka.sort=String(Qe.sort):ka.sort=ri(ve>=0?ve:ze.value.length-1,ze.value||[]),(te.getAllLeafNodes(F.value)||[]).filter(B=>(B==null?void 0:B.type)!=="operate"&&(B==null?void 0:B.label)!=="操作"&&(B==null?void 0:B.prop)!=="operate").forEach(B=>{const G=B==null?void 0:B.prop;if(G){const $e=Qe[G];$e!==void 0?ka[G]=$e??"":ka[G]=""}}),T.push(ka);return}const za=(te.getAllLeafNodes(F.value)||[]).filter(wa=>(wa==null?void 0:wa.type)!=="operate"&&(wa==null?void 0:wa.label)!=="操作"&&(wa==null?void 0:wa.prop)!=="operate"),La=new Set(za.map(wa=>wa==null?void 0:wa.prop).filter(Boolean)),ea={};for(const wa of La)Object.prototype.hasOwnProperty.call(Qe,wa)&&(ea[wa]=Qe[wa]);z.push({id:Qe.id,value:{tableData:ea}})}),ua.setTableLoading(u==null?void 0:u.index),z.length>0){const qe=z.map(xa=>{const za={id:xa.id,...xa.value.tableData};return delete za._isOCRRow,delete za._ocrTableId,delete za._isTemp,delete za.tableEditType,delete za.index,za}),Qe=[{tableName:((re=u==null?void 0:u.related)==null?void 0:re.find(xa=>xa==null?void 0:xa.includes("content")))??"content_"+(u==null?void 0:u.index),tableContents:qe}];try{await A.pageBatchUpdateApi({platId:parseInt((q=hl.value)==null?void 0:q.plat_id),changeContents:Qe})}catch(xa){ja.ElMessage.error(((Ee=(be=xa==null?void 0:xa.response)==null?void 0:be.data)==null?void 0:Ee.message)||(xa==null?void 0:xa.message)||"保存失败"),ua.setTableLoading(!1);return}}if(T.length>0){const qe={fixContent:T,buttonName:"新增",relatedContents:u==null?void 0:u.related,name:u==null?void 0:u.compName,columns:F.value};Be("change",qe)}ja.ElMessage.success("保存成功"),s.value.clear(),h.value.clear(),ze.value=(Ye=ze.value)==null?void 0:Ye.map(qe=>({...qe,tableEditType:"text"})),Vl.value=!1,ua.setRefreshCurStructure(!0)},Yo=()=>{var v;const p=Array.from(s.value||[]);if(p.length===0){Vl.value=!1;return}p.forEach(T=>{var D,ne;const z=h.value.get(T),P=(D=ze.value)==null?void 0:D.find(re=>(re==null?void 0:re.id)===T);if(P!=null&&P._isTemp){ze.value=ze.value.filter(re=>(re==null?void 0:re.id)!==P.id);return}if(z){const re=(ne=ze.value)==null?void 0:ne.findIndex(q=>(q==null?void 0:q.id)===T);re!==-1&&(ze.value[re]={...ze.value[re],...z})}}),s.value.clear(),h.value.clear(),ze.value=(v=ze.value)==null?void 0:v.map(T=>({...T,tableEditType:"text"})),Vl.value=!1},Li=e.ref(!1),ao=async p=>{var P,D,ne,re;if(!Vl.value||p!=null&&p.isComposing||(p==null?void 0:p.key)!=="Enter")return;const v=p==null?void 0:p.target;if(((D=(P=v==null?void 0:v.tagName)==null?void 0:P.toLowerCase)==null?void 0:D.call(P))==="textarea")return;const z=document.getElementById("excel-table");z&&!z.contains(v)||((ne=v==null?void 0:v.blur)==null||ne.call(v),(re=p.preventDefault)==null||re.call(p),await e.nextTick(),await lo())},lo=async()=>{if(H.value){Vl.value=!1;return}if(!Li.value){Li.value=!0;try{Array.from(s.value||[]).length>0?await Oi():Vl.value=!1}finally{Promise.resolve().then(()=>{Li.value=!1})}}},Jo=p=>{ql.value=p},ro=(p,v)=>{fr.value===v?Vr.value=!1:Vr.value=!0,fr.value=v==null?void 0:v.changeProp},hi=p=>{if(!p)return;const{item:v,value:T}=p,z=Ae.value.find(P=>P.prop==v.prop);z&&z.contents.push({label:T,value:T})},bn=e.computed(()=>{var T,z,P;const p=(T=F.value)==null?void 0:T.some(D=>D==null?void 0:D.filterable);return document.documentElement.style.setProperty("--ssTable-header-filter-display",p?"inline-block":"none"),(P=(z=F.value)==null?void 0:z.filter(D=>(D==null?void 0:D.label)!=="操作"))==null?void 0:P.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,T)=>{const z=A.cloneDeep(F.value);await e.nextTick();const P=z==null?void 0:z.map(ne=>(T==null?void 0:T.label)===(ne==null?void 0:ne.label)?{...ne,[v]:p}:ne),D=Ri(P);await bs(u.index,D),F.value=P,ie.value=D},Ri=p=>{var P;const v=p||[];return((P=te.getAllLeafNodes(v)||[])==null?void 0:P.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:ne}=D;return u0(ne,D)})},no=async p=>{let v=await p0(u.index);v||(v=Ri(p)),ie.value=v},io=async(p,v)=>{const T=A.cloneDeep(F.value),z=ne=>Array.isArray(ne)?ne.map(re=>{const q=Array.isArray(re==null?void 0:re.children)&&re.children.length>0,be={...re};return(be==null?void 0:be.prop)==="operate"||(be==null?void 0:be.label)==="操作"||(be==null?void 0:be.type)==="operate"?(be.sortable=!1,be.filterable=!1,be.operable=!1):be.sortable=q?!1:!!p,q&&(be.children=z(be.children)),be}):ne,P=z(T),D=Ri(P);await bs(u.index,D),F.value=P,ie.value=D,await e.nextTick(),qr.value=qr.value+1},oo=()=>{Ne.value=!1},ei=p=>{Be("clickTrigger",p)},to=async p=>{var D,ne,re,q,be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa,wa;const v=p==null?void 0:p.row,T=p==null?void 0:p.rowData,z=p==null?void 0:p.suffix;if((D=v==null?void 0:v.toString())!=null&&D.includes(".urdf")||p!=null&&p.isUrdf||z!=null&&z.includes(".urdf")){if(v.includes(",")){ja.ElMessage.error("当前版本仅允许单个urdf预览!");return}if(se(v)){const ve={files:[je(v)],data:{}};Ie(ve);return}Ve.value=[{url:v,extension:_e(v)}],fe.value=!0,N.value={data:A.cloneDeep(T)},Fe.value=!0;return}let P=[];if((ne=v==null?void 0:v.toString())!=null&&ne.includes(".stl")||(re=v==null?void 0:v.toString())!=null&&re.includes(".STL")||(q=v==null?void 0:v.toString())!=null&&q.includes(".obj")||(be=v==null?void 0:v.toString())!=null&&be.includes(".mtl")){const el=(Ee=v==null?void 0:v.toString())==null?void 0:Ee.split(","),ve=na(el),Ra=ve==null?void 0:ve[0];if(se(Ra==null?void 0:Ra.extension)){Ie({files:ve,data:{}});return}Ve.value=ve,fe.value=!1,Fe.value=!0;return}if((Ye=v==null?void 0:v.toString())!=null&&Ye.includes(".stl")||(qe=v==null?void 0:v.toString())!=null&&qe.includes(".STL")||(Qe=v==null?void 0:v.toString())!=null&&Qe.includes(".obj")||(xa=v==null?void 0:v.toString())!=null&&xa.includes(".mtl")||z!=null&&z.includes(".stl")||z!=null&&z.includes(".STL")||z!=null&&z.includes(".obj")||z!=null&&z.includes(".mtl")){let el,ve=[],Ra={};if(Array.isArray(v)?el=v:el=v==null?void 0:v.split(","),el==null||el.forEach(ka=>{ka.includes(".mtl")?ve.push(ka):Ra.blob=Ra.blob?Ra.blob+","+ka:ka}),(ve==null?void 0:ve.length)>0&&(Ra.mtlBlobs=ve),z&&(Ra.suffix=z),(La=(za=Object.values(Ra))==null?void 0:za[0])!=null&&La.includes("http:"))P.push(Ra);else{const ka=new Blob([Ra.blob],{type:"application/octet-stream;charset=UTF-8"});let Da=URL.createObjectURL(ka),Ea="";(ea=v==null?void 0:v.split("/"))==null||ea.forEach((B,G)=>{var $e;G===(($e=v==null?void 0:v.split("/"))==null?void 0:$e.length)-1&&(Ea=B)}),(Qa=Ra.blob)!=null&&Qa.includes(".stl")&&(Ea=(Ea==null?void 0:Ea.replaceAll(">",""))+".urdf"),ca.value=[{name:Ea,blobUrl:Da}],ee.value=!0}}else{const el=await ja.axios.get(v,{responseType:"blob",headers:{"Content-Type":"application/json"}}),ve=new Blob([el.data],{type:"application/octet-stream;charset=UTF-8"});let Ra=URL.createObjectURL(ve),ka="";if((wa=v==null?void 0:v.split("/"))==null||wa.forEach((Da,Ea)=>{var B;Ea===((B=v==null?void 0:v.split("/"))==null?void 0:B.length)-1&&(ka=Da)}),se(ka)){const Da=U(ka),Ea=je(v);Ie({files:[Ea],data:{trackFileType:Da}});return}ca.value=[{name:ka,blobUrl:Ra}],ee.value=!0}(P==null?void 0:P.length)>0&&r.setBlobUrls(P)},ai=p=>{var z,P,D,ne;if(p!=null&&p.downloadUrl)return p==null?void 0:p.name;const v=(ne=(z=p==null?void 0:p.url)==null?void 0:z.split("."))==null?void 0:ne[((D=(P=p==null?void 0:p.url)==null?void 0:P.split("."))==null?void 0:D.length)-1];return(p==null?void 0:p.name)+"."+v},so=p=>{if(!p)return"未知文件";try{const z=ai(p);if(typeof z=="string"&&z.includes("."))return z}catch{}const v=(p==null?void 0:p.fileName)||(p==null?void 0:p.name)||"未知文件",T=(p==null?void 0:p.suffix)||"";return v.includes(".")?v:`${v}${T}`},co=p=>{if(p==null||typeof p=="number"||typeof p!="string")return p;const v=p.match(/^(\d+)\_(\d+)$/);if(!v)return p;const T=Number(v[1]),z=Number(v[2]);return!Number.isFinite(T)||!Number.isFinite(z)?p:String(T*1e3+z)},li=p=>{if(p==null)return null;const v=String(p).trim();if(!v)return null;const T=Number(v);return Number.isFinite(T)?T:null},Xo=p=>{if(p==null)return null;const v=String(p).trim();if(!v)return null;if(/^\d+$/.test(v)){const P=Number(v);return Number.isFinite(P)?v.length<=10?P*1e3:P:null}const T=v.includes("T")?v:v.replace(" ","T"),z=Date.parse(T);return Number.isFinite(z)?z:null},vi=(p,v=[])=>{const T=Array.isArray(p)?p.slice():[];if(T.length<=1)return T;const z=new Map((v||[]).map((ne,re)=>[String(ne),re])),P=T.some(ne=>li(ne==null?void 0:ne.sort)!==null),D=T.map((ne,re)=>({r:ne,idx:re,id:String((ne==null?void 0:ne.id)??""),sortVal:li(ne==null?void 0:ne.sort),createTimeMs:Xo(ne==null?void 0:ne.create_time),prevIdx:z.has(String(ne==null?void 0:ne.id))?z.get(String(ne==null?void 0:ne.id)):Number.POSITIVE_INFINITY}));return D.sort((ne,re)=>{if(P){const Ee=ne.sortVal,Ye=re.sortVal;if(Ee===null&&Ye!==null)return 1;if(Ee!==null&&Ye===null)return-1;if(Ee!==null&&Ye!==null&&Ee!==Ye)return Ee-Ye}const q=ne.createTimeMs,be=re.createTimeMs;return q!==null&&be!==null&&q!==be?be-q:q!==null&&be===null?-1:q===null&&be!==null?1:ne.prevIdx!==re.prevIdx?ne.prevIdx-re.prevIdx:ne.idx-re.idx}),D.map(ne=>ne.r)},ri=(p,v=[])=>{const T=v==null?void 0:v[p-1],z=v==null?void 0:v[p],P=li(T==null?void 0:T.sort),D=li(z==null?void 0:z.sort);let ne=null;P!==null&&D!==null&&D>P?ne=(P+D)/2:P!==null?ne=P+1:D!==null?ne=Math.max(D-1,0):ne=(p??0)+1;const re=Number(ne.toFixed(6));return String(Number.isFinite(re)?re:ne)},mi=async p=>{let v=null,T=null;if(p!=null&&p.id){const P=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),T=so(p)}finally{P.close()}}else if(p!=null&&p.downloadUrl){const P=await yi(),D=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),ne=await ja.axios.post(p==null?void 0:p.url,null,{responseType:"blob",headers:{Authorization:P,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}).finally(()=>{D.close()}),re=new Blob([ne.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(re),T=p==null?void 0:p.name}else{const P=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(P.data),T=ai(p)):v=p==null?void 0:p.url}if(se(v)){const P={row:`${v}`,suffix:_e(T)};to(P);return}const z={name:T,blobUrl:v};ca.value=[z],ee.value=!0},Zo=async p=>{let v=null,T=null;if(p!=null&&p.id){const D=await A.platformDownloadFile(p);v=URL.createObjectURL(D.data),T=so(p)}else if(p!=null&&p.downloadUrl){const D=await yi(),ne=await ja.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"}}),re=new Blob([ne.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(re),T=p==null?void 0:p.name}else{const D=await A.platformDownloadFile({url:p==null?void 0:p.url});v=URL.createObjectURL(D.data),T=ai(p)}const z={name:T,blobUrl:v},P=document.createElement("a");P.href=z.blobUrl,P.download=z.name,P.style.display="none",document.body.appendChild(P),P.click(),setTimeout(()=>{document.body.removeChild(P)},100)},$i=(p,v)=>{var z;if(Object.values(v).length===0)return;let T=p;return Object.values(v).find(P=>{var D,ne,re;return((D=P==null?void 0:P.toString())==null?void 0:D.includes(".txt"))||((ne=P==null?void 0:P.toString())==null?void 0:ne.includes(".cpt"))||((re=P==null?void 0:P.toString())==null?void 0:re.includes(".obj"))})?T=[...p,oe.value]:(z=u==null?void 0:u.config)!=null&&z.allowMove&&(T=[...p,{label:"迁移"}]),T},Qo=()=>{I.value=!0},et=e.ref([]),uo=async(p,v,T=!1)=>{var ne,re,q,be;if(!p)return;if(T){ze.value=[...Oa.value.values()].filter(Ee=>Object.values(Ee).some(Ye=>typeof Ye=="string"?Ye==null?void 0:Ye.toLowerCase().includes(v==null?void 0:v.toLowerCase()):!1));return}let z={};for(let Ee in p)(p==null?void 0:p[Ee])!==""&&(z[Ee]=p==null?void 0:p[Ee]);if(JSON.stringify(z)==="{}"){ze.value=Array.from(((ne=Oa.value)==null?void 0:ne.values())??[]);return}let P=(re=u==null?void 0:u.related)==null?void 0:re.find(Ee=>Ee==null?void 0:Ee.includes("content_")),D=await A.getFillFind({platId:parseInt((q=hl==null?void 0:hl.value)==null?void 0:q.plat_id),tableName:P,params:z});D=(be=D==null?void 0:D.data)==null?void 0:be.result,ze.value=D,ua.setTableLoading(!1)},ni=e.computed(()=>{var v,T;return((T=(v=u==null?void 0:u.itemData)==null?void 0:v.find(z=>(z==null?void 0:z.key)==="isEdit"))==null?void 0:T.contents)??!0}),An=async p=>{var z,P,D,ne;if(!_a(u.config,{type:He.TABLE})||!(((P=(z=u==null?void 0:u.itemData)==null?void 0:z.find(re=>(re==null?void 0:re.key)==="isEdit"))==null?void 0:P.contents)??!0)||!p)return;((D=Array.from(s.value))==null?void 0:D.length)>0&&await Oi();const T=p==null?void 0:p.id;T!=null&&(s.value.clear(),h.value.clear(),h.value.has(T)||h.value.set(T,A.cloneDeep(p)),ze.value=(ne=ze.value)==null?void 0:ne.map(re=>({...re,tableEditType:(re==null?void 0:re.id)===T?"edit":"text"})),s.value.add(T),Vl.value=!0)},Vi=async(p,v,T,z)=>{z!=null&&z.isExistChild&&Be("clickMainKey",p,T,F.value)},Pi=()=>{ee.value=!1},at=p=>{Be("rowClick",p)};e.watch(()=>u.changedContent,()=>{var T,z;if(!u.changedContent)return;let p=(T=ze.value)==null?void 0:T.map(P=>{var D;return P.id===((D=u.changedContent)==null?void 0:D.id)&&(P={...u.changedContent,id:u.changedContent.newId?u.changedContent.newId:u.changedContent.id},delete P.newId),P});const v=(z=u.itemData)==null?void 0:z.map(P=>((P==null?void 0:P.key)==="tableContents"&&(P.contents=p),P));ze.value=p,Be("contentChange",{contents:v,index:u.index}),Be("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=we.value,v=sessionStorage.getItem("systemKey"),T=await te.getItemData(p,v,""),z=(T==null?void 0:T.find(re=>(re==null?void 0:re.name)==="方法明细"))||(T==null?void 0:T[0]),P=(z==null?void 0:z.compData)||[],D=P==null?void 0:P.find(re=>{const q=re==null?void 0:re.key;return q==="formContent"||q==="tableContents"});return D==null?void 0:D.contents},yi=async()=>{const v=ja.Local.get("access-token");return v?`Bearer ${v}`:""},nt=async(p,{token:v,inputData:T}={})=>await ja.axios.post(p,T,{headers:{Authorization:v}}).catch(P=>(de.setImportLoading(!1),Promise.reject(P))),it=p=>{var z;let v={};const T=[];return v.form={},(z=A.cloneDeep(p))==null||z.forEach((P,D)=>{var ne,re,q,be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa,wa;if((P==null?void 0:P.comp)==="Table"){(re=(ne=P==null?void 0:P.compData)==null?void 0:ne.find(ka=>(ka==null?void 0:ka.key)==="header"))==null||re.contents;let el=(Ee=(be=(q=P==null?void 0:P.compData)==null?void 0:q.find(ka=>(ka==null?void 0:ka.key)==="tableContents"))==null?void 0:be.contents)==null?void 0:Ee.map(ka=>ka.slice(1));(za=(xa=(Qe=(qe=(Ye=P==null?void 0:P.compData)==null?void 0:Ye.find(ka=>(ka==null?void 0:ka.key)==="header"))==null?void 0:qe.contents)==null?void 0:Qe[0])==null?void 0:xa[0])==null||za.label;let ve=(ea=(La=P==null?void 0:P.compData)==null?void 0:La.find(ka=>(ka==null?void 0:ka.key)==="header"))==null?void 0:ea.contents,Ra=[];el==null||el.forEach(ka=>{let Da=[];ka==null||ka.forEach((Ea,B)=>{var $e;let G={};(($e=ve[B])==null?void 0:$e.label)!=="操作"&&(G[ve[B].label]=Ea,Da.push(G))}),Ra.push(Da)}),v[P.name]=Ra}else{const el=(wa=(Qa=P.compData)==null?void 0:Qa.find(ve=>(ve==null?void 0:ve.key)==="formContent"))==null?void 0:wa.contents;el==null||el.forEach(ve=>{var Ra,ka;if(ve.prop!==""){let Da=ve==null?void 0:ve.value;Array.isArray(Da)?Da=((Ra=Da==null?void 0:Da[0])==null?void 0:Ra.oldUrl)||"http://222.92.178.198:62001/"+((ka=Da==null?void 0:Da[0])==null?void 0:ka.url):Da=Da.toString(),ve={key:(ve==null?void 0:ve.prop)??(ve==null?void 0:ve.label),value:Da},T.push(ve)}})}}),v.form=te.getFormContents(T),v},ot=p=>{const v=[],T=z=>{z&&typeof z=="object"&&!Array.isArray(z)?Object.values(z).forEach(T):v.push(z)};return T(p),v},tt=async(p,v,T)=>{var ve,Ra,ka,Da,Ea,B,G,$e,sa,xe,da,Na,il,qa,pl,fl,Ul;de.setImportLoading(!0),ua.setFreshContent(!1);let z=await rt().catch(Fa=>(de.setImportLoading(!1),Promise.reject(Fa)));z=z==null?void 0:z.filter(Fa=>{var bl;return((bl=Fa==null?void 0:Fa.find(Va=>Va==null?void 0:Va.id))==null?void 0:bl.id)===(v==null?void 0:v.id)});let P=te.getEqualChild([(ve=F.value)==null?void 0:ve.filter(Fa=>(Fa==null?void 0:Fa.label)!=="操作")]);const D=(ka=(Ra=te.tableToForm(z,P))==null?void 0:Ra[0])==null?void 0:ka.find(Fa=>{const bl=Fa==null?void 0:Fa.key;return bl==="Interface"||bl==="方法体"}),ne=D==null?void 0:D.value;if(!ne){console.log("未搜索到isMain, 缺少算法执行接口"),de.setImportLoading(!1);return}const re=F.value?te.getEqualChild([F.value]):[],q=re.find(Fa=>{const bl=Fa==null?void 0:Fa.prop;return bl==="Input1"||bl==="输入数据.输入1"||bl==="样本输入数据"}),be=q==null?void 0:q.prop;let Ee=v==null?void 0:v[be];const Ye=await yi().catch(Fa=>(de.setImportLoading(!1),Promise.reject(Fa)));let qe=!0,Qe="";(Da=F.value)==null||Da.forEach(Fa=>{(Fa==null?void 0:Fa.prop)===be&&(qe=!!(Fa!=null&&Fa.childPath),Qe=Fa==null?void 0:Fa.childPath)});let xa="";if(qe){let Fa=(B=(Ea=F.value)==null?void 0:Ea.find(dl=>(dl==null?void 0:dl.isMainKey)===!0))==null?void 0:B.prop;xa=v==null?void 0:v[Fa];let bl=Qe==null?void 0:Qe.split(S),Va=[];bl==null||bl.forEach((dl,Tl)=>{(bl==null?void 0:bl.length)-1===Tl&&Va.push(xa),Va.push(dl)}),Va=Va==null?void 0:Va[0];let ul=await te.getItemData(Va,sessionStorage.getItem("systemKey"),""),Ga=ul==null?void 0:ul.filter(dl=>(dl==null?void 0:dl.name)===be);Ga=Ga==null?void 0:Ga.map(dl=>{var Tl;return dl.compData=(Tl=dl==null?void 0:dl.compData)==null?void 0:Tl.map(Ml=>{var Nr;return(Ml==null?void 0:Ml.key)==="tableContents"&&(Ml.contents=(Nr=Ml==null?void 0:Ml.contents)==null?void 0:Nr.filter(Fl=>(Fl==null?void 0:Fl[1])===(v==null?void 0:v[be]))),Ml}),dl}),(!Ga||(Ga==null?void 0:Ga.length)===0)&&(Ga=ul,Ga=Ga==null?void 0:Ga.map(dl=>{var Tl;return dl.compData=(Tl=dl==null?void 0:dl.compData)==null?void 0:Tl.map(Ml=>{var Nr;return(Ml==null?void 0:Ml.key)==="tableContents"&&(Ml.contents=(Nr=Ml==null?void 0:Ml.contents)==null?void 0:Nr.filter(Fl=>{var xl,Ll;return(Fl==null?void 0:Fl[1])===(v==null?void 0:v[(Ll=(xl=F==null?void 0:F.value)==null?void 0:xl[0])==null?void 0:Ll.prop])})),Ml}),dl})),Ee=it(Ga)}const za=await nt(ne,{token:Ye,inputData:Ee}).catch(Fa=>(de.setImportLoading(!1),Promise.reject(Fa))),La=(G=za==null?void 0:za.data)==null?void 0:G.data,ea=re.find(Fa=>(Fa==null?void 0:Fa.prop)==="Output1"),Qa=ea==null?void 0:ea.prop;let wa=[],el=[];if(La&&(($e=Object.values(La))==null?void 0:$e.length)>0){let Fa=[];const bl=new FormData,Va=(sa=ot(La))==null?void 0:sa.map(async Ga=>{var dl,Tl;if(!Array.isArray(Ga)&&(Ga!=null&&Ga.includes("http"))){let Ml=await ja.axios.get(Ga,{responseType:"blob"}),Nr=(Tl=Ga==null?void 0:Ga.split("/"))==null?void 0:Tl[((dl=Ga==null?void 0:Ga.split("/"))==null?void 0:dl.length)-1];bl.append("files",Ml.data,Nr)}else Fa.push(Ga)});if(await Promise.all(Va),!te.isFormDataEmpty(bl)){let Ga=await A.uploadAmountApi(bl),dl=(da=(xe=Ga==null?void 0:Ga.data)==null?void 0:xe.result)==null?void 0:da.map(Tl=>{var Ml,Nr,Fl,xl,Ll,Zl;return{name:(Zl=(Ll=(xl=(Ml=Tl==null?void 0:Tl.url)==null?void 0:Ml.split("/"))==null?void 0:xl[((Fl=(Nr=Tl==null?void 0:Tl.url)==null?void 0:Nr.split("/"))==null?void 0:Fl.length)-1])==null?void 0:Ll.split("."))==null?void 0:Zl[0],url:Tl==null?void 0:Tl.url}});Fa=[...Fa,...dl]}let ul={};for(let Ga in v)Ga!=="id"&&(ul[Ga]=v[Ga]);ul[Qa]=Fa,el.push({id:v==null?void 0:v.id,value:{tableData:ul}})}if((el==null?void 0:el.length)>0){const Fa=el.map(Va=>{const ul={id:Va.id,...Va.value.tableData};return delete ul._isOCRRow,delete ul._ocrTableId,delete ul._isTemp,delete ul.tableEditType,delete ul.index,ul}),bl=[{tableName:(Na=u==null?void 0:u.related)==null?void 0:Na.find(Va=>Va==null?void 0:Va.includes("content")),tableContents:Fa}];await A.pageBatchUpdateApi({platId:parseInt((il=hl.value)==null?void 0:il.plat_id),changeContents:bl})}if((wa==null?void 0:wa.length)>0)try{await A.pageBatchAddApi({platId:parseInt((qa=hl.value)==null?void 0:qa.plat_id),changeContents:[{tableName:(pl=u==null?void 0:u.related)==null?void 0:pl.find(Fa=>Fa==null?void 0:Fa.includes("content")),tableContents:wa.map(Fa=>{var Va,ul,Ga;const bl={id:((Va=Fa==null?void 0:Fa.key)==null?void 0:Va.id)??((ul=Fa==null?void 0:Fa.key)==null?void 0:ul.rowId)??(Fa==null?void 0:Fa.id),...((Ga=Fa==null?void 0:Fa.value)==null?void 0:Ga.tableData)||{}};return delete bl._isOCRRow,delete bl._ocrTableId,delete bl._isTemp,delete bl.tableEditType,delete bl.index,Object.keys(bl).forEach(dl=>{dl==="证书附件"&&Array.isArray(bl[dl])&&(bl[dl]=JSON.stringify(bl[dl]))}),bl})}]})}catch(Fa){ja.ElMessage.error(((Ul=(fl=Fa==null?void 0:Fa.response)==null?void 0:fl.data)==null?void 0:Ul.message)||(Fa==null?void 0:Fa.message)||"保存失败"),ua.setTableLoading(!1);return}Hi(!0),de.setImportLoading(!1),ua.setFreshContent(!0)},po=(p,v)=>(p=p==null?void 0:p.map(T=>{var z,P;return T!=null&&T.children&&((z=T.children)!=null&&z.find(D=>D.id===(v==null?void 0:v.id))?T.children=(P=T.children)==null?void 0:P.filter(D=>(D==null?void 0:D.id)!==(v==null?void 0:v.id)):T.children=po(T.children,v)),T}),p),gi=e.ref(!1),t=()=>{gi.value=!0},o=async p=>{var T,z,P,D;gi.value=!1;const v=Array.isArray(p)?p:p?[p]:[];if(v.length!==0)for(const ne of v){const re={name:ne.name||`capture-${Date.now()}.jpg`,url:URL.createObjectURL(ne),raw:ne,uid:Date.now()+Math.random()};Aa.value.push(re),or(re,"uploading"),Rl(re,0);try{const q=new FormData;q.append("file",ne,re.name);const be=await A.platformUploadFile(q);re.uploadResult=((T=be==null?void 0:be.data)==null?void 0:T.result)||{name:re.name,url:"",fileName:re.name},Cl({name:((z=re.uploadResult)==null?void 0:z.name)||re.name,url:((P=re.uploadResult)==null?void 0:P.url)||"",id:(D=re.uploadResult)==null?void 0:D.id}),or(re,"uploaded"),Rl(re,100)}catch(q){console.error("文件上传失败:",q),ja.ElMessage.error(`文件 ${re.name} 上传失败,请重试`),or(re,"pending"),Rl(re,0);const be=Aa.value.findIndex(Ee=>Ee.uid===re.uid);be>-1&&Aa.value.splice(be,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,T)=>{v===(u==null?void 0:u.index)?T(new Error("选择源不能和目标源一致")):T()}}]},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:""}),_=()=>{y.show=!1},O=async p=>{var v,T,z,P,D,ne,re,q;try{const be=[];let Ee=(v=ze.value||[])==null?void 0:v.slice();(p||[]).forEach(za=>{const La={...za};try{La.sort=ri(0,Ee)}catch{}be.push(La),Ee.unshift(La)});let Ye=await A.quoteApi({platId:parseInt((T=hl==null?void 0:hl.value)==null?void 0:T.plat_id),type:"fatherSyncs",related:[{menus:we.value,groups:""},{menus:we.value,groups:u==null?void 0:u.compName}]});Ye=(z=Ye==null?void 0:Ye.data)==null?void 0:z.result;let qe=Ye==null?void 0:Ye.map(za=>({tableName:"content_"+(za==null?void 0:za.id),tableContents:be==null?void 0:be.map((La,ea)=>({id:ea,...La}))})),Qe=[{tableName:(P=u==null?void 0:u.related)==null?void 0:P.find(za=>za==null?void 0:za.includes("content")),tableContents:be==null?void 0:be.map((za,La)=>({id:La,...za}))}];Qe=[...Qe,...qe];const xa=await A.pageBatchAddApi({platId:parseInt((D=hl.value)==null?void 0:D.plat_id),changeContents:Qe});if(((ne=xa==null?void 0:xa.data)==null?void 0:ne.code)===200){const za={buttonName:"新增",columns:F.value,fixContent:be==null?void 0:be.map((ea,Qa)=>({id:Qa,...ea})),relatedContents:u==null?void 0:u.related};await Dt(za),ja.ElMessage.success("数据导入成功");let La=[];Qe==null||Qe.forEach(ea=>{var Qa;(Qa=ea==null?void 0:ea.tableContents)==null||Qa.forEach(wa=>{La.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(wa),request_result:"{}",is_delete:!1,request_table:ea==null?void 0:ea.tableName,request_type:"export"})})}),await A.pageBatchAddApi({platId:parseInt((re=hl==null?void 0:hl.value)==null?void 0:re.plat_id),changeContents:[{tableName:"log",tableContents:La}]})}else{let za=[];Qe==null||Qe.forEach(La=>{var ea;(ea=La==null?void 0:La.tableContents)==null||ea.forEach(Qa=>{za.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Qa),request_result:"{}",is_delete:!1,request_table:La==null?void 0:La.tableName,request_type:"error"})})}),await A.pageBatchAddApi({platId:parseInt((q=hl==null?void 0:hl.value)==null?void 0:q.plat_id),changeContents:[{tableName:"log",tableContents:za}]}),ja.ElMessage.error("数据导入响应失败")}}catch(be){throw new Error(be)}},K=async p=>{var v,T,z,P,D,ne,re,q,be,Ee;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((T=hl.value)==null?void 0:T.plat_id),changeContents:[{tableName:((z=u==null?void 0:u.related)==null?void 0:z.find(qe=>qe==null?void 0:qe.includes("content_")))||((P=u==null?void 0:u.related)==null?void 0:P.find(qe=>qe==null?void 0:qe.includes("content"))),tableContents:y==null?void 0:y.existRows}]});const Ye=await A.pageBatchAddApi({platId:parseInt((D=hl.value)==null?void 0:D.plat_id),changeContents:[{tableName:(ne=u==null?void 0:u.related)==null?void 0:ne.find(qe=>qe==null?void 0:qe.includes("content")),tableContents:(()=>{const qe=(ze.value||[]).filter(La=>!((y==null?void 0:y.existRows)||[]).some(ea=>String(ea==null?void 0:ea.id)===String(La==null?void 0:La.id))),Qe=(y==null?void 0:y.tableData)||[],xa=[];let za=qe.slice();return Qe.forEach(La=>{const ea={...La};try{ea.sort=ri(0,za)}catch{}xa.push(ea),za.unshift(ea)}),xa.map((La,ea)=>({id:ea,...La}))})()}]});if(((re=Ye==null?void 0:Ye.data)==null?void 0:re.code)!==200)return;(q=y.newRows)!=null&&q.length&&await O(y.newRows),await Dt({buttonName:"新增",columns:F.value,fixContent:(be=y==null?void 0:y.tableData)==null?void 0:be.map((qe,Qe)=>({id:Qe,...qe})),relatedContents:u==null?void 0:u.related}),(Ee=y.newRows)!=null&&Ee.length||ja.ElMessage.success("数据导入成功")}}catch(Ye){throw new Error(Ye)}finally{y.show=!1,y.columns=[],y.tableData=[],y.existRows=[]}},Q=()=>{f.show=!1},ge=p=>{var v,T;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)!==((T=f.to)==null?void 0:T.groupName)&&(Be("change",{buttonName:"迁移",value:{from:f.from,to:f.to,data:f.selectRow}}),f.show=!1)},Ue=async p=>{var v,T,z,P;if(p){if(!yr.validateFileSize(p.raw)){ja.ElMessage.warning(`文件大小不能超过 ${vn.value.maxSize}MB`);const D=Aa.value.findIndex(ne=>ne.uid===p.uid);D>-1&&Aa.value.splice(D,1),Se();return}if(!yr.validateFileType(p.raw)){ja.ElMessage.warning("请上传图片文件");const D=Aa.value.findIndex(ne=>ne.uid===p.uid);D>-1&&Aa.value.splice(D,1),Se();return}or(p,"uploading"),Rl(p,0);try{const D=new FormData;D.append("file",p.raw,p.name);const ne=await A.platformUploadFile(D);p.uploadResult=((v=ne==null?void 0:ne.data)==null?void 0:v.result)||{name:p.name,url:"",fileName:p.name},Cl({name:((T=p.uploadResult)==null?void 0:T.name)||p.name,url:((z=p.uploadResult)==null?void 0:z.url)||"",id:(P=p.uploadResult)==null?void 0:P.id}),or(p,"uploaded"),Rl(p,100)}catch(D){console.error("文件上传失败:",D),ja.ElMessage.error(`文件 ${p.name} 上传失败,请重试`),or(p,"pending"),Rl(p,0);const ne=Aa.value.findIndex(re=>re.uid===p.uid);ne>-1&&Aa.value.splice(ne,1)}finally{Se()}}},Se=()=>{e.nextTick(()=>{const p=document.querySelector('.ocr-upload-input input[type="file"]');p&&(p.value="")})},ra=async()=>{var T,z;if(sessionStorage.setItem("ocr_root_table_id",String((u==null?void 0:u.index)??"")),Aa.value.length===0){ja.ElMessage.warning("请先选择要上传的图片");return}if(Aa.value.filter(P=>{const D=zl(P);return D!=="uploaded"&&D!=="completed"&&D!=="failed"}).length>0){ja.ElMessage.warning("请等待所有文件上传完成后再开始识别");return}rl.value=!0,la.value=0;let v=null;try{Aa.value.forEach(ea=>{or(ea,"processing")});const P=Math.floor(Math.random()*10)+90;v=setInterval(()=>{la.value<P?la.value+=1:clearInterval(v)},50);const D=Aa.value.map(ea=>{var Qa,wa,el;return{name:((Qa=ea.uploadResult)==null?void 0:Qa.name)||ea.name,url:((wa=ea.uploadResult)==null?void 0:wa.url)||"",fileName:((el=ea.uploadResult)==null?void 0:el.fileName)||ea.name}}),ne=yr.extractTableHeaders(F.value),re=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 yr.recognize(re,ne);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)){la.value=0,Aa.value.forEach(ea=>{or(ea,"failed"),Rl(ea,0)}),ja.ElMessage.error((q==null?void 0:q.message)||"OCR识别失败,请重试"),rl.value=!1;return}la.value=P;const be=Array.isArray(q==null?void 0:q.result)?q.result:[];if(be.length===0){la.value=0,Aa.value.forEach(ea=>{or(ea,"failed"),Rl(ea,0)}),ja.ElMessage.warning("OCR识别未返回有效数据"),rl.value=!1;return}const Ee=new Set,Ye=[];be.forEach((ea,Qa)=>{const wa=ea!=null&&ea.数据&&typeof(ea==null?void 0:ea.数据)=="object"?ea.数据:{},el=Array.isArray(ea==null?void 0:ea.图片信息)?ea.图片信息:[],ve=new Map;el.forEach(ka=>{ka!=null&&ka.name&&ve.set(ka.name,ka.url||"")});const Ra={_index:Qa,_certType:(ea==null?void 0:ea.证书类型)||"",_certNo:(ea==null?void 0:ea.证书编号)||"",_ocrImages:el,__ocrFieldMeta:{}};Object.entries(wa).forEach(([ka,Da])=>{let Ea="",B=0,G=[],$e="";Da&&typeof Da=="object"&&!Array.isArray(Da)?(Ea=(Da==null?void 0:Da.value)??"",B=(Da==null?void 0:Da.score)??0,G=Array.isArray(Da==null?void 0:Da.bboxNorm)?Da==null?void 0:Da.bboxNorm:[],$e=(Da==null?void 0:Da.imageName)||""):Array.isArray(Da)&&Da.length>=2?(Ea=Da[0]??"",B=Da[1]??0):(Ea=Da??"",B=0),Ra[ka]=Ea,Ra[`${ka}_accuracy`]=B,Ee.add(ka),Ra.__ocrFieldMeta[ka]={value:Ea,score:B,bboxNorm:G,imageName:$e,imageUrl:$e&&ve.get($e)||"",images:el}}),Ye.push(Ra)});const qe=[],Qe=new Set;Ye.forEach(ea=>{ea&&Ee.forEach(Qa=>{const wa=ea[`${Qa}_accuracy`];(typeof wa=="number"?wa>0:wa!=null&&String(wa).trim()!==""&&String(wa)!=="0")&&Qe.add(Qa)})}),Ee.forEach(ea=>{qe.push({prop:ea,label:ea,editable:!0,minWidth:230}),Qe.has(ea)&&qe.push({prop:`${ea}_accuracy`,label:"准确率",editable:!1,minWidth:100,isAccuracy:!0})}),Aa.value.forEach(ea=>{or(ea,"completed")}),la.value=100,Ua.value=qe,Ke.value=Ye,Le.value=D,ia.value=q;const xa=["出厂编号","设备名称","制造厂"],za=qe.filter(ea=>ea&&!ea.isAccuracy&&typeof ea.prop=="string").map(ea=>ea.prop),La=["出厂编号","设备名称","制造厂"];va.value=za.filter(ea=>La.includes(ea)),console.log("[OCR] 默认勾选字段 props:",va.value),Ia.value=2,rl.value=!1,ba.value=!1}catch(P){console.error("OCR处理失败:",P),v&&(clearInterval(v),v=null),ja.ElMessage.error(((z=(T=P==null?void 0:P.response)==null?void 0:T.data)==null?void 0:z.message)||"OCR识别失败,请重试"),rl.value=!1,la.value=0,Aa.value.forEach(D=>{or(D,"pending"),Rl(D,0)})}},Ta=p=>{if(p==null)return"";let v=String(p);return v=v.replace(/\s+/g," ").trim(),v=v.replace(/[!-~]/g,T=>String.fromCharCode(T.charCodeAt(0)-65248)),v=v.replace(/ /g," "),v=v.replace(/^(编号|No\.?|NO\.?|no\.?|SN\.?|sn\.?|序列号)\s*[::]?\s*/i,""),v},Za=()=>{var ea,Qa;const p=Le.value,v=ia.value,T=Ke.value;if(!T||T.length===0){ja.ElMessage.warning("暂无数据可添加");return}const z=(ea=te.getAllLeafNodes(F.value)||[])==null?void 0:ea.filter(wa=>(wa==null?void 0:wa.type)!=="operate"&&(wa==null?void 0:wa.label)!=="操作"&&(wa==null?void 0:wa.prop)!=="operate"),P=new Map,D=new Map,ne=(Qa=z==null?void 0:z.find(wa=>(wa==null?void 0:wa.label)==="证书附件"))==null?void 0:Qa.prop;z==null||z.forEach(wa=>{wa!=null&&wa.label&&(wa!=null&&wa.prop)&&(P.set(wa.label,wa.prop),D.set(wa.prop,wa.label))});const re=Date.now(),q=wa=>String(re*1e3+wa),be=[],Ee=[],Ye=wa=>{const el=zo&&zo[wa]||[wa];for(const ve of el){const Ra=P.get(ve);if(Ra)return Ra}return""},qe=Ye("出厂编号"),Qe=Ye("设备名称"),xa=Ye("制造厂"),za=[],La=wa=>{var Ea,B;if(!ne)return[];const el=(Array.isArray(p)?p[wa]:null)||null,ve=(el==null?void 0:el.url)||"",Ra=(el==null?void 0:el.fileName)||(el==null?void 0:el.name)||"";return(String(Ra).toLowerCase().endsWith(".pdf")||String(ve).toLowerCase().endsWith(".pdf"))&&ve?[{url:ve,name:Ra,fileName:Ra}]:(Array.isArray((B=(Ea=v==null?void 0:v.result)==null?void 0:Ea[wa])==null?void 0:B.图片信息)?v.result[wa].图片信息:[]).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(T.forEach((wa,el)=>{var il;const ve={id:q(el),_isOCRRow:!0,_ocrTableId:u==null?void 0:u.index};for(const[qa,pl]of P.entries())Object.prototype.hasOwnProperty.call(wa,qa)&&(ve[pl]=wa[qa]);ne&&(ve[ne]=La(el));const Ra=(Array.isArray(v==null?void 0:v.result)?v.result[el]:null)||null,ka=(Array.isArray(p)?p[el]:null)||null,Da=(ka==null?void 0:ka.url)||"",Ea=(ka==null?void 0:ka.fileName)||(ka==null?void 0:ka.name)||"",B=String(Ea).toLowerCase().endsWith(".pdf")||String(Da).toLowerCase().endsWith(".pdf"),G={ts:Date.now(),versionId:String(Date.now())+"_"+String(el),label:new Date().toLocaleString(),certType:(Ra==null?void 0:Ra.证书类型)||"",certNo:(Ra==null?void 0:Ra.证书编号)||"",fileType:B?"pdf":"image",sourceUrl:B?Da:"",images:Array.isArray(Ra==null?void 0:Ra.图片信息)?Ra.图片信息.map(qa=>({name:(qa==null?void 0:qa.name)||"",url:(qa==null?void 0:qa.url)||""})).filter(qa=>qa.url):[]},$e=qa=>Ta(qa?ve==null?void 0:ve[qa]:""),sa=$e(qe),xe=$e(Qe),da=$e(xa);if(!!(qe&&Qe&&xa&&sa&&xe&&da)){const qa=(ze.value||[]).find(pl=>{const fl=Ta(qe?pl==null?void 0:pl[qe]:""),Ul=Ta(Qe?pl==null?void 0:pl[Qe]:""),Fa=Ta(xa?pl==null?void 0:pl[xa]:"");return fl&&Ul&&Fa&&fl===sa&&Ul===xe&&Fa===da});if(qa){za.push({idx:el,ocrRow:ve,versionItem:G,ocrNo:sa,candidates:[qa],selectedTargetId:String((qa==null?void 0:qa.id)??""),__decision:"replace",allowAdd:!1,allowReplace:!0});return}}if(sa&&qe){const qa=(ze.value||[]).filter(pl=>{const fl=Ta(qe?pl==null?void 0:pl[qe]:"");return fl&&fl===sa});if(qa.length>0){za.push({idx:el,ocrRow:ve,versionItem:G,ocrNo:sa,candidates:qa,selectedTargetId:"",__decision:"",allowAdd:!0,allowReplace:!0});return}}try{if(ve.sort===void 0||ve.sort===null||String(ve.sort).trim()===""){const qa=(ze.value||[]).map(fl=>li(fl==null?void 0:fl.sort)).filter(fl=>fl!==null),pl=qa.length>0?Math.max(...qa):((il=ze.value)==null?void 0:il.length)??0;ve.sort=String(Number((pl+1).toFixed(6)))}}catch{}aa(u==null?void 0:u.index,ve.id,G),za.push({idx:el,ocrRow:ve,versionItem:G,ocrNo:sa,candidates:[],selectedTargetId:"",__decision:"add",allowAdd:!0,allowReplace:!1})}),(za||[]).length>0){_r.value=(za||[]).map(wa=>({...wa,selectedTargetId:(wa==null?void 0:wa.selectedTargetId)||""})),nr.value=!0,jl.value=Ee,pr.value=be,Sr.value=v,Cr.value=p,Oe.value=ne||"";return}},Ka=(p,v,T)=>{Ke.value[p]&&(Ke.value[p][v]=T)},nl=p=>p==null||p===0?"-":`${(Number(p)*100).toFixed(1)}%`,_l=p=>{if(p==null||p===0)return"#909399";const v=Number(p);return v>=.9?"#67c23a":v>=.7?"#e6a23c":"#f56c6c"},gl=p=>{var T,z,P,D;if(ll.value===p){ll.value=null,Dl.value=!1,Pe.value="";return}ll.value=p,Pe.value="";const v=(T=Ke.value)==null?void 0:T[p];if(v&&Array.isArray(v._ocrImages)&&v._ocrImages.length>0){Wa.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 ne=v.__ocrFieldMeta||{},re=(z=Object.values(ne))==null?void 0:z.find(q=>q==null?void 0:q.imageName);ml.value=(re==null?void 0:re.imageName)||((D=(P=Wa.value)==null?void 0:P[0])==null?void 0:D.name)||"",Dl.value=Wa.value.length>0}else Wa.value=[],Dl.value=!1,ml.value=""},Nl=()=>{ya.value=!1,Aa.value=[],ol.value=null,Ia.value=1,$a.value.clear(),Z.value.clear(),la.value=0,Dl.value=!1},Wl=p=>p.raw?URL.createObjectURL(p.raw):p.url?p.url:"",zl=p=>{const v=p.uid||p.name;return $a.value.get(v)||"pending"},$l=p=>{const v=p.uid||p.name;return Z.value.get(v)||0},Rl=(p,v)=>{const T=p.uid||p.name;Z.value.set(T,Math.min(100,Math.max(0,v)))},rn=p=>{const v=zl(p),T=100.53;if(v==="completed"||v==="uploaded")return`${T} ${T}`;if(v==="failed")return`${T} ${T}`;if(v==="uploading"){const z=$l(p);return`${T*(z/100)} ${T}`}else if(v==="processing")return`${T*.5} ${T}`;return`0 ${T}`},or=(p,v)=>{const T=p.uid||p.name;$a.value.set(T,v),(v==="completed"||v==="uploaded")&&Rl(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 T=>{const z=Array.from(T.target.files||[]);for(const P of z){const D={name:P.name,raw:P,uid:Date.now()+Math.random()};Aa.value.push(D),await Ue(D)}T.target.value="",document.body.removeChild(v)},document.body.appendChild(v),v.click()}})},kn=()=>{Ia.value>1&&Ia.value--},Tn=()=>{Ia.value===1?Aa.value.length>0&&!rl.value&&ra():Ia.value===2&&(Za(),Ia.value=3)},bi=async p=>{await It(p==null?void 0:p.row)},ii=async({row:p,prop:v})=>{!p||!v||await It(p,v)},It=async(p,v)=>{var P,D;const T=p==null?void 0:p.id;if(!T){ja.ElMessage.warning("暂无可预览数据");return}let z=Sl(u==null?void 0:u.index,T);if(!z||z.length===0){const ne=sessionStorage.getItem("ocr_root_table_id"),re=ne!==null?Number(ne):null;if(re!=null&&re!==""&&!Number.isNaN(re)){const q=Sl(re,T);Array.isArray(q)&&q.length>0&&(Gl(u==null?void 0:u.index,T,q),z=q)}}if(!z||z.length===0){const ne=(P=te.getAllLeafNodes(F.value)||[])==null?void 0:P.filter(q=>(q==null?void 0:q.type)!=="operate"&&(q==null?void 0:q.label)!=="操作"&&(q==null?void 0:q.prop)!=="operate"),re=v||((D=ne==null?void 0:ne.find(q=>(q==null?void 0:q.label)==="证书附件"))==null?void 0:D.prop);if(re&&p[re]){const q=p[re];let be=[],Ee="",Ye=!1;if(typeof q=="string")try{const qe=JSON.parse(q);Array.isArray(qe)&&(be=qe.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),be.length>0&&(Ee=be[0].url||"",Ye=String(be[0].name).toLowerCase().endsWith(".pdf")||String(Ee).toLowerCase().endsWith(".pdf")))}catch{Ee=q,Ye=String(q).toLowerCase().endsWith(".pdf"),be=[{name:q,url:q}]}else Array.isArray(q)&&(be=q.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),be.length>0&&(Ee=be[0].url||"",Ye=String(be[0].name).toLowerCase().endsWith(".pdf")||String(Ee).toLowerCase().endsWith(".pdf")));if(be.length>0||Ee){const qe={ts:Date.now(),versionId:String(Date.now()),label:new Date().toLocaleString(),certType:p.证书类型||"",certNo:p.证书编号||"",fileType:Ye?"pdf":"image",sourceUrl:Ye?Ee:"",images:be};z=[qe],aa(u==null?void 0:u.index,T,qe)}}}if(!z||z.length===0){ja.ElMessage.warning("暂无可预览数据");return}ke.value=z,al.value=!0},cu=p=>{Aa.value=Aa.value.filter((v,T)=>T!==p)},st=async(p,v,T)=>{var z,P,D,ne,re,q,be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa,wa,el,ve,Ra,ka;if(_a(u.config,{type:He.TABLE,tableOperate:p})){if(Ma.value="",Xa.value=!0,fa.value=!0,Be("onButtonClick",p,v),le.value=[],p==="删除")A.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var Da,Ea,B,G;(Da=ze.value)!=null&&Da.find($e=>($e==null?void 0:$e.id)===(v==null?void 0:v.id))?ze.value=(Ea=A.cloneDeep(ze.value))==null?void 0:Ea.filter($e=>($e==null?void 0:$e.id)!==(v==null?void 0:v.id)):ze.value=po(A.cloneDeep(ze.value),v);try{v!=null&&v.id&&((G=(B=Oa.value)==null?void 0:B.has)!=null&&G.call(B,v==null?void 0:v.id))&&Oa.value.delete(v.id)}catch{}Rf(jr.value,Wr.value,v==null?void 0:v.id),ua.setTableLoading(u==null?void 0:u.index),Be("change",{content:ze.value,fixContent:[v],index:u==null?void 0:u.index,type:"delete",name:u==null?void 0:u.groupNames,buttonName:p,columns:F.value,relatedContents:u==null?void 0:u.related}),console.log(v,"item")});else if(p==="批量删除"){if(((z=ql.value)==null?void 0:z.length)===0)return ja.ElMessage.warning("请先勾选操作的数据");A.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(async()=>{var B,G,$e,sa,xe;const Da=(B=ql.value)==null?void 0:B.map(da=>da.id);ze.value=(G=A.cloneDeep(ze.value))==null?void 0:G.filter(da=>!(Da!=null&&Da.includes(da.id))),ua.setTableLoading(u==null?void 0:u.index),Be("change",{content:ze.value,fixContent:ql.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:F.value});const Ea=(Da||[]).filter(Boolean);if(Ea.length>0&&Ea.every(da=>da!=null&&da!=="")){const da=(ql.value||[]).map(Na=>{const il={...Na};return delete il._isOCRRow,delete il._ocrTableId,delete il._isTemp,delete il.tableEditType,delete il.index,il});await A.pageBatchDeleteApi({platId:parseInt(($e=hl.value)==null?void 0:$e.plat_id),changeContents:[{tableName:((sa=u==null?void 0:u.related)==null?void 0:sa.find(Na=>Na==null?void 0:Na.includes("content_")))||((xe=u==null?void 0:u.related)==null?void 0:xe.find(Na=>Na==null?void 0:Na.includes("content"))),tableContents:da}]})}})}else if(p==="复制新增"){ye.value="复制新增",A.cloneDeep(v);const Da=(P=F.value)==null?void 0:P.find(Ea=>Ea==null?void 0:Ea.isMainKey);Da||((D=F.value)==null||D[0]),Al.value=v,Hi(!0)}else if(p==="新增")ye.value="新增",Fi(""),Ne.value=!0;else if(p==="编辑")ye.value="编辑",Fi(v),Ne.value=!0;else if(p==="查看")ye.value="查看",Fi(v),Xa.value=!1,fa.value=!1,Ne.value=!0;else if(p==="查看三维模型"){const Da={};for(let B in v)B!=="id"&&(Da[B]=v[B]);let Ea=(ne=Object.values(Da))==null?void 0:ne[1];Ge.setTableShowThree(Ea)}else if(p==="切换视图")wu();else if(((re=T==null?void 0:T.extra)==null?void 0:re.type)==="modelExample")ye.value=p,Xe.value=!0;else if(p==="新建"){let Da=pe.value,Ea=[];for(let xe in Da)xe!=null&&xe.includes(`loading${((q=hl.value)==null?void 0:q.account)||((be=hl.value)==null?void 0:be.账号)}`)&&(Ea=[...Ea,...xe]);let B=[];for(let xe in Da)xe!=null&&xe.includes(`updateLoading${((Ee=hl.value)==null?void 0:Ee.account)||((Ye=hl.value)==null?void 0:Ye.账号)}`)&&(B=[...B,...xe]);let G=Ea==null?void 0:Ea.map(xe=>xe==null?void 0:xe.id);const $e=B==null?void 0:B.map(xe=>xe==null?void 0:xe.id);G=[...A.cloneDeep(G),...$e],(G==null?void 0:G.length)>0&&(G!=null&&G.every(xe=>xe!==null&&xe))&&await Rr.batchDeleteInsofDataApi({ids:G});const sa=(qe=We.value)==null?void 0:qe.find(xe=>(xe==null?void 0:xe.label)==="新建");await pu(!1,sa)}else if(p==="修改模板"){let Da=A.cloneDeep(we).value;ua.setRouteToChildPath(Da),de.setActiveMenuPath(Da+S)}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=["推力","真空","压力","温度","流量"],B=xl=>{var Ll,Zl,Ol;return xl?typeof(xl==null?void 0:xl.value)=="string"?xl.value:((Ol=(Zl=(Ll=xl==null?void 0:xl._custom)==null?void 0:Ll.value)==null?void 0:Zl.value)==null?void 0:Ol.value)||"":""},G=Array.isArray(ar.value)?ar.value:[],$e=B(G.find(xl=>(xl==null?void 0:xl.condition)==="child")),sa=String($e||"").slice(0,8),xe=xl=>{if(xl==null)return"";const Ll=String(xl).trim();if(!Ll)return"";if(/^\d{8}$/.test(Ll))return Ll;const Zl=Ll.match(/^(\d{4})[-\/.](\d{1,2})[-\/.](\d{1,2})$/);if(Zl){const Xl=Zl[1],tr=Zl[2].padStart(2,"0"),Yl=Zl[3].padStart(2,"0");return`${Xl}${tr}${Yl}`}const Ol=Ll.replace(/\D/g,"");return Ol.length>=8?Ol.slice(0,8):""},da=async xl=>{var Ll,Zl;if(!xl)return"";try{const Ol=await an("试验任务/任务管理",!1),Xl=(xr,dr=[])=>{if(!Array.isArray(xr))return dr;for(const vr of xr)(vr==null?void 0:vr.comp)==="Table"&&(vr!=null&&vr.name)&&dr.push(vr),Array.isArray(vr==null?void 0:vr.children)&&Xl(vr.children,dr),Array.isArray(vr==null?void 0:vr.tab)&&Xl(vr.tab,dr),Array.isArray(vr==null?void 0:vr.choice)&&Xl(vr.choice,dr);return dr},Yl=Xl(Ol||[]).find(xr=>(xr==null?void 0:xr.name)==="任务列表"),kr=((Zl=(Ll=Yl==null?void 0:Yl.compData)==null?void 0:Ll.find(xr=>(xr==null?void 0:xr.key)==="tableContents"))==null?void 0:Zl.contents)||[];if(!Array.isArray(kr)||kr.length===0)return"";const on=kr.find(xr=>String((xr==null?void 0:xr["试验代号(名称)"])||"").slice(0,8)===xl);return xe(on==null?void 0:on.计划试验时间)}catch(Ol){return console.warn("获取任务列表计划试验时间失败:",Ol),""}},Na=(we.value||"").replace(/\/+$/,""),il=$e?`${Na}/${$e}`:Na,qa=await an(il||we.value,!1),pl=String(ta.value||"").trim(),fl=xl=>String(xl||"").trim(),Ul=(xl,Ll=[],Zl="")=>{if(!Array.isArray(xl))return Ll;for(const Ol of xl){const Xl=fl((Ol==null?void 0:Ol.choiceName)||(Ol==null?void 0:Ol.name0)||Zl);(Ol==null?void 0:Ol.comp)==="Table"&&(Ol==null?void 0:Ol.name)&&Ea.includes(Ol.name)&&(!pl||Xl===pl)&&Ll.push(Ol),Array.isArray(Ol==null?void 0:Ol.children)&&Ul(Ol.children,Ll,Xl),Array.isArray(Ol==null?void 0:Ol.tab)&&Ul(Ol.tab,Ll,Xl),Array.isArray(Ol==null?void 0:Ol.choice)&&Ul(Ol.choice,Ll,Xl)}return Ll},Fa=Ul(qa||[]),bl=new Map;for(const xl of Fa)xl!=null&&xl.name&&!bl.has(xl.name)&&bl.set(xl.name,xl);const Va=Ea.map(xl=>bl.get(xl)).filter(Boolean);if(!Va||Va.length===0)return ja.ElMessage.warning("未找到需要导出的表(推力、真空、压力、温度、流量)");const ul=xl=>{const Ll=new Map,Zl=(Ol,Xl=[])=>{if(Array.isArray(Ol))for(const tr of Ol){const Yl=((tr==null?void 0:tr.label)??"").toString().trim(),kr=Yl?[...Xl,Yl]:[...Xl];if(Array.isArray(tr==null?void 0:tr.children)&&tr.children.length>0)Zl(tr.children,kr);else{const xr=((tr==null?void 0:tr.prop)??"").toString();if(!xr)continue;const dr=Yl||xr,vr=(kr.length>0?[...Xl,dr]:[dr]).join(".");Ll.set(xr,vr)}}};return Zl(xl,[]),Ll},Ga=(xl,Ll)=>{const Zl=ul(xl||[]),Xl=(te.getAllLeafNodes(xl||[])||[]).filter(Yl=>(Yl==null?void 0:Yl.prop)&&(Yl==null?void 0:Yl.type)!=="operate"&&(Yl==null?void 0:Yl.label)!=="操作"&&(Yl==null?void 0:Yl.prop)!=="operate"),tr=Array.isArray(Ll)?Ll:[];return tr.length===0?[]:tr.map(Yl=>{const kr={};return Xl.forEach(on=>{const xr=String(on.prop),dr=Zl.get(xr)||String(on.label||on.prop);kr[dr]=(Yl==null?void 0:Yl[xr])??""}),kr})},dl=Va.map(xl=>{var tr,Yl;const Ll=(xl==null?void 0:xl.compData)||[];let Zl=(tr=Ll==null?void 0:Ll.find(kr=>(kr==null?void 0:kr.key)==="header"))==null?void 0:tr.contents;Array.isArray(Zl==null?void 0:Zl[0])&&(Zl=Zl[0]);const Ol=((Yl=Ll==null?void 0:Ll.find(kr=>(kr==null?void 0:kr.key)==="tableContents"))==null?void 0:Yl.contents)||[];if(!Array.isArray(Zl)||Zl.length===0||!Array.isArray(Ol)||Ol.length===0)return null;const Xl=Ga(Zl||[],Ol||[]);return!Array.isArray(Xl)||Xl.length===0?null:{类型:xl==null?void 0:xl.name,数据:Xl}}).filter(Boolean);if(!dl||dl.length===0)return ja.ElMessage.warning("没有可导出的数据(推力、真空、压力、温度、流量均为空)");const Tl=await da(sa),Ml={试验代号:sa,试验日期:Tl,ParaForm:dl},Nr=await yi().catch(()=>""),Fl=await A.exportParaformApi(Ml,Nr);if(((Qe=Fl==null?void 0:Fl.data)==null?void 0:Qe.code)===200&&((za=(xa=Fl==null?void 0:Fl.data)==null?void 0:xa.result)!=null&&za.Excel文件)){const xl=Fl.data.result.Excel文件,Ll=await A.platformDownloadFile({url:xl}),Zl=new Blob([Ll.data],{type:"application/vnd.ms-excel"}),Ol=URL.createObjectURL(Zl),Xl=A.dayjs().format("YYYYMMDD"),Yl=`${(sa||"UNKNOWN").trim()||"UNKNOWN"}_${Xl}_paraform.xls`,kr=document.createElement("a");kr.href=Ol,kr.download=Yl,kr.style.display="none",document.body.appendChild(kr),kr.click(),setTimeout(()=>{document.body.removeChild(kr),URL.revokeObjectURL(Ol)},100);const on=Array.isArray((ea=(La=Fl==null?void 0:Fl.data)==null?void 0:La.result)==null?void 0:ea.warnings)?Fl.data.result.warnings:[];if(on.length>0){const xr=on.map((dr,vr)=>`${vr+1}. ${(dr==null?void 0:dr.field)||"未知字段"}:${(dr==null?void 0:dr.message)||""}`).join(`
24
+ `);ja.ElMessage.warning({message:`导出成功,但存在以下提示:
25
+ ${xr}`,duration:5e3,showClose:!0})}else ja.ElMessage.success("导出成功")}else ja.ElMessage.error(((Qa=Fl==null?void 0:Fl.data)==null?void 0:Qa.message)||"导出失败")}catch(Ea){console.error("导出paraform失败:",Ea),ja.ElMessage.error("导出失败:"+((Ea==null?void 0:Ea.message)||"未知错误"))}finally{Da.close()}}else if(p!=null&&p.includes("导出")&&p!=="导出paraform"){if(p==="导出选中"&&((wa=ql.value)==null?void 0:wa.length)===0)return ja.ElMessage.warning(`请先勾选${p}的数据`);if(p==="导出全部"&&((el=ze.value)==null?void 0:el.length)===0)return ja.ElMessage.warning("暂无数据导出");let Da=["序号",...(Ra=(ve=F.value)==null?void 0:ve.map($e=>$e==null?void 0:$e.prop))==null?void 0:Ra.filter($e=>$e!=="操作")],Ea=p==="导出全部"?ze.value:ql.value;const B=["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($e=>Object.fromEntries(Object.entries($e).filter(([sa])=>!B.includes(sa)))),Da=["序号",...Da],Ea=Ea==null?void 0:Ea.map(($e,sa)=>({序号:sa+1,...$e}));let G=(u==null?void 0:u.compName)||"表格信息";Wo(Ea,G,Da,G)}else if(p==="OCR识别")ya.value=!0,Aa.value=[],Ia.value=1,$a.value.clear(),Z.value.clear(),la.value=0;else if(p==="迁移")f.selectRow=v,f.show=!0;else if(p==="生成方法"){let Da=await a0(v),Ea;v!==""?Ea=[v]:Ea=A.cloneDeep(ze.value),Ea=Ea==null?void 0:Ea.map(G=>(G.输出值=Da,G));const B={fixContent:Ea,buttonName:"编辑",relatedContents:u==null?void 0:u.related,columns:F.value,name:u==null?void 0:u.groupNames};Be("change",B)}else if(((ka=T==null?void 0:T.extra)==null?void 0:ka.type)==="methodButton"){let Da;v!==""?Da=[v]:Da=A.cloneDeep(ze.value);const B={fixContent:await xt(Da,F==null?void 0:F.value,"Manual",ze.value),buttonName:"methodButton",relatedContents:u==null?void 0:u.related,columns:F.value,name:u==null?void 0:u.groupNames};Be("change",B)}}},uu=async(p,v)=>{var T,z,P,D,ne,re,q,be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa,wa,el,ve;try{let Ra,ka;const Da=(T=pe.value[we.value+S])==null?void 0:T.filter(Na=>{var il;return((il=Na==null?void 0:Na.key)==null?void 0:il.type)==="structureMethod"}),Ea=(z=pe.value[we.value+S])==null?void 0:z.filter(Na=>{var il;return((il=Na==null?void 0:Na.key)==null?void 0:il.type)==="structure"}),B=Da==null?void 0:Da.find(Na=>{var il,qa;return((qa=(il=Na==null?void 0:Na.value)==null?void 0:il.pageData)==null?void 0:qa.method)==="保存"});if(!B)return;const G=(re=(ne=pe.value[(D=(P=B==null?void 0:B.value)==null?void 0:P.pageData)==null?void 0:D.path])==null?void 0:ne.filter(Na=>{var il;return((il=Na==null?void 0:Na.key)==null?void 0:il.type)==="data"}))==null?void 0:re.find(Na=>{var il,qa,pl,fl;return((qa=(il=Na==null?void 0:Na.value)==null?void 0:il.tableData)==null?void 0:qa.算法名称)===((fl=(pl=B==null?void 0:B.value)==null?void 0:pl.pageData)==null?void 0:fl.method)});if(!G)return;const $e={buttonName:(be=(q=B==null?void 0:B.value)==null?void 0:q.pageData)==null?void 0:be.method,api:(Ye=(Ee=G==null?void 0:G.value)==null?void 0:Ee.tableData)==null?void 0:Ye.算法体,content:Ea==null?void 0:Ea.map(Na=>{var il;return(il=Na==null?void 0:Na.value)==null?void 0:il.pageData}),extraContent:[],extraValues:(Qe=(qe=B==null?void 0:B.value)==null?void 0:qe.pageData)==null?void 0:Qe.data,methodName:(za=(xa=B==null?void 0:B.value)==null?void 0:xa.pageData)==null?void 0:za.path};if(!p)return;const sa={...p,compData:(La=p==null?void 0:p.compData)==null?void 0:La.map(Na=>{var il;return(Na==null?void 0:Na.key)==="formContent"?{...Na,contents:(il=Na==null?void 0:Na.contents)==null?void 0:il.map(qa=>(qa==null?void 0:qa.prop)===v?{...qa,value:""}:qa)}:Na})},xe={key:{pageKey:we.value+S,parentTable:"",systemKey:sessionStorage.getItem("systemKey"),type:"structure"},value:{pageData:sa}},da=await ja.axios.post($e.api,xe,{headers:{"Content-Type":"application/json"}});return((ea=da==null?void 0:da.data)==null?void 0:ea.code)===200&&(Ra=(wa=(Qa=da==null?void 0:da.data)==null?void 0:Qa.result)==null?void 0:wa.latestReportCode,ka=(ve=(el=da==null?void 0:da.data)==null?void 0:el.result)==null?void 0:ve.status),{newMainKeyValue:Ra,newStatus:ka}}catch(Ra){throw ja.ElMessage.error(Ra),new Error(Ra)}},Ot=e.reactive({prop:"状态",value:""});e.ref(["系统自动生成信息","审批意见"]);const du=async(p,v,T)=>{var q,be;let z=p==null?void 0:p[v==null?void 0:v.prop],P=1,D,ne;const re=A.cloneDeep(we).value+S+z;if(re){Ot.value="",D=(q=pe.value[re])==null?void 0:q.filter(qe=>{var Qe;return((Qe=qe==null?void 0:qe.key)==null?void 0:Qe.type)==="structure"});const Ee=D==null?void 0:D.find(qe=>{var Qe,xa,za;return((za=(xa=(Qe=qe==null?void 0:qe.value)==null?void 0:Qe.pageData)==null?void 0:xa.comp)==null?void 0:za.toUpperCase())==="FORM"});ne={...(be=Ee==null?void 0:Ee.value)==null?void 0:be.pageData,id:Ee==null?void 0:Ee.id};const Ye=await uu(ne,v==null?void 0:v.prop);if(Ot.value=Ye==null?void 0:Ye.newStatus,Ye!=null&&Ye.newMainKeyValue)return Ye==null?void 0:Ye.newMainKeyValue}if(ze.value.some(Ee=>(Ee==null?void 0:Ee[v==null?void 0:v.prop])===z)){const Ee=z;for(;ze.value.some(Ye=>(Ye==null?void 0:Ye[v==null?void 0:v.prop])===`${Ee}(${P})`);)P++;z=`${Ee}(${P})`}return z},pu=async(p,v,T)=>{var D,ne,re,q;let z,P;if(await du(T==null?void 0:T.data,T==null?void 0:T.firstCol),z=A.cloneDeep(we).value+S,P=A.cloneDeep(z)+`loading${((D=hl.value)==null?void 0:D.account)||((ne=hl.value)==null?void 0:ne.账号)}`,v){const be=(q=(re=pe.value[P])==null?void 0:re.filter(Ee=>{var Ye;return((Ye=Ee==null?void 0:Ee.key)==null?void 0:Ye.parentTable)===""}))==null?void 0:q.map(Ee=>{var Ye;return{id:Ee==null?void 0:Ee.id,...(Ye=Ee==null?void 0:Ee.value)==null?void 0:Ye.pageData}});(be==null?void 0:be.length)>0||await te.loadingConstruct(z,P,null,null,null),ua.setRouteToChildPath(A.cloneDeep(we).value),de.setActiveMenuPath(P)}else ua.setRouteToChildPath(A.cloneDeep(we).value),de.setActiveMenuPath(P)},fu=()=>{Fe.value=!1,Ve.value=[],fe.value=!1},Fi=p=>{var D,ne,re,q,be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa,wa,el,ve,Ra,ka,Da,Ea;const v=[];Ce.value=A.cloneDeep(F.value),(ne=te.getColumnChild((D=A.cloneDeep(F.value))==null?void 0:D.filter(B=>(B==null?void 0:B.label)!=="操作")))==null||ne.forEach((B,G)=>{var $e,sa,xe;B!=null&&B.formType&&(($e=B==null?void 0:B.formType)==null?void 0:$e.toUpperCase())==="SELECT"||B!=null&&B.menuId?v.push({label:(sa=B==null?void 0:B.prop)!=null&&sa.includes(".")?B==null?void 0:B.prop:(B==null?void 0:B.label)??(B==null?void 0:B.prop)??"",name:(B==null?void 0:B.prop)??"t"+G,prop:B==null?void 0:B.prop,type:"Select",value:(p==null?void 0:p[B==null?void 0:B.prop])??(B==null?void 0:B.value)??"",id:(B==null?void 0:B.id)??G,contents:(B==null?void 0:B.options)??[],multiple:(B==null?void 0:B.multiple)??!1,multipleLimit:B==null?void 0:B.multipleLimit,width:1,isFormColHidden:B==null?void 0:B.isFormColHidden,relatedValueId:B==null?void 0:B.relatedValueId,disabled:B==null?void 0:B.disabled,menus:B==null?void 0:B.menus,groups:B==null?void 0:B.groups,words:B==null?void 0:B.words,allSelectionContents:(B==null?void 0:B.allSelectionContents)??[],filterContent:B==null?void 0:B.filterContent,disabled:(B==null?void 0:B.prop)==="disabled"?!0:B==null?void 0:B.disabled,filter:B==null?void 0:B.filter,bindMenus:B==null?void 0:B.bindMenus,isMainPath:B==null?void 0:B.isMainPath,required:(B==null?void 0:B.required)??!1,relatedContents:B==null?void 0:B.relatedContents,mainKey:B==null?void 0:B.mainKey,relatedContents:B==null?void 0:B.relatedContents,functionName:B==null?void 0:B.functionName,functionRelatedWords:B==null?void 0:B.functionRelatedWords,calculatorFilter:B==null?void 0:B.calculatorFilter,isReadonly:B==null?void 0:B.isReadonly}):v.push({label:(xe=B==null?void 0:B.prop)!=null&&xe.includes(".")?B==null?void 0:B.prop:(B==null?void 0:B.label)??(B==null?void 0:B.prop)??"",prop:B==null?void 0:B.prop,name:(B==null?void 0:B.prop)??"t"+G,type:!(B!=null&&B.formType)||(B==null?void 0:B.formType)===""?"Input":B==null?void 0:B.formType,value:(B==null?void 0:B.formType)==="Upload"?(p==null?void 0:p[B==null?void 0:B.prop])??"{}":(p==null?void 0:p[B==null?void 0:B.prop])??(B==null?void 0:B.value)??"",id:(B==null?void 0:B.id)??G,contents:(B==null?void 0:B.options)??[],multiple:(B==null?void 0:B.multiple)??!1,width:1,isFormColHidden:B==null?void 0:B.isFormColHidden,disabled:(B==null?void 0:B.prop)==="disabled"?!0:B==null?void 0:B.disabled,relatedValueId:B==null?void 0:B.relatedValueId,menus:B==null?void 0:B.menus,groups:B==null?void 0:B.groups,words:B==null?void 0:B.words,filter:B==null?void 0:B.filter,bindMenus:B==null?void 0:B.bindMenus,isMainPath:B==null?void 0:B.isMainPath,required:(B==null?void 0:B.required)??!1,relatedContents:B==null?void 0:B.relatedContents,mainKey:B==null?void 0:B.mainKey,relatedContents:B==null?void 0:B.relatedContents,functionName:B==null?void 0:B.functionName,functionRelatedWords:B==null?void 0:B.functionRelatedWords,calculatorFilter:B==null?void 0:B.calculatorFilter,isReadonly:B==null?void 0:B.isReadonly})}),p===""||!p||(Ma.value=(p==null?void 0:p.id)??"");let T=te.getColumnChild((re=A.cloneDeep(F.value))==null?void 0:re.filter(B=>(B==null?void 0:B.label)!=="操作"));Pa.value&&((q=Pa.value)==null?void 0:q.length)>0&&(Pa.value=(be=A.cloneDeep(Pa).value)==null?void 0:be.map(B=>{var $e;let G=(B==null?void 0:B.prop)||(($e=T==null?void 0:T.find(sa=>(sa==null?void 0:sa.label)===(B==null?void 0:B.label)))==null?void 0:$e.prop);return G&&(B.value=p[G]),B})),Ae.value=Pa.value&&((Ee=Pa.value)==null?void 0:Ee.length)>0?te.getTableFormToForm(Pa.value):v,Ae.value=((Ye=Ae.value)==null?void 0:Ye.map(B=>({...B,disabled:(B==null?void 0:B.prop)==="disabled"?!0:B==null?void 0:B.disabled})))??Ae.value;let z=[],P=((xa=(Qe=(qe=u.itemData)==null?void 0:qe.filter(B=>(B==null?void 0:B.key)==="filter"))==null?void 0:Qe[0])==null?void 0:xa.contents)??"";if(P=te.analyzeSplitToContent(P,","),(P==null?void 0:P.length)>0&&(z=P.flat()),(z==null?void 0:z.length)>0){let B=z==null?void 0:z.filter(da=>da==null?void 0:da.includes("@Type"));if(B=B==null?void 0:B[(B==null?void 0:B.length)-1],(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)),B){let da=(La=(za=B==null?void 0:B.replace("=",w))==null?void 0:za.split(w))==null?void 0:La[1];((ea=da==null?void 0:da.trim())==null?void 0:ea.toUpperCase())==="MANUAL"&&(u==null||u.index,Ae.value=(Qa=Ae.value)==null?void 0:Qa.map((Na,il)=>Na))}let G=(wa=Ae.value)==null?void 0:wa.filter(da=>da==null?void 0:da.mainKey),$e;G==null||G.forEach(da=>{var il;if($e!==void 0)return;let Na=da==null?void 0:da.menus;((il=G==null?void 0:G.filter(qa=>qa==null?void 0:qa.mainKey))==null?void 0:il.length)>1&&($e=Na,da==null||da.groups)});let sa=[],xe=new Map;if(G==null||G.forEach(da=>{var Na,il,qa,pl,fl,Ul,Fa,bl,Va,ul,Ga,dl,Tl;if((Na=da==null?void 0:da.prop)!=null&&Na.includes(".")){let Ml=[];xe.get(((qa=(il=da==null?void 0:da.prop)==null?void 0:il.split("."))==null?void 0:qa[0])+(da!=null&&da.isMainPath?0:1)+((pl=da==null?void 0:da.groups)==null?void 0:pl[0]))&&(Ml=xe.get(((Ul=(fl=da==null?void 0:da.prop)==null?void 0:fl.split("."))==null?void 0:Ul[0])+(da!=null&&da.isMainPath?0:1)+((Fa=da==null?void 0:da.groups)==null?void 0:Fa[0]))),Ml.push(da),xe.set(((Va=(bl=da==null?void 0:da.prop)==null?void 0:bl.split("."))==null?void 0:Va[0])+(da!=null&&da.isMainPath?0:1)+((ul=da==null?void 0:da.groups)==null?void 0:ul[0]),Ml)}else{let Ml=[];xe.get("normal"+(da!=null&&da.isMainPath?0:1)+((Ga=da==null?void 0:da.groups)==null?void 0:Ga[0]))&&(Ml=xe.get("normal"+(da!=null&&da.isMainPath?0:1)+((dl=da==null?void 0:da.groups)==null?void 0:dl[0]))),Ml.push(da),xe.set("normal"+(da!=null&&da.isMainPath?0:1)+((Tl=da==null?void 0:da.groups)==null?void 0:Tl[0]),Ml)}}),sa=Array.from(xe.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 il=Na==null?void 0:Na.map(ul=>ul==null?void 0:ul.prop),qa=Na==null?void 0:Na.map(ul=>ul==null?void 0:ul.label),pl=Na==null?void 0:Na.map(ul=>ul==null?void 0:ul.value),fl=(el=A.cloneDeep(Na))==null?void 0:el[0],Ul=(ve=Ae.value)==null?void 0:ve.findIndex(ul=>(ul==null?void 0:ul.prop)===(fl==null?void 0:fl.prop)),Fa=(Ra=Ae.value)==null?void 0:Ra.slice(0,Ul),bl=(Da=Ae.value)==null?void 0:Da.slice(Ul,(ka=Ae.value)==null?void 0:ka.length);fl.label=qa==null?void 0:qa.join("·"),fl.value=pl==null?void 0:pl.join(" "),fl.value.trim()===""&&(fl.value=""),fl.prop=il==null?void 0:il.join("·");let Va=Na==null?void 0:Na.map(ul=>{var Ga;return(Ga=ul==null?void 0:ul.words)==null?void 0:Ga.join(".")});fl.relatedWords=Va,fl.usingType="parent",bl.unshift(fl),Ae.value=[...Fa,...bl],Ae.value=(Ea=Ae.value)==null?void 0:Ea.map(ul=>(il!=null&&il.find(Ga=>Ga===(ul==null?void 0:ul.prop))&&(ul.isFormColHidden=!0,ul.relatedWords=Va),ul))}}}}},hu=()=>{var v;const p=(v=i.value)==null?void 0:v.$el;p&&Il.Sortable.create(p,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:T=>{var ne;const{oldIndex:z,newIndex:P}=T;if(z===P)return;const D=bn.value.splice(z,1)[0];bn.value.splice(P,0,D),F.value=(ne=F.value)==null?void 0:ne.slice().sort((re,q)=>{if(re.label==="操作")return 1;if(q.label==="操作")return-1;const be=bn.value.findIndex(Ye=>Ye.label===re.label),Ee=bn.value.findIndex(Ye=>Ye.label===q.label);return be-Ee})}})};e.onMounted(()=>{Ze.value=window.innerWidth-240*2,window.addEventListener("keydown",ao)});const vu=()=>{e.nextTick(()=>{hu()})},mu=()=>{c.value=!0},ct=(p,v)=>{var z;if(!p&&!(p!=null&&p.children))return{contents:p,currentSelectContents:void 0};let T;return p.children=(z=p.children)==null?void 0:z.map(P=>{var D,ne;if((P==null?void 0:P.id)===Ma.value){let re={};for(let q in P){let be=(D=v==null?void 0:v.find(Ee=>(Ee==null?void 0:Ee.prop)===q))==null?void 0:D.label;be?re[q]=(ne=Al.value)==null?void 0:ne[be]:re[q]=P[q]??""}P=Object.assign(re,Al.value),T=P}else{let re=ct(P,v);P=re==null?void 0:re.contents,T=re==null?void 0:re.currentSelectContents}return P}),{contents:p,currentSelectContents:T}},Lt=(p,v)=>{let T,z;return p!=null&&p.find(P=>(P==null?void 0:P.id)===Ma.value)?T=p==null?void 0:p.map(P=>{var D,ne,re;if((P==null?void 0:P.id)===Ma.value){let q={};for(let Ee in P){let Ye=(D=v==null?void 0:v.find(qe=>(qe==null?void 0:qe.prop)===Ee))==null?void 0:D.label;Ye?q[Ee]=((ne=Al.value)==null?void 0:ne[Ye])??"":q[Ee]=P[Ee]??""}let be=Al.value;for(let Ee in q)(re=Al.value)!=null&&re[Ee]||(be[Ee]=(q==null?void 0:q[Ee])??"");P=be,z=P}return P}):T=p==null?void 0:p.map(P=>{var D,ne,re,q;if((P==null?void 0:P.id)===Ma.value){let be={};for(let Ee in P){let Ye=(D=v==null?void 0:v.find(qe=>(qe==null?void 0:qe.prop)===Ee))==null?void 0:D.label;Ye?be[Ee]=(ne=Al.value)==null?void 0:ne[Ye]:be[Ee]=P[Ee]??""}P=Object.assign(be,Al.value),z=P}else P=(re=ct(P,v))==null?void 0:re.contents,z=(q=ct(P,v))==null?void 0:q.currentSelectContents;return P}),{newContents:T,currentSelectContents:z}},Rt=(p,v,T)=>{var z,P;return p[v==null?void 0:v.prop]=T,typeof p.id=="number"&&(p.id=(z=p.id)==null?void 0:z.toString()),p.children&&((P=p.children)==null?void 0:P.length)>0&&(p.children=p.children.map(Rt)),p},$t=p=>{var T;const v=[];return v.push({...p}),p!=null&&p.children&&Array.isArray(p.children)&&((T=p.children)==null||T.forEach(z=>{v.push(...$t(z))})),(v==null?void 0:v.length)>0?v==null?void 0:v.map(z=>{const P={...z};return delete P.children,P}):[]},fo=["Pacific6000数据采集装置.通道号","通道号"],ji=p=>{if(!p)return"";const v=fo.map(T=>p==null?void 0:p[T]).find(T=>T!=null&&String(T).trim()!=="");return v==null?"":String(v).trim()},ut=async(p,v=void 0)=>{if(!p)return!1;try{const T=Qe=>{var xa,za,La;return Qe?typeof(Qe==null?void 0:Qe.value)=="string"?Qe.value:((La=(za=(xa=Qe==null?void 0:Qe._custom)==null?void 0:xa.value)==null?void 0:za.value)==null?void 0:La.value)||"":""},z=Array.isArray(ar.value)?ar.value:[],P=T(z.find(Qe=>(Qe==null?void 0:Qe.condition)==="child")),D=(we.value||"").replace(/\/+$/,""),ne=P?`${D}/${P}`:D,re=await an(ne||we.value,!1),q=String(ta.value||"").trim(),be=Qe=>String(Qe||"").trim(),Ee=(Qe,xa=[],za="")=>{if(!Array.isArray(Qe))return xa;for(const La of Qe){const ea=be((La==null?void 0:La.choiceName)||(La==null?void 0:La.name0)||za);(La==null?void 0:La.comp)==="Table"&&(!q||ea===q)&&xa.push(La),Array.isArray(La==null?void 0:La.children)&&Ee(La.children,xa,ea),Array.isArray(La==null?void 0:La.tab)&&Ee(La.tab,xa,ea),Array.isArray(La==null?void 0:La.choice)&&Ee(La.choice,xa,ea)}return xa},Ye=Ee(re||[]),qe=String((u==null?void 0:u.compName)||"");return Ye.some(Qe=>{var za,La;const xa=((La=(za=Qe==null?void 0:Qe.compData)==null?void 0:za.find(ea=>(ea==null?void 0:ea.key)==="tableContents"))==null?void 0:La.contents)||[];return!Array.isArray(xa)||xa.length===0?!1:xa.some(ea=>{if(String((Qe==null?void 0:Qe.name)||"")===qe&&(ea==null?void 0:ea.id)===v)return!1;const wa=ji(ea);return!!wa&&wa===p})})}catch{return(ze.value||[]).some(z=>{if((z==null?void 0:z.id)===v)return!1;const P=ji(z);return!!P&&P===p})}},Hi=async(p=!0,v,T)=>{var be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa,wa,el,ve,Ra,ka,Da,Ea,B,G,$e,sa,xe,da,Na,il,qa,pl,fl,Ul,Fa,bl;if(Al.value){const Va=(Ee=te.getColumnChild((be=A.cloneDeep(F.value))==null?void 0:be.filter(Ga=>(Ga==null?void 0:Ga.label)!=="操作")))==null?void 0:Ee.filter(Ga=>(Ga==null?void 0:Ga.required)===!0);for(let Ga=0;Ga<((Va==null?void 0:Va.length)??0);Ga++){const dl=Va[Ga],Tl=dl==null?void 0:dl.prop,Ml=(dl==null?void 0:dl.label)??Tl,Nr=(Ye=Al.value)==null?void 0:Ye[Tl];if(Nr===""||Nr===null||Nr===void 0||Array.isArray(Nr)&&Nr.length===0){ja.ElMessage.error(`${Ml}不能为空`);return}}const ul=ji(Al.value);if(ul&&await ut(ul,Ma.value||void 0)){ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择");return}}let z=te.getColumnChild((qe=A.cloneDeep(F.value))==null?void 0:qe.filter(Va=>(Va==null?void 0:Va.label)!=="操作")),P,D=A.cloneDeep(ze.value);if(!Al.value){Ne.value=!1;return}if(Ma.value===""){Ba.value++;let Va;Va={id:Ba.value.toString()};try{Va.sort=ri(0,ze.value||[])}catch{}Va!=null&&Va.children&&(Va={...Va,children:(Qe=Va.children)==null?void 0:Qe.map(Ga=>Rt(Ga,v,T))});const ul=Object.assign(Al.value,Va);D.unshift(ul),P=ul}else D=(xa=Lt(D,z))==null?void 0:xa.newContents,P=(za=Lt(D,z))==null?void 0:za.currentSelectContents;const ne=(La=u.itemData)==null?void 0:La.filter(Va=>(Va==null?void 0:Va.key)==="childTree")[0];if(((ea=ne==null?void 0:ne.contents)==null?void 0:ea.length)>0){ye.value="编辑";const Va=[];D==null||D.forEach((dl,Tl)=>{var Nr;let Ml={};if(Array.isArray(dl)){let Fl=[];dl==null||dl.filter(xl=>!(xl!=null&&xl.id)).forEach((xl,Ll)=>{var Zl,Ol,Xl,tr,Yl,kr,on;if((Ol=(Zl=hr.value)==null?void 0:Zl[Ll])!=null&&Ol.prop&&!Array.isArray(xl)){let xr={};xr[hr.value[Ll].column]=xl,R!=null&&R.value&&((Xl=R==null?void 0:R.value)==null?void 0:Xl.length)>0&&((tr=R==null?void 0:R.value)!=null&&tr.find(dr=>JSON.stringify(dr==null?void 0:dr[0])===JSON.stringify(xr)))&&(Fl=(Yl=R==null?void 0:R.value)==null?void 0:Yl.find(dr=>JSON.stringify(dr==null?void 0:dr[0])===JSON.stringify(xr))),Fl&&Fl.length>0?Ml[hr.value[Ll].prop]=Fl!=null&&Fl.find(dr=>{var vr;return((vr=Object.keys(dr))==null?void 0:vr[0])===hr.value[Ll].column})?(kr=Fl==null?void 0:Fl.find(dr=>{var vr;return((vr=Object.keys(dr))==null?void 0:vr[0])===hr.value[Ll].column}))==null?void 0:kr[hr.value[Ll].column]:xl:Ml[hr.value[Ll].prop]=xl}else Array.isArray(xl)&&((on=hr.value[Ll])!=null&&on.prop?Ml[hr.value[Ll].prop]=xl:Ml.children=wt(xl,hr.value))})}else Ml=dl;if(Array.isArray(dl)&&dl.some(Fl=>Fl==null?void 0:Fl.id)){const Fl=(Nr=dl==null?void 0:dl.find(xl=>xl.id))==null?void 0:Nr.id;Va.push(Object.assign(Ml,{id:co(Fl)}))}else Ml.id?Va.push(Ml):Va.push(Object.assign(Ml,{id:Tl.toString()}))});const ul=(ze.value||[]).map(dl=>String(dl==null?void 0:dl.id)),Ga=vi(Va,ul);ze.value=jt(Ga,ne,F.value)}Pt(ze.value),jr.value=ze.value;const re=Vf(jr.value,Wr.value,D);let q=[];if(H.value?(q=(Qa=A.cloneDeep(H).value.singleContent)==null?void 0:Qa.filter(Va=>(Va==null?void 0:Va.id)!==(P==null?void 0:P.id)),q.push(P)):q=[P],Vl.value){const Va={content:re,singleContent:((wa=ne==null?void 0:ne.contents)==null?void 0:wa.length)>0?q==null?void 0:q.flatMap($t):q,index:u==null?void 0:u.index,buttonName:"编辑",column:F.value,parentTableId:u==null?void 0:u.parentTableId};ua.setCacheUpdatingData(Va)}if((el=F.value)==null||el.forEach(Va=>{(Va==null?void 0:Va.formType)==="Upload"&&(P[Va.prop]=P[Va.prop]===""?"{}":typeof P[Va.prop]!="string"?JSON.stringify(P[Va.prop]):P[Va.prop])}),p){(Da=(ka=(Ra=(ve=u.itemData)==null?void 0:ve.find(Ga=>(Ga==null?void 0:Ga.key)==="filterAllType"))==null?void 0:Ra.value)==null?void 0:ka.find(Ga=>(Ga==null?void 0:Ga.value)==="onConditionContents"))==null||Da.content;let Va=(Ea=u.itemData)==null?void 0:Ea.filter(Ga=>(Ga==null?void 0:Ga.key)==="filterAllType");Va=Array.from(new Map(Va.filter(Boolean).map((Ga,dl)=>[Ga.value,{...Ga,_idx:dl}])).values()).sort((Ga,dl)=>Ga._idx-dl._idx).map(({_idx:Ga,...dl})=>dl),Va=(B=Va==null?void 0:Va[(Va==null?void 0:Va.length)-1])==null?void 0:B.value;const ul={fixContent:[P],buttonName:ye.value,relatedContents:u==null?void 0:u.related,columns:F.value,name:u==null?void 0:u.groupNames};ua.setTableLoading(u==null?void 0:u.index),Ne.value=!1,Al.value=void 0,Be("change",ul)}if((sa=($e=(G=Ae.value)==null?void 0:G[0])==null?void 0:$e.optionUrl)!=null&&sa.menuId){Ne.value=!1;let Va=(xe=u.itemData)==null?void 0:xe.filter(ul=>(ul==null?void 0:ul.key)==="filterAllType");if((Va==null?void 0:Va.length)>0){let ul=Va==null?void 0:Va.map(Tl=>Tl==null?void 0:Tl.value),Ga=(il=(Na=(da=ul.flat().find(Tl=>{var Ml;return(Ml=Tl==null?void 0:Tl.content)==null?void 0:Ml.includes("@Num")}))==null?void 0:da.content)==null?void 0:Na.split(":"))==null?void 0:il[1];((fl=(pl=(qa=ul.flat().find(Tl=>{var Ml;return(Ml=Tl==null?void 0:Tl.content)==null?void 0:Ml.includes("@Type:")}))==null?void 0:qa.content)==null?void 0:pl.split(":"))==null?void 0:fl[1])!=="Manual"&&(Ga=parseInt(Ga),ze.value=(bl=ze.value)==null?void 0:bl.slice(((Ul=ze.value)==null?void 0:Ul.length)-Ga,(Fa=ze.value)==null?void 0:Fa.length))}}};e.onUnmounted(()=>{window.removeEventListener("keydown",ao),F.value=[],ze.value=[],Ce.value=[],Ca.value=[],Pa.value=[],Sa.value=[],Ve.value=[],Re.value=[],Ae.value=[],ql.value=[],i.value=null,Fn.value=""});const ho=async(p,v,T)=>{var Qe,xa,za,La,ea,Qa,wa,el,ve,Ra,ka,Da,Ea;fr.value=(T==null?void 0:T.prop)??(T==null?void 0:T.property);const z=A.cloneDeep(u.itemData),P=((Qe=z==null?void 0:z.find(B=>(B==null?void 0:B.key)==="header"))==null?void 0:Qe.contents)??[];let D=P==null?void 0:P.find((B,G)=>{var $e,sa,xe;return(B==null?void 0:B.prop)===fr.value||(B==null?void 0:B.label)===fr.value||(G==null?void 0:G.toString())===((xe=(sa=($e=fr.value)==null?void 0:$e.split("a"))==null?void 0:sa[1])==null?void 0:xe.toString())});const ne=te.getColumnChild((xa=A.cloneDeep(F.value))==null?void 0:xa.filter(B=>(B==null?void 0:B.label)!=="操作"));if(D||(D=ne==null?void 0:ne.find(B=>(B==null?void 0:B.prop)===fr.value||(B==null?void 0:B.label)===fr.value)),D&&!((za=D==null?void 0:D.menus)!=null&&za.length)&&!((La=D==null?void 0:D.groups)!=null&&La.length)&&!((ea=D==null?void 0:D.words)!=null&&ea.length)){const B=(Qa=Ae.value)==null?void 0:Qa.find(G=>(G==null?void 0:G.prop)===fr.value);B&&(D={...D,menus:(B==null?void 0:B.menus)??(D==null?void 0:D.menus),groups:(B==null?void 0:B.groups)??(D==null?void 0:D.groups),words:(B==null?void 0:B.words)??(D==null?void 0:D.words),bindMenus:(B==null?void 0:B.bindMenus)??(D==null?void 0:D.bindMenus),isMainPath:(B==null?void 0:B.isMainPath)??(D==null?void 0:D.isMainPath),relatedContents:(B==null?void 0:B.relatedContents)??(D==null?void 0:D.relatedContents),endChildMenu:(B==null?void 0:B.endChildMenu)??(D==null?void 0:D.endChildMenu)})}if(D&&((wa=Ae==null?void 0:Ae.value)==null||wa.forEach(B=>{var G,$e,sa,xe,da;(B==null?void 0:B.prop)===(D==null?void 0:D.prop)&&(B!=null&&B.endChildMenu)&&((G=D==null?void 0:D.prop)!=null&&G.includes(".")&&((sa=($e=D==null?void 0:D.prop)==null?void 0:$e.split("."))==null?void 0:sa[0])!==((da=(xe=B==null?void 0:B.prop)==null?void 0:xe.split("."))==null?void 0:da[0])?D.endChildMenu=B==null?void 0:B.value:D.endChildMenu=B==null?void 0:B.endChildMenu)})),!D)return;const re=fr.value,q=(el=ze.value)==null?void 0:el.findIndex(B=>(B==null?void 0:B.id)===(v==null?void 0:v.id));q!==-1&&re&&(ze.value[q]={...ze.value[q],[re]:p});const be=B=>{Array.isArray(B)&&B.forEach(G=>{Array.isArray(G==null?void 0:G.allSelectionContents)&&G.allSelectionContents.length>0&&(G.contactValue=ze.value[q]??v),Array.isArray(G==null?void 0:G.children)&&G.children.length>0&&be(G.children)})};be(F.value),D.value=p,D.endChildMenu=D.endChildMenu||"";let Ee=D!=null&&D.isMainPath&&(D!=null&&D.mainKey)?D==null?void 0:D.value:"";const Ye=B=>{Array.isArray(B)&&B.forEach(G=>{var sa,xe;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=(xe=D==null?void 0:D.prop)!=null&&xe.includes(".")?D.prop.split(".")[0]:null;(!da||!Na||da===Na)&&(G.endChildMenu=Ee)}Array.isArray(G==null?void 0:G.children)&&G.children.length>0&&Ye(G.children)})};if(Ye(F.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 B=D!=null&&D.relatedContents&&((ve=D==null?void 0:D.relatedContents)==null?void 0:ve.length)>0?(Ra=D==null?void 0:D.relatedContents)==null?void 0:Ra.find(G=>{var $e,sa,xe,da;return(G==null?void 0:G[(da=($e=D==null?void 0:D.prop)==null?void 0:$e.split("."))==null?void 0:da[((xe=(sa=D==null?void 0:D.prop)==null?void 0:sa.split("."))==null?void 0:xe.length)-1]])===(D==null?void 0:D.value)}):await hs(D);if(B){const G={...v};ne==null||ne.forEach($e=>{var sa,xe,da,Na,il,qa,pl,fl,Ul,Fa,bl,Va,ul,Ga,dl,Tl;($e==null?void 0:$e.prop)!==(D==null?void 0:D.prop)&&(D!=null&&D.relatedContents&&((sa=D==null?void 0:D.relatedContents)==null?void 0:sa.length)>0?(xe=$e==null?void 0:$e.prop)!=null&&xe.includes(".")&&((Na=(da=$e==null?void 0:$e.prop)==null?void 0:da.split("."))==null?void 0:Na[0])===((qa=(il=D==null?void 0:D.prop)==null?void 0:il.split("."))==null?void 0:qa[0])?G[$e.prop]=B[(Fa=(pl=$e==null?void 0:$e.prop)==null?void 0:pl.split("."))==null?void 0:Fa[((Ul=(fl=$e==null?void 0:$e.prop)==null?void 0:fl.split("."))==null?void 0:Ul.length)-1]]??G[$e.prop]:G[$e.prop]=(B==null?void 0:B[$e.prop])??G[$e.prop]:te.same((D==null?void 0:D.menus)??[],($e==null?void 0:$e.menus)??[])&&te.same((D==null?void 0:D.groups)??[],($e==null?void 0:$e.groups)??[])&&!te.same((D==null?void 0:D.words)??[],($e==null?void 0:$e.words)??[])?(bl=$e==null?void 0:$e.prop)!=null&&bl.includes(".")&&((ul=(Va=$e==null?void 0:$e.prop)==null?void 0:Va.split("."))==null?void 0:ul[0])!==((dl=(Ga=D==null?void 0:D.prop)==null?void 0:Ga.split("."))==null?void 0:dl[0])||(G[$e.prop]=(B==null?void 0:B[(Tl=$e==null?void 0:$e.words)==null?void 0:Tl.join(".")])??(B==null?void 0:B[$e.prop])??G[$e.prop]):(!($e!=null&&$e.isMainPath)&&te.same((D==null?void 0:D.bindMenus)??[],($e==null?void 0:$e.bindMenus)??[]),G[$e.prop]=(B==null?void 0:B[$e.prop])??G[$e.prop]))}),ze.value=(ka=A.cloneDeep(ze.value))==null?void 0:ka.map($e=>($e==null?void 0:$e.id)===(v==null?void 0:v.id)?{...G,id:$e==null?void 0:$e.id}:$e)}}if((Da=D==null?void 0:D.optionUrl)!=null&&Da.menuSelect){let B="";ne==null||ne.forEach(sa=>{var xe,da,Na,il,qa;B===""&&((Na=(da=(xe=sa==null?void 0:sa.optionUrl)==null?void 0:xe.groupSelect)==null?void 0:da[1])!=null&&Na.includes("["))&&(B=(qa=(il=sa==null?void 0:sa.optionUrl)==null?void 0:il.groupSelect)==null?void 0:qa[1])});let G=await _t(D),$e;if(G==null||G.forEach(sa=>{var xe,da,Na,il,qa,pl,fl,Ul,Fa,bl;B===((da=(xe=D==null?void 0:D.optionUrl)==null?void 0:xe.groupSelect)==null?void 0:da[1])&&((qa=(il=(Na=D==null?void 0:D.optionUrl)==null?void 0:Na.groupSelect)==null?void 0:il[1])!=null&&qa.includes("["))&&((bl=A.cloneDeep(sa))==null?void 0:bl[(Fa=(Ul=(fl=(pl=D==null?void 0:D.optionUrl)==null?void 0:pl.groupSelect)==null?void 0:fl[1])==null?void 0:Ul.replaceAll("[",""))==null?void 0:Fa.replaceAll("]","")])===(D==null?void 0:D.value)&&($e=sa)}),$e){const sa={...v};ne==null||ne.forEach(xe=>{var da,Na,il,qa,pl,fl,Ul,Fa,bl,Va,ul;($e!=null&&$e[xe==null?void 0:xe.label]||$e!=null&&$e[(qa=(il=(Na=(da=xe==null?void 0:xe.optionUrl)==null?void 0:da.groupSelect)==null?void 0:Na[1])==null?void 0:il.replaceAll("[",""))==null?void 0:qa.replaceAll("]","")])&&((Ul=(fl=(pl=xe==null?void 0:xe.optionUrl)==null?void 0:pl.groupSelect)==null?void 0:fl[1])!=null&&Ul.includes("["))&&(sa[xe.prop]=($e==null?void 0:$e[xe==null?void 0:xe.label])||($e==null?void 0:$e[(ul=(Va=(bl=(Fa=xe==null?void 0:xe.optionUrl)==null?void 0:Fa.groupSelect)==null?void 0:bl[1])==null?void 0:Va.replaceAll("[",""))==null?void 0:ul.replaceAll("]","")]))}),ze.value=(Ea=A.cloneDeep(ze.value))==null?void 0:Ea.map(xe=>(xe==null?void 0:xe.id)===(v==null?void 0:v.id)?{...sa,id:xe==null?void 0:xe.id}:xe)}}},yu=async p=>{var Qe,xa,za,La,ea,Qa,wa,el,ve,Ra,ka,Da,Ea,B;if(!p)return;const v=A.cloneDeep(Al.value||{});Al.value=p;const T=ji(v),z=ji(Al.value);if(z&&z!==T&&await ut(z,Ma.value||void 0)){ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择"),fo.forEach($e=>{if(Object.prototype.hasOwnProperty.call(Al.value||{},$e)||Object.prototype.hasOwnProperty.call(v||{},$e)){const sa=(v==null?void 0:v[$e])??"";Al.value[$e]=sa,p[$e]=sa}}),Ae.value=(Ae.value||[]).map($e=>{if(!($e!=null&&$e.prop)||!fo.includes($e.prop))return $e;const sa=(v==null?void 0:v[$e.prop])??"";return{...$e,value:sa,selectValue:sa===""?[]:[sa]}});return}let P=A.cloneDeep(u.itemData);P==null||P.map(G=>{var $e,sa,xe,da;return(G==null?void 0:G.key)==="header"&&(Array.isArray(($e=G.contents)==null?void 0:$e[0])?G.contents=(xe=te.getColumnChild((sa=G.contents)==null?void 0:sa[0]))==null?void 0:xe.map((Na,il)=>{var qa,pl,fl,Ul,Fa,bl;return((fl=(pl=(qa=Ae.value)==null?void 0:qa.find(Va=>(Va==null?void 0:Va.prop)===(Na==null?void 0:Na.prop)))==null?void 0:pl.optionUrl)==null?void 0:fl.multiple)===!0&&!Array.isArray((Ul=Object.values(p))==null?void 0:Ul[il])?Na.value=[(Fa=Object.values(p))==null?void 0:Fa[il]]:Na.value=(bl=Object.values(p))==null?void 0:bl[il],Na}):G.contents=(da=G.contents)==null?void 0:da.map((Na,il)=>{var qa,pl,fl,Ul,Fa,bl;return((fl=(pl=(qa=Ae.value)==null?void 0:qa.find(Va=>(Va==null?void 0:Va.prop)===(Na==null?void 0:Na.prop)))==null?void 0:pl.optionUrl)==null?void 0:fl.multiple)===!0&&!Array.isArray((Ul=Object.values(p))==null?void 0:Ul[il])?Na.value=[(Fa=Object.values(p))==null?void 0:Fa[il]]:Na.value=(bl=Object.values(p))==null?void 0:bl[il],Na})),G});let D=Ae.value,ne=(Qe=P==null?void 0:P.find(G=>(G==null?void 0:G.key)==="header"))==null?void 0:Qe.contents;if(fr.value||(D=D==null?void 0:D.map(G=>{var $e;return G.value=G.value??(($e=ne==null?void 0:ne.find((sa,xe)=>(sa==null?void 0:sa.prop)===(G==null?void 0:G.name)))==null?void 0:$e.value),G})),!Vr.value)return;let re=A.cloneDeep(fr.value);(xa=fr.value)!=null&&xa.includes("·")&&(fr.value=(La=(za=fr.value)==null?void 0:za.split("·"))==null?void 0:La[0]);let q=(Qa=(ea=P==null?void 0:P.find(G=>(G==null?void 0:G.key)==="header"))==null?void 0:ea.contents)==null?void 0:Qa.find((G,$e)=>(G==null?void 0:G.prop)===fr.value);(wa=Ae==null?void 0:Ae.value)==null||wa.forEach(G=>{var $e,sa,xe,da,Na,il,qa,pl,fl;(G==null?void 0:G.prop)===(q==null?void 0:q.prop)&&(G!=null&&G.endChildMenu)&&(($e=q==null?void 0:q.prop)!=null&&$e.includes(".")&&((xe=(sa=q==null?void 0:q.prop)==null?void 0:sa.split("."))==null?void 0:xe[0])!==((Na=(da=G==null?void 0:G.prop)==null?void 0:da.split("."))==null?void 0:Na[0])?q.endChildMenu=(qa=(il=G==null?void 0:G.value)==null?void 0:il.split(" "))==null?void 0:qa[0]:q.endChildMenu=(fl=(pl=G==null?void 0:G.endChildMenu)==null?void 0:pl.split(" "))==null?void 0:fl[0])});let be=q!=null&&q.isMainPath&&(q!=null&&q.mainKey)?q==null?void 0:q.value:"",Ee=D,Ye=Y.value;if(Ye!=null&&Ye.find(G=>(q==null?void 0:q.prop)===(G==null?void 0:G.key))&&(Ye=Ye==null?void 0:Ye.filter(G=>(q==null?void 0:q.prop)!==(G==null?void 0:G.key))),Ye!=null&&Ye.find(G=>re===(G==null?void 0:G.key))&&(Ye=Ye==null?void 0:Ye.filter(G=>re!==(G==null?void 0:G.key))),(q==null?void 0:q.formType)==="Select"?Ee=Ee==null?void 0:Ee.map(G=>{var $e,sa,xe,da,Na,il,qa,pl,fl,Ul,Fa,bl,Va,ul,Ga,dl;return(G==null?void 0:G.type)==="Select"&&((($e=G==null?void 0:G.allSelectionContents)==null?void 0:$e.length)>0&&(G.contactValue=p),((q==null?void 0:q.prop)===(G==null?void 0:G.prop)||re===(G==null?void 0:G.prop))&&q&&(Array.isArray(q.value)&&((sa=q.value)==null?void 0:sa.length)>0&&((xe=q.value)!=null&&xe.every(Tl=>typeof Tl=="string"))?(Ye.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=(il=Ye==null?void 0:Ye.find(Tl=>(Tl==null?void 0:Tl.key)===(G==null?void 0:G.prop)))==null?void 0:il.value):Array.isArray(q.value)&&((qa=q.value)==null?void 0:qa.length)===0?(Ye=[],G.selectValue=[],p[G==null?void 0:G.prop]=""):Array.isArray(G.value)&&Ye.push({key:G==null?void 0:G.prop,value:[(pl=G.value)==null?void 0:pl[(G==null?void 0:G.length)-1]]})),((Ul=G==null?void 0:G.menus)==null?void 0:Ul[((fl=G==null?void 0:G.menus)==null?void 0:fl.length)-1])===""&&(q!=null&&q.isMainPath)&&(q!=null&&q.mainKey)&&((Fa=G==null?void 0:G.prop)!=null&&Fa.includes(".")&&((Va=(bl=G==null?void 0:G.prop)==null?void 0:bl.split("."))==null?void 0:Va[0])!==((Ga=(ul=q==null?void 0:q.prop)==null?void 0:ul.split("."))==null?void 0:Ga[0])||(G.endChildMenu=(dl=be==null?void 0:be.split(" "))==null?void 0:dl[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"&&(Ee=Ee==null?void 0:Ee.map(G=>(G.value=(p==null?void 0:p[G==null?void 0:G.prop])??(G==null?void 0:G.value),G))),Y.value=Ye,Ee!=null&&Ee.some(G=>(G==null?void 0:G.functionName)&&(G==null?void 0:G.functionName)!=="")){let G=await xt([p],F==null?void 0:F.value,"Auto",ze.value),$e=[];(el=Ee==null?void 0:Ee.filter(xe=>(xe==null?void 0:xe.functionName)&&(xe==null?void 0:xe.functionName)!==""))==null||el.forEach(xe=>{var da;((da=xe==null?void 0:xe.functionRelatedWords)==null?void 0:da.length)>0&&($e=[...$e,...xe==null?void 0:xe.functionRelatedWords])}),$e=$e==null?void 0:$e.filter(xe=>(xe==null?void 0:xe[0])!=="@");let sa=[];for(let xe in G==null?void 0:G[0])$e!=null&&$e.find(da=>xe===da||(xe==null?void 0:xe.includes("."+da)))&&sa.push(((ve=G==null?void 0:G[0])==null?void 0:ve[xe])!=="");(G==null?void 0:G.length)>0&&sa.every(xe=>xe)&&(Ee=Ee==null?void 0:Ee.map(xe=>{var da;return xe.value=((da=G==null?void 0:G[0])==null?void 0:da[xe==null?void 0:xe.prop])??xe.value,xe})),Al.value=G==null?void 0:G[0]}if(Ae.value=Ee,q=Object.assign({},q??{},{relatedWords:(ka=(Ra=Ae==null?void 0:Ae.value)==null?void 0:Ra.find(G=>(G==null?void 0:G.prop)===(q==null?void 0:q.prop)))==null?void 0:ka.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($e=>{var sa,xe,da,Na;return($e==null?void 0:$e[(Na=(sa=q==null?void 0:q.prop)==null?void 0:sa.split("."))==null?void 0:Na[((da=(xe=q==null?void 0:q.prop)==null?void 0:xe.split("."))==null?void 0:da.length)-1]])===(q==null?void 0:q.value)}):await hs(q);if(G&&JSON.stringify(G)!=="{}"){let $e=Ee;$e=$e==null?void 0:$e.map(xe=>{var da,Na,il,qa,pl,fl,Ul,Fa,bl,Va,ul,Ga,dl,Tl,Ml,Nr,Fl,xl,Ll,Zl,Ol;if((q==null?void 0:q.prop)===(xe==null?void 0:xe.prop))xe.value=(G==null?void 0:G[(da=xe==null?void 0:xe.words)==null?void 0:da.join(".")])??(G==null?void 0:G[xe==null?void 0:xe.prop])??G[(pl=(Na=xe==null?void 0:xe.prop)==null?void 0:Na.split("."))==null?void 0:pl[((qa=(il=xe==null?void 0:xe.prop)==null?void 0:il.split("."))==null?void 0:qa.length)-1]];else if(q!=null&&q.relatedContents&&((fl=q==null?void 0:q.relatedContents)==null?void 0:fl.length)>0)xe.value=(Ul=xe==null?void 0:xe.prop)!=null&&Ul.includes(".")&&((bl=(Fa=xe==null?void 0:xe.prop)==null?void 0:Fa.split("."))==null?void 0:bl[0])===((ul=(Va=q==null?void 0:q.prop)==null?void 0:Va.split("."))==null?void 0:ul[0])?G[(Ml=(Ga=xe==null?void 0:xe.prop)==null?void 0:Ga.split("."))==null?void 0:Ml[((Tl=(dl=xe==null?void 0:xe.prop)==null?void 0:dl.split("."))==null?void 0:Tl.length)-1]]:(G==null?void 0:G[xe==null?void 0:xe.prop])??(xe==null?void 0:xe.value);else if(te.same((q==null?void 0:q.menus)??[],(xe==null?void 0:xe.menus)??[])&&te.same((q==null?void 0:q.groups)??[],(xe==null?void 0:xe.groups)??[])&&!te.same((q==null?void 0:q.words)??[],(xe==null?void 0:xe.words)??[]))if((Nr=xe==null?void 0:xe.prop)!=null&&Nr.includes(".")&&((xl=(Fl=xe==null?void 0:xe.prop)==null?void 0:Fl.split("."))==null?void 0:xl[0])!==((Zl=(Ll=q==null?void 0:q.prop)==null?void 0:Ll.split("."))==null?void 0:Zl[0])){let Xl=Object.keys(G);Xl=Xl==null?void 0:Xl.find(tr=>{var Yl;return tr==null?void 0:tr.includes("."+((Yl=xe==null?void 0:xe.words)==null?void 0:Yl.join(".")))}),xe.value=(G==null?void 0:G[Xl])??(G==null?void 0:G[xe==null?void 0:xe.prop])??xe.value}else{let Xl=Object.keys(G);Xl=Xl==null?void 0:Xl.find(tr=>{var Yl;return tr==null?void 0:tr.includes("."+((Yl=xe==null?void 0:xe.words)==null?void 0:Yl.join(".")))}),xe.value=(G==null?void 0:G[(Ol=xe==null?void 0:xe.words)==null?void 0:Ol.join(".")])??(G==null?void 0:G[Xl])??(G==null?void 0:G[xe==null?void 0:xe.prop])??xe.value}else!(xe!=null&&xe.isMainPath)&&te.same((q==null?void 0:q.bindMenus)??[],(xe==null?void 0:xe.bindMenus)??[]),xe.value=(G==null?void 0:G[xe==null?void 0:xe.prop])??xe.value;return xe}),Ae.value=$e;let sa={};(B=Ae.value)==null||B.forEach(xe=>{sa[xe.prop]=xe==null?void 0:xe.value}),Al.value=sa}}Vr.value=!0,I.value=!1},gu=p=>p?(p==null?void 0:p.toUpperCase())==="INPUT"?"TEXTAREA":p:"TEXTAREA",bu=p=>{var D,ne;const v=(ne=(D=Pa.value)==null?void 0:D.find(re=>(re==null?void 0:re.label)===(p==null?void 0:p.label)))==null?void 0:ne.multiple,T=p==null?void 0:p.prop;if((p==null?void 0:p.formType)!="Select")return;ze.value.forEach(re=>{const q=re==null?void 0:re[T];v&&No.isString(q)&&(re[T]=[q]),!v&&!No.isString(q)&&(re[T]="")})},Vt=(p,v)=>{var T;return v==null||v.forEach(z=>{p[z==null?void 0:z.prop]=z==null?void 0:z.value}),p.children&&((T=p.children)==null?void 0:T.length)>0&&(p.children=p.children.map(z=>Vt(z,v))),p},dt=p=>{var T,z,P,D,ne,re;Fi("");const v=(T=Ae.value)==null?void 0:T.reduce((q,be)=>(q[be.name]=be.value,q),{});if(((z=Object.keys(v))==null?void 0:z.length)>0){Al.value=v,Ma.value="",Ba.value=(P=ze.value)==null?void 0:P.length,Re.value=(D=We.value)==null?void 0:D.filter(be=>(be==null?void 0:be.label)!=="新增");const q=(re=(ne=Ce.value)==null?void 0:ne.filter(be=>(be==null?void 0:be.label)!=="操作"))==null?void 0:re.map(be=>{var Ye,qe,Qe;const Ee=(qe=(Ye=Pa.value)==null?void 0:Ye.find(xa=>(xa==null?void 0:xa.label)===(be==null?void 0:be.label)))==null?void 0:qe.multiple;return bu(be),{...be,contents:(be==null?void 0:be.options)??[],optionUrl:be!=null&&be.formMenuSelect&&((Qe=be==null?void 0:be.formMenuSelect)==null?void 0:Qe.length)>0?{groupSelect:be==null?void 0:be.groupSelect,menuSelect:be==null?void 0:be.formMenuSelect,selectRelateType:"",type:be==null?void 0:be.formType,multiple:Ee}:null}});F.value=q==null?void 0:q.map(be=>Vt(be,[{prop:"type",value:"edit"},{prop:"columnType",value:gu(be==null?void 0:be.formType)||(be==null?void 0:be.columnType)}])),p==="createClick"&&(ye.value="新增",Hi(!0))}},ki={START:"开始时间",END:"结束时间",HOURS:"工时"},ku=(p,v)=>Number(A.dayjs(v).diff(A.dayjs(p),"day",!0).toFixed(1)),Pt=p=>{var D;const v=u.itemData,T=(D=v==null?void 0:v.find(ne=>(ne==null?void 0:ne.key)==="header"))==null?void 0:D.contents,z=new Map;return T==null||T.forEach((ne,re)=>{const{label:q}=ne;z.set(q,re)}),!z.has(ki.START)||!z.has(ki.END)||!z.has(ki.HOURS)?p:p==null?void 0:p.map(ne=>{const re=ne==null?void 0:ne[ki.START],q=ne==null?void 0:ne[ki.END],be=ku(re,q);return re&&q&&(ne[ki.HOURS]=`${be}天`),ne})},Ft=(p,v,T=0)=>{if(T>((v==null?void 0:v.length)??""))return p;const z=v==null?void 0:v[T],P=new Map;for(const ne of p){const re=ne[z];P.has(re)||P.set(re,[]),P.get(re)&&P.get(re).push(ne)}const D=[];for(const[ne,re]of P){const[q,...be]=re,Ee={...q};T+1===((v==null?void 0:v.length)??"")?Ee.children=re==null?void 0:re.map(Ye=>(Ye.level=A.cloneDeep(T)+1,Ye)).filter((Ye,qe)=>qe!==0):be.length>0&&(Ee.children=Ft(be,v,T+1)),Ee.level=T,D.push(Ee)}return D},jt=(p,v,T)=>{var P;if(!(v!=null&&v.contents)||((P=v==null?void 0:v.contents)==null?void 0:P.length)===0)return p;let z=[];return z=Ft(p,v==null?void 0:v.contents,0),z},Ht=async(p,v)=>{var ea,Qa,wa,el,ve,Ra,ka,Da,Ea,B,G,$e,sa,xe,da,Na,il,qa,pl,fl,Ul,Fa,bl,Va,ul,Ga,dl,Tl,Ml,Nr,Fl,xl,Ll,Zl,Ol,Xl,tr,Yl,kr,on,xr,dr,vr,qt,Wt,Kt,Gt,Yt;const T=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 z=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="childTree")[0];let P=!0;if((wa=(Qa=(ea=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="filterAllType"))==null?void 0:ea.value)==null?void 0:Qa.find(oa=>(oa==null?void 0:oa.value)==="onPamButtonContents"))!=null&&wa.content){let oa=(Ra=(ve=(el=p==null?void 0:p.find(El=>(El==null?void 0:El.key)==="filterAllType"))==null?void 0:el.value)==null?void 0:ve.find(El=>(El==null?void 0:El.value)==="onPamButtonContents"))==null?void 0:Ra.content;oa=(ka=oa==null?void 0:oa.split(":"))==null?void 0:ka[1],oa=(Da=oa.slice(1,(oa==null?void 0:oa.length)-1))==null?void 0:Da.split(","),P=!!(oa!=null&&oa.find(El=>El==="操作"))}const D=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="page"),ne=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="rowButton"),re=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"),be=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="bottomButton");let Ee=[];const Ye=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="tableIndex");Pa.value=(B=(Ea=p==null?void 0:p.filter(oa=>(oa==null?void 0:oa.key)==="tableToForm"))==null?void 0:Ea[0])==null?void 0:B.contents,Te.value=(D==null?void 0:D.contents)??!0;let qe=[];lr.value===""?qe=T==null?void 0:T[0]:qe=(T==null?void 0:T.find(oa=>(oa==null?void 0:oa.selectLabel)==="("+lr.value+")"))??(T==null?void 0:T.find(oa=>!(oa!=null&&oa.selectLabel)));let Qe=[];lr.value===""?Qe=Ye==null?void 0:Ye[0]:Qe=(Ye==null?void 0:Ye.find(oa=>(oa==null?void 0:oa.selectLabel)==="("+lr.value+")"))??(Ye==null?void 0:Ye.find(oa=>!(oa!=null&&oa.selectLabel)));let xa=[],za=[];if(((G=qe==null?void 0:qe.contents)==null?void 0:G.length)>0){let oa=[],El=qe==null?void 0:qe.contents;if(Array.isArray(El==null?void 0:El[0])&&(($e=El==null?void 0:El[0])!=null&&$e.every(Ya=>!(Ya!=null&&Ya.children)))&&(El=El==null?void 0:El[0]),El.some(Ya=>Array.isArray(Ya)&&(Ya==null?void 0:Ya.find(Je=>Je.children))))oa=(sa=te.getGradeColumns(El,P))==null?void 0:sa[0],oa!=null&&oa.find(Ya=>(Ya==null?void 0:Ya.label)==="操作")||oa.push({label:"操作",prop:"operate",type:"operate"});else{let Ya=El.some(Je=>Array.isArray(Je))?El==null?void 0:El[0]:El;Ya!=null&&Ya.find(Je=>(Je==null?void 0:Je.label)==="操作")||Ya.push({label:"操作",prop:"operate",type:"operate"}),Ya==null||Ya.forEach((Je,rr)=>{var Fr,Yr,Ir,oi,xi,wi,Tr,Bn,Un,_i,yn,qn,Jt,Xt,Zt,Qt,es,as,ls,rs,ns;if((Yr=(Fr=we.value)==null?void 0:Fr.split("/"))==null||Yr.forEach(sr=>{var wr,zn,is;sr!==""&&((is=(zn=(wr=sr==null?void 0:sr.split(S+"updateLoading"))==null?void 0:wr[0])==null?void 0:zn.split(S+"loading"))==null||is[0])}),Je!=null&&Je.methodContent){let sr=(xi=(oi=(Ir=Je==null?void 0:Je.methodContent)==null?void 0:Ir.replace("@","%%#"))==null?void 0:oi.split("%%#"))==null?void 0:xi[1];if(sr=sr==null?void 0:sr.slice(0,(sr==null?void 0:sr.length)-1),sr=te.contentTransArrayToAllNoExtra(sr??"",","),(wi=sr==null?void 0:sr.find(wr=>wr==null?void 0:wr.includes("@Button")))!=null&&wi.includes("Prop")&&((Tr=sr==null?void 0:sr.find(wr=>wr==null?void 0:wr.includes("Type")))!=null&&Tr.includes("Manual"))){let wr=(Un=(Bn=sr==null?void 0:sr.find(zn=>zn==null?void 0:zn.includes("@Button")))==null?void 0:Bn.split(":"))==null?void 0:Un[1];wr=((qn=(yn=(_i=wr==null?void 0:wr.replaceAll("[",""))==null?void 0:_i.replaceAll("]",""))==null?void 0:yn.split(","))==null?void 0:qn[1])??"算法执行",xa.push(wr)}else if((Jt=sr==null?void 0:sr.find(wr=>wr==null?void 0:wr.includes("@Button")))!=null&&Jt.includes("Row")&&((Xt=sr==null?void 0:sr.find(wr=>wr==null?void 0:wr.includes("Type")))!=null&&Xt.includes("Manual"))){let wr=(Qt=(Zt=sr==null?void 0:sr.find(zn=>zn==null?void 0:zn.includes("@Button")))==null?void 0:Zt.split(":"))==null?void 0:Qt[1];wr=((ls=(as=(es=wr==null?void 0:wr.replaceAll("[",""))==null?void 0:es.replaceAll("]",""))==null?void 0:as.split(","))==null?void 0:ls[1])??"算法执行",za.push(wr)}}(rs=Pa.value)==null||rs.find(sr=>(sr==null?void 0:sr.prop)===(Je==null?void 0:Je.prop));let en=((ns=Je==null?void 0:Je.filter)==null?void 0:ns.includes("@EditRead=Read"))??!1;oa.push({label:(Je==null?void 0:Je.label)==="操作"?P?"操作":"":(Je==null?void 0:Je.label)??"",prop:(Je==null?void 0:Je.label)==="操作"?"operate":(Je==null?void 0:Je.prop)??"a"+rr,width:Je!=null&&Je.width?parseInt(Je.width):"",fixed:(Je==null?void 0:Je.fixed)??void 0,sortable:(Je==null?void 0:Je.sortable)??!1,filterable:(Je==null?void 0:Je.filterable)??!1,operable:(Je==null?void 0:Je.operable)??!1,showSummary:(Je==null?void 0:Je.showSummary)??!1,align:(Je==null?void 0:Je.align)??"left",showOverflowTooltip:(Je==null?void 0:Je.showOverflowTooltip)??!0,isNotDrag:(Je==null?void 0:Je.isNotDrag)??!1,isEditCol:(Je==null?void 0:Je.isEditCol)??!1,isOperate:(Je==null?void 0:Je.isOperate)??!1,id:(Je==null?void 0:Je.id)??rr,type:(Je==null?void 0:Je.label)==="操作"?"operate":void 0,formType:(Je==null?void 0:Je.formType)??(Je!=null&&Je.groupSelect?"Select":""),disabled:Je==null?void 0:Je.disabled,options:(Je==null?void 0:Je.options)??[],value:(Je==null?void 0:Je.value)??"",isExistChild:(Je==null?void 0:Je.isExistChild)??!1,mainKey:(Je==null?void 0:Je.mainKey)??rr===0,allSelectionContents:(Je==null?void 0:Je.allContents)??[],filterContent:Je==null?void 0:Je.filterContents,menus:Je==null?void 0:Je.menus,groups:Je==null?void 0:Je.groups,words:Je==null?void 0:Je.words,filter:Je==null?void 0:Je.filter,bindMenus:Je==null?void 0:Je.bindMenus,fatherPath:Je==null?void 0:Je.fatherPath,isMainPath:Je==null?void 0:Je.isMainPath,required:(Je==null?void 0:Je.required)??!1,relatedContents:Je==null?void 0:Je.relatedContents,functionName:Je==null?void 0:Je.functionName,functionRelatedWords:Je==null?void 0:Je.functionRelatedWords,calculatorFilter:Je==null?void 0:Je.calculatorFilter,relatedPages:Je==null?void 0:Je.relatedPages,multiple:(Je==null?void 0:Je.multiple)??!1,multipleLimit:Je==null?void 0:Je.multipleLimit,isReadonly:en})})}j.value=(xe=be==null?void 0:be[0])==null?void 0:xe.contents;const Qr=te.getNewColumnChild(oa);Ee=te.getColumnChild(Qr);const Hn=Ya=>Array.isArray(Ya)?Ya.map(Je=>(Array.isArray(Je==null?void 0:Je.children)&&Je.children.length>0?(Je.sortable=!1,Hn(Je.children)):(Je==null?void 0:Je.prop)==="operate"||(Je==null?void 0:Je.label)==="操作"||(Je==null?void 0:Je.type)==="operate"||(Je.sortable=!1),Je)):Ya;Hn(Qr),await no(Qr),s0(ie.value,Qr),F.value=Qr,Ca.value=Qr,n.value=(da=F.value)==null?void 0:da.map(Ya=>Ya==null?void 0:Ya.label);let zr=(il=(Na=te.getAllLeafNodes(F.value))==null?void 0:Na.filter(Ya=>(Ya==null?void 0:Ya.type)!=="operate"))==null?void 0:il.map((Ya,Je)=>({prop:(Ya==null?void 0:Ya.prop)??"a"+Je,column:Ya.label}));hr.value=zr;let Lr=[];lr.value===""?Lr=q==null?void 0:q[0]:Lr=(q==null?void 0:q.find(Ya=>(Ya==null?void 0:Ya.selectLabel)==="("+lr.value+")"))??(q==null?void 0:q.find(Ya=>!(Ya!=null&&Ya.selectLabel)));let Mr=Array.isArray((qa=Lr==null?void 0:Lr.contents)==null?void 0:qa[0])&&((pl=Lr==null?void 0:Lr.contents)!=null&&pl[0].every(Ya=>Array.isArray(Ya)))?(fl=Lr==null?void 0:Lr.contents)==null?void 0:fl[0]:Lr==null?void 0:Lr.contents;Qe!=null&&Qe.contents&&((Ul=Qe==null?void 0:Qe.contents)==null?void 0:Ul.length)!==0&&(Mr=(Fa=A.cloneDeep(Mr))==null?void 0:Fa.map((Ya,Je)=>{if(!Array.isArray(Ya)){let rr={};for(let en in Ya)en!=="id"&&en!=="index"&&(rr[en]=Ya[en]);Ya=Object.values(rr)}return Ya}));const vo=!!((bl=F.value)!=null&&bl.find(Ya=>Ya.prop==="index"));Mr=vc(Mr,Qe==null?void 0:Qe.contents,vo);const Ln=[];Mr==null||Mr.forEach((Ya,Je)=>{var en;let rr={};if(Array.isArray(Ya)){let Fr=[];Ya==null||Ya.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,R!=null&&R.value&&((xi=R==null?void 0:R.value)==null?void 0:xi.length)>0&&((wi=R==null?void 0:R.value)!=null&&wi.find(yn=>JSON.stringify(yn==null?void 0:yn[0])===JSON.stringify(_i)))&&(Fr=(Tr=R==null?void 0:R.value)==null?void 0:Tr.find(yn=>JSON.stringify(yn==null?void 0:yn[0])===JSON.stringify(_i))),Fr&&Fr.length>0?rr[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:rr[zr[Ir].prop]=Yr}else Array.isArray(Yr)&&((Un=zr[Ir])!=null&&Un.prop?rr[zr[Ir].prop]=Yr:rr.children=wt(Yr,zr))})}else rr=Ya;if(Array.isArray(Ya)&&Ya.some(Fr=>Fr==null?void 0:Fr.id)){const Fr=(en=Ya==null?void 0:Ya.find(Yr=>Yr.id))==null?void 0:en.id;Ln.push(Object.assign(rr,{id:co(Fr)}))}else rr.id?Ln.push(rr):Ln.push(Object.assign(rr,{id:Je.toString()}))});try{const Ya=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),Je=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null"),rr=Ya==null?void 0:Ya.tableId,en=Ya==null?void 0:Ya.compIndex;if(rr&&Array.isArray(Je)&&Je.length>0&&String(rr)===String(u==null?void 0:u.parentTableId)&&String(en)===String(u==null?void 0:u.index)){const Fr=new Set(Ln.map(Ir=>String(Ir==null?void 0:Ir.id))),Yr=Je.filter(Ir=>!Fr.has(String(Ir)));if(Yr.length>0){const Ir=Ya==null?void 0:Ya.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(rr)&&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 Ya=`ocr_committed_temp_ids_v1:${String((u==null?void 0:u.parentTableId)??"")}:${String((u==null?void 0:u.index)??"")}`,Je=JSON.parse(sessionStorage.getItem(Ya)||"null");Array.isArray(Je)&&Je.length>0&&(Rn=new Set(Je.map(rr=>String(rr))))}catch{}const Ui=Array.from(((Va=Oa.value)==null?void 0:Va.values())||[]).filter(Ya=>!(!(Ya!=null&&Ya._isOCRRow&&(Ya==null?void 0:Ya._ocrTableId)===(u==null?void 0:u.index))||Rn&&Rn.has(String(Ya==null?void 0:Ya.id)))),mo=(ze.value||[]).map(Ya=>String(Ya==null?void 0:Ya.id)),Kl=vi(Ln,mo);if(ze.value=jt(Kl,z,F.value),ma.value=Kl,(ul=ma.value)==null||ul.forEach(Ya=>{var Je;(Je=Oa.value)==null||Je.set(Ya.id,Ya)}),Rn&&Rn.size>0)try{const Ya=new Set(Array.from(Rn.values()));ze.value=(ze.value||[]).filter(Je=>!Ya.has(String(Je==null?void 0:Je.id))),ma.value=(ma.value||[]).filter(Je=>!Ya.has(String(Je==null?void 0:Je.id))),Ya.forEach(Je=>{var rr,en;try{(en=(rr=Oa.value)==null?void 0:rr.delete)==null||en.call(rr,Je)}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 Ya=new Set((ma.value||[]).map(Je=>String(Je==null?void 0:Je.id)));pt.filter(Je=>!Ya.has(String(Je)))}if(Ui.length>0){const Ya=new Set((ze.value||[]).map(rr=>rr==null?void 0:rr.id)),Je=Ui.filter(rr=>!Ya.has(rr.id));Je.length>0&&(ze.value=[...ze.value||[],...Je],ma.value=[...ma.value||[],...Je],Je.forEach(rr=>{var en;return(en=Oa.value)==null?void 0:en.set(rr.id,rr)}))}}else F.value=[],Ce.value=[],ze.value=[],ma.value=[],Oa.value=new Map;if(za=[...new Set(za)],za=za==null?void 0:za.map(oa=>({label:oa,type:"methodButton"})),((Ga=ne==null?void 0:ne.contents)==null?void 0:Ga.length)>0?Sa.value=ne==null?void 0:ne.contents:Sa.value=[],Sa.value=[...Sa.value,...za],xa=[...new Set(xa)],xa=xa==null?void 0:xa.map(oa=>({label:oa,type:"methodButton"})),((dl=re==null?void 0:re.contents)==null?void 0:dl.length)>0)if((Nr=(Ml=(Tl=p==null?void 0:p.find(oa=>(oa==null?void 0:oa.key)==="filterAllType"))==null?void 0:Tl.value)==null?void 0:Ml.find(oa=>(oa==null?void 0:oa.value)==="onButtonContents"))!=null&&Nr.content){let oa=(Ll=(xl=(Fl=p==null?void 0:p.find(El=>(El==null?void 0:El.key)==="filterAllType"))==null?void 0:Fl.value)==null?void 0:xl.find(El=>(El==null?void 0:El.value)==="onButtonContents"))==null?void 0:Ll.content;if(oa=(Zl=oa==null?void 0:oa.split(":"))==null?void 0:Zl[1],oa=(Ol=oa.slice(1,(oa==null?void 0:oa.length)-1))==null?void 0:Ol.split(","),Re.value=(Xl=re==null?void 0:re.contents)==null?void 0:Xl.filter(El=>oa==null?void 0:oa.find(Qr=>Qr===(El==null?void 0:El.label))),We.value=(tr=re==null?void 0:re.contents)==null?void 0:tr.filter(El=>oa==null?void 0:oa.find(Qr=>Qr===(El==null?void 0:El.label))),(Yl=re==null?void 0:re.contents)!=null&&Yl.some(El=>(El==null?void 0:El.label)==="OCR识别")&&!((kr=Re.value)!=null&&kr.some(El=>(El==null?void 0:El.label)==="OCR识别"))){const El=(on=re==null?void 0:re.contents)==null?void 0:on.find(Qr=>(Qr==null?void 0:Qr.label)==="OCR识别");Re.value=[...Re.value,El],We.value=[...We.value,El]}W.value=!!(oa!=null&&oa.find(El=>El==="搜索")),V.value=!!(oa!=null&&oa.find(El=>El==="块状显示"))}else Re.value=re==null?void 0:re.contents,We.value=re==null?void 0:re.contents;else Re.value=[],We.value=[];if(Re.value=[...Re.value,...xa],We.value=[...We.value,...xa],typeof we.value=="string"&&we.value==="设备管理/试验设备"&&(u==null?void 0:u.compName)==="设备列表"?((xr=Re.value)!=null&&xr.some(oa=>(oa==null?void 0:oa.label)==="OCR识别")||(Re.value=[...Re.value||[],{label:"OCR识别"}]),(dr=We.value)!=null&&dr.some(oa=>(oa==null?void 0:oa.label)==="OCR识别")||(We.value=[...We.value||[],{label:"OCR识别"}])):(Re.value=(Re.value||[]).filter(oa=>(oa==null?void 0:oa.label)!=="OCR识别"),We.value=(We.value||[]).filter(oa=>(oa==null?void 0:oa.label)!=="OCR识别")),(vr=Re.value)!=null&&vr.some(oa=>(oa==null?void 0:oa.label)==="切换视图")||(Re.value=[...Re.value||[],{label:"切换视图"}]),(qt=We.value)!=null&&qt.some(oa=>(oa==null?void 0:oa.label)==="切换视图")||(We.value=[...We.value||[],{label:"切换视图"}]),Ee!=null&&Ee.some(oa=>{var El;return(oa==null?void 0:oa.calculatorFilter)&&((El=oa==null?void 0:oa.calculatorFilter)==null?void 0:El.includes("@Button"))})){let oa=(Wt=Ee==null?void 0:Ee.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:Wt.map(zr=>zr==null?void 0:zr.calculatorFilter),El=[],Qr=[],Hn=[];oa==null||oa.forEach(zr=>{var vo,Ln,Rn,Ui,mo;let Lr=(vo=te.analyzeSplitToContent(zr,","))==null?void 0:vo.map(Kl=>((Kl==null?void 0:Kl[(Kl==null?void 0:Kl.length)-1])===","&&(Kl=Kl==null?void 0:Kl.slice(0,(Kl==null?void 0:Kl.length)-1)),Kl)),Mr=Lr==null?void 0:Lr.find(Kl=>Kl==null?void 0:Kl.includes("@Button"));if(Lr!=null&&Lr.find(Kl=>Kl==null?void 0:Kl.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 Kl=(Ui=te.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));Kl=Kl==null?void 0:Kl[0],Kl=Kl==null?void 0:Kl.slice(1,(Kl==null?void 0:Kl.length)-1),Kl=(mo=Kl==null?void 0:Kl.split(","))==null?void 0:mo.map(Pr=>({label:Pr,prop:Pr})),Mr!=null&&Mr.includes("Up")?El=[...El,...Kl??[]]:Mr!=null&&Mr.includes("Line")?Qr=[...Qr,...Kl??[]]:Hn=[...Hn,...Kl??[]]}}),Re.value=[...El,...Re.value??[]],Sa.value=[...Qr,...Sa.value??[]],Hn.value=[...Hn,...Hn.value??[]]}Ba.value=((Kt=ze==null?void 0:ze.value)==null?void 0:Kt.length)??0,Pt(ze.value),jr.value=ze.value,Vl.value&&(F.value=(Yt=(Gt=Ce.value)==null?void 0:Gt.filter(oa=>(oa==null?void 0:oa.label)!=="操作"))==null?void 0:Yt.map(oa=>{var El;return{...oa,type:"edit",optionUrl:oa!=null&&oa.formMenuSelect&&((El=oa==null?void 0:oa.formMenuSelect)==null?void 0:El.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,lr.value,Jr.value,Wr.value,R==null?void 0:R.value],async()=>{var p,v,T,z,P,D;if((p=u==null?void 0:u.itemData)!=null&&p.find(ne=>(ne==null?void 0:ne.key)==="columnPath")&&!((v=J.value)!=null&&v.find(ne=>{var re,q;return(ne==null?void 0:ne.key)===((q=(re=u==null?void 0:u.itemData)==null?void 0:re.find(be=>(be==null?void 0:be.key)==="columnPath"))==null?void 0:q.contents)}))){let ne=J.value,re={key:(z=(T=u==null?void 0:u.itemData)==null?void 0:T.find(q=>(q==null?void 0:q.key)==="columnPath"))==null?void 0:z.contents,value:(D=(P=u==null?void 0:u.itemData)==null?void 0:P.find(q=>(q==null?void 0:q.key)==="columnUsingPath"))==null?void 0:D.contents};ne!=null&&ne.find(q=>(q==null?void 0:q.key)===(re==null?void 0:re.key))?ne=ne==null?void 0:ne.map(q=>((q==null?void 0:q.key)===(re==null?void 0:re.key)&&(q.value=re.value),q)):ne.push(re),ua.setTableViewContents(ne)}await Ht(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),ye.value=p==null?void 0:p.dialogTitle,Xa.value=!0,Ne.value=!0)},{immediate:!0,deep:!0});const xu=()=>{var p;(p=k.value)!=null&&p.includes("read")&&(Vl.value=!Vl.value)},wu=()=>{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?Vl.value=!1:(p!=null&&p.includes("read")||(Vl.value=!0),p!=null&&p.includes("edit")||(Vl.value=!1)),M.value=((v=u==null?void 0:u.config)==null?void 0:v.showIndex)||Vl.value},{immediate:!0}),e.watch(()=>Vl.value,p=>{var v;p?(dt("viewChange"),ua.setCacheUpdatingData(null)):(Re.value=We.value,F.value=Ca.value,H.value&&(ua.setTableLoading(u==null?void 0:u.index),Be("change",H.value))),M.value=p||((v=u==null?void 0:u.config)==null?void 0:v.showIndex),ql.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 _u=(p,v)=>{var T;dt("createClick"),v===me.pageSize&&(me.currentPage=Math.ceil(((T=ze.value)==null?void 0:T.length)/me.pageSize))},Su=async(p,v,T)=>{var P,D,ne,re,q;const z=(v==null?void 0:v.property)??(v==null?void 0:v.prop);if(z&&fo.includes(z)&&T!==void 0&&T!==null&&String(T).trim()!==""){const be=String(T).trim();if(await ut(be,p==null?void 0:p.id)){ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择");const Ye=(P=ze.value)==null?void 0:P.findIndex(Qe=>(Qe==null?void 0:Qe.id)===(p==null?void 0:p.id)),qe=Ye!==-1?(ne=(D=ze.value)==null?void 0:D[Ye])==null?void 0:ne[z]:void 0;z&&(p[z]=qe??"");return}}if(Vl.value){const be=p==null?void 0:p.id;be!=null&&(h.value.has(be)||h.value.set(be,A.cloneDeep(p)),s.value.add(be));const Ee=(re=ze.value)==null?void 0:re.findIndex(Ye=>(Ye==null?void 0:Ye.id)===(p==null?void 0:p.id));Ee!==-1&&z&&(ze.value[Ee]={...ze.value[Ee],[z]:T}),ho(T,p,v);return}ho(T,p,v),Al.value=A.cloneDeep(p),Ma.value=p==null?void 0:p.id,Ba.value=(q=ze.value)==null?void 0:q.length,ye.value=p!=null&&p._isTemp?"新增":"编辑",Hi(!1)},Eu=async()=>{var p,v;try{const T=[];if(u!=null&&u.related&&Array.isArray(u.related)&&(console.log("props.related",u.related),u.related.forEach(z=>{if(typeof z=="string"&&z.includes("content_")){const P=z.split("_")[1];P&&(T.push(`content_${P}`),T.push(`struct_${P}`))}})),T.length===0&&(u!=null&&u.itemData)){const z=(v=(p=u.itemData)==null?void 0:p.find(P=>(P==null?void 0:P.key)==="contentTableId"))==null?void 0:v.contents;z&&(T.push(`content_${z}`),T.push(`struct_${z}`))}return T}catch(T){return console.error("获取 tableNames 失败:",T),[]}},Cu=async(p,v,T)=>{var D,ne;if(!T||typeof T!="string"||T.trim()===""){const re=(v==null?void 0:v.property)??(v==null?void 0:v.prop),q=`${p==null?void 0:p.id}:${re}`;d.value.delete(q),g.value.set(q,!1);return}const z=(v==null?void 0:v.property)??(v==null?void 0:v.prop),P=`${p==null?void 0:p.id}:${z}`;g.value.set(P,!0);try{const re=await Eu();if(re.length===0){console.warn("未找到同名表,跳过全局搜索"),d.value.delete(P),g.value.set(P,!1);return}const q=parseInt((D=hl.value)==null?void 0:D.plat_id);if(!q){console.warn("platId 无效,跳过全局搜索"),d.value.delete(P),g.value.set(P,!1);return}const be=await A.getAllTables({platId:q,tableNames:re??[]}),Ee=((ne=be==null?void 0:be.data)==null?void 0:ne.result)||[],Ye=[],qe=[];for(let Qe=0;Qe<Ee.length;Qe+=2)Qe+1<Ee.length&&qe.push([Ee[Qe],Ee[Qe+1]]);qe.forEach(([Qe,xa])=>{var el;if(!Array.isArray(Qe)||Qe.length===0||!Array.isArray(xa)||xa.length===0)return;const za=xa[0];let La=((el=za==null?void 0:za.结构)==null?void 0:el.contents)??[];if(!Array.isArray(La)||La.length===0)return;let ea=A.cloneDeep(La);if(Array.isArray(ea==null?void 0:ea[0])&&(ea=te.getColumnChild(ea[0])),!Array.isArray(ea)||ea.length===0||!ea.some(ve=>(ve==null?void 0:ve.prop)===z))return;[...Qe].sort((ve,Ra)=>{const ka=Number((ve==null?void 0:ve.update_time)??0);return Number((Ra==null?void 0:Ra.update_time)??0)-ka}).slice(0,20).forEach(ve=>{const Ra=ve[z];if(Ra!=null){const ka=String(Ra);ka.toLowerCase().includes(T.toLowerCase())&&Ye.findIndex(Ea=>{var B;return ve.id&&((B=Ea.rowData)==null?void 0:B.id)===ve.id?!0:Ea.label===ka})===-1&&Ye.push({label:ka,rowData:A.cloneDeep(ve),sourceTable:(za==null?void 0:za.source_table)||""})}})}),d.value.set(P,Ye)}catch(re){console.error("全局搜索建议失败:",re),d.value.delete(P)}finally{g.value.set(P,!1)}},Du=(p,v,T)=>{if(!Vl.value)return;const z=(v==null?void 0:v.property)??(v==null?void 0:v.prop),P=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"";if(P&&P.toUpperCase()!=="INPUT"&&P!=="")return;const D=`${p==null?void 0:p.id}:${z}`;if(m.has(D)&&clearTimeout(m.get(D)),!T||T.trim()===""){d.value.delete(D),g.value.set(D,!1);return}const ne=setTimeout(()=>{Cu(p,{prop:z,property:z},T),m.delete(D)},300);m.set(D,ne)};function Tu(p,v){const T=`${p==null?void 0:p.id}:${(v==null?void 0:v.property)??(v==null?void 0:v.prop)}`;return d.value.get(T)||[]}const Bu=(p,v,T)=>{var be;if(!T||!T.rowData)return;const z=T.rowData,P=p==null?void 0:p.id,D=(v==null?void 0:v.property)??(v==null?void 0:v.prop);(te.getAllLeafNodes(F.value)||[]).filter(Ee=>(Ee==null?void 0:Ee.type)!=="operate"&&(Ee==null?void 0:Ee.label)!=="操作"&&(Ee==null?void 0:Ee.prop)!=="operate").forEach(Ee=>{const Ye=Ee==null?void 0:Ee.prop;Ye&&z[Ye]!==void 0&&(p[Ye]=z[Ye])}),(be=ze.value)==null||be.findIndex(Ee=>(Ee==null?void 0:Ee.id)===P),P!=null&&(h.value.has(P)||h.value.set(P,A.cloneDeep(p)),s.value.add(P));const q=`${P}:${D}`;d.value.delete(q),g.value.set(q,!1),ho(p[D],p,v)},nn=p=>{var q,be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa;const{row:v,column:T,item:z,slotData:P}=p;let D=v!=null&&v[T==null?void 0:T.prop]||(v==null?void 0:v[T==null?void 0:T.prop])===0?((be=(q=v==null?void 0:v[T==null?void 0:T.prop])==null?void 0:q[0])==null?void 0:be.contents)??((v==null?void 0:v[T==null?void 0:T.prop])===0?"0":v==null?void 0:v[T==null?void 0:T.prop]):((Ye=(Ee=v==null?void 0:v[z==null?void 0:z.prop])==null?void 0:Ee[0])==null?void 0:Ye.contents)??(v==null?void 0:v[z==null?void 0:z.prop])??((Qe=(qe=P==null?void 0:P[z==null?void 0:z.prop])==null?void 0:qe[0])==null?void 0:Qe.contents)??(P==null?void 0:P[z==null?void 0:z.prop])??((La=(za=v==null?void 0:v[(xa=z==null?void 0:z.child)==null?void 0:xa.prop])==null?void 0:za[0])==null?void 0:La.contents)??(v==null?void 0:v[(ea=z==null?void 0:z.child)==null?void 0:ea.prop]),re=Array.isArray(D)&&!(D!=null&&D.every(wa=>typeof wa=="string"||typeof wa=="number"))?"查看":D;if(re=Array.isArray(re)?re.join(","):re,(T==null?void 0:T.formType)==="Date")if(!re||re===""||re===null||re===void 0)re="";else{const wa=A.dayjs(re,["YYYY-MM-DD","YYYY/MM/DD","YYYY年MM月DD日","YYYYMMDD"],!0);re=wa.isValid()?wa.format("YYYYMMDD"):re??""}return Array.isArray(T==null?void 0:T.relatedPages)&&((Qa=T==null?void 0:T.relatedPages)==null?void 0:Qa.length)>0&&(re="详情页"),re},Nu=p=>{var be,Ee,Ye,qe,Qe,xa,za,La,ea,Qa;const{row:v,column:T,item:z,slotData:P}=p;let D=v!=null&&v[T==null?void 0:T.prop]?((Ee=(be=v==null?void 0:v[T==null?void 0:T.prop])==null?void 0:be[0])==null?void 0:Ee.contents)??(v==null?void 0:v[T==null?void 0:T.prop]):((qe=(Ye=v==null?void 0:v[z==null?void 0:z.prop])==null?void 0:Ye[0])==null?void 0:qe.contents)??(v==null?void 0:v[z==null?void 0:z.prop])??((xa=(Qe=P==null?void 0:P[z==null?void 0:z.prop])==null?void 0:Qe[0])==null?void 0:xa.contents)??(P==null?void 0:P[z==null?void 0:z.prop])??((ea=(La=v==null?void 0:v[(za=z==null?void 0:z.child)==null?void 0:za.prop])==null?void 0:La[0])==null?void 0:ea.contents)??(v==null?void 0:v[(Qa=z==null?void 0:z.child)==null?void 0:Qa.prop]);const re=Array.isArray(D)&&!(D!=null&&D.every(wa=>typeof wa=="string"||typeof wa=="number")),q=Array.isArray(D)&&(D==null?void 0:D.find(wa=>wa==null?void 0:wa.url));return re&&q},Au=p=>{var P,D,ne,re;if(!(p!=null&&p.column))return!1;const v=we.value==="试验任务/任务管理",T=(u==null?void 0:u.compName)==="任务列表",z=((D=(P=p==null?void 0:p.column)==null?void 0:P.filter)==null?void 0:D.includes("@TextRGBA"))||((re=(ne=p==null?void 0:p.column)==null?void 0:ne.filter)==null?void 0:re.includes("@TextBackRGBA"));return v&&T&&z},zu=(p,v)=>p.find(T=>Object.values(T).some(z=>z===v));return e.watch(()=>De.value,async p=>{if(p){de.setContentLoading(!0),await e.nextTick();const v=zu(ze.value,p==null?void 0:p.data);if(!v)return de.setContentLoading(!1);await Vi(p==null?void 0:p.data,null,v,{data:p==null?void 0:p.data}),de.setContentLoading(!1)}},{deep:!0,immediate:!0}),e.watch(()=>u==null?void 0:u.cacheNewData,p=>{var v;p&&(Array.isArray(p)?p.forEach(T=>{var z,P,D,ne,re;if(换,String(T==null?void 0:T.compId)===String(u==null?void 0:u.index)&&(T!=null&&T.resId)&&((z=T==null?void 0:T.data)!=null&&z.id)){const q=(P=T==null?void 0:T.data)==null?void 0:P.id,be=T==null?void 0:T.resId;if(ze.value=(D=ze.value)==null?void 0:D.map(Ee=>{if((Ee==null?void 0:Ee.id)===q){const Ye={...Ee,id:be};return delete Ye._isOCRRow,delete Ye._ocrTableId,Ye}return Ee}),(re=(ne=Oa.value)==null?void 0:ne.has)!=null&&re.call(ne,q)){const Ye={...Oa.value.get(q)||{},id:be};delete Ye._isOCRRow,delete Ye._ocrTableId,Oa.value.delete(q),Oa.value.set(be,Ye)}Ha(u==null?void 0:u.index,q,be)}}):String(p==null?void 0:p.compId)===String(u==null?void 0:u.index)&&(ze.value=(v=ze.value)==null?void 0:v.map(T=>{var z;if((T==null?void 0:T.id)===((z=p==null?void 0:p.data)==null?void 0:z.id)){const P={...T,id:p==null?void 0:p.resId};return delete P._isOCRRow,delete P._ocrTableId,P}return T})))},{immediate:!0,deep:!0}),(p,v)=>{var ea,Qa,wa,el;const T=e.resolveComponent("svg-icon"),z=e.resolveComponent("el-popover"),P=e.resolveComponent("el-switch"),D=e.resolveComponent("el-checkbox"),ne=e.resolveComponent("el-radio"),re=e.resolveComponent("el-radio-group"),q=e.resolveComponent("el-checkbox-group"),be=e.resolveComponent("el-button"),Ee=e.resolveComponent("el-icon"),Ye=e.resolveComponent("el-progress"),qe=e.resolveComponent("el-alert"),Qe=e.resolveComponent("el-table-column"),xa=e.resolveComponent("el-table"),za=e.resolveComponent("el-upload"),La=e.resolveComponent("el-text");return e.openBlock(),e.createElementBlock("div",G0,[br.value?(e.openBlock(),e.createBlock(sl.ssTable,{id:"excel-table",pageObj:me,showIndex:M.value,isTree:(ea=a.compItem)==null?void 0:ea.isTree,summaryInfo:X,columns:F.value,defaultSort:ce,isCardViewport:Er.value,checkedColumns:n.value,key:qr.value+JSON.stringify(F.value),tableData:_n.value,isEditViewport:Vl.value,isShowPagination:Te.value,isShowEdit:!1,isShowDelete:!1,allowSelect:C.value,onDbClickRow:An,extraButton:Re.value,rowButton:Sa.value,cacheExtraButtons:We.value,isClearSelection:((Qa=ql.value)==null?void 0:Qa.length)===0,onDoCurrentChange:Mi,onDoSizeChange:jo,onSortChange:Ho,onContentClick:Vi,onRowClick:at,onSelectChange:Jo,onCellChange:Su,onCellInput:Du,onSelectSuggest:Bu,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 Ra,ka,Da,Ea;return[a.showHeader?(e.openBlock(),e.createBlock(Sf,{key:0,id:"tableHeaderButton",pageLayout:a.pageLayout,lockingPage:e.unref(ha)===e.unref(we),filterValues:et.value,selectNums:(Ra=ql.value)==null?void 0:Ra.length,dataNums:(ka=ze.value)==null?void 0:ka.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]=(B,G,$e)=>st(B,G,{extra:$e})),columns:F.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,Ra,ka,Da;return[((ve=ze.value)==null?void 0:ve.length)>0&&a.allowOperate&&V.value?(e.openBlock(),e.createElementBlock("div",X0,[(Ra=k.value)!=null&&Ra.includes("read")&&((ka=k.value)!=null&&ka.includes("edit"))&&((Da=Sa.value)!=null&&Da.some(Ea=>(Ea==null?void 0:Ea.label)==="编辑"))&&!Er.value&&e.unref(ha)!==e.unref(we)?(e.openBlock(),e.createElementBlock("span",{key:0,title:"编辑表格",onClick:xu},[e.createVNode(T,{name:"editTable",class:"view-icon"})])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]}),rowCreate:e.withCtx(({row:ve,index:Ra})=>[e.createElementVNode("span",{title:"新增",class:"row-create-wrap",onClick:ka=>_u(ve,Ra)},[e.createVNode(T,{name:"rowCreate",style:{width:"10px",height:"10px"}})],8,Z0)]),operateCol:e.withCtx(()=>[e.createVNode(z,{title:"选择显示列信息",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:vu,onBeforeEnter:mu},{reference:e.withCtx(()=>[e.createElementVNode("span",Q0,[e.createVNode(T,{name:"operate",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",e3,[v[20]||(v[20]=e.createElementVNode("div",{class:"group-title"},"表格操作",-1)),e.createVNode(P,{"model-value":$.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,a3)]),_:2},1032,["value"]),e.createVNode(z,{"popper-class":"col-operate-popover",title:"列操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(T,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Ra;return[e.createElementVNode("div",l3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Ra=Object.keys(ve))==null?void 0:Ra.filter(ka=>{var Da;return(Da=E.value)==null?void 0:Da.find(Ea=>(Ea==null?void 0:Ea.value)===ka)}),ka=>{var Da,Ea;return e.openBlock(),e.createElementBlock("div",{key:ka},[L[ka]=="radio"?(e.openBlock(),e.createElementBlock("div",r3,[v[19]||(v[19]=e.createElementVNode("div",null,"固定:",-1)),e.createVNode(re,{"model-value":ve==null?void 0:ve[ka],onChange:B=>Qn(B,ka,ve)},{default:e.withCtx(()=>{var B,G;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((G=(B=E.value)==null?void 0:B.find($e=>($e==null?void 0:$e.value)===ka))==null?void 0:G.options,$e=>(e.openBlock(),e.createBlock(ne,{key:$e==null?void 0:$e.value,label:$e==null?void 0:$e.value,value:$e==null?void 0:$e.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString($e==null?void 0:$e.label),1)]),_:2},1032,["label","value"]))),128))]}),_:2},1032,["model-value","onChange"])])):e.createCommentVNode("",!0),L[ka]=="switch"?(e.openBlock(),e.createBlock(P,{key:1,"model-value":ve==null?void 0:ve[ka],"active-text":(Ea=(Da=E.value)==null?void 0:Da.find(B=>(B==null?void 0:B.value)===ka))==null?void 0:Ea.label,onChange:B=>Qn(B,ka,ve)},null,8,["model-value","active-text","onChange"])):e.createCommentVNode("",!0)])}),128))])]}),_:2},1024),e.createElementVNode("span",n3,[e.createVNode(T,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:1},8,["modelValue"])])):e.createCommentVNode("",!0)]),_:1})]),content:e.withCtx(ve=>{var Ra,ka,Da,Ea,B,G,$e,sa,xe,da,Na,il,qa,pl,fl,Ul,Fa,bl,Va,ul;return[((Ra=ve==null?void 0:ve.column)==null?void 0:Ra.label)==="证书附件"||((ka=ve==null?void 0:ve.column)==null?void 0:ka.prop)==="证书附件"?(e.openBlock(),e.createElementBlock("div",i3,[e.createVNode(T,{name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(Ga=>bi(ve),["stop"]),title:"查看OCR图片"},null,8,["onClick"])])):Nu(ve)?(e.openBlock(),e.createBlock(z,{key:1,"popper-class":"file-popover",placement:"right",trigger:"hover",effect:"light",width:"auto"},{reference:e.withCtx(()=>[e.createElementVNode("span",o3,e.toDisplayString(nn(ve)),1)]),default:e.withCtx(()=>{var Ga,dl;return[e.createElementVNode("div",t3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((dl=ve==null?void 0:ve.row)==null?void 0:dl[(Ga=ve==null?void 0:ve.column)==null?void 0:Ga.prop],Tl=>(e.openBlock(),e.createElementBlock("div",s3,[e.createElementVNode("div",{class:"prop-url",title:ai(Tl),onClick:Ml=>mi(Tl)},e.toDisplayString(ai(Tl)),9,c3),e.createElementVNode("div",{class:"prop-download",onClick:Ml=>Zo(Tl)}," 下载 ",8,u3)]))),256))])]}),_:2},1024)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[Au(ve)?(e.openBlock(),e.createBlock(ju,{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=(B=nn(ve))==null?void 0:B.toString())!=null&&G.includes(".cpt")||(sa=($e=nn(ve))==null?void 0:$e.toString())!=null&&sa.includes(".cyd"))?"var(--vertical-menuitem-active-bg)":"",textDecoration:!Array.isArray(nn(ve))&&((da=(xe=nn(ve))==null?void 0:xe.toString())!=null&&da.includes(".txt")||(il=(Na=nn(ve))==null?void 0:Na.toString())!=null&&il.includes(".cpt")||(pl=(qa=nn(ve))==null?void 0:qa.toString())!=null&&pl.includes(".cyd"))?"underline":"",cursor:!Array.isArray(nn(ve))&&((Ul=(fl=nn(ve))==null?void 0:fl.toString())!=null&&Ul.includes(".txt")||(bl=(Fa=nn(ve))==null?void 0:Fa.toString())!=null&&bl.includes(".cpt")||(ul=(Va=nn(ve))==null?void 0:Va.toString())!=null&&ul.includes(".cyd"))?"pointer":"",marginLeft:(ve==null?void 0:ve.colIndex)===0?`${((ve==null?void 0:ve.level)??0)*20}px`:0}),onClick:Ga=>{var dl;return Xn(nn(ve),((dl=ve==null?void 0:ve.column)==null?void 0:dl.relatedPages)??[])}},e.toDisplayString(nn(ve)===0?"0":nn(ve)),13,d3))],64))]}),_:2},[((wa=Sa.value)==null?void 0:wa.length)>0?{name:"actions",fn:e.withCtx(({item:ve,fIndex:Ra})=>[e.createVNode(z,{title:"",placement:"left-start","popper-class":"menu-operate-popover"},{reference:e.withCtx(()=>[e.createVNode(T,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"},onClick:v[0]||(v[0]=e.withModifiers(()=>{},["stop"]))})]),default:e.withCtx(()=>[e.createElementVNode("div",Y0,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($i(Sa.value,ve),(ka,Da)=>(e.openBlock(),e.createElementBlock("div",{class:"menu-config-item",key:Da,onClick:e.withModifiers(Ea=>st(ka==null?void 0:ka.label,ve,{extra:ka}),["stop"])},[e.createElementVNode("div",{style:e.normalizeStyle({color:ka==null?void 0:ka.textColor}),class:"extra-button-label"},e.toDisplayString(ka==null?void 0:ka.label),5)],8,J0))),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),Vl.value?(e.openBlock(),e.createElementBlock("div",p3,[e.createVNode(be,{id:"themeBorderButton",onClick:Yo},{default:e.withCtx(()=>v[22]||(v[22]=[e.createTextVNode("取消")])),_:1,__:[22]}),e.createVNode(be,{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:ye.value,visible:Ne.value,width:ir.value,onBeforeDestroy:oo,style:{height:"74%"}},{default:e.withCtx(()=>[e.createElementVNode("div",f3,[e.createVNode(sl.ssForm,{ref_key:"formRef",ref:ae,rowContents:Ae.value,showOperator:!1,onChange:yu,isEnableWrap:!1,onFixChangeValue:Qo,onClickTrigger:ei,isEdit:fa.value,onBlurChange:ro,onCreate:hi,onTagChange:On},null,8,["rowContents","isEdit"])])]),footer:e.withCtx(()=>[Xa.value?(e.openBlock(),e.createElementBlock("div",h3,[e.createVNode(be,{onClick:v[4]||(v[4]=ve=>Ne.value=!1),id:"themeBorderButton"},{default:e.withCtx(()=>v[24]||(v[24]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[24]}),e.createVNode(be,{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:ye.value,visible:Xe.value,width:Ze.value,onBeforeDestroy:v[7]||(v[7]=ve=>Xe.value=!1)},{default:e.withCtx(()=>[e.createVNode(Lf)]),footer:e.withCtx(()=>[e.createElementVNode("div",v3,[e.createVNode(be,{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(be,{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"]),ee.value?(e.openBlock(),e.createBlock(sl.ssFilePreview,{key:2,fileDataList:ca.value,onDestroy:Pi},null,8,["fileDataList"])):e.createCommentVNode("",!0),Fe.value?(e.openBlock(),e.createBlock(Ar.ssDialog,{key:3,visible:Fe.value,onBeforeDestroy:fu,style:{height:"80vh",width:"80vw"},"body-class":"three-dialog-body","footer-class":"three-dialog-footer"},{default:e.withCtx(()=>[e.createVNode(Bo.ThreeViewerHost,{files:Ve.value,threeData:N.value},null,8,["files","threeData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0),e.createVNode(Ar.ssDialog,{title:"OCR扫描录入",visible:ya.value,"close-on-click-modal":!1,onBeforeDestroy:Nl,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",m3,[e.createElementVNode("div",y3,[e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:Ia.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:Ia.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:Ia.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)]),Ia.value===1?(e.openBlock(),e.createElementBlock("div",g3,[e.createVNode(be,{onClick:t,class:"ocr-action-btn",disabled:rl.value,size:"default"},{default:e.withCtx(()=>v[33]||(v[33]=[e.createTextVNode("扫描文件 ")])),_:1,__:[33]},8,["disabled"]),e.createVNode(be,{onClick:un,class:"ocr-action-btn",disabled:rl.value,size:"default"},{default:e.withCtx(()=>v[34]||(v[34]=[e.createTextVNode("上传文件 ")])),_:1,__:[34]},8,["disabled"])])):e.createCommentVNode("",!0),Ia.value===1?(e.openBlock(),e.createElementBlock("div",b3,[e.createElementVNode("div",k3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Aa.value,(ve,Ra)=>{var ka;return e.openBlock(),e.createElementBlock("div",{key:Ra,class:"ocr-file-item"},[e.createElementVNode("div",x3,[ve.raw&&((ka=ve.raw.type)!=null&&ka.startsWith("image/"))?(e.openBlock(),e.createElementBlock("img",{key:0,src:Wl(ve),alt:"预览",class:"thumbnail-image"},null,8,w3)):(e.openBlock(),e.createElementBlock("div",_3,[e.createVNode(Ee,{size:40},{default:e.withCtx(()=>[e.createVNode(e.unref(ja.document_default))]),_:1})])),e.createElementVNode("div",{class:e.normalizeClass(["file-progress-ring",{uploading:zl(ve)==="uploading",processing:zl(ve)==="processing",completed:zl(ve)==="completed"||zl(ve)==="uploaded",failed:zl(ve)==="failed"}])},[(e.openBlock(),e.createElementBlock("svg",S3,[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:zl(ve)==="completed"||zl(ve)==="uploaded",uploading:zl(ve)==="uploading",processing:zl(ve)==="processing",failed:zl(ve)==="failed"}]),cx:"18",cy:"18",r:"16",fill:"none",stroke:zl(ve)==="failed"?"#f56c6c":zl(ve)==="completed"||zl(ve)==="uploaded"?"#67c23a":"#409eff","stroke-width":zl(ve)==="completed"||zl(ve)==="uploaded"||zl(ve)==="failed"?3:2,"stroke-dasharray":rn(ve),"stroke-dashoffset":"0","stroke-linecap":"round",transform:"rotate(-90 18 18)"},null,10,E3)])),zl(ve)==="completed"||zl(ve)==="uploaded"?(e.openBlock(),e.createElementBlock("div",C3,[e.createVNode(Ee,{class:"check-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(ja.check_default))]),_:1})])):e.createCommentVNode("",!0),zl(ve)==="failed"?(e.openBlock(),e.createElementBlock("div",D3,[e.createVNode(Ee,{class:"error-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(ja.close_default))]),_:1})])):e.createCommentVNode("",!0)],2),e.createElementVNode("div",{class:"file-delete-btn",onClick:Da=>cu(Ra)},[e.createVNode(Ee,null,{default:e.withCtx(()=>[e.createVNode(e.unref(ja.close_default))]),_:1})],8,T3)]),e.createElementVNode("div",B3,e.toDisplayString(ve.name||"文件名123"),1)])}),128))]),Aa.value.length>0?(e.openBlock(),e.createElementBlock("div",N3,[e.createVNode(be,{onClick:ra,class:"ocr-start-recognize-btn",disabled:rl.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),Ia.value===1?(e.openBlock(),e.createElementBlock("div",A3,[e.createVNode(Ye,{percentage:la.value,"stroke-width":8},null,8,["percentage"])])):e.createCommentVNode("",!0),Ia.value===2?(e.openBlock(),e.createElementBlock("div",z3,[e.createElementVNode("div",M3,[e.createVNode(qe,{title:"请核对识别结果。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",I3,[e.createVNode(xa,{data:Ke.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(Ua.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",O3,[e.createElementVNode("span",null,e.toDisplayString(ve.label),1)])]),default:e.withCtx(({row:Ra,$index:ka})=>{var Da,Ea,B;return[ve.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:_l(Ra[ve.prop]),fontWeight:500})},e.toDisplayString(nl(Ra[ve.prop])),5)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[ll.value!==ka?(e.openBlock(),e.createElementBlock("span",L3,e.toDisplayString(Ra[ve.prop]),1)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(tl(ve.prop)),{key:1,modelValue:Ra[ve.prop],"onUpdate:modelValue":G=>Ra[ve.prop]=G,size:"small",placeholder:"请输入"+ve.label,content:((Da=ga(ve.prop))==null?void 0:Da.contents)??((Ea=ga(ve.prop))==null?void 0:Ea.options)??[],optionUrl:(B=ga(ve.prop))==null?void 0:B.optionUrl,onChange:G=>Ka(ka,ve.prop,G),onFocus:G=>Pe.value=ve.prop,onBlur:v[8]||(v[8]=G=>Pe.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})=>[ll.value===ve?(e.openBlock(),e.createBlock(Ee,{key:0,class:"ocr-edit-icon editing",style:{"margin-left":"12px"},onClick:e.withModifiers(Ra=>gl(ve),["stop"])},{default:e.withCtx(()=>[e.createVNode(e.unref(ja.check_default))]),_:2},1032,["onClick"])):(e.openBlock(),e.createBlock(T,{key:1,name:"edit_101",class:"ocr-edit-icon",onClick:e.withModifiers(Ra=>gl(ve),["stop"])},null,8,["onClick"]))]),_:1})]),_:1},8,["data"])])])):e.createCommentVNode("",!0),Ia.value===3?(e.openBlock(),e.createElementBlock("div",R3,[e.createVNode(Ee,{size:"32",class:"ocr-success-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(ja.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":Ue,"show-file-list":!1,class:"ocr-upload-input",style:{display:"none"}},null,8,["file-list"])]),footer:e.withCtx(()=>[Ia.value!==3?(e.openBlock(),e.createElementBlock("div",$3,[e.createVNode(be,{onClick:kn,class:"ocr-start-recognize-btn",disabled:Ia.value===1||rl.value},{default:e.withCtx(()=>v[39]||(v[39]=[e.createTextVNode(" 上一步 ")])),_:1,__:[39]},8,["disabled"]),e.createVNode(be,{onClick:Tn,class:"ocr-start-recognize-btn",disabled:rl.value},{default:e.withCtx(()=>v[40]||(v[40]=[e.createTextVNode(" 下一步 ")])),_:1,__:[40]},8,["disabled"])])):e.createCommentVNode("",!0)]),_:1},8,["visible"]),e.createVNode(e0,{visible:gi.value,onConfirm:o,onCancel:v[10]||(v[10]=ve=>gi.value=!1)},null,8,["visible"]),e.createVNode(_d,{visible:al.value,"onUpdate:visible":v[11]||(v[11]=ve=>al.value=ve),versions:ke.value},null,8,["visible","versions"]),e.createVNode(cd,{visible:Dl.value,"onUpdate:visible":v[12]||(v[12]=ve=>Dl.value=ve),images:Wa.value,"default-image-name":ml.value,"field-meta":ll.value!==null?((el=Ke.value[ll.value])==null?void 0:el.__ocrFieldMeta)||{}:{},"focused-field-name":Pe.value,onClose:v[13]||(v[13]=ve=>Dl.value=!1),class:"ocr-img-preview-dialog"},null,8,["visible","images","default-image-name","field-meta","focused-field-name"]),e.createVNode(Ld,{visible:nr.value,"onUpdate:visible":v[14]||(v[14]=ve=>nr.value=ve),candidates:_r.value,"name-prop":er.value,"mfr-prop":gr.value,columns:F.value,onSubmit:Hl,onPreviewFile:ii},null,8,["visible","candidates","name-prop","mfr-prop","columns"]),e.createVNode(Hd,{visible:ba.value,"onUpdate:visible":v[15]||(v[15]=ve=>ba.value=ve),ocrPreviewData:Ke.value,"onUpdate:ocrPreviewData":v[16]||(v[16]=ve=>Ke.value=ve),ocrSelectedFields:va.value,"onUpdate:ocrSelectedFields":v[17]||(v[17]=ve=>va.value=ve),ocrPreviewColumns:Ua.value,onConfirm:Za,onFieldChange:v[18]||(v[18]=({rowIndex:ve,prop:Ra,value:ka})=>Ka(ve,Ra,ka))},null,8,["visible","ocrPreviewData","ocrSelectedFields","ocrPreviewColumns"]),e.createVNode(Ar.ssDialog,{title:f.title,visible:f.show,width:f.width,onBeforeDestroy:Q},{default:e.withCtx(()=>[e.createElementVNode("div",V3,[e.createVNode(sl.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:ge},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:_},{header:e.withCtx(()=>[e.createElementVNode("div",null,[e.createElementVNode("div",P3,e.toDisplayString(y.title),1),e.createVNode(La,{size:"small",type:"danger",style:{width:"100%"}},{default:e.withCtx(()=>v[41]||(v[41]=[e.createTextVNode(" (选择【覆盖】,可能会影响到原数据的引用关系;选择【跳过】将会放弃重复数据的导入。请谨慎操作!) ")])),_:1,__:[41]})])]),footer:e.withCtx(()=>[e.createElementVNode("div",F3,[e.createVNode(La,{size:"small",style:{width:"100%","text-align":"left"},type:"info"},{default:e.withCtx(()=>[e.createTextVNode("引用模块:"+e.toDisplayString(Fn.value||"暂无"),1)]),_:1}),e.createElementVNode("div",j3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y==null?void 0:y.buttonValue,ve=>(e.openBlock(),e.createBlock(be,{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:Ra=>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(Ef,{columns:y==null?void 0:y.columns,tableData:y==null?void 0:y.tableData},{content:e.withCtx(({row:ve,item:Ra,slotData:ka,scope:Da,column:Ea,columnProp:B,$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])||(ka==null?void 0:ka[Ea==null?void 0:Ea.property])),1)]),_:1},8,["columns","tableData"])]),_:1},8,["visible","width"])])}}},Mc=Ql._export_sfc(U3,[["__scopeId","data-v-d24d2d88"]]),q3={key:1,class:"static-form-body"},W3=["onClick"],K3={key:1},G3=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 $;const w=($=n.itemData)==null?void 0:$.find(V=>(V==null?void 0:V.key)==="formContent"),b=(w==null?void 0:w.contents)||[];return(n.fields&&n.fields.length>0?n.fields:b).filter(V=>(V==null?void 0:V.label)||(V==null?void 0:V.isHideInForm)).map(V=>{let le=V==null?void 0:V.value;Array.isArray(le)&&(le=le.map(F=>F==null?"":typeof F=="object"?F.label??F.value??F.name??JSON.stringify(F):String(F)).filter(Boolean).join(",")),le!=null&&typeof le=="object"&&(le=le.label??le.value??le.name??JSON.stringify(le));const X=V.isHideInForm?"":V.label??"",me=le==null||le===""?"-":String(le),Be=X==="使用状态";return{label:X,value:me,isStatus:Be,tagType:Be?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),b=te.rgbaToColor(n==null?void 0:n.textColor),S={},$={},V={},le={};return!Number.isNaN(w)&&w&&(S.fontSize=`${w}px`,$.fontSize=`${w+1}px`,V.fontSize=`${w}px`,le.fontSize=`${w}px`),b&&($.color=b,V.color=b,le.color=b),{item:S,label:$,value:V,empty:le}}),m=e.ref(""),g=e.ref(""),u=e.ref(!1),C=async w=>{if(w){g.value&&(URL.revokeObjectURL(g.value),g.value="");try{const b=await A.platformDownloadFile({url:w}),S=new Blob([b==null?void 0:b.data],{type:(b==null?void 0:b.headers["content-type"])||"image/*"});g.value=URL.createObjectURL(S)}catch{g.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 $,V,le;const b=w.target,S=($=b==null?void 0:b.files)==null?void 0:$[0];if(!S){b.value="";return}u.value=!0;try{const X=new FormData;X.append("file",S);const me=await A.platformUploadFile(X),Be=(le=(V=me==null?void 0:me.data)==null?void 0:V.result)==null?void 0:le.url;Be?(m.value=Be,r("update:backGroundImage",Be),C(Be),ja.ElMessage.success("背景图片上传成功")):ja.ElMessage.error("背景图片上传失败")}catch{ja.ElMessage.error("背景图片上传失败")}finally{u.value=!1,b.value=""}},W=e.computed(()=>{var w;return g.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"}:{}}),I=w=>sl.getComponent(w),j=w=>{if(!w)return;const b=w.querySelector("input, textarea, .el-input__inner");b&&typeof b.focus=="function"&&b.focus()},L=(w,b,S)=>{n.disabled||(h.value=b,e.nextTick(()=>{j(S.currentTarget)}))},E=()=>{h.value=null},x=w=>{const b=w!=null&&w.width&&w.width>0?w.width:1,$=`calc((100% - ${(b-1)*48}px) / ${b})`;return{flex:`0 0 ${$}`,maxWidth:$,minWidth:"0",boxSizing:"border-box"}};return(w,b)=>{const S=e.resolveComponent("el-tag");return e.openBlock(),e.createElementBlock("div",{class:"static-form-card",style:e.normalizeStyle(W.value),onClick:b[2]||(b[2]=$=>(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:b[0]||(b[0]=e.withModifiers($=>M(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:c,type:"file",accept:"image/*",style:{display:"none"},onChange:k},null,544),b[3]||(b[3]=e.createElementVNode("img",{src:sl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),s.value.length?(e.openBlock(),e.createElementBlock("div",q3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,($,V)=>{var le,X,me,Be,F,ie,Y,ce,Ce;return e.openBlock(),e.createElementBlock("div",{key:V,class:"static-form-item",style:e.normalizeStyle({...x($),...d.value.item}),onClick:b[1]||(b[1]=e.withModifiers(()=>{},["stop"]))},[$.label&&!((le=$==null?void 0:$.field)!=null&&le.isHideInForm)?(e.openBlock(),e.createElementBlock("div",{key:0,class:"static-form-label",style:e.normalizeStyle(d.value.label)},e.toDisplayString($.label)+": ",5)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"static-form-value",style:e.normalizeStyle(d.value.value),onClick:Fe=>{var fe;return(fe=$.field)!=null&&fe.isNoClick?null:L($,V,Fe)}},[h.value===V&&$.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(I(((X=$.field)==null?void 0:X.type)??"Input")),{key:0,modelValue:$.field.value,"onUpdate:modelValue":Fe=>$.field.value=Fe,isEdit:!0,disabled:(me=$.field)==null?void 0:me.disabled,content:((Be=$.field)==null?void 0:Be.contents)??[],optionUrl:$.field,originalValue:(F=$.field)==null?void 0:F.value,config:(ie=$.field)==null?void 0:ie.config,configModel:((Y=$.field)==null?void 0:Y.prop)??((ce=$.field)==null?void 0:ce.name),selectedTagList:((Ce=$.field)==null?void 0:Ce.selectValue)??[],onBlur:E,onBlurChange:E},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[$.isStatus?(e.openBlock(),e.createBlock(S,{key:0,type:$.tagType,size:"Default",effect:"plain"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString($.value??"-"),1)]),_:2},1032,["type"])):(e.openBlock(),e.createElementBlock("span",K3,e.toDisplayString($.value??"-"),1))],64))],12,W3)],4)}),128))])):(e.openBlock(),e.createElementBlock("div",{key:2,class:"static-form-empty",style:e.normalizeStyle(d.value.empty)}," 暂无数据 ",4))],4)}}}),Ic=Ql._export_sfc(G3,[["__scopeId","data-v-5937a104"]]),Y3={class:"form-content"},J3={title:"选择标签"},X3={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},Z3={class:"col-operate-wrap"},Q3={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},eh={__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:Fe.value==="view"});const i=l,s=e.ref(""),h=e.ref([]),c=e.ref(!1),d=e.ref(!1),m=e.ref([]),{getFileExtension:g}=Bo.useThreeSystem(),u=e.ref(),C=e.ref(!1),M=e.ref(!1),k=A.useUnit(A.pinia),{chooseTitle:W}=A.storeToRefs(k),I=e.ref([]),j=e.ref(),L=e.ref(!1),E=e.ref([]),x=hc(A.pinia),w=At(A.pinia),b=e.ref(!1),S=e.ref(),$=e.ref(),V=e.ref(),le=e.ref(),X=e.ref(),me=A.useLoginState(A.pinia),{loginUserInfo:Be}=A.storeToRefs(me),F=e.ref(),ie=e.ref(!0),Y=A.useModelComp(A.pinia),{tableViewContents:ce,itemData:Ce,isEdit:Fe,routeToChildPath:fe,lockingPage:N,homepageBackgroundTableId:se,refreshCurrentPageInform:U}=A.storeToRefs(Y),_e=e.ref(null),Ie=e.ref(!1),je=e.ref(!1),na=A.useMenuState(),{activeMenuPath:Ca}=A.storeToRefs(na),ee=te.useOriginalState(A.pinia),{originalPath:ca}=A.storeToRefs(ee),{compType:de,hasEditable:pa}=Qs.useRole(),we=()=>!pa(r.config,{type:de.FORM});e.computed(()=>Ca.value==="设备管理/试验设备"&&r.compName==="设备概要");const ue=async()=>{var Xe,Ze,Pa;const ae=se==null?void 0:se.value,oe=(Xe=Be==null?void 0:Be.value)==null?void 0:Xe.plat_id;if(!(!ae||!oe))try{const Sa=await A.getAllTables({platId:parseInt(oe),tableNames:[`content_${ae}`,`struct_${ae}`],user_unique_id:"0"}),Xa=((Pa=(Ze=Sa==null?void 0:Sa.data)==null?void 0:Ze.result)==null?void 0:Pa[0])??[],Ve=String((r==null?void 0:r.index)??""),Re=Xa==null?void 0:Xa.find(We=>String(We==null?void 0:We.relatedForm_id)===Ve);Re!=null&&Re.backgroundImg_url&&(le.value=Re.backgroundImg_url)}catch(Sa){console.error("获取首页背景图片表数据失败:",Sa)}},De=e.ref([]),Ge=e.ref([{label:"编辑",value:"operable",checked:!1},{label:"禁用",value:"disabled",checked:!1}]),ua=async ae=>{je.value=ae,await ha("disabled",null,ae,!0)},Ja=async ae=>{await ha("operable",null,ae,!0)};e.watch(()=>Ca.value,async()=>{h.value=[],m.value=[]},{deep:!0,immediate:!0});const R=()=>{e.nextTick(()=>{pe()})},H=ae=>{var oe;h.value=(oe=h.value)==null?void 0:oe.map(Xe=>({...Xe,isFormColHidden:!(ae!=null&&ae.includes(Xe.label))}))};e.onUnmounted(()=>{_e.value=null});const J=ae=>{i("clickTrigger",ae)},he=async ae=>{var oe,Xe,Ze,Pa,Sa,Xa;if(ae===""){let Ve="";(oe=h.value)==null||oe.forEach(Me=>{Me!=null&&Me.isMain&&(Ve=Me==null?void 0:Me.value)});let Re=await te.getItemData(fe.value,sessionStorage.getItem("systemKey"),"");Ve=((Xa=(Sa=(Pa=(Ze=(Xe=Re==null?void 0:Re[0])==null?void 0:Xe.compData)==null?void 0:Ze.find(Me=>(Me==null?void 0:Me.key)==="mainRouters"))==null?void 0:Pa.contents)==null?void 0:Sa[0])==null?void 0:Xa.routerContent)+ca.value+Ve;let Ae=await te.getItemData(Ve,sessionStorage.getItem("systemKey"),"");L.value=!0,E.value=Ae==null?void 0:Ae.filter(Me=>(Me==null?void 0:Me.comp)!=="methodButton"),i("routeUrl",E.value)}},pe=()=>{var oe;const ae=(oe=_e.value)==null?void 0:oe.$el;ae&&Il.Sortable.create(ae,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:Xe=>{const{oldIndex:Ze,newIndex:Pa}=Xe;if(Ze===Pa)return;const Sa=h.value.splice(Ze,1)[0];h.value.splice(Pa,0,Sa)}})},ha=async(ae,oe,Xe,Ze=!1)=>{try{Y.setRefreshCurStructure(!1)}catch{ja.ElMessage.error("编辑处理失败")}},ta=async(ae,oe)=>{await ha()},He=async(ae,oe)=>{ae&&await ha()},_a=async(ae,oe,Xe)=>{await ha(oe,Xe,ae,!1)},ze=(ae,oe)=>{F.value===oe?ie.value=!1:ie.value=!0,F.value=oe==null?void 0:oe.changeProp},ma=async ae=>{var Xa;le.value=ae;const oe=r.itemData,Xe=oe==null?void 0:oe.find(Ve=>(Ve==null?void 0:Ve.key)==="backGroundImage");Xe?Xe.contents=ae:oe==null||oe.push({key:"backGroundImage",contents:ae}),i("change",{key:"backGroundImage",contents:ae});const Ze=se==null?void 0:se.value,Pa=r==null?void 0:r.index,Sa=(Xa=Be==null?void 0:Be.value)==null?void 0:Xa.plat_id;if(!(!Ze||!Sa||!Pa||!ae))try{await A.pageBatchAddApi({platId:parseInt(Sa),changeContents:[{tableName:`content_${Ze}`,tableContents:[{backgroundImg_url:ae,relatedForm_id:String(Pa)}]}],user_unique_id:"0"})}catch(Ve){console.error("保存背景图片记录失败:",Ve),ja.ElMessage.error("背景图片记录保存失败")}},Oa=async ae=>{var Xe,Ze,Pa,Sa,Xa,Ve,Re,We,Ae,Me,cl,wl,Cl,Pl,Sl;let oe=[];if((Xe=ae==null?void 0:ae.toString())!=null&&Xe.includes(".urdf")){if(ae.includes(",")){ja.ElMessage.error("当前版本仅允许单个urdf预览!");return}m.value=[{url:ae,extension:g(ae)}],d.value=!0,c.value=!0;return}if((Ze=ae==null?void 0:ae.toString())!=null&&Ze.includes(".stl")||(Pa=ae==null?void 0:ae.toString())!=null&&Pa.includes(".STL")||(Sa=ae==null?void 0:ae.toString())!=null&&Sa.includes(".obj")||(Xa=ae==null?void 0:ae.toString())!=null&&Xa.includes(".mtl")){const aa=((Ve=ae==null?void 0:ae.toString())==null?void 0:Ve.split(",")).map(Ha=>({url:Ha,extension:g(Ha)}));m.value=aa,d.value=!1,c.value=!0;return}if((Re=ae==null?void 0:ae.toString())!=null&&Re.includes(".stl")||(We=ae==null?void 0:ae.toString())!=null&&We.includes(".STL")||(Ae=ae==null?void 0:ae.toString())!=null&&Ae.includes(".obj")||(Me=ae==null?void 0:ae.toString())!=null&&Me.includes(".mtl")){let Gl,aa=[],Ha={};if(Array.isArray(ae)?Gl=ae:Gl=ae==null?void 0:ae.split(","),Gl==null||Gl.forEach(ya=>{ya.includes(".mtl")?aa.push(ya):Ha.blob=Ha.blob?Ha.blob+","+ya:ya}),(aa==null?void 0:aa.length)>0&&(Ha.mtlBlobs=aa),(wl=(cl=Object.values(Ha))==null?void 0:cl[0])!=null&&wl.includes("http:"))oe.push(Ha);else{const ya=new Blob([Ha.blob],{type:"application/octet-stream;charset=UTF-8"});let rl=URL.createObjectURL(ya),Aa="";(Cl=ae==null?void 0:ae.split("/"))==null||Cl.forEach((ol,al)=>{var ke;al===((ke=ae==null?void 0:ae.split("/"))==null?void 0:ke.length)-1&&(Aa=ol)}),(Pl=Ha.blob)!=null&&Pl.includes(".stl")&&(Aa=(Aa==null?void 0:Aa.replaceAll(">",""))+".urdf"),j.value=[{name:Aa,blobUrl:rl}],M.value=!0}}else{const Gl=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),aa=await ja.axios.get(ae,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{Gl.close()}),Ha=new Blob([aa.data],{type:"application/octet-stream;charset=UTF-8"});let ya=URL.createObjectURL(Ha),rl="";(Sl=ae==null?void 0:ae.split("/"))==null||Sl.forEach((Aa,ol)=>{var al;ol===((al=ae==null?void 0:ae.split("/"))==null?void 0:al.length)-1&&(rl=Aa)}),j.value=[{name:rl,blobUrl:ya}],M.value=!0}(oe==null?void 0:oe.length)>0&&w.setBlobUrls(oe)},Ma=()=>{M.value=!1},fa=ae=>{var Sa,Xa,Ve,Re;const oe=(Xa=(Sa=sl.safeClone(r.itemData))==null?void 0:Sa.find(We=>(We==null?void 0:We.key)==="formContent"))==null?void 0:Xa.contents,Xe=sl.safeClone(ae.content);let Ze={};Xe&&((Ve=Object.values(Xe))==null?void 0:Ve.length)>0&&((Re=Object.values(Xe))==null||Re.forEach((We,Ae)=>{Ze[oe[Ae].key]=We}));const Pa={content:Ze,index:r==null?void 0:r.index,buttonName:ae==null?void 0:ae.buttonName};i("change",Pa)};e.computed(()=>"http://222.92.178.198:62001");const Ba=async ae=>{var cl,wl,Cl,Pl,Sl,Gl,aa,Ha,ya,rl,Aa,ol,al,ke,Ia,$a;if(!ae)return;(wl=(cl=r==null?void 0:r.itemData)==null?void 0:cl.find(Z=>(Z==null?void 0:Z.key)==="parentFormPath"))==null||wl.contents;let oe=ce.value;(oe==null?void 0:oe.length)>0&&(oe=oe==null?void 0:oe.map(Z=>{var ba,Ke,Ua,ga;let la=(ba=Z==null?void 0:Z.key)==null?void 0:ba.split("/");return(r==null?void 0:r.compName)===(la==null?void 0:la[0])&&(Ke=h.value)!=null&&Ke.find(tl=>(tl==null?void 0:tl.prop)===(la==null?void 0:la[1]))&&(Z.value=(ga=(Ua=h.value)==null?void 0:Ua.find(tl=>(tl==null?void 0:tl.prop)===(la==null?void 0:la[1])))==null?void 0:ga.value),Z}),Y.setTableViewContents(oe));const Xe=sl.safeClone(r.itemData);let Ze=Xe==null?void 0:Xe.map(Z=>{var la;return(Z==null?void 0:Z.key)==="formContent"&&((la=Z.contents)==null||la.map((ba,Ke)=>{var Ua,ga,tl,Le,ia,va,ll,Pe,Dl,Wa,ml,nr,_r,jl,pr,Sr,Cr,Oe,er,gr,Dr;return ba.type=(ga=(Ua=h.value)==null?void 0:Ua.find(Bl=>(Bl==null?void 0:Bl.prop)===(ba==null?void 0:ba.prop)))==null?void 0:ga.type,ba.options=ba!=null&&ba.options?ba.options:((ia=(Le=(tl=ba==null?void 0:ba.key)==null?void 0:tl.split("$"))==null?void 0:Le[1])==null?void 0:ia.length)>0?(Dl=(Pe=Vu((ll=(va=ba==null?void 0:ba.key)==null?void 0:va.split("$"))==null?void 0:ll[1]))==null?void 0:Pe.split(","))==null?void 0:Dl.map(Bl=>({label:Bl,value:Bl})):[],(Wa=ba==null?void 0:ba.key)!=null&&Wa.includes("$")&&(ba.key=(nr=(ml=ba==null?void 0:ba.key)==null?void 0:ml.split("$"))==null?void 0:nr[0]),ba.signature=(jl=(_r=h.value)==null?void 0:_r.find(Bl=>(Bl==null?void 0:Bl.prop)===(ba==null?void 0:ba.prop)))==null?void 0:jl.signature,ba.isLoginUser=(Sr=(pr=h.value)==null?void 0:pr.find(Bl=>(Bl==null?void 0:Bl.prop)===(ba==null?void 0:ba.prop)))==null?void 0:Sr.isLoginUser,ba.value=(Cr=Object.values(ae))==null?void 0:Cr[Ke],ba.isFormColHidden=(er=(Oe=h.value)==null?void 0:Oe.find(Bl=>(Bl==null?void 0:Bl.prop)===(ba==null?void 0:ba.prop)))==null?void 0:er.isFormColHidden,ba.isHideInForm=(Dr=(gr=h.value)==null?void 0:gr.find(Bl=>(Bl==null?void 0:Bl.prop)===(ba==null?void 0:ba.prop)))==null?void 0:Dr.isHideInForm,ba})),Z}),Pa=h.value,Sa=(Pl=(Cl=sl.safeClone(Ze))==null?void 0:Cl.find(Z=>(Z==null?void 0:Z.key)==="formContent"))==null?void 0:Pl.contents;if(Pa=Pa==null?void 0:Pa.map(Z=>{var la,ba;return(Z==null?void 0:Z.type)==="Select"&&((la=Z==null?void 0:Z.allSelectionContents)==null?void 0:la.length)>0&&(Z.contactValue=ae),Z.value=(ba=Sa==null?void 0:Sa.find((Ke,Ua)=>((Ke==null?void 0:Ke.id)??Ua)===(Z==null?void 0:Z.id)))==null?void 0:ba.value,Z}),!ie.value){i("contentChange",{contents:Ze,index:r.index});return}let Xa="",Ve=(aa=(Gl=(Sl=sl.safeClone(Ze))==null?void 0:Sl.find(Z=>(Z==null?void 0:Z.key)==="formContent"))==null?void 0:Gl.contents)==null?void 0:aa.find((Z,la)=>{var ba,Ke,Ua;return(Z==null?void 0:Z.label)===F.value||la.toString()===((Ua=(Ke=(ba=F.value)==null?void 0:ba.split("t"))==null?void 0:Ke[1])==null?void 0:Ua.toString())}),Re=(Ha=Ve==null?void 0:Ve.optionUrl)==null?void 0:Ha.menuSelect,We=!0;if((Aa=(rl=(ya=sl.safeClone(Ze))==null?void 0:ya.find(Z=>(Z==null?void 0:Z.key)==="formContent"))==null?void 0:rl.contents)==null||Aa.forEach(Z=>{var la,ba,Ke,Ua,ga,tl;We&&((Ke=(ba=(la=Z==null?void 0:Z.optionUrl)==null?void 0:la.groupSelect)==null?void 0:ba[1])!=null&&Ke.includes("["))&&(Xa=(ga=(Ua=Z==null?void 0:Z.optionUrl)==null?void 0:Ua.groupSelect)==null?void 0:ga[1],JSON.stringify(Re)===JSON.stringify((tl=Z==null?void 0:Z.optionUrl)==null?void 0:tl.menuSelect)&&(We=!1))}),(ol=Ve==null?void 0:Ve.optionUrl)!=null&&ol.menuSelect&&ie.value){let Z=await _t(Ve),la,ba=(al=Ve==null?void 0:Ve.optionUrl)==null?void 0:al.menuSelect;if(Z==null||Z.forEach(Ke=>{var Ua,ga,tl,Le,ia,va,ll,Pe,Dl,Wa;Xa===((ga=(Ua=Ve==null?void 0:Ve.optionUrl)==null?void 0:Ua.groupSelect)==null?void 0:ga[1])&&((ia=(Le=(tl=Ve==null?void 0:Ve.optionUrl)==null?void 0:tl.groupSelect)==null?void 0:Le[1])!=null&&ia.includes("["))&&((Wa=sl.safeClone(Ke))==null?void 0:Wa[(Dl=(Pe=(ll=(va=Ve==null?void 0:Ve.optionUrl)==null?void 0:va.groupSelect)==null?void 0:ll[1])==null?void 0:Pe.replaceAll("[",""))==null?void 0:Dl.replaceAll("]","")])===(Ve==null?void 0:Ve.value)&&(la=Ke)}),la){let Ke=sl.safeClone(Pa);Ke=Ke==null?void 0:Ke.map(ga=>{var tl,Le,ia,va,ll,Pe,Dl,Wa,ml,nr,_r;return(la!=null&&la[ga==null?void 0:ga.label]||la!=null&&la[(va=(ia=(Le=(tl=ga==null?void 0:ga.optionUrl)==null?void 0:tl.groupSelect)==null?void 0:Le[1])==null?void 0:ia.replaceAll("[",""))==null?void 0:va.replaceAll("]","")])&&((Dl=(Pe=(ll=ga==null?void 0:ga.optionUrl)==null?void 0:ll.groupSelect)==null?void 0:Pe[1])!=null&&Dl.includes("["))&&ba!=null&&ba.every(jl=>{var pr,Sr;return(Sr=(pr=ga==null?void 0:ga.optionUrl)==null?void 0:pr.menuSelect)==null?void 0:Sr.includes(jl)})&&(ga.value=(la==null?void 0:la[ga==null?void 0:ga.label])||(la==null?void 0:la[(_r=(nr=(ml=(Wa=ga==null?void 0:ga.optionUrl)==null?void 0:Wa.groupSelect)==null?void 0:ml[1])==null?void 0:nr.replaceAll("[",""))==null?void 0:_r.replaceAll("]","")]),Array.isArray(ga.value)&&ga.value.every(jl=>(jl==null?void 0:jl.url)&&(jl==null?void 0:jl.name))&&(ga.type="Upload")),ga}),Ke=Ke==null?void 0:Ke.map(ga=>{var tl,Le,ia;return(tl=ga==null?void 0:ga.optionUrl)!=null&&tl.oldMenuSelect&&(ga.optionUrl.menuSelect=(ia=(Le=sl.safeClone(ga))==null?void 0:Le.optionUrl)==null?void 0:ia.oldMenuSelect),ga}),h.value=sl.safeClone(Ke);let Ua=sl.safeClone(Ke);Ua=Ua==null?void 0:Ua.map(ga=>{var tl,Le,ia,va,ll,Pe;return(Le=(tl=ga==null?void 0:ga.optionUrl)==null?void 0:tl.menuSelect)!=null&&Le.some(Dl=>Dl==null?void 0:Dl.includes("["))&&(ga.optionUrl.oldMenuSelect=(va=(ia=sl.safeClone(ga))==null?void 0:ia.optionUrl)==null?void 0:va.menuSelect,ga.optionUrl.menuSelect=(Pe=(ll=ga==null?void 0:ga.optionUrl)==null?void 0:ll.menuSelect)==null?void 0:Pe.map(Dl=>{var Wa,ml,nr,_r;if(Dl!=null&&Dl.includes("[")){let jl=(ml=(Wa=Dl==null?void 0:Dl.replaceAll("[","").replaceAll("]",""))==null?void 0:Wa.split(":"))==null?void 0:ml[1];Dl=(_r=(nr=sl.safeClone(Ke))==null?void 0:nr.find(pr=>(pr==null?void 0:pr.label)===jl))==null?void 0:_r.value}return Dl})),ga}),h.value=Ua}else h.value=Pa;Ze=Ze==null?void 0:Ze.map(Ke=>{var Ua;return(Ke==null?void 0:Ke.key)==="formContent"&&(Ke.contents=(Ua=Ke.contents)==null?void 0:Ua.map(ga=>{var tl,Le,ia,va;return ga.value=((Le=(tl=h.value)==null?void 0:tl.find(ll=>(ll==null?void 0:ll.label)===(ga==null?void 0:ga.key)))==null?void 0:Le.value)??(ga==null?void 0:ga.value),ga.type=((va=(ia=h.value)==null?void 0:ia.find(ll=>(ll==null?void 0:ll.prop)===(ga==null?void 0:ga.key)))==null?void 0:va.type)??(ga==null?void 0:ga.type),ga})),Ke})}ie.value=!1,i("contentChange",{contents:Ze,index:r.index});let Ae=[],Me=[];if((Ia=sl.safeClone((ke=Ze==null?void 0:Ze.find(Z=>(Z==null?void 0:Z.key)==="formContent"))==null?void 0:ke.contents))==null||Ia.forEach(Z=>{var la;Array.isArray(Z==null?void 0:Z.value)&&((la=Z==null?void 0:Z.value)!=null&&la.find(ba=>{var Ke;return(Ke=ba==null?void 0:ba.url)==null?void 0:Ke.includes(".obj")}))&&(Me=Z==null?void 0:Z.value)}),(Me==null?void 0:Me.length)>0){const Z=($a=sl.safeClone(Me))==null?void 0:$a.filter(la=>{var ba;return(ba=la==null?void 0:la.url)==null?void 0:ba.includes(".obj")});Z==null||Z.forEach(la=>{var Ke,Ua,ga,tl;const ba=(Ke=Me==null?void 0:Me.filter(Le=>{var ia;return(Le==null?void 0:Le.name)===(la==null?void 0:la.name)&&((ia=Le==null?void 0:Le.url)==null?void 0:ia.includes(".mtl"))}))==null?void 0:Ke.map(Le=>Le==null?void 0:Le.url);Ae.push({objUrl:la==null?void 0:la.url,mtlUrls:((Ua=Me==null?void 0:Me.filter(Le=>{var ia;return(Le==null?void 0:Le.name)===(la==null?void 0:la.name)&&((ia=Le==null?void 0:Le.url)==null?void 0:ia.includes(".mtl"))}))==null?void 0:Ua.length)===1?(tl=(ga=Me==null?void 0:Me.filter(Le=>{var ia;return(Le==null?void 0:Le.name)===(la==null?void 0:la.name)&&((ia=Le==null?void 0:Le.url)==null?void 0:ia.includes(".mtl"))}))==null?void 0:ga[0])==null?void 0:tl.url:ba})}),w.setObjUrl(Ae)}},Te=(ae,oe,Xe)=>{let Ze="";const Pa=oe==null?void 0:oe.map(Sa=>{var Xa;return(Xa=Sa==null?void 0:Sa.value)==null?void 0:Xa.pageData});return Pa==null||Pa.forEach(Sa=>{var Xa;(Sa==null?void 0:Sa.name)===(ae==null?void 0:ae[0])&&((Xa=Sa==null?void 0:Sa.compData)==null||Xa.forEach(Ve=>{var Re;(Ve==null?void 0:Ve.key)==="formContent"&&((Re=Ve==null?void 0:Ve.contents)==null||Re.forEach(We=>{var Ae;(We==null?void 0:We.prop)===(ae==null?void 0:ae[1])&&(Ze=(We==null?void 0:We.value)===""?te.judgeContents((Ae=sl.safeClone(We))==null?void 0:Ae.optionUrl,Xe):We==null?void 0:We.value)}))}))}),Ze},ye=(ae,oe,Xe,Ze)=>{var Ve,Re;let Pa="",Sa="";(Ve=sl.safeClone(oe))==null||Ve.forEach((We,Ae)=>{We!=null&&We.includes("[")?Sa=Sa+ca.value+ae[Ae]:Sa=Sa===""?Sa+We:Sa+"/"+We});let Xa=(Re=Ze[Sa])==null?void 0:Re.map(We=>{var Ae;return(Ae=We==null?void 0:We.value)==null?void 0:Ae.pageData});return Xa==null||Xa.forEach(We=>{var Ae;(We==null?void 0:We.name)===(Xe==null?void 0:Xe[0])&&((Ae=We==null?void 0:We.compData)==null||Ae.forEach(Me=>{var cl;(Me==null?void 0:Me.key)==="formContent"&&((cl=Me==null?void 0:Me.contents)==null||cl.forEach(wl=>{(wl==null?void 0:wl.prop)===(Xe==null?void 0:Xe[1])&&(Pa=wl==null?void 0:wl.value)}))}))}),Pa};e.watch(()=>se==null?void 0:se.value,async()=>{await ue()},{immediate:!0});const Ne=async ae=>await jp(ae,"Auto");return e.watch(()=>U.value,async()=>{var ae;(ae=h.value)!=null&&ae.some(oe=>(oe==null?void 0:oe.functionName)&&(oe==null?void 0:oe.functionName)!=="")&&(h.value=await Ne(h.value))},{immediate:!0,deep:!0}),e.watch(()=>r.itemData,async()=>{var wl,Cl,Pl,Sl,Gl,aa,Ha,ya,rl,Aa,ol,al,ke,Ia,$a,Z,la,ba,Ke,Ua,ga,tl,Le,ia,va,ll,Pe,Dl;const ae=(wl=r.itemData)==null?void 0:wl.find(Wa=>(Wa==null?void 0:Wa.key)==="formContent");let oe=(Cl=r.itemData)==null?void 0:Cl.find(Wa=>(Wa==null?void 0:Wa.key)==="backGround");oe&&((Pl=oe==null?void 0:oe.contents)==null?void 0:Pl.length)>0&&(s.value=((Gl=(Sl=oe==null?void 0:oe.contents)==null?void 0:Sl[0])==null?void 0:Gl.url)??"");const Xe=(aa=sl.safeClone(r.itemData))==null?void 0:aa.find(Wa=>(Wa==null?void 0:Wa.key)==="formButton"),Ze=(Ha=sl.safeClone(r.itemData))==null?void 0:Ha.find(Wa=>(Wa==null?void 0:Wa.key)==="formFlex"),Pa=(ya=sl.safeClone(r.itemData))==null?void 0:ya.find(Wa=>(Wa==null?void 0:Wa.key)==="formWrap"),Sa=(rl=sl.safeClone(r.itemData))==null?void 0:rl.find(Wa=>(Wa==null?void 0:Wa.key)==="enableWrap"),Xa=(Aa=sl.safeClone(r.itemData))==null?void 0:Aa.find(Wa=>(Wa==null?void 0:Wa.key)==="textSize"),Ve=(ol=sl.safeClone(r.itemData))==null?void 0:ol.find(Wa=>(Wa==null?void 0:Wa.key)==="textRGBA"),Re=(al=sl.safeClone(r.itemData))==null?void 0:al.find(Wa=>(Wa==null?void 0:Wa.key)==="backGround"),We=(ke=sl.safeClone(r.itemData))==null?void 0:ke.find(Wa=>(Wa==null?void 0:Wa.key)==="backGroundImage");(Pa==null?void 0:Pa.contents)==="纵向"?C.value=!1:C.value=!0;const Ae=Number(Xa==null?void 0:Xa.contents);S.value=Number.isNaN(Ae)?void 0:Ae,$.value=Ve==null?void 0:Ve.contents,V.value=Re==null?void 0:Re.contents,le.value=We==null?void 0:We.contents;const Me=Sa==null?void 0:Sa.contents;if(Me===void 0?b.value=si.BLOCK:typeof Me=="boolean"?b.value=Me?si.ORDINARY:si.BLOCK:b.value=Me,X.value=typeof(Ze==null?void 0:Ze.contents)!="boolean"?!(!(Ze!=null&&Ze.contents)===""||((Ia=Ze==null?void 0:Ze.contents)==null?void 0:Ia.toUpperCase())==="VERTICAL"):Ze==null?void 0:Ze.contents,(($a=ae==null?void 0:ae.contents)==null?void 0:$a.length)>0&&Array.isArray(ae==null?void 0:ae.contents)){let Wa=r.allMapContents;const ml=(la=(Z=sl.safeClone(ae))==null?void 0:Z.contents)==null?void 0:la.map((Oe,er)=>{var Kr,Jr,Wr,ar,lr,Xr,hl,ir,Vl,Er,ql,fr,Vr;let gr=(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("$")&&(gr=(Jr=sl.safeClone(Oe==null?void 0:Oe.key).split("$"))==null?void 0:Jr[0],((ar=(Wr=sl.safeClone(Oe==null?void 0:Oe.key).split("$"))==null?void 0:Wr[1])==null?void 0:ar.length)>0)){const[br,cn]=(Xr=(lr=sl.safeClone(Oe==null?void 0:Oe.key).split("$"))==null?void 0:lr[1])==null?void 0:Xr.split(/[()]/);(hl=te.FormType.find(Zr=>(Zr==null?void 0:Zr.key)===br))==null||hl.value,((ir=cn==null?void 0:cn.split(","))==null?void 0:ir.length)>0&&(Dr=(Vl=cn==null?void 0:cn.split(","))==null?void 0:Vl.map(Zr=>({label:Zr,value:Zr})))}let Bl=Oe==null?void 0:Oe.options;((Er=Oe==null?void 0:Oe.optionUrl)==null?void 0:Er.selectRelateType)==="自定义绑定"&&(Bl=(fr=(ql=Oe==null?void 0:Oe.optionUrl)==null?void 0:ql.defaultSelect)==null?void 0:fr.map(br=>({label:br,value:br})));let $r=(Oe==null?void 0:Oe.menuPath)??[],Ur=(Oe==null?void 0:Oe.groups)??[],Hl=(Oe==null?void 0:Oe.columns)??[],yr=!1,vn=(Oe==null?void 0:Oe.isFormColHidden)??!1,hr="",Al=Oe!=null&&Oe.value?Oe.value:(Bl==null?void 0:Bl.length)>0?(Vr=Bl==null?void 0:Bl[0])==null?void 0:Vr.value:(Oe==null?void 0:Oe.value)??"",sn=!1,jr="Input";return((Bl==null?void 0:Bl.length)>0||($r==null?void 0:$r.length)>0)&&(jr="Select"),(Array.isArray(hr)&&(hr!=null&&hr.every(br=>(br==null?void 0:br.name)&&(br==null?void 0:br.url)))||Array.isArray(Al)&&(Al!=null&&Al.every(br=>(br==null?void 0:br.name)&&(br==null?void 0:br.url))))&&(jr="upload"),Oe!=null&&Oe.isMainUrl&&(jr="Url"),{label:gr??"",name:gr??"t"+er,prop:gr??sl.safeClone(Oe==null?void 0:Oe.key),type:(Oe==null?void 0:Oe.type)??jr,value:(Oe==null?void 0:Oe.type)==="Date"&&Al===""?new Date:Al,id:(Oe==null?void 0:Oe.id)??er,contents:(Bl==null?void 0:Bl.length)>0?Bl:Dr??[],width:(Oe==null?void 0:Oe.width)??1,isLoginUser:yr,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:Hl,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}}),nr=ml==null?void 0:ml.map(Oe=>Oe==null?void 0:Oe.value);let _r="";nr==null||nr.forEach(Oe=>{Oe!==""&&Oe!==void 0&&(_r=_r===""?Oe:_r+"/"+Oe)}),x.setSelectArray(nr),x.setSelectString(_r);let jl=(ba=sl.safeClone(ml))==null?void 0:ba.map(Oe=>(Oe!=null&&Oe.value&&te.IsJson(Oe==null?void 0:Oe.value)&&Array.isArray(JSON.parse(Oe==null?void 0:Oe.value))&&(Oe.value=JSON.parse(Oe.value)),Oe)),pr={};jl==null||jl.forEach(Oe=>{pr[Oe.label]=Oe==null?void 0:Oe.value}),jl=jl==null?void 0:jl.map(Oe=>{var er,gr,Dr,Bl,$r,Ur,Hl,yr,vn;if((Oe==null?void 0:Oe.type)==="Select"&&((er=Oe==null?void 0:Oe.allSelectionContents)==null?void 0:er.length)>0&&(Oe.contactValue=pr),(Dr=(gr=Oe==null?void 0:Oe.optionUrl)==null?void 0:gr.menuSelect)!=null&&Dr.some(hr=>hr==null?void 0:hr.includes("["))){let hr="";Oe.optionUrl.oldMenuSelect=($r=(Bl=sl.safeClone(Oe))==null?void 0:Bl.optionUrl)==null?void 0:$r.menuSelect,Oe.optionUrl.menuSelect=(Hl=(Ur=Oe==null?void 0:Oe.optionUrl)==null?void 0:Ur.menuSelect)==null?void 0:Hl.map(Al=>{var sn,jr,qr,Kr,Jr,Wr;if(Al!=null&&Al.includes("[")){let ar=(jr=(sn=Al==null?void 0:Al.replaceAll("[","").replaceAll("]",""))==null?void 0:sn.split(":"))==null?void 0:jr[1];hr=Te((qr=Al==null?void 0:Al.replaceAll("[","").replaceAll("]",""))==null?void 0:qr.split(":"),Wa==null?void 0:Wa[Ca.value],Wa),Al=((Jr=(Kr=sl.safeClone(jl))==null?void 0:Kr.find(lr=>(lr==null?void 0:lr.label)===ar))==null?void 0:Jr.value)||Te((Wr=Al==null?void 0:Al.replaceAll("[","").replaceAll("]",""))==null?void 0:Wr.split(":"),Wa==null?void 0:Wa[Ca.value],Wa)}return Al}),hr!==""&&Oe.value===""&&(Oe.value=ye(Oe.optionUrl.menuSelect,Oe.optionUrl.oldMenuSelect,(yr=Oe==null?void 0:Oe.optionUrl)==null?void 0:yr.groupSelect,Wa),Array.isArray(Oe.value)&&((vn=Oe.value)!=null&&vn.every(Al=>Al==null?void 0:Al.url))&&(Oe.type="UPLOAD"))}return Oe}),h.value=jl,je.value=((Ke=h.value)==null?void 0:Ke.every(Oe=>Oe==null?void 0:Oe.disabled))||N.value===Ca.value,Ie.value=(Ua=h.value)==null?void 0:Ua.every(Oe=>Oe==null?void 0:Oe.operable),De.value=(ga=h.value)==null?void 0:ga.map(Oe=>Oe==null?void 0:Oe.label);let Sr=[],Cr=[];if((tl=sl.safeClone(h.value))==null||tl.forEach(Oe=>{var er;Array.isArray(Oe==null?void 0:Oe.value)&&((er=Oe==null?void 0:Oe.value)!=null&&er.find(gr=>{var Dr;return(Dr=gr==null?void 0:gr.url)==null?void 0:Dr.includes(".obj")}))&&(Cr=Oe==null?void 0:Oe.value)}),(Cr==null?void 0:Cr.length)>0){const Oe=(Le=sl.safeClone(Cr))==null?void 0:Le.filter(er=>{var gr;return(gr=er==null?void 0:er.url)==null?void 0:gr.includes(".obj")});Oe==null||Oe.forEach(er=>{var Dr,Bl,$r,Ur;const gr=(Dr=Cr==null?void 0:Cr.filter(Hl=>{var yr;return(Hl==null?void 0:Hl.name)===(er==null?void 0:er.name)&&((yr=Hl==null?void 0:Hl.url)==null?void 0:yr.includes(".mtl"))}))==null?void 0:Dr.map(Hl=>Hl==null?void 0:Hl.url);Sr.push({objUrl:er==null?void 0:er.url,mtlUrls:((Bl=Cr==null?void 0:Cr.filter(Hl=>{var yr;return(Hl==null?void 0:Hl.name)===(er==null?void 0:er.name)&&((yr=Hl==null?void 0:Hl.url)==null?void 0:yr.includes(".mtl"))}))==null?void 0:Bl.length)===1?(Ur=($r=Cr==null?void 0:Cr.filter(Hl=>{var yr;return(Hl==null?void 0:Hl.name)===(er==null?void 0:er.name)&&((yr=Hl==null?void 0:Hl.url)==null?void 0:yr.includes(".mtl"))}))==null?void 0:$r[0])==null?void 0:Ur.url:gr})}),w.setObjUrl(Sr)}(ia=sl.safeClone(h.value))==null||ia.forEach(Oe=>{var er,gr,Dr,Bl,$r,Ur,Hl,yr,vn,hr,Al,sn,jr;if((gr=(er=Oe==null?void 0:Oe.value)==null?void 0:er.toString())!=null&&gr.includes(".stl")||(Bl=(Dr=Oe==null?void 0:Oe.value)==null?void 0:Dr.toString())!=null&&Bl.includes(".STL")||(Ur=($r=Oe==null?void 0:Oe.value)==null?void 0:$r.toString())!=null&&Ur.includes(".obj")||(yr=(Hl=Oe==null?void 0:Oe.value)==null?void 0:Hl.toString())!=null&&yr.includes(".mtl")||(hr=(vn=Oe==null?void 0:Oe.value)==null?void 0:vn.toString())!=null&&hr.includes(".urdf")){let qr={},Kr=[],Jr;Array.isArray(Oe==null?void 0:Oe.value)?Jr=Oe==null?void 0:Oe.value:Jr=(Al=Oe==null?void 0:Oe.value)==null?void 0:Al.split(","),Jr==null||Jr.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 cl=ce.value;if((cl==null?void 0:cl.length)>0&&(cl=cl==null?void 0:cl.map(Wa=>{var nr,_r,jl,pr;let ml=(nr=Wa==null?void 0:Wa.key)==null?void 0:nr.split("/");return(r==null?void 0:r.compName)===(ml==null?void 0:ml[0])&&(_r=h.value)!=null&&_r.find(Sr=>(Sr==null?void 0:Sr.prop)===(ml==null?void 0:ml[1]))&&(Wa.value=(pr=(jl=h.value)==null?void 0:jl.find(Sr=>(Sr==null?void 0:Sr.prop)===(ml==null?void 0:ml[1])))==null?void 0:pr.value),Wa}),Y.setTableViewContents(cl)),r!=null&&r.formRules)u.value=r==null?void 0:r.formRules;else{let Wa={};(va=sl.safeClone(h).value)==null||va.forEach(ml=>{((ml==null?void 0:ml.isMain)===!0||(ml==null?void 0:ml.required)===!0)&&(Wa[(ml==null?void 0:ml.prop)??(ml==null?void 0:ml.name)]=[{required:!0,message:`${(ml==null?void 0:ml.label)||(ml==null?void 0:ml.prop)||(ml==null?void 0:ml.name)}不能为空`}])}),u.value=Wa}if(((ll=Xe==null?void 0:Xe.contents)==null?void 0:ll.length)>0){const Wa=[];(Pe=Xe==null?void 0:Xe.contents)==null||Pe.forEach((ml,nr)=>{(ml==null?void 0:ml.label)!==""&&Wa.push({label:(ml==null?void 0:ml.label)??"",id:(ml==null?void 0:ml.id)??nr,type:(ml==null?void 0:ml.type)??"",background:ml==null?void 0:ml.background})}),I.value=Wa}else I.value=[];(Dl=h.value)!=null&&Dl.some(Wa=>(Wa==null?void 0:Wa.functionName)&&(Wa==null?void 0:Wa.functionName)!=="")&&(h.value=await Ne(h.value))},{deep:!0,immediate:!0}),e.watch(()=>N.value,ae=>{je.value=ae===Ca.value},{immediate:!0}),(ae,oe)=>{var Ve;const Xe=e.resolveComponent("svg-icon"),Ze=e.resolveComponent("el-switch"),Pa=e.resolveComponent("el-checkbox"),Sa=e.resolveComponent("el-popover"),Xa=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",Y3,[b.value===e.unref(si).TEXT?(e.openBlock(),e.createBlock(Ic,{key:0,itemData:a.itemData,compName:a.compName,fields:h.value,textSize:S.value,textColor:$.value,backGround:V.value,backGroundImage:le.value,disabled:je.value||we(),"onUpdate:backGroundImage":ma,backgroundUrl:s.value},null,8,["itemData","compName","fields","textSize","textColor","backGround","backGroundImage","disabled","backgroundUrl"])):b.value===e.unref(si).BLOCK?(e.openBlock(),e.createBlock(Af,{key:1,items:(Ve=h.value)==null?void 0:Ve.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:S.value,textColor:$.value,backGround:V.value,backGroundImage:le.value,disabled:je.value||we(),"onUpdate:backGroundImage":ma,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":b.value===e.unref(si).ORDINARY})},[e.createVNode(sl.ssForm,{rowContents:h.value,formRules:u.value,buttonValue:I.value,isRowFlex:!1,isEnableWrap:!0,textSize:S.value,textColor:$.value,backGround:V.value,backGroundImage:le.value,onOnButtonClick:fa,onChange:Ba,formDisabled:je.value||we(),formLabelsOperable:Ie.value,isButtonRow:C.value,onPreview:Oa,onBlurChange:ze,style:e.normalizeStyle({backGroundImage:s.value!==""?`url("${s.value}")`:void 0}),onHandleColEditChange:ta,onHandleColTypeChange:He,onRouteUrl:he,onClickTrigger:J,"onUpdate:backGroundImage":ma},{operateCol:e.withCtx(({renderColumns:Re,formDisabled:We,formLabelsOperable:Ae})=>[e.createVNode(Sa,{title:"选择操作的标签",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:R},{reference:e.withCtx(()=>[e.createElementVNode("span",J3,[e.createVNode(Xe,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"}})])]),default:e.withCtx(()=>[e.createElementVNode("div",X3,[oe[1]||(oe[1]=e.createElementVNode("div",{class:"group-title"},"表单操作",-1)),e.createVNode(Ze,{"model-value":We,"active-text":"禁用","inactive-text":"",onChange:ua,style:{"margin-right":"8px"}},null,8,["model-value"]),e.createVNode(Ze,{"model-value":Ae,"active-text":"编辑所有标签","inactive-text":"",onChange:Ja},null,8,["model-value"]),oe[2]||(oe[2]=e.createElementVNode("div",{class:"group-title"},"表单列操作",-1)),e.createVNode(Xa,{modelValue:De.value,"onUpdate:modelValue":oe[0]||(oe[0]=Me=>De.value=Me),style:{height:"100%"},ref_key:"checkboxGroupRef",ref:_e,onChange:H},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Re,Me=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:Me.label},[e.createVNode(Pa,{value:Me.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(Me.label),1)]),_:2},1032,["value"]),e.createVNode(Sa,{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 cl;return[e.createElementVNode("div",Z3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((cl=Object.keys(Me))==null?void 0:cl.filter(wl=>{var Cl;return(Cl=Ge.value)==null?void 0:Cl.find(Pl=>(Pl==null?void 0:Pl.value)===wl)}),wl=>{var Cl,Pl;return e.openBlock(),e.createElementBlock("div",{key:wl},[e.createVNode(sl._sfc_main$1,{value:Me==null?void 0:Me[wl],"active-text":(Pl=(Cl=Ge.value)==null?void 0:Cl.find(Sl=>(Sl==null?void 0:Sl.value)===wl))==null?void 0:Pl.label,inactiveText:"",onChange:Sl=>_a(Sl,wl,Me)},null,8,["value","active-text","onChange"])])}),128))])]}),_:2},1024),e.createElementVNode("span",Q3,[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(sl.ssFilePreview,{key:3,fileDataList:j.value,onDestroy:Ma},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)])}}},Es=Ql._export_sfc(eh,[["__scopeId","data-v-4eb80a57"]]),Ro=e.ref(0),Oc=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:Oc(r==null?void 0:r.children)},r))},ah=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:Oc(r==null?void 0:r.children)},r))},Lc=(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=Lc(r==null?void 0:r.children,l),r)),a)},Rc=(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=Rc(r==null?void 0:r.children,l),r)),a)},$c=(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=$c(r==null?void 0:r.children,l),r)),a)},Vc=(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=Vc(r==null?void 0:r.children,l),r)),a)},cr=[{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"}],lh=[{label:"查看",value:"view"},{label:"修改",value:"fix"},{label:"删除",value:"delete"},{label:"三维算例",value:"modelExample"}],rh=[{label:"新增",value:"add"}],Vn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:rh},{key:"background",label:"按钮背景色",type:"Color"}],Pn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:lh},{key:"textColor",label:"按钮颜色",type:"Color"}],nh={class:"table-header-child"},ih={class:"table-header-child-main"},oh={class:"table-header-child-content"},th={class:"table-header-child-content-item"},sh={class:"fix-button"},ch={key:0},uh={class:"form-content"},dh={__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=te.useTableComp(A.pinia),{tableIndex:c}=A.storeToRefs(h);e.ref(0);const d=e.ref(""),m=e.ref([]),g=e.ref([]),u=E=>{var w;i.value=!0;let x=[];cr==null||cr.forEach(b=>{let S=A.cloneDeep(c.value)+1;h.setTableIndex(S),x.push({label:b==null?void 0:b.label,name:b==null?void 0:b.label,type:b.type,value:E[b.key],id:c.value,contents:b==null?void 0:b.options})}),E!=null&&E.children&&((w=E==null?void 0:E.children)==null?void 0:w.length)>0&&x.push({children:E==null?void 0:E.children,isFormColHidden:!0}),d.value=E==null?void 0:E.id,m.value=x,g.value=x},C=E=>{r("fixChange",A.cloneDeep(E))},M=E=>{r("deleteChange",A.cloneDeep(E))},k=E=>{i.value=!0;let x=[];cr==null||cr.forEach(w=>{let b=A.cloneDeep(c.value)+1;h.setTableIndex(b),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=E==null?void 0:E.id,m.value=x,g.value=x},W=E=>{let x=A.cloneDeep(g.value);x=x==null?void 0:x.map(w=>(w.children||(w.value=E==null?void 0:E[w.name]),w)),g.value=x},I=()=>{var x,w;m.value=g.value;let E={};if(d.value!=="")E.id=d.value,(x=m.value)==null||x.forEach(b=>{const S=cr==null?void 0:cr.find($=>($==null?void 0:$.label)===(b==null?void 0:b.label));S?E[S.key]=b.value:b!=null&&b.children&&b.children.length>0&&(E.children=b.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"fix"});else{let b=A.cloneDeep(c.value)+1;h.setTableIndex(b),E.id="id"+c.value,(w=m.value)==null||w.forEach(S=>{const $=cr==null?void 0:cr.find(V=>(V==null?void 0:V.label)===(S==null?void 0:S.label));$?E[$.key]=S.value:S!=null&&S.children&&S.children.length>0&&(E.children=S.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"add"})}d.value="",m.value=[],g.value=[]},j=()=>{i.value=!1,d.value="",s.value="",m.value=[],g.value=[]},L=E=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{r("deleteChange",E),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(E,x)=>{const w=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",nh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n==null?void 0:n.tableChildContents,(b,S)=>(e.openBlock(),e.createElementBlock("div",ih,[e.createElementVNode("div",oh,[e.createElementVNode("div",th,e.toDisplayString(b.label),1),e.createElementVNode("div",sh,[e.createVNode(w,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:$=>k(b)},null,8,["onClick"]),e.createVNode(w,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:$=>u(b)},null,8,["onClick"]),e.createVNode(w,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:$=>L(b)},null,8,["onClick"])])]),b!=null&&b.children&&b.children.length>0?(e.openBlock(),e.createElementBlock("div",ch,[e.createVNode(Pc,{tableChildContents:b==null?void 0:b.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",uh,[(e.openBlock(),e.createBlock(sl.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:I},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},ph=Ql._export_sfc(dh,[["__scopeId","data-v-e0fef72d"]]),fh={class:"table-header-child"},hh={class:"table-header-child-main"},vh={class:"table-header-child-content"},mh={class:"table-header-child-content-item"},yh={class:"fix-button"},gh={key:0},bh={class:"form-content"},kh={class:"dialog-footer"},xh={__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=te.useTableComp(A.pinia),{tableIndex:c}=A.storeToRefs(h),d=e.ref(""),m=e.ref([]),g=e.ref([]),u=E=>{r("fixChange",A.cloneDeep(E))},C=E=>{var w;i.value=!0;let x=[];cr==null||cr.forEach(b=>{let S=A.cloneDeep(c.value)+1;h.setTableIndex(S),x.push({label:b==null?void 0:b.label,name:b==null?void 0:b.label,type:b.type,value:E[b.key],id:c.value,contents:b==null?void 0:b.options})}),E!=null&&E.children&&((w=E==null?void 0:E.children)==null?void 0:w.length)>0&&x.push({children:E==null?void 0:E.children,isFormColHidden:!0}),d.value=E==null?void 0:E.id,m.value=x,g.value=x},M=E=>{i.value=!0;let x=[];cr==null||cr.forEach(w=>{let b=A.cloneDeep(c.value)+1;h.setTableIndex(b),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=E==null?void 0:E.id,m.value=x,g.value=x},k=E=>{let x=A.cloneDeep(g.value);x=x==null?void 0:x.map(w=>(w.children||(w.value=E==null?void 0:E[w.name]),w)),g.value=x},W=()=>{var x,w;m.value=g.value;let E={};if(d.value!=="")E.id=d.value,(x=m.value)==null||x.forEach(b=>{const S=cr==null?void 0:cr.find($=>($==null?void 0:$.label)===(b==null?void 0:b.label));S?E[S.key]=b.value:b!=null&&b.children&&b.children.length>0&&(E.children=b.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"fix"});else{let b=A.cloneDeep(c.value)+1;h.setTableIndex(b),E.id="idChild"+c.value,(w=m.value)==null||w.forEach(S=>{const $=cr==null?void 0:cr.find(V=>(V==null?void 0:V.label)===(S==null?void 0:S.label));$?E[$.key]=S.value:S!=null&&S.children&&S.children.length>0&&(E.children=S.children)}),i.value=!1,r("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"add"})}d.value="",m.value=[],g.value=[]},I=()=>{i.value=!1,d.value="",s.value="",m.value=[],g.value=[]},j=E=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{r("deleteChange",E),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},L=E=>{r("deleteChange",E)};return(E,x)=>{const w=e.resolveComponent("svg-icon"),b=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",fh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n==null?void 0:n.tableChildContents,(S,$)=>(e.openBlock(),e.createElementBlock("div",hh,[e.createElementVNode("div",vh,[e.createElementVNode("div",mh,e.toDisplayString(S.label),1),e.createElementVNode("div",yh,[e.createVNode(w,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:V=>M(S)},null,8,["onClick"]),e.createVNode(w,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:V=>C(S)},null,8,["onClick"]),e.createVNode(w,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:V=>j(S)},null,8,["onClick"])])]),S!=null&&S.children&&S.children.length>0?(e.openBlock(),e.createElementBlock("div",gh,[e.createVNode(ph,{tableChildContents:S==null?void 0:S.children,onDeleteChange:L,onFixChange:u},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode(Ar.ssDialog,{visible:i.value,onBeforeDestroy:I,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",bh,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:k},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",kh,[e.createVNode(b,{onClick:I,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>x[0]||(x[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(b,{class:"ok-button button",onClick:W,id:"themeButton"},{default:e.withCtx(()=>x[1]||(x[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},Pc=Ql._export_sfc(xh,[["__scopeId","data-v-ebd68fa1"]]),wh={class:"table-operate-content"},_h={class:"table-operate-item"},Sh={class:"operate-title"},Eh={class:"operate-content"},Ch={class:"fix-content"},Dh={class:"fix-content-label"},Th={class:"fix-button"},Bh={key:0},Nh={class:"operate-title"},Ah={class:"operate-content"},zh={class:"fix-content"},Mh={class:"fix-content-label"},Ih={class:"fix-button"},Oh={class:"operate-title"},Lh={class:"operate-content"},Rh={class:"fix-content"},$h={class:"fix-content-label"},Vh={class:"fix-button"},Ph={class:"operate-title"},Fh={class:"operate-content"},jh={class:"fix-content"},Hh={class:"fix-content-label"},Uh={class:"fix-button"},qh={class:"operate-content"},Wh={style:{display:"flex","justify-content":"space-between"}},Kh={class:"form-content"},Gh={class:"dialog-footer"},Yh={class:"form-content"},Jh={class:"dialog-footer"},Xh={class:"form-content"},Zh={class:"dialog-footer"},Qh={class:"form-content"},e4={class:"dialog-footer"},a4={__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([]),g=e.ref(!1),u=e.ref([]),C=e.ref(""),M=e.ref(""),k=e.ref([]),W=e.ref([]),I=e.ref([]),j=e.ref([]),L=e.ref(!1),E=e.ref([]),x=e.ref([]),w=e.ref(0),b=e.ref([]),S=e.ref([]),$=e.ref([]),V=()=>{L.value=!0;let R=[];Vn==null||Vn.forEach(H=>{w.value++,R.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})}),E.value=R,x.value=R},le=()=>{var H,J,he;h.value=!0;let R=[];(he=(J=(H=te.FormContent)==null?void 0:H.find(pe=>(pe==null?void 0:pe.key)==="Input"))==null?void 0:J.value)==null||he.forEach(pe=>{w.value++,R.push({label:pe==null?void 0:pe.label,name:(pe==null?void 0:pe.name)||(pe==null?void 0:pe.label),type:pe.type,value:(pe==null?void 0:pe.label)==="类型"?"Input":"",id:w.value,contents:pe==null?void 0:pe.options})}),b.value=R,S.value=R},X=R=>{R||(b.value=S.value)},me=async R=>{var H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma;if((R==null?void 0:R.类型)!==((J=(H=S.value)==null?void 0:H.find(fa=>(fa==null?void 0:fa.label)==="类型"))==null?void 0:J.value)){let fa=[],Ba=await((ha=(pe=(he=te.FormContent)==null?void 0:he.find(Te=>(Te==null?void 0:Te.key)===((R==null?void 0:R.类型)===""?"Input":R==null?void 0:R.类型)))==null?void 0:pe.value)==null?void 0:ha.value)?await((ma=(ze=(_a=te.FormContent)==null?void 0:_a.find(Te=>(Te==null?void 0:Te.key)===((R==null?void 0:R.类型)===""?"Input":R==null?void 0:R.类型)))==null?void 0:ze.value)==null?void 0:ma.value):(He=(ta=te.FormContent)==null?void 0:ta.find(Te=>(Te==null?void 0:Te.key)===((R==null?void 0:R.类型)===""?"Input":R==null?void 0:R.类型)))==null?void 0:He.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.属性名?(R==null?void 0:R.prop)||(R==null?void 0:R.name)||(R==null?void 0:R.label):(R==null?void 0:R[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)})}),R!=null&&R.菜单选项&&((Oa=R==null?void 0:R.菜单选项)==null?void 0:Oa.length)>0){const Te=await te.menuToContentType(R==null?void 0:R.菜单选项);fa=fa==null?void 0:fa.map(ye=>((ye==null?void 0:ye.name)==="组信息选项"&&(ye.contents=Te),ye))}S.value=await te.selectToBase(A.cloneDeep(fa)),b.value=await te.selectToBase(A.cloneDeep(fa))}else{let fa=A.cloneDeep(b.value);if(fa=fa==null?void 0:fa.map(Ba=>(Ba.value=R==null?void 0:R[Ba.name],Ba)),R!=null&&R.菜单选项&&((Ma=R==null?void 0:R.菜单选项)==null?void 0:Ma.length)>0){const Ba=await te.menuToContentType(R==null?void 0:R.菜单选项);fa=fa==null?void 0:fa.map(Te=>((Te==null?void 0:Te.name)==="组信息选项"&&(Te.contents=Ba),Te))}fa=te.formToOptionsContents(fa),S.value=await te.selectToBase(A.cloneDeep(fa))}},Be=async R=>{await me(R),b.value=S.value},F=(R,H)=>{if((H==null?void 0:H.type)=="Select"&&(R==null?void 0:R.key)==="selectRelateType"){const J=H==null?void 0:H.optionUrl;return(J==null?void 0:J.selectRelateType)||H[R.key]}if((H==null?void 0:H.type)=="Select"&&(R==null?void 0:R.key)==="menuSelect"){const J=H==null?void 0:H.optionUrl;return(J==null?void 0:J.menuSelect)||H[R.key]}if((H==null?void 0:H.type)=="Select"&&(R==null?void 0:R.key)==="groupSelect"){const J=H==null?void 0:H.optionUrl;return(J==null?void 0:J.groupSelect)||H[R.key]}if((H==null?void 0:H.type)=="Select"&&(R==null?void 0:R.key)==="originalContent")return(H==null?void 0:H.value)||H[R.key];if((H==null?void 0:H.type)=="Select"&&(R==null?void 0:R.key)==="multiple"){const J=H[R.key];return ac(J)?J:R.default}return(R==null?void 0:R.label)==="类型"&&H[R.key]===""?"Input":(R==null?void 0:R.key)==="isFormColHidden"&&!H[R.key]?!1:H[R.key]},ie=async R=>{var he,pe,ha,ta,He,_a,ze,ma,Oa;h.value=!0;let H=[];const J=await((ha=(pe=(he=te.FormContent)==null?void 0:he.find(Ma=>(Ma==null?void 0:Ma.key)===((R==null?void 0:R.type)===""?"Input":R==null?void 0:R.type)))==null?void 0:pe.value)==null?void 0:ha.value)?await((ma=(ze=(_a=te.FormContent)==null?void 0:_a.find(Ma=>(Ma==null?void 0:Ma.key)===((R==null?void 0:R.type)===""?"Input":R==null?void 0:R.type)))==null?void 0:ze.value)==null?void 0:ma.value):(He=(ta=te.FormContent)==null?void 0:ta.find(Ma=>(Ma==null?void 0:Ma.key)===((R==null?void 0:R.type)===""?"Input":R==null?void 0:R.type)))==null?void 0:He.value;if(J==null||J.forEach(Ma=>{w.value++,H.push({label:Ma==null?void 0:Ma.label,name:(Ma==null?void 0:Ma.name)||(Ma==null?void 0:Ma.label),type:Ma.type,value:(Ma==null?void 0:Ma.label)==="属性名"?(R==null?void 0:R.prop)||(R==null?void 0:R.name)||(R==null?void 0:R.label):F(Ma,R),id:w.value,contents:Ma==null?void 0:Ma.options})}),R!=null&&R.menuSelect&&((Oa=R==null?void 0:R.menuSelect)==null?void 0:Oa.length)>0){const Ma=await te.menuToContentType(R==null?void 0:R.menuSelect);H=H==null?void 0:H.map(fa=>((fa==null?void 0:fa.name)==="组信息选项"&&(fa.contents=Ma),fa))}C.value=R==null?void 0:R.id,b.value=await te.selectToBase(te.formToOptionsContents(H)),S.value=await te.selectToBase(te.formToOptionsContents(H))},Y=R=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,J;$.value=(H=A.cloneDeep($.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==(R==null?void 0:R.id)),r("change",(J=A.cloneDeep(n.originalItemContents))==null?void 0:J.map(he=>((he==null?void 0:he.key)==="tableToForm"&&(he.contents=$.value),he))),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},ce=()=>{h.value=!1,b.value=[],C.value=""},Ce=async()=>{var he,pe,ha,ta,He,_a,ze,ma,Oa,Ma;b.value=S.value;let R={};C.value!==""?R.id=C.value:(w.value++,R.id="id"+w.value);let H=await((ha=(pe=(he=te.FormContent)==null?void 0:he.find(fa=>{var Ba,Te;return(fa==null?void 0:fa.key)===(((Te=(Ba=b.value)==null?void 0:Ba.find(ye=>(ye==null?void 0:ye.label)==="类型"))==null?void 0:Te.value)??"label")}))==null?void 0:pe.value)==null?void 0:ha.value)??((He=(ta=te.FormContent)==null?void 0:ta.find(fa=>{var Ba,Te;return(fa==null?void 0:fa.key)===(((Te=(Ba=b.value)==null?void 0:Ba.find(ye=>(ye==null?void 0:ye.label)==="类型"))==null?void 0:Te.value)??"label")}))==null?void 0:He.value);if((_a=b.value)==null||_a.forEach(fa=>{const Ba=H==null?void 0:H.find(Te=>(Te==null?void 0:Te.label)===(fa==null?void 0:fa.label));Ba&&(R[Ba.key]=fa.value)}),R.name=R.label,(ze=$.value)!=null&&ze.find(fa=>fa.id===R.id))$.value=(ma=$.value)==null?void 0:ma.map(fa=>(fa.id===R.id&&(fa=R),fa));else{let fa=A.cloneDeep($.value);$.value||($.value=[]),fa.push(R),$.value=fa}$.value=$.value.map(({id:fa,...Ba})=>Ba),h.value=!1,C.value="";let J=A.cloneDeep(n.originalItemContents);(Oa=A.cloneDeep(n.originalItemContents))!=null&&Oa.find(fa=>(fa==null?void 0:fa.key)==="tableToForm")?J=(Ma=A.cloneDeep(n.originalItemContents))==null?void 0:Ma.map(fa=>((fa==null?void 0:fa.key)==="tableToForm"&&(fa.contents=$.value),fa)):J.push({key:"tableToForm",contents:$.value}),r("change",J)},Fe=R=>{L.value=!0;let H=[];Vn==null||Vn.forEach(J=>{w.value++,H.push({label:J==null?void 0:J.label,name:J==null?void 0:J.label,type:J.type,value:R[J.key],id:w.value,contents:J==null?void 0:J.options})}),C.value=R==null?void 0:R.id,E.value=H,x.value=H};e.watch(()=>g.value,()=>{var H,J;let R=A.cloneDeep(n.originalItemContents);(H=A.cloneDeep(n.originalItemContents))!=null&&H.find(he=>(he==null?void 0:he.key)==="page")?R=(J=A.cloneDeep(n.originalItemContents))==null?void 0:J.map(he=>((he==null?void 0:he.key)==="page"&&(he.contents=g.value),he)):R.push({key:"page",contents:g.value}),r("change",R)},{deep:!0});const fe=R=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,J;W.value=(H=A.cloneDeep(W.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==(R==null?void 0:R.id)),r("change",(J=A.cloneDeep(n.originalItemContents))==null?void 0:J.map(he=>((he==null?void 0:he.key)==="extraButton"&&(he.contents=W.value),he))),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},N=()=>{var J,he,pe,ha,ta;E.value=x.value;let R={};if(C.value!==""?R.id=C.value:(w.value++,R.id="id"+w.value),(J=E.value)==null||J.forEach(He=>{const _a=Vn==null?void 0:Vn.find(ze=>(ze==null?void 0:ze.label)===(He==null?void 0:He.label));_a?R[_a.key]=He.value:He!=null&&He.children&&He.children.length>0&&(R.children=He.children)}),(he=W.value)!=null&&he.find(He=>He.id===R.id))W.value=(pe=W.value)==null?void 0:pe.map(He=>(He.id===R.id&&(He=R),He));else{let He=A.cloneDeep(W.value)??[];He.push(R),W.value=He}L.value=!1,C.value="";let H=A.cloneDeep(n.originalItemContents);(ha=A.cloneDeep(n.originalItemContents))!=null&&ha.find(He=>(He==null?void 0:He.key)==="extraButton")?H=(ta=A.cloneDeep(n.originalItemContents))==null?void 0:ta.map(He=>((He==null?void 0:He.key)==="extraButton"&&(He.contents=W.value),He)):H.push({key:"extraButton",contents:W.value}),r("change",H)},se=R=>{let H=A.cloneDeep(x.value);H=H==null?void 0:H.map(J=>(J.children||(J.value=R==null?void 0:R[J.name]),J)),x.value=H},U=()=>{L.value=!1,E.value=[],C.value=""},_e=R=>{d.value=!0;let H=[];Pn==null||Pn.forEach(J=>{w.value++,H.push({label:J==null?void 0:J.label,name:J==null?void 0:J.label,type:J.type,value:R[J.key],id:w.value,contents:J==null?void 0:J.options})}),C.value=R==null?void 0:R.id,I.value=H,j.value=H},Ie=R=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,J;k.value=(H=A.cloneDeep(k.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==(R==null?void 0:R.id)),r("change",(J=A.cloneDeep(n.originalItemContents))==null?void 0:J.map(he=>((he==null?void 0:he.key)==="rowButton"&&(he.contents=k.value),he))),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},je=()=>{s.value=!0;let R=[];cr==null||cr.forEach(H=>{w.value++,R.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=R,u.value=R},na=()=>{d.value=!0;let R=[];Pn==null||Pn.forEach(H=>{w.value++,R.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})}),I.value=R,j.value=R},Ca=R=>{let H=A.cloneDeep(j.value);H=H==null?void 0:H.map(J=>(J.children||(J.value=R==null?void 0:R[J.name]),J)),j.value=H},ee=()=>{var J,he,pe,ha,ta;I.value=j.value;let R={};if(C.value!==""?R.id=C.value:(w.value++,R.id="id"+w.value),(J=I.value)==null||J.forEach(He=>{const _a=Pn==null?void 0:Pn.find(ze=>(ze==null?void 0:ze.label)===(He==null?void 0:He.label));_a?R[_a.key]=He.value:He!=null&&He.children&&He.children.length>0&&(R.children=He.children)}),(he=k.value)!=null&&he.find(He=>He.id===R.id))k.value=(pe=k.value)==null?void 0:pe.map(He=>(He.id===R.id&&(He=R),He));else{let He=A.cloneDeep(k.value);He.push(R),k.value=He}d.value=!1,C.value="";let H=A.cloneDeep(n.originalItemContents);(ha=A.cloneDeep(n.originalItemContents))!=null&&ha.find(He=>(He==null?void 0:He.key)==="rowButton")?H=(ta=A.cloneDeep(n.originalItemContents))==null?void 0:ta.map(He=>((He==null?void 0:He.key)==="rowButton"&&(He.contents=k.value),He)):H.push({key:"rowButton",contents:k.value}),r("change",H)},ca=()=>{d.value=!1,C.value="",j.value=[],I.value=[]},de=R=>{s.value=!0;let H=[];cr==null||cr.forEach(J=>{w.value++,H.push({label:J==null?void 0:J.label,name:J==null?void 0:J.label,type:J.type,value:"",id:w.value,contents:J==null?void 0:J.options})}),m.value=H,M.value=R==null?void 0:R.id,u.value=H},pa=R=>{var H;c.value=Lc(A.cloneDeep(c.value),R==null?void 0:R.id),r("change",(H=A.cloneDeep(n.originalItemContents))==null?void 0:H.map(J=>{var he;return(J==null?void 0:J.key)==="header"&&(J.contents=(he=c.value)!=null&&he.some(pe=>pe==null?void 0:pe.children)?[c.value]:c.value),J}))},we=R=>{var J,he,pe;R.type==="fix"?R.id!==""?c.value=$c(c.value,R):c.value=Rc(c.value,R==null?void 0:R.contents):c.value=Vc(c.value,R),c.value=(J=c.value)!=null&&J.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=(pe=A.cloneDeep(n.originalItemContents))==null?void 0:pe.map(ha=>((ha==null?void 0:ha.key)==="header"&&(ha.contents=c.value),ha)):H.push({key:"header",contents:c.value}),r("change",H)},ue=R=>{var J;s.value=!0;let H=[];cr==null||cr.forEach(he=>{w.value++,H.push({label:he==null?void 0:he.label,name:he==null?void 0:he.label,type:he.type,value:R[he.key],id:w.value,contents:he==null?void 0:he.options})}),R!=null&&R.children&&((J=R==null?void 0:R.children)==null?void 0:J.length)>0&&H.push({children:R==null?void 0:R.children,isFormColHidden:!0}),C.value=R==null?void 0:R.id,M.value="",m.value=H,u.value=H},De=R=>{let H=A.cloneDeep(u.value);H=H==null?void 0:H.map(J=>(J.children||(J.value=R==null?void 0:R[J.name]),J)),u.value=H},Ge=()=>{s.value=!1,C.value="",M.value="",u.value=[]},ua=()=>{var J,he,pe,ha,ta,He;m.value=u.value;let R={};if(C.value!==""?R.id=C.value:(w.value++,R.id="id"+w.value),(J=m.value)==null||J.forEach(_a=>{const ze=cr==null?void 0:cr.find(ma=>(ma==null?void 0:ma.label)===(_a==null?void 0:_a.label));ze?R[ze.key]=_a.value:_a!=null&&_a.children&&_a.children.length>0&&(R.children=_a.children)}),(he=c.value)!=null&&he.find(_a=>_a.id===R.id))c.value=(pe=c.value)==null?void 0:pe.map(_a=>(_a.id===R.id&&(_a=R),_a));else{let _a=A.cloneDeep(c.value)??[];M.value===""?_a.push(R):_a=_a==null?void 0:_a.map(ze=>(ze.id===M.value&&(ze.children||(ze.children=[]),ze.children.push(R)),ze)),c.value=_a}c.value=(ha=c.value)!=null&&ha.some(_a=>_a==null?void 0:_a.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(_a=>(_a==null?void 0:_a.key)==="header")?H=(He=A.cloneDeep(n.originalItemContents))==null?void 0:He.map(_a=>((_a==null?void 0:_a.key)==="header"&&(_a.contents=c.value),_a)):H.push({key:"header",contents:c.value}),r("change",H)},Ja=R=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,J;c.value=(H=A.cloneDeep(c.value))==null?void 0:H.filter(he=>(he==null?void 0:he.id)!==(R==null?void 0:R.id)),r("change",(J=A.cloneDeep(n.originalItemContents))==null?void 0:J.map(he=>{var pe;return(he==null?void 0:he.key)==="header"&&(he.contents=(pe=c.value)!=null&&pe.some(ha=>ha==null?void 0:ha.children)?[c.value]:c.value),he})),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return e.watch(()=>n.originalItemContents,()=>{var R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae;if(!(!n.originalItemContents||n.originalItemContents.length===0))if(i.value=A.cloneDeep(n.originalItemContents),c.value=(H=(R=i.value)==null?void 0:R.find(oe=>(oe==null?void 0:oe.key)==="header"))==null?void 0:H.contents,k.value=(he=(J=i.value)==null?void 0:J.find(oe=>(oe==null?void 0:oe.key)==="rowButton"))==null?void 0:he.contents,W.value=(ha=(pe=i.value)==null?void 0:pe.find(oe=>(oe==null?void 0:oe.key)==="extraButton"))==null?void 0:ha.contents,g.value=(He=(ta=i.value)==null?void 0:ta.find(oe=>(oe==null?void 0:oe.key)==="page"))!=null&&He.contents?!!((ze=(_a=i.value)==null?void 0:_a.find(oe=>(oe==null?void 0:oe.key)==="page"))!=null&&ze.contents):!1,$.value=(Oa=(ma=i.value)==null?void 0:ma.find(oe=>(oe==null?void 0:oe.key)==="tableToForm"))==null?void 0:Oa.contents,c.value=(Ma=c.value)==null?void 0:Ma.map((oe,Xe)=>(Array.isArray(oe)?oe=ah(oe):oe={label:(oe==null?void 0:oe.label)??"",prop:(oe==null?void 0:oe.label)==="操作"?"operate":oe==null?void 0:oe.prop,width:oe!=null&&oe.width?parseInt(oe.width):"",fixed:(oe==null?void 0:oe.fixed)??void 0,sortable:(oe==null?void 0:oe.sortable)??!1,align:(oe==null?void 0:oe.align)??"left",showOverflowTooltip:(oe==null?void 0:oe.showOverflowTooltip)??!0,isNotDrag:(oe==null?void 0:oe.isNotDrag)??!1,isEditCol:(oe==null?void 0:oe.isEditCol)??!1,isOperate:(oe==null?void 0:oe.isOperate)??!1,id:(oe==null?void 0:oe.id)??Xe,formMenuSelect:(oe==null?void 0:oe.formMenuSelect)??void 0,groupSelect:(oe==null?void 0:oe.groupSelect)??void 0},oe)),c.value=(fa=c.value)!=null&&fa.every(oe=>Array.isArray(oe))?(Ba=c.value)==null?void 0:Ba[0]:c.value,k.value=(Te=k.value)==null?void 0:Te.map((oe,Xe)=>oe={label:(oe==null?void 0:oe.label)??"",type:(oe==null?void 0:oe.type)??"",textColor:(oe==null?void 0:oe.textColor)??"#000000",id:(oe==null?void 0:oe.id)??Xe}),W.value=(ye=W.value)==null?void 0:ye.map((oe,Xe)=>oe={label:(oe==null?void 0:oe.label)??"",type:(oe==null?void 0:oe.type)??"",background:(oe==null?void 0:oe.background)??"var(--ssComponent-primary-color)",id:(oe==null?void 0:oe.id)??Xe}),$.value)$.value=(ae=$.value)==null?void 0:ae.map(oe=>{w.value++;let Xe=oe;return Xe.id=w.value,Xe});else{let oe=[];const Xe=(Ne=te.getColumnChild(A.cloneDeep(c.value)))==null?void 0:Ne.filter(Ze=>(Ze==null?void 0:Ze.prop)!=="operate");Xe==null||Xe.forEach(Ze=>{var Pa;w.value++,oe.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:(Pa=Ze==null?void 0:Ze.groupSelect)==null?void 0:Pa.split(":"),selectRelateType:"关联绑定列"})}),$.value=oe}},{deep:!0,immediate:!0}),(R,H)=>{const J=e.resolveComponent("svg-icon"),he=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",wh,[e.createElementVNode("div",_h,[e.createElementVNode("div",Sh,[H[2]||(H[2]=e.createElementVNode("div",null,e.toDisplayString("表头"),-1)),e.createVNode(he,{class:"icon-content",onClick:je,id:"themeButton"},{icon:e.withCtx(()=>[e.createVNode(J,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[1]||(H[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",Eh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(pe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",Ch,[e.createElementVNode("div",Dh,e.toDisplayString(pe==null?void 0:pe.label),1),e.createElementVNode("div",Th,[e.createVNode(J,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>de(pe)},null,8,["onClick"]),e.createVNode(J,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>ue(pe)},null,8,["onClick"]),e.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>Ja(pe)},null,8,["onClick"])])]),pe!=null&&pe.children&&pe.children.length>0?(e.openBlock(),e.createElementBlock("div",Bh,[e.createVNode(Pc,{tableChildContents:pe==null?void 0:pe.children,onDeleteChange:pa,onFixChange:we},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),128))]),e.createElementVNode("div",Nh,[H[4]||(H[4]=e.createElementVNode("div",null,e.toDisplayString("行内按钮"),-1)),e.createVNode(he,{class:"icon-content",id:"themeButton",onClick:na},{icon:e.withCtx(()=>[e.createVNode(J,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[3]||(H[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",Ah,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,(pe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",zh,[e.createElementVNode("div",Mh,e.toDisplayString(pe==null?void 0:pe.label),1),e.createElementVNode("div",Ih,[e.createVNode(J,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ta=>_e(pe)},null,8,["onClick"]),e.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>Ie(pe)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Oh,[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(J,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[5]||(H[5]=e.createTextVNode(" 新增 "))]),_:1,__:[5]})]),e.createElementVNode("div",Lh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(W.value,(pe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",Rh,[e.createElementVNode("div",$h,e.toDisplayString(pe==null?void 0:pe.label),1),e.createElementVNode("div",Vh,[e.createVNode(J,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ta=>Fe(pe)},null,8,["onClick"]),e.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>fe(pe)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Ph,[H[8]||(H[8]=e.createElementVNode("div",null,e.toDisplayString("表格弹框字段设置"),-1)),e.createVNode(he,{class:"icon-content",id:"themeButton",onClick:le},{icon:e.withCtx(()=>[e.createVNode(J,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[7]||(H[7]=e.createTextVNode(" 新增 "))]),_:1,__:[7]})]),e.createElementVNode("div",Fh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($.value,(pe,ha)=>(e.openBlock(),e.createElementBlock("div",{key:ha},[e.createElementVNode("div",jh,[e.createElementVNode("div",Hh,e.toDisplayString(pe==null?void 0:pe.label),1),e.createElementVNode("div",Uh,[e.createVNode(J,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ta=>ie(pe)},null,8,["onClick"]),e.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ta=>Y(pe)},null,8,["onClick"])])])]))),128))]),H[10]||(H[10]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("分页"))],-1)),e.createElementVNode("div",qh,[e.createElementVNode("div",Wh,[H[9]||(H[9]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否分页"),-1)),e.createVNode(sl._sfc_main$1,{modelValue:g.value,"onUpdate:modelValue":H[0]||(H[0]=pe=>g.value=pe)},null,8,["modelValue"])])])]),e.createVNode(Ar.ssDialog,{visible:s.value,onBeforeDestroy:Ge,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Kh,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:De},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Gh,[e.createVNode(he,{onClick:Ge,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",Yh,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:I.value,key:I.value,isEnableWrap:!0,onChange:Ca},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Jh,[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:ee,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",Xh,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:se},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Zh,[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:N,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:ce,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Qh,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:me,onChangeVisible:X,onBlurChange:Be},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",e4,[e.createVNode(he,{onClick:ce,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:Ce,id:"themeButton"},{default:e.withCtx(()=>H[18]||(H[18]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[18]})])]),_:1},8,["visible"])])}}},l4=Ql._export_sfc(a4,[["__scopeId","data-v-7a6b87b5"]]),r4=A.useModelComp(A.pinia),{pageMapState:n4}=A.storeToRefs(r4),i4=A.useMenuState(A.pinia),{activeMenuPath:o4}=A.storeToRefs(i4),t4=e.ref(24),s4=e.ref(6),c4=e.ref(10),u4=e.ref(70),d4=e.ref(.18),p4=e.ref(45),f4=(a,l,n,r)=>{var i,s,h,c,d,m,g,u,C,M,k,W,I,j,L,E;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)||t4.value,h:((u=(g=a==null?void 0:a.value)==null?void 0:g.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)||s4.value,minH:((W=(k=a==null?void 0:a.value)==null?void 0:k.tableData)==null?void 0:W.minH)||d4.value,maxH:((j=(I=a==null?void 0:a.value)==null?void 0:I.tableData)==null?void 0:j.maxH)||p4.value,i:((E=(L=a==null?void 0:a.value)==null?void 0:L.tableData)==null?void 0:E.i)||l,id:(a==null?void 0:a.id)||l+"",component:r}},h4=(a,l)=>{var r,i,s,h,c,d,m,g;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=((g=(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:g.length)/5);return n*2},Fc=(a,l,n)=>{var h,c;const r=(c=(h=n4.value)==null?void 0:h[o4.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,g,u;return((u=(g=(m=d==null?void 0:d.value)==null?void 0:m.tableData)==null?void 0:g.component)==null?void 0:u.id)===a.id}),s=h4(a);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((d,m)=>Fc(d,m))),{...f4(i,l,s,a)}},v4=(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)=>Fc(r,i)):[]},m4=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}]}]}}),y4=(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}),g4=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 g;const d=m4(n==null?void 0:n.optionItems),m=c?(g=d[c==null?void 0:c.toUpperCase()])==null?void 0:g[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=>sl.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(g=>{var u;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(u=g==null?void 0:g.options)==null?void 0:u.map(C=>({...C,disabled:!0}))}:(g==null?void 0:g.prop)==="isGridLayout"?{...g,disabled:!0}:g}):i.value=(m=i.value)==null?void 0:m.map(g=>{var u;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(u=g==null?void 0:g.options)==null?void 0:u.map(C=>({...C,disabled:!1}))}:(g==null?void 0:g.prop)==="isGridLayout"?{...g,disabled:!1}:g}),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"),g=e.resolveComponent("el-row");return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,u=>(e.openBlock(),e.createBlock(g,{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)}}}),b4=Ql._export_sfc(g4,[["__scopeId","data-v-6c233914"]]),k4=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,E)=>(L[E==null?void 0:E.prop]=E==null?void 0:E.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(""),g=(j,L,E)=>{var b;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:(b=n==null?void 0:n.relatedData)==null?void 0:b.map(S=>({label:S==null?void 0:S.任务名称,value:S==null?void 0:S.任务名称}))},{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 E&&(E==null?void 0:E.length)>0?w=[...x,...u(j,L,E)]:w=x,w},u=(j,L,E)=>{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 E?x==null?void 0:x.filter(w=>E==null?void 0:E.includes(w==null?void 0:w.prop)):x},C=(j,L)=>{var S,$,V,le,X,me,Be,F,ie;const E=((X=(le=(V=($=(S=n==null?void 0:n.comp)==null?void 0:S.compData)==null?void 0:$.find(Y=>(Y==null?void 0:Y.key)==="header"))==null?void 0:V.contents)==null?void 0:le.filter(Y=>(Y==null?void 0:Y.label)!=="操作"))==null?void 0:X.map(Y=>({value:Y==null?void 0:Y.prop,label:Y.label})))||[],x=/button/i,w=((ie=(F=(Be=(me=n==null?void 0:n.comp)==null?void 0:me.compData)==null?void 0:Be.filter(Y=>x.test(Y==null?void 0:Y.key)))==null?void 0:F.flatMap(Y=>Y==null?void 0:Y.contents))==null?void 0:ie.map(Y=>({value:Y==null?void 0:Y.label,label:Y.label})))||[],b=g(E,w,j);d.value=L?y4(b,L):b,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 E=L==null?void 0:L.join("/");C(E==="统计/统计规则/自定义"?["统计算法源","统计是否获取错误集"]:E==="进度设置/进度条"?["进度关键词"]: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)},I=j=>{r("onButtonClick",j)};return(j,L)=>(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:d.value,key:d.value,isStartJustify:!1,isEnableWrap:!1,formRules:c.value.formRules,buttonValue:c.value.buttonValue,onChange:k,onBlurChange:W,onOnButtonClick:I},null,8,["rowContents","formRules","buttonValue"]))}}),x4=Ql._export_sfc(k4,[["__scopeId","data-v-7c660c1f"]]),w4={};function _4(a,l){return null}const S4=Ql._export_sfc(w4,[["render",_4]]),E4={class:"form-operate-content"},C4={class:"form-operate-item"},D4={class:"operate-title"},T4={class:"operate-content"},B4={class:"fix-content"},N4={class:"fix-button"},A4={class:"operate-title"},z4={class:"operate-content"},M4={class:"fix-content"},I4={class:"fix-button"},O4={style:{display:"flex","justify-content":"space-between"}},L4={class:"form-content"},R4={class:"dialog-footer"},$4={class:"form-content"},V4={__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([]),g=e.ref(""),u=e.ref(!1),C=e.ref(0),M=e.ref([]),k=e.ref([]),W=(F,ie)=>{if((ie==null?void 0:ie.type)=="Select"&&(F==null?void 0:F.key)==="selectRelateType"){const Y=ie==null?void 0:ie.optionUrl;return(Y==null?void 0:Y.selectRelateType)||ie[F.key]}if((ie==null?void 0:ie.type)=="Select"&&(F==null?void 0:F.key)==="menuSelect"){const Y=ie==null?void 0:ie.optionUrl;return(Y==null?void 0:Y.menuSelect)||ie[F.key]}if((ie==null?void 0:ie.type)=="Select"&&(F==null?void 0:F.key)==="groupSelect"){const Y=ie==null?void 0:ie.optionUrl;return(Y==null?void 0:Y.groupSelect)||ie[F.key]}if((ie==null?void 0:ie.type)=="Select"&&(F==null?void 0:F.key)==="originalContent")return(ie==null?void 0:ie.value)||ie[F.key];if((ie==null?void 0:ie.type)=="Select"&&(F==null?void 0:F.key)==="multiple"){const Y=ie[F.key];return ac(Y)?Y:F.default}return(F==null?void 0:F.label)==="类型"&&ie[F.key]===""?"Input":(F==null?void 0:F.key)==="isFormColHidden"&&!ie[F.key]?!1:ie[F.key]},I=async F=>{var ce,Ce,Fe,fe,N,se;i.value=!0;let ie=[];const Y=await((Fe=(Ce=(ce=te.FormContent)==null?void 0:ce.find(U=>(U==null?void 0:U.key)===((F==null?void 0:F.type)===""?"Input":F==null?void 0:F.type)))==null?void 0:Ce.value)==null?void 0:Fe.value)??((N=(fe=te.FormContent)==null?void 0:fe.find(U=>(U==null?void 0:U.key)===((F==null?void 0:F.type)===""?"Input":F==null?void 0:F.type)))==null?void 0:N.value);if(Y==null||Y.forEach(U=>{C.value++,ie.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,F),id:C.value,contents:U==null?void 0:U.options,width:(F==null?void 0:F.width)??1})}),F!=null&&F.menuSelect&&((se=F==null?void 0:F.menuSelect)==null?void 0:se.length)>0){const U=await te.menuToContentType(F==null?void 0:F.menuSelect);ie=ie==null?void 0:ie.map(_e=>((_e==null?void 0:_e.name)==="组信息选项"&&(_e.contents=U),_e))}g.value=F==null?void 0:F.id,s.value=await te.selectToBase(te.formToOptionsContents(ie)),h.value=await te.selectToBase(te.formToOptionsContents(ie))},j=F=>{var Y;c.value=!0;let ie=[];(Y=te.FormButton)==null||Y.forEach(ce=>{C.value++,ie.push({label:ce==null?void 0:ce.label,name:ce==null?void 0:ce.label,type:ce.type,value:(ce==null?void 0:ce.label)==="类型"&&F[ce.key]===""?"normal":F[ce.key],id:C.value,contents:ce==null?void 0:ce.options})}),M.value=ie,k.value=ie,g.value=F==null?void 0:F.id};e.watch(()=>u.value,()=>{var ie,Y;let F=A.cloneDeep(n.originalItemContents);(ie=A.cloneDeep(n.originalItemContents))!=null&&ie.find(ce=>(ce==null?void 0:ce.key)==="enableWrap")?F=(Y=A.cloneDeep(n.originalItemContents))==null?void 0:Y.map(ce=>((ce==null?void 0:ce.key)==="enableWrap"&&(ce.contents=!u.value),ce)):F.push({key:"enableWrap",contents:!u.value}),r("change",F)},{deep:!0});const L=()=>{var Y,ce,Ce,Fe,fe;M.value=k.value;let F={};if(g.value!==""?F.id=g.value:(C.value++,F.id="id"+C.value),(Y=M.value)==null||Y.forEach(N=>{var U;const se=(U=te.FormButton)==null?void 0:U.find(_e=>(_e==null?void 0:_e.label)===(N==null?void 0:N.label));se&&(F[se.key]=N.value)}),(ce=d.value)!=null&&ce.find(N=>N.id===F.id))d.value=(Ce=d.value)==null?void 0:Ce.map(N=>(N.id===F.id&&(N=F),N));else{let N=A.cloneDeep(d.value);d.value||(d.value=[]),N.push(F),d.value=N}c.value=!1,g.value="";let ie=A.cloneDeep(n.originalItemContents);(Fe=A.cloneDeep(n.originalItemContents))!=null&&Fe.find(N=>(N==null?void 0:N.key)==="formButton")?ie=(fe=A.cloneDeep(n.originalItemContents))==null?void 0:fe.map(N=>((N==null?void 0:N.key)==="formButton"&&(N.contents=d.value),N)):ie.push({key:"formButton",contents:d.value}),r("change",ie)},E=F=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var ie,Y;m.value=(ie=A.cloneDeep(m.value))==null?void 0:ie.filter(ce=>(ce==null?void 0:ce.id)!==(F==null?void 0:F.id)),r("change",(Y=A.cloneDeep(n.originalItemContents))==null?void 0:Y.map(ce=>((ce==null?void 0:ce.key)==="formContent"&&(ce.contents=m.value),ce))),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=F=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var ie,Y;d.value=(ie=A.cloneDeep(d.value))==null?void 0:ie.filter(ce=>(ce==null?void 0:ce.id)!==(F==null?void 0:F.id)),r("change",(Y=A.cloneDeep(n.originalItemContents))==null?void 0:Y.map(ce=>((ce==null?void 0:ce.key)==="formButton"&&(ce.contents=d.value),ce))),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},w=()=>{var ie;c.value=!0;let F=[];(ie=te.FormButton)==null||ie.forEach(Y=>{C.value++,F.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=F,k.value=F},b=()=>{var ie,Y,ce;i.value=!0;let F=[];(ce=(Y=(ie=te.FormContent)==null?void 0:ie.find(Ce=>(Ce==null?void 0:Ce.key)==="Input"))==null?void 0:Y.value)==null||ce.forEach(Ce=>{C.value++,F.push({label:Ce==null?void 0:Ce.label,name:Ce==null?void 0:Ce.label,type:Ce.type,value:(Ce==null?void 0:Ce.label)==="类型"?"Input":"",id:C.value,contents:Ce==null?void 0:Ce.options})}),s.value=F,h.value=F},S=F=>{let ie=A.cloneDeep(k.value);ie=ie==null?void 0:ie.map(Y=>(Y.value=F==null?void 0:F[Y.name],Y)),k.value=ie},$=F=>{const ie=F.find(Ce=>(Ce==null?void 0:Ce.name)==="类型");if((ie==null?void 0:ie.value)!="Select")return;const Y=F.find(Ce=>(Ce==null?void 0:Ce.name)==="多选"),ce=F.find(Ce=>(Ce==null?void 0:Ce.name)==="初始值");Y!=null&&Y.value&&No.isString(ce.value)&&(ce.value=[ce.value]),!(Y!=null&&Y.value)&&!No.isString(ce.value)&&(ce.value="")},V=async F=>{var ie,Y,ce,Ce,Fe,fe,N,se,U,_e,Ie,je;if((F==null?void 0:F.类型)!==((Y=(ie=h.value)==null?void 0:ie.find(na=>(na==null?void 0:na.label)==="类型"))==null?void 0:Y.value)){let na=[];const Ca=await((Fe=(Ce=(ce=te.FormContent)==null?void 0:ce.find(ee=>(ee==null?void 0:ee.key)===((F==null?void 0:F.类型)===""?"Input":F==null?void 0:F.类型)))==null?void 0:Ce.value)==null?void 0:Fe.value)?await((_e=(U=(se=te.FormContent)==null?void 0:se.find(ee=>(ee==null?void 0:ee.key)===((F==null?void 0:F.类型)===""?"Input":F==null?void 0:F.类型)))==null?void 0:U.value)==null?void 0:_e.value):(N=(fe=te.FormContent)==null?void 0:fe.find(ee=>(ee==null?void 0:ee.key)===((F==null?void 0:F.类型)===""?"Input":F==null?void 0:F.类型)))==null?void 0:N.value;if(Ca==null||Ca.forEach(ee=>{var de,pa;C.value++;const ca=$u(ee==null?void 0:ee.default)?(F==null?void 0:F[ee.label])??ee.value??"":ee==null?void 0:ee.default;na.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:ca,prop:ee==null?void 0:ee.prop,id:C.value,contents:ee==null?void 0:ee.options,width:((pa=(de=h.value)==null?void 0:de[0])==null?void 0:pa.width)??1})}),F!=null&&F.菜单选项&&((Ie=F==null?void 0:F.菜单选项)==null?void 0:Ie.length)>0){const ee=await te.menuToContentType(F==null?void 0:F.菜单选项);na=na==null?void 0:na.map(ca=>((ca==null?void 0:ca.name)==="组信息选项"&&(ca.contents=ee),ca))}$(na),h.value=await te.selectToBase(A.cloneDeep(na)),s.value=await te.selectToBase(A.cloneDeep(na))}else{let na=A.cloneDeep(h.value);if(na=na==null?void 0:na.map(Ca=>(Ca.value=F==null?void 0:F[Ca.name],Ca)),F!=null&&F.菜单选项&&((je=F==null?void 0:F.菜单选项)==null?void 0:je.length)>0){const Ca=await te.menuToContentType(F==null?void 0:F.菜单选项);na=na==null?void 0:na.map(ee=>((ee==null?void 0:ee.name)==="组信息选项"&&(ee.contents=Ca),ee))}na=te.formToOptionsContents(na),$(na),h.value=await te.selectToBase(A.cloneDeep(na))}},le=F=>{F||(s.value=h.value)},X=async F=>{await V(F),s.value=h.value},me=Il.debounce(async()=>{var ce,Ce,Fe,fe,N,se,U,_e,Ie,je,na,Ca;s.value=h.value;let F={};F.width=((Ce=(ce=s.value)==null?void 0:ce[0])==null?void 0:Ce.width)??1,g.value!==""?F.id=g.value:(C.value++,F.id="id"+C.value);let ie=await((N=(fe=(Fe=te.FormContent)==null?void 0:Fe.find(ee=>{var ca,de;return(ee==null?void 0:ee.key)===(((de=(ca=s.value)==null?void 0:ca.find(pa=>(pa==null?void 0:pa.label)==="类型"))==null?void 0:de.value)??"label")}))==null?void 0:fe.value)==null?void 0:N.value)??((U=(se=te.FormContent)==null?void 0:se.find(ee=>{var ca,de;return(ee==null?void 0:ee.key)===(((de=(ca=s.value)==null?void 0:ca.find(pa=>(pa==null?void 0:pa.label)==="类型"))==null?void 0:de.value)??"label")}))==null?void 0:U.value);if((_e=s.value)==null||_e.forEach(ee=>{const ca=ie==null?void 0:ie.find(de=>(de==null?void 0:de.label)===(ee==null?void 0:ee.label));ca&&(F[ca.key]=ee.value)}),F.width=F.width?F.width:1,F.key=F==null?void 0:F.label,F.isFormColHidden=F==null?void 0:F.isFormColHidden,(Ie=m.value)!=null&&Ie.find(ee=>ee.id===F.id))m.value=(je=m.value)==null?void 0:je.map(ee=>(ee.id===F.id&&(ee=F),ee));else{let ee=A.cloneDeep(m.value);ee.push(F),m.value=ee}m.value=m.value.map(({id:ee,...ca})=>ca),i.value=!1,g.value="";let Y=A.cloneDeep(n.originalItemContents);(na=A.cloneDeep(n.originalItemContents))!=null&&na.find(ee=>(ee==null?void 0:ee.key)==="formContent")?Y=(Ca=A.cloneDeep(n.originalItemContents))==null?void 0:Ca.map(ee=>((ee==null?void 0:ee.key)==="formContent"&&(ee.contents=m.value),ee)):Y.push({key:"formContent",contents:m.value}),r("change",Y)},300),Be=()=>{i.value=!1,c.value=!1,g.value="",h.value=[],k.value=[]};return e.watch(()=>n.originalItemContents,()=>{var ie,Y,ce,Ce,Fe,fe;if(!n.originalItemContents||n.originalItemContents.length===0)return;const F=A.cloneDeep(n.originalItemContents);m.value=((ie=F==null?void 0:F.find(N=>(N==null?void 0:N.key)==="formContent"))==null?void 0:ie.contents)??[],d.value=((Y=F==null?void 0:F.find(N=>(N==null?void 0:N.key)==="formButton"))==null?void 0:Y.contents)??[],u.value=(ce=F==null?void 0:F.find(N=>(N==null?void 0:N.key)==="enableWrap"))!=null&&ce.contents?!((Ce=F==null?void 0:F.find(N=>(N==null?void 0:N.key)==="enableWrap"))!=null&&Ce.contents):!0,m.value=(Fe=A.cloneDeep(m.value))==null?void 0:Fe.map((N,se)=>{var _e;let U=N;return U.id=(N==null?void 0:N.id)??se,N!=null&&N.label||(N.label=(N==null?void 0:N.key)??(N==null?void 0:N.label)??""),N!=null&&N.type||(N.type=(N==null?void 0:N.type)??""),N.contents=((_e=N==null?void 0:N.options)==null?void 0:_e.length)===0?(N==null?void 0:N.contents)??"":N==null?void 0:N.options,U}),m.value=te.formToOptionsContents(m.value),d.value=(fe=d.value)==null?void 0:fe.map((N,se)=>N={label:(N==null?void 0:N.label)??"",type:(N==null?void 0:N.type)??"",background:(N==null?void 0:N.background)??"var(--ssComponent-primary-color)",id:se})},{deep:!0,immediate:!0}),(F,ie)=>{const Y=e.resolveComponent("svg-icon"),ce=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",E4,[e.createElementVNode("div",C4,[e.createElementVNode("div",D4,[ie[2]||(ie[2]=e.createElementVNode("div",null,e.toDisplayString("表单内容"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:b},{icon:e.withCtx(()=>[e.createVNode(Y,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[ie[1]||(ie[1]=e.createElementVNode("div",null,e.toDisplayString("新增"),-1))]),_:1,__:[1]})]),e.createElementVNode("div",T4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(Ce,Fe)=>(e.openBlock(),e.createElementBlock("div",{key:Fe},[e.createElementVNode("div",B4,[e.createElementVNode("div",null,e.toDisplayString(Ce.label),1),e.createElementVNode("div",N4,[e.createVNode(Y,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:fe=>I(Ce)},null,8,["onClick"]),e.createVNode(Y,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:fe=>E(Ce)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",A4,[ie[4]||(ie[4]=e.createElementVNode("div",null,e.toDisplayString("表单按钮"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:w},{icon:e.withCtx(()=>[e.createVNode(Y,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[ie[3]||(ie[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",z4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(Ce,Fe)=>(e.openBlock(),e.createElementBlock("div",{key:Fe},[e.createElementVNode("div",M4,[e.createElementVNode("div",null,e.toDisplayString(Ce.label),1),e.createElementVNode("div",I4,[e.createVNode(Y,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:fe=>j(Ce)},null,8,["onClick"]),e.createVNode(Y,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:fe=>x(Ce)},null,8,["onClick"])])])]))),128))]),ie[6]||(ie[6]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("表单布局"))],-1)),e.createElementVNode("div",O4,[ie[5]||(ie[5]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否自动撑宽"),-1)),e.createVNode(sl._sfc_main$1,{modelValue:u.value,"onUpdate:modelValue":ie[0]||(ie[0]=Ce=>u.value=Ce)},null,8,["modelValue"])])]),e.createVNode(Ar.ssDialog,{visible:i.value,onBeforeDestroy:Be,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",L4,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!0,onChange:V,onChangeVisible:le,onBlurChange:X},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",R4,[e.createVNode(ce,{onClick:Be,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>ie[7]||(ie[7]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[7]}),e.createVNode(ce,{class:"ok-button button",onClick:e.unref(me),id:"themeButton"},{default:e.withCtx(()=>ie[8]||(ie[8]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[8]},8,["onClick"])])]),_:1},8,["visible"]),e.createVNode(Ar.ssDialog,{visible:c.value,onBeforeDestroy:Be,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",$4,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:M.value,key:M.value,isEnableWrap:!0,onChange:S},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:Be,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:L},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},Cs=Ql._export_sfc(V4,[["__scopeId","data-v-20850524"]]),P4={class:"step-module content"},F4={class:"module-data"},j4={class:"step-module layout"},H4={class:"form-content"},U4=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({}),g=e.ref([]),u=I=>{var j;m.value=I,r("change",(j=k())==null?void 0:j.compData)},C=(I,j)=>{var L,E;switch(I){case"create":(L=s.value)==null||L.forEach(x=>{x.value=""}),d.value="create",c.visible=!0;break;case"update":(E=s.value)==null||E.forEach(x=>{x.value=j[x==null?void 0:x.prop]}),d.value="update",c.visible=!0;break;case"delete":g.value.splice(j,1),d.value="delete";break}},M=I=>{var j,L,E;if((I==null?void 0:I.buttonName)==="确认"){const x=A.cloneDeep(I==null?void 0:I.content);switch(Object.keys(x).forEach(w=>{x[w]===""&&delete x[w]}),d.value){case"create":g.value.push({...x,index:((j=g.value)==null?void 0:j.length)+1});break;case"update":g.value=(L=g.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",(E=k())==null?void 0:E.compData),c.visible=!1}else c.visible=!1},k=()=>({comp:"Step",compData:[{key:"stepList",contents:g.value},{key:"stepConfig",contents:m.value}]}),W=()=>{c.visible=!1};return e.watch(()=>n==null?void 0:n.itemContents,I=>{var j,L;I&&(m.value=((j=I==null?void 0:I.find(E=>E.key==="stepConfig"))==null?void 0:j.contents)??{},g.value=((L=I==null?void 0:I.find(E=>E.key==="stepList"))==null?void 0:L.contents)??[])},{immediate:!0}),(I,j)=>{const L=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",P4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{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",F4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.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(E,{type:"primary",size:"small",onClick:b=>C("update",{...x,index:w+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>C("delete",w)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",j4,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(sl.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",H4,[(e.openBlock(),e.createBlock(sl.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)}}}),q4=Ql._export_sfc(U4,[["__scopeId","data-v-7dbd17f2"]]),W4={class:"step-module content"},K4={class:"module-data"},G4={class:"step-module layout"},Y4={class:"form-content"},J4=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"}]),g=e.reactive({visible:!1,width:"40%",title:"时间线"}),u=I=>{var j;s.value=I,r("change",(j=k())==null?void 0:j.compData)},C=(I,j)=>{var L,E;switch(I){case"create":(L=d.value)==null||L.forEach(x=>{x.value=""}),i.value="create",g.visible=!0;break;case"update":(E=d.value)==null||E.forEach(x=>{x.value=j[x==null?void 0:x.prop]}),i.value="update",g.visible=!0;break;case"delete":h.value.splice(j,1),i.value="delete";break}},M=I=>{var j,L,E,x;if((I==null?void 0:I.buttonName)==="确认"){const w=A.cloneDeep(I==null?void 0:I.content);switch(Object.keys(w).forEach(b=>{w[b]===""&&delete w[b]}),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=(E=h.value)==null?void 0:E.map(b=>b.index===(w==null?void 0:w.index)?{...b,content:w==null?void 0:w.content,timestamp:w==null?void 0:w.timestamp}:b);break}r("change",(x=k())==null?void 0:x.compData),g.visible=!1}else g.visible=!1},k=()=>({comp:"TimeLine",compData:[{key:"timeLineList",contents:h.value},{key:"timeLineConfig",contents:s.value}]}),W=()=>{g.visible=!1};return e.watch(()=>n==null?void 0:n.itemContents,I=>{var j,L;I&&(s.value=((j=I==null?void 0:I.find(E=>E.key==="timeLineConfig"))==null?void 0:j.contents)??{},h.value=((L=I==null?void 0:I.find(E=>E.key==="timeLineList"))==null?void 0:L.contents)??[])},{immediate:!0}),(I,j)=>{const L=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",W4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{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",K4,[(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(E,{type:"primary",size:"small",onClick:b=>C("update",{...x,index:w+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>C("delete",w)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",G4,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(sl.ssForm,{rowContents:c.value,onChange:u},null,8,["rowContents"])])]),e.createVNode(Ar.ssDialog,{visible:g.visible,title:g.title,onBeforeDestroy:W,width:g.width},{default:e.withCtx(()=>[e.createElementVNode("div",Y4,[(e.openBlock(),e.createBlock(sl.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)}}}),X4=Ql._export_sfc(J4,[["__scopeId","data-v-39ffc861"]]),Z4={};function Q4(a,l){return e.openBlock(),e.createElementBlock("div")}const e2=Ql._export_sfc(Z4,[["render",Q4]]),a2={class:"extra-content"},l2={key:0},r2={key:1},n2={class:"dialog-footer"},i2={__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({}),g=e.ref();e.watch(()=>[n.itemData],()=>{var x;const E=A.cloneDeep(n.itemData);i.value=(x=A.cloneDeep(E))==null?void 0:x.map(w=>{var b;if(w.key==="extra"){let S=[];(b=w.value)==null||b.forEach($=>{var V;S.push((V=Object.values($))==null?void 0:V[0])}),w.value=S}return w})},{deep:!0,immediate:!0});const u=(E,x,w,b)=>{var $;let S={};(($=E==null?void 0:E[0])==null?void 0:$.contents)==="详情"&&(c.value=!0,S[x]=E,s.value=E==null?void 0:E.filter(V=>(V==null?void 0:V.key)!=="tableContentName"),d.value=S,m.value=w,g.value=b.id)},C=E=>{var V,le,X,me;const x=(le=(V=Object.values(A.cloneDeep(d.value)))==null?void 0:V[0])==null?void 0:le.filter(Be=>(Be==null?void 0:Be.key)==="tableContentName"),w=(me=(X=Object.values(A.cloneDeep(d.value)))==null?void 0:X[0])==null?void 0:me.filter(Be=>(Be==null?void 0:Be.key)!=="tableContentName"),b=w==null?void 0:w.map((Be,F)=>{var ie;return F===E.index&&(Be==null?void 0:Be.comp)==="Table"&&(Be.compData=(ie=Be.compData)==null?void 0:ie.map(Y=>{var ce,Ce;return(Y==null?void 0:Y.key)==="tableContents"&&(Y.contents=(Ce=(ce=E.content)==null?void 0:ce.map(Fe=>{let fe={};for(let N in Fe)N!=="id"&&(fe[N]=Fe[N]);return fe}))==null?void 0:Ce.map(Fe=>Object.values(Fe))),Y})),Be});b.unshift(x==null?void 0:x[0]);let S=A.cloneDeep(d.value),$={};for(let Be in S)$[Be]=b;d.value=$},M=()=>{c.value=!1,d.value={},m.value={},g.value=void 0,r.value++},k=E=>{var V,le,X,me;const x=(le=(V=Object.values(A.cloneDeep(d.value)))==null?void 0:V[0])==null?void 0:le.filter(Be=>(Be==null?void 0:Be.key)==="tableContentName"),w=(me=(X=Object.values(A.cloneDeep(d.value)))==null?void 0:X[0])==null?void 0:me.filter(Be=>(Be==null?void 0:Be.key)!=="tableContentName"),b=w==null?void 0:w.map((Be,F)=>(F===E.index&&(Be.compData=E.contents),Be));b.unshift(x==null?void 0:x[0]);let S=A.cloneDeep(d.value),$={};for(let Be in S)$[Be]=b;d.value=$},W=()=>{var x,w;let E={};for(let b in m.value)b===((x=Object.keys(d.value))==null?void 0:x[0])?E[b]=(w=Object.values(d.value))==null?void 0:w[0]:E[b]=m.value[b];h("change",{buttonName:"编辑",index:g.value,singleContent:E},"methodData"),c.value=!1,d.value={},m.value={},g.value=void 0},I=()=>{c.value=!1,d.value={},m.value={},g.value=void 0},j=E=>{h("change",E,"methodData")},L=E=>zi(E);return(E,x)=>{const w=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",a2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(b,S)=>(e.openBlock(),e.createElementBlock("div",{key:r.value},[(b==null?void 0:b.key)==="extra"?(e.openBlock(),e.createElementBlock("div",l2)):(e.openBlock(),e.createElementBlock("div",r2,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(L(b.comp)),{itemData:b==null?void 0:b.compData,childItemData:b==null?void 0:b.itemChildData,key:S,index:(b==null?void 0:b.id)??S,onContentClick:u,onChange:j},null,40,["itemData","childItemData","index"]))]))]))),128)),e.createVNode(Ar.ssDialog,{visible:c.value,onBeforeDestroy:I},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(b,S)=>(e.openBlock(),e.createElementBlock("div",{key:S,class:"extra-dialog"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(L(b.comp)),{itemData:b==null?void 0:b.compData,onChange:C,childItemData:b==null?void 0:b.itemChildData,key:S,onContentChange:k,index:(b==null?void 0:b.id)??S,class:"extra-component"},null,40,["itemData","childItemData","index"]))]))),128))]),footer:e.withCtx(()=>[e.createElementVNode("div",n2,[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"])])}}},o2=Ql._export_sfc(i2,[["__scopeId","data-v-2d9c5ab2"]]),t2={key:0,class:"method-content"},s2={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},setup(a){const l=e.ref([]),n=te.useOriginalState(A.pinia),{originalPath:r}=A.storeToRefs(n),i=a,s=e.ref(!1),h=e.ref(),c=te.useTableComp(A.pinia),{multipleTableConst:d}=A.storeToRefs(c),m=A.useModelComp(A.pinia),g=e.ref(!1),u=A.useMenuState(A.pinia),C=A.useLoginState(A.pinia),{itemData:M,isEdit:k,routeToChildPath:W,tableViewContents:I,lockingPage:j,payloadTypes:L}=A.storeToRefs(m),{activeMenuPath:E,platform:x,childMenu:w}=A.storeToRefs(u),{loginUserInfo:b}=A.storeToRefs(C),S=e.ref(!1),$=async()=>{var fe,N;(fe=l.value)!=null&&fe.find(se=>(se==null?void 0:se.buttonName)==="保存")&&await Y((N=l.value)==null?void 0:N.find(se=>(se==null?void 0:se.buttonName)==="保存")),await te.onSaveBack()};e.watch(()=>M.value,async()=>{k.value==="view"&&!S.value&&await Fe(A.cloneDeep(i.itemData)),S.value=!1},{deep:!0});const V=()=>{s.value=!1,h.value=void 0},le=fe=>fe.map(N=>{const se={};for(const U in N){const _e=N[U];if(U.includes(d.value)){const Ie=U.split(d.value);let je=se;Ie.forEach((na,Ca)=>{Ca===Ie.length-1?je[na]=_e:(je[na]||(je[na]={}),je=je[na])})}else se[U]=_e}return se}),X=async(fe,N,se=[])=>{var _e,Ie,je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja;let U=(_e=A.cloneDeep(N))==null?void 0:_e.filter(R=>(R==null?void 0:R.comp)!=="methodButton");if(fe!=null&&fe.includes("[")){let R=(ee=(Ca=(na=(je=(Ie=A.cloneDeep(fe))==null?void 0:Ie.split("["))==null?void 0:je[1])==null?void 0:na.split("]"))==null?void 0:Ca[0])==null?void 0:ee.split(":"),H="";if(R!=null&&R[0]){let J=(ca=U==null?void 0:U.find(he=>(he==null?void 0:he.name)===(R==null?void 0:R[0])))==null?void 0:ca.compData;if(!J){let he=(de=fe==null?void 0:fe.split("["))==null?void 0:de[0],pe=await te.getItemData(he,sessionStorage.getItem("systemKey"),"",!1,"","",se);J=(pa=pe==null?void 0:pe.find(ha=>(ha==null?void 0:ha.name)===(R==null?void 0:R[0])))==null?void 0:pa.compData}J==null||J.forEach(he=>{var pe,ha,ta,He,_a,ze;if((he==null?void 0:he.key)==="formContent")(pe=he==null?void 0:he.contents)==null||pe.forEach(ma=>{var Oa;(ma==null?void 0:ma.key)===(R==null?void 0:R[1])&&(Array.isArray(ma==null?void 0:ma.value)?H=ma==null?void 0:ma.value:H=(Oa=ma==null?void 0:ma.value)==null?void 0:Oa.toString())});else if((he==null?void 0:he.key)==="tableContents"){let ma=[],Oa=(ha=J==null?void 0:J.find(fa=>(fa==null?void 0:fa.key)==="header"))==null?void 0:ha.contents,Ma=(R==null?void 0:R[1])??"";if(Oa!=null&&Oa.every(fa=>Array.isArray(fa))){let fa=te.getColumnChild((_a=Oa==null?void 0:Oa[0])==null?void 0:_a.filter(Ba=>(Ba==null?void 0:Ba.label)!=="操作"));(ze=he.contents)==null||ze.forEach(Ba=>{let Te={};Ba=Ba==null?void 0:Ba.filter(ye=>!(ye!=null&&ye.id)),fa==null||fa.forEach((ye,Ne)=>{let ae=Ba[Ne];typeof Ba[Ne]=="number"&&(ae=Ba[Ne].toString()),(Ma===""||Ma===ye.prop)&&(Te[ye.prop]=ae)}),ma.push(Te)}),ma=le(ma)}else{let fa=(ta=Oa==null?void 0:Oa.map(Ba=>Ba==null?void 0:Ba.label))==null?void 0:ta.filter(Ba=>Ba!=="操作");(He=he.contents)==null||He.forEach(Ba=>{let Te={};Ba=Ba==null?void 0:Ba.filter(ye=>!(ye!=null&&ye.id)),fa==null||fa.forEach((ye,Ne)=>{let ae=Ba[Ne];typeof Ba[Ne]=="number"&&(ae=Ba[Ne].toString()),(Ma===""||Ma===ye)&&(Te[ye]=ae)}),ma.push(Te)})}H=ma}})}return H}else if(fe!=null&&fe.includes("/")){let R={};return(we=A.cloneDeep(U))==null||we.forEach((H,J)=>{var he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae,oe,Xe,Ze;if((H==null?void 0:H.comp)==="Table"){let Pa=Array.isArray((ha=(pe=(he=H==null?void 0:H.compData)==null?void 0:he.find(Re=>(Re==null?void 0:Re.key)==="header"))==null?void 0:pe.contents)==null?void 0:ha[0])?(ze=(_a=(He=(ta=H==null?void 0:H.compData)==null?void 0:ta.find(Re=>(Re==null?void 0:Re.key)==="header"))==null?void 0:He.contents)==null?void 0:_a[0])==null?void 0:ze.some(Re=>Re==null?void 0:Re.children):[],Sa=(Ma=(Oa=(ma=H==null?void 0:H.compData)==null?void 0:ma.find(Re=>(Re==null?void 0:Re.key)==="tableContents"))==null?void 0:Oa.contents)==null?void 0:Ma.map(Re=>(Re!=null&&Re.find(We=>We==null?void 0:We.id)&&(Re=Re.slice(1)),Re)),Xa=(Ne=(ye=(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:ye[0])==null?void 0:Ne.label,Ve=(oe=(ae=H==null?void 0:H.compData)==null?void 0:ae.find(Re=>(Re==null?void 0:Re.key)==="header"))==null?void 0:oe.contents;if(Pa)(Pa==null?void 0:Pa.length)===0?R[H.name]=R!=null&&R[H.name]?R[H.name]:te.tableToForm(Sa,Ve):R[Xa]=te.tableToForm(Sa,Ve);else{const Re=[];Ve=Ve.slice(1,Ve.length-1),Ve==null||Ve.forEach((We,Ae)=>{Sa==null||Sa.forEach(Me=>{Re.push({key:We.label+Me[0],value:Me[Ae+1]})})}),R["form"+J]=Re}}else{const Pa=(Ze=(Xe=H.compData)==null?void 0:Xe.find(Xa=>(Xa==null?void 0:Xa.key)==="formContent"))==null?void 0:Ze.contents;R!=null&&R.form||(R.form=[]);const Sa=[];Pa==null||Pa.forEach(Xa=>{Xa.key!==""&&(Xa={key:(Xa==null?void 0:Xa.key)??(Xa==null?void 0:Xa.label),value:Xa==null?void 0:Xa.value},Sa.push(Xa))}),R.form=[...Sa,...A.cloneDeep(R==null?void 0:R.form)]}}),R}else{if(fe==="createInsofDataApi"){let R=(ue=A.cloneDeep(N))==null?void 0:ue[0];return R={comp:(De=A.cloneDeep(R))==null?void 0:De.comp,compData:(Ge=A.cloneDeep(R))==null?void 0:Ge.compData,name:(ua=A.cloneDeep(R))==null?void 0:ua.name,isShow:(Ja=A.cloneDeep(R))==null?void 0:Ja.isShow},{key:{type:"structure",systemKey:sessionStorage.getItem("systemKey"),parentTable:"",pageKey:E.value},value:{pageData:R}}}return fe}},me=async(fe,N,se)=>{var Ie,je,na;let U=await te.getItemData(N,sessionStorage.getItem("systemKey"),""),_e=U==null?void 0:U.find(Ca=>(Ca==null?void 0:Ca.name)===(se==null?void 0:se[0]));if(_e){if((_e==null?void 0:_e.comp)==="Table"){let Ca={};for(let De in A.cloneDeep(fe))A.cloneDeep(fe)[De]!=="loginUser"?Ca[De]=A.cloneDeep(fe)[De]:Ca[De]=((Ie=b.value)==null?void 0:Ie.account)||((je=b.value)==null?void 0:je.账号);let ee=[],ca=Ca;Array.isArray(fe)||(ca=[Ca]),ca==null||ca.forEach(De=>{ee.push({[De[se[1]]]:De})});let de=[],pa=ee==null?void 0:ee.map(De=>{var Ge;return(Ge=Object.keys(De))==null?void 0:Ge[0]});U==null||U.forEach(De=>{var Ge;(De==null?void 0:De.name)===(se==null?void 0:se[0])&&((Ge=De==null?void 0:De.compData)==null||Ge.forEach(ua=>{var Ja;(ua==null?void 0:ua.key)==="tableContents"&&((Ja=ua==null?void 0:ua.contents)==null||Ja.forEach(R=>{R!=null&&R.some(H=>pa.includes(H))&&de.push({[R.find(H=>H.id).id]:R.find(H=>pa.includes(H))})}))}))});let we=de==null?void 0:de.map(De=>{var Ge;return(Ge=Object.keys(De))==null?void 0:Ge[0]}),ue=[];if(we==null||we.forEach(De=>{var Ja;let Ge=(Ja=de==null?void 0:de.find(R=>{var H;return((H=Object.keys(R))==null?void 0:H[0].toString())===De.toString()}))==null?void 0:Ja[De],ua=ee==null?void 0:ee.find(R=>{var H;return((H=Object.keys(R))==null?void 0:H[0])===Ge});ue.push({id:parseInt(De),value:{tableData:ua[Ge]}})}),(ue==null?void 0:ue.length)>0)return ue}else if((_e==null?void 0:_e.comp)==="Form"){let Ca=A.cloneDeep(_e);Ca.compData=(na=Ca.compData)==null?void 0:na.map(de=>{var pa;return(de==null?void 0:de.key)==="formContent"&&(de.contents=(pa=de.contents)==null?void 0:pa.map(we=>((we==null?void 0:we.key)===(se==null?void 0:se[1])&&(we.value=(fe==null?void 0:fe[we==null?void 0:we.prop])||fe),we))),de});let ee={};for(let de in Ca)de!=="id"&&(ee[de]=Ca[de]);let ca=[];if(ca.push({id:_e==null?void 0:_e.id,keyType:se==null?void 0:se[1],value:{pageData:ee}}),(ca==null?void 0:ca.length)>0)return ca}}},Be=async(fe,N,se)=>{var Ie,je,na,Ca,ee,ca,de,pa,we,ue;let U=await te.getItemData(N,sessionStorage.getItem("systemKey"),""),_e=U==null?void 0:U.find(De=>(De==null?void 0:De.name)===(se==null?void 0:se[0]));if(_e){if((_e==null?void 0:_e.comp)==="Table"){let De={};for(let Ge in A.cloneDeep(fe))A.cloneDeep(fe)[Ge]!=="loginUser"?De[Ge]=A.cloneDeep(fe)[Ge]:De[Ge]=((Ie=b.value)==null?void 0:Ie.account)||((je=b.value)==null?void 0:je.账号);await Rr.createInsofDataApi({key:{type:"data",pageKey:N,tableId:_e==null?void 0:_e.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:De}})}else if((_e==null?void 0:_e.comp)==="Form"){let De=A.cloneDeep(_e),Ge=Object.keys(fe),ua="";(Ca=(na=A.cloneDeep(De))==null?void 0:na.compData)==null||Ca.forEach(pe=>{var ha,ta;(pe==null?void 0:pe.key)==="formContent"&&((ta=(ha=A.cloneDeep(pe))==null?void 0:ha.contents)==null||ta.forEach(He=>{var _a;Ge.includes(He==null?void 0:He.key)&&(He==null?void 0:He.value)===((_a=b.value)==null?void 0:_a.姓名)&&(ua=He==null?void 0:He.key)}))});let Ja=[];(ee=Object.values(fe[ua]))==null||ee.forEach(pe=>{pe!=null&&pe.includes("(")&&Ja.push(pe)}),Ja=[...new Set(Ja)];const R=Ja==null?void 0:Ja.map(async pe=>{var ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae,oe,Xe;let ha="";(Ba=(fa=(Ma=(Oa=(ma=(ze=A.cloneDeep(pe))==null?void 0:ze.split("("))==null?void 0:ma[1])==null?void 0:Oa.split(")"))==null?void 0:Ma[0])==null?void 0:fa.split(":"))==null||Ba.forEach(Ze=>{ha=ha===""?ha+Ze.replaceAll("'",""):ha+"/"+Ze.replaceAll("'","")});let ta=[];(Xe=(oe=(ae=(Ne=(ye=(Te=A.cloneDeep(pe))==null?void 0:Te.split("<"))==null?void 0:ye[1])==null?void 0:Ne.split(">"))==null?void 0:ae[0])==null?void 0:oe.split(":"))==null||Xe.forEach(Ze=>{ta.push(Ze.replaceAll("'",""))});const He=await te.getItemData(ha,sessionStorage.getItem("systemKey"),"");let _a="";return He==null||He.forEach(Ze=>{var Pa;Ze.name===(ta==null?void 0:ta[0])&&((Pa=Ze==null?void 0:Ze.compData)==null||Pa.forEach(Sa=>{var Xa;(Sa==null?void 0:Sa.key)==="formContent"&&((Xa=Sa.contents)==null||Xa.forEach(Ve=>{(Ve==null?void 0:Ve.key)===(ta==null?void 0:ta[1])&&(_a=Ve==null?void 0:Ve.value)}))}))}),{[pe]:_a}}),H=await Promise.all(R);De.compData=(de=(ca=A.cloneDeep(De))==null?void 0:ca.compData)==null?void 0:de.map(pe=>{var ha,ta;return(pe==null?void 0:pe.key)==="formContent"&&(pe.contents=(ta=(ha=A.cloneDeep(pe))==null?void 0:ha.contents)==null?void 0:ta.map(He=>{var _a,ze,ma,Oa;return(_a=fe[ua])!=null&&_a[He==null?void 0:He.key]&&(fe[ua][He==null?void 0:He.key].includes("(")?He.value=(ze=H==null?void 0:H.find(Ma=>{var fa;return((fa=Object.keys(Ma))==null?void 0:fa[0])===fe[ua][He==null?void 0:He.key]}))==null?void 0:ze[fe[ua][He==null?void 0:He.key]]:He.value=(Oa=(ma=A.cloneDeep(fe))==null?void 0:ma[ua])==null?void 0:Oa[He==null?void 0:He.key]),He})),pe});const J=await Rr.getInsofDataApi({key:{type:"structure",pageKey:N,systemKey:sessionStorage.getItem("systemKey")}});let he="";((pa=J==null?void 0:J.data)==null?void 0:pa.type)==="success"&&((ue=(we=J==null?void 0:J.data)==null?void 0:we.result)==null||ue.forEach(pe=>{var ha,ta;((ta=(ha=pe==null?void 0:pe.value)==null?void 0:ha.pageData)==null?void 0:ta.name)===(se==null?void 0:se[0])&&(he=pe.id)}),await Rr.updateInsofDataApi({id:he,value:{pageData:De}}))}}},F=(fe,N="",se={})=>{for(const[U,_e]of Object.entries(fe)){const Ie=N?`${N}.${U}`:U;_e!==null&&typeof _e=="object"&&!Array.isArray(_e)&&Object.prototype.toString.call(_e)!=="[object Date]"?F(_e,Ie,se):se[Ie]=_e}return se},ie=async(fe,N,se,U)=>{var je,na,Ca,ee,ca,de,pa,we,ue,De,Ge,ua,Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa;let _e=await te.getItemData(N,sessionStorage.getItem("systemKey"),""),Ie=_e==null?void 0:_e.find(Ma=>(Ma==null?void 0:Ma.name)===(se==null?void 0:se[0]));if(Ie){if(!(se!=null&&se[1])&&(Ie==null?void 0:Ie.comp)==="Table"){let Ma={},fa=[],Ba=(na=(je=Ie==null?void 0:Ie.compData)==null?void 0:je.find(Ne=>(Ne==null?void 0:Ne.key)==="header"))==null?void 0:na.contents;Ba!=null&&Ba.every(Ne=>Array.isArray(Ne))?fa=(ee=te.getColumnChild((Ca=Ba==null?void 0:Ba[0])==null?void 0:Ca.filter(Ne=>(Ne==null?void 0:Ne.label)!=="操作")))==null?void 0:ee.map(Ne=>Ne==null?void 0:Ne.prop):fa=Ba==null?void 0:Ba.map(Ne=>Ne==null?void 0:Ne.label);for(let Ne in A.cloneDeep(fe))if(A.cloneDeep(fe)[Ne]!=="loginUser"){let ae=F(A.cloneDeep(fe)[Ne]),oe={};for(let Xe in ae)if(fa!=null&&fa.find(Ze=>Ze===Xe))oe[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(Pa=>(Pa==null?void 0:Pa.toUpperCase())===(Xe==null?void 0:Xe.toUpperCase()));oe[Ze]=ae[Xe]}Ma[Ne]=oe}else Ma[Ne]=((ca=b.value)==null?void 0:ca.account)||((de=b.value)==null?void 0:de.账号);let Te=await Rr.getInsofDataApi({keyLikes:{tableId:Ie==null?void 0:Ie.id}});if(((we=(pa=Te==null?void 0:Te.data)==null?void 0:pa.result)==null?void 0:we.length)>0){let Ne=(De=(ue=Te==null?void 0:Te.data)==null?void 0:ue.result)==null?void 0:De.map(ae=>ae==null?void 0:ae.id);(Ne==null?void 0:Ne.length)>0&&await Rr.batchDeleteInsofDataApi({ids:Ne})}let ye=[];if((Ge=Ie==null?void 0:Ie.compData)!=null&&Ge.find(Ne=>(Ne==null?void 0:Ne.key)==="pageColumn")&&((R=(Ja=(ua=Ie==null?void 0:Ie.compData)==null?void 0:ua.find(Ne=>(Ne==null?void 0:Ne.key)==="pageColumn"))==null?void 0:Ja.contents)!=null&&R.includes("["))){const Ne=await Rr.getInsofDataApi({id:Ie==null?void 0:Ie.tableId});let ae=((pe=(he=(J=(H=Ne==null?void 0:Ne.data)==null?void 0:H.result)==null?void 0:J[0])==null?void 0:he.key)==null?void 0:pe.pageKey)??"";(ha=Object.values(Ma))==null||ha.forEach(oe=>{ye.push({key:{type:"data",pageKey:ae,tableId:Ie==null?void 0:Ie.tableId,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:oe}})})}else(ta=Object.values(Ma))==null||ta.forEach(Ne=>{ye.push({key:{type:"data",pageKey:N,tableId:Ie==null?void 0:Ie.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Ne}})});(ye==null?void 0:ye.length)>0&&await Rr.batchAddInsofDataApi({dataList:ye})}else if(!(se!=null&&se[1])&&(Ie==null?void 0:Ie.comp)==="Form"){let Ma=A.cloneDeep(Ie);Ma.compData=(_a=(He=A.cloneDeep(Ma))==null?void 0:He.compData)==null?void 0:_a.map(Te=>{var ye,Ne;return(Te==null?void 0:Te.key)==="formContent"&&(Te.contents=(Ne=(ye=A.cloneDeep(Te))==null?void 0:ye.contents)==null?void 0:Ne.map(ae=>{var oe,Xe;return(oe=A.cloneDeep(fe))!=null&&oe[ae==null?void 0:ae.key]&&(ae.value=(Xe=A.cloneDeep(fe))==null?void 0:Xe[ae==null?void 0:ae.key]),ae})),Te});const fa=await Rr.getInsofDataApi({key:{type:"structure",pageKey:N,systemKey:sessionStorage.getItem("systemKey")}});let Ba="";((ze=fa==null?void 0:fa.data)==null?void 0:ze.type)==="success"&&((Oa=(ma=fa==null?void 0:fa.data)==null?void 0:ma.result)==null||Oa.forEach(Te=>{var ye,Ne;((Ne=(ye=Te==null?void 0:Te.value)==null?void 0:ye.pageData)==null?void 0:Ne.name)===(se==null?void 0:se[0])&&(Ba=Te.id)}),await Rr.updateInsofDataApi({id:Ba,value:{pageData:Ma}}))}}},Y=async fe=>{var N,se,U,_e,Ie,je,na,Ca,ee,ca,de,pa,we,ue;u.setImportLoading(!0);try{if(fe.api){let De=new WeakMap,Ge=await te.getItemData((w==null?void 0:w.value)===""?E.value:w==null?void 0:w.value,sessionStorage.getItem("systemKey"),"",!1,"","",De),ua="";if(Ge=Ge==null?void 0:Ge.map(ta=>{var He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae;if((ta==null?void 0:ta.comp)==="Form")ta.compData=(He=ta.compData)==null?void 0:He.map(oe=>{var Xe;return(oe==null?void 0:oe.key)==="formContent"&&(oe.contents=(Xe=oe.contents)==null?void 0:Xe.map(Ze=>{var Pa;if((Ze==null?void 0:Ze.value)===""&&(Ze==null?void 0:Ze.type)==="Select"){let Sa=te.judgeContents((Pa=A.cloneDeep(Ze))==null?void 0:Pa.optionUrl,De);Ze.value=Ze.value||Sa}return Ze})),oe});else if((ta==null?void 0:ta.comp)==="Table"&&(_a=ta.compData)!=null&&_a.find(oe=>(oe==null?void 0:oe.key)==="pageColumn")){let oe=(ma=(ze=ta.compData)==null?void 0:ze.find(Sa=>(Sa==null?void 0:Sa.key)==="pageColumn"))==null?void 0:ma.contents,Xe=((Ma=(Oa=ta.compData)==null?void 0:Oa.find(Sa=>(Sa==null?void 0:Sa.key)==="pageGroup"))==null?void 0:Ma.contents)??"",Ze=(Te=(Ba=(fa=oe==null?void 0:oe.split("["))==null?void 0:fa[1])==null?void 0:Ba.split("]"))==null?void 0:Te[0];ua=((ye=oe==null?void 0:oe.split("["))==null?void 0:ye[0])+((ae=(Ne=I.value)==null?void 0:Ne.find(Sa=>(Sa==null?void 0:Sa.key)===Ze))==null?void 0:ae.value)}return ta}),!(ua===""||ua==="")){const ta=await te.getItemData(ua,sessionStorage.getItem("systemKey"),"",!1,"","",De);Ge=Ge==null?void 0:Ge.map(He=>{var _a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae,oe,Xe;if((He==null?void 0:He.comp)==="Table"&&(_a=He.compData)!=null&&_a.find(Ze=>(Ze==null?void 0:Ze.key)==="pageColumn")){let Ze=(ma=(ze=He.compData)==null?void 0:ze.find(Re=>(Re==null?void 0:Re.key)==="pageColumn"))==null?void 0:ma.contents,Pa=((Ma=(Oa=He.compData)==null?void 0:Oa.find(Re=>(Re==null?void 0:Re.key)==="pageGroup"))==null?void 0:Ma.contents)??"",Sa=(Te=(Ba=(fa=Ze==null?void 0:Ze.split("["))==null?void 0:fa[1])==null?void 0:Ba.split("]"))==null?void 0:Te[0],Xa=((ye=Ze==null?void 0:Ze.split("["))==null?void 0:ye[0])+((ae=(Ne=I.value)==null?void 0:Ne.find(Re=>(Re==null?void 0:Re.key)===Sa))==null?void 0:ae.value),Ve=(oe=ta==null?void 0:ta.find(Re=>(Re==null?void 0:Re.name)===(Pa===""?i==null?void 0:i.compName:Pa)))==null?void 0:oe.compData;He.compData=(Xe=He.compData)==null?void 0:Xe.map(Re=>{var We;return(Re==null?void 0:Re.key)==="tableContents"&&(Re.contents=(We=Ve==null?void 0:Ve.find(Ae=>(Ae==null?void 0:Ae.key)==="tableContents"))==null?void 0:We.contents),Re})}return He})}let Ja={};if(((se=(N=fe==null?void 0:fe.extraValues)==null?void 0:N.input)==null?void 0:se.length)>0){const ta=(_e=(U=fe==null?void 0:fe.extraValues)==null?void 0:U.input)==null?void 0:_e.map(async He=>{var _a;ce!=null&&ce.find(ze=>ze===He)?Ja=await X(He,Ge):Ja[Object.keys(He)[0]]=await X((_a=Object.values(He))==null?void 0:_a[0],Ge,De)});await Promise.all(ta)}else Ja=await X("/",Ge);let R=!1;(je=(Ie=fe==null?void 0:fe.extraValues)==null?void 0:Ie.output)==null||je.forEach(ta=>{var He,_a;(_a=(He=Object.values(ta))==null?void 0:He[0])!=null&&_a.includes(".doc")&&(R=!0)});let H;if(R){const ta=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});H=await ja.axios.post(fe.api,Ja,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{ta.close()})}else H=await ja.axios.post(fe.api,Ja,{headers:{"Content-Type":"application/json"}});let J=(ca=(ee=(Ca=(na=A.cloneDeep(fe))==null?void 0:na.extraValues)==null?void 0:Ca.output)==null?void 0:ee.map(ta=>{var He,_a,ze,ma,Oa,Ma,fa,Ba,Te,ye,Ne,ae,oe,Xe,Ze,Pa;if(!((_a=(He=Object.values(ta))==null?void 0:He[0])!=null&&_a.includes(".doc"))){let Sa=(ye=(Te=(Ba=(ma=A.cloneDeep((ze=Object.values(ta))==null?void 0:ze[0]))==null?void 0:ma.split("["))==null?void 0:Ba[((fa=(Ma=A.cloneDeep((Oa=Object.values(ta))==null?void 0:Oa[0]))==null?void 0:Ma.split("["))==null?void 0:fa.length)-1])==null?void 0:Te.split("]"))==null?void 0:ye[0],Xa=Sa==null?void 0:Sa.split(":"),Ve=(oe=A.cloneDeep((Ne=Object.values(ta))==null?void 0:Ne[0]))==null?void 0:oe.substring(0,A.cloneDeep((ae=Object.values(ta))==null?void 0:ae[0]).lastIndexOf("["));if(Ve=(Ze=A.cloneDeep(Ve))==null?void 0:Ze.slice(0,((Xe=A.cloneDeep(Ve))==null?void 0:Xe.length)-1),Ve!=null&&Ve.includes("[")){let Re="";if((Pa=te.contentTransArrayToAll(Ve,"/"))==null||Pa.forEach(We=>{var Ae,Me,cl,wl,Cl,Pl,Sl;if(!(We!=null&&We.includes("[")))Re=Re===""?Re+We.replaceAll("/",""):Re+"/"+We.replaceAll("/","");else{let Gl=A.cloneDeep(We).slice(1,((Ae=A.cloneDeep(We))==null?void 0:Ae.length)-1),aa=(Pl=(Cl=(wl=(cl=(Me=A.cloneDeep(Gl))==null?void 0:Me.split("["))==null?void 0:cl[1])==null?void 0:wl.split("]"))==null?void 0:Cl[0])==null?void 0:Pl.split(":"),Ha="",ya=(Sl=Ge==null?void 0:Ge.find(rl=>(rl==null?void 0:rl.name)===(aa==null?void 0:aa[0])))==null?void 0:Sl.compData;ya==null||ya.forEach(rl=>{var Aa;(rl==null?void 0:rl.key)==="formContent"&&((Aa=rl==null?void 0:rl.contents)==null||Aa.forEach(ol=>{(ol==null?void 0:ol.key)===(aa==null?void 0:aa[1])&&(Ha=ol==null?void 0:ol.value)}))}),Re=Re===""?Re+Ha.replaceAll("/",""):Re+"/"+Ha.replaceAll("/","")}}),Ve=Re,Ve[(Ve==null?void 0:Ve.length)-1]!=="/")return Ve}}}))==null?void 0:ca.filter(ta=>ta);J=[...new Set(A.cloneDeep(J))];let he=J==null?void 0:J.map(async ta=>{let He=await te.getItemData(ta,sessionStorage.getItem("systemKey"),"",!1,"","",De);if((He==null?void 0:He.length)===0)return await te.getParentContents(ta)});await Promise.all(he);let pe=[],ha=(we=(pa=(de=A.cloneDeep(fe))==null?void 0:de.extraValues)==null?void 0:pa.output)==null?void 0:we.map(async ta=>{var Ba,Te,ye,Ne,ae,oe,Xe,Ze,Pa,Sa,Xa,Ve,Re,We,Ae,Me,cl,wl,Cl,Pl,Sl,Gl,aa,Ha,ya,rl,Aa,ol,al,ke,Ia,$a,Z,la,ba,Ke,Ua,ga,tl,Le,ia,va,ll,Pe,Dl,Wa,ml,nr,_r,jl,pr,Sr,Cr,Oe,er,gr,Dr,Bl,$r,Ur,Hl,yr,vn,hr,Al,sn,jr,qr,Kr,Jr;if((Te=(Ba=Object.values(ta))==null?void 0:Ba[0])!=null&&Te.includes(".doc")){var He=new Blob([H.data],{type:"application/octet-stream;charset=UTF-8"}),_a=H.headers["content-disposition"],ze=new RegExp("filename=([^;]+\\.[^\\.;]+);*"),ma=ze.exec(_a),Oa=ma==null?void 0:ma[1],Ma=document.createElement("a"),fa=window.URL.createObjectURL(He);h.value=[{name:Oa,blobUrl:fa}],s.value=!0}else{let Wr=(Sa=(Pa=(Ze=(Ne=A.cloneDeep((ye=Object.values(ta))==null?void 0:ye[0]))==null?void 0:Ne.split("["))==null?void 0:Ze[((Xe=(oe=A.cloneDeep((ae=Object.values(ta))==null?void 0:ae[0]))==null?void 0:oe.split("["))==null?void 0:Xe.length)-1])==null?void 0:Pa.split("]"))==null?void 0:Sa[0],ar=Wr==null?void 0:Wr.split(":"),lr=(Re=A.cloneDeep((Xa=Object.values(ta))==null?void 0:Xa[0]))==null?void 0:Re.substring(0,A.cloneDeep((Ve=Object.values(ta))==null?void 0:Ve[0]).lastIndexOf("["));if(lr!=null&&lr.includes("[")?lr=(Ae=A.cloneDeep(lr))==null?void 0:Ae.slice(0,((We=A.cloneDeep(lr))==null?void 0:We.length)-1):lr===""&&(lr=E.value),lr=lr.replaceAll("<","[").replaceAll(">","]"),lr!=null&&lr.includes("[")){let hl="";(Me=te.contentTransArrayToAll(lr,"/"))==null||Me.forEach((ir,Vl)=>{var Er,ql,fr,Vr,br,cn,Zr,Jn,Fn,Dn,In;if(!(ir!=null&&ir.includes("[")))hl=hl===""?hl+ir.replaceAll("/",""):hl+"/"+ir.replaceAll("/","");else{let jn="",mn="";(Er=A.cloneDeep(ir))!=null&&Er.includes("]")?(jn=A.cloneDeep(ir).slice(1,((ql=A.cloneDeep(ir))==null?void 0:ql.length)-1),mn=(Zr=(cn=(br=(Vr=(fr=A.cloneDeep(jn))==null?void 0:fr.split("["))==null?void 0:Vr[1])==null?void 0:br.split("]"))==null?void 0:cn[0])==null?void 0:Zr.split(":")):(jn=A.cloneDeep(ir).slice(1,(Jn=A.cloneDeep(ir))==null?void 0:Jn.length),mn=(Fn=A.cloneDeep(jn))==null?void 0:Fn.split("/"));let On="",Xn=(Dn=Ge==null?void 0:Ge.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=te.contentTransArrayToAll(lr,"/"))==null?void 0:In.length)-1!==Vl?hl=hl===""?hl+On.replaceAll("/",""):hl+"/"+On.replaceAll("/",""):hl=hl+r.value+On.replaceAll("/","")}}),(cl=E.value)!=null&&cl.includes(hl)?lr=E.value:lr=hl}let Xr=A.cloneDeep((wl=Object.keys(ta))==null?void 0:wl[0]);if(((Cl=H==null?void 0:H.data)==null?void 0:Cl.statusCode)===200||((Pl=H==null?void 0:H.data)==null?void 0:Pl.code)===200){if(((Gl=(Sl=H==null?void 0:H.data)==null?void 0:Sl.data)!=null&&Gl[Xr]||(Ha=(aa=H==null?void 0:H.data)==null?void 0:aa.result)!=null&&Ha[Xr])&&(ar==null?void 0:ar.length)===1)return await ie(((rl=(ya=H==null?void 0:H.data)==null?void 0:ya.data)==null?void 0:rl[Xr])||((ol=(Aa=H==null?void 0:H.data)==null?void 0:Aa.result)==null?void 0:ol[Xr]),A.cloneDeep(lr),ar,ua);if((ke=(al=H==null?void 0:H.data)==null?void 0:al.data)!=null&&ke[Xr]||($a=(Ia=H==null?void 0:H.data)==null?void 0:Ia.result)!=null&&$a[Xr]){let hl=await me(((la=(Z=H==null?void 0:H.data)==null?void 0:Z.data)==null?void 0:la[Xr])||((Ke=(ba=H==null?void 0:H.data)==null?void 0:ba.result)==null?void 0:Ke[Xr]),A.cloneDeep(lr),ar);return hl&&(pe=[...pe,...hl]),hl}else{if(!((Ua=H==null?void 0:H.data)!=null&&Ua.data)){let hl=await te.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,"","",De);hl=hl==null?void 0:hl.map(Vl=>{var Er;return(Vl==null?void 0:Vl.name)===(ar==null?void 0:ar[0])&&(Vl.compData=(Er=Vl.compData)==null?void 0:Er.map(ql=>{var fr;return(ql==null?void 0:ql.key)==="formContent"&&(ql.contents=(fr=ql.contents)==null?void 0:fr.map(Vr=>{var br,cn;return(Vr==null?void 0:Vr.key)===(ar==null?void 0:ar[1])&&(Vr.value=(cn=(br=H==null?void 0:H.data)==null?void 0:br.result)==null?void 0:cn[Xr==null?void 0:Xr.replaceAll(":","")]),Vr})),ql})),Vl});let ir=[];(ga=hl==null?void 0:hl.filter(Vl=>(Vl==null?void 0:Vl.comp)==="Form"))==null||ga.forEach(async Vl=>{let Er={};for(let ql in Vl)ql!=="id"&&(Er[ql]=Vl[ql]);ir.push({id:Vl==null?void 0:Vl.id,value:{pageData:Er}})}),(ir==null?void 0:ir.length)>0&&await Rr.batchUpdateInsofDataApi({dataList:ir});return}if((ar==null?void 0:ar.length)===1){const hl=(ia=(Le=(tl=H==null?void 0:H.data)==null?void 0:tl.data)==null?void 0:Le.path)==null?void 0:ia.path;let ir="";(Wa=(Dl=(Pe=(ll=(va=hl==null?void 0:hl.split("("))==null?void 0:va[1])==null?void 0:ll.split(")"))==null?void 0:Pe[0])==null?void 0:Dl.split(":"))==null||Wa.forEach(ql=>{var fr,Vr;ir=ir===""?ir+((fr=ql==null?void 0:ql.replaceAll("'",""))==null?void 0:fr.trim()):ir+"/"+((Vr=ql==null?void 0:ql.replaceAll("'",""))==null?void 0:Vr.trim())});let Vl=[(pr=(jl=(_r=(nr=(ml=hl==null?void 0:hl.split("<"))==null?void 0:ml[1])==null?void 0:nr.split(">"))==null?void 0:_r[0])==null?void 0:jl.replaceAll("'",""))==null?void 0:pr.trim()],Er;return(Oe=(Cr=(Sr=H==null?void 0:H.data)==null?void 0:Sr.data)==null?void 0:Cr.data)!=null&&Oe[ar==null?void 0:ar[0]]?Er=await ie((Dr=(gr=(er=H==null?void 0:H.data)==null?void 0:er.data)==null?void 0:gr.data)==null?void 0:Dr[ar==null?void 0:ar[0]],ir,ar,ua):Er=await Be(($r=(Bl=H==null?void 0:H.data)==null?void 0:Bl.data)==null?void 0:$r.data,ir,Vl,De),Er}else{const hl=(yr=(Hl=(Ur=H==null?void 0:H.data)==null?void 0:Ur.data)==null?void 0:Hl.path)==null?void 0:yr.path;let ir="";return(jr=(sn=(Al=(hr=(vn=hl==null?void 0:hl.split("("))==null?void 0:vn[1])==null?void 0:hr.split(")"))==null?void 0:Al[0])==null?void 0:sn.split(":"))==null||jr.forEach(Er=>{var ql,fr;ir=ir===""?ir+((ql=Er==null?void 0:Er.replaceAll("'",""))==null?void 0:ql.trim()):ir+"/"+((fr=Er==null?void 0:Er.replaceAll("'",""))==null?void 0:fr.trim())}),await me((Jr=(Kr=(qr=H==null?void 0:H.data)==null?void 0:qr.data)==null?void 0:Kr.data)==null?void 0:Jr[ar==null?void 0:ar[0]],ir,ar)}}}}});if(await Promise.all(ha),(pe==null?void 0:pe.length)>0){let ta=[];pe==null||pe.forEach(ze=>{ta!=null&&ta.find(ma=>{var Oa,Ma,fa,Ba;return((Ma=(Oa=ma==null?void 0:ma.value)==null?void 0:Oa.pageData)==null?void 0:Ma.name)===((Ba=(fa=ze==null?void 0:ze.value)==null?void 0:fa.pageData)==null?void 0:Ba.name)})||ta.push(ze)});let He=[];ta==null||ta.forEach(ze=>{var Ma,fa,Ba,Te;let ma=A.cloneDeep(ze);ma.value.pageData.compData=(Ma=ma.value.pageData.compData)==null?void 0:Ma.map(ye=>{var Ne;return(ye==null?void 0:ye.key)==="formContent"&&(ye.contents=(Ne=ye.contents)==null?void 0:Ne.map(ae=>{var Xe,Ze,Pa,Sa;let oe=(Xe=A.cloneDeep(pe))==null?void 0:Xe.find(Xa=>(Xa==null?void 0:Xa.keyType)===(ae==null?void 0:ae.key));if(oe){let Xa=(Sa=(Pa=(Ze=oe.value.pageData.compData)==null?void 0:Ze.find(Ve=>(Ve==null?void 0:Ve.key)==="formContent"))==null?void 0:Pa.contents)==null?void 0:Sa.find(Ve=>(Ve==null?void 0:Ve.key)===(ae==null?void 0:ae.key));ae.value=Xa==null?void 0:Xa.value}return ae})),ye}),He.push({id:ma==null?void 0:ma.id,value:ma==null?void 0:ma.value});let Oa=[];(Te=(Ba=(fa=ma==null?void 0:ma.value)==null?void 0:fa.pageData)==null?void 0:Ba.compData)==null||Te.forEach(ye=>{var Ne;(ye==null?void 0:ye.key)==="formContent"&&((Ne=ye==null?void 0:ye.contents)==null||Ne.forEach(ae=>{var oe,Xe,Ze,Pa,Sa,Xa;if((Xe=(oe=ae==null?void 0:ae.optionUrl)==null?void 0:oe.menuSelect)!=null&&Xe.find(Ve=>Ve==null?void 0:Ve.includes("[")))if(Oa!=null&&Oa.find(Ve=>{var Re,We,Ae;return((Re=Ve==null?void 0:Ve.key)==null?void 0:Re.join(","))===((Ae=(We=ae==null?void 0:ae.optionUrl)==null?void 0:We.menuSelect)==null?void 0:Ae.join(","))})){let Ve=(Ze=Oa==null?void 0:Oa.find(Re=>{var We,Ae,Me;return((We=Re==null?void 0:Re.key)==null?void 0:We.join(","))===((Me=(Ae=ae==null?void 0:ae.optionUrl)==null?void 0:Ae.menuSelect)==null?void 0:Me.join(","))}))==null?void 0:Ze.value;Ve.push({key:ae==null?void 0:ae.prop,groups:(Pa=ae==null?void 0:ae.optionUrl)==null?void 0:Pa.groupSelect,value:ae==null?void 0:ae.value}),Oa=Oa==null?void 0:Oa.map(Re=>{var We,Ae,Me;return((We=Re==null?void 0:Re.key)==null?void 0:We.join(","))===((Me=(Ae=ae==null?void 0:ae.optionUrl)==null?void 0:Ae.menuSelect)==null?void 0:Me.join(","))&&(Re.value=Ve),Re})}else Oa.push({key:(Sa=ae==null?void 0:ae.optionUrl)==null?void 0:Sa.menuSelect,value:[{key:ae==null?void 0:ae.prop,groups:(Xa=ae==null?void 0:ae.optionUrl)==null?void 0:Xa.groupSelect,value:ae==null?void 0:ae.value}]})}))}),(Oa==null?void 0:Oa.length)>0&&(Oa=Oa==null?void 0:Oa.map(ye=>{var ae;let Ne="";return(ae=ye==null?void 0:ye.key)==null||ae.forEach(oe=>{var Xe;if(!(oe!=null&&oe.includes("[")))Ne=Ne===""?Ne+oe:Ne+"/"+oe;else{let Ze="",Pa=(Xe=oe==null?void 0:oe.replaceAll("[","").replaceAll("]",""))==null?void 0:Xe.split(":");Ge==null||Ge.forEach(Sa=>{var Xa;(Sa==null?void 0:Sa.name)===(Pa==null?void 0:Pa[0])&&((Xa=Sa==null?void 0:Sa.compData)==null||Xa.forEach(Ve=>{var Re;(Ve==null?void 0:Ve.key)==="formContent"&&((Re=Ve==null?void 0:Ve.contents)==null||Re.forEach(We=>{(We==null?void 0:We.prop)===(Pa==null?void 0:Pa[1])&&(Ze=We==null?void 0:We.value)}))}))}),Ne=Ne+r.value+Ze}}),ye.key=Ne,ye})),Oa==null||Oa.forEach(ye=>{var Xe,Ze,Pa;let Ne=(Xe=De[ye.key])==null?void 0:Xe.find(Sa=>{var Xa,Ve,Re,We,Ae,Me,cl;return((Ve=(Xa=Sa==null?void 0:Sa.value)==null?void 0:Xa.pageData)==null?void 0:Ve.name)===((Ae=(We=(Re=ye==null?void 0:ye.value)==null?void 0:Re[0])==null?void 0:We.groups)==null?void 0:Ae[0])&&((cl=(Me=Sa==null?void 0:Sa.value)==null?void 0:Me.pageData)==null?void 0:cl.name)!==void 0}),ae=Ne==null?void 0:Ne.id,oe=(Ze=Ne==null?void 0:Ne.value)==null?void 0:Ze.pageData;oe.compData=(Pa=oe.compData)==null?void 0:Pa.map(Sa=>{var Xa;return(Sa==null?void 0:Sa.key)==="formContent"&&(Sa.contents=(Xa=Sa.contents)==null?void 0:Xa.map(Ve=>{var We;let Re=(We=ye.value)==null?void 0:We.find(Ae=>(Ae==null?void 0:Ae.key)===(Ve==null?void 0:Ve.prop));return Re&&(Ve.value=Re.value),Ve})),Sa}),He.push({id:ae,value:{pageData:oe}})})});let _a=(ue=A.cloneDeep(pe))==null?void 0:ue[0];(He==null?void 0:He.length)>0&&await Rr.batchUpdateInsofDataApi({dataList:He})}m.setFreshContent(!0)}u.setImportLoading(!1)}catch{ja.ElMessage.error("方法执行错误,请查看方法!"),u.setImportLoading(!1)}S.value=!0},ce=["createInsofDataApi"],Ce=Il.debounce(async fe=>{Y(fe)},100),Fe=async fe=>{var je,na,Ca;const N=A.cloneDeep(fe);let se,U=new WeakMap;fe!=null&&fe[0].path&&(se=await(N==null?void 0:N.map(async(ee,ca)=>{var Ja,R,H,J,he,pe,ha,ta,He,_a,ze,ma,Oa,Ma,fa,Ba;const pa=(Ja=U[ee==null?void 0:ee.path])==null?void 0:Ja.filter(Te=>{var ye;return((ye=Te==null?void 0:Te.key)==null?void 0:ye.type)==="data"});let we="";const ue=await te.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,U);pa==null||pa.forEach(Te=>{var ye,Ne,ae,oe,Xe;((Ne=(ye=Te==null?void 0:Te.value)==null?void 0:ye.tableData)==null?void 0:Ne.算法名称)===((ae=N==null?void 0:N[ca])==null?void 0:ae.method)&&(we=(Xe=(oe=Te==null?void 0:Te.value)==null?void 0:oe.tableData)==null?void 0:Xe.算法体)});const De=await te.getItemData(ee==null?void 0:ee.path,sessionStorage.getItem("systemKey"),"",!1,[],!1,U);let Ge="",ua=(he=(J=(H=(R=De==null?void 0:De[0])==null?void 0:R.compData)==null?void 0:H.find(Te=>(Te==null?void 0:Te.key)==="header"))==null?void 0:J.contents)==null?void 0:he.findIndex(Te=>(Te==null?void 0:Te.prop)==="算法体");return(ha=(pe=De==null?void 0:De[0])==null?void 0:pe.compData)==null||ha.forEach(Te=>{var ye;(Te==null?void 0:Te.key)==="tableContents"&&((ye=Te==null?void 0:Te.contents)==null||ye.forEach(Ne=>{Ne!=null&&Ne.find(ae=>ae===(ee==null?void 0:ee.method))&&(Ge=Ne[ua])}))}),{buttonName:((ta=N==null?void 0:N[ca])==null?void 0:ta.method)||((ze=(_a=(He=pa==null?void 0:pa[0])==null?void 0:He.value)==null?void 0:_a.tableData)==null?void 0:ze.算法名称),api:(we===""?(Ma=(Oa=(ma=pa==null?void 0:pa[0])==null?void 0:ma.value)==null?void 0:Oa.tableData)==null?void 0:Ma.算法体:we)||Ge,content:ue==null?void 0:ue.filter(Te=>Te.comp!=="methodButton"),extraContent:(fa=A.cloneDeep(ee.value))==null?void 0:fa.slice(1),methodName:(ee==null?void 0:ee.path)??"",extraValues:(Ba=N==null?void 0:N[ca])==null?void 0:Ba.data}})));const _e=N==null?void 0:N.map(async ee=>{var De,Ge,ua,Ja,R,H;const ca=(De=resAll.data.result)==null?void 0:De.filter(J=>{var he,pe,ha;return((he=J==null?void 0:J.key)==null?void 0:he.parentTable)===""&&((pe=J==null?void 0:J.key)==null?void 0:pe.type)==="method"&&((ha=J==null?void 0:J.key)==null?void 0:ha.methodName)===J.method}),de=ca==null?void 0:ca[0],pa=(Ge=resAll.data.result)==null?void 0:Ge.filter(J=>{var he,pe;return((he=J==null?void 0:J.key)==null?void 0:he.type)==="methodData"&&((pe=J==null?void 0:J.key)==null?void 0:pe.tableId)===(de==null?void 0:de.id)}),we=await te.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,U),ue=pa==null?void 0:pa[0];return{buttonName:(ua=de==null?void 0:de.key)==null?void 0:ua.methodKey,api:(R=(Ja=ue==null?void 0:ue.value)==null?void 0:Ja.tableData)==null?void 0:R[0],content:we==null?void 0:we.filter(J=>J.comp!=="methodButton"),extraContent:(H=A.cloneDeep(ee.value))==null?void 0:H.slice(1),methodName:(ee==null?void 0:ee.method)??""}}),Ie=(je=fe==null?void 0:fe[0])!=null&&je.path&&((na=fe==null?void 0:fe[0])==null?void 0:na.path)!==""?await Promise.all(se):await Promise.all(_e);l.value=Ie==null?void 0:Ie.filter(ee=>ee==null?void 0:ee.extraContent),(Ca=l.value)==null||Ca.forEach(ee=>{var ca;ee.api===""&&((ca=ee.content)==null||ca.forEach(de=>{var pa;de.comp=="Table"&&m.setExtraContents(te.methodTableToContent(de.compData,(pa=ee.extraContent)==null?void 0:pa[0]))}))})};return e.watch(()=>i.itemData,async()=>{k.value=="view"&&!S.value&&await Fe(A.cloneDeep(i.itemData)),S.value=!1},{immediate:!0,deep:!0}),(fe,N)=>{var se,U,_e;return e.unref(k)!=="edit"?(e.openBlock(),e.createElementBlock("div",t2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((se=l.value)==null?void 0:se.filter(Ie=>(Ie==null?void 0:Ie.buttonName)!=="保存"),Ie=>{var je;return e.openBlock(),e.createElementBlock("div",null,[Ie.api!==""?(e.openBlock(),e.createBlock(e.unref(ts._sfc_main),{key:0,disabled:e.unref(j)===e.unref(E)&&!((je=Ie==null?void 0:Ie.buttonName)!=null&&je.includes("预览")),class:"calculator-content",modelValue:Ie.buttonName,onClickTrigger:na=>e.unref(Ce)(Ie),loading:g.value},null,8,["disabled","modelValue","onClickTrigger","loading"])):e.createCommentVNode("",!0)])}),256)),e.createElementVNode("div",null,[e.unref(W)!==""&&((_e=e.unref(E))==null?void 0:_e[((U=e.unref(E))==null?void 0:U.length)-1])!==e.unref(r)?(e.openBlock(),e.createBlock(e.unref(ts._sfc_main),{key:0,class:"calculator-content",onClickTrigger:$,modelValue:"保存"})):e.createCommentVNode("",!0)]),s.value?(e.openBlock(),e.createBlock(sl.ssFilePreview,{key:0,fileDataList:h.value,onDestroy:V},null,8,["fileDataList"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},c2=Ql._export_sfc(s2,[["__scopeId","data-v-063aa9af"]]),u2={};function d2(a,l){return" 567 "}const p2=Ql._export_sfc(u2,[["render",d2]]),f2={class:"module content"},h2={class:"module data"},v2={class:"module layout"},m2={class:"form-content"},y2=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({}),g=e.ref([]),u=()=>({comp:"Signature",compData:[{key:"signTypeList",contents:g.value},{key:"signConfig",contents:m.value}]}),C=I=>{var j;m.value=A.cloneDeep(I),r("change",(j=u())==null?void 0:j.compData)},M=I=>{var j,L;if((I==null?void 0:I.buttonName)==="确认"){const E=A.cloneDeep(I==null?void 0:I.content);switch(s.value){case"create":g.value.push({...E,index:((j=g.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=(I,j)=>{var L,E;switch(I){case"create":(L=d.value)==null||L.forEach(x=>{x.value=""}),s.value="create",i.visible=!0;break;case"update":(E=d.value)==null||E.forEach(x=>{x.value=j[x==null?void 0:x.prop]}),s.value="update",i.visible=!0;break;case"delete":g.value.splice(j,1),s.value="delete";break}},W=()=>{i.visible=!1};return e.watch(()=>n==null?void 0:n.itemContents,I=>{var j,L;I&&(m.value=((j=I==null?void 0:I.find(E=>E.key==="signConfig"))==null?void 0:j.contents)??{},g.value=((L=I==null?void 0:I.find(E=>E.key==="signTypeList"))==null?void 0:L.contents)??[])},{immediate:!0}),(I,j)=>{const L=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",f2,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"签名类型",-1)),e.createVNode(E,{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",h2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.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(E,{type:"primary",size:"small",onClick:b=>k("update",{...x,index:w+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>k("delete",w)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",v2,[e.createVNode(sl.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",m2,[(e.openBlock(),e.createBlock(sl.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)}}}),g2=Ql._export_sfc(y2,[["__scopeId","data-v-487e0536"]]),b2=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=>sl.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)},g=u=>{r("changeTrigger",u)};return(u,C)=>{var W,I,j,L,E;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:(I=a.stepConfig)==null?void 0:I.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:b=>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&&((E=a.stepConfig)!=null&&E.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":b=>x.value=b,onClickTrigger:m,onChangeTrigger:g,content:x==null?void 0:x.content},e.createSlots({_:2},[e.renderList(u.$slots,(b,S)=>({name:S,fn:e.withCtx($=>[e.renderSlot(u.$slots,S,e.mergeProps({ref_for:!0},$||{}),void 0,!0)])}))]),1064,["modelValue","onUpdate:modelValue","content"]))]))),128)):e.createCommentVNode("",!0)],64)}}}),k2=Ql._export_sfc(b2,[["__scopeId","data-v-fdbd6832"]]),x2=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 g=((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,I)=>{let j=m==null?void 0:m.map(L=>{var E;return{...L,value:(E=g==null?void 0:g[I])==null?void 0:E[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(k2,{stepConfig:i.value,stepList:s.value,onClickStep:h},{icon:e.withCtx(()=>[e.createVNode(m,{name:"import"})]),title:e.withCtx(({title:g})=>[e.createTextVNode(e.toDisplayString(g),1)]),description:e.withCtx(({descriptions:g})=>[e.createVNode(sl.ssForm,{ref:"formRef",rowContents:g,showOperator:!0,isEnableWrap:!1,isEdit:!1},null,8,["rowContents"])]),_:1},8,["stepConfig","stepList"])}}}),w2=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})}}}),_2=Ql._export_sfc(w2,[["__scopeId","data-v-4172a886"]]),S2={class:"line-content"},E2={class:"line-time"},C2=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(_2,{activities:r.value,timeLineConfig:n.value},{content:e.withCtx(({content:h,timestamp:c})=>[e.createElementVNode("span",S2,e.toDisplayString(h),1),e.createElementVNode("span",E2,e.toDisplayString(c),1)]),_:1},8,["activities","timeLineConfig"]))}}),D2=Ql._export_sfc(C2,[["__scopeId","data-v-b4d9deed"]]),T2={class:"tabs-content"},B2=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)},g=C=>{r("clickTrigger",C)},u=(C,M)=>{r("clickMainKey",C,M)};return(C,M)=>{var k,W;return e.openBlock(),e.createElementBlock("div",T2,[(k=i.value)!=null&&k.length?(e.openBlock(),e.createBlock(sl.ssTab,{tabsContents:i.value,key:(W=i.value)==null?void 0:W.length},{pane:e.withCtx(({tab:I,index:j})=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Zi)(I==null?void 0:I.comp)),{related:I==null?void 0:I.relatedTables,compNames:n==null?void 0:n.compNames,compName:I==null?void 0:I.name,cacheNewData:n==null?void 0:n.cacheNewData,isDevMode:a.isDevMode,itemData:I==null?void 0:I.compData,childItemData:I==null?void 0:I.itemChildData,onChange:s,index:(I==null?void 0:I.id)??j,config:{showIndex:I==null?void 0:I.showIndex,allowMove:I==null?void 0:I.allowMove,viewport:I==null?void 0:I.viewport,status:I==null?void 0:I.status},onContentChange:h,onPageChange:c,onRowClick:d,onRouteUrl:m,parentTableId:I==null?void 0:I.tableId,allMapContents:a.allMapContents,children:I==null?void 0:I.children,level:1,onClickTrigger:g,onClickMainKey:u},null,40,["related","compNames","compName","cacheNewData","isDevMode","itemData","childItemData","index","config","parentTableId","allMapContents","children"]))]),_:1},8,["tabsContents"])):e.createCommentVNode("",!0)])}}}),N2=Ql._export_sfc(B2,[["__scopeId","data-v-1ea318b4"]]),A2={class:"type-select"},z2=["onClick"],M2={class:"list-icon"},I2={__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",A2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(su),(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",M2,[e.createVNode(h,{name:c.icon},null,8,["name"])]),e.createElementVNode("div",null,e.toDisplayString(c.name),1)],8,z2)]))),128))])}}},O2=Ql._export_sfc(I2,[["__scopeId","data-v-91799bf8"]]),L2={class:"fill-content"},R2={class:"operate-content"},$2={class:"collapse-title-content"},V2={class:"collapse-title-item"},P2={key:1},F2=["onClick"],j2={class:"icon-content"},H2={key:0,class:"edit-content"},U2=["onClick"],q2={class:"comp-child"},W2={__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((I,j)=>(M===j&&(I.content=!0),I));h.value=k},d=M=>{var W;let k=(W=A.cloneDeep(h.value))==null?void 0:W.map((I,j)=>(M===j&&(I.content=!1),I));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((E,x)=>(M===x&&(E.content=!1),E));h.value=W;const I=A.cloneDeep(n.value),j=I==null?void 0:I.filter((E,x)=>(x===M&&(E.name=k),E));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(I=>(I==null?void 0:I.comp)!=="methodButton"),s.value=i.value,h.value=(W=A.cloneDeep(s.value))==null?void 0:W.map((I,j)=>({id:j,content:!1}))},{deep:!0,immediate:!0});const g=M=>zi(M),u=(M,k,W)=>{var j,L;if(!M)return;let I=A.cloneDeep(n.value);I=(j=I==null?void 0:I.map((E,x)=>(x===W&&(E.compData=M),E)))==null?void 0:j.filter(E=>(E==null?void 0:E.comp)!=="methodButton"),h.value=(L=A.cloneDeep(I))==null?void 0:L.map((E,x)=>({id:x,content:!1})),l.setOriginalData(I),l.setItemData(I)},C=M=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const k=A.cloneDeep(n.value),W=k==null?void 0:k.filter((I,j)=>j!==M);l.setOriginalData(W),l.setItemData(W),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(M,k)=>{const W=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",L2,[k[1]||(k[1]=e.createElementVNode("div",{class:"fill-operate"},e.toDisplayString("操作栏"),-1)),e.createElementVNode("div",R2,[e.createVNode(ec.default,{class:"collapse-content",collapseContents:i.value},{title:e.withCtx(({item:I,index:j})=>{var L,E,x,w,b,S,$,V,le,X;return[e.createElementVNode("div",$2,[e.createElementVNode("div",V2,[(E=(L=h.value)==null?void 0:L.find(me=>me.id===j))!=null&&E.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"collapse-title",style:e.normalizeStyle({marginRight:I.name&&I.name!==""?"8px":"0px"})},e.toDisplayString(I.name),5)),(w=(x=h.value)==null?void 0:x.find(me=>me.id===j))!=null&&w.content?(e.openBlock(),e.createElementBlock("div",P2,[e.createVNode(sl.ssInput,{modelValue:I.name,"onUpdate:modelValue":me=>I.name=me,onClick:k[0]||(k[0]=e.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):e.createCommentVNode("",!0),(S=(b=h.value)==null?void 0:b.find(me=>me.id===j))!=null&&S.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,F2))]),e.createElementVNode("div",j2,[(V=($=h.value)==null?void 0:$.find(me=>me.id===j))!=null&&V.content?(e.openBlock(),e.createElementBlock("div",H2,[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,I.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):e.createCommentVNode("",!0),(X=(le=h.value)==null?void 0:le.find(me=>me.id===j))!=null&&X.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,U2))])])]}),content:e.withCtx(({item:I,index:j})=>{var L,E;return[e.createElementVNode("div",q2,[e.createTextVNode(e.toDisplayString(g(I.comp+"Operate"))+" ",1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g(I.comp+"Operate")),{itemContents:I==null?void 0:I.compData,originalItemContents:(E=(L=s.value)==null?void 0:L.find((x,w)=>w===j))==null?void 0:E.compData,onChange:x=>u(x,I,j)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},K2=Ql._export_sfc(W2,[["__scopeId","data-v-a46a44b9"]]),G2={key:0,class:"show-content"},Y2={style:{display:"flex"}},J2={__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",G2,[(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",Y2,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)}}},X2=Ql._export_sfc(J2,[["__scopeId","data-v-3f3e863e"]]),Z2={class:"tabs-header"},Q2={class:"tabs-list"},e6={class:"tab-name"},a6={class:"tab-actions"},l6=["onClick"],r6=["onClick"],n6=["onClick"],i6={class:"model-operate"},o6={class:"model-select",style:{display:"unset"}},t6={class:"existing-components"},s6={class:"component-list"},c6=["onClick"],u6={class:"component-info"},d6={class:"component-type"},p6={class:"component-name"},f6={class:"model-fill"},h6={__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),g=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},I=fe=>{h.value="修改标签页",c.value.title=i.value[fe].title,d.value=fe,s.value=!0},j=fe=>{const N=x(fe);u.value.delete(N),i.value.splice(fe,1),Fe()},L=()=>{if(c.value.title.trim()){if(d.value===-1){const fe={title:c.value.title,value:c.value.title,label:c.value.title,children:[],id:E()};i.value.push(fe)}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,Fe()}},E=()=>`tab_${Date.now()}_${Math.random().toString(36).substr(2,9)}`,x=fe=>{const N=i.value[fe];return N.id||(N.id=E()),N.id},w=fe=>{var U;g.value=fe;const N=x(fe);C.value=A.cloneDeep(k.value);let se=u.value.get(N);!se&&((U=i.value[fe].children)==null?void 0:U.length)>0&&(se=V(i.value[fe].children)),se?M.setItemData(A.cloneDeep(se)):M.setItemData([]),m.value=!0},b=e.computed(()=>{const fe=A.useModelComp(A.pinia),N=A.storeToRefs(fe).itemData.value;return console.log("可用组件数据",N),!N||!Array.isArray(N)?[]:N.filter(se=>{var U;if(se.comp==="Tabs"&&g.value>=0){const _e=x(g.value);if((U=se.compData)==null?void 0:U.some(je=>{var na;return je.key==="stepList"&&((na=je.contents)==null?void 0:na.some(Ca=>Ca.id===_e))}))return!1}return!0})}),S=fe=>({Table:"表格",Form:"表单",Tabs:"标签页",Chart:"图表",Card:"卡片"})[fe]||fe,$=fe=>{var N;try{const se=A.cloneDeep(fe);se.id=Date.now()+Math.random(),se.comp==="Tabs"&&((N=se.compData)==null||N.forEach(_e=>{_e.key==="stepList"&&_e.contents&&_e.contents.forEach(Ie=>{Ie.id=E()})}));const U=A.cloneDeep(k.value);U.push(se),M.setItemData(U)}catch(se){console.error("添加组件失败:",se)}},V=fe=>fe.map(N=>{var se;switch(N.type){case"form":return{comp:"Form",name:N.value||"表单",compData:le(N.content)};case"table":return{comp:"Table",name:N.value||"表格",compData:X(N.content)};default:return{comp:"Unknown",name:N.value||"",compData:((se=N.content)==null?void 0:se.originalData)||[]}}}),le=fe=>{if(!fe)return[];const N=[];return fe.rowContents&&N.push({key:"formContent",contents:fe.rowContents}),fe.buttonValue&&N.push({key:"formButton",contents:fe.buttonValue}),typeof fe.isEnableWrap<"u"&&N.push({key:"enableWrap",contents:fe.isEnableWrap}),N},X=fe=>[],me=()=>{if(g.value>=0&&g.value<i.value.length){const fe=x(g.value);u.value.set(fe,A.cloneDeep(k.value)),i.value[g.value].children=ie(k.value),console.log("保存后的数据",ie(k.value))}m.value=!1,g.value=-1,C.value=null,Fe()},Be=()=>{C.value&&M.setItemData(A.cloneDeep(C.value)),m.value=!1,g.value=-1,C.value=null},F=()=>{m.value&&Be()},ie=fe=>{if(!Array.isArray(fe))throw new Error("sourceData must be an array");return fe.map((N,se)=>{if(!N||typeof N!="object")return N;const{comp:U,name:_e,compData:Ie}=N;switch(U){case"Form":return{type:"form",content:Y(Ie||[]),value:"表单"};case"Table":return{type:"table",content:ce(Ie||[]),value:"表格"};default:return{type:"xxx",content:Ce(Ie||[]),value:""}}})},Y=fe=>{const N={formRules:{},rowContents:[],buttonValue:[],rowValues:[],isEnableWrap:!0,isRowFlex:!0,isButtonRow:!0,isEdit:!0,isStartJustify:!0},se={formContent:"rowContents",enableWrap:"isEnableWrap",formButton:"buttonValue"};return fe.forEach((U,_e)=>{if(!U||typeof U!="object"){console.warn(`Invalid config at index ${_e}:`,U);return}const{key:Ie,contents:je}=U,na=se[Ie];if(!na){console.warn(`Unknown Form config key: ${Ie}`);return}Ie==="enableWrap"?N[na]=!!je:N[na]=Array.isArray(je)?je:[]}),N},ce=fe=>{const N={columns:[],tableData:[],extraButton:[],rowButton:[],currentPage:0,total:0,pageSize:0,isShowPagination:!0,isShowEdit:!0,isMoveColumn:!0,isShowDelete:!0},se={header:"columns",tableContents:"tableData"};return fe.forEach((U,_e)=>{if(!U||typeof U!="object"){console.warn(`Invalid config at index ${_e}:`,U);return}const{key:Ie,contents:je}=U,na=se[Ie];if(!na){console.warn(`Unknown Table config key: ${Ie}`);return}N[na]=Array.isArray(je)?je:[]}),N},Ce=fe=>(console.log("Default conversion logic - to be implemented"),{originalData:fe,processed:!1,componentType:"unknown"}),Fe=()=>{const fe=[{key:"stepList",contents:i.value}];r("change",fe)};return e.watch(()=>n.itemContents,fe=>{if(fe&&fe.length>0){const N=fe.find(se=>se.key==="stepList");N&&N.contents&&(i.value=N.contents.map(se=>({title:se.title||"",value:se.value||se.title||"",label:se.label||se.title||"",children:se.children||[],id:se.id||E()})))}},{immediate:!0,deep:!0}),(fe,N)=>{const se=e.resolveComponent("svg-icon"),U=e.resolveComponent("el-input"),_e=e.resolveComponent("el-form-item"),Ie=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",Z2,[N[6]||(N[6]=e.createElementVNode("h4",null,"标签页管理",-1)),e.createElementVNode("button",{onClick:W},[e.createVNode(se,{name:"Plus",style:{width:"14px",height:"14px","margin-right":"4px"}}),N[5]||(N[5]=e.createTextVNode(" 新增标签页 "))])]),e.createElementVNode("div",Q2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(je,na)=>(e.openBlock(),e.createElementBlock("div",{class:"tab-item",key:na},[e.createElementVNode("span",e6,e.toDisplayString(je.title),1),e.createElementVNode("div",a6,[e.createElementVNode("button",{onClick:Ca=>I(na)},"修改标题",8,l6),e.createElementVNode("button",{onClick:Ca=>w(na)},"布局调整",8,r6),e.createElementVNode("button",{onClick:Ca=>j(na)},"删除",8,n6)])]))),128))]),e.createVNode(Ar.ssDialog,{modelValue:s.value,"onUpdate:modelValue":N[2]||(N[2]=je=>s.value=je),title:h.value,onBeforeDestroy:N[3]||(N[3]=je=>s.value=!1)},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:N[1]||(N[1]=je=>s.value=!1)},"取消"),e.createElementVNode("button",{type:"primary",onClick:L},"确定")]),default:e.withCtx(()=>[e.createVNode(Ie,{model:c.value,"label-width":"80px"},{default:e.withCtx(()=>[e.createVNode(_e,{label:"标签名称",required:""},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:c.value.title,"onUpdate:modelValue":N[0]||(N[0]=je=>c.value.title=je),placeholder:"请输入标签页名称"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue","title"]),e.createVNode(Ar.ssDialog,{modelValue:m.value,"onUpdate:modelValue":N[4]||(N[4]=je=>m.value=je),title:"布局调整",fullScreen:"",onBeforeDestroy:F},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:Be},"取消"),e.createElementVNode("button",{onClick:me},"确定")]),default:e.withCtx(()=>[e.createElementVNode("div",i6,[e.createElementVNode("div",o6,[e.createVNode(O2),e.createElementVNode("div",t6,[N[8]||(N[8]=e.createElementVNode("h5",null,"添加已有组件",-1)),e.createElementVNode("div",s6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,je=>(e.openBlock(),e.createElementBlock("div",{key:je.id,class:"component-item",onClick:na=>$(je)},[e.createElementVNode("div",u6,[e.createElementVNode("span",d6,e.toDisplayString(S(je.comp)),1),e.createElementVNode("span",p6,e.toDisplayString(je.name),1)]),N[7]||(N[7]=e.createElementVNode("button",{class:"add-btn"},"添加",-1))],8,c6))),128))])])]),(e.openBlock(),e.createElementBlock("div",{class:"model-show",key:fe.innerWidth},[e.createVNode(X2)])),e.createElementVNode("div",f6,[e.createVNode(K2)])])]),_:1},8,["modelValue"])])}}},v6=Ql._export_sfc(h6,[["__scopeId","data-v-9096ed0d"]]);function m6(){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 y6(a){return{type:"line",...a}}function g6(){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 b6(a){return{type:"bar",barWidth:"60%",...a}}function k6(){return{title:{text:"",left:"center"},tooltip:{trigger:"item"},series:[]}}function x6(a){return{type:"pie",radius:"80%",emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},...a}}const w6=()=>({title:{text:"",left:"center"},tooltip:{trigger:"item"},xAxis:{scale:!0},yAxis:{scale:!0},series:[]}),_6=a=>({type:"scatter",symbolSize:20,...a}),Cn={Line:{initBaseoptions:m6,initSeries:y6},Bar:{initBaseoptions:g6,initSeries:b6},Pie:{initBaseoptions:k6,initSeries:x6},Scatter:{initBaseoptions:w6,initSeries:_6}},S6=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 g=[];if(m==null||m.forEach(C=>{var M;g.push((M=n==null?void 0:n[0])==null?void 0:M[C])}),!m||!g)return d;d.xAxis.data=m;const u=c({data:g});return d.series.push(u),d},E6=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 g=[];if(m==null||m.forEach(C=>{var M;g.push((M=n==null?void 0:n[0])==null?void 0:M[C])}),!m||!g)return d;d.xAxis.data=m;const u=c({data:g});return d.series.push(u),d},C6=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 g=[];if(m==null||m.forEach(M=>{var k;g.push((k=n==null?void 0:n[0])==null?void 0:k[M])}),!m||!g)return d;const u=[];for(let M=0;M<m.length;M++){const k=m[M],W=g[M];u.push({name:k,value:W})}const C=c({data:u});return d.series.push(C),d},D6=({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 g=l==null?void 0:l.map(M=>M==null?void 0:M.prop);if(m=g==null?void 0:g.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},T6=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 S6({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),i==="Bar"&&(s=await E6({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),i==="Pie"&&(s=await C6({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),i==="Scatter"&&(s=await D6({chartBaseConfig:l,chartDataConfig:n,chartDetailConfig:r})),s},B6=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 T6(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(Ou.ssChart,{optionContents:n.value},null,8,["optionContents"])],4))}}),N6=Ql._export_sfc(B6,[["__scopeId","data-v-d4c081e8"]]),A6={class:"chart-module layout"},z6={class:"chart-module content"},M6={class:"chart-module content"},I6={class:"form-content"},O6={class:"dialog-footer"},L6={class:"form-content"},R6={class:"dialog-footer"},$6={class:"form-content"},V6={class:"dialog-footer"},P6=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 we;s.value=h(),(we=s.value)==null||we.forEach(ue=>{var Ge;const De=ue==null?void 0:ue.prop;ue.value=(Ge=c==null?void 0:c.value)==null?void 0:Ge[De]}),i.visible=!0},m=we=>{c.value=we},g=()=>{var we;i.visible=!1,r("change",(we=de())==null?void 0:we.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 we=C.value,ue=A.cloneDeep(we);return ue==null||ue.forEach(De=>{var ua;const Ge=De==null?void 0:De.prop;De.value=(ua=k.value)==null?void 0:ua[Ge]}),ue},I=we=>{var De;k.value=we;const ue=W();C.value=ue,r("change",(De=de())==null?void 0:De.compData)},j=async()=>{const we=await te.getMenusContent(),ue=W();ue==null||ue.forEach(De=>{(De==null?void 0:De.prop)==="menu"&&(De.contents=we)}),C.value=ue,u.visible=!0,await je(k.value.menu),await ee(k.value.group)},L=e.reactive({visible:!1,width:"840",title:"详情页配置"}),E=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({}),b=()=>{const we=E.value,ue=A.cloneDeep(we);return ue==null||ue.forEach(De=>{var ua;const Ge=De==null?void 0:De.prop;De.value=(ua=w.value)==null?void 0:ua[Ge]}),ue},S=we=>{var De;w.value=we;const ue=b();E.value=ue,r("change",(De=de())==null?void 0:De.compData)},$=async()=>{await F();const we=A.cloneDeep(V.value),ue=b();ue==null||ue.forEach(De=>{var ua;const Ge=De==null?void 0:De.prop;De.value=(ua=w==null?void 0:w.value)==null?void 0:ua[Ge],Ge==="mainKey"&&(De.contents=we)}),E.value=ue,L.visible=!0},V=e.ref([]),le=e.ref([]),X=e.ref({}),me=e.ref({}),Be=()=>{const{compData:we}=U.value||{},ue=we==null?void 0:we.find(J=>{const{key:he}=J;return he==="header"}),De=(ue==null?void 0:ue.contents)||[],Ge=De==null?void 0:De.filter((J,he)=>{const{label:pe}=J;return pe!=="操作"}),ua=Ge==null?void 0:Ge.findIndex((J,he)=>{const{isMainKey:pe}=J;return pe});if(ua<0)return[];const Ja=we==null?void 0:we.find(J=>{const{key:he}=J;return he==="tableContents"}),R=(Ja==null?void 0:Ja.contents)||[];return R==null?void 0:R.map(J=>{const he=J==null?void 0:J[0];let pe=ua;ja.isObject(he)&&(he!=null&&he.id)&&(pe=pe+1);const ha=J==null?void 0:J[pe];return{label:ha,value:ha}})},F=async()=>{const we=await Be();V.value=we},ie=async we=>{const ue=sessionStorage.getItem("systemKey");return await te.getItemData(we,ue,"")},Y=async we=>{const ue=we;le.value=ue==null?void 0:ue.map(De=>{const{name:Ge}=De;return X.value[Ge]=De,{label:Ge,value:Ge}})},ce=we=>{const{comp:ue,compData:De}=me.value||{};if(ue==="Table"){let Ge=b();Ge=Ge.filter(ua=>{const{prop:Ja}=ua;return Ja!=="formItems"}),na(Ge,De),E.value=Ge}},Ce=async()=>{var De,Ge;const we=(De=w==null?void 0:w.value)==null?void 0:De.mainKey,ue=(Ge=k==null?void 0:k.value)==null?void 0:Ge.menu;if(we){const Ja=`${ue==null?void 0:ue.join("/")}^${we}`,R=await ie(Ja);await Y(R);const H=b();H==null||H.forEach(J=>{(J==null?void 0:J.prop)==="group"&&(J.contents=le.value)}),E.value=H}};e.watch(()=>{var we;return(we=w==null?void 0:w.value)==null?void 0:we.mainKey},async(we,ue)=>{we!=ue&&we&&await Ce()});const Fe=async we=>{const ue=X.value[we];me.value=ue,await ce()};e.watch(()=>{var we;return(we=w==null?void 0:w.value)==null?void 0:we.group},async(we,ue)=>{we!=ue&&we&&Fe(we)});const fe=async()=>{var ue;await Ce();const we=(ue=w.value)==null?void 0:ue.group;await Fe(we)},N=e.ref([]),se=e.ref({}),U=e.ref({}),_e=async we=>{const ue=we==null?void 0:we.join("/"),De=sessionStorage.getItem("systemKey");return await te.getItemData(ue,De,"")},Ie=async we=>{const ue=await _e(we);N.value=ue==null?void 0:ue.map(De=>{const{name:Ge}=De;return se.value[Ge]=De,{label:Ge,value:Ge}})},je=async(we,ue)=>{await Ie(we);const De=W();De==null||De.forEach(Ge=>{(Ge==null?void 0:Ge.prop)==="group"&&(Ge.contents=N.value)}),C.value=De};e.watch(()=>{var we;return(we=k==null?void 0:k.value)==null?void 0:we.menu},async(we,ue)=>{const De=we==null?void 0:we.join("/"),Ge=ue==null?void 0:ue.join("/");De!=Ge&&await je(we)});const na=(we,ue)=>{const De=ue==null?void 0:ue.find(R=>{const{key:H}=R;return H==="header"}),Ge=(De==null?void 0:De.contents)||[],ua=Ge==null?void 0:Ge.filter((R,H)=>{const{label:J}=R;return J!=="操作"}),Ja=ua==null?void 0:ua.map((R,H)=>{const{label:J}=R;return{label:J,value:H}});we==null||we.forEach(R=>{const H=R==null?void 0:R.prop;(H==="nameCol"||H==="valueCol")&&(R.contents=Ja)})},Ca=we=>{const{comp:ue,compData:De}=U.value||{};if(ue==="Table"){k.value.formItems=[];let Ge=W();Ge=Ge.filter(ua=>{const{prop:Ja}=ua;return Ja!=="formItems"}),na(Ge,De),C.value=Ge}},ee=async we=>{const ue=se.value[we];U.value=ue,await Ca()};e.watch(()=>{var we;return(we=k==null?void 0:k.value)==null?void 0:we.group},async(we,ue)=>{we!=ue&&ee(we)});const ca=async()=>{var De,Ge;const we=(De=k.value)==null?void 0:De.menu;await je(we);const ue=(Ge=k.value)==null?void 0:Ge.group;await ee(ue)},de=()=>({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 ue,De,Ge;C.value=M(),E.value=x();const we=n==null?void 0:n.itemContents;c.value=((ue=we==null?void 0:we.find(ua=>ua.key==="chartBaseConfig"))==null?void 0:ue.contents)??{},k.value=((De=we==null?void 0:we.find(ua=>ua.key==="chartDataConfig"))==null?void 0:De.contents)??{},await ca(),w.value=((Ge=we==null?void 0:we.find(ua=>ua.key==="chartDetailConfig"))==null?void 0:Ge.contents)??{},await fe()}),(we,ue)=>{const De=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",A6,[ue[4]||(ue[4]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createVNode(De,{id:"themeButton",onClick:ue[0]||(ue[0]=Ge=>d())},{default:e.withCtx(()=>ue[3]||(ue[3]=[e.createTextVNode(" 修改 ")])),_:1,__:[3]})]),e.createElementVNode("div",z6,[ue[6]||(ue[6]=e.createElementVNode("h4",{class:"module-title"},"数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:ue[1]||(ue[1]=Ge=>j())},{default:e.withCtx(()=>ue[5]||(ue[5]=[e.createTextVNode(" 修改 ")])),_:1,__:[5]})]),e.createElementVNode("div",M6,[ue[8]||(ue[8]=e.createElementVNode("h4",{class:"module-title"},"详情数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:ue[2]||(ue[2]=Ge=>$())},{default:e.withCtx(()=>ue[7]||(ue[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",I6,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!0,onChange:m},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",O6,[e.createVNode(De,{class:"cancel-button button",onClick:pa,id:"themeBorderButton"},{default:e.withCtx(()=>ue[9]||(ue[9]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[9]}),e.createVNode(De,{class:"ok-button button",onClick:g,id:"themeButton"},{default:e.withCtx(()=>ue[10]||(ue[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",L6,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:C.value,key:C.value,isEnableWrap:!0,onChange:I},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",R6,[e.createVNode(De,{class:"cancel-button button",onClick:pa,id:"themeBorderButton"},{default:e.withCtx(()=>ue[11]||(ue[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(De,{class:"ok-button button",onClick:pa,id:"themeButton"},{default:e.withCtx(()=>ue[12]||(ue[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",$6,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:S},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",V6,[e.createVNode(De,{class:"cancel-button button",onClick:pa,id:"themeBorderButton"},{default:e.withCtx(()=>ue[13]||(ue[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(De,{class:"ok-button button",onClick:pa,id:"themeButton"},{default:e.withCtx(()=>ue[14]||(ue[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible","title","width"])],64)}}}),F6=Ql._export_sfc(P6,[["__scopeId","data-v-fe119645"]]),j6={class:"layout"},H6=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 g;const m=(g=i==null?void 0:i.value)==null?void 0:g.find(u=>{const{key:C}=u;return C==="baseConfig"});return m==null?void 0:m.contents}),h=e.computed(()=>{var g;const m=(g=i==null?void 0:i.value)==null?void 0:g.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 g=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)/g);C.forEach(k=>{k.span=M})}return m}),d=m=>{n("rowClick",m)};return(m,g)=>{var M;const u=e.resolveComponent("el-col"),C=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",j6,[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 I;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:(I=s.value)==null?void 0:I.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"])])}}}),U6=Ql._export_sfc(H6,[["__scopeId","data-v-ab9a36ed"]]),q6={class:"layout-operate"},W6={class:"layout-module"},K6={class:"collapse-title-item"},G6={class:"collapse-title"},Y6={class:"icon-content"},J6=["onClick"],X6={class:"comp-child"},Z6=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([]),g=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,b=w==null?void 0:w.find(S=>{const{key:$}=S;return $==="baseConfig"});return b==null?void 0:b.contents}),k=e.computed(()=>{const w=C==null?void 0:C.value,b=w==null?void 0:w.find(S=>{const{key:$}=S;return $==="children"});return b==null?void 0:b.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(b=>{var $;const{prop:S}=b;return b.value=($=M.value)==null?void 0:$[S],b})};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)||[],g.value=(w=k.value)==null?void 0:w.map(b=>u(b))},{immediate:!0});const I=(w,b)=>{const S=A.cloneDeep(k==null?void 0:k.value);S[b].span=w.span,m.value=S,r("change",x(),!0)},j=w=>zi(w),L=(w,b,S)=>{if(!w)return;const $=A.cloneDeep(k==null?void 0:k.value);$[S]&&($[S].compData=w,m.value=$,r("change",x(),!0))},E=w=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{let b=A.cloneDeep(k==null?void 0:k.value);b=b==null?void 0:b.filter((S,$)=>w!==$),m.value=b,r("change",x(),!0),ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=()=>({compData:[{key:"baseConfig",contents:s.value},{key:"children",contents:m==null?void 0:m.value}]});return(w,b)=>{const S=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",q6,[e.createElementVNode("div",W6,[b[1]||(b[1]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createElementVNode("div",null,[e.createVNode(sl.ssForm,{rowContents:h.value,isEnableWrap:!0,onChange:b[0]||(b[0]=$=>d($))},null,8,["rowContents"])])]),e.createVNode(ec.default,{class:"collapse-content",collapseContents:k.value},{title:e.withCtx(({item:$,index:V})=>[e.createElementVNode("div",K6,[e.createElementVNode("div",G6,e.toDisplayString($.name),1),e.createElementVNode("div",Y6,[e.createElementVNode("div",{onClick:e.withModifiers(le=>E(V),["stop"]),class:"icon-content"},[e.createVNode(S,{name:"Delete",style:{width:"16px",height:"16px"}})],8,J6)])])]),content:e.withCtx(({item:$,index:V})=>[e.createElementVNode("div",X6,[e.createElementVNode("div",null,[(e.openBlock(),e.createBlock(sl.ssForm,{rowContents:g.value[V],key:V,isEnableWrap:!0,onChange:le=>I(le,V)},null,8,["rowContents","onChange"]))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(j($.comp+"Operate")),{itemContents:$==null?void 0:$.compData,originalItemContents:$.compData,onChange:le=>L(le,$,V)},null,40,["itemContents","originalItemContents","onChange"]))])]),_:1},8,["collapseContents"])])}}}),Q6=Ql._export_sfc(Z6,[["__scopeId","data-v-ba05456e"]]),e1=typeof window<"u";var Ds;e1&&((Ds=window==null?void 0:window.navigator)!=null&&Ds.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function xn(a){return a==null}function jc(){}const a1=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(a1)));function l1(){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 Ts(a,l=16){if(typeof a!="function")return jc;const n=(...s)=>{a(...s)};if(l<=0)return Hc(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 r1(a,l=100){if(typeof a!="function")return jc;const n=(...i)=>{a(...i)};if(l<=0)return Hc(n);let r;return function(...i){clearTimeout(r),r=setTimeout(()=>{n(...i)},l)}}function Hc(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,Uc=new WeakMap;function n1(){Gi.forEach(a=>{a(...Uc.get(a))}),Gi.clear()}function dn(a,...l){if(typeof a!="function")return a;Uc.set(a,l),!Gi.has(a)&&(Gi.add(a),Gi.size===1&&Promise.resolve().then(n1))}const qc=Symbol("LAYOUT_KEY"),Wc=Symbol("EMITTER_KEY");function i1(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 Tt(a){const l=Array(a.length);for(let n=0,r=a.length;n<r;n++)l[n]=o1(a[n]);return l}function o1(a){return{...a}}function Kc(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=Yc(a),i=Jc(a),s=Array(a.length);for(let h=0,c=i.length;h<c;h++){let d=i[h];d.static||(d=s1(r,d,l,n),r.push(d)),s[a.findIndex(m=>m.i===d.i)]=d,d.moved=!1}return s}function s1(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 c1(a,l){const n=Yc(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 Bs(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(Kc(a[n],l))return a[n]}function Gc(a,l){return a.filter(n=>Kc(n,l))}function Yc(a){return a.filter(l=>l.static)}function Bt(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=Jc(a);d&&(m=m.reverse());const g=Gc(m,l);if(s&&g.length)return l.x=h,l.y=c,l.moved=!1,a;for(let u=0,C=g.length;u<C;u++){const M=g[u];M.moved||l.y>M.y&&l.y-M.y>M.h/4||(M.static?a=Ns(a,M,l,i):a=Ns(a,l,M,i))}return a}function Ns(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 Bt(a,n,void 0,i.y,!1)}return Bt(a,n,void 0,n.y+1,!1)}function u1(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 d1(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 p1(a,l,n,r){return{top:a+"px",left:l+"px",width:n+"px",height:r+"px",position:"absolute"}}function f1(a,l,n,r){return{top:a+"px",right:l+"px",width:n+"px",height:r+"px",position:"absolute"}}function Jc(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 h1(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 v1(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 As(a){return m1(a)}function m1(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 zs(a,l,n,r){return y1(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 y1(a){return typeof a=="number"&&!Number.isNaN(a)}function g1(a,l){const n=Zc(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 Xc(a,l){if(!l[a])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+a+" is missing!");return l[a]}function b1(a,l,n,r,i,s,h){if(l[r])return Tt(l[r]);let c=a;const d=Zc(n),m=d.slice(d.indexOf(r));for(let g=0,u=m.length;g<u;g++){const C=m[g];if(l[C]){c=l[C];break}}return c=Tt(c||[]),Ci(c1(c,{cols:s}),h)}function Zc(a){return Object.keys(a).sort((l,n)=>a[l]-a[n])}let k1="auto";function x1(){return typeof document<"u"}function Ms(){return x1()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir"):k1}var Wi={exports:{}},w1=Wi.exports,Is;function _1(){return Is||(Is=1,function(a,l){(function(n,r){a.exports=r()})(w1,function(){function n(t,o){var f=Object.keys(t);if(Object.getOwnPropertySymbols){var y=Object.getOwnPropertySymbols(t);o&&(y=y.filter(function(_){return Object.getOwnPropertyDescriptor(t,_).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 g(t){return g=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(o){return o.__proto__||Object.getPrototypeOf(o)},g(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=g(t);if(o){var _=g(this).constructor;f=Reflect.construct(y,arguments,_)}else f=y.apply(this,arguments);return function(O,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(O)}(this,f)}}function k(){return k=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(t,o,f){var y=function(O,K){for(;!Object.prototype.hasOwnProperty.call(O,K)&&(O=g(O))!==null;);return O}(t,o);if(y){var _=Object.getOwnPropertyDescriptor(y,o);return _.get?_.get.call(arguments.length<3?t:f):_.value}},k.apply(this,arguments)}function W(t){var o=function(f,y){if(typeof f!="object"||f===null)return f;var _=f[Symbol.toPrimitive];if(_!==void 0){var O=_.call(f,y);if(typeof O!="object")return O;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(f)}(t,"string");return typeof o=="symbol"?o:o+""}var I=function(t){return!(!t||!t.Window)&&t instanceof t.Window},j=void 0,L=void 0;function E(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 I(t)?t:(t.ownerDocument||t).defaultView||L.window}typeof window<"u"&&window&&E(window);var w=function(t){return!!t&&i(t)==="object"},b=function(t){return typeof t=="function"},S={window:function(t){return t===L||I(t)},docFrag:function(t){return w(t)&&t.nodeType===11},object:w,func:b,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&&b(t.splice)}};function $(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 _=y==="x"?"y":"x";o.page[_]=f.coords.start.page[_],o.client[_]=f.coords.start.client[_],o.delta[_]=0}}}var le={id:"actions/drag",install:function(t){var o=t.actions,f=t.Interactable,y=t.defaults;f.prototype.draggable=le.draggable,o.map.drag=le,o.methodDict.drag="draggable",y.actions.drag=le.defaults},listeners:{"interactions:before-action-move":$,"interactions:action-resume":$,"interactions:action-move":V,"auto-start:check":function(t){var o=t.interaction,f=t.interactable,y=t.buttons,_=f.options.drag;if(_&&_.enabled&&(!o.pointerIsDown||!/mouse|pointer/.test(o.pointerType)||(y&f.options.drag.mouseButtons)!=0))return t.action={name:"drag",axis:_.lockAxis==="start"?_.startAxis:_.lockAxis},!1}},draggable:function(t){return S.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):S.bool(t)?(this.options.drag.enabled=t,this):this.options.drag},beforeMove:$,move:V,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor:function(){return"move"},filterEventType:function(t){return t.search("drag")===0}},X=le,me={init:function(t){var o=t;me.document=o.document,me.DocumentFragment=o.DocumentFragment||Be,me.SVGElement=o.SVGElement||Be,me.SVGSVGElement=o.SVGSVGElement||Be,me.SVGElementInstance=o.SVGElementInstance||Be,me.Element=o.Element||Be,me.HTMLElement=o.HTMLElement||me.Element,me.Event=o.Event,me.Touch=o.Touch||Be,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 Be(){}var F=me,ie={init:function(t){var o=F.Element,f=t.navigator||{};ie.supportsTouch="ontouchstart"in t||S.func(t.DocumentTouch)&&F.document instanceof t.DocumentTouch,ie.supportsPointerEvent=f.pointerEnabled!==!1&&!!F.PointerEvent,ie.isIOS=/iP(hone|od|ad)/.test(f.platform),ie.isIOS7=/iP(hone|od|ad)/.test(f.platform)&&/OS 7[^\d]/.test(f.appVersion),ie.isIe9=/MSIE 9/.test(f.userAgent),ie.isOperaMobile=f.appName==="Opera"&&ie.supportsTouch&&/Presto/.test(f.userAgent),ie.prefixedMatchesSelector="matches"in o.prototype?"matches":"webkitMatchesSelector"in o.prototype?"webkitMatchesSelector":"mozMatchesSelector"in o.prototype?"mozMatchesSelector":"oMatchesSelector"in o.prototype?"oMatchesSelector":"msMatchesSelector",ie.pEventTypes=ie.supportsPointerEvent?F.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,ie.wheelEvent=F.document&&"onmousewheel"in F.document?"mousewheel":"wheel"},supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null},Y=ie;function ce(t,o){if(t.contains)return t.contains(o);for(;o;){if(o===t)return!0;o=o.parentNode}return!1}function Ce(t,o){for(;S.element(t);){if(fe(t,o))return t;t=Fe(t)}return null}function Fe(t){var o=t.parentNode;if(S.docFrag(o)){for(;(o=o.host)&&S.docFrag(o););return o}return o}function fe(t,o){return L!==j&&(o=o.replace(/\/deep\//g," ")),t[Y.prefixedMatchesSelector](o)}var N=function(t){return t.parentNode||t.host};function se(t,o){for(var f,y=[],_=t;(f=N(_))&&_!==o&&f!==_.ownerDocument;)y.unshift(_),_=f;return y}function U(t,o,f){for(;S.element(t);){if(fe(t,o))return!0;if((t=Fe(t))===f)return fe(t,o)}return!1}function _e(t){return t.correspondingUseElement||t}function Ie(t){var o=t instanceof F.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 je(t){var o,f=Ie(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 na(t){for(var o=[];t;)o.push(t),t=Fe(t);return o}function Ca(t){return!!S.string(t)&&(F.document.querySelector(t),!0)}function ee(t,o){for(var f in o)t[f]=o[f];return t}function ca(t,o,f){return t==="parent"?Fe(f):t==="self"?o.getRect(f):Ce(f,t)}function de(t,o,f,y){var _=t;return S.string(_)?_=ca(_,o,f):S.func(_)&&(_=_.apply(void 0,y)),S.element(_)&&(_=je(_)),_}function pa(t){return t&&{x:"x"in t?t.x:t.left,y:"y"in t?t.y:t.top}}function we(t){return!t||"x"in t&&"y"in t||((t=ee({},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 ue(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(de(y&&y.origin||t.options.origin,t,o,[t&&o]))||{x:0,y:0}}function Ge(t,o){var f=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(ge){return!0},y=arguments.length>3?arguments[3]:void 0;if(y=y||{},S.string(t)&&t.search(" ")!==-1&&(t=ua(t)),S.array(t))return t.forEach(function(ge){return Ge(ge,o,f,y)}),y;if(S.object(t)&&(o=t,t=""),S.func(o)&&f(t))y[t]=y[t]||[],y[t].push(o);else if(S.array(o))for(var _=0,O=o;_<O.length;_++){var K=O[_];Ge(t,K,f,y)}else if(S.object(o))for(var Q in o)Ge(ua(Q).map(function(ge){return"".concat(t).concat(ge)}),o[Q],f,y);return y}function ua(t){return t.trim().split(/ +/)}var Ja=function(t,o){return Math.sqrt(t*t+o*o)},R=["webkit","moz"];function H(t,o){t.__set||(t.__set={});var f=function(_){if(R.some(function(O){return _.indexOf(O)===0}))return 1;typeof t[_]!="function"&&_!=="__set"&&Object.defineProperty(t,_,{get:function(){return _ in t.__set?t.__set[_]:t.__set[_]=o[_]},set:function(O){t.__set[_]=O},configurable:!0})};for(var y in o)f(y);return t}function J(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 pe(t){return t instanceof F.Event||t instanceof F.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&&pe(t)?(ha("screen",t,o),o.x+=window.scrollX,o.y+=window.scrollY):ha("page",t,o),o}function He(t){return S.number(t.pointerId)?t.pointerId:t.identifier}function _a(t,o,f){var y=o.length>1?ma(o):o[0];ta(y,t.page),function(_,O){O=O||{},Y.isOperaMobile&&pe(_)?ha("screen",_,O):ha("client",_,O)}(y,t.client),t.timeStamp=f}function ze(t){var o=[];return S.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 ma(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 _ in o)o[_]+=y[_]}for(var O in o)o[O]/=t.length;return o}function Oa(t){if(!t.length)return null;var o=ze(t),f=Math.min(o[0].pageX,o[1].pageX),y=Math.min(o[0].pageY,o[1].pageY),_=Math.max(o[0].pageX,o[1].pageX),O=Math.max(o[0].pageY,o[1].pageY);return{x:f,y,left:f,top:y,right:_,bottom:O,width:_-f,height:O-y}}function Ma(t,o){var f=o+"X",y=o+"Y",_=ze(t),O=_[0][f]-_[1][f],K=_[0][y]-_[1][y];return Ja(O,K)}function fa(t,o){var f=o+"X",y=o+"Y",_=ze(t),O=_[1][f]-_[0][f],K=_[1][y]-_[0][y];return 180*Math.atan2(K,O)/Math.PI}function Ba(t){return S.string(t.pointerType)?t.pointerType:S.number(t.pointerType)?[void 0,void 0,"touch","pen","mouse"][t.pointerType]:/touch/.test(t.type||"")||t instanceof F.Touch?"touch":"mouse"}function Te(t){var o=S.func(t.composedPath)?t.composedPath():t.path;return[_e(o?o[0]:t.target),_e(t.currentTarget)]}var ye=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(ye.prototype,"interaction",{get:function(){return this._interaction._proxy},set:function(){}});var Ne=function(t,o){for(var f=0;f<o.length;f++){var y=o[f];t.push(y)}return t},ae=function(t){return Ne([],t)},oe=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[oe(t,o)]},Ze=function(t){m(f,t);var o=M(f);function f(y,_,O){var K;s(this,f),(K=o.call(this,_._interaction)).dropzone=void 0,K.dragEvent=void 0,K.relatedTarget=void 0,K.draggable=void 0,K.propagationStopped=!1,K.immediatePropagationStopped=!1;var Q=O==="dragleave"?y.prev:y.cur,ge=Q.element,Ue=Q.dropzone;return K.type=O,K.target=ge,K.currentTarget=ge,K.dropzone=Ue,K.dragEvent=_,K.relatedTarget=_.target,K.draggable=_.interactable,K.timeStamp=_.timeStamp,K}return c(f,[{key:"reject",value:function(){var y=this,_=this._interaction.dropState;if(this.type==="dropactivate"||this.dropzone&&_.cur.dropzone===this.dropzone&&_.cur.element===this.target)if(_.prev.dropzone=this.dropzone,_.prev.element=this.target,_.rejected=!0,_.events.enter=null,this.stopImmediatePropagation(),this.type==="dropactivate"){var O=_.activeDrops,K=oe(O,function(ge){var Ue=ge.dropzone,Se=ge.element;return Ue===y.dropzone&&Se===y.target});_.activeDrops.splice(K,1);var Q=new f(_,this.dragEvent,"dropdeactivate");Q.dropzone=this.dropzone,Q.target=this.target,this.dropzone.fire(Q)}else this.dropzone.fire(new f(_,this.dragEvent,"dragleave"))}},{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),f}(ye);function Pa(t,o){for(var f=0,y=t.slice();f<y.length;f++){var _=y[f],O=_.dropzone,K=_.element;o.dropzone=O,o.target=K,O.fire(o),o.propagationStopped=o.immediatePropagationStopped=!1}}function Sa(t,o){for(var f=function(O,K){for(var Q=[],ge=0,Ue=O.interactables.list;ge<Ue.length;ge++){var Se=Ue[ge];if(Se.options.drop.enabled){var ra=Se.options.drop.accept;if(!(S.element(ra)&&ra!==K||S.string(ra)&&!fe(K,ra)||S.func(ra)&&!ra({dropzone:Se,draggableElement:K})))for(var Ta=0,Za=Se.getAllElements();Ta<Za.length;Ta++){var Ka=Za[Ta];Ka!==K&&Q.push({dropzone:Se,element:Ka,rect:Se.getRect(Ka)})}}}return Q}(t,o),y=0;y<f.length;y++){var _=f[y];_.rect=_.dropzone.getRect(_.element)}return f}function Xa(t,o,f){for(var y=t.dropState,_=t.interactable,O=t.element,K=[],Q=0,ge=y.activeDrops;Q<ge.length;Q++){var Ue=ge[Q],Se=Ue.dropzone,ra=Ue.element,Ta=Ue.rect,Za=Se.dropCheck(o,f,_,O,ra,Ta);K.push(Za?ra:null)}var Ka=function(nl){for(var _l,gl,Nl,Wl=[],zl=0;zl<nl.length;zl++){var $l=nl[zl],Rl=nl[_l];if($l&&zl!==_l)if(Rl){var rn=N($l),or=N(Rl);if(rn!==$l.ownerDocument)if(or!==$l.ownerDocument)if(rn!==or){Wl=Wl.length?Wl:se(Rl);var un=void 0;if(Rl instanceof F.HTMLElement&&$l instanceof F.SVGElement&&!($l instanceof F.SVGSVGElement)){if($l===or)continue;un=$l.ownerSVGElement}else un=$l;for(var kn=se(un,Rl.ownerDocument),Tn=0;kn[Tn]&&kn[Tn]===Wl[Tn];)Tn++;var bi=[kn[Tn-1],kn[Tn],Wl[Tn]];if(bi[0])for(var ii=bi[0].lastChild;ii;){if(ii===bi[1]){_l=zl,Wl=kn;break}if(ii===bi[2])break;ii=ii.previousSibling}}else Nl=Rl,(parseInt(x(gl=$l).getComputedStyle(gl).zIndex,10)||0)>=(parseInt(x(Nl).getComputedStyle(Nl).zIndex,10)||0)&&(_l=zl);else _l=zl}else _l=zl}return _l}(K);return y.activeDrops[Ka]||null}function Ve(t,o,f){var y=t.dropState,_={enter:null,leave:null,activate:null,deactivate:null,move:null,drop:null};return f.type==="dragstart"&&(_.activate=new Ze(y,f,"dropactivate"),_.activate.target=null,_.activate.dropzone=null),f.type==="dragend"&&(_.deactivate=new Ze(y,f,"dropdeactivate"),_.deactivate.target=null,_.deactivate.dropzone=null),y.rejected||(y.cur.element!==y.prev.element&&(y.prev.dropzone&&(_.leave=new Ze(y,f,"dragleave"),f.dragLeave=_.leave.target=y.prev.element,f.prevDropzone=_.leave.dropzone=y.prev.dropzone),y.cur.dropzone&&(_.enter=new Ze(y,f,"dragenter"),f.dragEnter=y.cur.element,f.dropzone=y.cur.dropzone)),f.type==="dragend"&&y.cur.dropzone&&(_.drop=new Ze(y,f,"drop"),f.dropzone=y.cur.dropzone,f.relatedTarget=y.cur.element),f.type==="dragmove"&&y.cur.dropzone&&(_.move=new Ze(y,f,"dropmove"),f.dropzone=y.cur.dropzone)),_}function Re(t,o){var f=t.dropState,y=f.activeDrops,_=f.cur,O=f.prev;o.leave&&O.dropzone.fire(o.leave),o.enter&&_.dropzone.fire(o.enter),o.move&&_.dropzone.fire(o.move),o.drop&&_.dropzone.fire(o.drop),o.deactivate&&Pa(y,o.deactivate),f.prev.dropzone=_.dropzone,f.prev.element=_.element}function We(t,o){var f=t.interaction,y=t.iEvent,_=t.event;if(y.type==="dragmove"||y.type==="dragend"){var O=f.dropState;o.dynamicDrop&&(O.activeDrops=Sa(o,f.element));var K=y,Q=Xa(f,K,_);O.rejected=O.rejected&&!!Q&&Q.dropzone===O.cur.dropzone&&Q.element===O.cur.element,O.cur.dropzone=Q&&Q.dropzone,O.cur.element=Q&&Q.element,O.events=Ve(f,0,K)}}var Ae={id:"actions/drop",install:function(t){var o=t.actions,f=t.interactStatic,y=t.Interactable,_=t.defaults;t.usePlugin(X),y.prototype.dropzone=function(O){return function(K,Q){if(S.object(Q)){if(K.options.drop.enabled=Q.enabled!==!1,Q.listeners){var ge=Ge(Q.listeners),Ue=Object.keys(ge).reduce(function(ra,Ta){return ra[/^(enter|leave)/.test(Ta)?"drag".concat(Ta):/^(activate|deactivate|move)/.test(Ta)?"drop".concat(Ta):Ta]=ge[Ta],ra},{}),Se=K.options.drop.listeners;Se&&K.off(Se),K.on(Ue),K.options.drop.listeners=Ue}return S.func(Q.ondrop)&&K.on("drop",Q.ondrop),S.func(Q.ondropactivate)&&K.on("dropactivate",Q.ondropactivate),S.func(Q.ondropdeactivate)&&K.on("dropdeactivate",Q.ondropdeactivate),S.func(Q.ondragenter)&&K.on("dragenter",Q.ondragenter),S.func(Q.ondragleave)&&K.on("dragleave",Q.ondragleave),S.func(Q.ondropmove)&&K.on("dropmove",Q.ondropmove),/^(pointer|center)$/.test(Q.overlap)?K.options.drop.overlap=Q.overlap:S.number(Q.overlap)&&(K.options.drop.overlap=Math.max(Math.min(1,Q.overlap),0)),"accept"in Q&&(K.options.drop.accept=Q.accept),"checker"in Q&&(K.options.drop.checker=Q.checker),K}return S.bool(Q)?(K.options.drop.enabled=Q,K):K.options.drop}(this,O)},y.prototype.dropCheck=function(O,K,Q,ge,Ue,Se){return function(ra,Ta,Za,Ka,nl,_l,gl){var Nl=!1;if(!(gl=gl||ra.getRect(_l)))return!!ra.options.drop.checker&&ra.options.drop.checker(Ta,Za,Nl,ra,_l,Ka,nl);var Wl=ra.options.drop.overlap;if(Wl==="pointer"){var zl=De(Ka,nl,"drag"),$l=ta(Ta);$l.x+=zl.x,$l.y+=zl.y;var Rl=$l.x>gl.left&&$l.x<gl.right,rn=$l.y>gl.top&&$l.y<gl.bottom;Nl=Rl&&rn}var or=Ka.getRect(nl);if(or&&Wl==="center"){var un=or.left+or.width/2,kn=or.top+or.height/2;Nl=un>=gl.left&&un<=gl.right&&kn>=gl.top&&kn<=gl.bottom}return or&&S.number(Wl)&&(Nl=Math.max(0,Math.min(gl.right,or.right)-Math.max(gl.left,or.left))*Math.max(0,Math.min(gl.bottom,or.bottom)-Math.max(gl.top,or.top))/(or.width*or.height)>=Wl),ra.options.drop.checker&&(Nl=ra.options.drop.checker(Ta,Za,Nl,ra,_l,Ka,nl)),Nl}(this,O,K,Q,ge,Ue,Se)},f.dynamicDrop=function(O){return S.bool(O)?(t.dynamicDrop=O,f):t.dynamicDrop},ee(o.phaselessTypes,{dragenter:!0,dragleave:!0,dropactivate:!0,dropdeactivate:!0,dropmove:!0,drop:!0}),o.methodDict.drop="dropzone",t.dynamicDrop=!1,_.actions.drop=Ae.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 _=f.dropState;_.activeDrops=[],_.events={},_.activeDrops=Sa(o,f.element),_.events=Ve(f,0,y),_.events.activate&&(Pa(_.activeDrops,_.events.activate),o.fire("actions/drop:start",{interaction:f,dragEvent:y}))}},"interactions:action-move":We,"interactions:after-action-move":function(t,o){var f=t.interaction,y=t.iEvent;if(f.prepared.name==="drag"){var _=f.dropState;Re(f,_.events),o.fire("actions/drop:move",{interaction:f,dragEvent:y}),_.events={}}},"interactions:action-end":function(t,o){if(t.interaction.prepared.name==="drag"){var f=t.interaction,y=t.iEvent;We(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:Sa,getDrop:Xa,getDropEvents:Ve,fireDropEvents:Re,filterEventType:function(t){return t.search("drag")===0||t.search("drop")===0},defaults:{enabled:!1,accept:null,overlap:"pointer"}},Me=Ae;function cl(t){var o=t.interaction,f=t.iEvent,y=t.phase;if(o.prepared.name==="gesture"){var _=o.pointers.map(function(Ue){return Ue.pointer}),O=y==="start",K=y==="end",Q=o.interactable.options.deltaSource;if(f.touches=[_[0],_[1]],O)f.distance=Ma(_,Q),f.box=Oa(_),f.scale=1,f.ds=0,f.angle=fa(_,Q),f.da=0,o.gesture.startDistance=f.distance,o.gesture.startAngle=f.angle;else if(K||o.pointers.length<2){var ge=o.prevEvent;f.distance=ge.distance,f.box=ge.box,f.scale=ge.scale,f.ds=0,f.angle=ge.angle,f.da=0}else f.distance=Ma(_,Q),f.box=Oa(_),f.scale=f.distance/o.gesture.startDistance,f.angle=fa(_,Q),f.ds=f.scale-o.gesture.scale,f.da=f.angle-o.gesture.angle;o.gesture.distance=f.distance,o.gesture.angle=f.angle,S.number(f.scale)&&f.scale!==1/0&&!isNaN(f.scale)&&(o.gesture.scale=f.scale)}}var wl={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(_){return S.object(_)?(this.options.gesture.enabled=_.enabled!==!1,this.setPerAction("gesture",_),this.setOnEvents("gesture",_),this):S.bool(_)?(this.options.gesture.enabled=_,this):this.options.gesture},o.map.gesture=wl,o.methodDict.gesture="gesturable",y.actions.gesture=wl.defaults},listeners:{"interactions:action-start":cl,"interactions:action-move":cl,"interactions:action-end":cl,"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}},Cl=wl;function Pl(t,o,f,y,_,O,K){if(!o)return!1;if(o===!0){var Q=S.number(O.width)?O.width:O.right-O.left,ge=S.number(O.height)?O.height:O.bottom-O.top;if(K=Math.min(K,Math.abs((t==="left"||t==="right"?Q:ge)/2)),Q<0&&(t==="left"?t="right":t==="right"&&(t="left")),ge<0&&(t==="top"?t="bottom":t==="bottom"&&(t="top")),t==="left"){var Ue=Q>=0?O.left:O.right;return f.x<Ue+K}if(t==="top"){var Se=ge>=0?O.top:O.bottom;return f.y<Se+K}if(t==="right")return f.x>(Q>=0?O.right:O.left)-K;if(t==="bottom")return f.y>(ge>=0?O.bottom:O.top)-K}return!!S.element(y)&&(S.element(o)?o===y:U(y,o,_))}function Sl(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 Gl,aa,Ha={id:"actions/resize",before:["actions/drag"],install:function(t){var o=t.actions,f=t.browser,y=t.Interactable,_=t.defaults;Ha.cursors=function(O){return O.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),Ha.defaultMargin=f.supportsTouch||f.supportsPointerEvent?20:10,y.prototype.resizable=function(O){return function(K,Q,ge){return S.object(Q)?(K.options.resize.enabled=Q.enabled!==!1,K.setPerAction("resize",Q),K.setOnEvents("resize",Q),S.string(Q.axis)&&/^x$|^y$|^xy$/.test(Q.axis)?K.options.resize.axis=Q.axis:Q.axis===null&&(K.options.resize.axis=ge.defaults.actions.resize.axis),S.bool(Q.preserveAspectRatio)?K.options.resize.preserveAspectRatio=Q.preserveAspectRatio:S.bool(Q.square)&&(K.options.resize.square=Q.square),K):S.bool(Q)?(K.options.resize.enabled=Q,K):K.options.resize}(this,O,t)},o.map.resize=Ha,o.methodDict.resize="resizable",_.actions.resize=Ha.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 _=f,O=y.rect;y._rects={start:ee({},O),corrected:ee({},O),previous:ee({},O),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},_.edges=y.prepared.edges,_.rect=y._rects.corrected,_.deltaRect=y._rects.delta}})(t),Sl(t)},"interactions:action-move":function(t){(function(o){var f=o.iEvent,y=o.interaction;if(y.prepared.name==="resize"&&y.prepared.edges){var _=f,O=y.interactable.options.resize.invert,K=O==="reposition"||O==="negate",Q=y.rect,ge=y._rects,Ue=ge.start,Se=ge.corrected,ra=ge.delta,Ta=ge.previous;if(ee(Ta,Se),K){if(ee(Se,Q),O==="reposition"){if(Se.top>Se.bottom){var Za=Se.top;Se.top=Se.bottom,Se.bottom=Za}if(Se.left>Se.right){var Ka=Se.left;Se.left=Se.right,Se.right=Ka}}}else Se.top=Math.min(Q.top,Ue.bottom),Se.bottom=Math.max(Q.bottom,Ue.top),Se.left=Math.min(Q.left,Ue.right),Se.right=Math.max(Q.right,Ue.left);for(var nl in Se.width=Se.right-Se.left,Se.height=Se.bottom-Se.top,Se)ra[nl]=Se[nl]-Ta[nl];_.edges=y.prepared.edges,_.rect=Se,_.deltaRect=ra}})(t),Sl(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,_=t.rect,O=t.buttons;if(_){var K=ee({},o.coords.cur.page),Q=f.options.resize;if(Q&&Q.enabled&&(!o.pointerIsDown||!/mouse|pointer/.test(o.pointerType)||(O&Q.mouseButtons)!=0)){if(S.object(Q.edges)){var ge={left:!1,right:!1,top:!1,bottom:!1};for(var Ue in ge)ge[Ue]=Pl(Ue,Q.edges[Ue],K,o._latestPointer.eventTarget,y,_,Q.margin||Ha.defaultMargin);ge.left=ge.left&&!ge.right,ge.top=ge.top&&!ge.bottom,(ge.left||ge.right||ge.top||ge.bottom)&&(t.action={name:"resize",edges:ge})}else{var Se=Q.axis!=="y"&&K.x>_.right-Ha.defaultMargin,ra=Q.axis!=="x"&&K.y>_.bottom-Ha.defaultMargin;(Se||ra)&&(t.action={name:"resize",axes:(Se?"x":"")+(ra?"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,_=Ha.cursors,O=null;if(f)O=_[y+f];else if(o){for(var K="",Q=0,ge=["top","bottom","left","right"];Q<ge.length;Q++){var Ue=ge[Q];o[Ue]&&(K+=Ue)}O=_[K]}return O},filterEventType:function(t){return t.search("resize")===0},defaultMargin:null},ya=Ha,rl={id:"actions",install:function(t){t.usePlugin(Cl),t.usePlugin(ya),t.usePlugin(X),t.usePlugin(Me)}},Aa=0,ol={request:function(t){return Gl(t)},cancel:function(t){return aa(t)},init:function(t){if(Gl=t.requestAnimationFrame,aa=t.cancelAnimationFrame,!Gl)for(var o=["ms","moz","webkit","o"],f=0;f<o.length;f++){var y=o[f];Gl=t["".concat(y,"RequestAnimationFrame")],aa=t["".concat(y,"CancelAnimationFrame")]||t["".concat(y,"CancelRequestAnimationFrame")]}Gl=Gl&&Gl.bind(t),aa=aa&&aa.bind(t),Gl||(Gl=function(_){var O=Date.now(),K=Math.max(0,16-(O-Aa)),Q=t.setTimeout(function(){_(O+K)},K);return Aa=O+K,Q},aa=function(_){return clearTimeout(_)})}},al={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){al.isScrolling=!0,ol.cancel(al.i),t.autoScroll=al,al.interaction=t,al.prevTime=al.now(),al.i=ol.request(al.scroll)},stop:function(){al.isScrolling=!1,al.interaction&&(al.interaction.autoScroll=null),ol.cancel(al.i)},scroll:function(){var t=al.interaction,o=t.interactable,f=t.element,y=t.prepared.name,_=o.options[y].autoScroll,O=ke(_.container,o,f),K=al.now(),Q=(K-al.prevTime)/1e3,ge=_.speed*Q;if(ge>=1){var Ue={x:al.x*ge,y:al.y*ge};if(Ue.x||Ue.y){var Se=Ia(O);S.window(O)?O.scrollBy(Ue.x,Ue.y):O&&(O.scrollLeft+=Ue.x,O.scrollTop+=Ue.y);var ra=Ia(O),Ta={x:ra.x-Se.x,y:ra.y-Se.y};(Ta.x||Ta.y)&&o.fire({type:"autoscroll",target:f,interactable:o,delta:Ta,interaction:t,container:O})}al.prevTime=K}al.isScrolling&&(ol.cancel(al.i),al.i=ol.request(al.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()&&al.check(o.interactable,o.prepared.name))if(o.simulation)al.x=al.y=0;else{var y,_,O,K,Q=o.interactable,ge=o.element,Ue=o.prepared.name,Se=Q.options[Ue].autoScroll,ra=ke(Se.container,Q,ge);if(S.window(ra))K=f.clientX<al.margin,y=f.clientY<al.margin,_=f.clientX>ra.innerWidth-al.margin,O=f.clientY>ra.innerHeight-al.margin;else{var Ta=Ie(ra);K=f.clientX<Ta.left+al.margin,y=f.clientY<Ta.top+al.margin,_=f.clientX>Ta.right-al.margin,O=f.clientY>Ta.bottom-al.margin}al.x=_?1:K?-1:0,al.y=O?1:y?-1:0,al.isScrolling||(al.margin=Se.margin,al.speed=Se.speed,al.start(o))}}};function ke(t,o,f){return(S.string(t)?ca(t,o,f):t)||x(f)}function Ia(t){return S.window(t)&&(t=window.document.body),{x:t.scrollLeft,y:t.scrollTop}}var $a={id:"auto-scroll",install:function(t){var o=t.defaults,f=t.actions;t.autoScroll=al,al.now=function(){return t.now()},f.phaselessTypes.autoscroll=!0,o.perAction.autoScroll=al.defaults},listeners:{"interactions:new":function(t){t.interaction.autoScroll=null},"interactions:destroy":function(t){t.interaction.autoScroll=null,al.stop(),al.interaction&&(al.interaction=null)},"interactions:stop":al.stop,"interactions:action-move":function(t){return al.onInteractionMove(t)}}},Z=$a;function la(t,o){var f=!1;return function(){return f||(L.console.warn(o),f=!0),t.apply(this,arguments)}}function ba(t,o){return t.name=o.name,t.axis=o.axis,t.edges=o.edges,t}function Ke(t){return S.bool(t)?(this.options.styleCursor=t,this):t===null?(delete this.options.styleCursor,this):this.options.styleCursor}function Ua(t){return S.func(t)?(this.options.actionChecker=t,this):t===null?(delete this.options.actionChecker,this):this.options.actionChecker}var ga={id:"auto-start/interactableMethods",install:function(t){var o=t.Interactable;o.prototype.getAction=function(f,y,_,O){var K=function(Q,ge,Ue,Se,ra){var Ta=Q.getRect(Se),Za=ge.buttons||{0:1,1:4,3:8,4:16}[ge.button],Ka={action:null,interactable:Q,interaction:Ue,element:Se,rect:Ta,buttons:Za};return ra.fire("auto-start:check",Ka),Ka.action}(this,y,_,O,t);return this.options.actionChecker?this.options.actionChecker(f,y,K,this,O,_):K},o.prototype.ignoreFrom=la(function(f){return this._backCompatOption("ignoreFrom",f)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),o.prototype.allowFrom=la(function(f){return this._backCompatOption("allowFrom",f)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),o.prototype.actionChecker=Ua,o.prototype.styleCursor=Ke}};function tl(t,o,f,y,_){return o.testIgnoreAllow(o.options[t.name],f,y)&&o.options[t.name].enabled&&ll(o,f,t,_)?t:null}function Le(t,o,f,y,_,O,K){for(var Q=0,ge=y.length;Q<ge;Q++){var Ue=y[Q],Se=_[Q],ra=Ue.getAction(o,f,t,Se);if(ra){var Ta=tl(ra,Ue,Se,O,K);if(Ta)return{action:Ta,interactable:Ue,element:Se}}}return{action:null,interactable:null,element:null}}function ia(t,o,f,y,_){var O=[],K=[],Q=y;function ge(Se){O.push(Se),K.push(Q)}for(;S.element(Q);){O=[],K=[],_.interactables.forEachMatch(Q,ge);var Ue=Le(t,o,f,O,K,y,_);if(Ue.action&&!Ue.interactable.options[Ue.action.name].manualStart)return Ue;Q=Fe(Q)}return{action:null,interactable:null,element:null}}function va(t,o,f){var y=o.action,_=o.interactable,O=o.element;y=y||{name:null},t.interactable=_,t.element=O,ba(t.prepared,y),t.rect=_&&y.name?_.getRect(O):null,Wa(t,f),f.fire("autoStart:prepared",{interaction:t})}function ll(t,o,f,y){var _=t.options,O=_[f.name].max,K=_[f.name].maxPerElement,Q=y.autoStart.maxInteractions,ge=0,Ue=0,Se=0;if(!(O&&K&&Q))return!1;for(var ra=0,Ta=y.interactions.list;ra<Ta.length;ra++){var Za=Ta[ra],Ka=Za.prepared.name;if(Za.interacting()&&(++ge>=Q||Za.interactable===t&&((Ue+=Ka===f.name?1:0)>=O||Za.element===o&&(Se++,Ka===f.name&&Se>=K))))return!1}return Q>0}function Pe(t,o){return S.number(t)?(o.autoStart.maxInteractions=t,this):o.autoStart.maxInteractions}function Dl(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 Wa(t,o){var f=t.interactable,y=t.element,_=t.prepared;if(t.pointerType==="mouse"&&f&&f.options.styleCursor){var O="";if(_.name){var K=f.options[_.name].cursorChecker;O=S.func(K)?K(_,f,y,t._interacting):o.actions.map[_.name].getCursor(_)}Dl(t.element,O||"",o)}else o.autoStart.cursorElement&&Dl(o.autoStart.cursorElement,"",o)}var ml={id:"auto-start/base",before:["actions"],install:function(t){var o=t.interactStatic,f=t.defaults;t.usePlugin(ga),f.base.actionChecker=null,f.base.styleCursor=!0,ee(f.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),o.maxInteractions=function(y){return Pe(y,t)},t.autoStart={maxInteractions:1/0,withinInteractionLimit:ll,cursorElement:null}},listeners:{"interactions:down":function(t,o){var f=t.interaction,y=t.pointer,_=t.event,O=t.eventTarget;f.interacting()||va(f,ia(f,y,_,O,o),o)},"interactions:move":function(t,o){(function(f,y){var _=f.interaction,O=f.pointer,K=f.event,Q=f.eventTarget;_.pointerType!=="mouse"||_.pointerIsDown||_.interacting()||va(_,ia(_,O,K,Q,y),y)})(t,o),function(f,y){var _=f.interaction;if(_.pointerIsDown&&!_.interacting()&&_.pointerWasMoved&&_.prepared.name){y.fire("autoStart:before-start",f);var O=_.interactable,K=_.prepared.name;K&&O&&(O.options[K].manualStart||!ll(O,_.element,_.prepared,y)?_.stop():(_.start(_.prepared,O,_.element),Wa(_,y)))}}(t,o)},"interactions:stop":function(t,o){var f=t.interaction,y=f.interactable;y&&y.options.styleCursor&&Dl(f.element,"",o)}},maxInteractions:Pe,withinInteractionLimit:ll,validateAction:tl},nr=ml,_r={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":function(t,o){var f=t.interaction,y=t.eventTarget,_=t.dx,O=t.dy;if(f.prepared.name==="drag"){var K=Math.abs(_),Q=Math.abs(O),ge=f.interactable.options.drag,Ue=ge.startAxis,Se=K>Q?"x":K<Q?"y":"xy";if(f.prepared.axis=ge.lockAxis==="start"?Se[0]:ge.lockAxis,Se!=="xy"&&Ue!=="xy"&&Ue!==Se){f.prepared.name=null;for(var ra=y,Ta=function(Ka){if(Ka!==f.interactable){var nl=f.interactable.options.drag;if(!nl.manualStart&&Ka.testIgnoreAllow(nl,ra,y)){var _l=Ka.getAction(f.downPointer,f.downEvent,f,ra);if(_l&&_l.name==="drag"&&function(gl,Nl){if(!Nl)return!1;var Wl=Nl.options.drag.startAxis;return gl==="xy"||Wl==="xy"||Wl===gl}(Se,Ka)&&nr.validateAction(_l,Ka,ra,y,o))return Ka}}};S.element(ra);){var Za=o.interactables.forEachMatch(ra,Ta);if(Za){f.prepared.name="drag",f.interactable=Za,f.element=ra;break}ra=Fe(ra)}}}}}};function jl(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 pr={id:"auto-start/hold",install:function(t){var o=t.defaults;t.usePlugin(nr),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=jl(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;jl(o)>0&&(o.prepared.name=null)}},getHoldDuration:jl},Sr=pr,Cr={id:"auto-start",install:function(t){t.usePlugin(nr),t.usePlugin(Sr),t.usePlugin(_r)}},Oe=function(t){return/^(always|never|auto)$/.test(t)?(this.options.preventDefault=t,this):S.bool(t)?(this.options.preventDefault=t?"always":"never",this):this.options.preventDefault};function er(t){var o=t.interaction,f=t.event;o.interactable&&o.interactable.checkAndPreventDefault(f)}var gr={id:"core/interactablePreventDefault",install:function(t){var o=t.Interactable;o.prototype.preventDefault=Oe,o.prototype.checkAndPreventDefault=function(f){return function(y,_,O){var K=y.options.preventDefault;if(K!=="never")if(K!=="always"){if(_.events.supportsPassive&&/^touch(start|move)$/.test(O.type)){var Q=x(O.target).document,ge=_.getDocOptions(Q);if(!ge||!ge.events||ge.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(O.type)||S.element(O.target)&&fe(O.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||O.preventDefault()}else O.preventDefault()}(this,t,f)},t.interactions.docEvents.push({type:"dragstart",listener:function(f){for(var y=0,_=t.interactions.list;y<_.length;y++){var O=_[y];if(O.element&&(O.element===f.target||ce(O.element,f.target)))return void O.interactable.checkAndPreventDefault(f)}}})},listeners:["down","move","up","cancel"].reduce(function(t,o){return t["interactions:".concat(o)]=er,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 Bl(t){var o={};for(var f in t){var y=t[f];S.plainObject(y)?o[f]=Bl(y):S.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,_,O=o.phase,K=this.interaction,Q=function(Ue){var Se=Ue.interactable.options[Ue.prepared.name],ra=Se.modifiers;return ra&&ra.length?ra:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(function(Ta){var Za=Se[Ta];return Za&&Za.enabled&&{options:Za,methods:Za._methods}}).filter(function(Ta){return!!Ta})}(K);this.prepareStates(Q),this.startEdges=ee({},K.edges),this.edges=ee({},this.startEdges),this.startOffset=(y=K.rect,_=f,y?{left:_.x-y.left,top:_.y-y.top,right:y.right-_.x,bottom:y.bottom-_.y}:{left:0,top:0,right:0,bottom:0}),this.startDelta={x:0,y:0};var ge=this.fillArg({phase:O,pageCoords:f,preEnd:!1});return this.result=Ur(),this.startAll(ge),this.result=this.setAll(ge)}},{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 _=y[f];_.methods.start&&(o.state=_,_.methods.start(o))}}},{key:"setAll",value:function(o){var f=o.phase,y=o.preEnd,_=o.skipModifiers,O=o.rect,K=o.edges;o.coords=ee({},o.pageCoords),o.rect=ee({},O),o.edges=ee({},K);for(var Q=_?this.states.slice(_):this.states,ge=Ur(o.coords,o.rect),Ue=0;Ue<Q.length;Ue++){var Se,ra=Q[Ue],Ta=ra.options,Za=ee({},o.coords),Ka=null;(Se=ra.methods)!=null&&Se.set&&this.shouldDo(Ta,y,f)&&(o.state=ra,Ka=ra.methods.set(o),ue(o.edges,o.rect,{x:o.coords.x-Za.x,y:o.coords.y-Za.y})),ge.eventProps.push(Ka)}ee(this.edges,o.edges),ge.delta.x=o.coords.x-o.pageCoords.x,ge.delta.y=o.coords.y-o.pageCoords.y,ge.rectDelta.left=o.rect.left-O.left,ge.rectDelta.right=o.rect.right-O.right,ge.rectDelta.top=o.rect.top-O.top,ge.rectDelta.bottom=o.rect.bottom-O.bottom;var nl=this.result.coords,_l=this.result.rect;if(nl&&_l){var gl=ge.rect.left!==_l.left||ge.rect.right!==_l.right||ge.rect.top!==_l.top||ge.rect.bottom!==_l.bottom;ge.changed=gl||nl.x!==ge.coords.x||nl.y!==ge.coords.y}return ge}},{key:"applyToInteraction",value:function(o){var f=this.interaction,y=o.phase,_=f.coords.cur,O=f.coords.start,K=this.result,Q=this.startDelta,ge=K.delta;y==="start"&&ee(this.startDelta,K.delta);for(var Ue=0,Se=[[O,Q],[_,ge]];Ue<Se.length;Ue++){var ra=Se[Ue],Ta=ra[0],Za=ra[1];Ta.page.x+=Za.x,Ta.page.y+=Za.y,Ta.client.x+=Za.x,Ta.client.y+=Za.y}var Ka=this.result.rectDelta,nl=o.rect||f.rect;nl.left+=Ka.left,nl.right+=Ka.right,nl.top+=Ka.top,nl.bottom+=Ka.bottom,nl.width=nl.right-nl.left,nl.height=nl.bottom-nl.top}},{key:"setAndApply",value:function(o){var f=this.interaction,y=o.phase,_=o.preEnd,O=o.skipModifiers,K=this.setAll(this.fillArg({preEnd:_,phase:y,pageCoords:o.modifiedCoords||f.coords.cur.page}));if(this.result=K,!K.changed&&(!O||O<this.states.length)&&f.interacting())return!1;if(o.modifiedCoords){var Q=f.coords.cur.page,ge={x:o.modifiedCoords.x-Q.x,y:o.modifiedCoords.y-Q.y};K.coords.x+=ge.x,K.coords.y+=ge.y,K.delta.x+=ge.x,K.delta.y+=ge.y}this.applyToInteraction(o)}},{key:"beforeEnd",value:function(o){var f=o.interaction,y=o.event,_=this.states;if(_&&_.length){for(var O=!1,K=0;K<_.length;K++){var Q=_[K];o.state=Q;var ge=Q.options,Ue=Q.methods,Se=Ue.beforeEnd&&Ue.beforeEnd(o);if(Se)return this.endResult=Se,!1;O=O||!O&&this.shouldDo(ge,!0,o.phase,!0)}O&&f.move({event:y,preEnd:!0})}}},{key:"stop",value:function(o){var f=o.interaction;if(this.states&&this.states.length){var y=ee({states:this.states,interactable:f.interactable,element:f.element,rect:null},o);this.fillArg(y);for(var _=0,O=this.states;_<O.length;_++){var K=O[_];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],_=y.options,O=y.methods,K=y.name;this.states.push({options:_,methods:O,index:f,name:K})}return this.states}},{key:"restoreInteractionCoords",value:function(o){var f=o.interaction,y=f.coords,_=f.rect,O=f.modification;if(O.result){for(var K=O.startDelta,Q=O.result,ge=Q.delta,Ue=Q.rectDelta,Se=0,ra=[[y.start,K],[y.cur,ge]];Se<ra.length;Se++){var Ta=ra[Se],Za=Ta[0],Ka=Ta[1];Za.page.x-=Ka.x,Za.page.y-=Ka.y,Za.client.x-=Ka.x,Za.client.y-=Ka.y}_.left-=Ue.left,_.right-=Ue.right,_.top-=Ue.top,_.bottom-=Ue.bottom}}},{key:"shouldDo",value:function(o,f,y,_){return!(!o||o.enabled===!1||_&&!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 Bl(f)}),this.result=Ur(ee({},o.result.coords),ee({},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 Hl(t,o){var f=t.defaults,y={start:t.start,set:t.set,beforeEnd:t.beforeEnd,stop:t.stop},_=function(O){var K=O||{};for(var Q in K.enabled=K.enabled!==!1,f)Q in K||(K[Q]=f[Q]);var ge={options:K,methods:y,name:o,enable:function(){return K.enabled=!0,ge},disable:function(){return K.enabled=!1,ge}};return ge};return o&&typeof o=="string"&&(_._defaults=f,_._methods=y),_}function yr(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":yr,"interactions:action-move":yr,"interactions:action-end":yr,"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)}}},hr=vn,Al={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,_,O,K,Q,ge,Ue){var Se;s(this,f),(Se=o.call(this,y)).relatedTarget=null,Se.screenX=void 0,Se.screenY=void 0,Se.button=void 0,Se.buttons=void 0,Se.ctrlKey=void 0,Se.shiftKey=void 0,Se.altKey=void 0,Se.metaKey=void 0,Se.page=void 0,Se.client=void 0,Se.delta=void 0,Se.rect=void 0,Se.x0=void 0,Se.y0=void 0,Se.t0=void 0,Se.dt=void 0,Se.duration=void 0,Se.clientX0=void 0,Se.clientY0=void 0,Se.velocity=void 0,Se.speed=void 0,Se.swipe=void 0,Se.axes=void 0,Se.preEnd=void 0,Q=Q||y.element;var ra=y.interactable,Ta=(ra&&ra.options||Al).deltaSource,Za=De(ra,Q,O),Ka=K==="start",nl=K==="end",_l=Ka?C(Se):y.prevEvent,gl=Ka?y.coords.start:nl?{page:_l.page,client:_l.client,timeStamp:y.coords.cur.timeStamp}:y.coords.cur;return Se.page=ee({},gl.page),Se.client=ee({},gl.client),Se.rect=ee({},y.rect),Se.timeStamp=gl.timeStamp,nl||(Se.page.x-=Za.x,Se.page.y-=Za.y,Se.client.x-=Za.x,Se.client.y-=Za.y),Se.ctrlKey=_.ctrlKey,Se.altKey=_.altKey,Se.shiftKey=_.shiftKey,Se.metaKey=_.metaKey,Se.button=_.button,Se.buttons=_.buttons,Se.target=Q,Se.currentTarget=Q,Se.preEnd=ge,Se.type=Ue||O+(K||""),Se.interactable=ra,Se.t0=Ka?y.pointers[y.pointers.length-1].downTime:_l.t0,Se.x0=y.coords.start.page.x-Za.x,Se.y0=y.coords.start.page.y-Za.y,Se.clientX0=y.coords.start.client.x-Za.x,Se.clientY0=y.coords.start.client.y-Za.y,Se.delta=Ka||nl?{x:0,y:0}:{x:Se[Ta].x-_l[Ta].x,y:Se[Ta].y-_l[Ta].y},Se.dt=y.coords.delta.timeStamp,Se.duration=Se.timeStamp-Se.t0,Se.velocity=ee({},y.coords.velocity[Ta]),Se.speed=Ja(Se.velocity.x,Se.velocity.y),Se.swipe=nl||K==="inertiastart"?Se.getSwipe():null,Se}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 _=180*Math.atan2(y.prevEvent.velocityY,y.prevEvent.velocityX)/Math.PI;_<0&&(_+=360);var O=112.5<=_&&_<247.5,K=202.5<=_&&_<337.5;return{up:K,down:!K&&22.5<=_&&_<157.5,left:O,right:!O&&(292.5<=_||_<67.5),angle:_,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}(ye);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,_,O){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=_,this.downTarget=O}),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}({}),Jr=0,Wr=function(){function t(o){var f=this,y=o.pointerType,_=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=la(function(Se){this.move(Se)},"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=Jr++,this._scopeFire=_,this.pointerType=y;var O=this;this._proxy={};var K=function(Se){Object.defineProperty(f._proxy,Se,{get:function(){return O[Se]}})};for(var Q in qr)K(Q);var ge=function(Se){Object.defineProperty(f._proxy,Se,{value:function(){return O[Se].apply(O,arguments)}})};for(var Ue in Kr)ge(Ue);this._scopeFire("interactions:new",{interaction:this})}return c(t,[{key:"pointerMoveTolerance",get:function(){return 1}},{key:"pointerDown",value:function(o,f,y){var _=this.updatePointer(o,f,y,!0),O=this.pointers[_];this._scopeFire("interactions:down",{pointer:o,event:f,eventTarget:y,pointerIndex:_,pointerInfo:O,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)&&(ba(this.prepared,o),this.interactable=f,this.element=y,this.rect=f.getRect(y),this.edges=this.prepared.edges?ee({},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 _,O,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&&(_=this.coords.cur.client.x-this.coords.start.client.x,O=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=Ja(_,O)>this.pointerMoveTolerance);var Q,ge,Ue,Se=this.getPointerIndex(o),ra={pointer:o,pointerIndex:Se,pointerInfo:this.pointers[Se],event:f,type:"move",eventTarget:y,dx:_,dy:O,duplicate:K,interaction:this};K||(Q=this.coords.velocity,ge=this.coords.delta,Ue=Math.max(ge.timeStamp/1e3,.001),Q.page.x=ge.page.x/Ue,Q.page.y=ge.page.y/Ue,Q.client.x=ge.client.x/Ue,Q.client.y=ge.client.y/Ue,Q.timeStamp=Ue),this._scopeFire("interactions:move",ra),K||this.simulation||(this.interacting()&&(ra.type=null,this.move(ra)),this.pointerWasMoved&&J(this.coords.prev,this.coords.cur))}},{key:"move",value:function(o){o&&o.event||he(this.coords.delta),(o=ee({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,_){var O=this.getPointerIndex(o);O===-1&&(O=this.updatePointer(o,f,y,!1));var K=/cancel$/i.test(f.type)?"cancel":"up";this._scopeFire("interactions:".concat(K),{pointer:o,pointerIndex:O,pointerInfo:this.pointers[O],event:f,eventTarget:y,type:K,curEventTarget:_,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=He(o);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:oe(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,_){var O,K,Q,ge=He(o),Ue=this.getPointerIndex(o),Se=this.pointers[Ue];return _=_!==!1&&(_||/(down|start)$/i.test(f.type)),Se?Se.pointer=o:(Se=new jr(ge,o,f,null,null),Ue=this.pointers.length,this.pointers.push(Se)),_a(this.coords.cur,this.pointers.map(function(ra){return ra.pointer}),this._now()),O=this.coords.delta,K=this.coords.prev,Q=this.coords.cur,O.page.x=Q.page.x-K.page.x,O.page.y=Q.page.y-K.page.y,O.client.x=Q.client.x-K.client.x,O.client.y=Q.client.y-K.client.y,O.timeStamp=Q.timeStamp-K.timeStamp,_&&(this.pointerIsDown=!0,Se.downTime=this.coords.cur.timeStamp,Se.downTarget=y,H(this.downPointer,o),this.interacting()||(J(this.coords.start,this.coords.cur),J(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:_,pointerInfo:Se,pointerIndex:Ue,interaction:this}),Ue}},{key:"removePointer",value:function(o,f){var y=this.getPointerIndex(o);if(y!==-1){var _=this.pointers[y];this._scopeFire("interactions:remove-pointer",{pointer:o,event:f,eventTarget:null,pointerIndex:y,pointerInfo:_,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,_){return new sn(this,o,this.prepared.name,f,this.element,y,_)}},{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,_=o.preEnd,O=o.type,K=this.rect;if(K&&y==="move"&&(ue(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 Q=o.iEvent=this._createPreparedEvent(f,y,_,O);return this._scopeFire("interactions:action-".concat(y),o),y==="start"&&(this.prevEvent=Q),this._fireEvent(Q),this._scopeFire("interactions:after-action-".concat(y),o),!0}},{key:"_now",value:function(){return Date.now()}}]),t}();function ar(t){lr(t.interaction)}function lr(t){if(!function(f){return!(!f.offset.pending.x&&!f.offset.pending.y)}(t))return!1;var o=t.offset.pending;return hl(t.coords.cur,o),hl(t.coords.delta,o),ue(t.edges,t.rect,o),o.x=0,o.y=0,!0}function Xr(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 hl(t,o){var f=t.page,y=t.client,_=o.x,O=o.y;f.x+=_,f.y+=O,y.x+=_,y.y+=O}Kr.offsetBy="";var ir={id:"offset",before:["modifiers","pointer-events","actions","inertia"],install:function(t){t.Interaction.prototype.offsetBy=Xr},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&&(hl(o.coords.cur,o.offset.total),o.offset.pending.x=0,o.offset.pending.y=0)}(t.interaction)},"interactions:before-action-start":ar,"interactions:before-action-move":ar,"interactions:before-action-end":function(t){var o=t.interaction;if(lr(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}}},Vl=ir,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=ql(f);if(!y||!y.enabled)return!1;var _=f.coords.velocity.client,O=Ja(_.x,_.y),K=this.modification||(this.modification=new $r(f));if(K.copyFrom(f.modification),this.t0=f._now(),this.allowResume=y.allowResume,this.v0=O,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&&O>y.minSpeed&&O>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=ql(this.interaction),_=y.resistance,O=-Math.log(y.endSpeed/this.v0)/_;this.targetOffset={x:(f.x-O)/_,y:(f.y-O)/_},this.te=O,this.lambda_v0=_/this.v0,this.one_ve_v0=1-y.endSpeed/this.v0;var K=this.modification,Q=this.modifierArg;Q.pageCoords={x:this.startCoords.x+this.targetOffset.x,y:this.startCoords.y+this.targetOffset.y},K.result=K.setAll(Q),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=ol.request(function(){f.active&&o()})}},{key:"inertiaTick",value:function(){var o,f,y,_,O,K,Q,ge=this,Ue=this.interaction,Se=ql(Ue).resistance,ra=(Ue._now()-this.t0)/1e3;if(ra<this.te){var Ta,Za=1-(Math.exp(-Se*ra)-this.lambda_v0)/this.one_ve_v0;this.isModified?(o=0,f=0,y=this.targetOffset.x,_=this.targetOffset.y,O=this.modifiedOffset.x,K=this.modifiedOffset.y,Ta={x:Vr(Q=Za,o,y,O),y:Vr(Q,f,_,K)}):Ta={x:this.targetOffset.x*Za,y:this.targetOffset.y*Za};var Ka={x:Ta.x-this.currentOffset.x,y:Ta.y-this.currentOffset.y};this.currentOffset.x+=Ka.x,this.currentOffset.y+=Ka.y,Ue.offsetBy(Ka),Ue.move(),this.onNextFrame(function(){return ge.inertiaTick()})}else Ue.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,_=ql(f).smoothEndDuration;if(y<_){var O={x:br(y,0,this.targetOffset.x,_),y:br(y,0,this.targetOffset.y,_)},K={x:O.x-this.currentOffset.x,y:O.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,_=o.eventTarget,O=this.interaction;O.offsetBy({x:-this.currentOffset.x,y:-this.currentOffset.y}),O.updatePointer(f,y,_,!0),O._doPhase({interaction:O,event:y,phase:"resume"}),J(O.coords.prev,O.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,ol.cancel(this.timeout)}}]),t}();function ql(t){var o=t.interactable,f=t.prepared;return o&&o.options&&f.name&&o.options[f.name].inertia}var fr={id:"inertia",before:["modifiers","actions"],install:function(t){var o=t.defaults;t.usePlugin(Vl),t.usePlugin(hr),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 _=f;S.element(_);){if(_===o.element){y.resume(t);break}_=Fe(_)}},"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":yr,"interactions:action-inertiastart":yr,"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 _=1-t;return _*_*o+2*_*t*f+t*t*y}function br(t,o,f,y){return-f*(t/=y)*(t-2)+o}var cn=fr;function Zr(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=ee({},o||{})}return c(t,[{key:"fire",value:function(o){var f,y=this.global;(f=this.types[o.type])&&Zr(o,f),!o.propagationStopped&&y&&(f=y[o.type])&&Zr(o,f)}},{key:"on",value:function(o,f){var y=Ge(o,f);for(o in y)this.types[o]=Ne(this.types[o]||[],y[o])}},{key:"off",value:function(o,f){var y=Ge(o,f);for(o in y){var _=this.types[o];if(_&&_.length)for(var O=0,K=y[o];O<K.length;O++){var Q=K[O],ge=_.indexOf(Q);ge!==-1&&_.splice(ge,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 S.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={},_=[],O={add:K,remove:Q,addDelegate:function(Se,ra,Ta,Za,Ka){var nl=Dn(Ka);if(!y[Ta]){y[Ta]=[];for(var _l=0;_l<_.length;_l++){var gl=_[_l];K(gl,Ta,ge),K(gl,Ta,Ue,!0)}}var Nl=y[Ta],Wl=Xe(Nl,function(zl){return zl.selector===Se&&zl.context===ra});Wl||(Wl={selector:Se,context:ra,listeners:[]},Nl.push(Wl)),Wl.listeners.push({func:Za,options:nl})},removeDelegate:function(Se,ra,Ta,Za,Ka){var nl,_l=Dn(Ka),gl=y[Ta],Nl=!1;if(gl)for(nl=gl.length-1;nl>=0;nl--){var Wl=gl[nl];if(Wl.selector===Se&&Wl.context===ra){for(var zl=Wl.listeners,$l=zl.length-1;$l>=0;$l--){var Rl=zl[$l];if(Rl.func===Za&&In(Rl.options,_l)){zl.splice($l,1),zl.length||(gl.splice(nl,1),Q(ra,Ta,ge),Q(ra,Ta,Ue,!0)),Nl=!0;break}}if(Nl)break}}},delegateListener:ge,delegateUseCapture:Ue,delegatedEvents:y,documents:_,targets:f,supportsOptions:!1,supportsPassive:!1};function K(Se,ra,Ta,Za){if(Se.addEventListener){var Ka=Dn(Za),nl=Xe(f,function(_l){return _l.eventTarget===Se});nl||(nl={eventTarget:Se,events:{}},f.push(nl)),nl.events[ra]||(nl.events[ra]=[]),Xe(nl.events[ra],function(_l){return _l.func===Ta&&In(_l.options,Ka)})||(Se.addEventListener(ra,Ta,O.supportsOptions?Ka:Ka.capture),nl.events[ra].push({func:Ta,options:Ka}))}}function Q(Se,ra,Ta,Za){if(Se.addEventListener&&Se.removeEventListener){var Ka=oe(f,function(rn){return rn.eventTarget===Se}),nl=f[Ka];if(nl&&nl.events)if(ra!=="all"){var _l=!1,gl=nl.events[ra];if(gl){if(Ta==="all"){for(var Nl=gl.length-1;Nl>=0;Nl--){var Wl=gl[Nl];Q(Se,ra,Wl.func,Wl.options)}return}for(var zl=Dn(Za),$l=0;$l<gl.length;$l++){var Rl=gl[$l];if(Rl.func===Ta&&In(Rl.options,zl)){Se.removeEventListener(ra,Ta,O.supportsOptions?zl:zl.capture),gl.splice($l,1),gl.length===0&&(delete nl.events[ra],_l=!0);break}}}_l&&!Object.keys(nl.events).length&&f.splice(Ka,1)}else for(ra in nl.events)nl.events.hasOwnProperty(ra)&&Q(Se,ra,"all")}}function ge(Se,ra){for(var Ta=Dn(ra),Za=new Fn(Se),Ka=y[Se.type],nl=Te(Se)[0],_l=nl;S.element(_l);){for(var gl=0;gl<Ka.length;gl++){var Nl=Ka[gl],Wl=Nl.selector,zl=Nl.context;if(fe(_l,Wl)&&ce(zl,nl)&&ce(zl,_l)){var $l=Nl.listeners;Za.currentTarget=_l;for(var Rl=0;Rl<$l.length;Rl++){var rn=$l[Rl];In(rn.options,Ta)&&rn.func(Za)}}}_l=Fe(_l)}}function Ue(Se){return ge(Se,!0)}return(o=t.document)==null||o.createElement("div").addEventListener("test",null,{get capture(){return O.supportsOptions=!0},get passive(){return O.supportsPassive=!0}}),t.events=O,O}},mn={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search:function(t){for(var o=0,f=mn.methodOrder;o<f.length;o++){var y=f[o],_=mn[y](t);if(_)return _}return null},simulationResume:function(t){var o=t.pointerType,f=t.eventType,y=t.eventTarget,_=t.scope;if(!/down|start/i.test(f))return null;for(var O=0,K=_.interactions.list;O<K.length;O++){var Q=K[O],ge=y;if(Q.simulation&&Q.simulation.allowResume&&Q.pointerType===o)for(;ge;){if(ge===Q.element)return Q;ge=Fe(ge)}}return null},mouseOrPen:function(t){var o,f=t.pointerId,y=t.pointerType,_=t.eventType,O=t.scope;if(y!=="mouse"&&y!=="pen")return null;for(var K=0,Q=O.interactions.list;K<Q.length;K++){var ge=Q[K];if(ge.pointerType===y){if(ge.simulation&&!On(ge,f))continue;if(ge.interacting())return ge;o||(o=ge)}}if(o)return o;for(var Ue=0,Se=O.interactions.list;Ue<Se.length;Ue++){var ra=Se[Ue];if(!(ra.pointerType!==y||/down/i.test(_)&&ra.simulation))return ra}return null},hasPointer:function(t){for(var o=t.pointerId,f=0,y=t.scope.interactions.list;f<y.length;f++){var _=y[f];if(On(_,o))return _}return null},idle:function(t){for(var o=t.pointerType,f=0,y=t.scope.interactions.list;f<y.length;f++){var _=y[f];if(_.pointers.length===1){var O=_.interactable;if(O&&(!O.options.gesture||!O.options.gesture.enabled))continue}else if(_.pointers.length>=2)continue;if(!_.interacting()&&o===_.pointerType)return _}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,_=Ba(f),O=Te(f),K=O[0],Q=O[1],ge=[];if(/^touch/.test(f.type)){o.prevTouchTime=o.now();for(var Ue=0,Se=f.changedTouches;Ue<Se.length;Ue++){var ra=Se[Ue],Ta={pointer:ra,pointerId:He(ra),pointerType:_,eventType:f.type,eventTarget:K,curEventTarget:Q,scope:o},Za=_n(Ta);ge.push([Ta.pointer,Ta.eventTarget,Ta.curEventTarget,Za])}}else{var Ka=!1;if(!Y.supportsPointerEvent&&/mouse/.test(f.type)){for(var nl=0;nl<y.length&&!Ka;nl++)Ka=y[nl].pointerType!=="mouse"&&y[nl].pointerIsDown;Ka=Ka||o.now()-o.prevTouchTime<500||f.timeStamp===0}if(!Ka){var _l={pointer:f,pointerId:He(f),pointerType:_,eventType:f.type,curEventTarget:Q,eventTarget:K,scope:o},gl=_n(_l);ge.push([_l.pointer,_l.eventTarget,_l.curEventTarget,gl])}}for(var Nl=0;Nl<ge.length;Nl++){var Wl=ge[Nl],zl=Wl[0],$l=Wl[1],Rl=Wl[2];Wl[3][t](zl,f,$l,Rl)}}}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,_=t.options,O=y.interactions.docEvents,K=y.events,Q=K[o];for(var ge in y.browser.isIOS&&!_.events&&(_.events={passive:!1}),K.delegatedEvents)Q(f,ge,K.delegateListener),Q(f,ge,K.delegateUseCapture,!0);for(var Ue=_&&_.events,Se=0;Se<O.length;Se++){var ra=O[Se];Q(f,ra.type,ra.listener,Ue)}}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 _,O=Y.pEventTypes;function K(){for(var Q=0,ge=t.interactions.list;Q<ge.length;Q++){var Ue=ge[Q];if(Ue.pointerIsDown&&Ue.pointerType==="touch"&&!Ue._interacting)for(var Se=function(){var Za=Ta[ra];t.documents.some(function(Ka){return ce(Ka.doc,Za.downTarget)})||Ue.removePointer(Za.pointer,Za.event)},ra=0,Ta=Ue.pointers;ra<Ta.length;ra++)Se()}}(_=F.PointerEvent?[{type:O.down,listener:K},{type:O.down,listener:o.pointerDown},{type:O.move,listener:o.pointerMove},{type:O.up,listener:o.pointerUp},{type:O.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(Q){for(var ge=0,Ue=t.interactions.list;ge<Ue.length;ge++)Ue[ge].documentBlur(Q)}}),t.prevTouchTime=0,t.Interaction=function(Q){m(Ue,Q);var ge=M(Ue);function Ue(){return s(this,Ue),ge.apply(this,arguments)}return c(Ue,[{key:"pointerMoveTolerance",get:function(){return t.interactions.pointerMoveTolerance},set:function(Se){t.interactions.pointerMoveTolerance=Se}},{key:"_now",value:function(){return t.now()}}]),Ue}(Wr),t.interactions={list:[],new:function(Q){Q.scopeFire=function(Ue,Se){return t.fire(Ue,Se)};var ge=new t.Interaction(Q);return t.interactions.list.push(ge),ge},listeners:o,docEvents:_,pointerMoveTolerance:1},t.usePlugin(gr)},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 _=o.interactions.list[y];_.interactable===f&&(_.stop(),o.fire("interactions:destroy",{interaction:_}),_.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(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=_,this.set(f)}return c(t,[{key:"_defaults",get:function(){return{base:{},perAction:{},actions:{}}}},{key:"setOnEvents",value:function(o,f){return S.func(f.onstart)&&this.on("".concat(o,"start"),f.onstart),S.func(f.onmove)&&this.on("".concat(o,"move"),f.onmove),S.func(f.onend)&&this.on("".concat(o,"end"),f.onend),S.func(f.oninertiastart)&&this.on("".concat(o,"inertiastart"),f.oninertiastart),this}},{key:"updatePerActionListeners",value:function(o,f,y){var _,O=this,K=(_=this._actions.map[o])==null?void 0:_.filterEventType,Q=function(ge){return(K==null||K(ge))&&Dr(ge,O._actions)};(S.array(f)||S.object(f))&&this._onOff(Nn.Off,o,f,void 0,Q),(S.array(y)||S.object(y))&&this._onOff(Nn.On,o,y,void 0,Q)}},{key:"setPerAction",value:function(o,f){var y=this._defaults;for(var _ in f){var O=_,K=this.options[o],Q=f[O];O==="listeners"&&this.updatePerActionListeners(o,K.listeners,Q),S.array(Q)?K[O]=ae(Q):S.plainObject(Q)?(K[O]=ee(K[O]||{},Bl(Q)),S.object(y.perAction[O])&&"enabled"in y.perAction[O]&&(K[O].enabled=Q.enabled!==!1)):S.bool(Q)&&S.object(y.perAction[O])?K[O].enabled=Q:K[O]=Q}}},{key:"getRect",value:function(o){return o=o||(S.element(this.target)?this.target:null),S.string(this.target)&&(o=o||this._context.querySelector(this.target)),je(o)}},{key:"rectChecker",value:function(o){var f=this;return S.func(o)?(this.getRect=function(y){var _=ee({},o.apply(f,y));return"width"in _||(_.width=_.right-_.left,_.height=_.bottom-_.top),_},this):o===null?(delete this.getRect,this):this.getRect}},{key:"_backCompatOption",value:function(o,f){if(Ca(f)||S.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 S.string(o)?Array.from(this._context.querySelectorAll(o)):S.func(o)&&o.getAllElements?o.getAllElements():S.element(o)?[o]:[]}},{key:"context",value:function(){return this._context}},{key:"inContext",value:function(o){return this._context===o.ownerDocument||ce(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||!!S.element(y)&&(S.string(o)?U(y,o,f):!!S.element(o)&&ce(o,y))}},{key:"testIgnore",value:function(o,f,y){return!(!o||!S.element(y))&&(S.string(o)?U(y,o,f):!!S.element(o)&&ce(o,y))}},{key:"fire",value:function(o){return this.events.fire(o),this}},{key:"_onOff",value:function(o,f,y,_,O){S.object(f)&&!S.array(f)&&(_=y,y=null);var K=Ge(f,y,O);for(var Q in K){Q==="wheel"&&(Q=Y.wheelEvent);for(var ge=0,Ue=K[Q];ge<Ue.length;ge++){var Se=Ue[ge];Dr(Q,this._actions)?this.events[o===Nn.On?"on":"off"](Q,Se):S.string(this.target)?this._scopeEvents[o===Nn.On?"addDelegate":"removeDelegate"](this.target,this._context,Q,Se,_):this._scopeEvents[o===Nn.On?"add":"remove"](this.target,Q,Se,_)}}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 S.object(o)||(o={}),this.options=Bl(f.base),this._actions.methodDict){var _=y,O=this._actions.methodDict[_];this.options[_]={},this.setPerAction(_,ee(ee({},f.perAction),f.actions[_])),this[O](o[_])}for(var K in o)K!=="getRect"?S.func(this[K])&&this[K](o[K]):this.rectChecker(o.getRect);return this}},{key:"unset",value:function(){if(S.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 _=f[y],O=_.selector,K=_.context,Q=_.listeners;O===this.target&&K===this._context&&f.splice(y,1);for(var ge=Q.length-1;ge>=0;ge--)this._scopeEvents.removeDelegate(this.target,this._context,o,Q[ge][0],Q[ge][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 _=y.interactable,O=_.target,K=S.string(O)?f.selectorMap[O]:O[f.scope.id],Q=oe(K,function(ge){return ge===_});K.splice(Q,1)}})}return c(t,[{key:"new",value:function(o,f){f=ee(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),S.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.string(o),O=_?this.selectorMap[o]:o[this.scope.id];if(O)return Xe(O,function(K){return K._context===y&&(_||K.inContext(o))})}},{key:"forEachMatch",value:function(o,f){for(var y=0,_=this.list;y<_.length;y++){var O=_[y],K=void 0;if((S.string(O.target)?S.element(o)&&fe(o,O.target):o===O.target)&&O.inContext(o)&&(K=f(O)),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=Bl(Al),this.Eventable=Jn,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=function(y){var _=function O(K,Q){var ge=y.interactables.getExisting(K,Q);return ge||((ge=y.interactables.new(K,Q)).events.global=O.globalEvents),ge};return _.getPointerAverage=ma,_.getTouchBBox=Oa,_.getTouchDistance=Ma,_.getTouchAngle=fa,_.getElementRect=je,_.getElementClientRect=Ie,_.matchesSelector=fe,_.closest=Ce,_.globalEvents={},_.version="1.10.27",_.scope=y,_.use=function(O,K){return this.scope.usePlugin(O,K),this},_.isSet=function(O,K){return!!this.scope.interactables.get(O,K&&K.context)},_.on=la(function(O,K,Q){if(S.string(O)&&O.search(" ")!==-1&&(O=O.trim().split(/ +/)),S.array(O)){for(var ge=0,Ue=O;ge<Ue.length;ge++){var Se=Ue[ge];this.on(Se,K,Q)}return this}if(S.object(O)){for(var ra in O)this.on(ra,O[ra],K);return this}return Dr(O,this.scope.actions)?this.globalEvents[O]?this.globalEvents[O].push(K):this.globalEvents[O]=[K]:this.scope.events.add(this.scope.document,O,K,{options:Q}),this},"The interact.on() method is being deprecated"),_.off=la(function(O,K,Q){if(S.string(O)&&O.search(" ")!==-1&&(O=O.trim().split(/ +/)),S.array(O)){for(var ge=0,Ue=O;ge<Ue.length;ge++){var Se=Ue[ge];this.off(Se,K,Q)}return this}if(S.object(O)){for(var ra in O)this.off(ra,O[ra],K);return this}var Ta;return Dr(O,this.scope.actions)?O in this.globalEvents&&(Ta=this.globalEvents[O].indexOf(K))!==-1&&this.globalEvents[O].splice(Ta,1):this.scope.events.remove(this.scope.document,O,K,Q),this},"The interact.off() method is being deprecated"),_.debug=function(){return this.scope},_.supportsTouch=function(){return Y.supportsTouch},_.supportsPointerEvent=function(){return Y.supportsPointerEvent},_.stop=function(){for(var O=0,K=this.scope.interactions.list;O<K.length;O++)K[O].stop();return this},_.pointerMoveTolerance=function(O){return S.number(O)?(this.scope.interactions.pointerMoveTolerance=O,this):this.scope.interactions.pointerMoveTolerance},_.addDocument=function(O,K){this.scope.addDocument(O,K)},_.removeDocument=function(O){this.scope.removeDocument(O)},_}(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(O,y);var _=M(O);function O(){return s(this,O),_.apply(this,arguments)}return c(O,[{key:"_defaults",get:function(){return f.defaults}},{key:"set",value:function(K){return k(g(O.prototype),"set",this).call(this,K),f.fire("interactable:set",{options:K,interactable:this}),this}},{key:"unset",value:function(){k(g(O.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}))}}]),O}(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,_=this.listenerMaps;y<_.length;y++){var O=_[y].map[o];if(O&&O(f,this,o)===!1)return!1}}},{key:"init",value:function(o){return this.isInitialized?this:function(f,y){return f.isInitialized=!0,S.window(y)&&E(y),F.init(y),Y.init(y),ol.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,_=this.listenerMaps.length,O=o.before.reduce(function(Q,ge){return Q[ge]=!0,Q[Ii(ge)]=!0,Q},{});y<_;y++){var K=this.listenerMaps[y].id;if(K&&(O[K]||O[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?ee({},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),_=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:_})}},{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 _=y[0],O=y[1];return _ in t||O in t}),f=function(y,_){for(var O=t.range,K=t.limits,Q=K===void 0?{left:-1/0,right:1/0,top:-1/0,bottom:1/0}:K,ge=t.offset,Ue=ge===void 0?{x:0,y:0}:ge,Se={range:O,grid:t,x:null,y:null},ra=0;ra<o.length;ra++){var Ta=o[ra],Za=Ta[0],Ka=Ta[1],nl=Math.round((y-Ue.x)/t[Za]),_l=Math.round((_-Ue.y)/t[Ka]);Se[Za]=Math.max(Q.left,Math.min(Q.right,nl*t[Za]+Ue.x)),Se[Ka]=Math.max(Q.top,Math.min(Q.bottom,_l*t[Ka]+Ue.y))}return Se};return f.grid=t,f.coordFields=o,f}}),Oi={id:"snappers",install:function(t){var o=t.interactStatic;o.snappers=ee(o.snappers||{},Go),o.createSnapGrid=o.snappers.grid}},Yo=Oi,Li={start:function(t){var o=t.state,f=t.rect,y=t.edges,_=t.pageCoords,O=o.options,K=O.ratio,Q=O.enabled,ge=o.options,Ue=ge.equalDelta,Se=ge.modifiers;K==="preserve"&&(K=f.width/f.height),o.startCoords=ee({},_),o.startRect=ee({},f),o.ratio=K,o.equalDelta=Ue;var ra=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=(ra.left?1:-1)*(ra.top?1:-1);o.edgeSign={x:Ta,y:Ta}}else o.edgeSign={x:ra.left?-1:1,y:ra.top?-1:1};if(Q!==!1&&ee(y,ra),Se!=null&&Se.length){var Za=new $r(t.interaction);Za.copyFrom(t.interaction.modification),Za.prepareStates(Se),o.subModification=Za,Za.startAll(r({},t))}},set:function(t){var o=t.state,f=t.rect,y=t.coords,_=o.linkedEdges,O=ee({},y),K=o.equalDelta?ao:lo;if(ee(t.edges,_),K(o,o.xIsPrimaryAxis,y,f),!o.subModification)return null;var Q=ee({},f);ue(_,Q,{x:y.x-O.x,y:y.y-O.y});var ge=o.subModification.setAll(r(r({},t),{},{rect:Q,edges:_,pageCoords:y,prevCoords:y,prevRect:Q})),Ue=ge.delta;return ge.changed&&(K(o,Math.abs(Ue.x)>Math.abs(Ue.y),ge.coords,ge.rect),ee(y,ge.coords)),ge.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function ao(t,o,f){var y=t.startCoords,_=t.edgeSign;o?f.y=y.y+(f.x-y.x)*_.y:f.x=y.x+(f.y-y.y)*_.x}function lo(t,o,f,y){var _=t.startRect,O=t.startCoords,K=t.ratio,Q=t.edgeSign;if(o){var ge=y.width/K;f.y=O.y+(ge-_.height)*Q.y}else{var Ue=y.height*K;f.x=O.x+(Ue-_.width)*Q.x}}var Jo=Hl(Li,"aspectRatio"),ro=function(){};ro._defaults={};var hi=ro;function bn(t,o,f){return S.func(t)?de(t,o.interactable,o.element,[f.x,f.y,o]):de(t,o.interactable,o.element)}var Qn={start:function(t){var o=t.rect,f=t.startOffset,y=t.state,_=t.interaction,O=t.pageCoords,K=y.options,Q=K.elementRect,ge=ee({left:0,top:0,right:0,bottom:0},K.offset||{});if(o&&Q){var Ue=bn(K.restriction,_,O);if(Ue){var Se=Ue.right-Ue.left-o.width,ra=Ue.bottom-Ue.top-o.height;Se<0&&(ge.left+=Se,ge.right+=Se),ra<0&&(ge.top+=ra,ge.bottom+=ra)}ge.left+=f.left-o.width*Q.left,ge.top+=f.top-o.height*Q.top,ge.right+=f.right-o.width*(1-Q.right),ge.bottom+=f.bottom-o.height*(1-Q.bottom)}y.offset=ge},set:function(t){var o=t.coords,f=t.interaction,y=t.state,_=y.options,O=y.offset,K=bn(_.restriction,f,o);if(K){var Q=function(ge){return!ge||"left"in ge&&"top"in ge||((ge=ee({},ge)).left=ge.x||0,ge.top=ge.y||0,ge.right=ge.right||ge.left+ge.width,ge.bottom=ge.bottom||ge.top+ge.height),ge}(K);o.x=Math.max(Math.min(Q.right-O.right,o.x),Q.left+O.left),o.y=Math.max(Math.min(Q.bottom-O.bottom,o.y),Q.top+O.top)}},defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}},Ri=Hl(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 _=y[f];_ in t||(t[_]=o[_])}return t}var ei={noInner:no,noOuter:io,start:function(t){var o,f=t.interaction,y=t.startOffset,_=t.state,O=_.options;O&&(o=pa(bn(O.offset,f,f.coords.start.page))),o=o||{x:0,y:0},_.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,_=t.state,O=_.offset,K=_.options;if(f){var Q=ee({},o),ge=bn(K.inner,y,Q)||{},Ue=bn(K.outer,y,Q)||{};oo(ge,no),oo(Ue,io),f.top?o.y=Math.min(Math.max(Ue.top+O.top,Q.y),ge.top+O.top):f.bottom&&(o.y=Math.max(Math.min(Ue.bottom+O.bottom,Q.y),ge.bottom+O.bottom)),f.left?o.x=Math.min(Math.max(Ue.left+O.left,Q.x),ge.left+O.left):f.right&&(o.x=Math.max(Math.min(Ue.right+O.right,Q.x),ge.right+O.right))}},defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}},to=Hl(ei,"restrictEdges"),ai=ee({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(t){}},Qn.defaults),so=Hl({start:Qn.start,set:Qn.set,defaults:ai},"restrictRect"),co={width:-1/0,height:-1/0},li={width:1/0,height:1/0},Xo=Hl({start:function(t){return ei.start(t)},set:function(t){var o=t.interaction,f=t.state,y=t.rect,_=t.edges,O=f.options;if(_){var K=we(bn(O.min,o,t.coords))||co,Q=we(bn(O.max,o,t.coords))||li;f.options={endOnly:O.endOnly,inner:ee({},ei.noInner),outer:ee({},ei.noOuter)},_.top?(f.options.inner.top=y.bottom-K.height,f.options.outer.top=y.bottom-Q.height):_.bottom&&(f.options.inner.bottom=y.top+K.height,f.options.outer.bottom=y.top+Q.height),_.left?(f.options.inner.left=y.right-K.width,f.options.outer.left=y.right-Q.width):_.right&&(f.options.inner.right=y.left+K.width,f.options.outer.right=y.left+Q.width),ei.set(t),f.options=O}},defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize"),vi={start:function(t){var o,f=t.interaction,y=t.interactable,_=t.element,O=t.rect,K=t.state,Q=t.startOffset,ge=K.options,Ue=ge.offsetWithOrigin?function(Ta){var Za=Ta.interaction.element,Ka=pa(de(Ta.state.options.origin,null,null,[Za])),nl=Ka||De(Ta.interactable,Za,Ta.interaction.prepared.name);return nl}(t):{x:0,y:0};if(ge.offset==="startCoords")o={x:f.coords.start.page.x,y:f.coords.start.page.y};else{var Se=de(ge.offset,y,_,[f]);(o=pa(Se)||{x:0,y:0}).x+=Ue.x,o.y+=Ue.y}var ra=ge.relativePoints;K.offsets=O&&ra&&ra.length?ra.map(function(Ta,Za){return{index:Za,relativePoint:Ta,x:Q.left-O.width*Ta.x+o.x,y:Q.top-O.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,_=y.options,O=y.offsets,K=De(o.interactable,o.element,o.prepared.name),Q=ee({},f),ge=[];_.offsetWithOrigin||(Q.x-=K.x,Q.y-=K.y);for(var Ue=0,Se=O;Ue<Se.length;Ue++)for(var ra=Se[Ue],Ta=Q.x-ra.x,Za=Q.y-ra.y,Ka=0,nl=_.targets.length;Ka<nl;Ka++){var _l=_.targets[Ka],gl=void 0;(gl=S.func(_l)?_l(Ta,Za,o._proxy,ra,Ka):_l)&&ge.push({x:(S.number(gl.x)?gl.x:Ta)+ra.x,y:(S.number(gl.y)?gl.y:Za)+ra.y,range:S.number(gl.range)?gl.range:_.range,source:_l,index:Ka,offset:ra})}for(var Nl={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}},Wl=0;Wl<ge.length;Wl++){var zl=ge[Wl],$l=zl.range,Rl=zl.x-Q.x,rn=zl.y-Q.y,or=Ja(Rl,rn),un=or<=$l;$l===1/0&&Nl.inRange&&Nl.range!==1/0&&(un=!1),Nl.target&&!(un?Nl.inRange&&$l!==1/0?or/$l<Nl.distance/Nl.range:$l===1/0&&Nl.range!==1/0||or<Nl.distance:!Nl.inRange&&or<Nl.distance)||(Nl.target=zl,Nl.distance=or,Nl.range=$l,Nl.inRange=un,Nl.delta.x=Rl,Nl.delta.y=rn)}return Nl.inRange&&(f.x=Nl.target.x,f.y=Nl.target.y),y.closest=Nl,Nl},defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}},ri=Hl(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,_=f.options,O=f.offsets,K={x:y.x-O[0].x,y:y.y-O[0].y};f.options=ee({},_),f.options.targets=[];for(var Q=0,ge=_.targets||[];Q<ge.length;Q++){var Ue=ge[Q],Se=void 0;if(Se=S.func(Ue)?Ue(K.x,K.y,o):Ue){for(var ra=0,Ta=f.targetFields;ra<Ta.length;ra++){var Za=Ta[ra],Ka=Za[0],nl=Za[1];if(Ka in Se||nl in Se){Se.x=Se[Ka],Se.y=Se[nl];break}}f.options.targets.push(Se)}}var _l=vi.set(t);return f.options=_,_l},defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}},Zo=Hl(mi,"snapSize"),$i={aspectRatio:Jo,restrictEdges:to,restrict:Ri,restrictRect:so,restrictSize:Xo,snapEdges:Hl({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:ee(Bl(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(hr),t.usePlugin(Yo),o.modifiers=$i,$i){var y=$i[f],_=y._defaults,O=y._methods;_._methods=O,t.defaults.perAction[f]=_}}},et=Qo,uo=function(t){m(f,t);var o=M(f);function f(y,_,O,K,Q,ge){var Ue;if(s(this,f),H(C(Ue=o.call(this,Q)),O),O!==_&&H(C(Ue),_),Ue.timeStamp=ge,Ue.originalEvent=O,Ue.type=y,Ue.pointerId=He(_),Ue.pointerType=Ba(_),Ue.target=K,Ue.currentTarget=null,y==="tap"){var Se=Q.getPointerIndex(_);Ue.dt=Ue.timeStamp-Q.pointers[Se].downTime;var ra=Ue.timeStamp-Q.tapTime;Ue.double=!!Q.prevTap&&Q.prevTap.type!=="doubletap"&&Q.prevTap.target===Ue.target&&ra<500}else y==="doubletap"&&(Ue.dt=_.timeStamp-Q.tapTime,Ue.double=!0);return Ue}return c(f,[{key:"_subtractOrigin",value:function(y){var _=y.x,O=y.y;return this.pageX-=_,this.pageY-=O,this.clientX-=_,this.clientY-=O,this}},{key:"_addOrigin",value:function(y){var _=y.x,O=y.y;return this.pageX+=_,this.pageY+=O,this.clientX+=_,this.clientY+=O,this}},{key:"preventDefault",value:function(){this.originalEvent.preventDefault()}}]),f}(ye),ni={id:"pointer-events/base",before:["inertia","modifiers","auto-start","actions"],install:function(t){t.pointerEvents=ni,t.defaults.actions.pointerEvents=ni.defaults,ee(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,_=t.event,O=t.eventTarget;t.duplicate||f.pointerIsDown&&!f.pointerWasMoved||(f.pointerIsDown&&Pi(t),An({interaction:f,pointer:y,event:_,eventTarget:O,type:"move"},o))},"interactions:down":function(t,o){(function(f,y){for(var _=f.interaction,O=f.pointer,K=f.event,Q=f.eventTarget,ge=f.pointerIndex,Ue=_.pointers[ge].hold,Se=na(Q),ra={interaction:_,pointer:O,event:K,eventTarget:Q,type:"hold",targets:[],path:Se,node:null},Ta=0;Ta<Se.length;Ta++){var Za=Se[Ta];ra.node=Za,y.fire("pointerEvents:collect-targets",ra)}if(ra.targets.length){for(var Ka=1/0,nl=0,_l=ra.targets;nl<_l.length;nl++){var gl=_l[nl].eventable.options.holdDuration;gl<Ka&&(Ka=gl)}Ue.duration=Ka,Ue.timeout=setTimeout(function(){An({interaction:_,eventTarget:Q,pointer:O,event:K,type:"hold"},y)},Ka)}})(t,o),An(t,o)},"interactions:up":function(t,o){Pi(t),An(t,o),function(f,y){var _=f.interaction,O=f.pointer,K=f.event,Q=f.eventTarget;_.pointerWasMoved||An({interaction:_,eventTarget:Q,pointer:O,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,_=t.event,O=t.eventTarget,K=t.type,Q=t.targets,ge=Q===void 0?Vi(t,o):Q,Ue=new uo(K,y,_,O,f,o.now());o.fire("pointerEvents:new",{pointerEvent:Ue});for(var Se={interaction:f,pointer:y,event:_,eventTarget:O,targets:ge,type:K,pointerEvent:Ue},ra=0;ra<ge.length;ra++){var Ta=ge[ra];for(var Za in Ta.props||{})Ue[Za]=Ta.props[Za];var Ka=De(Ta.eventable,Ta.node);if(Ue._subtractOrigin(Ka),Ue.eventable=Ta.eventable,Ue.currentTarget=Ta.node,Ta.eventable.fire(Ue),Ue._addOrigin(Ka),Ue.immediatePropagationStopped||Ue.propagationStopped&&ra+1<ge.length&&ge[ra+1].node!==Ue.currentTarget)break}if(o.fire("pointerEvents:fired",Se),K==="tap"){var nl=Ue.double?An({interaction:f,pointer:y,event:_,eventTarget:O,type:"doubletap"},o):Ue;f.prevTap=nl,f.tapTime=nl.timeStamp}return Ue}function Vi(t,o){var f=t.interaction,y=t.pointer,_=t.event,O=t.eventTarget,K=t.type,Q=f.getPointerIndex(y),ge=f.pointers[Q];if(K==="tap"&&(f.pointerWasMoved||!ge||ge.downTarget!==O))return[];for(var Ue=na(O),Se={interaction:f,pointer:y,event:_,eventTarget:O,type:K,path:Ue,targets:[],node:null},ra=0;ra<Ue.length;ra++){var Ta=Ue[ra];Se.node=Ta,o.fire("pointerEvents:collect-targets",Se)}return K==="hold"&&(Se.targets=Se.targets.filter(function(Za){var Ka,nl;return Za.eventable.options.holdDuration===((Ka=f.pointers[Q])==null||(nl=Ka.hold)==null?void 0:nl.duration)})),Se.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,_=t.eventTarget,O=t.targets;if(y.type==="hold"&&O.length){var K=O[0].eventable.options.holdRepeatInterval;K<=0||(f.holdIntervalHandle=setTimeout(function(){o.pointerEvents.fire({interaction:f,eventTarget:_,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 ee(this.events.options,y),this};var f=o.prototype._backCompatOption;o.prototype._backCompatOption=function(y,_){var O=f.call(this,y,_);return O===this&&(this.events.options[y]=_),O}},listeners:{"pointerEvents:collect-targets":function(t,o){var f=t.targets,y=t.node,_=t.type,O=t.eventTarget;o.interactables.forEachMatch(y,function(K){var Q=K.events,ge=Q.options;Q.types[_]&&Q.types[_].length&&K.testIgnoreAllow(ge,y,O)&&f.push({node:y,eventable:Q,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;ee(f.events.options,o.pointerEvents.defaults),ee(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,_,O){for(var K=y.getAllElements(),Q=O.window.Promise,ge=Q?[]:null,Ue=function(){var ra=K[Se],Ta=y.getRect(ra);if(!Ta)return 1;var Za,Ka=Xe(O.interactions.list,function(gl){return gl.interacting()&&gl.interactable===y&&gl.element===ra&&gl.prepared.name===_.name});if(Ka)Ka.move(),ge&&(Za=Ka._reflowPromise||new Q(function(gl){Ka._reflowResolve=gl}));else{var nl=we(Ta),_l=function(gl){return{coords:gl,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:nl.x,y:nl.y},client:{x:nl.x,y:nl.y},timeStamp:O.now()});Za=function(gl,Nl,Wl,zl,$l){var Rl=gl.interactions.new({pointerType:"reflow"}),rn={interaction:Rl,event:$l,pointer:$l,eventTarget:Wl,phase:"reflow"};Rl.interactable=Nl,Rl.element=Wl,Rl.prevEvent=$l,Rl.updatePointer($l,$l,Wl,!0),he(Rl.coords.delta),ba(Rl.prepared,zl),Rl._doPhase(rn);var or=gl.window,un=or.Promise,kn=un?new un(function(Tn){Rl._reflowResolve=Tn}):void 0;return Rl._reflowPromise=kn,Rl.start(zl,Nl,Wl),Rl._interacting?(Rl.move(rn),Rl.end($l)):(Rl.stop(),Rl._reflowResolve()),Rl.removePointer($l,$l),kn}(O,y,ra,_,_l)}ge&&ge.push(Za)},Se=0;Se<K.length&&!Ue();Se++);return ge&&Q.all(ge).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,_){y.splice(y.indexOf(_),1)}(o.interactions.list,f))}}},gi=po;if(ln.use(gr),ln.use(Vl),ln.use(tt),ln.use(cn),ln.use(et),ln.use(Cr),ln.use(rl),ln.use(Z),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 S1=_1();const Os=A.getDefaultExportFromCjs(S1),$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(qc),h=e.inject(Wc);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,g=!1,u=NaN,C=NaN,M=NaN,k=NaN,W=-1,I=-1,j=-1,L=-1,E=r.x,x=r.y,w=r.w,b=r.h;const S=e.ref(),$=e.reactive({i:e.toRef(r,"i"),state:d,wrapper:S,calcXY:de});function V(pe){Ge(pe)}function le(){ua()}function X(pe){xn(r.isDraggable)&&(d.draggable=pe)}function me(pe){xn(r.isResizable)&&(d.resizable=pe)}function Be(pe){xn(r.isBounded)&&(d.bounded=pe)}function F(pe){d.transformScale=pe}function ie(pe){d.rowHeight=pe}function Y(pe){d.maxRows=pe}function ce(){d.rtl=Ms()==="rtl",ua()}function Ce(pe){d.cols=Math.floor(pe)}s.increaseItem($),e.onBeforeMount(()=>{d.rtl=Ms()==="rtl"}),e.onMounted(()=>{s.responsive&&s.lastBreakpoint?d.cols=Xc(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(()=>{E=r.x,x=r.y,b=r.h,w=r.w,dn(je)}),h.on("updateWidth",V),h.on("compact",le),h.on("setDraggable",X),h.on("setResizable",me),h.on("setBounded",Be),h.on("setTransformScale",F),h.on("setRowHeight",ie),h.on("setMaxRows",Y),h.on("directionchange",ce),h.on("setColNum",Ce)}),e.onBeforeUnmount(()=>{h.off("updateWidth",V),h.off("compact",le),h.off("setDraggable",X),h.off("setResizable",me),h.off("setBounded",Be),h.off("setTransformScale",F),h.off("setRowHeight",ie),h.off("setMaxRows",Y),h.off("directionchange",ce),h.off("setColNum",Ce),c.value&&(c.value.unset(),c.value=null),s.decreaseItem($)}),l({state:d,wrapper:S});const Fe=typeof navigator<"u"?navigator.userAgent.toLowerCase().includes("android"):!1,fe=e.computed(()=>d.resizable&&!r.static),N=e.computed(()=>s.isMirrored?!d.rtl:d.rtl),se=e.computed(()=>(d.draggable||d.resizable)&&!r.static),U=v1("item"),_e=e.computed(()=>({[U.b()]:!0,[U.bm("resizable")]:fe.value,[U.bm("static")]:r.static,[U.bm("resizing")]:d.isResizing,[U.bm("dragging")]:d.isDragging,[U.bm("transform")]:d.useCssTransforms,[U.bm("rtl")]:N.value,[U.bm("no-touch")]:Fe&&se.value})),Ie=e.computed(()=>[U.be("resizer"),N.value&&U.bem("resizer","rtl")].filter(Boolean));e.watch(()=>r.isDraggable,pe=>{d.draggable=pe}),e.watch(()=>r.static,()=>{dn(H),dn(he)}),e.watch(()=>d.draggable,()=>{dn(H)}),e.watch(()=>r.isResizable,pe=>{d.resizable=pe}),e.watch(()=>r.isBounded,pe=>{d.bounded=pe}),e.watch(()=>d.resizable,()=>{dn(he)}),e.watch(()=>d.rowHeight,()=>{dn(je),dn(na)}),e.watch([()=>d.cols,()=>d.containerWidth],()=>{dn(he),dn(je),dn(na)}),e.watch([()=>r.minH,()=>r.maxH,()=>r.minW,()=>r.maxW],()=>{dn(he)}),e.watch(N,()=>{dn(he),dn(je)}),e.watch([()=>s.margin,()=>s.margin[0],()=>s.margin[1]],()=>{const pe=s.margin;!pe||pe[0]===d.margin[0]&&pe[1]===d.margin[1]||(d.margin=pe.map(Number),dn(je),dn(na))});function je(){r.x+r.w>d.cols?(E=0,w=r.w>d.cols?d.cols:r.w):(E=r.x,w=r.w);const pe=ca(E,x,w,b);d.isDragging&&(pe.top=d.dragging.top,N.value?pe.right=d.dragging.left:pe.left=d.dragging.left),d.isResizing&&(pe.width=d.resizing.width,pe.height=d.resizing.height);let ha;d.useCssTransforms?N.value?ha=d1(pe.top,pe.right,pe.width,pe.height):ha=u1(pe.top,pe.left,pe.width,pe.height):N.value?ha=f1(pe.top,pe.right,pe.width,pe.height):ha=p1(pe.top,pe.left,pe.width,pe.height),d.style=ha}function na(){const pe={};for(const ha of["width","height"]){const ta=d.style[ha].match(/^(\d+)px$/);if(!ta)return;pe[ha]=ta[1]}i("container-resized",r.i,r.h,r.w,pe.height,pe.width)}function Ca(pe){if(r.static)return;const ha=pe.type;if(ha==="resizestart"&&d.isResizing||ha!=="resizestart"&&!d.isResizing)return;const ta=As(pe);if(xn(ta))return;const{x:He,y:_a}=ta,ze={width:0,height:0};let ma;switch(ha){case"resizestart":{he(),W=w,I=b,ma=ca(E,x,w,b),ze.width=ma.width,ze.height=ma.height,d.resizing=ze,d.isResizing=!0;break}case"resizemove":{!pe.edges.right&&!pe.edges.left&&(M=He),!pe.edges.top&&!pe.edges.bottom&&(k=_a);const Oa=zs(M,k,He,_a);N.value?ze.width=d.resizing.width-Oa.deltaX/d.transformScale:ze.width=d.resizing.width+Oa.deltaX/d.transformScale,ze.height=d.resizing.height+Oa.deltaY/d.transformScale,d.resizing=ze;break}case"resizeend":{ma=ca(E,x,w,b),ze.width=ma.width,ze.height=ma.height,d.resizing={width:-1,height:-1},d.isResizing=!1;break}}ma=De(ze.height,ze.width),ma.w<r.minW&&(ma.w=r.minW),ma.w>r.maxW&&(ma.w=r.maxW),ma.h<r.minH&&(ma.h=r.minH),ma.h>r.maxH&&(ma.h=r.maxH),ma.h<1&&(ma.h=1),ma.w<1&&(ma.w=1),M=He,k=_a,(w!==ma.w||b!==ma.h)&&i("resize",r.i,ma.h,ma.w,ze.height,ze.width),pe.type==="resizeend"&&(W!==w||I!==b)&&i("resized",r.i,ma.h,ma.w,ze.height,ze.width),h.emit("resizeEvent",pe.type,r.i,E,x,ma.h,ma.w)}function ee(pe){if(r.static||d.isResizing)return;const ha=pe.type;if(ha==="dragstart"&&d.isDragging||ha!=="dragstart"&&!d.isDragging)return;const ta=As(pe);if(xn(ta))return;const{x:He,y:_a}=ta,ze=pe.target;if(!ze.offsetParent)return;const ma={top:0,left:0};switch(ha){case"dragstart":{j=E,L=x;const Ma=ze.offsetParent.getBoundingClientRect(),fa=ze.getBoundingClientRect(),Ba=fa.left/d.transformScale,Te=Ma.left/d.transformScale,ye=fa.right/d.transformScale,Ne=Ma.right/d.transformScale,ae=fa.top/d.transformScale,oe=Ma.top/d.transformScale;N.value?ma.left=(ye-Ne)*-1:ma.left=Ba-Te,ma.top=ae-oe,d.dragging=ma,d.isDragging=!0;break}case"dragmove":{const Ma=zs(u,C,He,_a);if(N.value?ma.left=d.dragging.left-Ma.deltaX/d.transformScale:ma.left=d.dragging.left+Ma.deltaX/d.transformScale,ma.top=d.dragging.top+Ma.deltaY/d.transformScale,d.bounded){const fa=ze.offsetParent.clientHeight-we(r.h,d.rowHeight,d.margin[1]);ma.top=ue(ma.top,0,fa);const Ba=pa(),Te=d.containerWidth-we(r.w,Ba,d.margin[0]);ma.left=ue(ma.left,0,Te)}d.dragging=ma;break}case"dragend":{const Ma=ze.offsetParent.getBoundingClientRect(),fa=ze.getBoundingClientRect(),Ba=fa.left/d.transformScale,Te=Ma.left/d.transformScale,ye=fa.right/d.transformScale,Ne=Ma.right/d.transformScale,ae=fa.top/d.transformScale,oe=Ma.top/d.transformScale;N.value?ma.left=(ye-Ne)*-1:ma.left=Ba-Te,ma.top=ae-oe,d.dragging={top:-1,left:-1},d.isDragging=!1;break}}let Oa;N.value,Oa=de(ma.top,ma.left),u=He,C=_a,(E!==Oa.x||x!==Oa.y)&&i("move",r.i,Oa.x,Oa.y),pe.type==="dragend"&&(j!==E||L!==x)&&i("moved",r.i,Oa.x,Oa.y),h.emit("dragEvent",pe.type,r.i,Oa.x,Oa.y,b,w)}function ca(pe,ha,ta,He){const _a=pa();let ze;return N.value?ze={right:Math.round(_a*pe+(pe+1)*d.margin[0]),top:Math.round(d.rowHeight*ha+(ha+1)*d.margin[1]),width:ta===1/0?ta:Math.round(_a*ta+Math.max(0,ta-1)*d.margin[0]),height:He===1/0?He:Math.round(d.rowHeight*He+Math.max(0,He-1)*d.margin[1])}:ze={left:Math.round(_a*pe+(pe+1)*d.margin[0]),top:Math.round(d.rowHeight*ha+(ha+1)*d.margin[1]),width:ta===1/0?ta:Math.round(_a*ta+Math.max(0,ta-1)*d.margin[0]),height:He===1/0?He:Math.round(d.rowHeight*He+Math.max(0,He-1)*d.margin[1])},ze}function de(pe,ha){const ta=pa();let He=Math.round((ha-d.margin[0])/(ta+d.margin[0])),_a=Math.round((pe-d.margin[1])/(d.rowHeight+d.margin[1]));return He=Math.max(Math.min(He,d.cols-w),0),_a=Math.max(Math.min(_a,d.maxRows-b),0),{x:He,y:_a}}function pa(){return(d.containerWidth-d.margin[0]*(d.cols+1))/d.cols}function we(pe,ha,ta){return Number.isFinite(pe)?Math.round(ha*pe+Math.max(0,pe-1)*ta):pe}function ue(pe,ha,ta){return Math.max(Math.min(pe,ta),ha)}function De(pe,ha,ta=!1){const He=pa();let _a=Math.round((ha+d.margin[0])/(He+d.margin[0])),ze=0;return ta?ze=Math.ceil((pe+d.margin[1])/(d.rowHeight+d.margin[1])):ze=Math.round((pe+d.margin[1])/(d.rowHeight+d.margin[1])),_a=Math.max(Math.min(_a,d.cols-E),0),ze=Math.max(Math.min(ze,d.maxRows-x),0),{w:_a,h:ze}}function Ge(pe,ha){d.containerWidth=pe}function ua(){je()}function Ja(){!c.value&&S.value&&(c.value=Os(S.value),d.useStyleCursor||c.value.styleCursor(!1))}const R=Ts(ee);function H(){if(Ja(),!!c.value)if(d.draggable&&!r.static){const pe={ignoreFrom:r.dragIgnoreFrom,allowFrom:r.dragAllowFrom,...r.dragOption};c.value.draggable(pe),m||(m=!0,c.value.on("dragstart dragmove dragend",ha=>{ha.type==="dragmove"?R(ha):ee(ha)}))}else c.value.draggable({enabled:!1})}const J=Ts(Ca);function he(){if(Ja(),!!c.value)if(d.resizable&&!r.static){const pe=ca(0,0,r.maxW,r.maxH),ha=ca(0,0,r.minW,r.minH),ta={edges:{left:N.value?`.${Ie.value[0]}`:!1,right:N.value?!1:`.${Ie.value[0]}`,bottom:`.${Ie.value[0]}`,top:!1},ignoreFrom:r.resizeIgnoreFrom,restrictSize:{min:{height:ha.height*d.transformScale,width:ha.width*d.transformScale},max:{height:pe.height*d.transformScale,width:pe.width*d.transformScale}},...r.resizeOption};r.preserveAspectRatio&&(ta.modifiers=[Os.modifiers.aspectRatio({ratio:"preserve"})]),c.value.resizable(ta),g||(g=!0,c.value.on("resizestart resizemove resizeend",He=>{He.type==="resizemove"?J(He):Ca(He)}))}else c.value.resizable({enabled:!1})}return(pe,ha)=>(e.openBlock(),e.createElementBlock("section",{ref_key:"wrapper",ref:S,class:e.normalizeClass(_e.value),style:e.normalizeStyle(d.style)},[e.renderSlot(pe.$slots,"default"),fe.value?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(Ie.value)},null,2)):e.createCommentVNode("",!0)],6))}}),fi=typeof window<"u";var Ls;fi&&(Ls=window==null?void 0:window.navigator)!=null&&Ls.userAgent&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Rs(a){return a!=null}function $s(){}const E1=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(E1)));const C1=fi&&("ontouchstart"in window||T1()>0),D1=C1?"pointerdown":"click";function T1(){return typeof navigator<"u"&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)||0}function B1(a,l,n=window.Event){const{type:r,bubbles:i=!1,cancelable:s=!1,...h}=l;if(!Rs(r)||r==="")return!1;let c;return Rs(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 N1="clickoutside",A1=new Set;fi&&document.addEventListener(D1,a=>{const l=a.target,n=a.composedPath&&a.composedPath();A1.forEach(r=>{r!==l&&(n?!n.includes(r):!r.contains(l))&&(!r.__transferElement||r.__transferElement!==l&&!r.__transferElement.contains(l))&&B1(r,{type:N1})})},!0);const z1=[["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 z1)if(a[1]in document){Do=a;break}}e.computed(()=>!1);const M1=new Set,I1=new WeakMap;if(fi&&Do){const a=Do[2],l=Do[4];document.addEventListener(l,()=>{if(M1.forEach(n=>{n.value=!1}),document[a]){const n=I1.get(document[a]);n&&(n.value=!0)}},!1)}const Qc=new Map;Qc.set("x",0);Qc.set("y",0);var di=[],O1=function(){return di.some(function(a){return a.activeTargets.length>0})},L1=function(){return di.some(function(a){return a.skippedTargets.length>0})},Vs="ResizeObserver loop completed with undelivered notifications.",R1=function(){var a;typeof ErrorEvent=="function"?a=new ErrorEvent("error",{message:Vs}):(a=document.createEvent("Event"),a.initEvent("error",!1,!1),a.message=Vs),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)},$1=function(){function a(l,n){this.inlineSize=l,this.blockSize=n,pi(this)}return a}(),eu=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}(),Mt=function(a){return a instanceof SVGElement&&"getBBox"in a},au=function(a){if(Mt(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)},Ps=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)},V1=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,Fs=/auto|scroll/,P1=/^tb|vertical/,F1=/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 $1((n?l:a)||0,(n?a:l)||0)},js=pi({devicePixelContentBoxSize:Bi(),borderBoxSize:Bi(),contentBoxSize:Bi(),contentRect:new eu(0,0,0,0)}),lu=function(a,l){if(l===void 0&&(l=!1),_o.has(a)&&!l)return _o.get(a);if(au(a))return _o.set(a,js),js;var n=getComputedStyle(a),r=Mt(a)&&a.ownerSVGElement&&a.getBBox(),i=!F1&&n.boxSizing==="border-box",s=P1.test(n.writingMode||""),h=!r&&Fs.test(n.overflowY||""),c=!r&&Fs.test(n.overflowX||""),d=r?0:Mn(n.paddingTop),m=r?0:Mn(n.paddingRight),g=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),I=u+m,j=d+g,L=W+M,E=C+k,x=c?a.offsetHeight-E-a.clientHeight:0,w=h?a.offsetWidth-L-a.clientWidth:0,b=i?I+L:0,S=i?j+E:0,$=r?r.width:Mn(n.width)-b-w,V=r?r.height:Mn(n.height)-S-x,le=$+I+w+L,X=V+j+x+E,me=pi({devicePixelContentBoxSize:Bi(Math.round($*devicePixelRatio),Math.round(V*devicePixelRatio),s),borderBoxSize:Bi(le,X,s),contentBoxSize:Bi($,V,s),contentRect:new eu(u,d,$,V)});return _o.set(a,me),me},ru=function(a,l,n){var r=lu(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}},j1=function(){function a(l){var n=lu(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}(),nu=function(a){if(au(a))return 1/0;for(var l=0,n=a.parentNode;n;)l+=1,n=n.parentNode;return l},H1=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 j1(c.target),m=nu(c.target);h.push(d),c.lastReportedSize=ru(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},Hs=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()&&(nu(n.target)>a?l.activeTargets.push(n):l.skippedTargets.push(n))})})},U1=function(){var a=0;for(Hs(a);O1();)a=H1(),Hs(a);return L1()&&R1(),a>0},mt,iu=[],q1=function(){return iu.splice(0).forEach(function(a){return a()})},W1=function(a){if(!mt){var l=0,n=document.createTextNode(""),r={characterData:!0};new MutationObserver(function(){return q1()}).observe(n,r),mt=function(){n.textContent="".concat(l?l--:l++)}}iu.push(a),mt()},K1=function(a){W1(function(){requestAnimationFrame(a)})},To=0,G1=function(){return!!To},Y1=250,J1={attributes:!0,characterData:!0,childList:!0,subtree:!0},Us=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],qs=function(a){return a===void 0&&(a=0),Date.now()+a},yt=!1,X1=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=Y1),!yt){yt=!0;var r=qs(l);K1(function(){var i=!1;try{i=U1()}finally{if(yt=!1,l=r-qs(),!G1())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,J1)};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(),Us.forEach(function(n){return Ji.addEventListener(n,l.listener,!0)}))},a.prototype.stop=function(){var l=this;this.stopped||(this.observer&&this.observer.disconnect(),Us.forEach(function(n){return Ji.removeEventListener(n,l.listener,!0)}),this.stopped=!0)},a}(),Nt=new X1,Ws=function(a){!To&&a>0&&Nt.start(),To+=a,!To&&Nt.stop()},Z1=function(a){return!Mt(a)&&!V1(a)&&getComputedStyle(a).display==="inline"},Q1=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=ru(this.target,this.observedBox,!0);return Z1(this.target)&&(this.lastReportedSize=l),this.lastReportedSize.inlineSize!==l.inlineSize||this.lastReportedSize.blockSize!==l.blockSize},a}(),ev=function(){function a(l,n){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=l,this.callback=n}return a}(),So=new WeakMap,Ks=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 ev(l,n);So.set(l,r)},a.observe=function(l,n,r){var i=So.get(l),s=i.observationTargets.length===0;Ks(i.observationTargets,n)<0&&(s&&di.push(i),i.observationTargets.push(new Q1(n,r&&r.box)),Ws(1),Nt.schedule())},a.unobserve=function(l,n){var r=So.get(l),i=Ks(r.observationTargets,n),s=r.observationTargets.length===1;i>=0&&(s&&di.splice(di.indexOf(r),1),r.observationTargets.splice(i,1),Ws(-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}(),av=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(!Ps(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(!Ps(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 lv(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 ou=new(fi&&window.ResizeObserver||av)(lv);function Gs(a,l){Vo.set(a,l),ou.observe(a)}function Ys(a){Vo.has(a)&&(ou.unobserve(a),Vo.delete(a))}function rv(a={}){let l=$s;const n=e.watch(()=>e.unref(a.target),i=>{l(),!(!i||typeof a.onResize!="function")&&(Gs(i,a.onResize),l=()=>{Ys(i),l=$s})},{immediate:!0}),r=()=>{n(),l()};return e.getCurrentScope()&&e.onScopeDispose(r),{observeResize:Gs,unobserveResize:Ys,unobserve:r}}const nv=e.ref(!1);e.computed(()=>nv.value);const Js="__theme_style__",gt="__theme_observer__",Xs=e.reactive(new Map),Zs=new Map;e.watch(Xs,()=>{if(!fi)return;Zs.clear();const a=document.head.querySelector(`#${Js}`);a&&document.head.removeChild(a);const l=document.createElement("style");let n=`.${gt} { width: 1px }`,r=1;for(const[i,[s,h]]of Xs.entries())n+=` html.${s} .${gt}, .${h} .${gt} { width: ${++r}px }`,Zs.set(r,i);l.textContent=n,l.id=Js,document.head.appendChild(l)});const tu=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:g}=rv(),u=l1();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(()=>{h1(c.value),s.originalLayout=c.value,e.nextTick(()=>{V(),d.value&&m(d.value,r1(E,16)),Ci(c.value,r.verticalCompact),i("layout-updated",c.value),L(),E()})})}),e.onBeforeUnmount(()=>{u.clearAll(),d.value&&g(d.value)});function C(X,me,Be,F,ie,Y){S(X,me,Be,F,ie,Y)}function M(X,me,Be,F,ie,Y){b(X,me,Be,F,ie,Y)}e.watch(()=>s.width,(X,me)=>{e.nextTick(()=>{u.emit("updateWidth",X),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,X=>{u.emit("setColNum",X)}),e.watch(()=>r.rowHeight,X=>{u.emit("setRowHeight",X)}),e.watch(()=>r.isDraggable,X=>{u.emit("setDraggable",X)}),e.watch(()=>r.isResizable,X=>{u.emit("setResizable",X)}),e.watch(()=>r.isBounded,X=>{u.emit("setBounded",X)}),e.watch(()=>r.transformScale,X=>{u.emit("setTransformScale",X)}),e.watch(()=>r.responsive,X=>{X||(i("update:layout",s.originalLayout),u.emit("setColNum",r.colNum)),E()}),e.watch(()=>r.maxRows,X=>{u.emit("setMaxRows",X)}),e.watch([()=>r.margin,()=>r.margin[1]],L),e.provide(qc,e.reactive({...e.toRefs(r),...e.toRefs(s),increaseItem:k,decreaseItem:W})),e.provide(Wc,u),l({state:s,getItem:I,resizeEvent:S,dragEvent:b,layoutUpdate:j});function k(X){h.set(X.i,X)}function W(X){h.delete(X.i)}function I(X){return h.get(X)}function j(){if(!xn(c.value)&&!xn(s.originalLayout)){if(c.value.length!==s.originalLayout.length){const X=le(c.value,s.originalLayout);if(X.length>0)if(c.value.length>s.originalLayout.length)s.originalLayout=s.originalLayout.concat(X);else{const me=new Set(X.map(Be=>Be.i));s.originalLayout=s.originalLayout.filter(Be=>!me.has(Be.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 E(){d.value&&(s.width=d.value.offsetWidth),u.emit("resizeEvent")}function x(){if(!r.autoSize)return;const X=parseFloat(r.margin[1]);return i1(c.value)*(r.rowHeight+X)+X+"px"}let w;function b(X,me,Be,F,ie,Y){let ce=Bs(c.value,me);xn(ce)&&(ce={h:0,w:0,x:0,y:0,i:""}),X==="dragstart"&&!r.verticalCompact&&(w=c.value.reduce((Ce,{i:Fe,x:fe,y:N})=>({...Ce,[Fe]:{x:fe,y:N}}),{})),X==="dragmove"||X==="dragstart"?(s.placeholder.i=me,s.placeholder.x=ce.x,s.placeholder.y=ce.y,s.placeholder.w=Y,s.placeholder.h=ie,e.nextTick(()=>{s.isDragging=!0}),u.emit("updateWidth",s.width)):e.nextTick(()=>{s.isDragging=!1}),c.value=Bt(c.value,ce,Be,F,!0,r.preventCollision),r.restoreOnDrag?(ce.static=!0,Ci(c.value,r.verticalCompact,w),ce.static=!1):Ci(c.value,r.verticalCompact),u.emit("compact"),L(),X==="dragend"&&(w=void 0,i("layout-updated",c.value))}function S(X,me,Be,F,ie,Y){let ce=Bs(c.value,me);xn(ce)&&(ce={h:0,w:0,x:0,y:0,i:""});let Ce;if(r.preventCollision){const Fe=Gc(c.value,{...ce,w:Y,h:ie}).filter(fe=>fe.i!==ce.i);if(Ce=Fe.length>0,Ce){let fe=1/0,N=1/0;Fe.forEach(se=>{se.x>ce.x&&(fe=Math.min(fe,se.x)),se.y>ce.y&&(N=Math.min(N,se.y))}),Number.isFinite(fe)&&(ce.w=fe-ce.x),Number.isFinite(N)&&(ce.h=N-ce.y)}}Ce||(ce.w=Y,ce.h=ie),X==="resizestart"||X==="resizemove"?(s.placeholder.i=me,s.placeholder.x=Be,s.placeholder.y=F,s.placeholder.w=ce.w,s.placeholder.h=ce.h,e.nextTick(()=>{s.isDragging=!0}),u.emit("updateWidth",s.width)):X&&e.nextTick(()=>{s.isDragging=!1}),r.responsive&&$(),Ci(c.value,r.verticalCompact),u.emit("compact"),L(),X==="resizeend"&&i("layout-updated",c.value)}function $(){const X=g1(r.breakpoints,s.width);if(X===s.lastBreakpoint)return;const me=Xc(X,r.cols);!xn(s.lastBreakpoint)&&!s.layouts[s.lastBreakpoint]&&(s.layouts[s.lastBreakpoint]=Tt(c.value));const Be=b1(s.originalLayout,s.layouts,r.breakpoints,X,s.lastBreakpoint,me,r.verticalCompact);s.layouts[X]=Be,s.lastBreakpoint!==X&&i("breakpoint-changed",X,Be),c.value=Be,i("update:layout",Be),s.lastBreakpoint=X,u.emit("setColNum",me)}function V(){s.layouts=Object.assign({},r.responsiveLayouts)}function le(X,me){const Be=new Set(me.map(ce=>ce.i)),F=new Set(X.map(ce=>ce.i)),ie=X.filter(ce=>!Be.has(ce.i)),Y=me.filter(ce=>!F.has(ce.i));return ie.concat(Y)}return(X,me)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"wrapper",ref:d,class:"vgl-layout",style:e.normalizeStyle(s.mergedStyle)},[X.$slots.default?e.renderSlot(X.$slots,"default",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(c.value,Be=>(e.openBlock(),e.createBlock($o,e.mergeProps({key:Be.i,ref_for:!0},Be),{default:e.withCtx(()=>[e.renderSlot(X.$slots,"item",{item:Be})]),_: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 iv={key:0,class:"item-view-group"},ov={key:0,class:"item-view-group"},tv=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,E,x,w;return((L=h==null?void 0:h.children)==null?void 0:L.length)>0&&((E=h==null?void 0:h.children)!=null&&E.every(b=>b==null?void 0:b.layout))?(w=(x=h==null?void 0:h.children)==null?void 0:x[0])==null?void 0:w.layout:"vertical"}),g=L=>{c.value=L,s("radioChange",L)},u=e.computed(()=>{var L,E;return((E=(L=h==null?void 0:h.children)==null?void 0:L[0])==null?void 0:E.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"),E=h.children.some(x=>(x==null?void 0:x.name)==="测量系统传递表"&&(x==null?void 0:x.comp)==="ParentItem");return L&&E}),k=e.computed(()=>{var E,x,w,b,S,$;let L=(E=h==null?void 0:h.children)==null?void 0:E.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=(S=(b=h==null?void 0:h.children)==null?void 0:b.find(le=>le==null?void 0:le.choice))==null?void 0:S.choiceName;return($=h==null?void 0:h.children)==null?void 0:$.filter(le=>!(le!=null&&le.choiceName)||(le==null?void 0:le.choiceName)===V)}}),W=L=>{const E=(L==null?void 0:L.menuFilter)||[];return Array.isArray(E)&&(E==null?void 0:E.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 I=L=>{s("rowClick",L)},j=(L,E)=>{s("routeUrl",L,E)};return(L,E)=>u.value?(e.openBlock(),e.createBlock(e.unref(tu),{key:0,layout:d.value,"onUpdate:layout":E[0]||(E[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 b,S,$,V,le,X,me,Be,F,ie,Y,ce,Ce,Fe;return[e.createElementVNode("div",{style:e.normalizeStyle({gap:"16px",display:"flex",flexDirection:"column",paddingBottom:w===((b=h==null?void 0:h.children)==null?void 0:b.length)-1?"0px":"24px"})},[(($=(S=x==null?void 0:x.component)==null?void 0:S.comp)==null?void 0:$.toUpperCase())!=="TABLE"&&((V=x==null?void 0:x.component)!=null&&V.name)?(e.openBlock(),e.createElementBlock("div",iv,[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((le=x==null?void 0:x.component)==null?void 0:le.name),5)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Zi)((X=x==null?void 0:x.component)==null?void 0:X.comp)),{pageLayout:m.value,config:{showIndex:(me=e.unref(ur)[w])==null?void 0:me.showIndex,allowMove:(Be=e.unref(ur)[w])==null?void 0:Be.allowMove,viewport:(F=e.unref(ur)[w])==null?void 0:F.viewport,status:(ie=e.unref(ur)[w])==null?void 0:ie.status},related:x==null?void 0:x.relatedTables,compName:x==null?void 0:x.component.name,compNames:e.unref(Dc),itemData:(Y=x==null?void 0:x.component)==null?void 0:Y.compData,childItemData:(ce=x==null?void 0:x.component)==null?void 0:ce.itemChildData,key:e.unref(Gn),cacheNewData:e.unref(Cc),onChange:e.unref(Io),index:(x==null?void 0:x.id)??w,onContentChange:e.unref(Oo),onPageChange:e.unref(Lo),parentTableId:(Ce=x==null?void 0:x.component)==null?void 0:Ce.tableId,allMapContents:e.unref(Et),children:(Fe=x==null?void 0:x.component)==null?void 0:Fe.children,level:C.value,onRowClick:I,onRouteUrl:j,onClickTrigger:e.unref(Tc),onClickMainKey:e.unref(Bc),onRadioChange:g},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 b,S;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)===((b=h==null?void 0:h.children)==null?void 0:b.length)-1?"0px":"24px"})},[((S=x==null?void 0:x.comp)==null?void 0:S.toUpperCase())!=="TABLE"&&x.name?(e.openBlock(),e.createElementBlock("div",ov,[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(Et),children:x==null?void 0:x.children,level:C.value,onRowClick:I,onRouteUrl:j,onRadioChange:g},null,40,["compName","groupNames","config","itemData","related","childItemData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level"]))],4)}),256))}}),sv=Ql._export_sfc(tv,[["__scopeId","data-v-bafbdd45"]]),cv={class:"radio-group-container"},uv=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",cv,[e.createVNode(sl.ssRadio,{modelValue:i.value,"onUpdate:modelValue":m[0]||(m[0]=g=>i.value=g),content:n==null?void 0:n.itemData,onChange:c},null,8,["modelValue","content"])]))}}),dv=Ql._export_sfc(uv,[["__scopeId","data-v-177d64c3"]]),pv=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(sl.ssCarousel,{carouselList:n.value},null,8,["carouselList"])]))}}),su=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"}]),fv={TABLE:Mc,FORM:Es,STATICFORM:Ic,TABLEOPERATE:l4,TABLESTYLE:b4,TABLEEXTEND:x4,TABLEINTERACTION:S4,FORMOPERATE:Cs,FOLD:e2,CALCULATOR:o2,METHODBUTTON:c2,AVATARUPLOAD:os.ssAvatar,SIGNATURE:os.ssSignature,FORMTOP:Es,STEP:x2,STEPOPERATE:q4,TIMELINE:D2,TIMELINEOPERATE:X4,FORMTOPOPERATE:Cs,SIGNATUREOPERATE:g2,AVATARUPLOADOPERATE:p2,TABS:N2,TABSOPERATE:v6,CHART:N6,CHARTOPERATE:F6,LAYOUT:U6,LAYOUTOPERATE:Q6,PARENTITEM:sv,RADIO:dv,CAROUSEL:pv};function zi(a){return fv[a==null?void 0:a.toUpperCase()]||null}exports.De=tu;exports.activeStepInfo=Di;exports.addContents=Xi;exports.addVisibleDialog=zt;exports.affixItems=A0;exports.allMapContents=Et;exports.analyzeMenu=ic;exports.cacheNewData=Cc;exports.clickMainKey=Bc;exports.clickSavePage=N0;exports.clickStep=Ac;exports.clickTrigger=Tc;exports.compId=Gn;exports.compNames=Dc;exports.compShow=Ai;exports.existLayouts=V0;exports.fixChangeValue=Po;exports.generateLayouts=v4;exports.getComponent=zi;exports.getComponents=Zi;exports.getPageConstruct=Xd;exports.getPageData=an;exports.getSliceContLength=q0;exports.gridRowHeight=u4;exports.gridRowHeightHmPg=c4;exports.isStepLayout=zc;exports.onBack=T0;exports.onButtonChange=O0;exports.onChange=Io;exports.onClick=B0;exports.onClickStep=P0;exports.onContentChange=Oo;exports.onExtendTaskEnd=$0;exports.onOk=L0;exports.onPageBack=j0;exports.onPageChange=Lo;exports.onSelectFixContent=D0;exports.renderShowItems=Sc;exports.showItems=ur;exports.sliceTableLength=Ec;exports.slotContent=su;exports.ssTable=Mc;exports.st=$o;exports.stepItems=W0;exports.tabChange=F0;exports.toolBar=R0;exports.useFormComp=At;exports.useModelLoader=Tf;exports.verifyButton=H0;