ss-component-new 1.3.488 → 1.3.490
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{array-CIY5ngNa.cjs → array-BM4J2Hfs.cjs} +1 -1
- package/dist/{array-CyWnJOse.js → array-CVYp6Chy.js} +2 -2
- package/dist/{index-BhFJYTQq.cjs → index-2P0gL-8h.cjs} +1 -1
- package/dist/{index-CQDPjmOU.js → index-AOahVMc9.js} +2 -2
- package/dist/{index-DMjQx-9S.js → index-B3FYCeYg.js} +210 -210
- package/dist/{index-euYbY01D.js → index-B44aoDYY.js} +3 -3
- package/dist/{index-Ck4GufLt.js → index-B5CksVe-.js} +2 -2
- package/dist/{index-AMJhBnpR.js → index-B7kewjn4.js} +1 -1
- package/dist/{index-BjLsZ-S_.cjs → index-B8aeaUY3.cjs} +1 -1
- package/dist/{index-CINVQm_r.cjs → index-BJboQsJ0.cjs} +1 -1
- package/dist/{index-dRHSDo1o.cjs → index-BnHuye3z.cjs} +1 -1
- package/dist/{index-bTdS4XKD.cjs → index-BwDCXZEv.cjs} +5 -5
- package/dist/{index-B1PRPWIp.js → index-C-WM7ePh.js} +2 -2
- package/dist/{index-B7Xqz_xI.js → index-Co-RAur6.js} +1 -1
- package/dist/{index-D0TYT7v6.cjs → index-D1hl24-E.cjs} +1 -1
- package/dist/{index-BKdFWWeX.js → index-D4Nr69rH.js} +1 -1
- package/dist/{index-BT61Flji.cjs → index-D4Y3XURU.cjs} +1 -1
- package/dist/{index-Drd5LFAC.cjs → index-DB3Tk7l3.cjs} +1 -1
- package/dist/{index-B42QuG8S.js → index-DL700Ss1.js} +7 -7
- package/dist/{index-BQDIqqJ2.js → index-DWHdl8CF.js} +1 -1
- package/dist/{index-SIP1SPLp.js → index-DdLwbfXr.js} +1 -1
- package/dist/{index-C9wqyLWd.js → index-Dx9h2Wje.js} +1 -1
- package/dist/{index-DL3f05A0.cjs → index-SI8emaks.cjs} +1 -1
- package/dist/{index-BuhPDJ6F.cjs → index-dYGLVem9.cjs} +1 -1
- package/dist/{index-CJHVV4bB.cjs → index-kH00xIEP.cjs} +1 -1
- package/dist/{index-CXOEH7mw.cjs → index-uaC1E_Wd.cjs} +1 -1
- package/dist/{main-_uqGx9CZ.js → main-BLZvDFKp.js} +2 -2
- package/dist/{main-DqqJYUpM.cjs → main-DECNweuK.cjs} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.js +5 -5
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +8 -8
- package/dist/{threeModel-BQf_RwK2.js → threeModel-BN8j5J0b.js} +1 -1
- package/dist/{threeModel-iuZHtta5.cjs → threeModel-Dz9axLbS.cjs} +1 -1
- package/dist/{threeSceneView-BRgp6llJ.cjs → threeSceneView-BXn45is-.cjs} +1 -1
- package/dist/{threeSceneView-DjOXUVv6.js → threeSceneView-BYMjKYLC.js} +3 -3
- package/dist/{threeSceneViewForCPMPIP-R_AJyvcF.js → threeSceneViewForCPMPIP-CMSPNMtp.js} +1 -1
- package/dist/{threeSceneViewForCPMPIP-CHGIlq2o.cjs → threeSceneViewForCPMPIP-D1AXgn7a.cjs} +1 -1
- package/dist/{threeViewerHost-DFRtPjLy.cjs → threeViewerHost-CjQ-eaaH.cjs} +1 -1
- package/dist/{threeViewerHost-_jhH2hZw.js → threeViewerHost-DAaNwmDe.js} +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
"use strict";var Qu=Object.defineProperty;var ed=(a,l,r)=>l in a?Qu(a,l,{enumerable:!0,configurable:!0,writable:!0,value:r}):a[l]=r;var fn=(a,l,r)=>ed(a,typeof l!="symbol"?l+"":l,r);const e=require("vue"),Ja=require("./request-Dl8yi2iS.cjs"),M=require("./index-CMUsYepp.cjs"),pl=require("./index-BhFJYTQq.cjs"),le=require("./index-BuZHI6xx.cjs"),pr=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Fl=require("./index.vue_vue_type_style_index_0_scoped_07c75c98_lang-J7Knzs4U.cjs"),$r=require("./index-B-pflqKE.cjs"),Do=require("./threeViewerHost-DFRtPjLy.cjs"),Kr=require("./index-DmwxzDGW.cjs"),ms=require("./index-D0TYT7v6.cjs"),dc=require("./index-DkTHtURJ.cjs");;/* empty css */const To=require("./isString-CGrvcmBw.cjs"),ys=require("./index.vue_vue_type_script_setup_true_lang-BKTJR2th.cjs"),pc=require("./index-BVaHwt5f.cjs"),ad=require("./index-CPTra5LJ.cjs"),Yn=require("./MTLLoader-DqJ6tn_v.cjs"),ld=require("./URDFLoader-CnIz461N.cjs");var rd="[object Boolean]";function fc(a){return a===!0||a===!1||Ja.isObjectLike(a)&&Ja.baseGetTag(a)==rd}function nd(a){return a===void 0}const id=a=>a.match(/\((.*)\)/)[1],od={__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,r=e.ref(null),n=e.ref(!1),i=e.ref(null);return e.watch(()=>l==null?void 0:l.isVisible,()=>{n.value=l==null?void 0:l.isVisible},{deep:!0,immediate:!0}),e.watch(()=>i.value,()=>{e.nextTick(()=>{var o,p;(p=(o=r.value)==null?void 0:o.updatePopper)==null||p.call(o)})},{deep:!0,immediate:!0}),(o,p)=>{const c=e.resolveComponent("el-popover");return e.openBlock(),e.createBlock(c,{visible:n.value,"onUpdate:visible":p[0]||(p[0]=u=>n.value=u),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:r,"trigger-keys":"[]"},{reference:e.withCtx(()=>[e.createElementVNode("div",null,[e.renderSlot(o.$slots,"reference",{ref_key:"referenceRef",ref:i})])]),default:e.withCtx(()=>[e.createElementVNode("div",null,[e.renderSlot(o.$slots,"content")])]),_:3},8,["visible","trigger","title","placement","width"])}}},td=e.defineComponent({__name:"index",props:{value:{type:[String,Number],default:""},columnContent:{type:Object,default:{}}},setup(a){const l=a,r=e.computed(()=>{var u,m,g,y,d,D;const n=l.value??"";let i=(u=l==null?void 0:l.columnContent)==null?void 0:u.filter;if(i=(m=le.analyzeSplitToContent(i,","))==null?void 0:m.map(w=>((w==null?void 0:w[(w==null?void 0:w.length)-1])===","&&(w=w==null?void 0:w.slice(0,(w==null?void 0:w.length)-1)),w)),i=i==null?void 0:i.find(w=>(w==null?void 0:w[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 o=(y=(g=l==null?void 0:l.columnContent)==null?void 0:g.options)==null?void 0:y.findIndex(w=>(w==null?void 0:w.value)===n);o=i==null?void 0:i[o],o=le.analyzeSplitToContent(o,","),o=o==null?void 0:o.map(w=>((w==null?void 0:w[(w==null?void 0:w.length)-1])===","&&(w=w==null?void 0:w.slice(0,(w==null?void 0:w.length)-1)),w));let p=o==null?void 0:o.find(w=>w==null?void 0:w.includes("@TextBackRGBA"));p?p=le.rgbaToColor((d=p==null?void 0:p.split("="))==null?void 0:d[1]):p=void 0;let c=o==null?void 0:o.find(w=>w==null?void 0:w.includes("@TextRGBA"));return c?c=le.rgbaToColor((D=c==null?void 0:c.split("="))==null?void 0:D[1]):c=void 0,{backgroundColor:p,color:c}});return(n,i)=>a.value!==void 0&&a.value!==null?(e.openBlock(),e.createElementBlock("span",{key:0,class:"task-status-tag",style:e.normalizeStyle(r.value)},e.toDisplayString(a.value===0?"0":a.value),5)):e.createCommentVNode("",!0)}}),sd=pr._export_sfc(td,[["__scopeId","data-v-3290070b"]]);function cd(a,l,r,n={}){if(!a||!l||!r||r.length!==4)return;const i=a.getContext("2d");if(!i)return;const{color:o="rgba(255, 235, 59, 0.3)",strokeWidth:p=2,fillOpacity:c=.2}=n,u=a.getBoundingClientRect(),m=l.getBoundingClientRect(),g=l.naturalWidth,y=l.naturalHeight,d=m.width/g,D=m.height/y,w=Math.min(d,D),q=g*w,A=y*w,j=(u.width-q)/2,O=(u.height-A)/2,E=r.map(([x,b])=>{const S=j+x*q,I=O+b*A;return{x:S,y:I}});i.clearRect(0,0,a.width,a.height),i.beginPath(),i.moveTo(E[0].x,E[0].y);for(let x=1;x<E.length;x++)i.lineTo(E[x].x,E[x].y);i.closePath();const _=o.replace(/[\d.]+\)$/,`${c})`);i.fillStyle=_,i.fill(),i.strokeStyle=o.replace(/[\d.]+\)$/,"1)"),i.lineWidth=p,i.stroke()}function Bi(a){if(!a)return;const l=a.getContext("2d");l&&l.clearRect(0,0,a.width,a.height)}function gs(a,l){if(!a||!l)return null;const r=a[l];return!r||!r.bboxNorm||!Array.isArray(r.bboxNorm)||r.bboxNorm.length!==4?null:{bboxNorm:r.bboxNorm,imageName:r.imageName||""}}const ud={key:0,class:"ocr-img-preview-root"},dd={class:"ocr-img-preview-window"},pd={key:0,class:"img-preview-body"},fd={class:"img-preview-header"},hd={class:"img-header-left"},vd={class:"img-name"},md={key:0,class:"img-header-right"},yd={class:"img-index"},gd={key:0,class:"img-thumb-list"},bd=["onClick"],kd={key:1,class:"thumb-placeholder"},xd={class:"thumb-name"},wd={class:"img-preview-container"},_d={key:0,class:"img-placeholder"},Sd={key:2,class:"img-placeholder"},Ed={key:0},Cd={key:1},Dd={key:1,class:"img-placeholder"},Td=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 r=a,n=l,i=e.computed({get:()=>r.visible,set:N=>n("update:visible",N)});let o=!1,p="",c=0,u=0,m=0,g=0,y=0,d=0,D=null;const w=N=>{var G,fe;const se=(fe=(G=N==null?void 0:N.target)==null?void 0:G.closest)==null?void 0:fe.call(G,".ocr-img-preview-window");return se||document.querySelector(".ocr-img-preview-window")},q=N=>{if(!N||N==="none")return{tx:0,ty:0};let se=N.match(/matrix\(([^)]+)\)/);if(se){const G=se[1].split(",").map(fe=>Number(fe.trim()));return{tx:(G==null?void 0:G[4])||0,ty:(G==null?void 0:G[5])||0}}if(se=N.match(/matrix3d\(([^)]+)\)/),se){const G=se[1].split(",").map(fe=>Number(fe.trim()));return{tx:(G==null?void 0:G[12])||0,ty:(G==null?void 0:G[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}},A=(N,se,G)=>{N.style.transform=`translate(${se}px, ${G}px)`},j=N=>{const se=w(N);if(!se)return;o=!0,D=se,p="move",c=N.clientX,u=N.clientY;const G=window.getComputedStyle(se),{tx:fe,ty:we}=q(G.transform);y=fe,d=we,document.addEventListener("mousemove",E),document.addEventListener("mouseup",_)},O=(N,se)=>{const G=w(N);if(!G)return;o=!0,D=G,p=se,c=N.clientX,u=N.clientY;const fe=G.getBoundingClientRect();m=fe.width,g=fe.height;const we=window.getComputedStyle(G),{tx:_e,ty:qe}=q(we.transform);y=_e,d=qe,document.addEventListener("mousemove",E),document.addEventListener("mouseup",_)},E=N=>{if(!o||!D)return;const se=N.clientX-c,G=N.clientY-u,fe=360,we=420;let _e=m,qe=g,ra=y,P=d;if(p==="move"){ra=y+se,P=d+G,A(D,ra,P);return}if(p.includes("right")&&(_e=Math.max(fe,m+se)),p.includes("bottom")&&(qe=Math.max(we,g+G)),p.includes("left")){const Ke=m-se;Ke<fe?(_e=fe,ra=y+(m-fe)):(_e=Ke,ra=y+se)}if(p.includes("top")){const Ke=g-G;Ke<we?(qe=we,P=d+(g-we)):(qe=Ke,P=d+G)}D.style.width=`${_e}px`,D.style.height=`${qe}px`,A(D,ra,P)},_=()=>{o=!1,p="",D=null,document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",_)},x=e.ref([]),b=e.ref(!1);e.watch(()=>r.images,async N=>{if(!Array.isArray(N)||N.length===0){x.value=[];return}b.value=!0;const se=[];for(const G of N)if(G.url&&!G.url.startsWith("blob:")&&!G.url.startsWith("http"))try{const fe=await Fl.downloadFile(G.url),we=URL.createObjectURL(fe);se.push({...G,blobUrl:we})}catch(fe){console.error(`Failed to load image for preview: ${G.url}`,fe),se.push({...G,blobUrl:""})}else se.push({...G,blobUrl:G.url});x.value=se,b.value=!1},{deep:!0,immediate:!0});const S=e.ref(0),I=e.ref(null),R=e.ref(null),re=e.computed(()=>x.value[S.value]||null),X=()=>{if(!x.value.length){S.value=0;return}if(r.defaultImageName){const N=x.value.findIndex(se=>(se==null?void 0:se.name)===r.defaultImageName);S.value=N>=0?N:0}else S.value=0},me=N=>{if(!x.value.length)return;const se=Math.max(0,Math.min(N,x.value.length-1));S.value=se},ue=()=>me(S.value-1),U=()=>me(S.value+1),W=N=>{if(!N)return;const se=x.value.findIndex(G=>(G==null?void 0:G.name)===N);se>=0&&(S.value=se)},Z=()=>{if(!R.value)return;const N=R.value.parentElement;if(!N)return;const se=N.getBoundingClientRect();R.value.width=se.width,R.value.height=se.height},ae=()=>{var fe,we;if(!R.value||!I.value||!r.focusedFieldName){R.value&&Bi(R.value);return}const N=(fe=I.value.$el)==null?void 0:fe.querySelector("img");if(!N)return;if(!N.complete||N.naturalWidth===0){N.onload=()=>{e.nextTick(()=>{ae()})};return}const se=((we=re.value)==null?void 0:we.name)||"",G=gs(r.fieldMeta,r.focusedFieldName);if(!G){Bi(R.value);return}if(G.imageName!==se){Bi(R.value);return}Z(),cd(R.value,N,G.bboxNorm)},ve=()=>{e.nextTick(()=>{Z(),ae()})};e.watch(()=>r.focusedFieldName,()=>{if(!i.value)return;const N=gs(r.fieldMeta,r.focusedFieldName);N!=null&&N.imageName&&W(N.imageName),e.nextTick(()=>{ae()})}),e.watch(()=>{var N;return(N=re.value)==null?void 0:N.name},()=>{i.value&&e.nextTick(()=>{R.value&&Bi(R.value),ae()})}),e.watch(()=>r.visible,N=>{N?(X(),e.nextTick(()=>{Z(),ae()})):R.value&&Bi(R.value)}),e.watch(()=>r.defaultImageName,()=>{i.value&&X()});let ze=null;e.onMounted(()=>{var N;typeof ResizeObserver<"u"&&(ze=new ResizeObserver(()=>{Z(),e.nextTick(()=>{ae()})}),(N=R.value)!=null&&N.parentElement&&ze.observe(R.value.parentElement))}),e.onUnmounted(()=>{ze&&(ze.disconnect(),ze=null),document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",_)});const te=()=>{R.value&&Bi(R.value),n("update:visible",!1),n("close")};return(N,se)=>{var qe,ra;const G=e.resolveComponent("el-button"),fe=e.resolveComponent("el-image"),we=e.resolveComponent("Loading"),_e=e.resolveComponent("el-icon");return i.value?(e.openBlock(),e.createElementBlock("div",ud,[se[12]||(se[12]=e.createElementVNode("div",{class:"ocr-img-preview-backdrop"},null,-1)),e.createElementVNode("div",dd,[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:te},"×")],32),e.createElementVNode("div",{class:"resizable-handle top",onMousedown:se[0]||(se[0]=e.withModifiers(P=>O(P,"top"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle right",onMousedown:se[1]||(se[1]=e.withModifiers(P=>O(P,"right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom",onMousedown:se[2]||(se[2]=e.withModifiers(P=>O(P,"bottom"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle left",onMousedown:se[3]||(se[3]=e.withModifiers(P=>O(P,"left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-left",onMousedown:se[4]||(se[4]=e.withModifiers(P=>O(P,"top-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-right",onMousedown:se[5]||(se[5]=e.withModifiers(P=>O(P,"top-right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-left",onMousedown:se[6]||(se[6]=e.withModifiers(P=>O(P,"bottom-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-right",onMousedown:se[7]||(se[7]=e.withModifiers(P=>O(P,"bottom-right"),["stop"]))},null,32),re.value?(e.openBlock(),e.createElementBlock("div",pd,[e.createElementVNode("div",fd,[e.createElementVNode("div",hd,[e.createElementVNode("span",vd,e.toDisplayString(re.value.name?re.value.name+(re.value.url&&re.value.url.lastIndexOf(".")!==-1?re.value.url.substring(re.value.url.lastIndexOf(".")):""):""),1)]),x.value.length>1?(e.openBlock(),e.createElementBlock("div",md,[e.createVNode(G,{size:"small",disabled:S.value===0,onClick:ue},{default:e.withCtx(()=>se[9]||(se[9]=[e.createTextVNode("上一张")])),_:1,__:[9]},8,["disabled"]),e.createElementVNode("span",yd,e.toDisplayString(S.value+1)+" / "+e.toDisplayString(x.value.length),1),e.createVNode(G,{size:"small",disabled:S.value===x.value.length-1,onClick:U},{default:e.withCtx(()=>se[10]||(se[10]=[e.createTextVNode("下一张")])),_:1,__:[10]},8,["disabled"])])):e.createCommentVNode("",!0)]),x.value.length>1?(e.openBlock(),e.createElementBlock("div",gd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value,(P,Ke)=>(e.openBlock(),e.createElementBlock("div",{key:(P.name||"")+"-"+Ke,class:e.normalizeClass(["img-thumb-item",{active:Ke===S.value}]),onClick:Me=>me(Ke)},[P!=null&&P.blobUrl?(e.openBlock(),e.createBlock(fe,{key:0,src:P.blobUrl,fit:"cover",class:"thumb-image","preview-src-list":[P.blobUrl],"initial-index":0},null,8,["src","preview-src-list"])):(e.openBlock(),e.createElementBlock("div",kd,"加载失败")),e.createElementVNode("div",xd,e.toDisplayString(P.name||"-"),1)],10,bd))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",wd,[b.value?(e.openBlock(),e.createElementBlock("div",_d,[e.createVNode(_e,{class:"is-loading"},{default:e.withCtx(()=>[e.createVNode(we)]),_:1}),se[11]||(se[11]=e.createElementVNode("span",null,"图片加载中...",-1))])):(qe=re.value)!=null&&qe.blobUrl?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(fe,{ref_key:"imageRef",ref:I,src:re.value.blobUrl,fit:"contain",class:"preview-image","preview-src-list":[re.value.blobUrl],onLoad:ve},null,8,["src","preview-src-list"]),e.createElementVNode("canvas",{ref_key:"canvasRef",ref:R,class:"highlight-canvas"},null,512)],64)):(e.openBlock(),e.createElementBlock("div",Sd,[(ra=re.value)!=null&&ra.url?(e.openBlock(),e.createElementBlock("span",Ed,"图片加载失败")):(e.openBlock(),e.createElementBlock("span",Cd,"暂无图片"))]))])])):(e.openBlock(),e.createElementBlock("div",Dd,"暂无图片"))])])):e.createCommentVNode("",!0)}}}),Bd=pr._export_sfc(Td,[["__scopeId","data-v-48a4ecb1"]]),Nd={class:"cert-preview-body"},Ad={key:0,class:"pdf-preview-container"},zd={class:"thumbs"},Md=["onClick"],Id={class:"thumb-img"},Od=["src"],Ld={key:1,class:"thumb-loading"},Rd={class:"thumb-title"},$d={class:"viewer"},Vd={key:0,class:"viewer-img-wrap"},Fd=["src"],Pd={key:1,class:"viewer-loading"},jd=e.defineComponent({__name:"CertificatePreview",props:{visible:{type:Boolean},versions:{}},emits:["update:visible"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(""),o=e.ref(""),p=e.computed(()=>(r.versions||[]).find(w=>String(w.versionId)===String(i.value))),c=e.ref({}),u=e.ref(""),m=e.ref("证书附件.pdf"),g=()=>{try{Object.values(c.value||{}).forEach(w=>{w&&URL.revokeObjectURL(w)}),u.value&&URL.revokeObjectURL(u.value)}catch{}c.value={},u.value=""},y=async w=>{if(!w||w.fileType==="pdf")return;const q=Array.isArray(w.images)?w.images:[];for(const A of q){const j=A==null?void 0:A.url;if(!(!j||c.value[j]))try{const O=await M.platformDownloadFile({url:j}),E=URL.createObjectURL(O.data);c.value={...c.value,[j]:E}}catch{}}},d=async w=>{var A;if(!w||w.fileType!=="pdf"){u.value="";return}const q=w.sourceUrl||"";if(!q){u.value="";return}if(u.value){try{URL.revokeObjectURL(u.value)}catch{}u.value=""}try{console.log("[CertificatePreview] 下载PDF附件:",{url:q,versionId:w==null?void 0:w.versionId,certNo:w==null?void 0:w.certNo});const j=await M.platformDownloadFile({url:q});console.log("[CertificatePreview] PDF响应:",{url:q,status:j==null?void 0:j.status,size:(A=j==null?void 0:j.data)==null?void 0:A.size});const O=URL.createObjectURL(j.data);u.value=O;const E=w.certNo?String(w.certNo):"";m.value=E?`${E}.pdf`:"证书附件.pdf"}catch(j){console.error("[CertificatePreview] PDF加载失败:",{url:q,error:j}),u.value=""}};e.watch(()=>r.visible,async w=>{var A;if(!w){g();return}const q=(A=r.versions)==null?void 0:A[0];i.value=(q==null?void 0:q.versionId)||"",await y(q),await d(q)},{immediate:!0}),e.watch(()=>i.value,async()=>{var q,A;const w=p.value;if(!w){o.value="",u.value="";return}if(w.fileType==="pdf"){o.value="",await d(w);return}u.value="",o.value=((A=(q=w.images)==null?void 0:q[0])==null?void 0:A.url)||"",await y(w)},{immediate:!0});const D=()=>{n("update:visible",!1),g()};return e.onBeforeUnmount(()=>{g()}),(w,q)=>{const A=e.resolveComponent("el-empty"),j=e.resolveComponent("el-tab-pane"),O=e.resolveComponent("el-tabs"),E=e.resolveComponent("el-button"),_=e.resolveComponent("el-dialog");return e.openBlock(),e.createBlock(_,{"model-value":w.visible,title:"证书附件预览",width:"1100px","close-on-click-modal":!1,onClose:D},{footer:e.withCtx(()=>[e.createVNode(E,{id:"themeBorderButton",onClick:D},{default:e.withCtx(()=>q[1]||(q[1]=[e.createTextVNode("关闭")])),_:1,__:[1]})]),default:e.withCtx(()=>[w.versions&&w.versions.length>0?(e.openBlock(),e.createBlock(O,{key:0,modelValue:i.value,"onUpdate:modelValue":q[0]||(q[0]=x=>i.value=x),type:"card",class:"cert-version-tabs"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.versions,x=>(e.openBlock(),e.createBlock(j,{key:x.versionId,name:x.versionId,label:x.label},{default:e.withCtx(()=>[e.createElementVNode("div",Nd,[x.fileType==="pdf"?(e.openBlock(),e.createElementBlock("div",Ad,[u.value?(e.openBlock(),e.createBlock(pl.SsFilePreview,{key:1,fileName:m.value,blobUrl:u.value},null,8,["fileName","blobUrl"])):(e.openBlock(),e.createBlock(A,{key:0,description:"加载中"}))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",zd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.images||[],b=>(e.openBlock(),e.createElementBlock("div",{key:b.url,class:e.normalizeClass(["thumb",{active:b.url===o.value}]),onClick:S=>o.value=b.url},[e.createElementVNode("div",Id,[c.value[b.url]?(e.openBlock(),e.createElementBlock("img",{key:0,src:c.value[b.url]},null,8,Od)):(e.openBlock(),e.createElementBlock("div",Ld,"加载中"))]),e.createElementVNode("div",Rd,e.toDisplayString(b.name),1)],10,Md))),128))]),e.createElementVNode("div",$d,[o.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[c.value[o.value]?(e.openBlock(),e.createElementBlock("div",Vd,[e.createElementVNode("img",{class:"viewer-img",src:c.value[o.value]},null,8,Fd)])):(e.openBlock(),e.createElementBlock("div",Pd,"加载中"))],64)):(e.openBlock(),e.createBlock(A,{key:0,description:"暂无图片"}))])],64))])]),_:2},1032,["name","label"]))),128))]),_:1},8,["modelValue"])):(e.openBlock(),e.createBlock(A,{key:1,description:"暂无可预览的证书附件"}))]),_:1},8,["model-value"])}}}),Hd=pr._export_sfc(jd,[["__scopeId","data-v-220703c0"]]),Ud={class:"ocr-candidate-wrap"},qd={class:"ocr-candidate-left"},Wd={key:1},Gd={key:0},Kd={key:1},Yd={key:2},Jd={key:3},Xd={key:0,class:"ocr-candidate-right"},Zd={class:"ocr-candidate-actions"},Qd={key:1},ep={class:"dialog-footer"},ap={__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 r=(S=[])=>{const I=[],R=re=>{(re||[]).forEach(X=>{if(!X)return;const me=X.children||X.childrens||X.columns;Array.isArray(me)&&me.length>0?R(me):I.push(X)})};return R(S),I},n=a,i=l,o=e.computed(()=>{var S;return((S=d.value)==null?void 0:S.allowAdd)!==!1}),p=e.computed(()=>{var S;return((S=d.value)==null?void 0:S.allowReplace)!==!1}),c=S=>{if(!S)return[];if(Array.isArray(S))return S;if(typeof S=="string")try{const I=JSON.parse(S);return Array.isArray(I)?I:[]}catch{return[]}return[]},u=S=>{i("preview-file",S)},m=e.ref([]),g=e.ref(0),y=e.ref("");e.watch(()=>n.candidates,S=>{var I,R;m.value=(S||[]).map(re=>({...re,...(re==null?void 0:re.ocrRow)||{},selectedTargetId:(re==null?void 0:re.selectedTargetId)||"",__decision:re==null?void 0:re.__decision})),g.value=0,y.value=((R=(I=m.value)==null?void 0:I[0])==null?void 0:R.selectedTargetId)||""},{immediate:!0,deep:!0}),e.watch(()=>n.visible,S=>{var I,R;S&&(g.value=0,y.value=((R=(I=m.value)==null?void 0:I[0])==null?void 0:R.selectedTargetId)||"")});const d=e.computed(()=>{var I;const S=Number(g.value||0);return((I=m.value||[])==null?void 0:I[S])||null}),D=e.computed(()=>(r(n.columns||[])||[]).filter(R=>R&&R.prop).filter(R=>R.type!=="operate"&&R.label!=="操作"&&R.prop!=="operate")),w=e.computed(()=>D.value.filter(S=>S.label!=="证书附件"&&S.prop!=="证书附件")),q=S=>{if(!S)return;const I=(m.value||[]).findIndex(R=>(R==null?void 0:R.idx)===(S==null?void 0:S.idx));I>-1&&(g.value=I,y.value=(S==null?void 0:S.selectedTargetId)||"")},A=S=>{if(!S){y.value="";return}y.value=String((S==null?void 0:S.id)??"")},j=(S,I="")=>{const R=Number(g.value||0),re=m.value||[],X=re[R];X&&(X.__decision=S,X.selectedTargetId=I,y.value=I,m.value=[...re])},O=()=>j("skip",""),E=()=>j("add",""),_=()=>{if(!y.value){Ja.ElMessage.warning("请先选择要替换的目标记录");return}j("replace",y.value)},x=()=>{i("update:visible",!1)},b=()=>{const S=m.value||[];if(S.find(R=>(R==null?void 0:R.__decision)==="replace"&&!(R!=null&&R.selectedTargetId))){Ja.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}i("submit",S),i("update:visible",!1)};return(S,I)=>{const R=e.resolveComponent("el-table-column"),re=e.resolveComponent("svg-icon"),X=e.resolveComponent("el-table"),me=e.resolveComponent("el-button"),ue=e.resolveComponent("el-alert");return e.openBlock(),e.createBlock($r.ssDialog,{title:"OCR候选匹配",visible:a.visible,"close-on-click-modal":!1,width:"90%",style:{maxWidth:"1200px"},onBeforeDestroy:x},{default:e.withCtx(()=>{var U,W;return[e.createElementVNode("div",Ud,[e.createElementVNode("div",qd,[I[0]||(I[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:q},{default:e.withCtx(()=>[e.createVNode(R,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,Z=>(e.openBlock(),e.createBlock(R,{key:Z.prop,label:Z.label,prop:Z.prop,"min-width":Z.minWidth||160},{default:e.withCtx(({row:ae})=>[Z.label==="证书附件"||Z.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(ae==null?void 0:ae[Z.prop]).length>0?(e.openBlock(),e.createBlock(re,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(ve=>u({row:ae,prop:Z.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Wd,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((ae==null?void 0:ae[Z.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128)),e.createVNode(R,{label:"候选数",width:"90",fixed:"right"},{default:e.withCtx(({row:Z})=>[e.createTextVNode(e.toDisplayString(((Z==null?void 0:Z.candidates)||[]).length),1)]),_:1}),e.createVNode(R,{label:"处理状态",width:"120",fixed:"right"},{default:e.withCtx(({row:Z})=>[(Z==null?void 0:Z.__decision)==="replace"?(e.openBlock(),e.createElementBlock("span",Gd,"替换")):(Z==null?void 0:Z.__decision)==="add"?(e.openBlock(),e.createElementBlock("span",Kd,"新增")):(Z==null?void 0:Z.__decision)==="skip"?(e.openBlock(),e.createElementBlock("span",Yd,"跳过")):(e.openBlock(),e.createElementBlock("span",Jd,"未处理"))]),_:1})]),_:1},8,["data"])]),m.value&&m.value.length>0?(e.openBlock(),e.createElementBlock("div",Xd,[I[4]||(I[4]=e.createElementVNode("div",{class:"ocr-candidate-title"},"当前行候选记录(同编号)",-1)),e.createElementVNode("div",Zd,[e.createVNode(me,{id:"themeBorderButton",onClick:O},{default:e.withCtx(()=>I[1]||(I[1]=[e.createTextVNode("跳过本行")])),_:1,__:[1]}),e.createVNode(me,{id:"themeBorderButton",onClick:E,disabled:!o.value},{default:e.withCtx(()=>I[2]||(I[2]=[e.createTextVNode("新增本行")])),_:1,__:[2]},8,["disabled"]),e.createVNode(me,{class:"ok-button",id:"themeButton",onClick:_,disabled:!p.value||!y.value},{default:e.withCtx(()=>I[3]||(I[3]=[e.createTextVNode("替换选中记录")])),_:1,__:[3]},8,["disabled"])]),(((U=d.value)==null?void 0:U.candidates)||[]).length===0?(e.openBlock(),e.createBlock(ue,{key:0,title:"该编号暂无候选记录,可选择“新增本行”或“跳过本行”。",type:"info",closable:!1,"show-icon":"",style:{margin:"8px 0"}})):e.createCommentVNode("",!0),e.createVNode(X,{data:((W=d.value)==null?void 0:W.candidates)||[],border:"",stripe:"","max-height":"300",style:{width:"100%"},onCurrentChange:A,"highlight-current-row":""},{default:e.withCtx(()=>[e.createVNode(R,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(D.value,Z=>(e.openBlock(),e.createBlock(R,{key:Z.prop,label:Z.label,prop:Z.prop,"min-width":Z.minWidth||160},{default:e.withCtx(({row:ae})=>[Z.label==="证书附件"||Z.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(ae==null?void 0:ae[Z.prop]).length>0?(e.openBlock(),e.createBlock(re,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(ve=>u({row:ae,prop:Z.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Qd,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((ae==null?void 0:ae[Z.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128))]),_:1},8,["data"])])):e.createCommentVNode("",!0)])]}),footer:e.withCtx(()=>[e.createElementVNode("div",ep,[e.createVNode(me,{id:"themeBorderButton",onClick:x},{default:e.withCtx(()=>I[5]||(I[5]=[e.createTextVNode("取消")])),_:1,__:[5]}),e.createVNode(me,{class:"ok-button",id:"themeButton",onClick:b},{default:e.withCtx(()=>I[6]||(I[6]=[e.createTextVNode("提交已处理")])),_:1,__:[6]})])]),_:1},8,["visible"])}}},lp=pr._export_sfc(ap,[["__scopeId","data-v-89e0489c"]]),rp={class:"ocr-preview-content"},np={class:"ocr-preview-tip"},ip={class:"ocr-preview-table"},op={style:{display:"flex","align-items":"center",gap:"8px"}},tp={class:"dialog-footer"},sp={__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 r=a,n=l,i=e.ref([]),o=e.ref([]),p=e.ref([]);e.watch(()=>r.visible,D=>{D&&(i.value=JSON.parse(JSON.stringify(r.ocrPreviewData)),o.value=JSON.parse(JSON.stringify(r.ocrPreviewColumns)),p.value=[...r.ocrSelectedFields])});const c=(D,w)=>{const q=[...p.value];if(w)q.includes(D)||q.push(D);else{const A=q.indexOf(D);A>-1&&q.splice(A,1)}p.value=q,n("update:ocrSelectedFields",q)},u=(D,w,q)=>{n("fieldChange",{rowIndex:D,prop:w,value:q})},m=()=>{n("update:ocrPreviewData",i.value),n("confirm",i.value),n("update:visible",!1)},g=()=>{n("update:visible",!1)},y=D=>typeof D!="number"?"-":`${(D*100).toFixed(1)}%`,d=D=>typeof D!="number"?"#606266":D>=.9?"#67c23a":D>=.7?"#e6a23c":"#f56c6c";return(D,w)=>{const q=e.resolveComponent("el-alert"),A=e.resolveComponent("el-table-column"),j=e.resolveComponent("el-checkbox"),O=e.resolveComponent("el-input"),E=e.resolveComponent("el-table"),_=e.resolveComponent("el-button");return e.openBlock(),e.createBlock($r.ssDialog,{title:"OCR识别结果预览",visible:a.visible,onBeforeDestroy:g,width:"90%",style:{maxWidth:"1200px"}},{default:e.withCtx(()=>[e.createElementVNode("div",rp,[e.createElementVNode("div",np,[e.createVNode(q,{title:"请核对识别结果。系统将按 编号+名称+制造厂 规则匹配并替换;未唯一命中但有编号的,将进入候选选择;无编号则直接新增。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",ip,[e.createVNode(E,{data:i.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(A,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,x=>(e.openBlock(),e.createBlock(A,{key:x.prop,prop:x.prop,"min-width":x.minWidth||230,"class-name":x.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",op,[x.isAccuracy?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(j,{key:0,"model-value":p.value.includes(x.prop),onChange:b=>c(x.prop,b),onClick:w[0]||(w[0]=e.withModifiers(()=>{},["stop"]))},null,8,["model-value","onChange"])),e.createElementVNode("span",null,e.toDisplayString(x.label),1)])]),default:e.withCtx(({row:b,$index:S})=>[x.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:d(b[x.prop]),fontWeight:500})},e.toDisplayString(y(b[x.prop])),5)):(e.openBlock(),e.createBlock(O,{key:1,modelValue:b[x.prop],"onUpdate:modelValue":I=>b[x.prop]=I,size:"small",placeholder:"请输入"+x.label,onChange:I=>u(S,x.prop,I)},null,8,["modelValue","onUpdate:modelValue","placeholder","onChange"]))]),_:2},1032,["prop","min-width","class-name"]))),128))]),_:1},8,["data"])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",tp,[e.createVNode(_,{onClick:g,id:"themeBorderButton"},{default:e.withCtx(()=>w[1]||(w[1]=[e.createTextVNode("取消")])),_:1,__:[1]}),e.createVNode(_,{class:"ok-button",onClick:m,id:"themeButton"},{default:e.withCtx(()=>w[2]||(w[2]=[e.createTextVNode("确认")])),_:1,__:[2]})])]),_:1},8,["visible"])}}},cp=pr._export_sfc(sp,[["__scopeId","data-v-df66eb1f"]]),ri=a=>{var n;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 r=(n=le.analyzeSplitToContent(l,","))==null?void 0:n.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)),hn(i)));return r=r==null?void 0:r.join(","),r};function hc(a){return Ja.axios.post("http://222.92.178.198:8000/api/v1/excel-chat",a)}function up(a){return Ja.axios.get(a,{responseType:"blob"})}let ur="$R",dp="http://222.92.178.198:55002/AIRobot",yt=["Form","BarChart","FormText","FormBlock"];const Ct=a=>{var r,n;let l=(n=le.analyzeSplitToContent(a,"@"))==null?void 0:n[((r=le.analyzeSplitToContent(a,"@"))==null?void 0:r.length)-1];return!!(yt!=null&&yt.some(i=>l==null?void 0:l.includes(i)))},pp=async(a,l,r,n)=>{var o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me;let i=a;if(Ct(i==null?void 0:i[0])){let Le=yc(i),Ie=(o=Le==null?void 0:Le.filter)==null?void 0:o.join(","),de=[];(p=Le==null?void 0:Le.hideContents)==null||p.forEach(Ea=>{if(Ea){const Ge=Ea;Ge&&de.push(`(HideGroup=Yes, prop=${Ge})`)}});let De=(c=Le==null?void 0:Le.formContents)==null?void 0:c.filter(Ea=>{var Ge;return(Ge=Ea==null?void 0:Ea.filters)==null?void 0:Ge.includes("@ShowHide=Hide")});(De==null?void 0:De.length)>0&&(De==null||De.forEach(Ea=>{if(Ea){const Ge=Ea==null?void 0:Ea.prop;Ge&&de.push(`(Hide=Yes, prop=${Ge})`)}}));let Xe=(n==null?void 0:n.menuFilter)??[];return Array.isArray(Xe)||(Xe=Xe?[Xe]:[]),Xe=[...Xe,...de],Ie===""&&((u=Le==null?void 0:Le.formContents)==null?void 0:u.length)===0?void 0:{key:"Form",name:Le==null?void 0:Le.groupName,value:Le==null?void 0:Le.formContents,contents:Array.isArray((m=Le==null?void 0:Le.contents)==null?void 0:m[0])&&((y=(g=Le==null?void 0:Le.contents)==null?void 0:g[0])!=null&&y.every(Ea=>Array.isArray(Ea)))?[(D=(d=Le==null?void 0:Le.contents)==null?void 0:d[0])==null?void 0:D[r]]:[Le==null?void 0:Le.contents],filter:"("+Ie+")",menuFilter:Xe,groupFilter:Le==null?void 0:Le.groupFilters}}else if(((w=i==null?void 0:i[0])==null?void 0:w[0])!=="&"){let Le=gc(i,n),Ie="";(q=Le==null?void 0:Le.tableFilter)!=null&&q.includes(ur)?Le.tableFilter=(A=Le==null?void 0:Le.tableFilter)==null?void 0:A.replace(ur,""):Ie=(E=(O=(j=Le==null?void 0:Le.tableFilter)==null?void 0:j.replace("(",ur))==null?void 0:O.split(ur))==null?void 0:E[0];let de=[];Le!=null&&Le.tableFilter&&((_=le.analyzeSplitToContent(Le==null?void 0:Le.tableFilter,","))==null||_.forEach(Xe=>{Xe!=null&&Xe.includes("@ShowHide=Hide")&&de.push("HideGroup=Yes")}));let De=(n==null?void 0:n.menuFilter)??[];return Array.isArray(De)||(De=De?[De]:[]),De=[...De,...de],{key:"Table",name:Le==null?void 0:Le.groupName,tableColumns:Le==null?void 0:Le.tableColumns,assistColumn:Le==null?void 0:Le.columns,tableContents:l===1?Le==null?void 0:Le.tableContents:(b=(x=Le==null?void 0:Le.tableContents)==null?void 0:x[r])!=null&&b.every(Xe=>Array.isArray(Xe))?(S=Le==null?void 0:Le.tableContents)==null?void 0:S[r]:[(I=Le==null?void 0:Le.tableContents)==null?void 0:I[r]],filter:Le==null?void 0:Le.tableFilter,menuFilter:De,quotePage:Ie!==""?((X=(re=(R=Ie==null?void 0:Ie.replace("*",ur))==null?void 0:R.split(ur))==null?void 0:re[0])==null?void 0:X.replaceAll(":","/"))??"":void 0,quoteGroup:Ie!==""?((ve=(ae=(Z=(W=(U=(ue=(me=Ie==null?void 0:Ie.replace("*",ur))==null?void 0:me.split(ur))==null?void 0:ue[1])==null?void 0:U.replace("{",ur))==null?void 0:W.split(ur))==null?void 0:Z[0])==null?void 0:ae.split(":"))==null?void 0:ve.filter(Xe=>Xe!==""))??[]:[],relatedQuotes:Le==null?void 0:Le.relatedQuotes,fatherSyncContents:Le==null?void 0:Le.fatherSyncContents,sonSyncContents:Le==null?void 0:Le.sonSyncContents,calculatorFilters:(Le==null?void 0:Le.calculatorFilters)??[]}}else{let Le=[{label:"序号",prop:"sort"},{label:"函数名称",prop:"函数名称"},{label:"函数关联名",prop:"函数关联名"},{label:"函数参数",prop:"函数参数"},{label:"输出值",prop:"输出值"},{label:"导入文件",prop:"导入文件",formType:"Upload"}],Ie=i==null?void 0:i[0];Ie=Ie==null?void 0:Ie.slice(1,Ie==null?void 0:Ie.length),Ie=le.analyzeSplitToContent(Ie,":"),Ie=Ie==null?void 0:Ie[(Ie==null?void 0:Ie.length)-1];let de=[];de.push("1");let De=Ie==null?void 0:Ie.replace("(",ur);De=(ze=De==null?void 0:De.split(ur))==null?void 0:ze[0],de.push(De);let Xe=Ie==null?void 0:Ie.replace("(",ur);if(Xe=(te=Xe==null?void 0:Xe.split(ur))==null?void 0:te[1],Xe=(se=(N=Xe==null?void 0:Xe.replace(")",ur))==null?void 0:N.split(ur))==null?void 0:se[0],(fe=(G=Xe==null?void 0:Xe.replace(",",ur))==null?void 0:G.split(ur))==null||fe.forEach(Ea=>{de.push(Ea)}),de.push(""),de.push(""),(we=de==null?void 0:de[2])!=null&&we.includes(".xlsx")||(_e=de==null?void 0:de[2])!=null&&_e.includes(".xls"))try{let Ea=dp+"/"+(de==null?void 0:de[2]),Ge=await up(Ea),$=`生成js函数名称为${de==null?void 0:de[1]}的函数,规则为:`+(de==null?void 0:de[3])+"。根据上述描述获取对应的总结性详细可运行js函数,不需要任何注释。";if((Ge==null?void 0:Ge.status)===200){let V=Ge==null?void 0:Ge.data;const ee=new FormData;ee.append("file",V,de==null?void 0:de[2]),ee.append("query",$);let ce=await hc(ee);ce=(P=(ra=(qe=ce==null?void 0:ce.data)==null?void 0:qe.data)==null?void 0:ra.response)==null?void 0:P.replace("generateResult",de==null?void 0:de[1]),de[de.length-2]=ce,de[de.length-1]=[{name:(Me=(Ke=de==null?void 0:de[2])==null?void 0:Ke.split("."))==null?void 0:Me[0],url:Ea}]}}catch{}return de=[de],{key:"Method",name:[],tableContents:de,tableColumns:Le}}},fp=(a,l)=>{var n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea;let r=(i=(n=le.analyzeSplitToContent(a,"="))==null?void 0:n.filter(Ge=>Ge!=="="))==null?void 0:i.map(Ge=>((Ge==null?void 0:Ge[(Ge==null?void 0:Ge.length)-1])==="="&&(Ge=Ge==null?void 0:Ge.slice(0,(Ge==null?void 0:Ge.length)-1)),Ge));if(Ct(r==null?void 0:r[1])||Ct(r==null?void 0:r[0])){let Ge=bp(r);if(Ge!=null&&Ge.formContents){let he=(o=Ge==null?void 0:Ge.filter)==null?void 0:o.join(","),pa=[];(p=Ge==null?void 0:Ge.hideContents)==null||p.forEach(ya=>{if(ya){const Ca=ya;Ca&&pa.push(`(HideGroup=Yes, prop=${Ca})`)}});let ia=(c=Ge==null?void 0:Ge.formContents)==null?void 0:c.filter(ya=>{var Ca;return(Ca=ya==null?void 0:ya.filters)==null?void 0:Ca.includes("@ShowHide=Hide")});(ia==null?void 0:ia.length)>0&&(ia==null||ia.forEach(ya=>{if(ya){const Ca=ya==null?void 0:ya.prop;Ca&&pa.push(`(Hide=Yes, prop=${Ca})`)}}));let Ve=(l==null?void 0:l.menuFilter)??[];return Array.isArray(Ve)||(Ve=Ve?[Ve]:[]),Ve=[...Ve,...pa],he===""&&((u=Ge==null?void 0:Ge.formContents)==null?void 0:u.length)===0?void 0:{key:"Form",name:Ge==null?void 0:Ge.groupName,value:Ge==null?void 0:Ge.formContents,contents:[Ge==null?void 0:Ge.contents],filter:"("+he+")",menuFilter:Ve,groupFilter:Ge==null?void 0:Ge.groupFilters,calculatorFilters:Ge==null?void 0:Ge.calculatorFilters}}let $=(y=(g=(m=Ge==null?void 0:Ge.filter)==null?void 0:m.replace("@",ur))==null?void 0:g.split(ur))==null?void 0:y[0],V=(w=(D=(d=Ge==null?void 0:Ge.filter)==null?void 0:d.replace("(",ur))==null?void 0:D.split(ur))==null?void 0:w[1],ee=(j=(A=(q=Ge==null?void 0:Ge.filter)==null?void 0:q.replace("(",ur))==null?void 0:A.split(ur))==null?void 0:j[0];ee="@"+((O=ee==null?void 0:ee.split("@"))==null?void 0:O[1]),V=V==null?void 0:V.slice(0,(V==null?void 0:V.length)-1),V=(_=(E=le.analyzeSplitToContent(V,","))==null?void 0:E.map(he=>(he=ee+he,he)))==null?void 0:_.join("");let ce=$+"("+V+")";return{key:"Form",name:Ge==null?void 0:Ge.group,filter:ce,formPage:((S=(b=(x=$==null?void 0:$.replace("*",ur))==null?void 0:x.split(ur))==null?void 0:b[0])==null?void 0:S.replaceAll(":","/"))??"",formGroup:((U=(ue=(me=(X=(re=(R=(I=$==null?void 0:$.replace("*",ur))==null?void 0:I.split(ur))==null?void 0:R[1])==null?void 0:re.replace("{",ur))==null?void 0:X.split(ur))==null?void 0:me[0])==null?void 0:ue.split(":"))==null?void 0:U.filter(he=>he!==""))??[],value:[],menuFilter:l==null?void 0:l.menuFilter,contents:[]}}else{let Ge=r==null?void 0:r.filter((ia,Ve)=>Ve!==0);Ge=Ge==null?void 0:Ge.join("");let $=gc(r,l,Ge),V="";(W=$==null?void 0:$.tableFilter)!=null&&W.includes(ur)?$.tableFilter=(Z=$==null?void 0:$.tableFilter)==null?void 0:Z.replace(ur,""):V=(ze=(ve=(ae=$==null?void 0:$.tableFilter)==null?void 0:ae.replace("(",ur))==null?void 0:ve.split(ur))==null?void 0:ze[0];let ee=(se=(N=(te=$==null?void 0:$.tableFilter)==null?void 0:te.replace("(",ur))==null?void 0:N.split(ur))==null?void 0:se[0];ee=[{menus:(fe=(G=ee==null?void 0:ee.split("*"))==null?void 0:G[0])==null?void 0:fe.replaceAll(":","/"),groups:((_e=(we=ee==null?void 0:ee.split("*"))==null?void 0:we[1])==null?void 0:_e.split(":"))??[]}];let ce=(P=(ra=(qe=$==null?void 0:$.tableFilter)==null?void 0:qe.replace("(",ur))==null?void 0:ra.split(ur))==null?void 0:P[1];(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));let he=[];$!=null&&$.tableFilter&&((Ke=le.analyzeSplitToContent($==null?void 0:$.tableFilter,","))==null||Ke.forEach(ia=>{ia!=null&&ia.includes("@ShowHide=Hide")&&he.push("HideGroup=Yes")}));let pa=(l==null?void 0:l.menuFilter)??[];return Array.isArray(pa)||(pa=pa?[pa]:[]),pa=[...pa,...he],{key:"Table",name:$==null?void 0:$.groupName,filter:$==null?void 0:$.tableFilter,tableColumns:$==null?void 0:$.tableColumns,tableContents:$==null?void 0:$.tableContents,quotePage:V!==""?((Ie=(Le=(Me=V==null?void 0:V.replace("*",ur))==null?void 0:Me.split(ur))==null?void 0:Le[0])==null?void 0:Ie.replaceAll(":","/"))??"":void 0,quoteGroup:V!==""?((Ea=(Xe=(De=(de=V==null?void 0:V.replace("*",ur))==null?void 0:de.split(ur))==null?void 0:De[1])==null?void 0:Xe.split(":"))==null?void 0:Ea.filter(ia=>ia!==""))??[]:[],menuFilter:pa,relatedQuotes:ee,fatherSyncContents:($==null?void 0:$.fatherSyncContents)??[],sonSyncContents:($==null?void 0:$.sonSyncContents)??[],calculatorFilters:($==null?void 0:$.calculatorFilters)??[]}}},hp=async(a,l)=>{let r=[],n=l==null?void 0:l.length;return l=l==null?void 0:l.map(async(i,o)=>{let p=[];i=i==null?void 0:i.map(async c=>{var u,m;if(p.push(c),((u=le.analyzeSplitToContent(a,"="))==null?void 0:u.length)<=2){if(((m=le.analyzeSplitToContent(a,"="))==null?void 0:m.length)!==0){const g=await pp(le.analyzeSplitToContent(a,"="),n,o,c);g&&p.push(g)}}else p.push(fp(a,c))}),await Promise.all(i),r.push(p)}),await Promise.all(l),r};let Wi="/",vp="$",zn="$R";const vc=a=>{var r,n,i;let l="";if((a==null?void 0:a.length)>1){let o=a==null?void 0:a.filter((p,c)=>c!==0);o=o==null?void 0:o.join(""),o=le.analyzerSplitToWord(o,")"),(o==null?void 0:o.length)!==1?(o==null?void 0:o[(o==null?void 0:o.length)-1])===")"?o=o==null?void 0:o.join(""):o=(r=o==null?void 0:o.filter((p,c)=>c!==(o==null?void 0:o.length)-1))==null?void 0:r.join(""):o=o==null?void 0:o[0],l="("+o,((i=a==null?void 0:a[0])==null?void 0:i[((n=a==null?void 0:a[0])==null?void 0:n.length)-2])==="@"&&(l="@"+l)}return{filter:l}},mc=(a,l=[])=>{let r=(a==null?void 0:a.map(o=>{var p,c;return(c=o==null?void 0:o.key)==null?void 0:c.slice(1,(p=o==null?void 0:o.key)==null?void 0:p.length)}))??[],n=[];r==null||r.forEach(o=>{var p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me;if(o===""&&(o="算法库:通用算法"),o!=null&&o.includes(vp)){let ue="",U=!0,W=le.analyzerSplitToWord(o,"(");(W==null?void 0:W.length)>1&&(ue="("+((p=le.analyzerSplitToWord(W==null?void 0:W[1],")"))==null?void 0:p[0]),((u=W==null?void 0:W[0])==null?void 0:u[((c=W==null?void 0:W[0])==null?void 0:c.length)-2])==="@"&&(ue="@"+ue));let Z=o;Z=Z==null?void 0:Z.replace(ue,""),ue=hn(ue),ue=(m=le.analyzeSplitToContent(ue,","))==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)),ue!=null&&ue.includes("@ShowHide=Hide")&&(U=!1);let ae=(g=Z==null?void 0:Z.replace("$",zn))==null?void 0:g.split(zn),ve=ae==null?void 0:ae[1],ze=ae==null?void 0:ae[0];ze!=null&&ze.includes("[")&&(ze=(d=(y=ze==null?void 0:ze.replace("[",zn))==null?void 0:y.split(zn))==null?void 0:d[0],ve=ve+":["+((q=(w=(D=ae==null?void 0:ae[0])==null?void 0:D.replace("[",zn))==null?void 0:w.split(zn))==null?void 0:q[1])),ze=(j=(A=ze==null?void 0:ze.replaceAll(":","/"))==null?void 0:A.replaceAll("{",""))==null?void 0:j.replaceAll("}",""),(ze==null?void 0:ze[(ze==null?void 0:ze.length)-1])!=="/"&&(ze=ze+"/"),ve=((O=ze==null?void 0:ze.split("/"))==null?void 0:O[0])+":"+ve;let N="";if(!(ve!=null&&ve.includes("[")))N=ve==null?void 0:ve.replaceAll(":","/"),n==null||n.push({path:N,isShow:U,filter:ue,fatherPath:ze});else{let se=(_=(E=ve==null?void 0:ve.replace("[",zn))==null?void 0:E.split(zn))==null?void 0:_[1];se=se==null?void 0:se.slice(0,(se==null?void 0:se.length)-1),se=(x=le.analyzeSplitToContent(se,","))==null?void 0:x.map(G=>((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)),G)),se==null||se.forEach(G=>{var fe,we;N=((we=(fe=ve==null?void 0:ve.replace("[",zn))==null?void 0:fe.split(zn))==null?void 0:we[0])+G,N=N==null?void 0:N.replaceAll(":","/"),n==null||n.push({path:N,isShow:U,filter:ue,fatherPath:ze})})}}else{let ue="",U=!0,W=le.analyzerSplitToWord(o,"(");(W==null?void 0:W.length)>1&&(ue=(b=vc(W))==null?void 0:b.filter);let Z=o;if(Z=Z==null?void 0:Z.replace(ue,""),(ue==null?void 0:ue[0])==="("){ue=ue==null?void 0:ue.slice(1,(ue==null?void 0:ue.length)-1);let ve=[];(S=le.analyzeSplitToContent(ue,","))==null||S.forEach(ze=>{(ze==null?void 0:ze[(ze==null?void 0:ze.length)-1])===","&&(ze=ze==null?void 0:ze.slice(0,(ze==null?void 0:ze.length)-1)),(ze==null?void 0:ze[0])==="("&&(ze=ze==null?void 0:ze.slice(1,(ze==null?void 0:ze.length)-1)),(ze==null?void 0:ze[0])!=="@"&&(ze="@"+ze),ve.push(hn(ze))}),ue=ve==null?void 0:ve.join(",")}else ue=hn(ue);ue=(I=le.analyzeSplitToContent(ue,","))==null?void 0:I.map(ve=>((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)),ue!=null&&ue.includes("@ShowHide=Hide")&&(U=!1),(Z==null?void 0:Z[(Z==null?void 0:Z.length)-1])==="}"&&(Z=Z+":"),Z=(R=Z==null?void 0:Z.replaceAll("{",""))==null?void 0:R.replaceAll("}","");let ae="";if(Z!=null&&Z.includes("[")){let ve=(re=Z==null?void 0:Z.replace("[",zn))==null?void 0:re.split(zn),ze=ve==null?void 0:ve[1];ze=ze==null?void 0:ze.slice(0,(ze==null?void 0:ze.length)-1),(me=(X=le.analyzeSplitToContent(ze,","))==null?void 0:X.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)))==null||me.forEach(te=>{ae=(ve==null?void 0:ve[0])+te,ae=ae==null?void 0:ae.replaceAll(":","/"),n==null||n.push({path:ae,isShow:U,filter:ue})})}else ae=Z==null?void 0:Z.replaceAll(":","/"),n==null||n.push({path:ae,isShow:U,filter:ue})}});let i=M.cloneDeep(n);return(l==null?void 0:l.length)>0&&(i=l),i=i==null?void 0:i.filter(o=>{var p,c,u,m;return!(o!=null&&o.fatherPath)&&((c=(p=o==null?void 0:o.path)==null?void 0:p.split(Wi))==null?void 0:c.length)>1&&((m=(u=o==null?void 0:o.path)==null?void 0:u.split(Wi))==null?void 0:m[1])===""}),i=i==null?void 0:i.map(o=>{var p;return o.path=(p=o.path)==null?void 0:p.replace(Wi,""),o.path}),(i==null?void 0:i.length)>0&&(n=n==null?void 0:n.map(o=>{var c,u,m,g,y,d,D;let p=i==null?void 0:i.find(w=>{var q;return(q=o==null?void 0:o.path)==null?void 0:q.includes(w)});return!(o!=null&&o.fatherPath)&&p&&!((c=o==null?void 0:o.path)!=null&&c.includes(Wi))&&!(i!=null&&i.find(w=>(o==null?void 0:o.path)===w))&&(o.path=p+Wi+((D=(m=(u=o==null?void 0:o.path)==null?void 0:u.split(p))==null?void 0:m[1])==null?void 0:D.slice(1,(d=(y=(g=o==null?void 0:o.path)==null?void 0:g.split(p))==null?void 0:y[1])==null?void 0:d.length))),o})),n},mp=(a,l)=>mc([{key:a}],l),yp=async(a,l)=>{const r=[],n=mp(a==null?void 0:a.key,l);return n&&(n==null?void 0:n.length)>0&&(n==null||n.forEach(o=>{r.push([{key:"path",value:o==null?void 0:o.path,parentPath:(o==null?void 0:o.parentPath)??"",isShow:o==null?void 0:o.isShow,menuFilter:o==null?void 0:o.filter}])})),await hp(a==null?void 0:a.value,r)};let ml="$R",Yi="[Any]";const gp=a=>{var n;let l=[],r=a;return(n=le.chunkArray(r))==null||n.forEach(i=>{var m,g,y,d,D;let o="",p=[],c="";(i==null?void 0:i.length)>1&&(c="@"+(i==null?void 0:i[0]),c=hn(c));let u=(i==null?void 0:i.length)===1?i==null?void 0:i[0]:i==null?void 0:i[1];u=u==null?void 0:u.slice(1,u==null?void 0:u.length),o=(g=(m=u==null?void 0:u.replace("(",ml))==null?void 0:m.split(ml))==null?void 0:g[0],u=(d=(y=u==null?void 0:u.replace("(",ml))==null?void 0:y.split(ml))==null?void 0:d[1],u=u==null?void 0:u.slice(0,(u==null?void 0:u.length)-1),p=(D=le.analyzeSplitToContent(u,","))==null?void 0:D.map(w=>((w==null?void 0:w[(w==null?void 0:w.length)-1])===","&&(w=w==null?void 0:w.slice(0,(w==null?void 0:w.length)-1)),w)),l.push({functionName:o,functionRelatedWords:p,calculatorFilter:c})}),l},bp=a=>{var r,n,i;let l={};if(((r=a==null?void 0:a[1])==null?void 0:r[0])==="&"){let o=a==null?void 0:a[0],p=a==null?void 0:a[1];p=le.analyzeSplitToContent(p,":"),p!=null&&p[1]&&(p==null?void 0:p[1])!==""&&(o=o+":"+(p==null?void 0:p[1])),p=p==null?void 0:p[0],p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1),p=[p],o=[o],o=yc(o),l.filter=o==null?void 0:o.filter,l.contents=o==null?void 0:o.contents,l.formContents=o==null?void 0:o.formContents,l.groupFilters=o==null?void 0:o.groupFilters,l.groupName=o==null?void 0:o.groupName,l.hideContents=o==null?void 0:o.hideContents,l.calculatorFilters=gp(p)??[]}else{let p=a==null?void 0:a[0];(p==null?void 0:p[0])==="*"&&(p=p==null?void 0:p.slice(1,p==null?void 0:p.length)),p=p==null?void 0:p.split(":"),l.group=p;let c=a==null?void 0:a[1],u;c!=null&&c.includes("{")?u=(i=(n=c==null?void 0:c.replaceAll("{",""))==null?void 0:n.replaceAll("}",""))==null?void 0:i.replaceAll(Yi,""):u=c==null?void 0:c.replaceAll(Yi,""),(u==null?void 0:u[0])==="$"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length)),l.filter=u}return l},yc=a=>{var d,D,w,q,A,j;let l=[],r=[],n=[],i=[],o=[],p=[],c="",u=a==null?void 0:a[0];(u==null?void 0:u[0])==="*"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length));let m=le.analyzeSplitToContent(u,":");(d=m==null?void 0:m.filter(O=>(O==null?void 0:O[0])!=="{"&&(O==null?void 0:O[0])!=="["))==null||d.forEach(O=>{var _,x,b;(O==null?void 0:O[(O==null?void 0:O.length)-1])===":"&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1));let E=le.analyzerSplitToWord(O,"(");if((E==null?void 0:E.length)>1){c=(_=vc(E))==null?void 0:_.filter;let S=O==null?void 0:O.replace(c,"");if(n.push(S),(c==null?void 0:c[0])==="("){c=c==null?void 0:c.slice(1,(c==null?void 0:c.length)-1);let I=[];(x=le.analyzeSplitToContent(c,","))==null||x.forEach(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==null?void 0:R.slice(1,(R==null?void 0:R.length)-1)),(R==null?void 0:R[0])!=="@"&&(R="@"+R),I.push(hn(R))}),c=I==null?void 0:I.join(",")}else c=hn(c);c=(b=le.analyzeSplitToContent(c,","))==null?void 0:b.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)),c!=null&&c.includes("@ShowHide=Hide")&&p.push(S),i=[...i,...c]}else n.push(E==null?void 0:E[0])});let g=(D=m==null?void 0:m.filter(O=>(O==null?void 0:O[0])==="{"))==null?void 0:D[0],y=(w=m==null?void 0:m.filter(O=>(O==null?void 0:O[0])==="["))==null?void 0:w[0];return l=Li(y??""),l!=null&&l.every(O=>Array.isArray(O))&&(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)),o=(q=le.analyzeSplitToContent(g,"@"))==null?void 0:q[1],o="@"+o,g=g==null?void 0:g.replace(o,""),o=hn(o),o=(A=le.analyzeSplitToContent(o,","))==null?void 0:A.map(O=>((O==null?void 0:O[(O==null?void 0:O.length)-1])===","&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1)),O)),(g==null?void 0:g[0])==="{"&&(g=g==null?void 0:g.slice(1,(g==null?void 0:g.length)-1)),g=(j=le.analyzeSplitToContent(g,","))==null?void 0:j.map(O=>((O==null?void 0:O[(O==null?void 0:O.length)-1])===","&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1)),O)),g==null||g.forEach((O,E)=>{var ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja;let _=[],x=[],b=[],S="",I="",R=!1,re,X=[],me=[],ue=[],U="Input",W=[],Z=[];if(O!=null&&O.includes("==")){re=(ae=O==null?void 0:O.split("=="))==null?void 0:ae[0];let sa=(ve=O==null?void 0:O.split("=="))==null?void 0:ve[1],Pe="";((ze=le.analyzeSplitToContent(sa,"$"))==null?void 0:ze.length)>1&&((te=le.analyzeSplitToContent(sa,"$"))==null?void 0:te[0])!=="$"?(Pe=(N=le.analyzeSplitToContent(sa,"$"))==null?void 0:N[0],Pe=Pe==null?void 0:Pe.slice(0,(Pe==null?void 0:Pe.length)-1)):((se=le.analyzeSplitToContent(sa,"}"))==null?void 0:se.length)>1&&(Pe=(G=le.analyzeSplitToContent(sa,"}"))==null?void 0:G[1]);let ma=sa==null?void 0:sa.replace(Pe,"");if((Pe==null?void 0:Pe[0])==="("&&(Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1)),(fe=le.analyzeSplitToContent(Pe,","))==null||fe.forEach(Qe=>{var $e;(Qe==null?void 0:Qe[0])!=="@"&&(Qe="@"+Qe),(Qe==null?void 0:Qe[(Qe==null?void 0:Qe.length)-1])===","&&(Qe=Qe==null?void 0:Qe.slice(0,(Qe==null?void 0:Qe.length)-1));let Oe=hn(Qe);($e=le.analyzeSplitToContent(Oe,","))==null||$e.forEach(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)),_.push(ne)})}),(ma==null?void 0:ma[0])==="$"&&(ma=ma==null?void 0:ma.slice(1,ma==null?void 0:ma.length)),ma!=null&&ma.includes("&")){let Qe=ma;if((ma==null?void 0:ma[0])==="("){let $e=(we=le.analyzeSplitToContent(ma,"&"))==null?void 0:we.map(ne=>((ne==null?void 0:ne[(ne==null?void 0:ne.length)-1])==="&"&&(ne=ne==null?void 0:ne.slice(0,(ne==null?void 0:ne.length)-1)),ne));Qe=$e==null?void 0:$e[1],$e=$e==null?void 0:$e[0],($e==null?void 0:$e[0])!=="@"&&($e="@"+$e),S=hn($e)}(Qe==null?void 0:Qe[0])==="&"&&(Qe=Qe==null?void 0:Qe.slice(1,Qe==null?void 0:Qe.length)),I=(qe=(_e=Qe==null?void 0:Qe.replace("(",ml))==null?void 0:_e.split(ml))==null?void 0:qe[0],b=(P=(ra=Qe==null?void 0:Qe.replace("(",ml))==null?void 0:ra.split(ml))==null?void 0:P[1],b=[b==null?void 0:b.slice(0,(b==null?void 0:b.length)-1)],U="Input"}else{let Qe=(Ke=ma==null?void 0:ma.replace("*",ml))==null?void 0:Ke.split(ml);X=(Me=Qe==null?void 0:Qe[0])==null?void 0:Me.split(":"),me=(Ie=(Le=le.analyzeSplitToContent(Qe==null?void 0:Qe[1],":"))==null?void 0:Le.filter((Oe,$e)=>{var ne,We;return $e!==((We=(ne=Qe==null?void 0:Qe[1])==null?void 0:ne.split(":"))==null?void 0:We.length)-1}))==null?void 0:Ie.map(Oe=>((Oe==null?void 0:Oe[(Oe==null?void 0:Oe.length)-1])===":"&&(Oe=Oe==null?void 0:Oe.slice(0,(Oe==null?void 0:Oe.length)-1)),Oe)),ue=(De=(de=le.analyzeSplitToContent(Qe==null?void 0:Qe[1],":"))==null?void 0:de.filter((Oe,$e)=>{var ne,We;return $e===((We=(ne=Qe==null?void 0:Qe[1])==null?void 0:ne.split(":"))==null?void 0:We.length)-1}))==null?void 0:De[0],ue=(Ea=(Xe=ue==null?void 0:ue.replaceAll("{",""))==null?void 0:Xe.replaceAll("}",""))==null?void 0:Ea.split(":"),U="Select"}if(re!=null&&re.includes("@")){let Qe=le.analyzeSplitToContent(re,"@");re=Qe==null?void 0:Qe[0],re=re==null?void 0:re.slice(0,(re==null?void 0:re.length)-1),Qe="@"+(Qe==null?void 0:Qe[1]),Qe=hn(Qe),_=(Ge=le.analyzeSplitToContent(Qe,","))==null?void 0:Ge.map(Oe=>((Oe==null?void 0:Oe[(Oe==null?void 0:Oe.length)-1])===","&&(Oe=Oe==null?void 0:Oe.slice(0,(Oe==null?void 0:Oe.length)-1)),Oe))}}else if((($=le.analyzeSplitToContent(O,"="))==null?void 0:$.length)>1)if(U="Select",re=(ee=(V=O==null?void 0:O.replace("=",ml))==null?void 0:V.split(ml))==null?void 0:ee[0],!(O!=null&&O.includes("If")))W=(he=(ce=O==null?void 0:O.replace("=",ml))==null?void 0:ce.split(ml))==null?void 0:he[1],W=W==null?void 0:W.split("||");else{let sa=(ia=(pa=O==null?void 0:O.replace("=",ml))==null?void 0:pa.split(ml))==null?void 0:ia[1];Z=(Ve=le.analyzeSplitToContent(sa,")"))==null?void 0:Ve.filter(Pe=>!(Pe!=null&&Pe.includes("If"))),Z=Z==null?void 0:Z.map(Pe=>((Pe==null?void 0:Pe[0])==="("&&(Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1)),Pe=Pe==null?void 0:Pe.split("||"),Pe)),x=(ya=le.analyzeSplitToContent(sa,")"))==null?void 0:ya.filter(Pe=>Pe==null?void 0:Pe.includes("If")),x=x==null?void 0:x.map(Pe=>((Pe==null?void 0:Pe[0])==="|"&&(Pe=Pe==null?void 0:Pe.slice(2,Pe==null?void 0:Pe.length)),(Pe==null?void 0:Pe[0])==="("&&(Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1)),(Pe==null?void 0:Pe[0])!=="@"&&(Pe="@"+Pe),Pe))}else if(((Ca=le.analyzeSplitToContent(O,"@"))==null?void 0:Ca.length)>1){re=(Ce=le.analyzeSplitToContent(O,"@"))==null?void 0:Ce[0],(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 sa="@"+((Fa=le.analyzeSplitToContent(O,"@"))==null?void 0:Fa[1]);sa=hn(sa),_=(Ta=le.analyzeSplitToContent(sa,","))==null?void 0:Ta.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)),_!=null&&_.find(Pe=>Pe==null?void 0:Pe.includes("@Type"))&&(U=(ja=(fa=_==null?void 0:_.find(Pe=>Pe==null?void 0:Pe.includes("@Type")))==null?void 0:fa.split("="))==null?void 0:ja[1])}else re=O;_!=null&&_.includes("@ShowHide=Hide")&&(R=!0),r.push({prop:re,label:re,value:"",menuPath:X,groups:me,columns:ue,type:U,options:W,allContents:Z,filters:_,width:g==null?void 0:g.length,isFormColHidden:R,filterContents:x,functionName:I,functionRelatedWords:b,calculatorFilter:S})}),{groupName:n,groupFilters:i,formContents:r,contents:l,filter:o,hideContents:p}},Li=a=>{var n,i;if(!a||typeof a!="string")return[];let l=[],r=a.slice(1,(a==null?void 0:a.length)-1);if((r==null?void 0:r[0])!=="[")(n=le.analyzeSplitToContent(r,","))==null||n.forEach(o=>{(o==null?void 0:o[(o==null?void 0:o.length)-1])===","&&(o=o.slice(0,(o==null?void 0:o.length)-1)),l.push(o??"")}),(r==null?void 0:r[(r==null?void 0:r.length)-1])===","&&l.push("");else{let o=[];(i=le.analyzeSplitToContent(r,","))==null||i.forEach(p=>{(p==null?void 0:p[(p==null?void 0:p.length)-1])===","&&(p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1)),o.push(Li(p))}),l=o}return l},Dt=(a,l)=>{var j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va;let r,n=[],i=[],o=[],p=[],c=[],u=[],m=[],g="Input",y,d="",D="",w="",q=[],A="";if(a!=null&&a.includes("==")||a!=null&&a.includes("=")||a!=null&&a.includes("@")||a!=null&&a.includes("||"))if(r=(j=a==null?void 0:a.split("=="))==null?void 0:j[0],y=(O=a==null?void 0:a.split("=="))==null?void 0:O[0],g="Select",a!=null&&a.includes("=")&&!(a!=null&&a.includes("=="))&&!((x=(_=(E=a==null?void 0:a.replace("=",ml))==null?void 0:E.split(ml))==null?void 0:_[1])!=null&&x.includes("If")))if(r=le.analyzeSplitToContent(a,"@"),r=r==null?void 0:r[0],(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=(S=(b=r==null?void 0:r.replace("=",ml))==null?void 0:b.split(ml))==null?void 0:S[0],r!=null&&r.includes("&")&&(r=(R=(I=r==null?void 0:r.replace("&",ml))==null?void 0:I.split(ml))==null?void 0:R[0]),y=r,((re=le.analyzeSplitToContent(a,"@"))==null?void 0:re.length)>1&&!(a!=null&&a.includes("||"))){if(!(a!=null&&a.includes("&"))){let Ae=(X=le.analyzeSplitToContent(a,"@"))==null?void 0:X[1];if((Ae==null?void 0:Ae[0])!=="@"&&(Ae="@"+Ae),Ae=hn(Ae),D=Ae,D!=null&&D.includes("@Type")){let Be=le.analyzeSplitToContent(D,",");Be=Be==null?void 0:Be.map(Ye=>((Ye==null?void 0:Ye[(Ye==null?void 0:Ye.length)-1])===","&&(Ye=Ye==null?void 0:Ye.slice(0,(Ye==null?void 0:Ye.length)-1)),Ye)),Be=(me=Be==null?void 0:Be.filter(Ye=>Ye==null?void 0:Ye.includes("@Type")))==null?void 0:me[0],g=(ue=Be==null?void 0:Be.split("="))==null?void 0:ue[1],g==="File"&&(g="Upload")}else g="Input"}}else if(a!=null&&a.includes("||")){let Ae=[];n=(Z=(W=(U=le.analyzeSplitToContent(a,"="))==null?void 0:U[1])==null?void 0:W.split("||"))==null?void 0:Z.map(Ye=>{var ye,$a,wl,Qa;let Ee=Ye;if(Ee!=null&&Ee.includes("@")){let Pl="@"+(($a=(ye=Ee==null?void 0:Ee.replace("@",ml))==null?void 0:ye.split(ml))==null?void 0:$a[1]);Ee=(Qa=(wl=Ee==null?void 0:Ee.replace("@",ml))==null?void 0:wl.split(ml))==null?void 0:Qa[0],Pl=ri(Pl),Ae.push(Pl)}return{label:Ee==null?void 0:Ee.replaceAll("'",""),value:Ee==null?void 0:Ee.replaceAll("'","")}}),(Ae==null?void 0:Ae.length)>0&&(D="("+(Ae==null?void 0:Ae.join("||"))+")");let Be=(ae=le.analyzeSplitToContent(a,"="))==null?void 0:ae[0];if(Be!=null&&Be.includes("@")){(Be==null?void 0:Be[(Be==null?void 0:Be.length)-1])==="="&&(Be=Be==null?void 0:Be.slice(0,(Be==null?void 0:Be.length)-1));let Ye=(ve=le.analyzeSplitToContent(Be,"@"))==null?void 0:ve[1];Ye="@"+Ye,Ye=ri(Ye),D=D===""?Ye:Ye+","+D}}else g="Input",d=(N=(te=(ze=a==null?void 0:a.replace("=",ml))==null?void 0:ze.split(ml))==null?void 0:te[1])==null?void 0:N.replaceAll("'","");else if((G=(se=le.analyzeSplitToContent(a,"="))==null?void 0:se[1])!=null&&G.includes("||")){let Ae=(fe=le.analyzeSplitToContent(a,"="))==null?void 0:fe[0];if((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!=null&&Ae.includes("@")){let ye=(we=le.analyzeSplitToContent(Ae,"@"))==null?void 0:we[1];ye="@"+ye,D=ri(ye),r=(P=(_e=le.analyzeSplitToContent(Ae,"@"))==null?void 0:_e[0])==null?void 0:P.slice(0,((ra=(qe=le.analyzeSplitToContent(Ae,"@"))==null?void 0:qe[0])==null?void 0:ra.length)-1),y=(Ie=(Ke=le.analyzeSplitToContent(Ae,"@"))==null?void 0:Ke[0])==null?void 0:Ie.slice(0,((Le=(Me=le.analyzeSplitToContent(Ae,"@"))==null?void 0:Me[0])==null?void 0:Le.length)-1)}else r=Ae,y=Ae;let Be=(de=le.analyzeSplitToContent(a,"="))==null?void 0:de[1];Be=le.analyzeSplitToContent(Be,")");let Ye=Be==null?void 0:Be.filter(ye=>!(ye!=null&&ye.includes("If")));Ye==null||Ye.forEach(ye=>{(ye==null?void 0:ye[0])==="("&&(ye=ye==null?void 0:ye.slice(1,(ye==null?void 0:ye.length)-1)),i==null||i.push(ye==null?void 0:ye.split("||"))});let Ee=Be==null?void 0:Be.filter(ye=>ye==null?void 0:ye.includes("If"));Ee=Ee==null?void 0:Ee.map(ye=>((ye==null?void 0:ye[0])==="|"&&(ye==null?void 0:ye[1])==="|"&&(ye=ye==null?void 0:ye.slice(2,ye==null?void 0:ye.length)),(ye==null?void 0:ye[0])==="("&&(ye=ye==null?void 0:ye.slice(1,(ye==null?void 0:ye.length)-1)),(ye==null?void 0:ye[0])!=="@"&&(ye="@"+ye),ye)),o=Ee}else{let Ae=a==null?void 0:a.split("=="),Be=(De=Ae==null?void 0:Ae.filter(Ye=>(Ye==null?void 0:Ye.includes("$"))&&(Ye==null?void 0:Ye[0])!=="{"))==null?void 0:De[0];if(Be&&!(Be!=null&&Be.includes("&"))){let Ye=(Ea=le.analyzeSplitToContent(Be,")"))==null?void 0:Ea[((Xe=le.analyzeSplitToContent(Be,")"))==null?void 0:Xe.length)-1],Ee=(Ge=Ye==null?void 0:Ye.replace("*",ml))==null?void 0:Ge.split(ml),ye=(Ee==null?void 0:Ee[0])===""?l==null?void 0:l.value:Ee==null?void 0:Ee[0];(ye==null?void 0:ye[0])==="("&&(ye=($=le.analyzeSplitToContent(ye,")"))==null?void 0:$[1]),ye=(ee=(V=ye==null?void 0:ye.replaceAll("{",""))==null?void 0:V.replaceAll("}",""))==null?void 0:ee.replaceAll(Yi,""),(ye==null?void 0:ye[0])==="$"&&(ye=(ce=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length))==null?void 0:ce.replaceAll(":","/")),p=ye==null?void 0:ye.split("/");let $a=(pa=(he=Ee==null?void 0:Ee[1])==null?void 0:he.replace("{",ml))==null?void 0:pa.split(ml),wl=$a==null?void 0:$a[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(":"),u=(Ca=(ya=(Ve=(ia=$a==null?void 0:$a[1])==null?void 0:ia.replace("}",ml))==null?void 0:Ve.split(ml))==null?void 0:ya[0])==null?void 0:Ca.split(":");let Qa="";((Ce=le.analyzeSplitToContent(Be,")"))==null?void 0:Ce.length)>1&&(Qa=(Fa=le.analyzeSplitToContent(Be,")"))==null?void 0:Fa[0]),Qa&&Qa!==""&&((Qa==null?void 0:Qa[0])!=="@"&&(Qa="@"+Qa),D=ri(Qa))}if(Ae!=null&&Ae.some(Ye=>Ye==null?void 0:Ye.includes("&"))){let Ye=(Ta=Ae==null?void 0:Ae.filter($a=>$a==null?void 0:$a.includes("&")))==null?void 0:Ta[0];Ye=(fa=le.analyzeSplitToContent(Ye,"&"))==null?void 0:fa.map($a=>(($a==null?void 0:$a[($a==null?void 0:$a.length)-1])==="&"&&($a=$a==null?void 0:$a.slice(0,($a==null?void 0:$a.length)-1)),$a)),w=(Pe=(sa=(ja=Ye==null?void 0:Ye[1])==null?void 0:ja.replace("(",ml))==null?void 0:sa.split(ml))==null?void 0:Pe[0];let Ee=(ma=le.analyzeSplitToContent(Ye==null?void 0:Ye[1],")"))==null?void 0:ma[0];Ee=(Oe=(Qe=Ee==null?void 0:Ee.replace("(",ml))==null?void 0:Qe.split(ml))==null?void 0:Oe[1],Ee=Ee==null?void 0:Ee.slice(0,(Ee==null?void 0:Ee.length)-1),(Ee==null?void 0:Ee[0])==="{"&&(Ee=Ee==null?void 0:Ee.slice(1,Ee==null?void 0:Ee.length)),(Ee==null?void 0:Ee[(Ee==null?void 0:Ee.length)-1])==="}"&&(Ee=Ee==null?void 0:Ee.slice(0,(Ee==null?void 0:Ee.length)-1)),q=Ee==null?void 0:Ee.split(",");let ye=Ye==null?void 0:Ye[0];ye&&ye!==""&&((ye==null?void 0:ye[0])!=="@"&&(ye="@"+ye),A=ri(ye))}else if(!Be&&(($e=Ae==null?void 0:Ae.filter(Ye=>(Ye==null?void 0:Ye[0])==="{"))==null?void 0:$e.length)>0){let Ye=Ae==null?void 0:Ae[(Ae==null?void 0:Ae.length)-1];Ye=Ye==null?void 0:Ye.slice(1,(Ye==null?void 0:Ye.length)-1),Ye=le.analyzeSplitToContent(Ye,","),Ye=Ye==null?void 0:Ye.map(Ee=>((Ee==null?void 0:Ee[(Ee==null?void 0:Ee.length)-1])===","&&(Ee=Ee==null?void 0:Ee.slice(0,(Ee==null?void 0:Ee.length)-1)),Ee)),Ye=Ye==null?void 0:Ye.map(Ee=>{var ye,$a,wl,Qa;if(Ee=Ee==null?void 0:Ee.replaceAll("$",""),Ee!=null&&Ee.includes("{")){let Pl="";Ee=Ee==null?void 0:Ee.replaceAll("{","");let gl=Ee==null?void 0:Ee.split("}");Pl=(($a=(ye=gl==null?void 0:gl[0])==null?void 0:ye.split(":"))==null?void 0:$a[0])+":"+(gl==null?void 0:gl[1]),Ee=Pl,Ee=Ee+":"}if(Ee!=null&&Ee.includes(Yi)){let Pl="",gl=Ee==null?void 0:Ee.split(Yi);Pl=((Qa=(wl=gl==null?void 0:gl[0])==null?void 0:wl.split(":"))==null?void 0:Qa[0])+":"+(gl==null?void 0:gl[1]),Ee=Pl,Ee=Ee+":"}return Ee=Ee==null?void 0:Ee.replaceAll(":","/"),Ee}),m=Ye}else!((ne=Ae==null?void 0:Ae[1])!=null&&ne.includes("$"))&&((We=Ae==null?void 0:Ae[1])==null?void 0:We[0])!=="("&&u.push(Ae==null?void 0:Ae[1])}else r=(na=a==null?void 0:a.split("&"))==null?void 0:na[0],y=(va=a==null?void 0:a.split("&"))==null?void 0:va[0];return(n==null?void 0:n.length)===0&&(i==null?void 0:i.length)===0&&(p==null?void 0:p.length)===0&&g==="Select"&&(g="Input"),{label:r,prop:y,options:n,allContents:i,filterContents:o,menus:p,groups:c,words:u,align:"center",formType:g,filter:D,functionName:w,functionRelatedWords:q,calculatorFilter:A,relatedPages:m,value:d}},Bo=(a,l)=>{var n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z;let r=[];if((a==null?void 0:a[0])==="{"&&(a==null?void 0:a[(a==null?void 0:a.length)-1])==="}"&&!((p=(o=(i=(n=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1))==null?void 0:n.replace(":",ml))==null?void 0:i.split(ml))==null?void 0:o[0])!=null&&p.includes(","))){let ae=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1),ve=(c=ae==null?void 0:ae.replace(":",ml))==null?void 0:c.split(ml);if(((u=le.analyzeSplitToContent(ve==null?void 0:ve[1],"="))==null?void 0:u.length)===1){let ze=ve==null?void 0:ve[0],te=[];(y=le.analyzeSplitToContent((g=ve==null?void 0:ve[1])==null?void 0:g.slice(1,((m=ve==null?void 0:ve[1])==null?void 0:m.length)-1),","))==null||y.forEach(N=>{var se,G;((se=le.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)),te=[...te,...Bo(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)),te.push((G=Bo(N,l))==null?void 0:G[0]))}),r==null||r.push({label:ze,prop:ze,children:te,align:"center"})}else{let ze=[];if(((d=le.analyzeSplitToContent(ae,"="))==null?void 0:d.length)>=2){let N=(D=le.analyzeSplitToContent(ae,"="))==null?void 0:D[1],se=(w=le.analyzeSplitToContent(N,"/"))==null?void 0:w.map(G=>((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)),G));ze=se==null?void 0:se.map(G=>(G=Li(G),G))}let te=(_=(E=(O=(j=(A=(q=ae==null?void 0:ae.replace("{",ml))==null?void 0:q.split(ml))==null?void 0:A[1])==null?void 0:j.replace("}",ml))==null?void 0:O.split(ml))==null?void 0:E[0])==null?void 0:_.split(",");te==null||te.forEach((N,se)=>{(ze==null?void 0:ze.length)>0&&se===0?r==null||r.push({label:N,prop:N,align:"center",formType:"Select",relatedContents:ze==null?void 0:ze.map(G=>{let fe={};return te==null||te.forEach((we,_e)=>{fe[we]=G==null?void 0:G[_e]}),fe}),options:ze==null?void 0:ze.map(G=>({label:G==null?void 0:G[0],value:G==null?void 0:G[0]})),mainKey:!0}):r==null||r.push({label:N,prop:N,align:"center"})})}}else if((a==null?void 0:a[0])==="{")if(((x=le.analyzeSplitToContent(a,"="))==null?void 0:x.length)===2&&((S=(b=le.analyzeSplitToContent(a,"="))==null?void 0:b[1])==null?void 0:S[0])==="["){let ae=[];if(((I=le.analyzeSplitToContent(a,"="))==null?void 0:I.length)>=2){let ze=(R=le.analyzeSplitToContent(a,"="))==null?void 0:R[1],te=(X=(re=le.analyzeSplitToContent(ze,"|"))==null?void 0:re.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));ae=te==null?void 0:te.map(N=>(N=Li(N),N))}let ve=(ue=(me=a==null?void 0:a.replace("}",ml))==null?void 0:me.split(ml))==null?void 0:ue[0];ve=(U=ve==null?void 0:ve.slice(1,ve==null?void 0:ve.length))==null?void 0:U.split(","),ve==null||ve.forEach((ze,te)=>{(ae==null?void 0:ae.length)>0&&te===0?r==null||r.push({label:ze,prop:ze,align:"center",formType:"Select",relatedContents:ae==null?void 0:ae.map(N=>{let se={};return ve==null||ve.forEach((G,fe)=>{se[G]=N==null?void 0:N[fe]}),se}),options:ae==null?void 0:ae.map(N=>({label:N==null?void 0:N[0],value:N==null?void 0:N[0]})),mainKey:!0}):r==null||r.push({label:ze,prop:ze,align:"center"})})}else(W=le.analyzeSplitToContent(a,","))==null||W.forEach(ae=>{var ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe;if((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==null?void 0:ae[0])==="{"){let Oe=le.analyzeSplitToContent(ae,"="),$e=Oe==null?void 0:Oe[(Oe==null?void 0:Oe.length)-1],ne=[],We=[],na=[],va="",Ae="",Be=[],Ye=[],Ee=(ve=$e==null?void 0:$e.replace("*",ml))==null?void 0:ve.split(ml),ye=(Ee==null?void 0:Ee[0])===""?l==null?void 0:l.value:Ee==null?void 0:Ee[0];ye=le.analyzeSplitToContent(ye,")");let $a="";if((ye==null?void 0:ye.length)>1&&((ze=ye==null?void 0:ye[0])==null?void 0:ze[0])!=="&"&&($a=ye==null?void 0:ye[0],($a==null?void 0:$a[0])!=="@"&&($a="@"+$a),Ae=$a??""),ye=(te=ye==null?void 0:ye.filter(al=>(al==null?void 0:al[0])==="$"))==null?void 0:te[0],((N=le.analyzeSplitToContent(ye,"}"))==null?void 0:N.length)>1&&((G=(se=le.analyzeSplitToContent(ye,"}"))==null?void 0:se[1])==null?void 0:G[0])==="("&&($a=(fe=le.analyzeSplitToContent(ye,"}"))==null?void 0:fe[1],($a==null?void 0:$a[0])!=="@"&&($a="@"+$a),Ae!==""&&(Ae=Ae+","),Ae=Ae+$a),(we=ye==null?void 0:ye.slice(1,(ye==null?void 0:ye.length)-1))!=null&&we.includes("$")||(ye=(_e=le.analyzeSplitToContent(ye,"}"))==null?void 0:_e[0]),(ye==null?void 0:ye[0])==="$"&&(ye=(qe=ye==null?void 0:ye.replace("{",""))==null?void 0:qe.replace("}",":"),ye=(ra=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length))==null?void 0:ra.replaceAll(":","/")),ye!=null&&ye.includes("$")){let al=(P=ye==null?void 0:ye.split("$"))==null?void 0:P[0];al=(Ke=al==null?void 0:al.split("/"))==null?void 0:Ke[0],ye=al+"/"+((Me=ye==null?void 0:ye.split("$"))==null?void 0:Me[1])+"/"}ne=(ye==null?void 0:ye.split("/"))??[];let wl=(Ie=(Le=Ee==null?void 0:Ee[1])==null?void 0:Le.replace("{",ml))==null?void 0:Ie.split(ml);if((Xe=(De=(de=Ee==null?void 0:Ee[1])==null?void 0:de.split("(@"))==null?void 0:De[0])!=null&&Xe.includes("&&")||($=(Ge=(Ea=Ee==null?void 0:Ee[1])==null?void 0:Ea.split("@"))==null?void 0:Ge[0])!=null&&$.includes("&&")){let al=(V=Ee==null?void 0:Ee[1])!=null&&V.includes("(@")?(he=(ce=(ee=Ee==null?void 0:Ee[1])==null?void 0:ee.split("(@"))==null?void 0:ce[0])==null?void 0:he.split("&&"):(Ve=(ia=(pa=Ee==null?void 0:Ee[1])==null?void 0:pa.split("@"))==null?void 0:ia[0])==null?void 0:Ve.split("&&");Be=al==null?void 0:al.map(Wa=>{var Gl,Kl;return(Wa==null?void 0:Wa[0])==="*"&&(Wa=Wa==null?void 0:Wa.slice(1,Wa==null?void 0:Wa.length)),Wa=(Kl=(Gl=Wa==null?void 0:Wa.replace("{",ml))==null?void 0:Gl.split(ml))==null?void 0:Kl[0],(Wa==null?void 0:Wa[(Wa==null?void 0:Wa.length)-1])===":"&&(Wa=Wa==null?void 0:Wa.slice(0,(Wa==null?void 0:Wa.length)-1)),Wa=Wa==null?void 0:Wa.split(":"),Wa});let Hl=[];al==null||al.forEach((Wa,Gl)=>{var Kl,Zl;(Wa==null?void 0:Wa[0])==="*"&&(Wa=Wa==null?void 0:Wa.slice(1,Wa==null?void 0:Wa.length)),Wa=(Zl=(Kl=Wa==null?void 0:Wa.replace("{",ml))==null?void 0:Kl.split(ml))==null?void 0:Zl[1],(Wa==null?void 0:Wa[(Wa==null?void 0:Wa.length)-1])==="}"&&(Wa=Wa==null?void 0:Wa.slice(0,(Wa==null?void 0:Wa.length)-1)),Wa=Wa==null?void 0:Wa.split(","),Hl.push(Gl===0?(Wa==null?void 0:Wa.length)-1:Wa==null?void 0:Wa.length),Ye=[...Ye,...Wa]}),Hl=(ya=le.prefixSum(Hl))==null?void 0:ya.map(Wa=>Wa==null?void 0:Wa.total),Be=Be==null?void 0:Be.map((Wa,Gl)=>({number:Hl==null?void 0:Hl[Gl],contents:Wa}))}let Qa=wl==null?void 0:wl[0];(Qa==null?void 0:Qa[(Qa==null?void 0:Qa.length)-1])===":"&&(Qa=Qa==null?void 0:Qa.slice(0,(Qa==null?void 0:Qa.length)-1)),We=(Qa==null?void 0:Qa.split(":"))??[],na=((Ta=(Fa=(Ce=(Ca=wl==null?void 0:wl[1])==null?void 0:Ca.replace("}",ml))==null?void 0:Ce.split(ml))==null?void 0:Fa[0])==null?void 0:Ta.split(","))??[];let Pl=(ja=Oe==null?void 0:Oe[0])==null?void 0:ja.slice(1,((fa=Oe==null?void 0:Oe[0])==null?void 0:fa.length)-2);Ae&&Ae!==""&&(va=ri(Ae));let gl=(sa=le.analyzeSplitToContent(va,","))==null?void 0:sa.map(al=>((al==null?void 0:al[(al==null?void 0:al.length)-1])===","&&(al=al==null?void 0:al.slice(0,(al==null?void 0:al.length)-1)),al)),jl=[];gl!=null&&gl.find(al=>al==null?void 0:al.includes("@MainParam"))&&(gl=gl==null?void 0:gl.find(al=>al==null?void 0:al.includes("@MainParam")),gl=(ma=(Pe=gl==null?void 0:gl.replace("=",ml))==null?void 0:Pe.split(ml))==null?void 0:ma[1],gl=gl==null?void 0:gl.slice(1,(gl==null?void 0:gl.length)-1),jl=le.analyzeSplitToContent(gl,",")),(Qe=Pl==null?void 0:Pl.split(","))==null||Qe.forEach((al,Hl)=>{var Wa,Gl,Kl,Zl,Sl,dr;if(((Wa=le.analyzeSplitToContent(al,"@"))==null?void 0:Wa.length)>1){let ga=(Gl=le.analyzeSplitToContent(al,"@"))==null?void 0:Gl[1];ga="@"+ga,va=ri(ga),al=(Kl=le.analyzeSplitToContent(al,"@"))==null?void 0:Kl[0],(al==null?void 0:al[(al==null?void 0:al.length)-1])==="@"&&(al=al==null?void 0:al.slice(0,(al==null?void 0:al.length)-1))}r.push({label:al,prop:al,align:"center",menus:ne,groups:(Be==null?void 0:Be.length)===0?We:(Zl=Be==null?void 0:Be.find(ga=>(ga==null?void 0:ga.number)>=Hl))==null?void 0:Zl.contents,words:(Ye==null?void 0:Ye.length)===0?(Sl=na==null?void 0:na[Hl])==null?void 0:Sl.split(":"):(dr=Ye==null?void 0:Ye[Hl])==null?void 0:dr.split(":"),formType:(ne==null?void 0:ne.length)>0?"Select":"Input",mainKey:!!(Hl===0||jl!=null&&jl.find(ga=>ga===al)),filter:va,isMainPath:(Be==null?void 0:Be.findIndex(ga=>(ga==null?void 0:ga.number)>=Hl))===0})})}else r.push({label:ae,prop:ae,align:"center"})});else{let ae=(Z=le.analyzeSplitToContent(a,","))==null?void 0:Z.map(ve=>((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));ae==null||ae.forEach(ve=>{r.push(Dt(ve,l))})}return r},kp=(a,l)=>{var p,c,u,m,g;let r=a;if(!a)return;let n="";((p=le.analyzeSplitToContent(a,"}"))==null?void 0:p.length)>1&&(r=(c=le.analyzeSplitToContent(a,"}"))==null?void 0:c[0],n=(u=le.analyzeSplitToContent(a,"}"))==null?void 0:u[1]),(a==null?void 0:a[0])==="{"&&(a==null?void 0:a[(a==null?void 0:a.length)-1])==="}"&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1));let i=[],o=[];return i.push({label:"排序",prop:"sort"}),i.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(m=le.analyzeSplitToContent(r,","))==null||m.forEach(y=>{var d;(y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),(y==null?void 0:y[0])==="{"?(d=Bo(y,l))==null||d.forEach(D=>{i.push(D)}):i.push(Dt(y,l))}),i!=null&&i.some(y=>{var d;return(d=y==null?void 0:y.prop)==null?void 0:d.includes("@")})&&(i=i==null?void 0:i.filter(y=>{var d;return!((d=y==null?void 0:y.prop)!=null&&d.includes("@"))})),n!==""&&((n==null?void 0:n[0])=="{"&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1)),(g=le.analyzeSplitToContent(n,","))==null||g.forEach(y=>{var d;(y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),(y==null?void 0:y[0])==="{"?(d=Bo(y,l))==null||d.forEach(D=>{o.push(D)}):o.push(Dt(y,l))})),{columns:i,secondColumns:o}},hn=a=>{var l,r,n,i,o;if(a!=null&&a.includes("@Filter")||a!=null&&a.includes("@Condition")||a!=null&&a.includes("@If"))return a;{let p=(r=(l=a==null?void 0:a.replace("(",ml))==null?void 0:l.split(ml))==null?void 0:r[1],c=(i=(n=a==null?void 0:a.replace("(",ml))==null?void 0:n.split(ml))==null?void 0:i[0];return p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1),p=(o=le.analyzeSplitToContent(p,","))==null?void 0:o.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==null?void 0:u[0])==="("&&(u=u==null?void 0:u.slice(1,(u==null?void 0:u.length)-1)),c+u)),p=p==null?void 0:p.join(","),a!=null&&a.includes("@Quote")&&(p!=null&&p.includes("@QuoteType")||(p=p===""?p+"@QuoteType=Manual":p+",@QuoteType=Manual"),p!=null&&p.includes("@QuoteSonSync")||(p=p===""?p+"@QuoteSonSync=No":p+",@QuoteSonSync=No"),p!=null&&p.includes("@QuoteFatherSync")||(p=p===""?p+"@QuoteFatherSync=Yes":p+",@QuoteFatherSync=Yes")),p}},bs=a=>{let l=a==null?void 0:a.map(r=>{var n,i;return{menus:r==null?void 0:r.menus,content:((n=r==null?void 0:r.menus)==null?void 0:n.join("/"))+ml+((i=r==null?void 0:r.groups)==null?void 0:i.join("/"))}});return l=l==null?void 0:l.filter(r=>{var n;return(r==null?void 0:r.menus)&&((n=r==null?void 0:r.menus)==null?void 0:n.length)>0}),l=l==null?void 0:l.map(r=>r==null?void 0:r.content),l=[...new Set(l)],l=l==null?void 0:l.map(r=>{var n,i;return{menus:(n=r==null?void 0:r.split(ml))==null?void 0:n[0],groups:((i=r==null?void 0:r.split(ml))==null?void 0:i[1])??[]}}),l},ks=a=>{var r;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=(r=le.analyzeSplitToContent(l,","))==null?void 0:r.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==null?void 0:n[0])!=="@"&&(n="@"+n),(n==null?void 0:n[1])==="("&&(n=hn(n)),n)),l==null?void 0:l.join(",")},gc=(a,l,r="")=>{var E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe;let n=[],i=[],o=[],p="",c="",u="",m=[],g=[],y=[],d=[],D="";if(((E=a==null?void 0:a[0])==null?void 0:E[0])!=="*"&&((_=a==null?void 0:a[0])==null?void 0:_[0])!=="$"&&!((x=a==null?void 0:a[0])!=null&&x.includes("$")))return;((b=a==null?void 0:a[0])==null?void 0:b[0])!=="*"&&((S=a==null?void 0:a[0])==null?void 0:S[0])!=="$"&&(p=(I=le.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:I[0],(p==null?void 0:p[0])!=="@"&&(p="@"+p),p=ri(p),u=(R=le.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:R[1],(u==null?void 0:u[0])==="$"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length)),u=u==null?void 0:u.replaceAll(":","/"));let q=le.analyzeSplitToContent(a==null?void 0:a[0],":");if(n=(re=q==null?void 0:q.filter($e=>($e==null?void 0:$e[0])!=="{"&&($e==null?void 0:$e[0])!=="["))==null?void 0:re.join(""),c=(X=a==null?void 0:a[0])==null?void 0:X.replace(n,""),(n==null?void 0:n[0])==="("&&(n=""),D=(me=q==null?void 0:q.filter($e=>($e==null?void 0:$e[0])!=="["))==null?void 0:me.join(""),D=(ue=a==null?void 0:a[0])==null?void 0:ue.replace(D,""),c=c==null?void 0:c.replace(D,""),(n==null?void 0:n[0])==="*"&&(n=n==null?void 0:n.slice(1,n==null?void 0:n.length)),(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)),((U=le.analyzeSplitToContent(c,"@"))==null?void 0:U.length)>1&&(p=(W=le.analyzeSplitToContent(c,"@"))==null?void 0:W[1],(p==null?void 0:p[(p==null?void 0:p.length)-1])===":"&&(p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1)),p="@"+p,p=hn(p),c=(Z=le.analyzeSplitToContent(c,"@"))==null?void 0:Z[0],c=c==null?void 0:c.slice(0,(c==null?void 0:c.length)-1)),((ae=le.analyzeSplitToContent(n,"@"))==null?void 0:ae.length)>1){p!==""&&(p=p+",");let $e=(ve=le.analyzeSplitToContent(n,"@"))==null?void 0:ve[1];$e="@"+$e,$e=hn($e),p=p+$e,n=(ze=le.analyzeSplitToContent(n,"@"))==null?void 0:ze[0]}if((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=n===""?[]:n==null?void 0:n.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)),r!==""){let $e=(te=le.analyzeSplitToContent(r,")"))==null?void 0:te[0],ne=le.analyzeSplitToContent(r,")");ne=ne==null?void 0:ne.filter((Ae,Be)=>Be!==(ne==null?void 0:ne.length)-1),ne=ne==null?void 0:ne.join("");let We=(N=le.analyzeSplitToContent(r,"@"))==null?void 0:N[1];u=(G=(se=le.analyzeSplitToContent(r,"@"))==null?void 0:se[0])==null?void 0:G.replace(ne,""),(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));let na="";if(na=le.analyzeSplitToContent(r,")"),na=na==null?void 0:na.filter((Ae,Be)=>Be!==0&&Be!==(na==null?void 0:na.length)-1),((fe=le.analyzeSplitToContent(r,"&"))==null?void 0:fe.length)>1&&(na==null?void 0:na.length)<2&&($e="",u="",na=le.analyzeSplitToContent(r,")")),na!=null&&na.some(Ae=>(Ae==null?void 0:Ae[0])===":")){let Ae=(we=na==null?void 0:na.filter(Be=>(Be==null?void 0:Be[0])===":"))==null?void 0:we.join("");D=Ae==null?void 0:Ae.slice(1,Ae==null?void 0:Ae.length),na=na==null?void 0:na.filter(Be=>(Be==null?void 0:Be[0])!==":")}(na==null?void 0:na.length)>0&&((_e=le.chunkArray(na))==null||_e.forEach(Ae=>{var $a,wl,Qa,Pl,gl;let Be="",Ye=[],Ee="";(Ae==null?void 0:Ae.length)>1&&(Ee="@"+(Ae==null?void 0:Ae[0]),Ee=hn(Ee));let ye=(Ae==null?void 0:Ae.length)===1?Ae==null?void 0:Ae[0]:Ae==null?void 0:Ae[1];ye=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length),Be=(wl=($a=ye==null?void 0:ye.replace("(",ml))==null?void 0:$a.split(ml))==null?void 0:wl[0],ye=(Pl=(Qa=ye==null?void 0:ye.replace("(",ml))==null?void 0:Qa.split(ml))==null?void 0:Pl[1],ye=ye==null?void 0:ye.slice(0,(ye==null?void 0:ye.length)-1),Ye=(gl=le.analyzeSplitToContent(ye,","))==null?void 0:gl.map(jl=>((jl==null?void 0:jl[(jl==null?void 0:jl.length)-1])===","&&(jl=jl==null?void 0:jl.slice(0,(jl==null?void 0:jl.length)-1)),jl)),m.push({functionName:Be,functionRelatedWords:Ye,calculatorFilter:Ee})})),$e=ks($e),We=ks(We);let va=$e??"";if(va!==""&&(va=va+","),va=va+We,(va==null?void 0:va[(va==null?void 0:va.length)-1])===","&&(va=va==null?void 0:va.slice(0,(va==null?void 0:va.length)-1)),va!==""&&p!==""&&(p=p+","),p=p+va,(u==null?void 0:u[0])==="$"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length)),u=(qe=le.analyzeSplitToContent(u,":"))==null?void 0:qe.filter((Ae,Be)=>{var Ye;return!((Ae==null?void 0:Ae[0])==="{"&&Be===((Ye=le.analyzeSplitToContent(u,":"))==null?void 0:Ye.length)-1)}),u=u==null?void 0:u.join(""),(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)),p!=null&&p.includes("@Sync")||(p=p===""?p+"@Sync=(Yes,Yes)":p+",@Sync=(Yes,Yes)"),u!=null&&u.includes("$")){let Ae=(P=(ra=u==null?void 0:u.replace("*",ml))==null?void 0:ra.split(ml))==null?void 0:P[1],Be=(Me=(Ke=u==null?void 0:u.replace("*",ml))==null?void 0:Ke.split(ml))==null?void 0:Me[0];Be=Be==null?void 0:Be.split("$"),Be=((Ie=(Le=Be==null?void 0:Be[0])==null?void 0:Le.split(":"))==null?void 0:Ie[0])+":"+(Be==null?void 0:Be[1])+":",u=Be+"*"+Ae}else u=(de=u==null?void 0:u.replaceAll("{",""))==null?void 0:de.replaceAll("}","");(u==null?void 0:u[0])===":"&&(D=u==null?void 0:u.slice(1,u==null?void 0:u.length),u="")}p!==""&&p&&(p="("+p+")"),p=u+p,((De=le.analyzeSplitToContent(c,"}"))==null?void 0:De.length)>1&&(c=(Xe=le.analyzeSplitToContent(c,"}"))==null?void 0:Xe.filter($e=>($e==null?void 0:$e[0])!=="@"),c=c==null?void 0:c.join(""));let A=kp(c,l);o=c===""?[]:(A==null?void 0:A.columns)??[],d=le.getColumnChild(o);let j=le.getColumnChild(o);o!=null&&o.some($e=>{var ne;return Array.isArray($e==null?void 0:$e.children)&&((ne=$e==null?void 0:$e.children)==null?void 0:ne.length)>0})&&(o=[o]),i=D?Li(D):[],!(i!=null&&i.every($e=>Array.isArray($e)))&&(i==null?void 0:i.length)>0&&(i=[i]),(i==null?void 0:i.length)>0&&(Array.isArray(i==null?void 0:i[0])&&((Ea=i==null?void 0:i[0])!=null&&Ea.every($e=>Array.isArray($e)))?i=i==null?void 0:i.map(($e,ne)=>($e=$e.map((We,na)=>(We.unshift("{}"),We.unshift((na+1).toString()),We)),$e)):i=i==null?void 0:i.map(($e,ne)=>($e.unshift("{}"),$e.unshift((ne+1).toString()),$e))),A!=null&&A.secondColumns&&((Ge=A==null?void 0:A.secondColumns)==null?void 0:Ge.length)>0&&((i==null?void 0:i.length)>0?i=i==null?void 0:i.map(($e,ne)=>{var We,na;return Array.isArray($e==null?void 0:$e[0])?$e=$e==null?void 0:$e.map((va,Ae)=>{var Be,Ye;return va.unshift((Ye=(Be=A==null?void 0:A.secondColumns)==null?void 0:Be[Ae])==null?void 0:Ye.prop),va}):$e.unshift((na=(We=A==null?void 0:A.secondColumns)==null?void 0:We[ne])==null?void 0:na.prop),$e}):i=($=A==null?void 0:A.secondColumns)==null?void 0:$.map(($e,ne)=>($e=[$e==null?void 0:$e.label],$e.push(ne),$e)),o.unshift({label:"",prop:"disabled",sortable:!1})),d=d==null?void 0:d.map($e=>{var ne,We;return{menus:$e==null?void 0:$e.menus,content:((ne=$e==null?void 0:$e.menus)==null?void 0:ne.join("/"))+ml+((We=$e==null?void 0:$e.groups)==null?void 0:We.join("/"))}});let O=[];if(((ee=(V=p==null?void 0:p.replace("(",ml))==null?void 0:V.split(ml))==null?void 0:ee[0])!==""&&(O=(he=(ce=p==null?void 0:p.replace("(",ml))==null?void 0:ce.split(ml))==null?void 0:he[0],O=[O],O=O==null?void 0:O.map($e=>{var We,na,va;let ne=$e==null?void 0:$e.split("*");return{menus:(We=ne==null?void 0:ne[0])==null?void 0:We.split(":"),content:((na=ne==null?void 0:ne[0])==null?void 0:na.replaceAll(":","/"))+ml+((va=ne==null?void 0:ne[1])==null?void 0:va.replaceAll(":","/"))}}),d=[...d,...O]),d=d==null?void 0:d.filter($e=>{var ne;return($e==null?void 0:$e.menus)&&((ne=$e==null?void 0:$e.menus)==null?void 0:ne.length)>0}),d=d==null?void 0:d.map($e=>$e==null?void 0:$e.content),d=[...new Set(d)],d=d==null?void 0:d.map($e=>{var ne,We;return{menus:(ne=$e==null?void 0:$e.split(ml))==null?void 0:ne[0],groups:((We=$e==null?void 0:$e.split(ml))==null?void 0:We[1])??[]}}),g=j==null?void 0:j.filter($e=>{var ne;return($e==null?void 0:$e.filter)&&((ne=$e==null?void 0:$e.filter)==null?void 0:ne.includes("@Sync"))}),(g==null?void 0:g.length)>0&&(g=g==null?void 0:g.filter($e=>{var ne,We,na,va;return(va=(na=(We=(ne=le.analyzeSplitToContent($e==null?void 0:$e.filter,","))==null?void 0:ne.find(Ae=>Ae==null?void 0:Ae.includes("@Sync")))==null?void 0:We.split(","))==null?void 0:na[0])==null?void 0:va.includes("Yes")}),g=bs(g)),y=j==null?void 0:j.filter($e=>{var ne;return($e==null?void 0:$e.filter)&&((ne=$e==null?void 0:$e.filter)==null?void 0:ne.includes("@Sync"))}),(y==null?void 0:y.length)>0&&(y=y==null?void 0:y.filter($e=>{var ne,We,na,va;return(va=(na=(We=(ne=le.analyzeSplitToContent($e==null?void 0:$e.filter,","))==null?void 0:ne.find(Ae=>Ae==null?void 0:Ae.includes("@Sync")))==null?void 0:We.split(","))==null?void 0:na[1])==null?void 0:va.includes("Yes")}),y=bs(y)),p!==""&&(p!=null&&p.includes("@Sync"))&&(p==null?void 0:p[0])!=="("){let $e=(pa=p==null?void 0:p.replace("(",ml))==null?void 0:pa.split(ml),ne=$e==null?void 0:$e[1];if(ne=ne==null?void 0:ne.slice(0,(ne==null?void 0:ne.length)-1),ne=le.analyzeSplitToContent(ne,","),(ya=(Ve=(ia=ne==null?void 0:ne.find(We=>We==null?void 0:We.includes("@Sync")))==null?void 0:ia.split(","))==null?void 0:Ve[0])!=null&&ya.includes("Yes")){let We=$e==null?void 0:$e[0];We=[{menus:(Ce=(Ca=We==null?void 0:We.split("*"))==null?void 0:Ca[0])==null?void 0:Ce.replaceAll(":","/"),groups:((Ta=(Fa=We==null?void 0:We.split("*"))==null?void 0:Fa[1])==null?void 0:Ta.split(":"))??[]}],g=[...g,...We]}if((sa=(ja=(fa=ne==null?void 0:ne.find(We=>We==null?void 0:We.includes("@Sync")))==null?void 0:fa.split(","))==null?void 0:ja[1])!=null&&sa.includes("Yes")){let We=$e==null?void 0:$e[0];We=[{menus:(ma=(Pe=We==null?void 0:We.split("*"))==null?void 0:Pe[0])==null?void 0:ma.replaceAll(":","/"),groups:((Oe=(Qe=We==null?void 0:We.split("*"))==null?void 0:Qe[1])==null?void 0:Oe.split(":"))??[]}],y=[...y,...We]}}return{groupName:n,tableColumns:o,tableFilter:p,tableContents:i,columns:(A==null?void 0:A.secondColumns)??[],relatedQuotes:d,fatherSyncContents:g,sonSyncContents:y,calculatorFilters:m}},bc=(a,l)=>(a=a==null?void 0:a.map((r,n)=>{var i,o,p,c;if(Array.isArray(r))r=r==null?void 0:r.map(u=>{var m,g,y,d;return u!=null&&u.isMainPath||(((m=u==null?void 0:u.children)==null?void 0:m.length)>0?u.children=bc(u.children,l):((g=u==null?void 0:u.menus)==null?void 0:g.length)>0&&!((y=r==null?void 0:r[0])!=null&&y.isMainPath)&&(u.menus=(d=u.menus)==null?void 0:d.map((D,w)=>{var q,A;return((q=u.menus)==null?void 0:q.length)-1===w&&D===""&&(l==null?void 0:l.parentContent)+"/"!==((A=u.menus)==null?void 0:A.join("/"))&&(D=l==null?void 0:l.value),u}),u.bindMenus=u.menus)),u});else{if(n===0&&((i=r.menus)==null?void 0:i.length)>0&&(r.mainKey=!0),r!=null&&r.isMainPath)return r;((o=r.menus)==null?void 0:o.length)>0&&!((p=a==null?void 0:a[0])!=null&&p.isMainPath)&&(r.menus=(c=r.menus)==null?void 0:c.map((u,m)=>{var g,y;return((g=r.menus)==null?void 0:g.length)-1===m&&u===""&&(l==null?void 0:l.parentContent)+"/"!==((y=r.menus)==null?void 0:y.join("/"))&&(u=l==null?void 0:l.value),u}),r.bindMenus=r.menus)}return r}),a),xp=(a,l)=>(a=a==null?void 0:a.map(r=>((r==null?void 0:r.key)==="header"&&(r.contents=bc(r.contents,l)),r)),a),Tt=(a,l)=>{let r=a;return Array.isArray(r==null?void 0:r[0])?r=r==null?void 0:r.map(n=>(n=Tt(n,l),n)):r=r==null?void 0:r.map(n=>{var i,o;return n!=null&&n.children&&((i=n==null?void 0:n.children)==null?void 0:i.length)>0?n.children=Tt(n==null?void 0:n.children,l):n!=null&&n.words&&((o=n==null?void 0:n.words)==null?void 0:o.length)>0&&(l!=null&&l.find(p=>{var c,u,m,g;return((g=(c=n==null?void 0:n.prop)==null?void 0:c.split("."))==null?void 0:g[((m=(u=n==null?void 0:n.prop)==null?void 0:u.split("."))==null?void 0:m.length)-1])===p}))&&(n.mainKey=!0),n}),r};let Nr="$R";const wp=M.useUnit(M.pinia),{selectTitle:xn}=M.storeToRefs(wp),_p=M.useMenuState(M.pinia),{localFiles:gt}=M.storeToRefs(_p),Sp=M.useLoginState(M.pinia),{loginUserInfo:bt}=M.storeToRefs(Sp),Mn=[{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:"@TextBackRGBA",value:"onTextBackRGBA",order:1},{key:"@Position",value:"onPosition",order:4},{key:"@ColumnNum",value:"onColumnNum",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 vi=(a=>(a[a.ORDINARY=1]="ORDINARY",a[a.BLOCK=2]="BLOCK",a[a.TEXT=3]="TEXT",a))(vi||{});const Ep=async a=>{var r,n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O;let l=le.analyzeSplitToContent((a==null?void 0:a.filter)??"",")");if((l==null?void 0:l.length)>1){let E=l==null?void 0:l[0];E=E==null?void 0:E.slice(1,(E==null?void 0:E.length)-1),E=(n=(r=E==null?void 0:E.replace("(",Nr))==null?void 0:r.split(Nr))==null?void 0:n[1],E="("+((i=E==null?void 0:E.replaceAll("{",""))==null?void 0:i.replaceAll("}",""));let _=le.calculatorAndToOr(E),x=Object.keys(_==null?void 0:_[0]);if(E=_,((o=x==null?void 0:x[0])==null?void 0:o[0])==="$"){let b=(c=x==null?void 0:x[0])==null?void 0:c.slice(1,((p=x==null?void 0:x[0])==null?void 0:p.length)-1),S=(m=(u=b==null?void 0:b.split("*"))==null?void 0:u[0])==null?void 0:m.replaceAll(".","/"),I=(d=(y=(g=b==null?void 0:b.split("*"))==null?void 0:g[1])==null?void 0:y.split("."))==null?void 0:d[0],R=await Hr(S,!1);R=(D=R==null?void 0:R.filter(U=>(U==null?void 0:U.name)===I))==null?void 0:D[0];let re=(q=(w=R==null?void 0:R.compData)==null?void 0:w.find(U=>(U==null?void 0:U.key)==="tableContents"))==null?void 0:q.contents;E=E==null?void 0:E.map(U=>{var Z,ae;let W={};for(let ve in U)if((ve==null?void 0:ve[0])==="$"){let ze=(ae=ve==null?void 0:ve.split("."))==null?void 0:ae[((Z=ve==null?void 0:ve.split("."))==null?void 0:Z.length)-1];W[ze]=U==null?void 0:U[ve]}else W[ve]=U==null?void 0:U[ve];return W});let X=(j=(A=R==null?void 0:R.compData)==null?void 0:A.find(U=>(U==null?void 0:U.key)==="header"))==null?void 0:j.contents;X=(O=le.getEqualChild(X))==null?void 0:O.filter(U=>(U==null?void 0:U.label)!=="操作");let ue=le.tableToForm(re,X);if(E==null||E.forEach(U=>{var W,Z,ae,ve,ze;for(let te in U)(U==null?void 0:U[te])==="LoginUser"&&(U[te]=((W=bt.value)==null?void 0:W.姓名)||((Z=bt.value)==null?void 0:Z.account)||((ae=bt.value)==null?void 0:ae.账号)),!((ve=ue==null?void 0:ue[0])!=null&&ve.find(N=>{var se;return(N==null?void 0:N.key)===te||((se=N==null?void 0:N.key)==null?void 0:se.includes(te))}))&&!(ue!=null&&ue.find(N=>{var se;return(N==null?void 0:N.key)===te||((se=N==null?void 0:N.key)==null?void 0:se.includes(te))}))||(((ze=U[te])==null?void 0:ze[0])!=="!"?ue=ue==null?void 0:ue.filter(N=>{var se,G;return((se=N==null?void 0:N.find(fe=>{var we;return(fe==null?void 0:fe.key)===te||((we=fe==null?void 0:fe.key)==null?void 0:we.includes(te))}))==null?void 0:se.value)===U[te]||Array.isArray(U==null?void 0:U[te])&&((G=U==null?void 0:U[te])==null?void 0:G.find(fe=>{var we;return((we=N==null?void 0:N.find(_e=>{var qe;return(_e==null?void 0:_e.key)===te||((qe=_e==null?void 0:_e.key)==null?void 0:qe.includes(te))}))==null?void 0:we.value)===fe}))}):ue=ue==null?void 0:ue.filter(N=>{var se;return((se=N==null?void 0:N.find(G=>{var fe;return(G==null?void 0:G.key)===te||((fe=G==null?void 0:G.key)==null?void 0:fe.includes(te))}))==null?void 0:se.value)!==U[te]}))}),(ue==null?void 0:ue.length)===0){let U=a==null?void 0:a.contents;return U.push({key:"hideContents",contents:!0}),U}}}return 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;return l.push({key:"textBackRGBA",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Dp=a=>{var l,r,n,i,o;if((a==null?void 0:a.filter)!==void 0&&(a==null?void 0:a.filter)!==null&&(a==null?void 0:a.filter)!==""){let p=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=le.analyzeSplitToContent(c,","))==null?void 0:l.map(y=>((y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),y));let u=(c==null?void 0:c[2])??"Center",m=(c==null?void 0:c[0])??"Picture";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=(r=le.analyzeSplitToContent(c,","))==null?void 0:r.map(y=>((y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),y));let g=(o=(i=(n=gt.value)==null?void 0:n.filter(y=>{var d;return(y==null?void 0:y.path)===((d=a==null?void 0:a.groupName)==null?void 0:d[0])}))==null?void 0:i[0])==null?void 0:o.children;return g=(g==null?void 0:g.filter(y=>c==null?void 0:c.find(d=>d===(y==null?void 0:y.name))))??[],(c==null?void 0:c.length)>0&&(g==null?void 0:g.length)===0&&(c==null||c.forEach(y=>{var D,w;let d=(w=(D=gt.value)==null?void 0:D.find(q=>(q==null?void 0:q.path)===y))==null?void 0:w.url;console.log(232,d,y,gt.value),g.push({url:d})}),console.log(2321,g)),g[0]={...g==null?void 0:g[0],position:u,fileType:m},p.push({key:"backGround",contents:g}),p}return a==null?void 0:a.contents},Tp=a=>{const l=xc(a==null?void 0:a.filter);return l?rf(a==null?void 0:a.contents,{position:l}):a==null?void 0:a.contents},Bp=a=>{let l=parseInt(a==null?void 0:a.filter);l=1/l;let r=a==null?void 0:a.contents;return r.push({key:"rowPosition",contents:l}),r},Np=a=>{const l=xc(a==null?void 0:a.filter);if(!l)return a==null?void 0:a.contents;let r=a==null?void 0:a.contents;return r.push({key:"numPosition",contents:l}),r},Ap=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 r=Number(a==null?void 0:a.filter);return l.push({key:"textSize",contents:Number.isNaN(r)?a==null?void 0:a.filter:r}),l}return a==null?void 0:a.contents},zp=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},Mp=a=>{var r;return(a==null?void 0:a.filter.toUpperCase())==="ALL"||(a==null?void 0:a.filter.toUpperCase())==="NONE"?a==null?void 0:a.contents:(r=a==null?void 0:a.contents)==null?void 0:r.map(n=>{var i;return(n==null?void 0:n.key)==="tableContents"&&(n.contents=(i=n.contents)==null?void 0:i.slice(0,parseInt(a==null?void 0:a.filter))),n})},Ip=async a=>{var l,r,n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U;if((a==null?void 0:a.filter)==="Random")return(l=a==null?void 0:a.contents)==null?void 0:l.map(Z=>((Z==null?void 0:Z.key)==="tableContents"&&(Z.contents=le.shuffle(Z.contents)),Z));if((a==null?void 0:a.filter)==="Auto"){let W=(n=(r=a==null?void 0:a.contents)==null?void 0:r.find(fe=>(fe==null?void 0:fe.key)==="header"))==null?void 0:n.contents;Array.isArray(W==null?void 0:W[0])&&(W=W==null?void 0:W[0]),W=le.getColumnChild(W);let Z=W==null?void 0:W.filter(fe=>(fe==null?void 0:fe.filter)&&(fe==null?void 0:fe.filter)!==""),ae=new Map,ve=[];Z==null||Z.forEach(fe=>{var we,_e;ae.get((we=fe==null?void 0:fe.menus)==null?void 0:we.join("/"))||(ae.set((_e=fe==null?void 0:fe.menus)==null?void 0:_e.join("/"),fe),ve.push(fe))});let ze=(o=(i=xn==null?void 0:xn.value)==null?void 0:i.find(fe=>(fe==null?void 0:fe.condition)==="child"))==null?void 0:o.value,te=ve==null?void 0:ve.map(fe=>{var we,_e,qe;return fe=(we=fe==null?void 0:fe.menus)==null?void 0:we.join("/"),(fe==null?void 0:fe[(fe==null?void 0:fe.length)-1])==="/"&&((qe=(_e=xn==null?void 0:xn.value)==null?void 0:_e.find(ra=>(ra==null?void 0:ra.condition)==="child"))==null?void 0:qe.parentContent)+"/"!==fe?fe=fe+ze:(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}),N=ve==null?void 0:ve.map(fe=>fe==null?void 0:fe.groups),se=te==null?void 0:te.map(async fe=>{let we=await Hr(fe,!1);return{path:fe,contents:we}});se=await Promise.all(se);let G=se==null?void 0:se.map((fe,we)=>{var qe,ra,P,Ke,Me,Le,Ie;let _e=(qe=fe==null?void 0:fe.contents)==null?void 0:qe.filter(de=>{var De,Xe;return(de==null?void 0:de.name)===((Xe=N==null?void 0:N[we])==null?void 0:Xe[((De=N==null?void 0:N[we])==null?void 0:De.length)-1])});return _e=(Ke=(P=(ra=_e==null?void 0:_e[0])==null?void 0:ra.compData)==null?void 0:P.find(de=>(de==null?void 0:de.key)==="tableContents"))==null?void 0:Ke.contents,(fe==null?void 0:fe.path)===((Le=(Me=xn==null?void 0:xn.value)==null?void 0:Me.find(de=>(de==null?void 0:de.condition)==="child"))==null?void 0:Le.parentContent)&&(_e=((Ie=_e==null?void 0:_e.map(de=>{for(let De in de)if(de[De]===ze)return de}))==null?void 0:Ie.filter(de=>de))??[]),_e??[]});if(G=G==null?void 0:G.map(fe=>(fe=fe==null?void 0:fe.map(we=>{var qe;let _e={};for(let ra in we)if(Z!=null&&Z.find(P=>{var Ke,Me;return((Me=(Ke=P==null?void 0:P.words)==null?void 0:Ke[0])==null?void 0:Me.replaceAll("'",""))===ra})){let P=(qe=Z==null?void 0:Z.find(Ke=>{var Me,Le;return((Le=(Me=Ke==null?void 0:Ke.words)==null?void 0:Me[0])==null?void 0:Le.replaceAll("'",""))===ra}))==null?void 0:qe.prop;_e[P]=we==null?void 0:we[ra]}return _e}),fe)),G=le.cartesianProduct(G),Array.isArray(G==null?void 0:G[0])&&(G=G==null?void 0:G[0]),(G==null?void 0:G.length)>0&&((y=(c=(p=Z==null?void 0:Z[0])==null?void 0:p.menus)==null?void 0:c.join("/"))==null?void 0:y[((g=(m=(u=Z==null?void 0:Z[0])==null?void 0:u.menus)==null?void 0:m.join("/"))==null?void 0:g.length)-1])==="/")return(d=a==null?void 0:a.contents)==null?void 0:d.map(we=>{var _e;return(we==null?void 0:we.key)==="tableContents"&&(G==null?void 0:G.length)>0&&(we.contents=((_e=we.contents)==null?void 0:_e.length)>0?we.contents:G),we})}if((a==null?void 0:a.filter)==="Manual"){let W=[],Z=[],ae=(w=(D=a==null?void 0:a.contents)==null?void 0:D.find(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:w.contents;(ae==null?void 0:ae[(ae==null?void 0:ae.length)-1])===")"?ae=(A=(q=ae==null?void 0:ae.replace("(",Nr))==null?void 0:q.split(Nr))==null?void 0:A[0]:ae="",ae!==""&&(W=((O=(j=ae==null?void 0:ae.split("*"))==null?void 0:j[0])==null?void 0:O.split(":"))??[],Z=((S=(b=(x=(_=(E=ae==null?void 0:ae.split("*"))==null?void 0:E[1])==null?void 0:_.replace("{",Nr))==null?void 0:x.split(Nr))==null?void 0:b[0])==null?void 0:S.split(":"))??[]);let ve=(R=(I=a==null?void 0:a.contents)==null?void 0:I.find(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:R.contents;ve=(X=(re=ve==null?void 0:ve.replace("(",Nr))==null?void 0:re.split(Nr))==null?void 0:X[1],ve=ve==null?void 0:ve.slice(0,(ve==null?void 0:ve.length)-1);let ze=(me=a==null?void 0:a.contents)==null?void 0:me.map(N=>{var se,G,fe,we,_e,qe,ra,P,Ke;return(N==null?void 0:N.key)==="header"&&((se=N==null?void 0:N.contents)!=null&&se.every(Me=>(Me==null?void 0:Me.mainKey)!==!0)&&Array.isArray(N==null?void 0:N.contents)&&!Array.isArray((G=N==null?void 0:N.contents)==null?void 0:G[0])?N.contents=(fe=N==null?void 0:N.contents)==null?void 0:fe.map((Me,Le)=>{var Ie,de,De;return Me!=null&&Me.isMainPath||(Le===0?(Me.mainKey=!0,Me.formType="Select",Me.bindMenus=W,Me.groups=((Ie=Me.groups)==null?void 0:Ie.length)===0?Z:Me.groups,Me.words=((de=Me.words)==null?void 0:de.length)===0?[Me==null?void 0:Me.prop]:Me.words,Me.filter=ve,(!(Me!=null&&Me.menus)||((De=Me==null?void 0:Me.menus)==null?void 0:De.length)===0)&&(Me.menus=W)):(Me.mainKey=!1,Me.bindMenus=W)),Me}):Array.isArray((we=N==null?void 0:N.contents)==null?void 0:we[0])&&((ra=(qe=(_e=N==null?void 0:N.contents)==null?void 0:_e[0])==null?void 0:qe.filter(()=>(W==null?void 0:W.length)>0))==null?void 0:ra.length)>0&&(N.contents[0]=(Ke=(P=N==null?void 0:N.contents)==null?void 0:P[0])==null?void 0:Ke.map((Me,Le)=>{var Ie,de,De;return Me!=null&&Me.isMainPath||(Le===0?(Me.mainKey=!0,Me.formType="Select",Me.bindMenus=W,Me.groups=((Ie=Me.groups)==null?void 0:Ie.length)===0?Z:Me.groups,Me.words=((de=Me.words)==null?void 0:de.length)===0?[Me==null?void 0:Me.prop]:Me.words,Me.filter=ve,(!(Me!=null&&Me.menus)||Array.isArray(Me==null?void 0:Me.menus)&&((De=Me==null?void 0:Me.menus)==null?void 0:De.length)===0)&&(W==null?void 0:W.length)>0&&(Me.menus=W)):(Me.mainKey=!1,Me.bindMenus=W)),Me}))),N}),te=(ue=ze==null?void 0:ze.find(N=>(N==null?void 0:N.key)==="header"))==null?void 0:ue.contents;if(Array.isArray(te==null?void 0:te[0])&&(te=te==null?void 0:te[0]),te=le.getColumnChild(te),te!=null&&te.some(N=>{var se,G;return((G=N==null?void 0:N.menus)==null?void 0:G[((se=N==null?void 0:N.menus)==null?void 0:se.length)-1])===""})){let N=(U=xn==null?void 0:xn.value)==null?void 0:U.find(se=>(se==null?void 0:se.condition)==="child");ze=xp(ze,N)}return ze}if((a==null?void 0:a.filter)==="Chart"){let W=a==null?void 0:a.contents;return W.push({key:"newType",contents:"Chart"}),W}if((a==null?void 0:a.filter)==="Carousel"){let W=a==null?void 0:a.contents;return W.push({key:"newType",contents:"Carousel"}),W}return a==null?void 0:a.contents},Op=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},Lp=a=>{var n,i,o,p,c,u,m,g,y,d,D,w;let l=a==null?void 0:a.filter;if(l!=null&&l.includes("*")&&(l="({"+((i=(n=l==null?void 0:l.replace(":",Nr))==null?void 0:n.split(Nr))==null?void 0:i[1])),l=(o=l==null?void 0:l.replaceAll("{",""))==null?void 0:o.replaceAll("}",""),(c=(p=l==null?void 0:l.split("="))==null?void 0:p[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 q=(u=l==null?void 0:l.split("="))==null?void 0:u[0],A=(m=l==null?void 0:l.split("="))==null?void 0:m[1];(g=A==null?void 0:A.slice(1,A==null?void 0:A.length))!=null&&g.includes("$")&&(A=(D=(d=(y=xn==null?void 0:xn.value)==null?void 0:y.filter(j=>(j==null?void 0:j.condition)==="child"))==null?void 0:d[0])==null?void 0:D.value),l=q+"="+A}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 r=le.calculatorAndToOr(l);if((r==null?void 0:r.length)>0){let q=[];return r==null||r.forEach(j=>{let O={};for(let E in j){let _=E;_!=null&&_.includes("[")||(O[_]=j[E])}q.push(O)}),(w=a==null?void 0:a.contents)==null?void 0:w.map(j=>{var E,_,x;let O=(_=(E=a==null?void 0:a.contents)==null?void 0:E.find(b=>(b==null?void 0:b.key)==="header"))==null?void 0:_.contents;if(O=(x=le.getEqualChild(O))==null?void 0:x.filter(b=>(b==null?void 0:b.label)!=="操作"),(j==null?void 0:j.key)==="tableContents"){let S=le.tableToForm(j==null?void 0:j.contents,O);q==null||q.forEach(I=>{var R,re;for(let X in I)!((R=S==null?void 0:S[0])!=null&&R.find(me=>{var ue;return(me==null?void 0:me.key)===X||((ue=me==null?void 0:me.key)==null?void 0:ue.includes(X))}))&&!(S!=null&&S.find(me=>{var ue;return(me==null?void 0:me.key)===X||((ue=me==null?void 0:me.key)==null?void 0:ue.includes(X))}))||(((re=I[X])==null?void 0:re[0])!=="!"?S=S==null?void 0:S.filter(me=>{var ue,U;return((ue=me==null?void 0:me.find(W=>{var Z;return(W==null?void 0:W.key)===X||((Z=W==null?void 0:W.key)==null?void 0:Z.includes(X))}))==null?void 0:ue.value)===I[X]||Array.isArray(I==null?void 0:I[X])&&((U=I==null?void 0:I[X])==null?void 0:U.find(W=>{var Z;return((Z=me==null?void 0:me.find(ae=>{var ve;return(ae==null?void 0:ae.key)===X||((ve=ae==null?void 0:ae.key)==null?void 0:ve.includes(X))}))==null?void 0:Z.value)===W}))}):S=S==null?void 0:S.filter(me=>{var ue;return((ue=me==null?void 0:me.find(U=>{var W;return(U==null?void 0:U.key)===X||((W=U==null?void 0:U.key)==null?void 0:W.includes(X))}))==null?void 0:ue.value)!==(I[X]==="!"?"":I==null?void 0:I[X])}))}),(S==null?void 0:S.length)===0?j.contents=[]:j.contents=S==null?void 0:S.map(I=>{let R={};return I==null||I.forEach(re=>{R[re==null?void 0:re.key]=re==null?void 0:re.value}),R})}return j})}return a==null?void 0:a.contents},Rp=a=>a==null?void 0:a.contents,$p=a=>a==null?void 0:a.contents,Vp=a=>{var l,r,n,i;if((a==null?void 0:a.filter)!==""&&(a!=null&&a.filter)){let o=(n=(r=a==null?void 0:a.filter)==null?void 0:r.slice(1,((l=a==null?void 0:a.filter)==null?void 0:l.length)-1))==null?void 0:n.split(",");return(i=a==null?void 0:a.contents)==null?void 0:i.map(c=>((c==null?void 0:c.key)==="header"&&(c.contents=Tt(c.contents,o)),c))}return a==null?void 0:a.contents},Fp=a=>{var r,n,i,o,p;let l=(a==null?void 0:a.filter)??"";if(l!==""){let c=(n=(r=l==null?void 0:l.replace("(",Nr))==null?void 0:r.split(Nr))==null?void 0:n[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=le.analyzeSplitToContent(c,","))==null?void 0:i.map(y=>((y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),y));let u=c==null?void 0:c[0];(u==null?void 0:u[0])==="("&&(u=u==null?void 0:u.slice(1,(u==null?void 0:u.length)-1));let m=(c==null?void 0:c[1])??"Up",g=(o=a==null?void 0:a.contents)==null?void 0:o.map(y=>{var d,D;if(m==="Up"){if((y==null?void 0:y.key)==="extraButton"){let w=(d=u==null?void 0:u.split(","))==null?void 0:d.map(q=>({label:q,prop:q}));y.contents=[...w??[],...y.contents]}}else if(m==="Line"&&(y==null?void 0:y.key)==="rowButton"){let w=(D=u==null?void 0:u.split(","))==null?void 0:D.map(q=>({label:q,prop:q}));y.contents=[...w??[],...y.contents]}return y});if(m==="Bottom"||m==="Down"){let y=(p=u==null?void 0:u.split(","))==null?void 0:p.map(d=>({label:d,prop:d}));g.push({key:"bottomButton",contents:y})}return g}return a==null?void 0:a.contents},Pp=a=>a==null?void 0:a.contents,jp=a=>{var r;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!==""?(r=a==null?void 0:a.contents)==null?void 0:r.map(i=>{var o;return(i==null?void 0:i.key)==="rowButton"&&(i.contents=(o=l==null?void 0:l.split(","))==null?void 0:o.map(p=>({label:p,prop:p}))),i}):a==null?void 0:a.contents},Hp=a=>{var r;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 n=a==null?void 0:a.contents,i=(r=l==null?void 0:l.split(","))==null?void 0:r.map(o=>({label:o,prop:o}));return n.push({key:"bottomButton",contents:i}),n}return a==null?void 0:a.contents},Up=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(r=>{var n;return(r==null?void 0:r.key)==="formContent"&&(r.contents=(n=r.contents)==null?void 0:n.map(i=>(i.isNoClick=!0,i))),r}),l!=null&&l.find(r=>(r==null?void 0:r.key)==="tableContents")&&(l==null||l.push({key:"isEdit",contents:!1}),l=l==null?void 0:l.filter(r=>(r==null?void 0:r.key)!=="extraButton"&&(r==null?void 0:r.key)!=="rowButton")),l}return a==null?void 0:a.contents},qp=a=>{var l;if(a!=null&&a.filter){const r=parseInt(a==null?void 0:a.filter);return!r||Number.isNaN(r)?a==null?void 0:a.contents:(l=a==null?void 0:a.contents)==null?void 0:l.map(i=>{var o;return(i==null?void 0:i.key)==="formContent"&&(i.contents=(o=i.contents)==null?void 0:o.map(p=>(p.width=r,p))),i})}return a==null?void 0:a.contents},Wp=a=>{var l,r,n,i;if(((l=a==null?void 0:a.filter)==null?void 0:l[0])!=="["){const o=parseInt(a==null?void 0:a.filter);return!o||Number.isNaN(o)?a==null?void 0:a.contents:(r=a==null?void 0:a.contents)==null?void 0:r.map(c=>{var u;return(c==null?void 0:c.key)==="formContent"&&(c.contents=(u=c.contents)==null?void 0:u.map(m=>(m.width=o,m))),c})}if(((n=a==null?void 0:a.filter)==null?void 0:n[0])==="["){let o=Li(a==null?void 0:a.filter),p=Array.isArray(o)?o.map(u=>parseInt(u)).filter(u=>!!u&&!Number.isNaN(u)):[];return p.length?(i=a==null?void 0:a.contents)==null?void 0:i.map(u=>{if((u==null?void 0:u.key)==="formContent"){const m=u.contents??[];u.contents=m.map((g,y)=>{const d=y+1;let D=0,w=0;for(let A=0;A<p.length;A++){if(w+=p[A],d<=w){D=A;break}A===p.length-1&&(D=p.length-1)}const q=p[D]||p[p.length-1]||1;return g.width=q,g})}return u}):a==null?void 0:a.contents}return a==null?void 0:a.contents},Gp=a=>{var l;if((a==null?void 0:a.filter)!==""){let 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=r==null?void 0:r.split(","),(l=a==null?void 0:a.contents)==null?void 0:l.map(i=>{var o,p,c;return(i==null?void 0:i.key)==="header"&&(Array.isArray((o=i==null?void 0:i.contents)==null?void 0:o[0])?i.contents[0]=(c=i.contents[0])==null?void 0:c.map(u=>(r!=null&&r.find(m=>m===(u==null?void 0:u.prop))&&(u.fixed="left"),u)):i.contents=(p=i.contents)==null?void 0:p.map(u=>(r!=null&&r.find(m=>m===(u==null?void 0:u.prop))&&(u.fixed="left"),u))),i})}return a==null?void 0:a.contents},Kp=a=>{var l;if((a==null?void 0:a.filter)!==""){let r=a==null?void 0:a.filter;(r==null?void 0:r[0])==="("&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1)),r=r==null?void 0:r.split(",");const n=o=>(r!=null&&r.find(p=>p===(o==null?void 0:o.prop))&&(o.required=!0),o!=null&&o.children&&Array.isArray(o.children)&&(o.children=o.children.map(p=>n(p))),o);return(l=a==null?void 0:a.contents)==null?void 0:l.map(o=>{var p,c,u;return(o==null?void 0:o.key)==="header"&&(Array.isArray((p=o==null?void 0:o.contents)==null?void 0:p[0])?o.contents[0]=(u=o.contents[0])==null?void 0:u.map(m=>n(m)):o.contents=(c=o.contents)==null?void 0:c.map(m=>n(m))),o})}return a==null?void 0:a.contents},Yp=async a=>{var n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E;const l=M.useUnit(M.pinia),{chooseTitle:r}=M.storeToRefs(l);if((a==null?void 0:a.filter)==="true"){let _=await Hr(((i=(n=r==null?void 0:r.value)==null?void 0:n[0])==null?void 0:i.parentContent)??((p=(o=r==null?void 0:r.value)==null?void 0:o[0])==null?void 0:p.relatedContent),!1),x=(u=(c=r==null?void 0:r.value)==null?void 0:c[0])==null?void 0:u.value;(g=(m=_==null?void 0:_[0])==null?void 0:m.compData)!=null&&g.find(R=>(R==null?void 0:R.key)==="header")?_=(y=_==null?void 0:_[0])==null?void 0:y.compData:_=(D=(d=_==null?void 0:_.filter(R=>{var re;return(re=R==null?void 0:R.compData)==null?void 0:re.find(X=>(X==null?void 0:X.key)==="header")}))==null?void 0:d[0])==null?void 0:D.compData;let b=(w=_==null?void 0:_.find(R=>(R==null?void 0:R.key)==="header"))==null?void 0:w.contents;Array.isArray(b==null?void 0:b[0])&&(b=b==null?void 0:b[0]),b=((q=b==null?void 0:b.find(R=>R==null?void 0:R.isMainKey))==null?void 0:q.prop)??((A=b==null?void 0:b[0])==null?void 0:A.prop);let S=(O=(j=_==null?void 0:_.find(R=>(R==null?void 0:R.key)==="tableContents"))==null?void 0:j.contents)==null?void 0:O.find(R=>(R==null?void 0:R[b])===x);return(E=a==null?void 0:a.contents)==null?void 0:E.map(R=>{var re;return(R==null?void 0:R.key)==="formContent"&&(R.contents=(re=R.contents)==null?void 0:re.map(X=>(X.value=S==null?void 0:S[X==null?void 0:X.prop],X))),R})}return a==null?void 0:a.contents},Jp=a=>{var l,r,n,i,o;if((l=a==null?void 0:a.extra)!=null&&l.row){let p=a==null?void 0:a.filter;if(p!=null&&p.includes("*")&&(p="({"+((n=(r=p==null?void 0:p.replace("{",Nr))==null?void 0:r.split(Nr))==null?void 0:n[1])),p=(i=p==null?void 0:p.replaceAll("{",""))==null?void 0:i.replaceAll("}",""),(p==null?void 0:p[0])!=="("&&(p="("+p+")"),p.slice(1,(p==null?void 0:p.length)-1)==="undefined")return a==null?void 0:a.contents;let c=le.calculatorAndToOr(p),u=c==null?void 0:c[0],m=(o=a==null?void 0:a.extra)==null?void 0:o.row,g=[];for(let y in u)(u==null?void 0:u[y])===(m==null?void 0:m[y])?g.push(!0):g.push(!1);return g!=null&&g.every(y=>y===!0)?a==null?void 0:a.contents:[]}else return a==null?void 0:a.contents},Xp=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"tab",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Zp=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"choice",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Qp=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},ef=a=>{var l;if(a!=null&&a.filter){let r=a==null?void 0:a.contents,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=(l=le.analyzeSplitToContent(n,","))==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)),r.push({key:"stepName",contents:n}),r}return a==null?void 0:a.contents},af=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},kc={onNumSlice:Mp,onRandomContents:Ip,onConditionContents:Lp,onFatherPaceContents:Rp,onPaceContents:$p,onMainTagContents:Vp,onButtonContents:Fp,onPamButtonContents:Pp,onRowButtonContents:jp,onRelated:Yp,onRowNum:Wp,onFixRow:Gp,onReqItem:Kp,onBottomButtonContents:Hp,onConditionContent:Jp,onTabs:Xp,onSinChoice:Zp,onTextSize:Ap,onTextRGBA:zp,onTextBackRGBA:Cp,onPosition:Tp,onColumnNum:Bp,onSize:Np,onShowType:Qp,onStepName:ef,onStep:af,onInterfaceTypeContents:Op,onBackGround:Dp,onMaxColumn:qp,onEditRead:Up,onShowHide:Ep},lf=async(a,l,r="")=>{var p,c,u,m,g,y,d,D,w,q,A,j;let n="";if(((p=a==null?void 0:a.find(O=>(O==null?void 0:O.key)==="filter"))==null?void 0:p.contents)!==""&&(n=(c=a==null?void 0:a.find(O=>(O==null?void 0:O.key)==="filter"))==null?void 0:c.contents),n===""||!n)return a;(n==null?void 0:n[0])==="("?n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1):(n=(m=(u=n==null?void 0:n.replace("(",Nr))==null?void 0:u.split(Nr))==null?void 0:m[1],n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1));let i=(g=le.analyzeSplitToContent(n,","))==null?void 0:g.map(O=>((O==null?void 0:O[(O==null?void 0:O.length)-1])===","&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1)),O!=null&&O.includes("(")||(O=O==null?void 0:O.replaceAll(":","=")),O)),o=a;for(let O in i){let E,_="";E=(D=(d=(y=i==null?void 0:i[O])==null?void 0:y.replace("=",Nr))==null?void 0:d.split(Nr))==null?void 0:D[0],_=(A=(q=(w=i==null?void 0:i[O])==null?void 0:w.replace("=",Nr))==null?void 0:q.split(Nr))==null?void 0:A[1];let x=(j=Mn==null?void 0:Mn.find(b=>(b==null?void 0:b.key)===E))==null?void 0:j.value;if(x){const b=kc[x];o=await b({contents:o,filter:_,extra:l,groupName:r})}}return o},Vo=async(a,l,r="")=>{var c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re;let n="";if(((c=a==null?void 0:a.find(X=>(X==null?void 0:X.key)==="filter"))==null?void 0:c.contents)!==""&&(n=(u=a==null?void 0:a.find(X=>(X==null?void 0:X.key)==="filter"))==null?void 0:u.contents),n===""||!n)return a;(n==null?void 0:n[0])===","&&(n=n==null?void 0:n.slice(1,n==null?void 0:n.length)),(n==null?void 0:n[0])==="("?n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1):(n==null?void 0:n[0])==="@"||(n=(g=(m=n==null?void 0:n.replace("(",Nr))==null?void 0:m.split(Nr))==null?void 0:g[1],n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1));let i=(y=le.analyzeSplitToContent(n,","))==null?void 0:y.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)),o=a,p=new Map;i==null||i.forEach(X=>{var ue,U,W;let me=(ue=X==null?void 0:X.split("="))==null?void 0:ue[0];if(me==="@MainParam"&&p.get(me)){let Z=p.get(me);Z=Z==null?void 0:Z.slice(0,(Z==null?void 0:Z.length)-1);let ae=(W=(U=X==null?void 0:X.replace("{",Nr))==null?void 0:U.split(Nr))==null?void 0:W[1];ae=Z+","+ae,p.set(me,ae)}else me==="@Button"&&p.get(me)?p.set(X,X):p.set(me,X)}),i=Array.from(p.values()),i=i==null?void 0:i.sort((X,me)=>{var ue,U;return((ue=Mn==null?void 0:Mn.find(W=>me==null?void 0:me.includes(W==null?void 0:W.key)))==null?void 0:ue.order)-((U=Mn==null?void 0:Mn.find(W=>X==null?void 0:X.includes(W==null?void 0:W.key)))==null?void 0:U.order)});for(let X in i){let me,ue="";(d=i==null?void 0:i[X])!=null&&d.includes("(")&&((D=i==null?void 0:i[X])!=null&&D.includes("@If"))?(me=(A=(q=(w=i==null?void 0:i[X])==null?void 0:w.replace("(",Nr))==null?void 0:q.split(Nr))==null?void 0:A[0],ue="("+((E=(O=(j=i==null?void 0:i[X])==null?void 0:j.replace("(",Nr))==null?void 0:O.split(Nr))==null?void 0:E[1])):(me=(b=(x=(_=i==null?void 0:i[X])==null?void 0:_.replace("=",Nr))==null?void 0:x.split(Nr))==null?void 0:b[0],ue=(R=(I=(S=i==null?void 0:i[X])==null?void 0:S.replace("=",Nr))==null?void 0:I.split(Nr))==null?void 0:R[1]);let U=(re=Mn==null?void 0:Mn.find(W=>(W==null?void 0:W.key)===me))==null?void 0:re.value;if(U){const W=kc[U];o=await W({contents:o,filter:ue,extra:l,groupName:r})}}return o},xc=a=>{if(a==null)return null;const l=String(a).trim();if(!l.startsWith("(")||!l.endsWith(")"))return null;const r=l.slice(1,-1).split(",").map(n=>Number(n.trim()));return r.length<2||r.some(n=>Number.isNaN(n))?null:[r[0],r[1]]},rf=(a,l)=>{var q,A,j,O,E;const r=Array.isArray(a)?a:[],n=r.find(_=>(_==null?void 0:_.key)==="formContent"),i=Array.isArray(n==null?void 0:n.contents)?n.contents:[],o=((q=r.find(_=>(_==null?void 0:_.key)==="_gridLayoutMeta"))==null?void 0:q.contents)??{},p=(i==null?void 0:i[0])??{};let c=((A=l==null?void 0:l.position)==null?void 0:A[0])??(o==null?void 0:o._positionStartRow)??(p==null?void 0:p._positionStartRow),u=((j=l==null?void 0:l.position)==null?void 0:j[1])??(o==null?void 0:o._positionRowSpan)??(p==null?void 0:p._positionRowSpan);(!c||Number.isNaN(c)||c<1)&&(c=1),(!u||Number.isNaN(u)||u<1)&&(u=1);let m=((O=l==null?void 0:l.size)==null?void 0:O[0])??(o==null?void 0:o._sizeStart)??(p==null?void 0:p._sizeStart),g=((E=l==null?void 0:l.size)==null?void 0:E[1])??(o==null?void 0:o._sizeEnd)??(p==null?void 0:p._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 y=g-m,d=Math.max(1,Math.round(1/y));let D=r.map(_=>{if((_==null?void 0:_.key)!=="formContent")return _;const x=Array.isArray(_==null?void 0:_.contents)?_.contents:[];return{..._,contents:x.map(b=>({...b,width:d,_positionStartRow:c,_positionRowSpan:u,_sizeStart:m,_sizeEnd:g}))}});const w={_positionStartRow:c,_positionRowSpan:u,_sizeStart:m,_sizeEnd:g};return D.some(_=>(_==null?void 0:_.key)==="_gridLayoutMeta")?D=D.map(_=>(_==null?void 0:_.key)==="_gridLayoutMeta"?{..._,contents:w}:_):D.push({key:"_gridLayoutMeta",contents:w}),D};let Ni="$R";const nf=M.useUnit(M.pinia),{selectTitle:of}=M.storeToRefs(nf);let tf=[{label:"新增",prop:"新增"},{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],sf=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"},{label:"复制新增",prop:"复制新增"},{label:"删除",prop:"删除"}],cf=[{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],uf=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"}];const xs=async(a,l,r=!0)=>{let n=[],i=a==null?void 0:a.map(async o=>{var y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha,Sa,ll,Te,oa,Ka,pe,_a,Pa,ul,Ol;let p=(w=(D=(d=(y=o==null?void 0:o.contents)==null?void 0:y.find(ca=>{var Xa;return(Xa=ca==null?void 0:ca.key)==null?void 0:Xa.includes("struct")}))==null?void 0:d.value)==null?void 0:D[0])==null?void 0:w.类型,c=Object.values(o==null?void 0:o.name);c=c==null?void 0:c.reverse();let u=(q=o==null?void 0:o.contents)==null?void 0:q.map(ca=>ca==null?void 0:ca.key),m={comp:p,isShow:o==null?void 0:o.is_show,name:c==null?void 0:c[0],id:o==null?void 0:o.object_id,order_no:o==null?void 0:o.order_no,relatedTables:u,menuFilter:(A=o==null?void 0:o.filter)==null?void 0:A.menuFilter,status:o==null?void 0:o.status,fatherSyncContents:(j=o==null?void 0:o.filter)==null?void 0:j.fatherSyncs,relatedQuotes:(O=o==null?void 0:o.filter)==null?void 0:O.quotes,sonSyncContents:(E=o==null?void 0:o.filter)==null?void 0:E.sonSyncs,nameContents:(_=M.cloneDeep(c))==null?void 0:_.reverse(),isHidden:!1,calculatorFilters:(R=(I=(S=(b=(x=o==null?void 0:o.contents)==null?void 0:x.find(ca=>{var Xa;return(Xa=ca==null?void 0:ca.key)==null?void 0:Xa.includes("struct")}))==null?void 0:b.value)==null?void 0:S[0])==null?void 0:I.算法)==null?void 0:R.contents};for(let ca in c)parseInt(ca)>=1&&(m[`name${parseInt(ca)-1}`]=c[ca]);let g=Array.isArray((re=o==null?void 0:o.filter)==null?void 0:re.menuFilter)?(X=o==null?void 0:o.filter)==null?void 0:X.menuFilter:[];if(((me=g==null?void 0:g.filter(ca=>ca==null?void 0:ca.includes("@If")))==null?void 0:me.length)>0){let ca=g==null?void 0:g.filter(Fe=>Fe==null?void 0:Fe.includes("@If"));ca=ca==null?void 0:ca[0],ca=(U=(ue=ca==null?void 0:ca.replace("(",Ni))==null?void 0:ue.split(Ni))==null?void 0:U[1],ca=ca==null?void 0:ca.slice(0,(ca==null?void 0:ca.length)-1),ca!=null&&ca.includes("*")&&(ca=(Z=(W=ca==null?void 0:ca.replace("{",Ni))==null?void 0:W.split(Ni))==null?void 0:Z[1],ca=ca==null?void 0:ca.replace("}","")),ca=le.calculatorAndToOr(ca);let Xa=(l==null?void 0:l.originPath)??"";(Xa==null?void 0:Xa[(Xa==null?void 0:Xa.length)-1])==="/"&&(Xa=Xa==null?void 0:Xa.slice(0,(Xa==null?void 0:Xa.length)-1));let ua=await Hr(Xa,!1),wa=(ae=ua==null?void 0:ua.filter(Fe=>(Fe==null?void 0:Fe.comp)==="Table"))==null?void 0:ae[0];wa=(ze=(ve=wa==null?void 0:wa.compData)==null?void 0:ve.find(Fe=>(Fe==null?void 0:Fe.key)==="tableContents"))==null?void 0:ze.contents;let Ba=(N=(te=of.value)==null?void 0:te.find(Fe=>(Fe==null?void 0:Fe.condition)==="child"))==null?void 0:N.value;wa=(se=wa==null?void 0:wa.map(Fe=>{for(let bl in Fe)if((Fe==null?void 0:Fe[bl])===Ba)return Fe}))==null?void 0:se.filter(Fe=>Fe),wa=wa==null?void 0:wa[0],ca=ca==null?void 0:ca[0];let hl=[];for(let Fe in ca){let bl="";Ja.isObject(wa)&&(bl=(fe=(G=Object.keys(wa))==null?void 0:G.filter(tr=>tr==null?void 0:tr.includes("."+Fe)))==null?void 0:fe[0]),bl!==""&&(wa!=null&&wa[bl])&&(ca==null?void 0:ca[Fe])===(wa==null?void 0:wa[bl])||wa!=null&&wa[Fe]&&(ca==null?void 0:ca[Fe])===(wa==null?void 0:wa[Fe])?hl.push(!0):hl.push(!1)}if(hl!=null&&hl.some(Fe=>Fe===!1)&&((_e=l==null?void 0:l.originPath)==null?void 0:_e[((we=l==null?void 0:l.originPath)==null?void 0:we.length)-1])!=="/")return}if(p==="Table"||p==="Method"){!r&&((qe=m==null?void 0:m.fatherSyncContents)==null?void 0:qe.length)>0;let ca=((ra=o==null?void 0:o.contents)==null?void 0:ra.find(Ra=>{var kl;return(kl=Ra==null?void 0:Ra.key)==null?void 0:kl.includes("content")}))||[],Xa=[];m.comp="Table",ca.value=(P=ca==null?void 0:ca.value)==null?void 0:P.sort((Ra,kl)=>parseInt(Ra==null?void 0:Ra.id)-parseInt(kl==null?void 0:kl.id)),ca.value=(Ke=ca==null?void 0:ca.value)==null?void 0:Ke.map(Ra=>{let kl={};for(let Ml in Ra)JSON.stringify(Ra==null?void 0:Ra[Ml])==="{}"?kl[Ml]="":kl[Ml]=Ra==null?void 0:Ra[Ml];return kl}),Xa.push({key:"tableContents",contents:ca==null?void 0:ca.value});let ua=(De=(de=(Ie=(Le=(Me=o==null?void 0:o.contents)==null?void 0:Me.find(Ra=>{var kl;return(kl=Ra==null?void 0:Ra.key)==null?void 0:kl.includes("struct")}))==null?void 0:Le.value)==null?void 0:Ie[0])==null?void 0:de.结构)==null?void 0:De.contents;Array.isArray(ua==null?void 0:ua[0])?ua[0]=(Xe=ua==null?void 0:ua[0])==null?void 0:Xe.filter(Ra=>(Ra==null?void 0:Ra.prop)!=="sort"&&(Ra==null?void 0:Ra.prop)!=="relatedId"):ua=ua==null?void 0:ua.filter(Ra=>(Ra==null?void 0:Ra.prop)!=="sort"&&(Ra==null?void 0:Ra.prop)!=="relatedId"),Xa.push({key:"header",contents:ua}),Xa.push({key:"filter",contents:(ee=(V=($=(Ge=(Ea=o==null?void 0:o.contents)==null?void 0:Ea.find(Ra=>{var kl;return(kl=Ra==null?void 0:Ra.key)==null?void 0:kl.includes("struct")}))==null?void 0:Ge.value)==null?void 0:$[0])==null?void 0:V.引用)==null?void 0:ee.contents}),Xa.push({key:"calculator",contents:m==null?void 0:m.calculatorFilters});let wa=tf,Ba=M.cloneDeep(sf);p==="Method"&&Ba.push({label:"生成方法",prop:"生成方法"}),!Array.isArray(ua==null?void 0:ua[0])&&((ce=ua==null?void 0:ua[0])==null?void 0:ce.prop)==="disabled"&&(wa=cf,Ba=uf);const hl=["推力","真空","压力","温度","流量"],Fe=m.name;Fe&&hl.includes(Fe)&&(wa=[...wa],wa.push({label:"导出paraform",prop:"导出paraform",type:"methodButton"}));let bl=[];if(!Array.isArray(ua==null?void 0:ua[0])&&(ua!=null&&ua.some(Ra=>{var kl;return(Ra==null?void 0:Ra.calculatorFilter)&&((kl=Ra==null?void 0:Ra.calculatorFilter)==null?void 0:kl.includes("Manual"))}))){let Ra=(he=ua==null?void 0:ua.map(kl=>kl==null?void 0:kl.calculatorFilter))==null?void 0:he.filter(kl=>kl&&(kl==null?void 0:kl.includes("Manual")));Ra==null||Ra.forEach(kl=>{var Oa;let Ml=le.analyzeSplitToContent(kl,",");if(Ml=Ml==null?void 0:Ml.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)),Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Extent"))&&(aa==null?void 0:aa.includes("Row")))&&(Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Button"))&&(aa==null?void 0:aa.includes(","))))){let aa=Ml==null?void 0:Ml.find(Rl=>Rl==null?void 0:Rl.includes("@FunctionButton"));aa=(Oa=aa==null?void 0:aa.split("="))==null?void 0:Oa[1],aa=aa==null?void 0:aa.slice(1,(aa==null?void 0:aa.length)-1),aa=aa==null?void 0:aa.split(","),aa=aa==null?void 0:aa[(aa==null?void 0:aa.length)-1],bl.push(aa)}}),bl=[...new Set(bl)],bl=bl==null?void 0:bl.map(kl=>({label:kl,prop:kl,type:"methodButton"}))}else if(Array.isArray(ua==null?void 0:ua[0])&&((pa=le.getColumnChild(ua==null?void 0:ua[0]))!=null&&pa.some(Ra=>{var kl;return(Ra==null?void 0:Ra.calculatorFilter)&&((kl=Ra==null?void 0:Ra.calculatorFilter)==null?void 0:kl.includes("Manual"))}))){let Ra=(Ve=(ia=le.getColumnChild(ua==null?void 0:ua[0]))==null?void 0:ia.map(kl=>kl==null?void 0:kl.calculatorFilter))==null?void 0:Ve.filter(kl=>kl&&(kl==null?void 0:kl.includes("Manual")));Ra==null||Ra.forEach(kl=>{var Oa;let Ml=le.analyzeSplitToContent(kl,",");if(Ml=Ml==null?void 0:Ml.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)),Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Extent"))&&(aa==null?void 0:aa.includes("Row")))&&(Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Button"))&&(aa==null?void 0:aa.includes(","))))){let aa=Ml==null?void 0:Ml.find(Rl=>Rl==null?void 0:Rl.includes("@FunctionButton"));aa=(Oa=aa==null?void 0:aa.split("="))==null?void 0:Oa[1],aa=aa==null?void 0:aa.slice(1,(aa==null?void 0:aa.length)-1),aa=aa==null?void 0:aa.split(","),aa=aa==null?void 0:aa[(aa==null?void 0:aa.length)-1],bl.push(aa)}}),bl=[...new Set(bl)],bl=bl==null?void 0:bl.map(kl=>({label:kl,prop:kl,type:"methodButton"}))}if(Xa.push({key:"extraButton",contents:wa}),Xa.push({key:"rowButton",contents:[...Ba,...bl]}),m.compData=await Vo(Xa,l,m==null?void 0:m.nameContents),(ya=m.compData)!=null&&ya.find(Ra=>(Ra==null?void 0:Ra.key)==="tab")&&(m.tab=(Ce=(Ca=m.compData)==null?void 0:Ca.find(Ra=>(Ra==null?void 0:Ra.key)==="tab"))==null?void 0:Ce.contents),(Fa=m.compData)!=null&&Fa.find(Ra=>(Ra==null?void 0:Ra.key)==="step")&&(m.step=(fa=(Ta=m.compData)==null?void 0:Ta.find(Ra=>(Ra==null?void 0:Ra.key)==="step"))==null?void 0:fa.contents),(ja=m.compData)!=null&&ja.find(Ra=>(Ra==null?void 0:Ra.key)==="choice")&&(m.choice=(Pe=(sa=m.compData)==null?void 0:sa.find(Ra=>(Ra==null?void 0:Ra.key)==="choice"))==null?void 0:Pe.contents),(ma=m.compData)!=null&&ma.find(Ra=>(Ra==null?void 0:Ra.key)==="hideContents")&&(m.isHidden=((Oe=(Qe=m.compData)==null?void 0:Qe.find(Ra=>(Ra==null?void 0:Ra.key)==="hideContents"))==null?void 0:Oe.contents)??!1),($e=m.compData)!=null&&$e.find(Ra=>(Ra==null?void 0:Ra.key)==="newType")){let Ra=(We=(ne=m.compData)==null?void 0:ne.find(kl=>(kl==null?void 0:kl.key)==="newType"))==null?void 0:We.contents;m.comp=Ra,m.compData=(na=m.compData)==null?void 0:na.filter(kl=>(kl==null?void 0:kl.key)!=="newType")}let tr="",xr=(va=m==null?void 0:m.compData)==null?void 0:va.filter(Ra=>(Ra==null?void 0:Ra.key)==="fixType");if((xr==null?void 0:xr.length)>0&&r&&(tr=(Ae=xr==null?void 0:xr[0])==null?void 0:Ae.contents,m.comp=tr),((Be=m==null?void 0:m.calculatorFilters)==null?void 0:Be.length)>0){let Ra=[],kl=[],Ml=[];(Ye=m==null?void 0:m.calculatorFilters)==null||Ye.forEach(Oa=>{var Rl,Yr,Jr,vn,en,Ar,Re;let aa=(Jr=(Yr=(Rl=Oa==null?void 0:Oa.calculatorFilter)==null?void 0:Rl.replace("(",Ni))==null?void 0:Yr.split(Ni))==null?void 0:Jr[1];aa=(vn=aa==null?void 0:aa.split(","))==null?void 0:vn[0],aa=aa??(Oa==null?void 0:Oa.functionName),(en=Oa==null?void 0:Oa.calculatorFilter)!=null&&en.includes("Up")&&Ra.push({label:aa,prop:aa,type:"methodButton"}),(Ar=Oa==null?void 0:Oa.calculatorFilter)!=null&&Ar.includes("Line")&&kl.push({label:aa,prop:aa,type:"methodButton"}),(Re=Oa==null?void 0:Oa.calculatorFilter)!=null&&Re.includes("Down")&&Ml.push({label:aa,prop:aa,type:"methodButton"})}),m.compData=(Ee=m.compData)==null?void 0:Ee.map(Oa=>((Oa==null?void 0:Oa.key)==="extraButton"&&(Oa.contents=[...Ra??[],...Oa.contents]),(Oa==null?void 0:Oa.key)==="rowButton"&&(Oa.contents=[...kl??[],...Oa.contents]),(Oa==null?void 0:Oa.key)==="bottomButton"&&(Oa.contents=[...Ml??[],...Oa.contents]),Oa)),(Ml==null?void 0:Ml.length)>0&&!(($a=(ye=m.compData)==null?void 0:ye.find(Oa=>(Oa==null?void 0:Oa.key)==="bottomButton"))!=null&&$a.contents)&&m.compData.push({key:"bottomButton",contents:Ml})}}else if(p==="Form"){let ca=[],Xa=(Pl=(Qa=(wl=o==null?void 0:o.contents)==null?void 0:wl.find(Fe=>{var bl;return(bl=Fe==null?void 0:Fe.key)==null?void 0:bl.includes("content")}))==null?void 0:Qa.value)==null?void 0:Pl[0],ua=[],wa=Array.isArray((gl=o==null?void 0:o.filter)==null?void 0:gl.menuFilter)?(jl=o==null?void 0:o.filter)==null?void 0:jl.menuFilter:[];wa==null||wa.forEach(Fe=>{if(Fe!=null&&Fe.includes("@Param(Hide=Yes, prop=")||Fe!=null&&Fe.includes("(Hide=Yes, prop=")){const bl=Fe==null?void 0:Fe.match(/prop=([^,)]+)/);bl!=null&&bl[1]&&ua.push(bl==null?void 0:bl[1])}});let Ba=(Kl=(Gl=(Wa=(Hl=(al=o==null?void 0:o.contents)==null?void 0:al.find(Fe=>{var bl;return(bl=Fe==null?void 0:Fe.key)==null?void 0:bl.includes("struct")}))==null?void 0:Hl.value)==null?void 0:Wa[0])==null?void 0:Gl.结构)==null?void 0:Kl.contents,hl=(Zl=Ba==null?void 0:Ba.map(Fe=>(Fe.value=Xa==null?void 0:Xa[Fe==null?void 0:Fe.prop],Fe)))==null?void 0:Zl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="sort"&&(Fe==null?void 0:Fe.prop)!=="relatedId");hl=hl==null?void 0:hl.map(Fe=>(ua!=null&&ua.includes(Fe==null?void 0:Fe.prop)&&(Fe.isHideInForm=!0),Fe)),ca.push({key:"calculator",contents:m==null?void 0:m.calculatorFilters}),ca.push({key:"filter",contents:(fl=(il=(ga=(dr=(Sl=o==null?void 0:o.contents)==null?void 0:Sl.find(Fe=>{var bl;return(bl=Fe==null?void 0:Fe.key)==null?void 0:bl.includes("struct")}))==null?void 0:dr.value)==null?void 0:ga[0])==null?void 0:il.引用)==null?void 0:fl.contents}),ca.push({key:"formContent",contents:hl}),ca.push({key:"paramHideProps",contents:ua}),m.compData=await lf(ca,l,m==null?void 0:m.nameContents),(Bl=m.compData)!=null&&Bl.find(Fe=>(Fe==null?void 0:Fe.key)==="tab")&&(m.tab=(Sa=(Ha=m.compData)==null?void 0:Ha.find(Fe=>(Fe==null?void 0:Fe.key)==="tab"))==null?void 0:Sa.contents),(ll=m.compData)!=null&&ll.find(Fe=>(Fe==null?void 0:Fe.key)==="step")&&(m.step=(oa=(Te=m.compData)==null?void 0:Te.find(Fe=>(Fe==null?void 0:Fe.key)==="step"))==null?void 0:oa.contents),(Ka=m.compData)!=null&&Ka.find(Fe=>(Fe==null?void 0:Fe.key)==="choice")&&(m.choice=(_a=(pe=m.compData)==null?void 0:pe.find(Fe=>(Fe==null?void 0:Fe.key)==="choice"))==null?void 0:_a.contents),(Pa=m.compData)!=null&&Pa.find(Fe=>(Fe==null?void 0:Fe.key)==="hideContents")&&(m.isHidden=((Ol=(ul=m.compData)==null?void 0:ul.find(Fe=>(Fe==null?void 0:Fe.key)==="hideContents"))==null?void 0:Ol.contents)??!1)}return m});return n=await Promise.all(i),n=n==null?void 0:n.filter(o=>!(o!=null&&o.isHidden)),n};let df="http://139.196.154.85:20031";function pf(a){return Ja.axios({method:"post",url:df+"/api/word-report/build-by-upload",responseType:"blob",data:a})}const ff=M.useUnit(M.pinia),{selectTitle:ws}=M.storeToRefs(ff),hf=async a=>{var r;let l=(r=le.analyzerStringToArray(a,[":","@","="]))==null?void 0:r[0];return l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1),l=le.analyzeSplitToContent(l,","),l=l==null?void 0:l.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)),l=l==null?void 0:l.map(async n=>{var o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se;let i=le.analyzeSplitToContent(n,"=");if(n!=null&&n.includes("==")){i=n==null?void 0:n.split("==");let G=i==null?void 0:i[0],fe=i==null?void 0:i[1],we=(x=fe==null?void 0:fe.split("*"))==null?void 0:x[0],_e=(b=fe==null?void 0:fe.split("*"))==null?void 0:b[1];_e=(S=le.analyzeSplitToContent(_e,":"))==null?void 0:S.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===":"&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P));let qe=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])!=="{"),ra=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])==="{");if(ra=ra==null?void 0:ra[0],ra=ra==null?void 0:ra.slice(1,(ra==null?void 0:ra.length)-1),ra=(I=le.analyzeSplitToContent(ra,","))==null?void 0:I.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===","&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P)),we!=null&&we.includes("{")){let P=(re=(R=ws.value)==null?void 0:R.find(De=>(De==null?void 0:De.condition)==="child"))==null?void 0:re.value;we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(me=(X=we==null?void 0:we.replace("{",""))==null?void 0:X.replace("}",""))==null?void 0:me.replace(":","/"),we=we+"/"+P;let Ke=await Hr(we,!1);Ke=Ke==null?void 0:Ke.find(De=>(De==null?void 0:De.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1]));let Me=(U=(ue=Ke==null?void 0:Ke.compData)==null?void 0:ue.find(De=>(De==null?void 0:De.key)==="tableContents"))==null?void 0:U.contents,Le=(Z=(W=Ke==null?void 0:Ke.compData)==null?void 0:W.find(De=>(De==null?void 0:De.key)==="header"))==null?void 0:Z.contents,Ie=le.tableToForm(Me,Le),de=[];Ie==null||Ie.forEach(De=>{let Xe=[];ra==null||ra.forEach(Ea=>{var Ge;Xe.push(((Ge=De==null?void 0:De.find($=>($==null?void 0:$.key)===Ea))==null?void 0:Ge.value)??"")}),de.push(Xe)}),de=le.arrayToString(de),n=G+"=="+de}else{we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(ve=(ae=we==null?void 0:we.replace("{",""))==null?void 0:ae.replace("}",""))==null?void 0:ve.replace(":","/");let P=await Hr(we,!1);P=P==null?void 0:P.find(de=>(de==null?void 0:de.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1]));let Ke=(te=(ze=P==null?void 0:P.compData)==null?void 0:ze.find(de=>(de==null?void 0:de.key)==="tableContents"))==null?void 0:te.contents,Me=(se=(N=P==null?void 0:P.compData)==null?void 0:N.find(de=>(de==null?void 0:de.key)==="header"))==null?void 0:se.contents,Le=le.tableToForm(Ke,Me),Ie=[];Le==null||Le.forEach(de=>{let De=[];ra==null||ra.forEach(Xe=>{var Ea;De.push(((Ea=de==null?void 0:de.find(Ge=>(Ge==null?void 0:Ge.key)===Xe))==null?void 0:Ea.value)??"")}),Ie.push(De)}),Ie=le.arrayToString(Ie),n=G+"=="+Ie}}else{let G=i==null?void 0:i[0],fe=i==null?void 0:i[1],we=(o=fe==null?void 0:fe.split("*"))==null?void 0:o[0],_e=(p=fe==null?void 0:fe.split("*"))==null?void 0:p[1];_e=(c=le.analyzeSplitToContent(_e,":"))==null?void 0:c.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===":"&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P));let qe=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])!=="{"),ra=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])==="{");if(ra=ra==null?void 0:ra[0],ra=ra==null?void 0:ra.slice(1,(ra==null?void 0:ra.length)-1),ra=(u=le.analyzeSplitToContent(ra,":"))==null?void 0:u.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===":"&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P)),we!=null&&we.includes("{")){let P=(g=(m=ws.value)==null?void 0:m.find(Me=>(Me==null?void 0:Me.condition)==="child"))==null?void 0:g.value;we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(d=(y=we==null?void 0:we.replace("{",""))==null?void 0:y.replace("}",""))==null?void 0:d.replace(":","/"),we=we+"/"+P;let Ke=await Hr(we,!1);Ke=Ke==null?void 0:Ke.find(Me=>(Me==null?void 0:Me.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1])),Ke=(w=(D=Ke==null?void 0:Ke.compData)==null?void 0:D.find(Me=>(Me==null?void 0:Me.key)==="formContent"))==null?void 0:w.contents,Ke=(q=Ke==null?void 0:Ke.find(Me=>(Me==null?void 0:Me.prop)===(ra==null?void 0:ra[(ra==null?void 0:ra.length)-1])))==null?void 0:q.value,fe=Ke}else{we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(j=(A=we==null?void 0:we.replace("{",""))==null?void 0:A.replace("}",""))==null?void 0:j.replace(":","/");let P=await Hr(we,!1);P=P==null?void 0:P.find(Ke=>(Ke==null?void 0:Ke.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1])),P=(E=(O=P==null?void 0:P.compData)==null?void 0:O.find(Ke=>(Ke==null?void 0:Ke.key)==="formContent"))==null?void 0:E.contents,P=(_=P==null?void 0:P.find(Ke=>(Ke==null?void 0:Ke.prop)===(ra==null?void 0:ra[(ra==null?void 0:ra.length)-1])))==null?void 0:_.value,fe=P}n=G+fe}return n}),l=await Promise.all(l),l=l==null?void 0:l.join(","),l="{"+l+"}",l},vf=M.useLoginState(M.pinia),{loginUserInfo:Zn}=M.storeToRefs(vf),mf=M.useUnit(M.pinia),{selectTitle:wc}=M.storeToRefs(mf),Gi=M.useMenuState(M.pinia),{localFiles:kt}=M.storeToRefs(Gi),Vt=async(a=[],l="Manual",r=[],n=[])=>{var c;let i=a,o=(c=i==null?void 0:i.filter(u=>{var m;return(u==null?void 0:u.functionName)&&(l==="Manual"&&((m=u==null?void 0:u.calculatorFilter)==null?void 0:m.includes(l))||l!=="Manual")}))==null?void 0:c.map(u=>({prop:u==null?void 0:u.prop,label:u==null?void 0:u.label,methods:u==null?void 0:u.calculatorFilter,functionName:u==null?void 0:u.functionName,functionRelatedWords:u==null?void 0:u.functionRelatedWords}));(n==null?void 0:n.length)>0&&(o=[...n==null?void 0:n.map(m=>({prop:"",label:"",methods:m==null?void 0:m.calculatorFilter,functionName:m==null?void 0:m.functionName,functionRelatedWords:m==null?void 0:m.functionRelatedWords})),...o]),(n==null?void 0:n.length)>0&&(i=[i==null?void 0:i[0]]);let p=i==null?void 0:i.map(async u=>{let m=(n==null?void 0:n.length)>0?n:o==null?void 0:o.filter(g=>(g==null?void 0:g.prop)===(u==null?void 0:u.prop));return u=await No(u,m,i,l,i,r),u});return p=await Promise.all(p),p},Bt=async(a,l,r="Manual",n=[],i=[],o=[])=>{var g;let p=a,c;Array.isArray(l==null?void 0:l[0])?c=le.getColumnChild(l==null?void 0:l[0]):c=l;let u=(g=c==null?void 0:c.filter(y=>{var d;return(y==null?void 0:y.calculatorFilter)&&((d=y==null?void 0:y.calculatorFilter)==null?void 0:d.includes(r))||(y==null?void 0:y.calculatorFilter)===""&&(y==null?void 0:y.functionName)}))==null?void 0:g.map(y=>({prop:y==null?void 0:y.prop,label:y==null?void 0:y.label,methods:y==null?void 0:y.calculatorFilter,functionName:y==null?void 0:y.functionName,functionRelatedWords:y==null?void 0:y.functionRelatedWords}));(i==null?void 0:i.length)>0&&(u=[...i==null?void 0:i.map(d=>({prop:"",label:"",methods:d==null?void 0:d.calculatorFilter,functionName:d==null?void 0:d.functionName,functionRelatedWords:d==null?void 0:d.functionRelatedWords})),...u]),(i==null?void 0:i.length)>0&&(p=[p==null?void 0:p[0]]);let m=p==null?void 0:p.map(async y=>(y=await No(y,u,c,r,p,n,o),y));return m=await Promise.all(m),m},yf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o;return Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(p=>{var c;if(l!=null&&l[p]){let u=l==null?void 0:l[p];o=o?u?Fl.isEqual(u.toString(),o.toString()):void 0:u}else{let u=(c=i==null?void 0:i.find(g=>(g==null?void 0:g.label)===p))==null?void 0:c.prop,m=(l==null?void 0:l[u])??0;o=o?m?Fl.isEqual(m.toString(),o.toString()):void 0:m}}),l[n]=o===void 0?void 0:o?1:0,l},Rr=a=>{const[l,r,n]=M.cloneDeep(a).split(":").map(Number);let i=+a;return!a||!(a!=null&&a.includes(":"))?i:(l??0)*3600+(r??0)*60+(n??0)},ii=a=>{const l=o=>o.toString().padStart(2,"0"),r=Math.floor(a/3600),n=Math.floor(a%3600/60),i=a%60;return`${l(r)}:${l(n)}:${parseInt(l(i))}`},gf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q,A,j;if(l!=null&&l[u]){if(o==="Row")if(!((g=((m=l==null?void 0:l[u])==null?void 0:m.toString())??"")!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let O=+(l==null?void 0:l[u]);c=c+O}else c=Rr(c.toString())+Rr((d=l==null?void 0:l[u])==null?void 0:d.toString()),c=ii(c)}else if(o==="Row"){let O=(D=i==null?void 0:i.find(E=>(E==null?void 0:E.label)===u))==null?void 0:D.prop;if(!((q=Number.isNaN(l==null?void 0:l[O])?"":(w=l==null?void 0:l[O])==null?void 0:w.toString())!=null&&q.includes(":"))&&!((A=c==null?void 0:c.toString())!=null&&A.includes(":"))){let E=+((l==null?void 0:l[O])??0);c=c+E}else c=Rr(c==null?void 0:c.toString())+Rr((j=(l==null?void 0:l[O])??0)==null?void 0:j.toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y+d},0)}return l[n]=c,l},bf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q;if(l!=null&&l[u]){if(o==="Row")if(!((g=(m=l==null?void 0:l[u])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let A=+(l==null?void 0:l[u]);c=c===0?c+A:c-A}else c=c===0?Rr(c.toString())+Rr(l==null?void 0:l[u].toString()):Rr(c.toString())-Rr(l==null?void 0:l[u].toString()),c=ii(c)}else if(o==="Row"){let A=(d=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===u))==null?void 0:d.prop;if(!((w=Number.isNaN(l==null?void 0:l[A])?"":(D=l==null?void 0:l[A])==null?void 0:D.toString())!=null&&w.includes(":"))&&!((q=c==null?void 0:c.toString())!=null&&q.includes(":"))){let j=+((l==null?void 0:l[A])??0);c=c===0?c+j:c-j}else c=c===0?Rr(c.toString())+Rr(((l==null?void 0:l[A])??0).toString()):Rr(c.toString())-Rr(((l==null?void 0:l[A])??0).toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y-d},0)}return l[n]=c,l},kf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q;if(l!=null&&l[u]){if(o==="Row")if(!((g=(m=l==null?void 0:l[u])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let A=+(l==null?void 0:l[u]);c=c===0?c+A:c*A}else c=c===0?Rr(c.toString())+Rr(l==null?void 0:l[u].toString()):Rr(c.toString())*Rr(l==null?void 0:l[u].toString()),c=ii(c)}else if(o==="Row"){let A=(d=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===u))==null?void 0:d.prop;if(!(l!=null&&l[A]))c=void 0;else if(!((w=Number.isNaN(l==null?void 0:l[A])?"":(D=l==null?void 0:l[A])==null?void 0:D.toString())!=null&&w.includes(":"))&&!((q=c==null?void 0:c.toString())!=null&&q.includes(":"))){let j=+((l==null?void 0:l[A])??0);c=c===0?c+j:c*j}else c=c===0?Rr(c.toString())+Rr(((l==null?void 0:l[A])??0).toString()):Rr(c.toString())*Rr(((l==null?void 0:l[A])??0).toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y*d},0)}return l[n]=c,l},xf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q;if(l!=null&&l[u]){if(o==="Row")if(!((g=(m=l==null?void 0:l[u])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let A=+(l==null?void 0:l[u]);c=c===0?c+A:c/A}else c=c===0?Rr(c.toString())+Rr(l==null?void 0:l[u].toString()):Rr(c.toString())/Rr(l==null?void 0:l[u].toString()),c=ii(c)}else if(o==="Row"){let A=(d=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===u))==null?void 0:d.prop;if(!((w=Number.isNaN(l==null?void 0:l[A])?"":(D=l==null?void 0:l[A])==null?void 0:D.toString())!=null&&w.includes(":"))&&!((q=c==null?void 0:c.toString())!=null&&q.includes(":"))){let j=+((l==null?void 0:l[A])??0);c=c===0?c+j:c/j}else c=c===0?Rr(c.toString())+Rr(((l==null?void 0:l[A])??0).toString()):Rr(c.toString())/Rr(((l==null?void 0:l[A])??0).toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y/d},0)}return l[n]=c.toFixed(2),l},wf=async a=>{var o,p,c,u,m,g,y,d,D,w,q;let l=(o=a==null?void 0:a.valueString)==null?void 0:o[0],r=(p=a==null?void 0:a.contents)==null?void 0:p.calculatorFilter,n=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 A=(u=(c=l==null?void 0:l.split("*"))==null?void 0:c[0])==null?void 0:u.replaceAll(":","/"),j=await Hr(A,!1),O=(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)===O))==null?void 0:g[0],r!==""){let E=j.compData;E=E==null?void 0:E.filter(_=>(_==null?void 0:_.key)!=="filter"),E.push({key:"filter",contents:"("+r+")"}),E=await Vo(E,{}),n=(d=(y=E==null?void 0:E.find(_=>(_==null?void 0:_.key)==="tableContents"))==null?void 0:y.contents)==null?void 0:d.length}else n=(q=(w=(D=j==null?void 0:j.compData)==null?void 0:D.find(E=>(E==null?void 0:E.key)==="tableContents"))==null?void 0:w.contents)==null?void 0:q.length}return i.value=n,i},_f=async a=>{var y,d,D,w,q,A,j,O,E;let l=(y=a==null?void 0:a.valueString)==null?void 0:y[0],r=a==null?void 0:a.filter;r=(r==null?void 0:r.find(_=>_==null?void 0:_.includes("@If")))??"",(l==null?void 0:l[0])==="$"&&(l=l==null?void 0:l.slice(1,l==null?void 0:l.length));let n=(D=(d=l==null?void 0:l.split("*"))==null?void 0:d[0])==null?void 0:D.replaceAll(":","/"),i=(w=l==null?void 0:l.split("*"))==null?void 0:w[1],o=(q=i==null?void 0:i.split("{"))==null?void 0:q[0],p=i==null?void 0:i.replace(o,"");o=o==null?void 0:o.slice(0,(o==null?void 0:o.length)-1),o=o==null?void 0:o.split(":"),o=o==null?void 0:o[(o==null?void 0:o.length)-1];let c=await Hr(n,!1);if(p=p==null?void 0:p.slice(1,(p==null?void 0:p.length)-1),p=p==null?void 0:p.split(":"),p=p==null?void 0:p[(p==null?void 0:p.length)-1],c=c==null?void 0:c.find(_=>(_==null?void 0:_.name)===o),c=(j=(A=c==null?void 0:c.compData)==null?void 0:A.find(_=>(_==null?void 0:_.key)==="tableContents"))==null?void 0:j.contents,(r==null?void 0:r.length)>0){r=(E=(O=r==null?void 0:r.replace("(","$R"))==null?void 0:O.split("$R"))==null?void 0:E[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1);let _=le.calculatorAndToOr(r);_==null||_.forEach(x=>{for(let b in x)x[b]!=="!"?c=c==null?void 0:c.filter(S=>{var I;return(S==null?void 0:S[b])===(x==null?void 0:x[b])||(S==null?void 0:S[(I=Object.keys(S))==null?void 0:I.find(R=>R==null?void 0:R.includes("."+b))])===(x==null?void 0:x[b])}):c=c==null?void 0:c.filter(S=>{var I;return(S==null?void 0:S[b])!==(x==null?void 0:x[b])&&(S==null?void 0:S[(I=Object.keys(S))==null?void 0:I.find(R=>R==null?void 0:R.includes("."+b))])!==(x==null?void 0:x[b])})})}c=c==null?void 0:c.map(_=>_==null?void 0:_[p]);let u=[...new Set(c)],m=[],g={};return u==null||u.forEach(_=>{var b;let x=(b=c==null?void 0:c.filter(S=>_===S))==null?void 0:b.length;g[_]=x}),m.push(g),{xAxis:u,yAxis:m}},Sf=async a=>{var n,i;let l=a==null?void 0:a.valueString;l=l==null?void 0:l[0];let r={};if((l==null?void 0:l[0])==="{"){l=l==null?void 0:l.slice(1,l.length-1),l=(n=le.analyzeSplitToContent(l,","))==null?void 0:n.map(c=>((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)),c));let o=l==null?void 0:l.map(async c=>{var y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me;let u=(d=(y=c==null?void 0:c.replace("=","$R"))==null?void 0:y.split("$R"))==null?void 0:d[0],m=(w=(D=c==null?void 0:c.replace("=","$R"))==null?void 0:D.split("$R"))==null?void 0:w[1],g="";if(m==="LoginUser")g=((q=Zn.value)==null?void 0:q.姓名)||((A=Zn.value)==null?void 0:A.account)||((j=Zn.value)==null?void 0:j.账号);else if((m==null?void 0:m[0])==="$"){let ue=(O=m==null?void 0:m.split("*"))==null?void 0:O[0],U=(E=m==null?void 0:m.split("*"))==null?void 0:E[1],W=U;if((ue==null?void 0:ue[0])==="$"&&(ue=ue==null?void 0:ue.slice(1,ue==null?void 0:ue.length)),ue!=null&&ue.includes("$")){let ae=(_=ue==null?void 0:ue.split("$"))==null?void 0:_[0],ve=(x=ue==null?void 0:ue.split("$"))==null?void 0:x[1],ze=(b=ae==null?void 0:ae.split(":"))==null?void 0:b[0],te=(R=(I=(S=wc.value)==null?void 0:S.filter(N=>(N==null?void 0:N.condition)==="child"))==null?void 0:I[0])==null?void 0:R.value;ve=ve==null?void 0:ve.replaceAll(":","/"),ue=ze+"/"+ve+"/"+te}else ue=ue==null?void 0:ue.replaceAll(":","/");U=U==null?void 0:U.split(":"),U=U==null?void 0:U.find((ae,ve)=>ve===(U==null?void 0:U.length)-2),W=W==null?void 0:W.split(":"),W=W==null?void 0:W.find((ae,ve)=>ve===(W==null?void 0:W.length)-1),(W==null?void 0:W[0])==="{"&&(W=W==null?void 0:W.slice(1,(W==null?void 0:W.length)-1));let Z=await Hr(ue,!1);Z=Z==null?void 0:Z.find(ae=>(ae==null?void 0:ae.name)===U),Z=(X=(re=Z==null?void 0:Z.compData)==null?void 0:re.find(ae=>(ae==null?void 0:ae.key)==="tableContents"))==null?void 0:X.contents,g=(me=Z==null?void 0:Z[0])==null?void 0:me[W]}else g=m;r[u]=g});await Promise.all(o);let p=(i=a==null?void 0:a.valueString)==null?void 0:i[1];r.menuPathContent=p}return r},Ef=async a=>{var m,g,y,d,D,w,q,A,j,O,E;let l=a==null?void 0:a.valueString,r=l==null?void 0:l.filter(_=>(_==null?void 0:_.includes(".docx"))||(_==null?void 0:_.includes(".doc")));r=r==null?void 0:r[0];let n=l==null?void 0:l.filter(_=>!(_!=null&&_.includes(".docx"))&&!(_!=null&&_.includes(".doc")));n=n==null?void 0:n[0];let i=(g=a==null?void 0:a.compNames)==null?void 0:g[((m=a==null?void 0:a.compNames)==null?void 0:m.length)-1],o=((D=(d=(y=wc.value)==null?void 0:y.filter(_=>(_==null?void 0:_.condition)==="child"))==null?void 0:d[0])==null?void 0:D.value)??"",p=kt.value;o!==""&&(p=(w=p==null?void 0:p.find(_=>(_==null?void 0:_.path)===o))==null?void 0:w.children),p=(q=p==null?void 0:p.find(_=>(_==null?void 0:_.name)===i))==null?void 0:q.children;let c=p==null?void 0:p.find(_=>(_==null?void 0:_.name)===r),u=p==null?void 0:p.find(_=>(_==null?void 0:_.name)===n);if(u=(u==null?void 0:u.url)??"",u!=="")u=u==null?void 0:u.replace(/^file:\/\//,"file:///").replace(/\\/g,"/");else{let _=(j=(A=kt.value)==null?void 0:A.find(x=>(x==null?void 0:x.name)===n))==null?void 0:j.url;u=_==null?void 0:_.replace(/^file:\/\//,"file:///").replace(/\\/g,"/"),console.log(2323,u)}if(c=(c==null?void 0:c.url)??"",c!=="")c=c==null?void 0:c.replace(/^file:\/\//,"file:///").replace(/\\/g,"/");else{let _=(E=(O=kt.value)==null?void 0:O.find(x=>(x==null?void 0:x.name)===r))==null?void 0:E.url;c=_==null?void 0:_.replace(/^file:\/\//,"file:///").replace(/\\/g,"/"),console.log(2324,c)}try{const x=await(await fetch(c)).blob();let b=c.split(/[\\/]/).pop();const S=new File([x],b,{type:x.type||"application/octet-stream"}),I=new FormData;I.append("TemplateFile",S);let R=await fetch(u);R=await R.text(),R=await hf(R),I.append("RawContent",R);let re=await pf(I),X=new Blob([re.data],{type:"application/zip"});const me=window.URL.createObjectURL(X),ue=document.createElement("a");ue.href=me,ue.download=r,document.body.appendChild(ue),ue.click(),document.body.removeChild(ue),window.URL.revokeObjectURL(me)}catch{Ja.ElMessage.error("文件路径未找到")}},Cf=async a=>{var i,o;let l=a==null?void 0:a.valueString,r=l==null?void 0:l[0];r=(i=r==null?void 0:r.split("*"))==null?void 0:i[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.replaceAll(":","/"),r=r;let n=await Hr(r,!1);if((n==null?void 0:n.length)>0){Gi.setActiveTopMenuPath((o=r==null?void 0:r.split("/"))==null?void 0:o[0]);let p=localStorage.getItem("menus-store");p=JSON.parse(p),p=p==null?void 0:p.menus,p=p==null?void 0:p.find(c=>{var u;return(c==null?void 0:c.path)===((u=r==null?void 0:r.split("/"))==null?void 0:u[0])}),p=p==null?void 0:p.childMenus,Gi.setAsideMenus(p),Gi.setJumpMenuInform(!0),Gi.setActiveMenuPath(r)}else Ja.ElMessage.error("页面不存在");return a},mo={Sum:gf,Substract:bf,Multiple:kf,Divide:xf,Compare:yf,VecDimCount:wf,Approval:Sf,VecRepCount:_f,AutoReportGen:Ef,OpenPortal:Cf},No=async(a,l,r,n="Auto",i,o=[],p=[])=>{var y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W;let c=a,u=[],m=await M.getPageDataApi({platId:parseInt((y=Zn==null?void 0:Zn.value)==null?void 0:y.plat_id),pageName:"menu"});m=(w=(D=(d=m==null?void 0:m.data)==null?void 0:d.result)==null?void 0:D.filter(Z=>(Z==null?void 0:Z.property_name)===""))==null?void 0:w[0];let g=[];if(m!=null&&m.object_name){m=m==null?void 0:m.object_name;let Z=await M.getPageDataApi({platId:parseInt((q=Zn==null?void 0:Zn.value)==null?void 0:q.plat_id),pageName:m});Z=(_=(E=(O=(j=(A=Z==null?void 0:Z.data)==null?void 0:A.result)==null?void 0:j[0])==null?void 0:O.contents)==null?void 0:E.find(ae=>{var ve;return(ve=ae==null?void 0:ae.key)==null?void 0:ve.includes("content")}))==null?void 0:_.value,u=(x=Z==null?void 0:Z.map(ae=>({functionName:ae==null?void 0:ae.函数名称,functionContent:ae==null?void 0:ae.输出值})))==null?void 0:x.filter(ae=>(ae==null?void 0:ae.functionContent)!==""),u==null||u.forEach(ae=>{g.push(ae.functionName),mo[ae.functionName]=new Function("return "+ae.functionContent)()})}if((l==null?void 0:l.length)===0)return c;for(let Z in l){let ae=(b=l==null?void 0:l[Z])==null?void 0:b.functionName;const ve=mo==null?void 0:mo[ae];let ze=(S=l==null?void 0:l[Z])==null?void 0:S.methods;if(ze=le.analyzeSplitToContent(ze,","),(I=ze==null?void 0:ze.find(te=>te==null?void 0:te.includes("@Type")))!=null&&I.includes(n)||!(ze!=null&&ze.find(te=>te==null?void 0:te.includes("@Type")))&&n==="Manual"||n==="Auto"||(ze==null?void 0:ze.length)===0){let te=((X=(re=(R=ze==null?void 0:ze.find(N=>N==null?void 0:N.includes("@Extent")))==null?void 0:R.replace(":","="))==null?void 0:re.split("="))==null?void 0:X[1])??[];if(await new Function("return ")(),(g==null?void 0:g.length)>0&&g.find(N=>N===ae)){let N="";try{let G=(me=l==null?void 0:l[Z])==null?void 0:me.functionRelatedWords,fe=(o==null?void 0:o.length)>0?o==null?void 0:o.map(_e=>{var qe;return _e==null?void 0:_e[(qe=l==null?void 0:l[Z])==null?void 0:qe.prop]}):["0"];fe=fe==null?void 0:fe.map(_e=>_e==null?void 0:_e.slice((_e==null?void 0:_e.length)-5,_e==null?void 0:_e.length)),fe=fe==null?void 0:fe.map(_e=>le.isNumber(parseInt(_e))&&parseInt(_e)?parseInt(_e):0);let we=Math.max(...fe);G=G==null?void 0:G.map(_e=>{if(_e!=null&&_e.includes("'"))return _e==null?void 0:_e.replaceAll("'","");if(_e!=null&&_e.includes("@"))return we+1;{let qe=Object.keys(c);return _e=(c==null?void 0:c[_e])??(c==null?void 0:c[qe==null?void 0:qe.find(ra=>ra==null?void 0:ra.includes("."+_e))]),_e}}),N=ve(...G)}catch(G){Ja.ElMessage.warning("关联数据出现错误,"+G.message)}let se=(ue=l==null?void 0:l[Z])==null?void 0:ue.prop;c[se]=N}else c=await ve({contents:c,valueString:(U=l==null?void 0:l[Z])==null?void 0:U.functionRelatedWords,prop:(W=l==null?void 0:l[Z])==null?void 0:W.prop,filter:ze,headers:r,typeString:te,allContents:i,compNames:p})}}return c},Df=M.useLoginState(M.pinia),{loginUserInfo:wn}=M.storeToRefs(Df),Tf=M.useMenuState(M.pinia),{activeMenuPath:_s,currentMenuPath:yo}=M.storeToRefs(Tf),_c=M.useUnit(M.pinia);let Ss="$R";const{selectTitle:Ii}=M.storeToRefs(_c),Sc=async(a,l)=>{var p,c,u,m,g,y,d,D,w,q,A,j,O;let r=_s.value,n="",i=((p=Ii==null?void 0:Ii.value)==null?void 0:p.find(E=>(E==null?void 0:E.condition)==="child"&&!(E!=null&&E.relatedContent)))??void 0;(a==null?void 0:a.length)===0||(r=l?r:(c=a==null?void 0:a[0])==null?void 0:c.object_name,n=(u=a==null?void 0:a[0])==null?void 0:u.father_name);let o=[];if(n!==""){let E=n;(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 _=await Hr(E,!1);_=(m=_==null?void 0:_[0])==null?void 0:m.compData;let x=(g=_==null?void 0:_.find(S=>(S==null?void 0:S.key)==="header"))==null?void 0:g.contents;x=((y=x==null?void 0:x.find(S=>S==null?void 0:S.isMainKey))==null?void 0:y.prop)??((d=x==null?void 0:x[0])==null?void 0:d.prop);let b=(w=(D=_==null?void 0:_.find(S=>(S==null?void 0:S.key)==="tableContents"))==null?void 0:D.contents)==null?void 0:w.map(S=>({label:S==null?void 0:S[x],value:S==null?void 0:S[x]}));o=(q=n==null?void 0:n.split("/"))==null?void 0:q.map(S=>(S===""?i?(i.isShow=!0,S=i):S={value:S,condition:"child",options:b,parentContent:(n==null?void 0:n[(n==null?void 0:n.length)-1])==="/"?n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1):n,isShow:!0}:S={condition:"parent",value:S.trim(),isShow:!0},S))}if(r!==""){let E=(A=r==null?void 0:r.split("/"))==null?void 0:A.map(_=>(_={condition:"normal",value:_.trim(),isShow:!0},_));((j=E==null?void 0:E[0])==null?void 0:j.value)===((O=o==null?void 0:o[0])==null?void 0:O.value)&&(E=E==null?void 0:E.filter((_,x)=>x!==0)),o=[...o??[],...E??[]]}n===""&&i&&((i==null?void 0:i.parentContent)!==_s.value&&(i.isShow=!1),(i==null?void 0:i.value)!==""&&o.push(i)),_c.setSelectTitle(o)},Bf=async a=>{var o,p,c,u,m,g,y,d,D;let l=await M.getPageDataApi({platId:parseInt((o=wn==null?void 0:wn.value)==null?void 0:o.plat_id),pageName:"menu"}),r=(p=l==null?void 0:l.data)==null?void 0:p.result,n=(g=(m=(u=(c=a==null?void 0:a.filter(w=>(w==null?void 0:w.comp)==="Table"))==null?void 0:c[0])==null?void 0:u.compData)==null?void 0:m.find(w=>(w==null?void 0:w.key)==="filter"))==null?void 0:g.contents;n=(D=(d=(y=n==null?void 0:n.replace("(",Ss))==null?void 0:y.split(Ss))==null?void 0:d[0])==null?void 0:D.replaceAll(":","/");let i=r==null?void 0:r.filter(w=>{var q;return(w==null?void 0:w.object_name)===yo.value+"/"||((q=yo.value)==null?void 0:q.includes(n))&&n+"/"===(w==null?void 0:w.object_name)||n===(w==null?void 0:w.object_name)});return(i==null?void 0:i.length)>0&&(a=a==null?void 0:a.map(w=>{var q;return(w==null?void 0:w.comp)==="Table"&&(w.compData=(q=w==null?void 0:w.compData)==null?void 0:q.map(A=>{var j,O,E;return(A==null?void 0:A.key)==="header"&&(Array.isArray((j=A.contents)==null?void 0:j[0])?A.contents[0]=(E=A.contents[0])==null?void 0:E.map((_,x)=>{var b;return x===0&&(_.isExistChild=!0,((b=yo.value)!=null&&b.includes(n)||n)&&(_.fatherPath=n)),_}):A.contents=(O=A.contents)==null?void 0:O.map((_,x)=>{var b;return x===0&&(_.isExistChild=!0,((b=yo.value)!=null&&b.includes(n)||n)&&(_.fatherPath=n)),_})),A})),w})),a},Hr=async(a,l,r={})=>{var p,c,u,m,g,y,d,D,w,q,A,j;let n=await M.getPageDataApi({platId:parseInt((p=wn==null?void 0:wn.value)==null?void 0:p.plat_id),pageName:a}),i=(c=n==null?void 0:n.data)==null?void 0:c.result;if((i==null?void 0:i.length)===0&&(r!=null&&r.originPath)&&(r==null?void 0:r.originPath)!==a){let O=await M.getPageDataApi({platId:parseInt((u=wn==null?void 0:wn.value)==null?void 0:u.plat_id),pageName:r==null?void 0:r.originPath});if(((g=(m=O==null?void 0:O.data)==null?void 0:m.result)==null?void 0:g.length)>0){let E=await xs((y=O==null?void 0:O.data)==null?void 0:y.result,r,!1);E=E==null?void 0:E.map(async b=>{var R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge;let S=[],I=(R=Object.keys(b))==null?void 0:R.filter($=>($==null?void 0:$.includes("name"))&&$!=="nameContents");for(let $ in b)I!=null&&I.find(V=>V===$)&&S.push(b==null?void 0:b[$]);if(S=S.reverse(),(b==null?void 0:b.comp)==="Table"){let $=(me=(X=(re=b==null?void 0:b.compData)==null?void 0:re.find(ee=>(ee==null?void 0:ee.key)==="tableContents"))==null?void 0:X.contents)==null?void 0:me.map(ee=>{let ce={};for(let he in ee)he!=="id"&&he!=="create_time"&&he!=="update_time"&&he!=="sort"&&he!=="create_user_id"&&he!=="update_user_id"&&he!=="department_id"&&he!=="relatedId"&&(ce[he]=ee==null?void 0:ee[he]);return ee=Object.values(ce),ee}),V=(U=(ue=b==null?void 0:b.compData)==null?void 0:ue.find(ee=>(ee==null?void 0:ee.key)==="header"))==null?void 0:U.contents;if(Array.isArray(V==null?void 0:V[0])?(V[0].push({label:"排序",prop:"sort"}),V[0].push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(W=V[0])!=null&&W.find(ee=>(ee==null?void 0:ee.prop)==="disabled")&&(V[0]=(Z=V[0])==null?void 0:Z.filter(ee=>(ee==null?void 0:ee.prop)!=="disabled"),V[0].unshift({label:"",prop:"disabled",sortable:!1}))):(V||(V=[]),V.push({label:"排序",prop:"sort"}),V.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),V!=null&&V.find(ee=>(ee==null?void 0:ee.prop)==="disabled")&&(V=V==null?void 0:V.filter(ee=>(ee==null?void 0:ee.prop)!=="disabled"),V.unshift({label:"",prop:"disabled",sortable:!1}))),V!=null&&V.some(ee=>{var ce;return(ee==null?void 0:ee.calculatorFilter)&&((ce=ee==null?void 0:ee.calculatorFilter)==null?void 0:ce.includes("Auto"))})&&($=await Bt($,V,"Auto"),$=$==null?void 0:$.map(ee=>Object.values(ee))),b!=null&&b.fatherSyncContents){Array.isArray((ae=b==null?void 0:b.fatherSyncContents)==null?void 0:ae[0])&&(b.fatherSyncContents=(ve=b==null?void 0:b.fatherSyncContents)==null?void 0:ve[0]);let ee=(ze=Ii.value)==null?void 0:ze.find(ce=>(ce==null?void 0:ce.condition)==="child");b.fatherSyncContents=(te=b==null?void 0:b.fatherSyncContents)==null?void 0:te.map(ce=>{var he,pa,ia,Ve,ya,Ca;return((pa=ce==null?void 0:ce.menus)==null?void 0:pa[((he=ce==null?void 0:ce.menus)==null?void 0:he.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"!==(ce==null?void 0:ce.menus)?ce.menus=(ce==null?void 0:ce.menus)+(ee==null?void 0:ee.value):((Ve=ce==null?void 0:ce.menus)==null?void 0:Ve[((ia=ce==null?void 0:ce.menus)==null?void 0:ia.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"===(ce==null?void 0:ce.menus)&&(ce.menus=(Ca=ce.menus)==null?void 0:Ca.slice(0,((ya=ce.menus)==null?void 0:ya.length)-1)),ce})}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 ee=(G=Ii.value)==null?void 0:G.find(ce=>(ce==null?void 0:ce.condition)==="child");b.sonSyncContents=(fe=b==null?void 0:b.sonSyncContents)==null?void 0:fe.map(ce=>{var he,pa,ia,Ve,ya,Ca;return((pa=ce==null?void 0:ce.menus)==null?void 0:pa[((he=ce==null?void 0:ce.menus)==null?void 0:he.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"!==(ce==null?void 0:ce.menus)?ce.menus=(ce==null?void 0:ce.menus)+(ee==null?void 0:ee.value):((Ve=ce==null?void 0:ce.menus)==null?void 0:Ve[((ia=ce==null?void 0:ce.menus)==null?void 0:ia.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"===(ce==null?void 0:ce.menus)&&(ce.menus=(Ca=ce.menus)==null?void 0:Ca.slice(0,((ya=ce.menus)==null?void 0:ya.length)-1)),ce})}if(b!=null&&b.relatedQuotes){Array.isArray((we=b==null?void 0:b.relatedQuotes)==null?void 0:we[0])&&(b.relatedQuotes=(_e=b==null?void 0:b.relatedQuotes)==null?void 0:_e[0]);let ee=(qe=Ii.value)==null?void 0:qe.find(ce=>(ce==null?void 0:ce.condition)==="child");b.relatedQuotes=(ra=b==null?void 0:b.relatedQuotes)==null?void 0:ra.map(ce=>{var he,pa,ia,Ve,ya,Ca;return((pa=ce==null?void 0:ce.menus)==null?void 0:pa[((he=ce==null?void 0:ce.menus)==null?void 0:he.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"!==(ce==null?void 0:ce.menus)?ce.menus=(ce==null?void 0:ce.menus)+(ee==null?void 0:ee.value):((Ve=ce==null?void 0:ce.menus)==null?void 0:Ve[((ia=ce==null?void 0:ce.menus)==null?void 0:ia.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"===(ce==null?void 0:ce.menus)&&(ce.menus=(Ca=ce.menus)==null?void 0:Ca.slice(0,((ya=ce.menus)==null?void 0:ya.length)-1)),ce})}b={filter:(Ke=(P=b==null?void 0:b.compData)==null?void 0:P.find(ee=>(ee==null?void 0:ee.key)==="filter"))==null?void 0:Ke.contents,key:b==null?void 0:b.comp,name:S,tableColumns:V,tableContents:$,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,calculatorFilters:b==null?void 0:b.calculatorFilters}}else{let $=(Ie=(Le=(Me=b==null?void 0:b.compData)==null?void 0:Me.find(ee=>(ee==null?void 0:ee.key)==="formContent"))==null?void 0:Le.contents)==null?void 0:Ie.map(ee=>(ee==null?void 0:ee.value)??"");$=[$];let V=(Xe=(De=(de=b==null?void 0:b.compData)==null?void 0:de.find(ee=>(ee==null?void 0:ee.key)==="formContent"))==null?void 0:De.contents)==null?void 0:Xe.map(ee=>(ee.value="",ee));b={contents:$,filter:(Ge=(Ea=b==null?void 0:b.compData)==null?void 0:Ea.find(ee=>(ee==null?void 0:ee.key)==="filter"))==null?void 0:Ge.contents,key:b==null?void 0:b.comp,name:S,value:V,fatherSyncContents:b==null?void 0:b.fatherSyncContents,relatedQuotes:b==null?void 0:b.relatedQuotes,sonSyncContents:b==null?void 0:b.sonSyncContents,calculatorFilters:b==null?void 0:b.calculatorFilters}}return b.isShow=!1,b}),E=await Promise.all(E);let _=[{key:"menuPath",contents:[{path:a,fatherPath:(w=(D=(d=O==null?void 0:O.data)==null?void 0:d.result)==null?void 0:D[0])==null?void 0:w.father_name,isShow:!1}]},{key:a,contents:E}];await M.createPlatFormDataApi({platId:parseInt((q=wn==null?void 0:wn.value)==null?void 0:q.plat_id),changeData:_});let x=await M.getPageDataApi({platId:parseInt((A=wn==null?void 0:wn.value)==null?void 0:A.plat_id),pageName:a});i=(j=x==null?void 0:x.data)==null?void 0:j.result}}l&&await Sc(i,!!(r!=null&&r.originPath));let o=await xs(i,r);return l&&(o=await Bf(o)),o==null?void 0:o.filter(O=>O)},Es=async a=>{var n,i,o,p,c,u,m,g,y,d,D;let l=(n=a==null?void 0:a.menus)==null?void 0:n.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+((o=(i=a.value)==null?void 0:i.split(" "))==null?void 0:o[0]));let r=await Hr(l,!1);if(r=(p=r==null?void 0:r.filter(w=>{var q,A;return(w==null?void 0:w.name)===((A=a==null?void 0:a.groups)==null?void 0:A[((q=a==null?void 0:a.groups)==null?void 0:q.length)-1])}))==null?void 0:p[0],(u=(c=r==null?void 0:r.compData)==null?void 0:c.find(w=>(w==null?void 0:w.key)==="tableContents"))!=null&&u.contents){r=(g=(m=r==null?void 0:r.compData)==null?void 0:m.find(q=>(q==null?void 0:q.key)==="tableContents"))==null?void 0:g.contents;let w=((y=a==null?void 0:a.words)==null?void 0:y[0])??(a==null?void 0:a.prop);return r=r==null?void 0:r.filter(q=>{var A,j,O,E;return(q==null?void 0:q[a!=null&&a.endChildMenu?w:(A=a==null?void 0:a.words)==null?void 0:A[0]])===(a!=null&&a.relatedWords&&((j=a==null?void 0:a.relatedWords)==null?void 0:j.length)>0?(E=(O=a.value)==null?void 0:O.split(" "))==null?void 0:E[0]:a.value)}),r==null?void 0:r[0]}else{let w=(D=(d=r==null?void 0:r.compData)==null?void 0:d.find(A=>(A==null?void 0:A.key)==="formContent"))==null?void 0:D.contents,q={};return w==null||w.forEach(A=>{q[A.prop]=A.value}),q}},Nf={key:0,class:"extra-button-content"},Af={class:"table-operator-wrap"},zf={key:0,class:"extra-button-filter"},Mf={key:1,class:"extra-header"},If=["onClick"],Of={class:"table-op-text"},Lf={class:"table-op-text"},Rf={class:"drop-menu",style:{width:"120px"}},$f=["onClick"],Vf={key:0},Ff={key:1},Pf=["onClick"],jf={class:"table-op-text"},Hf={key:1,class:"extra-button-content tabs-button-wrapper"},Uf={class:"table-operator-wrap"},qf={class:"extra-button-filter"},Wf={key:0,class:"extra-header"},Gf={class:"table-op-action"},Kf={class:"table-op-text"},Yf={class:"drop-menu",style:{width:"120px"}},Jf={key:0},Xf={key:1},Zf=["onClick"],Qf={class:"table-op-text"},e0={__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 r=l,n=a,i=()=>{const I=(n==null?void 0:n.menuFilter)||[];return Array.isArray(I)&&(I==null?void 0:I.some(R=>{const re=typeof R=="string"?R:JSON.stringify(R);return re==null?void 0:re.includes("HideGroup=Yes")}))},o=e.ref(""),p=e.ref(!1),c=e.ref(!1),u=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 y(I,R){return I.map(re=>{const X={...re};return R.forEach(me=>{delete X[me]}),X})}function d(I){if(!I||I.t!=="n")return(I==null?void 0:I.v)??"";const R=I.v;if(I.z){const re=String(I.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 U of X)if(re.includes(U))return D(R);const me=/[ymdhms]/.test(re),ue=/^[0#\.\,\s]+$/.test(re.replace(/[\\\/\-:]/g,""));if(me&&!ue)return D(R)}if(R>=1&&R<=73050){if(R<5e3)return R;if(R>=5e3&&R<4e4){const re=Math.floor((R-25569)/365.25)+1970;return re>=1970&&re<=2e3&&I.z&&/[ymd]/.test(String(I.z).toLowerCase())?D(R):R}if(R>=4e4)return D(R)}return R}function D(I){if(typeof I!="number")return I;try{const R=new Date((I-25569)*86400*1e3);if(isNaN(R.getTime()))return I;const re=R.getFullYear(),X=String(R.getMonth()+1).padStart(2,"0"),me=String(R.getDate()).padStart(2,"0");return`${re}-${X}-${me}`}catch{return I}}const w=I=>{const R=I.raw;if(!R)return;const re=new FileReader;re.onload=X=>{try{const me=new Uint8Array(X.target.result),ue=le.readSync(me,{type:"array"}),U=ue.SheetNames[0],W=ue.Sheets[U],ae=le.utils.decode_range(W["!ref"]).e.c+1,ve=new Array(ae).fill(""),ze=[];for(const fe in W){if(fe[0]==="!")continue;const{r:we,c:_e}=le.utils.decode_cell(fe),qe=W[fe];let ra=d(qe);if((ra==null||ra==="")&&(ra=""),we===0)ve[_e]=ra;else{if(!ze[we-1]){ze[we-1]={};for(let P=0;P<ae;P++)ze[we-1][`col_${P}`]=""}ze[we-1][`col_${_e}`]=ra}}for(let fe=0;fe<ae;fe++)ve[fe]===void 0&&(ve[fe]="");const te=[];for(let fe=0;fe<ve.length;fe++)(!ve[fe]||ve[fe].toString().trim()==="")&&te.push(fe);let N,se;(te==null?void 0:te.length)>0?(Ja.ElMessage.warning("存在键为空的列,已自动过滤,请检查补充"),N=ve.filter((fe,we)=>!te.includes(we)),se=y(ze,te==null?void 0:te.map(fe=>`col_${fe}`))):(N=ve,se=ze);const G=ze==null?void 0:ze[0];if(!(G!=null&&G.hasOwnProperty("col_0")))return Ja.ElMessage.error("导入的数据列不匹配,请检查是否错位");r("getImportData",N,se)}catch(me){throw Ja.ElMessage.error(me.message),new Error(me.message)}},re.readAsArrayBuffer(R)},q=I=>{var re;const R=(re=u.value)==null?void 0:re.reduce((X,me,ue)=>(ue===0?X[me.label]=I:X[me.label]=me==null?void 0:me.value,X),{});r("filter",R,I,!0)},A=(I,R={})=>{r("buttonClick",I,"",R)},j=I=>{var R,re;u.value=(re=(R=le.getColumnChild(M.cloneDeep(I)))==null?void 0:R.filter(X=>(X==null?void 0:X.label)!==""&&(X==null?void 0:X.label)!=="操作"))==null?void 0:re.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:3,prop:(X==null?void 0:X.prop)??""}))},O=e.ref(!1),E=I=>{var R;if((I==null?void 0:I.buttonName)==="确认"&&(r("filter",I==null?void 0:I.content),O.value=(I==null?void 0:I.content)&&Object.values(I==null?void 0:I.content).length>0),(I==null?void 0:I.buttonName)==="清空"){const re=M.cloneDeep(I==null?void 0:I.content);for(const X in re)re[X]="";u.value=(R=u.value)==null?void 0:R.map(X=>({...X,value:""})),r("filter",re),O.value=!1}p.value=!1},_=()=>{p.value=!p.value,c.value=!0},x=()=>{var R,re;u.value=(R=u.value)==null?void 0:R.map(X=>({...X,value:""}));const I=(re=u.value)==null?void 0:re.reduce((X,me)=>(X[me.label]=me.value,X),{});r("filter",I)},b=e.ref(null);let S;return S=I=>{var me;if(!p.value)return;const R=(me=b==null?void 0:b.value)==null?void 0:me.$el,re=R==null?void 0:R.contains(I.target);let X=!1;document.querySelectorAll(".el-popover, .el-popper").forEach(ue=>{ue.contains(I.target)&&(X=!0)}),!re&&!X&&(p.value=!1)},e.onMounted(()=>{document.addEventListener("click",S),j(n.columns)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",S)}),e.watch(()=>n.columns,()=>{j(n.columns)},{deep:!0,immediate:!0}),(I,R)=>{var W,Z,ae,ve,ze,te,N,se;const re=e.resolveComponent("el-icon"),X=e.resolveComponent("svg-icon"),me=e.resolveComponent("el-input"),ue=e.resolveComponent("el-upload"),U=e.resolveComponent("el-button");return a.pageLayout==="vertical"?(e.openBlock(),e.createElementBlock("div",Nf,[i()?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(a.compName?"table-name-wrap":""),style:e.normalizeStyle({background:(n==null?void 0:n.level)>1?"transparent":"var(--ssgroup-background)",paddingLeft:((n==null?void 0:n.level)-1)*12+"px",fontWeight:600-((n==null?void 0:n.level)-1)*100>=400?600-((n==null?void 0:n.level)-1)*100:400,fontSize:17-(n==null?void 0:n.level)>=14?17-(n==null?void 0:n.level)+"px":"14px"})},e.toDisplayString(a.compName),7)),e.createElementVNode("div",Af,[n!=null&&n.filterShow?(e.openBlock(),e.createElementBlock("div",zf,[e.createVNode(od,{trigger:"contextmenu",ref_key:"popOverRef",ref:b,title:"",width:800,placement:"bottom-start",isVisible:p.value,"onUpdate:isVisible":R[4]||(R[4]=G=>p.value=G)},{reference:e.withCtx(()=>{var G,fe,we,_e;return[e.createVNode(me,{modelValue:o.value,"onUpdate:modelValue":R[0]||(R[0]=qe=>o.value=qe),style:{"min-width":"80px"},placeholder:O.value?(we=(fe=(G=a.filterValues)==null?void 0:G.filter(qe=>qe))==null?void 0:fe.slice(0,3))==null?void 0:we.join("/"):"搜索","prefix-icon":e.unref(Ja.search_default),clearable:"",onInput:q,disabled:((_e=u.value)==null?void 0:_e.length)===0},{suffix:e.withCtx(()=>{var qe,ra;return[!o.value&&((ra=(qe=a.filterValues)==null?void 0:qe.filter(P=>P))!=null&&ra.join("/"))?(e.openBlock(),e.createBlock(re,{key:0,style:{cursor:"pointer"},onClick:x},{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(_,["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:R[1]||(R[1]=e.withModifiers(()=>{},["stop"])),onKeyup:R[2]||(R[2]=e.withModifiers(()=>{},["stop"])),onKeypress:R[3]||(R[3]=e.withModifiers(()=>{},["stop"]))},[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,buttonValue:m.value,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&&((W=a.buttons)==null?void 0:W.length)>0?(e.openBlock(),e.createElementBlock("div",Mf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Z=a.buttons)==null?void 0:Z.filter(G=>a.isDevMode||(G==null?void 0:G.label)!=="修改模板"),(G,fe)=>{var we;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:fe},[(G==null?void 0:G.type)==="upload"?(e.openBlock(),e.createBlock(ue,{key:0,class:"upload-button-wrap","on-change":w,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1,disabled:!!a.lockingPage},{default:e.withCtx(()=>{var _e;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:qe=>A(G==null?void 0:G.label)},[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"]),e.createElementVNode("span",Of,e.toDisplayString(G==null?void 0:G.label),1)],10,If)]}),_:2},1032,["disabled"])):e.createCommentVNode("",!0),(G==null?void 0:G.type)==="popover"?(e.openBlock(),e.createBlock(pl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>{var _e;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}])},[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"]),e.createElementVNode("span",Lf,e.toDisplayString(G==null?void 0:G.label),1)],2)]}),dropMenu:e.withCtx(()=>[e.createElementVNode("div",Rf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G==null?void 0:G.contents,_e=>{var qe,ra;return e.openBlock(),e.createElementBlock("div",{key:_e==null?void 0:_e.label,class:e.normalizeClass(["table-op-drop-item",{"is-disabled":!!a.lockingPage}]),onClick:P=>!a.lockingPage&&A(_e==null?void 0:_e.label)},[e.createTextVNode(e.toDisplayString(_e==null?void 0:_e.label),1),(qe=_e==null?void 0:_e.label)!=null&&qe.includes("选中")?(e.openBlock(),e.createElementBlock("span",Vf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(ra=_e==null?void 0:_e.label)!=null&&ra.includes("全部")?(e.openBlock(),e.createElementBlock("span",Ff,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)],10,$f)}),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(G!=null&&G.type)||(G==null?void 0:G.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,id:"themeButton",class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:_e=>!a.lockingPage&&A(G==null?void 0:G.label,G)},[e.createVNode(X,{class:"table-op-icon",name:((we=g==null?void 0:g.find(_e=>(_e==null?void 0:_e.label)===(G==null?void 0:G.label)))==null?void 0:we.icon)??"normal"},null,8,["name"]),e.createElementVNode("span",jf,e.toDisplayString(G==null?void 0:G.label),1)],10,Pf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createElementBlock("div",Hf,[e.createElementVNode("div",Uf,[e.createElementVNode("div",qf,[e.createVNode(me,{modelValue:o.value,"onUpdate:modelValue":R[5]||(R[5]=G=>o.value=G),style:{"min-width":"80px"},placeholder:O.value?(ze=(ve=(ae=a.filterValues)==null?void 0:ae.filter(G=>G))==null?void 0:ve.slice(0,3))==null?void 0:ze.join("/"):"搜索","prefix-icon":e.unref(Ja.search_default),clearable:"",onInput:q,disabled:((te=u.value)==null?void 0:te.length)===0},{suffix:e.withCtx(()=>{var G,fe;return[!o.value&&((fe=(G=a.filterValues)==null?void 0:G.filter(we=>we))!=null&&fe.join("/"))?(e.openBlock(),e.createBlock(re,{key:0,style:{cursor:"pointer"},onClick:x},{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(_,["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",Wf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((se=a.buttons)==null?void 0:se.filter(G=>a.isDevMode||(G==null?void 0:G.label)!=="修改模板"),(G,fe)=>{var we;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:fe},[(G==null?void 0:G.type)==="upload"?(e.openBlock(),e.createBlock(ue,{key:0,class:"upload-button-wrap","on-change":w,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1},{default:e.withCtx(()=>{var _e;return[e.createElementVNode("div",Gf,[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"]),e.createElementVNode("span",Kf,e.toDisplayString(G==null?void 0:G.label),1)])]}),_:2},1024)):e.createCommentVNode("",!0),(G==null?void 0:G.type)==="popover"?(e.openBlock(),e.createBlock(pl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>[(G==null?void 0:G.type)==="popover"?(e.openBlock(),e.createBlock(U,{key:0,style:{background:"transparent",color:"#000000"}},{icon:e.withCtx(()=>{var _e;return[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"])]}),default:e.withCtx(()=>[e.createTextVNode(" "+e.toDisplayString(G==null?void 0:G.label),1)]),_:2},1024)):e.createCommentVNode("",!0)]),dropMenu:e.withCtx(()=>[e.createElementVNode("div",Yf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G==null?void 0:G.contents,_e=>(e.openBlock(),e.createBlock(U,{key:_e==null?void 0:_e.label,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:qe=>A(_e==null?void 0:_e.label)},{default:e.withCtx(()=>{var qe,ra;return[e.createTextVNode(e.toDisplayString(_e==null?void 0:_e.label),1),(qe=_e==null?void 0:_e.label)!=null&&qe.includes("选中")?(e.openBlock(),e.createElementBlock("span",Jf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(ra=_e==null?void 0:_e.label)!=null&&ra.includes("全部")?(e.openBlock(),e.createElementBlock("span",Xf,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)]}),_:2},1032,["onClick"]))),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(G!=null&&G.type)||(G==null?void 0:G.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),id:"themeButton",onClick:_e=>!a.lockingPage&&A(G==null?void 0:G.label,G)},[e.createVNode(X,{class:"table-op-icon",name:(we=g==null?void 0:g.find(_e=>(_e==null?void 0:_e.label)===(G==null?void 0:G.label)))==null?void 0:we.icon},null,8,["name"]),e.createElementVNode("span",Qf,e.toDisplayString(G==null?void 0:G.label),1)],10,Zf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])]))}}},a0=pr._export_sfc(e0,[["__scopeId","data-v-c54c7b35"]]),l0={__name:"index",props:{columns:Array,tableData:Array},setup(a){return(l,r)=>{const n=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,o=>{var p;return e.openBlock(),e.createBlock(n,{key:o==null?void 0:o.prop,label:o==null?void 0:o.label,prop:o==null?void 0:o.prop,fixed:(o==null?void 0:o.prop)==="operate"?"right":o==null?void 0:o.fixed,align:(o==null?void 0:o.align)??"left","show-overflow-tooltip":(o==null?void 0:o.showOverflowTooltip)??!0,width:o==null?void 0:o.width,"min-width":(o==null?void 0:o.minWidth)||((o==null?void 0:o.prop)==="operate"?80:(((p=o==null?void 0:o.label)==null?void 0:p.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(o.children,(u,m)=>(e.openBlock(),e.createBlock(pl._sfc_main$2,{key:m,column:u,tableData:a.tableData},e.createSlots({_:2},[e.renderList(l.$slots,(g,y)=>({name:y,fn:e.withCtx(({row:d,slotData:D,item:w,column:q})=>[e.renderSlot(l.$slots,y,e.mergeProps({ref_for:!0},D??d,{item:w??u,slotData:D??d,row:d,column:q,columnProp:u}))])}))]),1032,["column","tableData"]))),128))]),_:2},1032,["label","prop","fixed","align","show-overflow-tooltip","width","min-width"])}),128))]),_:3},8,["data"])}}};class r0 extends Fl.Loader{constructor(l){super(l),this.littleEndian=!0}load(l,r,n,i){const o=this,p=new Fl.FileLoader(o.manager);p.setPath(o.path),p.setResponseType("arraybuffer"),p.setRequestHeader(o.requestHeader),p.setWithCredentials(o.withCredentials),p.load(l,function(c){try{r(o.parse(c))}catch(u){i?i(u):console.error(u),o.manager.itemError(l)}},n,i)}_getDataView(l,r,n,i){switch(n){case"F":return i===8?l.getFloat64(r,this.littleEndian):l.getFloat32(r,this.littleEndian);case"I":return i===1?l.getInt8(r):i===2?l.getInt16(r,this.littleEndian):l.getInt32(r,this.littleEndian);case"U":return i===1?l.getUint8(r):i===2?l.getUint16(r,this.littleEndian):l.getUint32(r,this.littleEndian)}}parse(l){function r(D,w){const q=D.length,A=new Uint8Array(w);let j=0,O=0,E,_,x;do if(E=D[j++],E<32){if(E++,O+E>w)throw new Error("Output buffer is not large enough");if(j+E>q)throw new Error("Invalid compressed data");do A[O++]=D[j++];while(--E)}else{if(_=E>>5,x=O-((E&31)<<8)-1,j>=q)throw new Error("Invalid compressed data");if(_===7&&(_+=D[j++],j>=q))throw new Error("Invalid compressed data");if(x-=D[j++],O+_+2>w)throw new Error("Output buffer is not large enough");if(x<0)throw new Error("Invalid compressed data");if(x>=O)throw new Error("Invalid compressed data");do A[O++]=A[x++];while(--_+2)}while(j<q);return A}function n(D){const w={},q=new Uint8Array(D);let A="",j="",O=0,E=!1;const _=q.length;for(;O<_&&E===!1;){const I=String.fromCharCode(q[O++]);I===`
|
|
1
|
+
"use strict";var Qu=Object.defineProperty;var ed=(a,l,r)=>l in a?Qu(a,l,{enumerable:!0,configurable:!0,writable:!0,value:r}):a[l]=r;var fn=(a,l,r)=>ed(a,typeof l!="symbol"?l+"":l,r);const e=require("vue"),Ja=require("./request-Dl8yi2iS.cjs"),M=require("./index-CMUsYepp.cjs"),pl=require("./index-2P0gL-8h.cjs"),le=require("./index-BuZHI6xx.cjs"),pr=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Fl=require("./index.vue_vue_type_style_index_0_scoped_07c75c98_lang-J7Knzs4U.cjs"),$r=require("./index-B-pflqKE.cjs"),Do=require("./threeViewerHost-CjQ-eaaH.cjs"),Kr=require("./index-DmwxzDGW.cjs"),vs=require("./index-D1hl24-E.cjs"),dc=require("./index-DkTHtURJ.cjs");;/* empty css */const To=require("./isString-CGrvcmBw.cjs"),ms=require("./index.vue_vue_type_script_setup_true_lang-BKTJR2th.cjs"),pc=require("./index-BVaHwt5f.cjs"),ad=require("./index-CPTra5LJ.cjs"),Yn=require("./MTLLoader-DqJ6tn_v.cjs"),ld=require("./URDFLoader-CnIz461N.cjs");var rd="[object Boolean]";function fc(a){return a===!0||a===!1||Ja.isObjectLike(a)&&Ja.baseGetTag(a)==rd}function nd(a){return a===void 0}const id=a=>a.match(/\((.*)\)/)[1],od={__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,r=e.ref(null),n=e.ref(!1),i=e.ref(null);return e.watch(()=>l==null?void 0:l.isVisible,()=>{n.value=l==null?void 0:l.isVisible},{deep:!0,immediate:!0}),e.watch(()=>i.value,()=>{e.nextTick(()=>{var o,p;(p=(o=r.value)==null?void 0:o.updatePopper)==null||p.call(o)})},{deep:!0,immediate:!0}),(o,p)=>{const c=e.resolveComponent("el-popover");return e.openBlock(),e.createBlock(c,{visible:n.value,"onUpdate:visible":p[0]||(p[0]=u=>n.value=u),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:r,"trigger-keys":"[]"},{reference:e.withCtx(()=>[e.createElementVNode("div",null,[e.renderSlot(o.$slots,"reference",{ref_key:"referenceRef",ref:i})])]),default:e.withCtx(()=>[e.createElementVNode("div",null,[e.renderSlot(o.$slots,"content")])]),_:3},8,["visible","trigger","title","placement","width"])}}},td=e.defineComponent({__name:"index",props:{value:{type:[String,Number],default:""},columnContent:{type:Object,default:{}}},setup(a){const l=a,r=e.computed(()=>{var u,m,g,y,d,D;const n=l.value??"";let i=(u=l==null?void 0:l.columnContent)==null?void 0:u.filter;if(i=(m=le.analyzeSplitToContent(i,","))==null?void 0:m.map(w=>((w==null?void 0:w[(w==null?void 0:w.length)-1])===","&&(w=w==null?void 0:w.slice(0,(w==null?void 0:w.length)-1)),w)),i=i==null?void 0:i.find(w=>(w==null?void 0:w[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 o=(y=(g=l==null?void 0:l.columnContent)==null?void 0:g.options)==null?void 0:y.findIndex(w=>(w==null?void 0:w.value)===n);o=i==null?void 0:i[o],o=le.analyzeSplitToContent(o,","),o=o==null?void 0:o.map(w=>((w==null?void 0:w[(w==null?void 0:w.length)-1])===","&&(w=w==null?void 0:w.slice(0,(w==null?void 0:w.length)-1)),w));let p=o==null?void 0:o.find(w=>w==null?void 0:w.includes("@TextBackRGBA"));p?p=le.rgbaToColor((d=p==null?void 0:p.split("="))==null?void 0:d[1]):p=void 0;let c=o==null?void 0:o.find(w=>w==null?void 0:w.includes("@TextRGBA"));return c?c=le.rgbaToColor((D=c==null?void 0:c.split("="))==null?void 0:D[1]):c=void 0,{backgroundColor:p,color:c}});return(n,i)=>a.value!==void 0&&a.value!==null?(e.openBlock(),e.createElementBlock("span",{key:0,class:"task-status-tag",style:e.normalizeStyle(r.value)},e.toDisplayString(a.value===0?"0":a.value),5)):e.createCommentVNode("",!0)}}),sd=pr._export_sfc(td,[["__scopeId","data-v-3290070b"]]);function cd(a,l,r,n={}){if(!a||!l||!r||r.length!==4)return;const i=a.getContext("2d");if(!i)return;const{color:o="rgba(255, 235, 59, 0.3)",strokeWidth:p=2,fillOpacity:c=.2}=n,u=a.getBoundingClientRect(),m=l.getBoundingClientRect(),g=l.naturalWidth,y=l.naturalHeight,d=m.width/g,D=m.height/y,w=Math.min(d,D),q=g*w,A=y*w,j=(u.width-q)/2,O=(u.height-A)/2,E=r.map(([x,b])=>{const S=j+x*q,I=O+b*A;return{x:S,y:I}});i.clearRect(0,0,a.width,a.height),i.beginPath(),i.moveTo(E[0].x,E[0].y);for(let x=1;x<E.length;x++)i.lineTo(E[x].x,E[x].y);i.closePath();const _=o.replace(/[\d.]+\)$/,`${c})`);i.fillStyle=_,i.fill(),i.strokeStyle=o.replace(/[\d.]+\)$/,"1)"),i.lineWidth=p,i.stroke()}function Bi(a){if(!a)return;const l=a.getContext("2d");l&&l.clearRect(0,0,a.width,a.height)}function ys(a,l){if(!a||!l)return null;const r=a[l];return!r||!r.bboxNorm||!Array.isArray(r.bboxNorm)||r.bboxNorm.length!==4?null:{bboxNorm:r.bboxNorm,imageName:r.imageName||""}}const ud={key:0,class:"ocr-img-preview-root"},dd={class:"ocr-img-preview-window"},pd={key:0,class:"img-preview-body"},fd={class:"img-preview-header"},hd={class:"img-header-left"},vd={class:"img-name"},md={key:0,class:"img-header-right"},yd={class:"img-index"},gd={key:0,class:"img-thumb-list"},bd=["onClick"],kd={key:1,class:"thumb-placeholder"},xd={class:"thumb-name"},wd={class:"img-preview-container"},_d={key:0,class:"img-placeholder"},Sd={key:2,class:"img-placeholder"},Ed={key:0},Cd={key:1},Dd={key:1,class:"img-placeholder"},Td=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 r=a,n=l,i=e.computed({get:()=>r.visible,set:N=>n("update:visible",N)});let o=!1,p="",c=0,u=0,m=0,g=0,y=0,d=0,D=null;const w=N=>{var G,fe;const se=(fe=(G=N==null?void 0:N.target)==null?void 0:G.closest)==null?void 0:fe.call(G,".ocr-img-preview-window");return se||document.querySelector(".ocr-img-preview-window")},q=N=>{if(!N||N==="none")return{tx:0,ty:0};let se=N.match(/matrix\(([^)]+)\)/);if(se){const G=se[1].split(",").map(fe=>Number(fe.trim()));return{tx:(G==null?void 0:G[4])||0,ty:(G==null?void 0:G[5])||0}}if(se=N.match(/matrix3d\(([^)]+)\)/),se){const G=se[1].split(",").map(fe=>Number(fe.trim()));return{tx:(G==null?void 0:G[12])||0,ty:(G==null?void 0:G[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}},A=(N,se,G)=>{N.style.transform=`translate(${se}px, ${G}px)`},j=N=>{const se=w(N);if(!se)return;o=!0,D=se,p="move",c=N.clientX,u=N.clientY;const G=window.getComputedStyle(se),{tx:fe,ty:we}=q(G.transform);y=fe,d=we,document.addEventListener("mousemove",E),document.addEventListener("mouseup",_)},O=(N,se)=>{const G=w(N);if(!G)return;o=!0,D=G,p=se,c=N.clientX,u=N.clientY;const fe=G.getBoundingClientRect();m=fe.width,g=fe.height;const we=window.getComputedStyle(G),{tx:_e,ty:qe}=q(we.transform);y=_e,d=qe,document.addEventListener("mousemove",E),document.addEventListener("mouseup",_)},E=N=>{if(!o||!D)return;const se=N.clientX-c,G=N.clientY-u,fe=360,we=420;let _e=m,qe=g,ra=y,P=d;if(p==="move"){ra=y+se,P=d+G,A(D,ra,P);return}if(p.includes("right")&&(_e=Math.max(fe,m+se)),p.includes("bottom")&&(qe=Math.max(we,g+G)),p.includes("left")){const Ke=m-se;Ke<fe?(_e=fe,ra=y+(m-fe)):(_e=Ke,ra=y+se)}if(p.includes("top")){const Ke=g-G;Ke<we?(qe=we,P=d+(g-we)):(qe=Ke,P=d+G)}D.style.width=`${_e}px`,D.style.height=`${qe}px`,A(D,ra,P)},_=()=>{o=!1,p="",D=null,document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",_)},x=e.ref([]),b=e.ref(!1);e.watch(()=>r.images,async N=>{if(!Array.isArray(N)||N.length===0){x.value=[];return}b.value=!0;const se=[];for(const G of N)if(G.url&&!G.url.startsWith("blob:")&&!G.url.startsWith("http"))try{const fe=await Fl.downloadFile(G.url),we=URL.createObjectURL(fe);se.push({...G,blobUrl:we})}catch(fe){console.error(`Failed to load image for preview: ${G.url}`,fe),se.push({...G,blobUrl:""})}else se.push({...G,blobUrl:G.url});x.value=se,b.value=!1},{deep:!0,immediate:!0});const S=e.ref(0),I=e.ref(null),R=e.ref(null),re=e.computed(()=>x.value[S.value]||null),X=()=>{if(!x.value.length){S.value=0;return}if(r.defaultImageName){const N=x.value.findIndex(se=>(se==null?void 0:se.name)===r.defaultImageName);S.value=N>=0?N:0}else S.value=0},me=N=>{if(!x.value.length)return;const se=Math.max(0,Math.min(N,x.value.length-1));S.value=se},ue=()=>me(S.value-1),U=()=>me(S.value+1),W=N=>{if(!N)return;const se=x.value.findIndex(G=>(G==null?void 0:G.name)===N);se>=0&&(S.value=se)},Z=()=>{if(!R.value)return;const N=R.value.parentElement;if(!N)return;const se=N.getBoundingClientRect();R.value.width=se.width,R.value.height=se.height},ae=()=>{var fe,we;if(!R.value||!I.value||!r.focusedFieldName){R.value&&Bi(R.value);return}const N=(fe=I.value.$el)==null?void 0:fe.querySelector("img");if(!N)return;if(!N.complete||N.naturalWidth===0){N.onload=()=>{e.nextTick(()=>{ae()})};return}const se=((we=re.value)==null?void 0:we.name)||"",G=ys(r.fieldMeta,r.focusedFieldName);if(!G){Bi(R.value);return}if(G.imageName!==se){Bi(R.value);return}Z(),cd(R.value,N,G.bboxNorm)},ve=()=>{e.nextTick(()=>{Z(),ae()})};e.watch(()=>r.focusedFieldName,()=>{if(!i.value)return;const N=ys(r.fieldMeta,r.focusedFieldName);N!=null&&N.imageName&&W(N.imageName),e.nextTick(()=>{ae()})}),e.watch(()=>{var N;return(N=re.value)==null?void 0:N.name},()=>{i.value&&e.nextTick(()=>{R.value&&Bi(R.value),ae()})}),e.watch(()=>r.visible,N=>{N?(X(),e.nextTick(()=>{Z(),ae()})):R.value&&Bi(R.value)}),e.watch(()=>r.defaultImageName,()=>{i.value&&X()});let ze=null;e.onMounted(()=>{var N;typeof ResizeObserver<"u"&&(ze=new ResizeObserver(()=>{Z(),e.nextTick(()=>{ae()})}),(N=R.value)!=null&&N.parentElement&&ze.observe(R.value.parentElement))}),e.onUnmounted(()=>{ze&&(ze.disconnect(),ze=null),document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",_)});const te=()=>{R.value&&Bi(R.value),n("update:visible",!1),n("close")};return(N,se)=>{var qe,ra;const G=e.resolveComponent("el-button"),fe=e.resolveComponent("el-image"),we=e.resolveComponent("Loading"),_e=e.resolveComponent("el-icon");return i.value?(e.openBlock(),e.createElementBlock("div",ud,[se[12]||(se[12]=e.createElementVNode("div",{class:"ocr-img-preview-backdrop"},null,-1)),e.createElementVNode("div",dd,[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:te},"×")],32),e.createElementVNode("div",{class:"resizable-handle top",onMousedown:se[0]||(se[0]=e.withModifiers(P=>O(P,"top"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle right",onMousedown:se[1]||(se[1]=e.withModifiers(P=>O(P,"right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom",onMousedown:se[2]||(se[2]=e.withModifiers(P=>O(P,"bottom"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle left",onMousedown:se[3]||(se[3]=e.withModifiers(P=>O(P,"left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-left",onMousedown:se[4]||(se[4]=e.withModifiers(P=>O(P,"top-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-right",onMousedown:se[5]||(se[5]=e.withModifiers(P=>O(P,"top-right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-left",onMousedown:se[6]||(se[6]=e.withModifiers(P=>O(P,"bottom-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-right",onMousedown:se[7]||(se[7]=e.withModifiers(P=>O(P,"bottom-right"),["stop"]))},null,32),re.value?(e.openBlock(),e.createElementBlock("div",pd,[e.createElementVNode("div",fd,[e.createElementVNode("div",hd,[e.createElementVNode("span",vd,e.toDisplayString(re.value.name?re.value.name+(re.value.url&&re.value.url.lastIndexOf(".")!==-1?re.value.url.substring(re.value.url.lastIndexOf(".")):""):""),1)]),x.value.length>1?(e.openBlock(),e.createElementBlock("div",md,[e.createVNode(G,{size:"small",disabled:S.value===0,onClick:ue},{default:e.withCtx(()=>se[9]||(se[9]=[e.createTextVNode("上一张")])),_:1,__:[9]},8,["disabled"]),e.createElementVNode("span",yd,e.toDisplayString(S.value+1)+" / "+e.toDisplayString(x.value.length),1),e.createVNode(G,{size:"small",disabled:S.value===x.value.length-1,onClick:U},{default:e.withCtx(()=>se[10]||(se[10]=[e.createTextVNode("下一张")])),_:1,__:[10]},8,["disabled"])])):e.createCommentVNode("",!0)]),x.value.length>1?(e.openBlock(),e.createElementBlock("div",gd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value,(P,Ke)=>(e.openBlock(),e.createElementBlock("div",{key:(P.name||"")+"-"+Ke,class:e.normalizeClass(["img-thumb-item",{active:Ke===S.value}]),onClick:Me=>me(Ke)},[P!=null&&P.blobUrl?(e.openBlock(),e.createBlock(fe,{key:0,src:P.blobUrl,fit:"cover",class:"thumb-image","preview-src-list":[P.blobUrl],"initial-index":0},null,8,["src","preview-src-list"])):(e.openBlock(),e.createElementBlock("div",kd,"加载失败")),e.createElementVNode("div",xd,e.toDisplayString(P.name||"-"),1)],10,bd))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",wd,[b.value?(e.openBlock(),e.createElementBlock("div",_d,[e.createVNode(_e,{class:"is-loading"},{default:e.withCtx(()=>[e.createVNode(we)]),_:1}),se[11]||(se[11]=e.createElementVNode("span",null,"图片加载中...",-1))])):(qe=re.value)!=null&&qe.blobUrl?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(fe,{ref_key:"imageRef",ref:I,src:re.value.blobUrl,fit:"contain",class:"preview-image","preview-src-list":[re.value.blobUrl],onLoad:ve},null,8,["src","preview-src-list"]),e.createElementVNode("canvas",{ref_key:"canvasRef",ref:R,class:"highlight-canvas"},null,512)],64)):(e.openBlock(),e.createElementBlock("div",Sd,[(ra=re.value)!=null&&ra.url?(e.openBlock(),e.createElementBlock("span",Ed,"图片加载失败")):(e.openBlock(),e.createElementBlock("span",Cd,"暂无图片"))]))])])):(e.openBlock(),e.createElementBlock("div",Dd,"暂无图片"))])])):e.createCommentVNode("",!0)}}}),Bd=pr._export_sfc(Td,[["__scopeId","data-v-48a4ecb1"]]),Nd={class:"cert-preview-body"},Ad={key:0,class:"pdf-preview-container"},zd={class:"thumbs"},Md=["onClick"],Id={class:"thumb-img"},Od=["src"],Ld={key:1,class:"thumb-loading"},Rd={class:"thumb-title"},$d={class:"viewer"},Vd={key:0,class:"viewer-img-wrap"},Fd=["src"],Pd={key:1,class:"viewer-loading"},jd=e.defineComponent({__name:"CertificatePreview",props:{visible:{type:Boolean},versions:{}},emits:["update:visible"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(""),o=e.ref(""),p=e.computed(()=>(r.versions||[]).find(w=>String(w.versionId)===String(i.value))),c=e.ref({}),u=e.ref(""),m=e.ref("证书附件.pdf"),g=()=>{try{Object.values(c.value||{}).forEach(w=>{w&&URL.revokeObjectURL(w)}),u.value&&URL.revokeObjectURL(u.value)}catch{}c.value={},u.value=""},y=async w=>{if(!w||w.fileType==="pdf")return;const q=Array.isArray(w.images)?w.images:[];for(const A of q){const j=A==null?void 0:A.url;if(!(!j||c.value[j]))try{const O=await M.platformDownloadFile({url:j}),E=URL.createObjectURL(O.data);c.value={...c.value,[j]:E}}catch{}}},d=async w=>{var A;if(!w||w.fileType!=="pdf"){u.value="";return}const q=w.sourceUrl||"";if(!q){u.value="";return}if(u.value){try{URL.revokeObjectURL(u.value)}catch{}u.value=""}try{console.log("[CertificatePreview] 下载PDF附件:",{url:q,versionId:w==null?void 0:w.versionId,certNo:w==null?void 0:w.certNo});const j=await M.platformDownloadFile({url:q});console.log("[CertificatePreview] PDF响应:",{url:q,status:j==null?void 0:j.status,size:(A=j==null?void 0:j.data)==null?void 0:A.size});const O=URL.createObjectURL(j.data);u.value=O;const E=w.certNo?String(w.certNo):"";m.value=E?`${E}.pdf`:"证书附件.pdf"}catch(j){console.error("[CertificatePreview] PDF加载失败:",{url:q,error:j}),u.value=""}};e.watch(()=>r.visible,async w=>{var A;if(!w){g();return}const q=(A=r.versions)==null?void 0:A[0];i.value=(q==null?void 0:q.versionId)||"",await y(q),await d(q)},{immediate:!0}),e.watch(()=>i.value,async()=>{var q,A;const w=p.value;if(!w){o.value="",u.value="";return}if(w.fileType==="pdf"){o.value="",await d(w);return}u.value="",o.value=((A=(q=w.images)==null?void 0:q[0])==null?void 0:A.url)||"",await y(w)},{immediate:!0});const D=()=>{n("update:visible",!1),g()};return e.onBeforeUnmount(()=>{g()}),(w,q)=>{const A=e.resolveComponent("el-empty"),j=e.resolveComponent("el-tab-pane"),O=e.resolveComponent("el-tabs"),E=e.resolveComponent("el-button"),_=e.resolveComponent("el-dialog");return e.openBlock(),e.createBlock(_,{"model-value":w.visible,title:"证书附件预览",width:"1100px","close-on-click-modal":!1,onClose:D},{footer:e.withCtx(()=>[e.createVNode(E,{id:"themeBorderButton",onClick:D},{default:e.withCtx(()=>q[1]||(q[1]=[e.createTextVNode("关闭")])),_:1,__:[1]})]),default:e.withCtx(()=>[w.versions&&w.versions.length>0?(e.openBlock(),e.createBlock(O,{key:0,modelValue:i.value,"onUpdate:modelValue":q[0]||(q[0]=x=>i.value=x),type:"card",class:"cert-version-tabs"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.versions,x=>(e.openBlock(),e.createBlock(j,{key:x.versionId,name:x.versionId,label:x.label},{default:e.withCtx(()=>[e.createElementVNode("div",Nd,[x.fileType==="pdf"?(e.openBlock(),e.createElementBlock("div",Ad,[u.value?(e.openBlock(),e.createBlock(pl.SsFilePreview,{key:1,fileName:m.value,blobUrl:u.value},null,8,["fileName","blobUrl"])):(e.openBlock(),e.createBlock(A,{key:0,description:"加载中"}))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",zd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.images||[],b=>(e.openBlock(),e.createElementBlock("div",{key:b.url,class:e.normalizeClass(["thumb",{active:b.url===o.value}]),onClick:S=>o.value=b.url},[e.createElementVNode("div",Id,[c.value[b.url]?(e.openBlock(),e.createElementBlock("img",{key:0,src:c.value[b.url]},null,8,Od)):(e.openBlock(),e.createElementBlock("div",Ld,"加载中"))]),e.createElementVNode("div",Rd,e.toDisplayString(b.name),1)],10,Md))),128))]),e.createElementVNode("div",$d,[o.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[c.value[o.value]?(e.openBlock(),e.createElementBlock("div",Vd,[e.createElementVNode("img",{class:"viewer-img",src:c.value[o.value]},null,8,Fd)])):(e.openBlock(),e.createElementBlock("div",Pd,"加载中"))],64)):(e.openBlock(),e.createBlock(A,{key:0,description:"暂无图片"}))])],64))])]),_:2},1032,["name","label"]))),128))]),_:1},8,["modelValue"])):(e.openBlock(),e.createBlock(A,{key:1,description:"暂无可预览的证书附件"}))]),_:1},8,["model-value"])}}}),Hd=pr._export_sfc(jd,[["__scopeId","data-v-220703c0"]]),Ud={class:"ocr-candidate-wrap"},qd={class:"ocr-candidate-left"},Wd={key:1},Gd={key:0},Kd={key:1},Yd={key:2},Jd={key:3},Xd={key:0,class:"ocr-candidate-right"},Zd={class:"ocr-candidate-actions"},Qd={key:1},ep={class:"dialog-footer"},ap={__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 r=(S=[])=>{const I=[],R=re=>{(re||[]).forEach(X=>{if(!X)return;const me=X.children||X.childrens||X.columns;Array.isArray(me)&&me.length>0?R(me):I.push(X)})};return R(S),I},n=a,i=l,o=e.computed(()=>{var S;return((S=d.value)==null?void 0:S.allowAdd)!==!1}),p=e.computed(()=>{var S;return((S=d.value)==null?void 0:S.allowReplace)!==!1}),c=S=>{if(!S)return[];if(Array.isArray(S))return S;if(typeof S=="string")try{const I=JSON.parse(S);return Array.isArray(I)?I:[]}catch{return[]}return[]},u=S=>{i("preview-file",S)},m=e.ref([]),g=e.ref(0),y=e.ref("");e.watch(()=>n.candidates,S=>{var I,R;m.value=(S||[]).map(re=>({...re,...(re==null?void 0:re.ocrRow)||{},selectedTargetId:(re==null?void 0:re.selectedTargetId)||"",__decision:re==null?void 0:re.__decision})),g.value=0,y.value=((R=(I=m.value)==null?void 0:I[0])==null?void 0:R.selectedTargetId)||""},{immediate:!0,deep:!0}),e.watch(()=>n.visible,S=>{var I,R;S&&(g.value=0,y.value=((R=(I=m.value)==null?void 0:I[0])==null?void 0:R.selectedTargetId)||"")});const d=e.computed(()=>{var I;const S=Number(g.value||0);return((I=m.value||[])==null?void 0:I[S])||null}),D=e.computed(()=>(r(n.columns||[])||[]).filter(R=>R&&R.prop).filter(R=>R.type!=="operate"&&R.label!=="操作"&&R.prop!=="operate")),w=e.computed(()=>D.value.filter(S=>S.label!=="证书附件"&&S.prop!=="证书附件")),q=S=>{if(!S)return;const I=(m.value||[]).findIndex(R=>(R==null?void 0:R.idx)===(S==null?void 0:S.idx));I>-1&&(g.value=I,y.value=(S==null?void 0:S.selectedTargetId)||"")},A=S=>{if(!S){y.value="";return}y.value=String((S==null?void 0:S.id)??"")},j=(S,I="")=>{const R=Number(g.value||0),re=m.value||[],X=re[R];X&&(X.__decision=S,X.selectedTargetId=I,y.value=I,m.value=[...re])},O=()=>j("skip",""),E=()=>j("add",""),_=()=>{if(!y.value){Ja.ElMessage.warning("请先选择要替换的目标记录");return}j("replace",y.value)},x=()=>{i("update:visible",!1)},b=()=>{const S=m.value||[];if(S.find(R=>(R==null?void 0:R.__decision)==="replace"&&!(R!=null&&R.selectedTargetId))){Ja.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}i("submit",S),i("update:visible",!1)};return(S,I)=>{const R=e.resolveComponent("el-table-column"),re=e.resolveComponent("svg-icon"),X=e.resolveComponent("el-table"),me=e.resolveComponent("el-button"),ue=e.resolveComponent("el-alert");return e.openBlock(),e.createBlock($r.ssDialog,{title:"OCR候选匹配",visible:a.visible,"close-on-click-modal":!1,width:"90%",style:{maxWidth:"1200px"},onBeforeDestroy:x},{default:e.withCtx(()=>{var U,W;return[e.createElementVNode("div",Ud,[e.createElementVNode("div",qd,[I[0]||(I[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:q},{default:e.withCtx(()=>[e.createVNode(R,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,Z=>(e.openBlock(),e.createBlock(R,{key:Z.prop,label:Z.label,prop:Z.prop,"min-width":Z.minWidth||160},{default:e.withCtx(({row:ae})=>[Z.label==="证书附件"||Z.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(ae==null?void 0:ae[Z.prop]).length>0?(e.openBlock(),e.createBlock(re,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(ve=>u({row:ae,prop:Z.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Wd,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((ae==null?void 0:ae[Z.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128)),e.createVNode(R,{label:"候选数",width:"90",fixed:"right"},{default:e.withCtx(({row:Z})=>[e.createTextVNode(e.toDisplayString(((Z==null?void 0:Z.candidates)||[]).length),1)]),_:1}),e.createVNode(R,{label:"处理状态",width:"120",fixed:"right"},{default:e.withCtx(({row:Z})=>[(Z==null?void 0:Z.__decision)==="replace"?(e.openBlock(),e.createElementBlock("span",Gd,"替换")):(Z==null?void 0:Z.__decision)==="add"?(e.openBlock(),e.createElementBlock("span",Kd,"新增")):(Z==null?void 0:Z.__decision)==="skip"?(e.openBlock(),e.createElementBlock("span",Yd,"跳过")):(e.openBlock(),e.createElementBlock("span",Jd,"未处理"))]),_:1})]),_:1},8,["data"])]),m.value&&m.value.length>0?(e.openBlock(),e.createElementBlock("div",Xd,[I[4]||(I[4]=e.createElementVNode("div",{class:"ocr-candidate-title"},"当前行候选记录(同编号)",-1)),e.createElementVNode("div",Zd,[e.createVNode(me,{id:"themeBorderButton",onClick:O},{default:e.withCtx(()=>I[1]||(I[1]=[e.createTextVNode("跳过本行")])),_:1,__:[1]}),e.createVNode(me,{id:"themeBorderButton",onClick:E,disabled:!o.value},{default:e.withCtx(()=>I[2]||(I[2]=[e.createTextVNode("新增本行")])),_:1,__:[2]},8,["disabled"]),e.createVNode(me,{class:"ok-button",id:"themeButton",onClick:_,disabled:!p.value||!y.value},{default:e.withCtx(()=>I[3]||(I[3]=[e.createTextVNode("替换选中记录")])),_:1,__:[3]},8,["disabled"])]),(((U=d.value)==null?void 0:U.candidates)||[]).length===0?(e.openBlock(),e.createBlock(ue,{key:0,title:"该编号暂无候选记录,可选择“新增本行”或“跳过本行”。",type:"info",closable:!1,"show-icon":"",style:{margin:"8px 0"}})):e.createCommentVNode("",!0),e.createVNode(X,{data:((W=d.value)==null?void 0:W.candidates)||[],border:"",stripe:"","max-height":"300",style:{width:"100%"},onCurrentChange:A,"highlight-current-row":""},{default:e.withCtx(()=>[e.createVNode(R,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(D.value,Z=>(e.openBlock(),e.createBlock(R,{key:Z.prop,label:Z.label,prop:Z.prop,"min-width":Z.minWidth||160},{default:e.withCtx(({row:ae})=>[Z.label==="证书附件"||Z.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c(ae==null?void 0:ae[Z.prop]).length>0?(e.openBlock(),e.createBlock(re,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(ve=>u({row:ae,prop:Z.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Qd,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((ae==null?void 0:ae[Z.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128))]),_:1},8,["data"])])):e.createCommentVNode("",!0)])]}),footer:e.withCtx(()=>[e.createElementVNode("div",ep,[e.createVNode(me,{id:"themeBorderButton",onClick:x},{default:e.withCtx(()=>I[5]||(I[5]=[e.createTextVNode("取消")])),_:1,__:[5]}),e.createVNode(me,{class:"ok-button",id:"themeButton",onClick:b},{default:e.withCtx(()=>I[6]||(I[6]=[e.createTextVNode("提交已处理")])),_:1,__:[6]})])]),_:1},8,["visible"])}}},lp=pr._export_sfc(ap,[["__scopeId","data-v-89e0489c"]]),rp={class:"ocr-preview-content"},np={class:"ocr-preview-tip"},ip={class:"ocr-preview-table"},op={style:{display:"flex","align-items":"center",gap:"8px"}},tp={class:"dialog-footer"},sp={__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 r=a,n=l,i=e.ref([]),o=e.ref([]),p=e.ref([]);e.watch(()=>r.visible,D=>{D&&(i.value=JSON.parse(JSON.stringify(r.ocrPreviewData)),o.value=JSON.parse(JSON.stringify(r.ocrPreviewColumns)),p.value=[...r.ocrSelectedFields])});const c=(D,w)=>{const q=[...p.value];if(w)q.includes(D)||q.push(D);else{const A=q.indexOf(D);A>-1&&q.splice(A,1)}p.value=q,n("update:ocrSelectedFields",q)},u=(D,w,q)=>{n("fieldChange",{rowIndex:D,prop:w,value:q})},m=()=>{n("update:ocrPreviewData",i.value),n("confirm",i.value),n("update:visible",!1)},g=()=>{n("update:visible",!1)},y=D=>typeof D!="number"?"-":`${(D*100).toFixed(1)}%`,d=D=>typeof D!="number"?"#606266":D>=.9?"#67c23a":D>=.7?"#e6a23c":"#f56c6c";return(D,w)=>{const q=e.resolveComponent("el-alert"),A=e.resolveComponent("el-table-column"),j=e.resolveComponent("el-checkbox"),O=e.resolveComponent("el-input"),E=e.resolveComponent("el-table"),_=e.resolveComponent("el-button");return e.openBlock(),e.createBlock($r.ssDialog,{title:"OCR识别结果预览",visible:a.visible,onBeforeDestroy:g,width:"90%",style:{maxWidth:"1200px"}},{default:e.withCtx(()=>[e.createElementVNode("div",rp,[e.createElementVNode("div",np,[e.createVNode(q,{title:"请核对识别结果。系统将按 编号+名称+制造厂 规则匹配并替换;未唯一命中但有编号的,将进入候选选择;无编号则直接新增。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",ip,[e.createVNode(E,{data:i.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(A,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,x=>(e.openBlock(),e.createBlock(A,{key:x.prop,prop:x.prop,"min-width":x.minWidth||230,"class-name":x.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",op,[x.isAccuracy?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(j,{key:0,"model-value":p.value.includes(x.prop),onChange:b=>c(x.prop,b),onClick:w[0]||(w[0]=e.withModifiers(()=>{},["stop"]))},null,8,["model-value","onChange"])),e.createElementVNode("span",null,e.toDisplayString(x.label),1)])]),default:e.withCtx(({row:b,$index:S})=>[x.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:d(b[x.prop]),fontWeight:500})},e.toDisplayString(y(b[x.prop])),5)):(e.openBlock(),e.createBlock(O,{key:1,modelValue:b[x.prop],"onUpdate:modelValue":I=>b[x.prop]=I,size:"small",placeholder:"请输入"+x.label,onChange:I=>u(S,x.prop,I)},null,8,["modelValue","onUpdate:modelValue","placeholder","onChange"]))]),_:2},1032,["prop","min-width","class-name"]))),128))]),_:1},8,["data"])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",tp,[e.createVNode(_,{onClick:g,id:"themeBorderButton"},{default:e.withCtx(()=>w[1]||(w[1]=[e.createTextVNode("取消")])),_:1,__:[1]}),e.createVNode(_,{class:"ok-button",onClick:m,id:"themeButton"},{default:e.withCtx(()=>w[2]||(w[2]=[e.createTextVNode("确认")])),_:1,__:[2]})])]),_:1},8,["visible"])}}},cp=pr._export_sfc(sp,[["__scopeId","data-v-df66eb1f"]]),ri=a=>{var n;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 r=(n=le.analyzeSplitToContent(l,","))==null?void 0:n.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)),hn(i)));return r=r==null?void 0:r.join(","),r};function hc(a){return Ja.axios.post("http://222.92.178.198:8000/api/v1/excel-chat",a)}function up(a){return Ja.axios.get(a,{responseType:"blob"})}let ur="$R",dp="http://222.92.178.198:55002/AIRobot",yt=["Form","BarChart","FormText","FormBlock"];const Et=a=>{var r,n;let l=(n=le.analyzeSplitToContent(a,"@"))==null?void 0:n[((r=le.analyzeSplitToContent(a,"@"))==null?void 0:r.length)-1];return!!(yt!=null&&yt.some(i=>l==null?void 0:l.includes(i)))},pp=async(a,l,r,n)=>{var o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me;let i=a;if(Et(i==null?void 0:i[0])){let Le=yc(i),Ie=(o=Le==null?void 0:Le.filter)==null?void 0:o.join(","),de=[];(p=Le==null?void 0:Le.hideContents)==null||p.forEach(Ea=>{if(Ea){const Ge=Ea;Ge&&de.push(`(HideGroup=Yes, prop=${Ge})`)}});let De=(c=Le==null?void 0:Le.formContents)==null?void 0:c.filter(Ea=>{var Ge;return(Ge=Ea==null?void 0:Ea.filters)==null?void 0:Ge.includes("@ShowHide=Hide")});(De==null?void 0:De.length)>0&&(De==null||De.forEach(Ea=>{if(Ea){const Ge=Ea==null?void 0:Ea.prop;Ge&&de.push(`(Hide=Yes, prop=${Ge})`)}}));let Xe=(n==null?void 0:n.menuFilter)??[];return Array.isArray(Xe)||(Xe=Xe?[Xe]:[]),Xe=[...Xe,...de],Ie===""&&((u=Le==null?void 0:Le.formContents)==null?void 0:u.length)===0?void 0:{key:"Form",name:Le==null?void 0:Le.groupName,value:Le==null?void 0:Le.formContents,contents:Array.isArray((m=Le==null?void 0:Le.contents)==null?void 0:m[0])&&((y=(g=Le==null?void 0:Le.contents)==null?void 0:g[0])!=null&&y.every(Ea=>Array.isArray(Ea)))?[(D=(d=Le==null?void 0:Le.contents)==null?void 0:d[0])==null?void 0:D[r]]:[Le==null?void 0:Le.contents],filter:"("+Ie+")",menuFilter:Xe,groupFilter:Le==null?void 0:Le.groupFilters}}else if(((w=i==null?void 0:i[0])==null?void 0:w[0])!=="&"){let Le=gc(i,n),Ie="";(q=Le==null?void 0:Le.tableFilter)!=null&&q.includes(ur)?Le.tableFilter=(A=Le==null?void 0:Le.tableFilter)==null?void 0:A.replace(ur,""):Ie=(E=(O=(j=Le==null?void 0:Le.tableFilter)==null?void 0:j.replace("(",ur))==null?void 0:O.split(ur))==null?void 0:E[0];let de=[];Le!=null&&Le.tableFilter&&((_=le.analyzeSplitToContent(Le==null?void 0:Le.tableFilter,","))==null||_.forEach(Xe=>{Xe!=null&&Xe.includes("@ShowHide=Hide")&&de.push("HideGroup=Yes")}));let De=(n==null?void 0:n.menuFilter)??[];return Array.isArray(De)||(De=De?[De]:[]),De=[...De,...de],{key:"Table",name:Le==null?void 0:Le.groupName,tableColumns:Le==null?void 0:Le.tableColumns,assistColumn:Le==null?void 0:Le.columns,tableContents:l===1?Le==null?void 0:Le.tableContents:(b=(x=Le==null?void 0:Le.tableContents)==null?void 0:x[r])!=null&&b.every(Xe=>Array.isArray(Xe))?(S=Le==null?void 0:Le.tableContents)==null?void 0:S[r]:[(I=Le==null?void 0:Le.tableContents)==null?void 0:I[r]],filter:Le==null?void 0:Le.tableFilter,menuFilter:De,quotePage:Ie!==""?((X=(re=(R=Ie==null?void 0:Ie.replace("*",ur))==null?void 0:R.split(ur))==null?void 0:re[0])==null?void 0:X.replaceAll(":","/"))??"":void 0,quoteGroup:Ie!==""?((ve=(ae=(Z=(W=(U=(ue=(me=Ie==null?void 0:Ie.replace("*",ur))==null?void 0:me.split(ur))==null?void 0:ue[1])==null?void 0:U.replace("{",ur))==null?void 0:W.split(ur))==null?void 0:Z[0])==null?void 0:ae.split(":"))==null?void 0:ve.filter(Xe=>Xe!==""))??[]:[],relatedQuotes:Le==null?void 0:Le.relatedQuotes,fatherSyncContents:Le==null?void 0:Le.fatherSyncContents,sonSyncContents:Le==null?void 0:Le.sonSyncContents,calculatorFilters:(Le==null?void 0:Le.calculatorFilters)??[]}}else{let Le=[{label:"序号",prop:"sort"},{label:"函数名称",prop:"函数名称"},{label:"函数关联名",prop:"函数关联名"},{label:"函数参数",prop:"函数参数"},{label:"输出值",prop:"输出值"},{label:"导入文件",prop:"导入文件",formType:"Upload"}],Ie=i==null?void 0:i[0];Ie=Ie==null?void 0:Ie.slice(1,Ie==null?void 0:Ie.length),Ie=le.analyzeSplitToContent(Ie,":"),Ie=Ie==null?void 0:Ie[(Ie==null?void 0:Ie.length)-1];let de=[];de.push("1");let De=Ie==null?void 0:Ie.replace("(",ur);De=(ze=De==null?void 0:De.split(ur))==null?void 0:ze[0],de.push(De);let Xe=Ie==null?void 0:Ie.replace("(",ur);if(Xe=(te=Xe==null?void 0:Xe.split(ur))==null?void 0:te[1],Xe=(se=(N=Xe==null?void 0:Xe.replace(")",ur))==null?void 0:N.split(ur))==null?void 0:se[0],(fe=(G=Xe==null?void 0:Xe.replace(",",ur))==null?void 0:G.split(ur))==null||fe.forEach(Ea=>{de.push(Ea)}),de.push(""),de.push(""),(we=de==null?void 0:de[2])!=null&&we.includes(".xlsx")||(_e=de==null?void 0:de[2])!=null&&_e.includes(".xls"))try{let Ea=dp+"/"+(de==null?void 0:de[2]),Ge=await up(Ea),$=`生成js函数名称为${de==null?void 0:de[1]}的函数,规则为:`+(de==null?void 0:de[3])+"。根据上述描述获取对应的总结性详细可运行js函数,不需要任何注释。";if((Ge==null?void 0:Ge.status)===200){let V=Ge==null?void 0:Ge.data;const ee=new FormData;ee.append("file",V,de==null?void 0:de[2]),ee.append("query",$);let ce=await hc(ee);ce=(P=(ra=(qe=ce==null?void 0:ce.data)==null?void 0:qe.data)==null?void 0:ra.response)==null?void 0:P.replace("generateResult",de==null?void 0:de[1]),de[de.length-2]=ce,de[de.length-1]=[{name:(Me=(Ke=de==null?void 0:de[2])==null?void 0:Ke.split("."))==null?void 0:Me[0],url:Ea}]}}catch{}return de=[de],{key:"Method",name:[],tableContents:de,tableColumns:Le}}},fp=(a,l)=>{var n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea;let r=(i=(n=le.analyzeSplitToContent(a,"="))==null?void 0:n.filter(Ge=>Ge!=="="))==null?void 0:i.map(Ge=>((Ge==null?void 0:Ge[(Ge==null?void 0:Ge.length)-1])==="="&&(Ge=Ge==null?void 0:Ge.slice(0,(Ge==null?void 0:Ge.length)-1)),Ge));if(Et(r==null?void 0:r[1])||Et(r==null?void 0:r[0])){let Ge=bp(r);if(Ge!=null&&Ge.formContents){let he=(o=Ge==null?void 0:Ge.filter)==null?void 0:o.join(","),pa=[];(p=Ge==null?void 0:Ge.hideContents)==null||p.forEach(ya=>{if(ya){const Ca=ya;Ca&&pa.push(`(HideGroup=Yes, prop=${Ca})`)}});let ia=(c=Ge==null?void 0:Ge.formContents)==null?void 0:c.filter(ya=>{var Ca;return(Ca=ya==null?void 0:ya.filters)==null?void 0:Ca.includes("@ShowHide=Hide")});(ia==null?void 0:ia.length)>0&&(ia==null||ia.forEach(ya=>{if(ya){const Ca=ya==null?void 0:ya.prop;Ca&&pa.push(`(Hide=Yes, prop=${Ca})`)}}));let Ve=(l==null?void 0:l.menuFilter)??[];return Array.isArray(Ve)||(Ve=Ve?[Ve]:[]),Ve=[...Ve,...pa],he===""&&((u=Ge==null?void 0:Ge.formContents)==null?void 0:u.length)===0?void 0:{key:"Form",name:Ge==null?void 0:Ge.groupName,value:Ge==null?void 0:Ge.formContents,contents:[Ge==null?void 0:Ge.contents],filter:"("+he+")",menuFilter:Ve,groupFilter:Ge==null?void 0:Ge.groupFilters,calculatorFilters:Ge==null?void 0:Ge.calculatorFilters}}let $=(y=(g=(m=Ge==null?void 0:Ge.filter)==null?void 0:m.replace("@",ur))==null?void 0:g.split(ur))==null?void 0:y[0],V=(w=(D=(d=Ge==null?void 0:Ge.filter)==null?void 0:d.replace("(",ur))==null?void 0:D.split(ur))==null?void 0:w[1],ee=(j=(A=(q=Ge==null?void 0:Ge.filter)==null?void 0:q.replace("(",ur))==null?void 0:A.split(ur))==null?void 0:j[0];ee="@"+((O=ee==null?void 0:ee.split("@"))==null?void 0:O[1]),V=V==null?void 0:V.slice(0,(V==null?void 0:V.length)-1),V=(_=(E=le.analyzeSplitToContent(V,","))==null?void 0:E.map(he=>(he=ee+he,he)))==null?void 0:_.join("");let ce=$+"("+V+")";return{key:"Form",name:Ge==null?void 0:Ge.group,filter:ce,formPage:((S=(b=(x=$==null?void 0:$.replace("*",ur))==null?void 0:x.split(ur))==null?void 0:b[0])==null?void 0:S.replaceAll(":","/"))??"",formGroup:((U=(ue=(me=(X=(re=(R=(I=$==null?void 0:$.replace("*",ur))==null?void 0:I.split(ur))==null?void 0:R[1])==null?void 0:re.replace("{",ur))==null?void 0:X.split(ur))==null?void 0:me[0])==null?void 0:ue.split(":"))==null?void 0:U.filter(he=>he!==""))??[],value:[],menuFilter:l==null?void 0:l.menuFilter,contents:[]}}else{let Ge=r==null?void 0:r.filter((ia,Ve)=>Ve!==0);Ge=Ge==null?void 0:Ge.join("");let $=gc(r,l,Ge),V="";(W=$==null?void 0:$.tableFilter)!=null&&W.includes(ur)?$.tableFilter=(Z=$==null?void 0:$.tableFilter)==null?void 0:Z.replace(ur,""):V=(ze=(ve=(ae=$==null?void 0:$.tableFilter)==null?void 0:ae.replace("(",ur))==null?void 0:ve.split(ur))==null?void 0:ze[0];let ee=(se=(N=(te=$==null?void 0:$.tableFilter)==null?void 0:te.replace("(",ur))==null?void 0:N.split(ur))==null?void 0:se[0];ee=[{menus:(fe=(G=ee==null?void 0:ee.split("*"))==null?void 0:G[0])==null?void 0:fe.replaceAll(":","/"),groups:((_e=(we=ee==null?void 0:ee.split("*"))==null?void 0:we[1])==null?void 0:_e.split(":"))??[]}];let ce=(P=(ra=(qe=$==null?void 0:$.tableFilter)==null?void 0:qe.replace("(",ur))==null?void 0:ra.split(ur))==null?void 0:P[1];(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));let he=[];$!=null&&$.tableFilter&&((Ke=le.analyzeSplitToContent($==null?void 0:$.tableFilter,","))==null||Ke.forEach(ia=>{ia!=null&&ia.includes("@ShowHide=Hide")&&he.push("HideGroup=Yes")}));let pa=(l==null?void 0:l.menuFilter)??[];return Array.isArray(pa)||(pa=pa?[pa]:[]),pa=[...pa,...he],{key:"Table",name:$==null?void 0:$.groupName,filter:$==null?void 0:$.tableFilter,tableColumns:$==null?void 0:$.tableColumns,tableContents:$==null?void 0:$.tableContents,quotePage:V!==""?((Ie=(Le=(Me=V==null?void 0:V.replace("*",ur))==null?void 0:Me.split(ur))==null?void 0:Le[0])==null?void 0:Ie.replaceAll(":","/"))??"":void 0,quoteGroup:V!==""?((Ea=(Xe=(De=(de=V==null?void 0:V.replace("*",ur))==null?void 0:de.split(ur))==null?void 0:De[1])==null?void 0:Xe.split(":"))==null?void 0:Ea.filter(ia=>ia!==""))??[]:[],menuFilter:pa,relatedQuotes:ee,fatherSyncContents:($==null?void 0:$.fatherSyncContents)??[],sonSyncContents:($==null?void 0:$.sonSyncContents)??[],calculatorFilters:($==null?void 0:$.calculatorFilters)??[]}}},hp=async(a,l)=>{let r=[],n=l==null?void 0:l.length;return l=l==null?void 0:l.map(async(i,o)=>{let p=[];i=i==null?void 0:i.map(async c=>{var u,m;if(p.push(c),((u=le.analyzeSplitToContent(a,"="))==null?void 0:u.length)<=2){if(((m=le.analyzeSplitToContent(a,"="))==null?void 0:m.length)!==0){const g=await pp(le.analyzeSplitToContent(a,"="),n,o,c);g&&p.push(g)}}else p.push(fp(a,c))}),await Promise.all(i),r.push(p)}),await Promise.all(l),r};let Wi="/",vp="$",zn="$R";const vc=a=>{var r,n,i;let l="";if((a==null?void 0:a.length)>1){let o=a==null?void 0:a.filter((p,c)=>c!==0);o=o==null?void 0:o.join(""),o=le.analyzerSplitToWord(o,")"),(o==null?void 0:o.length)!==1?(o==null?void 0:o[(o==null?void 0:o.length)-1])===")"?o=o==null?void 0:o.join(""):o=(r=o==null?void 0:o.filter((p,c)=>c!==(o==null?void 0:o.length)-1))==null?void 0:r.join(""):o=o==null?void 0:o[0],l="("+o,((i=a==null?void 0:a[0])==null?void 0:i[((n=a==null?void 0:a[0])==null?void 0:n.length)-2])==="@"&&(l="@"+l)}return{filter:l}},mc=(a,l=[])=>{let r=(a==null?void 0:a.map(o=>{var p,c;return(c=o==null?void 0:o.key)==null?void 0:c.slice(1,(p=o==null?void 0:o.key)==null?void 0:p.length)}))??[],n=[];r==null||r.forEach(o=>{var p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me;if(o===""&&(o="算法库:通用算法"),o!=null&&o.includes(vp)){let ue="",U=!0,W=le.analyzerSplitToWord(o,"(");(W==null?void 0:W.length)>1&&(ue="("+((p=le.analyzerSplitToWord(W==null?void 0:W[1],")"))==null?void 0:p[0]),((u=W==null?void 0:W[0])==null?void 0:u[((c=W==null?void 0:W[0])==null?void 0:c.length)-2])==="@"&&(ue="@"+ue));let Z=o;Z=Z==null?void 0:Z.replace(ue,""),ue=hn(ue),ue=(m=le.analyzeSplitToContent(ue,","))==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)),ue!=null&&ue.includes("@ShowHide=Hide")&&(U=!1);let ae=(g=Z==null?void 0:Z.replace("$",zn))==null?void 0:g.split(zn),ve=ae==null?void 0:ae[1],ze=ae==null?void 0:ae[0];ze!=null&&ze.includes("[")&&(ze=(d=(y=ze==null?void 0:ze.replace("[",zn))==null?void 0:y.split(zn))==null?void 0:d[0],ve=ve+":["+((q=(w=(D=ae==null?void 0:ae[0])==null?void 0:D.replace("[",zn))==null?void 0:w.split(zn))==null?void 0:q[1])),ze=(j=(A=ze==null?void 0:ze.replaceAll(":","/"))==null?void 0:A.replaceAll("{",""))==null?void 0:j.replaceAll("}",""),(ze==null?void 0:ze[(ze==null?void 0:ze.length)-1])!=="/"&&(ze=ze+"/"),ve=((O=ze==null?void 0:ze.split("/"))==null?void 0:O[0])+":"+ve;let N="";if(!(ve!=null&&ve.includes("[")))N=ve==null?void 0:ve.replaceAll(":","/"),n==null||n.push({path:N,isShow:U,filter:ue,fatherPath:ze});else{let se=(_=(E=ve==null?void 0:ve.replace("[",zn))==null?void 0:E.split(zn))==null?void 0:_[1];se=se==null?void 0:se.slice(0,(se==null?void 0:se.length)-1),se=(x=le.analyzeSplitToContent(se,","))==null?void 0:x.map(G=>((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)),G)),se==null||se.forEach(G=>{var fe,we;N=((we=(fe=ve==null?void 0:ve.replace("[",zn))==null?void 0:fe.split(zn))==null?void 0:we[0])+G,N=N==null?void 0:N.replaceAll(":","/"),n==null||n.push({path:N,isShow:U,filter:ue,fatherPath:ze})})}}else{let ue="",U=!0,W=le.analyzerSplitToWord(o,"(");(W==null?void 0:W.length)>1&&(ue=(b=vc(W))==null?void 0:b.filter);let Z=o;if(Z=Z==null?void 0:Z.replace(ue,""),(ue==null?void 0:ue[0])==="("){ue=ue==null?void 0:ue.slice(1,(ue==null?void 0:ue.length)-1);let ve=[];(S=le.analyzeSplitToContent(ue,","))==null||S.forEach(ze=>{(ze==null?void 0:ze[(ze==null?void 0:ze.length)-1])===","&&(ze=ze==null?void 0:ze.slice(0,(ze==null?void 0:ze.length)-1)),(ze==null?void 0:ze[0])==="("&&(ze=ze==null?void 0:ze.slice(1,(ze==null?void 0:ze.length)-1)),(ze==null?void 0:ze[0])!=="@"&&(ze="@"+ze),ve.push(hn(ze))}),ue=ve==null?void 0:ve.join(",")}else ue=hn(ue);ue=(I=le.analyzeSplitToContent(ue,","))==null?void 0:I.map(ve=>((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)),ue!=null&&ue.includes("@ShowHide=Hide")&&(U=!1),(Z==null?void 0:Z[(Z==null?void 0:Z.length)-1])==="}"&&(Z=Z+":"),Z=(R=Z==null?void 0:Z.replaceAll("{",""))==null?void 0:R.replaceAll("}","");let ae="";if(Z!=null&&Z.includes("[")){let ve=(re=Z==null?void 0:Z.replace("[",zn))==null?void 0:re.split(zn),ze=ve==null?void 0:ve[1];ze=ze==null?void 0:ze.slice(0,(ze==null?void 0:ze.length)-1),(me=(X=le.analyzeSplitToContent(ze,","))==null?void 0:X.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)))==null||me.forEach(te=>{ae=(ve==null?void 0:ve[0])+te,ae=ae==null?void 0:ae.replaceAll(":","/"),n==null||n.push({path:ae,isShow:U,filter:ue})})}else ae=Z==null?void 0:Z.replaceAll(":","/"),n==null||n.push({path:ae,isShow:U,filter:ue})}});let i=M.cloneDeep(n);return(l==null?void 0:l.length)>0&&(i=l),i=i==null?void 0:i.filter(o=>{var p,c,u,m;return!(o!=null&&o.fatherPath)&&((c=(p=o==null?void 0:o.path)==null?void 0:p.split(Wi))==null?void 0:c.length)>1&&((m=(u=o==null?void 0:o.path)==null?void 0:u.split(Wi))==null?void 0:m[1])===""}),i=i==null?void 0:i.map(o=>{var p;return o.path=(p=o.path)==null?void 0:p.replace(Wi,""),o.path}),(i==null?void 0:i.length)>0&&(n=n==null?void 0:n.map(o=>{var c,u,m,g,y,d,D;let p=i==null?void 0:i.find(w=>{var q;return(q=o==null?void 0:o.path)==null?void 0:q.includes(w)});return!(o!=null&&o.fatherPath)&&p&&!((c=o==null?void 0:o.path)!=null&&c.includes(Wi))&&!(i!=null&&i.find(w=>(o==null?void 0:o.path)===w))&&(o.path=p+Wi+((D=(m=(u=o==null?void 0:o.path)==null?void 0:u.split(p))==null?void 0:m[1])==null?void 0:D.slice(1,(d=(y=(g=o==null?void 0:o.path)==null?void 0:g.split(p))==null?void 0:y[1])==null?void 0:d.length))),o})),n},mp=(a,l)=>mc([{key:a}],l),yp=async(a,l)=>{const r=[],n=mp(a==null?void 0:a.key,l);return n&&(n==null?void 0:n.length)>0&&(n==null||n.forEach(o=>{r.push([{key:"path",value:o==null?void 0:o.path,parentPath:(o==null?void 0:o.parentPath)??"",isShow:o==null?void 0:o.isShow,menuFilter:o==null?void 0:o.filter}])})),await hp(a==null?void 0:a.value,r)};let ml="$R",Yi="[Any]";const gp=a=>{var n;let l=[],r=a;return(n=le.chunkArray(r))==null||n.forEach(i=>{var m,g,y,d,D;let o="",p=[],c="";(i==null?void 0:i.length)>1&&(c="@"+(i==null?void 0:i[0]),c=hn(c));let u=(i==null?void 0:i.length)===1?i==null?void 0:i[0]:i==null?void 0:i[1];u=u==null?void 0:u.slice(1,u==null?void 0:u.length),o=(g=(m=u==null?void 0:u.replace("(",ml))==null?void 0:m.split(ml))==null?void 0:g[0],u=(d=(y=u==null?void 0:u.replace("(",ml))==null?void 0:y.split(ml))==null?void 0:d[1],u=u==null?void 0:u.slice(0,(u==null?void 0:u.length)-1),p=(D=le.analyzeSplitToContent(u,","))==null?void 0:D.map(w=>((w==null?void 0:w[(w==null?void 0:w.length)-1])===","&&(w=w==null?void 0:w.slice(0,(w==null?void 0:w.length)-1)),w)),l.push({functionName:o,functionRelatedWords:p,calculatorFilter:c})}),l},bp=a=>{var r,n,i;let l={};if(((r=a==null?void 0:a[1])==null?void 0:r[0])==="&"){let o=a==null?void 0:a[0],p=a==null?void 0:a[1];p=le.analyzeSplitToContent(p,":"),p!=null&&p[1]&&(p==null?void 0:p[1])!==""&&(o=o+":"+(p==null?void 0:p[1])),p=p==null?void 0:p[0],p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1),p=[p],o=[o],o=yc(o),l.filter=o==null?void 0:o.filter,l.contents=o==null?void 0:o.contents,l.formContents=o==null?void 0:o.formContents,l.groupFilters=o==null?void 0:o.groupFilters,l.groupName=o==null?void 0:o.groupName,l.hideContents=o==null?void 0:o.hideContents,l.calculatorFilters=gp(p)??[]}else{let p=a==null?void 0:a[0];(p==null?void 0:p[0])==="*"&&(p=p==null?void 0:p.slice(1,p==null?void 0:p.length)),p=p==null?void 0:p.split(":"),l.group=p;let c=a==null?void 0:a[1],u;c!=null&&c.includes("{")?u=(i=(n=c==null?void 0:c.replaceAll("{",""))==null?void 0:n.replaceAll("}",""))==null?void 0:i.replaceAll(Yi,""):u=c==null?void 0:c.replaceAll(Yi,""),(u==null?void 0:u[0])==="$"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length)),l.filter=u}return l},yc=a=>{var d,D,w,q,A,j;let l=[],r=[],n=[],i=[],o=[],p=[],c="",u=a==null?void 0:a[0];(u==null?void 0:u[0])==="*"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length));let m=le.analyzeSplitToContent(u,":");(d=m==null?void 0:m.filter(O=>(O==null?void 0:O[0])!=="{"&&(O==null?void 0:O[0])!=="["))==null||d.forEach(O=>{var _,x,b;(O==null?void 0:O[(O==null?void 0:O.length)-1])===":"&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1));let E=le.analyzerSplitToWord(O,"(");if((E==null?void 0:E.length)>1){c=(_=vc(E))==null?void 0:_.filter;let S=O==null?void 0:O.replace(c,"");if(n.push(S),(c==null?void 0:c[0])==="("){c=c==null?void 0:c.slice(1,(c==null?void 0:c.length)-1);let I=[];(x=le.analyzeSplitToContent(c,","))==null||x.forEach(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==null?void 0:R.slice(1,(R==null?void 0:R.length)-1)),(R==null?void 0:R[0])!=="@"&&(R="@"+R),I.push(hn(R))}),c=I==null?void 0:I.join(",")}else c=hn(c);c=(b=le.analyzeSplitToContent(c,","))==null?void 0:b.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)),c!=null&&c.includes("@ShowHide=Hide")&&p.push(S),i=[...i,...c]}else n.push(E==null?void 0:E[0])});let g=(D=m==null?void 0:m.filter(O=>(O==null?void 0:O[0])==="{"))==null?void 0:D[0],y=(w=m==null?void 0:m.filter(O=>(O==null?void 0:O[0])==="["))==null?void 0:w[0];return l=Li(y??""),l!=null&&l.every(O=>Array.isArray(O))&&(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)),o=(q=le.analyzeSplitToContent(g,"@"))==null?void 0:q[1],o="@"+o,g=g==null?void 0:g.replace(o,""),o=hn(o),o=(A=le.analyzeSplitToContent(o,","))==null?void 0:A.map(O=>((O==null?void 0:O[(O==null?void 0:O.length)-1])===","&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1)),O)),(g==null?void 0:g[0])==="{"&&(g=g==null?void 0:g.slice(1,(g==null?void 0:g.length)-1)),g=(j=le.analyzeSplitToContent(g,","))==null?void 0:j.map(O=>((O==null?void 0:O[(O==null?void 0:O.length)-1])===","&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1)),O)),g==null||g.forEach((O,E)=>{var ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja;let _=[],x=[],b=[],S="",I="",R=!1,re,X=[],me=[],ue=[],U="Input",W=[],Z=[];if(O!=null&&O.includes("==")){re=(ae=O==null?void 0:O.split("=="))==null?void 0:ae[0];let sa=(ve=O==null?void 0:O.split("=="))==null?void 0:ve[1],Pe="";((ze=le.analyzeSplitToContent(sa,"$"))==null?void 0:ze.length)>1&&((te=le.analyzeSplitToContent(sa,"$"))==null?void 0:te[0])!=="$"?(Pe=(N=le.analyzeSplitToContent(sa,"$"))==null?void 0:N[0],Pe=Pe==null?void 0:Pe.slice(0,(Pe==null?void 0:Pe.length)-1)):((se=le.analyzeSplitToContent(sa,"}"))==null?void 0:se.length)>1&&(Pe=(G=le.analyzeSplitToContent(sa,"}"))==null?void 0:G[1]);let ma=sa==null?void 0:sa.replace(Pe,"");if((Pe==null?void 0:Pe[0])==="("&&(Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1)),(fe=le.analyzeSplitToContent(Pe,","))==null||fe.forEach(Qe=>{var $e;(Qe==null?void 0:Qe[0])!=="@"&&(Qe="@"+Qe),(Qe==null?void 0:Qe[(Qe==null?void 0:Qe.length)-1])===","&&(Qe=Qe==null?void 0:Qe.slice(0,(Qe==null?void 0:Qe.length)-1));let Oe=hn(Qe);($e=le.analyzeSplitToContent(Oe,","))==null||$e.forEach(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)),_.push(ne)})}),(ma==null?void 0:ma[0])==="$"&&(ma=ma==null?void 0:ma.slice(1,ma==null?void 0:ma.length)),ma!=null&&ma.includes("&")){let Qe=ma;if((ma==null?void 0:ma[0])==="("){let $e=(we=le.analyzeSplitToContent(ma,"&"))==null?void 0:we.map(ne=>((ne==null?void 0:ne[(ne==null?void 0:ne.length)-1])==="&"&&(ne=ne==null?void 0:ne.slice(0,(ne==null?void 0:ne.length)-1)),ne));Qe=$e==null?void 0:$e[1],$e=$e==null?void 0:$e[0],($e==null?void 0:$e[0])!=="@"&&($e="@"+$e),S=hn($e)}(Qe==null?void 0:Qe[0])==="&"&&(Qe=Qe==null?void 0:Qe.slice(1,Qe==null?void 0:Qe.length)),I=(qe=(_e=Qe==null?void 0:Qe.replace("(",ml))==null?void 0:_e.split(ml))==null?void 0:qe[0],b=(P=(ra=Qe==null?void 0:Qe.replace("(",ml))==null?void 0:ra.split(ml))==null?void 0:P[1],b=[b==null?void 0:b.slice(0,(b==null?void 0:b.length)-1)],U="Input"}else{let Qe=(Ke=ma==null?void 0:ma.replace("*",ml))==null?void 0:Ke.split(ml);X=(Me=Qe==null?void 0:Qe[0])==null?void 0:Me.split(":"),me=(Ie=(Le=le.analyzeSplitToContent(Qe==null?void 0:Qe[1],":"))==null?void 0:Le.filter((Oe,$e)=>{var ne,We;return $e!==((We=(ne=Qe==null?void 0:Qe[1])==null?void 0:ne.split(":"))==null?void 0:We.length)-1}))==null?void 0:Ie.map(Oe=>((Oe==null?void 0:Oe[(Oe==null?void 0:Oe.length)-1])===":"&&(Oe=Oe==null?void 0:Oe.slice(0,(Oe==null?void 0:Oe.length)-1)),Oe)),ue=(De=(de=le.analyzeSplitToContent(Qe==null?void 0:Qe[1],":"))==null?void 0:de.filter((Oe,$e)=>{var ne,We;return $e===((We=(ne=Qe==null?void 0:Qe[1])==null?void 0:ne.split(":"))==null?void 0:We.length)-1}))==null?void 0:De[0],ue=(Ea=(Xe=ue==null?void 0:ue.replaceAll("{",""))==null?void 0:Xe.replaceAll("}",""))==null?void 0:Ea.split(":"),U="Select"}if(re!=null&&re.includes("@")){let Qe=le.analyzeSplitToContent(re,"@");re=Qe==null?void 0:Qe[0],re=re==null?void 0:re.slice(0,(re==null?void 0:re.length)-1),Qe="@"+(Qe==null?void 0:Qe[1]),Qe=hn(Qe),_=(Ge=le.analyzeSplitToContent(Qe,","))==null?void 0:Ge.map(Oe=>((Oe==null?void 0:Oe[(Oe==null?void 0:Oe.length)-1])===","&&(Oe=Oe==null?void 0:Oe.slice(0,(Oe==null?void 0:Oe.length)-1)),Oe))}}else if((($=le.analyzeSplitToContent(O,"="))==null?void 0:$.length)>1)if(U="Select",re=(ee=(V=O==null?void 0:O.replace("=",ml))==null?void 0:V.split(ml))==null?void 0:ee[0],!(O!=null&&O.includes("If")))W=(he=(ce=O==null?void 0:O.replace("=",ml))==null?void 0:ce.split(ml))==null?void 0:he[1],W=W==null?void 0:W.split("||");else{let sa=(ia=(pa=O==null?void 0:O.replace("=",ml))==null?void 0:pa.split(ml))==null?void 0:ia[1];Z=(Ve=le.analyzeSplitToContent(sa,")"))==null?void 0:Ve.filter(Pe=>!(Pe!=null&&Pe.includes("If"))),Z=Z==null?void 0:Z.map(Pe=>((Pe==null?void 0:Pe[0])==="("&&(Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1)),Pe=Pe==null?void 0:Pe.split("||"),Pe)),x=(ya=le.analyzeSplitToContent(sa,")"))==null?void 0:ya.filter(Pe=>Pe==null?void 0:Pe.includes("If")),x=x==null?void 0:x.map(Pe=>((Pe==null?void 0:Pe[0])==="|"&&(Pe=Pe==null?void 0:Pe.slice(2,Pe==null?void 0:Pe.length)),(Pe==null?void 0:Pe[0])==="("&&(Pe=Pe==null?void 0:Pe.slice(1,(Pe==null?void 0:Pe.length)-1)),(Pe==null?void 0:Pe[0])!=="@"&&(Pe="@"+Pe),Pe))}else if(((Ca=le.analyzeSplitToContent(O,"@"))==null?void 0:Ca.length)>1){re=(Ce=le.analyzeSplitToContent(O,"@"))==null?void 0:Ce[0],(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 sa="@"+((Fa=le.analyzeSplitToContent(O,"@"))==null?void 0:Fa[1]);sa=hn(sa),_=(Ta=le.analyzeSplitToContent(sa,","))==null?void 0:Ta.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)),_!=null&&_.find(Pe=>Pe==null?void 0:Pe.includes("@Type"))&&(U=(ja=(fa=_==null?void 0:_.find(Pe=>Pe==null?void 0:Pe.includes("@Type")))==null?void 0:fa.split("="))==null?void 0:ja[1])}else re=O;_!=null&&_.includes("@ShowHide=Hide")&&(R=!0),r.push({prop:re,label:re,value:"",menuPath:X,groups:me,columns:ue,type:U,options:W,allContents:Z,filters:_,width:g==null?void 0:g.length,isFormColHidden:R,filterContents:x,functionName:I,functionRelatedWords:b,calculatorFilter:S})}),{groupName:n,groupFilters:i,formContents:r,contents:l,filter:o,hideContents:p}},Li=a=>{var n,i;if(!a||typeof a!="string")return[];let l=[],r=a.slice(1,(a==null?void 0:a.length)-1);if((r==null?void 0:r[0])!=="[")(n=le.analyzeSplitToContent(r,","))==null||n.forEach(o=>{(o==null?void 0:o[(o==null?void 0:o.length)-1])===","&&(o=o.slice(0,(o==null?void 0:o.length)-1)),l.push(o??"")}),(r==null?void 0:r[(r==null?void 0:r.length)-1])===","&&l.push("");else{let o=[];(i=le.analyzeSplitToContent(r,","))==null||i.forEach(p=>{(p==null?void 0:p[(p==null?void 0:p.length)-1])===","&&(p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1)),o.push(Li(p))}),l=o}return l},Ct=(a,l)=>{var j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va;let r,n=[],i=[],o=[],p=[],c=[],u=[],m=[],g="Input",y,d="",D="",w="",q=[],A="";if(a!=null&&a.includes("==")||a!=null&&a.includes("=")||a!=null&&a.includes("@")||a!=null&&a.includes("||"))if(r=(j=a==null?void 0:a.split("=="))==null?void 0:j[0],y=(O=a==null?void 0:a.split("=="))==null?void 0:O[0],g="Select",a!=null&&a.includes("=")&&!(a!=null&&a.includes("=="))&&!((x=(_=(E=a==null?void 0:a.replace("=",ml))==null?void 0:E.split(ml))==null?void 0:_[1])!=null&&x.includes("If")))if(r=le.analyzeSplitToContent(a,"@"),r=r==null?void 0:r[0],(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=(S=(b=r==null?void 0:r.replace("=",ml))==null?void 0:b.split(ml))==null?void 0:S[0],r!=null&&r.includes("&")&&(r=(R=(I=r==null?void 0:r.replace("&",ml))==null?void 0:I.split(ml))==null?void 0:R[0]),y=r,((re=le.analyzeSplitToContent(a,"@"))==null?void 0:re.length)>1&&!(a!=null&&a.includes("||"))){if(!(a!=null&&a.includes("&"))){let Ae=(X=le.analyzeSplitToContent(a,"@"))==null?void 0:X[1];if((Ae==null?void 0:Ae[0])!=="@"&&(Ae="@"+Ae),Ae=hn(Ae),D=Ae,D!=null&&D.includes("@Type")){let Be=le.analyzeSplitToContent(D,",");Be=Be==null?void 0:Be.map(Ye=>((Ye==null?void 0:Ye[(Ye==null?void 0:Ye.length)-1])===","&&(Ye=Ye==null?void 0:Ye.slice(0,(Ye==null?void 0:Ye.length)-1)),Ye)),Be=(me=Be==null?void 0:Be.filter(Ye=>Ye==null?void 0:Ye.includes("@Type")))==null?void 0:me[0],g=(ue=Be==null?void 0:Be.split("="))==null?void 0:ue[1],g==="File"&&(g="Upload")}else g="Input"}}else if(a!=null&&a.includes("||")){let Ae=[];n=(Z=(W=(U=le.analyzeSplitToContent(a,"="))==null?void 0:U[1])==null?void 0:W.split("||"))==null?void 0:Z.map(Ye=>{var ye,$a,wl,Qa;let Ee=Ye;if(Ee!=null&&Ee.includes("@")){let Pl="@"+(($a=(ye=Ee==null?void 0:Ee.replace("@",ml))==null?void 0:ye.split(ml))==null?void 0:$a[1]);Ee=(Qa=(wl=Ee==null?void 0:Ee.replace("@",ml))==null?void 0:wl.split(ml))==null?void 0:Qa[0],Pl=ri(Pl),Ae.push(Pl)}return{label:Ee==null?void 0:Ee.replaceAll("'",""),value:Ee==null?void 0:Ee.replaceAll("'","")}}),(Ae==null?void 0:Ae.length)>0&&(D="("+(Ae==null?void 0:Ae.join("||"))+")");let Be=(ae=le.analyzeSplitToContent(a,"="))==null?void 0:ae[0];if(Be!=null&&Be.includes("@")){(Be==null?void 0:Be[(Be==null?void 0:Be.length)-1])==="="&&(Be=Be==null?void 0:Be.slice(0,(Be==null?void 0:Be.length)-1));let Ye=(ve=le.analyzeSplitToContent(Be,"@"))==null?void 0:ve[1];Ye="@"+Ye,Ye=ri(Ye),D=D===""?Ye:Ye+","+D}}else g="Input",d=(N=(te=(ze=a==null?void 0:a.replace("=",ml))==null?void 0:ze.split(ml))==null?void 0:te[1])==null?void 0:N.replaceAll("'","");else if((G=(se=le.analyzeSplitToContent(a,"="))==null?void 0:se[1])!=null&&G.includes("||")){let Ae=(fe=le.analyzeSplitToContent(a,"="))==null?void 0:fe[0];if((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!=null&&Ae.includes("@")){let ye=(we=le.analyzeSplitToContent(Ae,"@"))==null?void 0:we[1];ye="@"+ye,D=ri(ye),r=(P=(_e=le.analyzeSplitToContent(Ae,"@"))==null?void 0:_e[0])==null?void 0:P.slice(0,((ra=(qe=le.analyzeSplitToContent(Ae,"@"))==null?void 0:qe[0])==null?void 0:ra.length)-1),y=(Ie=(Ke=le.analyzeSplitToContent(Ae,"@"))==null?void 0:Ke[0])==null?void 0:Ie.slice(0,((Le=(Me=le.analyzeSplitToContent(Ae,"@"))==null?void 0:Me[0])==null?void 0:Le.length)-1)}else r=Ae,y=Ae;let Be=(de=le.analyzeSplitToContent(a,"="))==null?void 0:de[1];Be=le.analyzeSplitToContent(Be,")");let Ye=Be==null?void 0:Be.filter(ye=>!(ye!=null&&ye.includes("If")));Ye==null||Ye.forEach(ye=>{(ye==null?void 0:ye[0])==="("&&(ye=ye==null?void 0:ye.slice(1,(ye==null?void 0:ye.length)-1)),i==null||i.push(ye==null?void 0:ye.split("||"))});let Ee=Be==null?void 0:Be.filter(ye=>ye==null?void 0:ye.includes("If"));Ee=Ee==null?void 0:Ee.map(ye=>((ye==null?void 0:ye[0])==="|"&&(ye==null?void 0:ye[1])==="|"&&(ye=ye==null?void 0:ye.slice(2,ye==null?void 0:ye.length)),(ye==null?void 0:ye[0])==="("&&(ye=ye==null?void 0:ye.slice(1,(ye==null?void 0:ye.length)-1)),(ye==null?void 0:ye[0])!=="@"&&(ye="@"+ye),ye)),o=Ee}else{let Ae=a==null?void 0:a.split("=="),Be=(De=Ae==null?void 0:Ae.filter(Ye=>(Ye==null?void 0:Ye.includes("$"))&&(Ye==null?void 0:Ye[0])!=="{"))==null?void 0:De[0];if(Be&&!(Be!=null&&Be.includes("&"))){let Ye=(Ea=le.analyzeSplitToContent(Be,")"))==null?void 0:Ea[((Xe=le.analyzeSplitToContent(Be,")"))==null?void 0:Xe.length)-1],Ee=(Ge=Ye==null?void 0:Ye.replace("*",ml))==null?void 0:Ge.split(ml),ye=(Ee==null?void 0:Ee[0])===""?l==null?void 0:l.value:Ee==null?void 0:Ee[0];(ye==null?void 0:ye[0])==="("&&(ye=($=le.analyzeSplitToContent(ye,")"))==null?void 0:$[1]),ye=(ee=(V=ye==null?void 0:ye.replaceAll("{",""))==null?void 0:V.replaceAll("}",""))==null?void 0:ee.replaceAll(Yi,""),(ye==null?void 0:ye[0])==="$"&&(ye=(ce=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length))==null?void 0:ce.replaceAll(":","/")),p=ye==null?void 0:ye.split("/");let $a=(pa=(he=Ee==null?void 0:Ee[1])==null?void 0:he.replace("{",ml))==null?void 0:pa.split(ml),wl=$a==null?void 0:$a[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(":"),u=(Ca=(ya=(Ve=(ia=$a==null?void 0:$a[1])==null?void 0:ia.replace("}",ml))==null?void 0:Ve.split(ml))==null?void 0:ya[0])==null?void 0:Ca.split(":");let Qa="";((Ce=le.analyzeSplitToContent(Be,")"))==null?void 0:Ce.length)>1&&(Qa=(Fa=le.analyzeSplitToContent(Be,")"))==null?void 0:Fa[0]),Qa&&Qa!==""&&((Qa==null?void 0:Qa[0])!=="@"&&(Qa="@"+Qa),D=ri(Qa))}if(Ae!=null&&Ae.some(Ye=>Ye==null?void 0:Ye.includes("&"))){let Ye=(Ta=Ae==null?void 0:Ae.filter($a=>$a==null?void 0:$a.includes("&")))==null?void 0:Ta[0];Ye=(fa=le.analyzeSplitToContent(Ye,"&"))==null?void 0:fa.map($a=>(($a==null?void 0:$a[($a==null?void 0:$a.length)-1])==="&"&&($a=$a==null?void 0:$a.slice(0,($a==null?void 0:$a.length)-1)),$a)),w=(Pe=(sa=(ja=Ye==null?void 0:Ye[1])==null?void 0:ja.replace("(",ml))==null?void 0:sa.split(ml))==null?void 0:Pe[0];let Ee=(ma=le.analyzeSplitToContent(Ye==null?void 0:Ye[1],")"))==null?void 0:ma[0];Ee=(Oe=(Qe=Ee==null?void 0:Ee.replace("(",ml))==null?void 0:Qe.split(ml))==null?void 0:Oe[1],Ee=Ee==null?void 0:Ee.slice(0,(Ee==null?void 0:Ee.length)-1),(Ee==null?void 0:Ee[0])==="{"&&(Ee=Ee==null?void 0:Ee.slice(1,Ee==null?void 0:Ee.length)),(Ee==null?void 0:Ee[(Ee==null?void 0:Ee.length)-1])==="}"&&(Ee=Ee==null?void 0:Ee.slice(0,(Ee==null?void 0:Ee.length)-1)),q=Ee==null?void 0:Ee.split(",");let ye=Ye==null?void 0:Ye[0];ye&&ye!==""&&((ye==null?void 0:ye[0])!=="@"&&(ye="@"+ye),A=ri(ye))}else if(!Be&&(($e=Ae==null?void 0:Ae.filter(Ye=>(Ye==null?void 0:Ye[0])==="{"))==null?void 0:$e.length)>0){let Ye=Ae==null?void 0:Ae[(Ae==null?void 0:Ae.length)-1];Ye=Ye==null?void 0:Ye.slice(1,(Ye==null?void 0:Ye.length)-1),Ye=le.analyzeSplitToContent(Ye,","),Ye=Ye==null?void 0:Ye.map(Ee=>((Ee==null?void 0:Ee[(Ee==null?void 0:Ee.length)-1])===","&&(Ee=Ee==null?void 0:Ee.slice(0,(Ee==null?void 0:Ee.length)-1)),Ee)),Ye=Ye==null?void 0:Ye.map(Ee=>{var ye,$a,wl,Qa;if(Ee=Ee==null?void 0:Ee.replaceAll("$",""),Ee!=null&&Ee.includes("{")){let Pl="";Ee=Ee==null?void 0:Ee.replaceAll("{","");let gl=Ee==null?void 0:Ee.split("}");Pl=(($a=(ye=gl==null?void 0:gl[0])==null?void 0:ye.split(":"))==null?void 0:$a[0])+":"+(gl==null?void 0:gl[1]),Ee=Pl,Ee=Ee+":"}if(Ee!=null&&Ee.includes(Yi)){let Pl="",gl=Ee==null?void 0:Ee.split(Yi);Pl=((Qa=(wl=gl==null?void 0:gl[0])==null?void 0:wl.split(":"))==null?void 0:Qa[0])+":"+(gl==null?void 0:gl[1]),Ee=Pl,Ee=Ee+":"}return Ee=Ee==null?void 0:Ee.replaceAll(":","/"),Ee}),m=Ye}else!((ne=Ae==null?void 0:Ae[1])!=null&&ne.includes("$"))&&((We=Ae==null?void 0:Ae[1])==null?void 0:We[0])!=="("&&u.push(Ae==null?void 0:Ae[1])}else r=(na=a==null?void 0:a.split("&"))==null?void 0:na[0],y=(va=a==null?void 0:a.split("&"))==null?void 0:va[0];return(n==null?void 0:n.length)===0&&(i==null?void 0:i.length)===0&&(p==null?void 0:p.length)===0&&g==="Select"&&(g="Input"),{label:r,prop:y,options:n,allContents:i,filterContents:o,menus:p,groups:c,words:u,align:"center",formType:g,filter:D,functionName:w,functionRelatedWords:q,calculatorFilter:A,relatedPages:m,value:d}},Bo=(a,l)=>{var n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z;let r=[];if((a==null?void 0:a[0])==="{"&&(a==null?void 0:a[(a==null?void 0:a.length)-1])==="}"&&!((p=(o=(i=(n=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1))==null?void 0:n.replace(":",ml))==null?void 0:i.split(ml))==null?void 0:o[0])!=null&&p.includes(","))){let ae=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1),ve=(c=ae==null?void 0:ae.replace(":",ml))==null?void 0:c.split(ml);if(((u=le.analyzeSplitToContent(ve==null?void 0:ve[1],"="))==null?void 0:u.length)===1){let ze=ve==null?void 0:ve[0],te=[];(y=le.analyzeSplitToContent((g=ve==null?void 0:ve[1])==null?void 0:g.slice(1,((m=ve==null?void 0:ve[1])==null?void 0:m.length)-1),","))==null||y.forEach(N=>{var se,G;((se=le.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)),te=[...te,...Bo(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)),te.push((G=Bo(N,l))==null?void 0:G[0]))}),r==null||r.push({label:ze,prop:ze,children:te,align:"center"})}else{let ze=[];if(((d=le.analyzeSplitToContent(ae,"="))==null?void 0:d.length)>=2){let N=(D=le.analyzeSplitToContent(ae,"="))==null?void 0:D[1],se=(w=le.analyzeSplitToContent(N,"/"))==null?void 0:w.map(G=>((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)),G));ze=se==null?void 0:se.map(G=>(G=Li(G),G))}let te=(_=(E=(O=(j=(A=(q=ae==null?void 0:ae.replace("{",ml))==null?void 0:q.split(ml))==null?void 0:A[1])==null?void 0:j.replace("}",ml))==null?void 0:O.split(ml))==null?void 0:E[0])==null?void 0:_.split(",");te==null||te.forEach((N,se)=>{(ze==null?void 0:ze.length)>0&&se===0?r==null||r.push({label:N,prop:N,align:"center",formType:"Select",relatedContents:ze==null?void 0:ze.map(G=>{let fe={};return te==null||te.forEach((we,_e)=>{fe[we]=G==null?void 0:G[_e]}),fe}),options:ze==null?void 0:ze.map(G=>({label:G==null?void 0:G[0],value:G==null?void 0:G[0]})),mainKey:!0}):r==null||r.push({label:N,prop:N,align:"center"})})}}else if((a==null?void 0:a[0])==="{")if(((x=le.analyzeSplitToContent(a,"="))==null?void 0:x.length)===2&&((S=(b=le.analyzeSplitToContent(a,"="))==null?void 0:b[1])==null?void 0:S[0])==="["){let ae=[];if(((I=le.analyzeSplitToContent(a,"="))==null?void 0:I.length)>=2){let ze=(R=le.analyzeSplitToContent(a,"="))==null?void 0:R[1],te=(X=(re=le.analyzeSplitToContent(ze,"|"))==null?void 0:re.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));ae=te==null?void 0:te.map(N=>(N=Li(N),N))}let ve=(ue=(me=a==null?void 0:a.replace("}",ml))==null?void 0:me.split(ml))==null?void 0:ue[0];ve=(U=ve==null?void 0:ve.slice(1,ve==null?void 0:ve.length))==null?void 0:U.split(","),ve==null||ve.forEach((ze,te)=>{(ae==null?void 0:ae.length)>0&&te===0?r==null||r.push({label:ze,prop:ze,align:"center",formType:"Select",relatedContents:ae==null?void 0:ae.map(N=>{let se={};return ve==null||ve.forEach((G,fe)=>{se[G]=N==null?void 0:N[fe]}),se}),options:ae==null?void 0:ae.map(N=>({label:N==null?void 0:N[0],value:N==null?void 0:N[0]})),mainKey:!0}):r==null||r.push({label:ze,prop:ze,align:"center"})})}else(W=le.analyzeSplitToContent(a,","))==null||W.forEach(ae=>{var ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe;if((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==null?void 0:ae[0])==="{"){let Oe=le.analyzeSplitToContent(ae,"="),$e=Oe==null?void 0:Oe[(Oe==null?void 0:Oe.length)-1],ne=[],We=[],na=[],va="",Ae="",Be=[],Ye=[],Ee=(ve=$e==null?void 0:$e.replace("*",ml))==null?void 0:ve.split(ml),ye=(Ee==null?void 0:Ee[0])===""?l==null?void 0:l.value:Ee==null?void 0:Ee[0];ye=le.analyzeSplitToContent(ye,")");let $a="";if((ye==null?void 0:ye.length)>1&&((ze=ye==null?void 0:ye[0])==null?void 0:ze[0])!=="&"&&($a=ye==null?void 0:ye[0],($a==null?void 0:$a[0])!=="@"&&($a="@"+$a),Ae=$a??""),ye=(te=ye==null?void 0:ye.filter(al=>(al==null?void 0:al[0])==="$"))==null?void 0:te[0],((N=le.analyzeSplitToContent(ye,"}"))==null?void 0:N.length)>1&&((G=(se=le.analyzeSplitToContent(ye,"}"))==null?void 0:se[1])==null?void 0:G[0])==="("&&($a=(fe=le.analyzeSplitToContent(ye,"}"))==null?void 0:fe[1],($a==null?void 0:$a[0])!=="@"&&($a="@"+$a),Ae!==""&&(Ae=Ae+","),Ae=Ae+$a),(we=ye==null?void 0:ye.slice(1,(ye==null?void 0:ye.length)-1))!=null&&we.includes("$")||(ye=(_e=le.analyzeSplitToContent(ye,"}"))==null?void 0:_e[0]),(ye==null?void 0:ye[0])==="$"&&(ye=(qe=ye==null?void 0:ye.replace("{",""))==null?void 0:qe.replace("}",":"),ye=(ra=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length))==null?void 0:ra.replaceAll(":","/")),ye!=null&&ye.includes("$")){let al=(P=ye==null?void 0:ye.split("$"))==null?void 0:P[0];al=(Ke=al==null?void 0:al.split("/"))==null?void 0:Ke[0],ye=al+"/"+((Me=ye==null?void 0:ye.split("$"))==null?void 0:Me[1])+"/"}ne=(ye==null?void 0:ye.split("/"))??[];let wl=(Ie=(Le=Ee==null?void 0:Ee[1])==null?void 0:Le.replace("{",ml))==null?void 0:Ie.split(ml);if((Xe=(De=(de=Ee==null?void 0:Ee[1])==null?void 0:de.split("(@"))==null?void 0:De[0])!=null&&Xe.includes("&&")||($=(Ge=(Ea=Ee==null?void 0:Ee[1])==null?void 0:Ea.split("@"))==null?void 0:Ge[0])!=null&&$.includes("&&")){let al=(V=Ee==null?void 0:Ee[1])!=null&&V.includes("(@")?(he=(ce=(ee=Ee==null?void 0:Ee[1])==null?void 0:ee.split("(@"))==null?void 0:ce[0])==null?void 0:he.split("&&"):(Ve=(ia=(pa=Ee==null?void 0:Ee[1])==null?void 0:pa.split("@"))==null?void 0:ia[0])==null?void 0:Ve.split("&&");Be=al==null?void 0:al.map(Wa=>{var Gl,Kl;return(Wa==null?void 0:Wa[0])==="*"&&(Wa=Wa==null?void 0:Wa.slice(1,Wa==null?void 0:Wa.length)),Wa=(Kl=(Gl=Wa==null?void 0:Wa.replace("{",ml))==null?void 0:Gl.split(ml))==null?void 0:Kl[0],(Wa==null?void 0:Wa[(Wa==null?void 0:Wa.length)-1])===":"&&(Wa=Wa==null?void 0:Wa.slice(0,(Wa==null?void 0:Wa.length)-1)),Wa=Wa==null?void 0:Wa.split(":"),Wa});let Hl=[];al==null||al.forEach((Wa,Gl)=>{var Kl,Zl;(Wa==null?void 0:Wa[0])==="*"&&(Wa=Wa==null?void 0:Wa.slice(1,Wa==null?void 0:Wa.length)),Wa=(Zl=(Kl=Wa==null?void 0:Wa.replace("{",ml))==null?void 0:Kl.split(ml))==null?void 0:Zl[1],(Wa==null?void 0:Wa[(Wa==null?void 0:Wa.length)-1])==="}"&&(Wa=Wa==null?void 0:Wa.slice(0,(Wa==null?void 0:Wa.length)-1)),Wa=Wa==null?void 0:Wa.split(","),Hl.push(Gl===0?(Wa==null?void 0:Wa.length)-1:Wa==null?void 0:Wa.length),Ye=[...Ye,...Wa]}),Hl=(ya=le.prefixSum(Hl))==null?void 0:ya.map(Wa=>Wa==null?void 0:Wa.total),Be=Be==null?void 0:Be.map((Wa,Gl)=>({number:Hl==null?void 0:Hl[Gl],contents:Wa}))}let Qa=wl==null?void 0:wl[0];(Qa==null?void 0:Qa[(Qa==null?void 0:Qa.length)-1])===":"&&(Qa=Qa==null?void 0:Qa.slice(0,(Qa==null?void 0:Qa.length)-1)),We=(Qa==null?void 0:Qa.split(":"))??[],na=((Ta=(Fa=(Ce=(Ca=wl==null?void 0:wl[1])==null?void 0:Ca.replace("}",ml))==null?void 0:Ce.split(ml))==null?void 0:Fa[0])==null?void 0:Ta.split(","))??[];let Pl=(ja=Oe==null?void 0:Oe[0])==null?void 0:ja.slice(1,((fa=Oe==null?void 0:Oe[0])==null?void 0:fa.length)-2);Ae&&Ae!==""&&(va=ri(Ae));let gl=(sa=le.analyzeSplitToContent(va,","))==null?void 0:sa.map(al=>((al==null?void 0:al[(al==null?void 0:al.length)-1])===","&&(al=al==null?void 0:al.slice(0,(al==null?void 0:al.length)-1)),al)),jl=[];gl!=null&&gl.find(al=>al==null?void 0:al.includes("@MainParam"))&&(gl=gl==null?void 0:gl.find(al=>al==null?void 0:al.includes("@MainParam")),gl=(ma=(Pe=gl==null?void 0:gl.replace("=",ml))==null?void 0:Pe.split(ml))==null?void 0:ma[1],gl=gl==null?void 0:gl.slice(1,(gl==null?void 0:gl.length)-1),jl=le.analyzeSplitToContent(gl,",")),(Qe=Pl==null?void 0:Pl.split(","))==null||Qe.forEach((al,Hl)=>{var Wa,Gl,Kl,Zl,Sl,dr;if(((Wa=le.analyzeSplitToContent(al,"@"))==null?void 0:Wa.length)>1){let ga=(Gl=le.analyzeSplitToContent(al,"@"))==null?void 0:Gl[1];ga="@"+ga,va=ri(ga),al=(Kl=le.analyzeSplitToContent(al,"@"))==null?void 0:Kl[0],(al==null?void 0:al[(al==null?void 0:al.length)-1])==="@"&&(al=al==null?void 0:al.slice(0,(al==null?void 0:al.length)-1))}r.push({label:al,prop:al,align:"center",menus:ne,groups:(Be==null?void 0:Be.length)===0?We:(Zl=Be==null?void 0:Be.find(ga=>(ga==null?void 0:ga.number)>=Hl))==null?void 0:Zl.contents,words:(Ye==null?void 0:Ye.length)===0?(Sl=na==null?void 0:na[Hl])==null?void 0:Sl.split(":"):(dr=Ye==null?void 0:Ye[Hl])==null?void 0:dr.split(":"),formType:(ne==null?void 0:ne.length)>0?"Select":"Input",mainKey:!!(Hl===0||jl!=null&&jl.find(ga=>ga===al)),filter:va,isMainPath:(Be==null?void 0:Be.findIndex(ga=>(ga==null?void 0:ga.number)>=Hl))===0})})}else r.push({label:ae,prop:ae,align:"center"})});else{let ae=(Z=le.analyzeSplitToContent(a,","))==null?void 0:Z.map(ve=>((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));ae==null||ae.forEach(ve=>{r.push(Ct(ve,l))})}return r},kp=(a,l)=>{var p,c,u,m,g;let r=a;if(!a)return;let n="";((p=le.analyzeSplitToContent(a,"}"))==null?void 0:p.length)>1&&(r=(c=le.analyzeSplitToContent(a,"}"))==null?void 0:c[0],n=(u=le.analyzeSplitToContent(a,"}"))==null?void 0:u[1]),(a==null?void 0:a[0])==="{"&&(a==null?void 0:a[(a==null?void 0:a.length)-1])==="}"&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1));let i=[],o=[];return i.push({label:"排序",prop:"sort"}),i.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(m=le.analyzeSplitToContent(r,","))==null||m.forEach(y=>{var d;(y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),(y==null?void 0:y[0])==="{"?(d=Bo(y,l))==null||d.forEach(D=>{i.push(D)}):i.push(Ct(y,l))}),i!=null&&i.some(y=>{var d;return(d=y==null?void 0:y.prop)==null?void 0:d.includes("@")})&&(i=i==null?void 0:i.filter(y=>{var d;return!((d=y==null?void 0:y.prop)!=null&&d.includes("@"))})),n!==""&&((n==null?void 0:n[0])=="{"&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1)),(g=le.analyzeSplitToContent(n,","))==null||g.forEach(y=>{var d;(y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),(y==null?void 0:y[0])==="{"?(d=Bo(y,l))==null||d.forEach(D=>{o.push(D)}):o.push(Ct(y,l))})),{columns:i,secondColumns:o}},hn=a=>{var l,r,n,i,o;if(a!=null&&a.includes("@Filter")||a!=null&&a.includes("@Condition")||a!=null&&a.includes("@If"))return a;{let p=(r=(l=a==null?void 0:a.replace("(",ml))==null?void 0:l.split(ml))==null?void 0:r[1],c=(i=(n=a==null?void 0:a.replace("(",ml))==null?void 0:n.split(ml))==null?void 0:i[0];return p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1),p=(o=le.analyzeSplitToContent(p,","))==null?void 0:o.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==null?void 0:u[0])==="("&&(u=u==null?void 0:u.slice(1,(u==null?void 0:u.length)-1)),c+u)),p=p==null?void 0:p.join(","),a!=null&&a.includes("@Quote")&&(p!=null&&p.includes("@QuoteType")||(p=p===""?p+"@QuoteType=Manual":p+",@QuoteType=Manual"),p!=null&&p.includes("@QuoteSonSync")||(p=p===""?p+"@QuoteSonSync=No":p+",@QuoteSonSync=No"),p!=null&&p.includes("@QuoteFatherSync")||(p=p===""?p+"@QuoteFatherSync=Yes":p+",@QuoteFatherSync=Yes")),p}},gs=a=>{let l=a==null?void 0:a.map(r=>{var n,i;return{menus:r==null?void 0:r.menus,content:((n=r==null?void 0:r.menus)==null?void 0:n.join("/"))+ml+((i=r==null?void 0:r.groups)==null?void 0:i.join("/"))}});return l=l==null?void 0:l.filter(r=>{var n;return(r==null?void 0:r.menus)&&((n=r==null?void 0:r.menus)==null?void 0:n.length)>0}),l=l==null?void 0:l.map(r=>r==null?void 0:r.content),l=[...new Set(l)],l=l==null?void 0:l.map(r=>{var n,i;return{menus:(n=r==null?void 0:r.split(ml))==null?void 0:n[0],groups:((i=r==null?void 0:r.split(ml))==null?void 0:i[1])??[]}}),l},bs=a=>{var r;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=(r=le.analyzeSplitToContent(l,","))==null?void 0:r.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==null?void 0:n[0])!=="@"&&(n="@"+n),(n==null?void 0:n[1])==="("&&(n=hn(n)),n)),l==null?void 0:l.join(",")},gc=(a,l,r="")=>{var E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe;let n=[],i=[],o=[],p="",c="",u="",m=[],g=[],y=[],d=[],D="";if(((E=a==null?void 0:a[0])==null?void 0:E[0])!=="*"&&((_=a==null?void 0:a[0])==null?void 0:_[0])!=="$"&&!((x=a==null?void 0:a[0])!=null&&x.includes("$")))return;((b=a==null?void 0:a[0])==null?void 0:b[0])!=="*"&&((S=a==null?void 0:a[0])==null?void 0:S[0])!=="$"&&(p=(I=le.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:I[0],(p==null?void 0:p[0])!=="@"&&(p="@"+p),p=ri(p),u=(R=le.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:R[1],(u==null?void 0:u[0])==="$"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length)),u=u==null?void 0:u.replaceAll(":","/"));let q=le.analyzeSplitToContent(a==null?void 0:a[0],":");if(n=(re=q==null?void 0:q.filter($e=>($e==null?void 0:$e[0])!=="{"&&($e==null?void 0:$e[0])!=="["))==null?void 0:re.join(""),c=(X=a==null?void 0:a[0])==null?void 0:X.replace(n,""),(n==null?void 0:n[0])==="("&&(n=""),D=(me=q==null?void 0:q.filter($e=>($e==null?void 0:$e[0])!=="["))==null?void 0:me.join(""),D=(ue=a==null?void 0:a[0])==null?void 0:ue.replace(D,""),c=c==null?void 0:c.replace(D,""),(n==null?void 0:n[0])==="*"&&(n=n==null?void 0:n.slice(1,n==null?void 0:n.length)),(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)),((U=le.analyzeSplitToContent(c,"@"))==null?void 0:U.length)>1&&(p=(W=le.analyzeSplitToContent(c,"@"))==null?void 0:W[1],(p==null?void 0:p[(p==null?void 0:p.length)-1])===":"&&(p=p==null?void 0:p.slice(0,(p==null?void 0:p.length)-1)),p="@"+p,p=hn(p),c=(Z=le.analyzeSplitToContent(c,"@"))==null?void 0:Z[0],c=c==null?void 0:c.slice(0,(c==null?void 0:c.length)-1)),((ae=le.analyzeSplitToContent(n,"@"))==null?void 0:ae.length)>1){p!==""&&(p=p+",");let $e=(ve=le.analyzeSplitToContent(n,"@"))==null?void 0:ve[1];$e="@"+$e,$e=hn($e),p=p+$e,n=(ze=le.analyzeSplitToContent(n,"@"))==null?void 0:ze[0]}if((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=n===""?[]:n==null?void 0:n.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)),r!==""){let $e=(te=le.analyzeSplitToContent(r,")"))==null?void 0:te[0],ne=le.analyzeSplitToContent(r,")");ne=ne==null?void 0:ne.filter((Ae,Be)=>Be!==(ne==null?void 0:ne.length)-1),ne=ne==null?void 0:ne.join("");let We=(N=le.analyzeSplitToContent(r,"@"))==null?void 0:N[1];u=(G=(se=le.analyzeSplitToContent(r,"@"))==null?void 0:se[0])==null?void 0:G.replace(ne,""),(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));let na="";if(na=le.analyzeSplitToContent(r,")"),na=na==null?void 0:na.filter((Ae,Be)=>Be!==0&&Be!==(na==null?void 0:na.length)-1),((fe=le.analyzeSplitToContent(r,"&"))==null?void 0:fe.length)>1&&(na==null?void 0:na.length)<2&&($e="",u="",na=le.analyzeSplitToContent(r,")")),na!=null&&na.some(Ae=>(Ae==null?void 0:Ae[0])===":")){let Ae=(we=na==null?void 0:na.filter(Be=>(Be==null?void 0:Be[0])===":"))==null?void 0:we.join("");D=Ae==null?void 0:Ae.slice(1,Ae==null?void 0:Ae.length),na=na==null?void 0:na.filter(Be=>(Be==null?void 0:Be[0])!==":")}(na==null?void 0:na.length)>0&&((_e=le.chunkArray(na))==null||_e.forEach(Ae=>{var $a,wl,Qa,Pl,gl;let Be="",Ye=[],Ee="";(Ae==null?void 0:Ae.length)>1&&(Ee="@"+(Ae==null?void 0:Ae[0]),Ee=hn(Ee));let ye=(Ae==null?void 0:Ae.length)===1?Ae==null?void 0:Ae[0]:Ae==null?void 0:Ae[1];ye=ye==null?void 0:ye.slice(1,ye==null?void 0:ye.length),Be=(wl=($a=ye==null?void 0:ye.replace("(",ml))==null?void 0:$a.split(ml))==null?void 0:wl[0],ye=(Pl=(Qa=ye==null?void 0:ye.replace("(",ml))==null?void 0:Qa.split(ml))==null?void 0:Pl[1],ye=ye==null?void 0:ye.slice(0,(ye==null?void 0:ye.length)-1),Ye=(gl=le.analyzeSplitToContent(ye,","))==null?void 0:gl.map(jl=>((jl==null?void 0:jl[(jl==null?void 0:jl.length)-1])===","&&(jl=jl==null?void 0:jl.slice(0,(jl==null?void 0:jl.length)-1)),jl)),m.push({functionName:Be,functionRelatedWords:Ye,calculatorFilter:Ee})})),$e=bs($e),We=bs(We);let va=$e??"";if(va!==""&&(va=va+","),va=va+We,(va==null?void 0:va[(va==null?void 0:va.length)-1])===","&&(va=va==null?void 0:va.slice(0,(va==null?void 0:va.length)-1)),va!==""&&p!==""&&(p=p+","),p=p+va,(u==null?void 0:u[0])==="$"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length)),u=(qe=le.analyzeSplitToContent(u,":"))==null?void 0:qe.filter((Ae,Be)=>{var Ye;return!((Ae==null?void 0:Ae[0])==="{"&&Be===((Ye=le.analyzeSplitToContent(u,":"))==null?void 0:Ye.length)-1)}),u=u==null?void 0:u.join(""),(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)),p!=null&&p.includes("@Sync")||(p=p===""?p+"@Sync=(Yes,Yes)":p+",@Sync=(Yes,Yes)"),u!=null&&u.includes("$")){let Ae=(P=(ra=u==null?void 0:u.replace("*",ml))==null?void 0:ra.split(ml))==null?void 0:P[1],Be=(Me=(Ke=u==null?void 0:u.replace("*",ml))==null?void 0:Ke.split(ml))==null?void 0:Me[0];Be=Be==null?void 0:Be.split("$"),Be=((Ie=(Le=Be==null?void 0:Be[0])==null?void 0:Le.split(":"))==null?void 0:Ie[0])+":"+(Be==null?void 0:Be[1])+":",u=Be+"*"+Ae}else u=(de=u==null?void 0:u.replaceAll("{",""))==null?void 0:de.replaceAll("}","");(u==null?void 0:u[0])===":"&&(D=u==null?void 0:u.slice(1,u==null?void 0:u.length),u="")}p!==""&&p&&(p="("+p+")"),p=u+p,((De=le.analyzeSplitToContent(c,"}"))==null?void 0:De.length)>1&&(c=(Xe=le.analyzeSplitToContent(c,"}"))==null?void 0:Xe.filter($e=>($e==null?void 0:$e[0])!=="@"),c=c==null?void 0:c.join(""));let A=kp(c,l);o=c===""?[]:(A==null?void 0:A.columns)??[],d=le.getColumnChild(o);let j=le.getColumnChild(o);o!=null&&o.some($e=>{var ne;return Array.isArray($e==null?void 0:$e.children)&&((ne=$e==null?void 0:$e.children)==null?void 0:ne.length)>0})&&(o=[o]),i=D?Li(D):[],!(i!=null&&i.every($e=>Array.isArray($e)))&&(i==null?void 0:i.length)>0&&(i=[i]),(i==null?void 0:i.length)>0&&(Array.isArray(i==null?void 0:i[0])&&((Ea=i==null?void 0:i[0])!=null&&Ea.every($e=>Array.isArray($e)))?i=i==null?void 0:i.map(($e,ne)=>($e=$e.map((We,na)=>(We.unshift("{}"),We.unshift((na+1).toString()),We)),$e)):i=i==null?void 0:i.map(($e,ne)=>($e.unshift("{}"),$e.unshift((ne+1).toString()),$e))),A!=null&&A.secondColumns&&((Ge=A==null?void 0:A.secondColumns)==null?void 0:Ge.length)>0&&((i==null?void 0:i.length)>0?i=i==null?void 0:i.map(($e,ne)=>{var We,na;return Array.isArray($e==null?void 0:$e[0])?$e=$e==null?void 0:$e.map((va,Ae)=>{var Be,Ye;return va.unshift((Ye=(Be=A==null?void 0:A.secondColumns)==null?void 0:Be[Ae])==null?void 0:Ye.prop),va}):$e.unshift((na=(We=A==null?void 0:A.secondColumns)==null?void 0:We[ne])==null?void 0:na.prop),$e}):i=($=A==null?void 0:A.secondColumns)==null?void 0:$.map(($e,ne)=>($e=[$e==null?void 0:$e.label],$e.push(ne),$e)),o.unshift({label:"",prop:"disabled",sortable:!1})),d=d==null?void 0:d.map($e=>{var ne,We;return{menus:$e==null?void 0:$e.menus,content:((ne=$e==null?void 0:$e.menus)==null?void 0:ne.join("/"))+ml+((We=$e==null?void 0:$e.groups)==null?void 0:We.join("/"))}});let O=[];if(((ee=(V=p==null?void 0:p.replace("(",ml))==null?void 0:V.split(ml))==null?void 0:ee[0])!==""&&(O=(he=(ce=p==null?void 0:p.replace("(",ml))==null?void 0:ce.split(ml))==null?void 0:he[0],O=[O],O=O==null?void 0:O.map($e=>{var We,na,va;let ne=$e==null?void 0:$e.split("*");return{menus:(We=ne==null?void 0:ne[0])==null?void 0:We.split(":"),content:((na=ne==null?void 0:ne[0])==null?void 0:na.replaceAll(":","/"))+ml+((va=ne==null?void 0:ne[1])==null?void 0:va.replaceAll(":","/"))}}),d=[...d,...O]),d=d==null?void 0:d.filter($e=>{var ne;return($e==null?void 0:$e.menus)&&((ne=$e==null?void 0:$e.menus)==null?void 0:ne.length)>0}),d=d==null?void 0:d.map($e=>$e==null?void 0:$e.content),d=[...new Set(d)],d=d==null?void 0:d.map($e=>{var ne,We;return{menus:(ne=$e==null?void 0:$e.split(ml))==null?void 0:ne[0],groups:((We=$e==null?void 0:$e.split(ml))==null?void 0:We[1])??[]}}),g=j==null?void 0:j.filter($e=>{var ne;return($e==null?void 0:$e.filter)&&((ne=$e==null?void 0:$e.filter)==null?void 0:ne.includes("@Sync"))}),(g==null?void 0:g.length)>0&&(g=g==null?void 0:g.filter($e=>{var ne,We,na,va;return(va=(na=(We=(ne=le.analyzeSplitToContent($e==null?void 0:$e.filter,","))==null?void 0:ne.find(Ae=>Ae==null?void 0:Ae.includes("@Sync")))==null?void 0:We.split(","))==null?void 0:na[0])==null?void 0:va.includes("Yes")}),g=gs(g)),y=j==null?void 0:j.filter($e=>{var ne;return($e==null?void 0:$e.filter)&&((ne=$e==null?void 0:$e.filter)==null?void 0:ne.includes("@Sync"))}),(y==null?void 0:y.length)>0&&(y=y==null?void 0:y.filter($e=>{var ne,We,na,va;return(va=(na=(We=(ne=le.analyzeSplitToContent($e==null?void 0:$e.filter,","))==null?void 0:ne.find(Ae=>Ae==null?void 0:Ae.includes("@Sync")))==null?void 0:We.split(","))==null?void 0:na[1])==null?void 0:va.includes("Yes")}),y=gs(y)),p!==""&&(p!=null&&p.includes("@Sync"))&&(p==null?void 0:p[0])!=="("){let $e=(pa=p==null?void 0:p.replace("(",ml))==null?void 0:pa.split(ml),ne=$e==null?void 0:$e[1];if(ne=ne==null?void 0:ne.slice(0,(ne==null?void 0:ne.length)-1),ne=le.analyzeSplitToContent(ne,","),(ya=(Ve=(ia=ne==null?void 0:ne.find(We=>We==null?void 0:We.includes("@Sync")))==null?void 0:ia.split(","))==null?void 0:Ve[0])!=null&&ya.includes("Yes")){let We=$e==null?void 0:$e[0];We=[{menus:(Ce=(Ca=We==null?void 0:We.split("*"))==null?void 0:Ca[0])==null?void 0:Ce.replaceAll(":","/"),groups:((Ta=(Fa=We==null?void 0:We.split("*"))==null?void 0:Fa[1])==null?void 0:Ta.split(":"))??[]}],g=[...g,...We]}if((sa=(ja=(fa=ne==null?void 0:ne.find(We=>We==null?void 0:We.includes("@Sync")))==null?void 0:fa.split(","))==null?void 0:ja[1])!=null&&sa.includes("Yes")){let We=$e==null?void 0:$e[0];We=[{menus:(ma=(Pe=We==null?void 0:We.split("*"))==null?void 0:Pe[0])==null?void 0:ma.replaceAll(":","/"),groups:((Oe=(Qe=We==null?void 0:We.split("*"))==null?void 0:Qe[1])==null?void 0:Oe.split(":"))??[]}],y=[...y,...We]}}return{groupName:n,tableColumns:o,tableFilter:p,tableContents:i,columns:(A==null?void 0:A.secondColumns)??[],relatedQuotes:d,fatherSyncContents:g,sonSyncContents:y,calculatorFilters:m}},bc=(a,l)=>(a=a==null?void 0:a.map((r,n)=>{var i,o,p,c;if(Array.isArray(r))r=r==null?void 0:r.map(u=>{var m,g,y,d;return u!=null&&u.isMainPath||(((m=u==null?void 0:u.children)==null?void 0:m.length)>0?u.children=bc(u.children,l):((g=u==null?void 0:u.menus)==null?void 0:g.length)>0&&!((y=r==null?void 0:r[0])!=null&&y.isMainPath)&&(u.menus=(d=u.menus)==null?void 0:d.map((D,w)=>{var q,A;return((q=u.menus)==null?void 0:q.length)-1===w&&D===""&&(l==null?void 0:l.parentContent)+"/"!==((A=u.menus)==null?void 0:A.join("/"))&&(D=l==null?void 0:l.value),u}),u.bindMenus=u.menus)),u});else{if(n===0&&((i=r.menus)==null?void 0:i.length)>0&&(r.mainKey=!0),r!=null&&r.isMainPath)return r;((o=r.menus)==null?void 0:o.length)>0&&!((p=a==null?void 0:a[0])!=null&&p.isMainPath)&&(r.menus=(c=r.menus)==null?void 0:c.map((u,m)=>{var g,y;return((g=r.menus)==null?void 0:g.length)-1===m&&u===""&&(l==null?void 0:l.parentContent)+"/"!==((y=r.menus)==null?void 0:y.join("/"))&&(u=l==null?void 0:l.value),u}),r.bindMenus=r.menus)}return r}),a),xp=(a,l)=>(a=a==null?void 0:a.map(r=>((r==null?void 0:r.key)==="header"&&(r.contents=bc(r.contents,l)),r)),a),Dt=(a,l)=>{let r=a;return Array.isArray(r==null?void 0:r[0])?r=r==null?void 0:r.map(n=>(n=Dt(n,l),n)):r=r==null?void 0:r.map(n=>{var i,o;return n!=null&&n.children&&((i=n==null?void 0:n.children)==null?void 0:i.length)>0?n.children=Dt(n==null?void 0:n.children,l):n!=null&&n.words&&((o=n==null?void 0:n.words)==null?void 0:o.length)>0&&(l!=null&&l.find(p=>{var c,u,m,g;return((g=(c=n==null?void 0:n.prop)==null?void 0:c.split("."))==null?void 0:g[((m=(u=n==null?void 0:n.prop)==null?void 0:u.split("."))==null?void 0:m.length)-1])===p}))&&(n.mainKey=!0),n}),r};let Nr="$R";const wp=M.useUnit(M.pinia),{selectTitle:xn}=M.storeToRefs(wp),_p=M.useMenuState(M.pinia),{localFiles:ks}=M.storeToRefs(_p),Sp=M.useLoginState(M.pinia),{loginUserInfo:gt}=M.storeToRefs(Sp),Mn=[{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:"@TextBackRGBA",value:"onTextBackRGBA",order:1},{key:"@Position",value:"onPosition",order:4},{key:"@ColumnNum",value:"onColumnNum",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 vi=(a=>(a[a.ORDINARY=1]="ORDINARY",a[a.BLOCK=2]="BLOCK",a[a.TEXT=3]="TEXT",a))(vi||{});const Ep=async a=>{var r,n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O;let l=le.analyzeSplitToContent((a==null?void 0:a.filter)??"",")");if((l==null?void 0:l.length)>1){let E=l==null?void 0:l[0];E=E==null?void 0:E.slice(1,(E==null?void 0:E.length)-1),E=(n=(r=E==null?void 0:E.replace("(",Nr))==null?void 0:r.split(Nr))==null?void 0:n[1],E="("+((i=E==null?void 0:E.replaceAll("{",""))==null?void 0:i.replaceAll("}",""));let _=le.calculatorAndToOr(E),x=Object.keys(_==null?void 0:_[0]);if(E=_,((o=x==null?void 0:x[0])==null?void 0:o[0])==="$"){let b=(c=x==null?void 0:x[0])==null?void 0:c.slice(1,((p=x==null?void 0:x[0])==null?void 0:p.length)-1),S=(m=(u=b==null?void 0:b.split("*"))==null?void 0:u[0])==null?void 0:m.replaceAll(".","/"),I=(d=(y=(g=b==null?void 0:b.split("*"))==null?void 0:g[1])==null?void 0:y.split("."))==null?void 0:d[0],R=await Hr(S,!1);R=(D=R==null?void 0:R.filter(U=>(U==null?void 0:U.name)===I))==null?void 0:D[0];let re=(q=(w=R==null?void 0:R.compData)==null?void 0:w.find(U=>(U==null?void 0:U.key)==="tableContents"))==null?void 0:q.contents;E=E==null?void 0:E.map(U=>{var Z,ae;let W={};for(let ve in U)if((ve==null?void 0:ve[0])==="$"){let ze=(ae=ve==null?void 0:ve.split("."))==null?void 0:ae[((Z=ve==null?void 0:ve.split("."))==null?void 0:Z.length)-1];W[ze]=U==null?void 0:U[ve]}else W[ve]=U==null?void 0:U[ve];return W});let X=(j=(A=R==null?void 0:R.compData)==null?void 0:A.find(U=>(U==null?void 0:U.key)==="header"))==null?void 0:j.contents;X=(O=le.getEqualChild(X))==null?void 0:O.filter(U=>(U==null?void 0:U.label)!=="操作");let ue=le.tableToForm(re,X);if(E==null||E.forEach(U=>{var W,Z,ae,ve,ze;for(let te in U)(U==null?void 0:U[te])==="LoginUser"&&(U[te]=((W=gt.value)==null?void 0:W.姓名)||((Z=gt.value)==null?void 0:Z.account)||((ae=gt.value)==null?void 0:ae.账号)),!((ve=ue==null?void 0:ue[0])!=null&&ve.find(N=>{var se;return(N==null?void 0:N.key)===te||((se=N==null?void 0:N.key)==null?void 0:se.includes(te))}))&&!(ue!=null&&ue.find(N=>{var se;return(N==null?void 0:N.key)===te||((se=N==null?void 0:N.key)==null?void 0:se.includes(te))}))||(((ze=U[te])==null?void 0:ze[0])!=="!"?ue=ue==null?void 0:ue.filter(N=>{var se,G;return((se=N==null?void 0:N.find(fe=>{var we;return(fe==null?void 0:fe.key)===te||((we=fe==null?void 0:fe.key)==null?void 0:we.includes(te))}))==null?void 0:se.value)===U[te]||Array.isArray(U==null?void 0:U[te])&&((G=U==null?void 0:U[te])==null?void 0:G.find(fe=>{var we;return((we=N==null?void 0:N.find(_e=>{var qe;return(_e==null?void 0:_e.key)===te||((qe=_e==null?void 0:_e.key)==null?void 0:qe.includes(te))}))==null?void 0:we.value)===fe}))}):ue=ue==null?void 0:ue.filter(N=>{var se;return((se=N==null?void 0:N.find(G=>{var fe;return(G==null?void 0:G.key)===te||((fe=G==null?void 0:G.key)==null?void 0:fe.includes(te))}))==null?void 0:se.value)!==U[te]}))}),(ue==null?void 0:ue.length)===0){let U=a==null?void 0:a.contents;return U.push({key:"hideContents",contents:!0}),U}}}return 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;return l.push({key:"textBackRGBA",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Dp=a=>{var l,r,n,i,o;if((a==null?void 0:a.filter)!==void 0&&(a==null?void 0:a.filter)!==null&&(a==null?void 0:a.filter)!==""){let p=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=le.analyzeSplitToContent(c,","))==null?void 0:l.map(y=>((y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),y));let u=(c==null?void 0:c[2])??"Center",m=(c==null?void 0:c[0])??"Picture";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=(r=le.analyzeSplitToContent(c,","))==null?void 0:r.map(y=>((y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),y));let g=(o=(i=(n=ks.value)==null?void 0:n.filter(y=>{var d;return(y==null?void 0:y.path)===((d=a==null?void 0:a.groupName)==null?void 0:d[0])}))==null?void 0:i[0])==null?void 0:o.children;return g=(g==null?void 0:g.filter(y=>c==null?void 0:c.find(d=>d===(y==null?void 0:y.name))))??[],(c==null?void 0:c.length)>0&&(g==null?void 0:g.length)===0&&(c==null||c.forEach(y=>{var D,w;let d=(w=(D=ks.value)==null?void 0:D.find(q=>(q==null?void 0:q.path)===y))==null?void 0:w.url;g.push({url:d})})),g[0]={...g==null?void 0:g[0],position:u,fileType:m},p.push({key:"backGround",contents:g}),p}return a==null?void 0:a.contents},Tp=a=>{const l=xc(a==null?void 0:a.filter);return l?rf(a==null?void 0:a.contents,{position:l}):a==null?void 0:a.contents},Bp=a=>{let l=parseInt(a==null?void 0:a.filter);l=1/l;let r=a==null?void 0:a.contents;return r.push({key:"rowPosition",contents:l}),r},Np=a=>{const l=xc(a==null?void 0:a.filter);if(!l)return a==null?void 0:a.contents;let r=a==null?void 0:a.contents;return r.push({key:"numPosition",contents:l}),r},Ap=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 r=Number(a==null?void 0:a.filter);return l.push({key:"textSize",contents:Number.isNaN(r)?a==null?void 0:a.filter:r}),l}return a==null?void 0:a.contents},zp=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},Mp=a=>{var r;return(a==null?void 0:a.filter.toUpperCase())==="ALL"||(a==null?void 0:a.filter.toUpperCase())==="NONE"?a==null?void 0:a.contents:(r=a==null?void 0:a.contents)==null?void 0:r.map(n=>{var i;return(n==null?void 0:n.key)==="tableContents"&&(n.contents=(i=n.contents)==null?void 0:i.slice(0,parseInt(a==null?void 0:a.filter))),n})},Ip=async a=>{var l,r,n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U;if((a==null?void 0:a.filter)==="Random")return(l=a==null?void 0:a.contents)==null?void 0:l.map(Z=>((Z==null?void 0:Z.key)==="tableContents"&&(Z.contents=le.shuffle(Z.contents)),Z));if((a==null?void 0:a.filter)==="Auto"){let W=(n=(r=a==null?void 0:a.contents)==null?void 0:r.find(fe=>(fe==null?void 0:fe.key)==="header"))==null?void 0:n.contents;Array.isArray(W==null?void 0:W[0])&&(W=W==null?void 0:W[0]),W=le.getColumnChild(W);let Z=W==null?void 0:W.filter(fe=>(fe==null?void 0:fe.filter)&&(fe==null?void 0:fe.filter)!==""),ae=new Map,ve=[];Z==null||Z.forEach(fe=>{var we,_e;ae.get((we=fe==null?void 0:fe.menus)==null?void 0:we.join("/"))||(ae.set((_e=fe==null?void 0:fe.menus)==null?void 0:_e.join("/"),fe),ve.push(fe))});let ze=(o=(i=xn==null?void 0:xn.value)==null?void 0:i.find(fe=>(fe==null?void 0:fe.condition)==="child"))==null?void 0:o.value,te=ve==null?void 0:ve.map(fe=>{var we,_e,qe;return fe=(we=fe==null?void 0:fe.menus)==null?void 0:we.join("/"),(fe==null?void 0:fe[(fe==null?void 0:fe.length)-1])==="/"&&((qe=(_e=xn==null?void 0:xn.value)==null?void 0:_e.find(ra=>(ra==null?void 0:ra.condition)==="child"))==null?void 0:qe.parentContent)+"/"!==fe?fe=fe+ze:(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}),N=ve==null?void 0:ve.map(fe=>fe==null?void 0:fe.groups),se=te==null?void 0:te.map(async fe=>{let we=await Hr(fe,!1);return{path:fe,contents:we}});se=await Promise.all(se);let G=se==null?void 0:se.map((fe,we)=>{var qe,ra,P,Ke,Me,Le,Ie;let _e=(qe=fe==null?void 0:fe.contents)==null?void 0:qe.filter(de=>{var De,Xe;return(de==null?void 0:de.name)===((Xe=N==null?void 0:N[we])==null?void 0:Xe[((De=N==null?void 0:N[we])==null?void 0:De.length)-1])});return _e=(Ke=(P=(ra=_e==null?void 0:_e[0])==null?void 0:ra.compData)==null?void 0:P.find(de=>(de==null?void 0:de.key)==="tableContents"))==null?void 0:Ke.contents,(fe==null?void 0:fe.path)===((Le=(Me=xn==null?void 0:xn.value)==null?void 0:Me.find(de=>(de==null?void 0:de.condition)==="child"))==null?void 0:Le.parentContent)&&(_e=((Ie=_e==null?void 0:_e.map(de=>{for(let De in de)if(de[De]===ze)return de}))==null?void 0:Ie.filter(de=>de))??[]),_e??[]});if(G=G==null?void 0:G.map(fe=>(fe=fe==null?void 0:fe.map(we=>{var qe;let _e={};for(let ra in we)if(Z!=null&&Z.find(P=>{var Ke,Me;return((Me=(Ke=P==null?void 0:P.words)==null?void 0:Ke[0])==null?void 0:Me.replaceAll("'",""))===ra})){let P=(qe=Z==null?void 0:Z.find(Ke=>{var Me,Le;return((Le=(Me=Ke==null?void 0:Ke.words)==null?void 0:Me[0])==null?void 0:Le.replaceAll("'",""))===ra}))==null?void 0:qe.prop;_e[P]=we==null?void 0:we[ra]}return _e}),fe)),G=le.cartesianProduct(G),Array.isArray(G==null?void 0:G[0])&&(G=G==null?void 0:G[0]),(G==null?void 0:G.length)>0&&((y=(c=(p=Z==null?void 0:Z[0])==null?void 0:p.menus)==null?void 0:c.join("/"))==null?void 0:y[((g=(m=(u=Z==null?void 0:Z[0])==null?void 0:u.menus)==null?void 0:m.join("/"))==null?void 0:g.length)-1])==="/")return(d=a==null?void 0:a.contents)==null?void 0:d.map(we=>{var _e;return(we==null?void 0:we.key)==="tableContents"&&(G==null?void 0:G.length)>0&&(we.contents=((_e=we.contents)==null?void 0:_e.length)>0?we.contents:G),we})}if((a==null?void 0:a.filter)==="Manual"){let W=[],Z=[],ae=(w=(D=a==null?void 0:a.contents)==null?void 0:D.find(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:w.contents;(ae==null?void 0:ae[(ae==null?void 0:ae.length)-1])===")"?ae=(A=(q=ae==null?void 0:ae.replace("(",Nr))==null?void 0:q.split(Nr))==null?void 0:A[0]:ae="",ae!==""&&(W=((O=(j=ae==null?void 0:ae.split("*"))==null?void 0:j[0])==null?void 0:O.split(":"))??[],Z=((S=(b=(x=(_=(E=ae==null?void 0:ae.split("*"))==null?void 0:E[1])==null?void 0:_.replace("{",Nr))==null?void 0:x.split(Nr))==null?void 0:b[0])==null?void 0:S.split(":"))??[]);let ve=(R=(I=a==null?void 0:a.contents)==null?void 0:I.find(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:R.contents;ve=(X=(re=ve==null?void 0:ve.replace("(",Nr))==null?void 0:re.split(Nr))==null?void 0:X[1],ve=ve==null?void 0:ve.slice(0,(ve==null?void 0:ve.length)-1);let ze=(me=a==null?void 0:a.contents)==null?void 0:me.map(N=>{var se,G,fe,we,_e,qe,ra,P,Ke;return(N==null?void 0:N.key)==="header"&&((se=N==null?void 0:N.contents)!=null&&se.every(Me=>(Me==null?void 0:Me.mainKey)!==!0)&&Array.isArray(N==null?void 0:N.contents)&&!Array.isArray((G=N==null?void 0:N.contents)==null?void 0:G[0])?N.contents=(fe=N==null?void 0:N.contents)==null?void 0:fe.map((Me,Le)=>{var Ie,de,De;return Me!=null&&Me.isMainPath||(Le===0?(Me.mainKey=!0,Me.formType="Select",Me.bindMenus=W,Me.groups=((Ie=Me.groups)==null?void 0:Ie.length)===0?Z:Me.groups,Me.words=((de=Me.words)==null?void 0:de.length)===0?[Me==null?void 0:Me.prop]:Me.words,Me.filter=ve,(!(Me!=null&&Me.menus)||((De=Me==null?void 0:Me.menus)==null?void 0:De.length)===0)&&(Me.menus=W)):(Me.mainKey=!1,Me.bindMenus=W)),Me}):Array.isArray((we=N==null?void 0:N.contents)==null?void 0:we[0])&&((ra=(qe=(_e=N==null?void 0:N.contents)==null?void 0:_e[0])==null?void 0:qe.filter(()=>(W==null?void 0:W.length)>0))==null?void 0:ra.length)>0&&(N.contents[0]=(Ke=(P=N==null?void 0:N.contents)==null?void 0:P[0])==null?void 0:Ke.map((Me,Le)=>{var Ie,de,De;return Me!=null&&Me.isMainPath||(Le===0?(Me.mainKey=!0,Me.formType="Select",Me.bindMenus=W,Me.groups=((Ie=Me.groups)==null?void 0:Ie.length)===0?Z:Me.groups,Me.words=((de=Me.words)==null?void 0:de.length)===0?[Me==null?void 0:Me.prop]:Me.words,Me.filter=ve,(!(Me!=null&&Me.menus)||Array.isArray(Me==null?void 0:Me.menus)&&((De=Me==null?void 0:Me.menus)==null?void 0:De.length)===0)&&(W==null?void 0:W.length)>0&&(Me.menus=W)):(Me.mainKey=!1,Me.bindMenus=W)),Me}))),N}),te=(ue=ze==null?void 0:ze.find(N=>(N==null?void 0:N.key)==="header"))==null?void 0:ue.contents;if(Array.isArray(te==null?void 0:te[0])&&(te=te==null?void 0:te[0]),te=le.getColumnChild(te),te!=null&&te.some(N=>{var se,G;return((G=N==null?void 0:N.menus)==null?void 0:G[((se=N==null?void 0:N.menus)==null?void 0:se.length)-1])===""})){let N=(U=xn==null?void 0:xn.value)==null?void 0:U.find(se=>(se==null?void 0:se.condition)==="child");ze=xp(ze,N)}return ze}if((a==null?void 0:a.filter)==="Chart"){let W=a==null?void 0:a.contents;return W.push({key:"newType",contents:"Chart"}),W}if((a==null?void 0:a.filter)==="Carousel"){let W=a==null?void 0:a.contents;return W.push({key:"newType",contents:"Carousel"}),W}return a==null?void 0:a.contents},Op=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},Lp=a=>{var n,i,o,p,c,u,m,g,y,d,D,w;let l=a==null?void 0:a.filter;if(l!=null&&l.includes("*")&&(l="({"+((i=(n=l==null?void 0:l.replace(":",Nr))==null?void 0:n.split(Nr))==null?void 0:i[1])),l=(o=l==null?void 0:l.replaceAll("{",""))==null?void 0:o.replaceAll("}",""),(c=(p=l==null?void 0:l.split("="))==null?void 0:p[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 q=(u=l==null?void 0:l.split("="))==null?void 0:u[0],A=(m=l==null?void 0:l.split("="))==null?void 0:m[1];(g=A==null?void 0:A.slice(1,A==null?void 0:A.length))!=null&&g.includes("$")&&(A=(D=(d=(y=xn==null?void 0:xn.value)==null?void 0:y.filter(j=>(j==null?void 0:j.condition)==="child"))==null?void 0:d[0])==null?void 0:D.value),l=q+"="+A}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 r=le.calculatorAndToOr(l);if((r==null?void 0:r.length)>0){let q=[];return r==null||r.forEach(j=>{let O={};for(let E in j){let _=E;_!=null&&_.includes("[")||(O[_]=j[E])}q.push(O)}),(w=a==null?void 0:a.contents)==null?void 0:w.map(j=>{var E,_,x;let O=(_=(E=a==null?void 0:a.contents)==null?void 0:E.find(b=>(b==null?void 0:b.key)==="header"))==null?void 0:_.contents;if(O=(x=le.getEqualChild(O))==null?void 0:x.filter(b=>(b==null?void 0:b.label)!=="操作"),(j==null?void 0:j.key)==="tableContents"){let S=le.tableToForm(j==null?void 0:j.contents,O);q==null||q.forEach(I=>{var R,re;for(let X in I)!((R=S==null?void 0:S[0])!=null&&R.find(me=>{var ue;return(me==null?void 0:me.key)===X||((ue=me==null?void 0:me.key)==null?void 0:ue.includes(X))}))&&!(S!=null&&S.find(me=>{var ue;return(me==null?void 0:me.key)===X||((ue=me==null?void 0:me.key)==null?void 0:ue.includes(X))}))||(((re=I[X])==null?void 0:re[0])!=="!"?S=S==null?void 0:S.filter(me=>{var ue,U;return((ue=me==null?void 0:me.find(W=>{var Z;return(W==null?void 0:W.key)===X||((Z=W==null?void 0:W.key)==null?void 0:Z.includes(X))}))==null?void 0:ue.value)===I[X]||Array.isArray(I==null?void 0:I[X])&&((U=I==null?void 0:I[X])==null?void 0:U.find(W=>{var Z;return((Z=me==null?void 0:me.find(ae=>{var ve;return(ae==null?void 0:ae.key)===X||((ve=ae==null?void 0:ae.key)==null?void 0:ve.includes(X))}))==null?void 0:Z.value)===W}))}):S=S==null?void 0:S.filter(me=>{var ue;return((ue=me==null?void 0:me.find(U=>{var W;return(U==null?void 0:U.key)===X||((W=U==null?void 0:U.key)==null?void 0:W.includes(X))}))==null?void 0:ue.value)!==(I[X]==="!"?"":I==null?void 0:I[X])}))}),(S==null?void 0:S.length)===0?j.contents=[]:j.contents=S==null?void 0:S.map(I=>{let R={};return I==null||I.forEach(re=>{R[re==null?void 0:re.key]=re==null?void 0:re.value}),R})}return j})}return a==null?void 0:a.contents},Rp=a=>a==null?void 0:a.contents,$p=a=>a==null?void 0:a.contents,Vp=a=>{var l,r,n,i;if((a==null?void 0:a.filter)!==""&&(a!=null&&a.filter)){let o=(n=(r=a==null?void 0:a.filter)==null?void 0:r.slice(1,((l=a==null?void 0:a.filter)==null?void 0:l.length)-1))==null?void 0:n.split(",");return(i=a==null?void 0:a.contents)==null?void 0:i.map(c=>((c==null?void 0:c.key)==="header"&&(c.contents=Dt(c.contents,o)),c))}return a==null?void 0:a.contents},Fp=a=>{var r,n,i,o,p;let l=(a==null?void 0:a.filter)??"";if(l!==""){let c=(n=(r=l==null?void 0:l.replace("(",Nr))==null?void 0:r.split(Nr))==null?void 0:n[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=le.analyzeSplitToContent(c,","))==null?void 0:i.map(y=>((y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),y));let u=c==null?void 0:c[0];(u==null?void 0:u[0])==="("&&(u=u==null?void 0:u.slice(1,(u==null?void 0:u.length)-1));let m=(c==null?void 0:c[1])??"Up",g=(o=a==null?void 0:a.contents)==null?void 0:o.map(y=>{var d,D;if(m==="Up"){if((y==null?void 0:y.key)==="extraButton"){let w=(d=u==null?void 0:u.split(","))==null?void 0:d.map(q=>({label:q,prop:q}));y.contents=[...w??[],...y.contents]}}else if(m==="Line"&&(y==null?void 0:y.key)==="rowButton"){let w=(D=u==null?void 0:u.split(","))==null?void 0:D.map(q=>({label:q,prop:q}));y.contents=[...w??[],...y.contents]}return y});if(m==="Bottom"||m==="Down"){let y=(p=u==null?void 0:u.split(","))==null?void 0:p.map(d=>({label:d,prop:d}));g.push({key:"bottomButton",contents:y})}return g}return a==null?void 0:a.contents},Pp=a=>a==null?void 0:a.contents,jp=a=>{var r;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!==""?(r=a==null?void 0:a.contents)==null?void 0:r.map(i=>{var o;return(i==null?void 0:i.key)==="rowButton"&&(i.contents=(o=l==null?void 0:l.split(","))==null?void 0:o.map(p=>({label:p,prop:p}))),i}):a==null?void 0:a.contents},Hp=a=>{var r;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 n=a==null?void 0:a.contents,i=(r=l==null?void 0:l.split(","))==null?void 0:r.map(o=>({label:o,prop:o}));return n.push({key:"bottomButton",contents:i}),n}return a==null?void 0:a.contents},Up=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(r=>{var n;return(r==null?void 0:r.key)==="formContent"&&(r.contents=(n=r.contents)==null?void 0:n.map(i=>(i.isNoClick=!0,i))),r}),l!=null&&l.find(r=>(r==null?void 0:r.key)==="tableContents")&&(l==null||l.push({key:"isEdit",contents:!1}),l=l==null?void 0:l.filter(r=>(r==null?void 0:r.key)!=="extraButton"&&(r==null?void 0:r.key)!=="rowButton")),l}return a==null?void 0:a.contents},qp=a=>{var l;if(a!=null&&a.filter){const r=parseInt(a==null?void 0:a.filter);return!r||Number.isNaN(r)?a==null?void 0:a.contents:(l=a==null?void 0:a.contents)==null?void 0:l.map(i=>{var o;return(i==null?void 0:i.key)==="formContent"&&(i.contents=(o=i.contents)==null?void 0:o.map(p=>(p.width=r,p))),i})}return a==null?void 0:a.contents},Wp=a=>{var l,r,n,i;if(((l=a==null?void 0:a.filter)==null?void 0:l[0])!=="["){const o=parseInt(a==null?void 0:a.filter);return!o||Number.isNaN(o)?a==null?void 0:a.contents:(r=a==null?void 0:a.contents)==null?void 0:r.map(c=>{var u;return(c==null?void 0:c.key)==="formContent"&&(c.contents=(u=c.contents)==null?void 0:u.map(m=>(m.width=o,m))),c})}if(((n=a==null?void 0:a.filter)==null?void 0:n[0])==="["){let o=Li(a==null?void 0:a.filter),p=Array.isArray(o)?o.map(u=>parseInt(u)).filter(u=>!!u&&!Number.isNaN(u)):[];return p.length?(i=a==null?void 0:a.contents)==null?void 0:i.map(u=>{if((u==null?void 0:u.key)==="formContent"){const m=u.contents??[];u.contents=m.map((g,y)=>{const d=y+1;let D=0,w=0;for(let A=0;A<p.length;A++){if(w+=p[A],d<=w){D=A;break}A===p.length-1&&(D=p.length-1)}const q=p[D]||p[p.length-1]||1;return g.width=q,g})}return u}):a==null?void 0:a.contents}return a==null?void 0:a.contents},Gp=a=>{var l;if((a==null?void 0:a.filter)!==""){let 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=r==null?void 0:r.split(","),(l=a==null?void 0:a.contents)==null?void 0:l.map(i=>{var o,p,c;return(i==null?void 0:i.key)==="header"&&(Array.isArray((o=i==null?void 0:i.contents)==null?void 0:o[0])?i.contents[0]=(c=i.contents[0])==null?void 0:c.map(u=>(r!=null&&r.find(m=>m===(u==null?void 0:u.prop))&&(u.fixed="left"),u)):i.contents=(p=i.contents)==null?void 0:p.map(u=>(r!=null&&r.find(m=>m===(u==null?void 0:u.prop))&&(u.fixed="left"),u))),i})}return a==null?void 0:a.contents},Kp=a=>{var l;if((a==null?void 0:a.filter)!==""){let r=a==null?void 0:a.filter;(r==null?void 0:r[0])==="("&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1)),r=r==null?void 0:r.split(",");const n=o=>(r!=null&&r.find(p=>p===(o==null?void 0:o.prop))&&(o.required=!0),o!=null&&o.children&&Array.isArray(o.children)&&(o.children=o.children.map(p=>n(p))),o);return(l=a==null?void 0:a.contents)==null?void 0:l.map(o=>{var p,c,u;return(o==null?void 0:o.key)==="header"&&(Array.isArray((p=o==null?void 0:o.contents)==null?void 0:p[0])?o.contents[0]=(u=o.contents[0])==null?void 0:u.map(m=>n(m)):o.contents=(c=o.contents)==null?void 0:c.map(m=>n(m))),o})}return a==null?void 0:a.contents},Yp=async a=>{var n,i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E;const l=M.useUnit(M.pinia),{chooseTitle:r}=M.storeToRefs(l);if((a==null?void 0:a.filter)==="true"){let _=await Hr(((i=(n=r==null?void 0:r.value)==null?void 0:n[0])==null?void 0:i.parentContent)??((p=(o=r==null?void 0:r.value)==null?void 0:o[0])==null?void 0:p.relatedContent),!1),x=(u=(c=r==null?void 0:r.value)==null?void 0:c[0])==null?void 0:u.value;(g=(m=_==null?void 0:_[0])==null?void 0:m.compData)!=null&&g.find(R=>(R==null?void 0:R.key)==="header")?_=(y=_==null?void 0:_[0])==null?void 0:y.compData:_=(D=(d=_==null?void 0:_.filter(R=>{var re;return(re=R==null?void 0:R.compData)==null?void 0:re.find(X=>(X==null?void 0:X.key)==="header")}))==null?void 0:d[0])==null?void 0:D.compData;let b=(w=_==null?void 0:_.find(R=>(R==null?void 0:R.key)==="header"))==null?void 0:w.contents;Array.isArray(b==null?void 0:b[0])&&(b=b==null?void 0:b[0]),b=((q=b==null?void 0:b.find(R=>R==null?void 0:R.isMainKey))==null?void 0:q.prop)??((A=b==null?void 0:b[0])==null?void 0:A.prop);let S=(O=(j=_==null?void 0:_.find(R=>(R==null?void 0:R.key)==="tableContents"))==null?void 0:j.contents)==null?void 0:O.find(R=>(R==null?void 0:R[b])===x);return(E=a==null?void 0:a.contents)==null?void 0:E.map(R=>{var re;return(R==null?void 0:R.key)==="formContent"&&(R.contents=(re=R.contents)==null?void 0:re.map(X=>(X.value=S==null?void 0:S[X==null?void 0:X.prop],X))),R})}return a==null?void 0:a.contents},Jp=a=>{var l,r,n,i,o;if((l=a==null?void 0:a.extra)!=null&&l.row){let p=a==null?void 0:a.filter;if(p!=null&&p.includes("*")&&(p="({"+((n=(r=p==null?void 0:p.replace("{",Nr))==null?void 0:r.split(Nr))==null?void 0:n[1])),p=(i=p==null?void 0:p.replaceAll("{",""))==null?void 0:i.replaceAll("}",""),(p==null?void 0:p[0])!=="("&&(p="("+p+")"),p.slice(1,(p==null?void 0:p.length)-1)==="undefined")return a==null?void 0:a.contents;let c=le.calculatorAndToOr(p),u=c==null?void 0:c[0],m=(o=a==null?void 0:a.extra)==null?void 0:o.row,g=[];for(let y in u)(u==null?void 0:u[y])===(m==null?void 0:m[y])?g.push(!0):g.push(!1);return g!=null&&g.every(y=>y===!0)?a==null?void 0:a.contents:[]}else return a==null?void 0:a.contents},Xp=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"tab",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Zp=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"choice",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},Qp=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},ef=a=>{var l;if(a!=null&&a.filter){let r=a==null?void 0:a.contents,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=(l=le.analyzeSplitToContent(n,","))==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)),r.push({key:"stepName",contents:n}),r}return a==null?void 0:a.contents},af=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},kc={onNumSlice:Mp,onRandomContents:Ip,onConditionContents:Lp,onFatherPaceContents:Rp,onPaceContents:$p,onMainTagContents:Vp,onButtonContents:Fp,onPamButtonContents:Pp,onRowButtonContents:jp,onRelated:Yp,onRowNum:Wp,onFixRow:Gp,onReqItem:Kp,onBottomButtonContents:Hp,onConditionContent:Jp,onTabs:Xp,onSinChoice:Zp,onTextSize:Ap,onTextRGBA:zp,onTextBackRGBA:Cp,onPosition:Tp,onColumnNum:Bp,onSize:Np,onShowType:Qp,onStepName:ef,onStep:af,onInterfaceTypeContents:Op,onBackGround:Dp,onMaxColumn:qp,onEditRead:Up,onShowHide:Ep},lf=async(a,l,r="")=>{var p,c,u,m,g,y,d,D,w,q,A,j;let n="";if(((p=a==null?void 0:a.find(O=>(O==null?void 0:O.key)==="filter"))==null?void 0:p.contents)!==""&&(n=(c=a==null?void 0:a.find(O=>(O==null?void 0:O.key)==="filter"))==null?void 0:c.contents),n===""||!n)return a;(n==null?void 0:n[0])==="("?n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1):(n=(m=(u=n==null?void 0:n.replace("(",Nr))==null?void 0:u.split(Nr))==null?void 0:m[1],n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1));let i=(g=le.analyzeSplitToContent(n,","))==null?void 0:g.map(O=>((O==null?void 0:O[(O==null?void 0:O.length)-1])===","&&(O=O==null?void 0:O.slice(0,(O==null?void 0:O.length)-1)),O!=null&&O.includes("(")||(O=O==null?void 0:O.replaceAll(":","=")),O)),o=a;for(let O in i){let E,_="";E=(D=(d=(y=i==null?void 0:i[O])==null?void 0:y.replace("=",Nr))==null?void 0:d.split(Nr))==null?void 0:D[0],_=(A=(q=(w=i==null?void 0:i[O])==null?void 0:w.replace("=",Nr))==null?void 0:q.split(Nr))==null?void 0:A[1];let x=(j=Mn==null?void 0:Mn.find(b=>(b==null?void 0:b.key)===E))==null?void 0:j.value;if(x){const b=kc[x];o=await b({contents:o,filter:_,extra:l,groupName:r})}}return o},Vo=async(a,l,r="")=>{var c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re;let n="";if(((c=a==null?void 0:a.find(X=>(X==null?void 0:X.key)==="filter"))==null?void 0:c.contents)!==""&&(n=(u=a==null?void 0:a.find(X=>(X==null?void 0:X.key)==="filter"))==null?void 0:u.contents),n===""||!n)return a;(n==null?void 0:n[0])===","&&(n=n==null?void 0:n.slice(1,n==null?void 0:n.length)),(n==null?void 0:n[0])==="("?n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1):(n==null?void 0:n[0])==="@"||(n=(g=(m=n==null?void 0:n.replace("(",Nr))==null?void 0:m.split(Nr))==null?void 0:g[1],n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1));let i=(y=le.analyzeSplitToContent(n,","))==null?void 0:y.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)),o=a,p=new Map;i==null||i.forEach(X=>{var ue,U,W;let me=(ue=X==null?void 0:X.split("="))==null?void 0:ue[0];if(me==="@MainParam"&&p.get(me)){let Z=p.get(me);Z=Z==null?void 0:Z.slice(0,(Z==null?void 0:Z.length)-1);let ae=(W=(U=X==null?void 0:X.replace("{",Nr))==null?void 0:U.split(Nr))==null?void 0:W[1];ae=Z+","+ae,p.set(me,ae)}else me==="@Button"&&p.get(me)?p.set(X,X):p.set(me,X)}),i=Array.from(p.values()),i=i==null?void 0:i.sort((X,me)=>{var ue,U;return((ue=Mn==null?void 0:Mn.find(W=>me==null?void 0:me.includes(W==null?void 0:W.key)))==null?void 0:ue.order)-((U=Mn==null?void 0:Mn.find(W=>X==null?void 0:X.includes(W==null?void 0:W.key)))==null?void 0:U.order)});for(let X in i){let me,ue="";(d=i==null?void 0:i[X])!=null&&d.includes("(")&&((D=i==null?void 0:i[X])!=null&&D.includes("@If"))?(me=(A=(q=(w=i==null?void 0:i[X])==null?void 0:w.replace("(",Nr))==null?void 0:q.split(Nr))==null?void 0:A[0],ue="("+((E=(O=(j=i==null?void 0:i[X])==null?void 0:j.replace("(",Nr))==null?void 0:O.split(Nr))==null?void 0:E[1])):(me=(b=(x=(_=i==null?void 0:i[X])==null?void 0:_.replace("=",Nr))==null?void 0:x.split(Nr))==null?void 0:b[0],ue=(R=(I=(S=i==null?void 0:i[X])==null?void 0:S.replace("=",Nr))==null?void 0:I.split(Nr))==null?void 0:R[1]);let U=(re=Mn==null?void 0:Mn.find(W=>(W==null?void 0:W.key)===me))==null?void 0:re.value;if(U){const W=kc[U];o=await W({contents:o,filter:ue,extra:l,groupName:r})}}return o},xc=a=>{if(a==null)return null;const l=String(a).trim();if(!l.startsWith("(")||!l.endsWith(")"))return null;const r=l.slice(1,-1).split(",").map(n=>Number(n.trim()));return r.length<2||r.some(n=>Number.isNaN(n))?null:[r[0],r[1]]},rf=(a,l)=>{var q,A,j,O,E;const r=Array.isArray(a)?a:[],n=r.find(_=>(_==null?void 0:_.key)==="formContent"),i=Array.isArray(n==null?void 0:n.contents)?n.contents:[],o=((q=r.find(_=>(_==null?void 0:_.key)==="_gridLayoutMeta"))==null?void 0:q.contents)??{},p=(i==null?void 0:i[0])??{};let c=((A=l==null?void 0:l.position)==null?void 0:A[0])??(o==null?void 0:o._positionStartRow)??(p==null?void 0:p._positionStartRow),u=((j=l==null?void 0:l.position)==null?void 0:j[1])??(o==null?void 0:o._positionRowSpan)??(p==null?void 0:p._positionRowSpan);(!c||Number.isNaN(c)||c<1)&&(c=1),(!u||Number.isNaN(u)||u<1)&&(u=1);let m=((O=l==null?void 0:l.size)==null?void 0:O[0])??(o==null?void 0:o._sizeStart)??(p==null?void 0:p._sizeStart),g=((E=l==null?void 0:l.size)==null?void 0:E[1])??(o==null?void 0:o._sizeEnd)??(p==null?void 0:p._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 y=g-m,d=Math.max(1,Math.round(1/y));let D=r.map(_=>{if((_==null?void 0:_.key)!=="formContent")return _;const x=Array.isArray(_==null?void 0:_.contents)?_.contents:[];return{..._,contents:x.map(b=>({...b,width:d,_positionStartRow:c,_positionRowSpan:u,_sizeStart:m,_sizeEnd:g}))}});const w={_positionStartRow:c,_positionRowSpan:u,_sizeStart:m,_sizeEnd:g};return D.some(_=>(_==null?void 0:_.key)==="_gridLayoutMeta")?D=D.map(_=>(_==null?void 0:_.key)==="_gridLayoutMeta"?{..._,contents:w}:_):D.push({key:"_gridLayoutMeta",contents:w}),D};let Ni="$R";const nf=M.useUnit(M.pinia),{selectTitle:of}=M.storeToRefs(nf);let tf=[{label:"新增",prop:"新增"},{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],sf=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"},{label:"复制新增",prop:"复制新增"},{label:"删除",prop:"删除"}],cf=[{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],uf=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"}];const xs=async(a,l,r=!0)=>{let n=[],i=a==null?void 0:a.map(async o=>{var y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha,Sa,ll,Te,oa,Ka,pe,_a,Pa,ul,Ol;let p=(w=(D=(d=(y=o==null?void 0:o.contents)==null?void 0:y.find(ca=>{var Xa;return(Xa=ca==null?void 0:ca.key)==null?void 0:Xa.includes("struct")}))==null?void 0:d.value)==null?void 0:D[0])==null?void 0:w.类型,c=Object.values(o==null?void 0:o.name);c=c==null?void 0:c.reverse();let u=(q=o==null?void 0:o.contents)==null?void 0:q.map(ca=>ca==null?void 0:ca.key),m={comp:p,isShow:o==null?void 0:o.is_show,name:c==null?void 0:c[0],id:o==null?void 0:o.object_id,order_no:o==null?void 0:o.order_no,relatedTables:u,menuFilter:(A=o==null?void 0:o.filter)==null?void 0:A.menuFilter,status:o==null?void 0:o.status,fatherSyncContents:(j=o==null?void 0:o.filter)==null?void 0:j.fatherSyncs,relatedQuotes:(O=o==null?void 0:o.filter)==null?void 0:O.quotes,sonSyncContents:(E=o==null?void 0:o.filter)==null?void 0:E.sonSyncs,nameContents:(_=M.cloneDeep(c))==null?void 0:_.reverse(),isHidden:!1,calculatorFilters:(R=(I=(S=(b=(x=o==null?void 0:o.contents)==null?void 0:x.find(ca=>{var Xa;return(Xa=ca==null?void 0:ca.key)==null?void 0:Xa.includes("struct")}))==null?void 0:b.value)==null?void 0:S[0])==null?void 0:I.算法)==null?void 0:R.contents};for(let ca in c)parseInt(ca)>=1&&(m[`name${parseInt(ca)-1}`]=c[ca]);let g=Array.isArray((re=o==null?void 0:o.filter)==null?void 0:re.menuFilter)?(X=o==null?void 0:o.filter)==null?void 0:X.menuFilter:[];if(((me=g==null?void 0:g.filter(ca=>ca==null?void 0:ca.includes("@If")))==null?void 0:me.length)>0){let ca=g==null?void 0:g.filter(Fe=>Fe==null?void 0:Fe.includes("@If"));ca=ca==null?void 0:ca[0],ca=(U=(ue=ca==null?void 0:ca.replace("(",Ni))==null?void 0:ue.split(Ni))==null?void 0:U[1],ca=ca==null?void 0:ca.slice(0,(ca==null?void 0:ca.length)-1),ca!=null&&ca.includes("*")&&(ca=(Z=(W=ca==null?void 0:ca.replace("{",Ni))==null?void 0:W.split(Ni))==null?void 0:Z[1],ca=ca==null?void 0:ca.replace("}","")),ca=le.calculatorAndToOr(ca);let Xa=(l==null?void 0:l.originPath)??"";(Xa==null?void 0:Xa[(Xa==null?void 0:Xa.length)-1])==="/"&&(Xa=Xa==null?void 0:Xa.slice(0,(Xa==null?void 0:Xa.length)-1));let ua=await Hr(Xa,!1),wa=(ae=ua==null?void 0:ua.filter(Fe=>(Fe==null?void 0:Fe.comp)==="Table"))==null?void 0:ae[0];wa=(ze=(ve=wa==null?void 0:wa.compData)==null?void 0:ve.find(Fe=>(Fe==null?void 0:Fe.key)==="tableContents"))==null?void 0:ze.contents;let Ba=(N=(te=of.value)==null?void 0:te.find(Fe=>(Fe==null?void 0:Fe.condition)==="child"))==null?void 0:N.value;wa=(se=wa==null?void 0:wa.map(Fe=>{for(let bl in Fe)if((Fe==null?void 0:Fe[bl])===Ba)return Fe}))==null?void 0:se.filter(Fe=>Fe),wa=wa==null?void 0:wa[0],ca=ca==null?void 0:ca[0];let hl=[];for(let Fe in ca){let bl="";Ja.isObject(wa)&&(bl=(fe=(G=Object.keys(wa))==null?void 0:G.filter(tr=>tr==null?void 0:tr.includes("."+Fe)))==null?void 0:fe[0]),bl!==""&&(wa!=null&&wa[bl])&&(ca==null?void 0:ca[Fe])===(wa==null?void 0:wa[bl])||wa!=null&&wa[Fe]&&(ca==null?void 0:ca[Fe])===(wa==null?void 0:wa[Fe])?hl.push(!0):hl.push(!1)}if(hl!=null&&hl.some(Fe=>Fe===!1)&&((_e=l==null?void 0:l.originPath)==null?void 0:_e[((we=l==null?void 0:l.originPath)==null?void 0:we.length)-1])!=="/")return}if(p==="Table"||p==="Method"){!r&&((qe=m==null?void 0:m.fatherSyncContents)==null?void 0:qe.length)>0;let ca=((ra=o==null?void 0:o.contents)==null?void 0:ra.find(Ra=>{var kl;return(kl=Ra==null?void 0:Ra.key)==null?void 0:kl.includes("content")}))||[],Xa=[];m.comp="Table",ca.value=(P=ca==null?void 0:ca.value)==null?void 0:P.sort((Ra,kl)=>parseInt(Ra==null?void 0:Ra.id)-parseInt(kl==null?void 0:kl.id)),ca.value=(Ke=ca==null?void 0:ca.value)==null?void 0:Ke.map(Ra=>{let kl={};for(let Ml in Ra)JSON.stringify(Ra==null?void 0:Ra[Ml])==="{}"?kl[Ml]="":kl[Ml]=Ra==null?void 0:Ra[Ml];return kl}),Xa.push({key:"tableContents",contents:ca==null?void 0:ca.value});let ua=(De=(de=(Ie=(Le=(Me=o==null?void 0:o.contents)==null?void 0:Me.find(Ra=>{var kl;return(kl=Ra==null?void 0:Ra.key)==null?void 0:kl.includes("struct")}))==null?void 0:Le.value)==null?void 0:Ie[0])==null?void 0:de.结构)==null?void 0:De.contents;Array.isArray(ua==null?void 0:ua[0])?ua[0]=(Xe=ua==null?void 0:ua[0])==null?void 0:Xe.filter(Ra=>(Ra==null?void 0:Ra.prop)!=="sort"&&(Ra==null?void 0:Ra.prop)!=="relatedId"):ua=ua==null?void 0:ua.filter(Ra=>(Ra==null?void 0:Ra.prop)!=="sort"&&(Ra==null?void 0:Ra.prop)!=="relatedId"),Xa.push({key:"header",contents:ua}),Xa.push({key:"filter",contents:(ee=(V=($=(Ge=(Ea=o==null?void 0:o.contents)==null?void 0:Ea.find(Ra=>{var kl;return(kl=Ra==null?void 0:Ra.key)==null?void 0:kl.includes("struct")}))==null?void 0:Ge.value)==null?void 0:$[0])==null?void 0:V.引用)==null?void 0:ee.contents}),Xa.push({key:"calculator",contents:m==null?void 0:m.calculatorFilters});let wa=tf,Ba=M.cloneDeep(sf);p==="Method"&&Ba.push({label:"生成方法",prop:"生成方法"}),!Array.isArray(ua==null?void 0:ua[0])&&((ce=ua==null?void 0:ua[0])==null?void 0:ce.prop)==="disabled"&&(wa=cf,Ba=uf);const hl=["推力","真空","压力","温度","流量"],Fe=m.name;Fe&&hl.includes(Fe)&&(wa=[...wa],wa.push({label:"导出paraform",prop:"导出paraform",type:"methodButton"}));let bl=[];if(!Array.isArray(ua==null?void 0:ua[0])&&(ua!=null&&ua.some(Ra=>{var kl;return(Ra==null?void 0:Ra.calculatorFilter)&&((kl=Ra==null?void 0:Ra.calculatorFilter)==null?void 0:kl.includes("Manual"))}))){let Ra=(he=ua==null?void 0:ua.map(kl=>kl==null?void 0:kl.calculatorFilter))==null?void 0:he.filter(kl=>kl&&(kl==null?void 0:kl.includes("Manual")));Ra==null||Ra.forEach(kl=>{var Oa;let Ml=le.analyzeSplitToContent(kl,",");if(Ml=Ml==null?void 0:Ml.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)),Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Extent"))&&(aa==null?void 0:aa.includes("Row")))&&(Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Button"))&&(aa==null?void 0:aa.includes(","))))){let aa=Ml==null?void 0:Ml.find(Rl=>Rl==null?void 0:Rl.includes("@FunctionButton"));aa=(Oa=aa==null?void 0:aa.split("="))==null?void 0:Oa[1],aa=aa==null?void 0:aa.slice(1,(aa==null?void 0:aa.length)-1),aa=aa==null?void 0:aa.split(","),aa=aa==null?void 0:aa[(aa==null?void 0:aa.length)-1],bl.push(aa)}}),bl=[...new Set(bl)],bl=bl==null?void 0:bl.map(kl=>({label:kl,prop:kl,type:"methodButton"}))}else if(Array.isArray(ua==null?void 0:ua[0])&&((pa=le.getColumnChild(ua==null?void 0:ua[0]))!=null&&pa.some(Ra=>{var kl;return(Ra==null?void 0:Ra.calculatorFilter)&&((kl=Ra==null?void 0:Ra.calculatorFilter)==null?void 0:kl.includes("Manual"))}))){let Ra=(Ve=(ia=le.getColumnChild(ua==null?void 0:ua[0]))==null?void 0:ia.map(kl=>kl==null?void 0:kl.calculatorFilter))==null?void 0:Ve.filter(kl=>kl&&(kl==null?void 0:kl.includes("Manual")));Ra==null||Ra.forEach(kl=>{var Oa;let Ml=le.analyzeSplitToContent(kl,",");if(Ml=Ml==null?void 0:Ml.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)),Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Extent"))&&(aa==null?void 0:aa.includes("Row")))&&(Ml!=null&&Ml.find(aa=>(aa==null?void 0:aa.includes("Button"))&&(aa==null?void 0:aa.includes(","))))){let aa=Ml==null?void 0:Ml.find(Rl=>Rl==null?void 0:Rl.includes("@FunctionButton"));aa=(Oa=aa==null?void 0:aa.split("="))==null?void 0:Oa[1],aa=aa==null?void 0:aa.slice(1,(aa==null?void 0:aa.length)-1),aa=aa==null?void 0:aa.split(","),aa=aa==null?void 0:aa[(aa==null?void 0:aa.length)-1],bl.push(aa)}}),bl=[...new Set(bl)],bl=bl==null?void 0:bl.map(kl=>({label:kl,prop:kl,type:"methodButton"}))}if(Xa.push({key:"extraButton",contents:wa}),Xa.push({key:"rowButton",contents:[...Ba,...bl]}),m.compData=await Vo(Xa,l,m==null?void 0:m.nameContents),(ya=m.compData)!=null&&ya.find(Ra=>(Ra==null?void 0:Ra.key)==="tab")&&(m.tab=(Ce=(Ca=m.compData)==null?void 0:Ca.find(Ra=>(Ra==null?void 0:Ra.key)==="tab"))==null?void 0:Ce.contents),(Fa=m.compData)!=null&&Fa.find(Ra=>(Ra==null?void 0:Ra.key)==="step")&&(m.step=(fa=(Ta=m.compData)==null?void 0:Ta.find(Ra=>(Ra==null?void 0:Ra.key)==="step"))==null?void 0:fa.contents),(ja=m.compData)!=null&&ja.find(Ra=>(Ra==null?void 0:Ra.key)==="choice")&&(m.choice=(Pe=(sa=m.compData)==null?void 0:sa.find(Ra=>(Ra==null?void 0:Ra.key)==="choice"))==null?void 0:Pe.contents),(ma=m.compData)!=null&&ma.find(Ra=>(Ra==null?void 0:Ra.key)==="hideContents")&&(m.isHidden=((Oe=(Qe=m.compData)==null?void 0:Qe.find(Ra=>(Ra==null?void 0:Ra.key)==="hideContents"))==null?void 0:Oe.contents)??!1),($e=m.compData)!=null&&$e.find(Ra=>(Ra==null?void 0:Ra.key)==="newType")){let Ra=(We=(ne=m.compData)==null?void 0:ne.find(kl=>(kl==null?void 0:kl.key)==="newType"))==null?void 0:We.contents;m.comp=Ra,m.compData=(na=m.compData)==null?void 0:na.filter(kl=>(kl==null?void 0:kl.key)!=="newType")}let tr="",xr=(va=m==null?void 0:m.compData)==null?void 0:va.filter(Ra=>(Ra==null?void 0:Ra.key)==="fixType");if((xr==null?void 0:xr.length)>0&&r&&(tr=(Ae=xr==null?void 0:xr[0])==null?void 0:Ae.contents,m.comp=tr),((Be=m==null?void 0:m.calculatorFilters)==null?void 0:Be.length)>0){let Ra=[],kl=[],Ml=[];(Ye=m==null?void 0:m.calculatorFilters)==null||Ye.forEach(Oa=>{var Rl,Yr,Jr,vn,en,Ar,Re;let aa=(Jr=(Yr=(Rl=Oa==null?void 0:Oa.calculatorFilter)==null?void 0:Rl.replace("(",Ni))==null?void 0:Yr.split(Ni))==null?void 0:Jr[1];aa=(vn=aa==null?void 0:aa.split(","))==null?void 0:vn[0],aa=aa??(Oa==null?void 0:Oa.functionName),(en=Oa==null?void 0:Oa.calculatorFilter)!=null&&en.includes("Up")&&Ra.push({label:aa,prop:aa,type:"methodButton"}),(Ar=Oa==null?void 0:Oa.calculatorFilter)!=null&&Ar.includes("Line")&&kl.push({label:aa,prop:aa,type:"methodButton"}),(Re=Oa==null?void 0:Oa.calculatorFilter)!=null&&Re.includes("Down")&&Ml.push({label:aa,prop:aa,type:"methodButton"})}),m.compData=(Ee=m.compData)==null?void 0:Ee.map(Oa=>((Oa==null?void 0:Oa.key)==="extraButton"&&(Oa.contents=[...Ra??[],...Oa.contents]),(Oa==null?void 0:Oa.key)==="rowButton"&&(Oa.contents=[...kl??[],...Oa.contents]),(Oa==null?void 0:Oa.key)==="bottomButton"&&(Oa.contents=[...Ml??[],...Oa.contents]),Oa)),(Ml==null?void 0:Ml.length)>0&&!(($a=(ye=m.compData)==null?void 0:ye.find(Oa=>(Oa==null?void 0:Oa.key)==="bottomButton"))!=null&&$a.contents)&&m.compData.push({key:"bottomButton",contents:Ml})}}else if(p==="Form"){let ca=[],Xa=(Pl=(Qa=(wl=o==null?void 0:o.contents)==null?void 0:wl.find(Fe=>{var bl;return(bl=Fe==null?void 0:Fe.key)==null?void 0:bl.includes("content")}))==null?void 0:Qa.value)==null?void 0:Pl[0],ua=[],wa=Array.isArray((gl=o==null?void 0:o.filter)==null?void 0:gl.menuFilter)?(jl=o==null?void 0:o.filter)==null?void 0:jl.menuFilter:[];wa==null||wa.forEach(Fe=>{if(Fe!=null&&Fe.includes("@Param(Hide=Yes, prop=")||Fe!=null&&Fe.includes("(Hide=Yes, prop=")){const bl=Fe==null?void 0:Fe.match(/prop=([^,)]+)/);bl!=null&&bl[1]&&ua.push(bl==null?void 0:bl[1])}});let Ba=(Kl=(Gl=(Wa=(Hl=(al=o==null?void 0:o.contents)==null?void 0:al.find(Fe=>{var bl;return(bl=Fe==null?void 0:Fe.key)==null?void 0:bl.includes("struct")}))==null?void 0:Hl.value)==null?void 0:Wa[0])==null?void 0:Gl.结构)==null?void 0:Kl.contents,hl=(Zl=Ba==null?void 0:Ba.map(Fe=>(Fe.value=Xa==null?void 0:Xa[Fe==null?void 0:Fe.prop],Fe)))==null?void 0:Zl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="sort"&&(Fe==null?void 0:Fe.prop)!=="relatedId");hl=hl==null?void 0:hl.map(Fe=>(ua!=null&&ua.includes(Fe==null?void 0:Fe.prop)&&(Fe.isHideInForm=!0),Fe)),ca.push({key:"calculator",contents:m==null?void 0:m.calculatorFilters}),ca.push({key:"filter",contents:(fl=(il=(ga=(dr=(Sl=o==null?void 0:o.contents)==null?void 0:Sl.find(Fe=>{var bl;return(bl=Fe==null?void 0:Fe.key)==null?void 0:bl.includes("struct")}))==null?void 0:dr.value)==null?void 0:ga[0])==null?void 0:il.引用)==null?void 0:fl.contents}),ca.push({key:"formContent",contents:hl}),ca.push({key:"paramHideProps",contents:ua}),m.compData=await lf(ca,l,m==null?void 0:m.nameContents),(Bl=m.compData)!=null&&Bl.find(Fe=>(Fe==null?void 0:Fe.key)==="tab")&&(m.tab=(Sa=(Ha=m.compData)==null?void 0:Ha.find(Fe=>(Fe==null?void 0:Fe.key)==="tab"))==null?void 0:Sa.contents),(ll=m.compData)!=null&&ll.find(Fe=>(Fe==null?void 0:Fe.key)==="step")&&(m.step=(oa=(Te=m.compData)==null?void 0:Te.find(Fe=>(Fe==null?void 0:Fe.key)==="step"))==null?void 0:oa.contents),(Ka=m.compData)!=null&&Ka.find(Fe=>(Fe==null?void 0:Fe.key)==="choice")&&(m.choice=(_a=(pe=m.compData)==null?void 0:pe.find(Fe=>(Fe==null?void 0:Fe.key)==="choice"))==null?void 0:_a.contents),(Pa=m.compData)!=null&&Pa.find(Fe=>(Fe==null?void 0:Fe.key)==="hideContents")&&(m.isHidden=((Ol=(ul=m.compData)==null?void 0:ul.find(Fe=>(Fe==null?void 0:Fe.key)==="hideContents"))==null?void 0:Ol.contents)??!1)}return m});return n=await Promise.all(i),n=n==null?void 0:n.filter(o=>!(o!=null&&o.isHidden)),n};let df="http://139.196.154.85:20031";function pf(a){return Ja.axios({method:"post",url:df+"/api/word-report/build-by-upload",responseType:"blob",data:a})}const ff=M.useUnit(M.pinia),{selectTitle:ws}=M.storeToRefs(ff),hf=async a=>{var r;let l=(r=le.analyzerStringToArray(a,[":","@","="]))==null?void 0:r[0];return l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1),l=le.analyzeSplitToContent(l,","),l=l==null?void 0:l.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)),l=l==null?void 0:l.map(async n=>{var o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se;let i=le.analyzeSplitToContent(n,"=");if(n!=null&&n.includes("==")){i=n==null?void 0:n.split("==");let G=i==null?void 0:i[0],fe=i==null?void 0:i[1],we=(x=fe==null?void 0:fe.split("*"))==null?void 0:x[0],_e=(b=fe==null?void 0:fe.split("*"))==null?void 0:b[1];_e=(S=le.analyzeSplitToContent(_e,":"))==null?void 0:S.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===":"&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P));let qe=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])!=="{"),ra=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])==="{");if(ra=ra==null?void 0:ra[0],ra=ra==null?void 0:ra.slice(1,(ra==null?void 0:ra.length)-1),ra=(I=le.analyzeSplitToContent(ra,","))==null?void 0:I.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===","&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P)),we!=null&&we.includes("{")){let P=(re=(R=ws.value)==null?void 0:R.find(De=>(De==null?void 0:De.condition)==="child"))==null?void 0:re.value;we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(me=(X=we==null?void 0:we.replace("{",""))==null?void 0:X.replace("}",""))==null?void 0:me.replace(":","/"),we=we+"/"+P;let Ke=await Hr(we,!1);Ke=Ke==null?void 0:Ke.find(De=>(De==null?void 0:De.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1]));let Me=(U=(ue=Ke==null?void 0:Ke.compData)==null?void 0:ue.find(De=>(De==null?void 0:De.key)==="tableContents"))==null?void 0:U.contents,Le=(Z=(W=Ke==null?void 0:Ke.compData)==null?void 0:W.find(De=>(De==null?void 0:De.key)==="header"))==null?void 0:Z.contents,Ie=le.tableToForm(Me,Le),de=[];Ie==null||Ie.forEach(De=>{let Xe=[];ra==null||ra.forEach(Ea=>{var Ge;Xe.push(((Ge=De==null?void 0:De.find($=>($==null?void 0:$.key)===Ea))==null?void 0:Ge.value)??"")}),de.push(Xe)}),de=le.arrayToString(de),n=G+"=="+de}else{we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(ve=(ae=we==null?void 0:we.replace("{",""))==null?void 0:ae.replace("}",""))==null?void 0:ve.replace(":","/");let P=await Hr(we,!1);P=P==null?void 0:P.find(de=>(de==null?void 0:de.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1]));let Ke=(te=(ze=P==null?void 0:P.compData)==null?void 0:ze.find(de=>(de==null?void 0:de.key)==="tableContents"))==null?void 0:te.contents,Me=(se=(N=P==null?void 0:P.compData)==null?void 0:N.find(de=>(de==null?void 0:de.key)==="header"))==null?void 0:se.contents,Le=le.tableToForm(Ke,Me),Ie=[];Le==null||Le.forEach(de=>{let De=[];ra==null||ra.forEach(Xe=>{var Ea;De.push(((Ea=de==null?void 0:de.find(Ge=>(Ge==null?void 0:Ge.key)===Xe))==null?void 0:Ea.value)??"")}),Ie.push(De)}),Ie=le.arrayToString(Ie),n=G+"=="+Ie}}else{let G=i==null?void 0:i[0],fe=i==null?void 0:i[1],we=(o=fe==null?void 0:fe.split("*"))==null?void 0:o[0],_e=(p=fe==null?void 0:fe.split("*"))==null?void 0:p[1];_e=(c=le.analyzeSplitToContent(_e,":"))==null?void 0:c.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===":"&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P));let qe=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])!=="{"),ra=_e==null?void 0:_e.filter(P=>(P==null?void 0:P[0])==="{");if(ra=ra==null?void 0:ra[0],ra=ra==null?void 0:ra.slice(1,(ra==null?void 0:ra.length)-1),ra=(u=le.analyzeSplitToContent(ra,":"))==null?void 0:u.map(P=>((P==null?void 0:P[(P==null?void 0:P.length)-1])===":"&&(P=P==null?void 0:P.slice(0,(P==null?void 0:P.length)-1)),P)),we!=null&&we.includes("{")){let P=(g=(m=ws.value)==null?void 0:m.find(Me=>(Me==null?void 0:Me.condition)==="child"))==null?void 0:g.value;we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(d=(y=we==null?void 0:we.replace("{",""))==null?void 0:y.replace("}",""))==null?void 0:d.replace(":","/"),we=we+"/"+P;let Ke=await Hr(we,!1);Ke=Ke==null?void 0:Ke.find(Me=>(Me==null?void 0:Me.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1])),Ke=(w=(D=Ke==null?void 0:Ke.compData)==null?void 0:D.find(Me=>(Me==null?void 0:Me.key)==="formContent"))==null?void 0:w.contents,Ke=(q=Ke==null?void 0:Ke.find(Me=>(Me==null?void 0:Me.prop)===(ra==null?void 0:ra[(ra==null?void 0:ra.length)-1])))==null?void 0:q.value,fe=Ke}else{we=we==null?void 0:we.slice(1,we==null?void 0:we.length),we=(j=(A=we==null?void 0:we.replace("{",""))==null?void 0:A.replace("}",""))==null?void 0:j.replace(":","/");let P=await Hr(we,!1);P=P==null?void 0:P.find(Ke=>(Ke==null?void 0:Ke.name)===(qe==null?void 0:qe[(qe==null?void 0:qe.length)-1])),P=(E=(O=P==null?void 0:P.compData)==null?void 0:O.find(Ke=>(Ke==null?void 0:Ke.key)==="formContent"))==null?void 0:E.contents,P=(_=P==null?void 0:P.find(Ke=>(Ke==null?void 0:Ke.prop)===(ra==null?void 0:ra[(ra==null?void 0:ra.length)-1])))==null?void 0:_.value,fe=P}n=G+fe}return n}),l=await Promise.all(l),l=l==null?void 0:l.join(","),l="{"+l+"}",l},vf=M.useLoginState(M.pinia),{loginUserInfo:Zn}=M.storeToRefs(vf),mf=M.useUnit(M.pinia),{selectTitle:wc}=M.storeToRefs(mf),Gi=M.useMenuState(M.pinia),{localFiles:bt}=M.storeToRefs(Gi),$t=async(a=[],l="Manual",r=[],n=[])=>{var c;let i=a,o=(c=i==null?void 0:i.filter(u=>{var m;return(u==null?void 0:u.functionName)&&(l==="Manual"&&((m=u==null?void 0:u.calculatorFilter)==null?void 0:m.includes(l))||l!=="Manual")}))==null?void 0:c.map(u=>({prop:u==null?void 0:u.prop,label:u==null?void 0:u.label,methods:u==null?void 0:u.calculatorFilter,functionName:u==null?void 0:u.functionName,functionRelatedWords:u==null?void 0:u.functionRelatedWords}));(n==null?void 0:n.length)>0&&(o=[...n==null?void 0:n.map(m=>({prop:"",label:"",methods:m==null?void 0:m.calculatorFilter,functionName:m==null?void 0:m.functionName,functionRelatedWords:m==null?void 0:m.functionRelatedWords})),...o]),(n==null?void 0:n.length)>0&&(i=[i==null?void 0:i[0]]);let p=i==null?void 0:i.map(async u=>{let m=(n==null?void 0:n.length)>0?n:o==null?void 0:o.filter(g=>(g==null?void 0:g.prop)===(u==null?void 0:u.prop));return u=await No(u,m,i,l,i,r),u});return p=await Promise.all(p),p},Tt=async(a,l,r="Manual",n=[],i=[],o=[])=>{var g;let p=a,c;Array.isArray(l==null?void 0:l[0])?c=le.getColumnChild(l==null?void 0:l[0]):c=l;let u=(g=c==null?void 0:c.filter(y=>{var d;return(y==null?void 0:y.calculatorFilter)&&((d=y==null?void 0:y.calculatorFilter)==null?void 0:d.includes(r))||(y==null?void 0:y.calculatorFilter)===""&&(y==null?void 0:y.functionName)}))==null?void 0:g.map(y=>({prop:y==null?void 0:y.prop,label:y==null?void 0:y.label,methods:y==null?void 0:y.calculatorFilter,functionName:y==null?void 0:y.functionName,functionRelatedWords:y==null?void 0:y.functionRelatedWords}));(i==null?void 0:i.length)>0&&(u=[...i==null?void 0:i.map(d=>({prop:"",label:"",methods:d==null?void 0:d.calculatorFilter,functionName:d==null?void 0:d.functionName,functionRelatedWords:d==null?void 0:d.functionRelatedWords})),...u]),(i==null?void 0:i.length)>0&&(p=[p==null?void 0:p[0]]);let m=p==null?void 0:p.map(async y=>(y=await No(y,u,c,r,p,n,o),y));return m=await Promise.all(m),m},yf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o;return Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(p=>{var c;if(l!=null&&l[p]){let u=l==null?void 0:l[p];o=o?u?Fl.isEqual(u.toString(),o.toString()):void 0:u}else{let u=(c=i==null?void 0:i.find(g=>(g==null?void 0:g.label)===p))==null?void 0:c.prop,m=(l==null?void 0:l[u])??0;o=o?m?Fl.isEqual(m.toString(),o.toString()):void 0:m}}),l[n]=o===void 0?void 0:o?1:0,l},Rr=a=>{const[l,r,n]=M.cloneDeep(a).split(":").map(Number);let i=+a;return!a||!(a!=null&&a.includes(":"))?i:(l??0)*3600+(r??0)*60+(n??0)},ii=a=>{const l=o=>o.toString().padStart(2,"0"),r=Math.floor(a/3600),n=Math.floor(a%3600/60),i=a%60;return`${l(r)}:${l(n)}:${parseInt(l(i))}`},gf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q,A,j;if(l!=null&&l[u]){if(o==="Row")if(!((g=((m=l==null?void 0:l[u])==null?void 0:m.toString())??"")!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let O=+(l==null?void 0:l[u]);c=c+O}else c=Rr(c.toString())+Rr((d=l==null?void 0:l[u])==null?void 0:d.toString()),c=ii(c)}else if(o==="Row"){let O=(D=i==null?void 0:i.find(E=>(E==null?void 0:E.label)===u))==null?void 0:D.prop;if(!((q=Number.isNaN(l==null?void 0:l[O])?"":(w=l==null?void 0:l[O])==null?void 0:w.toString())!=null&&q.includes(":"))&&!((A=c==null?void 0:c.toString())!=null&&A.includes(":"))){let E=+((l==null?void 0:l[O])??0);c=c+E}else c=Rr(c==null?void 0:c.toString())+Rr((j=(l==null?void 0:l[O])??0)==null?void 0:j.toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y+d},0)}return l[n]=c,l},bf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q;if(l!=null&&l[u]){if(o==="Row")if(!((g=(m=l==null?void 0:l[u])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let A=+(l==null?void 0:l[u]);c=c===0?c+A:c-A}else c=c===0?Rr(c.toString())+Rr(l==null?void 0:l[u].toString()):Rr(c.toString())-Rr(l==null?void 0:l[u].toString()),c=ii(c)}else if(o==="Row"){let A=(d=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===u))==null?void 0:d.prop;if(!((w=Number.isNaN(l==null?void 0:l[A])?"":(D=l==null?void 0:l[A])==null?void 0:D.toString())!=null&&w.includes(":"))&&!((q=c==null?void 0:c.toString())!=null&&q.includes(":"))){let j=+((l==null?void 0:l[A])??0);c=c===0?c+j:c-j}else c=c===0?Rr(c.toString())+Rr(((l==null?void 0:l[A])??0).toString()):Rr(c.toString())-Rr(((l==null?void 0:l[A])??0).toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y-d},0)}return l[n]=c,l},kf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q;if(l!=null&&l[u]){if(o==="Row")if(!((g=(m=l==null?void 0:l[u])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let A=+(l==null?void 0:l[u]);c=c===0?c+A:c*A}else c=c===0?Rr(c.toString())+Rr(l==null?void 0:l[u].toString()):Rr(c.toString())*Rr(l==null?void 0:l[u].toString()),c=ii(c)}else if(o==="Row"){let A=(d=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===u))==null?void 0:d.prop;if(!(l!=null&&l[A]))c=void 0;else if(!((w=Number.isNaN(l==null?void 0:l[A])?"":(D=l==null?void 0:l[A])==null?void 0:D.toString())!=null&&w.includes(":"))&&!((q=c==null?void 0:c.toString())!=null&&q.includes(":"))){let j=+((l==null?void 0:l[A])??0);c=c===0?c+j:c*j}else c=c===0?Rr(c.toString())+Rr(((l==null?void 0:l[A])??0).toString()):Rr(c.toString())*Rr(((l==null?void 0:l[A])??0).toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y*d},0)}return l[n]=c,l},xf=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,i=a==null?void 0:a.headers,o=a==null?void 0:a.typeString,p=a==null?void 0:a.allContents,c=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=le.getValueToObjectValue(l,le.getColumnContents(i))),r==null||r.forEach(u=>{var m,g,y,d,D,w,q;if(l!=null&&l[u]){if(o==="Row")if(!((g=(m=l==null?void 0:l[u])==null?void 0:m.toString())!=null&&g.includes(":"))&&!((y=c==null?void 0:c.toString())!=null&&y.includes(":"))){let A=+(l==null?void 0:l[u]);c=c===0?c+A:c/A}else c=c===0?Rr(c.toString())+Rr(l==null?void 0:l[u].toString()):Rr(c.toString())/Rr(l==null?void 0:l[u].toString()),c=ii(c)}else if(o==="Row"){let A=(d=i==null?void 0:i.find(j=>(j==null?void 0:j.label)===u))==null?void 0:d.prop;if(!((w=Number.isNaN(l==null?void 0:l[A])?"":(D=l==null?void 0:l[A])==null?void 0:D.toString())!=null&&w.includes(":"))&&!((q=c==null?void 0:c.toString())!=null&&q.includes(":"))){let j=+((l==null?void 0:l[A])??0);c=c===0?c+j:c/j}else c=c===0?Rr(c.toString())+Rr(((l==null?void 0:l[A])??0).toString()):Rr(c.toString())/Rr(((l==null?void 0:l[A])??0).toString()),c=ii(c)}}),o==="Column"){let u=[];r==null||r.forEach(m=>{let g=p==null?void 0:p.map(y=>{var d;return(y==null?void 0:y[m])??(y==null?void 0:y[(d=i==null?void 0:i.find(D=>(D==null?void 0:D.label)===m))==null?void 0:d.prop])});u=[...u,...g]}),c=u.reduce((m,g)=>{let y=0;Number.isNaN(m)||(y=+m);let d=0;return Number.isNaN(g)||(d=+g),y/d},0)}return l[n]=c.toFixed(2),l},wf=async a=>{var o,p,c,u,m,g,y,d,D,w,q;let l=(o=a==null?void 0:a.valueString)==null?void 0:o[0],r=(p=a==null?void 0:a.contents)==null?void 0:p.calculatorFilter,n=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 A=(u=(c=l==null?void 0:l.split("*"))==null?void 0:c[0])==null?void 0:u.replaceAll(":","/"),j=await Hr(A,!1),O=(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)===O))==null?void 0:g[0],r!==""){let E=j.compData;E=E==null?void 0:E.filter(_=>(_==null?void 0:_.key)!=="filter"),E.push({key:"filter",contents:"("+r+")"}),E=await Vo(E,{}),n=(d=(y=E==null?void 0:E.find(_=>(_==null?void 0:_.key)==="tableContents"))==null?void 0:y.contents)==null?void 0:d.length}else n=(q=(w=(D=j==null?void 0:j.compData)==null?void 0:D.find(E=>(E==null?void 0:E.key)==="tableContents"))==null?void 0:w.contents)==null?void 0:q.length}return i.value=n,i},_f=async a=>{var y,d,D,w,q,A,j,O,E;let l=(y=a==null?void 0:a.valueString)==null?void 0:y[0],r=a==null?void 0:a.filter;r=(r==null?void 0:r.find(_=>_==null?void 0:_.includes("@If")))??"",(l==null?void 0:l[0])==="$"&&(l=l==null?void 0:l.slice(1,l==null?void 0:l.length));let n=(D=(d=l==null?void 0:l.split("*"))==null?void 0:d[0])==null?void 0:D.replaceAll(":","/"),i=(w=l==null?void 0:l.split("*"))==null?void 0:w[1],o=(q=i==null?void 0:i.split("{"))==null?void 0:q[0],p=i==null?void 0:i.replace(o,"");o=o==null?void 0:o.slice(0,(o==null?void 0:o.length)-1),o=o==null?void 0:o.split(":"),o=o==null?void 0:o[(o==null?void 0:o.length)-1];let c=await Hr(n,!1);if(p=p==null?void 0:p.slice(1,(p==null?void 0:p.length)-1),p=p==null?void 0:p.split(":"),p=p==null?void 0:p[(p==null?void 0:p.length)-1],c=c==null?void 0:c.find(_=>(_==null?void 0:_.name)===o),c=(j=(A=c==null?void 0:c.compData)==null?void 0:A.find(_=>(_==null?void 0:_.key)==="tableContents"))==null?void 0:j.contents,(r==null?void 0:r.length)>0){r=(E=(O=r==null?void 0:r.replace("(","$R"))==null?void 0:O.split("$R"))==null?void 0:E[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1);let _=le.calculatorAndToOr(r);_==null||_.forEach(x=>{for(let b in x)x[b]!=="!"?c=c==null?void 0:c.filter(S=>{var I;return(S==null?void 0:S[b])===(x==null?void 0:x[b])||(S==null?void 0:S[(I=Object.keys(S))==null?void 0:I.find(R=>R==null?void 0:R.includes("."+b))])===(x==null?void 0:x[b])}):c=c==null?void 0:c.filter(S=>{var I;return(S==null?void 0:S[b])!==(x==null?void 0:x[b])&&(S==null?void 0:S[(I=Object.keys(S))==null?void 0:I.find(R=>R==null?void 0:R.includes("."+b))])!==(x==null?void 0:x[b])})})}c=c==null?void 0:c.map(_=>_==null?void 0:_[p]);let u=[...new Set(c)],m=[],g={};return u==null||u.forEach(_=>{var b;let x=(b=c==null?void 0:c.filter(S=>_===S))==null?void 0:b.length;g[_]=x}),m.push(g),{xAxis:u,yAxis:m}},Sf=async a=>{var n,i;let l=a==null?void 0:a.valueString;l=l==null?void 0:l[0];let r={};if((l==null?void 0:l[0])==="{"){l=l==null?void 0:l.slice(1,l.length-1),l=(n=le.analyzeSplitToContent(l,","))==null?void 0:n.map(c=>((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)),c));let o=l==null?void 0:l.map(async c=>{var y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me;let u=(d=(y=c==null?void 0:c.replace("=","$R"))==null?void 0:y.split("$R"))==null?void 0:d[0],m=(w=(D=c==null?void 0:c.replace("=","$R"))==null?void 0:D.split("$R"))==null?void 0:w[1],g="";if(m==="LoginUser")g=((q=Zn.value)==null?void 0:q.姓名)||((A=Zn.value)==null?void 0:A.account)||((j=Zn.value)==null?void 0:j.账号);else if((m==null?void 0:m[0])==="$"){let ue=(O=m==null?void 0:m.split("*"))==null?void 0:O[0],U=(E=m==null?void 0:m.split("*"))==null?void 0:E[1],W=U;if((ue==null?void 0:ue[0])==="$"&&(ue=ue==null?void 0:ue.slice(1,ue==null?void 0:ue.length)),ue!=null&&ue.includes("$")){let ae=(_=ue==null?void 0:ue.split("$"))==null?void 0:_[0],ve=(x=ue==null?void 0:ue.split("$"))==null?void 0:x[1],ze=(b=ae==null?void 0:ae.split(":"))==null?void 0:b[0],te=(R=(I=(S=wc.value)==null?void 0:S.filter(N=>(N==null?void 0:N.condition)==="child"))==null?void 0:I[0])==null?void 0:R.value;ve=ve==null?void 0:ve.replaceAll(":","/"),ue=ze+"/"+ve+"/"+te}else ue=ue==null?void 0:ue.replaceAll(":","/");U=U==null?void 0:U.split(":"),U=U==null?void 0:U.find((ae,ve)=>ve===(U==null?void 0:U.length)-2),W=W==null?void 0:W.split(":"),W=W==null?void 0:W.find((ae,ve)=>ve===(W==null?void 0:W.length)-1),(W==null?void 0:W[0])==="{"&&(W=W==null?void 0:W.slice(1,(W==null?void 0:W.length)-1));let Z=await Hr(ue,!1);Z=Z==null?void 0:Z.find(ae=>(ae==null?void 0:ae.name)===U),Z=(X=(re=Z==null?void 0:Z.compData)==null?void 0:re.find(ae=>(ae==null?void 0:ae.key)==="tableContents"))==null?void 0:X.contents,g=(me=Z==null?void 0:Z[0])==null?void 0:me[W]}else g=m;r[u]=g});await Promise.all(o);let p=(i=a==null?void 0:a.valueString)==null?void 0:i[1];r.menuPathContent=p}return r},Ef=async a=>{var m,g,y,d,D,w,q,A,j,O,E;let l=a==null?void 0:a.valueString,r=l==null?void 0:l.filter(_=>(_==null?void 0:_.includes(".docx"))||(_==null?void 0:_.includes(".doc")));r=r==null?void 0:r[0];let n=l==null?void 0:l.filter(_=>!(_!=null&&_.includes(".docx"))&&!(_!=null&&_.includes(".doc")));n=n==null?void 0:n[0];let i=(g=a==null?void 0:a.compNames)==null?void 0:g[((m=a==null?void 0:a.compNames)==null?void 0:m.length)-1],o=((D=(d=(y=wc.value)==null?void 0:y.filter(_=>(_==null?void 0:_.condition)==="child"))==null?void 0:d[0])==null?void 0:D.value)??"",p=bt.value;o!==""&&(p=(w=p==null?void 0:p.find(_=>(_==null?void 0:_.path)===o))==null?void 0:w.children),p=(q=p==null?void 0:p.find(_=>(_==null?void 0:_.name)===i))==null?void 0:q.children;let c=p==null?void 0:p.find(_=>(_==null?void 0:_.name)===r),u=p==null?void 0:p.find(_=>(_==null?void 0:_.name)===n);if(u=(u==null?void 0:u.url)??"",u!=="")u=u==null?void 0:u.replace(/^file:\/\//,"file:///").replace(/\\/g,"/");else{let _=(j=(A=bt.value)==null?void 0:A.find(x=>(x==null?void 0:x.name)===n))==null?void 0:j.url;u=_==null?void 0:_.replace(/^file:\/\//,"file:///").replace(/\\/g,"/")}if(c=(c==null?void 0:c.url)??"",c!=="")c=c==null?void 0:c.replace(/^file:\/\//,"file:///").replace(/\\/g,"/");else{let _=(E=(O=bt.value)==null?void 0:O.find(x=>(x==null?void 0:x.name)===r))==null?void 0:E.url;c=_==null?void 0:_.replace(/^file:\/\//,"file:///").replace(/\\/g,"/")}try{const x=await(await fetch(c)).blob();let b=c.split(/[\\/]/).pop();const S=new File([x],b,{type:x.type||"application/octet-stream"}),I=new FormData;I.append("TemplateFile",S);let R=await fetch(u);R=await R.text(),R=await hf(R),I.append("RawContent",R);let re=await pf(I),X=new Blob([re.data],{type:"application/zip"});const me=window.URL.createObjectURL(X),ue=document.createElement("a");ue.href=me,ue.download=r,document.body.appendChild(ue),ue.click(),document.body.removeChild(ue),window.URL.revokeObjectURL(me)}catch{Ja.ElMessage.error("文件路径未找到")}},Cf=async a=>{var i,o;let l=a==null?void 0:a.valueString,r=l==null?void 0:l[0];r=(i=r==null?void 0:r.split("*"))==null?void 0:i[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.replaceAll(":","/"),r=r;let n=await Hr(r,!1);if((n==null?void 0:n.length)>0){Gi.setActiveTopMenuPath((o=r==null?void 0:r.split("/"))==null?void 0:o[0]);let p=localStorage.getItem("menus-store");p=JSON.parse(p),p=p==null?void 0:p.menus,p=p==null?void 0:p.find(c=>{var u;return(c==null?void 0:c.path)===((u=r==null?void 0:r.split("/"))==null?void 0:u[0])}),p=p==null?void 0:p.childMenus,Gi.setAsideMenus(p),Gi.setJumpMenuInform(!0),Gi.setActiveMenuPath(r)}else Ja.ElMessage.error("页面不存在");return a},mo={Sum:gf,Substract:bf,Multiple:kf,Divide:xf,Compare:yf,VecDimCount:wf,Approval:Sf,VecRepCount:_f,AutoReportGen:Ef,OpenPortal:Cf},No=async(a,l,r,n="Auto",i,o=[],p=[])=>{var y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W;let c=a,u=[],m=await M.getPageDataApi({platId:parseInt((y=Zn==null?void 0:Zn.value)==null?void 0:y.plat_id),pageName:"menu"});m=(w=(D=(d=m==null?void 0:m.data)==null?void 0:d.result)==null?void 0:D.filter(Z=>(Z==null?void 0:Z.property_name)===""))==null?void 0:w[0];let g=[];if(m!=null&&m.object_name){m=m==null?void 0:m.object_name;let Z=await M.getPageDataApi({platId:parseInt((q=Zn==null?void 0:Zn.value)==null?void 0:q.plat_id),pageName:m});Z=(_=(E=(O=(j=(A=Z==null?void 0:Z.data)==null?void 0:A.result)==null?void 0:j[0])==null?void 0:O.contents)==null?void 0:E.find(ae=>{var ve;return(ve=ae==null?void 0:ae.key)==null?void 0:ve.includes("content")}))==null?void 0:_.value,u=(x=Z==null?void 0:Z.map(ae=>({functionName:ae==null?void 0:ae.函数名称,functionContent:ae==null?void 0:ae.输出值})))==null?void 0:x.filter(ae=>(ae==null?void 0:ae.functionContent)!==""),u==null||u.forEach(ae=>{g.push(ae.functionName),mo[ae.functionName]=new Function("return "+ae.functionContent)()})}if((l==null?void 0:l.length)===0)return c;for(let Z in l){let ae=(b=l==null?void 0:l[Z])==null?void 0:b.functionName;const ve=mo==null?void 0:mo[ae];let ze=(S=l==null?void 0:l[Z])==null?void 0:S.methods;if(ze=le.analyzeSplitToContent(ze,","),(I=ze==null?void 0:ze.find(te=>te==null?void 0:te.includes("@Type")))!=null&&I.includes(n)||!(ze!=null&&ze.find(te=>te==null?void 0:te.includes("@Type")))&&n==="Manual"||n==="Auto"||(ze==null?void 0:ze.length)===0){let te=((X=(re=(R=ze==null?void 0:ze.find(N=>N==null?void 0:N.includes("@Extent")))==null?void 0:R.replace(":","="))==null?void 0:re.split("="))==null?void 0:X[1])??[];if(await new Function("return ")(),(g==null?void 0:g.length)>0&&g.find(N=>N===ae)){let N="";try{let G=(me=l==null?void 0:l[Z])==null?void 0:me.functionRelatedWords,fe=(o==null?void 0:o.length)>0?o==null?void 0:o.map(_e=>{var qe;return _e==null?void 0:_e[(qe=l==null?void 0:l[Z])==null?void 0:qe.prop]}):["0"];fe=fe==null?void 0:fe.map(_e=>_e==null?void 0:_e.slice((_e==null?void 0:_e.length)-5,_e==null?void 0:_e.length)),fe=fe==null?void 0:fe.map(_e=>le.isNumber(parseInt(_e))&&parseInt(_e)?parseInt(_e):0);let we=Math.max(...fe);G=G==null?void 0:G.map(_e=>{if(_e!=null&&_e.includes("'"))return _e==null?void 0:_e.replaceAll("'","");if(_e!=null&&_e.includes("@"))return we+1;{let qe=Object.keys(c);return _e=(c==null?void 0:c[_e])??(c==null?void 0:c[qe==null?void 0:qe.find(ra=>ra==null?void 0:ra.includes("."+_e))]),_e}}),N=ve(...G)}catch(G){Ja.ElMessage.warning("关联数据出现错误,"+G.message)}let se=(ue=l==null?void 0:l[Z])==null?void 0:ue.prop;c[se]=N}else c=await ve({contents:c,valueString:(U=l==null?void 0:l[Z])==null?void 0:U.functionRelatedWords,prop:(W=l==null?void 0:l[Z])==null?void 0:W.prop,filter:ze,headers:r,typeString:te,allContents:i,compNames:p})}}return c},Df=M.useLoginState(M.pinia),{loginUserInfo:wn}=M.storeToRefs(Df),Tf=M.useMenuState(M.pinia),{activeMenuPath:_s,currentMenuPath:yo}=M.storeToRefs(Tf),_c=M.useUnit(M.pinia);let Ss="$R";const{selectTitle:Ii}=M.storeToRefs(_c),Sc=async(a,l)=>{var p,c,u,m,g,y,d,D,w,q,A,j,O;let r=_s.value,n="",i=((p=Ii==null?void 0:Ii.value)==null?void 0:p.find(E=>(E==null?void 0:E.condition)==="child"&&!(E!=null&&E.relatedContent)))??void 0;(a==null?void 0:a.length)===0||(r=l?r:(c=a==null?void 0:a[0])==null?void 0:c.object_name,n=(u=a==null?void 0:a[0])==null?void 0:u.father_name);let o=[];if(n!==""){let E=n;(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 _=await Hr(E,!1);_=(m=_==null?void 0:_[0])==null?void 0:m.compData;let x=(g=_==null?void 0:_.find(S=>(S==null?void 0:S.key)==="header"))==null?void 0:g.contents;x=((y=x==null?void 0:x.find(S=>S==null?void 0:S.isMainKey))==null?void 0:y.prop)??((d=x==null?void 0:x[0])==null?void 0:d.prop);let b=(w=(D=_==null?void 0:_.find(S=>(S==null?void 0:S.key)==="tableContents"))==null?void 0:D.contents)==null?void 0:w.map(S=>({label:S==null?void 0:S[x],value:S==null?void 0:S[x]}));o=(q=n==null?void 0:n.split("/"))==null?void 0:q.map(S=>(S===""?i?(i.isShow=!0,S=i):S={value:S,condition:"child",options:b,parentContent:(n==null?void 0:n[(n==null?void 0:n.length)-1])==="/"?n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1):n,isShow:!0}:S={condition:"parent",value:S.trim(),isShow:!0},S))}if(r!==""){let E=(A=r==null?void 0:r.split("/"))==null?void 0:A.map(_=>(_={condition:"normal",value:_.trim(),isShow:!0},_));((j=E==null?void 0:E[0])==null?void 0:j.value)===((O=o==null?void 0:o[0])==null?void 0:O.value)&&(E=E==null?void 0:E.filter((_,x)=>x!==0)),o=[...o??[],...E??[]]}n===""&&i&&((i==null?void 0:i.parentContent)!==_s.value&&(i.isShow=!1),(i==null?void 0:i.value)!==""&&o.push(i)),_c.setSelectTitle(o)},Bf=async a=>{var o,p,c,u,m,g,y,d,D;let l=await M.getPageDataApi({platId:parseInt((o=wn==null?void 0:wn.value)==null?void 0:o.plat_id),pageName:"menu"}),r=(p=l==null?void 0:l.data)==null?void 0:p.result,n=(g=(m=(u=(c=a==null?void 0:a.filter(w=>(w==null?void 0:w.comp)==="Table"))==null?void 0:c[0])==null?void 0:u.compData)==null?void 0:m.find(w=>(w==null?void 0:w.key)==="filter"))==null?void 0:g.contents;n=(D=(d=(y=n==null?void 0:n.replace("(",Ss))==null?void 0:y.split(Ss))==null?void 0:d[0])==null?void 0:D.replaceAll(":","/");let i=r==null?void 0:r.filter(w=>{var q;return(w==null?void 0:w.object_name)===yo.value+"/"||((q=yo.value)==null?void 0:q.includes(n))&&n+"/"===(w==null?void 0:w.object_name)||n===(w==null?void 0:w.object_name)});return(i==null?void 0:i.length)>0&&(a=a==null?void 0:a.map(w=>{var q;return(w==null?void 0:w.comp)==="Table"&&(w.compData=(q=w==null?void 0:w.compData)==null?void 0:q.map(A=>{var j,O,E;return(A==null?void 0:A.key)==="header"&&(Array.isArray((j=A.contents)==null?void 0:j[0])?A.contents[0]=(E=A.contents[0])==null?void 0:E.map((_,x)=>{var b;return x===0&&(_.isExistChild=!0,((b=yo.value)!=null&&b.includes(n)||n)&&(_.fatherPath=n)),_}):A.contents=(O=A.contents)==null?void 0:O.map((_,x)=>{var b;return x===0&&(_.isExistChild=!0,((b=yo.value)!=null&&b.includes(n)||n)&&(_.fatherPath=n)),_})),A})),w})),a},Hr=async(a,l,r={})=>{var p,c,u,m,g,y,d,D,w,q,A,j;let n=await M.getPageDataApi({platId:parseInt((p=wn==null?void 0:wn.value)==null?void 0:p.plat_id),pageName:a}),i=(c=n==null?void 0:n.data)==null?void 0:c.result;if((i==null?void 0:i.length)===0&&(r!=null&&r.originPath)&&(r==null?void 0:r.originPath)!==a){let O=await M.getPageDataApi({platId:parseInt((u=wn==null?void 0:wn.value)==null?void 0:u.plat_id),pageName:r==null?void 0:r.originPath});if(((g=(m=O==null?void 0:O.data)==null?void 0:m.result)==null?void 0:g.length)>0){let E=await xs((y=O==null?void 0:O.data)==null?void 0:y.result,r,!1);E=E==null?void 0:E.map(async b=>{var R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge;let S=[],I=(R=Object.keys(b))==null?void 0:R.filter($=>($==null?void 0:$.includes("name"))&&$!=="nameContents");for(let $ in b)I!=null&&I.find(V=>V===$)&&S.push(b==null?void 0:b[$]);if(S=S.reverse(),(b==null?void 0:b.comp)==="Table"){let $=(me=(X=(re=b==null?void 0:b.compData)==null?void 0:re.find(ee=>(ee==null?void 0:ee.key)==="tableContents"))==null?void 0:X.contents)==null?void 0:me.map(ee=>{let ce={};for(let he in ee)he!=="id"&&he!=="create_time"&&he!=="update_time"&&he!=="sort"&&he!=="create_user_id"&&he!=="update_user_id"&&he!=="department_id"&&he!=="relatedId"&&(ce[he]=ee==null?void 0:ee[he]);return ee=Object.values(ce),ee}),V=(U=(ue=b==null?void 0:b.compData)==null?void 0:ue.find(ee=>(ee==null?void 0:ee.key)==="header"))==null?void 0:U.contents;if(Array.isArray(V==null?void 0:V[0])?(V[0].push({label:"排序",prop:"sort"}),V[0].push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(W=V[0])!=null&&W.find(ee=>(ee==null?void 0:ee.prop)==="disabled")&&(V[0]=(Z=V[0])==null?void 0:Z.filter(ee=>(ee==null?void 0:ee.prop)!=="disabled"),V[0].unshift({label:"",prop:"disabled",sortable:!1}))):(V||(V=[]),V.push({label:"排序",prop:"sort"}),V.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),V!=null&&V.find(ee=>(ee==null?void 0:ee.prop)==="disabled")&&(V=V==null?void 0:V.filter(ee=>(ee==null?void 0:ee.prop)!=="disabled"),V.unshift({label:"",prop:"disabled",sortable:!1}))),V!=null&&V.some(ee=>{var ce;return(ee==null?void 0:ee.calculatorFilter)&&((ce=ee==null?void 0:ee.calculatorFilter)==null?void 0:ce.includes("Auto"))})&&($=await Tt($,V,"Auto"),$=$==null?void 0:$.map(ee=>Object.values(ee))),b!=null&&b.fatherSyncContents){Array.isArray((ae=b==null?void 0:b.fatherSyncContents)==null?void 0:ae[0])&&(b.fatherSyncContents=(ve=b==null?void 0:b.fatherSyncContents)==null?void 0:ve[0]);let ee=(ze=Ii.value)==null?void 0:ze.find(ce=>(ce==null?void 0:ce.condition)==="child");b.fatherSyncContents=(te=b==null?void 0:b.fatherSyncContents)==null?void 0:te.map(ce=>{var he,pa,ia,Ve,ya,Ca;return((pa=ce==null?void 0:ce.menus)==null?void 0:pa[((he=ce==null?void 0:ce.menus)==null?void 0:he.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"!==(ce==null?void 0:ce.menus)?ce.menus=(ce==null?void 0:ce.menus)+(ee==null?void 0:ee.value):((Ve=ce==null?void 0:ce.menus)==null?void 0:Ve[((ia=ce==null?void 0:ce.menus)==null?void 0:ia.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"===(ce==null?void 0:ce.menus)&&(ce.menus=(Ca=ce.menus)==null?void 0:Ca.slice(0,((ya=ce.menus)==null?void 0:ya.length)-1)),ce})}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 ee=(G=Ii.value)==null?void 0:G.find(ce=>(ce==null?void 0:ce.condition)==="child");b.sonSyncContents=(fe=b==null?void 0:b.sonSyncContents)==null?void 0:fe.map(ce=>{var he,pa,ia,Ve,ya,Ca;return((pa=ce==null?void 0:ce.menus)==null?void 0:pa[((he=ce==null?void 0:ce.menus)==null?void 0:he.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"!==(ce==null?void 0:ce.menus)?ce.menus=(ce==null?void 0:ce.menus)+(ee==null?void 0:ee.value):((Ve=ce==null?void 0:ce.menus)==null?void 0:Ve[((ia=ce==null?void 0:ce.menus)==null?void 0:ia.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"===(ce==null?void 0:ce.menus)&&(ce.menus=(Ca=ce.menus)==null?void 0:Ca.slice(0,((ya=ce.menus)==null?void 0:ya.length)-1)),ce})}if(b!=null&&b.relatedQuotes){Array.isArray((we=b==null?void 0:b.relatedQuotes)==null?void 0:we[0])&&(b.relatedQuotes=(_e=b==null?void 0:b.relatedQuotes)==null?void 0:_e[0]);let ee=(qe=Ii.value)==null?void 0:qe.find(ce=>(ce==null?void 0:ce.condition)==="child");b.relatedQuotes=(ra=b==null?void 0:b.relatedQuotes)==null?void 0:ra.map(ce=>{var he,pa,ia,Ve,ya,Ca;return((pa=ce==null?void 0:ce.menus)==null?void 0:pa[((he=ce==null?void 0:ce.menus)==null?void 0:he.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"!==(ce==null?void 0:ce.menus)?ce.menus=(ce==null?void 0:ce.menus)+(ee==null?void 0:ee.value):((Ve=ce==null?void 0:ce.menus)==null?void 0:Ve[((ia=ce==null?void 0:ce.menus)==null?void 0:ia.length)-1])==="/"&&(ee==null?void 0:ee.parentContent)+"/"===(ce==null?void 0:ce.menus)&&(ce.menus=(Ca=ce.menus)==null?void 0:Ca.slice(0,((ya=ce.menus)==null?void 0:ya.length)-1)),ce})}b={filter:(Ke=(P=b==null?void 0:b.compData)==null?void 0:P.find(ee=>(ee==null?void 0:ee.key)==="filter"))==null?void 0:Ke.contents,key:b==null?void 0:b.comp,name:S,tableColumns:V,tableContents:$,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,calculatorFilters:b==null?void 0:b.calculatorFilters}}else{let $=(Ie=(Le=(Me=b==null?void 0:b.compData)==null?void 0:Me.find(ee=>(ee==null?void 0:ee.key)==="formContent"))==null?void 0:Le.contents)==null?void 0:Ie.map(ee=>(ee==null?void 0:ee.value)??"");$=[$];let V=(Xe=(De=(de=b==null?void 0:b.compData)==null?void 0:de.find(ee=>(ee==null?void 0:ee.key)==="formContent"))==null?void 0:De.contents)==null?void 0:Xe.map(ee=>(ee.value="",ee));b={contents:$,filter:(Ge=(Ea=b==null?void 0:b.compData)==null?void 0:Ea.find(ee=>(ee==null?void 0:ee.key)==="filter"))==null?void 0:Ge.contents,key:b==null?void 0:b.comp,name:S,value:V,fatherSyncContents:b==null?void 0:b.fatherSyncContents,relatedQuotes:b==null?void 0:b.relatedQuotes,sonSyncContents:b==null?void 0:b.sonSyncContents,calculatorFilters:b==null?void 0:b.calculatorFilters}}return b.isShow=!1,b}),E=await Promise.all(E);let _=[{key:"menuPath",contents:[{path:a,fatherPath:(w=(D=(d=O==null?void 0:O.data)==null?void 0:d.result)==null?void 0:D[0])==null?void 0:w.father_name,isShow:!1}]},{key:a,contents:E}];await M.createPlatFormDataApi({platId:parseInt((q=wn==null?void 0:wn.value)==null?void 0:q.plat_id),changeData:_});let x=await M.getPageDataApi({platId:parseInt((A=wn==null?void 0:wn.value)==null?void 0:A.plat_id),pageName:a});i=(j=x==null?void 0:x.data)==null?void 0:j.result}}l&&await Sc(i,!!(r!=null&&r.originPath));let o=await xs(i,r);return l&&(o=await Bf(o)),o==null?void 0:o.filter(O=>O)},Es=async a=>{var n,i,o,p,c,u,m,g,y,d,D;let l=(n=a==null?void 0:a.menus)==null?void 0:n.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+((o=(i=a.value)==null?void 0:i.split(" "))==null?void 0:o[0]));let r=await Hr(l,!1);if(r=(p=r==null?void 0:r.filter(w=>{var q,A;return(w==null?void 0:w.name)===((A=a==null?void 0:a.groups)==null?void 0:A[((q=a==null?void 0:a.groups)==null?void 0:q.length)-1])}))==null?void 0:p[0],(u=(c=r==null?void 0:r.compData)==null?void 0:c.find(w=>(w==null?void 0:w.key)==="tableContents"))!=null&&u.contents){r=(g=(m=r==null?void 0:r.compData)==null?void 0:m.find(q=>(q==null?void 0:q.key)==="tableContents"))==null?void 0:g.contents;let w=((y=a==null?void 0:a.words)==null?void 0:y[0])??(a==null?void 0:a.prop);return r=r==null?void 0:r.filter(q=>{var A,j,O,E;return(q==null?void 0:q[a!=null&&a.endChildMenu?w:(A=a==null?void 0:a.words)==null?void 0:A[0]])===(a!=null&&a.relatedWords&&((j=a==null?void 0:a.relatedWords)==null?void 0:j.length)>0?(E=(O=a.value)==null?void 0:O.split(" "))==null?void 0:E[0]:a.value)}),r==null?void 0:r[0]}else{let w=(D=(d=r==null?void 0:r.compData)==null?void 0:d.find(A=>(A==null?void 0:A.key)==="formContent"))==null?void 0:D.contents,q={};return w==null||w.forEach(A=>{q[A.prop]=A.value}),q}},Nf={key:0,class:"extra-button-content"},Af={class:"table-operator-wrap"},zf={key:0,class:"extra-button-filter"},Mf={key:1,class:"extra-header"},If=["onClick"],Of={class:"table-op-text"},Lf={class:"table-op-text"},Rf={class:"drop-menu",style:{width:"120px"}},$f=["onClick"],Vf={key:0},Ff={key:1},Pf=["onClick"],jf={class:"table-op-text"},Hf={key:1,class:"extra-button-content tabs-button-wrapper"},Uf={class:"table-operator-wrap"},qf={class:"extra-button-filter"},Wf={key:0,class:"extra-header"},Gf={class:"table-op-action"},Kf={class:"table-op-text"},Yf={class:"drop-menu",style:{width:"120px"}},Jf={key:0},Xf={key:1},Zf=["onClick"],Qf={class:"table-op-text"},e0={__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 r=l,n=a,i=()=>{const I=(n==null?void 0:n.menuFilter)||[];return Array.isArray(I)&&(I==null?void 0:I.some(R=>{const re=typeof R=="string"?R:JSON.stringify(R);return re==null?void 0:re.includes("HideGroup=Yes")}))},o=e.ref(""),p=e.ref(!1),c=e.ref(!1),u=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 y(I,R){return I.map(re=>{const X={...re};return R.forEach(me=>{delete X[me]}),X})}function d(I){if(!I||I.t!=="n")return(I==null?void 0:I.v)??"";const R=I.v;if(I.z){const re=String(I.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 U of X)if(re.includes(U))return D(R);const me=/[ymdhms]/.test(re),ue=/^[0#\.\,\s]+$/.test(re.replace(/[\\\/\-:]/g,""));if(me&&!ue)return D(R)}if(R>=1&&R<=73050){if(R<5e3)return R;if(R>=5e3&&R<4e4){const re=Math.floor((R-25569)/365.25)+1970;return re>=1970&&re<=2e3&&I.z&&/[ymd]/.test(String(I.z).toLowerCase())?D(R):R}if(R>=4e4)return D(R)}return R}function D(I){if(typeof I!="number")return I;try{const R=new Date((I-25569)*86400*1e3);if(isNaN(R.getTime()))return I;const re=R.getFullYear(),X=String(R.getMonth()+1).padStart(2,"0"),me=String(R.getDate()).padStart(2,"0");return`${re}-${X}-${me}`}catch{return I}}const w=I=>{const R=I.raw;if(!R)return;const re=new FileReader;re.onload=X=>{try{const me=new Uint8Array(X.target.result),ue=le.readSync(me,{type:"array"}),U=ue.SheetNames[0],W=ue.Sheets[U],ae=le.utils.decode_range(W["!ref"]).e.c+1,ve=new Array(ae).fill(""),ze=[];for(const fe in W){if(fe[0]==="!")continue;const{r:we,c:_e}=le.utils.decode_cell(fe),qe=W[fe];let ra=d(qe);if((ra==null||ra==="")&&(ra=""),we===0)ve[_e]=ra;else{if(!ze[we-1]){ze[we-1]={};for(let P=0;P<ae;P++)ze[we-1][`col_${P}`]=""}ze[we-1][`col_${_e}`]=ra}}for(let fe=0;fe<ae;fe++)ve[fe]===void 0&&(ve[fe]="");const te=[];for(let fe=0;fe<ve.length;fe++)(!ve[fe]||ve[fe].toString().trim()==="")&&te.push(fe);let N,se;(te==null?void 0:te.length)>0?(Ja.ElMessage.warning("存在键为空的列,已自动过滤,请检查补充"),N=ve.filter((fe,we)=>!te.includes(we)),se=y(ze,te==null?void 0:te.map(fe=>`col_${fe}`))):(N=ve,se=ze);const G=ze==null?void 0:ze[0];if(!(G!=null&&G.hasOwnProperty("col_0")))return Ja.ElMessage.error("导入的数据列不匹配,请检查是否错位");r("getImportData",N,se)}catch(me){throw Ja.ElMessage.error(me.message),new Error(me.message)}},re.readAsArrayBuffer(R)},q=I=>{var re;const R=(re=u.value)==null?void 0:re.reduce((X,me,ue)=>(ue===0?X[me.label]=I:X[me.label]=me==null?void 0:me.value,X),{});r("filter",R,I,!0)},A=(I,R={})=>{r("buttonClick",I,"",R)},j=I=>{var R,re;u.value=(re=(R=le.getColumnChild(M.cloneDeep(I)))==null?void 0:R.filter(X=>(X==null?void 0:X.label)!==""&&(X==null?void 0:X.label)!=="操作"))==null?void 0:re.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:3,prop:(X==null?void 0:X.prop)??""}))},O=e.ref(!1),E=I=>{var R;if((I==null?void 0:I.buttonName)==="确认"&&(r("filter",I==null?void 0:I.content),O.value=(I==null?void 0:I.content)&&Object.values(I==null?void 0:I.content).length>0),(I==null?void 0:I.buttonName)==="清空"){const re=M.cloneDeep(I==null?void 0:I.content);for(const X in re)re[X]="";u.value=(R=u.value)==null?void 0:R.map(X=>({...X,value:""})),r("filter",re),O.value=!1}p.value=!1},_=()=>{p.value=!p.value,c.value=!0},x=()=>{var R,re;u.value=(R=u.value)==null?void 0:R.map(X=>({...X,value:""}));const I=(re=u.value)==null?void 0:re.reduce((X,me)=>(X[me.label]=me.value,X),{});r("filter",I)},b=e.ref(null);let S;return S=I=>{var me;if(!p.value)return;const R=(me=b==null?void 0:b.value)==null?void 0:me.$el,re=R==null?void 0:R.contains(I.target);let X=!1;document.querySelectorAll(".el-popover, .el-popper").forEach(ue=>{ue.contains(I.target)&&(X=!0)}),!re&&!X&&(p.value=!1)},e.onMounted(()=>{document.addEventListener("click",S),j(n.columns)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",S)}),e.watch(()=>n.columns,()=>{j(n.columns)},{deep:!0,immediate:!0}),(I,R)=>{var W,Z,ae,ve,ze,te,N,se;const re=e.resolveComponent("el-icon"),X=e.resolveComponent("svg-icon"),me=e.resolveComponent("el-input"),ue=e.resolveComponent("el-upload"),U=e.resolveComponent("el-button");return a.pageLayout==="vertical"?(e.openBlock(),e.createElementBlock("div",Nf,[i()?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(a.compName?"table-name-wrap":""),style:e.normalizeStyle({background:(n==null?void 0:n.level)>1?"transparent":"var(--ssgroup-background)",paddingLeft:((n==null?void 0:n.level)-1)*12+"px",fontWeight:600-((n==null?void 0:n.level)-1)*100>=400?600-((n==null?void 0:n.level)-1)*100:400,fontSize:17-(n==null?void 0:n.level)>=14?17-(n==null?void 0:n.level)+"px":"14px"})},e.toDisplayString(a.compName),7)),e.createElementVNode("div",Af,[n!=null&&n.filterShow?(e.openBlock(),e.createElementBlock("div",zf,[e.createVNode(od,{trigger:"contextmenu",ref_key:"popOverRef",ref:b,title:"",width:800,placement:"bottom-start",isVisible:p.value,"onUpdate:isVisible":R[4]||(R[4]=G=>p.value=G)},{reference:e.withCtx(()=>{var G,fe,we,_e;return[e.createVNode(me,{modelValue:o.value,"onUpdate:modelValue":R[0]||(R[0]=qe=>o.value=qe),style:{"min-width":"80px"},placeholder:O.value?(we=(fe=(G=a.filterValues)==null?void 0:G.filter(qe=>qe))==null?void 0:fe.slice(0,3))==null?void 0:we.join("/"):"搜索","prefix-icon":e.unref(Ja.search_default),clearable:"",onInput:q,disabled:((_e=u.value)==null?void 0:_e.length)===0},{suffix:e.withCtx(()=>{var qe,ra;return[!o.value&&((ra=(qe=a.filterValues)==null?void 0:qe.filter(P=>P))!=null&&ra.join("/"))?(e.openBlock(),e.createBlock(re,{key:0,style:{cursor:"pointer"},onClick:x},{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(_,["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:R[1]||(R[1]=e.withModifiers(()=>{},["stop"])),onKeyup:R[2]||(R[2]=e.withModifiers(()=>{},["stop"])),onKeypress:R[3]||(R[3]=e.withModifiers(()=>{},["stop"]))},[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,buttonValue:m.value,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&&((W=a.buttons)==null?void 0:W.length)>0?(e.openBlock(),e.createElementBlock("div",Mf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Z=a.buttons)==null?void 0:Z.filter(G=>a.isDevMode||(G==null?void 0:G.label)!=="修改模板"),(G,fe)=>{var we;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:fe},[(G==null?void 0:G.type)==="upload"?(e.openBlock(),e.createBlock(ue,{key:0,class:"upload-button-wrap","on-change":w,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1,disabled:!!a.lockingPage},{default:e.withCtx(()=>{var _e;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:qe=>A(G==null?void 0:G.label)},[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"]),e.createElementVNode("span",Of,e.toDisplayString(G==null?void 0:G.label),1)],10,If)]}),_:2},1032,["disabled"])):e.createCommentVNode("",!0),(G==null?void 0:G.type)==="popover"?(e.openBlock(),e.createBlock(pl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>{var _e;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}])},[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"]),e.createElementVNode("span",Lf,e.toDisplayString(G==null?void 0:G.label),1)],2)]}),dropMenu:e.withCtx(()=>[e.createElementVNode("div",Rf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G==null?void 0:G.contents,_e=>{var qe,ra;return e.openBlock(),e.createElementBlock("div",{key:_e==null?void 0:_e.label,class:e.normalizeClass(["table-op-drop-item",{"is-disabled":!!a.lockingPage}]),onClick:P=>!a.lockingPage&&A(_e==null?void 0:_e.label)},[e.createTextVNode(e.toDisplayString(_e==null?void 0:_e.label),1),(qe=_e==null?void 0:_e.label)!=null&&qe.includes("选中")?(e.openBlock(),e.createElementBlock("span",Vf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(ra=_e==null?void 0:_e.label)!=null&&ra.includes("全部")?(e.openBlock(),e.createElementBlock("span",Ff,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)],10,$f)}),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(G!=null&&G.type)||(G==null?void 0:G.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,id:"themeButton",class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:_e=>!a.lockingPage&&A(G==null?void 0:G.label,G)},[e.createVNode(X,{class:"table-op-icon",name:((we=g==null?void 0:g.find(_e=>(_e==null?void 0:_e.label)===(G==null?void 0:G.label)))==null?void 0:we.icon)??"normal"},null,8,["name"]),e.createElementVNode("span",jf,e.toDisplayString(G==null?void 0:G.label),1)],10,Pf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createElementBlock("div",Hf,[e.createElementVNode("div",Uf,[e.createElementVNode("div",qf,[e.createVNode(me,{modelValue:o.value,"onUpdate:modelValue":R[5]||(R[5]=G=>o.value=G),style:{"min-width":"80px"},placeholder:O.value?(ze=(ve=(ae=a.filterValues)==null?void 0:ae.filter(G=>G))==null?void 0:ve.slice(0,3))==null?void 0:ze.join("/"):"搜索","prefix-icon":e.unref(Ja.search_default),clearable:"",onInput:q,disabled:((te=u.value)==null?void 0:te.length)===0},{suffix:e.withCtx(()=>{var G,fe;return[!o.value&&((fe=(G=a.filterValues)==null?void 0:G.filter(we=>we))!=null&&fe.join("/"))?(e.openBlock(),e.createBlock(re,{key:0,style:{cursor:"pointer"},onClick:x},{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(_,["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",Wf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((se=a.buttons)==null?void 0:se.filter(G=>a.isDevMode||(G==null?void 0:G.label)!=="修改模板"),(G,fe)=>{var we;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:fe},[(G==null?void 0:G.type)==="upload"?(e.openBlock(),e.createBlock(ue,{key:0,class:"upload-button-wrap","on-change":w,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1},{default:e.withCtx(()=>{var _e;return[e.createElementVNode("div",Gf,[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"]),e.createElementVNode("span",Kf,e.toDisplayString(G==null?void 0:G.label),1)])]}),_:2},1024)):e.createCommentVNode("",!0),(G==null?void 0:G.type)==="popover"?(e.openBlock(),e.createBlock(pl._sfc_main,{key:1},{dropTitle:e.withCtx(()=>[(G==null?void 0:G.type)==="popover"?(e.openBlock(),e.createBlock(U,{key:0,style:{background:"transparent",color:"#000000"}},{icon:e.withCtx(()=>{var _e;return[e.createVNode(X,{class:"table-op-icon",name:(_e=g==null?void 0:g.find(qe=>(qe==null?void 0:qe.label)===(G==null?void 0:G.label)))==null?void 0:_e.icon},null,8,["name"])]}),default:e.withCtx(()=>[e.createTextVNode(" "+e.toDisplayString(G==null?void 0:G.label),1)]),_:2},1024)):e.createCommentVNode("",!0)]),dropMenu:e.withCtx(()=>[e.createElementVNode("div",Yf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G==null?void 0:G.contents,_e=>(e.openBlock(),e.createBlock(U,{key:_e==null?void 0:_e.label,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:qe=>A(_e==null?void 0:_e.label)},{default:e.withCtx(()=>{var qe,ra;return[e.createTextVNode(e.toDisplayString(_e==null?void 0:_e.label),1),(qe=_e==null?void 0:_e.label)!=null&&qe.includes("选中")?(e.openBlock(),e.createElementBlock("span",Jf,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(ra=_e==null?void 0:_e.label)!=null&&ra.includes("全部")?(e.openBlock(),e.createElementBlock("span",Xf,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)]}),_:2},1032,["onClick"]))),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(G!=null&&G.type)||(G==null?void 0:G.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),id:"themeButton",onClick:_e=>!a.lockingPage&&A(G==null?void 0:G.label,G)},[e.createVNode(X,{class:"table-op-icon",name:(we=g==null?void 0:g.find(_e=>(_e==null?void 0:_e.label)===(G==null?void 0:G.label)))==null?void 0:we.icon},null,8,["name"]),e.createElementVNode("span",Qf,e.toDisplayString(G==null?void 0:G.label),1)],10,Zf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])]))}}},a0=pr._export_sfc(e0,[["__scopeId","data-v-c54c7b35"]]),l0={__name:"index",props:{columns:Array,tableData:Array},setup(a){return(l,r)=>{const n=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,o=>{var p;return e.openBlock(),e.createBlock(n,{key:o==null?void 0:o.prop,label:o==null?void 0:o.label,prop:o==null?void 0:o.prop,fixed:(o==null?void 0:o.prop)==="operate"?"right":o==null?void 0:o.fixed,align:(o==null?void 0:o.align)??"left","show-overflow-tooltip":(o==null?void 0:o.showOverflowTooltip)??!0,width:o==null?void 0:o.width,"min-width":(o==null?void 0:o.minWidth)||((o==null?void 0:o.prop)==="operate"?80:(((p=o==null?void 0:o.label)==null?void 0:p.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(o.children,(u,m)=>(e.openBlock(),e.createBlock(pl._sfc_main$2,{key:m,column:u,tableData:a.tableData},e.createSlots({_:2},[e.renderList(l.$slots,(g,y)=>({name:y,fn:e.withCtx(({row:d,slotData:D,item:w,column:q})=>[e.renderSlot(l.$slots,y,e.mergeProps({ref_for:!0},D??d,{item:w??u,slotData:D??d,row:d,column:q,columnProp:u}))])}))]),1032,["column","tableData"]))),128))]),_:2},1032,["label","prop","fixed","align","show-overflow-tooltip","width","min-width"])}),128))]),_:3},8,["data"])}}};class r0 extends Fl.Loader{constructor(l){super(l),this.littleEndian=!0}load(l,r,n,i){const o=this,p=new Fl.FileLoader(o.manager);p.setPath(o.path),p.setResponseType("arraybuffer"),p.setRequestHeader(o.requestHeader),p.setWithCredentials(o.withCredentials),p.load(l,function(c){try{r(o.parse(c))}catch(u){i?i(u):console.error(u),o.manager.itemError(l)}},n,i)}_getDataView(l,r,n,i){switch(n){case"F":return i===8?l.getFloat64(r,this.littleEndian):l.getFloat32(r,this.littleEndian);case"I":return i===1?l.getInt8(r):i===2?l.getInt16(r,this.littleEndian):l.getInt32(r,this.littleEndian);case"U":return i===1?l.getUint8(r):i===2?l.getUint16(r,this.littleEndian):l.getUint32(r,this.littleEndian)}}parse(l){function r(D,w){const q=D.length,A=new Uint8Array(w);let j=0,O=0,E,_,x;do if(E=D[j++],E<32){if(E++,O+E>w)throw new Error("Output buffer is not large enough");if(j+E>q)throw new Error("Invalid compressed data");do A[O++]=D[j++];while(--E)}else{if(_=E>>5,x=O-((E&31)<<8)-1,j>=q)throw new Error("Invalid compressed data");if(_===7&&(_+=D[j++],j>=q))throw new Error("Invalid compressed data");if(x-=D[j++],O+_+2>w)throw new Error("Output buffer is not large enough");if(x<0)throw new Error("Invalid compressed data");if(x>=O)throw new Error("Invalid compressed data");do A[O++]=A[x++];while(--_+2)}while(j<q);return A}function n(D){const w={},q=new Uint8Array(D);let A="",j="",O=0,E=!1;const _=q.length;for(;O<_&&E===!1;){const I=String.fromCharCode(q[O++]);I===`
|
|
2
2
|
`||I==="\r"?(j.trim().toLowerCase().startsWith("data")&&(E=!0),j=""):j+=I,A+=I}const x=A.search(/[\r\n]DATA\s(\S*)\s/i),b=/[\r\n]DATA\s(\S*)\s/i.exec(A.slice(x-1));if(w.data=b[1],w.headerLen=b[0].length+x,w.str=A.slice(0,w.headerLen),w.str=w.str.replace(/#.*/gi,""),w.version=/^VERSION (.*)/im.exec(w.str),w.fields=/^FIELDS (.*)/im.exec(w.str),w.size=/^SIZE (.*)/im.exec(w.str),w.type=/^TYPE (.*)/im.exec(w.str),w.count=/^COUNT (.*)/im.exec(w.str),w.width=/^WIDTH (.*)/im.exec(w.str),w.height=/^HEIGHT (.*)/im.exec(w.str),w.viewpoint=/^VIEWPOINT (.*)/im.exec(w.str),w.points=/^POINTS (.*)/im.exec(w.str),w.version!==null&&(w.version=parseFloat(w.version[1])),w.fields=w.fields!==null?w.fields[1].split(" "):[],w.type!==null&&(w.type=w.type[1].split(" ")),w.width!==null&&(w.width=parseInt(w.width[1])),w.height!==null&&(w.height=parseInt(w.height[1])),w.viewpoint!==null&&(w.viewpoint=w.viewpoint[1]),w.points!==null&&(w.points=parseInt(w.points[1],10)),w.points===null&&(w.points=w.width*w.height),w.size!==null&&(w.size=w.size[1].split(" ").map(function(I){return parseInt(I,10)})),w.count!==null)w.count=w.count[1].split(" ").map(function(I){return parseInt(I,10)});else{w.count=[];for(let I=0,R=w.fields.length;I<R;I++)w.count.push(1)}w.offset={};let S=0;for(let I=0,R=w.fields.length;I<R;I++)w.data==="ascii"?w.offset[w.fields[I]]=I:(w.offset[w.fields[I]]=S,S+=w.size[I]*w.count[I]);return w.rowSize=S,w}const i=n(l),o=[],p=[],c=[],u=[],m=[],g=new Fl.Color;if(i.data==="ascii"){const D=i.offset,A=new TextDecoder().decode(l).slice(i.headerLen).split(`
|
|
3
|
-
`);for(let j=0,O=A.length;j<O;j++){if(A[j]==="")continue;const E=A[j].split(" ");if(D.x!==void 0&&(o.push(parseFloat(E[D.x])),o.push(parseFloat(E[D.y])),o.push(parseFloat(E[D.z]))),D.rgb!==void 0){const _=i.fields.findIndex(X=>X==="rgb"),x=i.type[_],b=parseFloat(E[D.rgb]);let S=b;if(x==="F"){const X=new Float32Array(1);X[0]=b,S=new Int32Array(X.buffer)[0]}const I=(S>>16&255)/255,R=(S>>8&255)/255,re=(S>>0&255)/255;g.setRGB(I,R,re,Fl.SRGBColorSpace),c.push(g.r,g.g,g.b)}D.normal_x!==void 0&&(p.push(parseFloat(E[D.normal_x])),p.push(parseFloat(E[D.normal_y])),p.push(parseFloat(E[D.normal_z]))),D.intensity!==void 0&&u.push(parseFloat(E[D.intensity])),D.label!==void 0&&m.push(parseInt(E[D.label]))}}if(i.data==="binary_compressed"){const D=new Uint32Array(l.slice(i.headerLen,i.headerLen+8)),w=D[0],q=D[1],A=r(new Uint8Array(l,i.headerLen+8,w),q),j=new DataView(A.buffer),O=i.offset;for(let E=0;E<i.points;E++){if(O.x!==void 0){const _=i.fields.indexOf("x"),x=i.fields.indexOf("y"),b=i.fields.indexOf("z");o.push(this._getDataView(j,i.points*O.x+i.size[_]*E,i.type[_],i.size[_])),o.push(this._getDataView(j,i.points*O.y+i.size[x]*E,i.type[x],i.size[x])),o.push(this._getDataView(j,i.points*O.z+i.size[b]*E,i.type[b],i.size[b]))}if(O.rgb!==void 0){const _=i.fields.indexOf("rgb"),x=j.getUint8(i.points*O.rgb+i.size[_]*E+2)/255,b=j.getUint8(i.points*O.rgb+i.size[_]*E+1)/255,S=j.getUint8(i.points*O.rgb+i.size[_]*E+0)/255;g.setRGB(x,b,S,Fl.SRGBColorSpace),c.push(g.r,g.g,g.b)}if(O.normal_x!==void 0){const _=i.fields.indexOf("normal_x"),x=i.fields.indexOf("normal_y"),b=i.fields.indexOf("normal_z");p.push(this._getDataView(j,i.points*O.normal_x+i.size[_]*E,i.type[_],i.size[_])),p.push(this._getDataView(j,i.points*O.normal_y+i.size[x]*E,i.type[x],i.size[x])),p.push(this._getDataView(j,i.points*O.normal_z+i.size[b]*E,i.type[b],i.size[b]))}if(O.intensity!==void 0){const _=i.fields.indexOf("intensity");u.push(this._getDataView(j,i.points*O.intensity+i.size[_]*E,i.type[_],i.size[_]))}if(O.label!==void 0){const _=i.fields.indexOf("label");m.push(j.getInt32(i.points*O.label+i.size[_]*E,this.littleEndian))}}}if(i.data==="binary"){const D=new DataView(l,i.headerLen),w=i.offset;for(let q=0,A=0;q<i.points;q++,A+=i.rowSize){if(w.x!==void 0){const j=i.fields.indexOf("x"),O=i.fields.indexOf("y"),E=i.fields.indexOf("z");o.push(this._getDataView(D,A+w.x,i.type[j],i.size[j])),o.push(this._getDataView(D,A+w.y,i.type[O],i.size[O])),o.push(this._getDataView(D,A+w.z,i.type[E],i.size[E]))}if(w.rgb!==void 0){const j=D.getUint8(A+w.rgb+2)/255,O=D.getUint8(A+w.rgb+1)/255,E=D.getUint8(A+w.rgb+0)/255;g.setRGB(j,O,E,Fl.SRGBColorSpace),c.push(g.r,g.g,g.b)}if(w.normal_x!==void 0){const j=i.fields.indexOf("normal_x"),O=i.fields.indexOf("normal_y"),E=i.fields.indexOf("normal_z");p.push(this._getDataView(D,A+w.normal_x,i.type[j],i.size[j])),p.push(this._getDataView(D,A+w.normal_y,i.type[O],i.size[O])),p.push(this._getDataView(D,A+w.normal_z,i.type[E],i.size[E]))}if(w.intensity!==void 0){const j=i.fields.indexOf("intensity");u.push(this._getDataView(D,A+w.intensity,i.type[j],i.size[j]))}w.label!==void 0&&m.push(D.getInt32(A+w.label,this.littleEndian))}}const y=new Fl.BufferGeometry;o.length>0&&y.setAttribute("position",new Fl.Float32BufferAttribute(o,3)),p.length>0&&y.setAttribute("normal",new Fl.Float32BufferAttribute(p,3)),c.length>0&&y.setAttribute("color",new Fl.Float32BufferAttribute(c,3)),u.length>0&&y.setAttribute("intensity",new Fl.Float32BufferAttribute(u,1)),m.length>0&&y.setAttribute("label",new Fl.Int32BufferAttribute(m,1)),y.computeBoundingSphere();const d=new Fl.PointsMaterial({size:.005});return c.length>0&&(d.vertexColors=!0),new Fl.Points(y,d)}}const n0=M.useModelComp(M.pinia),{systemPath:Cs}=M.storeToRefs(n0),go=e.ref(),Ds=new WeakMap;function i0(a,l,r,n,i){const o=async d=>{try{const D=await M.platformDownloadFile({url:d});if(D.status!==200)throw new Error(`下载失败: ${D.status}`);return D.data}catch(D){throw console.error("addModelFromUrl失败:",D),D}},p=d=>new Promise((D,w)=>{const q=new FileReader;q.onload=A=>{try{const j=A.target.result,E=new Yn.MTLLoader().parse(j);E.preload(),D(E)}catch(j){w(j)}},q.onerror=()=>{w(new Error("MTL文件读取失败"))},q.readAsText(d)}),c=async d=>{const D={materials:{},create:function(w){return this.materials[w]?this.materials[w]:(console.warn(`Material '${w}' not found, using default material`),new Fl.MeshPhongMaterial({color:8947848,side:Fl.DoubleSide}))},getAsArray:function(){const w=[];for(const q in this.materials)w.push(this.materials[q]);return w},preload:function(){for(const w in this.materials)this.materials[w].map&&(this.materials[w].map.needsUpdate=!0)}};for(const w of d){const q=await p(w);Object.assign(D.materials,q.materials)}return D.preload(),D},u=async(d,D=[])=>new Promise((w,q)=>{const A=new FileReader;A.onload=async j=>{try{const O=j.target.result;let E=null;D&&D.length>0&&(D.length===1?E=await p(D[0]):E=await c(D));const _=new Yn.OBJLoader;E&&_.setMaterials(E);const x=_.parse(O);E||x.traverse(b=>{b.isMesh&&(b.material=new Fl.MeshPhongMaterial({color:8947848,side:Fl.DoubleSide}))}),w(x)}catch(O){q(O)}},A.onerror=()=>{q(new Error("OBJ文件读取失败"))},A.readAsText(d)}),m=async d=>{var D;try{r.value=!0;const{scene:w}=a();if(!w)throw new Error("Scene not initialized");i();const q=[];for(let A=0;A<d.length;A++){const j=d[A];n.value=`正在加载模型 ${A+1}/${d.length}...`;const O=await o(j.objUrl),E=((D=j.objUrl)==null?void 0:D.split("/").pop())||`model_${A}.obj`,_=new File([O],E,{type:O.type});let x=[];if(j.mtlUrls){const S=Array.isArray(j.mtlUrls)?j.mtlUrls:[j.mtlUrls];for(let I=0;I<S.length;I++){const R=S[I],re=await o(R),X=(R==null?void 0:R.split("/").pop())||`material_${A}_${I}.mtl`,me=new File([re],X,{type:re.type});x.push(me)}}const b=await u(_,x);w.add(b),l.value.push(b),q.push(b)}return r.value=!1,q}catch(w){throw console.error("加载模型失败:",w),r.value=!1,w}},g=async(d,D,w=[],q=[])=>{let A;const j=d.toLowerCase();switch(j){case".txt":case".cpt":case".obj":const O=await D.text();if(j===".txt"||j===".cpt"){const P=/^(?!.*\bf\b)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?$/gm,Me=[...O.matchAll(P)].map(de=>({x:parseFloat(de[1]),y:parseFloat(de[2]),z:parseFloat(de[3])})),Le=new Fl.BufferGeometry,Ie=Me.flatMap(de=>[de.x,de.y,de.z]);if(Le.setAttribute("position",new Fl.Float32BufferAttribute(Ie,3)),j===".txt"){const de=new Fl.PointsMaterial({color:"#5B5C99",size:1,sizeAttenuation:!1});A=new Fl.Points(Le,de)}else if(j===".cpt"){const de=new Fl.LineBasicMaterial({color:"#5B5C99",linewidth:100});A=new Fl.Line(Le,de)}}else if(j===".obj"){const P=new Yn.OBJLoader;if(w&&w.length>0){const Ke=new Yn.MTLLoader;for(const Me of w){const Le=await Me.text(),Ie=Ke.parse(Le);Ie.preload(),P.setMaterials(Ie);break}}A=P.parse(O),(!w||w.length===0)&&A.traverse(Ke=>{Ke.isMesh&&(Ke.material=new Fl.MeshPhongMaterial({color:"#B3B3D4"})),Ke instanceof Fl.Mesh&&(Ke.material.side=Fl.DoubleSide)})}break;case".stl":const E=await D.arrayBuffer(),x=new Yn.STLLoader().parse(E),b=new Fl.MeshPhongMaterial({color:"#B3B3D4",side:Fl.DoubleSide});A=new Fl.Mesh(x,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"],I={"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)"},R=new Fl.Group,re=S.map(P=>new Promise((Ke,Me)=>{new Yn.STLLoader().load(Cs.value===""?`/model/${P}`:`${Cs.value}\\${P}`,Ie=>{const de=new Fl.MeshPhongMaterial({color:I[P]||"#B3B3D4",side:Fl.DoubleSide}),De=new Fl.Mesh(Ie,de);Ke(De)},void 0,Me)}));try{(await Promise.all(re)).forEach(Ke=>R.add(Ke)),A=R}catch(P){throw console.error("加载NC文件对应的STL文件失败:",P),new Error("无法加载.NC文件对应的STL文件")}break;case".pcd":const X=new r0,me=new Fl.Group;try{const P=await Ja.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/target.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),Ke=new Blob([P.data],{type:"application/octet-stream;charset=UTF-8"}),Me=await Ja.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/final.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),Le=new Blob([Me.data],{type:"application/octet-stream;charset=UTF-8"}),Ie=await new Promise((De,Xe)=>{const Ea=URL.createObjectURL(Ke);X.load(Ea,Ge=>{const $=new Float32Array(Ge.geometry.attributes.position.count*3);for(let V=0;V<Ge.geometry.attributes.position.count;V++)$[V*3]=1,$[V*3+1]=0,$[V*3+2]=0;Ge.geometry.setAttribute("color",new Fl.BufferAttribute($,3)),Ge.material.vertexColors=!0,Ge.scale.set(.3,.3,.3),URL.revokeObjectURL(Ea),De(Ge)},void 0,Xe)}),de=await new Promise((De,Xe)=>{const Ea=URL.createObjectURL(Le);X.load(Ea,Ge=>{const $=new Float32Array(Ge.geometry.attributes.position.count*3);for(let V=0;V<Ge.geometry.attributes.position.count;V++)$[V*3]=0,$[V*3+1]=1,$[V*3+2]=0;Ge.geometry.setAttribute("color",new Fl.BufferAttribute($,3)),Ge.material.vertexColors=!0,Ge.scale.set(.3,.3,.3),URL.revokeObjectURL(Ea),De(Ge)},void 0,Xe)});me.add(Ie),me.add(de),A=me}catch(P){throw console.error("PCD文件加载失败:",P),new Error("无法加载PCD文件")}break;case".urdf":const ue=URL.createObjectURL(D),U=new ld.URDFLoader,W="http://139.196.154.85:20026/chfs/shared/机器人/urdf/SmallBender_R-2000iC-165F/meshes",Z={maxConcurrentLoads:4,enableCache:!0,enableLOD:!0,simplifyGeometry:!0,shareMaterials:!0,enableInstancing:!0},ae=new WeakMap,ve=new WeakMap,ze=new WeakMap,te=async P=>{if(ae.has(P))return console.log(`从缓存加载: ${P}`),ae.get(P);try{const Ke=await Ja.axios.get(`${W}/${P}`,{responseType:"blob",headers:{"Content-Type":"application/json"},timeout:6e5}),Me=new Blob([Ke.data],{type:"application/octet-stream;charset=UTF-8"});return Z.enableCache&&ae.set(P,Me),Me}catch(Ke){throw console.error(`加载文件失败: ${P}`,Ke),new Error(`无法加载文件: ${P}`)}},N=(P="default")=>{if(ve.has(P))return ve.get(P);const Ke=new Fl.MeshPhongMaterial({color:12303291,shininess:30,transparent:!1,alphaTest:.1,side:Fl.FrontSide});return ve.set(P,Ke),Ke},se=P=>{try{P.isBufferGeometry&&P.mergeVertices&&P.mergeVertices(),P.computeVertexNormals&&P.computeVertexNormals(),P.computeBoundingSphere&&P.computeBoundingSphere(),P.deleteAttribute&&P.deleteAttribute("uv2")}catch(Ke){console.warn("几何体优化失败,使用原始几何体:",Ke)}return P},G=async(P,Ke,Me)=>{const Le=`stl_${Ke}`;if(ze.has(Le)){const Xe=ze.get(Le);return new Fl.Mesh(Xe,N())}const Ie=await P.arrayBuffer();let De=new Yn.STLLoader(Me).parse(Ie);return De=se(De),ze.set(Le,De),new Fl.Mesh(De,N())},fe=async(P,Ke,Me)=>{const Le=`obj_${Ke}`;if(ae.has(Le))return ae.get(Le).clone();const Ie=await P.text(),de=new Yn.OBJLoader(Me),De=Ke.replace(".obj",".mtl");try{const Ge=await(await te(De)).text(),V=new Yn.MTLLoader(Me).parse(Ge);V.preload(),de.setMaterials(V)}catch{console.warn(`MTL文件加载失败,使用默认材质: ${De}`)}const Xe=de.parse(Ie);return Xe.traverse(Ea=>{Ea.isMesh&&(Ea.geometry=se(Ea.geometry),Ea.castShadow=!0,Ea.receiveShadow=!0,Ea.renderOrder=1)}),ae.set(Le,Xe),Xe},we=(P,Ke)=>{const Me=new Fl.LOD;if(Me.addLevel(P,0),P.geometry){const Le=P.geometry.clone(),Ie=new Fl.Mesh(Le,P.material);Me.addLevel(Ie,50)}return Me};let _e=0,qe=0;const ra=[];U.loadMeshCb=async(P,Ke,Me,Le,Ie)=>{const de=P.split("/").pop(),De=Me||(()=>{});_e++;const Xe=new Promise(async(Ea,Ge)=>{try{const $=await te(de);if(!$||$.size===0)throw new Error(`文件为空: ${de}`);const V=de.split(".").pop().toLowerCase();let ee;switch(V){case"stl":ee=await G($,de,Ke);break;case"obj":ee=await fe($,de,Ke);break;default:throw new Error(`不支持的文件格式: ${V}`)}Z.enableLOD&&ee.isMesh&&(ee=we(ee,de)),De(ee),qe++,Le&&Le({loaded:qe,total:_e,progress:qe/_e}),Ea(ee)}catch($){console.error(`mesh文件加载失败: ${de}`,$);const V=new Fl.Group;De(V),Ea(V);const ee=new Fl.BoxGeometry(.1,.1,.1),ce=new Fl.MeshStandardMaterial({color:16711680,wireframe:!0});return new Fl.Mesh(ee,ce)}});ra.push(Xe)};try{if(!ue){go.value=void 0;break}if(A=await U.loadAsync(ue),console.log(`URDF文件加载完成,等待${_e}个mesh文件加载...`),ra.length>0)try{await Promise.allSettled(ra),console.log(`所有mesh文件处理完成,成功加载: ${qe}/${_e}`)}catch(Me){console.warn("部分mesh文件加载失败,但继续显示模型",Me)}A.traverse(Me=>{Me.isMesh&&(Me.castShadow=!0,Me.receiveShadow=!0,Me.renderOrder=1,Me.material&&(Me.material.needsUpdate=!0))}),console.time("计算包围盒");const P=new Fl.Box3;P.expandByObject(A);const Ke=`urdf_${Date.now()}`;A.userData.boundingBox=P.clone(),A.userData.modelId=Ke,Ds.set(Ke,{box:P.clone(),center:P.getCenter(new Fl.Vector3),size:P.getSize(new Fl.Vector3),maxSize:Math.max(...P.getSize(new Fl.Vector3).toArray())}),go.value=A,console.log("URDF模型加载完成并优化")}catch(P){console.error("URDF加载失败:",P),go.value=void 0}finally{ue&&URL.revokeObjectURL(ue)}break;default:throw new Error(`不支持的文件格式: ${d}`)}return A};return{addModelsFromUrls:m,loadModelByDefaultPath:async d=>{console.log(d);try{r.value=!0,n.value="正在加载模型...";const{scene:D}=a();if(!D)throw new Error("Scene not initialized");i(),await new Promise(q=>setTimeout(q,100));const w=[];for(let q=0;q<d.length;q++){const A=d[q],j=await g(A.suffix,A.blob,A.mtlBlobs||[],A.meshFiles||[]);j&&(D.add(j),l.value.push(j),w.push(j))}return r.value=!1,n.value="",w}catch(D){throw console.error("加载模型失败:",D),r.value=!1,n.value="",D}},urdfModel:go,modelBoundingBoxes:Ds}}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=(r=(r=document.getElementsByTagName("script"))[r.length-1]).getAttribute("data-injectcss"),r=r.getAttribute("data-disable-injectsvg");if(!r){var n,i,o,p,c,u=function(y,d){d.parentNode.insertBefore(y,d)};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(y){console&&console.log(y)}}n=function(){var y,d=document.createElement("div");d.innerHTML=a._iconfont_svg_string_4827314,(d=d.getElementsByTagName("svg")[0])&&(d.setAttribute("aria-hidden","true"),d.style.position="absolute",d.style.width=0,d.style.height=0,d.style.overflow="hidden",d=d,(y=document.body).firstChild?u(d,y.firstChild):y.appendChild(d))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(n,0):(i=function(){document.removeEventListener("DOMContentLoaded",i,!1),n()},document.addEventListener("DOMContentLoaded",i,!1)):document.attachEvent&&(o=n,p=a.document,c=!1,g(),p.onreadystatechange=function(){p.readyState=="complete"&&(p.onreadystatechange=null,m())})}function m(){c||(c=!0,o())}function g(){try{p.documentElement.doScroll("left")}catch{return void setTimeout(g,50)}m()}})(window);const o0=["onClick"],t0=["src"],s0=["src"],c0=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:""},backgroundPosition:{default:"Center"},iconUrl:{default:void 0},calculator:{default:()=>[]},textBackColor:{default:void 0}},emits:["update:backGroundImage"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(null),o=e.ref(null),p=x=>{var S,I,R,re;let b={};if(x!=null&&x.find(X=>X==null?void 0:X.includes("@TextSize"))){let X=(I=(S=x==null?void 0:x.find(me=>me==null?void 0:me.includes("@TextSize")))==null?void 0:S.split("="))==null?void 0:I[1];b.fontSize=`${X}px`}if(x!=null&&x.find(X=>X==null?void 0:X.includes("@TextRGBA"))){let X=(re=(R=x==null?void 0:x.find(me=>me==null?void 0:me.includes("@TextRGBA")))==null?void 0:R.split("="))==null?void 0:re[1];b.color=le.rgbaToColor(X)}return b},c=e.computed(()=>{const x=Number(r==null?void 0:r.textSize),b=le.rgbaToColor(r==null?void 0:r.textColor),S={},I={};return!Number.isNaN(x)&&x&&(S.fontSize=`${x}px`,I.fontSize=`${x}px`),b&&(S.color=b,I.color=b),{label:S,value:I}}),u=e.ref(""),m=e.ref(""),g=e.ref(!1),y=async x=>{if(x){m.value&&(URL.revokeObjectURL(m.value),m.value="");try{const b=await M.platformDownloadFile({url:x}),S=new Blob([b==null?void 0:b.data],{type:(b==null?void 0:b.headers["content-type"])||"image/*"});m.value=URL.createObjectURL(S)}catch{m.value=""}}};e.watch(()=>r==null?void 0:r.backGroundImage,x=>{x&&(u.value=x)},{immediate:!0}),e.watch(u,x=>{y(x)},{immediate:!0});const d=async()=>{var x,b;((x=r==null?void 0:r.calculator)==null?void 0:x.length)>0&&await Vt(r==null?void 0:r.items,"Auto",[],r==null?void 0:r.calculator),(b=o.value)==null||b.click()},D=async x=>{var I,R,re;const b=x.target,S=(I=b==null?void 0:b.files)==null?void 0:I[0];if(!S){b.value="";return}g.value=!0;try{const X=new FormData;X.append("file",S);const me=await M.platformUploadFile(X),ue=(re=(R=me==null?void 0:me.data)==null?void 0:R.result)==null?void 0:re.url;ue?(u.value=ue,n("update:backGroundImage",ue),y(ue),Ja.ElMessage.success("背景图片上传成功")):Ja.ElMessage.error("背景图片上传失败")}catch{Ja.ElMessage.error("背景图片上传失败")}finally{g.value=!1,b.value=""}},w=e.computed(()=>{var x,b,S,I;return m.value||(r==null?void 0:r.backgroundUrl)!==""?{backgroundImage:`url("${(x=r==null?void 0:r.backgroundUrl)==null?void 0:x.replace(/\\/g,"/")}")`,backgroundPosition:`${((b=r==null?void 0:r.backgroundPosition)==null?void 0:b.toLowerCase())??"center"} center`,backgroundRepeat:"no-repeat",cursor:((S=r==null?void 0:r.calculator)==null?void 0:S.length)>0?"pointer":"auto"}:{cursor:((I=r==null?void 0:r.calculator)==null?void 0:I.length)>0?"pointer":"auto",background:r!=null&&r.textBackColor?le.rgbaToColor(r==null?void 0:r.textBackColor):void 0}}),q=x=>pl.getComponent(x),A=x=>{if(!x)return;const b=x.querySelector("input, textarea, .el-input__inner");b&&typeof b.focus=="function"&&b.focus()},j=(x,b,S)=>{r.disabled||x.field&&(i.value=b,e.nextTick(()=>{A(S.currentTarget)}))},O=()=>{i.value=null},E=x=>{var S;const b=((S=x==null?void 0:x.field)==null?void 0:S.value)??(x==null?void 0:x.value);return b==null||b===""?"-":b},_=x=>{var re,X,me,ue;const b=x!=null&&x.width&&x.width>0?x.width:1,I=`calc((100% - ${(b-1)*16}px) / ${b})`;let R;return(re=x==null?void 0:x.filters)!=null&&re.find(U=>U==null?void 0:U.includes("@TextBackRGBA"))&&(R=(ue=(me=(X=x==null?void 0:x.filters)==null?void 0:X.find(U=>U==null?void 0:U.includes("@TextBackRGBA")))==null?void 0:me.split("="))==null?void 0:ue[1],R=le.rgbaToColor(R)),{flex:`0 0 ${I}`,maxWidth:I,minWidth:"140px",boxSizing:"border-box",background:R}};return(x,b)=>(e.openBlock(),e.createElementBlock("div",{class:"statistics-cards-container",style:e.normalizeStyle(w.value),onClick:b[1]||(b[1]=S=>d())},[r!=null&&r.backGround?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-backGround-upload",onClick:b[0]||(b[0]=e.withModifiers(S=>d(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:o,type:"file",accept:"image/*",style:{display:"none"},onChange:D},null,544),b[2]||(b[2]=e.createElementVNode("img",{src:pl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.items,(S,I)=>{var R,re,X,me,ue,U,W,Z;return e.openBlock(),e.createElementBlock("div",{class:"statistics-card",key:I,style:e.normalizeStyle(_(S))},[e.createElementVNode("div",{class:"statistics-label",style:e.normalizeStyle({...c.value.label,...p(S==null?void 0:S.filters)})},e.toDisplayString(S==null?void 0:S.label),5),e.createElementVNode("div",{class:"statistics-value",style:e.normalizeStyle(c.value.value),onClick:ae=>{var ve;return(ve=S.field)!=null&&ve.isNoClick?null:j(S,I,ae)}},[x.iconUrl&&x.backgroundPosition==="Left"?(e.openBlock(),e.createElementBlock("img",{key:0,src:x.iconUrl,class:"bg-upload-icon"},null,8,t0)):e.createCommentVNode("",!0),i.value===I&&S.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(q(((R=S.field)==null?void 0:R.type)??"Input")),{key:1,modelValue:S.field.value,"onUpdate:modelValue":ae=>S.field.value=ae,isEdit:!0,disabled:(re=S.field)==null?void 0:re.disabled,content:((X=S.field)==null?void 0:X.contents)??[],optionUrl:S.field,originalValue:(me=S.field)==null?void 0:me.value,config:(ue=S.field)==null?void 0:ue.config,configModel:((U=S.field)==null?void 0:U.prop)??((W=S.field)==null?void 0:W.name),selectedTagList:((Z=S.field)==null?void 0:Z.selectValue)??[],onBlur:O,onBlurChange:O},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(E(S)),1)],64)),x.iconUrl&&x.backgroundPosition==="Right"?(e.openBlock(),e.createElementBlock("img",{key:3,src:x.iconUrl,class:"bg-upload-icon"},null,8,s0)):e.createCommentVNode("",!0)],12,o0)],4)}),128))],4))}}),u0=pr._export_sfc(c0,[["__scopeId","data-v-3e28c1c9"]]),Ec=M.defineStore("formToTableComp",{state:()=>({selectArray:[],selectString:""}),actions:{setSelectArray(a){this.selectArray=a},setSelectString(a){this.selectString=a}}}),d0={class:"calculator-content"},p0={class:"calculator-child"},f0={class:"calculator-child"},h0=e.defineComponent({__name:"calculator",setup(a){const l=e.ref(),r=e.ref();return e.onMounted(()=>{l.value=[{type:"Upload",label:"输入",name:"input"}],r.value=[{type:"Upload",label:"输出",name:"output"}]}),(n,i)=>(e.openBlock(),e.createElementBlock("div",d0,[e.createElementVNode("div",p0,[e.createVNode(pl.ssForm,{rowContents:l.value,isRowFlex:!0},null,8,["rowContents"])]),e.createElementVNode("div",f0,[e.createVNode(pl.ssForm,{rowContents:r.value,isEdit:!1,isRowFlex:!0},null,8,["rowContents"])])]))}}),v0=pr._export_sfc(h0,[["__scopeId","data-v-73db0fe7"]]),Nt=(a,l)=>{let r=a,n=l;return Array.isArray(r)&&(r=r==null?void 0:r.map((i,o)=>{if(Array.isArray(i)){let p={};return i=i==null?void 0:i.forEach((c,u)=>{var m;(m=n==null?void 0:n[u])!=null&&m.prop?p[n[u].prop]=c:Array.isArray(c)&&(p.children=Nt(c,n))}),Object.assign(p,{id:o})}else return i})),r},Cc=(a,l,r)=>{let n=a,i=l;return n=n==null?void 0:n.map((o,p)=>{var c,u;return!Array.isArray(o)||!((c=i==null?void 0:i[p])!=null&&c.label)&&!r||(o.unshift(((u=i==null?void 0:i[p])==null?void 0:u.label)??""),o.some(m=>Array.isArray(m))&&(o=o==null?void 0:o.map(m=>{var g;return Array.isArray(m)&&(m=Cc(m,(g=i==null?void 0:i[p])==null?void 0:g.children,r)),m}))),o}),n},m0=(a,l,r)=>{if(l==="")return a==null?void 0:a.filter(n=>(n==null?void 0:n.id)!==r);{const n=l.split("-");return y0(a,n,r)}},y0=(a,l,r)=>{let n=a,i=l;return(i==null?void 0:i.length)===0?n=n==null?void 0:n.filter(o=>o.id!==r):n=n==null?void 0:n.map(o=>(o.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),o=Dc(o,i,r)),o)),n},Dc=(a,l,r)=>{var o,p;let n=a,i=l;return(i==null?void 0:i.length)===0?n.children=(o=n.children)==null?void 0:o.filter(c=>c.id!==r):n.children=(p=n.children)==null?void 0:p.map(c=>(c.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),c=Dc(c,i,r)),c)),n},g0=(a,l,r)=>{if(l==="")return r;{const n=l.split("-");return b0(a,n,r)}},b0=(a,l,r)=>{let n=a,i=l;return(i==null?void 0:i.length)===0?n=r:n=n==null?void 0:n.map(o=>(o.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),o=Tc(o,i,r)),o)),n},Tc=(a,l,r)=>{var o;let n=a,i=l;return(i==null?void 0:i.length)===0?n.children=r:n.children=(o=n.children)==null?void 0:o.map(p=>(p.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),p=Tc(p,i,r)),p)),n};class k0{constructor(l={}){fn(this,"url");fn(this,"heartbeatInterval");fn(this,"socket",null);fn(this,"isConnected",!1);fn(this,"heartTimer",null);fn(this,"canvas",null);fn(this,"ctx",null);fn(this,"mainCamCutMode",0);fn(this,"pMainShowStartX",0);fn(this,"pMainShowStartY",0);fn(this,"onLog");fn(this,"onDevCount");fn(this,"onResolution");fn(this,"onCameraStatus");fn(this,"onPhoto");this.url=l.url??"ws://127.0.0.1:22225",this.heartbeatInterval=l.heartbeatInterval??3e3}init(l,r,n){var p;(p=this.canvas)!=null&&p.parentNode&&this.canvas.parentNode.removeChild(this.canvas);const i=document.createElement("canvas");i.style.border="solid 1px #A0A0A0",i.id="MainCamCanvas",i.width=r,i.height=n;const o=i.getContext("2d");if(!o)throw new Error("无法获取 CanvasRenderingContext2D");l.appendChild(i),this.canvas=i,this.ctx=o}async connect(){this.socket&&(this.socket.readyState===WebSocket.OPEN||this.socket.readyState===WebSocket.CONNECTING)||await new Promise((l,r)=>{const n=new WebSocket(this.url);n.binaryType="arraybuffer",n.onopen=()=>{this.socket=n,this.isConnected=!0,this.startHeartbeat(),this.log("socket.onopen"),l()},n.onerror=i=>{this.isConnected=!1,this.log("socket.onerror"),r(i)},n.onclose=()=>{this.isConnected=!1,this.stopHeartbeat(),this.log("socket.onclose")},n.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 r=l.find(i=>i.width===2592&&i.height===1944);return r||[...l].sort((i,o)=>o.width*o.height-i.width*i.height)[0]||null}openCamera(l=0,r=1280,n=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]=r>>8&255,i[9]=r&255,i[10]=n>>8&255,i[11]=n&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 r;(r=this.onLog)==null||r.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,o,p,c,u,m;const r=new Uint8Array(l.data);if(r.length<=0)return;if(r[0]===17&&r[1]===17&&r[2]===17){this.log("heart socket!!!!");return}if(r[0]!==85||r[1]!==102)return;const n=r[2];if(n===80){const g=r[3],y=r.length-4,d=new Uint8Array(y);for(let q=0;q<y;q++)d[q]=r[4+q];const w=decodeURIComponent(this.byteToString(d)).split("|");(i=this.onDevCount)==null||i.call(this,g,w);return}if(n===81){const g=r[3]||0,y=[];for(let d=0;d<g;d++){const D=(r[4+d*4+0]||0)*256+(r[4+d*4+1]||0),w=(r[4+d*4+2]||0)*256+(r[4+d*4+3]||0);y.push({width:D,height:w,text:`${D}*${w}`})}(o=this.onResolution)==null||o.call(this,g,y);return}if(n===1){r[3]===1&&((p=this.onCameraStatus)==null||p.call(this,"opened")),r[3]===3&&((c=this.onCameraStatus)==null||c.call(this,"closed"));return}if(n===16){if(r[3]===1){const y=r[4]*256+r[5],d=r[6]*65536+r[7]*256+r[8];let D="";if(y>0){const A=new Uint8Array(y);for(let j=0;j<y;j++)A[j]=r[9+j];D=decodeURIComponent(this.byteToString(A))}const w=new Uint8Array(d);for(let A=0;A<d;A++)w[A]=r[9+y+A];const q=this.uint8ArrayToString(w);(u=this.onPhoto)==null||u.call(this,{flag:0,imgPath:D,base64:q})}r[3]===2&&((m=this.onPhoto)==null||m.call(this,{flag:2,imgPath:"",base64:""}));return}if(n===204){if(!this.canvas||!this.ctx)return;const g=r[3]*256+r[4],y=r[5]*256+r[6];this.pMainShowStartX=r[7]*256+r[8],this.pMainShowStartY=r[9]*256+r[10],this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height);const d=this.ctx.createImageData(g,y);let D=11;for(let w=0;w<d.data.length;w+=4)d.data[w+0]=r[D],d.data[w+1]=r[D+1],d.data[w+2]=r[D+2],d.data[w+3]=255,D+=3;this.ctx.putImageData(d,this.pMainShowStartX,this.pMainShowStartY),this.mainCamCutMode;return}}uint8ArrayToString(l){let r="";for(let n=0;n<l.length;n++)r+=String.fromCharCode(l[n]);return r}byteToString(l){let r="";for(let n=0;n<l.length;n++)r+=String.fromCharCode(l[n]);return r}}const x0={style:{display:"flex",gap:"16px",height:"100%"}},w0={key:0,style:{color:"var(--el-text-color-secondary)"}},_0={style:{width:"420px",display:"flex","flex-direction":"column",gap:"16px"}},S0={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px"}},E0={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"}},C0={key:0,style:{height:"100%",display:"flex","align-items":"center","justify-content":"center",color:"var(--el-text-color-secondary)"}},D0={key:1,style:{display:"grid","grid-template-columns":"repeat(2, minmax(0, 1fr))",gap:"8px"}},T0=["src","onClick"],B0=["onClick"],N0={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px",flex:"1","min-height":"0",display:"flex","flex-direction":"column"}},A0={class:"dialog-footer"},z0=e.defineComponent({__name:"index",props:{visible:{type:Boolean,default:!1}},emits:["confirm","cancel"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(null),o=e.ref(!1),p=e.ref([]),c=e.ref(""),u=e.ref(!1),m=e.ref([]),g=new k0({url:"ws://127.0.0.1:22225"});function y(R,re){var Z;const X=R.split(","),me=((Z=X[0].match(/:(.*?);/))==null?void 0:Z[1])??"image/jpeg",ue=atob(X[1]);let U=ue.length;const W=new Uint8Array(U);for(;U--;)W[U]=ue.charCodeAt(U);return new File([W],re,{type:me})}function d(){g.onLog=R=>{console.log("[GPY]",R)},g.onDevCount=(R,re)=>{if(c.value+=`设备数量=${R},设备=${re.join(",")}
|
|
3
|
+
`);for(let j=0,O=A.length;j<O;j++){if(A[j]==="")continue;const E=A[j].split(" ");if(D.x!==void 0&&(o.push(parseFloat(E[D.x])),o.push(parseFloat(E[D.y])),o.push(parseFloat(E[D.z]))),D.rgb!==void 0){const _=i.fields.findIndex(X=>X==="rgb"),x=i.type[_],b=parseFloat(E[D.rgb]);let S=b;if(x==="F"){const X=new Float32Array(1);X[0]=b,S=new Int32Array(X.buffer)[0]}const I=(S>>16&255)/255,R=(S>>8&255)/255,re=(S>>0&255)/255;g.setRGB(I,R,re,Fl.SRGBColorSpace),c.push(g.r,g.g,g.b)}D.normal_x!==void 0&&(p.push(parseFloat(E[D.normal_x])),p.push(parseFloat(E[D.normal_y])),p.push(parseFloat(E[D.normal_z]))),D.intensity!==void 0&&u.push(parseFloat(E[D.intensity])),D.label!==void 0&&m.push(parseInt(E[D.label]))}}if(i.data==="binary_compressed"){const D=new Uint32Array(l.slice(i.headerLen,i.headerLen+8)),w=D[0],q=D[1],A=r(new Uint8Array(l,i.headerLen+8,w),q),j=new DataView(A.buffer),O=i.offset;for(let E=0;E<i.points;E++){if(O.x!==void 0){const _=i.fields.indexOf("x"),x=i.fields.indexOf("y"),b=i.fields.indexOf("z");o.push(this._getDataView(j,i.points*O.x+i.size[_]*E,i.type[_],i.size[_])),o.push(this._getDataView(j,i.points*O.y+i.size[x]*E,i.type[x],i.size[x])),o.push(this._getDataView(j,i.points*O.z+i.size[b]*E,i.type[b],i.size[b]))}if(O.rgb!==void 0){const _=i.fields.indexOf("rgb"),x=j.getUint8(i.points*O.rgb+i.size[_]*E+2)/255,b=j.getUint8(i.points*O.rgb+i.size[_]*E+1)/255,S=j.getUint8(i.points*O.rgb+i.size[_]*E+0)/255;g.setRGB(x,b,S,Fl.SRGBColorSpace),c.push(g.r,g.g,g.b)}if(O.normal_x!==void 0){const _=i.fields.indexOf("normal_x"),x=i.fields.indexOf("normal_y"),b=i.fields.indexOf("normal_z");p.push(this._getDataView(j,i.points*O.normal_x+i.size[_]*E,i.type[_],i.size[_])),p.push(this._getDataView(j,i.points*O.normal_y+i.size[x]*E,i.type[x],i.size[x])),p.push(this._getDataView(j,i.points*O.normal_z+i.size[b]*E,i.type[b],i.size[b]))}if(O.intensity!==void 0){const _=i.fields.indexOf("intensity");u.push(this._getDataView(j,i.points*O.intensity+i.size[_]*E,i.type[_],i.size[_]))}if(O.label!==void 0){const _=i.fields.indexOf("label");m.push(j.getInt32(i.points*O.label+i.size[_]*E,this.littleEndian))}}}if(i.data==="binary"){const D=new DataView(l,i.headerLen),w=i.offset;for(let q=0,A=0;q<i.points;q++,A+=i.rowSize){if(w.x!==void 0){const j=i.fields.indexOf("x"),O=i.fields.indexOf("y"),E=i.fields.indexOf("z");o.push(this._getDataView(D,A+w.x,i.type[j],i.size[j])),o.push(this._getDataView(D,A+w.y,i.type[O],i.size[O])),o.push(this._getDataView(D,A+w.z,i.type[E],i.size[E]))}if(w.rgb!==void 0){const j=D.getUint8(A+w.rgb+2)/255,O=D.getUint8(A+w.rgb+1)/255,E=D.getUint8(A+w.rgb+0)/255;g.setRGB(j,O,E,Fl.SRGBColorSpace),c.push(g.r,g.g,g.b)}if(w.normal_x!==void 0){const j=i.fields.indexOf("normal_x"),O=i.fields.indexOf("normal_y"),E=i.fields.indexOf("normal_z");p.push(this._getDataView(D,A+w.normal_x,i.type[j],i.size[j])),p.push(this._getDataView(D,A+w.normal_y,i.type[O],i.size[O])),p.push(this._getDataView(D,A+w.normal_z,i.type[E],i.size[E]))}if(w.intensity!==void 0){const j=i.fields.indexOf("intensity");u.push(this._getDataView(D,A+w.intensity,i.type[j],i.size[j]))}w.label!==void 0&&m.push(D.getInt32(A+w.label,this.littleEndian))}}const y=new Fl.BufferGeometry;o.length>0&&y.setAttribute("position",new Fl.Float32BufferAttribute(o,3)),p.length>0&&y.setAttribute("normal",new Fl.Float32BufferAttribute(p,3)),c.length>0&&y.setAttribute("color",new Fl.Float32BufferAttribute(c,3)),u.length>0&&y.setAttribute("intensity",new Fl.Float32BufferAttribute(u,1)),m.length>0&&y.setAttribute("label",new Fl.Int32BufferAttribute(m,1)),y.computeBoundingSphere();const d=new Fl.PointsMaterial({size:.005});return c.length>0&&(d.vertexColors=!0),new Fl.Points(y,d)}}const n0=M.useModelComp(M.pinia),{systemPath:Cs}=M.storeToRefs(n0),go=e.ref(),Ds=new WeakMap;function i0(a,l,r,n,i){const o=async d=>{try{const D=await M.platformDownloadFile({url:d});if(D.status!==200)throw new Error(`下载失败: ${D.status}`);return D.data}catch(D){throw console.error("addModelFromUrl失败:",D),D}},p=d=>new Promise((D,w)=>{const q=new FileReader;q.onload=A=>{try{const j=A.target.result,E=new Yn.MTLLoader().parse(j);E.preload(),D(E)}catch(j){w(j)}},q.onerror=()=>{w(new Error("MTL文件读取失败"))},q.readAsText(d)}),c=async d=>{const D={materials:{},create:function(w){return this.materials[w]?this.materials[w]:(console.warn(`Material '${w}' not found, using default material`),new Fl.MeshPhongMaterial({color:8947848,side:Fl.DoubleSide}))},getAsArray:function(){const w=[];for(const q in this.materials)w.push(this.materials[q]);return w},preload:function(){for(const w in this.materials)this.materials[w].map&&(this.materials[w].map.needsUpdate=!0)}};for(const w of d){const q=await p(w);Object.assign(D.materials,q.materials)}return D.preload(),D},u=async(d,D=[])=>new Promise((w,q)=>{const A=new FileReader;A.onload=async j=>{try{const O=j.target.result;let E=null;D&&D.length>0&&(D.length===1?E=await p(D[0]):E=await c(D));const _=new Yn.OBJLoader;E&&_.setMaterials(E);const x=_.parse(O);E||x.traverse(b=>{b.isMesh&&(b.material=new Fl.MeshPhongMaterial({color:8947848,side:Fl.DoubleSide}))}),w(x)}catch(O){q(O)}},A.onerror=()=>{q(new Error("OBJ文件读取失败"))},A.readAsText(d)}),m=async d=>{var D;try{r.value=!0;const{scene:w}=a();if(!w)throw new Error("Scene not initialized");i();const q=[];for(let A=0;A<d.length;A++){const j=d[A];n.value=`正在加载模型 ${A+1}/${d.length}...`;const O=await o(j.objUrl),E=((D=j.objUrl)==null?void 0:D.split("/").pop())||`model_${A}.obj`,_=new File([O],E,{type:O.type});let x=[];if(j.mtlUrls){const S=Array.isArray(j.mtlUrls)?j.mtlUrls:[j.mtlUrls];for(let I=0;I<S.length;I++){const R=S[I],re=await o(R),X=(R==null?void 0:R.split("/").pop())||`material_${A}_${I}.mtl`,me=new File([re],X,{type:re.type});x.push(me)}}const b=await u(_,x);w.add(b),l.value.push(b),q.push(b)}return r.value=!1,q}catch(w){throw console.error("加载模型失败:",w),r.value=!1,w}},g=async(d,D,w=[],q=[])=>{let A;const j=d.toLowerCase();switch(j){case".txt":case".cpt":case".obj":const O=await D.text();if(j===".txt"||j===".cpt"){const P=/^(?!.*\bf\b)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?$/gm,Me=[...O.matchAll(P)].map(de=>({x:parseFloat(de[1]),y:parseFloat(de[2]),z:parseFloat(de[3])})),Le=new Fl.BufferGeometry,Ie=Me.flatMap(de=>[de.x,de.y,de.z]);if(Le.setAttribute("position",new Fl.Float32BufferAttribute(Ie,3)),j===".txt"){const de=new Fl.PointsMaterial({color:"#5B5C99",size:1,sizeAttenuation:!1});A=new Fl.Points(Le,de)}else if(j===".cpt"){const de=new Fl.LineBasicMaterial({color:"#5B5C99",linewidth:100});A=new Fl.Line(Le,de)}}else if(j===".obj"){const P=new Yn.OBJLoader;if(w&&w.length>0){const Ke=new Yn.MTLLoader;for(const Me of w){const Le=await Me.text(),Ie=Ke.parse(Le);Ie.preload(),P.setMaterials(Ie);break}}A=P.parse(O),(!w||w.length===0)&&A.traverse(Ke=>{Ke.isMesh&&(Ke.material=new Fl.MeshPhongMaterial({color:"#B3B3D4"})),Ke instanceof Fl.Mesh&&(Ke.material.side=Fl.DoubleSide)})}break;case".stl":const E=await D.arrayBuffer(),x=new Yn.STLLoader().parse(E),b=new Fl.MeshPhongMaterial({color:"#B3B3D4",side:Fl.DoubleSide});A=new Fl.Mesh(x,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"],I={"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)"},R=new Fl.Group,re=S.map(P=>new Promise((Ke,Me)=>{new Yn.STLLoader().load(Cs.value===""?`/model/${P}`:`${Cs.value}\\${P}`,Ie=>{const de=new Fl.MeshPhongMaterial({color:I[P]||"#B3B3D4",side:Fl.DoubleSide}),De=new Fl.Mesh(Ie,de);Ke(De)},void 0,Me)}));try{(await Promise.all(re)).forEach(Ke=>R.add(Ke)),A=R}catch(P){throw console.error("加载NC文件对应的STL文件失败:",P),new Error("无法加载.NC文件对应的STL文件")}break;case".pcd":const X=new r0,me=new Fl.Group;try{const P=await Ja.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/target.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),Ke=new Blob([P.data],{type:"application/octet-stream;charset=UTF-8"}),Me=await Ja.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/final.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),Le=new Blob([Me.data],{type:"application/octet-stream;charset=UTF-8"}),Ie=await new Promise((De,Xe)=>{const Ea=URL.createObjectURL(Ke);X.load(Ea,Ge=>{const $=new Float32Array(Ge.geometry.attributes.position.count*3);for(let V=0;V<Ge.geometry.attributes.position.count;V++)$[V*3]=1,$[V*3+1]=0,$[V*3+2]=0;Ge.geometry.setAttribute("color",new Fl.BufferAttribute($,3)),Ge.material.vertexColors=!0,Ge.scale.set(.3,.3,.3),URL.revokeObjectURL(Ea),De(Ge)},void 0,Xe)}),de=await new Promise((De,Xe)=>{const Ea=URL.createObjectURL(Le);X.load(Ea,Ge=>{const $=new Float32Array(Ge.geometry.attributes.position.count*3);for(let V=0;V<Ge.geometry.attributes.position.count;V++)$[V*3]=0,$[V*3+1]=1,$[V*3+2]=0;Ge.geometry.setAttribute("color",new Fl.BufferAttribute($,3)),Ge.material.vertexColors=!0,Ge.scale.set(.3,.3,.3),URL.revokeObjectURL(Ea),De(Ge)},void 0,Xe)});me.add(Ie),me.add(de),A=me}catch(P){throw console.error("PCD文件加载失败:",P),new Error("无法加载PCD文件")}break;case".urdf":const ue=URL.createObjectURL(D),U=new ld.URDFLoader,W="http://139.196.154.85:20026/chfs/shared/机器人/urdf/SmallBender_R-2000iC-165F/meshes",Z={maxConcurrentLoads:4,enableCache:!0,enableLOD:!0,simplifyGeometry:!0,shareMaterials:!0,enableInstancing:!0},ae=new WeakMap,ve=new WeakMap,ze=new WeakMap,te=async P=>{if(ae.has(P))return console.log(`从缓存加载: ${P}`),ae.get(P);try{const Ke=await Ja.axios.get(`${W}/${P}`,{responseType:"blob",headers:{"Content-Type":"application/json"},timeout:6e5}),Me=new Blob([Ke.data],{type:"application/octet-stream;charset=UTF-8"});return Z.enableCache&&ae.set(P,Me),Me}catch(Ke){throw console.error(`加载文件失败: ${P}`,Ke),new Error(`无法加载文件: ${P}`)}},N=(P="default")=>{if(ve.has(P))return ve.get(P);const Ke=new Fl.MeshPhongMaterial({color:12303291,shininess:30,transparent:!1,alphaTest:.1,side:Fl.FrontSide});return ve.set(P,Ke),Ke},se=P=>{try{P.isBufferGeometry&&P.mergeVertices&&P.mergeVertices(),P.computeVertexNormals&&P.computeVertexNormals(),P.computeBoundingSphere&&P.computeBoundingSphere(),P.deleteAttribute&&P.deleteAttribute("uv2")}catch(Ke){console.warn("几何体优化失败,使用原始几何体:",Ke)}return P},G=async(P,Ke,Me)=>{const Le=`stl_${Ke}`;if(ze.has(Le)){const Xe=ze.get(Le);return new Fl.Mesh(Xe,N())}const Ie=await P.arrayBuffer();let De=new Yn.STLLoader(Me).parse(Ie);return De=se(De),ze.set(Le,De),new Fl.Mesh(De,N())},fe=async(P,Ke,Me)=>{const Le=`obj_${Ke}`;if(ae.has(Le))return ae.get(Le).clone();const Ie=await P.text(),de=new Yn.OBJLoader(Me),De=Ke.replace(".obj",".mtl");try{const Ge=await(await te(De)).text(),V=new Yn.MTLLoader(Me).parse(Ge);V.preload(),de.setMaterials(V)}catch{console.warn(`MTL文件加载失败,使用默认材质: ${De}`)}const Xe=de.parse(Ie);return Xe.traverse(Ea=>{Ea.isMesh&&(Ea.geometry=se(Ea.geometry),Ea.castShadow=!0,Ea.receiveShadow=!0,Ea.renderOrder=1)}),ae.set(Le,Xe),Xe},we=(P,Ke)=>{const Me=new Fl.LOD;if(Me.addLevel(P,0),P.geometry){const Le=P.geometry.clone(),Ie=new Fl.Mesh(Le,P.material);Me.addLevel(Ie,50)}return Me};let _e=0,qe=0;const ra=[];U.loadMeshCb=async(P,Ke,Me,Le,Ie)=>{const de=P.split("/").pop(),De=Me||(()=>{});_e++;const Xe=new Promise(async(Ea,Ge)=>{try{const $=await te(de);if(!$||$.size===0)throw new Error(`文件为空: ${de}`);const V=de.split(".").pop().toLowerCase();let ee;switch(V){case"stl":ee=await G($,de,Ke);break;case"obj":ee=await fe($,de,Ke);break;default:throw new Error(`不支持的文件格式: ${V}`)}Z.enableLOD&&ee.isMesh&&(ee=we(ee,de)),De(ee),qe++,Le&&Le({loaded:qe,total:_e,progress:qe/_e}),Ea(ee)}catch($){console.error(`mesh文件加载失败: ${de}`,$);const V=new Fl.Group;De(V),Ea(V);const ee=new Fl.BoxGeometry(.1,.1,.1),ce=new Fl.MeshStandardMaterial({color:16711680,wireframe:!0});return new Fl.Mesh(ee,ce)}});ra.push(Xe)};try{if(!ue){go.value=void 0;break}if(A=await U.loadAsync(ue),console.log(`URDF文件加载完成,等待${_e}个mesh文件加载...`),ra.length>0)try{await Promise.allSettled(ra),console.log(`所有mesh文件处理完成,成功加载: ${qe}/${_e}`)}catch(Me){console.warn("部分mesh文件加载失败,但继续显示模型",Me)}A.traverse(Me=>{Me.isMesh&&(Me.castShadow=!0,Me.receiveShadow=!0,Me.renderOrder=1,Me.material&&(Me.material.needsUpdate=!0))}),console.time("计算包围盒");const P=new Fl.Box3;P.expandByObject(A);const Ke=`urdf_${Date.now()}`;A.userData.boundingBox=P.clone(),A.userData.modelId=Ke,Ds.set(Ke,{box:P.clone(),center:P.getCenter(new Fl.Vector3),size:P.getSize(new Fl.Vector3),maxSize:Math.max(...P.getSize(new Fl.Vector3).toArray())}),go.value=A,console.log("URDF模型加载完成并优化")}catch(P){console.error("URDF加载失败:",P),go.value=void 0}finally{ue&&URL.revokeObjectURL(ue)}break;default:throw new Error(`不支持的文件格式: ${d}`)}return A};return{addModelsFromUrls:m,loadModelByDefaultPath:async d=>{console.log(d);try{r.value=!0,n.value="正在加载模型...";const{scene:D}=a();if(!D)throw new Error("Scene not initialized");i(),await new Promise(q=>setTimeout(q,100));const w=[];for(let q=0;q<d.length;q++){const A=d[q],j=await g(A.suffix,A.blob,A.mtlBlobs||[],A.meshFiles||[]);j&&(D.add(j),l.value.push(j),w.push(j))}return r.value=!1,n.value="",w}catch(D){throw console.error("加载模型失败:",D),r.value=!1,n.value="",D}},urdfModel:go,modelBoundingBoxes:Ds}}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=(r=(r=document.getElementsByTagName("script"))[r.length-1]).getAttribute("data-injectcss"),r=r.getAttribute("data-disable-injectsvg");if(!r){var n,i,o,p,c,u=function(y,d){d.parentNode.insertBefore(y,d)};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(y){console&&console.log(y)}}n=function(){var y,d=document.createElement("div");d.innerHTML=a._iconfont_svg_string_4827314,(d=d.getElementsByTagName("svg")[0])&&(d.setAttribute("aria-hidden","true"),d.style.position="absolute",d.style.width=0,d.style.height=0,d.style.overflow="hidden",d=d,(y=document.body).firstChild?u(d,y.firstChild):y.appendChild(d))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(n,0):(i=function(){document.removeEventListener("DOMContentLoaded",i,!1),n()},document.addEventListener("DOMContentLoaded",i,!1)):document.attachEvent&&(o=n,p=a.document,c=!1,g(),p.onreadystatechange=function(){p.readyState=="complete"&&(p.onreadystatechange=null,m())})}function m(){c||(c=!0,o())}function g(){try{p.documentElement.doScroll("left")}catch{return void setTimeout(g,50)}m()}})(window);const o0=["onClick"],t0=["src"],s0=["src"],c0=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:""},backgroundPosition:{default:"Center"},iconUrl:{default:void 0},calculator:{default:()=>[]},textBackColor:{default:void 0}},emits:["update:backGroundImage"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(null),o=e.ref(null),p=x=>{var S,I,R,re;let b={};if(x!=null&&x.find(X=>X==null?void 0:X.includes("@TextSize"))){let X=(I=(S=x==null?void 0:x.find(me=>me==null?void 0:me.includes("@TextSize")))==null?void 0:S.split("="))==null?void 0:I[1];b.fontSize=`${X}px`}if(x!=null&&x.find(X=>X==null?void 0:X.includes("@TextRGBA"))){let X=(re=(R=x==null?void 0:x.find(me=>me==null?void 0:me.includes("@TextRGBA")))==null?void 0:R.split("="))==null?void 0:re[1];b.color=le.rgbaToColor(X)}return b},c=e.computed(()=>{const x=Number(r==null?void 0:r.textSize),b=le.rgbaToColor(r==null?void 0:r.textColor),S={},I={};return!Number.isNaN(x)&&x&&(S.fontSize=`${x}px`,I.fontSize=`${x}px`),b&&(S.color=b,I.color=b),{label:S,value:I}}),u=e.ref(""),m=e.ref(""),g=e.ref(!1),y=async x=>{if(x){m.value&&(URL.revokeObjectURL(m.value),m.value="");try{const b=await M.platformDownloadFile({url:x}),S=new Blob([b==null?void 0:b.data],{type:(b==null?void 0:b.headers["content-type"])||"image/*"});m.value=URL.createObjectURL(S)}catch{m.value=""}}};e.watch(()=>r==null?void 0:r.backGroundImage,x=>{x&&(u.value=x)},{immediate:!0}),e.watch(u,x=>{y(x)},{immediate:!0});const d=async()=>{var x,b;((x=r==null?void 0:r.calculator)==null?void 0:x.length)>0&&await $t(r==null?void 0:r.items,"Auto",[],r==null?void 0:r.calculator),(b=o.value)==null||b.click()},D=async x=>{var I,R,re;const b=x.target,S=(I=b==null?void 0:b.files)==null?void 0:I[0];if(!S){b.value="";return}g.value=!0;try{const X=new FormData;X.append("file",S);const me=await M.platformUploadFile(X),ue=(re=(R=me==null?void 0:me.data)==null?void 0:R.result)==null?void 0:re.url;ue?(u.value=ue,n("update:backGroundImage",ue),y(ue),Ja.ElMessage.success("背景图片上传成功")):Ja.ElMessage.error("背景图片上传失败")}catch{Ja.ElMessage.error("背景图片上传失败")}finally{g.value=!1,b.value=""}},w=e.computed(()=>{var x,b,S,I;return m.value||(r==null?void 0:r.backgroundUrl)!==""?{backgroundImage:`url("${(x=r==null?void 0:r.backgroundUrl)==null?void 0:x.replace(/\\/g,"/")}")`,backgroundPosition:`${((b=r==null?void 0:r.backgroundPosition)==null?void 0:b.toLowerCase())??"center"} center`,backgroundRepeat:"no-repeat",cursor:((S=r==null?void 0:r.calculator)==null?void 0:S.length)>0?"pointer":"auto"}:{cursor:((I=r==null?void 0:r.calculator)==null?void 0:I.length)>0?"pointer":"auto",background:r!=null&&r.textBackColor?le.rgbaToColor(r==null?void 0:r.textBackColor):void 0}}),q=x=>pl.getComponent(x),A=x=>{if(!x)return;const b=x.querySelector("input, textarea, .el-input__inner");b&&typeof b.focus=="function"&&b.focus()},j=(x,b,S)=>{r.disabled||x.field&&(i.value=b,e.nextTick(()=>{A(S.currentTarget)}))},O=()=>{i.value=null},E=x=>{var S;const b=((S=x==null?void 0:x.field)==null?void 0:S.value)??(x==null?void 0:x.value);return b==null||b===""?"-":b},_=x=>{var re,X,me,ue;const b=x!=null&&x.width&&x.width>0?x.width:1,I=`calc((100% - ${(b-1)*16}px) / ${b})`;let R;return(re=x==null?void 0:x.filters)!=null&&re.find(U=>U==null?void 0:U.includes("@TextBackRGBA"))&&(R=(ue=(me=(X=x==null?void 0:x.filters)==null?void 0:X.find(U=>U==null?void 0:U.includes("@TextBackRGBA")))==null?void 0:me.split("="))==null?void 0:ue[1],R=le.rgbaToColor(R)),{flex:`0 0 ${I}`,maxWidth:I,minWidth:"140px",boxSizing:"border-box",background:R}};return(x,b)=>(e.openBlock(),e.createElementBlock("div",{class:"statistics-cards-container",style:e.normalizeStyle(w.value),onClick:b[1]||(b[1]=S=>d())},[r!=null&&r.backGround?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-backGround-upload",onClick:b[0]||(b[0]=e.withModifiers(S=>d(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:o,type:"file",accept:"image/*",style:{display:"none"},onChange:D},null,544),b[2]||(b[2]=e.createElementVNode("img",{src:pl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.items,(S,I)=>{var R,re,X,me,ue,U,W,Z;return e.openBlock(),e.createElementBlock("div",{class:"statistics-card",key:I,style:e.normalizeStyle(_(S))},[e.createElementVNode("div",{class:"statistics-label",style:e.normalizeStyle({...c.value.label,...p(S==null?void 0:S.filters)})},e.toDisplayString(S==null?void 0:S.label),5),e.createElementVNode("div",{class:"statistics-value",style:e.normalizeStyle(c.value.value),onClick:ae=>{var ve;return(ve=S.field)!=null&&ve.isNoClick?null:j(S,I,ae)}},[x.iconUrl&&x.backgroundPosition==="Left"?(e.openBlock(),e.createElementBlock("img",{key:0,src:x.iconUrl,class:"bg-upload-icon"},null,8,t0)):e.createCommentVNode("",!0),i.value===I&&S.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(q(((R=S.field)==null?void 0:R.type)??"Input")),{key:1,modelValue:S.field.value,"onUpdate:modelValue":ae=>S.field.value=ae,isEdit:!0,disabled:(re=S.field)==null?void 0:re.disabled,content:((X=S.field)==null?void 0:X.contents)??[],optionUrl:S.field,originalValue:(me=S.field)==null?void 0:me.value,config:(ue=S.field)==null?void 0:ue.config,configModel:((U=S.field)==null?void 0:U.prop)??((W=S.field)==null?void 0:W.name),selectedTagList:((Z=S.field)==null?void 0:Z.selectValue)??[],onBlur:O,onBlurChange:O},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(E(S)),1)],64)),x.iconUrl&&x.backgroundPosition==="Right"?(e.openBlock(),e.createElementBlock("img",{key:3,src:x.iconUrl,class:"bg-upload-icon"},null,8,s0)):e.createCommentVNode("",!0)],12,o0)],4)}),128))],4))}}),u0=pr._export_sfc(c0,[["__scopeId","data-v-3e28c1c9"]]),Ec=M.defineStore("formToTableComp",{state:()=>({selectArray:[],selectString:""}),actions:{setSelectArray(a){this.selectArray=a},setSelectString(a){this.selectString=a}}}),d0={class:"calculator-content"},p0={class:"calculator-child"},f0={class:"calculator-child"},h0=e.defineComponent({__name:"calculator",setup(a){const l=e.ref(),r=e.ref();return e.onMounted(()=>{l.value=[{type:"Upload",label:"输入",name:"input"}],r.value=[{type:"Upload",label:"输出",name:"output"}]}),(n,i)=>(e.openBlock(),e.createElementBlock("div",d0,[e.createElementVNode("div",p0,[e.createVNode(pl.ssForm,{rowContents:l.value,isRowFlex:!0},null,8,["rowContents"])]),e.createElementVNode("div",f0,[e.createVNode(pl.ssForm,{rowContents:r.value,isEdit:!1,isRowFlex:!0},null,8,["rowContents"])])]))}}),v0=pr._export_sfc(h0,[["__scopeId","data-v-73db0fe7"]]),Bt=(a,l)=>{let r=a,n=l;return Array.isArray(r)&&(r=r==null?void 0:r.map((i,o)=>{if(Array.isArray(i)){let p={};return i=i==null?void 0:i.forEach((c,u)=>{var m;(m=n==null?void 0:n[u])!=null&&m.prop?p[n[u].prop]=c:Array.isArray(c)&&(p.children=Bt(c,n))}),Object.assign(p,{id:o})}else return i})),r},Cc=(a,l,r)=>{let n=a,i=l;return n=n==null?void 0:n.map((o,p)=>{var c,u;return!Array.isArray(o)||!((c=i==null?void 0:i[p])!=null&&c.label)&&!r||(o.unshift(((u=i==null?void 0:i[p])==null?void 0:u.label)??""),o.some(m=>Array.isArray(m))&&(o=o==null?void 0:o.map(m=>{var g;return Array.isArray(m)&&(m=Cc(m,(g=i==null?void 0:i[p])==null?void 0:g.children,r)),m}))),o}),n},m0=(a,l,r)=>{if(l==="")return a==null?void 0:a.filter(n=>(n==null?void 0:n.id)!==r);{const n=l.split("-");return y0(a,n,r)}},y0=(a,l,r)=>{let n=a,i=l;return(i==null?void 0:i.length)===0?n=n==null?void 0:n.filter(o=>o.id!==r):n=n==null?void 0:n.map(o=>(o.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),o=Dc(o,i,r)),o)),n},Dc=(a,l,r)=>{var o,p;let n=a,i=l;return(i==null?void 0:i.length)===0?n.children=(o=n.children)==null?void 0:o.filter(c=>c.id!==r):n.children=(p=n.children)==null?void 0:p.map(c=>(c.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),c=Dc(c,i,r)),c)),n},g0=(a,l,r)=>{if(l==="")return r;{const n=l.split("-");return b0(a,n,r)}},b0=(a,l,r)=>{let n=a,i=l;return(i==null?void 0:i.length)===0?n=r:n=n==null?void 0:n.map(o=>(o.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),o=Tc(o,i,r)),o)),n},Tc=(a,l,r)=>{var o;let n=a,i=l;return(i==null?void 0:i.length)===0?n.children=r:n.children=(o=n.children)==null?void 0:o.map(p=>(p.id.toString()===(i==null?void 0:i[0])&&(i==null||i.shift(),p=Tc(p,i,r)),p)),n};class k0{constructor(l={}){fn(this,"url");fn(this,"heartbeatInterval");fn(this,"socket",null);fn(this,"isConnected",!1);fn(this,"heartTimer",null);fn(this,"canvas",null);fn(this,"ctx",null);fn(this,"mainCamCutMode",0);fn(this,"pMainShowStartX",0);fn(this,"pMainShowStartY",0);fn(this,"onLog");fn(this,"onDevCount");fn(this,"onResolution");fn(this,"onCameraStatus");fn(this,"onPhoto");this.url=l.url??"ws://127.0.0.1:22225",this.heartbeatInterval=l.heartbeatInterval??3e3}init(l,r,n){var p;(p=this.canvas)!=null&&p.parentNode&&this.canvas.parentNode.removeChild(this.canvas);const i=document.createElement("canvas");i.style.border="solid 1px #A0A0A0",i.id="MainCamCanvas",i.width=r,i.height=n;const o=i.getContext("2d");if(!o)throw new Error("无法获取 CanvasRenderingContext2D");l.appendChild(i),this.canvas=i,this.ctx=o}async connect(){this.socket&&(this.socket.readyState===WebSocket.OPEN||this.socket.readyState===WebSocket.CONNECTING)||await new Promise((l,r)=>{const n=new WebSocket(this.url);n.binaryType="arraybuffer",n.onopen=()=>{this.socket=n,this.isConnected=!0,this.startHeartbeat(),this.log("socket.onopen"),l()},n.onerror=i=>{this.isConnected=!1,this.log("socket.onerror"),r(i)},n.onclose=()=>{this.isConnected=!1,this.stopHeartbeat(),this.log("socket.onclose")},n.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 r=l.find(i=>i.width===2592&&i.height===1944);return r||[...l].sort((i,o)=>o.width*o.height-i.width*i.height)[0]||null}openCamera(l=0,r=1280,n=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]=r>>8&255,i[9]=r&255,i[10]=n>>8&255,i[11]=n&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 r;(r=this.onLog)==null||r.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,o,p,c,u,m;const r=new Uint8Array(l.data);if(r.length<=0)return;if(r[0]===17&&r[1]===17&&r[2]===17){this.log("heart socket!!!!");return}if(r[0]!==85||r[1]!==102)return;const n=r[2];if(n===80){const g=r[3],y=r.length-4,d=new Uint8Array(y);for(let q=0;q<y;q++)d[q]=r[4+q];const w=decodeURIComponent(this.byteToString(d)).split("|");(i=this.onDevCount)==null||i.call(this,g,w);return}if(n===81){const g=r[3]||0,y=[];for(let d=0;d<g;d++){const D=(r[4+d*4+0]||0)*256+(r[4+d*4+1]||0),w=(r[4+d*4+2]||0)*256+(r[4+d*4+3]||0);y.push({width:D,height:w,text:`${D}*${w}`})}(o=this.onResolution)==null||o.call(this,g,y);return}if(n===1){r[3]===1&&((p=this.onCameraStatus)==null||p.call(this,"opened")),r[3]===3&&((c=this.onCameraStatus)==null||c.call(this,"closed"));return}if(n===16){if(r[3]===1){const y=r[4]*256+r[5],d=r[6]*65536+r[7]*256+r[8];let D="";if(y>0){const A=new Uint8Array(y);for(let j=0;j<y;j++)A[j]=r[9+j];D=decodeURIComponent(this.byteToString(A))}const w=new Uint8Array(d);for(let A=0;A<d;A++)w[A]=r[9+y+A];const q=this.uint8ArrayToString(w);(u=this.onPhoto)==null||u.call(this,{flag:0,imgPath:D,base64:q})}r[3]===2&&((m=this.onPhoto)==null||m.call(this,{flag:2,imgPath:"",base64:""}));return}if(n===204){if(!this.canvas||!this.ctx)return;const g=r[3]*256+r[4],y=r[5]*256+r[6];this.pMainShowStartX=r[7]*256+r[8],this.pMainShowStartY=r[9]*256+r[10],this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height);const d=this.ctx.createImageData(g,y);let D=11;for(let w=0;w<d.data.length;w+=4)d.data[w+0]=r[D],d.data[w+1]=r[D+1],d.data[w+2]=r[D+2],d.data[w+3]=255,D+=3;this.ctx.putImageData(d,this.pMainShowStartX,this.pMainShowStartY),this.mainCamCutMode;return}}uint8ArrayToString(l){let r="";for(let n=0;n<l.length;n++)r+=String.fromCharCode(l[n]);return r}byteToString(l){let r="";for(let n=0;n<l.length;n++)r+=String.fromCharCode(l[n]);return r}}const x0={style:{display:"flex",gap:"16px",height:"100%"}},w0={key:0,style:{color:"var(--el-text-color-secondary)"}},_0={style:{width:"420px",display:"flex","flex-direction":"column",gap:"16px"}},S0={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px"}},E0={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"}},C0={key:0,style:{height:"100%",display:"flex","align-items":"center","justify-content":"center",color:"var(--el-text-color-secondary)"}},D0={key:1,style:{display:"grid","grid-template-columns":"repeat(2, minmax(0, 1fr))",gap:"8px"}},T0=["src","onClick"],B0=["onClick"],N0={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px",flex:"1","min-height":"0",display:"flex","flex-direction":"column"}},A0={class:"dialog-footer"},z0=e.defineComponent({__name:"index",props:{visible:{type:Boolean,default:!1}},emits:["confirm","cancel"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(null),o=e.ref(!1),p=e.ref([]),c=e.ref(""),u=e.ref(!1),m=e.ref([]),g=new k0({url:"ws://127.0.0.1:22225"});function y(R,re){var Z;const X=R.split(","),me=((Z=X[0].match(/:(.*?);/))==null?void 0:Z[1])??"image/jpeg",ue=atob(X[1]);let U=ue.length;const W=new Uint8Array(U);for(;U--;)W[U]=ue.charCodeAt(U);return new File([W],re,{type:me})}function d(){g.onLog=R=>{console.log("[GPY]",R)},g.onDevCount=(R,re)=>{if(c.value+=`设备数量=${R},设备=${re.join(",")}
|
|
4
4
|
`,R>0){c.value+=`检测到设备,正在获取分辨率...
|
|
5
5
|
`;try{g.getResolution(0)}catch(X){c.value+=`获取分辨率失败:${(X==null?void 0:X.message)??X}
|
|
6
6
|
`}}else c.value+=`未检测到高拍仪设备!
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
`,g.getDevCount()},w=()=>{try{g.destroy()}catch(R){console.error(R)}o.value=!1,p.value=[],c.value="",u.value=!1,m.value=[]};e.watch(()=>r.visible,R=>{R?D():w()});const q=()=>{try{g.bestSize()}catch(R){console.error(R)}},A=()=>{try{g.rotateLeft()}catch(R){console.error(R)}},j=()=>{try{g.rotateRight()}catch(R){console.error(R)}},O=()=>{try{g.focus()}catch(R){console.error(R)}},E=()=>{c.value+=`正在拍照...
|
|
21
21
|
`;try{g.photo()}catch(R){c.value+=`拍照调用失败:${(R==null?void 0:R.message)??R}
|
|
22
22
|
`}},_=()=>{p.value.length>0?n("confirm",p.value.map(R=>R.file)):n("confirm",[])},x=R=>{R<0||R>=p.value.length||(p.value.splice(R,1),c.value+=`已删除一张图片(剩余 ${p.value.length} 张)
|
|
23
|
-
`)},b=R=>{if(!R)return;const re=`gpy-preview-${Date.now()}.jpg`;m.value=[{name:re,blobUrl:R}],u.value=!0},S=()=>{u.value=!1},I=()=>{w(),n("cancel")};return(R,re)=>{const X=e.resolveComponent("el-input"),me=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode($r.ssDialog,{title:"扫描录入",visible:r.visible,onBeforeDestroy:I,width:"1200px",style:{height:"80%"}},{default:e.withCtx(()=>[e.createElementVNode("div",x0,[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)"}},[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",w0,"初始化摄像头..."))],512),e.createElementVNode("div",_0,[e.createElementVNode("div",S0,[re[0]||(re[0]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"拍照图片",-1)),e.createElementVNode("div",E0,[p.value.length===0?(e.openBlock(),e.createElementBlock("div",C0,"暂无图片")):(e.openBlock(),e.createElementBlock("div",D0,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(ue,U)=>(e.openBlock(),e.createElementBlock("div",{key:ue.uid,style:{position:"relative",border:"1px solid var(--el-border-color)","border-radius":"4px",overflow:"hidden",background:"#fafafa"}},[e.createElementVNode("img",{src:ue.url,onClick:W=>b(ue.url),style:{width:"100%",height:"94px","object-fit":"contain",display:"block",background:"#fafafa",cursor:"zoom-in"},alt:"captured image",title:"点击放大"},null,8,T0),e.createElementVNode("div",{onClick:W=>x(U),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,B0)]))),128))]))],512)]),e.createElementVNode("div",N0,[re[1]||(re[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",A0,[e.createVNode(me,{onClick:q,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[2]||(re[2]=[e.createTextVNode("适屏")])),_:1,__:[2]},8,["disabled"]),e.createVNode(me,{onClick:A,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[3]||(re[3]=[e.createTextVNode("左旋")])),_:1,__:[3]},8,["disabled"]),e.createVNode(me,{onClick:j,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[4]||(re[4]=[e.createTextVNode("右旋")])),_:1,__:[4]},8,["disabled"]),e.createVNode(me,{onClick:O,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[5]||(re[5]=[e.createTextVNode("对焦")])),_:1,__:[5]},8,["disabled"]),e.createVNode(me,{onClick:E,disabled:!o.value,id:"themeButton"},{default:e.withCtx(()=>re[6]||(re[6]=[e.createTextVNode("拍照")])),_:1,__:[6]},8,["disabled"]),re[9]||(re[9]=e.createElementVNode("div",{style:{flex:"1"}},null,-1)),e.createVNode(me,{onClick:_,disabled:p.value.length===0,id:"themeButton"},{default:e.withCtx(()=>re[7]||(re[7]=[e.createTextVNode("确认")])),_:1,__:[7]},8,["disabled"]),e.createVNode(me,{onClick:I,id:"themeBorderButton"},{default:e.withCtx(()=>re[8]||(re[8]=[e.createTextVNode("取消")])),_:1,__:[8]})])]),_:1},8,["visible"]),u.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:0,fileDataList:m.value,onDestroy:S},null,8,["fileDataList"])):e.createCommentVNode("",!0)],64)}}}),M0=pr._export_sfc(z0,[["__scopeId","data-v-24a2050a"]]),Ts=M.useMenuState(M.pinia);let Ai="$R";const I0=async a=>{var o,p,c,u,m,g;let l=a==null?void 0:a.导入文件,r=a==null?void 0:a.函数参数,n=(o=l==null?void 0:l[0])==null?void 0:o.url,i="";if(!(n!=null&&n.includes("http"))||!(n!=null&&n.includes("https"))){Ts.setContentLoading(!0);const y=await M.platformDownloadFile({url:n});let d=y==null?void 0:y.data;const D=new FormData;D.append("file",d,((p=l==null?void 0:l[0])==null?void 0:p.name)+"."+((c=n==null?void 0:n.split("."))==null?void 0:c[1])),D.append("query",r);let w=await hc(D);w=(g=(m=(u=w==null?void 0:w.data)==null?void 0:u.data)==null?void 0:m.response)==null?void 0:g.replace("generateResult",a==null?void 0:a.函数名称),i=w,Ts.setContentLoading(!1)}return i},O0=a=>{var r,n;if(a==="")return;let l=a;return l=(n=(r=l==null?void 0:l.replace("(",Ai))==null?void 0:r.split(Ai))==null?void 0:n[1],l=l==null?void 0:l.slice(0,(l==null?void 0:l.length)-1),l=le.analyzeSplitToContent(l,","),l=l==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)),l=l==null?void 0:l.filter(i=>(i==null?void 0:i.includes("If"))&&!(i!=null&&i.includes("@If"))),l=l==null?void 0:l.map(i=>{var c,u,m,g,y;let o=i;o=(u=(c=o==null?void 0:o.replace("=",Ai))==null?void 0:c.split(Ai))==null?void 0:u[1],o=(m=le.analyzeSplitToContent(o,")"))==null?void 0:m[0];let p=i==null?void 0:i.replaceAll(o,"");return(o==null?void 0:o[0])==="("&&(o=o==null?void 0:o.slice(1,(o==null?void 0:o.length)-1)),o=(y=(g=o==null?void 0:o.replace("(",Ai))==null?void 0:g.split(Ai))==null?void 0:y[1],o="("+o,o=le.calculatorAndToOr(o),{key:p,content:o}}),l},Bs=(a,l)=>{let r=[l];return a==null||a.forEach(n=>{for(let i in n)n[i]!=="!"?r=r==null?void 0:r.filter(o=>{var p;return(o==null?void 0:o[i])===(n==null?void 0:n[i])||(o==null?void 0:o[(p=Object.keys(o))==null?void 0:p.find(c=>c==null?void 0:c.includes("."+i))])===(n==null?void 0:n[i])}):r=r==null?void 0:r.filter(o=>{var p;return(o==null?void 0:o[i])!==(n==null?void 0:n[i])&&(o==null?void 0:o[(p=Object.keys(o))==null?void 0:p.find(c=>c==null?void 0:c.includes("."+i))])!==(n==null?void 0:n[i])})}),r},Ft=M.defineStore("formComp",{state:()=>({objUrl:[],blobUrls:[]}),actions:{setObjUrl(a){this.objUrl=a},setBlobUrls(a){this.blobUrls=a}}}),L0=M.useModelComp(M.pinia),{extraContents:Z1}=M.storeToRefs(L0),R0=M.useLoginState(M.pinia),{extraUrl:mi}=M.storeToRefs(R0);let Bc=mi.value===""||!mi.value?"http://139.196.154.85:20015":mi.value;e.watch(()=>mi.value,()=>{Bc=mi.value===""||!mi.value?"http://139.196.154.85:20015":mi.value},{deep:!0,immediate:!0});const Ao={检校类型:["检校类型","证书类别"],证书编号:["证书编号"],设备名称:["设备名称","器具名称","样品名称","仪器名称","被校设备"],型号规格:["型号规格","型号/规格","型号"],出厂编号:["出厂编号","器具/管理编号","器具编号","管理编号","仪器编号"],制造厂:["制造厂","制造单位","制造厂商","制造商"],检校结果:["检校结果","检定结论","校准结果","校准/检定结果","检定结果"],依据文件:["依据文件","检定依据","检定所依据的技术文件","所依据/参照技术文件(代号/名称)","检定所依据的技术文件(编号/名称)","检定方法说明"],检校日期:["检校日期","校准日期","校验日期","检定日期","发证日期","发布日期","接收日期","签证日期"],有效日期:["有效日期","有效期","有效期至"]},Ns={columnName:"OCR图片",acceptTypes:"image/*",maxSize:10,maxFiles:20,apiUrl:Bc+"/api/public/paddleOCR"};class $0{constructor(l){fn(this,"config");this.config={...Ns,...l}}updateConfig(l){this.config={...this.config,...l}}getConfig(){return{...this.config}}validateFileSize(l){const r=this.config.maxSize*1024*1024;return l.size<=r}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,r){return{title:r,form:{OCR图片文件:l}}}async recognize(l,r){const n=this.getAuthorizationToken(),i=this.buildOCRRequest(l,r),o=this.config.apiUrl||Ns.apiUrl||"";return(await Ja.axios.post(o,i,{headers:{"Content-Type":"application/json",Authorization:n}})).data}getFieldAliases(l){return Ao[l]?Ao[l]:[l]}extractTableHeaders(l){const r=[],n=new Set,i=p=>{const c=p==null?void 0:p.label;return!(!c||c==="操作"||c===this.config.columnName||(p==null?void 0:p.type)==="operate"||(p==null?void 0:p.prop)==="operate")},o=p=>{(p||[]).forEach(c=>{if(!c)return;const u=(c==null?void 0:c.children)||(c==null?void 0:c.child)||(c==null?void 0:c.columns);if(Array.isArray(u)&&u.length>0){o(u);return}if(i(c)){const m=c.label;if(!n.has(m)){n.add(m);const g=this.getFieldAliases(m);r.push(g)}}})};return o(l||[]),r}}function Nc(a){return new $0(a)}Nc();const At=async(a,l)=>{var p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b;let r=(c=(p=M.cloneDeep(a))==null?void 0:p.optionUrl)==null?void 0:c.menuSelect,n=[];r==null||r.forEach(S=>{});let i="",o=await le.menuToParent(r);if(o==null||o.forEach(S=>{var I,R,re,X;(S==null?void 0:S.name)===(((X=(re=(R=(I=M.cloneDeep(a))==null?void 0:I.optionUrl)==null?void 0:R.groupSelect)==null?void 0:re[0])==null?void 0:X.replaceAll("'",""))??"")&&(i=S==null?void 0:S.id)}),l){i=l;const S=await Kr.getInsofDataApi({id:i}),I=(y=(g=(m=(u=S==null?void 0:S.data)==null?void 0:u.result)==null?void 0:m[0])==null?void 0:g.key)==null?void 0:y.pageKey;o=await le.getItemData(I,sessionStorage.getItem("systemKey"),"")}if(i!==""){let S;l?S=(d=o==null?void 0:o.find(re=>(re==null?void 0:re.id)===l))==null?void 0:d.compData:S=(D=o==null?void 0:o.find(re=>{var X,me,ue,U;return(re==null?void 0:re.name)===(((me=(X=a==null?void 0:a.groupSelect)==null?void 0:X.split(":"))==null?void 0:me[0])||((U=(ue=a==null?void 0:a.optionUrl)==null?void 0:ue.groupSelect)==null?void 0:U[0]))}))==null?void 0:D.compData;let I=(q=(w=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:w.contents)==null?void 0:q.map(re=>re==null?void 0:re.label);(j=(A=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:A.contents)!=null&&j.every(re=>Array.isArray(re))&&(I=(_=le.getColumnChild((E=(O=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:O.contents)==null?void 0:E[0]))==null?void 0:_.map(re=>re==null?void 0:re.prop));let R=(b=(x=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="tableContents"))==null?void 0:x.contents)==null?void 0:b.map(re=>{if(Array.isArray(re))re=re==null?void 0:re.filter(X=>!(X!=null&&X.id));else{let X={};for(let me in re)me!=="id"&&(X[me]=re==null?void 0:re[me]);re=X}return re});R==null||R.forEach(re=>{Array.isArray(re)?n.push(le.getValueToObjectValue(re,I)):n.push(re)})}return n},V0=M.useMenuState(M.pinia),{activeMenuPath:Q1}=M.storeToRefs(V0),F0=M.useUnit(M.pinia),{chooseTitle:e8}=M.storeToRefs(F0),P0="col-operate",Ac=a=>`${P0}-${a}`,j0=(a,l)=>{const r=new Map;a.forEach(i=>{const{prop:o}=i;r.set(o,i)});const n=i=>{Array.isArray(i)&&i.forEach(o=>{const{prop:p}=o||{},c=r.get(p);H0(c,o),Array.isArray(o==null?void 0:o.children)&&o.children.length>0&&n(o.children)})};return n(l),l},H0=(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:r=!1,filterable:n=!1,showSummary:i=!1,operable:o=!1,fixed:p=!1}=l||{};return{prop:a,sortable:r,filterable:n,showSummary:i,operable:o,fixed:p}},q0=async a=>{var o,p;if(!a)return;const l=Ac(a),r=await Kr.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:l}}),n=(o=r==null?void 0:r.data)==null?void 0:o.code,i=(p=r==null?void 0:r.data)==null?void 0:p.result;if(n==200)return i==null?void 0:i[0]},W0=async a=>{if(a)return[]},G0=async(a,l)=>{if(!a||!l)return;const r=Ac(a);return await Kr.createInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:r},value:{columns:l}})},K0=async(a,l)=>!a||!l?void 0:await Kr.updateInsofDataApi({id:a,value:{columns:l}}),As=async(a,l)=>{const r=sessionStorage.getItem("systemKey");if(!a||!l||!r)return;const n=await q0(a);return n?await K0(n==null?void 0:n.id,l):await G0(a,l)};var So={exports:{}},Y0=So.exports,zs;function J0(){return zs||(zs=1,function(a,l){(function(r,n){n()})(Y0,function(){function r(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 n(m,g,y){var d=new XMLHttpRequest;d.open("GET",m),d.responseType="blob",d.onload=function(){u(d.response,g,y)},d.onerror=function(){console.error("could not download file")},d.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 o(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 p=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof M.commonjsGlobal=="object"&&M.commonjsGlobal.global===M.commonjsGlobal?M.commonjsGlobal:void 0,c=p.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),u=p.saveAs||(typeof window!="object"||window!==p?function(){}:"download"in HTMLAnchorElement.prototype&&!c?function(m,g,y){var d=p.URL||p.webkitURL,D=document.createElement("a");g=g||m.name||"download",D.download=g,D.rel="noopener",typeof m=="string"?(D.href=m,D.origin===location.origin?o(D):i(D.href)?n(m,g,y):o(D,D.target="_blank")):(D.href=d.createObjectURL(m),setTimeout(function(){d.revokeObjectURL(D.href)},4e4),setTimeout(function(){o(D)},0))}:"msSaveOrOpenBlob"in navigator?function(m,g,y){if(g=g||m.name||"download",typeof m!="string")navigator.msSaveOrOpenBlob(r(m,y),g);else if(i(m))n(m,g,y);else{var d=document.createElement("a");d.href=m,d.target="_blank",setTimeout(function(){o(d)})}}:function(m,g,y,d){if(d=d||open("","_blank"),d&&(d.document.title=d.document.body.innerText="downloading..."),typeof m=="string")return n(m,g,y);var D=m.type==="application/octet-stream",w=/constructor/i.test(p.HTMLElement)||p.safari,q=/CriOS\/[\d]+/.test(navigator.userAgent);if((q||D&&w||c)&&typeof FileReader<"u"){var A=new FileReader;A.onloadend=function(){var E=A.result;E=q?E:E.replace(/^data:[^;]*;/,"data:attachment/file;"),d?d.location.href=E:location=E,d=null},A.readAsDataURL(m)}else{var j=p.URL||p.webkitURL,O=j.createObjectURL(m);d?d.location=O:location.href=O,d=null,setTimeout(function(){j.revokeObjectURL(O)},4e4)}});p.saveAs=u.saveAs=u,a.exports=u})}(So)),So.exports}J0();const ti=M.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}}}),X0=M.useLoginState(M.pinia),{loginUserInfo:xt}=M.storeToRefs(X0),Z0=async a=>{var n,i,o;let l=await M.getAllTables({platId:parseInt((n=xt==null?void 0:xt.value)==null?void 0:n.plat_id),tableNames:[a]});return l=(o=(i=l==null?void 0:l.data)==null?void 0:i.result)==null?void 0:o[0],await Sc(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}]}]},Q0=M.useLoginState(),{loginUserInfo:yl}=M.storeToRefs(Q0);let bo="$R";const Wr=M.useModelComp(M.pinia),zc=e.ref(!1),{itemData:e3,itemGridData:hi,curStructureCompIds:Ms,isSubmitCurStructure:a3,routeToChildPath:l3,pageMapState:zt,itemExtendData:ko,refreshTable:Is,refreshCurrentPageInform:r3}=M.storeToRefs(Wr),Fo=ti(M.pinia),ln=M.useMenuState(M.pinia),kr=e.shallowRef([]),{asideMenus:n3,activeTopMenuPath:i3,activeMenuPath:Cl,platform:a8,buttonTriggerType:o3,currentMenuPath:_n}=M.storeToRefs(ln),Nn=M.useUnit(M.pinia),{selectTitle:ni,chooseTitle:zo}=M.storeToRefs(Nn);e.ref();const Ri=e.ref(!0),oi=e.ref(0),Mt=e.ref([]);e.ref(!1);const Pt=e.ref(!1),Qi=e.ref(),Mc=e.ref(),Ic=e.ref(),t3=()=>{Wr.setItemGridData([]),Wr.setIsEdit("edit"),Wr.setSubmitCurStructure(Cl.value!=="/平台管理/菜单管理")},s3=()=>{Wr.setIsEdit("view"),Wr.setRefreshCurStructure(!0)},c3=async a=>{var i;let l=ni.value,r=l==null?void 0:l.findIndex(o=>(o==null?void 0:o.value)===(a==null?void 0:a.value)),n=l==null?void 0:l.filter((o,p)=>p<=r);Nn.setSelectTitle(pl.safeClone(n)),n=(i=n==null?void 0:n.map(o=>o==null?void 0:o.value))==null?void 0:i.join("/"),ln.setActiveMenuPath(null),ln.setActiveMenuPath(n)},wt=async(a,l,r,n="contentConfig")=>{var i;try{if(!Array.isArray(a))return;let o,p;l==="create"?(o={dataList:a==null?void 0:a.map(u=>{var m;return{key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:r!=null&&r.startsWith("/")?r==null?void 0:r.substring(1):r,type:"structure",structureBelong:n,parentTable:"",version:1},value:{pageData:{...u,compData:(m=u==null?void 0:u.compData)==null?void 0:m.filter(g=>(g==null?void 0:g.key)!=="tableContents")}}}})},p=Kr.batchAddInsofDataApi):l==="update"?(o={dataList:a==null?void 0:a.map(u=>{var m;return{id:u==null?void 0:u.id,value:{pageData:{...u,compData:(m=u==null?void 0:u.compData)==null?void 0:m.filter(g=>(g==null?void 0:g.key)!=="tableContents")}}}})},p=Kr.batchUpdateInsofDataApi):l==="delete"&&(o={ids:a},p=Kr.batchDeleteInsofDataApi);const c=await p(o);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("保存响应失败")}},Os=async(a,l,r,n)=>{var i,o,p,c,u,m,g,y,d,D,w;try{const q=(o=(i=a==null?void 0:a.results)==null?void 0:i.filter(x=>!(x!=null&&x.id)||typeof(x==null?void 0:x.id)=="string"))==null?void 0:o.map(x=>({key:{pageKey:a==null?void 0:a.pageKey,systemKey:sessionStorage.getItem("systemKey"),type:l,relatedInfo:r},value:{tableData:x}})),A=(c=(p=a==null?void 0:a.results)==null?void 0:p.filter(x=>(x==null?void 0:x.id)&&typeof(x==null?void 0:x.id)=="number"))==null?void 0:c.map(x=>({id:x==null?void 0:x.id,value:{tableData:x}})),j=JSON.parse(JSON.stringify(a)),O=(u=j==null?void 0:j.results)==null?void 0:u.map(x=>x.id);let E;r?E=(y=(g=(m=zt.value)==null?void 0:m[Cl.value])==null?void 0:g.filter(x=>{var b,S,I;return((b=x==null?void 0:x.key)==null?void 0:b.type)===l&&((I=(S=x==null?void 0:x.key)==null?void 0:S.relatedInfo)==null?void 0:I.target)===n}))==null?void 0:y.map(x=>x==null?void 0:x.id):E=(w=(D=(d=zt.value)==null?void 0:d[Cl.value])==null?void 0:D.filter(x=>{var b;return((b=x==null?void 0:x.key)==null?void 0:b.type)===l}))==null?void 0:w.map(x=>x==null?void 0:x.id);const _=E==null?void 0:E.filter(x=>!(O!=null&&O.includes(x))&&typeof x=="number");(q==null?void 0:q.length)>0&&await Kr.batchAddInsofDataApi({dataList:q}),(A==null?void 0:A.length)>0&&await Kr.batchUpdateInsofDataApi({dataList:A}),(_==null?void 0:_.length)>0&&await Kr.batchDeleteInsofDataApi({ids:_})}catch(q){throw new Error(q)}},u3=async a=>{var m,g,y,d,D,w,q,A,j,O;ln.setContentLoading(!0);const l=JSON.parse(JSON.stringify(e3.value));if(!a3.value)return ln.setCacheStructures({key:o3.value,data:l}),Ja.ElMessage.success("已暂存");const r=l==null?void 0:l.map(E=>E.id),n=r.filter(E=>{var _;return!((_=Ms.value)!=null&&_.includes(E))}),i=(m=Ms.value)==null?void 0:m.filter(E=>!r.includes(E)),o=[...n,...i].filter(E=>typeof E!==null&&typeof E<"u"),p=l==null?void 0:l.filter(E=>!E.id),c=l==null?void 0:l.filter(E=>E.id);let u=[];if(o&&(o==null?void 0:o.length)>0&&u.push(wt(o,"delete",a)),p&&(p==null?void 0:p.length)>0&&u.push(wt(p,"create",a)),c&&(c==null?void 0:c.length)>0&&u.push(wt(c,"update",a)),hi.value&&((g=hi.value)!=null&&g.isDelete&&((d=(y=hi.value)==null?void 0:y.results)==null?void 0:d.length)>0&&((w=(D=hi.value)==null?void 0:D.results)!=null&&w.every(E=>typeof E=="number"))?await Kr.batchDeleteInsofDataApi({ids:(q=hi.value)==null?void 0:q.results}):(console.log("itemGridData.value",hi.value),u.push(await Os(hi.value,"gridLayout")))),ko.value)for(const E in ko.value)u.push(await Os((A=ko.value)==null?void 0:A[E],"extend",{target:E,compId:(O=(j=ko.value)==null?void 0:j[E])==null?void 0:O.compId},E));await Promise.all(u).then(()=>{Ja.ElMessage.success("保存成功"),Wr.setRefreshCurStructure(!0)}).catch(E=>{Ja.ElMessage.success(E)}),ln.setContentLoading(!1)},eo=a=>$i(a),d3=e.computed(()=>{var a;return(a=kr.value)==null?void 0:a.filter(l=>(l==null?void 0:l.affix)&&(l==null?void 0:l.affix)!=="default")}),Oc=e.computed(()=>{var a;return(a=kr.value)==null?void 0:a.filter(l=>!(l!=null&&l.affix&&(l==null?void 0:l.affix)!=="default"))}),Lc=e.ref(0),Rc=e.ref(null),p3="ocr_committed_temp_ids_v1",f3=(a,l)=>`${p3}:${String(a??"")}:${String(l??"")}`,h3=(a,l,r)=>{try{const n=f3(a,l),i=sessionStorage.getItem(n),o=i?JSON.parse(i):[],p=Array.isArray(o)?o:[],c=Array.from(new Set([...p,...r||[]].map(u=>String(u)))).slice(-200);sessionStorage.setItem(n,JSON.stringify(c))}catch{}},Mo=async(a,l="data",r)=>{var i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr;let n=((p=(o=(i=ni.value)==null?void 0:i.filter(ga=>(ga==null?void 0:ga.condition)==="child"))==null?void 0:o[0])==null?void 0:p.value)??"";if((a==null?void 0:a.buttonName)==="新增"){let ga=(c=a==null?void 0:a.fixContent)==null?void 0:c.map(il=>{let fl={};for(let Bl in il)Array.isArray(il==null?void 0:il[Bl])?fl[Bl]=JSON.stringify(il==null?void 0:il[Bl]):fl[Bl]=il==null?void 0:il[Bl];return fl});if(ga!=null&&ga.every(il=>il==null?void 0:il.menuPathContent)){let il=(u=ga==null?void 0:ga[0])==null?void 0:u.menuPathContent;ga=ga==null?void 0:ga.map(oa=>(oa.id="0",oa==null||delete oa.menuPathContent,oa)),(il==null?void 0:il[0])==="$"&&(il=il==null?void 0:il.slice(1,il==null?void 0:il.length));let fl=(m=le.analyzeSplitToContent(il,"*"))==null?void 0:m[0],Bl=(g=le.analyzeSplitToContent(il,"*"))==null?void 0:g[1];fl=fl==null?void 0:fl.slice(0,(fl==null?void 0:fl.length)-1),fl=(y=le.analyzeSplitToContent(fl,":"))==null?void 0:y.map(oa=>{var Ka,pe,_a,Pa,ul;if((oa==null?void 0:oa[(oa==null?void 0:oa.length)-1])===":"&&(oa=oa==null?void 0:oa.slice(0,(oa==null?void 0:oa.length)-1)),(oa==null?void 0:oa[0])==="{"){oa=oa==null?void 0:oa.slice(1,(oa==null?void 0:oa.length)-1),(oa==null?void 0:oa[0])==="*"&&(oa=oa==null?void 0:oa.slice(1,oa==null?void 0:oa.length));let Ol=oa==null?void 0:oa.split(":"),ca=Ol==null?void 0:Ol[0],Xa=Ol==null?void 0:Ol[1];Xa=Xa==null?void 0:Xa.slice(1,(Xa==null?void 0:Xa.length)-1);let ua=(Ka=kr.value)==null?void 0:Ka.filter(wa=>(wa==null?void 0:wa.name)===ca);ua=ua==null?void 0:ua[0],ua=(ul=(Pa=(_a=(pe=ua==null?void 0:ua.compData)==null?void 0:pe.find(wa=>(wa==null?void 0:wa.key)==="tableContents"))==null?void 0:_a.contents)==null?void 0:Pa[0])==null?void 0:ul[Xa],oa=ua}return oa}),fl=fl==null?void 0:fl.join("/");let Ha=await M.getPageDataApi({platId:parseInt((d=yl==null?void 0:yl.value)==null?void 0:d.plat_id),pageName:"menu"});Ha=(D=Ha==null?void 0:Ha.data)==null?void 0:D.result,Ha=Ha==null?void 0:Ha.find(oa=>(oa==null?void 0:oa.object_name)===fl&&(oa==null?void 0:oa.property_name)===Bl);let Sa=(Ha==null?void 0:Ha.object_id)??"";if(Sa===""){Ja.ElMessage.warning("添加页面数据不存在");return}let ll=[{tableName:"content_"+Sa,tableContents:ga}];await M.pageBatchAddApi({platId:parseInt((w=yl==null?void 0:yl.value)==null?void 0:w.plat_id),changeContents:ll});let Te=[];ll==null||ll.forEach(oa=>{var Ka;(Ka=oa==null?void 0:oa.tableContents)==null||Ka.forEach(pe=>{Te.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(pe),request_result:"{}",is_delete:!1,request_table:oa==null?void 0:oa.tableName,request_type:"add"})})}),await M.pageBatchAddApi({platId:parseInt((q=yl==null?void 0:yl.value)==null?void 0:q.plat_id),changeContents:[{tableName:"log",tableContents:Te}]})}else{let il=await M.quoteApi({platId:parseInt((A=yl==null?void 0:yl.value)==null?void 0:A.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});il=(j=il==null?void 0:il.data)==null?void 0:j.result,il=il==null?void 0:il.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let fl=il==null?void 0:il.map(Te=>{var _a,Pa;let oa={},Ka=ga==null?void 0:ga[0],pe;return Array.isArray((_a=Te==null?void 0:Te.struct)==null?void 0:_a[0])?pe=le.getColumnChild((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0]):pe=Te==null?void 0:Te.struct,pe=pe==null?void 0:pe.filter(ul=>(ul==null?void 0:ul.prop)!=="relatedId"),pe==null||pe.forEach(ul=>{var Ol,ca;oa[ul.prop]=((Ol=ul==null?void 0:ul.words)!=null&&Ol[0]?(Ka==null?void 0:Ka[(ca=ul==null?void 0:ul.words)==null?void 0:ca[0]])??(Ka==null?void 0:Ka[ul==null?void 0:ul.prop]):Ka==null?void 0:Ka[ul==null?void 0:ul.prop])??""}),oa.id="1",oa.relatedId=`[${oa.id}]`,delete oa.sort,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[oa]}}),Bl=[{tableName:(O=a==null?void 0:a.relatedContents)==null?void 0:O.find(Te=>Te==null?void 0:Te.includes("content")),tableContents:ga}];Bl=[...Bl,...fl];let Ha=await M.quoteApi({platId:parseInt((E=yl==null?void 0:yl.value)==null?void 0:E.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Ha=(x=(_=Ha==null?void 0:Ha.data)==null?void 0:_.result)==null?void 0:x.filter(Te=>!(Bl!=null&&Bl.find(oa=>(oa==null?void 0:oa.tableName)==="content_"+(Te==null?void 0:Te.id)))),Ha=Ha==null?void 0:Ha.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let Sa=Ha==null?void 0:Ha.map(Te=>{var _a,Pa,ul,Ol,ca,Xa,ua;let oa={},Ka=ga==null?void 0:ga[0],pe;return Array.isArray((_a=Te==null?void 0:Te.struct)==null?void 0:_a[0])?pe=le.getColumnChild((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0]):pe=Te==null?void 0:Te.struct,pe=pe==null?void 0:pe.filter(wa=>(wa==null?void 0:wa.prop)!=="relatedId"),((Ol=(ul=pe==null?void 0:pe[0])==null?void 0:ul.words)!=null&&Ol[0]?Ka!=null&&Ka[(Xa=(ca=pe==null?void 0:pe[0])==null?void 0:ca.words)==null?void 0:Xa[0]]:Ka!=null&&Ka[(ua=pe==null?void 0:pe[0])==null?void 0:ua.prop])?(pe==null||pe.forEach(wa=>{var Ba,hl;oa[wa.prop]=((Ba=wa==null?void 0:wa.words)!=null&&Ba[0]?(Ka==null?void 0:Ka[(hl=wa==null?void 0:wa.words)==null?void 0:hl[0]])??(Ka==null?void 0:Ka[wa==null?void 0:wa.prop]):Ka==null?void 0:Ka[wa==null?void 0:wa.prop])??""}),oa.id="1",oa.relatedId=`[${oa.id}]`,delete oa.sort):oa=void 0,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[oa]}});Sa=Sa==null?void 0:Sa.filter(Te=>{var oa;return!((oa=Te==null?void 0:Te.tableContents)!=null&&oa.every(Ka=>Ka===void 0))}),Bl=[...Bl,...Sa],await M.pageBatchAddApi({platId:parseInt((b=yl==null?void 0:yl.value)==null?void 0:b.plat_id),changeContents:Bl});let ll=[];Bl==null||Bl.forEach(Te=>{var oa;(oa=Te==null?void 0:Te.tableContents)==null||oa.forEach(Ka=>{ll.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Ka),request_result:"{}",is_delete:!1,request_table:Te==null?void 0:Te.tableName,request_type:"add"})})}),await M.pageBatchAddApi({platId:parseInt((S=yl==null?void 0:yl.value)==null?void 0:S.plat_id),changeContents:[{tableName:"log",tableContents:ll}]})}}if((a==null?void 0:a.buttonName)==="OCR批量新增"){const ga=((a==null?void 0:a.ocrRows)||[]).map(Ha=>Ha==null?void 0:Ha.id).filter(Ha=>Ha!=null),il=((a==null?void 0:a.ocrRows)||[]).map(Ha=>{const Sa={...Ha};return delete Sa._isOCRRow,delete Sa._ocrTableId,Object.keys(Sa).forEach(ll=>{/(^|\.)证书附件$/.test(ll)&&Array.isArray(Sa[ll])&&(Sa[ll]=JSON.stringify(Sa[ll].map(Te=>({url:(Te==null?void 0:Te.url)||"",name:(Te==null?void 0:Te.name)||(Te==null?void 0:Te.fileName)||"",fileName:(Te==null?void 0:Te.fileName)||(Te==null?void 0:Te.name)||""})).filter(Te=>Te.url||Te.name)))}),Sa});let fl=[{tableName:(I=a==null?void 0:a.relatedContents)==null?void 0:I.find(Ha=>Ha==null?void 0:Ha.includes("content")),tableContents:il}];await M.pageBatchAddApi({platId:parseInt((R=yl==null?void 0:yl.value)==null?void 0:R.plat_id),changeContents:fl});let Bl=[];fl==null||fl.forEach(Ha=>{var Sa;(Sa=Ha==null?void 0:Ha.tableContents)==null||Sa.forEach(ll=>{Bl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ll),request_result:"{}",is_delete:!1,request_table:Ha==null?void 0:Ha.tableName,request_type:"ocrBatchAdd"})})}),await M.pageBatchAddApi({platId:parseInt((re=yl==null?void 0:yl.value)==null?void 0:re.plat_id),changeContents:[{tableName:"log",tableContents:Bl}]}),h3(a==null?void 0:a.parentTableId,a==null?void 0:a.index,ga)}if((a==null?void 0:a.buttonName)==="编辑"){const il=((a==null?void 0:a.fixContent)||(a==null?void 0:a.singleContent)||[]||[]).map(pe=>{const _a={...pe};return delete _a._isOCRRow,delete _a._ocrTableId,delete _a._isTemp,delete _a.tableEditType,delete _a.index,_a});let fl=il==null?void 0:il.map(pe=>{let _a={};for(let Pa in pe)Array.isArray(pe==null?void 0:pe[Pa])?_a[Pa]=JSON.stringify(pe==null?void 0:pe[Pa]):_a[Pa]=pe==null?void 0:pe[Pa];return _a}),Bl=await M.quoteApi({platId:parseInt((X=yl==null?void 0:yl.value)==null?void 0:X.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Bl=(me=Bl==null?void 0:Bl.data)==null?void 0:me.result,Bl=Bl==null?void 0:Bl.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))});let Ha=(ue=fl==null?void 0:fl[0])==null?void 0:ue.id,Sa=[{tableName:(U=a==null?void 0:a.relatedContents)==null?void 0:U.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:fl}],ll=(W=Bl==null?void 0:Bl.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa,Ba;return JSON.stringify(ua==null?void 0:ua.relatedId)!=="{}"&&(ua==null?void 0:ua.relatedId)!==""&&(ua!=null&&ua.relatedId)?(wa=ua==null?void 0:ua.relatedId)==null?void 0:wa.includes(parseInt(Ha)):(ua==null?void 0:ua.sort)===((Ba=fl==null?void 0:fl[0])==null?void 0:Ba.sort)});if((_a==null?void 0:_a.length)>0){let ua=fl==null?void 0:fl[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var bl,tr;wa[Fe.prop]=((bl=Fe==null?void 0:Fe.words)!=null&&bl[0]?(Ba==null?void 0:Ba[(tr=Fe==null?void 0:Fe.words)==null?void 0:tr[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??""}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,delete wa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:W.filter(pe=>pe);Sa=[...Sa,...ll];let Te=await M.quoteApi({platId:parseInt((Z=yl==null?void 0:yl.value)==null?void 0:Z.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Te=(ve=(ae=Te==null?void 0:Te.data)==null?void 0:ae.result)==null?void 0:ve.filter(pe=>!(Sa!=null&&Sa.find(_a=>(_a==null?void 0:_a.tableName)==="content_"+(pe==null?void 0:pe.id)))),Te=Te==null?void 0:Te.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))});let oa=(ze=Te==null?void 0:Te.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa,Ba,hl;return JSON.stringify(ua==null?void 0:ua.relatedId)!=="{}"&&(ua==null?void 0:ua.relatedId)!==""&&(ua!=null&&ua.relatedId)?(wa=ua==null?void 0:ua.relatedId)==null?void 0:wa.includes(parseInt(Ha)):(ua==null?void 0:ua.sort)===((Ba=fl==null?void 0:fl[0])==null?void 0:Ba.sort)||(ua==null?void 0:ua.sort)===(parseInt(((hl=fl==null?void 0:fl[0])==null?void 0:hl.sort)??"0")+1).toString()});if((_a==null?void 0:_a.length)>0){let ua=fl==null?void 0:fl[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var bl,tr,xr,Ra;((bl=Fe==null?void 0:Fe.words)!=null&&bl[0]?(Ba==null?void 0:Ba[(tr=Fe==null?void 0:Fe.words)==null?void 0:tr[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba!=null&&Ba[Fe==null?void 0:Fe.prop])&&(wa[Fe.prop]=((xr=Fe==null?void 0:Fe.words)!=null&&xr[0]?(Ba==null?void 0:Ba[(Ra=Fe==null?void 0:Fe.words)==null?void 0:Ra[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??"")}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,delete wa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:ze.filter(pe=>pe);Sa=[...Sa,...oa],await M.pageBatchUpdateApi({platId:parseInt((te=yl==null?void 0:yl.value)==null?void 0:te.plat_id),changeContents:Sa});let Ka=[];Sa==null||Sa.forEach(pe=>{var _a;(_a=pe==null?void 0:pe.tableContents)==null||_a.forEach(Pa=>{Ka.push({id:"1",request_method:"Post",request_url:"/platform/page/update",request_param:JSON.stringify(Pa),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"update"})})}),await M.pageBatchAddApi({platId:parseInt((N=yl==null?void 0:yl.value)==null?void 0:N.plat_id),changeContents:[{tableName:"log",tableContents:Ka}]})}if((a==null?void 0:a.buttonName)==="删除"){let ga=[{tableName:(se=a==null?void 0:a.relatedContents)==null?void 0:se.find(Te=>Te==null?void 0:Te.includes("content")),tableContents:a==null?void 0:a.fixContent}],il=await M.quoteApi({platId:parseInt((G=yl==null?void 0:yl.value)==null?void 0:G.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});il=(fe=il==null?void 0:il.data)==null?void 0:fe.result,il=il==null?void 0:il.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let fl=(_e=(we=a==null?void 0:a.fixContent)==null?void 0:we[0])==null?void 0:_e.id,Bl=(qe=il==null?void 0:il.map(Te=>{var Ka,pe,_a,Pa,ul,Ol;let oa=(Ka=Te==null?void 0:Te.contents)==null?void 0:Ka.filter(ca=>{var Xa,ua,wa;return JSON.stringify(ca==null?void 0:ca.relatedId)!=="{}"&&(ca==null?void 0:ca.relatedId)!==""&&(ca!=null&&ca.relatedId)?(Xa=ca==null?void 0:ca.relatedId)==null?void 0:Xa.includes(parseInt(fl)):(ca==null?void 0:ca.sort)===((wa=(ua=a==null?void 0:a.fixContent)==null?void 0:ua[0])==null?void 0:wa.sort)});if((oa==null?void 0:oa.length)>0){let ca=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];ca={...ca,id:(_a=oa==null?void 0:oa[0])==null?void 0:_a.id};let Xa={},ua=ca,wa;return Array.isArray((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0])?wa=le.getColumnChild((ul=Te==null?void 0:Te.struct)==null?void 0:ul[0]):wa=Te==null?void 0:Te.struct,wa=wa==null?void 0:wa.filter(Ba=>(Ba==null?void 0:Ba.prop)!=="relatedId"),wa==null||wa.forEach(Ba=>{var hl,Fe;Xa[Ba.prop]=((hl=Ba==null?void 0:Ba.words)!=null&&hl[0]?(ua==null?void 0:ua[(Fe=Ba==null?void 0:Ba.words)==null?void 0:Fe[0]])??(ua==null?void 0:ua[Ba==null?void 0:Ba.prop]):ua==null?void 0:ua[Ba==null?void 0:Ba.prop])??""}),Xa.id=(Ol=oa==null?void 0:oa[0])==null?void 0:Ol.id,delete Xa.sort,delete Xa.relatedId,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[Xa]}}else return}))==null?void 0:qe.filter(Te=>Te);ga=[...ga,...Bl];let Ha=await M.quoteApi({platId:parseInt((ra=yl==null?void 0:yl.value)==null?void 0:ra.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Ha=(Ke=(P=Ha==null?void 0:Ha.data)==null?void 0:P.result)==null?void 0:Ke.filter(Te=>!(ga!=null&&ga.find(oa=>(oa==null?void 0:oa.tableName)==="content_"+(Te==null?void 0:Te.id)))),Ha=Ha==null?void 0:Ha.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let Sa=(Me=Ha==null?void 0:Ha.map(Te=>{var Ka,pe,_a,Pa,ul,Ol;let oa=(Ka=Te==null?void 0:Te.contents)==null?void 0:Ka.filter(ca=>{var Xa,ua,wa;return JSON.stringify(ca==null?void 0:ca.relatedId)!=="{}"&&(ca==null?void 0:ca.relatedId)!==""&&(ca!=null&&ca.relatedId)?(Xa=ca==null?void 0:ca.relatedId)==null?void 0:Xa.includes(parseInt(fl)):(ca==null?void 0:ca.sort)===((wa=(ua=a==null?void 0:a.fixContent)==null?void 0:ua[0])==null?void 0:wa.sort)});if((oa==null?void 0:oa.length)>0){let ca=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];ca={...ca,id:(_a=oa==null?void 0:oa[0])==null?void 0:_a.id};let Xa={},ua=ca,wa;return Array.isArray((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0])?wa=le.getColumnChild((ul=Te==null?void 0:Te.struct)==null?void 0:ul[0]):wa=Te==null?void 0:Te.struct,wa=wa==null?void 0:wa.filter(Ba=>(Ba==null?void 0:Ba.prop)!=="relatedId"),wa==null||wa.forEach(Ba=>{var hl,Fe;Xa[Ba.prop]=((hl=Ba==null?void 0:Ba.words)!=null&&hl[0]?(ua==null?void 0:ua[(Fe=Ba==null?void 0:Ba.words)==null?void 0:Fe[0]])??(ua==null?void 0:ua[Ba==null?void 0:Ba.prop]):ua==null?void 0:ua[Ba==null?void 0:Ba.prop])??""}),Xa.id=(Ol=oa==null?void 0:oa[0])==null?void 0:Ol.id,delete Xa.sort,delete Xa.relatedId,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[Xa]}}else return}))==null?void 0:Me.filter(Te=>Te);ga=[...ga,...Sa],await M.pageBatchDeleteApi({platId:parseInt((Le=yl==null?void 0:yl.value)==null?void 0:Le.plat_id),changeContents:ga});let ll=[];ga==null||ga.forEach(Te=>{var oa;(oa=Te==null?void 0:Te.tableContents)==null||oa.forEach(Ka=>{ll.push({id:"1",request_method:"Post",request_url:"/platform/page/delete",request_param:JSON.stringify(Ka),request_result:"{}",is_delete:!1,request_table:Te==null?void 0:Te.tableName,request_type:"delete"})})}),await M.pageBatchAddApi({platId:parseInt((Ie=yl==null?void 0:yl.value)==null?void 0:Ie.plat_id),changeContents:[{tableName:"log",tableContents:ll}]})}if((a==null?void 0:a.buttonName)==="复制新增"){let ga=await M.getPageDataApi({platId:parseInt((de=yl==null?void 0:yl.value)==null?void 0:de.plat_id),pageName:"menu"});if(ga=(De=ga==null?void 0:ga.data)==null?void 0:De.result,ga!=null&&ga.find(il=>(il==null?void 0:il.father_name)===Cl.value+"/")){Ic.value=a,Mc.value=ga==null?void 0:ga.filter(Bl=>(Bl==null?void 0:Bl.father_name)===Cl.value+"/");let il=(Ea=(Xe=a==null?void 0:a.columns)==null?void 0:Xe.find(Bl=>Bl==null?void 0:Bl.mainKey))==null?void 0:Ea.prop,fl=($=(Ge=a==null?void 0:a.fixContent)==null?void 0:Ge[0])==null?void 0:$[il];Pt.value=!0,Qi.value=[{prop:il,label:il,name:il,value:fl}]}else{let il=(V=a==null?void 0:a.fixContent)==null?void 0:V.map(Ha=>{let Sa={};for(let ll in Ha)Array.isArray(Ha==null?void 0:Ha[ll])?Sa[ll]=JSON.stringify(Ha==null?void 0:Ha[ll]):Sa[ll]=Ha==null?void 0:Ha[ll];return Sa.relatedId="",Sa}),fl=[{tableName:(ee=a==null?void 0:a.relatedContents)==null?void 0:ee.find(Ha=>Ha==null?void 0:Ha.includes("content")),tableContents:il}];await M.pageBatchAddApi({platId:parseInt((ce=yl==null?void 0:yl.value)==null?void 0:ce.plat_id),changeContents:fl});let Bl=[];fl==null||fl.forEach(Ha=>{var Sa;(Sa=Ha==null?void 0:Ha.tableContents)==null||Sa.forEach(ll=>{Bl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ll),request_result:"{}",is_delete:!1,request_table:Ha==null?void 0:Ha.tableName,request_type:"copyAdd"})})}),await M.pageBatchAddApi({platId:parseInt((he=yl==null?void 0:yl.value)==null?void 0:he.plat_id),changeContents:[{tableName:"log",tableContents:Bl}]})}}if((a==null?void 0:a.buttonName)==="methodButton"){let ga=((Ve=(ia=(pa=a==null?void 0:a.columns)==null?void 0:pa.map(pe=>pe==null?void 0:pe.filter))==null?void 0:ia.filter(pe=>pe!==""))==null?void 0:Ve[0])??"";ga=le.analyzeSplitToContent(ga,","),ga=(ga==null?void 0:ga.find(pe=>pe==null?void 0:pe.includes("@Filter")))??"";let il=(ya=a==null?void 0:a.fixContent)==null?void 0:ya.map(pe=>{let _a={};for(let Pa in pe)Array.isArray(pe==null?void 0:pe[Pa])?_a[Pa]=JSON.stringify(pe==null?void 0:pe[Pa]):_a[Pa]=pe==null?void 0:pe[Pa];return _a}),fl=await M.quoteApi({platId:parseInt((Ca=yl==null?void 0:yl.value)==null?void 0:Ca.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});fl=(Ce=fl==null?void 0:fl.data)==null?void 0:Ce.result,fl=fl==null?void 0:fl.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))});let Bl=(Ta=(Fa=a==null?void 0:a.columns)==null?void 0:Fa[0])==null?void 0:Ta.prop,Ha=(fa=il==null?void 0:il[0])==null?void 0:fa[Bl],Sa=[{tableName:(ja=a==null?void 0:a.relatedContents)==null?void 0:ja.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:il}],ll=(sa=fl==null?void 0:fl.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa;return(wa=Object.values(ua))==null?void 0:wa.find(Ba=>Ba===Ha)});if((_a==null?void 0:_a.length)>0){let ua=il==null?void 0:il[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var bl,tr;wa[Fe.prop]=((bl=Fe==null?void 0:Fe.words)!=null&&bl[0]?(Ba==null?void 0:Ba[(tr=Fe==null?void 0:Fe.words)==null?void 0:tr[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??""}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:sa.filter(pe=>pe);Sa=[...Sa,...ll];let Te=await M.quoteApi({platId:parseInt((Pe=yl==null?void 0:yl.value)==null?void 0:Pe.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});if(Te=(Qe=(ma=Te==null?void 0:Te.data)==null?void 0:ma.result)==null?void 0:Qe.filter(pe=>!(Sa!=null&&Sa.find(_a=>(_a==null?void 0:_a.tableName)==="content_"+(pe==null?void 0:pe.id)))),Te=Te==null?void 0:Te.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))}),ga&&ga!==""){(ga==null?void 0:ga[(ga==null?void 0:ga.length)-1])===","&&(ga=ga==null?void 0:ga.slice(0,(ga==null?void 0:ga.length)-1)),ga=($e=(Oe=ga==null?void 0:ga.replace("(",bo))==null?void 0:Oe.split(bo))==null?void 0:$e[1],ga=ga==null?void 0:ga.slice(0,(ga==null?void 0:ga.length)-1),(ga==null?void 0:ga[0])==="*"&&(ga="{"+((We=(ne=ga==null?void 0:ga.replace("{",bo))==null?void 0:ne.split(bo))==null?void 0:We[1])),ga=(na=ga==null?void 0:ga.replaceAll("{",""))==null?void 0:na.replaceAll("}","");let pe=le.calculatorAndToOr(ga);pe=pe==null?void 0:pe[0];let _a;if((va=Object.values(pe))!=null&&va.some(Pa=>(Pa==null?void 0:Pa[0])==="*")){let Pa=(Be=(Ae=ni.value)==null?void 0:Ae.find(ul=>(ul==null?void 0:ul.condition)==="child"))!=null&&Be.value?(_n==null?void 0:_n.value)+"/"+((Ee=(Ye=ni.value)==null?void 0:Ye.find(ul=>(ul==null?void 0:ul.condition)==="child"))==null?void 0:Ee.value):_n==null?void 0:_n.value;_a=await Hr(Pa,!1)}for(let Pa in pe)if(((ye=pe==null?void 0:pe[Pa])==null?void 0:ye[0])==="*"){let ul=(Pl=(Qa=(wl=pe[Pa])==null?void 0:wl.slice(1,($a=pe[Pa])==null?void 0:$a.length))==null?void 0:Qa.split(":"))==null?void 0:Pl[0],Ol=(jl=(gl=pe[Pa])==null?void 0:gl.split(":"))==null?void 0:jl[1],ca=(al=_a==null?void 0:_a.filter(Xa=>(Xa==null?void 0:Xa.name)===ul))==null?void 0:al[0];ca=(Wa=(Hl=ca==null?void 0:ca.compData)==null?void 0:Hl.find(Xa=>(Xa==null?void 0:Xa.key)==="tableContents"))==null?void 0:Wa.contents,ca=(Gl=ca==null?void 0:ca[0])==null?void 0:Gl[Ol],pe[Pa]=ca}ga=((Kl=Object.values(pe))==null?void 0:Kl[0])??""}let oa=(Zl=Te==null?void 0:Te.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa;return(wa=Object.values(ua))==null?void 0:wa.find(Ba=>Ba===(ga===""?Ha:ga))});if((_a==null?void 0:_a.length)>0){let ua=il==null?void 0:il[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var tr,xr,Ra,kl;let bl=(tr=a==null?void 0:a.columns)==null?void 0:tr.find(Ml=>{var Oa,aa,Rl;return((aa=(Oa=Ml==null?void 0:Ml.words)==null?void 0:Oa[0])==null?void 0:aa.replaceAll("'",""))===(Fe==null?void 0:Fe.prop)&&((Rl=Ml==null?void 0:Ml.functionRelatedWords)==null?void 0:Rl.length)>0});bl=(xr=bl==null?void 0:bl.prop)==null?void 0:xr.replaceAll("'",""),wa[Fe.prop]=((Ra=Fe==null?void 0:Fe.words)!=null&&Ra[0]?(Ba==null?void 0:Ba[(kl=Fe==null?void 0:Fe.words)==null?void 0:kl[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??(Ba==null?void 0:Ba[bl]):(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??(Ba==null?void 0:Ba[bl]))??void 0}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:Zl.filter(pe=>pe);Sa=[...Sa,...oa],await M.pageBatchUpdateApi({platId:parseInt((Sl=yl==null?void 0:yl.value)==null?void 0:Sl.plat_id),changeContents:Sa});let Ka=[];Sa==null||Sa.forEach(pe=>{var _a;(_a=pe==null?void 0:pe.tableContents)==null||_a.forEach(Pa=>{Ka.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Pa),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"method"})})}),await M.pageBatchAddApi({platId:parseInt((dr=yl==null?void 0:yl.value)==null?void 0:dr.plat_id),changeContents:[{tableName:"log",tableContents:Ka}]})}Wr.setRefreshCurStructure(!0),Wr.setRefreshCurrentPageInform(r3.value++),await Ot(a)},It=async(a,l,r)=>{var i;let n=a==null?void 0:a.find(o=>(o==null?void 0:o.id)===l);if(n){let o=(i=n.compData)==null?void 0:i.map(p=>{var c;if((p==null?void 0:p.key)==="tableContents"){let u={...p,contents:r};return u.contents=(c=(u==null?void 0:u.contents)??[])==null?void 0:c.map(m=>{let g={};for(let y in m)JSON.stringify(m==null?void 0:m[y])==="{}"?g[y]="":g[y]=m==null?void 0:m[y];return g}),u}return p});return n.compData=await Vo(o,{}),a=a==null?void 0:a.map(p=>((p==null?void 0:p.id)===(n==null?void 0:n.id)&&(p=n),p)),a}else{let o=a==null?void 0:a.filter(c=>{var u;return(c==null?void 0:c.children)&&((u=c==null?void 0:c.children)==null?void 0:u.length)>0||(c==null?void 0:c.comp)==="Tabs"}),p=o==null?void 0:o.map(async c=>{var u;return c!=null&&c.children&&((u=c==null?void 0:c.children)==null?void 0:u.length)>0?c.children=await It(c==null?void 0:c.children,l,r):c.compData=await It(c==null?void 0:c.compData,l,r),c});return o=await Promise.all(p),o}},Ot=async a=>{var o,p,c,u,m,g,y;let l=(o=a==null?void 0:a.relatedContents)==null?void 0:o.filter(d=>d==null?void 0:d.includes("content_"));if(!l)return;let r=await M.getAllTables({platId:parseInt((p=yl==null?void 0:yl.value)==null?void 0:p.plat_id),tableNames:l??[]});if(r=(u=(c=r==null?void 0:r.data)==null?void 0:c.result)==null?void 0:u[0],!r||!Array.isArray(r))return;r=r==null?void 0:r.map(d=>{d==null||delete d.source_table;const D={};for(let w in d){const q=d==null?void 0:d[w],A=q&&Object.prototype.toString.call(q)==="[object Object]"&&Object.keys(q).length===0,j=Array.isArray(q)&&q.length===0;q==null||q==="{}"||A||j?D[w]="":D[w]=q}return D});let n=(g=(m=l==null?void 0:l[0])==null?void 0:m.split("_"))==null?void 0:g[1],i=await It(kr.value,n,r);kr.value=(y=kr.value)==null?void 0:y.map(d=>{var D,w;return(D=i==null?void 0:i[0])!=null&&D.tabInform&&((w=i==null?void 0:i[0])==null?void 0:w.tabInform)===(d==null?void 0:d.tabInform)?d=i==null?void 0:i[0]:(d!=null&&d.name?(d==null?void 0:d.name)===(i==null?void 0:i.name):(d==null?void 0:d.id)===(i==null?void 0:i.id))&&(d=i),d})},v3=a=>{let l=Qi.value;Qi.value=l==null?void 0:l.map(r=>(r.value=a==null?void 0:a[r==null?void 0:r.prop],r))},m3=async()=>{var d,D,w,q,A,j,O,E,_,x;let a=Ic.value,l=Mc.value,r=(D=(d=a==null?void 0:a.columns)==null?void 0:d.find(b=>b==null?void 0:b.mainKey))==null?void 0:D.prop,n=(q=(w=Qi.value)==null?void 0:w[0])==null?void 0:q.value,i=(A=a==null?void 0:a.fixContent)==null?void 0:A.map(b=>{var I;let S={};for(let R in b)Array.isArray(b==null?void 0:b[R])?S[R]=JSON.stringify(b==null?void 0:b[R]):S[R]=b==null?void 0:b[R];return(I=a==null?void 0:a.columns)==null||I.forEach(R=>{(R==null?void 0:R.formType)==="Upload"&&(S==null?void 0:S[R==null?void 0:R.prop])===""&&(S[R==null?void 0:R.prop]="{}")}),S[r]=n,S}),o=[{tableName:(j=a==null?void 0:a.relatedContents)==null?void 0:j.find(b=>b==null?void 0:b.includes("content")),tableContents:i}];await M.pageBatchAddApi({platId:parseInt((O=yl==null?void 0:yl.value)==null?void 0:O.plat_id),changeContents:o}),l=l==null?void 0:l.filter(b=>{var S,I,R;return(R=b==null?void 0:b.object_name)==null?void 0:R.includes((I=(S=a==null?void 0:a.fixContent)==null?void 0:S[0])==null?void 0:I[r])});let p=[],c=new Map;l==null||l.forEach(b=>{p.push(`content_${b==null?void 0:b.object_id}`),p.push(`struct_${b==null?void 0:b.object_id}`),c.set(b==null?void 0:b.object_id,b)});let u=await M.getAllTables({platId:parseInt((E=yl==null?void 0:yl.value)==null?void 0:E.plat_id),tableNames:p??[]});u=(_=u==null?void 0:u.data)==null?void 0:_.result;let m=[],g=[];u=le.chunk(u,2),u==null||u.forEach(b=>{var R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P;let S=c.get((me=(X=(re=(R=b==null?void 0:b[1])==null?void 0:R[0])==null?void 0:re.source_table)==null?void 0:X.split("_"))==null?void 0:me[1]),I=(W=(U=(ue=S==null?void 0:S.object_name)==null?void 0:ue.split("/"))==null?void 0:U.filter((Ke,Me)=>{var Le,Ie;return((Ie=(Le=S==null?void 0:S.object_name)==null?void 0:Le.split("/"))==null?void 0:Ie.length)-1!==Me}))==null?void 0:W.join("/");if(I=I+"/"+n,g!=null&&g.find(Ke=>(Ke==null?void 0:Ke.path)===I)||g.push({fatherPath:S==null?void 0:S.father_name,isShow:S==null?void 0:S.is_show,path:I}),((ae=(Z=b==null?void 0:b[1])==null?void 0:Z[0])==null?void 0:ae.类型)==="Table"){let Ke=((te=(ze=(ve=b==null?void 0:b[1])==null?void 0:ve[0])==null?void 0:ze.结构)==null?void 0:te.contents)??[],Me=pl.safeClone(Ke);Array.isArray(Me==null?void 0:Me[0])&&(Me=le.getColumnChild(Me==null?void 0:Me[0]));let Le=[];if(((N=b==null?void 0:b[0])==null?void 0:N.length)>0&&(Le=(se=b==null?void 0:b[0])==null?void 0:se.map(Ie=>Me==null?void 0:Me.map(De=>(De=(Ie==null?void 0:Ie[De==null?void 0:De.prop])??"",De)))),m!=null&&m.find(Ie=>(Ie==null?void 0:Ie.key)===I)){let Ie=(G=m==null?void 0:m.find(De=>(De==null?void 0:De.key)===I))==null?void 0:G.contents;Ie.push({isShow:S==null?void 0:S.is_show,filter:((_e=(we=(fe=b==null?void 0:b[1])==null?void 0:fe[0])==null?void 0:we.引用)==null?void 0:_e.contents)??"",key:"Table",name:Object.values(S==null?void 0:S.name),tableColumns:Ke,tableContents:Le});let de=m==null?void 0:m.findIndex(De=>(De==null?void 0:De.key)===I);m[de].contents=Ie}else m.push({key:I,contents:[{isShow:S==null?void 0:S.is_show,filter:((P=(ra=(qe=b==null?void 0:b[1])==null?void 0:qe[0])==null?void 0:ra.引用)==null?void 0:P.contents)??"",key:"Table",name:Object.values(S==null?void 0:S.name),tableColumns:Ke,tableContents:Le}]})}});let y=[];y.push({key:"menuPath",contents:g}),y=[...y,...m],await M.createPlatFormDataApi({platId:parseInt((x=yl==null?void 0:yl.value)==null?void 0:x.plat_id),changeData:y}),Pt.value=!1,Wr.setRefreshTable(!0)},Io=async(a,l)=>{},Oo=async a=>{kr.value=await le.getDeepDiffItems(a),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value)};e.ref();const y3=e.ref(null),g3=()=>{var a,l;console.log("倒计时结束时"),M.ElMessageBox.alert(`超时未提交,【${(l=(a=Cl.value)==null?void 0:a.split("/"))==null?void 0:l[0]}】失败`,"告警",{confirmButtonText:"确认",type:"error"})},$c=e.ref([]),b3=e.computed(()=>{var a,l;return(l=(a=zt.value)==null?void 0:a[Cl.value])==null?void 0:l.filter(r=>{var n;return((n=r==null?void 0:r.key)==null?void 0:n.type)==="gridLayout"})});e.watch(()=>[i3.value],()=>{Nn.setSelectTitle([]),Nn.setChooseTitle([])},{deep:!0});e.watch(()=>zo.value,async(a,l)=>{var n,i,o,p,c,u;let r=(n=zo.value)==null?void 0:n.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==_n.value);if((r==null?void 0:r.length)>0){ln.setContentLoading(!0);let m=((i=r==null?void 0:r[0])==null?void 0:i.relatedContent)??(Cl==null?void 0:Cl.value),g=m+"/"+((o=r==null?void 0:r[0])==null?void 0:o.value),y=!!((p=r==null?void 0:r[0])!=null&&p.parentContent),d=await Hr(g,y,{originPath:m});d=(c=d==null?void 0:d.filter(q=>q))==null?void 0:c.map(q=>(q.isShow=!0,q)),console.log(d,"loadingContents");let D=await le.getDeepDiffItems(d),w=D==null?void 0:D.filter(q=>q==null?void 0:q.choice);Fo.setSelectTab((u=w==null?void 0:w[0])==null?void 0:u.choiceName),D=D==null?void 0:D.filter(q=>{var A;return!(q!=null&&q.choiceName)||(q==null?void 0:q.choiceName)===((A=w==null?void 0:w[0])==null?void 0:A.choiceName)}),kr.value=D,ln.setContentLoading(!1)}});const k3=(a,l)=>{setTimeout(async()=>{var c,u,m;let r=(c=zo.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)!==_n.value),n=Cl==null?void 0:Cl.value,i=Cl==null?void 0:Cl.value;(r==null?void 0:r.length)>0&&(i=((u=r==null?void 0:r[0])==null?void 0:u.relatedContent)??(Cl==null?void 0:Cl.value),n=i+"/"+((m=r==null?void 0:r[0])==null?void 0:m.value));let o=await Hr(n,!1,{originPath:i});o=o==null?void 0:o.map(g=>(g.isShow=!0,g));let p=await le.getDeepDiffItems(o);kr.value=p==null?void 0:p.filter(g=>!(g!=null&&g.step)||(g==null?void 0:g.step)===(a==null?void 0:a.title))},10)},x3=a=>{setTimeout(async()=>{var p,c,u;let l=(p=zo.value)==null?void 0:p.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==_n.value),r=Cl==null?void 0:Cl.value,n=Cl==null?void 0:Cl.value;(l==null?void 0:l.length)>0&&(n=((c=l==null?void 0:l[0])==null?void 0:c.relatedContent)??(Cl==null?void 0:Cl.value),r=n+"/"+((u=l==null?void 0:l[0])==null?void 0:u.value));let i=await Hr(r,!1,{originPath:n});i=i==null?void 0:i.map(m=>(m.isShow=!0,m)),Fo.setSelectTab(a);let o=await le.getDeepDiffItems(i);kr.value=o==null?void 0:o.filter(m=>!(m!=null&&m.choiceName)||(m==null?void 0:m.choiceName)===a)},10)};e.watch(()=>n3.value,a=>{a!=null&&a.length||(kr.value=[])},{immediate:!0});e.watch(()=>[Cl.value],async a=>{var o,p,c,u;if(!Cl.value)return;if(Cl.value==="/"){kr.value=[];return}ln.setCurrentMenuPath(Cl.value),Wr.setLockingPage(""),kr.value=[];let l=e.getCurrentInstance();(o=l==null?void 0:l.scope)==null||o.stop(),l=null,Ri.value=!1,ln.setContentLoading(!0),zc.value=!0;let r=a==null?void 0:a[0],n=r,i=(p=ni.value)==null?void 0:p.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==Cl.value&&!(m!=null&&m.relatedContent));if((i==null?void 0:i.length)>0&&(r=r+"/"+((c=i==null?void 0:i[0])==null?void 0:c.value)),r==="系统管理/日志管理")kr.value=await Z0("log");else{let m=await Hr(r,!0,{originPath:n});m=m==null?void 0:m.map(d=>(d.isShow=!0,d));let g=await le.getDeepDiffItems(m),y=g==null?void 0:g.filter(d=>d==null?void 0:d.choice);Fo.setSelectTab((u=y==null?void 0:y[0])==null?void 0:u.choiceName),kr.value=g==null?void 0:g.filter(d=>{var D;return!(d!=null&&d.choiceName)||(d==null?void 0:d.choiceName)===((D=y==null?void 0:y[0])==null?void 0:D.choiceName)})}ln.setContentLoading(!1),Wr.setExtraContents([]),Nn.setSelectIndex(""),Nn.setSelectMenu(""),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value),Wr.setRefreshTable(!1),e.nextTick(()=>{oi.value=oi.value++,Ri.value=!0})},{immediate:!0});e.watch(()=>[Is.value],async()=>{var a,l,r,n;if(Is.value){kr.value=[];let i=e.getCurrentInstance();(a=i==null?void 0:i.scope)==null||a.stop(),i=null,Ri.value=!1,ln.setContentLoading(!0),zc.value=!0;let o=_n==null?void 0:_n.value,p=o,c=(l=ni.value)==null?void 0:l.filter(y=>(y==null?void 0:y.condition)==="child"&&(y==null?void 0:y.value)!==""&&(y==null?void 0:y.parentContent)!==(_n==null?void 0:_n.value));(c==null?void 0:c.length)>0&&(o=o+"/"+((r=c==null?void 0:c[0])==null?void 0:r.value));let u=await Hr(o,!0,{originPath:p});u=u==null?void 0:u.map(y=>(y.isShow=!0,y));let m=await le.getDeepDiffItems(u),g=m==null?void 0:m.filter(y=>y==null?void 0:y.choice);if(Fo.setSelectTab((n=g==null?void 0:g[0])==null?void 0:n.choiceName),kr.value=m==null?void 0:m.filter(y=>{var d;return!(y!=null&&y.choiceName)||(y==null?void 0:y.choiceName)===((d=g==null?void 0:g[0])==null?void 0:d.choiceName)}),ln.setContentLoading(!1),Wr.setExtraContents([]),Nn.setSelectIndex(""),Nn.setSelectMenu(""),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value),Wr.setRefreshTable(!1),(c==null?void 0:c.length)>0){let y=[...ni.value,...c];Nn.setSelectTitle(y)}e.nextTick(()=>{oi.value=oi.value++,Ri.value=!0})}},{immediate:!0,deep:!0});const w3=async()=>{ln.setLinkMenuInfo(null),ln.setActiveMenuPath(l3.value),kr.value=null,Wr.setRouteToChildPath(""),ln.setChildMenu("")},_3=a=>new RegExp("button","i").test(a),S3=a=>/^[\u4e00-\u9fa5]+\/[\u4e00-\u9fa5]+\^(.+)$/.test(a),Vc=a=>{if(S3(a)){const l=a==null?void 0:a.split("^");(l==null?void 0:l.length)>0&&(l!=null&&l[0])&&ln.setLinkMenuInfo({path:l==null?void 0:l[0],data:l==null?void 0:l[1]})}},Fc=async(a,l,r)=>{var d,D,w,q,A,j,O,E,_,x,b,S;let n="",i="";for(let I in l)(l==null?void 0:l[I])===a&&(i=I);r==null||r.forEach(I=>{(I==null?void 0:I.prop)===i&&(n=I==null?void 0:I.fatherPath)});let o=n===""?Cl.value:n;n!==""&&ln.setCurrentMenuPath(o),ln.setCurrentMenuPath(o+"/"+a),ln.setContentLoading(!0),kr.value=await Hr(o+"/"+a,!0,{originPath:o+"/",row:l});let p=await Hr(o,!1),c=(d=p==null?void 0:p.filter(I=>(I==null?void 0:I.comp)==="Table"))==null?void 0:d[0],u=((A=(q=(w=(D=c==null?void 0:c.compData)==null?void 0:D.find(I=>(I==null?void 0:I.key)==="header"))==null?void 0:w.contents)==null?void 0:q[0])==null?void 0:A.prop)??((x=(_=(E=(O=(j=c==null?void 0:c.compData)==null?void 0:j.find(I=>(I==null?void 0:I.key)==="header"))==null?void 0:O.contents)==null?void 0:E[0])==null?void 0:_[0])==null?void 0:x.prop),m=(S=(b=c==null?void 0:c.compData)==null?void 0:b.find(I=>(I==null?void 0:I.key)==="tableContents"))==null?void 0:S.contents;m=m==null?void 0:m.map(I=>({label:I==null?void 0:I[u],value:I==null?void 0:I[u]}));let g=ni.value,y={value:a,condition:"child",options:m,relatedContent:o,isShow:!0};g=g==null?void 0:g.filter(I=>(I==null?void 0:I.condition)!=="child"),g.push(y),Nn.setSelectTitle(g),Nn.setChooseTitle([y]),ln.setContentLoading(!1),Wr.setExtraContents([]),Nn.setSelectIndex(""),Nn.setSelectMenu(""),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value)},E3=a=>{Lc.value=a},Mi=e.reactive({index:0,comp:null}),C3=e.computed(()=>{var a;return(a=kr.value)==null?void 0:a.map((l,r)=>({id:l.id,name:l.name,status:D3(l,r)}))}),Pc=(a,l)=>{var u,m,g,y,d;const r=l?a:a-2,n=(u=kr.value)==null?void 0:u[r],i=(g=(m=n==null?void 0:n.compData)==null?void 0:m.find(D=>(D==null?void 0:D.key)==="header"))==null?void 0:g.contents,o=i==null?void 0:i.findIndex(D=>(D==null?void 0:D.isMainKey)&&(D==null?void 0:D.label)!=="操作"),p=o===-1?0:o,c=(d=(y=n==null?void 0:n.compData)==null?void 0:y.find(D=>(D==null?void 0:D.key)==="tableContents"))==null?void 0:d.contents;return{valid:c==null?void 0:c.every(D=>D==null?void 0:D[p+1]),length:(c==null?void 0:c.length)||0}},D3=(a,l)=>{var n;let r="process";if(((n=a==null?void 0:a.comp)==null?void 0:n.toUpperCase())==="TABLE"){const{valid:i,length:o}=Pc(l,!0);Mi.index===l?r="process":o===0?r="wait":r=i?"success":"error"}return r},jc=a=>{var r,n,i,o,p;const l=a+1;if(l>1&&((i=(n=(r=kr.value)==null?void 0:r[a])==null?void 0:n.comp)==null?void 0:i.toUpperCase())==="TABLE"){const{valid:c}=Pc(l);c?(Mi.index=l,Mi.comp=(o=kr.value)==null?void 0:o[a]):Ja.ElMessage({showClose:!0,type:"warning",message:"当前流程有输入未完成"})}else Mi.index=l,Mi.comp=(p=kr.value)==null?void 0:p[a]},Hc=e.computed(()=>{var a,l;return(l=(a=Oc.value)==null?void 0:a[0])==null?void 0:l.isStepLayout});e.watch(()=>Hc.value,a=>{a&&jc(0)},{immediate:!0});const Lo=e.ref(0),Uc=a=>{var l;return!a||(a==null?void 0:a.length)===0?[]:(l=M.cloneDeep(a))==null?void 0:l.map(n=>(Lo.value++,n={label:(n==null?void 0:n.label)??"",prop:(n==null?void 0:n.label)==="操作"?"operate":n==null?void 0:n.prop,width:n!=null&&n.width?parseInt(n.width):"",fixed:(n==null?void 0:n.fixed)??void 0,sortable:(n==null?void 0:n.sortable)??!1,align:(n==null?void 0:n.align)??"left",showOverflowTooltip:(n==null?void 0:n.showOverflowTooltip)??!0,isNotDrag:(n==null?void 0:n.isNotDrag)??!1,isEditCol:(n==null?void 0:n.isEditCol)??!1,isOperate:(n==null?void 0:n.isOperate)??!1,id:(n==null?void 0:n.id)??Lo.value,children:Uc(n==null?void 0:n.children)},n))},T3=a=>{var r;return(r=M.cloneDeep(a))==null?void 0:r.map(n=>(Lo.value++,n={label:(n==null?void 0:n.label)??"",prop:(n==null?void 0:n.label)==="操作"?"operate":n==null?void 0:n.prop,width:n!=null&&n.width?parseInt(n.width):"",fixed:(n==null?void 0:n.fixed)??void 0,sortable:(n==null?void 0:n.sortable)??!1,align:(n==null?void 0:n.align)??"left",showOverflowTooltip:(n==null?void 0:n.showOverflowTooltip)??!0,isNotDrag:(n==null?void 0:n.isNotDrag)??!1,isEditCol:(n==null?void 0:n.isEditCol)??!1,isOperate:(n==null?void 0:n.isOperate)??!1,id:(n==null?void 0:n.id)??Lo.value,children:Uc(n==null?void 0:n.children)},n))},qc=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===l)?(r=M.cloneDeep(a))==null?void 0:r.filter(i=>(i==null?void 0:i.id)!==l):(a=a==null?void 0:a.map(n=>(n.children=qc(n==null?void 0:n.children,l),n)),a)},Wc=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===(l==null?void 0:l.id))?(r=M.cloneDeep(a))==null?void 0:r.map(i=>((i==null?void 0:i.id)===(l==null?void 0:l.id)&&(i=l),i)):(a=a==null?void 0:a.map(n=>(n.children=Wc(n==null?void 0:n.children,l),n)),a)},Gc=(a,l)=>{var r;return a!=null&&a.find(n=>{var i;return(n==null?void 0:n.id)===((i=l==null?void 0:l.contents)==null?void 0:i.id)})?(r=M.cloneDeep(a))==null?void 0:r.map(i=>{var o;return(i==null?void 0:i.id)===((o=l==null?void 0:l.contents)==null?void 0:o.id)&&(i=l==null?void 0:l.contents),i}):(a=a==null?void 0:a.map(n=>(n.children=Gc(n==null?void 0:n.children,l),n)),a)},Kc=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===(l==null?void 0:l.id))?(r=M.cloneDeep(a))==null?void 0:r.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(n=>(n.children=Kc(n==null?void 0:n.children,l),n)),a)},_r=[{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"}],B3=[{label:"查看",value:"view"},{label:"修改",value:"fix"},{label:"删除",value:"delete"},{label:"三维算例",value:"modelExample"}],N3=[{label:"新增",value:"add"}],Jn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:N3},{key:"background",label:"按钮背景色",type:"Color"}],Xn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:B3},{key:"textColor",label:"按钮颜色",type:"Color"}],A3={class:"table-content"},z3={class:"menu-config-wrap"},M3=["onClick"],I3={key:0,class:"viewport-wrap"},O3=["onClick"],L3={title:"选择显示列信息"},R3={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"}},$3=["title"],V3={class:"col-operate-wrap"},F3={key:0,class:"col-operate-radio-wrapper"},P3={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},j3={key:0,style:{display:"flex","justify-content":"center","align-items":"center"}},H3={class:"pop-view"},U3={class:"pop-wrapper"},q3={class:"file-list-pop"},W3=["title","onClick"],G3=["onClick"],K3=["onClick"],Y3={key:1,style:{display:"flex","justify-content":"flex-end",gap:"8px","margin-top":"8px"}},J3={class:"form-content"},X3={key:0,class:"dialog-footer"},Z3={class:"dialog-footer"},Q3={class:"ocr-dialog-content"},eh={class:"ocr-steps"},ah={key:0,class:"ocr-action-buttons"},lh={key:1,class:"ocr-preview-area"},rh={class:"ocr-file-grid"},nh={class:"file-thumbnail"},ih=["src"],oh={key:1,class:"thumbnail-placeholder"},th={class:"progress-svg",viewBox:"0 0 36 36"},sh=["stroke","stroke-width","stroke-dasharray"],ch={key:0,class:"progress-icon"},uh={key:1,class:"progress-icon"},dh=["onClick"],ph={class:"file-name"},fh={key:0,class:"ocr-recognize-button"},hh={key:2,class:"ocr-progress-section"},vh={key:3,class:"ocr-confirm-area"},mh={class:"ocr-preview-tip"},yh={class:"ocr-preview-table"},gh={style:{display:"flex","align-items":"center",gap:"8px"}},bh={key:0},kh={key:4,class:"ocr-success-area"},xh={key:0,class:"ocr-dialog-footer"},wh={class:"form-content"},_h={style:{width:"100%",margin:"0","font-size":"14px","font-weight":"600"}},Sh={style:{display:"flex","justify-content":"space-between",gap:"8px"}},Eh={style:{display:"flex"}},Ls="ss-ocr-upload-history",Ch="ss-ocr-cert-history-v1",Dh={__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},calculator:{type:Array,default:()=>[]},itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,isDevMode:Boolean,changedContent:{type:Object,default:()=>{}},showHeader:{type:Boolean,default:!0},allowSelect:{type:Boolean,default:!0},allowOperate:{type:Boolean,default:!0},allMapContents:{type:Object,default:()=>{}}},emits:["getSliceContLength","clickMainKey","change","contentChange","onButtonClick","contentClick","pageChange","rowClick","routeUrl"],setup(a,{emit:l}){var Qt;const r=e.ref([]),n=Ft(M.pinia),i=e.ref(null),o=e.ref(new Set),p=e.ref(new Map),c=e.ref(!1),u=e.ref([]),m=e.ref(new Map),g=new Map,y=e.ref(new Map),d=a,D=e.ref((d==null?void 0:d.allowSelect)??!0),w=e.ref(((Qt=d==null?void 0:d.config)==null?void 0:Qt.showIndex)??!0),q=e.ref(),A=e.ref(!0),j=e.ref(!1),O=e.ref([]),E={sortable:"switch",filterable:"switch",showSummary:"switch",operable:"switch",fixed:"radio"},_=e.ref([{label:"排序",value:"sortable",checked:!1},{label:"合计",value:"showSummary",checked:!1},{type:"radio",label:"固定",value:"fixed",checked:"",options:[{label:"无",value:!1},{label:"左",value:"left"},{label:"右",value:"right"}]}]),x=le.useOriginalState(M.pinia);let b="$R";const{originalPath:S}=M.storeToRefs(x),I=S.value,R=e.computed(()=>{var v;const f=(v=le.getAllLeafNodes(W.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 f.length>0?f.every(z=>!!(z!=null&&z.sortable)):!1});e.computed(()=>{var v;return(v=W.value)==null?void 0:v.every(z=>z==null?void 0:z.filterable)}),e.computed(()=>{var v;return(v=W.value)==null?void 0:v.every(z=>z==null?void 0:z.operable)});const re=e.ref(!0),X=e.ref([]),me=e.reactive({column:{},status:!1,text:"合计"}),ue=e.reactive({currentPage:1,pageSize:10,total:0,pageSizes:[5,10,20]}),U=l,W=e.ref([]),Z=e.ref([]),ae=e.ref([]),ve=e.reactive({prop:"",order:null}),ze=e.ref([]),te=e.ref(!1),N=e.ref(!1),se=e.ref(null),{isUseBackdrop:G,initTrackFileType:fe,getFileExtension:we,setData:_e,getFileInfo:qe,getFilesInfo:ra}=Do.useThreeSystem(),P=e.ref([]),Ke=e.ref(!1),Me=e.ref(),Le=M.useMenuState(),{importLoading:Ie,activeMenuPath:de,contentLoading:De,linkMenuInfo:Xe}=M.storeToRefs(Le),Ea=le.useTableComp(M.pinia),Ge=M.useModelComp(M.pinia),$=ti(M.pinia),{extraContents:V,cacheUpdatingData:ee,tableViewContents:ce,tableLoading:he,pageMapState:pa,lockingPage:ia}=M.storeToRefs(Ge),{selectTab:Ve}=M.storeToRefs($),{compType:ya,hasEditable:Ca}=dc.useRole(),Ce=e.ref([]),Fa=e.ref([]),Ta=e.ref(new Map);e.ref(!1);const fa=e.ref("");e.ref();const ja=e.ref(!0),sa=e.ref(0),Pe=e.ref(!0),ma=e.ref(""),Qe=e.ref(!1),Oe=e.ref(null);e.ref([]);const $e=e.ref({label:"查看三维模型"}),ne=e.ref(!1),We=e.ref(),na=e.ref([]),va=e.ref([]),Ae=e.ref(!1),Be=e.ref([]),Ye=e.ref([]),Ee=e.ref([]),ye=e.ref([]),$a=e.ref({dialogShow:!1,dialogTitle:""}),wl=()=>{$a.value.dialogShow=!1,$a.value.dialogTitle=""},Qa=f=>{console.log("Received signature data:",f),$a.value.dialogShow=!1},Pl=e.ref([]),gl=()=>{try{const f=localStorage.getItem(Ls),v=f?JSON.parse(f):[];Pl.value=Array.isArray(v)?v:[]}catch{Pl.value=[]}},jl=()=>{try{localStorage.setItem(Ls,JSON.stringify(Pl.value||[]))}catch{}},al=f=>{var ie,oe,K;if(!f)return;const v=f.url||((ie=f==null?void 0:f.uploadResult)==null?void 0:ie.url)||"",z=f.name||((oe=f==null?void 0:f.uploadResult)==null?void 0:oe.name)||((K=f==null?void 0:f.uploadResult)==null?void 0:K.fileName)||"";if(!v&&!z)return;const L={name:z,url:v,ts:Date.now()},H=String(L.name||"").trim().toLowerCase(),T=(Pl.value||[]).findIndex(ke=>String((ke==null?void 0:ke.name)||"").trim().toLowerCase()===H);T>-1&&Pl.value.splice(T,1),Pl.value.unshift(L),Pl.value.length>20&&(Pl.value=Pl.value.slice(0,20)),jl()};gl();const Hl=(f,v)=>`${Ch}:${String(f??"")}:${String(v??"")}`,Wa=(f,v)=>{try{const z=sessionStorage.getItem(Hl(f,v)),L=z?JSON.parse(z):[];return Array.isArray(L)?L:[]}catch{return[]}},Gl=(f,v,z)=>{try{sessionStorage.setItem(Hl(f,v),JSON.stringify(Array.isArray(z)?z:[]))}catch{}},Kl=(f,v,z)=>{if(!v)return;const L=Wa(f,v),H=[z,...L||[]].filter(Boolean).slice(0,1);return Gl(f,v,H),H},Zl=(f,v,z)=>{if(!v||!z)return;const L=Hl(f,v),H=Hl(f,z);try{const T=sessionStorage.getItem(L);if(!T)return;const ie=(()=>{try{const ke=JSON.parse(T);return Array.isArray(ke)?ke:[]}catch{return[]}})(),oe=Wa(f,z),K=[...ie,...oe||[]].filter(Boolean).sort((ke,ge)=>Number((ge==null?void 0:ge.ts)||0)-Number((ke==null?void 0:ke.ts)||0)).slice(0,1);sessionStorage.setItem(H,JSON.stringify(K)),sessionStorage.removeItem(L)}catch{}},Sl=e.ref(!1),dr=e.ref(!1),ga=e.ref([]),il=e.ref(null);e.ref(!1),e.ref([]),e.ref(""),e.ref("");const fl=e.ref(!1),Bl=e.ref([]),Ha=e.ref(1),Sa=e.ref(new Map),ll=e.ref(new Map),Te=e.ref(0),oa=e.ref(!1),Ka=e.ref([]),pe=e.ref([]),_a=f=>{var v;try{const z=(v=le.getAllLeafNodes(W.value)||[])==null?void 0:v.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate");return(z==null?void 0:z.find(L=>(L==null?void 0:L.prop)===f||(L==null?void 0:L.label)===f))||null}catch{return null}},Pa=f=>{const v=_a(f),z=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"Input";return pl.getComponent(z)||pl.getComponent("Input")},ul=e.ref([]),Ol=e.ref(null),ca=e.ref([]),Xa=e.ref(null),ua=e.ref(""),wa=e.ref(!1),Ba=e.ref([]),hl=e.ref(""),Fe=e.ref(!1),bl=e.ref([]),tr=e.ref([]),xr=e.ref([]),Ra=e.ref(null),kl=e.ref([]),Ml=e.ref("");e.computed(()=>{var f;try{const v=(f=le.getAllLeafNodes(W.value)||[])==null?void 0:f.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate"),z=new Map;return v==null||v.forEach(L=>{L!=null&&L.label&&(L!=null&&L.prop)&&z.set(L.label,L.prop)}),z.get("编号")||""}catch{return""}});const Oa=e.computed(()=>{var f;try{const v=(f=le.getAllLeafNodes(W.value)||[])==null?void 0:f.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate"),z=new Map;return v==null||v.forEach(L=>{L!=null&&L.label&&(L!=null&&L.prop)&&z.set(L.label,L.prop)}),z.get("名称")||""}catch{return""}}),aa=e.computed(()=>{var f;try{const v=(f=le.getAllLeafNodes(W.value)||[])==null?void 0:f.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate"),z=new Map;return v==null||v.forEach(L=>{L!=null&&L.label&&(L!=null&&L.prop)&&z.set(L.label,L.prop)}),z.get("制造厂")||""}catch{return""}}),Rl=()=>{Fe.value=!1,bl.value=[],tr.value=[],xr.value=[],Ra.value=null,kl.value=[],Ml.value=""},Yr=f=>f==null?!1:typeof f=="string"?f.trim()!=="":Array.isArray(f)?f.length>0:!0,Jr=(f,v)=>{const z=(f==null?void 0:f.ocrRow)||{};for(const H of Object.keys(z))H==="id"||H==="_isOCRRow"||H==="_ocrTableId"||Yr(z[H])&&(v[H]=z[H]);const L=Fa.value.find(H=>H.id===v.id);if(L)for(const H of Object.keys(z))H==="id"||H==="_isOCRRow"||H==="_ocrTableId"||Yr(z[H])&&(L[H]=z[H]);Ta.value&&Ta.value.set(v.id,v),Kl(d==null?void 0:d.index,v.id,f==null?void 0:f.versionItem),tr.value=[...tr.value||[],JSON.parse(JSON.stringify(v))]},vn=async(f,v=null)=>{var z,L,H,T,ie,oe,K;try{const ke=(z=le.getAllLeafNodes(W.value)||[])==null?void 0:z.filter(ka=>(ka==null?void 0:ka.type)!=="operate"&&(ka==null?void 0:ka.label)!=="操作"&&(ka==null?void 0:ka.prop)!=="operate"),ge=new Map;ke==null||ke.forEach(ka=>{ka!=null&&ka.label&&(ka!=null&&ka.prop)&&ge.set(ka.label,ka.prop)});const Je=ge.get("系统编号")||ge.get("编号");if(!Je){console.warn("未找到系统编号字段,跳过向检校记录表插入数据");return}const Ue=v||Ra.value;if((Array.isArray(Ue==null?void 0:Ue.result)?Ue.result:[]).length===0){console.warn("OCR识别结果为空,跳过向检校记录表插入数据");return}for(let ka=0;ka<f.length;ka++){const Na=f[ka],Aa=Na[Je];if(!Aa){console.warn(`第 ${ka+1} 条匹配行缺少系统编号,跳过`);continue}const la=`设备管理/试验设备/${Aa}`,ol=await M.getPageDataApi({platId:parseInt((L=Nl.value)==null?void 0:L.plat_id),pageName:la});if(!((H=ol==null?void 0:ol.data)!=null&&H.result)||!Array.isArray(ol.data.result)){console.warn(`未找到详情页数据: ${la}`);continue}const xa=ol.data.result.find(ha=>(ha==null?void 0:ha.property_name)==="校检记录");if(!xa){console.warn(`详情页 ${la} 中未找到校检记录表`);continue}const tl=(T=xa.contents)==null?void 0:T.find(ha=>(ha==null?void 0:ha.key)&&ha.key.startsWith("content_"));if(!tl||!tl.key){console.warn("校检记录表中未找到 content item");continue}const be=tl.key,Va=Array.isArray(tl.value)?tl.value:[];if(Va.length>=5){const B=[...Va].sort((za,Ua)=>{const sl=Number((za==null?void 0:za.create_time)||0),Ga=Number((Ua==null?void 0:Ua.create_time)||0);return sl-Ga})[0];B!=null&&B.id&&await M.pageBatchDeleteApi({platId:parseInt((ie=Nl.value)==null?void 0:ie.plat_id),changeContents:[{tableName:be,tableContents:[{id:B.id}]}]})}const ba=(oe=ke==null?void 0:ke.find(ha=>(ha==null?void 0:ha.label)==="证书附件"))==null?void 0:oe.prop,Ya=String(Date.now()),Ia={id:Ya},Ne=Va[0]||{},Q=new Date().toISOString().split("T")[0];if(Object.keys(Ne||{}).forEach(ha=>{if(ha!=="id"){if(ha==="证书附件"){Ia[ha]="";return}if(ha==="校检日期"||ha==="检校日期"){Ia[ha]=Na[ha]||Na.校检日期||Na.检校日期||Q;return}if(["校检周期","检校周期","校检结果","检校结果","计量状态","依据文件","证书编号"].includes(ha)){Ia[ha]=Na[ha]??"";return}Ia[ha]=Na[ha]??""}}),ba&&Na[ba]){const ha=Na[ba];if(Array.isArray(ha)&&ha.length>0)Ia.证书附件=JSON.stringify(ha.map(B=>({url:(B==null?void 0:B.url)||"",name:(B==null?void 0:B.name)||(B==null?void 0:B.fileName)||"",fileName:(B==null?void 0:B.fileName)||(B==null?void 0:B.name)||""})).filter(B=>B.url||B.name));else if(typeof ha=="string")try{const B=JSON.parse(ha);Ia.证书附件=ha}catch{Ia.证书附件=JSON.stringify([{url:ha,name:ha,fileName:ha}])}}console.log(be,"tableName","inspectionRecordRow",Ia),await M.pageBatchAddApi({platId:parseInt((K=Nl.value)==null?void 0:K.plat_id),changeContents:[{tableName:be,tableContents:[Ia]}]});const je=xa==null?void 0:xa.object_id;if(je&&Ya){const ha=ba&&Na[ba]?Na[ba]:null;let B=[],za="",Ua=!1;if(Array.isArray(ha)&&ha.length>0){B=ha.map(dl=>({name:(dl==null?void 0:dl.name)||(dl==null?void 0:dl.fileName)||"",url:(dl==null?void 0:dl.url)||""})).filter(dl=>dl.url||dl.name);const Ga=ha[0];za=(Ga==null?void 0:Ga.url)||"";const Da=(Ga==null?void 0:Ga.name)||(Ga==null?void 0:Ga.fileName)||"";Ua=String(Da).toLowerCase().endsWith(".pdf")||String(za).toLowerCase().endsWith(".pdf")}else if(typeof ha=="string")try{const Ga=JSON.parse(ha);Array.isArray(Ga)?(B=Ga.map(Da=>({name:(Da==null?void 0:Da.name)||(Da==null?void 0:Da.fileName)||"",url:(Da==null?void 0:Da.url)||""})).filter(Da=>Da.url||Da.name),B.length>0&&(za=B[0].url||"",Ua=String(B[0].name).toLowerCase().endsWith(".pdf")||String(za).toLowerCase().endsWith(".pdf"))):(za=ha,Ua=String(ha).toLowerCase().endsWith(".pdf"))}catch{za=ha,Ua=String(ha).toLowerCase().endsWith(".pdf")}const sl={ts:Date.now(),versionId:String(Date.now())+"_"+String(ka),label:new Date().toLocaleString(),certType:Na.证书类型||"",certNo:Na.证书编号||"",fileType:Ua?"pdf":"image",sourceUrl:Ua?za:"",images:B};Kl(je,Ya,sl)}}}catch(ke){console.error("向校检记录表插入OCR识别结果失败:",ke),Ja.ElMessage.error("向校检记录表插入数据失败,请查看控制台")}},en=f=>{const v=Array.isArray(f)?f:bl.value||[];if(v.length===0){Rl();return}if(v.find(T=>(T==null?void 0:T.__decision)==="replace"&&!(T!=null&&T.selectedTargetId))){Ja.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}v.forEach(T=>{var oe;const ie=T==null?void 0:T.__decision;if(!(!ie||ie==="skip")){if(ie==="add"){Kl(d==null?void 0:d.index,(oe=T==null?void 0:T.ocrRow)==null?void 0:oe.id,T==null?void 0:T.versionItem),xr.value=[...xr.value||[],T.ocrRow];return}if(ie==="replace"){const K=T==null?void 0:T.selectedTargetId,ke=(Ce.value||[]).find(ge=>String(ge==null?void 0:ge.id)===String(K));if(!ke)return;Jr(T,ke)}}}),(tr.value||[]).length>0&&(Ce.value=[...Ce.value||[]]),(xr.value||[]).length>0&&(Ce.value=[...Ce.value||[],...xr.value||[]],Fa.value=[...Fa.value||[],...xr.value||[]],(xr.value||[]).forEach(T=>{var ie,oe;return(oe=(ie=Ta.value)==null?void 0:ie.set)==null?void 0:oe.call(ie,T.id,T)})),Sr.value=Ce.value;const L=tr.value||[],H=xr.value||[];if(L.length>0&&(U("change",{buttonName:"编辑",singleContent:L,content:Ce.value,relatedContents:d==null?void 0:d.related,index:d==null?void 0:d.index,parentTableId:d==null?void 0:d.parentTableId,columns:W.value,name:d==null?void 0:d.compName}),vn(L)),H.length>0){const T=Ra.value;U("change",{buttonName:"OCR批量新增",content:Ce.value,index:d==null?void 0:d.index,parentTableId:d==null?void 0:d.parentTableId,column:W.value,ocrRows:H,relatedContents:d==null?void 0:d.related,uploadedFiles:(Array.isArray(T==null?void 0:T.result)?T.result:[]).map(ie=>(Array.isArray(ie==null?void 0:ie.图片信息)?ie.图片信息:[]).map(oe=>({url:(oe==null?void 0:oe.url)||"",name:(oe==null?void 0:oe.name)||"",fileName:(oe==null?void 0:oe.name)||""})).filter(oe=>oe.url)),ocrResult:T,matchedCount:(L||[]).length,newCount:(H||[]).length})}Ja.ElMessage.success("已提交候选处理结果"),Rl()},Ar=Nc(),Re=e.computed(()=>Ar.getConfig()),lr=e.ref(),Yl=e.ref(),an=Ec(M.pinia),Sr=e.ref(),Jl=e.ref(0),Er=M.useUnit(M.pinia),{selectIndex:Xl,selectMenu:$l,selectTitle:nr}=M.storeToRefs(Er),{selectString:Ql}=M.storeToRefs(an),Ul=M.useLoginState(M.pinia),{loginUserInfo:Nl}=M.storeToRefs(Ul),Vr=e.ref(720),er=e.ref(!1),Ur=e.ref(!1),Br=e.ref([]),Tr=e.ref(),gn=e.ref(!0),Sn=e.ref(!0);e.ref([]);const Cn=e.inject("contentRef");e.provide("contentRef",Cn),e.provide("getSuggestListForCell",Ku),e.provide("getSuggestLoadingForCell",(f,v)=>{const z=`${f==null?void 0:f.id}:${(v==null?void 0:v.prop)||(v==null?void 0:v.property)}`;return y.value.get(z)||!1}),e.watch(()=>{var f;return(f=Ce.value)==null?void 0:f.length},f=>{ue.total=f}),e.watch(()=>ce.value,async()=>{var v,z,L,H,T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la;if(((v=ce.value)==null?void 0:v.length)===0||!((z=d==null?void 0:d.itemData)!=null&&z.find(ol=>(ol==null?void 0:ol.key)==="columnPath"))||!((L=d==null?void 0:d.itemData)!=null&&L.find(ol=>(ol==null?void 0:ol.key)==="pageColumn")))return;let f=(ke=(K=(oe=(ie=(T=(H=d==null?void 0:d.itemData)==null?void 0:H.find(ol=>(ol==null?void 0:ol.key)==="pageColumn"))==null?void 0:T.contents)==null?void 0:ie.split("["))==null?void 0:oe[1])==null?void 0:K.split("]"))==null?void 0:ke[0];((ea=(Ue=(Je=(ge=d==null?void 0:d.itemData)==null?void 0:ge.find(ol=>(ol==null?void 0:ol.key)==="pageColumn"))==null?void 0:Je.contents)==null?void 0:Ue.split("["))==null?void 0:ea[0])+((Na=(ka=ce.value)==null?void 0:ka.find(ol=>(ol==null?void 0:ol.key)===f))==null?void 0:Na.value),(la=(Aa=d==null?void 0:d.itemData)==null?void 0:Aa.find(ol=>(ol==null?void 0:ol.key)==="pageGroup"))==null||la.contents,Zt(compData,d.allMapContents)},{deep:!0});const mn=f=>{var z,L,H,T,ie;const v=(L=(z=W.value)==null?void 0:z.filter(oe=>oe==null?void 0:oe.mainKey))==null?void 0:L.map(oe=>oe==null?void 0:oe.prop);if(v.length===0){const oe=(H=W.value)==null?void 0:H.map(K=>K==null?void 0:K.prop);return(T=oe==null?void 0:oe.map(K=>f==null?void 0:f[K]))==null?void 0:T.join("|")}return(ie=v==null?void 0:v.map(oe=>f==null?void 0:f[oe]))==null?void 0:ie.join("|")},On=f=>{var oe,K,ke,ge,Je;const v=(K=(oe=W.value)==null?void 0:oe.filter(Ue=>Ue==null?void 0:Ue.required))==null?void 0:K.map(Ue=>Ue==null?void 0:Ue.prop),z=[];if(f==null||f.forEach(Ue=>{v==null||v.forEach(ea=>{const ka=Ue[ea];(ka==null||ka==="")&&(z.includes(ea)||z.push(ea))})}),z.length>0)return Ja.ElMessage.warning(`请填写必填项:${z.join("、")}`);const L=new Map,H=new Map;(ke=Ce.value)==null||ke.forEach(Ue=>{const ea=mn(Ue);L.set(ea,Ue)}),f==null||f.forEach(Ue=>{const ea=mn(Ue);H.set(ea,Ue)});const T=f==null?void 0:f.filter(Ue=>L.has(mn(Ue))),ie=(ge=Ce.value)==null?void 0:ge.filter(Ue=>H.has(mn(Ue)));return(T==null?void 0:T.length)>0&&(J.columns=(Je=W.value)==null?void 0:Je.filter(Ue=>(Ue==null?void 0:Ue.label)!=="操作"),J.existRows=ie,J.tableData=T,J.show=!0),J.newRows=f==null?void 0:f.filter(Ue=>{const ea=mn(Ue);return!L.has(ea)}),J.newRows},rn=e.ref(""),Dn=e.ref(null),Vn=async()=>{var f,v,z,L,H,T;try{const ie=await M.quoteApi({related:[{menus:de.value,groups:d==null?void 0:d.compName}],platId:parseInt((f=Nl.value)==null?void 0:f.plat_id)});if(((v=ie==null?void 0:ie.data)==null?void 0:v.code)===200){Dn.value=(z=ie==null?void 0:ie.data)==null?void 0:z.result;const oe=(L=W.value)==null?void 0:L.map(ge=>(ge==null?void 0:ge.prop)||(ge==null?void 0:ge.label)),K=nn(oe,(H=ie==null?void 0:ie.data)==null?void 0:H.result),ke=K==null?void 0:K.flatMap(ge=>ge==null?void 0:ge.quote);(ke==null?void 0:ke.length)>0&&(rn.value=(T=ke==null?void 0:ke.map(ge=>ge==null?void 0:ge.menus))==null?void 0:T.join("、"))}}catch(ie){throw new Error(ie)}};function nn(f,v){var z;return(z=v.filter(L=>L.struct&&Array.isArray(L.struct)?L.struct.some(H=>H.words&&Array.isArray(H.words)?H.words.some(T=>f.includes(T)):!1):!1))==null?void 0:z.map(L=>{const H={...L};return H.struct&&Array.isArray(H.struct)&&(H.struct=H.struct.filter(T=>T.words&&Array.isArray(T.words)?T.words.some(ie=>f.includes(ie)):!1)),H})}const Fn=async(f,v)=>{var z,L;try{Dn.value||await Vn();const H=v==null?void 0:v.map(ie=>{const oe=Object.keys(ie),K={};return oe.forEach((ke,ge)=>{K[f[ge]]=ie[ke]}),K}),T=On(H);if(!T||(T==null?void 0:T.length)===0)return;J.show||await He(T)}catch(H){throw Ja.ElMessage.error("数据导入处理失败"),await M.pageBatchAddApi({platId:parseInt((z=Nl==null?void 0:Nl.value)==null?void 0:z.plat_id),changeContents:[{tableName:"log",tableContents:[{id:"1",request_method:"Post",request_url:"",request_param:JSON.stringify(t1),request_result:JSON.stringify(H),is_delete:!1,request_table:(L=d==null?void 0:d.related)==null?void 0:L.find(T=>T==null?void 0:T.includes("content")),request_type:"error"}]}]}),new Error(H)}},zr=async f=>{var T,ie,oe,K,ke,ge,Je;let v=ae.value;v!=null&&v.find(Ue=>(f==null?void 0:f.key)===(Ue==null?void 0:Ue.key))&&(v=v==null?void 0:v.filter(Ue=>(f==null?void 0:f.key)!==(Ue==null?void 0:Ue.key))),v.push({key:f==null?void 0:f.key,value:[(ie=f==null?void 0:f.value)==null?void 0:ie[((T=f==null?void 0:f.value)==null?void 0:T.length)-1]]});let z=ye.value;z=z==null?void 0:z.map(Ue=>{var ea,ka;return(Ue==null?void 0:Ue.type)==="Select"&&(f==null?void 0:f.key)===(Ue==null?void 0:Ue.prop)&&Array.isArray(Ue.value)&&(ea=Ue.value)!=null&&ea.every(Na=>typeof Na=="string")&&(Ue.selectValue=(ka=v==null?void 0:v.find(Na=>(Na==null?void 0:Na.key)===(Ue==null?void 0:Ue.prop)))==null?void 0:ka.value),Ue});let L=(K=(oe=z==null?void 0:z.find(Ue=>(Ue==null?void 0:Ue.prop)===(f==null?void 0:f.key)))==null?void 0:oe.optionUrl)==null?void 0:K.menuId,H=z==null?void 0:z.find(Ue=>(Ue==null?void 0:Ue.prop)===(f==null?void 0:f.key));if(L){let Ue=await At(H==null?void 0:H.optionUrl,L),ea,ka=X.value,Na=(Je=(ge=(ke=ye.value)==null?void 0:ke.find(Aa=>{var la;return(la=H==null?void 0:H.optionUrl)==null?void 0:la.menuId}))==null?void 0:ge.selectValue)==null?void 0:Je[0];if(Ue==null||Ue.forEach(Aa=>{var la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne;if(L){let Q=(ol=(la=ye.value)==null?void 0:la.find(ha=>{var B,za;return((B=H==null?void 0:H.optionUrl)==null?void 0:B.menuId)===((za=ha==null?void 0:ha.optionUrl)==null?void 0:za.menuId)}))==null?void 0:ol.prop,je=(tl=(xa=z==null?void 0:z.find(ha=>(ha==null?void 0:ha.prop)===Q))==null?void 0:xa.selectValue)==null?void 0:tl[0];Q!=null&&Q.includes("·")&&(Q=(be=Q==null?void 0:Q.split("·"))==null?void 0:be[0],je=(Ia=(Ya=(ba=f==null?void 0:f.value)==null?void 0:ba[((Va=f==null?void 0:f.value)==null?void 0:Va.length)-1])==null?void 0:Ya.split(" "))==null?void 0:Ia[0]),ka!=null&&ka.find(ha=>(ha==null?void 0:ha.value)===Na)?ea=(Ne=ka==null?void 0:ka.find(ha=>(ha==null?void 0:ha.value)===Na))==null?void 0:Ne.objectValue:Aa[Q]===je&&(ea=Aa)}}),ea){let Aa=z;Aa=Aa==null?void 0:Aa.map(la=>{var ol,xa,tl,be,Va,ba;return L&&(ea!=null&&ea[la==null?void 0:la.prop])&&ma.value==="新增"&&(la==null?void 0:la.prop)!==(H==null?void 0:H.prop)?la.value=(ea==null?void 0:ea[la==null?void 0:la.prop])||(ea==null?void 0:ea[(be=(tl=(xa=(ol=la==null?void 0:la.optionUrl)==null?void 0:ol.groupSelect)==null?void 0:xa[1])==null?void 0:tl.replaceAll("[",""))==null?void 0:be.replaceAll("]","")]):la.value=(ba=(Va=ye.value)==null?void 0:Va.find(Ya=>(Ya==null?void 0:Ya.prop)===(la==null?void 0:la.prop)))==null?void 0:ba.value,la}),ye.value=Aa}}ae.value=v},An=async(f,v)=>{var z,L,H,T,ie;if((z=f==null?void 0:f.toString())!=null&&z.includes(".txt")||(L=f==null?void 0:f.toString())!=null&&L.includes(".cpt")||(H=f==null?void 0:f.toString())!=null&&H.includes(".cyd")){const oe=await Ja.axios.get(f,{responseType:"blob",headers:{"Content-Type":"application/json"}}),K=new Blob([oe.data],{type:"application/octet-stream;charset=UTF-8"});let ke=URL.createObjectURL(K);Me.value=[{name:(ie=f==null?void 0:f.split("/"))==null?void 0:ie[((T=f==null?void 0:f.split("/"))==null?void 0:T.length)-1],blobUrl:ke}],Ke.value=!0}else Array.isArray(v)&&(v==null?void 0:v.length)>0&&U("routeUrl",{isEdit:!1,routerUrl:v})};e.onBeforeUnmount(()=>{Sn.value=!1;let f=Jl.value;Jl.value=f+1});const Tn=e.reactive({prop:"",order:null}),Po=e.computed(()=>{const f=(Ce.value??[]).slice(),v=Tn.prop||ve.prop,z=Tn.order||ve.order;if(!v||!z)return f;const L=z==="ascending",H=ie=>{if(v)return ie&&Object.prototype.hasOwnProperty.call(ie,v)?ie[v]:v.includes(".")?v.split(".").reduce((oe,K)=>oe==null?oe:oe[K],ie):ie==null?void 0:ie[v]},T=ie=>{if(ie==null)return{ok:!1,value:NaN};if(typeof ie=="number")return{ok:Number.isFinite(ie),value:ie};const oe=String(ie).trim();if(oe==="")return{ok:!1,value:NaN};const K=oe.replace(/[,\s]/g,"");if(!/^[+-]?(\d+\.?\d*|\.\d+)$/.test(K))return{ok:!1,value:NaN};const ke=Number(K);return{ok:Number.isFinite(ke),value:ke}};return f.sort((ie,oe)=>{const K=H(ie),ke=H(oe);if(K==null&&ke==null)return 0;if(K==null)return L?-1:1;if(ke==null)return L?1:-1;const ge=T(K),Je=T(ke);if(ge.ok&&Je.ok)return L?ge.value-Je.value:Je.value-ge.value;const Ue=be=>{if(be==null)return{ok:!1,value:NaN};const Va=String(be).trim();if(Va==="")return{ok:!1,value:NaN};const ba=Va.match(/^(-)?(\d+):(\d{1,2}):(\d{1,2})$/);if(!ba)return{ok:!1,value:NaN};const Ya=ba[1]?-1:1,Ia=Number(ba[2]),Ne=Number(ba[3]),Q=Number(ba[4]);return[Ia,Ne,Q].some(je=>Number.isNaN(je))?{ok:!1,value:NaN}:Ne>=60||Q>=60?{ok:!1,value:NaN}:{ok:!0,value:Ya*(Ia*3600+Ne*60+Q)}},ea=Ue(K),ka=Ue(ke);if(ea.ok&&ka.ok)return L?ea.value-ka.value:ka.value-ea.value;const Na=new Date(K).getTime(),Aa=new Date(ke).getTime(),la=!Number.isNaN(Na),ol=!Number.isNaN(Aa);if(la&&ol)return L?Na-Aa:Aa-Na;const xa=String(K),tl=String(ke);return L?xa.localeCompare(tl):tl.localeCompare(xa)})}),Ln=e.computed(()=>{var z;const f=(ue.currentPage-1)*ue.pageSize,v=f+ue.pageSize;return U("getSliceContLength",ue),(z=Po.value)==null?void 0:z.slice(f,v)}),jo=f=>{ue.currentPage=f,U("getSliceContLength",ue)},Ho=f=>{var L;ue.pageSize=f;const v=((L=Ce.value)==null?void 0:L.length)??0,z=f>0?Math.ceil(v/f):1;ue.currentPage>z&&(ue.currentPage=z||1,Ja.ElMessage.warning("当前页超出范围,已自动跳转到最后一页")),U("getSliceContLength",ue)},Uo=({prop:f,order:v})=>{Tn.prop=f,Tn.order=v,ue.currentPage=1};function lo(f){const v=[];function z(L,H=""){L.forEach(T=>{T.children&&T.children.length>0?z(T.children,T.prop):v.push(T.prop)})}return z(f),v}const ro=(f,v)=>{var oe,K,ke,ge;let z=(K=(oe=W.value)==null?void 0:oe.map(Je=>Je==null?void 0:Je.prop))==null?void 0:K.filter(Je=>Je!=="operate");((ke=W.value)==null?void 0:ke.some(Je=>{var Ue;return((Ue=Je==null?void 0:Je.children)==null?void 0:Ue.length)>0}))&&(z=lo((ge=W.value)==null?void 0:ge.filter(Je=>(Je==null?void 0:Je.prop)!=="operate")));let H;if(H=(f==null?void 0:f.length)===(z==null?void 0:z.length)?f:f.slice(0,z==null?void 0:z.length),!(H==null?void 0:H.every(Je=>z==null?void 0:z.find(Ue=>Je===Ue))))return Ja.ElMessage.error("导入的数据表头不匹配");Fn(H,v)},un=(f,v)=>{var H;const z=f==null?void 0:f.filter(T=>T!=="序号"),L=v==null?void 0:v.map(T=>{const ie=Object.entries(T);return ie.shift(),Object.fromEntries(ie)});Ge.setRefreshCurStructure(!1),((H=W.value)==null?void 0:H.length)===0||ro(z,L)},qo=(f,v,z,L)=>{const H=[],T=[],ie=ke=>Object.keys(ke).length;for(const ke in f)if(f[ke]!==void 0){const ge=f[ke],Je=[];for(const[Ue,ea]of Object.entries(ge))Je.push(ea),T.length<ie(ge)&&T.push(Ue);H.push(Je)}H.unshift(T);const oe=le.utils.aoa_to_sheet(H),K=le.utils.book_new();le.utils.book_append_sheet(K,oe,L),le.writeFileSync(K,`${v}.xlsx`),Br.value=[]},no=async(f,v,z,L=!1,H)=>{try{Ge.setRefreshCurStructure(!1)}catch(T){Ja.ElMessage.error(T)}},Wo=async(f,v)=>{await no()},Go=async(f,v)=>{await no("columnType",v,f,!1)},Ko=async({newRow:f,targetIndex:v})=>{var H;if(!Ca(d.config,{type:ya.TABLE}))return;const L=(ue.currentPage-1)*ue.pageSize+(v??0);f._isTemp=!0;try{(f.sort===void 0||f.sort===null||String(f.sort).trim()==="")&&(f.sort=ui(L,Ce.value||[]))}catch{}Ce.value.splice(L,0,f),await e.nextTick(),p.value.has(f.id)||p.value.set(f.id,M.cloneDeep(f)),Ce.value=(H=Ce.value)==null?void 0:H.map(T=>({...T,tableEditType:(T==null?void 0:T.id)===f.id?"edit":(T==null?void 0:T.tableEditType)??"text"})),o.value.add(f.id),er.value=!0},Yo=(f,v,z,L=[])=>(!Array.isArray(v)||v.length===0||v.forEach(H=>{const T=H==null?void 0:H.prop;if(!T)return;let ie=f==null?void 0:f[T];if(ie==null||String(ie).trim()==="")return;ie=String(ie);const oe=new Set([...(Array.isArray(z)?z:[]).filter(ge=>(ge==null?void 0:ge.id)!==(f==null?void 0:f.id)).map(ge=>ge==null?void 0:ge[T]).filter(ge=>ge!=null).map(ge=>String(ge)),...(Array.isArray(L)?L:[]).map(ge=>ge==null?void 0:ge[T]).filter(ge=>ge!=null).map(ge=>String(ge))]);if(!oe.has(ie))return;let K=1,ke="";for(;ke=`${ie}(${K})`,!!oe.has(ke);)K++;f[T]=ke}),f),Vi=async()=>{var H,T,ie,oe,K,ke,ge,Je;const f=Array.from(o.value||[]);if(f.length===0)return;const v=(T=le.getColumnChild((H=M.cloneDeep(W.value))==null?void 0:H.filter(Ue=>(Ue==null?void 0:Ue.label)!=="操作")))==null?void 0:T.filter(Ue=>(Ue==null?void 0:Ue.required)===!0);if((v==null?void 0:v.length)>0)for(let Ue=0;Ue<f.length;Ue++){const ea=f[Ue],ka=(ie=Ce.value)==null?void 0:ie.find(Na=>(Na==null?void 0:Na.id)===ea);if(ka)for(let Na=0;Na<v.length;Na++){const Aa=v[Na],la=Aa==null?void 0:Aa.prop,ol=(Aa==null?void 0:Aa.label)??la,xa=ka==null?void 0:ka[la];if(xa===""||xa===null||xa===void 0||Array.isArray(xa)&&xa.length===0){Ja.ElMessage.error(`${ol}不能为空`);let be={};be.id=ka==null?void 0:ka.id;const Va={fixContent:[be],buttonName:"修改",relatedContents:d==null?void 0:d.related,name:d==null?void 0:d.compName,columns:W.value};U("change",Va);return}}}const z=[],L=[];if(f.forEach(Ue=>{var ol;const ea=(ol=Ce.value)==null?void 0:ol.find(xa=>(xa==null?void 0:xa.id)===Ue);if(!ea)return;if(ea!=null&&ea._isTemp){const tl=(le.getAllLeafNodes(W.value)||[]).filter(Ne=>(Ne==null?void 0:Ne.mainKey)===!0||(Ne==null?void 0:Ne.isMainKey)===!0),be=Ce.value.findIndex(Ne=>(Ne==null?void 0:Ne.id)===Ue),Va=be>=0?be+1:Ce.value.length+1;Yo(ea,tl,Ce.value,z);const ba={id:Va.toString()};(ea==null?void 0:ea.sort)!==void 0&&(ea==null?void 0:ea.sort)!==null&&String(ea.sort).trim()!==""?ba.sort=String(ea.sort):ba.sort=ui(be>=0?be:Ce.value.length-1,Ce.value||[]),(le.getAllLeafNodes(W.value)||[]).filter(Ne=>(Ne==null?void 0:Ne.type)!=="operate"&&(Ne==null?void 0:Ne.label)!=="操作"&&(Ne==null?void 0:Ne.prop)!=="operate").forEach(Ne=>{const Q=Ne==null?void 0:Ne.prop;if(Q){const je=ea[Q];je!==void 0?ba[Q]=je??"":ba[Q]=""}}),z.push(ba);return}const Na=(le.getAllLeafNodes(W.value)||[]).filter(xa=>(xa==null?void 0:xa.type)!=="operate"&&(xa==null?void 0:xa.label)!=="操作"&&(xa==null?void 0:xa.prop)!=="operate"),Aa=new Set(Na.map(xa=>xa==null?void 0:xa.prop).filter(Boolean)),la={};for(const xa of Aa)Object.prototype.hasOwnProperty.call(ea,xa)&&(la[xa]=ea[xa]);L.push({id:ea.id,value:{tableData:la}})}),Ge.setTableLoading(d==null?void 0:d.index),L.length>0){const Ue=L.map(ka=>{const Na={id:ka.id,...ka.value.tableData};return delete Na._isOCRRow,delete Na._ocrTableId,delete Na._isTemp,delete Na.tableEditType,delete Na.index,Na}),ea=[{tableName:((oe=d==null?void 0:d.related)==null?void 0:oe.find(ka=>ka==null?void 0:ka.includes("content")))??"content_"+(d==null?void 0:d.index),tableContents:Ue}];try{await M.pageBatchUpdateApi({platId:parseInt((K=Nl.value)==null?void 0:K.plat_id),changeContents:ea})}catch(ka){Ja.ElMessage.error(((ge=(ke=ka==null?void 0:ka.response)==null?void 0:ke.data)==null?void 0:ge.message)||(ka==null?void 0:ka.message)||"保存失败"),Ge.setTableLoading(!1);return}}if(z.length>0){const Ue={fixContent:z,buttonName:"新增",relatedContents:d==null?void 0:d.related,name:d==null?void 0:d.compName,columns:W.value};U("change",Ue)}Ja.ElMessage.success("保存成功"),o.value.clear(),p.value.clear(),Ce.value=(Je=Ce.value)==null?void 0:Je.map(Ue=>({...Ue,tableEditType:"text"})),er.value=!1,Ge.setRefreshCurStructure(!0)},Jo=()=>{var v;const f=Array.from(o.value||[]);if(f.length===0){er.value=!1;return}f.forEach(z=>{var T,ie;const L=p.value.get(z),H=(T=Ce.value)==null?void 0:T.find(oe=>(oe==null?void 0:oe.id)===z);if(H!=null&&H._isTemp){Ce.value=Ce.value.filter(oe=>(oe==null?void 0:oe.id)!==H.id);return}if(L){const oe=(ie=Ce.value)==null?void 0:ie.findIndex(K=>(K==null?void 0:K.id)===z);oe!==-1&&(Ce.value[oe]={...Ce.value[oe],...L})}}),o.value.clear(),p.value.clear(),Ce.value=(v=Ce.value)==null?void 0:v.map(z=>({...z,tableEditType:"text"})),er.value=!1},ki=e.ref(!1),si=async f=>{var H,T,ie,oe;if(!er.value||f!=null&&f.isComposing||(f==null?void 0:f.key)!=="Enter")return;const v=f==null?void 0:f.target;if(((T=(H=v==null?void 0:v.tagName)==null?void 0:H.toLowerCase)==null?void 0:T.call(H))==="textarea")return;const L=document.getElementById("excel-table");L&&!L.contains(v)||((ie=v==null?void 0:v.blur)==null||ie.call(v),(oe=f.preventDefault)==null||oe.call(f),await e.nextTick(),await Pn())},Pn=async()=>{if(ee.value){er.value=!1;return}if(!ki.value){ki.value=!0;try{Array.from(o.value||[]).length>0?await Vi():er.value=!1}finally{Promise.resolve().then(()=>{ki.value=!1})}}},xi=f=>{Br.value=f},Xo=(f,v)=>{Tr.value===v?gn.value=!1:gn.value=!0,Tr.value=v==null?void 0:v.changeProp},io=f=>{if(!f)return;const{item:v,value:z}=f,L=ye.value.find(H=>H.prop==v.prop);L&&L.contents.push({label:z,value:z})},Qn=e.computed(()=>{var z,L,H;const f=(z=W.value)==null?void 0:z.some(T=>T==null?void 0:T.filterable);return document.documentElement.style.setProperty("--ssTable-header-filter-display",f?"inline-block":"none"),(H=(L=W.value)==null?void 0:L.filter(T=>(T==null?void 0:T.label)!=="操作"))==null?void 0:H.map(T=>({...T,filterable:!!(T!=null&&T.filterable),showSummary:!!(T!=null&&T.showSummary),operable:!!(T!=null&&T.operable),fixed:T==null?void 0:T.fixed}))}),Fi=async(f,v,z)=>{const L=M.cloneDeep(W.value);await e.nextTick();const H=L==null?void 0:L.map(ie=>(z==null?void 0:z.label)===(ie==null?void 0:ie.label)?{...ie,[v]:f}:ie),T=Wn(H);await As(d.index,T),W.value=H,Z.value=T},Wn=f=>{var H;const v=f||[];return((H=le.getAllLeafNodes(v)||[])==null?void 0:H.filter(T=>(T==null?void 0:T.prop)&&(T==null?void 0:T.type)!=="operate"&&(T==null?void 0:T.label)!=="操作"&&(T==null?void 0:T.prop)!=="operate")).map(T=>{const{prop:ie}=T;return U0(ie,T)})},Zo=async f=>{let v=await W0(d.index);v||(v=Wn(f)),Z.value=v},Qo=async(f,v)=>{const z=M.cloneDeep(W.value),L=ie=>Array.isArray(ie)?ie.map(oe=>{const K=Array.isArray(oe==null?void 0:oe.children)&&oe.children.length>0,ke={...oe};return(ke==null?void 0:ke.prop)==="operate"||(ke==null?void 0:ke.label)==="操作"||(ke==null?void 0:ke.type)==="operate"?(ke.sortable=!1,ke.filterable=!1,ke.operable=!1):ke.sortable=K?!1:!!f,K&&(ke.children=L(ke.children)),ke}):ie,H=L(z),T=Wn(H);await As(d.index,T),W.value=H,Z.value=T,await e.nextTick(),Jl.value=Jl.value+1},et=()=>{Qe.value=!1},at=f=>{U("clickTrigger",f)},oo=async f=>{var T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa;const v=f==null?void 0:f.row,z=f==null?void 0:f.rowData,L=f==null?void 0:f.suffix;if((T=v==null?void 0:v.toString())!=null&&T.includes(".urdf")||f!=null&&f.isUrdf||L!=null&&L.includes(".urdf")){if(v.includes(",")){Ja.ElMessage.error("当前版本仅允许单个urdf预览!");return}if(G(v)){const be={files:[qe(v)],data:{}};_e(be);return}Be.value=[{url:v,extension:we(v)}],N.value=!0,se.value={data:M.cloneDeep(z)},te.value=!0;return}let H=[];if((ie=v==null?void 0:v.toString())!=null&&ie.includes(".stl")||(oe=v==null?void 0:v.toString())!=null&&oe.includes(".STL")||(K=v==null?void 0:v.toString())!=null&&K.includes(".obj")||(ke=v==null?void 0:v.toString())!=null&&ke.includes(".mtl")){const tl=(ge=v==null?void 0:v.toString())==null?void 0:ge.split(","),be=ra(tl),Va=be==null?void 0:be[0];if(G(Va==null?void 0:Va.extension)){_e({files:be,data:{}});return}Be.value=be,N.value=!1,te.value=!0;return}if((Je=v==null?void 0:v.toString())!=null&&Je.includes(".stl")||(Ue=v==null?void 0:v.toString())!=null&&Ue.includes(".STL")||(ea=v==null?void 0:v.toString())!=null&&ea.includes(".obj")||(ka=v==null?void 0:v.toString())!=null&&ka.includes(".mtl")||L!=null&&L.includes(".stl")||L!=null&&L.includes(".STL")||L!=null&&L.includes(".obj")||L!=null&&L.includes(".mtl")){let tl,be=[],Va={};if(Array.isArray(v)?tl=v:tl=v==null?void 0:v.split(","),tl==null||tl.forEach(ba=>{ba.includes(".mtl")?be.push(ba):Va.blob=Va.blob?Va.blob+","+ba:ba}),(be==null?void 0:be.length)>0&&(Va.mtlBlobs=be),L&&(Va.suffix=L),(Aa=(Na=Object.values(Va))==null?void 0:Na[0])!=null&&Aa.includes("http:"))H.push(Va);else{const ba=new Blob([Va.blob],{type:"application/octet-stream;charset=UTF-8"});let Ya=URL.createObjectURL(ba),Ia="";(la=v==null?void 0:v.split("/"))==null||la.forEach((Ne,Q)=>{var je;Q===((je=v==null?void 0:v.split("/"))==null?void 0:je.length)-1&&(Ia=Ne)}),(ol=Va.blob)!=null&&ol.includes(".stl")&&(Ia=(Ia==null?void 0:Ia.replaceAll(">",""))+".urdf"),Me.value=[{name:Ia,blobUrl:Ya}],Ke.value=!0}}else{const tl=await Ja.axios.get(v,{responseType:"blob",headers:{"Content-Type":"application/json"}}),be=new Blob([tl.data],{type:"application/octet-stream;charset=UTF-8"});let Va=URL.createObjectURL(be),ba="";if((xa=v==null?void 0:v.split("/"))==null||xa.forEach((Ya,Ia)=>{var Ne;Ia===((Ne=v==null?void 0:v.split("/"))==null?void 0:Ne.length)-1&&(ba=Ya)}),G(ba)){const Ya=fe(ba),Ia=qe(v);_e({files:[Ia],data:{trackFileType:Ya}});return}Me.value=[{name:ba,blobUrl:Va}],Ke.value=!0}(H==null?void 0:H.length)>0&&n.setBlobUrls(H)},ci=f=>{var L,H,T,ie;if(f!=null&&f.downloadUrl)return f==null?void 0:f.name;const v=(ie=(L=f==null?void 0:f.url)==null?void 0:L.split("."))==null?void 0:ie[((T=(H=f==null?void 0:f.url)==null?void 0:H.split("."))==null?void 0:T.length)-1];return(f==null?void 0:f.name)+"."+v},wi=f=>{if(!f)return"未知文件";try{const L=ci(f);if(typeof L=="string"&&L.includes("."))return L}catch{}const v=(f==null?void 0:f.fileName)||(f==null?void 0:f.name)||"未知文件",z=(f==null?void 0:f.suffix)||"";return v.includes(".")?v:`${v}${z}`},to=f=>{if(f==null||typeof f=="number"||typeof f!="string")return f;const v=f.match(/^(\d+)\_(\d+)$/);if(!v)return f;const z=Number(v[1]),L=Number(v[2]);return!Number.isFinite(z)||!Number.isFinite(L)?f:String(z*1e3+L)},jn=f=>{if(f==null)return null;const v=String(f).trim();if(!v)return null;const z=Number(v);return Number.isFinite(z)?z:null},lt=f=>{if(f==null)return null;const v=String(f).trim();if(!v)return null;if(/^\d+$/.test(v)){const H=Number(v);return Number.isFinite(H)?v.length<=10?H*1e3:H:null}const z=v.includes("T")?v:v.replace(" ","T"),L=Date.parse(z);return Number.isFinite(L)?L:null},_i=(f,v=[])=>{const z=Array.isArray(f)?f.slice():[];if(z.length<=1)return z;const L=new Map((v||[]).map((ie,oe)=>[String(ie),oe])),H=z.some(ie=>jn(ie==null?void 0:ie.sort)!==null),T=z.map((ie,oe)=>({r:ie,idx:oe,id:String((ie==null?void 0:ie.id)??""),sortVal:jn(ie==null?void 0:ie.sort),createTimeMs:lt(ie==null?void 0:ie.create_time),prevIdx:L.has(String(ie==null?void 0:ie.id))?L.get(String(ie==null?void 0:ie.id)):Number.POSITIVE_INFINITY}));return T.sort((ie,oe)=>{if(H){const ge=ie.sortVal,Je=oe.sortVal;if(ge===null&&Je!==null)return 1;if(ge!==null&&Je===null)return-1;if(ge!==null&&Je!==null&&ge!==Je)return ge-Je}const K=ie.createTimeMs,ke=oe.createTimeMs;return K!==null&&ke!==null&&K!==ke?ke-K:K!==null&&ke===null?-1:K===null&&ke!==null?1:ie.prevIdx!==oe.prevIdx?ie.prevIdx-oe.prevIdx:ie.idx-oe.idx}),T.map(ie=>ie.r)},ui=(f,v=[])=>{const z=v==null?void 0:v[f-1],L=v==null?void 0:v[f],H=jn(z==null?void 0:z.sort),T=jn(L==null?void 0:L.sort);let ie=null;H!==null&&T!==null&&T>H?ie=(H+T)/2:H!==null?ie=H+1:T!==null?ie=Math.max(T-1,0):ie=(f??0)+1;const oe=Number(ie.toFixed(6));return String(Number.isFinite(oe)?oe:ie)},rt=async f=>{let v=null,z=null;if(f!=null&&f.id){const H=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});try{const T=await M.platformDownloadFile(f);v=URL.createObjectURL(T.data),z=wi(f)}finally{H.close()}}else if(f!=null&&f.downloadUrl){const H=await Si(),T=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),ie=await Ja.axios.post(f==null?void 0:f.url,null,{responseType:"blob",headers:{Authorization:H,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}).finally(()=>{T.close()}),oe=new Blob([ie.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(oe),z=f==null?void 0:f.name}else{const H=await M.platformDownloadFile({url:f==null?void 0:f.url});!f.url.toUpperCase().includes(".OBJ")&&!f.url.toUpperCase().includes(".STL")&&!f.url.toUpperCase().includes(".MTL")&&!f.url.toUpperCase().includes(".URDF")?(v=URL.createObjectURL(H.data),z=ci(f)):v=f==null?void 0:f.url}if(G(v)){const H={row:`${v}`,suffix:we(z)};oo(H);return}const L={name:z,blobUrl:v};Me.value=[L],Ke.value=!0},so=async f=>{let v=null,z=null;if(f!=null&&f.id){const T=await M.platformDownloadFile(f);v=URL.createObjectURL(T.data),z=wi(f)}else if(f!=null&&f.downloadUrl){const T=await Si(),ie=await Ja.axios.post(f==null?void 0:f.url,null,{responseType:"blob",headers:{Authorization:T,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}),oe=new Blob([ie.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(oe),z=f==null?void 0:f.name}else{const T=await M.platformDownloadFile({url:f==null?void 0:f.url});v=URL.createObjectURL(T.data),z=ci(f)}const L={name:z,blobUrl:v},H=document.createElement("a");H.href=L.blobUrl,H.download=L.name,H.style.display="none",document.body.appendChild(H),H.click(),setTimeout(()=>{document.body.removeChild(H)},100)},di=(f,v)=>{var L;if(Object.values(v).length===0)return;let z=f;return Object.values(v).find(H=>{var T,ie,oe;return((T=H==null?void 0:H.toString())==null?void 0:T.includes(".txt"))||((ie=H==null?void 0:H.toString())==null?void 0:ie.includes(".cpt"))||((oe=H==null?void 0:H.toString())==null?void 0:oe.includes(".obj"))})?z=[...f,$e.value]:(L=d==null?void 0:d.config)!=null&&L.allowMove&&(z=[...f,{label:"迁移"}]),z},Hn=()=>{j.value=!0},co=e.ref([]),Pi=async(f,v,z=!1)=>{var ie,oe,K,ke;if(!f)return;if(z){Ce.value=[...Ta.value.values()].filter(ge=>Object.values(ge).some(Je=>typeof Je=="string"?Je==null?void 0:Je.toLowerCase().includes(v==null?void 0:v.toLowerCase()):!1));return}let L={};for(let ge in f)(f==null?void 0:f[ge])!==""&&(L[ge]=f==null?void 0:f[ge]);if(JSON.stringify(L)==="{}"){Ce.value=Array.from(((ie=Ta.value)==null?void 0:ie.values())??[]);return}let H=(oe=d==null?void 0:d.related)==null?void 0:oe.find(ge=>ge==null?void 0:ge.includes("content_")),T=await M.getFillFind({platId:parseInt((K=Nl==null?void 0:Nl.value)==null?void 0:K.plat_id),tableName:H,params:L});T=(ke=T==null?void 0:T.data)==null?void 0:ke.result,Ce.value=T,Ge.setTableLoading(!1)},nt=e.computed(()=>{var v,z;return((z=(v=d==null?void 0:d.itemData)==null?void 0:v.find(L=>(L==null?void 0:L.key)==="isEdit"))==null?void 0:z.contents)??!0}),it=async f=>{var H,T,ie,oe,K,ke;if(!Ca(d.config,{type:ya.TABLE})||!(((T=(H=d==null?void 0:d.itemData)==null?void 0:H.find(ge=>(ge==null?void 0:ge.key)==="isEdit"))==null?void 0:T.contents)??!0))return;let z=(oe=(ie=u.value)==null?void 0:ie.find(ge=>{var Je;return(Je=ge==null?void 0:ge.key)==null?void 0:Je.includes("@EditRead")}))==null?void 0:oe.content;if((z==null?void 0:z.length)>0){let ge=Bs(z,f);if((ge==null?void 0:ge.length)>0)return}if(!f)return;((K=Array.from(o.value))==null?void 0:K.length)>0&&await Vi();const L=f==null?void 0:f.id;L!=null&&(o.value.clear(),p.value.clear(),p.value.has(L)||p.value.set(L,M.cloneDeep(f)),Ce.value=(ke=Ce.value)==null?void 0:ke.map(ge=>({...ge,tableEditType:(ge==null?void 0:ge.id)===L?"edit":"text"})),o.value.add(L),er.value=!0)},uo=async(f,v,z,L)=>{L!=null&&L.isExistChild&&U("clickMainKey",f,z,W.value)},ot=()=>{Ke.value=!1},tt=f=>{U("rowClick",f)};e.watch(()=>d.changedContent,()=>{var z,L;if(!d.changedContent)return;let f=(z=Ce.value)==null?void 0:z.map(H=>{var T;return H.id===((T=d.changedContent)==null?void 0:T.id)&&(H={...d.changedContent,id:d.changedContent.newId?d.changedContent.newId:d.changedContent.id},delete H.newId),H});const v=(L=d.itemData)==null?void 0:L.map(H=>((H==null?void 0:H.key)==="tableContents"&&(H.contents=f),H));Ce.value=f,U("contentChange",{contents:v,index:d.index}),U("change",{content:f,index:d==null?void 0:d.index,buttonName:"",id:d==null?void 0:d.index})},{deep:!0,immediate:!0});const st=()=>{},ct=async()=>{const f=de.value,v=sessionStorage.getItem("systemKey"),z=await le.getItemData(f,v,""),L=(z==null?void 0:z.find(oe=>(oe==null?void 0:oe.name)==="方法明细"))||(z==null?void 0:z[0]),H=(L==null?void 0:L.compData)||[],T=H==null?void 0:H.find(oe=>{const K=oe==null?void 0:oe.key;return K==="formContent"||K==="tableContents"});return T==null?void 0:T.contents},Si=async()=>{const v=Ja.Local.get("access-token");return v?`Bearer ${v}`:""},ut=async(f,{token:v,inputData:z}={})=>await Ja.axios.post(f,z,{headers:{Authorization:v}}).catch(H=>(Le.setImportLoading(!1),Promise.reject(H))),dt=f=>{var L;let v={};const z=[];return v.form={},(L=M.cloneDeep(f))==null||L.forEach((H,T)=>{var ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa;if((H==null?void 0:H.comp)==="Table"){(oe=(ie=H==null?void 0:H.compData)==null?void 0:ie.find(ba=>(ba==null?void 0:ba.key)==="header"))==null||oe.contents;let tl=(ge=(ke=(K=H==null?void 0:H.compData)==null?void 0:K.find(ba=>(ba==null?void 0:ba.key)==="tableContents"))==null?void 0:ke.contents)==null?void 0:ge.map(ba=>ba.slice(1));(Na=(ka=(ea=(Ue=(Je=H==null?void 0:H.compData)==null?void 0:Je.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:Ue.contents)==null?void 0:ea[0])==null?void 0:ka[0])==null||Na.label;let be=(la=(Aa=H==null?void 0:H.compData)==null?void 0:Aa.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:la.contents,Va=[];tl==null||tl.forEach(ba=>{let Ya=[];ba==null||ba.forEach((Ia,Ne)=>{var je;let Q={};((je=be[Ne])==null?void 0:je.label)!=="操作"&&(Q[be[Ne].label]=Ia,Ya.push(Q))}),Va.push(Ya)}),v[H.name]=Va}else{const tl=(xa=(ol=H.compData)==null?void 0:ol.find(be=>(be==null?void 0:be.key)==="formContent"))==null?void 0:xa.contents;tl==null||tl.forEach(be=>{var Va,ba;if(be.prop!==""){let Ya=be==null?void 0:be.value;Array.isArray(Ya)?Ya=((Va=Ya==null?void 0:Ya[0])==null?void 0:Va.oldUrl)||"http://222.92.178.198:62001/"+((ba=Ya==null?void 0:Ya[0])==null?void 0:ba.url):Ya=Ya.toString(),be={key:(be==null?void 0:be.prop)??(be==null?void 0:be.label),value:Ya},z.push(be)}})}}),v.form=le.getFormContents(z),v},s=f=>{const v=[],z=L=>{L&&typeof L=="object"&&!Array.isArray(L)?Object.values(L).forEach(z):v.push(L)};return z(f),v},t=async(f,v,z)=>{var be,Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl;Le.setImportLoading(!0),Ge.setFreshContent(!1);let L=await ct().catch(qa=>(Le.setImportLoading(!1),Promise.reject(qa)));L=L==null?void 0:L.filter(qa=>{var Tl;return((Tl=qa==null?void 0:qa.find(La=>La==null?void 0:La.id))==null?void 0:Tl.id)===(v==null?void 0:v.id)});let H=le.getEqualChild([(be=W.value)==null?void 0:be.filter(qa=>(qa==null?void 0:qa.label)!=="操作")]);const T=(ba=(Va=le.tableToForm(L,H))==null?void 0:Va[0])==null?void 0:ba.find(qa=>{const Tl=qa==null?void 0:qa.key;return Tl==="Interface"||Tl==="方法体"}),ie=T==null?void 0:T.value;if(!ie){console.log("未搜索到isMain, 缺少算法执行接口"),Le.setImportLoading(!1);return}const oe=W.value?le.getEqualChild([W.value]):[],K=oe.find(qa=>{const Tl=qa==null?void 0:qa.prop;return Tl==="Input1"||Tl==="输入数据.输入1"||Tl==="样本输入数据"}),ke=K==null?void 0:K.prop;let ge=v==null?void 0:v[ke];const Je=await Si().catch(qa=>(Le.setImportLoading(!1),Promise.reject(qa)));let Ue=!0,ea="";(Ya=W.value)==null||Ya.forEach(qa=>{(qa==null?void 0:qa.prop)===ke&&(Ue=!!(qa!=null&&qa.childPath),ea=qa==null?void 0:qa.childPath)});let ka="";if(Ue){let qa=(Ne=(Ia=W.value)==null?void 0:Ia.find(vl=>(vl==null?void 0:vl.isMainKey)===!0))==null?void 0:Ne.prop;ka=v==null?void 0:v[qa];let Tl=ea==null?void 0:ea.split(I),La=[];Tl==null||Tl.forEach((vl,zl)=>{(Tl==null?void 0:Tl.length)-1===zl&&La.push(ka),La.push(vl)}),La=La==null?void 0:La[0];let Ll=await le.getItemData(La,sessionStorage.getItem("systemKey"),""),nl=Ll==null?void 0:Ll.filter(vl=>(vl==null?void 0:vl.name)===ke);nl=nl==null?void 0:nl.map(vl=>{var zl;return vl.compData=(zl=vl==null?void 0:vl.compData)==null?void 0:zl.map(xl=>{var Cr;return(xl==null?void 0:xl.key)==="tableContents"&&(xl.contents=(Cr=xl==null?void 0:xl.contents)==null?void 0:Cr.filter(hr=>(hr==null?void 0:hr[1])===(v==null?void 0:v[ke]))),xl}),vl}),(!nl||(nl==null?void 0:nl.length)===0)&&(nl=Ll,nl=nl==null?void 0:nl.map(vl=>{var zl;return vl.compData=(zl=vl==null?void 0:vl.compData)==null?void 0:zl.map(xl=>{var Cr;return(xl==null?void 0:xl.key)==="tableContents"&&(xl.contents=(Cr=xl==null?void 0:xl.contents)==null?void 0:Cr.filter(hr=>{var cr,_l;return(hr==null?void 0:hr[1])===(v==null?void 0:v[(_l=(cr=W==null?void 0:W.value)==null?void 0:cr[0])==null?void 0:_l.prop])})),xl}),vl})),ge=dt(nl)}const Na=await ut(ie,{token:Je,inputData:ge}).catch(qa=>(Le.setImportLoading(!1),Promise.reject(qa))),Aa=(Q=Na==null?void 0:Na.data)==null?void 0:Q.data,la=oe.find(qa=>(qa==null?void 0:qa.prop)==="Output1"),ol=la==null?void 0:la.prop;let xa=[],tl=[];if(Aa&&((je=Object.values(Aa))==null?void 0:je.length)>0){let qa=[];const Tl=new FormData,La=(ha=s(Aa))==null?void 0:ha.map(async nl=>{var vl,zl;if(!Array.isArray(nl)&&(nl!=null&&nl.includes("http"))){let xl=await Ja.axios.get(nl,{responseType:"blob"}),Cr=(zl=nl==null?void 0:nl.split("/"))==null?void 0:zl[((vl=nl==null?void 0:nl.split("/"))==null?void 0:vl.length)-1];Tl.append("files",xl.data,Cr)}else qa.push(nl)});if(await Promise.all(La),!le.isFormDataEmpty(Tl)){let nl=await pl.uploadAmountApi(Tl),vl=(za=(B=nl==null?void 0:nl.data)==null?void 0:B.result)==null?void 0:za.map(zl=>{var xl,Cr,hr,cr,_l,rr;return{name:(rr=(_l=(cr=(xl=zl==null?void 0:zl.url)==null?void 0:xl.split("/"))==null?void 0:cr[((hr=(Cr=zl==null?void 0:zl.url)==null?void 0:Cr.split("/"))==null?void 0:hr.length)-1])==null?void 0:_l.split("."))==null?void 0:rr[0],url:zl==null?void 0:zl.url}});qa=[...qa,...vl]}let Ll={};for(let nl in v)nl!=="id"&&(Ll[nl]=v[nl]);Ll[ol]=qa,tl.push({id:v==null?void 0:v.id,value:{tableData:Ll}})}if((tl==null?void 0:tl.length)>0){const qa=tl.map(La=>{const Ll={id:La.id,...La.value.tableData};return delete Ll._isOCRRow,delete Ll._ocrTableId,delete Ll._isTemp,delete Ll.tableEditType,delete Ll.index,Ll}),Tl=[{tableName:(Ua=d==null?void 0:d.related)==null?void 0:Ua.find(La=>La==null?void 0:La.includes("content")),tableContents:qa}];await M.pageBatchUpdateApi({platId:parseInt((sl=Nl.value)==null?void 0:sl.plat_id),changeContents:Tl})}if((xa==null?void 0:xa.length)>0)try{await M.pageBatchAddApi({platId:parseInt((Ga=Nl.value)==null?void 0:Ga.plat_id),changeContents:[{tableName:(Da=d==null?void 0:d.related)==null?void 0:Da.find(qa=>qa==null?void 0:qa.includes("content")),tableContents:xa.map(qa=>{var La,Ll,nl;const Tl={id:((La=qa==null?void 0:qa.key)==null?void 0:La.id)??((Ll=qa==null?void 0:qa.key)==null?void 0:Ll.rowId)??(qa==null?void 0:qa.id),...((nl=qa==null?void 0:qa.value)==null?void 0:nl.tableData)||{}};return delete Tl._isOCRRow,delete Tl._ocrTableId,delete Tl._isTemp,delete Tl.tableEditType,delete Tl.index,Object.keys(Tl).forEach(vl=>{vl==="证书附件"&&Array.isArray(Tl[vl])&&(Tl[vl]=JSON.stringify(Tl[vl]))}),Tl})}]})}catch(qa){Ja.ElMessage.error(((Wl=(dl=qa==null?void 0:qa.response)==null?void 0:dl.data)==null?void 0:Wl.message)||(qa==null?void 0:qa.message)||"保存失败"),Ge.setTableLoading(!1);return}Ui(!0),Le.setImportLoading(!1),Ge.setFreshContent(!0)},h=(f,v)=>(f=f==null?void 0:f.map(z=>{var L,H;return z!=null&&z.children&&((L=z.children)!=null&&L.find(T=>T.id===(v==null?void 0:v.id))?z.children=(H=z.children)==null?void 0:H.filter(T=>(T==null?void 0:T.id)!==(v==null?void 0:v.id)):z.children=h(z.children,v)),z}),f),k=e.ref(!1),C=()=>{k.value=!0},F=async f=>{var z,L,H,T;k.value=!1;const v=Array.isArray(f)?f:f?[f]:[];if(v.length!==0)for(const ie of v){const oe={name:ie.name||`capture-${Date.now()}.jpg`,url:URL.createObjectURL(ie),raw:ie,uid:Date.now()+Math.random()};ga.value.push(oe),yn(oe,"uploading"),Xr(oe,0);try{const K=new FormData;K.append("file",ie,oe.name);const ke=await M.platformUploadFile(K);oe.uploadResult=((z=ke==null?void 0:ke.data)==null?void 0:z.result)||{name:oe.name,url:"",fileName:oe.name},al({name:((L=oe.uploadResult)==null?void 0:L.name)||oe.name,url:((H=oe.uploadResult)==null?void 0:H.url)||"",id:(T=oe.uploadResult)==null?void 0:T.id}),yn(oe,"uploaded"),Xr(oe,100)}catch(K){console.error("文件上传失败:",K),Ja.ElMessage.error(`文件 ${oe.name} 上传失败,请重试`),yn(oe,"pending"),Xr(oe,0);const ke=ga.value.findIndex(ge=>ge.uid===oe.uid);ke>-1&&ga.value.splice(ke,1)}}},Y=e.reactive({title:"迁移至",show:!1,width:"20%",selectRow:null,from:d==null?void 0:d.index,to:null,contents:[],formRules:{groupName:[{required:!0,message:"输入不能为空",trigger:"blur"},{validator:(f,v,z)=>{v===(d==null?void 0:d.index)?z(new Error("选择源不能和目标源一致")):z()}}]},buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"确认",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]}),J=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:""}),xe=()=>{J.show=!1},He=async f=>{var v,z,L,H,T,ie,oe,K;try{const ke=[];let ge=(v=Ce.value||[])==null?void 0:v.slice();(f||[]).forEach(Na=>{const Aa={...Na};try{Aa.sort=ui(0,ge)}catch{}ke.push(Aa),ge.unshift(Aa)});let Je=await M.quoteApi({platId:parseInt((z=Nl==null?void 0:Nl.value)==null?void 0:z.plat_id),type:"fatherSyncs",related:[{menus:de.value,groups:""},{menus:de.value,groups:d==null?void 0:d.compName}]});Je=(L=Je==null?void 0:Je.data)==null?void 0:L.result;let Ue=Je==null?void 0:Je.map(Na=>({tableName:"content_"+(Na==null?void 0:Na.id),tableContents:ke==null?void 0:ke.map((Aa,la)=>({id:la,...Aa}))})),ea=[{tableName:(H=d==null?void 0:d.related)==null?void 0:H.find(Na=>Na==null?void 0:Na.includes("content")),tableContents:ke==null?void 0:ke.map((Na,Aa)=>({id:Aa,...Na}))}];ea=[...ea,...Ue];const ka=await M.pageBatchAddApi({platId:parseInt((T=Nl.value)==null?void 0:T.plat_id),changeContents:ea});if(((ie=ka==null?void 0:ka.data)==null?void 0:ie.code)===200){const Na={buttonName:"新增",columns:W.value,fixContent:ke==null?void 0:ke.map((la,ol)=>({id:ol,...la})),relatedContents:d==null?void 0:d.related};await Ot(Na),Ja.ElMessage.success("数据导入成功");let Aa=[];ea==null||ea.forEach(la=>{var ol;(ol=la==null?void 0:la.tableContents)==null||ol.forEach(xa=>{Aa.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(xa),request_result:"{}",is_delete:!1,request_table:la==null?void 0:la.tableName,request_type:"export"})})}),await M.pageBatchAddApi({platId:parseInt((oe=Nl==null?void 0:Nl.value)==null?void 0:oe.plat_id),changeContents:[{tableName:"log",tableContents:Aa}]})}else{let Na=[];ea==null||ea.forEach(Aa=>{var la;(la=Aa==null?void 0:Aa.tableContents)==null||la.forEach(ol=>{Na.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ol),request_result:"{}",is_delete:!1,request_table:Aa==null?void 0:Aa.tableName,request_type:"error"})})}),await M.pageBatchAddApi({platId:parseInt((K=Nl==null?void 0:Nl.value)==null?void 0:K.plat_id),changeContents:[{tableName:"log",tableContents:Na}]}),Ja.ElMessage.error("数据导入响应失败")}}catch(ke){throw new Error(ke)}},Se=async f=>{var v,z,L,H,T,ie,oe,K,ke,ge;try{if(f==="cancel"&&(J.show=!1),f==="replace"&&((v=J==null?void 0:J.existRows)==null?void 0:v.length)>0){await M.pageBatchDeleteApi({platId:parseInt((z=Nl.value)==null?void 0:z.plat_id),changeContents:[{tableName:((L=d==null?void 0:d.related)==null?void 0:L.find(Ue=>Ue==null?void 0:Ue.includes("content_")))||((H=d==null?void 0:d.related)==null?void 0:H.find(Ue=>Ue==null?void 0:Ue.includes("content"))),tableContents:J==null?void 0:J.existRows}]});const Je=await M.pageBatchAddApi({platId:parseInt((T=Nl.value)==null?void 0:T.plat_id),changeContents:[{tableName:(ie=d==null?void 0:d.related)==null?void 0:ie.find(Ue=>Ue==null?void 0:Ue.includes("content")),tableContents:(()=>{const Ue=(Ce.value||[]).filter(Aa=>!((J==null?void 0:J.existRows)||[]).some(la=>String(la==null?void 0:la.id)===String(Aa==null?void 0:Aa.id))),ea=(J==null?void 0:J.tableData)||[],ka=[];let Na=Ue.slice();return ea.forEach(Aa=>{const la={...Aa};try{la.sort=ui(0,Na)}catch{}ka.push(la),Na.unshift(la)}),ka.map((Aa,la)=>({id:la,...Aa}))})()}]});if(((oe=Je==null?void 0:Je.data)==null?void 0:oe.code)!==200)return;(K=J.newRows)!=null&&K.length&&await He(J.newRows),await Ot({buttonName:"新增",columns:W.value,fixContent:(ke=J==null?void 0:J.tableData)==null?void 0:ke.map((Ue,ea)=>({id:ea,...Ue})),relatedContents:d==null?void 0:d.related}),(ge=J.newRows)!=null&&ge.length||Ja.ElMessage.success("数据导入成功")}}catch(Je){throw new Error(Je)}finally{J.show=!1,J.columns=[],J.tableData=[],J.existRows=[]}},da=()=>{Y.show=!1},Ma=f=>{var v,z;if((f==null?void 0:f.buttonName)==="取消")return Y.show=!1;Y.to=f==null?void 0:f.content,!(!(d!=null&&d.index)||!((v=Y.to)!=null&&v.groupName))&&(d==null?void 0:d.index)!==((z=Y.to)==null?void 0:z.groupName)&&(U("change",{buttonName:"迁移",value:{from:Y.from,to:Y.to,data:Y.selectRow}}),Y.show=!1)},rl=async f=>{var v,z,L,H;if(f){if(!Ar.validateFileSize(f.raw)){Ja.ElMessage.warning(`文件大小不能超过 ${Re.value.maxSize}MB`);const T=ga.value.findIndex(ie=>ie.uid===f.uid);T>-1&&ga.value.splice(T,1),el();return}if(!Ar.validateFileType(f.raw)){Ja.ElMessage.warning("请上传图片文件");const T=ga.value.findIndex(ie=>ie.uid===f.uid);T>-1&&ga.value.splice(T,1),el();return}yn(f,"uploading"),Xr(f,0);try{const T=new FormData;T.append("file",f.raw,f.name);const ie=await M.platformUploadFile(T);f.uploadResult=((v=ie==null?void 0:ie.data)==null?void 0:v.result)||{name:f.name,url:"",fileName:f.name},al({name:((z=f.uploadResult)==null?void 0:z.name)||f.name,url:((L=f.uploadResult)==null?void 0:L.url)||"",id:(H=f.uploadResult)==null?void 0:H.id}),yn(f,"uploaded"),Xr(f,100)}catch(T){console.error("文件上传失败:",T),Ja.ElMessage.error(`文件 ${f.name} 上传失败,请重试`),yn(f,"pending"),Xr(f,0);const ie=ga.value.findIndex(oe=>oe.uid===f.uid);ie>-1&&ga.value.splice(ie,1)}finally{el()}}},el=()=>{e.nextTick(()=>{const f=document.querySelector('.ocr-upload-input input[type="file"]');f&&(f.value="")})},cl=async()=>{var z,L;if(sessionStorage.setItem("ocr_root_table_id",String((d==null?void 0:d.index)??"")),ga.value.length===0){Ja.ElMessage.warning("请先选择要上传的图片");return}if(ga.value.filter(H=>{const T=ar(H);return T!=="uploaded"&&T!=="completed"&&T!=="failed"}).length>0){Ja.ElMessage.warning("请等待所有文件上传完成后再开始识别");return}dr.value=!0,Te.value=0;let v=null;try{ga.value.forEach(la=>{yn(la,"processing")});const H=Math.floor(Math.random()*10)+90;v=setInterval(()=>{Te.value<H?Te.value+=1:clearInterval(v)},50);const T=ga.value.map(la=>{var ol,xa,tl;return{name:((ol=la.uploadResult)==null?void 0:ol.name)||la.name,url:((xa=la.uploadResult)==null?void 0:xa.url)||"",fileName:((tl=la.uploadResult)==null?void 0:tl.fileName)||la.name}}),ie=Ar.extractTableHeaders(W.value),oe=T.map(la=>({name:(la==null?void 0:la.fileName)||(la==null?void 0:la.name),url:(la==null?void 0:la.url)||""})),K=await Ar.recognize(oe,ie);if(console.log(K,"ocrResult"),clearInterval(v),v=null,(K==null?void 0:K.code)===500||(K==null?void 0:K.type)==="error"||!(K!=null&&K.result)){Te.value=0,ga.value.forEach(la=>{yn(la,"failed"),Xr(la,0)}),Ja.ElMessage.error((K==null?void 0:K.message)||"OCR识别失败,请重试"),dr.value=!1;return}Te.value=H;const ke=Array.isArray(K==null?void 0:K.result)?K.result:[];if(ke.length===0){Te.value=0,ga.value.forEach(la=>{yn(la,"failed"),Xr(la,0)}),Ja.ElMessage.warning("OCR识别未返回有效数据"),dr.value=!1;return}const ge=new Set,Je=[];ke.forEach((la,ol)=>{const xa=la!=null&&la.数据&&typeof(la==null?void 0:la.数据)=="object"?la.数据:{},tl=Array.isArray(la==null?void 0:la.图片信息)?la.图片信息:[],be=new Map;tl.forEach(ba=>{ba!=null&&ba.name&&be.set(ba.name,ba.url||"")});const Va={_index:ol,_certType:(la==null?void 0:la.证书类型)||"",_certNo:(la==null?void 0:la.证书编号)||"",_ocrImages:tl,__ocrFieldMeta:{}};Object.entries(xa).forEach(([ba,Ya])=>{let Ia="",Ne=0,Q=[],je="";Ya&&typeof Ya=="object"&&!Array.isArray(Ya)?(Ia=(Ya==null?void 0:Ya.value)??"",Ne=(Ya==null?void 0:Ya.score)??0,Q=Array.isArray(Ya==null?void 0:Ya.bboxNorm)?Ya==null?void 0:Ya.bboxNorm:[],je=(Ya==null?void 0:Ya.imageName)||""):Array.isArray(Ya)&&Ya.length>=2?(Ia=Ya[0]??"",Ne=Ya[1]??0):(Ia=Ya??"",Ne=0),Va[ba]=Ia,Va[`${ba}_accuracy`]=Ne,ge.add(ba),Va.__ocrFieldMeta[ba]={value:Ia,score:Ne,bboxNorm:Q,imageName:je,imageUrl:je&&be.get(je)||"",images:tl}}),Je.push(Va)});const Ue=[],ea=new Set;Je.forEach(la=>{la&&ge.forEach(ol=>{const xa=la[`${ol}_accuracy`];(typeof xa=="number"?xa>0:xa!=null&&String(xa).trim()!==""&&String(xa)!=="0")&&ea.add(ol)})}),ge.forEach(la=>{Ue.push({prop:la,label:la,editable:!0,minWidth:230}),ea.has(la)&&Ue.push({prop:`${la}_accuracy`,label:"准确率",editable:!1,minWidth:100,isAccuracy:!0})}),ga.value.forEach(la=>{yn(la,"completed")}),Te.value=100,pe.value=Ue,Ka.value=Je,ul.value=T,Ol.value=K;const ka=["出厂编号","设备名称","制造厂"],Na=Ue.filter(la=>la&&!la.isAccuracy&&typeof la.prop=="string").map(la=>la.prop),Aa=["出厂编号","设备名称","制造厂"];ca.value=Na.filter(la=>Aa.includes(la)),console.log("[OCR] 默认勾选字段 props:",ca.value),Ha.value=2,dr.value=!1,oa.value=!1}catch(H){console.error("OCR处理失败:",H),v&&(clearInterval(v),v=null),Ja.ElMessage.error(((L=(z=H==null?void 0:H.response)==null?void 0:z.data)==null?void 0:L.message)||"OCR识别失败,请重试"),dr.value=!1,Te.value=0,ga.value.forEach(T=>{yn(T,"pending"),Xr(T,0)})}},Dl=f=>{if(f==null)return"";let v=String(f);return v=v.replace(/\s+/g," ").trim(),v=v.replace(/[!-~]/g,z=>String.fromCharCode(z.charCodeAt(0)-65248)),v=v.replace(/ /g," "),v=v.replace(/^(编号|No\.?|NO\.?|no\.?|SN\.?|sn\.?|序列号)\s*[::]?\s*/i,""),v},El=()=>{var la,ol;const f=ul.value,v=Ol.value,z=Ka.value;if(!z||z.length===0){Ja.ElMessage.warning("暂无数据可添加");return}const L=(la=le.getAllLeafNodes(W.value)||[])==null?void 0:la.filter(xa=>(xa==null?void 0:xa.type)!=="operate"&&(xa==null?void 0:xa.label)!=="操作"&&(xa==null?void 0:xa.prop)!=="operate"),H=new Map,T=new Map,ie=(ol=L==null?void 0:L.find(xa=>(xa==null?void 0:xa.label)==="证书附件"))==null?void 0:ol.prop;L==null||L.forEach(xa=>{xa!=null&&xa.label&&(xa!=null&&xa.prop)&&(H.set(xa.label,xa.prop),T.set(xa.prop,xa.label))});const oe=Date.now(),K=xa=>String(oe*1e3+xa),ke=[],ge=[],Je=xa=>{const tl=Ao&&Ao[xa]||[xa];for(const be of tl){const Va=H.get(be);if(Va)return Va}return""},Ue=Je("出厂编号"),ea=Je("设备名称"),ka=Je("制造厂"),Na=[],Aa=xa=>{var Ia,Ne;if(!ie)return[];const tl=(Array.isArray(f)?f[xa]:null)||null,be=(tl==null?void 0:tl.url)||"",Va=(tl==null?void 0:tl.fileName)||(tl==null?void 0:tl.name)||"";return(String(Va).toLowerCase().endsWith(".pdf")||String(be).toLowerCase().endsWith(".pdf"))&&be?[{url:be,name:Va,fileName:Va}]:(Array.isArray((Ne=(Ia=v==null?void 0:v.result)==null?void 0:Ia[xa])==null?void 0:Ne.图片信息)?v.result[xa].图片信息:[]).map(Q=>({url:(Q==null?void 0:Q.url)||"",name:(Q==null?void 0:Q.name)||"",fileName:(Q==null?void 0:Q.name)||""})).filter(Q=>Q.url)};if(z.forEach((xa,tl)=>{var sl;const be={id:K(tl),_isOCRRow:!0,_ocrTableId:d==null?void 0:d.index};for(const[Ga,Da]of H.entries())Object.prototype.hasOwnProperty.call(xa,Ga)&&(be[Da]=xa[Ga]);ie&&(be[ie]=Aa(tl));const Va=(Array.isArray(v==null?void 0:v.result)?v.result[tl]:null)||null,ba=(Array.isArray(f)?f[tl]:null)||null,Ya=(ba==null?void 0:ba.url)||"",Ia=(ba==null?void 0:ba.fileName)||(ba==null?void 0:ba.name)||"",Ne=String(Ia).toLowerCase().endsWith(".pdf")||String(Ya).toLowerCase().endsWith(".pdf"),Q={ts:Date.now(),versionId:String(Date.now())+"_"+String(tl),label:new Date().toLocaleString(),certType:(Va==null?void 0:Va.证书类型)||"",certNo:(Va==null?void 0:Va.证书编号)||"",fileType:Ne?"pdf":"image",sourceUrl:Ne?Ya:"",images:Array.isArray(Va==null?void 0:Va.图片信息)?Va.图片信息.map(Ga=>({name:(Ga==null?void 0:Ga.name)||"",url:(Ga==null?void 0:Ga.url)||""})).filter(Ga=>Ga.url):[]},je=Ga=>Dl(Ga?be==null?void 0:be[Ga]:""),ha=je(Ue),B=je(ea),za=je(ka);if(!!(Ue&&ea&&ka&&ha&&B&&za)){const Ga=(Ce.value||[]).find(Da=>{const dl=Dl(Ue?Da==null?void 0:Da[Ue]:""),Wl=Dl(ea?Da==null?void 0:Da[ea]:""),qa=Dl(ka?Da==null?void 0:Da[ka]:"");return dl&&Wl&&qa&&dl===ha&&Wl===B&&qa===za});if(Ga){Na.push({idx:tl,ocrRow:be,versionItem:Q,ocrNo:ha,candidates:[Ga],selectedTargetId:String((Ga==null?void 0:Ga.id)??""),__decision:"replace",allowAdd:!1,allowReplace:!0});return}}if(ha&&Ue){const Ga=(Ce.value||[]).filter(Da=>{const dl=Dl(Ue?Da==null?void 0:Da[Ue]:"");return dl&&dl===ha});if(Ga.length>0){Na.push({idx:tl,ocrRow:be,versionItem:Q,ocrNo:ha,candidates:Ga,selectedTargetId:"",__decision:"",allowAdd:!0,allowReplace:!0});return}}try{if(be.sort===void 0||be.sort===null||String(be.sort).trim()===""){const Ga=(Ce.value||[]).map(dl=>jn(dl==null?void 0:dl.sort)).filter(dl=>dl!==null),Da=Ga.length>0?Math.max(...Ga):((sl=Ce.value)==null?void 0:sl.length)??0;be.sort=String(Number((Da+1).toFixed(6)))}}catch{}Kl(d==null?void 0:d.index,be.id,Q),Na.push({idx:tl,ocrRow:be,versionItem:Q,ocrNo:ha,candidates:[],selectedTargetId:"",__decision:"add",allowAdd:!0,allowReplace:!1})}),(Na||[]).length>0){bl.value=(Na||[]).map(xa=>({...xa,selectedTargetId:(xa==null?void 0:xa.selectedTargetId)||""})),Fe.value=!0,tr.value=ge,xr.value=ke,Ra.value=v,kl.value=f,Ml.value=ie||"";return}},Vl=(f,v,z)=>{Ka.value[f]&&(Ka.value[f][v]=z)},ir=f=>f==null||f===0?"-":`${(Number(f)*100).toFixed(1)}%`,fr=f=>{if(f==null||f===0)return"#909399";const v=Number(f);return v>=.9?"#67c23a":v>=.7?"#e6a23c":"#f56c6c"},ql=f=>{var z,L,H,T;if(Xa.value===f){Xa.value=null,wa.value=!1,ua.value="";return}Xa.value=f,ua.value="";const v=(z=Ka.value)==null?void 0:z[f];if(v&&Array.isArray(v._ocrImages)&&v._ocrImages.length>0){Ba.value=v._ocrImages.map(K=>({name:(K==null?void 0:K.name)||"",url:(K==null?void 0:K.url)||""})).filter(K=>K.name||K.url);const ie=v.__ocrFieldMeta||{},oe=(L=Object.values(ie))==null?void 0:L.find(K=>K==null?void 0:K.imageName);hl.value=(oe==null?void 0:oe.imageName)||((T=(H=Ba.value)==null?void 0:H[0])==null?void 0:T.name)||"",wa.value=Ba.value.length>0}else Ba.value=[],wa.value=!1,hl.value=""},sr=()=>{Sl.value=!1,ga.value=[],il.value=null,Ha.value=1,Sa.value.clear(),ll.value.clear(),Te.value=0,wa.value=!1},dn=f=>f.raw?URL.createObjectURL(f.raw):f.url?f.url:"",ar=f=>{const v=f.uid||f.name;return Sa.value.get(v)||"pending"},bn=f=>{const v=f.uid||f.name;return ll.value.get(v)||0},Xr=(f,v)=>{const z=f.uid||f.name;ll.value.set(z,Math.min(100,Math.max(0,v)))},Rn=f=>{const v=ar(f),z=100.53;if(v==="completed"||v==="uploaded")return`${z} ${z}`;if(v==="failed")return`${z} ${z}`;if(v==="uploading"){const L=bn(f);return`${z*(L/100)} ${z}`}else if(v==="processing")return`${z*.5} ${z}`;return`0 ${z}`},yn=(f,v)=>{const z=f.uid||f.name;Sa.value.set(z,v),(v==="completed"||v==="uploaded")&&Xr(f,100)},pi=()=>{e.nextTick(()=>{const f=document.querySelector('.ocr-upload-input input[type="file"]');if(f)f.value="",f.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 z=>{const L=Array.from(z.target.files||[]);for(const H of L){const T={name:H.name,raw:H,uid:Date.now()+Math.random()};ga.value.push(T),await rl(T)}z.target.value="",document.body.removeChild(v)},document.body.appendChild(v),v.click()}})},Eu=()=>{Ha.value>1&&Ha.value--},Cu=()=>{Ha.value===1?ga.value.length>0&&!dr.value&&cl():Ha.value===2&&(El(),Ha.value=3)},Du=async f=>{await Ht(f==null?void 0:f.row)},Tu=async({row:f,prop:v})=>{!f||!v||await Ht(f,v)},Ht=async(f,v)=>{var H,T;const z=f==null?void 0:f.id;if(!z){Ja.ElMessage.warning("暂无可预览数据");return}let L=Wa(d==null?void 0:d.index,z);if(!L||L.length===0){const ie=sessionStorage.getItem("ocr_root_table_id"),oe=ie!==null?Number(ie):null;if(oe!=null&&oe!==""&&!Number.isNaN(oe)){const K=Wa(oe,z);Array.isArray(K)&&K.length>0&&(Gl(d==null?void 0:d.index,z,K),L=K)}}if(!L||L.length===0){const ie=(H=le.getAllLeafNodes(W.value)||[])==null?void 0:H.filter(K=>(K==null?void 0:K.type)!=="operate"&&(K==null?void 0:K.label)!=="操作"&&(K==null?void 0:K.prop)!=="operate"),oe=v||((T=ie==null?void 0:ie.find(K=>(K==null?void 0:K.label)==="证书附件"))==null?void 0:T.prop);if(oe&&f[oe]){const K=f[oe];let ke=[],ge="",Je=!1;if(typeof K=="string")try{const Ue=JSON.parse(K);Array.isArray(Ue)&&(ke=Ue.map(ea=>({name:(ea==null?void 0:ea.name)||(ea==null?void 0:ea.fileName)||"",url:(ea==null?void 0:ea.url)||""})).filter(ea=>ea.url||ea.name),ke.length>0&&(ge=ke[0].url||"",Je=String(ke[0].name).toLowerCase().endsWith(".pdf")||String(ge).toLowerCase().endsWith(".pdf")))}catch{ge=K,Je=String(K).toLowerCase().endsWith(".pdf"),ke=[{name:K,url:K}]}else Array.isArray(K)&&(ke=K.map(Ue=>({name:(Ue==null?void 0:Ue.name)||(Ue==null?void 0:Ue.fileName)||"",url:(Ue==null?void 0:Ue.url)||""})).filter(Ue=>Ue.url||Ue.name),ke.length>0&&(ge=ke[0].url||"",Je=String(ke[0].name).toLowerCase().endsWith(".pdf")||String(ge).toLowerCase().endsWith(".pdf")));if(ke.length>0||ge){const Ue={ts:Date.now(),versionId:String(Date.now()),label:new Date().toLocaleString(),certType:f.证书类型||"",certNo:f.证书编号||"",fileType:Je?"pdf":"image",sourceUrl:Je?ge:"",images:ke};L=[Ue],Kl(d==null?void 0:d.index,z,Ue)}}}if(!L||L.length===0){Ja.ElMessage.warning("暂无可预览数据");return}Bl.value=L,fl.value=!0},Bu=f=>{ga.value=ga.value.filter((v,z)=>z!==f)},pt=async(f,v,z)=>{var L,H,T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya;if(Ca(d.config,{type:ya.TABLE,tableOperate:f})){if(fa.value="",Ae.value=!0,ja.value=!0,U("onButtonClick",f,v),X.value=[],f==="删除")M.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var Ia,Ne,Q,je;(Ia=Ce.value)!=null&&Ia.find(ha=>(ha==null?void 0:ha.id)===(v==null?void 0:v.id))?Ce.value=(Ne=M.cloneDeep(Ce.value))==null?void 0:Ne.filter(ha=>(ha==null?void 0:ha.id)!==(v==null?void 0:v.id)):Ce.value=h(M.cloneDeep(Ce.value),v);try{v!=null&&v.id&&((je=(Q=Ta.value)==null?void 0:Q.has)!=null&&je.call(Q,v==null?void 0:v.id))&&Ta.value.delete(v.id)}catch{}m0(Sr.value,$l.value,v==null?void 0:v.id),Ge.setTableLoading(d==null?void 0:d.index),U("change",{content:Ce.value,fixContent:[v],index:d==null?void 0:d.index,type:"delete",name:d==null?void 0:d.groupNames,buttonName:f,columns:W.value,relatedContents:d==null?void 0:d.related}),console.log(v,"item")});else if(f==="批量删除"){if(((L=Br.value)==null?void 0:L.length)===0)return Ja.ElMessage.warning("请先勾选操作的数据");M.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(async()=>{var Q,je,ha,B,za;const Ia=(Q=Br.value)==null?void 0:Q.map(Ua=>Ua.id);Ce.value=(je=M.cloneDeep(Ce.value))==null?void 0:je.filter(Ua=>!(Ia!=null&&Ia.includes(Ua.id))),Ge.setTableLoading(d==null?void 0:d.index),U("change",{content:Ce.value,fixContent:Br.value,index:d==null?void 0:d.index,type:"delete",name:d==null?void 0:d.compName,buttonName:f,relatedContents:d==null?void 0:d.related,columns:W.value});const Ne=(Ia||[]).filter(Boolean);if(Ne.length>0&&Ne.every(Ua=>Ua!=null&&Ua!=="")){const Ua=(Br.value||[]).map(sl=>{const Ga={...sl};return delete Ga._isOCRRow,delete Ga._ocrTableId,delete Ga._isTemp,delete Ga.tableEditType,delete Ga.index,Ga});await M.pageBatchDeleteApi({platId:parseInt((ha=Nl.value)==null?void 0:ha.plat_id),changeContents:[{tableName:((B=d==null?void 0:d.related)==null?void 0:B.find(sl=>sl==null?void 0:sl.includes("content_")))||((za=d==null?void 0:d.related)==null?void 0:za.find(sl=>sl==null?void 0:sl.includes("content"))),tableContents:Ua}]})}})}else if(f==="复制新增"){ma.value="复制新增",M.cloneDeep(v);const Ia=(H=W.value)==null?void 0:H.find(Ne=>Ne==null?void 0:Ne.isMainKey);Ia||((T=W.value)==null||T[0]),Yl.value=v,Ui(!0)}else if(f==="新增")ma.value="新增",ji(""),Qe.value=!0;else if(f==="编辑")ma.value="编辑",ji(v),Qe.value=!0;else if(f==="查看")ma.value="查看",ji(v),Ae.value=!1,ja.value=!1,Qe.value=!0;else if(f==="查看三维模型"){const Ia={};for(let Q in v)Q!=="id"&&(Ia[Q]=v[Q]);let Ne=(ie=Object.values(Ia))==null?void 0:ie[1];Ea.setTableShowThree(Ne)}else if(f==="切换视图")ju();else if(((oe=z==null?void 0:z.extra)==null?void 0:oe.type)==="modelExample")ma.value=f,ne.value=!0;else if(f==="新建"){let Ia=pa.value,Ne=[];for(let za in Ia)za!=null&&za.includes(`loading${((K=Nl.value)==null?void 0:K.account)||((ke=Nl.value)==null?void 0:ke.账号)}`)&&(Ne=[...Ne,...za]);let Q=[];for(let za in Ia)za!=null&&za.includes(`updateLoading${((ge=Nl.value)==null?void 0:ge.account)||((Je=Nl.value)==null?void 0:Je.账号)}`)&&(Q=[...Q,...za]);let je=Ne==null?void 0:Ne.map(za=>za==null?void 0:za.id);const ha=Q==null?void 0:Q.map(za=>za==null?void 0:za.id);je=[...M.cloneDeep(je),...ha],(je==null?void 0:je.length)>0&&(je!=null&&je.every(za=>za!==null&&za))&&await Kr.batchDeleteInsofDataApi({ids:je});const B=(Ue=Ee.value)==null?void 0:Ue.find(za=>(za==null?void 0:za.label)==="新建");await zu(!1,B)}else if(f==="修改模板"){let Ia=M.cloneDeep(de).value;Ge.setRouteToChildPath(Ia),Le.setActiveMenuPath(Ia+I)}else if(f==="执行")t(f,v);else if(f==="导出paraform"){const Ia=M.ElLoading.service({lock:!0,text:"正在导出paraform...",background:"rgba(0, 0, 0, 0.7)"});try{const Ne=["推力","真空","压力","温度","流量"],Q=_l=>{var rr,mr,Il;return _l?typeof(_l==null?void 0:_l.value)=="string"?_l.value:((Il=(mr=(rr=_l==null?void 0:_l._custom)==null?void 0:rr.value)==null?void 0:mr.value)==null?void 0:Il.value)||"":""},je=Array.isArray(nr.value)?nr.value:[],ha=Q(je.find(_l=>(_l==null?void 0:_l.condition)==="child")),B=String(ha||"").slice(0,8),za=_l=>{if(_l==null)return"";const rr=String(_l).trim();if(!rr)return"";if(/^\d{8}$/.test(rr))return rr;const mr=rr.match(/^(\d{4})[-\/.](\d{1,2})[-\/.](\d{1,2})$/);if(mr){const yr=mr[1],Dr=mr[2].padStart(2,"0"),gr=mr[3].padStart(2,"0");return`${yr}${Dr}${gr}`}const Il=rr.replace(/\D/g,"");return Il.length>=8?Il.slice(0,8):""},Ua=async _l=>{var rr,mr;if(!_l)return"";try{const Il=await Hr("试验任务/任务管理",!1),yr=(vr,Or=[])=>{if(!Array.isArray(vr))return Or;for(const Fr of vr)(Fr==null?void 0:Fr.comp)==="Table"&&(Fr!=null&&Fr.name)&&Or.push(Fr),Array.isArray(Fr==null?void 0:Fr.children)&&yr(Fr.children,Or),Array.isArray(Fr==null?void 0:Fr.tab)&&yr(Fr.tab,Or),Array.isArray(Fr==null?void 0:Fr.choice)&&yr(Fr.choice,Or);return Or},gr=yr(Il||[]).find(vr=>(vr==null?void 0:vr.name)==="任务列表"),Mr=((mr=(rr=gr==null?void 0:gr.compData)==null?void 0:rr.find(vr=>(vr==null?void 0:vr.key)==="tableContents"))==null?void 0:mr.contents)||[];if(!Array.isArray(Mr)||Mr.length===0)return"";const tn=Mr.find(vr=>String((vr==null?void 0:vr["试验代号(名称)"])||"").slice(0,8)===_l);return za(tn==null?void 0:tn.计划试验时间)}catch(Il){return console.warn("获取任务列表计划试验时间失败:",Il),""}},sl=(de.value||"").replace(/\/+$/,""),Ga=ha?`${sl}/${ha}`:sl,Da=await Hr(Ga||de.value,!1),dl=String(Ve.value||"").trim(),Wl=_l=>String(_l||"").trim(),qa=(_l,rr=[],mr="")=>{if(!Array.isArray(_l))return rr;for(const Il of _l){const yr=Wl((Il==null?void 0:Il.choiceName)||(Il==null?void 0:Il.name0)||mr);(Il==null?void 0:Il.comp)==="Table"&&(Il==null?void 0:Il.name)&&Ne.includes(Il.name)&&(!dl||yr===dl)&&rr.push(Il),Array.isArray(Il==null?void 0:Il.children)&&qa(Il.children,rr,yr),Array.isArray(Il==null?void 0:Il.tab)&&qa(Il.tab,rr,yr),Array.isArray(Il==null?void 0:Il.choice)&&qa(Il.choice,rr,yr)}return rr},Tl=qa(Da||[]),La=new Map;for(const _l of Tl)_l!=null&&_l.name&&!La.has(_l.name)&&La.set(_l.name,_l);const Ll=Ne.map(_l=>La.get(_l)).filter(Boolean);if(!Ll||Ll.length===0)return Ja.ElMessage.warning("未找到需要导出的表(推力、真空、压力、温度、流量)");const nl=_l=>{const rr=new Map,mr=(Il,yr=[])=>{if(Array.isArray(Il))for(const Dr of Il){const gr=((Dr==null?void 0:Dr.label)??"").toString().trim(),Mr=gr?[...yr,gr]:[...yr];if(Array.isArray(Dr==null?void 0:Dr.children)&&Dr.children.length>0)mr(Dr.children,Mr);else{const vr=((Dr==null?void 0:Dr.prop)??"").toString();if(!vr)continue;const Or=gr||vr,Fr=(Mr.length>0?[...yr,Or]:[Or]).join(".");rr.set(vr,Fr)}}};return mr(_l,[]),rr},vl=(_l,rr)=>{const mr=nl(_l||[]),yr=(le.getAllLeafNodes(_l||[])||[]).filter(gr=>(gr==null?void 0:gr.prop)&&(gr==null?void 0:gr.type)!=="operate"&&(gr==null?void 0:gr.label)!=="操作"&&(gr==null?void 0:gr.prop)!=="operate"),Dr=Array.isArray(rr)?rr:[];return Dr.length===0?[]:Dr.map(gr=>{const Mr={};return yr.forEach(tn=>{const vr=String(tn.prop),Or=mr.get(vr)||String(tn.label||tn.prop);Mr[Or]=(gr==null?void 0:gr[vr])??""}),Mr})},zl=Ll.map(_l=>{var Dr,gr;const rr=(_l==null?void 0:_l.compData)||[];let mr=(Dr=rr==null?void 0:rr.find(Mr=>(Mr==null?void 0:Mr.key)==="header"))==null?void 0:Dr.contents;Array.isArray(mr==null?void 0:mr[0])&&(mr=mr[0]);const Il=((gr=rr==null?void 0:rr.find(Mr=>(Mr==null?void 0:Mr.key)==="tableContents"))==null?void 0:gr.contents)||[];if(!Array.isArray(mr)||mr.length===0||!Array.isArray(Il)||Il.length===0)return null;const yr=vl(mr||[],Il||[]);return!Array.isArray(yr)||yr.length===0?null:{类型:_l==null?void 0:_l.name,数据:yr}}).filter(Boolean);if(!zl||zl.length===0)return Ja.ElMessage.warning("没有可导出的数据(推力、真空、压力、温度、流量均为空)");const xl=await Ua(B),Cr={试验代号:B,试验日期:xl,ParaForm:zl},hr=await Si().catch(()=>""),cr=await M.exportParaformApi(Cr,hr);if(((ea=cr==null?void 0:cr.data)==null?void 0:ea.code)===200&&((Na=(ka=cr==null?void 0:cr.data)==null?void 0:ka.result)!=null&&Na.Excel文件)){const _l=cr.data.result.Excel文件,rr=await M.platformDownloadFile({url:_l}),mr=new Blob([rr.data],{type:"application/vnd.ms-excel"}),Il=URL.createObjectURL(mr),yr=M.dayjs().format("YYYYMMDD"),gr=`${(B||"UNKNOWN").trim()||"UNKNOWN"}_${yr}_paraform.xls`,Mr=document.createElement("a");Mr.href=Il,Mr.download=gr,Mr.style.display="none",document.body.appendChild(Mr),Mr.click(),setTimeout(()=>{document.body.removeChild(Mr),URL.revokeObjectURL(Il)},100);const tn=Array.isArray((la=(Aa=cr==null?void 0:cr.data)==null?void 0:Aa.result)==null?void 0:la.warnings)?cr.data.result.warnings:[];if(tn.length>0){const vr=tn.map((Or,Fr)=>`${Fr+1}. ${(Or==null?void 0:Or.field)||"未知字段"}:${(Or==null?void 0:Or.message)||""}`).join(`
|
|
23
|
+
`)},b=R=>{if(!R)return;const re=`gpy-preview-${Date.now()}.jpg`;m.value=[{name:re,blobUrl:R}],u.value=!0},S=()=>{u.value=!1},I=()=>{w(),n("cancel")};return(R,re)=>{const X=e.resolveComponent("el-input"),me=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode($r.ssDialog,{title:"扫描录入",visible:r.visible,onBeforeDestroy:I,width:"1200px",style:{height:"80%"}},{default:e.withCtx(()=>[e.createElementVNode("div",x0,[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)"}},[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",w0,"初始化摄像头..."))],512),e.createElementVNode("div",_0,[e.createElementVNode("div",S0,[re[0]||(re[0]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"拍照图片",-1)),e.createElementVNode("div",E0,[p.value.length===0?(e.openBlock(),e.createElementBlock("div",C0,"暂无图片")):(e.openBlock(),e.createElementBlock("div",D0,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(ue,U)=>(e.openBlock(),e.createElementBlock("div",{key:ue.uid,style:{position:"relative",border:"1px solid var(--el-border-color)","border-radius":"4px",overflow:"hidden",background:"#fafafa"}},[e.createElementVNode("img",{src:ue.url,onClick:W=>b(ue.url),style:{width:"100%",height:"94px","object-fit":"contain",display:"block",background:"#fafafa",cursor:"zoom-in"},alt:"captured image",title:"点击放大"},null,8,T0),e.createElementVNode("div",{onClick:W=>x(U),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,B0)]))),128))]))],512)]),e.createElementVNode("div",N0,[re[1]||(re[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",A0,[e.createVNode(me,{onClick:q,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[2]||(re[2]=[e.createTextVNode("适屏")])),_:1,__:[2]},8,["disabled"]),e.createVNode(me,{onClick:A,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[3]||(re[3]=[e.createTextVNode("左旋")])),_:1,__:[3]},8,["disabled"]),e.createVNode(me,{onClick:j,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[4]||(re[4]=[e.createTextVNode("右旋")])),_:1,__:[4]},8,["disabled"]),e.createVNode(me,{onClick:O,disabled:!o.value,id:"themeBorderButton"},{default:e.withCtx(()=>re[5]||(re[5]=[e.createTextVNode("对焦")])),_:1,__:[5]},8,["disabled"]),e.createVNode(me,{onClick:E,disabled:!o.value,id:"themeButton"},{default:e.withCtx(()=>re[6]||(re[6]=[e.createTextVNode("拍照")])),_:1,__:[6]},8,["disabled"]),re[9]||(re[9]=e.createElementVNode("div",{style:{flex:"1"}},null,-1)),e.createVNode(me,{onClick:_,disabled:p.value.length===0,id:"themeButton"},{default:e.withCtx(()=>re[7]||(re[7]=[e.createTextVNode("确认")])),_:1,__:[7]},8,["disabled"]),e.createVNode(me,{onClick:I,id:"themeBorderButton"},{default:e.withCtx(()=>re[8]||(re[8]=[e.createTextVNode("取消")])),_:1,__:[8]})])]),_:1},8,["visible"]),u.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:0,fileDataList:m.value,onDestroy:S},null,8,["fileDataList"])):e.createCommentVNode("",!0)],64)}}}),M0=pr._export_sfc(z0,[["__scopeId","data-v-24a2050a"]]),Ts=M.useMenuState(M.pinia);let Ai="$R";const I0=async a=>{var o,p,c,u,m,g;let l=a==null?void 0:a.导入文件,r=a==null?void 0:a.函数参数,n=(o=l==null?void 0:l[0])==null?void 0:o.url,i="";if(!(n!=null&&n.includes("http"))||!(n!=null&&n.includes("https"))){Ts.setContentLoading(!0);const y=await M.platformDownloadFile({url:n});let d=y==null?void 0:y.data;const D=new FormData;D.append("file",d,((p=l==null?void 0:l[0])==null?void 0:p.name)+"."+((c=n==null?void 0:n.split("."))==null?void 0:c[1])),D.append("query",r);let w=await hc(D);w=(g=(m=(u=w==null?void 0:w.data)==null?void 0:u.data)==null?void 0:m.response)==null?void 0:g.replace("generateResult",a==null?void 0:a.函数名称),i=w,Ts.setContentLoading(!1)}return i},O0=a=>{var r,n;if(a==="")return;let l=a;return l=(n=(r=l==null?void 0:l.replace("(",Ai))==null?void 0:r.split(Ai))==null?void 0:n[1],l=l==null?void 0:l.slice(0,(l==null?void 0:l.length)-1),l=le.analyzeSplitToContent(l,","),l=l==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)),l=l==null?void 0:l.filter(i=>(i==null?void 0:i.includes("If"))&&!(i!=null&&i.includes("@If"))),l=l==null?void 0:l.map(i=>{var c,u,m,g,y;let o=i;o=(u=(c=o==null?void 0:o.replace("=",Ai))==null?void 0:c.split(Ai))==null?void 0:u[1],o=(m=le.analyzeSplitToContent(o,")"))==null?void 0:m[0];let p=i==null?void 0:i.replaceAll(o,"");return(o==null?void 0:o[0])==="("&&(o=o==null?void 0:o.slice(1,(o==null?void 0:o.length)-1)),o=(y=(g=o==null?void 0:o.replace("(",Ai))==null?void 0:g.split(Ai))==null?void 0:y[1],o="("+o,o=le.calculatorAndToOr(o),{key:p,content:o}}),l},Bs=(a,l)=>{let r=[l];return a==null||a.forEach(n=>{for(let i in n)n[i]!=="!"?r=r==null?void 0:r.filter(o=>{var p;return(o==null?void 0:o[i])===(n==null?void 0:n[i])||(o==null?void 0:o[(p=Object.keys(o))==null?void 0:p.find(c=>c==null?void 0:c.includes("."+i))])===(n==null?void 0:n[i])}):r=r==null?void 0:r.filter(o=>{var p;return(o==null?void 0:o[i])!==(n==null?void 0:n[i])&&(o==null?void 0:o[(p=Object.keys(o))==null?void 0:p.find(c=>c==null?void 0:c.includes("."+i))])!==(n==null?void 0:n[i])})}),r},Vt=M.defineStore("formComp",{state:()=>({objUrl:[],blobUrls:[]}),actions:{setObjUrl(a){this.objUrl=a},setBlobUrls(a){this.blobUrls=a}}}),L0=M.useModelComp(M.pinia),{extraContents:Z1}=M.storeToRefs(L0),R0=M.useLoginState(M.pinia),{extraUrl:mi}=M.storeToRefs(R0);let Bc=mi.value===""||!mi.value?"http://139.196.154.85:20015":mi.value;e.watch(()=>mi.value,()=>{Bc=mi.value===""||!mi.value?"http://139.196.154.85:20015":mi.value},{deep:!0,immediate:!0});const Ao={检校类型:["检校类型","证书类别"],证书编号:["证书编号"],设备名称:["设备名称","器具名称","样品名称","仪器名称","被校设备"],型号规格:["型号规格","型号/规格","型号"],出厂编号:["出厂编号","器具/管理编号","器具编号","管理编号","仪器编号"],制造厂:["制造厂","制造单位","制造厂商","制造商"],检校结果:["检校结果","检定结论","校准结果","校准/检定结果","检定结果"],依据文件:["依据文件","检定依据","检定所依据的技术文件","所依据/参照技术文件(代号/名称)","检定所依据的技术文件(编号/名称)","检定方法说明"],检校日期:["检校日期","校准日期","校验日期","检定日期","发证日期","发布日期","接收日期","签证日期"],有效日期:["有效日期","有效期","有效期至"]},Ns={columnName:"OCR图片",acceptTypes:"image/*",maxSize:10,maxFiles:20,apiUrl:Bc+"/api/public/paddleOCR"};class $0{constructor(l){fn(this,"config");this.config={...Ns,...l}}updateConfig(l){this.config={...this.config,...l}}getConfig(){return{...this.config}}validateFileSize(l){const r=this.config.maxSize*1024*1024;return l.size<=r}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,r){return{title:r,form:{OCR图片文件:l}}}async recognize(l,r){const n=this.getAuthorizationToken(),i=this.buildOCRRequest(l,r),o=this.config.apiUrl||Ns.apiUrl||"";return(await Ja.axios.post(o,i,{headers:{"Content-Type":"application/json",Authorization:n}})).data}getFieldAliases(l){return Ao[l]?Ao[l]:[l]}extractTableHeaders(l){const r=[],n=new Set,i=p=>{const c=p==null?void 0:p.label;return!(!c||c==="操作"||c===this.config.columnName||(p==null?void 0:p.type)==="operate"||(p==null?void 0:p.prop)==="operate")},o=p=>{(p||[]).forEach(c=>{if(!c)return;const u=(c==null?void 0:c.children)||(c==null?void 0:c.child)||(c==null?void 0:c.columns);if(Array.isArray(u)&&u.length>0){o(u);return}if(i(c)){const m=c.label;if(!n.has(m)){n.add(m);const g=this.getFieldAliases(m);r.push(g)}}})};return o(l||[]),r}}function Nc(a){return new $0(a)}Nc();const Nt=async(a,l)=>{var p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b;let r=(c=(p=M.cloneDeep(a))==null?void 0:p.optionUrl)==null?void 0:c.menuSelect,n=[];r==null||r.forEach(S=>{});let i="",o=await le.menuToParent(r);if(o==null||o.forEach(S=>{var I,R,re,X;(S==null?void 0:S.name)===(((X=(re=(R=(I=M.cloneDeep(a))==null?void 0:I.optionUrl)==null?void 0:R.groupSelect)==null?void 0:re[0])==null?void 0:X.replaceAll("'",""))??"")&&(i=S==null?void 0:S.id)}),l){i=l;const S=await Kr.getInsofDataApi({id:i}),I=(y=(g=(m=(u=S==null?void 0:S.data)==null?void 0:u.result)==null?void 0:m[0])==null?void 0:g.key)==null?void 0:y.pageKey;o=await le.getItemData(I,sessionStorage.getItem("systemKey"),"")}if(i!==""){let S;l?S=(d=o==null?void 0:o.find(re=>(re==null?void 0:re.id)===l))==null?void 0:d.compData:S=(D=o==null?void 0:o.find(re=>{var X,me,ue,U;return(re==null?void 0:re.name)===(((me=(X=a==null?void 0:a.groupSelect)==null?void 0:X.split(":"))==null?void 0:me[0])||((U=(ue=a==null?void 0:a.optionUrl)==null?void 0:ue.groupSelect)==null?void 0:U[0]))}))==null?void 0:D.compData;let I=(q=(w=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:w.contents)==null?void 0:q.map(re=>re==null?void 0:re.label);(j=(A=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:A.contents)!=null&&j.every(re=>Array.isArray(re))&&(I=(_=le.getColumnChild((E=(O=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:O.contents)==null?void 0:E[0]))==null?void 0:_.map(re=>re==null?void 0:re.prop));let R=(b=(x=S==null?void 0:S.find(re=>(re==null?void 0:re.key)==="tableContents"))==null?void 0:x.contents)==null?void 0:b.map(re=>{if(Array.isArray(re))re=re==null?void 0:re.filter(X=>!(X!=null&&X.id));else{let X={};for(let me in re)me!=="id"&&(X[me]=re==null?void 0:re[me]);re=X}return re});R==null||R.forEach(re=>{Array.isArray(re)?n.push(le.getValueToObjectValue(re,I)):n.push(re)})}return n},V0=M.useMenuState(M.pinia),{activeMenuPath:Q1}=M.storeToRefs(V0),F0=M.useUnit(M.pinia),{chooseTitle:e8}=M.storeToRefs(F0),P0="col-operate",Ac=a=>`${P0}-${a}`,j0=(a,l)=>{const r=new Map;a.forEach(i=>{const{prop:o}=i;r.set(o,i)});const n=i=>{Array.isArray(i)&&i.forEach(o=>{const{prop:p}=o||{},c=r.get(p);H0(c,o),Array.isArray(o==null?void 0:o.children)&&o.children.length>0&&n(o.children)})};return n(l),l},H0=(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:r=!1,filterable:n=!1,showSummary:i=!1,operable:o=!1,fixed:p=!1}=l||{};return{prop:a,sortable:r,filterable:n,showSummary:i,operable:o,fixed:p}},q0=async a=>{var o,p;if(!a)return;const l=Ac(a),r=await Kr.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:l}}),n=(o=r==null?void 0:r.data)==null?void 0:o.code,i=(p=r==null?void 0:r.data)==null?void 0:p.result;if(n==200)return i==null?void 0:i[0]},W0=async a=>{if(a)return[]},G0=async(a,l)=>{if(!a||!l)return;const r=Ac(a);return await Kr.createInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:r},value:{columns:l}})},K0=async(a,l)=>!a||!l?void 0:await Kr.updateInsofDataApi({id:a,value:{columns:l}}),As=async(a,l)=>{const r=sessionStorage.getItem("systemKey");if(!a||!l||!r)return;const n=await q0(a);return n?await K0(n==null?void 0:n.id,l):await G0(a,l)};var So={exports:{}},Y0=So.exports,zs;function J0(){return zs||(zs=1,function(a,l){(function(r,n){n()})(Y0,function(){function r(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 n(m,g,y){var d=new XMLHttpRequest;d.open("GET",m),d.responseType="blob",d.onload=function(){u(d.response,g,y)},d.onerror=function(){console.error("could not download file")},d.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 o(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 p=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof M.commonjsGlobal=="object"&&M.commonjsGlobal.global===M.commonjsGlobal?M.commonjsGlobal:void 0,c=p.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),u=p.saveAs||(typeof window!="object"||window!==p?function(){}:"download"in HTMLAnchorElement.prototype&&!c?function(m,g,y){var d=p.URL||p.webkitURL,D=document.createElement("a");g=g||m.name||"download",D.download=g,D.rel="noopener",typeof m=="string"?(D.href=m,D.origin===location.origin?o(D):i(D.href)?n(m,g,y):o(D,D.target="_blank")):(D.href=d.createObjectURL(m),setTimeout(function(){d.revokeObjectURL(D.href)},4e4),setTimeout(function(){o(D)},0))}:"msSaveOrOpenBlob"in navigator?function(m,g,y){if(g=g||m.name||"download",typeof m!="string")navigator.msSaveOrOpenBlob(r(m,y),g);else if(i(m))n(m,g,y);else{var d=document.createElement("a");d.href=m,d.target="_blank",setTimeout(function(){o(d)})}}:function(m,g,y,d){if(d=d||open("","_blank"),d&&(d.document.title=d.document.body.innerText="downloading..."),typeof m=="string")return n(m,g,y);var D=m.type==="application/octet-stream",w=/constructor/i.test(p.HTMLElement)||p.safari,q=/CriOS\/[\d]+/.test(navigator.userAgent);if((q||D&&w||c)&&typeof FileReader<"u"){var A=new FileReader;A.onloadend=function(){var E=A.result;E=q?E:E.replace(/^data:[^;]*;/,"data:attachment/file;"),d?d.location.href=E:location=E,d=null},A.readAsDataURL(m)}else{var j=p.URL||p.webkitURL,O=j.createObjectURL(m);d?d.location=O:location.href=O,d=null,setTimeout(function(){j.revokeObjectURL(O)},4e4)}});p.saveAs=u.saveAs=u,a.exports=u})}(So)),So.exports}J0();const ti=M.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}}}),X0=M.useLoginState(M.pinia),{loginUserInfo:kt}=M.storeToRefs(X0),Z0=async a=>{var n,i,o;let l=await M.getAllTables({platId:parseInt((n=kt==null?void 0:kt.value)==null?void 0:n.plat_id),tableNames:[a]});return l=(o=(i=l==null?void 0:l.data)==null?void 0:i.result)==null?void 0:o[0],await Sc(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}]}]},Q0=M.useLoginState(),{loginUserInfo:yl}=M.storeToRefs(Q0);let bo="$R";const Wr=M.useModelComp(M.pinia),zc=e.ref(!1),{itemData:e3,itemGridData:hi,curStructureCompIds:Ms,isSubmitCurStructure:a3,routeToChildPath:l3,pageMapState:At,itemExtendData:ko,refreshTable:Is,refreshCurrentPageInform:r3}=M.storeToRefs(Wr),Fo=ti(M.pinia),ln=M.useMenuState(M.pinia),kr=e.shallowRef([]),{asideMenus:n3,activeTopMenuPath:i3,activeMenuPath:Cl,platform:a8,buttonTriggerType:o3,currentMenuPath:_n}=M.storeToRefs(ln),Nn=M.useUnit(M.pinia),{selectTitle:ni,chooseTitle:zo}=M.storeToRefs(Nn);e.ref();const Ri=e.ref(!0),oi=e.ref(0),zt=e.ref([]);e.ref(!1);const Ft=e.ref(!1),Qi=e.ref(),Mc=e.ref(),Ic=e.ref(),t3=()=>{Wr.setItemGridData([]),Wr.setIsEdit("edit"),Wr.setSubmitCurStructure(Cl.value!=="/平台管理/菜单管理")},s3=()=>{Wr.setIsEdit("view"),Wr.setRefreshCurStructure(!0)},c3=async a=>{var i;let l=ni.value,r=l==null?void 0:l.findIndex(o=>(o==null?void 0:o.value)===(a==null?void 0:a.value)),n=l==null?void 0:l.filter((o,p)=>p<=r);Nn.setSelectTitle(pl.safeClone(n)),n=(i=n==null?void 0:n.map(o=>o==null?void 0:o.value))==null?void 0:i.join("/"),ln.setActiveMenuPath(null),ln.setActiveMenuPath(n)},xt=async(a,l,r,n="contentConfig")=>{var i;try{if(!Array.isArray(a))return;let o,p;l==="create"?(o={dataList:a==null?void 0:a.map(u=>{var m;return{key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:r!=null&&r.startsWith("/")?r==null?void 0:r.substring(1):r,type:"structure",structureBelong:n,parentTable:"",version:1},value:{pageData:{...u,compData:(m=u==null?void 0:u.compData)==null?void 0:m.filter(g=>(g==null?void 0:g.key)!=="tableContents")}}}})},p=Kr.batchAddInsofDataApi):l==="update"?(o={dataList:a==null?void 0:a.map(u=>{var m;return{id:u==null?void 0:u.id,value:{pageData:{...u,compData:(m=u==null?void 0:u.compData)==null?void 0:m.filter(g=>(g==null?void 0:g.key)!=="tableContents")}}}})},p=Kr.batchUpdateInsofDataApi):l==="delete"&&(o={ids:a},p=Kr.batchDeleteInsofDataApi);const c=await p(o);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("保存响应失败")}},Os=async(a,l,r,n)=>{var i,o,p,c,u,m,g,y,d,D,w;try{const q=(o=(i=a==null?void 0:a.results)==null?void 0:i.filter(x=>!(x!=null&&x.id)||typeof(x==null?void 0:x.id)=="string"))==null?void 0:o.map(x=>({key:{pageKey:a==null?void 0:a.pageKey,systemKey:sessionStorage.getItem("systemKey"),type:l,relatedInfo:r},value:{tableData:x}})),A=(c=(p=a==null?void 0:a.results)==null?void 0:p.filter(x=>(x==null?void 0:x.id)&&typeof(x==null?void 0:x.id)=="number"))==null?void 0:c.map(x=>({id:x==null?void 0:x.id,value:{tableData:x}})),j=JSON.parse(JSON.stringify(a)),O=(u=j==null?void 0:j.results)==null?void 0:u.map(x=>x.id);let E;r?E=(y=(g=(m=At.value)==null?void 0:m[Cl.value])==null?void 0:g.filter(x=>{var b,S,I;return((b=x==null?void 0:x.key)==null?void 0:b.type)===l&&((I=(S=x==null?void 0:x.key)==null?void 0:S.relatedInfo)==null?void 0:I.target)===n}))==null?void 0:y.map(x=>x==null?void 0:x.id):E=(w=(D=(d=At.value)==null?void 0:d[Cl.value])==null?void 0:D.filter(x=>{var b;return((b=x==null?void 0:x.key)==null?void 0:b.type)===l}))==null?void 0:w.map(x=>x==null?void 0:x.id);const _=E==null?void 0:E.filter(x=>!(O!=null&&O.includes(x))&&typeof x=="number");(q==null?void 0:q.length)>0&&await Kr.batchAddInsofDataApi({dataList:q}),(A==null?void 0:A.length)>0&&await Kr.batchUpdateInsofDataApi({dataList:A}),(_==null?void 0:_.length)>0&&await Kr.batchDeleteInsofDataApi({ids:_})}catch(q){throw new Error(q)}},u3=async a=>{var m,g,y,d,D,w,q,A,j,O;ln.setContentLoading(!0);const l=JSON.parse(JSON.stringify(e3.value));if(!a3.value)return ln.setCacheStructures({key:o3.value,data:l}),Ja.ElMessage.success("已暂存");const r=l==null?void 0:l.map(E=>E.id),n=r.filter(E=>{var _;return!((_=Ms.value)!=null&&_.includes(E))}),i=(m=Ms.value)==null?void 0:m.filter(E=>!r.includes(E)),o=[...n,...i].filter(E=>typeof E!==null&&typeof E<"u"),p=l==null?void 0:l.filter(E=>!E.id),c=l==null?void 0:l.filter(E=>E.id);let u=[];if(o&&(o==null?void 0:o.length)>0&&u.push(xt(o,"delete",a)),p&&(p==null?void 0:p.length)>0&&u.push(xt(p,"create",a)),c&&(c==null?void 0:c.length)>0&&u.push(xt(c,"update",a)),hi.value&&((g=hi.value)!=null&&g.isDelete&&((d=(y=hi.value)==null?void 0:y.results)==null?void 0:d.length)>0&&((w=(D=hi.value)==null?void 0:D.results)!=null&&w.every(E=>typeof E=="number"))?await Kr.batchDeleteInsofDataApi({ids:(q=hi.value)==null?void 0:q.results}):(console.log("itemGridData.value",hi.value),u.push(await Os(hi.value,"gridLayout")))),ko.value)for(const E in ko.value)u.push(await Os((A=ko.value)==null?void 0:A[E],"extend",{target:E,compId:(O=(j=ko.value)==null?void 0:j[E])==null?void 0:O.compId},E));await Promise.all(u).then(()=>{Ja.ElMessage.success("保存成功"),Wr.setRefreshCurStructure(!0)}).catch(E=>{Ja.ElMessage.success(E)}),ln.setContentLoading(!1)},eo=a=>$i(a),d3=e.computed(()=>{var a;return(a=kr.value)==null?void 0:a.filter(l=>(l==null?void 0:l.affix)&&(l==null?void 0:l.affix)!=="default")}),Oc=e.computed(()=>{var a;return(a=kr.value)==null?void 0:a.filter(l=>!(l!=null&&l.affix&&(l==null?void 0:l.affix)!=="default"))}),Lc=e.ref(0),Rc=e.ref(null),p3="ocr_committed_temp_ids_v1",f3=(a,l)=>`${p3}:${String(a??"")}:${String(l??"")}`,h3=(a,l,r)=>{try{const n=f3(a,l),i=sessionStorage.getItem(n),o=i?JSON.parse(i):[],p=Array.isArray(o)?o:[],c=Array.from(new Set([...p,...r||[]].map(u=>String(u)))).slice(-200);sessionStorage.setItem(n,JSON.stringify(c))}catch{}},Mo=async(a,l="data",r)=>{var i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E,_,x,b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr;let n=((p=(o=(i=ni.value)==null?void 0:i.filter(ga=>(ga==null?void 0:ga.condition)==="child"))==null?void 0:o[0])==null?void 0:p.value)??"";if((a==null?void 0:a.buttonName)==="新增"){let ga=(c=a==null?void 0:a.fixContent)==null?void 0:c.map(il=>{let fl={};for(let Bl in il)Array.isArray(il==null?void 0:il[Bl])?fl[Bl]=JSON.stringify(il==null?void 0:il[Bl]):fl[Bl]=il==null?void 0:il[Bl];return fl});if(ga!=null&&ga.every(il=>il==null?void 0:il.menuPathContent)){let il=(u=ga==null?void 0:ga[0])==null?void 0:u.menuPathContent;ga=ga==null?void 0:ga.map(oa=>(oa.id="0",oa==null||delete oa.menuPathContent,oa)),(il==null?void 0:il[0])==="$"&&(il=il==null?void 0:il.slice(1,il==null?void 0:il.length));let fl=(m=le.analyzeSplitToContent(il,"*"))==null?void 0:m[0],Bl=(g=le.analyzeSplitToContent(il,"*"))==null?void 0:g[1];fl=fl==null?void 0:fl.slice(0,(fl==null?void 0:fl.length)-1),fl=(y=le.analyzeSplitToContent(fl,":"))==null?void 0:y.map(oa=>{var Ka,pe,_a,Pa,ul;if((oa==null?void 0:oa[(oa==null?void 0:oa.length)-1])===":"&&(oa=oa==null?void 0:oa.slice(0,(oa==null?void 0:oa.length)-1)),(oa==null?void 0:oa[0])==="{"){oa=oa==null?void 0:oa.slice(1,(oa==null?void 0:oa.length)-1),(oa==null?void 0:oa[0])==="*"&&(oa=oa==null?void 0:oa.slice(1,oa==null?void 0:oa.length));let Ol=oa==null?void 0:oa.split(":"),ca=Ol==null?void 0:Ol[0],Xa=Ol==null?void 0:Ol[1];Xa=Xa==null?void 0:Xa.slice(1,(Xa==null?void 0:Xa.length)-1);let ua=(Ka=kr.value)==null?void 0:Ka.filter(wa=>(wa==null?void 0:wa.name)===ca);ua=ua==null?void 0:ua[0],ua=(ul=(Pa=(_a=(pe=ua==null?void 0:ua.compData)==null?void 0:pe.find(wa=>(wa==null?void 0:wa.key)==="tableContents"))==null?void 0:_a.contents)==null?void 0:Pa[0])==null?void 0:ul[Xa],oa=ua}return oa}),fl=fl==null?void 0:fl.join("/");let Ha=await M.getPageDataApi({platId:parseInt((d=yl==null?void 0:yl.value)==null?void 0:d.plat_id),pageName:"menu"});Ha=(D=Ha==null?void 0:Ha.data)==null?void 0:D.result,Ha=Ha==null?void 0:Ha.find(oa=>(oa==null?void 0:oa.object_name)===fl&&(oa==null?void 0:oa.property_name)===Bl);let Sa=(Ha==null?void 0:Ha.object_id)??"";if(Sa===""){Ja.ElMessage.warning("添加页面数据不存在");return}let ll=[{tableName:"content_"+Sa,tableContents:ga}];await M.pageBatchAddApi({platId:parseInt((w=yl==null?void 0:yl.value)==null?void 0:w.plat_id),changeContents:ll});let Te=[];ll==null||ll.forEach(oa=>{var Ka;(Ka=oa==null?void 0:oa.tableContents)==null||Ka.forEach(pe=>{Te.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(pe),request_result:"{}",is_delete:!1,request_table:oa==null?void 0:oa.tableName,request_type:"add"})})}),await M.pageBatchAddApi({platId:parseInt((q=yl==null?void 0:yl.value)==null?void 0:q.plat_id),changeContents:[{tableName:"log",tableContents:Te}]})}else{let il=await M.quoteApi({platId:parseInt((A=yl==null?void 0:yl.value)==null?void 0:A.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});il=(j=il==null?void 0:il.data)==null?void 0:j.result,il=il==null?void 0:il.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let fl=il==null?void 0:il.map(Te=>{var _a,Pa;let oa={},Ka=ga==null?void 0:ga[0],pe;return Array.isArray((_a=Te==null?void 0:Te.struct)==null?void 0:_a[0])?pe=le.getColumnChild((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0]):pe=Te==null?void 0:Te.struct,pe=pe==null?void 0:pe.filter(ul=>(ul==null?void 0:ul.prop)!=="relatedId"),pe==null||pe.forEach(ul=>{var Ol,ca;oa[ul.prop]=((Ol=ul==null?void 0:ul.words)!=null&&Ol[0]?(Ka==null?void 0:Ka[(ca=ul==null?void 0:ul.words)==null?void 0:ca[0]])??(Ka==null?void 0:Ka[ul==null?void 0:ul.prop]):Ka==null?void 0:Ka[ul==null?void 0:ul.prop])??""}),oa.id="1",oa.relatedId=`[${oa.id}]`,delete oa.sort,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[oa]}}),Bl=[{tableName:(O=a==null?void 0:a.relatedContents)==null?void 0:O.find(Te=>Te==null?void 0:Te.includes("content")),tableContents:ga}];Bl=[...Bl,...fl];let Ha=await M.quoteApi({platId:parseInt((E=yl==null?void 0:yl.value)==null?void 0:E.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Ha=(x=(_=Ha==null?void 0:Ha.data)==null?void 0:_.result)==null?void 0:x.filter(Te=>!(Bl!=null&&Bl.find(oa=>(oa==null?void 0:oa.tableName)==="content_"+(Te==null?void 0:Te.id)))),Ha=Ha==null?void 0:Ha.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let Sa=Ha==null?void 0:Ha.map(Te=>{var _a,Pa,ul,Ol,ca,Xa,ua;let oa={},Ka=ga==null?void 0:ga[0],pe;return Array.isArray((_a=Te==null?void 0:Te.struct)==null?void 0:_a[0])?pe=le.getColumnChild((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0]):pe=Te==null?void 0:Te.struct,pe=pe==null?void 0:pe.filter(wa=>(wa==null?void 0:wa.prop)!=="relatedId"),((Ol=(ul=pe==null?void 0:pe[0])==null?void 0:ul.words)!=null&&Ol[0]?Ka!=null&&Ka[(Xa=(ca=pe==null?void 0:pe[0])==null?void 0:ca.words)==null?void 0:Xa[0]]:Ka!=null&&Ka[(ua=pe==null?void 0:pe[0])==null?void 0:ua.prop])?(pe==null||pe.forEach(wa=>{var Ba,hl;oa[wa.prop]=((Ba=wa==null?void 0:wa.words)!=null&&Ba[0]?(Ka==null?void 0:Ka[(hl=wa==null?void 0:wa.words)==null?void 0:hl[0]])??(Ka==null?void 0:Ka[wa==null?void 0:wa.prop]):Ka==null?void 0:Ka[wa==null?void 0:wa.prop])??""}),oa.id="1",oa.relatedId=`[${oa.id}]`,delete oa.sort):oa=void 0,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[oa]}});Sa=Sa==null?void 0:Sa.filter(Te=>{var oa;return!((oa=Te==null?void 0:Te.tableContents)!=null&&oa.every(Ka=>Ka===void 0))}),Bl=[...Bl,...Sa],await M.pageBatchAddApi({platId:parseInt((b=yl==null?void 0:yl.value)==null?void 0:b.plat_id),changeContents:Bl});let ll=[];Bl==null||Bl.forEach(Te=>{var oa;(oa=Te==null?void 0:Te.tableContents)==null||oa.forEach(Ka=>{ll.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Ka),request_result:"{}",is_delete:!1,request_table:Te==null?void 0:Te.tableName,request_type:"add"})})}),await M.pageBatchAddApi({platId:parseInt((S=yl==null?void 0:yl.value)==null?void 0:S.plat_id),changeContents:[{tableName:"log",tableContents:ll}]})}}if((a==null?void 0:a.buttonName)==="OCR批量新增"){const ga=((a==null?void 0:a.ocrRows)||[]).map(Ha=>Ha==null?void 0:Ha.id).filter(Ha=>Ha!=null),il=((a==null?void 0:a.ocrRows)||[]).map(Ha=>{const Sa={...Ha};return delete Sa._isOCRRow,delete Sa._ocrTableId,Object.keys(Sa).forEach(ll=>{/(^|\.)证书附件$/.test(ll)&&Array.isArray(Sa[ll])&&(Sa[ll]=JSON.stringify(Sa[ll].map(Te=>({url:(Te==null?void 0:Te.url)||"",name:(Te==null?void 0:Te.name)||(Te==null?void 0:Te.fileName)||"",fileName:(Te==null?void 0:Te.fileName)||(Te==null?void 0:Te.name)||""})).filter(Te=>Te.url||Te.name)))}),Sa});let fl=[{tableName:(I=a==null?void 0:a.relatedContents)==null?void 0:I.find(Ha=>Ha==null?void 0:Ha.includes("content")),tableContents:il}];await M.pageBatchAddApi({platId:parseInt((R=yl==null?void 0:yl.value)==null?void 0:R.plat_id),changeContents:fl});let Bl=[];fl==null||fl.forEach(Ha=>{var Sa;(Sa=Ha==null?void 0:Ha.tableContents)==null||Sa.forEach(ll=>{Bl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ll),request_result:"{}",is_delete:!1,request_table:Ha==null?void 0:Ha.tableName,request_type:"ocrBatchAdd"})})}),await M.pageBatchAddApi({platId:parseInt((re=yl==null?void 0:yl.value)==null?void 0:re.plat_id),changeContents:[{tableName:"log",tableContents:Bl}]}),h3(a==null?void 0:a.parentTableId,a==null?void 0:a.index,ga)}if((a==null?void 0:a.buttonName)==="编辑"){const il=((a==null?void 0:a.fixContent)||(a==null?void 0:a.singleContent)||[]||[]).map(pe=>{const _a={...pe};return delete _a._isOCRRow,delete _a._ocrTableId,delete _a._isTemp,delete _a.tableEditType,delete _a.index,_a});let fl=il==null?void 0:il.map(pe=>{let _a={};for(let Pa in pe)Array.isArray(pe==null?void 0:pe[Pa])?_a[Pa]=JSON.stringify(pe==null?void 0:pe[Pa]):_a[Pa]=pe==null?void 0:pe[Pa];return _a}),Bl=await M.quoteApi({platId:parseInt((X=yl==null?void 0:yl.value)==null?void 0:X.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Bl=(me=Bl==null?void 0:Bl.data)==null?void 0:me.result,Bl=Bl==null?void 0:Bl.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))});let Ha=(ue=fl==null?void 0:fl[0])==null?void 0:ue.id,Sa=[{tableName:(U=a==null?void 0:a.relatedContents)==null?void 0:U.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:fl}],ll=(W=Bl==null?void 0:Bl.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa,Ba;return JSON.stringify(ua==null?void 0:ua.relatedId)!=="{}"&&(ua==null?void 0:ua.relatedId)!==""&&(ua!=null&&ua.relatedId)?(wa=ua==null?void 0:ua.relatedId)==null?void 0:wa.includes(parseInt(Ha)):(ua==null?void 0:ua.sort)===((Ba=fl==null?void 0:fl[0])==null?void 0:Ba.sort)});if((_a==null?void 0:_a.length)>0){let ua=fl==null?void 0:fl[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var bl,tr;wa[Fe.prop]=((bl=Fe==null?void 0:Fe.words)!=null&&bl[0]?(Ba==null?void 0:Ba[(tr=Fe==null?void 0:Fe.words)==null?void 0:tr[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??""}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,delete wa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:W.filter(pe=>pe);Sa=[...Sa,...ll];let Te=await M.quoteApi({platId:parseInt((Z=yl==null?void 0:yl.value)==null?void 0:Z.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Te=(ve=(ae=Te==null?void 0:Te.data)==null?void 0:ae.result)==null?void 0:ve.filter(pe=>!(Sa!=null&&Sa.find(_a=>(_a==null?void 0:_a.tableName)==="content_"+(pe==null?void 0:pe.id)))),Te=Te==null?void 0:Te.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))});let oa=(ze=Te==null?void 0:Te.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa,Ba,hl;return JSON.stringify(ua==null?void 0:ua.relatedId)!=="{}"&&(ua==null?void 0:ua.relatedId)!==""&&(ua!=null&&ua.relatedId)?(wa=ua==null?void 0:ua.relatedId)==null?void 0:wa.includes(parseInt(Ha)):(ua==null?void 0:ua.sort)===((Ba=fl==null?void 0:fl[0])==null?void 0:Ba.sort)||(ua==null?void 0:ua.sort)===(parseInt(((hl=fl==null?void 0:fl[0])==null?void 0:hl.sort)??"0")+1).toString()});if((_a==null?void 0:_a.length)>0){let ua=fl==null?void 0:fl[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var bl,tr,xr,Ra;((bl=Fe==null?void 0:Fe.words)!=null&&bl[0]?(Ba==null?void 0:Ba[(tr=Fe==null?void 0:Fe.words)==null?void 0:tr[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba!=null&&Ba[Fe==null?void 0:Fe.prop])&&(wa[Fe.prop]=((xr=Fe==null?void 0:Fe.words)!=null&&xr[0]?(Ba==null?void 0:Ba[(Ra=Fe==null?void 0:Fe.words)==null?void 0:Ra[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??"")}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,delete wa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:ze.filter(pe=>pe);Sa=[...Sa,...oa],await M.pageBatchUpdateApi({platId:parseInt((te=yl==null?void 0:yl.value)==null?void 0:te.plat_id),changeContents:Sa});let Ka=[];Sa==null||Sa.forEach(pe=>{var _a;(_a=pe==null?void 0:pe.tableContents)==null||_a.forEach(Pa=>{Ka.push({id:"1",request_method:"Post",request_url:"/platform/page/update",request_param:JSON.stringify(Pa),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"update"})})}),await M.pageBatchAddApi({platId:parseInt((N=yl==null?void 0:yl.value)==null?void 0:N.plat_id),changeContents:[{tableName:"log",tableContents:Ka}]})}if((a==null?void 0:a.buttonName)==="删除"){let ga=[{tableName:(se=a==null?void 0:a.relatedContents)==null?void 0:se.find(Te=>Te==null?void 0:Te.includes("content")),tableContents:a==null?void 0:a.fixContent}],il=await M.quoteApi({platId:parseInt((G=yl==null?void 0:yl.value)==null?void 0:G.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});il=(fe=il==null?void 0:il.data)==null?void 0:fe.result,il=il==null?void 0:il.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let fl=(_e=(we=a==null?void 0:a.fixContent)==null?void 0:we[0])==null?void 0:_e.id,Bl=(qe=il==null?void 0:il.map(Te=>{var Ka,pe,_a,Pa,ul,Ol;let oa=(Ka=Te==null?void 0:Te.contents)==null?void 0:Ka.filter(ca=>{var Xa,ua,wa;return JSON.stringify(ca==null?void 0:ca.relatedId)!=="{}"&&(ca==null?void 0:ca.relatedId)!==""&&(ca!=null&&ca.relatedId)?(Xa=ca==null?void 0:ca.relatedId)==null?void 0:Xa.includes(parseInt(fl)):(ca==null?void 0:ca.sort)===((wa=(ua=a==null?void 0:a.fixContent)==null?void 0:ua[0])==null?void 0:wa.sort)});if((oa==null?void 0:oa.length)>0){let ca=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];ca={...ca,id:(_a=oa==null?void 0:oa[0])==null?void 0:_a.id};let Xa={},ua=ca,wa;return Array.isArray((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0])?wa=le.getColumnChild((ul=Te==null?void 0:Te.struct)==null?void 0:ul[0]):wa=Te==null?void 0:Te.struct,wa=wa==null?void 0:wa.filter(Ba=>(Ba==null?void 0:Ba.prop)!=="relatedId"),wa==null||wa.forEach(Ba=>{var hl,Fe;Xa[Ba.prop]=((hl=Ba==null?void 0:Ba.words)!=null&&hl[0]?(ua==null?void 0:ua[(Fe=Ba==null?void 0:Ba.words)==null?void 0:Fe[0]])??(ua==null?void 0:ua[Ba==null?void 0:Ba.prop]):ua==null?void 0:ua[Ba==null?void 0:Ba.prop])??""}),Xa.id=(Ol=oa==null?void 0:oa[0])==null?void 0:Ol.id,delete Xa.sort,delete Xa.relatedId,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[Xa]}}else return}))==null?void 0:qe.filter(Te=>Te);ga=[...ga,...Bl];let Ha=await M.quoteApi({platId:parseInt((ra=yl==null?void 0:yl.value)==null?void 0:ra.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});Ha=(Ke=(P=Ha==null?void 0:Ha.data)==null?void 0:P.result)==null?void 0:Ke.filter(Te=>!(ga!=null&&ga.find(oa=>(oa==null?void 0:oa.tableName)==="content_"+(Te==null?void 0:Te.id)))),Ha=Ha==null?void 0:Ha.filter(Te=>{var oa,Ka;return!((Te==null?void 0:Te.fatherPath)!==""&&((Ka=(oa=Te==null?void 0:Te.quote)==null?void 0:oa[0])==null?void 0:Ka.menus)===(Cl==null?void 0:Cl.value))});let Sa=(Me=Ha==null?void 0:Ha.map(Te=>{var Ka,pe,_a,Pa,ul,Ol;let oa=(Ka=Te==null?void 0:Te.contents)==null?void 0:Ka.filter(ca=>{var Xa,ua,wa;return JSON.stringify(ca==null?void 0:ca.relatedId)!=="{}"&&(ca==null?void 0:ca.relatedId)!==""&&(ca!=null&&ca.relatedId)?(Xa=ca==null?void 0:ca.relatedId)==null?void 0:Xa.includes(parseInt(fl)):(ca==null?void 0:ca.sort)===((wa=(ua=a==null?void 0:a.fixContent)==null?void 0:ua[0])==null?void 0:wa.sort)});if((oa==null?void 0:oa.length)>0){let ca=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];ca={...ca,id:(_a=oa==null?void 0:oa[0])==null?void 0:_a.id};let Xa={},ua=ca,wa;return Array.isArray((Pa=Te==null?void 0:Te.struct)==null?void 0:Pa[0])?wa=le.getColumnChild((ul=Te==null?void 0:Te.struct)==null?void 0:ul[0]):wa=Te==null?void 0:Te.struct,wa=wa==null?void 0:wa.filter(Ba=>(Ba==null?void 0:Ba.prop)!=="relatedId"),wa==null||wa.forEach(Ba=>{var hl,Fe;Xa[Ba.prop]=((hl=Ba==null?void 0:Ba.words)!=null&&hl[0]?(ua==null?void 0:ua[(Fe=Ba==null?void 0:Ba.words)==null?void 0:Fe[0]])??(ua==null?void 0:ua[Ba==null?void 0:Ba.prop]):ua==null?void 0:ua[Ba==null?void 0:Ba.prop])??""}),Xa.id=(Ol=oa==null?void 0:oa[0])==null?void 0:Ol.id,delete Xa.sort,delete Xa.relatedId,{tableName:"content_"+(Te==null?void 0:Te.id),tableContents:[Xa]}}else return}))==null?void 0:Me.filter(Te=>Te);ga=[...ga,...Sa],await M.pageBatchDeleteApi({platId:parseInt((Le=yl==null?void 0:yl.value)==null?void 0:Le.plat_id),changeContents:ga});let ll=[];ga==null||ga.forEach(Te=>{var oa;(oa=Te==null?void 0:Te.tableContents)==null||oa.forEach(Ka=>{ll.push({id:"1",request_method:"Post",request_url:"/platform/page/delete",request_param:JSON.stringify(Ka),request_result:"{}",is_delete:!1,request_table:Te==null?void 0:Te.tableName,request_type:"delete"})})}),await M.pageBatchAddApi({platId:parseInt((Ie=yl==null?void 0:yl.value)==null?void 0:Ie.plat_id),changeContents:[{tableName:"log",tableContents:ll}]})}if((a==null?void 0:a.buttonName)==="复制新增"){let ga=await M.getPageDataApi({platId:parseInt((de=yl==null?void 0:yl.value)==null?void 0:de.plat_id),pageName:"menu"});if(ga=(De=ga==null?void 0:ga.data)==null?void 0:De.result,ga!=null&&ga.find(il=>(il==null?void 0:il.father_name)===Cl.value+"/")){Ic.value=a,Mc.value=ga==null?void 0:ga.filter(Bl=>(Bl==null?void 0:Bl.father_name)===Cl.value+"/");let il=(Ea=(Xe=a==null?void 0:a.columns)==null?void 0:Xe.find(Bl=>Bl==null?void 0:Bl.mainKey))==null?void 0:Ea.prop,fl=($=(Ge=a==null?void 0:a.fixContent)==null?void 0:Ge[0])==null?void 0:$[il];Ft.value=!0,Qi.value=[{prop:il,label:il,name:il,value:fl}]}else{let il=(V=a==null?void 0:a.fixContent)==null?void 0:V.map(Ha=>{let Sa={};for(let ll in Ha)Array.isArray(Ha==null?void 0:Ha[ll])?Sa[ll]=JSON.stringify(Ha==null?void 0:Ha[ll]):Sa[ll]=Ha==null?void 0:Ha[ll];return Sa.relatedId="",Sa}),fl=[{tableName:(ee=a==null?void 0:a.relatedContents)==null?void 0:ee.find(Ha=>Ha==null?void 0:Ha.includes("content")),tableContents:il}];await M.pageBatchAddApi({platId:parseInt((ce=yl==null?void 0:yl.value)==null?void 0:ce.plat_id),changeContents:fl});let Bl=[];fl==null||fl.forEach(Ha=>{var Sa;(Sa=Ha==null?void 0:Ha.tableContents)==null||Sa.forEach(ll=>{Bl.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ll),request_result:"{}",is_delete:!1,request_table:Ha==null?void 0:Ha.tableName,request_type:"copyAdd"})})}),await M.pageBatchAddApi({platId:parseInt((he=yl==null?void 0:yl.value)==null?void 0:he.plat_id),changeContents:[{tableName:"log",tableContents:Bl}]})}}if((a==null?void 0:a.buttonName)==="methodButton"){let ga=((Ve=(ia=(pa=a==null?void 0:a.columns)==null?void 0:pa.map(pe=>pe==null?void 0:pe.filter))==null?void 0:ia.filter(pe=>pe!==""))==null?void 0:Ve[0])??"";ga=le.analyzeSplitToContent(ga,","),ga=(ga==null?void 0:ga.find(pe=>pe==null?void 0:pe.includes("@Filter")))??"";let il=(ya=a==null?void 0:a.fixContent)==null?void 0:ya.map(pe=>{let _a={};for(let Pa in pe)Array.isArray(pe==null?void 0:pe[Pa])?_a[Pa]=JSON.stringify(pe==null?void 0:pe[Pa]):_a[Pa]=pe==null?void 0:pe[Pa];return _a}),fl=await M.quoteApi({platId:parseInt((Ca=yl==null?void 0:yl.value)==null?void 0:Ca.plat_id),type:"fatherSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});fl=(Ce=fl==null?void 0:fl.data)==null?void 0:Ce.result,fl=fl==null?void 0:fl.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))});let Bl=(Ta=(Fa=a==null?void 0:a.columns)==null?void 0:Fa[0])==null?void 0:Ta.prop,Ha=(fa=il==null?void 0:il[0])==null?void 0:fa[Bl],Sa=[{tableName:(ja=a==null?void 0:a.relatedContents)==null?void 0:ja.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:il}],ll=(sa=fl==null?void 0:fl.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa;return(wa=Object.values(ua))==null?void 0:wa.find(Ba=>Ba===Ha)});if((_a==null?void 0:_a.length)>0){let ua=il==null?void 0:il[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var bl,tr;wa[Fe.prop]=((bl=Fe==null?void 0:Fe.words)!=null&&bl[0]?(Ba==null?void 0:Ba[(tr=Fe==null?void 0:Fe.words)==null?void 0:tr[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop]):Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??""}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:sa.filter(pe=>pe);Sa=[...Sa,...ll];let Te=await M.quoteApi({platId:parseInt((Pe=yl==null?void 0:yl.value)==null?void 0:Pe.plat_id),type:"sonSyncs",related:[{menus:n!==""?Cl.value+"/"+n:Cl.value,groups:a==null?void 0:a.name}]});if(Te=(Qe=(ma=Te==null?void 0:Te.data)==null?void 0:ma.result)==null?void 0:Qe.filter(pe=>!(Sa!=null&&Sa.find(_a=>(_a==null?void 0:_a.tableName)==="content_"+(pe==null?void 0:pe.id)))),Te=Te==null?void 0:Te.filter(pe=>{var _a,Pa;return!((pe==null?void 0:pe.fatherPath)!==""&&((Pa=(_a=pe==null?void 0:pe.quote)==null?void 0:_a[0])==null?void 0:Pa.menus)===(Cl==null?void 0:Cl.value))}),ga&&ga!==""){(ga==null?void 0:ga[(ga==null?void 0:ga.length)-1])===","&&(ga=ga==null?void 0:ga.slice(0,(ga==null?void 0:ga.length)-1)),ga=($e=(Oe=ga==null?void 0:ga.replace("(",bo))==null?void 0:Oe.split(bo))==null?void 0:$e[1],ga=ga==null?void 0:ga.slice(0,(ga==null?void 0:ga.length)-1),(ga==null?void 0:ga[0])==="*"&&(ga="{"+((We=(ne=ga==null?void 0:ga.replace("{",bo))==null?void 0:ne.split(bo))==null?void 0:We[1])),ga=(na=ga==null?void 0:ga.replaceAll("{",""))==null?void 0:na.replaceAll("}","");let pe=le.calculatorAndToOr(ga);pe=pe==null?void 0:pe[0];let _a;if((va=Object.values(pe))!=null&&va.some(Pa=>(Pa==null?void 0:Pa[0])==="*")){let Pa=(Be=(Ae=ni.value)==null?void 0:Ae.find(ul=>(ul==null?void 0:ul.condition)==="child"))!=null&&Be.value?(_n==null?void 0:_n.value)+"/"+((Ee=(Ye=ni.value)==null?void 0:Ye.find(ul=>(ul==null?void 0:ul.condition)==="child"))==null?void 0:Ee.value):_n==null?void 0:_n.value;_a=await Hr(Pa,!1)}for(let Pa in pe)if(((ye=pe==null?void 0:pe[Pa])==null?void 0:ye[0])==="*"){let ul=(Pl=(Qa=(wl=pe[Pa])==null?void 0:wl.slice(1,($a=pe[Pa])==null?void 0:$a.length))==null?void 0:Qa.split(":"))==null?void 0:Pl[0],Ol=(jl=(gl=pe[Pa])==null?void 0:gl.split(":"))==null?void 0:jl[1],ca=(al=_a==null?void 0:_a.filter(Xa=>(Xa==null?void 0:Xa.name)===ul))==null?void 0:al[0];ca=(Wa=(Hl=ca==null?void 0:ca.compData)==null?void 0:Hl.find(Xa=>(Xa==null?void 0:Xa.key)==="tableContents"))==null?void 0:Wa.contents,ca=(Gl=ca==null?void 0:ca[0])==null?void 0:Gl[Ol],pe[Pa]=ca}ga=((Kl=Object.values(pe))==null?void 0:Kl[0])??""}let oa=(Zl=Te==null?void 0:Te.map(pe=>{var Pa,ul,Ol,ca,Xa;let _a=(Pa=pe==null?void 0:pe.contents)==null?void 0:Pa.filter(ua=>{var wa;return(wa=Object.values(ua))==null?void 0:wa.find(Ba=>Ba===(ga===""?Ha:ga))});if((_a==null?void 0:_a.length)>0){let ua=il==null?void 0:il[0];ua={...ua,id:(ul=_a==null?void 0:_a[0])==null?void 0:ul.id};let wa={},Ba=ua,hl;return Array.isArray((Ol=pe==null?void 0:pe.struct)==null?void 0:Ol[0])?hl=le.getColumnChild((ca=pe==null?void 0:pe.struct)==null?void 0:ca[0]):hl=pe==null?void 0:pe.struct,hl=hl==null?void 0:hl.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="relatedId"),hl==null||hl.forEach(Fe=>{var tr,xr,Ra,kl;let bl=(tr=a==null?void 0:a.columns)==null?void 0:tr.find(Ml=>{var Oa,aa,Rl;return((aa=(Oa=Ml==null?void 0:Ml.words)==null?void 0:Oa[0])==null?void 0:aa.replaceAll("'",""))===(Fe==null?void 0:Fe.prop)&&((Rl=Ml==null?void 0:Ml.functionRelatedWords)==null?void 0:Rl.length)>0});bl=(xr=bl==null?void 0:bl.prop)==null?void 0:xr.replaceAll("'",""),wa[Fe.prop]=((Ra=Fe==null?void 0:Fe.words)!=null&&Ra[0]?(Ba==null?void 0:Ba[(kl=Fe==null?void 0:Fe.words)==null?void 0:kl[0]])??(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??(Ba==null?void 0:Ba[bl]):(Ba==null?void 0:Ba[Fe==null?void 0:Fe.prop])??(Ba==null?void 0:Ba[bl]))??void 0}),wa.id=(Xa=_a==null?void 0:_a[0])==null?void 0:Xa.id,delete wa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[wa]}}else return}))==null?void 0:Zl.filter(pe=>pe);Sa=[...Sa,...oa],await M.pageBatchUpdateApi({platId:parseInt((Sl=yl==null?void 0:yl.value)==null?void 0:Sl.plat_id),changeContents:Sa});let Ka=[];Sa==null||Sa.forEach(pe=>{var _a;(_a=pe==null?void 0:pe.tableContents)==null||_a.forEach(Pa=>{Ka.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Pa),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"method"})})}),await M.pageBatchAddApi({platId:parseInt((dr=yl==null?void 0:yl.value)==null?void 0:dr.plat_id),changeContents:[{tableName:"log",tableContents:Ka}]})}Wr.setRefreshCurStructure(!0),Wr.setRefreshCurrentPageInform(r3.value++),await It(a)},Mt=async(a,l,r)=>{var i;let n=a==null?void 0:a.find(o=>(o==null?void 0:o.id)===l);if(n){let o=(i=n.compData)==null?void 0:i.map(p=>{var c;if((p==null?void 0:p.key)==="tableContents"){let u={...p,contents:r};return u.contents=(c=(u==null?void 0:u.contents)??[])==null?void 0:c.map(m=>{let g={};for(let y in m)JSON.stringify(m==null?void 0:m[y])==="{}"?g[y]="":g[y]=m==null?void 0:m[y];return g}),u}return p});return n.compData=await Vo(o,{}),a=a==null?void 0:a.map(p=>((p==null?void 0:p.id)===(n==null?void 0:n.id)&&(p=n),p)),a}else{let o=a==null?void 0:a.filter(c=>{var u;return(c==null?void 0:c.children)&&((u=c==null?void 0:c.children)==null?void 0:u.length)>0||(c==null?void 0:c.comp)==="Tabs"}),p=o==null?void 0:o.map(async c=>{var u;return c!=null&&c.children&&((u=c==null?void 0:c.children)==null?void 0:u.length)>0?c.children=await Mt(c==null?void 0:c.children,l,r):c.compData=await Mt(c==null?void 0:c.compData,l,r),c});return o=await Promise.all(p),o}},It=async a=>{var o,p,c,u,m,g,y;let l=(o=a==null?void 0:a.relatedContents)==null?void 0:o.filter(d=>d==null?void 0:d.includes("content_"));if(!l)return;let r=await M.getAllTables({platId:parseInt((p=yl==null?void 0:yl.value)==null?void 0:p.plat_id),tableNames:l??[]});if(r=(u=(c=r==null?void 0:r.data)==null?void 0:c.result)==null?void 0:u[0],!r||!Array.isArray(r))return;r=r==null?void 0:r.map(d=>{d==null||delete d.source_table;const D={};for(let w in d){const q=d==null?void 0:d[w],A=q&&Object.prototype.toString.call(q)==="[object Object]"&&Object.keys(q).length===0,j=Array.isArray(q)&&q.length===0;q==null||q==="{}"||A||j?D[w]="":D[w]=q}return D});let n=(g=(m=l==null?void 0:l[0])==null?void 0:m.split("_"))==null?void 0:g[1],i=await Mt(kr.value,n,r);kr.value=(y=kr.value)==null?void 0:y.map(d=>{var D,w;return(D=i==null?void 0:i[0])!=null&&D.tabInform&&((w=i==null?void 0:i[0])==null?void 0:w.tabInform)===(d==null?void 0:d.tabInform)?d=i==null?void 0:i[0]:(d!=null&&d.name?(d==null?void 0:d.name)===(i==null?void 0:i.name):(d==null?void 0:d.id)===(i==null?void 0:i.id))&&(d=i),d})},v3=a=>{let l=Qi.value;Qi.value=l==null?void 0:l.map(r=>(r.value=a==null?void 0:a[r==null?void 0:r.prop],r))},m3=async()=>{var d,D,w,q,A,j,O,E,_,x;let a=Ic.value,l=Mc.value,r=(D=(d=a==null?void 0:a.columns)==null?void 0:d.find(b=>b==null?void 0:b.mainKey))==null?void 0:D.prop,n=(q=(w=Qi.value)==null?void 0:w[0])==null?void 0:q.value,i=(A=a==null?void 0:a.fixContent)==null?void 0:A.map(b=>{var I;let S={};for(let R in b)Array.isArray(b==null?void 0:b[R])?S[R]=JSON.stringify(b==null?void 0:b[R]):S[R]=b==null?void 0:b[R];return(I=a==null?void 0:a.columns)==null||I.forEach(R=>{(R==null?void 0:R.formType)==="Upload"&&(S==null?void 0:S[R==null?void 0:R.prop])===""&&(S[R==null?void 0:R.prop]="{}")}),S[r]=n,S}),o=[{tableName:(j=a==null?void 0:a.relatedContents)==null?void 0:j.find(b=>b==null?void 0:b.includes("content")),tableContents:i}];await M.pageBatchAddApi({platId:parseInt((O=yl==null?void 0:yl.value)==null?void 0:O.plat_id),changeContents:o}),l=l==null?void 0:l.filter(b=>{var S,I,R;return(R=b==null?void 0:b.object_name)==null?void 0:R.includes((I=(S=a==null?void 0:a.fixContent)==null?void 0:S[0])==null?void 0:I[r])});let p=[],c=new Map;l==null||l.forEach(b=>{p.push(`content_${b==null?void 0:b.object_id}`),p.push(`struct_${b==null?void 0:b.object_id}`),c.set(b==null?void 0:b.object_id,b)});let u=await M.getAllTables({platId:parseInt((E=yl==null?void 0:yl.value)==null?void 0:E.plat_id),tableNames:p??[]});u=(_=u==null?void 0:u.data)==null?void 0:_.result;let m=[],g=[];u=le.chunk(u,2),u==null||u.forEach(b=>{var R,re,X,me,ue,U,W,Z,ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra,P;let S=c.get((me=(X=(re=(R=b==null?void 0:b[1])==null?void 0:R[0])==null?void 0:re.source_table)==null?void 0:X.split("_"))==null?void 0:me[1]),I=(W=(U=(ue=S==null?void 0:S.object_name)==null?void 0:ue.split("/"))==null?void 0:U.filter((Ke,Me)=>{var Le,Ie;return((Ie=(Le=S==null?void 0:S.object_name)==null?void 0:Le.split("/"))==null?void 0:Ie.length)-1!==Me}))==null?void 0:W.join("/");if(I=I+"/"+n,g!=null&&g.find(Ke=>(Ke==null?void 0:Ke.path)===I)||g.push({fatherPath:S==null?void 0:S.father_name,isShow:S==null?void 0:S.is_show,path:I}),((ae=(Z=b==null?void 0:b[1])==null?void 0:Z[0])==null?void 0:ae.类型)==="Table"){let Ke=((te=(ze=(ve=b==null?void 0:b[1])==null?void 0:ve[0])==null?void 0:ze.结构)==null?void 0:te.contents)??[],Me=pl.safeClone(Ke);Array.isArray(Me==null?void 0:Me[0])&&(Me=le.getColumnChild(Me==null?void 0:Me[0]));let Le=[];if(((N=b==null?void 0:b[0])==null?void 0:N.length)>0&&(Le=(se=b==null?void 0:b[0])==null?void 0:se.map(Ie=>Me==null?void 0:Me.map(De=>(De=(Ie==null?void 0:Ie[De==null?void 0:De.prop])??"",De)))),m!=null&&m.find(Ie=>(Ie==null?void 0:Ie.key)===I)){let Ie=(G=m==null?void 0:m.find(De=>(De==null?void 0:De.key)===I))==null?void 0:G.contents;Ie.push({isShow:S==null?void 0:S.is_show,filter:((_e=(we=(fe=b==null?void 0:b[1])==null?void 0:fe[0])==null?void 0:we.引用)==null?void 0:_e.contents)??"",key:"Table",name:Object.values(S==null?void 0:S.name),tableColumns:Ke,tableContents:Le});let de=m==null?void 0:m.findIndex(De=>(De==null?void 0:De.key)===I);m[de].contents=Ie}else m.push({key:I,contents:[{isShow:S==null?void 0:S.is_show,filter:((P=(ra=(qe=b==null?void 0:b[1])==null?void 0:qe[0])==null?void 0:ra.引用)==null?void 0:P.contents)??"",key:"Table",name:Object.values(S==null?void 0:S.name),tableColumns:Ke,tableContents:Le}]})}});let y=[];y.push({key:"menuPath",contents:g}),y=[...y,...m],await M.createPlatFormDataApi({platId:parseInt((x=yl==null?void 0:yl.value)==null?void 0:x.plat_id),changeData:y}),Ft.value=!1,Wr.setRefreshTable(!0)},Io=async(a,l)=>{},Oo=async a=>{kr.value=await le.getDeepDiffItems(a),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value)};e.ref();const y3=e.ref(null),g3=()=>{var a,l;console.log("倒计时结束时"),M.ElMessageBox.alert(`超时未提交,【${(l=(a=Cl.value)==null?void 0:a.split("/"))==null?void 0:l[0]}】失败`,"告警",{confirmButtonText:"确认",type:"error"})},$c=e.ref([]),b3=e.computed(()=>{var a,l;return(l=(a=At.value)==null?void 0:a[Cl.value])==null?void 0:l.filter(r=>{var n;return((n=r==null?void 0:r.key)==null?void 0:n.type)==="gridLayout"})});e.watch(()=>[i3.value],()=>{Nn.setSelectTitle([]),Nn.setChooseTitle([])},{deep:!0});e.watch(()=>zo.value,async(a,l)=>{var n,i,o,p,c,u;let r=(n=zo.value)==null?void 0:n.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==_n.value);if((r==null?void 0:r.length)>0){ln.setContentLoading(!0);let m=((i=r==null?void 0:r[0])==null?void 0:i.relatedContent)??(Cl==null?void 0:Cl.value),g=m+"/"+((o=r==null?void 0:r[0])==null?void 0:o.value),y=!!((p=r==null?void 0:r[0])!=null&&p.parentContent),d=await Hr(g,y,{originPath:m});d=(c=d==null?void 0:d.filter(q=>q))==null?void 0:c.map(q=>(q.isShow=!0,q)),console.log(d,"loadingContents");let D=await le.getDeepDiffItems(d),w=D==null?void 0:D.filter(q=>q==null?void 0:q.choice);Fo.setSelectTab((u=w==null?void 0:w[0])==null?void 0:u.choiceName),D=D==null?void 0:D.filter(q=>{var A;return!(q!=null&&q.choiceName)||(q==null?void 0:q.choiceName)===((A=w==null?void 0:w[0])==null?void 0:A.choiceName)}),kr.value=D,ln.setContentLoading(!1)}});const k3=(a,l)=>{setTimeout(async()=>{var c,u,m;let r=(c=zo.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)!==_n.value),n=Cl==null?void 0:Cl.value,i=Cl==null?void 0:Cl.value;(r==null?void 0:r.length)>0&&(i=((u=r==null?void 0:r[0])==null?void 0:u.relatedContent)??(Cl==null?void 0:Cl.value),n=i+"/"+((m=r==null?void 0:r[0])==null?void 0:m.value));let o=await Hr(n,!1,{originPath:i});o=o==null?void 0:o.map(g=>(g.isShow=!0,g));let p=await le.getDeepDiffItems(o);kr.value=p==null?void 0:p.filter(g=>!(g!=null&&g.step)||(g==null?void 0:g.step)===(a==null?void 0:a.title))},10)},x3=a=>{setTimeout(async()=>{var p,c,u;let l=(p=zo.value)==null?void 0:p.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==_n.value),r=Cl==null?void 0:Cl.value,n=Cl==null?void 0:Cl.value;(l==null?void 0:l.length)>0&&(n=((c=l==null?void 0:l[0])==null?void 0:c.relatedContent)??(Cl==null?void 0:Cl.value),r=n+"/"+((u=l==null?void 0:l[0])==null?void 0:u.value));let i=await Hr(r,!1,{originPath:n});i=i==null?void 0:i.map(m=>(m.isShow=!0,m)),Fo.setSelectTab(a);let o=await le.getDeepDiffItems(i);kr.value=o==null?void 0:o.filter(m=>!(m!=null&&m.choiceName)||(m==null?void 0:m.choiceName)===a)},10)};e.watch(()=>n3.value,a=>{a!=null&&a.length||(kr.value=[])},{immediate:!0});e.watch(()=>[Cl.value],async a=>{var o,p,c,u;if(!Cl.value)return;if(Cl.value==="/"){kr.value=[];return}ln.setCurrentMenuPath(Cl.value),Wr.setLockingPage(""),kr.value=[];let l=e.getCurrentInstance();(o=l==null?void 0:l.scope)==null||o.stop(),l=null,Ri.value=!1,ln.setContentLoading(!0),zc.value=!0;let r=a==null?void 0:a[0],n=r,i=(p=ni.value)==null?void 0:p.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==Cl.value&&!(m!=null&&m.relatedContent));if((i==null?void 0:i.length)>0&&(r=r+"/"+((c=i==null?void 0:i[0])==null?void 0:c.value)),r==="系统管理/日志管理")kr.value=await Z0("log");else{let m=await Hr(r,!0,{originPath:n});m=m==null?void 0:m.map(d=>(d.isShow=!0,d));let g=await le.getDeepDiffItems(m),y=g==null?void 0:g.filter(d=>d==null?void 0:d.choice);Fo.setSelectTab((u=y==null?void 0:y[0])==null?void 0:u.choiceName),kr.value=g==null?void 0:g.filter(d=>{var D;return!(d!=null&&d.choiceName)||(d==null?void 0:d.choiceName)===((D=y==null?void 0:y[0])==null?void 0:D.choiceName)})}ln.setContentLoading(!1),Wr.setExtraContents([]),Nn.setSelectIndex(""),Nn.setSelectMenu(""),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value),Wr.setRefreshTable(!1),e.nextTick(()=>{oi.value=oi.value++,Ri.value=!0})},{immediate:!0});e.watch(()=>[Is.value],async()=>{var a,l,r,n;if(Is.value){kr.value=[];let i=e.getCurrentInstance();(a=i==null?void 0:i.scope)==null||a.stop(),i=null,Ri.value=!1,ln.setContentLoading(!0),zc.value=!0;let o=_n==null?void 0:_n.value,p=o,c=(l=ni.value)==null?void 0:l.filter(y=>(y==null?void 0:y.condition)==="child"&&(y==null?void 0:y.value)!==""&&(y==null?void 0:y.parentContent)!==(_n==null?void 0:_n.value));(c==null?void 0:c.length)>0&&(o=o+"/"+((r=c==null?void 0:c[0])==null?void 0:r.value));let u=await Hr(o,!0,{originPath:p});u=u==null?void 0:u.map(y=>(y.isShow=!0,y));let m=await le.getDeepDiffItems(u),g=m==null?void 0:m.filter(y=>y==null?void 0:y.choice);if(Fo.setSelectTab((n=g==null?void 0:g[0])==null?void 0:n.choiceName),kr.value=m==null?void 0:m.filter(y=>{var d;return!(y!=null&&y.choiceName)||(y==null?void 0:y.choiceName)===((d=g==null?void 0:g[0])==null?void 0:d.choiceName)}),ln.setContentLoading(!1),Wr.setExtraContents([]),Nn.setSelectIndex(""),Nn.setSelectMenu(""),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value),Wr.setRefreshTable(!1),(c==null?void 0:c.length)>0){let y=[...ni.value,...c];Nn.setSelectTitle(y)}e.nextTick(()=>{oi.value=oi.value++,Ri.value=!0})}},{immediate:!0,deep:!0});const w3=async()=>{ln.setLinkMenuInfo(null),ln.setActiveMenuPath(l3.value),kr.value=null,Wr.setRouteToChildPath(""),ln.setChildMenu("")},_3=a=>new RegExp("button","i").test(a),S3=a=>/^[\u4e00-\u9fa5]+\/[\u4e00-\u9fa5]+\^(.+)$/.test(a),Vc=a=>{if(S3(a)){const l=a==null?void 0:a.split("^");(l==null?void 0:l.length)>0&&(l!=null&&l[0])&&ln.setLinkMenuInfo({path:l==null?void 0:l[0],data:l==null?void 0:l[1]})}},Fc=async(a,l,r)=>{var d,D,w,q,A,j,O,E,_,x,b,S;let n="",i="";for(let I in l)(l==null?void 0:l[I])===a&&(i=I);r==null||r.forEach(I=>{(I==null?void 0:I.prop)===i&&(n=I==null?void 0:I.fatherPath)});let o=n===""?Cl.value:n;n!==""&&ln.setCurrentMenuPath(o),ln.setCurrentMenuPath(o+"/"+a),ln.setContentLoading(!0),kr.value=await Hr(o+"/"+a,!0,{originPath:o+"/",row:l});let p=await Hr(o,!1),c=(d=p==null?void 0:p.filter(I=>(I==null?void 0:I.comp)==="Table"))==null?void 0:d[0],u=((A=(q=(w=(D=c==null?void 0:c.compData)==null?void 0:D.find(I=>(I==null?void 0:I.key)==="header"))==null?void 0:w.contents)==null?void 0:q[0])==null?void 0:A.prop)??((x=(_=(E=(O=(j=c==null?void 0:c.compData)==null?void 0:j.find(I=>(I==null?void 0:I.key)==="header"))==null?void 0:O.contents)==null?void 0:E[0])==null?void 0:_[0])==null?void 0:x.prop),m=(S=(b=c==null?void 0:c.compData)==null?void 0:b.find(I=>(I==null?void 0:I.key)==="tableContents"))==null?void 0:S.contents;m=m==null?void 0:m.map(I=>({label:I==null?void 0:I[u],value:I==null?void 0:I[u]}));let g=ni.value,y={value:a,condition:"child",options:m,relatedContent:o,isShow:!0};g=g==null?void 0:g.filter(I=>(I==null?void 0:I.condition)!=="child"),g.push(y),Nn.setSelectTitle(g),Nn.setChooseTitle([y]),ln.setContentLoading(!1),Wr.setExtraContents([]),Nn.setSelectIndex(""),Nn.setSelectMenu(""),Wr.setItemData(kr.value),Wr.setOriginalData(kr.value)},E3=a=>{Lc.value=a},Mi=e.reactive({index:0,comp:null}),C3=e.computed(()=>{var a;return(a=kr.value)==null?void 0:a.map((l,r)=>({id:l.id,name:l.name,status:D3(l,r)}))}),Pc=(a,l)=>{var u,m,g,y,d;const r=l?a:a-2,n=(u=kr.value)==null?void 0:u[r],i=(g=(m=n==null?void 0:n.compData)==null?void 0:m.find(D=>(D==null?void 0:D.key)==="header"))==null?void 0:g.contents,o=i==null?void 0:i.findIndex(D=>(D==null?void 0:D.isMainKey)&&(D==null?void 0:D.label)!=="操作"),p=o===-1?0:o,c=(d=(y=n==null?void 0:n.compData)==null?void 0:y.find(D=>(D==null?void 0:D.key)==="tableContents"))==null?void 0:d.contents;return{valid:c==null?void 0:c.every(D=>D==null?void 0:D[p+1]),length:(c==null?void 0:c.length)||0}},D3=(a,l)=>{var n;let r="process";if(((n=a==null?void 0:a.comp)==null?void 0:n.toUpperCase())==="TABLE"){const{valid:i,length:o}=Pc(l,!0);Mi.index===l?r="process":o===0?r="wait":r=i?"success":"error"}return r},jc=a=>{var r,n,i,o,p;const l=a+1;if(l>1&&((i=(n=(r=kr.value)==null?void 0:r[a])==null?void 0:n.comp)==null?void 0:i.toUpperCase())==="TABLE"){const{valid:c}=Pc(l);c?(Mi.index=l,Mi.comp=(o=kr.value)==null?void 0:o[a]):Ja.ElMessage({showClose:!0,type:"warning",message:"当前流程有输入未完成"})}else Mi.index=l,Mi.comp=(p=kr.value)==null?void 0:p[a]},Hc=e.computed(()=>{var a,l;return(l=(a=Oc.value)==null?void 0:a[0])==null?void 0:l.isStepLayout});e.watch(()=>Hc.value,a=>{a&&jc(0)},{immediate:!0});const Lo=e.ref(0),Uc=a=>{var l;return!a||(a==null?void 0:a.length)===0?[]:(l=M.cloneDeep(a))==null?void 0:l.map(n=>(Lo.value++,n={label:(n==null?void 0:n.label)??"",prop:(n==null?void 0:n.label)==="操作"?"operate":n==null?void 0:n.prop,width:n!=null&&n.width?parseInt(n.width):"",fixed:(n==null?void 0:n.fixed)??void 0,sortable:(n==null?void 0:n.sortable)??!1,align:(n==null?void 0:n.align)??"left",showOverflowTooltip:(n==null?void 0:n.showOverflowTooltip)??!0,isNotDrag:(n==null?void 0:n.isNotDrag)??!1,isEditCol:(n==null?void 0:n.isEditCol)??!1,isOperate:(n==null?void 0:n.isOperate)??!1,id:(n==null?void 0:n.id)??Lo.value,children:Uc(n==null?void 0:n.children)},n))},T3=a=>{var r;return(r=M.cloneDeep(a))==null?void 0:r.map(n=>(Lo.value++,n={label:(n==null?void 0:n.label)??"",prop:(n==null?void 0:n.label)==="操作"?"operate":n==null?void 0:n.prop,width:n!=null&&n.width?parseInt(n.width):"",fixed:(n==null?void 0:n.fixed)??void 0,sortable:(n==null?void 0:n.sortable)??!1,align:(n==null?void 0:n.align)??"left",showOverflowTooltip:(n==null?void 0:n.showOverflowTooltip)??!0,isNotDrag:(n==null?void 0:n.isNotDrag)??!1,isEditCol:(n==null?void 0:n.isEditCol)??!1,isOperate:(n==null?void 0:n.isOperate)??!1,id:(n==null?void 0:n.id)??Lo.value,children:Uc(n==null?void 0:n.children)},n))},qc=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===l)?(r=M.cloneDeep(a))==null?void 0:r.filter(i=>(i==null?void 0:i.id)!==l):(a=a==null?void 0:a.map(n=>(n.children=qc(n==null?void 0:n.children,l),n)),a)},Wc=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===(l==null?void 0:l.id))?(r=M.cloneDeep(a))==null?void 0:r.map(i=>((i==null?void 0:i.id)===(l==null?void 0:l.id)&&(i=l),i)):(a=a==null?void 0:a.map(n=>(n.children=Wc(n==null?void 0:n.children,l),n)),a)},Gc=(a,l)=>{var r;return a!=null&&a.find(n=>{var i;return(n==null?void 0:n.id)===((i=l==null?void 0:l.contents)==null?void 0:i.id)})?(r=M.cloneDeep(a))==null?void 0:r.map(i=>{var o;return(i==null?void 0:i.id)===((o=l==null?void 0:l.contents)==null?void 0:o.id)&&(i=l==null?void 0:l.contents),i}):(a=a==null?void 0:a.map(n=>(n.children=Gc(n==null?void 0:n.children,l),n)),a)},Kc=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===(l==null?void 0:l.id))?(r=M.cloneDeep(a))==null?void 0:r.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(n=>(n.children=Kc(n==null?void 0:n.children,l),n)),a)},_r=[{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"}],B3=[{label:"查看",value:"view"},{label:"修改",value:"fix"},{label:"删除",value:"delete"},{label:"三维算例",value:"modelExample"}],N3=[{label:"新增",value:"add"}],Jn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:N3},{key:"background",label:"按钮背景色",type:"Color"}],Xn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:B3},{key:"textColor",label:"按钮颜色",type:"Color"}],A3={class:"table-content"},z3={class:"menu-config-wrap"},M3=["onClick"],I3={key:0,class:"viewport-wrap"},O3=["onClick"],L3={title:"选择显示列信息"},R3={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"}},$3=["title"],V3={class:"col-operate-wrap"},F3={key:0,class:"col-operate-radio-wrapper"},P3={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},j3={key:0,style:{display:"flex","justify-content":"center","align-items":"center"}},H3={class:"pop-view"},U3={class:"pop-wrapper"},q3={class:"file-list-pop"},W3=["title","onClick"],G3=["onClick"],K3=["onClick"],Y3={key:1,style:{display:"flex","justify-content":"flex-end",gap:"8px","margin-top":"8px"}},J3={class:"form-content"},X3={key:0,class:"dialog-footer"},Z3={class:"dialog-footer"},Q3={class:"ocr-dialog-content"},eh={class:"ocr-steps"},ah={key:0,class:"ocr-action-buttons"},lh={key:1,class:"ocr-preview-area"},rh={class:"ocr-file-grid"},nh={class:"file-thumbnail"},ih=["src"],oh={key:1,class:"thumbnail-placeholder"},th={class:"progress-svg",viewBox:"0 0 36 36"},sh=["stroke","stroke-width","stroke-dasharray"],ch={key:0,class:"progress-icon"},uh={key:1,class:"progress-icon"},dh=["onClick"],ph={class:"file-name"},fh={key:0,class:"ocr-recognize-button"},hh={key:2,class:"ocr-progress-section"},vh={key:3,class:"ocr-confirm-area"},mh={class:"ocr-preview-tip"},yh={class:"ocr-preview-table"},gh={style:{display:"flex","align-items":"center",gap:"8px"}},bh={key:0},kh={key:4,class:"ocr-success-area"},xh={key:0,class:"ocr-dialog-footer"},wh={class:"form-content"},_h={style:{width:"100%",margin:"0","font-size":"14px","font-weight":"600"}},Sh={style:{display:"flex","justify-content":"space-between",gap:"8px"}},Eh={style:{display:"flex"}},Ls="ss-ocr-upload-history",Ch="ss-ocr-cert-history-v1",Dh={__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},calculator:{type:Array,default:()=>[]},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 Zt;const r=e.ref([]),n=Vt(M.pinia),i=e.ref(null),o=e.ref(new Set),p=e.ref(new Map),c=e.ref(!1),u=e.ref([]),m=e.ref(new Map),g=new Map,y=e.ref(new Map),d=a,D=e.ref((d==null?void 0:d.allowSelect)??!0),w=e.ref(((Zt=d==null?void 0:d.config)==null?void 0:Zt.showIndex)??!0),q=e.ref(),A=e.ref(!0),j=e.ref(!1),O=e.ref([]),E={sortable:"switch",filterable:"switch",showSummary:"switch",operable:"switch",fixed:"radio"},_=e.ref([{label:"排序",value:"sortable",checked:!1},{label:"合计",value:"showSummary",checked:!1},{type:"radio",label:"固定",value:"fixed",checked:"",options:[{label:"无",value:!1},{label:"左",value:"left"},{label:"右",value:"right"}]}]),x=le.useOriginalState(M.pinia);let b="$R";const{originalPath:S}=M.storeToRefs(x),I=S.value,R=e.computed(()=>{var v;const f=(v=le.getAllLeafNodes(W.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 f.length>0?f.every(z=>!!(z!=null&&z.sortable)):!1});e.computed(()=>{var v;return(v=W.value)==null?void 0:v.every(z=>z==null?void 0:z.filterable)}),e.computed(()=>{var v;return(v=W.value)==null?void 0:v.every(z=>z==null?void 0:z.operable)});const re=e.ref(!0),X=e.ref([]),me=e.reactive({column:{},status:!1,text:"合计"}),ue=e.reactive({currentPage:1,pageSize:10,total:0,pageSizes:[5,10,20]}),U=l,W=e.ref([]),Z=e.ref([]),ae=e.ref([]),ve=e.reactive({prop:"",order:null}),ze=e.ref([]),te=e.ref(!1),N=e.ref(!1),se=e.ref(null),{isUseBackdrop:G,initTrackFileType:fe,getFileExtension:we,setData:_e,getFileInfo:qe,getFilesInfo:ra}=Do.useThreeSystem(),P=e.ref([]),Ke=e.ref(!1),Me=e.ref(),Le=M.useMenuState(),{importLoading:Ie,activeMenuPath:de,contentLoading:De,linkMenuInfo:Xe}=M.storeToRefs(Le),Ea=le.useTableComp(M.pinia),Ge=M.useModelComp(M.pinia),$=ti(M.pinia),{extraContents:V,cacheUpdatingData:ee,tableViewContents:ce,tableLoading:he,pageMapState:pa,lockingPage:ia}=M.storeToRefs(Ge),{selectTab:Ve}=M.storeToRefs($),{compType:ya,hasEditable:Ca}=dc.useRole(),Ce=e.ref([]),Fa=e.ref([]),Ta=e.ref(new Map);e.ref(!1);const fa=e.ref("");e.ref();const ja=e.ref(!0),sa=e.ref(0),Pe=e.ref(!0),ma=e.ref(""),Qe=e.ref(!1),Oe=e.ref(null);e.ref([]);const $e=e.ref({label:"查看三维模型"}),ne=e.ref(!1),We=e.ref(),na=e.ref([]),va=e.ref([]),Ae=e.ref(!1),Be=e.ref([]),Ye=e.ref([]),Ee=e.ref([]),ye=e.ref([]),$a=e.ref({dialogShow:!1,dialogTitle:""}),wl=()=>{$a.value.dialogShow=!1,$a.value.dialogTitle=""},Qa=f=>{console.log("Received signature data:",f),$a.value.dialogShow=!1},Pl=e.ref([]),gl=()=>{try{const f=localStorage.getItem(Ls),v=f?JSON.parse(f):[];Pl.value=Array.isArray(v)?v:[]}catch{Pl.value=[]}},jl=()=>{try{localStorage.setItem(Ls,JSON.stringify(Pl.value||[]))}catch{}},al=f=>{var ie,oe,K;if(!f)return;const v=f.url||((ie=f==null?void 0:f.uploadResult)==null?void 0:ie.url)||"",z=f.name||((oe=f==null?void 0:f.uploadResult)==null?void 0:oe.name)||((K=f==null?void 0:f.uploadResult)==null?void 0:K.fileName)||"";if(!v&&!z)return;const L={name:z,url:v,ts:Date.now()},H=String(L.name||"").trim().toLowerCase(),T=(Pl.value||[]).findIndex(ke=>String((ke==null?void 0:ke.name)||"").trim().toLowerCase()===H);T>-1&&Pl.value.splice(T,1),Pl.value.unshift(L),Pl.value.length>20&&(Pl.value=Pl.value.slice(0,20)),jl()};gl();const Hl=(f,v)=>`${Ch}:${String(f??"")}:${String(v??"")}`,Wa=(f,v)=>{try{const z=sessionStorage.getItem(Hl(f,v)),L=z?JSON.parse(z):[];return Array.isArray(L)?L:[]}catch{return[]}},Gl=(f,v,z)=>{try{sessionStorage.setItem(Hl(f,v),JSON.stringify(Array.isArray(z)?z:[]))}catch{}},Kl=(f,v,z)=>{if(!v)return;const L=Wa(f,v),H=[z,...L||[]].filter(Boolean).slice(0,1);return Gl(f,v,H),H},Zl=(f,v,z)=>{if(!v||!z)return;const L=Hl(f,v),H=Hl(f,z);try{const T=sessionStorage.getItem(L);if(!T)return;const ie=(()=>{try{const ke=JSON.parse(T);return Array.isArray(ke)?ke:[]}catch{return[]}})(),oe=Wa(f,z),K=[...ie,...oe||[]].filter(Boolean).sort((ke,ge)=>Number((ge==null?void 0:ge.ts)||0)-Number((ke==null?void 0:ke.ts)||0)).slice(0,1);sessionStorage.setItem(H,JSON.stringify(K)),sessionStorage.removeItem(L)}catch{}},Sl=e.ref(!1),dr=e.ref(!1),ga=e.ref([]),il=e.ref(null);e.ref(!1),e.ref([]),e.ref(""),e.ref("");const fl=e.ref(!1),Bl=e.ref([]),Ha=e.ref(1),Sa=e.ref(new Map),ll=e.ref(new Map),Te=e.ref(0),oa=e.ref(!1),Ka=e.ref([]),pe=e.ref([]),_a=f=>{var v;try{const z=(v=le.getAllLeafNodes(W.value)||[])==null?void 0:v.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate");return(z==null?void 0:z.find(L=>(L==null?void 0:L.prop)===f||(L==null?void 0:L.label)===f))||null}catch{return null}},Pa=f=>{const v=_a(f),z=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"Input";return pl.getComponent(z)||pl.getComponent("Input")},ul=e.ref([]),Ol=e.ref(null),ca=e.ref([]),Xa=e.ref(null),ua=e.ref(""),wa=e.ref(!1),Ba=e.ref([]),hl=e.ref(""),Fe=e.ref(!1),bl=e.ref([]),tr=e.ref([]),xr=e.ref([]),Ra=e.ref(null),kl=e.ref([]),Ml=e.ref("");e.computed(()=>{var f;try{const v=(f=le.getAllLeafNodes(W.value)||[])==null?void 0:f.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate"),z=new Map;return v==null||v.forEach(L=>{L!=null&&L.label&&(L!=null&&L.prop)&&z.set(L.label,L.prop)}),z.get("编号")||""}catch{return""}});const Oa=e.computed(()=>{var f;try{const v=(f=le.getAllLeafNodes(W.value)||[])==null?void 0:f.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate"),z=new Map;return v==null||v.forEach(L=>{L!=null&&L.label&&(L!=null&&L.prop)&&z.set(L.label,L.prop)}),z.get("名称")||""}catch{return""}}),aa=e.computed(()=>{var f;try{const v=(f=le.getAllLeafNodes(W.value)||[])==null?void 0:f.filter(L=>(L==null?void 0:L.type)!=="operate"&&(L==null?void 0:L.label)!=="操作"&&(L==null?void 0:L.prop)!=="operate"),z=new Map;return v==null||v.forEach(L=>{L!=null&&L.label&&(L!=null&&L.prop)&&z.set(L.label,L.prop)}),z.get("制造厂")||""}catch{return""}}),Rl=()=>{Fe.value=!1,bl.value=[],tr.value=[],xr.value=[],Ra.value=null,kl.value=[],Ml.value=""},Yr=f=>f==null?!1:typeof f=="string"?f.trim()!=="":Array.isArray(f)?f.length>0:!0,Jr=(f,v)=>{const z=(f==null?void 0:f.ocrRow)||{};for(const H of Object.keys(z))H==="id"||H==="_isOCRRow"||H==="_ocrTableId"||Yr(z[H])&&(v[H]=z[H]);const L=Fa.value.find(H=>H.id===v.id);if(L)for(const H of Object.keys(z))H==="id"||H==="_isOCRRow"||H==="_ocrTableId"||Yr(z[H])&&(L[H]=z[H]);Ta.value&&Ta.value.set(v.id,v),Kl(d==null?void 0:d.index,v.id,f==null?void 0:f.versionItem),tr.value=[...tr.value||[],JSON.parse(JSON.stringify(v))]},vn=async(f,v=null)=>{var z,L,H,T,ie,oe,K;try{const ke=(z=le.getAllLeafNodes(W.value)||[])==null?void 0:z.filter(ka=>(ka==null?void 0:ka.type)!=="operate"&&(ka==null?void 0:ka.label)!=="操作"&&(ka==null?void 0:ka.prop)!=="operate"),ge=new Map;ke==null||ke.forEach(ka=>{ka!=null&&ka.label&&(ka!=null&&ka.prop)&&ge.set(ka.label,ka.prop)});const Je=ge.get("系统编号")||ge.get("编号");if(!Je){console.warn("未找到系统编号字段,跳过向检校记录表插入数据");return}const Ue=v||Ra.value;if((Array.isArray(Ue==null?void 0:Ue.result)?Ue.result:[]).length===0){console.warn("OCR识别结果为空,跳过向检校记录表插入数据");return}for(let ka=0;ka<f.length;ka++){const Na=f[ka],Aa=Na[Je];if(!Aa){console.warn(`第 ${ka+1} 条匹配行缺少系统编号,跳过`);continue}const la=`设备管理/试验设备/${Aa}`,ol=await M.getPageDataApi({platId:parseInt((L=Nl.value)==null?void 0:L.plat_id),pageName:la});if(!((H=ol==null?void 0:ol.data)!=null&&H.result)||!Array.isArray(ol.data.result)){console.warn(`未找到详情页数据: ${la}`);continue}const xa=ol.data.result.find(ha=>(ha==null?void 0:ha.property_name)==="校检记录");if(!xa){console.warn(`详情页 ${la} 中未找到校检记录表`);continue}const tl=(T=xa.contents)==null?void 0:T.find(ha=>(ha==null?void 0:ha.key)&&ha.key.startsWith("content_"));if(!tl||!tl.key){console.warn("校检记录表中未找到 content item");continue}const be=tl.key,Va=Array.isArray(tl.value)?tl.value:[];if(Va.length>=5){const B=[...Va].sort((za,Ua)=>{const sl=Number((za==null?void 0:za.create_time)||0),Ga=Number((Ua==null?void 0:Ua.create_time)||0);return sl-Ga})[0];B!=null&&B.id&&await M.pageBatchDeleteApi({platId:parseInt((ie=Nl.value)==null?void 0:ie.plat_id),changeContents:[{tableName:be,tableContents:[{id:B.id}]}]})}const ba=(oe=ke==null?void 0:ke.find(ha=>(ha==null?void 0:ha.label)==="证书附件"))==null?void 0:oe.prop,Ya=String(Date.now()),Ia={id:Ya},Ne=Va[0]||{},Q=new Date().toISOString().split("T")[0];if(Object.keys(Ne||{}).forEach(ha=>{if(ha!=="id"){if(ha==="证书附件"){Ia[ha]="";return}if(ha==="校检日期"||ha==="检校日期"){Ia[ha]=Na[ha]||Na.校检日期||Na.检校日期||Q;return}if(["校检周期","检校周期","校检结果","检校结果","计量状态","依据文件","证书编号"].includes(ha)){Ia[ha]=Na[ha]??"";return}Ia[ha]=Na[ha]??""}}),ba&&Na[ba]){const ha=Na[ba];if(Array.isArray(ha)&&ha.length>0)Ia.证书附件=JSON.stringify(ha.map(B=>({url:(B==null?void 0:B.url)||"",name:(B==null?void 0:B.name)||(B==null?void 0:B.fileName)||"",fileName:(B==null?void 0:B.fileName)||(B==null?void 0:B.name)||""})).filter(B=>B.url||B.name));else if(typeof ha=="string")try{const B=JSON.parse(ha);Ia.证书附件=ha}catch{Ia.证书附件=JSON.stringify([{url:ha,name:ha,fileName:ha}])}}console.log(be,"tableName","inspectionRecordRow",Ia),await M.pageBatchAddApi({platId:parseInt((K=Nl.value)==null?void 0:K.plat_id),changeContents:[{tableName:be,tableContents:[Ia]}]});const je=xa==null?void 0:xa.object_id;if(je&&Ya){const ha=ba&&Na[ba]?Na[ba]:null;let B=[],za="",Ua=!1;if(Array.isArray(ha)&&ha.length>0){B=ha.map(dl=>({name:(dl==null?void 0:dl.name)||(dl==null?void 0:dl.fileName)||"",url:(dl==null?void 0:dl.url)||""})).filter(dl=>dl.url||dl.name);const Ga=ha[0];za=(Ga==null?void 0:Ga.url)||"";const Da=(Ga==null?void 0:Ga.name)||(Ga==null?void 0:Ga.fileName)||"";Ua=String(Da).toLowerCase().endsWith(".pdf")||String(za).toLowerCase().endsWith(".pdf")}else if(typeof ha=="string")try{const Ga=JSON.parse(ha);Array.isArray(Ga)?(B=Ga.map(Da=>({name:(Da==null?void 0:Da.name)||(Da==null?void 0:Da.fileName)||"",url:(Da==null?void 0:Da.url)||""})).filter(Da=>Da.url||Da.name),B.length>0&&(za=B[0].url||"",Ua=String(B[0].name).toLowerCase().endsWith(".pdf")||String(za).toLowerCase().endsWith(".pdf"))):(za=ha,Ua=String(ha).toLowerCase().endsWith(".pdf"))}catch{za=ha,Ua=String(ha).toLowerCase().endsWith(".pdf")}const sl={ts:Date.now(),versionId:String(Date.now())+"_"+String(ka),label:new Date().toLocaleString(),certType:Na.证书类型||"",certNo:Na.证书编号||"",fileType:Ua?"pdf":"image",sourceUrl:Ua?za:"",images:B};Kl(je,Ya,sl)}}}catch(ke){console.error("向校检记录表插入OCR识别结果失败:",ke),Ja.ElMessage.error("向校检记录表插入数据失败,请查看控制台")}},en=f=>{const v=Array.isArray(f)?f:bl.value||[];if(v.length===0){Rl();return}if(v.find(T=>(T==null?void 0:T.__decision)==="replace"&&!(T!=null&&T.selectedTargetId))){Ja.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}v.forEach(T=>{var oe;const ie=T==null?void 0:T.__decision;if(!(!ie||ie==="skip")){if(ie==="add"){Kl(d==null?void 0:d.index,(oe=T==null?void 0:T.ocrRow)==null?void 0:oe.id,T==null?void 0:T.versionItem),xr.value=[...xr.value||[],T.ocrRow];return}if(ie==="replace"){const K=T==null?void 0:T.selectedTargetId,ke=(Ce.value||[]).find(ge=>String(ge==null?void 0:ge.id)===String(K));if(!ke)return;Jr(T,ke)}}}),(tr.value||[]).length>0&&(Ce.value=[...Ce.value||[]]),(xr.value||[]).length>0&&(Ce.value=[...Ce.value||[],...xr.value||[]],Fa.value=[...Fa.value||[],...xr.value||[]],(xr.value||[]).forEach(T=>{var ie,oe;return(oe=(ie=Ta.value)==null?void 0:ie.set)==null?void 0:oe.call(ie,T.id,T)})),Sr.value=Ce.value;const L=tr.value||[],H=xr.value||[];if(L.length>0&&(U("change",{buttonName:"编辑",singleContent:L,content:Ce.value,relatedContents:d==null?void 0:d.related,index:d==null?void 0:d.index,parentTableId:d==null?void 0:d.parentTableId,columns:W.value,name:d==null?void 0:d.compName}),vn(L)),H.length>0){const T=Ra.value;U("change",{buttonName:"OCR批量新增",content:Ce.value,index:d==null?void 0:d.index,parentTableId:d==null?void 0:d.parentTableId,column:W.value,ocrRows:H,relatedContents:d==null?void 0:d.related,uploadedFiles:(Array.isArray(T==null?void 0:T.result)?T.result:[]).map(ie=>(Array.isArray(ie==null?void 0:ie.图片信息)?ie.图片信息:[]).map(oe=>({url:(oe==null?void 0:oe.url)||"",name:(oe==null?void 0:oe.name)||"",fileName:(oe==null?void 0:oe.name)||""})).filter(oe=>oe.url)),ocrResult:T,matchedCount:(L||[]).length,newCount:(H||[]).length})}Ja.ElMessage.success("已提交候选处理结果"),Rl()},Ar=Nc(),Re=e.computed(()=>Ar.getConfig()),lr=e.ref(),Yl=e.ref(),an=Ec(M.pinia),Sr=e.ref(),Jl=e.ref(0),Er=M.useUnit(M.pinia),{selectIndex:Xl,selectMenu:$l,selectTitle:nr}=M.storeToRefs(Er),{selectString:Ql}=M.storeToRefs(an),Ul=M.useLoginState(M.pinia),{loginUserInfo:Nl}=M.storeToRefs(Ul),Vr=e.ref(720),er=e.ref(!1),Ur=e.ref(!1),Br=e.ref([]),Tr=e.ref(),gn=e.ref(!0),Sn=e.ref(!0);e.ref([]);const Cn=e.inject("contentRef");e.provide("contentRef",Cn),e.provide("getSuggestListForCell",Ku),e.provide("getSuggestLoadingForCell",(f,v)=>{const z=`${f==null?void 0:f.id}:${(v==null?void 0:v.prop)||(v==null?void 0:v.property)}`;return y.value.get(z)||!1}),e.watch(()=>{var f;return(f=Ce.value)==null?void 0:f.length},f=>{ue.total=f}),e.watch(()=>ce.value,async()=>{var v,z,L,H,T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la;if(((v=ce.value)==null?void 0:v.length)===0||!((z=d==null?void 0:d.itemData)!=null&&z.find(ol=>(ol==null?void 0:ol.key)==="columnPath"))||!((L=d==null?void 0:d.itemData)!=null&&L.find(ol=>(ol==null?void 0:ol.key)==="pageColumn")))return;let f=(ke=(K=(oe=(ie=(T=(H=d==null?void 0:d.itemData)==null?void 0:H.find(ol=>(ol==null?void 0:ol.key)==="pageColumn"))==null?void 0:T.contents)==null?void 0:ie.split("["))==null?void 0:oe[1])==null?void 0:K.split("]"))==null?void 0:ke[0];((ea=(Ue=(Je=(ge=d==null?void 0:d.itemData)==null?void 0:ge.find(ol=>(ol==null?void 0:ol.key)==="pageColumn"))==null?void 0:Je.contents)==null?void 0:Ue.split("["))==null?void 0:ea[0])+((Na=(ka=ce.value)==null?void 0:ka.find(ol=>(ol==null?void 0:ol.key)===f))==null?void 0:Na.value),(la=(Aa=d==null?void 0:d.itemData)==null?void 0:Aa.find(ol=>(ol==null?void 0:ol.key)==="pageGroup"))==null||la.contents,Xt(compData,d.allMapContents)},{deep:!0});const mn=f=>{var z,L,H,T,ie;const v=(L=(z=W.value)==null?void 0:z.filter(oe=>oe==null?void 0:oe.mainKey))==null?void 0:L.map(oe=>oe==null?void 0:oe.prop);if(v.length===0){const oe=(H=W.value)==null?void 0:H.map(K=>K==null?void 0:K.prop);return(T=oe==null?void 0:oe.map(K=>f==null?void 0:f[K]))==null?void 0:T.join("|")}return(ie=v==null?void 0:v.map(oe=>f==null?void 0:f[oe]))==null?void 0:ie.join("|")},On=f=>{var oe,K,ke,ge,Je;const v=(K=(oe=W.value)==null?void 0:oe.filter(Ue=>Ue==null?void 0:Ue.required))==null?void 0:K.map(Ue=>Ue==null?void 0:Ue.prop),z=[];if(f==null||f.forEach(Ue=>{v==null||v.forEach(ea=>{const ka=Ue[ea];(ka==null||ka==="")&&(z.includes(ea)||z.push(ea))})}),z.length>0)return Ja.ElMessage.warning(`请填写必填项:${z.join("、")}`);const L=new Map,H=new Map;(ke=Ce.value)==null||ke.forEach(Ue=>{const ea=mn(Ue);L.set(ea,Ue)}),f==null||f.forEach(Ue=>{const ea=mn(Ue);H.set(ea,Ue)});const T=f==null?void 0:f.filter(Ue=>L.has(mn(Ue))),ie=(ge=Ce.value)==null?void 0:ge.filter(Ue=>H.has(mn(Ue)));return(T==null?void 0:T.length)>0&&(J.columns=(Je=W.value)==null?void 0:Je.filter(Ue=>(Ue==null?void 0:Ue.label)!=="操作"),J.existRows=ie,J.tableData=T,J.show=!0),J.newRows=f==null?void 0:f.filter(Ue=>{const ea=mn(Ue);return!L.has(ea)}),J.newRows},rn=e.ref(""),Dn=e.ref(null),Vn=async()=>{var f,v,z,L,H,T;try{const ie=await M.quoteApi({related:[{menus:de.value,groups:d==null?void 0:d.compName}],platId:parseInt((f=Nl.value)==null?void 0:f.plat_id)});if(((v=ie==null?void 0:ie.data)==null?void 0:v.code)===200){Dn.value=(z=ie==null?void 0:ie.data)==null?void 0:z.result;const oe=(L=W.value)==null?void 0:L.map(ge=>(ge==null?void 0:ge.prop)||(ge==null?void 0:ge.label)),K=nn(oe,(H=ie==null?void 0:ie.data)==null?void 0:H.result),ke=K==null?void 0:K.flatMap(ge=>ge==null?void 0:ge.quote);(ke==null?void 0:ke.length)>0&&(rn.value=(T=ke==null?void 0:ke.map(ge=>ge==null?void 0:ge.menus))==null?void 0:T.join("、"))}}catch(ie){throw new Error(ie)}};function nn(f,v){var z;return(z=v.filter(L=>L.struct&&Array.isArray(L.struct)?L.struct.some(H=>H.words&&Array.isArray(H.words)?H.words.some(T=>f.includes(T)):!1):!1))==null?void 0:z.map(L=>{const H={...L};return H.struct&&Array.isArray(H.struct)&&(H.struct=H.struct.filter(T=>T.words&&Array.isArray(T.words)?T.words.some(ie=>f.includes(ie)):!1)),H})}const Fn=async(f,v)=>{var z,L;try{Dn.value||await Vn();const H=v==null?void 0:v.map(ie=>{const oe=Object.keys(ie),K={};return oe.forEach((ke,ge)=>{K[f[ge]]=ie[ke]}),K}),T=On(H);if(!T||(T==null?void 0:T.length)===0)return;J.show||await He(T)}catch(H){throw Ja.ElMessage.error("数据导入处理失败"),await M.pageBatchAddApi({platId:parseInt((z=Nl==null?void 0:Nl.value)==null?void 0:z.plat_id),changeContents:[{tableName:"log",tableContents:[{id:"1",request_method:"Post",request_url:"",request_param:JSON.stringify(t1),request_result:JSON.stringify(H),is_delete:!1,request_table:(L=d==null?void 0:d.related)==null?void 0:L.find(T=>T==null?void 0:T.includes("content")),request_type:"error"}]}]}),new Error(H)}},zr=async f=>{var T,ie,oe,K,ke,ge,Je;let v=ae.value;v!=null&&v.find(Ue=>(f==null?void 0:f.key)===(Ue==null?void 0:Ue.key))&&(v=v==null?void 0:v.filter(Ue=>(f==null?void 0:f.key)!==(Ue==null?void 0:Ue.key))),v.push({key:f==null?void 0:f.key,value:[(ie=f==null?void 0:f.value)==null?void 0:ie[((T=f==null?void 0:f.value)==null?void 0:T.length)-1]]});let z=ye.value;z=z==null?void 0:z.map(Ue=>{var ea,ka;return(Ue==null?void 0:Ue.type)==="Select"&&(f==null?void 0:f.key)===(Ue==null?void 0:Ue.prop)&&Array.isArray(Ue.value)&&(ea=Ue.value)!=null&&ea.every(Na=>typeof Na=="string")&&(Ue.selectValue=(ka=v==null?void 0:v.find(Na=>(Na==null?void 0:Na.key)===(Ue==null?void 0:Ue.prop)))==null?void 0:ka.value),Ue});let L=(K=(oe=z==null?void 0:z.find(Ue=>(Ue==null?void 0:Ue.prop)===(f==null?void 0:f.key)))==null?void 0:oe.optionUrl)==null?void 0:K.menuId,H=z==null?void 0:z.find(Ue=>(Ue==null?void 0:Ue.prop)===(f==null?void 0:f.key));if(L){let Ue=await Nt(H==null?void 0:H.optionUrl,L),ea,ka=X.value,Na=(Je=(ge=(ke=ye.value)==null?void 0:ke.find(Aa=>{var la;return(la=H==null?void 0:H.optionUrl)==null?void 0:la.menuId}))==null?void 0:ge.selectValue)==null?void 0:Je[0];if(Ue==null||Ue.forEach(Aa=>{var la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne;if(L){let Q=(ol=(la=ye.value)==null?void 0:la.find(ha=>{var B,za;return((B=H==null?void 0:H.optionUrl)==null?void 0:B.menuId)===((za=ha==null?void 0:ha.optionUrl)==null?void 0:za.menuId)}))==null?void 0:ol.prop,je=(tl=(xa=z==null?void 0:z.find(ha=>(ha==null?void 0:ha.prop)===Q))==null?void 0:xa.selectValue)==null?void 0:tl[0];Q!=null&&Q.includes("·")&&(Q=(be=Q==null?void 0:Q.split("·"))==null?void 0:be[0],je=(Ia=(Ya=(ba=f==null?void 0:f.value)==null?void 0:ba[((Va=f==null?void 0:f.value)==null?void 0:Va.length)-1])==null?void 0:Ya.split(" "))==null?void 0:Ia[0]),ka!=null&&ka.find(ha=>(ha==null?void 0:ha.value)===Na)?ea=(Ne=ka==null?void 0:ka.find(ha=>(ha==null?void 0:ha.value)===Na))==null?void 0:Ne.objectValue:Aa[Q]===je&&(ea=Aa)}}),ea){let Aa=z;Aa=Aa==null?void 0:Aa.map(la=>{var ol,xa,tl,be,Va,ba;return L&&(ea!=null&&ea[la==null?void 0:la.prop])&&ma.value==="新增"&&(la==null?void 0:la.prop)!==(H==null?void 0:H.prop)?la.value=(ea==null?void 0:ea[la==null?void 0:la.prop])||(ea==null?void 0:ea[(be=(tl=(xa=(ol=la==null?void 0:la.optionUrl)==null?void 0:ol.groupSelect)==null?void 0:xa[1])==null?void 0:tl.replaceAll("[",""))==null?void 0:be.replaceAll("]","")]):la.value=(ba=(Va=ye.value)==null?void 0:Va.find(Ya=>(Ya==null?void 0:Ya.prop)===(la==null?void 0:la.prop)))==null?void 0:ba.value,la}),ye.value=Aa}}ae.value=v},An=async(f,v)=>{var z,L,H,T,ie;if((z=f==null?void 0:f.toString())!=null&&z.includes(".txt")||(L=f==null?void 0:f.toString())!=null&&L.includes(".cpt")||(H=f==null?void 0:f.toString())!=null&&H.includes(".cyd")){const oe=await Ja.axios.get(f,{responseType:"blob",headers:{"Content-Type":"application/json"}}),K=new Blob([oe.data],{type:"application/octet-stream;charset=UTF-8"});let ke=URL.createObjectURL(K);Me.value=[{name:(ie=f==null?void 0:f.split("/"))==null?void 0:ie[((T=f==null?void 0:f.split("/"))==null?void 0:T.length)-1],blobUrl:ke}],Ke.value=!0}else Array.isArray(v)&&(v==null?void 0:v.length)>0&&U("routeUrl",{isEdit:!1,routerUrl:v})};e.onBeforeUnmount(()=>{Sn.value=!1;let f=Jl.value;Jl.value=f+1});const Tn=e.reactive({prop:"",order:null}),Po=e.computed(()=>{const f=(Ce.value??[]).slice(),v=Tn.prop||ve.prop,z=Tn.order||ve.order;if(!v||!z)return f;const L=z==="ascending",H=ie=>{if(v)return ie&&Object.prototype.hasOwnProperty.call(ie,v)?ie[v]:v.includes(".")?v.split(".").reduce((oe,K)=>oe==null?oe:oe[K],ie):ie==null?void 0:ie[v]},T=ie=>{if(ie==null)return{ok:!1,value:NaN};if(typeof ie=="number")return{ok:Number.isFinite(ie),value:ie};const oe=String(ie).trim();if(oe==="")return{ok:!1,value:NaN};const K=oe.replace(/[,\s]/g,"");if(!/^[+-]?(\d+\.?\d*|\.\d+)$/.test(K))return{ok:!1,value:NaN};const ke=Number(K);return{ok:Number.isFinite(ke),value:ke}};return f.sort((ie,oe)=>{const K=H(ie),ke=H(oe);if(K==null&&ke==null)return 0;if(K==null)return L?-1:1;if(ke==null)return L?1:-1;const ge=T(K),Je=T(ke);if(ge.ok&&Je.ok)return L?ge.value-Je.value:Je.value-ge.value;const Ue=be=>{if(be==null)return{ok:!1,value:NaN};const Va=String(be).trim();if(Va==="")return{ok:!1,value:NaN};const ba=Va.match(/^(-)?(\d+):(\d{1,2}):(\d{1,2})$/);if(!ba)return{ok:!1,value:NaN};const Ya=ba[1]?-1:1,Ia=Number(ba[2]),Ne=Number(ba[3]),Q=Number(ba[4]);return[Ia,Ne,Q].some(je=>Number.isNaN(je))?{ok:!1,value:NaN}:Ne>=60||Q>=60?{ok:!1,value:NaN}:{ok:!0,value:Ya*(Ia*3600+Ne*60+Q)}},ea=Ue(K),ka=Ue(ke);if(ea.ok&&ka.ok)return L?ea.value-ka.value:ka.value-ea.value;const Na=new Date(K).getTime(),Aa=new Date(ke).getTime(),la=!Number.isNaN(Na),ol=!Number.isNaN(Aa);if(la&&ol)return L?Na-Aa:Aa-Na;const xa=String(K),tl=String(ke);return L?xa.localeCompare(tl):tl.localeCompare(xa)})}),Ln=e.computed(()=>{var z;const f=(ue.currentPage-1)*ue.pageSize,v=f+ue.pageSize;return U("getSliceContLength",ue),(z=Po.value)==null?void 0:z.slice(f,v)}),jo=f=>{ue.currentPage=f,U("getSliceContLength",ue)},Ho=f=>{var L;ue.pageSize=f;const v=((L=Ce.value)==null?void 0:L.length)??0,z=f>0?Math.ceil(v/f):1;ue.currentPage>z&&(ue.currentPage=z||1,Ja.ElMessage.warning("当前页超出范围,已自动跳转到最后一页")),U("getSliceContLength",ue)},Uo=({prop:f,order:v})=>{Tn.prop=f,Tn.order=v,ue.currentPage=1};function lo(f){const v=[];function z(L,H=""){L.forEach(T=>{T.children&&T.children.length>0?z(T.children,T.prop):v.push(T.prop)})}return z(f),v}const ro=(f,v)=>{var oe,K,ke,ge;let z=(K=(oe=W.value)==null?void 0:oe.map(Je=>Je==null?void 0:Je.prop))==null?void 0:K.filter(Je=>Je!=="operate");((ke=W.value)==null?void 0:ke.some(Je=>{var Ue;return((Ue=Je==null?void 0:Je.children)==null?void 0:Ue.length)>0}))&&(z=lo((ge=W.value)==null?void 0:ge.filter(Je=>(Je==null?void 0:Je.prop)!=="operate")));let H;if(H=(f==null?void 0:f.length)===(z==null?void 0:z.length)?f:f.slice(0,z==null?void 0:z.length),!(H==null?void 0:H.every(Je=>z==null?void 0:z.find(Ue=>Je===Ue))))return Ja.ElMessage.error("导入的数据表头不匹配");Fn(H,v)},un=(f,v)=>{var H;const z=f==null?void 0:f.filter(T=>T!=="序号"),L=v==null?void 0:v.map(T=>{const ie=Object.entries(T);return ie.shift(),Object.fromEntries(ie)});Ge.setRefreshCurStructure(!1),((H=W.value)==null?void 0:H.length)===0||ro(z,L)},qo=(f,v,z,L)=>{const H=[],T=[],ie=ke=>Object.keys(ke).length;for(const ke in f)if(f[ke]!==void 0){const ge=f[ke],Je=[];for(const[Ue,ea]of Object.entries(ge))Je.push(ea),T.length<ie(ge)&&T.push(Ue);H.push(Je)}H.unshift(T);const oe=le.utils.aoa_to_sheet(H),K=le.utils.book_new();le.utils.book_append_sheet(K,oe,L),le.writeFileSync(K,`${v}.xlsx`),Br.value=[]},no=async(f,v,z,L=!1,H)=>{try{Ge.setRefreshCurStructure(!1)}catch(T){Ja.ElMessage.error(T)}},Wo=async(f,v)=>{await no()},Go=async(f,v)=>{await no("columnType",v,f,!1)},Ko=async({newRow:f,targetIndex:v})=>{var H;if(!Ca(d.config,{type:ya.TABLE}))return;const L=(ue.currentPage-1)*ue.pageSize+(v??0);f._isTemp=!0;try{(f.sort===void 0||f.sort===null||String(f.sort).trim()==="")&&(f.sort=ui(L,Ce.value||[]))}catch{}Ce.value.splice(L,0,f),await e.nextTick(),p.value.has(f.id)||p.value.set(f.id,M.cloneDeep(f)),Ce.value=(H=Ce.value)==null?void 0:H.map(T=>({...T,tableEditType:(T==null?void 0:T.id)===f.id?"edit":(T==null?void 0:T.tableEditType)??"text"})),o.value.add(f.id),er.value=!0},Yo=(f,v,z,L=[])=>(!Array.isArray(v)||v.length===0||v.forEach(H=>{const T=H==null?void 0:H.prop;if(!T)return;let ie=f==null?void 0:f[T];if(ie==null||String(ie).trim()==="")return;ie=String(ie);const oe=new Set([...(Array.isArray(z)?z:[]).filter(ge=>(ge==null?void 0:ge.id)!==(f==null?void 0:f.id)).map(ge=>ge==null?void 0:ge[T]).filter(ge=>ge!=null).map(ge=>String(ge)),...(Array.isArray(L)?L:[]).map(ge=>ge==null?void 0:ge[T]).filter(ge=>ge!=null).map(ge=>String(ge))]);if(!oe.has(ie))return;let K=1,ke="";for(;ke=`${ie}(${K})`,!!oe.has(ke);)K++;f[T]=ke}),f),Vi=async()=>{var H,T,ie,oe,K,ke,ge,Je;const f=Array.from(o.value||[]);if(f.length===0)return;const v=(T=le.getColumnChild((H=M.cloneDeep(W.value))==null?void 0:H.filter(Ue=>(Ue==null?void 0:Ue.label)!=="操作")))==null?void 0:T.filter(Ue=>(Ue==null?void 0:Ue.required)===!0);if((v==null?void 0:v.length)>0)for(let Ue=0;Ue<f.length;Ue++){const ea=f[Ue],ka=(ie=Ce.value)==null?void 0:ie.find(Na=>(Na==null?void 0:Na.id)===ea);if(ka)for(let Na=0;Na<v.length;Na++){const Aa=v[Na],la=Aa==null?void 0:Aa.prop,ol=(Aa==null?void 0:Aa.label)??la,xa=ka==null?void 0:ka[la];if(xa===""||xa===null||xa===void 0||Array.isArray(xa)&&xa.length===0){Ja.ElMessage.error(`${ol}不能为空`);let be={};be.id=ka==null?void 0:ka.id;const Va={fixContent:[be],buttonName:"修改",relatedContents:d==null?void 0:d.related,name:d==null?void 0:d.compName,columns:W.value};U("change",Va);return}}}const z=[],L=[];if(f.forEach(Ue=>{var ol;const ea=(ol=Ce.value)==null?void 0:ol.find(xa=>(xa==null?void 0:xa.id)===Ue);if(!ea)return;if(ea!=null&&ea._isTemp){const tl=(le.getAllLeafNodes(W.value)||[]).filter(Ne=>(Ne==null?void 0:Ne.mainKey)===!0||(Ne==null?void 0:Ne.isMainKey)===!0),be=Ce.value.findIndex(Ne=>(Ne==null?void 0:Ne.id)===Ue),Va=be>=0?be+1:Ce.value.length+1;Yo(ea,tl,Ce.value,z);const ba={id:Va.toString()};(ea==null?void 0:ea.sort)!==void 0&&(ea==null?void 0:ea.sort)!==null&&String(ea.sort).trim()!==""?ba.sort=String(ea.sort):ba.sort=ui(be>=0?be:Ce.value.length-1,Ce.value||[]),(le.getAllLeafNodes(W.value)||[]).filter(Ne=>(Ne==null?void 0:Ne.type)!=="operate"&&(Ne==null?void 0:Ne.label)!=="操作"&&(Ne==null?void 0:Ne.prop)!=="operate").forEach(Ne=>{const Q=Ne==null?void 0:Ne.prop;if(Q){const je=ea[Q];je!==void 0?ba[Q]=je??"":ba[Q]=""}}),z.push(ba);return}const Na=(le.getAllLeafNodes(W.value)||[]).filter(xa=>(xa==null?void 0:xa.type)!=="operate"&&(xa==null?void 0:xa.label)!=="操作"&&(xa==null?void 0:xa.prop)!=="operate"),Aa=new Set(Na.map(xa=>xa==null?void 0:xa.prop).filter(Boolean)),la={};for(const xa of Aa)Object.prototype.hasOwnProperty.call(ea,xa)&&(la[xa]=ea[xa]);L.push({id:ea.id,value:{tableData:la}})}),Ge.setTableLoading(d==null?void 0:d.index),L.length>0){const Ue=L.map(ka=>{const Na={id:ka.id,...ka.value.tableData};return delete Na._isOCRRow,delete Na._ocrTableId,delete Na._isTemp,delete Na.tableEditType,delete Na.index,Na}),ea=[{tableName:((oe=d==null?void 0:d.related)==null?void 0:oe.find(ka=>ka==null?void 0:ka.includes("content")))??"content_"+(d==null?void 0:d.index),tableContents:Ue}];try{await M.pageBatchUpdateApi({platId:parseInt((K=Nl.value)==null?void 0:K.plat_id),changeContents:ea})}catch(ka){Ja.ElMessage.error(((ge=(ke=ka==null?void 0:ka.response)==null?void 0:ke.data)==null?void 0:ge.message)||(ka==null?void 0:ka.message)||"保存失败"),Ge.setTableLoading(!1);return}}if(z.length>0){const Ue={fixContent:z,buttonName:"新增",relatedContents:d==null?void 0:d.related,name:d==null?void 0:d.compName,columns:W.value};U("change",Ue)}Ja.ElMessage.success("保存成功"),o.value.clear(),p.value.clear(),Ce.value=(Je=Ce.value)==null?void 0:Je.map(Ue=>({...Ue,tableEditType:"text"})),er.value=!1,Ge.setRefreshCurStructure(!0)},Jo=()=>{var v;const f=Array.from(o.value||[]);if(f.length===0){er.value=!1;return}f.forEach(z=>{var T,ie;const L=p.value.get(z),H=(T=Ce.value)==null?void 0:T.find(oe=>(oe==null?void 0:oe.id)===z);if(H!=null&&H._isTemp){Ce.value=Ce.value.filter(oe=>(oe==null?void 0:oe.id)!==H.id);return}if(L){const oe=(ie=Ce.value)==null?void 0:ie.findIndex(K=>(K==null?void 0:K.id)===z);oe!==-1&&(Ce.value[oe]={...Ce.value[oe],...L})}}),o.value.clear(),p.value.clear(),Ce.value=(v=Ce.value)==null?void 0:v.map(z=>({...z,tableEditType:"text"})),er.value=!1},ki=e.ref(!1),si=async f=>{var H,T,ie,oe;if(!er.value||f!=null&&f.isComposing||(f==null?void 0:f.key)!=="Enter")return;const v=f==null?void 0:f.target;if(((T=(H=v==null?void 0:v.tagName)==null?void 0:H.toLowerCase)==null?void 0:T.call(H))==="textarea")return;const L=document.getElementById("excel-table");L&&!L.contains(v)||((ie=v==null?void 0:v.blur)==null||ie.call(v),(oe=f.preventDefault)==null||oe.call(f),await e.nextTick(),await Pn())},Pn=async()=>{if(ee.value){er.value=!1;return}if(!ki.value){ki.value=!0;try{Array.from(o.value||[]).length>0?await Vi():er.value=!1}finally{Promise.resolve().then(()=>{ki.value=!1})}}},xi=f=>{Br.value=f},Xo=(f,v)=>{Tr.value===v?gn.value=!1:gn.value=!0,Tr.value=v==null?void 0:v.changeProp},io=f=>{if(!f)return;const{item:v,value:z}=f,L=ye.value.find(H=>H.prop==v.prop);L&&L.contents.push({label:z,value:z})},Qn=e.computed(()=>{var z,L,H;const f=(z=W.value)==null?void 0:z.some(T=>T==null?void 0:T.filterable);return document.documentElement.style.setProperty("--ssTable-header-filter-display",f?"inline-block":"none"),(H=(L=W.value)==null?void 0:L.filter(T=>(T==null?void 0:T.label)!=="操作"))==null?void 0:H.map(T=>({...T,filterable:!!(T!=null&&T.filterable),showSummary:!!(T!=null&&T.showSummary),operable:!!(T!=null&&T.operable),fixed:T==null?void 0:T.fixed}))}),Fi=async(f,v,z)=>{const L=M.cloneDeep(W.value);await e.nextTick();const H=L==null?void 0:L.map(ie=>(z==null?void 0:z.label)===(ie==null?void 0:ie.label)?{...ie,[v]:f}:ie),T=Wn(H);await As(d.index,T),W.value=H,Z.value=T},Wn=f=>{var H;const v=f||[];return((H=le.getAllLeafNodes(v)||[])==null?void 0:H.filter(T=>(T==null?void 0:T.prop)&&(T==null?void 0:T.type)!=="operate"&&(T==null?void 0:T.label)!=="操作"&&(T==null?void 0:T.prop)!=="operate")).map(T=>{const{prop:ie}=T;return U0(ie,T)})},Zo=async f=>{let v=await W0(d.index);v||(v=Wn(f)),Z.value=v},Qo=async(f,v)=>{const z=M.cloneDeep(W.value),L=ie=>Array.isArray(ie)?ie.map(oe=>{const K=Array.isArray(oe==null?void 0:oe.children)&&oe.children.length>0,ke={...oe};return(ke==null?void 0:ke.prop)==="operate"||(ke==null?void 0:ke.label)==="操作"||(ke==null?void 0:ke.type)==="operate"?(ke.sortable=!1,ke.filterable=!1,ke.operable=!1):ke.sortable=K?!1:!!f,K&&(ke.children=L(ke.children)),ke}):ie,H=L(z),T=Wn(H);await As(d.index,T),W.value=H,Z.value=T,await e.nextTick(),Jl.value=Jl.value+1},et=()=>{Qe.value=!1},at=f=>{U("clickTrigger",f)},oo=async f=>{var T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa;const v=f==null?void 0:f.row,z=f==null?void 0:f.rowData,L=f==null?void 0:f.suffix;if((T=v==null?void 0:v.toString())!=null&&T.includes(".urdf")||f!=null&&f.isUrdf||L!=null&&L.includes(".urdf")){if(v.includes(",")){Ja.ElMessage.error("当前版本仅允许单个urdf预览!");return}if(G(v)){const be={files:[qe(v)],data:{}};_e(be);return}Be.value=[{url:v,extension:we(v)}],N.value=!0,se.value={data:M.cloneDeep(z)},te.value=!0;return}let H=[];if((ie=v==null?void 0:v.toString())!=null&&ie.includes(".stl")||(oe=v==null?void 0:v.toString())!=null&&oe.includes(".STL")||(K=v==null?void 0:v.toString())!=null&&K.includes(".obj")||(ke=v==null?void 0:v.toString())!=null&&ke.includes(".mtl")){const tl=(ge=v==null?void 0:v.toString())==null?void 0:ge.split(","),be=ra(tl),Va=be==null?void 0:be[0];if(G(Va==null?void 0:Va.extension)){_e({files:be,data:{}});return}Be.value=be,N.value=!1,te.value=!0;return}if((Je=v==null?void 0:v.toString())!=null&&Je.includes(".stl")||(Ue=v==null?void 0:v.toString())!=null&&Ue.includes(".STL")||(ea=v==null?void 0:v.toString())!=null&&ea.includes(".obj")||(ka=v==null?void 0:v.toString())!=null&&ka.includes(".mtl")||L!=null&&L.includes(".stl")||L!=null&&L.includes(".STL")||L!=null&&L.includes(".obj")||L!=null&&L.includes(".mtl")){let tl,be=[],Va={};if(Array.isArray(v)?tl=v:tl=v==null?void 0:v.split(","),tl==null||tl.forEach(ba=>{ba.includes(".mtl")?be.push(ba):Va.blob=Va.blob?Va.blob+","+ba:ba}),(be==null?void 0:be.length)>0&&(Va.mtlBlobs=be),L&&(Va.suffix=L),(Aa=(Na=Object.values(Va))==null?void 0:Na[0])!=null&&Aa.includes("http:"))H.push(Va);else{const ba=new Blob([Va.blob],{type:"application/octet-stream;charset=UTF-8"});let Ya=URL.createObjectURL(ba),Ia="";(la=v==null?void 0:v.split("/"))==null||la.forEach((Ne,Q)=>{var je;Q===((je=v==null?void 0:v.split("/"))==null?void 0:je.length)-1&&(Ia=Ne)}),(ol=Va.blob)!=null&&ol.includes(".stl")&&(Ia=(Ia==null?void 0:Ia.replaceAll(">",""))+".urdf"),Me.value=[{name:Ia,blobUrl:Ya}],Ke.value=!0}}else{const tl=await Ja.axios.get(v,{responseType:"blob",headers:{"Content-Type":"application/json"}}),be=new Blob([tl.data],{type:"application/octet-stream;charset=UTF-8"});let Va=URL.createObjectURL(be),ba="";if((xa=v==null?void 0:v.split("/"))==null||xa.forEach((Ya,Ia)=>{var Ne;Ia===((Ne=v==null?void 0:v.split("/"))==null?void 0:Ne.length)-1&&(ba=Ya)}),G(ba)){const Ya=fe(ba),Ia=qe(v);_e({files:[Ia],data:{trackFileType:Ya}});return}Me.value=[{name:ba,blobUrl:Va}],Ke.value=!0}(H==null?void 0:H.length)>0&&n.setBlobUrls(H)},ci=f=>{var L,H,T,ie;if(f!=null&&f.downloadUrl)return f==null?void 0:f.name;const v=(ie=(L=f==null?void 0:f.url)==null?void 0:L.split("."))==null?void 0:ie[((T=(H=f==null?void 0:f.url)==null?void 0:H.split("."))==null?void 0:T.length)-1];return(f==null?void 0:f.name)+"."+v},wi=f=>{if(!f)return"未知文件";try{const L=ci(f);if(typeof L=="string"&&L.includes("."))return L}catch{}const v=(f==null?void 0:f.fileName)||(f==null?void 0:f.name)||"未知文件",z=(f==null?void 0:f.suffix)||"";return v.includes(".")?v:`${v}${z}`},to=f=>{if(f==null||typeof f=="number"||typeof f!="string")return f;const v=f.match(/^(\d+)\_(\d+)$/);if(!v)return f;const z=Number(v[1]),L=Number(v[2]);return!Number.isFinite(z)||!Number.isFinite(L)?f:String(z*1e3+L)},jn=f=>{if(f==null)return null;const v=String(f).trim();if(!v)return null;const z=Number(v);return Number.isFinite(z)?z:null},lt=f=>{if(f==null)return null;const v=String(f).trim();if(!v)return null;if(/^\d+$/.test(v)){const H=Number(v);return Number.isFinite(H)?v.length<=10?H*1e3:H:null}const z=v.includes("T")?v:v.replace(" ","T"),L=Date.parse(z);return Number.isFinite(L)?L:null},_i=(f,v=[])=>{const z=Array.isArray(f)?f.slice():[];if(z.length<=1)return z;const L=new Map((v||[]).map((ie,oe)=>[String(ie),oe])),H=z.some(ie=>jn(ie==null?void 0:ie.sort)!==null),T=z.map((ie,oe)=>({r:ie,idx:oe,id:String((ie==null?void 0:ie.id)??""),sortVal:jn(ie==null?void 0:ie.sort),createTimeMs:lt(ie==null?void 0:ie.create_time),prevIdx:L.has(String(ie==null?void 0:ie.id))?L.get(String(ie==null?void 0:ie.id)):Number.POSITIVE_INFINITY}));return T.sort((ie,oe)=>{if(H){const ge=ie.sortVal,Je=oe.sortVal;if(ge===null&&Je!==null)return 1;if(ge!==null&&Je===null)return-1;if(ge!==null&&Je!==null&&ge!==Je)return ge-Je}const K=ie.createTimeMs,ke=oe.createTimeMs;return K!==null&&ke!==null&&K!==ke?ke-K:K!==null&&ke===null?-1:K===null&&ke!==null?1:ie.prevIdx!==oe.prevIdx?ie.prevIdx-oe.prevIdx:ie.idx-oe.idx}),T.map(ie=>ie.r)},ui=(f,v=[])=>{const z=v==null?void 0:v[f-1],L=v==null?void 0:v[f],H=jn(z==null?void 0:z.sort),T=jn(L==null?void 0:L.sort);let ie=null;H!==null&&T!==null&&T>H?ie=(H+T)/2:H!==null?ie=H+1:T!==null?ie=Math.max(T-1,0):ie=(f??0)+1;const oe=Number(ie.toFixed(6));return String(Number.isFinite(oe)?oe:ie)},rt=async f=>{let v=null,z=null;if(f!=null&&f.id){const H=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});try{const T=await M.platformDownloadFile(f);v=URL.createObjectURL(T.data),z=wi(f)}finally{H.close()}}else if(f!=null&&f.downloadUrl){const H=await Si(),T=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),ie=await Ja.axios.post(f==null?void 0:f.url,null,{responseType:"blob",headers:{Authorization:H,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}).finally(()=>{T.close()}),oe=new Blob([ie.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(oe),z=f==null?void 0:f.name}else{const H=await M.platformDownloadFile({url:f==null?void 0:f.url});!f.url.toUpperCase().includes(".OBJ")&&!f.url.toUpperCase().includes(".STL")&&!f.url.toUpperCase().includes(".MTL")&&!f.url.toUpperCase().includes(".URDF")?(v=URL.createObjectURL(H.data),z=ci(f)):v=f==null?void 0:f.url}if(G(v)){const H={row:`${v}`,suffix:we(z)};oo(H);return}const L={name:z,blobUrl:v};Me.value=[L],Ke.value=!0},so=async f=>{let v=null,z=null;if(f!=null&&f.id){const T=await M.platformDownloadFile(f);v=URL.createObjectURL(T.data),z=wi(f)}else if(f!=null&&f.downloadUrl){const T=await Si(),ie=await Ja.axios.post(f==null?void 0:f.url,null,{responseType:"blob",headers:{Authorization:T,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}),oe=new Blob([ie.data],{type:"application/octet-stream;charset=UTF-8"});v=URL.createObjectURL(oe),z=f==null?void 0:f.name}else{const T=await M.platformDownloadFile({url:f==null?void 0:f.url});v=URL.createObjectURL(T.data),z=ci(f)}const L={name:z,blobUrl:v},H=document.createElement("a");H.href=L.blobUrl,H.download=L.name,H.style.display="none",document.body.appendChild(H),H.click(),setTimeout(()=>{document.body.removeChild(H)},100)},di=(f,v)=>{var L;if(Object.values(v).length===0)return;let z=f;return Object.values(v).find(H=>{var T,ie,oe;return((T=H==null?void 0:H.toString())==null?void 0:T.includes(".txt"))||((ie=H==null?void 0:H.toString())==null?void 0:ie.includes(".cpt"))||((oe=H==null?void 0:H.toString())==null?void 0:oe.includes(".obj"))})?z=[...f,$e.value]:(L=d==null?void 0:d.config)!=null&&L.allowMove&&(z=[...f,{label:"迁移"}]),z},Hn=()=>{j.value=!0},co=e.ref([]),Pi=async(f,v,z=!1)=>{var ie,oe,K,ke;if(!f)return;if(z){Ce.value=[...Ta.value.values()].filter(ge=>Object.values(ge).some(Je=>typeof Je=="string"?Je==null?void 0:Je.toLowerCase().includes(v==null?void 0:v.toLowerCase()):!1));return}let L={};for(let ge in f)(f==null?void 0:f[ge])!==""&&(L[ge]=f==null?void 0:f[ge]);if(JSON.stringify(L)==="{}"){Ce.value=Array.from(((ie=Ta.value)==null?void 0:ie.values())??[]);return}let H=(oe=d==null?void 0:d.related)==null?void 0:oe.find(ge=>ge==null?void 0:ge.includes("content_")),T=await M.getFillFind({platId:parseInt((K=Nl==null?void 0:Nl.value)==null?void 0:K.plat_id),tableName:H,params:L});T=(ke=T==null?void 0:T.data)==null?void 0:ke.result,Ce.value=T,Ge.setTableLoading(!1)},nt=e.computed(()=>{var v,z;return((z=(v=d==null?void 0:d.itemData)==null?void 0:v.find(L=>(L==null?void 0:L.key)==="isEdit"))==null?void 0:z.contents)??!0}),it=async f=>{var H,T,ie,oe,K,ke;if(!Ca(d.config,{type:ya.TABLE})||!(((T=(H=d==null?void 0:d.itemData)==null?void 0:H.find(ge=>(ge==null?void 0:ge.key)==="isEdit"))==null?void 0:T.contents)??!0))return;let z=(oe=(ie=u.value)==null?void 0:ie.find(ge=>{var Je;return(Je=ge==null?void 0:ge.key)==null?void 0:Je.includes("@EditRead")}))==null?void 0:oe.content;if((z==null?void 0:z.length)>0){let ge=Bs(z,f);if((ge==null?void 0:ge.length)>0)return}if(!f)return;((K=Array.from(o.value))==null?void 0:K.length)>0&&await Vi();const L=f==null?void 0:f.id;L!=null&&(o.value.clear(),p.value.clear(),p.value.has(L)||p.value.set(L,M.cloneDeep(f)),Ce.value=(ke=Ce.value)==null?void 0:ke.map(ge=>({...ge,tableEditType:(ge==null?void 0:ge.id)===L?"edit":"text"})),o.value.add(L),er.value=!0)},uo=async(f,v,z,L)=>{L!=null&&L.isExistChild&&U("clickMainKey",f,z,W.value)},ot=()=>{Ke.value=!1},tt=f=>{U("rowClick",f)};e.watch(()=>d.changedContent,()=>{var z,L;if(!d.changedContent)return;let f=(z=Ce.value)==null?void 0:z.map(H=>{var T;return H.id===((T=d.changedContent)==null?void 0:T.id)&&(H={...d.changedContent,id:d.changedContent.newId?d.changedContent.newId:d.changedContent.id},delete H.newId),H});const v=(L=d.itemData)==null?void 0:L.map(H=>((H==null?void 0:H.key)==="tableContents"&&(H.contents=f),H));Ce.value=f,U("contentChange",{contents:v,index:d.index}),U("change",{content:f,index:d==null?void 0:d.index,buttonName:"",id:d==null?void 0:d.index})},{deep:!0,immediate:!0});const st=()=>{},ct=async()=>{const f=de.value,v=sessionStorage.getItem("systemKey"),z=await le.getItemData(f,v,""),L=(z==null?void 0:z.find(oe=>(oe==null?void 0:oe.name)==="方法明细"))||(z==null?void 0:z[0]),H=(L==null?void 0:L.compData)||[],T=H==null?void 0:H.find(oe=>{const K=oe==null?void 0:oe.key;return K==="formContent"||K==="tableContents"});return T==null?void 0:T.contents},Si=async()=>{const v=Ja.Local.get("access-token");return v?`Bearer ${v}`:""},ut=async(f,{token:v,inputData:z}={})=>await Ja.axios.post(f,z,{headers:{Authorization:v}}).catch(H=>(Le.setImportLoading(!1),Promise.reject(H))),dt=f=>{var L;let v={};const z=[];return v.form={},(L=M.cloneDeep(f))==null||L.forEach((H,T)=>{var ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa;if((H==null?void 0:H.comp)==="Table"){(oe=(ie=H==null?void 0:H.compData)==null?void 0:ie.find(ba=>(ba==null?void 0:ba.key)==="header"))==null||oe.contents;let tl=(ge=(ke=(K=H==null?void 0:H.compData)==null?void 0:K.find(ba=>(ba==null?void 0:ba.key)==="tableContents"))==null?void 0:ke.contents)==null?void 0:ge.map(ba=>ba.slice(1));(Na=(ka=(ea=(Ue=(Je=H==null?void 0:H.compData)==null?void 0:Je.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:Ue.contents)==null?void 0:ea[0])==null?void 0:ka[0])==null||Na.label;let be=(la=(Aa=H==null?void 0:H.compData)==null?void 0:Aa.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:la.contents,Va=[];tl==null||tl.forEach(ba=>{let Ya=[];ba==null||ba.forEach((Ia,Ne)=>{var je;let Q={};((je=be[Ne])==null?void 0:je.label)!=="操作"&&(Q[be[Ne].label]=Ia,Ya.push(Q))}),Va.push(Ya)}),v[H.name]=Va}else{const tl=(xa=(ol=H.compData)==null?void 0:ol.find(be=>(be==null?void 0:be.key)==="formContent"))==null?void 0:xa.contents;tl==null||tl.forEach(be=>{var Va,ba;if(be.prop!==""){let Ya=be==null?void 0:be.value;Array.isArray(Ya)?Ya=((Va=Ya==null?void 0:Ya[0])==null?void 0:Va.oldUrl)||"http://222.92.178.198:62001/"+((ba=Ya==null?void 0:Ya[0])==null?void 0:ba.url):Ya=Ya.toString(),be={key:(be==null?void 0:be.prop)??(be==null?void 0:be.label),value:Ya},z.push(be)}})}}),v.form=le.getFormContents(z),v},s=f=>{const v=[],z=L=>{L&&typeof L=="object"&&!Array.isArray(L)?Object.values(L).forEach(z):v.push(L)};return z(f),v},t=async(f,v,z)=>{var be,Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl;Le.setImportLoading(!0),Ge.setFreshContent(!1);let L=await ct().catch(qa=>(Le.setImportLoading(!1),Promise.reject(qa)));L=L==null?void 0:L.filter(qa=>{var Tl;return((Tl=qa==null?void 0:qa.find(La=>La==null?void 0:La.id))==null?void 0:Tl.id)===(v==null?void 0:v.id)});let H=le.getEqualChild([(be=W.value)==null?void 0:be.filter(qa=>(qa==null?void 0:qa.label)!=="操作")]);const T=(ba=(Va=le.tableToForm(L,H))==null?void 0:Va[0])==null?void 0:ba.find(qa=>{const Tl=qa==null?void 0:qa.key;return Tl==="Interface"||Tl==="方法体"}),ie=T==null?void 0:T.value;if(!ie){console.log("未搜索到isMain, 缺少算法执行接口"),Le.setImportLoading(!1);return}const oe=W.value?le.getEqualChild([W.value]):[],K=oe.find(qa=>{const Tl=qa==null?void 0:qa.prop;return Tl==="Input1"||Tl==="输入数据.输入1"||Tl==="样本输入数据"}),ke=K==null?void 0:K.prop;let ge=v==null?void 0:v[ke];const Je=await Si().catch(qa=>(Le.setImportLoading(!1),Promise.reject(qa)));let Ue=!0,ea="";(Ya=W.value)==null||Ya.forEach(qa=>{(qa==null?void 0:qa.prop)===ke&&(Ue=!!(qa!=null&&qa.childPath),ea=qa==null?void 0:qa.childPath)});let ka="";if(Ue){let qa=(Ne=(Ia=W.value)==null?void 0:Ia.find(vl=>(vl==null?void 0:vl.isMainKey)===!0))==null?void 0:Ne.prop;ka=v==null?void 0:v[qa];let Tl=ea==null?void 0:ea.split(I),La=[];Tl==null||Tl.forEach((vl,zl)=>{(Tl==null?void 0:Tl.length)-1===zl&&La.push(ka),La.push(vl)}),La=La==null?void 0:La[0];let Ll=await le.getItemData(La,sessionStorage.getItem("systemKey"),""),nl=Ll==null?void 0:Ll.filter(vl=>(vl==null?void 0:vl.name)===ke);nl=nl==null?void 0:nl.map(vl=>{var zl;return vl.compData=(zl=vl==null?void 0:vl.compData)==null?void 0:zl.map(xl=>{var Cr;return(xl==null?void 0:xl.key)==="tableContents"&&(xl.contents=(Cr=xl==null?void 0:xl.contents)==null?void 0:Cr.filter(hr=>(hr==null?void 0:hr[1])===(v==null?void 0:v[ke]))),xl}),vl}),(!nl||(nl==null?void 0:nl.length)===0)&&(nl=Ll,nl=nl==null?void 0:nl.map(vl=>{var zl;return vl.compData=(zl=vl==null?void 0:vl.compData)==null?void 0:zl.map(xl=>{var Cr;return(xl==null?void 0:xl.key)==="tableContents"&&(xl.contents=(Cr=xl==null?void 0:xl.contents)==null?void 0:Cr.filter(hr=>{var cr,_l;return(hr==null?void 0:hr[1])===(v==null?void 0:v[(_l=(cr=W==null?void 0:W.value)==null?void 0:cr[0])==null?void 0:_l.prop])})),xl}),vl})),ge=dt(nl)}const Na=await ut(ie,{token:Je,inputData:ge}).catch(qa=>(Le.setImportLoading(!1),Promise.reject(qa))),Aa=(Q=Na==null?void 0:Na.data)==null?void 0:Q.data,la=oe.find(qa=>(qa==null?void 0:qa.prop)==="Output1"),ol=la==null?void 0:la.prop;let xa=[],tl=[];if(Aa&&((je=Object.values(Aa))==null?void 0:je.length)>0){let qa=[];const Tl=new FormData,La=(ha=s(Aa))==null?void 0:ha.map(async nl=>{var vl,zl;if(!Array.isArray(nl)&&(nl!=null&&nl.includes("http"))){let xl=await Ja.axios.get(nl,{responseType:"blob"}),Cr=(zl=nl==null?void 0:nl.split("/"))==null?void 0:zl[((vl=nl==null?void 0:nl.split("/"))==null?void 0:vl.length)-1];Tl.append("files",xl.data,Cr)}else qa.push(nl)});if(await Promise.all(La),!le.isFormDataEmpty(Tl)){let nl=await pl.uploadAmountApi(Tl),vl=(za=(B=nl==null?void 0:nl.data)==null?void 0:B.result)==null?void 0:za.map(zl=>{var xl,Cr,hr,cr,_l,rr;return{name:(rr=(_l=(cr=(xl=zl==null?void 0:zl.url)==null?void 0:xl.split("/"))==null?void 0:cr[((hr=(Cr=zl==null?void 0:zl.url)==null?void 0:Cr.split("/"))==null?void 0:hr.length)-1])==null?void 0:_l.split("."))==null?void 0:rr[0],url:zl==null?void 0:zl.url}});qa=[...qa,...vl]}let Ll={};for(let nl in v)nl!=="id"&&(Ll[nl]=v[nl]);Ll[ol]=qa,tl.push({id:v==null?void 0:v.id,value:{tableData:Ll}})}if((tl==null?void 0:tl.length)>0){const qa=tl.map(La=>{const Ll={id:La.id,...La.value.tableData};return delete Ll._isOCRRow,delete Ll._ocrTableId,delete Ll._isTemp,delete Ll.tableEditType,delete Ll.index,Ll}),Tl=[{tableName:(Ua=d==null?void 0:d.related)==null?void 0:Ua.find(La=>La==null?void 0:La.includes("content")),tableContents:qa}];await M.pageBatchUpdateApi({platId:parseInt((sl=Nl.value)==null?void 0:sl.plat_id),changeContents:Tl})}if((xa==null?void 0:xa.length)>0)try{await M.pageBatchAddApi({platId:parseInt((Ga=Nl.value)==null?void 0:Ga.plat_id),changeContents:[{tableName:(Da=d==null?void 0:d.related)==null?void 0:Da.find(qa=>qa==null?void 0:qa.includes("content")),tableContents:xa.map(qa=>{var La,Ll,nl;const Tl={id:((La=qa==null?void 0:qa.key)==null?void 0:La.id)??((Ll=qa==null?void 0:qa.key)==null?void 0:Ll.rowId)??(qa==null?void 0:qa.id),...((nl=qa==null?void 0:qa.value)==null?void 0:nl.tableData)||{}};return delete Tl._isOCRRow,delete Tl._ocrTableId,delete Tl._isTemp,delete Tl.tableEditType,delete Tl.index,Object.keys(Tl).forEach(vl=>{vl==="证书附件"&&Array.isArray(Tl[vl])&&(Tl[vl]=JSON.stringify(Tl[vl]))}),Tl})}]})}catch(qa){Ja.ElMessage.error(((Wl=(dl=qa==null?void 0:qa.response)==null?void 0:dl.data)==null?void 0:Wl.message)||(qa==null?void 0:qa.message)||"保存失败"),Ge.setTableLoading(!1);return}Ui(!0),Le.setImportLoading(!1),Ge.setFreshContent(!0)},h=(f,v)=>(f=f==null?void 0:f.map(z=>{var L,H;return z!=null&&z.children&&((L=z.children)!=null&&L.find(T=>T.id===(v==null?void 0:v.id))?z.children=(H=z.children)==null?void 0:H.filter(T=>(T==null?void 0:T.id)!==(v==null?void 0:v.id)):z.children=h(z.children,v)),z}),f),k=e.ref(!1),C=()=>{k.value=!0},F=async f=>{var z,L,H,T;k.value=!1;const v=Array.isArray(f)?f:f?[f]:[];if(v.length!==0)for(const ie of v){const oe={name:ie.name||`capture-${Date.now()}.jpg`,url:URL.createObjectURL(ie),raw:ie,uid:Date.now()+Math.random()};ga.value.push(oe),yn(oe,"uploading"),Xr(oe,0);try{const K=new FormData;K.append("file",ie,oe.name);const ke=await M.platformUploadFile(K);oe.uploadResult=((z=ke==null?void 0:ke.data)==null?void 0:z.result)||{name:oe.name,url:"",fileName:oe.name},al({name:((L=oe.uploadResult)==null?void 0:L.name)||oe.name,url:((H=oe.uploadResult)==null?void 0:H.url)||"",id:(T=oe.uploadResult)==null?void 0:T.id}),yn(oe,"uploaded"),Xr(oe,100)}catch(K){console.error("文件上传失败:",K),Ja.ElMessage.error(`文件 ${oe.name} 上传失败,请重试`),yn(oe,"pending"),Xr(oe,0);const ke=ga.value.findIndex(ge=>ge.uid===oe.uid);ke>-1&&ga.value.splice(ke,1)}}},Y=e.reactive({title:"迁移至",show:!1,width:"20%",selectRow:null,from:d==null?void 0:d.index,to:null,contents:[],formRules:{groupName:[{required:!0,message:"输入不能为空",trigger:"blur"},{validator:(f,v,z)=>{v===(d==null?void 0:d.index)?z(new Error("选择源不能和目标源一致")):z()}}]},buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"确认",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]}),J=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:""}),xe=()=>{J.show=!1},He=async f=>{var v,z,L,H,T,ie,oe,K;try{const ke=[];let ge=(v=Ce.value||[])==null?void 0:v.slice();(f||[]).forEach(Na=>{const Aa={...Na};try{Aa.sort=ui(0,ge)}catch{}ke.push(Aa),ge.unshift(Aa)});let Je=await M.quoteApi({platId:parseInt((z=Nl==null?void 0:Nl.value)==null?void 0:z.plat_id),type:"fatherSyncs",related:[{menus:de.value,groups:""},{menus:de.value,groups:d==null?void 0:d.compName}]});Je=(L=Je==null?void 0:Je.data)==null?void 0:L.result;let Ue=Je==null?void 0:Je.map(Na=>({tableName:"content_"+(Na==null?void 0:Na.id),tableContents:ke==null?void 0:ke.map((Aa,la)=>({id:la,...Aa}))})),ea=[{tableName:(H=d==null?void 0:d.related)==null?void 0:H.find(Na=>Na==null?void 0:Na.includes("content")),tableContents:ke==null?void 0:ke.map((Na,Aa)=>({id:Aa,...Na}))}];ea=[...ea,...Ue];const ka=await M.pageBatchAddApi({platId:parseInt((T=Nl.value)==null?void 0:T.plat_id),changeContents:ea});if(((ie=ka==null?void 0:ka.data)==null?void 0:ie.code)===200){const Na={buttonName:"新增",columns:W.value,fixContent:ke==null?void 0:ke.map((la,ol)=>({id:ol,...la})),relatedContents:d==null?void 0:d.related};await It(Na),Ja.ElMessage.success("数据导入成功");let Aa=[];ea==null||ea.forEach(la=>{var ol;(ol=la==null?void 0:la.tableContents)==null||ol.forEach(xa=>{Aa.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(xa),request_result:"{}",is_delete:!1,request_table:la==null?void 0:la.tableName,request_type:"export"})})}),await M.pageBatchAddApi({platId:parseInt((oe=Nl==null?void 0:Nl.value)==null?void 0:oe.plat_id),changeContents:[{tableName:"log",tableContents:Aa}]})}else{let Na=[];ea==null||ea.forEach(Aa=>{var la;(la=Aa==null?void 0:Aa.tableContents)==null||la.forEach(ol=>{Na.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ol),request_result:"{}",is_delete:!1,request_table:Aa==null?void 0:Aa.tableName,request_type:"error"})})}),await M.pageBatchAddApi({platId:parseInt((K=Nl==null?void 0:Nl.value)==null?void 0:K.plat_id),changeContents:[{tableName:"log",tableContents:Na}]}),Ja.ElMessage.error("数据导入响应失败")}}catch(ke){throw new Error(ke)}},Se=async f=>{var v,z,L,H,T,ie,oe,K,ke,ge;try{if(f==="cancel"&&(J.show=!1),f==="replace"&&((v=J==null?void 0:J.existRows)==null?void 0:v.length)>0){await M.pageBatchDeleteApi({platId:parseInt((z=Nl.value)==null?void 0:z.plat_id),changeContents:[{tableName:((L=d==null?void 0:d.related)==null?void 0:L.find(Ue=>Ue==null?void 0:Ue.includes("content_")))||((H=d==null?void 0:d.related)==null?void 0:H.find(Ue=>Ue==null?void 0:Ue.includes("content"))),tableContents:J==null?void 0:J.existRows}]});const Je=await M.pageBatchAddApi({platId:parseInt((T=Nl.value)==null?void 0:T.plat_id),changeContents:[{tableName:(ie=d==null?void 0:d.related)==null?void 0:ie.find(Ue=>Ue==null?void 0:Ue.includes("content")),tableContents:(()=>{const Ue=(Ce.value||[]).filter(Aa=>!((J==null?void 0:J.existRows)||[]).some(la=>String(la==null?void 0:la.id)===String(Aa==null?void 0:Aa.id))),ea=(J==null?void 0:J.tableData)||[],ka=[];let Na=Ue.slice();return ea.forEach(Aa=>{const la={...Aa};try{la.sort=ui(0,Na)}catch{}ka.push(la),Na.unshift(la)}),ka.map((Aa,la)=>({id:la,...Aa}))})()}]});if(((oe=Je==null?void 0:Je.data)==null?void 0:oe.code)!==200)return;(K=J.newRows)!=null&&K.length&&await He(J.newRows),await It({buttonName:"新增",columns:W.value,fixContent:(ke=J==null?void 0:J.tableData)==null?void 0:ke.map((Ue,ea)=>({id:ea,...Ue})),relatedContents:d==null?void 0:d.related}),(ge=J.newRows)!=null&&ge.length||Ja.ElMessage.success("数据导入成功")}}catch(Je){throw new Error(Je)}finally{J.show=!1,J.columns=[],J.tableData=[],J.existRows=[]}},da=()=>{Y.show=!1},Ma=f=>{var v,z;if((f==null?void 0:f.buttonName)==="取消")return Y.show=!1;Y.to=f==null?void 0:f.content,!(!(d!=null&&d.index)||!((v=Y.to)!=null&&v.groupName))&&(d==null?void 0:d.index)!==((z=Y.to)==null?void 0:z.groupName)&&(U("change",{buttonName:"迁移",value:{from:Y.from,to:Y.to,data:Y.selectRow}}),Y.show=!1)},rl=async f=>{var v,z,L,H;if(f){if(!Ar.validateFileSize(f.raw)){Ja.ElMessage.warning(`文件大小不能超过 ${Re.value.maxSize}MB`);const T=ga.value.findIndex(ie=>ie.uid===f.uid);T>-1&&ga.value.splice(T,1),el();return}if(!Ar.validateFileType(f.raw)){Ja.ElMessage.warning("请上传图片文件");const T=ga.value.findIndex(ie=>ie.uid===f.uid);T>-1&&ga.value.splice(T,1),el();return}yn(f,"uploading"),Xr(f,0);try{const T=new FormData;T.append("file",f.raw,f.name);const ie=await M.platformUploadFile(T);f.uploadResult=((v=ie==null?void 0:ie.data)==null?void 0:v.result)||{name:f.name,url:"",fileName:f.name},al({name:((z=f.uploadResult)==null?void 0:z.name)||f.name,url:((L=f.uploadResult)==null?void 0:L.url)||"",id:(H=f.uploadResult)==null?void 0:H.id}),yn(f,"uploaded"),Xr(f,100)}catch(T){console.error("文件上传失败:",T),Ja.ElMessage.error(`文件 ${f.name} 上传失败,请重试`),yn(f,"pending"),Xr(f,0);const ie=ga.value.findIndex(oe=>oe.uid===f.uid);ie>-1&&ga.value.splice(ie,1)}finally{el()}}},el=()=>{e.nextTick(()=>{const f=document.querySelector('.ocr-upload-input input[type="file"]');f&&(f.value="")})},cl=async()=>{var z,L;if(sessionStorage.setItem("ocr_root_table_id",String((d==null?void 0:d.index)??"")),ga.value.length===0){Ja.ElMessage.warning("请先选择要上传的图片");return}if(ga.value.filter(H=>{const T=ar(H);return T!=="uploaded"&&T!=="completed"&&T!=="failed"}).length>0){Ja.ElMessage.warning("请等待所有文件上传完成后再开始识别");return}dr.value=!0,Te.value=0;let v=null;try{ga.value.forEach(la=>{yn(la,"processing")});const H=Math.floor(Math.random()*10)+90;v=setInterval(()=>{Te.value<H?Te.value+=1:clearInterval(v)},50);const T=ga.value.map(la=>{var ol,xa,tl;return{name:((ol=la.uploadResult)==null?void 0:ol.name)||la.name,url:((xa=la.uploadResult)==null?void 0:xa.url)||"",fileName:((tl=la.uploadResult)==null?void 0:tl.fileName)||la.name}}),ie=Ar.extractTableHeaders(W.value),oe=T.map(la=>({name:(la==null?void 0:la.fileName)||(la==null?void 0:la.name),url:(la==null?void 0:la.url)||""})),K=await Ar.recognize(oe,ie);if(console.log(K,"ocrResult"),clearInterval(v),v=null,(K==null?void 0:K.code)===500||(K==null?void 0:K.type)==="error"||!(K!=null&&K.result)){Te.value=0,ga.value.forEach(la=>{yn(la,"failed"),Xr(la,0)}),Ja.ElMessage.error((K==null?void 0:K.message)||"OCR识别失败,请重试"),dr.value=!1;return}Te.value=H;const ke=Array.isArray(K==null?void 0:K.result)?K.result:[];if(ke.length===0){Te.value=0,ga.value.forEach(la=>{yn(la,"failed"),Xr(la,0)}),Ja.ElMessage.warning("OCR识别未返回有效数据"),dr.value=!1;return}const ge=new Set,Je=[];ke.forEach((la,ol)=>{const xa=la!=null&&la.数据&&typeof(la==null?void 0:la.数据)=="object"?la.数据:{},tl=Array.isArray(la==null?void 0:la.图片信息)?la.图片信息:[],be=new Map;tl.forEach(ba=>{ba!=null&&ba.name&&be.set(ba.name,ba.url||"")});const Va={_index:ol,_certType:(la==null?void 0:la.证书类型)||"",_certNo:(la==null?void 0:la.证书编号)||"",_ocrImages:tl,__ocrFieldMeta:{}};Object.entries(xa).forEach(([ba,Ya])=>{let Ia="",Ne=0,Q=[],je="";Ya&&typeof Ya=="object"&&!Array.isArray(Ya)?(Ia=(Ya==null?void 0:Ya.value)??"",Ne=(Ya==null?void 0:Ya.score)??0,Q=Array.isArray(Ya==null?void 0:Ya.bboxNorm)?Ya==null?void 0:Ya.bboxNorm:[],je=(Ya==null?void 0:Ya.imageName)||""):Array.isArray(Ya)&&Ya.length>=2?(Ia=Ya[0]??"",Ne=Ya[1]??0):(Ia=Ya??"",Ne=0),Va[ba]=Ia,Va[`${ba}_accuracy`]=Ne,ge.add(ba),Va.__ocrFieldMeta[ba]={value:Ia,score:Ne,bboxNorm:Q,imageName:je,imageUrl:je&&be.get(je)||"",images:tl}}),Je.push(Va)});const Ue=[],ea=new Set;Je.forEach(la=>{la&&ge.forEach(ol=>{const xa=la[`${ol}_accuracy`];(typeof xa=="number"?xa>0:xa!=null&&String(xa).trim()!==""&&String(xa)!=="0")&&ea.add(ol)})}),ge.forEach(la=>{Ue.push({prop:la,label:la,editable:!0,minWidth:230}),ea.has(la)&&Ue.push({prop:`${la}_accuracy`,label:"准确率",editable:!1,minWidth:100,isAccuracy:!0})}),ga.value.forEach(la=>{yn(la,"completed")}),Te.value=100,pe.value=Ue,Ka.value=Je,ul.value=T,Ol.value=K;const ka=["出厂编号","设备名称","制造厂"],Na=Ue.filter(la=>la&&!la.isAccuracy&&typeof la.prop=="string").map(la=>la.prop),Aa=["出厂编号","设备名称","制造厂"];ca.value=Na.filter(la=>Aa.includes(la)),console.log("[OCR] 默认勾选字段 props:",ca.value),Ha.value=2,dr.value=!1,oa.value=!1}catch(H){console.error("OCR处理失败:",H),v&&(clearInterval(v),v=null),Ja.ElMessage.error(((L=(z=H==null?void 0:H.response)==null?void 0:z.data)==null?void 0:L.message)||"OCR识别失败,请重试"),dr.value=!1,Te.value=0,ga.value.forEach(T=>{yn(T,"pending"),Xr(T,0)})}},Dl=f=>{if(f==null)return"";let v=String(f);return v=v.replace(/\s+/g," ").trim(),v=v.replace(/[!-~]/g,z=>String.fromCharCode(z.charCodeAt(0)-65248)),v=v.replace(/ /g," "),v=v.replace(/^(编号|No\.?|NO\.?|no\.?|SN\.?|sn\.?|序列号)\s*[::]?\s*/i,""),v},El=()=>{var la,ol;const f=ul.value,v=Ol.value,z=Ka.value;if(!z||z.length===0){Ja.ElMessage.warning("暂无数据可添加");return}const L=(la=le.getAllLeafNodes(W.value)||[])==null?void 0:la.filter(xa=>(xa==null?void 0:xa.type)!=="operate"&&(xa==null?void 0:xa.label)!=="操作"&&(xa==null?void 0:xa.prop)!=="operate"),H=new Map,T=new Map,ie=(ol=L==null?void 0:L.find(xa=>(xa==null?void 0:xa.label)==="证书附件"))==null?void 0:ol.prop;L==null||L.forEach(xa=>{xa!=null&&xa.label&&(xa!=null&&xa.prop)&&(H.set(xa.label,xa.prop),T.set(xa.prop,xa.label))});const oe=Date.now(),K=xa=>String(oe*1e3+xa),ke=[],ge=[],Je=xa=>{const tl=Ao&&Ao[xa]||[xa];for(const be of tl){const Va=H.get(be);if(Va)return Va}return""},Ue=Je("出厂编号"),ea=Je("设备名称"),ka=Je("制造厂"),Na=[],Aa=xa=>{var Ia,Ne;if(!ie)return[];const tl=(Array.isArray(f)?f[xa]:null)||null,be=(tl==null?void 0:tl.url)||"",Va=(tl==null?void 0:tl.fileName)||(tl==null?void 0:tl.name)||"";return(String(Va).toLowerCase().endsWith(".pdf")||String(be).toLowerCase().endsWith(".pdf"))&&be?[{url:be,name:Va,fileName:Va}]:(Array.isArray((Ne=(Ia=v==null?void 0:v.result)==null?void 0:Ia[xa])==null?void 0:Ne.图片信息)?v.result[xa].图片信息:[]).map(Q=>({url:(Q==null?void 0:Q.url)||"",name:(Q==null?void 0:Q.name)||"",fileName:(Q==null?void 0:Q.name)||""})).filter(Q=>Q.url)};if(z.forEach((xa,tl)=>{var sl;const be={id:K(tl),_isOCRRow:!0,_ocrTableId:d==null?void 0:d.index};for(const[Ga,Da]of H.entries())Object.prototype.hasOwnProperty.call(xa,Ga)&&(be[Da]=xa[Ga]);ie&&(be[ie]=Aa(tl));const Va=(Array.isArray(v==null?void 0:v.result)?v.result[tl]:null)||null,ba=(Array.isArray(f)?f[tl]:null)||null,Ya=(ba==null?void 0:ba.url)||"",Ia=(ba==null?void 0:ba.fileName)||(ba==null?void 0:ba.name)||"",Ne=String(Ia).toLowerCase().endsWith(".pdf")||String(Ya).toLowerCase().endsWith(".pdf"),Q={ts:Date.now(),versionId:String(Date.now())+"_"+String(tl),label:new Date().toLocaleString(),certType:(Va==null?void 0:Va.证书类型)||"",certNo:(Va==null?void 0:Va.证书编号)||"",fileType:Ne?"pdf":"image",sourceUrl:Ne?Ya:"",images:Array.isArray(Va==null?void 0:Va.图片信息)?Va.图片信息.map(Ga=>({name:(Ga==null?void 0:Ga.name)||"",url:(Ga==null?void 0:Ga.url)||""})).filter(Ga=>Ga.url):[]},je=Ga=>Dl(Ga?be==null?void 0:be[Ga]:""),ha=je(Ue),B=je(ea),za=je(ka);if(!!(Ue&&ea&&ka&&ha&&B&&za)){const Ga=(Ce.value||[]).find(Da=>{const dl=Dl(Ue?Da==null?void 0:Da[Ue]:""),Wl=Dl(ea?Da==null?void 0:Da[ea]:""),qa=Dl(ka?Da==null?void 0:Da[ka]:"");return dl&&Wl&&qa&&dl===ha&&Wl===B&&qa===za});if(Ga){Na.push({idx:tl,ocrRow:be,versionItem:Q,ocrNo:ha,candidates:[Ga],selectedTargetId:String((Ga==null?void 0:Ga.id)??""),__decision:"replace",allowAdd:!1,allowReplace:!0});return}}if(ha&&Ue){const Ga=(Ce.value||[]).filter(Da=>{const dl=Dl(Ue?Da==null?void 0:Da[Ue]:"");return dl&&dl===ha});if(Ga.length>0){Na.push({idx:tl,ocrRow:be,versionItem:Q,ocrNo:ha,candidates:Ga,selectedTargetId:"",__decision:"",allowAdd:!0,allowReplace:!0});return}}try{if(be.sort===void 0||be.sort===null||String(be.sort).trim()===""){const Ga=(Ce.value||[]).map(dl=>jn(dl==null?void 0:dl.sort)).filter(dl=>dl!==null),Da=Ga.length>0?Math.max(...Ga):((sl=Ce.value)==null?void 0:sl.length)??0;be.sort=String(Number((Da+1).toFixed(6)))}}catch{}Kl(d==null?void 0:d.index,be.id,Q),Na.push({idx:tl,ocrRow:be,versionItem:Q,ocrNo:ha,candidates:[],selectedTargetId:"",__decision:"add",allowAdd:!0,allowReplace:!1})}),(Na||[]).length>0){bl.value=(Na||[]).map(xa=>({...xa,selectedTargetId:(xa==null?void 0:xa.selectedTargetId)||""})),Fe.value=!0,tr.value=ge,xr.value=ke,Ra.value=v,kl.value=f,Ml.value=ie||"";return}},Vl=(f,v,z)=>{Ka.value[f]&&(Ka.value[f][v]=z)},ir=f=>f==null||f===0?"-":`${(Number(f)*100).toFixed(1)}%`,fr=f=>{if(f==null||f===0)return"#909399";const v=Number(f);return v>=.9?"#67c23a":v>=.7?"#e6a23c":"#f56c6c"},ql=f=>{var z,L,H,T;if(Xa.value===f){Xa.value=null,wa.value=!1,ua.value="";return}Xa.value=f,ua.value="";const v=(z=Ka.value)==null?void 0:z[f];if(v&&Array.isArray(v._ocrImages)&&v._ocrImages.length>0){Ba.value=v._ocrImages.map(K=>({name:(K==null?void 0:K.name)||"",url:(K==null?void 0:K.url)||""})).filter(K=>K.name||K.url);const ie=v.__ocrFieldMeta||{},oe=(L=Object.values(ie))==null?void 0:L.find(K=>K==null?void 0:K.imageName);hl.value=(oe==null?void 0:oe.imageName)||((T=(H=Ba.value)==null?void 0:H[0])==null?void 0:T.name)||"",wa.value=Ba.value.length>0}else Ba.value=[],wa.value=!1,hl.value=""},sr=()=>{Sl.value=!1,ga.value=[],il.value=null,Ha.value=1,Sa.value.clear(),ll.value.clear(),Te.value=0,wa.value=!1},dn=f=>f.raw?URL.createObjectURL(f.raw):f.url?f.url:"",ar=f=>{const v=f.uid||f.name;return Sa.value.get(v)||"pending"},bn=f=>{const v=f.uid||f.name;return ll.value.get(v)||0},Xr=(f,v)=>{const z=f.uid||f.name;ll.value.set(z,Math.min(100,Math.max(0,v)))},Rn=f=>{const v=ar(f),z=100.53;if(v==="completed"||v==="uploaded")return`${z} ${z}`;if(v==="failed")return`${z} ${z}`;if(v==="uploading"){const L=bn(f);return`${z*(L/100)} ${z}`}else if(v==="processing")return`${z*.5} ${z}`;return`0 ${z}`},yn=(f,v)=>{const z=f.uid||f.name;Sa.value.set(z,v),(v==="completed"||v==="uploaded")&&Xr(f,100)},pi=()=>{e.nextTick(()=>{const f=document.querySelector('.ocr-upload-input input[type="file"]');if(f)f.value="",f.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 z=>{const L=Array.from(z.target.files||[]);for(const H of L){const T={name:H.name,raw:H,uid:Date.now()+Math.random()};ga.value.push(T),await rl(T)}z.target.value="",document.body.removeChild(v)},document.body.appendChild(v),v.click()}})},Eu=()=>{Ha.value>1&&Ha.value--},Cu=()=>{Ha.value===1?ga.value.length>0&&!dr.value&&cl():Ha.value===2&&(El(),Ha.value=3)},Du=async f=>{await jt(f==null?void 0:f.row)},Tu=async({row:f,prop:v})=>{!f||!v||await jt(f,v)},jt=async(f,v)=>{var H,T;const z=f==null?void 0:f.id;if(!z){Ja.ElMessage.warning("暂无可预览数据");return}let L=Wa(d==null?void 0:d.index,z);if(!L||L.length===0){const ie=sessionStorage.getItem("ocr_root_table_id"),oe=ie!==null?Number(ie):null;if(oe!=null&&oe!==""&&!Number.isNaN(oe)){const K=Wa(oe,z);Array.isArray(K)&&K.length>0&&(Gl(d==null?void 0:d.index,z,K),L=K)}}if(!L||L.length===0){const ie=(H=le.getAllLeafNodes(W.value)||[])==null?void 0:H.filter(K=>(K==null?void 0:K.type)!=="operate"&&(K==null?void 0:K.label)!=="操作"&&(K==null?void 0:K.prop)!=="operate"),oe=v||((T=ie==null?void 0:ie.find(K=>(K==null?void 0:K.label)==="证书附件"))==null?void 0:T.prop);if(oe&&f[oe]){const K=f[oe];let ke=[],ge="",Je=!1;if(typeof K=="string")try{const Ue=JSON.parse(K);Array.isArray(Ue)&&(ke=Ue.map(ea=>({name:(ea==null?void 0:ea.name)||(ea==null?void 0:ea.fileName)||"",url:(ea==null?void 0:ea.url)||""})).filter(ea=>ea.url||ea.name),ke.length>0&&(ge=ke[0].url||"",Je=String(ke[0].name).toLowerCase().endsWith(".pdf")||String(ge).toLowerCase().endsWith(".pdf")))}catch{ge=K,Je=String(K).toLowerCase().endsWith(".pdf"),ke=[{name:K,url:K}]}else Array.isArray(K)&&(ke=K.map(Ue=>({name:(Ue==null?void 0:Ue.name)||(Ue==null?void 0:Ue.fileName)||"",url:(Ue==null?void 0:Ue.url)||""})).filter(Ue=>Ue.url||Ue.name),ke.length>0&&(ge=ke[0].url||"",Je=String(ke[0].name).toLowerCase().endsWith(".pdf")||String(ge).toLowerCase().endsWith(".pdf")));if(ke.length>0||ge){const Ue={ts:Date.now(),versionId:String(Date.now()),label:new Date().toLocaleString(),certType:f.证书类型||"",certNo:f.证书编号||"",fileType:Je?"pdf":"image",sourceUrl:Je?ge:"",images:ke};L=[Ue],Kl(d==null?void 0:d.index,z,Ue)}}}if(!L||L.length===0){Ja.ElMessage.warning("暂无可预览数据");return}Bl.value=L,fl.value=!0},Bu=f=>{ga.value=ga.value.filter((v,z)=>z!==f)},pt=async(f,v,z)=>{var L,H,T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya;if(Ca(d.config,{type:ya.TABLE,tableOperate:f})){if(fa.value="",Ae.value=!0,ja.value=!0,U("onButtonClick",f,v),X.value=[],f==="删除")M.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var Ia,Ne,Q,je;(Ia=Ce.value)!=null&&Ia.find(ha=>(ha==null?void 0:ha.id)===(v==null?void 0:v.id))?Ce.value=(Ne=M.cloneDeep(Ce.value))==null?void 0:Ne.filter(ha=>(ha==null?void 0:ha.id)!==(v==null?void 0:v.id)):Ce.value=h(M.cloneDeep(Ce.value),v);try{v!=null&&v.id&&((je=(Q=Ta.value)==null?void 0:Q.has)!=null&&je.call(Q,v==null?void 0:v.id))&&Ta.value.delete(v.id)}catch{}m0(Sr.value,$l.value,v==null?void 0:v.id),Ge.setTableLoading(d==null?void 0:d.index),U("change",{content:Ce.value,fixContent:[v],index:d==null?void 0:d.index,type:"delete",name:d==null?void 0:d.groupNames,buttonName:f,columns:W.value,relatedContents:d==null?void 0:d.related}),console.log(v,"item")});else if(f==="批量删除"){if(((L=Br.value)==null?void 0:L.length)===0)return Ja.ElMessage.warning("请先勾选操作的数据");M.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(async()=>{var Q,je,ha,B,za;const Ia=(Q=Br.value)==null?void 0:Q.map(Ua=>Ua.id);Ce.value=(je=M.cloneDeep(Ce.value))==null?void 0:je.filter(Ua=>!(Ia!=null&&Ia.includes(Ua.id))),Ge.setTableLoading(d==null?void 0:d.index),U("change",{content:Ce.value,fixContent:Br.value,index:d==null?void 0:d.index,type:"delete",name:d==null?void 0:d.compName,buttonName:f,relatedContents:d==null?void 0:d.related,columns:W.value});const Ne=(Ia||[]).filter(Boolean);if(Ne.length>0&&Ne.every(Ua=>Ua!=null&&Ua!=="")){const Ua=(Br.value||[]).map(sl=>{const Ga={...sl};return delete Ga._isOCRRow,delete Ga._ocrTableId,delete Ga._isTemp,delete Ga.tableEditType,delete Ga.index,Ga});await M.pageBatchDeleteApi({platId:parseInt((ha=Nl.value)==null?void 0:ha.plat_id),changeContents:[{tableName:((B=d==null?void 0:d.related)==null?void 0:B.find(sl=>sl==null?void 0:sl.includes("content_")))||((za=d==null?void 0:d.related)==null?void 0:za.find(sl=>sl==null?void 0:sl.includes("content"))),tableContents:Ua}]})}})}else if(f==="复制新增"){ma.value="复制新增",M.cloneDeep(v);const Ia=(H=W.value)==null?void 0:H.find(Ne=>Ne==null?void 0:Ne.isMainKey);Ia||((T=W.value)==null||T[0]),Yl.value=v,Ui(!0)}else if(f==="新增")ma.value="新增",ji(""),Qe.value=!0;else if(f==="编辑")ma.value="编辑",ji(v),Qe.value=!0;else if(f==="查看")ma.value="查看",ji(v),Ae.value=!1,ja.value=!1,Qe.value=!0;else if(f==="查看三维模型"){const Ia={};for(let Q in v)Q!=="id"&&(Ia[Q]=v[Q]);let Ne=(ie=Object.values(Ia))==null?void 0:ie[1];Ea.setTableShowThree(Ne)}else if(f==="切换视图")ju();else if(((oe=z==null?void 0:z.extra)==null?void 0:oe.type)==="modelExample")ma.value=f,ne.value=!0;else if(f==="新建"){let Ia=pa.value,Ne=[];for(let za in Ia)za!=null&&za.includes(`loading${((K=Nl.value)==null?void 0:K.account)||((ke=Nl.value)==null?void 0:ke.账号)}`)&&(Ne=[...Ne,...za]);let Q=[];for(let za in Ia)za!=null&&za.includes(`updateLoading${((ge=Nl.value)==null?void 0:ge.account)||((Je=Nl.value)==null?void 0:Je.账号)}`)&&(Q=[...Q,...za]);let je=Ne==null?void 0:Ne.map(za=>za==null?void 0:za.id);const ha=Q==null?void 0:Q.map(za=>za==null?void 0:za.id);je=[...M.cloneDeep(je),...ha],(je==null?void 0:je.length)>0&&(je!=null&&je.every(za=>za!==null&&za))&&await Kr.batchDeleteInsofDataApi({ids:je});const B=(Ue=Ee.value)==null?void 0:Ue.find(za=>(za==null?void 0:za.label)==="新建");await zu(!1,B)}else if(f==="修改模板"){let Ia=M.cloneDeep(de).value;Ge.setRouteToChildPath(Ia),Le.setActiveMenuPath(Ia+I)}else if(f==="执行")t(f,v);else if(f==="导出paraform"){const Ia=M.ElLoading.service({lock:!0,text:"正在导出paraform...",background:"rgba(0, 0, 0, 0.7)"});try{const Ne=["推力","真空","压力","温度","流量"],Q=_l=>{var rr,mr,Il;return _l?typeof(_l==null?void 0:_l.value)=="string"?_l.value:((Il=(mr=(rr=_l==null?void 0:_l._custom)==null?void 0:rr.value)==null?void 0:mr.value)==null?void 0:Il.value)||"":""},je=Array.isArray(nr.value)?nr.value:[],ha=Q(je.find(_l=>(_l==null?void 0:_l.condition)==="child")),B=String(ha||"").slice(0,8),za=_l=>{if(_l==null)return"";const rr=String(_l).trim();if(!rr)return"";if(/^\d{8}$/.test(rr))return rr;const mr=rr.match(/^(\d{4})[-\/.](\d{1,2})[-\/.](\d{1,2})$/);if(mr){const yr=mr[1],Dr=mr[2].padStart(2,"0"),gr=mr[3].padStart(2,"0");return`${yr}${Dr}${gr}`}const Il=rr.replace(/\D/g,"");return Il.length>=8?Il.slice(0,8):""},Ua=async _l=>{var rr,mr;if(!_l)return"";try{const Il=await Hr("试验任务/任务管理",!1),yr=(vr,Or=[])=>{if(!Array.isArray(vr))return Or;for(const Fr of vr)(Fr==null?void 0:Fr.comp)==="Table"&&(Fr!=null&&Fr.name)&&Or.push(Fr),Array.isArray(Fr==null?void 0:Fr.children)&&yr(Fr.children,Or),Array.isArray(Fr==null?void 0:Fr.tab)&&yr(Fr.tab,Or),Array.isArray(Fr==null?void 0:Fr.choice)&&yr(Fr.choice,Or);return Or},gr=yr(Il||[]).find(vr=>(vr==null?void 0:vr.name)==="任务列表"),Mr=((mr=(rr=gr==null?void 0:gr.compData)==null?void 0:rr.find(vr=>(vr==null?void 0:vr.key)==="tableContents"))==null?void 0:mr.contents)||[];if(!Array.isArray(Mr)||Mr.length===0)return"";const tn=Mr.find(vr=>String((vr==null?void 0:vr["试验代号(名称)"])||"").slice(0,8)===_l);return za(tn==null?void 0:tn.计划试验时间)}catch(Il){return console.warn("获取任务列表计划试验时间失败:",Il),""}},sl=(de.value||"").replace(/\/+$/,""),Ga=ha?`${sl}/${ha}`:sl,Da=await Hr(Ga||de.value,!1),dl=String(Ve.value||"").trim(),Wl=_l=>String(_l||"").trim(),qa=(_l,rr=[],mr="")=>{if(!Array.isArray(_l))return rr;for(const Il of _l){const yr=Wl((Il==null?void 0:Il.choiceName)||(Il==null?void 0:Il.name0)||mr);(Il==null?void 0:Il.comp)==="Table"&&(Il==null?void 0:Il.name)&&Ne.includes(Il.name)&&(!dl||yr===dl)&&rr.push(Il),Array.isArray(Il==null?void 0:Il.children)&&qa(Il.children,rr,yr),Array.isArray(Il==null?void 0:Il.tab)&&qa(Il.tab,rr,yr),Array.isArray(Il==null?void 0:Il.choice)&&qa(Il.choice,rr,yr)}return rr},Tl=qa(Da||[]),La=new Map;for(const _l of Tl)_l!=null&&_l.name&&!La.has(_l.name)&&La.set(_l.name,_l);const Ll=Ne.map(_l=>La.get(_l)).filter(Boolean);if(!Ll||Ll.length===0)return Ja.ElMessage.warning("未找到需要导出的表(推力、真空、压力、温度、流量)");const nl=_l=>{const rr=new Map,mr=(Il,yr=[])=>{if(Array.isArray(Il))for(const Dr of Il){const gr=((Dr==null?void 0:Dr.label)??"").toString().trim(),Mr=gr?[...yr,gr]:[...yr];if(Array.isArray(Dr==null?void 0:Dr.children)&&Dr.children.length>0)mr(Dr.children,Mr);else{const vr=((Dr==null?void 0:Dr.prop)??"").toString();if(!vr)continue;const Or=gr||vr,Fr=(Mr.length>0?[...yr,Or]:[Or]).join(".");rr.set(vr,Fr)}}};return mr(_l,[]),rr},vl=(_l,rr)=>{const mr=nl(_l||[]),yr=(le.getAllLeafNodes(_l||[])||[]).filter(gr=>(gr==null?void 0:gr.prop)&&(gr==null?void 0:gr.type)!=="operate"&&(gr==null?void 0:gr.label)!=="操作"&&(gr==null?void 0:gr.prop)!=="operate"),Dr=Array.isArray(rr)?rr:[];return Dr.length===0?[]:Dr.map(gr=>{const Mr={};return yr.forEach(tn=>{const vr=String(tn.prop),Or=mr.get(vr)||String(tn.label||tn.prop);Mr[Or]=(gr==null?void 0:gr[vr])??""}),Mr})},zl=Ll.map(_l=>{var Dr,gr;const rr=(_l==null?void 0:_l.compData)||[];let mr=(Dr=rr==null?void 0:rr.find(Mr=>(Mr==null?void 0:Mr.key)==="header"))==null?void 0:Dr.contents;Array.isArray(mr==null?void 0:mr[0])&&(mr=mr[0]);const Il=((gr=rr==null?void 0:rr.find(Mr=>(Mr==null?void 0:Mr.key)==="tableContents"))==null?void 0:gr.contents)||[];if(!Array.isArray(mr)||mr.length===0||!Array.isArray(Il)||Il.length===0)return null;const yr=vl(mr||[],Il||[]);return!Array.isArray(yr)||yr.length===0?null:{类型:_l==null?void 0:_l.name,数据:yr}}).filter(Boolean);if(!zl||zl.length===0)return Ja.ElMessage.warning("没有可导出的数据(推力、真空、压力、温度、流量均为空)");const xl=await Ua(B),Cr={试验代号:B,试验日期:xl,ParaForm:zl},hr=await Si().catch(()=>""),cr=await M.exportParaformApi(Cr,hr);if(((ea=cr==null?void 0:cr.data)==null?void 0:ea.code)===200&&((Na=(ka=cr==null?void 0:cr.data)==null?void 0:ka.result)!=null&&Na.Excel文件)){const _l=cr.data.result.Excel文件,rr=await M.platformDownloadFile({url:_l}),mr=new Blob([rr.data],{type:"application/vnd.ms-excel"}),Il=URL.createObjectURL(mr),yr=M.dayjs().format("YYYYMMDD"),gr=`${(B||"UNKNOWN").trim()||"UNKNOWN"}_${yr}_paraform.xls`,Mr=document.createElement("a");Mr.href=Il,Mr.download=gr,Mr.style.display="none",document.body.appendChild(Mr),Mr.click(),setTimeout(()=>{document.body.removeChild(Mr),URL.revokeObjectURL(Il)},100);const tn=Array.isArray((la=(Aa=cr==null?void 0:cr.data)==null?void 0:Aa.result)==null?void 0:la.warnings)?cr.data.result.warnings:[];if(tn.length>0){const vr=tn.map((Or,Fr)=>`${Fr+1}. ${(Or==null?void 0:Or.field)||"未知字段"}:${(Or==null?void 0:Or.message)||""}`).join(`
|
|
24
24
|
`);Ja.ElMessage.warning({message:`导出成功,但存在以下提示:
|
|
25
|
-
${vr}`,duration:5e3,showClose:!0})}else Ja.ElMessage.success("导出成功")}else Ja.ElMessage.error(((ol=cr==null?void 0:cr.data)==null?void 0:ol.message)||"导出失败")}catch(Ne){console.error("导出paraform失败:",Ne),Ja.ElMessage.error("导出失败:"+((Ne==null?void 0:Ne.message)||"未知错误"))}finally{Ia.close()}}else if(f!=null&&f.includes("导出")&&f!=="导出paraform"){if(f==="导出选中"&&((xa=Br.value)==null?void 0:xa.length)===0)return Ja.ElMessage.warning(`请先勾选${f}的数据`);if(f==="导出全部"&&((tl=Ce.value)==null?void 0:tl.length)===0)return Ja.ElMessage.warning("暂无数据导出");let Ia=["序号",...(Va=(be=W.value)==null?void 0:be.map(ha=>ha==null?void 0:ha.prop))==null?void 0:Va.filter(ha=>ha!=="操作")],Ne=f==="导出全部"?Ce.value:Br.value;const Q=["id","sort","tableEditType","create_time","update_time","source_table","create_user_id","update_user_id","department_id","relatedId"];Ne=Ne==null?void 0:Ne.map(ha=>Object.fromEntries(Object.entries(ha).filter(([B])=>!Q.includes(B)))),Ia=["序号",...Ia],Ne=Ne==null?void 0:Ne.map((ha,B)=>({序号:B+1,...ha}));let je=(d==null?void 0:d.compName)||"表格信息";qo(Ne,je,Ia,je)}else if(f==="OCR识别")Sl.value=!0,ga.value=[],Ha.value=1,Sa.value.clear(),ll.value.clear(),Te.value=0;else if(f==="迁移")Y.selectRow=v,Y.show=!0;else if(f==="生成方法"){let Ia=await I0(v),Ne;v!==""?Ne=[v]:Ne=M.cloneDeep(Ce.value),Ne=Ne==null?void 0:Ne.map(je=>(je.输出值=Ia,je));const Q={fixContent:Ne,buttonName:"编辑",relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames};U("change",Q)}else if(f==="签字板"||f==="触控笔")$a.value.dialogShow=!0,$a.value.dialogTitle=f;else if(((ba=z==null?void 0:z.extra)==null?void 0:ba.type)==="methodButton"){let Ia;v!==""?Ia=[v]:Ia=M.cloneDeep(Ce.value);const Ne=await Bt(Ia,W==null?void 0:W.value,"Manual",Ce.value,d==null?void 0:d.calculator,d==null?void 0:d.compNames);let Q;(Ya=Ne==null?void 0:Ne[0])!=null&&Ya.menuPathContent?Q={fixContent:Ne,buttonName:"新增",relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames}:Q={fixContent:Ne,buttonName:"methodButton",relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames},U("change",Q)}}},Nu=async(f,v)=>{var z,L,H,T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be;try{let Va,ba;const Ya=(z=pa.value[de.value+I])==null?void 0:z.filter(Ua=>{var sl;return((sl=Ua==null?void 0:Ua.key)==null?void 0:sl.type)==="structureMethod"}),Ia=(L=pa.value[de.value+I])==null?void 0:L.filter(Ua=>{var sl;return((sl=Ua==null?void 0:Ua.key)==null?void 0:sl.type)==="structure"}),Ne=Ya==null?void 0:Ya.find(Ua=>{var sl,Ga;return((Ga=(sl=Ua==null?void 0:Ua.value)==null?void 0:sl.pageData)==null?void 0:Ga.method)==="保存"});if(!Ne)return;const Q=(oe=(ie=pa.value[(T=(H=Ne==null?void 0:Ne.value)==null?void 0:H.pageData)==null?void 0:T.path])==null?void 0:ie.filter(Ua=>{var sl;return((sl=Ua==null?void 0:Ua.key)==null?void 0:sl.type)==="data"}))==null?void 0:oe.find(Ua=>{var sl,Ga,Da,dl;return((Ga=(sl=Ua==null?void 0:Ua.value)==null?void 0:sl.tableData)==null?void 0:Ga.算法名称)===((dl=(Da=Ne==null?void 0:Ne.value)==null?void 0:Da.pageData)==null?void 0:dl.method)});if(!Q)return;const je={buttonName:(ke=(K=Ne==null?void 0:Ne.value)==null?void 0:K.pageData)==null?void 0:ke.method,api:(Je=(ge=Q==null?void 0:Q.value)==null?void 0:ge.tableData)==null?void 0:Je.算法体,content:Ia==null?void 0:Ia.map(Ua=>{var sl;return(sl=Ua==null?void 0:Ua.value)==null?void 0:sl.pageData}),extraContent:[],extraValues:(ea=(Ue=Ne==null?void 0:Ne.value)==null?void 0:Ue.pageData)==null?void 0:ea.data,methodName:(Na=(ka=Ne==null?void 0:Ne.value)==null?void 0:ka.pageData)==null?void 0:Na.path};if(!f)return;const ha={...f,compData:(Aa=f==null?void 0:f.compData)==null?void 0:Aa.map(Ua=>{var sl;return(Ua==null?void 0:Ua.key)==="formContent"?{...Ua,contents:(sl=Ua==null?void 0:Ua.contents)==null?void 0:sl.map(Ga=>(Ga==null?void 0:Ga.prop)===v?{...Ga,value:""}:Ga)}:Ua})},B={key:{pageKey:de.value+I,parentTable:"",systemKey:sessionStorage.getItem("systemKey"),type:"structure"},value:{pageData:ha}},za=await Ja.axios.post(je.api,B,{headers:{"Content-Type":"application/json"}});return((la=za==null?void 0:za.data)==null?void 0:la.code)===200&&(Va=(xa=(ol=za==null?void 0:za.data)==null?void 0:ol.result)==null?void 0:xa.latestReportCode,ba=(be=(tl=za==null?void 0:za.data)==null?void 0:tl.result)==null?void 0:be.status),{newMainKeyValue:Va,newStatus:ba}}catch(Va){throw Ja.ElMessage.error(Va),new Error(Va)}},Ut=e.reactive({prop:"状态",value:""});e.ref(["系统自动生成信息","审批意见"]);const Au=async(f,v,z)=>{var K,ke;let L=f==null?void 0:f[v==null?void 0:v.prop],H=1,T,ie;const oe=M.cloneDeep(de).value+I+L;if(oe){Ut.value="",T=(K=pa.value[oe])==null?void 0:K.filter(Ue=>{var ea;return((ea=Ue==null?void 0:Ue.key)==null?void 0:ea.type)==="structure"});const ge=T==null?void 0:T.find(Ue=>{var ea,ka,Na;return((Na=(ka=(ea=Ue==null?void 0:Ue.value)==null?void 0:ea.pageData)==null?void 0:ka.comp)==null?void 0:Na.toUpperCase())==="FORM"});ie={...(ke=ge==null?void 0:ge.value)==null?void 0:ke.pageData,id:ge==null?void 0:ge.id};const Je=await Nu(ie,v==null?void 0:v.prop);if(Ut.value=Je==null?void 0:Je.newStatus,Je!=null&&Je.newMainKeyValue)return Je==null?void 0:Je.newMainKeyValue}if(Ce.value.some(ge=>(ge==null?void 0:ge[v==null?void 0:v.prop])===L)){const ge=L;for(;Ce.value.some(Je=>(Je==null?void 0:Je[v==null?void 0:v.prop])===`${ge}(${H})`);)H++;L=`${ge}(${H})`}return L},zu=async(f,v,z)=>{var T,ie,oe,K;let L,H;if(await Au(z==null?void 0:z.data,z==null?void 0:z.firstCol),L=M.cloneDeep(de).value+I,H=M.cloneDeep(L)+`loading${((T=Nl.value)==null?void 0:T.account)||((ie=Nl.value)==null?void 0:ie.账号)}`,v){const ke=(K=(oe=pa.value[H])==null?void 0:oe.filter(ge=>{var Je;return((Je=ge==null?void 0:ge.key)==null?void 0:Je.parentTable)===""}))==null?void 0:K.map(ge=>{var Je;return{id:ge==null?void 0:ge.id,...(Je=ge==null?void 0:ge.value)==null?void 0:Je.pageData}});(ke==null?void 0:ke.length)>0||await le.loadingConstruct(L,H,null,null,null),Ge.setRouteToChildPath(M.cloneDeep(de).value),Le.setActiveMenuPath(H)}else Ge.setRouteToChildPath(M.cloneDeep(de).value),Le.setActiveMenuPath(H)},Mu=()=>{te.value=!1,Be.value=[],N.value=!1},ji=f=>{var oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne,Q,je,ha;const v=[];ze.value=M.cloneDeep(W.value);let z=(K=(oe=u.value)==null?void 0:oe.find(B=>{var za;return(za=B==null?void 0:B.key)==null?void 0:za.includes("@EditRead")}))==null?void 0:K.content,L=!1;(z==null?void 0:z.length)>0&&(L=Bs(z,f),(L==null?void 0:L.length)>0?L=!0:L=!1),(ge=le.getColumnChild((ke=M.cloneDeep(W.value))==null?void 0:ke.filter(B=>(B==null?void 0:B.label)!=="操作")))==null||ge.forEach((B,za)=>{var Ua,sl,Ga;B!=null&&B.formType&&((Ua=B==null?void 0:B.formType)==null?void 0:Ua.toUpperCase())==="SELECT"||B!=null&&B.menuId?v.push({label:(sl=B==null?void 0:B.prop)!=null&&sl.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"+za,prop:B==null?void 0:B.prop,type:"Select",value:(f==null?void 0:f[B==null?void 0:B.prop])??(B==null?void 0:B.value)??"",id:(B==null?void 0:B.id)??za,contents:(B==null?void 0:B.options)??[],multiple:(B==null?void 0:B.multiple)??!1,multipleLimit:B==null?void 0:B.multipleLimit,width:2,isFormColHidden:B==null?void 0:B.isFormColHidden,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,allSelectionContents:(B==null?void 0:B.allSelectionContents)??[],filterContent:B==null?void 0:B.filterContent,disabled:(B==null?void 0:B.prop)==="disabled"?!0:L||(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:(Ga=B==null?void 0:B.prop)!=null&&Ga.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"+za,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"?(f==null?void 0:f[B==null?void 0:B.prop])??"{}":(f==null?void 0:f[B==null?void 0:B.prop])??(B==null?void 0:B.value)??"",id:(B==null?void 0:B.id)??za,contents:(B==null?void 0:B.options)??[],multiple:(B==null?void 0:B.multiple)??!1,width:2,isFormColHidden:B==null?void 0:B.isFormColHidden,disabled:(B==null?void 0:B.prop)==="disabled"?!0:L||(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})}),f===""||!f||(fa.value=(f==null?void 0:f.id)??"");let H=le.getColumnChild((Je=M.cloneDeep(W.value))==null?void 0:Je.filter(B=>(B==null?void 0:B.label)!=="操作"));na.value&&((Ue=na.value)==null?void 0:Ue.length)>0&&(na.value=(ea=M.cloneDeep(na).value)==null?void 0:ea.map(B=>{var Ua;let za=(B==null?void 0:B.prop)||((Ua=H==null?void 0:H.find(sl=>(sl==null?void 0:sl.label)===(B==null?void 0:B.label)))==null?void 0:Ua.prop);return za&&(B.value=f[za]),B})),ye.value=na.value&&((ka=na.value)==null?void 0:ka.length)>0?le.getTableFormToForm(na.value):v,ye.value=((Na=ye.value)==null?void 0:Na.map(B=>({...B,disabled:(B==null?void 0:B.prop)==="disabled"?!0:B==null?void 0:B.disabled})))??ye.value;let T=[],ie=((ol=(la=(Aa=d.itemData)==null?void 0:Aa.filter(B=>(B==null?void 0:B.key)==="filter"))==null?void 0:la[0])==null?void 0:ol.contents)??"";if(ie=le.analyzeSplitToContent(ie,","),(ie==null?void 0:ie.length)>0&&(T=ie.flat()),(T==null?void 0:T.length)>0){let B=T==null?void 0:T.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=(tl=(xa=B==null?void 0:B.replace("=",b))==null?void 0:xa.split(b))==null?void 0:tl[1];((be=Da==null?void 0:Da.trim())==null?void 0:be.toUpperCase())==="MANUAL"&&(d==null||d.index,ye.value=(Va=ye.value)==null?void 0:Va.map((dl,Wl)=>dl))}let za=(ba=ye.value)==null?void 0:ba.filter(Da=>Da==null?void 0:Da.mainKey),Ua;za==null||za.forEach(Da=>{var Wl;if(Ua!==void 0)return;let dl=Da==null?void 0:Da.menus;((Wl=za==null?void 0:za.filter(qa=>qa==null?void 0:qa.mainKey))==null?void 0:Wl.length)>1&&(Ua=dl,Da==null||Da.groups)});let sl=[],Ga=new Map;if(za==null||za.forEach(Da=>{var dl,Wl,qa,Tl,La,Ll,nl,vl,zl,xl,Cr,hr,cr;if((dl=Da==null?void 0:Da.prop)!=null&&dl.includes(".")){let _l=[];Ga.get(((qa=(Wl=Da==null?void 0:Da.prop)==null?void 0:Wl.split("."))==null?void 0:qa[0])+(Da!=null&&Da.isMainPath?0:1)+((Tl=Da==null?void 0:Da.groups)==null?void 0:Tl[0]))&&(_l=Ga.get(((Ll=(La=Da==null?void 0:Da.prop)==null?void 0:La.split("."))==null?void 0:Ll[0])+(Da!=null&&Da.isMainPath?0:1)+((nl=Da==null?void 0:Da.groups)==null?void 0:nl[0]))),_l.push(Da),Ga.set(((zl=(vl=Da==null?void 0:Da.prop)==null?void 0:vl.split("."))==null?void 0:zl[0])+(Da!=null&&Da.isMainPath?0:1)+((xl=Da==null?void 0:Da.groups)==null?void 0:xl[0]),_l)}else{let _l=[];Ga.get("normal"+(Da!=null&&Da.isMainPath?0:1)+((Cr=Da==null?void 0:Da.groups)==null?void 0:Cr[0]))&&(_l=Ga.get("normal"+(Da!=null&&Da.isMainPath?0:1)+((hr=Da==null?void 0:Da.groups)==null?void 0:hr[0]))),_l.push(Da),Ga.set("normal"+(Da!=null&&Da.isMainPath?0:1)+((cr=Da==null?void 0:Da.groups)==null?void 0:cr[0]),_l)}}),sl=Array.from(Ga.values()),(sl==null?void 0:sl.length)>0)for(let Da in sl){let dl=sl==null?void 0:sl[Da];if((dl==null?void 0:dl.length)!==1){if((dl==null?void 0:dl.length)>1){let Wl=dl==null?void 0:dl.map(xl=>xl==null?void 0:xl.prop),qa=dl==null?void 0:dl.map(xl=>xl==null?void 0:xl.label),Tl=dl==null?void 0:dl.map(xl=>xl==null?void 0:xl.value),La=(Ya=M.cloneDeep(dl))==null?void 0:Ya[0],Ll=(Ia=ye.value)==null?void 0:Ia.findIndex(xl=>(xl==null?void 0:xl.prop)===(La==null?void 0:La.prop)),nl=(Ne=ye.value)==null?void 0:Ne.slice(0,Ll),vl=(je=ye.value)==null?void 0:je.slice(Ll,(Q=ye.value)==null?void 0:Q.length);La.label=qa==null?void 0:qa.join("·"),La.value=Tl==null?void 0:Tl.join(" "),La.value.trim()===""&&(La.value=""),La.prop=Wl==null?void 0:Wl.join("·");let zl=dl==null?void 0:dl.map(xl=>{var Cr;return(Cr=xl==null?void 0:xl.words)==null?void 0:Cr.join(".")});La.relatedWords=zl,La.usingType="parent",vl.unshift(La),ye.value=[...nl,...vl],ye.value=(ha=ye.value)==null?void 0:ha.map(xl=>(Wl!=null&&Wl.find(Cr=>Cr===(xl==null?void 0:xl.prop))&&(xl.isFormColHidden=!0,xl.relatedWords=zl),xl))}}}}},Iu=()=>{var v;const f=(v=i.value)==null?void 0:v.$el;f&&Fl.Sortable.create(f,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:z=>{var ie;const{oldIndex:L,newIndex:H}=z;if(L===H)return;const T=Qn.value.splice(L,1)[0];Qn.value.splice(H,0,T),W.value=(ie=W.value)==null?void 0:ie.slice().sort((oe,K)=>{if(oe.label==="操作")return 1;if(K.label==="操作")return-1;const ke=Qn.value.findIndex(Je=>Je.label===oe.label),ge=Qn.value.findIndex(Je=>Je.label===K.label);return ke-ge})}})};e.onMounted(()=>{We.value=window.innerWidth-240*2,window.addEventListener("keydown",si)});const Ou=()=>{e.nextTick(()=>{Iu()})},Lu=()=>{c.value=!0},ft=(f,v)=>{var L;if(!f&&!(f!=null&&f.children))return{contents:f,currentSelectContents:void 0};let z;return f.children=(L=f.children)==null?void 0:L.map(H=>{var T,ie;if((H==null?void 0:H.id)===fa.value){let oe={};for(let K in H){let ke=(T=v==null?void 0:v.find(ge=>(ge==null?void 0:ge.prop)===K))==null?void 0:T.label;ke?oe[K]=(ie=Yl.value)==null?void 0:ie[ke]:oe[K]=H[K]??""}H=Object.assign(oe,Yl.value),z=H}else{let oe=ft(H,v);H=oe==null?void 0:oe.contents,z=oe==null?void 0:oe.currentSelectContents}return H}),{contents:f,currentSelectContents:z}},qt=(f,v)=>{let z,L;return f!=null&&f.find(H=>(H==null?void 0:H.id)===fa.value)?z=f==null?void 0:f.map(H=>{var T,ie,oe;if((H==null?void 0:H.id)===fa.value){let K={};for(let ge in H){let Je=(T=v==null?void 0:v.find(Ue=>(Ue==null?void 0:Ue.prop)===ge))==null?void 0:T.label;Je?K[ge]=((ie=Yl.value)==null?void 0:ie[Je])??"":K[ge]=H[ge]??""}let ke=Yl.value;for(let ge in K)(oe=Yl.value)!=null&&oe[ge]||(ke[ge]=(K==null?void 0:K[ge])??"");H=ke,L=H}return H}):z=f==null?void 0:f.map(H=>{var T,ie,oe,K;if((H==null?void 0:H.id)===fa.value){let ke={};for(let ge in H){let Je=(T=v==null?void 0:v.find(Ue=>(Ue==null?void 0:Ue.prop)===ge))==null?void 0:T.label;Je?ke[ge]=(ie=Yl.value)==null?void 0:ie[Je]:ke[ge]=H[ge]??""}H=Object.assign(ke,Yl.value),L=H}else H=(oe=ft(H,v))==null?void 0:oe.contents,L=(K=ft(H,v))==null?void 0:K.currentSelectContents;return H}),{newContents:z,currentSelectContents:L}},Wt=(f,v,z)=>{var L,H;return f[v==null?void 0:v.prop]=z,typeof f.id=="number"&&(f.id=(L=f.id)==null?void 0:L.toString()),f.children&&((H=f.children)==null?void 0:H.length)>0&&(f.children=f.children.map(Wt)),f},Gt=f=>{var z;const v=[];return v.push({...f}),f!=null&&f.children&&Array.isArray(f.children)&&((z=f.children)==null||z.forEach(L=>{v.push(...Gt(L))})),(v==null?void 0:v.length)>0?v==null?void 0:v.map(L=>{const H={...L};return delete H.children,H}):[]},po=["Pacific6000数据采集装置.通道号","通道号"],Hi=f=>{if(!f)return"";const v=po.map(z=>f==null?void 0:f[z]).find(z=>z!=null&&String(z).trim()!=="");return v==null?"":String(v).trim()},ht=async(f,v=void 0)=>{if(!f)return!1;try{const z=ea=>{var ka,Na,Aa;return ea?typeof(ea==null?void 0:ea.value)=="string"?ea.value:((Aa=(Na=(ka=ea==null?void 0:ea._custom)==null?void 0:ka.value)==null?void 0:Na.value)==null?void 0:Aa.value)||"":""},L=Array.isArray(nr.value)?nr.value:[],H=z(L.find(ea=>(ea==null?void 0:ea.condition)==="child")),T=(de.value||"").replace(/\/+$/,""),ie=H?`${T}/${H}`:T,oe=await Hr(ie||de.value,!1),K=String(Ve.value||"").trim(),ke=ea=>String(ea||"").trim(),ge=(ea,ka=[],Na="")=>{if(!Array.isArray(ea))return ka;for(const Aa of ea){const la=ke((Aa==null?void 0:Aa.choiceName)||(Aa==null?void 0:Aa.name0)||Na);(Aa==null?void 0:Aa.comp)==="Table"&&(!K||la===K)&&ka.push(Aa),Array.isArray(Aa==null?void 0:Aa.children)&&ge(Aa.children,ka,la),Array.isArray(Aa==null?void 0:Aa.tab)&&ge(Aa.tab,ka,la),Array.isArray(Aa==null?void 0:Aa.choice)&&ge(Aa.choice,ka,la)}return ka},Je=ge(oe||[]),Ue=String((d==null?void 0:d.compName)||"");return Je.some(ea=>{var Na,Aa;const ka=((Aa=(Na=ea==null?void 0:ea.compData)==null?void 0:Na.find(la=>(la==null?void 0:la.key)==="tableContents"))==null?void 0:Aa.contents)||[];return!Array.isArray(ka)||ka.length===0?!1:ka.some(la=>{if(String((ea==null?void 0:ea.name)||"")===Ue&&(la==null?void 0:la.id)===v)return!1;const xa=Hi(la);return!!xa&&xa===f})})}catch{return(Ce.value||[]).some(L=>{if((L==null?void 0:L.id)===v)return!1;const H=Hi(L);return!!H&&H===f})}},Ui=async(f=!0,v,z)=>{var ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl;if(Yl.value){const La=(ge=le.getColumnChild((ke=M.cloneDeep(W.value))==null?void 0:ke.filter(nl=>(nl==null?void 0:nl.label)!=="操作")))==null?void 0:ge.filter(nl=>(nl==null?void 0:nl.required)===!0);for(let nl=0;nl<((La==null?void 0:La.length)??0);nl++){const vl=La[nl],zl=vl==null?void 0:vl.prop,xl=(vl==null?void 0:vl.label)??zl,Cr=(Je=Yl.value)==null?void 0:Je[zl];if(Cr===""||Cr===null||Cr===void 0||Array.isArray(Cr)&&Cr.length===0){Ja.ElMessage.error(`${xl}不能为空`);return}}const Ll=Hi(Yl.value);if(Ll&&await ht(Ll,fa.value||void 0)){Ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择");return}}let L=le.getColumnChild((Ue=M.cloneDeep(W.value))==null?void 0:Ue.filter(La=>(La==null?void 0:La.label)!=="操作")),H,T=M.cloneDeep(Ce.value);if(!Yl.value){Qe.value=!1;return}if(fa.value===""){sa.value++;let La;La={id:sa.value.toString()};try{La.sort=ui(0,Ce.value||[])}catch{}La!=null&&La.children&&(La={...La,children:(ea=La.children)==null?void 0:ea.map(nl=>Wt(nl,v,z))});const Ll=Object.assign(Yl.value,La);T.unshift(Ll),H=Ll}else T=(ka=qt(T,L))==null?void 0:ka.newContents,H=(Na=qt(T,L))==null?void 0:Na.currentSelectContents;const ie=(Aa=d.itemData)==null?void 0:Aa.filter(La=>(La==null?void 0:La.key)==="childTree")[0];if(((la=ie==null?void 0:ie.contents)==null?void 0:la.length)>0){ma.value="编辑";const La=[];T==null||T.forEach((vl,zl)=>{var Cr;let xl={};if(Array.isArray(vl)){let hr=[];vl==null||vl.filter(cr=>!(cr!=null&&cr.id)).forEach((cr,_l)=>{var rr,mr,Il,yr,Dr,gr,Mr;if((mr=(rr=lr.value)==null?void 0:rr[_l])!=null&&mr.prop&&!Array.isArray(cr)){let tn={};tn[lr.value[_l].column]=cr,V!=null&&V.value&&((Il=V==null?void 0:V.value)==null?void 0:Il.length)>0&&((yr=V==null?void 0:V.value)!=null&&yr.find(vr=>JSON.stringify(vr==null?void 0:vr[0])===JSON.stringify(tn)))&&(hr=(Dr=V==null?void 0:V.value)==null?void 0:Dr.find(vr=>JSON.stringify(vr==null?void 0:vr[0])===JSON.stringify(tn))),hr&&hr.length>0?xl[lr.value[_l].prop]=hr!=null&&hr.find(vr=>{var Or;return((Or=Object.keys(vr))==null?void 0:Or[0])===lr.value[_l].column})?(gr=hr==null?void 0:hr.find(vr=>{var Or;return((Or=Object.keys(vr))==null?void 0:Or[0])===lr.value[_l].column}))==null?void 0:gr[lr.value[_l].column]:cr:xl[lr.value[_l].prop]=cr}else Array.isArray(cr)&&((Mr=lr.value[_l])!=null&&Mr.prop?xl[lr.value[_l].prop]=cr:xl.children=Nt(cr,lr.value))})}else xl=vl;if(Array.isArray(vl)&&vl.some(hr=>hr==null?void 0:hr.id)){const hr=(Cr=vl==null?void 0:vl.find(cr=>cr.id))==null?void 0:Cr.id;La.push(Object.assign(xl,{id:to(hr)}))}else xl.id?La.push(xl):La.push(Object.assign(xl,{id:zl.toString()}))});const Ll=(Ce.value||[]).map(vl=>String(vl==null?void 0:vl.id)),nl=_i(La,Ll);Ce.value=Xt(nl,ie,W.value)}Yt(Ce.value),Sr.value=Ce.value;const oe=g0(Sr.value,$l.value,T);let K=[];if(ee.value?(K=(ol=M.cloneDeep(ee).value.singleContent)==null?void 0:ol.filter(La=>(La==null?void 0:La.id)!==(H==null?void 0:H.id)),K.push(H)):K=[H],er.value){const La={content:oe,singleContent:((xa=ie==null?void 0:ie.contents)==null?void 0:xa.length)>0?K==null?void 0:K.flatMap(Gt):K,index:d==null?void 0:d.index,buttonName:"编辑",column:W.value,parentTableId:d==null?void 0:d.parentTableId};Ge.setCacheUpdatingData(La)}if((tl=W.value)==null||tl.forEach(La=>{(La==null?void 0:La.formType)==="Upload"&&(H[La.prop]=H[La.prop]===""?"{}":typeof H[La.prop]!="string"?JSON.stringify(H[La.prop]):H[La.prop])}),f){(Ya=(ba=(Va=(be=d.itemData)==null?void 0:be.find(nl=>(nl==null?void 0:nl.key)==="filterAllType"))==null?void 0:Va.value)==null?void 0:ba.find(nl=>(nl==null?void 0:nl.value)==="onConditionContents"))==null||Ya.content;let La=(Ia=d.itemData)==null?void 0:Ia.filter(nl=>(nl==null?void 0:nl.key)==="filterAllType");La=Array.from(new Map(La.filter(Boolean).map((nl,vl)=>[nl.value,{...nl,_idx:vl}])).values()).sort((nl,vl)=>nl._idx-vl._idx).map(({_idx:nl,...vl})=>vl),La=(Ne=La==null?void 0:La[(La==null?void 0:La.length)-1])==null?void 0:Ne.value;const Ll={fixContent:[H],buttonName:ma.value,relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames};Ge.setTableLoading(d==null?void 0:d.index),Qe.value=!1,Yl.value=void 0,U("change",Ll)}if((ha=(je=(Q=ye.value)==null?void 0:Q[0])==null?void 0:je.optionUrl)!=null&&ha.menuId){Qe.value=!1;let La=(B=d.itemData)==null?void 0:B.filter(Ll=>(Ll==null?void 0:Ll.key)==="filterAllType");if((La==null?void 0:La.length)>0){let Ll=La==null?void 0:La.map(zl=>zl==null?void 0:zl.value),nl=(sl=(Ua=(za=Ll.flat().find(zl=>{var xl;return(xl=zl==null?void 0:zl.content)==null?void 0:xl.includes("@Num")}))==null?void 0:za.content)==null?void 0:Ua.split(":"))==null?void 0:sl[1];((dl=(Da=(Ga=Ll.flat().find(zl=>{var xl;return(xl=zl==null?void 0:zl.content)==null?void 0:xl.includes("@Type:")}))==null?void 0:Ga.content)==null?void 0:Da.split(":"))==null?void 0:dl[1])!=="Manual"&&(nl=parseInt(nl),Ce.value=(Tl=Ce.value)==null?void 0:Tl.slice(((Wl=Ce.value)==null?void 0:Wl.length)-nl,(qa=Ce.value)==null?void 0:qa.length))}}};e.onUnmounted(()=>{window.removeEventListener("keydown",si),W.value=[],Ce.value=[],ze.value=[],P.value=[],na.value=[],va.value=[],Be.value=[],Ye.value=[],ye.value=[],Br.value=[],i.value=null,rn.value=""});const fo=async(f,v,z)=>{var ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia;Tr.value=(z==null?void 0:z.prop)??(z==null?void 0:z.property);const L=M.cloneDeep(d.itemData),H=((ea=L==null?void 0:L.find(Ne=>(Ne==null?void 0:Ne.key)==="header"))==null?void 0:ea.contents)??[];let T=H==null?void 0:H.find((Ne,Q)=>{var je,ha,B;return(Ne==null?void 0:Ne.prop)===Tr.value||(Ne==null?void 0:Ne.label)===Tr.value||(Q==null?void 0:Q.toString())===((B=(ha=(je=Tr.value)==null?void 0:je.split("a"))==null?void 0:ha[1])==null?void 0:B.toString())});const ie=le.getColumnChild((ka=M.cloneDeep(W.value))==null?void 0:ka.filter(Ne=>(Ne==null?void 0:Ne.label)!=="操作"));if(T||(T=ie==null?void 0:ie.find(Ne=>(Ne==null?void 0:Ne.prop)===Tr.value||(Ne==null?void 0:Ne.label)===Tr.value)),T&&!((Na=T==null?void 0:T.menus)!=null&&Na.length)&&!((Aa=T==null?void 0:T.groups)!=null&&Aa.length)&&!((la=T==null?void 0:T.words)!=null&&la.length)){const Ne=(ol=ye.value)==null?void 0:ol.find(Q=>(Q==null?void 0:Q.prop)===Tr.value);Ne&&(T={...T,menus:(Ne==null?void 0:Ne.menus)??(T==null?void 0:T.menus),groups:(Ne==null?void 0:Ne.groups)??(T==null?void 0:T.groups),words:(Ne==null?void 0:Ne.words)??(T==null?void 0:T.words),bindMenus:(Ne==null?void 0:Ne.bindMenus)??(T==null?void 0:T.bindMenus),isMainPath:(Ne==null?void 0:Ne.isMainPath)??(T==null?void 0:T.isMainPath),relatedContents:(Ne==null?void 0:Ne.relatedContents)??(T==null?void 0:T.relatedContents),endChildMenu:(Ne==null?void 0:Ne.endChildMenu)??(T==null?void 0:T.endChildMenu)})}if(T&&((xa=ye==null?void 0:ye.value)==null||xa.forEach(Ne=>{var Q,je,ha,B,za;(Ne==null?void 0:Ne.prop)===(T==null?void 0:T.prop)&&(Ne!=null&&Ne.endChildMenu)&&((Q=T==null?void 0:T.prop)!=null&&Q.includes(".")&&((ha=(je=T==null?void 0:T.prop)==null?void 0:je.split("."))==null?void 0:ha[0])!==((za=(B=Ne==null?void 0:Ne.prop)==null?void 0:B.split("."))==null?void 0:za[0])?T.endChildMenu=Ne==null?void 0:Ne.value:T.endChildMenu=Ne==null?void 0:Ne.endChildMenu)})),!T)return;const oe=Tr.value,K=(tl=Ce.value)==null?void 0:tl.findIndex(Ne=>(Ne==null?void 0:Ne.id)===(v==null?void 0:v.id));K!==-1&&oe&&(Ce.value[K]={...Ce.value[K],[oe]:f});const ke=Ne=>{Array.isArray(Ne)&&Ne.forEach(Q=>{Array.isArray(Q==null?void 0:Q.allSelectionContents)&&Q.allSelectionContents.length>0&&(Q.contactValue=Ce.value[K]??v),Array.isArray(Q==null?void 0:Q.children)&&Q.children.length>0&&ke(Q.children)})};ke(W.value),T.value=f,T.endChildMenu=T.endChildMenu||"";let ge=T!=null&&T.isMainPath&&(T!=null&&T.mainKey)?T==null?void 0:T.value:"";const Je=Ne=>{Array.isArray(Ne)&&Ne.forEach(Q=>{var ha,B;if(((Q==null?void 0:Q.type)==="Select"||(Q==null?void 0:Q.formType)&&Q.formType.toUpperCase()==="SELECT"||(Q==null?void 0:Q.columnType)&&Q.columnType.toUpperCase()==="SELECT")&&Array.isArray(Q==null?void 0:Q.menus)&&Q.menus.length>0&&Q.menus[Q.menus.length-1]===""&&(T!=null&&T.isMainPath)&&(T!=null&&T.mainKey)){const za=(ha=Q==null?void 0:Q.prop)!=null&&ha.includes(".")?Q.prop.split(".")[0]:null,Ua=(B=T==null?void 0:T.prop)!=null&&B.includes(".")?T.prop.split(".")[0]:null;(!za||!Ua||za===Ua)&&(Q.endChildMenu=ge)}Array.isArray(Q==null?void 0:Q.children)&&Q.children.length>0&&Je(Q.children)})};if(Je(W.value),!!(T!=null&&T.mainKey)&&Array.isArray(T==null?void 0:T.menus)&&(T==null?void 0:T.menus.length)>0&&(T!=null&&T.value)&&(T==null?void 0:T.value)!==""){let Ne=T!=null&&T.relatedContents&&((be=T==null?void 0:T.relatedContents)==null?void 0:be.length)>0?(Va=T==null?void 0:T.relatedContents)==null?void 0:Va.find(Q=>{var je,ha,B,za;return(Q==null?void 0:Q[(za=(je=T==null?void 0:T.prop)==null?void 0:je.split("."))==null?void 0:za[((B=(ha=T==null?void 0:T.prop)==null?void 0:ha.split("."))==null?void 0:B.length)-1]])===(T==null?void 0:T.value)}):await Es(T);if(Ne){const Q={...v};ie==null||ie.forEach(je=>{var ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl,zl;(je==null?void 0:je.prop)!==(T==null?void 0:T.prop)&&(T!=null&&T.relatedContents&&((ha=T==null?void 0:T.relatedContents)==null?void 0:ha.length)>0?(B=je==null?void 0:je.prop)!=null&&B.includes(".")&&((Ua=(za=je==null?void 0:je.prop)==null?void 0:za.split("."))==null?void 0:Ua[0])===((Ga=(sl=T==null?void 0:T.prop)==null?void 0:sl.split("."))==null?void 0:Ga[0])?Q[je.prop]=Ne[(qa=(Da=je==null?void 0:je.prop)==null?void 0:Da.split("."))==null?void 0:qa[((Wl=(dl=je==null?void 0:je.prop)==null?void 0:dl.split("."))==null?void 0:Wl.length)-1]]??Q[je.prop]:Q[je.prop]=(Ne==null?void 0:Ne[je.prop])??Q[je.prop]:le.same((T==null?void 0:T.menus)??[],(je==null?void 0:je.menus)??[])&&le.same((T==null?void 0:T.groups)??[],(je==null?void 0:je.groups)??[])&&!le.same((T==null?void 0:T.words)??[],(je==null?void 0:je.words)??[])?(Tl=je==null?void 0:je.prop)!=null&&Tl.includes(".")&&((Ll=(La=je==null?void 0:je.prop)==null?void 0:La.split("."))==null?void 0:Ll[0])!==((vl=(nl=T==null?void 0:T.prop)==null?void 0:nl.split("."))==null?void 0:vl[0])||(Q[je.prop]=(Ne==null?void 0:Ne[(zl=je==null?void 0:je.words)==null?void 0:zl.join(".")])??(Ne==null?void 0:Ne[je.prop])??Q[je.prop]):(!(je!=null&&je.isMainPath)&&le.same((T==null?void 0:T.bindMenus)??[],(je==null?void 0:je.bindMenus)??[]),Q[je.prop]=(Ne==null?void 0:Ne[je.prop])??Q[je.prop]))}),Ce.value=(ba=M.cloneDeep(Ce.value))==null?void 0:ba.map(je=>(je==null?void 0:je.id)===(v==null?void 0:v.id)?{...Q,id:je==null?void 0:je.id}:je)}}if((Ya=T==null?void 0:T.optionUrl)!=null&&Ya.menuSelect){let Ne="";ie==null||ie.forEach(ha=>{var B,za,Ua,sl,Ga;Ne===""&&((Ua=(za=(B=ha==null?void 0:ha.optionUrl)==null?void 0:B.groupSelect)==null?void 0:za[1])!=null&&Ua.includes("["))&&(Ne=(Ga=(sl=ha==null?void 0:ha.optionUrl)==null?void 0:sl.groupSelect)==null?void 0:Ga[1])});let Q=await At(T),je;if(Q==null||Q.forEach(ha=>{var B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl;Ne===((za=(B=T==null?void 0:T.optionUrl)==null?void 0:B.groupSelect)==null?void 0:za[1])&&((Ga=(sl=(Ua=T==null?void 0:T.optionUrl)==null?void 0:Ua.groupSelect)==null?void 0:sl[1])!=null&&Ga.includes("["))&&((Tl=M.cloneDeep(ha))==null?void 0:Tl[(qa=(Wl=(dl=(Da=T==null?void 0:T.optionUrl)==null?void 0:Da.groupSelect)==null?void 0:dl[1])==null?void 0:Wl.replaceAll("[",""))==null?void 0:qa.replaceAll("]","")])===(T==null?void 0:T.value)&&(je=ha)}),je){const ha={...v};ie==null||ie.forEach(B=>{var za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll;(je!=null&&je[B==null?void 0:B.label]||je!=null&&je[(Ga=(sl=(Ua=(za=B==null?void 0:B.optionUrl)==null?void 0:za.groupSelect)==null?void 0:Ua[1])==null?void 0:sl.replaceAll("[",""))==null?void 0:Ga.replaceAll("]","")])&&((Wl=(dl=(Da=B==null?void 0:B.optionUrl)==null?void 0:Da.groupSelect)==null?void 0:dl[1])!=null&&Wl.includes("["))&&(ha[B.prop]=(je==null?void 0:je[B==null?void 0:B.label])||(je==null?void 0:je[(Ll=(La=(Tl=(qa=B==null?void 0:B.optionUrl)==null?void 0:qa.groupSelect)==null?void 0:Tl[1])==null?void 0:La.replaceAll("[",""))==null?void 0:Ll.replaceAll("]","")]))}),Ce.value=(Ia=M.cloneDeep(Ce.value))==null?void 0:Ia.map(B=>(B==null?void 0:B.id)===(v==null?void 0:v.id)?{...ha,id:B==null?void 0:B.id}:B)}}},Ru=async f=>{var ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne;if(!f)return;const v=M.cloneDeep(Yl.value||{});Yl.value=f;const z=Hi(v),L=Hi(Yl.value);if(L&&L!==z&&await ht(L,fa.value||void 0)){Ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择"),po.forEach(je=>{if(Object.prototype.hasOwnProperty.call(Yl.value||{},je)||Object.prototype.hasOwnProperty.call(v||{},je)){const ha=(v==null?void 0:v[je])??"";Yl.value[je]=ha,f[je]=ha}}),ye.value=(ye.value||[]).map(je=>{if(!(je!=null&&je.prop)||!po.includes(je.prop))return je;const ha=(v==null?void 0:v[je.prop])??"";return{...je,value:ha,selectValue:ha===""?[]:[ha]}});return}let H=M.cloneDeep(d.itemData);H==null||H.map(Q=>{var je,ha,B,za;return(Q==null?void 0:Q.key)==="header"&&(Array.isArray((je=Q.contents)==null?void 0:je[0])?Q.contents=(B=le.getColumnChild((ha=Q.contents)==null?void 0:ha[0]))==null?void 0:B.map((Ua,sl)=>{var Ga,Da,dl,Wl,qa,Tl;return((dl=(Da=(Ga=ye.value)==null?void 0:Ga.find(La=>(La==null?void 0:La.prop)===(Ua==null?void 0:Ua.prop)))==null?void 0:Da.optionUrl)==null?void 0:dl.multiple)===!0&&!Array.isArray((Wl=Object.values(f))==null?void 0:Wl[sl])?Ua.value=[(qa=Object.values(f))==null?void 0:qa[sl]]:Ua.value=(Tl=Object.values(f))==null?void 0:Tl[sl],Ua}):Q.contents=(za=Q.contents)==null?void 0:za.map((Ua,sl)=>{var Ga,Da,dl,Wl,qa,Tl;return((dl=(Da=(Ga=ye.value)==null?void 0:Ga.find(La=>(La==null?void 0:La.prop)===(Ua==null?void 0:Ua.prop)))==null?void 0:Da.optionUrl)==null?void 0:dl.multiple)===!0&&!Array.isArray((Wl=Object.values(f))==null?void 0:Wl[sl])?Ua.value=[(qa=Object.values(f))==null?void 0:qa[sl]]:Ua.value=(Tl=Object.values(f))==null?void 0:Tl[sl],Ua})),Q});let T=ye.value,ie=(ea=H==null?void 0:H.find(Q=>(Q==null?void 0:Q.key)==="header"))==null?void 0:ea.contents;if(Tr.value||(T=T==null?void 0:T.map(Q=>{var je;return Q.value=Q.value??((je=ie==null?void 0:ie.find((ha,B)=>(ha==null?void 0:ha.prop)===(Q==null?void 0:Q.name)))==null?void 0:je.value),Q})),!gn.value)return;let oe=M.cloneDeep(Tr.value);(ka=Tr.value)!=null&&ka.includes("·")&&(Tr.value=(Aa=(Na=Tr.value)==null?void 0:Na.split("·"))==null?void 0:Aa[0]);let K=(ol=(la=H==null?void 0:H.find(Q=>(Q==null?void 0:Q.key)==="header"))==null?void 0:la.contents)==null?void 0:ol.find((Q,je)=>(Q==null?void 0:Q.prop)===Tr.value);(xa=ye==null?void 0:ye.value)==null||xa.forEach(Q=>{var je,ha,B,za,Ua,sl,Ga,Da,dl;(Q==null?void 0:Q.prop)===(K==null?void 0:K.prop)&&(Q!=null&&Q.endChildMenu)&&((je=K==null?void 0:K.prop)!=null&&je.includes(".")&&((B=(ha=K==null?void 0:K.prop)==null?void 0:ha.split("."))==null?void 0:B[0])!==((Ua=(za=Q==null?void 0:Q.prop)==null?void 0:za.split("."))==null?void 0:Ua[0])?K.endChildMenu=(Ga=(sl=Q==null?void 0:Q.value)==null?void 0:sl.split(" "))==null?void 0:Ga[0]:K.endChildMenu=(dl=(Da=Q==null?void 0:Q.endChildMenu)==null?void 0:Da.split(" "))==null?void 0:dl[0])});let ke=K!=null&&K.isMainPath&&(K!=null&&K.mainKey)?K==null?void 0:K.value:"",ge=T,Je=ae.value;if(Je!=null&&Je.find(Q=>(K==null?void 0:K.prop)===(Q==null?void 0:Q.key))&&(Je=Je==null?void 0:Je.filter(Q=>(K==null?void 0:K.prop)!==(Q==null?void 0:Q.key))),Je!=null&&Je.find(Q=>oe===(Q==null?void 0:Q.key))&&(Je=Je==null?void 0:Je.filter(Q=>oe!==(Q==null?void 0:Q.key))),(K==null?void 0:K.formType)==="Select"?ge=ge==null?void 0:ge.map(Q=>{var je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl;return(Q==null?void 0:Q.type)==="Select"&&(((je=Q==null?void 0:Q.allSelectionContents)==null?void 0:je.length)>0&&(Q.contactValue=f),((K==null?void 0:K.prop)===(Q==null?void 0:Q.prop)||oe===(Q==null?void 0:Q.prop))&&K&&(Array.isArray(K.value)&&((ha=K.value)==null?void 0:ha.length)>0&&((B=K.value)!=null&&B.every(zl=>typeof zl=="string"))?(Je.push({key:Q==null?void 0:Q.prop,value:[(Ua=K.value)==null?void 0:Ua[((za=K.value)==null?void 0:za.length)-1]]}),Q.selectValue=(sl=Je==null?void 0:Je.find(zl=>(zl==null?void 0:zl.key)===(Q==null?void 0:Q.prop)))==null?void 0:sl.value):Array.isArray(K.value)&&((Ga=K.value)==null?void 0:Ga.length)===0?(Je=[],Q.selectValue=[],f[Q==null?void 0:Q.prop]=""):Array.isArray(Q.value)&&Je.push({key:Q==null?void 0:Q.prop,value:[(Da=Q.value)==null?void 0:Da[(Q==null?void 0:Q.length)-1]]})),((Wl=Q==null?void 0:Q.menus)==null?void 0:Wl[((dl=Q==null?void 0:Q.menus)==null?void 0:dl.length)-1])===""&&(K!=null&&K.isMainPath)&&(K!=null&&K.mainKey)&&((qa=Q==null?void 0:Q.prop)!=null&&qa.includes(".")&&((La=(Tl=Q==null?void 0:Q.prop)==null?void 0:Tl.split("."))==null?void 0:La[0])!==((nl=(Ll=K==null?void 0:K.prop)==null?void 0:Ll.split("."))==null?void 0:nl[0])||(Q.endChildMenu=(vl=ke==null?void 0:ke.split(" "))==null?void 0:vl[0]))),Q.value=(f==null?void 0:f[Q==null?void 0:Q.prop])??(Q==null?void 0:Q.value),Q}):(K==null?void 0:K.formType)!=="Input"&&(ge=ge==null?void 0:ge.map(Q=>(Q.value=(f==null?void 0:f[Q==null?void 0:Q.prop])??(Q==null?void 0:Q.value),Q))),ae.value=Je,ge!=null&&ge.some(Q=>(Q==null?void 0:Q.functionName)&&(Q==null?void 0:Q.functionName)!=="")){let Q=await Bt([f],W==null?void 0:W.value,"Auto",Ce.value),je=[];(tl=ge==null?void 0:ge.filter(B=>(B==null?void 0:B.functionName)&&(B==null?void 0:B.functionName)!==""))==null||tl.forEach(B=>{var za;((za=B==null?void 0:B.functionRelatedWords)==null?void 0:za.length)>0&&(je=[...je,...B==null?void 0:B.functionRelatedWords])}),je=je==null?void 0:je.filter(B=>(B==null?void 0:B[0])!=="@");let ha=[];for(let B in Q==null?void 0:Q[0])je!=null&&je.find(za=>B===za||(B==null?void 0:B.includes("."+za)))&&ha.push(((be=Q==null?void 0:Q[0])==null?void 0:be[B])!=="");(Q==null?void 0:Q.length)>0&&ha.every(B=>B)&&(ge=ge==null?void 0:ge.map(B=>{var za;return B.value=((za=Q==null?void 0:Q[0])==null?void 0:za[B==null?void 0:B.prop])??B.value,B})),Yl.value=Q==null?void 0:Q[0]}if(ye.value=ge,K=Object.assign({},K??{},{relatedWords:(ba=(Va=ye==null?void 0:ye.value)==null?void 0:Va.find(Q=>(Q==null?void 0:Q.prop)===(K==null?void 0:K.prop)))==null?void 0:ba.relatedWords}),(K==null?void 0:K.mainKey)&&(K!=null&&K.value)&&(K==null?void 0:K.value)!==""){let Q=K!=null&&K.relatedContents&&((Ya=K==null?void 0:K.relatedContents)==null?void 0:Ya.length)>0?(Ia=K==null?void 0:K.relatedContents)==null?void 0:Ia.find(je=>{var ha,B,za,Ua;return(je==null?void 0:je[(Ua=(ha=K==null?void 0:K.prop)==null?void 0:ha.split("."))==null?void 0:Ua[((za=(B=K==null?void 0:K.prop)==null?void 0:B.split("."))==null?void 0:za.length)-1]])===(K==null?void 0:K.value)}):await Es(K);if(Q&&JSON.stringify(Q)!=="{}"){let je=ge;je=je==null?void 0:je.map(B=>{var za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl,zl,xl,Cr,hr,cr,_l,rr,mr;if((K==null?void 0:K.prop)===(B==null?void 0:B.prop))B.value=(Q==null?void 0:Q[(za=B==null?void 0:B.words)==null?void 0:za.join(".")])??(Q==null?void 0:Q[B==null?void 0:B.prop])??Q[(Da=(Ua=B==null?void 0:B.prop)==null?void 0:Ua.split("."))==null?void 0:Da[((Ga=(sl=B==null?void 0:B.prop)==null?void 0:sl.split("."))==null?void 0:Ga.length)-1]];else if(K!=null&&K.relatedContents&&((dl=K==null?void 0:K.relatedContents)==null?void 0:dl.length)>0)B.value=(Wl=B==null?void 0:B.prop)!=null&&Wl.includes(".")&&((Tl=(qa=B==null?void 0:B.prop)==null?void 0:qa.split("."))==null?void 0:Tl[0])===((Ll=(La=K==null?void 0:K.prop)==null?void 0:La.split("."))==null?void 0:Ll[0])?Q[(xl=(nl=B==null?void 0:B.prop)==null?void 0:nl.split("."))==null?void 0:xl[((zl=(vl=B==null?void 0:B.prop)==null?void 0:vl.split("."))==null?void 0:zl.length)-1]]:(Q==null?void 0:Q[B==null?void 0:B.prop])??(B==null?void 0:B.value);else if(le.same((K==null?void 0:K.menus)??[],(B==null?void 0:B.menus)??[])&&le.same((K==null?void 0:K.groups)??[],(B==null?void 0:B.groups)??[])&&!le.same((K==null?void 0:K.words)??[],(B==null?void 0:B.words)??[]))if((Cr=B==null?void 0:B.prop)!=null&&Cr.includes(".")&&((cr=(hr=B==null?void 0:B.prop)==null?void 0:hr.split("."))==null?void 0:cr[0])!==((rr=(_l=K==null?void 0:K.prop)==null?void 0:_l.split("."))==null?void 0:rr[0])){let Il=Object.keys(Q);Il=Il==null?void 0:Il.find(yr=>{var Dr;return yr==null?void 0:yr.includes("."+((Dr=B==null?void 0:B.words)==null?void 0:Dr.join(".")))}),B.value=(Q==null?void 0:Q[Il])??(Q==null?void 0:Q[B==null?void 0:B.prop])??B.value}else{let Il=Object.keys(Q);Il=Il==null?void 0:Il.find(yr=>{var Dr;return yr==null?void 0:yr.includes("."+((Dr=B==null?void 0:B.words)==null?void 0:Dr.join(".")))}),B.value=(Q==null?void 0:Q[(mr=B==null?void 0:B.words)==null?void 0:mr.join(".")])??(Q==null?void 0:Q[Il])??(Q==null?void 0:Q[B==null?void 0:B.prop])??B.value}else!(B!=null&&B.isMainPath)&&le.same((K==null?void 0:K.bindMenus)??[],(B==null?void 0:B.bindMenus)??[]),B.value=(Q==null?void 0:Q[B==null?void 0:B.prop])??B.value;return B}),ye.value=je;let ha={};(Ne=ye.value)==null||Ne.forEach(B=>{ha[B.prop]=B==null?void 0:B.value}),Yl.value=ha}}gn.value=!0,j.value=!1},$u=f=>f?(f==null?void 0:f.toUpperCase())==="INPUT"?"TEXTAREA":f:"TEXTAREA",Vu=f=>{var T,ie;const v=(ie=(T=na.value)==null?void 0:T.find(oe=>(oe==null?void 0:oe.label)===(f==null?void 0:f.label)))==null?void 0:ie.multiple,z=f==null?void 0:f.prop;if((f==null?void 0:f.formType)!="Select")return;Ce.value.forEach(oe=>{const K=oe==null?void 0:oe[z];v&&To.isString(K)&&(oe[z]=[K]),!v&&!To.isString(K)&&(oe[z]="")})},Kt=(f,v)=>{var z;return v==null||v.forEach(L=>{f[L==null?void 0:L.prop]=L==null?void 0:L.value}),f.children&&((z=f.children)==null?void 0:z.length)>0&&(f.children=f.children.map(L=>Kt(L,v))),f},vt=f=>{var z,L,H,T,ie,oe;ji("");const v=(z=ye.value)==null?void 0:z.reduce((K,ke)=>(K[ke.name]=ke.value,K),{});if(((L=Object.keys(v))==null?void 0:L.length)>0){Yl.value=v,fa.value="",sa.value=(H=Ce.value)==null?void 0:H.length,Ye.value=(T=Ee.value)==null?void 0:T.filter(ke=>(ke==null?void 0:ke.label)!=="新增");const K=(oe=(ie=ze.value)==null?void 0:ie.filter(ke=>(ke==null?void 0:ke.label)!=="操作"))==null?void 0:oe.map(ke=>{var Je,Ue,ea;const ge=(Ue=(Je=na.value)==null?void 0:Je.find(ka=>(ka==null?void 0:ka.label)===(ke==null?void 0:ke.label)))==null?void 0:Ue.multiple;return Vu(ke),{...ke,contents:(ke==null?void 0:ke.options)??[],optionUrl:ke!=null&&ke.formMenuSelect&&((ea=ke==null?void 0:ke.formMenuSelect)==null?void 0:ea.length)>0?{groupSelect:ke==null?void 0:ke.groupSelect,menuSelect:ke==null?void 0:ke.formMenuSelect,selectRelateType:"",type:ke==null?void 0:ke.formType,multiple:ge}:null}});W.value=K==null?void 0:K.map(ke=>Kt(ke,[{prop:"type",value:"edit"},{prop:"columnType",value:$u(ke==null?void 0:ke.formType)||(ke==null?void 0:ke.columnType)}])),f==="createClick"&&(ma.value="新增",Ui(!0))}},Ei={START:"开始时间",END:"结束时间",HOURS:"工时"},Fu=(f,v)=>Number(M.dayjs(v).diff(M.dayjs(f),"day",!0).toFixed(1)),Yt=f=>{var T;const v=d.itemData,z=(T=v==null?void 0:v.find(ie=>(ie==null?void 0:ie.key)==="header"))==null?void 0:T.contents,L=new Map;return z==null||z.forEach((ie,oe)=>{const{label:K}=ie;L.set(K,oe)}),!L.has(Ei.START)||!L.has(Ei.END)||!L.has(Ei.HOURS)?f:f==null?void 0:f.map(ie=>{const oe=ie==null?void 0:ie[Ei.START],K=ie==null?void 0:ie[Ei.END],ke=Fu(oe,K);return oe&&K&&(ie[Ei.HOURS]=`${ke}天`),ie})},Jt=(f,v,z=0)=>{if(z>((v==null?void 0:v.length)??""))return f;const L=v==null?void 0:v[z],H=new Map;for(const ie of f){const oe=ie[L];H.has(oe)||H.set(oe,[]),H.get(oe)&&H.get(oe).push(ie)}const T=[];for(const[ie,oe]of H){const[K,...ke]=oe,ge={...K};z+1===((v==null?void 0:v.length)??"")?ge.children=oe==null?void 0:oe.map(Je=>(Je.level=M.cloneDeep(z)+1,Je)).filter((Je,Ue)=>Ue!==0):ke.length>0&&(ge.children=Jt(ke,v,z+1)),ge.level=z,T.push(ge)}return T},Xt=(f,v,z)=>{var H;if(!(v!=null&&v.contents)||((H=v==null?void 0:v.contents)==null?void 0:H.length)===0)return f;let L=[];return L=Jt(f,v==null?void 0:v.contents,0),L},Zt=async(f,v)=>{var ol,xa,tl,be,Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl,zl,xl,Cr,hr,cr,_l,rr,mr,Il,yr,Dr,gr,Mr,tn,vr,Or,Fr,es,as,ls,rs,ns,is;const z=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="header");f==null||f.filter(ta=>(ta==null?void 0:ta.key)==="tableIndexColumn")[0];const L=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="childTree")[0];let H=!0;if((tl=(xa=(ol=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="filterAllType"))==null?void 0:ol.value)==null?void 0:xa.find(ta=>(ta==null?void 0:ta.value)==="onPamButtonContents"))!=null&&tl.content){let ta=(ba=(Va=(be=f==null?void 0:f.find(Al=>(Al==null?void 0:Al.key)==="filterAllType"))==null?void 0:be.value)==null?void 0:Va.find(Al=>(Al==null?void 0:Al.value)==="onPamButtonContents"))==null?void 0:ba.content;ta=(Ya=ta==null?void 0:ta.split(":"))==null?void 0:Ya[1],ta=(Ia=ta.slice(1,(ta==null?void 0:ta.length)-1))==null?void 0:Ia.split(","),H=!!(ta!=null&&ta.find(Al=>Al==="操作"))}const T=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="page"),ie=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="rowButton"),oe=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="extraButton"),K=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="tableContents"),ke=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="bottomButton");let ge=[],Je=(Ne=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="filter"))==null?void 0:Ne[0];Je=(Je==null?void 0:Je.contents)??"",Je=O0(Je),(Je==null?void 0:Je.length)>0&&(u.value=Je);const Ue=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="tableIndex");na.value=(je=(Q=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="tableToForm"))==null?void 0:Q[0])==null?void 0:je.contents,Pe.value=(T==null?void 0:T.contents)??!0;let ea=[];Ql.value===""?ea=z==null?void 0:z[0]:ea=(z==null?void 0:z.find(ta=>(ta==null?void 0:ta.selectLabel)==="("+Ql.value+")"))??(z==null?void 0:z.find(ta=>!(ta!=null&&ta.selectLabel)));let ka=[];Ql.value===""?ka=Ue==null?void 0:Ue[0]:ka=(Ue==null?void 0:Ue.find(ta=>(ta==null?void 0:ta.selectLabel)==="("+Ql.value+")"))??(Ue==null?void 0:Ue.find(ta=>!(ta!=null&&ta.selectLabel)));let Na=[],Aa=[];if(((ha=ea==null?void 0:ea.contents)==null?void 0:ha.length)>0){let ta=[],Al=ea==null?void 0:ea.contents;if(Array.isArray(Al==null?void 0:Al[0])&&((B=Al==null?void 0:Al[0])!=null&&B.every(Za=>!(Za!=null&&Za.children)))&&(Al=Al==null?void 0:Al[0]),Al.some(Za=>Array.isArray(Za)&&(Za==null?void 0:Za.find(Ze=>Ze.children))))ta=(za=le.getGradeColumns(Al,H))==null?void 0:za[0],ta!=null&&ta.find(Za=>(Za==null?void 0:Za.label)==="操作")||ta.push({label:"操作",prop:"operate",type:"operate"});else{let Za=Al.some(Ze=>Array.isArray(Ze))?Al==null?void 0:Al[0]:Al;Za!=null&&Za.find(Ze=>(Ze==null?void 0:Ze.label)==="操作")||Za.push({label:"操作",prop:"operate",type:"operate"}),Za==null||Za.forEach((Ze,br)=>{var Qr,on,qr,fi,Ci,Di,Lr,$n,ai,Ti,En,li,os,ts,ss,cs,us,ds,ps,fs,hs;if((on=(Qr=de.value)==null?void 0:Qr.split("/"))==null||on.forEach(wr=>{var Ir,Un,vs;wr!==""&&((vs=(Un=(Ir=wr==null?void 0:wr.split(I+"updateLoading"))==null?void 0:Ir[0])==null?void 0:Un.split(I+"loading"))==null||vs[0])}),Ze!=null&&Ze.methodContent){let wr=(Ci=(fi=(qr=Ze==null?void 0:Ze.methodContent)==null?void 0:qr.replace("@","%%#"))==null?void 0:fi.split("%%#"))==null?void 0:Ci[1];if(wr=wr==null?void 0:wr.slice(0,(wr==null?void 0:wr.length)-1),wr=le.contentTransArrayToAllNoExtra(wr??"",","),(Di=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("@Button")))!=null&&Di.includes("Prop")&&((Lr=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("Type")))!=null&&Lr.includes("Manual"))){let Ir=(ai=($n=wr==null?void 0:wr.find(Un=>Un==null?void 0:Un.includes("@Button")))==null?void 0:$n.split(":"))==null?void 0:ai[1];Ir=((li=(En=(Ti=Ir==null?void 0:Ir.replaceAll("[",""))==null?void 0:Ti.replaceAll("]",""))==null?void 0:En.split(","))==null?void 0:li[1])??"算法执行",Na.push(Ir)}else if((os=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("@Button")))!=null&&os.includes("Row")&&((ts=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("Type")))!=null&&ts.includes("Manual"))){let Ir=(cs=(ss=wr==null?void 0:wr.find(Un=>Un==null?void 0:Un.includes("@Button")))==null?void 0:ss.split(":"))==null?void 0:cs[1];Ir=((ps=(ds=(us=Ir==null?void 0:Ir.replaceAll("[",""))==null?void 0:us.replaceAll("]",""))==null?void 0:ds.split(","))==null?void 0:ps[1])??"算法执行",Aa.push(Ir)}}(fs=na.value)==null||fs.find(wr=>(wr==null?void 0:wr.prop)===(Ze==null?void 0:Ze.prop));let cn=((hs=Ze==null?void 0:Ze.filter)==null?void 0:hs.includes("@EditRead=Read"))??!1;ta.push({label:(Ze==null?void 0:Ze.label)==="操作"?H?"操作":"":(Ze==null?void 0:Ze.label)??"",prop:(Ze==null?void 0:Ze.label)==="操作"?"operate":(Ze==null?void 0:Ze.prop)??"a"+br,width:Ze!=null&&Ze.width?parseInt(Ze.width):"",fixed:(Ze==null?void 0:Ze.fixed)??void 0,sortable:(Ze==null?void 0:Ze.sortable)??!1,filterable:(Ze==null?void 0:Ze.filterable)??!1,operable:(Ze==null?void 0:Ze.operable)??!1,showSummary:(Ze==null?void 0:Ze.showSummary)??!1,align:(Ze==null?void 0:Ze.align)??"left",showOverflowTooltip:(Ze==null?void 0:Ze.showOverflowTooltip)??!0,isNotDrag:(Ze==null?void 0:Ze.isNotDrag)??!1,isEditCol:(Ze==null?void 0:Ze.isEditCol)??!1,isOperate:(Ze==null?void 0:Ze.isOperate)??!1,id:(Ze==null?void 0:Ze.id)??br,type:(Ze==null?void 0:Ze.label)==="操作"?"operate":void 0,formType:(Ze==null?void 0:Ze.formType)??(Ze!=null&&Ze.groupSelect?"Select":""),disabled:Ze==null?void 0:Ze.disabled,options:(Ze==null?void 0:Ze.options)??[],value:(Ze==null?void 0:Ze.value)??"",isExistChild:(Ze==null?void 0:Ze.isExistChild)??!1,mainKey:(Ze==null?void 0:Ze.mainKey)??br===0,allSelectionContents:(Ze==null?void 0:Ze.allContents)??[],filterContent:Ze==null?void 0:Ze.filterContents,menus:Ze==null?void 0:Ze.menus,groups:Ze==null?void 0:Ze.groups,words:Ze==null?void 0:Ze.words,filter:Ze==null?void 0:Ze.filter,bindMenus:Ze==null?void 0:Ze.bindMenus,fatherPath:Ze==null?void 0:Ze.fatherPath,isMainPath:Ze==null?void 0:Ze.isMainPath,required:(Ze==null?void 0:Ze.required)??!1,relatedContents:Ze==null?void 0:Ze.relatedContents,functionName:Ze==null?void 0:Ze.functionName,functionRelatedWords:Ze==null?void 0:Ze.functionRelatedWords,calculatorFilter:Ze==null?void 0:Ze.calculatorFilter,relatedPages:Ze==null?void 0:Ze.relatedPages,multiple:(Ze==null?void 0:Ze.multiple)??!1,multipleLimit:Ze==null?void 0:Ze.multipleLimit,isReadonly:cn})})}ta=ta==null?void 0:ta.filter(Za=>{var Ze;return!((Ze=Za==null?void 0:Za.filter)!=null&&Ze.includes("@ShowHide=Hide"))}),O.value=(Ua=ke==null?void 0:ke[0])==null?void 0:Ua.contents;const sn=le.getNewColumnChild(ta);ge=le.getColumnChild(sn);const ei=Za=>Array.isArray(Za)?Za.map(Ze=>(Array.isArray(Ze==null?void 0:Ze.children)&&Ze.children.length>0?(Ze.sortable=!1,ei(Ze.children)):(Ze==null?void 0:Ze.prop)==="operate"||(Ze==null?void 0:Ze.label)==="操作"||(Ze==null?void 0:Ze.type)==="operate"||(Ze.sortable=!1),Ze)):Za;ei(sn),await Zo(sn),j0(Z.value,sn),W.value=sn,P.value=sn,r.value=(sl=W.value)==null?void 0:sl.map(Za=>Za==null?void 0:Za.label);let Pr=(Da=(Ga=le.getAllLeafNodes(W.value))==null?void 0:Ga.filter(Za=>(Za==null?void 0:Za.type)!=="operate"))==null?void 0:Da.map((Za,Ze)=>({prop:(Za==null?void 0:Za.prop)??"a"+Ze,column:Za.label}));lr.value=Pr;let Gr=[];Ql.value===""?Gr=K==null?void 0:K[0]:Gr=(K==null?void 0:K.find(Za=>(Za==null?void 0:Za.selectLabel)==="("+Ql.value+")"))??(K==null?void 0:K.find(Za=>!(Za!=null&&Za.selectLabel)));let jr=Array.isArray((dl=Gr==null?void 0:Gr.contents)==null?void 0:dl[0])&&((Wl=Gr==null?void 0:Gr.contents)!=null&&Wl[0].every(Za=>Array.isArray(Za)))?(qa=Gr==null?void 0:Gr.contents)==null?void 0:qa[0]:Gr==null?void 0:Gr.contents;ka!=null&&ka.contents&&((Tl=ka==null?void 0:ka.contents)==null?void 0:Tl.length)!==0&&(jr=(La=M.cloneDeep(jr))==null?void 0:La.map((Za,Ze)=>{if(!Array.isArray(Za)){let br={};for(let cn in Za)cn!=="id"&&cn!=="index"&&(br[cn]=Za[cn]);Za=Object.values(br)}return Za}));const ho=!!((Ll=W.value)!=null&&Ll.find(Za=>Za.prop==="index"));jr=Cc(jr,ka==null?void 0:ka.contents,ho);const Gn=[];jr==null||jr.forEach((Za,Ze)=>{var cn;let br={};if(Array.isArray(Za)){let Qr=[];Za==null||Za.filter(on=>!(on!=null&&on.id)).forEach((on,qr)=>{var fi,Ci,Di,Lr,$n,ai;if((fi=Pr==null?void 0:Pr[qr])!=null&&fi.prop&&!Array.isArray(on)){let Ti={};Ti[Pr[qr].column]=on,V!=null&&V.value&&((Ci=V==null?void 0:V.value)==null?void 0:Ci.length)>0&&((Di=V==null?void 0:V.value)!=null&&Di.find(En=>JSON.stringify(En==null?void 0:En[0])===JSON.stringify(Ti)))&&(Qr=(Lr=V==null?void 0:V.value)==null?void 0:Lr.find(En=>JSON.stringify(En==null?void 0:En[0])===JSON.stringify(Ti))),Qr&&Qr.length>0?br[Pr[qr].prop]=Qr!=null&&Qr.find(En=>{var li;return((li=Object.keys(En))==null?void 0:li[0])===Pr[qr].column})?($n=Qr==null?void 0:Qr.find(En=>{var li;return((li=Object.keys(En))==null?void 0:li[0])===Pr[qr].column}))==null?void 0:$n[Pr[qr].column]:on:br[Pr[qr].prop]=on}else Array.isArray(on)&&((ai=Pr[qr])!=null&&ai.prop?br[Pr[qr].prop]=on:br.children=Nt(on,Pr))})}else br=Za;if(Array.isArray(Za)&&Za.some(Qr=>Qr==null?void 0:Qr.id)){const Qr=(cn=Za==null?void 0:Za.find(on=>on.id))==null?void 0:cn.id;Gn.push(Object.assign(br,{id:to(Qr)}))}else br.id?Gn.push(br):Gn.push(Object.assign(br,{id:Ze.toString()}))});try{const Za=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),Ze=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null"),br=Za==null?void 0:Za.tableId,cn=Za==null?void 0:Za.compIndex;if(br&&Array.isArray(Ze)&&Ze.length>0&&String(br)===String(d==null?void 0:d.parentTableId)&&String(cn)===String(d==null?void 0:d.index)){const Qr=new Set(Gn.map(qr=>String(qr==null?void 0:qr.id))),on=Ze.filter(qr=>!Qr.has(String(qr)));if(on.length>0){const qr=Za==null?void 0:Za.pageKey,fi=qr!=null&&qr.startsWith("/")?qr.substring(1):qr;((v==null?void 0:v[qr])||(v==null?void 0:v[fi])||[]).filter(Lr=>{var $n,ai;return(($n=Lr==null?void 0:Lr.key)==null?void 0:$n.type)==="data"&&String((ai=Lr==null?void 0:Lr.key)==null?void 0:ai.tableId)===String(br)&&on.includes(Lr==null?void 0:Lr.id)}).forEach(Lr=>{var $n;Qr.has(String(Lr==null?void 0:Lr.id))||(Gn.push({id:Lr==null?void 0:Lr.id,...(($n=Lr==null?void 0:Lr.value)==null?void 0:$n.tableData)||{}}),Qr.add(String(Lr==null?void 0:Lr.id)))})}}}catch{}let Kn=null;try{const Za=`ocr_committed_temp_ids_v1:${String((d==null?void 0:d.parentTableId)??"")}:${String((d==null?void 0:d.index)??"")}`,Ze=JSON.parse(sessionStorage.getItem(Za)||"null");Array.isArray(Ze)&&Ze.length>0&&(Kn=new Set(Ze.map(br=>String(br))))}catch{}const qi=Array.from(((nl=Ta.value)==null?void 0:nl.values())||[]).filter(Za=>!(!(Za!=null&&Za._isOCRRow&&(Za==null?void 0:Za._ocrTableId)===(d==null?void 0:d.index))||Kn&&Kn.has(String(Za==null?void 0:Za.id)))),vo=(Ce.value||[]).map(Za=>String(Za==null?void 0:Za.id)),or=_i(Gn,vo);if(Ce.value=Xt(or,L,W.value),Fa.value=or,(vl=Fa.value)==null||vl.forEach(Za=>{var Ze;(Ze=Ta.value)==null||Ze.set(Za.id,Za)}),Kn&&Kn.size>0)try{const Za=new Set(Array.from(Kn.values()));Ce.value=(Ce.value||[]).filter(Ze=>!Za.has(String(Ze==null?void 0:Ze.id))),Fa.value=(Fa.value||[]).filter(Ze=>!Za.has(String(Ze==null?void 0:Ze.id))),Za.forEach(Ze=>{var br,cn;try{(cn=(br=Ta.value)==null?void 0:br.delete)==null||cn.call(br,Ze)}catch{}})}catch{}const Zr=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),mt=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null");if(Zr&&Array.isArray(mt)&&mt.length>0&&String(Zr==null?void 0:Zr.compIndex)===String(d==null?void 0:d.index)){const Za=new Set((Fa.value||[]).map(Ze=>String(Ze==null?void 0:Ze.id)));mt.filter(Ze=>!Za.has(String(Ze)))}if(qi.length>0){const Za=new Set((Ce.value||[]).map(br=>br==null?void 0:br.id)),Ze=qi.filter(br=>!Za.has(br.id));Ze.length>0&&(Ce.value=[...Ce.value||[],...Ze],Fa.value=[...Fa.value||[],...Ze],Ze.forEach(br=>{var cn;return(cn=Ta.value)==null?void 0:cn.set(br.id,br)}))}}else W.value=[],ze.value=[],Ce.value=[],Fa.value=[],Ta.value=new Map;if(Aa=[...new Set(Aa)],Aa=Aa==null?void 0:Aa.map(ta=>({label:ta,type:"methodButton"})),((zl=ie==null?void 0:ie.contents)==null?void 0:zl.length)>0?va.value=ie==null?void 0:ie.contents:va.value=[],va.value=[...va.value,...Aa],Na=[...new Set(Na)],Na=Na==null?void 0:Na.map(ta=>({label:ta,type:"methodButton"})),((xl=oe==null?void 0:oe.contents)==null?void 0:xl.length)>0)if((cr=(hr=(Cr=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="filterAllType"))==null?void 0:Cr.value)==null?void 0:hr.find(ta=>(ta==null?void 0:ta.value)==="onButtonContents"))!=null&&cr.content){let ta=(mr=(rr=(_l=f==null?void 0:f.find(Al=>(Al==null?void 0:Al.key)==="filterAllType"))==null?void 0:_l.value)==null?void 0:rr.find(Al=>(Al==null?void 0:Al.value)==="onButtonContents"))==null?void 0:mr.content;if(ta=(Il=ta==null?void 0:ta.split(":"))==null?void 0:Il[1],ta=(yr=ta.slice(1,(ta==null?void 0:ta.length)-1))==null?void 0:yr.split(","),Ye.value=(Dr=oe==null?void 0:oe.contents)==null?void 0:Dr.filter(Al=>ta==null?void 0:ta.find(sn=>sn===(Al==null?void 0:Al.label))),Ee.value=(gr=oe==null?void 0:oe.contents)==null?void 0:gr.filter(Al=>ta==null?void 0:ta.find(sn=>sn===(Al==null?void 0:Al.label))),(Mr=oe==null?void 0:oe.contents)!=null&&Mr.some(Al=>(Al==null?void 0:Al.label)==="OCR识别")&&!((tn=Ye.value)!=null&&tn.some(Al=>(Al==null?void 0:Al.label)==="OCR识别"))){const Al=(vr=oe==null?void 0:oe.contents)==null?void 0:vr.find(sn=>(sn==null?void 0:sn.label)==="OCR识别");Ye.value=[...Ye.value,Al],Ee.value=[...Ee.value,Al]}A.value=!!(ta!=null&&ta.find(Al=>Al==="搜索")),re.value=!!(ta!=null&&ta.find(Al=>Al==="块状显示"))}else Ye.value=oe==null?void 0:oe.contents,Ee.value=oe==null?void 0:oe.contents;else Ye.value=[],Ee.value=[];if(Ye.value=[...Ye.value,...Na],Ee.value=[...Ee.value,...Na],typeof de.value=="string"&&de.value==="设备管理/试验设备"&&(d==null?void 0:d.compName)==="设备列表"?((Or=Ye.value)!=null&&Or.some(ta=>(ta==null?void 0:ta.label)==="OCR识别")||(Ye.value=[...Ye.value||[],{label:"OCR识别"}]),(Fr=Ee.value)!=null&&Fr.some(ta=>(ta==null?void 0:ta.label)==="OCR识别")||(Ee.value=[...Ee.value||[],{label:"OCR识别"}])):(Ye.value=(Ye.value||[]).filter(ta=>(ta==null?void 0:ta.label)!=="OCR识别"),Ee.value=(Ee.value||[]).filter(ta=>(ta==null?void 0:ta.label)!=="OCR识别")),(es=Ye.value)!=null&&es.some(ta=>(ta==null?void 0:ta.label)==="切换视图")||(Ye.value=[...Ye.value||[],{label:"切换视图"}]),(as=Ee.value)!=null&&as.some(ta=>(ta==null?void 0:ta.label)==="切换视图")||(Ee.value=[...Ee.value||[],{label:"切换视图"}]),ge!=null&&ge.some(ta=>{var Al;return(ta==null?void 0:ta.calculatorFilter)&&((Al=ta==null?void 0:ta.calculatorFilter)==null?void 0:Al.includes("@Button"))})){let ta=(ls=ge==null?void 0:ge.filter(Pr=>{var Gr;return(Pr==null?void 0:Pr.calculatorFilter)&&((Gr=Pr==null?void 0:Pr.calculatorFilter)==null?void 0:Gr.includes("@Button"))}))==null?void 0:ls.map(Pr=>Pr==null?void 0:Pr.calculatorFilter),Al=[],sn=[],ei=[];ta==null||ta.forEach(Pr=>{var ho,Gn,Kn,qi,vo;let Gr=(ho=le.analyzeSplitToContent(Pr,","))==null?void 0:ho.map(or=>((or==null?void 0:or[(or==null?void 0:or.length)-1])===","&&(or=or==null?void 0:or.slice(0,(or==null?void 0:or.length)-1)),or)),jr=Gr==null?void 0:Gr.find(or=>or==null?void 0:or.includes("@Button"));if(Gr!=null&&Gr.find(or=>or==null?void 0:or.includes("Manual"))){jr=(Kn=(Gn=jr==null?void 0:jr.replace("=","$R"))==null?void 0:Gn.split("$R"))==null?void 0:Kn[1],jr=jr==null?void 0:jr.slice(1,(jr==null?void 0:jr.length)-1);let or=(qi=le.analyzeSplitToContent(jr,","))==null?void 0:qi.map(Zr=>((Zr==null?void 0:Zr[(Zr==null?void 0:Zr.length)-1])===","&&(Zr=Zr==null?void 0:Zr.slice(0,(Zr==null?void 0:Zr.length)-1)),Zr));or=or==null?void 0:or[0],or=or==null?void 0:or.slice(1,(or==null?void 0:or.length)-1),or=(vo=or==null?void 0:or.split(","))==null?void 0:vo.map(Zr=>({label:Zr,prop:Zr})),jr!=null&&jr.includes("Up")?Al=[...Al,...or??[]]:jr!=null&&jr.includes("Line")?sn=[...sn,...or??[]]:ei=[...ei,...or??[]]}}),Ye.value=[...Al,...Ye.value??[]],va.value=[...sn,...va.value??[]],ei.value=[...ei,...ei.value??[]]}sa.value=((rs=Ce==null?void 0:Ce.value)==null?void 0:rs.length)??0,Yt(Ce.value),Sr.value=Ce.value,er.value&&(W.value=(is=(ns=ze.value)==null?void 0:ns.filter(ta=>(ta==null?void 0:ta.label)!=="操作"))==null?void 0:is.map(ta=>{var Al;return{...ta,type:"edit",optionUrl:ta!=null&&ta.formMenuSelect&&((Al=ta==null?void 0:ta.formMenuSelect)==null?void 0:Al.length)>0?{groupSelect:ta==null?void 0:ta.groupSelect,menuSelect:ta==null?void 0:ta.formMenuSelect,selectRelateType:"",type:ta==null?void 0:ta.formType}:null}}),vt())};e.watch(()=>[d.itemData,Ql.value,Xl.value,$l.value,V==null?void 0:V.value],async()=>{var f,v,z,L,H,T;if((f=d==null?void 0:d.itemData)!=null&&f.find(ie=>(ie==null?void 0:ie.key)==="columnPath")&&!((v=ce.value)!=null&&v.find(ie=>{var oe,K;return(ie==null?void 0:ie.key)===((K=(oe=d==null?void 0:d.itemData)==null?void 0:oe.find(ke=>(ke==null?void 0:ke.key)==="columnPath"))==null?void 0:K.contents)}))){let ie=ce.value,oe={key:(L=(z=d==null?void 0:d.itemData)==null?void 0:z.find(K=>(K==null?void 0:K.key)==="columnPath"))==null?void 0:L.contents,value:(T=(H=d==null?void 0:d.itemData)==null?void 0:H.find(K=>(K==null?void 0:K.key)==="columnUsingPath"))==null?void 0:T.contents};ie!=null&&ie.find(K=>(K==null?void 0:K.key)===(oe==null?void 0:oe.key))?ie=ie==null?void 0:ie.map(K=>((K==null?void 0:K.key)===(oe==null?void 0:oe.key)&&(K.value=oe.value),K)):ie.push(oe),Ge.setTableViewContents(ie)}await Zt(d.itemData,d.allMapContents)},{deep:!0,immediate:!0}),e.watch(()=>d==null?void 0:d.operatingForm,f=>{f!=null&&f.form&&(ji(f==null?void 0:f.form),ma.value=f==null?void 0:f.dialogTitle,Ae.value=!0,Qe.value=!0)},{immediate:!0,deep:!0});const Pu=()=>{var f;(f=q.value)!=null&&f.includes("read")&&(er.value=!er.value)},ju=()=>{Ur.value=!Ur.value};e.watch(()=>{var f;return(f=d==null?void 0:d.config)==null?void 0:f.viewport},f=>{var v;q.value=f,(f==null?void 0:f.length)===0?er.value=!1:(f!=null&&f.includes("read")||(er.value=!0),f!=null&&f.includes("edit")||(er.value=!1)),w.value=((v=d==null?void 0:d.config)==null?void 0:v.showIndex)||er.value},{immediate:!0}),e.watch(()=>er.value,f=>{var v;f?(vt("viewChange"),Ge.setCacheUpdatingData(null)):(Ye.value=Ee.value,W.value=P.value,ee.value&&(Ge.setTableLoading(d==null?void 0:d.index),U("change",ee.value))),w.value=f||((v=d==null?void 0:d.config)==null?void 0:v.showIndex),Br.value=[]},{immediate:!0}),e.watch(()=>{var f;return(f=Ln.value)==null?void 0:f.length},f=>{f===0&&(ue.currentPage=1)}),e.watch(()=>d==null?void 0:d.compNames,f=>{Y.contents=[{label:"列表名",prop:"groupName",name:"列表名",type:"select",value:"",id:0,contents:f||[],width:1}]},{immediate:!0}),e.ref(!1);const Hu=(f,v)=>{var z;vt("createClick"),v===ue.pageSize&&(ue.currentPage=Math.ceil(((z=Ce.value)==null?void 0:z.length)/ue.pageSize))},Uu=async(f,v,z)=>{var H,T,ie,oe,K;const L=(v==null?void 0:v.property)??(v==null?void 0:v.prop);if(L&&po.includes(L)&&z!==void 0&&z!==null&&String(z).trim()!==""){const ke=String(z).trim();if(await ht(ke,f==null?void 0:f.id)){Ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择");const Je=(H=Ce.value)==null?void 0:H.findIndex(ea=>(ea==null?void 0:ea.id)===(f==null?void 0:f.id)),Ue=Je!==-1?(ie=(T=Ce.value)==null?void 0:T[Je])==null?void 0:ie[L]:void 0;L&&(f[L]=Ue??"");return}}if(er.value){const ke=f==null?void 0:f.id;ke!=null&&(p.value.has(ke)||p.value.set(ke,M.cloneDeep(f)),o.value.add(ke));const ge=(oe=Ce.value)==null?void 0:oe.findIndex(Je=>(Je==null?void 0:Je.id)===(f==null?void 0:f.id));ge!==-1&&L&&(Ce.value[ge]={...Ce.value[ge],[L]:z}),fo(z,f,v);return}fo(z,f,v),Yl.value=M.cloneDeep(f),fa.value=f==null?void 0:f.id,sa.value=(K=Ce.value)==null?void 0:K.length,ma.value=f!=null&&f._isTemp?"新增":"编辑",Ui(!1)},qu=async()=>{var f,v;try{const z=[];if(d!=null&&d.related&&Array.isArray(d.related)&&(console.log("props.related",d.related),d.related.forEach(L=>{if(typeof L=="string"&&L.includes("content_")){const H=L.split("_")[1];H&&(z.push(`content_${H}`),z.push(`struct_${H}`))}})),z.length===0&&(d!=null&&d.itemData)){const L=(v=(f=d.itemData)==null?void 0:f.find(H=>(H==null?void 0:H.key)==="contentTableId"))==null?void 0:v.contents;L&&(z.push(`content_${L}`),z.push(`struct_${L}`))}return z}catch(z){return console.error("获取 tableNames 失败:",z),[]}},Wu=async(f,v,z)=>{var T,ie;if(!z||typeof z!="string"||z.trim()===""){const oe=(v==null?void 0:v.property)??(v==null?void 0:v.prop),K=`${f==null?void 0:f.id}:${oe}`;m.value.delete(K),y.value.set(K,!1);return}const L=(v==null?void 0:v.property)??(v==null?void 0:v.prop),H=`${f==null?void 0:f.id}:${L}`;y.value.set(H,!0);try{const oe=await qu();if(oe.length===0){console.warn("未找到同名表,跳过全局搜索"),m.value.delete(H),y.value.set(H,!1);return}const K=parseInt((T=Nl.value)==null?void 0:T.plat_id);if(!K){console.warn("platId 无效,跳过全局搜索"),m.value.delete(H),y.value.set(H,!1);return}const ke=await M.getAllTables({platId:K,tableNames:oe??[]}),ge=((ie=ke==null?void 0:ke.data)==null?void 0:ie.result)||[],Je=[],Ue=[];for(let ea=0;ea<ge.length;ea+=2)ea+1<ge.length&&Ue.push([ge[ea],ge[ea+1]]);Ue.forEach(([ea,ka])=>{var tl;if(!Array.isArray(ea)||ea.length===0||!Array.isArray(ka)||ka.length===0)return;const Na=ka[0];let Aa=((tl=Na==null?void 0:Na.结构)==null?void 0:tl.contents)??[];if(!Array.isArray(Aa)||Aa.length===0)return;let la=M.cloneDeep(Aa);if(Array.isArray(la==null?void 0:la[0])&&(la=le.getColumnChild(la[0])),!Array.isArray(la)||la.length===0||!la.some(be=>(be==null?void 0:be.prop)===L))return;[...ea].sort((be,Va)=>{const ba=Number((be==null?void 0:be.update_time)??0);return Number((Va==null?void 0:Va.update_time)??0)-ba}).slice(0,20).forEach(be=>{const Va=be[L];if(Va!=null){const ba=String(Va);ba.toLowerCase().includes(z.toLowerCase())&&Je.findIndex(Ia=>{var Ne;return be.id&&((Ne=Ia.rowData)==null?void 0:Ne.id)===be.id?!0:Ia.label===ba})===-1&&Je.push({label:ba,rowData:M.cloneDeep(be),sourceTable:(Na==null?void 0:Na.source_table)||""})}})}),m.value.set(H,Je)}catch(oe){console.error("全局搜索建议失败:",oe),m.value.delete(H)}finally{y.value.set(H,!1)}},Gu=(f,v,z)=>{if(!er.value)return;const L=(v==null?void 0:v.property)??(v==null?void 0:v.prop),H=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"";if(H&&H.toUpperCase()!=="INPUT"&&H!=="")return;const T=`${f==null?void 0:f.id}:${L}`;if(g.has(T)&&clearTimeout(g.get(T)),!z||z.trim()===""){m.value.delete(T),y.value.set(T,!1);return}const ie=setTimeout(()=>{Wu(f,{prop:L,property:L},z),g.delete(T)},300);g.set(T,ie)};function Ku(f,v){const z=`${f==null?void 0:f.id}:${(v==null?void 0:v.property)??(v==null?void 0:v.prop)}`;return m.value.get(z)||[]}const Yu=(f,v,z)=>{var ke;if(!z||!z.rowData)return;const L=z.rowData,H=f==null?void 0:f.id,T=(v==null?void 0:v.property)??(v==null?void 0:v.prop);(le.getAllLeafNodes(W.value)||[]).filter(ge=>(ge==null?void 0:ge.type)!=="operate"&&(ge==null?void 0:ge.label)!=="操作"&&(ge==null?void 0:ge.prop)!=="operate").forEach(ge=>{const Je=ge==null?void 0:ge.prop;Je&&L[Je]!==void 0&&(f[Je]=L[Je])}),(ke=Ce.value)==null||ke.findIndex(ge=>(ge==null?void 0:ge.id)===H),H!=null&&(p.value.has(H)||p.value.set(H,M.cloneDeep(f)),o.value.add(H));const K=`${H}:${T}`;m.value.delete(K),y.value.set(K,!1),fo(f[T],f,v)},pn=f=>{var K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol;const{row:v,column:z,item:L,slotData:H}=f;let T=v!=null&&v[z==null?void 0:z.prop]||(v==null?void 0:v[z==null?void 0:z.prop])===0?((ke=(K=v==null?void 0:v[z==null?void 0:z.prop])==null?void 0:K[0])==null?void 0:ke.contents)??((v==null?void 0:v[z==null?void 0:z.prop])===0?"0":v==null?void 0:v[z==null?void 0:z.prop]):((Je=(ge=v==null?void 0:v[L==null?void 0:L.prop])==null?void 0:ge[0])==null?void 0:Je.contents)??(v==null?void 0:v[L==null?void 0:L.prop])??((ea=(Ue=H==null?void 0:H[L==null?void 0:L.prop])==null?void 0:Ue[0])==null?void 0:ea.contents)??(H==null?void 0:H[L==null?void 0:L.prop])??((Aa=(Na=v==null?void 0:v[(ka=L==null?void 0:L.child)==null?void 0:ka.prop])==null?void 0:Na[0])==null?void 0:Aa.contents)??(v==null?void 0:v[(la=L==null?void 0:L.child)==null?void 0:la.prop]),oe=Array.isArray(T)&&!(T!=null&&T.every(xa=>typeof xa=="string"||typeof xa=="number"))?"查看":T;if(oe=Array.isArray(oe)?oe.join(","):oe,(z==null?void 0:z.formType)==="Date")if(!oe||oe===""||oe===null||oe===void 0)oe="";else{const xa=M.dayjs(oe,["YYYY-MM-DD","YYYY/MM/DD","YYYY年MM月DD日","YYYYMMDD"],!0);oe=xa.isValid()?xa.format("YYYYMMDD"):oe??""}return Array.isArray(z==null?void 0:z.relatedPages)&&((ol=z==null?void 0:z.relatedPages)==null?void 0:ol.length)>0&&(oe="详情页"),oe},Ju=f=>{var ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol;const{row:v,column:z,item:L,slotData:H}=f;let T=v!=null&&v[z==null?void 0:z.prop]?((ge=(ke=v==null?void 0:v[z==null?void 0:z.prop])==null?void 0:ke[0])==null?void 0:ge.contents)??(v==null?void 0:v[z==null?void 0:z.prop]):((Ue=(Je=v==null?void 0:v[L==null?void 0:L.prop])==null?void 0:Je[0])==null?void 0:Ue.contents)??(v==null?void 0:v[L==null?void 0:L.prop])??((ka=(ea=H==null?void 0:H[L==null?void 0:L.prop])==null?void 0:ea[0])==null?void 0:ka.contents)??(H==null?void 0:H[L==null?void 0:L.prop])??((la=(Aa=v==null?void 0:v[(Na=L==null?void 0:L.child)==null?void 0:Na.prop])==null?void 0:Aa[0])==null?void 0:la.contents)??(v==null?void 0:v[(ol=L==null?void 0:L.child)==null?void 0:ol.prop]);const oe=Array.isArray(T)&&!(T!=null&&T.every(xa=>typeof xa=="string"||typeof xa=="number")),K=Array.isArray(T)&&(T==null?void 0:T.find(xa=>xa==null?void 0:xa.url));return oe&&K},Xu=f=>{var z,L,H,T;return f!=null&&f.column?(de.value,d==null||d.compName,((L=(z=f==null?void 0:f.column)==null?void 0:z.filter)==null?void 0:L.includes("@TextRGBA"))||((T=(H=f==null?void 0:f.column)==null?void 0:H.filter)==null?void 0:T.includes("@TextBackRGBA"))):!1},Zu=(f,v)=>f.find(z=>Object.values(z).some(L=>L===v));return e.watch(()=>Xe.value,async f=>{if(f){Le.setContentLoading(!0),await e.nextTick();const v=Zu(Ce.value,f==null?void 0:f.data);if(!v)return Le.setContentLoading(!1);await uo(f==null?void 0:f.data,null,v,{data:f==null?void 0:f.data}),Le.setContentLoading(!1)}},{deep:!0,immediate:!0}),e.watch(()=>d==null?void 0:d.cacheNewData,f=>{var v;f&&(Array.isArray(f)?f.forEach(z=>{var L,H,T,ie,oe;if(换,String(z==null?void 0:z.compId)===String(d==null?void 0:d.index)&&(z!=null&&z.resId)&&((L=z==null?void 0:z.data)!=null&&L.id)){const K=(H=z==null?void 0:z.data)==null?void 0:H.id,ke=z==null?void 0:z.resId;if(Ce.value=(T=Ce.value)==null?void 0:T.map(ge=>{if((ge==null?void 0:ge.id)===K){const Je={...ge,id:ke};return delete Je._isOCRRow,delete Je._ocrTableId,Je}return ge}),(oe=(ie=Ta.value)==null?void 0:ie.has)!=null&&oe.call(ie,K)){const Je={...Ta.value.get(K)||{},id:ke};delete Je._isOCRRow,delete Je._ocrTableId,Ta.value.delete(K),Ta.value.set(ke,Je)}Zl(d==null?void 0:d.index,K,ke)}}):String(f==null?void 0:f.compId)===String(d==null?void 0:d.index)&&(Ce.value=(v=Ce.value)==null?void 0:v.map(z=>{var L;if((z==null?void 0:z.id)===((L=f==null?void 0:f.data)==null?void 0:L.id)){const H={...z,id:f==null?void 0:f.resId};return delete H._isOCRRow,delete H._ocrTableId,H}return z})))},{immediate:!0,deep:!0}),(f,v)=>{var la,ol,xa,tl;const z=e.resolveComponent("svg-icon"),L=e.resolveComponent("el-popover"),H=e.resolveComponent("el-switch"),T=e.resolveComponent("el-checkbox"),ie=e.resolveComponent("el-radio"),oe=e.resolveComponent("el-radio-group"),K=e.resolveComponent("el-checkbox-group"),ke=e.resolveComponent("el-button"),ge=e.resolveComponent("el-icon"),Je=e.resolveComponent("el-progress"),Ue=e.resolveComponent("el-alert"),ea=e.resolveComponent("el-table-column"),ka=e.resolveComponent("el-table"),Na=e.resolveComponent("el-upload"),Aa=e.resolveComponent("el-text");return e.openBlock(),e.createElementBlock("div",A3,[Sn.value?(e.openBlock(),e.createBlock(pl.ssTable,{id:"excel-table",pageObj:ue,showIndex:w.value,isTree:(la=a.compItem)==null?void 0:la.isTree,summaryInfo:me,columns:W.value,defaultSort:ve,isCardViewport:Ur.value,checkedColumns:r.value,key:Jl.value+JSON.stringify(W.value),tableData:Ln.value,isEditViewport:er.value,isShowPagination:Pe.value,isShowEdit:!1,isShowDelete:!1,allowSelect:D.value,onDbClickRow:it,extraButton:Ye.value,rowButton:va.value,cacheExtraButtons:Ee.value,isClearSelection:((ol=Br.value)==null?void 0:ol.length)===0,onDoCurrentChange:jo,onDoSizeChange:Ho,onSortChange:Uo,onContentClick:uo,onRowClick:tt,onSelectChange:xi,onCellChange:Uu,onCellInput:Gu,onSelectSuggest:Yu,onChange:fo,onPreview:oo,onSubmitEditingTable:Pn,onHandleColEditChange:Wo,onHandleColTypeChange:Go,onClickButton:pt,onAddNewRow:Ko,bottomButton:O.value,allowRowAddOrDelete:nt.value},e.createSlots({headerButton:e.withCtx(be=>{var Va,ba,Ya,Ia;return[a.showHeader?(e.openBlock(),e.createBlock(a0,{key:0,id:"tableHeaderButton",pageLayout:a.pageLayout,lockingPage:e.unref(ia)===e.unref(de),filterValues:co.value,selectNums:(Va=Br.value)==null?void 0:Va.length,dataNums:(ba=Ce.value)==null?void 0:ba.length,compName:a.compName,isDevMode:a.isDevMode,buttons:be.buttons,menuFilter:(Ia=(Ya=a.compItem)==null?void 0:Ya.component)==null?void 0:Ia.menuFilter,onButtonClick:v[1]||(v[1]=(Ne,Q,je)=>pt(Ne,Q,{extra:je})),columns:W.value,onFilter:Pi,onGetImportData:un,level:a.level,filterShow:A.value},null,8,["pageLayout","lockingPage","filterValues","selectNums","dataNums","compName","isDevMode","buttons","menuFilter","columns","level","filterShow"])):e.createCommentVNode("",!0)]}),viewport:e.withCtx(()=>{var be,Va,ba,Ya;return[((be=Ce.value)==null?void 0:be.length)>0&&a.allowOperate&&re.value?(e.openBlock(),e.createElementBlock("div",I3,[(Va=q.value)!=null&&Va.includes("read")&&((ba=q.value)!=null&&ba.includes("edit"))&&((Ya=va.value)!=null&&Ya.some(Ia=>(Ia==null?void 0:Ia.label)==="编辑"))&&!Ur.value&&e.unref(ia)!==e.unref(de)?(e.openBlock(),e.createElementBlock("span",{key:0,title:"编辑表格",onClick:Pu},[e.createVNode(z,{name:"editTable",class:"view-icon"})])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]}),rowCreate:e.withCtx(({row:be,index:Va})=>[e.createElementVNode("span",{title:"新增",class:"row-create-wrap",onClick:ba=>Hu(be,Va)},[e.createVNode(z,{name:"rowCreate",style:{width:"10px",height:"10px"}})],8,O3)]),operateCol:e.withCtx(()=>[e.createVNode(L,{title:"选择显示列信息",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:Ou,onBeforeEnter:Lu},{reference:e.withCtx(()=>[e.createElementVNode("span",L3,[e.createVNode(z,{name:"operate",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",R3,[v[20]||(v[20]=e.createElementVNode("div",{class:"group-title"},"表格操作",-1)),e.createVNode(H,{"model-value":R.value,"active-text":"排序","inactive-text":"",style:{"margin-right":"8px"},onChange:v[2]||(v[2]=be=>Qo(be))},null,8,["model-value"]),v[21]||(v[21]=e.createElementVNode("div",{class:"group-title"},"表格列操作",-1)),e.createVNode(K,{modelValue:r.value,"onUpdate:modelValue":v[3]||(v[3]=be=>r.value=be),style:{height:"100%"},min:2,ref_key:"checkboxGroupRef",ref:i},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Qn.value,be=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:be.label},[e.createVNode(T,{value:be.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",{title:be.label,style:{display:"inline-block",width:"250px",overflow:"hidden","text-overflow":"ellipsis","white-space":"nowrap"}},e.toDisplayString(be.label),9,$3)]),_:2},1032,["value"]),e.createVNode(L,{"popper-class":"col-operate-popover",title:"列操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(z,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Va;return[e.createElementVNode("div",V3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Va=Object.keys(be))==null?void 0:Va.filter(ba=>{var Ya;return(Ya=_.value)==null?void 0:Ya.find(Ia=>(Ia==null?void 0:Ia.value)===ba)}),ba=>{var Ya,Ia;return e.openBlock(),e.createElementBlock("div",{key:ba},[E[ba]=="radio"?(e.openBlock(),e.createElementBlock("div",F3,[v[19]||(v[19]=e.createElementVNode("div",null,"固定:",-1)),e.createVNode(oe,{"model-value":be==null?void 0:be[ba],onChange:Ne=>Fi(Ne,ba,be)},{default:e.withCtx(()=>{var Ne,Q;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Q=(Ne=_.value)==null?void 0:Ne.find(je=>(je==null?void 0:je.value)===ba))==null?void 0:Q.options,je=>(e.openBlock(),e.createBlock(ie,{key:je==null?void 0:je.value,label:je==null?void 0:je.value,value:je==null?void 0:je.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(je==null?void 0:je.label),1)]),_:2},1032,["label","value"]))),128))]}),_:2},1032,["model-value","onChange"])])):e.createCommentVNode("",!0),E[ba]=="switch"?(e.openBlock(),e.createBlock(H,{key:1,"model-value":be==null?void 0:be[ba],"active-text":(Ia=(Ya=_.value)==null?void 0:Ya.find(Ne=>(Ne==null?void 0:Ne.value)===ba))==null?void 0:Ia.label,onChange:Ne=>Fi(Ne,ba,be)},null,8,["model-value","active-text","onChange"])):e.createCommentVNode("",!0)])}),128))])]}),_:2},1024),e.createElementVNode("span",P3,[e.createVNode(z,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:1},8,["modelValue"])])):e.createCommentVNode("",!0)]),_:1})]),content:e.withCtx(be=>{var Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll;return[((Va=be==null?void 0:be.column)==null?void 0:Va.label)==="证书附件"||((ba=be==null?void 0:be.column)==null?void 0:ba.prop)==="证书附件"?(e.openBlock(),e.createElementBlock("div",j3,[e.createVNode(z,{name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(nl=>Du(be),["stop"]),title:"查看OCR图片"},null,8,["onClick"])])):Ju(be)?(e.openBlock(),e.createBlock(L,{key:1,"popper-class":"file-popover",placement:"right",trigger:"hover",effect:"light",width:"auto"},{reference:e.withCtx(()=>[e.createElementVNode("span",H3,e.toDisplayString(pn(be)),1)]),default:e.withCtx(()=>{var nl,vl;return[e.createElementVNode("div",U3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((vl=be==null?void 0:be.row)==null?void 0:vl[(nl=be==null?void 0:be.column)==null?void 0:nl.prop],zl=>(e.openBlock(),e.createElementBlock("div",q3,[e.createElementVNode("div",{class:"prop-url",title:ci(zl),onClick:xl=>rt(zl)},e.toDisplayString(ci(zl)),9,W3),e.createElementVNode("div",{class:"prop-download",onClick:xl=>so(zl)}," 下载 ",8,G3)]))),256))])]}),_:2},1024)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[Xu(be)?(e.openBlock(),e.createBlock(sd,{key:0,value:pn(be),columnContent:be==null?void 0:be.column},null,8,["value","columnContent"])):(e.openBlock(),e.createElementBlock("div",{key:1,class:"table-cell-content",style:e.normalizeStyle({color:!Array.isArray(pn(be))&&((Ia=(Ya=pn(be))==null?void 0:Ya.toString())!=null&&Ia.includes(".txt")||(Q=(Ne=pn(be))==null?void 0:Ne.toString())!=null&&Q.includes(".cpt")||(ha=(je=pn(be))==null?void 0:je.toString())!=null&&ha.includes(".cyd"))?"var(--vertical-menuitem-active-bg)":"",textDecoration:!Array.isArray(pn(be))&&((za=(B=pn(be))==null?void 0:B.toString())!=null&&za.includes(".txt")||(sl=(Ua=pn(be))==null?void 0:Ua.toString())!=null&&sl.includes(".cpt")||(Da=(Ga=pn(be))==null?void 0:Ga.toString())!=null&&Da.includes(".cyd"))?"underline":"",cursor:!Array.isArray(pn(be))&&((Wl=(dl=pn(be))==null?void 0:dl.toString())!=null&&Wl.includes(".txt")||(Tl=(qa=pn(be))==null?void 0:qa.toString())!=null&&Tl.includes(".cpt")||(Ll=(La=pn(be))==null?void 0:La.toString())!=null&&Ll.includes(".cyd"))?"pointer":"",marginLeft:(be==null?void 0:be.colIndex)===0?`${((be==null?void 0:be.level)??0)*20}px`:0}),onClick:nl=>{var vl;return An(pn(be),((vl=be==null?void 0:be.column)==null?void 0:vl.relatedPages)??[])}},e.toDisplayString(pn(be)===0?"0":pn(be)),13,K3))],64))]}),_:2},[((xa=va.value)==null?void 0:xa.length)>0?{name:"actions",fn:e.withCtx(({item:be,fIndex:Va})=>[e.createVNode(L,{title:"",placement:"left-start","popper-class":"menu-operate-popover"},{reference:e.withCtx(()=>[e.createVNode(z,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"},onClick:v[0]||(v[0]=e.withModifiers(()=>{},["stop"]))})]),default:e.withCtx(()=>[e.createElementVNode("div",z3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(di(va.value,be),(ba,Ya)=>(e.openBlock(),e.createElementBlock("div",{class:"menu-config-item",key:Ya,onClick:e.withModifiers(Ia=>pt(ba==null?void 0:ba.label,be,{extra:ba}),["stop"])},[e.createElementVNode("div",{style:e.normalizeStyle({color:ba==null?void 0:ba.textColor}),class:"extra-button-label"},e.toDisplayString(ba==null?void 0:ba.label),5)],8,M3))),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),er.value?(e.openBlock(),e.createElementBlock("div",Y3,[e.createVNode(ke,{id:"themeBorderButton",onClick:Jo},{default:e.withCtx(()=>v[22]||(v[22]=[e.createTextVNode("取消")])),_:1,__:[22]}),e.createVNode(ke,{class:"ok-button",id:"themeButton",onClick:Vi},{default:e.withCtx(()=>v[23]||(v[23]=[e.createTextVNode("保存")])),_:1,__:[23]})])):e.createCommentVNode("",!0),e.createVNode($r.ssDialog,{title:ma.value,visible:Qe.value,width:Vr.value,onBeforeDestroy:et,style:{height:"74%"}},{default:e.withCtx(()=>[e.createElementVNode("div",J3,[e.createVNode(pl.ssForm,{ref_key:"formRef",ref:Oe,rowContents:ye.value,showOperator:!1,onChange:Ru,isEnableWrap:!1,layer:!0,onFixChangeValue:Hn,onClickTrigger:at,isEdit:ja.value,onBlurChange:Xo,onCreate:io,onTagChange:zr},null,8,["rowContents","isEdit"])])]),footer:e.withCtx(()=>[Ae.value?(e.openBlock(),e.createElementBlock("div",X3,[e.createVNode(ke,{onClick:v[4]||(v[4]=be=>Qe.value=!1),id:"themeBorderButton"},{default:e.withCtx(()=>v[24]||(v[24]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[24]}),e.createVNode(ke,{class:"ok-button",onClick:v[5]||(v[5]=be=>Ui(!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($r.ssDialog,{title:ma.value,visible:ne.value,width:We.value,onBeforeDestroy:v[7]||(v[7]=be=>ne.value=!1)},{default:e.withCtx(()=>[e.createVNode(v0)]),footer:e.withCtx(()=>[e.createElementVNode("div",Z3,[e.createVNode(ke,{onClick:v[6]||(v[6]=be=>ne.value=!1),class:"cancel-button",id:"themeBorderButton"},{default:e.withCtx(()=>v[26]||(v[26]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[26]}),e.createVNode(ke,{class:"ok-button",onClick:st,id:"themeButton"},{default:e.withCtx(()=>v[27]||(v[27]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[27]})])]),_:1},8,["title","visible","width"]),Ke.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:2,fileDataList:Me.value,onDestroy:ot},null,8,["fileDataList"])):e.createCommentVNode("",!0),te.value?(e.openBlock(),e.createBlock($r.ssDialog,{key:3,visible:te.value,onBeforeDestroy:Mu,style:{height:"80vh",width:"80vw"},"body-class":"three-dialog-body","footer-class":"three-dialog-footer"},{default:e.withCtx(()=>[e.createVNode(Do.ThreeViewerHost,{files:Be.value,threeData:se.value},null,8,["files","threeData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0),e.createVNode($r.ssDialog,{title:"OCR扫描录入",visible:Sl.value,"close-on-click-modal":!1,onBeforeDestroy:sr,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",Q3,[e.createElementVNode("div",eh,[e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:Ha.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:Ha.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:Ha.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)]),Ha.value===1?(e.openBlock(),e.createElementBlock("div",ah,[e.createVNode(ke,{onClick:C,class:"ocr-action-btn",disabled:dr.value,size:"default"},{default:e.withCtx(()=>v[33]||(v[33]=[e.createTextVNode("扫描文件 ")])),_:1,__:[33]},8,["disabled"]),e.createVNode(ke,{onClick:pi,class:"ocr-action-btn",disabled:dr.value,size:"default"},{default:e.withCtx(()=>v[34]||(v[34]=[e.createTextVNode("上传文件 ")])),_:1,__:[34]},8,["disabled"])])):e.createCommentVNode("",!0),Ha.value===1?(e.openBlock(),e.createElementBlock("div",lh,[e.createElementVNode("div",rh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ga.value,(be,Va)=>{var ba;return e.openBlock(),e.createElementBlock("div",{key:Va,class:"ocr-file-item"},[e.createElementVNode("div",nh,[be.raw&&((ba=be.raw.type)!=null&&ba.startsWith("image/"))?(e.openBlock(),e.createElementBlock("img",{key:0,src:dn(be),alt:"预览",class:"thumbnail-image"},null,8,ih)):(e.openBlock(),e.createElementBlock("div",oh,[e.createVNode(ge,{size:40},{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.document_default))]),_:1})])),e.createElementVNode("div",{class:e.normalizeClass(["file-progress-ring",{uploading:ar(be)==="uploading",processing:ar(be)==="processing",completed:ar(be)==="completed"||ar(be)==="uploaded",failed:ar(be)==="failed"}])},[(e.openBlock(),e.createElementBlock("svg",th,[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:ar(be)==="completed"||ar(be)==="uploaded",uploading:ar(be)==="uploading",processing:ar(be)==="processing",failed:ar(be)==="failed"}]),cx:"18",cy:"18",r:"16",fill:"none",stroke:ar(be)==="failed"?"#f56c6c":ar(be)==="completed"||ar(be)==="uploaded"?"#67c23a":"#409eff","stroke-width":ar(be)==="completed"||ar(be)==="uploaded"||ar(be)==="failed"?3:2,"stroke-dasharray":Rn(be),"stroke-dashoffset":"0","stroke-linecap":"round",transform:"rotate(-90 18 18)"},null,10,sh)])),ar(be)==="completed"||ar(be)==="uploaded"?(e.openBlock(),e.createElementBlock("div",ch,[e.createVNode(ge,{class:"check-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.check_default))]),_:1})])):e.createCommentVNode("",!0),ar(be)==="failed"?(e.openBlock(),e.createElementBlock("div",uh,[e.createVNode(ge,{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:Ya=>Bu(Va)},[e.createVNode(ge,null,{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.close_default))]),_:1})],8,dh)]),e.createElementVNode("div",ph,e.toDisplayString(be.name||"文件名123"),1)])}),128))]),ga.value.length>0?(e.openBlock(),e.createElementBlock("div",fh,[e.createVNode(ke,{onClick:cl,class:"ocr-start-recognize-btn",disabled:dr.value||ga.value.length===0,size:"default"},{default:e.withCtx(()=>v[36]||(v[36]=[e.createTextVNode("开始识别 ")])),_:1,__:[36]},8,["disabled"])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),Ha.value===1?(e.openBlock(),e.createElementBlock("div",hh,[e.createVNode(Je,{percentage:Te.value,"stroke-width":8},null,8,["percentage"])])):e.createCommentVNode("",!0),Ha.value===2?(e.openBlock(),e.createElementBlock("div",vh,[e.createElementVNode("div",mh,[e.createVNode(Ue,{title:"请核对识别结果。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",yh,[e.createVNode(ka,{data:Ka.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(ea,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(pe.value,be=>(e.openBlock(),e.createBlock(ea,{key:be.prop,prop:be.prop,"min-width":be.minWidth||230,"class-name":be.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",gh,[e.createElementVNode("span",null,e.toDisplayString(be.label),1)])]),default:e.withCtx(({row:Va,$index:ba})=>{var Ya,Ia,Ne;return[be.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:fr(Va[be.prop]),fontWeight:500})},e.toDisplayString(ir(Va[be.prop])),5)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[Xa.value!==ba?(e.openBlock(),e.createElementBlock("span",bh,e.toDisplayString(Va[be.prop]),1)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(Pa(be.prop)),{key:1,modelValue:Va[be.prop],"onUpdate:modelValue":Q=>Va[be.prop]=Q,size:"small",placeholder:"请输入"+be.label,content:((Ya=_a(be.prop))==null?void 0:Ya.contents)??((Ia=_a(be.prop))==null?void 0:Ia.options)??[],optionUrl:(Ne=_a(be.prop))==null?void 0:Ne.optionUrl,onChange:Q=>Vl(ba,be.prop,Q),onFocus:Q=>ua.value=be.prop,onBlur:v[8]||(v[8]=Q=>ua.value="")},null,40,["modelValue","onUpdate:modelValue","placeholder","content","optionUrl","onChange","onFocus"]))],64))]}),_:2},1032,["prop","min-width","class-name"]))),128)),e.createVNode(ea,{label:"编辑",width:"80",fixed:"right"},{default:e.withCtx(({$index:be})=>[Xa.value===be?(e.openBlock(),e.createBlock(ge,{key:0,class:"ocr-edit-icon editing",style:{"margin-left":"12px"},onClick:e.withModifiers(Va=>ql(be),["stop"])},{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.check_default))]),_:2},1032,["onClick"])):(e.openBlock(),e.createBlock(z,{key:1,name:"edit_101",class:"ocr-edit-icon",onClick:e.withModifiers(Va=>ql(be),["stop"])},null,8,["onClick"]))]),_:1})]),_:1},8,["data"])])])):e.createCommentVNode("",!0),Ha.value===3?(e.openBlock(),e.createElementBlock("div",kh,[e.createVNode(ge,{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(Na,{ref:"ocrUploadRef","file-list":ga.value,"onUpdate:fileList":v[9]||(v[9]=be=>ga.value=be),multiple:"",action:"","auto-upload":!1,limit:20,accept:"image/*,application/pdf","on-change":rl,"show-file-list":!1,class:"ocr-upload-input",style:{display:"none"}},null,8,["file-list"])]),footer:e.withCtx(()=>[Ha.value!==3?(e.openBlock(),e.createElementBlock("div",xh,[e.createVNode(ke,{onClick:Eu,class:"ocr-start-recognize-btn",disabled:Ha.value===1||dr.value},{default:e.withCtx(()=>v[39]||(v[39]=[e.createTextVNode(" 上一步 ")])),_:1,__:[39]},8,["disabled"]),e.createVNode(ke,{onClick:Cu,class:"ocr-start-recognize-btn",disabled:dr.value},{default:e.withCtx(()=>v[40]||(v[40]=[e.createTextVNode(" 下一步 ")])),_:1,__:[40]},8,["disabled"])])):e.createCommentVNode("",!0)]),_:1},8,["visible"]),e.createVNode(M0,{visible:k.value,onConfirm:F,onCancel:v[10]||(v[10]=be=>k.value=!1)},null,8,["visible"]),e.createVNode(Hd,{visible:fl.value,"onUpdate:visible":v[11]||(v[11]=be=>fl.value=be),versions:Bl.value},null,8,["visible","versions"]),e.createVNode(Bd,{visible:wa.value,"onUpdate:visible":v[12]||(v[12]=be=>wa.value=be),images:Ba.value,"default-image-name":hl.value,"field-meta":Xa.value!==null?((tl=Ka.value[Xa.value])==null?void 0:tl.__ocrFieldMeta)||{}:{},"focused-field-name":ua.value,onClose:v[13]||(v[13]=be=>wa.value=!1),class:"ocr-img-preview-dialog"},null,8,["visible","images","default-image-name","field-meta","focused-field-name"]),e.createVNode(lp,{visible:Fe.value,"onUpdate:visible":v[14]||(v[14]=be=>Fe.value=be),candidates:bl.value,"name-prop":Oa.value,"mfr-prop":aa.value,columns:W.value,onSubmit:en,onPreviewFile:Tu},null,8,["visible","candidates","name-prop","mfr-prop","columns"]),e.createVNode(cp,{visible:oa.value,"onUpdate:visible":v[15]||(v[15]=be=>oa.value=be),ocrPreviewData:Ka.value,"onUpdate:ocrPreviewData":v[16]||(v[16]=be=>Ka.value=be),ocrSelectedFields:ca.value,"onUpdate:ocrSelectedFields":v[17]||(v[17]=be=>ca.value=be),ocrPreviewColumns:pe.value,onConfirm:El,onFieldChange:v[18]||(v[18]=({rowIndex:be,prop:Va,value:ba})=>Vl(be,Va,ba))},null,8,["visible","ocrPreviewData","ocrSelectedFields","ocrPreviewColumns"]),e.createVNode($r.ssDialog,{title:Y.title,visible:Y.show,width:Y.width,onBeforeDestroy:da},{default:e.withCtx(()=>[e.createElementVNode("div",wh,[e.createVNode(pl.ssForm,{rowContents:Y==null?void 0:Y.contents,formRules:Y==null?void 0:Y.formRules,showOperator:!1,buttonValue:Y.buttonValue,isEdit:ja.value,isStartJustify:!1,onOnButtonClick:Ma},null,8,["rowContents","formRules","buttonValue","isEdit"])])]),_:1},8,["title","visible","width"]),e.createVNode($r.ssDialog,{title:"",visible:J.show,width:J.width,alignCenter:!0,onBeforeDestroy:xe},{header:e.withCtx(()=>[e.createElementVNode("div",null,[e.createElementVNode("div",_h,e.toDisplayString(J.title),1),e.createVNode(Aa,{size:"small",type:"danger",style:{width:"100%"}},{default:e.withCtx(()=>v[41]||(v[41]=[e.createTextVNode(" (选择【覆盖】,可能会影响到原数据的引用关系;选择【跳过】将会放弃重复数据的导入。请谨慎操作!) ")])),_:1,__:[41]})])]),footer:e.withCtx(()=>[e.createElementVNode("div",Sh,[e.createVNode(Aa,{size:"small",style:{width:"100%","text-align":"left"},type:"info"},{default:e.withCtx(()=>[e.createTextVNode("引用模块:"+e.toDisplayString(rn.value||"暂无"),1)]),_:1}),e.createElementVNode("div",Eh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(J==null?void 0:J.buttonValue,be=>(e.openBlock(),e.createBlock(ke,{key:be==null?void 0:be.label,style:e.normalizeStyle({background:be==null?void 0:be.background,color:be==null?void 0:be.color}),onClick:Va=>Se(be==null?void 0:be.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(be==null?void 0:be.label),1)]),_:2},1032,["style","onClick"]))),128))])])]),default:e.withCtx(()=>[e.createVNode(l0,{columns:J==null?void 0:J.columns,tableData:J==null?void 0:J.tableData},{content:e.withCtx(({row:be,item:Va,slotData:ba,scope:Ya,column:Ia,columnProp:Ne,$index:Q})=>[e.createTextVNode(e.toDisplayString((be==null?void 0:be[Ia==null?void 0:Ia.prop])||(be==null?void 0:be[Ia==null?void 0:Ia.label])||(be==null?void 0:be[Ia==null?void 0:Ia.property])||(ba==null?void 0:ba[Ia==null?void 0:Ia.property])),1)]),_:1},8,["columns","tableData"])]),_:1},8,["visible","width"]),e.createVNode(pl.Signature,{signPadInfo:$a.value,onBeforeDestroy:wl,onClickSubmitSign:Qa},null,8,["signPadInfo"])])}}},Yc=pr._export_sfc(Dh,[["__scopeId","data-v-12c76af6"]]),Th={key:1,class:"static-form-body"},Bh=["onClick"],Nh=["src"],Ah={key:1},zh=["src"],Mh=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},backgroundPosition:{default:"Center"},iconUrl:{default:void 0},calculator:{default:()=>[]},textBackColor:{default:void 0}},emits:["update:backGroundImage"],setup(a,{emit:l}){const r=a,n=l,i=x=>{switch(x){case"占用":return"warning";case"注销":return"info";case"损坏":return"danger";case"可用":return"success";default:return""}},o=e.computed(()=>{var I;const x=(I=r.itemData)==null?void 0:I.find(R=>(R==null?void 0:R.key)==="formContent"),b=(x==null?void 0:x.contents)||[];return(r.fields&&r.fields.length>0?r.fields:b).filter(R=>(R==null?void 0:R.label)||(R==null?void 0:R.isHideInForm)).map(R=>{let re=R==null?void 0:R.value;Array.isArray(re)&&(re=re.map(U=>U==null?"":typeof U=="object"?U.label??U.value??U.name??JSON.stringify(U):String(U)).filter(Boolean).join(",")),re!=null&&typeof re=="object"&&(re=re.label??re.value??re.name??JSON.stringify(re));const X=R.isHideInForm?"":R.label??"",me=re==null||re===""?"-":String(re),ue=X==="使用状态";return{label:X,value:me,isStatus:ue,tagType:ue?i(me):"",width:R.width??1,field:R}})}),p=e.ref(null),c=e.ref(null),u=e.computed(()=>{const x=Number(r==null?void 0:r.textSize),b=le.rgbaToColor(r==null?void 0:r.textColor),S={},I={},R={},re={};return!Number.isNaN(x)&&x&&(S.fontSize=`${x}px`,I.fontSize=`${x+1}px`,R.fontSize=`${x}px`,re.fontSize=`${x}px`),b&&(I.color=b,R.color=b,re.color=b),{item:S,label:I,value:R,empty:re}}),m=e.ref(""),g=e.ref(""),y=e.ref(!1),d=async x=>{if(x){g.value&&(URL.revokeObjectURL(g.value),g.value="");try{const b=await M.platformDownloadFile({url:x}),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(()=>r==null?void 0:r.backGroundImage,x=>{x&&(m.value=x)},{immediate:!0}),e.watch(m,x=>{d(x)},{immediate:!0});const D=async()=>{var x,b;((x=r==null?void 0:r.calculator)==null?void 0:x.length)>0&&await Vt(o.value,"Auto",[],r==null?void 0:r.calculator),(b=c.value)==null||b.click()},w=async x=>{var I,R,re;const b=x.target,S=(I=b==null?void 0:b.files)==null?void 0:I[0];if(!S){b.value="";return}y.value=!0;try{const X=new FormData;X.append("file",S);const me=await M.platformUploadFile(X),ue=(re=(R=me==null?void 0:me.data)==null?void 0:R.result)==null?void 0:re.url;ue?(m.value=ue,n("update:backGroundImage",ue),d(ue),Ja.ElMessage.success("背景图片上传成功")):Ja.ElMessage.error("背景图片上传失败")}catch{Ja.ElMessage.error("背景图片上传失败")}finally{y.value=!1,b.value=""}},q=e.computed(()=>{var x,b,S,I;return g.value||(r==null?void 0:r.backgroundUrl)!==""?{backgroundImage:`url("${(x=r==null?void 0:r.backgroundUrl)==null?void 0:x.replace(/\\/g,"/")}")`,backgroundPosition:`${((b=r==null?void 0:r.backgroundPosition)==null?void 0:b.toLowerCase())??"center"} center`,backgroundRepeat:"no-repeat",cursor:((S=r==null?void 0:r.calculator)==null?void 0:S.length)>0?"pointer":"auto"}:{cursor:((I=r==null?void 0:r.calculator)==null?void 0:I.length)>0?"pointer":"auto",background:r!=null&&r.textBackColor?le.rgbaToColor(r==null?void 0:r.textBackColor):void 0}}),A=x=>pl.getComponent(x),j=x=>{if(!x)return;const b=x.querySelector("input, textarea, .el-input__inner");b&&typeof b.focus=="function"&&b.focus()},O=(x,b,S)=>{r.disabled||(p.value=b,e.nextTick(()=>{j(S.currentTarget)}))},E=()=>{p.value=null},_=x=>{const b=x!=null&&x.width&&x.width>0?x.width:1,I=`calc((100% - ${(b-1)*48}px) / ${b})`;return{flex:`0 0 ${I}`,maxWidth:I,minWidth:"0",boxSizing:"border-box"}};return(x,b)=>{const S=e.resolveComponent("el-tag");return e.openBlock(),e.createElementBlock("div",{class:"static-form-card",style:e.normalizeStyle(q.value),onClick:b[1]||(b[1]=I=>D())},[(r==null?void 0:r.backGround)==="Yes"?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-backGround-upload",onClick:b[0]||(b[0]=e.withModifiers(I=>D(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:c,type:"file",accept:"image/*",style:{display:"none"},onChange:w},null,544),b[2]||(b[2]=e.createElementVNode("img",{src:pl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),o.value.length?(e.openBlock(),e.createElementBlock("div",Th,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,(I,R)=>{var re,X,me,ue,U,W,Z,ae,ve;return e.openBlock(),e.createElementBlock("div",{key:R,class:"static-form-item",style:e.normalizeStyle({..._(I),...u.value.item})},[I.label&&!((re=I==null?void 0:I.field)!=null&&re.isHideInForm)?(e.openBlock(),e.createElementBlock("div",{key:0,class:"static-form-label",style:e.normalizeStyle(u.value.label)},e.toDisplayString(I.label)+": ",5)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"static-form-value",style:e.normalizeStyle(u.value.value),onClick:ze=>{var te;return(te=I.field)!=null&&te.isNoClick?null:O(I,R,ze)}},[x.iconUrl&&x.backgroundPosition==="Left"?(e.openBlock(),e.createElementBlock("img",{key:0,src:x.iconUrl,class:"bg-upload-icon"},null,8,Nh)):e.createCommentVNode("",!0),p.value===R&&I.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A(((X=I.field)==null?void 0:X.type)??"Input")),{key:1,modelValue:I.field.value,"onUpdate:modelValue":ze=>I.field.value=ze,isEdit:!0,disabled:(me=I.field)==null?void 0:me.disabled,content:((ue=I.field)==null?void 0:ue.contents)??[],optionUrl:I.field,originalValue:(U=I.field)==null?void 0:U.value,config:(W=I.field)==null?void 0:W.config,configModel:((Z=I.field)==null?void 0:Z.prop)??((ae=I.field)==null?void 0:ae.name),selectedTagList:((ve=I.field)==null?void 0:ve.selectValue)??[],onBlur:E,onBlurChange:E},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[I.isStatus?(e.openBlock(),e.createBlock(S,{key:0,type:I.tagType,size:"Default",effect:"plain"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(I.value??"-"),1)]),_:2},1032,["type"])):(e.openBlock(),e.createElementBlock("span",Ah,e.toDisplayString(I.value??"-"),1))],64)),x.iconUrl&&x.backgroundPosition==="Right"?(e.openBlock(),e.createElementBlock("img",{key:3,src:x.iconUrl,class:"bg-upload-icon"},null,8,zh)):e.createCommentVNode("",!0)],12,Bh)],4)}),128))])):(e.openBlock(),e.createElementBlock("div",{key:2,class:"static-form-empty",style:e.normalizeStyle(u.value.empty)}," 暂无数据 ",4))],4)}}}),Jc=pr._export_sfc(Mh,[["__scopeId","data-v-f6c4a15a"]]),Ih={class:"form-content"},Oh={title:"选择标签"},Lh={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},Rh={class:"col-operate-wrap"},$h={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},Vh={__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:()=>{}},calculator:{type:Array,default:()=>[]}},emits:["change","contentChange","routeUrl","clickTrigger"],setup(a,{emit:l}){const r=()=>{m.value=!1,g.value=!1,y.value=[]},n=a;e.computed(()=>{var na;const ne=(na=Me.value)==null?void 0:na.split("/");return(ne==null?void 0:ne.some(va=>(va==null?void 0:va.includes("updateLoading"))||(va==null?void 0:va.includes("loading"))))?!1:se.value==="view"});const i=l,o=e.ref(""),p=e.ref(""),c=e.ref("Center"),u=e.ref([]),m=e.ref(!1),g=e.ref(!1),y=e.ref([]),{getFileExtension:d}=Do.useThreeSystem(),D=e.ref(),w=e.ref(!1),q=e.ref(!1),A=M.useUnit(M.pinia),{chooseTitle:j}=M.storeToRefs(A),O=e.ref([]),E=e.ref(),_=e.ref(!1),x=e.ref([]),b=Ec(M.pinia),S=Ft(M.pinia),I=e.ref(!1),R=e.ref(),re=e.ref(),X=e.ref(),me=e.ref(),ue=e.ref(),U=e.ref(),W=M.useLoginState(M.pinia),{loginUserInfo:Z}=M.storeToRefs(W),ae=e.ref(),ve=e.ref(!0),ze=M.useModelComp(M.pinia),{tableViewContents:te,itemData:N,isEdit:se,routeToChildPath:G,lockingPage:fe,homepageBackgroundTableId:we,refreshCurrentPageInform:_e}=M.storeToRefs(ze),qe=e.ref(null),ra=e.ref(!1),P=e.ref(!1),Ke=M.useMenuState(),{activeMenuPath:Me}=M.storeToRefs(Ke),Le=le.useOriginalState(M.pinia),{originalPath:Ie}=M.storeToRefs(Le),{compType:de,hasEditable:De}=dc.useRole(),Xe=()=>!De(n.config,{type:de.FORM});e.computed(()=>Me.value==="设备管理/试验设备"&&n.compName==="设备概要");const Ea=async()=>{var na,va,Ae;const ne=we==null?void 0:we.value,We=(na=Z==null?void 0:Z.value)==null?void 0:na.plat_id;if(!(!ne||!We))try{const Be=await M.getAllTables({platId:parseInt(We),tableNames:[`content_${ne}`,`struct_${ne}`],user_unique_id:"0"}),Ye=((Ae=(va=Be==null?void 0:Be.data)==null?void 0:va.result)==null?void 0:Ae[0])??[],Ee=String((n==null?void 0:n.index)??""),ye=Ye==null?void 0:Ye.find($a=>String($a==null?void 0:$a.relatedForm_id)===Ee);ye!=null&&ye.backgroundImg_url&&(ue.value=ye.backgroundImg_url)}catch(Be){console.error("获取首页背景图片表数据失败:",Be)}},Ge=e.ref([]),$=e.ref([{label:"编辑",value:"operable",checked:!1},{label:"禁用",value:"disabled",checked:!1}]),V=async ne=>{P.value=ne,await ya("disabled",null,ne,!0)},ee=async ne=>{await ya("operable",null,ne,!0)};e.watch(()=>Me.value,async()=>{u.value=[],y.value=[]},{deep:!0,immediate:!0});const ce=()=>{e.nextTick(()=>{Ve()})},he=ne=>{var We;u.value=(We=u.value)==null?void 0:We.map(na=>({...na,isFormColHidden:!(ne!=null&&ne.includes(na.label))}))};e.onUnmounted(()=>{qe.value=null});const pa=ne=>{i("clickTrigger",ne)},ia=async ne=>{var We,na,va,Ae,Be,Ye;if(ne===""){let Ee="";(We=u.value)==null||We.forEach(Qa=>{Qa!=null&&Qa.isMain&&(Ee=Qa==null?void 0:Qa.value)});let ye=await le.getItemData(G.value,sessionStorage.getItem("systemKey"),"");Ee=((Ye=(Be=(Ae=(va=(na=ye==null?void 0:ye[0])==null?void 0:na.compData)==null?void 0:va.find(Qa=>(Qa==null?void 0:Qa.key)==="mainRouters"))==null?void 0:Ae.contents)==null?void 0:Be[0])==null?void 0:Ye.routerContent)+Ie.value+Ee;let wl=await le.getItemData(Ee,sessionStorage.getItem("systemKey"),"");_.value=!0,x.value=wl==null?void 0:wl.filter(Qa=>(Qa==null?void 0:Qa.comp)!=="methodButton"),i("routeUrl",x.value)}},Ve=()=>{var We;const ne=(We=qe.value)==null?void 0:We.$el;ne&&Fl.Sortable.create(ne,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:na=>{const{oldIndex:va,newIndex:Ae}=na;if(va===Ae)return;const Be=u.value.splice(va,1)[0];u.value.splice(Ae,0,Be)}})},ya=async(ne,We,na,va=!1)=>{try{ze.setRefreshCurStructure(!1)}catch{Ja.ElMessage.error("编辑处理失败")}},Ca=async(ne,We)=>{await ya()},Ce=async(ne,We)=>{ne&&await ya()},Fa=async(ne,We,na)=>{await ya(We,na,ne,!1)},Ta=(ne,We)=>{ae.value===We?ve.value=!1:ve.value=!0,ae.value=We==null?void 0:We.changeProp},fa=async ne=>{var Ye;ue.value=ne;const We=n.itemData,na=We==null?void 0:We.find(Ee=>(Ee==null?void 0:Ee.key)==="backGroundImage");na?na.contents=ne:We==null||We.push({key:"backGroundImage",contents:ne}),i("change",{key:"backGroundImage",contents:ne});const va=we==null?void 0:we.value,Ae=n==null?void 0:n.index,Be=(Ye=Z==null?void 0:Z.value)==null?void 0:Ye.plat_id;if(!(!va||!Be||!Ae||!ne))try{await M.pageBatchAddApi({platId:parseInt(Be),changeContents:[{tableName:`content_${va}`,tableContents:[{backgroundImg_url:ne,relatedForm_id:String(Ae)}]}],user_unique_id:"0"})}catch(Ee){console.error("保存背景图片记录失败:",Ee),Ja.ElMessage.error("背景图片记录保存失败")}},ja=async ne=>{var na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl;let We=[];if((na=ne==null?void 0:ne.toString())!=null&&na.includes(".urdf")){if(ne.includes(",")){Ja.ElMessage.error("当前版本仅允许单个urdf预览!");return}y.value=[{url:ne,extension:d(ne)}],g.value=!0,m.value=!0;return}if((va=ne==null?void 0:ne.toString())!=null&&va.includes(".stl")||(Ae=ne==null?void 0:ne.toString())!=null&&Ae.includes(".STL")||(Be=ne==null?void 0:ne.toString())!=null&&Be.includes(".obj")||(Ye=ne==null?void 0:ne.toString())!=null&&Ye.includes(".mtl")){const Gl=((Ee=ne==null?void 0:ne.toString())==null?void 0:Ee.split(",")).map(Kl=>({url:Kl,extension:d(Kl)}));y.value=Gl,g.value=!1,m.value=!0;return}if((ye=ne==null?void 0:ne.toString())!=null&&ye.includes(".stl")||($a=ne==null?void 0:ne.toString())!=null&&$a.includes(".STL")||(wl=ne==null?void 0:ne.toString())!=null&&wl.includes(".obj")||(Qa=ne==null?void 0:ne.toString())!=null&&Qa.includes(".mtl")){let Wa,Gl=[],Kl={};if(Array.isArray(ne)?Wa=ne:Wa=ne==null?void 0:ne.split(","),Wa==null||Wa.forEach(Zl=>{Zl.includes(".mtl")?Gl.push(Zl):Kl.blob=Kl.blob?Kl.blob+","+Zl:Zl}),(Gl==null?void 0:Gl.length)>0&&(Kl.mtlBlobs=Gl),(gl=(Pl=Object.values(Kl))==null?void 0:Pl[0])!=null&&gl.includes("http:"))We.push(Kl);else{const Zl=new Blob([Kl.blob],{type:"application/octet-stream;charset=UTF-8"});let Sl=URL.createObjectURL(Zl),dr="";(jl=ne==null?void 0:ne.split("/"))==null||jl.forEach((ga,il)=>{var fl;il===((fl=ne==null?void 0:ne.split("/"))==null?void 0:fl.length)-1&&(dr=ga)}),(al=Kl.blob)!=null&&al.includes(".stl")&&(dr=(dr==null?void 0:dr.replaceAll(">",""))+".urdf"),E.value=[{name:dr,blobUrl:Sl}],q.value=!0}}else{const Wa=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),Gl=await Ja.axios.get(ne,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{Wa.close()}),Kl=new Blob([Gl.data],{type:"application/octet-stream;charset=UTF-8"});let Zl=URL.createObjectURL(Kl),Sl="";(Hl=ne==null?void 0:ne.split("/"))==null||Hl.forEach((dr,ga)=>{var il;ga===((il=ne==null?void 0:ne.split("/"))==null?void 0:il.length)-1&&(Sl=dr)}),E.value=[{name:Sl,blobUrl:Zl}],q.value=!0}(We==null?void 0:We.length)>0&&S.setBlobUrls(We)},sa=()=>{q.value=!1},Pe=ne=>{var Be,Ye,Ee,ye;const We=(Ye=(Be=pl.safeClone(n.itemData))==null?void 0:Be.find($a=>($a==null?void 0:$a.key)==="formContent"))==null?void 0:Ye.contents,na=pl.safeClone(ne.content);let va={};na&&((Ee=Object.values(na))==null?void 0:Ee.length)>0&&((ye=Object.values(na))==null||ye.forEach(($a,wl)=>{va[We[wl].key]=$a}));const Ae={content:va,index:n==null?void 0:n.index,buttonName:ne==null?void 0:ne.buttonName};i("change",Ae)};e.computed(()=>"http://222.92.178.198:62001");const ma=async ne=>{var Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha;if(!ne)return;(gl=(Pl=n==null?void 0:n.itemData)==null?void 0:Pl.find(Sa=>(Sa==null?void 0:Sa.key)==="parentFormPath"))==null||gl.contents;let We=te.value;(We==null?void 0:We.length)>0&&(We=We==null?void 0:We.map(Sa=>{var Te,oa,Ka,pe;let ll=(Te=Sa==null?void 0:Sa.key)==null?void 0:Te.split("/");return(n==null?void 0:n.compName)===(ll==null?void 0:ll[0])&&(oa=u.value)!=null&&oa.find(_a=>(_a==null?void 0:_a.prop)===(ll==null?void 0:ll[1]))&&(Sa.value=(pe=(Ka=u.value)==null?void 0:Ka.find(_a=>(_a==null?void 0:_a.prop)===(ll==null?void 0:ll[1])))==null?void 0:pe.value),Sa}),ze.setTableViewContents(We));const na=pl.safeClone(n.itemData);let va=na==null?void 0:na.map(Sa=>{var ll;return(Sa==null?void 0:Sa.key)==="formContent"&&((ll=Sa.contents)==null||ll.map((Te,oa)=>{var Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe,bl,tr,xr,Ra,kl,Ml,Oa,aa;return Te.type=(pe=(Ka=u.value)==null?void 0:Ka.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:pe.type,Te.options=Te!=null&&Te.options?Te.options:((ul=(Pa=(_a=Te==null?void 0:Te.key)==null?void 0:_a.split("$"))==null?void 0:Pa[1])==null?void 0:ul.length)>0?(ua=(Xa=id((ca=(Ol=Te==null?void 0:Te.key)==null?void 0:Ol.split("$"))==null?void 0:ca[1]))==null?void 0:Xa.split(","))==null?void 0:ua.map(Rl=>({label:Rl,value:Rl})):[],(wa=Te==null?void 0:Te.key)!=null&&wa.includes("$")&&(Te.key=(hl=(Ba=Te==null?void 0:Te.key)==null?void 0:Ba.split("$"))==null?void 0:hl[0]),Te.signature=(bl=(Fe=u.value)==null?void 0:Fe.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:bl.signature,Te.isLoginUser=(xr=(tr=u.value)==null?void 0:tr.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:xr.isLoginUser,Te.value=(Ra=Object.values(ne))==null?void 0:Ra[oa],Te.isFormColHidden=(Ml=(kl=u.value)==null?void 0:kl.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:Ml.isFormColHidden,Te.isHideInForm=(aa=(Oa=u.value)==null?void 0:Oa.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:aa.isHideInForm,Te})),Sa}),Ae=u.value,Be=(al=(jl=pl.safeClone(va))==null?void 0:jl.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:al.contents;if(Ae=Ae==null?void 0:Ae.map(Sa=>{var ll,Te;return(Sa==null?void 0:Sa.type)==="Select"&&((ll=Sa==null?void 0:Sa.allSelectionContents)==null?void 0:ll.length)>0&&(Sa.contactValue=ne),Sa.value=(Te=Be==null?void 0:Be.find((oa,Ka)=>((oa==null?void 0:oa.id)??Ka)===(Sa==null?void 0:Sa.id)))==null?void 0:Te.value,Sa}),!ve.value){i("contentChange",{contents:va,index:n.index});return}let Ye="",Ee=(Gl=(Wa=(Hl=pl.safeClone(va))==null?void 0:Hl.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:Wa.contents)==null?void 0:Gl.find((Sa,ll)=>{var Te,oa,Ka;return(Sa==null?void 0:Sa.label)===ae.value||ll.toString()===((Ka=(oa=(Te=ae.value)==null?void 0:Te.split("t"))==null?void 0:oa[1])==null?void 0:Ka.toString())}),ye=(Kl=Ee==null?void 0:Ee.optionUrl)==null?void 0:Kl.menuSelect,$a=!0;if((dr=(Sl=(Zl=pl.safeClone(va))==null?void 0:Zl.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:Sl.contents)==null||dr.forEach(Sa=>{var ll,Te,oa,Ka,pe,_a;$a&&((oa=(Te=(ll=Sa==null?void 0:Sa.optionUrl)==null?void 0:ll.groupSelect)==null?void 0:Te[1])!=null&&oa.includes("["))&&(Ye=(pe=(Ka=Sa==null?void 0:Sa.optionUrl)==null?void 0:Ka.groupSelect)==null?void 0:pe[1],JSON.stringify(ye)===JSON.stringify((_a=Sa==null?void 0:Sa.optionUrl)==null?void 0:_a.menuSelect)&&($a=!1))}),(ga=Ee==null?void 0:Ee.optionUrl)!=null&&ga.menuSelect&&ve.value){let Sa=await At(Ee),ll,Te=(il=Ee==null?void 0:Ee.optionUrl)==null?void 0:il.menuSelect;if(Sa==null||Sa.forEach(oa=>{var Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa;Ye===((pe=(Ka=Ee==null?void 0:Ee.optionUrl)==null?void 0:Ka.groupSelect)==null?void 0:pe[1])&&((ul=(Pa=(_a=Ee==null?void 0:Ee.optionUrl)==null?void 0:_a.groupSelect)==null?void 0:Pa[1])!=null&&ul.includes("["))&&((wa=pl.safeClone(oa))==null?void 0:wa[(ua=(Xa=(ca=(Ol=Ee==null?void 0:Ee.optionUrl)==null?void 0:Ol.groupSelect)==null?void 0:ca[1])==null?void 0:Xa.replaceAll("[",""))==null?void 0:ua.replaceAll("]","")])===(Ee==null?void 0:Ee.value)&&(ll=oa)}),ll){let oa=pl.safeClone(Ae);oa=oa==null?void 0:oa.map(pe=>{var _a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe;return(ll!=null&&ll[pe==null?void 0:pe.label]||ll!=null&&ll[(Ol=(ul=(Pa=(_a=pe==null?void 0:pe.optionUrl)==null?void 0:_a.groupSelect)==null?void 0:Pa[1])==null?void 0:ul.replaceAll("[",""))==null?void 0:Ol.replaceAll("]","")])&&((ua=(Xa=(ca=pe==null?void 0:pe.optionUrl)==null?void 0:ca.groupSelect)==null?void 0:Xa[1])!=null&&ua.includes("["))&&Te!=null&&Te.every(bl=>{var tr,xr;return(xr=(tr=pe==null?void 0:pe.optionUrl)==null?void 0:tr.menuSelect)==null?void 0:xr.includes(bl)})&&(pe.value=(ll==null?void 0:ll[pe==null?void 0:pe.label])||(ll==null?void 0:ll[(Fe=(hl=(Ba=(wa=pe==null?void 0:pe.optionUrl)==null?void 0:wa.groupSelect)==null?void 0:Ba[1])==null?void 0:hl.replaceAll("[",""))==null?void 0:Fe.replaceAll("]","")]),Array.isArray(pe.value)&&pe.value.every(bl=>(bl==null?void 0:bl.url)&&(bl==null?void 0:bl.name))&&(pe.type="Upload")),pe}),oa=oa==null?void 0:oa.map(pe=>{var _a,Pa,ul;return(_a=pe==null?void 0:pe.optionUrl)!=null&&_a.oldMenuSelect&&(pe.optionUrl.menuSelect=(ul=(Pa=pl.safeClone(pe))==null?void 0:Pa.optionUrl)==null?void 0:ul.oldMenuSelect),pe}),u.value=pl.safeClone(oa);let Ka=pl.safeClone(oa);Ka=Ka==null?void 0:Ka.map(pe=>{var _a,Pa,ul,Ol,ca,Xa;return(Pa=(_a=pe==null?void 0:pe.optionUrl)==null?void 0:_a.menuSelect)!=null&&Pa.some(ua=>ua==null?void 0:ua.includes("["))&&(pe.optionUrl.oldMenuSelect=(Ol=(ul=pl.safeClone(pe))==null?void 0:ul.optionUrl)==null?void 0:Ol.menuSelect,pe.optionUrl.menuSelect=(Xa=(ca=pe==null?void 0:pe.optionUrl)==null?void 0:ca.menuSelect)==null?void 0:Xa.map(ua=>{var wa,Ba,hl,Fe;if(ua!=null&&ua.includes("[")){let bl=(Ba=(wa=ua==null?void 0:ua.replaceAll("[","").replaceAll("]",""))==null?void 0:wa.split(":"))==null?void 0:Ba[1];ua=(Fe=(hl=pl.safeClone(oa))==null?void 0:hl.find(tr=>(tr==null?void 0:tr.label)===bl))==null?void 0:Fe.value}return ua})),pe}),u.value=Ka}else u.value=Ae;va=va==null?void 0:va.map(oa=>{var Ka;return(oa==null?void 0:oa.key)==="formContent"&&(oa.contents=(Ka=oa.contents)==null?void 0:Ka.map(pe=>{var _a,Pa,ul,Ol;return pe.value=((Pa=(_a=u.value)==null?void 0:_a.find(ca=>(ca==null?void 0:ca.label)===(pe==null?void 0:pe.key)))==null?void 0:Pa.value)??(pe==null?void 0:pe.value),pe.type=((Ol=(ul=u.value)==null?void 0:ul.find(ca=>(ca==null?void 0:ca.prop)===(pe==null?void 0:pe.key)))==null?void 0:Ol.type)??(pe==null?void 0:pe.type),pe})),oa})}ve.value=!1,i("contentChange",{contents:va,index:n.index});let wl=[],Qa=[];if((Bl=pl.safeClone((fl=va==null?void 0:va.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:fl.contents))==null||Bl.forEach(Sa=>{var ll;Array.isArray(Sa==null?void 0:Sa.value)&&((ll=Sa==null?void 0:Sa.value)!=null&&ll.find(Te=>{var oa;return(oa=Te==null?void 0:Te.url)==null?void 0:oa.includes(".obj")}))&&(Qa=Sa==null?void 0:Sa.value)}),(Qa==null?void 0:Qa.length)>0){const Sa=(Ha=pl.safeClone(Qa))==null?void 0:Ha.filter(ll=>{var Te;return(Te=ll==null?void 0:ll.url)==null?void 0:Te.includes(".obj")});Sa==null||Sa.forEach(ll=>{var oa,Ka,pe,_a;const Te=(oa=Qa==null?void 0:Qa.filter(Pa=>{var ul;return(Pa==null?void 0:Pa.name)===(ll==null?void 0:ll.name)&&((ul=Pa==null?void 0:Pa.url)==null?void 0:ul.includes(".mtl"))}))==null?void 0:oa.map(Pa=>Pa==null?void 0:Pa.url);wl.push({objUrl:ll==null?void 0:ll.url,mtlUrls:((Ka=Qa==null?void 0:Qa.filter(Pa=>{var ul;return(Pa==null?void 0:Pa.name)===(ll==null?void 0:ll.name)&&((ul=Pa==null?void 0:Pa.url)==null?void 0:ul.includes(".mtl"))}))==null?void 0:Ka.length)===1?(_a=(pe=Qa==null?void 0:Qa.filter(Pa=>{var ul;return(Pa==null?void 0:Pa.name)===(ll==null?void 0:ll.name)&&((ul=Pa==null?void 0:Pa.url)==null?void 0:ul.includes(".mtl"))}))==null?void 0:pe[0])==null?void 0:_a.url:Te})}),S.setObjUrl(wl)}},Qe=(ne,We,na)=>{let va="";const Ae=We==null?void 0:We.map(Be=>{var Ye;return(Ye=Be==null?void 0:Be.value)==null?void 0:Ye.pageData});return Ae==null||Ae.forEach(Be=>{var Ye;(Be==null?void 0:Be.name)===(ne==null?void 0:ne[0])&&((Ye=Be==null?void 0:Be.compData)==null||Ye.forEach(Ee=>{var ye;(Ee==null?void 0:Ee.key)==="formContent"&&((ye=Ee==null?void 0:Ee.contents)==null||ye.forEach($a=>{var wl;($a==null?void 0:$a.prop)===(ne==null?void 0:ne[1])&&(va=($a==null?void 0:$a.value)===""?le.judgeContents((wl=pl.safeClone($a))==null?void 0:wl.optionUrl,na):$a==null?void 0:$a.value)}))}))}),va},Oe=(ne,We,na,va)=>{var Ee,ye;let Ae="",Be="";(Ee=pl.safeClone(We))==null||Ee.forEach(($a,wl)=>{$a!=null&&$a.includes("[")?Be=Be+Ie.value+ne[wl]:Be=Be===""?Be+$a:Be+"/"+$a});let Ye=(ye=va[Be])==null?void 0:ye.map($a=>{var wl;return(wl=$a==null?void 0:$a.value)==null?void 0:wl.pageData});return Ye==null||Ye.forEach($a=>{var wl;($a==null?void 0:$a.name)===(na==null?void 0:na[0])&&((wl=$a==null?void 0:$a.compData)==null||wl.forEach(Qa=>{var Pl;(Qa==null?void 0:Qa.key)==="formContent"&&((Pl=Qa==null?void 0:Qa.contents)==null||Pl.forEach(gl=>{(gl==null?void 0:gl.prop)===(na==null?void 0:na[1])&&(Ae=gl==null?void 0:gl.value)}))}))}),Ae};e.watch(()=>we==null?void 0:we.value,async()=>{await Ea()},{immediate:!0});const $e=async ne=>await Vt(ne,"Auto");return e.watch(()=>_e.value,async()=>{var ne;(ne=u.value)!=null&&ne.some(We=>(We==null?void 0:We.functionName)&&(We==null?void 0:We.functionName)!=="")&&(u.value=await $e(u.value))},{immediate:!0,deep:!0}),e.watch(()=>n.itemData,async()=>{var jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha,Sa,ll,Te,oa,Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe,bl,tr,xr,Ra,kl,Ml;const ne=(jl=n.itemData)==null?void 0:jl.find(Oa=>(Oa==null?void 0:Oa.key)==="formContent");let We=(al=n.itemData)==null?void 0:al.find(Oa=>(Oa==null?void 0:Oa.key)==="backGround");We&&((Hl=We==null?void 0:We.contents)==null?void 0:Hl.length)>0&&(((Gl=(Wa=We==null?void 0:We.contents)==null?void 0:Wa[0])==null?void 0:Gl.fileType)==="Picture"&&(o.value=((Zl=(Kl=We==null?void 0:We.contents)==null?void 0:Kl[0])==null?void 0:Zl.url)??""),((dr=(Sl=We==null?void 0:We.contents)==null?void 0:Sl[0])==null?void 0:dr.fileType)==="Icon"&&(p.value=((il=(ga=We==null?void 0:We.contents)==null?void 0:ga[0])==null?void 0:il.url)??""),c.value=((Bl=(fl=We==null?void 0:We.contents)==null?void 0:fl[0])==null?void 0:Bl.position)??"");const na=(Ha=pl.safeClone(n.itemData))==null?void 0:Ha.find(Oa=>(Oa==null?void 0:Oa.key)==="formButton"),va=(Sa=pl.safeClone(n.itemData))==null?void 0:Sa.find(Oa=>(Oa==null?void 0:Oa.key)==="formFlex"),Ae=(ll=pl.safeClone(n.itemData))==null?void 0:ll.find(Oa=>(Oa==null?void 0:Oa.key)==="formWrap"),Be=(Te=pl.safeClone(n.itemData))==null?void 0:Te.find(Oa=>(Oa==null?void 0:Oa.key)==="enableWrap"),Ye=(oa=pl.safeClone(n.itemData))==null?void 0:oa.find(Oa=>(Oa==null?void 0:Oa.key)==="textSize"),Ee=(Ka=pl.safeClone(n.itemData))==null?void 0:Ka.find(Oa=>(Oa==null?void 0:Oa.key)==="textRGBA"),ye=(pe=pl.safeClone(n.itemData))==null?void 0:pe.find(Oa=>(Oa==null?void 0:Oa.key)==="textBackRGBA"),$a=(_a=pl.safeClone(n.itemData))==null?void 0:_a.find(Oa=>(Oa==null?void 0:Oa.key)==="backGround"),wl=(Pa=pl.safeClone(n.itemData))==null?void 0:Pa.find(Oa=>(Oa==null?void 0:Oa.key)==="backGroundImage");(Ae==null?void 0:Ae.contents)==="纵向"?w.value=!1:w.value=!0;const Qa=Number(Ye==null?void 0:Ye.contents);R.value=Number.isNaN(Qa)?void 0:Qa,re.value=Ee==null?void 0:Ee.contents,X.value=ye==null?void 0:ye.contents,me.value=$a==null?void 0:$a.contents,ue.value=wl==null?void 0:wl.contents;const Pl=Be==null?void 0:Be.contents;if(Pl===void 0?I.value=vi.BLOCK:typeof Pl=="boolean"?I.value=Pl?vi.ORDINARY:vi.BLOCK:I.value=Pl,U.value=typeof(va==null?void 0:va.contents)!="boolean"?!(!(va!=null&&va.contents)===""||((ul=va==null?void 0:va.contents)==null?void 0:ul.toUpperCase())==="VERTICAL"):va==null?void 0:va.contents,((Ol=ne==null?void 0:ne.contents)==null?void 0:Ol.length)>0&&Array.isArray(ne==null?void 0:ne.contents)){let Oa=n.allMapContents;const aa=(Xa=(ca=pl.safeClone(ne))==null?void 0:ca.contents)==null?void 0:Xa.map((Re,lr)=>{var Ur,Br,Tr,gn,Sn,Cn,mn,On,rn,Dn,Vn,nn,Fn;let Yl=(Re==null?void 0:Re.label)??(Re==null?void 0:Re.key)??"";Re==null||Re.type;let an=(Re==null?void 0:Re.options)??[];if((Ur=Re==null?void 0:Re.key)!=null&&Ur.includes("$")&&(Yl=(Br=pl.safeClone(Re==null?void 0:Re.key).split("$"))==null?void 0:Br[0],((gn=(Tr=pl.safeClone(Re==null?void 0:Re.key).split("$"))==null?void 0:Tr[1])==null?void 0:gn.length)>0)){const[zr,An]=(Cn=(Sn=pl.safeClone(Re==null?void 0:Re.key).split("$"))==null?void 0:Sn[1])==null?void 0:Cn.split(/[()]/);(mn=le.FormType.find(Tn=>(Tn==null?void 0:Tn.key)===zr))==null||mn.value,((On=An==null?void 0:An.split(","))==null?void 0:On.length)>0&&(an=(rn=An==null?void 0:An.split(","))==null?void 0:rn.map(Tn=>({label:Tn,value:Tn})))}let Sr=Re==null?void 0:Re.options;((Dn=Re==null?void 0:Re.optionUrl)==null?void 0:Dn.selectRelateType)==="自定义绑定"&&(Sr=(nn=(Vn=Re==null?void 0:Re.optionUrl)==null?void 0:Vn.defaultSelect)==null?void 0:nn.map(zr=>({label:zr,value:zr})));let Jl=(Re==null?void 0:Re.menuPath)??[],Er=(Re==null?void 0:Re.groups)??[],Xl=(Re==null?void 0:Re.columns)??[],$l=!1,nr=(Re==null?void 0:Re.isFormColHidden)??!1,Ql="",Ul=Re!=null&&Re.value?Re.value:(Sr==null?void 0:Sr.length)>0?(Fn=Sr==null?void 0:Sr[0])==null?void 0:Fn.value:(Re==null?void 0:Re.value)??"",Nl=!1,Vr="Input";return((Sr==null?void 0:Sr.length)>0||(Jl==null?void 0:Jl.length)>0)&&(Vr="Select"),(Array.isArray(Ql)&&(Ql!=null&&Ql.every(zr=>(zr==null?void 0:zr.name)&&(zr==null?void 0:zr.url)))||Array.isArray(Ul)&&(Ul!=null&&Ul.every(zr=>(zr==null?void 0:zr.name)&&(zr==null?void 0:zr.url))))&&(Vr="upload"),Re!=null&&Re.isMainUrl&&(Vr="Url"),{label:Yl??"",name:Yl??"t"+lr,prop:Yl??pl.safeClone(Re==null?void 0:Re.key),type:(Re==null?void 0:Re.type)??Vr,value:(Re==null?void 0:Re.type)==="Date"&&Ul===""?new Date:Ul,id:(Re==null?void 0:Re.id)??lr,contents:(Sr==null?void 0:Sr.length)>0?Sr:an??[],width:(Re==null?void 0:Re.width)??1,isLoginUser:$l,config:Re==null?void 0:Re.config,optionUrl:(Re==null?void 0:Re.optionUrl)??Re,isFormColHidden:nr,isHideInForm:(Re==null?void 0:Re.isHideInForm)??!1,signature:Nl,isMain:Re==null?void 0:Re.isMain,required:(Re==null?void 0:Re.required)??!1,isMainUrl:Re==null?void 0:Re.isMainUrl,operable:(Re==null?void 0:Re.operable)??!1,disabled:(Re==null?void 0:Re.disabled)??!1,isSync:Re==null?void 0:Re.isSync,menus:Jl,groups:Er,words:Xl,allSelectionContents:Re==null?void 0:Re.allContents,filterContent:Re==null?void 0:Re.filterContents,isNoClick:(Re==null?void 0:Re.isNoClick)??!1,functionName:Re==null?void 0:Re.functionName,functionRelatedWords:Re==null?void 0:Re.functionRelatedWords,calculatorFilter:Re==null?void 0:Re.calculatorFilter,filters:Re==null?void 0:Re.filters}}),Rl=aa==null?void 0:aa.map(Re=>Re==null?void 0:Re.value);let Yr="";Rl==null||Rl.forEach(Re=>{Re!==""&&Re!==void 0&&(Yr=Yr===""?Re:Yr+"/"+Re)}),b.setSelectArray(Rl),b.setSelectString(Yr);let Jr=(ua=pl.safeClone(aa))==null?void 0:ua.map(Re=>(Re!=null&&Re.value&&le.IsJson(Re==null?void 0:Re.value)&&Array.isArray(JSON.parse(Re==null?void 0:Re.value))&&(Re.value=JSON.parse(Re.value)),Re)),vn={};Jr==null||Jr.forEach(Re=>{vn[Re.label]=Re==null?void 0:Re.value}),Jr=Jr==null?void 0:Jr.map(Re=>{var lr,Yl,an,Sr,Jl,Er,Xl,$l,nr;if((Re==null?void 0:Re.type)==="Select"&&((lr=Re==null?void 0:Re.allSelectionContents)==null?void 0:lr.length)>0&&(Re.contactValue=vn),(an=(Yl=Re==null?void 0:Re.optionUrl)==null?void 0:Yl.menuSelect)!=null&&an.some(Ql=>Ql==null?void 0:Ql.includes("["))){let Ql="";Re.optionUrl.oldMenuSelect=(Jl=(Sr=pl.safeClone(Re))==null?void 0:Sr.optionUrl)==null?void 0:Jl.menuSelect,Re.optionUrl.menuSelect=(Xl=(Er=Re==null?void 0:Re.optionUrl)==null?void 0:Er.menuSelect)==null?void 0:Xl.map(Ul=>{var Nl,Vr,er,Ur,Br,Tr;if(Ul!=null&&Ul.includes("[")){let gn=(Vr=(Nl=Ul==null?void 0:Ul.replaceAll("[","").replaceAll("]",""))==null?void 0:Nl.split(":"))==null?void 0:Vr[1];Ql=Qe((er=Ul==null?void 0:Ul.replaceAll("[","").replaceAll("]",""))==null?void 0:er.split(":"),Oa==null?void 0:Oa[Me.value],Oa),Ul=((Br=(Ur=pl.safeClone(Jr))==null?void 0:Ur.find(Sn=>(Sn==null?void 0:Sn.label)===gn))==null?void 0:Br.value)||Qe((Tr=Ul==null?void 0:Ul.replaceAll("[","").replaceAll("]",""))==null?void 0:Tr.split(":"),Oa==null?void 0:Oa[Me.value],Oa)}return Ul}),Ql!==""&&Re.value===""&&(Re.value=Oe(Re.optionUrl.menuSelect,Re.optionUrl.oldMenuSelect,($l=Re==null?void 0:Re.optionUrl)==null?void 0:$l.groupSelect,Oa),Array.isArray(Re.value)&&((nr=Re.value)!=null&&nr.every(Ul=>Ul==null?void 0:Ul.url))&&(Re.type="UPLOAD"))}return Re}),u.value=Jr,P.value=((wa=u.value)==null?void 0:wa.every(Re=>Re==null?void 0:Re.disabled))||fe.value===Me.value,ra.value=(Ba=u.value)==null?void 0:Ba.every(Re=>Re==null?void 0:Re.operable),Ge.value=(hl=u.value)==null?void 0:hl.map(Re=>Re==null?void 0:Re.label);let en=[],Ar=[];if((Fe=pl.safeClone(u.value))==null||Fe.forEach(Re=>{var lr;Array.isArray(Re==null?void 0:Re.value)&&((lr=Re==null?void 0:Re.value)!=null&&lr.find(Yl=>{var an;return(an=Yl==null?void 0:Yl.url)==null?void 0:an.includes(".obj")}))&&(Ar=Re==null?void 0:Re.value)}),(Ar==null?void 0:Ar.length)>0){const Re=(bl=pl.safeClone(Ar))==null?void 0:bl.filter(lr=>{var Yl;return(Yl=lr==null?void 0:lr.url)==null?void 0:Yl.includes(".obj")});Re==null||Re.forEach(lr=>{var an,Sr,Jl,Er;const Yl=(an=Ar==null?void 0:Ar.filter(Xl=>{var $l;return(Xl==null?void 0:Xl.name)===(lr==null?void 0:lr.name)&&(($l=Xl==null?void 0:Xl.url)==null?void 0:$l.includes(".mtl"))}))==null?void 0:an.map(Xl=>Xl==null?void 0:Xl.url);en.push({objUrl:lr==null?void 0:lr.url,mtlUrls:((Sr=Ar==null?void 0:Ar.filter(Xl=>{var $l;return(Xl==null?void 0:Xl.name)===(lr==null?void 0:lr.name)&&(($l=Xl==null?void 0:Xl.url)==null?void 0:$l.includes(".mtl"))}))==null?void 0:Sr.length)===1?(Er=(Jl=Ar==null?void 0:Ar.filter(Xl=>{var $l;return(Xl==null?void 0:Xl.name)===(lr==null?void 0:lr.name)&&(($l=Xl==null?void 0:Xl.url)==null?void 0:$l.includes(".mtl"))}))==null?void 0:Jl[0])==null?void 0:Er.url:Yl})}),S.setObjUrl(en)}(tr=pl.safeClone(u.value))==null||tr.forEach(Re=>{var lr,Yl,an,Sr,Jl,Er,Xl,$l,nr,Ql,Ul,Nl,Vr;if((Yl=(lr=Re==null?void 0:Re.value)==null?void 0:lr.toString())!=null&&Yl.includes(".stl")||(Sr=(an=Re==null?void 0:Re.value)==null?void 0:an.toString())!=null&&Sr.includes(".STL")||(Er=(Jl=Re==null?void 0:Re.value)==null?void 0:Jl.toString())!=null&&Er.includes(".obj")||($l=(Xl=Re==null?void 0:Re.value)==null?void 0:Xl.toString())!=null&&$l.includes(".mtl")||(Ql=(nr=Re==null?void 0:Re.value)==null?void 0:nr.toString())!=null&&Ql.includes(".urdf")){let er={},Ur=[],Br;Array.isArray(Re==null?void 0:Re.value)?Br=Re==null?void 0:Re.value:Br=(Ul=Re==null?void 0:Re.value)==null?void 0:Ul.split(","),Br==null||Br.forEach(Tr=>{Tr.includes(".mtl")?Ur.push(Tr):er.blob=er.blob==="undefined"?Tr:er.blob+","+Tr}),(Ur==null?void 0:Ur.length)>0&&(er.mtlBlobs=Ur),(Vr=(Nl=Object.values(er))==null?void 0:Nl[0])!=null&&Vr.includes("http:")}})}else u.value=[];let gl=te.value;if((gl==null?void 0:gl.length)>0&&(gl=gl==null?void 0:gl.map(Oa=>{var Rl,Yr,Jr,vn;let aa=(Rl=Oa==null?void 0:Oa.key)==null?void 0:Rl.split("/");return(n==null?void 0:n.compName)===(aa==null?void 0:aa[0])&&(Yr=u.value)!=null&&Yr.find(en=>(en==null?void 0:en.prop)===(aa==null?void 0:aa[1]))&&(Oa.value=(vn=(Jr=u.value)==null?void 0:Jr.find(en=>(en==null?void 0:en.prop)===(aa==null?void 0:aa[1])))==null?void 0:vn.value),Oa}),ze.setTableViewContents(gl)),n!=null&&n.formRules)D.value=n==null?void 0:n.formRules;else{let Oa={};(xr=pl.safeClone(u).value)==null||xr.forEach(aa=>{((aa==null?void 0:aa.isMain)===!0||(aa==null?void 0:aa.required)===!0)&&(Oa[(aa==null?void 0:aa.prop)??(aa==null?void 0:aa.name)]=[{required:!0,message:`${(aa==null?void 0:aa.label)||(aa==null?void 0:aa.prop)||(aa==null?void 0:aa.name)}不能为空`}])}),D.value=Oa}if(((Ra=na==null?void 0:na.contents)==null?void 0:Ra.length)>0){const Oa=[];(kl=na==null?void 0:na.contents)==null||kl.forEach((aa,Rl)=>{(aa==null?void 0:aa.label)!==""&&Oa.push({label:(aa==null?void 0:aa.label)??"",id:(aa==null?void 0:aa.id)??Rl,type:(aa==null?void 0:aa.type)??"",background:aa==null?void 0:aa.background})}),O.value=Oa}else O.value=[];(Ml=u.value)!=null&&Ml.some(Oa=>(Oa==null?void 0:Oa.functionName)&&(Oa==null?void 0:Oa.functionName)!=="")&&(u.value=await $e(u.value))},{deep:!0,immediate:!0}),e.watch(()=>fe.value,ne=>{P.value=ne===Me.value},{immediate:!0}),(ne,We)=>{var Ee;const na=e.resolveComponent("svg-icon"),va=e.resolveComponent("el-switch"),Ae=e.resolveComponent("el-checkbox"),Be=e.resolveComponent("el-popover"),Ye=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",Ih,[I.value===e.unref(vi).TEXT?(e.openBlock(),e.createBlock(Jc,{key:0,itemData:a.itemData,compName:a.compName,calculator:a.calculator,fields:u.value,textSize:R.value,textColor:re.value,backGround:me.value,textBackColor:X.value,backGroundImage:ue.value,disabled:P.value||Xe(),iconUrl:p.value,"onUpdate:backGroundImage":fa,backgroundUrl:o.value,backgroundPosition:c.value},null,8,["itemData","compName","calculator","fields","textSize","textColor","backGround","textBackColor","backGroundImage","disabled","iconUrl","backgroundUrl","backgroundPosition"])):I.value===e.unref(vi).BLOCK?(e.openBlock(),e.createBlock(u0,{key:1,items:(Ee=u.value)==null?void 0:Ee.map(ye=>({label:ye!=null&&ye.isHideInForm?"":ye==null?void 0:ye.label,value:ye==null?void 0:ye.value,width:(ye==null?void 0:ye.width)??1,field:ye,filters:ye==null?void 0:ye.filters})),textSize:R.value,textColor:re.value,backGround:me.value,iconUrl:p.value,textBackColor:X.value,backGroundImage:ue.value,disabled:P.value||Xe(),calculator:a.calculator,"onUpdate:backGroundImage":fa,backgroundUrl:o.value,backgroundPosition:c.value},null,8,["items","textSize","textColor","backGround","iconUrl","textBackColor","backGroundImage","disabled","calculator","backgroundUrl","backgroundPosition"])):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass({"form-shadow-box":I.value===e.unref(vi).ORDINARY})},[e.createVNode(pl.ssForm,{rowContents:u.value,formRules:D.value,buttonValue:O.value,isRowFlex:!1,isEnableWrap:!0,textSize:R.value,textColor:re.value,backGround:me.value,backGroundImage:ue.value,onOnButtonClick:Pe,onChange:ma,formDisabled:P.value||Xe(),formLabelsOperable:ra.value,isButtonRow:w.value,onPreview:ja,onBlurChange:Ta,style:e.normalizeStyle({backGroundImage:o.value!==""?`url("${o.value}")`:void 0}),onHandleColEditChange:Ca,onHandleColTypeChange:Ce,onRouteUrl:ia,onClickTrigger:pa,"onUpdate:backGroundImage":fa},{operateCol:e.withCtx(({renderColumns:ye,formDisabled:$a,formLabelsOperable:wl})=>[e.createVNode(Be,{title:"选择操作的标签",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:ce},{reference:e.withCtx(()=>[e.createElementVNode("span",Oh,[e.createVNode(na,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"}})])]),default:e.withCtx(()=>[e.createElementVNode("div",Lh,[We[1]||(We[1]=e.createElementVNode("div",{class:"group-title"},"表单操作",-1)),e.createVNode(va,{"model-value":$a,"active-text":"禁用","inactive-text":"",onChange:V,style:{"margin-right":"8px"}},null,8,["model-value"]),e.createVNode(va,{"model-value":wl,"active-text":"编辑所有标签","inactive-text":"",onChange:ee},null,8,["model-value"]),We[2]||(We[2]=e.createElementVNode("div",{class:"group-title"},"表单列操作",-1)),e.createVNode(Ye,{modelValue:Ge.value,"onUpdate:modelValue":We[0]||(We[0]=Qa=>Ge.value=Qa),style:{height:"100%"},ref_key:"checkboxGroupRef",ref:qe,onChange:he},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ye,Qa=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:Qa.label},[e.createVNode(Ae,{value:Qa.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(Qa.label),1)]),_:2},1032,["value"]),e.createVNode(Be,{title:"标签操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(na,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Pl;return[e.createElementVNode("div",Rh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Pl=Object.keys(Qa))==null?void 0:Pl.filter(gl=>{var jl;return(jl=$.value)==null?void 0:jl.find(al=>(al==null?void 0:al.value)===gl)}),gl=>{var jl,al;return e.openBlock(),e.createElementBlock("div",{key:gl},[e.createVNode(pl._sfc_main$1,{value:Qa==null?void 0:Qa[gl],"active-text":(al=(jl=$.value)==null?void 0:jl.find(Hl=>(Hl==null?void 0:Hl.value)===gl))==null?void 0:al.label,inactiveText:"",onChange:Hl=>Fa(Hl,gl,Qa)},null,8,["value","active-text","onChange"])])}),128))])]}),_:2},1024),e.createElementVNode("span",$h,[e.createVNode(na,{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)),q.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:3,fileDataList:E.value,onDestroy:sa},null,8,["fileDataList"])):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createBlock($r.ssDialog,{key:4,visible:m.value,onBeforeDestroy:r,style:{height:"700px",width:"1000px"}},{default:e.withCtx(()=>[e.createVNode(Do.ThreeViewerHost,{files:y.value,onGetAnimationData:ne.onAnimationData},null,8,["files","onGetAnimationData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0)])}}},Rs=pr._export_sfc(Vh,[["__scopeId","data-v-6e8f9fb6"]]),Fh={class:"table-header-child"},Ph={class:"table-header-child-main"},jh={class:"table-header-child-content"},Hh={class:"table-header-child-content-item"},Uh={class:"fix-button"},qh={key:0},Wh={class:"form-content"},Gh={__name:"tableNewChild",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(!1),o=e.ref(""),p=le.useTableComp(M.pinia),{tableIndex:c}=M.storeToRefs(p);e.ref(0);const u=e.ref(""),m=e.ref([]),g=e.ref([]),y=E=>{var x;i.value=!0;let _=[];_r==null||_r.forEach(b=>{let S=M.cloneDeep(c.value)+1;p.setTableIndex(S),_.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&&((x=E==null?void 0:E.children)==null?void 0:x.length)>0&&_.push({children:E==null?void 0:E.children,isFormColHidden:!0}),u.value=E==null?void 0:E.id,m.value=_,g.value=_},d=E=>{n("fixChange",M.cloneDeep(E))},D=E=>{n("deleteChange",M.cloneDeep(E))},w=E=>{i.value=!0;let _=[];_r==null||_r.forEach(x=>{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),_.push({label:x==null?void 0:x.label,name:x==null?void 0:x.label,type:x.type,value:"",id:c.value,contents:x==null?void 0:x.options})}),o.value=E==null?void 0:E.id,m.value=_,g.value=_},q=E=>{let _=M.cloneDeep(g.value);_=_==null?void 0:_.map(x=>(x.children||(x.value=E==null?void 0:E[x.name]),x)),g.value=_},A=()=>{var _,x;m.value=g.value;let E={};if(u.value!=="")E.id=u.value,(_=m.value)==null||_.forEach(b=>{const S=_r==null?void 0:_r.find(I=>(I==null?void 0:I.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,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"fix"});else{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),E.id="id"+c.value,(x=m.value)==null||x.forEach(S=>{const I=_r==null?void 0:_r.find(R=>(R==null?void 0:R.label)===(S==null?void 0:S.label));I?E[I.key]=S.value:S!=null&&S.children&&S.children.length>0&&(E.children=S.children)}),i.value=!1,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"add"})}u.value="",m.value=[],g.value=[]},j=()=>{i.value=!1,u.value="",o.value="",m.value=[],g.value=[]},O=E=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{n("deleteChange",E),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(E,_)=>{const x=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",Fh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r==null?void 0:r.tableChildContents,(b,S)=>(e.openBlock(),e.createElementBlock("div",Ph,[e.createElementVNode("div",jh,[e.createElementVNode("div",Hh,e.toDisplayString(b.label),1),e.createElementVNode("div",Uh,[e.createVNode(x,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:I=>w(b)},null,8,["onClick"]),e.createVNode(x,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:I=>y(b)},null,8,["onClick"]),e.createVNode(x,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:I=>O(b)},null,8,["onClick"])])]),b!=null&&b.children&&b.children.length>0?(e.openBlock(),e.createElementBlock("div",qh,[e.createVNode(Xc,{tableChildContents:b==null?void 0:b.children,onDeleteChange:D,onFixChange:d},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode($r.ssDialog,{visible:i.value,onBeforeDestroy:j,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Wh,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:q},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:A},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},Kh=pr._export_sfc(Gh,[["__scopeId","data-v-e0fef72d"]]),Yh={class:"table-header-child"},Jh={class:"table-header-child-main"},Xh={class:"table-header-child-content"},Zh={class:"table-header-child-content-item"},Qh={class:"fix-button"},e6={key:0},a6={class:"form-content"},l6={class:"dialog-footer"},r6={__name:"tableChildren",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(!1),o=e.ref(""),p=le.useTableComp(M.pinia),{tableIndex:c}=M.storeToRefs(p),u=e.ref(""),m=e.ref([]),g=e.ref([]),y=E=>{n("fixChange",M.cloneDeep(E))},d=E=>{var x;i.value=!0;let _=[];_r==null||_r.forEach(b=>{let S=M.cloneDeep(c.value)+1;p.setTableIndex(S),_.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&&((x=E==null?void 0:E.children)==null?void 0:x.length)>0&&_.push({children:E==null?void 0:E.children,isFormColHidden:!0}),u.value=E==null?void 0:E.id,m.value=_,g.value=_},D=E=>{i.value=!0;let _=[];_r==null||_r.forEach(x=>{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),_.push({label:x==null?void 0:x.label,name:x==null?void 0:x.label,type:x.type,value:"",id:c.value,contents:x==null?void 0:x.options})}),o.value=E==null?void 0:E.id,m.value=_,g.value=_},w=E=>{let _=M.cloneDeep(g.value);_=_==null?void 0:_.map(x=>(x.children||(x.value=E==null?void 0:E[x.name]),x)),g.value=_},q=()=>{var _,x;m.value=g.value;let E={};if(u.value!=="")E.id=u.value,(_=m.value)==null||_.forEach(b=>{const S=_r==null?void 0:_r.find(I=>(I==null?void 0:I.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,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"fix"});else{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),E.id="idChild"+c.value,(x=m.value)==null||x.forEach(S=>{const I=_r==null?void 0:_r.find(R=>(R==null?void 0:R.label)===(S==null?void 0:S.label));I?E[I.key]=S.value:S!=null&&S.children&&S.children.length>0&&(E.children=S.children)}),i.value=!1,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"add"})}u.value="",m.value=[],g.value=[]},A=()=>{i.value=!1,u.value="",o.value="",m.value=[],g.value=[]},j=E=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{n("deleteChange",E),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},O=E=>{n("deleteChange",E)};return(E,_)=>{const x=e.resolveComponent("svg-icon"),b=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",Yh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r==null?void 0:r.tableChildContents,(S,I)=>(e.openBlock(),e.createElementBlock("div",Jh,[e.createElementVNode("div",Xh,[e.createElementVNode("div",Zh,e.toDisplayString(S.label),1),e.createElementVNode("div",Qh,[e.createVNode(x,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:R=>D(S)},null,8,["onClick"]),e.createVNode(x,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:R=>d(S)},null,8,["onClick"]),e.createVNode(x,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:R=>j(S)},null,8,["onClick"])])]),S!=null&&S.children&&S.children.length>0?(e.openBlock(),e.createElementBlock("div",e6,[e.createVNode(Kh,{tableChildContents:S==null?void 0:S.children,onDeleteChange:O,onFixChange:y},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode($r.ssDialog,{visible:i.value,onBeforeDestroy:A,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",a6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:w},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",l6,[e.createVNode(b,{onClick:A,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>_[0]||(_[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(b,{class:"ok-button button",onClick:q,id:"themeButton"},{default:e.withCtx(()=>_[1]||(_[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},Xc=pr._export_sfc(r6,[["__scopeId","data-v-ebd68fa1"]]),n6={class:"table-operate-content"},i6={class:"table-operate-item"},o6={class:"operate-title"},t6={class:"operate-content"},s6={class:"fix-content"},c6={class:"fix-content-label"},u6={class:"fix-button"},d6={key:0},p6={class:"operate-title"},f6={class:"operate-content"},h6={class:"fix-content"},v6={class:"fix-content-label"},m6={class:"fix-button"},y6={class:"operate-title"},g6={class:"operate-content"},b6={class:"fix-content"},k6={class:"fix-content-label"},x6={class:"fix-button"},w6={class:"operate-title"},_6={class:"operate-content"},S6={class:"fix-content"},E6={class:"fix-content-label"},C6={class:"fix-button"},D6={class:"operate-content"},T6={style:{display:"flex","justify-content":"space-between"}},B6={class:"form-content"},N6={class:"dialog-footer"},A6={class:"form-content"},z6={class:"dialog-footer"},M6={class:"form-content"},I6={class:"dialog-footer"},O6={class:"form-content"},L6={class:"dialog-footer"},R6={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref([]),o=e.ref(!1),p=e.ref(!1),c=e.ref([]),u=e.ref(!1),m=e.ref([]),g=e.ref(!1),y=e.ref([]),d=e.ref(""),D=e.ref(""),w=e.ref([]),q=e.ref([]),A=e.ref([]),j=e.ref([]),O=e.ref(!1),E=e.ref([]),_=e.ref([]),x=e.ref(0),b=e.ref([]),S=e.ref([]),I=e.ref([]),R=()=>{O.value=!0;let $=[];Jn==null||Jn.forEach(V=>{x.value++,$.push({label:V==null?void 0:V.label,name:V==null?void 0:V.label,type:V.type,value:(V==null?void 0:V.key)==="background"?"var(--ssComponent-primary-color)":"",id:x.value,contents:V==null?void 0:V.options})}),E.value=$,_.value=$},re=()=>{var V,ee,ce;p.value=!0;let $=[];(ce=(ee=(V=le.FormContent)==null?void 0:V.find(he=>(he==null?void 0:he.key)==="Input"))==null?void 0:ee.value)==null||ce.forEach(he=>{x.value++,$.push({label:he==null?void 0:he.label,name:(he==null?void 0:he.name)||(he==null?void 0:he.label),type:he.type,value:(he==null?void 0:he.label)==="类型"?"Input":"",id:x.value,contents:he==null?void 0:he.options})}),b.value=$,S.value=$},X=$=>{$||(b.value=S.value)},me=async $=>{var V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta;if(($==null?void 0:$.类型)!==((ee=(V=S.value)==null?void 0:V.find(fa=>(fa==null?void 0:fa.label)==="类型"))==null?void 0:ee.value)){let fa=[],ja=await((pa=(he=(ce=le.FormContent)==null?void 0:ce.find(sa=>(sa==null?void 0:sa.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:he.value)==null?void 0:pa.value)?await((Ce=(Ca=(ya=le.FormContent)==null?void 0:ya.find(sa=>(sa==null?void 0:sa.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:Ca.value)==null?void 0:Ce.value):(Ve=(ia=le.FormContent)==null?void 0:ia.find(sa=>(sa==null?void 0:sa.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:Ve.value;if(ja==null||ja.forEach(sa=>{x.value++,fa.push({label:sa==null?void 0:sa.label,name:(sa==null?void 0:sa.name)||(sa==null?void 0:sa.label),type:sa.type,value:sa!=null&&sa.属性名?($==null?void 0:$.prop)||($==null?void 0:$.name)||($==null?void 0:$.label):($==null?void 0:$[sa.label])??"",id:x.value,contents:sa==null?void 0:sa.options,prop:(sa==null?void 0:sa.prop)||(sa==null?void 0:sa.name)||(sa==null?void 0:sa.label)})}),$!=null&&$.菜单选项&&((Fa=$==null?void 0:$.菜单选项)==null?void 0:Fa.length)>0){const sa=await le.menuToContentType($==null?void 0:$.菜单选项);fa=fa==null?void 0:fa.map(Pe=>((Pe==null?void 0:Pe.name)==="组信息选项"&&(Pe.contents=sa),Pe))}S.value=await le.selectToBase(M.cloneDeep(fa)),b.value=await le.selectToBase(M.cloneDeep(fa))}else{let fa=M.cloneDeep(b.value);if(fa=fa==null?void 0:fa.map(ja=>(ja.value=$==null?void 0:$[ja.name],ja)),$!=null&&$.菜单选项&&((Ta=$==null?void 0:$.菜单选项)==null?void 0:Ta.length)>0){const ja=await le.menuToContentType($==null?void 0:$.菜单选项);fa=fa==null?void 0:fa.map(sa=>((sa==null?void 0:sa.name)==="组信息选项"&&(sa.contents=ja),sa))}fa=le.formToOptionsContents(fa),S.value=await le.selectToBase(M.cloneDeep(fa))}},ue=async $=>{await me($),b.value=S.value},U=($,V)=>{if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="selectRelateType"){const ee=V==null?void 0:V.optionUrl;return(ee==null?void 0:ee.selectRelateType)||V[$.key]}if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="menuSelect"){const ee=V==null?void 0:V.optionUrl;return(ee==null?void 0:ee.menuSelect)||V[$.key]}if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="groupSelect"){const ee=V==null?void 0:V.optionUrl;return(ee==null?void 0:ee.groupSelect)||V[$.key]}if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="originalContent")return(V==null?void 0:V.value)||V[$.key];if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="multiple"){const ee=V[$.key];return fc(ee)?ee:$.default}return($==null?void 0:$.label)==="类型"&&V[$.key]===""?"Input":($==null?void 0:$.key)==="isFormColHidden"&&!V[$.key]?!1:V[$.key]},W=async $=>{var ce,he,pa,ia,Ve,ya,Ca,Ce,Fa;p.value=!0;let V=[];const ee=await((pa=(he=(ce=le.FormContent)==null?void 0:ce.find(Ta=>(Ta==null?void 0:Ta.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:he.value)==null?void 0:pa.value)?await((Ce=(Ca=(ya=le.FormContent)==null?void 0:ya.find(Ta=>(Ta==null?void 0:Ta.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:Ca.value)==null?void 0:Ce.value):(Ve=(ia=le.FormContent)==null?void 0:ia.find(Ta=>(Ta==null?void 0:Ta.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:Ve.value;if(ee==null||ee.forEach(Ta=>{x.value++,V.push({label:Ta==null?void 0:Ta.label,name:(Ta==null?void 0:Ta.name)||(Ta==null?void 0:Ta.label),type:Ta.type,value:(Ta==null?void 0:Ta.label)==="属性名"?($==null?void 0:$.prop)||($==null?void 0:$.name)||($==null?void 0:$.label):U(Ta,$),id:x.value,contents:Ta==null?void 0:Ta.options})}),$!=null&&$.menuSelect&&((Fa=$==null?void 0:$.menuSelect)==null?void 0:Fa.length)>0){const Ta=await le.menuToContentType($==null?void 0:$.menuSelect);V=V==null?void 0:V.map(fa=>((fa==null?void 0:fa.name)==="组信息选项"&&(fa.contents=Ta),fa))}d.value=$==null?void 0:$.id,b.value=await le.selectToBase(le.formToOptionsContents(V)),S.value=await le.selectToBase(le.formToOptionsContents(V))},Z=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;I.value=(V=M.cloneDeep(I.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="tableToForm"&&(ce.contents=I.value),ce))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},ae=()=>{p.value=!1,b.value=[],d.value=""},ve=async()=>{var ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta;b.value=S.value;let $={};d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value);let V=await((pa=(he=(ce=le.FormContent)==null?void 0:ce.find(fa=>{var ja,sa;return(fa==null?void 0:fa.key)===(((sa=(ja=b.value)==null?void 0:ja.find(Pe=>(Pe==null?void 0:Pe.label)==="类型"))==null?void 0:sa.value)??"label")}))==null?void 0:he.value)==null?void 0:pa.value)??((Ve=(ia=le.FormContent)==null?void 0:ia.find(fa=>{var ja,sa;return(fa==null?void 0:fa.key)===(((sa=(ja=b.value)==null?void 0:ja.find(Pe=>(Pe==null?void 0:Pe.label)==="类型"))==null?void 0:sa.value)??"label")}))==null?void 0:Ve.value);if((ya=b.value)==null||ya.forEach(fa=>{const ja=V==null?void 0:V.find(sa=>(sa==null?void 0:sa.label)===(fa==null?void 0:fa.label));ja&&($[ja.key]=fa.value)}),$.name=$.label,(Ca=I.value)!=null&&Ca.find(fa=>fa.id===$.id))I.value=(Ce=I.value)==null?void 0:Ce.map(fa=>(fa.id===$.id&&(fa=$),fa));else{let fa=M.cloneDeep(I.value);I.value||(I.value=[]),fa.push($),I.value=fa}I.value=I.value.map(({id:fa,...ja})=>ja),p.value=!1,d.value="";let ee=M.cloneDeep(r.originalItemContents);(Fa=M.cloneDeep(r.originalItemContents))!=null&&Fa.find(fa=>(fa==null?void 0:fa.key)==="tableToForm")?ee=(Ta=M.cloneDeep(r.originalItemContents))==null?void 0:Ta.map(fa=>((fa==null?void 0:fa.key)==="tableToForm"&&(fa.contents=I.value),fa)):ee.push({key:"tableToForm",contents:I.value}),n("change",ee)},ze=$=>{O.value=!0;let V=[];Jn==null||Jn.forEach(ee=>{x.value++,V.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:$[ee.key],id:x.value,contents:ee==null?void 0:ee.options})}),d.value=$==null?void 0:$.id,E.value=V,_.value=V};e.watch(()=>g.value,()=>{var V,ee;let $=M.cloneDeep(r.originalItemContents);(V=M.cloneDeep(r.originalItemContents))!=null&&V.find(ce=>(ce==null?void 0:ce.key)==="page")?$=(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="page"&&(ce.contents=g.value),ce)):$.push({key:"page",contents:g.value}),n("change",$)},{deep:!0});const te=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;q.value=(V=M.cloneDeep(q.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="extraButton"&&(ce.contents=q.value),ce))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},N=()=>{var ee,ce,he,pa,ia;E.value=_.value;let $={};if(d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value),(ee=E.value)==null||ee.forEach(Ve=>{const ya=Jn==null?void 0:Jn.find(Ca=>(Ca==null?void 0:Ca.label)===(Ve==null?void 0:Ve.label));ya?$[ya.key]=Ve.value:Ve!=null&&Ve.children&&Ve.children.length>0&&($.children=Ve.children)}),(ce=q.value)!=null&&ce.find(Ve=>Ve.id===$.id))q.value=(he=q.value)==null?void 0:he.map(Ve=>(Ve.id===$.id&&(Ve=$),Ve));else{let Ve=M.cloneDeep(q.value)??[];Ve.push($),q.value=Ve}O.value=!1,d.value="";let V=M.cloneDeep(r.originalItemContents);(pa=M.cloneDeep(r.originalItemContents))!=null&&pa.find(Ve=>(Ve==null?void 0:Ve.key)==="extraButton")?V=(ia=M.cloneDeep(r.originalItemContents))==null?void 0:ia.map(Ve=>((Ve==null?void 0:Ve.key)==="extraButton"&&(Ve.contents=q.value),Ve)):V.push({key:"extraButton",contents:q.value}),n("change",V)},se=$=>{let V=M.cloneDeep(_.value);V=V==null?void 0:V.map(ee=>(ee.children||(ee.value=$==null?void 0:$[ee.name]),ee)),_.value=V},G=()=>{O.value=!1,E.value=[],d.value=""},fe=$=>{u.value=!0;let V=[];Xn==null||Xn.forEach(ee=>{x.value++,V.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:$[ee.key],id:x.value,contents:ee==null?void 0:ee.options})}),d.value=$==null?void 0:$.id,A.value=V,j.value=V},we=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;w.value=(V=M.cloneDeep(w.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="rowButton"&&(ce.contents=w.value),ce))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},_e=()=>{o.value=!0;let $=[];_r==null||_r.forEach(V=>{x.value++,$.push({label:V==null?void 0:V.label,name:V==null?void 0:V.label,type:V.type,value:"",id:x.value,contents:V==null?void 0:V.options})}),m.value=$,y.value=$},qe=()=>{u.value=!0;let $=[];Xn==null||Xn.forEach(V=>{x.value++,$.push({label:V==null?void 0:V.label,name:V==null?void 0:V.label,type:V.type,value:"",id:x.value,contents:V==null?void 0:V.options})}),A.value=$,j.value=$},ra=$=>{let V=M.cloneDeep(j.value);V=V==null?void 0:V.map(ee=>(ee.children||(ee.value=$==null?void 0:$[ee.name]),ee)),j.value=V},P=()=>{var ee,ce,he,pa,ia;A.value=j.value;let $={};if(d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value),(ee=A.value)==null||ee.forEach(Ve=>{const ya=Xn==null?void 0:Xn.find(Ca=>(Ca==null?void 0:Ca.label)===(Ve==null?void 0:Ve.label));ya?$[ya.key]=Ve.value:Ve!=null&&Ve.children&&Ve.children.length>0&&($.children=Ve.children)}),(ce=w.value)!=null&&ce.find(Ve=>Ve.id===$.id))w.value=(he=w.value)==null?void 0:he.map(Ve=>(Ve.id===$.id&&(Ve=$),Ve));else{let Ve=M.cloneDeep(w.value);Ve.push($),w.value=Ve}u.value=!1,d.value="";let V=M.cloneDeep(r.originalItemContents);(pa=M.cloneDeep(r.originalItemContents))!=null&&pa.find(Ve=>(Ve==null?void 0:Ve.key)==="rowButton")?V=(ia=M.cloneDeep(r.originalItemContents))==null?void 0:ia.map(Ve=>((Ve==null?void 0:Ve.key)==="rowButton"&&(Ve.contents=w.value),Ve)):V.push({key:"rowButton",contents:w.value}),n("change",V)},Ke=()=>{u.value=!1,d.value="",j.value=[],A.value=[]},Me=$=>{o.value=!0;let V=[];_r==null||_r.forEach(ee=>{x.value++,V.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:"",id:x.value,contents:ee==null?void 0:ee.options})}),m.value=V,D.value=$==null?void 0:$.id,y.value=V},Le=$=>{var V;c.value=qc(M.cloneDeep(c.value),$==null?void 0:$.id),n("change",(V=M.cloneDeep(r.originalItemContents))==null?void 0:V.map(ee=>{var ce;return(ee==null?void 0:ee.key)==="header"&&(ee.contents=(ce=c.value)!=null&&ce.some(he=>he==null?void 0:he.children)?[c.value]:c.value),ee}))},Ie=$=>{var ee,ce,he;$.type==="fix"?$.id!==""?c.value=Gc(c.value,$):c.value=Wc(c.value,$==null?void 0:$.contents):c.value=Kc(c.value,$),c.value=(ee=c.value)!=null&&ee.some(pa=>pa==null?void 0:pa.children)?[c.value]:c.value,d.value="";let V=M.cloneDeep(r.originalItemContents);(ce=M.cloneDeep(r.originalItemContents))!=null&&ce.find(pa=>(pa==null?void 0:pa.key)==="header")?V=(he=M.cloneDeep(r.originalItemContents))==null?void 0:he.map(pa=>((pa==null?void 0:pa.key)==="header"&&(pa.contents=c.value),pa)):V.push({key:"header",contents:c.value}),n("change",V)},de=$=>{var ee;o.value=!0;let V=[];_r==null||_r.forEach(ce=>{x.value++,V.push({label:ce==null?void 0:ce.label,name:ce==null?void 0:ce.label,type:ce.type,value:$[ce.key],id:x.value,contents:ce==null?void 0:ce.options})}),$!=null&&$.children&&((ee=$==null?void 0:$.children)==null?void 0:ee.length)>0&&V.push({children:$==null?void 0:$.children,isFormColHidden:!0}),d.value=$==null?void 0:$.id,D.value="",m.value=V,y.value=V},De=$=>{let V=M.cloneDeep(y.value);V=V==null?void 0:V.map(ee=>(ee.children||(ee.value=$==null?void 0:$[ee.name]),ee)),y.value=V},Xe=()=>{o.value=!1,d.value="",D.value="",y.value=[]},Ea=()=>{var ee,ce,he,pa,ia,Ve;m.value=y.value;let $={};if(d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value),(ee=m.value)==null||ee.forEach(ya=>{const Ca=_r==null?void 0:_r.find(Ce=>(Ce==null?void 0:Ce.label)===(ya==null?void 0:ya.label));Ca?$[Ca.key]=ya.value:ya!=null&&ya.children&&ya.children.length>0&&($.children=ya.children)}),(ce=c.value)!=null&&ce.find(ya=>ya.id===$.id))c.value=(he=c.value)==null?void 0:he.map(ya=>(ya.id===$.id&&(ya=$),ya));else{let ya=M.cloneDeep(c.value)??[];D.value===""?ya.push($):ya=ya==null?void 0:ya.map(Ca=>(Ca.id===D.value&&(Ca.children||(Ca.children=[]),Ca.children.push($)),Ca)),c.value=ya}c.value=(pa=c.value)!=null&&pa.some(ya=>ya==null?void 0:ya.children)?[c.value]:c.value,o.value=!1,d.value="",D.value="";let V=M.cloneDeep(r.originalItemContents);(ia=M.cloneDeep(r.originalItemContents))!=null&&ia.find(ya=>(ya==null?void 0:ya.key)==="header")?V=(Ve=M.cloneDeep(r.originalItemContents))==null?void 0:Ve.map(ya=>((ya==null?void 0:ya.key)==="header"&&(ya.contents=c.value),ya)):V.push({key:"header",contents:c.value}),n("change",V)},Ge=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;c.value=(V=M.cloneDeep(c.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>{var he;return(ce==null?void 0:ce.key)==="header"&&(ce.contents=(he=c.value)!=null&&he.some(pa=>pa==null?void 0:pa.children)?[c.value]:c.value),ce})),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return e.watch(()=>r.originalItemContents,()=>{var $,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe;if(!(!r.originalItemContents||r.originalItemContents.length===0))if(i.value=M.cloneDeep(r.originalItemContents),c.value=(V=($=i.value)==null?void 0:$.find(Oe=>(Oe==null?void 0:Oe.key)==="header"))==null?void 0:V.contents,w.value=(ce=(ee=i.value)==null?void 0:ee.find(Oe=>(Oe==null?void 0:Oe.key)==="rowButton"))==null?void 0:ce.contents,q.value=(pa=(he=i.value)==null?void 0:he.find(Oe=>(Oe==null?void 0:Oe.key)==="extraButton"))==null?void 0:pa.contents,g.value=(Ve=(ia=i.value)==null?void 0:ia.find(Oe=>(Oe==null?void 0:Oe.key)==="page"))!=null&&Ve.contents?!!((Ca=(ya=i.value)==null?void 0:ya.find(Oe=>(Oe==null?void 0:Oe.key)==="page"))!=null&&Ca.contents):!1,I.value=(Fa=(Ce=i.value)==null?void 0:Ce.find(Oe=>(Oe==null?void 0:Oe.key)==="tableToForm"))==null?void 0:Fa.contents,c.value=(Ta=c.value)==null?void 0:Ta.map((Oe,$e)=>(Array.isArray(Oe)?Oe=T3(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)??$e,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))?(ja=c.value)==null?void 0:ja[0]:c.value,w.value=(sa=w.value)==null?void 0:sa.map((Oe,$e)=>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)??$e}),q.value=(Pe=q.value)==null?void 0:Pe.map((Oe,$e)=>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)??$e}),I.value)I.value=(Qe=I.value)==null?void 0:Qe.map(Oe=>{x.value++;let $e=Oe;return $e.id=x.value,$e});else{let Oe=[];const $e=(ma=le.getColumnChild(M.cloneDeep(c.value)))==null?void 0:ma.filter(ne=>(ne==null?void 0:ne.prop)!=="operate");$e==null||$e.forEach(ne=>{var We;x.value++,Oe.push({label:ne==null?void 0:ne.label,name:(ne==null?void 0:ne.prop)||(ne==null?void 0:ne.label),type:ne!=null&&ne.groupSelect?"Select":"Input",value:"",id:x.value,contents:ne==null?void 0:ne.options,menuSelect:ne==null?void 0:ne.formMenuSelect,groupSelect:(We=ne==null?void 0:ne.groupSelect)==null?void 0:We.split(":"),selectRelateType:"关联绑定列"})}),I.value=Oe}},{deep:!0,immediate:!0}),($,V)=>{const ee=e.resolveComponent("svg-icon"),ce=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",n6,[e.createElementVNode("div",i6,[e.createElementVNode("div",o6,[V[2]||(V[2]=e.createElementVNode("div",null,e.toDisplayString("表头"),-1)),e.createVNode(ce,{class:"icon-content",onClick:_e,id:"themeButton"},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[1]||(V[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",t6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",s6,[e.createElementVNode("div",c6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",u6,[e.createVNode(ee,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>Me(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>de(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>Ge(he)},null,8,["onClick"])])]),he!=null&&he.children&&he.children.length>0?(e.openBlock(),e.createElementBlock("div",d6,[e.createVNode(Xc,{tableChildContents:he==null?void 0:he.children,onDeleteChange:Le,onFixChange:Ie},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),128))]),e.createElementVNode("div",p6,[V[4]||(V[4]=e.createElementVNode("div",null,e.toDisplayString("行内按钮"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:qe},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[3]||(V[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",f6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",h6,[e.createElementVNode("div",v6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",m6,[e.createVNode(ee,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ia=>fe(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>we(he)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",y6,[V[6]||(V[6]=e.createElementVNode("div",null,e.toDisplayString("表外按钮"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:R},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[5]||(V[5]=e.createTextVNode(" 新增 "))]),_:1,__:[5]})]),e.createElementVNode("div",g6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(q.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",b6,[e.createElementVNode("div",k6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",x6,[e.createVNode(ee,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ia=>ze(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>te(he)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",w6,[V[8]||(V[8]=e.createElementVNode("div",null,e.toDisplayString("表格弹框字段设置"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:re},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[7]||(V[7]=e.createTextVNode(" 新增 "))]),_:1,__:[7]})]),e.createElementVNode("div",_6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(I.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",S6,[e.createElementVNode("div",E6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",C6,[e.createVNode(ee,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ia=>W(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>Z(he)},null,8,["onClick"])])])]))),128))]),V[10]||(V[10]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("分页"))],-1)),e.createElementVNode("div",D6,[e.createElementVNode("div",T6,[V[9]||(V[9]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否分页"),-1)),e.createVNode(pl._sfc_main$1,{modelValue:g.value,"onUpdate:modelValue":V[0]||(V[0]=he=>g.value=he)},null,8,["modelValue"])])])]),e.createVNode($r.ssDialog,{visible:o.value,onBeforeDestroy:Xe,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",B6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:De},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",N6,[e.createVNode(ce,{onClick:Xe,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[11]||(V[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(ce,{class:"ok-button button",onClick:Ea,id:"themeButton"},{default:e.withCtx(()=>V[12]||(V[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:u.value,onBeforeDestroy:Ke,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",A6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:A.value,key:A.value,isEnableWrap:!0,onChange:ra},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",z6,[e.createVNode(ce,{onClick:Ke,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[13]||(V[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(ce,{class:"ok-button button",onClick:P,id:"themeButton"},{default:e.withCtx(()=>V[14]||(V[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:O.value,onBeforeDestroy:G,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",M6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:se},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",I6,[e.createVNode(ce,{onClick:G,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[15]||(V[15]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[15]}),e.createVNode(ce,{class:"ok-button button",onClick:N,id:"themeButton"},{default:e.withCtx(()=>V[16]||(V[16]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[16]})])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:p.value,onBeforeDestroy:ae,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",O6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:me,onChangeVisible:X,onBlurChange:ue},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",L6,[e.createVNode(ce,{onClick:ae,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[17]||(V[17]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[17]}),e.createVNode(ce,{class:"ok-button button",onClick:ve,id:"themeButton"},{default:e.withCtx(()=>V[18]||(V[18]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[18]})])]),_:1},8,["visible"])])}}},$6=pr._export_sfc(R6,[["__scopeId","data-v-7a6b87b5"]]),V6=M.useModelComp(M.pinia),{pageMapState:Zc}=M.storeToRefs(V6),F6=M.useMenuState(M.pinia),{activeMenuPath:Qc,systemHeight:eu}=M.storeToRefs(F6),P6=e.ref(24),j6=e.ref(6),au=e.ref(10),H6=e.ref(70),U6=e.ref(.18),q6=e.ref(45),W6=()=>{au.value=(eu.value-100)/100};e.watch(()=>eu.value,()=>{W6()},{deep:!0,immediate:!0});const G6=(a,l,r,n)=>{var i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E;return{x:((o=(i=a==null?void 0:a.value)==null?void 0:i.tableData)==null?void 0:o.x)||l%2*12,y:((c=(p=a==null?void 0:a.value)==null?void 0:p.tableData)==null?void 0:c.y)||l,w:((m=(u=a==null?void 0:a.value)==null?void 0:u.tableData)==null?void 0:m.w)||P6.value,h:((y=(g=a==null?void 0:a.value)==null?void 0:g.tableData)==null?void 0:y.h)||r,minW:((D=(d=a==null?void 0:a.value)==null?void 0:d.tableData)==null?void 0:D.minW)||j6.value,minH:((q=(w=a==null?void 0:a.value)==null?void 0:w.tableData)==null?void 0:q.minH)||U6.value,maxH:((j=(A=a==null?void 0:a.value)==null?void 0:A.tableData)==null?void 0:j.maxH)||q6.value,i:((E=(O=a==null?void 0:a.value)==null?void 0:O.tableData)==null?void 0:E.i)||l,id:(a==null?void 0:a.id)||l+"",component:n}},K6=(a,l)=>{var n,i,o,p,c,u,m,g;let r=1;if(a!=null&&a.compData&&Array.isArray(a==null?void 0:a.compData))if(((n=a==null?void 0:a.comp)==null?void 0:n.toUpperCase())==="TABLE"){if(((p=(o=(i=a==null?void 0:a.compData)==null?void 0:i.find(d=>(d==null?void 0:d.key)==="tableContents"))==null?void 0:o.contents)==null?void 0:p.length)===0)return 2}else((c=a==null?void 0:a.comp)==null?void 0:c.toUpperCase())==="FORM"&&(r=((g=(m=(u=a==null?void 0:a.compData)==null?void 0:u.find(d=>(d==null?void 0:d.key)==="formContent"))==null?void 0:m.contents)==null?void 0:g.length)/5);return r*2},lu=(a,l,r)=>{var p,c;const n=(c=(p=Zc.value)==null?void 0:p[Qc.value])==null?void 0:c.filter(u=>{var m;return((m=u==null?void 0:u.key)==null?void 0:m.type)==="gridLayout"}),i=n==null?void 0:n.find(u=>{var m,g,y;return((y=(g=(m=u==null?void 0:u.value)==null?void 0:m.tableData)==null?void 0:g.component)==null?void 0:y.id)===a.id}),o=K6(a);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((u,m)=>lu(u,m))),{...G6(i,l,o,a)}},Y6=(a,l)=>{if((a==null?void 0:a.length)===0)return[];const r=M.cloneDeep(a);return Array.isArray(a)?r==null?void 0:r.map((n,i)=>lu(n,i)):[]},J6=(a,l,r,n)=>{var i,o;return{x:r==null?void 0:r.x,y:0,w:Math.round(r==null?void 0:r.w),h:r==null?void 0:r.h,arrowGap:r==null?void 0:r.arrowGap,i:((o=(i=a==null?void 0:a.value)==null?void 0:i.tableData)==null?void 0:o.i)||l,id:(a==null?void 0:a.id)||l+"",component:n}},X6=(a,l)=>{var m,g,y,d;let r=0,n=0,i=0,o=0,p=0,c=((g=(m=a==null?void 0:a.compData)==null?void 0:m.find(D=>(D==null?void 0:D.key)==="numPosition"))==null?void 0:g.contents)??[],u=((d=(y=a==null?void 0:a.compData)==null?void 0:y.find(D=>(D==null?void 0:D.key)==="rowPosition"))==null?void 0:d.contents)??"";return u&&u!==1&&(p=Math.ceil(u*l)),i=(c==null?void 0:c[0])*l,o=(c==null?void 0:c[1])*100,{x:r,y:n,w:i,h:o,arrowGap:p}},ru=(a,l,r)=>{var p,c;const n=(c=(p=Zc.value)==null?void 0:p[Qc.value])==null?void 0:c.filter(u=>{var m;return((m=u==null?void 0:u.key)==null?void 0:m.type)==="gridLayout"}),i=n==null?void 0:n.find(u=>{var m,g,y;return((y=(g=(m=u==null?void 0:u.value)==null?void 0:m.tableData)==null?void 0:g.component)==null?void 0:y.id)===a.id}),o=X6(a,r);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((u,m)=>ru(u,m,r))),{...J6(i,l,o,a)}},Z6=(a,l)=>{if((a==null?void 0:a.length)===0)return[];const r=M.cloneDeep(a);return Array.isArray(a)?r==null?void 0:r.map((n,i)=>ru(n,i,l)):[]},Q6=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}]}]}}),e4=(a,l)=>a==null?void 0:a.map(r=>{for(const n in l)if(n===(r==null?void 0:r.prop))return{...r,value:l[n]};return r}),a4=e.defineComponent({__name:"index",props:{compType:String,comp:Object,target:{type:String,default:"alone"},optionItems:Array},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref([]);e.watch(()=>r.compType,c=>{var g;const u=Q6(r==null?void 0:r.optionItems),m=c?(g=u[c==null?void 0:c.toUpperCase()])==null?void 0:g[r==null?void 0:r.target]:[];i.value=m==null?void 0:m.map(y=>{for(const[d,D]of Object.entries((r==null?void 0:r.comp)||{}))if((y==null?void 0:y.prop)===d)return{...y,value:D};return y})},{immediate:!0});const o=c=>pl.getComponent(c),p=c=>{var u,m;(c==null?void 0:c.prop)==="layout"&&(c==null?void 0:c.value)==="horizontal"?i.value=(u=i.value)==null?void 0:u.map(g=>{var y;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(y=g==null?void 0:g.options)==null?void 0:y.map(d=>({...d,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 y;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(y=g==null?void 0:g.options)==null?void 0:y.map(d=>({...d,disabled:!1}))}:(g==null?void 0:g.prop)==="isGridLayout"?{...g,disabled:!1}:g}),n("change",{target:r==null?void 0:r.target,styleConfigs:i.value,prop:c==null?void 0:c.prop})};return(c,u)=>{const m=e.resolveComponent("el-col"),g=e.resolveComponent("el-row");return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,y=>(e.openBlock(),e.createBlock(g,{class:"style-row",key:y==null?void 0:y.prop},{default:e.withCtx(()=>[e.createVNode(m,{span:6,class:"style-row-title"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(y==null?void 0:y.label)+":",1)]),_:2},1024),e.createVNode(m,{span:18,style:{display:"flex"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o(y.type)),{modelValue:y.value,"onUpdate:modelValue":d=>y.value=d,content:y==null?void 0:y.options,optionUrl:y==null?void 0:y.optionUrl,disabled:y==null?void 0:y.disabled,activeText:y==null?void 0:y.activeText,inactiveText:y==null?void 0:y.inactiveText,onChange:d=>p(y)},null,40,["modelValue","onUpdate:modelValue","content","optionUrl","disabled","activeText","inactiveText","onChange"]))]),_:2},1024)]),_:2},1024))),128)}}}),l4=pr._export_sfc(a4,[["__scopeId","data-v-da01b651"]]),r4=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 r=a,n=l,i=[{required:!0,message:"输入不能为空",trigger:"blur"}],o=e.ref([]),p=j=>j==null?void 0:j.reduce((O,E)=>(O[E==null?void 0:E.prop]=E==null?void 0:E.rule,O),{}),c=e.computed(()=>({formRules:p(o.value),buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"保存",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]})),u=e.ref([]),m=e.ref(""),g=(j,O,E)=>{var b;let _=[];(r==null?void 0:r.activeTabName)==="任务配置"?(_=[{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:O}]},{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:"暂停"}]}],o.value=[{prop:"任务名称",rule:i},{prop:"任务关键词",rule:i},{prop:"执行任务",rule:i},{prop:"执行动作",rule:i},{prop:"执行交互",rule:i}]):(r==null?void 0:r.activeTabName)==="任务关联"&&(_=[{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=r==null?void 0:r.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:"暂停"}]}],o.value=[{prop:"关联名称",rule:i},{prop:"关联状态",rule:i},{prop:"关联形式",rule:i},{prop:"关联任务集合",rule:i}]);let x;return E&&(E==null?void 0:E.length)>0?x=[..._,...y(j,O,E)]:x=_,x},y=(j,O,E)=>{const _=[{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?_==null?void 0:_.filter(x=>E==null?void 0:E.includes(x==null?void 0:x.prop)):_},d=(j,O)=>{var S,I,R,re,X,me,ue,U,W;const E=((X=(re=(R=(I=(S=r==null?void 0:r.comp)==null?void 0:S.compData)==null?void 0:I.find(Z=>(Z==null?void 0:Z.key)==="header"))==null?void 0:R.contents)==null?void 0:re.filter(Z=>(Z==null?void 0:Z.label)!=="操作"))==null?void 0:X.map(Z=>({value:Z==null?void 0:Z.prop,label:Z.label})))||[],_=/button/i,x=((W=(U=(ue=(me=r==null?void 0:r.comp)==null?void 0:me.compData)==null?void 0:ue.filter(Z=>_.test(Z==null?void 0:Z.key)))==null?void 0:U.flatMap(Z=>Z==null?void 0:Z.contents))==null?void 0:W.map(Z=>({value:Z==null?void 0:Z.label,label:Z.label})))||[],b=g(E,x,j);u.value=O?e4(b,O):b,j&&(j==null?void 0:j.length)>0&&o.value.push(...j==null?void 0:j.map(Z=>({prop:Z,rule:i})))};e.onMounted(()=>{d(null,r==null?void 0:r.extendItem)});const D=j=>{const O=j==null?void 0:j[m.value];if(m.value==="执行任务"){if(!(O!=null&&O.join("/")))return;const E=O==null?void 0:O.join("/");d(E==="统计/统计规则/自定义"?["统计算法源","统计是否获取错误集"]:E==="进度设置/进度条"?["进度关键词"]:null,j)}},w=j=>{n("change",{target:r==null?void 0:r.target,extendConfigs:j})},q=(j,O)=>{m.value=O==null?void 0:O.changeProp,D(j)},A=j=>{n("onButtonClick",j)};return(j,O)=>(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,key:u.value,isStartJustify:!1,isEnableWrap:!1,formRules:c.value.formRules,buttonValue:c.value.buttonValue,onChange:w,onBlurChange:q,onOnButtonClick:A},null,8,["rowContents","formRules","buttonValue"]))}}),n4=pr._export_sfc(r4,[["__scopeId","data-v-4b39853f"]]),i4={};function o4(a,l){return null}const t4=pr._export_sfc(i4,[["render",o4]]),s4={class:"form-operate-content"},c4={class:"form-operate-item"},u4={class:"operate-title"},d4={class:"operate-content"},p4={class:"fix-content"},f4={class:"fix-button"},h4={class:"operate-title"},v4={class:"operate-content"},m4={class:"fix-content"},y4={class:"fix-button"},g4={style:{display:"flex","justify-content":"space-between"}},b4={class:"form-content"},k4={class:"dialog-footer"},x4={class:"form-content"},w4={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(!1),o=e.ref([]),p=e.ref([]),c=e.ref(!1),u=e.ref([]),m=e.ref([]),g=e.ref(""),y=e.ref(!1),d=e.ref(0),D=e.ref([]),w=e.ref([]),q=(U,W)=>{if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="selectRelateType"){const Z=W==null?void 0:W.optionUrl;return(Z==null?void 0:Z.selectRelateType)||W[U.key]}if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="menuSelect"){const Z=W==null?void 0:W.optionUrl;return(Z==null?void 0:Z.menuSelect)||W[U.key]}if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="groupSelect"){const Z=W==null?void 0:W.optionUrl;return(Z==null?void 0:Z.groupSelect)||W[U.key]}if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="originalContent")return(W==null?void 0:W.value)||W[U.key];if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="multiple"){const Z=W[U.key];return fc(Z)?Z:U.default}return(U==null?void 0:U.label)==="类型"&&W[U.key]===""?"Input":(U==null?void 0:U.key)==="isFormColHidden"&&!W[U.key]?!1:W[U.key]},A=async U=>{var ae,ve,ze,te,N,se;i.value=!0;let W=[];const Z=await((ze=(ve=(ae=le.FormContent)==null?void 0:ae.find(G=>(G==null?void 0:G.key)===((U==null?void 0:U.type)===""?"Input":U==null?void 0:U.type)))==null?void 0:ve.value)==null?void 0:ze.value)??((N=(te=le.FormContent)==null?void 0:te.find(G=>(G==null?void 0:G.key)===((U==null?void 0:U.type)===""?"Input":U==null?void 0:U.type)))==null?void 0:N.value);if(Z==null||Z.forEach(G=>{d.value++,W.push({label:G==null?void 0:G.label,name:G==null?void 0:G.label,type:G.type,prop:G==null?void 0:G.prop,value:q(G,U),id:d.value,contents:G==null?void 0:G.options,width:(U==null?void 0:U.width)??1})}),U!=null&&U.menuSelect&&((se=U==null?void 0:U.menuSelect)==null?void 0:se.length)>0){const G=await le.menuToContentType(U==null?void 0:U.menuSelect);W=W==null?void 0:W.map(fe=>((fe==null?void 0:fe.name)==="组信息选项"&&(fe.contents=G),fe))}g.value=U==null?void 0:U.id,o.value=await le.selectToBase(le.formToOptionsContents(W)),p.value=await le.selectToBase(le.formToOptionsContents(W))},j=U=>{var Z;c.value=!0;let W=[];(Z=le.FormButton)==null||Z.forEach(ae=>{d.value++,W.push({label:ae==null?void 0:ae.label,name:ae==null?void 0:ae.label,type:ae.type,value:(ae==null?void 0:ae.label)==="类型"&&U[ae.key]===""?"normal":U[ae.key],id:d.value,contents:ae==null?void 0:ae.options})}),D.value=W,w.value=W,g.value=U==null?void 0:U.id};e.watch(()=>y.value,()=>{var W,Z;let U=M.cloneDeep(r.originalItemContents);(W=M.cloneDeep(r.originalItemContents))!=null&&W.find(ae=>(ae==null?void 0:ae.key)==="enableWrap")?U=(Z=M.cloneDeep(r.originalItemContents))==null?void 0:Z.map(ae=>((ae==null?void 0:ae.key)==="enableWrap"&&(ae.contents=!y.value),ae)):U.push({key:"enableWrap",contents:!y.value}),n("change",U)},{deep:!0});const O=()=>{var Z,ae,ve,ze,te;D.value=w.value;let U={};if(g.value!==""?U.id=g.value:(d.value++,U.id="id"+d.value),(Z=D.value)==null||Z.forEach(N=>{var G;const se=(G=le.FormButton)==null?void 0:G.find(fe=>(fe==null?void 0:fe.label)===(N==null?void 0:N.label));se&&(U[se.key]=N.value)}),(ae=u.value)!=null&&ae.find(N=>N.id===U.id))u.value=(ve=u.value)==null?void 0:ve.map(N=>(N.id===U.id&&(N=U),N));else{let N=M.cloneDeep(u.value);u.value||(u.value=[]),N.push(U),u.value=N}c.value=!1,g.value="";let W=M.cloneDeep(r.originalItemContents);(ze=M.cloneDeep(r.originalItemContents))!=null&&ze.find(N=>(N==null?void 0:N.key)==="formButton")?W=(te=M.cloneDeep(r.originalItemContents))==null?void 0:te.map(N=>((N==null?void 0:N.key)==="formButton"&&(N.contents=u.value),N)):W.push({key:"formButton",contents:u.value}),n("change",W)},E=U=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var W,Z;m.value=(W=M.cloneDeep(m.value))==null?void 0:W.filter(ae=>(ae==null?void 0:ae.id)!==(U==null?void 0:U.id)),n("change",(Z=M.cloneDeep(r.originalItemContents))==null?void 0:Z.map(ae=>((ae==null?void 0:ae.key)==="formContent"&&(ae.contents=m.value),ae))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},_=U=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var W,Z;u.value=(W=M.cloneDeep(u.value))==null?void 0:W.filter(ae=>(ae==null?void 0:ae.id)!==(U==null?void 0:U.id)),n("change",(Z=M.cloneDeep(r.originalItemContents))==null?void 0:Z.map(ae=>((ae==null?void 0:ae.key)==="formButton"&&(ae.contents=u.value),ae))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=()=>{var W;c.value=!0;let U=[];(W=le.FormButton)==null||W.forEach(Z=>{d.value++,U.push({label:Z==null?void 0:Z.label,name:Z==null?void 0:Z.label,type:Z.type,value:(Z==null?void 0:Z.label)==="类型"?"normal":"",id:d.value,contents:Z==null?void 0:Z.options})}),D.value=U,w.value=U},b=()=>{var W,Z,ae;i.value=!0;let U=[];(ae=(Z=(W=le.FormContent)==null?void 0:W.find(ve=>(ve==null?void 0:ve.key)==="Input"))==null?void 0:Z.value)==null||ae.forEach(ve=>{d.value++,U.push({label:ve==null?void 0:ve.label,name:ve==null?void 0:ve.label,type:ve.type,value:(ve==null?void 0:ve.label)==="类型"?"Input":"",id:d.value,contents:ve==null?void 0:ve.options})}),o.value=U,p.value=U},S=U=>{let W=M.cloneDeep(w.value);W=W==null?void 0:W.map(Z=>(Z.value=U==null?void 0:U[Z.name],Z)),w.value=W},I=U=>{const W=U.find(ve=>(ve==null?void 0:ve.name)==="类型");if((W==null?void 0:W.value)!="Select")return;const Z=U.find(ve=>(ve==null?void 0:ve.name)==="多选"),ae=U.find(ve=>(ve==null?void 0:ve.name)==="初始值");Z!=null&&Z.value&&To.isString(ae.value)&&(ae.value=[ae.value]),!(Z!=null&&Z.value)&&!To.isString(ae.value)&&(ae.value="")},R=async U=>{var W,Z,ae,ve,ze,te,N,se,G,fe,we,_e;if((U==null?void 0:U.类型)!==((Z=(W=p.value)==null?void 0:W.find(qe=>(qe==null?void 0:qe.label)==="类型"))==null?void 0:Z.value)){let qe=[];const ra=await((ze=(ve=(ae=le.FormContent)==null?void 0:ae.find(P=>(P==null?void 0:P.key)===((U==null?void 0:U.类型)===""?"Input":U==null?void 0:U.类型)))==null?void 0:ve.value)==null?void 0:ze.value)?await((fe=(G=(se=le.FormContent)==null?void 0:se.find(P=>(P==null?void 0:P.key)===((U==null?void 0:U.类型)===""?"Input":U==null?void 0:U.类型)))==null?void 0:G.value)==null?void 0:fe.value):(N=(te=le.FormContent)==null?void 0:te.find(P=>(P==null?void 0:P.key)===((U==null?void 0:U.类型)===""?"Input":U==null?void 0:U.类型)))==null?void 0:N.value;if(ra==null||ra.forEach(P=>{var Me,Le;d.value++;const Ke=nd(P==null?void 0:P.default)?(U==null?void 0:U[P.label])??P.value??"":P==null?void 0:P.default;qe.push({label:P==null?void 0:P.label,name:P==null?void 0:P.label,type:P.type,value:Ke,prop:P==null?void 0:P.prop,id:d.value,contents:P==null?void 0:P.options,width:((Le=(Me=p.value)==null?void 0:Me[0])==null?void 0:Le.width)??1})}),U!=null&&U.菜单选项&&((we=U==null?void 0:U.菜单选项)==null?void 0:we.length)>0){const P=await le.menuToContentType(U==null?void 0:U.菜单选项);qe=qe==null?void 0:qe.map(Ke=>((Ke==null?void 0:Ke.name)==="组信息选项"&&(Ke.contents=P),Ke))}I(qe),p.value=await le.selectToBase(M.cloneDeep(qe)),o.value=await le.selectToBase(M.cloneDeep(qe))}else{let qe=M.cloneDeep(p.value);if(qe=qe==null?void 0:qe.map(ra=>(ra.value=U==null?void 0:U[ra.name],ra)),U!=null&&U.菜单选项&&((_e=U==null?void 0:U.菜单选项)==null?void 0:_e.length)>0){const ra=await le.menuToContentType(U==null?void 0:U.菜单选项);qe=qe==null?void 0:qe.map(P=>((P==null?void 0:P.name)==="组信息选项"&&(P.contents=ra),P))}qe=le.formToOptionsContents(qe),I(qe),p.value=await le.selectToBase(M.cloneDeep(qe))}},re=U=>{U||(o.value=p.value)},X=async U=>{await R(U),o.value=p.value},me=Fl.debounce(async()=>{var ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra;o.value=p.value;let U={};U.width=((ve=(ae=o.value)==null?void 0:ae[0])==null?void 0:ve.width)??1,g.value!==""?U.id=g.value:(d.value++,U.id="id"+d.value);let W=await((N=(te=(ze=le.FormContent)==null?void 0:ze.find(P=>{var Ke,Me;return(P==null?void 0:P.key)===(((Me=(Ke=o.value)==null?void 0:Ke.find(Le=>(Le==null?void 0:Le.label)==="类型"))==null?void 0:Me.value)??"label")}))==null?void 0:te.value)==null?void 0:N.value)??((G=(se=le.FormContent)==null?void 0:se.find(P=>{var Ke,Me;return(P==null?void 0:P.key)===(((Me=(Ke=o.value)==null?void 0:Ke.find(Le=>(Le==null?void 0:Le.label)==="类型"))==null?void 0:Me.value)??"label")}))==null?void 0:G.value);if((fe=o.value)==null||fe.forEach(P=>{const Ke=W==null?void 0:W.find(Me=>(Me==null?void 0:Me.label)===(P==null?void 0:P.label));Ke&&(U[Ke.key]=P.value)}),U.width=U.width?U.width:1,U.key=U==null?void 0:U.label,U.isFormColHidden=U==null?void 0:U.isFormColHidden,(we=m.value)!=null&&we.find(P=>P.id===U.id))m.value=(_e=m.value)==null?void 0:_e.map(P=>(P.id===U.id&&(P=U),P));else{let P=M.cloneDeep(m.value);P.push(U),m.value=P}m.value=m.value.map(({id:P,...Ke})=>Ke),i.value=!1,g.value="";let Z=M.cloneDeep(r.originalItemContents);(qe=M.cloneDeep(r.originalItemContents))!=null&&qe.find(P=>(P==null?void 0:P.key)==="formContent")?Z=(ra=M.cloneDeep(r.originalItemContents))==null?void 0:ra.map(P=>((P==null?void 0:P.key)==="formContent"&&(P.contents=m.value),P)):Z.push({key:"formContent",contents:m.value}),n("change",Z)},300),ue=()=>{i.value=!1,c.value=!1,g.value="",p.value=[],w.value=[]};return e.watch(()=>r.originalItemContents,()=>{var W,Z,ae,ve,ze,te;if(!r.originalItemContents||r.originalItemContents.length===0)return;const U=M.cloneDeep(r.originalItemContents);m.value=((W=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="formContent"))==null?void 0:W.contents)??[],u.value=((Z=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="formButton"))==null?void 0:Z.contents)??[],y.value=(ae=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="enableWrap"))!=null&&ae.contents?!((ve=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="enableWrap"))!=null&&ve.contents):!0,m.value=(ze=M.cloneDeep(m.value))==null?void 0:ze.map((N,se)=>{var fe;let G=N;return G.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=((fe=N==null?void 0:N.options)==null?void 0:fe.length)===0?(N==null?void 0:N.contents)??"":N==null?void 0:N.options,G}),m.value=le.formToOptionsContents(m.value),u.value=(te=u.value)==null?void 0:te.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}),(U,W)=>{const Z=e.resolveComponent("svg-icon"),ae=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",s4,[e.createElementVNode("div",c4,[e.createElementVNode("div",u4,[W[2]||(W[2]=e.createElementVNode("div",null,e.toDisplayString("表单内容"),-1)),e.createVNode(ae,{class:"icon-content",id:"themeButton",onClick:b},{icon:e.withCtx(()=>[e.createVNode(Z,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[W[1]||(W[1]=e.createElementVNode("div",null,e.toDisplayString("新增"),-1))]),_:1,__:[1]})]),e.createElementVNode("div",d4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(ve,ze)=>(e.openBlock(),e.createElementBlock("div",{key:ze},[e.createElementVNode("div",p4,[e.createElementVNode("div",null,e.toDisplayString(ve.label),1),e.createElementVNode("div",f4,[e.createVNode(Z,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>A(ve)},null,8,["onClick"]),e.createVNode(Z,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>E(ve)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",h4,[W[4]||(W[4]=e.createElementVNode("div",null,e.toDisplayString("表单按钮"),-1)),e.createVNode(ae,{class:"icon-content",id:"themeButton",onClick:x},{icon:e.withCtx(()=>[e.createVNode(Z,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[W[3]||(W[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",v4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(ve,ze)=>(e.openBlock(),e.createElementBlock("div",{key:ze},[e.createElementVNode("div",m4,[e.createElementVNode("div",null,e.toDisplayString(ve.label),1),e.createElementVNode("div",y4,[e.createVNode(Z,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>j(ve)},null,8,["onClick"]),e.createVNode(Z,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>_(ve)},null,8,["onClick"])])])]))),128))]),W[6]||(W[6]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("表单布局"))],-1)),e.createElementVNode("div",g4,[W[5]||(W[5]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否自动撑宽"),-1)),e.createVNode(pl._sfc_main$1,{modelValue:y.value,"onUpdate:modelValue":W[0]||(W[0]=ve=>y.value=ve)},null,8,["modelValue"])])]),e.createVNode($r.ssDialog,{visible:i.value,onBeforeDestroy:ue,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",b4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:o.value,key:o.value,isEnableWrap:!0,onChange:R,onChangeVisible:re,onBlurChange:X},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",k4,[e.createVNode(ae,{onClick:ue,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>W[7]||(W[7]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[7]}),e.createVNode(ae,{class:"ok-button button",onClick:e.unref(me),id:"themeButton"},{default:e.withCtx(()=>W[8]||(W[8]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[8]},8,["onClick"])])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:c.value,onBeforeDestroy:ue,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",x4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:D.value,key:D.value,isEnableWrap:!0,onChange:S},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:ue,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:O},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},$s=pr._export_sfc(w4,[["__scopeId","data-v-20850524"]]),_4={class:"step-module content"},S4={class:"module-data"},E4={class:"step-module layout"},C4={class:"form-content"},D4=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=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}]),o=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"标题",prop:"title",type:"input",value:""},{label:"描述",prop:"description",type:"input",value:""}]),p=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),c=e.reactive({visible:!1,width:"40%",title:"步骤条"}),u=e.ref("create"),m=e.ref({}),g=e.ref([]),y=A=>{var j;m.value=A,n("change",(j=w())==null?void 0:j.compData)},d=(A,j)=>{var O,E;switch(A){case"create":(O=o.value)==null||O.forEach(_=>{_.value=""}),u.value="create",c.visible=!0;break;case"update":(E=o.value)==null||E.forEach(_=>{_.value=j[_==null?void 0:_.prop]}),u.value="update",c.visible=!0;break;case"delete":g.value.splice(j,1),u.value="delete";break}},D=A=>{var j,O,E;if((A==null?void 0:A.buttonName)==="确认"){const _=M.cloneDeep(A==null?void 0:A.content);switch(Object.keys(_).forEach(x=>{_[x]===""&&delete _[x]}),u.value){case"create":g.value.push({..._,index:((j=g.value)==null?void 0:j.length)+1});break;case"update":g.value=(O=g.value)==null?void 0:O.map(x=>x.index===(_==null?void 0:_.index)?{...x,title:_==null?void 0:_.title,description:_==null?void 0:_.description}:x);break}n("change",(E=w())==null?void 0:E.compData),c.visible=!1}else c.visible=!1},w=()=>({comp:"Step",compData:[{key:"stepList",contents:g.value},{key:"stepConfig",contents:m.value}]}),q=()=>{c.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,A=>{var j,O;A&&(m.value=((j=A==null?void 0:A.find(E=>E.key==="stepConfig"))==null?void 0:j.contents)??{},g.value=((O=A==null?void 0:A.find(E=>E.key==="stepList"))==null?void 0:O.contents)??[])},{immediate:!0}),(A,j)=>{const O=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",_4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=_=>d("create"))},{icon:e.withCtx(()=>[e.createVNode(O,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",S4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(_,x)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:x},[e.createElementVNode("span",null,e.toDisplayString(_==null?void 0:_.title),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>d("update",{..._,index:x+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>d("delete",x)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",E4,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(pl.ssForm,{rowContents:i.value,onChange:y},null,8,["rowContents"])])]),e.createVNode($r.ssDialog,{visible:c.visible,title:c.title,onBeforeDestroy:q,width:c.width},{default:e.withCtx(()=>[e.createElementVNode("div",C4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:o.value,key:o.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:p.value,onOnButtonClick:D},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),T4=pr._export_sfc(D4,[["__scopeId","data-v-7dbd17f2"]]),B4={class:"step-module content"},N4={class:"module-data"},A4={class:"step-module layout"},z4={class:"form-content"},M4=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref("create"),o=e.ref({}),p=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}]),u=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:"时间线"}),y=A=>{var j;o.value=A,n("change",(j=w())==null?void 0:j.compData)},d=(A,j)=>{var O,E;switch(A){case"create":(O=u.value)==null||O.forEach(_=>{_.value=""}),i.value="create",g.visible=!0;break;case"update":(E=u.value)==null||E.forEach(_=>{_.value=j[_==null?void 0:_.prop]}),i.value="update",g.visible=!0;break;case"delete":p.value.splice(j,1),i.value="delete";break}},D=A=>{var j,O,E,_;if((A==null?void 0:A.buttonName)==="确认"){const x=M.cloneDeep(A==null?void 0:A.content);switch(Object.keys(x).forEach(b=>{x[b]===""&&delete x[b]}),i.value){case"create":(O=p.value)==null||O.push({...x,index:((j=p.value)==null?void 0:j.length)+1});break;case"update":p.value=(E=p.value)==null?void 0:E.map(b=>b.index===(x==null?void 0:x.index)?{...b,content:x==null?void 0:x.content,timestamp:x==null?void 0:x.timestamp}:b);break}n("change",(_=w())==null?void 0:_.compData),g.visible=!1}else g.visible=!1},w=()=>({comp:"TimeLine",compData:[{key:"timeLineList",contents:p.value},{key:"timeLineConfig",contents:o.value}]}),q=()=>{g.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,A=>{var j,O;A&&(o.value=((j=A==null?void 0:A.find(E=>E.key==="timeLineConfig"))==null?void 0:j.contents)??{},p.value=((O=A==null?void 0:A.find(E=>E.key==="timeLineList"))==null?void 0:O.contents)??[])},{immediate:!0}),(A,j)=>{const O=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",B4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=_=>d("create"))},{icon:e.withCtx(()=>[e.createVNode(O,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",N4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(_,x)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:x},[e.createElementVNode("span",null,e.toDisplayString(_==null?void 0:_.content),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>d("update",{..._,index:x+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>d("delete",x)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",A4,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(pl.ssForm,{rowContents:c.value,onChange:y},null,8,["rowContents"])])]),e.createVNode($r.ssDialog,{visible:g.visible,title:g.title,onBeforeDestroy:q,width:g.width},{default:e.withCtx(()=>[e.createElementVNode("div",z4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,key:u.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:m.value,onOnButtonClick:D},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),I4=pr._export_sfc(M4,[["__scopeId","data-v-39ffc861"]]),O4={};function L4(a,l){return e.openBlock(),e.createElementBlock("div")}const R4=pr._export_sfc(O4,[["render",L4]]),$4={class:"extra-content"},V4={key:0},F4={key:1},P4={class:"dialog-footer"},j4={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},emits:["change"],setup(a,{emit:l}){const r=a,n=e.ref(0),i=e.ref(),o=e.ref(),p=l,c=e.ref(!1),u=e.ref({}),m=e.ref({}),g=e.ref();e.watch(()=>[r.itemData],()=>{var _;const E=M.cloneDeep(r.itemData);i.value=(_=M.cloneDeep(E))==null?void 0:_.map(x=>{var b;if(x.key==="extra"){let S=[];(b=x.value)==null||b.forEach(I=>{var R;S.push((R=Object.values(I))==null?void 0:R[0])}),x.value=S}return x})},{deep:!0,immediate:!0});const y=(E,_,x,b)=>{var I;let S={};((I=E==null?void 0:E[0])==null?void 0:I.contents)==="详情"&&(c.value=!0,S[_]=E,o.value=E==null?void 0:E.filter(R=>(R==null?void 0:R.key)!=="tableContentName"),u.value=S,m.value=x,g.value=b.id)},d=E=>{var R,re,X,me;const _=(re=(R=Object.values(M.cloneDeep(u.value)))==null?void 0:R[0])==null?void 0:re.filter(ue=>(ue==null?void 0:ue.key)==="tableContentName"),x=(me=(X=Object.values(M.cloneDeep(u.value)))==null?void 0:X[0])==null?void 0:me.filter(ue=>(ue==null?void 0:ue.key)!=="tableContentName"),b=x==null?void 0:x.map((ue,U)=>{var W;return U===E.index&&(ue==null?void 0:ue.comp)==="Table"&&(ue.compData=(W=ue.compData)==null?void 0:W.map(Z=>{var ae,ve;return(Z==null?void 0:Z.key)==="tableContents"&&(Z.contents=(ve=(ae=E.content)==null?void 0:ae.map(ze=>{let te={};for(let N in ze)N!=="id"&&(te[N]=ze[N]);return te}))==null?void 0:ve.map(ze=>Object.values(ze))),Z})),ue});b.unshift(_==null?void 0:_[0]);let S=M.cloneDeep(u.value),I={};for(let ue in S)I[ue]=b;u.value=I},D=()=>{c.value=!1,u.value={},m.value={},g.value=void 0,n.value++},w=E=>{var R,re,X,me;const _=(re=(R=Object.values(M.cloneDeep(u.value)))==null?void 0:R[0])==null?void 0:re.filter(ue=>(ue==null?void 0:ue.key)==="tableContentName"),x=(me=(X=Object.values(M.cloneDeep(u.value)))==null?void 0:X[0])==null?void 0:me.filter(ue=>(ue==null?void 0:ue.key)!=="tableContentName"),b=x==null?void 0:x.map((ue,U)=>(U===E.index&&(ue.compData=E.contents),ue));b.unshift(_==null?void 0:_[0]);let S=M.cloneDeep(u.value),I={};for(let ue in S)I[ue]=b;u.value=I},q=()=>{var _,x;let E={};for(let b in m.value)b===((_=Object.keys(u.value))==null?void 0:_[0])?E[b]=(x=Object.values(u.value))==null?void 0:x[0]:E[b]=m.value[b];p("change",{buttonName:"编辑",index:g.value,singleContent:E},"methodData"),c.value=!1,u.value={},m.value={},g.value=void 0},A=()=>{c.value=!1,u.value={},m.value={},g.value=void 0},j=E=>{p("change",E,"methodData")},O=E=>$i(E);return(E,_)=>{const x=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",$4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(b,S)=>(e.openBlock(),e.createElementBlock("div",{key:n.value},[(b==null?void 0:b.key)==="extra"?(e.openBlock(),e.createElementBlock("div",V4)):(e.openBlock(),e.createElementBlock("div",F4,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(O(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:y,onChange:j},null,40,["itemData","childItemData","index"]))]))]))),128)),e.createVNode($r.ssDialog,{visible:c.value,onBeforeDestroy:A},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,(b,S)=>(e.openBlock(),e.createElementBlock("div",{key:S,class:"extra-dialog"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(O(b.comp)),{itemData:b==null?void 0:b.compData,onChange:d,childItemData:b==null?void 0:b.itemChildData,key:S,onContentChange:w,index:(b==null?void 0:b.id)??S,class:"extra-component"},null,40,["itemData","childItemData","index"]))]))),128))]),footer:e.withCtx(()=>[e.createElementVNode("div",P4,[e.createVNode(x,{class:"cancel-button footer-button",onClick:D,id:"themeBorderButton"},{default:e.withCtx(()=>_[0]||(_[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(x,{class:"confirm-button footer-button",onClick:q,id:"themeButton"},{default:e.withCtx(()=>_[1]||(_[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},H4=pr._export_sfc(j4,[["__scopeId","data-v-2d9c5ab2"]]),U4={key:0,class:"method-content"},q4={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},setup(a){const l=e.ref([]),r=le.useOriginalState(M.pinia),{originalPath:n}=M.storeToRefs(r),i=a,o=e.ref(!1),p=e.ref(),c=le.useTableComp(M.pinia),{multipleTableConst:u}=M.storeToRefs(c),m=M.useModelComp(M.pinia),g=e.ref(!1),y=M.useMenuState(M.pinia),d=M.useLoginState(M.pinia),{itemData:D,isEdit:w,routeToChildPath:q,tableViewContents:A,lockingPage:j,payloadTypes:O}=M.storeToRefs(m),{activeMenuPath:E,platform:_,childMenu:x}=M.storeToRefs(y),{loginUserInfo:b}=M.storeToRefs(d),S=e.ref(!1),I=async()=>{var te,N;(te=l.value)!=null&&te.find(se=>(se==null?void 0:se.buttonName)==="保存")&&await Z((N=l.value)==null?void 0:N.find(se=>(se==null?void 0:se.buttonName)==="保存")),await le.onSaveBack()};e.watch(()=>D.value,async()=>{w.value==="view"&&!S.value&&await ze(M.cloneDeep(i.itemData)),S.value=!1},{deep:!0});const R=()=>{o.value=!1,p.value=void 0},re=te=>te.map(N=>{const se={};for(const G in N){const fe=N[G];if(G.includes(u.value)){const we=G.split(u.value);let _e=se;we.forEach((qe,ra)=>{ra===we.length-1?_e[qe]=fe:(_e[qe]||(_e[qe]={}),_e=_e[qe])})}else se[G]=fe}return se}),X=async(te,N,se=[])=>{var fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge;let G=(fe=M.cloneDeep(N))==null?void 0:fe.filter($=>($==null?void 0:$.comp)!=="methodButton");if(te!=null&&te.includes("[")){let $=(P=(ra=(qe=(_e=(we=M.cloneDeep(te))==null?void 0:we.split("["))==null?void 0:_e[1])==null?void 0:qe.split("]"))==null?void 0:ra[0])==null?void 0:P.split(":"),V="";if($!=null&&$[0]){let ee=(Ke=G==null?void 0:G.find(ce=>(ce==null?void 0:ce.name)===($==null?void 0:$[0])))==null?void 0:Ke.compData;if(!ee){let ce=(Me=te==null?void 0:te.split("["))==null?void 0:Me[0],he=await le.getItemData(ce,sessionStorage.getItem("systemKey"),"",!1,"","",se);ee=(Le=he==null?void 0:he.find(pa=>(pa==null?void 0:pa.name)===($==null?void 0:$[0])))==null?void 0:Le.compData}ee==null||ee.forEach(ce=>{var he,pa,ia,Ve,ya,Ca;if((ce==null?void 0:ce.key)==="formContent")(he=ce==null?void 0:ce.contents)==null||he.forEach(Ce=>{var Fa;(Ce==null?void 0:Ce.key)===($==null?void 0:$[1])&&(Array.isArray(Ce==null?void 0:Ce.value)?V=Ce==null?void 0:Ce.value:V=(Fa=Ce==null?void 0:Ce.value)==null?void 0:Fa.toString())});else if((ce==null?void 0:ce.key)==="tableContents"){let Ce=[],Fa=(pa=ee==null?void 0:ee.find(fa=>(fa==null?void 0:fa.key)==="header"))==null?void 0:pa.contents,Ta=($==null?void 0:$[1])??"";if(Fa!=null&&Fa.every(fa=>Array.isArray(fa))){let fa=le.getColumnChild((ya=Fa==null?void 0:Fa[0])==null?void 0:ya.filter(ja=>(ja==null?void 0:ja.label)!=="操作"));(Ca=ce.contents)==null||Ca.forEach(ja=>{let sa={};ja=ja==null?void 0:ja.filter(Pe=>!(Pe!=null&&Pe.id)),fa==null||fa.forEach((Pe,ma)=>{let Qe=ja[ma];typeof ja[ma]=="number"&&(Qe=ja[ma].toString()),(Ta===""||Ta===Pe.prop)&&(sa[Pe.prop]=Qe)}),Ce.push(sa)}),Ce=re(Ce)}else{let fa=(ia=Fa==null?void 0:Fa.map(ja=>ja==null?void 0:ja.label))==null?void 0:ia.filter(ja=>ja!=="操作");(Ve=ce.contents)==null||Ve.forEach(ja=>{let sa={};ja=ja==null?void 0:ja.filter(Pe=>!(Pe!=null&&Pe.id)),fa==null||fa.forEach((Pe,ma)=>{let Qe=ja[ma];typeof ja[ma]=="number"&&(Qe=ja[ma].toString()),(Ta===""||Ta===Pe)&&(sa[Pe]=Qe)}),Ce.push(sa)})}V=Ce}})}return V}else if(te!=null&&te.includes("/")){let $={};return(Ie=M.cloneDeep(G))==null||Ie.forEach((V,ee)=>{var ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne;if((V==null?void 0:V.comp)==="Table"){let We=Array.isArray((pa=(he=(ce=V==null?void 0:V.compData)==null?void 0:ce.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:he.contents)==null?void 0:pa[0])?(Ca=(ya=(Ve=(ia=V==null?void 0:V.compData)==null?void 0:ia.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:Ve.contents)==null?void 0:ya[0])==null?void 0:Ca.some(Be=>Be==null?void 0:Be.children):[],na=(Ta=(Fa=(Ce=V==null?void 0:V.compData)==null?void 0:Ce.find(Be=>(Be==null?void 0:Be.key)==="tableContents"))==null?void 0:Fa.contents)==null?void 0:Ta.map(Be=>(Be!=null&&Be.find(Ye=>Ye==null?void 0:Ye.id)&&(Be=Be.slice(1)),Be)),va=(ma=(Pe=(sa=(ja=(fa=V==null?void 0:V.compData)==null?void 0:fa.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:ja.contents)==null?void 0:sa[0])==null?void 0:Pe[0])==null?void 0:ma.label,Ae=(Oe=(Qe=V==null?void 0:V.compData)==null?void 0:Qe.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:Oe.contents;if(We)(We==null?void 0:We.length)===0?$[V.name]=$!=null&&$[V.name]?$[V.name]:le.tableToForm(na,Ae):$[va]=le.tableToForm(na,Ae);else{const Be=[];Ae=Ae.slice(1,Ae.length-1),Ae==null||Ae.forEach((Ye,Ee)=>{na==null||na.forEach(ye=>{Be.push({key:Ye.label+ye[0],value:ye[Ee+1]})})}),$["form"+ee]=Be}}else{const We=(ne=($e=V.compData)==null?void 0:$e.find(va=>(va==null?void 0:va.key)==="formContent"))==null?void 0:ne.contents;$!=null&&$.form||($.form=[]);const na=[];We==null||We.forEach(va=>{va.key!==""&&(va={key:(va==null?void 0:va.key)??(va==null?void 0:va.label),value:va==null?void 0:va.value},na.push(va))}),$.form=[...na,...M.cloneDeep($==null?void 0:$.form)]}}),$}else{if(te==="createInsofDataApi"){let $=(de=M.cloneDeep(N))==null?void 0:de[0];return $={comp:(De=M.cloneDeep($))==null?void 0:De.comp,compData:(Xe=M.cloneDeep($))==null?void 0:Xe.compData,name:(Ea=M.cloneDeep($))==null?void 0:Ea.name,isShow:(Ge=M.cloneDeep($))==null?void 0:Ge.isShow},{key:{type:"structure",systemKey:sessionStorage.getItem("systemKey"),parentTable:"",pageKey:E.value},value:{pageData:$}}}return te}},me=async(te,N,se)=>{var we,_e,qe;let G=await le.getItemData(N,sessionStorage.getItem("systemKey"),""),fe=G==null?void 0:G.find(ra=>(ra==null?void 0:ra.name)===(se==null?void 0:se[0]));if(fe){if((fe==null?void 0:fe.comp)==="Table"){let ra={};for(let De in M.cloneDeep(te))M.cloneDeep(te)[De]!=="loginUser"?ra[De]=M.cloneDeep(te)[De]:ra[De]=((we=b.value)==null?void 0:we.account)||((_e=b.value)==null?void 0:_e.账号);let P=[],Ke=ra;Array.isArray(te)||(Ke=[ra]),Ke==null||Ke.forEach(De=>{P.push({[De[se[1]]]:De})});let Me=[],Le=P==null?void 0:P.map(De=>{var Xe;return(Xe=Object.keys(De))==null?void 0:Xe[0]});G==null||G.forEach(De=>{var Xe;(De==null?void 0:De.name)===(se==null?void 0:se[0])&&((Xe=De==null?void 0:De.compData)==null||Xe.forEach(Ea=>{var Ge;(Ea==null?void 0:Ea.key)==="tableContents"&&((Ge=Ea==null?void 0:Ea.contents)==null||Ge.forEach($=>{$!=null&&$.some(V=>Le.includes(V))&&Me.push({[$.find(V=>V.id).id]:$.find(V=>Le.includes(V))})}))}))});let Ie=Me==null?void 0:Me.map(De=>{var Xe;return(Xe=Object.keys(De))==null?void 0:Xe[0]}),de=[];if(Ie==null||Ie.forEach(De=>{var Ge;let Xe=(Ge=Me==null?void 0:Me.find($=>{var V;return((V=Object.keys($))==null?void 0:V[0].toString())===De.toString()}))==null?void 0:Ge[De],Ea=P==null?void 0:P.find($=>{var V;return((V=Object.keys($))==null?void 0:V[0])===Xe});de.push({id:parseInt(De),value:{tableData:Ea[Xe]}})}),(de==null?void 0:de.length)>0)return de}else if((fe==null?void 0:fe.comp)==="Form"){let ra=M.cloneDeep(fe);ra.compData=(qe=ra.compData)==null?void 0:qe.map(Me=>{var Le;return(Me==null?void 0:Me.key)==="formContent"&&(Me.contents=(Le=Me.contents)==null?void 0:Le.map(Ie=>((Ie==null?void 0:Ie.key)===(se==null?void 0:se[1])&&(Ie.value=(te==null?void 0:te[Ie==null?void 0:Ie.prop])||te),Ie))),Me});let P={};for(let Me in ra)Me!=="id"&&(P[Me]=ra[Me]);let Ke=[];if(Ke.push({id:fe==null?void 0:fe.id,keyType:se==null?void 0:se[1],value:{pageData:P}}),(Ke==null?void 0:Ke.length)>0)return Ke}}},ue=async(te,N,se)=>{var we,_e,qe,ra,P,Ke,Me,Le,Ie,de;let G=await le.getItemData(N,sessionStorage.getItem("systemKey"),""),fe=G==null?void 0:G.find(De=>(De==null?void 0:De.name)===(se==null?void 0:se[0]));if(fe){if((fe==null?void 0:fe.comp)==="Table"){let De={};for(let Xe in M.cloneDeep(te))M.cloneDeep(te)[Xe]!=="loginUser"?De[Xe]=M.cloneDeep(te)[Xe]:De[Xe]=((we=b.value)==null?void 0:we.account)||((_e=b.value)==null?void 0:_e.账号);await Kr.createInsofDataApi({key:{type:"data",pageKey:N,tableId:fe==null?void 0:fe.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:De}})}else if((fe==null?void 0:fe.comp)==="Form"){let De=M.cloneDeep(fe),Xe=Object.keys(te),Ea="";(ra=(qe=M.cloneDeep(De))==null?void 0:qe.compData)==null||ra.forEach(he=>{var pa,ia;(he==null?void 0:he.key)==="formContent"&&((ia=(pa=M.cloneDeep(he))==null?void 0:pa.contents)==null||ia.forEach(Ve=>{var ya;Xe.includes(Ve==null?void 0:Ve.key)&&(Ve==null?void 0:Ve.value)===((ya=b.value)==null?void 0:ya.姓名)&&(Ea=Ve==null?void 0:Ve.key)}))});let Ge=[];(P=Object.values(te[Ea]))==null||P.forEach(he=>{he!=null&&he.includes("(")&&Ge.push(he)}),Ge=[...new Set(Ge)];const $=Ge==null?void 0:Ge.map(async he=>{var Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e;let pa="";(ja=(fa=(Ta=(Fa=(Ce=(Ca=M.cloneDeep(he))==null?void 0:Ca.split("("))==null?void 0:Ce[1])==null?void 0:Fa.split(")"))==null?void 0:Ta[0])==null?void 0:fa.split(":"))==null||ja.forEach(ne=>{pa=pa===""?pa+ne.replaceAll("'",""):pa+"/"+ne.replaceAll("'","")});let ia=[];($e=(Oe=(Qe=(ma=(Pe=(sa=M.cloneDeep(he))==null?void 0:sa.split("<"))==null?void 0:Pe[1])==null?void 0:ma.split(">"))==null?void 0:Qe[0])==null?void 0:Oe.split(":"))==null||$e.forEach(ne=>{ia.push(ne.replaceAll("'",""))});const Ve=await le.getItemData(pa,sessionStorage.getItem("systemKey"),"");let ya="";return Ve==null||Ve.forEach(ne=>{var We;ne.name===(ia==null?void 0:ia[0])&&((We=ne==null?void 0:ne.compData)==null||We.forEach(na=>{var va;(na==null?void 0:na.key)==="formContent"&&((va=na.contents)==null||va.forEach(Ae=>{(Ae==null?void 0:Ae.key)===(ia==null?void 0:ia[1])&&(ya=Ae==null?void 0:Ae.value)}))}))}),{[he]:ya}}),V=await Promise.all($);De.compData=(Me=(Ke=M.cloneDeep(De))==null?void 0:Ke.compData)==null?void 0:Me.map(he=>{var pa,ia;return(he==null?void 0:he.key)==="formContent"&&(he.contents=(ia=(pa=M.cloneDeep(he))==null?void 0:pa.contents)==null?void 0:ia.map(Ve=>{var ya,Ca,Ce,Fa;return(ya=te[Ea])!=null&&ya[Ve==null?void 0:Ve.key]&&(te[Ea][Ve==null?void 0:Ve.key].includes("(")?Ve.value=(Ca=V==null?void 0:V.find(Ta=>{var fa;return((fa=Object.keys(Ta))==null?void 0:fa[0])===te[Ea][Ve==null?void 0:Ve.key]}))==null?void 0:Ca[te[Ea][Ve==null?void 0:Ve.key]]:Ve.value=(Fa=(Ce=M.cloneDeep(te))==null?void 0:Ce[Ea])==null?void 0:Fa[Ve==null?void 0:Ve.key]),Ve})),he});const ee=await Kr.getInsofDataApi({key:{type:"structure",pageKey:N,systemKey:sessionStorage.getItem("systemKey")}});let ce="";((Le=ee==null?void 0:ee.data)==null?void 0:Le.type)==="success"&&((de=(Ie=ee==null?void 0:ee.data)==null?void 0:Ie.result)==null||de.forEach(he=>{var pa,ia;((ia=(pa=he==null?void 0:he.value)==null?void 0:pa.pageData)==null?void 0:ia.name)===(se==null?void 0:se[0])&&(ce=he.id)}),await Kr.updateInsofDataApi({id:ce,value:{pageData:De}}))}}},U=(te,N="",se={})=>{for(const[G,fe]of Object.entries(te)){const we=N?`${N}.${G}`:G;fe!==null&&typeof fe=="object"&&!Array.isArray(fe)&&Object.prototype.toString.call(fe)!=="[object Date]"?U(fe,we,se):se[we]=fe}return se},W=async(te,N,se,G)=>{var _e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa;let fe=await le.getItemData(N,sessionStorage.getItem("systemKey"),""),we=fe==null?void 0:fe.find(Ta=>(Ta==null?void 0:Ta.name)===(se==null?void 0:se[0]));if(we){if(!(se!=null&&se[1])&&(we==null?void 0:we.comp)==="Table"){let Ta={},fa=[],ja=(qe=(_e=we==null?void 0:we.compData)==null?void 0:_e.find(ma=>(ma==null?void 0:ma.key)==="header"))==null?void 0:qe.contents;ja!=null&&ja.every(ma=>Array.isArray(ma))?fa=(P=le.getColumnChild((ra=ja==null?void 0:ja[0])==null?void 0:ra.filter(ma=>(ma==null?void 0:ma.label)!=="操作")))==null?void 0:P.map(ma=>ma==null?void 0:ma.prop):fa=ja==null?void 0:ja.map(ma=>ma==null?void 0:ma.label);for(let ma in M.cloneDeep(te))if(M.cloneDeep(te)[ma]!=="loginUser"){let Qe=U(M.cloneDeep(te)[ma]),Oe={};for(let $e in Qe)if(fa!=null&&fa.find(ne=>ne===$e))Oe[$e]=Qe[$e];else if(fa!=null&&fa.find(ne=>(ne==null?void 0:ne.toUpperCase())===($e==null?void 0:$e.toUpperCase()))){let ne=fa==null?void 0:fa.find(We=>(We==null?void 0:We.toUpperCase())===($e==null?void 0:$e.toUpperCase()));Oe[ne]=Qe[$e]}Ta[ma]=Oe}else Ta[ma]=((Ke=b.value)==null?void 0:Ke.account)||((Me=b.value)==null?void 0:Me.账号);let sa=await Kr.getInsofDataApi({keyLikes:{tableId:we==null?void 0:we.id}});if(((Ie=(Le=sa==null?void 0:sa.data)==null?void 0:Le.result)==null?void 0:Ie.length)>0){let ma=(De=(de=sa==null?void 0:sa.data)==null?void 0:de.result)==null?void 0:De.map(Qe=>Qe==null?void 0:Qe.id);(ma==null?void 0:ma.length)>0&&await Kr.batchDeleteInsofDataApi({ids:ma})}let Pe=[];if((Xe=we==null?void 0:we.compData)!=null&&Xe.find(ma=>(ma==null?void 0:ma.key)==="pageColumn")&&(($=(Ge=(Ea=we==null?void 0:we.compData)==null?void 0:Ea.find(ma=>(ma==null?void 0:ma.key)==="pageColumn"))==null?void 0:Ge.contents)!=null&&$.includes("["))){const ma=await Kr.getInsofDataApi({id:we==null?void 0:we.tableId});let Qe=((he=(ce=(ee=(V=ma==null?void 0:ma.data)==null?void 0:V.result)==null?void 0:ee[0])==null?void 0:ce.key)==null?void 0:he.pageKey)??"";(pa=Object.values(Ta))==null||pa.forEach(Oe=>{Pe.push({key:{type:"data",pageKey:Qe,tableId:we==null?void 0:we.tableId,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Oe}})})}else(ia=Object.values(Ta))==null||ia.forEach(ma=>{Pe.push({key:{type:"data",pageKey:N,tableId:we==null?void 0:we.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:ma}})});(Pe==null?void 0:Pe.length)>0&&await Kr.batchAddInsofDataApi({dataList:Pe})}else if(!(se!=null&&se[1])&&(we==null?void 0:we.comp)==="Form"){let Ta=M.cloneDeep(we);Ta.compData=(ya=(Ve=M.cloneDeep(Ta))==null?void 0:Ve.compData)==null?void 0:ya.map(sa=>{var Pe,ma;return(sa==null?void 0:sa.key)==="formContent"&&(sa.contents=(ma=(Pe=M.cloneDeep(sa))==null?void 0:Pe.contents)==null?void 0:ma.map(Qe=>{var Oe,$e;return(Oe=M.cloneDeep(te))!=null&&Oe[Qe==null?void 0:Qe.key]&&(Qe.value=($e=M.cloneDeep(te))==null?void 0:$e[Qe==null?void 0:Qe.key]),Qe})),sa});const fa=await Kr.getInsofDataApi({key:{type:"structure",pageKey:N,systemKey:sessionStorage.getItem("systemKey")}});let ja="";((Ca=fa==null?void 0:fa.data)==null?void 0:Ca.type)==="success"&&((Fa=(Ce=fa==null?void 0:fa.data)==null?void 0:Ce.result)==null||Fa.forEach(sa=>{var Pe,ma;((ma=(Pe=sa==null?void 0:sa.value)==null?void 0:Pe.pageData)==null?void 0:ma.name)===(se==null?void 0:se[0])&&(ja=sa.id)}),await Kr.updateInsofDataApi({id:ja,value:{pageData:Ta}}))}}},Z=async te=>{var N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de;y.setImportLoading(!0);try{if(te.api){let De=new WeakMap,Xe=await le.getItemData((x==null?void 0:x.value)===""?E.value:x==null?void 0:x.value,sessionStorage.getItem("systemKey"),"",!1,"","",De),Ea="";if(Xe=Xe==null?void 0:Xe.map(ia=>{var Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe;if((ia==null?void 0:ia.comp)==="Form")ia.compData=(Ve=ia.compData)==null?void 0:Ve.map(Oe=>{var $e;return(Oe==null?void 0:Oe.key)==="formContent"&&(Oe.contents=($e=Oe.contents)==null?void 0:$e.map(ne=>{var We;if((ne==null?void 0:ne.value)===""&&(ne==null?void 0:ne.type)==="Select"){let na=le.judgeContents((We=M.cloneDeep(ne))==null?void 0:We.optionUrl,De);ne.value=ne.value||na}return ne})),Oe});else if((ia==null?void 0:ia.comp)==="Table"&&(ya=ia.compData)!=null&&ya.find(Oe=>(Oe==null?void 0:Oe.key)==="pageColumn")){let Oe=(Ce=(Ca=ia.compData)==null?void 0:Ca.find(na=>(na==null?void 0:na.key)==="pageColumn"))==null?void 0:Ce.contents,$e=((Ta=(Fa=ia.compData)==null?void 0:Fa.find(na=>(na==null?void 0:na.key)==="pageGroup"))==null?void 0:Ta.contents)??"",ne=(sa=(ja=(fa=Oe==null?void 0:Oe.split("["))==null?void 0:fa[1])==null?void 0:ja.split("]"))==null?void 0:sa[0];Ea=((Pe=Oe==null?void 0:Oe.split("["))==null?void 0:Pe[0])+((Qe=(ma=A.value)==null?void 0:ma.find(na=>(na==null?void 0:na.key)===ne))==null?void 0:Qe.value)}return ia}),!(Ea===""||Ea==="")){const ia=await le.getItemData(Ea,sessionStorage.getItem("systemKey"),"",!1,"","",De);Xe=Xe==null?void 0:Xe.map(Ve=>{var ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e;if((Ve==null?void 0:Ve.comp)==="Table"&&(ya=Ve.compData)!=null&&ya.find(ne=>(ne==null?void 0:ne.key)==="pageColumn")){let ne=(Ce=(Ca=Ve.compData)==null?void 0:Ca.find(Be=>(Be==null?void 0:Be.key)==="pageColumn"))==null?void 0:Ce.contents,We=((Ta=(Fa=Ve.compData)==null?void 0:Fa.find(Be=>(Be==null?void 0:Be.key)==="pageGroup"))==null?void 0:Ta.contents)??"",na=(sa=(ja=(fa=ne==null?void 0:ne.split("["))==null?void 0:fa[1])==null?void 0:ja.split("]"))==null?void 0:sa[0],va=((Pe=ne==null?void 0:ne.split("["))==null?void 0:Pe[0])+((Qe=(ma=A.value)==null?void 0:ma.find(Be=>(Be==null?void 0:Be.key)===na))==null?void 0:Qe.value),Ae=(Oe=ia==null?void 0:ia.find(Be=>(Be==null?void 0:Be.name)===(We===""?i==null?void 0:i.compName:We)))==null?void 0:Oe.compData;Ve.compData=($e=Ve.compData)==null?void 0:$e.map(Be=>{var Ye;return(Be==null?void 0:Be.key)==="tableContents"&&(Be.contents=(Ye=Ae==null?void 0:Ae.find(Ee=>(Ee==null?void 0:Ee.key)==="tableContents"))==null?void 0:Ye.contents),Be})}return Ve})}let Ge={};if(((se=(N=te==null?void 0:te.extraValues)==null?void 0:N.input)==null?void 0:se.length)>0){const ia=(fe=(G=te==null?void 0:te.extraValues)==null?void 0:G.input)==null?void 0:fe.map(async Ve=>{var ya;ae!=null&&ae.find(Ca=>Ca===Ve)?Ge=await X(Ve,Xe):Ge[Object.keys(Ve)[0]]=await X((ya=Object.values(Ve))==null?void 0:ya[0],Xe,De)});await Promise.all(ia)}else Ge=await X("/",Xe);let $=!1;(_e=(we=te==null?void 0:te.extraValues)==null?void 0:we.output)==null||_e.forEach(ia=>{var Ve,ya;(ya=(Ve=Object.values(ia))==null?void 0:Ve[0])!=null&&ya.includes(".doc")&&($=!0)});let V;if($){const ia=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});V=await Ja.axios.post(te.api,Ge,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{ia.close()})}else V=await Ja.axios.post(te.api,Ge,{headers:{"Content-Type":"application/json"}});let ee=(Ke=(P=(ra=(qe=M.cloneDeep(te))==null?void 0:qe.extraValues)==null?void 0:ra.output)==null?void 0:P.map(ia=>{var Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We;if(!((ya=(Ve=Object.values(ia))==null?void 0:Ve[0])!=null&&ya.includes(".doc"))){let na=(Pe=(sa=(ja=(Ce=M.cloneDeep((Ca=Object.values(ia))==null?void 0:Ca[0]))==null?void 0:Ce.split("["))==null?void 0:ja[((fa=(Ta=M.cloneDeep((Fa=Object.values(ia))==null?void 0:Fa[0]))==null?void 0:Ta.split("["))==null?void 0:fa.length)-1])==null?void 0:sa.split("]"))==null?void 0:Pe[0],va=na==null?void 0:na.split(":"),Ae=(Oe=M.cloneDeep((ma=Object.values(ia))==null?void 0:ma[0]))==null?void 0:Oe.substring(0,M.cloneDeep((Qe=Object.values(ia))==null?void 0:Qe[0]).lastIndexOf("["));if(Ae=(ne=M.cloneDeep(Ae))==null?void 0:ne.slice(0,(($e=M.cloneDeep(Ae))==null?void 0:$e.length)-1),Ae!=null&&Ae.includes("[")){let Be="";if((We=le.contentTransArrayToAll(Ae,"/"))==null||We.forEach(Ye=>{var Ee,ye,$a,wl,Qa,Pl,gl;if(!(Ye!=null&&Ye.includes("[")))Be=Be===""?Be+Ye.replaceAll("/",""):Be+"/"+Ye.replaceAll("/","");else{let jl=M.cloneDeep(Ye).slice(1,((Ee=M.cloneDeep(Ye))==null?void 0:Ee.length)-1),al=(Pl=(Qa=(wl=($a=(ye=M.cloneDeep(jl))==null?void 0:ye.split("["))==null?void 0:$a[1])==null?void 0:wl.split("]"))==null?void 0:Qa[0])==null?void 0:Pl.split(":"),Hl="",Wa=(gl=Xe==null?void 0:Xe.find(Gl=>(Gl==null?void 0:Gl.name)===(al==null?void 0:al[0])))==null?void 0:gl.compData;Wa==null||Wa.forEach(Gl=>{var Kl;(Gl==null?void 0:Gl.key)==="formContent"&&((Kl=Gl==null?void 0:Gl.contents)==null||Kl.forEach(Zl=>{(Zl==null?void 0:Zl.key)===(al==null?void 0:al[1])&&(Hl=Zl==null?void 0:Zl.value)}))}),Be=Be===""?Be+Hl.replaceAll("/",""):Be+"/"+Hl.replaceAll("/","")}}),Ae=Be,Ae[(Ae==null?void 0:Ae.length)-1]!=="/")return Ae}}}))==null?void 0:Ke.filter(ia=>ia);ee=[...new Set(M.cloneDeep(ee))];let ce=ee==null?void 0:ee.map(async ia=>{let Ve=await le.getItemData(ia,sessionStorage.getItem("systemKey"),"",!1,"","",De);if((Ve==null?void 0:Ve.length)===0)return await le.getParentContents(ia)});await Promise.all(ce);let he=[],pa=(Ie=(Le=(Me=M.cloneDeep(te))==null?void 0:Me.extraValues)==null?void 0:Le.output)==null?void 0:Ie.map(async ia=>{var ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha,Sa,ll,Te,oa,Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe,bl,tr,xr,Ra,kl,Ml,Oa,aa,Rl,Yr,Jr,vn,en,Ar,Re,lr,Yl,an;if((sa=(ja=Object.values(ia))==null?void 0:ja[0])!=null&&sa.includes(".doc")){var Ve=new Blob([V.data],{type:"application/octet-stream;charset=UTF-8"}),ya=V.headers["content-disposition"],Ca=new RegExp("filename=([^;]+\\.[^\\.;]+);*"),Ce=Ca.exec(ya),Fa=Ce==null?void 0:Ce[1],Ta=document.createElement("a"),fa=window.URL.createObjectURL(Ve);p.value=[{name:Fa,blobUrl:fa}],o.value=!0}else{let Sr=(na=(We=(ne=(ma=M.cloneDeep((Pe=Object.values(ia))==null?void 0:Pe[0]))==null?void 0:ma.split("["))==null?void 0:ne[(($e=(Oe=M.cloneDeep((Qe=Object.values(ia))==null?void 0:Qe[0]))==null?void 0:Oe.split("["))==null?void 0:$e.length)-1])==null?void 0:We.split("]"))==null?void 0:na[0],Jl=Sr==null?void 0:Sr.split(":"),Er=(Be=M.cloneDeep((va=Object.values(ia))==null?void 0:va[0]))==null?void 0:Be.substring(0,M.cloneDeep((Ae=Object.values(ia))==null?void 0:Ae[0]).lastIndexOf("["));if(Er!=null&&Er.includes("[")?Er=(Ee=M.cloneDeep(Er))==null?void 0:Ee.slice(0,((Ye=M.cloneDeep(Er))==null?void 0:Ye.length)-1):Er===""&&(Er=E.value),Er=Er.replaceAll("<","[").replaceAll(">","]"),Er!=null&&Er.includes("[")){let $l="";(ye=le.contentTransArrayToAll(Er,"/"))==null||ye.forEach((nr,Ql)=>{var Ul,Nl,Vr,er,Ur,Br,Tr,gn,Sn,Cn,mn;if(!(nr!=null&&nr.includes("[")))$l=$l===""?$l+nr.replaceAll("/",""):$l+"/"+nr.replaceAll("/","");else{let On="",rn="";(Ul=M.cloneDeep(nr))!=null&&Ul.includes("]")?(On=M.cloneDeep(nr).slice(1,((Nl=M.cloneDeep(nr))==null?void 0:Nl.length)-1),rn=(Tr=(Br=(Ur=(er=(Vr=M.cloneDeep(On))==null?void 0:Vr.split("["))==null?void 0:er[1])==null?void 0:Ur.split("]"))==null?void 0:Br[0])==null?void 0:Tr.split(":")):(On=M.cloneDeep(nr).slice(1,(gn=M.cloneDeep(nr))==null?void 0:gn.length),rn=(Sn=M.cloneDeep(On))==null?void 0:Sn.split("/"));let Dn="",Vn=(Cn=Xe==null?void 0:Xe.find(nn=>(nn==null?void 0:nn.name)===(rn==null?void 0:rn[0])))==null?void 0:Cn.compData;Vn==null||Vn.forEach(nn=>{var Fn;(nn==null?void 0:nn.key)==="formContent"&&((Fn=nn==null?void 0:nn.contents)==null||Fn.forEach(zr=>{(zr==null?void 0:zr.key)===(rn==null?void 0:rn[1])&&(Dn=zr==null?void 0:zr.value)}))}),((mn=le.contentTransArrayToAll(Er,"/"))==null?void 0:mn.length)-1!==Ql?$l=$l===""?$l+Dn.replaceAll("/",""):$l+"/"+Dn.replaceAll("/",""):$l=$l+n.value+Dn.replaceAll("/","")}}),($a=E.value)!=null&&$a.includes($l)?Er=E.value:Er=$l}let Xl=M.cloneDeep((wl=Object.keys(ia))==null?void 0:wl[0]);if(((Qa=V==null?void 0:V.data)==null?void 0:Qa.statusCode)===200||((Pl=V==null?void 0:V.data)==null?void 0:Pl.code)===200){if(((jl=(gl=V==null?void 0:V.data)==null?void 0:gl.data)!=null&&jl[Xl]||(Hl=(al=V==null?void 0:V.data)==null?void 0:al.result)!=null&&Hl[Xl])&&(Jl==null?void 0:Jl.length)===1)return await W(((Gl=(Wa=V==null?void 0:V.data)==null?void 0:Wa.data)==null?void 0:Gl[Xl])||((Zl=(Kl=V==null?void 0:V.data)==null?void 0:Kl.result)==null?void 0:Zl[Xl]),M.cloneDeep(Er),Jl,Ea);if((dr=(Sl=V==null?void 0:V.data)==null?void 0:Sl.data)!=null&&dr[Xl]||(il=(ga=V==null?void 0:V.data)==null?void 0:ga.result)!=null&&il[Xl]){let $l=await me(((Bl=(fl=V==null?void 0:V.data)==null?void 0:fl.data)==null?void 0:Bl[Xl])||((Sa=(Ha=V==null?void 0:V.data)==null?void 0:Ha.result)==null?void 0:Sa[Xl]),M.cloneDeep(Er),Jl);return $l&&(he=[...he,...$l]),$l}else{if(!((ll=V==null?void 0:V.data)!=null&&ll.data)){let $l=await le.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,"","",De);$l=$l==null?void 0:$l.map(Ql=>{var Ul;return(Ql==null?void 0:Ql.name)===(Jl==null?void 0:Jl[0])&&(Ql.compData=(Ul=Ql.compData)==null?void 0:Ul.map(Nl=>{var Vr;return(Nl==null?void 0:Nl.key)==="formContent"&&(Nl.contents=(Vr=Nl.contents)==null?void 0:Vr.map(er=>{var Ur,Br;return(er==null?void 0:er.key)===(Jl==null?void 0:Jl[1])&&(er.value=(Br=(Ur=V==null?void 0:V.data)==null?void 0:Ur.result)==null?void 0:Br[Xl==null?void 0:Xl.replaceAll(":","")]),er})),Nl})),Ql});let nr=[];(Te=$l==null?void 0:$l.filter(Ql=>(Ql==null?void 0:Ql.comp)==="Form"))==null||Te.forEach(async Ql=>{let Ul={};for(let Nl in Ql)Nl!=="id"&&(Ul[Nl]=Ql[Nl]);nr.push({id:Ql==null?void 0:Ql.id,value:{pageData:Ul}})}),(nr==null?void 0:nr.length)>0&&await Kr.batchUpdateInsofDataApi({dataList:nr});return}if((Jl==null?void 0:Jl.length)===1){const $l=(pe=(Ka=(oa=V==null?void 0:V.data)==null?void 0:oa.data)==null?void 0:Ka.path)==null?void 0:pe.path;let nr="";(ca=(Ol=(ul=(Pa=(_a=$l==null?void 0:$l.split("("))==null?void 0:_a[1])==null?void 0:Pa.split(")"))==null?void 0:ul[0])==null?void 0:Ol.split(":"))==null||ca.forEach(Nl=>{var Vr,er;nr=nr===""?nr+((Vr=Nl==null?void 0:Nl.replaceAll("'",""))==null?void 0:Vr.trim()):nr+"/"+((er=Nl==null?void 0:Nl.replaceAll("'",""))==null?void 0:er.trim())});let Ql=[(hl=(Ba=(wa=(ua=(Xa=$l==null?void 0:$l.split("<"))==null?void 0:Xa[1])==null?void 0:ua.split(">"))==null?void 0:wa[0])==null?void 0:Ba.replaceAll("'",""))==null?void 0:hl.trim()],Ul;return(tr=(bl=(Fe=V==null?void 0:V.data)==null?void 0:Fe.data)==null?void 0:bl.data)!=null&&tr[Jl==null?void 0:Jl[0]]?Ul=await W((kl=(Ra=(xr=V==null?void 0:V.data)==null?void 0:xr.data)==null?void 0:Ra.data)==null?void 0:kl[Jl==null?void 0:Jl[0]],nr,Jl,Ea):Ul=await ue((Oa=(Ml=V==null?void 0:V.data)==null?void 0:Ml.data)==null?void 0:Oa.data,nr,Ql,De),Ul}else{const $l=(Yr=(Rl=(aa=V==null?void 0:V.data)==null?void 0:aa.data)==null?void 0:Rl.path)==null?void 0:Yr.path;let nr="";return(Re=(Ar=(en=(vn=(Jr=$l==null?void 0:$l.split("("))==null?void 0:Jr[1])==null?void 0:vn.split(")"))==null?void 0:en[0])==null?void 0:Ar.split(":"))==null||Re.forEach(Ul=>{var Nl,Vr;nr=nr===""?nr+((Nl=Ul==null?void 0:Ul.replaceAll("'",""))==null?void 0:Nl.trim()):nr+"/"+((Vr=Ul==null?void 0:Ul.replaceAll("'",""))==null?void 0:Vr.trim())}),await me((an=(Yl=(lr=V==null?void 0:V.data)==null?void 0:lr.data)==null?void 0:Yl.data)==null?void 0:an[Jl==null?void 0:Jl[0]],nr,Jl)}}}}});if(await Promise.all(pa),(he==null?void 0:he.length)>0){let ia=[];he==null||he.forEach(Ca=>{ia!=null&&ia.find(Ce=>{var Fa,Ta,fa,ja;return((Ta=(Fa=Ce==null?void 0:Ce.value)==null?void 0:Fa.pageData)==null?void 0:Ta.name)===((ja=(fa=Ca==null?void 0:Ca.value)==null?void 0:fa.pageData)==null?void 0:ja.name)})||ia.push(Ca)});let Ve=[];ia==null||ia.forEach(Ca=>{var Ta,fa,ja,sa;let Ce=M.cloneDeep(Ca);Ce.value.pageData.compData=(Ta=Ce.value.pageData.compData)==null?void 0:Ta.map(Pe=>{var ma;return(Pe==null?void 0:Pe.key)==="formContent"&&(Pe.contents=(ma=Pe.contents)==null?void 0:ma.map(Qe=>{var $e,ne,We,na;let Oe=($e=M.cloneDeep(he))==null?void 0:$e.find(va=>(va==null?void 0:va.keyType)===(Qe==null?void 0:Qe.key));if(Oe){let va=(na=(We=(ne=Oe.value.pageData.compData)==null?void 0:ne.find(Ae=>(Ae==null?void 0:Ae.key)==="formContent"))==null?void 0:We.contents)==null?void 0:na.find(Ae=>(Ae==null?void 0:Ae.key)===(Qe==null?void 0:Qe.key));Qe.value=va==null?void 0:va.value}return Qe})),Pe}),Ve.push({id:Ce==null?void 0:Ce.id,value:Ce==null?void 0:Ce.value});let Fa=[];(sa=(ja=(fa=Ce==null?void 0:Ce.value)==null?void 0:fa.pageData)==null?void 0:ja.compData)==null||sa.forEach(Pe=>{var ma;(Pe==null?void 0:Pe.key)==="formContent"&&((ma=Pe==null?void 0:Pe.contents)==null||ma.forEach(Qe=>{var Oe,$e,ne,We,na,va;if(($e=(Oe=Qe==null?void 0:Qe.optionUrl)==null?void 0:Oe.menuSelect)!=null&&$e.find(Ae=>Ae==null?void 0:Ae.includes("[")))if(Fa!=null&&Fa.find(Ae=>{var Be,Ye,Ee;return((Be=Ae==null?void 0:Ae.key)==null?void 0:Be.join(","))===((Ee=(Ye=Qe==null?void 0:Qe.optionUrl)==null?void 0:Ye.menuSelect)==null?void 0:Ee.join(","))})){let Ae=(ne=Fa==null?void 0:Fa.find(Be=>{var Ye,Ee,ye;return((Ye=Be==null?void 0:Be.key)==null?void 0:Ye.join(","))===((ye=(Ee=Qe==null?void 0:Qe.optionUrl)==null?void 0:Ee.menuSelect)==null?void 0:ye.join(","))}))==null?void 0:ne.value;Ae.push({key:Qe==null?void 0:Qe.prop,groups:(We=Qe==null?void 0:Qe.optionUrl)==null?void 0:We.groupSelect,value:Qe==null?void 0:Qe.value}),Fa=Fa==null?void 0:Fa.map(Be=>{var Ye,Ee,ye;return((Ye=Be==null?void 0:Be.key)==null?void 0:Ye.join(","))===((ye=(Ee=Qe==null?void 0:Qe.optionUrl)==null?void 0:Ee.menuSelect)==null?void 0:ye.join(","))&&(Be.value=Ae),Be})}else Fa.push({key:(na=Qe==null?void 0:Qe.optionUrl)==null?void 0:na.menuSelect,value:[{key:Qe==null?void 0:Qe.prop,groups:(va=Qe==null?void 0:Qe.optionUrl)==null?void 0:va.groupSelect,value:Qe==null?void 0:Qe.value}]})}))}),(Fa==null?void 0:Fa.length)>0&&(Fa=Fa==null?void 0:Fa.map(Pe=>{var Qe;let ma="";return(Qe=Pe==null?void 0:Pe.key)==null||Qe.forEach(Oe=>{var $e;if(!(Oe!=null&&Oe.includes("[")))ma=ma===""?ma+Oe:ma+"/"+Oe;else{let ne="",We=($e=Oe==null?void 0:Oe.replaceAll("[","").replaceAll("]",""))==null?void 0:$e.split(":");Xe==null||Xe.forEach(na=>{var va;(na==null?void 0:na.name)===(We==null?void 0:We[0])&&((va=na==null?void 0:na.compData)==null||va.forEach(Ae=>{var Be;(Ae==null?void 0:Ae.key)==="formContent"&&((Be=Ae==null?void 0:Ae.contents)==null||Be.forEach(Ye=>{(Ye==null?void 0:Ye.prop)===(We==null?void 0:We[1])&&(ne=Ye==null?void 0:Ye.value)}))}))}),ma=ma+n.value+ne}}),Pe.key=ma,Pe})),Fa==null||Fa.forEach(Pe=>{var $e,ne,We;let ma=($e=De[Pe.key])==null?void 0:$e.find(na=>{var va,Ae,Be,Ye,Ee,ye,$a;return((Ae=(va=na==null?void 0:na.value)==null?void 0:va.pageData)==null?void 0:Ae.name)===((Ee=(Ye=(Be=Pe==null?void 0:Pe.value)==null?void 0:Be[0])==null?void 0:Ye.groups)==null?void 0:Ee[0])&&(($a=(ye=na==null?void 0:na.value)==null?void 0:ye.pageData)==null?void 0:$a.name)!==void 0}),Qe=ma==null?void 0:ma.id,Oe=(ne=ma==null?void 0:ma.value)==null?void 0:ne.pageData;Oe.compData=(We=Oe.compData)==null?void 0:We.map(na=>{var va;return(na==null?void 0:na.key)==="formContent"&&(na.contents=(va=na.contents)==null?void 0:va.map(Ae=>{var Ye;let Be=(Ye=Pe.value)==null?void 0:Ye.find(Ee=>(Ee==null?void 0:Ee.key)===(Ae==null?void 0:Ae.prop));return Be&&(Ae.value=Be.value),Ae})),na}),Ve.push({id:Qe,value:{pageData:Oe}})})});let ya=(de=M.cloneDeep(he))==null?void 0:de[0];(Ve==null?void 0:Ve.length)>0&&await Kr.batchUpdateInsofDataApi({dataList:Ve})}m.setFreshContent(!0)}y.setImportLoading(!1)}catch{Ja.ElMessage.error("方法执行错误,请查看方法!"),y.setImportLoading(!1)}S.value=!0},ae=["createInsofDataApi"],ve=Fl.debounce(async te=>{Z(te)},100),ze=async te=>{var _e,qe,ra;const N=M.cloneDeep(te);let se,G=new WeakMap;te!=null&&te[0].path&&(se=await(N==null?void 0:N.map(async(P,Ke)=>{var Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja;const Le=(Ge=G[P==null?void 0:P.path])==null?void 0:Ge.filter(sa=>{var Pe;return((Pe=sa==null?void 0:sa.key)==null?void 0:Pe.type)==="data"});let Ie="";const de=await le.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,G);Le==null||Le.forEach(sa=>{var Pe,ma,Qe,Oe,$e;((ma=(Pe=sa==null?void 0:sa.value)==null?void 0:Pe.tableData)==null?void 0:ma.算法名称)===((Qe=N==null?void 0:N[Ke])==null?void 0:Qe.method)&&(Ie=($e=(Oe=sa==null?void 0:sa.value)==null?void 0:Oe.tableData)==null?void 0:$e.算法体)});const De=await le.getItemData(P==null?void 0:P.path,sessionStorage.getItem("systemKey"),"",!1,[],!1,G);let Xe="",Ea=(ce=(ee=(V=($=De==null?void 0:De[0])==null?void 0:$.compData)==null?void 0:V.find(sa=>(sa==null?void 0:sa.key)==="header"))==null?void 0:ee.contents)==null?void 0:ce.findIndex(sa=>(sa==null?void 0:sa.prop)==="算法体");return(pa=(he=De==null?void 0:De[0])==null?void 0:he.compData)==null||pa.forEach(sa=>{var Pe;(sa==null?void 0:sa.key)==="tableContents"&&((Pe=sa==null?void 0:sa.contents)==null||Pe.forEach(ma=>{ma!=null&&ma.find(Qe=>Qe===(P==null?void 0:P.method))&&(Xe=ma[Ea])}))}),{buttonName:((ia=N==null?void 0:N[Ke])==null?void 0:ia.method)||((Ca=(ya=(Ve=Le==null?void 0:Le[0])==null?void 0:Ve.value)==null?void 0:ya.tableData)==null?void 0:Ca.算法名称),api:(Ie===""?(Ta=(Fa=(Ce=Le==null?void 0:Le[0])==null?void 0:Ce.value)==null?void 0:Fa.tableData)==null?void 0:Ta.算法体:Ie)||Xe,content:de==null?void 0:de.filter(sa=>sa.comp!=="methodButton"),extraContent:(fa=M.cloneDeep(P.value))==null?void 0:fa.slice(1),methodName:(P==null?void 0:P.path)??"",extraValues:(ja=N==null?void 0:N[Ke])==null?void 0:ja.data}})));const fe=N==null?void 0:N.map(async P=>{var De,Xe,Ea,Ge,$,V;const Ke=(De=resAll.data.result)==null?void 0:De.filter(ee=>{var ce,he,pa;return((ce=ee==null?void 0:ee.key)==null?void 0:ce.parentTable)===""&&((he=ee==null?void 0:ee.key)==null?void 0:he.type)==="method"&&((pa=ee==null?void 0:ee.key)==null?void 0:pa.methodName)===ee.method}),Me=Ke==null?void 0:Ke[0],Le=(Xe=resAll.data.result)==null?void 0:Xe.filter(ee=>{var ce,he;return((ce=ee==null?void 0:ee.key)==null?void 0:ce.type)==="methodData"&&((he=ee==null?void 0:ee.key)==null?void 0:he.tableId)===(Me==null?void 0:Me.id)}),Ie=await le.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,G),de=Le==null?void 0:Le[0];return{buttonName:(Ea=Me==null?void 0:Me.key)==null?void 0:Ea.methodKey,api:($=(Ge=de==null?void 0:de.value)==null?void 0:Ge.tableData)==null?void 0:$[0],content:Ie==null?void 0:Ie.filter(ee=>ee.comp!=="methodButton"),extraContent:(V=M.cloneDeep(P.value))==null?void 0:V.slice(1),methodName:(P==null?void 0:P.method)??""}}),we=(_e=te==null?void 0:te[0])!=null&&_e.path&&((qe=te==null?void 0:te[0])==null?void 0:qe.path)!==""?await Promise.all(se):await Promise.all(fe);l.value=we==null?void 0:we.filter(P=>P==null?void 0:P.extraContent),(ra=l.value)==null||ra.forEach(P=>{var Ke;P.api===""&&((Ke=P.content)==null||Ke.forEach(Me=>{var Le;Me.comp=="Table"&&m.setExtraContents(le.methodTableToContent(Me.compData,(Le=P.extraContent)==null?void 0:Le[0]))}))})};return e.watch(()=>i.itemData,async()=>{w.value=="view"&&!S.value&&await ze(M.cloneDeep(i.itemData)),S.value=!1},{immediate:!0,deep:!0}),(te,N)=>{var se,G,fe;return e.unref(w)!=="edit"?(e.openBlock(),e.createElementBlock("div",U4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((se=l.value)==null?void 0:se.filter(we=>(we==null?void 0:we.buttonName)!=="保存"),we=>{var _e;return e.openBlock(),e.createElementBlock("div",null,[we.api!==""?(e.openBlock(),e.createBlock(e.unref(ys._sfc_main),{key:0,disabled:e.unref(j)===e.unref(E)&&!((_e=we==null?void 0:we.buttonName)!=null&&_e.includes("预览")),class:"calculator-content",modelValue:we.buttonName,onClickTrigger:qe=>e.unref(ve)(we),loading:g.value},null,8,["disabled","modelValue","onClickTrigger","loading"])):e.createCommentVNode("",!0)])}),256)),e.createElementVNode("div",null,[e.unref(q)!==""&&((fe=e.unref(E))==null?void 0:fe[((G=e.unref(E))==null?void 0:G.length)-1])!==e.unref(n)?(e.openBlock(),e.createBlock(e.unref(ys._sfc_main),{key:0,class:"calculator-content",onClickTrigger:I,modelValue:"保存"})):e.createCommentVNode("",!0)]),o.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:0,fileDataList:p.value,onDestroy:R},null,8,["fileDataList"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},W4=pr._export_sfc(q4,[["__scopeId","data-v-063aa9af"]]),G4={};function K4(a,l){return" 567 "}const Y4=pr._export_sfc(G4,[["render",K4]]),J4={class:"module content"},X4={class:"module data"},Z4={class:"module layout"},Q4={class:"form-content"},e2=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.reactive({visible:!1,width:"40%",title:"签名配置"}),o=e.ref("create"),p=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}]),u=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([]),y=()=>({comp:"Signature",compData:[{key:"signTypeList",contents:g.value},{key:"signConfig",contents:m.value}]}),d=A=>{var j;m.value=M.cloneDeep(A),n("change",(j=y())==null?void 0:j.compData)},D=A=>{var j,O;if((A==null?void 0:A.buttonName)==="确认"){const E=M.cloneDeep(A==null?void 0:A.content);switch(o.value){case"create":g.value.push({...E,index:((j=g.value)==null?void 0:j.length)+1});break}n("change",(O=y())==null?void 0:O.compData),i.visible=!1}else i.visible=!1},w=(A,j)=>{var O,E;switch(A){case"create":(O=u.value)==null||O.forEach(_=>{_.value=""}),o.value="create",i.visible=!0;break;case"update":(E=u.value)==null||E.forEach(_=>{_.value=j[_==null?void 0:_.prop]}),o.value="update",i.visible=!0;break;case"delete":g.value.splice(j,1),o.value="delete";break}},q=()=>{i.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,A=>{var j,O;A&&(m.value=((j=A==null?void 0:A.find(E=>E.key==="signConfig"))==null?void 0:j.contents)??{},g.value=((O=A==null?void 0:A.find(E=>E.key==="signTypeList"))==null?void 0:O.contents)??[])},{immediate:!0}),(A,j)=>{const O=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",J4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"签名类型",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=_=>w("create"))},{icon:e.withCtx(()=>[e.createVNode(O,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",X4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(_,x)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:x},[e.createElementVNode("span",null,e.toDisplayString(_==null?void 0:_.label),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>w("update",{..._,index:x+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>w("delete",x)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",Z4,[e.createVNode(pl.ssForm,{rowContents:c.value,onChange:d},null,8,["rowContents"])])]),e.createVNode($r.ssDialog,{visible:i.visible,title:i.title,onBeforeDestroy:q,width:i.width},{default:e.withCtx(()=>[e.createElementVNode("div",Q4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,key:u.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:p.value,onOnButtonClick:D},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),a2=pr._export_sfc(e2,[["__scopeId","data-v-487e0536"]]),l2=e.defineComponent({__name:"index",props:{stepConfig:{type:Object,default:{}},stepList:{type:Array,default:()=>[]}},emits:["clickStep","clickTrigger","changeTrigger"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(0),o=e.computed(()=>{var y,d;return(y=r==null?void 0:r.stepConfig)!=null&&y.allowTrigger?i.value:(d=r==null?void 0:r.stepConfig)==null?void 0:d.active}),p=(y,d)=>{i.value=d-1,n("clickStep",y,d)};e.onMounted(()=>{var y;n("clickStep",(y=r==null?void 0:r.stepList)==null?void 0:y[0],0)});const c=y=>pl.getComponent(y),u=()=>{var d;const y=(d=r==null?void 0:r.stepList)==null?void 0:d.find((D,w)=>w+1===o.value);return console.log("findStep",y),y?y==null?void 0:y.children:[]},m=y=>{n("clickTrigger",y)},g=y=>{n("changeTrigger",y)};return(y,d)=>{var q,A,j,O,E;const D=e.resolveComponent("el-step"),w=e.resolveComponent("el-steps");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(w,{direction:(q=a.stepConfig)==null?void 0:q.direction,active:o.value,"finish-status":"success",simple:(A=a.stepConfig)==null?void 0:A.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)=>(e.openBlock(),e.createBlock(D,{key:x,class:"step-item",onClick:b=>p(_,x+1)},{title:e.withCtx(()=>[e.renderSlot(y.$slots,"title",{title:_==null?void 0:_.title},void 0,!0)]),description:e.withCtx(()=>[e.renderSlot(y.$slots,"description",{descriptions:_==null?void 0:_.description},void 0,!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["direction","active","simple","align-center"]),(O=a.stepConfig)!=null&&O.allowTrigger&&((E=a.stepConfig)!=null&&E.active)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(u(),(_,x)=>(e.openBlock(),e.createElementBlock("div",{key:x,class:"step-cont-wrap"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(c(_==null?void 0:_.type)),{modelValue:_.value,"onUpdate:modelValue":b=>_.value=b,onClickTrigger:m,onChangeTrigger:g,content:_==null?void 0:_.content},e.createSlots({_:2},[e.renderList(y.$slots,(b,S)=>({name:S,fn:e.withCtx(I=>[e.renderSlot(y.$slots,S,e.mergeProps({ref_for:!0},I||{}),void 0,!0)])}))]),1064,["modelValue","onUpdate:modelValue","content"]))]))),128)):e.createCommentVNode("",!0)],64)}}}),r2=pr._export_sfc(l2,[["__scopeId","data-v-a30ff621"]]),n2=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]}},emits:["clickStep"],setup(a,{emit:l}){const r=a,n=l,i=e.ref({}),o=e.ref([]),p=(c,u)=>{n("clickStep",c,u)};return e.watch(()=>r==null?void 0:r.itemData,c=>{var y,d,D,w;i.value={direction:"horizontal",simple:!1,alignCenter:!0,allowTrigger:!0};let u=((y=c==null?void 0:c.find(q=>(q==null?void 0:q.key)==="stepName"))==null?void 0:y.contents)??[],m=[];(D=(d=c==null?void 0:c.find(q=>(q==null?void 0:q.key)==="header"))==null?void 0:d.contents)==null||D.forEach(q=>{m.push({label:q==null?void 0:q.label,prop:q==null?void 0:q.prop,name:q==null?void 0:q.prop,type:"text",disabled:!0})});let g=((w=c==null?void 0:c.find(q=>(q==null?void 0:q.key)==="tableContents"))==null?void 0:w.contents)??[];u=u==null?void 0:u.map((q,A)=>{let j=m==null?void 0:m.map(O=>{var E;return{...O,value:(E=g==null?void 0:g[A])==null?void 0:E[O==null?void 0:O.prop]}});return{title:q,description:j}}),o.value=u},{immediate:!0,deep:!0}),(c,u)=>{const m=e.resolveComponent("svg-icon");return e.openBlock(),e.createBlock(r2,{stepConfig:i.value,stepList:o.value,onClickStep:p},{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(pl.ssForm,{ref:"formRef",rowContents:g,showOperator:!0,isEnableWrap:!1,isEdit:!1},null,8,["rowContents"])]),_:1},8,["stepConfig","stepList"])}}}),i2=e.defineComponent({__name:"index",props:{activities:{type:Array,default:()=>[]},timeLineConfig:{type:Object,default:()=>{}}},setup(a){return(l,r)=>{const n=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,(o,p)=>(e.openBlock(),e.createBlock(n,{key:p,timestamp:o.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:o==null?void 0:o.content,timestamp:o==null?void 0:o.timestamp},void 0,!0)]),_:2},1032,["timestamp","placement","center","type","color","size","icon","hollow"]))),128))]),_:3})}}}),o2=pr._export_sfc(i2,[["__scopeId","data-v-4172a886"]]),t2={class:"line-content"},s2={class:"line-time"},c2=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(a){const l=a,r=e.ref({}),n=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,i=>{var o,p;n.value=(o=i==null?void 0:i.find(c=>(c==null?void 0:c.key)==="timeLineList"))==null?void 0:o.contents,r.value=(p=i==null?void 0:i.find(c=>(c==null?void 0:c.key)==="timeLineConfig"))==null?void 0:p.contents},{immediate:!0}),(i,o)=>(e.openBlock(),e.createBlock(o2,{activities:n.value,timeLineConfig:r.value},{content:e.withCtx(({content:p,timestamp:c})=>[e.createElementVNode("span",t2,e.toDisplayString(p),1),e.createElementVNode("span",s2,e.toDisplayString(c),1)]),_:1},8,["activities","timeLineConfig"]))}}),u2=pr._export_sfc(c2,[["__scopeId","data-v-b4d9deed"]]),d2={class:"tabs-content"},p2=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 r=a,n=l,i=e.ref();e.watch(()=>r==null?void 0:r.itemData,()=>{i.value=r==null?void 0:r.itemData},{immediate:!0,deep:!0});const o=d=>{n("change",d)},p=(d,D)=>{n("contentChange",d,D)},c=d=>{n("pageChange",d)},u=d=>{n("rowClick",d)},m=(d,D)=>{n("routeUrl",d,D)},g=d=>{n("clickTrigger",d)},y=(d,D)=>{n("clickMainKey",d,D)};return(d,D)=>{var w,q;return e.openBlock(),e.createElementBlock("div",d2,[(w=i.value)!=null&&w.length?(e.openBlock(),e.createBlock(pl.ssTab,{tabsContents:i.value,key:(q=i.value)==null?void 0:q.length},{pane:e.withCtx(({tab:A,index:j})=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)(A==null?void 0:A.comp)),{related:A==null?void 0:A.relatedTables,compNames:A==null?void 0:A.nameContents,compName:A==null?void 0:A.name,cacheNewData:r==null?void 0:r.cacheNewData,isDevMode:a.isDevMode,itemData:A==null?void 0:A.compData,childItemData:A==null?void 0:A.itemChildData,onChange:o,calculator:A==null?void 0:A.calculatorFilters,index:(A==null?void 0:A.id)??j,config:{showIndex:A==null?void 0:A.showIndex,allowMove:A==null?void 0:A.allowMove,viewport:A==null?void 0:A.viewport,status:A==null?void 0:A.status},onContentChange:p,onPageChange:c,onRowClick:u,onRouteUrl:m,parentTableId:A==null?void 0:A.tableId,allMapContents:a.allMapContents,children:A==null?void 0:A.children,level:1,onClickTrigger:g,onClickMainKey:y},null,40,["related","compNames","compName","cacheNewData","isDevMode","itemData","childItemData","calculator","index","config","parentTableId","allMapContents","children"]))]),_:1},8,["tabsContents"])):e.createCommentVNode("",!0)])}}}),f2=pr._export_sfc(p2,[["__scopeId","data-v-71516232"]]),h2={class:"type-select"},v2=["onClick"],m2={class:"list-icon"},y2={__name:"modelSelect",setup(a){const l=ti(M.pinia),{itemData:r}=M.storeToRefs(l),n=i=>{const o=M.cloneDeep(r.value);o.push({comp:i.comp,name:i.name,compData:[]}),l.setItemData(o)};return(i,o)=>{const p=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",h2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(Su),(c,u)=>(e.openBlock(),e.createElementBlock("div",{class:"type-list",key:u},[e.createElementVNode("div",{class:"list-content",onClick:m=>n(c)},[e.createElementVNode("div",m2,[e.createVNode(p,{name:c.icon},null,8,["name"])]),e.createElementVNode("div",null,e.toDisplayString(c.name),1)],8,v2)]))),128))])}}},g2=pr._export_sfc(y2,[["__scopeId","data-v-91799bf8"]]),b2={class:"fill-content"},k2={class:"operate-content"},x2={class:"collapse-title-content"},w2={class:"collapse-title-item"},_2={key:1},S2=["onClick"],E2={class:"icon-content"},C2={key:0,class:"edit-content"},D2=["onClick"],T2={class:"comp-child"},B2={__name:"modelFill",setup(a){const l=ti(M.pinia),{itemData:r,originalData:n}=M.storeToRefs(l),i=e.ref([]);e.ref([]);const o=e.ref([]),p=e.ref([]),c=D=>{var q;let w=(q=M.cloneDeep(p.value))==null?void 0:q.map((A,j)=>(D===j&&(A.content=!0),A));p.value=w},u=D=>{var q;let w=(q=M.cloneDeep(p.value))==null?void 0:q.map((A,j)=>(D===j&&(A.content=!1),A));p.value=w,i.value=M.cloneDeep(r.value)},m=(D,w)=>{var O;let q=(O=M.cloneDeep(p.value))==null?void 0:O.map((E,_)=>(D===_&&(E.content=!1),E));p.value=q;const A=M.cloneDeep(r.value),j=A==null?void 0:A.filter((E,_)=>(_===D&&(E.name=w),E));l.setOriginalData(j),l.setItemData(j)};e.watch(()=>r.value,()=>{var D,w,q;!r.value||((D=r.value)==null?void 0:D.length)===0?i.value=[]:i.value=(w=M.cloneDeep(r.value))==null?void 0:w.filter(A=>(A==null?void 0:A.comp)!=="methodButton"),o.value=i.value,p.value=(q=M.cloneDeep(o.value))==null?void 0:q.map((A,j)=>({id:j,content:!1}))},{deep:!0,immediate:!0});const g=D=>$i(D),y=(D,w,q)=>{var j,O;if(!D)return;let A=M.cloneDeep(r.value);A=(j=A==null?void 0:A.map((E,_)=>(_===q&&(E.compData=D),E)))==null?void 0:j.filter(E=>(E==null?void 0:E.comp)!=="methodButton"),p.value=(O=M.cloneDeep(A))==null?void 0:O.map((E,_)=>({id:_,content:!1})),l.setOriginalData(A),l.setItemData(A)},d=D=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const w=M.cloneDeep(r.value),q=w==null?void 0:w.filter((A,j)=>j!==D);l.setOriginalData(q),l.setItemData(q),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(D,w)=>{const q=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",b2,[w[1]||(w[1]=e.createElementVNode("div",{class:"fill-operate"},e.toDisplayString("操作栏"),-1)),e.createElementVNode("div",k2,[e.createVNode(pc.default,{class:"collapse-content",collapseContents:i.value},{title:e.withCtx(({item:A,index:j})=>{var O,E,_,x,b,S,I,R,re,X;return[e.createElementVNode("div",x2,[e.createElementVNode("div",w2,[(E=(O=p.value)==null?void 0:O.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:A.name&&A.name!==""?"8px":"0px"})},e.toDisplayString(A.name),5)),(x=(_=p.value)==null?void 0:_.find(me=>me.id===j))!=null&&x.content?(e.openBlock(),e.createElementBlock("div",_2,[e.createVNode(pl.ssInput,{modelValue:A.name,"onUpdate:modelValue":me=>A.name=me,onClick:w[0]||(w[0]=e.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):e.createCommentVNode("",!0),(S=(b=p.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(q,{name:"Edit",style:{width:"16px",height:"16px"}})],8,S2))]),e.createElementVNode("div",E2,[(R=(I=p.value)==null?void 0:I.find(me=>me.id===j))!=null&&R.content?(e.openBlock(),e.createElementBlock("div",C2,[e.createVNode(q,{name:"Cancel",style:{width:"16px",height:"16px"},class:"icon-content",onClick:e.withModifiers(me=>u(j),["stop"])},null,8,["onClick"]),e.createVNode(q,{name:"Save",onClick:e.withModifiers(me=>m(j,A.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):e.createCommentVNode("",!0),(X=(re=p.value)==null?void 0:re.find(me=>me.id===j))!=null&&X.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,onClick:e.withModifiers(me=>d(j),["stop"]),class:"icon-content"},[e.createVNode(q,{name:"Delete",style:{width:"16px",height:"16px"}})],8,D2))])])]}),content:e.withCtx(({item:A,index:j})=>{var O,E;return[e.createElementVNode("div",T2,[e.createTextVNode(e.toDisplayString(g(A.comp+"Operate"))+" ",1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g(A.comp+"Operate")),{itemContents:A==null?void 0:A.compData,originalItemContents:(E=(O=o.value)==null?void 0:O.find((_,x)=>x===j))==null?void 0:E.compData,onChange:_=>y(_,A,j)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},N2=pr._export_sfc(B2,[["__scopeId","data-v-a46a44b9"]]),A2={key:0,class:"show-content"},z2={style:{display:"flex"}},M2={__name:"modelShow",setup(a){const l=ti(M.pinia),{itemData:r}=M.storeToRefs(l),n=e.ref([]);e.watch(()=>r.value,()=>{var o;!r.value||((o=r.value)==null?void 0:o.length)===0?n.value=[]:n.value=M.cloneDeep(r.value)},{deep:!0,immediate:!0});const i=o=>$i(o);return(o,p)=>{var c;return((c=n.value)==null?void 0:c.length)>0?(e.openBlock(),e.createElementBlock("div",A2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.value,(u,m)=>(e.openBlock(),e.createElementBlock("div",{class:"item-content",key:m},[e.createElementVNode("div",z2,e.toDisplayString(u.name),1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i(u.comp)),{itemData:u==null?void 0:u.compData,childItemData:u==null?void 0:u.itemChildData,key:m},null,8,["itemData","childItemData"]))]))),128))])):e.createCommentVNode("",!0)}}},I2=pr._export_sfc(M2,[["__scopeId","data-v-3f3e863e"]]),O2={class:"tabs-header"},L2={class:"tabs-list"},R2={class:"tab-name"},$2={class:"tab-actions"},V2=["onClick"],F2=["onClick"],P2=["onClick"],j2={class:"model-operate"},H2={class:"model-select",style:{display:"unset"}},U2={class:"existing-components"},q2={class:"component-list"},W2=["onClick"],G2={class:"component-info"},K2={class:"component-type"},Y2={class:"component-name"},J2={class:"model-fill"},X2={__name:"operate",props:{itemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref([]),o=e.ref(!1),p=e.ref(""),c=e.ref({title:""}),u=e.ref(-1),m=e.ref(!1),g=e.ref(-1),y=e.ref(new WeakMap),d=e.ref(null),D=ti(M.pinia),{itemData:w}=M.storeToRefs(D),q=()=>{p.value="新增标签页",c.value.title="",u.value=-1,o.value=!0},A=te=>{p.value="修改标签页",c.value.title=i.value[te].title,u.value=te,o.value=!0},j=te=>{const N=_(te);y.value.delete(N),i.value.splice(te,1),ze()},O=()=>{if(c.value.title.trim()){if(u.value===-1){const te={title:c.value.title,value:c.value.title,label:c.value.title,children:[],id:E()};i.value.push(te)}else i.value[u.value].title=c.value.title,i.value[u.value].value=c.value.title,i.value[u.value].label=c.value.title;o.value=!1,ze()}},E=()=>`tab_${Date.now()}_${Math.random().toString(36).substr(2,9)}`,_=te=>{const N=i.value[te];return N.id||(N.id=E()),N.id},x=te=>{var G;g.value=te;const N=_(te);d.value=M.cloneDeep(w.value);let se=y.value.get(N);!se&&((G=i.value[te].children)==null?void 0:G.length)>0&&(se=R(i.value[te].children)),se?D.setItemData(M.cloneDeep(se)):D.setItemData([]),m.value=!0},b=e.computed(()=>{const te=M.useModelComp(M.pinia),N=M.storeToRefs(te).itemData.value;return console.log("可用组件数据",N),!N||!Array.isArray(N)?[]:N.filter(se=>{var G;if(se.comp==="Tabs"&&g.value>=0){const fe=_(g.value);if((G=se.compData)==null?void 0:G.some(_e=>{var qe;return _e.key==="stepList"&&((qe=_e.contents)==null?void 0:qe.some(ra=>ra.id===fe))}))return!1}return!0})}),S=te=>({Table:"表格",Form:"表单",Tabs:"标签页",Chart:"图表",Card:"卡片"})[te]||te,I=te=>{var N;try{const se=M.cloneDeep(te);se.id=Date.now()+Math.random(),se.comp==="Tabs"&&((N=se.compData)==null||N.forEach(fe=>{fe.key==="stepList"&&fe.contents&&fe.contents.forEach(we=>{we.id=E()})}));const G=M.cloneDeep(w.value);G.push(se),D.setItemData(G)}catch(se){console.error("添加组件失败:",se)}},R=te=>te.map(N=>{var se;switch(N.type){case"form":return{comp:"Form",name:N.value||"表单",compData:re(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)||[]}}}),re=te=>{if(!te)return[];const N=[];return te.rowContents&&N.push({key:"formContent",contents:te.rowContents}),te.buttonValue&&N.push({key:"formButton",contents:te.buttonValue}),typeof te.isEnableWrap<"u"&&N.push({key:"enableWrap",contents:te.isEnableWrap}),N},X=te=>[],me=()=>{if(g.value>=0&&g.value<i.value.length){const te=_(g.value);y.value.set(te,M.cloneDeep(w.value)),i.value[g.value].children=W(w.value),console.log("保存后的数据",W(w.value))}m.value=!1,g.value=-1,d.value=null,ze()},ue=()=>{d.value&&D.setItemData(M.cloneDeep(d.value)),m.value=!1,g.value=-1,d.value=null},U=()=>{m.value&&ue()},W=te=>{if(!Array.isArray(te))throw new Error("sourceData must be an array");return te.map((N,se)=>{if(!N||typeof N!="object")return N;const{comp:G,name:fe,compData:we}=N;switch(G){case"Form":return{type:"form",content:Z(we||[]),value:"表单"};case"Table":return{type:"table",content:ae(we||[]),value:"表格"};default:return{type:"xxx",content:ve(we||[]),value:""}}})},Z=te=>{const N={formRules:{},rowContents:[],buttonValue:[],rowValues:[],isEnableWrap:!0,isRowFlex:!0,isButtonRow:!0,isEdit:!0,isStartJustify:!0},se={formContent:"rowContents",enableWrap:"isEnableWrap",formButton:"buttonValue"};return te.forEach((G,fe)=>{if(!G||typeof G!="object"){console.warn(`Invalid config at index ${fe}:`,G);return}const{key:we,contents:_e}=G,qe=se[we];if(!qe){console.warn(`Unknown Form config key: ${we}`);return}we==="enableWrap"?N[qe]=!!_e:N[qe]=Array.isArray(_e)?_e:[]}),N},ae=te=>{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 te.forEach((G,fe)=>{if(!G||typeof G!="object"){console.warn(`Invalid config at index ${fe}:`,G);return}const{key:we,contents:_e}=G,qe=se[we];if(!qe){console.warn(`Unknown Table config key: ${we}`);return}N[qe]=Array.isArray(_e)?_e:[]}),N},ve=te=>(console.log("Default conversion logic - to be implemented"),{originalData:te,processed:!1,componentType:"unknown"}),ze=()=>{const te=[{key:"stepList",contents:i.value}];n("change",te)};return e.watch(()=>r.itemContents,te=>{if(te&&te.length>0){const N=te.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}),(te,N)=>{const se=e.resolveComponent("svg-icon"),G=e.resolveComponent("el-input"),fe=e.resolveComponent("el-form-item"),we=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",O2,[N[6]||(N[6]=e.createElementVNode("h4",null,"标签页管理",-1)),e.createElementVNode("button",{onClick:q},[e.createVNode(se,{name:"Plus",style:{width:"14px",height:"14px","margin-right":"4px"}}),N[5]||(N[5]=e.createTextVNode(" 新增标签页 "))])]),e.createElementVNode("div",L2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(_e,qe)=>(e.openBlock(),e.createElementBlock("div",{class:"tab-item",key:qe},[e.createElementVNode("span",R2,e.toDisplayString(_e.title),1),e.createElementVNode("div",$2,[e.createElementVNode("button",{onClick:ra=>A(qe)},"修改标题",8,V2),e.createElementVNode("button",{onClick:ra=>x(qe)},"布局调整",8,F2),e.createElementVNode("button",{onClick:ra=>j(qe)},"删除",8,P2)])]))),128))]),e.createVNode($r.ssDialog,{modelValue:o.value,"onUpdate:modelValue":N[2]||(N[2]=_e=>o.value=_e),title:p.value,onBeforeDestroy:N[3]||(N[3]=_e=>o.value=!1)},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:N[1]||(N[1]=_e=>o.value=!1)},"取消"),e.createElementVNode("button",{type:"primary",onClick:O},"确定")]),default:e.withCtx(()=>[e.createVNode(we,{model:c.value,"label-width":"80px"},{default:e.withCtx(()=>[e.createVNode(fe,{label:"标签名称",required:""},{default:e.withCtx(()=>[e.createVNode(G,{modelValue:c.value.title,"onUpdate:modelValue":N[0]||(N[0]=_e=>c.value.title=_e),placeholder:"请输入标签页名称"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue","title"]),e.createVNode($r.ssDialog,{modelValue:m.value,"onUpdate:modelValue":N[4]||(N[4]=_e=>m.value=_e),title:"布局调整",fullScreen:"",onBeforeDestroy:U},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:ue},"取消"),e.createElementVNode("button",{onClick:me},"确定")]),default:e.withCtx(()=>[e.createElementVNode("div",j2,[e.createElementVNode("div",H2,[e.createVNode(g2),e.createElementVNode("div",U2,[N[8]||(N[8]=e.createElementVNode("h5",null,"添加已有组件",-1)),e.createElementVNode("div",q2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,_e=>(e.openBlock(),e.createElementBlock("div",{key:_e.id,class:"component-item",onClick:qe=>I(_e)},[e.createElementVNode("div",G2,[e.createElementVNode("span",K2,e.toDisplayString(S(_e.comp)),1),e.createElementVNode("span",Y2,e.toDisplayString(_e.name),1)]),N[7]||(N[7]=e.createElementVNode("button",{class:"add-btn"},"添加",-1))],8,W2))),128))])])]),(e.openBlock(),e.createElementBlock("div",{class:"model-show",key:te.innerWidth},[e.createVNode(I2)])),e.createElementVNode("div",J2,[e.createVNode(N2)])])]),_:1},8,["modelValue"])])}}},Z2=pr._export_sfc(X2,[["__scopeId","data-v-9096ed0d"]]);function Q2(){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 ev(a){return{type:"line",color:["#5070DD","#B6D634","#505372","#FF994E","#0CA8DF","#FFD10A","#FB628B","#8466C1","#3EBE95"],...a}}function av(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{top:"3%",left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",data:[]},yAxis:[{type:"value"}],series:[]}}function lv(a){return{type:"bar",barWidth:"60%",showBackground:!0,backgroundStyle:{color:"rgba(180, 180, 180, 0.1)"},itemStyle:{color:new Fl.LinearGradient(0,0,0,1,[{offset:0,color:"#94C2FD"},{offset:.7,color:"#6491E1"},{offset:1,color:"#3264C8"}])},emphasis:{itemStyle:{color:new Fl.LinearGradient(0,0,0,1,[{offset:0,color:"#3264C8"},{offset:.7,color:"#6491E1"},{offset:1,color:"#94C2FD"}])}},...a}}function rv(){return{title:{text:"",left:"center"},tooltip:{trigger:"item"},series:[]}}function nv(a){return{type:"pie",color:["#5070DD","#B6D634","#505372","#FF994E","#0CA8DF","#FFD10A","#FB628B","#8466C1","#3EBE95"],radius:["40%","70%"],itemStyle:{borderRadius:6,borderColor:"#fff",borderWidth:2},label:{show:!0,formatter:function(l){return"{b|"+l.name+`}
|
|
26
|
-
{c|`+l.value+"}"},rich:{b:{fontFamily:"SourceHanSansSC",fontWeight:"bold",fontSize:14,color:"#333"},c:{fontFamily:"SourceHanSansSC",fontSize:12,color:"#666"},d:{fontFamily:"SourceHanSansSC",fontSize:12,color:"#999"}}},emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},...a}}const iv=()=>({title:{text:"",left:"center"},tooltip:{trigger:"item"},xAxis:{scale:!0},yAxis:{scale:!0},series:[]}),ov=a=>({type:"scatter",symbolSize:20,...a}),In={Line:{initBaseoptions:Q2,initSeries:ev},Bar:{initBaseoptions:av,initSeries:lv},Pie:{initBaseoptions:rv,initSeries:nv},Scatter:{initBaseoptions:iv,initSeries:ov}},tv=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";const m=l==null?void 0:l.map(d=>d==null?void 0:d.prop);let g=[];if(m==null||m.forEach(d=>{var D;g.push((D=r==null?void 0:r[0])==null?void 0:D[d])}),!m||!g)return u;u.xAxis.data=m;const y=c({data:g});return u.series.push(y),u},sv=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";const m=l==null?void 0:l.map(d=>d==null?void 0:d.prop);let g=[];if(m==null||m.forEach(d=>{var D;g.push((D=r==null?void 0:r[0])==null?void 0:D[d])}),!m||!g)return u;u.xAxis.data=m;const y=c({data:g});return u.series.push(y),u},cv=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";const m=l==null?void 0:l.map(D=>D==null?void 0:D.prop);let g=[];if(m==null||m.forEach(D=>{var w;g.push((w=r==null?void 0:r[0])==null?void 0:w[D])}),!m||!g)return u;const y=[];for(let D=0;D<m.length;D++){const w=m[D],q=g[D];y.push({name:w,value:q})}const d=c({data:y});return u.series.push(d),u},uv=({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";let m=[];const g=l==null?void 0:l.map(D=>D==null?void 0:D.prop);if(m=g==null?void 0:g.map(D=>{var q;let w=[];return w.push(D),w.push((q=r==null?void 0:r[0])==null?void 0:q[D]),w}),!m)return u;const d=c({data:m});return u.series.push(d),u},dv=async(a=[])=>{var c,u,m,g,y;const l=((c=a==null?void 0:a.find(d=>d.key==="ChartType"))==null?void 0:c.contents)??{};let r=((u=a==null?void 0:a.find(d=>d.key==="header"))==null?void 0:u.contents)??[],n=((m=a==null?void 0:a.find(d=>d.key==="tableContents"))==null?void 0:m.contents)??[],i=((g=a==null?void 0:a.find(d=>d.key==="calculator"))==null?void 0:g.contents)??[];if((i==null?void 0:i.length)>0){i=i==null?void 0:i.map(D=>({methods:D==null?void 0:D.calculatorFilter,functionName:D==null?void 0:D.functionName,functionRelatedWords:D==null?void 0:D.functionRelatedWords}));let d=await No([],i,[],"Auto",[],[]);r=(y=d==null?void 0:d.xAxis)==null?void 0:y.map(D=>({label:D,prop:D})),n=d==null?void 0:d.yAxis}else if(r!=null&&r.some(d=>d==null?void 0:d.functionName)){let d=r==null?void 0:r.filter(q=>q==null?void 0:q.functionName);d=d==null?void 0:d.map(async q=>{let A={methods:q==null?void 0:q.calculatorFilter,functionName:q==null?void 0:q.functionName,functionRelatedWords:q==null?void 0:q.functionRelatedWords};return A=await No(q,[A],[],"Auto",[],[]),{name:q==null?void 0:q.prop,value:A==null?void 0:A.value}});let D=await Promise.all(d),w={};D==null||D.forEach(q=>{var A;w[q==null?void 0:q.name]=((A=q==null?void 0:q.value)==null?void 0:A.toString())??""}),n=[w]}let{type:o}=l,p={};return o==="Line"&&(p=await tv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),o==="Bar"&&(p=await sv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),o==="Pie"&&(p=await cv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),o==="Scatter"&&(p=await uv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),p},pv=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,r=e.ref({});e.onMounted(async()=>{const i=l==null?void 0:l.itemData;r.value=await dv(i)});const n=e.computed(()=>(l==null?void 0:l.height)||"300px");return(i,o)=>(e.openBlock(),e.createElementBlock("div",{class:"eCharts",style:e.normalizeStyle({height:n.value})},[e.createVNode(ad.ssChart,{optionContents:r.value},null,8,["optionContents"])],4))}}),fv=pr._export_sfc(pv,[["__scopeId","data-v-d4c081e8"]]),hv={class:"chart-module layout"},vv={class:"chart-module content"},mv={class:"chart-module content"},yv={class:"form-content"},gv={class:"dialog-footer"},bv={class:"form-content"},kv={class:"dialog-footer"},xv={class:"form-content"},wv={class:"dialog-footer"},_v=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.reactive({visible:!1,width:"840",title:"基础配置"}),o=e.ref([]),p=()=>[{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({}),u=Ie=>{var de;o.value=p(),(de=o.value)==null||de.forEach(De=>{var Ea;const Xe=De==null?void 0:De.prop;De.value=(Ea=c==null?void 0:c.value)==null?void 0:Ea[Xe]}),i.visible=!0},m=Ie=>{c.value=Ie},g=()=>{var Ie;i.visible=!1,n("change",(Ie=Me())==null?void 0:Ie.compData)},y=e.reactive({visible:!1,width:"840",title:"数据配置"}),d=e.ref([]),D=()=>[{label:"菜单选项",prop:"menu",type:"cascader",contents:[]},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],w=e.ref({}),q=()=>{const Ie=d.value,de=M.cloneDeep(Ie);return de==null||de.forEach(De=>{var Ea;const Xe=De==null?void 0:De.prop;De.value=(Ea=w.value)==null?void 0:Ea[Xe]}),de},A=Ie=>{var De;w.value=Ie;const de=q();d.value=de,n("change",(De=Me())==null?void 0:De.compData)},j=async Ie=>{const de=await le.getMenusContent(),De=q();De==null||De.forEach(Xe=>{(Xe==null?void 0:Xe.prop)==="menu"&&(Xe.contents=de)}),d.value=De,y.visible=!0,await _e(w.value.menu),await P(w.value.group)},O=e.reactive({visible:!1,width:"840",title:"详情页配置"}),E=e.ref([]),_=()=>[{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:[]}],x=e.ref({}),b=()=>{const Ie=E.value,de=M.cloneDeep(Ie);return de==null||de.forEach(De=>{var Ea;const Xe=De==null?void 0:De.prop;De.value=(Ea=x.value)==null?void 0:Ea[Xe]}),de},S=Ie=>{var De;x.value=Ie;const de=b();E.value=de,n("change",(De=Me())==null?void 0:De.compData)},I=async Ie=>{await U();const de=M.cloneDeep(R.value),De=b();De==null||De.forEach(Xe=>{var Ge;const Ea=Xe==null?void 0:Xe.prop;Xe.value=(Ge=x==null?void 0:x.value)==null?void 0:Ge[Ea],Ea==="mainKey"&&(Xe.contents=de)}),E.value=De,O.visible=!0},R=e.ref([]),re=e.ref([]),X=e.ref({}),me=e.ref({}),ue=()=>{const{compData:Ie}=G.value||{},de=Ie==null?void 0:Ie.find(ee=>{const{key:ce}=ee;return ce==="header"}),De=(de==null?void 0:de.contents)||[],Xe=De==null?void 0:De.filter((ee,ce)=>{const{label:he}=ee;return he!=="操作"}),Ea=Xe==null?void 0:Xe.findIndex((ee,ce)=>{const{isMainKey:he}=ee;return he});if(Ea<0)return[];const Ge=Ie==null?void 0:Ie.find(ee=>{const{key:ce}=ee;return ce==="tableContents"}),$=(Ge==null?void 0:Ge.contents)||[];return $==null?void 0:$.map(ee=>{const ce=ee==null?void 0:ee[0];let he=Ea;Ja.isObject(ce)&&(ce!=null&&ce.id)&&(he=he+1);const pa=ee==null?void 0:ee[he];return{label:pa,value:pa}})},U=async()=>{const Ie=await ue();R.value=Ie},W=async Ie=>{const de=sessionStorage.getItem("systemKey");return await le.getItemData(Ie,de,"")},Z=async Ie=>{const de=Ie;re.value=de==null?void 0:de.map(De=>{const{name:Xe}=De;return X.value[Xe]=De,{label:Xe,value:Xe}})},ae=Ie=>{const{comp:de,compData:De}=me.value||{};if(de==="Table"){let Xe=b();Xe=Xe.filter(Ea=>{const{prop:Ge}=Ea;return Ge!=="formItems"}),qe(Xe,De),E.value=Xe}},ve=async()=>{var De,Xe;const Ie=(De=x==null?void 0:x.value)==null?void 0:De.mainKey,de=(Xe=w==null?void 0:w.value)==null?void 0:Xe.menu;if(Ie){const Ge=`${de==null?void 0:de.join("/")}^${Ie}`,$=await W(Ge);await Z($);const V=b();V==null||V.forEach(ee=>{(ee==null?void 0:ee.prop)==="group"&&(ee.contents=re.value)}),E.value=V}};e.watch(()=>{var Ie;return(Ie=x==null?void 0:x.value)==null?void 0:Ie.mainKey},async(Ie,de)=>{Ie!=de&&Ie&&await ve()});const ze=async Ie=>{const de=X.value[Ie];me.value=de,await ae()};e.watch(()=>{var Ie;return(Ie=x==null?void 0:x.value)==null?void 0:Ie.group},async(Ie,de)=>{Ie!=de&&Ie&&ze(Ie)});const te=async()=>{var de;await ve();const Ie=(de=x.value)==null?void 0:de.group;await ze(Ie)},N=e.ref([]),se=e.ref({}),G=e.ref({}),fe=async Ie=>{const de=Ie==null?void 0:Ie.join("/"),De=sessionStorage.getItem("systemKey");return await le.getItemData(de,De,"")},we=async Ie=>{const de=await fe(Ie);N.value=de==null?void 0:de.map(De=>{const{name:Xe}=De;return se.value[Xe]=De,{label:Xe,value:Xe}})},_e=async(Ie,de)=>{await we(Ie);const De=q();De==null||De.forEach(Xe=>{(Xe==null?void 0:Xe.prop)==="group"&&(Xe.contents=N.value)}),d.value=De};e.watch(()=>{var Ie;return(Ie=w==null?void 0:w.value)==null?void 0:Ie.menu},async(Ie,de)=>{const De=Ie==null?void 0:Ie.join("/"),Xe=de==null?void 0:de.join("/");De!=Xe&&await _e(Ie)});const qe=(Ie,de)=>{const De=de==null?void 0:de.find($=>{const{key:V}=$;return V==="header"}),Xe=(De==null?void 0:De.contents)||[],Ea=Xe==null?void 0:Xe.filter(($,V)=>{const{label:ee}=$;return ee!=="操作"}),Ge=Ea==null?void 0:Ea.map(($,V)=>{const{label:ee}=$;return{label:ee,value:V}});Ie==null||Ie.forEach($=>{const V=$==null?void 0:$.prop;(V==="nameCol"||V==="valueCol")&&($.contents=Ge)})},ra=Ie=>{const{comp:de,compData:De}=G.value||{};if(de==="Table"){w.value.formItems=[];let Xe=q();Xe=Xe.filter(Ea=>{const{prop:Ge}=Ea;return Ge!=="formItems"}),qe(Xe,De),d.value=Xe}},P=async Ie=>{const de=se.value[Ie];G.value=de,await ra()};e.watch(()=>{var Ie;return(Ie=w==null?void 0:w.value)==null?void 0:Ie.group},async(Ie,de)=>{Ie!=de&&P(Ie)});const Ke=async()=>{var De,Xe;const Ie=(De=w.value)==null?void 0:De.menu;await _e(Ie);const de=(Xe=w.value)==null?void 0:Xe.group;await P(de)},Me=()=>({comp:"chart",compData:[{key:"chartBaseConfig",contents:c.value},{key:"chartDataConfig",contents:w.value},{key:"chartDetailConfig",contents:x.value}]}),Le=()=>{i.visible=!1,y.visible=!1,O.visible=!1};return e.onMounted(async()=>{var de,De,Xe;d.value=D(),E.value=_();const Ie=r==null?void 0:r.itemContents;c.value=((de=Ie==null?void 0:Ie.find(Ea=>Ea.key==="chartBaseConfig"))==null?void 0:de.contents)??{},w.value=((De=Ie==null?void 0:Ie.find(Ea=>Ea.key==="chartDataConfig"))==null?void 0:De.contents)??{},await Ke(),x.value=((Xe=Ie==null?void 0:Ie.find(Ea=>Ea.key==="chartDetailConfig"))==null?void 0:Xe.contents)??{},await te()}),(Ie,de)=>{const De=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",hv,[de[4]||(de[4]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createVNode(De,{id:"themeButton",onClick:de[0]||(de[0]=Xe=>u())},{default:e.withCtx(()=>de[3]||(de[3]=[e.createTextVNode(" 修改 ")])),_:1,__:[3]})]),e.createElementVNode("div",vv,[de[6]||(de[6]=e.createElementVNode("h4",{class:"module-title"},"数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:de[1]||(de[1]=Xe=>j())},{default:e.withCtx(()=>de[5]||(de[5]=[e.createTextVNode(" 修改 ")])),_:1,__:[5]})]),e.createElementVNode("div",mv,[de[8]||(de[8]=e.createElementVNode("h4",{class:"module-title"},"详情数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:de[2]||(de[2]=Xe=>I())},{default:e.withCtx(()=>de[7]||(de[7]=[e.createTextVNode(" 修改 ")])),_:1,__:[7]})])]),e.createVNode($r.ssDialog,{visible:i.visible,title:i.title,onBeforeDestroy:Le,width:i.width},{default:e.withCtx(()=>[e.createElementVNode("div",yv,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:o.value,key:o.value,isEnableWrap:!0,onChange:m},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",gv,[e.createVNode(De,{class:"cancel-button button",onClick:Le,id:"themeBorderButton"},{default:e.withCtx(()=>de[9]||(de[9]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[9]}),e.createVNode(De,{class:"ok-button button",onClick:g,id:"themeButton"},{default:e.withCtx(()=>de[10]||(de[10]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[10]})])]),_:1},8,["visible","title","width"]),e.createVNode($r.ssDialog,{visible:y.visible,title:y.title,onBeforeDestroy:Le,width:y.width},{default:e.withCtx(()=>[e.createElementVNode("div",bv,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:d.value,key:d.value,isEnableWrap:!0,onChange:A},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",kv,[e.createVNode(De,{class:"cancel-button button",onClick:Le,id:"themeBorderButton"},{default:e.withCtx(()=>de[11]||(de[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(De,{class:"ok-button button",onClick:Le,id:"themeButton"},{default:e.withCtx(()=>de[12]||(de[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible","title","width"]),e.createVNode($r.ssDialog,{visible:O.visible,title:O.title,onBeforeDestroy:Le,width:O.width},{default:e.withCtx(()=>[e.createElementVNode("div",xv,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:S},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",wv,[e.createVNode(De,{class:"cancel-button button",onClick:Le,id:"themeBorderButton"},{default:e.withCtx(()=>de[13]||(de[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(De,{class:"ok-button button",onClick:Le,id:"themeButton"},{default:e.withCtx(()=>de[14]||(de[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible","title","width"])],64)}}}),Sv=pr._export_sfc(_v,[["__scopeId","data-v-88c50cdb"]]),Ev={class:"layout"},Cv=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}}},emits:["rowClick"],setup(a,{emit:l}){const r=l,n=a;e.onMounted(async()=>{});const i=e.computed(()=>M.cloneDeep(n==null?void 0:n.itemData)||[]),o=e.computed(()=>{var g;const m=(g=i==null?void 0:i.value)==null?void 0:g.find(y=>{const{key:d}=y;return d==="baseConfig"});return m==null?void 0:m.contents}),p=e.computed(()=>{var g;const m=(g=i==null?void 0:i.value)==null?void 0:g.find(y=>{const{key:d}=y;return d==="children"});return m==null?void 0:m.contents}),c=e.computed(()=>{let m=M.cloneDeep(p.value)||[];const g=m.length;let y=0;const d=[];if(m=m.map(D=>{const w=D.span;return w?(D.span=Number(w),y=y+D.span):d.push(D),D}),y<24){const D=Math.floor((24-y)/g);d.forEach(w=>{w.span=D})}return m}),u=m=>{r("rowClick",m)};return(m,g)=>{var D;const y=e.resolveComponent("el-col"),d=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",Ev,[e.createVNode(d,{style:e.normalizeStyle({height:(D=o.value)==null?void 0:D.height})},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(w,q)=>(e.openBlock(),e.createBlock(y,{span:w==null?void 0:w.span},{default:e.withCtx(()=>{var A;return[e.unref(Ri)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)(w.comp)),{key:e.unref(oi),compName:w.name,index:(w==null?void 0:w.id)??q,height:(A=o.value)==null?void 0:A.height,itemData:w==null?void 0:w.compData,childItemData:w==null?void 0:w.itemChildData,onChange:e.unref(Mo),onContentChange:e.unref(Io),onPageChange:e.unref(Oo),onRowClick:u},null,40,["compName","index","height","itemData","childItemData","onChange","onContentChange","onPageChange"])):e.createCommentVNode("",!0)]}),_:2},1032,["span"]))),256))]),_:1},8,["style"])])}}}),Dv=pr._export_sfc(Cv,[["__scopeId","data-v-ab9a36ed"]]),Tv={class:"layout-operate"},Bv={class:"layout-module"},Nv={class:"collapse-title-item"},Av={class:"collapse-title"},zv={class:"icon-content"},Mv=["onClick"],Iv={class:"comp-child"},Ov=e.defineComponent({__name:"operate",props:{itemContents:{type:Object,default:()=>{}},originalItemContents:{type:Array,default:()=>[]},itemChildData:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l;e.onMounted(()=>{q()});const i=e.ref({}),o=e.ref({}),p=e.ref([]),c=x=>[{label:"高度",prop:"height",type:"input",value:x==null?void 0:x.height}],u=x=>{o.value=x,n("change",_(),!0)},m=e.ref([]),g=e.ref([]),y=x=>[{label:"占比",prop:"span",type:"input",value:x==null?void 0:x.span}],d=e.computed(()=>{const x=r==null?void 0:r.itemContents;return M.cloneDeep(x)}),D=e.computed(()=>{const x=d==null?void 0:d.value,b=x==null?void 0:x.find(S=>{const{key:I}=S;return I==="baseConfig"});return b==null?void 0:b.contents}),w=e.computed(()=>{const x=d==null?void 0:d.value,b=x==null?void 0:x.find(S=>{const{key:I}=S;return I==="children"});return b==null?void 0:b.contents}),q=()=>{var x;i.value=d.value||{},m.value=(w==null?void 0:w.value)||[],p.value=c(),p.value=(x=p.value)==null?void 0:x.map(b=>{var I;const{prop:S}=b;return b.value=(I=D.value)==null?void 0:I[S],b})};e.watch(()=>{var x;return(x=w==null?void 0:w.value)==null?void 0:x.length},()=>{var x;m.value=(w==null?void 0:w.value)||[],g.value=(x=w.value)==null?void 0:x.map(b=>y(b))},{immediate:!0});const A=(x,b)=>{const S=M.cloneDeep(w==null?void 0:w.value);S[b].span=x.span,m.value=S,n("change",_(),!0)},j=x=>$i(x),O=(x,b,S)=>{if(!x)return;const I=M.cloneDeep(w==null?void 0:w.value);I[S]&&(I[S].compData=x,m.value=I,n("change",_(),!0))},E=x=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{let b=M.cloneDeep(w==null?void 0:w.value);b=b==null?void 0:b.filter((S,I)=>x!==I),m.value=b,n("change",_(),!0),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},_=()=>({compData:[{key:"baseConfig",contents:o.value},{key:"children",contents:m==null?void 0:m.value}]});return(x,b)=>{const S=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",Tv,[e.createElementVNode("div",Bv,[b[1]||(b[1]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createElementVNode("div",null,[e.createVNode(pl.ssForm,{rowContents:p.value,isEnableWrap:!0,onChange:b[0]||(b[0]=I=>u(I))},null,8,["rowContents"])])]),e.createVNode(pc.default,{class:"collapse-content",collapseContents:w.value},{title:e.withCtx(({item:I,index:R})=>[e.createElementVNode("div",Nv,[e.createElementVNode("div",Av,e.toDisplayString(I.name),1),e.createElementVNode("div",zv,[e.createElementVNode("div",{onClick:e.withModifiers(re=>E(R),["stop"]),class:"icon-content"},[e.createVNode(S,{name:"Delete",style:{width:"16px",height:"16px"}})],8,Mv)])])]),content:e.withCtx(({item:I,index:R})=>[e.createElementVNode("div",Iv,[e.createElementVNode("div",null,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:g.value[R],key:R,isEnableWrap:!0,onChange:re=>A(re,R)},null,8,["rowContents","onChange"]))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(j(I.comp+"Operate")),{itemContents:I==null?void 0:I.compData,originalItemContents:I.compData,onChange:re=>O(re,I,R)},null,40,["itemContents","originalItemContents","onChange"]))])]),_:1},8,["collapseContents"])])}}}),Lv=pr._export_sfc(Ov,[["__scopeId","data-v-ba05456e"]]),Rv=typeof window<"u";var Vs;Rv&&((Vs=window==null?void 0:window.navigator)!=null&&Vs.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Bn(a){return a==null}function nu(){}const $v=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($v)));function Vv(){const a=new Map;return{on(l,r){const n=a.get(l);n!=null&&n.add(r)||a.set(l,new Set([r]))},off(l,r){const n=a.get(l);n&&n.delete(r)},clear(l){const r=a.get(l);r&&r.clear()},clearAll(){a.clear()},emit(l,...r){const n=a.get(l);n&&n.forEach(i=>{i(...r)})}}}function Fs(a,l=16){if(typeof a!="function")return nu;const r=(...o)=>{a(...o)};if(l<=0)return iu(r);let n=0,i;return function(...o){const p=Date.now(),c=p-n;clearTimeout(i),c>=l?(n=p,r(...o)):i=setTimeout(()=>{n=Date.now(),r(...o)},Math.max(0,l-c))}}function Fv(a,l=100){if(typeof a!="function")return nu;const r=(...i)=>{a(...i)};if(l<=0)return iu(r);let n;return function(...i){clearTimeout(n),n=setTimeout(()=>{r(...i)},l)}}function iu(a){if(typeof a!="function")return a;let l=!1,r,n;return function(...i){return r=i,l||(l=!0,n=Promise.resolve().then(()=>(l=!1,n=void 0,a(...r)))),n}}const Ji=new Set,ou=new WeakMap;function Pv(){Ji.forEach(a=>{a(...ou.get(a))}),Ji.clear()}function kn(a,...l){if(typeof a!="function")return a;ou.set(a,l),!Ji.has(a)&&(Ji.add(a),Ji.size===1&&Promise.resolve().then(Pv))}const tu=Symbol("LAYOUT_KEY"),su=Symbol("EMITTER_KEY");function jv(a){let l=0,r;for(let n=0,i=a.length;n<i;n++)r=a[n].y+a[n].h,r>l&&(l=r);return l}function Lt(a){const l=Array(a.length);for(let r=0,n=a.length;r<n;r++)l[r]=Hv(a[r]);return l}function Hv(a){return{...a}}function cu(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 zi(a,l,r){const n=du(a),i=pu(a),o=Array(a.length);for(let p=0,c=i.length;p<c;p++){let u=i[p];u.static||(u=Uv(n,u,l,r),n.push(u)),o[a.findIndex(m=>m.i===u.i)]=u,u.moved=!1}return o}function Uv(a,l,r,n){if(r)for(;l.y>0&&!Xi(a,l);)l.y--;else if(n){const o=n[l.i].y;for(;l.y>o&&!Xi(a,l);)l.y--}let i;for(;i=Xi(a,l);)l.y=i.y+i.h;return l}function qv(a,l){const r=du(a);for(let n=0,i=a.length;n<i;n++){const o=a[n];if(o.x+o.w>l.cols&&(o.x=l.cols-o.w),o.x<0&&(o.x=0,o.w=l.cols),!o.static)r.push(o);else for(;Xi(r,o);)o.y++}return a}function Ps(a,l){for(let r=0,n=a.length;r<n;r++)if(a[r].i===l)return a[r]}function Xi(a,l){for(let r=0,n=a.length;r<n;r++)if(cu(a[r],l))return a[r]}function uu(a,l){return a.filter(r=>cu(r,l))}function du(a){return a.filter(l=>l.static)}function Rt(a,l,r,n,i=!1,o=!1){if(l.static)return a;const p=l.x,c=l.y,u=n&&l.y>n;typeof r=="number"&&(l.x=r),typeof n=="number"&&(l.y=n),l.moved=!0;let m=pu(a);u&&(m=m.reverse());const g=uu(m,l);if(o&&g.length)return l.x=p,l.y=c,l.moved=!1,a;for(let y=0,d=g.length;y<d;y++){const D=g[y];D.moved||l.y>D.y&&l.y-D.y>D.h/4||(D.static?a=js(a,D,l,i):a=js(a,l,D,i))}return a}function js(a,l,r,n){if(n){const i={x:r.x,y:r.y,w:r.w,h:r.h};if(i.y=Math.max(l.y-r.h,0),!Xi(a,i))return Rt(a,r,void 0,i.y,!1)}return Rt(a,r,void 0,r.y+1,!1)}function Wv(a,l,r,n){const i="translate3d("+l+"px,"+a+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:r+"px",height:n+"px",position:"absolute"}}function Gv(a,l,r,n){const i="translate3d("+l*-1+"px,"+a+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:r+"px",height:n+"px",position:"absolute"}}function Kv(a,l,r,n){return{top:a+"px",left:l+"px",width:r+"px",height:n+"px",position:"absolute"}}function Yv(a,l,r,n){return{top:a+"px",right:l+"px",width:r+"px",height:n+"px",position:"absolute"}}function pu(a){return Array.from(a).sort(function(l,r){return l.y===r.y&&l.x===r.x?0:l.y>r.y||l.y===r.y&&l.x>r.x?1:-1})}function Jv(a,l){l=l||"Layout";const r=["x","y","w","h"],n=[];if(!Array.isArray(a))throw new Error(l+" must be an array!");for(let i=0,o=a.length;i<o;i++){const p=a[i];for(let c=0;c<r.length;c++)if(typeof p[r[c]]!="number")throw new Error("VueGridLayout: "+l+"["+i+"]."+r[c]+" must be a number!");if(p.i===void 0||p.i===null)throw new Error("VueGridLayout: "+l+"["+i+"].i cannot be null!");if(typeof p.i!="number"&&typeof p.i!="string")throw new Error("VueGridLayout: "+l+"["+i+"].i must be a string or number!");if(n.indexOf(p.i)>=0)throw new Error("VueGridLayout: "+l+"["+i+"].i must be unique!");if(n.push(p.i),p.static!==void 0&&typeof p.static!="boolean")throw new Error("VueGridLayout: "+l+"["+i+"].static must be a boolean!")}}function Xv(a,l="vgl"){const r=()=>`${l}-${a}`;return{b:r,be:n=>`${r()}__${n}`,bm:n=>`${r()}--${n}`,bem:(n,i)=>`${r()}__${n}--${i}`}}function Hs(a){return Zv(a)}function Zv(a){var l;const r=((l=a.target)==null?void 0:l.offsetParent)||document.body,n=a.offsetParent===document.body?{left:0,top:0}:r.getBoundingClientRect(),i=a.clientX+r.scrollLeft-n.left,o=a.clientY+r.scrollTop-n.top;return{x:i,y:o}}function Us(a,l,r,n){return Qv(a)?{deltaX:r-a,deltaY:n-l,lastX:a,lastY:l,x:r,y:n}:{deltaX:0,deltaY:0,lastX:r,lastY:n,x:r,y:n}}function Qv(a){return typeof a=="number"&&!Number.isNaN(a)}function e1(a,l){const r=hu(a);let n=r[0];for(let i=1,o=r.length;i<o;i++){const p=r[i];l>a[p]&&(n=p)}return n}function fu(a,l){if(!l[a])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+a+" is missing!");return l[a]}function a1(a,l,r,n,i,o,p){if(l[n])return Lt(l[n]);let c=a;const u=hu(r),m=u.slice(u.indexOf(n));for(let g=0,y=m.length;g<y;g++){const d=m[g];if(l[d]){c=l[d];break}}return c=Lt(c||[]),zi(qv(c,{cols:o}),p)}function hu(a){return Object.keys(a).sort((l,r)=>a[l]-a[r])}let l1="auto";function r1(){return typeof document<"u"}function qs(){return r1()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir"):l1}var Ki={exports:{}},n1=Ki.exports,Ws;function i1(){return Ws||(Ws=1,function(a,l){(function(r,n){a.exports=n()})(n1,function(){function r(s,t){var h=Object.keys(s);if(Object.getOwnPropertySymbols){var k=Object.getOwnPropertySymbols(s);t&&(k=k.filter(function(C){return Object.getOwnPropertyDescriptor(s,C).enumerable})),h.push.apply(h,k)}return h}function n(s){for(var t=1;t<arguments.length;t++){var h=arguments[t]!=null?arguments[t]:{};t%2?r(Object(h),!0).forEach(function(k){u(s,k,h[k])}):Object.getOwnPropertyDescriptors?Object.defineProperties(s,Object.getOwnPropertyDescriptors(h)):r(Object(h)).forEach(function(k){Object.defineProperty(s,k,Object.getOwnPropertyDescriptor(h,k))})}return s}function i(s){return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(s)}function o(s,t){if(!(s instanceof t))throw new TypeError("Cannot call a class as a function")}function p(s,t){for(var h=0;h<t.length;h++){var k=t[h];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(s,q(k.key),k)}}function c(s,t,h){return t&&p(s.prototype,t),Object.defineProperty(s,"prototype",{writable:!1}),s}function u(s,t,h){return(t=q(t))in s?Object.defineProperty(s,t,{value:h,enumerable:!0,configurable:!0,writable:!0}):s[t]=h,s}function m(s,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");s.prototype=Object.create(t&&t.prototype,{constructor:{value:s,writable:!0,configurable:!0}}),Object.defineProperty(s,"prototype",{writable:!1}),t&&y(s,t)}function g(s){return g=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},g(s)}function y(s,t){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(h,k){return h.__proto__=k,h},y(s,t)}function d(s){if(s===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return s}function D(s){var t=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 h,k=g(s);if(t){var C=g(this).constructor;h=Reflect.construct(k,arguments,C)}else h=k.apply(this,arguments);return function(F,Y){if(Y&&(typeof Y=="object"||typeof Y=="function"))return Y;if(Y!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return d(F)}(this,h)}}function w(){return w=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(s,t,h){var k=function(F,Y){for(;!Object.prototype.hasOwnProperty.call(F,Y)&&(F=g(F))!==null;);return F}(s,t);if(k){var C=Object.getOwnPropertyDescriptor(k,t);return C.get?C.get.call(arguments.length<3?s:h):C.value}},w.apply(this,arguments)}function q(s){var t=function(h,k){if(typeof h!="object"||h===null)return h;var C=h[Symbol.toPrimitive];if(C!==void 0){var F=C.call(h,k);if(typeof F!="object")return F;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(h)}(s,"string");return typeof t=="symbol"?t:t+""}var A=function(s){return!(!s||!s.Window)&&s instanceof s.Window},j=void 0,O=void 0;function E(s){j=s;var t=s.document.createTextNode("");t.ownerDocument!==s.document&&typeof s.wrap=="function"&&s.wrap(t)===t&&(s=s.wrap(s)),O=s}function _(s){return A(s)?s:(s.ownerDocument||s).defaultView||O.window}typeof window<"u"&&window&&E(window);var x=function(s){return!!s&&i(s)==="object"},b=function(s){return typeof s=="function"},S={window:function(s){return s===O||A(s)},docFrag:function(s){return x(s)&&s.nodeType===11},object:x,func:b,number:function(s){return typeof s=="number"},bool:function(s){return typeof s=="boolean"},string:function(s){return typeof s=="string"},element:function(s){if(!s||i(s)!=="object")return!1;var t=_(s)||O;return/object|function/.test(typeof Element>"u"?"undefined":i(Element))?s instanceof Element||s instanceof t.Element:s.nodeType===1&&typeof s.nodeName=="string"},plainObject:function(s){return x(s)&&!!s.constructor&&/function Object\b/.test(s.constructor.toString())},array:function(s){return x(s)&&s.length!==void 0&&b(s.splice)}};function I(s){var t=s.interaction;if(t.prepared.name==="drag"){var h=t.prepared.axis;h==="x"?(t.coords.cur.page.y=t.coords.start.page.y,t.coords.cur.client.y=t.coords.start.client.y,t.coords.velocity.client.y=0,t.coords.velocity.page.y=0):h==="y"&&(t.coords.cur.page.x=t.coords.start.page.x,t.coords.cur.client.x=t.coords.start.client.x,t.coords.velocity.client.x=0,t.coords.velocity.page.x=0)}}function R(s){var t=s.iEvent,h=s.interaction;if(h.prepared.name==="drag"){var k=h.prepared.axis;if(k==="x"||k==="y"){var C=k==="x"?"y":"x";t.page[C]=h.coords.start.page[C],t.client[C]=h.coords.start.client[C],t.delta[C]=0}}}var re={id:"actions/drag",install:function(s){var t=s.actions,h=s.Interactable,k=s.defaults;h.prototype.draggable=re.draggable,t.map.drag=re,t.methodDict.drag="draggable",k.actions.drag=re.defaults},listeners:{"interactions:before-action-move":I,"interactions:action-resume":I,"interactions:action-move":R,"auto-start:check":function(s){var t=s.interaction,h=s.interactable,k=s.buttons,C=h.options.drag;if(C&&C.enabled&&(!t.pointerIsDown||!/mouse|pointer/.test(t.pointerType)||(k&h.options.drag.mouseButtons)!=0))return s.action={name:"drag",axis:C.lockAxis==="start"?C.startAxis:C.lockAxis},!1}},draggable:function(s){return S.object(s)?(this.options.drag.enabled=s.enabled!==!1,this.setPerAction("drag",s),this.setOnEvents("drag",s),/^(xy|x|y|start)$/.test(s.lockAxis)&&(this.options.drag.lockAxis=s.lockAxis),/^(xy|x|y)$/.test(s.startAxis)&&(this.options.drag.startAxis=s.startAxis),this):S.bool(s)?(this.options.drag.enabled=s,this):this.options.drag},beforeMove:I,move:R,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor:function(){return"move"},filterEventType:function(s){return s.search("drag")===0}},X=re,me={init:function(s){var t=s;me.document=t.document,me.DocumentFragment=t.DocumentFragment||ue,me.SVGElement=t.SVGElement||ue,me.SVGSVGElement=t.SVGSVGElement||ue,me.SVGElementInstance=t.SVGElementInstance||ue,me.Element=t.Element||ue,me.HTMLElement=t.HTMLElement||me.Element,me.Event=t.Event,me.Touch=t.Touch||ue,me.PointerEvent=t.PointerEvent||t.MSPointerEvent},document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function ue(){}var U=me,W={init:function(s){var t=U.Element,h=s.navigator||{};W.supportsTouch="ontouchstart"in s||S.func(s.DocumentTouch)&&U.document instanceof s.DocumentTouch,W.supportsPointerEvent=h.pointerEnabled!==!1&&!!U.PointerEvent,W.isIOS=/iP(hone|od|ad)/.test(h.platform),W.isIOS7=/iP(hone|od|ad)/.test(h.platform)&&/OS 7[^\d]/.test(h.appVersion),W.isIe9=/MSIE 9/.test(h.userAgent),W.isOperaMobile=h.appName==="Opera"&&W.supportsTouch&&/Presto/.test(h.userAgent),W.prefixedMatchesSelector="matches"in t.prototype?"matches":"webkitMatchesSelector"in t.prototype?"webkitMatchesSelector":"mozMatchesSelector"in t.prototype?"mozMatchesSelector":"oMatchesSelector"in t.prototype?"oMatchesSelector":"msMatchesSelector",W.pEventTypes=W.supportsPointerEvent?U.PointerEvent===s.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,W.wheelEvent=U.document&&"onmousewheel"in U.document?"mousewheel":"wheel"},supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null},Z=W;function ae(s,t){if(s.contains)return s.contains(t);for(;t;){if(t===s)return!0;t=t.parentNode}return!1}function ve(s,t){for(;S.element(s);){if(te(s,t))return s;s=ze(s)}return null}function ze(s){var t=s.parentNode;if(S.docFrag(t)){for(;(t=t.host)&&S.docFrag(t););return t}return t}function te(s,t){return O!==j&&(t=t.replace(/\/deep\//g," ")),s[Z.prefixedMatchesSelector](t)}var N=function(s){return s.parentNode||s.host};function se(s,t){for(var h,k=[],C=s;(h=N(C))&&C!==t&&h!==C.ownerDocument;)k.unshift(C),C=h;return k}function G(s,t,h){for(;S.element(s);){if(te(s,t))return!0;if((s=ze(s))===h)return te(s,t)}return!1}function fe(s){return s.correspondingUseElement||s}function we(s){var t=s instanceof U.SVGElement?s.getBoundingClientRect():s.getClientRects()[0];return t&&{left:t.left,right:t.right,top:t.top,bottom:t.bottom,width:t.width||t.right-t.left,height:t.height||t.bottom-t.top}}function _e(s){var t,h=we(s);if(!Z.isIOS7&&h){var k={x:(t=(t=_(s))||O).scrollX||t.document.documentElement.scrollLeft,y:t.scrollY||t.document.documentElement.scrollTop};h.left+=k.x,h.right+=k.x,h.top+=k.y,h.bottom+=k.y}return h}function qe(s){for(var t=[];s;)t.push(s),s=ze(s);return t}function ra(s){return!!S.string(s)&&(U.document.querySelector(s),!0)}function P(s,t){for(var h in t)s[h]=t[h];return s}function Ke(s,t,h){return s==="parent"?ze(h):s==="self"?t.getRect(h):ve(h,s)}function Me(s,t,h,k){var C=s;return S.string(C)?C=Ke(C,t,h):S.func(C)&&(C=C.apply(void 0,k)),S.element(C)&&(C=_e(C)),C}function Le(s){return s&&{x:"x"in s?s.x:s.left,y:"y"in s?s.y:s.top}}function Ie(s){return!s||"x"in s&&"y"in s||((s=P({},s)).x=s.left||0,s.y=s.top||0,s.width=s.width||(s.right||0)-s.x,s.height=s.height||(s.bottom||0)-s.y),s}function de(s,t,h){s.left&&(t.left+=h.x),s.right&&(t.right+=h.x),s.top&&(t.top+=h.y),s.bottom&&(t.bottom+=h.y),t.width=t.right-t.left,t.height=t.bottom-t.top}function De(s,t,h){var k=h&&s.options[h];return Le(Me(k&&k.origin||s.options.origin,s,t,[s&&t]))||{x:0,y:0}}function Xe(s,t){var h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(xe){return!0},k=arguments.length>3?arguments[3]:void 0;if(k=k||{},S.string(s)&&s.search(" ")!==-1&&(s=Ea(s)),S.array(s))return s.forEach(function(xe){return Xe(xe,t,h,k)}),k;if(S.object(s)&&(t=s,s=""),S.func(t)&&h(s))k[s]=k[s]||[],k[s].push(t);else if(S.array(t))for(var C=0,F=t;C<F.length;C++){var Y=F[C];Xe(s,Y,h,k)}else if(S.object(t))for(var J in t)Xe(Ea(J).map(function(xe){return"".concat(s).concat(xe)}),t[J],h,k);return k}function Ea(s){return s.trim().split(/ +/)}var Ge=function(s,t){return Math.sqrt(s*s+t*t)},$=["webkit","moz"];function V(s,t){s.__set||(s.__set={});var h=function(C){if($.some(function(F){return C.indexOf(F)===0}))return 1;typeof s[C]!="function"&&C!=="__set"&&Object.defineProperty(s,C,{get:function(){return C in s.__set?s.__set[C]:s.__set[C]=t[C]},set:function(F){s.__set[C]=F},configurable:!0})};for(var k in t)h(k);return s}function ee(s,t){s.page=s.page||{},s.page.x=t.page.x,s.page.y=t.page.y,s.client=s.client||{},s.client.x=t.client.x,s.client.y=t.client.y,s.timeStamp=t.timeStamp}function ce(s){s.page.x=0,s.page.y=0,s.client.x=0,s.client.y=0}function he(s){return s instanceof U.Event||s instanceof U.Touch}function pa(s,t,h){return s=s||"page",(h=h||{}).x=t[s+"X"],h.y=t[s+"Y"],h}function ia(s,t){return t=t||{x:0,y:0},Z.isOperaMobile&&he(s)?(pa("screen",s,t),t.x+=window.scrollX,t.y+=window.scrollY):pa("page",s,t),t}function Ve(s){return S.number(s.pointerId)?s.pointerId:s.identifier}function ya(s,t,h){var k=t.length>1?Ce(t):t[0];ia(k,s.page),function(C,F){F=F||{},Z.isOperaMobile&&he(C)?pa("screen",C,F):pa("client",C,F)}(k,s.client),s.timeStamp=h}function Ca(s){var t=[];return S.array(s)?(t[0]=s[0],t[1]=s[1]):s.type==="touchend"?s.touches.length===1?(t[0]=s.touches[0],t[1]=s.changedTouches[0]):s.touches.length===0&&(t[0]=s.changedTouches[0],t[1]=s.changedTouches[1]):(t[0]=s.touches[0],t[1]=s.touches[1]),t}function Ce(s){for(var t={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0},h=0;h<s.length;h++){var k=s[h];for(var C in t)t[C]+=k[C]}for(var F in t)t[F]/=s.length;return t}function Fa(s){if(!s.length)return null;var t=Ca(s),h=Math.min(t[0].pageX,t[1].pageX),k=Math.min(t[0].pageY,t[1].pageY),C=Math.max(t[0].pageX,t[1].pageX),F=Math.max(t[0].pageY,t[1].pageY);return{x:h,y:k,left:h,top:k,right:C,bottom:F,width:C-h,height:F-k}}function Ta(s,t){var h=t+"X",k=t+"Y",C=Ca(s),F=C[0][h]-C[1][h],Y=C[0][k]-C[1][k];return Ge(F,Y)}function fa(s,t){var h=t+"X",k=t+"Y",C=Ca(s),F=C[1][h]-C[0][h],Y=C[1][k]-C[0][k];return 180*Math.atan2(Y,F)/Math.PI}function ja(s){return S.string(s.pointerType)?s.pointerType:S.number(s.pointerType)?[void 0,void 0,"touch","pen","mouse"][s.pointerType]:/touch/.test(s.type||"")||s instanceof U.Touch?"touch":"mouse"}function sa(s){var t=S.func(s.composedPath)?s.composedPath():s.path;return[fe(t?t[0]:s.target),fe(s.currentTarget)]}var Pe=function(){function s(t){o(this,s),this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=t}return c(s,[{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),s}();Object.defineProperty(Pe.prototype,"interaction",{get:function(){return this._interaction._proxy},set:function(){}});var ma=function(s,t){for(var h=0;h<t.length;h++){var k=t[h];s.push(k)}return s},Qe=function(s){return ma([],s)},Oe=function(s,t){for(var h=0;h<s.length;h++)if(t(s[h],h,s))return h;return-1},$e=function(s,t){return s[Oe(s,t)]},ne=function(s){m(h,s);var t=D(h);function h(k,C,F){var Y;o(this,h),(Y=t.call(this,C._interaction)).dropzone=void 0,Y.dragEvent=void 0,Y.relatedTarget=void 0,Y.draggable=void 0,Y.propagationStopped=!1,Y.immediatePropagationStopped=!1;var J=F==="dragleave"?k.prev:k.cur,xe=J.element,He=J.dropzone;return Y.type=F,Y.target=xe,Y.currentTarget=xe,Y.dropzone=He,Y.dragEvent=C,Y.relatedTarget=C.target,Y.draggable=C.interactable,Y.timeStamp=C.timeStamp,Y}return c(h,[{key:"reject",value:function(){var k=this,C=this._interaction.dropState;if(this.type==="dropactivate"||this.dropzone&&C.cur.dropzone===this.dropzone&&C.cur.element===this.target)if(C.prev.dropzone=this.dropzone,C.prev.element=this.target,C.rejected=!0,C.events.enter=null,this.stopImmediatePropagation(),this.type==="dropactivate"){var F=C.activeDrops,Y=Oe(F,function(xe){var He=xe.dropzone,Se=xe.element;return He===k.dropzone&&Se===k.target});C.activeDrops.splice(Y,1);var J=new h(C,this.dragEvent,"dropdeactivate");J.dropzone=this.dropzone,J.target=this.target,this.dropzone.fire(J)}else this.dropzone.fire(new h(C,this.dragEvent,"dragleave"))}},{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),h}(Pe);function We(s,t){for(var h=0,k=s.slice();h<k.length;h++){var C=k[h],F=C.dropzone,Y=C.element;t.dropzone=F,t.target=Y,F.fire(t),t.propagationStopped=t.immediatePropagationStopped=!1}}function na(s,t){for(var h=function(F,Y){for(var J=[],xe=0,He=F.interactables.list;xe<He.length;xe++){var Se=He[xe];if(Se.options.drop.enabled){var da=Se.options.drop.accept;if(!(S.element(da)&&da!==Y||S.string(da)&&!te(Y,da)||S.func(da)&&!da({dropzone:Se,draggableElement:Y})))for(var Ma=0,rl=Se.getAllElements();Ma<rl.length;Ma++){var el=rl[Ma];el!==Y&&J.push({dropzone:Se,element:el,rect:Se.getRect(el)})}}}return J}(s,t),k=0;k<h.length;k++){var C=h[k];C.rect=C.dropzone.getRect(C.element)}return h}function va(s,t,h){for(var k=s.dropState,C=s.interactable,F=s.element,Y=[],J=0,xe=k.activeDrops;J<xe.length;J++){var He=xe[J],Se=He.dropzone,da=He.element,Ma=He.rect,rl=Se.dropCheck(t,h,C,F,da,Ma);Y.push(rl?da:null)}var el=function(cl){for(var Dl,El,Vl,ir=[],fr=0;fr<cl.length;fr++){var ql=cl[fr],sr=cl[Dl];if(ql&&fr!==Dl)if(sr){var dn=N(ql),ar=N(sr);if(dn!==ql.ownerDocument)if(ar!==ql.ownerDocument)if(dn!==ar){ir=ir.length?ir:se(sr);var bn=void 0;if(sr instanceof U.HTMLElement&&ql instanceof U.SVGElement&&!(ql instanceof U.SVGSVGElement)){if(ql===ar)continue;bn=ql.ownerSVGElement}else bn=ql;for(var Xr=se(bn,sr.ownerDocument),Rn=0;Xr[Rn]&&Xr[Rn]===ir[Rn];)Rn++;var yn=[Xr[Rn-1],Xr[Rn],ir[Rn]];if(yn[0])for(var pi=yn[0].lastChild;pi;){if(pi===yn[1]){Dl=fr,ir=Xr;break}if(pi===yn[2])break;pi=pi.previousSibling}}else Vl=sr,(parseInt(_(El=ql).getComputedStyle(El).zIndex,10)||0)>=(parseInt(_(Vl).getComputedStyle(Vl).zIndex,10)||0)&&(Dl=fr);else Dl=fr}else Dl=fr}return Dl}(Y);return k.activeDrops[el]||null}function Ae(s,t,h){var k=s.dropState,C={enter:null,leave:null,activate:null,deactivate:null,move:null,drop:null};return h.type==="dragstart"&&(C.activate=new ne(k,h,"dropactivate"),C.activate.target=null,C.activate.dropzone=null),h.type==="dragend"&&(C.deactivate=new ne(k,h,"dropdeactivate"),C.deactivate.target=null,C.deactivate.dropzone=null),k.rejected||(k.cur.element!==k.prev.element&&(k.prev.dropzone&&(C.leave=new ne(k,h,"dragleave"),h.dragLeave=C.leave.target=k.prev.element,h.prevDropzone=C.leave.dropzone=k.prev.dropzone),k.cur.dropzone&&(C.enter=new ne(k,h,"dragenter"),h.dragEnter=k.cur.element,h.dropzone=k.cur.dropzone)),h.type==="dragend"&&k.cur.dropzone&&(C.drop=new ne(k,h,"drop"),h.dropzone=k.cur.dropzone,h.relatedTarget=k.cur.element),h.type==="dragmove"&&k.cur.dropzone&&(C.move=new ne(k,h,"dropmove"),h.dropzone=k.cur.dropzone)),C}function Be(s,t){var h=s.dropState,k=h.activeDrops,C=h.cur,F=h.prev;t.leave&&F.dropzone.fire(t.leave),t.enter&&C.dropzone.fire(t.enter),t.move&&C.dropzone.fire(t.move),t.drop&&C.dropzone.fire(t.drop),t.deactivate&&We(k,t.deactivate),h.prev.dropzone=C.dropzone,h.prev.element=C.element}function Ye(s,t){var h=s.interaction,k=s.iEvent,C=s.event;if(k.type==="dragmove"||k.type==="dragend"){var F=h.dropState;t.dynamicDrop&&(F.activeDrops=na(t,h.element));var Y=k,J=va(h,Y,C);F.rejected=F.rejected&&!!J&&J.dropzone===F.cur.dropzone&&J.element===F.cur.element,F.cur.dropzone=J&&J.dropzone,F.cur.element=J&&J.element,F.events=Ae(h,0,Y)}}var Ee={id:"actions/drop",install:function(s){var t=s.actions,h=s.interactStatic,k=s.Interactable,C=s.defaults;s.usePlugin(X),k.prototype.dropzone=function(F){return function(Y,J){if(S.object(J)){if(Y.options.drop.enabled=J.enabled!==!1,J.listeners){var xe=Xe(J.listeners),He=Object.keys(xe).reduce(function(da,Ma){return da[/^(enter|leave)/.test(Ma)?"drag".concat(Ma):/^(activate|deactivate|move)/.test(Ma)?"drop".concat(Ma):Ma]=xe[Ma],da},{}),Se=Y.options.drop.listeners;Se&&Y.off(Se),Y.on(He),Y.options.drop.listeners=He}return S.func(J.ondrop)&&Y.on("drop",J.ondrop),S.func(J.ondropactivate)&&Y.on("dropactivate",J.ondropactivate),S.func(J.ondropdeactivate)&&Y.on("dropdeactivate",J.ondropdeactivate),S.func(J.ondragenter)&&Y.on("dragenter",J.ondragenter),S.func(J.ondragleave)&&Y.on("dragleave",J.ondragleave),S.func(J.ondropmove)&&Y.on("dropmove",J.ondropmove),/^(pointer|center)$/.test(J.overlap)?Y.options.drop.overlap=J.overlap:S.number(J.overlap)&&(Y.options.drop.overlap=Math.max(Math.min(1,J.overlap),0)),"accept"in J&&(Y.options.drop.accept=J.accept),"checker"in J&&(Y.options.drop.checker=J.checker),Y}return S.bool(J)?(Y.options.drop.enabled=J,Y):Y.options.drop}(this,F)},k.prototype.dropCheck=function(F,Y,J,xe,He,Se){return function(da,Ma,rl,el,cl,Dl,El){var Vl=!1;if(!(El=El||da.getRect(Dl)))return!!da.options.drop.checker&&da.options.drop.checker(Ma,rl,Vl,da,Dl,el,cl);var ir=da.options.drop.overlap;if(ir==="pointer"){var fr=De(el,cl,"drag"),ql=ia(Ma);ql.x+=fr.x,ql.y+=fr.y;var sr=ql.x>El.left&&ql.x<El.right,dn=ql.y>El.top&&ql.y<El.bottom;Vl=sr&&dn}var ar=el.getRect(cl);if(ar&&ir==="center"){var bn=ar.left+ar.width/2,Xr=ar.top+ar.height/2;Vl=bn>=El.left&&bn<=El.right&&Xr>=El.top&&Xr<=El.bottom}return ar&&S.number(ir)&&(Vl=Math.max(0,Math.min(El.right,ar.right)-Math.max(El.left,ar.left))*Math.max(0,Math.min(El.bottom,ar.bottom)-Math.max(El.top,ar.top))/(ar.width*ar.height)>=ir),da.options.drop.checker&&(Vl=da.options.drop.checker(Ma,rl,Vl,da,Dl,el,cl)),Vl}(this,F,Y,J,xe,He,Se)},h.dynamicDrop=function(F){return S.bool(F)?(s.dynamicDrop=F,h):s.dynamicDrop},P(t.phaselessTypes,{dragenter:!0,dragleave:!0,dropactivate:!0,dropdeactivate:!0,dropmove:!0,drop:!0}),t.methodDict.drop="dropzone",s.dynamicDrop=!1,C.actions.drop=Ee.defaults},listeners:{"interactions:before-action-start":function(s){var t=s.interaction;t.prepared.name==="drag"&&(t.dropState={cur:{dropzone:null,element:null},prev:{dropzone:null,element:null},rejected:null,events:null,activeDrops:[]})},"interactions:after-action-start":function(s,t){var h=s.interaction,k=(s.event,s.iEvent);if(h.prepared.name==="drag"){var C=h.dropState;C.activeDrops=[],C.events={},C.activeDrops=na(t,h.element),C.events=Ae(h,0,k),C.events.activate&&(We(C.activeDrops,C.events.activate),t.fire("actions/drop:start",{interaction:h,dragEvent:k}))}},"interactions:action-move":Ye,"interactions:after-action-move":function(s,t){var h=s.interaction,k=s.iEvent;if(h.prepared.name==="drag"){var C=h.dropState;Be(h,C.events),t.fire("actions/drop:move",{interaction:h,dragEvent:k}),C.events={}}},"interactions:action-end":function(s,t){if(s.interaction.prepared.name==="drag"){var h=s.interaction,k=s.iEvent;Ye(s,t),Be(h,h.dropState.events),t.fire("actions/drop:end",{interaction:h,dragEvent:k})}},"interactions:stop":function(s){var t=s.interaction;if(t.prepared.name==="drag"){var h=t.dropState;h&&(h.activeDrops=null,h.events=null,h.cur.dropzone=null,h.cur.element=null,h.prev.dropzone=null,h.prev.element=null,h.rejected=!1)}}},getActiveDrops:na,getDrop:va,getDropEvents:Ae,fireDropEvents:Be,filterEventType:function(s){return s.search("drag")===0||s.search("drop")===0},defaults:{enabled:!1,accept:null,overlap:"pointer"}},ye=Ee;function $a(s){var t=s.interaction,h=s.iEvent,k=s.phase;if(t.prepared.name==="gesture"){var C=t.pointers.map(function(He){return He.pointer}),F=k==="start",Y=k==="end",J=t.interactable.options.deltaSource;if(h.touches=[C[0],C[1]],F)h.distance=Ta(C,J),h.box=Fa(C),h.scale=1,h.ds=0,h.angle=fa(C,J),h.da=0,t.gesture.startDistance=h.distance,t.gesture.startAngle=h.angle;else if(Y||t.pointers.length<2){var xe=t.prevEvent;h.distance=xe.distance,h.box=xe.box,h.scale=xe.scale,h.ds=0,h.angle=xe.angle,h.da=0}else h.distance=Ta(C,J),h.box=Fa(C),h.scale=h.distance/t.gesture.startDistance,h.angle=fa(C,J),h.ds=h.scale-t.gesture.scale,h.da=h.angle-t.gesture.angle;t.gesture.distance=h.distance,t.gesture.angle=h.angle,S.number(h.scale)&&h.scale!==1/0&&!isNaN(h.scale)&&(t.gesture.scale=h.scale)}}var wl={id:"actions/gesture",before:["actions/drag","actions/resize"],install:function(s){var t=s.actions,h=s.Interactable,k=s.defaults;h.prototype.gesturable=function(C){return S.object(C)?(this.options.gesture.enabled=C.enabled!==!1,this.setPerAction("gesture",C),this.setOnEvents("gesture",C),this):S.bool(C)?(this.options.gesture.enabled=C,this):this.options.gesture},t.map.gesture=wl,t.methodDict.gesture="gesturable",k.actions.gesture=wl.defaults},listeners:{"interactions:action-start":$a,"interactions:action-move":$a,"interactions:action-end":$a,"interactions:new":function(s){s.interaction.gesture={angle:0,distance:0,scale:1,startAngle:0,startDistance:0}},"auto-start:check":function(s){if(!(s.interaction.pointers.length<2)){var t=s.interactable.options.gesture;if(t&&t.enabled)return s.action={name:"gesture"},!1}}},defaults:{},getCursor:function(){return""},filterEventType:function(s){return s.search("gesture")===0}},Qa=wl;function Pl(s,t,h,k,C,F,Y){if(!t)return!1;if(t===!0){var J=S.number(F.width)?F.width:F.right-F.left,xe=S.number(F.height)?F.height:F.bottom-F.top;if(Y=Math.min(Y,Math.abs((s==="left"||s==="right"?J:xe)/2)),J<0&&(s==="left"?s="right":s==="right"&&(s="left")),xe<0&&(s==="top"?s="bottom":s==="bottom"&&(s="top")),s==="left"){var He=J>=0?F.left:F.right;return h.x<He+Y}if(s==="top"){var Se=xe>=0?F.top:F.bottom;return h.y<Se+Y}if(s==="right")return h.x>(J>=0?F.right:F.left)-Y;if(s==="bottom")return h.y>(xe>=0?F.bottom:F.top)-Y}return!!S.element(k)&&(S.element(t)?t===k:G(k,t,C))}function gl(s){var t=s.iEvent,h=s.interaction;if(h.prepared.name==="resize"&&h.resizeAxes){var k=t;h.interactable.options.resize.square?(h.resizeAxes==="y"?k.delta.x=k.delta.y:k.delta.y=k.delta.x,k.axes="xy"):(k.axes=h.resizeAxes,h.resizeAxes==="x"?k.delta.y=0:h.resizeAxes==="y"&&(k.delta.x=0))}}var jl,al,Hl={id:"actions/resize",before:["actions/drag"],install:function(s){var t=s.actions,h=s.browser,k=s.Interactable,C=s.defaults;Hl.cursors=function(F){return F.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"}}(h),Hl.defaultMargin=h.supportsTouch||h.supportsPointerEvent?20:10,k.prototype.resizable=function(F){return function(Y,J,xe){return S.object(J)?(Y.options.resize.enabled=J.enabled!==!1,Y.setPerAction("resize",J),Y.setOnEvents("resize",J),S.string(J.axis)&&/^x$|^y$|^xy$/.test(J.axis)?Y.options.resize.axis=J.axis:J.axis===null&&(Y.options.resize.axis=xe.defaults.actions.resize.axis),S.bool(J.preserveAspectRatio)?Y.options.resize.preserveAspectRatio=J.preserveAspectRatio:S.bool(J.square)&&(Y.options.resize.square=J.square),Y):S.bool(J)?(Y.options.resize.enabled=J,Y):Y.options.resize}(this,F,s)},t.map.resize=Hl,t.methodDict.resize="resizable",C.actions.resize=Hl.defaults},listeners:{"interactions:new":function(s){s.interaction.resizeAxes="xy"},"interactions:action-start":function(s){(function(t){var h=t.iEvent,k=t.interaction;if(k.prepared.name==="resize"&&k.prepared.edges){var C=h,F=k.rect;k._rects={start:P({},F),corrected:P({},F),previous:P({},F),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},C.edges=k.prepared.edges,C.rect=k._rects.corrected,C.deltaRect=k._rects.delta}})(s),gl(s)},"interactions:action-move":function(s){(function(t){var h=t.iEvent,k=t.interaction;if(k.prepared.name==="resize"&&k.prepared.edges){var C=h,F=k.interactable.options.resize.invert,Y=F==="reposition"||F==="negate",J=k.rect,xe=k._rects,He=xe.start,Se=xe.corrected,da=xe.delta,Ma=xe.previous;if(P(Ma,Se),Y){if(P(Se,J),F==="reposition"){if(Se.top>Se.bottom){var rl=Se.top;Se.top=Se.bottom,Se.bottom=rl}if(Se.left>Se.right){var el=Se.left;Se.left=Se.right,Se.right=el}}}else Se.top=Math.min(J.top,He.bottom),Se.bottom=Math.max(J.bottom,He.top),Se.left=Math.min(J.left,He.right),Se.right=Math.max(J.right,He.left);for(var cl in Se.width=Se.right-Se.left,Se.height=Se.bottom-Se.top,Se)da[cl]=Se[cl]-Ma[cl];C.edges=k.prepared.edges,C.rect=Se,C.deltaRect=da}})(s),gl(s)},"interactions:action-end":function(s){var t=s.iEvent,h=s.interaction;if(h.prepared.name==="resize"&&h.prepared.edges){var k=t;k.edges=h.prepared.edges,k.rect=h._rects.corrected,k.deltaRect=h._rects.delta}},"auto-start:check":function(s){var t=s.interaction,h=s.interactable,k=s.element,C=s.rect,F=s.buttons;if(C){var Y=P({},t.coords.cur.page),J=h.options.resize;if(J&&J.enabled&&(!t.pointerIsDown||!/mouse|pointer/.test(t.pointerType)||(F&J.mouseButtons)!=0)){if(S.object(J.edges)){var xe={left:!1,right:!1,top:!1,bottom:!1};for(var He in xe)xe[He]=Pl(He,J.edges[He],Y,t._latestPointer.eventTarget,k,C,J.margin||Hl.defaultMargin);xe.left=xe.left&&!xe.right,xe.top=xe.top&&!xe.bottom,(xe.left||xe.right||xe.top||xe.bottom)&&(s.action={name:"resize",edges:xe})}else{var Se=J.axis!=="y"&&Y.x>C.right-Hl.defaultMargin,da=J.axis!=="x"&&Y.y>C.bottom-Hl.defaultMargin;(Se||da)&&(s.action={name:"resize",axes:(Se?"x":"")+(da?"y":"")})}return!s.action&&void 0}}}},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor:function(s){var t=s.edges,h=s.axis,k=s.name,C=Hl.cursors,F=null;if(h)F=C[k+h];else if(t){for(var Y="",J=0,xe=["top","bottom","left","right"];J<xe.length;J++){var He=xe[J];t[He]&&(Y+=He)}F=C[Y]}return F},filterEventType:function(s){return s.search("resize")===0},defaultMargin:null},Wa=Hl,Gl={id:"actions",install:function(s){s.usePlugin(Qa),s.usePlugin(Wa),s.usePlugin(X),s.usePlugin(ye)}},Kl=0,Zl={request:function(s){return jl(s)},cancel:function(s){return al(s)},init:function(s){if(jl=s.requestAnimationFrame,al=s.cancelAnimationFrame,!jl)for(var t=["ms","moz","webkit","o"],h=0;h<t.length;h++){var k=t[h];jl=s["".concat(k,"RequestAnimationFrame")],al=s["".concat(k,"CancelAnimationFrame")]||s["".concat(k,"CancelRequestAnimationFrame")]}jl=jl&&jl.bind(s),al=al&&al.bind(s),jl||(jl=function(C){var F=Date.now(),Y=Math.max(0,16-(F-Kl)),J=s.setTimeout(function(){C(F+Y)},Y);return Kl=F+Y,J},al=function(C){return clearTimeout(C)})}},Sl={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(s){Sl.isScrolling=!0,Zl.cancel(Sl.i),s.autoScroll=Sl,Sl.interaction=s,Sl.prevTime=Sl.now(),Sl.i=Zl.request(Sl.scroll)},stop:function(){Sl.isScrolling=!1,Sl.interaction&&(Sl.interaction.autoScroll=null),Zl.cancel(Sl.i)},scroll:function(){var s=Sl.interaction,t=s.interactable,h=s.element,k=s.prepared.name,C=t.options[k].autoScroll,F=dr(C.container,t,h),Y=Sl.now(),J=(Y-Sl.prevTime)/1e3,xe=C.speed*J;if(xe>=1){var He={x:Sl.x*xe,y:Sl.y*xe};if(He.x||He.y){var Se=ga(F);S.window(F)?F.scrollBy(He.x,He.y):F&&(F.scrollLeft+=He.x,F.scrollTop+=He.y);var da=ga(F),Ma={x:da.x-Se.x,y:da.y-Se.y};(Ma.x||Ma.y)&&t.fire({type:"autoscroll",target:h,interactable:t,delta:Ma,interaction:s,container:F})}Sl.prevTime=Y}Sl.isScrolling&&(Zl.cancel(Sl.i),Sl.i=Zl.request(Sl.scroll))},check:function(s,t){var h;return(h=s.options[t].autoScroll)==null?void 0:h.enabled},onInteractionMove:function(s){var t=s.interaction,h=s.pointer;if(t.interacting()&&Sl.check(t.interactable,t.prepared.name))if(t.simulation)Sl.x=Sl.y=0;else{var k,C,F,Y,J=t.interactable,xe=t.element,He=t.prepared.name,Se=J.options[He].autoScroll,da=dr(Se.container,J,xe);if(S.window(da))Y=h.clientX<Sl.margin,k=h.clientY<Sl.margin,C=h.clientX>da.innerWidth-Sl.margin,F=h.clientY>da.innerHeight-Sl.margin;else{var Ma=we(da);Y=h.clientX<Ma.left+Sl.margin,k=h.clientY<Ma.top+Sl.margin,C=h.clientX>Ma.right-Sl.margin,F=h.clientY>Ma.bottom-Sl.margin}Sl.x=C?1:Y?-1:0,Sl.y=F?1:k?-1:0,Sl.isScrolling||(Sl.margin=Se.margin,Sl.speed=Se.speed,Sl.start(t))}}};function dr(s,t,h){return(S.string(s)?Ke(s,t,h):s)||_(h)}function ga(s){return S.window(s)&&(s=window.document.body),{x:s.scrollLeft,y:s.scrollTop}}var il={id:"auto-scroll",install:function(s){var t=s.defaults,h=s.actions;s.autoScroll=Sl,Sl.now=function(){return s.now()},h.phaselessTypes.autoscroll=!0,t.perAction.autoScroll=Sl.defaults},listeners:{"interactions:new":function(s){s.interaction.autoScroll=null},"interactions:destroy":function(s){s.interaction.autoScroll=null,Sl.stop(),Sl.interaction&&(Sl.interaction=null)},"interactions:stop":Sl.stop,"interactions:action-move":function(s){return Sl.onInteractionMove(s)}}},fl=il;function Bl(s,t){var h=!1;return function(){return h||(O.console.warn(t),h=!0),s.apply(this,arguments)}}function Ha(s,t){return s.name=t.name,s.axis=t.axis,s.edges=t.edges,s}function Sa(s){return S.bool(s)?(this.options.styleCursor=s,this):s===null?(delete this.options.styleCursor,this):this.options.styleCursor}function ll(s){return S.func(s)?(this.options.actionChecker=s,this):s===null?(delete this.options.actionChecker,this):this.options.actionChecker}var Te={id:"auto-start/interactableMethods",install:function(s){var t=s.Interactable;t.prototype.getAction=function(h,k,C,F){var Y=function(J,xe,He,Se,da){var Ma=J.getRect(Se),rl=xe.buttons||{0:1,1:4,3:8,4:16}[xe.button],el={action:null,interactable:J,interaction:He,element:Se,rect:Ma,buttons:rl};return da.fire("auto-start:check",el),el.action}(this,k,C,F,s);return this.options.actionChecker?this.options.actionChecker(h,k,Y,this,F,C):Y},t.prototype.ignoreFrom=Bl(function(h){return this._backCompatOption("ignoreFrom",h)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),t.prototype.allowFrom=Bl(function(h){return this._backCompatOption("allowFrom",h)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),t.prototype.actionChecker=ll,t.prototype.styleCursor=Sa}};function oa(s,t,h,k,C){return t.testIgnoreAllow(t.options[s.name],h,k)&&t.options[s.name].enabled&&Pa(t,h,s,C)?s:null}function Ka(s,t,h,k,C,F,Y){for(var J=0,xe=k.length;J<xe;J++){var He=k[J],Se=C[J],da=He.getAction(t,h,s,Se);if(da){var Ma=oa(da,He,Se,F,Y);if(Ma)return{action:Ma,interactable:He,element:Se}}}return{action:null,interactable:null,element:null}}function pe(s,t,h,k,C){var F=[],Y=[],J=k;function xe(Se){F.push(Se),Y.push(J)}for(;S.element(J);){F=[],Y=[],C.interactables.forEachMatch(J,xe);var He=Ka(s,t,h,F,Y,k,C);if(He.action&&!He.interactable.options[He.action.name].manualStart)return He;J=ze(J)}return{action:null,interactable:null,element:null}}function _a(s,t,h){var k=t.action,C=t.interactable,F=t.element;k=k||{name:null},s.interactable=C,s.element=F,Ha(s.prepared,k),s.rect=C&&k.name?C.getRect(F):null,ca(s,h),h.fire("autoStart:prepared",{interaction:s})}function Pa(s,t,h,k){var C=s.options,F=C[h.name].max,Y=C[h.name].maxPerElement,J=k.autoStart.maxInteractions,xe=0,He=0,Se=0;if(!(F&&Y&&J))return!1;for(var da=0,Ma=k.interactions.list;da<Ma.length;da++){var rl=Ma[da],el=rl.prepared.name;if(rl.interacting()&&(++xe>=J||rl.interactable===s&&((He+=el===h.name?1:0)>=F||rl.element===t&&(Se++,el===h.name&&Se>=Y))))return!1}return J>0}function ul(s,t){return S.number(s)?(t.autoStart.maxInteractions=s,this):t.autoStart.maxInteractions}function Ol(s,t,h){var k=h.autoStart.cursorElement;k&&k!==s&&(k.style.cursor=""),s.ownerDocument.documentElement.style.cursor=t,s.style.cursor=t,h.autoStart.cursorElement=t?s:null}function ca(s,t){var h=s.interactable,k=s.element,C=s.prepared;if(s.pointerType==="mouse"&&h&&h.options.styleCursor){var F="";if(C.name){var Y=h.options[C.name].cursorChecker;F=S.func(Y)?Y(C,h,k,s._interacting):t.actions.map[C.name].getCursor(C)}Ol(s.element,F||"",t)}else t.autoStart.cursorElement&&Ol(t.autoStart.cursorElement,"",t)}var Xa={id:"auto-start/base",before:["actions"],install:function(s){var t=s.interactStatic,h=s.defaults;s.usePlugin(Te),h.base.actionChecker=null,h.base.styleCursor=!0,P(h.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),t.maxInteractions=function(k){return ul(k,s)},s.autoStart={maxInteractions:1/0,withinInteractionLimit:Pa,cursorElement:null}},listeners:{"interactions:down":function(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget;h.interacting()||_a(h,pe(h,k,C,F,t),t)},"interactions:move":function(s,t){(function(h,k){var C=h.interaction,F=h.pointer,Y=h.event,J=h.eventTarget;C.pointerType!=="mouse"||C.pointerIsDown||C.interacting()||_a(C,pe(C,F,Y,J,k),k)})(s,t),function(h,k){var C=h.interaction;if(C.pointerIsDown&&!C.interacting()&&C.pointerWasMoved&&C.prepared.name){k.fire("autoStart:before-start",h);var F=C.interactable,Y=C.prepared.name;Y&&F&&(F.options[Y].manualStart||!Pa(F,C.element,C.prepared,k)?C.stop():(C.start(C.prepared,F,C.element),ca(C,k)))}}(s,t)},"interactions:stop":function(s,t){var h=s.interaction,k=h.interactable;k&&k.options.styleCursor&&Ol(h.element,"",t)}},maxInteractions:ul,withinInteractionLimit:Pa,validateAction:oa},ua=Xa,wa={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":function(s,t){var h=s.interaction,k=s.eventTarget,C=s.dx,F=s.dy;if(h.prepared.name==="drag"){var Y=Math.abs(C),J=Math.abs(F),xe=h.interactable.options.drag,He=xe.startAxis,Se=Y>J?"x":Y<J?"y":"xy";if(h.prepared.axis=xe.lockAxis==="start"?Se[0]:xe.lockAxis,Se!=="xy"&&He!=="xy"&&He!==Se){h.prepared.name=null;for(var da=k,Ma=function(el){if(el!==h.interactable){var cl=h.interactable.options.drag;if(!cl.manualStart&&el.testIgnoreAllow(cl,da,k)){var Dl=el.getAction(h.downPointer,h.downEvent,h,da);if(Dl&&Dl.name==="drag"&&function(El,Vl){if(!Vl)return!1;var ir=Vl.options.drag.startAxis;return El==="xy"||ir==="xy"||ir===El}(Se,el)&&ua.validateAction(Dl,el,da,k,t))return el}}};S.element(da);){var rl=t.interactables.forEachMatch(da,Ma);if(rl){h.prepared.name="drag",h.interactable=rl,h.element=da;break}da=ze(da)}}}}}};function Ba(s){var t=s.prepared&&s.prepared.name;if(!t)return null;var h=s.interactable.options;return h[t].hold||h[t].delay}var hl={id:"auto-start/hold",install:function(s){var t=s.defaults;s.usePlugin(ua),t.perAction.hold=0,t.perAction.delay=0},listeners:{"interactions:new":function(s){s.interaction.autoStartHoldTimer=null},"autoStart:prepared":function(s){var t=s.interaction,h=Ba(t);h>0&&(t.autoStartHoldTimer=setTimeout(function(){t.start(t.prepared,t.interactable,t.element)},h))},"interactions:move":function(s){var t=s.interaction,h=s.duplicate;t.autoStartHoldTimer&&t.pointerWasMoved&&!h&&(clearTimeout(t.autoStartHoldTimer),t.autoStartHoldTimer=null)},"autoStart:before-start":function(s){var t=s.interaction;Ba(t)>0&&(t.prepared.name=null)}},getHoldDuration:Ba},Fe=hl,bl={id:"auto-start",install:function(s){s.usePlugin(ua),s.usePlugin(Fe),s.usePlugin(wa)}},tr=function(s){return/^(always|never|auto)$/.test(s)?(this.options.preventDefault=s,this):S.bool(s)?(this.options.preventDefault=s?"always":"never",this):this.options.preventDefault};function xr(s){var t=s.interaction,h=s.event;t.interactable&&t.interactable.checkAndPreventDefault(h)}var Ra={id:"core/interactablePreventDefault",install:function(s){var t=s.Interactable;t.prototype.preventDefault=tr,t.prototype.checkAndPreventDefault=function(h){return function(k,C,F){var Y=k.options.preventDefault;if(Y!=="never")if(Y!=="always"){if(C.events.supportsPassive&&/^touch(start|move)$/.test(F.type)){var J=_(F.target).document,xe=C.getDocOptions(J);if(!xe||!xe.events||xe.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(F.type)||S.element(F.target)&&te(F.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||F.preventDefault()}else F.preventDefault()}(this,s,h)},s.interactions.docEvents.push({type:"dragstart",listener:function(h){for(var k=0,C=s.interactions.list;k<C.length;k++){var F=C[k];if(F.element&&(F.element===h.target||ae(F.element,h.target)))return void F.interactable.checkAndPreventDefault(h)}}})},listeners:["down","move","up","cancel"].reduce(function(s,t){return s["interactions:".concat(t)]=xr,s},{})};function kl(s,t){if(t.phaselessTypes[s])return!0;for(var h in t.map)if(s.indexOf(h)===0&&s.substr(h.length)in t.phases)return!0;return!1}function Ml(s){var t={};for(var h in s){var k=s[h];S.plainObject(k)?t[h]=Ml(k):S.array(k)?t[h]=Qe(k):t[h]=k}return t}var Oa=function(){function s(t){o(this,s),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=t,this.result=aa(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}return c(s,[{key:"start",value:function(t,h){var k,C,F=t.phase,Y=this.interaction,J=function(He){var Se=He.interactable.options[He.prepared.name],da=Se.modifiers;return da&&da.length?da:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(function(Ma){var rl=Se[Ma];return rl&&rl.enabled&&{options:rl,methods:rl._methods}}).filter(function(Ma){return!!Ma})}(Y);this.prepareStates(J),this.startEdges=P({},Y.edges),this.edges=P({},this.startEdges),this.startOffset=(k=Y.rect,C=h,k?{left:C.x-k.left,top:C.y-k.top,right:k.right-C.x,bottom:k.bottom-C.y}:{left:0,top:0,right:0,bottom:0}),this.startDelta={x:0,y:0};var xe=this.fillArg({phase:F,pageCoords:h,preEnd:!1});return this.result=aa(),this.startAll(xe),this.result=this.setAll(xe)}},{key:"fillArg",value:function(t){var h=this.interaction;return t.interaction=h,t.interactable=h.interactable,t.element=h.element,t.rect||(t.rect=h.rect),t.edges||(t.edges=this.startEdges),t.startOffset=this.startOffset,t}},{key:"startAll",value:function(t){for(var h=0,k=this.states;h<k.length;h++){var C=k[h];C.methods.start&&(t.state=C,C.methods.start(t))}}},{key:"setAll",value:function(t){var h=t.phase,k=t.preEnd,C=t.skipModifiers,F=t.rect,Y=t.edges;t.coords=P({},t.pageCoords),t.rect=P({},F),t.edges=P({},Y);for(var J=C?this.states.slice(C):this.states,xe=aa(t.coords,t.rect),He=0;He<J.length;He++){var Se,da=J[He],Ma=da.options,rl=P({},t.coords),el=null;(Se=da.methods)!=null&&Se.set&&this.shouldDo(Ma,k,h)&&(t.state=da,el=da.methods.set(t),de(t.edges,t.rect,{x:t.coords.x-rl.x,y:t.coords.y-rl.y})),xe.eventProps.push(el)}P(this.edges,t.edges),xe.delta.x=t.coords.x-t.pageCoords.x,xe.delta.y=t.coords.y-t.pageCoords.y,xe.rectDelta.left=t.rect.left-F.left,xe.rectDelta.right=t.rect.right-F.right,xe.rectDelta.top=t.rect.top-F.top,xe.rectDelta.bottom=t.rect.bottom-F.bottom;var cl=this.result.coords,Dl=this.result.rect;if(cl&&Dl){var El=xe.rect.left!==Dl.left||xe.rect.right!==Dl.right||xe.rect.top!==Dl.top||xe.rect.bottom!==Dl.bottom;xe.changed=El||cl.x!==xe.coords.x||cl.y!==xe.coords.y}return xe}},{key:"applyToInteraction",value:function(t){var h=this.interaction,k=t.phase,C=h.coords.cur,F=h.coords.start,Y=this.result,J=this.startDelta,xe=Y.delta;k==="start"&&P(this.startDelta,Y.delta);for(var He=0,Se=[[F,J],[C,xe]];He<Se.length;He++){var da=Se[He],Ma=da[0],rl=da[1];Ma.page.x+=rl.x,Ma.page.y+=rl.y,Ma.client.x+=rl.x,Ma.client.y+=rl.y}var el=this.result.rectDelta,cl=t.rect||h.rect;cl.left+=el.left,cl.right+=el.right,cl.top+=el.top,cl.bottom+=el.bottom,cl.width=cl.right-cl.left,cl.height=cl.bottom-cl.top}},{key:"setAndApply",value:function(t){var h=this.interaction,k=t.phase,C=t.preEnd,F=t.skipModifiers,Y=this.setAll(this.fillArg({preEnd:C,phase:k,pageCoords:t.modifiedCoords||h.coords.cur.page}));if(this.result=Y,!Y.changed&&(!F||F<this.states.length)&&h.interacting())return!1;if(t.modifiedCoords){var J=h.coords.cur.page,xe={x:t.modifiedCoords.x-J.x,y:t.modifiedCoords.y-J.y};Y.coords.x+=xe.x,Y.coords.y+=xe.y,Y.delta.x+=xe.x,Y.delta.y+=xe.y}this.applyToInteraction(t)}},{key:"beforeEnd",value:function(t){var h=t.interaction,k=t.event,C=this.states;if(C&&C.length){for(var F=!1,Y=0;Y<C.length;Y++){var J=C[Y];t.state=J;var xe=J.options,He=J.methods,Se=He.beforeEnd&&He.beforeEnd(t);if(Se)return this.endResult=Se,!1;F=F||!F&&this.shouldDo(xe,!0,t.phase,!0)}F&&h.move({event:k,preEnd:!0})}}},{key:"stop",value:function(t){var h=t.interaction;if(this.states&&this.states.length){var k=P({states:this.states,interactable:h.interactable,element:h.element,rect:null},t);this.fillArg(k);for(var C=0,F=this.states;C<F.length;C++){var Y=F[C];k.state=Y,Y.methods.stop&&Y.methods.stop(k)}this.states=null,this.endResult=null}}},{key:"prepareStates",value:function(t){this.states=[];for(var h=0;h<t.length;h++){var k=t[h],C=k.options,F=k.methods,Y=k.name;this.states.push({options:C,methods:F,index:h,name:Y})}return this.states}},{key:"restoreInteractionCoords",value:function(t){var h=t.interaction,k=h.coords,C=h.rect,F=h.modification;if(F.result){for(var Y=F.startDelta,J=F.result,xe=J.delta,He=J.rectDelta,Se=0,da=[[k.start,Y],[k.cur,xe]];Se<da.length;Se++){var Ma=da[Se],rl=Ma[0],el=Ma[1];rl.page.x-=el.x,rl.page.y-=el.y,rl.client.x-=el.x,rl.client.y-=el.y}C.left-=He.left,C.right-=He.right,C.top-=He.top,C.bottom-=He.bottom}}},{key:"shouldDo",value:function(t,h,k,C){return!(!t||t.enabled===!1||C&&!t.endOnly||t.endOnly&&!h||k==="start"&&!t.setStart)}},{key:"copyFrom",value:function(t){this.startOffset=t.startOffset,this.startDelta=t.startDelta,this.startEdges=t.startEdges,this.edges=t.edges,this.states=t.states.map(function(h){return Ml(h)}),this.result=aa(P({},t.result.coords),P({},t.result.rect))}},{key:"destroy",value:function(){for(var t in this)this[t]=null}}]),s}();function aa(s,t){return{rect:t,coords:s,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function Rl(s,t){var h=s.defaults,k={start:s.start,set:s.set,beforeEnd:s.beforeEnd,stop:s.stop},C=function(F){var Y=F||{};for(var J in Y.enabled=Y.enabled!==!1,h)J in Y||(Y[J]=h[J]);var xe={options:Y,methods:k,name:t,enable:function(){return Y.enabled=!0,xe},disable:function(){return Y.enabled=!1,xe}};return xe};return t&&typeof t=="string"&&(C._defaults=h,C._methods=k),C}function Yr(s){var t=s.iEvent,h=s.interaction.modification.result;h&&(t.modifiers=h.eventProps)}var Jr={id:"modifiers/base",before:["actions"],install:function(s){s.defaults.perAction.modifiers=[]},listeners:{"interactions:new":function(s){var t=s.interaction;t.modification=new Oa(t)},"interactions:before-action-start":function(s){var t=s.interaction,h=s.interaction.modification;h.start(s,t.coords.start.page),t.edges=h.edges,h.applyToInteraction(s)},"interactions:before-action-move":function(s){var t=s.interaction,h=t.modification,k=h.setAndApply(s);return t.edges=h.edges,k},"interactions:before-action-end":function(s){var t=s.interaction,h=t.modification,k=h.beforeEnd(s);return t.edges=h.startEdges,k},"interactions:action-start":Yr,"interactions:action-move":Yr,"interactions:action-end":Yr,"interactions:after-action-start":function(s){return s.interaction.modification.restoreInteractionCoords(s)},"interactions:after-action-move":function(s){return s.interaction.modification.restoreInteractionCoords(s)},"interactions:stop":function(s){return s.interaction.modification.stop(s)}}},vn=Jr,en={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}},Ar=function(s){m(h,s);var t=D(h);function h(k,C,F,Y,J,xe,He){var Se;o(this,h),(Se=t.call(this,k)).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,J=J||k.element;var da=k.interactable,Ma=(da&&da.options||en).deltaSource,rl=De(da,J,F),el=Y==="start",cl=Y==="end",Dl=el?d(Se):k.prevEvent,El=el?k.coords.start:cl?{page:Dl.page,client:Dl.client,timeStamp:k.coords.cur.timeStamp}:k.coords.cur;return Se.page=P({},El.page),Se.client=P({},El.client),Se.rect=P({},k.rect),Se.timeStamp=El.timeStamp,cl||(Se.page.x-=rl.x,Se.page.y-=rl.y,Se.client.x-=rl.x,Se.client.y-=rl.y),Se.ctrlKey=C.ctrlKey,Se.altKey=C.altKey,Se.shiftKey=C.shiftKey,Se.metaKey=C.metaKey,Se.button=C.button,Se.buttons=C.buttons,Se.target=J,Se.currentTarget=J,Se.preEnd=xe,Se.type=He||F+(Y||""),Se.interactable=da,Se.t0=el?k.pointers[k.pointers.length-1].downTime:Dl.t0,Se.x0=k.coords.start.page.x-rl.x,Se.y0=k.coords.start.page.y-rl.y,Se.clientX0=k.coords.start.client.x-rl.x,Se.clientY0=k.coords.start.client.y-rl.y,Se.delta=el||cl?{x:0,y:0}:{x:Se[Ma].x-Dl[Ma].x,y:Se[Ma].y-Dl[Ma].y},Se.dt=k.coords.delta.timeStamp,Se.duration=Se.timeStamp-Se.t0,Se.velocity=P({},k.coords.velocity[Ma]),Se.speed=Ge(Se.velocity.x,Se.velocity.y),Se.swipe=cl||Y==="inertiastart"?Se.getSwipe():null,Se}return c(h,[{key:"getSwipe",value:function(){var k=this._interaction;if(k.prevEvent.speed<600||this.timeStamp-k.prevEvent.timeStamp>150)return null;var C=180*Math.atan2(k.prevEvent.velocityY,k.prevEvent.velocityX)/Math.PI;C<0&&(C+=360);var F=112.5<=C&&C<247.5,Y=202.5<=C&&C<337.5;return{up:Y,down:!Y&&22.5<=C&&C<157.5,left:F,right:!F&&(292.5<=C||C<67.5),angle:C,speed:k.prevEvent.speed,velocity:{x:k.prevEvent.velocityX,y:k.prevEvent.velocityY}}}},{key:"preventDefault",value:function(){}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}}]),h}(Pe);Object.defineProperties(Ar.prototype,{pageX:{get:function(){return this.page.x},set:function(s){this.page.x=s}},pageY:{get:function(){return this.page.y},set:function(s){this.page.y=s}},clientX:{get:function(){return this.client.x},set:function(s){this.client.x=s}},clientY:{get:function(){return this.client.y},set:function(s){this.client.y=s}},dx:{get:function(){return this.delta.x},set:function(s){this.delta.x=s}},dy:{get:function(){return this.delta.y},set:function(s){this.delta.y=s}},velocityX:{get:function(){return this.velocity.x},set:function(s){this.velocity.x=s}},velocityY:{get:function(){return this.velocity.y},set:function(s){this.velocity.y=s}}});var Re=c(function s(t,h,k,C,F){o(this,s),this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=t,this.pointer=h,this.event=k,this.downTime=C,this.downTarget=F}),lr=function(s){return s.interactable="",s.element="",s.prepared="",s.pointerIsDown="",s.pointerWasMoved="",s._proxy="",s}({}),Yl=function(s){return s.start="",s.move="",s.end="",s.stop="",s.interacting="",s}({}),an=0,Sr=function(){function s(t){var h=this,k=t.pointerType,C=t.scopeFire;o(this,s),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=Bl(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=an++,this._scopeFire=C,this.pointerType=k;var F=this;this._proxy={};var Y=function(Se){Object.defineProperty(h._proxy,Se,{get:function(){return F[Se]}})};for(var J in lr)Y(J);var xe=function(Se){Object.defineProperty(h._proxy,Se,{value:function(){return F[Se].apply(F,arguments)}})};for(var He in Yl)xe(He);this._scopeFire("interactions:new",{interaction:this})}return c(s,[{key:"pointerMoveTolerance",get:function(){return 1}},{key:"pointerDown",value:function(t,h,k){var C=this.updatePointer(t,h,k,!0),F=this.pointers[C];this._scopeFire("interactions:down",{pointer:t,event:h,eventTarget:k,pointerIndex:C,pointerInfo:F,type:"down",interaction:this})}},{key:"start",value:function(t,h,k){return!(this.interacting()||!this.pointerIsDown||this.pointers.length<(t.name==="gesture"?2:1)||!h.options[t.name].enabled)&&(Ha(this.prepared,t),this.interactable=h,this.element=k,this.rect=h.getRect(k),this.edges=this.prepared.edges?P({},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(t,h,k){this.simulation||this.modification&&this.modification.endResult||this.updatePointer(t,h,k,!1);var C,F,Y=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&&(C=this.coords.cur.client.x-this.coords.start.client.x,F=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=Ge(C,F)>this.pointerMoveTolerance);var J,xe,He,Se=this.getPointerIndex(t),da={pointer:t,pointerIndex:Se,pointerInfo:this.pointers[Se],event:h,type:"move",eventTarget:k,dx:C,dy:F,duplicate:Y,interaction:this};Y||(J=this.coords.velocity,xe=this.coords.delta,He=Math.max(xe.timeStamp/1e3,.001),J.page.x=xe.page.x/He,J.page.y=xe.page.y/He,J.client.x=xe.client.x/He,J.client.y=xe.client.y/He,J.timeStamp=He),this._scopeFire("interactions:move",da),Y||this.simulation||(this.interacting()&&(da.type=null,this.move(da)),this.pointerWasMoved&&ee(this.coords.prev,this.coords.cur))}},{key:"move",value:function(t){t&&t.event||ce(this.coords.delta),(t=P({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},t||{})).phase="move",this._doPhase(t)}},{key:"pointerUp",value:function(t,h,k,C){var F=this.getPointerIndex(t);F===-1&&(F=this.updatePointer(t,h,k,!1));var Y=/cancel$/i.test(h.type)?"cancel":"up";this._scopeFire("interactions:".concat(Y),{pointer:t,pointerIndex:F,pointerInfo:this.pointers[F],event:h,eventTarget:k,type:Y,curEventTarget:C,interaction:this}),this.simulation||this.end(h),this.removePointer(t,h)}},{key:"documentBlur",value:function(t){this.end(t),this._scopeFire("interactions:blur",{event:t,type:"blur",interaction:this})}},{key:"end",value:function(t){var h;this._ending=!0,t=t||this._latestPointer.event,this.interacting()&&(h=this._doPhase({event:t,interaction:this,phase:"end"})),this._ending=!1,h===!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(t){var h=Ve(t);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:Oe(this.pointers,function(k){return k.id===h})}},{key:"getPointerInfo",value:function(t){return this.pointers[this.getPointerIndex(t)]}},{key:"updatePointer",value:function(t,h,k,C){var F,Y,J,xe=Ve(t),He=this.getPointerIndex(t),Se=this.pointers[He];return C=C!==!1&&(C||/(down|start)$/i.test(h.type)),Se?Se.pointer=t:(Se=new Re(xe,t,h,null,null),He=this.pointers.length,this.pointers.push(Se)),ya(this.coords.cur,this.pointers.map(function(da){return da.pointer}),this._now()),F=this.coords.delta,Y=this.coords.prev,J=this.coords.cur,F.page.x=J.page.x-Y.page.x,F.page.y=J.page.y-Y.page.y,F.client.x=J.client.x-Y.client.x,F.client.y=J.client.y-Y.client.y,F.timeStamp=J.timeStamp-Y.timeStamp,C&&(this.pointerIsDown=!0,Se.downTime=this.coords.cur.timeStamp,Se.downTarget=k,V(this.downPointer,t),this.interacting()||(ee(this.coords.start,this.coords.cur),ee(this.coords.prev,this.coords.cur),this.downEvent=h,this.pointerWasMoved=!1)),this._updateLatestPointer(t,h,k),this._scopeFire("interactions:update-pointer",{pointer:t,event:h,eventTarget:k,down:C,pointerInfo:Se,pointerIndex:He,interaction:this}),He}},{key:"removePointer",value:function(t,h){var k=this.getPointerIndex(t);if(k!==-1){var C=this.pointers[k];this._scopeFire("interactions:remove-pointer",{pointer:t,event:h,eventTarget:null,pointerIndex:k,pointerInfo:C,interaction:this}),this.pointers.splice(k,1),this.pointerIsDown=!1}}},{key:"_updateLatestPointer",value:function(t,h,k){this._latestPointer.pointer=t,this._latestPointer.event=h,this._latestPointer.eventTarget=k}},{key:"destroy",value:function(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}},{key:"_createPreparedEvent",value:function(t,h,k,C){return new Ar(this,t,this.prepared.name,h,this.element,k,C)}},{key:"_fireEvent",value:function(t){var h;(h=this.interactable)==null||h.fire(t),(!this.prevEvent||t.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=t)}},{key:"_doPhase",value:function(t){var h=t.event,k=t.phase,C=t.preEnd,F=t.type,Y=this.rect;if(Y&&k==="move"&&(de(this.edges,Y,this.coords.delta[this.interactable.options.deltaSource]),Y.width=Y.right-Y.left,Y.height=Y.bottom-Y.top),this._scopeFire("interactions:before-action-".concat(k),t)===!1)return!1;var J=t.iEvent=this._createPreparedEvent(h,k,C,F);return this._scopeFire("interactions:action-".concat(k),t),k==="start"&&(this.prevEvent=J),this._fireEvent(J),this._scopeFire("interactions:after-action-".concat(k),t),!0}},{key:"_now",value:function(){return Date.now()}}]),s}();function Jl(s){Er(s.interaction)}function Er(s){if(!function(h){return!(!h.offset.pending.x&&!h.offset.pending.y)}(s))return!1;var t=s.offset.pending;return $l(s.coords.cur,t),$l(s.coords.delta,t),de(s.edges,s.rect,t),t.x=0,t.y=0,!0}function Xl(s){var t=s.x,h=s.y;this.offset.pending.x+=t,this.offset.pending.y+=h,this.offset.total.x+=t,this.offset.total.y+=h}function $l(s,t){var h=s.page,k=s.client,C=t.x,F=t.y;h.x+=C,h.y+=F,k.x+=C,k.y+=F}Yl.offsetBy="";var nr={id:"offset",before:["modifiers","pointer-events","actions","inertia"],install:function(s){s.Interaction.prototype.offsetBy=Xl},listeners:{"interactions:new":function(s){s.interaction.offset={total:{x:0,y:0},pending:{x:0,y:0}}},"interactions:update-pointer":function(s){return function(t){t.pointerIsDown&&($l(t.coords.cur,t.offset.total),t.offset.pending.x=0,t.offset.pending.y=0)}(s.interaction)},"interactions:before-action-start":Jl,"interactions:before-action-move":Jl,"interactions:before-action-end":function(s){var t=s.interaction;if(Er(t))return t.move({offset:!0}),t.end(),!1},"interactions:stop":function(s){var t=s.interaction;t.offset.total.x=0,t.offset.total.y=0,t.offset.pending.x=0,t.offset.pending.y=0}}},Ql=nr,Ul=function(){function s(t){o(this,s),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=t}return c(s,[{key:"start",value:function(t){var h=this.interaction,k=Nl(h);if(!k||!k.enabled)return!1;var C=h.coords.velocity.client,F=Ge(C.x,C.y),Y=this.modification||(this.modification=new Oa(h));if(Y.copyFrom(h.modification),this.t0=h._now(),this.allowResume=k.allowResume,this.v0=F,this.currentOffset={x:0,y:0},this.startCoords=h.coords.cur.page,this.modifierArg=Y.fillArg({pageCoords:this.startCoords,preEnd:!0,phase:"inertiastart"}),this.t0-h.coords.cur.timeStamp<50&&F>k.minSpeed&&F>k.endSpeed)this.startInertia();else{if(Y.result=Y.setAll(this.modifierArg),!Y.result.changed)return!1;this.startSmoothEnd()}return h.modification.result.rect=null,h.offsetBy(this.targetOffset),h._doPhase({interaction:h,event:t,phase:"inertiastart"}),h.offsetBy({x:-this.targetOffset.x,y:-this.targetOffset.y}),h.modification.result.rect=null,this.active=!0,h.simulation=this,!0}},{key:"startInertia",value:function(){var t=this,h=this.interaction.coords.velocity.client,k=Nl(this.interaction),C=k.resistance,F=-Math.log(k.endSpeed/this.v0)/C;this.targetOffset={x:(h.x-F)/C,y:(h.y-F)/C},this.te=F,this.lambda_v0=C/this.v0,this.one_ve_v0=1-k.endSpeed/this.v0;var Y=this.modification,J=this.modifierArg;J.pageCoords={x:this.startCoords.x+this.targetOffset.x,y:this.startCoords.y+this.targetOffset.y},Y.result=Y.setAll(J),Y.result.changed&&(this.isModified=!0,this.modifiedOffset={x:this.targetOffset.x+Y.result.delta.x,y:this.targetOffset.y+Y.result.delta.y}),this.onNextFrame(function(){return t.inertiaTick()})}},{key:"startSmoothEnd",value:function(){var t=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 t.smoothEndTick()})}},{key:"onNextFrame",value:function(t){var h=this;this.timeout=Zl.request(function(){h.active&&t()})}},{key:"inertiaTick",value:function(){var t,h,k,C,F,Y,J,xe=this,He=this.interaction,Se=Nl(He).resistance,da=(He._now()-this.t0)/1e3;if(da<this.te){var Ma,rl=1-(Math.exp(-Se*da)-this.lambda_v0)/this.one_ve_v0;this.isModified?(t=0,h=0,k=this.targetOffset.x,C=this.targetOffset.y,F=this.modifiedOffset.x,Y=this.modifiedOffset.y,Ma={x:er(J=rl,t,k,F),y:er(J,h,C,Y)}):Ma={x:this.targetOffset.x*rl,y:this.targetOffset.y*rl};var el={x:Ma.x-this.currentOffset.x,y:Ma.y-this.currentOffset.y};this.currentOffset.x+=el.x,this.currentOffset.y+=el.y,He.offsetBy(el),He.move(),this.onNextFrame(function(){return xe.inertiaTick()})}else He.offsetBy({x:this.modifiedOffset.x-this.currentOffset.x,y:this.modifiedOffset.y-this.currentOffset.y}),this.end()}},{key:"smoothEndTick",value:function(){var t=this,h=this.interaction,k=h._now()-this.t0,C=Nl(h).smoothEndDuration;if(k<C){var F={x:Ur(k,0,this.targetOffset.x,C),y:Ur(k,0,this.targetOffset.y,C)},Y={x:F.x-this.currentOffset.x,y:F.y-this.currentOffset.y};this.currentOffset.x+=Y.x,this.currentOffset.y+=Y.y,h.offsetBy(Y),h.move({skipModifiers:this.modifierCount}),this.onNextFrame(function(){return t.smoothEndTick()})}else h.offsetBy({x:this.targetOffset.x-this.currentOffset.x,y:this.targetOffset.y-this.currentOffset.y}),this.end()}},{key:"resume",value:function(t){var h=t.pointer,k=t.event,C=t.eventTarget,F=this.interaction;F.offsetBy({x:-this.currentOffset.x,y:-this.currentOffset.y}),F.updatePointer(h,k,C,!0),F._doPhase({interaction:F,event:k,phase:"resume"}),ee(F.coords.prev,F.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,Zl.cancel(this.timeout)}}]),s}();function Nl(s){var t=s.interactable,h=s.prepared;return t&&t.options&&h.name&&t.options[h.name].inertia}var Vr={id:"inertia",before:["modifiers","actions"],install:function(s){var t=s.defaults;s.usePlugin(Ql),s.usePlugin(vn),s.actions.phases.inertiastart=!0,s.actions.phases.resume=!0,t.perAction.inertia={enabled:!1,resistance:10,minSpeed:100,endSpeed:10,allowResume:!0,smoothEndDuration:300}},listeners:{"interactions:new":function(s){var t=s.interaction;t.inertia=new Ul(t)},"interactions:before-action-end":function(s){var t=s.interaction,h=s.event;return(!t._interacting||t.simulation||!t.inertia.start(h))&&null},"interactions:down":function(s){var t=s.interaction,h=s.eventTarget,k=t.inertia;if(k.active)for(var C=h;S.element(C);){if(C===t.element){k.resume(s);break}C=ze(C)}},"interactions:stop":function(s){var t=s.interaction.inertia;t.active&&t.stop()},"interactions:before-action-resume":function(s){var t=s.interaction.modification;t.stop(s),t.start(s,s.interaction.coords.cur.page),t.applyToInteraction(s)},"interactions:before-action-inertiastart":function(s){return s.interaction.modification.setAndApply(s)},"interactions:action-resume":Yr,"interactions:action-inertiastart":Yr,"interactions:after-action-inertiastart":function(s){return s.interaction.modification.restoreInteractionCoords(s)},"interactions:after-action-resume":function(s){return s.interaction.modification.restoreInteractionCoords(s)}}};function er(s,t,h,k){var C=1-s;return C*C*t+2*C*s*h+s*s*k}function Ur(s,t,h,k){return-h*(s/=k)*(s-2)+t}var Br=Vr;function Tr(s,t){for(var h=0;h<t.length;h++){var k=t[h];if(s.immediatePropagationStopped)break;k(s)}}var gn=function(){function s(t){o(this,s),this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=P({},t||{})}return c(s,[{key:"fire",value:function(t){var h,k=this.global;(h=this.types[t.type])&&Tr(t,h),!t.propagationStopped&&k&&(h=k[t.type])&&Tr(t,h)}},{key:"on",value:function(t,h){var k=Xe(t,h);for(t in k)this.types[t]=ma(this.types[t]||[],k[t])}},{key:"off",value:function(t,h){var k=Xe(t,h);for(t in k){var C=this.types[t];if(C&&C.length)for(var F=0,Y=k[t];F<Y.length;F++){var J=Y[F],xe=C.indexOf(J);xe!==-1&&C.splice(xe,1)}}}},{key:"getRect",value:function(t){return null}}]),s}(),Sn=function(){function s(t){o(this,s),this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=t,V(this,t)}return c(s,[{key:"preventOriginalDefault",value:function(){this.originalEvent.preventDefault()}},{key:"stopPropagation",value:function(){this.originalEvent.stopPropagation()}},{key:"stopImmediatePropagation",value:function(){this.originalEvent.stopImmediatePropagation()}}]),s}();function Cn(s){return S.object(s)?{capture:!!s.capture,passive:!!s.passive}:{capture:!!s,passive:!1}}function mn(s,t){return s===t||(typeof s=="boolean"?!!t.capture===s&&!t.passive:!!s.capture==!!t.capture&&!!s.passive==!!t.passive)}var On={id:"events",install:function(s){var t,h=[],k={},C=[],F={add:Y,remove:J,addDelegate:function(Se,da,Ma,rl,el){var cl=Cn(el);if(!k[Ma]){k[Ma]=[];for(var Dl=0;Dl<C.length;Dl++){var El=C[Dl];Y(El,Ma,xe),Y(El,Ma,He,!0)}}var Vl=k[Ma],ir=$e(Vl,function(fr){return fr.selector===Se&&fr.context===da});ir||(ir={selector:Se,context:da,listeners:[]},Vl.push(ir)),ir.listeners.push({func:rl,options:cl})},removeDelegate:function(Se,da,Ma,rl,el){var cl,Dl=Cn(el),El=k[Ma],Vl=!1;if(El)for(cl=El.length-1;cl>=0;cl--){var ir=El[cl];if(ir.selector===Se&&ir.context===da){for(var fr=ir.listeners,ql=fr.length-1;ql>=0;ql--){var sr=fr[ql];if(sr.func===rl&&mn(sr.options,Dl)){fr.splice(ql,1),fr.length||(El.splice(cl,1),J(da,Ma,xe),J(da,Ma,He,!0)),Vl=!0;break}}if(Vl)break}}},delegateListener:xe,delegateUseCapture:He,delegatedEvents:k,documents:C,targets:h,supportsOptions:!1,supportsPassive:!1};function Y(Se,da,Ma,rl){if(Se.addEventListener){var el=Cn(rl),cl=$e(h,function(Dl){return Dl.eventTarget===Se});cl||(cl={eventTarget:Se,events:{}},h.push(cl)),cl.events[da]||(cl.events[da]=[]),$e(cl.events[da],function(Dl){return Dl.func===Ma&&mn(Dl.options,el)})||(Se.addEventListener(da,Ma,F.supportsOptions?el:el.capture),cl.events[da].push({func:Ma,options:el}))}}function J(Se,da,Ma,rl){if(Se.addEventListener&&Se.removeEventListener){var el=Oe(h,function(dn){return dn.eventTarget===Se}),cl=h[el];if(cl&&cl.events)if(da!=="all"){var Dl=!1,El=cl.events[da];if(El){if(Ma==="all"){for(var Vl=El.length-1;Vl>=0;Vl--){var ir=El[Vl];J(Se,da,ir.func,ir.options)}return}for(var fr=Cn(rl),ql=0;ql<El.length;ql++){var sr=El[ql];if(sr.func===Ma&&mn(sr.options,fr)){Se.removeEventListener(da,Ma,F.supportsOptions?fr:fr.capture),El.splice(ql,1),El.length===0&&(delete cl.events[da],Dl=!0);break}}}Dl&&!Object.keys(cl.events).length&&h.splice(el,1)}else for(da in cl.events)cl.events.hasOwnProperty(da)&&J(Se,da,"all")}}function xe(Se,da){for(var Ma=Cn(da),rl=new Sn(Se),el=k[Se.type],cl=sa(Se)[0],Dl=cl;S.element(Dl);){for(var El=0;El<el.length;El++){var Vl=el[El],ir=Vl.selector,fr=Vl.context;if(te(Dl,ir)&&ae(fr,cl)&&ae(fr,Dl)){var ql=Vl.listeners;rl.currentTarget=Dl;for(var sr=0;sr<ql.length;sr++){var dn=ql[sr];mn(dn.options,Ma)&&dn.func(rl)}}}Dl=ze(Dl)}}function He(Se){return xe(Se,!0)}return(t=s.document)==null||t.createElement("div").addEventListener("test",null,{get capture(){return F.supportsOptions=!0},get passive(){return F.supportsPassive=!0}}),s.events=F,F}},rn={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search:function(s){for(var t=0,h=rn.methodOrder;t<h.length;t++){var k=h[t],C=rn[k](s);if(C)return C}return null},simulationResume:function(s){var t=s.pointerType,h=s.eventType,k=s.eventTarget,C=s.scope;if(!/down|start/i.test(h))return null;for(var F=0,Y=C.interactions.list;F<Y.length;F++){var J=Y[F],xe=k;if(J.simulation&&J.simulation.allowResume&&J.pointerType===t)for(;xe;){if(xe===J.element)return J;xe=ze(xe)}}return null},mouseOrPen:function(s){var t,h=s.pointerId,k=s.pointerType,C=s.eventType,F=s.scope;if(k!=="mouse"&&k!=="pen")return null;for(var Y=0,J=F.interactions.list;Y<J.length;Y++){var xe=J[Y];if(xe.pointerType===k){if(xe.simulation&&!Dn(xe,h))continue;if(xe.interacting())return xe;t||(t=xe)}}if(t)return t;for(var He=0,Se=F.interactions.list;He<Se.length;He++){var da=Se[He];if(!(da.pointerType!==k||/down/i.test(C)&&da.simulation))return da}return null},hasPointer:function(s){for(var t=s.pointerId,h=0,k=s.scope.interactions.list;h<k.length;h++){var C=k[h];if(Dn(C,t))return C}return null},idle:function(s){for(var t=s.pointerType,h=0,k=s.scope.interactions.list;h<k.length;h++){var C=k[h];if(C.pointers.length===1){var F=C.interactable;if(F&&(!F.options.gesture||!F.options.gesture.enabled))continue}else if(C.pointers.length>=2)continue;if(!C.interacting()&&t===C.pointerType)return C}return null}};function Dn(s,t){return s.pointers.some(function(h){return h.id===t})}var Vn=rn,nn=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function Fn(s,t){return function(h){var k=t.interactions.list,C=ja(h),F=sa(h),Y=F[0],J=F[1],xe=[];if(/^touch/.test(h.type)){t.prevTouchTime=t.now();for(var He=0,Se=h.changedTouches;He<Se.length;He++){var da=Se[He],Ma={pointer:da,pointerId:Ve(da),pointerType:C,eventType:h.type,eventTarget:Y,curEventTarget:J,scope:t},rl=zr(Ma);xe.push([Ma.pointer,Ma.eventTarget,Ma.curEventTarget,rl])}}else{var el=!1;if(!Z.supportsPointerEvent&&/mouse/.test(h.type)){for(var cl=0;cl<k.length&&!el;cl++)el=k[cl].pointerType!=="mouse"&&k[cl].pointerIsDown;el=el||t.now()-t.prevTouchTime<500||h.timeStamp===0}if(!el){var Dl={pointer:h,pointerId:Ve(h),pointerType:C,eventType:h.type,curEventTarget:J,eventTarget:Y,scope:t},El=zr(Dl);xe.push([Dl.pointer,Dl.eventTarget,Dl.curEventTarget,El])}}for(var Vl=0;Vl<xe.length;Vl++){var ir=xe[Vl],fr=ir[0],ql=ir[1],sr=ir[2];ir[3][s](fr,h,ql,sr)}}}function zr(s){var t=s.pointerType,h=s.scope,k={interaction:Vn.search(s),searchDetails:s};return h.fire("interactions:find",k),k.interaction||h.interactions.new({pointerType:t})}function An(s,t){var h=s.doc,k=s.scope,C=s.options,F=k.interactions.docEvents,Y=k.events,J=Y[t];for(var xe in k.browser.isIOS&&!C.events&&(C.events={passive:!1}),Y.delegatedEvents)J(h,xe,Y.delegateListener),J(h,xe,Y.delegateUseCapture,!0);for(var He=C&&C.events,Se=0;Se<F.length;Se++){var da=F[Se];J(h,da.type,da.listener,He)}}var Tn={id:"core/interactions",install:function(s){for(var t={},h=0;h<nn.length;h++){var k=nn[h];t[k]=Fn(k,s)}var C,F=Z.pEventTypes;function Y(){for(var J=0,xe=s.interactions.list;J<xe.length;J++){var He=xe[J];if(He.pointerIsDown&&He.pointerType==="touch"&&!He._interacting)for(var Se=function(){var rl=Ma[da];s.documents.some(function(el){return ae(el.doc,rl.downTarget)})||He.removePointer(rl.pointer,rl.event)},da=0,Ma=He.pointers;da<Ma.length;da++)Se()}}(C=U.PointerEvent?[{type:F.down,listener:Y},{type:F.down,listener:t.pointerDown},{type:F.move,listener:t.pointerMove},{type:F.up,listener:t.pointerUp},{type:F.cancel,listener:t.pointerUp}]:[{type:"mousedown",listener:t.pointerDown},{type:"mousemove",listener:t.pointerMove},{type:"mouseup",listener:t.pointerUp},{type:"touchstart",listener:Y},{type:"touchstart",listener:t.pointerDown},{type:"touchmove",listener:t.pointerMove},{type:"touchend",listener:t.pointerUp},{type:"touchcancel",listener:t.pointerUp}]).push({type:"blur",listener:function(J){for(var xe=0,He=s.interactions.list;xe<He.length;xe++)He[xe].documentBlur(J)}}),s.prevTouchTime=0,s.Interaction=function(J){m(He,J);var xe=D(He);function He(){return o(this,He),xe.apply(this,arguments)}return c(He,[{key:"pointerMoveTolerance",get:function(){return s.interactions.pointerMoveTolerance},set:function(Se){s.interactions.pointerMoveTolerance=Se}},{key:"_now",value:function(){return s.now()}}]),He}(Sr),s.interactions={list:[],new:function(J){J.scopeFire=function(He,Se){return s.fire(He,Se)};var xe=new s.Interaction(J);return s.interactions.list.push(xe),xe},listeners:t,docEvents:C,pointerMoveTolerance:1},s.usePlugin(Ra)},listeners:{"scope:add-document":function(s){return An(s,"add")},"scope:remove-document":function(s){return An(s,"remove")},"interactable:unset":function(s,t){for(var h=s.interactable,k=t.interactions.list.length-1;k>=0;k--){var C=t.interactions.list[k];C.interactable===h&&(C.stop(),t.fire("interactions:destroy",{interaction:C}),C.destroy(),t.interactions.list.length>2&&t.interactions.list.splice(k,1))}}},onDocSignal:An,doOnInteractions:Fn,methodNames:nn},Po=Tn,Ln=function(s){return s[s.On=0]="On",s[s.Off=1]="Off",s}(Ln||{}),jo=function(){function s(t,h,k,C){o(this,s),this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new gn,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=h.actions,this.target=t,this._context=h.context||k,this._win=_(ra(t)?this._context:t),this._doc=this._win.document,this._scopeEvents=C,this.set(h)}return c(s,[{key:"_defaults",get:function(){return{base:{},perAction:{},actions:{}}}},{key:"setOnEvents",value:function(t,h){return S.func(h.onstart)&&this.on("".concat(t,"start"),h.onstart),S.func(h.onmove)&&this.on("".concat(t,"move"),h.onmove),S.func(h.onend)&&this.on("".concat(t,"end"),h.onend),S.func(h.oninertiastart)&&this.on("".concat(t,"inertiastart"),h.oninertiastart),this}},{key:"updatePerActionListeners",value:function(t,h,k){var C,F=this,Y=(C=this._actions.map[t])==null?void 0:C.filterEventType,J=function(xe){return(Y==null||Y(xe))&&kl(xe,F._actions)};(S.array(h)||S.object(h))&&this._onOff(Ln.Off,t,h,void 0,J),(S.array(k)||S.object(k))&&this._onOff(Ln.On,t,k,void 0,J)}},{key:"setPerAction",value:function(t,h){var k=this._defaults;for(var C in h){var F=C,Y=this.options[t],J=h[F];F==="listeners"&&this.updatePerActionListeners(t,Y.listeners,J),S.array(J)?Y[F]=Qe(J):S.plainObject(J)?(Y[F]=P(Y[F]||{},Ml(J)),S.object(k.perAction[F])&&"enabled"in k.perAction[F]&&(Y[F].enabled=J.enabled!==!1)):S.bool(J)&&S.object(k.perAction[F])?Y[F].enabled=J:Y[F]=J}}},{key:"getRect",value:function(t){return t=t||(S.element(this.target)?this.target:null),S.string(this.target)&&(t=t||this._context.querySelector(this.target)),_e(t)}},{key:"rectChecker",value:function(t){var h=this;return S.func(t)?(this.getRect=function(k){var C=P({},t.apply(h,k));return"width"in C||(C.width=C.right-C.left,C.height=C.bottom-C.top),C},this):t===null?(delete this.getRect,this):this.getRect}},{key:"_backCompatOption",value:function(t,h){if(ra(h)||S.object(h)){for(var k in this.options[t]=h,this._actions.map)this.options[k][t]=h;return this}return this.options[t]}},{key:"origin",value:function(t){return this._backCompatOption("origin",t)}},{key:"deltaSource",value:function(t){return t==="page"||t==="client"?(this.options.deltaSource=t,this):this.options.deltaSource}},{key:"getAllElements",value:function(){var t=this.target;return S.string(t)?Array.from(this._context.querySelectorAll(t)):S.func(t)&&t.getAllElements?t.getAllElements():S.element(t)?[t]:[]}},{key:"context",value:function(){return this._context}},{key:"inContext",value:function(t){return this._context===t.ownerDocument||ae(this._context,t)}},{key:"testIgnoreAllow",value:function(t,h,k){return!this.testIgnore(t.ignoreFrom,h,k)&&this.testAllow(t.allowFrom,h,k)}},{key:"testAllow",value:function(t,h,k){return!t||!!S.element(k)&&(S.string(t)?G(k,t,h):!!S.element(t)&&ae(t,k))}},{key:"testIgnore",value:function(t,h,k){return!(!t||!S.element(k))&&(S.string(t)?G(k,t,h):!!S.element(t)&&ae(t,k))}},{key:"fire",value:function(t){return this.events.fire(t),this}},{key:"_onOff",value:function(t,h,k,C,F){S.object(h)&&!S.array(h)&&(C=k,k=null);var Y=Xe(h,k,F);for(var J in Y){J==="wheel"&&(J=Z.wheelEvent);for(var xe=0,He=Y[J];xe<He.length;xe++){var Se=He[xe];kl(J,this._actions)?this.events[t===Ln.On?"on":"off"](J,Se):S.string(this.target)?this._scopeEvents[t===Ln.On?"addDelegate":"removeDelegate"](this.target,this._context,J,Se,C):this._scopeEvents[t===Ln.On?"add":"remove"](this.target,J,Se,C)}}return this}},{key:"on",value:function(t,h,k){return this._onOff(Ln.On,t,h,k)}},{key:"off",value:function(t,h,k){return this._onOff(Ln.Off,t,h,k)}},{key:"set",value:function(t){var h=this._defaults;for(var k in S.object(t)||(t={}),this.options=Ml(h.base),this._actions.methodDict){var C=k,F=this._actions.methodDict[C];this.options[C]={},this.setPerAction(C,P(P({},h.perAction),h.actions[C])),this[F](t[C])}for(var Y in t)Y!=="getRect"?S.func(this[Y])&&this[Y](t[Y]):this.rectChecker(t.getRect);return this}},{key:"unset",value:function(){if(S.string(this.target))for(var t in this._scopeEvents.delegatedEvents)for(var h=this._scopeEvents.delegatedEvents[t],k=h.length-1;k>=0;k--){var C=h[k],F=C.selector,Y=C.context,J=C.listeners;F===this.target&&Y===this._context&&h.splice(k,1);for(var xe=J.length-1;xe>=0;xe--)this._scopeEvents.removeDelegate(this.target,this._context,t,J[xe][0],J[xe][1])}else this._scopeEvents.remove(this.target,"all")}}]),s}(),Ho=function(){function s(t){var h=this;o(this,s),this.list=[],this.selectorMap={},this.scope=void 0,this.scope=t,t.addListeners({"interactable:unset":function(k){var C=k.interactable,F=C.target,Y=S.string(F)?h.selectorMap[F]:F[h.scope.id],J=Oe(Y,function(xe){return xe===C});Y.splice(J,1)}})}return c(s,[{key:"new",value:function(t,h){h=P(h||{},{actions:this.scope.actions});var k=new this.scope.Interactable(t,h,this.scope.document,this.scope.events);return this.scope.addDocument(k._doc),this.list.push(k),S.string(t)?(this.selectorMap[t]||(this.selectorMap[t]=[]),this.selectorMap[t].push(k)):(k.target[this.scope.id]||Object.defineProperty(t,this.scope.id,{value:[],configurable:!0}),t[this.scope.id].push(k)),this.scope.fire("interactable:new",{target:t,options:h,interactable:k,win:this.scope._win}),k}},{key:"getExisting",value:function(t,h){var k=h&&h.context||this.scope.document,C=S.string(t),F=C?this.selectorMap[t]:t[this.scope.id];if(F)return $e(F,function(Y){return Y._context===k&&(C||Y.inContext(t))})}},{key:"forEachMatch",value:function(t,h){for(var k=0,C=this.list;k<C.length;k++){var F=C[k],Y=void 0;if((S.string(F.target)?S.element(t)&&te(t,F.target):t===F.target)&&F.inContext(t)&&(Y=h(F)),Y!==void 0)return Y}}}]),s}(),Uo=function(){function s(){var t=this;o(this,s),this.id="__interact_scope_".concat(Math.floor(100*Math.random())),this.isInitialized=!1,this.listenerMaps=[],this.browser=Z,this.defaults=Ml(en),this.Eventable=gn,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=function(k){var C=function F(Y,J){var xe=k.interactables.getExisting(Y,J);return xe||((xe=k.interactables.new(Y,J)).events.global=F.globalEvents),xe};return C.getPointerAverage=Ce,C.getTouchBBox=Fa,C.getTouchDistance=Ta,C.getTouchAngle=fa,C.getElementRect=_e,C.getElementClientRect=we,C.matchesSelector=te,C.closest=ve,C.globalEvents={},C.version="1.10.27",C.scope=k,C.use=function(F,Y){return this.scope.usePlugin(F,Y),this},C.isSet=function(F,Y){return!!this.scope.interactables.get(F,Y&&Y.context)},C.on=Bl(function(F,Y,J){if(S.string(F)&&F.search(" ")!==-1&&(F=F.trim().split(/ +/)),S.array(F)){for(var xe=0,He=F;xe<He.length;xe++){var Se=He[xe];this.on(Se,Y,J)}return this}if(S.object(F)){for(var da in F)this.on(da,F[da],Y);return this}return kl(F,this.scope.actions)?this.globalEvents[F]?this.globalEvents[F].push(Y):this.globalEvents[F]=[Y]:this.scope.events.add(this.scope.document,F,Y,{options:J}),this},"The interact.on() method is being deprecated"),C.off=Bl(function(F,Y,J){if(S.string(F)&&F.search(" ")!==-1&&(F=F.trim().split(/ +/)),S.array(F)){for(var xe=0,He=F;xe<He.length;xe++){var Se=He[xe];this.off(Se,Y,J)}return this}if(S.object(F)){for(var da in F)this.off(da,F[da],Y);return this}var Ma;return kl(F,this.scope.actions)?F in this.globalEvents&&(Ma=this.globalEvents[F].indexOf(Y))!==-1&&this.globalEvents[F].splice(Ma,1):this.scope.events.remove(this.scope.document,F,Y,J),this},"The interact.off() method is being deprecated"),C.debug=function(){return this.scope},C.supportsTouch=function(){return Z.supportsTouch},C.supportsPointerEvent=function(){return Z.supportsPointerEvent},C.stop=function(){for(var F=0,Y=this.scope.interactions.list;F<Y.length;F++)Y[F].stop();return this},C.pointerMoveTolerance=function(F){return S.number(F)?(this.scope.interactions.pointerMoveTolerance=F,this):this.scope.interactions.pointerMoveTolerance},C.addDocument=function(F,Y){this.scope.addDocument(F,Y)},C.removeDocument=function(F){this.scope.removeDocument(F)},C}(this),this.InteractEvent=Ar,this.Interactable=void 0,this.interactables=new Ho(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=function(k){return t.removeDocument(k.target)};var h=this;this.Interactable=function(k){m(F,k);var C=D(F);function F(){return o(this,F),C.apply(this,arguments)}return c(F,[{key:"_defaults",get:function(){return h.defaults}},{key:"set",value:function(Y){return w(g(F.prototype),"set",this).call(this,Y),h.fire("interactable:set",{options:Y,interactable:this}),this}},{key:"unset",value:function(){w(g(F.prototype),"unset",this).call(this);var Y=h.interactables.list.indexOf(this);Y<0||(h.interactables.list.splice(Y,1),h.fire("interactable:unset",{interactable:this}))}}]),F}(jo)}return c(s,[{key:"addListeners",value:function(t,h){this.listenerMaps.push({id:h,map:t})}},{key:"fire",value:function(t,h){for(var k=0,C=this.listenerMaps;k<C.length;k++){var F=C[k].map[t];if(F&&F(h,this,t)===!1)return!1}}},{key:"init",value:function(t){return this.isInitialized?this:function(h,k){return h.isInitialized=!0,S.window(k)&&E(k),U.init(k),Z.init(k),Zl.init(k),h.window=k,h.document=k.document,h.usePlugin(Po),h.usePlugin(On),h}(this,t)}},{key:"pluginIsInstalled",value:function(t){var h=t.id;return h?!!this._plugins.map[h]:this._plugins.list.indexOf(t)!==-1}},{key:"usePlugin",value:function(t,h){if(!this.isInitialized)return this;if(this.pluginIsInstalled(t))return this;if(t.id&&(this._plugins.map[t.id]=t),this._plugins.list.push(t),t.install&&t.install(this,h),t.listeners&&t.before){for(var k=0,C=this.listenerMaps.length,F=t.before.reduce(function(J,xe){return J[xe]=!0,J[lo(xe)]=!0,J},{});k<C;k++){var Y=this.listenerMaps[k].id;if(Y&&(F[Y]||F[lo(Y)]))break}this.listenerMaps.splice(k,0,{id:t.id,map:t.listeners})}else t.listeners&&this.listenerMaps.push({id:t.id,map:t.listeners});return this}},{key:"addDocument",value:function(t,h){if(this.getDocIndex(t)!==-1)return!1;var k=_(t);h=h?P({},h):{},this.documents.push({doc:t,options:h}),this.events.documents.push(t),t!==this.document&&this.events.add(k,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:t,window:k,scope:this,options:h})}},{key:"removeDocument",value:function(t){var h=this.getDocIndex(t),k=_(t),C=this.documents[h].options;this.events.remove(k,"unload",this.onWindowUnload),this.documents.splice(h,1),this.events.documents.splice(h,1),this.fire("scope:remove-document",{doc:t,window:k,scope:this,options:C})}},{key:"getDocIndex",value:function(t){for(var h=0;h<this.documents.length;h++)if(this.documents[h].doc===t)return h;return-1}},{key:"getDocOptions",value:function(t){var h=this.getDocIndex(t);return h===-1?null:this.documents[h].options}},{key:"now",value:function(){return(this.window.Date||Date).now()}}]),s}();function lo(s){return s&&s.replace(/\/.*$/,"")}var ro=new Uo,un=ro.interactStatic,qo=typeof globalThis<"u"?globalThis:window;ro.init(qo);var no=Object.freeze({__proto__:null,edgeTarget:function(){},elements:function(){},grid:function(s){var t=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(function(k){var C=k[0],F=k[1];return C in s||F in s}),h=function(k,C){for(var F=s.range,Y=s.limits,J=Y===void 0?{left:-1/0,right:1/0,top:-1/0,bottom:1/0}:Y,xe=s.offset,He=xe===void 0?{x:0,y:0}:xe,Se={range:F,grid:s,x:null,y:null},da=0;da<t.length;da++){var Ma=t[da],rl=Ma[0],el=Ma[1],cl=Math.round((k-He.x)/s[rl]),Dl=Math.round((C-He.y)/s[el]);Se[rl]=Math.max(J.left,Math.min(J.right,cl*s[rl]+He.x)),Se[el]=Math.max(J.top,Math.min(J.bottom,Dl*s[el]+He.y))}return Se};return h.grid=s,h.coordFields=t,h}}),Wo={id:"snappers",install:function(s){var t=s.interactStatic;t.snappers=P(t.snappers||{},no),t.createSnapGrid=t.snappers.grid}},Go=Wo,Ko={start:function(s){var t=s.state,h=s.rect,k=s.edges,C=s.pageCoords,F=t.options,Y=F.ratio,J=F.enabled,xe=t.options,He=xe.equalDelta,Se=xe.modifiers;Y==="preserve"&&(Y=h.width/h.height),t.startCoords=P({},C),t.startRect=P({},h),t.ratio=Y,t.equalDelta=He;var da=t.linkedEdges={top:k.top||k.left&&!k.bottom,left:k.left||k.top&&!k.right,bottom:k.bottom||k.right&&!k.top,right:k.right||k.bottom&&!k.left};if(t.xIsPrimaryAxis=!(!k.left&&!k.right),t.equalDelta){var Ma=(da.left?1:-1)*(da.top?1:-1);t.edgeSign={x:Ma,y:Ma}}else t.edgeSign={x:da.left?-1:1,y:da.top?-1:1};if(J!==!1&&P(k,da),Se!=null&&Se.length){var rl=new Oa(s.interaction);rl.copyFrom(s.interaction.modification),rl.prepareStates(Se),t.subModification=rl,rl.startAll(n({},s))}},set:function(s){var t=s.state,h=s.rect,k=s.coords,C=t.linkedEdges,F=P({},k),Y=t.equalDelta?Yo:Vi;if(P(s.edges,C),Y(t,t.xIsPrimaryAxis,k,h),!t.subModification)return null;var J=P({},h);de(C,J,{x:k.x-F.x,y:k.y-F.y});var xe=t.subModification.setAll(n(n({},s),{},{rect:J,edges:C,pageCoords:k,prevCoords:k,prevRect:J})),He=xe.delta;return xe.changed&&(Y(t,Math.abs(He.x)>Math.abs(He.y),xe.coords,xe.rect),P(k,xe.coords)),xe.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function Yo(s,t,h){var k=s.startCoords,C=s.edgeSign;t?h.y=k.y+(h.x-k.x)*C.y:h.x=k.x+(h.y-k.y)*C.x}function Vi(s,t,h,k){var C=s.startRect,F=s.startCoords,Y=s.ratio,J=s.edgeSign;if(t){var xe=k.width/Y;h.y=F.y+(xe-C.height)*J.y}else{var He=k.height*Y;h.x=F.x+(He-C.width)*J.x}}var Jo=Rl(Ko,"aspectRatio"),ki=function(){};ki._defaults={};var si=ki;function Pn(s,t,h){return S.func(s)?Me(s,t.interactable,t.element,[h.x,h.y,t]):Me(s,t.interactable,t.element)}var xi={start:function(s){var t=s.rect,h=s.startOffset,k=s.state,C=s.interaction,F=s.pageCoords,Y=k.options,J=Y.elementRect,xe=P({left:0,top:0,right:0,bottom:0},Y.offset||{});if(t&&J){var He=Pn(Y.restriction,C,F);if(He){var Se=He.right-He.left-t.width,da=He.bottom-He.top-t.height;Se<0&&(xe.left+=Se,xe.right+=Se),da<0&&(xe.top+=da,xe.bottom+=da)}xe.left+=h.left-t.width*J.left,xe.top+=h.top-t.height*J.top,xe.right+=h.right-t.width*(1-J.right),xe.bottom+=h.bottom-t.height*(1-J.bottom)}k.offset=xe},set:function(s){var t=s.coords,h=s.interaction,k=s.state,C=k.options,F=k.offset,Y=Pn(C.restriction,h,t);if(Y){var J=function(xe){return!xe||"left"in xe&&"top"in xe||((xe=P({},xe)).left=xe.x||0,xe.top=xe.y||0,xe.right=xe.right||xe.left+xe.width,xe.bottom=xe.bottom||xe.top+xe.height),xe}(Y);t.x=Math.max(Math.min(J.right-F.right,t.x),J.left+F.left),t.y=Math.max(Math.min(J.bottom-F.bottom,t.y),J.top+F.top)}},defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}},Xo=Rl(xi,"restrict"),io={top:1/0,left:1/0,bottom:-1/0,right:-1/0},Qn={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function Fi(s,t){for(var h=0,k=["top","left","bottom","right"];h<k.length;h++){var C=k[h];C in s||(s[C]=t[C])}return s}var Wn={noInner:io,noOuter:Qn,start:function(s){var t,h=s.interaction,k=s.startOffset,C=s.state,F=C.options;F&&(t=Le(Pn(F.offset,h,h.coords.start.page))),t=t||{x:0,y:0},C.offset={top:t.y+k.top,left:t.x+k.left,bottom:t.y-k.bottom,right:t.x-k.right}},set:function(s){var t=s.coords,h=s.edges,k=s.interaction,C=s.state,F=C.offset,Y=C.options;if(h){var J=P({},t),xe=Pn(Y.inner,k,J)||{},He=Pn(Y.outer,k,J)||{};Fi(xe,io),Fi(He,Qn),h.top?t.y=Math.min(Math.max(He.top+F.top,J.y),xe.top+F.top):h.bottom&&(t.y=Math.max(Math.min(He.bottom+F.bottom,J.y),xe.bottom+F.bottom)),h.left?t.x=Math.min(Math.max(He.left+F.left,J.x),xe.left+F.left):h.right&&(t.x=Math.max(Math.min(He.right+F.right,J.x),xe.right+F.right))}},defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}},Zo=Rl(Wn,"restrictEdges"),Qo=P({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(s){}},xi.defaults),et=Rl({start:xi.start,set:xi.set,defaults:Qo},"restrictRect"),at={width:-1/0,height:-1/0},oo={width:1/0,height:1/0},ci=Rl({start:function(s){return Wn.start(s)},set:function(s){var t=s.interaction,h=s.state,k=s.rect,C=s.edges,F=h.options;if(C){var Y=Ie(Pn(F.min,t,s.coords))||at,J=Ie(Pn(F.max,t,s.coords))||oo;h.options={endOnly:F.endOnly,inner:P({},Wn.noInner),outer:P({},Wn.noOuter)},C.top?(h.options.inner.top=k.bottom-Y.height,h.options.outer.top=k.bottom-J.height):C.bottom&&(h.options.inner.bottom=k.top+Y.height,h.options.outer.bottom=k.top+J.height),C.left?(h.options.inner.left=k.right-Y.width,h.options.outer.left=k.right-J.width):C.right&&(h.options.inner.right=k.left+Y.width,h.options.outer.right=k.left+J.width),Wn.set(s),h.options=F}},defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize"),wi={start:function(s){var t,h=s.interaction,k=s.interactable,C=s.element,F=s.rect,Y=s.state,J=s.startOffset,xe=Y.options,He=xe.offsetWithOrigin?function(Ma){var rl=Ma.interaction.element,el=Le(Me(Ma.state.options.origin,null,null,[rl])),cl=el||De(Ma.interactable,rl,Ma.interaction.prepared.name);return cl}(s):{x:0,y:0};if(xe.offset==="startCoords")t={x:h.coords.start.page.x,y:h.coords.start.page.y};else{var Se=Me(xe.offset,k,C,[h]);(t=Le(Se)||{x:0,y:0}).x+=He.x,t.y+=He.y}var da=xe.relativePoints;Y.offsets=F&&da&&da.length?da.map(function(Ma,rl){return{index:rl,relativePoint:Ma,x:J.left-F.width*Ma.x+t.x,y:J.top-F.height*Ma.y+t.y}}):[{index:0,relativePoint:null,x:t.x,y:t.y}]},set:function(s){var t=s.interaction,h=s.coords,k=s.state,C=k.options,F=k.offsets,Y=De(t.interactable,t.element,t.prepared.name),J=P({},h),xe=[];C.offsetWithOrigin||(J.x-=Y.x,J.y-=Y.y);for(var He=0,Se=F;He<Se.length;He++)for(var da=Se[He],Ma=J.x-da.x,rl=J.y-da.y,el=0,cl=C.targets.length;el<cl;el++){var Dl=C.targets[el],El=void 0;(El=S.func(Dl)?Dl(Ma,rl,t._proxy,da,el):Dl)&&xe.push({x:(S.number(El.x)?El.x:Ma)+da.x,y:(S.number(El.y)?El.y:rl)+da.y,range:S.number(El.range)?El.range:C.range,source:Dl,index:el,offset:da})}for(var Vl={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}},ir=0;ir<xe.length;ir++){var fr=xe[ir],ql=fr.range,sr=fr.x-J.x,dn=fr.y-J.y,ar=Ge(sr,dn),bn=ar<=ql;ql===1/0&&Vl.inRange&&Vl.range!==1/0&&(bn=!1),Vl.target&&!(bn?Vl.inRange&&ql!==1/0?ar/ql<Vl.distance/Vl.range:ql===1/0&&Vl.range!==1/0||ar<Vl.distance:!Vl.inRange&&ar<Vl.distance)||(Vl.target=fr,Vl.distance=ar,Vl.range=ql,Vl.inRange=bn,Vl.delta.x=sr,Vl.delta.y=dn)}return Vl.inRange&&(h.x=Vl.target.x,h.y=Vl.target.y),k.closest=Vl,Vl},defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}},to=Rl(wi,"snap"),jn={start:function(s){var t=s.state,h=s.edges,k=t.options;if(!h)return null;s.state={options:{targets:null,relativePoints:[{x:h.left?0:1,y:h.top?0:1}],offset:k.offset||"self",origin:{x:0,y:0},range:k.range}},t.targetFields=t.targetFields||[["width","height"],["x","y"]],wi.start(s),t.offsets=s.state.offsets,s.state=t},set:function(s){var t=s.interaction,h=s.state,k=s.coords,C=h.options,F=h.offsets,Y={x:k.x-F[0].x,y:k.y-F[0].y};h.options=P({},C),h.options.targets=[];for(var J=0,xe=C.targets||[];J<xe.length;J++){var He=xe[J],Se=void 0;if(Se=S.func(He)?He(Y.x,Y.y,t):He){for(var da=0,Ma=h.targetFields;da<Ma.length;da++){var rl=Ma[da],el=rl[0],cl=rl[1];if(el in Se||cl in Se){Se.x=Se[el],Se.y=Se[cl];break}}h.options.targets.push(Se)}}var Dl=wi.set(s);return h.options=C,Dl},defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}},lt=Rl(jn,"snapSize"),_i={aspectRatio:Jo,restrictEdges:Zo,restrict:Xo,restrictRect:et,restrictSize:ci,snapEdges:Rl({start:function(s){var t=s.edges;return t?(s.state.targetFields=s.state.targetFields||[[t.left?"left":"right",t.top?"top":"bottom"]],jn.start(s)):null},set:jn.set,defaults:P(Ml(jn.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})},"snapEdges"),snap:to,snapSize:lt,spring:si,avoid:si,transform:si,rubberband:si},ui={id:"modifiers",install:function(s){var t=s.interactStatic;for(var h in s.usePlugin(vn),s.usePlugin(Go),t.modifiers=_i,_i){var k=_i[h],C=k._defaults,F=k._methods;C._methods=F,s.defaults.perAction[h]=C}}},rt=ui,so=function(s){m(h,s);var t=D(h);function h(k,C,F,Y,J,xe){var He;if(o(this,h),V(d(He=t.call(this,J)),F),F!==C&&V(d(He),C),He.timeStamp=xe,He.originalEvent=F,He.type=k,He.pointerId=Ve(C),He.pointerType=ja(C),He.target=Y,He.currentTarget=null,k==="tap"){var Se=J.getPointerIndex(C);He.dt=He.timeStamp-J.pointers[Se].downTime;var da=He.timeStamp-J.tapTime;He.double=!!J.prevTap&&J.prevTap.type!=="doubletap"&&J.prevTap.target===He.target&&da<500}else k==="doubletap"&&(He.dt=C.timeStamp-J.tapTime,He.double=!0);return He}return c(h,[{key:"_subtractOrigin",value:function(k){var C=k.x,F=k.y;return this.pageX-=C,this.pageY-=F,this.clientX-=C,this.clientY-=F,this}},{key:"_addOrigin",value:function(k){var C=k.x,F=k.y;return this.pageX+=C,this.pageY+=F,this.clientX+=C,this.clientY+=F,this}},{key:"preventDefault",value:function(){this.originalEvent.preventDefault()}}]),h}(Pe),di={id:"pointer-events/base",before:["inertia","modifiers","auto-start","actions"],install:function(s){s.pointerEvents=di,s.defaults.actions.pointerEvents=di.defaults,P(s.actions.phaselessTypes,di.types)},listeners:{"interactions:new":function(s){var t=s.interaction;t.prevTap=null,t.tapTime=0},"interactions:update-pointer":function(s){var t=s.down,h=s.pointerInfo;!t&&h.hold||(h.hold={duration:1/0,timeout:null})},"interactions:move":function(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget;s.duplicate||h.pointerIsDown&&!h.pointerWasMoved||(h.pointerIsDown&&Pi(s),Hn({interaction:h,pointer:k,event:C,eventTarget:F,type:"move"},t))},"interactions:down":function(s,t){(function(h,k){for(var C=h.interaction,F=h.pointer,Y=h.event,J=h.eventTarget,xe=h.pointerIndex,He=C.pointers[xe].hold,Se=qe(J),da={interaction:C,pointer:F,event:Y,eventTarget:J,type:"hold",targets:[],path:Se,node:null},Ma=0;Ma<Se.length;Ma++){var rl=Se[Ma];da.node=rl,k.fire("pointerEvents:collect-targets",da)}if(da.targets.length){for(var el=1/0,cl=0,Dl=da.targets;cl<Dl.length;cl++){var El=Dl[cl].eventable.options.holdDuration;El<el&&(el=El)}He.duration=el,He.timeout=setTimeout(function(){Hn({interaction:C,eventTarget:J,pointer:F,event:Y,type:"hold"},k)},el)}})(s,t),Hn(s,t)},"interactions:up":function(s,t){Pi(s),Hn(s,t),function(h,k){var C=h.interaction,F=h.pointer,Y=h.event,J=h.eventTarget;C.pointerWasMoved||Hn({interaction:C,eventTarget:J,pointer:F,event:Y,type:"tap"},k)}(s,t)},"interactions:cancel":function(s,t){Pi(s),Hn(s,t)}},PointerEvent:so,fire:Hn,collectEventTargets:co,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 Hn(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget,Y=s.type,J=s.targets,xe=J===void 0?co(s,t):J,He=new so(Y,k,C,F,h,t.now());t.fire("pointerEvents:new",{pointerEvent:He});for(var Se={interaction:h,pointer:k,event:C,eventTarget:F,targets:xe,type:Y,pointerEvent:He},da=0;da<xe.length;da++){var Ma=xe[da];for(var rl in Ma.props||{})He[rl]=Ma.props[rl];var el=De(Ma.eventable,Ma.node);if(He._subtractOrigin(el),He.eventable=Ma.eventable,He.currentTarget=Ma.node,Ma.eventable.fire(He),He._addOrigin(el),He.immediatePropagationStopped||He.propagationStopped&&da+1<xe.length&&xe[da+1].node!==He.currentTarget)break}if(t.fire("pointerEvents:fired",Se),Y==="tap"){var cl=He.double?Hn({interaction:h,pointer:k,event:C,eventTarget:F,type:"doubletap"},t):He;h.prevTap=cl,h.tapTime=cl.timeStamp}return He}function co(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget,Y=s.type,J=h.getPointerIndex(k),xe=h.pointers[J];if(Y==="tap"&&(h.pointerWasMoved||!xe||xe.downTarget!==F))return[];for(var He=qe(F),Se={interaction:h,pointer:k,event:C,eventTarget:F,type:Y,path:He,targets:[],node:null},da=0;da<He.length;da++){var Ma=He[da];Se.node=Ma,t.fire("pointerEvents:collect-targets",Se)}return Y==="hold"&&(Se.targets=Se.targets.filter(function(rl){var el,cl;return rl.eventable.options.holdDuration===((el=h.pointers[J])==null||(cl=el.hold)==null?void 0:cl.duration)})),Se.targets}function Pi(s){var t=s.interaction,h=s.pointerIndex,k=t.pointers[h].hold;k&&k.timeout&&(clearTimeout(k.timeout),k.timeout=null)}var nt=Object.freeze({__proto__:null,default:di});function it(s){var t=s.interaction;t.holdIntervalHandle&&(clearInterval(t.holdIntervalHandle),t.holdIntervalHandle=null)}var uo={id:"pointer-events/holdRepeat",install:function(s){s.usePlugin(di);var t=s.pointerEvents;t.defaults.holdRepeatInterval=0,t.types.holdrepeat=s.actions.phaselessTypes.holdrepeat=!0},listeners:["move","up","cancel","endall"].reduce(function(s,t){return s["pointerEvents:".concat(t)]=it,s},{"pointerEvents:new":function(s){var t=s.pointerEvent;t.type==="hold"&&(t.count=(t.count||0)+1)},"pointerEvents:fired":function(s,t){var h=s.interaction,k=s.pointerEvent,C=s.eventTarget,F=s.targets;if(k.type==="hold"&&F.length){var Y=F[0].eventable.options.holdRepeatInterval;Y<=0||(h.holdIntervalHandle=setTimeout(function(){t.pointerEvents.fire({interaction:h,eventTarget:C,type:"hold",pointer:k,event:k},t)},Y))}}})},ot=uo,tt={id:"pointer-events/interactableTargets",install:function(s){var t=s.Interactable;t.prototype.pointerEvents=function(k){return P(this.events.options,k),this};var h=t.prototype._backCompatOption;t.prototype._backCompatOption=function(k,C){var F=h.call(this,k,C);return F===this&&(this.events.options[k]=C),F}},listeners:{"pointerEvents:collect-targets":function(s,t){var h=s.targets,k=s.node,C=s.type,F=s.eventTarget;t.interactables.forEachMatch(k,function(Y){var J=Y.events,xe=J.options;J.types[C]&&J.types[C].length&&Y.testIgnoreAllow(xe,k,F)&&h.push({node:k,eventable:J,props:{interactable:Y}})})},"interactable:new":function(s){var t=s.interactable;t.events.getRect=function(h){return t.getRect(h)}},"interactable:set":function(s,t){var h=s.interactable,k=s.options;P(h.events.options,t.pointerEvents.defaults),P(h.events.options,k.pointerEvents||{})}}},st=tt,ct={id:"pointer-events",install:function(s){s.usePlugin(nt),s.usePlugin(ot),s.usePlugin(st)}},Si=ct,ut={id:"reflow",install:function(s){var t=s.Interactable;s.actions.phases.reflow=!0,t.prototype.reflow=function(h){return function(k,C,F){for(var Y=k.getAllElements(),J=F.window.Promise,xe=J?[]:null,He=function(){var da=Y[Se],Ma=k.getRect(da);if(!Ma)return 1;var rl,el=$e(F.interactions.list,function(El){return El.interacting()&&El.interactable===k&&El.element===da&&El.prepared.name===C.name});if(el)el.move(),xe&&(rl=el._reflowPromise||new J(function(El){el._reflowResolve=El}));else{var cl=Ie(Ma),Dl=function(El){return{coords:El,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:cl.x,y:cl.y},client:{x:cl.x,y:cl.y},timeStamp:F.now()});rl=function(El,Vl,ir,fr,ql){var sr=El.interactions.new({pointerType:"reflow"}),dn={interaction:sr,event:ql,pointer:ql,eventTarget:ir,phase:"reflow"};sr.interactable=Vl,sr.element=ir,sr.prevEvent=ql,sr.updatePointer(ql,ql,ir,!0),ce(sr.coords.delta),Ha(sr.prepared,fr),sr._doPhase(dn);var ar=El.window,bn=ar.Promise,Xr=bn?new bn(function(Rn){sr._reflowResolve=Rn}):void 0;return sr._reflowPromise=Xr,sr.start(fr,Vl,ir),sr._interacting?(sr.move(dn),sr.end(ql)):(sr.stop(),sr._reflowResolve()),sr.removePointer(ql,ql),Xr}(F,k,da,C,Dl)}xe&&xe.push(rl)},Se=0;Se<Y.length&&!He();Se++);return xe&&J.all(xe).then(function(){return k})}(this,h,s)}},listeners:{"interactions:stop":function(s,t){var h=s.interaction;h.pointerType==="reflow"&&(h._reflowResolve&&h._reflowResolve(),function(k,C){k.splice(k.indexOf(C),1)}(t.interactions.list,h))}}},dt=ut;if(un.use(Ra),un.use(Ql),un.use(Si),un.use(Br),un.use(rt),un.use(bl),un.use(Gl),un.use(fl),un.use(dt),un.default=un,i(a)==="object"&&a)try{a.exports=un}catch{}return un.default=un,un})}(Ki,Ki.exports)),Ki.exports}var o1=i1();const Gs=M.getDefaultExportFromCjs(o1),Ro=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:r}){const n=a,i=r,o=e.inject(tu),p=e.inject(su);if(!o)throw new Error("[grid-layout-plus]: missing layout store, GridItem must under a GridLayout.");const c=e.shallowRef(null),u=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,y=NaN,d=NaN,D=NaN,w=NaN,q=-1,A=-1,j=-1,O=-1,E=n.x,_=n.y,x=n.w,b=n.h;const S=e.ref(),I=e.reactive({i:e.toRef(n,"i"),state:u,wrapper:S,calcXY:Me});function R(he){Xe(he)}function re(){Ea()}function X(he){Bn(n.isDraggable)&&(u.draggable=he)}function me(he){Bn(n.isResizable)&&(u.resizable=he)}function ue(he){Bn(n.isBounded)&&(u.bounded=he)}function U(he){u.transformScale=he}function W(he){u.rowHeight=he}function Z(he){u.maxRows=he}function ae(){u.rtl=qs()==="rtl",Ea()}function ve(he){u.cols=Math.floor(he)}o.increaseItem(I),e.onBeforeMount(()=>{u.rtl=qs()==="rtl"}),e.onMounted(()=>{o.responsive&&o.lastBreakpoint?u.cols=fu(o.lastBreakpoint,o.cols):u.cols=o.colNum,u.rowHeight=o.rowHeight,u.containerWidth=o.width!==null?o.width:100,u.margin=o.margin!==void 0?o.margin.map(Number):[10,10],u.maxRows=o.maxRows,Bn(n.isDraggable)?u.draggable=o.isDraggable:u.draggable=n.isDraggable,Bn(n.isResizable)?u.resizable=o.isResizable:u.resizable=n.isResizable,Bn(n.isBounded)?u.bounded=o.isBounded:u.bounded=n.isBounded,u.transformScale=o.transformScale,u.useCssTransforms=o.useCssTransforms,u.useStyleCursor=o.useStyleCursor,e.watchEffect(()=>{E=n.x,_=n.y,b=n.h,x=n.w,kn(_e)}),p.on("updateWidth",R),p.on("compact",re),p.on("setDraggable",X),p.on("setResizable",me),p.on("setBounded",ue),p.on("setTransformScale",U),p.on("setRowHeight",W),p.on("setMaxRows",Z),p.on("directionchange",ae),p.on("setColNum",ve)}),e.onBeforeUnmount(()=>{p.off("updateWidth",R),p.off("compact",re),p.off("setDraggable",X),p.off("setResizable",me),p.off("setBounded",ue),p.off("setTransformScale",U),p.off("setRowHeight",W),p.off("setMaxRows",Z),p.off("directionchange",ae),p.off("setColNum",ve),c.value&&(c.value.unset(),c.value=null),o.decreaseItem(I)}),l({state:u,wrapper:S});const ze=typeof navigator<"u"?navigator.userAgent.toLowerCase().includes("android"):!1,te=e.computed(()=>u.resizable&&!n.static),N=e.computed(()=>o.isMirrored?!u.rtl:u.rtl),se=e.computed(()=>(u.draggable||u.resizable)&&!n.static),G=Xv("item"),fe=e.computed(()=>({[G.b()]:!0,[G.bm("resizable")]:te.value,[G.bm("static")]:n.static,[G.bm("resizing")]:u.isResizing,[G.bm("dragging")]:u.isDragging,[G.bm("transform")]:u.useCssTransforms,[G.bm("rtl")]:N.value,[G.bm("no-touch")]:ze&&se.value})),we=e.computed(()=>[G.be("resizer"),N.value&&G.bem("resizer","rtl")].filter(Boolean));e.watch(()=>n.isDraggable,he=>{u.draggable=he}),e.watch(()=>n.static,()=>{kn(V),kn(ce)}),e.watch(()=>u.draggable,()=>{kn(V)}),e.watch(()=>n.isResizable,he=>{u.resizable=he}),e.watch(()=>n.isBounded,he=>{u.bounded=he}),e.watch(()=>u.resizable,()=>{kn(ce)}),e.watch(()=>u.rowHeight,()=>{kn(_e),kn(qe)}),e.watch([()=>u.cols,()=>u.containerWidth],()=>{kn(ce),kn(_e),kn(qe)}),e.watch([()=>n.minH,()=>n.maxH,()=>n.minW,()=>n.maxW],()=>{kn(ce)}),e.watch(N,()=>{kn(ce),kn(_e)}),e.watch([()=>o.margin,()=>o.margin[0],()=>o.margin[1]],()=>{const he=o.margin;!he||he[0]===u.margin[0]&&he[1]===u.margin[1]||(u.margin=he.map(Number),kn(_e),kn(qe))});function _e(){n.x+n.w>u.cols?(E=0,x=n.w>u.cols?u.cols:n.w):(E=n.x,x=n.w);const he=Ke(E,_,x,b);u.isDragging&&(he.top=u.dragging.top,N.value?he.right=u.dragging.left:he.left=u.dragging.left),u.isResizing&&(he.width=u.resizing.width,he.height=u.resizing.height);let pa;u.useCssTransforms?N.value?pa=Gv(he.top,he.right,he.width,he.height):pa=Wv(he.top,he.left,he.width,he.height):N.value?pa=Yv(he.top,he.right,he.width,he.height):pa=Kv(he.top,he.left,he.width,he.height),u.style=pa}function qe(){const he={};for(const pa of["width","height"]){const ia=u.style[pa].match(/^(\d+)px$/);if(!ia)return;he[pa]=ia[1]}i("container-resized",n.i,n.h,n.w,he.height,he.width)}function ra(he){if(n.static)return;const pa=he.type;if(pa==="resizestart"&&u.isResizing||pa!=="resizestart"&&!u.isResizing)return;const ia=Hs(he);if(Bn(ia))return;const{x:Ve,y:ya}=ia,Ca={width:0,height:0};let Ce;switch(pa){case"resizestart":{ce(),q=x,A=b,Ce=Ke(E,_,x,b),Ca.width=Ce.width,Ca.height=Ce.height,u.resizing=Ca,u.isResizing=!0;break}case"resizemove":{!he.edges.right&&!he.edges.left&&(D=Ve),!he.edges.top&&!he.edges.bottom&&(w=ya);const Fa=Us(D,w,Ve,ya);N.value?Ca.width=u.resizing.width-Fa.deltaX/u.transformScale:Ca.width=u.resizing.width+Fa.deltaX/u.transformScale,Ca.height=u.resizing.height+Fa.deltaY/u.transformScale,u.resizing=Ca;break}case"resizeend":{Ce=Ke(E,_,x,b),Ca.width=Ce.width,Ca.height=Ce.height,u.resizing={width:-1,height:-1},u.isResizing=!1;break}}Ce=De(Ca.height,Ca.width),Ce.w<n.minW&&(Ce.w=n.minW),Ce.w>n.maxW&&(Ce.w=n.maxW),Ce.h<n.minH&&(Ce.h=n.minH),Ce.h>n.maxH&&(Ce.h=n.maxH),Ce.h<1&&(Ce.h=1),Ce.w<1&&(Ce.w=1),D=Ve,w=ya,(x!==Ce.w||b!==Ce.h)&&i("resize",n.i,Ce.h,Ce.w,Ca.height,Ca.width),he.type==="resizeend"&&(q!==x||A!==b)&&i("resized",n.i,Ce.h,Ce.w,Ca.height,Ca.width),p.emit("resizeEvent",he.type,n.i,E,_,Ce.h,Ce.w)}function P(he){if(n.static||u.isResizing)return;const pa=he.type;if(pa==="dragstart"&&u.isDragging||pa!=="dragstart"&&!u.isDragging)return;const ia=Hs(he);if(Bn(ia))return;const{x:Ve,y:ya}=ia,Ca=he.target;if(!Ca.offsetParent)return;const Ce={top:0,left:0};switch(pa){case"dragstart":{j=E,O=_;const Ta=Ca.offsetParent.getBoundingClientRect(),fa=Ca.getBoundingClientRect(),ja=fa.left/u.transformScale,sa=Ta.left/u.transformScale,Pe=fa.right/u.transformScale,ma=Ta.right/u.transformScale,Qe=fa.top/u.transformScale,Oe=Ta.top/u.transformScale;N.value?Ce.left=(Pe-ma)*-1:Ce.left=ja-sa,Ce.top=Qe-Oe,u.dragging=Ce,u.isDragging=!0;break}case"dragmove":{const Ta=Us(y,d,Ve,ya);if(N.value?Ce.left=u.dragging.left-Ta.deltaX/u.transformScale:Ce.left=u.dragging.left+Ta.deltaX/u.transformScale,Ce.top=u.dragging.top+Ta.deltaY/u.transformScale,u.bounded){const fa=Ca.offsetParent.clientHeight-Ie(n.h,u.rowHeight,u.margin[1]);Ce.top=de(Ce.top,0,fa);const ja=Le(),sa=u.containerWidth-Ie(n.w,ja,u.margin[0]);Ce.left=de(Ce.left,0,sa)}u.dragging=Ce;break}case"dragend":{const Ta=Ca.offsetParent.getBoundingClientRect(),fa=Ca.getBoundingClientRect(),ja=fa.left/u.transformScale,sa=Ta.left/u.transformScale,Pe=fa.right/u.transformScale,ma=Ta.right/u.transformScale,Qe=fa.top/u.transformScale,Oe=Ta.top/u.transformScale;N.value?Ce.left=(Pe-ma)*-1:Ce.left=ja-sa,Ce.top=Qe-Oe,u.dragging={top:-1,left:-1},u.isDragging=!1;break}}let Fa;N.value,Fa=Me(Ce.top,Ce.left),y=Ve,d=ya,(E!==Fa.x||_!==Fa.y)&&i("move",n.i,Fa.x,Fa.y),he.type==="dragend"&&(j!==E||O!==_)&&i("moved",n.i,Fa.x,Fa.y),p.emit("dragEvent",he.type,n.i,Fa.x,Fa.y,b,x)}function Ke(he,pa,ia,Ve){const ya=Le();let Ca;return N.value?Ca={right:Math.round(ya*he+(he+1)*u.margin[0]),top:Math.round(u.rowHeight*pa+(pa+1)*u.margin[1]),width:ia===1/0?ia:Math.round(ya*ia+Math.max(0,ia-1)*u.margin[0]),height:Ve===1/0?Ve:Math.round(u.rowHeight*Ve+Math.max(0,Ve-1)*u.margin[1])}:Ca={left:Math.round(ya*he+(he+1)*u.margin[0]),top:Math.round(u.rowHeight*pa+(pa+1)*u.margin[1]),width:ia===1/0?ia:Math.round(ya*ia+Math.max(0,ia-1)*u.margin[0]),height:Ve===1/0?Ve:Math.round(u.rowHeight*Ve+Math.max(0,Ve-1)*u.margin[1])},Ca}function Me(he,pa){const ia=Le();let Ve=Math.round((pa-u.margin[0])/(ia+u.margin[0])),ya=Math.round((he-u.margin[1])/(u.rowHeight+u.margin[1]));return Ve=Math.max(Math.min(Ve,u.cols-x),0),ya=Math.max(Math.min(ya,u.maxRows-b),0),{x:Ve,y:ya}}function Le(){return(u.containerWidth-u.margin[0]*(u.cols+1))/u.cols}function Ie(he,pa,ia){return Number.isFinite(he)?Math.round(pa*he+Math.max(0,he-1)*ia):he}function de(he,pa,ia){return Math.max(Math.min(he,ia),pa)}function De(he,pa,ia=!1){const Ve=Le();let ya=Math.round((pa+u.margin[0])/(Ve+u.margin[0])),Ca=0;return ia?Ca=Math.ceil((he+u.margin[1])/(u.rowHeight+u.margin[1])):Ca=Math.round((he+u.margin[1])/(u.rowHeight+u.margin[1])),ya=Math.max(Math.min(ya,u.cols-E),0),Ca=Math.max(Math.min(Ca,u.maxRows-_),0),{w:ya,h:Ca}}function Xe(he,pa){u.containerWidth=he}function Ea(){_e()}function Ge(){!c.value&&S.value&&(c.value=Gs(S.value),u.useStyleCursor||c.value.styleCursor(!1))}const $=Fs(P);function V(){if(Ge(),!!c.value)if(u.draggable&&!n.static){const he={ignoreFrom:n.dragIgnoreFrom,allowFrom:n.dragAllowFrom,...n.dragOption};c.value.draggable(he),m||(m=!0,c.value.on("dragstart dragmove dragend",pa=>{pa.type==="dragmove"?$(pa):P(pa)}))}else c.value.draggable({enabled:!1})}const ee=Fs(ra);function ce(){if(Ge(),!!c.value)if(u.resizable&&!n.static){const he=Ke(0,0,n.maxW,n.maxH),pa=Ke(0,0,n.minW,n.minH),ia={edges:{left:N.value?`.${we.value[0]}`:!1,right:N.value?!1:`.${we.value[0]}`,bottom:`.${we.value[0]}`,top:!1},ignoreFrom:n.resizeIgnoreFrom,restrictSize:{min:{height:pa.height*u.transformScale,width:pa.width*u.transformScale},max:{height:he.height*u.transformScale,width:he.width*u.transformScale}},...n.resizeOption};n.preserveAspectRatio&&(ia.modifiers=[Gs.modifiers.aspectRatio({ratio:"preserve"})]),c.value.resizable(ia),g||(g=!0,c.value.on("resizestart resizemove resizeend",Ve=>{Ve.type==="resizemove"?ee(Ve):ra(Ve)}))}else c.value.resizable({enabled:!1})}return(he,pa)=>(e.openBlock(),e.createElementBlock("section",{ref_key:"wrapper",ref:S,class:e.normalizeClass(fe.value),style:e.normalizeStyle(u.style)},[e.renderSlot(he.$slots,"default"),te.value?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(we.value)},null,2)):e.createCommentVNode("",!0)],6))}}),bi=typeof window<"u";var Ks;bi&&(Ks=window==null?void 0:window.navigator)!=null&&Ks.userAgent&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Ys(a){return a!=null}function Js(){}const s1=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(s1)));const c1=bi&&("ontouchstart"in window||d1()>0),u1=c1?"pointerdown":"click";function d1(){return typeof navigator<"u"&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)||0}function p1(a,l,r=window.Event){const{type:n,bubbles:i=!1,cancelable:o=!1,...p}=l;if(!Ys(n)||n==="")return!1;let c;return Ys(r)?c=new r(n,{bubbles:i,cancelable:o}):(c=document.createEvent("HTMLEvents"),c.initEvent(n,i,o)),Object.assign(c,p),a.dispatchEvent(c)}const f1="clickoutside",h1=new Set;bi&&document.addEventListener(u1,a=>{const l=a.target,r=a.composedPath&&a.composedPath();h1.forEach(n=>{n!==l&&(r?!r.includes(n):!n.contains(l))&&(!n.__transferElement||n.__transferElement!==l&&!n.__transferElement.contains(l))&&p1(n,{type:f1})})},!0);const v1=[["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 Eo;if(bi){for(const a of v1)if(a[1]in document){Eo=a;break}}e.computed(()=>!1);const m1=new Set,y1=new WeakMap;if(bi&&Eo){const a=Eo[2],l=Eo[4];document.addEventListener(l,()=>{if(m1.forEach(r=>{r.value=!1}),document[a]){const r=y1.get(document[a]);r&&(r.value=!0)}},!1)}const vu=new Map;vu.set("x",0);vu.set("y",0);var yi=[],g1=function(){return yi.some(function(a){return a.activeTargets.length>0})},b1=function(){return yi.some(function(a){return a.skippedTargets.length>0})},Xs="ResizeObserver loop completed with undelivered notifications.",k1=function(){var a;typeof ErrorEvent=="function"?a=new ErrorEvent("error",{message:Xs}):(a=document.createEvent("Event"),a.initEvent("error",!1,!1),a.message=Xs),window.dispatchEvent(a)},ao;(function(a){a.BORDER_BOX="border-box",a.CONTENT_BOX="content-box",a.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(ao||(ao={}));var gi=function(a){return Object.freeze(a)},x1=function(){function a(l,r){this.inlineSize=l,this.blockSize=r,gi(this)}return a}(),mu=function(){function a(l,r,n,i){return this.x=l,this.y=r,this.width=n,this.height=i,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,gi(this)}return a.prototype.toJSON=function(){var l=this,r=l.x,n=l.y,i=l.top,o=l.right,p=l.bottom,c=l.left,u=l.width,m=l.height;return{x:r,y:n,top:i,right:o,bottom:p,left:c,width:u,height:m}},a.fromRect=function(l){return new a(l.x,l.y,l.width,l.height)},a}(),jt=function(a){return a instanceof SVGElement&&"getBBox"in a},yu=function(a){if(jt(a)){var l=a.getBBox(),r=l.width,n=l.height;return!r&&!n}var i=a,o=i.offsetWidth,p=i.offsetHeight;return!(o||p||a.getClientRects().length)},Zs=function(a){var l;if(a instanceof Element)return!0;var r=(l=a==null?void 0:a.ownerDocument)===null||l===void 0?void 0:l.defaultView;return!!(r&&a instanceof r.Element)},w1=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},Zi=typeof window<"u"?window:{},xo=new WeakMap,Qs=/auto|scroll/,_1=/^tb|vertical/,S1=/msie|trident/i.test(Zi.navigator&&Zi.navigator.userAgent),qn=function(a){return parseFloat(a||"0")},Oi=function(a,l,r){return a===void 0&&(a=0),l===void 0&&(l=0),r===void 0&&(r=!1),new x1((r?l:a)||0,(r?a:l)||0)},ec=gi({devicePixelContentBoxSize:Oi(),borderBoxSize:Oi(),contentBoxSize:Oi(),contentRect:new mu(0,0,0,0)}),gu=function(a,l){if(l===void 0&&(l=!1),xo.has(a)&&!l)return xo.get(a);if(yu(a))return xo.set(a,ec),ec;var r=getComputedStyle(a),n=jt(a)&&a.ownerSVGElement&&a.getBBox(),i=!S1&&r.boxSizing==="border-box",o=_1.test(r.writingMode||""),p=!n&&Qs.test(r.overflowY||""),c=!n&&Qs.test(r.overflowX||""),u=n?0:qn(r.paddingTop),m=n?0:qn(r.paddingRight),g=n?0:qn(r.paddingBottom),y=n?0:qn(r.paddingLeft),d=n?0:qn(r.borderTopWidth),D=n?0:qn(r.borderRightWidth),w=n?0:qn(r.borderBottomWidth),q=n?0:qn(r.borderLeftWidth),A=y+m,j=u+g,O=q+D,E=d+w,_=c?a.offsetHeight-E-a.clientHeight:0,x=p?a.offsetWidth-O-a.clientWidth:0,b=i?A+O:0,S=i?j+E:0,I=n?n.width:qn(r.width)-b-x,R=n?n.height:qn(r.height)-S-_,re=I+A+x+O,X=R+j+_+E,me=gi({devicePixelContentBoxSize:Oi(Math.round(I*devicePixelRatio),Math.round(R*devicePixelRatio),o),borderBoxSize:Oi(re,X,o),contentBoxSize:Oi(I,R,o),contentRect:new mu(y,u,I,R)});return xo.set(a,me),me},bu=function(a,l,r){var n=gu(a,r),i=n.borderBoxSize,o=n.contentBoxSize,p=n.devicePixelContentBoxSize;switch(l){case ao.DEVICE_PIXEL_CONTENT_BOX:return p;case ao.BORDER_BOX:return i;default:return o}},E1=function(){function a(l){var r=gu(l);this.target=l,this.contentRect=r.contentRect,this.borderBoxSize=gi([r.borderBoxSize]),this.contentBoxSize=gi([r.contentBoxSize]),this.devicePixelContentBoxSize=gi([r.devicePixelContentBoxSize])}return a}(),ku=function(a){if(yu(a))return 1/0;for(var l=0,r=a.parentNode;r;)l+=1,r=r.parentNode;return l},C1=function(){var a=1/0,l=[];yi.forEach(function(o){if(o.activeTargets.length!==0){var p=[];o.activeTargets.forEach(function(c){var u=new E1(c.target),m=ku(c.target);p.push(u),c.lastReportedSize=bu(c.target,c.observedBox),m<a&&(a=m)}),l.push(function(){o.callback.call(o.observer,p,o.observer)}),o.activeTargets.splice(0,o.activeTargets.length)}});for(var r=0,n=l;r<n.length;r++){var i=n[r];i()}return a},ac=function(a){yi.forEach(function(l){l.activeTargets.splice(0,l.activeTargets.length),l.skippedTargets.splice(0,l.skippedTargets.length),l.observationTargets.forEach(function(r){r.isActive()&&(ku(r.target)>a?l.activeTargets.push(r):l.skippedTargets.push(r))})})},D1=function(){var a=0;for(ac(a);g1();)a=C1(),ac(a);return b1()&&k1(),a>0},_t,xu=[],T1=function(){return xu.splice(0).forEach(function(a){return a()})},B1=function(a){if(!_t){var l=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return T1()}).observe(r,n),_t=function(){r.textContent="".concat(l?l--:l++)}}xu.push(a),_t()},N1=function(a){B1(function(){requestAnimationFrame(a)})},Co=0,A1=function(){return!!Co},z1=250,M1={attributes:!0,characterData:!0,childList:!0,subtree:!0},lc=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],rc=function(a){return a===void 0&&(a=0),Date.now()+a},St=!1,I1=function(){function a(){var l=this;this.stopped=!0,this.listener=function(){return l.schedule()}}return a.prototype.run=function(l){var r=this;if(l===void 0&&(l=z1),!St){St=!0;var n=rc(l);N1(function(){var i=!1;try{i=D1()}finally{if(St=!1,l=n-rc(),!A1())return;i?r.run(1e3):l>0?r.run(l):r.start()}})}},a.prototype.schedule=function(){this.stop(),this.run()},a.prototype.observe=function(){var l=this,r=function(){return l.observer&&l.observer.observe(document.body,M1)};document.body?r():Zi.addEventListener("DOMContentLoaded",r)},a.prototype.start=function(){var l=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),lc.forEach(function(r){return Zi.addEventListener(r,l.listener,!0)}))},a.prototype.stop=function(){var l=this;this.stopped||(this.observer&&this.observer.disconnect(),lc.forEach(function(r){return Zi.removeEventListener(r,l.listener,!0)}),this.stopped=!0)},a}(),$t=new I1,nc=function(a){!Co&&a>0&&$t.start(),Co+=a,!Co&&$t.stop()},O1=function(a){return!jt(a)&&!w1(a)&&getComputedStyle(a).display==="inline"},L1=function(){function a(l,r){this.target=l,this.observedBox=r||ao.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return a.prototype.isActive=function(){var l=bu(this.target,this.observedBox,!0);return O1(this.target)&&(this.lastReportedSize=l),this.lastReportedSize.inlineSize!==l.inlineSize||this.lastReportedSize.blockSize!==l.blockSize},a}(),R1=function(){function a(l,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=l,this.callback=r}return a}(),wo=new WeakMap,ic=function(a,l){for(var r=0;r<a.length;r+=1)if(a[r].target===l)return r;return-1},_o=function(){function a(){}return a.connect=function(l,r){var n=new R1(l,r);wo.set(l,n)},a.observe=function(l,r,n){var i=wo.get(l),o=i.observationTargets.length===0;ic(i.observationTargets,r)<0&&(o&&yi.push(i),i.observationTargets.push(new L1(r,n&&n.box)),nc(1),$t.schedule())},a.unobserve=function(l,r){var n=wo.get(l),i=ic(n.observationTargets,r),o=n.observationTargets.length===1;i>=0&&(o&&yi.splice(yi.indexOf(n),1),n.observationTargets.splice(i,1),nc(-1))},a.disconnect=function(l){var r=this,n=wo.get(l);n.observationTargets.slice().forEach(function(i){return r.unobserve(l,i.target)}),n.activeTargets.splice(0,n.activeTargets.length)},a}(),$1=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.");_o.connect(this,l)}return a.prototype.observe=function(l,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Zs(l))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");_o.observe(this,l,r)},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(!Zs(l))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");_o.unobserve(this,l)},a.prototype.disconnect=function(){_o.disconnect(this)},a.toString=function(){return"function ResizeObserver () { [polyfill code] }"},a}();const $o=new WeakMap;function V1(a){var l;for(let r=0,n=a.length;r<n;++r){const i=a[r],o=$o.get(i.target);if(typeof o=="function"){const{inlineSize:p,blockSize:c}=((l=i.borderBoxSize)==null?void 0:l[0])??{},{offsetWidth:u,offsetHeight:m}=i.target;o(Object.assign(i,{offsetWidth:u,offsetHeight:m,width:p??u,height:c??m}))}}}const wu=new(bi&&window.ResizeObserver||$1)(V1);function oc(a,l){$o.set(a,l),wu.observe(a)}function tc(a){$o.has(a)&&(wu.unobserve(a),$o.delete(a))}function F1(a={}){let l=Js;const r=e.watch(()=>e.unref(a.target),i=>{l(),!(!i||typeof a.onResize!="function")&&(oc(i,a.onResize),l=()=>{tc(i),l=Js})},{immediate:!0}),n=()=>{r(),l()};return e.getCurrentScope()&&e.onScopeDispose(n),{observeResize:oc,unobserveResize:tc,unobserve:n}}const P1=e.ref(!1);e.computed(()=>P1.value);const sc="__theme_style__",Et="__theme_observer__",cc=e.reactive(new Map),uc=new Map;e.watch(cc,()=>{if(!bi)return;uc.clear();const a=document.head.querySelector(`#${sc}`);a&&document.head.removeChild(a);const l=document.createElement("style");let r=`.${Et} { width: 1px }`,n=1;for(const[i,[o,p]]of cc.entries())r+=` html.${o} .${Et}, .${p} .${Et} { width: ${++n}px }`,uc.set(n,i);l.textContent=r,l.id=sc,document.head.appendChild(l)});const _u=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:r}){const n=a,i=r,o=e.reactive({width:-1,mergedStyle:{},lastLayoutLength:0,isDragging:!1,placeholder:{x:0,y:0,w:0,h:0,i:""},layouts:{},lastBreakpoint:null,originalLayout:null}),p=new Map,c=e.ref(n.layout),u=e.ref(),{observeResize:m,unobserveResize:g}=F1(),y=Vv();y.on("resizeEvent",d),y.on("dragEvent",D),e.onBeforeMount(()=>{i("layout-before-mount",c.value)}),e.onMounted(()=>{i("layout-mounted",c.value),e.nextTick(()=>{Jv(c.value),o.originalLayout=c.value,e.nextTick(()=>{R(),u.value&&m(u.value,Fv(E,16)),zi(c.value,n.verticalCompact),i("layout-updated",c.value),O(),E()})})}),e.onBeforeUnmount(()=>{y.clearAll(),u.value&&g(u.value)});function d(X,me,ue,U,W,Z){S(X,me,ue,U,W,Z)}function D(X,me,ue,U,W,Z){b(X,me,ue,U,W,Z)}e.watch(()=>o.width,(X,me)=>{e.nextTick(()=>{y.emit("updateWidth",X),me===-1&&e.nextTick(()=>{i("layout-ready",c.value)}),O()})}),e.watch(()=>[n.layout,n.layout.length],()=>{c.value=n.layout,j()}),e.watch(()=>n.colNum,X=>{y.emit("setColNum",X)}),e.watch(()=>n.rowHeight,X=>{y.emit("setRowHeight",X)}),e.watch(()=>n.isDraggable,X=>{y.emit("setDraggable",X)}),e.watch(()=>n.isResizable,X=>{y.emit("setResizable",X)}),e.watch(()=>n.isBounded,X=>{y.emit("setBounded",X)}),e.watch(()=>n.transformScale,X=>{y.emit("setTransformScale",X)}),e.watch(()=>n.responsive,X=>{X||(i("update:layout",o.originalLayout),y.emit("setColNum",n.colNum)),E()}),e.watch(()=>n.maxRows,X=>{y.emit("setMaxRows",X)}),e.watch([()=>n.margin,()=>n.margin[1]],O),e.provide(tu,e.reactive({...e.toRefs(n),...e.toRefs(o),increaseItem:w,decreaseItem:q})),e.provide(su,y),l({state:o,getItem:A,resizeEvent:S,dragEvent:b,layoutUpdate:j});function w(X){p.set(X.i,X)}function q(X){p.delete(X.i)}function A(X){return p.get(X)}function j(){if(!Bn(c.value)&&!Bn(o.originalLayout)){if(c.value.length!==o.originalLayout.length){const X=re(c.value,o.originalLayout);if(X.length>0)if(c.value.length>o.originalLayout.length)o.originalLayout=o.originalLayout.concat(X);else{const me=new Set(X.map(ue=>ue.i));o.originalLayout=o.originalLayout.filter(ue=>!me.has(ue.i))}o.lastLayoutLength=c.value.length,R()}zi(c.value,n.verticalCompact),y.emit("updateWidth",o.width),O(),i("layout-updated",c.value)}}function O(){o.mergedStyle={height:_()}}function E(){u.value&&(o.width=u.value.offsetWidth),y.emit("resizeEvent")}function _(){if(!n.autoSize)return;const X=parseFloat(n.margin[1]);return jv(c.value)*(n.rowHeight+X)+X+"px"}let x;function b(X,me,ue,U,W,Z){let ae=Ps(c.value,me);Bn(ae)&&(ae={h:0,w:0,x:0,y:0,i:""}),X==="dragstart"&&!n.verticalCompact&&(x=c.value.reduce((ve,{i:ze,x:te,y:N})=>({...ve,[ze]:{x:te,y:N}}),{})),X==="dragmove"||X==="dragstart"?(o.placeholder.i=me,o.placeholder.x=ae.x,o.placeholder.y=ae.y,o.placeholder.w=Z,o.placeholder.h=W,e.nextTick(()=>{o.isDragging=!0}),y.emit("updateWidth",o.width)):e.nextTick(()=>{o.isDragging=!1}),c.value=Rt(c.value,ae,ue,U,!0,n.preventCollision),n.restoreOnDrag?(ae.static=!0,zi(c.value,n.verticalCompact,x),ae.static=!1):zi(c.value,n.verticalCompact),y.emit("compact"),O(),X==="dragend"&&(x=void 0,i("layout-updated",c.value))}function S(X,me,ue,U,W,Z){let ae=Ps(c.value,me);Bn(ae)&&(ae={h:0,w:0,x:0,y:0,i:""});let ve;if(n.preventCollision){const ze=uu(c.value,{...ae,w:Z,h:W}).filter(te=>te.i!==ae.i);if(ve=ze.length>0,ve){let te=1/0,N=1/0;ze.forEach(se=>{se.x>ae.x&&(te=Math.min(te,se.x)),se.y>ae.y&&(N=Math.min(N,se.y))}),Number.isFinite(te)&&(ae.w=te-ae.x),Number.isFinite(N)&&(ae.h=N-ae.y)}}ve||(ae.w=Z,ae.h=W),X==="resizestart"||X==="resizemove"?(o.placeholder.i=me,o.placeholder.x=ue,o.placeholder.y=U,o.placeholder.w=ae.w,o.placeholder.h=ae.h,e.nextTick(()=>{o.isDragging=!0}),y.emit("updateWidth",o.width)):X&&e.nextTick(()=>{o.isDragging=!1}),n.responsive&&I(),zi(c.value,n.verticalCompact),y.emit("compact"),O(),X==="resizeend"&&i("layout-updated",c.value)}function I(){const X=e1(n.breakpoints,o.width);if(X===o.lastBreakpoint)return;const me=fu(X,n.cols);!Bn(o.lastBreakpoint)&&!o.layouts[o.lastBreakpoint]&&(o.layouts[o.lastBreakpoint]=Lt(c.value));const ue=a1(o.originalLayout,o.layouts,n.breakpoints,X,o.lastBreakpoint,me,n.verticalCompact);o.layouts[X]=ue,o.lastBreakpoint!==X&&i("breakpoint-changed",X,ue),c.value=ue,i("update:layout",ue),o.lastBreakpoint=X,y.emit("setColNum",me)}function R(){o.layouts=Object.assign({},n.responsiveLayouts)}function re(X,me){const ue=new Set(me.map(ae=>ae.i)),U=new Set(X.map(ae=>ae.i)),W=X.filter(ae=>!ue.has(ae.i)),Z=me.filter(ae=>!U.has(ae.i));return W.concat(Z)}return(X,me)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"wrapper",ref:u,class:"vgl-layout",style:e.normalizeStyle(o.mergedStyle)},[X.$slots.default?e.renderSlot(X.$slots,"default",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(c.value,ue=>(e.openBlock(),e.createBlock(Ro,e.mergeProps({key:ue.i,ref_for:!0},ue),{default:e.withCtx(()=>[e.renderSlot(X.$slots,"item",{item:ue})]),_:2},1040))),128)),e.withDirectives(e.createVNode(Ro,{class:"vgl-item--placeholder",x:o.placeholder.x,y:o.placeholder.y,w:o.placeholder.w,h:o.placeholder.h,i:o.placeholder.i},null,8,["x","y","w","h","i"]),[[e.vShow,o.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 j1={key:0,class:"item-view-group"},H1={key:0,class:"item-view-group"},U1=e.defineComponent({__name:"index",props:{children:{type:Object,default:()=>{}},level:{type:Number,default:1}},emits:["rowClick","routeUrl","radioChange"],setup(a,{emit:l}){const r=M.useModelComp(M.pinia),{isEdit:n}=M.storeToRefs(r),i=ti(M.pinia),o=l,p=a,c=e.ref(""),u=e.computed(()=>p==null?void 0:p.children),m=e.computed(()=>{var O,E,_,x;return((O=p==null?void 0:p.children)==null?void 0:O.length)>0&&((E=p==null?void 0:p.children)!=null&&E.every(b=>b==null?void 0:b.layout))?(x=(_=p==null?void 0:p.children)==null?void 0:_[0])==null?void 0:x.layout:"vertical"}),g=O=>{c.value=O,o("radioChange",O)},y=e.computed(()=>{var O,E;return((E=(O=p==null?void 0:p.children)==null?void 0:O[0])==null?void 0:E.isGridLayout)||!1}),d=e.ref((p==null?void 0:p.level)+1),D=e.computed(()=>{if(!(p!=null&&p.children)||!Array.isArray(p.children)||p.children.length<2)return!1;const O=p.children.some(_=>(_==null?void 0:_.name)==="测量系统配置表"&&(_==null?void 0:_.comp)==="ParentItem"),E=p.children.some(_=>(_==null?void 0:_.name)==="测量系统传递表"&&(_==null?void 0:_.comp)==="ParentItem");return O&&E}),w=e.computed(()=>{var E,_,x,b,S,I;let O=(E=p==null?void 0:p.children)==null?void 0:E.filter(R=>R==null?void 0:R.choice);if(i.setSelectTab((_=O==null?void 0:O[0])==null?void 0:_.choiceName),(c==null?void 0:c.value)!=="")return(x=p==null?void 0:p.children)==null?void 0:x.filter(R=>!(R!=null&&R.choiceName)||(R==null?void 0:R.choiceName)===(c==null?void 0:c.value));{let R=(S=(b=p==null?void 0:p.children)==null?void 0:b.find(re=>re==null?void 0:re.choice))==null?void 0:S.choiceName;return(I=p==null?void 0:p.children)==null?void 0:I.filter(re=>!(re!=null&&re.choiceName)||(re==null?void 0:re.choiceName)===R)}}),q=O=>{const E=(O==null?void 0:O.menuFilter)||[];return Array.isArray(E)&&(E==null?void 0:E.some(_=>{const x=typeof _=="string"?_:JSON.stringify(_);return x==null?void 0:x.includes("HideGroup=Yes")}))};e.watch(()=>p==null?void 0:p.children,()=>{D.value},{deep:!0});const A=O=>{o("rowClick",O)},j=(O,E)=>{o("routeUrl",O,E)};return(O,E)=>y.value?(e.openBlock(),e.createBlock(e.unref(_u),{key:0,layout:u.value,"onUpdate:layout":E[0]||(E[0]=_=>u.value=_),"is-draggable":e.unref(n)==="edit","is-resizable":e.unref(n)==="edit","col-num":24,margin:[8,16]},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(_,x)=>(e.openBlock(),e.createBlock(e.unref(Ro),{key:_.i,x:_.x,y:_.y,"min-h":_.minH,"max-h":_.maxH,"min-w":_.minW,w:_.w,h:_.h,i:_.i},{default:e.withCtx(()=>{var b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze;return[e.createElementVNode("div",{style:e.normalizeStyle({gap:"16px",display:"flex",flexDirection:"column",paddingBottom:x===((b=p==null?void 0:p.children)==null?void 0:b.length)-1?"0px":"24px"})},[((I=(S=_==null?void 0:_.component)==null?void 0:S.comp)==null?void 0:I.toUpperCase())!=="TABLE"&&((R=_==null?void 0:_.component)!=null&&R.name)?(e.openBlock(),e.createElementBlock("div",j1,[e.createElementVNode("div",{class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:(parseInt(d.value.toString())-1)*12+"px",fontWeight:600-(d.value-1)*100>=400?600-(d.value-1)*100:400,fontSize:17-d.value>=14?17-d.value+"px":"14px"})},e.toDisplayString((re=_==null?void 0:_.component)==null?void 0:re.name),5)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)((X=_==null?void 0:_.component)==null?void 0:X.comp)),{pageLayout:m.value,config:{showIndex:(me=e.unref(kr)[x])==null?void 0:me.showIndex,allowMove:(ue=e.unref(kr)[x])==null?void 0:ue.allowMove,viewport:(U=e.unref(kr)[x])==null?void 0:U.viewport,status:(W=e.unref(kr)[x])==null?void 0:W.status},related:_==null?void 0:_.relatedTables,compName:_==null?void 0:_.component.name,compNames:e.unref($c),itemData:(Z=_==null?void 0:_.component)==null?void 0:Z.compData,childItemData:(ae=_==null?void 0:_.component)==null?void 0:ae.itemChildData,key:e.unref(oi),cacheNewData:e.unref(Rc),onChange:e.unref(Mo),index:(_==null?void 0:_.id)??x,onContentChange:e.unref(Io),onPageChange:e.unref(Oo),parentTableId:(ve=_==null?void 0:_.component)==null?void 0:ve.tableId,allMapContents:e.unref(Mt),children:(ze=_==null?void 0:_.component)==null?void 0:ze.children,level:d.value,onRowClick:A,onRouteUrl:j,onClickTrigger:e.unref(Vc),onClickMainKey:e.unref(Fc),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(w.value,(_,x)=>{var b,S;return e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({gap:"16px",display:(_==null?void 0:_.isShow)===!1?"none":"flex",flexDirection:"column",paddingBottom:parseInt(x)===((b=p==null?void 0:p.children)==null?void 0:b.length)-1?"0px":"24px"})},[((S=_==null?void 0:_.comp)==null?void 0:S.toUpperCase())!=="TABLE"&&_.name?(e.openBlock(),e.createElementBlock("div",H1,[q(_)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:parseInt(d.value.toString())>1?"12px":"0px",fontWeight:600-(d.value-1)*100>=400?600-(d.value-1)*100:400,fontSize:17-d.value>=14?17-d.value+"px":"14px"})},e.toDisplayString(_.name),5))])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)(_.comp)),{compName:_.name,groupNames:_==null?void 0:_.nameContents,config:{showIndex:_==null?void 0:_.showIndex,allowMove:_==null?void 0:_.allowMove,viewport:_==null?void 0:_.viewport,status:_==null?void 0:_.status},itemData:_==null?void 0:_.compData,related:_==null?void 0:_.relatedTables,childItemData:_==null?void 0:_.itemChildData,key:e.unref(oi),onChange:e.unref(Mo),index:(_==null?void 0:_.id)??x,onContentChange:e.unref(Io),onPageChange:e.unref(Oo),parentTableId:_==null?void 0:_.tableId,allMapContents:e.unref(Mt),children:_==null?void 0:_.children,level:d.value,onRowClick:A,onRouteUrl:j,onRadioChange:g},null,40,["compName","groupNames","config","itemData","related","childItemData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level"]))],4)}),256))}}),q1=pr._export_sfc(U1,[["__scopeId","data-v-bafbdd45"]]),W1={class:"radio-group-container"},G1=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},emits:["radioChange"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(),o=ti(M.pinia),{selectTab:p}=M.storeToRefs(o);e.watch(()=>r==null?void 0:r.itemData,()=>{i.value=p.value},{immediate:!0,deep:!0});const c=u=>{i.value=u,n("radioChange",i.value)};return(u,m)=>(e.openBlock(),e.createElementBlock("div",W1,[e.createVNode(pl.ssRadio,{modelValue:i.value,"onUpdate:modelValue":m[0]||(m[0]=g=>i.value=g),content:r==null?void 0:r.itemData,onChange:c},null,8,["modelValue","content"])]))}}),K1=pr._export_sfc(G1,[["__scopeId","data-v-177d64c3"]]),Y1=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(a){const l=a,r=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,()=>{var n,i;r.value=((i=(n=l==null?void 0:l.itemData)==null?void 0:n.find(o=>(o==null?void 0:o.key)==="backGround"))==null?void 0:i.contents)??[]},{deep:!0,immediate:!0}),(n,i)=>(e.openBlock(),e.createElementBlock("div",null,[e.createVNode(pl.ssCarousel,{carouselList:r.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"}]),J1={TABLE:Yc,FORM:Rs,STATICFORM:Jc,TABLEOPERATE:$6,TABLESTYLE:l4,TABLEEXTEND:n4,TABLEINTERACTION:t4,FORMOPERATE:$s,FOLD:R4,CALCULATOR:H4,METHODBUTTON:W4,AVATARUPLOAD:ms.ssAvatar,SIGNATURE:ms.ssSignature,FORMTOP:Rs,STEP:n2,STEPOPERATE:T4,TIMELINE:u2,TIMELINEOPERATE:I4,FORMTOPOPERATE:$s,SIGNATUREOPERATE:a2,AVATARUPLOADOPERATE:Y4,TABS:f2,TABSOPERATE:Z2,CHART:fv,CHARTOPERATE:Sv,LAYOUT:Dv,LAYOUTOPERATE:Lv,PARENTITEM:q1,RADIO:K1,CAROUSEL:Y1};function $i(a){return J1[a==null?void 0:a.toUpperCase()]||null}exports.De=_u;exports.activeStepInfo=Mi;exports.addContents=Qi;exports.addVisibleDialog=Pt;exports.affixItems=d3;exports.allMapContents=Mt;exports.analyzeMenu=mc;exports.cacheNewData=Rc;exports.clickMainKey=Fc;exports.clickSavePage=u3;exports.clickStep=jc;exports.clickTrigger=Vc;exports.compId=oi;exports.compNames=$c;exports.compShow=Ri;exports.existLayouts=b3;exports.fixChangeValue=Vo;exports.generateLayouts=Y6;exports.getComponent=$i;exports.getComponents=eo;exports.getPageConstruct=yp;exports.getPageData=Hr;exports.getSliceContLength=E3;exports.gridRowHeight=H6;exports.gridRowHeightHmPg=au;exports.isStepLayout=Hc;exports.newGenerateLayouts=Z6;exports.onBack=s3;exports.onButtonChange=v3;exports.onChange=Mo;exports.onClick=c3;exports.onClickStep=k3;exports.onContentChange=Io;exports.onExtendTaskEnd=g3;exports.onOk=m3;exports.onPageBack=w3;exports.onPageChange=Oo;exports.onSelectFixContent=t3;exports.renderShowItems=Oc;exports.showItems=kr;exports.sliceTableLength=Lc;exports.slotContent=Su;exports.ssTable=Yc;exports.st=Ro;exports.stepItems=C3;exports.tabChange=x3;exports.toolBar=y3;exports.useFormComp=Ft;exports.useModelLoader=i0;exports.verifyButton=_3;
|
|
25
|
+
${vr}`,duration:5e3,showClose:!0})}else Ja.ElMessage.success("导出成功")}else Ja.ElMessage.error(((ol=cr==null?void 0:cr.data)==null?void 0:ol.message)||"导出失败")}catch(Ne){console.error("导出paraform失败:",Ne),Ja.ElMessage.error("导出失败:"+((Ne==null?void 0:Ne.message)||"未知错误"))}finally{Ia.close()}}else if(f!=null&&f.includes("导出")&&f!=="导出paraform"){if(f==="导出选中"&&((xa=Br.value)==null?void 0:xa.length)===0)return Ja.ElMessage.warning(`请先勾选${f}的数据`);if(f==="导出全部"&&((tl=Ce.value)==null?void 0:tl.length)===0)return Ja.ElMessage.warning("暂无数据导出");let Ia=["序号",...(Va=(be=W.value)==null?void 0:be.map(ha=>ha==null?void 0:ha.prop))==null?void 0:Va.filter(ha=>ha!=="操作")],Ne=f==="导出全部"?Ce.value:Br.value;const Q=["id","sort","tableEditType","create_time","update_time","source_table","create_user_id","update_user_id","department_id","relatedId"];Ne=Ne==null?void 0:Ne.map(ha=>Object.fromEntries(Object.entries(ha).filter(([B])=>!Q.includes(B)))),Ia=["序号",...Ia],Ne=Ne==null?void 0:Ne.map((ha,B)=>({序号:B+1,...ha}));let je=(d==null?void 0:d.compName)||"表格信息";qo(Ne,je,Ia,je)}else if(f==="OCR识别")Sl.value=!0,ga.value=[],Ha.value=1,Sa.value.clear(),ll.value.clear(),Te.value=0;else if(f==="迁移")Y.selectRow=v,Y.show=!0;else if(f==="生成方法"){let Ia=await I0(v),Ne;v!==""?Ne=[v]:Ne=M.cloneDeep(Ce.value),Ne=Ne==null?void 0:Ne.map(je=>(je.输出值=Ia,je));const Q={fixContent:Ne,buttonName:"编辑",relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames};U("change",Q)}else if(f==="签字板"||f==="触控笔")$a.value.dialogShow=!0,$a.value.dialogTitle=f;else if(((ba=z==null?void 0:z.extra)==null?void 0:ba.type)==="methodButton"){let Ia;v!==""?Ia=[v]:Ia=M.cloneDeep(Ce.value);const Ne=await Tt(Ia,W==null?void 0:W.value,"Manual",Ce.value,d==null?void 0:d.calculator,d==null?void 0:d.compNames);let Q;(Ya=Ne==null?void 0:Ne[0])!=null&&Ya.menuPathContent?Q={fixContent:Ne,buttonName:"新增",relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames}:Q={fixContent:Ne,buttonName:"methodButton",relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames},U("change",Q)}}},Nu=async(f,v)=>{var z,L,H,T,ie,oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be;try{let Va,ba;const Ya=(z=pa.value[de.value+I])==null?void 0:z.filter(Ua=>{var sl;return((sl=Ua==null?void 0:Ua.key)==null?void 0:sl.type)==="structureMethod"}),Ia=(L=pa.value[de.value+I])==null?void 0:L.filter(Ua=>{var sl;return((sl=Ua==null?void 0:Ua.key)==null?void 0:sl.type)==="structure"}),Ne=Ya==null?void 0:Ya.find(Ua=>{var sl,Ga;return((Ga=(sl=Ua==null?void 0:Ua.value)==null?void 0:sl.pageData)==null?void 0:Ga.method)==="保存"});if(!Ne)return;const Q=(oe=(ie=pa.value[(T=(H=Ne==null?void 0:Ne.value)==null?void 0:H.pageData)==null?void 0:T.path])==null?void 0:ie.filter(Ua=>{var sl;return((sl=Ua==null?void 0:Ua.key)==null?void 0:sl.type)==="data"}))==null?void 0:oe.find(Ua=>{var sl,Ga,Da,dl;return((Ga=(sl=Ua==null?void 0:Ua.value)==null?void 0:sl.tableData)==null?void 0:Ga.算法名称)===((dl=(Da=Ne==null?void 0:Ne.value)==null?void 0:Da.pageData)==null?void 0:dl.method)});if(!Q)return;const je={buttonName:(ke=(K=Ne==null?void 0:Ne.value)==null?void 0:K.pageData)==null?void 0:ke.method,api:(Je=(ge=Q==null?void 0:Q.value)==null?void 0:ge.tableData)==null?void 0:Je.算法体,content:Ia==null?void 0:Ia.map(Ua=>{var sl;return(sl=Ua==null?void 0:Ua.value)==null?void 0:sl.pageData}),extraContent:[],extraValues:(ea=(Ue=Ne==null?void 0:Ne.value)==null?void 0:Ue.pageData)==null?void 0:ea.data,methodName:(Na=(ka=Ne==null?void 0:Ne.value)==null?void 0:ka.pageData)==null?void 0:Na.path};if(!f)return;const ha={...f,compData:(Aa=f==null?void 0:f.compData)==null?void 0:Aa.map(Ua=>{var sl;return(Ua==null?void 0:Ua.key)==="formContent"?{...Ua,contents:(sl=Ua==null?void 0:Ua.contents)==null?void 0:sl.map(Ga=>(Ga==null?void 0:Ga.prop)===v?{...Ga,value:""}:Ga)}:Ua})},B={key:{pageKey:de.value+I,parentTable:"",systemKey:sessionStorage.getItem("systemKey"),type:"structure"},value:{pageData:ha}},za=await Ja.axios.post(je.api,B,{headers:{"Content-Type":"application/json"}});return((la=za==null?void 0:za.data)==null?void 0:la.code)===200&&(Va=(xa=(ol=za==null?void 0:za.data)==null?void 0:ol.result)==null?void 0:xa.latestReportCode,ba=(be=(tl=za==null?void 0:za.data)==null?void 0:tl.result)==null?void 0:be.status),{newMainKeyValue:Va,newStatus:ba}}catch(Va){throw Ja.ElMessage.error(Va),new Error(Va)}},Ht=e.reactive({prop:"状态",value:""});e.ref(["系统自动生成信息","审批意见"]);const Au=async(f,v,z)=>{var K,ke;let L=f==null?void 0:f[v==null?void 0:v.prop],H=1,T,ie;const oe=M.cloneDeep(de).value+I+L;if(oe){Ht.value="",T=(K=pa.value[oe])==null?void 0:K.filter(Ue=>{var ea;return((ea=Ue==null?void 0:Ue.key)==null?void 0:ea.type)==="structure"});const ge=T==null?void 0:T.find(Ue=>{var ea,ka,Na;return((Na=(ka=(ea=Ue==null?void 0:Ue.value)==null?void 0:ea.pageData)==null?void 0:ka.comp)==null?void 0:Na.toUpperCase())==="FORM"});ie={...(ke=ge==null?void 0:ge.value)==null?void 0:ke.pageData,id:ge==null?void 0:ge.id};const Je=await Nu(ie,v==null?void 0:v.prop);if(Ht.value=Je==null?void 0:Je.newStatus,Je!=null&&Je.newMainKeyValue)return Je==null?void 0:Je.newMainKeyValue}if(Ce.value.some(ge=>(ge==null?void 0:ge[v==null?void 0:v.prop])===L)){const ge=L;for(;Ce.value.some(Je=>(Je==null?void 0:Je[v==null?void 0:v.prop])===`${ge}(${H})`);)H++;L=`${ge}(${H})`}return L},zu=async(f,v,z)=>{var T,ie,oe,K;let L,H;if(await Au(z==null?void 0:z.data,z==null?void 0:z.firstCol),L=M.cloneDeep(de).value+I,H=M.cloneDeep(L)+`loading${((T=Nl.value)==null?void 0:T.account)||((ie=Nl.value)==null?void 0:ie.账号)}`,v){const ke=(K=(oe=pa.value[H])==null?void 0:oe.filter(ge=>{var Je;return((Je=ge==null?void 0:ge.key)==null?void 0:Je.parentTable)===""}))==null?void 0:K.map(ge=>{var Je;return{id:ge==null?void 0:ge.id,...(Je=ge==null?void 0:ge.value)==null?void 0:Je.pageData}});(ke==null?void 0:ke.length)>0||await le.loadingConstruct(L,H,null,null,null),Ge.setRouteToChildPath(M.cloneDeep(de).value),Le.setActiveMenuPath(H)}else Ge.setRouteToChildPath(M.cloneDeep(de).value),Le.setActiveMenuPath(H)},Mu=()=>{te.value=!1,Be.value=[],N.value=!1},ji=f=>{var oe,K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne,Q,je,ha;const v=[];ze.value=M.cloneDeep(W.value);let z=(K=(oe=u.value)==null?void 0:oe.find(B=>{var za;return(za=B==null?void 0:B.key)==null?void 0:za.includes("@EditRead")}))==null?void 0:K.content,L=!1;(z==null?void 0:z.length)>0&&(L=Bs(z,f),(L==null?void 0:L.length)>0?L=!0:L=!1),(ge=le.getColumnChild((ke=M.cloneDeep(W.value))==null?void 0:ke.filter(B=>(B==null?void 0:B.label)!=="操作")))==null||ge.forEach((B,za)=>{var Ua,sl,Ga;B!=null&&B.formType&&((Ua=B==null?void 0:B.formType)==null?void 0:Ua.toUpperCase())==="SELECT"||B!=null&&B.menuId?v.push({label:(sl=B==null?void 0:B.prop)!=null&&sl.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"+za,prop:B==null?void 0:B.prop,type:"Select",value:(f==null?void 0:f[B==null?void 0:B.prop])??(B==null?void 0:B.value)??"",id:(B==null?void 0:B.id)??za,contents:(B==null?void 0:B.options)??[],multiple:(B==null?void 0:B.multiple)??!1,multipleLimit:B==null?void 0:B.multipleLimit,width:2,isFormColHidden:B==null?void 0:B.isFormColHidden,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,allSelectionContents:(B==null?void 0:B.allSelectionContents)??[],filterContent:B==null?void 0:B.filterContent,disabled:(B==null?void 0:B.prop)==="disabled"?!0:L||(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:(Ga=B==null?void 0:B.prop)!=null&&Ga.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"+za,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"?(f==null?void 0:f[B==null?void 0:B.prop])??"{}":(f==null?void 0:f[B==null?void 0:B.prop])??(B==null?void 0:B.value)??"",id:(B==null?void 0:B.id)??za,contents:(B==null?void 0:B.options)??[],multiple:(B==null?void 0:B.multiple)??!1,width:2,isFormColHidden:B==null?void 0:B.isFormColHidden,disabled:(B==null?void 0:B.prop)==="disabled"?!0:L||(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})}),f===""||!f||(fa.value=(f==null?void 0:f.id)??"");let H=le.getColumnChild((Je=M.cloneDeep(W.value))==null?void 0:Je.filter(B=>(B==null?void 0:B.label)!=="操作"));na.value&&((Ue=na.value)==null?void 0:Ue.length)>0&&(na.value=(ea=M.cloneDeep(na).value)==null?void 0:ea.map(B=>{var Ua;let za=(B==null?void 0:B.prop)||((Ua=H==null?void 0:H.find(sl=>(sl==null?void 0:sl.label)===(B==null?void 0:B.label)))==null?void 0:Ua.prop);return za&&(B.value=f[za]),B})),ye.value=na.value&&((ka=na.value)==null?void 0:ka.length)>0?le.getTableFormToForm(na.value):v,ye.value=((Na=ye.value)==null?void 0:Na.map(B=>({...B,disabled:(B==null?void 0:B.prop)==="disabled"?!0:B==null?void 0:B.disabled})))??ye.value;let T=[],ie=((ol=(la=(Aa=d.itemData)==null?void 0:Aa.filter(B=>(B==null?void 0:B.key)==="filter"))==null?void 0:la[0])==null?void 0:ol.contents)??"";if(ie=le.analyzeSplitToContent(ie,","),(ie==null?void 0:ie.length)>0&&(T=ie.flat()),(T==null?void 0:T.length)>0){let B=T==null?void 0:T.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=(tl=(xa=B==null?void 0:B.replace("=",b))==null?void 0:xa.split(b))==null?void 0:tl[1];((be=Da==null?void 0:Da.trim())==null?void 0:be.toUpperCase())==="MANUAL"&&(d==null||d.index,ye.value=(Va=ye.value)==null?void 0:Va.map((dl,Wl)=>dl))}let za=(ba=ye.value)==null?void 0:ba.filter(Da=>Da==null?void 0:Da.mainKey),Ua;za==null||za.forEach(Da=>{var Wl;if(Ua!==void 0)return;let dl=Da==null?void 0:Da.menus;((Wl=za==null?void 0:za.filter(qa=>qa==null?void 0:qa.mainKey))==null?void 0:Wl.length)>1&&(Ua=dl,Da==null||Da.groups)});let sl=[],Ga=new Map;if(za==null||za.forEach(Da=>{var dl,Wl,qa,Tl,La,Ll,nl,vl,zl,xl,Cr,hr,cr;if((dl=Da==null?void 0:Da.prop)!=null&&dl.includes(".")){let _l=[];Ga.get(((qa=(Wl=Da==null?void 0:Da.prop)==null?void 0:Wl.split("."))==null?void 0:qa[0])+(Da!=null&&Da.isMainPath?0:1)+((Tl=Da==null?void 0:Da.groups)==null?void 0:Tl[0]))&&(_l=Ga.get(((Ll=(La=Da==null?void 0:Da.prop)==null?void 0:La.split("."))==null?void 0:Ll[0])+(Da!=null&&Da.isMainPath?0:1)+((nl=Da==null?void 0:Da.groups)==null?void 0:nl[0]))),_l.push(Da),Ga.set(((zl=(vl=Da==null?void 0:Da.prop)==null?void 0:vl.split("."))==null?void 0:zl[0])+(Da!=null&&Da.isMainPath?0:1)+((xl=Da==null?void 0:Da.groups)==null?void 0:xl[0]),_l)}else{let _l=[];Ga.get("normal"+(Da!=null&&Da.isMainPath?0:1)+((Cr=Da==null?void 0:Da.groups)==null?void 0:Cr[0]))&&(_l=Ga.get("normal"+(Da!=null&&Da.isMainPath?0:1)+((hr=Da==null?void 0:Da.groups)==null?void 0:hr[0]))),_l.push(Da),Ga.set("normal"+(Da!=null&&Da.isMainPath?0:1)+((cr=Da==null?void 0:Da.groups)==null?void 0:cr[0]),_l)}}),sl=Array.from(Ga.values()),(sl==null?void 0:sl.length)>0)for(let Da in sl){let dl=sl==null?void 0:sl[Da];if((dl==null?void 0:dl.length)!==1){if((dl==null?void 0:dl.length)>1){let Wl=dl==null?void 0:dl.map(xl=>xl==null?void 0:xl.prop),qa=dl==null?void 0:dl.map(xl=>xl==null?void 0:xl.label),Tl=dl==null?void 0:dl.map(xl=>xl==null?void 0:xl.value),La=(Ya=M.cloneDeep(dl))==null?void 0:Ya[0],Ll=(Ia=ye.value)==null?void 0:Ia.findIndex(xl=>(xl==null?void 0:xl.prop)===(La==null?void 0:La.prop)),nl=(Ne=ye.value)==null?void 0:Ne.slice(0,Ll),vl=(je=ye.value)==null?void 0:je.slice(Ll,(Q=ye.value)==null?void 0:Q.length);La.label=qa==null?void 0:qa.join("·"),La.value=Tl==null?void 0:Tl.join(" "),La.value.trim()===""&&(La.value=""),La.prop=Wl==null?void 0:Wl.join("·");let zl=dl==null?void 0:dl.map(xl=>{var Cr;return(Cr=xl==null?void 0:xl.words)==null?void 0:Cr.join(".")});La.relatedWords=zl,La.usingType="parent",vl.unshift(La),ye.value=[...nl,...vl],ye.value=(ha=ye.value)==null?void 0:ha.map(xl=>(Wl!=null&&Wl.find(Cr=>Cr===(xl==null?void 0:xl.prop))&&(xl.isFormColHidden=!0,xl.relatedWords=zl),xl))}}}}},Iu=()=>{var v;const f=(v=i.value)==null?void 0:v.$el;f&&Fl.Sortable.create(f,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:z=>{var ie;const{oldIndex:L,newIndex:H}=z;if(L===H)return;const T=Qn.value.splice(L,1)[0];Qn.value.splice(H,0,T),W.value=(ie=W.value)==null?void 0:ie.slice().sort((oe,K)=>{if(oe.label==="操作")return 1;if(K.label==="操作")return-1;const ke=Qn.value.findIndex(Je=>Je.label===oe.label),ge=Qn.value.findIndex(Je=>Je.label===K.label);return ke-ge})}})};e.onMounted(()=>{We.value=window.innerWidth-240*2,window.addEventListener("keydown",si)});const Ou=()=>{e.nextTick(()=>{Iu()})},Lu=()=>{c.value=!0},ft=(f,v)=>{var L;if(!f&&!(f!=null&&f.children))return{contents:f,currentSelectContents:void 0};let z;return f.children=(L=f.children)==null?void 0:L.map(H=>{var T,ie;if((H==null?void 0:H.id)===fa.value){let oe={};for(let K in H){let ke=(T=v==null?void 0:v.find(ge=>(ge==null?void 0:ge.prop)===K))==null?void 0:T.label;ke?oe[K]=(ie=Yl.value)==null?void 0:ie[ke]:oe[K]=H[K]??""}H=Object.assign(oe,Yl.value),z=H}else{let oe=ft(H,v);H=oe==null?void 0:oe.contents,z=oe==null?void 0:oe.currentSelectContents}return H}),{contents:f,currentSelectContents:z}},Ut=(f,v)=>{let z,L;return f!=null&&f.find(H=>(H==null?void 0:H.id)===fa.value)?z=f==null?void 0:f.map(H=>{var T,ie,oe;if((H==null?void 0:H.id)===fa.value){let K={};for(let ge in H){let Je=(T=v==null?void 0:v.find(Ue=>(Ue==null?void 0:Ue.prop)===ge))==null?void 0:T.label;Je?K[ge]=((ie=Yl.value)==null?void 0:ie[Je])??"":K[ge]=H[ge]??""}let ke=Yl.value;for(let ge in K)(oe=Yl.value)!=null&&oe[ge]||(ke[ge]=(K==null?void 0:K[ge])??"");H=ke,L=H}return H}):z=f==null?void 0:f.map(H=>{var T,ie,oe,K;if((H==null?void 0:H.id)===fa.value){let ke={};for(let ge in H){let Je=(T=v==null?void 0:v.find(Ue=>(Ue==null?void 0:Ue.prop)===ge))==null?void 0:T.label;Je?ke[ge]=(ie=Yl.value)==null?void 0:ie[Je]:ke[ge]=H[ge]??""}H=Object.assign(ke,Yl.value),L=H}else H=(oe=ft(H,v))==null?void 0:oe.contents,L=(K=ft(H,v))==null?void 0:K.currentSelectContents;return H}),{newContents:z,currentSelectContents:L}},qt=(f,v,z)=>{var L,H;return f[v==null?void 0:v.prop]=z,typeof f.id=="number"&&(f.id=(L=f.id)==null?void 0:L.toString()),f.children&&((H=f.children)==null?void 0:H.length)>0&&(f.children=f.children.map(qt)),f},Wt=f=>{var z;const v=[];return v.push({...f}),f!=null&&f.children&&Array.isArray(f.children)&&((z=f.children)==null||z.forEach(L=>{v.push(...Wt(L))})),(v==null?void 0:v.length)>0?v==null?void 0:v.map(L=>{const H={...L};return delete H.children,H}):[]},po=["Pacific6000数据采集装置.通道号","通道号"],Hi=f=>{if(!f)return"";const v=po.map(z=>f==null?void 0:f[z]).find(z=>z!=null&&String(z).trim()!=="");return v==null?"":String(v).trim()},ht=async(f,v=void 0)=>{if(!f)return!1;try{const z=ea=>{var ka,Na,Aa;return ea?typeof(ea==null?void 0:ea.value)=="string"?ea.value:((Aa=(Na=(ka=ea==null?void 0:ea._custom)==null?void 0:ka.value)==null?void 0:Na.value)==null?void 0:Aa.value)||"":""},L=Array.isArray(nr.value)?nr.value:[],H=z(L.find(ea=>(ea==null?void 0:ea.condition)==="child")),T=(de.value||"").replace(/\/+$/,""),ie=H?`${T}/${H}`:T,oe=await Hr(ie||de.value,!1),K=String(Ve.value||"").trim(),ke=ea=>String(ea||"").trim(),ge=(ea,ka=[],Na="")=>{if(!Array.isArray(ea))return ka;for(const Aa of ea){const la=ke((Aa==null?void 0:Aa.choiceName)||(Aa==null?void 0:Aa.name0)||Na);(Aa==null?void 0:Aa.comp)==="Table"&&(!K||la===K)&&ka.push(Aa),Array.isArray(Aa==null?void 0:Aa.children)&&ge(Aa.children,ka,la),Array.isArray(Aa==null?void 0:Aa.tab)&&ge(Aa.tab,ka,la),Array.isArray(Aa==null?void 0:Aa.choice)&&ge(Aa.choice,ka,la)}return ka},Je=ge(oe||[]),Ue=String((d==null?void 0:d.compName)||"");return Je.some(ea=>{var Na,Aa;const ka=((Aa=(Na=ea==null?void 0:ea.compData)==null?void 0:Na.find(la=>(la==null?void 0:la.key)==="tableContents"))==null?void 0:Aa.contents)||[];return!Array.isArray(ka)||ka.length===0?!1:ka.some(la=>{if(String((ea==null?void 0:ea.name)||"")===Ue&&(la==null?void 0:la.id)===v)return!1;const xa=Hi(la);return!!xa&&xa===f})})}catch{return(Ce.value||[]).some(L=>{if((L==null?void 0:L.id)===v)return!1;const H=Hi(L);return!!H&&H===f})}},Ui=async(f=!0,v,z)=>{var ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl;if(Yl.value){const La=(ge=le.getColumnChild((ke=M.cloneDeep(W.value))==null?void 0:ke.filter(nl=>(nl==null?void 0:nl.label)!=="操作")))==null?void 0:ge.filter(nl=>(nl==null?void 0:nl.required)===!0);for(let nl=0;nl<((La==null?void 0:La.length)??0);nl++){const vl=La[nl],zl=vl==null?void 0:vl.prop,xl=(vl==null?void 0:vl.label)??zl,Cr=(Je=Yl.value)==null?void 0:Je[zl];if(Cr===""||Cr===null||Cr===void 0||Array.isArray(Cr)&&Cr.length===0){Ja.ElMessage.error(`${xl}不能为空`);return}}const Ll=Hi(Yl.value);if(Ll&&await ht(Ll,fa.value||void 0)){Ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择");return}}let L=le.getColumnChild((Ue=M.cloneDeep(W.value))==null?void 0:Ue.filter(La=>(La==null?void 0:La.label)!=="操作")),H,T=M.cloneDeep(Ce.value);if(!Yl.value){Qe.value=!1;return}if(fa.value===""){sa.value++;let La;La={id:sa.value.toString()};try{La.sort=ui(0,Ce.value||[])}catch{}La!=null&&La.children&&(La={...La,children:(ea=La.children)==null?void 0:ea.map(nl=>qt(nl,v,z))});const Ll=Object.assign(Yl.value,La);T.unshift(Ll),H=Ll}else T=(ka=Ut(T,L))==null?void 0:ka.newContents,H=(Na=Ut(T,L))==null?void 0:Na.currentSelectContents;const ie=(Aa=d.itemData)==null?void 0:Aa.filter(La=>(La==null?void 0:La.key)==="childTree")[0];if(((la=ie==null?void 0:ie.contents)==null?void 0:la.length)>0){ma.value="编辑";const La=[];T==null||T.forEach((vl,zl)=>{var Cr;let xl={};if(Array.isArray(vl)){let hr=[];vl==null||vl.filter(cr=>!(cr!=null&&cr.id)).forEach((cr,_l)=>{var rr,mr,Il,yr,Dr,gr,Mr;if((mr=(rr=lr.value)==null?void 0:rr[_l])!=null&&mr.prop&&!Array.isArray(cr)){let tn={};tn[lr.value[_l].column]=cr,V!=null&&V.value&&((Il=V==null?void 0:V.value)==null?void 0:Il.length)>0&&((yr=V==null?void 0:V.value)!=null&&yr.find(vr=>JSON.stringify(vr==null?void 0:vr[0])===JSON.stringify(tn)))&&(hr=(Dr=V==null?void 0:V.value)==null?void 0:Dr.find(vr=>JSON.stringify(vr==null?void 0:vr[0])===JSON.stringify(tn))),hr&&hr.length>0?xl[lr.value[_l].prop]=hr!=null&&hr.find(vr=>{var Or;return((Or=Object.keys(vr))==null?void 0:Or[0])===lr.value[_l].column})?(gr=hr==null?void 0:hr.find(vr=>{var Or;return((Or=Object.keys(vr))==null?void 0:Or[0])===lr.value[_l].column}))==null?void 0:gr[lr.value[_l].column]:cr:xl[lr.value[_l].prop]=cr}else Array.isArray(cr)&&((Mr=lr.value[_l])!=null&&Mr.prop?xl[lr.value[_l].prop]=cr:xl.children=Bt(cr,lr.value))})}else xl=vl;if(Array.isArray(vl)&&vl.some(hr=>hr==null?void 0:hr.id)){const hr=(Cr=vl==null?void 0:vl.find(cr=>cr.id))==null?void 0:Cr.id;La.push(Object.assign(xl,{id:to(hr)}))}else xl.id?La.push(xl):La.push(Object.assign(xl,{id:zl.toString()}))});const Ll=(Ce.value||[]).map(vl=>String(vl==null?void 0:vl.id)),nl=_i(La,Ll);Ce.value=Jt(nl,ie,W.value)}Kt(Ce.value),Sr.value=Ce.value;const oe=g0(Sr.value,$l.value,T);let K=[];if(ee.value?(K=(ol=M.cloneDeep(ee).value.singleContent)==null?void 0:ol.filter(La=>(La==null?void 0:La.id)!==(H==null?void 0:H.id)),K.push(H)):K=[H],er.value){const La={content:oe,singleContent:((xa=ie==null?void 0:ie.contents)==null?void 0:xa.length)>0?K==null?void 0:K.flatMap(Wt):K,index:d==null?void 0:d.index,buttonName:"编辑",column:W.value,parentTableId:d==null?void 0:d.parentTableId};Ge.setCacheUpdatingData(La)}if((tl=W.value)==null||tl.forEach(La=>{(La==null?void 0:La.formType)==="Upload"&&(H[La.prop]=H[La.prop]===""?"{}":typeof H[La.prop]!="string"?JSON.stringify(H[La.prop]):H[La.prop])}),f){(Ya=(ba=(Va=(be=d.itemData)==null?void 0:be.find(nl=>(nl==null?void 0:nl.key)==="filterAllType"))==null?void 0:Va.value)==null?void 0:ba.find(nl=>(nl==null?void 0:nl.value)==="onConditionContents"))==null||Ya.content;let La=(Ia=d.itemData)==null?void 0:Ia.filter(nl=>(nl==null?void 0:nl.key)==="filterAllType");La=Array.from(new Map(La.filter(Boolean).map((nl,vl)=>[nl.value,{...nl,_idx:vl}])).values()).sort((nl,vl)=>nl._idx-vl._idx).map(({_idx:nl,...vl})=>vl),La=(Ne=La==null?void 0:La[(La==null?void 0:La.length)-1])==null?void 0:Ne.value;const Ll={fixContent:[H],buttonName:ma.value,relatedContents:d==null?void 0:d.related,columns:W.value,name:d==null?void 0:d.groupNames};Ge.setTableLoading(d==null?void 0:d.index),Qe.value=!1,Yl.value=void 0,U("change",Ll)}if((ha=(je=(Q=ye.value)==null?void 0:Q[0])==null?void 0:je.optionUrl)!=null&&ha.menuId){Qe.value=!1;let La=(B=d.itemData)==null?void 0:B.filter(Ll=>(Ll==null?void 0:Ll.key)==="filterAllType");if((La==null?void 0:La.length)>0){let Ll=La==null?void 0:La.map(zl=>zl==null?void 0:zl.value),nl=(sl=(Ua=(za=Ll.flat().find(zl=>{var xl;return(xl=zl==null?void 0:zl.content)==null?void 0:xl.includes("@Num")}))==null?void 0:za.content)==null?void 0:Ua.split(":"))==null?void 0:sl[1];((dl=(Da=(Ga=Ll.flat().find(zl=>{var xl;return(xl=zl==null?void 0:zl.content)==null?void 0:xl.includes("@Type:")}))==null?void 0:Ga.content)==null?void 0:Da.split(":"))==null?void 0:dl[1])!=="Manual"&&(nl=parseInt(nl),Ce.value=(Tl=Ce.value)==null?void 0:Tl.slice(((Wl=Ce.value)==null?void 0:Wl.length)-nl,(qa=Ce.value)==null?void 0:qa.length))}}};e.onUnmounted(()=>{window.removeEventListener("keydown",si),W.value=[],Ce.value=[],ze.value=[],P.value=[],na.value=[],va.value=[],Be.value=[],Ye.value=[],ye.value=[],Br.value=[],i.value=null,rn.value=""});const fo=async(f,v,z)=>{var ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia;Tr.value=(z==null?void 0:z.prop)??(z==null?void 0:z.property);const L=M.cloneDeep(d.itemData),H=((ea=L==null?void 0:L.find(Ne=>(Ne==null?void 0:Ne.key)==="header"))==null?void 0:ea.contents)??[];let T=H==null?void 0:H.find((Ne,Q)=>{var je,ha,B;return(Ne==null?void 0:Ne.prop)===Tr.value||(Ne==null?void 0:Ne.label)===Tr.value||(Q==null?void 0:Q.toString())===((B=(ha=(je=Tr.value)==null?void 0:je.split("a"))==null?void 0:ha[1])==null?void 0:B.toString())});const ie=le.getColumnChild((ka=M.cloneDeep(W.value))==null?void 0:ka.filter(Ne=>(Ne==null?void 0:Ne.label)!=="操作"));if(T||(T=ie==null?void 0:ie.find(Ne=>(Ne==null?void 0:Ne.prop)===Tr.value||(Ne==null?void 0:Ne.label)===Tr.value)),T&&!((Na=T==null?void 0:T.menus)!=null&&Na.length)&&!((Aa=T==null?void 0:T.groups)!=null&&Aa.length)&&!((la=T==null?void 0:T.words)!=null&&la.length)){const Ne=(ol=ye.value)==null?void 0:ol.find(Q=>(Q==null?void 0:Q.prop)===Tr.value);Ne&&(T={...T,menus:(Ne==null?void 0:Ne.menus)??(T==null?void 0:T.menus),groups:(Ne==null?void 0:Ne.groups)??(T==null?void 0:T.groups),words:(Ne==null?void 0:Ne.words)??(T==null?void 0:T.words),bindMenus:(Ne==null?void 0:Ne.bindMenus)??(T==null?void 0:T.bindMenus),isMainPath:(Ne==null?void 0:Ne.isMainPath)??(T==null?void 0:T.isMainPath),relatedContents:(Ne==null?void 0:Ne.relatedContents)??(T==null?void 0:T.relatedContents),endChildMenu:(Ne==null?void 0:Ne.endChildMenu)??(T==null?void 0:T.endChildMenu)})}if(T&&((xa=ye==null?void 0:ye.value)==null||xa.forEach(Ne=>{var Q,je,ha,B,za;(Ne==null?void 0:Ne.prop)===(T==null?void 0:T.prop)&&(Ne!=null&&Ne.endChildMenu)&&((Q=T==null?void 0:T.prop)!=null&&Q.includes(".")&&((ha=(je=T==null?void 0:T.prop)==null?void 0:je.split("."))==null?void 0:ha[0])!==((za=(B=Ne==null?void 0:Ne.prop)==null?void 0:B.split("."))==null?void 0:za[0])?T.endChildMenu=Ne==null?void 0:Ne.value:T.endChildMenu=Ne==null?void 0:Ne.endChildMenu)})),!T)return;const oe=Tr.value,K=(tl=Ce.value)==null?void 0:tl.findIndex(Ne=>(Ne==null?void 0:Ne.id)===(v==null?void 0:v.id));K!==-1&&oe&&(Ce.value[K]={...Ce.value[K],[oe]:f});const ke=Ne=>{Array.isArray(Ne)&&Ne.forEach(Q=>{Array.isArray(Q==null?void 0:Q.allSelectionContents)&&Q.allSelectionContents.length>0&&(Q.contactValue=Ce.value[K]??v),Array.isArray(Q==null?void 0:Q.children)&&Q.children.length>0&&ke(Q.children)})};ke(W.value),T.value=f,T.endChildMenu=T.endChildMenu||"";let ge=T!=null&&T.isMainPath&&(T!=null&&T.mainKey)?T==null?void 0:T.value:"";const Je=Ne=>{Array.isArray(Ne)&&Ne.forEach(Q=>{var ha,B;if(((Q==null?void 0:Q.type)==="Select"||(Q==null?void 0:Q.formType)&&Q.formType.toUpperCase()==="SELECT"||(Q==null?void 0:Q.columnType)&&Q.columnType.toUpperCase()==="SELECT")&&Array.isArray(Q==null?void 0:Q.menus)&&Q.menus.length>0&&Q.menus[Q.menus.length-1]===""&&(T!=null&&T.isMainPath)&&(T!=null&&T.mainKey)){const za=(ha=Q==null?void 0:Q.prop)!=null&&ha.includes(".")?Q.prop.split(".")[0]:null,Ua=(B=T==null?void 0:T.prop)!=null&&B.includes(".")?T.prop.split(".")[0]:null;(!za||!Ua||za===Ua)&&(Q.endChildMenu=ge)}Array.isArray(Q==null?void 0:Q.children)&&Q.children.length>0&&Je(Q.children)})};if(Je(W.value),!!(T!=null&&T.mainKey)&&Array.isArray(T==null?void 0:T.menus)&&(T==null?void 0:T.menus.length)>0&&(T!=null&&T.value)&&(T==null?void 0:T.value)!==""){let Ne=T!=null&&T.relatedContents&&((be=T==null?void 0:T.relatedContents)==null?void 0:be.length)>0?(Va=T==null?void 0:T.relatedContents)==null?void 0:Va.find(Q=>{var je,ha,B,za;return(Q==null?void 0:Q[(za=(je=T==null?void 0:T.prop)==null?void 0:je.split("."))==null?void 0:za[((B=(ha=T==null?void 0:T.prop)==null?void 0:ha.split("."))==null?void 0:B.length)-1]])===(T==null?void 0:T.value)}):await Es(T);if(Ne){const Q={...v};ie==null||ie.forEach(je=>{var ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl,zl;(je==null?void 0:je.prop)!==(T==null?void 0:T.prop)&&(T!=null&&T.relatedContents&&((ha=T==null?void 0:T.relatedContents)==null?void 0:ha.length)>0?(B=je==null?void 0:je.prop)!=null&&B.includes(".")&&((Ua=(za=je==null?void 0:je.prop)==null?void 0:za.split("."))==null?void 0:Ua[0])===((Ga=(sl=T==null?void 0:T.prop)==null?void 0:sl.split("."))==null?void 0:Ga[0])?Q[je.prop]=Ne[(qa=(Da=je==null?void 0:je.prop)==null?void 0:Da.split("."))==null?void 0:qa[((Wl=(dl=je==null?void 0:je.prop)==null?void 0:dl.split("."))==null?void 0:Wl.length)-1]]??Q[je.prop]:Q[je.prop]=(Ne==null?void 0:Ne[je.prop])??Q[je.prop]:le.same((T==null?void 0:T.menus)??[],(je==null?void 0:je.menus)??[])&&le.same((T==null?void 0:T.groups)??[],(je==null?void 0:je.groups)??[])&&!le.same((T==null?void 0:T.words)??[],(je==null?void 0:je.words)??[])?(Tl=je==null?void 0:je.prop)!=null&&Tl.includes(".")&&((Ll=(La=je==null?void 0:je.prop)==null?void 0:La.split("."))==null?void 0:Ll[0])!==((vl=(nl=T==null?void 0:T.prop)==null?void 0:nl.split("."))==null?void 0:vl[0])||(Q[je.prop]=(Ne==null?void 0:Ne[(zl=je==null?void 0:je.words)==null?void 0:zl.join(".")])??(Ne==null?void 0:Ne[je.prop])??Q[je.prop]):(!(je!=null&&je.isMainPath)&&le.same((T==null?void 0:T.bindMenus)??[],(je==null?void 0:je.bindMenus)??[]),Q[je.prop]=(Ne==null?void 0:Ne[je.prop])??Q[je.prop]))}),Ce.value=(ba=M.cloneDeep(Ce.value))==null?void 0:ba.map(je=>(je==null?void 0:je.id)===(v==null?void 0:v.id)?{...Q,id:je==null?void 0:je.id}:je)}}if((Ya=T==null?void 0:T.optionUrl)!=null&&Ya.menuSelect){let Ne="";ie==null||ie.forEach(ha=>{var B,za,Ua,sl,Ga;Ne===""&&((Ua=(za=(B=ha==null?void 0:ha.optionUrl)==null?void 0:B.groupSelect)==null?void 0:za[1])!=null&&Ua.includes("["))&&(Ne=(Ga=(sl=ha==null?void 0:ha.optionUrl)==null?void 0:sl.groupSelect)==null?void 0:Ga[1])});let Q=await Nt(T),je;if(Q==null||Q.forEach(ha=>{var B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl;Ne===((za=(B=T==null?void 0:T.optionUrl)==null?void 0:B.groupSelect)==null?void 0:za[1])&&((Ga=(sl=(Ua=T==null?void 0:T.optionUrl)==null?void 0:Ua.groupSelect)==null?void 0:sl[1])!=null&&Ga.includes("["))&&((Tl=M.cloneDeep(ha))==null?void 0:Tl[(qa=(Wl=(dl=(Da=T==null?void 0:T.optionUrl)==null?void 0:Da.groupSelect)==null?void 0:dl[1])==null?void 0:Wl.replaceAll("[",""))==null?void 0:qa.replaceAll("]","")])===(T==null?void 0:T.value)&&(je=ha)}),je){const ha={...v};ie==null||ie.forEach(B=>{var za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll;(je!=null&&je[B==null?void 0:B.label]||je!=null&&je[(Ga=(sl=(Ua=(za=B==null?void 0:B.optionUrl)==null?void 0:za.groupSelect)==null?void 0:Ua[1])==null?void 0:sl.replaceAll("[",""))==null?void 0:Ga.replaceAll("]","")])&&((Wl=(dl=(Da=B==null?void 0:B.optionUrl)==null?void 0:Da.groupSelect)==null?void 0:dl[1])!=null&&Wl.includes("["))&&(ha[B.prop]=(je==null?void 0:je[B==null?void 0:B.label])||(je==null?void 0:je[(Ll=(La=(Tl=(qa=B==null?void 0:B.optionUrl)==null?void 0:qa.groupSelect)==null?void 0:Tl[1])==null?void 0:La.replaceAll("[",""))==null?void 0:Ll.replaceAll("]","")]))}),Ce.value=(Ia=M.cloneDeep(Ce.value))==null?void 0:Ia.map(B=>(B==null?void 0:B.id)===(v==null?void 0:v.id)?{...ha,id:B==null?void 0:B.id}:B)}}},Ru=async f=>{var ea,ka,Na,Aa,la,ol,xa,tl,be,Va,ba,Ya,Ia,Ne;if(!f)return;const v=M.cloneDeep(Yl.value||{});Yl.value=f;const z=Hi(v),L=Hi(Yl.value);if(L&&L!==z&&await ht(L,fa.value||void 0)){Ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择"),po.forEach(je=>{if(Object.prototype.hasOwnProperty.call(Yl.value||{},je)||Object.prototype.hasOwnProperty.call(v||{},je)){const ha=(v==null?void 0:v[je])??"";Yl.value[je]=ha,f[je]=ha}}),ye.value=(ye.value||[]).map(je=>{if(!(je!=null&&je.prop)||!po.includes(je.prop))return je;const ha=(v==null?void 0:v[je.prop])??"";return{...je,value:ha,selectValue:ha===""?[]:[ha]}});return}let H=M.cloneDeep(d.itemData);H==null||H.map(Q=>{var je,ha,B,za;return(Q==null?void 0:Q.key)==="header"&&(Array.isArray((je=Q.contents)==null?void 0:je[0])?Q.contents=(B=le.getColumnChild((ha=Q.contents)==null?void 0:ha[0]))==null?void 0:B.map((Ua,sl)=>{var Ga,Da,dl,Wl,qa,Tl;return((dl=(Da=(Ga=ye.value)==null?void 0:Ga.find(La=>(La==null?void 0:La.prop)===(Ua==null?void 0:Ua.prop)))==null?void 0:Da.optionUrl)==null?void 0:dl.multiple)===!0&&!Array.isArray((Wl=Object.values(f))==null?void 0:Wl[sl])?Ua.value=[(qa=Object.values(f))==null?void 0:qa[sl]]:Ua.value=(Tl=Object.values(f))==null?void 0:Tl[sl],Ua}):Q.contents=(za=Q.contents)==null?void 0:za.map((Ua,sl)=>{var Ga,Da,dl,Wl,qa,Tl;return((dl=(Da=(Ga=ye.value)==null?void 0:Ga.find(La=>(La==null?void 0:La.prop)===(Ua==null?void 0:Ua.prop)))==null?void 0:Da.optionUrl)==null?void 0:dl.multiple)===!0&&!Array.isArray((Wl=Object.values(f))==null?void 0:Wl[sl])?Ua.value=[(qa=Object.values(f))==null?void 0:qa[sl]]:Ua.value=(Tl=Object.values(f))==null?void 0:Tl[sl],Ua})),Q});let T=ye.value,ie=(ea=H==null?void 0:H.find(Q=>(Q==null?void 0:Q.key)==="header"))==null?void 0:ea.contents;if(Tr.value||(T=T==null?void 0:T.map(Q=>{var je;return Q.value=Q.value??((je=ie==null?void 0:ie.find((ha,B)=>(ha==null?void 0:ha.prop)===(Q==null?void 0:Q.name)))==null?void 0:je.value),Q})),!gn.value)return;let oe=M.cloneDeep(Tr.value);(ka=Tr.value)!=null&&ka.includes("·")&&(Tr.value=(Aa=(Na=Tr.value)==null?void 0:Na.split("·"))==null?void 0:Aa[0]);let K=(ol=(la=H==null?void 0:H.find(Q=>(Q==null?void 0:Q.key)==="header"))==null?void 0:la.contents)==null?void 0:ol.find((Q,je)=>(Q==null?void 0:Q.prop)===Tr.value);(xa=ye==null?void 0:ye.value)==null||xa.forEach(Q=>{var je,ha,B,za,Ua,sl,Ga,Da,dl;(Q==null?void 0:Q.prop)===(K==null?void 0:K.prop)&&(Q!=null&&Q.endChildMenu)&&((je=K==null?void 0:K.prop)!=null&&je.includes(".")&&((B=(ha=K==null?void 0:K.prop)==null?void 0:ha.split("."))==null?void 0:B[0])!==((Ua=(za=Q==null?void 0:Q.prop)==null?void 0:za.split("."))==null?void 0:Ua[0])?K.endChildMenu=(Ga=(sl=Q==null?void 0:Q.value)==null?void 0:sl.split(" "))==null?void 0:Ga[0]:K.endChildMenu=(dl=(Da=Q==null?void 0:Q.endChildMenu)==null?void 0:Da.split(" "))==null?void 0:dl[0])});let ke=K!=null&&K.isMainPath&&(K!=null&&K.mainKey)?K==null?void 0:K.value:"",ge=T,Je=ae.value;if(Je!=null&&Je.find(Q=>(K==null?void 0:K.prop)===(Q==null?void 0:Q.key))&&(Je=Je==null?void 0:Je.filter(Q=>(K==null?void 0:K.prop)!==(Q==null?void 0:Q.key))),Je!=null&&Je.find(Q=>oe===(Q==null?void 0:Q.key))&&(Je=Je==null?void 0:Je.filter(Q=>oe!==(Q==null?void 0:Q.key))),(K==null?void 0:K.formType)==="Select"?ge=ge==null?void 0:ge.map(Q=>{var je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl;return(Q==null?void 0:Q.type)==="Select"&&(((je=Q==null?void 0:Q.allSelectionContents)==null?void 0:je.length)>0&&(Q.contactValue=f),((K==null?void 0:K.prop)===(Q==null?void 0:Q.prop)||oe===(Q==null?void 0:Q.prop))&&K&&(Array.isArray(K.value)&&((ha=K.value)==null?void 0:ha.length)>0&&((B=K.value)!=null&&B.every(zl=>typeof zl=="string"))?(Je.push({key:Q==null?void 0:Q.prop,value:[(Ua=K.value)==null?void 0:Ua[((za=K.value)==null?void 0:za.length)-1]]}),Q.selectValue=(sl=Je==null?void 0:Je.find(zl=>(zl==null?void 0:zl.key)===(Q==null?void 0:Q.prop)))==null?void 0:sl.value):Array.isArray(K.value)&&((Ga=K.value)==null?void 0:Ga.length)===0?(Je=[],Q.selectValue=[],f[Q==null?void 0:Q.prop]=""):Array.isArray(Q.value)&&Je.push({key:Q==null?void 0:Q.prop,value:[(Da=Q.value)==null?void 0:Da[(Q==null?void 0:Q.length)-1]]})),((Wl=Q==null?void 0:Q.menus)==null?void 0:Wl[((dl=Q==null?void 0:Q.menus)==null?void 0:dl.length)-1])===""&&(K!=null&&K.isMainPath)&&(K!=null&&K.mainKey)&&((qa=Q==null?void 0:Q.prop)!=null&&qa.includes(".")&&((La=(Tl=Q==null?void 0:Q.prop)==null?void 0:Tl.split("."))==null?void 0:La[0])!==((nl=(Ll=K==null?void 0:K.prop)==null?void 0:Ll.split("."))==null?void 0:nl[0])||(Q.endChildMenu=(vl=ke==null?void 0:ke.split(" "))==null?void 0:vl[0]))),Q.value=(f==null?void 0:f[Q==null?void 0:Q.prop])??(Q==null?void 0:Q.value),Q}):(K==null?void 0:K.formType)!=="Input"&&(ge=ge==null?void 0:ge.map(Q=>(Q.value=(f==null?void 0:f[Q==null?void 0:Q.prop])??(Q==null?void 0:Q.value),Q))),ae.value=Je,ge!=null&&ge.some(Q=>(Q==null?void 0:Q.functionName)&&(Q==null?void 0:Q.functionName)!=="")){let Q=await Tt([f],W==null?void 0:W.value,"Auto",Ce.value),je=[];(tl=ge==null?void 0:ge.filter(B=>(B==null?void 0:B.functionName)&&(B==null?void 0:B.functionName)!==""))==null||tl.forEach(B=>{var za;((za=B==null?void 0:B.functionRelatedWords)==null?void 0:za.length)>0&&(je=[...je,...B==null?void 0:B.functionRelatedWords])}),je=je==null?void 0:je.filter(B=>(B==null?void 0:B[0])!=="@");let ha=[];for(let B in Q==null?void 0:Q[0])je!=null&&je.find(za=>B===za||(B==null?void 0:B.includes("."+za)))&&ha.push(((be=Q==null?void 0:Q[0])==null?void 0:be[B])!=="");(Q==null?void 0:Q.length)>0&&ha.every(B=>B)&&(ge=ge==null?void 0:ge.map(B=>{var za;return B.value=((za=Q==null?void 0:Q[0])==null?void 0:za[B==null?void 0:B.prop])??B.value,B})),Yl.value=Q==null?void 0:Q[0]}if(ye.value=ge,K=Object.assign({},K??{},{relatedWords:(ba=(Va=ye==null?void 0:ye.value)==null?void 0:Va.find(Q=>(Q==null?void 0:Q.prop)===(K==null?void 0:K.prop)))==null?void 0:ba.relatedWords}),(K==null?void 0:K.mainKey)&&(K!=null&&K.value)&&(K==null?void 0:K.value)!==""){let Q=K!=null&&K.relatedContents&&((Ya=K==null?void 0:K.relatedContents)==null?void 0:Ya.length)>0?(Ia=K==null?void 0:K.relatedContents)==null?void 0:Ia.find(je=>{var ha,B,za,Ua;return(je==null?void 0:je[(Ua=(ha=K==null?void 0:K.prop)==null?void 0:ha.split("."))==null?void 0:Ua[((za=(B=K==null?void 0:K.prop)==null?void 0:B.split("."))==null?void 0:za.length)-1]])===(K==null?void 0:K.value)}):await Es(K);if(Q&&JSON.stringify(Q)!=="{}"){let je=ge;je=je==null?void 0:je.map(B=>{var za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl,zl,xl,Cr,hr,cr,_l,rr,mr;if((K==null?void 0:K.prop)===(B==null?void 0:B.prop))B.value=(Q==null?void 0:Q[(za=B==null?void 0:B.words)==null?void 0:za.join(".")])??(Q==null?void 0:Q[B==null?void 0:B.prop])??Q[(Da=(Ua=B==null?void 0:B.prop)==null?void 0:Ua.split("."))==null?void 0:Da[((Ga=(sl=B==null?void 0:B.prop)==null?void 0:sl.split("."))==null?void 0:Ga.length)-1]];else if(K!=null&&K.relatedContents&&((dl=K==null?void 0:K.relatedContents)==null?void 0:dl.length)>0)B.value=(Wl=B==null?void 0:B.prop)!=null&&Wl.includes(".")&&((Tl=(qa=B==null?void 0:B.prop)==null?void 0:qa.split("."))==null?void 0:Tl[0])===((Ll=(La=K==null?void 0:K.prop)==null?void 0:La.split("."))==null?void 0:Ll[0])?Q[(xl=(nl=B==null?void 0:B.prop)==null?void 0:nl.split("."))==null?void 0:xl[((zl=(vl=B==null?void 0:B.prop)==null?void 0:vl.split("."))==null?void 0:zl.length)-1]]:(Q==null?void 0:Q[B==null?void 0:B.prop])??(B==null?void 0:B.value);else if(le.same((K==null?void 0:K.menus)??[],(B==null?void 0:B.menus)??[])&&le.same((K==null?void 0:K.groups)??[],(B==null?void 0:B.groups)??[])&&!le.same((K==null?void 0:K.words)??[],(B==null?void 0:B.words)??[]))if((Cr=B==null?void 0:B.prop)!=null&&Cr.includes(".")&&((cr=(hr=B==null?void 0:B.prop)==null?void 0:hr.split("."))==null?void 0:cr[0])!==((rr=(_l=K==null?void 0:K.prop)==null?void 0:_l.split("."))==null?void 0:rr[0])){let Il=Object.keys(Q);Il=Il==null?void 0:Il.find(yr=>{var Dr;return yr==null?void 0:yr.includes("."+((Dr=B==null?void 0:B.words)==null?void 0:Dr.join(".")))}),B.value=(Q==null?void 0:Q[Il])??(Q==null?void 0:Q[B==null?void 0:B.prop])??B.value}else{let Il=Object.keys(Q);Il=Il==null?void 0:Il.find(yr=>{var Dr;return yr==null?void 0:yr.includes("."+((Dr=B==null?void 0:B.words)==null?void 0:Dr.join(".")))}),B.value=(Q==null?void 0:Q[(mr=B==null?void 0:B.words)==null?void 0:mr.join(".")])??(Q==null?void 0:Q[Il])??(Q==null?void 0:Q[B==null?void 0:B.prop])??B.value}else!(B!=null&&B.isMainPath)&&le.same((K==null?void 0:K.bindMenus)??[],(B==null?void 0:B.bindMenus)??[]),B.value=(Q==null?void 0:Q[B==null?void 0:B.prop])??B.value;return B}),ye.value=je;let ha={};(Ne=ye.value)==null||Ne.forEach(B=>{ha[B.prop]=B==null?void 0:B.value}),Yl.value=ha}}gn.value=!0,j.value=!1},$u=f=>f?(f==null?void 0:f.toUpperCase())==="INPUT"?"TEXTAREA":f:"TEXTAREA",Vu=f=>{var T,ie;const v=(ie=(T=na.value)==null?void 0:T.find(oe=>(oe==null?void 0:oe.label)===(f==null?void 0:f.label)))==null?void 0:ie.multiple,z=f==null?void 0:f.prop;if((f==null?void 0:f.formType)!="Select")return;Ce.value.forEach(oe=>{const K=oe==null?void 0:oe[z];v&&To.isString(K)&&(oe[z]=[K]),!v&&!To.isString(K)&&(oe[z]="")})},Gt=(f,v)=>{var z;return v==null||v.forEach(L=>{f[L==null?void 0:L.prop]=L==null?void 0:L.value}),f.children&&((z=f.children)==null?void 0:z.length)>0&&(f.children=f.children.map(L=>Gt(L,v))),f},vt=f=>{var z,L,H,T,ie,oe;ji("");const v=(z=ye.value)==null?void 0:z.reduce((K,ke)=>(K[ke.name]=ke.value,K),{});if(((L=Object.keys(v))==null?void 0:L.length)>0){Yl.value=v,fa.value="",sa.value=(H=Ce.value)==null?void 0:H.length,Ye.value=(T=Ee.value)==null?void 0:T.filter(ke=>(ke==null?void 0:ke.label)!=="新增");const K=(oe=(ie=ze.value)==null?void 0:ie.filter(ke=>(ke==null?void 0:ke.label)!=="操作"))==null?void 0:oe.map(ke=>{var Je,Ue,ea;const ge=(Ue=(Je=na.value)==null?void 0:Je.find(ka=>(ka==null?void 0:ka.label)===(ke==null?void 0:ke.label)))==null?void 0:Ue.multiple;return Vu(ke),{...ke,contents:(ke==null?void 0:ke.options)??[],optionUrl:ke!=null&&ke.formMenuSelect&&((ea=ke==null?void 0:ke.formMenuSelect)==null?void 0:ea.length)>0?{groupSelect:ke==null?void 0:ke.groupSelect,menuSelect:ke==null?void 0:ke.formMenuSelect,selectRelateType:"",type:ke==null?void 0:ke.formType,multiple:ge}:null}});W.value=K==null?void 0:K.map(ke=>Gt(ke,[{prop:"type",value:"edit"},{prop:"columnType",value:$u(ke==null?void 0:ke.formType)||(ke==null?void 0:ke.columnType)}])),f==="createClick"&&(ma.value="新增",Ui(!0))}},Ei={START:"开始时间",END:"结束时间",HOURS:"工时"},Fu=(f,v)=>Number(M.dayjs(v).diff(M.dayjs(f),"day",!0).toFixed(1)),Kt=f=>{var T;const v=d.itemData,z=(T=v==null?void 0:v.find(ie=>(ie==null?void 0:ie.key)==="header"))==null?void 0:T.contents,L=new Map;return z==null||z.forEach((ie,oe)=>{const{label:K}=ie;L.set(K,oe)}),!L.has(Ei.START)||!L.has(Ei.END)||!L.has(Ei.HOURS)?f:f==null?void 0:f.map(ie=>{const oe=ie==null?void 0:ie[Ei.START],K=ie==null?void 0:ie[Ei.END],ke=Fu(oe,K);return oe&&K&&(ie[Ei.HOURS]=`${ke}天`),ie})},Yt=(f,v,z=0)=>{if(z>((v==null?void 0:v.length)??""))return f;const L=v==null?void 0:v[z],H=new Map;for(const ie of f){const oe=ie[L];H.has(oe)||H.set(oe,[]),H.get(oe)&&H.get(oe).push(ie)}const T=[];for(const[ie,oe]of H){const[K,...ke]=oe,ge={...K};z+1===((v==null?void 0:v.length)??"")?ge.children=oe==null?void 0:oe.map(Je=>(Je.level=M.cloneDeep(z)+1,Je)).filter((Je,Ue)=>Ue!==0):ke.length>0&&(ge.children=Yt(ke,v,z+1)),ge.level=z,T.push(ge)}return T},Jt=(f,v,z)=>{var H;if(!(v!=null&&v.contents)||((H=v==null?void 0:v.contents)==null?void 0:H.length)===0)return f;let L=[];return L=Yt(f,v==null?void 0:v.contents,0),L},Xt=async(f,v)=>{var ol,xa,tl,be,Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll,nl,vl,zl,xl,Cr,hr,cr,_l,rr,mr,Il,yr,Dr,gr,Mr,tn,vr,Or,Fr,Qt,es,as,ls,rs,ns;const z=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="header");f==null||f.filter(ta=>(ta==null?void 0:ta.key)==="tableIndexColumn")[0];const L=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="childTree")[0];let H=!0;if((tl=(xa=(ol=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="filterAllType"))==null?void 0:ol.value)==null?void 0:xa.find(ta=>(ta==null?void 0:ta.value)==="onPamButtonContents"))!=null&&tl.content){let ta=(ba=(Va=(be=f==null?void 0:f.find(Al=>(Al==null?void 0:Al.key)==="filterAllType"))==null?void 0:be.value)==null?void 0:Va.find(Al=>(Al==null?void 0:Al.value)==="onPamButtonContents"))==null?void 0:ba.content;ta=(Ya=ta==null?void 0:ta.split(":"))==null?void 0:Ya[1],ta=(Ia=ta.slice(1,(ta==null?void 0:ta.length)-1))==null?void 0:Ia.split(","),H=!!(ta!=null&&ta.find(Al=>Al==="操作"))}const T=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="page"),ie=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="rowButton"),oe=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="extraButton"),K=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="tableContents"),ke=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="bottomButton");let ge=[],Je=(Ne=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="filter"))==null?void 0:Ne[0];Je=(Je==null?void 0:Je.contents)??"",Je=O0(Je),(Je==null?void 0:Je.length)>0&&(u.value=Je);const Ue=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="tableIndex");na.value=(je=(Q=f==null?void 0:f.filter(ta=>(ta==null?void 0:ta.key)==="tableToForm"))==null?void 0:Q[0])==null?void 0:je.contents,Pe.value=(T==null?void 0:T.contents)??!0;let ea=[];Ql.value===""?ea=z==null?void 0:z[0]:ea=(z==null?void 0:z.find(ta=>(ta==null?void 0:ta.selectLabel)==="("+Ql.value+")"))??(z==null?void 0:z.find(ta=>!(ta!=null&&ta.selectLabel)));let ka=[];Ql.value===""?ka=Ue==null?void 0:Ue[0]:ka=(Ue==null?void 0:Ue.find(ta=>(ta==null?void 0:ta.selectLabel)==="("+Ql.value+")"))??(Ue==null?void 0:Ue.find(ta=>!(ta!=null&&ta.selectLabel)));let Na=[],Aa=[];if(((ha=ea==null?void 0:ea.contents)==null?void 0:ha.length)>0){let ta=[],Al=ea==null?void 0:ea.contents;if(Array.isArray(Al==null?void 0:Al[0])&&((B=Al==null?void 0:Al[0])!=null&&B.every(Za=>!(Za!=null&&Za.children)))&&(Al=Al==null?void 0:Al[0]),Al.some(Za=>Array.isArray(Za)&&(Za==null?void 0:Za.find(Ze=>Ze.children))))ta=(za=le.getGradeColumns(Al,H))==null?void 0:za[0],ta!=null&&ta.find(Za=>(Za==null?void 0:Za.label)==="操作")||ta.push({label:"操作",prop:"operate",type:"operate"});else{let Za=Al.some(Ze=>Array.isArray(Ze))?Al==null?void 0:Al[0]:Al;Za!=null&&Za.find(Ze=>(Ze==null?void 0:Ze.label)==="操作")||Za.push({label:"操作",prop:"operate",type:"operate"}),Za==null||Za.forEach((Ze,br)=>{var Qr,on,qr,fi,Ci,Di,Lr,$n,ai,Ti,En,li,is,os,ts,ss,cs,us,ds,ps,fs;if((on=(Qr=de.value)==null?void 0:Qr.split("/"))==null||on.forEach(wr=>{var Ir,Un,hs;wr!==""&&((hs=(Un=(Ir=wr==null?void 0:wr.split(I+"updateLoading"))==null?void 0:Ir[0])==null?void 0:Un.split(I+"loading"))==null||hs[0])}),Ze!=null&&Ze.methodContent){let wr=(Ci=(fi=(qr=Ze==null?void 0:Ze.methodContent)==null?void 0:qr.replace("@","%%#"))==null?void 0:fi.split("%%#"))==null?void 0:Ci[1];if(wr=wr==null?void 0:wr.slice(0,(wr==null?void 0:wr.length)-1),wr=le.contentTransArrayToAllNoExtra(wr??"",","),(Di=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("@Button")))!=null&&Di.includes("Prop")&&((Lr=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("Type")))!=null&&Lr.includes("Manual"))){let Ir=(ai=($n=wr==null?void 0:wr.find(Un=>Un==null?void 0:Un.includes("@Button")))==null?void 0:$n.split(":"))==null?void 0:ai[1];Ir=((li=(En=(Ti=Ir==null?void 0:Ir.replaceAll("[",""))==null?void 0:Ti.replaceAll("]",""))==null?void 0:En.split(","))==null?void 0:li[1])??"算法执行",Na.push(Ir)}else if((is=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("@Button")))!=null&&is.includes("Row")&&((os=wr==null?void 0:wr.find(Ir=>Ir==null?void 0:Ir.includes("Type")))!=null&&os.includes("Manual"))){let Ir=(ss=(ts=wr==null?void 0:wr.find(Un=>Un==null?void 0:Un.includes("@Button")))==null?void 0:ts.split(":"))==null?void 0:ss[1];Ir=((ds=(us=(cs=Ir==null?void 0:Ir.replaceAll("[",""))==null?void 0:cs.replaceAll("]",""))==null?void 0:us.split(","))==null?void 0:ds[1])??"算法执行",Aa.push(Ir)}}(ps=na.value)==null||ps.find(wr=>(wr==null?void 0:wr.prop)===(Ze==null?void 0:Ze.prop));let cn=((fs=Ze==null?void 0:Ze.filter)==null?void 0:fs.includes("@EditRead=Read"))??!1;ta.push({label:(Ze==null?void 0:Ze.label)==="操作"?H?"操作":"":(Ze==null?void 0:Ze.label)??"",prop:(Ze==null?void 0:Ze.label)==="操作"?"operate":(Ze==null?void 0:Ze.prop)??"a"+br,width:Ze!=null&&Ze.width?parseInt(Ze.width):"",fixed:(Ze==null?void 0:Ze.fixed)??void 0,sortable:(Ze==null?void 0:Ze.sortable)??!1,filterable:(Ze==null?void 0:Ze.filterable)??!1,operable:(Ze==null?void 0:Ze.operable)??!1,showSummary:(Ze==null?void 0:Ze.showSummary)??!1,align:(Ze==null?void 0:Ze.align)??"left",showOverflowTooltip:(Ze==null?void 0:Ze.showOverflowTooltip)??!0,isNotDrag:(Ze==null?void 0:Ze.isNotDrag)??!1,isEditCol:(Ze==null?void 0:Ze.isEditCol)??!1,isOperate:(Ze==null?void 0:Ze.isOperate)??!1,id:(Ze==null?void 0:Ze.id)??br,type:(Ze==null?void 0:Ze.label)==="操作"?"operate":void 0,formType:(Ze==null?void 0:Ze.formType)??(Ze!=null&&Ze.groupSelect?"Select":""),disabled:Ze==null?void 0:Ze.disabled,options:(Ze==null?void 0:Ze.options)??[],value:(Ze==null?void 0:Ze.value)??"",isExistChild:(Ze==null?void 0:Ze.isExistChild)??!1,mainKey:(Ze==null?void 0:Ze.mainKey)??br===0,allSelectionContents:(Ze==null?void 0:Ze.allContents)??[],filterContent:Ze==null?void 0:Ze.filterContents,menus:Ze==null?void 0:Ze.menus,groups:Ze==null?void 0:Ze.groups,words:Ze==null?void 0:Ze.words,filter:Ze==null?void 0:Ze.filter,bindMenus:Ze==null?void 0:Ze.bindMenus,fatherPath:Ze==null?void 0:Ze.fatherPath,isMainPath:Ze==null?void 0:Ze.isMainPath,required:(Ze==null?void 0:Ze.required)??!1,relatedContents:Ze==null?void 0:Ze.relatedContents,functionName:Ze==null?void 0:Ze.functionName,functionRelatedWords:Ze==null?void 0:Ze.functionRelatedWords,calculatorFilter:Ze==null?void 0:Ze.calculatorFilter,relatedPages:Ze==null?void 0:Ze.relatedPages,multiple:(Ze==null?void 0:Ze.multiple)??!1,multipleLimit:Ze==null?void 0:Ze.multipleLimit,isReadonly:cn})})}ta=ta==null?void 0:ta.filter(Za=>{var Ze;return!((Ze=Za==null?void 0:Za.filter)!=null&&Ze.includes("@ShowHide=Hide"))}),O.value=(Ua=ke==null?void 0:ke[0])==null?void 0:Ua.contents;const sn=le.getNewColumnChild(ta);ge=le.getColumnChild(sn);const ei=Za=>Array.isArray(Za)?Za.map(Ze=>(Array.isArray(Ze==null?void 0:Ze.children)&&Ze.children.length>0?(Ze.sortable=!1,ei(Ze.children)):(Ze==null?void 0:Ze.prop)==="operate"||(Ze==null?void 0:Ze.label)==="操作"||(Ze==null?void 0:Ze.type)==="operate"||(Ze.sortable=!1),Ze)):Za;ei(sn),await Zo(sn),j0(Z.value,sn),W.value=sn,P.value=sn,r.value=(sl=W.value)==null?void 0:sl.map(Za=>Za==null?void 0:Za.label);let Pr=(Da=(Ga=le.getAllLeafNodes(W.value))==null?void 0:Ga.filter(Za=>(Za==null?void 0:Za.type)!=="operate"))==null?void 0:Da.map((Za,Ze)=>({prop:(Za==null?void 0:Za.prop)??"a"+Ze,column:Za.label}));lr.value=Pr;let Gr=[];Ql.value===""?Gr=K==null?void 0:K[0]:Gr=(K==null?void 0:K.find(Za=>(Za==null?void 0:Za.selectLabel)==="("+Ql.value+")"))??(K==null?void 0:K.find(Za=>!(Za!=null&&Za.selectLabel)));let jr=Array.isArray((dl=Gr==null?void 0:Gr.contents)==null?void 0:dl[0])&&((Wl=Gr==null?void 0:Gr.contents)!=null&&Wl[0].every(Za=>Array.isArray(Za)))?(qa=Gr==null?void 0:Gr.contents)==null?void 0:qa[0]:Gr==null?void 0:Gr.contents;ka!=null&&ka.contents&&((Tl=ka==null?void 0:ka.contents)==null?void 0:Tl.length)!==0&&(jr=(La=M.cloneDeep(jr))==null?void 0:La.map((Za,Ze)=>{if(!Array.isArray(Za)){let br={};for(let cn in Za)cn!=="id"&&cn!=="index"&&(br[cn]=Za[cn]);Za=Object.values(br)}return Za}));const ho=!!((Ll=W.value)!=null&&Ll.find(Za=>Za.prop==="index"));jr=Cc(jr,ka==null?void 0:ka.contents,ho);const Gn=[];jr==null||jr.forEach((Za,Ze)=>{var cn;let br={};if(Array.isArray(Za)){let Qr=[];Za==null||Za.filter(on=>!(on!=null&&on.id)).forEach((on,qr)=>{var fi,Ci,Di,Lr,$n,ai;if((fi=Pr==null?void 0:Pr[qr])!=null&&fi.prop&&!Array.isArray(on)){let Ti={};Ti[Pr[qr].column]=on,V!=null&&V.value&&((Ci=V==null?void 0:V.value)==null?void 0:Ci.length)>0&&((Di=V==null?void 0:V.value)!=null&&Di.find(En=>JSON.stringify(En==null?void 0:En[0])===JSON.stringify(Ti)))&&(Qr=(Lr=V==null?void 0:V.value)==null?void 0:Lr.find(En=>JSON.stringify(En==null?void 0:En[0])===JSON.stringify(Ti))),Qr&&Qr.length>0?br[Pr[qr].prop]=Qr!=null&&Qr.find(En=>{var li;return((li=Object.keys(En))==null?void 0:li[0])===Pr[qr].column})?($n=Qr==null?void 0:Qr.find(En=>{var li;return((li=Object.keys(En))==null?void 0:li[0])===Pr[qr].column}))==null?void 0:$n[Pr[qr].column]:on:br[Pr[qr].prop]=on}else Array.isArray(on)&&((ai=Pr[qr])!=null&&ai.prop?br[Pr[qr].prop]=on:br.children=Bt(on,Pr))})}else br=Za;if(Array.isArray(Za)&&Za.some(Qr=>Qr==null?void 0:Qr.id)){const Qr=(cn=Za==null?void 0:Za.find(on=>on.id))==null?void 0:cn.id;Gn.push(Object.assign(br,{id:to(Qr)}))}else br.id?Gn.push(br):Gn.push(Object.assign(br,{id:Ze.toString()}))});try{const Za=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),Ze=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null"),br=Za==null?void 0:Za.tableId,cn=Za==null?void 0:Za.compIndex;if(br&&Array.isArray(Ze)&&Ze.length>0&&String(br)===String(d==null?void 0:d.parentTableId)&&String(cn)===String(d==null?void 0:d.index)){const Qr=new Set(Gn.map(qr=>String(qr==null?void 0:qr.id))),on=Ze.filter(qr=>!Qr.has(String(qr)));if(on.length>0){const qr=Za==null?void 0:Za.pageKey,fi=qr!=null&&qr.startsWith("/")?qr.substring(1):qr;((v==null?void 0:v[qr])||(v==null?void 0:v[fi])||[]).filter(Lr=>{var $n,ai;return(($n=Lr==null?void 0:Lr.key)==null?void 0:$n.type)==="data"&&String((ai=Lr==null?void 0:Lr.key)==null?void 0:ai.tableId)===String(br)&&on.includes(Lr==null?void 0:Lr.id)}).forEach(Lr=>{var $n;Qr.has(String(Lr==null?void 0:Lr.id))||(Gn.push({id:Lr==null?void 0:Lr.id,...(($n=Lr==null?void 0:Lr.value)==null?void 0:$n.tableData)||{}}),Qr.add(String(Lr==null?void 0:Lr.id)))})}}}catch{}let Kn=null;try{const Za=`ocr_committed_temp_ids_v1:${String((d==null?void 0:d.parentTableId)??"")}:${String((d==null?void 0:d.index)??"")}`,Ze=JSON.parse(sessionStorage.getItem(Za)||"null");Array.isArray(Ze)&&Ze.length>0&&(Kn=new Set(Ze.map(br=>String(br))))}catch{}const qi=Array.from(((nl=Ta.value)==null?void 0:nl.values())||[]).filter(Za=>!(!(Za!=null&&Za._isOCRRow&&(Za==null?void 0:Za._ocrTableId)===(d==null?void 0:d.index))||Kn&&Kn.has(String(Za==null?void 0:Za.id)))),vo=(Ce.value||[]).map(Za=>String(Za==null?void 0:Za.id)),or=_i(Gn,vo);if(Ce.value=Jt(or,L,W.value),Fa.value=or,(vl=Fa.value)==null||vl.forEach(Za=>{var Ze;(Ze=Ta.value)==null||Ze.set(Za.id,Za)}),Kn&&Kn.size>0)try{const Za=new Set(Array.from(Kn.values()));Ce.value=(Ce.value||[]).filter(Ze=>!Za.has(String(Ze==null?void 0:Ze.id))),Fa.value=(Fa.value||[]).filter(Ze=>!Za.has(String(Ze==null?void 0:Ze.id))),Za.forEach(Ze=>{var br,cn;try{(cn=(br=Ta.value)==null?void 0:br.delete)==null||cn.call(br,Ze)}catch{}})}catch{}const Zr=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),mt=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null");if(Zr&&Array.isArray(mt)&&mt.length>0&&String(Zr==null?void 0:Zr.compIndex)===String(d==null?void 0:d.index)){const Za=new Set((Fa.value||[]).map(Ze=>String(Ze==null?void 0:Ze.id)));mt.filter(Ze=>!Za.has(String(Ze)))}if(qi.length>0){const Za=new Set((Ce.value||[]).map(br=>br==null?void 0:br.id)),Ze=qi.filter(br=>!Za.has(br.id));Ze.length>0&&(Ce.value=[...Ce.value||[],...Ze],Fa.value=[...Fa.value||[],...Ze],Ze.forEach(br=>{var cn;return(cn=Ta.value)==null?void 0:cn.set(br.id,br)}))}}else W.value=[],ze.value=[],Ce.value=[],Fa.value=[],Ta.value=new Map;if(Aa=[...new Set(Aa)],Aa=Aa==null?void 0:Aa.map(ta=>({label:ta,type:"methodButton"})),((zl=ie==null?void 0:ie.contents)==null?void 0:zl.length)>0?va.value=ie==null?void 0:ie.contents:va.value=[],va.value=[...va.value,...Aa],Na=[...new Set(Na)],Na=Na==null?void 0:Na.map(ta=>({label:ta,type:"methodButton"})),((xl=oe==null?void 0:oe.contents)==null?void 0:xl.length)>0)if((cr=(hr=(Cr=f==null?void 0:f.find(ta=>(ta==null?void 0:ta.key)==="filterAllType"))==null?void 0:Cr.value)==null?void 0:hr.find(ta=>(ta==null?void 0:ta.value)==="onButtonContents"))!=null&&cr.content){let ta=(mr=(rr=(_l=f==null?void 0:f.find(Al=>(Al==null?void 0:Al.key)==="filterAllType"))==null?void 0:_l.value)==null?void 0:rr.find(Al=>(Al==null?void 0:Al.value)==="onButtonContents"))==null?void 0:mr.content;if(ta=(Il=ta==null?void 0:ta.split(":"))==null?void 0:Il[1],ta=(yr=ta.slice(1,(ta==null?void 0:ta.length)-1))==null?void 0:yr.split(","),Ye.value=(Dr=oe==null?void 0:oe.contents)==null?void 0:Dr.filter(Al=>ta==null?void 0:ta.find(sn=>sn===(Al==null?void 0:Al.label))),Ee.value=(gr=oe==null?void 0:oe.contents)==null?void 0:gr.filter(Al=>ta==null?void 0:ta.find(sn=>sn===(Al==null?void 0:Al.label))),(Mr=oe==null?void 0:oe.contents)!=null&&Mr.some(Al=>(Al==null?void 0:Al.label)==="OCR识别")&&!((tn=Ye.value)!=null&&tn.some(Al=>(Al==null?void 0:Al.label)==="OCR识别"))){const Al=(vr=oe==null?void 0:oe.contents)==null?void 0:vr.find(sn=>(sn==null?void 0:sn.label)==="OCR识别");Ye.value=[...Ye.value,Al],Ee.value=[...Ee.value,Al]}A.value=!!(ta!=null&&ta.find(Al=>Al==="搜索")),re.value=!!(ta!=null&&ta.find(Al=>Al==="块状显示"))}else Ye.value=oe==null?void 0:oe.contents,Ee.value=oe==null?void 0:oe.contents;else Ye.value=[],Ee.value=[];if(Ye.value=[...Ye.value,...Na],Ee.value=[...Ee.value,...Na],typeof de.value=="string"&&de.value==="设备管理/试验设备"&&(d==null?void 0:d.compName)==="设备列表"?((Or=Ye.value)!=null&&Or.some(ta=>(ta==null?void 0:ta.label)==="OCR识别")||(Ye.value=[...Ye.value||[],{label:"OCR识别"}]),(Fr=Ee.value)!=null&&Fr.some(ta=>(ta==null?void 0:ta.label)==="OCR识别")||(Ee.value=[...Ee.value||[],{label:"OCR识别"}])):(Ye.value=(Ye.value||[]).filter(ta=>(ta==null?void 0:ta.label)!=="OCR识别"),Ee.value=(Ee.value||[]).filter(ta=>(ta==null?void 0:ta.label)!=="OCR识别")),(Qt=Ye.value)!=null&&Qt.some(ta=>(ta==null?void 0:ta.label)==="切换视图")||(Ye.value=[...Ye.value||[],{label:"切换视图"}]),(es=Ee.value)!=null&&es.some(ta=>(ta==null?void 0:ta.label)==="切换视图")||(Ee.value=[...Ee.value||[],{label:"切换视图"}]),ge!=null&&ge.some(ta=>{var Al;return(ta==null?void 0:ta.calculatorFilter)&&((Al=ta==null?void 0:ta.calculatorFilter)==null?void 0:Al.includes("@Button"))})){let ta=(as=ge==null?void 0:ge.filter(Pr=>{var Gr;return(Pr==null?void 0:Pr.calculatorFilter)&&((Gr=Pr==null?void 0:Pr.calculatorFilter)==null?void 0:Gr.includes("@Button"))}))==null?void 0:as.map(Pr=>Pr==null?void 0:Pr.calculatorFilter),Al=[],sn=[],ei=[];ta==null||ta.forEach(Pr=>{var ho,Gn,Kn,qi,vo;let Gr=(ho=le.analyzeSplitToContent(Pr,","))==null?void 0:ho.map(or=>((or==null?void 0:or[(or==null?void 0:or.length)-1])===","&&(or=or==null?void 0:or.slice(0,(or==null?void 0:or.length)-1)),or)),jr=Gr==null?void 0:Gr.find(or=>or==null?void 0:or.includes("@Button"));if(Gr!=null&&Gr.find(or=>or==null?void 0:or.includes("Manual"))){jr=(Kn=(Gn=jr==null?void 0:jr.replace("=","$R"))==null?void 0:Gn.split("$R"))==null?void 0:Kn[1],jr=jr==null?void 0:jr.slice(1,(jr==null?void 0:jr.length)-1);let or=(qi=le.analyzeSplitToContent(jr,","))==null?void 0:qi.map(Zr=>((Zr==null?void 0:Zr[(Zr==null?void 0:Zr.length)-1])===","&&(Zr=Zr==null?void 0:Zr.slice(0,(Zr==null?void 0:Zr.length)-1)),Zr));or=or==null?void 0:or[0],or=or==null?void 0:or.slice(1,(or==null?void 0:or.length)-1),or=(vo=or==null?void 0:or.split(","))==null?void 0:vo.map(Zr=>({label:Zr,prop:Zr})),jr!=null&&jr.includes("Up")?Al=[...Al,...or??[]]:jr!=null&&jr.includes("Line")?sn=[...sn,...or??[]]:ei=[...ei,...or??[]]}}),Ye.value=[...Al,...Ye.value??[]],va.value=[...sn,...va.value??[]],ei.value=[...ei,...ei.value??[]]}sa.value=((ls=Ce==null?void 0:Ce.value)==null?void 0:ls.length)??0,Kt(Ce.value),Sr.value=Ce.value,er.value&&(W.value=(ns=(rs=ze.value)==null?void 0:rs.filter(ta=>(ta==null?void 0:ta.label)!=="操作"))==null?void 0:ns.map(ta=>{var Al;return{...ta,type:"edit",optionUrl:ta!=null&&ta.formMenuSelect&&((Al=ta==null?void 0:ta.formMenuSelect)==null?void 0:Al.length)>0?{groupSelect:ta==null?void 0:ta.groupSelect,menuSelect:ta==null?void 0:ta.formMenuSelect,selectRelateType:"",type:ta==null?void 0:ta.formType}:null}}),vt())};e.watch(()=>[d.itemData,Ql.value,Xl.value,$l.value,V==null?void 0:V.value],async()=>{var f,v,z,L,H,T;if((f=d==null?void 0:d.itemData)!=null&&f.find(ie=>(ie==null?void 0:ie.key)==="columnPath")&&!((v=ce.value)!=null&&v.find(ie=>{var oe,K;return(ie==null?void 0:ie.key)===((K=(oe=d==null?void 0:d.itemData)==null?void 0:oe.find(ke=>(ke==null?void 0:ke.key)==="columnPath"))==null?void 0:K.contents)}))){let ie=ce.value,oe={key:(L=(z=d==null?void 0:d.itemData)==null?void 0:z.find(K=>(K==null?void 0:K.key)==="columnPath"))==null?void 0:L.contents,value:(T=(H=d==null?void 0:d.itemData)==null?void 0:H.find(K=>(K==null?void 0:K.key)==="columnUsingPath"))==null?void 0:T.contents};ie!=null&&ie.find(K=>(K==null?void 0:K.key)===(oe==null?void 0:oe.key))?ie=ie==null?void 0:ie.map(K=>((K==null?void 0:K.key)===(oe==null?void 0:oe.key)&&(K.value=oe.value),K)):ie.push(oe),Ge.setTableViewContents(ie)}await Xt(d.itemData,d.allMapContents)},{deep:!0,immediate:!0}),e.watch(()=>d==null?void 0:d.operatingForm,f=>{f!=null&&f.form&&(ji(f==null?void 0:f.form),ma.value=f==null?void 0:f.dialogTitle,Ae.value=!0,Qe.value=!0)},{immediate:!0,deep:!0});const Pu=()=>{var f;(f=q.value)!=null&&f.includes("read")&&(er.value=!er.value)},ju=()=>{Ur.value=!Ur.value};e.watch(()=>{var f;return(f=d==null?void 0:d.config)==null?void 0:f.viewport},f=>{var v;q.value=f,(f==null?void 0:f.length)===0?er.value=!1:(f!=null&&f.includes("read")||(er.value=!0),f!=null&&f.includes("edit")||(er.value=!1)),w.value=((v=d==null?void 0:d.config)==null?void 0:v.showIndex)||er.value},{immediate:!0}),e.watch(()=>er.value,f=>{var v;f?(vt("viewChange"),Ge.setCacheUpdatingData(null)):(Ye.value=Ee.value,W.value=P.value,ee.value&&(Ge.setTableLoading(d==null?void 0:d.index),U("change",ee.value))),w.value=f||((v=d==null?void 0:d.config)==null?void 0:v.showIndex),Br.value=[]},{immediate:!0}),e.watch(()=>{var f;return(f=Ln.value)==null?void 0:f.length},f=>{f===0&&(ue.currentPage=1)}),e.watch(()=>d==null?void 0:d.compNames,f=>{Y.contents=[{label:"列表名",prop:"groupName",name:"列表名",type:"select",value:"",id:0,contents:f||[],width:1}]},{immediate:!0}),e.ref(!1);const Hu=(f,v)=>{var z;vt("createClick"),v===ue.pageSize&&(ue.currentPage=Math.ceil(((z=Ce.value)==null?void 0:z.length)/ue.pageSize))},Uu=async(f,v,z)=>{var H,T,ie,oe,K;const L=(v==null?void 0:v.property)??(v==null?void 0:v.prop);if(L&&po.includes(L)&&z!==void 0&&z!==null&&String(z).trim()!==""){const ke=String(z).trim();if(await ht(ke,f==null?void 0:f.id)){Ja.ElMessage.warning("当前任务下通道号不能重复,请重新选择");const Je=(H=Ce.value)==null?void 0:H.findIndex(ea=>(ea==null?void 0:ea.id)===(f==null?void 0:f.id)),Ue=Je!==-1?(ie=(T=Ce.value)==null?void 0:T[Je])==null?void 0:ie[L]:void 0;L&&(f[L]=Ue??"");return}}if(er.value){const ke=f==null?void 0:f.id;ke!=null&&(p.value.has(ke)||p.value.set(ke,M.cloneDeep(f)),o.value.add(ke));const ge=(oe=Ce.value)==null?void 0:oe.findIndex(Je=>(Je==null?void 0:Je.id)===(f==null?void 0:f.id));ge!==-1&&L&&(Ce.value[ge]={...Ce.value[ge],[L]:z}),fo(z,f,v);return}fo(z,f,v),Yl.value=M.cloneDeep(f),fa.value=f==null?void 0:f.id,sa.value=(K=Ce.value)==null?void 0:K.length,ma.value=f!=null&&f._isTemp?"新增":"编辑",Ui(!1)},qu=async()=>{var f,v;try{const z=[];if(d!=null&&d.related&&Array.isArray(d.related)&&(console.log("props.related",d.related),d.related.forEach(L=>{if(typeof L=="string"&&L.includes("content_")){const H=L.split("_")[1];H&&(z.push(`content_${H}`),z.push(`struct_${H}`))}})),z.length===0&&(d!=null&&d.itemData)){const L=(v=(f=d.itemData)==null?void 0:f.find(H=>(H==null?void 0:H.key)==="contentTableId"))==null?void 0:v.contents;L&&(z.push(`content_${L}`),z.push(`struct_${L}`))}return z}catch(z){return console.error("获取 tableNames 失败:",z),[]}},Wu=async(f,v,z)=>{var T,ie;if(!z||typeof z!="string"||z.trim()===""){const oe=(v==null?void 0:v.property)??(v==null?void 0:v.prop),K=`${f==null?void 0:f.id}:${oe}`;m.value.delete(K),y.value.set(K,!1);return}const L=(v==null?void 0:v.property)??(v==null?void 0:v.prop),H=`${f==null?void 0:f.id}:${L}`;y.value.set(H,!0);try{const oe=await qu();if(oe.length===0){console.warn("未找到同名表,跳过全局搜索"),m.value.delete(H),y.value.set(H,!1);return}const K=parseInt((T=Nl.value)==null?void 0:T.plat_id);if(!K){console.warn("platId 无效,跳过全局搜索"),m.value.delete(H),y.value.set(H,!1);return}const ke=await M.getAllTables({platId:K,tableNames:oe??[]}),ge=((ie=ke==null?void 0:ke.data)==null?void 0:ie.result)||[],Je=[],Ue=[];for(let ea=0;ea<ge.length;ea+=2)ea+1<ge.length&&Ue.push([ge[ea],ge[ea+1]]);Ue.forEach(([ea,ka])=>{var tl;if(!Array.isArray(ea)||ea.length===0||!Array.isArray(ka)||ka.length===0)return;const Na=ka[0];let Aa=((tl=Na==null?void 0:Na.结构)==null?void 0:tl.contents)??[];if(!Array.isArray(Aa)||Aa.length===0)return;let la=M.cloneDeep(Aa);if(Array.isArray(la==null?void 0:la[0])&&(la=le.getColumnChild(la[0])),!Array.isArray(la)||la.length===0||!la.some(be=>(be==null?void 0:be.prop)===L))return;[...ea].sort((be,Va)=>{const ba=Number((be==null?void 0:be.update_time)??0);return Number((Va==null?void 0:Va.update_time)??0)-ba}).slice(0,20).forEach(be=>{const Va=be[L];if(Va!=null){const ba=String(Va);ba.toLowerCase().includes(z.toLowerCase())&&Je.findIndex(Ia=>{var Ne;return be.id&&((Ne=Ia.rowData)==null?void 0:Ne.id)===be.id?!0:Ia.label===ba})===-1&&Je.push({label:ba,rowData:M.cloneDeep(be),sourceTable:(Na==null?void 0:Na.source_table)||""})}})}),m.value.set(H,Je)}catch(oe){console.error("全局搜索建议失败:",oe),m.value.delete(H)}finally{y.value.set(H,!1)}},Gu=(f,v,z)=>{if(!er.value)return;const L=(v==null?void 0:v.property)??(v==null?void 0:v.prop),H=(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)||"";if(H&&H.toUpperCase()!=="INPUT"&&H!=="")return;const T=`${f==null?void 0:f.id}:${L}`;if(g.has(T)&&clearTimeout(g.get(T)),!z||z.trim()===""){m.value.delete(T),y.value.set(T,!1);return}const ie=setTimeout(()=>{Wu(f,{prop:L,property:L},z),g.delete(T)},300);g.set(T,ie)};function Ku(f,v){const z=`${f==null?void 0:f.id}:${(v==null?void 0:v.property)??(v==null?void 0:v.prop)}`;return m.value.get(z)||[]}const Yu=(f,v,z)=>{var ke;if(!z||!z.rowData)return;const L=z.rowData,H=f==null?void 0:f.id,T=(v==null?void 0:v.property)??(v==null?void 0:v.prop);(le.getAllLeafNodes(W.value)||[]).filter(ge=>(ge==null?void 0:ge.type)!=="operate"&&(ge==null?void 0:ge.label)!=="操作"&&(ge==null?void 0:ge.prop)!=="operate").forEach(ge=>{const Je=ge==null?void 0:ge.prop;Je&&L[Je]!==void 0&&(f[Je]=L[Je])}),(ke=Ce.value)==null||ke.findIndex(ge=>(ge==null?void 0:ge.id)===H),H!=null&&(p.value.has(H)||p.value.set(H,M.cloneDeep(f)),o.value.add(H));const K=`${H}:${T}`;m.value.delete(K),y.value.set(K,!1),fo(f[T],f,v)},pn=f=>{var K,ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol;const{row:v,column:z,item:L,slotData:H}=f;let T=v!=null&&v[z==null?void 0:z.prop]||(v==null?void 0:v[z==null?void 0:z.prop])===0?((ke=(K=v==null?void 0:v[z==null?void 0:z.prop])==null?void 0:K[0])==null?void 0:ke.contents)??((v==null?void 0:v[z==null?void 0:z.prop])===0?"0":v==null?void 0:v[z==null?void 0:z.prop]):((Je=(ge=v==null?void 0:v[L==null?void 0:L.prop])==null?void 0:ge[0])==null?void 0:Je.contents)??(v==null?void 0:v[L==null?void 0:L.prop])??((ea=(Ue=H==null?void 0:H[L==null?void 0:L.prop])==null?void 0:Ue[0])==null?void 0:ea.contents)??(H==null?void 0:H[L==null?void 0:L.prop])??((Aa=(Na=v==null?void 0:v[(ka=L==null?void 0:L.child)==null?void 0:ka.prop])==null?void 0:Na[0])==null?void 0:Aa.contents)??(v==null?void 0:v[(la=L==null?void 0:L.child)==null?void 0:la.prop]),oe=Array.isArray(T)&&!(T!=null&&T.every(xa=>typeof xa=="string"||typeof xa=="number"))?"查看":T;if(oe=Array.isArray(oe)?oe.join(","):oe,(z==null?void 0:z.formType)==="Date")if(!oe||oe===""||oe===null||oe===void 0)oe="";else{const xa=M.dayjs(oe,["YYYY-MM-DD","YYYY/MM/DD","YYYY年MM月DD日","YYYYMMDD"],!0);oe=xa.isValid()?xa.format("YYYYMMDD"):oe??""}return Array.isArray(z==null?void 0:z.relatedPages)&&((ol=z==null?void 0:z.relatedPages)==null?void 0:ol.length)>0&&(oe="详情页"),oe},Ju=f=>{var ke,ge,Je,Ue,ea,ka,Na,Aa,la,ol;const{row:v,column:z,item:L,slotData:H}=f;let T=v!=null&&v[z==null?void 0:z.prop]?((ge=(ke=v==null?void 0:v[z==null?void 0:z.prop])==null?void 0:ke[0])==null?void 0:ge.contents)??(v==null?void 0:v[z==null?void 0:z.prop]):((Ue=(Je=v==null?void 0:v[L==null?void 0:L.prop])==null?void 0:Je[0])==null?void 0:Ue.contents)??(v==null?void 0:v[L==null?void 0:L.prop])??((ka=(ea=H==null?void 0:H[L==null?void 0:L.prop])==null?void 0:ea[0])==null?void 0:ka.contents)??(H==null?void 0:H[L==null?void 0:L.prop])??((la=(Aa=v==null?void 0:v[(Na=L==null?void 0:L.child)==null?void 0:Na.prop])==null?void 0:Aa[0])==null?void 0:la.contents)??(v==null?void 0:v[(ol=L==null?void 0:L.child)==null?void 0:ol.prop]);const oe=Array.isArray(T)&&!(T!=null&&T.every(xa=>typeof xa=="string"||typeof xa=="number")),K=Array.isArray(T)&&(T==null?void 0:T.find(xa=>xa==null?void 0:xa.url));return oe&&K},Xu=f=>{var z,L,H,T;return f!=null&&f.column?(de.value,d==null||d.compName,((L=(z=f==null?void 0:f.column)==null?void 0:z.filter)==null?void 0:L.includes("@TextRGBA"))||((T=(H=f==null?void 0:f.column)==null?void 0:H.filter)==null?void 0:T.includes("@TextBackRGBA"))):!1},Zu=(f,v)=>f.find(z=>Object.values(z).some(L=>L===v));return e.watch(()=>Xe.value,async f=>{if(f){Le.setContentLoading(!0),await e.nextTick();const v=Zu(Ce.value,f==null?void 0:f.data);if(!v)return Le.setContentLoading(!1);await uo(f==null?void 0:f.data,null,v,{data:f==null?void 0:f.data}),Le.setContentLoading(!1)}},{deep:!0,immediate:!0}),e.watch(()=>d==null?void 0:d.cacheNewData,f=>{var v;f&&(Array.isArray(f)?f.forEach(z=>{var L,H,T,ie,oe;if(换,String(z==null?void 0:z.compId)===String(d==null?void 0:d.index)&&(z!=null&&z.resId)&&((L=z==null?void 0:z.data)!=null&&L.id)){const K=(H=z==null?void 0:z.data)==null?void 0:H.id,ke=z==null?void 0:z.resId;if(Ce.value=(T=Ce.value)==null?void 0:T.map(ge=>{if((ge==null?void 0:ge.id)===K){const Je={...ge,id:ke};return delete Je._isOCRRow,delete Je._ocrTableId,Je}return ge}),(oe=(ie=Ta.value)==null?void 0:ie.has)!=null&&oe.call(ie,K)){const Je={...Ta.value.get(K)||{},id:ke};delete Je._isOCRRow,delete Je._ocrTableId,Ta.value.delete(K),Ta.value.set(ke,Je)}Zl(d==null?void 0:d.index,K,ke)}}):String(f==null?void 0:f.compId)===String(d==null?void 0:d.index)&&(Ce.value=(v=Ce.value)==null?void 0:v.map(z=>{var L;if((z==null?void 0:z.id)===((L=f==null?void 0:f.data)==null?void 0:L.id)){const H={...z,id:f==null?void 0:f.resId};return delete H._isOCRRow,delete H._ocrTableId,H}return z})))},{immediate:!0,deep:!0}),(f,v)=>{var la,ol,xa,tl;const z=e.resolveComponent("svg-icon"),L=e.resolveComponent("el-popover"),H=e.resolveComponent("el-switch"),T=e.resolveComponent("el-checkbox"),ie=e.resolveComponent("el-radio"),oe=e.resolveComponent("el-radio-group"),K=e.resolveComponent("el-checkbox-group"),ke=e.resolveComponent("el-button"),ge=e.resolveComponent("el-icon"),Je=e.resolveComponent("el-progress"),Ue=e.resolveComponent("el-alert"),ea=e.resolveComponent("el-table-column"),ka=e.resolveComponent("el-table"),Na=e.resolveComponent("el-upload"),Aa=e.resolveComponent("el-text");return e.openBlock(),e.createElementBlock("div",A3,[Sn.value?(e.openBlock(),e.createBlock(pl.ssTable,{id:"excel-table",pageObj:ue,showIndex:w.value,isTree:(la=a.compItem)==null?void 0:la.isTree,summaryInfo:me,columns:W.value,defaultSort:ve,isCardViewport:Ur.value,checkedColumns:r.value,key:Jl.value+JSON.stringify(W.value),tableData:Ln.value,isEditViewport:er.value,isShowPagination:Pe.value,isShowEdit:!1,isShowDelete:!1,allowSelect:D.value,onDbClickRow:it,extraButton:Ye.value,rowButton:va.value,cacheExtraButtons:Ee.value,isClearSelection:((ol=Br.value)==null?void 0:ol.length)===0,onDoCurrentChange:jo,onDoSizeChange:Ho,onSortChange:Uo,onContentClick:uo,onRowClick:tt,onSelectChange:xi,onCellChange:Uu,onCellInput:Gu,onSelectSuggest:Yu,onChange:fo,onPreview:oo,onSubmitEditingTable:Pn,onHandleColEditChange:Wo,onHandleColTypeChange:Go,onClickButton:pt,onAddNewRow:Ko,bottomButton:O.value,allowRowAddOrDelete:nt.value},e.createSlots({headerButton:e.withCtx(be=>{var Va,ba,Ya,Ia;return[a.showHeader?(e.openBlock(),e.createBlock(a0,{key:0,id:"tableHeaderButton",pageLayout:a.pageLayout,lockingPage:e.unref(ia)===e.unref(de),filterValues:co.value,selectNums:(Va=Br.value)==null?void 0:Va.length,dataNums:(ba=Ce.value)==null?void 0:ba.length,compName:a.compName,isDevMode:a.isDevMode,buttons:be.buttons,menuFilter:(Ia=(Ya=a.compItem)==null?void 0:Ya.component)==null?void 0:Ia.menuFilter,onButtonClick:v[1]||(v[1]=(Ne,Q,je)=>pt(Ne,Q,{extra:je})),columns:W.value,onFilter:Pi,onGetImportData:un,level:a.level,filterShow:A.value},null,8,["pageLayout","lockingPage","filterValues","selectNums","dataNums","compName","isDevMode","buttons","menuFilter","columns","level","filterShow"])):e.createCommentVNode("",!0)]}),viewport:e.withCtx(()=>{var be,Va,ba,Ya;return[((be=Ce.value)==null?void 0:be.length)>0&&a.allowOperate&&re.value?(e.openBlock(),e.createElementBlock("div",I3,[(Va=q.value)!=null&&Va.includes("read")&&((ba=q.value)!=null&&ba.includes("edit"))&&((Ya=va.value)!=null&&Ya.some(Ia=>(Ia==null?void 0:Ia.label)==="编辑"))&&!Ur.value&&e.unref(ia)!==e.unref(de)?(e.openBlock(),e.createElementBlock("span",{key:0,title:"编辑表格",onClick:Pu},[e.createVNode(z,{name:"editTable",class:"view-icon"})])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]}),rowCreate:e.withCtx(({row:be,index:Va})=>[e.createElementVNode("span",{title:"新增",class:"row-create-wrap",onClick:ba=>Hu(be,Va)},[e.createVNode(z,{name:"rowCreate",style:{width:"10px",height:"10px"}})],8,O3)]),operateCol:e.withCtx(()=>[e.createVNode(L,{title:"选择显示列信息",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:Ou,onBeforeEnter:Lu},{reference:e.withCtx(()=>[e.createElementVNode("span",L3,[e.createVNode(z,{name:"operate",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",R3,[v[20]||(v[20]=e.createElementVNode("div",{class:"group-title"},"表格操作",-1)),e.createVNode(H,{"model-value":R.value,"active-text":"排序","inactive-text":"",style:{"margin-right":"8px"},onChange:v[2]||(v[2]=be=>Qo(be))},null,8,["model-value"]),v[21]||(v[21]=e.createElementVNode("div",{class:"group-title"},"表格列操作",-1)),e.createVNode(K,{modelValue:r.value,"onUpdate:modelValue":v[3]||(v[3]=be=>r.value=be),style:{height:"100%"},min:2,ref_key:"checkboxGroupRef",ref:i},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Qn.value,be=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:be.label},[e.createVNode(T,{value:be.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",{title:be.label,style:{display:"inline-block",width:"250px",overflow:"hidden","text-overflow":"ellipsis","white-space":"nowrap"}},e.toDisplayString(be.label),9,$3)]),_:2},1032,["value"]),e.createVNode(L,{"popper-class":"col-operate-popover",title:"列操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(z,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Va;return[e.createElementVNode("div",V3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Va=Object.keys(be))==null?void 0:Va.filter(ba=>{var Ya;return(Ya=_.value)==null?void 0:Ya.find(Ia=>(Ia==null?void 0:Ia.value)===ba)}),ba=>{var Ya,Ia;return e.openBlock(),e.createElementBlock("div",{key:ba},[E[ba]=="radio"?(e.openBlock(),e.createElementBlock("div",F3,[v[19]||(v[19]=e.createElementVNode("div",null,"固定:",-1)),e.createVNode(oe,{"model-value":be==null?void 0:be[ba],onChange:Ne=>Fi(Ne,ba,be)},{default:e.withCtx(()=>{var Ne,Q;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Q=(Ne=_.value)==null?void 0:Ne.find(je=>(je==null?void 0:je.value)===ba))==null?void 0:Q.options,je=>(e.openBlock(),e.createBlock(ie,{key:je==null?void 0:je.value,label:je==null?void 0:je.value,value:je==null?void 0:je.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(je==null?void 0:je.label),1)]),_:2},1032,["label","value"]))),128))]}),_:2},1032,["model-value","onChange"])])):e.createCommentVNode("",!0),E[ba]=="switch"?(e.openBlock(),e.createBlock(H,{key:1,"model-value":be==null?void 0:be[ba],"active-text":(Ia=(Ya=_.value)==null?void 0:Ya.find(Ne=>(Ne==null?void 0:Ne.value)===ba))==null?void 0:Ia.label,onChange:Ne=>Fi(Ne,ba,be)},null,8,["model-value","active-text","onChange"])):e.createCommentVNode("",!0)])}),128))])]}),_:2},1024),e.createElementVNode("span",P3,[e.createVNode(z,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:1},8,["modelValue"])])):e.createCommentVNode("",!0)]),_:1})]),content:e.withCtx(be=>{var Va,ba,Ya,Ia,Ne,Q,je,ha,B,za,Ua,sl,Ga,Da,dl,Wl,qa,Tl,La,Ll;return[((Va=be==null?void 0:be.column)==null?void 0:Va.label)==="证书附件"||((ba=be==null?void 0:be.column)==null?void 0:ba.prop)==="证书附件"?(e.openBlock(),e.createElementBlock("div",j3,[e.createVNode(z,{name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(nl=>Du(be),["stop"]),title:"查看OCR图片"},null,8,["onClick"])])):Ju(be)?(e.openBlock(),e.createBlock(L,{key:1,"popper-class":"file-popover",placement:"right",trigger:"hover",effect:"light",width:"auto"},{reference:e.withCtx(()=>[e.createElementVNode("span",H3,e.toDisplayString(pn(be)),1)]),default:e.withCtx(()=>{var nl,vl;return[e.createElementVNode("div",U3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((vl=be==null?void 0:be.row)==null?void 0:vl[(nl=be==null?void 0:be.column)==null?void 0:nl.prop],zl=>(e.openBlock(),e.createElementBlock("div",q3,[e.createElementVNode("div",{class:"prop-url",title:ci(zl),onClick:xl=>rt(zl)},e.toDisplayString(ci(zl)),9,W3),e.createElementVNode("div",{class:"prop-download",onClick:xl=>so(zl)}," 下载 ",8,G3)]))),256))])]}),_:2},1024)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[Xu(be)?(e.openBlock(),e.createBlock(sd,{key:0,value:pn(be),columnContent:be==null?void 0:be.column},null,8,["value","columnContent"])):(e.openBlock(),e.createElementBlock("div",{key:1,class:"table-cell-content",style:e.normalizeStyle({color:!Array.isArray(pn(be))&&((Ia=(Ya=pn(be))==null?void 0:Ya.toString())!=null&&Ia.includes(".txt")||(Q=(Ne=pn(be))==null?void 0:Ne.toString())!=null&&Q.includes(".cpt")||(ha=(je=pn(be))==null?void 0:je.toString())!=null&&ha.includes(".cyd"))?"var(--vertical-menuitem-active-bg)":"",textDecoration:!Array.isArray(pn(be))&&((za=(B=pn(be))==null?void 0:B.toString())!=null&&za.includes(".txt")||(sl=(Ua=pn(be))==null?void 0:Ua.toString())!=null&&sl.includes(".cpt")||(Da=(Ga=pn(be))==null?void 0:Ga.toString())!=null&&Da.includes(".cyd"))?"underline":"",cursor:!Array.isArray(pn(be))&&((Wl=(dl=pn(be))==null?void 0:dl.toString())!=null&&Wl.includes(".txt")||(Tl=(qa=pn(be))==null?void 0:qa.toString())!=null&&Tl.includes(".cpt")||(Ll=(La=pn(be))==null?void 0:La.toString())!=null&&Ll.includes(".cyd"))?"pointer":"",marginLeft:(be==null?void 0:be.colIndex)===0?`${((be==null?void 0:be.level)??0)*20}px`:0}),onClick:nl=>{var vl;return An(pn(be),((vl=be==null?void 0:be.column)==null?void 0:vl.relatedPages)??[])}},e.toDisplayString(pn(be)===0?"0":pn(be)),13,K3))],64))]}),_:2},[((xa=va.value)==null?void 0:xa.length)>0?{name:"actions",fn:e.withCtx(({item:be,fIndex:Va})=>[e.createVNode(L,{title:"",placement:"left-start","popper-class":"menu-operate-popover"},{reference:e.withCtx(()=>[e.createVNode(z,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"},onClick:v[0]||(v[0]=e.withModifiers(()=>{},["stop"]))})]),default:e.withCtx(()=>[e.createElementVNode("div",z3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(di(va.value,be),(ba,Ya)=>(e.openBlock(),e.createElementBlock("div",{class:"menu-config-item",key:Ya,onClick:e.withModifiers(Ia=>pt(ba==null?void 0:ba.label,be,{extra:ba}),["stop"])},[e.createElementVNode("div",{style:e.normalizeStyle({color:ba==null?void 0:ba.textColor}),class:"extra-button-label"},e.toDisplayString(ba==null?void 0:ba.label),5)],8,M3))),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),er.value?(e.openBlock(),e.createElementBlock("div",Y3,[e.createVNode(ke,{id:"themeBorderButton",onClick:Jo},{default:e.withCtx(()=>v[22]||(v[22]=[e.createTextVNode("取消")])),_:1,__:[22]}),e.createVNode(ke,{class:"ok-button",id:"themeButton",onClick:Vi},{default:e.withCtx(()=>v[23]||(v[23]=[e.createTextVNode("保存")])),_:1,__:[23]})])):e.createCommentVNode("",!0),e.createVNode($r.ssDialog,{title:ma.value,visible:Qe.value,width:Vr.value,onBeforeDestroy:et,style:{height:"74%"}},{default:e.withCtx(()=>[e.createElementVNode("div",J3,[e.createVNode(pl.ssForm,{ref_key:"formRef",ref:Oe,rowContents:ye.value,showOperator:!1,onChange:Ru,isEnableWrap:!1,layer:!0,onFixChangeValue:Hn,onClickTrigger:at,isEdit:ja.value,onBlurChange:Xo,onCreate:io,onTagChange:zr},null,8,["rowContents","isEdit"])])]),footer:e.withCtx(()=>[Ae.value?(e.openBlock(),e.createElementBlock("div",X3,[e.createVNode(ke,{onClick:v[4]||(v[4]=be=>Qe.value=!1),id:"themeBorderButton"},{default:e.withCtx(()=>v[24]||(v[24]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[24]}),e.createVNode(ke,{class:"ok-button",onClick:v[5]||(v[5]=be=>Ui(!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($r.ssDialog,{title:ma.value,visible:ne.value,width:We.value,onBeforeDestroy:v[7]||(v[7]=be=>ne.value=!1)},{default:e.withCtx(()=>[e.createVNode(v0)]),footer:e.withCtx(()=>[e.createElementVNode("div",Z3,[e.createVNode(ke,{onClick:v[6]||(v[6]=be=>ne.value=!1),class:"cancel-button",id:"themeBorderButton"},{default:e.withCtx(()=>v[26]||(v[26]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[26]}),e.createVNode(ke,{class:"ok-button",onClick:st,id:"themeButton"},{default:e.withCtx(()=>v[27]||(v[27]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[27]})])]),_:1},8,["title","visible","width"]),Ke.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:2,fileDataList:Me.value,onDestroy:ot},null,8,["fileDataList"])):e.createCommentVNode("",!0),te.value?(e.openBlock(),e.createBlock($r.ssDialog,{key:3,visible:te.value,onBeforeDestroy:Mu,style:{height:"80vh",width:"80vw"},"body-class":"three-dialog-body","footer-class":"three-dialog-footer"},{default:e.withCtx(()=>[e.createVNode(Do.ThreeViewerHost,{files:Be.value,threeData:se.value},null,8,["files","threeData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0),e.createVNode($r.ssDialog,{title:"OCR扫描录入",visible:Sl.value,"close-on-click-modal":!1,onBeforeDestroy:sr,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",Q3,[e.createElementVNode("div",eh,[e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:Ha.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:Ha.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:Ha.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)]),Ha.value===1?(e.openBlock(),e.createElementBlock("div",ah,[e.createVNode(ke,{onClick:C,class:"ocr-action-btn",disabled:dr.value,size:"default"},{default:e.withCtx(()=>v[33]||(v[33]=[e.createTextVNode("扫描文件 ")])),_:1,__:[33]},8,["disabled"]),e.createVNode(ke,{onClick:pi,class:"ocr-action-btn",disabled:dr.value,size:"default"},{default:e.withCtx(()=>v[34]||(v[34]=[e.createTextVNode("上传文件 ")])),_:1,__:[34]},8,["disabled"])])):e.createCommentVNode("",!0),Ha.value===1?(e.openBlock(),e.createElementBlock("div",lh,[e.createElementVNode("div",rh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ga.value,(be,Va)=>{var ba;return e.openBlock(),e.createElementBlock("div",{key:Va,class:"ocr-file-item"},[e.createElementVNode("div",nh,[be.raw&&((ba=be.raw.type)!=null&&ba.startsWith("image/"))?(e.openBlock(),e.createElementBlock("img",{key:0,src:dn(be),alt:"预览",class:"thumbnail-image"},null,8,ih)):(e.openBlock(),e.createElementBlock("div",oh,[e.createVNode(ge,{size:40},{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.document_default))]),_:1})])),e.createElementVNode("div",{class:e.normalizeClass(["file-progress-ring",{uploading:ar(be)==="uploading",processing:ar(be)==="processing",completed:ar(be)==="completed"||ar(be)==="uploaded",failed:ar(be)==="failed"}])},[(e.openBlock(),e.createElementBlock("svg",th,[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:ar(be)==="completed"||ar(be)==="uploaded",uploading:ar(be)==="uploading",processing:ar(be)==="processing",failed:ar(be)==="failed"}]),cx:"18",cy:"18",r:"16",fill:"none",stroke:ar(be)==="failed"?"#f56c6c":ar(be)==="completed"||ar(be)==="uploaded"?"#67c23a":"#409eff","stroke-width":ar(be)==="completed"||ar(be)==="uploaded"||ar(be)==="failed"?3:2,"stroke-dasharray":Rn(be),"stroke-dashoffset":"0","stroke-linecap":"round",transform:"rotate(-90 18 18)"},null,10,sh)])),ar(be)==="completed"||ar(be)==="uploaded"?(e.openBlock(),e.createElementBlock("div",ch,[e.createVNode(ge,{class:"check-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.check_default))]),_:1})])):e.createCommentVNode("",!0),ar(be)==="failed"?(e.openBlock(),e.createElementBlock("div",uh,[e.createVNode(ge,{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:Ya=>Bu(Va)},[e.createVNode(ge,null,{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.close_default))]),_:1})],8,dh)]),e.createElementVNode("div",ph,e.toDisplayString(be.name||"文件名123"),1)])}),128))]),ga.value.length>0?(e.openBlock(),e.createElementBlock("div",fh,[e.createVNode(ke,{onClick:cl,class:"ocr-start-recognize-btn",disabled:dr.value||ga.value.length===0,size:"default"},{default:e.withCtx(()=>v[36]||(v[36]=[e.createTextVNode("开始识别 ")])),_:1,__:[36]},8,["disabled"])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),Ha.value===1?(e.openBlock(),e.createElementBlock("div",hh,[e.createVNode(Je,{percentage:Te.value,"stroke-width":8},null,8,["percentage"])])):e.createCommentVNode("",!0),Ha.value===2?(e.openBlock(),e.createElementBlock("div",vh,[e.createElementVNode("div",mh,[e.createVNode(Ue,{title:"请核对识别结果。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",yh,[e.createVNode(ka,{data:Ka.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(ea,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(pe.value,be=>(e.openBlock(),e.createBlock(ea,{key:be.prop,prop:be.prop,"min-width":be.minWidth||230,"class-name":be.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",gh,[e.createElementVNode("span",null,e.toDisplayString(be.label),1)])]),default:e.withCtx(({row:Va,$index:ba})=>{var Ya,Ia,Ne;return[be.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:fr(Va[be.prop]),fontWeight:500})},e.toDisplayString(ir(Va[be.prop])),5)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[Xa.value!==ba?(e.openBlock(),e.createElementBlock("span",bh,e.toDisplayString(Va[be.prop]),1)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(Pa(be.prop)),{key:1,modelValue:Va[be.prop],"onUpdate:modelValue":Q=>Va[be.prop]=Q,size:"small",placeholder:"请输入"+be.label,content:((Ya=_a(be.prop))==null?void 0:Ya.contents)??((Ia=_a(be.prop))==null?void 0:Ia.options)??[],optionUrl:(Ne=_a(be.prop))==null?void 0:Ne.optionUrl,onChange:Q=>Vl(ba,be.prop,Q),onFocus:Q=>ua.value=be.prop,onBlur:v[8]||(v[8]=Q=>ua.value="")},null,40,["modelValue","onUpdate:modelValue","placeholder","content","optionUrl","onChange","onFocus"]))],64))]}),_:2},1032,["prop","min-width","class-name"]))),128)),e.createVNode(ea,{label:"编辑",width:"80",fixed:"right"},{default:e.withCtx(({$index:be})=>[Xa.value===be?(e.openBlock(),e.createBlock(ge,{key:0,class:"ocr-edit-icon editing",style:{"margin-left":"12px"},onClick:e.withModifiers(Va=>ql(be),["stop"])},{default:e.withCtx(()=>[e.createVNode(e.unref(Ja.check_default))]),_:2},1032,["onClick"])):(e.openBlock(),e.createBlock(z,{key:1,name:"edit_101",class:"ocr-edit-icon",onClick:e.withModifiers(Va=>ql(be),["stop"])},null,8,["onClick"]))]),_:1})]),_:1},8,["data"])])])):e.createCommentVNode("",!0),Ha.value===3?(e.openBlock(),e.createElementBlock("div",kh,[e.createVNode(ge,{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(Na,{ref:"ocrUploadRef","file-list":ga.value,"onUpdate:fileList":v[9]||(v[9]=be=>ga.value=be),multiple:"",action:"","auto-upload":!1,limit:20,accept:"image/*,application/pdf","on-change":rl,"show-file-list":!1,class:"ocr-upload-input",style:{display:"none"}},null,8,["file-list"])]),footer:e.withCtx(()=>[Ha.value!==3?(e.openBlock(),e.createElementBlock("div",xh,[e.createVNode(ke,{onClick:Eu,class:"ocr-start-recognize-btn",disabled:Ha.value===1||dr.value},{default:e.withCtx(()=>v[39]||(v[39]=[e.createTextVNode(" 上一步 ")])),_:1,__:[39]},8,["disabled"]),e.createVNode(ke,{onClick:Cu,class:"ocr-start-recognize-btn",disabled:dr.value},{default:e.withCtx(()=>v[40]||(v[40]=[e.createTextVNode(" 下一步 ")])),_:1,__:[40]},8,["disabled"])])):e.createCommentVNode("",!0)]),_:1},8,["visible"]),e.createVNode(M0,{visible:k.value,onConfirm:F,onCancel:v[10]||(v[10]=be=>k.value=!1)},null,8,["visible"]),e.createVNode(Hd,{visible:fl.value,"onUpdate:visible":v[11]||(v[11]=be=>fl.value=be),versions:Bl.value},null,8,["visible","versions"]),e.createVNode(Bd,{visible:wa.value,"onUpdate:visible":v[12]||(v[12]=be=>wa.value=be),images:Ba.value,"default-image-name":hl.value,"field-meta":Xa.value!==null?((tl=Ka.value[Xa.value])==null?void 0:tl.__ocrFieldMeta)||{}:{},"focused-field-name":ua.value,onClose:v[13]||(v[13]=be=>wa.value=!1),class:"ocr-img-preview-dialog"},null,8,["visible","images","default-image-name","field-meta","focused-field-name"]),e.createVNode(lp,{visible:Fe.value,"onUpdate:visible":v[14]||(v[14]=be=>Fe.value=be),candidates:bl.value,"name-prop":Oa.value,"mfr-prop":aa.value,columns:W.value,onSubmit:en,onPreviewFile:Tu},null,8,["visible","candidates","name-prop","mfr-prop","columns"]),e.createVNode(cp,{visible:oa.value,"onUpdate:visible":v[15]||(v[15]=be=>oa.value=be),ocrPreviewData:Ka.value,"onUpdate:ocrPreviewData":v[16]||(v[16]=be=>Ka.value=be),ocrSelectedFields:ca.value,"onUpdate:ocrSelectedFields":v[17]||(v[17]=be=>ca.value=be),ocrPreviewColumns:pe.value,onConfirm:El,onFieldChange:v[18]||(v[18]=({rowIndex:be,prop:Va,value:ba})=>Vl(be,Va,ba))},null,8,["visible","ocrPreviewData","ocrSelectedFields","ocrPreviewColumns"]),e.createVNode($r.ssDialog,{title:Y.title,visible:Y.show,width:Y.width,onBeforeDestroy:da},{default:e.withCtx(()=>[e.createElementVNode("div",wh,[e.createVNode(pl.ssForm,{rowContents:Y==null?void 0:Y.contents,formRules:Y==null?void 0:Y.formRules,showOperator:!1,buttonValue:Y.buttonValue,isEdit:ja.value,isStartJustify:!1,onOnButtonClick:Ma},null,8,["rowContents","formRules","buttonValue","isEdit"])])]),_:1},8,["title","visible","width"]),e.createVNode($r.ssDialog,{title:"",visible:J.show,width:J.width,alignCenter:!0,onBeforeDestroy:xe},{header:e.withCtx(()=>[e.createElementVNode("div",null,[e.createElementVNode("div",_h,e.toDisplayString(J.title),1),e.createVNode(Aa,{size:"small",type:"danger",style:{width:"100%"}},{default:e.withCtx(()=>v[41]||(v[41]=[e.createTextVNode(" (选择【覆盖】,可能会影响到原数据的引用关系;选择【跳过】将会放弃重复数据的导入。请谨慎操作!) ")])),_:1,__:[41]})])]),footer:e.withCtx(()=>[e.createElementVNode("div",Sh,[e.createVNode(Aa,{size:"small",style:{width:"100%","text-align":"left"},type:"info"},{default:e.withCtx(()=>[e.createTextVNode("引用模块:"+e.toDisplayString(rn.value||"暂无"),1)]),_:1}),e.createElementVNode("div",Eh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(J==null?void 0:J.buttonValue,be=>(e.openBlock(),e.createBlock(ke,{key:be==null?void 0:be.label,style:e.normalizeStyle({background:be==null?void 0:be.background,color:be==null?void 0:be.color}),onClick:Va=>Se(be==null?void 0:be.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(be==null?void 0:be.label),1)]),_:2},1032,["style","onClick"]))),128))])])]),default:e.withCtx(()=>[e.createVNode(l0,{columns:J==null?void 0:J.columns,tableData:J==null?void 0:J.tableData},{content:e.withCtx(({row:be,item:Va,slotData:ba,scope:Ya,column:Ia,columnProp:Ne,$index:Q})=>[e.createTextVNode(e.toDisplayString((be==null?void 0:be[Ia==null?void 0:Ia.prop])||(be==null?void 0:be[Ia==null?void 0:Ia.label])||(be==null?void 0:be[Ia==null?void 0:Ia.property])||(ba==null?void 0:ba[Ia==null?void 0:Ia.property])),1)]),_:1},8,["columns","tableData"])]),_:1},8,["visible","width"]),e.createVNode(pl.Signature,{signPadInfo:$a.value,onBeforeDestroy:wl,onClickSubmitSign:Qa},null,8,["signPadInfo"])])}}},Yc=pr._export_sfc(Dh,[["__scopeId","data-v-12c76af6"]]),Th={key:1,class:"static-form-body"},Bh=["onClick"],Nh=["src"],Ah={key:1},zh=["src"],Mh=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},backgroundPosition:{default:"Center"},iconUrl:{default:void 0},calculator:{default:()=>[]},textBackColor:{default:void 0}},emits:["update:backGroundImage"],setup(a,{emit:l}){const r=a,n=l,i=x=>{switch(x){case"占用":return"warning";case"注销":return"info";case"损坏":return"danger";case"可用":return"success";default:return""}},o=e.computed(()=>{var I;const x=(I=r.itemData)==null?void 0:I.find(R=>(R==null?void 0:R.key)==="formContent"),b=(x==null?void 0:x.contents)||[];return(r.fields&&r.fields.length>0?r.fields:b).filter(R=>(R==null?void 0:R.label)||(R==null?void 0:R.isHideInForm)).map(R=>{let re=R==null?void 0:R.value;Array.isArray(re)&&(re=re.map(U=>U==null?"":typeof U=="object"?U.label??U.value??U.name??JSON.stringify(U):String(U)).filter(Boolean).join(",")),re!=null&&typeof re=="object"&&(re=re.label??re.value??re.name??JSON.stringify(re));const X=R.isHideInForm?"":R.label??"",me=re==null||re===""?"-":String(re),ue=X==="使用状态";return{label:X,value:me,isStatus:ue,tagType:ue?i(me):"",width:R.width??1,field:R}})}),p=e.ref(null),c=e.ref(null),u=e.computed(()=>{const x=Number(r==null?void 0:r.textSize),b=le.rgbaToColor(r==null?void 0:r.textColor),S={},I={},R={},re={};return!Number.isNaN(x)&&x&&(S.fontSize=`${x}px`,I.fontSize=`${x+1}px`,R.fontSize=`${x}px`,re.fontSize=`${x}px`),b&&(I.color=b,R.color=b,re.color=b),{item:S,label:I,value:R,empty:re}}),m=e.ref(""),g=e.ref(""),y=e.ref(!1),d=async x=>{if(x){g.value&&(URL.revokeObjectURL(g.value),g.value="");try{const b=await M.platformDownloadFile({url:x}),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(()=>r==null?void 0:r.backGroundImage,x=>{x&&(m.value=x)},{immediate:!0}),e.watch(m,x=>{d(x)},{immediate:!0});const D=async()=>{var x,b;((x=r==null?void 0:r.calculator)==null?void 0:x.length)>0&&await $t(o.value,"Auto",[],r==null?void 0:r.calculator),(b=c.value)==null||b.click()},w=async x=>{var I,R,re;const b=x.target,S=(I=b==null?void 0:b.files)==null?void 0:I[0];if(!S){b.value="";return}y.value=!0;try{const X=new FormData;X.append("file",S);const me=await M.platformUploadFile(X),ue=(re=(R=me==null?void 0:me.data)==null?void 0:R.result)==null?void 0:re.url;ue?(m.value=ue,n("update:backGroundImage",ue),d(ue),Ja.ElMessage.success("背景图片上传成功")):Ja.ElMessage.error("背景图片上传失败")}catch{Ja.ElMessage.error("背景图片上传失败")}finally{y.value=!1,b.value=""}},q=e.computed(()=>{var x,b,S,I;return g.value||(r==null?void 0:r.backgroundUrl)!==""?{backgroundImage:`url("${(x=r==null?void 0:r.backgroundUrl)==null?void 0:x.replace(/\\/g,"/")}")`,backgroundPosition:`${((b=r==null?void 0:r.backgroundPosition)==null?void 0:b.toLowerCase())??"center"} center`,backgroundRepeat:"no-repeat",cursor:((S=r==null?void 0:r.calculator)==null?void 0:S.length)>0?"pointer":"auto"}:{cursor:((I=r==null?void 0:r.calculator)==null?void 0:I.length)>0?"pointer":"auto",background:r!=null&&r.textBackColor?le.rgbaToColor(r==null?void 0:r.textBackColor):void 0}}),A=x=>pl.getComponent(x),j=x=>{if(!x)return;const b=x.querySelector("input, textarea, .el-input__inner");b&&typeof b.focus=="function"&&b.focus()},O=(x,b,S)=>{r.disabled||(p.value=b,e.nextTick(()=>{j(S.currentTarget)}))},E=()=>{p.value=null},_=x=>{const b=x!=null&&x.width&&x.width>0?x.width:1,I=`calc((100% - ${(b-1)*48}px) / ${b})`;return{flex:`0 0 ${I}`,maxWidth:I,minWidth:"0",boxSizing:"border-box"}};return(x,b)=>{const S=e.resolveComponent("el-tag");return e.openBlock(),e.createElementBlock("div",{class:"static-form-card",style:e.normalizeStyle(q.value),onClick:b[1]||(b[1]=I=>D())},[(r==null?void 0:r.backGround)==="Yes"?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-backGround-upload",onClick:b[0]||(b[0]=e.withModifiers(I=>D(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:c,type:"file",accept:"image/*",style:{display:"none"},onChange:w},null,544),b[2]||(b[2]=e.createElementVNode("img",{src:pl._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),o.value.length?(e.openBlock(),e.createElementBlock("div",Th,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,(I,R)=>{var re,X,me,ue,U,W,Z,ae,ve;return e.openBlock(),e.createElementBlock("div",{key:R,class:"static-form-item",style:e.normalizeStyle({..._(I),...u.value.item})},[I.label&&!((re=I==null?void 0:I.field)!=null&&re.isHideInForm)?(e.openBlock(),e.createElementBlock("div",{key:0,class:"static-form-label",style:e.normalizeStyle(u.value.label)},e.toDisplayString(I.label)+": ",5)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"static-form-value",style:e.normalizeStyle(u.value.value),onClick:ze=>{var te;return(te=I.field)!=null&&te.isNoClick?null:O(I,R,ze)}},[x.iconUrl&&x.backgroundPosition==="Left"?(e.openBlock(),e.createElementBlock("img",{key:0,src:x.iconUrl,class:"bg-upload-icon"},null,8,Nh)):e.createCommentVNode("",!0),p.value===R&&I.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A(((X=I.field)==null?void 0:X.type)??"Input")),{key:1,modelValue:I.field.value,"onUpdate:modelValue":ze=>I.field.value=ze,isEdit:!0,disabled:(me=I.field)==null?void 0:me.disabled,content:((ue=I.field)==null?void 0:ue.contents)??[],optionUrl:I.field,originalValue:(U=I.field)==null?void 0:U.value,config:(W=I.field)==null?void 0:W.config,configModel:((Z=I.field)==null?void 0:Z.prop)??((ae=I.field)==null?void 0:ae.name),selectedTagList:((ve=I.field)==null?void 0:ve.selectValue)??[],onBlur:E,onBlurChange:E},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[I.isStatus?(e.openBlock(),e.createBlock(S,{key:0,type:I.tagType,size:"Default",effect:"plain"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(I.value??"-"),1)]),_:2},1032,["type"])):(e.openBlock(),e.createElementBlock("span",Ah,e.toDisplayString(I.value??"-"),1))],64)),x.iconUrl&&x.backgroundPosition==="Right"?(e.openBlock(),e.createElementBlock("img",{key:3,src:x.iconUrl,class:"bg-upload-icon"},null,8,zh)):e.createCommentVNode("",!0)],12,Bh)],4)}),128))])):(e.openBlock(),e.createElementBlock("div",{key:2,class:"static-form-empty",style:e.normalizeStyle(u.value.empty)}," 暂无数据 ",4))],4)}}}),Jc=pr._export_sfc(Mh,[["__scopeId","data-v-f6c4a15a"]]),Ih={class:"form-content"},Oh={title:"选择标签"},Lh={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},Rh={class:"col-operate-wrap"},$h={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},Vh={__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:()=>{}},calculator:{type:Array,default:()=>[]}},emits:["change","contentChange","routeUrl","clickTrigger"],setup(a,{emit:l}){const r=()=>{m.value=!1,g.value=!1,y.value=[]},n=a;e.computed(()=>{var na;const ne=(na=Me.value)==null?void 0:na.split("/");return(ne==null?void 0:ne.some(va=>(va==null?void 0:va.includes("updateLoading"))||(va==null?void 0:va.includes("loading"))))?!1:se.value==="view"});const i=l,o=e.ref(""),p=e.ref(""),c=e.ref("Center"),u=e.ref([]),m=e.ref(!1),g=e.ref(!1),y=e.ref([]),{getFileExtension:d}=Do.useThreeSystem(),D=e.ref(),w=e.ref(!1),q=e.ref(!1),A=M.useUnit(M.pinia),{chooseTitle:j}=M.storeToRefs(A),O=e.ref([]),E=e.ref(),_=e.ref(!1),x=e.ref([]),b=Ec(M.pinia),S=Vt(M.pinia),I=e.ref(!1),R=e.ref(),re=e.ref(),X=e.ref(),me=e.ref(),ue=e.ref(),U=e.ref(),W=M.useLoginState(M.pinia),{loginUserInfo:Z}=M.storeToRefs(W),ae=e.ref(),ve=e.ref(!0),ze=M.useModelComp(M.pinia),{tableViewContents:te,itemData:N,isEdit:se,routeToChildPath:G,lockingPage:fe,homepageBackgroundTableId:we,refreshCurrentPageInform:_e}=M.storeToRefs(ze),qe=e.ref(null),ra=e.ref(!1),P=e.ref(!1),Ke=M.useMenuState(),{activeMenuPath:Me}=M.storeToRefs(Ke),Le=le.useOriginalState(M.pinia),{originalPath:Ie}=M.storeToRefs(Le),{compType:de,hasEditable:De}=dc.useRole(),Xe=()=>!De(n.config,{type:de.FORM});e.computed(()=>Me.value==="设备管理/试验设备"&&n.compName==="设备概要");const Ea=async()=>{var na,va,Ae;const ne=we==null?void 0:we.value,We=(na=Z==null?void 0:Z.value)==null?void 0:na.plat_id;if(!(!ne||!We))try{const Be=await M.getAllTables({platId:parseInt(We),tableNames:[`content_${ne}`,`struct_${ne}`],user_unique_id:"0"}),Ye=((Ae=(va=Be==null?void 0:Be.data)==null?void 0:va.result)==null?void 0:Ae[0])??[],Ee=String((n==null?void 0:n.index)??""),ye=Ye==null?void 0:Ye.find($a=>String($a==null?void 0:$a.relatedForm_id)===Ee);ye!=null&&ye.backgroundImg_url&&(ue.value=ye.backgroundImg_url)}catch(Be){console.error("获取首页背景图片表数据失败:",Be)}},Ge=e.ref([]),$=e.ref([{label:"编辑",value:"operable",checked:!1},{label:"禁用",value:"disabled",checked:!1}]),V=async ne=>{P.value=ne,await ya("disabled",null,ne,!0)},ee=async ne=>{await ya("operable",null,ne,!0)};e.watch(()=>Me.value,async()=>{u.value=[],y.value=[]},{deep:!0,immediate:!0});const ce=()=>{e.nextTick(()=>{Ve()})},he=ne=>{var We;u.value=(We=u.value)==null?void 0:We.map(na=>({...na,isFormColHidden:!(ne!=null&&ne.includes(na.label))}))};e.onUnmounted(()=>{qe.value=null});const pa=ne=>{i("clickTrigger",ne)},ia=async ne=>{var We,na,va,Ae,Be,Ye;if(ne===""){let Ee="";(We=u.value)==null||We.forEach(Qa=>{Qa!=null&&Qa.isMain&&(Ee=Qa==null?void 0:Qa.value)});let ye=await le.getItemData(G.value,sessionStorage.getItem("systemKey"),"");Ee=((Ye=(Be=(Ae=(va=(na=ye==null?void 0:ye[0])==null?void 0:na.compData)==null?void 0:va.find(Qa=>(Qa==null?void 0:Qa.key)==="mainRouters"))==null?void 0:Ae.contents)==null?void 0:Be[0])==null?void 0:Ye.routerContent)+Ie.value+Ee;let wl=await le.getItemData(Ee,sessionStorage.getItem("systemKey"),"");_.value=!0,x.value=wl==null?void 0:wl.filter(Qa=>(Qa==null?void 0:Qa.comp)!=="methodButton"),i("routeUrl",x.value)}},Ve=()=>{var We;const ne=(We=qe.value)==null?void 0:We.$el;ne&&Fl.Sortable.create(ne,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:na=>{const{oldIndex:va,newIndex:Ae}=na;if(va===Ae)return;const Be=u.value.splice(va,1)[0];u.value.splice(Ae,0,Be)}})},ya=async(ne,We,na,va=!1)=>{try{ze.setRefreshCurStructure(!1)}catch{Ja.ElMessage.error("编辑处理失败")}},Ca=async(ne,We)=>{await ya()},Ce=async(ne,We)=>{ne&&await ya()},Fa=async(ne,We,na)=>{await ya(We,na,ne,!1)},Ta=(ne,We)=>{ae.value===We?ve.value=!1:ve.value=!0,ae.value=We==null?void 0:We.changeProp},fa=async ne=>{var Ye;ue.value=ne;const We=n.itemData,na=We==null?void 0:We.find(Ee=>(Ee==null?void 0:Ee.key)==="backGroundImage");na?na.contents=ne:We==null||We.push({key:"backGroundImage",contents:ne}),i("change",{key:"backGroundImage",contents:ne});const va=we==null?void 0:we.value,Ae=n==null?void 0:n.index,Be=(Ye=Z==null?void 0:Z.value)==null?void 0:Ye.plat_id;if(!(!va||!Be||!Ae||!ne))try{await M.pageBatchAddApi({platId:parseInt(Be),changeContents:[{tableName:`content_${va}`,tableContents:[{backgroundImg_url:ne,relatedForm_id:String(Ae)}]}],user_unique_id:"0"})}catch(Ee){console.error("保存背景图片记录失败:",Ee),Ja.ElMessage.error("背景图片记录保存失败")}},ja=async ne=>{var na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl;let We=[];if((na=ne==null?void 0:ne.toString())!=null&&na.includes(".urdf")){if(ne.includes(",")){Ja.ElMessage.error("当前版本仅允许单个urdf预览!");return}y.value=[{url:ne,extension:d(ne)}],g.value=!0,m.value=!0;return}if((va=ne==null?void 0:ne.toString())!=null&&va.includes(".stl")||(Ae=ne==null?void 0:ne.toString())!=null&&Ae.includes(".STL")||(Be=ne==null?void 0:ne.toString())!=null&&Be.includes(".obj")||(Ye=ne==null?void 0:ne.toString())!=null&&Ye.includes(".mtl")){const Gl=((Ee=ne==null?void 0:ne.toString())==null?void 0:Ee.split(",")).map(Kl=>({url:Kl,extension:d(Kl)}));y.value=Gl,g.value=!1,m.value=!0;return}if((ye=ne==null?void 0:ne.toString())!=null&&ye.includes(".stl")||($a=ne==null?void 0:ne.toString())!=null&&$a.includes(".STL")||(wl=ne==null?void 0:ne.toString())!=null&&wl.includes(".obj")||(Qa=ne==null?void 0:ne.toString())!=null&&Qa.includes(".mtl")){let Wa,Gl=[],Kl={};if(Array.isArray(ne)?Wa=ne:Wa=ne==null?void 0:ne.split(","),Wa==null||Wa.forEach(Zl=>{Zl.includes(".mtl")?Gl.push(Zl):Kl.blob=Kl.blob?Kl.blob+","+Zl:Zl}),(Gl==null?void 0:Gl.length)>0&&(Kl.mtlBlobs=Gl),(gl=(Pl=Object.values(Kl))==null?void 0:Pl[0])!=null&&gl.includes("http:"))We.push(Kl);else{const Zl=new Blob([Kl.blob],{type:"application/octet-stream;charset=UTF-8"});let Sl=URL.createObjectURL(Zl),dr="";(jl=ne==null?void 0:ne.split("/"))==null||jl.forEach((ga,il)=>{var fl;il===((fl=ne==null?void 0:ne.split("/"))==null?void 0:fl.length)-1&&(dr=ga)}),(al=Kl.blob)!=null&&al.includes(".stl")&&(dr=(dr==null?void 0:dr.replaceAll(">",""))+".urdf"),E.value=[{name:dr,blobUrl:Sl}],q.value=!0}}else{const Wa=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),Gl=await Ja.axios.get(ne,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{Wa.close()}),Kl=new Blob([Gl.data],{type:"application/octet-stream;charset=UTF-8"});let Zl=URL.createObjectURL(Kl),Sl="";(Hl=ne==null?void 0:ne.split("/"))==null||Hl.forEach((dr,ga)=>{var il;ga===((il=ne==null?void 0:ne.split("/"))==null?void 0:il.length)-1&&(Sl=dr)}),E.value=[{name:Sl,blobUrl:Zl}],q.value=!0}(We==null?void 0:We.length)>0&&S.setBlobUrls(We)},sa=()=>{q.value=!1},Pe=ne=>{var Be,Ye,Ee,ye;const We=(Ye=(Be=pl.safeClone(n.itemData))==null?void 0:Be.find($a=>($a==null?void 0:$a.key)==="formContent"))==null?void 0:Ye.contents,na=pl.safeClone(ne.content);let va={};na&&((Ee=Object.values(na))==null?void 0:Ee.length)>0&&((ye=Object.values(na))==null||ye.forEach(($a,wl)=>{va[We[wl].key]=$a}));const Ae={content:va,index:n==null?void 0:n.index,buttonName:ne==null?void 0:ne.buttonName};i("change",Ae)};e.computed(()=>"http://222.92.178.198:62001");const ma=async ne=>{var Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha;if(!ne)return;(gl=(Pl=n==null?void 0:n.itemData)==null?void 0:Pl.find(Sa=>(Sa==null?void 0:Sa.key)==="parentFormPath"))==null||gl.contents;let We=te.value;(We==null?void 0:We.length)>0&&(We=We==null?void 0:We.map(Sa=>{var Te,oa,Ka,pe;let ll=(Te=Sa==null?void 0:Sa.key)==null?void 0:Te.split("/");return(n==null?void 0:n.compName)===(ll==null?void 0:ll[0])&&(oa=u.value)!=null&&oa.find(_a=>(_a==null?void 0:_a.prop)===(ll==null?void 0:ll[1]))&&(Sa.value=(pe=(Ka=u.value)==null?void 0:Ka.find(_a=>(_a==null?void 0:_a.prop)===(ll==null?void 0:ll[1])))==null?void 0:pe.value),Sa}),ze.setTableViewContents(We));const na=pl.safeClone(n.itemData);let va=na==null?void 0:na.map(Sa=>{var ll;return(Sa==null?void 0:Sa.key)==="formContent"&&((ll=Sa.contents)==null||ll.map((Te,oa)=>{var Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe,bl,tr,xr,Ra,kl,Ml,Oa,aa;return Te.type=(pe=(Ka=u.value)==null?void 0:Ka.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:pe.type,Te.options=Te!=null&&Te.options?Te.options:((ul=(Pa=(_a=Te==null?void 0:Te.key)==null?void 0:_a.split("$"))==null?void 0:Pa[1])==null?void 0:ul.length)>0?(ua=(Xa=id((ca=(Ol=Te==null?void 0:Te.key)==null?void 0:Ol.split("$"))==null?void 0:ca[1]))==null?void 0:Xa.split(","))==null?void 0:ua.map(Rl=>({label:Rl,value:Rl})):[],(wa=Te==null?void 0:Te.key)!=null&&wa.includes("$")&&(Te.key=(hl=(Ba=Te==null?void 0:Te.key)==null?void 0:Ba.split("$"))==null?void 0:hl[0]),Te.signature=(bl=(Fe=u.value)==null?void 0:Fe.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:bl.signature,Te.isLoginUser=(xr=(tr=u.value)==null?void 0:tr.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:xr.isLoginUser,Te.value=(Ra=Object.values(ne))==null?void 0:Ra[oa],Te.isFormColHidden=(Ml=(kl=u.value)==null?void 0:kl.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:Ml.isFormColHidden,Te.isHideInForm=(aa=(Oa=u.value)==null?void 0:Oa.find(Rl=>(Rl==null?void 0:Rl.prop)===(Te==null?void 0:Te.prop)))==null?void 0:aa.isHideInForm,Te})),Sa}),Ae=u.value,Be=(al=(jl=pl.safeClone(va))==null?void 0:jl.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:al.contents;if(Ae=Ae==null?void 0:Ae.map(Sa=>{var ll,Te;return(Sa==null?void 0:Sa.type)==="Select"&&((ll=Sa==null?void 0:Sa.allSelectionContents)==null?void 0:ll.length)>0&&(Sa.contactValue=ne),Sa.value=(Te=Be==null?void 0:Be.find((oa,Ka)=>((oa==null?void 0:oa.id)??Ka)===(Sa==null?void 0:Sa.id)))==null?void 0:Te.value,Sa}),!ve.value){i("contentChange",{contents:va,index:n.index});return}let Ye="",Ee=(Gl=(Wa=(Hl=pl.safeClone(va))==null?void 0:Hl.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:Wa.contents)==null?void 0:Gl.find((Sa,ll)=>{var Te,oa,Ka;return(Sa==null?void 0:Sa.label)===ae.value||ll.toString()===((Ka=(oa=(Te=ae.value)==null?void 0:Te.split("t"))==null?void 0:oa[1])==null?void 0:Ka.toString())}),ye=(Kl=Ee==null?void 0:Ee.optionUrl)==null?void 0:Kl.menuSelect,$a=!0;if((dr=(Sl=(Zl=pl.safeClone(va))==null?void 0:Zl.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:Sl.contents)==null||dr.forEach(Sa=>{var ll,Te,oa,Ka,pe,_a;$a&&((oa=(Te=(ll=Sa==null?void 0:Sa.optionUrl)==null?void 0:ll.groupSelect)==null?void 0:Te[1])!=null&&oa.includes("["))&&(Ye=(pe=(Ka=Sa==null?void 0:Sa.optionUrl)==null?void 0:Ka.groupSelect)==null?void 0:pe[1],JSON.stringify(ye)===JSON.stringify((_a=Sa==null?void 0:Sa.optionUrl)==null?void 0:_a.menuSelect)&&($a=!1))}),(ga=Ee==null?void 0:Ee.optionUrl)!=null&&ga.menuSelect&&ve.value){let Sa=await Nt(Ee),ll,Te=(il=Ee==null?void 0:Ee.optionUrl)==null?void 0:il.menuSelect;if(Sa==null||Sa.forEach(oa=>{var Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa;Ye===((pe=(Ka=Ee==null?void 0:Ee.optionUrl)==null?void 0:Ka.groupSelect)==null?void 0:pe[1])&&((ul=(Pa=(_a=Ee==null?void 0:Ee.optionUrl)==null?void 0:_a.groupSelect)==null?void 0:Pa[1])!=null&&ul.includes("["))&&((wa=pl.safeClone(oa))==null?void 0:wa[(ua=(Xa=(ca=(Ol=Ee==null?void 0:Ee.optionUrl)==null?void 0:Ol.groupSelect)==null?void 0:ca[1])==null?void 0:Xa.replaceAll("[",""))==null?void 0:ua.replaceAll("]","")])===(Ee==null?void 0:Ee.value)&&(ll=oa)}),ll){let oa=pl.safeClone(Ae);oa=oa==null?void 0:oa.map(pe=>{var _a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe;return(ll!=null&&ll[pe==null?void 0:pe.label]||ll!=null&&ll[(Ol=(ul=(Pa=(_a=pe==null?void 0:pe.optionUrl)==null?void 0:_a.groupSelect)==null?void 0:Pa[1])==null?void 0:ul.replaceAll("[",""))==null?void 0:Ol.replaceAll("]","")])&&((ua=(Xa=(ca=pe==null?void 0:pe.optionUrl)==null?void 0:ca.groupSelect)==null?void 0:Xa[1])!=null&&ua.includes("["))&&Te!=null&&Te.every(bl=>{var tr,xr;return(xr=(tr=pe==null?void 0:pe.optionUrl)==null?void 0:tr.menuSelect)==null?void 0:xr.includes(bl)})&&(pe.value=(ll==null?void 0:ll[pe==null?void 0:pe.label])||(ll==null?void 0:ll[(Fe=(hl=(Ba=(wa=pe==null?void 0:pe.optionUrl)==null?void 0:wa.groupSelect)==null?void 0:Ba[1])==null?void 0:hl.replaceAll("[",""))==null?void 0:Fe.replaceAll("]","")]),Array.isArray(pe.value)&&pe.value.every(bl=>(bl==null?void 0:bl.url)&&(bl==null?void 0:bl.name))&&(pe.type="Upload")),pe}),oa=oa==null?void 0:oa.map(pe=>{var _a,Pa,ul;return(_a=pe==null?void 0:pe.optionUrl)!=null&&_a.oldMenuSelect&&(pe.optionUrl.menuSelect=(ul=(Pa=pl.safeClone(pe))==null?void 0:Pa.optionUrl)==null?void 0:ul.oldMenuSelect),pe}),u.value=pl.safeClone(oa);let Ka=pl.safeClone(oa);Ka=Ka==null?void 0:Ka.map(pe=>{var _a,Pa,ul,Ol,ca,Xa;return(Pa=(_a=pe==null?void 0:pe.optionUrl)==null?void 0:_a.menuSelect)!=null&&Pa.some(ua=>ua==null?void 0:ua.includes("["))&&(pe.optionUrl.oldMenuSelect=(Ol=(ul=pl.safeClone(pe))==null?void 0:ul.optionUrl)==null?void 0:Ol.menuSelect,pe.optionUrl.menuSelect=(Xa=(ca=pe==null?void 0:pe.optionUrl)==null?void 0:ca.menuSelect)==null?void 0:Xa.map(ua=>{var wa,Ba,hl,Fe;if(ua!=null&&ua.includes("[")){let bl=(Ba=(wa=ua==null?void 0:ua.replaceAll("[","").replaceAll("]",""))==null?void 0:wa.split(":"))==null?void 0:Ba[1];ua=(Fe=(hl=pl.safeClone(oa))==null?void 0:hl.find(tr=>(tr==null?void 0:tr.label)===bl))==null?void 0:Fe.value}return ua})),pe}),u.value=Ka}else u.value=Ae;va=va==null?void 0:va.map(oa=>{var Ka;return(oa==null?void 0:oa.key)==="formContent"&&(oa.contents=(Ka=oa.contents)==null?void 0:Ka.map(pe=>{var _a,Pa,ul,Ol;return pe.value=((Pa=(_a=u.value)==null?void 0:_a.find(ca=>(ca==null?void 0:ca.label)===(pe==null?void 0:pe.key)))==null?void 0:Pa.value)??(pe==null?void 0:pe.value),pe.type=((Ol=(ul=u.value)==null?void 0:ul.find(ca=>(ca==null?void 0:ca.prop)===(pe==null?void 0:pe.key)))==null?void 0:Ol.type)??(pe==null?void 0:pe.type),pe})),oa})}ve.value=!1,i("contentChange",{contents:va,index:n.index});let wl=[],Qa=[];if((Bl=pl.safeClone((fl=va==null?void 0:va.find(Sa=>(Sa==null?void 0:Sa.key)==="formContent"))==null?void 0:fl.contents))==null||Bl.forEach(Sa=>{var ll;Array.isArray(Sa==null?void 0:Sa.value)&&((ll=Sa==null?void 0:Sa.value)!=null&&ll.find(Te=>{var oa;return(oa=Te==null?void 0:Te.url)==null?void 0:oa.includes(".obj")}))&&(Qa=Sa==null?void 0:Sa.value)}),(Qa==null?void 0:Qa.length)>0){const Sa=(Ha=pl.safeClone(Qa))==null?void 0:Ha.filter(ll=>{var Te;return(Te=ll==null?void 0:ll.url)==null?void 0:Te.includes(".obj")});Sa==null||Sa.forEach(ll=>{var oa,Ka,pe,_a;const Te=(oa=Qa==null?void 0:Qa.filter(Pa=>{var ul;return(Pa==null?void 0:Pa.name)===(ll==null?void 0:ll.name)&&((ul=Pa==null?void 0:Pa.url)==null?void 0:ul.includes(".mtl"))}))==null?void 0:oa.map(Pa=>Pa==null?void 0:Pa.url);wl.push({objUrl:ll==null?void 0:ll.url,mtlUrls:((Ka=Qa==null?void 0:Qa.filter(Pa=>{var ul;return(Pa==null?void 0:Pa.name)===(ll==null?void 0:ll.name)&&((ul=Pa==null?void 0:Pa.url)==null?void 0:ul.includes(".mtl"))}))==null?void 0:Ka.length)===1?(_a=(pe=Qa==null?void 0:Qa.filter(Pa=>{var ul;return(Pa==null?void 0:Pa.name)===(ll==null?void 0:ll.name)&&((ul=Pa==null?void 0:Pa.url)==null?void 0:ul.includes(".mtl"))}))==null?void 0:pe[0])==null?void 0:_a.url:Te})}),S.setObjUrl(wl)}},Qe=(ne,We,na)=>{let va="";const Ae=We==null?void 0:We.map(Be=>{var Ye;return(Ye=Be==null?void 0:Be.value)==null?void 0:Ye.pageData});return Ae==null||Ae.forEach(Be=>{var Ye;(Be==null?void 0:Be.name)===(ne==null?void 0:ne[0])&&((Ye=Be==null?void 0:Be.compData)==null||Ye.forEach(Ee=>{var ye;(Ee==null?void 0:Ee.key)==="formContent"&&((ye=Ee==null?void 0:Ee.contents)==null||ye.forEach($a=>{var wl;($a==null?void 0:$a.prop)===(ne==null?void 0:ne[1])&&(va=($a==null?void 0:$a.value)===""?le.judgeContents((wl=pl.safeClone($a))==null?void 0:wl.optionUrl,na):$a==null?void 0:$a.value)}))}))}),va},Oe=(ne,We,na,va)=>{var Ee,ye;let Ae="",Be="";(Ee=pl.safeClone(We))==null||Ee.forEach(($a,wl)=>{$a!=null&&$a.includes("[")?Be=Be+Ie.value+ne[wl]:Be=Be===""?Be+$a:Be+"/"+$a});let Ye=(ye=va[Be])==null?void 0:ye.map($a=>{var wl;return(wl=$a==null?void 0:$a.value)==null?void 0:wl.pageData});return Ye==null||Ye.forEach($a=>{var wl;($a==null?void 0:$a.name)===(na==null?void 0:na[0])&&((wl=$a==null?void 0:$a.compData)==null||wl.forEach(Qa=>{var Pl;(Qa==null?void 0:Qa.key)==="formContent"&&((Pl=Qa==null?void 0:Qa.contents)==null||Pl.forEach(gl=>{(gl==null?void 0:gl.prop)===(na==null?void 0:na[1])&&(Ae=gl==null?void 0:gl.value)}))}))}),Ae};e.watch(()=>we==null?void 0:we.value,async()=>{await Ea()},{immediate:!0});const $e=async ne=>await $t(ne,"Auto");return e.watch(()=>_e.value,async()=>{var ne;(ne=u.value)!=null&&ne.some(We=>(We==null?void 0:We.functionName)&&(We==null?void 0:We.functionName)!=="")&&(u.value=await $e(u.value))},{immediate:!0,deep:!0}),e.watch(()=>n.itemData,async()=>{var jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha,Sa,ll,Te,oa,Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe,bl,tr,xr,Ra,kl,Ml;const ne=(jl=n.itemData)==null?void 0:jl.find(Oa=>(Oa==null?void 0:Oa.key)==="formContent");let We=(al=n.itemData)==null?void 0:al.find(Oa=>(Oa==null?void 0:Oa.key)==="backGround");We&&((Hl=We==null?void 0:We.contents)==null?void 0:Hl.length)>0&&(((Gl=(Wa=We==null?void 0:We.contents)==null?void 0:Wa[0])==null?void 0:Gl.fileType)==="Picture"&&(o.value=((Zl=(Kl=We==null?void 0:We.contents)==null?void 0:Kl[0])==null?void 0:Zl.url)??""),((dr=(Sl=We==null?void 0:We.contents)==null?void 0:Sl[0])==null?void 0:dr.fileType)==="Icon"&&(p.value=((il=(ga=We==null?void 0:We.contents)==null?void 0:ga[0])==null?void 0:il.url)??""),c.value=((Bl=(fl=We==null?void 0:We.contents)==null?void 0:fl[0])==null?void 0:Bl.position)??"");const na=(Ha=pl.safeClone(n.itemData))==null?void 0:Ha.find(Oa=>(Oa==null?void 0:Oa.key)==="formButton"),va=(Sa=pl.safeClone(n.itemData))==null?void 0:Sa.find(Oa=>(Oa==null?void 0:Oa.key)==="formFlex"),Ae=(ll=pl.safeClone(n.itemData))==null?void 0:ll.find(Oa=>(Oa==null?void 0:Oa.key)==="formWrap"),Be=(Te=pl.safeClone(n.itemData))==null?void 0:Te.find(Oa=>(Oa==null?void 0:Oa.key)==="enableWrap"),Ye=(oa=pl.safeClone(n.itemData))==null?void 0:oa.find(Oa=>(Oa==null?void 0:Oa.key)==="textSize"),Ee=(Ka=pl.safeClone(n.itemData))==null?void 0:Ka.find(Oa=>(Oa==null?void 0:Oa.key)==="textRGBA"),ye=(pe=pl.safeClone(n.itemData))==null?void 0:pe.find(Oa=>(Oa==null?void 0:Oa.key)==="textBackRGBA"),$a=(_a=pl.safeClone(n.itemData))==null?void 0:_a.find(Oa=>(Oa==null?void 0:Oa.key)==="backGround"),wl=(Pa=pl.safeClone(n.itemData))==null?void 0:Pa.find(Oa=>(Oa==null?void 0:Oa.key)==="backGroundImage");(Ae==null?void 0:Ae.contents)==="纵向"?w.value=!1:w.value=!0;const Qa=Number(Ye==null?void 0:Ye.contents);R.value=Number.isNaN(Qa)?void 0:Qa,re.value=Ee==null?void 0:Ee.contents,X.value=ye==null?void 0:ye.contents,me.value=$a==null?void 0:$a.contents,ue.value=wl==null?void 0:wl.contents;const Pl=Be==null?void 0:Be.contents;if(Pl===void 0?I.value=vi.BLOCK:typeof Pl=="boolean"?I.value=Pl?vi.ORDINARY:vi.BLOCK:I.value=Pl,U.value=typeof(va==null?void 0:va.contents)!="boolean"?!(!(va!=null&&va.contents)===""||((ul=va==null?void 0:va.contents)==null?void 0:ul.toUpperCase())==="VERTICAL"):va==null?void 0:va.contents,((Ol=ne==null?void 0:ne.contents)==null?void 0:Ol.length)>0&&Array.isArray(ne==null?void 0:ne.contents)){let Oa=n.allMapContents;const aa=(Xa=(ca=pl.safeClone(ne))==null?void 0:ca.contents)==null?void 0:Xa.map((Re,lr)=>{var Ur,Br,Tr,gn,Sn,Cn,mn,On,rn,Dn,Vn,nn,Fn;let Yl=(Re==null?void 0:Re.label)??(Re==null?void 0:Re.key)??"";Re==null||Re.type;let an=(Re==null?void 0:Re.options)??[];if((Ur=Re==null?void 0:Re.key)!=null&&Ur.includes("$")&&(Yl=(Br=pl.safeClone(Re==null?void 0:Re.key).split("$"))==null?void 0:Br[0],((gn=(Tr=pl.safeClone(Re==null?void 0:Re.key).split("$"))==null?void 0:Tr[1])==null?void 0:gn.length)>0)){const[zr,An]=(Cn=(Sn=pl.safeClone(Re==null?void 0:Re.key).split("$"))==null?void 0:Sn[1])==null?void 0:Cn.split(/[()]/);(mn=le.FormType.find(Tn=>(Tn==null?void 0:Tn.key)===zr))==null||mn.value,((On=An==null?void 0:An.split(","))==null?void 0:On.length)>0&&(an=(rn=An==null?void 0:An.split(","))==null?void 0:rn.map(Tn=>({label:Tn,value:Tn})))}let Sr=Re==null?void 0:Re.options;((Dn=Re==null?void 0:Re.optionUrl)==null?void 0:Dn.selectRelateType)==="自定义绑定"&&(Sr=(nn=(Vn=Re==null?void 0:Re.optionUrl)==null?void 0:Vn.defaultSelect)==null?void 0:nn.map(zr=>({label:zr,value:zr})));let Jl=(Re==null?void 0:Re.menuPath)??[],Er=(Re==null?void 0:Re.groups)??[],Xl=(Re==null?void 0:Re.columns)??[],$l=!1,nr=(Re==null?void 0:Re.isFormColHidden)??!1,Ql="",Ul=Re!=null&&Re.value?Re.value:(Sr==null?void 0:Sr.length)>0?(Fn=Sr==null?void 0:Sr[0])==null?void 0:Fn.value:(Re==null?void 0:Re.value)??"",Nl=!1,Vr="Input";return((Sr==null?void 0:Sr.length)>0||(Jl==null?void 0:Jl.length)>0)&&(Vr="Select"),(Array.isArray(Ql)&&(Ql!=null&&Ql.every(zr=>(zr==null?void 0:zr.name)&&(zr==null?void 0:zr.url)))||Array.isArray(Ul)&&(Ul!=null&&Ul.every(zr=>(zr==null?void 0:zr.name)&&(zr==null?void 0:zr.url))))&&(Vr="upload"),Re!=null&&Re.isMainUrl&&(Vr="Url"),{label:Yl??"",name:Yl??"t"+lr,prop:Yl??pl.safeClone(Re==null?void 0:Re.key),type:(Re==null?void 0:Re.type)??Vr,value:(Re==null?void 0:Re.type)==="Date"&&Ul===""?new Date:Ul,id:(Re==null?void 0:Re.id)??lr,contents:(Sr==null?void 0:Sr.length)>0?Sr:an??[],width:(Re==null?void 0:Re.width)??1,isLoginUser:$l,config:Re==null?void 0:Re.config,optionUrl:(Re==null?void 0:Re.optionUrl)??Re,isFormColHidden:nr,isHideInForm:(Re==null?void 0:Re.isHideInForm)??!1,signature:Nl,isMain:Re==null?void 0:Re.isMain,required:(Re==null?void 0:Re.required)??!1,isMainUrl:Re==null?void 0:Re.isMainUrl,operable:(Re==null?void 0:Re.operable)??!1,disabled:(Re==null?void 0:Re.disabled)??!1,isSync:Re==null?void 0:Re.isSync,menus:Jl,groups:Er,words:Xl,allSelectionContents:Re==null?void 0:Re.allContents,filterContent:Re==null?void 0:Re.filterContents,isNoClick:(Re==null?void 0:Re.isNoClick)??!1,functionName:Re==null?void 0:Re.functionName,functionRelatedWords:Re==null?void 0:Re.functionRelatedWords,calculatorFilter:Re==null?void 0:Re.calculatorFilter,filters:Re==null?void 0:Re.filters}}),Rl=aa==null?void 0:aa.map(Re=>Re==null?void 0:Re.value);let Yr="";Rl==null||Rl.forEach(Re=>{Re!==""&&Re!==void 0&&(Yr=Yr===""?Re:Yr+"/"+Re)}),b.setSelectArray(Rl),b.setSelectString(Yr);let Jr=(ua=pl.safeClone(aa))==null?void 0:ua.map(Re=>(Re!=null&&Re.value&&le.IsJson(Re==null?void 0:Re.value)&&Array.isArray(JSON.parse(Re==null?void 0:Re.value))&&(Re.value=JSON.parse(Re.value)),Re)),vn={};Jr==null||Jr.forEach(Re=>{vn[Re.label]=Re==null?void 0:Re.value}),Jr=Jr==null?void 0:Jr.map(Re=>{var lr,Yl,an,Sr,Jl,Er,Xl,$l,nr;if((Re==null?void 0:Re.type)==="Select"&&((lr=Re==null?void 0:Re.allSelectionContents)==null?void 0:lr.length)>0&&(Re.contactValue=vn),(an=(Yl=Re==null?void 0:Re.optionUrl)==null?void 0:Yl.menuSelect)!=null&&an.some(Ql=>Ql==null?void 0:Ql.includes("["))){let Ql="";Re.optionUrl.oldMenuSelect=(Jl=(Sr=pl.safeClone(Re))==null?void 0:Sr.optionUrl)==null?void 0:Jl.menuSelect,Re.optionUrl.menuSelect=(Xl=(Er=Re==null?void 0:Re.optionUrl)==null?void 0:Er.menuSelect)==null?void 0:Xl.map(Ul=>{var Nl,Vr,er,Ur,Br,Tr;if(Ul!=null&&Ul.includes("[")){let gn=(Vr=(Nl=Ul==null?void 0:Ul.replaceAll("[","").replaceAll("]",""))==null?void 0:Nl.split(":"))==null?void 0:Vr[1];Ql=Qe((er=Ul==null?void 0:Ul.replaceAll("[","").replaceAll("]",""))==null?void 0:er.split(":"),Oa==null?void 0:Oa[Me.value],Oa),Ul=((Br=(Ur=pl.safeClone(Jr))==null?void 0:Ur.find(Sn=>(Sn==null?void 0:Sn.label)===gn))==null?void 0:Br.value)||Qe((Tr=Ul==null?void 0:Ul.replaceAll("[","").replaceAll("]",""))==null?void 0:Tr.split(":"),Oa==null?void 0:Oa[Me.value],Oa)}return Ul}),Ql!==""&&Re.value===""&&(Re.value=Oe(Re.optionUrl.menuSelect,Re.optionUrl.oldMenuSelect,($l=Re==null?void 0:Re.optionUrl)==null?void 0:$l.groupSelect,Oa),Array.isArray(Re.value)&&((nr=Re.value)!=null&&nr.every(Ul=>Ul==null?void 0:Ul.url))&&(Re.type="UPLOAD"))}return Re}),u.value=Jr,P.value=((wa=u.value)==null?void 0:wa.every(Re=>Re==null?void 0:Re.disabled))||fe.value===Me.value,ra.value=(Ba=u.value)==null?void 0:Ba.every(Re=>Re==null?void 0:Re.operable),Ge.value=(hl=u.value)==null?void 0:hl.map(Re=>Re==null?void 0:Re.label);let en=[],Ar=[];if((Fe=pl.safeClone(u.value))==null||Fe.forEach(Re=>{var lr;Array.isArray(Re==null?void 0:Re.value)&&((lr=Re==null?void 0:Re.value)!=null&&lr.find(Yl=>{var an;return(an=Yl==null?void 0:Yl.url)==null?void 0:an.includes(".obj")}))&&(Ar=Re==null?void 0:Re.value)}),(Ar==null?void 0:Ar.length)>0){const Re=(bl=pl.safeClone(Ar))==null?void 0:bl.filter(lr=>{var Yl;return(Yl=lr==null?void 0:lr.url)==null?void 0:Yl.includes(".obj")});Re==null||Re.forEach(lr=>{var an,Sr,Jl,Er;const Yl=(an=Ar==null?void 0:Ar.filter(Xl=>{var $l;return(Xl==null?void 0:Xl.name)===(lr==null?void 0:lr.name)&&(($l=Xl==null?void 0:Xl.url)==null?void 0:$l.includes(".mtl"))}))==null?void 0:an.map(Xl=>Xl==null?void 0:Xl.url);en.push({objUrl:lr==null?void 0:lr.url,mtlUrls:((Sr=Ar==null?void 0:Ar.filter(Xl=>{var $l;return(Xl==null?void 0:Xl.name)===(lr==null?void 0:lr.name)&&(($l=Xl==null?void 0:Xl.url)==null?void 0:$l.includes(".mtl"))}))==null?void 0:Sr.length)===1?(Er=(Jl=Ar==null?void 0:Ar.filter(Xl=>{var $l;return(Xl==null?void 0:Xl.name)===(lr==null?void 0:lr.name)&&(($l=Xl==null?void 0:Xl.url)==null?void 0:$l.includes(".mtl"))}))==null?void 0:Jl[0])==null?void 0:Er.url:Yl})}),S.setObjUrl(en)}(tr=pl.safeClone(u.value))==null||tr.forEach(Re=>{var lr,Yl,an,Sr,Jl,Er,Xl,$l,nr,Ql,Ul,Nl,Vr;if((Yl=(lr=Re==null?void 0:Re.value)==null?void 0:lr.toString())!=null&&Yl.includes(".stl")||(Sr=(an=Re==null?void 0:Re.value)==null?void 0:an.toString())!=null&&Sr.includes(".STL")||(Er=(Jl=Re==null?void 0:Re.value)==null?void 0:Jl.toString())!=null&&Er.includes(".obj")||($l=(Xl=Re==null?void 0:Re.value)==null?void 0:Xl.toString())!=null&&$l.includes(".mtl")||(Ql=(nr=Re==null?void 0:Re.value)==null?void 0:nr.toString())!=null&&Ql.includes(".urdf")){let er={},Ur=[],Br;Array.isArray(Re==null?void 0:Re.value)?Br=Re==null?void 0:Re.value:Br=(Ul=Re==null?void 0:Re.value)==null?void 0:Ul.split(","),Br==null||Br.forEach(Tr=>{Tr.includes(".mtl")?Ur.push(Tr):er.blob=er.blob==="undefined"?Tr:er.blob+","+Tr}),(Ur==null?void 0:Ur.length)>0&&(er.mtlBlobs=Ur),(Vr=(Nl=Object.values(er))==null?void 0:Nl[0])!=null&&Vr.includes("http:")}})}else u.value=[];let gl=te.value;if((gl==null?void 0:gl.length)>0&&(gl=gl==null?void 0:gl.map(Oa=>{var Rl,Yr,Jr,vn;let aa=(Rl=Oa==null?void 0:Oa.key)==null?void 0:Rl.split("/");return(n==null?void 0:n.compName)===(aa==null?void 0:aa[0])&&(Yr=u.value)!=null&&Yr.find(en=>(en==null?void 0:en.prop)===(aa==null?void 0:aa[1]))&&(Oa.value=(vn=(Jr=u.value)==null?void 0:Jr.find(en=>(en==null?void 0:en.prop)===(aa==null?void 0:aa[1])))==null?void 0:vn.value),Oa}),ze.setTableViewContents(gl)),n!=null&&n.formRules)D.value=n==null?void 0:n.formRules;else{let Oa={};(xr=pl.safeClone(u).value)==null||xr.forEach(aa=>{((aa==null?void 0:aa.isMain)===!0||(aa==null?void 0:aa.required)===!0)&&(Oa[(aa==null?void 0:aa.prop)??(aa==null?void 0:aa.name)]=[{required:!0,message:`${(aa==null?void 0:aa.label)||(aa==null?void 0:aa.prop)||(aa==null?void 0:aa.name)}不能为空`}])}),D.value=Oa}if(((Ra=na==null?void 0:na.contents)==null?void 0:Ra.length)>0){const Oa=[];(kl=na==null?void 0:na.contents)==null||kl.forEach((aa,Rl)=>{(aa==null?void 0:aa.label)!==""&&Oa.push({label:(aa==null?void 0:aa.label)??"",id:(aa==null?void 0:aa.id)??Rl,type:(aa==null?void 0:aa.type)??"",background:aa==null?void 0:aa.background})}),O.value=Oa}else O.value=[];(Ml=u.value)!=null&&Ml.some(Oa=>(Oa==null?void 0:Oa.functionName)&&(Oa==null?void 0:Oa.functionName)!=="")&&(u.value=await $e(u.value))},{deep:!0,immediate:!0}),e.watch(()=>fe.value,ne=>{P.value=ne===Me.value},{immediate:!0}),(ne,We)=>{var Ee;const na=e.resolveComponent("svg-icon"),va=e.resolveComponent("el-switch"),Ae=e.resolveComponent("el-checkbox"),Be=e.resolveComponent("el-popover"),Ye=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",Ih,[I.value===e.unref(vi).TEXT?(e.openBlock(),e.createBlock(Jc,{key:0,itemData:a.itemData,compName:a.compName,calculator:a.calculator,fields:u.value,textSize:R.value,textColor:re.value,backGround:me.value,textBackColor:X.value,backGroundImage:ue.value,disabled:P.value||Xe(),iconUrl:p.value,"onUpdate:backGroundImage":fa,backgroundUrl:o.value,backgroundPosition:c.value},null,8,["itemData","compName","calculator","fields","textSize","textColor","backGround","textBackColor","backGroundImage","disabled","iconUrl","backgroundUrl","backgroundPosition"])):I.value===e.unref(vi).BLOCK?(e.openBlock(),e.createBlock(u0,{key:1,items:(Ee=u.value)==null?void 0:Ee.map(ye=>({label:ye!=null&&ye.isHideInForm?"":ye==null?void 0:ye.label,value:ye==null?void 0:ye.value,width:(ye==null?void 0:ye.width)??1,field:ye,filters:ye==null?void 0:ye.filters})),textSize:R.value,textColor:re.value,backGround:me.value,iconUrl:p.value,textBackColor:X.value,backGroundImage:ue.value,disabled:P.value||Xe(),calculator:a.calculator,"onUpdate:backGroundImage":fa,backgroundUrl:o.value,backgroundPosition:c.value},null,8,["items","textSize","textColor","backGround","iconUrl","textBackColor","backGroundImage","disabled","calculator","backgroundUrl","backgroundPosition"])):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass({"form-shadow-box":I.value===e.unref(vi).ORDINARY})},[e.createVNode(pl.ssForm,{rowContents:u.value,formRules:D.value,buttonValue:O.value,isRowFlex:!1,isEnableWrap:!0,textSize:R.value,textColor:re.value,backGround:me.value,backGroundImage:ue.value,onOnButtonClick:Pe,onChange:ma,formDisabled:P.value||Xe(),formLabelsOperable:ra.value,isButtonRow:w.value,onPreview:ja,onBlurChange:Ta,style:e.normalizeStyle({backGroundImage:o.value!==""?`url("${o.value}")`:void 0}),onHandleColEditChange:Ca,onHandleColTypeChange:Ce,onRouteUrl:ia,onClickTrigger:pa,"onUpdate:backGroundImage":fa},{operateCol:e.withCtx(({renderColumns:ye,formDisabled:$a,formLabelsOperable:wl})=>[e.createVNode(Be,{title:"选择操作的标签",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:ce},{reference:e.withCtx(()=>[e.createElementVNode("span",Oh,[e.createVNode(na,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"}})])]),default:e.withCtx(()=>[e.createElementVNode("div",Lh,[We[1]||(We[1]=e.createElementVNode("div",{class:"group-title"},"表单操作",-1)),e.createVNode(va,{"model-value":$a,"active-text":"禁用","inactive-text":"",onChange:V,style:{"margin-right":"8px"}},null,8,["model-value"]),e.createVNode(va,{"model-value":wl,"active-text":"编辑所有标签","inactive-text":"",onChange:ee},null,8,["model-value"]),We[2]||(We[2]=e.createElementVNode("div",{class:"group-title"},"表单列操作",-1)),e.createVNode(Ye,{modelValue:Ge.value,"onUpdate:modelValue":We[0]||(We[0]=Qa=>Ge.value=Qa),style:{height:"100%"},ref_key:"checkboxGroupRef",ref:qe,onChange:he},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ye,Qa=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:Qa.label},[e.createVNode(Ae,{value:Qa.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(Qa.label),1)]),_:2},1032,["value"]),e.createVNode(Be,{title:"标签操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(na,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Pl;return[e.createElementVNode("div",Rh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Pl=Object.keys(Qa))==null?void 0:Pl.filter(gl=>{var jl;return(jl=$.value)==null?void 0:jl.find(al=>(al==null?void 0:al.value)===gl)}),gl=>{var jl,al;return e.openBlock(),e.createElementBlock("div",{key:gl},[e.createVNode(pl._sfc_main$1,{value:Qa==null?void 0:Qa[gl],"active-text":(al=(jl=$.value)==null?void 0:jl.find(Hl=>(Hl==null?void 0:Hl.value)===gl))==null?void 0:al.label,inactiveText:"",onChange:Hl=>Fa(Hl,gl,Qa)},null,8,["value","active-text","onChange"])])}),128))])]}),_:2},1024),e.createElementVNode("span",$h,[e.createVNode(na,{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)),q.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:3,fileDataList:E.value,onDestroy:sa},null,8,["fileDataList"])):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createBlock($r.ssDialog,{key:4,visible:m.value,onBeforeDestroy:r,style:{height:"700px",width:"1000px"}},{default:e.withCtx(()=>[e.createVNode(Do.ThreeViewerHost,{files:y.value,onGetAnimationData:ne.onAnimationData},null,8,["files","onGetAnimationData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0)])}}},Rs=pr._export_sfc(Vh,[["__scopeId","data-v-6e8f9fb6"]]),Fh={class:"table-header-child"},Ph={class:"table-header-child-main"},jh={class:"table-header-child-content"},Hh={class:"table-header-child-content-item"},Uh={class:"fix-button"},qh={key:0},Wh={class:"form-content"},Gh={__name:"tableNewChild",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(!1),o=e.ref(""),p=le.useTableComp(M.pinia),{tableIndex:c}=M.storeToRefs(p);e.ref(0);const u=e.ref(""),m=e.ref([]),g=e.ref([]),y=E=>{var x;i.value=!0;let _=[];_r==null||_r.forEach(b=>{let S=M.cloneDeep(c.value)+1;p.setTableIndex(S),_.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&&((x=E==null?void 0:E.children)==null?void 0:x.length)>0&&_.push({children:E==null?void 0:E.children,isFormColHidden:!0}),u.value=E==null?void 0:E.id,m.value=_,g.value=_},d=E=>{n("fixChange",M.cloneDeep(E))},D=E=>{n("deleteChange",M.cloneDeep(E))},w=E=>{i.value=!0;let _=[];_r==null||_r.forEach(x=>{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),_.push({label:x==null?void 0:x.label,name:x==null?void 0:x.label,type:x.type,value:"",id:c.value,contents:x==null?void 0:x.options})}),o.value=E==null?void 0:E.id,m.value=_,g.value=_},q=E=>{let _=M.cloneDeep(g.value);_=_==null?void 0:_.map(x=>(x.children||(x.value=E==null?void 0:E[x.name]),x)),g.value=_},A=()=>{var _,x;m.value=g.value;let E={};if(u.value!=="")E.id=u.value,(_=m.value)==null||_.forEach(b=>{const S=_r==null?void 0:_r.find(I=>(I==null?void 0:I.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,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"fix"});else{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),E.id="id"+c.value,(x=m.value)==null||x.forEach(S=>{const I=_r==null?void 0:_r.find(R=>(R==null?void 0:R.label)===(S==null?void 0:S.label));I?E[I.key]=S.value:S!=null&&S.children&&S.children.length>0&&(E.children=S.children)}),i.value=!1,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"add"})}u.value="",m.value=[],g.value=[]},j=()=>{i.value=!1,u.value="",o.value="",m.value=[],g.value=[]},O=E=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{n("deleteChange",E),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(E,_)=>{const x=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",Fh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r==null?void 0:r.tableChildContents,(b,S)=>(e.openBlock(),e.createElementBlock("div",Ph,[e.createElementVNode("div",jh,[e.createElementVNode("div",Hh,e.toDisplayString(b.label),1),e.createElementVNode("div",Uh,[e.createVNode(x,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:I=>w(b)},null,8,["onClick"]),e.createVNode(x,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:I=>y(b)},null,8,["onClick"]),e.createVNode(x,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:I=>O(b)},null,8,["onClick"])])]),b!=null&&b.children&&b.children.length>0?(e.openBlock(),e.createElementBlock("div",qh,[e.createVNode(Xc,{tableChildContents:b==null?void 0:b.children,onDeleteChange:D,onFixChange:d},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode($r.ssDialog,{visible:i.value,onBeforeDestroy:j,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Wh,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:q},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:A},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},Kh=pr._export_sfc(Gh,[["__scopeId","data-v-e0fef72d"]]),Yh={class:"table-header-child"},Jh={class:"table-header-child-main"},Xh={class:"table-header-child-content"},Zh={class:"table-header-child-content-item"},Qh={class:"fix-button"},e6={key:0},a6={class:"form-content"},l6={class:"dialog-footer"},r6={__name:"tableChildren",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(!1),o=e.ref(""),p=le.useTableComp(M.pinia),{tableIndex:c}=M.storeToRefs(p),u=e.ref(""),m=e.ref([]),g=e.ref([]),y=E=>{n("fixChange",M.cloneDeep(E))},d=E=>{var x;i.value=!0;let _=[];_r==null||_r.forEach(b=>{let S=M.cloneDeep(c.value)+1;p.setTableIndex(S),_.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&&((x=E==null?void 0:E.children)==null?void 0:x.length)>0&&_.push({children:E==null?void 0:E.children,isFormColHidden:!0}),u.value=E==null?void 0:E.id,m.value=_,g.value=_},D=E=>{i.value=!0;let _=[];_r==null||_r.forEach(x=>{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),_.push({label:x==null?void 0:x.label,name:x==null?void 0:x.label,type:x.type,value:"",id:c.value,contents:x==null?void 0:x.options})}),o.value=E==null?void 0:E.id,m.value=_,g.value=_},w=E=>{let _=M.cloneDeep(g.value);_=_==null?void 0:_.map(x=>(x.children||(x.value=E==null?void 0:E[x.name]),x)),g.value=_},q=()=>{var _,x;m.value=g.value;let E={};if(u.value!=="")E.id=u.value,(_=m.value)==null||_.forEach(b=>{const S=_r==null?void 0:_r.find(I=>(I==null?void 0:I.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,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"fix"});else{let b=M.cloneDeep(c.value)+1;p.setTableIndex(b),E.id="idChild"+c.value,(x=m.value)==null||x.forEach(S=>{const I=_r==null?void 0:_r.find(R=>(R==null?void 0:R.label)===(S==null?void 0:S.label));I?E[I.key]=S.value:S!=null&&S.children&&S.children.length>0&&(E.children=S.children)}),i.value=!1,n("fixChange",{contents:M.cloneDeep(E),id:o.value,type:"add"})}u.value="",m.value=[],g.value=[]},A=()=>{i.value=!1,u.value="",o.value="",m.value=[],g.value=[]},j=E=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{n("deleteChange",E),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},O=E=>{n("deleteChange",E)};return(E,_)=>{const x=e.resolveComponent("svg-icon"),b=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",Yh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r==null?void 0:r.tableChildContents,(S,I)=>(e.openBlock(),e.createElementBlock("div",Jh,[e.createElementVNode("div",Xh,[e.createElementVNode("div",Zh,e.toDisplayString(S.label),1),e.createElementVNode("div",Qh,[e.createVNode(x,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:R=>D(S)},null,8,["onClick"]),e.createVNode(x,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:R=>d(S)},null,8,["onClick"]),e.createVNode(x,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:R=>j(S)},null,8,["onClick"])])]),S!=null&&S.children&&S.children.length>0?(e.openBlock(),e.createElementBlock("div",e6,[e.createVNode(Kh,{tableChildContents:S==null?void 0:S.children,onDeleteChange:O,onFixChange:y},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode($r.ssDialog,{visible:i.value,onBeforeDestroy:A,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",a6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:w},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",l6,[e.createVNode(b,{onClick:A,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>_[0]||(_[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(b,{class:"ok-button button",onClick:q,id:"themeButton"},{default:e.withCtx(()=>_[1]||(_[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},Xc=pr._export_sfc(r6,[["__scopeId","data-v-ebd68fa1"]]),n6={class:"table-operate-content"},i6={class:"table-operate-item"},o6={class:"operate-title"},t6={class:"operate-content"},s6={class:"fix-content"},c6={class:"fix-content-label"},u6={class:"fix-button"},d6={key:0},p6={class:"operate-title"},f6={class:"operate-content"},h6={class:"fix-content"},v6={class:"fix-content-label"},m6={class:"fix-button"},y6={class:"operate-title"},g6={class:"operate-content"},b6={class:"fix-content"},k6={class:"fix-content-label"},x6={class:"fix-button"},w6={class:"operate-title"},_6={class:"operate-content"},S6={class:"fix-content"},E6={class:"fix-content-label"},C6={class:"fix-button"},D6={class:"operate-content"},T6={style:{display:"flex","justify-content":"space-between"}},B6={class:"form-content"},N6={class:"dialog-footer"},A6={class:"form-content"},z6={class:"dialog-footer"},M6={class:"form-content"},I6={class:"dialog-footer"},O6={class:"form-content"},L6={class:"dialog-footer"},R6={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref([]),o=e.ref(!1),p=e.ref(!1),c=e.ref([]),u=e.ref(!1),m=e.ref([]),g=e.ref(!1),y=e.ref([]),d=e.ref(""),D=e.ref(""),w=e.ref([]),q=e.ref([]),A=e.ref([]),j=e.ref([]),O=e.ref(!1),E=e.ref([]),_=e.ref([]),x=e.ref(0),b=e.ref([]),S=e.ref([]),I=e.ref([]),R=()=>{O.value=!0;let $=[];Jn==null||Jn.forEach(V=>{x.value++,$.push({label:V==null?void 0:V.label,name:V==null?void 0:V.label,type:V.type,value:(V==null?void 0:V.key)==="background"?"var(--ssComponent-primary-color)":"",id:x.value,contents:V==null?void 0:V.options})}),E.value=$,_.value=$},re=()=>{var V,ee,ce;p.value=!0;let $=[];(ce=(ee=(V=le.FormContent)==null?void 0:V.find(he=>(he==null?void 0:he.key)==="Input"))==null?void 0:ee.value)==null||ce.forEach(he=>{x.value++,$.push({label:he==null?void 0:he.label,name:(he==null?void 0:he.name)||(he==null?void 0:he.label),type:he.type,value:(he==null?void 0:he.label)==="类型"?"Input":"",id:x.value,contents:he==null?void 0:he.options})}),b.value=$,S.value=$},X=$=>{$||(b.value=S.value)},me=async $=>{var V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta;if(($==null?void 0:$.类型)!==((ee=(V=S.value)==null?void 0:V.find(fa=>(fa==null?void 0:fa.label)==="类型"))==null?void 0:ee.value)){let fa=[],ja=await((pa=(he=(ce=le.FormContent)==null?void 0:ce.find(sa=>(sa==null?void 0:sa.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:he.value)==null?void 0:pa.value)?await((Ce=(Ca=(ya=le.FormContent)==null?void 0:ya.find(sa=>(sa==null?void 0:sa.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:Ca.value)==null?void 0:Ce.value):(Ve=(ia=le.FormContent)==null?void 0:ia.find(sa=>(sa==null?void 0:sa.key)===(($==null?void 0:$.类型)===""?"Input":$==null?void 0:$.类型)))==null?void 0:Ve.value;if(ja==null||ja.forEach(sa=>{x.value++,fa.push({label:sa==null?void 0:sa.label,name:(sa==null?void 0:sa.name)||(sa==null?void 0:sa.label),type:sa.type,value:sa!=null&&sa.属性名?($==null?void 0:$.prop)||($==null?void 0:$.name)||($==null?void 0:$.label):($==null?void 0:$[sa.label])??"",id:x.value,contents:sa==null?void 0:sa.options,prop:(sa==null?void 0:sa.prop)||(sa==null?void 0:sa.name)||(sa==null?void 0:sa.label)})}),$!=null&&$.菜单选项&&((Fa=$==null?void 0:$.菜单选项)==null?void 0:Fa.length)>0){const sa=await le.menuToContentType($==null?void 0:$.菜单选项);fa=fa==null?void 0:fa.map(Pe=>((Pe==null?void 0:Pe.name)==="组信息选项"&&(Pe.contents=sa),Pe))}S.value=await le.selectToBase(M.cloneDeep(fa)),b.value=await le.selectToBase(M.cloneDeep(fa))}else{let fa=M.cloneDeep(b.value);if(fa=fa==null?void 0:fa.map(ja=>(ja.value=$==null?void 0:$[ja.name],ja)),$!=null&&$.菜单选项&&((Ta=$==null?void 0:$.菜单选项)==null?void 0:Ta.length)>0){const ja=await le.menuToContentType($==null?void 0:$.菜单选项);fa=fa==null?void 0:fa.map(sa=>((sa==null?void 0:sa.name)==="组信息选项"&&(sa.contents=ja),sa))}fa=le.formToOptionsContents(fa),S.value=await le.selectToBase(M.cloneDeep(fa))}},ue=async $=>{await me($),b.value=S.value},U=($,V)=>{if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="selectRelateType"){const ee=V==null?void 0:V.optionUrl;return(ee==null?void 0:ee.selectRelateType)||V[$.key]}if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="menuSelect"){const ee=V==null?void 0:V.optionUrl;return(ee==null?void 0:ee.menuSelect)||V[$.key]}if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="groupSelect"){const ee=V==null?void 0:V.optionUrl;return(ee==null?void 0:ee.groupSelect)||V[$.key]}if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="originalContent")return(V==null?void 0:V.value)||V[$.key];if((V==null?void 0:V.type)=="Select"&&($==null?void 0:$.key)==="multiple"){const ee=V[$.key];return fc(ee)?ee:$.default}return($==null?void 0:$.label)==="类型"&&V[$.key]===""?"Input":($==null?void 0:$.key)==="isFormColHidden"&&!V[$.key]?!1:V[$.key]},W=async $=>{var ce,he,pa,ia,Ve,ya,Ca,Ce,Fa;p.value=!0;let V=[];const ee=await((pa=(he=(ce=le.FormContent)==null?void 0:ce.find(Ta=>(Ta==null?void 0:Ta.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:he.value)==null?void 0:pa.value)?await((Ce=(Ca=(ya=le.FormContent)==null?void 0:ya.find(Ta=>(Ta==null?void 0:Ta.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:Ca.value)==null?void 0:Ce.value):(Ve=(ia=le.FormContent)==null?void 0:ia.find(Ta=>(Ta==null?void 0:Ta.key)===(($==null?void 0:$.type)===""?"Input":$==null?void 0:$.type)))==null?void 0:Ve.value;if(ee==null||ee.forEach(Ta=>{x.value++,V.push({label:Ta==null?void 0:Ta.label,name:(Ta==null?void 0:Ta.name)||(Ta==null?void 0:Ta.label),type:Ta.type,value:(Ta==null?void 0:Ta.label)==="属性名"?($==null?void 0:$.prop)||($==null?void 0:$.name)||($==null?void 0:$.label):U(Ta,$),id:x.value,contents:Ta==null?void 0:Ta.options})}),$!=null&&$.menuSelect&&((Fa=$==null?void 0:$.menuSelect)==null?void 0:Fa.length)>0){const Ta=await le.menuToContentType($==null?void 0:$.menuSelect);V=V==null?void 0:V.map(fa=>((fa==null?void 0:fa.name)==="组信息选项"&&(fa.contents=Ta),fa))}d.value=$==null?void 0:$.id,b.value=await le.selectToBase(le.formToOptionsContents(V)),S.value=await le.selectToBase(le.formToOptionsContents(V))},Z=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;I.value=(V=M.cloneDeep(I.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="tableToForm"&&(ce.contents=I.value),ce))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},ae=()=>{p.value=!1,b.value=[],d.value=""},ve=async()=>{var ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta;b.value=S.value;let $={};d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value);let V=await((pa=(he=(ce=le.FormContent)==null?void 0:ce.find(fa=>{var ja,sa;return(fa==null?void 0:fa.key)===(((sa=(ja=b.value)==null?void 0:ja.find(Pe=>(Pe==null?void 0:Pe.label)==="类型"))==null?void 0:sa.value)??"label")}))==null?void 0:he.value)==null?void 0:pa.value)??((Ve=(ia=le.FormContent)==null?void 0:ia.find(fa=>{var ja,sa;return(fa==null?void 0:fa.key)===(((sa=(ja=b.value)==null?void 0:ja.find(Pe=>(Pe==null?void 0:Pe.label)==="类型"))==null?void 0:sa.value)??"label")}))==null?void 0:Ve.value);if((ya=b.value)==null||ya.forEach(fa=>{const ja=V==null?void 0:V.find(sa=>(sa==null?void 0:sa.label)===(fa==null?void 0:fa.label));ja&&($[ja.key]=fa.value)}),$.name=$.label,(Ca=I.value)!=null&&Ca.find(fa=>fa.id===$.id))I.value=(Ce=I.value)==null?void 0:Ce.map(fa=>(fa.id===$.id&&(fa=$),fa));else{let fa=M.cloneDeep(I.value);I.value||(I.value=[]),fa.push($),I.value=fa}I.value=I.value.map(({id:fa,...ja})=>ja),p.value=!1,d.value="";let ee=M.cloneDeep(r.originalItemContents);(Fa=M.cloneDeep(r.originalItemContents))!=null&&Fa.find(fa=>(fa==null?void 0:fa.key)==="tableToForm")?ee=(Ta=M.cloneDeep(r.originalItemContents))==null?void 0:Ta.map(fa=>((fa==null?void 0:fa.key)==="tableToForm"&&(fa.contents=I.value),fa)):ee.push({key:"tableToForm",contents:I.value}),n("change",ee)},ze=$=>{O.value=!0;let V=[];Jn==null||Jn.forEach(ee=>{x.value++,V.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:$[ee.key],id:x.value,contents:ee==null?void 0:ee.options})}),d.value=$==null?void 0:$.id,E.value=V,_.value=V};e.watch(()=>g.value,()=>{var V,ee;let $=M.cloneDeep(r.originalItemContents);(V=M.cloneDeep(r.originalItemContents))!=null&&V.find(ce=>(ce==null?void 0:ce.key)==="page")?$=(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="page"&&(ce.contents=g.value),ce)):$.push({key:"page",contents:g.value}),n("change",$)},{deep:!0});const te=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;q.value=(V=M.cloneDeep(q.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="extraButton"&&(ce.contents=q.value),ce))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},N=()=>{var ee,ce,he,pa,ia;E.value=_.value;let $={};if(d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value),(ee=E.value)==null||ee.forEach(Ve=>{const ya=Jn==null?void 0:Jn.find(Ca=>(Ca==null?void 0:Ca.label)===(Ve==null?void 0:Ve.label));ya?$[ya.key]=Ve.value:Ve!=null&&Ve.children&&Ve.children.length>0&&($.children=Ve.children)}),(ce=q.value)!=null&&ce.find(Ve=>Ve.id===$.id))q.value=(he=q.value)==null?void 0:he.map(Ve=>(Ve.id===$.id&&(Ve=$),Ve));else{let Ve=M.cloneDeep(q.value)??[];Ve.push($),q.value=Ve}O.value=!1,d.value="";let V=M.cloneDeep(r.originalItemContents);(pa=M.cloneDeep(r.originalItemContents))!=null&&pa.find(Ve=>(Ve==null?void 0:Ve.key)==="extraButton")?V=(ia=M.cloneDeep(r.originalItemContents))==null?void 0:ia.map(Ve=>((Ve==null?void 0:Ve.key)==="extraButton"&&(Ve.contents=q.value),Ve)):V.push({key:"extraButton",contents:q.value}),n("change",V)},se=$=>{let V=M.cloneDeep(_.value);V=V==null?void 0:V.map(ee=>(ee.children||(ee.value=$==null?void 0:$[ee.name]),ee)),_.value=V},G=()=>{O.value=!1,E.value=[],d.value=""},fe=$=>{u.value=!0;let V=[];Xn==null||Xn.forEach(ee=>{x.value++,V.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:$[ee.key],id:x.value,contents:ee==null?void 0:ee.options})}),d.value=$==null?void 0:$.id,A.value=V,j.value=V},we=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;w.value=(V=M.cloneDeep(w.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>((ce==null?void 0:ce.key)==="rowButton"&&(ce.contents=w.value),ce))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},_e=()=>{o.value=!0;let $=[];_r==null||_r.forEach(V=>{x.value++,$.push({label:V==null?void 0:V.label,name:V==null?void 0:V.label,type:V.type,value:"",id:x.value,contents:V==null?void 0:V.options})}),m.value=$,y.value=$},qe=()=>{u.value=!0;let $=[];Xn==null||Xn.forEach(V=>{x.value++,$.push({label:V==null?void 0:V.label,name:V==null?void 0:V.label,type:V.type,value:"",id:x.value,contents:V==null?void 0:V.options})}),A.value=$,j.value=$},ra=$=>{let V=M.cloneDeep(j.value);V=V==null?void 0:V.map(ee=>(ee.children||(ee.value=$==null?void 0:$[ee.name]),ee)),j.value=V},P=()=>{var ee,ce,he,pa,ia;A.value=j.value;let $={};if(d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value),(ee=A.value)==null||ee.forEach(Ve=>{const ya=Xn==null?void 0:Xn.find(Ca=>(Ca==null?void 0:Ca.label)===(Ve==null?void 0:Ve.label));ya?$[ya.key]=Ve.value:Ve!=null&&Ve.children&&Ve.children.length>0&&($.children=Ve.children)}),(ce=w.value)!=null&&ce.find(Ve=>Ve.id===$.id))w.value=(he=w.value)==null?void 0:he.map(Ve=>(Ve.id===$.id&&(Ve=$),Ve));else{let Ve=M.cloneDeep(w.value);Ve.push($),w.value=Ve}u.value=!1,d.value="";let V=M.cloneDeep(r.originalItemContents);(pa=M.cloneDeep(r.originalItemContents))!=null&&pa.find(Ve=>(Ve==null?void 0:Ve.key)==="rowButton")?V=(ia=M.cloneDeep(r.originalItemContents))==null?void 0:ia.map(Ve=>((Ve==null?void 0:Ve.key)==="rowButton"&&(Ve.contents=w.value),Ve)):V.push({key:"rowButton",contents:w.value}),n("change",V)},Ke=()=>{u.value=!1,d.value="",j.value=[],A.value=[]},Me=$=>{o.value=!0;let V=[];_r==null||_r.forEach(ee=>{x.value++,V.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:"",id:x.value,contents:ee==null?void 0:ee.options})}),m.value=V,D.value=$==null?void 0:$.id,y.value=V},Le=$=>{var V;c.value=qc(M.cloneDeep(c.value),$==null?void 0:$.id),n("change",(V=M.cloneDeep(r.originalItemContents))==null?void 0:V.map(ee=>{var ce;return(ee==null?void 0:ee.key)==="header"&&(ee.contents=(ce=c.value)!=null&&ce.some(he=>he==null?void 0:he.children)?[c.value]:c.value),ee}))},Ie=$=>{var ee,ce,he;$.type==="fix"?$.id!==""?c.value=Gc(c.value,$):c.value=Wc(c.value,$==null?void 0:$.contents):c.value=Kc(c.value,$),c.value=(ee=c.value)!=null&&ee.some(pa=>pa==null?void 0:pa.children)?[c.value]:c.value,d.value="";let V=M.cloneDeep(r.originalItemContents);(ce=M.cloneDeep(r.originalItemContents))!=null&&ce.find(pa=>(pa==null?void 0:pa.key)==="header")?V=(he=M.cloneDeep(r.originalItemContents))==null?void 0:he.map(pa=>((pa==null?void 0:pa.key)==="header"&&(pa.contents=c.value),pa)):V.push({key:"header",contents:c.value}),n("change",V)},de=$=>{var ee;o.value=!0;let V=[];_r==null||_r.forEach(ce=>{x.value++,V.push({label:ce==null?void 0:ce.label,name:ce==null?void 0:ce.label,type:ce.type,value:$[ce.key],id:x.value,contents:ce==null?void 0:ce.options})}),$!=null&&$.children&&((ee=$==null?void 0:$.children)==null?void 0:ee.length)>0&&V.push({children:$==null?void 0:$.children,isFormColHidden:!0}),d.value=$==null?void 0:$.id,D.value="",m.value=V,y.value=V},De=$=>{let V=M.cloneDeep(y.value);V=V==null?void 0:V.map(ee=>(ee.children||(ee.value=$==null?void 0:$[ee.name]),ee)),y.value=V},Xe=()=>{o.value=!1,d.value="",D.value="",y.value=[]},Ea=()=>{var ee,ce,he,pa,ia,Ve;m.value=y.value;let $={};if(d.value!==""?$.id=d.value:(x.value++,$.id="id"+x.value),(ee=m.value)==null||ee.forEach(ya=>{const Ca=_r==null?void 0:_r.find(Ce=>(Ce==null?void 0:Ce.label)===(ya==null?void 0:ya.label));Ca?$[Ca.key]=ya.value:ya!=null&&ya.children&&ya.children.length>0&&($.children=ya.children)}),(ce=c.value)!=null&&ce.find(ya=>ya.id===$.id))c.value=(he=c.value)==null?void 0:he.map(ya=>(ya.id===$.id&&(ya=$),ya));else{let ya=M.cloneDeep(c.value)??[];D.value===""?ya.push($):ya=ya==null?void 0:ya.map(Ca=>(Ca.id===D.value&&(Ca.children||(Ca.children=[]),Ca.children.push($)),Ca)),c.value=ya}c.value=(pa=c.value)!=null&&pa.some(ya=>ya==null?void 0:ya.children)?[c.value]:c.value,o.value=!1,d.value="",D.value="";let V=M.cloneDeep(r.originalItemContents);(ia=M.cloneDeep(r.originalItemContents))!=null&&ia.find(ya=>(ya==null?void 0:ya.key)==="header")?V=(Ve=M.cloneDeep(r.originalItemContents))==null?void 0:Ve.map(ya=>((ya==null?void 0:ya.key)==="header"&&(ya.contents=c.value),ya)):V.push({key:"header",contents:c.value}),n("change",V)},Ge=$=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var V,ee;c.value=(V=M.cloneDeep(c.value))==null?void 0:V.filter(ce=>(ce==null?void 0:ce.id)!==($==null?void 0:$.id)),n("change",(ee=M.cloneDeep(r.originalItemContents))==null?void 0:ee.map(ce=>{var he;return(ce==null?void 0:ce.key)==="header"&&(ce.contents=(he=c.value)!=null&&he.some(pa=>pa==null?void 0:pa.children)?[c.value]:c.value),ce})),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return e.watch(()=>r.originalItemContents,()=>{var $,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe;if(!(!r.originalItemContents||r.originalItemContents.length===0))if(i.value=M.cloneDeep(r.originalItemContents),c.value=(V=($=i.value)==null?void 0:$.find(Oe=>(Oe==null?void 0:Oe.key)==="header"))==null?void 0:V.contents,w.value=(ce=(ee=i.value)==null?void 0:ee.find(Oe=>(Oe==null?void 0:Oe.key)==="rowButton"))==null?void 0:ce.contents,q.value=(pa=(he=i.value)==null?void 0:he.find(Oe=>(Oe==null?void 0:Oe.key)==="extraButton"))==null?void 0:pa.contents,g.value=(Ve=(ia=i.value)==null?void 0:ia.find(Oe=>(Oe==null?void 0:Oe.key)==="page"))!=null&&Ve.contents?!!((Ca=(ya=i.value)==null?void 0:ya.find(Oe=>(Oe==null?void 0:Oe.key)==="page"))!=null&&Ca.contents):!1,I.value=(Fa=(Ce=i.value)==null?void 0:Ce.find(Oe=>(Oe==null?void 0:Oe.key)==="tableToForm"))==null?void 0:Fa.contents,c.value=(Ta=c.value)==null?void 0:Ta.map((Oe,$e)=>(Array.isArray(Oe)?Oe=T3(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)??$e,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))?(ja=c.value)==null?void 0:ja[0]:c.value,w.value=(sa=w.value)==null?void 0:sa.map((Oe,$e)=>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)??$e}),q.value=(Pe=q.value)==null?void 0:Pe.map((Oe,$e)=>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)??$e}),I.value)I.value=(Qe=I.value)==null?void 0:Qe.map(Oe=>{x.value++;let $e=Oe;return $e.id=x.value,$e});else{let Oe=[];const $e=(ma=le.getColumnChild(M.cloneDeep(c.value)))==null?void 0:ma.filter(ne=>(ne==null?void 0:ne.prop)!=="operate");$e==null||$e.forEach(ne=>{var We;x.value++,Oe.push({label:ne==null?void 0:ne.label,name:(ne==null?void 0:ne.prop)||(ne==null?void 0:ne.label),type:ne!=null&&ne.groupSelect?"Select":"Input",value:"",id:x.value,contents:ne==null?void 0:ne.options,menuSelect:ne==null?void 0:ne.formMenuSelect,groupSelect:(We=ne==null?void 0:ne.groupSelect)==null?void 0:We.split(":"),selectRelateType:"关联绑定列"})}),I.value=Oe}},{deep:!0,immediate:!0}),($,V)=>{const ee=e.resolveComponent("svg-icon"),ce=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",n6,[e.createElementVNode("div",i6,[e.createElementVNode("div",o6,[V[2]||(V[2]=e.createElementVNode("div",null,e.toDisplayString("表头"),-1)),e.createVNode(ce,{class:"icon-content",onClick:_e,id:"themeButton"},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[1]||(V[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",t6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",s6,[e.createElementVNode("div",c6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",u6,[e.createVNode(ee,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>Me(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>de(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>Ge(he)},null,8,["onClick"])])]),he!=null&&he.children&&he.children.length>0?(e.openBlock(),e.createElementBlock("div",d6,[e.createVNode(Xc,{tableChildContents:he==null?void 0:he.children,onDeleteChange:Le,onFixChange:Ie},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),128))]),e.createElementVNode("div",p6,[V[4]||(V[4]=e.createElementVNode("div",null,e.toDisplayString("行内按钮"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:qe},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[3]||(V[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",f6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",h6,[e.createElementVNode("div",v6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",m6,[e.createVNode(ee,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ia=>fe(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>we(he)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",y6,[V[6]||(V[6]=e.createElementVNode("div",null,e.toDisplayString("表外按钮"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:R},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[5]||(V[5]=e.createTextVNode(" 新增 "))]),_:1,__:[5]})]),e.createElementVNode("div",g6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(q.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",b6,[e.createElementVNode("div",k6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",x6,[e.createVNode(ee,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ia=>ze(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>te(he)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",w6,[V[8]||(V[8]=e.createElementVNode("div",null,e.toDisplayString("表格弹框字段设置"),-1)),e.createVNode(ce,{class:"icon-content",id:"themeButton",onClick:re},{icon:e.withCtx(()=>[e.createVNode(ee,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[V[7]||(V[7]=e.createTextVNode(" 新增 "))]),_:1,__:[7]})]),e.createElementVNode("div",_6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(I.value,(he,pa)=>(e.openBlock(),e.createElementBlock("div",{key:pa},[e.createElementVNode("div",S6,[e.createElementVNode("div",E6,e.toDisplayString(he==null?void 0:he.label),1),e.createElementVNode("div",C6,[e.createVNode(ee,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ia=>W(he)},null,8,["onClick"]),e.createVNode(ee,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ia=>Z(he)},null,8,["onClick"])])])]))),128))]),V[10]||(V[10]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("分页"))],-1)),e.createElementVNode("div",D6,[e.createElementVNode("div",T6,[V[9]||(V[9]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否分页"),-1)),e.createVNode(pl._sfc_main$1,{modelValue:g.value,"onUpdate:modelValue":V[0]||(V[0]=he=>g.value=he)},null,8,["modelValue"])])])]),e.createVNode($r.ssDialog,{visible:o.value,onBeforeDestroy:Xe,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",B6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:De},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",N6,[e.createVNode(ce,{onClick:Xe,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[11]||(V[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(ce,{class:"ok-button button",onClick:Ea,id:"themeButton"},{default:e.withCtx(()=>V[12]||(V[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:u.value,onBeforeDestroy:Ke,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",A6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:A.value,key:A.value,isEnableWrap:!0,onChange:ra},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",z6,[e.createVNode(ce,{onClick:Ke,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[13]||(V[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(ce,{class:"ok-button button",onClick:P,id:"themeButton"},{default:e.withCtx(()=>V[14]||(V[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:O.value,onBeforeDestroy:G,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",M6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:se},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",I6,[e.createVNode(ce,{onClick:G,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[15]||(V[15]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[15]}),e.createVNode(ce,{class:"ok-button button",onClick:N,id:"themeButton"},{default:e.withCtx(()=>V[16]||(V[16]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[16]})])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:p.value,onBeforeDestroy:ae,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",O6,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:me,onChangeVisible:X,onBlurChange:ue},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",L6,[e.createVNode(ce,{onClick:ae,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>V[17]||(V[17]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[17]}),e.createVNode(ce,{class:"ok-button button",onClick:ve,id:"themeButton"},{default:e.withCtx(()=>V[18]||(V[18]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[18]})])]),_:1},8,["visible"])])}}},$6=pr._export_sfc(R6,[["__scopeId","data-v-7a6b87b5"]]),V6=M.useModelComp(M.pinia),{pageMapState:Zc}=M.storeToRefs(V6),F6=M.useMenuState(M.pinia),{activeMenuPath:Qc,systemHeight:eu}=M.storeToRefs(F6),P6=e.ref(24),j6=e.ref(6),au=e.ref(10),H6=e.ref(70),U6=e.ref(.18),q6=e.ref(45),W6=()=>{au.value=(eu.value-100)/100};e.watch(()=>eu.value,()=>{W6()},{deep:!0,immediate:!0});const G6=(a,l,r,n)=>{var i,o,p,c,u,m,g,y,d,D,w,q,A,j,O,E;return{x:((o=(i=a==null?void 0:a.value)==null?void 0:i.tableData)==null?void 0:o.x)||l%2*12,y:((c=(p=a==null?void 0:a.value)==null?void 0:p.tableData)==null?void 0:c.y)||l,w:((m=(u=a==null?void 0:a.value)==null?void 0:u.tableData)==null?void 0:m.w)||P6.value,h:((y=(g=a==null?void 0:a.value)==null?void 0:g.tableData)==null?void 0:y.h)||r,minW:((D=(d=a==null?void 0:a.value)==null?void 0:d.tableData)==null?void 0:D.minW)||j6.value,minH:((q=(w=a==null?void 0:a.value)==null?void 0:w.tableData)==null?void 0:q.minH)||U6.value,maxH:((j=(A=a==null?void 0:a.value)==null?void 0:A.tableData)==null?void 0:j.maxH)||q6.value,i:((E=(O=a==null?void 0:a.value)==null?void 0:O.tableData)==null?void 0:E.i)||l,id:(a==null?void 0:a.id)||l+"",component:n}},K6=(a,l)=>{var n,i,o,p,c,u,m,g;let r=1;if(a!=null&&a.compData&&Array.isArray(a==null?void 0:a.compData))if(((n=a==null?void 0:a.comp)==null?void 0:n.toUpperCase())==="TABLE"){if(((p=(o=(i=a==null?void 0:a.compData)==null?void 0:i.find(d=>(d==null?void 0:d.key)==="tableContents"))==null?void 0:o.contents)==null?void 0:p.length)===0)return 2}else((c=a==null?void 0:a.comp)==null?void 0:c.toUpperCase())==="FORM"&&(r=((g=(m=(u=a==null?void 0:a.compData)==null?void 0:u.find(d=>(d==null?void 0:d.key)==="formContent"))==null?void 0:m.contents)==null?void 0:g.length)/5);return r*2},lu=(a,l,r)=>{var p,c;const n=(c=(p=Zc.value)==null?void 0:p[Qc.value])==null?void 0:c.filter(u=>{var m;return((m=u==null?void 0:u.key)==null?void 0:m.type)==="gridLayout"}),i=n==null?void 0:n.find(u=>{var m,g,y;return((y=(g=(m=u==null?void 0:u.value)==null?void 0:m.tableData)==null?void 0:g.component)==null?void 0:y.id)===a.id}),o=K6(a);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((u,m)=>lu(u,m))),{...G6(i,l,o,a)}},Y6=(a,l)=>{if((a==null?void 0:a.length)===0)return[];const r=M.cloneDeep(a);return Array.isArray(a)?r==null?void 0:r.map((n,i)=>lu(n,i)):[]},J6=(a,l,r,n)=>{var i,o;return{x:r==null?void 0:r.x,y:0,w:Math.round(r==null?void 0:r.w),h:r==null?void 0:r.h,arrowGap:r==null?void 0:r.arrowGap,i:((o=(i=a==null?void 0:a.value)==null?void 0:i.tableData)==null?void 0:o.i)||l,id:(a==null?void 0:a.id)||l+"",component:n}},X6=(a,l)=>{var m,g,y,d;let r=0,n=0,i=0,o=0,p=0,c=((g=(m=a==null?void 0:a.compData)==null?void 0:m.find(D=>(D==null?void 0:D.key)==="numPosition"))==null?void 0:g.contents)??[],u=((d=(y=a==null?void 0:a.compData)==null?void 0:y.find(D=>(D==null?void 0:D.key)==="rowPosition"))==null?void 0:d.contents)??"";return u&&u!==1&&(p=Math.ceil(u*l)),i=(c==null?void 0:c[0])*l,o=(c==null?void 0:c[1])*100,{x:r,y:n,w:i,h:o,arrowGap:p}},ru=(a,l,r)=>{var p,c;const n=(c=(p=Zc.value)==null?void 0:p[Qc.value])==null?void 0:c.filter(u=>{var m;return((m=u==null?void 0:u.key)==null?void 0:m.type)==="gridLayout"}),i=n==null?void 0:n.find(u=>{var m,g,y;return((y=(g=(m=u==null?void 0:u.value)==null?void 0:m.tableData)==null?void 0:g.component)==null?void 0:y.id)===a.id}),o=X6(a,r);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((u,m)=>ru(u,m,r))),{...J6(i,l,o,a)}},Z6=(a,l)=>{if((a==null?void 0:a.length)===0)return[];const r=M.cloneDeep(a);return Array.isArray(a)?r==null?void 0:r.map((n,i)=>ru(n,i,l)):[]},Q6=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}]}]}}),e4=(a,l)=>a==null?void 0:a.map(r=>{for(const n in l)if(n===(r==null?void 0:r.prop))return{...r,value:l[n]};return r}),a4=e.defineComponent({__name:"index",props:{compType:String,comp:Object,target:{type:String,default:"alone"},optionItems:Array},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref([]);e.watch(()=>r.compType,c=>{var g;const u=Q6(r==null?void 0:r.optionItems),m=c?(g=u[c==null?void 0:c.toUpperCase()])==null?void 0:g[r==null?void 0:r.target]:[];i.value=m==null?void 0:m.map(y=>{for(const[d,D]of Object.entries((r==null?void 0:r.comp)||{}))if((y==null?void 0:y.prop)===d)return{...y,value:D};return y})},{immediate:!0});const o=c=>pl.getComponent(c),p=c=>{var u,m;(c==null?void 0:c.prop)==="layout"&&(c==null?void 0:c.value)==="horizontal"?i.value=(u=i.value)==null?void 0:u.map(g=>{var y;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(y=g==null?void 0:g.options)==null?void 0:y.map(d=>({...d,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 y;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(y=g==null?void 0:g.options)==null?void 0:y.map(d=>({...d,disabled:!1}))}:(g==null?void 0:g.prop)==="isGridLayout"?{...g,disabled:!1}:g}),n("change",{target:r==null?void 0:r.target,styleConfigs:i.value,prop:c==null?void 0:c.prop})};return(c,u)=>{const m=e.resolveComponent("el-col"),g=e.resolveComponent("el-row");return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,y=>(e.openBlock(),e.createBlock(g,{class:"style-row",key:y==null?void 0:y.prop},{default:e.withCtx(()=>[e.createVNode(m,{span:6,class:"style-row-title"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(y==null?void 0:y.label)+":",1)]),_:2},1024),e.createVNode(m,{span:18,style:{display:"flex"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o(y.type)),{modelValue:y.value,"onUpdate:modelValue":d=>y.value=d,content:y==null?void 0:y.options,optionUrl:y==null?void 0:y.optionUrl,disabled:y==null?void 0:y.disabled,activeText:y==null?void 0:y.activeText,inactiveText:y==null?void 0:y.inactiveText,onChange:d=>p(y)},null,40,["modelValue","onUpdate:modelValue","content","optionUrl","disabled","activeText","inactiveText","onChange"]))]),_:2},1024)]),_:2},1024))),128)}}}),l4=pr._export_sfc(a4,[["__scopeId","data-v-da01b651"]]),r4=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 r=a,n=l,i=[{required:!0,message:"输入不能为空",trigger:"blur"}],o=e.ref([]),p=j=>j==null?void 0:j.reduce((O,E)=>(O[E==null?void 0:E.prop]=E==null?void 0:E.rule,O),{}),c=e.computed(()=>({formRules:p(o.value),buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"保存",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]})),u=e.ref([]),m=e.ref(""),g=(j,O,E)=>{var b;let _=[];(r==null?void 0:r.activeTabName)==="任务配置"?(_=[{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:O}]},{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:"暂停"}]}],o.value=[{prop:"任务名称",rule:i},{prop:"任务关键词",rule:i},{prop:"执行任务",rule:i},{prop:"执行动作",rule:i},{prop:"执行交互",rule:i}]):(r==null?void 0:r.activeTabName)==="任务关联"&&(_=[{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=r==null?void 0:r.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:"暂停"}]}],o.value=[{prop:"关联名称",rule:i},{prop:"关联状态",rule:i},{prop:"关联形式",rule:i},{prop:"关联任务集合",rule:i}]);let x;return E&&(E==null?void 0:E.length)>0?x=[..._,...y(j,O,E)]:x=_,x},y=(j,O,E)=>{const _=[{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?_==null?void 0:_.filter(x=>E==null?void 0:E.includes(x==null?void 0:x.prop)):_},d=(j,O)=>{var S,I,R,re,X,me,ue,U,W;const E=((X=(re=(R=(I=(S=r==null?void 0:r.comp)==null?void 0:S.compData)==null?void 0:I.find(Z=>(Z==null?void 0:Z.key)==="header"))==null?void 0:R.contents)==null?void 0:re.filter(Z=>(Z==null?void 0:Z.label)!=="操作"))==null?void 0:X.map(Z=>({value:Z==null?void 0:Z.prop,label:Z.label})))||[],_=/button/i,x=((W=(U=(ue=(me=r==null?void 0:r.comp)==null?void 0:me.compData)==null?void 0:ue.filter(Z=>_.test(Z==null?void 0:Z.key)))==null?void 0:U.flatMap(Z=>Z==null?void 0:Z.contents))==null?void 0:W.map(Z=>({value:Z==null?void 0:Z.label,label:Z.label})))||[],b=g(E,x,j);u.value=O?e4(b,O):b,j&&(j==null?void 0:j.length)>0&&o.value.push(...j==null?void 0:j.map(Z=>({prop:Z,rule:i})))};e.onMounted(()=>{d(null,r==null?void 0:r.extendItem)});const D=j=>{const O=j==null?void 0:j[m.value];if(m.value==="执行任务"){if(!(O!=null&&O.join("/")))return;const E=O==null?void 0:O.join("/");d(E==="统计/统计规则/自定义"?["统计算法源","统计是否获取错误集"]:E==="进度设置/进度条"?["进度关键词"]:null,j)}},w=j=>{n("change",{target:r==null?void 0:r.target,extendConfigs:j})},q=(j,O)=>{m.value=O==null?void 0:O.changeProp,D(j)},A=j=>{n("onButtonClick",j)};return(j,O)=>(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,key:u.value,isStartJustify:!1,isEnableWrap:!1,formRules:c.value.formRules,buttonValue:c.value.buttonValue,onChange:w,onBlurChange:q,onOnButtonClick:A},null,8,["rowContents","formRules","buttonValue"]))}}),n4=pr._export_sfc(r4,[["__scopeId","data-v-4b39853f"]]),i4={};function o4(a,l){return null}const t4=pr._export_sfc(i4,[["render",o4]]),s4={class:"form-operate-content"},c4={class:"form-operate-item"},u4={class:"operate-title"},d4={class:"operate-content"},p4={class:"fix-content"},f4={class:"fix-button"},h4={class:"operate-title"},v4={class:"operate-content"},m4={class:"fix-content"},y4={class:"fix-button"},g4={style:{display:"flex","justify-content":"space-between"}},b4={class:"form-content"},k4={class:"dialog-footer"},x4={class:"form-content"},w4={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(!1),o=e.ref([]),p=e.ref([]),c=e.ref(!1),u=e.ref([]),m=e.ref([]),g=e.ref(""),y=e.ref(!1),d=e.ref(0),D=e.ref([]),w=e.ref([]),q=(U,W)=>{if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="selectRelateType"){const Z=W==null?void 0:W.optionUrl;return(Z==null?void 0:Z.selectRelateType)||W[U.key]}if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="menuSelect"){const Z=W==null?void 0:W.optionUrl;return(Z==null?void 0:Z.menuSelect)||W[U.key]}if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="groupSelect"){const Z=W==null?void 0:W.optionUrl;return(Z==null?void 0:Z.groupSelect)||W[U.key]}if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="originalContent")return(W==null?void 0:W.value)||W[U.key];if((W==null?void 0:W.type)=="Select"&&(U==null?void 0:U.key)==="multiple"){const Z=W[U.key];return fc(Z)?Z:U.default}return(U==null?void 0:U.label)==="类型"&&W[U.key]===""?"Input":(U==null?void 0:U.key)==="isFormColHidden"&&!W[U.key]?!1:W[U.key]},A=async U=>{var ae,ve,ze,te,N,se;i.value=!0;let W=[];const Z=await((ze=(ve=(ae=le.FormContent)==null?void 0:ae.find(G=>(G==null?void 0:G.key)===((U==null?void 0:U.type)===""?"Input":U==null?void 0:U.type)))==null?void 0:ve.value)==null?void 0:ze.value)??((N=(te=le.FormContent)==null?void 0:te.find(G=>(G==null?void 0:G.key)===((U==null?void 0:U.type)===""?"Input":U==null?void 0:U.type)))==null?void 0:N.value);if(Z==null||Z.forEach(G=>{d.value++,W.push({label:G==null?void 0:G.label,name:G==null?void 0:G.label,type:G.type,prop:G==null?void 0:G.prop,value:q(G,U),id:d.value,contents:G==null?void 0:G.options,width:(U==null?void 0:U.width)??1})}),U!=null&&U.menuSelect&&((se=U==null?void 0:U.menuSelect)==null?void 0:se.length)>0){const G=await le.menuToContentType(U==null?void 0:U.menuSelect);W=W==null?void 0:W.map(fe=>((fe==null?void 0:fe.name)==="组信息选项"&&(fe.contents=G),fe))}g.value=U==null?void 0:U.id,o.value=await le.selectToBase(le.formToOptionsContents(W)),p.value=await le.selectToBase(le.formToOptionsContents(W))},j=U=>{var Z;c.value=!0;let W=[];(Z=le.FormButton)==null||Z.forEach(ae=>{d.value++,W.push({label:ae==null?void 0:ae.label,name:ae==null?void 0:ae.label,type:ae.type,value:(ae==null?void 0:ae.label)==="类型"&&U[ae.key]===""?"normal":U[ae.key],id:d.value,contents:ae==null?void 0:ae.options})}),D.value=W,w.value=W,g.value=U==null?void 0:U.id};e.watch(()=>y.value,()=>{var W,Z;let U=M.cloneDeep(r.originalItemContents);(W=M.cloneDeep(r.originalItemContents))!=null&&W.find(ae=>(ae==null?void 0:ae.key)==="enableWrap")?U=(Z=M.cloneDeep(r.originalItemContents))==null?void 0:Z.map(ae=>((ae==null?void 0:ae.key)==="enableWrap"&&(ae.contents=!y.value),ae)):U.push({key:"enableWrap",contents:!y.value}),n("change",U)},{deep:!0});const O=()=>{var Z,ae,ve,ze,te;D.value=w.value;let U={};if(g.value!==""?U.id=g.value:(d.value++,U.id="id"+d.value),(Z=D.value)==null||Z.forEach(N=>{var G;const se=(G=le.FormButton)==null?void 0:G.find(fe=>(fe==null?void 0:fe.label)===(N==null?void 0:N.label));se&&(U[se.key]=N.value)}),(ae=u.value)!=null&&ae.find(N=>N.id===U.id))u.value=(ve=u.value)==null?void 0:ve.map(N=>(N.id===U.id&&(N=U),N));else{let N=M.cloneDeep(u.value);u.value||(u.value=[]),N.push(U),u.value=N}c.value=!1,g.value="";let W=M.cloneDeep(r.originalItemContents);(ze=M.cloneDeep(r.originalItemContents))!=null&&ze.find(N=>(N==null?void 0:N.key)==="formButton")?W=(te=M.cloneDeep(r.originalItemContents))==null?void 0:te.map(N=>((N==null?void 0:N.key)==="formButton"&&(N.contents=u.value),N)):W.push({key:"formButton",contents:u.value}),n("change",W)},E=U=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var W,Z;m.value=(W=M.cloneDeep(m.value))==null?void 0:W.filter(ae=>(ae==null?void 0:ae.id)!==(U==null?void 0:U.id)),n("change",(Z=M.cloneDeep(r.originalItemContents))==null?void 0:Z.map(ae=>((ae==null?void 0:ae.key)==="formContent"&&(ae.contents=m.value),ae))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},_=U=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var W,Z;u.value=(W=M.cloneDeep(u.value))==null?void 0:W.filter(ae=>(ae==null?void 0:ae.id)!==(U==null?void 0:U.id)),n("change",(Z=M.cloneDeep(r.originalItemContents))==null?void 0:Z.map(ae=>((ae==null?void 0:ae.key)==="formButton"&&(ae.contents=u.value),ae))),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=()=>{var W;c.value=!0;let U=[];(W=le.FormButton)==null||W.forEach(Z=>{d.value++,U.push({label:Z==null?void 0:Z.label,name:Z==null?void 0:Z.label,type:Z.type,value:(Z==null?void 0:Z.label)==="类型"?"normal":"",id:d.value,contents:Z==null?void 0:Z.options})}),D.value=U,w.value=U},b=()=>{var W,Z,ae;i.value=!0;let U=[];(ae=(Z=(W=le.FormContent)==null?void 0:W.find(ve=>(ve==null?void 0:ve.key)==="Input"))==null?void 0:Z.value)==null||ae.forEach(ve=>{d.value++,U.push({label:ve==null?void 0:ve.label,name:ve==null?void 0:ve.label,type:ve.type,value:(ve==null?void 0:ve.label)==="类型"?"Input":"",id:d.value,contents:ve==null?void 0:ve.options})}),o.value=U,p.value=U},S=U=>{let W=M.cloneDeep(w.value);W=W==null?void 0:W.map(Z=>(Z.value=U==null?void 0:U[Z.name],Z)),w.value=W},I=U=>{const W=U.find(ve=>(ve==null?void 0:ve.name)==="类型");if((W==null?void 0:W.value)!="Select")return;const Z=U.find(ve=>(ve==null?void 0:ve.name)==="多选"),ae=U.find(ve=>(ve==null?void 0:ve.name)==="初始值");Z!=null&&Z.value&&To.isString(ae.value)&&(ae.value=[ae.value]),!(Z!=null&&Z.value)&&!To.isString(ae.value)&&(ae.value="")},R=async U=>{var W,Z,ae,ve,ze,te,N,se,G,fe,we,_e;if((U==null?void 0:U.类型)!==((Z=(W=p.value)==null?void 0:W.find(qe=>(qe==null?void 0:qe.label)==="类型"))==null?void 0:Z.value)){let qe=[];const ra=await((ze=(ve=(ae=le.FormContent)==null?void 0:ae.find(P=>(P==null?void 0:P.key)===((U==null?void 0:U.类型)===""?"Input":U==null?void 0:U.类型)))==null?void 0:ve.value)==null?void 0:ze.value)?await((fe=(G=(se=le.FormContent)==null?void 0:se.find(P=>(P==null?void 0:P.key)===((U==null?void 0:U.类型)===""?"Input":U==null?void 0:U.类型)))==null?void 0:G.value)==null?void 0:fe.value):(N=(te=le.FormContent)==null?void 0:te.find(P=>(P==null?void 0:P.key)===((U==null?void 0:U.类型)===""?"Input":U==null?void 0:U.类型)))==null?void 0:N.value;if(ra==null||ra.forEach(P=>{var Me,Le;d.value++;const Ke=nd(P==null?void 0:P.default)?(U==null?void 0:U[P.label])??P.value??"":P==null?void 0:P.default;qe.push({label:P==null?void 0:P.label,name:P==null?void 0:P.label,type:P.type,value:Ke,prop:P==null?void 0:P.prop,id:d.value,contents:P==null?void 0:P.options,width:((Le=(Me=p.value)==null?void 0:Me[0])==null?void 0:Le.width)??1})}),U!=null&&U.菜单选项&&((we=U==null?void 0:U.菜单选项)==null?void 0:we.length)>0){const P=await le.menuToContentType(U==null?void 0:U.菜单选项);qe=qe==null?void 0:qe.map(Ke=>((Ke==null?void 0:Ke.name)==="组信息选项"&&(Ke.contents=P),Ke))}I(qe),p.value=await le.selectToBase(M.cloneDeep(qe)),o.value=await le.selectToBase(M.cloneDeep(qe))}else{let qe=M.cloneDeep(p.value);if(qe=qe==null?void 0:qe.map(ra=>(ra.value=U==null?void 0:U[ra.name],ra)),U!=null&&U.菜单选项&&((_e=U==null?void 0:U.菜单选项)==null?void 0:_e.length)>0){const ra=await le.menuToContentType(U==null?void 0:U.菜单选项);qe=qe==null?void 0:qe.map(P=>((P==null?void 0:P.name)==="组信息选项"&&(P.contents=ra),P))}qe=le.formToOptionsContents(qe),I(qe),p.value=await le.selectToBase(M.cloneDeep(qe))}},re=U=>{U||(o.value=p.value)},X=async U=>{await R(U),o.value=p.value},me=Fl.debounce(async()=>{var ae,ve,ze,te,N,se,G,fe,we,_e,qe,ra;o.value=p.value;let U={};U.width=((ve=(ae=o.value)==null?void 0:ae[0])==null?void 0:ve.width)??1,g.value!==""?U.id=g.value:(d.value++,U.id="id"+d.value);let W=await((N=(te=(ze=le.FormContent)==null?void 0:ze.find(P=>{var Ke,Me;return(P==null?void 0:P.key)===(((Me=(Ke=o.value)==null?void 0:Ke.find(Le=>(Le==null?void 0:Le.label)==="类型"))==null?void 0:Me.value)??"label")}))==null?void 0:te.value)==null?void 0:N.value)??((G=(se=le.FormContent)==null?void 0:se.find(P=>{var Ke,Me;return(P==null?void 0:P.key)===(((Me=(Ke=o.value)==null?void 0:Ke.find(Le=>(Le==null?void 0:Le.label)==="类型"))==null?void 0:Me.value)??"label")}))==null?void 0:G.value);if((fe=o.value)==null||fe.forEach(P=>{const Ke=W==null?void 0:W.find(Me=>(Me==null?void 0:Me.label)===(P==null?void 0:P.label));Ke&&(U[Ke.key]=P.value)}),U.width=U.width?U.width:1,U.key=U==null?void 0:U.label,U.isFormColHidden=U==null?void 0:U.isFormColHidden,(we=m.value)!=null&&we.find(P=>P.id===U.id))m.value=(_e=m.value)==null?void 0:_e.map(P=>(P.id===U.id&&(P=U),P));else{let P=M.cloneDeep(m.value);P.push(U),m.value=P}m.value=m.value.map(({id:P,...Ke})=>Ke),i.value=!1,g.value="";let Z=M.cloneDeep(r.originalItemContents);(qe=M.cloneDeep(r.originalItemContents))!=null&&qe.find(P=>(P==null?void 0:P.key)==="formContent")?Z=(ra=M.cloneDeep(r.originalItemContents))==null?void 0:ra.map(P=>((P==null?void 0:P.key)==="formContent"&&(P.contents=m.value),P)):Z.push({key:"formContent",contents:m.value}),n("change",Z)},300),ue=()=>{i.value=!1,c.value=!1,g.value="",p.value=[],w.value=[]};return e.watch(()=>r.originalItemContents,()=>{var W,Z,ae,ve,ze,te;if(!r.originalItemContents||r.originalItemContents.length===0)return;const U=M.cloneDeep(r.originalItemContents);m.value=((W=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="formContent"))==null?void 0:W.contents)??[],u.value=((Z=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="formButton"))==null?void 0:Z.contents)??[],y.value=(ae=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="enableWrap"))!=null&&ae.contents?!((ve=U==null?void 0:U.find(N=>(N==null?void 0:N.key)==="enableWrap"))!=null&&ve.contents):!0,m.value=(ze=M.cloneDeep(m.value))==null?void 0:ze.map((N,se)=>{var fe;let G=N;return G.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=((fe=N==null?void 0:N.options)==null?void 0:fe.length)===0?(N==null?void 0:N.contents)??"":N==null?void 0:N.options,G}),m.value=le.formToOptionsContents(m.value),u.value=(te=u.value)==null?void 0:te.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}),(U,W)=>{const Z=e.resolveComponent("svg-icon"),ae=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",s4,[e.createElementVNode("div",c4,[e.createElementVNode("div",u4,[W[2]||(W[2]=e.createElementVNode("div",null,e.toDisplayString("表单内容"),-1)),e.createVNode(ae,{class:"icon-content",id:"themeButton",onClick:b},{icon:e.withCtx(()=>[e.createVNode(Z,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[W[1]||(W[1]=e.createElementVNode("div",null,e.toDisplayString("新增"),-1))]),_:1,__:[1]})]),e.createElementVNode("div",d4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(ve,ze)=>(e.openBlock(),e.createElementBlock("div",{key:ze},[e.createElementVNode("div",p4,[e.createElementVNode("div",null,e.toDisplayString(ve.label),1),e.createElementVNode("div",f4,[e.createVNode(Z,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>A(ve)},null,8,["onClick"]),e.createVNode(Z,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>E(ve)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",h4,[W[4]||(W[4]=e.createElementVNode("div",null,e.toDisplayString("表单按钮"),-1)),e.createVNode(ae,{class:"icon-content",id:"themeButton",onClick:x},{icon:e.withCtx(()=>[e.createVNode(Z,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[W[3]||(W[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",v4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(ve,ze)=>(e.openBlock(),e.createElementBlock("div",{key:ze},[e.createElementVNode("div",m4,[e.createElementVNode("div",null,e.toDisplayString(ve.label),1),e.createElementVNode("div",y4,[e.createVNode(Z,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>j(ve)},null,8,["onClick"]),e.createVNode(Z,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:te=>_(ve)},null,8,["onClick"])])])]))),128))]),W[6]||(W[6]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("表单布局"))],-1)),e.createElementVNode("div",g4,[W[5]||(W[5]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否自动撑宽"),-1)),e.createVNode(pl._sfc_main$1,{modelValue:y.value,"onUpdate:modelValue":W[0]||(W[0]=ve=>y.value=ve)},null,8,["modelValue"])])]),e.createVNode($r.ssDialog,{visible:i.value,onBeforeDestroy:ue,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",b4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:o.value,key:o.value,isEnableWrap:!0,onChange:R,onChangeVisible:re,onBlurChange:X},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",k4,[e.createVNode(ae,{onClick:ue,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>W[7]||(W[7]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[7]}),e.createVNode(ae,{class:"ok-button button",onClick:e.unref(me),id:"themeButton"},{default:e.withCtx(()=>W[8]||(W[8]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[8]},8,["onClick"])])]),_:1},8,["visible"]),e.createVNode($r.ssDialog,{visible:c.value,onBeforeDestroy:ue,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",x4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:D.value,key:D.value,isEnableWrap:!0,onChange:S},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:ue,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:O},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},$s=pr._export_sfc(w4,[["__scopeId","data-v-20850524"]]),_4={class:"step-module content"},S4={class:"module-data"},E4={class:"step-module layout"},C4={class:"form-content"},D4=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=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}]),o=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"标题",prop:"title",type:"input",value:""},{label:"描述",prop:"description",type:"input",value:""}]),p=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),c=e.reactive({visible:!1,width:"40%",title:"步骤条"}),u=e.ref("create"),m=e.ref({}),g=e.ref([]),y=A=>{var j;m.value=A,n("change",(j=w())==null?void 0:j.compData)},d=(A,j)=>{var O,E;switch(A){case"create":(O=o.value)==null||O.forEach(_=>{_.value=""}),u.value="create",c.visible=!0;break;case"update":(E=o.value)==null||E.forEach(_=>{_.value=j[_==null?void 0:_.prop]}),u.value="update",c.visible=!0;break;case"delete":g.value.splice(j,1),u.value="delete";break}},D=A=>{var j,O,E;if((A==null?void 0:A.buttonName)==="确认"){const _=M.cloneDeep(A==null?void 0:A.content);switch(Object.keys(_).forEach(x=>{_[x]===""&&delete _[x]}),u.value){case"create":g.value.push({..._,index:((j=g.value)==null?void 0:j.length)+1});break;case"update":g.value=(O=g.value)==null?void 0:O.map(x=>x.index===(_==null?void 0:_.index)?{...x,title:_==null?void 0:_.title,description:_==null?void 0:_.description}:x);break}n("change",(E=w())==null?void 0:E.compData),c.visible=!1}else c.visible=!1},w=()=>({comp:"Step",compData:[{key:"stepList",contents:g.value},{key:"stepConfig",contents:m.value}]}),q=()=>{c.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,A=>{var j,O;A&&(m.value=((j=A==null?void 0:A.find(E=>E.key==="stepConfig"))==null?void 0:j.contents)??{},g.value=((O=A==null?void 0:A.find(E=>E.key==="stepList"))==null?void 0:O.contents)??[])},{immediate:!0}),(A,j)=>{const O=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",_4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=_=>d("create"))},{icon:e.withCtx(()=>[e.createVNode(O,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",S4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(_,x)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:x},[e.createElementVNode("span",null,e.toDisplayString(_==null?void 0:_.title),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>d("update",{..._,index:x+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>d("delete",x)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",E4,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(pl.ssForm,{rowContents:i.value,onChange:y},null,8,["rowContents"])])]),e.createVNode($r.ssDialog,{visible:c.visible,title:c.title,onBeforeDestroy:q,width:c.width},{default:e.withCtx(()=>[e.createElementVNode("div",C4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:o.value,key:o.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:p.value,onOnButtonClick:D},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),T4=pr._export_sfc(D4,[["__scopeId","data-v-7dbd17f2"]]),B4={class:"step-module content"},N4={class:"module-data"},A4={class:"step-module layout"},z4={class:"form-content"},M4=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref("create"),o=e.ref({}),p=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}]),u=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:"时间线"}),y=A=>{var j;o.value=A,n("change",(j=w())==null?void 0:j.compData)},d=(A,j)=>{var O,E;switch(A){case"create":(O=u.value)==null||O.forEach(_=>{_.value=""}),i.value="create",g.visible=!0;break;case"update":(E=u.value)==null||E.forEach(_=>{_.value=j[_==null?void 0:_.prop]}),i.value="update",g.visible=!0;break;case"delete":p.value.splice(j,1),i.value="delete";break}},D=A=>{var j,O,E,_;if((A==null?void 0:A.buttonName)==="确认"){const x=M.cloneDeep(A==null?void 0:A.content);switch(Object.keys(x).forEach(b=>{x[b]===""&&delete x[b]}),i.value){case"create":(O=p.value)==null||O.push({...x,index:((j=p.value)==null?void 0:j.length)+1});break;case"update":p.value=(E=p.value)==null?void 0:E.map(b=>b.index===(x==null?void 0:x.index)?{...b,content:x==null?void 0:x.content,timestamp:x==null?void 0:x.timestamp}:b);break}n("change",(_=w())==null?void 0:_.compData),g.visible=!1}else g.visible=!1},w=()=>({comp:"TimeLine",compData:[{key:"timeLineList",contents:p.value},{key:"timeLineConfig",contents:o.value}]}),q=()=>{g.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,A=>{var j,O;A&&(o.value=((j=A==null?void 0:A.find(E=>E.key==="timeLineConfig"))==null?void 0:j.contents)??{},p.value=((O=A==null?void 0:A.find(E=>E.key==="timeLineList"))==null?void 0:O.contents)??[])},{immediate:!0}),(A,j)=>{const O=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",B4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=_=>d("create"))},{icon:e.withCtx(()=>[e.createVNode(O,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",N4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(_,x)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:x},[e.createElementVNode("span",null,e.toDisplayString(_==null?void 0:_.content),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>d("update",{..._,index:x+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>d("delete",x)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",A4,[j[5]||(j[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(pl.ssForm,{rowContents:c.value,onChange:y},null,8,["rowContents"])])]),e.createVNode($r.ssDialog,{visible:g.visible,title:g.title,onBeforeDestroy:q,width:g.width},{default:e.withCtx(()=>[e.createElementVNode("div",z4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,key:u.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:m.value,onOnButtonClick:D},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),I4=pr._export_sfc(M4,[["__scopeId","data-v-39ffc861"]]),O4={};function L4(a,l){return e.openBlock(),e.createElementBlock("div")}const R4=pr._export_sfc(O4,[["render",L4]]),$4={class:"extra-content"},V4={key:0},F4={key:1},P4={class:"dialog-footer"},j4={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},emits:["change"],setup(a,{emit:l}){const r=a,n=e.ref(0),i=e.ref(),o=e.ref(),p=l,c=e.ref(!1),u=e.ref({}),m=e.ref({}),g=e.ref();e.watch(()=>[r.itemData],()=>{var _;const E=M.cloneDeep(r.itemData);i.value=(_=M.cloneDeep(E))==null?void 0:_.map(x=>{var b;if(x.key==="extra"){let S=[];(b=x.value)==null||b.forEach(I=>{var R;S.push((R=Object.values(I))==null?void 0:R[0])}),x.value=S}return x})},{deep:!0,immediate:!0});const y=(E,_,x,b)=>{var I;let S={};((I=E==null?void 0:E[0])==null?void 0:I.contents)==="详情"&&(c.value=!0,S[_]=E,o.value=E==null?void 0:E.filter(R=>(R==null?void 0:R.key)!=="tableContentName"),u.value=S,m.value=x,g.value=b.id)},d=E=>{var R,re,X,me;const _=(re=(R=Object.values(M.cloneDeep(u.value)))==null?void 0:R[0])==null?void 0:re.filter(ue=>(ue==null?void 0:ue.key)==="tableContentName"),x=(me=(X=Object.values(M.cloneDeep(u.value)))==null?void 0:X[0])==null?void 0:me.filter(ue=>(ue==null?void 0:ue.key)!=="tableContentName"),b=x==null?void 0:x.map((ue,U)=>{var W;return U===E.index&&(ue==null?void 0:ue.comp)==="Table"&&(ue.compData=(W=ue.compData)==null?void 0:W.map(Z=>{var ae,ve;return(Z==null?void 0:Z.key)==="tableContents"&&(Z.contents=(ve=(ae=E.content)==null?void 0:ae.map(ze=>{let te={};for(let N in ze)N!=="id"&&(te[N]=ze[N]);return te}))==null?void 0:ve.map(ze=>Object.values(ze))),Z})),ue});b.unshift(_==null?void 0:_[0]);let S=M.cloneDeep(u.value),I={};for(let ue in S)I[ue]=b;u.value=I},D=()=>{c.value=!1,u.value={},m.value={},g.value=void 0,n.value++},w=E=>{var R,re,X,me;const _=(re=(R=Object.values(M.cloneDeep(u.value)))==null?void 0:R[0])==null?void 0:re.filter(ue=>(ue==null?void 0:ue.key)==="tableContentName"),x=(me=(X=Object.values(M.cloneDeep(u.value)))==null?void 0:X[0])==null?void 0:me.filter(ue=>(ue==null?void 0:ue.key)!=="tableContentName"),b=x==null?void 0:x.map((ue,U)=>(U===E.index&&(ue.compData=E.contents),ue));b.unshift(_==null?void 0:_[0]);let S=M.cloneDeep(u.value),I={};for(let ue in S)I[ue]=b;u.value=I},q=()=>{var _,x;let E={};for(let b in m.value)b===((_=Object.keys(u.value))==null?void 0:_[0])?E[b]=(x=Object.values(u.value))==null?void 0:x[0]:E[b]=m.value[b];p("change",{buttonName:"编辑",index:g.value,singleContent:E},"methodData"),c.value=!1,u.value={},m.value={},g.value=void 0},A=()=>{c.value=!1,u.value={},m.value={},g.value=void 0},j=E=>{p("change",E,"methodData")},O=E=>$i(E);return(E,_)=>{const x=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",$4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(b,S)=>(e.openBlock(),e.createElementBlock("div",{key:n.value},[(b==null?void 0:b.key)==="extra"?(e.openBlock(),e.createElementBlock("div",V4)):(e.openBlock(),e.createElementBlock("div",F4,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(O(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:y,onChange:j},null,40,["itemData","childItemData","index"]))]))]))),128)),e.createVNode($r.ssDialog,{visible:c.value,onBeforeDestroy:A},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,(b,S)=>(e.openBlock(),e.createElementBlock("div",{key:S,class:"extra-dialog"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(O(b.comp)),{itemData:b==null?void 0:b.compData,onChange:d,childItemData:b==null?void 0:b.itemChildData,key:S,onContentChange:w,index:(b==null?void 0:b.id)??S,class:"extra-component"},null,40,["itemData","childItemData","index"]))]))),128))]),footer:e.withCtx(()=>[e.createElementVNode("div",P4,[e.createVNode(x,{class:"cancel-button footer-button",onClick:D,id:"themeBorderButton"},{default:e.withCtx(()=>_[0]||(_[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(x,{class:"confirm-button footer-button",onClick:q,id:"themeButton"},{default:e.withCtx(()=>_[1]||(_[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},H4=pr._export_sfc(j4,[["__scopeId","data-v-2d9c5ab2"]]),U4={key:0,class:"method-content"},q4={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},setup(a){const l=e.ref([]),r=le.useOriginalState(M.pinia),{originalPath:n}=M.storeToRefs(r),i=a,o=e.ref(!1),p=e.ref(),c=le.useTableComp(M.pinia),{multipleTableConst:u}=M.storeToRefs(c),m=M.useModelComp(M.pinia),g=e.ref(!1),y=M.useMenuState(M.pinia),d=M.useLoginState(M.pinia),{itemData:D,isEdit:w,routeToChildPath:q,tableViewContents:A,lockingPage:j,payloadTypes:O}=M.storeToRefs(m),{activeMenuPath:E,platform:_,childMenu:x}=M.storeToRefs(y),{loginUserInfo:b}=M.storeToRefs(d),S=e.ref(!1),I=async()=>{var te,N;(te=l.value)!=null&&te.find(se=>(se==null?void 0:se.buttonName)==="保存")&&await Z((N=l.value)==null?void 0:N.find(se=>(se==null?void 0:se.buttonName)==="保存")),await le.onSaveBack()};e.watch(()=>D.value,async()=>{w.value==="view"&&!S.value&&await ze(M.cloneDeep(i.itemData)),S.value=!1},{deep:!0});const R=()=>{o.value=!1,p.value=void 0},re=te=>te.map(N=>{const se={};for(const G in N){const fe=N[G];if(G.includes(u.value)){const we=G.split(u.value);let _e=se;we.forEach((qe,ra)=>{ra===we.length-1?_e[qe]=fe:(_e[qe]||(_e[qe]={}),_e=_e[qe])})}else se[G]=fe}return se}),X=async(te,N,se=[])=>{var fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge;let G=(fe=M.cloneDeep(N))==null?void 0:fe.filter($=>($==null?void 0:$.comp)!=="methodButton");if(te!=null&&te.includes("[")){let $=(P=(ra=(qe=(_e=(we=M.cloneDeep(te))==null?void 0:we.split("["))==null?void 0:_e[1])==null?void 0:qe.split("]"))==null?void 0:ra[0])==null?void 0:P.split(":"),V="";if($!=null&&$[0]){let ee=(Ke=G==null?void 0:G.find(ce=>(ce==null?void 0:ce.name)===($==null?void 0:$[0])))==null?void 0:Ke.compData;if(!ee){let ce=(Me=te==null?void 0:te.split("["))==null?void 0:Me[0],he=await le.getItemData(ce,sessionStorage.getItem("systemKey"),"",!1,"","",se);ee=(Le=he==null?void 0:he.find(pa=>(pa==null?void 0:pa.name)===($==null?void 0:$[0])))==null?void 0:Le.compData}ee==null||ee.forEach(ce=>{var he,pa,ia,Ve,ya,Ca;if((ce==null?void 0:ce.key)==="formContent")(he=ce==null?void 0:ce.contents)==null||he.forEach(Ce=>{var Fa;(Ce==null?void 0:Ce.key)===($==null?void 0:$[1])&&(Array.isArray(Ce==null?void 0:Ce.value)?V=Ce==null?void 0:Ce.value:V=(Fa=Ce==null?void 0:Ce.value)==null?void 0:Fa.toString())});else if((ce==null?void 0:ce.key)==="tableContents"){let Ce=[],Fa=(pa=ee==null?void 0:ee.find(fa=>(fa==null?void 0:fa.key)==="header"))==null?void 0:pa.contents,Ta=($==null?void 0:$[1])??"";if(Fa!=null&&Fa.every(fa=>Array.isArray(fa))){let fa=le.getColumnChild((ya=Fa==null?void 0:Fa[0])==null?void 0:ya.filter(ja=>(ja==null?void 0:ja.label)!=="操作"));(Ca=ce.contents)==null||Ca.forEach(ja=>{let sa={};ja=ja==null?void 0:ja.filter(Pe=>!(Pe!=null&&Pe.id)),fa==null||fa.forEach((Pe,ma)=>{let Qe=ja[ma];typeof ja[ma]=="number"&&(Qe=ja[ma].toString()),(Ta===""||Ta===Pe.prop)&&(sa[Pe.prop]=Qe)}),Ce.push(sa)}),Ce=re(Ce)}else{let fa=(ia=Fa==null?void 0:Fa.map(ja=>ja==null?void 0:ja.label))==null?void 0:ia.filter(ja=>ja!=="操作");(Ve=ce.contents)==null||Ve.forEach(ja=>{let sa={};ja=ja==null?void 0:ja.filter(Pe=>!(Pe!=null&&Pe.id)),fa==null||fa.forEach((Pe,ma)=>{let Qe=ja[ma];typeof ja[ma]=="number"&&(Qe=ja[ma].toString()),(Ta===""||Ta===Pe)&&(sa[Pe]=Qe)}),Ce.push(sa)})}V=Ce}})}return V}else if(te!=null&&te.includes("/")){let $={};return(Ie=M.cloneDeep(G))==null||Ie.forEach((V,ee)=>{var ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne;if((V==null?void 0:V.comp)==="Table"){let We=Array.isArray((pa=(he=(ce=V==null?void 0:V.compData)==null?void 0:ce.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:he.contents)==null?void 0:pa[0])?(Ca=(ya=(Ve=(ia=V==null?void 0:V.compData)==null?void 0:ia.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:Ve.contents)==null?void 0:ya[0])==null?void 0:Ca.some(Be=>Be==null?void 0:Be.children):[],na=(Ta=(Fa=(Ce=V==null?void 0:V.compData)==null?void 0:Ce.find(Be=>(Be==null?void 0:Be.key)==="tableContents"))==null?void 0:Fa.contents)==null?void 0:Ta.map(Be=>(Be!=null&&Be.find(Ye=>Ye==null?void 0:Ye.id)&&(Be=Be.slice(1)),Be)),va=(ma=(Pe=(sa=(ja=(fa=V==null?void 0:V.compData)==null?void 0:fa.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:ja.contents)==null?void 0:sa[0])==null?void 0:Pe[0])==null?void 0:ma.label,Ae=(Oe=(Qe=V==null?void 0:V.compData)==null?void 0:Qe.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:Oe.contents;if(We)(We==null?void 0:We.length)===0?$[V.name]=$!=null&&$[V.name]?$[V.name]:le.tableToForm(na,Ae):$[va]=le.tableToForm(na,Ae);else{const Be=[];Ae=Ae.slice(1,Ae.length-1),Ae==null||Ae.forEach((Ye,Ee)=>{na==null||na.forEach(ye=>{Be.push({key:Ye.label+ye[0],value:ye[Ee+1]})})}),$["form"+ee]=Be}}else{const We=(ne=($e=V.compData)==null?void 0:$e.find(va=>(va==null?void 0:va.key)==="formContent"))==null?void 0:ne.contents;$!=null&&$.form||($.form=[]);const na=[];We==null||We.forEach(va=>{va.key!==""&&(va={key:(va==null?void 0:va.key)??(va==null?void 0:va.label),value:va==null?void 0:va.value},na.push(va))}),$.form=[...na,...M.cloneDeep($==null?void 0:$.form)]}}),$}else{if(te==="createInsofDataApi"){let $=(de=M.cloneDeep(N))==null?void 0:de[0];return $={comp:(De=M.cloneDeep($))==null?void 0:De.comp,compData:(Xe=M.cloneDeep($))==null?void 0:Xe.compData,name:(Ea=M.cloneDeep($))==null?void 0:Ea.name,isShow:(Ge=M.cloneDeep($))==null?void 0:Ge.isShow},{key:{type:"structure",systemKey:sessionStorage.getItem("systemKey"),parentTable:"",pageKey:E.value},value:{pageData:$}}}return te}},me=async(te,N,se)=>{var we,_e,qe;let G=await le.getItemData(N,sessionStorage.getItem("systemKey"),""),fe=G==null?void 0:G.find(ra=>(ra==null?void 0:ra.name)===(se==null?void 0:se[0]));if(fe){if((fe==null?void 0:fe.comp)==="Table"){let ra={};for(let De in M.cloneDeep(te))M.cloneDeep(te)[De]!=="loginUser"?ra[De]=M.cloneDeep(te)[De]:ra[De]=((we=b.value)==null?void 0:we.account)||((_e=b.value)==null?void 0:_e.账号);let P=[],Ke=ra;Array.isArray(te)||(Ke=[ra]),Ke==null||Ke.forEach(De=>{P.push({[De[se[1]]]:De})});let Me=[],Le=P==null?void 0:P.map(De=>{var Xe;return(Xe=Object.keys(De))==null?void 0:Xe[0]});G==null||G.forEach(De=>{var Xe;(De==null?void 0:De.name)===(se==null?void 0:se[0])&&((Xe=De==null?void 0:De.compData)==null||Xe.forEach(Ea=>{var Ge;(Ea==null?void 0:Ea.key)==="tableContents"&&((Ge=Ea==null?void 0:Ea.contents)==null||Ge.forEach($=>{$!=null&&$.some(V=>Le.includes(V))&&Me.push({[$.find(V=>V.id).id]:$.find(V=>Le.includes(V))})}))}))});let Ie=Me==null?void 0:Me.map(De=>{var Xe;return(Xe=Object.keys(De))==null?void 0:Xe[0]}),de=[];if(Ie==null||Ie.forEach(De=>{var Ge;let Xe=(Ge=Me==null?void 0:Me.find($=>{var V;return((V=Object.keys($))==null?void 0:V[0].toString())===De.toString()}))==null?void 0:Ge[De],Ea=P==null?void 0:P.find($=>{var V;return((V=Object.keys($))==null?void 0:V[0])===Xe});de.push({id:parseInt(De),value:{tableData:Ea[Xe]}})}),(de==null?void 0:de.length)>0)return de}else if((fe==null?void 0:fe.comp)==="Form"){let ra=M.cloneDeep(fe);ra.compData=(qe=ra.compData)==null?void 0:qe.map(Me=>{var Le;return(Me==null?void 0:Me.key)==="formContent"&&(Me.contents=(Le=Me.contents)==null?void 0:Le.map(Ie=>((Ie==null?void 0:Ie.key)===(se==null?void 0:se[1])&&(Ie.value=(te==null?void 0:te[Ie==null?void 0:Ie.prop])||te),Ie))),Me});let P={};for(let Me in ra)Me!=="id"&&(P[Me]=ra[Me]);let Ke=[];if(Ke.push({id:fe==null?void 0:fe.id,keyType:se==null?void 0:se[1],value:{pageData:P}}),(Ke==null?void 0:Ke.length)>0)return Ke}}},ue=async(te,N,se)=>{var we,_e,qe,ra,P,Ke,Me,Le,Ie,de;let G=await le.getItemData(N,sessionStorage.getItem("systemKey"),""),fe=G==null?void 0:G.find(De=>(De==null?void 0:De.name)===(se==null?void 0:se[0]));if(fe){if((fe==null?void 0:fe.comp)==="Table"){let De={};for(let Xe in M.cloneDeep(te))M.cloneDeep(te)[Xe]!=="loginUser"?De[Xe]=M.cloneDeep(te)[Xe]:De[Xe]=((we=b.value)==null?void 0:we.account)||((_e=b.value)==null?void 0:_e.账号);await Kr.createInsofDataApi({key:{type:"data",pageKey:N,tableId:fe==null?void 0:fe.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:De}})}else if((fe==null?void 0:fe.comp)==="Form"){let De=M.cloneDeep(fe),Xe=Object.keys(te),Ea="";(ra=(qe=M.cloneDeep(De))==null?void 0:qe.compData)==null||ra.forEach(he=>{var pa,ia;(he==null?void 0:he.key)==="formContent"&&((ia=(pa=M.cloneDeep(he))==null?void 0:pa.contents)==null||ia.forEach(Ve=>{var ya;Xe.includes(Ve==null?void 0:Ve.key)&&(Ve==null?void 0:Ve.value)===((ya=b.value)==null?void 0:ya.姓名)&&(Ea=Ve==null?void 0:Ve.key)}))});let Ge=[];(P=Object.values(te[Ea]))==null||P.forEach(he=>{he!=null&&he.includes("(")&&Ge.push(he)}),Ge=[...new Set(Ge)];const $=Ge==null?void 0:Ge.map(async he=>{var Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e;let pa="";(ja=(fa=(Ta=(Fa=(Ce=(Ca=M.cloneDeep(he))==null?void 0:Ca.split("("))==null?void 0:Ce[1])==null?void 0:Fa.split(")"))==null?void 0:Ta[0])==null?void 0:fa.split(":"))==null||ja.forEach(ne=>{pa=pa===""?pa+ne.replaceAll("'",""):pa+"/"+ne.replaceAll("'","")});let ia=[];($e=(Oe=(Qe=(ma=(Pe=(sa=M.cloneDeep(he))==null?void 0:sa.split("<"))==null?void 0:Pe[1])==null?void 0:ma.split(">"))==null?void 0:Qe[0])==null?void 0:Oe.split(":"))==null||$e.forEach(ne=>{ia.push(ne.replaceAll("'",""))});const Ve=await le.getItemData(pa,sessionStorage.getItem("systemKey"),"");let ya="";return Ve==null||Ve.forEach(ne=>{var We;ne.name===(ia==null?void 0:ia[0])&&((We=ne==null?void 0:ne.compData)==null||We.forEach(na=>{var va;(na==null?void 0:na.key)==="formContent"&&((va=na.contents)==null||va.forEach(Ae=>{(Ae==null?void 0:Ae.key)===(ia==null?void 0:ia[1])&&(ya=Ae==null?void 0:Ae.value)}))}))}),{[he]:ya}}),V=await Promise.all($);De.compData=(Me=(Ke=M.cloneDeep(De))==null?void 0:Ke.compData)==null?void 0:Me.map(he=>{var pa,ia;return(he==null?void 0:he.key)==="formContent"&&(he.contents=(ia=(pa=M.cloneDeep(he))==null?void 0:pa.contents)==null?void 0:ia.map(Ve=>{var ya,Ca,Ce,Fa;return(ya=te[Ea])!=null&&ya[Ve==null?void 0:Ve.key]&&(te[Ea][Ve==null?void 0:Ve.key].includes("(")?Ve.value=(Ca=V==null?void 0:V.find(Ta=>{var fa;return((fa=Object.keys(Ta))==null?void 0:fa[0])===te[Ea][Ve==null?void 0:Ve.key]}))==null?void 0:Ca[te[Ea][Ve==null?void 0:Ve.key]]:Ve.value=(Fa=(Ce=M.cloneDeep(te))==null?void 0:Ce[Ea])==null?void 0:Fa[Ve==null?void 0:Ve.key]),Ve})),he});const ee=await Kr.getInsofDataApi({key:{type:"structure",pageKey:N,systemKey:sessionStorage.getItem("systemKey")}});let ce="";((Le=ee==null?void 0:ee.data)==null?void 0:Le.type)==="success"&&((de=(Ie=ee==null?void 0:ee.data)==null?void 0:Ie.result)==null||de.forEach(he=>{var pa,ia;((ia=(pa=he==null?void 0:he.value)==null?void 0:pa.pageData)==null?void 0:ia.name)===(se==null?void 0:se[0])&&(ce=he.id)}),await Kr.updateInsofDataApi({id:ce,value:{pageData:De}}))}}},U=(te,N="",se={})=>{for(const[G,fe]of Object.entries(te)){const we=N?`${N}.${G}`:G;fe!==null&&typeof fe=="object"&&!Array.isArray(fe)&&Object.prototype.toString.call(fe)!=="[object Date]"?U(fe,we,se):se[we]=fe}return se},W=async(te,N,se,G)=>{var _e,qe,ra,P,Ke,Me,Le,Ie,de,De,Xe,Ea,Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa;let fe=await le.getItemData(N,sessionStorage.getItem("systemKey"),""),we=fe==null?void 0:fe.find(Ta=>(Ta==null?void 0:Ta.name)===(se==null?void 0:se[0]));if(we){if(!(se!=null&&se[1])&&(we==null?void 0:we.comp)==="Table"){let Ta={},fa=[],ja=(qe=(_e=we==null?void 0:we.compData)==null?void 0:_e.find(ma=>(ma==null?void 0:ma.key)==="header"))==null?void 0:qe.contents;ja!=null&&ja.every(ma=>Array.isArray(ma))?fa=(P=le.getColumnChild((ra=ja==null?void 0:ja[0])==null?void 0:ra.filter(ma=>(ma==null?void 0:ma.label)!=="操作")))==null?void 0:P.map(ma=>ma==null?void 0:ma.prop):fa=ja==null?void 0:ja.map(ma=>ma==null?void 0:ma.label);for(let ma in M.cloneDeep(te))if(M.cloneDeep(te)[ma]!=="loginUser"){let Qe=U(M.cloneDeep(te)[ma]),Oe={};for(let $e in Qe)if(fa!=null&&fa.find(ne=>ne===$e))Oe[$e]=Qe[$e];else if(fa!=null&&fa.find(ne=>(ne==null?void 0:ne.toUpperCase())===($e==null?void 0:$e.toUpperCase()))){let ne=fa==null?void 0:fa.find(We=>(We==null?void 0:We.toUpperCase())===($e==null?void 0:$e.toUpperCase()));Oe[ne]=Qe[$e]}Ta[ma]=Oe}else Ta[ma]=((Ke=b.value)==null?void 0:Ke.account)||((Me=b.value)==null?void 0:Me.账号);let sa=await Kr.getInsofDataApi({keyLikes:{tableId:we==null?void 0:we.id}});if(((Ie=(Le=sa==null?void 0:sa.data)==null?void 0:Le.result)==null?void 0:Ie.length)>0){let ma=(De=(de=sa==null?void 0:sa.data)==null?void 0:de.result)==null?void 0:De.map(Qe=>Qe==null?void 0:Qe.id);(ma==null?void 0:ma.length)>0&&await Kr.batchDeleteInsofDataApi({ids:ma})}let Pe=[];if((Xe=we==null?void 0:we.compData)!=null&&Xe.find(ma=>(ma==null?void 0:ma.key)==="pageColumn")&&(($=(Ge=(Ea=we==null?void 0:we.compData)==null?void 0:Ea.find(ma=>(ma==null?void 0:ma.key)==="pageColumn"))==null?void 0:Ge.contents)!=null&&$.includes("["))){const ma=await Kr.getInsofDataApi({id:we==null?void 0:we.tableId});let Qe=((he=(ce=(ee=(V=ma==null?void 0:ma.data)==null?void 0:V.result)==null?void 0:ee[0])==null?void 0:ce.key)==null?void 0:he.pageKey)??"";(pa=Object.values(Ta))==null||pa.forEach(Oe=>{Pe.push({key:{type:"data",pageKey:Qe,tableId:we==null?void 0:we.tableId,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Oe}})})}else(ia=Object.values(Ta))==null||ia.forEach(ma=>{Pe.push({key:{type:"data",pageKey:N,tableId:we==null?void 0:we.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:ma}})});(Pe==null?void 0:Pe.length)>0&&await Kr.batchAddInsofDataApi({dataList:Pe})}else if(!(se!=null&&se[1])&&(we==null?void 0:we.comp)==="Form"){let Ta=M.cloneDeep(we);Ta.compData=(ya=(Ve=M.cloneDeep(Ta))==null?void 0:Ve.compData)==null?void 0:ya.map(sa=>{var Pe,ma;return(sa==null?void 0:sa.key)==="formContent"&&(sa.contents=(ma=(Pe=M.cloneDeep(sa))==null?void 0:Pe.contents)==null?void 0:ma.map(Qe=>{var Oe,$e;return(Oe=M.cloneDeep(te))!=null&&Oe[Qe==null?void 0:Qe.key]&&(Qe.value=($e=M.cloneDeep(te))==null?void 0:$e[Qe==null?void 0:Qe.key]),Qe})),sa});const fa=await Kr.getInsofDataApi({key:{type:"structure",pageKey:N,systemKey:sessionStorage.getItem("systemKey")}});let ja="";((Ca=fa==null?void 0:fa.data)==null?void 0:Ca.type)==="success"&&((Fa=(Ce=fa==null?void 0:fa.data)==null?void 0:Ce.result)==null||Fa.forEach(sa=>{var Pe,ma;((ma=(Pe=sa==null?void 0:sa.value)==null?void 0:Pe.pageData)==null?void 0:ma.name)===(se==null?void 0:se[0])&&(ja=sa.id)}),await Kr.updateInsofDataApi({id:ja,value:{pageData:Ta}}))}}},Z=async te=>{var N,se,G,fe,we,_e,qe,ra,P,Ke,Me,Le,Ie,de;y.setImportLoading(!0);try{if(te.api){let De=new WeakMap,Xe=await le.getItemData((x==null?void 0:x.value)===""?E.value:x==null?void 0:x.value,sessionStorage.getItem("systemKey"),"",!1,"","",De),Ea="";if(Xe=Xe==null?void 0:Xe.map(ia=>{var Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe;if((ia==null?void 0:ia.comp)==="Form")ia.compData=(Ve=ia.compData)==null?void 0:Ve.map(Oe=>{var $e;return(Oe==null?void 0:Oe.key)==="formContent"&&(Oe.contents=($e=Oe.contents)==null?void 0:$e.map(ne=>{var We;if((ne==null?void 0:ne.value)===""&&(ne==null?void 0:ne.type)==="Select"){let na=le.judgeContents((We=M.cloneDeep(ne))==null?void 0:We.optionUrl,De);ne.value=ne.value||na}return ne})),Oe});else if((ia==null?void 0:ia.comp)==="Table"&&(ya=ia.compData)!=null&&ya.find(Oe=>(Oe==null?void 0:Oe.key)==="pageColumn")){let Oe=(Ce=(Ca=ia.compData)==null?void 0:Ca.find(na=>(na==null?void 0:na.key)==="pageColumn"))==null?void 0:Ce.contents,$e=((Ta=(Fa=ia.compData)==null?void 0:Fa.find(na=>(na==null?void 0:na.key)==="pageGroup"))==null?void 0:Ta.contents)??"",ne=(sa=(ja=(fa=Oe==null?void 0:Oe.split("["))==null?void 0:fa[1])==null?void 0:ja.split("]"))==null?void 0:sa[0];Ea=((Pe=Oe==null?void 0:Oe.split("["))==null?void 0:Pe[0])+((Qe=(ma=A.value)==null?void 0:ma.find(na=>(na==null?void 0:na.key)===ne))==null?void 0:Qe.value)}return ia}),!(Ea===""||Ea==="")){const ia=await le.getItemData(Ea,sessionStorage.getItem("systemKey"),"",!1,"","",De);Xe=Xe==null?void 0:Xe.map(Ve=>{var ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e;if((Ve==null?void 0:Ve.comp)==="Table"&&(ya=Ve.compData)!=null&&ya.find(ne=>(ne==null?void 0:ne.key)==="pageColumn")){let ne=(Ce=(Ca=Ve.compData)==null?void 0:Ca.find(Be=>(Be==null?void 0:Be.key)==="pageColumn"))==null?void 0:Ce.contents,We=((Ta=(Fa=Ve.compData)==null?void 0:Fa.find(Be=>(Be==null?void 0:Be.key)==="pageGroup"))==null?void 0:Ta.contents)??"",na=(sa=(ja=(fa=ne==null?void 0:ne.split("["))==null?void 0:fa[1])==null?void 0:ja.split("]"))==null?void 0:sa[0],va=((Pe=ne==null?void 0:ne.split("["))==null?void 0:Pe[0])+((Qe=(ma=A.value)==null?void 0:ma.find(Be=>(Be==null?void 0:Be.key)===na))==null?void 0:Qe.value),Ae=(Oe=ia==null?void 0:ia.find(Be=>(Be==null?void 0:Be.name)===(We===""?i==null?void 0:i.compName:We)))==null?void 0:Oe.compData;Ve.compData=($e=Ve.compData)==null?void 0:$e.map(Be=>{var Ye;return(Be==null?void 0:Be.key)==="tableContents"&&(Be.contents=(Ye=Ae==null?void 0:Ae.find(Ee=>(Ee==null?void 0:Ee.key)==="tableContents"))==null?void 0:Ye.contents),Be})}return Ve})}let Ge={};if(((se=(N=te==null?void 0:te.extraValues)==null?void 0:N.input)==null?void 0:se.length)>0){const ia=(fe=(G=te==null?void 0:te.extraValues)==null?void 0:G.input)==null?void 0:fe.map(async Ve=>{var ya;ae!=null&&ae.find(Ca=>Ca===Ve)?Ge=await X(Ve,Xe):Ge[Object.keys(Ve)[0]]=await X((ya=Object.values(Ve))==null?void 0:ya[0],Xe,De)});await Promise.all(ia)}else Ge=await X("/",Xe);let $=!1;(_e=(we=te==null?void 0:te.extraValues)==null?void 0:we.output)==null||_e.forEach(ia=>{var Ve,ya;(ya=(Ve=Object.values(ia))==null?void 0:Ve[0])!=null&&ya.includes(".doc")&&($=!0)});let V;if($){const ia=M.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});V=await Ja.axios.post(te.api,Ge,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{ia.close()})}else V=await Ja.axios.post(te.api,Ge,{headers:{"Content-Type":"application/json"}});let ee=(Ke=(P=(ra=(qe=M.cloneDeep(te))==null?void 0:qe.extraValues)==null?void 0:ra.output)==null?void 0:P.map(ia=>{var Ve,ya,Ca,Ce,Fa,Ta,fa,ja,sa,Pe,ma,Qe,Oe,$e,ne,We;if(!((ya=(Ve=Object.values(ia))==null?void 0:Ve[0])!=null&&ya.includes(".doc"))){let na=(Pe=(sa=(ja=(Ce=M.cloneDeep((Ca=Object.values(ia))==null?void 0:Ca[0]))==null?void 0:Ce.split("["))==null?void 0:ja[((fa=(Ta=M.cloneDeep((Fa=Object.values(ia))==null?void 0:Fa[0]))==null?void 0:Ta.split("["))==null?void 0:fa.length)-1])==null?void 0:sa.split("]"))==null?void 0:Pe[0],va=na==null?void 0:na.split(":"),Ae=(Oe=M.cloneDeep((ma=Object.values(ia))==null?void 0:ma[0]))==null?void 0:Oe.substring(0,M.cloneDeep((Qe=Object.values(ia))==null?void 0:Qe[0]).lastIndexOf("["));if(Ae=(ne=M.cloneDeep(Ae))==null?void 0:ne.slice(0,(($e=M.cloneDeep(Ae))==null?void 0:$e.length)-1),Ae!=null&&Ae.includes("[")){let Be="";if((We=le.contentTransArrayToAll(Ae,"/"))==null||We.forEach(Ye=>{var Ee,ye,$a,wl,Qa,Pl,gl;if(!(Ye!=null&&Ye.includes("[")))Be=Be===""?Be+Ye.replaceAll("/",""):Be+"/"+Ye.replaceAll("/","");else{let jl=M.cloneDeep(Ye).slice(1,((Ee=M.cloneDeep(Ye))==null?void 0:Ee.length)-1),al=(Pl=(Qa=(wl=($a=(ye=M.cloneDeep(jl))==null?void 0:ye.split("["))==null?void 0:$a[1])==null?void 0:wl.split("]"))==null?void 0:Qa[0])==null?void 0:Pl.split(":"),Hl="",Wa=(gl=Xe==null?void 0:Xe.find(Gl=>(Gl==null?void 0:Gl.name)===(al==null?void 0:al[0])))==null?void 0:gl.compData;Wa==null||Wa.forEach(Gl=>{var Kl;(Gl==null?void 0:Gl.key)==="formContent"&&((Kl=Gl==null?void 0:Gl.contents)==null||Kl.forEach(Zl=>{(Zl==null?void 0:Zl.key)===(al==null?void 0:al[1])&&(Hl=Zl==null?void 0:Zl.value)}))}),Be=Be===""?Be+Hl.replaceAll("/",""):Be+"/"+Hl.replaceAll("/","")}}),Ae=Be,Ae[(Ae==null?void 0:Ae.length)-1]!=="/")return Ae}}}))==null?void 0:Ke.filter(ia=>ia);ee=[...new Set(M.cloneDeep(ee))];let ce=ee==null?void 0:ee.map(async ia=>{let Ve=await le.getItemData(ia,sessionStorage.getItem("systemKey"),"",!1,"","",De);if((Ve==null?void 0:Ve.length)===0)return await le.getParentContents(ia)});await Promise.all(ce);let he=[],pa=(Ie=(Le=(Me=M.cloneDeep(te))==null?void 0:Me.extraValues)==null?void 0:Le.output)==null?void 0:Ie.map(async ia=>{var ja,sa,Pe,ma,Qe,Oe,$e,ne,We,na,va,Ae,Be,Ye,Ee,ye,$a,wl,Qa,Pl,gl,jl,al,Hl,Wa,Gl,Kl,Zl,Sl,dr,ga,il,fl,Bl,Ha,Sa,ll,Te,oa,Ka,pe,_a,Pa,ul,Ol,ca,Xa,ua,wa,Ba,hl,Fe,bl,tr,xr,Ra,kl,Ml,Oa,aa,Rl,Yr,Jr,vn,en,Ar,Re,lr,Yl,an;if((sa=(ja=Object.values(ia))==null?void 0:ja[0])!=null&&sa.includes(".doc")){var Ve=new Blob([V.data],{type:"application/octet-stream;charset=UTF-8"}),ya=V.headers["content-disposition"],Ca=new RegExp("filename=([^;]+\\.[^\\.;]+);*"),Ce=Ca.exec(ya),Fa=Ce==null?void 0:Ce[1],Ta=document.createElement("a"),fa=window.URL.createObjectURL(Ve);p.value=[{name:Fa,blobUrl:fa}],o.value=!0}else{let Sr=(na=(We=(ne=(ma=M.cloneDeep((Pe=Object.values(ia))==null?void 0:Pe[0]))==null?void 0:ma.split("["))==null?void 0:ne[(($e=(Oe=M.cloneDeep((Qe=Object.values(ia))==null?void 0:Qe[0]))==null?void 0:Oe.split("["))==null?void 0:$e.length)-1])==null?void 0:We.split("]"))==null?void 0:na[0],Jl=Sr==null?void 0:Sr.split(":"),Er=(Be=M.cloneDeep((va=Object.values(ia))==null?void 0:va[0]))==null?void 0:Be.substring(0,M.cloneDeep((Ae=Object.values(ia))==null?void 0:Ae[0]).lastIndexOf("["));if(Er!=null&&Er.includes("[")?Er=(Ee=M.cloneDeep(Er))==null?void 0:Ee.slice(0,((Ye=M.cloneDeep(Er))==null?void 0:Ye.length)-1):Er===""&&(Er=E.value),Er=Er.replaceAll("<","[").replaceAll(">","]"),Er!=null&&Er.includes("[")){let $l="";(ye=le.contentTransArrayToAll(Er,"/"))==null||ye.forEach((nr,Ql)=>{var Ul,Nl,Vr,er,Ur,Br,Tr,gn,Sn,Cn,mn;if(!(nr!=null&&nr.includes("[")))$l=$l===""?$l+nr.replaceAll("/",""):$l+"/"+nr.replaceAll("/","");else{let On="",rn="";(Ul=M.cloneDeep(nr))!=null&&Ul.includes("]")?(On=M.cloneDeep(nr).slice(1,((Nl=M.cloneDeep(nr))==null?void 0:Nl.length)-1),rn=(Tr=(Br=(Ur=(er=(Vr=M.cloneDeep(On))==null?void 0:Vr.split("["))==null?void 0:er[1])==null?void 0:Ur.split("]"))==null?void 0:Br[0])==null?void 0:Tr.split(":")):(On=M.cloneDeep(nr).slice(1,(gn=M.cloneDeep(nr))==null?void 0:gn.length),rn=(Sn=M.cloneDeep(On))==null?void 0:Sn.split("/"));let Dn="",Vn=(Cn=Xe==null?void 0:Xe.find(nn=>(nn==null?void 0:nn.name)===(rn==null?void 0:rn[0])))==null?void 0:Cn.compData;Vn==null||Vn.forEach(nn=>{var Fn;(nn==null?void 0:nn.key)==="formContent"&&((Fn=nn==null?void 0:nn.contents)==null||Fn.forEach(zr=>{(zr==null?void 0:zr.key)===(rn==null?void 0:rn[1])&&(Dn=zr==null?void 0:zr.value)}))}),((mn=le.contentTransArrayToAll(Er,"/"))==null?void 0:mn.length)-1!==Ql?$l=$l===""?$l+Dn.replaceAll("/",""):$l+"/"+Dn.replaceAll("/",""):$l=$l+n.value+Dn.replaceAll("/","")}}),($a=E.value)!=null&&$a.includes($l)?Er=E.value:Er=$l}let Xl=M.cloneDeep((wl=Object.keys(ia))==null?void 0:wl[0]);if(((Qa=V==null?void 0:V.data)==null?void 0:Qa.statusCode)===200||((Pl=V==null?void 0:V.data)==null?void 0:Pl.code)===200){if(((jl=(gl=V==null?void 0:V.data)==null?void 0:gl.data)!=null&&jl[Xl]||(Hl=(al=V==null?void 0:V.data)==null?void 0:al.result)!=null&&Hl[Xl])&&(Jl==null?void 0:Jl.length)===1)return await W(((Gl=(Wa=V==null?void 0:V.data)==null?void 0:Wa.data)==null?void 0:Gl[Xl])||((Zl=(Kl=V==null?void 0:V.data)==null?void 0:Kl.result)==null?void 0:Zl[Xl]),M.cloneDeep(Er),Jl,Ea);if((dr=(Sl=V==null?void 0:V.data)==null?void 0:Sl.data)!=null&&dr[Xl]||(il=(ga=V==null?void 0:V.data)==null?void 0:ga.result)!=null&&il[Xl]){let $l=await me(((Bl=(fl=V==null?void 0:V.data)==null?void 0:fl.data)==null?void 0:Bl[Xl])||((Sa=(Ha=V==null?void 0:V.data)==null?void 0:Ha.result)==null?void 0:Sa[Xl]),M.cloneDeep(Er),Jl);return $l&&(he=[...he,...$l]),$l}else{if(!((ll=V==null?void 0:V.data)!=null&&ll.data)){let $l=await le.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,"","",De);$l=$l==null?void 0:$l.map(Ql=>{var Ul;return(Ql==null?void 0:Ql.name)===(Jl==null?void 0:Jl[0])&&(Ql.compData=(Ul=Ql.compData)==null?void 0:Ul.map(Nl=>{var Vr;return(Nl==null?void 0:Nl.key)==="formContent"&&(Nl.contents=(Vr=Nl.contents)==null?void 0:Vr.map(er=>{var Ur,Br;return(er==null?void 0:er.key)===(Jl==null?void 0:Jl[1])&&(er.value=(Br=(Ur=V==null?void 0:V.data)==null?void 0:Ur.result)==null?void 0:Br[Xl==null?void 0:Xl.replaceAll(":","")]),er})),Nl})),Ql});let nr=[];(Te=$l==null?void 0:$l.filter(Ql=>(Ql==null?void 0:Ql.comp)==="Form"))==null||Te.forEach(async Ql=>{let Ul={};for(let Nl in Ql)Nl!=="id"&&(Ul[Nl]=Ql[Nl]);nr.push({id:Ql==null?void 0:Ql.id,value:{pageData:Ul}})}),(nr==null?void 0:nr.length)>0&&await Kr.batchUpdateInsofDataApi({dataList:nr});return}if((Jl==null?void 0:Jl.length)===1){const $l=(pe=(Ka=(oa=V==null?void 0:V.data)==null?void 0:oa.data)==null?void 0:Ka.path)==null?void 0:pe.path;let nr="";(ca=(Ol=(ul=(Pa=(_a=$l==null?void 0:$l.split("("))==null?void 0:_a[1])==null?void 0:Pa.split(")"))==null?void 0:ul[0])==null?void 0:Ol.split(":"))==null||ca.forEach(Nl=>{var Vr,er;nr=nr===""?nr+((Vr=Nl==null?void 0:Nl.replaceAll("'",""))==null?void 0:Vr.trim()):nr+"/"+((er=Nl==null?void 0:Nl.replaceAll("'",""))==null?void 0:er.trim())});let Ql=[(hl=(Ba=(wa=(ua=(Xa=$l==null?void 0:$l.split("<"))==null?void 0:Xa[1])==null?void 0:ua.split(">"))==null?void 0:wa[0])==null?void 0:Ba.replaceAll("'",""))==null?void 0:hl.trim()],Ul;return(tr=(bl=(Fe=V==null?void 0:V.data)==null?void 0:Fe.data)==null?void 0:bl.data)!=null&&tr[Jl==null?void 0:Jl[0]]?Ul=await W((kl=(Ra=(xr=V==null?void 0:V.data)==null?void 0:xr.data)==null?void 0:Ra.data)==null?void 0:kl[Jl==null?void 0:Jl[0]],nr,Jl,Ea):Ul=await ue((Oa=(Ml=V==null?void 0:V.data)==null?void 0:Ml.data)==null?void 0:Oa.data,nr,Ql,De),Ul}else{const $l=(Yr=(Rl=(aa=V==null?void 0:V.data)==null?void 0:aa.data)==null?void 0:Rl.path)==null?void 0:Yr.path;let nr="";return(Re=(Ar=(en=(vn=(Jr=$l==null?void 0:$l.split("("))==null?void 0:Jr[1])==null?void 0:vn.split(")"))==null?void 0:en[0])==null?void 0:Ar.split(":"))==null||Re.forEach(Ul=>{var Nl,Vr;nr=nr===""?nr+((Nl=Ul==null?void 0:Ul.replaceAll("'",""))==null?void 0:Nl.trim()):nr+"/"+((Vr=Ul==null?void 0:Ul.replaceAll("'",""))==null?void 0:Vr.trim())}),await me((an=(Yl=(lr=V==null?void 0:V.data)==null?void 0:lr.data)==null?void 0:Yl.data)==null?void 0:an[Jl==null?void 0:Jl[0]],nr,Jl)}}}}});if(await Promise.all(pa),(he==null?void 0:he.length)>0){let ia=[];he==null||he.forEach(Ca=>{ia!=null&&ia.find(Ce=>{var Fa,Ta,fa,ja;return((Ta=(Fa=Ce==null?void 0:Ce.value)==null?void 0:Fa.pageData)==null?void 0:Ta.name)===((ja=(fa=Ca==null?void 0:Ca.value)==null?void 0:fa.pageData)==null?void 0:ja.name)})||ia.push(Ca)});let Ve=[];ia==null||ia.forEach(Ca=>{var Ta,fa,ja,sa;let Ce=M.cloneDeep(Ca);Ce.value.pageData.compData=(Ta=Ce.value.pageData.compData)==null?void 0:Ta.map(Pe=>{var ma;return(Pe==null?void 0:Pe.key)==="formContent"&&(Pe.contents=(ma=Pe.contents)==null?void 0:ma.map(Qe=>{var $e,ne,We,na;let Oe=($e=M.cloneDeep(he))==null?void 0:$e.find(va=>(va==null?void 0:va.keyType)===(Qe==null?void 0:Qe.key));if(Oe){let va=(na=(We=(ne=Oe.value.pageData.compData)==null?void 0:ne.find(Ae=>(Ae==null?void 0:Ae.key)==="formContent"))==null?void 0:We.contents)==null?void 0:na.find(Ae=>(Ae==null?void 0:Ae.key)===(Qe==null?void 0:Qe.key));Qe.value=va==null?void 0:va.value}return Qe})),Pe}),Ve.push({id:Ce==null?void 0:Ce.id,value:Ce==null?void 0:Ce.value});let Fa=[];(sa=(ja=(fa=Ce==null?void 0:Ce.value)==null?void 0:fa.pageData)==null?void 0:ja.compData)==null||sa.forEach(Pe=>{var ma;(Pe==null?void 0:Pe.key)==="formContent"&&((ma=Pe==null?void 0:Pe.contents)==null||ma.forEach(Qe=>{var Oe,$e,ne,We,na,va;if(($e=(Oe=Qe==null?void 0:Qe.optionUrl)==null?void 0:Oe.menuSelect)!=null&&$e.find(Ae=>Ae==null?void 0:Ae.includes("[")))if(Fa!=null&&Fa.find(Ae=>{var Be,Ye,Ee;return((Be=Ae==null?void 0:Ae.key)==null?void 0:Be.join(","))===((Ee=(Ye=Qe==null?void 0:Qe.optionUrl)==null?void 0:Ye.menuSelect)==null?void 0:Ee.join(","))})){let Ae=(ne=Fa==null?void 0:Fa.find(Be=>{var Ye,Ee,ye;return((Ye=Be==null?void 0:Be.key)==null?void 0:Ye.join(","))===((ye=(Ee=Qe==null?void 0:Qe.optionUrl)==null?void 0:Ee.menuSelect)==null?void 0:ye.join(","))}))==null?void 0:ne.value;Ae.push({key:Qe==null?void 0:Qe.prop,groups:(We=Qe==null?void 0:Qe.optionUrl)==null?void 0:We.groupSelect,value:Qe==null?void 0:Qe.value}),Fa=Fa==null?void 0:Fa.map(Be=>{var Ye,Ee,ye;return((Ye=Be==null?void 0:Be.key)==null?void 0:Ye.join(","))===((ye=(Ee=Qe==null?void 0:Qe.optionUrl)==null?void 0:Ee.menuSelect)==null?void 0:ye.join(","))&&(Be.value=Ae),Be})}else Fa.push({key:(na=Qe==null?void 0:Qe.optionUrl)==null?void 0:na.menuSelect,value:[{key:Qe==null?void 0:Qe.prop,groups:(va=Qe==null?void 0:Qe.optionUrl)==null?void 0:va.groupSelect,value:Qe==null?void 0:Qe.value}]})}))}),(Fa==null?void 0:Fa.length)>0&&(Fa=Fa==null?void 0:Fa.map(Pe=>{var Qe;let ma="";return(Qe=Pe==null?void 0:Pe.key)==null||Qe.forEach(Oe=>{var $e;if(!(Oe!=null&&Oe.includes("[")))ma=ma===""?ma+Oe:ma+"/"+Oe;else{let ne="",We=($e=Oe==null?void 0:Oe.replaceAll("[","").replaceAll("]",""))==null?void 0:$e.split(":");Xe==null||Xe.forEach(na=>{var va;(na==null?void 0:na.name)===(We==null?void 0:We[0])&&((va=na==null?void 0:na.compData)==null||va.forEach(Ae=>{var Be;(Ae==null?void 0:Ae.key)==="formContent"&&((Be=Ae==null?void 0:Ae.contents)==null||Be.forEach(Ye=>{(Ye==null?void 0:Ye.prop)===(We==null?void 0:We[1])&&(ne=Ye==null?void 0:Ye.value)}))}))}),ma=ma+n.value+ne}}),Pe.key=ma,Pe})),Fa==null||Fa.forEach(Pe=>{var $e,ne,We;let ma=($e=De[Pe.key])==null?void 0:$e.find(na=>{var va,Ae,Be,Ye,Ee,ye,$a;return((Ae=(va=na==null?void 0:na.value)==null?void 0:va.pageData)==null?void 0:Ae.name)===((Ee=(Ye=(Be=Pe==null?void 0:Pe.value)==null?void 0:Be[0])==null?void 0:Ye.groups)==null?void 0:Ee[0])&&(($a=(ye=na==null?void 0:na.value)==null?void 0:ye.pageData)==null?void 0:$a.name)!==void 0}),Qe=ma==null?void 0:ma.id,Oe=(ne=ma==null?void 0:ma.value)==null?void 0:ne.pageData;Oe.compData=(We=Oe.compData)==null?void 0:We.map(na=>{var va;return(na==null?void 0:na.key)==="formContent"&&(na.contents=(va=na.contents)==null?void 0:va.map(Ae=>{var Ye;let Be=(Ye=Pe.value)==null?void 0:Ye.find(Ee=>(Ee==null?void 0:Ee.key)===(Ae==null?void 0:Ae.prop));return Be&&(Ae.value=Be.value),Ae})),na}),Ve.push({id:Qe,value:{pageData:Oe}})})});let ya=(de=M.cloneDeep(he))==null?void 0:de[0];(Ve==null?void 0:Ve.length)>0&&await Kr.batchUpdateInsofDataApi({dataList:Ve})}m.setFreshContent(!0)}y.setImportLoading(!1)}catch{Ja.ElMessage.error("方法执行错误,请查看方法!"),y.setImportLoading(!1)}S.value=!0},ae=["createInsofDataApi"],ve=Fl.debounce(async te=>{Z(te)},100),ze=async te=>{var _e,qe,ra;const N=M.cloneDeep(te);let se,G=new WeakMap;te!=null&&te[0].path&&(se=await(N==null?void 0:N.map(async(P,Ke)=>{var Ge,$,V,ee,ce,he,pa,ia,Ve,ya,Ca,Ce,Fa,Ta,fa,ja;const Le=(Ge=G[P==null?void 0:P.path])==null?void 0:Ge.filter(sa=>{var Pe;return((Pe=sa==null?void 0:sa.key)==null?void 0:Pe.type)==="data"});let Ie="";const de=await le.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,G);Le==null||Le.forEach(sa=>{var Pe,ma,Qe,Oe,$e;((ma=(Pe=sa==null?void 0:sa.value)==null?void 0:Pe.tableData)==null?void 0:ma.算法名称)===((Qe=N==null?void 0:N[Ke])==null?void 0:Qe.method)&&(Ie=($e=(Oe=sa==null?void 0:sa.value)==null?void 0:Oe.tableData)==null?void 0:$e.算法体)});const De=await le.getItemData(P==null?void 0:P.path,sessionStorage.getItem("systemKey"),"",!1,[],!1,G);let Xe="",Ea=(ce=(ee=(V=($=De==null?void 0:De[0])==null?void 0:$.compData)==null?void 0:V.find(sa=>(sa==null?void 0:sa.key)==="header"))==null?void 0:ee.contents)==null?void 0:ce.findIndex(sa=>(sa==null?void 0:sa.prop)==="算法体");return(pa=(he=De==null?void 0:De[0])==null?void 0:he.compData)==null||pa.forEach(sa=>{var Pe;(sa==null?void 0:sa.key)==="tableContents"&&((Pe=sa==null?void 0:sa.contents)==null||Pe.forEach(ma=>{ma!=null&&ma.find(Qe=>Qe===(P==null?void 0:P.method))&&(Xe=ma[Ea])}))}),{buttonName:((ia=N==null?void 0:N[Ke])==null?void 0:ia.method)||((Ca=(ya=(Ve=Le==null?void 0:Le[0])==null?void 0:Ve.value)==null?void 0:ya.tableData)==null?void 0:Ca.算法名称),api:(Ie===""?(Ta=(Fa=(Ce=Le==null?void 0:Le[0])==null?void 0:Ce.value)==null?void 0:Fa.tableData)==null?void 0:Ta.算法体:Ie)||Xe,content:de==null?void 0:de.filter(sa=>sa.comp!=="methodButton"),extraContent:(fa=M.cloneDeep(P.value))==null?void 0:fa.slice(1),methodName:(P==null?void 0:P.path)??"",extraValues:(ja=N==null?void 0:N[Ke])==null?void 0:ja.data}})));const fe=N==null?void 0:N.map(async P=>{var De,Xe,Ea,Ge,$,V;const Ke=(De=resAll.data.result)==null?void 0:De.filter(ee=>{var ce,he,pa;return((ce=ee==null?void 0:ee.key)==null?void 0:ce.parentTable)===""&&((he=ee==null?void 0:ee.key)==null?void 0:he.type)==="method"&&((pa=ee==null?void 0:ee.key)==null?void 0:pa.methodName)===ee.method}),Me=Ke==null?void 0:Ke[0],Le=(Xe=resAll.data.result)==null?void 0:Xe.filter(ee=>{var ce,he;return((ce=ee==null?void 0:ee.key)==null?void 0:ce.type)==="methodData"&&((he=ee==null?void 0:ee.key)==null?void 0:he.tableId)===(Me==null?void 0:Me.id)}),Ie=await le.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,G),de=Le==null?void 0:Le[0];return{buttonName:(Ea=Me==null?void 0:Me.key)==null?void 0:Ea.methodKey,api:($=(Ge=de==null?void 0:de.value)==null?void 0:Ge.tableData)==null?void 0:$[0],content:Ie==null?void 0:Ie.filter(ee=>ee.comp!=="methodButton"),extraContent:(V=M.cloneDeep(P.value))==null?void 0:V.slice(1),methodName:(P==null?void 0:P.method)??""}}),we=(_e=te==null?void 0:te[0])!=null&&_e.path&&((qe=te==null?void 0:te[0])==null?void 0:qe.path)!==""?await Promise.all(se):await Promise.all(fe);l.value=we==null?void 0:we.filter(P=>P==null?void 0:P.extraContent),(ra=l.value)==null||ra.forEach(P=>{var Ke;P.api===""&&((Ke=P.content)==null||Ke.forEach(Me=>{var Le;Me.comp=="Table"&&m.setExtraContents(le.methodTableToContent(Me.compData,(Le=P.extraContent)==null?void 0:Le[0]))}))})};return e.watch(()=>i.itemData,async()=>{w.value=="view"&&!S.value&&await ze(M.cloneDeep(i.itemData)),S.value=!1},{immediate:!0,deep:!0}),(te,N)=>{var se,G,fe;return e.unref(w)!=="edit"?(e.openBlock(),e.createElementBlock("div",U4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((se=l.value)==null?void 0:se.filter(we=>(we==null?void 0:we.buttonName)!=="保存"),we=>{var _e;return e.openBlock(),e.createElementBlock("div",null,[we.api!==""?(e.openBlock(),e.createBlock(e.unref(ms._sfc_main),{key:0,disabled:e.unref(j)===e.unref(E)&&!((_e=we==null?void 0:we.buttonName)!=null&&_e.includes("预览")),class:"calculator-content",modelValue:we.buttonName,onClickTrigger:qe=>e.unref(ve)(we),loading:g.value},null,8,["disabled","modelValue","onClickTrigger","loading"])):e.createCommentVNode("",!0)])}),256)),e.createElementVNode("div",null,[e.unref(q)!==""&&((fe=e.unref(E))==null?void 0:fe[((G=e.unref(E))==null?void 0:G.length)-1])!==e.unref(n)?(e.openBlock(),e.createBlock(e.unref(ms._sfc_main),{key:0,class:"calculator-content",onClickTrigger:I,modelValue:"保存"})):e.createCommentVNode("",!0)]),o.value?(e.openBlock(),e.createBlock(pl.ssFilePreview,{key:0,fileDataList:p.value,onDestroy:R},null,8,["fileDataList"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},W4=pr._export_sfc(q4,[["__scopeId","data-v-063aa9af"]]),G4={};function K4(a,l){return" 567 "}const Y4=pr._export_sfc(G4,[["render",K4]]),J4={class:"module content"},X4={class:"module data"},Z4={class:"module layout"},Q4={class:"form-content"},e2=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.reactive({visible:!1,width:"40%",title:"签名配置"}),o=e.ref("create"),p=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}]),u=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([]),y=()=>({comp:"Signature",compData:[{key:"signTypeList",contents:g.value},{key:"signConfig",contents:m.value}]}),d=A=>{var j;m.value=M.cloneDeep(A),n("change",(j=y())==null?void 0:j.compData)},D=A=>{var j,O;if((A==null?void 0:A.buttonName)==="确认"){const E=M.cloneDeep(A==null?void 0:A.content);switch(o.value){case"create":g.value.push({...E,index:((j=g.value)==null?void 0:j.length)+1});break}n("change",(O=y())==null?void 0:O.compData),i.visible=!1}else i.visible=!1},w=(A,j)=>{var O,E;switch(A){case"create":(O=u.value)==null||O.forEach(_=>{_.value=""}),o.value="create",i.visible=!0;break;case"update":(E=u.value)==null||E.forEach(_=>{_.value=j[_==null?void 0:_.prop]}),o.value="update",i.visible=!0;break;case"delete":g.value.splice(j,1),o.value="delete";break}},q=()=>{i.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,A=>{var j,O;A&&(m.value=((j=A==null?void 0:A.find(E=>E.key==="signConfig"))==null?void 0:j.contents)??{},g.value=((O=A==null?void 0:A.find(E=>E.key==="signTypeList"))==null?void 0:O.contents)??[])},{immediate:!0}),(A,j)=>{const O=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",J4,[j[2]||(j[2]=e.createElementVNode("h4",{class:"module-title"},"签名类型",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:j[0]||(j[0]=_=>w("create"))},{icon:e.withCtx(()=>[e.createVNode(O,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[j[1]||(j[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",X4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(_,x)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:x},[e.createElementVNode("span",null,e.toDisplayString(_==null?void 0:_.label),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>w("update",{..._,index:x+1})},{default:e.withCtx(()=>j[3]||(j[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>w("delete",x)},{default:e.withCtx(()=>j[4]||(j[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",Z4,[e.createVNode(pl.ssForm,{rowContents:c.value,onChange:d},null,8,["rowContents"])])]),e.createVNode($r.ssDialog,{visible:i.visible,title:i.title,onBeforeDestroy:q,width:i.width},{default:e.withCtx(()=>[e.createElementVNode("div",Q4,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:u.value,key:u.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:p.value,onOnButtonClick:D},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),a2=pr._export_sfc(e2,[["__scopeId","data-v-487e0536"]]),l2=e.defineComponent({__name:"index",props:{stepConfig:{type:Object,default:{}},stepList:{type:Array,default:()=>[]}},emits:["clickStep","clickTrigger","changeTrigger"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(0),o=e.computed(()=>{var y,d;return(y=r==null?void 0:r.stepConfig)!=null&&y.allowTrigger?i.value:(d=r==null?void 0:r.stepConfig)==null?void 0:d.active}),p=(y,d)=>{i.value=d-1,n("clickStep",y,d)};e.onMounted(()=>{var y;n("clickStep",(y=r==null?void 0:r.stepList)==null?void 0:y[0],0)});const c=y=>pl.getComponent(y),u=()=>{var d;const y=(d=r==null?void 0:r.stepList)==null?void 0:d.find((D,w)=>w+1===o.value);return console.log("findStep",y),y?y==null?void 0:y.children:[]},m=y=>{n("clickTrigger",y)},g=y=>{n("changeTrigger",y)};return(y,d)=>{var q,A,j,O,E;const D=e.resolveComponent("el-step"),w=e.resolveComponent("el-steps");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(w,{direction:(q=a.stepConfig)==null?void 0:q.direction,active:o.value,"finish-status":"success",simple:(A=a.stepConfig)==null?void 0:A.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)=>(e.openBlock(),e.createBlock(D,{key:x,class:"step-item",onClick:b=>p(_,x+1)},{title:e.withCtx(()=>[e.renderSlot(y.$slots,"title",{title:_==null?void 0:_.title},void 0,!0)]),description:e.withCtx(()=>[e.renderSlot(y.$slots,"description",{descriptions:_==null?void 0:_.description},void 0,!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["direction","active","simple","align-center"]),(O=a.stepConfig)!=null&&O.allowTrigger&&((E=a.stepConfig)!=null&&E.active)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(u(),(_,x)=>(e.openBlock(),e.createElementBlock("div",{key:x,class:"step-cont-wrap"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(c(_==null?void 0:_.type)),{modelValue:_.value,"onUpdate:modelValue":b=>_.value=b,onClickTrigger:m,onChangeTrigger:g,content:_==null?void 0:_.content},e.createSlots({_:2},[e.renderList(y.$slots,(b,S)=>({name:S,fn:e.withCtx(I=>[e.renderSlot(y.$slots,S,e.mergeProps({ref_for:!0},I||{}),void 0,!0)])}))]),1064,["modelValue","onUpdate:modelValue","content"]))]))),128)):e.createCommentVNode("",!0)],64)}}}),r2=pr._export_sfc(l2,[["__scopeId","data-v-a30ff621"]]),n2=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]}},emits:["clickStep"],setup(a,{emit:l}){const r=a,n=l,i=e.ref({}),o=e.ref([]),p=(c,u)=>{n("clickStep",c,u)};return e.watch(()=>r==null?void 0:r.itemData,c=>{var y,d,D,w;i.value={direction:"horizontal",simple:!1,alignCenter:!0,allowTrigger:!0};let u=((y=c==null?void 0:c.find(q=>(q==null?void 0:q.key)==="stepName"))==null?void 0:y.contents)??[],m=[];(D=(d=c==null?void 0:c.find(q=>(q==null?void 0:q.key)==="header"))==null?void 0:d.contents)==null||D.forEach(q=>{m.push({label:q==null?void 0:q.label,prop:q==null?void 0:q.prop,name:q==null?void 0:q.prop,type:"text",disabled:!0})});let g=((w=c==null?void 0:c.find(q=>(q==null?void 0:q.key)==="tableContents"))==null?void 0:w.contents)??[];u=u==null?void 0:u.map((q,A)=>{let j=m==null?void 0:m.map(O=>{var E;return{...O,value:(E=g==null?void 0:g[A])==null?void 0:E[O==null?void 0:O.prop]}});return{title:q,description:j}}),o.value=u},{immediate:!0,deep:!0}),(c,u)=>{const m=e.resolveComponent("svg-icon");return e.openBlock(),e.createBlock(r2,{stepConfig:i.value,stepList:o.value,onClickStep:p},{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(pl.ssForm,{ref:"formRef",rowContents:g,showOperator:!0,isEnableWrap:!1,isEdit:!1},null,8,["rowContents"])]),_:1},8,["stepConfig","stepList"])}}}),i2=e.defineComponent({__name:"index",props:{activities:{type:Array,default:()=>[]},timeLineConfig:{type:Object,default:()=>{}}},setup(a){return(l,r)=>{const n=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,(o,p)=>(e.openBlock(),e.createBlock(n,{key:p,timestamp:o.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:o==null?void 0:o.content,timestamp:o==null?void 0:o.timestamp},void 0,!0)]),_:2},1032,["timestamp","placement","center","type","color","size","icon","hollow"]))),128))]),_:3})}}}),o2=pr._export_sfc(i2,[["__scopeId","data-v-4172a886"]]),t2={class:"line-content"},s2={class:"line-time"},c2=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(a){const l=a,r=e.ref({}),n=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,i=>{var o,p;n.value=(o=i==null?void 0:i.find(c=>(c==null?void 0:c.key)==="timeLineList"))==null?void 0:o.contents,r.value=(p=i==null?void 0:i.find(c=>(c==null?void 0:c.key)==="timeLineConfig"))==null?void 0:p.contents},{immediate:!0}),(i,o)=>(e.openBlock(),e.createBlock(o2,{activities:n.value,timeLineConfig:r.value},{content:e.withCtx(({content:p,timestamp:c})=>[e.createElementVNode("span",t2,e.toDisplayString(p),1),e.createElementVNode("span",s2,e.toDisplayString(c),1)]),_:1},8,["activities","timeLineConfig"]))}}),u2=pr._export_sfc(c2,[["__scopeId","data-v-b4d9deed"]]),d2={class:"tabs-content"},p2=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 r=a,n=l,i=e.ref();e.watch(()=>r==null?void 0:r.itemData,()=>{i.value=r==null?void 0:r.itemData},{immediate:!0,deep:!0});const o=d=>{n("change",d)},p=(d,D)=>{n("contentChange",d,D)},c=d=>{n("pageChange",d)},u=d=>{n("rowClick",d)},m=(d,D)=>{n("routeUrl",d,D)},g=d=>{n("clickTrigger",d)},y=(d,D)=>{n("clickMainKey",d,D)};return(d,D)=>{var w,q;return e.openBlock(),e.createElementBlock("div",d2,[(w=i.value)!=null&&w.length?(e.openBlock(),e.createBlock(pl.ssTab,{tabsContents:i.value,key:(q=i.value)==null?void 0:q.length},{pane:e.withCtx(({tab:A,index:j})=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)(A==null?void 0:A.comp)),{related:A==null?void 0:A.relatedTables,compNames:A==null?void 0:A.nameContents,compName:A==null?void 0:A.name,cacheNewData:r==null?void 0:r.cacheNewData,isDevMode:a.isDevMode,itemData:A==null?void 0:A.compData,childItemData:A==null?void 0:A.itemChildData,onChange:o,calculator:A==null?void 0:A.calculatorFilters,index:(A==null?void 0:A.id)??j,config:{showIndex:A==null?void 0:A.showIndex,allowMove:A==null?void 0:A.allowMove,viewport:A==null?void 0:A.viewport,status:A==null?void 0:A.status},onContentChange:p,onPageChange:c,onRowClick:u,onRouteUrl:m,parentTableId:A==null?void 0:A.tableId,allMapContents:a.allMapContents,children:A==null?void 0:A.children,level:1,onClickTrigger:g,onClickMainKey:y},null,40,["related","compNames","compName","cacheNewData","isDevMode","itemData","childItemData","calculator","index","config","parentTableId","allMapContents","children"]))]),_:1},8,["tabsContents"])):e.createCommentVNode("",!0)])}}}),f2=pr._export_sfc(p2,[["__scopeId","data-v-71516232"]]),h2={class:"type-select"},v2=["onClick"],m2={class:"list-icon"},y2={__name:"modelSelect",setup(a){const l=ti(M.pinia),{itemData:r}=M.storeToRefs(l),n=i=>{const o=M.cloneDeep(r.value);o.push({comp:i.comp,name:i.name,compData:[]}),l.setItemData(o)};return(i,o)=>{const p=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",h2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(Su),(c,u)=>(e.openBlock(),e.createElementBlock("div",{class:"type-list",key:u},[e.createElementVNode("div",{class:"list-content",onClick:m=>n(c)},[e.createElementVNode("div",m2,[e.createVNode(p,{name:c.icon},null,8,["name"])]),e.createElementVNode("div",null,e.toDisplayString(c.name),1)],8,v2)]))),128))])}}},g2=pr._export_sfc(y2,[["__scopeId","data-v-91799bf8"]]),b2={class:"fill-content"},k2={class:"operate-content"},x2={class:"collapse-title-content"},w2={class:"collapse-title-item"},_2={key:1},S2=["onClick"],E2={class:"icon-content"},C2={key:0,class:"edit-content"},D2=["onClick"],T2={class:"comp-child"},B2={__name:"modelFill",setup(a){const l=ti(M.pinia),{itemData:r,originalData:n}=M.storeToRefs(l),i=e.ref([]);e.ref([]);const o=e.ref([]),p=e.ref([]),c=D=>{var q;let w=(q=M.cloneDeep(p.value))==null?void 0:q.map((A,j)=>(D===j&&(A.content=!0),A));p.value=w},u=D=>{var q;let w=(q=M.cloneDeep(p.value))==null?void 0:q.map((A,j)=>(D===j&&(A.content=!1),A));p.value=w,i.value=M.cloneDeep(r.value)},m=(D,w)=>{var O;let q=(O=M.cloneDeep(p.value))==null?void 0:O.map((E,_)=>(D===_&&(E.content=!1),E));p.value=q;const A=M.cloneDeep(r.value),j=A==null?void 0:A.filter((E,_)=>(_===D&&(E.name=w),E));l.setOriginalData(j),l.setItemData(j)};e.watch(()=>r.value,()=>{var D,w,q;!r.value||((D=r.value)==null?void 0:D.length)===0?i.value=[]:i.value=(w=M.cloneDeep(r.value))==null?void 0:w.filter(A=>(A==null?void 0:A.comp)!=="methodButton"),o.value=i.value,p.value=(q=M.cloneDeep(o.value))==null?void 0:q.map((A,j)=>({id:j,content:!1}))},{deep:!0,immediate:!0});const g=D=>$i(D),y=(D,w,q)=>{var j,O;if(!D)return;let A=M.cloneDeep(r.value);A=(j=A==null?void 0:A.map((E,_)=>(_===q&&(E.compData=D),E)))==null?void 0:j.filter(E=>(E==null?void 0:E.comp)!=="methodButton"),p.value=(O=M.cloneDeep(A))==null?void 0:O.map((E,_)=>({id:_,content:!1})),l.setOriginalData(A),l.setItemData(A)},d=D=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const w=M.cloneDeep(r.value),q=w==null?void 0:w.filter((A,j)=>j!==D);l.setOriginalData(q),l.setItemData(q),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(D,w)=>{const q=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",b2,[w[1]||(w[1]=e.createElementVNode("div",{class:"fill-operate"},e.toDisplayString("操作栏"),-1)),e.createElementVNode("div",k2,[e.createVNode(pc.default,{class:"collapse-content",collapseContents:i.value},{title:e.withCtx(({item:A,index:j})=>{var O,E,_,x,b,S,I,R,re,X;return[e.createElementVNode("div",x2,[e.createElementVNode("div",w2,[(E=(O=p.value)==null?void 0:O.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:A.name&&A.name!==""?"8px":"0px"})},e.toDisplayString(A.name),5)),(x=(_=p.value)==null?void 0:_.find(me=>me.id===j))!=null&&x.content?(e.openBlock(),e.createElementBlock("div",_2,[e.createVNode(pl.ssInput,{modelValue:A.name,"onUpdate:modelValue":me=>A.name=me,onClick:w[0]||(w[0]=e.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):e.createCommentVNode("",!0),(S=(b=p.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(q,{name:"Edit",style:{width:"16px",height:"16px"}})],8,S2))]),e.createElementVNode("div",E2,[(R=(I=p.value)==null?void 0:I.find(me=>me.id===j))!=null&&R.content?(e.openBlock(),e.createElementBlock("div",C2,[e.createVNode(q,{name:"Cancel",style:{width:"16px",height:"16px"},class:"icon-content",onClick:e.withModifiers(me=>u(j),["stop"])},null,8,["onClick"]),e.createVNode(q,{name:"Save",onClick:e.withModifiers(me=>m(j,A.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):e.createCommentVNode("",!0),(X=(re=p.value)==null?void 0:re.find(me=>me.id===j))!=null&&X.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,onClick:e.withModifiers(me=>d(j),["stop"]),class:"icon-content"},[e.createVNode(q,{name:"Delete",style:{width:"16px",height:"16px"}})],8,D2))])])]}),content:e.withCtx(({item:A,index:j})=>{var O,E;return[e.createElementVNode("div",T2,[e.createTextVNode(e.toDisplayString(g(A.comp+"Operate"))+" ",1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g(A.comp+"Operate")),{itemContents:A==null?void 0:A.compData,originalItemContents:(E=(O=o.value)==null?void 0:O.find((_,x)=>x===j))==null?void 0:E.compData,onChange:_=>y(_,A,j)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},N2=pr._export_sfc(B2,[["__scopeId","data-v-a46a44b9"]]),A2={key:0,class:"show-content"},z2={style:{display:"flex"}},M2={__name:"modelShow",setup(a){const l=ti(M.pinia),{itemData:r}=M.storeToRefs(l),n=e.ref([]);e.watch(()=>r.value,()=>{var o;!r.value||((o=r.value)==null?void 0:o.length)===0?n.value=[]:n.value=M.cloneDeep(r.value)},{deep:!0,immediate:!0});const i=o=>$i(o);return(o,p)=>{var c;return((c=n.value)==null?void 0:c.length)>0?(e.openBlock(),e.createElementBlock("div",A2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.value,(u,m)=>(e.openBlock(),e.createElementBlock("div",{class:"item-content",key:m},[e.createElementVNode("div",z2,e.toDisplayString(u.name),1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i(u.comp)),{itemData:u==null?void 0:u.compData,childItemData:u==null?void 0:u.itemChildData,key:m},null,8,["itemData","childItemData"]))]))),128))])):e.createCommentVNode("",!0)}}},I2=pr._export_sfc(M2,[["__scopeId","data-v-3f3e863e"]]),O2={class:"tabs-header"},L2={class:"tabs-list"},R2={class:"tab-name"},$2={class:"tab-actions"},V2=["onClick"],F2=["onClick"],P2=["onClick"],j2={class:"model-operate"},H2={class:"model-select",style:{display:"unset"}},U2={class:"existing-components"},q2={class:"component-list"},W2=["onClick"],G2={class:"component-info"},K2={class:"component-type"},Y2={class:"component-name"},J2={class:"model-fill"},X2={__name:"operate",props:{itemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.ref([]),o=e.ref(!1),p=e.ref(""),c=e.ref({title:""}),u=e.ref(-1),m=e.ref(!1),g=e.ref(-1),y=e.ref(new WeakMap),d=e.ref(null),D=ti(M.pinia),{itemData:w}=M.storeToRefs(D),q=()=>{p.value="新增标签页",c.value.title="",u.value=-1,o.value=!0},A=te=>{p.value="修改标签页",c.value.title=i.value[te].title,u.value=te,o.value=!0},j=te=>{const N=_(te);y.value.delete(N),i.value.splice(te,1),ze()},O=()=>{if(c.value.title.trim()){if(u.value===-1){const te={title:c.value.title,value:c.value.title,label:c.value.title,children:[],id:E()};i.value.push(te)}else i.value[u.value].title=c.value.title,i.value[u.value].value=c.value.title,i.value[u.value].label=c.value.title;o.value=!1,ze()}},E=()=>`tab_${Date.now()}_${Math.random().toString(36).substr(2,9)}`,_=te=>{const N=i.value[te];return N.id||(N.id=E()),N.id},x=te=>{var G;g.value=te;const N=_(te);d.value=M.cloneDeep(w.value);let se=y.value.get(N);!se&&((G=i.value[te].children)==null?void 0:G.length)>0&&(se=R(i.value[te].children)),se?D.setItemData(M.cloneDeep(se)):D.setItemData([]),m.value=!0},b=e.computed(()=>{const te=M.useModelComp(M.pinia),N=M.storeToRefs(te).itemData.value;return console.log("可用组件数据",N),!N||!Array.isArray(N)?[]:N.filter(se=>{var G;if(se.comp==="Tabs"&&g.value>=0){const fe=_(g.value);if((G=se.compData)==null?void 0:G.some(_e=>{var qe;return _e.key==="stepList"&&((qe=_e.contents)==null?void 0:qe.some(ra=>ra.id===fe))}))return!1}return!0})}),S=te=>({Table:"表格",Form:"表单",Tabs:"标签页",Chart:"图表",Card:"卡片"})[te]||te,I=te=>{var N;try{const se=M.cloneDeep(te);se.id=Date.now()+Math.random(),se.comp==="Tabs"&&((N=se.compData)==null||N.forEach(fe=>{fe.key==="stepList"&&fe.contents&&fe.contents.forEach(we=>{we.id=E()})}));const G=M.cloneDeep(w.value);G.push(se),D.setItemData(G)}catch(se){console.error("添加组件失败:",se)}},R=te=>te.map(N=>{var se;switch(N.type){case"form":return{comp:"Form",name:N.value||"表单",compData:re(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)||[]}}}),re=te=>{if(!te)return[];const N=[];return te.rowContents&&N.push({key:"formContent",contents:te.rowContents}),te.buttonValue&&N.push({key:"formButton",contents:te.buttonValue}),typeof te.isEnableWrap<"u"&&N.push({key:"enableWrap",contents:te.isEnableWrap}),N},X=te=>[],me=()=>{if(g.value>=0&&g.value<i.value.length){const te=_(g.value);y.value.set(te,M.cloneDeep(w.value)),i.value[g.value].children=W(w.value),console.log("保存后的数据",W(w.value))}m.value=!1,g.value=-1,d.value=null,ze()},ue=()=>{d.value&&D.setItemData(M.cloneDeep(d.value)),m.value=!1,g.value=-1,d.value=null},U=()=>{m.value&&ue()},W=te=>{if(!Array.isArray(te))throw new Error("sourceData must be an array");return te.map((N,se)=>{if(!N||typeof N!="object")return N;const{comp:G,name:fe,compData:we}=N;switch(G){case"Form":return{type:"form",content:Z(we||[]),value:"表单"};case"Table":return{type:"table",content:ae(we||[]),value:"表格"};default:return{type:"xxx",content:ve(we||[]),value:""}}})},Z=te=>{const N={formRules:{},rowContents:[],buttonValue:[],rowValues:[],isEnableWrap:!0,isRowFlex:!0,isButtonRow:!0,isEdit:!0,isStartJustify:!0},se={formContent:"rowContents",enableWrap:"isEnableWrap",formButton:"buttonValue"};return te.forEach((G,fe)=>{if(!G||typeof G!="object"){console.warn(`Invalid config at index ${fe}:`,G);return}const{key:we,contents:_e}=G,qe=se[we];if(!qe){console.warn(`Unknown Form config key: ${we}`);return}we==="enableWrap"?N[qe]=!!_e:N[qe]=Array.isArray(_e)?_e:[]}),N},ae=te=>{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 te.forEach((G,fe)=>{if(!G||typeof G!="object"){console.warn(`Invalid config at index ${fe}:`,G);return}const{key:we,contents:_e}=G,qe=se[we];if(!qe){console.warn(`Unknown Table config key: ${we}`);return}N[qe]=Array.isArray(_e)?_e:[]}),N},ve=te=>(console.log("Default conversion logic - to be implemented"),{originalData:te,processed:!1,componentType:"unknown"}),ze=()=>{const te=[{key:"stepList",contents:i.value}];n("change",te)};return e.watch(()=>r.itemContents,te=>{if(te&&te.length>0){const N=te.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}),(te,N)=>{const se=e.resolveComponent("svg-icon"),G=e.resolveComponent("el-input"),fe=e.resolveComponent("el-form-item"),we=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",O2,[N[6]||(N[6]=e.createElementVNode("h4",null,"标签页管理",-1)),e.createElementVNode("button",{onClick:q},[e.createVNode(se,{name:"Plus",style:{width:"14px",height:"14px","margin-right":"4px"}}),N[5]||(N[5]=e.createTextVNode(" 新增标签页 "))])]),e.createElementVNode("div",L2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(_e,qe)=>(e.openBlock(),e.createElementBlock("div",{class:"tab-item",key:qe},[e.createElementVNode("span",R2,e.toDisplayString(_e.title),1),e.createElementVNode("div",$2,[e.createElementVNode("button",{onClick:ra=>A(qe)},"修改标题",8,V2),e.createElementVNode("button",{onClick:ra=>x(qe)},"布局调整",8,F2),e.createElementVNode("button",{onClick:ra=>j(qe)},"删除",8,P2)])]))),128))]),e.createVNode($r.ssDialog,{modelValue:o.value,"onUpdate:modelValue":N[2]||(N[2]=_e=>o.value=_e),title:p.value,onBeforeDestroy:N[3]||(N[3]=_e=>o.value=!1)},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:N[1]||(N[1]=_e=>o.value=!1)},"取消"),e.createElementVNode("button",{type:"primary",onClick:O},"确定")]),default:e.withCtx(()=>[e.createVNode(we,{model:c.value,"label-width":"80px"},{default:e.withCtx(()=>[e.createVNode(fe,{label:"标签名称",required:""},{default:e.withCtx(()=>[e.createVNode(G,{modelValue:c.value.title,"onUpdate:modelValue":N[0]||(N[0]=_e=>c.value.title=_e),placeholder:"请输入标签页名称"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue","title"]),e.createVNode($r.ssDialog,{modelValue:m.value,"onUpdate:modelValue":N[4]||(N[4]=_e=>m.value=_e),title:"布局调整",fullScreen:"",onBeforeDestroy:U},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:ue},"取消"),e.createElementVNode("button",{onClick:me},"确定")]),default:e.withCtx(()=>[e.createElementVNode("div",j2,[e.createElementVNode("div",H2,[e.createVNode(g2),e.createElementVNode("div",U2,[N[8]||(N[8]=e.createElementVNode("h5",null,"添加已有组件",-1)),e.createElementVNode("div",q2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,_e=>(e.openBlock(),e.createElementBlock("div",{key:_e.id,class:"component-item",onClick:qe=>I(_e)},[e.createElementVNode("div",G2,[e.createElementVNode("span",K2,e.toDisplayString(S(_e.comp)),1),e.createElementVNode("span",Y2,e.toDisplayString(_e.name),1)]),N[7]||(N[7]=e.createElementVNode("button",{class:"add-btn"},"添加",-1))],8,W2))),128))])])]),(e.openBlock(),e.createElementBlock("div",{class:"model-show",key:te.innerWidth},[e.createVNode(I2)])),e.createElementVNode("div",J2,[e.createVNode(N2)])])]),_:1},8,["modelValue"])])}}},Z2=pr._export_sfc(X2,[["__scopeId","data-v-9096ed0d"]]);function Q2(){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 ev(a){return{type:"line",color:["#5070DD","#B6D634","#505372","#FF994E","#0CA8DF","#FFD10A","#FB628B","#8466C1","#3EBE95"],...a}}function av(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{top:"3%",left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",data:[]},yAxis:[{type:"value"}],series:[]}}function lv(a){return{type:"bar",barWidth:"60%",showBackground:!0,backgroundStyle:{color:"rgba(180, 180, 180, 0.1)"},itemStyle:{color:new Fl.LinearGradient(0,0,0,1,[{offset:0,color:"#94C2FD"},{offset:.7,color:"#6491E1"},{offset:1,color:"#3264C8"}])},emphasis:{itemStyle:{color:new Fl.LinearGradient(0,0,0,1,[{offset:0,color:"#3264C8"},{offset:.7,color:"#6491E1"},{offset:1,color:"#94C2FD"}])}},...a}}function rv(){return{title:{text:"",left:"center"},tooltip:{trigger:"item"},series:[]}}function nv(a){return{type:"pie",color:["#5070DD","#B6D634","#505372","#FF994E","#0CA8DF","#FFD10A","#FB628B","#8466C1","#3EBE95"],radius:["40%","70%"],itemStyle:{borderRadius:6,borderColor:"#fff",borderWidth:2},label:{show:!0,formatter:function(l){return"{b|"+l.name+`}
|
|
26
|
+
{c|`+l.value+"}"},rich:{b:{fontFamily:"SourceHanSansSC",fontWeight:"bold",fontSize:14,color:"#333"},c:{fontFamily:"SourceHanSansSC",fontSize:12,color:"#666"},d:{fontFamily:"SourceHanSansSC",fontSize:12,color:"#999"}}},emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},...a}}const iv=()=>({title:{text:"",left:"center"},tooltip:{trigger:"item"},xAxis:{scale:!0},yAxis:{scale:!0},series:[]}),ov=a=>({type:"scatter",symbolSize:20,...a}),In={Line:{initBaseoptions:Q2,initSeries:ev},Bar:{initBaseoptions:av,initSeries:lv},Pie:{initBaseoptions:rv,initSeries:nv},Scatter:{initBaseoptions:iv,initSeries:ov}},tv=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";const m=l==null?void 0:l.map(d=>d==null?void 0:d.prop);let g=[];if(m==null||m.forEach(d=>{var D;g.push((D=r==null?void 0:r[0])==null?void 0:D[d])}),!m||!g)return u;u.xAxis.data=m;const y=c({data:g});return u.series.push(y),u},sv=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";const m=l==null?void 0:l.map(d=>d==null?void 0:d.prop);let g=[];if(m==null||m.forEach(d=>{var D;g.push((D=r==null?void 0:r[0])==null?void 0:D[d])}),!m||!g)return u;u.xAxis.data=m;const y=c({data:g});return u.series.push(y),u},cv=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";const m=l==null?void 0:l.map(D=>D==null?void 0:D.prop);let g=[];if(m==null||m.forEach(D=>{var w;g.push((w=r==null?void 0:r[0])==null?void 0:w[D])}),!m||!g)return u;const y=[];for(let D=0;D<m.length;D++){const w=m[D],q=g[D];y.push({name:w,value:q})}const d=c({data:y});return u.series.push(d),u},uv=({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:i}=a||{},o=In==null?void 0:In[n];if(!o)return;const{initBaseoptions:p,initSeries:c}=o,u=p();u.title.text=i??"";let m=[];const g=l==null?void 0:l.map(D=>D==null?void 0:D.prop);if(m=g==null?void 0:g.map(D=>{var q;let w=[];return w.push(D),w.push((q=r==null?void 0:r[0])==null?void 0:q[D]),w}),!m)return u;const d=c({data:m});return u.series.push(d),u},dv=async(a=[])=>{var c,u,m,g,y;const l=((c=a==null?void 0:a.find(d=>d.key==="ChartType"))==null?void 0:c.contents)??{};let r=((u=a==null?void 0:a.find(d=>d.key==="header"))==null?void 0:u.contents)??[],n=((m=a==null?void 0:a.find(d=>d.key==="tableContents"))==null?void 0:m.contents)??[],i=((g=a==null?void 0:a.find(d=>d.key==="calculator"))==null?void 0:g.contents)??[];if((i==null?void 0:i.length)>0){i=i==null?void 0:i.map(D=>({methods:D==null?void 0:D.calculatorFilter,functionName:D==null?void 0:D.functionName,functionRelatedWords:D==null?void 0:D.functionRelatedWords}));let d=await No([],i,[],"Auto",[],[]);r=(y=d==null?void 0:d.xAxis)==null?void 0:y.map(D=>({label:D,prop:D})),n=d==null?void 0:d.yAxis}else if(r!=null&&r.some(d=>d==null?void 0:d.functionName)){let d=r==null?void 0:r.filter(q=>q==null?void 0:q.functionName);d=d==null?void 0:d.map(async q=>{let A={methods:q==null?void 0:q.calculatorFilter,functionName:q==null?void 0:q.functionName,functionRelatedWords:q==null?void 0:q.functionRelatedWords};return A=await No(q,[A],[],"Auto",[],[]),{name:q==null?void 0:q.prop,value:A==null?void 0:A.value}});let D=await Promise.all(d),w={};D==null||D.forEach(q=>{var A;w[q==null?void 0:q.name]=((A=q==null?void 0:q.value)==null?void 0:A.toString())??""}),n=[w]}let{type:o}=l,p={};return o==="Line"&&(p=await tv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),o==="Bar"&&(p=await sv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),o==="Pie"&&(p=await cv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),o==="Scatter"&&(p=await uv({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),p},pv=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,r=e.ref({});e.onMounted(async()=>{const i=l==null?void 0:l.itemData;r.value=await dv(i)});const n=e.computed(()=>(l==null?void 0:l.height)||"300px");return(i,o)=>(e.openBlock(),e.createElementBlock("div",{class:"eCharts",style:e.normalizeStyle({height:n.value})},[e.createVNode(ad.ssChart,{optionContents:r.value},null,8,["optionContents"])],4))}}),fv=pr._export_sfc(pv,[["__scopeId","data-v-d4c081e8"]]),hv={class:"chart-module layout"},vv={class:"chart-module content"},mv={class:"chart-module content"},yv={class:"form-content"},gv={class:"dialog-footer"},bv={class:"form-content"},kv={class:"dialog-footer"},xv={class:"form-content"},wv={class:"dialog-footer"},_v=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,i=e.reactive({visible:!1,width:"840",title:"基础配置"}),o=e.ref([]),p=()=>[{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({}),u=Ie=>{var de;o.value=p(),(de=o.value)==null||de.forEach(De=>{var Ea;const Xe=De==null?void 0:De.prop;De.value=(Ea=c==null?void 0:c.value)==null?void 0:Ea[Xe]}),i.visible=!0},m=Ie=>{c.value=Ie},g=()=>{var Ie;i.visible=!1,n("change",(Ie=Me())==null?void 0:Ie.compData)},y=e.reactive({visible:!1,width:"840",title:"数据配置"}),d=e.ref([]),D=()=>[{label:"菜单选项",prop:"menu",type:"cascader",contents:[]},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],w=e.ref({}),q=()=>{const Ie=d.value,de=M.cloneDeep(Ie);return de==null||de.forEach(De=>{var Ea;const Xe=De==null?void 0:De.prop;De.value=(Ea=w.value)==null?void 0:Ea[Xe]}),de},A=Ie=>{var De;w.value=Ie;const de=q();d.value=de,n("change",(De=Me())==null?void 0:De.compData)},j=async Ie=>{const de=await le.getMenusContent(),De=q();De==null||De.forEach(Xe=>{(Xe==null?void 0:Xe.prop)==="menu"&&(Xe.contents=de)}),d.value=De,y.visible=!0,await _e(w.value.menu),await P(w.value.group)},O=e.reactive({visible:!1,width:"840",title:"详情页配置"}),E=e.ref([]),_=()=>[{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:[]}],x=e.ref({}),b=()=>{const Ie=E.value,de=M.cloneDeep(Ie);return de==null||de.forEach(De=>{var Ea;const Xe=De==null?void 0:De.prop;De.value=(Ea=x.value)==null?void 0:Ea[Xe]}),de},S=Ie=>{var De;x.value=Ie;const de=b();E.value=de,n("change",(De=Me())==null?void 0:De.compData)},I=async Ie=>{await U();const de=M.cloneDeep(R.value),De=b();De==null||De.forEach(Xe=>{var Ge;const Ea=Xe==null?void 0:Xe.prop;Xe.value=(Ge=x==null?void 0:x.value)==null?void 0:Ge[Ea],Ea==="mainKey"&&(Xe.contents=de)}),E.value=De,O.visible=!0},R=e.ref([]),re=e.ref([]),X=e.ref({}),me=e.ref({}),ue=()=>{const{compData:Ie}=G.value||{},de=Ie==null?void 0:Ie.find(ee=>{const{key:ce}=ee;return ce==="header"}),De=(de==null?void 0:de.contents)||[],Xe=De==null?void 0:De.filter((ee,ce)=>{const{label:he}=ee;return he!=="操作"}),Ea=Xe==null?void 0:Xe.findIndex((ee,ce)=>{const{isMainKey:he}=ee;return he});if(Ea<0)return[];const Ge=Ie==null?void 0:Ie.find(ee=>{const{key:ce}=ee;return ce==="tableContents"}),$=(Ge==null?void 0:Ge.contents)||[];return $==null?void 0:$.map(ee=>{const ce=ee==null?void 0:ee[0];let he=Ea;Ja.isObject(ce)&&(ce!=null&&ce.id)&&(he=he+1);const pa=ee==null?void 0:ee[he];return{label:pa,value:pa}})},U=async()=>{const Ie=await ue();R.value=Ie},W=async Ie=>{const de=sessionStorage.getItem("systemKey");return await le.getItemData(Ie,de,"")},Z=async Ie=>{const de=Ie;re.value=de==null?void 0:de.map(De=>{const{name:Xe}=De;return X.value[Xe]=De,{label:Xe,value:Xe}})},ae=Ie=>{const{comp:de,compData:De}=me.value||{};if(de==="Table"){let Xe=b();Xe=Xe.filter(Ea=>{const{prop:Ge}=Ea;return Ge!=="formItems"}),qe(Xe,De),E.value=Xe}},ve=async()=>{var De,Xe;const Ie=(De=x==null?void 0:x.value)==null?void 0:De.mainKey,de=(Xe=w==null?void 0:w.value)==null?void 0:Xe.menu;if(Ie){const Ge=`${de==null?void 0:de.join("/")}^${Ie}`,$=await W(Ge);await Z($);const V=b();V==null||V.forEach(ee=>{(ee==null?void 0:ee.prop)==="group"&&(ee.contents=re.value)}),E.value=V}};e.watch(()=>{var Ie;return(Ie=x==null?void 0:x.value)==null?void 0:Ie.mainKey},async(Ie,de)=>{Ie!=de&&Ie&&await ve()});const ze=async Ie=>{const de=X.value[Ie];me.value=de,await ae()};e.watch(()=>{var Ie;return(Ie=x==null?void 0:x.value)==null?void 0:Ie.group},async(Ie,de)=>{Ie!=de&&Ie&&ze(Ie)});const te=async()=>{var de;await ve();const Ie=(de=x.value)==null?void 0:de.group;await ze(Ie)},N=e.ref([]),se=e.ref({}),G=e.ref({}),fe=async Ie=>{const de=Ie==null?void 0:Ie.join("/"),De=sessionStorage.getItem("systemKey");return await le.getItemData(de,De,"")},we=async Ie=>{const de=await fe(Ie);N.value=de==null?void 0:de.map(De=>{const{name:Xe}=De;return se.value[Xe]=De,{label:Xe,value:Xe}})},_e=async(Ie,de)=>{await we(Ie);const De=q();De==null||De.forEach(Xe=>{(Xe==null?void 0:Xe.prop)==="group"&&(Xe.contents=N.value)}),d.value=De};e.watch(()=>{var Ie;return(Ie=w==null?void 0:w.value)==null?void 0:Ie.menu},async(Ie,de)=>{const De=Ie==null?void 0:Ie.join("/"),Xe=de==null?void 0:de.join("/");De!=Xe&&await _e(Ie)});const qe=(Ie,de)=>{const De=de==null?void 0:de.find($=>{const{key:V}=$;return V==="header"}),Xe=(De==null?void 0:De.contents)||[],Ea=Xe==null?void 0:Xe.filter(($,V)=>{const{label:ee}=$;return ee!=="操作"}),Ge=Ea==null?void 0:Ea.map(($,V)=>{const{label:ee}=$;return{label:ee,value:V}});Ie==null||Ie.forEach($=>{const V=$==null?void 0:$.prop;(V==="nameCol"||V==="valueCol")&&($.contents=Ge)})},ra=Ie=>{const{comp:de,compData:De}=G.value||{};if(de==="Table"){w.value.formItems=[];let Xe=q();Xe=Xe.filter(Ea=>{const{prop:Ge}=Ea;return Ge!=="formItems"}),qe(Xe,De),d.value=Xe}},P=async Ie=>{const de=se.value[Ie];G.value=de,await ra()};e.watch(()=>{var Ie;return(Ie=w==null?void 0:w.value)==null?void 0:Ie.group},async(Ie,de)=>{Ie!=de&&P(Ie)});const Ke=async()=>{var De,Xe;const Ie=(De=w.value)==null?void 0:De.menu;await _e(Ie);const de=(Xe=w.value)==null?void 0:Xe.group;await P(de)},Me=()=>({comp:"chart",compData:[{key:"chartBaseConfig",contents:c.value},{key:"chartDataConfig",contents:w.value},{key:"chartDetailConfig",contents:x.value}]}),Le=()=>{i.visible=!1,y.visible=!1,O.visible=!1};return e.onMounted(async()=>{var de,De,Xe;d.value=D(),E.value=_();const Ie=r==null?void 0:r.itemContents;c.value=((de=Ie==null?void 0:Ie.find(Ea=>Ea.key==="chartBaseConfig"))==null?void 0:de.contents)??{},w.value=((De=Ie==null?void 0:Ie.find(Ea=>Ea.key==="chartDataConfig"))==null?void 0:De.contents)??{},await Ke(),x.value=((Xe=Ie==null?void 0:Ie.find(Ea=>Ea.key==="chartDetailConfig"))==null?void 0:Xe.contents)??{},await te()}),(Ie,de)=>{const De=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",hv,[de[4]||(de[4]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createVNode(De,{id:"themeButton",onClick:de[0]||(de[0]=Xe=>u())},{default:e.withCtx(()=>de[3]||(de[3]=[e.createTextVNode(" 修改 ")])),_:1,__:[3]})]),e.createElementVNode("div",vv,[de[6]||(de[6]=e.createElementVNode("h4",{class:"module-title"},"数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:de[1]||(de[1]=Xe=>j())},{default:e.withCtx(()=>de[5]||(de[5]=[e.createTextVNode(" 修改 ")])),_:1,__:[5]})]),e.createElementVNode("div",mv,[de[8]||(de[8]=e.createElementVNode("h4",{class:"module-title"},"详情数据配置",-1)),e.createVNode(De,{id:"themeButton",onClick:de[2]||(de[2]=Xe=>I())},{default:e.withCtx(()=>de[7]||(de[7]=[e.createTextVNode(" 修改 ")])),_:1,__:[7]})])]),e.createVNode($r.ssDialog,{visible:i.visible,title:i.title,onBeforeDestroy:Le,width:i.width},{default:e.withCtx(()=>[e.createElementVNode("div",yv,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:o.value,key:o.value,isEnableWrap:!0,onChange:m},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",gv,[e.createVNode(De,{class:"cancel-button button",onClick:Le,id:"themeBorderButton"},{default:e.withCtx(()=>de[9]||(de[9]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[9]}),e.createVNode(De,{class:"ok-button button",onClick:g,id:"themeButton"},{default:e.withCtx(()=>de[10]||(de[10]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[10]})])]),_:1},8,["visible","title","width"]),e.createVNode($r.ssDialog,{visible:y.visible,title:y.title,onBeforeDestroy:Le,width:y.width},{default:e.withCtx(()=>[e.createElementVNode("div",bv,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:d.value,key:d.value,isEnableWrap:!0,onChange:A},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",kv,[e.createVNode(De,{class:"cancel-button button",onClick:Le,id:"themeBorderButton"},{default:e.withCtx(()=>de[11]||(de[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(De,{class:"ok-button button",onClick:Le,id:"themeButton"},{default:e.withCtx(()=>de[12]||(de[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible","title","width"]),e.createVNode($r.ssDialog,{visible:O.visible,title:O.title,onBeforeDestroy:Le,width:O.width},{default:e.withCtx(()=>[e.createElementVNode("div",xv,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:S},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",wv,[e.createVNode(De,{class:"cancel-button button",onClick:Le,id:"themeBorderButton"},{default:e.withCtx(()=>de[13]||(de[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(De,{class:"ok-button button",onClick:Le,id:"themeButton"},{default:e.withCtx(()=>de[14]||(de[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible","title","width"])],64)}}}),Sv=pr._export_sfc(_v,[["__scopeId","data-v-88c50cdb"]]),Ev={class:"layout"},Cv=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}}},emits:["rowClick"],setup(a,{emit:l}){const r=l,n=a;e.onMounted(async()=>{});const i=e.computed(()=>M.cloneDeep(n==null?void 0:n.itemData)||[]),o=e.computed(()=>{var g;const m=(g=i==null?void 0:i.value)==null?void 0:g.find(y=>{const{key:d}=y;return d==="baseConfig"});return m==null?void 0:m.contents}),p=e.computed(()=>{var g;const m=(g=i==null?void 0:i.value)==null?void 0:g.find(y=>{const{key:d}=y;return d==="children"});return m==null?void 0:m.contents}),c=e.computed(()=>{let m=M.cloneDeep(p.value)||[];const g=m.length;let y=0;const d=[];if(m=m.map(D=>{const w=D.span;return w?(D.span=Number(w),y=y+D.span):d.push(D),D}),y<24){const D=Math.floor((24-y)/g);d.forEach(w=>{w.span=D})}return m}),u=m=>{r("rowClick",m)};return(m,g)=>{var D;const y=e.resolveComponent("el-col"),d=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",Ev,[e.createVNode(d,{style:e.normalizeStyle({height:(D=o.value)==null?void 0:D.height})},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(w,q)=>(e.openBlock(),e.createBlock(y,{span:w==null?void 0:w.span},{default:e.withCtx(()=>{var A;return[e.unref(Ri)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)(w.comp)),{key:e.unref(oi),compName:w.name,index:(w==null?void 0:w.id)??q,height:(A=o.value)==null?void 0:A.height,itemData:w==null?void 0:w.compData,childItemData:w==null?void 0:w.itemChildData,onChange:e.unref(Mo),onContentChange:e.unref(Io),onPageChange:e.unref(Oo),onRowClick:u},null,40,["compName","index","height","itemData","childItemData","onChange","onContentChange","onPageChange"])):e.createCommentVNode("",!0)]}),_:2},1032,["span"]))),256))]),_:1},8,["style"])])}}}),Dv=pr._export_sfc(Cv,[["__scopeId","data-v-ab9a36ed"]]),Tv={class:"layout-operate"},Bv={class:"layout-module"},Nv={class:"collapse-title-item"},Av={class:"collapse-title"},zv={class:"icon-content"},Mv=["onClick"],Iv={class:"comp-child"},Ov=e.defineComponent({__name:"operate",props:{itemContents:{type:Object,default:()=>{}},originalItemContents:{type:Array,default:()=>[]},itemChildData:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l;e.onMounted(()=>{q()});const i=e.ref({}),o=e.ref({}),p=e.ref([]),c=x=>[{label:"高度",prop:"height",type:"input",value:x==null?void 0:x.height}],u=x=>{o.value=x,n("change",_(),!0)},m=e.ref([]),g=e.ref([]),y=x=>[{label:"占比",prop:"span",type:"input",value:x==null?void 0:x.span}],d=e.computed(()=>{const x=r==null?void 0:r.itemContents;return M.cloneDeep(x)}),D=e.computed(()=>{const x=d==null?void 0:d.value,b=x==null?void 0:x.find(S=>{const{key:I}=S;return I==="baseConfig"});return b==null?void 0:b.contents}),w=e.computed(()=>{const x=d==null?void 0:d.value,b=x==null?void 0:x.find(S=>{const{key:I}=S;return I==="children"});return b==null?void 0:b.contents}),q=()=>{var x;i.value=d.value||{},m.value=(w==null?void 0:w.value)||[],p.value=c(),p.value=(x=p.value)==null?void 0:x.map(b=>{var I;const{prop:S}=b;return b.value=(I=D.value)==null?void 0:I[S],b})};e.watch(()=>{var x;return(x=w==null?void 0:w.value)==null?void 0:x.length},()=>{var x;m.value=(w==null?void 0:w.value)||[],g.value=(x=w.value)==null?void 0:x.map(b=>y(b))},{immediate:!0});const A=(x,b)=>{const S=M.cloneDeep(w==null?void 0:w.value);S[b].span=x.span,m.value=S,n("change",_(),!0)},j=x=>$i(x),O=(x,b,S)=>{if(!x)return;const I=M.cloneDeep(w==null?void 0:w.value);I[S]&&(I[S].compData=x,m.value=I,n("change",_(),!0))},E=x=>{M.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{let b=M.cloneDeep(w==null?void 0:w.value);b=b==null?void 0:b.filter((S,I)=>x!==I),m.value=b,n("change",_(),!0),Ja.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},_=()=>({compData:[{key:"baseConfig",contents:o.value},{key:"children",contents:m==null?void 0:m.value}]});return(x,b)=>{const S=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",Tv,[e.createElementVNode("div",Bv,[b[1]||(b[1]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createElementVNode("div",null,[e.createVNode(pl.ssForm,{rowContents:p.value,isEnableWrap:!0,onChange:b[0]||(b[0]=I=>u(I))},null,8,["rowContents"])])]),e.createVNode(pc.default,{class:"collapse-content",collapseContents:w.value},{title:e.withCtx(({item:I,index:R})=>[e.createElementVNode("div",Nv,[e.createElementVNode("div",Av,e.toDisplayString(I.name),1),e.createElementVNode("div",zv,[e.createElementVNode("div",{onClick:e.withModifiers(re=>E(R),["stop"]),class:"icon-content"},[e.createVNode(S,{name:"Delete",style:{width:"16px",height:"16px"}})],8,Mv)])])]),content:e.withCtx(({item:I,index:R})=>[e.createElementVNode("div",Iv,[e.createElementVNode("div",null,[(e.openBlock(),e.createBlock(pl.ssForm,{rowContents:g.value[R],key:R,isEnableWrap:!0,onChange:re=>A(re,R)},null,8,["rowContents","onChange"]))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(j(I.comp+"Operate")),{itemContents:I==null?void 0:I.compData,originalItemContents:I.compData,onChange:re=>O(re,I,R)},null,40,["itemContents","originalItemContents","onChange"]))])]),_:1},8,["collapseContents"])])}}}),Lv=pr._export_sfc(Ov,[["__scopeId","data-v-ba05456e"]]),Rv=typeof window<"u";var Vs;Rv&&((Vs=window==null?void 0:window.navigator)!=null&&Vs.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Bn(a){return a==null}function nu(){}const $v=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($v)));function Vv(){const a=new Map;return{on(l,r){const n=a.get(l);n!=null&&n.add(r)||a.set(l,new Set([r]))},off(l,r){const n=a.get(l);n&&n.delete(r)},clear(l){const r=a.get(l);r&&r.clear()},clearAll(){a.clear()},emit(l,...r){const n=a.get(l);n&&n.forEach(i=>{i(...r)})}}}function Fs(a,l=16){if(typeof a!="function")return nu;const r=(...o)=>{a(...o)};if(l<=0)return iu(r);let n=0,i;return function(...o){const p=Date.now(),c=p-n;clearTimeout(i),c>=l?(n=p,r(...o)):i=setTimeout(()=>{n=Date.now(),r(...o)},Math.max(0,l-c))}}function Fv(a,l=100){if(typeof a!="function")return nu;const r=(...i)=>{a(...i)};if(l<=0)return iu(r);let n;return function(...i){clearTimeout(n),n=setTimeout(()=>{r(...i)},l)}}function iu(a){if(typeof a!="function")return a;let l=!1,r,n;return function(...i){return r=i,l||(l=!0,n=Promise.resolve().then(()=>(l=!1,n=void 0,a(...r)))),n}}const Ji=new Set,ou=new WeakMap;function Pv(){Ji.forEach(a=>{a(...ou.get(a))}),Ji.clear()}function kn(a,...l){if(typeof a!="function")return a;ou.set(a,l),!Ji.has(a)&&(Ji.add(a),Ji.size===1&&Promise.resolve().then(Pv))}const tu=Symbol("LAYOUT_KEY"),su=Symbol("EMITTER_KEY");function jv(a){let l=0,r;for(let n=0,i=a.length;n<i;n++)r=a[n].y+a[n].h,r>l&&(l=r);return l}function Ot(a){const l=Array(a.length);for(let r=0,n=a.length;r<n;r++)l[r]=Hv(a[r]);return l}function Hv(a){return{...a}}function cu(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 zi(a,l,r){const n=du(a),i=pu(a),o=Array(a.length);for(let p=0,c=i.length;p<c;p++){let u=i[p];u.static||(u=Uv(n,u,l,r),n.push(u)),o[a.findIndex(m=>m.i===u.i)]=u,u.moved=!1}return o}function Uv(a,l,r,n){if(r)for(;l.y>0&&!Xi(a,l);)l.y--;else if(n){const o=n[l.i].y;for(;l.y>o&&!Xi(a,l);)l.y--}let i;for(;i=Xi(a,l);)l.y=i.y+i.h;return l}function qv(a,l){const r=du(a);for(let n=0,i=a.length;n<i;n++){const o=a[n];if(o.x+o.w>l.cols&&(o.x=l.cols-o.w),o.x<0&&(o.x=0,o.w=l.cols),!o.static)r.push(o);else for(;Xi(r,o);)o.y++}return a}function Ps(a,l){for(let r=0,n=a.length;r<n;r++)if(a[r].i===l)return a[r]}function Xi(a,l){for(let r=0,n=a.length;r<n;r++)if(cu(a[r],l))return a[r]}function uu(a,l){return a.filter(r=>cu(r,l))}function du(a){return a.filter(l=>l.static)}function Lt(a,l,r,n,i=!1,o=!1){if(l.static)return a;const p=l.x,c=l.y,u=n&&l.y>n;typeof r=="number"&&(l.x=r),typeof n=="number"&&(l.y=n),l.moved=!0;let m=pu(a);u&&(m=m.reverse());const g=uu(m,l);if(o&&g.length)return l.x=p,l.y=c,l.moved=!1,a;for(let y=0,d=g.length;y<d;y++){const D=g[y];D.moved||l.y>D.y&&l.y-D.y>D.h/4||(D.static?a=js(a,D,l,i):a=js(a,l,D,i))}return a}function js(a,l,r,n){if(n){const i={x:r.x,y:r.y,w:r.w,h:r.h};if(i.y=Math.max(l.y-r.h,0),!Xi(a,i))return Lt(a,r,void 0,i.y,!1)}return Lt(a,r,void 0,r.y+1,!1)}function Wv(a,l,r,n){const i="translate3d("+l+"px,"+a+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:r+"px",height:n+"px",position:"absolute"}}function Gv(a,l,r,n){const i="translate3d("+l*-1+"px,"+a+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:r+"px",height:n+"px",position:"absolute"}}function Kv(a,l,r,n){return{top:a+"px",left:l+"px",width:r+"px",height:n+"px",position:"absolute"}}function Yv(a,l,r,n){return{top:a+"px",right:l+"px",width:r+"px",height:n+"px",position:"absolute"}}function pu(a){return Array.from(a).sort(function(l,r){return l.y===r.y&&l.x===r.x?0:l.y>r.y||l.y===r.y&&l.x>r.x?1:-1})}function Jv(a,l){l=l||"Layout";const r=["x","y","w","h"],n=[];if(!Array.isArray(a))throw new Error(l+" must be an array!");for(let i=0,o=a.length;i<o;i++){const p=a[i];for(let c=0;c<r.length;c++)if(typeof p[r[c]]!="number")throw new Error("VueGridLayout: "+l+"["+i+"]."+r[c]+" must be a number!");if(p.i===void 0||p.i===null)throw new Error("VueGridLayout: "+l+"["+i+"].i cannot be null!");if(typeof p.i!="number"&&typeof p.i!="string")throw new Error("VueGridLayout: "+l+"["+i+"].i must be a string or number!");if(n.indexOf(p.i)>=0)throw new Error("VueGridLayout: "+l+"["+i+"].i must be unique!");if(n.push(p.i),p.static!==void 0&&typeof p.static!="boolean")throw new Error("VueGridLayout: "+l+"["+i+"].static must be a boolean!")}}function Xv(a,l="vgl"){const r=()=>`${l}-${a}`;return{b:r,be:n=>`${r()}__${n}`,bm:n=>`${r()}--${n}`,bem:(n,i)=>`${r()}__${n}--${i}`}}function Hs(a){return Zv(a)}function Zv(a){var l;const r=((l=a.target)==null?void 0:l.offsetParent)||document.body,n=a.offsetParent===document.body?{left:0,top:0}:r.getBoundingClientRect(),i=a.clientX+r.scrollLeft-n.left,o=a.clientY+r.scrollTop-n.top;return{x:i,y:o}}function Us(a,l,r,n){return Qv(a)?{deltaX:r-a,deltaY:n-l,lastX:a,lastY:l,x:r,y:n}:{deltaX:0,deltaY:0,lastX:r,lastY:n,x:r,y:n}}function Qv(a){return typeof a=="number"&&!Number.isNaN(a)}function e1(a,l){const r=hu(a);let n=r[0];for(let i=1,o=r.length;i<o;i++){const p=r[i];l>a[p]&&(n=p)}return n}function fu(a,l){if(!l[a])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+a+" is missing!");return l[a]}function a1(a,l,r,n,i,o,p){if(l[n])return Ot(l[n]);let c=a;const u=hu(r),m=u.slice(u.indexOf(n));for(let g=0,y=m.length;g<y;g++){const d=m[g];if(l[d]){c=l[d];break}}return c=Ot(c||[]),zi(qv(c,{cols:o}),p)}function hu(a){return Object.keys(a).sort((l,r)=>a[l]-a[r])}let l1="auto";function r1(){return typeof document<"u"}function qs(){return r1()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir"):l1}var Ki={exports:{}},n1=Ki.exports,Ws;function i1(){return Ws||(Ws=1,function(a,l){(function(r,n){a.exports=n()})(n1,function(){function r(s,t){var h=Object.keys(s);if(Object.getOwnPropertySymbols){var k=Object.getOwnPropertySymbols(s);t&&(k=k.filter(function(C){return Object.getOwnPropertyDescriptor(s,C).enumerable})),h.push.apply(h,k)}return h}function n(s){for(var t=1;t<arguments.length;t++){var h=arguments[t]!=null?arguments[t]:{};t%2?r(Object(h),!0).forEach(function(k){u(s,k,h[k])}):Object.getOwnPropertyDescriptors?Object.defineProperties(s,Object.getOwnPropertyDescriptors(h)):r(Object(h)).forEach(function(k){Object.defineProperty(s,k,Object.getOwnPropertyDescriptor(h,k))})}return s}function i(s){return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(s)}function o(s,t){if(!(s instanceof t))throw new TypeError("Cannot call a class as a function")}function p(s,t){for(var h=0;h<t.length;h++){var k=t[h];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(s,q(k.key),k)}}function c(s,t,h){return t&&p(s.prototype,t),Object.defineProperty(s,"prototype",{writable:!1}),s}function u(s,t,h){return(t=q(t))in s?Object.defineProperty(s,t,{value:h,enumerable:!0,configurable:!0,writable:!0}):s[t]=h,s}function m(s,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");s.prototype=Object.create(t&&t.prototype,{constructor:{value:s,writable:!0,configurable:!0}}),Object.defineProperty(s,"prototype",{writable:!1}),t&&y(s,t)}function g(s){return g=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},g(s)}function y(s,t){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(h,k){return h.__proto__=k,h},y(s,t)}function d(s){if(s===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return s}function D(s){var t=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 h,k=g(s);if(t){var C=g(this).constructor;h=Reflect.construct(k,arguments,C)}else h=k.apply(this,arguments);return function(F,Y){if(Y&&(typeof Y=="object"||typeof Y=="function"))return Y;if(Y!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return d(F)}(this,h)}}function w(){return w=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(s,t,h){var k=function(F,Y){for(;!Object.prototype.hasOwnProperty.call(F,Y)&&(F=g(F))!==null;);return F}(s,t);if(k){var C=Object.getOwnPropertyDescriptor(k,t);return C.get?C.get.call(arguments.length<3?s:h):C.value}},w.apply(this,arguments)}function q(s){var t=function(h,k){if(typeof h!="object"||h===null)return h;var C=h[Symbol.toPrimitive];if(C!==void 0){var F=C.call(h,k);if(typeof F!="object")return F;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(h)}(s,"string");return typeof t=="symbol"?t:t+""}var A=function(s){return!(!s||!s.Window)&&s instanceof s.Window},j=void 0,O=void 0;function E(s){j=s;var t=s.document.createTextNode("");t.ownerDocument!==s.document&&typeof s.wrap=="function"&&s.wrap(t)===t&&(s=s.wrap(s)),O=s}function _(s){return A(s)?s:(s.ownerDocument||s).defaultView||O.window}typeof window<"u"&&window&&E(window);var x=function(s){return!!s&&i(s)==="object"},b=function(s){return typeof s=="function"},S={window:function(s){return s===O||A(s)},docFrag:function(s){return x(s)&&s.nodeType===11},object:x,func:b,number:function(s){return typeof s=="number"},bool:function(s){return typeof s=="boolean"},string:function(s){return typeof s=="string"},element:function(s){if(!s||i(s)!=="object")return!1;var t=_(s)||O;return/object|function/.test(typeof Element>"u"?"undefined":i(Element))?s instanceof Element||s instanceof t.Element:s.nodeType===1&&typeof s.nodeName=="string"},plainObject:function(s){return x(s)&&!!s.constructor&&/function Object\b/.test(s.constructor.toString())},array:function(s){return x(s)&&s.length!==void 0&&b(s.splice)}};function I(s){var t=s.interaction;if(t.prepared.name==="drag"){var h=t.prepared.axis;h==="x"?(t.coords.cur.page.y=t.coords.start.page.y,t.coords.cur.client.y=t.coords.start.client.y,t.coords.velocity.client.y=0,t.coords.velocity.page.y=0):h==="y"&&(t.coords.cur.page.x=t.coords.start.page.x,t.coords.cur.client.x=t.coords.start.client.x,t.coords.velocity.client.x=0,t.coords.velocity.page.x=0)}}function R(s){var t=s.iEvent,h=s.interaction;if(h.prepared.name==="drag"){var k=h.prepared.axis;if(k==="x"||k==="y"){var C=k==="x"?"y":"x";t.page[C]=h.coords.start.page[C],t.client[C]=h.coords.start.client[C],t.delta[C]=0}}}var re={id:"actions/drag",install:function(s){var t=s.actions,h=s.Interactable,k=s.defaults;h.prototype.draggable=re.draggable,t.map.drag=re,t.methodDict.drag="draggable",k.actions.drag=re.defaults},listeners:{"interactions:before-action-move":I,"interactions:action-resume":I,"interactions:action-move":R,"auto-start:check":function(s){var t=s.interaction,h=s.interactable,k=s.buttons,C=h.options.drag;if(C&&C.enabled&&(!t.pointerIsDown||!/mouse|pointer/.test(t.pointerType)||(k&h.options.drag.mouseButtons)!=0))return s.action={name:"drag",axis:C.lockAxis==="start"?C.startAxis:C.lockAxis},!1}},draggable:function(s){return S.object(s)?(this.options.drag.enabled=s.enabled!==!1,this.setPerAction("drag",s),this.setOnEvents("drag",s),/^(xy|x|y|start)$/.test(s.lockAxis)&&(this.options.drag.lockAxis=s.lockAxis),/^(xy|x|y)$/.test(s.startAxis)&&(this.options.drag.startAxis=s.startAxis),this):S.bool(s)?(this.options.drag.enabled=s,this):this.options.drag},beforeMove:I,move:R,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor:function(){return"move"},filterEventType:function(s){return s.search("drag")===0}},X=re,me={init:function(s){var t=s;me.document=t.document,me.DocumentFragment=t.DocumentFragment||ue,me.SVGElement=t.SVGElement||ue,me.SVGSVGElement=t.SVGSVGElement||ue,me.SVGElementInstance=t.SVGElementInstance||ue,me.Element=t.Element||ue,me.HTMLElement=t.HTMLElement||me.Element,me.Event=t.Event,me.Touch=t.Touch||ue,me.PointerEvent=t.PointerEvent||t.MSPointerEvent},document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function ue(){}var U=me,W={init:function(s){var t=U.Element,h=s.navigator||{};W.supportsTouch="ontouchstart"in s||S.func(s.DocumentTouch)&&U.document instanceof s.DocumentTouch,W.supportsPointerEvent=h.pointerEnabled!==!1&&!!U.PointerEvent,W.isIOS=/iP(hone|od|ad)/.test(h.platform),W.isIOS7=/iP(hone|od|ad)/.test(h.platform)&&/OS 7[^\d]/.test(h.appVersion),W.isIe9=/MSIE 9/.test(h.userAgent),W.isOperaMobile=h.appName==="Opera"&&W.supportsTouch&&/Presto/.test(h.userAgent),W.prefixedMatchesSelector="matches"in t.prototype?"matches":"webkitMatchesSelector"in t.prototype?"webkitMatchesSelector":"mozMatchesSelector"in t.prototype?"mozMatchesSelector":"oMatchesSelector"in t.prototype?"oMatchesSelector":"msMatchesSelector",W.pEventTypes=W.supportsPointerEvent?U.PointerEvent===s.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,W.wheelEvent=U.document&&"onmousewheel"in U.document?"mousewheel":"wheel"},supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null},Z=W;function ae(s,t){if(s.contains)return s.contains(t);for(;t;){if(t===s)return!0;t=t.parentNode}return!1}function ve(s,t){for(;S.element(s);){if(te(s,t))return s;s=ze(s)}return null}function ze(s){var t=s.parentNode;if(S.docFrag(t)){for(;(t=t.host)&&S.docFrag(t););return t}return t}function te(s,t){return O!==j&&(t=t.replace(/\/deep\//g," ")),s[Z.prefixedMatchesSelector](t)}var N=function(s){return s.parentNode||s.host};function se(s,t){for(var h,k=[],C=s;(h=N(C))&&C!==t&&h!==C.ownerDocument;)k.unshift(C),C=h;return k}function G(s,t,h){for(;S.element(s);){if(te(s,t))return!0;if((s=ze(s))===h)return te(s,t)}return!1}function fe(s){return s.correspondingUseElement||s}function we(s){var t=s instanceof U.SVGElement?s.getBoundingClientRect():s.getClientRects()[0];return t&&{left:t.left,right:t.right,top:t.top,bottom:t.bottom,width:t.width||t.right-t.left,height:t.height||t.bottom-t.top}}function _e(s){var t,h=we(s);if(!Z.isIOS7&&h){var k={x:(t=(t=_(s))||O).scrollX||t.document.documentElement.scrollLeft,y:t.scrollY||t.document.documentElement.scrollTop};h.left+=k.x,h.right+=k.x,h.top+=k.y,h.bottom+=k.y}return h}function qe(s){for(var t=[];s;)t.push(s),s=ze(s);return t}function ra(s){return!!S.string(s)&&(U.document.querySelector(s),!0)}function P(s,t){for(var h in t)s[h]=t[h];return s}function Ke(s,t,h){return s==="parent"?ze(h):s==="self"?t.getRect(h):ve(h,s)}function Me(s,t,h,k){var C=s;return S.string(C)?C=Ke(C,t,h):S.func(C)&&(C=C.apply(void 0,k)),S.element(C)&&(C=_e(C)),C}function Le(s){return s&&{x:"x"in s?s.x:s.left,y:"y"in s?s.y:s.top}}function Ie(s){return!s||"x"in s&&"y"in s||((s=P({},s)).x=s.left||0,s.y=s.top||0,s.width=s.width||(s.right||0)-s.x,s.height=s.height||(s.bottom||0)-s.y),s}function de(s,t,h){s.left&&(t.left+=h.x),s.right&&(t.right+=h.x),s.top&&(t.top+=h.y),s.bottom&&(t.bottom+=h.y),t.width=t.right-t.left,t.height=t.bottom-t.top}function De(s,t,h){var k=h&&s.options[h];return Le(Me(k&&k.origin||s.options.origin,s,t,[s&&t]))||{x:0,y:0}}function Xe(s,t){var h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(xe){return!0},k=arguments.length>3?arguments[3]:void 0;if(k=k||{},S.string(s)&&s.search(" ")!==-1&&(s=Ea(s)),S.array(s))return s.forEach(function(xe){return Xe(xe,t,h,k)}),k;if(S.object(s)&&(t=s,s=""),S.func(t)&&h(s))k[s]=k[s]||[],k[s].push(t);else if(S.array(t))for(var C=0,F=t;C<F.length;C++){var Y=F[C];Xe(s,Y,h,k)}else if(S.object(t))for(var J in t)Xe(Ea(J).map(function(xe){return"".concat(s).concat(xe)}),t[J],h,k);return k}function Ea(s){return s.trim().split(/ +/)}var Ge=function(s,t){return Math.sqrt(s*s+t*t)},$=["webkit","moz"];function V(s,t){s.__set||(s.__set={});var h=function(C){if($.some(function(F){return C.indexOf(F)===0}))return 1;typeof s[C]!="function"&&C!=="__set"&&Object.defineProperty(s,C,{get:function(){return C in s.__set?s.__set[C]:s.__set[C]=t[C]},set:function(F){s.__set[C]=F},configurable:!0})};for(var k in t)h(k);return s}function ee(s,t){s.page=s.page||{},s.page.x=t.page.x,s.page.y=t.page.y,s.client=s.client||{},s.client.x=t.client.x,s.client.y=t.client.y,s.timeStamp=t.timeStamp}function ce(s){s.page.x=0,s.page.y=0,s.client.x=0,s.client.y=0}function he(s){return s instanceof U.Event||s instanceof U.Touch}function pa(s,t,h){return s=s||"page",(h=h||{}).x=t[s+"X"],h.y=t[s+"Y"],h}function ia(s,t){return t=t||{x:0,y:0},Z.isOperaMobile&&he(s)?(pa("screen",s,t),t.x+=window.scrollX,t.y+=window.scrollY):pa("page",s,t),t}function Ve(s){return S.number(s.pointerId)?s.pointerId:s.identifier}function ya(s,t,h){var k=t.length>1?Ce(t):t[0];ia(k,s.page),function(C,F){F=F||{},Z.isOperaMobile&&he(C)?pa("screen",C,F):pa("client",C,F)}(k,s.client),s.timeStamp=h}function Ca(s){var t=[];return S.array(s)?(t[0]=s[0],t[1]=s[1]):s.type==="touchend"?s.touches.length===1?(t[0]=s.touches[0],t[1]=s.changedTouches[0]):s.touches.length===0&&(t[0]=s.changedTouches[0],t[1]=s.changedTouches[1]):(t[0]=s.touches[0],t[1]=s.touches[1]),t}function Ce(s){for(var t={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0},h=0;h<s.length;h++){var k=s[h];for(var C in t)t[C]+=k[C]}for(var F in t)t[F]/=s.length;return t}function Fa(s){if(!s.length)return null;var t=Ca(s),h=Math.min(t[0].pageX,t[1].pageX),k=Math.min(t[0].pageY,t[1].pageY),C=Math.max(t[0].pageX,t[1].pageX),F=Math.max(t[0].pageY,t[1].pageY);return{x:h,y:k,left:h,top:k,right:C,bottom:F,width:C-h,height:F-k}}function Ta(s,t){var h=t+"X",k=t+"Y",C=Ca(s),F=C[0][h]-C[1][h],Y=C[0][k]-C[1][k];return Ge(F,Y)}function fa(s,t){var h=t+"X",k=t+"Y",C=Ca(s),F=C[1][h]-C[0][h],Y=C[1][k]-C[0][k];return 180*Math.atan2(Y,F)/Math.PI}function ja(s){return S.string(s.pointerType)?s.pointerType:S.number(s.pointerType)?[void 0,void 0,"touch","pen","mouse"][s.pointerType]:/touch/.test(s.type||"")||s instanceof U.Touch?"touch":"mouse"}function sa(s){var t=S.func(s.composedPath)?s.composedPath():s.path;return[fe(t?t[0]:s.target),fe(s.currentTarget)]}var Pe=function(){function s(t){o(this,s),this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=t}return c(s,[{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),s}();Object.defineProperty(Pe.prototype,"interaction",{get:function(){return this._interaction._proxy},set:function(){}});var ma=function(s,t){for(var h=0;h<t.length;h++){var k=t[h];s.push(k)}return s},Qe=function(s){return ma([],s)},Oe=function(s,t){for(var h=0;h<s.length;h++)if(t(s[h],h,s))return h;return-1},$e=function(s,t){return s[Oe(s,t)]},ne=function(s){m(h,s);var t=D(h);function h(k,C,F){var Y;o(this,h),(Y=t.call(this,C._interaction)).dropzone=void 0,Y.dragEvent=void 0,Y.relatedTarget=void 0,Y.draggable=void 0,Y.propagationStopped=!1,Y.immediatePropagationStopped=!1;var J=F==="dragleave"?k.prev:k.cur,xe=J.element,He=J.dropzone;return Y.type=F,Y.target=xe,Y.currentTarget=xe,Y.dropzone=He,Y.dragEvent=C,Y.relatedTarget=C.target,Y.draggable=C.interactable,Y.timeStamp=C.timeStamp,Y}return c(h,[{key:"reject",value:function(){var k=this,C=this._interaction.dropState;if(this.type==="dropactivate"||this.dropzone&&C.cur.dropzone===this.dropzone&&C.cur.element===this.target)if(C.prev.dropzone=this.dropzone,C.prev.element=this.target,C.rejected=!0,C.events.enter=null,this.stopImmediatePropagation(),this.type==="dropactivate"){var F=C.activeDrops,Y=Oe(F,function(xe){var He=xe.dropzone,Se=xe.element;return He===k.dropzone&&Se===k.target});C.activeDrops.splice(Y,1);var J=new h(C,this.dragEvent,"dropdeactivate");J.dropzone=this.dropzone,J.target=this.target,this.dropzone.fire(J)}else this.dropzone.fire(new h(C,this.dragEvent,"dragleave"))}},{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),h}(Pe);function We(s,t){for(var h=0,k=s.slice();h<k.length;h++){var C=k[h],F=C.dropzone,Y=C.element;t.dropzone=F,t.target=Y,F.fire(t),t.propagationStopped=t.immediatePropagationStopped=!1}}function na(s,t){for(var h=function(F,Y){for(var J=[],xe=0,He=F.interactables.list;xe<He.length;xe++){var Se=He[xe];if(Se.options.drop.enabled){var da=Se.options.drop.accept;if(!(S.element(da)&&da!==Y||S.string(da)&&!te(Y,da)||S.func(da)&&!da({dropzone:Se,draggableElement:Y})))for(var Ma=0,rl=Se.getAllElements();Ma<rl.length;Ma++){var el=rl[Ma];el!==Y&&J.push({dropzone:Se,element:el,rect:Se.getRect(el)})}}}return J}(s,t),k=0;k<h.length;k++){var C=h[k];C.rect=C.dropzone.getRect(C.element)}return h}function va(s,t,h){for(var k=s.dropState,C=s.interactable,F=s.element,Y=[],J=0,xe=k.activeDrops;J<xe.length;J++){var He=xe[J],Se=He.dropzone,da=He.element,Ma=He.rect,rl=Se.dropCheck(t,h,C,F,da,Ma);Y.push(rl?da:null)}var el=function(cl){for(var Dl,El,Vl,ir=[],fr=0;fr<cl.length;fr++){var ql=cl[fr],sr=cl[Dl];if(ql&&fr!==Dl)if(sr){var dn=N(ql),ar=N(sr);if(dn!==ql.ownerDocument)if(ar!==ql.ownerDocument)if(dn!==ar){ir=ir.length?ir:se(sr);var bn=void 0;if(sr instanceof U.HTMLElement&&ql instanceof U.SVGElement&&!(ql instanceof U.SVGSVGElement)){if(ql===ar)continue;bn=ql.ownerSVGElement}else bn=ql;for(var Xr=se(bn,sr.ownerDocument),Rn=0;Xr[Rn]&&Xr[Rn]===ir[Rn];)Rn++;var yn=[Xr[Rn-1],Xr[Rn],ir[Rn]];if(yn[0])for(var pi=yn[0].lastChild;pi;){if(pi===yn[1]){Dl=fr,ir=Xr;break}if(pi===yn[2])break;pi=pi.previousSibling}}else Vl=sr,(parseInt(_(El=ql).getComputedStyle(El).zIndex,10)||0)>=(parseInt(_(Vl).getComputedStyle(Vl).zIndex,10)||0)&&(Dl=fr);else Dl=fr}else Dl=fr}return Dl}(Y);return k.activeDrops[el]||null}function Ae(s,t,h){var k=s.dropState,C={enter:null,leave:null,activate:null,deactivate:null,move:null,drop:null};return h.type==="dragstart"&&(C.activate=new ne(k,h,"dropactivate"),C.activate.target=null,C.activate.dropzone=null),h.type==="dragend"&&(C.deactivate=new ne(k,h,"dropdeactivate"),C.deactivate.target=null,C.deactivate.dropzone=null),k.rejected||(k.cur.element!==k.prev.element&&(k.prev.dropzone&&(C.leave=new ne(k,h,"dragleave"),h.dragLeave=C.leave.target=k.prev.element,h.prevDropzone=C.leave.dropzone=k.prev.dropzone),k.cur.dropzone&&(C.enter=new ne(k,h,"dragenter"),h.dragEnter=k.cur.element,h.dropzone=k.cur.dropzone)),h.type==="dragend"&&k.cur.dropzone&&(C.drop=new ne(k,h,"drop"),h.dropzone=k.cur.dropzone,h.relatedTarget=k.cur.element),h.type==="dragmove"&&k.cur.dropzone&&(C.move=new ne(k,h,"dropmove"),h.dropzone=k.cur.dropzone)),C}function Be(s,t){var h=s.dropState,k=h.activeDrops,C=h.cur,F=h.prev;t.leave&&F.dropzone.fire(t.leave),t.enter&&C.dropzone.fire(t.enter),t.move&&C.dropzone.fire(t.move),t.drop&&C.dropzone.fire(t.drop),t.deactivate&&We(k,t.deactivate),h.prev.dropzone=C.dropzone,h.prev.element=C.element}function Ye(s,t){var h=s.interaction,k=s.iEvent,C=s.event;if(k.type==="dragmove"||k.type==="dragend"){var F=h.dropState;t.dynamicDrop&&(F.activeDrops=na(t,h.element));var Y=k,J=va(h,Y,C);F.rejected=F.rejected&&!!J&&J.dropzone===F.cur.dropzone&&J.element===F.cur.element,F.cur.dropzone=J&&J.dropzone,F.cur.element=J&&J.element,F.events=Ae(h,0,Y)}}var Ee={id:"actions/drop",install:function(s){var t=s.actions,h=s.interactStatic,k=s.Interactable,C=s.defaults;s.usePlugin(X),k.prototype.dropzone=function(F){return function(Y,J){if(S.object(J)){if(Y.options.drop.enabled=J.enabled!==!1,J.listeners){var xe=Xe(J.listeners),He=Object.keys(xe).reduce(function(da,Ma){return da[/^(enter|leave)/.test(Ma)?"drag".concat(Ma):/^(activate|deactivate|move)/.test(Ma)?"drop".concat(Ma):Ma]=xe[Ma],da},{}),Se=Y.options.drop.listeners;Se&&Y.off(Se),Y.on(He),Y.options.drop.listeners=He}return S.func(J.ondrop)&&Y.on("drop",J.ondrop),S.func(J.ondropactivate)&&Y.on("dropactivate",J.ondropactivate),S.func(J.ondropdeactivate)&&Y.on("dropdeactivate",J.ondropdeactivate),S.func(J.ondragenter)&&Y.on("dragenter",J.ondragenter),S.func(J.ondragleave)&&Y.on("dragleave",J.ondragleave),S.func(J.ondropmove)&&Y.on("dropmove",J.ondropmove),/^(pointer|center)$/.test(J.overlap)?Y.options.drop.overlap=J.overlap:S.number(J.overlap)&&(Y.options.drop.overlap=Math.max(Math.min(1,J.overlap),0)),"accept"in J&&(Y.options.drop.accept=J.accept),"checker"in J&&(Y.options.drop.checker=J.checker),Y}return S.bool(J)?(Y.options.drop.enabled=J,Y):Y.options.drop}(this,F)},k.prototype.dropCheck=function(F,Y,J,xe,He,Se){return function(da,Ma,rl,el,cl,Dl,El){var Vl=!1;if(!(El=El||da.getRect(Dl)))return!!da.options.drop.checker&&da.options.drop.checker(Ma,rl,Vl,da,Dl,el,cl);var ir=da.options.drop.overlap;if(ir==="pointer"){var fr=De(el,cl,"drag"),ql=ia(Ma);ql.x+=fr.x,ql.y+=fr.y;var sr=ql.x>El.left&&ql.x<El.right,dn=ql.y>El.top&&ql.y<El.bottom;Vl=sr&&dn}var ar=el.getRect(cl);if(ar&&ir==="center"){var bn=ar.left+ar.width/2,Xr=ar.top+ar.height/2;Vl=bn>=El.left&&bn<=El.right&&Xr>=El.top&&Xr<=El.bottom}return ar&&S.number(ir)&&(Vl=Math.max(0,Math.min(El.right,ar.right)-Math.max(El.left,ar.left))*Math.max(0,Math.min(El.bottom,ar.bottom)-Math.max(El.top,ar.top))/(ar.width*ar.height)>=ir),da.options.drop.checker&&(Vl=da.options.drop.checker(Ma,rl,Vl,da,Dl,el,cl)),Vl}(this,F,Y,J,xe,He,Se)},h.dynamicDrop=function(F){return S.bool(F)?(s.dynamicDrop=F,h):s.dynamicDrop},P(t.phaselessTypes,{dragenter:!0,dragleave:!0,dropactivate:!0,dropdeactivate:!0,dropmove:!0,drop:!0}),t.methodDict.drop="dropzone",s.dynamicDrop=!1,C.actions.drop=Ee.defaults},listeners:{"interactions:before-action-start":function(s){var t=s.interaction;t.prepared.name==="drag"&&(t.dropState={cur:{dropzone:null,element:null},prev:{dropzone:null,element:null},rejected:null,events:null,activeDrops:[]})},"interactions:after-action-start":function(s,t){var h=s.interaction,k=(s.event,s.iEvent);if(h.prepared.name==="drag"){var C=h.dropState;C.activeDrops=[],C.events={},C.activeDrops=na(t,h.element),C.events=Ae(h,0,k),C.events.activate&&(We(C.activeDrops,C.events.activate),t.fire("actions/drop:start",{interaction:h,dragEvent:k}))}},"interactions:action-move":Ye,"interactions:after-action-move":function(s,t){var h=s.interaction,k=s.iEvent;if(h.prepared.name==="drag"){var C=h.dropState;Be(h,C.events),t.fire("actions/drop:move",{interaction:h,dragEvent:k}),C.events={}}},"interactions:action-end":function(s,t){if(s.interaction.prepared.name==="drag"){var h=s.interaction,k=s.iEvent;Ye(s,t),Be(h,h.dropState.events),t.fire("actions/drop:end",{interaction:h,dragEvent:k})}},"interactions:stop":function(s){var t=s.interaction;if(t.prepared.name==="drag"){var h=t.dropState;h&&(h.activeDrops=null,h.events=null,h.cur.dropzone=null,h.cur.element=null,h.prev.dropzone=null,h.prev.element=null,h.rejected=!1)}}},getActiveDrops:na,getDrop:va,getDropEvents:Ae,fireDropEvents:Be,filterEventType:function(s){return s.search("drag")===0||s.search("drop")===0},defaults:{enabled:!1,accept:null,overlap:"pointer"}},ye=Ee;function $a(s){var t=s.interaction,h=s.iEvent,k=s.phase;if(t.prepared.name==="gesture"){var C=t.pointers.map(function(He){return He.pointer}),F=k==="start",Y=k==="end",J=t.interactable.options.deltaSource;if(h.touches=[C[0],C[1]],F)h.distance=Ta(C,J),h.box=Fa(C),h.scale=1,h.ds=0,h.angle=fa(C,J),h.da=0,t.gesture.startDistance=h.distance,t.gesture.startAngle=h.angle;else if(Y||t.pointers.length<2){var xe=t.prevEvent;h.distance=xe.distance,h.box=xe.box,h.scale=xe.scale,h.ds=0,h.angle=xe.angle,h.da=0}else h.distance=Ta(C,J),h.box=Fa(C),h.scale=h.distance/t.gesture.startDistance,h.angle=fa(C,J),h.ds=h.scale-t.gesture.scale,h.da=h.angle-t.gesture.angle;t.gesture.distance=h.distance,t.gesture.angle=h.angle,S.number(h.scale)&&h.scale!==1/0&&!isNaN(h.scale)&&(t.gesture.scale=h.scale)}}var wl={id:"actions/gesture",before:["actions/drag","actions/resize"],install:function(s){var t=s.actions,h=s.Interactable,k=s.defaults;h.prototype.gesturable=function(C){return S.object(C)?(this.options.gesture.enabled=C.enabled!==!1,this.setPerAction("gesture",C),this.setOnEvents("gesture",C),this):S.bool(C)?(this.options.gesture.enabled=C,this):this.options.gesture},t.map.gesture=wl,t.methodDict.gesture="gesturable",k.actions.gesture=wl.defaults},listeners:{"interactions:action-start":$a,"interactions:action-move":$a,"interactions:action-end":$a,"interactions:new":function(s){s.interaction.gesture={angle:0,distance:0,scale:1,startAngle:0,startDistance:0}},"auto-start:check":function(s){if(!(s.interaction.pointers.length<2)){var t=s.interactable.options.gesture;if(t&&t.enabled)return s.action={name:"gesture"},!1}}},defaults:{},getCursor:function(){return""},filterEventType:function(s){return s.search("gesture")===0}},Qa=wl;function Pl(s,t,h,k,C,F,Y){if(!t)return!1;if(t===!0){var J=S.number(F.width)?F.width:F.right-F.left,xe=S.number(F.height)?F.height:F.bottom-F.top;if(Y=Math.min(Y,Math.abs((s==="left"||s==="right"?J:xe)/2)),J<0&&(s==="left"?s="right":s==="right"&&(s="left")),xe<0&&(s==="top"?s="bottom":s==="bottom"&&(s="top")),s==="left"){var He=J>=0?F.left:F.right;return h.x<He+Y}if(s==="top"){var Se=xe>=0?F.top:F.bottom;return h.y<Se+Y}if(s==="right")return h.x>(J>=0?F.right:F.left)-Y;if(s==="bottom")return h.y>(xe>=0?F.bottom:F.top)-Y}return!!S.element(k)&&(S.element(t)?t===k:G(k,t,C))}function gl(s){var t=s.iEvent,h=s.interaction;if(h.prepared.name==="resize"&&h.resizeAxes){var k=t;h.interactable.options.resize.square?(h.resizeAxes==="y"?k.delta.x=k.delta.y:k.delta.y=k.delta.x,k.axes="xy"):(k.axes=h.resizeAxes,h.resizeAxes==="x"?k.delta.y=0:h.resizeAxes==="y"&&(k.delta.x=0))}}var jl,al,Hl={id:"actions/resize",before:["actions/drag"],install:function(s){var t=s.actions,h=s.browser,k=s.Interactable,C=s.defaults;Hl.cursors=function(F){return F.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"}}(h),Hl.defaultMargin=h.supportsTouch||h.supportsPointerEvent?20:10,k.prototype.resizable=function(F){return function(Y,J,xe){return S.object(J)?(Y.options.resize.enabled=J.enabled!==!1,Y.setPerAction("resize",J),Y.setOnEvents("resize",J),S.string(J.axis)&&/^x$|^y$|^xy$/.test(J.axis)?Y.options.resize.axis=J.axis:J.axis===null&&(Y.options.resize.axis=xe.defaults.actions.resize.axis),S.bool(J.preserveAspectRatio)?Y.options.resize.preserveAspectRatio=J.preserveAspectRatio:S.bool(J.square)&&(Y.options.resize.square=J.square),Y):S.bool(J)?(Y.options.resize.enabled=J,Y):Y.options.resize}(this,F,s)},t.map.resize=Hl,t.methodDict.resize="resizable",C.actions.resize=Hl.defaults},listeners:{"interactions:new":function(s){s.interaction.resizeAxes="xy"},"interactions:action-start":function(s){(function(t){var h=t.iEvent,k=t.interaction;if(k.prepared.name==="resize"&&k.prepared.edges){var C=h,F=k.rect;k._rects={start:P({},F),corrected:P({},F),previous:P({},F),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},C.edges=k.prepared.edges,C.rect=k._rects.corrected,C.deltaRect=k._rects.delta}})(s),gl(s)},"interactions:action-move":function(s){(function(t){var h=t.iEvent,k=t.interaction;if(k.prepared.name==="resize"&&k.prepared.edges){var C=h,F=k.interactable.options.resize.invert,Y=F==="reposition"||F==="negate",J=k.rect,xe=k._rects,He=xe.start,Se=xe.corrected,da=xe.delta,Ma=xe.previous;if(P(Ma,Se),Y){if(P(Se,J),F==="reposition"){if(Se.top>Se.bottom){var rl=Se.top;Se.top=Se.bottom,Se.bottom=rl}if(Se.left>Se.right){var el=Se.left;Se.left=Se.right,Se.right=el}}}else Se.top=Math.min(J.top,He.bottom),Se.bottom=Math.max(J.bottom,He.top),Se.left=Math.min(J.left,He.right),Se.right=Math.max(J.right,He.left);for(var cl in Se.width=Se.right-Se.left,Se.height=Se.bottom-Se.top,Se)da[cl]=Se[cl]-Ma[cl];C.edges=k.prepared.edges,C.rect=Se,C.deltaRect=da}})(s),gl(s)},"interactions:action-end":function(s){var t=s.iEvent,h=s.interaction;if(h.prepared.name==="resize"&&h.prepared.edges){var k=t;k.edges=h.prepared.edges,k.rect=h._rects.corrected,k.deltaRect=h._rects.delta}},"auto-start:check":function(s){var t=s.interaction,h=s.interactable,k=s.element,C=s.rect,F=s.buttons;if(C){var Y=P({},t.coords.cur.page),J=h.options.resize;if(J&&J.enabled&&(!t.pointerIsDown||!/mouse|pointer/.test(t.pointerType)||(F&J.mouseButtons)!=0)){if(S.object(J.edges)){var xe={left:!1,right:!1,top:!1,bottom:!1};for(var He in xe)xe[He]=Pl(He,J.edges[He],Y,t._latestPointer.eventTarget,k,C,J.margin||Hl.defaultMargin);xe.left=xe.left&&!xe.right,xe.top=xe.top&&!xe.bottom,(xe.left||xe.right||xe.top||xe.bottom)&&(s.action={name:"resize",edges:xe})}else{var Se=J.axis!=="y"&&Y.x>C.right-Hl.defaultMargin,da=J.axis!=="x"&&Y.y>C.bottom-Hl.defaultMargin;(Se||da)&&(s.action={name:"resize",axes:(Se?"x":"")+(da?"y":"")})}return!s.action&&void 0}}}},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor:function(s){var t=s.edges,h=s.axis,k=s.name,C=Hl.cursors,F=null;if(h)F=C[k+h];else if(t){for(var Y="",J=0,xe=["top","bottom","left","right"];J<xe.length;J++){var He=xe[J];t[He]&&(Y+=He)}F=C[Y]}return F},filterEventType:function(s){return s.search("resize")===0},defaultMargin:null},Wa=Hl,Gl={id:"actions",install:function(s){s.usePlugin(Qa),s.usePlugin(Wa),s.usePlugin(X),s.usePlugin(ye)}},Kl=0,Zl={request:function(s){return jl(s)},cancel:function(s){return al(s)},init:function(s){if(jl=s.requestAnimationFrame,al=s.cancelAnimationFrame,!jl)for(var t=["ms","moz","webkit","o"],h=0;h<t.length;h++){var k=t[h];jl=s["".concat(k,"RequestAnimationFrame")],al=s["".concat(k,"CancelAnimationFrame")]||s["".concat(k,"CancelRequestAnimationFrame")]}jl=jl&&jl.bind(s),al=al&&al.bind(s),jl||(jl=function(C){var F=Date.now(),Y=Math.max(0,16-(F-Kl)),J=s.setTimeout(function(){C(F+Y)},Y);return Kl=F+Y,J},al=function(C){return clearTimeout(C)})}},Sl={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(s){Sl.isScrolling=!0,Zl.cancel(Sl.i),s.autoScroll=Sl,Sl.interaction=s,Sl.prevTime=Sl.now(),Sl.i=Zl.request(Sl.scroll)},stop:function(){Sl.isScrolling=!1,Sl.interaction&&(Sl.interaction.autoScroll=null),Zl.cancel(Sl.i)},scroll:function(){var s=Sl.interaction,t=s.interactable,h=s.element,k=s.prepared.name,C=t.options[k].autoScroll,F=dr(C.container,t,h),Y=Sl.now(),J=(Y-Sl.prevTime)/1e3,xe=C.speed*J;if(xe>=1){var He={x:Sl.x*xe,y:Sl.y*xe};if(He.x||He.y){var Se=ga(F);S.window(F)?F.scrollBy(He.x,He.y):F&&(F.scrollLeft+=He.x,F.scrollTop+=He.y);var da=ga(F),Ma={x:da.x-Se.x,y:da.y-Se.y};(Ma.x||Ma.y)&&t.fire({type:"autoscroll",target:h,interactable:t,delta:Ma,interaction:s,container:F})}Sl.prevTime=Y}Sl.isScrolling&&(Zl.cancel(Sl.i),Sl.i=Zl.request(Sl.scroll))},check:function(s,t){var h;return(h=s.options[t].autoScroll)==null?void 0:h.enabled},onInteractionMove:function(s){var t=s.interaction,h=s.pointer;if(t.interacting()&&Sl.check(t.interactable,t.prepared.name))if(t.simulation)Sl.x=Sl.y=0;else{var k,C,F,Y,J=t.interactable,xe=t.element,He=t.prepared.name,Se=J.options[He].autoScroll,da=dr(Se.container,J,xe);if(S.window(da))Y=h.clientX<Sl.margin,k=h.clientY<Sl.margin,C=h.clientX>da.innerWidth-Sl.margin,F=h.clientY>da.innerHeight-Sl.margin;else{var Ma=we(da);Y=h.clientX<Ma.left+Sl.margin,k=h.clientY<Ma.top+Sl.margin,C=h.clientX>Ma.right-Sl.margin,F=h.clientY>Ma.bottom-Sl.margin}Sl.x=C?1:Y?-1:0,Sl.y=F?1:k?-1:0,Sl.isScrolling||(Sl.margin=Se.margin,Sl.speed=Se.speed,Sl.start(t))}}};function dr(s,t,h){return(S.string(s)?Ke(s,t,h):s)||_(h)}function ga(s){return S.window(s)&&(s=window.document.body),{x:s.scrollLeft,y:s.scrollTop}}var il={id:"auto-scroll",install:function(s){var t=s.defaults,h=s.actions;s.autoScroll=Sl,Sl.now=function(){return s.now()},h.phaselessTypes.autoscroll=!0,t.perAction.autoScroll=Sl.defaults},listeners:{"interactions:new":function(s){s.interaction.autoScroll=null},"interactions:destroy":function(s){s.interaction.autoScroll=null,Sl.stop(),Sl.interaction&&(Sl.interaction=null)},"interactions:stop":Sl.stop,"interactions:action-move":function(s){return Sl.onInteractionMove(s)}}},fl=il;function Bl(s,t){var h=!1;return function(){return h||(O.console.warn(t),h=!0),s.apply(this,arguments)}}function Ha(s,t){return s.name=t.name,s.axis=t.axis,s.edges=t.edges,s}function Sa(s){return S.bool(s)?(this.options.styleCursor=s,this):s===null?(delete this.options.styleCursor,this):this.options.styleCursor}function ll(s){return S.func(s)?(this.options.actionChecker=s,this):s===null?(delete this.options.actionChecker,this):this.options.actionChecker}var Te={id:"auto-start/interactableMethods",install:function(s){var t=s.Interactable;t.prototype.getAction=function(h,k,C,F){var Y=function(J,xe,He,Se,da){var Ma=J.getRect(Se),rl=xe.buttons||{0:1,1:4,3:8,4:16}[xe.button],el={action:null,interactable:J,interaction:He,element:Se,rect:Ma,buttons:rl};return da.fire("auto-start:check",el),el.action}(this,k,C,F,s);return this.options.actionChecker?this.options.actionChecker(h,k,Y,this,F,C):Y},t.prototype.ignoreFrom=Bl(function(h){return this._backCompatOption("ignoreFrom",h)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),t.prototype.allowFrom=Bl(function(h){return this._backCompatOption("allowFrom",h)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),t.prototype.actionChecker=ll,t.prototype.styleCursor=Sa}};function oa(s,t,h,k,C){return t.testIgnoreAllow(t.options[s.name],h,k)&&t.options[s.name].enabled&&Pa(t,h,s,C)?s:null}function Ka(s,t,h,k,C,F,Y){for(var J=0,xe=k.length;J<xe;J++){var He=k[J],Se=C[J],da=He.getAction(t,h,s,Se);if(da){var Ma=oa(da,He,Se,F,Y);if(Ma)return{action:Ma,interactable:He,element:Se}}}return{action:null,interactable:null,element:null}}function pe(s,t,h,k,C){var F=[],Y=[],J=k;function xe(Se){F.push(Se),Y.push(J)}for(;S.element(J);){F=[],Y=[],C.interactables.forEachMatch(J,xe);var He=Ka(s,t,h,F,Y,k,C);if(He.action&&!He.interactable.options[He.action.name].manualStart)return He;J=ze(J)}return{action:null,interactable:null,element:null}}function _a(s,t,h){var k=t.action,C=t.interactable,F=t.element;k=k||{name:null},s.interactable=C,s.element=F,Ha(s.prepared,k),s.rect=C&&k.name?C.getRect(F):null,ca(s,h),h.fire("autoStart:prepared",{interaction:s})}function Pa(s,t,h,k){var C=s.options,F=C[h.name].max,Y=C[h.name].maxPerElement,J=k.autoStart.maxInteractions,xe=0,He=0,Se=0;if(!(F&&Y&&J))return!1;for(var da=0,Ma=k.interactions.list;da<Ma.length;da++){var rl=Ma[da],el=rl.prepared.name;if(rl.interacting()&&(++xe>=J||rl.interactable===s&&((He+=el===h.name?1:0)>=F||rl.element===t&&(Se++,el===h.name&&Se>=Y))))return!1}return J>0}function ul(s,t){return S.number(s)?(t.autoStart.maxInteractions=s,this):t.autoStart.maxInteractions}function Ol(s,t,h){var k=h.autoStart.cursorElement;k&&k!==s&&(k.style.cursor=""),s.ownerDocument.documentElement.style.cursor=t,s.style.cursor=t,h.autoStart.cursorElement=t?s:null}function ca(s,t){var h=s.interactable,k=s.element,C=s.prepared;if(s.pointerType==="mouse"&&h&&h.options.styleCursor){var F="";if(C.name){var Y=h.options[C.name].cursorChecker;F=S.func(Y)?Y(C,h,k,s._interacting):t.actions.map[C.name].getCursor(C)}Ol(s.element,F||"",t)}else t.autoStart.cursorElement&&Ol(t.autoStart.cursorElement,"",t)}var Xa={id:"auto-start/base",before:["actions"],install:function(s){var t=s.interactStatic,h=s.defaults;s.usePlugin(Te),h.base.actionChecker=null,h.base.styleCursor=!0,P(h.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),t.maxInteractions=function(k){return ul(k,s)},s.autoStart={maxInteractions:1/0,withinInteractionLimit:Pa,cursorElement:null}},listeners:{"interactions:down":function(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget;h.interacting()||_a(h,pe(h,k,C,F,t),t)},"interactions:move":function(s,t){(function(h,k){var C=h.interaction,F=h.pointer,Y=h.event,J=h.eventTarget;C.pointerType!=="mouse"||C.pointerIsDown||C.interacting()||_a(C,pe(C,F,Y,J,k),k)})(s,t),function(h,k){var C=h.interaction;if(C.pointerIsDown&&!C.interacting()&&C.pointerWasMoved&&C.prepared.name){k.fire("autoStart:before-start",h);var F=C.interactable,Y=C.prepared.name;Y&&F&&(F.options[Y].manualStart||!Pa(F,C.element,C.prepared,k)?C.stop():(C.start(C.prepared,F,C.element),ca(C,k)))}}(s,t)},"interactions:stop":function(s,t){var h=s.interaction,k=h.interactable;k&&k.options.styleCursor&&Ol(h.element,"",t)}},maxInteractions:ul,withinInteractionLimit:Pa,validateAction:oa},ua=Xa,wa={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":function(s,t){var h=s.interaction,k=s.eventTarget,C=s.dx,F=s.dy;if(h.prepared.name==="drag"){var Y=Math.abs(C),J=Math.abs(F),xe=h.interactable.options.drag,He=xe.startAxis,Se=Y>J?"x":Y<J?"y":"xy";if(h.prepared.axis=xe.lockAxis==="start"?Se[0]:xe.lockAxis,Se!=="xy"&&He!=="xy"&&He!==Se){h.prepared.name=null;for(var da=k,Ma=function(el){if(el!==h.interactable){var cl=h.interactable.options.drag;if(!cl.manualStart&&el.testIgnoreAllow(cl,da,k)){var Dl=el.getAction(h.downPointer,h.downEvent,h,da);if(Dl&&Dl.name==="drag"&&function(El,Vl){if(!Vl)return!1;var ir=Vl.options.drag.startAxis;return El==="xy"||ir==="xy"||ir===El}(Se,el)&&ua.validateAction(Dl,el,da,k,t))return el}}};S.element(da);){var rl=t.interactables.forEachMatch(da,Ma);if(rl){h.prepared.name="drag",h.interactable=rl,h.element=da;break}da=ze(da)}}}}}};function Ba(s){var t=s.prepared&&s.prepared.name;if(!t)return null;var h=s.interactable.options;return h[t].hold||h[t].delay}var hl={id:"auto-start/hold",install:function(s){var t=s.defaults;s.usePlugin(ua),t.perAction.hold=0,t.perAction.delay=0},listeners:{"interactions:new":function(s){s.interaction.autoStartHoldTimer=null},"autoStart:prepared":function(s){var t=s.interaction,h=Ba(t);h>0&&(t.autoStartHoldTimer=setTimeout(function(){t.start(t.prepared,t.interactable,t.element)},h))},"interactions:move":function(s){var t=s.interaction,h=s.duplicate;t.autoStartHoldTimer&&t.pointerWasMoved&&!h&&(clearTimeout(t.autoStartHoldTimer),t.autoStartHoldTimer=null)},"autoStart:before-start":function(s){var t=s.interaction;Ba(t)>0&&(t.prepared.name=null)}},getHoldDuration:Ba},Fe=hl,bl={id:"auto-start",install:function(s){s.usePlugin(ua),s.usePlugin(Fe),s.usePlugin(wa)}},tr=function(s){return/^(always|never|auto)$/.test(s)?(this.options.preventDefault=s,this):S.bool(s)?(this.options.preventDefault=s?"always":"never",this):this.options.preventDefault};function xr(s){var t=s.interaction,h=s.event;t.interactable&&t.interactable.checkAndPreventDefault(h)}var Ra={id:"core/interactablePreventDefault",install:function(s){var t=s.Interactable;t.prototype.preventDefault=tr,t.prototype.checkAndPreventDefault=function(h){return function(k,C,F){var Y=k.options.preventDefault;if(Y!=="never")if(Y!=="always"){if(C.events.supportsPassive&&/^touch(start|move)$/.test(F.type)){var J=_(F.target).document,xe=C.getDocOptions(J);if(!xe||!xe.events||xe.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(F.type)||S.element(F.target)&&te(F.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||F.preventDefault()}else F.preventDefault()}(this,s,h)},s.interactions.docEvents.push({type:"dragstart",listener:function(h){for(var k=0,C=s.interactions.list;k<C.length;k++){var F=C[k];if(F.element&&(F.element===h.target||ae(F.element,h.target)))return void F.interactable.checkAndPreventDefault(h)}}})},listeners:["down","move","up","cancel"].reduce(function(s,t){return s["interactions:".concat(t)]=xr,s},{})};function kl(s,t){if(t.phaselessTypes[s])return!0;for(var h in t.map)if(s.indexOf(h)===0&&s.substr(h.length)in t.phases)return!0;return!1}function Ml(s){var t={};for(var h in s){var k=s[h];S.plainObject(k)?t[h]=Ml(k):S.array(k)?t[h]=Qe(k):t[h]=k}return t}var Oa=function(){function s(t){o(this,s),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=t,this.result=aa(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}return c(s,[{key:"start",value:function(t,h){var k,C,F=t.phase,Y=this.interaction,J=function(He){var Se=He.interactable.options[He.prepared.name],da=Se.modifiers;return da&&da.length?da:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(function(Ma){var rl=Se[Ma];return rl&&rl.enabled&&{options:rl,methods:rl._methods}}).filter(function(Ma){return!!Ma})}(Y);this.prepareStates(J),this.startEdges=P({},Y.edges),this.edges=P({},this.startEdges),this.startOffset=(k=Y.rect,C=h,k?{left:C.x-k.left,top:C.y-k.top,right:k.right-C.x,bottom:k.bottom-C.y}:{left:0,top:0,right:0,bottom:0}),this.startDelta={x:0,y:0};var xe=this.fillArg({phase:F,pageCoords:h,preEnd:!1});return this.result=aa(),this.startAll(xe),this.result=this.setAll(xe)}},{key:"fillArg",value:function(t){var h=this.interaction;return t.interaction=h,t.interactable=h.interactable,t.element=h.element,t.rect||(t.rect=h.rect),t.edges||(t.edges=this.startEdges),t.startOffset=this.startOffset,t}},{key:"startAll",value:function(t){for(var h=0,k=this.states;h<k.length;h++){var C=k[h];C.methods.start&&(t.state=C,C.methods.start(t))}}},{key:"setAll",value:function(t){var h=t.phase,k=t.preEnd,C=t.skipModifiers,F=t.rect,Y=t.edges;t.coords=P({},t.pageCoords),t.rect=P({},F),t.edges=P({},Y);for(var J=C?this.states.slice(C):this.states,xe=aa(t.coords,t.rect),He=0;He<J.length;He++){var Se,da=J[He],Ma=da.options,rl=P({},t.coords),el=null;(Se=da.methods)!=null&&Se.set&&this.shouldDo(Ma,k,h)&&(t.state=da,el=da.methods.set(t),de(t.edges,t.rect,{x:t.coords.x-rl.x,y:t.coords.y-rl.y})),xe.eventProps.push(el)}P(this.edges,t.edges),xe.delta.x=t.coords.x-t.pageCoords.x,xe.delta.y=t.coords.y-t.pageCoords.y,xe.rectDelta.left=t.rect.left-F.left,xe.rectDelta.right=t.rect.right-F.right,xe.rectDelta.top=t.rect.top-F.top,xe.rectDelta.bottom=t.rect.bottom-F.bottom;var cl=this.result.coords,Dl=this.result.rect;if(cl&&Dl){var El=xe.rect.left!==Dl.left||xe.rect.right!==Dl.right||xe.rect.top!==Dl.top||xe.rect.bottom!==Dl.bottom;xe.changed=El||cl.x!==xe.coords.x||cl.y!==xe.coords.y}return xe}},{key:"applyToInteraction",value:function(t){var h=this.interaction,k=t.phase,C=h.coords.cur,F=h.coords.start,Y=this.result,J=this.startDelta,xe=Y.delta;k==="start"&&P(this.startDelta,Y.delta);for(var He=0,Se=[[F,J],[C,xe]];He<Se.length;He++){var da=Se[He],Ma=da[0],rl=da[1];Ma.page.x+=rl.x,Ma.page.y+=rl.y,Ma.client.x+=rl.x,Ma.client.y+=rl.y}var el=this.result.rectDelta,cl=t.rect||h.rect;cl.left+=el.left,cl.right+=el.right,cl.top+=el.top,cl.bottom+=el.bottom,cl.width=cl.right-cl.left,cl.height=cl.bottom-cl.top}},{key:"setAndApply",value:function(t){var h=this.interaction,k=t.phase,C=t.preEnd,F=t.skipModifiers,Y=this.setAll(this.fillArg({preEnd:C,phase:k,pageCoords:t.modifiedCoords||h.coords.cur.page}));if(this.result=Y,!Y.changed&&(!F||F<this.states.length)&&h.interacting())return!1;if(t.modifiedCoords){var J=h.coords.cur.page,xe={x:t.modifiedCoords.x-J.x,y:t.modifiedCoords.y-J.y};Y.coords.x+=xe.x,Y.coords.y+=xe.y,Y.delta.x+=xe.x,Y.delta.y+=xe.y}this.applyToInteraction(t)}},{key:"beforeEnd",value:function(t){var h=t.interaction,k=t.event,C=this.states;if(C&&C.length){for(var F=!1,Y=0;Y<C.length;Y++){var J=C[Y];t.state=J;var xe=J.options,He=J.methods,Se=He.beforeEnd&&He.beforeEnd(t);if(Se)return this.endResult=Se,!1;F=F||!F&&this.shouldDo(xe,!0,t.phase,!0)}F&&h.move({event:k,preEnd:!0})}}},{key:"stop",value:function(t){var h=t.interaction;if(this.states&&this.states.length){var k=P({states:this.states,interactable:h.interactable,element:h.element,rect:null},t);this.fillArg(k);for(var C=0,F=this.states;C<F.length;C++){var Y=F[C];k.state=Y,Y.methods.stop&&Y.methods.stop(k)}this.states=null,this.endResult=null}}},{key:"prepareStates",value:function(t){this.states=[];for(var h=0;h<t.length;h++){var k=t[h],C=k.options,F=k.methods,Y=k.name;this.states.push({options:C,methods:F,index:h,name:Y})}return this.states}},{key:"restoreInteractionCoords",value:function(t){var h=t.interaction,k=h.coords,C=h.rect,F=h.modification;if(F.result){for(var Y=F.startDelta,J=F.result,xe=J.delta,He=J.rectDelta,Se=0,da=[[k.start,Y],[k.cur,xe]];Se<da.length;Se++){var Ma=da[Se],rl=Ma[0],el=Ma[1];rl.page.x-=el.x,rl.page.y-=el.y,rl.client.x-=el.x,rl.client.y-=el.y}C.left-=He.left,C.right-=He.right,C.top-=He.top,C.bottom-=He.bottom}}},{key:"shouldDo",value:function(t,h,k,C){return!(!t||t.enabled===!1||C&&!t.endOnly||t.endOnly&&!h||k==="start"&&!t.setStart)}},{key:"copyFrom",value:function(t){this.startOffset=t.startOffset,this.startDelta=t.startDelta,this.startEdges=t.startEdges,this.edges=t.edges,this.states=t.states.map(function(h){return Ml(h)}),this.result=aa(P({},t.result.coords),P({},t.result.rect))}},{key:"destroy",value:function(){for(var t in this)this[t]=null}}]),s}();function aa(s,t){return{rect:t,coords:s,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function Rl(s,t){var h=s.defaults,k={start:s.start,set:s.set,beforeEnd:s.beforeEnd,stop:s.stop},C=function(F){var Y=F||{};for(var J in Y.enabled=Y.enabled!==!1,h)J in Y||(Y[J]=h[J]);var xe={options:Y,methods:k,name:t,enable:function(){return Y.enabled=!0,xe},disable:function(){return Y.enabled=!1,xe}};return xe};return t&&typeof t=="string"&&(C._defaults=h,C._methods=k),C}function Yr(s){var t=s.iEvent,h=s.interaction.modification.result;h&&(t.modifiers=h.eventProps)}var Jr={id:"modifiers/base",before:["actions"],install:function(s){s.defaults.perAction.modifiers=[]},listeners:{"interactions:new":function(s){var t=s.interaction;t.modification=new Oa(t)},"interactions:before-action-start":function(s){var t=s.interaction,h=s.interaction.modification;h.start(s,t.coords.start.page),t.edges=h.edges,h.applyToInteraction(s)},"interactions:before-action-move":function(s){var t=s.interaction,h=t.modification,k=h.setAndApply(s);return t.edges=h.edges,k},"interactions:before-action-end":function(s){var t=s.interaction,h=t.modification,k=h.beforeEnd(s);return t.edges=h.startEdges,k},"interactions:action-start":Yr,"interactions:action-move":Yr,"interactions:action-end":Yr,"interactions:after-action-start":function(s){return s.interaction.modification.restoreInteractionCoords(s)},"interactions:after-action-move":function(s){return s.interaction.modification.restoreInteractionCoords(s)},"interactions:stop":function(s){return s.interaction.modification.stop(s)}}},vn=Jr,en={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}},Ar=function(s){m(h,s);var t=D(h);function h(k,C,F,Y,J,xe,He){var Se;o(this,h),(Se=t.call(this,k)).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,J=J||k.element;var da=k.interactable,Ma=(da&&da.options||en).deltaSource,rl=De(da,J,F),el=Y==="start",cl=Y==="end",Dl=el?d(Se):k.prevEvent,El=el?k.coords.start:cl?{page:Dl.page,client:Dl.client,timeStamp:k.coords.cur.timeStamp}:k.coords.cur;return Se.page=P({},El.page),Se.client=P({},El.client),Se.rect=P({},k.rect),Se.timeStamp=El.timeStamp,cl||(Se.page.x-=rl.x,Se.page.y-=rl.y,Se.client.x-=rl.x,Se.client.y-=rl.y),Se.ctrlKey=C.ctrlKey,Se.altKey=C.altKey,Se.shiftKey=C.shiftKey,Se.metaKey=C.metaKey,Se.button=C.button,Se.buttons=C.buttons,Se.target=J,Se.currentTarget=J,Se.preEnd=xe,Se.type=He||F+(Y||""),Se.interactable=da,Se.t0=el?k.pointers[k.pointers.length-1].downTime:Dl.t0,Se.x0=k.coords.start.page.x-rl.x,Se.y0=k.coords.start.page.y-rl.y,Se.clientX0=k.coords.start.client.x-rl.x,Se.clientY0=k.coords.start.client.y-rl.y,Se.delta=el||cl?{x:0,y:0}:{x:Se[Ma].x-Dl[Ma].x,y:Se[Ma].y-Dl[Ma].y},Se.dt=k.coords.delta.timeStamp,Se.duration=Se.timeStamp-Se.t0,Se.velocity=P({},k.coords.velocity[Ma]),Se.speed=Ge(Se.velocity.x,Se.velocity.y),Se.swipe=cl||Y==="inertiastart"?Se.getSwipe():null,Se}return c(h,[{key:"getSwipe",value:function(){var k=this._interaction;if(k.prevEvent.speed<600||this.timeStamp-k.prevEvent.timeStamp>150)return null;var C=180*Math.atan2(k.prevEvent.velocityY,k.prevEvent.velocityX)/Math.PI;C<0&&(C+=360);var F=112.5<=C&&C<247.5,Y=202.5<=C&&C<337.5;return{up:Y,down:!Y&&22.5<=C&&C<157.5,left:F,right:!F&&(292.5<=C||C<67.5),angle:C,speed:k.prevEvent.speed,velocity:{x:k.prevEvent.velocityX,y:k.prevEvent.velocityY}}}},{key:"preventDefault",value:function(){}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}}]),h}(Pe);Object.defineProperties(Ar.prototype,{pageX:{get:function(){return this.page.x},set:function(s){this.page.x=s}},pageY:{get:function(){return this.page.y},set:function(s){this.page.y=s}},clientX:{get:function(){return this.client.x},set:function(s){this.client.x=s}},clientY:{get:function(){return this.client.y},set:function(s){this.client.y=s}},dx:{get:function(){return this.delta.x},set:function(s){this.delta.x=s}},dy:{get:function(){return this.delta.y},set:function(s){this.delta.y=s}},velocityX:{get:function(){return this.velocity.x},set:function(s){this.velocity.x=s}},velocityY:{get:function(){return this.velocity.y},set:function(s){this.velocity.y=s}}});var Re=c(function s(t,h,k,C,F){o(this,s),this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=t,this.pointer=h,this.event=k,this.downTime=C,this.downTarget=F}),lr=function(s){return s.interactable="",s.element="",s.prepared="",s.pointerIsDown="",s.pointerWasMoved="",s._proxy="",s}({}),Yl=function(s){return s.start="",s.move="",s.end="",s.stop="",s.interacting="",s}({}),an=0,Sr=function(){function s(t){var h=this,k=t.pointerType,C=t.scopeFire;o(this,s),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=Bl(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=an++,this._scopeFire=C,this.pointerType=k;var F=this;this._proxy={};var Y=function(Se){Object.defineProperty(h._proxy,Se,{get:function(){return F[Se]}})};for(var J in lr)Y(J);var xe=function(Se){Object.defineProperty(h._proxy,Se,{value:function(){return F[Se].apply(F,arguments)}})};for(var He in Yl)xe(He);this._scopeFire("interactions:new",{interaction:this})}return c(s,[{key:"pointerMoveTolerance",get:function(){return 1}},{key:"pointerDown",value:function(t,h,k){var C=this.updatePointer(t,h,k,!0),F=this.pointers[C];this._scopeFire("interactions:down",{pointer:t,event:h,eventTarget:k,pointerIndex:C,pointerInfo:F,type:"down",interaction:this})}},{key:"start",value:function(t,h,k){return!(this.interacting()||!this.pointerIsDown||this.pointers.length<(t.name==="gesture"?2:1)||!h.options[t.name].enabled)&&(Ha(this.prepared,t),this.interactable=h,this.element=k,this.rect=h.getRect(k),this.edges=this.prepared.edges?P({},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(t,h,k){this.simulation||this.modification&&this.modification.endResult||this.updatePointer(t,h,k,!1);var C,F,Y=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&&(C=this.coords.cur.client.x-this.coords.start.client.x,F=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=Ge(C,F)>this.pointerMoveTolerance);var J,xe,He,Se=this.getPointerIndex(t),da={pointer:t,pointerIndex:Se,pointerInfo:this.pointers[Se],event:h,type:"move",eventTarget:k,dx:C,dy:F,duplicate:Y,interaction:this};Y||(J=this.coords.velocity,xe=this.coords.delta,He=Math.max(xe.timeStamp/1e3,.001),J.page.x=xe.page.x/He,J.page.y=xe.page.y/He,J.client.x=xe.client.x/He,J.client.y=xe.client.y/He,J.timeStamp=He),this._scopeFire("interactions:move",da),Y||this.simulation||(this.interacting()&&(da.type=null,this.move(da)),this.pointerWasMoved&&ee(this.coords.prev,this.coords.cur))}},{key:"move",value:function(t){t&&t.event||ce(this.coords.delta),(t=P({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},t||{})).phase="move",this._doPhase(t)}},{key:"pointerUp",value:function(t,h,k,C){var F=this.getPointerIndex(t);F===-1&&(F=this.updatePointer(t,h,k,!1));var Y=/cancel$/i.test(h.type)?"cancel":"up";this._scopeFire("interactions:".concat(Y),{pointer:t,pointerIndex:F,pointerInfo:this.pointers[F],event:h,eventTarget:k,type:Y,curEventTarget:C,interaction:this}),this.simulation||this.end(h),this.removePointer(t,h)}},{key:"documentBlur",value:function(t){this.end(t),this._scopeFire("interactions:blur",{event:t,type:"blur",interaction:this})}},{key:"end",value:function(t){var h;this._ending=!0,t=t||this._latestPointer.event,this.interacting()&&(h=this._doPhase({event:t,interaction:this,phase:"end"})),this._ending=!1,h===!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(t){var h=Ve(t);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:Oe(this.pointers,function(k){return k.id===h})}},{key:"getPointerInfo",value:function(t){return this.pointers[this.getPointerIndex(t)]}},{key:"updatePointer",value:function(t,h,k,C){var F,Y,J,xe=Ve(t),He=this.getPointerIndex(t),Se=this.pointers[He];return C=C!==!1&&(C||/(down|start)$/i.test(h.type)),Se?Se.pointer=t:(Se=new Re(xe,t,h,null,null),He=this.pointers.length,this.pointers.push(Se)),ya(this.coords.cur,this.pointers.map(function(da){return da.pointer}),this._now()),F=this.coords.delta,Y=this.coords.prev,J=this.coords.cur,F.page.x=J.page.x-Y.page.x,F.page.y=J.page.y-Y.page.y,F.client.x=J.client.x-Y.client.x,F.client.y=J.client.y-Y.client.y,F.timeStamp=J.timeStamp-Y.timeStamp,C&&(this.pointerIsDown=!0,Se.downTime=this.coords.cur.timeStamp,Se.downTarget=k,V(this.downPointer,t),this.interacting()||(ee(this.coords.start,this.coords.cur),ee(this.coords.prev,this.coords.cur),this.downEvent=h,this.pointerWasMoved=!1)),this._updateLatestPointer(t,h,k),this._scopeFire("interactions:update-pointer",{pointer:t,event:h,eventTarget:k,down:C,pointerInfo:Se,pointerIndex:He,interaction:this}),He}},{key:"removePointer",value:function(t,h){var k=this.getPointerIndex(t);if(k!==-1){var C=this.pointers[k];this._scopeFire("interactions:remove-pointer",{pointer:t,event:h,eventTarget:null,pointerIndex:k,pointerInfo:C,interaction:this}),this.pointers.splice(k,1),this.pointerIsDown=!1}}},{key:"_updateLatestPointer",value:function(t,h,k){this._latestPointer.pointer=t,this._latestPointer.event=h,this._latestPointer.eventTarget=k}},{key:"destroy",value:function(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}},{key:"_createPreparedEvent",value:function(t,h,k,C){return new Ar(this,t,this.prepared.name,h,this.element,k,C)}},{key:"_fireEvent",value:function(t){var h;(h=this.interactable)==null||h.fire(t),(!this.prevEvent||t.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=t)}},{key:"_doPhase",value:function(t){var h=t.event,k=t.phase,C=t.preEnd,F=t.type,Y=this.rect;if(Y&&k==="move"&&(de(this.edges,Y,this.coords.delta[this.interactable.options.deltaSource]),Y.width=Y.right-Y.left,Y.height=Y.bottom-Y.top),this._scopeFire("interactions:before-action-".concat(k),t)===!1)return!1;var J=t.iEvent=this._createPreparedEvent(h,k,C,F);return this._scopeFire("interactions:action-".concat(k),t),k==="start"&&(this.prevEvent=J),this._fireEvent(J),this._scopeFire("interactions:after-action-".concat(k),t),!0}},{key:"_now",value:function(){return Date.now()}}]),s}();function Jl(s){Er(s.interaction)}function Er(s){if(!function(h){return!(!h.offset.pending.x&&!h.offset.pending.y)}(s))return!1;var t=s.offset.pending;return $l(s.coords.cur,t),$l(s.coords.delta,t),de(s.edges,s.rect,t),t.x=0,t.y=0,!0}function Xl(s){var t=s.x,h=s.y;this.offset.pending.x+=t,this.offset.pending.y+=h,this.offset.total.x+=t,this.offset.total.y+=h}function $l(s,t){var h=s.page,k=s.client,C=t.x,F=t.y;h.x+=C,h.y+=F,k.x+=C,k.y+=F}Yl.offsetBy="";var nr={id:"offset",before:["modifiers","pointer-events","actions","inertia"],install:function(s){s.Interaction.prototype.offsetBy=Xl},listeners:{"interactions:new":function(s){s.interaction.offset={total:{x:0,y:0},pending:{x:0,y:0}}},"interactions:update-pointer":function(s){return function(t){t.pointerIsDown&&($l(t.coords.cur,t.offset.total),t.offset.pending.x=0,t.offset.pending.y=0)}(s.interaction)},"interactions:before-action-start":Jl,"interactions:before-action-move":Jl,"interactions:before-action-end":function(s){var t=s.interaction;if(Er(t))return t.move({offset:!0}),t.end(),!1},"interactions:stop":function(s){var t=s.interaction;t.offset.total.x=0,t.offset.total.y=0,t.offset.pending.x=0,t.offset.pending.y=0}}},Ql=nr,Ul=function(){function s(t){o(this,s),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=t}return c(s,[{key:"start",value:function(t){var h=this.interaction,k=Nl(h);if(!k||!k.enabled)return!1;var C=h.coords.velocity.client,F=Ge(C.x,C.y),Y=this.modification||(this.modification=new Oa(h));if(Y.copyFrom(h.modification),this.t0=h._now(),this.allowResume=k.allowResume,this.v0=F,this.currentOffset={x:0,y:0},this.startCoords=h.coords.cur.page,this.modifierArg=Y.fillArg({pageCoords:this.startCoords,preEnd:!0,phase:"inertiastart"}),this.t0-h.coords.cur.timeStamp<50&&F>k.minSpeed&&F>k.endSpeed)this.startInertia();else{if(Y.result=Y.setAll(this.modifierArg),!Y.result.changed)return!1;this.startSmoothEnd()}return h.modification.result.rect=null,h.offsetBy(this.targetOffset),h._doPhase({interaction:h,event:t,phase:"inertiastart"}),h.offsetBy({x:-this.targetOffset.x,y:-this.targetOffset.y}),h.modification.result.rect=null,this.active=!0,h.simulation=this,!0}},{key:"startInertia",value:function(){var t=this,h=this.interaction.coords.velocity.client,k=Nl(this.interaction),C=k.resistance,F=-Math.log(k.endSpeed/this.v0)/C;this.targetOffset={x:(h.x-F)/C,y:(h.y-F)/C},this.te=F,this.lambda_v0=C/this.v0,this.one_ve_v0=1-k.endSpeed/this.v0;var Y=this.modification,J=this.modifierArg;J.pageCoords={x:this.startCoords.x+this.targetOffset.x,y:this.startCoords.y+this.targetOffset.y},Y.result=Y.setAll(J),Y.result.changed&&(this.isModified=!0,this.modifiedOffset={x:this.targetOffset.x+Y.result.delta.x,y:this.targetOffset.y+Y.result.delta.y}),this.onNextFrame(function(){return t.inertiaTick()})}},{key:"startSmoothEnd",value:function(){var t=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 t.smoothEndTick()})}},{key:"onNextFrame",value:function(t){var h=this;this.timeout=Zl.request(function(){h.active&&t()})}},{key:"inertiaTick",value:function(){var t,h,k,C,F,Y,J,xe=this,He=this.interaction,Se=Nl(He).resistance,da=(He._now()-this.t0)/1e3;if(da<this.te){var Ma,rl=1-(Math.exp(-Se*da)-this.lambda_v0)/this.one_ve_v0;this.isModified?(t=0,h=0,k=this.targetOffset.x,C=this.targetOffset.y,F=this.modifiedOffset.x,Y=this.modifiedOffset.y,Ma={x:er(J=rl,t,k,F),y:er(J,h,C,Y)}):Ma={x:this.targetOffset.x*rl,y:this.targetOffset.y*rl};var el={x:Ma.x-this.currentOffset.x,y:Ma.y-this.currentOffset.y};this.currentOffset.x+=el.x,this.currentOffset.y+=el.y,He.offsetBy(el),He.move(),this.onNextFrame(function(){return xe.inertiaTick()})}else He.offsetBy({x:this.modifiedOffset.x-this.currentOffset.x,y:this.modifiedOffset.y-this.currentOffset.y}),this.end()}},{key:"smoothEndTick",value:function(){var t=this,h=this.interaction,k=h._now()-this.t0,C=Nl(h).smoothEndDuration;if(k<C){var F={x:Ur(k,0,this.targetOffset.x,C),y:Ur(k,0,this.targetOffset.y,C)},Y={x:F.x-this.currentOffset.x,y:F.y-this.currentOffset.y};this.currentOffset.x+=Y.x,this.currentOffset.y+=Y.y,h.offsetBy(Y),h.move({skipModifiers:this.modifierCount}),this.onNextFrame(function(){return t.smoothEndTick()})}else h.offsetBy({x:this.targetOffset.x-this.currentOffset.x,y:this.targetOffset.y-this.currentOffset.y}),this.end()}},{key:"resume",value:function(t){var h=t.pointer,k=t.event,C=t.eventTarget,F=this.interaction;F.offsetBy({x:-this.currentOffset.x,y:-this.currentOffset.y}),F.updatePointer(h,k,C,!0),F._doPhase({interaction:F,event:k,phase:"resume"}),ee(F.coords.prev,F.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,Zl.cancel(this.timeout)}}]),s}();function Nl(s){var t=s.interactable,h=s.prepared;return t&&t.options&&h.name&&t.options[h.name].inertia}var Vr={id:"inertia",before:["modifiers","actions"],install:function(s){var t=s.defaults;s.usePlugin(Ql),s.usePlugin(vn),s.actions.phases.inertiastart=!0,s.actions.phases.resume=!0,t.perAction.inertia={enabled:!1,resistance:10,minSpeed:100,endSpeed:10,allowResume:!0,smoothEndDuration:300}},listeners:{"interactions:new":function(s){var t=s.interaction;t.inertia=new Ul(t)},"interactions:before-action-end":function(s){var t=s.interaction,h=s.event;return(!t._interacting||t.simulation||!t.inertia.start(h))&&null},"interactions:down":function(s){var t=s.interaction,h=s.eventTarget,k=t.inertia;if(k.active)for(var C=h;S.element(C);){if(C===t.element){k.resume(s);break}C=ze(C)}},"interactions:stop":function(s){var t=s.interaction.inertia;t.active&&t.stop()},"interactions:before-action-resume":function(s){var t=s.interaction.modification;t.stop(s),t.start(s,s.interaction.coords.cur.page),t.applyToInteraction(s)},"interactions:before-action-inertiastart":function(s){return s.interaction.modification.setAndApply(s)},"interactions:action-resume":Yr,"interactions:action-inertiastart":Yr,"interactions:after-action-inertiastart":function(s){return s.interaction.modification.restoreInteractionCoords(s)},"interactions:after-action-resume":function(s){return s.interaction.modification.restoreInteractionCoords(s)}}};function er(s,t,h,k){var C=1-s;return C*C*t+2*C*s*h+s*s*k}function Ur(s,t,h,k){return-h*(s/=k)*(s-2)+t}var Br=Vr;function Tr(s,t){for(var h=0;h<t.length;h++){var k=t[h];if(s.immediatePropagationStopped)break;k(s)}}var gn=function(){function s(t){o(this,s),this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=P({},t||{})}return c(s,[{key:"fire",value:function(t){var h,k=this.global;(h=this.types[t.type])&&Tr(t,h),!t.propagationStopped&&k&&(h=k[t.type])&&Tr(t,h)}},{key:"on",value:function(t,h){var k=Xe(t,h);for(t in k)this.types[t]=ma(this.types[t]||[],k[t])}},{key:"off",value:function(t,h){var k=Xe(t,h);for(t in k){var C=this.types[t];if(C&&C.length)for(var F=0,Y=k[t];F<Y.length;F++){var J=Y[F],xe=C.indexOf(J);xe!==-1&&C.splice(xe,1)}}}},{key:"getRect",value:function(t){return null}}]),s}(),Sn=function(){function s(t){o(this,s),this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=t,V(this,t)}return c(s,[{key:"preventOriginalDefault",value:function(){this.originalEvent.preventDefault()}},{key:"stopPropagation",value:function(){this.originalEvent.stopPropagation()}},{key:"stopImmediatePropagation",value:function(){this.originalEvent.stopImmediatePropagation()}}]),s}();function Cn(s){return S.object(s)?{capture:!!s.capture,passive:!!s.passive}:{capture:!!s,passive:!1}}function mn(s,t){return s===t||(typeof s=="boolean"?!!t.capture===s&&!t.passive:!!s.capture==!!t.capture&&!!s.passive==!!t.passive)}var On={id:"events",install:function(s){var t,h=[],k={},C=[],F={add:Y,remove:J,addDelegate:function(Se,da,Ma,rl,el){var cl=Cn(el);if(!k[Ma]){k[Ma]=[];for(var Dl=0;Dl<C.length;Dl++){var El=C[Dl];Y(El,Ma,xe),Y(El,Ma,He,!0)}}var Vl=k[Ma],ir=$e(Vl,function(fr){return fr.selector===Se&&fr.context===da});ir||(ir={selector:Se,context:da,listeners:[]},Vl.push(ir)),ir.listeners.push({func:rl,options:cl})},removeDelegate:function(Se,da,Ma,rl,el){var cl,Dl=Cn(el),El=k[Ma],Vl=!1;if(El)for(cl=El.length-1;cl>=0;cl--){var ir=El[cl];if(ir.selector===Se&&ir.context===da){for(var fr=ir.listeners,ql=fr.length-1;ql>=0;ql--){var sr=fr[ql];if(sr.func===rl&&mn(sr.options,Dl)){fr.splice(ql,1),fr.length||(El.splice(cl,1),J(da,Ma,xe),J(da,Ma,He,!0)),Vl=!0;break}}if(Vl)break}}},delegateListener:xe,delegateUseCapture:He,delegatedEvents:k,documents:C,targets:h,supportsOptions:!1,supportsPassive:!1};function Y(Se,da,Ma,rl){if(Se.addEventListener){var el=Cn(rl),cl=$e(h,function(Dl){return Dl.eventTarget===Se});cl||(cl={eventTarget:Se,events:{}},h.push(cl)),cl.events[da]||(cl.events[da]=[]),$e(cl.events[da],function(Dl){return Dl.func===Ma&&mn(Dl.options,el)})||(Se.addEventListener(da,Ma,F.supportsOptions?el:el.capture),cl.events[da].push({func:Ma,options:el}))}}function J(Se,da,Ma,rl){if(Se.addEventListener&&Se.removeEventListener){var el=Oe(h,function(dn){return dn.eventTarget===Se}),cl=h[el];if(cl&&cl.events)if(da!=="all"){var Dl=!1,El=cl.events[da];if(El){if(Ma==="all"){for(var Vl=El.length-1;Vl>=0;Vl--){var ir=El[Vl];J(Se,da,ir.func,ir.options)}return}for(var fr=Cn(rl),ql=0;ql<El.length;ql++){var sr=El[ql];if(sr.func===Ma&&mn(sr.options,fr)){Se.removeEventListener(da,Ma,F.supportsOptions?fr:fr.capture),El.splice(ql,1),El.length===0&&(delete cl.events[da],Dl=!0);break}}}Dl&&!Object.keys(cl.events).length&&h.splice(el,1)}else for(da in cl.events)cl.events.hasOwnProperty(da)&&J(Se,da,"all")}}function xe(Se,da){for(var Ma=Cn(da),rl=new Sn(Se),el=k[Se.type],cl=sa(Se)[0],Dl=cl;S.element(Dl);){for(var El=0;El<el.length;El++){var Vl=el[El],ir=Vl.selector,fr=Vl.context;if(te(Dl,ir)&&ae(fr,cl)&&ae(fr,Dl)){var ql=Vl.listeners;rl.currentTarget=Dl;for(var sr=0;sr<ql.length;sr++){var dn=ql[sr];mn(dn.options,Ma)&&dn.func(rl)}}}Dl=ze(Dl)}}function He(Se){return xe(Se,!0)}return(t=s.document)==null||t.createElement("div").addEventListener("test",null,{get capture(){return F.supportsOptions=!0},get passive(){return F.supportsPassive=!0}}),s.events=F,F}},rn={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search:function(s){for(var t=0,h=rn.methodOrder;t<h.length;t++){var k=h[t],C=rn[k](s);if(C)return C}return null},simulationResume:function(s){var t=s.pointerType,h=s.eventType,k=s.eventTarget,C=s.scope;if(!/down|start/i.test(h))return null;for(var F=0,Y=C.interactions.list;F<Y.length;F++){var J=Y[F],xe=k;if(J.simulation&&J.simulation.allowResume&&J.pointerType===t)for(;xe;){if(xe===J.element)return J;xe=ze(xe)}}return null},mouseOrPen:function(s){var t,h=s.pointerId,k=s.pointerType,C=s.eventType,F=s.scope;if(k!=="mouse"&&k!=="pen")return null;for(var Y=0,J=F.interactions.list;Y<J.length;Y++){var xe=J[Y];if(xe.pointerType===k){if(xe.simulation&&!Dn(xe,h))continue;if(xe.interacting())return xe;t||(t=xe)}}if(t)return t;for(var He=0,Se=F.interactions.list;He<Se.length;He++){var da=Se[He];if(!(da.pointerType!==k||/down/i.test(C)&&da.simulation))return da}return null},hasPointer:function(s){for(var t=s.pointerId,h=0,k=s.scope.interactions.list;h<k.length;h++){var C=k[h];if(Dn(C,t))return C}return null},idle:function(s){for(var t=s.pointerType,h=0,k=s.scope.interactions.list;h<k.length;h++){var C=k[h];if(C.pointers.length===1){var F=C.interactable;if(F&&(!F.options.gesture||!F.options.gesture.enabled))continue}else if(C.pointers.length>=2)continue;if(!C.interacting()&&t===C.pointerType)return C}return null}};function Dn(s,t){return s.pointers.some(function(h){return h.id===t})}var Vn=rn,nn=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function Fn(s,t){return function(h){var k=t.interactions.list,C=ja(h),F=sa(h),Y=F[0],J=F[1],xe=[];if(/^touch/.test(h.type)){t.prevTouchTime=t.now();for(var He=0,Se=h.changedTouches;He<Se.length;He++){var da=Se[He],Ma={pointer:da,pointerId:Ve(da),pointerType:C,eventType:h.type,eventTarget:Y,curEventTarget:J,scope:t},rl=zr(Ma);xe.push([Ma.pointer,Ma.eventTarget,Ma.curEventTarget,rl])}}else{var el=!1;if(!Z.supportsPointerEvent&&/mouse/.test(h.type)){for(var cl=0;cl<k.length&&!el;cl++)el=k[cl].pointerType!=="mouse"&&k[cl].pointerIsDown;el=el||t.now()-t.prevTouchTime<500||h.timeStamp===0}if(!el){var Dl={pointer:h,pointerId:Ve(h),pointerType:C,eventType:h.type,curEventTarget:J,eventTarget:Y,scope:t},El=zr(Dl);xe.push([Dl.pointer,Dl.eventTarget,Dl.curEventTarget,El])}}for(var Vl=0;Vl<xe.length;Vl++){var ir=xe[Vl],fr=ir[0],ql=ir[1],sr=ir[2];ir[3][s](fr,h,ql,sr)}}}function zr(s){var t=s.pointerType,h=s.scope,k={interaction:Vn.search(s),searchDetails:s};return h.fire("interactions:find",k),k.interaction||h.interactions.new({pointerType:t})}function An(s,t){var h=s.doc,k=s.scope,C=s.options,F=k.interactions.docEvents,Y=k.events,J=Y[t];for(var xe in k.browser.isIOS&&!C.events&&(C.events={passive:!1}),Y.delegatedEvents)J(h,xe,Y.delegateListener),J(h,xe,Y.delegateUseCapture,!0);for(var He=C&&C.events,Se=0;Se<F.length;Se++){var da=F[Se];J(h,da.type,da.listener,He)}}var Tn={id:"core/interactions",install:function(s){for(var t={},h=0;h<nn.length;h++){var k=nn[h];t[k]=Fn(k,s)}var C,F=Z.pEventTypes;function Y(){for(var J=0,xe=s.interactions.list;J<xe.length;J++){var He=xe[J];if(He.pointerIsDown&&He.pointerType==="touch"&&!He._interacting)for(var Se=function(){var rl=Ma[da];s.documents.some(function(el){return ae(el.doc,rl.downTarget)})||He.removePointer(rl.pointer,rl.event)},da=0,Ma=He.pointers;da<Ma.length;da++)Se()}}(C=U.PointerEvent?[{type:F.down,listener:Y},{type:F.down,listener:t.pointerDown},{type:F.move,listener:t.pointerMove},{type:F.up,listener:t.pointerUp},{type:F.cancel,listener:t.pointerUp}]:[{type:"mousedown",listener:t.pointerDown},{type:"mousemove",listener:t.pointerMove},{type:"mouseup",listener:t.pointerUp},{type:"touchstart",listener:Y},{type:"touchstart",listener:t.pointerDown},{type:"touchmove",listener:t.pointerMove},{type:"touchend",listener:t.pointerUp},{type:"touchcancel",listener:t.pointerUp}]).push({type:"blur",listener:function(J){for(var xe=0,He=s.interactions.list;xe<He.length;xe++)He[xe].documentBlur(J)}}),s.prevTouchTime=0,s.Interaction=function(J){m(He,J);var xe=D(He);function He(){return o(this,He),xe.apply(this,arguments)}return c(He,[{key:"pointerMoveTolerance",get:function(){return s.interactions.pointerMoveTolerance},set:function(Se){s.interactions.pointerMoveTolerance=Se}},{key:"_now",value:function(){return s.now()}}]),He}(Sr),s.interactions={list:[],new:function(J){J.scopeFire=function(He,Se){return s.fire(He,Se)};var xe=new s.Interaction(J);return s.interactions.list.push(xe),xe},listeners:t,docEvents:C,pointerMoveTolerance:1},s.usePlugin(Ra)},listeners:{"scope:add-document":function(s){return An(s,"add")},"scope:remove-document":function(s){return An(s,"remove")},"interactable:unset":function(s,t){for(var h=s.interactable,k=t.interactions.list.length-1;k>=0;k--){var C=t.interactions.list[k];C.interactable===h&&(C.stop(),t.fire("interactions:destroy",{interaction:C}),C.destroy(),t.interactions.list.length>2&&t.interactions.list.splice(k,1))}}},onDocSignal:An,doOnInteractions:Fn,methodNames:nn},Po=Tn,Ln=function(s){return s[s.On=0]="On",s[s.Off=1]="Off",s}(Ln||{}),jo=function(){function s(t,h,k,C){o(this,s),this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new gn,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=h.actions,this.target=t,this._context=h.context||k,this._win=_(ra(t)?this._context:t),this._doc=this._win.document,this._scopeEvents=C,this.set(h)}return c(s,[{key:"_defaults",get:function(){return{base:{},perAction:{},actions:{}}}},{key:"setOnEvents",value:function(t,h){return S.func(h.onstart)&&this.on("".concat(t,"start"),h.onstart),S.func(h.onmove)&&this.on("".concat(t,"move"),h.onmove),S.func(h.onend)&&this.on("".concat(t,"end"),h.onend),S.func(h.oninertiastart)&&this.on("".concat(t,"inertiastart"),h.oninertiastart),this}},{key:"updatePerActionListeners",value:function(t,h,k){var C,F=this,Y=(C=this._actions.map[t])==null?void 0:C.filterEventType,J=function(xe){return(Y==null||Y(xe))&&kl(xe,F._actions)};(S.array(h)||S.object(h))&&this._onOff(Ln.Off,t,h,void 0,J),(S.array(k)||S.object(k))&&this._onOff(Ln.On,t,k,void 0,J)}},{key:"setPerAction",value:function(t,h){var k=this._defaults;for(var C in h){var F=C,Y=this.options[t],J=h[F];F==="listeners"&&this.updatePerActionListeners(t,Y.listeners,J),S.array(J)?Y[F]=Qe(J):S.plainObject(J)?(Y[F]=P(Y[F]||{},Ml(J)),S.object(k.perAction[F])&&"enabled"in k.perAction[F]&&(Y[F].enabled=J.enabled!==!1)):S.bool(J)&&S.object(k.perAction[F])?Y[F].enabled=J:Y[F]=J}}},{key:"getRect",value:function(t){return t=t||(S.element(this.target)?this.target:null),S.string(this.target)&&(t=t||this._context.querySelector(this.target)),_e(t)}},{key:"rectChecker",value:function(t){var h=this;return S.func(t)?(this.getRect=function(k){var C=P({},t.apply(h,k));return"width"in C||(C.width=C.right-C.left,C.height=C.bottom-C.top),C},this):t===null?(delete this.getRect,this):this.getRect}},{key:"_backCompatOption",value:function(t,h){if(ra(h)||S.object(h)){for(var k in this.options[t]=h,this._actions.map)this.options[k][t]=h;return this}return this.options[t]}},{key:"origin",value:function(t){return this._backCompatOption("origin",t)}},{key:"deltaSource",value:function(t){return t==="page"||t==="client"?(this.options.deltaSource=t,this):this.options.deltaSource}},{key:"getAllElements",value:function(){var t=this.target;return S.string(t)?Array.from(this._context.querySelectorAll(t)):S.func(t)&&t.getAllElements?t.getAllElements():S.element(t)?[t]:[]}},{key:"context",value:function(){return this._context}},{key:"inContext",value:function(t){return this._context===t.ownerDocument||ae(this._context,t)}},{key:"testIgnoreAllow",value:function(t,h,k){return!this.testIgnore(t.ignoreFrom,h,k)&&this.testAllow(t.allowFrom,h,k)}},{key:"testAllow",value:function(t,h,k){return!t||!!S.element(k)&&(S.string(t)?G(k,t,h):!!S.element(t)&&ae(t,k))}},{key:"testIgnore",value:function(t,h,k){return!(!t||!S.element(k))&&(S.string(t)?G(k,t,h):!!S.element(t)&&ae(t,k))}},{key:"fire",value:function(t){return this.events.fire(t),this}},{key:"_onOff",value:function(t,h,k,C,F){S.object(h)&&!S.array(h)&&(C=k,k=null);var Y=Xe(h,k,F);for(var J in Y){J==="wheel"&&(J=Z.wheelEvent);for(var xe=0,He=Y[J];xe<He.length;xe++){var Se=He[xe];kl(J,this._actions)?this.events[t===Ln.On?"on":"off"](J,Se):S.string(this.target)?this._scopeEvents[t===Ln.On?"addDelegate":"removeDelegate"](this.target,this._context,J,Se,C):this._scopeEvents[t===Ln.On?"add":"remove"](this.target,J,Se,C)}}return this}},{key:"on",value:function(t,h,k){return this._onOff(Ln.On,t,h,k)}},{key:"off",value:function(t,h,k){return this._onOff(Ln.Off,t,h,k)}},{key:"set",value:function(t){var h=this._defaults;for(var k in S.object(t)||(t={}),this.options=Ml(h.base),this._actions.methodDict){var C=k,F=this._actions.methodDict[C];this.options[C]={},this.setPerAction(C,P(P({},h.perAction),h.actions[C])),this[F](t[C])}for(var Y in t)Y!=="getRect"?S.func(this[Y])&&this[Y](t[Y]):this.rectChecker(t.getRect);return this}},{key:"unset",value:function(){if(S.string(this.target))for(var t in this._scopeEvents.delegatedEvents)for(var h=this._scopeEvents.delegatedEvents[t],k=h.length-1;k>=0;k--){var C=h[k],F=C.selector,Y=C.context,J=C.listeners;F===this.target&&Y===this._context&&h.splice(k,1);for(var xe=J.length-1;xe>=0;xe--)this._scopeEvents.removeDelegate(this.target,this._context,t,J[xe][0],J[xe][1])}else this._scopeEvents.remove(this.target,"all")}}]),s}(),Ho=function(){function s(t){var h=this;o(this,s),this.list=[],this.selectorMap={},this.scope=void 0,this.scope=t,t.addListeners({"interactable:unset":function(k){var C=k.interactable,F=C.target,Y=S.string(F)?h.selectorMap[F]:F[h.scope.id],J=Oe(Y,function(xe){return xe===C});Y.splice(J,1)}})}return c(s,[{key:"new",value:function(t,h){h=P(h||{},{actions:this.scope.actions});var k=new this.scope.Interactable(t,h,this.scope.document,this.scope.events);return this.scope.addDocument(k._doc),this.list.push(k),S.string(t)?(this.selectorMap[t]||(this.selectorMap[t]=[]),this.selectorMap[t].push(k)):(k.target[this.scope.id]||Object.defineProperty(t,this.scope.id,{value:[],configurable:!0}),t[this.scope.id].push(k)),this.scope.fire("interactable:new",{target:t,options:h,interactable:k,win:this.scope._win}),k}},{key:"getExisting",value:function(t,h){var k=h&&h.context||this.scope.document,C=S.string(t),F=C?this.selectorMap[t]:t[this.scope.id];if(F)return $e(F,function(Y){return Y._context===k&&(C||Y.inContext(t))})}},{key:"forEachMatch",value:function(t,h){for(var k=0,C=this.list;k<C.length;k++){var F=C[k],Y=void 0;if((S.string(F.target)?S.element(t)&&te(t,F.target):t===F.target)&&F.inContext(t)&&(Y=h(F)),Y!==void 0)return Y}}}]),s}(),Uo=function(){function s(){var t=this;o(this,s),this.id="__interact_scope_".concat(Math.floor(100*Math.random())),this.isInitialized=!1,this.listenerMaps=[],this.browser=Z,this.defaults=Ml(en),this.Eventable=gn,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=function(k){var C=function F(Y,J){var xe=k.interactables.getExisting(Y,J);return xe||((xe=k.interactables.new(Y,J)).events.global=F.globalEvents),xe};return C.getPointerAverage=Ce,C.getTouchBBox=Fa,C.getTouchDistance=Ta,C.getTouchAngle=fa,C.getElementRect=_e,C.getElementClientRect=we,C.matchesSelector=te,C.closest=ve,C.globalEvents={},C.version="1.10.27",C.scope=k,C.use=function(F,Y){return this.scope.usePlugin(F,Y),this},C.isSet=function(F,Y){return!!this.scope.interactables.get(F,Y&&Y.context)},C.on=Bl(function(F,Y,J){if(S.string(F)&&F.search(" ")!==-1&&(F=F.trim().split(/ +/)),S.array(F)){for(var xe=0,He=F;xe<He.length;xe++){var Se=He[xe];this.on(Se,Y,J)}return this}if(S.object(F)){for(var da in F)this.on(da,F[da],Y);return this}return kl(F,this.scope.actions)?this.globalEvents[F]?this.globalEvents[F].push(Y):this.globalEvents[F]=[Y]:this.scope.events.add(this.scope.document,F,Y,{options:J}),this},"The interact.on() method is being deprecated"),C.off=Bl(function(F,Y,J){if(S.string(F)&&F.search(" ")!==-1&&(F=F.trim().split(/ +/)),S.array(F)){for(var xe=0,He=F;xe<He.length;xe++){var Se=He[xe];this.off(Se,Y,J)}return this}if(S.object(F)){for(var da in F)this.off(da,F[da],Y);return this}var Ma;return kl(F,this.scope.actions)?F in this.globalEvents&&(Ma=this.globalEvents[F].indexOf(Y))!==-1&&this.globalEvents[F].splice(Ma,1):this.scope.events.remove(this.scope.document,F,Y,J),this},"The interact.off() method is being deprecated"),C.debug=function(){return this.scope},C.supportsTouch=function(){return Z.supportsTouch},C.supportsPointerEvent=function(){return Z.supportsPointerEvent},C.stop=function(){for(var F=0,Y=this.scope.interactions.list;F<Y.length;F++)Y[F].stop();return this},C.pointerMoveTolerance=function(F){return S.number(F)?(this.scope.interactions.pointerMoveTolerance=F,this):this.scope.interactions.pointerMoveTolerance},C.addDocument=function(F,Y){this.scope.addDocument(F,Y)},C.removeDocument=function(F){this.scope.removeDocument(F)},C}(this),this.InteractEvent=Ar,this.Interactable=void 0,this.interactables=new Ho(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=function(k){return t.removeDocument(k.target)};var h=this;this.Interactable=function(k){m(F,k);var C=D(F);function F(){return o(this,F),C.apply(this,arguments)}return c(F,[{key:"_defaults",get:function(){return h.defaults}},{key:"set",value:function(Y){return w(g(F.prototype),"set",this).call(this,Y),h.fire("interactable:set",{options:Y,interactable:this}),this}},{key:"unset",value:function(){w(g(F.prototype),"unset",this).call(this);var Y=h.interactables.list.indexOf(this);Y<0||(h.interactables.list.splice(Y,1),h.fire("interactable:unset",{interactable:this}))}}]),F}(jo)}return c(s,[{key:"addListeners",value:function(t,h){this.listenerMaps.push({id:h,map:t})}},{key:"fire",value:function(t,h){for(var k=0,C=this.listenerMaps;k<C.length;k++){var F=C[k].map[t];if(F&&F(h,this,t)===!1)return!1}}},{key:"init",value:function(t){return this.isInitialized?this:function(h,k){return h.isInitialized=!0,S.window(k)&&E(k),U.init(k),Z.init(k),Zl.init(k),h.window=k,h.document=k.document,h.usePlugin(Po),h.usePlugin(On),h}(this,t)}},{key:"pluginIsInstalled",value:function(t){var h=t.id;return h?!!this._plugins.map[h]:this._plugins.list.indexOf(t)!==-1}},{key:"usePlugin",value:function(t,h){if(!this.isInitialized)return this;if(this.pluginIsInstalled(t))return this;if(t.id&&(this._plugins.map[t.id]=t),this._plugins.list.push(t),t.install&&t.install(this,h),t.listeners&&t.before){for(var k=0,C=this.listenerMaps.length,F=t.before.reduce(function(J,xe){return J[xe]=!0,J[lo(xe)]=!0,J},{});k<C;k++){var Y=this.listenerMaps[k].id;if(Y&&(F[Y]||F[lo(Y)]))break}this.listenerMaps.splice(k,0,{id:t.id,map:t.listeners})}else t.listeners&&this.listenerMaps.push({id:t.id,map:t.listeners});return this}},{key:"addDocument",value:function(t,h){if(this.getDocIndex(t)!==-1)return!1;var k=_(t);h=h?P({},h):{},this.documents.push({doc:t,options:h}),this.events.documents.push(t),t!==this.document&&this.events.add(k,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:t,window:k,scope:this,options:h})}},{key:"removeDocument",value:function(t){var h=this.getDocIndex(t),k=_(t),C=this.documents[h].options;this.events.remove(k,"unload",this.onWindowUnload),this.documents.splice(h,1),this.events.documents.splice(h,1),this.fire("scope:remove-document",{doc:t,window:k,scope:this,options:C})}},{key:"getDocIndex",value:function(t){for(var h=0;h<this.documents.length;h++)if(this.documents[h].doc===t)return h;return-1}},{key:"getDocOptions",value:function(t){var h=this.getDocIndex(t);return h===-1?null:this.documents[h].options}},{key:"now",value:function(){return(this.window.Date||Date).now()}}]),s}();function lo(s){return s&&s.replace(/\/.*$/,"")}var ro=new Uo,un=ro.interactStatic,qo=typeof globalThis<"u"?globalThis:window;ro.init(qo);var no=Object.freeze({__proto__:null,edgeTarget:function(){},elements:function(){},grid:function(s){var t=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(function(k){var C=k[0],F=k[1];return C in s||F in s}),h=function(k,C){for(var F=s.range,Y=s.limits,J=Y===void 0?{left:-1/0,right:1/0,top:-1/0,bottom:1/0}:Y,xe=s.offset,He=xe===void 0?{x:0,y:0}:xe,Se={range:F,grid:s,x:null,y:null},da=0;da<t.length;da++){var Ma=t[da],rl=Ma[0],el=Ma[1],cl=Math.round((k-He.x)/s[rl]),Dl=Math.round((C-He.y)/s[el]);Se[rl]=Math.max(J.left,Math.min(J.right,cl*s[rl]+He.x)),Se[el]=Math.max(J.top,Math.min(J.bottom,Dl*s[el]+He.y))}return Se};return h.grid=s,h.coordFields=t,h}}),Wo={id:"snappers",install:function(s){var t=s.interactStatic;t.snappers=P(t.snappers||{},no),t.createSnapGrid=t.snappers.grid}},Go=Wo,Ko={start:function(s){var t=s.state,h=s.rect,k=s.edges,C=s.pageCoords,F=t.options,Y=F.ratio,J=F.enabled,xe=t.options,He=xe.equalDelta,Se=xe.modifiers;Y==="preserve"&&(Y=h.width/h.height),t.startCoords=P({},C),t.startRect=P({},h),t.ratio=Y,t.equalDelta=He;var da=t.linkedEdges={top:k.top||k.left&&!k.bottom,left:k.left||k.top&&!k.right,bottom:k.bottom||k.right&&!k.top,right:k.right||k.bottom&&!k.left};if(t.xIsPrimaryAxis=!(!k.left&&!k.right),t.equalDelta){var Ma=(da.left?1:-1)*(da.top?1:-1);t.edgeSign={x:Ma,y:Ma}}else t.edgeSign={x:da.left?-1:1,y:da.top?-1:1};if(J!==!1&&P(k,da),Se!=null&&Se.length){var rl=new Oa(s.interaction);rl.copyFrom(s.interaction.modification),rl.prepareStates(Se),t.subModification=rl,rl.startAll(n({},s))}},set:function(s){var t=s.state,h=s.rect,k=s.coords,C=t.linkedEdges,F=P({},k),Y=t.equalDelta?Yo:Vi;if(P(s.edges,C),Y(t,t.xIsPrimaryAxis,k,h),!t.subModification)return null;var J=P({},h);de(C,J,{x:k.x-F.x,y:k.y-F.y});var xe=t.subModification.setAll(n(n({},s),{},{rect:J,edges:C,pageCoords:k,prevCoords:k,prevRect:J})),He=xe.delta;return xe.changed&&(Y(t,Math.abs(He.x)>Math.abs(He.y),xe.coords,xe.rect),P(k,xe.coords)),xe.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function Yo(s,t,h){var k=s.startCoords,C=s.edgeSign;t?h.y=k.y+(h.x-k.x)*C.y:h.x=k.x+(h.y-k.y)*C.x}function Vi(s,t,h,k){var C=s.startRect,F=s.startCoords,Y=s.ratio,J=s.edgeSign;if(t){var xe=k.width/Y;h.y=F.y+(xe-C.height)*J.y}else{var He=k.height*Y;h.x=F.x+(He-C.width)*J.x}}var Jo=Rl(Ko,"aspectRatio"),ki=function(){};ki._defaults={};var si=ki;function Pn(s,t,h){return S.func(s)?Me(s,t.interactable,t.element,[h.x,h.y,t]):Me(s,t.interactable,t.element)}var xi={start:function(s){var t=s.rect,h=s.startOffset,k=s.state,C=s.interaction,F=s.pageCoords,Y=k.options,J=Y.elementRect,xe=P({left:0,top:0,right:0,bottom:0},Y.offset||{});if(t&&J){var He=Pn(Y.restriction,C,F);if(He){var Se=He.right-He.left-t.width,da=He.bottom-He.top-t.height;Se<0&&(xe.left+=Se,xe.right+=Se),da<0&&(xe.top+=da,xe.bottom+=da)}xe.left+=h.left-t.width*J.left,xe.top+=h.top-t.height*J.top,xe.right+=h.right-t.width*(1-J.right),xe.bottom+=h.bottom-t.height*(1-J.bottom)}k.offset=xe},set:function(s){var t=s.coords,h=s.interaction,k=s.state,C=k.options,F=k.offset,Y=Pn(C.restriction,h,t);if(Y){var J=function(xe){return!xe||"left"in xe&&"top"in xe||((xe=P({},xe)).left=xe.x||0,xe.top=xe.y||0,xe.right=xe.right||xe.left+xe.width,xe.bottom=xe.bottom||xe.top+xe.height),xe}(Y);t.x=Math.max(Math.min(J.right-F.right,t.x),J.left+F.left),t.y=Math.max(Math.min(J.bottom-F.bottom,t.y),J.top+F.top)}},defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}},Xo=Rl(xi,"restrict"),io={top:1/0,left:1/0,bottom:-1/0,right:-1/0},Qn={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function Fi(s,t){for(var h=0,k=["top","left","bottom","right"];h<k.length;h++){var C=k[h];C in s||(s[C]=t[C])}return s}var Wn={noInner:io,noOuter:Qn,start:function(s){var t,h=s.interaction,k=s.startOffset,C=s.state,F=C.options;F&&(t=Le(Pn(F.offset,h,h.coords.start.page))),t=t||{x:0,y:0},C.offset={top:t.y+k.top,left:t.x+k.left,bottom:t.y-k.bottom,right:t.x-k.right}},set:function(s){var t=s.coords,h=s.edges,k=s.interaction,C=s.state,F=C.offset,Y=C.options;if(h){var J=P({},t),xe=Pn(Y.inner,k,J)||{},He=Pn(Y.outer,k,J)||{};Fi(xe,io),Fi(He,Qn),h.top?t.y=Math.min(Math.max(He.top+F.top,J.y),xe.top+F.top):h.bottom&&(t.y=Math.max(Math.min(He.bottom+F.bottom,J.y),xe.bottom+F.bottom)),h.left?t.x=Math.min(Math.max(He.left+F.left,J.x),xe.left+F.left):h.right&&(t.x=Math.max(Math.min(He.right+F.right,J.x),xe.right+F.right))}},defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}},Zo=Rl(Wn,"restrictEdges"),Qo=P({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(s){}},xi.defaults),et=Rl({start:xi.start,set:xi.set,defaults:Qo},"restrictRect"),at={width:-1/0,height:-1/0},oo={width:1/0,height:1/0},ci=Rl({start:function(s){return Wn.start(s)},set:function(s){var t=s.interaction,h=s.state,k=s.rect,C=s.edges,F=h.options;if(C){var Y=Ie(Pn(F.min,t,s.coords))||at,J=Ie(Pn(F.max,t,s.coords))||oo;h.options={endOnly:F.endOnly,inner:P({},Wn.noInner),outer:P({},Wn.noOuter)},C.top?(h.options.inner.top=k.bottom-Y.height,h.options.outer.top=k.bottom-J.height):C.bottom&&(h.options.inner.bottom=k.top+Y.height,h.options.outer.bottom=k.top+J.height),C.left?(h.options.inner.left=k.right-Y.width,h.options.outer.left=k.right-J.width):C.right&&(h.options.inner.right=k.left+Y.width,h.options.outer.right=k.left+J.width),Wn.set(s),h.options=F}},defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize"),wi={start:function(s){var t,h=s.interaction,k=s.interactable,C=s.element,F=s.rect,Y=s.state,J=s.startOffset,xe=Y.options,He=xe.offsetWithOrigin?function(Ma){var rl=Ma.interaction.element,el=Le(Me(Ma.state.options.origin,null,null,[rl])),cl=el||De(Ma.interactable,rl,Ma.interaction.prepared.name);return cl}(s):{x:0,y:0};if(xe.offset==="startCoords")t={x:h.coords.start.page.x,y:h.coords.start.page.y};else{var Se=Me(xe.offset,k,C,[h]);(t=Le(Se)||{x:0,y:0}).x+=He.x,t.y+=He.y}var da=xe.relativePoints;Y.offsets=F&&da&&da.length?da.map(function(Ma,rl){return{index:rl,relativePoint:Ma,x:J.left-F.width*Ma.x+t.x,y:J.top-F.height*Ma.y+t.y}}):[{index:0,relativePoint:null,x:t.x,y:t.y}]},set:function(s){var t=s.interaction,h=s.coords,k=s.state,C=k.options,F=k.offsets,Y=De(t.interactable,t.element,t.prepared.name),J=P({},h),xe=[];C.offsetWithOrigin||(J.x-=Y.x,J.y-=Y.y);for(var He=0,Se=F;He<Se.length;He++)for(var da=Se[He],Ma=J.x-da.x,rl=J.y-da.y,el=0,cl=C.targets.length;el<cl;el++){var Dl=C.targets[el],El=void 0;(El=S.func(Dl)?Dl(Ma,rl,t._proxy,da,el):Dl)&&xe.push({x:(S.number(El.x)?El.x:Ma)+da.x,y:(S.number(El.y)?El.y:rl)+da.y,range:S.number(El.range)?El.range:C.range,source:Dl,index:el,offset:da})}for(var Vl={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}},ir=0;ir<xe.length;ir++){var fr=xe[ir],ql=fr.range,sr=fr.x-J.x,dn=fr.y-J.y,ar=Ge(sr,dn),bn=ar<=ql;ql===1/0&&Vl.inRange&&Vl.range!==1/0&&(bn=!1),Vl.target&&!(bn?Vl.inRange&&ql!==1/0?ar/ql<Vl.distance/Vl.range:ql===1/0&&Vl.range!==1/0||ar<Vl.distance:!Vl.inRange&&ar<Vl.distance)||(Vl.target=fr,Vl.distance=ar,Vl.range=ql,Vl.inRange=bn,Vl.delta.x=sr,Vl.delta.y=dn)}return Vl.inRange&&(h.x=Vl.target.x,h.y=Vl.target.y),k.closest=Vl,Vl},defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}},to=Rl(wi,"snap"),jn={start:function(s){var t=s.state,h=s.edges,k=t.options;if(!h)return null;s.state={options:{targets:null,relativePoints:[{x:h.left?0:1,y:h.top?0:1}],offset:k.offset||"self",origin:{x:0,y:0},range:k.range}},t.targetFields=t.targetFields||[["width","height"],["x","y"]],wi.start(s),t.offsets=s.state.offsets,s.state=t},set:function(s){var t=s.interaction,h=s.state,k=s.coords,C=h.options,F=h.offsets,Y={x:k.x-F[0].x,y:k.y-F[0].y};h.options=P({},C),h.options.targets=[];for(var J=0,xe=C.targets||[];J<xe.length;J++){var He=xe[J],Se=void 0;if(Se=S.func(He)?He(Y.x,Y.y,t):He){for(var da=0,Ma=h.targetFields;da<Ma.length;da++){var rl=Ma[da],el=rl[0],cl=rl[1];if(el in Se||cl in Se){Se.x=Se[el],Se.y=Se[cl];break}}h.options.targets.push(Se)}}var Dl=wi.set(s);return h.options=C,Dl},defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}},lt=Rl(jn,"snapSize"),_i={aspectRatio:Jo,restrictEdges:Zo,restrict:Xo,restrictRect:et,restrictSize:ci,snapEdges:Rl({start:function(s){var t=s.edges;return t?(s.state.targetFields=s.state.targetFields||[[t.left?"left":"right",t.top?"top":"bottom"]],jn.start(s)):null},set:jn.set,defaults:P(Ml(jn.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})},"snapEdges"),snap:to,snapSize:lt,spring:si,avoid:si,transform:si,rubberband:si},ui={id:"modifiers",install:function(s){var t=s.interactStatic;for(var h in s.usePlugin(vn),s.usePlugin(Go),t.modifiers=_i,_i){var k=_i[h],C=k._defaults,F=k._methods;C._methods=F,s.defaults.perAction[h]=C}}},rt=ui,so=function(s){m(h,s);var t=D(h);function h(k,C,F,Y,J,xe){var He;if(o(this,h),V(d(He=t.call(this,J)),F),F!==C&&V(d(He),C),He.timeStamp=xe,He.originalEvent=F,He.type=k,He.pointerId=Ve(C),He.pointerType=ja(C),He.target=Y,He.currentTarget=null,k==="tap"){var Se=J.getPointerIndex(C);He.dt=He.timeStamp-J.pointers[Se].downTime;var da=He.timeStamp-J.tapTime;He.double=!!J.prevTap&&J.prevTap.type!=="doubletap"&&J.prevTap.target===He.target&&da<500}else k==="doubletap"&&(He.dt=C.timeStamp-J.tapTime,He.double=!0);return He}return c(h,[{key:"_subtractOrigin",value:function(k){var C=k.x,F=k.y;return this.pageX-=C,this.pageY-=F,this.clientX-=C,this.clientY-=F,this}},{key:"_addOrigin",value:function(k){var C=k.x,F=k.y;return this.pageX+=C,this.pageY+=F,this.clientX+=C,this.clientY+=F,this}},{key:"preventDefault",value:function(){this.originalEvent.preventDefault()}}]),h}(Pe),di={id:"pointer-events/base",before:["inertia","modifiers","auto-start","actions"],install:function(s){s.pointerEvents=di,s.defaults.actions.pointerEvents=di.defaults,P(s.actions.phaselessTypes,di.types)},listeners:{"interactions:new":function(s){var t=s.interaction;t.prevTap=null,t.tapTime=0},"interactions:update-pointer":function(s){var t=s.down,h=s.pointerInfo;!t&&h.hold||(h.hold={duration:1/0,timeout:null})},"interactions:move":function(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget;s.duplicate||h.pointerIsDown&&!h.pointerWasMoved||(h.pointerIsDown&&Pi(s),Hn({interaction:h,pointer:k,event:C,eventTarget:F,type:"move"},t))},"interactions:down":function(s,t){(function(h,k){for(var C=h.interaction,F=h.pointer,Y=h.event,J=h.eventTarget,xe=h.pointerIndex,He=C.pointers[xe].hold,Se=qe(J),da={interaction:C,pointer:F,event:Y,eventTarget:J,type:"hold",targets:[],path:Se,node:null},Ma=0;Ma<Se.length;Ma++){var rl=Se[Ma];da.node=rl,k.fire("pointerEvents:collect-targets",da)}if(da.targets.length){for(var el=1/0,cl=0,Dl=da.targets;cl<Dl.length;cl++){var El=Dl[cl].eventable.options.holdDuration;El<el&&(el=El)}He.duration=el,He.timeout=setTimeout(function(){Hn({interaction:C,eventTarget:J,pointer:F,event:Y,type:"hold"},k)},el)}})(s,t),Hn(s,t)},"interactions:up":function(s,t){Pi(s),Hn(s,t),function(h,k){var C=h.interaction,F=h.pointer,Y=h.event,J=h.eventTarget;C.pointerWasMoved||Hn({interaction:C,eventTarget:J,pointer:F,event:Y,type:"tap"},k)}(s,t)},"interactions:cancel":function(s,t){Pi(s),Hn(s,t)}},PointerEvent:so,fire:Hn,collectEventTargets:co,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 Hn(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget,Y=s.type,J=s.targets,xe=J===void 0?co(s,t):J,He=new so(Y,k,C,F,h,t.now());t.fire("pointerEvents:new",{pointerEvent:He});for(var Se={interaction:h,pointer:k,event:C,eventTarget:F,targets:xe,type:Y,pointerEvent:He},da=0;da<xe.length;da++){var Ma=xe[da];for(var rl in Ma.props||{})He[rl]=Ma.props[rl];var el=De(Ma.eventable,Ma.node);if(He._subtractOrigin(el),He.eventable=Ma.eventable,He.currentTarget=Ma.node,Ma.eventable.fire(He),He._addOrigin(el),He.immediatePropagationStopped||He.propagationStopped&&da+1<xe.length&&xe[da+1].node!==He.currentTarget)break}if(t.fire("pointerEvents:fired",Se),Y==="tap"){var cl=He.double?Hn({interaction:h,pointer:k,event:C,eventTarget:F,type:"doubletap"},t):He;h.prevTap=cl,h.tapTime=cl.timeStamp}return He}function co(s,t){var h=s.interaction,k=s.pointer,C=s.event,F=s.eventTarget,Y=s.type,J=h.getPointerIndex(k),xe=h.pointers[J];if(Y==="tap"&&(h.pointerWasMoved||!xe||xe.downTarget!==F))return[];for(var He=qe(F),Se={interaction:h,pointer:k,event:C,eventTarget:F,type:Y,path:He,targets:[],node:null},da=0;da<He.length;da++){var Ma=He[da];Se.node=Ma,t.fire("pointerEvents:collect-targets",Se)}return Y==="hold"&&(Se.targets=Se.targets.filter(function(rl){var el,cl;return rl.eventable.options.holdDuration===((el=h.pointers[J])==null||(cl=el.hold)==null?void 0:cl.duration)})),Se.targets}function Pi(s){var t=s.interaction,h=s.pointerIndex,k=t.pointers[h].hold;k&&k.timeout&&(clearTimeout(k.timeout),k.timeout=null)}var nt=Object.freeze({__proto__:null,default:di});function it(s){var t=s.interaction;t.holdIntervalHandle&&(clearInterval(t.holdIntervalHandle),t.holdIntervalHandle=null)}var uo={id:"pointer-events/holdRepeat",install:function(s){s.usePlugin(di);var t=s.pointerEvents;t.defaults.holdRepeatInterval=0,t.types.holdrepeat=s.actions.phaselessTypes.holdrepeat=!0},listeners:["move","up","cancel","endall"].reduce(function(s,t){return s["pointerEvents:".concat(t)]=it,s},{"pointerEvents:new":function(s){var t=s.pointerEvent;t.type==="hold"&&(t.count=(t.count||0)+1)},"pointerEvents:fired":function(s,t){var h=s.interaction,k=s.pointerEvent,C=s.eventTarget,F=s.targets;if(k.type==="hold"&&F.length){var Y=F[0].eventable.options.holdRepeatInterval;Y<=0||(h.holdIntervalHandle=setTimeout(function(){t.pointerEvents.fire({interaction:h,eventTarget:C,type:"hold",pointer:k,event:k},t)},Y))}}})},ot=uo,tt={id:"pointer-events/interactableTargets",install:function(s){var t=s.Interactable;t.prototype.pointerEvents=function(k){return P(this.events.options,k),this};var h=t.prototype._backCompatOption;t.prototype._backCompatOption=function(k,C){var F=h.call(this,k,C);return F===this&&(this.events.options[k]=C),F}},listeners:{"pointerEvents:collect-targets":function(s,t){var h=s.targets,k=s.node,C=s.type,F=s.eventTarget;t.interactables.forEachMatch(k,function(Y){var J=Y.events,xe=J.options;J.types[C]&&J.types[C].length&&Y.testIgnoreAllow(xe,k,F)&&h.push({node:k,eventable:J,props:{interactable:Y}})})},"interactable:new":function(s){var t=s.interactable;t.events.getRect=function(h){return t.getRect(h)}},"interactable:set":function(s,t){var h=s.interactable,k=s.options;P(h.events.options,t.pointerEvents.defaults),P(h.events.options,k.pointerEvents||{})}}},st=tt,ct={id:"pointer-events",install:function(s){s.usePlugin(nt),s.usePlugin(ot),s.usePlugin(st)}},Si=ct,ut={id:"reflow",install:function(s){var t=s.Interactable;s.actions.phases.reflow=!0,t.prototype.reflow=function(h){return function(k,C,F){for(var Y=k.getAllElements(),J=F.window.Promise,xe=J?[]:null,He=function(){var da=Y[Se],Ma=k.getRect(da);if(!Ma)return 1;var rl,el=$e(F.interactions.list,function(El){return El.interacting()&&El.interactable===k&&El.element===da&&El.prepared.name===C.name});if(el)el.move(),xe&&(rl=el._reflowPromise||new J(function(El){el._reflowResolve=El}));else{var cl=Ie(Ma),Dl=function(El){return{coords:El,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:cl.x,y:cl.y},client:{x:cl.x,y:cl.y},timeStamp:F.now()});rl=function(El,Vl,ir,fr,ql){var sr=El.interactions.new({pointerType:"reflow"}),dn={interaction:sr,event:ql,pointer:ql,eventTarget:ir,phase:"reflow"};sr.interactable=Vl,sr.element=ir,sr.prevEvent=ql,sr.updatePointer(ql,ql,ir,!0),ce(sr.coords.delta),Ha(sr.prepared,fr),sr._doPhase(dn);var ar=El.window,bn=ar.Promise,Xr=bn?new bn(function(Rn){sr._reflowResolve=Rn}):void 0;return sr._reflowPromise=Xr,sr.start(fr,Vl,ir),sr._interacting?(sr.move(dn),sr.end(ql)):(sr.stop(),sr._reflowResolve()),sr.removePointer(ql,ql),Xr}(F,k,da,C,Dl)}xe&&xe.push(rl)},Se=0;Se<Y.length&&!He();Se++);return xe&&J.all(xe).then(function(){return k})}(this,h,s)}},listeners:{"interactions:stop":function(s,t){var h=s.interaction;h.pointerType==="reflow"&&(h._reflowResolve&&h._reflowResolve(),function(k,C){k.splice(k.indexOf(C),1)}(t.interactions.list,h))}}},dt=ut;if(un.use(Ra),un.use(Ql),un.use(Si),un.use(Br),un.use(rt),un.use(bl),un.use(Gl),un.use(fl),un.use(dt),un.default=un,i(a)==="object"&&a)try{a.exports=un}catch{}return un.default=un,un})}(Ki,Ki.exports)),Ki.exports}var o1=i1();const Gs=M.getDefaultExportFromCjs(o1),Ro=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:r}){const n=a,i=r,o=e.inject(tu),p=e.inject(su);if(!o)throw new Error("[grid-layout-plus]: missing layout store, GridItem must under a GridLayout.");const c=e.shallowRef(null),u=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,y=NaN,d=NaN,D=NaN,w=NaN,q=-1,A=-1,j=-1,O=-1,E=n.x,_=n.y,x=n.w,b=n.h;const S=e.ref(),I=e.reactive({i:e.toRef(n,"i"),state:u,wrapper:S,calcXY:Me});function R(he){Xe(he)}function re(){Ea()}function X(he){Bn(n.isDraggable)&&(u.draggable=he)}function me(he){Bn(n.isResizable)&&(u.resizable=he)}function ue(he){Bn(n.isBounded)&&(u.bounded=he)}function U(he){u.transformScale=he}function W(he){u.rowHeight=he}function Z(he){u.maxRows=he}function ae(){u.rtl=qs()==="rtl",Ea()}function ve(he){u.cols=Math.floor(he)}o.increaseItem(I),e.onBeforeMount(()=>{u.rtl=qs()==="rtl"}),e.onMounted(()=>{o.responsive&&o.lastBreakpoint?u.cols=fu(o.lastBreakpoint,o.cols):u.cols=o.colNum,u.rowHeight=o.rowHeight,u.containerWidth=o.width!==null?o.width:100,u.margin=o.margin!==void 0?o.margin.map(Number):[10,10],u.maxRows=o.maxRows,Bn(n.isDraggable)?u.draggable=o.isDraggable:u.draggable=n.isDraggable,Bn(n.isResizable)?u.resizable=o.isResizable:u.resizable=n.isResizable,Bn(n.isBounded)?u.bounded=o.isBounded:u.bounded=n.isBounded,u.transformScale=o.transformScale,u.useCssTransforms=o.useCssTransforms,u.useStyleCursor=o.useStyleCursor,e.watchEffect(()=>{E=n.x,_=n.y,b=n.h,x=n.w,kn(_e)}),p.on("updateWidth",R),p.on("compact",re),p.on("setDraggable",X),p.on("setResizable",me),p.on("setBounded",ue),p.on("setTransformScale",U),p.on("setRowHeight",W),p.on("setMaxRows",Z),p.on("directionchange",ae),p.on("setColNum",ve)}),e.onBeforeUnmount(()=>{p.off("updateWidth",R),p.off("compact",re),p.off("setDraggable",X),p.off("setResizable",me),p.off("setBounded",ue),p.off("setTransformScale",U),p.off("setRowHeight",W),p.off("setMaxRows",Z),p.off("directionchange",ae),p.off("setColNum",ve),c.value&&(c.value.unset(),c.value=null),o.decreaseItem(I)}),l({state:u,wrapper:S});const ze=typeof navigator<"u"?navigator.userAgent.toLowerCase().includes("android"):!1,te=e.computed(()=>u.resizable&&!n.static),N=e.computed(()=>o.isMirrored?!u.rtl:u.rtl),se=e.computed(()=>(u.draggable||u.resizable)&&!n.static),G=Xv("item"),fe=e.computed(()=>({[G.b()]:!0,[G.bm("resizable")]:te.value,[G.bm("static")]:n.static,[G.bm("resizing")]:u.isResizing,[G.bm("dragging")]:u.isDragging,[G.bm("transform")]:u.useCssTransforms,[G.bm("rtl")]:N.value,[G.bm("no-touch")]:ze&&se.value})),we=e.computed(()=>[G.be("resizer"),N.value&&G.bem("resizer","rtl")].filter(Boolean));e.watch(()=>n.isDraggable,he=>{u.draggable=he}),e.watch(()=>n.static,()=>{kn(V),kn(ce)}),e.watch(()=>u.draggable,()=>{kn(V)}),e.watch(()=>n.isResizable,he=>{u.resizable=he}),e.watch(()=>n.isBounded,he=>{u.bounded=he}),e.watch(()=>u.resizable,()=>{kn(ce)}),e.watch(()=>u.rowHeight,()=>{kn(_e),kn(qe)}),e.watch([()=>u.cols,()=>u.containerWidth],()=>{kn(ce),kn(_e),kn(qe)}),e.watch([()=>n.minH,()=>n.maxH,()=>n.minW,()=>n.maxW],()=>{kn(ce)}),e.watch(N,()=>{kn(ce),kn(_e)}),e.watch([()=>o.margin,()=>o.margin[0],()=>o.margin[1]],()=>{const he=o.margin;!he||he[0]===u.margin[0]&&he[1]===u.margin[1]||(u.margin=he.map(Number),kn(_e),kn(qe))});function _e(){n.x+n.w>u.cols?(E=0,x=n.w>u.cols?u.cols:n.w):(E=n.x,x=n.w);const he=Ke(E,_,x,b);u.isDragging&&(he.top=u.dragging.top,N.value?he.right=u.dragging.left:he.left=u.dragging.left),u.isResizing&&(he.width=u.resizing.width,he.height=u.resizing.height);let pa;u.useCssTransforms?N.value?pa=Gv(he.top,he.right,he.width,he.height):pa=Wv(he.top,he.left,he.width,he.height):N.value?pa=Yv(he.top,he.right,he.width,he.height):pa=Kv(he.top,he.left,he.width,he.height),u.style=pa}function qe(){const he={};for(const pa of["width","height"]){const ia=u.style[pa].match(/^(\d+)px$/);if(!ia)return;he[pa]=ia[1]}i("container-resized",n.i,n.h,n.w,he.height,he.width)}function ra(he){if(n.static)return;const pa=he.type;if(pa==="resizestart"&&u.isResizing||pa!=="resizestart"&&!u.isResizing)return;const ia=Hs(he);if(Bn(ia))return;const{x:Ve,y:ya}=ia,Ca={width:0,height:0};let Ce;switch(pa){case"resizestart":{ce(),q=x,A=b,Ce=Ke(E,_,x,b),Ca.width=Ce.width,Ca.height=Ce.height,u.resizing=Ca,u.isResizing=!0;break}case"resizemove":{!he.edges.right&&!he.edges.left&&(D=Ve),!he.edges.top&&!he.edges.bottom&&(w=ya);const Fa=Us(D,w,Ve,ya);N.value?Ca.width=u.resizing.width-Fa.deltaX/u.transformScale:Ca.width=u.resizing.width+Fa.deltaX/u.transformScale,Ca.height=u.resizing.height+Fa.deltaY/u.transformScale,u.resizing=Ca;break}case"resizeend":{Ce=Ke(E,_,x,b),Ca.width=Ce.width,Ca.height=Ce.height,u.resizing={width:-1,height:-1},u.isResizing=!1;break}}Ce=De(Ca.height,Ca.width),Ce.w<n.minW&&(Ce.w=n.minW),Ce.w>n.maxW&&(Ce.w=n.maxW),Ce.h<n.minH&&(Ce.h=n.minH),Ce.h>n.maxH&&(Ce.h=n.maxH),Ce.h<1&&(Ce.h=1),Ce.w<1&&(Ce.w=1),D=Ve,w=ya,(x!==Ce.w||b!==Ce.h)&&i("resize",n.i,Ce.h,Ce.w,Ca.height,Ca.width),he.type==="resizeend"&&(q!==x||A!==b)&&i("resized",n.i,Ce.h,Ce.w,Ca.height,Ca.width),p.emit("resizeEvent",he.type,n.i,E,_,Ce.h,Ce.w)}function P(he){if(n.static||u.isResizing)return;const pa=he.type;if(pa==="dragstart"&&u.isDragging||pa!=="dragstart"&&!u.isDragging)return;const ia=Hs(he);if(Bn(ia))return;const{x:Ve,y:ya}=ia,Ca=he.target;if(!Ca.offsetParent)return;const Ce={top:0,left:0};switch(pa){case"dragstart":{j=E,O=_;const Ta=Ca.offsetParent.getBoundingClientRect(),fa=Ca.getBoundingClientRect(),ja=fa.left/u.transformScale,sa=Ta.left/u.transformScale,Pe=fa.right/u.transformScale,ma=Ta.right/u.transformScale,Qe=fa.top/u.transformScale,Oe=Ta.top/u.transformScale;N.value?Ce.left=(Pe-ma)*-1:Ce.left=ja-sa,Ce.top=Qe-Oe,u.dragging=Ce,u.isDragging=!0;break}case"dragmove":{const Ta=Us(y,d,Ve,ya);if(N.value?Ce.left=u.dragging.left-Ta.deltaX/u.transformScale:Ce.left=u.dragging.left+Ta.deltaX/u.transformScale,Ce.top=u.dragging.top+Ta.deltaY/u.transformScale,u.bounded){const fa=Ca.offsetParent.clientHeight-Ie(n.h,u.rowHeight,u.margin[1]);Ce.top=de(Ce.top,0,fa);const ja=Le(),sa=u.containerWidth-Ie(n.w,ja,u.margin[0]);Ce.left=de(Ce.left,0,sa)}u.dragging=Ce;break}case"dragend":{const Ta=Ca.offsetParent.getBoundingClientRect(),fa=Ca.getBoundingClientRect(),ja=fa.left/u.transformScale,sa=Ta.left/u.transformScale,Pe=fa.right/u.transformScale,ma=Ta.right/u.transformScale,Qe=fa.top/u.transformScale,Oe=Ta.top/u.transformScale;N.value?Ce.left=(Pe-ma)*-1:Ce.left=ja-sa,Ce.top=Qe-Oe,u.dragging={top:-1,left:-1},u.isDragging=!1;break}}let Fa;N.value,Fa=Me(Ce.top,Ce.left),y=Ve,d=ya,(E!==Fa.x||_!==Fa.y)&&i("move",n.i,Fa.x,Fa.y),he.type==="dragend"&&(j!==E||O!==_)&&i("moved",n.i,Fa.x,Fa.y),p.emit("dragEvent",he.type,n.i,Fa.x,Fa.y,b,x)}function Ke(he,pa,ia,Ve){const ya=Le();let Ca;return N.value?Ca={right:Math.round(ya*he+(he+1)*u.margin[0]),top:Math.round(u.rowHeight*pa+(pa+1)*u.margin[1]),width:ia===1/0?ia:Math.round(ya*ia+Math.max(0,ia-1)*u.margin[0]),height:Ve===1/0?Ve:Math.round(u.rowHeight*Ve+Math.max(0,Ve-1)*u.margin[1])}:Ca={left:Math.round(ya*he+(he+1)*u.margin[0]),top:Math.round(u.rowHeight*pa+(pa+1)*u.margin[1]),width:ia===1/0?ia:Math.round(ya*ia+Math.max(0,ia-1)*u.margin[0]),height:Ve===1/0?Ve:Math.round(u.rowHeight*Ve+Math.max(0,Ve-1)*u.margin[1])},Ca}function Me(he,pa){const ia=Le();let Ve=Math.round((pa-u.margin[0])/(ia+u.margin[0])),ya=Math.round((he-u.margin[1])/(u.rowHeight+u.margin[1]));return Ve=Math.max(Math.min(Ve,u.cols-x),0),ya=Math.max(Math.min(ya,u.maxRows-b),0),{x:Ve,y:ya}}function Le(){return(u.containerWidth-u.margin[0]*(u.cols+1))/u.cols}function Ie(he,pa,ia){return Number.isFinite(he)?Math.round(pa*he+Math.max(0,he-1)*ia):he}function de(he,pa,ia){return Math.max(Math.min(he,ia),pa)}function De(he,pa,ia=!1){const Ve=Le();let ya=Math.round((pa+u.margin[0])/(Ve+u.margin[0])),Ca=0;return ia?Ca=Math.ceil((he+u.margin[1])/(u.rowHeight+u.margin[1])):Ca=Math.round((he+u.margin[1])/(u.rowHeight+u.margin[1])),ya=Math.max(Math.min(ya,u.cols-E),0),Ca=Math.max(Math.min(Ca,u.maxRows-_),0),{w:ya,h:Ca}}function Xe(he,pa){u.containerWidth=he}function Ea(){_e()}function Ge(){!c.value&&S.value&&(c.value=Gs(S.value),u.useStyleCursor||c.value.styleCursor(!1))}const $=Fs(P);function V(){if(Ge(),!!c.value)if(u.draggable&&!n.static){const he={ignoreFrom:n.dragIgnoreFrom,allowFrom:n.dragAllowFrom,...n.dragOption};c.value.draggable(he),m||(m=!0,c.value.on("dragstart dragmove dragend",pa=>{pa.type==="dragmove"?$(pa):P(pa)}))}else c.value.draggable({enabled:!1})}const ee=Fs(ra);function ce(){if(Ge(),!!c.value)if(u.resizable&&!n.static){const he=Ke(0,0,n.maxW,n.maxH),pa=Ke(0,0,n.minW,n.minH),ia={edges:{left:N.value?`.${we.value[0]}`:!1,right:N.value?!1:`.${we.value[0]}`,bottom:`.${we.value[0]}`,top:!1},ignoreFrom:n.resizeIgnoreFrom,restrictSize:{min:{height:pa.height*u.transformScale,width:pa.width*u.transformScale},max:{height:he.height*u.transformScale,width:he.width*u.transformScale}},...n.resizeOption};n.preserveAspectRatio&&(ia.modifiers=[Gs.modifiers.aspectRatio({ratio:"preserve"})]),c.value.resizable(ia),g||(g=!0,c.value.on("resizestart resizemove resizeend",Ve=>{Ve.type==="resizemove"?ee(Ve):ra(Ve)}))}else c.value.resizable({enabled:!1})}return(he,pa)=>(e.openBlock(),e.createElementBlock("section",{ref_key:"wrapper",ref:S,class:e.normalizeClass(fe.value),style:e.normalizeStyle(u.style)},[e.renderSlot(he.$slots,"default"),te.value?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(we.value)},null,2)):e.createCommentVNode("",!0)],6))}}),bi=typeof window<"u";var Ks;bi&&(Ks=window==null?void 0:window.navigator)!=null&&Ks.userAgent&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Ys(a){return a!=null}function Js(){}const s1=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(s1)));const c1=bi&&("ontouchstart"in window||d1()>0),u1=c1?"pointerdown":"click";function d1(){return typeof navigator<"u"&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)||0}function p1(a,l,r=window.Event){const{type:n,bubbles:i=!1,cancelable:o=!1,...p}=l;if(!Ys(n)||n==="")return!1;let c;return Ys(r)?c=new r(n,{bubbles:i,cancelable:o}):(c=document.createEvent("HTMLEvents"),c.initEvent(n,i,o)),Object.assign(c,p),a.dispatchEvent(c)}const f1="clickoutside",h1=new Set;bi&&document.addEventListener(u1,a=>{const l=a.target,r=a.composedPath&&a.composedPath();h1.forEach(n=>{n!==l&&(r?!r.includes(n):!n.contains(l))&&(!n.__transferElement||n.__transferElement!==l&&!n.__transferElement.contains(l))&&p1(n,{type:f1})})},!0);const v1=[["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 Eo;if(bi){for(const a of v1)if(a[1]in document){Eo=a;break}}e.computed(()=>!1);const m1=new Set,y1=new WeakMap;if(bi&&Eo){const a=Eo[2],l=Eo[4];document.addEventListener(l,()=>{if(m1.forEach(r=>{r.value=!1}),document[a]){const r=y1.get(document[a]);r&&(r.value=!0)}},!1)}const vu=new Map;vu.set("x",0);vu.set("y",0);var yi=[],g1=function(){return yi.some(function(a){return a.activeTargets.length>0})},b1=function(){return yi.some(function(a){return a.skippedTargets.length>0})},Xs="ResizeObserver loop completed with undelivered notifications.",k1=function(){var a;typeof ErrorEvent=="function"?a=new ErrorEvent("error",{message:Xs}):(a=document.createEvent("Event"),a.initEvent("error",!1,!1),a.message=Xs),window.dispatchEvent(a)},ao;(function(a){a.BORDER_BOX="border-box",a.CONTENT_BOX="content-box",a.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(ao||(ao={}));var gi=function(a){return Object.freeze(a)},x1=function(){function a(l,r){this.inlineSize=l,this.blockSize=r,gi(this)}return a}(),mu=function(){function a(l,r,n,i){return this.x=l,this.y=r,this.width=n,this.height=i,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,gi(this)}return a.prototype.toJSON=function(){var l=this,r=l.x,n=l.y,i=l.top,o=l.right,p=l.bottom,c=l.left,u=l.width,m=l.height;return{x:r,y:n,top:i,right:o,bottom:p,left:c,width:u,height:m}},a.fromRect=function(l){return new a(l.x,l.y,l.width,l.height)},a}(),Pt=function(a){return a instanceof SVGElement&&"getBBox"in a},yu=function(a){if(Pt(a)){var l=a.getBBox(),r=l.width,n=l.height;return!r&&!n}var i=a,o=i.offsetWidth,p=i.offsetHeight;return!(o||p||a.getClientRects().length)},Zs=function(a){var l;if(a instanceof Element)return!0;var r=(l=a==null?void 0:a.ownerDocument)===null||l===void 0?void 0:l.defaultView;return!!(r&&a instanceof r.Element)},w1=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},Zi=typeof window<"u"?window:{},xo=new WeakMap,Qs=/auto|scroll/,_1=/^tb|vertical/,S1=/msie|trident/i.test(Zi.navigator&&Zi.navigator.userAgent),qn=function(a){return parseFloat(a||"0")},Oi=function(a,l,r){return a===void 0&&(a=0),l===void 0&&(l=0),r===void 0&&(r=!1),new x1((r?l:a)||0,(r?a:l)||0)},ec=gi({devicePixelContentBoxSize:Oi(),borderBoxSize:Oi(),contentBoxSize:Oi(),contentRect:new mu(0,0,0,0)}),gu=function(a,l){if(l===void 0&&(l=!1),xo.has(a)&&!l)return xo.get(a);if(yu(a))return xo.set(a,ec),ec;var r=getComputedStyle(a),n=Pt(a)&&a.ownerSVGElement&&a.getBBox(),i=!S1&&r.boxSizing==="border-box",o=_1.test(r.writingMode||""),p=!n&&Qs.test(r.overflowY||""),c=!n&&Qs.test(r.overflowX||""),u=n?0:qn(r.paddingTop),m=n?0:qn(r.paddingRight),g=n?0:qn(r.paddingBottom),y=n?0:qn(r.paddingLeft),d=n?0:qn(r.borderTopWidth),D=n?0:qn(r.borderRightWidth),w=n?0:qn(r.borderBottomWidth),q=n?0:qn(r.borderLeftWidth),A=y+m,j=u+g,O=q+D,E=d+w,_=c?a.offsetHeight-E-a.clientHeight:0,x=p?a.offsetWidth-O-a.clientWidth:0,b=i?A+O:0,S=i?j+E:0,I=n?n.width:qn(r.width)-b-x,R=n?n.height:qn(r.height)-S-_,re=I+A+x+O,X=R+j+_+E,me=gi({devicePixelContentBoxSize:Oi(Math.round(I*devicePixelRatio),Math.round(R*devicePixelRatio),o),borderBoxSize:Oi(re,X,o),contentBoxSize:Oi(I,R,o),contentRect:new mu(y,u,I,R)});return xo.set(a,me),me},bu=function(a,l,r){var n=gu(a,r),i=n.borderBoxSize,o=n.contentBoxSize,p=n.devicePixelContentBoxSize;switch(l){case ao.DEVICE_PIXEL_CONTENT_BOX:return p;case ao.BORDER_BOX:return i;default:return o}},E1=function(){function a(l){var r=gu(l);this.target=l,this.contentRect=r.contentRect,this.borderBoxSize=gi([r.borderBoxSize]),this.contentBoxSize=gi([r.contentBoxSize]),this.devicePixelContentBoxSize=gi([r.devicePixelContentBoxSize])}return a}(),ku=function(a){if(yu(a))return 1/0;for(var l=0,r=a.parentNode;r;)l+=1,r=r.parentNode;return l},C1=function(){var a=1/0,l=[];yi.forEach(function(o){if(o.activeTargets.length!==0){var p=[];o.activeTargets.forEach(function(c){var u=new E1(c.target),m=ku(c.target);p.push(u),c.lastReportedSize=bu(c.target,c.observedBox),m<a&&(a=m)}),l.push(function(){o.callback.call(o.observer,p,o.observer)}),o.activeTargets.splice(0,o.activeTargets.length)}});for(var r=0,n=l;r<n.length;r++){var i=n[r];i()}return a},ac=function(a){yi.forEach(function(l){l.activeTargets.splice(0,l.activeTargets.length),l.skippedTargets.splice(0,l.skippedTargets.length),l.observationTargets.forEach(function(r){r.isActive()&&(ku(r.target)>a?l.activeTargets.push(r):l.skippedTargets.push(r))})})},D1=function(){var a=0;for(ac(a);g1();)a=C1(),ac(a);return b1()&&k1(),a>0},wt,xu=[],T1=function(){return xu.splice(0).forEach(function(a){return a()})},B1=function(a){if(!wt){var l=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return T1()}).observe(r,n),wt=function(){r.textContent="".concat(l?l--:l++)}}xu.push(a),wt()},N1=function(a){B1(function(){requestAnimationFrame(a)})},Co=0,A1=function(){return!!Co},z1=250,M1={attributes:!0,characterData:!0,childList:!0,subtree:!0},lc=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],rc=function(a){return a===void 0&&(a=0),Date.now()+a},_t=!1,I1=function(){function a(){var l=this;this.stopped=!0,this.listener=function(){return l.schedule()}}return a.prototype.run=function(l){var r=this;if(l===void 0&&(l=z1),!_t){_t=!0;var n=rc(l);N1(function(){var i=!1;try{i=D1()}finally{if(_t=!1,l=n-rc(),!A1())return;i?r.run(1e3):l>0?r.run(l):r.start()}})}},a.prototype.schedule=function(){this.stop(),this.run()},a.prototype.observe=function(){var l=this,r=function(){return l.observer&&l.observer.observe(document.body,M1)};document.body?r():Zi.addEventListener("DOMContentLoaded",r)},a.prototype.start=function(){var l=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),lc.forEach(function(r){return Zi.addEventListener(r,l.listener,!0)}))},a.prototype.stop=function(){var l=this;this.stopped||(this.observer&&this.observer.disconnect(),lc.forEach(function(r){return Zi.removeEventListener(r,l.listener,!0)}),this.stopped=!0)},a}(),Rt=new I1,nc=function(a){!Co&&a>0&&Rt.start(),Co+=a,!Co&&Rt.stop()},O1=function(a){return!Pt(a)&&!w1(a)&&getComputedStyle(a).display==="inline"},L1=function(){function a(l,r){this.target=l,this.observedBox=r||ao.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return a.prototype.isActive=function(){var l=bu(this.target,this.observedBox,!0);return O1(this.target)&&(this.lastReportedSize=l),this.lastReportedSize.inlineSize!==l.inlineSize||this.lastReportedSize.blockSize!==l.blockSize},a}(),R1=function(){function a(l,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=l,this.callback=r}return a}(),wo=new WeakMap,ic=function(a,l){for(var r=0;r<a.length;r+=1)if(a[r].target===l)return r;return-1},_o=function(){function a(){}return a.connect=function(l,r){var n=new R1(l,r);wo.set(l,n)},a.observe=function(l,r,n){var i=wo.get(l),o=i.observationTargets.length===0;ic(i.observationTargets,r)<0&&(o&&yi.push(i),i.observationTargets.push(new L1(r,n&&n.box)),nc(1),Rt.schedule())},a.unobserve=function(l,r){var n=wo.get(l),i=ic(n.observationTargets,r),o=n.observationTargets.length===1;i>=0&&(o&&yi.splice(yi.indexOf(n),1),n.observationTargets.splice(i,1),nc(-1))},a.disconnect=function(l){var r=this,n=wo.get(l);n.observationTargets.slice().forEach(function(i){return r.unobserve(l,i.target)}),n.activeTargets.splice(0,n.activeTargets.length)},a}(),$1=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.");_o.connect(this,l)}return a.prototype.observe=function(l,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Zs(l))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");_o.observe(this,l,r)},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(!Zs(l))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");_o.unobserve(this,l)},a.prototype.disconnect=function(){_o.disconnect(this)},a.toString=function(){return"function ResizeObserver () { [polyfill code] }"},a}();const $o=new WeakMap;function V1(a){var l;for(let r=0,n=a.length;r<n;++r){const i=a[r],o=$o.get(i.target);if(typeof o=="function"){const{inlineSize:p,blockSize:c}=((l=i.borderBoxSize)==null?void 0:l[0])??{},{offsetWidth:u,offsetHeight:m}=i.target;o(Object.assign(i,{offsetWidth:u,offsetHeight:m,width:p??u,height:c??m}))}}}const wu=new(bi&&window.ResizeObserver||$1)(V1);function oc(a,l){$o.set(a,l),wu.observe(a)}function tc(a){$o.has(a)&&(wu.unobserve(a),$o.delete(a))}function F1(a={}){let l=Js;const r=e.watch(()=>e.unref(a.target),i=>{l(),!(!i||typeof a.onResize!="function")&&(oc(i,a.onResize),l=()=>{tc(i),l=Js})},{immediate:!0}),n=()=>{r(),l()};return e.getCurrentScope()&&e.onScopeDispose(n),{observeResize:oc,unobserveResize:tc,unobserve:n}}const P1=e.ref(!1);e.computed(()=>P1.value);const sc="__theme_style__",St="__theme_observer__",cc=e.reactive(new Map),uc=new Map;e.watch(cc,()=>{if(!bi)return;uc.clear();const a=document.head.querySelector(`#${sc}`);a&&document.head.removeChild(a);const l=document.createElement("style");let r=`.${St} { width: 1px }`,n=1;for(const[i,[o,p]]of cc.entries())r+=` html.${o} .${St}, .${p} .${St} { width: ${++n}px }`,uc.set(n,i);l.textContent=r,l.id=sc,document.head.appendChild(l)});const _u=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:r}){const n=a,i=r,o=e.reactive({width:-1,mergedStyle:{},lastLayoutLength:0,isDragging:!1,placeholder:{x:0,y:0,w:0,h:0,i:""},layouts:{},lastBreakpoint:null,originalLayout:null}),p=new Map,c=e.ref(n.layout),u=e.ref(),{observeResize:m,unobserveResize:g}=F1(),y=Vv();y.on("resizeEvent",d),y.on("dragEvent",D),e.onBeforeMount(()=>{i("layout-before-mount",c.value)}),e.onMounted(()=>{i("layout-mounted",c.value),e.nextTick(()=>{Jv(c.value),o.originalLayout=c.value,e.nextTick(()=>{R(),u.value&&m(u.value,Fv(E,16)),zi(c.value,n.verticalCompact),i("layout-updated",c.value),O(),E()})})}),e.onBeforeUnmount(()=>{y.clearAll(),u.value&&g(u.value)});function d(X,me,ue,U,W,Z){S(X,me,ue,U,W,Z)}function D(X,me,ue,U,W,Z){b(X,me,ue,U,W,Z)}e.watch(()=>o.width,(X,me)=>{e.nextTick(()=>{y.emit("updateWidth",X),me===-1&&e.nextTick(()=>{i("layout-ready",c.value)}),O()})}),e.watch(()=>[n.layout,n.layout.length],()=>{c.value=n.layout,j()}),e.watch(()=>n.colNum,X=>{y.emit("setColNum",X)}),e.watch(()=>n.rowHeight,X=>{y.emit("setRowHeight",X)}),e.watch(()=>n.isDraggable,X=>{y.emit("setDraggable",X)}),e.watch(()=>n.isResizable,X=>{y.emit("setResizable",X)}),e.watch(()=>n.isBounded,X=>{y.emit("setBounded",X)}),e.watch(()=>n.transformScale,X=>{y.emit("setTransformScale",X)}),e.watch(()=>n.responsive,X=>{X||(i("update:layout",o.originalLayout),y.emit("setColNum",n.colNum)),E()}),e.watch(()=>n.maxRows,X=>{y.emit("setMaxRows",X)}),e.watch([()=>n.margin,()=>n.margin[1]],O),e.provide(tu,e.reactive({...e.toRefs(n),...e.toRefs(o),increaseItem:w,decreaseItem:q})),e.provide(su,y),l({state:o,getItem:A,resizeEvent:S,dragEvent:b,layoutUpdate:j});function w(X){p.set(X.i,X)}function q(X){p.delete(X.i)}function A(X){return p.get(X)}function j(){if(!Bn(c.value)&&!Bn(o.originalLayout)){if(c.value.length!==o.originalLayout.length){const X=re(c.value,o.originalLayout);if(X.length>0)if(c.value.length>o.originalLayout.length)o.originalLayout=o.originalLayout.concat(X);else{const me=new Set(X.map(ue=>ue.i));o.originalLayout=o.originalLayout.filter(ue=>!me.has(ue.i))}o.lastLayoutLength=c.value.length,R()}zi(c.value,n.verticalCompact),y.emit("updateWidth",o.width),O(),i("layout-updated",c.value)}}function O(){o.mergedStyle={height:_()}}function E(){u.value&&(o.width=u.value.offsetWidth),y.emit("resizeEvent")}function _(){if(!n.autoSize)return;const X=parseFloat(n.margin[1]);return jv(c.value)*(n.rowHeight+X)+X+"px"}let x;function b(X,me,ue,U,W,Z){let ae=Ps(c.value,me);Bn(ae)&&(ae={h:0,w:0,x:0,y:0,i:""}),X==="dragstart"&&!n.verticalCompact&&(x=c.value.reduce((ve,{i:ze,x:te,y:N})=>({...ve,[ze]:{x:te,y:N}}),{})),X==="dragmove"||X==="dragstart"?(o.placeholder.i=me,o.placeholder.x=ae.x,o.placeholder.y=ae.y,o.placeholder.w=Z,o.placeholder.h=W,e.nextTick(()=>{o.isDragging=!0}),y.emit("updateWidth",o.width)):e.nextTick(()=>{o.isDragging=!1}),c.value=Lt(c.value,ae,ue,U,!0,n.preventCollision),n.restoreOnDrag?(ae.static=!0,zi(c.value,n.verticalCompact,x),ae.static=!1):zi(c.value,n.verticalCompact),y.emit("compact"),O(),X==="dragend"&&(x=void 0,i("layout-updated",c.value))}function S(X,me,ue,U,W,Z){let ae=Ps(c.value,me);Bn(ae)&&(ae={h:0,w:0,x:0,y:0,i:""});let ve;if(n.preventCollision){const ze=uu(c.value,{...ae,w:Z,h:W}).filter(te=>te.i!==ae.i);if(ve=ze.length>0,ve){let te=1/0,N=1/0;ze.forEach(se=>{se.x>ae.x&&(te=Math.min(te,se.x)),se.y>ae.y&&(N=Math.min(N,se.y))}),Number.isFinite(te)&&(ae.w=te-ae.x),Number.isFinite(N)&&(ae.h=N-ae.y)}}ve||(ae.w=Z,ae.h=W),X==="resizestart"||X==="resizemove"?(o.placeholder.i=me,o.placeholder.x=ue,o.placeholder.y=U,o.placeholder.w=ae.w,o.placeholder.h=ae.h,e.nextTick(()=>{o.isDragging=!0}),y.emit("updateWidth",o.width)):X&&e.nextTick(()=>{o.isDragging=!1}),n.responsive&&I(),zi(c.value,n.verticalCompact),y.emit("compact"),O(),X==="resizeend"&&i("layout-updated",c.value)}function I(){const X=e1(n.breakpoints,o.width);if(X===o.lastBreakpoint)return;const me=fu(X,n.cols);!Bn(o.lastBreakpoint)&&!o.layouts[o.lastBreakpoint]&&(o.layouts[o.lastBreakpoint]=Ot(c.value));const ue=a1(o.originalLayout,o.layouts,n.breakpoints,X,o.lastBreakpoint,me,n.verticalCompact);o.layouts[X]=ue,o.lastBreakpoint!==X&&i("breakpoint-changed",X,ue),c.value=ue,i("update:layout",ue),o.lastBreakpoint=X,y.emit("setColNum",me)}function R(){o.layouts=Object.assign({},n.responsiveLayouts)}function re(X,me){const ue=new Set(me.map(ae=>ae.i)),U=new Set(X.map(ae=>ae.i)),W=X.filter(ae=>!ue.has(ae.i)),Z=me.filter(ae=>!U.has(ae.i));return W.concat(Z)}return(X,me)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"wrapper",ref:u,class:"vgl-layout",style:e.normalizeStyle(o.mergedStyle)},[X.$slots.default?e.renderSlot(X.$slots,"default",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(c.value,ue=>(e.openBlock(),e.createBlock(Ro,e.mergeProps({key:ue.i,ref_for:!0},ue),{default:e.withCtx(()=>[e.renderSlot(X.$slots,"item",{item:ue})]),_:2},1040))),128)),e.withDirectives(e.createVNode(Ro,{class:"vgl-item--placeholder",x:o.placeholder.x,y:o.placeholder.y,w:o.placeholder.w,h:o.placeholder.h,i:o.placeholder.i},null,8,["x","y","w","h","i"]),[[e.vShow,o.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 j1={key:0,class:"item-view-group"},H1={key:0,class:"item-view-group"},U1=e.defineComponent({__name:"index",props:{children:{type:Object,default:()=>{}},level:{type:Number,default:1}},emits:["rowClick","routeUrl","radioChange"],setup(a,{emit:l}){const r=M.useModelComp(M.pinia),{isEdit:n}=M.storeToRefs(r),i=ti(M.pinia),o=l,p=a,c=e.ref(""),u=e.computed(()=>p==null?void 0:p.children),m=e.computed(()=>{var O,E,_,x;return((O=p==null?void 0:p.children)==null?void 0:O.length)>0&&((E=p==null?void 0:p.children)!=null&&E.every(b=>b==null?void 0:b.layout))?(x=(_=p==null?void 0:p.children)==null?void 0:_[0])==null?void 0:x.layout:"vertical"}),g=O=>{c.value=O,o("radioChange",O)},y=e.computed(()=>{var O,E;return((E=(O=p==null?void 0:p.children)==null?void 0:O[0])==null?void 0:E.isGridLayout)||!1}),d=e.ref((p==null?void 0:p.level)+1),D=e.computed(()=>{if(!(p!=null&&p.children)||!Array.isArray(p.children)||p.children.length<2)return!1;const O=p.children.some(_=>(_==null?void 0:_.name)==="测量系统配置表"&&(_==null?void 0:_.comp)==="ParentItem"),E=p.children.some(_=>(_==null?void 0:_.name)==="测量系统传递表"&&(_==null?void 0:_.comp)==="ParentItem");return O&&E}),w=e.computed(()=>{var E,_,x,b,S,I;let O=(E=p==null?void 0:p.children)==null?void 0:E.filter(R=>R==null?void 0:R.choice);if(i.setSelectTab((_=O==null?void 0:O[0])==null?void 0:_.choiceName),(c==null?void 0:c.value)!=="")return(x=p==null?void 0:p.children)==null?void 0:x.filter(R=>!(R!=null&&R.choiceName)||(R==null?void 0:R.choiceName)===(c==null?void 0:c.value));{let R=(S=(b=p==null?void 0:p.children)==null?void 0:b.find(re=>re==null?void 0:re.choice))==null?void 0:S.choiceName;return(I=p==null?void 0:p.children)==null?void 0:I.filter(re=>!(re!=null&&re.choiceName)||(re==null?void 0:re.choiceName)===R)}}),q=O=>{const E=(O==null?void 0:O.menuFilter)||[];return Array.isArray(E)&&(E==null?void 0:E.some(_=>{const x=typeof _=="string"?_:JSON.stringify(_);return x==null?void 0:x.includes("HideGroup=Yes")}))};e.watch(()=>p==null?void 0:p.children,()=>{D.value},{deep:!0});const A=O=>{o("rowClick",O)},j=(O,E)=>{o("routeUrl",O,E)};return(O,E)=>y.value?(e.openBlock(),e.createBlock(e.unref(_u),{key:0,layout:u.value,"onUpdate:layout":E[0]||(E[0]=_=>u.value=_),"is-draggable":e.unref(n)==="edit","is-resizable":e.unref(n)==="edit","col-num":24,margin:[8,16]},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(_,x)=>(e.openBlock(),e.createBlock(e.unref(Ro),{key:_.i,x:_.x,y:_.y,"min-h":_.minH,"max-h":_.maxH,"min-w":_.minW,w:_.w,h:_.h,i:_.i},{default:e.withCtx(()=>{var b,S,I,R,re,X,me,ue,U,W,Z,ae,ve,ze;return[e.createElementVNode("div",{style:e.normalizeStyle({gap:"16px",display:"flex",flexDirection:"column",paddingBottom:x===((b=p==null?void 0:p.children)==null?void 0:b.length)-1?"0px":"24px"})},[((I=(S=_==null?void 0:_.component)==null?void 0:S.comp)==null?void 0:I.toUpperCase())!=="TABLE"&&((R=_==null?void 0:_.component)!=null&&R.name)?(e.openBlock(),e.createElementBlock("div",j1,[e.createElementVNode("div",{class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:(parseInt(d.value.toString())-1)*12+"px",fontWeight:600-(d.value-1)*100>=400?600-(d.value-1)*100:400,fontSize:17-d.value>=14?17-d.value+"px":"14px"})},e.toDisplayString((re=_==null?void 0:_.component)==null?void 0:re.name),5)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)((X=_==null?void 0:_.component)==null?void 0:X.comp)),{pageLayout:m.value,config:{showIndex:(me=e.unref(kr)[x])==null?void 0:me.showIndex,allowMove:(ue=e.unref(kr)[x])==null?void 0:ue.allowMove,viewport:(U=e.unref(kr)[x])==null?void 0:U.viewport,status:(W=e.unref(kr)[x])==null?void 0:W.status},related:_==null?void 0:_.relatedTables,compName:_==null?void 0:_.component.name,compNames:e.unref($c),itemData:(Z=_==null?void 0:_.component)==null?void 0:Z.compData,childItemData:(ae=_==null?void 0:_.component)==null?void 0:ae.itemChildData,key:e.unref(oi),cacheNewData:e.unref(Rc),onChange:e.unref(Mo),index:(_==null?void 0:_.id)??x,onContentChange:e.unref(Io),onPageChange:e.unref(Oo),parentTableId:(ve=_==null?void 0:_.component)==null?void 0:ve.tableId,allMapContents:e.unref(zt),children:(ze=_==null?void 0:_.component)==null?void 0:ze.children,level:d.value,onRowClick:A,onRouteUrl:j,onClickTrigger:e.unref(Vc),onClickMainKey:e.unref(Fc),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(w.value,(_,x)=>{var b,S;return e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({gap:"16px",display:(_==null?void 0:_.isShow)===!1?"none":"flex",flexDirection:"column",paddingBottom:parseInt(x)===((b=p==null?void 0:p.children)==null?void 0:b.length)-1?"0px":"24px"})},[((S=_==null?void 0:_.comp)==null?void 0:S.toUpperCase())!=="TABLE"&&_.name?(e.openBlock(),e.createElementBlock("div",H1,[q(_)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:parseInt(d.value.toString())>1?"12px":"0px",fontWeight:600-(d.value-1)*100>=400?600-(d.value-1)*100:400,fontSize:17-d.value>=14?17-d.value+"px":"14px"})},e.toDisplayString(_.name),5))])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(eo)(_.comp)),{compName:_.name,groupNames:_==null?void 0:_.nameContents,config:{showIndex:_==null?void 0:_.showIndex,allowMove:_==null?void 0:_.allowMove,viewport:_==null?void 0:_.viewport,status:_==null?void 0:_.status},itemData:_==null?void 0:_.compData,related:_==null?void 0:_.relatedTables,childItemData:_==null?void 0:_.itemChildData,key:e.unref(oi),onChange:e.unref(Mo),index:(_==null?void 0:_.id)??x,onContentChange:e.unref(Io),onPageChange:e.unref(Oo),parentTableId:_==null?void 0:_.tableId,allMapContents:e.unref(zt),children:_==null?void 0:_.children,level:d.value,onRowClick:A,onRouteUrl:j,onRadioChange:g},null,40,["compName","groupNames","config","itemData","related","childItemData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level"]))],4)}),256))}}),q1=pr._export_sfc(U1,[["__scopeId","data-v-bafbdd45"]]),W1={class:"radio-group-container"},G1=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},emits:["radioChange"],setup(a,{emit:l}){const r=a,n=l,i=e.ref(),o=ti(M.pinia),{selectTab:p}=M.storeToRefs(o);e.watch(()=>r==null?void 0:r.itemData,()=>{i.value=p.value},{immediate:!0,deep:!0});const c=u=>{i.value=u,n("radioChange",i.value)};return(u,m)=>(e.openBlock(),e.createElementBlock("div",W1,[e.createVNode(pl.ssRadio,{modelValue:i.value,"onUpdate:modelValue":m[0]||(m[0]=g=>i.value=g),content:r==null?void 0:r.itemData,onChange:c},null,8,["modelValue","content"])]))}}),K1=pr._export_sfc(G1,[["__scopeId","data-v-177d64c3"]]),Y1=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(a){const l=a,r=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,()=>{var n,i;r.value=((i=(n=l==null?void 0:l.itemData)==null?void 0:n.find(o=>(o==null?void 0:o.key)==="backGround"))==null?void 0:i.contents)??[]},{deep:!0,immediate:!0}),(n,i)=>(e.openBlock(),e.createElementBlock("div",null,[e.createVNode(pl.ssCarousel,{carouselList:r.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"}]),J1={TABLE:Yc,FORM:Rs,STATICFORM:Jc,TABLEOPERATE:$6,TABLESTYLE:l4,TABLEEXTEND:n4,TABLEINTERACTION:t4,FORMOPERATE:$s,FOLD:R4,CALCULATOR:H4,METHODBUTTON:W4,AVATARUPLOAD:vs.ssAvatar,SIGNATURE:vs.ssSignature,FORMTOP:Rs,STEP:n2,STEPOPERATE:T4,TIMELINE:u2,TIMELINEOPERATE:I4,FORMTOPOPERATE:$s,SIGNATUREOPERATE:a2,AVATARUPLOADOPERATE:Y4,TABS:f2,TABSOPERATE:Z2,CHART:fv,CHARTOPERATE:Sv,LAYOUT:Dv,LAYOUTOPERATE:Lv,PARENTITEM:q1,RADIO:K1,CAROUSEL:Y1};function $i(a){return J1[a==null?void 0:a.toUpperCase()]||null}exports.De=_u;exports.activeStepInfo=Mi;exports.addContents=Qi;exports.addVisibleDialog=Ft;exports.affixItems=d3;exports.allMapContents=zt;exports.analyzeMenu=mc;exports.cacheNewData=Rc;exports.clickMainKey=Fc;exports.clickSavePage=u3;exports.clickStep=jc;exports.clickTrigger=Vc;exports.compId=oi;exports.compNames=$c;exports.compShow=Ri;exports.existLayouts=b3;exports.fixChangeValue=Vo;exports.generateLayouts=Y6;exports.getComponent=$i;exports.getComponents=eo;exports.getPageConstruct=yp;exports.getPageData=Hr;exports.getSliceContLength=E3;exports.gridRowHeight=H6;exports.gridRowHeightHmPg=au;exports.isStepLayout=Hc;exports.newGenerateLayouts=Z6;exports.onBack=s3;exports.onButtonChange=v3;exports.onChange=Mo;exports.onClick=c3;exports.onClickStep=k3;exports.onContentChange=Io;exports.onExtendTaskEnd=g3;exports.onOk=m3;exports.onPageBack=w3;exports.onPageChange=Oo;exports.onSelectFixContent=t3;exports.renderShowItems=Oc;exports.showItems=kr;exports.sliceTableLength=Lc;exports.slotContent=Su;exports.ssTable=Yc;exports.st=Ro;exports.stepItems=C3;exports.tabChange=x3;exports.toolBar=y3;exports.useFormComp=Vt;exports.useModelLoader=i0;exports.verifyButton=_3;
|