ss-component-new 1.3.375 → 1.3.376
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-D27NF3pp.cjs → array-8GGgzdnS.cjs} +1 -1
- package/dist/{array-IjIVyDHo.js → array-DeOnJlHi.js} +2 -2
- package/dist/{index-CGQC9zyu.js → index-B-qQteLP.js} +1 -1
- package/dist/{index-CvGOYyuH.cjs → index-BAe3isZR.cjs} +11 -11
- package/dist/{index-XmNGo-iR.js → index-BK9z2B5J.js} +2 -2
- package/dist/{index-Dx_pho24.js → index-BNyt0unS.js} +1 -1
- package/dist/index-BbnA8bo4.cjs +25 -0
- package/dist/{index-B2w-XGOf.js → index-BgnY2HQS.js} +3 -3
- package/dist/{index-DqSfeHGy.cjs → index-BmBa1mXA.cjs} +1 -1
- package/dist/{index-CN4sqxdy.cjs → index-C7M9N7VA.cjs} +1 -1
- package/dist/{index-BNSAlueW.cjs → index-CRoVplYk.cjs} +1 -1
- package/dist/{index-BG3oUrUB.js → index-C_IAwg5i.js} +1 -1
- package/dist/{index-DI13pscK.js → index-Cdr57BAU.js} +1 -1
- package/dist/{index-DYg8DrRu.cjs → index-Civfbits.cjs} +1 -1
- package/dist/{index-DA0vFQt4.cjs → index-CqlxzDOk.cjs} +1 -1
- package/dist/{index-DCXeSeLv.js → index-CvkNw_yG.js} +1 -1
- package/dist/{index-BCXaKENg.cjs → index-D-8UUsIw.cjs} +1 -1
- package/dist/{index-BPrOutlR.cjs → index-DAvmt51L.cjs} +1 -1
- package/dist/{index-GRJYnDSN.cjs → index-DNoXEza9.cjs} +1 -1
- package/dist/{index-DnXsY9Gu.js → index-DlQBgL32.js} +8732 -8771
- package/dist/{index-oRyFBxcU.js → index-DpPev0ws.js} +2 -2
- package/dist/{index--fAYZJ6I.js → index-RZB3eyY8.js} +7 -7
- package/dist/{index-C6jJYRcO.js → index-Ra2U0AAX.js} +5 -6
- package/dist/{index-BXkzOm8Q.js → index-SZIh82dr.js} +2 -2
- package/dist/{index-C23ZywJn.cjs → index-gWbr_HUn.cjs} +1 -1
- package/dist/{index-1_OTXKo2.cjs → index-xWkV8hYb.cjs} +1 -1
- package/dist/{main-Bk6ACrZv.cjs → main-B6RX1uXf.cjs} +1 -1
- package/dist/{main-DLLuXJ6-.js → main-dx5OziKj.js} +2 -2
- 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-CYNZ6zGK.cjs → threeModel-BUnfaQhc.cjs} +1 -1
- package/dist/{threeModel-xKn7sWo2.js → threeModel-CFToapt5.js} +1 -1
- package/dist/{threeSceneView-fCtbtOTa.js → threeSceneView-BzVhxD-1.js} +3 -3
- package/dist/{threeSceneView-Bup-nNvS.cjs → threeSceneView-gDCjqPXY.cjs} +1 -1
- package/dist/{threeSceneViewForCPMPIP-B75ptfRy.js → threeSceneViewForCPMPIP-CcbTqsbc.js} +1 -1
- package/dist/{threeSceneViewForCPMPIP-Cr2oI8fR.cjs → threeSceneViewForCPMPIP-Ds-GipqZ.cjs} +1 -1
- package/dist/{threeViewerHost-BAQs_Gc1.cjs → threeViewerHost-DnDhfl9l.cjs} +1 -1
- package/dist/{threeViewerHost-BEDKEUxi.js → threeViewerHost-gRi2EJ1m.js} +1 -1
- package/package.json +1 -1
- package/dist/index-DUsoX9j3.cjs +0 -25
package/dist/index-DUsoX9j3.cjs
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
"use strict";var Au=Object.defineProperty;var zu=(a,l,r)=>l in a?Au(a,l,{enumerable:!0,configurable:!0,writable:!0,value:r}):a[l]=r;var Wr=(a,l,r)=>zu(a,typeof l!="symbol"?l+"":l,r);const e=require("vue"),qa=require("./request-BC2w2vGr.cjs"),A=require("./index-BEli6-9O.cjs"),ll=require("./index-CvGOYyuH.cjs"),he=require("./index-BrBW7tRO.cjs"),Zl=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Bl=require("./index.vue_vue_type_style_index_0_scoped_6b92e250_lang-eirpGIM9.cjs"),wr=require("./index-gnhHdovX.cjs"),So=require("./threeViewerHost-BAQs_Gc1.cjs"),Tr=require("./index-CW4qJdP8.cjs"),as=require("./index-C23ZywJn.cjs"),Ys=require("./index-Ff9cJTW6.cjs");;/* empty css */const Eo=require("./isString-DNBlKLZH.cjs"),ls=require("./index.vue_vue_type_script_setup_true_lang-BKTJR2th.cjs"),Js=require("./index-BVaHwt5f.cjs"),Mu=require("./index-Bslyl2ID.cjs"),zn=require("./MTLLoader-HQ9_HPVv.cjs"),Iu=require("./URDFLoader-DEhmYKKG.cjs");var Ou="[object Boolean]";function Xs(a){return a===!0||a===!1||qa.isObjectLike(a)&&qa.baseGetTag(a)==Ou}function Lu(a){return a===void 0}const Ru=a=>a.match(/\((.*)\)/)[1],$u={__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),t=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(()=>t.value,()=>{e.nextTick(()=>{var s,v;(v=(s=r.value)==null?void 0:s.updatePopper)==null||v.call(s)})},{deep:!0,immediate:!0}),(s,v)=>{const d=e.resolveComponent("el-popover");return e.openBlock(),e.createBlock(d,{visible:n.value,"onUpdate:visible":v[0]||(v[0]=p=>n.value=p),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(s.$slots,"reference",{ref_key:"referenceRef",ref:t})])]),default:e.withCtx(()=>[e.createElementVNode("div",null,[e.renderSlot(s.$slots,"content")])]),_:3},8,["visible","trigger","title","placement","width"])}}},Vu=e.defineComponent({__name:"index",props:{value:{type:[String,Number],default:""},columnContent:{type:Object,default:{}}},setup(a){const l=a,r=e.computed(()=>{var p,y,g,c,D;const n=l.value??"";let t=(p=l==null?void 0:l.columnContent)==null?void 0:p.filter;(t==null?void 0:t[0])==="("&&(t=t==null?void 0:t.slice(1,(t==null?void 0:t.length)-1)),t=t==null?void 0:t.split("||");let s=(g=(y=l==null?void 0:l.columnContent)==null?void 0:y.options)==null?void 0:g.findIndex(M=>(M==null?void 0:M.value)===n);s=t==null?void 0:t[s],s=he.analyzeSplitToContent(s,","),s=s==null?void 0:s.map(M=>((M==null?void 0:M[(M==null?void 0:M.length)-1])===","&&(M=M==null?void 0:M.slice(0,(M==null?void 0:M.length)-1)),M));let v=s==null?void 0:s.find(M=>M==null?void 0:M.includes("@TextBackRGBA"));v?v=he.rgbaToColor((c=v==null?void 0:v.split("="))==null?void 0:c[1]):v=void 0;let d=s==null?void 0:s.find(M=>M==null?void 0:M.includes("@TextRGBA"));return d?d=he.rgbaToColor((D=d==null?void 0:d.split("="))==null?void 0:D[1]):d=void 0,{backgroundColor:v,color:d}});return(n,t)=>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)}}),Fu=Zl._export_sfc(Vu,[["__scopeId","data-v-96eae9de"]]);function Pu(a,l,r,n={}){if(!a||!l||!r||r.length!==4)return;const t=a.getContext("2d");if(!t)return;const{color:s="rgba(255, 235, 59, 0.3)",strokeWidth:v=2,fillOpacity:d=.2}=n,p=a.getBoundingClientRect(),y=l.getBoundingClientRect(),g=l.naturalWidth,c=l.naturalHeight,D=y.width/g,M=y.height/c,S=Math.min(D,M),K=g*S,I=c*S,R=(p.width-K)/2,j=(p.height-I)/2,E=r.map(([k,b])=>{const w=R+k*K,$=j+b*I;return{x:w,y:$}});t.clearRect(0,0,a.width,a.height),t.beginPath(),t.moveTo(E[0].x,E[0].y);for(let k=1;k<E.length;k++)t.lineTo(E[k].x,E[k].y);t.closePath();const x=s.replace(/[\d.]+\)$/,`${d})`);t.fillStyle=x,t.fill(),t.strokeStyle=s.replace(/[\d.]+\)$/,"1)"),t.lineWidth=v,t.stroke()}function ki(a){if(!a)return;const l=a.getContext("2d");l&&l.clearRect(0,0,a.width,a.height)}function rs(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 ju={key:0,class:"ocr-img-preview-root"},Hu={class:"ocr-img-preview-window"},Uu={key:0,class:"img-preview-body"},qu={class:"img-preview-header"},Wu={class:"img-header-left"},Ku={class:"img-name"},Gu={key:0,class:"img-header-right"},Yu={class:"img-index"},Ju={key:0,class:"img-thumb-list"},Xu=["onClick"],Zu={key:1,class:"thumb-placeholder"},Qu={class:"thumb-name"},ed={class:"img-preview-container"},ad={key:0,class:"img-placeholder"},ld={key:2,class:"img-placeholder"},rd={key:0},nd={key:1},id={key:1,class:"img-placeholder"},od=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,t=e.computed({get:()=>r.visible,set:T=>n("update:visible",T)});let s=!1,v="",d=0,p=0,y=0,g=0,c=0,D=0,M=null;const S=T=>{var U,Se;const ue=(Se=(U=T==null?void 0:T.target)==null?void 0:U.closest)==null?void 0:Se.call(U,".ocr-img-preview-window");return ue||document.querySelector(".ocr-img-preview-window")},K=T=>{if(!T||T==="none")return{tx:0,ty:0};let ue=T.match(/matrix\(([^)]+)\)/);if(ue){const U=ue[1].split(",").map(Se=>Number(Se.trim()));return{tx:(U==null?void 0:U[4])||0,ty:(U==null?void 0:U[5])||0}}if(ue=T.match(/matrix3d\(([^)]+)\)/),ue){const U=ue[1].split(",").map(Se=>Number(Se.trim()));return{tx:(U==null?void 0:U[12])||0,ty:(U==null?void 0:U[13])||0}}return ue=T.match(/translate\(\s*([-\d.]+)px\s*,\s*([-\d.]+)px\s*\)/),ue?{tx:Number(ue[1])||0,ty:Number(ue[2])||0}:{tx:0,ty:0}},I=(T,ue,U)=>{T.style.transform=`translate(${ue}px, ${U}px)`},R=T=>{const ue=S(T);if(!ue)return;s=!0,M=ue,v="move",d=T.clientX,p=T.clientY;const U=window.getComputedStyle(ue),{tx:Se,ty:Le}=K(U.transform);c=Se,D=Le,document.addEventListener("mousemove",E),document.addEventListener("mouseup",x)},j=(T,ue)=>{const U=S(T);if(!U)return;s=!0,M=U,v=ue,d=T.clientX,p=T.clientY;const Se=U.getBoundingClientRect();y=Se.width,g=Se.height;const Le=window.getComputedStyle(U),{tx:Pe,ty:la}=K(Le.transform);c=Pe,D=la,document.addEventListener("mousemove",E),document.addEventListener("mouseup",x)},E=T=>{if(!s||!M)return;const ue=T.clientX-d,U=T.clientY-p,Se=360,Le=420;let Pe=y,la=g,Da=c,le=D;if(v==="move"){Da=c+ue,le=D+U,I(M,Da,le);return}if(v.includes("right")&&(Pe=Math.max(Se,y+ue)),v.includes("bottom")&&(la=Math.max(Le,g+U)),v.includes("left")){const ta=y-ue;ta<Se?(Pe=Se,Da=c+(y-Se)):(Pe=ta,Da=c+ue)}if(v.includes("top")){const ta=g-U;ta<Le?(la=Le,le=D+(g-Le)):(la=ta,le=D+U)}M.style.width=`${Pe}px`,M.style.height=`${la}px`,I(M,Da,le)},x=()=>{s=!1,v="",M=null,document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",x)},k=e.ref([]),b=e.ref(!1);e.watch(()=>r.images,async T=>{if(!Array.isArray(T)||T.length===0){k.value=[];return}b.value=!0;const ue=[];for(const U of T)if(U.url&&!U.url.startsWith("blob:")&&!U.url.startsWith("http"))try{const Se=await Bl.downloadFile(U.url),Le=URL.createObjectURL(Se);ue.push({...U,blobUrl:Le})}catch(Se){console.error(`Failed to load image for preview: ${U.url}`,Se),ue.push({...U,blobUrl:""})}else ue.push({...U,blobUrl:U.url});k.value=ue,b.value=!1},{deep:!0,immediate:!0});const w=e.ref(0),$=e.ref(null),F=e.ref(null),J=e.computed(()=>k.value[w.value]||null),se=()=>{if(!k.value.length){w.value=0;return}if(r.defaultImageName){const T=k.value.findIndex(ue=>(ue==null?void 0:ue.name)===r.defaultImageName);w.value=T>=0?T:0}else w.value=0},ge=T=>{if(!k.value.length)return;const ue=Math.max(0,Math.min(T,k.value.length-1));w.value=ue},Me=()=>ge(w.value-1),V=()=>ge(w.value+1),fe=T=>{if(!T)return;const ue=k.value.findIndex(U=>(U==null?void 0:U.name)===T);ue>=0&&(w.value=ue)},ae=()=>{if(!F.value)return;const T=F.value.parentElement;if(!T)return;const ue=T.getBoundingClientRect();F.value.width=ue.width,F.value.height=ue.height},de=()=>{var Se,Le;if(!F.value||!$.value||!r.focusedFieldName){F.value&&ki(F.value);return}const T=(Se=$.value.$el)==null?void 0:Se.querySelector("img");if(!T)return;if(!T.complete||T.naturalWidth===0){T.onload=()=>{e.nextTick(()=>{de()})};return}const ue=((Le=J.value)==null?void 0:Le.name)||"",U=rs(r.fieldMeta,r.focusedFieldName);if(!U){ki(F.value);return}if(U.imageName!==ue){ki(F.value);return}ae(),Pu(F.value,T,U.bboxNorm)},De=()=>{e.nextTick(()=>{ae(),de()})};e.watch(()=>r.focusedFieldName,()=>{if(!t.value)return;const T=rs(r.fieldMeta,r.focusedFieldName);T!=null&&T.imageName&&fe(T.imageName),e.nextTick(()=>{de()})}),e.watch(()=>{var T;return(T=J.value)==null?void 0:T.name},()=>{t.value&&e.nextTick(()=>{F.value&&ki(F.value),de()})}),e.watch(()=>r.visible,T=>{T?(se(),e.nextTick(()=>{ae(),de()})):F.value&&ki(F.value)}),e.watch(()=>r.defaultImageName,()=>{t.value&&se()});let Fe=null;e.onMounted(()=>{var T;typeof ResizeObserver<"u"&&(Fe=new ResizeObserver(()=>{ae(),e.nextTick(()=>{de()})}),(T=F.value)!=null&&T.parentElement&&Fe.observe(F.value.parentElement))}),e.onUnmounted(()=>{Fe&&(Fe.disconnect(),Fe=null),document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",x)});const ye=()=>{F.value&&ki(F.value),n("update:visible",!1),n("close")};return(T,ue)=>{var la,Da;const U=e.resolveComponent("el-button"),Se=e.resolveComponent("el-image"),Le=e.resolveComponent("Loading"),Pe=e.resolveComponent("el-icon");return t.value?(e.openBlock(),e.createElementBlock("div",ju,[ue[12]||(ue[12]=e.createElementVNode("div",{class:"ocr-img-preview-backdrop"},null,-1)),e.createElementVNode("div",Hu,[e.createElementVNode("div",{class:"ocr-img-preview-header",onMousedown:e.withModifiers(R,["stop"])},[ue[8]||(ue[8]=e.createElementVNode("span",{class:"ocr-img-preview-title"},"文件预览",-1)),e.createElementVNode("button",{type:"button",class:"ocr-img-preview-close",onClick:ye},"×")],32),e.createElementVNode("div",{class:"resizable-handle top",onMousedown:ue[0]||(ue[0]=e.withModifiers(le=>j(le,"top"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle right",onMousedown:ue[1]||(ue[1]=e.withModifiers(le=>j(le,"right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom",onMousedown:ue[2]||(ue[2]=e.withModifiers(le=>j(le,"bottom"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle left",onMousedown:ue[3]||(ue[3]=e.withModifiers(le=>j(le,"left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-left",onMousedown:ue[4]||(ue[4]=e.withModifiers(le=>j(le,"top-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle top-right",onMousedown:ue[5]||(ue[5]=e.withModifiers(le=>j(le,"top-right"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-left",onMousedown:ue[6]||(ue[6]=e.withModifiers(le=>j(le,"bottom-left"),["stop"]))},null,32),e.createElementVNode("div",{class:"resizable-handle bottom-right",onMousedown:ue[7]||(ue[7]=e.withModifiers(le=>j(le,"bottom-right"),["stop"]))},null,32),J.value?(e.openBlock(),e.createElementBlock("div",Uu,[e.createElementVNode("div",qu,[e.createElementVNode("div",Wu,[e.createElementVNode("span",Ku,e.toDisplayString(J.value.name?J.value.name+(J.value.url&&J.value.url.lastIndexOf(".")!==-1?J.value.url.substring(J.value.url.lastIndexOf(".")):""):""),1)]),k.value.length>1?(e.openBlock(),e.createElementBlock("div",Gu,[e.createVNode(U,{size:"small",disabled:w.value===0,onClick:Me},{default:e.withCtx(()=>ue[9]||(ue[9]=[e.createTextVNode("上一张")])),_:1,__:[9]},8,["disabled"]),e.createElementVNode("span",Yu,e.toDisplayString(w.value+1)+" / "+e.toDisplayString(k.value.length),1),e.createVNode(U,{size:"small",disabled:w.value===k.value.length-1,onClick:V},{default:e.withCtx(()=>ue[10]||(ue[10]=[e.createTextVNode("下一张")])),_:1,__:[10]},8,["disabled"])])):e.createCommentVNode("",!0)]),k.value.length>1?(e.openBlock(),e.createElementBlock("div",Ju,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,(le,ta)=>(e.openBlock(),e.createElementBlock("div",{key:(le.name||"")+"-"+ta,class:e.normalizeClass(["img-thumb-item",{active:ta===w.value}]),onClick:te=>ge(ta)},[le!=null&&le.blobUrl?(e.openBlock(),e.createBlock(Se,{key:0,src:le.blobUrl,fit:"cover",class:"thumb-image","preview-src-list":[le.blobUrl],"initial-index":0},null,8,["src","preview-src-list"])):(e.openBlock(),e.createElementBlock("div",Zu,"加载失败")),e.createElementVNode("div",Qu,e.toDisplayString(le.name||"-"),1)],10,Xu))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",ed,[b.value?(e.openBlock(),e.createElementBlock("div",ad,[e.createVNode(Pe,{class:"is-loading"},{default:e.withCtx(()=>[e.createVNode(Le)]),_:1}),ue[11]||(ue[11]=e.createElementVNode("span",null,"图片加载中...",-1))])):(la=J.value)!=null&&la.blobUrl?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(Se,{ref_key:"imageRef",ref:$,src:J.value.blobUrl,fit:"contain",class:"preview-image","preview-src-list":[J.value.blobUrl],onLoad:De},null,8,["src","preview-src-list"]),e.createElementVNode("canvas",{ref_key:"canvasRef",ref:F,class:"highlight-canvas"},null,512)],64)):(e.openBlock(),e.createElementBlock("div",ld,[(Da=J.value)!=null&&Da.url?(e.openBlock(),e.createElementBlock("span",rd,"图片加载失败")):(e.openBlock(),e.createElementBlock("span",nd,"暂无图片"))]))])])):(e.openBlock(),e.createElementBlock("div",id,"暂无图片"))])])):e.createCommentVNode("",!0)}}}),td=Zl._export_sfc(od,[["__scopeId","data-v-48a4ecb1"]]),sd={class:"cert-preview-body"},cd={key:0,class:"pdf-preview-container"},ud={class:"thumbs"},dd=["onClick"],pd={class:"thumb-img"},fd=["src"],hd={key:1,class:"thumb-loading"},vd={class:"thumb-title"},md={class:"viewer"},yd={key:0,class:"viewer-img-wrap"},gd=["src"],bd={key:1,class:"viewer-loading"},kd=e.defineComponent({__name:"CertificatePreview",props:{visible:{type:Boolean},versions:{}},emits:["update:visible"],setup(a,{emit:l}){const r=a,n=l,t=e.ref(""),s=e.ref(""),v=e.computed(()=>(r.versions||[]).find(S=>String(S.versionId)===String(t.value))),d=e.ref({}),p=e.ref(""),y=e.ref("证书附件.pdf"),g=()=>{try{Object.values(d.value||{}).forEach(S=>{S&&URL.revokeObjectURL(S)}),p.value&&URL.revokeObjectURL(p.value)}catch{}d.value={},p.value=""},c=async S=>{if(!S||S.fileType==="pdf")return;const K=Array.isArray(S.images)?S.images:[];for(const I of K){const R=I==null?void 0:I.url;if(!(!R||d.value[R]))try{const j=await A.platformDownloadFile({url:R}),E=URL.createObjectURL(j.data);d.value={...d.value,[R]:E}}catch{}}},D=async S=>{var I;if(!S||S.fileType!=="pdf"){p.value="";return}const K=S.sourceUrl||"";if(!K){p.value="";return}if(p.value){try{URL.revokeObjectURL(p.value)}catch{}p.value=""}try{console.log("[CertificatePreview] 下载PDF附件:",{url:K,versionId:S==null?void 0:S.versionId,certNo:S==null?void 0:S.certNo});const R=await A.platformDownloadFile({url:K});console.log("[CertificatePreview] PDF响应:",{url:K,status:R==null?void 0:R.status,size:(I=R==null?void 0:R.data)==null?void 0:I.size});const j=URL.createObjectURL(R.data);p.value=j;const E=S.certNo?String(S.certNo):"";y.value=E?`${E}.pdf`:"证书附件.pdf"}catch(R){console.error("[CertificatePreview] PDF加载失败:",{url:K,error:R}),p.value=""}};e.watch(()=>r.visible,async S=>{var I;if(!S){g();return}const K=(I=r.versions)==null?void 0:I[0];t.value=(K==null?void 0:K.versionId)||"",await c(K),await D(K)},{immediate:!0}),e.watch(()=>t.value,async()=>{var K,I;const S=v.value;if(!S){s.value="",p.value="";return}if(S.fileType==="pdf"){s.value="",await D(S);return}p.value="",s.value=((I=(K=S.images)==null?void 0:K[0])==null?void 0:I.url)||"",await c(S)},{immediate:!0});const M=()=>{n("update:visible",!1),g()};return e.onBeforeUnmount(()=>{g()}),(S,K)=>{const I=e.resolveComponent("el-empty"),R=e.resolveComponent("el-tab-pane"),j=e.resolveComponent("el-tabs"),E=e.resolveComponent("el-button"),x=e.resolveComponent("el-dialog");return e.openBlock(),e.createBlock(x,{"model-value":S.visible,title:"证书附件预览",width:"1100px","close-on-click-modal":!1,onClose:M},{footer:e.withCtx(()=>[e.createVNode(E,{id:"themeBorderButton",onClick:M},{default:e.withCtx(()=>K[1]||(K[1]=[e.createTextVNode("关闭")])),_:1,__:[1]})]),default:e.withCtx(()=>[S.versions&&S.versions.length>0?(e.openBlock(),e.createBlock(j,{key:0,modelValue:t.value,"onUpdate:modelValue":K[0]||(K[0]=k=>t.value=k),type:"card",class:"cert-version-tabs"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.versions,k=>(e.openBlock(),e.createBlock(R,{key:k.versionId,name:k.versionId,label:k.label},{default:e.withCtx(()=>[e.createElementVNode("div",sd,[k.fileType==="pdf"?(e.openBlock(),e.createElementBlock("div",cd,[p.value?(e.openBlock(),e.createBlock(ll.SsFilePreview,{key:1,fileName:y.value,blobUrl:p.value},null,8,["fileName","blobUrl"])):(e.openBlock(),e.createBlock(I,{key:0,description:"加载中"}))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",ud,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.images||[],b=>(e.openBlock(),e.createElementBlock("div",{key:b.url,class:e.normalizeClass(["thumb",{active:b.url===s.value}]),onClick:w=>s.value=b.url},[e.createElementVNode("div",pd,[d.value[b.url]?(e.openBlock(),e.createElementBlock("img",{key:0,src:d.value[b.url]},null,8,fd)):(e.openBlock(),e.createElementBlock("div",hd,"加载中"))]),e.createElementVNode("div",vd,e.toDisplayString(b.name),1)],10,dd))),128))]),e.createElementVNode("div",md,[s.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[d.value[s.value]?(e.openBlock(),e.createElementBlock("div",yd,[e.createElementVNode("img",{class:"viewer-img",src:d.value[s.value]},null,8,gd)])):(e.openBlock(),e.createElementBlock("div",bd,"加载中"))],64)):(e.openBlock(),e.createBlock(I,{key:0,description:"暂无图片"}))])],64))])]),_:2},1032,["name","label"]))),128))]),_:1},8,["modelValue"])):(e.openBlock(),e.createBlock(I,{key:1,description:"暂无可预览的证书附件"}))]),_:1},8,["model-value"])}}}),xd=Zl._export_sfc(kd,[["__scopeId","data-v-220703c0"]]),wd={class:"ocr-candidate-wrap"},_d={class:"ocr-candidate-left"},Sd={key:1},Ed={key:0},Cd={key:1},Dd={key:2},Bd={key:3},Nd={key:0,class:"ocr-candidate-right"},Td={class:"ocr-candidate-actions"},Ad={key:1},zd={class:"dialog-footer"},Md={__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=(w=[])=>{const $=[],F=J=>{(J||[]).forEach(se=>{if(!se)return;const ge=se.children||se.childrens||se.columns;Array.isArray(ge)&&ge.length>0?F(ge):$.push(se)})};return F(w),$},n=a,t=l,s=e.computed(()=>{var w;return((w=D.value)==null?void 0:w.allowAdd)!==!1}),v=e.computed(()=>{var w;return((w=D.value)==null?void 0:w.allowReplace)!==!1}),d=w=>{if(!w)return[];if(Array.isArray(w))return w;if(typeof w=="string")try{const $=JSON.parse(w);return Array.isArray($)?$:[]}catch{return[]}return[]},p=w=>{t("preview-file",w)},y=e.ref([]),g=e.ref(0),c=e.ref("");e.watch(()=>n.candidates,w=>{var $,F;y.value=(w||[]).map(J=>({...J,...(J==null?void 0:J.ocrRow)||{},selectedTargetId:(J==null?void 0:J.selectedTargetId)||"",__decision:J==null?void 0:J.__decision})),g.value=0,c.value=((F=($=y.value)==null?void 0:$[0])==null?void 0:F.selectedTargetId)||""},{immediate:!0,deep:!0}),e.watch(()=>n.visible,w=>{var $,F;w&&(g.value=0,c.value=((F=($=y.value)==null?void 0:$[0])==null?void 0:F.selectedTargetId)||"")});const D=e.computed(()=>{var $;const w=Number(g.value||0);return(($=y.value||[])==null?void 0:$[w])||null}),M=e.computed(()=>(r(n.columns||[])||[]).filter(F=>F&&F.prop).filter(F=>F.type!=="operate"&&F.label!=="操作"&&F.prop!=="operate")),S=e.computed(()=>M.value.filter(w=>w.label!=="证书附件"&&w.prop!=="证书附件")),K=w=>{if(!w)return;const $=(y.value||[]).findIndex(F=>(F==null?void 0:F.idx)===(w==null?void 0:w.idx));$>-1&&(g.value=$,c.value=(w==null?void 0:w.selectedTargetId)||"")},I=w=>{if(!w){c.value="";return}c.value=String((w==null?void 0:w.id)??"")},R=(w,$="")=>{const F=Number(g.value||0),J=y.value||[],se=J[F];se&&(se.__decision=w,se.selectedTargetId=$,c.value=$,y.value=[...J])},j=()=>R("skip",""),E=()=>R("add",""),x=()=>{if(!c.value){qa.ElMessage.warning("请先选择要替换的目标记录");return}R("replace",c.value)},k=()=>{t("update:visible",!1)},b=()=>{const w=y.value||[];if(w.find(F=>(F==null?void 0:F.__decision)==="replace"&&!(F!=null&&F.selectedTargetId))){qa.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}t("submit",w),t("update:visible",!1)};return(w,$)=>{const F=e.resolveComponent("el-table-column"),J=e.resolveComponent("svg-icon"),se=e.resolveComponent("el-table"),ge=e.resolveComponent("el-button"),Me=e.resolveComponent("el-alert");return e.openBlock(),e.createBlock(wr.ssDialog,{title:"OCR候选匹配",visible:a.visible,"close-on-click-modal":!1,width:"90%",style:{maxWidth:"1200px"},onBeforeDestroy:k},{default:e.withCtx(()=>{var V,fe;return[e.createElementVNode("div",wd,[e.createElementVNode("div",_d,[$[0]||($[0]=e.createElementVNode("div",{class:"ocr-candidate-title"},"待处理OCR行(可跳过)",-1)),e.createVNode(se,{data:y.value,border:"",stripe:"","max-height":"300",style:{width:"100%"},"highlight-current-row":"",onCurrentChange:K},{default:e.withCtx(()=>[e.createVNode(F,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,ae=>(e.openBlock(),e.createBlock(F,{key:ae.prop,label:ae.label,prop:ae.prop,"min-width":ae.minWidth||160},{default:e.withCtx(({row:de})=>[ae.label==="证书附件"||ae.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[d(de==null?void 0:de[ae.prop]).length>0?(e.openBlock(),e.createBlock(J,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(De=>p({row:de,prop:ae.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Sd,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((de==null?void 0:de[ae.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128)),e.createVNode(F,{label:"候选数",width:"90",fixed:"right"},{default:e.withCtx(({row:ae})=>[e.createTextVNode(e.toDisplayString(((ae==null?void 0:ae.candidates)||[]).length),1)]),_:1}),e.createVNode(F,{label:"处理状态",width:"120",fixed:"right"},{default:e.withCtx(({row:ae})=>[(ae==null?void 0:ae.__decision)==="replace"?(e.openBlock(),e.createElementBlock("span",Ed,"替换")):(ae==null?void 0:ae.__decision)==="add"?(e.openBlock(),e.createElementBlock("span",Cd,"新增")):(ae==null?void 0:ae.__decision)==="skip"?(e.openBlock(),e.createElementBlock("span",Dd,"跳过")):(e.openBlock(),e.createElementBlock("span",Bd,"未处理"))]),_:1})]),_:1},8,["data"])]),y.value&&y.value.length>0?(e.openBlock(),e.createElementBlock("div",Nd,[$[4]||($[4]=e.createElementVNode("div",{class:"ocr-candidate-title"},"当前行候选记录(同编号)",-1)),e.createElementVNode("div",Td,[e.createVNode(ge,{id:"themeBorderButton",onClick:j},{default:e.withCtx(()=>$[1]||($[1]=[e.createTextVNode("跳过本行")])),_:1,__:[1]}),e.createVNode(ge,{id:"themeBorderButton",onClick:E,disabled:!s.value},{default:e.withCtx(()=>$[2]||($[2]=[e.createTextVNode("新增本行")])),_:1,__:[2]},8,["disabled"]),e.createVNode(ge,{class:"ok-button",id:"themeButton",onClick:x,disabled:!v.value||!c.value},{default:e.withCtx(()=>$[3]||($[3]=[e.createTextVNode("替换选中记录")])),_:1,__:[3]},8,["disabled"])]),(((V=D.value)==null?void 0:V.candidates)||[]).length===0?(e.openBlock(),e.createBlock(Me,{key:0,title:"该编号暂无候选记录,可选择“新增本行”或“跳过本行”。",type:"info",closable:!1,"show-icon":"",style:{margin:"8px 0"}})):e.createCommentVNode("",!0),e.createVNode(se,{data:((fe=D.value)==null?void 0:fe.candidates)||[],border:"",stripe:"","max-height":"300",style:{width:"100%"},onCurrentChange:I,"highlight-current-row":""},{default:e.withCtx(()=>[e.createVNode(F,{type:"index",label:"序号",width:"60"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(M.value,ae=>(e.openBlock(),e.createBlock(F,{key:ae.prop,label:ae.label,prop:ae.prop,"min-width":ae.minWidth||160},{default:e.withCtx(({row:de})=>[ae.label==="证书附件"||ae.prop==="证书附件"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[d(de==null?void 0:de[ae.prop]).length>0?(e.openBlock(),e.createBlock(J,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(De=>p({row:de,prop:ae.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(e.openBlock(),e.createElementBlock("span",Ad,"-"))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString((de==null?void 0:de[ae.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128))]),_:1},8,["data"])])):e.createCommentVNode("",!0)])]}),footer:e.withCtx(()=>[e.createElementVNode("div",zd,[e.createVNode(ge,{id:"themeBorderButton",onClick:k},{default:e.withCtx(()=>$[5]||($[5]=[e.createTextVNode("取消")])),_:1,__:[5]}),e.createVNode(ge,{class:"ok-button",id:"themeButton",onClick:b},{default:e.withCtx(()=>$[6]||($[6]=[e.createTextVNode("提交已处理")])),_:1,__:[6]})])]),_:1},8,["visible"])}}},Id=Zl._export_sfc(Md,[["__scopeId","data-v-89e0489c"]]),Od={class:"ocr-preview-content"},Ld={class:"ocr-preview-tip"},Rd={class:"ocr-preview-table"},$d={style:{display:"flex","align-items":"center",gap:"8px"}},Vd={class:"dialog-footer"},Fd={__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,t=e.ref([]),s=e.ref([]),v=e.ref([]);e.watch(()=>r.visible,M=>{M&&(t.value=JSON.parse(JSON.stringify(r.ocrPreviewData)),s.value=JSON.parse(JSON.stringify(r.ocrPreviewColumns)),v.value=[...r.ocrSelectedFields])});const d=(M,S)=>{const K=[...v.value];if(S)K.includes(M)||K.push(M);else{const I=K.indexOf(M);I>-1&&K.splice(I,1)}v.value=K,n("update:ocrSelectedFields",K)},p=(M,S,K)=>{n("fieldChange",{rowIndex:M,prop:S,value:K})},y=()=>{n("update:ocrPreviewData",t.value),n("confirm",t.value),n("update:visible",!1)},g=()=>{n("update:visible",!1)},c=M=>typeof M!="number"?"-":`${(M*100).toFixed(1)}%`,D=M=>typeof M!="number"?"#606266":M>=.9?"#67c23a":M>=.7?"#e6a23c":"#f56c6c";return(M,S)=>{const K=e.resolveComponent("el-alert"),I=e.resolveComponent("el-table-column"),R=e.resolveComponent("el-checkbox"),j=e.resolveComponent("el-input"),E=e.resolveComponent("el-table"),x=e.resolveComponent("el-button");return e.openBlock(),e.createBlock(wr.ssDialog,{title:"OCR识别结果预览",visible:a.visible,onBeforeDestroy:g,width:"90%",style:{maxWidth:"1200px"}},{default:e.withCtx(()=>[e.createElementVNode("div",Od,[e.createElementVNode("div",Ld,[e.createVNode(K,{title:"请核对识别结果。系统将按 编号+名称+制造厂 规则匹配并替换;未唯一命中但有编号的,将进入候选选择;无编号则直接新增。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",Rd,[e.createVNode(E,{data:t.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(I,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,k=>(e.openBlock(),e.createBlock(I,{key:k.prop,prop:k.prop,"min-width":k.minWidth||230,"class-name":k.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",$d,[k.isAccuracy?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(R,{key:0,"model-value":v.value.includes(k.prop),onChange:b=>d(k.prop,b),onClick:S[0]||(S[0]=e.withModifiers(()=>{},["stop"]))},null,8,["model-value","onChange"])),e.createElementVNode("span",null,e.toDisplayString(k.label),1)])]),default:e.withCtx(({row:b,$index:w})=>[k.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:D(b[k.prop]),fontWeight:500})},e.toDisplayString(c(b[k.prop])),5)):(e.openBlock(),e.createBlock(j,{key:1,modelValue:b[k.prop],"onUpdate:modelValue":$=>b[k.prop]=$,size:"small",placeholder:"请输入"+k.label,onChange:$=>p(w,k.prop,$)},null,8,["modelValue","onUpdate:modelValue","placeholder","onChange"]))]),_:2},1032,["prop","min-width","class-name"]))),128))]),_:1},8,["data"])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",Vd,[e.createVNode(x,{onClick:g,id:"themeBorderButton"},{default:e.withCtx(()=>S[1]||(S[1]=[e.createTextVNode("取消")])),_:1,__:[1]}),e.createVNode(x,{class:"ok-button",onClick:y,id:"themeButton"},{default:e.withCtx(()=>S[2]||(S[2]=[e.createTextVNode("确认")])),_:1,__:[2]})])]),_:1},8,["visible"])}}},Pd=Zl._export_sfc(Fd,[["__scopeId","data-v-df66eb1f"]]),ji=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=he.analyzeSplitToContent(l,","))==null?void 0:n.map(t=>((t==null?void 0:t[(t==null?void 0:t.length)-1])===","&&(t=t==null?void 0:t.slice(0,(t==null?void 0:t.length)-1)),un(t)));return r=r==null?void 0:r.join(","),r};function Zs(a){return qa.axios.post("http://222.92.178.198:8000/api/v1/excel-chat",a)}function jd(a){return qa.axios.get(a,{responseType:"blob"})}let Kl="$R",Hd="http://222.92.178.198:55002/AIRobot",tt=["Form","BarChart","FormText","FormBlock"];const Qs=a=>{var r,n;let l=(n=he.analyzeSplitToContent(a,"@"))==null?void 0:n[((r=he.analyzeSplitToContent(a,"@"))==null?void 0:r.length)-1];return!!(tt!=null&&tt.some(t=>l==null?void 0:l.includes(t)))},Ud=async(a,l,r,n)=>{var s,v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta;let t=a;if(Qs(t==null?void 0:t[0])){let te=Xd(t),ca=(s=te==null?void 0:te.filter)==null?void 0:s.join(","),Ee=[];(v=te==null?void 0:te.hideContents)==null||v.forEach(Ue=>{if(Ue){const oa=Ue;oa&&Ee.push(`(HideGroup=Yes, prop=${oa})`)}});let oe=(d=te==null?void 0:te.formContents)==null?void 0:d.filter(Ue=>{var oa;return(oa=Ue==null?void 0:Ue.filters)==null?void 0:oa.includes("@ShowHide=Hide")});(oe==null?void 0:oe.length)>0&&(oe==null||oe.forEach(Ue=>{if(Ue){const oa=Ue==null?void 0:Ue.prop;oa&&Ee.push(`(Hide=Yes, prop=${oa})`)}}));let Te=(n==null?void 0:n.menuFilter)??[];return Array.isArray(Te)||(Te=Te?[Te]:[]),Te=[...Te,...Ee],{key:"Form",name:te==null?void 0:te.groupName,value:te==null?void 0:te.formContents,contents:Array.isArray((p=te==null?void 0:te.contents)==null?void 0:p[0])&&((g=(y=te==null?void 0:te.contents)==null?void 0:y[0])!=null&&g.every(Ue=>Array.isArray(Ue)))?[(D=(c=te==null?void 0:te.contents)==null?void 0:c[0])==null?void 0:D[r]]:[te==null?void 0:te.contents],filter:"("+ca+")",menuFilter:Te,groupFilter:te==null?void 0:te.groupFilters}}else if(((M=t==null?void 0:t[0])==null?void 0:M[0])!=="&"){let te=lc(t,n),ca="";(S=te==null?void 0:te.tableFilter)!=null&&S.includes(Kl)?te.tableFilter=(K=te==null?void 0:te.tableFilter)==null?void 0:K.replace(Kl,""):ca=(j=(R=(I=te==null?void 0:te.tableFilter)==null?void 0:I.replace("(",Kl))==null?void 0:R.split(Kl))==null?void 0:j[0];let Ee=[];te!=null&&te.tableFilter&&((E=he.analyzeSplitToContent(te==null?void 0:te.tableFilter,","))==null||E.forEach(Te=>{Te!=null&&Te.includes("@ShowHide=Hide")&&Ee.push("HideGroup=Yes")}));let oe=(n==null?void 0:n.menuFilter)??[];return Array.isArray(oe)||(oe=oe?[oe]:[]),oe=[...oe,...Ee],{key:"Table",name:te==null?void 0:te.groupName,tableColumns:te==null?void 0:te.tableColumns,assistColumn:te==null?void 0:te.columns,tableContents:l===1?te==null?void 0:te.tableContents:(k=(x=te==null?void 0:te.tableContents)==null?void 0:x[r])!=null&&k.every(Te=>Array.isArray(Te))?(b=te==null?void 0:te.tableContents)==null?void 0:b[r]:[(w=te==null?void 0:te.tableContents)==null?void 0:w[r]],filter:te==null?void 0:te.tableFilter,menuFilter:oe,quotePage:ca!==""?((J=(F=($=ca==null?void 0:ca.replace("*",Kl))==null?void 0:$.split(Kl))==null?void 0:F[0])==null?void 0:J.replaceAll(":","/"))??"":void 0,quoteGroup:ca!==""?((de=(ae=(fe=(V=(Me=(ge=(se=ca==null?void 0:ca.replace("*",Kl))==null?void 0:se.split(Kl))==null?void 0:ge[1])==null?void 0:Me.replace("{",Kl))==null?void 0:V.split(Kl))==null?void 0:fe[0])==null?void 0:ae.split(":"))==null?void 0:de.filter(Te=>Te!==""))??[]:[],relatedQuotes:te==null?void 0:te.relatedQuotes,fatherSyncContents:te==null?void 0:te.fatherSyncContents,sonSyncContents:te==null?void 0:te.sonSyncContents}}else{let te=[{label:"序号",prop:"sort"},{label:"函数名称",prop:"函数名称"},{label:"函数关联名",prop:"函数关联名"},{label:"函数参数",prop:"函数参数"},{label:"输出值",prop:"输出值"},{label:"导入文件",prop:"导入文件",formType:"Upload"}],ca=t==null?void 0:t[0];ca=ca==null?void 0:ca.slice(1,ca==null?void 0:ca.length),ca=he.analyzeSplitToContent(ca,":"),ca=ca==null?void 0:ca[(ca==null?void 0:ca.length)-1];let Ee=[];Ee.push("1");let oe=ca==null?void 0:ca.replace("(",Kl);oe=(De=oe==null?void 0:oe.split(Kl))==null?void 0:De[0],Ee.push(oe);let Te=ca==null?void 0:ca.replace("(",Kl);if(Te=(Fe=Te==null?void 0:Te.split(Kl))==null?void 0:Fe[1],Te=(T=(ye=Te==null?void 0:Te.replace(")",Kl))==null?void 0:ye.split(Kl))==null?void 0:T[0],(U=(ue=Te==null?void 0:Te.replace(",",Kl))==null?void 0:ue.split(Kl))==null||U.forEach(Ue=>{Ee.push(Ue)}),Ee.push(""),Ee.push(""),(Se=Ee==null?void 0:Ee[2])!=null&&Se.includes(".xlsx")||(Le=Ee==null?void 0:Ee[2])!=null&&Le.includes(".xls"))try{let Ue=Hd+"/"+(Ee==null?void 0:Ee[2]),oa=await jd(Ue),Ja=`生成js函数名称为${Ee==null?void 0:Ee[1]}的函数,规则为:`+(Ee==null?void 0:Ee[3])+"。根据上述描述获取对应的总结性详细可运行js函数,不需要任何注释。";if((oa==null?void 0:oa.status)===200){let L=oa==null?void 0:oa.data;const H=new FormData;H.append("file",L,Ee==null?void 0:Ee[2]),H.append("query",Ja);let Q=await Zs(H);Q=(Da=(la=(Pe=Q==null?void 0:Q.data)==null?void 0:Pe.data)==null?void 0:la.response)==null?void 0:Da.replace("generateResult",Ee==null?void 0:Ee[1]),Ee[Ee.length-2]=Q,Ee[Ee.length-1]=[{name:(ta=(le=Ee==null?void 0:Ee[2])==null?void 0:le.split("."))==null?void 0:ta[0],url:Ue}]}}catch{}return Ee=[Ee],{key:"Method",name:[],tableContents:Ee,tableColumns:te}}},qd=(a,l)=>{var n,t,s,v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee;let r=(t=(n=he.analyzeSplitToContent(a,"="))==null?void 0:n.filter(oe=>oe!=="="))==null?void 0:t.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));if(Qs(r==null?void 0:r[1])){let oe=Jd(r),Te=(d=(v=(s=oe==null?void 0:oe.filter)==null?void 0:s.replace("@",Kl))==null?void 0:v.split(Kl))==null?void 0:d[0],Ue=(g=(y=(p=oe==null?void 0:oe.filter)==null?void 0:p.replace("(",Kl))==null?void 0:y.split(Kl))==null?void 0:g[1],oa=(M=(D=(c=oe==null?void 0:oe.filter)==null?void 0:c.replace("(",Kl))==null?void 0:D.split(Kl))==null?void 0:M[0];oa="@"+((S=oa==null?void 0:oa.split("@"))==null?void 0:S[1]),Ue=Ue==null?void 0:Ue.slice(0,(Ue==null?void 0:Ue.length)-1),Ue=(I=(K=he.analyzeSplitToContent(Ue,","))==null?void 0:K.map(L=>(L=oa+L,L)))==null?void 0:I.join("");let Ja=Te+"("+Ue+")";return{key:"Form",name:oe==null?void 0:oe.group,filter:Ja,formPage:((E=(j=(R=Te==null?void 0:Te.replace("*",Kl))==null?void 0:R.split(Kl))==null?void 0:j[0])==null?void 0:E.replaceAll(":","/"))??"",formGroup:((J=(F=($=(w=(b=(k=(x=Te==null?void 0:Te.replace("*",Kl))==null?void 0:x.split(Kl))==null?void 0:k[1])==null?void 0:b.replace("{",Kl))==null?void 0:w.split(Kl))==null?void 0:$[0])==null?void 0:F.split(":"))==null?void 0:J.filter(L=>L!==""))??[],value:[],menuFilter:l==null?void 0:l.menuFilter}}else{let oe=lc(r,l,r==null?void 0:r[1]),Te="";(se=oe==null?void 0:oe.tableFilter)!=null&&se.includes(Kl)?oe.tableFilter=(ge=oe==null?void 0:oe.tableFilter)==null?void 0:ge.replace(Kl,""):Te=(fe=(V=(Me=oe==null?void 0:oe.tableFilter)==null?void 0:Me.replace("(",Kl))==null?void 0:V.split(Kl))==null?void 0:fe[0];let Ue=(De=(de=(ae=oe==null?void 0:oe.tableFilter)==null?void 0:ae.replace("(",Kl))==null?void 0:de.split(Kl))==null?void 0:De[0];Ue=[{menus:(ye=(Fe=Ue==null?void 0:Ue.split("*"))==null?void 0:Fe[0])==null?void 0:ye.replaceAll(":","/"),groups:((ue=(T=Ue==null?void 0:Ue.split("*"))==null?void 0:T[1])==null?void 0:ue.split(":"))??[]}];let oa=(Le=(Se=(U=oe==null?void 0:oe.tableFilter)==null?void 0:U.replace("(",Kl))==null?void 0:Se.split(Kl))==null?void 0:Le[1];(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));let Ja=[];oe!=null&&oe.tableFilter&&((Pe=he.analyzeSplitToContent(oe==null?void 0:oe.tableFilter,","))==null||Pe.forEach(H=>{H!=null&&H.includes("@ShowHide=Hide")&&Ja.push("HideGroup=Yes")}));let L=(l==null?void 0:l.menuFilter)??[];return Array.isArray(L)||(L=L?[L]:[]),L=[...L,...Ja],{key:"Table",name:oe==null?void 0:oe.groupName,filter:oe==null?void 0:oe.tableFilter,tableColumns:oe==null?void 0:oe.tableColumns,quotePage:Te!==""?((le=(Da=(la=Te==null?void 0:Te.replace("*",Kl))==null?void 0:la.split(Kl))==null?void 0:Da[0])==null?void 0:le.replaceAll(":","/"))??"":void 0,quoteGroup:Te!==""?((Ee=(ca=(te=(ta=Te==null?void 0:Te.replace("*",Kl))==null?void 0:ta.split(Kl))==null?void 0:te[1])==null?void 0:ca.split(":"))==null?void 0:Ee.filter(H=>H!==""))??[]:[],menuFilter:L,relatedQuotes:Ue,fatherSyncContents:(oe==null?void 0:oe.fatherSyncContents)??[],sonSyncContents:(oe==null?void 0:oe.sonSyncContents)??[]}}},Wd=async(a,l)=>{let r=[],n=l==null?void 0:l.length;return l=l==null?void 0:l.map(async(t,s)=>{let v=[];t=t==null?void 0:t.map(async d=>{var p,y;if(v.push(d),((p=he.analyzeSplitToContent(a,"="))==null?void 0:p.length)<=2){if(((y=he.analyzeSplitToContent(a,"="))==null?void 0:y.length)!==0){const g=await Ud(he.analyzeSplitToContent(a,"="),n,s,d);v.push(g)}}else v.push(qd(a,d))}),await Promise.all(t),r.push(v)}),await Promise.all(l),r};let Fi="/",Kd="$",hn="$R";const ec=a=>{var r,n,t;let l="";if((a==null?void 0:a.length)>1){let s=a==null?void 0:a.filter((v,d)=>d!==0);s=s==null?void 0:s.join(""),s=he.analyzerSplitToWord(s,")"),(s==null?void 0:s.length)!==1?(s==null?void 0:s[(s==null?void 0:s.length)-1])===")"?s=s==null?void 0:s.join(""):s=(r=s==null?void 0:s.filter((v,d)=>d!==(s==null?void 0:s.length)-1))==null?void 0:r.join(""):s=s==null?void 0:s[0],l="("+s,((t=a==null?void 0:a[0])==null?void 0:t[((n=a==null?void 0:a[0])==null?void 0:n.length)-2])==="@"&&(l="@"+l)}return{filter:l}},ac=(a,l=[])=>{let r=(a==null?void 0:a.map(s=>{var v,d;return(d=s==null?void 0:s.key)==null?void 0:d.slice(1,(v=s==null?void 0:s.key)==null?void 0:v.length)}))??[],n=[];r==null||r.forEach(s=>{var v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge;if(s===""&&(s="算法库:通用算法"),s!=null&&s.includes(Kd)){let Me="",V=!0,fe=he.analyzerSplitToWord(s,"(");(fe==null?void 0:fe.length)>1&&(Me="("+((v=he.analyzerSplitToWord(fe==null?void 0:fe[1],")"))==null?void 0:v[0]),((p=fe==null?void 0:fe[0])==null?void 0:p[((d=fe==null?void 0:fe[0])==null?void 0:d.length)-2])==="@"&&(Me="@"+Me));let ae=s;ae=ae==null?void 0:ae.replace(Me,""),Me=un(Me),Me=(y=he.analyzeSplitToContent(Me,","))==null?void 0:y.map(ue=>((ue==null?void 0:ue[(ue==null?void 0:ue.length)-1])===","&&(ue=ue==null?void 0:ue.slice(0,(ue==null?void 0:ue.length)-1)),ue)),Me!=null&&Me.includes("@ShowHide=Hide")&&(V=!1);let de=(g=ae==null?void 0:ae.replace("$",hn))==null?void 0:g.split(hn),De=de==null?void 0:de[1],Fe=de==null?void 0:de[0];Fe!=null&&Fe.includes("[")&&(Fe=(D=(c=Fe==null?void 0:Fe.replace("[",hn))==null?void 0:c.split(hn))==null?void 0:D[0],De=De+":["+((K=(S=(M=de==null?void 0:de[0])==null?void 0:M.replace("[",hn))==null?void 0:S.split(hn))==null?void 0:K[1])),Fe=(R=(I=Fe==null?void 0:Fe.replaceAll(":","/"))==null?void 0:I.replaceAll("{",""))==null?void 0:R.replaceAll("}",""),(Fe==null?void 0:Fe[(Fe==null?void 0:Fe.length)-1])!=="/"&&(Fe=Fe+"/"),De=((j=Fe==null?void 0:Fe.split("/"))==null?void 0:j[0])+":"+De;let T="";if(!(De!=null&&De.includes("[")))T=De==null?void 0:De.replaceAll(":","/"),n==null||n.push({path:T,isShow:V,filter:Me,fatherPath:Fe});else{let ue=(x=(E=De==null?void 0:De.replace("[",hn))==null?void 0:E.split(hn))==null?void 0:x[1];ue=ue==null?void 0:ue.slice(0,(ue==null?void 0:ue.length)-1),ue=(k=he.analyzeSplitToContent(ue,","))==null?void 0:k.map(U=>((U==null?void 0:U[(U==null?void 0:U.length)-1])===","&&(U=U==null?void 0:U.slice(0,(U==null?void 0:U.length)-1)),U)),ue==null||ue.forEach(U=>{var Se,Le;T=((Le=(Se=De==null?void 0:De.replace("[",hn))==null?void 0:Se.split(hn))==null?void 0:Le[0])+U,T=T==null?void 0:T.replaceAll(":","/"),n==null||n.push({path:T,isShow:V,filter:Me,fatherPath:Fe})})}}else{let Me="",V=!0,fe=he.analyzerSplitToWord(s,"(");(fe==null?void 0:fe.length)>1&&(Me=(b=ec(fe))==null?void 0:b.filter);let ae=s;if(ae=ae==null?void 0:ae.replace(Me,""),(Me==null?void 0:Me[0])==="("){Me=Me==null?void 0:Me.slice(1,(Me==null?void 0:Me.length)-1);let De=[];(w=he.analyzeSplitToContent(Me,","))==null||w.forEach(Fe=>{(Fe==null?void 0:Fe[(Fe==null?void 0:Fe.length)-1])===","&&(Fe=Fe==null?void 0:Fe.slice(0,(Fe==null?void 0:Fe.length)-1)),(Fe==null?void 0:Fe[0])==="("&&(Fe=Fe==null?void 0:Fe.slice(1,(Fe==null?void 0:Fe.length)-1)),(Fe==null?void 0:Fe[0])!=="@"&&(Fe="@"+Fe),De.push(un(Fe))}),Me=De==null?void 0:De.join(",")}else Me=un(Me);Me=($=he.analyzeSplitToContent(Me,","))==null?void 0:$.map(De=>((De==null?void 0:De[(De==null?void 0:De.length)-1])===","&&(De=De==null?void 0:De.slice(0,(De==null?void 0:De.length)-1)),De)),Me!=null&&Me.includes("@ShowHide=Hide")&&(V=!1),(ae==null?void 0:ae[(ae==null?void 0:ae.length)-1])==="}"&&(ae=ae+":"),ae=(F=ae==null?void 0:ae.replaceAll("{",""))==null?void 0:F.replaceAll("}","");let de="";if(ae!=null&&ae.includes("[")){let De=(J=ae==null?void 0:ae.replace("[",hn))==null?void 0:J.split(hn),Fe=De==null?void 0:De[1];Fe=Fe==null?void 0:Fe.slice(0,(Fe==null?void 0:Fe.length)-1),(ge=(se=he.analyzeSplitToContent(Fe,","))==null?void 0:se.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)))==null||ge.forEach(ye=>{de=(De==null?void 0:De[0])+ye,de=de==null?void 0:de.replaceAll(":","/"),n==null||n.push({path:de,isShow:V,filter:Me})})}else de=ae==null?void 0:ae.replaceAll(":","/"),n==null||n.push({path:de,isShow:V,filter:Me})}});let t=A.cloneDeep(n);return(l==null?void 0:l.length)>0&&(t=l),t=t==null?void 0:t.filter(s=>{var v,d,p,y;return!(s!=null&&s.fatherPath)&&((d=(v=s==null?void 0:s.path)==null?void 0:v.split(Fi))==null?void 0:d.length)>1&&((y=(p=s==null?void 0:s.path)==null?void 0:p.split(Fi))==null?void 0:y[1])===""}),t=t==null?void 0:t.map(s=>{var v;return s.path=(v=s.path)==null?void 0:v.replace(Fi,""),s.path}),(t==null?void 0:t.length)>0&&(n=n==null?void 0:n.map(s=>{var d,p,y,g,c,D,M;let v=t==null?void 0:t.find(S=>{var K;return(K=s==null?void 0:s.path)==null?void 0:K.includes(S)});return!(s!=null&&s.fatherPath)&&v&&!((d=s==null?void 0:s.path)!=null&&d.includes(Fi))&&!(t!=null&&t.find(S=>(s==null?void 0:s.path)===S))&&(s.path=v+Fi+((M=(y=(p=s==null?void 0:s.path)==null?void 0:p.split(v))==null?void 0:y[1])==null?void 0:M.slice(1,(D=(c=(g=s==null?void 0:s.path)==null?void 0:g.split(v))==null?void 0:c[1])==null?void 0:D.length))),s})),n},Gd=(a,l)=>ac([{key:a}],l),Yd=async(a,l)=>{const r=[],n=Gd(a==null?void 0:a.key,l);return n&&(n==null?void 0:n.length)>0&&(n==null||n.forEach(s=>{r.push([{key:"path",value:s==null?void 0:s.path,parentPath:(s==null?void 0:s.parentPath)??"",isShow:s==null?void 0:s.isShow,menuFilter:s==null?void 0:s.filter}])})),await Wd(a==null?void 0:a.value,r)};let fl="$R",Hi="[Any]";const Jd=a=>{var v,d;let l={},n=a==null?void 0:a[0];(n==null?void 0:n[0])==="*"&&(n=n==null?void 0:n.slice(1,n==null?void 0:n.length)),n=n==null?void 0:n.split(":"),l.group=n;let t=a==null?void 0:a[1],s;return t!=null&&t.includes("{")?s=(d=(v=t==null?void 0:t.replaceAll("{",""))==null?void 0:v.replaceAll("}",""))==null?void 0:d.replaceAll(Hi,""):s=t==null?void 0:t.replaceAll(Hi,""),(s==null?void 0:s[0])==="$"&&(s=s==null?void 0:s.slice(1,s==null?void 0:s.length)),l.filter=s,l},Xd=a=>{var D,M,S,K,I,R;let l=[],r=[],n=[],t=[],s=[],v=[],d="",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));let y=he.analyzeSplitToContent(p,":");(D=y==null?void 0:y.filter(j=>(j==null?void 0:j[0])!=="{"&&(j==null?void 0:j[0])!=="["))==null||D.forEach(j=>{var x,k,b;(j==null?void 0:j[(j==null?void 0:j.length)-1])===":"&&(j=j==null?void 0:j.slice(0,(j==null?void 0:j.length)-1));let E=he.analyzerSplitToWord(j,"(");if((E==null?void 0:E.length)>1){d=(x=ec(E))==null?void 0:x.filter;let w=j==null?void 0:j.replace(d,"");if(n.push(w),(d==null?void 0:d[0])==="("){d=d==null?void 0:d.slice(1,(d==null?void 0:d.length)-1);let $=[];(k=he.analyzeSplitToContent(d,","))==null||k.forEach(F=>{(F==null?void 0:F[(F==null?void 0:F.length)-1])===","&&(F=F==null?void 0:F.slice(0,(F==null?void 0:F.length)-1)),(F==null?void 0:F[0])==="("&&(F=F==null?void 0:F.slice(1,(F==null?void 0:F.length)-1)),(F==null?void 0:F[0])!=="@"&&(F="@"+F),$.push(un(F))}),d=$==null?void 0:$.join(",")}else d=un(d);d=(b=he.analyzeSplitToContent(d,","))==null?void 0:b.map($=>(($==null?void 0:$[($==null?void 0:$.length)-1])===","&&($=$==null?void 0:$.slice(0,($==null?void 0:$.length)-1)),$)),d!=null&&d.includes("@ShowHide=Hide")&&v.push(w),t=[...t,...d]}else n.push(E==null?void 0:E[0])});let g=(M=y==null?void 0:y.filter(j=>(j==null?void 0:j[0])==="{"))==null?void 0:M[0],c=(S=y==null?void 0:y.filter(j=>(j==null?void 0:j[0])==="["))==null?void 0:S[0];return l=Ci(c??""),l!=null&&l.every(j=>Array.isArray(j))&&(l=[l]),(g==null?void 0:g[(g==null?void 0:g.length)-1])===":"&&(g=g==null?void 0:g.slice(0,(g==null?void 0:g.length)-1)),s=(K=he.analyzeSplitToContent(g,"@"))==null?void 0:K[1],s="@"+s,g=g==null?void 0:g.replace(s,""),s=un(s),s=(I=he.analyzeSplitToContent(s,","))==null?void 0:I.map(j=>((j==null?void 0:j[(j==null?void 0:j.length)-1])===","&&(j=j==null?void 0:j.slice(0,(j==null?void 0:j.length)-1)),j)),(g==null?void 0:g[0])==="{"&&(g=g==null?void 0:g.slice(1,(g==null?void 0:g.length)-1)),g=(R=he.analyzeSplitToContent(g,","))==null?void 0:R.map(j=>((j==null?void 0:j[(j==null?void 0:j.length)-1])===","&&(j=j==null?void 0:j.slice(0,(j==null?void 0:j.length)-1)),j)),g==null||g.forEach((j,E)=>{var V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja,L,H,Q,me,ve,da;let x=[],k=[],b=!1,w,$=[],F=[],J=[],se="Input",ge=[],Me=[];if(j!=null&&j.includes("==")){w=(V=j==null?void 0:j.split("=="))==null?void 0:V[0];let ea=(fe=j==null?void 0:j.split("=="))==null?void 0:fe[1],ce="";((ae=he.analyzeSplitToContent(ea,"$"))==null?void 0:ae.length)>1&&((de=he.analyzeSplitToContent(ea,"$"))==null?void 0:de[0])!=="$"?(ce=(De=he.analyzeSplitToContent(ea,"$"))==null?void 0:De[0],ce=ce==null?void 0:ce.slice(0,(ce==null?void 0:ce.length)-1)):((Fe=he.analyzeSplitToContent(ea,"}"))==null?void 0:Fe.length)>1&&(ce=(ye=he.analyzeSplitToContent(ea,"}"))==null?void 0:ye[1]);let pa=ea==null?void 0:ea.replace(ce,"");(ce==null?void 0:ce[0])==="("&&(ce=ce==null?void 0:ce.slice(1,(ce==null?void 0:ce.length)-1)),(T=he.analyzeSplitToContent(ce,","))==null||T.forEach(We=>{var Ca;(We==null?void 0:We[0])!=="@"&&(We="@"+We),(We==null?void 0:We[(We==null?void 0:We.length)-1])===","&&(We=We==null?void 0:We.slice(0,(We==null?void 0:We.length)-1));let Ta=un(We);(Ca=he.analyzeSplitToContent(Ta,","))==null||Ca.forEach(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)),x.push(Qe)})}),(pa==null?void 0:pa[0])==="$"&&(pa=pa==null?void 0:pa.slice(1,pa==null?void 0:pa.length));let Ne=(ue=pa==null?void 0:pa.replace("*",fl))==null?void 0:ue.split(fl);$=(U=Ne==null?void 0:Ne[0])==null?void 0:U.split(":"),F=(Le=(Se=he.analyzeSplitToContent(Ne==null?void 0:Ne[1],":"))==null?void 0:Se.filter((We,Ta)=>{var Ca,Qe;return Ta!==((Qe=(Ca=Ne==null?void 0:Ne[1])==null?void 0:Ca.split(":"))==null?void 0:Qe.length)-1}))==null?void 0:Le.map(We=>((We==null?void 0:We[(We==null?void 0:We.length)-1])===":"&&(We=We==null?void 0:We.slice(0,(We==null?void 0:We.length)-1)),We)),J=(la=(Pe=he.analyzeSplitToContent(Ne==null?void 0:Ne[1],":"))==null?void 0:Pe.filter((We,Ta)=>{var Ca,Qe;return Ta===((Qe=(Ca=Ne==null?void 0:Ne[1])==null?void 0:Ca.split(":"))==null?void 0:Qe.length)-1}))==null?void 0:la[0],J=(le=(Da=J==null?void 0:J.replaceAll("{",""))==null?void 0:Da.replaceAll("}",""))==null?void 0:le.split(":"),se="Select"}else if(((ta=he.analyzeSplitToContent(j,"="))==null?void 0:ta.length)>1)if(se="Select",w=(ca=(te=j==null?void 0:j.replace("=",fl))==null?void 0:te.split(fl))==null?void 0:ca[0],!(j!=null&&j.includes("If")))ge=(oe=(Ee=j==null?void 0:j.replace("=",fl))==null?void 0:Ee.split(fl))==null?void 0:oe[1],ge=ge==null?void 0:ge.split("||");else{let ea=(Ue=(Te=j==null?void 0:j.replace("=",fl))==null?void 0:Te.split(fl))==null?void 0:Ue[1];Me=(oa=he.analyzeSplitToContent(ea,")"))==null?void 0:oa.filter(ce=>!(ce!=null&&ce.includes("If"))),Me=Me==null?void 0:Me.map(ce=>((ce==null?void 0:ce[0])==="("&&(ce=ce==null?void 0:ce.slice(1,(ce==null?void 0:ce.length)-1)),ce=ce==null?void 0:ce.split("||"),ce)),k=(Ja=he.analyzeSplitToContent(ea,")"))==null?void 0:Ja.filter(ce=>ce==null?void 0:ce.includes("If")),k=k==null?void 0:k.map(ce=>((ce==null?void 0:ce[0])==="|"&&(ce=ce==null?void 0:ce.slice(2,ce==null?void 0:ce.length)),(ce==null?void 0:ce[0])==="("&&(ce=ce==null?void 0:ce.slice(1,(ce==null?void 0:ce.length)-1)),(ce==null?void 0:ce[0])!=="@"&&(ce="@"+ce),ce))}else if(((L=he.analyzeSplitToContent(j,"@"))==null?void 0:L.length)>1){w=(H=he.analyzeSplitToContent(j,"@"))==null?void 0:H[0],(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));let ea="@"+((Q=he.analyzeSplitToContent(j,"@"))==null?void 0:Q[1]);ea=un(ea),x=(me=he.analyzeSplitToContent(ea,","))==null?void 0:me.map(ce=>((ce==null?void 0:ce[(ce==null?void 0:ce.length)-1])===","&&(ce=ce==null?void 0:ce.slice(0,(ce==null?void 0:ce.length)-1)),ce)),x!=null&&x.find(ce=>ce==null?void 0:ce.includes("@Type"))&&(se=(da=(ve=x==null?void 0:x.find(ce=>ce==null?void 0:ce.includes("@Type")))==null?void 0:ve.split("="))==null?void 0:da[1])}else w=j;x!=null&&x.includes("@ShowHide=Hide")&&(b=!0),r.push({prop:w,label:w,value:"",menuPath:$,groups:F,columns:J,type:se,options:ge,allContents:Me,filters:x,width:g==null?void 0:g.length,isFormColHidden:b,filterContents:k})}),{groupName:n,groupFilters:t,formContents:r,contents:l,filter:s,hideContents:v}},Ci=a=>{var n,t;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=he.analyzeSplitToContent(r,","))==null||n.forEach(s=>{(s==null?void 0:s[(s==null?void 0:s.length)-1])===","&&(s=s.slice(0,(s==null?void 0:s.length)-1)),l.push(s??"")});else{let s=[];(t=he.analyzeSplitToContent(r,","))==null||t.forEach(v=>{(v==null?void 0:v[(v==null?void 0:v.length)-1])===","&&(v=v==null?void 0:v.slice(0,(v==null?void 0:v.length)-1)),s.push(Ci(v))}),l=s}return l},ft=(a,l)=>{var R,j,E,x,k,b,w,$,F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja,L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va;let r,n=[],t=[],s=[],v=[],d=[],p=[],y=[],g="Input",c,D="",M="",S="",K=[],I="";if(a!=null&&a.includes("==")||a!=null&&a.includes("=")||a!=null&&a.includes("@")||a!=null&&a.includes("||"))if(r=(R=a==null?void 0:a.split("=="))==null?void 0:R[0],c=(j=a==null?void 0:a.split("=="))==null?void 0:j[0],g="Select",a!=null&&a.includes("=")&&!(a!=null&&a.includes("=="))&&!((k=(x=(E=a==null?void 0:a.replace("=",fl))==null?void 0:E.split(fl))==null?void 0:x[1])!=null&&k.includes("If")))if(r=he.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=(w=(b=r==null?void 0:r.replace("=",fl))==null?void 0:b.split(fl))==null?void 0:w[0],r!=null&&r.includes("&")&&(r=(F=($=r==null?void 0:r.replace("&",fl))==null?void 0:$.split(fl))==null?void 0:F[0]),c=r,((J=he.analyzeSplitToContent(a,"@"))==null?void 0:J.length)>1&&!(a!=null&&a.includes("||"))){if(!(a!=null&&a.includes("&"))){let ne=(se=he.analyzeSplitToContent(a,"@"))==null?void 0:se[1];if((ne==null?void 0:ne[0])!=="@"&&(ne="@"+ne),ne=un(ne),M=ne,M!=null&&M.includes("@Type")){let X=he.analyzeSplitToContent(M,",");X=X==null?void 0:X.map(Z=>((Z==null?void 0:Z[(Z==null?void 0:Z.length)-1])===","&&(Z=Z==null?void 0:Z.slice(0,(Z==null?void 0:Z.length)-1)),Z)),X=(ge=X==null?void 0:X.filter(Z=>Z==null?void 0:Z.includes("@Type")))==null?void 0:ge[0],g=(Me=X==null?void 0:X.split("="))==null?void 0:Me[1]}}}else if(a!=null&&a.includes("||")){let ne=[];n=(de=(ae=(fe=(V=a==null?void 0:a.replace("=",fl))==null?void 0:V.split(fl))==null?void 0:fe[1])==null?void 0:ae.split("||"))==null?void 0:de.map(X=>{var q,Be,Je,ra;let Z=X;if(Z!=null&&Z.includes("@")){let ba="@"+((Be=(q=Z==null?void 0:Z.replace("@",fl))==null?void 0:q.split(fl))==null?void 0:Be[1]);Z=(ra=(Je=Z==null?void 0:Z.replace("@",fl))==null?void 0:Je.split(fl))==null?void 0:ra[0],ba=ji(ba),ne.push(ba)}return{label:Z==null?void 0:Z.replaceAll("'",""),value:Z==null?void 0:Z.replaceAll("'","")}}),(ne==null?void 0:ne.length)>0&&(M="("+(ne==null?void 0:ne.join("||"))+")")}else g="Input",D=(ye=(Fe=(De=a==null?void 0:a.replace("=",fl))==null?void 0:De.split(fl))==null?void 0:Fe[1])==null?void 0:ye.replaceAll("'","");else if((U=(ue=(T=a==null?void 0:a.replace("=",fl))==null?void 0:T.split(fl))==null?void 0:ue[1])!=null&&U.includes("||")){r=(Se=a==null?void 0:a.split("="))==null?void 0:Se[0],c=(Le=a==null?void 0:a.split("="))==null?void 0:Le[0];let ne=(la=(Pe=a==null?void 0:a.replace("=",fl))==null?void 0:Pe.split(fl))==null?void 0:la[1];ne=he.analyzeSplitToContent(ne,")");let X=ne==null?void 0:ne.filter(q=>!(q!=null&&q.includes("If")));X==null||X.forEach(q=>{(q==null?void 0:q[0])==="("&&(q=q==null?void 0:q.slice(1,(q==null?void 0:q.length)-1)),t==null||t.push(q==null?void 0:q.split("||"))});let Z=ne==null?void 0:ne.filter(q=>q==null?void 0:q.includes("If"));Z=Z==null?void 0:Z.map(q=>((q==null?void 0:q[0])==="|"&&(q==null?void 0:q[1])==="|"&&(q=q==null?void 0:q.slice(2,q==null?void 0:q.length)),(q==null?void 0:q[0])==="("&&(q=q==null?void 0:q.slice(1,(q==null?void 0:q.length)-1)),(q==null?void 0:q[0])!=="@"&&(q="@"+q),q)),s=Z}else{let ne=a==null?void 0:a.split("=="),X=(Da=ne==null?void 0:ne.filter(Z=>(Z==null?void 0:Z.includes("$"))&&(Z==null?void 0:Z[0])!=="{"))==null?void 0:Da[0];if(X&&!(X!=null&&X.includes("&"))){let Z=(le=X==null?void 0:X.replace("*",fl))==null?void 0:le.split(fl),q=(Z==null?void 0:Z[0])===""?l==null?void 0:l.value:Z==null?void 0:Z[0];(q==null?void 0:q[0])==="("&&(q=(ta=he.analyzeSplitToContent(q,")"))==null?void 0:ta[1]),q=(ca=(te=q==null?void 0:q.replaceAll("{",""))==null?void 0:te.replaceAll("}",""))==null?void 0:ca.replaceAll(Hi,""),(q==null?void 0:q[0])==="$"&&(q=(Ee=q==null?void 0:q.slice(1,q==null?void 0:q.length))==null?void 0:Ee.replaceAll(":","/")),v=q==null?void 0:q.split("/");let Be=(Te=(oe=Z==null?void 0:Z[1])==null?void 0:oe.replace("{",fl))==null?void 0:Te.split(fl),Je=Be==null?void 0:Be[0];(Je==null?void 0:Je[(Je==null?void 0:Je.length)-1])===":"&&(Je=Je==null?void 0:Je.slice(0,(Je==null?void 0:Je.length)-1)),d=Je==null?void 0:Je.split(":"),p=(L=(Ja=(oa=(Ue=Be==null?void 0:Be[1])==null?void 0:Ue.replace("}",fl))==null?void 0:oa.split(fl))==null?void 0:Ja[0])==null?void 0:L.split(":");let ra="";((H=he.analyzeSplitToContent(X,")"))==null?void 0:H.length)>1&&(ra=(Q=he.analyzeSplitToContent(X,")"))==null?void 0:Q[0]),ra&&ra!==""&&((ra==null?void 0:ra[0])!=="@"&&(ra="@"+ra),M=ji(ra))}if(ne!=null&&ne.some(Z=>(Z==null?void 0:Z[0])==="&")){let Z=(me=ne==null?void 0:ne.filter(Je=>(Je==null?void 0:Je[0])==="&"))==null?void 0:me[0];(Z==null?void 0:Z[0])==="&"&&(Z=Z==null?void 0:Z.slice(1,Z==null?void 0:Z.length)),S=(da=(ve=Z==null?void 0:Z.replace("(",fl))==null?void 0:ve.split(fl))==null?void 0:da[0];let q=(ea=he.analyzeSplitToContent(Z,")"))==null?void 0:ea[0];q=(pa=(ce=q==null?void 0:q.replace("(",fl))==null?void 0:ce.split(fl))==null?void 0:pa[1],q=q==null?void 0:q.slice(0,(q==null?void 0:q.length)-1),(q==null?void 0:q[0])==="{"&&(q=q==null?void 0:q.slice(1,q==null?void 0:q.length)),(q==null?void 0:q[(q==null?void 0:q.length)-1])==="}"&&(q=q==null?void 0:q.slice(0,(q==null?void 0:q.length)-1)),K=q==null?void 0:q.split(",");let Be=(Ne=he.analyzeSplitToContent(Z,")"))==null?void 0:Ne[1];Be&&Be!==""&&(I=ji(Be))}else if(!X&&((We=ne==null?void 0:ne.filter(Z=>(Z==null?void 0:Z[0])==="{"))==null?void 0:We.length)>0){let Z=ne==null?void 0:ne[(ne==null?void 0:ne.length)-1];Z=Z==null?void 0:Z.slice(1,(Z==null?void 0:Z.length)-1),Z=he.analyzeSplitToContent(Z,","),Z=Z==null?void 0:Z.map(q=>((q==null?void 0:q[(q==null?void 0:q.length)-1])===","&&(q=q==null?void 0:q.slice(0,(q==null?void 0:q.length)-1)),q)),Z=Z==null?void 0:Z.map(q=>{var Be,Je,ra,ba;if(q=q==null?void 0:q.replaceAll("$",""),q!=null&&q.includes("{")){let ga="";q=q==null?void 0:q.replaceAll("{","");let Aa=q==null?void 0:q.split("}");ga=((Je=(Be=Aa==null?void 0:Aa[0])==null?void 0:Be.split(":"))==null?void 0:Je[0])+":"+(Aa==null?void 0:Aa[1]),q=ga,q=q+":"}if(q!=null&&q.includes(Hi)){let ga="",Aa=q==null?void 0:q.split(Hi);ga=((ba=(ra=Aa==null?void 0:Aa[0])==null?void 0:ra.split(":"))==null?void 0:ba[0])+":"+(Aa==null?void 0:Aa[1]),q=ga,q=q+":"}return q=q==null?void 0:q.replaceAll(":","/"),q}),y=Z}else!((Ta=ne==null?void 0:ne[1])!=null&&Ta.includes("$"))&&((Ca=ne==null?void 0:ne[1])==null?void 0:Ca[0])!=="("&&p.push(ne==null?void 0:ne[1])}else r=(Qe=a==null?void 0:a.split("&"))==null?void 0:Qe[0],c=(Va=a==null?void 0:a.split("&"))==null?void 0:Va[0];return{label:r,prop:c,options:n,allContents:t,filterContents:s,menus:v,groups:d,words:p,align:"center",formType:g,filter:M,functionName:S,functionRelatedWords:K,calculatorFilter:I,relatedPages:y,value:D}},Co=(a,l)=>{var n,t,s,v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge,Me,V,fe,ae;let r=[];if((a==null?void 0:a[0])==="{"&&(a==null?void 0:a[(a==null?void 0:a.length)-1])==="}"&&!((v=(s=(t=(n=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1))==null?void 0:n.replace(":",fl))==null?void 0:t.split(fl))==null?void 0:s[0])!=null&&v.includes(","))){let de=a==null?void 0:a.slice(1,(a==null?void 0:a.length)-1),De=(d=de==null?void 0:de.replace(":",fl))==null?void 0:d.split(fl);if(((p=he.analyzeSplitToContent(De==null?void 0:De[1],"="))==null?void 0:p.length)===1){let Fe=De==null?void 0:De[0],ye=[];(c=he.analyzeSplitToContent((g=De==null?void 0:De[1])==null?void 0:g.slice(1,((y=De==null?void 0:De[1])==null?void 0:y.length)-1),","))==null||c.forEach(T=>{var ue,U;((ue=he.analyzeSplitToContent(T,"="))==null?void 0:ue.length)>1?((T==null?void 0:T[(T==null?void 0:T.length)-1])===","&&(T=T==null?void 0:T.slice(0,(T==null?void 0:T.length)-1)),ye=[...ye,...Co(T,l)]):((T==null?void 0:T[(T==null?void 0:T.length)-1])===","&&(T=T==null?void 0:T.slice(0,(T==null?void 0:T.length)-1)),ye.push((U=Co(T,l))==null?void 0:U[0]))}),r==null||r.push({label:Fe,prop:Fe,children:ye,align:"center"})}else{let Fe=[];if(((D=he.analyzeSplitToContent(de,"="))==null?void 0:D.length)>=2){let T=(M=he.analyzeSplitToContent(de,"="))==null?void 0:M[1],ue=(S=he.analyzeSplitToContent(T,"/"))==null?void 0:S.map(U=>((U==null?void 0:U[(U==null?void 0:U.length)-1])==="/"&&(U=U==null?void 0:U.slice(0,(U==null?void 0:U.length)-1)),U));Fe=ue==null?void 0:ue.map(U=>(U=Ci(U),U))}let ye=(x=(E=(j=(R=(I=(K=de==null?void 0:de.replace("{",fl))==null?void 0:K.split(fl))==null?void 0:I[1])==null?void 0:R.replace("}",fl))==null?void 0:j.split(fl))==null?void 0:E[0])==null?void 0:x.split(",");ye==null||ye.forEach((T,ue)=>{(Fe==null?void 0:Fe.length)>0&&ue===0?r==null||r.push({label:T,prop:T,align:"center",formType:"Select",relatedContents:Fe==null?void 0:Fe.map(U=>{let Se={};return ye==null||ye.forEach((Le,Pe)=>{Se[Le]=U==null?void 0:U[Pe]}),Se}),options:Fe==null?void 0:Fe.map(U=>({label:U==null?void 0:U[0],value:U==null?void 0:U[0]})),mainKey:!0}):r==null||r.push({label:T,prop:T,align:"center"})})}}else if((a==null?void 0:a[0])==="{")if(((k=he.analyzeSplitToContent(a,"="))==null?void 0:k.length)===2&&((w=(b=he.analyzeSplitToContent(a,"="))==null?void 0:b[1])==null?void 0:w[0])==="["){let de=[];if((($=he.analyzeSplitToContent(a,"="))==null?void 0:$.length)>=2){let Fe=(F=he.analyzeSplitToContent(a,"="))==null?void 0:F[1],ye=(se=(J=he.analyzeSplitToContent(Fe,"|"))==null?void 0:J.filter(T=>T!=="|"))==null?void 0:se.map(T=>((T==null?void 0:T[(T==null?void 0:T.length)-1])==="|"&&(T=T==null?void 0:T.slice(0,(T==null?void 0:T.length)-1)),T));de=ye==null?void 0:ye.map(T=>(T=Ci(T),T))}let De=(Me=(ge=a==null?void 0:a.replace("}",fl))==null?void 0:ge.split(fl))==null?void 0:Me[0];De=(V=De==null?void 0:De.slice(1,De==null?void 0:De.length))==null?void 0:V.split(","),De==null||De.forEach((Fe,ye)=>{(de==null?void 0:de.length)>0&&ye===0?r==null||r.push({label:Fe,prop:Fe,align:"center",formType:"Select",relatedContents:de==null?void 0:de.map(T=>{let ue={};return De==null||De.forEach((U,Se)=>{ue[U]=T==null?void 0:T[Se]}),ue}),options:de==null?void 0:de.map(T=>({label:T==null?void 0:T[0],value:T==null?void 0:T[0]})),mainKey:!0}):r==null||r.push({label:Fe,prop:Fe,align:"center"})})}else(fe=he.analyzeSplitToContent(a,","))==null||fe.forEach(de=>{var De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja,L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va,ne;if((de==null?void 0:de[(de==null?void 0:de.length)-1])===","&&(de=de==null?void 0:de.slice(0,(de==null?void 0:de.length)-1)),(de==null?void 0:de[0])==="{"){let X=he.analyzeSplitToContent(de,"="),Z=X==null?void 0:X[(X==null?void 0:X.length)-1],q=[],Be=[],Je=[],ra="",ba="",ga=[],Aa=[],_a=(De=Z==null?void 0:Z.replace("*",fl))==null?void 0:De.split(fl),Oe=(_a==null?void 0:_a[0])===""?l==null?void 0:l.value:_a==null?void 0:_a[0];Oe=he.analyzeSplitToContent(Oe,")");let Za="";if((Oe==null?void 0:Oe.length)>1&&((Fe=Oe==null?void 0:Oe[0])==null?void 0:Fe[0])!=="&"&&(Za=Oe==null?void 0:Oe[0],(Za==null?void 0:Za[0])!=="@"&&(Za="@"+Za),ba=Za??""),Oe=(ye=Oe==null?void 0:Oe.filter(kl=>(kl==null?void 0:kl[0])==="$"))==null?void 0:ye[0],((T=he.analyzeSplitToContent(Oe,"}"))==null?void 0:T.length)>1&&((U=(ue=he.analyzeSplitToContent(Oe,"}"))==null?void 0:ue[1])==null?void 0:U[0])==="("&&(Za=(Se=he.analyzeSplitToContent(Oe,"}"))==null?void 0:Se[1],(Za==null?void 0:Za[0])!=="@"&&(Za="@"+Za),ba!==""&&(ba=ba+","),ba=ba+Za),(Le=Oe==null?void 0:Oe.slice(1,(Oe==null?void 0:Oe.length)-1))!=null&&Le.includes("$")||(Oe=(Pe=he.analyzeSplitToContent(Oe,"}"))==null?void 0:Pe[0]),(Oe==null?void 0:Oe[0])==="$"&&(Oe=(la=Oe==null?void 0:Oe.replace("{",""))==null?void 0:la.replace("}",":"),Oe=(Da=Oe==null?void 0:Oe.slice(1,Oe==null?void 0:Oe.length))==null?void 0:Da.replaceAll(":","/")),Oe!=null&&Oe.includes("$")){let kl=(le=Oe==null?void 0:Oe.split("$"))==null?void 0:le[0];kl=(ta=kl==null?void 0:kl.split("/"))==null?void 0:ta[0],Oe=kl+"/"+((te=Oe==null?void 0:Oe.split("$"))==null?void 0:te[1])+"/"}q=(Oe==null?void 0:Oe.split("/"))??[];let Ha=(Ee=(ca=_a==null?void 0:_a[1])==null?void 0:ca.replace("{",fl))==null?void 0:Ee.split(fl);if((Ue=(Te=(oe=_a==null?void 0:_a[1])==null?void 0:oe.split("(@"))==null?void 0:Te[0])!=null&&Ue.includes("&&")||(L=(Ja=(oa=_a==null?void 0:_a[1])==null?void 0:oa.split("@"))==null?void 0:Ja[0])!=null&&L.includes("&&")){let kl=(H=_a==null?void 0:_a[1])!=null&&H.includes("(@")?(ve=(me=(Q=_a==null?void 0:_a[1])==null?void 0:Q.split("(@"))==null?void 0:me[0])==null?void 0:ve.split("&&"):(ce=(ea=(da=_a==null?void 0:_a[1])==null?void 0:da.split("@"))==null?void 0:ea[0])==null?void 0:ce.split("&&");ga=kl==null?void 0:kl.map(ja=>{var Ml,$l;return(ja==null?void 0:ja[0])==="*"&&(ja=ja==null?void 0:ja.slice(1,ja==null?void 0:ja.length)),ja=($l=(Ml=ja==null?void 0:ja.replace("{",fl))==null?void 0:Ml.split(fl))==null?void 0:$l[0],(ja==null?void 0:ja[(ja==null?void 0:ja.length)-1])===":"&&(ja=ja==null?void 0:ja.slice(0,(ja==null?void 0:ja.length)-1)),ja=ja==null?void 0:ja.split(":"),ja});let Pl=[];kl==null||kl.forEach((ja,Ml)=>{var $l,Ma;(ja==null?void 0:ja[0])==="*"&&(ja=ja==null?void 0:ja.slice(1,ja==null?void 0:ja.length)),ja=(Ma=($l=ja==null?void 0:ja.replace("{",fl))==null?void 0:$l.split(fl))==null?void 0:Ma[1],(ja==null?void 0:ja[(ja==null?void 0:ja.length)-1])==="}"&&(ja=ja==null?void 0:ja.slice(0,(ja==null?void 0:ja.length)-1)),ja=ja==null?void 0:ja.split(","),Pl.push(Ml===0?(ja==null?void 0:ja.length)-1:ja==null?void 0:ja.length),Aa=[...Aa,...ja]}),Pl=(pa=he.prefixSum(Pl))==null?void 0:pa.map(ja=>ja==null?void 0:ja.total),ga=ga==null?void 0:ga.map((ja,Ml)=>({number:Pl==null?void 0:Pl[Ml],contents:ja}))}let xl=Ha==null?void 0:Ha[0];(xl==null?void 0:xl[(xl==null?void 0:xl.length)-1])===":"&&(xl=xl==null?void 0:xl.slice(0,(xl==null?void 0:xl.length)-1)),Be=(xl==null?void 0:xl.split(":"))??[],Je=((Ca=(Ta=(We=(Ne=Ha==null?void 0:Ha[1])==null?void 0:Ne.replace("}",fl))==null?void 0:We.split(fl))==null?void 0:Ta[0])==null?void 0:Ca.split(","))??[];let Jl=(Va=X==null?void 0:X[0])==null?void 0:Va.slice(1,((Qe=X==null?void 0:X[0])==null?void 0:Qe.length)-2);ba&&ba!==""&&(ra=ji(ba)),(ne=Jl==null?void 0:Jl.split(","))==null||ne.forEach((kl,Pl)=>{var ja,Ml,$l,Ma,rl;((ja=he.analyzeSplitToContent(kl,"@"))==null?void 0:ja.length)>1&&(kl=(Ml=he.analyzeSplitToContent(kl,"@"))==null?void 0:Ml[0],(kl==null?void 0:kl[(kl==null?void 0:kl.length)-1])==="@"&&(kl=kl==null?void 0:kl.slice(0,(kl==null?void 0:kl.length)-1))),r.push({label:kl,prop:kl,align:"center",menus:q,groups:(ga==null?void 0:ga.length)===0?Be:($l=ga==null?void 0:ga.find(sl=>(sl==null?void 0:sl.number)>=Pl))==null?void 0:$l.contents,words:(Aa==null?void 0:Aa.length)===0?(Ma=Je==null?void 0:Je[Pl])==null?void 0:Ma.split(":"):(rl=Aa==null?void 0:Aa[Pl])==null?void 0:rl.split(":"),formType:(q==null?void 0:q.length)>0?"Select":"Input",mainKey:Pl===0,filter:ra,isMainPath:(ga==null?void 0:ga.findIndex(sl=>(sl==null?void 0:sl.number)>=Pl))===0})})}else r.push({label:de,prop:de,align:"center"})});else{let de=(ae=he.analyzeSplitToContent(a,","))==null?void 0:ae.map(De=>((De==null?void 0:De[(De==null?void 0:De.length)-1])===","&&(De=De==null?void 0:De.slice(0,(De==null?void 0:De.length)-1)),De));de==null||de.forEach(De=>{r.push(ft(De,l))})}return r},Zd=(a,l)=>{var v,d,p,y,g;let r=a;if(!a)return;let n="";((v=he.analyzeSplitToContent(a,"}"))==null?void 0:v.length)>1&&(r=(d=he.analyzeSplitToContent(a,"}"))==null?void 0:d[0],n=(p=he.analyzeSplitToContent(a,"}"))==null?void 0:p[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 t=[],s=[];return t.push({label:"排序",prop:"sort"}),t.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(y=he.analyzeSplitToContent(r,","))==null||y.forEach(c=>{var D;(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==null?void 0:c[0])==="{"?(D=Co(c,l))==null||D.forEach(M=>{t.push(M)}):t.push(ft(c,l))}),t!=null&&t.some(c=>{var D;return(D=c==null?void 0:c.prop)==null?void 0:D.includes("@")})&&(t=t==null?void 0:t.filter(c=>{var D;return!((D=c==null?void 0:c.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=he.analyzeSplitToContent(n,","))==null||g.forEach(c=>{var D;(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==null?void 0:c[0])==="{"?(D=Co(c,l))==null||D.forEach(M=>{s.push(M)}):s.push(ft(c,l))})),{columns:t,secondColumns:s}},un=a=>{var l,r,n,t,s;if(a!=null&&a.includes("@Filter")||a!=null&&a.includes("@Condition")||a!=null&&a.includes("@If"))return a;{let v=(r=(l=a==null?void 0:a.replace("(",fl))==null?void 0:l.split(fl))==null?void 0:r[1],d=(t=(n=a==null?void 0:a.replace("(",fl))==null?void 0:n.split(fl))==null?void 0:t[0];return v=v==null?void 0:v.slice(0,(v==null?void 0:v.length)-1),v=(s=he.analyzeSplitToContent(v,","))==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==null?void 0:p[0])==="("&&(p=p==null?void 0:p.slice(1,(p==null?void 0:p.length)-1)),d+p)),v=v==null?void 0:v.join(","),a!=null&&a.includes("@Quote")&&(v!=null&&v.includes("@QuoteType")||(v=v===""?v+"@QuoteType=Manual":v+",@QuoteType=Manual"),v!=null&&v.includes("@QuoteSonSync")||(v=v===""?v+"@QuoteSonSync=No":v+",@QuoteSonSync=No"),v!=null&&v.includes("@QuoteFatherSync")||(v=v===""?v+"@QuoteFatherSync=Yes":v+",@QuoteFatherSync=Yes")),v}},ns=a=>{let l=a==null?void 0:a.map(r=>{var n,t;return{menus:r==null?void 0:r.menus,content:((n=r==null?void 0:r.menus)==null?void 0:n.join("/"))+fl+((t=r==null?void 0:r.groups)==null?void 0:t.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,t;return{menus:(n=r==null?void 0:r.split(fl))==null?void 0:n[0],groups:((t=r==null?void 0:r.split(fl))==null?void 0:t[1])??[]}}),l},is=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=he.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=un(n),n)),l==null?void 0:l.join(",")},lc=(a,l,r="")=>{var j,E,x,k,b,w,$,F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja,L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va,ne;let n=[],t=[],s=[],v="",d="",p="",y=[],g=[],c=[],D="";if(((j=a==null?void 0:a[0])==null?void 0:j[0])!=="*"&&((E=a==null?void 0:a[0])==null?void 0:E[0])!=="$"&&!((x=a==null?void 0:a[0])!=null&&x.includes("$")))return;((k=a==null?void 0:a[0])==null?void 0:k[0])!=="*"&&((b=a==null?void 0:a[0])==null?void 0:b[0])!=="$"&&(v=(w=he.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:w[0],(v==null?void 0:v[0])!=="@"&&(v="@"+v),v=ji(v),p=($=he.analyzeSplitToContent(a==null?void 0:a[0],")"))==null?void 0:$[1],(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.replaceAll(":","/"));let S=he.analyzeSplitToContent(a==null?void 0:a[0],":");if(n=(F=S==null?void 0:S.filter(X=>(X==null?void 0:X[0])!=="{"&&(X==null?void 0:X[0])!=="["))==null?void 0:F.join(""),d=(J=a==null?void 0:a[0])==null?void 0:J.replace(n,""),(n==null?void 0:n[0])==="("&&(n=""),D=(se=S==null?void 0:S.filter(X=>(X==null?void 0:X[0])!=="["))==null?void 0:se.join(""),D=(ge=a==null?void 0:a[0])==null?void 0:ge.replace(D,""),d=d==null?void 0:d.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)),((Me=he.analyzeSplitToContent(d,"@"))==null?void 0:Me.length)>1&&(v=(V=he.analyzeSplitToContent(d,"@"))==null?void 0:V[1],(v==null?void 0:v[(v==null?void 0:v.length)-1])===":"&&(v=v==null?void 0:v.slice(0,(v==null?void 0:v.length)-1)),v="@"+v,v=un(v),d=(fe=he.analyzeSplitToContent(d,"@"))==null?void 0:fe[0],d=d==null?void 0:d.slice(0,(d==null?void 0:d.length)-1)),((ae=he.analyzeSplitToContent(n,"@"))==null?void 0:ae.length)>1){v!==""&&(v=v+",");let X=(de=he.analyzeSplitToContent(n,"@"))==null?void 0:de[1];X="@"+X,X=un(X),v=v+X,n=(De=he.analyzeSplitToContent(n,"@"))==null?void 0:De[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(":"),(d==null?void 0:d[(d==null?void 0:d.length)-1])===":"&&(d=d==null?void 0:d.slice(0,(d==null?void 0:d.length)-1)),r!==""){let X=(Fe=he.analyzeSplitToContent(r,")"))==null?void 0:Fe[0],Z=(ye=he.analyzeSplitToContent(r,"@"))==null?void 0:ye[1];p=(ue=(T=he.analyzeSplitToContent(r,"@"))==null?void 0:T[0])==null?void 0:ue.replace(X,""),(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)),X=is(X),Z=is(Z);let q=X??"";if(q!==""&&(q=q+","),q=q+Z,(q==null?void 0:q[(q==null?void 0:q.length)-1])===","&&(q=q==null?void 0:q.slice(0,(q==null?void 0:q.length)-1)),q!==""&&v!==""&&(v=v+","),v=v+q,(p==null?void 0:p[0])==="$"&&(p=p==null?void 0:p.slice(1,p==null?void 0:p.length)),p=(U=he.analyzeSplitToContent(p,":"))==null?void 0:U.filter((Be,Je)=>{var ra;return!((Be==null?void 0:Be[0])==="{"&&Je===((ra=he.analyzeSplitToContent(p,":"))==null?void 0:ra.length)-1)}),p=p==null?void 0:p.join(""),(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)),v!=null&&v.includes("@Sync")||(v=v===""?v+"@Sync=(Yes,Yes)":v+",@Sync=(Yes,Yes)"),p!=null&&p.includes("$")){let Be=(Le=(Se=p==null?void 0:p.replace("*",fl))==null?void 0:Se.split(fl))==null?void 0:Le[1],Je=(la=(Pe=p==null?void 0:p.replace("*",fl))==null?void 0:Pe.split(fl))==null?void 0:la[0];Je=Je==null?void 0:Je.split("$"),Je=((le=(Da=Je==null?void 0:Je[0])==null?void 0:Da.split(":"))==null?void 0:le[0])+":"+(Je==null?void 0:Je[1])+":",p=Je+"*"+Be}else p=(ta=p==null?void 0:p.replaceAll("{",""))==null?void 0:ta.replaceAll("}","")}v!==""&&v&&(v="("+v+")"),v=p+v,((te=he.analyzeSplitToContent(d,"}"))==null?void 0:te.length)>1&&(d=(ca=he.analyzeSplitToContent(d,"}"))==null?void 0:ca.filter(X=>(X==null?void 0:X[0])!=="@"),d=d==null?void 0:d.join(""));let K=Zd(d,l);s=d===""?[]:(K==null?void 0:K.columns)??[],c=he.getColumnChild(s);let I=he.getColumnChild(s);s!=null&&s.some(X=>{var Z;return Array.isArray(X==null?void 0:X.children)&&((Z=X==null?void 0:X.children)==null?void 0:Z.length)>0})&&(s=[s]),t=D?Ci(D):[],!(t!=null&&t.every(X=>Array.isArray(X)))&&(t==null?void 0:t.length)>0&&(t=[t]),(t==null?void 0:t.length)>0&&(Array.isArray(t==null?void 0:t[0])&&((Ee=t==null?void 0:t[0])!=null&&Ee.every(X=>Array.isArray(X)))?t=t==null?void 0:t.map((X,Z)=>(X=X.map((q,Be)=>(q.unshift("{}"),q.unshift((Be+1).toString()),q)),X)):t=t==null?void 0:t.map((X,Z)=>(X.unshift("{}"),X.unshift((Z+1).toString()),X))),K!=null&&K.secondColumns&&((oe=K==null?void 0:K.secondColumns)==null?void 0:oe.length)>0&&((t==null?void 0:t.length)>0?t=t==null?void 0:t.map((X,Z)=>{var q,Be;return Array.isArray(X==null?void 0:X[0])?X=X==null?void 0:X.map((Je,ra)=>{var ba,ga;return Je.unshift((ga=(ba=K==null?void 0:K.secondColumns)==null?void 0:ba[ra])==null?void 0:ga.prop),Je}):X.unshift((Be=(q=K==null?void 0:K.secondColumns)==null?void 0:q[Z])==null?void 0:Be.prop),X}):t=(Te=K==null?void 0:K.secondColumns)==null?void 0:Te.map((X,Z)=>(X=[X==null?void 0:X.label],X.push(Z),X)),s.unshift({label:"",prop:"disabled",sortable:!1})),c=c==null?void 0:c.map(X=>{var Z,q;return{menus:X==null?void 0:X.menus,content:((Z=X==null?void 0:X.menus)==null?void 0:Z.join("/"))+fl+((q=X==null?void 0:X.groups)==null?void 0:q.join("/"))}});let R=[];if(((oa=(Ue=v==null?void 0:v.replace("(",fl))==null?void 0:Ue.split(fl))==null?void 0:oa[0])!==""&&(R=(L=(Ja=v==null?void 0:v.replace("(",fl))==null?void 0:Ja.split(fl))==null?void 0:L[0],R=[R],R=R==null?void 0:R.map(X=>{var q,Be,Je;let Z=X==null?void 0:X.split("*");return{menus:(q=Z==null?void 0:Z[0])==null?void 0:q.split(":"),content:((Be=Z==null?void 0:Z[0])==null?void 0:Be.replaceAll(":","/"))+fl+((Je=Z==null?void 0:Z[1])==null?void 0:Je.replaceAll(":","/"))}}),c=[...c,...R]),c=c==null?void 0:c.filter(X=>{var Z;return(X==null?void 0:X.menus)&&((Z=X==null?void 0:X.menus)==null?void 0:Z.length)>0}),c=c==null?void 0:c.map(X=>X==null?void 0:X.content),c=[...new Set(c)],c=c==null?void 0:c.map(X=>{var Z,q;return{menus:(Z=X==null?void 0:X.split(fl))==null?void 0:Z[0],groups:((q=X==null?void 0:X.split(fl))==null?void 0:q[1])??[]}}),y=I==null?void 0:I.filter(X=>{var Z;return(X==null?void 0:X.filter)&&((Z=X==null?void 0:X.filter)==null?void 0:Z.includes("@Sync"))}),(y==null?void 0:y.length)>0&&(y=y==null?void 0:y.filter(X=>{var Z,q,Be,Je;return(Je=(Be=(q=(Z=he.analyzeSplitToContent(X==null?void 0:X.filter,","))==null?void 0:Z.find(ra=>ra==null?void 0:ra.includes("@Sync")))==null?void 0:q.split(","))==null?void 0:Be[0])==null?void 0:Je.includes("Yes")}),y=ns(y)),g=I==null?void 0:I.filter(X=>{var Z;return(X==null?void 0:X.filter)&&((Z=X==null?void 0:X.filter)==null?void 0:Z.includes("@Sync"))}),(g==null?void 0:g.length)>0&&(g=g==null?void 0:g.filter(X=>{var Z,q,Be,Je;return(Je=(Be=(q=(Z=he.analyzeSplitToContent(X==null?void 0:X.filter,","))==null?void 0:Z.find(ra=>ra==null?void 0:ra.includes("@Sync")))==null?void 0:q.split(","))==null?void 0:Be[1])==null?void 0:Je.includes("Yes")}),g=ns(g)),v!==""&&(v!=null&&v.includes("@Sync"))&&(v==null?void 0:v[0])!=="("){let X=(H=v==null?void 0:v.replace("(",fl))==null?void 0:H.split(fl),Z=X==null?void 0:X[1];if(Z=Z==null?void 0:Z.slice(0,(Z==null?void 0:Z.length)-1),Z=he.analyzeSplitToContent(Z,","),(ve=(me=(Q=Z==null?void 0:Z.find(q=>q==null?void 0:q.includes("@Sync")))==null?void 0:Q.split(","))==null?void 0:me[0])!=null&&ve.includes("Yes")){let q=X==null?void 0:X[0];q=[{menus:(ea=(da=q==null?void 0:q.split("*"))==null?void 0:da[0])==null?void 0:ea.replaceAll(":","/"),groups:((pa=(ce=q==null?void 0:q.split("*"))==null?void 0:ce[1])==null?void 0:pa.split(":"))??[]}],y=[...y,...q]}if((Ta=(We=(Ne=Z==null?void 0:Z.find(q=>q==null?void 0:q.includes("@Sync")))==null?void 0:Ne.split(","))==null?void 0:We[1])!=null&&Ta.includes("Yes")){let q=X==null?void 0:X[0];q=[{menus:(Qe=(Ca=q==null?void 0:q.split("*"))==null?void 0:Ca[0])==null?void 0:Qe.replaceAll(":","/"),groups:((ne=(Va=q==null?void 0:q.split("*"))==null?void 0:Va[1])==null?void 0:ne.split(":"))??[]}],g=[...g,...q]}}return{groupName:n,tableColumns:s,tableFilter:v,tableContents:t,columns:(K==null?void 0:K.secondColumns)??[],relatedQuotes:c,fatherSyncContents:y,sonSyncContents:g}},rc=(a,l)=>(a=a==null?void 0:a.map((r,n)=>{var t,s,v,d;if(Array.isArray(r))r=r==null?void 0:r.map(p=>{var y,g,c,D;return p!=null&&p.isMainPath||(((y=p==null?void 0:p.children)==null?void 0:y.length)>0?p.children=rc(p.children,l):((g=p==null?void 0:p.menus)==null?void 0:g.length)>0&&!((c=r==null?void 0:r[0])!=null&&c.isMainPath)&&(p.menus=(D=p.menus)==null?void 0:D.map((M,S)=>{var K,I;return((K=p.menus)==null?void 0:K.length)-1===S&&M===""&&(l==null?void 0:l.parentContent)+"/"!==((I=p.menus)==null?void 0:I.join("/"))&&(M=l==null?void 0:l.value),p}),p.bindMenus=p.menus)),p});else{if(n===0&&((t=r.menus)==null?void 0:t.length)>0&&(r.mainKey=!0),r!=null&&r.isMainPath)return r;((s=r.menus)==null?void 0:s.length)>0&&!((v=a==null?void 0:a[0])!=null&&v.isMainPath)&&(r.menus=(d=r.menus)==null?void 0:d.map((p,y)=>{var g,c;return((g=r.menus)==null?void 0:g.length)-1===y&&p===""&&(l==null?void 0:l.parentContent)+"/"!==((c=r.menus)==null?void 0:c.join("/"))&&(p=l==null?void 0:l.value),p}),r.bindMenus=r.menus)}return r}),a),Qd=(a,l)=>(a=a==null?void 0:a.map(r=>((r==null?void 0:r.key)==="header"&&(r.contents=rc(r.contents,l)),r)),a),ht=(a,l)=>{let r=a;return Array.isArray(r==null?void 0:r[0])?r=r==null?void 0:r.map(n=>(n=ht(n,l),n)):r=r==null?void 0:r.map(n=>{var t,s;return n!=null&&n.children&&((t=n==null?void 0:n.children)==null?void 0:t.length)>0?n.children=ht(n==null?void 0:n.children,l):n!=null&&n.words&&((s=n==null?void 0:n.words)==null?void 0:s.length)>0&&(l!=null&&l.find(v=>{var d,p,y,g;return((g=(d=n==null?void 0:n.prop)==null?void 0:d.split("."))==null?void 0:g[((y=(p=n==null?void 0:n.prop)==null?void 0:p.split("."))==null?void 0:y.length)-1])===v}))&&(n.mainKey=!0),n}),r};let gr="$R";const ep=A.useUnit(A.pinia),{selectTitle:Jr}=A.storeToRefs(ep),vn=[{key:"@MaxRow",value:"onNumSlice",order:1},{key:"@MaxColumn",value:"onMaxColumn",order:1},{key:"@EditRead",value:"onEditRead",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:"@MainPam",value:"onMainTagContents",order:3},{key:"@Button",value:"onButtonContents",order:1},{key:"@Related",value:"onRelated",order:1},{key:"@RowNum",value:"onRowNum",order:1},{key:"@FixRow",value:"onFixRow",order:1},{key:"@ReqItem",value:"onReqItem",order:1},{key:"@Condition",value:"onConditionContent",order:1},{key:"@Tab",value:"onTabs",order:1},{key:"@SinChoice",value:"onSinChoice",order:1},{key:"@TextSize",value:"onTextSize",order:1},{key:"@TextRGBA",value:"onTextRGBA",order:1},{key:"@Position",value:"onPosition",order:4},{key:"@Size",value:"onSize",order:4},{key:"@ShowType",value:"onShowType",order:1},{key:"@StepName",value:"onStepName",order:1},{key:"@Step",value:"onStep",order:1},{key:"@BackGround",value:"onBackGround",order:1}];var ri=(a=>(a[a.ORDINARY=1]="ORDINARY",a[a.BLOCK=2]="BLOCK",a[a.TEXT=3]="TEXT",a))(ri||{});const 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;return l.push({key:"backGround",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},lp=a=>{const l=ic(a==null?void 0:a.filter);return l?oc(a==null?void 0:a.contents,{position:l}):a==null?void 0:a.contents},rp=a=>{const l=ic(a==null?void 0:a.filter);return l?oc(a==null?void 0:a.contents,{size:l}):a==null?void 0:a.contents},np=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},ip=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},op=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 t;return(n==null?void 0:n.key)==="tableContents"&&(n.contents=(t=n.contents)==null?void 0:t.slice(0,parseInt(a==null?void 0:a.filter))),n})},tp=async a=>{var l,r,n,t,s,v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge,Me,V;if((a==null?void 0:a.filter)==="Random")return(l=a==null?void 0:a.contents)==null?void 0:l.map(ae=>((ae==null?void 0:ae.key)==="tableContents"&&(ae.contents=he.shuffle(ae.contents)),ae));if((a==null?void 0:a.filter)==="Auto"){let fe=(n=(r=a==null?void 0:a.contents)==null?void 0:r.find(Se=>(Se==null?void 0:Se.key)==="header"))==null?void 0:n.contents;Array.isArray(fe==null?void 0:fe[0])&&(fe=fe==null?void 0:fe[0]),fe=he.getColumnChild(fe);let ae=fe==null?void 0:fe.filter(Se=>(Se==null?void 0:Se.filter)&&(Se==null?void 0:Se.filter)!==""),de=new Map,De=[];ae==null||ae.forEach(Se=>{var Le,Pe;de.get((Le=Se==null?void 0:Se.menus)==null?void 0:Le.join("/"))||(de.set((Pe=Se==null?void 0:Se.menus)==null?void 0:Pe.join("/"),Se),De.push(Se))});let Fe=(s=(t=Jr==null?void 0:Jr.value)==null?void 0:t.find(Se=>(Se==null?void 0:Se.condition)==="child"))==null?void 0:s.value,ye=De==null?void 0:De.map(Se=>{var Le,Pe,la;return Se=(Le=Se==null?void 0:Se.menus)==null?void 0:Le.join("/"),(Se==null?void 0:Se[(Se==null?void 0:Se.length)-1])==="/"&&((la=(Pe=Jr==null?void 0:Jr.value)==null?void 0:Pe.find(Da=>(Da==null?void 0:Da.condition)==="child"))==null?void 0:la.parentContent)+"/"!==Se?Se=Se+Fe:(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}),T=De==null?void 0:De.map(Se=>Se==null?void 0:Se.groups),ue=ye==null?void 0:ye.map(async Se=>{let Le=await Kr(Se,!1);return{path:Se,contents:Le}});ue=await Promise.all(ue);let U=ue==null?void 0:ue.map((Se,Le)=>{var la,Da,le,ta,te,ca,Ee;let Pe=(la=Se==null?void 0:Se.contents)==null?void 0:la.filter(oe=>{var Te,Ue;return(oe==null?void 0:oe.name)===((Ue=T==null?void 0:T[Le])==null?void 0:Ue[((Te=T==null?void 0:T[Le])==null?void 0:Te.length)-1])});return Pe=(ta=(le=(Da=Pe==null?void 0:Pe[0])==null?void 0:Da.compData)==null?void 0:le.find(oe=>(oe==null?void 0:oe.key)==="tableContents"))==null?void 0:ta.contents,(Se==null?void 0:Se.path)===((ca=(te=Jr==null?void 0:Jr.value)==null?void 0:te.find(oe=>(oe==null?void 0:oe.condition)==="child"))==null?void 0:ca.parentContent)&&(Pe=((Ee=Pe==null?void 0:Pe.map(oe=>{for(let Te in oe)if(oe[Te]===Fe)return oe}))==null?void 0:Ee.filter(oe=>oe))??[]),Pe??[]});if(U=U==null?void 0:U.map(Se=>(Se=Se==null?void 0:Se.map(Le=>{var la;let Pe={};for(let Da in Le)if(ae!=null&&ae.find(le=>{var ta,te;return((te=(ta=le==null?void 0:le.words)==null?void 0:ta[0])==null?void 0:te.replaceAll("'",""))===Da})){let le=(la=ae==null?void 0:ae.find(ta=>{var te,ca;return((ca=(te=ta==null?void 0:ta.words)==null?void 0:te[0])==null?void 0:ca.replaceAll("'",""))===Da}))==null?void 0:la.prop;Pe[le]=Le==null?void 0:Le[Da]}return Pe}),Se)),U=he.cartesianProduct(U),Array.isArray(U==null?void 0:U[0])&&(U=U==null?void 0:U[0]),(U==null?void 0:U.length)>0&&((c=(d=(v=ae==null?void 0:ae[0])==null?void 0:v.menus)==null?void 0:d.join("/"))==null?void 0:c[((g=(y=(p=ae==null?void 0:ae[0])==null?void 0:p.menus)==null?void 0:y.join("/"))==null?void 0:g.length)-1])==="/")return(D=a==null?void 0:a.contents)==null?void 0:D.map(Le=>{var Pe;return(Le==null?void 0:Le.key)==="tableContents"&&(U==null?void 0:U.length)>0&&(Le.contents=((Pe=Le.contents)==null?void 0:Pe.length)>0?Le.contents:U),Le})}if((a==null?void 0:a.filter)==="Manual"){let fe=[],ae=[],de=(S=(M=a==null?void 0:a.contents)==null?void 0:M.find(T=>(T==null?void 0:T.key)==="filter"))==null?void 0:S.contents;(de==null?void 0:de[(de==null?void 0:de.length)-1])===")"?de=(I=(K=de==null?void 0:de.replace("(",gr))==null?void 0:K.split(gr))==null?void 0:I[0]:de="",de!==""&&(fe=((j=(R=de==null?void 0:de.split("*"))==null?void 0:R[0])==null?void 0:j.split(":"))??[],ae=((w=(b=(k=(x=(E=de==null?void 0:de.split("*"))==null?void 0:E[1])==null?void 0:x.replace("{",gr))==null?void 0:k.split(gr))==null?void 0:b[0])==null?void 0:w.split(":"))??[]);let De=(F=($=a==null?void 0:a.contents)==null?void 0:$.find(T=>(T==null?void 0:T.key)==="filter"))==null?void 0:F.contents;De=(se=(J=De==null?void 0:De.replace("(",gr))==null?void 0:J.split(gr))==null?void 0:se[1],De=De==null?void 0:De.slice(0,(De==null?void 0:De.length)-1);let Fe=(ge=a==null?void 0:a.contents)==null?void 0:ge.map(T=>{var ue,U,Se,Le,Pe,la,Da,le,ta;return(T==null?void 0:T.key)==="header"&&((ue=T==null?void 0:T.contents)!=null&&ue.every(te=>(te==null?void 0:te.mainKey)!==!0)&&Array.isArray(T==null?void 0:T.contents)&&!Array.isArray((U=T==null?void 0:T.contents)==null?void 0:U[0])?T.contents=(Se=T==null?void 0:T.contents)==null?void 0:Se.map((te,ca)=>{var Ee,oe,Te;return te!=null&&te.isMainPath||(ca===0?(te.mainKey=!0,te.formType="Select",te.bindMenus=fe,te.groups=((Ee=te.groups)==null?void 0:Ee.length)===0?ae:te.groups,te.words=((oe=te.words)==null?void 0:oe.length)===0?[te==null?void 0:te.prop]:te.words,te.filter=De,(!(te!=null&&te.menus)||((Te=te==null?void 0:te.menus)==null?void 0:Te.length)===0)&&(te.menus=fe)):(te.mainKey=!1,te.bindMenus=fe)),te}):Array.isArray((Le=T==null?void 0:T.contents)==null?void 0:Le[0])&&((Da=(la=(Pe=T==null?void 0:T.contents)==null?void 0:Pe[0])==null?void 0:la.filter(()=>(fe==null?void 0:fe.length)>0))==null?void 0:Da.length)>0&&(T.contents[0]=(ta=(le=T==null?void 0:T.contents)==null?void 0:le[0])==null?void 0:ta.map((te,ca)=>{var Ee,oe,Te;return te!=null&&te.isMainPath||(ca===0?(te.mainKey=!0,te.formType="Select",te.bindMenus=fe,te.groups=((Ee=te.groups)==null?void 0:Ee.length)===0?ae:te.groups,te.words=((oe=te.words)==null?void 0:oe.length)===0?[te==null?void 0:te.prop]:te.words,te.filter=De,(!(te!=null&&te.menus)||Array.isArray(te==null?void 0:te.menus)&&((Te=te==null?void 0:te.menus)==null?void 0:Te.length)===0)&&(fe==null?void 0:fe.length)>0&&(te.menus=fe)):(te.mainKey=!1,te.bindMenus=fe)),te}))),T}),ye=(Me=Fe==null?void 0:Fe.find(T=>(T==null?void 0:T.key)==="header"))==null?void 0:Me.contents;if(Array.isArray(ye==null?void 0:ye[0])&&(ye=ye==null?void 0:ye[0]),ye=he.getColumnChild(ye),ye!=null&&ye.some(T=>{var ue,U;return((U=T==null?void 0:T.menus)==null?void 0:U[((ue=T==null?void 0:T.menus)==null?void 0:ue.length)-1])===""})){let T=(V=Jr==null?void 0:Jr.value)==null?void 0:V.find(ue=>(ue==null?void 0:ue.condition)==="child");Fe=Qd(Fe,T)}return Fe}return a==null?void 0:a.contents},sp=async a=>{if((a==null?void 0:a.filter)==="Ordin"){let l=a==null?void 0:a.contents;return l.push({key:"enableWrap",contents:1}),l}if((a==null?void 0:a.filter)==="Block"){let l=a==null?void 0:a.contents;return l.push({key:"enableWrap",contents:2}),l}if((a==null?void 0:a.filter)==="Text"){let l=a==null?void 0:a.contents;return l.push({key:"enableWrap",contents:3}),l}return a==null?void 0:a.contents},cp=a=>{var n,t,s,v,d,p,y,g,c,D,M,S;let l=a==null?void 0:a.filter;if(l!=null&&l.includes("*")&&(l="({"+((t=(n=l==null?void 0:l.replace(":",gr))==null?void 0:n.split(gr))==null?void 0:t[1])),l=(s=l==null?void 0:l.replaceAll("{",""))==null?void 0:s.replaceAll("}",""),(d=(v=l==null?void 0:l.split("="))==null?void 0:v[1])!=null&&d.includes("$")){(l==null?void 0:l[0])==="("&&(l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1));let K=(p=l==null?void 0:l.split("="))==null?void 0:p[0],I=(y=l==null?void 0:l.split("="))==null?void 0:y[1];(g=I==null?void 0:I.slice(1,I==null?void 0:I.length))!=null&&g.includes("$")&&(I=(M=(D=(c=Jr==null?void 0:Jr.value)==null?void 0:c.filter(R=>(R==null?void 0:R.condition)==="child"))==null?void 0:D[0])==null?void 0:M.value),l=K+"="+I}if((l==null?void 0:l[0])!=="("&&(l="("+l+")"),l.slice(1,(l==null?void 0:l.length)-1)==="undefined")return a==null?void 0:a.contents;let r=he.calculatorAndToOr(l);if((r==null?void 0:r.length)>0){let K=[];return r==null||r.forEach(R=>{let j={};for(let E in R){let x=E;x!=null&&x.includes("[")||(j[x]=R[E])}K.push(j)}),(S=a==null?void 0:a.contents)==null?void 0:S.map(R=>{var E,x,k;let j=(x=(E=a==null?void 0:a.contents)==null?void 0:E.find(b=>(b==null?void 0:b.key)==="header"))==null?void 0:x.contents;if(j=(k=he.getEqualChild(j))==null?void 0:k.filter(b=>(b==null?void 0:b.label)!=="操作"),(R==null?void 0:R.key)==="tableContents"){let w=he.tableToForm(R==null?void 0:R.contents,j);K==null||K.forEach($=>{var F,J;for(let se in $)!((F=w==null?void 0:w[0])!=null&&F.find(ge=>{var Me;return(ge==null?void 0:ge.key)===se||((Me=ge==null?void 0:ge.key)==null?void 0:Me.includes(se))}))&&!(w!=null&&w.find(ge=>{var Me;return(ge==null?void 0:ge.key)===se||((Me=ge==null?void 0:ge.key)==null?void 0:Me.includes(se))}))||(((J=$[se])==null?void 0:J[0])!=="!"?w=w==null?void 0:w.filter(ge=>{var Me,V;return((Me=ge==null?void 0:ge.find(fe=>{var ae;return(fe==null?void 0:fe.key)===se||((ae=fe==null?void 0:fe.key)==null?void 0:ae.includes(se))}))==null?void 0:Me.value)===$[se]||Array.isArray($==null?void 0:$[se])&&((V=$==null?void 0:$[se])==null?void 0:V.find(fe=>{var ae;return((ae=ge==null?void 0:ge.find(de=>{var De;return(de==null?void 0:de.key)===se||((De=de==null?void 0:de.key)==null?void 0:De.includes(se))}))==null?void 0:ae.value)===fe}))}):w=w==null?void 0:w.filter(ge=>{var Me;return((Me=ge==null?void 0:ge.find(V=>{var fe;return(V==null?void 0:V.key)===se||((fe=V==null?void 0:V.key)==null?void 0:fe.includes(se))}))==null?void 0:Me.value)!==$[se]}))}),(w==null?void 0:w.length)===0?R.contents=[]:R.contents=w==null?void 0:w.map($=>{let F={};return $==null||$.forEach(J=>{F[J==null?void 0:J.key]=J==null?void 0:J.value}),F})}return R})}return a==null?void 0:a.contents},up=a=>a==null?void 0:a.contents,dp=a=>a==null?void 0:a.contents,pp=a=>{var l,r,n,t;if((a==null?void 0:a.filter)!==""&&(a!=null&&a.filter)){let s=(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(t=a==null?void 0:a.contents)==null?void 0:t.map(d=>((d==null?void 0:d.key)==="header"&&(d.contents=ht(d.contents,s)),d))}return a==null?void 0:a.contents},fp=a=>{var r,n,t,s,v;let l=(a==null?void 0:a.filter)??"";if(l!==""){let d=(n=(r=l==null?void 0:l.replace("(",gr))==null?void 0:r.split(gr))==null?void 0:n[1];d=d==null?void 0:d.slice(0,(d==null?void 0:d.length)-1),(d==null?void 0:d[(d==null?void 0:d.length)-1])===")"&&(d=d==null?void 0:d.slice(1,(d==null?void 0:d.length)-1)),d=(t=he.analyzeSplitToContent(d,","))==null?void 0:t.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 p=d==null?void 0:d[0];(p==null?void 0:p[0])==="("&&(p=p==null?void 0:p.slice(1,(p==null?void 0:p.length)-1));let y=(d==null?void 0:d[1])??"Up",g=(s=a==null?void 0:a.contents)==null?void 0:s.map(c=>{var D,M;return y==="Up"?(c==null?void 0:c.key)==="extraButton"&&(c.contents=(D=p==null?void 0:p.split(","))==null?void 0:D.map(S=>({label:S,prop:S}))):y==="Line"&&(c==null?void 0:c.key)==="rowButton"&&(c.contents=(M=p==null?void 0:p.split(","))==null?void 0:M.map(S=>({label:S,prop:S}))),c});if(y==="Bottom"||y==="Down"){let c=(v=p==null?void 0:p.split(","))==null?void 0:v.map(D=>({label:D,prop:D}));g.push({key:"bottomButton",contents:c})}return g}return a==null?void 0:a.contents},hp=a=>a==null?void 0:a.contents,vp=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(t=>{var s;return(t==null?void 0:t.key)==="rowButton"&&(t.contents=(s=l==null?void 0:l.split(","))==null?void 0:s.map(v=>({label:v,prop:v}))),t}):a==null?void 0:a.contents},mp=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,t=(r=l==null?void 0:l.split(","))==null?void 0:r.map(s=>({label:s,prop:s}));return n.push({key:"bottomButton",contents:t}),n}return a==null?void 0:a.contents},yp=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(t=>(t.isNoClick=!0,t))),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},gp=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(t=>{var s;return(t==null?void 0:t.key)==="formContent"&&(t.contents=(s=t.contents)==null?void 0:s.map(v=>(v.width=r,v))),t})}return a==null?void 0:a.contents},bp=a=>{var l,r,n,t;if(((l=a==null?void 0:a.filter)==null?void 0:l[0])!=="["){const s=parseInt(a==null?void 0:a.filter);return!s||Number.isNaN(s)?a==null?void 0:a.contents:(r=a==null?void 0:a.contents)==null?void 0:r.map(d=>{var p;return(d==null?void 0:d.key)==="formContent"&&(d.contents=(p=d.contents)==null?void 0:p.map(y=>(y.width=s,y))),d})}if(((n=a==null?void 0:a.filter)==null?void 0:n[0])==="["){let s=Ci(a==null?void 0:a.filter),v=Array.isArray(s)?s.map(p=>parseInt(p)).filter(p=>!!p&&!Number.isNaN(p)):[];return v.length?(t=a==null?void 0:a.contents)==null?void 0:t.map(p=>{if((p==null?void 0:p.key)==="formContent"){const y=p.contents??[];p.contents=y.map((g,c)=>{const D=c+1;let M=0,S=0;for(let I=0;I<v.length;I++){if(S+=v[I],D<=S){M=I;break}I===v.length-1&&(M=v.length-1)}const K=v[M]||v[v.length-1]||1;return g.width=K,g})}return p}):a==null?void 0:a.contents}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;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(t=>{var s,v,d;return(t==null?void 0:t.key)==="header"&&(Array.isArray((s=t==null?void 0:t.contents)==null?void 0:s[0])?t.contents[0]=(d=t.contents[0])==null?void 0:d.map(p=>(r!=null&&r.find(y=>y===(p==null?void 0:p.prop))&&(p.fixed="left"),p)):t.contents=(v=t.contents)==null?void 0:v.map(p=>(r!=null&&r.find(y=>y===(p==null?void 0:p.prop))&&(p.fixed="left"),p))),t})}return a==null?void 0:a.contents},xp=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=s=>(r!=null&&r.find(v=>v===(s==null?void 0:s.prop))&&(s.required=!0),s!=null&&s.children&&Array.isArray(s.children)&&(s.children=s.children.map(v=>n(v))),s);return(l=a==null?void 0:a.contents)==null?void 0:l.map(s=>{var v,d,p;return(s==null?void 0:s.key)==="header"&&(Array.isArray((v=s==null?void 0:s.contents)==null?void 0:v[0])?s.contents[0]=(p=s.contents[0])==null?void 0:p.map(y=>n(y)):s.contents=(d=s.contents)==null?void 0:d.map(y=>n(y))),s})}return a==null?void 0:a.contents},wp=async a=>{var n,t,s,v,d,p,y,g,c,D,M,S,K,I,R,j,E;const l=A.useUnit(A.pinia),{chooseTitle:r}=A.storeToRefs(l);if((a==null?void 0:a.filter)==="true"){let x=await Kr(((t=(n=r==null?void 0:r.value)==null?void 0:n[0])==null?void 0:t.parentContent)??((v=(s=r==null?void 0:r.value)==null?void 0:s[0])==null?void 0:v.relatedContent),!1),k=(p=(d=r==null?void 0:r.value)==null?void 0:d[0])==null?void 0:p.value;(g=(y=x==null?void 0:x[0])==null?void 0:y.compData)!=null&&g.find(F=>(F==null?void 0:F.key)==="header")?x=(c=x==null?void 0:x[0])==null?void 0:c.compData:x=(M=(D=x==null?void 0:x.filter(F=>{var J;return(J=F==null?void 0:F.compData)==null?void 0:J.find(se=>(se==null?void 0:se.key)==="header")}))==null?void 0:D[0])==null?void 0:M.compData;let b=(S=x==null?void 0:x.find(F=>(F==null?void 0:F.key)==="header"))==null?void 0:S.contents;Array.isArray(b==null?void 0:b[0])&&(b=b==null?void 0:b[0]),b=((K=b==null?void 0:b.find(F=>F==null?void 0:F.isMainKey))==null?void 0:K.prop)??((I=b==null?void 0:b[0])==null?void 0:I.prop);let w=(j=(R=x==null?void 0:x.find(F=>(F==null?void 0:F.key)==="tableContents"))==null?void 0:R.contents)==null?void 0:j.find(F=>(F==null?void 0:F[b])===k);return(E=a==null?void 0:a.contents)==null?void 0:E.map(F=>{var J;return(F==null?void 0:F.key)==="formContent"&&(F.contents=(J=F.contents)==null?void 0:J.map(se=>(se.value=w==null?void 0:w[se==null?void 0:se.prop],se))),F})}return a==null?void 0:a.contents},_p=a=>{var l,r,n,t,s;if((l=a==null?void 0:a.extra)!=null&&l.row){let v=a==null?void 0:a.filter;if(v!=null&&v.includes("*")&&(v="({"+((n=(r=v==null?void 0:v.replace("{",gr))==null?void 0:r.split(gr))==null?void 0:n[1])),v=(t=v==null?void 0:v.replaceAll("{",""))==null?void 0:t.replaceAll("}",""),(v==null?void 0:v[0])!=="("&&(v="("+v+")"),v.slice(1,(v==null?void 0:v.length)-1)==="undefined")return a==null?void 0:a.contents;let d=he.calculatorAndToOr(v),p=d==null?void 0:d[0],y=(s=a==null?void 0:a.extra)==null?void 0:s.row,g=[];for(let c in p)(p==null?void 0:p[c])===(y==null?void 0:y[c])?g.push(!0):g.push(!1);return g!=null&&g.every(c=>c===!0)?a==null?void 0:a.contents:[]}else return a==null?void 0:a.contents},Sp=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},Ep=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},Cp=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},Dp=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=he.analyzeSplitToContent(n,","))==null?void 0:l.map(t=>((t==null?void 0:t[(t==null?void 0:t.length)-1])===","&&(t=t==null?void 0:t.slice(0,(t==null?void 0:t.length)-1)),t)),r.push({key:"stepName",contents:n}),r}return a==null?void 0:a.contents},Bp=a=>{if(a!=null&&a.filter){let l=a==null?void 0:a.contents;return l.push({key:"step",contents:a==null?void 0:a.filter}),l}return a==null?void 0:a.contents},nc={onNumSlice:op,onRandomContents:tp,onConditionContents:cp,onFatherPaceContents:up,onPaceContents:dp,onMainTagContents:pp,onButtonContents:fp,onPamButtonContents:hp,onRowButtonContents:vp,onRelated:wp,onRowNum:bp,onFixRow:kp,onReqItem:xp,onBottomButtonContents:mp,onConditionContent:_p,onTabs:Sp,onSinChoice:Ep,onTextSize:np,onTextRGBA:ip,onPosition:lp,onSize:rp,onShowType:Cp,onStepName:Dp,onStep:Bp,onInterfaceTypeContents:sp,onBackGround:ap,onMaxColumn:gp,onEditRead:yp},Np=async(a,l)=>{var s,v,d,p,y,g,c,D,M,S,K,I;let r="";if(((s=a==null?void 0:a.find(R=>(R==null?void 0:R.key)==="filter"))==null?void 0:s.contents)!==""&&(r=(v=a==null?void 0:a.find(R=>(R==null?void 0:R.key)==="filter"))==null?void 0:v.contents),r===""||!r)return a;(r==null?void 0:r[0])==="("?r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1):(r=(p=(d=r==null?void 0:r.replace("(",gr))==null?void 0:d.split(gr))==null?void 0:p[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1));let n=(y=he.analyzeSplitToContent(r,","))==null?void 0:y.map(R=>((R==null?void 0:R[(R==null?void 0:R.length)-1])===","&&(R=R==null?void 0:R.slice(0,(R==null?void 0:R.length)-1)),R!=null&&R.includes("(")||(R=R==null?void 0:R.replaceAll(":","=")),R)),t=a;for(let R in n){let j,E="";j=(D=(c=(g=n==null?void 0:n[R])==null?void 0:g.replace("=",gr))==null?void 0:c.split(gr))==null?void 0:D[0],E=(K=(S=(M=n==null?void 0:n[R])==null?void 0:M.replace("=",gr))==null?void 0:S.split(gr))==null?void 0:K[1];let x=(I=vn==null?void 0:vn.find(k=>(k==null?void 0:k.key)===j))==null?void 0:I.value;if(x){const k=nc[x];t=await k({contents:t,filter:E})}}return t},Et=async(a,l)=>{var v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F;let r="";if(((v=a==null?void 0:a.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:v.contents)!==""&&(r=(d=a==null?void 0:a.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:d.contents),r===""||!r)return a;(r==null?void 0:r[0])===","&&(r=r==null?void 0:r.slice(1,r==null?void 0:r.length)),(r==null?void 0:r[0])==="("?r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1):(r==null?void 0:r[0])==="@"||(r=(y=(p=r==null?void 0:r.replace("(",gr))==null?void 0:p.split(gr))==null?void 0:y[1],r=r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1));let n=(g=he.analyzeSplitToContent(r,","))==null?void 0:g.map(J=>((J==null?void 0:J[(J==null?void 0:J.length)-1])===","&&(J=J==null?void 0:J.slice(0,(J==null?void 0:J.length)-1)),J!=null&&J.includes("(")||(J=J==null?void 0:J.replaceAll(":","=")),J)),t=a,s=new Map;n==null||n.forEach(J=>{var ge,Me,V;let se=(ge=J==null?void 0:J.split("="))==null?void 0:ge[0];if(se==="@MainPam"&&s.get(se)){let fe=s.get(se);fe=fe==null?void 0:fe.slice(0,(fe==null?void 0:fe.length)-1);let ae=(V=(Me=J==null?void 0:J.replace("{",gr))==null?void 0:Me.split(gr))==null?void 0:V[1];ae=fe+","+ae,s.set(se,ae)}else se==="@Button"&&s.get(se)?s.set(J,J):s.set(se,J)}),n=Array.from(s.values()),n=n==null?void 0:n.sort((J,se)=>{var ge,Me;return((ge=vn==null?void 0:vn.find(V=>se==null?void 0:se.includes(V==null?void 0:V.key)))==null?void 0:ge.order)-((Me=vn==null?void 0:vn.find(V=>J==null?void 0:J.includes(V==null?void 0:V.key)))==null?void 0:Me.order)});for(let J in n){let se,ge="";(c=n==null?void 0:n[J])!=null&&c.includes("(")&&((D=n==null?void 0:n[J])!=null&&D.includes("@If"))?(se=(K=(S=(M=n==null?void 0:n[J])==null?void 0:M.replace("(",gr))==null?void 0:S.split(gr))==null?void 0:K[0],ge="("+((j=(R=(I=n==null?void 0:n[J])==null?void 0:I.replace("(",gr))==null?void 0:R.split(gr))==null?void 0:j[1])):(se=(k=(x=(E=n==null?void 0:n[J])==null?void 0:E.replace("=",gr))==null?void 0:x.split(gr))==null?void 0:k[0],ge=($=(w=(b=n==null?void 0:n[J])==null?void 0:b.replace("=",gr))==null?void 0:w.split(gr))==null?void 0:$[1]);let Me=(F=vn==null?void 0:vn.find(V=>(V==null?void 0:V.key)===se))==null?void 0:F.value;if(Me){const V=nc[Me];t=await V({contents:t,filter:ge,extra:l})}}return t},ic=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]]},oc=(a,l)=>{var K,I,R,j,E;const r=Array.isArray(a)?a:[],n=r.find(x=>(x==null?void 0:x.key)==="formContent"),t=Array.isArray(n==null?void 0:n.contents)?n.contents:[],s=((K=r.find(x=>(x==null?void 0:x.key)==="_gridLayoutMeta"))==null?void 0:K.contents)??{},v=(t==null?void 0:t[0])??{};let d=((I=l==null?void 0:l.position)==null?void 0:I[0])??(s==null?void 0:s._positionStartRow)??(v==null?void 0:v._positionStartRow),p=((R=l==null?void 0:l.position)==null?void 0:R[1])??(s==null?void 0:s._positionRowSpan)??(v==null?void 0:v._positionRowSpan);(!d||Number.isNaN(d)||d<1)&&(d=1),(!p||Number.isNaN(p)||p<1)&&(p=1);let y=((j=l==null?void 0:l.size)==null?void 0:j[0])??(s==null?void 0:s._sizeStart)??(v==null?void 0:v._sizeStart),g=((E=l==null?void 0:l.size)==null?void 0:E[1])??(s==null?void 0:s._sizeEnd)??(v==null?void 0:v._sizeEnd);(y===void 0||Number.isNaN(y))&&(y=0),(g===void 0||Number.isNaN(g))&&(g=1),y=Math.max(0,Math.min(1,y)),g=Math.max(0,Math.min(1,g)),g<=y&&(y=0,g=1);const c=g-y,D=Math.max(1,Math.round(1/c));let M=r.map(x=>{if((x==null?void 0:x.key)!=="formContent")return x;const k=Array.isArray(x==null?void 0:x.contents)?x.contents:[];return{...x,contents:k.map(b=>({...b,width:D,_positionStartRow:d,_positionRowSpan:p,_sizeStart:y,_sizeEnd:g}))}});const S={_positionStartRow:d,_positionRowSpan:p,_sizeStart:y,_sizeEnd:g};return M.some(x=>(x==null?void 0:x.key)==="_gridLayoutMeta")?M=M.map(x=>(x==null?void 0:x.key)==="_gridLayoutMeta"?{...x,contents:S}:x):M.push({key:"_gridLayoutMeta",contents:S}),M};let po="$R";const Tp=A.useUnit(A.pinia),{selectTitle:Ap}=A.storeToRefs(Tp);let zp=[{label:"新增",prop:"新增"},{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],Mp=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"},{label:"复制新增",prop:"复制新增"},{label:"删除",prop:"删除"}],Ip=[{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],Op=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"}];const os=async(a,l,r=!0)=>{let n=[],t=a==null?void 0:a.map(async s=>{var c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja,L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q,Be,Je,ra,ba,ga,Aa,_a,Oe,Za,Ha,xl,Jl,kl,Pl,ja,Ml,$l,Ma,rl,sl;let v=(S=(M=(D=(c=s==null?void 0:s.contents)==null?void 0:c.find(ma=>{var ka;return(ka=ma==null?void 0:ma.key)==null?void 0:ka.includes("struct")}))==null?void 0:D.value)==null?void 0:M[0])==null?void 0:S.类型,d=Object.values(s==null?void 0:s.name);d=d==null?void 0:d.reverse();let p=(K=s==null?void 0:s.contents)==null?void 0:K.map(ma=>ma==null?void 0:ma.key),y={comp:v,isShow:s==null?void 0:s.is_show,name:d==null?void 0:d[0],id:s==null?void 0:s.object_id,order_no:s==null?void 0:s.order_no,relatedTables:p,menuFilter:(I=s==null?void 0:s.filter)==null?void 0:I.menuFilter,status:s==null?void 0:s.status,fatherSyncContents:(R=s==null?void 0:s.filter)==null?void 0:R.fatherSyncs,relatedQuotes:(j=s==null?void 0:s.filter)==null?void 0:j.quotes,sonSyncContents:(E=s==null?void 0:s.filter)==null?void 0:E.sonSyncs,nameContents:(x=A.cloneDeep(d))==null?void 0:x.reverse()};for(let ma in d)parseInt(ma)>=1&&(y[`name${parseInt(ma)-1}`]=d[ma]);let g=Array.isArray((k=s==null?void 0:s.filter)==null?void 0:k.menuFilter)?(b=s==null?void 0:s.filter)==null?void 0:b.menuFilter:[];if(((w=g==null?void 0:g.filter(ma=>ma==null?void 0:ma.includes("@Filter")))==null?void 0:w.length)>0){let ma=g==null?void 0:g.filter(Ie=>Ie==null?void 0:Ie.includes("@Filter"));ma=ma==null?void 0:ma[0],ma=(F=($=ma==null?void 0:ma.replace("(",po))==null?void 0:$.split(po))==null?void 0:F[1],ma=ma==null?void 0:ma.slice(0,(ma==null?void 0:ma.length)-1),ma!=null&&ma.includes("*")&&(ma=(se=(J=ma==null?void 0:ma.replace("{",po))==null?void 0:J.split(po))==null?void 0:se[1],ma=ma==null?void 0:ma.replace("}","")),ma=he.calculatorAndToOr(ma);let ka=(l==null?void 0:l.originPath)??"";(ka==null?void 0:ka[(ka==null?void 0:ka.length)-1])==="/"&&(ka=ka==null?void 0:ka.slice(0,(ka==null?void 0:ka.length)-1));let La=await Kr(ka,!1),$a=(ge=La==null?void 0:La.filter(Ie=>(Ie==null?void 0:Ie.comp)==="Table"))==null?void 0:ge[0];$a=(V=(Me=$a==null?void 0:$a.compData)==null?void 0:Me.find(Ie=>(Ie==null?void 0:Ie.key)==="tableContents"))==null?void 0:V.contents;let we=(ae=(fe=Ap.value)==null?void 0:fe.find(Ie=>(Ie==null?void 0:Ie.condition)==="child"))==null?void 0:ae.value;$a=(de=$a==null?void 0:$a.map(Ie=>{for(let pe in Ie)if((Ie==null?void 0:Ie[pe])===we)return Ie}))==null?void 0:de.filter(Ie=>Ie),$a=$a==null?void 0:$a[0],ma=ma==null?void 0:ma[0];let ia=[];for(let Ie in ma){let pe="";qa.isObject($a)&&(pe=(Fe=(De=Object.keys($a))==null?void 0:De.filter(ha=>ha==null?void 0:ha.includes("."+Ie)))==null?void 0:Fe[0]),pe!==""&&($a!=null&&$a[pe])&&(ma==null?void 0:ma[Ie])===($a==null?void 0:$a[pe])||$a!=null&&$a[Ie]&&(ma==null?void 0:ma[Ie])===($a==null?void 0:$a[Ie])?ia.push(!0):ia.push(!1)}if(ia!=null&&ia.some(Ie=>Ie===!1)&&((T=l==null?void 0:l.originPath)==null?void 0:T[((ye=l==null?void 0:l.originPath)==null?void 0:ye.length)-1])!=="/")return}if(v==="Table"||v==="Method"){!r&&((ue=y==null?void 0:y.fatherSyncContents)==null?void 0:ue.length)>0;let ma=((U=s==null?void 0:s.contents)==null?void 0:U.find(Xe=>{var Ze;return(Ze=Xe==null?void 0:Xe.key)==null?void 0:Ze.includes("content")}))||[],ka=[];y.comp="Table",ma.value=(Se=ma==null?void 0:ma.value)==null?void 0:Se.sort((Xe,Ze)=>parseInt(Xe==null?void 0:Xe.id)-parseInt(Ze==null?void 0:Ze.id)),ma.value=(Le=ma==null?void 0:ma.value)==null?void 0:Le.map(Xe=>{let Ze={};for(let Ke in Xe)JSON.stringify(Xe==null?void 0:Xe[Ke])==="{}"?Ze[Ke]="":Ze[Ke]=Xe==null?void 0:Xe[Ke];return Ze}),ka.push({key:"tableContents",contents:ma==null?void 0:ma.value});let La=(ta=(le=(Da=(la=(Pe=s==null?void 0:s.contents)==null?void 0:Pe.find(Xe=>{var Ze;return(Ze=Xe==null?void 0:Xe.key)==null?void 0:Ze.includes("struct")}))==null?void 0:la.value)==null?void 0:Da[0])==null?void 0:le.结构)==null?void 0:ta.contents;Array.isArray(La==null?void 0:La[0])?La[0]=(te=La==null?void 0:La[0])==null?void 0:te.filter(Xe=>(Xe==null?void 0:Xe.prop)!=="sort"&&(Xe==null?void 0:Xe.prop)!=="relatedId"):La=La==null?void 0:La.filter(Xe=>(Xe==null?void 0:Xe.prop)!=="sort"&&(Xe==null?void 0:Xe.prop)!=="relatedId"),ka.push({key:"header",contents:La}),ka.push({key:"filter",contents:(Ue=(Te=(oe=(Ee=(ca=s==null?void 0:s.contents)==null?void 0:ca.find(Xe=>{var Ze;return(Ze=Xe==null?void 0:Xe.key)==null?void 0:Ze.includes("struct")}))==null?void 0:Ee.value)==null?void 0:oe[0])==null?void 0:Te.引用)==null?void 0:Ue.contents});let $a=zp,we=A.cloneDeep(Mp);v==="Method"&&we.push({label:"生成方法",prop:"生成方法"}),!Array.isArray(La==null?void 0:La[0])&&((oa=La==null?void 0:La[0])==null?void 0:oa.prop)==="disabled"&&($a=Ip,we=Op);const ia=["推力","真空","压力","温度","流量"],Ie=y.name;Ie&&ia.includes(Ie)&&($a=[...$a],$a.push({label:"导出paraform",prop:"导出paraform",type:"methodButton"}));let pe=[];if(!Array.isArray(La==null?void 0:La[0])&&(La!=null&&La.some(Xe=>{var Ze;return(Xe==null?void 0:Xe.calculatorFilter)&&((Ze=Xe==null?void 0:Xe.calculatorFilter)==null?void 0:Ze.includes("Manual"))}))){let Xe=(Ja=La==null?void 0:La.map(Ze=>Ze==null?void 0:Ze.calculatorFilter))==null?void 0:Ja.filter(Ze=>Ze&&(Ze==null?void 0:Ze.includes("Manual")));Xe==null||Xe.forEach(Ze=>{var pl;let Ke=he.analyzeSplitToContent(Ze,",");if(Ke=Ke==null?void 0:Ke.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)),Ke!=null&&Ke.find(Ve=>(Ve==null?void 0:Ve.includes("Extent"))&&(Ve==null?void 0:Ve.includes("Row")))&&(Ke!=null&&Ke.find(Ve=>(Ve==null?void 0:Ve.includes("Button"))&&(Ve==null?void 0:Ve.includes(","))))){let Ve=Ke==null?void 0:Ke.find(Fa=>Fa==null?void 0:Fa.includes("@FunctionButton"));Ve=(pl=Ve==null?void 0:Ve.split("="))==null?void 0:pl[1],Ve=Ve==null?void 0:Ve.slice(1,(Ve==null?void 0:Ve.length)-1),Ve=Ve==null?void 0:Ve.split(","),Ve=Ve==null?void 0:Ve[(Ve==null?void 0:Ve.length)-1],pe.push(Ve)}}),pe=[...new Set(pe)],pe=pe==null?void 0:pe.map(Ze=>({label:Ze,prop:Ze,type:"methodButton"}))}else if(Array.isArray(La==null?void 0:La[0])&&((L=he.getColumnChild(La==null?void 0:La[0]))!=null&&L.some(Xe=>{var Ze;return(Xe==null?void 0:Xe.calculatorFilter)&&((Ze=Xe==null?void 0:Xe.calculatorFilter)==null?void 0:Ze.includes("Manual"))}))){let Xe=(Q=(H=he.getColumnChild(La==null?void 0:La[0]))==null?void 0:H.map(Ze=>Ze==null?void 0:Ze.calculatorFilter))==null?void 0:Q.filter(Ze=>Ze&&(Ze==null?void 0:Ze.includes("Manual")));Xe==null||Xe.forEach(Ze=>{var pl;let Ke=he.analyzeSplitToContent(Ze,",");if(Ke=Ke==null?void 0:Ke.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)),Ke!=null&&Ke.find(Ve=>(Ve==null?void 0:Ve.includes("Extent"))&&(Ve==null?void 0:Ve.includes("Row")))&&(Ke!=null&&Ke.find(Ve=>(Ve==null?void 0:Ve.includes("Button"))&&(Ve==null?void 0:Ve.includes(","))))){let Ve=Ke==null?void 0:Ke.find(Fa=>Fa==null?void 0:Fa.includes("@FunctionButton"));Ve=(pl=Ve==null?void 0:Ve.split("="))==null?void 0:pl[1],Ve=Ve==null?void 0:Ve.slice(1,(Ve==null?void 0:Ve.length)-1),Ve=Ve==null?void 0:Ve.split(","),Ve=Ve==null?void 0:Ve[(Ve==null?void 0:Ve.length)-1],pe.push(Ve)}}),pe=[...new Set(pe)],pe=pe==null?void 0:pe.map(Ze=>({label:Ze,prop:Ze,type:"methodButton"}))}ka.push({key:"extraButton",contents:$a}),ka.push({key:"rowButton",contents:[...we,...pe]}),y.compData=await Et(ka,l),(me=y.compData)!=null&&me.find(Xe=>(Xe==null?void 0:Xe.key)==="tab")&&(y.tab=(da=(ve=y.compData)==null?void 0:ve.find(Xe=>(Xe==null?void 0:Xe.key)==="tab"))==null?void 0:da.contents),(ea=y.compData)!=null&&ea.find(Xe=>(Xe==null?void 0:Xe.key)==="step")&&(y.step=(pa=(ce=y.compData)==null?void 0:ce.find(Xe=>(Xe==null?void 0:Xe.key)==="step"))==null?void 0:pa.contents),(Ne=y.compData)!=null&&Ne.find(Xe=>(Xe==null?void 0:Xe.key)==="choice")&&(y.choice=(Ta=(We=y.compData)==null?void 0:We.find(Xe=>(Xe==null?void 0:Xe.key)==="choice"))==null?void 0:Ta.contents);let ha="",va=(Ca=y==null?void 0:y.compData)==null?void 0:Ca.filter(Xe=>(Xe==null?void 0:Xe.key)==="fixType");(va==null?void 0:va.length)>0&&r&&(ha=(Qe=va==null?void 0:va[0])==null?void 0:Qe.contents,y.comp=ha)}else if(v==="Form"){let ma=[],ka=(X=(ne=(Va=s==null?void 0:s.contents)==null?void 0:Va.find(Ie=>{var pe;return(pe=Ie==null?void 0:Ie.key)==null?void 0:pe.includes("content")}))==null?void 0:ne.value)==null?void 0:X[0],La=[],$a=Array.isArray((Z=s==null?void 0:s.filter)==null?void 0:Z.menuFilter)?(q=s==null?void 0:s.filter)==null?void 0:q.menuFilter:[];$a==null||$a.forEach(Ie=>{if(Ie!=null&&Ie.includes("@Param(Hide=Yes, prop=")||Ie!=null&&Ie.includes("(Hide=Yes, prop=")){const pe=Ie==null?void 0:Ie.match(/prop=([^,)]+)/);pe!=null&&pe[1]&&La.push(pe==null?void 0:pe[1])}});let we=(ga=(ba=(ra=(Je=(Be=s==null?void 0:s.contents)==null?void 0:Be.find(Ie=>{var pe;return(pe=Ie==null?void 0:Ie.key)==null?void 0:pe.includes("struct")}))==null?void 0:Je.value)==null?void 0:ra[0])==null?void 0:ba.结构)==null?void 0:ga.contents,ia=(Aa=we==null?void 0:we.map(Ie=>(Ie.value=ka==null?void 0:ka[Ie==null?void 0:Ie.prop],Ie)))==null?void 0:Aa.filter(Ie=>(Ie==null?void 0:Ie.prop)!=="sort"&&(Ie==null?void 0:Ie.prop)!=="relatedId");ia=ia==null?void 0:ia.map(Ie=>(La!=null&&La.includes(Ie==null?void 0:Ie.prop)&&(Ie.isHideInForm=!0),Ie)),ma.push({key:"filter",contents:(xl=(Ha=(Za=(Oe=(_a=s==null?void 0:s.contents)==null?void 0:_a.find(Ie=>{var pe;return(pe=Ie==null?void 0:Ie.key)==null?void 0:pe.includes("struct")}))==null?void 0:Oe.value)==null?void 0:Za[0])==null?void 0:Ha.引用)==null?void 0:xl.contents}),ma.push({key:"formContent",contents:ia}),ma.push({key:"paramHideProps",contents:La}),y.compData=await Np(ma),(Jl=y.compData)!=null&&Jl.find(Ie=>(Ie==null?void 0:Ie.key)==="tab")&&(y.tab=(Pl=(kl=y.compData)==null?void 0:kl.find(Ie=>(Ie==null?void 0:Ie.key)==="tab"))==null?void 0:Pl.contents),(ja=y.compData)!=null&&ja.find(Ie=>(Ie==null?void 0:Ie.key)==="step")&&(y.step=($l=(Ml=y.compData)==null?void 0:Ml.find(Ie=>(Ie==null?void 0:Ie.key)==="step"))==null?void 0:$l.contents),(Ma=y.compData)!=null&&Ma.find(Ie=>(Ie==null?void 0:Ie.key)==="choice")&&(y.choice=(sl=(rl=y.compData)==null?void 0:rl.find(Ie=>(Ie==null?void 0:Ie.key)==="choice"))==null?void 0:sl.contents)}return y});return n=await Promise.all(t),n},Lp=A.useLoginState(A.pinia),{loginUserInfo:xi}=A.storeToRefs(Lp),vt=async(a,l,r="Manual",n=[])=>{var p;let t=a,s;Array.isArray(l==null?void 0:l[0])?s=he.getColumnChild(l==null?void 0:l[0]):s=l;let v=(p=s==null?void 0:s.filter(y=>{var g;return(y==null?void 0:y.calculatorFilter)&&((g=y==null?void 0:y.calculatorFilter)==null?void 0:g.includes(r))||(y==null?void 0:y.calculatorFilter)===""&&(y==null?void 0:y.functionName)}))==null?void 0:p.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})),d=t==null?void 0:t.map(async y=>(y=await jp(y,v,s,r,t,n),y));return d=await Promise.all(d),d},Rp=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,t=a==null?void 0:a.headers,s;return Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=he.getValueToObjectValue(l,he.getColumnContents(t))),r==null||r.forEach(v=>{var d;if(l!=null&&l[v]){let p=l==null?void 0:l[v];s=s?p?Bl.isEqual(p.toString(),s.toString()):void 0:p}else{let p=(d=t==null?void 0:t.find(g=>(g==null?void 0:g.label)===v))==null?void 0:d.prop,y=(l==null?void 0:l[p])??0;s=s?y?Bl.isEqual(y.toString(),s.toString()):void 0:y}}),l[n]=s===void 0?void 0:s?1:0,l},kr=a=>{const[l,r,n]=A.cloneDeep(a).split(":").map(Number);let t=+a;return!a||!(a!=null&&a.includes(":"))?t:(l??0)*3600+(r??0)*60+(n??0)},Pn=a=>{const l=s=>s.toString().padStart(2,"0"),r=Math.floor(a/3600),n=Math.floor(a%3600/60),t=a%60;return`${l(r)}:${l(n)}:${parseInt(l(t))}`},$p=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,t=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,v=a==null?void 0:a.allContents,d=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=he.getValueToObjectValue(l,he.getColumnContents(t))),r==null||r.forEach(p=>{var y,g,c,D,M,S,K,I,R;if(l!=null&&l[p]){if(s==="Row")if(!((g=((y=l==null?void 0:l[p])==null?void 0:y.toString())??"")!=null&&g.includes(":"))&&!((c=d==null?void 0:d.toString())!=null&&c.includes(":"))){let j=+(l==null?void 0:l[p]);d=d+j}else d=kr(d.toString())+kr((D=l==null?void 0:l[p])==null?void 0:D.toString()),d=Pn(d)}else if(s==="Row"){let j=(M=t==null?void 0:t.find(E=>(E==null?void 0:E.label)===p))==null?void 0:M.prop;if(!((K=Number.isNaN(l==null?void 0:l[j])?"":(S=l==null?void 0:l[j])==null?void 0:S.toString())!=null&&K.includes(":"))&&!((I=d==null?void 0:d.toString())!=null&&I.includes(":"))){let E=+((l==null?void 0:l[j])??0);d=d+E}else d=kr(d==null?void 0:d.toString())+kr((R=(l==null?void 0:l[j])??0)==null?void 0:R.toString()),d=Pn(d)}}),s==="Column"){let p=[];r==null||r.forEach(y=>{let g=v==null?void 0:v.map(c=>{var D;return(c==null?void 0:c[y])??(c==null?void 0:c[(D=t==null?void 0:t.find(M=>(M==null?void 0:M.label)===y))==null?void 0:D.prop])});p=[...p,...g]}),d=p.reduce((y,g)=>{let c=0;Number.isNaN(y)||(c=+y);let D=0;return Number.isNaN(g)||(D=+g),c+D},0)}return l[n]=d,l},Vp=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,t=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,v=a==null?void 0:a.allContents,d=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=he.getValueToObjectValue(l,he.getColumnContents(t))),r==null||r.forEach(p=>{var y,g,c,D,M,S,K;if(l!=null&&l[p]){if(s==="Row")if(!((g=(y=l==null?void 0:l[p])==null?void 0:y.toString())!=null&&g.includes(":"))&&!((c=d==null?void 0:d.toString())!=null&&c.includes(":"))){let I=+(l==null?void 0:l[p]);d=d===0?d+I:d-I}else d=d===0?kr(d.toString())+kr(l==null?void 0:l[p].toString()):kr(d.toString())-kr(l==null?void 0:l[p].toString()),d=Pn(d)}else if(s==="Row"){let I=(D=t==null?void 0:t.find(R=>(R==null?void 0:R.label)===p))==null?void 0:D.prop;if(!((S=Number.isNaN(l==null?void 0:l[I])?"":(M=l==null?void 0:l[I])==null?void 0:M.toString())!=null&&S.includes(":"))&&!((K=d==null?void 0:d.toString())!=null&&K.includes(":"))){let R=+((l==null?void 0:l[I])??0);d=d===0?d+R:d-R}else d=d===0?kr(d.toString())+kr(((l==null?void 0:l[I])??0).toString()):kr(d.toString())-kr(((l==null?void 0:l[I])??0).toString()),d=Pn(d)}}),s==="Column"){let p=[];r==null||r.forEach(y=>{let g=v==null?void 0:v.map(c=>{var D;return(c==null?void 0:c[y])??(c==null?void 0:c[(D=t==null?void 0:t.find(M=>(M==null?void 0:M.label)===y))==null?void 0:D.prop])});p=[...p,...g]}),d=p.reduce((y,g)=>{let c=0;Number.isNaN(y)||(c=+y);let D=0;return Number.isNaN(g)||(D=+g),c-D},0)}return l[n]=d,l},Fp=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,t=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,v=a==null?void 0:a.allContents,d=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=he.getValueToObjectValue(l,he.getColumnContents(t))),r==null||r.forEach(p=>{var y,g,c,D,M,S,K;if(l!=null&&l[p]){if(s==="Row")if(!((g=(y=l==null?void 0:l[p])==null?void 0:y.toString())!=null&&g.includes(":"))&&!((c=d==null?void 0:d.toString())!=null&&c.includes(":"))){let I=+(l==null?void 0:l[p]);d=d===0?d+I:d*I}else d=d===0?kr(d.toString())+kr(l==null?void 0:l[p].toString()):kr(d.toString())*kr(l==null?void 0:l[p].toString()),d=Pn(d)}else if(s==="Row"){let I=(D=t==null?void 0:t.find(R=>(R==null?void 0:R.label)===p))==null?void 0:D.prop;if(!(l!=null&&l[I]))d=void 0;else if(!((S=Number.isNaN(l==null?void 0:l[I])?"":(M=l==null?void 0:l[I])==null?void 0:M.toString())!=null&&S.includes(":"))&&!((K=d==null?void 0:d.toString())!=null&&K.includes(":"))){let R=+((l==null?void 0:l[I])??0);d=d===0?d+R:d*R}else d=d===0?kr(d.toString())+kr(((l==null?void 0:l[I])??0).toString()):kr(d.toString())*kr(((l==null?void 0:l[I])??0).toString()),d=Pn(d)}}),s==="Column"){let p=[];r==null||r.forEach(y=>{let g=v==null?void 0:v.map(c=>{var D;return(c==null?void 0:c[y])??(c==null?void 0:c[(D=t==null?void 0:t.find(M=>(M==null?void 0:M.label)===y))==null?void 0:D.prop])});p=[...p,...g]}),d=p.reduce((y,g)=>{let c=0;Number.isNaN(y)||(c=+y);let D=0;return Number.isNaN(g)||(D=+g),c*D},0)}return l[n]=d,l},Pp=a=>{let l=a==null?void 0:a.contents,r=a==null?void 0:a.valueString,n=a==null?void 0:a.prop,t=a==null?void 0:a.headers,s=a==null?void 0:a.typeString,v=a==null?void 0:a.allContents,d=0;if(Array.isArray(l)&&(l==null?void 0:l.length)!==1&&(l=he.getValueToObjectValue(l,he.getColumnContents(t))),r==null||r.forEach(p=>{var y,g,c,D,M,S,K;if(l!=null&&l[p]){if(s==="Row")if(!((g=(y=l==null?void 0:l[p])==null?void 0:y.toString())!=null&&g.includes(":"))&&!((c=d==null?void 0:d.toString())!=null&&c.includes(":"))){let I=+(l==null?void 0:l[p]);d=d===0?d+I:d/I}else d=d===0?kr(d.toString())+kr(l==null?void 0:l[p].toString()):kr(d.toString())/kr(l==null?void 0:l[p].toString()),d=Pn(d)}else if(s==="Row"){let I=(D=t==null?void 0:t.find(R=>(R==null?void 0:R.label)===p))==null?void 0:D.prop;if(!((S=Number.isNaN(l==null?void 0:l[I])?"":(M=l==null?void 0:l[I])==null?void 0:M.toString())!=null&&S.includes(":"))&&!((K=d==null?void 0:d.toString())!=null&&K.includes(":"))){let R=+((l==null?void 0:l[I])??0);d=d===0?d+R:d/R}else d=d===0?kr(d.toString())+kr(((l==null?void 0:l[I])??0).toString()):kr(d.toString())/kr(((l==null?void 0:l[I])??0).toString()),d=Pn(d)}}),s==="Column"){let p=[];r==null||r.forEach(y=>{let g=v==null?void 0:v.map(c=>{var D;return(c==null?void 0:c[y])??(c==null?void 0:c[(D=t==null?void 0:t.find(M=>(M==null?void 0:M.label)===y))==null?void 0:D.prop])});p=[...p,...g]}),d=p.reduce((y,g)=>{let c=0;Number.isNaN(y)||(c=+y);let D=0;return Number.isNaN(g)||(D=+g),c/D},0)}return l[n]=d.toFixed(2),l},fo={Sum:$p,Substract:Vp,Multiple:Fp,Divide:Pp,Compare:Rp},jp=async(a,l,r,n="Auto",t,s=[])=>{var g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge,Me,V;let v=a,d=[],p=await A.getPageDataApi({platId:parseInt((g=xi==null?void 0:xi.value)==null?void 0:g.plat_id),pageName:"menu"});p=(M=(D=(c=p==null?void 0:p.data)==null?void 0:c.result)==null?void 0:D.filter(fe=>(fe==null?void 0:fe.property_name)===""))==null?void 0:M[0];let y=[];if(p!=null&&p.object_name){p=p==null?void 0:p.object_name;let fe=await A.getPageDataApi({platId:parseInt((S=xi==null?void 0:xi.value)==null?void 0:S.plat_id),pageName:p});fe=(E=(j=(R=(I=(K=fe==null?void 0:fe.data)==null?void 0:K.result)==null?void 0:I[0])==null?void 0:R.contents)==null?void 0:j.find(ae=>{var de;return(de=ae==null?void 0:ae.key)==null?void 0:de.includes("content")}))==null?void 0:E.value,d=(x=fe==null?void 0:fe.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)!==""),d==null||d.forEach(ae=>{y.push(ae.functionName),fo[ae.functionName]=new Function("return "+ae.functionContent)()})}if((l==null?void 0:l.length)===0)return v;for(let fe in l){let ae=(k=l==null?void 0:l[fe])==null?void 0:k.functionName;const de=fo==null?void 0:fo[ae];let De=(b=l==null?void 0:l[fe])==null?void 0:b.methods;if(De=he.analyzeSplitToContent(De,","),console.log(De),(w=De==null?void 0:De.find(Fe=>Fe==null?void 0:Fe.includes("@FunctionType")))!=null&&w.includes(n)||(De==null?void 0:De.length)===0){let Fe=((J=(F=($=De==null?void 0:De.find(ye=>ye==null?void 0:ye.includes("@FunctionExtent")))==null?void 0:$.replace(":","="))==null?void 0:F.split("="))==null?void 0:J[1])??[];if(await new Function("return ")(),(y==null?void 0:y.length)>0&&y.find(ye=>ye===ae)){let ye="";try{let ue=(se=l==null?void 0:l[fe])==null?void 0:se.functionRelatedWords,U=(s==null?void 0:s.length)>0?s==null?void 0:s.map(Le=>{var Pe;return Le==null?void 0:Le[(Pe=l==null?void 0:l[fe])==null?void 0:Pe.prop]}):["0"];U=U==null?void 0:U.map(Le=>Le==null?void 0:Le.slice((Le==null?void 0:Le.length)-5,Le==null?void 0:Le.length)),U=U==null?void 0:U.map(Le=>he.isNumber(parseInt(Le))&&parseInt(Le)?parseInt(Le):0);let Se=Math.max(...U);ue=ue==null?void 0:ue.map(Le=>{if(Le!=null&&Le.includes("'"))return Le==null?void 0:Le.replaceAll("'","");if(Le!=null&&Le.includes("@"))return Se+1;{let Pe=Object.keys(v);return Le=(v==null?void 0:v[Le])??(v==null?void 0:v[Pe==null?void 0:Pe.find(la=>la==null?void 0:la.includes("."+Le))]),Le}}),ye=de(...ue)}catch(ue){qa.ElMessage.warning("关联数据出现错误,"+ue.message)}let T=(ge=l==null?void 0:l[fe])==null?void 0:ge.prop;v[T]=ye}else v=de({contents:v,valueString:(Me=l==null?void 0:l[fe])==null?void 0:Me.functionRelatedWords,prop:(V=l==null?void 0:l[fe])==null?void 0:V.prop,headers:r,typeString:Fe,allContents:t})}}return v},Hp=A.useLoginState(A.pinia),{loginUserInfo:Xr}=A.storeToRefs(Hp),Up=A.useMenuState(A.pinia),{activeMenuPath:ts,currentMenuPath:ho}=A.storeToRefs(Up),tc=A.useUnit(A.pinia);let ss="$R";const{selectTitle:Si}=A.storeToRefs(tc),sc=async(a,l)=>{var v,d,p,y,g,c,D,M,S,K,I,R,j;let r=ts.value,n="",t=((v=Si==null?void 0:Si.value)==null?void 0:v.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:(d=a==null?void 0:a[0])==null?void 0:d.object_name,n=(p=a==null?void 0:a[0])==null?void 0:p.father_name);let s=[];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 x=await Kr(E,!1);x=(y=x==null?void 0:x[0])==null?void 0:y.compData;let k=(g=x==null?void 0:x.find(w=>(w==null?void 0:w.key)==="header"))==null?void 0:g.contents;k=((c=k==null?void 0:k.find(w=>w==null?void 0:w.isMainKey))==null?void 0:c.prop)??((D=k==null?void 0:k[0])==null?void 0:D.prop);let b=(S=(M=x==null?void 0:x.find(w=>(w==null?void 0:w.key)==="tableContents"))==null?void 0:M.contents)==null?void 0:S.map(w=>({label:w==null?void 0:w[k],value:w==null?void 0:w[k]}));s=(K=n==null?void 0:n.split("/"))==null?void 0:K.map(w=>(w===""?t?(t.isShow=!0,w=t):w={value:w,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}:w={condition:"parent",value:w.trim(),isShow:!0},w))}if(r!==""){let E=(I=r==null?void 0:r.split("/"))==null?void 0:I.map(x=>(x={condition:"normal",value:x.trim(),isShow:!0},x));((R=E==null?void 0:E[0])==null?void 0:R.value)===((j=s==null?void 0:s[0])==null?void 0:j.value)&&(E=E==null?void 0:E.filter((x,k)=>k!==0)),s=[...s??[],...E??[]]}n===""&&t&&((t==null?void 0:t.parentContent)!==ts.value&&(t.isShow=!1),(t==null?void 0:t.value)!==""&&s.push(t)),tc.setSelectTitle(s)},qp=async a=>{var s,v,d,p,y,g,c,D,M;let l=await A.getPageDataApi({platId:parseInt((s=Xr==null?void 0:Xr.value)==null?void 0:s.plat_id),pageName:"menu"}),r=(v=l==null?void 0:l.data)==null?void 0:v.result,n=(g=(y=(p=(d=a==null?void 0:a.filter(S=>(S==null?void 0:S.comp)==="Table"))==null?void 0:d[0])==null?void 0:p.compData)==null?void 0:y.find(S=>(S==null?void 0:S.key)==="filter"))==null?void 0:g.contents;n=(M=(D=(c=n==null?void 0:n.replace("(",ss))==null?void 0:c.split(ss))==null?void 0:D[0])==null?void 0:M.replaceAll(":","/");let t=r==null?void 0:r.filter(S=>{var K;return(S==null?void 0:S.object_name)===ho.value+"/"||((K=ho.value)==null?void 0:K.includes(n))&&n+"/"===(S==null?void 0:S.object_name)});return(t==null?void 0:t.length)>0&&(a=a==null?void 0:a.map(S=>{var K;return(S==null?void 0:S.comp)==="Table"&&(S.compData=(K=S==null?void 0:S.compData)==null?void 0:K.map(I=>{var R,j,E;return(I==null?void 0:I.key)==="header"&&(Array.isArray((R=I.contents)==null?void 0:R[0])?I.contents[0]=(E=I.contents[0])==null?void 0:E.map((x,k)=>{var b;return k===0&&(x.isExistChild=!0,(b=ho.value)!=null&&b.includes(n)&&(x.fatherPath=n)),x}):I.contents=(j=I.contents)==null?void 0:j.map((x,k)=>{var b;return k===0&&(x.isExistChild=!0,(b=ho.value)!=null&&b.includes(n)&&(x.fatherPath=n)),x})),I})),S})),a},Kr=async(a,l,r={})=>{var v,d,p,y,g,c,D,M,S,K,I,R;let n=await A.getPageDataApi({platId:parseInt((v=Xr==null?void 0:Xr.value)==null?void 0:v.plat_id),pageName:a}),t=(d=n==null?void 0:n.data)==null?void 0:d.result;if((t==null?void 0:t.length)===0&&(r!=null&&r.originPath)&&(r==null?void 0:r.originPath)!==a){let j=await A.getPageDataApi({platId:parseInt((p=Xr==null?void 0:Xr.value)==null?void 0:p.plat_id),pageName:r==null?void 0:r.originPath});if(((g=(y=j==null?void 0:j.data)==null?void 0:y.result)==null?void 0:g.length)>0){let E=await os((c=j==null?void 0:j.data)==null?void 0:c.result,r,!1);E=E==null?void 0:E.map(async b=>{var F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja;let w=[],$=(F=Object.keys(b))==null?void 0:F.filter(L=>(L==null?void 0:L.includes("name"))&&L!=="nameContents");for(let L in b)$!=null&&$.find(H=>H===L)&&w.push(b==null?void 0:b[L]);if(w=w.reverse(),(b==null?void 0:b.comp)==="Table"){let L=(ge=(se=(J=b==null?void 0:b.compData)==null?void 0:J.find(Q=>(Q==null?void 0:Q.key)==="tableContents"))==null?void 0:se.contents)==null?void 0:ge.map(Q=>{let me={};for(let ve in Q)ve!=="id"&&ve!=="create_time"&&ve!=="update_time"&&ve!=="sort"&&ve!=="create_user_id"&&ve!=="update_user_id"&&ve!=="department_id"&&ve!=="relatedId"&&(me[ve]=Q==null?void 0:Q[ve]);return Q=Object.values(me),Q}),H=(V=(Me=b==null?void 0:b.compData)==null?void 0:Me.find(Q=>(Q==null?void 0:Q.key)==="header"))==null?void 0:V.contents;if(Array.isArray(H==null?void 0:H[0])?(H[0].push({label:"排序",prop:"sort"}),H[0].push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(fe=H[0])!=null&&fe.find(Q=>(Q==null?void 0:Q.prop)==="disabled")&&(H[0]=(ae=H[0])==null?void 0:ae.filter(Q=>(Q==null?void 0:Q.prop)!=="disabled"),H[0].unshift({label:"",prop:"disabled",sortable:!1}))):(H||(H=[]),H.push({label:"排序",prop:"sort"}),H.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),H!=null&&H.find(Q=>(Q==null?void 0:Q.prop)==="disabled")&&(H=H==null?void 0:H.filter(Q=>(Q==null?void 0:Q.prop)!=="disabled"),H.unshift({label:"",prop:"disabled",sortable:!1}))),H!=null&&H.some(Q=>{var me;return(Q==null?void 0:Q.calculatorFilter)&&((me=Q==null?void 0:Q.calculatorFilter)==null?void 0:me.includes("Auto"))})&&(L=await vt(L,H,"Auto"),L=L==null?void 0:L.map(Q=>Object.values(Q))),b!=null&&b.fatherSyncContents){Array.isArray((de=b==null?void 0:b.fatherSyncContents)==null?void 0:de[0])&&(b.fatherSyncContents=(De=b==null?void 0:b.fatherSyncContents)==null?void 0:De[0]);let Q=(Fe=Si.value)==null?void 0:Fe.find(me=>(me==null?void 0:me.condition)==="child");b.fatherSyncContents=(ye=b==null?void 0:b.fatherSyncContents)==null?void 0:ye.map(me=>{var ve,da,ea,ce,pa,Ne;return((da=me==null?void 0:me.menus)==null?void 0:da[((ve=me==null?void 0:me.menus)==null?void 0:ve.length)-1])==="/"&&(Q==null?void 0:Q.parentContent)+"/"!==(me==null?void 0:me.menus)?me.menus=(me==null?void 0:me.menus)+(Q==null?void 0:Q.value):((ce=me==null?void 0:me.menus)==null?void 0:ce[((ea=me==null?void 0:me.menus)==null?void 0:ea.length)-1])==="/"&&(Q==null?void 0:Q.parentContent)+"/"===(me==null?void 0:me.menus)&&(me.menus=(Ne=me.menus)==null?void 0:Ne.slice(0,((pa=me.menus)==null?void 0:pa.length)-1)),me})}if(b!=null&&b.sonSyncContents){Array.isArray((T=b==null?void 0:b.sonSyncContents)==null?void 0:T[0])&&(b.sonSyncContents=(ue=b==null?void 0:b.sonSyncContents)==null?void 0:ue[0]);let Q=(U=Si.value)==null?void 0:U.find(me=>(me==null?void 0:me.condition)==="child");b.sonSyncContents=(Se=b==null?void 0:b.sonSyncContents)==null?void 0:Se.map(me=>{var ve,da,ea,ce,pa,Ne;return((da=me==null?void 0:me.menus)==null?void 0:da[((ve=me==null?void 0:me.menus)==null?void 0:ve.length)-1])==="/"&&(Q==null?void 0:Q.parentContent)+"/"!==(me==null?void 0:me.menus)?me.menus=(me==null?void 0:me.menus)+(Q==null?void 0:Q.value):((ce=me==null?void 0:me.menus)==null?void 0:ce[((ea=me==null?void 0:me.menus)==null?void 0:ea.length)-1])==="/"&&(Q==null?void 0:Q.parentContent)+"/"===(me==null?void 0:me.menus)&&(me.menus=(Ne=me.menus)==null?void 0:Ne.slice(0,((pa=me.menus)==null?void 0:pa.length)-1)),me})}if(b!=null&&b.relatedQuotes){Array.isArray((Le=b==null?void 0:b.relatedQuotes)==null?void 0:Le[0])&&(b.relatedQuotes=(Pe=b==null?void 0:b.relatedQuotes)==null?void 0:Pe[0]);let Q=(la=Si.value)==null?void 0:la.find(me=>(me==null?void 0:me.condition)==="child");b.relatedQuotes=(Da=b==null?void 0:b.relatedQuotes)==null?void 0:Da.map(me=>{var ve,da,ea,ce,pa,Ne;return((da=me==null?void 0:me.menus)==null?void 0:da[((ve=me==null?void 0:me.menus)==null?void 0:ve.length)-1])==="/"&&(Q==null?void 0:Q.parentContent)+"/"!==(me==null?void 0:me.menus)?me.menus=(me==null?void 0:me.menus)+(Q==null?void 0:Q.value):((ce=me==null?void 0:me.menus)==null?void 0:ce[((ea=me==null?void 0:me.menus)==null?void 0:ea.length)-1])==="/"&&(Q==null?void 0:Q.parentContent)+"/"===(me==null?void 0:me.menus)&&(me.menus=(Ne=me.menus)==null?void 0:Ne.slice(0,((pa=me.menus)==null?void 0:pa.length)-1)),me})}b={filter:(ta=(le=b==null?void 0:b.compData)==null?void 0:le.find(Q=>(Q==null?void 0:Q.key)==="filter"))==null?void 0:ta.contents,key:b==null?void 0:b.comp,name:w,tableColumns:H,tableContents:L,menuFilter:b==null?void 0:b.menuFilter,fatherSyncContents:b==null?void 0:b.fatherSyncContents,relatedQuotes:b==null?void 0:b.relatedQuotes,sonSyncContents:b==null?void 0:b.sonSyncContents}}else{let L=(Ee=(ca=(te=b==null?void 0:b.compData)==null?void 0:te.find(Q=>(Q==null?void 0:Q.key)==="formContent"))==null?void 0:ca.contents)==null?void 0:Ee.map(Q=>(Q==null?void 0:Q.value)??"");L=[L];let H=(Ue=(Te=(oe=b==null?void 0:b.compData)==null?void 0:oe.find(Q=>(Q==null?void 0:Q.key)==="formContent"))==null?void 0:Te.contents)==null?void 0:Ue.map(Q=>(Q.value="",Q));b={contents:L,filter:(Ja=(oa=b==null?void 0:b.compData)==null?void 0:oa.find(Q=>(Q==null?void 0:Q.key)==="filter"))==null?void 0:Ja.contents,key:b==null?void 0:b.comp,name:w,value:H,fatherSyncContents:b==null?void 0:b.fatherSyncContents,relatedQuotes:b==null?void 0:b.relatedQuotes,sonSyncContents:b==null?void 0:b.sonSyncContents}}return b.isShow=!1,b}),E=await Promise.all(E);let x=[{key:"menuPath",contents:[{path:a,fatherPath:(S=(M=(D=j==null?void 0:j.data)==null?void 0:D.result)==null?void 0:M[0])==null?void 0:S.father_name,isShow:!1}]},{key:a,contents:E}];await A.createPlatFormDataApi({platId:parseInt((K=Xr==null?void 0:Xr.value)==null?void 0:K.plat_id),changeData:x});let k=await A.getPageDataApi({platId:parseInt((I=Xr==null?void 0:Xr.value)==null?void 0:I.plat_id),pageName:a});t=(R=k==null?void 0:k.data)==null?void 0:R.result}}l&&await sc(t,!!(r!=null&&r.originPath));let s=await os(t,r);return l&&(s=await qp(s)),s==null?void 0:s.filter(j=>j)},cs=async a=>{var n,t,s,v,d,p,y,g,c,D,M;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+((s=(t=a.value)==null?void 0:t.split(" "))==null?void 0:s[0]));let r=await Kr(l,!1);if(r=(v=r==null?void 0:r.filter(S=>{var K,I;return(S==null?void 0:S.name)===((I=a==null?void 0:a.groups)==null?void 0:I[((K=a==null?void 0:a.groups)==null?void 0:K.length)-1])}))==null?void 0:v[0],(p=(d=r==null?void 0:r.compData)==null?void 0:d.find(S=>(S==null?void 0:S.key)==="tableContents"))!=null&&p.contents){r=(g=(y=r==null?void 0:r.compData)==null?void 0:y.find(K=>(K==null?void 0:K.key)==="tableContents"))==null?void 0:g.contents;let S=((c=a==null?void 0:a.words)==null?void 0:c[0])??(a==null?void 0:a.prop);return r=r==null?void 0:r.filter(K=>{var I,R,j,E;return(K==null?void 0:K[a!=null&&a.endChildMenu?S:(I=a==null?void 0:a.words)==null?void 0:I[0]])===(a!=null&&a.relatedWords&&((R=a==null?void 0:a.relatedWords)==null?void 0:R.length)>0?(E=(j=a.value)==null?void 0:j.split(" "))==null?void 0:E[0]:a.value)}),r==null?void 0:r[0]}else{let S=(M=(D=r==null?void 0:r.compData)==null?void 0:D.find(I=>(I==null?void 0:I.key)==="formContent"))==null?void 0:M.contents,K={};return S==null||S.forEach(I=>{K[I.prop]=I.value}),K}},Wp={key:0,class:"extra-button-content"},Kp={class:"table-operator-wrap"},Gp={key:0,class:"extra-button-filter"},Yp={key:1,class:"extra-header"},Jp=["onClick"],Xp={class:"table-op-text"},Zp={class:"table-op-text"},Qp={class:"drop-menu",style:{width:"120px"}},ef=["onClick"],af={key:0},lf={key:1},rf=["onClick"],nf={class:"table-op-text"},of={key:1,class:"extra-button-content tabs-button-wrapper"},tf={class:"table-operator-wrap"},sf={class:"extra-button-filter"},cf={key:0,class:"extra-header"},uf={class:"table-op-action"},df={class:"table-op-text"},pf={class:"drop-menu",style:{width:"120px"}},ff={key:0},hf={key:1},vf=["onClick"],mf={class:"table-op-text"},yf={__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,t=()=>{const $=(n==null?void 0:n.menuFilter)||[];return Array.isArray($)&&($==null?void 0:$.some(F=>{const J=typeof F=="string"?F:JSON.stringify(F);return J==null?void 0:J.includes("HideGroup=Yes")}))},s=e.ref(""),v=e.ref(!1),d=e.ref(!1),p=e.ref([]),y=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 c($,F){return $.map(J=>{const se={...J};return F.forEach(ge=>{delete se[ge]}),se})}function D($){if(!$||$.t!=="n")return($==null?void 0:$.v)??"";const F=$.v;if($.z){const J=String($.z).toLowerCase(),se=["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 V of se)if(J.includes(V))return M(F);const ge=/[ymdhms]/.test(J),Me=/^[0#\.\,\s]+$/.test(J.replace(/[\\\/\-:]/g,""));if(ge&&!Me)return M(F)}if(F>=1&&F<=73050){if(F<5e3)return F;if(F>=5e3&&F<4e4){const J=Math.floor((F-25569)/365.25)+1970;return J>=1970&&J<=2e3&&$.z&&/[ymd]/.test(String($.z).toLowerCase())?M(F):F}if(F>=4e4)return M(F)}return F}function M($){if(typeof $!="number")return $;try{const F=new Date(($-25569)*86400*1e3);if(isNaN(F.getTime()))return $;const J=F.getFullYear(),se=String(F.getMonth()+1).padStart(2,"0"),ge=String(F.getDate()).padStart(2,"0");return`${J}-${se}-${ge}`}catch{return $}}const S=$=>{const F=$.raw;if(!F)return;const J=new FileReader;J.onload=se=>{try{const ge=new Uint8Array(se.target.result),Me=he.readSync(ge,{type:"array"}),V=Me.SheetNames[0],fe=Me.Sheets[V],de=he.utils.decode_range(fe["!ref"]).e.c+1,De=new Array(de).fill(""),Fe=[];for(const Se in fe){if(Se[0]==="!")continue;const{r:Le,c:Pe}=he.utils.decode_cell(Se),la=fe[Se];let Da=D(la);if((Da==null||Da==="")&&(Da=""),Le===0)De[Pe]=Da;else{if(!Fe[Le-1]){Fe[Le-1]={};for(let le=0;le<de;le++)Fe[Le-1][`col_${le}`]=""}Fe[Le-1][`col_${Pe}`]=Da}}for(let Se=0;Se<de;Se++)De[Se]===void 0&&(De[Se]="");const ye=[];for(let Se=0;Se<De.length;Se++)(!De[Se]||De[Se].toString().trim()==="")&&ye.push(Se);let T,ue;(ye==null?void 0:ye.length)>0?(qa.ElMessage.warning("存在键为空的列,已自动过滤,请检查补充"),T=De.filter((Se,Le)=>!ye.includes(Le)),ue=c(Fe,ye==null?void 0:ye.map(Se=>`col_${Se}`))):(T=De,ue=Fe);const U=Fe==null?void 0:Fe[0];if(!(U!=null&&U.hasOwnProperty("col_0")))return qa.ElMessage.error("导入的数据列不匹配,请检查是否错位");r("getImportData",T,ue)}catch(ge){throw qa.ElMessage.error(ge.message),new Error(ge.message)}},J.readAsArrayBuffer(F)},K=$=>{var J;const F=(J=p.value)==null?void 0:J.reduce((se,ge,Me)=>(Me===0?se[ge.label]=$:se[ge.label]=ge==null?void 0:ge.value,se),{});r("filter",F,$,!0)},I=($,F={})=>{r("buttonClick",$,"",F)},R=$=>{var F,J;p.value=(J=(F=he.getColumnChild(A.cloneDeep($)))==null?void 0:F.filter(se=>(se==null?void 0:se.label)!==""&&(se==null?void 0:se.label)!=="操作"))==null?void 0:J.map(se=>({label:(se==null?void 0:se.label)??"",value:"",name:(se==null?void 0:se.prop)??"",isFormColHidden:se==null?void 0:se.isTableColHidden,width:2,prop:(se==null?void 0:se.prop)??""}))},j=e.ref(!1),E=$=>{var F;if(($==null?void 0:$.buttonName)==="确认"&&(r("filter",$==null?void 0:$.content),j.value=($==null?void 0:$.content)&&Object.values($==null?void 0:$.content).length>0),($==null?void 0:$.buttonName)==="清空"){const J=A.cloneDeep($==null?void 0:$.content);for(const se in J)J[se]="";p.value=(F=p.value)==null?void 0:F.map(se=>({...se,value:""})),r("filter",J),j.value=!1}v.value=!1},x=()=>{v.value=!v.value,d.value=!0},k=()=>{var F,J;p.value=(F=p.value)==null?void 0:F.map(se=>({...se,value:""}));const $=(J=p.value)==null?void 0:J.reduce((se,ge)=>(se[ge.label]=ge.value,se),{});r("filter",$)},b=e.ref(null);let w;return w=$=>{var ge;if(!v.value)return;const F=(ge=b==null?void 0:b.value)==null?void 0:ge.$el,J=F==null?void 0:F.contains($.target);let se=!1;document.querySelectorAll(".el-popover, .el-popper").forEach(Me=>{Me.contains($.target)&&(se=!0)}),!J&&!se&&(v.value=!1)},e.onMounted(()=>{document.addEventListener("click",w),R(n.columns)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",w)}),e.watch(()=>n.columns,()=>{R(n.columns)},{deep:!0,immediate:!0}),($,F)=>{var fe,ae,de,De,Fe,ye,T,ue;const J=e.resolveComponent("el-icon"),se=e.resolveComponent("svg-icon"),ge=e.resolveComponent("el-input"),Me=e.resolveComponent("el-upload"),V=e.resolveComponent("el-button");return a.pageLayout==="vertical"?(e.openBlock(),e.createElementBlock("div",Wp,[t()?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",Kp,[n!=null&&n.filterShow?(e.openBlock(),e.createElementBlock("div",Gp,[e.createVNode($u,{trigger:"contextmenu",ref_key:"popOverRef",ref:b,title:"",width:800,placement:"bottom-start",isVisible:v.value,"onUpdate:isVisible":F[4]||(F[4]=U=>v.value=U)},{reference:e.withCtx(()=>{var U,Se,Le,Pe;return[e.createVNode(ge,{modelValue:s.value,"onUpdate:modelValue":F[0]||(F[0]=la=>s.value=la),style:{"min-width":"80px"},placeholder:j.value?(Le=(Se=(U=a.filterValues)==null?void 0:U.filter(la=>la))==null?void 0:Se.slice(0,3))==null?void 0:Le.join("/"):"搜索","prefix-icon":e.unref(qa.search_default),clearable:"",onInput:K,disabled:((Pe=p.value)==null?void 0:Pe.length)===0},{suffix:e.withCtx(()=>{var la,Da;return[!s.value&&((Da=(la=a.filterValues)==null?void 0:la.filter(le=>le))!=null&&Da.join("/"))?(e.openBlock(),e.createBlock(J,{key:0,style:{cursor:"pointer"},onClick:k},{default:e.withCtx(()=>[e.createVNode(e.unref(qa.circle_close_default))]),_:1})):e.createCommentVNode("",!0)]}),append:e.withCtx(()=>[e.createElementVNode("span",{title:"条件查询",onClick:e.withModifiers(x,["stop"])},[e.createVNode(se,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]}),content:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-content-value",onKeydown:F[1]||(F[1]=e.withModifiers(()=>{},["stop"])),onKeyup:F[2]||(F[2]=e.withModifiers(()=>{},["stop"])),onKeypress:F[3]||(F[3]=e.withModifiers(()=>{},["stop"]))},[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:p.value,buttonValue:y.value,isRowFlex:!0,isEnableWrap:!1,isButtonRow:!1,key:y.value,isStartJustify:!1,onOnButtonClick:E},null,8,["rowContents","buttonValue"]))],32)):e.createCommentVNode("",!0)]),_:1},8,["isVisible"])])):e.createCommentVNode("",!0),a.buttons&&((fe=a.buttons)==null?void 0:fe.length)>0?(e.openBlock(),e.createElementBlock("div",Yp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((ae=a.buttons)==null?void 0:ae.filter(U=>a.isDevMode||(U==null?void 0:U.label)!=="修改模板"),(U,Se)=>{var Le;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:Se},[(U==null?void 0:U.type)==="upload"?(e.openBlock(),e.createBlock(Me,{key:0,class:"upload-button-wrap","on-change":S,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1,disabled:!!a.lockingPage},{default:e.withCtx(()=>{var Pe;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:la=>I(U==null?void 0:U.label)},[e.createVNode(se,{class:"table-op-icon",name:(Pe=g==null?void 0:g.find(la=>(la==null?void 0:la.label)===(U==null?void 0:U.label)))==null?void 0:Pe.icon},null,8,["name"]),e.createElementVNode("span",Xp,e.toDisplayString(U==null?void 0:U.label),1)],10,Jp)]}),_:2},1032,["disabled"])):e.createCommentVNode("",!0),(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(ll._sfc_main,{key:1},{dropTitle:e.withCtx(()=>{var Pe;return[e.createElementVNode("div",{class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}])},[e.createVNode(se,{class:"table-op-icon",name:(Pe=g==null?void 0:g.find(la=>(la==null?void 0:la.label)===(U==null?void 0:U.label)))==null?void 0:Pe.icon},null,8,["name"]),e.createElementVNode("span",Zp,e.toDisplayString(U==null?void 0:U.label),1)],2)]}),dropMenu:e.withCtx(()=>[e.createElementVNode("div",Qp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U==null?void 0:U.contents,Pe=>{var la,Da;return e.openBlock(),e.createElementBlock("div",{key:Pe==null?void 0:Pe.label,class:e.normalizeClass(["table-op-drop-item",{"is-disabled":!!a.lockingPage}]),onClick:le=>!a.lockingPage&&I(Pe==null?void 0:Pe.label)},[e.createTextVNode(e.toDisplayString(Pe==null?void 0:Pe.label),1),(la=Pe==null?void 0:Pe.label)!=null&&la.includes("选中")?(e.openBlock(),e.createElementBlock("span",af,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(Da=Pe==null?void 0:Pe.label)!=null&&Da.includes("全部")?(e.openBlock(),e.createElementBlock("span",lf,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)],10,ef)}),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(U!=null&&U.type)||(U==null?void 0:U.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,id:"themeButton",class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),onClick:Pe=>!a.lockingPage&&I(U==null?void 0:U.label,U)},[e.createVNode(se,{class:"table-op-icon",name:((Le=g==null?void 0:g.find(Pe=>(Pe==null?void 0:Pe.label)===(U==null?void 0:U.label)))==null?void 0:Le.icon)??"normal"},null,8,["name"]),e.createElementVNode("span",nf,e.toDisplayString(U==null?void 0:U.label),1)],10,rf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createElementBlock("div",of,[e.createElementVNode("div",tf,[e.createElementVNode("div",sf,[e.createVNode(ge,{modelValue:s.value,"onUpdate:modelValue":F[5]||(F[5]=U=>s.value=U),style:{"min-width":"80px"},placeholder:j.value?(Fe=(De=(de=a.filterValues)==null?void 0:de.filter(U=>U))==null?void 0:De.slice(0,3))==null?void 0:Fe.join("/"):"搜索","prefix-icon":e.unref(qa.search_default),clearable:"",onInput:K,disabled:((ye=p.value)==null?void 0:ye.length)===0},{suffix:e.withCtx(()=>{var U,Se;return[!s.value&&((Se=(U=a.filterValues)==null?void 0:U.filter(Le=>Le))!=null&&Se.join("/"))?(e.openBlock(),e.createBlock(J,{key:0,style:{cursor:"pointer"},onClick:k},{default:e.withCtx(()=>[e.createVNode(e.unref(qa.circle_close_default))]),_:1})):e.createCommentVNode("",!0)]}),append:e.withCtx(()=>[e.createElementVNode("span",{title:"条件查询",onClick:e.withModifiers(x,["stop"])},[e.createVNode(se,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]),a.buttons&&((T=a.buttons)==null?void 0:T.length)>0?(e.openBlock(),e.createElementBlock("div",cf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((ue=a.buttons)==null?void 0:ue.filter(U=>a.isDevMode||(U==null?void 0:U.label)!=="修改模板"),(U,Se)=>{var Le;return e.openBlock(),e.createElementBlock("div",{class:"extra-contents",key:Se},[(U==null?void 0:U.type)==="upload"?(e.openBlock(),e.createBlock(Me,{key:0,class:"upload-button-wrap","on-change":S,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1},{default:e.withCtx(()=>{var Pe;return[e.createElementVNode("div",uf,[e.createVNode(se,{class:"table-op-icon",name:(Pe=g==null?void 0:g.find(la=>(la==null?void 0:la.label)===(U==null?void 0:U.label)))==null?void 0:Pe.icon},null,8,["name"]),e.createElementVNode("span",df,e.toDisplayString(U==null?void 0:U.label),1)])]}),_:2},1024)):e.createCommentVNode("",!0),(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(ll._sfc_main,{key:1},{dropTitle:e.withCtx(()=>[(U==null?void 0:U.type)==="popover"?(e.openBlock(),e.createBlock(V,{key:0,style:{background:"transparent",color:"#000000"}},{icon:e.withCtx(()=>{var Pe;return[e.createVNode(se,{class:"table-op-icon",name:(Pe=g==null?void 0:g.find(la=>(la==null?void 0:la.label)===(U==null?void 0:U.label)))==null?void 0:Pe.icon},null,8,["name"])]}),default:e.withCtx(()=>[e.createTextVNode(" "+e.toDisplayString(U==null?void 0:U.label),1)]),_:2},1024)):e.createCommentVNode("",!0)]),dropMenu:e.withCtx(()=>[e.createElementVNode("div",pf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U==null?void 0:U.contents,Pe=>(e.openBlock(),e.createBlock(V,{key:Pe==null?void 0:Pe.label,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:la=>I(Pe==null?void 0:Pe.label)},{default:e.withCtx(()=>{var la,Da;return[e.createTextVNode(e.toDisplayString(Pe==null?void 0:Pe.label),1),(la=Pe==null?void 0:Pe.label)!=null&&la.includes("选中")?(e.openBlock(),e.createElementBlock("span",ff,"("+e.toDisplayString(a.selectNums)+")",1)):e.createCommentVNode("",!0),(Da=Pe==null?void 0:Pe.label)!=null&&Da.includes("全部")?(e.openBlock(),e.createElementBlock("span",hf,"("+e.toDisplayString(a.dataNums)+")",1)):e.createCommentVNode("",!0)]}),_:2},1032,["onClick"]))),128))])]),_:2},1024)):e.createCommentVNode("",!0),!(U!=null&&U.type)||(U==null?void 0:U.type)==="methodButton"?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["table-op-action",{"is-disabled":!!a.lockingPage}]),id:"themeButton",onClick:Pe=>!a.lockingPage&&I(U==null?void 0:U.label,U)},[e.createVNode(se,{class:"table-op-icon",name:(Le=g==null?void 0:g.find(Pe=>(Pe==null?void 0:Pe.label)===(U==null?void 0:U.label)))==null?void 0:Le.icon},null,8,["name"]),e.createElementVNode("span",mf,e.toDisplayString(U==null?void 0:U.label),1)],10,vf)):e.createCommentVNode("",!0)])}),128))])):e.createCommentVNode("",!0)])]))}}},gf=Zl._export_sfc(yf,[["__scopeId","data-v-44a17652"]]),bf={__name:"index",props:{columns:Array,tableData:Array},setup(a){return(l,r)=>{const n=e.resolveComponent("el-table-column"),t=e.resolveComponent("el-table");return e.openBlock(),e.createBlock(t,{data:a.tableData,style:{width:"100%"},stripe:"","max-height":"500"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.columns,s=>{var v;return e.openBlock(),e.createBlock(n,{key:s==null?void 0:s.prop,label:s==null?void 0:s.label,prop:s==null?void 0:s.prop,fixed:(s==null?void 0:s.prop)==="operate"?"right":s==null?void 0:s.fixed,align:(s==null?void 0:s.align)??"left","show-overflow-tooltip":(s==null?void 0:s.showOverflowTooltip)??!0,width:s==null?void 0:s.width,"min-width":(s==null?void 0:s.minWidth)||((s==null?void 0:s.prop)==="operate"?80:(((v=s==null?void 0:s.label)==null?void 0:v.length)*2||4)*27)},{default:e.withCtx(d=>[e.renderSlot(l.$slots,"content",{row:d.row,column:d.column,$index:d.$index,scope:d}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.children,(p,y)=>(e.openBlock(),e.createBlock(ll._sfc_main$2,{key:y,column:p,tableData:a.tableData},e.createSlots({_:2},[e.renderList(l.$slots,(g,c)=>({name:c,fn:e.withCtx(({row:D,slotData:M,item:S,column:K})=>[e.renderSlot(l.$slots,c,e.mergeProps({ref_for:!0},M??D,{item:S??p,slotData:M??D,row:D,column:K,columnProp:p}))])}))]),1032,["column","tableData"]))),128))]),_:2},1032,["label","prop","fixed","align","show-overflow-tooltip","width","min-width"])}),128))]),_:3},8,["data"])}}};class kf extends Bl.Loader{constructor(l){super(l),this.littleEndian=!0}load(l,r,n,t){const s=this,v=new Bl.FileLoader(s.manager);v.setPath(s.path),v.setResponseType("arraybuffer"),v.setRequestHeader(s.requestHeader),v.setWithCredentials(s.withCredentials),v.load(l,function(d){try{r(s.parse(d))}catch(p){t?t(p):console.error(p),s.manager.itemError(l)}},n,t)}_getDataView(l,r,n,t){switch(n){case"F":return t===8?l.getFloat64(r,this.littleEndian):l.getFloat32(r,this.littleEndian);case"I":return t===1?l.getInt8(r):t===2?l.getInt16(r,this.littleEndian):l.getInt32(r,this.littleEndian);case"U":return t===1?l.getUint8(r):t===2?l.getUint16(r,this.littleEndian):l.getUint32(r,this.littleEndian)}}parse(l){function r(M,S){const K=M.length,I=new Uint8Array(S);let R=0,j=0,E,x,k;do if(E=M[R++],E<32){if(E++,j+E>S)throw new Error("Output buffer is not large enough");if(R+E>K)throw new Error("Invalid compressed data");do I[j++]=M[R++];while(--E)}else{if(x=E>>5,k=j-((E&31)<<8)-1,R>=K)throw new Error("Invalid compressed data");if(x===7&&(x+=M[R++],R>=K))throw new Error("Invalid compressed data");if(k-=M[R++],j+x+2>S)throw new Error("Output buffer is not large enough");if(k<0)throw new Error("Invalid compressed data");if(k>=j)throw new Error("Invalid compressed data");do I[j++]=I[k++];while(--x+2)}while(R<K);return I}function n(M){const S={},K=new Uint8Array(M);let I="",R="",j=0,E=!1;const x=K.length;for(;j<x&&E===!1;){const $=String.fromCharCode(K[j++]);$===`
|
|
2
|
-
`||$==="\r"?(R.trim().toLowerCase().startsWith("data")&&(E=!0),R=""):R+=$,I+=$}const k=I.search(/[\r\n]DATA\s(\S*)\s/i),b=/[\r\n]DATA\s(\S*)\s/i.exec(I.slice(k-1));if(S.data=b[1],S.headerLen=b[0].length+k,S.str=I.slice(0,S.headerLen),S.str=S.str.replace(/#.*/gi,""),S.version=/^VERSION (.*)/im.exec(S.str),S.fields=/^FIELDS (.*)/im.exec(S.str),S.size=/^SIZE (.*)/im.exec(S.str),S.type=/^TYPE (.*)/im.exec(S.str),S.count=/^COUNT (.*)/im.exec(S.str),S.width=/^WIDTH (.*)/im.exec(S.str),S.height=/^HEIGHT (.*)/im.exec(S.str),S.viewpoint=/^VIEWPOINT (.*)/im.exec(S.str),S.points=/^POINTS (.*)/im.exec(S.str),S.version!==null&&(S.version=parseFloat(S.version[1])),S.fields=S.fields!==null?S.fields[1].split(" "):[],S.type!==null&&(S.type=S.type[1].split(" ")),S.width!==null&&(S.width=parseInt(S.width[1])),S.height!==null&&(S.height=parseInt(S.height[1])),S.viewpoint!==null&&(S.viewpoint=S.viewpoint[1]),S.points!==null&&(S.points=parseInt(S.points[1],10)),S.points===null&&(S.points=S.width*S.height),S.size!==null&&(S.size=S.size[1].split(" ").map(function($){return parseInt($,10)})),S.count!==null)S.count=S.count[1].split(" ").map(function($){return parseInt($,10)});else{S.count=[];for(let $=0,F=S.fields.length;$<F;$++)S.count.push(1)}S.offset={};let w=0;for(let $=0,F=S.fields.length;$<F;$++)S.data==="ascii"?S.offset[S.fields[$]]=$:(S.offset[S.fields[$]]=w,w+=S.size[$]*S.count[$]);return S.rowSize=w,S}const t=n(l),s=[],v=[],d=[],p=[],y=[],g=new Bl.Color;if(t.data==="ascii"){const M=t.offset,I=new TextDecoder().decode(l).slice(t.headerLen).split(`
|
|
3
|
-
`);for(let R=0,j=I.length;R<j;R++){if(I[R]==="")continue;const E=I[R].split(" ");if(M.x!==void 0&&(s.push(parseFloat(E[M.x])),s.push(parseFloat(E[M.y])),s.push(parseFloat(E[M.z]))),M.rgb!==void 0){const x=t.fields.findIndex(se=>se==="rgb"),k=t.type[x],b=parseFloat(E[M.rgb]);let w=b;if(k==="F"){const se=new Float32Array(1);se[0]=b,w=new Int32Array(se.buffer)[0]}const $=(w>>16&255)/255,F=(w>>8&255)/255,J=(w>>0&255)/255;g.setRGB($,F,J,Bl.SRGBColorSpace),d.push(g.r,g.g,g.b)}M.normal_x!==void 0&&(v.push(parseFloat(E[M.normal_x])),v.push(parseFloat(E[M.normal_y])),v.push(parseFloat(E[M.normal_z]))),M.intensity!==void 0&&p.push(parseFloat(E[M.intensity])),M.label!==void 0&&y.push(parseInt(E[M.label]))}}if(t.data==="binary_compressed"){const M=new Uint32Array(l.slice(t.headerLen,t.headerLen+8)),S=M[0],K=M[1],I=r(new Uint8Array(l,t.headerLen+8,S),K),R=new DataView(I.buffer),j=t.offset;for(let E=0;E<t.points;E++){if(j.x!==void 0){const x=t.fields.indexOf("x"),k=t.fields.indexOf("y"),b=t.fields.indexOf("z");s.push(this._getDataView(R,t.points*j.x+t.size[x]*E,t.type[x],t.size[x])),s.push(this._getDataView(R,t.points*j.y+t.size[k]*E,t.type[k],t.size[k])),s.push(this._getDataView(R,t.points*j.z+t.size[b]*E,t.type[b],t.size[b]))}if(j.rgb!==void 0){const x=t.fields.indexOf("rgb"),k=R.getUint8(t.points*j.rgb+t.size[x]*E+2)/255,b=R.getUint8(t.points*j.rgb+t.size[x]*E+1)/255,w=R.getUint8(t.points*j.rgb+t.size[x]*E+0)/255;g.setRGB(k,b,w,Bl.SRGBColorSpace),d.push(g.r,g.g,g.b)}if(j.normal_x!==void 0){const x=t.fields.indexOf("normal_x"),k=t.fields.indexOf("normal_y"),b=t.fields.indexOf("normal_z");v.push(this._getDataView(R,t.points*j.normal_x+t.size[x]*E,t.type[x],t.size[x])),v.push(this._getDataView(R,t.points*j.normal_y+t.size[k]*E,t.type[k],t.size[k])),v.push(this._getDataView(R,t.points*j.normal_z+t.size[b]*E,t.type[b],t.size[b]))}if(j.intensity!==void 0){const x=t.fields.indexOf("intensity");p.push(this._getDataView(R,t.points*j.intensity+t.size[x]*E,t.type[x],t.size[x]))}if(j.label!==void 0){const x=t.fields.indexOf("label");y.push(R.getInt32(t.points*j.label+t.size[x]*E,this.littleEndian))}}}if(t.data==="binary"){const M=new DataView(l,t.headerLen),S=t.offset;for(let K=0,I=0;K<t.points;K++,I+=t.rowSize){if(S.x!==void 0){const R=t.fields.indexOf("x"),j=t.fields.indexOf("y"),E=t.fields.indexOf("z");s.push(this._getDataView(M,I+S.x,t.type[R],t.size[R])),s.push(this._getDataView(M,I+S.y,t.type[j],t.size[j])),s.push(this._getDataView(M,I+S.z,t.type[E],t.size[E]))}if(S.rgb!==void 0){const R=M.getUint8(I+S.rgb+2)/255,j=M.getUint8(I+S.rgb+1)/255,E=M.getUint8(I+S.rgb+0)/255;g.setRGB(R,j,E,Bl.SRGBColorSpace),d.push(g.r,g.g,g.b)}if(S.normal_x!==void 0){const R=t.fields.indexOf("normal_x"),j=t.fields.indexOf("normal_y"),E=t.fields.indexOf("normal_z");v.push(this._getDataView(M,I+S.normal_x,t.type[R],t.size[R])),v.push(this._getDataView(M,I+S.normal_y,t.type[j],t.size[j])),v.push(this._getDataView(M,I+S.normal_z,t.type[E],t.size[E]))}if(S.intensity!==void 0){const R=t.fields.indexOf("intensity");p.push(this._getDataView(M,I+S.intensity,t.type[R],t.size[R]))}S.label!==void 0&&y.push(M.getInt32(I+S.label,this.littleEndian))}}const c=new Bl.BufferGeometry;s.length>0&&c.setAttribute("position",new Bl.Float32BufferAttribute(s,3)),v.length>0&&c.setAttribute("normal",new Bl.Float32BufferAttribute(v,3)),d.length>0&&c.setAttribute("color",new Bl.Float32BufferAttribute(d,3)),p.length>0&&c.setAttribute("intensity",new Bl.Float32BufferAttribute(p,1)),y.length>0&&c.setAttribute("label",new Bl.Int32BufferAttribute(y,1)),c.computeBoundingSphere();const D=new Bl.PointsMaterial({size:.005});return d.length>0&&(D.vertexColors=!0),new Bl.Points(c,D)}}const xf=A.useModelComp(A.pinia),{systemPath:us}=A.storeToRefs(xf),vo=e.ref(),ds=new WeakMap;function wf(a,l,r,n,t){const s=async D=>{try{const M=await A.platformDownloadFile({url:D});if(M.status!==200)throw new Error(`下载失败: ${M.status}`);return M.data}catch(M){throw console.error("addModelFromUrl失败:",M),M}},v=D=>new Promise((M,S)=>{const K=new FileReader;K.onload=I=>{try{const R=I.target.result,E=new zn.MTLLoader().parse(R);E.preload(),M(E)}catch(R){S(R)}},K.onerror=()=>{S(new Error("MTL文件读取失败"))},K.readAsText(D)}),d=async D=>{const M={materials:{},create:function(S){return this.materials[S]?this.materials[S]:(console.warn(`Material '${S}' not found, using default material`),new Bl.MeshPhongMaterial({color:8947848,side:Bl.DoubleSide}))},getAsArray:function(){const S=[];for(const K in this.materials)S.push(this.materials[K]);return S},preload:function(){for(const S in this.materials)this.materials[S].map&&(this.materials[S].map.needsUpdate=!0)}};for(const S of D){const K=await v(S);Object.assign(M.materials,K.materials)}return M.preload(),M},p=async(D,M=[])=>new Promise((S,K)=>{const I=new FileReader;I.onload=async R=>{try{const j=R.target.result;let E=null;M&&M.length>0&&(M.length===1?E=await v(M[0]):E=await d(M));const x=new zn.OBJLoader;E&&x.setMaterials(E);const k=x.parse(j);E||k.traverse(b=>{b.isMesh&&(b.material=new Bl.MeshPhongMaterial({color:8947848,side:Bl.DoubleSide}))}),S(k)}catch(j){K(j)}},I.onerror=()=>{K(new Error("OBJ文件读取失败"))},I.readAsText(D)}),y=async D=>{var M;try{r.value=!0;const{scene:S}=a();if(!S)throw new Error("Scene not initialized");t();const K=[];for(let I=0;I<D.length;I++){const R=D[I];n.value=`正在加载模型 ${I+1}/${D.length}...`;const j=await s(R.objUrl),E=((M=R.objUrl)==null?void 0:M.split("/").pop())||`model_${I}.obj`,x=new File([j],E,{type:j.type});let k=[];if(R.mtlUrls){const w=Array.isArray(R.mtlUrls)?R.mtlUrls:[R.mtlUrls];for(let $=0;$<w.length;$++){const F=w[$],J=await s(F),se=(F==null?void 0:F.split("/").pop())||`material_${I}_${$}.mtl`,ge=new File([J],se,{type:J.type});k.push(ge)}}const b=await p(x,k);S.add(b),l.value.push(b),K.push(b)}return r.value=!1,K}catch(S){throw console.error("加载模型失败:",S),r.value=!1,S}},g=async(D,M,S=[],K=[])=>{let I;const R=D.toLowerCase();switch(R){case".txt":case".cpt":case".obj":const j=await M.text();if(R===".txt"||R===".cpt"){const le=/^(?!.*\bf\b)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?$/gm,te=[...j.matchAll(le)].map(oe=>({x:parseFloat(oe[1]),y:parseFloat(oe[2]),z:parseFloat(oe[3])})),ca=new Bl.BufferGeometry,Ee=te.flatMap(oe=>[oe.x,oe.y,oe.z]);if(ca.setAttribute("position",new Bl.Float32BufferAttribute(Ee,3)),R===".txt"){const oe=new Bl.PointsMaterial({color:"#5B5C99",size:1,sizeAttenuation:!1});I=new Bl.Points(ca,oe)}else if(R===".cpt"){const oe=new Bl.LineBasicMaterial({color:"#5B5C99",linewidth:100});I=new Bl.Line(ca,oe)}}else if(R===".obj"){const le=new zn.OBJLoader;if(S&&S.length>0){const ta=new zn.MTLLoader;for(const te of S){const ca=await te.text(),Ee=ta.parse(ca);Ee.preload(),le.setMaterials(Ee);break}}I=le.parse(j),(!S||S.length===0)&&I.traverse(ta=>{ta.isMesh&&(ta.material=new Bl.MeshPhongMaterial({color:"#B3B3D4"})),ta instanceof Bl.Mesh&&(ta.material.side=Bl.DoubleSide)})}break;case".stl":const E=await M.arrayBuffer(),k=new zn.STLLoader().parse(E),b=new Bl.MeshPhongMaterial({color:"#B3B3D4",side:Bl.DoubleSide});I=new Bl.Mesh(k,b);break;case".nc":const w=["Mach_B_Axis_0.STL","Mach_C_Axis_0.STL","Mach_X_Axis_0.STL","Mach_Y_Axis_0.STL","Mach_Z_Axis_0.STL","Mach_Spindle_0.STL"],$={"Mach_Y_Axis_0.STL":"rgb(128,118,152)","Mach_B_Axis_0.STL":"rgb(204,143,89)","Mach_C_Axis_0.STL":"rgb(145,245,251)","Mach_X_Axis_0.STL":"rgb(125,158,192)","Mach_Z_Axis_0.STL":"rgb(248,228,118)","Mach_Spindle_0.STL":"rgb(145,145,145)"},F=new Bl.Group,J=w.map(le=>new Promise((ta,te)=>{new zn.STLLoader().load(us.value===""?`/model/${le}`:`${us.value}\\${le}`,Ee=>{const oe=new Bl.MeshPhongMaterial({color:$[le]||"#B3B3D4",side:Bl.DoubleSide}),Te=new Bl.Mesh(Ee,oe);ta(Te)},void 0,te)}));try{(await Promise.all(J)).forEach(ta=>F.add(ta)),I=F}catch(le){throw console.error("加载NC文件对应的STL文件失败:",le),new Error("无法加载.NC文件对应的STL文件")}break;case".pcd":const se=new kf,ge=new Bl.Group;try{const le=await qa.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/target.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),ta=new Blob([le.data],{type:"application/octet-stream;charset=UTF-8"}),te=await qa.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/final.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),ca=new Blob([te.data],{type:"application/octet-stream;charset=UTF-8"}),Ee=await new Promise((Te,Ue)=>{const oa=URL.createObjectURL(ta);se.load(oa,Ja=>{const L=new Float32Array(Ja.geometry.attributes.position.count*3);for(let H=0;H<Ja.geometry.attributes.position.count;H++)L[H*3]=1,L[H*3+1]=0,L[H*3+2]=0;Ja.geometry.setAttribute("color",new Bl.BufferAttribute(L,3)),Ja.material.vertexColors=!0,Ja.scale.set(.3,.3,.3),URL.revokeObjectURL(oa),Te(Ja)},void 0,Ue)}),oe=await new Promise((Te,Ue)=>{const oa=URL.createObjectURL(ca);se.load(oa,Ja=>{const L=new Float32Array(Ja.geometry.attributes.position.count*3);for(let H=0;H<Ja.geometry.attributes.position.count;H++)L[H*3]=0,L[H*3+1]=1,L[H*3+2]=0;Ja.geometry.setAttribute("color",new Bl.BufferAttribute(L,3)),Ja.material.vertexColors=!0,Ja.scale.set(.3,.3,.3),URL.revokeObjectURL(oa),Te(Ja)},void 0,Ue)});ge.add(Ee),ge.add(oe),I=ge}catch(le){throw console.error("PCD文件加载失败:",le),new Error("无法加载PCD文件")}break;case".urdf":const Me=URL.createObjectURL(M),V=new Iu.URDFLoader,fe="http://139.196.154.85:20026/chfs/shared/机器人/urdf/SmallBender_R-2000iC-165F/meshes",ae={maxConcurrentLoads:4,enableCache:!0,enableLOD:!0,simplifyGeometry:!0,shareMaterials:!0,enableInstancing:!0},de=new WeakMap,De=new WeakMap,Fe=new WeakMap,ye=async le=>{if(de.has(le))return console.log(`从缓存加载: ${le}`),de.get(le);try{const ta=await qa.axios.get(`${fe}/${le}`,{responseType:"blob",headers:{"Content-Type":"application/json"},timeout:6e5}),te=new Blob([ta.data],{type:"application/octet-stream;charset=UTF-8"});return ae.enableCache&&de.set(le,te),te}catch(ta){throw console.error(`加载文件失败: ${le}`,ta),new Error(`无法加载文件: ${le}`)}},T=(le="default")=>{if(De.has(le))return De.get(le);const ta=new Bl.MeshPhongMaterial({color:12303291,shininess:30,transparent:!1,alphaTest:.1,side:Bl.FrontSide});return De.set(le,ta),ta},ue=le=>{try{le.isBufferGeometry&&le.mergeVertices&&le.mergeVertices(),le.computeVertexNormals&&le.computeVertexNormals(),le.computeBoundingSphere&&le.computeBoundingSphere(),le.deleteAttribute&&le.deleteAttribute("uv2")}catch(ta){console.warn("几何体优化失败,使用原始几何体:",ta)}return le},U=async(le,ta,te)=>{const ca=`stl_${ta}`;if(Fe.has(ca)){const Ue=Fe.get(ca);return new Bl.Mesh(Ue,T())}const Ee=await le.arrayBuffer();let Te=new zn.STLLoader(te).parse(Ee);return Te=ue(Te),Fe.set(ca,Te),new Bl.Mesh(Te,T())},Se=async(le,ta,te)=>{const ca=`obj_${ta}`;if(de.has(ca))return de.get(ca).clone();const Ee=await le.text(),oe=new zn.OBJLoader(te),Te=ta.replace(".obj",".mtl");try{const Ja=await(await ye(Te)).text(),H=new zn.MTLLoader(te).parse(Ja);H.preload(),oe.setMaterials(H)}catch{console.warn(`MTL文件加载失败,使用默认材质: ${Te}`)}const Ue=oe.parse(Ee);return Ue.traverse(oa=>{oa.isMesh&&(oa.geometry=ue(oa.geometry),oa.castShadow=!0,oa.receiveShadow=!0,oa.renderOrder=1)}),de.set(ca,Ue),Ue},Le=(le,ta)=>{const te=new Bl.LOD;if(te.addLevel(le,0),le.geometry){const ca=le.geometry.clone(),Ee=new Bl.Mesh(ca,le.material);te.addLevel(Ee,50)}return te};let Pe=0,la=0;const Da=[];V.loadMeshCb=async(le,ta,te,ca,Ee)=>{const oe=le.split("/").pop(),Te=te||(()=>{});Pe++;const Ue=new Promise(async(oa,Ja)=>{try{const L=await ye(oe);if(!L||L.size===0)throw new Error(`文件为空: ${oe}`);const H=oe.split(".").pop().toLowerCase();let Q;switch(H){case"stl":Q=await U(L,oe,ta);break;case"obj":Q=await Se(L,oe,ta);break;default:throw new Error(`不支持的文件格式: ${H}`)}ae.enableLOD&&Q.isMesh&&(Q=Le(Q,oe)),Te(Q),la++,ca&&ca({loaded:la,total:Pe,progress:la/Pe}),oa(Q)}catch(L){console.error(`mesh文件加载失败: ${oe}`,L);const H=new Bl.Group;Te(H),oa(H);const Q=new Bl.BoxGeometry(.1,.1,.1),me=new Bl.MeshStandardMaterial({color:16711680,wireframe:!0});return new Bl.Mesh(Q,me)}});Da.push(Ue)};try{if(!Me){vo.value=void 0;break}if(I=await V.loadAsync(Me),console.log(`URDF文件加载完成,等待${Pe}个mesh文件加载...`),Da.length>0)try{await Promise.allSettled(Da),console.log(`所有mesh文件处理完成,成功加载: ${la}/${Pe}`)}catch(te){console.warn("部分mesh文件加载失败,但继续显示模型",te)}I.traverse(te=>{te.isMesh&&(te.castShadow=!0,te.receiveShadow=!0,te.renderOrder=1,te.material&&(te.material.needsUpdate=!0))}),console.time("计算包围盒");const le=new Bl.Box3;le.expandByObject(I);const ta=`urdf_${Date.now()}`;I.userData.boundingBox=le.clone(),I.userData.modelId=ta,ds.set(ta,{box:le.clone(),center:le.getCenter(new Bl.Vector3),size:le.getSize(new Bl.Vector3),maxSize:Math.max(...le.getSize(new Bl.Vector3).toArray())}),vo.value=I,console.log("URDF模型加载完成并优化")}catch(le){console.error("URDF加载失败:",le),vo.value=void 0}finally{Me&&URL.revokeObjectURL(Me)}break;default:throw new Error(`不支持的文件格式: ${D}`)}return I};return{addModelsFromUrls:y,loadModelByDefaultPath:async D=>{console.log(D);try{r.value=!0,n.value="正在加载模型...";const{scene:M}=a();if(!M)throw new Error("Scene not initialized");t(),await new Promise(K=>setTimeout(K,100));const S=[];for(let K=0;K<D.length;K++){const I=D[K],R=await g(I.suffix,I.blob,I.mtlBlobs||[],I.meshFiles||[]);R&&(M.add(R),l.value.push(R),S.push(R))}return r.value=!1,n.value="",S}catch(M){throw console.error("加载模型失败:",M),r.value=!1,n.value="",M}},urdfModel:vo,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,t,s,v,d,p=function(c,D){D.parentNode.insertBefore(c,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(c){console&&console.log(c)}}n=function(){var c,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,(c=document.body).firstChild?p(D,c.firstChild):c.appendChild(D))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(n,0):(t=function(){document.removeEventListener("DOMContentLoaded",t,!1),n()},document.addEventListener("DOMContentLoaded",t,!1)):document.attachEvent&&(s=n,v=a.document,d=!1,g(),v.onreadystatechange=function(){v.readyState=="complete"&&(v.onreadystatechange=null,y())})}function y(){d||(d=!0,s())}function g(){try{v.documentElement.doScroll("left")}catch{return void setTimeout(g,50)}y()}})(window);const _f=["onClick"],Sf=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}},emits:["update:backGroundImage"],setup(a,{emit:l}){const r=a,n=l,t=e.ref(null),s=e.ref(null),v=e.computed(()=>{const x=Number(r==null?void 0:r.textSize),k=he.rgbaToColor(r==null?void 0:r.textColor),b={},w={};return!Number.isNaN(x)&&x&&(b.fontSize=`${x}px`,w.fontSize=`${x}px`),k&&(b.color=k,w.color=k),{label:b,value:w}}),d=e.ref(""),p=e.ref(""),y=e.ref(!1),g=async x=>{if(x){p.value&&(URL.revokeObjectURL(p.value),p.value="");try{const k=await A.platformDownloadFile({url:x}),b=new Blob([k==null?void 0:k.data],{type:(k==null?void 0:k.headers["content-type"])||"image/*"});p.value=URL.createObjectURL(b)}catch{p.value=""}}};e.watch(()=>r==null?void 0:r.backGroundImage,x=>{x&&(d.value=x)},{immediate:!0}),e.watch(d,x=>{g(x)},{immediate:!0});const c=()=>{var x;(x=s.value)==null||x.click()},D=async x=>{var w,$,F;const k=x.target,b=(w=k==null?void 0:k.files)==null?void 0:w[0];if(!b){k.value="";return}y.value=!0;try{const J=new FormData;J.append("file",b);const se=await A.platformUploadFile(J),ge=(F=($=se==null?void 0:se.data)==null?void 0:$.result)==null?void 0:F.url;ge?(d.value=ge,n("update:backGroundImage",ge),g(ge),qa.ElMessage.success("背景图片上传成功")):qa.ElMessage.error("背景图片上传失败")}catch{qa.ElMessage.error("背景图片上传失败")}finally{y.value=!1,k.value=""}},M=e.computed(()=>p.value?{backgroundImage:`url(${p.value})`,backgroundSize:"cover",backgroundPosition:"center",backgroundRepeat:"no-repeat"}:{}),S=x=>ll.getComponent(x),K=x=>{if(!x)return;const k=x.querySelector("input, textarea, .el-input__inner");k&&typeof k.focus=="function"&&k.focus()},I=(x,k,b)=>{r.disabled||x.field&&(t.value=k,e.nextTick(()=>{K(b.currentTarget)}))},R=()=>{t.value=null},j=x=>{var b;const k=((b=x==null?void 0:x.field)==null?void 0:b.value)??(x==null?void 0:x.value);return k==null||k===""?"-":k},E=x=>{const k=x!=null&&x.width&&x.width>0?x.width:1,w=`calc((100% - ${(k-1)*16}px) / ${k})`;return{flex:`0 0 ${w}`,maxWidth:w,minWidth:"140px",boxSizing:"border-box"}};return(x,k)=>(e.openBlock(),e.createElementBlock("div",{class:"statistics-cards-container",style:e.normalizeStyle(M.value),onClick:k[2]||(k[2]=b=>(r==null?void 0:r.backGround)&&c())},[r!=null&&r.backGround?(e.openBlock(),e.createElementBlock("div",{key:0,class:"form-backGround-upload",onClick:k[0]||(k[0]=e.withModifiers(b=>c(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:s,type:"file",accept:"image/*",style:{display:"none"},onChange:D},null,544),k[3]||(k[3]=e.createElementVNode("img",{src:ll._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.items,(b,w)=>{var $,F,J,se,ge,Me,V,fe;return e.openBlock(),e.createElementBlock("div",{class:"statistics-card",key:w,style:e.normalizeStyle(E(b)),onClick:k[1]||(k[1]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",{class:"statistics-label",style:e.normalizeStyle(v.value.label)},e.toDisplayString(b==null?void 0:b.label),5),e.createElementVNode("div",{class:"statistics-value",style:e.normalizeStyle(v.value.value),onClick:ae=>{var de;return(de=b.field)!=null&&de.isNoClick?null:I(b,w,ae)}},[t.value===w&&b.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(S((($=b.field)==null?void 0:$.type)??"Input")),{key:0,modelValue:b.field.value,"onUpdate:modelValue":ae=>b.field.value=ae,isEdit:!0,disabled:(F=b.field)==null?void 0:F.disabled,content:((J=b.field)==null?void 0:J.contents)??[],optionUrl:b.field,originalValue:(se=b.field)==null?void 0:se.value,config:(ge=b.field)==null?void 0:ge.config,configModel:((Me=b.field)==null?void 0:Me.prop)??((V=b.field)==null?void 0:V.name),selectedTagList:((fe=b.field)==null?void 0:fe.selectValue)??[],onBlur:R,onBlurChange:R},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(j(b)),1)],64))],12,_f)],4)}),128))],4))}}),Ef=Zl._export_sfc(Sf,[["__scopeId","data-v-d73001ab"]]),cc=A.defineStore("formToTableComp",{state:()=>({selectArray:[],selectString:""}),actions:{setSelectArray(a){this.selectArray=a},setSelectString(a){this.selectString=a}}}),Cf={class:"calculator-content"},Df={class:"calculator-child"},Bf={class:"calculator-child"},Nf=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,t)=>(e.openBlock(),e.createElementBlock("div",Cf,[e.createElementVNode("div",Df,[e.createVNode(ll.ssForm,{rowContents:l.value,isRowFlex:!0},null,8,["rowContents"])]),e.createElementVNode("div",Bf,[e.createVNode(ll.ssForm,{rowContents:r.value,isEdit:!1,isRowFlex:!0},null,8,["rowContents"])])]))}}),Tf=Zl._export_sfc(Nf,[["__scopeId","data-v-73db0fe7"]]),mt=(a,l)=>{let r=a,n=l;return Array.isArray(r)&&(r=r==null?void 0:r.map((t,s)=>{if(Array.isArray(t)){let v={};return t=t==null?void 0:t.forEach((d,p)=>{var y;(y=n==null?void 0:n[p])!=null&&y.prop?v[n[p].prop]=d:Array.isArray(d)&&(v.children=mt(d,n))}),Object.assign(v,{id:s})}else return t})),r},uc=(a,l,r)=>{let n=a,t=l;return n=n==null?void 0:n.map((s,v)=>{var d,p;return!Array.isArray(s)||!((d=t==null?void 0:t[v])!=null&&d.label)&&!r||(s.unshift(((p=t==null?void 0:t[v])==null?void 0:p.label)??""),s.some(y=>Array.isArray(y))&&(s=s==null?void 0:s.map(y=>{var g;return Array.isArray(y)&&(y=uc(y,(g=t==null?void 0:t[v])==null?void 0:g.children,r)),y}))),s}),n},Af=(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 zf(a,n,r)}},zf=(a,l,r)=>{let n=a,t=l;return(t==null?void 0:t.length)===0?n=n==null?void 0:n.filter(s=>s.id!==r):n=n==null?void 0:n.map(s=>(s.id.toString()===(t==null?void 0:t[0])&&(t==null||t.shift(),s=dc(s,t,r)),s)),n},dc=(a,l,r)=>{var s,v;let n=a,t=l;return(t==null?void 0:t.length)===0?n.children=(s=n.children)==null?void 0:s.filter(d=>d.id!==r):n.children=(v=n.children)==null?void 0:v.map(d=>(d.id.toString()===(t==null?void 0:t[0])&&(t==null||t.shift(),d=dc(d,t,r)),d)),n},Mf=(a,l,r)=>{if(l==="")return r;{const n=l.split("-");return If(a,n,r)}},If=(a,l,r)=>{let n=a,t=l;return(t==null?void 0:t.length)===0?n=r:n=n==null?void 0:n.map(s=>(s.id.toString()===(t==null?void 0:t[0])&&(t==null||t.shift(),s=pc(s,t,r)),s)),n},pc=(a,l,r)=>{var s;let n=a,t=l;return(t==null?void 0:t.length)===0?n.children=r:n.children=(s=n.children)==null?void 0:s.map(v=>(v.id.toString()===(t==null?void 0:t[0])&&(t==null||t.shift(),v=pc(v,t,r)),v)),n};class Of{constructor(l={}){Wr(this,"url");Wr(this,"heartbeatInterval");Wr(this,"socket",null);Wr(this,"isConnected",!1);Wr(this,"heartTimer",null);Wr(this,"canvas",null);Wr(this,"ctx",null);Wr(this,"mainCamCutMode",0);Wr(this,"pMainShowStartX",0);Wr(this,"pMainShowStartY",0);Wr(this,"onLog");Wr(this,"onDevCount");Wr(this,"onResolution");Wr(this,"onCameraStatus");Wr(this,"onPhoto");this.url=l.url??"ws://127.0.0.1:22225",this.heartbeatInterval=l.heartbeatInterval??3e3}init(l,r,n){var v;(v=this.canvas)!=null&&v.parentNode&&this.canvas.parentNode.removeChild(this.canvas);const t=document.createElement("canvas");t.style.border="solid 1px #A0A0A0",t.id="MainCamCanvas",t.width=r,t.height=n;const s=t.getContext("2d");if(!s)throw new Error("无法获取 CanvasRenderingContext2D");l.appendChild(t),this.canvas=t,this.ctx=s}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=t=>{this.isConnected=!1,this.log("socket.onerror"),r(t)},n.onclose=()=>{this.isConnected=!1,this.stopHeartbeat(),this.log("socket.onclose")},n.onmessage=t=>{this.handleMessage(t)}})}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(t=>t.width===2592&&t.height===1944);return r||[...l].sort((t,s)=>s.width*s.height-t.width*t.height)[0]||null}openCamera(l=0,r=1280,n=720){if(!this.canvas)throw new Error("请先 init() 传入容器并创建 canvas");const t=new Uint8Array(12);t[0]=119,t[1]=136,t[2]=1,t[3]=l,t[4]=this.canvas.width>>8&255,t[5]=this.canvas.width&255,t[6]=this.canvas.height>>8&255,t[7]=this.canvas.height&255,t[8]=r>>8&255,t[9]=r&255,t[10]=n>>8&255,t[11]=n&255,this.sendBytes(t)}closeCamera(){this.sendBytes(new Uint8Array([119,136,2,0]))}photo(){const t=new Uint8Array(12);t[0]=119,t[1]=136,t[2]=16,t[3]=0,t[4]=0,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t[9]=0,t[10]=0,t[11]=0,this.sendBytes(t)}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 t,s,v,d,p,y;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],c=r.length-4,D=new Uint8Array(c);for(let K=0;K<c;K++)D[K]=r[4+K];const S=decodeURIComponent(this.byteToString(D)).split("|");(t=this.onDevCount)==null||t.call(this,g,S);return}if(n===81){const g=r[3]||0,c=[];for(let D=0;D<g;D++){const M=(r[4+D*4+0]||0)*256+(r[4+D*4+1]||0),S=(r[4+D*4+2]||0)*256+(r[4+D*4+3]||0);c.push({width:M,height:S,text:`${M}*${S}`})}(s=this.onResolution)==null||s.call(this,g,c);return}if(n===1){r[3]===1&&((v=this.onCameraStatus)==null||v.call(this,"opened")),r[3]===3&&((d=this.onCameraStatus)==null||d.call(this,"closed"));return}if(n===16){if(r[3]===1){const c=r[4]*256+r[5],D=r[6]*65536+r[7]*256+r[8];let M="";if(c>0){const I=new Uint8Array(c);for(let R=0;R<c;R++)I[R]=r[9+R];M=decodeURIComponent(this.byteToString(I))}const S=new Uint8Array(D);for(let I=0;I<D;I++)S[I]=r[9+c+I];const K=this.uint8ArrayToString(S);(p=this.onPhoto)==null||p.call(this,{flag:0,imgPath:M,base64:K})}r[3]===2&&((y=this.onPhoto)==null||y.call(this,{flag:2,imgPath:"",base64:""}));return}if(n===204){if(!this.canvas||!this.ctx)return;const g=r[3]*256+r[4],c=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,c);let M=11;for(let S=0;S<D.data.length;S+=4)D.data[S+0]=r[M],D.data[S+1]=r[M+1],D.data[S+2]=r[M+2],D.data[S+3]=255,M+=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 Lf={style:{display:"flex",gap:"16px",height:"100%"}},Rf={key:0,style:{color:"var(--el-text-color-secondary)"}},$f={style:{width:"420px",display:"flex","flex-direction":"column",gap:"16px"}},Vf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px"}},Ff={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"}},Pf={key:0,style:{height:"100%",display:"flex","align-items":"center","justify-content":"center",color:"var(--el-text-color-secondary)"}},jf={key:1,style:{display:"grid","grid-template-columns":"repeat(2, minmax(0, 1fr))",gap:"8px"}},Hf=["src","onClick"],Uf=["onClick"],qf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px",flex:"1","min-height":"0",display:"flex","flex-direction":"column"}},Wf={class:"dialog-footer"},Kf=e.defineComponent({__name:"index",props:{visible:{type:Boolean,default:!1}},emits:["confirm","cancel"],setup(a,{emit:l}){const r=a,n=l,t=e.ref(null),s=e.ref(!1),v=e.ref([]),d=e.ref(""),p=e.ref(!1),y=e.ref([]),g=new Of({url:"ws://127.0.0.1:22225"});function c(F,J){var ae;const se=F.split(","),ge=((ae=se[0].match(/:(.*?);/))==null?void 0:ae[1])??"image/jpeg",Me=atob(se[1]);let V=Me.length;const fe=new Uint8Array(V);for(;V--;)fe[V]=Me.charCodeAt(V);return new File([fe],J,{type:ge})}function D(){g.onLog=F=>{console.log("[GPY]",F)},g.onDevCount=(F,J)=>{if(d.value+=`设备数量=${F},设备=${J.join(",")}
|
|
4
|
-
`,F>0){d.value+=`检测到设备,正在获取分辨率...
|
|
5
|
-
`;try{g.getResolution(0)}catch(se){d.value+=`获取分辨率失败:${(se==null?void 0:se.message)??se}
|
|
6
|
-
`}}else d.value+=`未检测到高拍仪设备!
|
|
7
|
-
`},g.onResolution=(F,J)=>{if(F<=0||!Array.isArray(J)||J.length===0){d.value+=`未获取到可用分辨率,回退使用 1280*720 打开...
|
|
8
|
-
`;try{g.openCamera(0,1280,720)}catch(ge){d.value+=`打开摄像头失败:${(ge==null?void 0:ge.message)??ge}
|
|
9
|
-
`}return}const se=g.chooseResolution(J);if(!se){d.value+=`分辨率选择失败,回退使用 1280*720 打开...
|
|
10
|
-
`;try{g.openCamera(0,1280,720)}catch(ge){d.value+=`打开摄像头失败:${(ge==null?void 0:ge.message)??ge}
|
|
11
|
-
`}return}d.value+=`获取分辨率 ${se.text}成功,打开摄像头...
|
|
12
|
-
`;try{g.closeCamera(),setTimeout(()=>{try{g.openCamera(0,se.width,se.height)}catch(ge){d.value+=`打开摄像头失败:${(ge==null?void 0:ge.message)??ge}
|
|
13
|
-
`}},100)}catch{try{g.openCamera(0,se.width,se.height)}catch(ge){d.value+=`打开摄像头失败:${(ge==null?void 0:ge.message)??ge}
|
|
14
|
-
`}}},g.onCameraStatus=F=>{F==="opened"?(s.value=!0,d.value+=`摄像头已打开
|
|
15
|
-
`):(s.value=!1,d.value+=`摄像头已关闭
|
|
16
|
-
`)},g.onPhoto=F=>{if(F.flag===0&&F.base64){const J=`data:image/jpeg;base64,${F.base64}`,se=c(J,`gpy-capture-${Date.now()}.jpg`);v.value.push({uid:`${Date.now()}_${Math.random().toString(16).slice(2)}`,url:J,file:se}),d.value+=`拍照完成,已接收图片(当前 ${v.value.length} 张)
|
|
17
|
-
`}else d.value+=`拍照失败 flag=${F.flag}
|
|
18
|
-
`}}const M=async()=>{if(await e.nextTick(),!t.value)return;S(),D();const F=t.value.getBoundingClientRect();g.init(t.value,Math.floor(F.width),Math.floor(F.height)),d.value+=`正在连接设备服务...
|
|
19
|
-
`,await g.connect(),d.value+=`正在获取设备数量...
|
|
20
|
-
`,g.getDevCount()},S=()=>{try{g.destroy()}catch(F){console.error(F)}s.value=!1,v.value=[],d.value="",p.value=!1,y.value=[]};e.watch(()=>r.visible,F=>{F?M():S()});const K=()=>{try{g.bestSize()}catch(F){console.error(F)}},I=()=>{try{g.rotateLeft()}catch(F){console.error(F)}},R=()=>{try{g.rotateRight()}catch(F){console.error(F)}},j=()=>{try{g.focus()}catch(F){console.error(F)}},E=()=>{d.value+=`正在拍照...
|
|
21
|
-
`;try{g.photo()}catch(F){d.value+=`拍照调用失败:${(F==null?void 0:F.message)??F}
|
|
22
|
-
`}},x=()=>{v.value.length>0?n("confirm",v.value.map(F=>F.file)):n("confirm",[])},k=F=>{F<0||F>=v.value.length||(v.value.splice(F,1),d.value+=`已删除一张图片(剩余 ${v.value.length} 张)
|
|
23
|
-
`)},b=F=>{if(!F)return;const J=`gpy-preview-${Date.now()}.jpg`;y.value=[{name:J,blobUrl:F}],p.value=!0},w=()=>{p.value=!1},$=()=>{S(),n("cancel")};return(F,J)=>{const se=e.resolveComponent("el-input"),ge=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(wr.ssDialog,{title:"扫描录入",visible:r.visible,onBeforeDestroy:$,width:"1200px",style:{height:"80%"}},{default:e.withCtx(()=>[e.createElementVNode("div",Lf,[e.createElementVNode("div",{ref_key:"cameraBox",ref:t,style:{flex:"1","min-width":"0",border:"1px solid var(--el-border-color)","border-radius":"4px",position:"relative",overflow:"hidden",display:"flex","align-items":"center","justify-content":"center",background:"var(--el-fill-color-lighter)"}},[s.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Rf,"初始化摄像头..."))],512),e.createElementVNode("div",$f,[e.createElementVNode("div",Vf,[J[0]||(J[0]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"拍照图片",-1)),e.createElementVNode("div",Ff,[v.value.length===0?(e.openBlock(),e.createElementBlock("div",Pf,"暂无图片")):(e.openBlock(),e.createElementBlock("div",jf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(v.value,(Me,V)=>(e.openBlock(),e.createElementBlock("div",{key:Me.uid,style:{position:"relative",border:"1px solid var(--el-border-color)","border-radius":"4px",overflow:"hidden",background:"#fafafa"}},[e.createElementVNode("img",{src:Me.url,onClick:fe=>b(Me.url),style:{width:"100%",height:"94px","object-fit":"contain",display:"block",background:"#fafafa",cursor:"zoom-in"},alt:"captured image",title:"点击放大"},null,8,Hf),e.createElementVNode("div",{onClick:fe=>k(V),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,Uf)]))),128))]))],512)]),e.createElementVNode("div",qf,[J[1]||(J[1]=e.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"操作记录",-1)),e.createVNode(se,{type:"textarea",value:d.value,readonly:"",rows:10,placeholder:"设备操作记录...",style:{flex:"1"}},null,8,["value"])])])])]),footer:e.withCtx(()=>[e.createElementVNode("div",Wf,[e.createVNode(ge,{onClick:K,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>J[2]||(J[2]=[e.createTextVNode("适屏")])),_:1,__:[2]},8,["disabled"]),e.createVNode(ge,{onClick:I,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>J[3]||(J[3]=[e.createTextVNode("左旋")])),_:1,__:[3]},8,["disabled"]),e.createVNode(ge,{onClick:R,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>J[4]||(J[4]=[e.createTextVNode("右旋")])),_:1,__:[4]},8,["disabled"]),e.createVNode(ge,{onClick:j,disabled:!s.value,id:"themeBorderButton"},{default:e.withCtx(()=>J[5]||(J[5]=[e.createTextVNode("对焦")])),_:1,__:[5]},8,["disabled"]),e.createVNode(ge,{onClick:E,disabled:!s.value,id:"themeButton"},{default:e.withCtx(()=>J[6]||(J[6]=[e.createTextVNode("拍照")])),_:1,__:[6]},8,["disabled"]),J[9]||(J[9]=e.createElementVNode("div",{style:{flex:"1"}},null,-1)),e.createVNode(ge,{onClick:x,disabled:v.value.length===0,id:"themeButton"},{default:e.withCtx(()=>J[7]||(J[7]=[e.createTextVNode("确认")])),_:1,__:[7]},8,["disabled"]),e.createVNode(ge,{onClick:$,id:"themeBorderButton"},{default:e.withCtx(()=>J[8]||(J[8]=[e.createTextVNode("取消")])),_:1,__:[8]})])]),_:1},8,["visible"]),p.value?(e.openBlock(),e.createBlock(ll.ssFilePreview,{key:0,fileDataList:y.value,onDestroy:w},null,8,["fileDataList"])):e.createCommentVNode("",!0)],64)}}}),Gf=Zl._export_sfc(Kf,[["__scopeId","data-v-24a2050a"]]),ps=A.useMenuState(A.pinia),Yf=async a=>{var s,v,d,p,y,g;let l=a==null?void 0:a.导入文件,r=a==null?void 0:a.函数参数,n=(s=l==null?void 0:l[0])==null?void 0:s.url,t="";if(!(n!=null&&n.includes("http"))||!(n!=null&&n.includes("https"))){ps.setContentLoading(!0);const c=await A.platformDownloadFile({url:n});let D=c==null?void 0:c.data;const M=new FormData;M.append("file",D,((v=l==null?void 0:l[0])==null?void 0:v.name)+"."+((d=n==null?void 0:n.split("."))==null?void 0:d[1])),M.append("query",r);let S=await Zs(M);S=(g=(y=(p=S==null?void 0:S.data)==null?void 0:p.data)==null?void 0:y.response)==null?void 0:g.replace("generateResult",a==null?void 0:a.函数名称),t=S,ps.setContentLoading(!1)}return t},Ct=A.defineStore("formComp",{state:()=>({objUrl:[],blobUrls:[]}),actions:{setObjUrl(a){this.objUrl=a},setBlobUrls(a){this.blobUrls=a}}}),Jf=A.useModelComp(A.pinia),{extraContents:ov}=A.storeToRefs(Jf),Xf=A.useLoginState(A.pinia),{extraUrl:ni}=A.storeToRefs(Xf);let fc=ni.value===""||!ni.value?"http://139.196.154.85:20015":ni.value;e.watch(()=>ni.value,()=>{fc=ni.value===""||!ni.value?"http://139.196.154.85:20015":ni.value},{deep:!0,immediate:!0});const Do={检校类型:["检校类型","证书类别"],证书编号:["证书编号"],设备名称:["设备名称","器具名称","样品名称","仪器名称","被校设备"],型号规格:["型号规格","型号/规格","型号"],出厂编号:["出厂编号","器具/管理编号","器具编号","管理编号","仪器编号"],制造厂:["制造厂","制造单位","制造厂商","制造商"],检校结果:["检校结果","检定结论","校准结果","校准/检定结果","检定结果"],依据文件:["依据文件","检定依据","检定所依据的技术文件","所依据/参照技术文件(代号/名称)","检定所依据的技术文件(编号/名称)","检定方法说明"],检校日期:["检校日期","校准日期","校验日期","检定日期","发证日期","发布日期","接收日期","签证日期"],有效日期:["有效日期","有效期","有效期至"]},fs={columnName:"OCR图片",acceptTypes:"image/*",maxSize:10,maxFiles:20,apiUrl:fc+"/api/public/paddleOCR"};class Zf{constructor(l){Wr(this,"config");this.config={...fs,...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=qa.Local.get(qa.accessTokenKey);return l?`Bearer ${l}`:""}buildOCRRequest(l,r){return{title:r,form:{OCR图片文件:l}}}async recognize(l,r){const n=this.getAuthorizationToken(),t=this.buildOCRRequest(l,r),s=this.config.apiUrl||fs.apiUrl||"";return(await qa.axios.post(s,t,{headers:{"Content-Type":"application/json",Authorization:n}})).data}getFieldAliases(l){return Do[l]?Do[l]:[l]}extractTableHeaders(l){const r=[],n=new Set,t=v=>{const d=v==null?void 0:v.label;return!(!d||d==="操作"||d===this.config.columnName||(v==null?void 0:v.type)==="operate"||(v==null?void 0:v.prop)==="operate")},s=v=>{(v||[]).forEach(d=>{if(!d)return;const p=(d==null?void 0:d.children)||(d==null?void 0:d.child)||(d==null?void 0:d.columns);if(Array.isArray(p)&&p.length>0){s(p);return}if(t(d)){const y=d.label;if(!n.has(y)){n.add(y);const g=this.getFieldAliases(y);r.push(g)}}})};return s(l||[]),r}}function hc(a){return new Zf(a)}hc();const yt=async(a,l)=>{var v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b;let r=(d=(v=A.cloneDeep(a))==null?void 0:v.optionUrl)==null?void 0:d.menuSelect,n=[];r==null||r.forEach(w=>{});let t="",s=await he.menuToParent(r);if(s==null||s.forEach(w=>{var $,F,J,se;(w==null?void 0:w.name)===(((se=(J=(F=($=A.cloneDeep(a))==null?void 0:$.optionUrl)==null?void 0:F.groupSelect)==null?void 0:J[0])==null?void 0:se.replaceAll("'",""))??"")&&(t=w==null?void 0:w.id)}),l){t=l;const w=await Tr.getInsofDataApi({id:t}),$=(c=(g=(y=(p=w==null?void 0:w.data)==null?void 0:p.result)==null?void 0:y[0])==null?void 0:g.key)==null?void 0:c.pageKey;s=await he.getItemData($,sessionStorage.getItem("systemKey"),"")}if(t!==""){let w;l?w=(D=s==null?void 0:s.find(J=>(J==null?void 0:J.id)===l))==null?void 0:D.compData:w=(M=s==null?void 0:s.find(J=>{var se,ge,Me,V;return(J==null?void 0:J.name)===(((ge=(se=a==null?void 0:a.groupSelect)==null?void 0:se.split(":"))==null?void 0:ge[0])||((V=(Me=a==null?void 0:a.optionUrl)==null?void 0:Me.groupSelect)==null?void 0:V[0]))}))==null?void 0:M.compData;let $=(K=(S=w==null?void 0:w.find(J=>(J==null?void 0:J.key)==="header"))==null?void 0:S.contents)==null?void 0:K.map(J=>J==null?void 0:J.label);(R=(I=w==null?void 0:w.find(J=>(J==null?void 0:J.key)==="header"))==null?void 0:I.contents)!=null&&R.every(J=>Array.isArray(J))&&($=(x=he.getColumnChild((E=(j=w==null?void 0:w.find(J=>(J==null?void 0:J.key)==="header"))==null?void 0:j.contents)==null?void 0:E[0]))==null?void 0:x.map(J=>J==null?void 0:J.prop));let F=(b=(k=w==null?void 0:w.find(J=>(J==null?void 0:J.key)==="tableContents"))==null?void 0:k.contents)==null?void 0:b.map(J=>{if(Array.isArray(J))J=J==null?void 0:J.filter(se=>!(se!=null&&se.id));else{let se={};for(let ge in J)ge!=="id"&&(se[ge]=J==null?void 0:J[ge]);J=se}return J});F==null||F.forEach(J=>{Array.isArray(J)?n.push(he.getValueToObjectValue(J,$)):n.push(J)})}return n},Qf=A.useMenuState(A.pinia),{activeMenuPath:tv}=A.storeToRefs(Qf),e0=A.useUnit(A.pinia),{chooseTitle:sv}=A.storeToRefs(e0),a0="col-operate",vc=a=>`${a0}-${a}`,l0=(a,l)=>{const r=new Map;a.forEach(t=>{const{prop:s}=t;r.set(s,t)});const n=t=>{Array.isArray(t)&&t.forEach(s=>{const{prop:v}=s||{},d=r.get(v);r0(d,s),Array.isArray(s==null?void 0:s.children)&&s.children.length>0&&n(s.children)})};return n(l),l},r0=(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),n0=(a,l)=>{const{sortable:r=!1,filterable:n=!1,showSummary:t=!1,operable:s=!1,fixed:v=!1}=l||{};return{prop:a,sortable:r,filterable:n,showSummary:t,operable:s,fixed:v}},i0=async a=>{var s,v;if(!a)return;const l=vc(a),r=await Tr.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:l}}),n=(s=r==null?void 0:r.data)==null?void 0:s.code,t=(v=r==null?void 0:r.data)==null?void 0:v.result;if(n==200)return t==null?void 0:t[0]},o0=async a=>{if(a)return[]},t0=async(a,l)=>{if(!a||!l)return;const r=vc(a);return await Tr.createInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:r},value:{columns:l}})},s0=async(a,l)=>!a||!l?void 0:await Tr.updateInsofDataApi({id:a,value:{columns:l}}),hs=async(a,l)=>{const r=sessionStorage.getItem("systemKey");if(!a||!l||!r)return;const n=await i0(a);return n?await s0(n==null?void 0:n.id,l):await t0(a,l)};var xo={exports:{}},c0=xo.exports,vs;function u0(){return vs||(vs=1,function(a,l){(function(r,n){n()})(c0,function(){function r(y,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(y.type)?new Blob(["\uFEFF",y],{type:y.type}):y}function n(y,g,c){var D=new XMLHttpRequest;D.open("GET",y),D.responseType="blob",D.onload=function(){p(D.response,g,c)},D.onerror=function(){console.error("could not download file")},D.send()}function t(y){var g=new XMLHttpRequest;g.open("HEAD",y,!1);try{g.send()}catch{}return 200<=g.status&&299>=g.status}function s(y){try{y.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),y.dispatchEvent(g)}}var v=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof A.commonjsGlobal=="object"&&A.commonjsGlobal.global===A.commonjsGlobal?A.commonjsGlobal:void 0,d=v.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),p=v.saveAs||(typeof window!="object"||window!==v?function(){}:"download"in HTMLAnchorElement.prototype&&!d?function(y,g,c){var D=v.URL||v.webkitURL,M=document.createElement("a");g=g||y.name||"download",M.download=g,M.rel="noopener",typeof y=="string"?(M.href=y,M.origin===location.origin?s(M):t(M.href)?n(y,g,c):s(M,M.target="_blank")):(M.href=D.createObjectURL(y),setTimeout(function(){D.revokeObjectURL(M.href)},4e4),setTimeout(function(){s(M)},0))}:"msSaveOrOpenBlob"in navigator?function(y,g,c){if(g=g||y.name||"download",typeof y!="string")navigator.msSaveOrOpenBlob(r(y,c),g);else if(t(y))n(y,g,c);else{var D=document.createElement("a");D.href=y,D.target="_blank",setTimeout(function(){s(D)})}}:function(y,g,c,D){if(D=D||open("","_blank"),D&&(D.document.title=D.document.body.innerText="downloading..."),typeof y=="string")return n(y,g,c);var M=y.type==="application/octet-stream",S=/constructor/i.test(v.HTMLElement)||v.safari,K=/CriOS\/[\d]+/.test(navigator.userAgent);if((K||M&&S||d)&&typeof FileReader<"u"){var I=new FileReader;I.onloadend=function(){var E=I.result;E=K?E:E.replace(/^data:[^;]*;/,"data:attachment/file;"),D?D.location.href=E:location=E,D=null},I.readAsDataURL(y)}else{var R=v.URL||v.webkitURL,j=R.createObjectURL(y);D?D.location=j:location.href=j,D=null,setTimeout(function(){R.revokeObjectURL(j)},4e4)}});v.saveAs=p.saveAs=p,a.exports=p})}(xo)),xo.exports}u0();const Hn=A.defineStore("tabComp",{state:()=>({itemData:[],originalData:[],extraContents:[],nodeDev:"",isEdit:"view",isRefreshCurStructure:!1,isSubmitCurStructure:!1,curStructureCompIds:[],itemGridData:[],itemExtendData:void 0,payloadTypes:"",lockingPage:"",systemPath:void 0,pageMapState:void 0,cacheUpdatingData:void 0,freshContent:!1,tableLoading:!1,routeToChildPath:"",tableViewContents:[],activeItemIndex:0,fixMenuStatus:!1,refreshTable:!1,selectTab:""}),actions:{setItemData(a){this.itemData=a},setCurStructureCompIds(a){this.curStructureCompIds=a},setRefreshCurStructure(a){this.isRefreshCurStructure=a},setOriginalData(a){this.originalData=a},setExtraContents(a){this.extraContents=a},setNodeDev(a){this.nodeDev=a},setIsEdit(a){this.isEdit=a},setSelectTab(a){this.selectTab=a}}}),d0=A.useLoginState(A.pinia),{loginUserInfo:st}=A.storeToRefs(d0),p0=async a=>{var n,t,s;let l=await A.getAllTables({platId:parseInt((n=st==null?void 0:st.value)==null?void 0:n.plat_id),tableNames:[a]});return l=(s=(t=l==null?void 0:l.data)==null?void 0:t.result)==null?void 0:s[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}]}]},f0=A.useLoginState(),{loginUserInfo:hl}=A.storeToRefs(f0);let mo="$R";const Br=A.useModelComp(A.pinia),mc=e.ref(!1),{itemData:h0,itemGridData:li,curStructureCompIds:ms,isSubmitCurStructure:v0,routeToChildPath:m0,pageMapState:gt,itemExtendData:yo,refreshTable:ys}=A.storeToRefs(Br),Oo=Hn(A.pinia),Ir=A.useMenuState(A.pinia),tr=e.shallowRef([]),{asideMenus:y0,activeTopMenuPath:g0,activeMenuPath:yl,platform:cv,buttonTriggerType:b0,currentMenuPath:Zr}=A.storeToRefs(Ir),dn=A.useUnit(A.pinia),{selectTitle:Fn,chooseTitle:Bo}=A.storeToRefs(dn);e.ref();const Di=e.ref(!0),jn=e.ref(0),bt=e.ref([]);e.ref(!1);const Dt=e.ref(!1),Ki=e.ref(),yc=e.ref(),gc=e.ref(),k0=()=>{Br.setItemGridData([]),Br.setIsEdit("edit"),Br.setSubmitCurStructure(yl.value!=="/平台管理/菜单管理")},x0=()=>{Br.setIsEdit("view"),Br.setRefreshCurStructure(!0)},w0=async a=>{var t;let l=Fn.value,r=l==null?void 0:l.findIndex(s=>(s==null?void 0:s.value)===(a==null?void 0:a.value)),n=l==null?void 0:l.filter((s,v)=>v<=r);dn.setSelectTitle(ll.safeClone(n)),n=(t=n==null?void 0:n.map(s=>s==null?void 0:s.value))==null?void 0:t.join("/"),Ir.setActiveMenuPath(null),Ir.setActiveMenuPath(n)},ct=async(a,l,r,n="contentConfig")=>{var t;try{if(!Array.isArray(a))return;let s,v;l==="create"?(s={dataList:a==null?void 0:a.map(p=>{var y;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:{...p,compData:(y=p==null?void 0:p.compData)==null?void 0:y.filter(g=>(g==null?void 0:g.key)!=="tableContents")}}}})},v=Tr.batchAddInsofDataApi):l==="update"?(s={dataList:a==null?void 0:a.map(p=>{var y;return{id:p==null?void 0:p.id,value:{pageData:{...p,compData:(y=p==null?void 0:p.compData)==null?void 0:y.filter(g=>(g==null?void 0:g.key)!=="tableContents")}}}})},v=Tr.batchUpdateInsofDataApi):l==="delete"&&(s={ids:a},v=Tr.batchDeleteInsofDataApi);const d=await v(s);if(((t=d==null?void 0:d.data)==null?void 0:t.code)===200)return d.data.result;throw qa.ElMessage.error("保存响应失败"),new Error("保存响应失败")}catch{qa.ElMessage.error("保存响应失败")}},gs=async(a,l,r,n)=>{var t,s,v,d,p,y,g,c,D,M,S;try{const K=(s=(t=a==null?void 0:a.results)==null?void 0:t.filter(k=>!(k!=null&&k.id)||typeof(k==null?void 0:k.id)=="string"))==null?void 0:s.map(k=>({key:{pageKey:a==null?void 0:a.pageKey,systemKey:sessionStorage.getItem("systemKey"),type:l,relatedInfo:r},value:{tableData:k}})),I=(d=(v=a==null?void 0:a.results)==null?void 0:v.filter(k=>(k==null?void 0:k.id)&&typeof(k==null?void 0:k.id)=="number"))==null?void 0:d.map(k=>({id:k==null?void 0:k.id,value:{tableData:k}})),R=JSON.parse(JSON.stringify(a)),j=(p=R==null?void 0:R.results)==null?void 0:p.map(k=>k.id);let E;r?E=(c=(g=(y=gt.value)==null?void 0:y[yl.value])==null?void 0:g.filter(k=>{var b,w,$;return((b=k==null?void 0:k.key)==null?void 0:b.type)===l&&(($=(w=k==null?void 0:k.key)==null?void 0:w.relatedInfo)==null?void 0:$.target)===n}))==null?void 0:c.map(k=>k==null?void 0:k.id):E=(S=(M=(D=gt.value)==null?void 0:D[yl.value])==null?void 0:M.filter(k=>{var b;return((b=k==null?void 0:k.key)==null?void 0:b.type)===l}))==null?void 0:S.map(k=>k==null?void 0:k.id);const x=E==null?void 0:E.filter(k=>!(j!=null&&j.includes(k))&&typeof k=="number");(K==null?void 0:K.length)>0&&await Tr.batchAddInsofDataApi({dataList:K}),(I==null?void 0:I.length)>0&&await Tr.batchUpdateInsofDataApi({dataList:I}),(x==null?void 0:x.length)>0&&await Tr.batchDeleteInsofDataApi({ids:x})}catch(K){throw new Error(K)}},_0=async a=>{var y,g,c,D,M,S,K,I,R,j;Ir.setContentLoading(!0);const l=JSON.parse(JSON.stringify(h0.value));if(!v0.value)return Ir.setCacheStructures({key:b0.value,data:l}),qa.ElMessage.success("已暂存");const r=l==null?void 0:l.map(E=>E.id),n=r.filter(E=>{var x;return!((x=ms.value)!=null&&x.includes(E))}),t=(y=ms.value)==null?void 0:y.filter(E=>!r.includes(E)),s=[...n,...t].filter(E=>typeof E!==null&&typeof E<"u"),v=l==null?void 0:l.filter(E=>!E.id),d=l==null?void 0:l.filter(E=>E.id);let p=[];if(s&&(s==null?void 0:s.length)>0&&p.push(ct(s,"delete",a)),v&&(v==null?void 0:v.length)>0&&p.push(ct(v,"create",a)),d&&(d==null?void 0:d.length)>0&&p.push(ct(d,"update",a)),li.value&&((g=li.value)!=null&&g.isDelete&&((D=(c=li.value)==null?void 0:c.results)==null?void 0:D.length)>0&&((S=(M=li.value)==null?void 0:M.results)!=null&&S.every(E=>typeof E=="number"))?await Tr.batchDeleteInsofDataApi({ids:(K=li.value)==null?void 0:K.results}):(console.log("itemGridData.value",li.value),p.push(await gs(li.value,"gridLayout")))),yo.value)for(const E in yo.value)p.push(await gs((I=yo.value)==null?void 0:I[E],"extend",{target:E,compId:(j=(R=yo.value)==null?void 0:R[E])==null?void 0:j.compId},E));await Promise.all(p).then(()=>{qa.ElMessage.success("保存成功"),Br.setRefreshCurStructure(!0)}).catch(E=>{qa.ElMessage.success(E)}),Ir.setContentLoading(!1)},Gi=a=>Bi(a),S0=e.computed(()=>{var a;return(a=tr.value)==null?void 0:a.filter(l=>(l==null?void 0:l.affix)&&(l==null?void 0:l.affix)!=="default")}),bc=e.computed(()=>{var a;return(a=tr.value)==null?void 0:a.filter(l=>!(l!=null&&l.affix&&(l==null?void 0:l.affix)!=="default"))}),kc=e.ref(0),xc=e.ref(null),E0="ocr_committed_temp_ids_v1",C0=(a,l)=>`${E0}:${String(a??"")}:${String(l??"")}`,D0=(a,l,r)=>{try{const n=C0(a,l),t=sessionStorage.getItem(n),s=t?JSON.parse(t):[],v=Array.isArray(s)?s:[],d=Array.from(new Set([...v,...r||[]].map(p=>String(p)))).slice(-200);sessionStorage.setItem(n,JSON.stringify(d))}catch{}},No=async(a,l="data",r)=>{var t,s,v,d,p,y,g,c,D,M,S,K,I,R,j,E,x,k,b,w,$,F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja,L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q,Be,Je,ra,ba,ga,Aa,_a,Oe,Za,Ha,xl,Jl,kl,Pl,ja,Ml,$l;let n=((v=(s=(t=Fn.value)==null?void 0:t.filter(Ma=>(Ma==null?void 0:Ma.condition)==="child"))==null?void 0:s[0])==null?void 0:v.value)??"";if((a==null?void 0:a.buttonName)==="新增"){let Ma=(d=a==null?void 0:a.fixContent)==null?void 0:d.map(we=>{let ia={};for(let Ie in we)Array.isArray(we==null?void 0:we[Ie])?ia[Ie]=JSON.stringify(we==null?void 0:we[Ie]):ia[Ie]=we==null?void 0:we[Ie];return ia}),rl=await A.quoteApi({platId:parseInt((p=hl==null?void 0:hl.value)==null?void 0:p.plat_id),type:"fatherSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});rl=(y=rl==null?void 0:rl.data)==null?void 0:y.result,rl=rl==null?void 0:rl.filter(we=>{var ia,Ie;return!((we==null?void 0:we.fatherPath)!==""&&((Ie=(ia=we==null?void 0:we.quote)==null?void 0:ia[0])==null?void 0:Ie.menus)===(yl==null?void 0:yl.value))});let sl=rl==null?void 0:rl.map(we=>{var ha,va;let ia={},Ie=Ma==null?void 0:Ma[0],pe;return Array.isArray((ha=we==null?void 0:we.struct)==null?void 0:ha[0])?pe=he.getColumnChild((va=we==null?void 0:we.struct)==null?void 0:va[0]):pe=we==null?void 0:we.struct,pe=pe==null?void 0:pe.filter(Xe=>(Xe==null?void 0:Xe.prop)!=="relatedId"),pe==null||pe.forEach(Xe=>{var Ze,Ke;ia[Xe.prop]=((Ze=Xe==null?void 0:Xe.words)!=null&&Ze[0]?(Ie==null?void 0:Ie[(Ke=Xe==null?void 0:Xe.words)==null?void 0:Ke[0]])??(Ie==null?void 0:Ie[Xe==null?void 0:Xe.prop]):Ie==null?void 0:Ie[Xe==null?void 0:Xe.prop])??""}),ia.id="1",ia.relatedId=`[${ia.id}]`,delete ia.sort,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[ia]}}),ma=[{tableName:(g=a==null?void 0:a.relatedContents)==null?void 0:g.find(we=>we==null?void 0:we.includes("content")),tableContents:Ma}];ma=[...ma,...sl];let ka=await A.quoteApi({platId:parseInt((c=hl==null?void 0:hl.value)==null?void 0:c.plat_id),type:"sonSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});ka=(M=(D=ka==null?void 0:ka.data)==null?void 0:D.result)==null?void 0:M.filter(we=>!(ma!=null&&ma.find(ia=>(ia==null?void 0:ia.tableName)==="content_"+(we==null?void 0:we.id)))),ka=ka==null?void 0:ka.filter(we=>{var ia,Ie;return!((we==null?void 0:we.fatherPath)!==""&&((Ie=(ia=we==null?void 0:we.quote)==null?void 0:ia[0])==null?void 0:Ie.menus)===(yl==null?void 0:yl.value))});let La=ka==null?void 0:ka.map(we=>{var ha,va,Xe,Ze,Ke,pl,Ve;let ia={},Ie=Ma==null?void 0:Ma[0],pe;return Array.isArray((ha=we==null?void 0:we.struct)==null?void 0:ha[0])?pe=he.getColumnChild((va=we==null?void 0:we.struct)==null?void 0:va[0]):pe=we==null?void 0:we.struct,pe=pe==null?void 0:pe.filter(Fa=>(Fa==null?void 0:Fa.prop)!=="relatedId"),((Ze=(Xe=pe==null?void 0:pe[0])==null?void 0:Xe.words)!=null&&Ze[0]?Ie!=null&&Ie[(pl=(Ke=pe==null?void 0:pe[0])==null?void 0:Ke.words)==null?void 0:pl[0]]:Ie!=null&&Ie[(Ve=pe==null?void 0:pe[0])==null?void 0:Ve.prop])?(pe==null||pe.forEach(Fa=>{var Sa,il;ia[Fa.prop]=((Sa=Fa==null?void 0:Fa.words)!=null&&Sa[0]?(Ie==null?void 0:Ie[(il=Fa==null?void 0:Fa.words)==null?void 0:il[0]])??(Ie==null?void 0:Ie[Fa==null?void 0:Fa.prop]):Ie==null?void 0:Ie[Fa==null?void 0:Fa.prop])??""}),ia.id="1",ia.relatedId=`[${ia.id}]`,delete ia.sort):ia=void 0,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[ia]}});La=La==null?void 0:La.filter(we=>{var ia;return!((ia=we==null?void 0:we.tableContents)!=null&&ia.every(Ie=>Ie===void 0))}),ma=[...ma,...La],await A.pageBatchAddApi({platId:parseInt((S=hl==null?void 0:hl.value)==null?void 0:S.plat_id),changeContents:ma});let $a=[];ma==null||ma.forEach(we=>{var ia;(ia=we==null?void 0:we.tableContents)==null||ia.forEach(Ie=>{$a.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Ie),request_result:"{}",is_delete:!1,request_table:we==null?void 0:we.tableName,request_type:"add"})})}),await A.pageBatchAddApi({platId:parseInt((K=hl==null?void 0:hl.value)==null?void 0:K.plat_id),changeContents:[{tableName:"log",tableContents:$a}]})}if((a==null?void 0:a.buttonName)==="OCR批量新增"){const Ma=((a==null?void 0:a.ocrRows)||[]).map(ka=>ka==null?void 0:ka.id).filter(ka=>ka!=null),rl=((a==null?void 0:a.ocrRows)||[]).map(ka=>{const La={...ka};return delete La._isOCRRow,delete La._ocrTableId,Object.keys(La).forEach($a=>{/(^|\.)证书附件$/.test($a)&&Array.isArray(La[$a])&&(La[$a]=JSON.stringify(La[$a].map(we=>({url:(we==null?void 0:we.url)||"",name:(we==null?void 0:we.name)||(we==null?void 0:we.fileName)||"",fileName:(we==null?void 0:we.fileName)||(we==null?void 0:we.name)||""})).filter(we=>we.url||we.name)))}),La});let sl=[{tableName:(I=a==null?void 0:a.relatedContents)==null?void 0:I.find(ka=>ka==null?void 0:ka.includes("content")),tableContents:rl}];await A.pageBatchAddApi({platId:parseInt((R=hl==null?void 0:hl.value)==null?void 0:R.plat_id),changeContents:sl});let ma=[];sl==null||sl.forEach(ka=>{var La;(La=ka==null?void 0:ka.tableContents)==null||La.forEach($a=>{ma.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify($a),request_result:"{}",is_delete:!1,request_table:ka==null?void 0:ka.tableName,request_type:"ocrBatchAdd"})})}),await A.pageBatchAddApi({platId:parseInt((j=hl==null?void 0:hl.value)==null?void 0:j.plat_id),changeContents:[{tableName:"log",tableContents:ma}]}),D0(a==null?void 0:a.parentTableId,a==null?void 0:a.index,Ma)}if((a==null?void 0:a.buttonName)==="编辑"){const rl=((a==null?void 0:a.fixContent)||(a==null?void 0:a.singleContent)||[]||[]).map(pe=>{const ha={...pe};return delete ha._isOCRRow,delete ha._ocrTableId,delete ha._isTemp,delete ha.tableEditType,delete ha.index,ha});let sl=rl==null?void 0:rl.map(pe=>{let ha={};for(let va in pe)Array.isArray(pe==null?void 0:pe[va])?ha[va]=JSON.stringify(pe==null?void 0:pe[va]):ha[va]=pe==null?void 0:pe[va];return ha}),ma=await A.quoteApi({platId:parseInt((E=hl==null?void 0:hl.value)==null?void 0:E.plat_id),type:"fatherSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});ma=(x=ma==null?void 0:ma.data)==null?void 0:x.result,ma=ma==null?void 0:ma.filter(pe=>{var ha,va;return!((pe==null?void 0:pe.fatherPath)!==""&&((va=(ha=pe==null?void 0:pe.quote)==null?void 0:ha[0])==null?void 0:va.menus)===(yl==null?void 0:yl.value))});let ka=(k=sl==null?void 0:sl[0])==null?void 0:k.id,La=[{tableName:(b=a==null?void 0:a.relatedContents)==null?void 0:b.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:sl}],$a=(w=ma==null?void 0:ma.map(pe=>{var va,Xe,Ze,Ke,pl;let ha=(va=pe==null?void 0:pe.contents)==null?void 0:va.filter(Ve=>{var Fa,Sa;return JSON.stringify(Ve==null?void 0:Ve.relatedId)!=="{}"&&(Ve==null?void 0:Ve.relatedId)!==""&&(Ve!=null&&Ve.relatedId)?(Fa=Ve==null?void 0:Ve.relatedId)==null?void 0:Fa.includes(parseInt(ka)):(Ve==null?void 0:Ve.sort)===((Sa=sl==null?void 0:sl[0])==null?void 0:Sa.sort)});if((ha==null?void 0:ha.length)>0){let Ve=sl==null?void 0:sl[0];Ve={...Ve,id:(Xe=ha==null?void 0:ha[0])==null?void 0:Xe.id};let Fa={},Sa=Ve,il;return Array.isArray((Ze=pe==null?void 0:pe.struct)==null?void 0:Ze[0])?il=he.getColumnChild((Ke=pe==null?void 0:pe.struct)==null?void 0:Ke[0]):il=pe==null?void 0:pe.struct,il=il==null?void 0:il.filter(Ia=>(Ia==null?void 0:Ia.prop)!=="relatedId"),il==null||il.forEach(Ia=>{var ze,_l;Fa[Ia.prop]=((ze=Ia==null?void 0:Ia.words)!=null&&ze[0]?(Sa==null?void 0:Sa[(_l=Ia==null?void 0:Ia.words)==null?void 0:_l[0]])??(Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop]):Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop])??""}),Fa.id=(pl=ha==null?void 0:ha[0])==null?void 0:pl.id,delete Fa.sort,delete Fa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Fa]}}else return}))==null?void 0:w.filter(pe=>pe);La=[...La,...$a];let we=await A.quoteApi({platId:parseInt(($=hl==null?void 0:hl.value)==null?void 0:$.plat_id),type:"sonSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});we=(J=(F=we==null?void 0:we.data)==null?void 0:F.result)==null?void 0:J.filter(pe=>!(La!=null&&La.find(ha=>(ha==null?void 0:ha.tableName)==="content_"+(pe==null?void 0:pe.id)))),we=we==null?void 0:we.filter(pe=>{var ha,va;return!((pe==null?void 0:pe.fatherPath)!==""&&((va=(ha=pe==null?void 0:pe.quote)==null?void 0:ha[0])==null?void 0:va.menus)===(yl==null?void 0:yl.value))});let ia=(se=we==null?void 0:we.map(pe=>{var va,Xe,Ze,Ke,pl;let ha=(va=pe==null?void 0:pe.contents)==null?void 0:va.filter(Ve=>{var Fa,Sa,il;return JSON.stringify(Ve==null?void 0:Ve.relatedId)!=="{}"&&(Ve==null?void 0:Ve.relatedId)!==""&&(Ve!=null&&Ve.relatedId)?(Fa=Ve==null?void 0:Ve.relatedId)==null?void 0:Fa.includes(parseInt(ka)):(Ve==null?void 0:Ve.sort)===((Sa=sl==null?void 0:sl[0])==null?void 0:Sa.sort)||(Ve==null?void 0:Ve.sort)===(parseInt(((il=sl==null?void 0:sl[0])==null?void 0:il.sort)??"0")+1).toString()});if((ha==null?void 0:ha.length)>0){let Ve=sl==null?void 0:sl[0];Ve={...Ve,id:(Xe=ha==null?void 0:ha[0])==null?void 0:Xe.id};let Fa={},Sa=Ve,il;return Array.isArray((Ze=pe==null?void 0:pe.struct)==null?void 0:Ze[0])?il=he.getColumnChild((Ke=pe==null?void 0:pe.struct)==null?void 0:Ke[0]):il=pe==null?void 0:pe.struct,il=il==null?void 0:il.filter(Ia=>(Ia==null?void 0:Ia.prop)!=="relatedId"),il==null||il.forEach(Ia=>{var ze,_l,Ol,ql;((ze=Ia==null?void 0:Ia.words)!=null&&ze[0]?(Sa==null?void 0:Sa[(_l=Ia==null?void 0:Ia.words)==null?void 0:_l[0]])??(Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop]):Sa!=null&&Sa[Ia==null?void 0:Ia.prop])&&(Fa[Ia.prop]=((Ol=Ia==null?void 0:Ia.words)!=null&&Ol[0]?(Sa==null?void 0:Sa[(ql=Ia==null?void 0:Ia.words)==null?void 0:ql[0]])??(Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop]):Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop])??"")}),Fa.id=(pl=ha==null?void 0:ha[0])==null?void 0:pl.id,delete Fa.sort,delete Fa.relatedId,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Fa]}}else return}))==null?void 0:se.filter(pe=>pe);La=[...La,...ia],await A.pageBatchUpdateApi({platId:parseInt((ge=hl==null?void 0:hl.value)==null?void 0:ge.plat_id),changeContents:La});let Ie=[];La==null||La.forEach(pe=>{var ha;(ha=pe==null?void 0:pe.tableContents)==null||ha.forEach(va=>{Ie.push({id:"1",request_method:"Post",request_url:"/platform/page/update",request_param:JSON.stringify(va),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"update"})})}),await A.pageBatchAddApi({platId:parseInt((Me=hl==null?void 0:hl.value)==null?void 0:Me.plat_id),changeContents:[{tableName:"log",tableContents:Ie}]})}if((a==null?void 0:a.buttonName)==="删除"){let Ma=[{tableName:(V=a==null?void 0:a.relatedContents)==null?void 0:V.find(we=>we==null?void 0:we.includes("content")),tableContents:a==null?void 0:a.fixContent}],rl=await A.quoteApi({platId:parseInt((fe=hl==null?void 0:hl.value)==null?void 0:fe.plat_id),type:"fatherSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});rl=(ae=rl==null?void 0:rl.data)==null?void 0:ae.result,rl=rl==null?void 0:rl.filter(we=>{var ia,Ie;return!((we==null?void 0:we.fatherPath)!==""&&((Ie=(ia=we==null?void 0:we.quote)==null?void 0:ia[0])==null?void 0:Ie.menus)===(yl==null?void 0:yl.value))});let sl=(De=(de=a==null?void 0:a.fixContent)==null?void 0:de[0])==null?void 0:De.id,ma=(Fe=rl==null?void 0:rl.map(we=>{var Ie,pe,ha,va,Xe,Ze;let ia=(Ie=we==null?void 0:we.contents)==null?void 0:Ie.filter(Ke=>{var pl,Ve,Fa;return JSON.stringify(Ke==null?void 0:Ke.relatedId)!=="{}"&&(Ke==null?void 0:Ke.relatedId)!==""&&(Ke!=null&&Ke.relatedId)?(pl=Ke==null?void 0:Ke.relatedId)==null?void 0:pl.includes(parseInt(sl)):(Ke==null?void 0:Ke.sort)===((Fa=(Ve=a==null?void 0:a.fixContent)==null?void 0:Ve[0])==null?void 0:Fa.sort)});if((ia==null?void 0:ia.length)>0){let Ke=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];Ke={...Ke,id:(ha=ia==null?void 0:ia[0])==null?void 0:ha.id};let pl={},Ve=Ke,Fa;return Array.isArray((va=we==null?void 0:we.struct)==null?void 0:va[0])?Fa=he.getColumnChild((Xe=we==null?void 0:we.struct)==null?void 0:Xe[0]):Fa=we==null?void 0:we.struct,Fa=Fa==null?void 0:Fa.filter(Sa=>(Sa==null?void 0:Sa.prop)!=="relatedId"),Fa==null||Fa.forEach(Sa=>{var il,Ia;pl[Sa.prop]=((il=Sa==null?void 0:Sa.words)!=null&&il[0]?(Ve==null?void 0:Ve[(Ia=Sa==null?void 0:Sa.words)==null?void 0:Ia[0]])??(Ve==null?void 0:Ve[Sa==null?void 0:Sa.prop]):Ve==null?void 0:Ve[Sa==null?void 0:Sa.prop])??""}),pl.id=(Ze=ia==null?void 0:ia[0])==null?void 0:Ze.id,delete pl.sort,delete pl.relatedId,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[pl]}}else return}))==null?void 0:Fe.filter(we=>we);Ma=[...Ma,...ma];let ka=await A.quoteApi({platId:parseInt((ye=hl==null?void 0:hl.value)==null?void 0:ye.plat_id),type:"sonSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});ka=(ue=(T=ka==null?void 0:ka.data)==null?void 0:T.result)==null?void 0:ue.filter(we=>!(Ma!=null&&Ma.find(ia=>(ia==null?void 0:ia.tableName)==="content_"+(we==null?void 0:we.id)))),ka=ka==null?void 0:ka.filter(we=>{var ia,Ie;return!((we==null?void 0:we.fatherPath)!==""&&((Ie=(ia=we==null?void 0:we.quote)==null?void 0:ia[0])==null?void 0:Ie.menus)===(yl==null?void 0:yl.value))});let La=(U=ka==null?void 0:ka.map(we=>{var Ie,pe,ha,va,Xe,Ze;let ia=(Ie=we==null?void 0:we.contents)==null?void 0:Ie.filter(Ke=>{var pl,Ve,Fa;return JSON.stringify(Ke==null?void 0:Ke.relatedId)!=="{}"&&(Ke==null?void 0:Ke.relatedId)!==""&&(Ke!=null&&Ke.relatedId)?(pl=Ke==null?void 0:Ke.relatedId)==null?void 0:pl.includes(parseInt(sl)):(Ke==null?void 0:Ke.sort)===((Fa=(Ve=a==null?void 0:a.fixContent)==null?void 0:Ve[0])==null?void 0:Fa.sort)});if((ia==null?void 0:ia.length)>0){let Ke=(pe=a==null?void 0:a.fixContent)==null?void 0:pe[0];Ke={...Ke,id:(ha=ia==null?void 0:ia[0])==null?void 0:ha.id};let pl={},Ve=Ke,Fa;return Array.isArray((va=we==null?void 0:we.struct)==null?void 0:va[0])?Fa=he.getColumnChild((Xe=we==null?void 0:we.struct)==null?void 0:Xe[0]):Fa=we==null?void 0:we.struct,Fa=Fa==null?void 0:Fa.filter(Sa=>(Sa==null?void 0:Sa.prop)!=="relatedId"),Fa==null||Fa.forEach(Sa=>{var il,Ia;pl[Sa.prop]=((il=Sa==null?void 0:Sa.words)!=null&&il[0]?(Ve==null?void 0:Ve[(Ia=Sa==null?void 0:Sa.words)==null?void 0:Ia[0]])??(Ve==null?void 0:Ve[Sa==null?void 0:Sa.prop]):Ve==null?void 0:Ve[Sa==null?void 0:Sa.prop])??""}),pl.id=(Ze=ia==null?void 0:ia[0])==null?void 0:Ze.id,delete pl.sort,delete pl.relatedId,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[pl]}}else return}))==null?void 0:U.filter(we=>we);Ma=[...Ma,...La],await A.pageBatchDeleteApi({platId:parseInt((Se=hl==null?void 0:hl.value)==null?void 0:Se.plat_id),changeContents:Ma});let $a=[];Ma==null||Ma.forEach(we=>{var ia;(ia=we==null?void 0:we.tableContents)==null||ia.forEach(Ie=>{$a.push({id:"1",request_method:"Post",request_url:"/platform/page/delete",request_param:JSON.stringify(Ie),request_result:"{}",is_delete:!1,request_table:we==null?void 0:we.tableName,request_type:"delete"})})}),await A.pageBatchAddApi({platId:parseInt((Le=hl==null?void 0:hl.value)==null?void 0:Le.plat_id),changeContents:[{tableName:"log",tableContents:$a}]})}if((a==null?void 0:a.buttonName)==="复制新增"){let Ma=await A.getPageDataApi({platId:parseInt((Pe=hl==null?void 0:hl.value)==null?void 0:Pe.plat_id),pageName:"menu"});if(Ma=(la=Ma==null?void 0:Ma.data)==null?void 0:la.result,Ma!=null&&Ma.find(rl=>(rl==null?void 0:rl.father_name)===yl.value+"/")){gc.value=a,yc.value=Ma==null?void 0:Ma.filter(ma=>(ma==null?void 0:ma.father_name)===yl.value+"/");let rl=(le=(Da=a==null?void 0:a.columns)==null?void 0:Da.find(ma=>ma==null?void 0:ma.mainKey))==null?void 0:le.prop,sl=(te=(ta=a==null?void 0:a.fixContent)==null?void 0:ta[0])==null?void 0:te[rl];Dt.value=!0,Ki.value=[{prop:rl,label:rl,name:rl,value:sl}]}else{let rl=(ca=a==null?void 0:a.fixContent)==null?void 0:ca.map(ka=>{let La={};for(let $a in ka)Array.isArray(ka==null?void 0:ka[$a])?La[$a]=JSON.stringify(ka==null?void 0:ka[$a]):La[$a]=ka==null?void 0:ka[$a];return La.relatedId="",La}),sl=[{tableName:(Ee=a==null?void 0:a.relatedContents)==null?void 0:Ee.find(ka=>ka==null?void 0:ka.includes("content")),tableContents:rl}];await A.pageBatchAddApi({platId:parseInt((oe=hl==null?void 0:hl.value)==null?void 0:oe.plat_id),changeContents:sl});let ma=[];sl==null||sl.forEach(ka=>{var La;(La=ka==null?void 0:ka.tableContents)==null||La.forEach($a=>{ma.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify($a),request_result:"{}",is_delete:!1,request_table:ka==null?void 0:ka.tableName,request_type:"copyAdd"})})}),await A.pageBatchAddApi({platId:parseInt((Te=hl==null?void 0:hl.value)==null?void 0:Te.plat_id),changeContents:[{tableName:"log",tableContents:ma}]})}}if((a==null?void 0:a.buttonName)==="methodButton"){let Ma=((Ja=(oa=(Ue=a==null?void 0:a.columns)==null?void 0:Ue.map(pe=>pe==null?void 0:pe.filter))==null?void 0:oa.filter(pe=>pe!==""))==null?void 0:Ja[0])??"";Ma=he.analyzeSplitToContent(Ma,","),Ma=(Ma==null?void 0:Ma.find(pe=>pe==null?void 0:pe.includes("@Filter")))??"";let rl=(L=a==null?void 0:a.fixContent)==null?void 0:L.map(pe=>{let ha={};for(let va in pe)Array.isArray(pe==null?void 0:pe[va])?ha[va]=JSON.stringify(pe==null?void 0:pe[va]):ha[va]=pe==null?void 0:pe[va];return ha}),sl=await A.quoteApi({platId:parseInt((H=hl==null?void 0:hl.value)==null?void 0:H.plat_id),type:"fatherSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});sl=(Q=sl==null?void 0:sl.data)==null?void 0:Q.result,sl=sl==null?void 0:sl.filter(pe=>{var ha,va;return!((pe==null?void 0:pe.fatherPath)!==""&&((va=(ha=pe==null?void 0:pe.quote)==null?void 0:ha[0])==null?void 0:va.menus)===(yl==null?void 0:yl.value))});let ma=(ve=(me=a==null?void 0:a.columns)==null?void 0:me[0])==null?void 0:ve.prop,ka=(da=rl==null?void 0:rl[0])==null?void 0:da[ma],La=[{tableName:(ea=a==null?void 0:a.relatedContents)==null?void 0:ea.find(pe=>pe==null?void 0:pe.includes("content")),tableContents:rl}],$a=(ce=sl==null?void 0:sl.map(pe=>{var va,Xe,Ze,Ke,pl;let ha=(va=pe==null?void 0:pe.contents)==null?void 0:va.filter(Ve=>{var Fa;return(Fa=Object.values(Ve))==null?void 0:Fa.find(Sa=>Sa===ka)});if((ha==null?void 0:ha.length)>0){let Ve=rl==null?void 0:rl[0];Ve={...Ve,id:(Xe=ha==null?void 0:ha[0])==null?void 0:Xe.id};let Fa={},Sa=Ve,il;return Array.isArray((Ze=pe==null?void 0:pe.struct)==null?void 0:Ze[0])?il=he.getColumnChild((Ke=pe==null?void 0:pe.struct)==null?void 0:Ke[0]):il=pe==null?void 0:pe.struct,il=il==null?void 0:il.filter(Ia=>(Ia==null?void 0:Ia.prop)!=="relatedId"),il==null||il.forEach(Ia=>{var ze,_l;Fa[Ia.prop]=((ze=Ia==null?void 0:Ia.words)!=null&&ze[0]?(Sa==null?void 0:Sa[(_l=Ia==null?void 0:Ia.words)==null?void 0:_l[0]])??(Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop]):Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop])??""}),Fa.id=(pl=ha==null?void 0:ha[0])==null?void 0:pl.id,delete Fa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Fa]}}else return}))==null?void 0:ce.filter(pe=>pe);La=[...La,...$a];let we=await A.quoteApi({platId:parseInt((pa=hl==null?void 0:hl.value)==null?void 0:pa.plat_id),type:"sonSyncs",related:[{menus:n!==""?yl.value+"/"+n:yl.value,groups:a==null?void 0:a.name}]});if(we=(We=(Ne=we==null?void 0:we.data)==null?void 0:Ne.result)==null?void 0:We.filter(pe=>!(La!=null&&La.find(ha=>(ha==null?void 0:ha.tableName)==="content_"+(pe==null?void 0:pe.id)))),we=we==null?void 0:we.filter(pe=>{var ha,va;return!((pe==null?void 0:pe.fatherPath)!==""&&((va=(ha=pe==null?void 0:pe.quote)==null?void 0:ha[0])==null?void 0:va.menus)===(yl==null?void 0:yl.value))}),Ma&&Ma!==""){(Ma==null?void 0:Ma[(Ma==null?void 0:Ma.length)-1])===","&&(Ma=Ma==null?void 0:Ma.slice(0,(Ma==null?void 0:Ma.length)-1)),Ma=(Ca=(Ta=Ma==null?void 0:Ma.replace("(",mo))==null?void 0:Ta.split(mo))==null?void 0:Ca[1],Ma=Ma==null?void 0:Ma.slice(0,(Ma==null?void 0:Ma.length)-1),(Ma==null?void 0:Ma[0])==="*"&&(Ma="{"+((Va=(Qe=Ma==null?void 0:Ma.replace("{",mo))==null?void 0:Qe.split(mo))==null?void 0:Va[1])),Ma=(ne=Ma==null?void 0:Ma.replaceAll("{",""))==null?void 0:ne.replaceAll("}","");let pe=he.calculatorAndToOr(Ma);pe=pe==null?void 0:pe[0];let ha;if((X=Object.values(pe))!=null&&X.some(va=>(va==null?void 0:va[0])==="*")){let va=(q=(Z=Fn.value)==null?void 0:Z.find(Xe=>(Xe==null?void 0:Xe.condition)==="child"))!=null&&q.value?(Zr==null?void 0:Zr.value)+"/"+((Je=(Be=Fn.value)==null?void 0:Be.find(Xe=>(Xe==null?void 0:Xe.condition)==="child"))==null?void 0:Je.value):Zr==null?void 0:Zr.value;ha=await Kr(va,!1)}for(let va in pe)if(((ra=pe==null?void 0:pe[va])==null?void 0:ra[0])==="*"){let Xe=(_a=(Aa=(ga=pe[va])==null?void 0:ga.slice(1,(ba=pe[va])==null?void 0:ba.length))==null?void 0:Aa.split(":"))==null?void 0:_a[0],Ze=(Za=(Oe=pe[va])==null?void 0:Oe.split(":"))==null?void 0:Za[1],Ke=(Ha=ha==null?void 0:ha.filter(pl=>(pl==null?void 0:pl.name)===Xe))==null?void 0:Ha[0];Ke=(Jl=(xl=Ke==null?void 0:Ke.compData)==null?void 0:xl.find(pl=>(pl==null?void 0:pl.key)==="tableContents"))==null?void 0:Jl.contents,Ke=(kl=Ke==null?void 0:Ke[0])==null?void 0:kl[Ze],pe[va]=Ke}Ma=((Pl=Object.values(pe))==null?void 0:Pl[0])??""}let ia=(ja=we==null?void 0:we.map(pe=>{var va,Xe,Ze,Ke,pl;let ha=(va=pe==null?void 0:pe.contents)==null?void 0:va.filter(Ve=>{var Fa;return(Fa=Object.values(Ve))==null?void 0:Fa.find(Sa=>Sa===(Ma===""?ka:Ma))});if((ha==null?void 0:ha.length)>0){let Ve=rl==null?void 0:rl[0];Ve={...Ve,id:(Xe=ha==null?void 0:ha[0])==null?void 0:Xe.id};let Fa={},Sa=Ve,il;return Array.isArray((Ze=pe==null?void 0:pe.struct)==null?void 0:Ze[0])?il=he.getColumnChild((Ke=pe==null?void 0:pe.struct)==null?void 0:Ke[0]):il=pe==null?void 0:pe.struct,il=il==null?void 0:il.filter(Ia=>(Ia==null?void 0:Ia.prop)!=="relatedId"),il==null||il.forEach(Ia=>{var _l,Ol,ql,Wl;let ze=(_l=a==null?void 0:a.columns)==null?void 0:_l.find(Ql=>{var pr,Ll,fr;return((Ll=(pr=Ql==null?void 0:Ql.words)==null?void 0:pr[0])==null?void 0:Ll.replaceAll("'",""))===(Ia==null?void 0:Ia.prop)&&((fr=Ql==null?void 0:Ql.functionRelatedWords)==null?void 0:fr.length)>0});ze=(Ol=ze==null?void 0:ze.prop)==null?void 0:Ol.replaceAll("'",""),Fa[Ia.prop]=((ql=Ia==null?void 0:Ia.words)!=null&&ql[0]?(Sa==null?void 0:Sa[(Wl=Ia==null?void 0:Ia.words)==null?void 0:Wl[0]])??(Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop])??(Sa==null?void 0:Sa[ze]):(Sa==null?void 0:Sa[Ia==null?void 0:Ia.prop])??(Sa==null?void 0:Sa[ze]))??void 0}),Fa.id=(pl=ha==null?void 0:ha[0])==null?void 0:pl.id,delete Fa.sort,{tableName:"content_"+(pe==null?void 0:pe.id),tableContents:[Fa]}}else return}))==null?void 0:ja.filter(pe=>pe);La=[...La,...ia],await A.pageBatchUpdateApi({platId:parseInt((Ml=hl==null?void 0:hl.value)==null?void 0:Ml.plat_id),changeContents:La});let Ie=[];La==null||La.forEach(pe=>{var ha;(ha=pe==null?void 0:pe.tableContents)==null||ha.forEach(va=>{Ie.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(va),request_result:"{}",is_delete:!1,request_table:pe==null?void 0:pe.tableName,request_type:"method"})})}),await A.pageBatchAddApi({platId:parseInt(($l=hl==null?void 0:hl.value)==null?void 0:$l.plat_id),changeContents:[{tableName:"log",tableContents:Ie}]})}Br.setRefreshCurStructure(!0),await xt(a)},kt=async(a,l,r)=>{var t;let n=a==null?void 0:a.find(s=>(s==null?void 0:s.id)===l);if(n){let s=(t=n.compData)==null?void 0:t.map(v=>{var d;if((v==null?void 0:v.key)==="tableContents"){let p={...v,contents:r};return p.contents=(d=(p==null?void 0:p.contents)??[])==null?void 0:d.map(y=>{let g={};for(let c in y)JSON.stringify(y==null?void 0:y[c])==="{}"?g[c]="":g[c]=y==null?void 0:y[c];return g}),p}return v});return n.compData=await Et(s,{}),a=a==null?void 0:a.map(v=>((v==null?void 0:v.id)===(n==null?void 0:n.id)&&(v=n),v)),a}else{let s=a==null?void 0:a.filter(d=>{var p;return(d==null?void 0:d.children)&&((p=d==null?void 0:d.children)==null?void 0:p.length)>0||(d==null?void 0:d.comp)==="Tabs"}),v=s==null?void 0:s.map(async d=>{var p;return d!=null&&d.children&&((p=d==null?void 0:d.children)==null?void 0:p.length)>0?d.children=await kt(d==null?void 0:d.children,l,r):d.compData=await kt(d==null?void 0:d.compData,l,r),d});return s=await Promise.all(v),s}},xt=async a=>{var s,v,d,p,y,g,c;let l=(s=a==null?void 0:a.relatedContents)==null?void 0:s.filter(D=>D==null?void 0:D.includes("content_"));if(!l)return;let r=await A.getAllTables({platId:parseInt((v=hl==null?void 0:hl.value)==null?void 0:v.plat_id),tableNames:l??[]});if(r=(p=(d=r==null?void 0:r.data)==null?void 0:d.result)==null?void 0:p[0],!r||!Array.isArray(r))return;r=r==null?void 0:r.map(D=>{D==null||delete D.source_table;const M={};for(let S in D){const K=D==null?void 0:D[S],I=K&&Object.prototype.toString.call(K)==="[object Object]"&&Object.keys(K).length===0,R=Array.isArray(K)&&K.length===0;K==null||K==="{}"||I||R?M[S]="":M[S]=K}return M});let n=(g=(y=l==null?void 0:l[0])==null?void 0:y.split("_"))==null?void 0:g[1],t=await kt(tr.value,n,r);tr.value=(c=tr.value)==null?void 0:c.map(D=>{var M,S;return(M=t==null?void 0:t[0])!=null&&M.tabInform&&((S=t==null?void 0:t[0])==null?void 0:S.tabInform)===(D==null?void 0:D.tabInform)?D=t==null?void 0:t[0]:(D!=null&&D.name?(D==null?void 0:D.name)===(t==null?void 0:t.name):(D==null?void 0:D.id)===(t==null?void 0:t.id))&&(D=t),D})},B0=a=>{let l=Ki.value;Ki.value=l==null?void 0:l.map(r=>(r.value=a==null?void 0:a[r==null?void 0:r.prop],r))},N0=async()=>{var D,M,S,K,I,R,j,E,x,k;let a=gc.value,l=yc.value,r=(M=(D=a==null?void 0:a.columns)==null?void 0:D.find(b=>b==null?void 0:b.mainKey))==null?void 0:M.prop,n=(K=(S=Ki.value)==null?void 0:S[0])==null?void 0:K.value,t=(I=a==null?void 0:a.fixContent)==null?void 0:I.map(b=>{var $;let w={};for(let F in b)Array.isArray(b==null?void 0:b[F])?w[F]=JSON.stringify(b==null?void 0:b[F]):w[F]=b==null?void 0:b[F];return($=a==null?void 0:a.columns)==null||$.forEach(F=>{(F==null?void 0:F.formType)==="Upload"&&(w==null?void 0:w[F==null?void 0:F.prop])===""&&(w[F==null?void 0:F.prop]="{}")}),w[r]=n,w}),s=[{tableName:(R=a==null?void 0:a.relatedContents)==null?void 0:R.find(b=>b==null?void 0:b.includes("content")),tableContents:t}];await A.pageBatchAddApi({platId:parseInt((j=hl==null?void 0:hl.value)==null?void 0:j.plat_id),changeContents:s}),l=l==null?void 0:l.filter(b=>{var w,$,F;return(F=b==null?void 0:b.object_name)==null?void 0:F.includes(($=(w=a==null?void 0:a.fixContent)==null?void 0:w[0])==null?void 0:$[r])});let v=[],d=new Map;l==null||l.forEach(b=>{v.push(`content_${b==null?void 0:b.object_id}`),v.push(`struct_${b==null?void 0:b.object_id}`),d.set(b==null?void 0:b.object_id,b)});let p=await A.getAllTables({platId:parseInt((E=hl==null?void 0:hl.value)==null?void 0:E.plat_id),tableNames:v??[]});p=(x=p==null?void 0:p.data)==null?void 0:x.result;let y=[],g=[];p=he.chunk(p,2),p==null||p.forEach(b=>{var F,J,se,ge,Me,V,fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da,le;let w=d.get((ge=(se=(J=(F=b==null?void 0:b[1])==null?void 0:F[0])==null?void 0:J.source_table)==null?void 0:se.split("_"))==null?void 0:ge[1]),$=(fe=(V=(Me=w==null?void 0:w.object_name)==null?void 0:Me.split("/"))==null?void 0:V.filter((ta,te)=>{var ca,Ee;return((Ee=(ca=w==null?void 0:w.object_name)==null?void 0:ca.split("/"))==null?void 0:Ee.length)-1!==te}))==null?void 0:fe.join("/");if($=$+"/"+n,g!=null&&g.find(ta=>(ta==null?void 0:ta.path)===$)||g.push({fatherPath:w==null?void 0:w.father_name,isShow:w==null?void 0:w.is_show,path:$}),((de=(ae=b==null?void 0:b[1])==null?void 0:ae[0])==null?void 0:de.类型)==="Table"){let ta=((ye=(Fe=(De=b==null?void 0:b[1])==null?void 0:De[0])==null?void 0:Fe.结构)==null?void 0:ye.contents)??[],te=ll.safeClone(ta);Array.isArray(te==null?void 0:te[0])&&(te=he.getColumnChild(te==null?void 0:te[0]));let ca=[];if(((T=b==null?void 0:b[0])==null?void 0:T.length)>0&&(ca=(ue=b==null?void 0:b[0])==null?void 0:ue.map(Ee=>te==null?void 0:te.map(Te=>(Te=(Ee==null?void 0:Ee[Te==null?void 0:Te.prop])??"",Te)))),y!=null&&y.find(Ee=>(Ee==null?void 0:Ee.key)===$)){let Ee=(U=y==null?void 0:y.find(Te=>(Te==null?void 0:Te.key)===$))==null?void 0:U.contents;Ee.push({isShow:w==null?void 0:w.is_show,filter:((Pe=(Le=(Se=b==null?void 0:b[1])==null?void 0:Se[0])==null?void 0:Le.引用)==null?void 0:Pe.contents)??"",key:"Table",name:Object.values(w==null?void 0:w.name),tableColumns:ta,tableContents:ca});let oe=y==null?void 0:y.findIndex(Te=>(Te==null?void 0:Te.key)===$);y[oe].contents=Ee}else y.push({key:$,contents:[{isShow:w==null?void 0:w.is_show,filter:((le=(Da=(la=b==null?void 0:b[1])==null?void 0:la[0])==null?void 0:Da.引用)==null?void 0:le.contents)??"",key:"Table",name:Object.values(w==null?void 0:w.name),tableColumns:ta,tableContents:ca}]})}});let c=[];c.push({key:"menuPath",contents:g}),c=[...c,...y],await A.createPlatFormDataApi({platId:parseInt((k=hl==null?void 0:hl.value)==null?void 0:k.plat_id),changeData:c}),Dt.value=!1,Br.setRefreshTable(!0)},To=async(a,l)=>{},Ao=async a=>{tr.value=await he.getDeepDiffItems(a),Br.setItemData(tr.value),Br.setOriginalData(tr.value)};e.ref();const T0=e.ref(null),A0=()=>{var a,l;console.log("倒计时结束时"),A.ElMessageBox.alert(`超时未提交,【${(l=(a=yl.value)==null?void 0:a.split("/"))==null?void 0:l[0]}】失败`,"告警",{confirmButtonText:"确认",type:"error"})},wc=e.ref([]),z0=e.computed(()=>{var a,l;return(l=(a=gt.value)==null?void 0:a[yl.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(()=>[g0.value],()=>{dn.setSelectTitle([]),dn.setChooseTitle([])},{deep:!0});e.watch(()=>Bo.value,async(a,l)=>{var n,t,s,v,d,p;let r=(n=Bo.value)==null?void 0:n.filter(y=>(y==null?void 0:y.condition)==="child"&&(y==null?void 0:y.value)!==""&&(y==null?void 0:y.parentContent)!==Zr.value);if((r==null?void 0:r.length)>0){Ir.setContentLoading(!0);let y=((t=r==null?void 0:r[0])==null?void 0:t.relatedContent)??(yl==null?void 0:yl.value),g=y+"/"+((s=r==null?void 0:r[0])==null?void 0:s.value),c=!!((v=r==null?void 0:r[0])!=null&&v.parentContent),D=await Kr(g,c,{originPath:y});D=(d=D==null?void 0:D.filter(K=>K))==null?void 0:d.map(K=>(K.isShow=!0,K)),console.log(D,"loadingContents");let M=await he.getDeepDiffItems(D),S=M==null?void 0:M.filter(K=>K==null?void 0:K.choice);Oo.setSelectTab((p=S==null?void 0:S[0])==null?void 0:p.choiceName),M=M==null?void 0:M.filter(K=>{var I;return!(K!=null&&K.choiceName)||(K==null?void 0:K.choiceName)===((I=S==null?void 0:S[0])==null?void 0:I.choiceName)}),tr.value=M,Ir.setContentLoading(!1)}});const M0=(a,l)=>{setTimeout(async()=>{var d,p,y;let r=(d=Bo.value)==null?void 0:d.filter(g=>(g==null?void 0:g.condition)==="child"&&(g==null?void 0:g.value)!==""&&(g==null?void 0:g.parentContent)!==Zr.value),n=yl==null?void 0:yl.value,t=yl==null?void 0:yl.value;(r==null?void 0:r.length)>0&&(t=((p=r==null?void 0:r[0])==null?void 0:p.relatedContent)??(yl==null?void 0:yl.value),n=t+"/"+((y=r==null?void 0:r[0])==null?void 0:y.value));let s=await Kr(n,!1,{originPath:t});s=s==null?void 0:s.map(g=>(g.isShow=!0,g));let v=await he.getDeepDiffItems(s);tr.value=v==null?void 0:v.filter(g=>!(g!=null&&g.step)||(g==null?void 0:g.step)===(a==null?void 0:a.title))},10)},I0=a=>{setTimeout(async()=>{var v,d,p;let l=(v=Bo.value)==null?void 0:v.filter(y=>(y==null?void 0:y.condition)==="child"&&(y==null?void 0:y.value)!==""&&(y==null?void 0:y.parentContent)!==Zr.value),r=yl==null?void 0:yl.value,n=yl==null?void 0:yl.value;(l==null?void 0:l.length)>0&&(n=((d=l==null?void 0:l[0])==null?void 0:d.relatedContent)??(yl==null?void 0:yl.value),r=n+"/"+((p=l==null?void 0:l[0])==null?void 0:p.value));let t=await Kr(r,!1,{originPath:n});t=t==null?void 0:t.map(y=>(y.isShow=!0,y)),Oo.setSelectTab(a);let s=await he.getDeepDiffItems(t);tr.value=s==null?void 0:s.filter(y=>!(y!=null&&y.choiceName)||(y==null?void 0:y.choiceName)===a)},10)};e.watch(()=>y0.value,a=>{a!=null&&a.length||(tr.value=[])},{immediate:!0});e.watch(()=>[yl.value],async a=>{var s,v,d,p;if(!yl.value)return;if(yl.value==="/"){tr.value=[];return}Ir.setCurrentMenuPath(yl.value),Br.setLockingPage(""),tr.value=[];let l=e.getCurrentInstance();(s=l==null?void 0:l.scope)==null||s.stop(),l=null,Di.value=!1,Ir.setContentLoading(!0),mc.value=!0;let r=a==null?void 0:a[0],n=r,t=(v=Fn.value)==null?void 0:v.filter(y=>(y==null?void 0:y.condition)==="child"&&(y==null?void 0:y.value)!==""&&(y==null?void 0:y.parentContent)!==yl.value&&!(y!=null&&y.relatedContent));if((t==null?void 0:t.length)>0&&(r=r+"/"+((d=t==null?void 0:t[0])==null?void 0:d.value)),r==="系统管理/日志管理")tr.value=await p0("log");else{let y=await Kr(r,!0,{originPath:n});y=y==null?void 0:y.map(D=>(D.isShow=!0,D));let g=await he.getDeepDiffItems(y),c=g==null?void 0:g.filter(D=>D==null?void 0:D.choice);Oo.setSelectTab((p=c==null?void 0:c[0])==null?void 0:p.choiceName),tr.value=g==null?void 0:g.filter(D=>{var M;return!(D!=null&&D.choiceName)||(D==null?void 0:D.choiceName)===((M=c==null?void 0:c[0])==null?void 0:M.choiceName)})}Ir.setContentLoading(!1),Br.setExtraContents([]),dn.setSelectIndex(""),dn.setSelectMenu(""),Br.setItemData(tr.value),Br.setOriginalData(tr.value),Br.setRefreshTable(!1),e.nextTick(()=>{jn.value=jn.value++,Di.value=!0})},{immediate:!0});e.watch(()=>[ys.value],async()=>{var a,l,r,n;if(ys.value){tr.value=[];let t=e.getCurrentInstance();(a=t==null?void 0:t.scope)==null||a.stop(),t=null,Di.value=!1,Ir.setContentLoading(!0),mc.value=!0;let s=Zr==null?void 0:Zr.value,v=s,d=(l=Fn.value)==null?void 0:l.filter(c=>(c==null?void 0:c.condition)==="child"&&(c==null?void 0:c.value)!==""&&(c==null?void 0:c.parentContent)!==(Zr==null?void 0:Zr.value));(d==null?void 0:d.length)>0&&(s=s+"/"+((r=d==null?void 0:d[0])==null?void 0:r.value));let p=await Kr(s,!0,{originPath:v});p=p==null?void 0:p.map(c=>(c.isShow=!0,c));let y=await he.getDeepDiffItems(p),g=y==null?void 0:y.filter(c=>c==null?void 0:c.choice);if(Oo.setSelectTab((n=g==null?void 0:g[0])==null?void 0:n.choiceName),tr.value=y==null?void 0:y.filter(c=>{var D;return!(c!=null&&c.choiceName)||(c==null?void 0:c.choiceName)===((D=g==null?void 0:g[0])==null?void 0:D.choiceName)}),Ir.setContentLoading(!1),Br.setExtraContents([]),dn.setSelectIndex(""),dn.setSelectMenu(""),Br.setItemData(tr.value),Br.setOriginalData(tr.value),Br.setRefreshTable(!1),(d==null?void 0:d.length)>0){let c=[...Fn.value,...d];dn.setSelectTitle(c)}e.nextTick(()=>{jn.value=jn.value++,Di.value=!0})}},{immediate:!0,deep:!0});const O0=async()=>{Ir.setLinkMenuInfo(null),Ir.setActiveMenuPath(m0.value),tr.value=null,Br.setRouteToChildPath(""),Ir.setChildMenu("")},L0=a=>new RegExp("button","i").test(a),R0=a=>/^[\u4e00-\u9fa5]+\/[\u4e00-\u9fa5]+\^(.+)$/.test(a),_c=a=>{if(R0(a)){const l=a==null?void 0:a.split("^");(l==null?void 0:l.length)>0&&(l!=null&&l[0])&&Ir.setLinkMenuInfo({path:l==null?void 0:l[0],data:l==null?void 0:l[1]})}},Sc=async(a,l,r)=>{var D,M,S,K,I,R,j,E,x,k,b,w;let n="",t="";for(let $ in l)(l==null?void 0:l[$])===a&&(t=$);r==null||r.forEach($=>{($==null?void 0:$.prop)===t&&(n=$==null?void 0:$.fatherPath)});let s=n===""?yl.value:n;n!==""&&Ir.setCurrentMenuPath(s),Ir.setCurrentMenuPath(s+"/"+a),Ir.setContentLoading(!0),tr.value=await Kr(s+"/"+a,!0,{originPath:s+"/",row:l});let v=await Kr(s,!1),d=(D=v==null?void 0:v.filter($=>($==null?void 0:$.comp)==="Table"))==null?void 0:D[0],p=((I=(K=(S=(M=d==null?void 0:d.compData)==null?void 0:M.find($=>($==null?void 0:$.key)==="header"))==null?void 0:S.contents)==null?void 0:K[0])==null?void 0:I.prop)??((k=(x=(E=(j=(R=d==null?void 0:d.compData)==null?void 0:R.find($=>($==null?void 0:$.key)==="header"))==null?void 0:j.contents)==null?void 0:E[0])==null?void 0:x[0])==null?void 0:k.prop),y=(w=(b=d==null?void 0:d.compData)==null?void 0:b.find($=>($==null?void 0:$.key)==="tableContents"))==null?void 0:w.contents;y=y==null?void 0:y.map($=>({label:$==null?void 0:$[p],value:$==null?void 0:$[p]}));let g=Fn.value,c={value:a,condition:"child",options:y,relatedContent:s,isShow:!0};g=g==null?void 0:g.filter($=>($==null?void 0:$.condition)!=="child"),g.push(c),dn.setSelectTitle(g),dn.setChooseTitle([c]),Ir.setContentLoading(!1),Br.setExtraContents([]),dn.setSelectIndex(""),dn.setSelectMenu(""),Br.setItemData(tr.value),Br.setOriginalData(tr.value)},$0=a=>{kc.value=a},_i=e.reactive({index:0,comp:null}),V0=e.computed(()=>{var a;return(a=tr.value)==null?void 0:a.map((l,r)=>({id:l.id,name:l.name,status:F0(l,r)}))}),Ec=(a,l)=>{var p,y,g,c,D;const r=l?a:a-2,n=(p=tr.value)==null?void 0:p[r],t=(g=(y=n==null?void 0:n.compData)==null?void 0:y.find(M=>(M==null?void 0:M.key)==="header"))==null?void 0:g.contents,s=t==null?void 0:t.findIndex(M=>(M==null?void 0:M.isMainKey)&&(M==null?void 0:M.label)!=="操作"),v=s===-1?0:s,d=(D=(c=n==null?void 0:n.compData)==null?void 0:c.find(M=>(M==null?void 0:M.key)==="tableContents"))==null?void 0:D.contents;return{valid:d==null?void 0:d.every(M=>M==null?void 0:M[v+1]),length:(d==null?void 0:d.length)||0}},F0=(a,l)=>{var n;let r="process";if(((n=a==null?void 0:a.comp)==null?void 0:n.toUpperCase())==="TABLE"){const{valid:t,length:s}=Ec(l,!0);_i.index===l?r="process":s===0?r="wait":r=t?"success":"error"}return r},Cc=a=>{var r,n,t,s,v;const l=a+1;if(l>1&&((t=(n=(r=tr.value)==null?void 0:r[a])==null?void 0:n.comp)==null?void 0:t.toUpperCase())==="TABLE"){const{valid:d}=Ec(l);d?(_i.index=l,_i.comp=(s=tr.value)==null?void 0:s[a]):qa.ElMessage({showClose:!0,type:"warning",message:"当前流程有输入未完成"})}else _i.index=l,_i.comp=(v=tr.value)==null?void 0:v[a]},Dc=e.computed(()=>{var a,l;return(l=(a=bc.value)==null?void 0:a[0])==null?void 0:l.isStepLayout});e.watch(()=>Dc.value,a=>{a&&Cc(0)},{immediate:!0});const P0={class:"table-content"},j0={class:"menu-config-wrap"},H0=["onClick"],U0={key:0,class:"viewport-wrap"},q0=["onClick"],W0={title:"选择显示列信息"},K0={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"}},G0=["title"],Y0={class:"col-operate-wrap"},J0={key:0,class:"col-operate-radio-wrapper"},X0={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},Z0={key:0,style:{display:"flex","justify-content":"center","align-items":"center"}},Q0={class:"pop-view"},e3={class:"pop-wrapper"},a3={class:"file-list-pop"},l3=["title","onClick"],r3=["onClick"],n3=["onClick"],i3={key:1,style:{display:"flex","justify-content":"flex-end",gap:"8px","margin-top":"8px"}},o3={class:"form-content"},t3={key:0,class:"dialog-footer"},s3={class:"dialog-footer"},c3={class:"ocr-dialog-content"},u3={class:"ocr-steps"},d3={key:0,class:"ocr-action-buttons"},p3={key:1,class:"ocr-preview-area"},f3={class:"ocr-file-grid"},h3={class:"file-thumbnail"},v3=["src"],m3={key:1,class:"thumbnail-placeholder"},y3={class:"progress-svg",viewBox:"0 0 36 36"},g3=["stroke","stroke-width","stroke-dasharray"],b3={key:0,class:"progress-icon"},k3={key:1,class:"progress-icon"},x3=["onClick"],w3={class:"file-name"},_3={key:0,class:"ocr-recognize-button"},S3={key:2,class:"ocr-progress-section"},E3={key:3,class:"ocr-confirm-area"},C3={class:"ocr-preview-tip"},D3={class:"ocr-preview-table"},B3={style:{display:"flex","align-items":"center",gap:"8px"}},N3={key:0},T3={key:4,class:"ocr-success-area"},A3={key:0,class:"ocr-dialog-footer"},z3={class:"form-content"},M3={style:{width:"100%",margin:"0","font-size":"14px","font-weight":"600"}},I3={style:{display:"flex","justify-content":"space-between",gap:"8px"}},O3={style:{display:"flex"}},bs="ss-ocr-upload-history",L3="ss-ocr-cert-history-v1",R3={__name:"index",props:{pageLayout:{type:String,default:"vertical"},related:{type:Array,default:[]},level:{type:Number,default:1},compName:{type:String,default:"",required:!1},compNames:{type:Array,default:()=>[],required:!1},groupNames:{type:Array,default:()=>[],required:!1},compItem:{type:Object,default:()=>{}},operatingForm:{type:Object,default:()=>{}},cacheNewData:{type:Object,default:()=>{}},config:Object,parentTableId:{type:Number,default:0},itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,isDevMode:Boolean,changedContent:{type:Object,default:()=>{}},showHeader:{type:Boolean,default:!0},allowSelect:{type:Boolean,default:!0},allowOperate:{type:Boolean,default:!0},allMapContents:{type:Object,default:()=>{}}},emits:["getSliceContLength","clickMainKey","change","contentChange","onButtonClick","contentClick","pageChange","rowClick","routeUrl"],setup(a,{emit:l}){var Ft;const r=e.ref([]),n=Ct(A.pinia),t=e.ref(null),s=e.ref(new Set),v=e.ref(new Map),d=e.ref(!1),p=e.ref(new Map),y=new Map,g=e.ref(new Map),c=a,D=e.ref((c==null?void 0:c.allowSelect)??!0),M=e.ref(((Ft=c==null?void 0:c.config)==null?void 0:Ft.showIndex)??!0),S=e.ref(),K=e.ref(!0),I=e.ref(!1),R=e.ref([]),j={sortable:"switch",filterable:"switch",showSummary:"switch",operable:"switch",fixed:"radio"},E=e.ref([{label:"排序",value:"sortable",checked:!1},{label:"合计",value:"showSummary",checked:!1},{type:"radio",label:"固定",value:"fixed",checked:"",options:[{label:"无",value:!1},{label:"左",value:"left"},{label:"右",value:"right"}]}]),x=he.useOriginalState(A.pinia);let k="$R";const{originalPath:b}=A.storeToRefs(x),w=b.value,$=e.computed(()=>{var h;const u=(h=he.getAllLeafNodes(V.value)||[])==null?void 0:h.filter(B=>(B==null?void 0:B.type)!=="operate"&&(B==null?void 0:B.label)!=="操作"&&(B==null?void 0:B.prop)!=="operate");return u.length>0?u.every(B=>!!(B!=null&&B.sortable)):!1});e.computed(()=>{var h;return(h=V.value)==null?void 0:h.every(B=>B==null?void 0:B.filterable)}),e.computed(()=>{var h;return(h=V.value)==null?void 0:h.every(B=>B==null?void 0:B.operable)});const F=e.ref(!0),J=e.ref([]),se=e.reactive({column:{},status:!1,text:"合计"}),ge=e.reactive({currentPage:1,pageSize:10,total:0,pageSizes:[5,10,20]}),Me=l,V=e.ref([]),fe=e.ref([]),ae=e.ref([]),de=e.reactive({prop:"",order:null}),De=e.ref([]),Fe=e.ref(!1),ye=e.ref(!1),T=e.ref(null),{isUseBackdrop:ue,initTrackFileType:U,getFileExtension:Se,setData:Le,getFileInfo:Pe,getFilesInfo:la}=So.useThreeSystem(),Da=e.ref([]),le=e.ref(!1),ta=e.ref(),te=A.useMenuState(),{importLoading:ca,activeMenuPath:Ee,contentLoading:oe,linkMenuInfo:Te}=A.storeToRefs(te),Ue=he.useTableComp(A.pinia),oa=A.useModelComp(A.pinia),Ja=Hn(A.pinia),{extraContents:L,cacheUpdatingData:H,tableViewContents:Q,tableLoading:me,pageMapState:ve,lockingPage:da}=A.storeToRefs(oa),{selectTab:ea}=A.storeToRefs(Ja),{compType:ce,hasEditable:pa}=Ys.useRole(),Ne=e.ref([]),We=e.ref([]),Ta=e.ref(new Map);e.ref(!1);const Ca=e.ref("");e.ref();const Qe=e.ref(!0),Va=e.ref(0),ne=e.ref(!0),X=e.ref(""),Z=e.ref(!1),q=e.ref(null);e.ref([]);const Be=e.ref({label:"查看三维模型"}),Je=e.ref(!1),ra=e.ref(),ba=e.ref([]),ga=e.ref([]),Aa=e.ref(!1),_a=e.ref([]),Oe=e.ref([]),Za=e.ref([]),Ha=e.ref([]),xl=e.ref([]),Jl=()=>{try{const u=localStorage.getItem(bs),h=u?JSON.parse(u):[];xl.value=Array.isArray(h)?h:[]}catch{xl.value=[]}},kl=()=>{try{localStorage.setItem(bs,JSON.stringify(xl.value||[]))}catch{}},Pl=u=>{var ie,re,W;if(!u)return;const h=u.url||((ie=u==null?void 0:u.uploadResult)==null?void 0:ie.url)||"",B=u.name||((re=u==null?void 0:u.uploadResult)==null?void 0:re.name)||((W=u==null?void 0:u.uploadResult)==null?void 0:W.fileName)||"";if(!h&&!B)return;const z={name:B,url:h,ts:Date.now()},P=String(z.name||"").trim().toLowerCase(),C=(xl.value||[]).findIndex(xe=>String((xe==null?void 0:xe.name)||"").trim().toLowerCase()===P);C>-1&&xl.value.splice(C,1),xl.value.unshift(z),xl.value.length>20&&(xl.value=xl.value.slice(0,20)),kl()};Jl();const ja=(u,h)=>`${L3}:${String(u??"")}:${String(h??"")}`,Ml=(u,h)=>{try{const B=sessionStorage.getItem(ja(u,h)),z=B?JSON.parse(B):[];return Array.isArray(z)?z:[]}catch{return[]}},$l=(u,h,B)=>{try{sessionStorage.setItem(ja(u,h),JSON.stringify(Array.isArray(B)?B:[]))}catch{}},Ma=(u,h,B)=>{if(!h)return;const z=Ml(u,h),P=[B,...z||[]].filter(Boolean).slice(0,1);return $l(u,h,P),P},rl=(u,h,B)=>{if(!h||!B)return;const z=ja(u,h),P=ja(u,B);try{const C=sessionStorage.getItem(z);if(!C)return;const ie=(()=>{try{const xe=JSON.parse(C);return Array.isArray(xe)?xe:[]}catch{return[]}})(),re=Ml(u,B),W=[...ie,...re||[]].filter(Boolean).sort((xe,Ae)=>Number((Ae==null?void 0:Ae.ts)||0)-Number((xe==null?void 0:xe.ts)||0)).slice(0,1);sessionStorage.setItem(P,JSON.stringify(W)),sessionStorage.removeItem(z)}catch{}},sl=e.ref(!1),ma=e.ref(!1),ka=e.ref([]),La=e.ref(null);e.ref(!1),e.ref([]),e.ref(""),e.ref("");const $a=e.ref(!1),we=e.ref([]),ia=e.ref(1),Ie=e.ref(new Map),pe=e.ref(new Map),ha=e.ref(0),va=e.ref(!1),Xe=e.ref([]),Ze=e.ref([]),Ke=u=>{var h;try{const B=(h=he.getAllLeafNodes(V.value)||[])==null?void 0:h.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate");return(B==null?void 0:B.find(z=>(z==null?void 0:z.prop)===u||(z==null?void 0:z.label)===u))||null}catch{return null}},pl=u=>{const h=Ke(u),B=(h==null?void 0:h.formType)||(h==null?void 0:h.columnType)||"Input";return ll.getComponent(B)||ll.getComponent("Input")},Ve=e.ref([]),Fa=e.ref(null),Sa=e.ref([]),il=e.ref(null),Ia=e.ref(""),ze=e.ref(!1),_l=e.ref([]),Ol=e.ref(""),ql=e.ref(!1),Wl=e.ref([]),Ql=e.ref([]),pr=e.ref([]),Ll=e.ref(null),fr=e.ref([]),Vr=e.ref("");e.computed(()=>{var u;try{const h=(u=he.getAllLeafNodes(V.value)||[])==null?void 0:u.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate"),B=new Map;return h==null||h.forEach(z=>{z!=null&&z.label&&(z!=null&&z.prop)&&B.set(z.label,z.prop)}),B.get("编号")||""}catch{return""}});const jl=e.computed(()=>{var u;try{const h=(u=he.getAllLeafNodes(V.value)||[])==null?void 0:u.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate"),B=new Map;return h==null||h.forEach(z=>{z!=null&&z.label&&(z!=null&&z.prop)&&B.set(z.label,z.prop)}),B.get("名称")||""}catch{return""}}),ar=e.computed(()=>{var u;try{const h=(u=he.getAllLeafNodes(V.value)||[])==null?void 0:u.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate"),B=new Map;return h==null||h.forEach(z=>{z!=null&&z.label&&(z!=null&&z.prop)&&B.set(z.label,z.prop)}),B.get("制造厂")||""}catch{return""}}),Fr=()=>{ql.value=!1,Wl.value=[],Ql.value=[],pr.value=[],Ll.value=null,fr.value=[],Vr.value=""},Nr=u=>u==null?!1:typeof u=="string"?u.trim()!=="":Array.isArray(u)?u.length>0:!0,Pr=(u,h)=>{const B=(u==null?void 0:u.ocrRow)||{};for(const P of Object.keys(B))P==="id"||P==="_isOCRRow"||P==="_ocrTableId"||Nr(B[P])&&(h[P]=B[P]);const z=We.value.find(P=>P.id===h.id);if(z)for(const P of Object.keys(B))P==="id"||P==="_isOCRRow"||P==="_ocrTableId"||Nr(B[P])&&(z[P]=B[P]);Ta.value&&Ta.value.set(h.id,h),Ma(c==null?void 0:c.index,h.id,u==null?void 0:u.versionItem),Ql.value=[...Ql.value||[],JSON.parse(JSON.stringify(h))]},Mr=async(u,h=null)=>{var B,z,P,C,ie,re,W;try{const xe=(B=he.getAllLeafNodes(V.value)||[])==null?void 0:B.filter(xa=>(xa==null?void 0:xa.type)!=="operate"&&(xa==null?void 0:xa.label)!=="操作"&&(xa==null?void 0:xa.prop)!=="operate"),Ae=new Map;xe==null||xe.forEach(xa=>{xa!=null&&xa.label&&(xa!=null&&xa.prop)&&Ae.set(xa.label,xa.prop)});const je=Ae.get("系统编号")||Ae.get("编号");if(!je){console.warn("未找到系统编号字段,跳过向检校记录表插入数据");return}const Re=h||Ll.value;if((Array.isArray(Re==null?void 0:Re.result)?Re.result:[]).length===0){console.warn("OCR识别结果为空,跳过向检校记录表插入数据");return}for(let xa=0;xa<u.length;xa++){const Oa=u[xa],za=Oa[je];if(!za){console.warn(`第 ${xa+1} 条匹配行缺少系统编号,跳过`);continue}const Ye=`设备管理/试验设备/${za}`,Qa=await A.getPageDataApi({platId:parseInt((z=cl.value)==null?void 0:z.plat_id),pageName:Ye});if(!((P=Qa==null?void 0:Qa.data)!=null&&P.result)||!Array.isArray(Qa.data.result)){console.warn(`未找到详情页数据: ${Ye}`);continue}const ya=Qa.data.result.find(na=>(na==null?void 0:na.property_name)==="校检记录");if(!ya){console.warn(`详情页 ${Ye} 中未找到校检记录表`);continue}const el=(C=ya.contents)==null?void 0:C.find(na=>(na==null?void 0:na.key)&&na.key.startsWith("content_"));if(!el||!el.key){console.warn("校检记录表中未找到 content item");continue}const be=el.key,Ra=Array.isArray(el.value)?el.value:[];if(Ra.length>=5){const _e=[...Ra].sort((sa,Na)=>{const nl=Number((sa==null?void 0:sa.create_time)||0),Wa=Number((Na==null?void 0:Na.create_time)||0);return nl-Wa})[0];_e!=null&&_e.id&&await A.pageBatchDeleteApi({platId:parseInt((ie=cl.value)==null?void 0:ie.plat_id),changeContents:[{tableName:be,tableContents:[{id:_e.id}]}]})}const fa=(re=xe==null?void 0:xe.find(na=>(na==null?void 0:na.label)==="证书附件"))==null?void 0:re.prop,Ea=String(Date.now()),wa={id:Ea},N=Ra[0]||{},Y=new Date().toISOString().split("T")[0];if(Object.keys(N||{}).forEach(na=>{if(na!=="id"){if(na==="证书附件"){wa[na]="";return}if(na==="校检日期"||na==="检校日期"){wa[na]=Oa[na]||Oa.校检日期||Oa.检校日期||Y;return}if(["校检周期","检校周期","校检结果","检校结果","计量状态","依据文件","证书编号"].includes(na)){wa[na]=Oa[na]??"";return}wa[na]=Oa[na]??""}}),fa&&Oa[fa]){const na=Oa[fa];if(Array.isArray(na)&&na.length>0)wa.证书附件=JSON.stringify(na.map(_e=>({url:(_e==null?void 0:_e.url)||"",name:(_e==null?void 0:_e.name)||(_e==null?void 0:_e.fileName)||"",fileName:(_e==null?void 0:_e.fileName)||(_e==null?void 0:_e.name)||""})).filter(_e=>_e.url||_e.name));else if(typeof na=="string")try{const _e=JSON.parse(na);wa.证书附件=na}catch{wa.证书附件=JSON.stringify([{url:na,name:na,fileName:na}])}}console.log(be,"tableName","inspectionRecordRow",wa),await A.pageBatchAddApi({platId:parseInt((W=cl.value)==null?void 0:W.plat_id),changeContents:[{tableName:be,tableContents:[wa]}]});const $e=ya==null?void 0:ya.object_id;if($e&&Ea){const na=fa&&Oa[fa]?Oa[fa]:null;let _e=[],sa="",Na=!1;if(Array.isArray(na)&&na.length>0){_e=na.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 Wa=na[0];sa=(Wa==null?void 0:Wa.url)||"";const ul=(Wa==null?void 0:Wa.name)||(Wa==null?void 0:Wa.fileName)||"";Na=String(ul).toLowerCase().endsWith(".pdf")||String(sa).toLowerCase().endsWith(".pdf")}else if(typeof na=="string")try{const Wa=JSON.parse(na);Array.isArray(Wa)?(_e=Wa.map(ul=>({name:(ul==null?void 0:ul.name)||(ul==null?void 0:ul.fileName)||"",url:(ul==null?void 0:ul.url)||""})).filter(ul=>ul.url||ul.name),_e.length>0&&(sa=_e[0].url||"",Na=String(_e[0].name).toLowerCase().endsWith(".pdf")||String(sa).toLowerCase().endsWith(".pdf"))):(sa=na,Na=String(na).toLowerCase().endsWith(".pdf"))}catch{sa=na,Na=String(na).toLowerCase().endsWith(".pdf")}const nl={ts:Date.now(),versionId:String(Date.now())+"_"+String(xa),label:new Date().toLocaleString(),certType:Oa.证书类型||"",certNo:Oa.证书编号||"",fileType:Na?"pdf":"image",sourceUrl:Na?sa:"",images:_e};Ma($e,Ea,nl)}}}catch(xe){console.error("向校检记录表插入OCR识别结果失败:",xe),qa.ElMessage.error("向校检记录表插入数据失败,请查看控制台")}},Sr=u=>{const h=Array.isArray(u)?u:Wl.value||[];if(h.length===0){Fr();return}if(h.find(C=>(C==null?void 0:C.__decision)==="replace"&&!(C!=null&&C.selectedTargetId))){qa.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}h.forEach(C=>{var re;const ie=C==null?void 0:C.__decision;if(!(!ie||ie==="skip")){if(ie==="add"){Ma(c==null?void 0:c.index,(re=C==null?void 0:C.ocrRow)==null?void 0:re.id,C==null?void 0:C.versionItem),pr.value=[...pr.value||[],C.ocrRow];return}if(ie==="replace"){const W=C==null?void 0:C.selectedTargetId,xe=(Ne.value||[]).find(Ae=>String(Ae==null?void 0:Ae.id)===String(W));if(!xe)return;Pr(C,xe)}}}),(Ql.value||[]).length>0&&(Ne.value=[...Ne.value||[]]),(pr.value||[]).length>0&&(Ne.value=[...Ne.value||[],...pr.value||[]],We.value=[...We.value||[],...pr.value||[]],(pr.value||[]).forEach(C=>{var ie,re;return(re=(ie=Ta.value)==null?void 0:ie.set)==null?void 0:re.call(ie,C.id,C)})),ln.value=Ne.value;const z=Ql.value||[],P=pr.value||[];if(z.length>0&&(Me("change",{buttonName:"编辑",singleContent:z,content:Ne.value,relatedContents:c==null?void 0:c.related,index:c==null?void 0:c.index,parentTableId:c==null?void 0:c.parentTableId,columns:V.value,name:c==null?void 0:c.compName}),Mr(z)),P.length>0){const C=Ll.value;Me("change",{buttonName:"OCR批量新增",content:Ne.value,index:c==null?void 0:c.index,parentTableId:c==null?void 0:c.parentTableId,column:V.value,ocrRows:P,relatedContents:c==null?void 0:c.related,uploadedFiles:(Array.isArray(C==null?void 0:C.result)?C.result:[]).map(ie=>(Array.isArray(ie==null?void 0:ie.图片信息)?ie.图片信息:[]).map(re=>({url:(re==null?void 0:re.url)||"",name:(re==null?void 0:re.name)||"",fileName:(re==null?void 0:re.name)||""})).filter(re=>re.url)),ocrResult:C,matchedCount:(z||[]).length,newCount:(P||[]).length})}qa.ElMessage.success("已提交候选处理结果"),Fr()},Er=hc(),mn=e.computed(()=>Er.getConfig()),Dr=e.ref(),ur=e.ref(),yn=cc(A.pinia),ln=e.ref(),rn=e.ref(0),_n=A.useUnit(A.pinia),{selectIndex:Bn,selectMenu:pn,selectTitle:lr}=A.storeToRefs(_n),{selectString:Il}=A.storeToRefs(yn),Ar=A.useLoginState(A.pinia),{loginUserInfo:cl}=A.storeToRefs(Ar),cr=e.ref(720),Vl=e.ref(!1),_r=e.ref(!1),Gl=e.ref([]),hr=e.ref(),Or=e.ref(!0),gn=e.ref(!0);e.ref([]);const Nn=e.inject("contentRef");e.provide("contentRef",Nn),e.provide("getSuggestListForCell",Su),e.provide("getSuggestLoadingForCell",(u,h)=>{const B=`${u==null?void 0:u.id}:${(h==null?void 0:h.prop)||(h==null?void 0:h.property)}`;return g.value.get(B)||!1}),e.watch(()=>{var u;return(u=Ne.value)==null?void 0:u.length},u=>{ge.total=u}),e.watch(()=>Q.value,async()=>{var h,B,z,P,C,ie,re,W,xe,Ae,je,Re,Ge,xa,Oa,za,Ye;if(((h=Q.value)==null?void 0:h.length)===0||!((B=c==null?void 0:c.itemData)!=null&&B.find(Qa=>(Qa==null?void 0:Qa.key)==="columnPath"))||!((z=c==null?void 0:c.itemData)!=null&&z.find(Qa=>(Qa==null?void 0:Qa.key)==="pageColumn")))return;let u=(xe=(W=(re=(ie=(C=(P=c==null?void 0:c.itemData)==null?void 0:P.find(Qa=>(Qa==null?void 0:Qa.key)==="pageColumn"))==null?void 0:C.contents)==null?void 0:ie.split("["))==null?void 0:re[1])==null?void 0:W.split("]"))==null?void 0:xe[0];((Ge=(Re=(je=(Ae=c==null?void 0:c.itemData)==null?void 0:Ae.find(Qa=>(Qa==null?void 0:Qa.key)==="pageColumn"))==null?void 0:je.contents)==null?void 0:Re.split("["))==null?void 0:Ge[0])+((Oa=(xa=Q.value)==null?void 0:xa.find(Qa=>(Qa==null?void 0:Qa.key)===u))==null?void 0:Oa.value),(Ye=(za=c==null?void 0:c.itemData)==null?void 0:za.find(Qa=>(Qa==null?void 0:Qa.key)==="pageGroup"))==null||Ye.contents,Vt(compData,c.allMapContents)},{deep:!0});const bn=u=>{var B,z,P,C,ie;const h=(z=(B=V.value)==null?void 0:B.filter(re=>re==null?void 0:re.mainKey))==null?void 0:z.map(re=>re==null?void 0:re.prop);if(h.length===0){const re=(P=V.value)==null?void 0:P.map(W=>W==null?void 0:W.prop);return(C=re==null?void 0:re.map(W=>u==null?void 0:u[W]))==null?void 0:C.join("|")}return(ie=h==null?void 0:h.map(re=>u==null?void 0:u[re]))==null?void 0:ie.join("|")},Un=u=>{var re,W,xe,Ae,je;const h=(W=(re=V.value)==null?void 0:re.filter(Re=>Re==null?void 0:Re.required))==null?void 0:W.map(Re=>Re==null?void 0:Re.prop),B=[];if(u==null||u.forEach(Re=>{h==null||h.forEach(Ge=>{const xa=Re[Ge];(xa==null||xa==="")&&(B.includes(Ge)||B.push(Ge))})}),B.length>0)return qa.ElMessage.warning(`请填写必填项:${B.join("、")}`);const z=new Map,P=new Map;(xe=Ne.value)==null||xe.forEach(Re=>{const Ge=bn(Re);z.set(Ge,Re)}),u==null||u.forEach(Re=>{const Ge=bn(Re);P.set(Ge,Re)});const C=u==null?void 0:u.filter(Re=>z.has(bn(Re))),ie=(Ae=Ne.value)==null?void 0:Ae.filter(Re=>P.has(bn(Re)));return(C==null?void 0:C.length)>0&&(m.columns=(je=V.value)==null?void 0:je.filter(Re=>(Re==null?void 0:Re.label)!=="操作"),m.existRows=ie,m.tableData=C,m.show=!0),m.newRows=u==null?void 0:u.filter(Re=>{const Ge=bn(Re);return!z.has(Ge)}),m.newRows},Ln=e.ref(""),kn=e.ref(null),Tn=async()=>{var u,h,B,z,P,C;try{const ie=await A.quoteApi({related:[{menus:Ee.value,groups:c==null?void 0:c.compName}],platId:parseInt((u=cl.value)==null?void 0:u.plat_id)});if(((h=ie==null?void 0:ie.data)==null?void 0:h.code)===200){kn.value=(B=ie==null?void 0:ie.data)==null?void 0:B.result;const re=(z=V.value)==null?void 0:z.map(Ae=>(Ae==null?void 0:Ae.prop)||(Ae==null?void 0:Ae.label)),W=Rn(re,(P=ie==null?void 0:ie.data)==null?void 0:P.result),xe=W==null?void 0:W.flatMap(Ae=>Ae==null?void 0:Ae.quote);(xe==null?void 0:xe.length)>0&&(Ln.value=(C=xe==null?void 0:xe.map(Ae=>Ae==null?void 0:Ae.menus))==null?void 0:C.join("、"))}}catch(ie){throw new Error(ie)}};function Rn(u,h){var B;return(B=h.filter(z=>z.struct&&Array.isArray(z.struct)?z.struct.some(P=>P.words&&Array.isArray(P.words)?P.words.some(C=>u.includes(C)):!1):!1))==null?void 0:B.map(z=>{const P={...z};return P.struct&&Array.isArray(P.struct)&&(P.struct=P.struct.filter(C=>C.words&&Array.isArray(C.words)?C.words.some(ie=>u.includes(ie)):!1)),P})}const Qr=async(u,h)=>{var B,z;try{kn.value||await Tn();const P=h==null?void 0:h.map(ie=>{const re=Object.keys(ie),W={};return re.forEach((xe,Ae)=>{W[u[Ae]]=ie[xe]}),W}),C=Un(P);if(!C||(C==null?void 0:C.length)===0)return;m.show||await O(C)}catch(P){throw qa.ElMessage.error("数据导入处理失败"),await A.pageBatchAddApi({platId:parseInt((B=cl==null?void 0:cl.value)==null?void 0:B.plat_id),changeContents:[{tableName:"log",tableContents:[{id:"1",request_method:"Post",request_url:"",request_param:JSON.stringify(t1),request_result:JSON.stringify(P),is_delete:!1,request_table:(z=c==null?void 0:c.related)==null?void 0:z.find(C=>C==null?void 0:C.includes("content")),request_type:"error"}]}]}),new Error(P)}},An=async u=>{var C,ie,re,W,xe,Ae,je;let h=ae.value;h!=null&&h.find(Re=>(u==null?void 0:u.key)===(Re==null?void 0:Re.key))&&(h=h==null?void 0:h.filter(Re=>(u==null?void 0:u.key)!==(Re==null?void 0:Re.key))),h.push({key:u==null?void 0:u.key,value:[(ie=u==null?void 0:u.value)==null?void 0:ie[((C=u==null?void 0:u.value)==null?void 0:C.length)-1]]});let B=Ha.value;B=B==null?void 0:B.map(Re=>{var Ge,xa;return(Re==null?void 0:Re.type)==="Select"&&(u==null?void 0:u.key)===(Re==null?void 0:Re.prop)&&Array.isArray(Re.value)&&(Ge=Re.value)!=null&&Ge.every(Oa=>typeof Oa=="string")&&(Re.selectValue=(xa=h==null?void 0:h.find(Oa=>(Oa==null?void 0:Oa.key)===(Re==null?void 0:Re.prop)))==null?void 0:xa.value),Re});let z=(W=(re=B==null?void 0:B.find(Re=>(Re==null?void 0:Re.prop)===(u==null?void 0:u.key)))==null?void 0:re.optionUrl)==null?void 0:W.menuId,P=B==null?void 0:B.find(Re=>(Re==null?void 0:Re.prop)===(u==null?void 0:u.key));if(z){let Re=await yt(P==null?void 0:P.optionUrl,z),Ge,xa=J.value,Oa=(je=(Ae=(xe=Ha.value)==null?void 0:xe.find(za=>{var Ye;return(Ye=P==null?void 0:P.optionUrl)==null?void 0:Ye.menuId}))==null?void 0:Ae.selectValue)==null?void 0:je[0];if(Re==null||Re.forEach(za=>{var Ye,Qa,ya,el,be,Ra,fa,Ea,wa,N;if(z){let Y=(Qa=(Ye=Ha.value)==null?void 0:Ye.find(na=>{var _e,sa;return((_e=P==null?void 0:P.optionUrl)==null?void 0:_e.menuId)===((sa=na==null?void 0:na.optionUrl)==null?void 0:sa.menuId)}))==null?void 0:Qa.prop,$e=(el=(ya=B==null?void 0:B.find(na=>(na==null?void 0:na.prop)===Y))==null?void 0:ya.selectValue)==null?void 0:el[0];Y!=null&&Y.includes("·")&&(Y=(be=Y==null?void 0:Y.split("·"))==null?void 0:be[0],$e=(wa=(Ea=(fa=u==null?void 0:u.value)==null?void 0:fa[((Ra=u==null?void 0:u.value)==null?void 0:Ra.length)-1])==null?void 0:Ea.split(" "))==null?void 0:wa[0]),xa!=null&&xa.find(na=>(na==null?void 0:na.value)===Oa)?Ge=(N=xa==null?void 0:xa.find(na=>(na==null?void 0:na.value)===Oa))==null?void 0:N.objectValue:za[Y]===$e&&(Ge=za)}}),Ge){let za=B;za=za==null?void 0:za.map(Ye=>{var Qa,ya,el,be,Ra,fa;return z&&(Ge!=null&&Ge[Ye==null?void 0:Ye.prop])&&X.value==="新增"&&(Ye==null?void 0:Ye.prop)!==(P==null?void 0:P.prop)?Ye.value=(Ge==null?void 0:Ge[Ye==null?void 0:Ye.prop])||(Ge==null?void 0:Ge[(be=(el=(ya=(Qa=Ye==null?void 0:Ye.optionUrl)==null?void 0:Qa.groupSelect)==null?void 0:ya[1])==null?void 0:el.replaceAll("[",""))==null?void 0:be.replaceAll("]","")]):Ye.value=(fa=(Ra=Ha.value)==null?void 0:Ra.find(Ea=>(Ea==null?void 0:Ea.prop)===(Ye==null?void 0:Ye.prop)))==null?void 0:fa.value,Ye}),Ha.value=za}}ae.value=h},qn=async(u,h)=>{var B,z,P,C,ie;if((B=u==null?void 0:u.toString())!=null&&B.includes(".txt")||(z=u==null?void 0:u.toString())!=null&&z.includes(".cpt")||(P=u==null?void 0:u.toString())!=null&&P.includes(".cyd")){const re=await qa.axios.get(u,{responseType:"blob",headers:{"Content-Type":"application/json"}}),W=new Blob([re.data],{type:"application/octet-stream;charset=UTF-8"});let xe=URL.createObjectURL(W);ta.value=[{name:(ie=u==null?void 0:u.split("/"))==null?void 0:ie[((C=u==null?void 0:u.split("/"))==null?void 0:C.length)-1],blobUrl:xe}],le.value=!0}else Array.isArray(h)&&(h==null?void 0:h.length)>0&&Me("routeUrl",{isEdit:!1,routerUrl:h})};e.onBeforeUnmount(()=>{gn.value=!1;let u=rn.value;rn.value=u+1});const Lr=e.reactive({prop:"",order:null}),Wn=e.computed(()=>{const u=(Ne.value??[]).slice(),h=Lr.prop||de.prop,B=Lr.order||de.order;if(!h||!B)return u;const z=B==="ascending",P=ie=>{if(h)return ie&&Object.prototype.hasOwnProperty.call(ie,h)?ie[h]:h.includes(".")?h.split(".").reduce((re,W)=>re==null?re:re[W],ie):ie==null?void 0:ie[h]},C=ie=>{if(ie==null)return{ok:!1,value:NaN};if(typeof ie=="number")return{ok:Number.isFinite(ie),value:ie};const re=String(ie).trim();if(re==="")return{ok:!1,value:NaN};const W=re.replace(/[,\s]/g,"");if(!/^[+-]?(\d+\.?\d*|\.\d+)$/.test(W))return{ok:!1,value:NaN};const xe=Number(W);return{ok:Number.isFinite(xe),value:xe}};return u.sort((ie,re)=>{const W=P(ie),xe=P(re);if(W==null&&xe==null)return 0;if(W==null)return z?-1:1;if(xe==null)return z?1:-1;const Ae=C(W),je=C(xe);if(Ae.ok&&je.ok)return z?Ae.value-je.value:je.value-Ae.value;const Re=be=>{if(be==null)return{ok:!1,value:NaN};const Ra=String(be).trim();if(Ra==="")return{ok:!1,value:NaN};const fa=Ra.match(/^(-)?(\d+):(\d{1,2}):(\d{1,2})$/);if(!fa)return{ok:!1,value:NaN};const Ea=fa[1]?-1:1,wa=Number(fa[2]),N=Number(fa[3]),Y=Number(fa[4]);return[wa,N,Y].some($e=>Number.isNaN($e))?{ok:!1,value:NaN}:N>=60||Y>=60?{ok:!1,value:NaN}:{ok:!0,value:Ea*(wa*3600+N*60+Y)}},Ge=Re(W),xa=Re(xe);if(Ge.ok&&xa.ok)return z?Ge.value-xa.value:xa.value-Ge.value;const Oa=new Date(W).getTime(),za=new Date(xe).getTime(),Ye=!Number.isNaN(Oa),Qa=!Number.isNaN(za);if(Ye&&Qa)return z?Oa-za:za-Oa;const ya=String(W),el=String(xe);return z?ya.localeCompare(el):el.localeCompare(ya)})}),fn=e.computed(()=>{var B;const u=(ge.currentPage-1)*ge.pageSize,h=u+ge.pageSize;return Me("getSliceContLength",ge),(B=Wn.value)==null?void 0:B.slice(u,h)}),Ni=u=>{ge.currentPage=u,Me("getSliceContLength",ge)},Lo=u=>{var z;ge.pageSize=u;const h=((z=Ne.value)==null?void 0:z.length)??0,B=u>0?Math.ceil(h/u):1;ge.currentPage>B&&(ge.currentPage=B||1,qa.ElMessage.warning("当前页超出范围,已自动跳转到最后一页")),Me("getSliceContLength",ge)},Ro=({prop:u,order:h})=>{Lr.prop=u,Lr.order=h,ge.currentPage=1};function Sn(u){const h=[];function B(z,P=""){z.forEach(C=>{C.children&&C.children.length>0?B(C.children,C.prop):h.push(C.prop)})}return B(u),h}const $o=(u,h)=>{var re,W,xe,Ae;let B=(W=(re=V.value)==null?void 0:re.map(je=>je==null?void 0:je.prop))==null?void 0:W.filter(je=>je!=="operate");((xe=V.value)==null?void 0:xe.some(je=>{var Re;return((Re=je==null?void 0:je.children)==null?void 0:Re.length)>0}))&&(B=Sn((Ae=V.value)==null?void 0:Ae.filter(je=>(je==null?void 0:je.prop)!=="operate")));let P;if(P=(u==null?void 0:u.length)===(B==null?void 0:B.length)?u:u.slice(0,B==null?void 0:B.length),!(P==null?void 0:P.every(je=>B==null?void 0:B.find(Re=>je===Re))))return qa.ElMessage.error("导入的数据表头不匹配");Qr(P,h)},Vo=(u,h)=>{var P;const B=u==null?void 0:u.filter(C=>C!=="序号"),z=h==null?void 0:h.map(C=>{const ie=Object.entries(C);return ie.shift(),Object.fromEntries(ie)});oa.setRefreshCurStructure(!1),((P=V.value)==null?void 0:P.length)===0||$o(B,z)},Fo=(u,h,B,z)=>{const P=[],C=[],ie=xe=>Object.keys(xe).length;for(const xe in u)if(u[xe]!==void 0){const Ae=u[xe],je=[];for(const[Re,Ge]of Object.entries(Ae))je.push(Ge),C.length<ie(Ae)&&C.push(Re);P.push(je)}P.unshift(C);const re=he.utils.aoa_to_sheet(P),W=he.utils.book_new();he.utils.book_append_sheet(W,re,z),he.writeFileSync(W,`${h}.xlsx`),Gl.value=[]},Ti=async(u,h,B,z=!1,P)=>{try{oa.setRefreshCurStructure(!1)}catch(C){qa.ElMessage.error(C)}},Ji=async(u,h)=>{await Ti()},jr=async(u,h)=>{await Ti("columnType",h,u,!1)},Po=async({newRow:u,targetIndex:h})=>{var P;if(!pa(c.config,{type:ce.TABLE}))return;const z=(ge.currentPage-1)*ge.pageSize+(h??0);u._isTemp=!0;try{(u.sort===void 0||u.sort===null||String(u.sort).trim()==="")&&(u.sort=Xn(z,Ne.value||[]))}catch{}Ne.value.splice(z,0,u),await e.nextTick(),v.value.has(u.id)||v.value.set(u.id,A.cloneDeep(u)),Ne.value=(P=Ne.value)==null?void 0:P.map(C=>({...C,tableEditType:(C==null?void 0:C.id)===u.id?"edit":(C==null?void 0:C.tableEditType)??"text"})),s.value.add(u.id),Vl.value=!0},jo=(u,h,B,z=[])=>(!Array.isArray(h)||h.length===0||h.forEach(P=>{const C=P==null?void 0:P.prop;if(!C)return;let ie=u==null?void 0:u[C];if(ie==null||String(ie).trim()==="")return;ie=String(ie);const re=new Set([...(Array.isArray(B)?B:[]).filter(Ae=>(Ae==null?void 0:Ae.id)!==(u==null?void 0:u.id)).map(Ae=>Ae==null?void 0:Ae[C]).filter(Ae=>Ae!=null).map(Ae=>String(Ae)),...(Array.isArray(z)?z:[]).map(Ae=>Ae==null?void 0:Ae[C]).filter(Ae=>Ae!=null).map(Ae=>String(Ae))]);if(!re.has(ie))return;let W=1,xe="";for(;xe=`${ie}(${W})`,!!re.has(xe);)W++;u[C]=xe}),u),Ai=async()=>{var P,C,ie,re,W,xe,Ae,je;const u=Array.from(s.value||[]);if(u.length===0)return;const h=(C=he.getColumnChild((P=A.cloneDeep(V.value))==null?void 0:P.filter(Re=>(Re==null?void 0:Re.label)!=="操作")))==null?void 0:C.filter(Re=>(Re==null?void 0:Re.required)===!0);if((h==null?void 0:h.length)>0)for(let Re=0;Re<u.length;Re++){const Ge=u[Re],xa=(ie=Ne.value)==null?void 0:ie.find(Oa=>(Oa==null?void 0:Oa.id)===Ge);if(xa)for(let Oa=0;Oa<h.length;Oa++){const za=h[Oa],Ye=za==null?void 0:za.prop,Qa=(za==null?void 0:za.label)??Ye,ya=xa==null?void 0:xa[Ye];if(ya===""||ya===null||ya===void 0||Array.isArray(ya)&&ya.length===0){qa.ElMessage.error(`${Qa}不能为空`);return}}}const B=[],z=[];if(u.forEach(Re=>{var Qa;const Ge=(Qa=Ne.value)==null?void 0:Qa.find(ya=>(ya==null?void 0:ya.id)===Re);if(!Ge)return;if(Ge!=null&&Ge._isTemp){const el=(he.getAllLeafNodes(V.value)||[]).filter(N=>(N==null?void 0:N.mainKey)===!0||(N==null?void 0:N.isMainKey)===!0),be=Ne.value.findIndex(N=>(N==null?void 0:N.id)===Re),Ra=be>=0?be+1:Ne.value.length+1;jo(Ge,el,Ne.value,B);const fa={id:Ra.toString()};(Ge==null?void 0:Ge.sort)!==void 0&&(Ge==null?void 0:Ge.sort)!==null&&String(Ge.sort).trim()!==""?fa.sort=String(Ge.sort):fa.sort=Xn(be>=0?be:Ne.value.length-1,Ne.value||[]),(he.getAllLeafNodes(V.value)||[]).filter(N=>(N==null?void 0:N.type)!=="operate"&&(N==null?void 0:N.label)!=="操作"&&(N==null?void 0:N.prop)!=="operate").forEach(N=>{const Y=N==null?void 0:N.prop;if(Y){const $e=Ge[Y];$e!==void 0?fa[Y]=$e??"":fa[Y]=""}}),B.push(fa);return}const Oa=(he.getAllLeafNodes(V.value)||[]).filter(ya=>(ya==null?void 0:ya.type)!=="operate"&&(ya==null?void 0:ya.label)!=="操作"&&(ya==null?void 0:ya.prop)!=="operate"),za=new Set(Oa.map(ya=>ya==null?void 0:ya.prop).filter(Boolean)),Ye={};for(const ya of za)Object.prototype.hasOwnProperty.call(Ge,ya)&&(Ye[ya]=Ge[ya]);z.push({id:Ge.id,value:{tableData:Ye}})}),oa.setTableLoading(c==null?void 0:c.index),z.length>0){const Re=z.map(xa=>{const Oa={id:xa.id,...xa.value.tableData};return delete Oa._isOCRRow,delete Oa._ocrTableId,delete Oa._isTemp,delete Oa.tableEditType,delete Oa.index,Oa}),Ge=[{tableName:((re=c==null?void 0:c.related)==null?void 0:re.find(xa=>xa==null?void 0:xa.includes("content")))??"content_"+(c==null?void 0:c.index),tableContents:Re}];try{await A.pageBatchUpdateApi({platId:parseInt((W=cl.value)==null?void 0:W.plat_id),changeContents:Ge})}catch(xa){qa.ElMessage.error(((Ae=(xe=xa==null?void 0:xa.response)==null?void 0:xe.data)==null?void 0:Ae.message)||(xa==null?void 0:xa.message)||"保存失败"),oa.setTableLoading(!1);return}}if(B.length>0){const Re={fixContent:B,buttonName:"新增",relatedContents:c==null?void 0:c.related,name:c==null?void 0:c.compName,columns:V.value};Me("change",Re)}qa.ElMessage.success("保存成功"),s.value.clear(),v.value.clear(),Ne.value=(je=Ne.value)==null?void 0:je.map(Re=>({...Re,tableEditType:"text"})),Vl.value=!1,oa.setRefreshCurStructure(!0)},Ho=()=>{var h;const u=Array.from(s.value||[]);if(u.length===0){Vl.value=!1;return}u.forEach(B=>{var C,ie;const z=v.value.get(B),P=(C=Ne.value)==null?void 0:C.find(re=>(re==null?void 0:re.id)===B);if(P!=null&&P._isTemp){Ne.value=Ne.value.filter(re=>(re==null?void 0:re.id)!==P.id);return}if(z){const re=(ie=Ne.value)==null?void 0:ie.findIndex(W=>(W==null?void 0:W.id)===B);re!==-1&&(Ne.value[re]={...Ne.value[re],...z})}}),s.value.clear(),v.value.clear(),Ne.value=(h=Ne.value)==null?void 0:h.map(B=>({...B,tableEditType:"text"})),Vl.value=!1},zi=e.ref(!1),Xi=async u=>{var P,C,ie,re;if(!Vl.value||u!=null&&u.isComposing||(u==null?void 0:u.key)!=="Enter")return;const h=u==null?void 0:u.target;if(((C=(P=h==null?void 0:h.tagName)==null?void 0:P.toLowerCase)==null?void 0:C.call(P))==="textarea")return;const z=document.getElementById("excel-table");z&&!z.contains(h)||((ie=h==null?void 0:h.blur)==null||ie.call(h),(re=u.preventDefault)==null||re.call(u),await e.nextTick(),await Zi())},Zi=async()=>{if(H.value){Vl.value=!1;return}if(!zi.value){zi.value=!0;try{Array.from(s.value||[]).length>0?await Ai():Vl.value=!1}finally{Promise.resolve().then(()=>{zi.value=!1})}}},Uo=u=>{Gl.value=u},Qi=(u,h)=>{hr.value===h?Or.value=!1:Or.value=!0,hr.value=h==null?void 0:h.changeProp},si=u=>{if(!u)return;const{item:h,value:B}=u,z=Ha.value.find(P=>P.prop==h.prop);z&&z.contents.push({label:B,value:B})},nn=e.computed(()=>{var B,z,P;const u=(B=V.value)==null?void 0:B.some(C=>C==null?void 0:C.filterable);return document.documentElement.style.setProperty("--ssTable-header-filter-display",u?"inline-block":"none"),(P=(z=V.value)==null?void 0:z.filter(C=>(C==null?void 0:C.label)!=="操作"))==null?void 0:P.map(C=>({...C,filterable:!!(C!=null&&C.filterable),showSummary:!!(C!=null&&C.showSummary),operable:!!(C!=null&&C.operable),fixed:C==null?void 0:C.fixed}))}),Kn=async(u,h,B)=>{const z=A.cloneDeep(V.value);await e.nextTick();const P=z==null?void 0:z.map(ie=>(B==null?void 0:B.label)===(ie==null?void 0:ie.label)?{...ie,[h]:u}:ie),C=Mi(P);await hs(c.index,C),V.value=P,fe.value=C},Mi=u=>{var P;const h=u||[];return((P=he.getAllLeafNodes(h)||[])==null?void 0:P.filter(C=>(C==null?void 0:C.prop)&&(C==null?void 0:C.type)!=="operate"&&(C==null?void 0:C.label)!=="操作"&&(C==null?void 0:C.prop)!=="operate")).map(C=>{const{prop:ie}=C;return n0(ie,C)})},eo=async u=>{let h=await o0(c.index);h||(h=Mi(u)),fe.value=h},ao=async(u,h)=>{const B=A.cloneDeep(V.value),z=ie=>Array.isArray(ie)?ie.map(re=>{const W=Array.isArray(re==null?void 0:re.children)&&re.children.length>0,xe={...re};return(xe==null?void 0:xe.prop)==="operate"||(xe==null?void 0:xe.label)==="操作"||(xe==null?void 0:xe.type)==="operate"?(xe.sortable=!1,xe.filterable=!1,xe.operable=!1):xe.sortable=W?!1:!!u,W&&(xe.children=z(xe.children)),xe}):ie,P=z(B),C=Mi(P);await hs(c.index,C),V.value=P,fe.value=C,await e.nextTick(),rn.value=rn.value+1},lo=()=>{Z.value=!1},Gn=u=>{Me("clickTrigger",u)},ro=async u=>{var C,ie,re,W,xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa,ya;const h=u==null?void 0:u.row,B=u==null?void 0:u.rowData,z=u==null?void 0:u.suffix;if((C=h==null?void 0:h.toString())!=null&&C.includes(".urdf")||u!=null&&u.isUrdf||z!=null&&z.includes(".urdf")){if(h.includes(",")){qa.ElMessage.error("当前版本仅允许单个urdf预览!");return}if(ue(h)){const be={files:[Pe(h)],data:{}};Le(be);return}_a.value=[{url:h,extension:Se(h)}],ye.value=!0,T.value={data:A.cloneDeep(B)},Fe.value=!0;return}let P=[];if((ie=h==null?void 0:h.toString())!=null&&ie.includes(".stl")||(re=h==null?void 0:h.toString())!=null&&re.includes(".STL")||(W=h==null?void 0:h.toString())!=null&&W.includes(".obj")||(xe=h==null?void 0:h.toString())!=null&&xe.includes(".mtl")){const el=(Ae=h==null?void 0:h.toString())==null?void 0:Ae.split(","),be=la(el),Ra=be==null?void 0:be[0];if(ue(Ra==null?void 0:Ra.extension)){Le({files:be,data:{}});return}_a.value=be,ye.value=!1,Fe.value=!0;return}if((je=h==null?void 0:h.toString())!=null&&je.includes(".stl")||(Re=h==null?void 0:h.toString())!=null&&Re.includes(".STL")||(Ge=h==null?void 0:h.toString())!=null&&Ge.includes(".obj")||(xa=h==null?void 0:h.toString())!=null&&xa.includes(".mtl")||z!=null&&z.includes(".stl")||z!=null&&z.includes(".STL")||z!=null&&z.includes(".obj")||z!=null&&z.includes(".mtl")){let el,be=[],Ra={};if(Array.isArray(h)?el=h:el=h==null?void 0:h.split(","),el==null||el.forEach(fa=>{fa.includes(".mtl")?be.push(fa):Ra.blob=Ra.blob?Ra.blob+","+fa:fa}),(be==null?void 0:be.length)>0&&(Ra.mtlBlobs=be),z&&(Ra.suffix=z),(za=(Oa=Object.values(Ra))==null?void 0:Oa[0])!=null&&za.includes("http:"))P.push(Ra);else{const fa=new Blob([Ra.blob],{type:"application/octet-stream;charset=UTF-8"});let Ea=URL.createObjectURL(fa),wa="";(Ye=h==null?void 0:h.split("/"))==null||Ye.forEach((N,Y)=>{var $e;Y===(($e=h==null?void 0:h.split("/"))==null?void 0:$e.length)-1&&(wa=N)}),(Qa=Ra.blob)!=null&&Qa.includes(".stl")&&(wa=(wa==null?void 0:wa.replaceAll(">",""))+".urdf"),ta.value=[{name:wa,blobUrl:Ea}],le.value=!0}}else{const el=await qa.axios.get(h,{responseType:"blob",headers:{"Content-Type":"application/json"}}),be=new Blob([el.data],{type:"application/octet-stream;charset=UTF-8"});let Ra=URL.createObjectURL(be),fa="";if((ya=h==null?void 0:h.split("/"))==null||ya.forEach((Ea,wa)=>{var N;wa===((N=h==null?void 0:h.split("/"))==null?void 0:N.length)-1&&(fa=Ea)}),ue(fa)){const Ea=U(fa),wa=Pe(h);Le({files:[wa],data:{trackFileType:Ea}});return}ta.value=[{name:fa,blobUrl:Ra}],le.value=!0}(P==null?void 0:P.length)>0&&n.setBlobUrls(P)},Yn=u=>{var z,P,C,ie;if(u!=null&&u.downloadUrl)return u==null?void 0:u.name;const h=(ie=(z=u==null?void 0:u.url)==null?void 0:z.split("."))==null?void 0:ie[((C=(P=u==null?void 0:u.url)==null?void 0:P.split("."))==null?void 0:C.length)-1];return(u==null?void 0:u.name)+"."+h},no=u=>{if(!u)return"未知文件";try{const z=Yn(u);if(typeof z=="string"&&z.includes("."))return z}catch{}const h=(u==null?void 0:u.fileName)||(u==null?void 0:u.name)||"未知文件",B=(u==null?void 0:u.suffix)||"";return h.includes(".")?h:`${h}${B}`},io=u=>{if(u==null||typeof u=="number"||typeof u!="string")return u;const h=u.match(/^(\d+)\_(\d+)$/);if(!h)return u;const B=Number(h[1]),z=Number(h[2]);return!Number.isFinite(B)||!Number.isFinite(z)?u:String(B*1e3+z)},Jn=u=>{if(u==null)return null;const h=String(u).trim();if(!h)return null;const B=Number(h);return Number.isFinite(B)?B:null},qo=u=>{if(u==null)return null;const h=String(u).trim();if(!h)return null;if(/^\d+$/.test(h)){const P=Number(h);return Number.isFinite(P)?h.length<=10?P*1e3:P:null}const B=h.includes("T")?h:h.replace(" ","T"),z=Date.parse(B);return Number.isFinite(z)?z:null},ci=(u,h=[])=>{const B=Array.isArray(u)?u.slice():[];if(B.length<=1)return B;const z=new Map((h||[]).map((ie,re)=>[String(ie),re])),P=B.some(ie=>Jn(ie==null?void 0:ie.sort)!==null),C=B.map((ie,re)=>({r:ie,idx:re,id:String((ie==null?void 0:ie.id)??""),sortVal:Jn(ie==null?void 0:ie.sort),createTimeMs:qo(ie==null?void 0:ie.create_time),prevIdx:z.has(String(ie==null?void 0:ie.id))?z.get(String(ie==null?void 0:ie.id)):Number.POSITIVE_INFINITY}));return C.sort((ie,re)=>{if(P){const Ae=ie.sortVal,je=re.sortVal;if(Ae===null&&je!==null)return 1;if(Ae!==null&&je===null)return-1;if(Ae!==null&&je!==null&&Ae!==je)return Ae-je}const W=ie.createTimeMs,xe=re.createTimeMs;return W!==null&&xe!==null&&W!==xe?xe-W:W!==null&&xe===null?-1:W===null&&xe!==null?1:ie.prevIdx!==re.prevIdx?ie.prevIdx-re.prevIdx:ie.idx-re.idx}),C.map(ie=>ie.r)},Xn=(u,h=[])=>{const B=h==null?void 0:h[u-1],z=h==null?void 0:h[u],P=Jn(B==null?void 0:B.sort),C=Jn(z==null?void 0:z.sort);let ie=null;P!==null&&C!==null&&C>P?ie=(P+C)/2:P!==null?ie=P+1:C!==null?ie=Math.max(C-1,0):ie=(u??0)+1;const re=Number(ie.toFixed(6));return String(Number.isFinite(re)?re:ie)},ui=async u=>{let h=null,B=null;if(u!=null&&u.id){const P=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});try{const C=await A.platformDownloadFile(u);h=URL.createObjectURL(C.data),B=no(u)}finally{P.close()}}else if(u!=null&&u.downloadUrl){const P=await di(),C=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),ie=await qa.axios.post(u==null?void 0:u.url,null,{responseType:"blob",headers:{Authorization:P,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}).finally(()=>{C.close()}),re=new Blob([ie.data],{type:"application/octet-stream;charset=UTF-8"});h=URL.createObjectURL(re),B=u==null?void 0:u.name}else{const P=await A.platformDownloadFile({url:u==null?void 0:u.url});!u.url.toUpperCase().includes(".OBJ")&&!u.url.toUpperCase().includes(".STL")&&!u.url.toUpperCase().includes(".MTL")&&!u.url.toUpperCase().includes(".URDF")?(h=URL.createObjectURL(P.data),B=Yn(u)):h=u==null?void 0:u.url}if(ue(h)){const P={row:`${h}`,suffix:Se(B)};ro(P);return}const z={name:B,blobUrl:h};ta.value=[z],le.value=!0},Wo=async u=>{let h=null,B=null;if(u!=null&&u.id){const C=await A.platformDownloadFile(u);h=URL.createObjectURL(C.data),B=no(u)}else if(u!=null&&u.downloadUrl){const C=await di(),ie=await qa.axios.post(u==null?void 0:u.url,null,{responseType:"blob",headers:{Authorization:C,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}),re=new Blob([ie.data],{type:"application/octet-stream;charset=UTF-8"});h=URL.createObjectURL(re),B=u==null?void 0:u.name}else{const C=await A.platformDownloadFile({url:u==null?void 0:u.url});h=URL.createObjectURL(C.data),B=Yn(u)}const z={name:B,blobUrl:h},P=document.createElement("a");P.href=z.blobUrl,P.download=z.name,P.style.display="none",document.body.appendChild(P),P.click(),setTimeout(()=>{document.body.removeChild(P)},100)},Ii=(u,h)=>{var z;if(Object.values(h).length===0)return;let B=u;return Object.values(h).find(P=>{var C,ie,re;return((C=P==null?void 0:P.toString())==null?void 0:C.includes(".txt"))||((ie=P==null?void 0:P.toString())==null?void 0:ie.includes(".cpt"))||((re=P==null?void 0:P.toString())==null?void 0:re.includes(".obj"))})?B=[...u,Be.value]:(z=c==null?void 0:c.config)!=null&&z.allowMove&&(B=[...u,{label:"迁移"}]),B},Ko=()=>{I.value=!0},Go=e.ref([]),oo=async(u,h,B=!1)=>{var ie,re,W,xe;if(!u)return;if(B){Ne.value=[...Ta.value.values()].filter(Ae=>Object.values(Ae).some(je=>typeof je=="string"?je==null?void 0:je.toLowerCase().includes(h==null?void 0:h.toLowerCase()):!1));return}let z={};for(let Ae in u)(u==null?void 0:u[Ae])!==""&&(z[Ae]=u==null?void 0:u[Ae]);if(JSON.stringify(z)==="{}"){Ne.value=Array.from(((ie=Ta.value)==null?void 0:ie.values())??[]);return}let P=(re=c==null?void 0:c.related)==null?void 0:re.find(Ae=>Ae==null?void 0:Ae.includes("content_")),C=await A.getFillFind({platId:parseInt((W=cl==null?void 0:cl.value)==null?void 0:W.plat_id),tableName:P,params:z});C=(xe=C==null?void 0:C.data)==null?void 0:xe.result,Ne.value=C,oa.setTableLoading(!1)},Zn=e.computed(()=>{var h,B;return((B=(h=c==null?void 0:c.itemData)==null?void 0:h.find(z=>(z==null?void 0:z.key)==="isEdit"))==null?void 0:B.contents)??!0}),En=async u=>{var z,P,C,ie;if(!pa(c.config,{type:ce.TABLE})||!(((P=(z=c==null?void 0:c.itemData)==null?void 0:z.find(re=>(re==null?void 0:re.key)==="isEdit"))==null?void 0:P.contents)??!0)||!u)return;((C=Array.from(s.value))==null?void 0:C.length)>0&&await Ai();const B=u==null?void 0:u.id;B!=null&&(s.value.clear(),v.value.clear(),v.value.has(B)||v.value.set(B,A.cloneDeep(u)),Ne.value=(ie=Ne.value)==null?void 0:ie.map(re=>({...re,tableEditType:(re==null?void 0:re.id)===B?"edit":"text"})),s.value.add(B),Vl.value=!0)},Oi=async(u,h,B,z)=>{z!=null&&z.isExistChild&&Me("clickMainKey",u,B,V.value)},Li=()=>{le.value=!1},Yo=u=>{Me("rowClick",u)};e.watch(()=>c.changedContent,()=>{var B,z;if(!c.changedContent)return;let u=(B=Ne.value)==null?void 0:B.map(P=>{var C;return P.id===((C=c.changedContent)==null?void 0:C.id)&&(P={...c.changedContent,id:c.changedContent.newId?c.changedContent.newId:c.changedContent.id},delete P.newId),P});const h=(z=c.itemData)==null?void 0:z.map(P=>((P==null?void 0:P.key)==="tableContents"&&(P.contents=u),P));Ne.value=u,Me("contentChange",{contents:h,index:c.index}),Me("change",{content:u,index:c==null?void 0:c.index,buttonName:"",id:c==null?void 0:c.index})},{deep:!0,immediate:!0});const Jo=()=>{},Xo=async()=>{const u=Ee.value,h=sessionStorage.getItem("systemKey"),B=await he.getItemData(u,h,""),z=(B==null?void 0:B.find(re=>(re==null?void 0:re.name)==="方法明细"))||(B==null?void 0:B[0]),P=(z==null?void 0:z.compData)||[],C=P==null?void 0:P.find(re=>{const W=re==null?void 0:re.key;return W==="formContent"||W==="tableContents"});return C==null?void 0:C.contents},di=async()=>{const h=qa.Local.get("access-token");return h?`Bearer ${h}`:""},Zo=async(u,{token:h,inputData:B}={})=>await qa.axios.post(u,B,{headers:{Authorization:h}}).catch(P=>(te.setImportLoading(!1),Promise.reject(P))),Qo=u=>{var z;let h={};const B=[];return h.form={},(z=A.cloneDeep(u))==null||z.forEach((P,C)=>{var ie,re,W,xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa,ya;if((P==null?void 0:P.comp)==="Table"){(re=(ie=P==null?void 0:P.compData)==null?void 0:ie.find(fa=>(fa==null?void 0:fa.key)==="header"))==null||re.contents;let el=(Ae=(xe=(W=P==null?void 0:P.compData)==null?void 0:W.find(fa=>(fa==null?void 0:fa.key)==="tableContents"))==null?void 0:xe.contents)==null?void 0:Ae.map(fa=>fa.slice(1));(Oa=(xa=(Ge=(Re=(je=P==null?void 0:P.compData)==null?void 0:je.find(fa=>(fa==null?void 0:fa.key)==="header"))==null?void 0:Re.contents)==null?void 0:Ge[0])==null?void 0:xa[0])==null||Oa.label;let be=(Ye=(za=P==null?void 0:P.compData)==null?void 0:za.find(fa=>(fa==null?void 0:fa.key)==="header"))==null?void 0:Ye.contents,Ra=[];el==null||el.forEach(fa=>{let Ea=[];fa==null||fa.forEach((wa,N)=>{var $e;let Y={};(($e=be[N])==null?void 0:$e.label)!=="操作"&&(Y[be[N].label]=wa,Ea.push(Y))}),Ra.push(Ea)}),h[P.name]=Ra}else{const el=(ya=(Qa=P.compData)==null?void 0:Qa.find(be=>(be==null?void 0:be.key)==="formContent"))==null?void 0:ya.contents;el==null||el.forEach(be=>{var Ra,fa;if(be.prop!==""){let Ea=be==null?void 0:be.value;Array.isArray(Ea)?Ea=((Ra=Ea==null?void 0:Ea[0])==null?void 0:Ra.oldUrl)||"http://222.92.178.198:62001/"+((fa=Ea==null?void 0:Ea[0])==null?void 0:fa.url):Ea=Ea.toString(),be={key:(be==null?void 0:be.prop)??(be==null?void 0:be.label),value:Ea},B.push(be)}})}}),h.form=he.getFormContents(B),h},et=u=>{const h=[],B=z=>{z&&typeof z=="object"&&!Array.isArray(z)?Object.values(z).forEach(B):h.push(z)};return B(u),h},at=async(u,h,B)=>{var be,Ra,fa,Ea,wa,N,Y,$e,na,_e,sa,Na,nl,Wa,ul,dl,Fl;te.setImportLoading(!0),oa.setFreshContent(!1);let z=await Xo().catch(Ua=>(te.setImportLoading(!1),Promise.reject(Ua)));z=z==null?void 0:z.filter(Ua=>{var ml;return((ml=Ua==null?void 0:Ua.find(Pa=>Pa==null?void 0:Pa.id))==null?void 0:ml.id)===(h==null?void 0:h.id)});let P=he.getEqualChild([(be=V.value)==null?void 0:be.filter(Ua=>(Ua==null?void 0:Ua.label)!=="操作")]);const C=(fa=(Ra=he.tableToForm(z,P))==null?void 0:Ra[0])==null?void 0:fa.find(Ua=>{const ml=Ua==null?void 0:Ua.key;return ml==="Interface"||ml==="方法体"}),ie=C==null?void 0:C.value;if(!ie){console.log("未搜索到isMain, 缺少算法执行接口"),te.setImportLoading(!1);return}const re=V.value?he.getEqualChild([V.value]):[],W=re.find(Ua=>{const ml=Ua==null?void 0:Ua.prop;return ml==="Input1"||ml==="输入数据.输入1"||ml==="样本输入数据"}),xe=W==null?void 0:W.prop;let Ae=h==null?void 0:h[xe];const je=await di().catch(Ua=>(te.setImportLoading(!1),Promise.reject(Ua)));let Re=!0,Ge="";(Ea=V.value)==null||Ea.forEach(Ua=>{(Ua==null?void 0:Ua.prop)===xe&&(Re=!!(Ua!=null&&Ua.childPath),Ge=Ua==null?void 0:Ua.childPath)});let xa="";if(Re){let Ua=(N=(wa=V.value)==null?void 0:wa.find(tl=>(tl==null?void 0:tl.isMainKey)===!0))==null?void 0:N.prop;xa=h==null?void 0:h[Ua];let ml=Ge==null?void 0:Ge.split(w),Pa=[];ml==null||ml.forEach((tl,wl)=>{(ml==null?void 0:ml.length)-1===wl&&Pa.push(xa),Pa.push(tl)}),Pa=Pa==null?void 0:Pa[0];let ol=await he.getItemData(Pa,sessionStorage.getItem("systemKey"),""),Ga=ol==null?void 0:ol.filter(tl=>(tl==null?void 0:tl.name)===xe);Ga=Ga==null?void 0:Ga.map(tl=>{var wl;return tl.compData=(wl=tl==null?void 0:tl.compData)==null?void 0:wl.map(Dl=>{var xr;return(Dl==null?void 0:Dl.key)==="tableContents"&&(Dl.contents=(xr=Dl==null?void 0:Dl.contents)==null?void 0:xr.filter(Rl=>(Rl==null?void 0:Rl[1])===(h==null?void 0:h[xe]))),Dl}),tl}),(!Ga||(Ga==null?void 0:Ga.length)===0)&&(Ga=ol,Ga=Ga==null?void 0:Ga.map(tl=>{var wl;return tl.compData=(wl=tl==null?void 0:tl.compData)==null?void 0:wl.map(Dl=>{var xr;return(Dl==null?void 0:Dl.key)==="tableContents"&&(Dl.contents=(xr=Dl==null?void 0:Dl.contents)==null?void 0:xr.filter(Rl=>{var gl,Tl;return(Rl==null?void 0:Rl[1])===(h==null?void 0:h[(Tl=(gl=V==null?void 0:V.value)==null?void 0:gl[0])==null?void 0:Tl.prop])})),Dl}),tl})),Ae=Qo(Ga)}const Oa=await Zo(ie,{token:je,inputData:Ae}).catch(Ua=>(te.setImportLoading(!1),Promise.reject(Ua))),za=(Y=Oa==null?void 0:Oa.data)==null?void 0:Y.data,Ye=re.find(Ua=>(Ua==null?void 0:Ua.prop)==="Output1"),Qa=Ye==null?void 0:Ye.prop;let ya=[],el=[];if(za&&(($e=Object.values(za))==null?void 0:$e.length)>0){let Ua=[];const ml=new FormData,Pa=(na=et(za))==null?void 0:na.map(async Ga=>{var tl,wl;if(!Array.isArray(Ga)&&(Ga!=null&&Ga.includes("http"))){let Dl=await qa.axios.get(Ga,{responseType:"blob"}),xr=(wl=Ga==null?void 0:Ga.split("/"))==null?void 0:wl[((tl=Ga==null?void 0:Ga.split("/"))==null?void 0:tl.length)-1];ml.append("files",Dl.data,xr)}else Ua.push(Ga)});if(await Promise.all(Pa),!he.isFormDataEmpty(ml)){let Ga=await A.uploadAmountApi(ml),tl=(sa=(_e=Ga==null?void 0:Ga.data)==null?void 0:_e.result)==null?void 0:sa.map(wl=>{var Dl,xr,Rl,gl,Tl,Xl;return{name:(Xl=(Tl=(gl=(Dl=wl==null?void 0:wl.url)==null?void 0:Dl.split("/"))==null?void 0:gl[((Rl=(xr=wl==null?void 0:wl.url)==null?void 0:xr.split("/"))==null?void 0:Rl.length)-1])==null?void 0:Tl.split("."))==null?void 0:Xl[0],url:wl==null?void 0:wl.url}});Ua=[...Ua,...tl]}let ol={};for(let Ga in h)Ga!=="id"&&(ol[Ga]=h[Ga]);ol[Qa]=Ua,el.push({id:h==null?void 0:h.id,value:{tableData:ol}})}if((el==null?void 0:el.length)>0){const Ua=el.map(Pa=>{const ol={id:Pa.id,...Pa.value.tableData};return delete ol._isOCRRow,delete ol._ocrTableId,delete ol._isTemp,delete ol.tableEditType,delete ol.index,ol}),ml=[{tableName:(Na=c==null?void 0:c.related)==null?void 0:Na.find(Pa=>Pa==null?void 0:Pa.includes("content")),tableContents:Ua}];await A.pageBatchUpdateApi({platId:parseInt((nl=cl.value)==null?void 0:nl.plat_id),changeContents:ml})}if((ya==null?void 0:ya.length)>0)try{await A.pageBatchAddApi({platId:parseInt((Wa=cl.value)==null?void 0:Wa.plat_id),changeContents:[{tableName:(ul=c==null?void 0:c.related)==null?void 0:ul.find(Ua=>Ua==null?void 0:Ua.includes("content")),tableContents:ya.map(Ua=>{var Pa,ol,Ga;const ml={id:((Pa=Ua==null?void 0:Ua.key)==null?void 0:Pa.id)??((ol=Ua==null?void 0:Ua.key)==null?void 0:ol.rowId)??(Ua==null?void 0:Ua.id),...((Ga=Ua==null?void 0:Ua.value)==null?void 0:Ga.tableData)||{}};return delete ml._isOCRRow,delete ml._ocrTableId,delete ml._isTemp,delete ml.tableEditType,delete ml.index,Object.keys(ml).forEach(tl=>{tl==="证书附件"&&Array.isArray(ml[tl])&&(ml[tl]=JSON.stringify(ml[tl]))}),ml})}]})}catch(Ua){qa.ElMessage.error(((Fl=(dl=Ua==null?void 0:Ua.response)==null?void 0:dl.data)==null?void 0:Fl.message)||(Ua==null?void 0:Ua.message)||"保存失败"),oa.setTableLoading(!1);return}Vi(!0),te.setImportLoading(!1),oa.setFreshContent(!0)},to=(u,h)=>(u=u==null?void 0:u.map(B=>{var z,P;return B!=null&&B.children&&((z=B.children)!=null&&z.find(C=>C.id===(h==null?void 0:h.id))?B.children=(P=B.children)==null?void 0:P.filter(C=>(C==null?void 0:C.id)!==(h==null?void 0:h.id)):B.children=to(B.children,h)),B}),u),pi=e.ref(!1),o=()=>{pi.value=!0},i=async u=>{var B,z,P,C;pi.value=!1;const h=Array.isArray(u)?u:u?[u]:[];if(h.length!==0)for(const ie of h){const re={name:ie.name||`capture-${Date.now()}.jpg`,url:URL.createObjectURL(ie),raw:ie,uid:Date.now()+Math.random()};ka.value.push(re),rr(re,"uploading"),Al(re,0);try{const W=new FormData;W.append("file",ie,re.name);const xe=await A.platformUploadFile(W);re.uploadResult=((B=xe==null?void 0:xe.data)==null?void 0:B.result)||{name:re.name,url:"",fileName:re.name},Pl({name:((z=re.uploadResult)==null?void 0:z.name)||re.name,url:((P=re.uploadResult)==null?void 0:P.url)||"",id:(C=re.uploadResult)==null?void 0:C.id}),rr(re,"uploaded"),Al(re,100)}catch(W){console.error("文件上传失败:",W),qa.ElMessage.error(`文件 ${re.name} 上传失败,请重试`),rr(re,"pending"),Al(re,0);const xe=ka.value.findIndex(Ae=>Ae.uid===re.uid);xe>-1&&ka.value.splice(xe,1)}}},f=e.reactive({title:"迁移至",show:!1,width:"20%",selectRow:null,from:c==null?void 0:c.index,to:null,contents:[],formRules:{groupName:[{required:!0,message:"输入不能为空",trigger:"blur"},{validator:(u,h,B)=>{h===(c==null?void 0:c.index)?B(new Error("选择源不能和目标源一致")):B()}}]},buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"确认",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]}),m=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:""}),_=()=>{m.show=!1},O=async u=>{var h,B,z,P,C,ie,re,W;try{const xe=[];let Ae=(h=Ne.value||[])==null?void 0:h.slice();(u||[]).forEach(Oa=>{const za={...Oa};try{za.sort=Xn(0,Ae)}catch{}xe.push(za),Ae.unshift(za)});let je=await A.quoteApi({platId:parseInt((B=cl==null?void 0:cl.value)==null?void 0:B.plat_id),type:"fatherSyncs",related:[{menus:Ee.value,groups:""},{menus:Ee.value,groups:c==null?void 0:c.compName}]});je=(z=je==null?void 0:je.data)==null?void 0:z.result;let Re=je==null?void 0:je.map(Oa=>({tableName:"content_"+(Oa==null?void 0:Oa.id),tableContents:xe==null?void 0:xe.map((za,Ye)=>({id:Ye,...za}))})),Ge=[{tableName:(P=c==null?void 0:c.related)==null?void 0:P.find(Oa=>Oa==null?void 0:Oa.includes("content")),tableContents:xe==null?void 0:xe.map((Oa,za)=>({id:za,...Oa}))}];Ge=[...Ge,...Re];const xa=await A.pageBatchAddApi({platId:parseInt((C=cl.value)==null?void 0:C.plat_id),changeContents:Ge});if(((ie=xa==null?void 0:xa.data)==null?void 0:ie.code)===200){const Oa={buttonName:"新增",columns:V.value,fixContent:xe==null?void 0:xe.map((Ye,Qa)=>({id:Qa,...Ye})),relatedContents:c==null?void 0:c.related};await xt(Oa),qa.ElMessage.success("数据导入成功");let za=[];Ge==null||Ge.forEach(Ye=>{var Qa;(Qa=Ye==null?void 0:Ye.tableContents)==null||Qa.forEach(ya=>{za.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ya),request_result:"{}",is_delete:!1,request_table:Ye==null?void 0:Ye.tableName,request_type:"export"})})}),await A.pageBatchAddApi({platId:parseInt((re=cl==null?void 0:cl.value)==null?void 0:re.plat_id),changeContents:[{tableName:"log",tableContents:za}]})}else{let Oa=[];Ge==null||Ge.forEach(za=>{var Ye;(Ye=za==null?void 0:za.tableContents)==null||Ye.forEach(Qa=>{Oa.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Qa),request_result:"{}",is_delete:!1,request_table:za==null?void 0:za.tableName,request_type:"error"})})}),await A.pageBatchAddApi({platId:parseInt((W=cl==null?void 0:cl.value)==null?void 0:W.plat_id),changeContents:[{tableName:"log",tableContents:Oa}]}),qa.ElMessage.error("数据导入响应失败")}}catch(xe){throw new Error(xe)}},G=async u=>{var h,B,z,P,C,ie,re,W,xe,Ae;try{if(u==="cancel"&&(m.show=!1),u==="replace"&&((h=m==null?void 0:m.existRows)==null?void 0:h.length)>0){await A.pageBatchDeleteApi({platId:parseInt((B=cl.value)==null?void 0:B.plat_id),changeContents:[{tableName:((z=c==null?void 0:c.related)==null?void 0:z.find(Re=>Re==null?void 0:Re.includes("content_")))||((P=c==null?void 0:c.related)==null?void 0:P.find(Re=>Re==null?void 0:Re.includes("content"))),tableContents:m==null?void 0:m.existRows}]});const je=await A.pageBatchAddApi({platId:parseInt((C=cl.value)==null?void 0:C.plat_id),changeContents:[{tableName:(ie=c==null?void 0:c.related)==null?void 0:ie.find(Re=>Re==null?void 0:Re.includes("content")),tableContents:(()=>{const Re=(Ne.value||[]).filter(za=>!((m==null?void 0:m.existRows)||[]).some(Ye=>String(Ye==null?void 0:Ye.id)===String(za==null?void 0:za.id))),Ge=(m==null?void 0:m.tableData)||[],xa=[];let Oa=Re.slice();return Ge.forEach(za=>{const Ye={...za};try{Ye.sort=Xn(0,Oa)}catch{}xa.push(Ye),Oa.unshift(Ye)}),xa.map((za,Ye)=>({id:Ye,...za}))})()}]});if(((re=je==null?void 0:je.data)==null?void 0:re.code)!==200)return;(W=m.newRows)!=null&&W.length&&await O(m.newRows),await xt({buttonName:"新增",columns:V.value,fixContent:(xe=m==null?void 0:m.tableData)==null?void 0:xe.map((Re,Ge)=>({id:Ge,...Re})),relatedContents:c==null?void 0:c.related}),(Ae=m.newRows)!=null&&Ae.length||qa.ElMessage.success("数据导入成功")}}catch(je){throw new Error(je)}finally{m.show=!1,m.columns=[],m.tableData=[],m.existRows=[]}},ee=()=>{f.show=!1},ke=u=>{var h,B;if((u==null?void 0:u.buttonName)==="取消")return f.show=!1;f.to=u==null?void 0:u.content,!(!(c!=null&&c.index)||!((h=f.to)!=null&&h.groupName))&&(c==null?void 0:c.index)!==((B=f.to)==null?void 0:B.groupName)&&(Me("change",{buttonName:"迁移",value:{from:f.from,to:f.to,data:f.selectRow}}),f.show=!1)},He=async u=>{var h,B,z,P;if(u){if(!Er.validateFileSize(u.raw)){qa.ElMessage.warning(`文件大小不能超过 ${mn.value.maxSize}MB`);const C=ka.value.findIndex(ie=>ie.uid===u.uid);C>-1&&ka.value.splice(C,1),Ce();return}if(!Er.validateFileType(u.raw)){qa.ElMessage.warning("请上传图片文件");const C=ka.value.findIndex(ie=>ie.uid===u.uid);C>-1&&ka.value.splice(C,1),Ce();return}rr(u,"uploading"),Al(u,0);try{const C=new FormData;C.append("file",u.raw,u.name);const ie=await A.platformUploadFile(C);u.uploadResult=((h=ie==null?void 0:ie.data)==null?void 0:h.result)||{name:u.name,url:"",fileName:u.name},Pl({name:((B=u.uploadResult)==null?void 0:B.name)||u.name,url:((z=u.uploadResult)==null?void 0:z.url)||"",id:(P=u.uploadResult)==null?void 0:P.id}),rr(u,"uploaded"),Al(u,100)}catch(C){console.error("文件上传失败:",C),qa.ElMessage.error(`文件 ${u.name} 上传失败,请重试`),rr(u,"pending"),Al(u,0);const ie=ka.value.findIndex(re=>re.uid===u.uid);ie>-1&&ka.value.splice(ie,1)}finally{Ce()}}},Ce=()=>{e.nextTick(()=>{const u=document.querySelector('.ocr-upload-input input[type="file"]');u&&(u.value="")})},aa=async()=>{var B,z;if(sessionStorage.setItem("ocr_root_table_id",String((c==null?void 0:c.index)??"")),ka.value.length===0){qa.ElMessage.warning("请先选择要上传的图片");return}if(ka.value.filter(P=>{const C=Cl(P);return C!=="uploaded"&&C!=="completed"&&C!=="failed"}).length>0){qa.ElMessage.warning("请等待所有文件上传完成后再开始识别");return}ma.value=!0,ha.value=0;let h=null;try{ka.value.forEach(Ye=>{rr(Ye,"processing")});const P=Math.floor(Math.random()*10)+90;h=setInterval(()=>{ha.value<P?ha.value+=1:clearInterval(h)},50);const C=ka.value.map(Ye=>{var Qa,ya,el;return{name:((Qa=Ye.uploadResult)==null?void 0:Qa.name)||Ye.name,url:((ya=Ye.uploadResult)==null?void 0:ya.url)||"",fileName:((el=Ye.uploadResult)==null?void 0:el.fileName)||Ye.name}}),ie=Er.extractTableHeaders(V.value),re=C.map(Ye=>({name:(Ye==null?void 0:Ye.fileName)||(Ye==null?void 0:Ye.name),url:(Ye==null?void 0:Ye.url)||""})),W=await Er.recognize(re,ie);if(console.log(W,"ocrResult"),clearInterval(h),h=null,(W==null?void 0:W.code)===500||(W==null?void 0:W.type)==="error"||!(W!=null&&W.result)){ha.value=0,ka.value.forEach(Ye=>{rr(Ye,"failed"),Al(Ye,0)}),qa.ElMessage.error((W==null?void 0:W.message)||"OCR识别失败,请重试"),ma.value=!1;return}ha.value=P;const xe=Array.isArray(W==null?void 0:W.result)?W.result:[];if(xe.length===0){ha.value=0,ka.value.forEach(Ye=>{rr(Ye,"failed"),Al(Ye,0)}),qa.ElMessage.warning("OCR识别未返回有效数据"),ma.value=!1;return}const Ae=new Set,je=[];xe.forEach((Ye,Qa)=>{const ya=Ye!=null&&Ye.数据&&typeof(Ye==null?void 0:Ye.数据)=="object"?Ye.数据:{},el=Array.isArray(Ye==null?void 0:Ye.图片信息)?Ye.图片信息:[],be=new Map;el.forEach(fa=>{fa!=null&&fa.name&&be.set(fa.name,fa.url||"")});const Ra={_index:Qa,_certType:(Ye==null?void 0:Ye.证书类型)||"",_certNo:(Ye==null?void 0:Ye.证书编号)||"",_ocrImages:el,__ocrFieldMeta:{}};Object.entries(ya).forEach(([fa,Ea])=>{let wa="",N=0,Y=[],$e="";Ea&&typeof Ea=="object"&&!Array.isArray(Ea)?(wa=(Ea==null?void 0:Ea.value)??"",N=(Ea==null?void 0:Ea.score)??0,Y=Array.isArray(Ea==null?void 0:Ea.bboxNorm)?Ea==null?void 0:Ea.bboxNorm:[],$e=(Ea==null?void 0:Ea.imageName)||""):Array.isArray(Ea)&&Ea.length>=2?(wa=Ea[0]??"",N=Ea[1]??0):(wa=Ea??"",N=0),Ra[fa]=wa,Ra[`${fa}_accuracy`]=N,Ae.add(fa),Ra.__ocrFieldMeta[fa]={value:wa,score:N,bboxNorm:Y,imageName:$e,imageUrl:$e&&be.get($e)||"",images:el}}),je.push(Ra)});const Re=[],Ge=new Set;je.forEach(Ye=>{Ye&&Ae.forEach(Qa=>{const ya=Ye[`${Qa}_accuracy`];(typeof ya=="number"?ya>0:ya!=null&&String(ya).trim()!==""&&String(ya)!=="0")&&Ge.add(Qa)})}),Ae.forEach(Ye=>{Re.push({prop:Ye,label:Ye,editable:!0,minWidth:230}),Ge.has(Ye)&&Re.push({prop:`${Ye}_accuracy`,label:"准确率",editable:!1,minWidth:100,isAccuracy:!0})}),ka.value.forEach(Ye=>{rr(Ye,"completed")}),ha.value=100,Ze.value=Re,Xe.value=je,Ve.value=C,Fa.value=W;const xa=["出厂编号","设备名称","制造厂"],Oa=Re.filter(Ye=>Ye&&!Ye.isAccuracy&&typeof Ye.prop=="string").map(Ye=>Ye.prop),za=["出厂编号","设备名称","制造厂"];Sa.value=Oa.filter(Ye=>za.includes(Ye)),console.log("[OCR] 默认勾选字段 props:",Sa.value),ia.value=2,ma.value=!1,va.value=!1}catch(P){console.error("OCR处理失败:",P),h&&(clearInterval(h),h=null),qa.ElMessage.error(((z=(B=P==null?void 0:P.response)==null?void 0:B.data)==null?void 0:z.message)||"OCR识别失败,请重试"),ma.value=!1,ha.value=0,ka.value.forEach(C=>{rr(C,"pending"),Al(C,0)})}},Ba=u=>{if(u==null)return"";let h=String(u);return h=h.replace(/\s+/g," ").trim(),h=h.replace(/[!-~]/g,B=>String.fromCharCode(B.charCodeAt(0)-65248)),h=h.replace(/ /g," "),h=h.replace(/^(编号|No\.?|NO\.?|no\.?|SN\.?|sn\.?|序列号)\s*[::]?\s*/i,""),h},Xa=()=>{var Ye,Qa;const u=Ve.value,h=Fa.value,B=Xe.value;if(!B||B.length===0){qa.ElMessage.warning("暂无数据可添加");return}const z=(Ye=he.getAllLeafNodes(V.value)||[])==null?void 0:Ye.filter(ya=>(ya==null?void 0:ya.type)!=="operate"&&(ya==null?void 0:ya.label)!=="操作"&&(ya==null?void 0:ya.prop)!=="operate"),P=new Map,C=new Map,ie=(Qa=z==null?void 0:z.find(ya=>(ya==null?void 0:ya.label)==="证书附件"))==null?void 0:Qa.prop;z==null||z.forEach(ya=>{ya!=null&&ya.label&&(ya!=null&&ya.prop)&&(P.set(ya.label,ya.prop),C.set(ya.prop,ya.label))});const re=Date.now(),W=ya=>String(re*1e3+ya),xe=[],Ae=[],je=ya=>{const el=Do&&Do[ya]||[ya];for(const be of el){const Ra=P.get(be);if(Ra)return Ra}return""},Re=je("出厂编号"),Ge=je("设备名称"),xa=je("制造厂"),Oa=[],za=ya=>{var wa,N;if(!ie)return[];const el=(Array.isArray(u)?u[ya]:null)||null,be=(el==null?void 0:el.url)||"",Ra=(el==null?void 0:el.fileName)||(el==null?void 0:el.name)||"";return(String(Ra).toLowerCase().endsWith(".pdf")||String(be).toLowerCase().endsWith(".pdf"))&&be?[{url:be,name:Ra,fileName:Ra}]:(Array.isArray((N=(wa=h==null?void 0:h.result)==null?void 0:wa[ya])==null?void 0:N.图片信息)?h.result[ya].图片信息:[]).map(Y=>({url:(Y==null?void 0:Y.url)||"",name:(Y==null?void 0:Y.name)||"",fileName:(Y==null?void 0:Y.name)||""})).filter(Y=>Y.url)};if(B.forEach((ya,el)=>{var nl;const be={id:W(el),_isOCRRow:!0,_ocrTableId:c==null?void 0:c.index};for(const[Wa,ul]of P.entries())Object.prototype.hasOwnProperty.call(ya,Wa)&&(be[ul]=ya[Wa]);ie&&(be[ie]=za(el));const Ra=(Array.isArray(h==null?void 0:h.result)?h.result[el]:null)||null,fa=(Array.isArray(u)?u[el]:null)||null,Ea=(fa==null?void 0:fa.url)||"",wa=(fa==null?void 0:fa.fileName)||(fa==null?void 0:fa.name)||"",N=String(wa).toLowerCase().endsWith(".pdf")||String(Ea).toLowerCase().endsWith(".pdf"),Y={ts:Date.now(),versionId:String(Date.now())+"_"+String(el),label:new Date().toLocaleString(),certType:(Ra==null?void 0:Ra.证书类型)||"",certNo:(Ra==null?void 0:Ra.证书编号)||"",fileType:N?"pdf":"image",sourceUrl:N?Ea:"",images:Array.isArray(Ra==null?void 0:Ra.图片信息)?Ra.图片信息.map(Wa=>({name:(Wa==null?void 0:Wa.name)||"",url:(Wa==null?void 0:Wa.url)||""})).filter(Wa=>Wa.url):[]},$e=Wa=>Ba(Wa?be==null?void 0:be[Wa]:""),na=$e(Re),_e=$e(Ge),sa=$e(xa);if(!!(Re&&Ge&&xa&&na&&_e&&sa)){const Wa=(Ne.value||[]).find(ul=>{const dl=Ba(Re?ul==null?void 0:ul[Re]:""),Fl=Ba(Ge?ul==null?void 0:ul[Ge]:""),Ua=Ba(xa?ul==null?void 0:ul[xa]:"");return dl&&Fl&&Ua&&dl===na&&Fl===_e&&Ua===sa});if(Wa){Oa.push({idx:el,ocrRow:be,versionItem:Y,ocrNo:na,candidates:[Wa],selectedTargetId:String((Wa==null?void 0:Wa.id)??""),__decision:"replace",allowAdd:!1,allowReplace:!0});return}}if(na&&Re){const Wa=(Ne.value||[]).filter(ul=>{const dl=Ba(Re?ul==null?void 0:ul[Re]:"");return dl&&dl===na});if(Wa.length>0){Oa.push({idx:el,ocrRow:be,versionItem:Y,ocrNo:na,candidates:Wa,selectedTargetId:"",__decision:"",allowAdd:!0,allowReplace:!0});return}}try{if(be.sort===void 0||be.sort===null||String(be.sort).trim()===""){const Wa=(Ne.value||[]).map(dl=>Jn(dl==null?void 0:dl.sort)).filter(dl=>dl!==null),ul=Wa.length>0?Math.max(...Wa):((nl=Ne.value)==null?void 0:nl.length)??0;be.sort=String(Number((ul+1).toFixed(6)))}}catch{}Ma(c==null?void 0:c.index,be.id,Y),Oa.push({idx:el,ocrRow:be,versionItem:Y,ocrNo:na,candidates:[],selectedTargetId:"",__decision:"add",allowAdd:!0,allowReplace:!1})}),(Oa||[]).length>0){Wl.value=(Oa||[]).map(ya=>({...ya,selectedTargetId:(ya==null?void 0:ya.selectedTargetId)||""})),ql.value=!0,Ql.value=Ae,pr.value=xe,Ll.value=h,fr.value=u,Vr.value=ie||"";return}},Ka=(u,h,B)=>{Xe.value[u]&&(Xe.value[u][h]=B)},al=u=>u==null||u===0?"-":`${(Number(u)*100).toFixed(1)}%`,bl=u=>{if(u==null||u===0)return"#909399";const h=Number(u);return h>=.9?"#67c23a":h>=.7?"#e6a23c":"#f56c6c"},vl=u=>{var B,z,P,C;if(il.value===u){il.value=null,ze.value=!1,Ia.value="";return}il.value=u,Ia.value="";const h=(B=Xe.value)==null?void 0:B[u];if(h&&Array.isArray(h._ocrImages)&&h._ocrImages.length>0){_l.value=h._ocrImages.map(W=>({name:(W==null?void 0:W.name)||"",url:(W==null?void 0:W.url)||""})).filter(W=>W.name||W.url);const ie=h.__ocrFieldMeta||{},re=(z=Object.values(ie))==null?void 0:z.find(W=>W==null?void 0:W.imageName);Ol.value=(re==null?void 0:re.imageName)||((C=(P=_l.value)==null?void 0:P[0])==null?void 0:C.name)||"",ze.value=_l.value.length>0}else _l.value=[],ze.value=!1,Ol.value=""},El=()=>{sl.value=!1,ka.value=[],La.value=null,ia.value=1,Ie.value.clear(),pe.value.clear(),ha.value=0,ze.value=!1},Hl=u=>u.raw?URL.createObjectURL(u.raw):u.url?u.url:"",Cl=u=>{const h=u.uid||u.name;return Ie.value.get(h)||"pending"},zl=u=>{const h=u.uid||u.name;return pe.value.get(h)||0},Al=(u,h)=>{const B=u.uid||u.name;pe.value.set(B,Math.min(100,Math.max(0,h)))},Hr=u=>{const h=Cl(u),B=100.53;if(h==="completed"||h==="uploaded")return`${B} ${B}`;if(h==="failed")return`${B} ${B}`;if(h==="uploading"){const z=zl(u);return`${B*(z/100)} ${B}`}else if(h==="processing")return`${B*.5} ${B}`;return`0 ${B}`},rr=(u,h)=>{const B=u.uid||u.name;Ie.value.set(B,h),(h==="completed"||h==="uploaded")&&Al(u,100)},Gr=()=>{e.nextTick(()=>{const u=document.querySelector('.ocr-upload-input input[type="file"]');if(u)u.value="",u.click();else{const h=document.createElement("input");h.type="file",h.multiple=!0,h.accept="image/*,application/pdf",h.style.display="none",h.onchange=async B=>{const z=Array.from(B.target.files||[]);for(const P of z){const C={name:P.name,raw:P,uid:Date.now()+Math.random()};ka.value.push(C),await He(C)}B.target.value="",document.body.removeChild(h)},document.body.appendChild(h),h.click()}})},on=()=>{ia.value>1&&ia.value--},xn=()=>{ia.value===1?ka.value.length>0&&!ma.value&&aa():ia.value===2&&(Xa(),ia.value=3)},fi=async u=>{await Tt(u==null?void 0:u.row)},Qn=async({row:u,prop:h})=>{!u||!h||await Tt(u,h)},Tt=async(u,h)=>{var P,C;const B=u==null?void 0:u.id;if(!B){qa.ElMessage.warning("暂无可预览数据");return}let z=Ml(c==null?void 0:c.index,B);if(!z||z.length===0){const ie=sessionStorage.getItem("ocr_root_table_id"),re=ie!==null?Number(ie):null;if(re!=null&&re!==""&&!Number.isNaN(re)){const W=Ml(re,B);Array.isArray(W)&&W.length>0&&($l(c==null?void 0:c.index,B,W),z=W)}}if(!z||z.length===0){const ie=(P=he.getAllLeafNodes(V.value)||[])==null?void 0:P.filter(W=>(W==null?void 0:W.type)!=="operate"&&(W==null?void 0:W.label)!=="操作"&&(W==null?void 0:W.prop)!=="operate"),re=h||((C=ie==null?void 0:ie.find(W=>(W==null?void 0:W.label)==="证书附件"))==null?void 0:C.prop);if(re&&u[re]){const W=u[re];let xe=[],Ae="",je=!1;if(typeof W=="string")try{const Re=JSON.parse(W);Array.isArray(Re)&&(xe=Re.map(Ge=>({name:(Ge==null?void 0:Ge.name)||(Ge==null?void 0:Ge.fileName)||"",url:(Ge==null?void 0:Ge.url)||""})).filter(Ge=>Ge.url||Ge.name),xe.length>0&&(Ae=xe[0].url||"",je=String(xe[0].name).toLowerCase().endsWith(".pdf")||String(Ae).toLowerCase().endsWith(".pdf")))}catch{Ae=W,je=String(W).toLowerCase().endsWith(".pdf"),xe=[{name:W,url:W}]}else Array.isArray(W)&&(xe=W.map(Re=>({name:(Re==null?void 0:Re.name)||(Re==null?void 0:Re.fileName)||"",url:(Re==null?void 0:Re.url)||""})).filter(Re=>Re.url||Re.name),xe.length>0&&(Ae=xe[0].url||"",je=String(xe[0].name).toLowerCase().endsWith(".pdf")||String(Ae).toLowerCase().endsWith(".pdf")));if(xe.length>0||Ae){const Re={ts:Date.now(),versionId:String(Date.now()),label:new Date().toLocaleString(),certType:u.证书类型||"",certNo:u.证书编号||"",fileType:je?"pdf":"image",sourceUrl:je?Ae:"",images:xe};z=[Re],Ma(c==null?void 0:c.index,B,Re)}}}if(!z||z.length===0){qa.ElMessage.warning("暂无可预览数据");return}we.value=z,$a.value=!0},iu=u=>{ka.value=ka.value.filter((h,B)=>B!==u)},lt=async(u,h,B)=>{var z,P,C,ie,re,W,xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa,ya,el,be,Ra,fa;if(pa(c.config,{type:ce.TABLE,tableOperate:u})){if(Ca.value="",Aa.value=!0,Qe.value=!0,Me("onButtonClick",u,h),J.value=[],u==="删除")A.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var Ea,wa,N,Y;(Ea=Ne.value)!=null&&Ea.find($e=>($e==null?void 0:$e.id)===(h==null?void 0:h.id))?Ne.value=(wa=A.cloneDeep(Ne.value))==null?void 0:wa.filter($e=>($e==null?void 0:$e.id)!==(h==null?void 0:h.id)):Ne.value=to(A.cloneDeep(Ne.value),h);try{h!=null&&h.id&&((Y=(N=Ta.value)==null?void 0:N.has)!=null&&Y.call(N,h==null?void 0:h.id))&&Ta.value.delete(h.id)}catch{}Af(ln.value,pn.value,h==null?void 0:h.id),oa.setTableLoading(c==null?void 0:c.index),Me("change",{content:Ne.value,fixContent:[h],index:c==null?void 0:c.index,type:"delete",name:c==null?void 0:c.groupNames,buttonName:u,columns:V.value,relatedContents:c==null?void 0:c.related}),console.log(h,"item")});else if(u==="批量删除"){if(((z=Gl.value)==null?void 0:z.length)===0)return qa.ElMessage.warning("请先勾选操作的数据");A.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(async()=>{var N,Y,$e,na,_e;const Ea=(N=Gl.value)==null?void 0:N.map(sa=>sa.id);Ne.value=(Y=A.cloneDeep(Ne.value))==null?void 0:Y.filter(sa=>!(Ea!=null&&Ea.includes(sa.id))),oa.setTableLoading(c==null?void 0:c.index),Me("change",{content:Ne.value,fixContent:Gl.value,index:c==null?void 0:c.index,type:"delete",name:c==null?void 0:c.compName,buttonName:u,relatedContents:c==null?void 0:c.related,columns:V.value});const wa=(Ea||[]).filter(Boolean);if(wa.length>0&&wa.every(sa=>sa!=null&&sa!=="")){const sa=(Gl.value||[]).map(Na=>{const nl={...Na};return delete nl._isOCRRow,delete nl._ocrTableId,delete nl._isTemp,delete nl.tableEditType,delete nl.index,nl});await A.pageBatchDeleteApi({platId:parseInt(($e=cl.value)==null?void 0:$e.plat_id),changeContents:[{tableName:((na=c==null?void 0:c.related)==null?void 0:na.find(Na=>Na==null?void 0:Na.includes("content_")))||((_e=c==null?void 0:c.related)==null?void 0:_e.find(Na=>Na==null?void 0:Na.includes("content"))),tableContents:sa}]})}})}else if(u==="复制新增"){X.value="复制新增",A.cloneDeep(h);const Ea=(P=V.value)==null?void 0:P.find(wa=>wa==null?void 0:wa.isMainKey);Ea||((C=V.value)==null||C[0]),ur.value=h,Vi(!0)}else if(u==="新增")X.value="新增",Ri(""),Z.value=!0;else if(u==="编辑")X.value="编辑",Ri(h),Z.value=!0;else if(u==="查看")X.value="查看",Ri(h),Aa.value=!1,Qe.value=!1,Z.value=!0;else if(u==="查看三维模型"){const Ea={};for(let N in h)N!=="id"&&(Ea[N]=h[N]);let wa=(ie=Object.values(Ea))==null?void 0:ie[1];Ue.setTableShowThree(wa)}else if(u==="切换视图")gu();else if(((re=B==null?void 0:B.extra)==null?void 0:re.type)==="modelExample")X.value=u,Je.value=!0;else if(u==="新建"){let Ea=ve.value,wa=[];for(let _e in Ea)_e!=null&&_e.includes(`loading${((W=cl.value)==null?void 0:W.account)||((xe=cl.value)==null?void 0:xe.账号)}`)&&(wa=[...wa,..._e]);let N=[];for(let _e in Ea)_e!=null&&_e.includes(`updateLoading${((Ae=cl.value)==null?void 0:Ae.account)||((je=cl.value)==null?void 0:je.账号)}`)&&(N=[...N,..._e]);let Y=wa==null?void 0:wa.map(_e=>_e==null?void 0:_e.id);const $e=N==null?void 0:N.map(_e=>_e==null?void 0:_e.id);Y=[...A.cloneDeep(Y),...$e],(Y==null?void 0:Y.length)>0&&(Y!=null&&Y.every(_e=>_e!==null&&_e))&&await Tr.batchDeleteInsofDataApi({ids:Y});const na=(Re=Za.value)==null?void 0:Re.find(_e=>(_e==null?void 0:_e.label)==="新建");await su(!1,na)}else if(u==="修改模板"){let Ea=A.cloneDeep(Ee).value;oa.setRouteToChildPath(Ea),te.setActiveMenuPath(Ea+w)}else if(u==="执行")at(u,h);else if(u==="导出paraform"){const Ea=A.ElLoading.service({lock:!0,text:"正在导出paraform...",background:"rgba(0, 0, 0, 0.7)"});try{const wa=["推力","真空","压力","温度","流量"],N=gl=>{var Tl,Xl,Nl;return gl?typeof(gl==null?void 0:gl.value)=="string"?gl.value:((Nl=(Xl=(Tl=gl==null?void 0:gl._custom)==null?void 0:Tl.value)==null?void 0:Xl.value)==null?void 0:Nl.value)||"":""},Y=Array.isArray(lr.value)?lr.value:[],$e=N(Y.find(gl=>(gl==null?void 0:gl.condition)==="child")),na=String($e||"").slice(0,8),_e=gl=>{if(gl==null)return"";const Tl=String(gl).trim();if(!Tl)return"";if(/^\d{8}$/.test(Tl))return Tl;const Xl=Tl.match(/^(\d{4})[-\/.](\d{1,2})[-\/.](\d{1,2})$/);if(Xl){const Yl=Xl[1],nr=Xl[2].padStart(2,"0"),Ul=Xl[3].padStart(2,"0");return`${Yl}${nr}${Ul}`}const Nl=Tl.replace(/\D/g,"");return Nl.length>=8?Nl.slice(0,8):""},sa=async gl=>{var Tl,Xl;if(!gl)return"";try{const Nl=await Kr("试验任务/任务管理",!1),Yl=(mr,sr=[])=>{if(!Array.isArray(mr))return sr;for(const dr of mr)(dr==null?void 0:dr.comp)==="Table"&&(dr!=null&&dr.name)&&sr.push(dr),Array.isArray(dr==null?void 0:dr.children)&&Yl(dr.children,sr),Array.isArray(dr==null?void 0:dr.tab)&&Yl(dr.tab,sr),Array.isArray(dr==null?void 0:dr.choice)&&Yl(dr.choice,sr);return sr},Ul=Yl(Nl||[]).find(mr=>(mr==null?void 0:mr.name)==="任务列表"),vr=((Xl=(Tl=Ul==null?void 0:Ul.compData)==null?void 0:Tl.find(mr=>(mr==null?void 0:mr.key)==="tableContents"))==null?void 0:Xl.contents)||[];if(!Array.isArray(vr)||vr.length===0)return"";const qr=vr.find(mr=>String((mr==null?void 0:mr["试验代号(名称)"])||"").slice(0,8)===gl);return _e(qr==null?void 0:qr.计划试验时间)}catch(Nl){return console.warn("获取任务列表计划试验时间失败:",Nl),""}},Na=(Ee.value||"").replace(/\/+$/,""),nl=$e?`${Na}/${$e}`:Na,Wa=await Kr(nl||Ee.value,!1),ul=String(ea.value||"").trim(),dl=gl=>String(gl||"").trim(),Fl=(gl,Tl=[],Xl="")=>{if(!Array.isArray(gl))return Tl;for(const Nl of gl){const Yl=dl((Nl==null?void 0:Nl.choiceName)||(Nl==null?void 0:Nl.name0)||Xl);(Nl==null?void 0:Nl.comp)==="Table"&&(Nl==null?void 0:Nl.name)&&wa.includes(Nl.name)&&(!ul||Yl===ul)&&Tl.push(Nl),Array.isArray(Nl==null?void 0:Nl.children)&&Fl(Nl.children,Tl,Yl),Array.isArray(Nl==null?void 0:Nl.tab)&&Fl(Nl.tab,Tl,Yl),Array.isArray(Nl==null?void 0:Nl.choice)&&Fl(Nl.choice,Tl,Yl)}return Tl},Ua=Fl(Wa||[]),ml=new Map;for(const gl of Ua)gl!=null&&gl.name&&!ml.has(gl.name)&&ml.set(gl.name,gl);const Pa=wa.map(gl=>ml.get(gl)).filter(Boolean);if(!Pa||Pa.length===0)return qa.ElMessage.warning("未找到需要导出的表(推力、真空、压力、温度、流量)");const ol=gl=>{const Tl=new Map,Xl=(Nl,Yl=[])=>{if(Array.isArray(Nl))for(const nr of Nl){const Ul=((nr==null?void 0:nr.label)??"").toString().trim(),vr=Ul?[...Yl,Ul]:[...Yl];if(Array.isArray(nr==null?void 0:nr.children)&&nr.children.length>0)Xl(nr.children,vr);else{const mr=((nr==null?void 0:nr.prop)??"").toString();if(!mr)continue;const sr=Ul||mr,dr=(vr.length>0?[...Yl,sr]:[sr]).join(".");Tl.set(mr,dr)}}};return Xl(gl,[]),Tl},Ga=(gl,Tl)=>{const Xl=ol(gl||[]),Yl=(he.getAllLeafNodes(gl||[])||[]).filter(Ul=>(Ul==null?void 0:Ul.prop)&&(Ul==null?void 0:Ul.type)!=="operate"&&(Ul==null?void 0:Ul.label)!=="操作"&&(Ul==null?void 0:Ul.prop)!=="operate"),nr=Array.isArray(Tl)?Tl:[];return nr.length===0?[]:nr.map(Ul=>{const vr={};return Yl.forEach(qr=>{const mr=String(qr.prop),sr=Xl.get(mr)||String(qr.label||qr.prop);vr[sr]=(Ul==null?void 0:Ul[mr])??""}),vr})},tl=Pa.map(gl=>{var nr,Ul;const Tl=(gl==null?void 0:gl.compData)||[];let Xl=(nr=Tl==null?void 0:Tl.find(vr=>(vr==null?void 0:vr.key)==="header"))==null?void 0:nr.contents;Array.isArray(Xl==null?void 0:Xl[0])&&(Xl=Xl[0]);const Nl=((Ul=Tl==null?void 0:Tl.find(vr=>(vr==null?void 0:vr.key)==="tableContents"))==null?void 0:Ul.contents)||[];if(!Array.isArray(Xl)||Xl.length===0||!Array.isArray(Nl)||Nl.length===0)return null;const Yl=Ga(Xl||[],Nl||[]);return!Array.isArray(Yl)||Yl.length===0?null:{类型:gl==null?void 0:gl.name,数据:Yl}}).filter(Boolean);if(!tl||tl.length===0)return qa.ElMessage.warning("没有可导出的数据(推力、真空、压力、温度、流量均为空)");const wl=await sa(na),Dl={试验代号:na,试验日期:wl,ParaForm:tl},xr=await di().catch(()=>""),Rl=await A.exportParaformApi(Dl,xr);if(((Ge=Rl==null?void 0:Rl.data)==null?void 0:Ge.code)===200&&((Oa=(xa=Rl==null?void 0:Rl.data)==null?void 0:xa.result)!=null&&Oa.Excel文件)){const gl=Rl.data.result.Excel文件,Tl=await A.platformDownloadFile({url:gl}),Xl=new Blob([Tl.data],{type:"application/vnd.ms-excel"}),Nl=URL.createObjectURL(Xl),Yl=A.dayjs().format("YYYYMMDD"),Ul=`${(na||"UNKNOWN").trim()||"UNKNOWN"}_${Yl}_paraform.xls`,vr=document.createElement("a");vr.href=Nl,vr.download=Ul,vr.style.display="none",document.body.appendChild(vr),vr.click(),setTimeout(()=>{document.body.removeChild(vr),URL.revokeObjectURL(Nl)},100);const qr=Array.isArray((Ye=(za=Rl==null?void 0:Rl.data)==null?void 0:za.result)==null?void 0:Ye.warnings)?Rl.data.result.warnings:[];if(qr.length>0){const mr=qr.map((sr,dr)=>`${dr+1}. ${(sr==null?void 0:sr.field)||"未知字段"}:${(sr==null?void 0:sr.message)||""}`).join(`
|
|
24
|
-
`);qa.ElMessage.warning({message:`导出成功,但存在以下提示:
|
|
25
|
-
${mr}`,duration:5e3,showClose:!0})}else qa.ElMessage.success("导出成功")}else qa.ElMessage.error(((Qa=Rl==null?void 0:Rl.data)==null?void 0:Qa.message)||"导出失败")}catch(wa){console.error("导出paraform失败:",wa),qa.ElMessage.error("导出失败:"+((wa==null?void 0:wa.message)||"未知错误"))}finally{Ea.close()}}else if(u!=null&&u.includes("导出")&&u!=="导出paraform"){if(u==="导出选中"&&((ya=Gl.value)==null?void 0:ya.length)===0)return qa.ElMessage.warning(`请先勾选${u}的数据`);if(u==="导出全部"&&((el=Ne.value)==null?void 0:el.length)===0)return qa.ElMessage.warning("暂无数据导出");let Ea=["序号",...(Ra=(be=V.value)==null?void 0:be.map($e=>$e==null?void 0:$e.prop))==null?void 0:Ra.filter($e=>$e!=="操作")],wa=u==="导出全部"?Ne.value:Gl.value;const N=["id","sort","tableEditType","create_time","update_time","source_table","create_user_id","update_user_id","department_id","relatedId"];wa=wa==null?void 0:wa.map($e=>Object.fromEntries(Object.entries($e).filter(([na])=>!N.includes(na)))),Ea=["序号",...Ea],wa=wa==null?void 0:wa.map(($e,na)=>({序号:na+1,...$e}));let Y=(c==null?void 0:c.compName)||"表格信息";Fo(wa,Y,Ea,Y)}else if(u==="OCR识别")sl.value=!0,ka.value=[],ia.value=1,Ie.value.clear(),pe.value.clear(),ha.value=0;else if(u==="迁移")f.selectRow=h,f.show=!0;else if(u==="生成方法"){let Ea=await Yf(h),wa;h!==""?wa=[h]:wa=A.cloneDeep(Ne.value),wa=wa==null?void 0:wa.map(Y=>(Y.输出值=Ea,Y));const N={fixContent:wa,buttonName:"编辑",relatedContents:c==null?void 0:c.related,columns:V.value,name:c==null?void 0:c.groupNames};Me("change",N)}else if(((fa=B==null?void 0:B.extra)==null?void 0:fa.type)==="methodButton"){let Ea;h!==""?Ea=[h]:Ea=A.cloneDeep(Ne.value);const N={fixContent:await vt(Ea,V==null?void 0:V.value,"Manual",Ne.value),buttonName:"methodButton",relatedContents:c==null?void 0:c.related,columns:V.value,name:c==null?void 0:c.groupNames};Me("change",N)}}},ou=async(u,h)=>{var B,z,P,C,ie,re,W,xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa,ya,el,be;try{let Ra,fa;const Ea=(B=ve.value[Ee.value+w])==null?void 0:B.filter(Na=>{var nl;return((nl=Na==null?void 0:Na.key)==null?void 0:nl.type)==="structureMethod"}),wa=(z=ve.value[Ee.value+w])==null?void 0:z.filter(Na=>{var nl;return((nl=Na==null?void 0:Na.key)==null?void 0:nl.type)==="structure"}),N=Ea==null?void 0:Ea.find(Na=>{var nl,Wa;return((Wa=(nl=Na==null?void 0:Na.value)==null?void 0:nl.pageData)==null?void 0:Wa.method)==="保存"});if(!N)return;const Y=(re=(ie=ve.value[(C=(P=N==null?void 0:N.value)==null?void 0:P.pageData)==null?void 0:C.path])==null?void 0:ie.filter(Na=>{var nl;return((nl=Na==null?void 0:Na.key)==null?void 0:nl.type)==="data"}))==null?void 0:re.find(Na=>{var nl,Wa,ul,dl;return((Wa=(nl=Na==null?void 0:Na.value)==null?void 0:nl.tableData)==null?void 0:Wa.算法名称)===((dl=(ul=N==null?void 0:N.value)==null?void 0:ul.pageData)==null?void 0:dl.method)});if(!Y)return;const $e={buttonName:(xe=(W=N==null?void 0:N.value)==null?void 0:W.pageData)==null?void 0:xe.method,api:(je=(Ae=Y==null?void 0:Y.value)==null?void 0:Ae.tableData)==null?void 0:je.算法体,content:wa==null?void 0:wa.map(Na=>{var nl;return(nl=Na==null?void 0:Na.value)==null?void 0:nl.pageData}),extraContent:[],extraValues:(Ge=(Re=N==null?void 0:N.value)==null?void 0:Re.pageData)==null?void 0:Ge.data,methodName:(Oa=(xa=N==null?void 0:N.value)==null?void 0:xa.pageData)==null?void 0:Oa.path};if(!u)return;const na={...u,compData:(za=u==null?void 0:u.compData)==null?void 0:za.map(Na=>{var nl;return(Na==null?void 0:Na.key)==="formContent"?{...Na,contents:(nl=Na==null?void 0:Na.contents)==null?void 0:nl.map(Wa=>(Wa==null?void 0:Wa.prop)===h?{...Wa,value:""}:Wa)}:Na})},_e={key:{pageKey:Ee.value+w,parentTable:"",systemKey:sessionStorage.getItem("systemKey"),type:"structure"},value:{pageData:na}},sa=await qa.axios.post($e.api,_e,{headers:{"Content-Type":"application/json"}});return((Ye=sa==null?void 0:sa.data)==null?void 0:Ye.code)===200&&(Ra=(ya=(Qa=sa==null?void 0:sa.data)==null?void 0:Qa.result)==null?void 0:ya.latestReportCode,fa=(be=(el=sa==null?void 0:sa.data)==null?void 0:el.result)==null?void 0:be.status),{newMainKeyValue:Ra,newStatus:fa}}catch(Ra){throw qa.ElMessage.error(Ra),new Error(Ra)}},At=e.reactive({prop:"状态",value:""});e.ref(["系统自动生成信息","审批意见"]);const tu=async(u,h,B)=>{var W,xe;let z=u==null?void 0:u[h==null?void 0:h.prop],P=1,C,ie;const re=A.cloneDeep(Ee).value+w+z;if(re){At.value="",C=(W=ve.value[re])==null?void 0:W.filter(Re=>{var Ge;return((Ge=Re==null?void 0:Re.key)==null?void 0:Ge.type)==="structure"});const Ae=C==null?void 0:C.find(Re=>{var Ge,xa,Oa;return((Oa=(xa=(Ge=Re==null?void 0:Re.value)==null?void 0:Ge.pageData)==null?void 0:xa.comp)==null?void 0:Oa.toUpperCase())==="FORM"});ie={...(xe=Ae==null?void 0:Ae.value)==null?void 0:xe.pageData,id:Ae==null?void 0:Ae.id};const je=await ou(ie,h==null?void 0:h.prop);if(At.value=je==null?void 0:je.newStatus,je!=null&&je.newMainKeyValue)return je==null?void 0:je.newMainKeyValue}if(Ne.value.some(Ae=>(Ae==null?void 0:Ae[h==null?void 0:h.prop])===z)){const Ae=z;for(;Ne.value.some(je=>(je==null?void 0:je[h==null?void 0:h.prop])===`${Ae}(${P})`);)P++;z=`${Ae}(${P})`}return z},su=async(u,h,B)=>{var C,ie,re,W;let z,P;if(await tu(B==null?void 0:B.data,B==null?void 0:B.firstCol),z=A.cloneDeep(Ee).value+w,P=A.cloneDeep(z)+`loading${((C=cl.value)==null?void 0:C.account)||((ie=cl.value)==null?void 0:ie.账号)}`,h){const xe=(W=(re=ve.value[P])==null?void 0:re.filter(Ae=>{var je;return((je=Ae==null?void 0:Ae.key)==null?void 0:je.parentTable)===""}))==null?void 0:W.map(Ae=>{var je;return{id:Ae==null?void 0:Ae.id,...(je=Ae==null?void 0:Ae.value)==null?void 0:je.pageData}});(xe==null?void 0:xe.length)>0||await he.loadingConstruct(z,P,null,null,null),oa.setRouteToChildPath(A.cloneDeep(Ee).value),te.setActiveMenuPath(P)}else oa.setRouteToChildPath(A.cloneDeep(Ee).value),te.setActiveMenuPath(P)},cu=()=>{Fe.value=!1,_a.value=[],ye.value=!1},Ri=u=>{var C,ie,re,W,xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa,ya,el,be,Ra,fa,Ea,wa;const h=[];De.value=A.cloneDeep(V.value),(ie=he.getColumnChild((C=A.cloneDeep(V.value))==null?void 0:C.filter(N=>(N==null?void 0:N.label)!=="操作")))==null||ie.forEach((N,Y)=>{var $e,na,_e;N!=null&&N.formType&&(($e=N==null?void 0:N.formType)==null?void 0:$e.toUpperCase())==="SELECT"||N!=null&&N.menuId?h.push({label:(na=N==null?void 0:N.prop)!=null&&na.includes(".")?N==null?void 0:N.prop:(N==null?void 0:N.label)??(N==null?void 0:N.prop)??"",name:(N==null?void 0:N.prop)??"t"+Y,prop:N==null?void 0:N.prop,type:"Select",value:(u==null?void 0:u[N==null?void 0:N.prop])??(N==null?void 0:N.value)??"",id:(N==null?void 0:N.id)??Y,contents:(N==null?void 0:N.options)??[],multiple:(N==null?void 0:N.multiple)??!1,multipleLimit:N==null?void 0:N.multipleLimit,width:1,isFormColHidden:N==null?void 0:N.isFormColHidden,relatedValueId:N==null?void 0:N.relatedValueId,disabled:N==null?void 0:N.disabled,menus:N==null?void 0:N.menus,groups:N==null?void 0:N.groups,words:N==null?void 0:N.words,allSelectionContents:(N==null?void 0:N.allSelectionContents)??[],filterContent:N==null?void 0:N.filterContent,disabled:(N==null?void 0:N.prop)==="disabled"?!0:N==null?void 0:N.disabled,filter:N==null?void 0:N.filter,bindMenus:N==null?void 0:N.bindMenus,isMainPath:N==null?void 0:N.isMainPath,required:(N==null?void 0:N.required)??!1,relatedContents:N==null?void 0:N.relatedContents,mainKey:N==null?void 0:N.mainKey,relatedContents:N==null?void 0:N.relatedContents,functionName:N==null?void 0:N.functionName,functionRelatedWords:N==null?void 0:N.functionRelatedWords,calculatorFilter:N==null?void 0:N.calculatorFilter}):h.push({label:(_e=N==null?void 0:N.prop)!=null&&_e.includes(".")?N==null?void 0:N.prop:(N==null?void 0:N.label)??(N==null?void 0:N.prop)??"",prop:N==null?void 0:N.prop,name:(N==null?void 0:N.prop)??"t"+Y,type:!(N!=null&&N.formType)||(N==null?void 0:N.formType)===""?"Input":N==null?void 0:N.formType,value:(N==null?void 0:N.formType)==="Upload"?(u==null?void 0:u[N==null?void 0:N.prop])??"{}":(u==null?void 0:u[N==null?void 0:N.prop])??(N==null?void 0:N.value)??"",id:(N==null?void 0:N.id)??Y,contents:(N==null?void 0:N.options)??[],multiple:(N==null?void 0:N.multiple)??!1,width:1,isFormColHidden:N==null?void 0:N.isFormColHidden,disabled:(N==null?void 0:N.prop)==="disabled"?!0:N==null?void 0:N.disabled,relatedValueId:N==null?void 0:N.relatedValueId,menus:N==null?void 0:N.menus,groups:N==null?void 0:N.groups,words:N==null?void 0:N.words,filter:N==null?void 0:N.filter,bindMenus:N==null?void 0:N.bindMenus,isMainPath:N==null?void 0:N.isMainPath,required:(N==null?void 0:N.required)??!1,relatedContents:N==null?void 0:N.relatedContents,mainKey:N==null?void 0:N.mainKey,relatedContents:N==null?void 0:N.relatedContents,functionName:N==null?void 0:N.functionName,functionRelatedWords:N==null?void 0:N.functionRelatedWords,calculatorFilter:N==null?void 0:N.calculatorFilter})}),u===""||!u||(Ca.value=(u==null?void 0:u.id)??"");let B=he.getColumnChild((re=A.cloneDeep(V.value))==null?void 0:re.filter(N=>(N==null?void 0:N.label)!=="操作"));ba.value&&((W=ba.value)==null?void 0:W.length)>0&&(ba.value=(xe=A.cloneDeep(ba).value)==null?void 0:xe.map(N=>{var $e;let Y=(N==null?void 0:N.prop)||(($e=B==null?void 0:B.find(na=>(na==null?void 0:na.label)===(N==null?void 0:N.label)))==null?void 0:$e.prop);return Y&&(N.value=u[Y]),N})),Ha.value=ba.value&&((Ae=ba.value)==null?void 0:Ae.length)>0?he.getTableFormToForm(ba.value):h,Ha.value=((je=Ha.value)==null?void 0:je.map(N=>({...N,disabled:(N==null?void 0:N.prop)==="disabled"?!0:N==null?void 0:N.disabled})))??Ha.value;let z=[],P=((xa=(Ge=(Re=c.itemData)==null?void 0:Re.filter(N=>(N==null?void 0:N.key)==="filter"))==null?void 0:Ge[0])==null?void 0:xa.contents)??"";if(P=he.analyzeSplitToContent(P,","),(P==null?void 0:P.length)>0&&(z=P.flat()),(z==null?void 0:z.length)>0){let N=z==null?void 0:z.filter(sa=>sa==null?void 0:sa.includes("@Type"));if(N=N==null?void 0:N[(N==null?void 0:N.length)-1],(N==null?void 0:N[(N==null?void 0:N.length)-1])===","&&(N=N==null?void 0:N.slice(0,(N==null?void 0:N.length)-1)),N){let sa=(za=(Oa=N==null?void 0:N.replace("=",k))==null?void 0:Oa.split(k))==null?void 0:za[1];((Ye=sa==null?void 0:sa.trim())==null?void 0:Ye.toUpperCase())==="MANUAL"&&(c==null||c.index,Ha.value=(Qa=Ha.value)==null?void 0:Qa.map((Na,nl)=>Na))}let Y=(ya=Ha.value)==null?void 0:ya.filter(sa=>sa==null?void 0:sa.mainKey),$e;Y==null||Y.forEach(sa=>{var nl;if($e!==void 0)return;let Na=sa==null?void 0:sa.menus;((nl=Y==null?void 0:Y.filter(Wa=>Wa==null?void 0:Wa.mainKey))==null?void 0:nl.length)>1&&($e=Na,sa==null||sa.groups)});let na=[],_e=new Map;if(Y==null||Y.forEach(sa=>{var Na,nl,Wa,ul,dl,Fl,Ua,ml,Pa,ol,Ga,tl,wl;if((Na=sa==null?void 0:sa.prop)!=null&&Na.includes(".")){let Dl=[];_e.get(((Wa=(nl=sa==null?void 0:sa.prop)==null?void 0:nl.split("."))==null?void 0:Wa[0])+(sa!=null&&sa.isMainPath?0:1)+((ul=sa==null?void 0:sa.groups)==null?void 0:ul[0]))&&(Dl=_e.get(((Fl=(dl=sa==null?void 0:sa.prop)==null?void 0:dl.split("."))==null?void 0:Fl[0])+(sa!=null&&sa.isMainPath?0:1)+((Ua=sa==null?void 0:sa.groups)==null?void 0:Ua[0]))),Dl.push(sa),_e.set(((Pa=(ml=sa==null?void 0:sa.prop)==null?void 0:ml.split("."))==null?void 0:Pa[0])+(sa!=null&&sa.isMainPath?0:1)+((ol=sa==null?void 0:sa.groups)==null?void 0:ol[0]),Dl)}else{let Dl=[];_e.get("normal"+(sa!=null&&sa.isMainPath?0:1)+((Ga=sa==null?void 0:sa.groups)==null?void 0:Ga[0]))&&(Dl=_e.get("normal"+(sa!=null&&sa.isMainPath?0:1)+((tl=sa==null?void 0:sa.groups)==null?void 0:tl[0]))),Dl.push(sa),_e.set("normal"+(sa!=null&&sa.isMainPath?0:1)+((wl=sa==null?void 0:sa.groups)==null?void 0:wl[0]),Dl)}}),na=Array.from(_e.values()),(na==null?void 0:na.length)>0)for(let sa in na){let Na=na==null?void 0:na[sa];if((Na==null?void 0:Na.length)!==1){if((Na==null?void 0:Na.length)>1){let nl=Na==null?void 0:Na.map(ol=>ol==null?void 0:ol.prop),Wa=Na==null?void 0:Na.map(ol=>ol==null?void 0:ol.label),ul=Na==null?void 0:Na.map(ol=>ol==null?void 0:ol.value),dl=(el=A.cloneDeep(Na))==null?void 0:el[0],Fl=(be=Ha.value)==null?void 0:be.findIndex(ol=>(ol==null?void 0:ol.prop)===(dl==null?void 0:dl.prop)),Ua=(Ra=Ha.value)==null?void 0:Ra.slice(0,Fl),ml=(Ea=Ha.value)==null?void 0:Ea.slice(Fl,(fa=Ha.value)==null?void 0:fa.length);dl.label=Wa==null?void 0:Wa.join("·"),dl.value=ul==null?void 0:ul.join(" "),dl.value.trim()===""&&(dl.value=""),dl.prop=nl==null?void 0:nl.join("·");let Pa=Na==null?void 0:Na.map(ol=>{var Ga;return(Ga=ol==null?void 0:ol.words)==null?void 0:Ga.join(".")});dl.relatedWords=Pa,dl.usingType="parent",ml.unshift(dl),Ha.value=[...Ua,...ml],Ha.value=(wa=Ha.value)==null?void 0:wa.map(ol=>(nl!=null&&nl.find(Ga=>Ga===(ol==null?void 0:ol.prop))&&(ol.isFormColHidden=!0,ol.relatedWords=Pa),ol))}}}}},uu=()=>{var h;const u=(h=t.value)==null?void 0:h.$el;u&&Bl.Sortable.create(u,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:B=>{var ie;const{oldIndex:z,newIndex:P}=B;if(z===P)return;const C=nn.value.splice(z,1)[0];nn.value.splice(P,0,C),V.value=(ie=V.value)==null?void 0:ie.slice().sort((re,W)=>{if(re.label==="操作")return 1;if(W.label==="操作")return-1;const xe=nn.value.findIndex(je=>je.label===re.label),Ae=nn.value.findIndex(je=>je.label===W.label);return xe-Ae})}})};e.onMounted(()=>{ra.value=window.innerWidth-240*2,window.addEventListener("keydown",Xi)});const du=()=>{e.nextTick(()=>{uu()})},pu=()=>{d.value=!0},rt=(u,h)=>{var z;if(!u&&!(u!=null&&u.children))return{contents:u,currentSelectContents:void 0};let B;return u.children=(z=u.children)==null?void 0:z.map(P=>{var C,ie;if((P==null?void 0:P.id)===Ca.value){let re={};for(let W in P){let xe=(C=h==null?void 0:h.find(Ae=>(Ae==null?void 0:Ae.prop)===W))==null?void 0:C.label;xe?re[W]=(ie=ur.value)==null?void 0:ie[xe]:re[W]=P[W]??""}P=Object.assign(re,ur.value),B=P}else{let re=rt(P,h);P=re==null?void 0:re.contents,B=re==null?void 0:re.currentSelectContents}return P}),{contents:u,currentSelectContents:B}},zt=(u,h)=>{let B,z;return u!=null&&u.find(P=>(P==null?void 0:P.id)===Ca.value)?B=u==null?void 0:u.map(P=>{var C,ie,re;if((P==null?void 0:P.id)===Ca.value){let W={};for(let Ae in P){let je=(C=h==null?void 0:h.find(Re=>(Re==null?void 0:Re.prop)===Ae))==null?void 0:C.label;je?W[Ae]=((ie=ur.value)==null?void 0:ie[je])??"":W[Ae]=P[Ae]??""}let xe=ur.value;for(let Ae in W)(re=ur.value)!=null&&re[Ae]||(xe[Ae]=(W==null?void 0:W[Ae])??"");P=xe,z=P}return P}):B=u==null?void 0:u.map(P=>{var C,ie,re,W;if((P==null?void 0:P.id)===Ca.value){let xe={};for(let Ae in P){let je=(C=h==null?void 0:h.find(Re=>(Re==null?void 0:Re.prop)===Ae))==null?void 0:C.label;je?xe[Ae]=(ie=ur.value)==null?void 0:ie[je]:xe[Ae]=P[Ae]??""}P=Object.assign(xe,ur.value),z=P}else P=(re=rt(P,h))==null?void 0:re.contents,z=(W=rt(P,h))==null?void 0:W.currentSelectContents;return P}),{newContents:B,currentSelectContents:z}},Mt=(u,h,B)=>{var z,P;return u[h==null?void 0:h.prop]=B,typeof u.id=="number"&&(u.id=(z=u.id)==null?void 0:z.toString()),u.children&&((P=u.children)==null?void 0:P.length)>0&&(u.children=u.children.map(Mt)),u},It=u=>{var B;const h=[];return h.push({...u}),u!=null&&u.children&&Array.isArray(u.children)&&((B=u.children)==null||B.forEach(z=>{h.push(...It(z))})),(h==null?void 0:h.length)>0?h==null?void 0:h.map(z=>{const P={...z};return delete P.children,P}):[]},so=["Pacific6000数据采集装置.通道号","通道号"],$i=u=>{if(!u)return"";const h=so.map(B=>u==null?void 0:u[B]).find(B=>B!=null&&String(B).trim()!=="");return h==null?"":String(h).trim()},nt=async(u,h=void 0)=>{if(!u)return!1;try{const B=Ge=>{var xa,Oa,za;return Ge?typeof(Ge==null?void 0:Ge.value)=="string"?Ge.value:((za=(Oa=(xa=Ge==null?void 0:Ge._custom)==null?void 0:xa.value)==null?void 0:Oa.value)==null?void 0:za.value)||"":""},z=Array.isArray(lr.value)?lr.value:[],P=B(z.find(Ge=>(Ge==null?void 0:Ge.condition)==="child")),C=(Ee.value||"").replace(/\/+$/,""),ie=P?`${C}/${P}`:C,re=await Kr(ie||Ee.value,!1),W=String(ea.value||"").trim(),xe=Ge=>String(Ge||"").trim(),Ae=(Ge,xa=[],Oa="")=>{if(!Array.isArray(Ge))return xa;for(const za of Ge){const Ye=xe((za==null?void 0:za.choiceName)||(za==null?void 0:za.name0)||Oa);(za==null?void 0:za.comp)==="Table"&&(!W||Ye===W)&&xa.push(za),Array.isArray(za==null?void 0:za.children)&&Ae(za.children,xa,Ye),Array.isArray(za==null?void 0:za.tab)&&Ae(za.tab,xa,Ye),Array.isArray(za==null?void 0:za.choice)&&Ae(za.choice,xa,Ye)}return xa},je=Ae(re||[]),Re=String((c==null?void 0:c.compName)||"");return je.some(Ge=>{var Oa,za;const xa=((za=(Oa=Ge==null?void 0:Ge.compData)==null?void 0:Oa.find(Ye=>(Ye==null?void 0:Ye.key)==="tableContents"))==null?void 0:za.contents)||[];return!Array.isArray(xa)||xa.length===0?!1:xa.some(Ye=>{if(String((Ge==null?void 0:Ge.name)||"")===Re&&(Ye==null?void 0:Ye.id)===h)return!1;const ya=$i(Ye);return!!ya&&ya===u})})}catch{return(Ne.value||[]).some(z=>{if((z==null?void 0:z.id)===h)return!1;const P=$i(z);return!!P&&P===u})}},Vi=async(u=!0,h,B)=>{var xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa,ya,el,be,Ra,fa,Ea,wa,N,Y,$e,na,_e,sa,Na,nl,Wa,ul,dl,Fl,Ua,ml;if(ur.value){const Pa=(Ae=he.getColumnChild((xe=A.cloneDeep(V.value))==null?void 0:xe.filter(Ga=>(Ga==null?void 0:Ga.label)!=="操作")))==null?void 0:Ae.filter(Ga=>(Ga==null?void 0:Ga.required)===!0);for(let Ga=0;Ga<((Pa==null?void 0:Pa.length)??0);Ga++){const tl=Pa[Ga],wl=tl==null?void 0:tl.prop,Dl=(tl==null?void 0:tl.label)??wl,xr=(je=ur.value)==null?void 0:je[wl];if(xr===""||xr===null||xr===void 0||Array.isArray(xr)&&xr.length===0){qa.ElMessage.error(`${Dl}不能为空`);return}}const ol=$i(ur.value);if(ol&&await nt(ol,Ca.value||void 0)){qa.ElMessage.warning("当前任务下通道号不能重复,请重新选择");return}}let z=he.getColumnChild((Re=A.cloneDeep(V.value))==null?void 0:Re.filter(Pa=>(Pa==null?void 0:Pa.label)!=="操作")),P,C=A.cloneDeep(Ne.value);if(!ur.value){Z.value=!1;return}if(Ca.value===""){Va.value++;let Pa;Pa={id:Va.value.toString()};try{Pa.sort=Xn(0,Ne.value||[])}catch{}Pa!=null&&Pa.children&&(Pa={...Pa,children:(Ge=Pa.children)==null?void 0:Ge.map(Ga=>Mt(Ga,h,B))});const ol=Object.assign(ur.value,Pa);C.unshift(ol),P=ol}else C=(xa=zt(C,z))==null?void 0:xa.newContents,P=(Oa=zt(C,z))==null?void 0:Oa.currentSelectContents;const ie=(za=c.itemData)==null?void 0:za.filter(Pa=>(Pa==null?void 0:Pa.key)==="childTree")[0];if(((Ye=ie==null?void 0:ie.contents)==null?void 0:Ye.length)>0){X.value="编辑";const Pa=[];C==null||C.forEach((tl,wl)=>{var xr;let Dl={};if(Array.isArray(tl)){let Rl=[];tl==null||tl.filter(gl=>!(gl!=null&&gl.id)).forEach((gl,Tl)=>{var Xl,Nl,Yl,nr,Ul,vr,qr;if((Nl=(Xl=Dr.value)==null?void 0:Xl[Tl])!=null&&Nl.prop&&!Array.isArray(gl)){let mr={};mr[Dr.value[Tl].column]=gl,L!=null&&L.value&&((Yl=L==null?void 0:L.value)==null?void 0:Yl.length)>0&&((nr=L==null?void 0:L.value)!=null&&nr.find(sr=>JSON.stringify(sr==null?void 0:sr[0])===JSON.stringify(mr)))&&(Rl=(Ul=L==null?void 0:L.value)==null?void 0:Ul.find(sr=>JSON.stringify(sr==null?void 0:sr[0])===JSON.stringify(mr))),Rl&&Rl.length>0?Dl[Dr.value[Tl].prop]=Rl!=null&&Rl.find(sr=>{var dr;return((dr=Object.keys(sr))==null?void 0:dr[0])===Dr.value[Tl].column})?(vr=Rl==null?void 0:Rl.find(sr=>{var dr;return((dr=Object.keys(sr))==null?void 0:dr[0])===Dr.value[Tl].column}))==null?void 0:vr[Dr.value[Tl].column]:gl:Dl[Dr.value[Tl].prop]=gl}else Array.isArray(gl)&&((qr=Dr.value[Tl])!=null&&qr.prop?Dl[Dr.value[Tl].prop]=gl:Dl.children=mt(gl,Dr.value))})}else Dl=tl;if(Array.isArray(tl)&&tl.some(Rl=>Rl==null?void 0:Rl.id)){const Rl=(xr=tl==null?void 0:tl.find(gl=>gl.id))==null?void 0:xr.id;Pa.push(Object.assign(Dl,{id:io(Rl)}))}else Dl.id?Pa.push(Dl):Pa.push(Object.assign(Dl,{id:wl.toString()}))});const ol=(Ne.value||[]).map(tl=>String(tl==null?void 0:tl.id)),Ga=ci(Pa,ol);Ne.value=$t(Ga,ie,V.value)}Lt(Ne.value),ln.value=Ne.value;const re=Mf(ln.value,pn.value,C);let W=[];if(H.value?(W=(Qa=A.cloneDeep(H).value.singleContent)==null?void 0:Qa.filter(Pa=>(Pa==null?void 0:Pa.id)!==(P==null?void 0:P.id)),W.push(P)):W=[P],Vl.value){const Pa={content:re,singleContent:((ya=ie==null?void 0:ie.contents)==null?void 0:ya.length)>0?W==null?void 0:W.flatMap(It):W,index:c==null?void 0:c.index,buttonName:"编辑",column:V.value,parentTableId:c==null?void 0:c.parentTableId};oa.setCacheUpdatingData(Pa)}if((el=V.value)==null||el.forEach(Pa=>{(Pa==null?void 0:Pa.formType)==="Upload"&&(P[Pa.prop]=P[Pa.prop]===""?"{}":typeof P[Pa.prop]!="string"?JSON.stringify(P[Pa.prop]):P[Pa.prop])}),u){(Ea=(fa=(Ra=(be=c.itemData)==null?void 0:be.find(Ga=>(Ga==null?void 0:Ga.key)==="filterAllType"))==null?void 0:Ra.value)==null?void 0:fa.find(Ga=>(Ga==null?void 0:Ga.value)==="onConditionContents"))==null||Ea.content;let Pa=(wa=c.itemData)==null?void 0:wa.filter(Ga=>(Ga==null?void 0:Ga.key)==="filterAllType");Pa=Array.from(new Map(Pa.filter(Boolean).map((Ga,tl)=>[Ga.value,{...Ga,_idx:tl}])).values()).sort((Ga,tl)=>Ga._idx-tl._idx).map(({_idx:Ga,...tl})=>tl),Pa=(N=Pa==null?void 0:Pa[(Pa==null?void 0:Pa.length)-1])==null?void 0:N.value;const ol={fixContent:[P],buttonName:X.value,relatedContents:c==null?void 0:c.related,columns:V.value,name:c==null?void 0:c.groupNames};oa.setTableLoading(c==null?void 0:c.index),Z.value=!1,ur.value=void 0,Me("change",ol)}if((na=($e=(Y=Ha.value)==null?void 0:Y[0])==null?void 0:$e.optionUrl)!=null&&na.menuId){Z.value=!1;let Pa=(_e=c.itemData)==null?void 0:_e.filter(ol=>(ol==null?void 0:ol.key)==="filterAllType");if((Pa==null?void 0:Pa.length)>0){let ol=Pa==null?void 0:Pa.map(wl=>wl==null?void 0:wl.value),Ga=(nl=(Na=(sa=ol.flat().find(wl=>{var Dl;return(Dl=wl==null?void 0:wl.content)==null?void 0:Dl.includes("@Num")}))==null?void 0:sa.content)==null?void 0:Na.split(":"))==null?void 0:nl[1];((dl=(ul=(Wa=ol.flat().find(wl=>{var Dl;return(Dl=wl==null?void 0:wl.content)==null?void 0:Dl.includes("@Type:")}))==null?void 0:Wa.content)==null?void 0:ul.split(":"))==null?void 0:dl[1])!=="Manual"&&(Ga=parseInt(Ga),Ne.value=(ml=Ne.value)==null?void 0:ml.slice(((Fl=Ne.value)==null?void 0:Fl.length)-Ga,(Ua=Ne.value)==null?void 0:Ua.length))}}};e.onUnmounted(()=>{window.removeEventListener("keydown",Xi),V.value=[],Ne.value=[],De.value=[],Da.value=[],ba.value=[],ga.value=[],_a.value=[],Oe.value=[],Ha.value=[],Gl.value=[],t.value=null,Ln.value=""});const co=async(u,h,B)=>{var Ge,xa,Oa,za,Ye,Qa,ya,el,be,Ra,fa,Ea,wa;hr.value=(B==null?void 0:B.prop)??(B==null?void 0:B.property);const z=A.cloneDeep(c.itemData),P=((Ge=z==null?void 0:z.find(N=>(N==null?void 0:N.key)==="header"))==null?void 0:Ge.contents)??[];let C=P==null?void 0:P.find((N,Y)=>{var $e,na,_e;return(N==null?void 0:N.prop)===hr.value||(N==null?void 0:N.label)===hr.value||(Y==null?void 0:Y.toString())===((_e=(na=($e=hr.value)==null?void 0:$e.split("a"))==null?void 0:na[1])==null?void 0:_e.toString())});const ie=he.getColumnChild((xa=A.cloneDeep(V.value))==null?void 0:xa.filter(N=>(N==null?void 0:N.label)!=="操作"));if(C||(C=ie==null?void 0:ie.find(N=>(N==null?void 0:N.prop)===hr.value||(N==null?void 0:N.label)===hr.value)),C&&!((Oa=C==null?void 0:C.menus)!=null&&Oa.length)&&!((za=C==null?void 0:C.groups)!=null&&za.length)&&!((Ye=C==null?void 0:C.words)!=null&&Ye.length)){const N=(Qa=Ha.value)==null?void 0:Qa.find(Y=>(Y==null?void 0:Y.prop)===hr.value);N&&(C={...C,menus:(N==null?void 0:N.menus)??(C==null?void 0:C.menus),groups:(N==null?void 0:N.groups)??(C==null?void 0:C.groups),words:(N==null?void 0:N.words)??(C==null?void 0:C.words),bindMenus:(N==null?void 0:N.bindMenus)??(C==null?void 0:C.bindMenus),isMainPath:(N==null?void 0:N.isMainPath)??(C==null?void 0:C.isMainPath),relatedContents:(N==null?void 0:N.relatedContents)??(C==null?void 0:C.relatedContents),endChildMenu:(N==null?void 0:N.endChildMenu)??(C==null?void 0:C.endChildMenu)})}if(C&&((ya=Ha==null?void 0:Ha.value)==null||ya.forEach(N=>{var Y,$e,na,_e,sa;(N==null?void 0:N.prop)===(C==null?void 0:C.prop)&&(N!=null&&N.endChildMenu)&&((Y=C==null?void 0:C.prop)!=null&&Y.includes(".")&&((na=($e=C==null?void 0:C.prop)==null?void 0:$e.split("."))==null?void 0:na[0])!==((sa=(_e=N==null?void 0:N.prop)==null?void 0:_e.split("."))==null?void 0:sa[0])?C.endChildMenu=N==null?void 0:N.value:C.endChildMenu=N==null?void 0:N.endChildMenu)})),!C)return;const re=hr.value,W=(el=Ne.value)==null?void 0:el.findIndex(N=>(N==null?void 0:N.id)===(h==null?void 0:h.id));W!==-1&&re&&(Ne.value[W]={...Ne.value[W],[re]:u});const xe=N=>{Array.isArray(N)&&N.forEach(Y=>{Array.isArray(Y==null?void 0:Y.allSelectionContents)&&Y.allSelectionContents.length>0&&(Y.contactValue=Ne.value[W]??h),Array.isArray(Y==null?void 0:Y.children)&&Y.children.length>0&&xe(Y.children)})};xe(V.value),C.value=u,C.endChildMenu=C.endChildMenu||"";let Ae=C!=null&&C.isMainPath&&(C!=null&&C.mainKey)?C==null?void 0:C.value:"";const je=N=>{Array.isArray(N)&&N.forEach(Y=>{var na,_e;if(((Y==null?void 0:Y.type)==="Select"||(Y==null?void 0:Y.formType)&&Y.formType.toUpperCase()==="SELECT"||(Y==null?void 0:Y.columnType)&&Y.columnType.toUpperCase()==="SELECT")&&Array.isArray(Y==null?void 0:Y.menus)&&Y.menus.length>0&&Y.menus[Y.menus.length-1]===""&&(C!=null&&C.isMainPath)&&(C!=null&&C.mainKey)){const sa=(na=Y==null?void 0:Y.prop)!=null&&na.includes(".")?Y.prop.split(".")[0]:null,Na=(_e=C==null?void 0:C.prop)!=null&&_e.includes(".")?C.prop.split(".")[0]:null;(!sa||!Na||sa===Na)&&(Y.endChildMenu=Ae)}Array.isArray(Y==null?void 0:Y.children)&&Y.children.length>0&&je(Y.children)})};if(je(V.value),!!(C!=null&&C.mainKey)&&Array.isArray(C==null?void 0:C.menus)&&(C==null?void 0:C.menus.length)>0&&(C!=null&&C.value)&&(C==null?void 0:C.value)!==""){let N=C!=null&&C.relatedContents&&((be=C==null?void 0:C.relatedContents)==null?void 0:be.length)>0?(Ra=C==null?void 0:C.relatedContents)==null?void 0:Ra.find(Y=>{var $e,na,_e,sa;return(Y==null?void 0:Y[(sa=($e=C==null?void 0:C.prop)==null?void 0:$e.split("."))==null?void 0:sa[((_e=(na=C==null?void 0:C.prop)==null?void 0:na.split("."))==null?void 0:_e.length)-1]])===(C==null?void 0:C.value)}):await cs(C);if(N){const Y={...h};ie==null||ie.forEach($e=>{var na,_e,sa,Na,nl,Wa,ul,dl,Fl,Ua,ml,Pa,ol,Ga,tl,wl;($e==null?void 0:$e.prop)!==(C==null?void 0:C.prop)&&(C!=null&&C.relatedContents&&((na=C==null?void 0:C.relatedContents)==null?void 0:na.length)>0?(_e=$e==null?void 0:$e.prop)!=null&&_e.includes(".")&&((Na=(sa=$e==null?void 0:$e.prop)==null?void 0:sa.split("."))==null?void 0:Na[0])===((Wa=(nl=C==null?void 0:C.prop)==null?void 0:nl.split("."))==null?void 0:Wa[0])?Y[$e.prop]=N[(Ua=(ul=$e==null?void 0:$e.prop)==null?void 0:ul.split("."))==null?void 0:Ua[((Fl=(dl=$e==null?void 0:$e.prop)==null?void 0:dl.split("."))==null?void 0:Fl.length)-1]]??Y[$e.prop]:Y[$e.prop]=(N==null?void 0:N[$e.prop])??Y[$e.prop]:he.same((C==null?void 0:C.menus)??[],($e==null?void 0:$e.menus)??[])&&he.same((C==null?void 0:C.groups)??[],($e==null?void 0:$e.groups)??[])&&!he.same((C==null?void 0:C.words)??[],($e==null?void 0:$e.words)??[])?(ml=$e==null?void 0:$e.prop)!=null&&ml.includes(".")&&((ol=(Pa=$e==null?void 0:$e.prop)==null?void 0:Pa.split("."))==null?void 0:ol[0])!==((tl=(Ga=C==null?void 0:C.prop)==null?void 0:Ga.split("."))==null?void 0:tl[0])||(Y[$e.prop]=(N==null?void 0:N[(wl=$e==null?void 0:$e.words)==null?void 0:wl.join(".")])??(N==null?void 0:N[$e.prop])??Y[$e.prop]):(!($e!=null&&$e.isMainPath)&&he.same((C==null?void 0:C.bindMenus)??[],($e==null?void 0:$e.bindMenus)??[]),Y[$e.prop]=(N==null?void 0:N[$e.prop])??Y[$e.prop]))}),Ne.value=(fa=A.cloneDeep(Ne.value))==null?void 0:fa.map($e=>($e==null?void 0:$e.id)===(h==null?void 0:h.id)?{...Y,id:$e==null?void 0:$e.id}:$e)}}if((Ea=C==null?void 0:C.optionUrl)!=null&&Ea.menuSelect){let N="";ie==null||ie.forEach(na=>{var _e,sa,Na,nl,Wa;N===""&&((Na=(sa=(_e=na==null?void 0:na.optionUrl)==null?void 0:_e.groupSelect)==null?void 0:sa[1])!=null&&Na.includes("["))&&(N=(Wa=(nl=na==null?void 0:na.optionUrl)==null?void 0:nl.groupSelect)==null?void 0:Wa[1])});let Y=await yt(C),$e;if(Y==null||Y.forEach(na=>{var _e,sa,Na,nl,Wa,ul,dl,Fl,Ua,ml;N===((sa=(_e=C==null?void 0:C.optionUrl)==null?void 0:_e.groupSelect)==null?void 0:sa[1])&&((Wa=(nl=(Na=C==null?void 0:C.optionUrl)==null?void 0:Na.groupSelect)==null?void 0:nl[1])!=null&&Wa.includes("["))&&((ml=A.cloneDeep(na))==null?void 0:ml[(Ua=(Fl=(dl=(ul=C==null?void 0:C.optionUrl)==null?void 0:ul.groupSelect)==null?void 0:dl[1])==null?void 0:Fl.replaceAll("[",""))==null?void 0:Ua.replaceAll("]","")])===(C==null?void 0:C.value)&&($e=na)}),$e){const na={...h};ie==null||ie.forEach(_e=>{var sa,Na,nl,Wa,ul,dl,Fl,Ua,ml,Pa,ol;($e!=null&&$e[_e==null?void 0:_e.label]||$e!=null&&$e[(Wa=(nl=(Na=(sa=_e==null?void 0:_e.optionUrl)==null?void 0:sa.groupSelect)==null?void 0:Na[1])==null?void 0:nl.replaceAll("[",""))==null?void 0:Wa.replaceAll("]","")])&&((Fl=(dl=(ul=_e==null?void 0:_e.optionUrl)==null?void 0:ul.groupSelect)==null?void 0:dl[1])!=null&&Fl.includes("["))&&(na[_e.prop]=($e==null?void 0:$e[_e==null?void 0:_e.label])||($e==null?void 0:$e[(ol=(Pa=(ml=(Ua=_e==null?void 0:_e.optionUrl)==null?void 0:Ua.groupSelect)==null?void 0:ml[1])==null?void 0:Pa.replaceAll("[",""))==null?void 0:ol.replaceAll("]","")]))}),Ne.value=(wa=A.cloneDeep(Ne.value))==null?void 0:wa.map(_e=>(_e==null?void 0:_e.id)===(h==null?void 0:h.id)?{...na,id:_e==null?void 0:_e.id}:_e)}}},fu=async u=>{var Ge,xa,Oa,za,Ye,Qa,ya,el,be,Ra,fa,Ea,wa,N;if(!u)return;const h=A.cloneDeep(ur.value||{});ur.value=u;const B=$i(h),z=$i(ur.value);if(z&&z!==B&&await nt(z,Ca.value||void 0)){qa.ElMessage.warning("当前任务下通道号不能重复,请重新选择"),so.forEach($e=>{if(Object.prototype.hasOwnProperty.call(ur.value||{},$e)||Object.prototype.hasOwnProperty.call(h||{},$e)){const na=(h==null?void 0:h[$e])??"";ur.value[$e]=na,u[$e]=na}}),Ha.value=(Ha.value||[]).map($e=>{if(!($e!=null&&$e.prop)||!so.includes($e.prop))return $e;const na=(h==null?void 0:h[$e.prop])??"";return{...$e,value:na,selectValue:na===""?[]:[na]}});return}let P=A.cloneDeep(c.itemData);P==null||P.map(Y=>{var $e,na,_e,sa;return(Y==null?void 0:Y.key)==="header"&&(Array.isArray(($e=Y.contents)==null?void 0:$e[0])?Y.contents=(_e=he.getColumnChild((na=Y.contents)==null?void 0:na[0]))==null?void 0:_e.map((Na,nl)=>{var Wa,ul,dl,Fl,Ua,ml;return((dl=(ul=(Wa=Ha.value)==null?void 0:Wa.find(Pa=>(Pa==null?void 0:Pa.prop)===(Na==null?void 0:Na.prop)))==null?void 0:ul.optionUrl)==null?void 0:dl.multiple)===!0&&!Array.isArray((Fl=Object.values(u))==null?void 0:Fl[nl])?Na.value=[(Ua=Object.values(u))==null?void 0:Ua[nl]]:Na.value=(ml=Object.values(u))==null?void 0:ml[nl],Na}):Y.contents=(sa=Y.contents)==null?void 0:sa.map((Na,nl)=>{var Wa,ul,dl,Fl,Ua,ml;return((dl=(ul=(Wa=Ha.value)==null?void 0:Wa.find(Pa=>(Pa==null?void 0:Pa.prop)===(Na==null?void 0:Na.prop)))==null?void 0:ul.optionUrl)==null?void 0:dl.multiple)===!0&&!Array.isArray((Fl=Object.values(u))==null?void 0:Fl[nl])?Na.value=[(Ua=Object.values(u))==null?void 0:Ua[nl]]:Na.value=(ml=Object.values(u))==null?void 0:ml[nl],Na})),Y});let C=Ha.value,ie=(Ge=P==null?void 0:P.find(Y=>(Y==null?void 0:Y.key)==="header"))==null?void 0:Ge.contents;if(hr.value||(C=C==null?void 0:C.map(Y=>{var $e;return Y.value=Y.value??(($e=ie==null?void 0:ie.find((na,_e)=>(na==null?void 0:na.prop)===(Y==null?void 0:Y.name)))==null?void 0:$e.value),Y})),!Or.value)return;let re=A.cloneDeep(hr.value);(xa=hr.value)!=null&&xa.includes("·")&&(hr.value=(za=(Oa=hr.value)==null?void 0:Oa.split("·"))==null?void 0:za[0]);let W=(Qa=(Ye=P==null?void 0:P.find(Y=>(Y==null?void 0:Y.key)==="header"))==null?void 0:Ye.contents)==null?void 0:Qa.find((Y,$e)=>(Y==null?void 0:Y.prop)===hr.value);(ya=Ha==null?void 0:Ha.value)==null||ya.forEach(Y=>{var $e,na,_e,sa,Na,nl,Wa,ul,dl;(Y==null?void 0:Y.prop)===(W==null?void 0:W.prop)&&(Y!=null&&Y.endChildMenu)&&(($e=W==null?void 0:W.prop)!=null&&$e.includes(".")&&((_e=(na=W==null?void 0:W.prop)==null?void 0:na.split("."))==null?void 0:_e[0])!==((Na=(sa=Y==null?void 0:Y.prop)==null?void 0:sa.split("."))==null?void 0:Na[0])?W.endChildMenu=(Wa=(nl=Y==null?void 0:Y.value)==null?void 0:nl.split(" "))==null?void 0:Wa[0]:W.endChildMenu=(dl=(ul=Y==null?void 0:Y.endChildMenu)==null?void 0:ul.split(" "))==null?void 0:dl[0])});let xe=W!=null&&W.isMainPath&&(W!=null&&W.mainKey)?W==null?void 0:W.value:"",Ae=C,je=ae.value;if(je!=null&&je.find(Y=>(W==null?void 0:W.prop)===(Y==null?void 0:Y.key))&&(je=je==null?void 0:je.filter(Y=>(W==null?void 0:W.prop)!==(Y==null?void 0:Y.key))),je!=null&&je.find(Y=>re===(Y==null?void 0:Y.key))&&(je=je==null?void 0:je.filter(Y=>re!==(Y==null?void 0:Y.key))),(W==null?void 0:W.formType)==="Select"?Ae=Ae==null?void 0:Ae.map(Y=>{var $e,na,_e,sa,Na,nl,Wa,ul,dl,Fl,Ua,ml,Pa,ol,Ga,tl;return(Y==null?void 0:Y.type)==="Select"&&((($e=Y==null?void 0:Y.allSelectionContents)==null?void 0:$e.length)>0&&(Y.contactValue=u),((W==null?void 0:W.prop)===(Y==null?void 0:Y.prop)||re===(Y==null?void 0:Y.prop))&&W&&(Array.isArray(W.value)&&((na=W.value)==null?void 0:na.length)>0&&((_e=W.value)!=null&&_e.every(wl=>typeof wl=="string"))?(je.push({key:Y==null?void 0:Y.prop,value:[(Na=W.value)==null?void 0:Na[((sa=W.value)==null?void 0:sa.length)-1]]}),Y.selectValue=(nl=je==null?void 0:je.find(wl=>(wl==null?void 0:wl.key)===(Y==null?void 0:Y.prop)))==null?void 0:nl.value):Array.isArray(W.value)&&((Wa=W.value)==null?void 0:Wa.length)===0?(je=[],Y.selectValue=[],u[Y==null?void 0:Y.prop]=""):Array.isArray(Y.value)&&je.push({key:Y==null?void 0:Y.prop,value:[(ul=Y.value)==null?void 0:ul[(Y==null?void 0:Y.length)-1]]})),((Fl=Y==null?void 0:Y.menus)==null?void 0:Fl[((dl=Y==null?void 0:Y.menus)==null?void 0:dl.length)-1])===""&&(W!=null&&W.isMainPath)&&(W!=null&&W.mainKey)&&((Ua=Y==null?void 0:Y.prop)!=null&&Ua.includes(".")&&((Pa=(ml=Y==null?void 0:Y.prop)==null?void 0:ml.split("."))==null?void 0:Pa[0])!==((Ga=(ol=W==null?void 0:W.prop)==null?void 0:ol.split("."))==null?void 0:Ga[0])||(Y.endChildMenu=(tl=xe==null?void 0:xe.split(" "))==null?void 0:tl[0]))),Y.value=(u==null?void 0:u[Y==null?void 0:Y.prop])??(Y==null?void 0:Y.value),Y}):(W==null?void 0:W.formType)!=="Input"&&(Ae=Ae==null?void 0:Ae.map(Y=>(Y.value=(u==null?void 0:u[Y==null?void 0:Y.prop])??(Y==null?void 0:Y.value),Y))),ae.value=je,Ae!=null&&Ae.some(Y=>(Y==null?void 0:Y.functionName)&&(Y==null?void 0:Y.functionName)!=="")){let Y=await vt([u],V==null?void 0:V.value,"Auto",Ne.value),$e=[];(el=Ae==null?void 0:Ae.filter(_e=>(_e==null?void 0:_e.functionName)&&(_e==null?void 0:_e.functionName)!==""))==null||el.forEach(_e=>{var sa;((sa=_e==null?void 0:_e.functionRelatedWords)==null?void 0:sa.length)>0&&($e=[...$e,..._e==null?void 0:_e.functionRelatedWords])}),$e=$e==null?void 0:$e.filter(_e=>(_e==null?void 0:_e[0])!=="@");let na=[];for(let _e in Y==null?void 0:Y[0])$e!=null&&$e.find(sa=>_e===sa||(_e==null?void 0:_e.includes("."+sa)))&&na.push(((be=Y==null?void 0:Y[0])==null?void 0:be[_e])!=="");(Y==null?void 0:Y.length)>0&&na.every(_e=>_e)&&(Ae=Ae==null?void 0:Ae.map(_e=>{var sa;return _e.value=((sa=Y==null?void 0:Y[0])==null?void 0:sa[_e==null?void 0:_e.prop])??_e.value,_e})),ur.value=Y==null?void 0:Y[0]}if(Ha.value=Ae,W=Object.assign({},W??{},{relatedWords:(fa=(Ra=Ha==null?void 0:Ha.value)==null?void 0:Ra.find(Y=>(Y==null?void 0:Y.prop)===(W==null?void 0:W.prop)))==null?void 0:fa.relatedWords}),(W==null?void 0:W.mainKey)&&(W!=null&&W.value)&&(W==null?void 0:W.value)!==""){let Y=W!=null&&W.relatedContents&&((Ea=W==null?void 0:W.relatedContents)==null?void 0:Ea.length)>0?(wa=W==null?void 0:W.relatedContents)==null?void 0:wa.find($e=>{var na,_e,sa,Na;return($e==null?void 0:$e[(Na=(na=W==null?void 0:W.prop)==null?void 0:na.split("."))==null?void 0:Na[((sa=(_e=W==null?void 0:W.prop)==null?void 0:_e.split("."))==null?void 0:sa.length)-1]])===(W==null?void 0:W.value)}):await cs(W);if(Y&&JSON.stringify(Y)!=="{}"){let $e=Ae;$e=$e==null?void 0:$e.map(_e=>{var sa,Na,nl,Wa,ul,dl,Fl,Ua,ml,Pa,ol,Ga,tl,wl,Dl,xr,Rl,gl,Tl,Xl,Nl;if((W==null?void 0:W.prop)===(_e==null?void 0:_e.prop))_e.value=(Y==null?void 0:Y[(sa=_e==null?void 0:_e.words)==null?void 0:sa.join(".")])??(Y==null?void 0:Y[_e==null?void 0:_e.prop])??Y[(ul=(Na=_e==null?void 0:_e.prop)==null?void 0:Na.split("."))==null?void 0:ul[((Wa=(nl=_e==null?void 0:_e.prop)==null?void 0:nl.split("."))==null?void 0:Wa.length)-1]];else if(W!=null&&W.relatedContents&&((dl=W==null?void 0:W.relatedContents)==null?void 0:dl.length)>0)_e.value=(Fl=_e==null?void 0:_e.prop)!=null&&Fl.includes(".")&&((ml=(Ua=_e==null?void 0:_e.prop)==null?void 0:Ua.split("."))==null?void 0:ml[0])===((ol=(Pa=W==null?void 0:W.prop)==null?void 0:Pa.split("."))==null?void 0:ol[0])?Y[(Dl=(Ga=_e==null?void 0:_e.prop)==null?void 0:Ga.split("."))==null?void 0:Dl[((wl=(tl=_e==null?void 0:_e.prop)==null?void 0:tl.split("."))==null?void 0:wl.length)-1]]:(Y==null?void 0:Y[_e==null?void 0:_e.prop])??(_e==null?void 0:_e.value);else if(he.same((W==null?void 0:W.menus)??[],(_e==null?void 0:_e.menus)??[])&&he.same((W==null?void 0:W.groups)??[],(_e==null?void 0:_e.groups)??[])&&!he.same((W==null?void 0:W.words)??[],(_e==null?void 0:_e.words)??[]))if((xr=_e==null?void 0:_e.prop)!=null&&xr.includes(".")&&((gl=(Rl=_e==null?void 0:_e.prop)==null?void 0:Rl.split("."))==null?void 0:gl[0])!==((Xl=(Tl=W==null?void 0:W.prop)==null?void 0:Tl.split("."))==null?void 0:Xl[0])){let Yl=Object.keys(Y);Yl=Yl==null?void 0:Yl.find(nr=>{var Ul;return nr==null?void 0:nr.includes("."+((Ul=_e==null?void 0:_e.words)==null?void 0:Ul.join(".")))}),_e.value=(Y==null?void 0:Y[Yl])??(Y==null?void 0:Y[_e==null?void 0:_e.prop])??_e.value}else{let Yl=Object.keys(Y);Yl=Yl==null?void 0:Yl.find(nr=>{var Ul;return nr==null?void 0:nr.includes("."+((Ul=_e==null?void 0:_e.words)==null?void 0:Ul.join(".")))}),_e.value=(Y==null?void 0:Y[(Nl=_e==null?void 0:_e.words)==null?void 0:Nl.join(".")])??(Y==null?void 0:Y[Yl])??(Y==null?void 0:Y[_e==null?void 0:_e.prop])??_e.value}else!(_e!=null&&_e.isMainPath)&&he.same((W==null?void 0:W.bindMenus)??[],(_e==null?void 0:_e.bindMenus)??[]),_e.value=(Y==null?void 0:Y[_e==null?void 0:_e.prop])??_e.value;return _e}),Ha.value=$e;let na={};(N=Ha.value)==null||N.forEach(_e=>{na[_e.prop]=_e==null?void 0:_e.value}),ur.value=na}}Or.value=!0,I.value=!1},hu=u=>u?(u==null?void 0:u.toUpperCase())==="INPUT"?"TEXTAREA":u:"TEXTAREA",vu=u=>{var C,ie;const h=(ie=(C=ba.value)==null?void 0:C.find(re=>(re==null?void 0:re.label)===(u==null?void 0:u.label)))==null?void 0:ie.multiple,B=u==null?void 0:u.prop;if((u==null?void 0:u.formType)!="Select")return;Ne.value.forEach(re=>{const W=re==null?void 0:re[B];h&&Eo.isString(W)&&(re[B]=[W]),!h&&!Eo.isString(W)&&(re[B]="")})},Ot=(u,h)=>{var B;return h==null||h.forEach(z=>{u[z==null?void 0:z.prop]=z==null?void 0:z.value}),u.children&&((B=u.children)==null?void 0:B.length)>0&&(u.children=u.children.map(z=>Ot(z,h))),u},it=u=>{var B,z,P,C,ie,re;Ri("");const h=(B=Ha.value)==null?void 0:B.reduce((W,xe)=>(W[xe.name]=xe.value,W),{});if(((z=Object.keys(h))==null?void 0:z.length)>0){ur.value=h,Ca.value="",Va.value=(P=Ne.value)==null?void 0:P.length,Oe.value=(C=Za.value)==null?void 0:C.filter(xe=>(xe==null?void 0:xe.label)!=="新增");const W=(re=(ie=De.value)==null?void 0:ie.filter(xe=>(xe==null?void 0:xe.label)!=="操作"))==null?void 0:re.map(xe=>{var je,Re,Ge;const Ae=(Re=(je=ba.value)==null?void 0:je.find(xa=>(xa==null?void 0:xa.label)===(xe==null?void 0:xe.label)))==null?void 0:Re.multiple;return vu(xe),{...xe,contents:(xe==null?void 0:xe.options)??[],optionUrl:xe!=null&&xe.formMenuSelect&&((Ge=xe==null?void 0:xe.formMenuSelect)==null?void 0:Ge.length)>0?{groupSelect:xe==null?void 0:xe.groupSelect,menuSelect:xe==null?void 0:xe.formMenuSelect,selectRelateType:"",type:xe==null?void 0:xe.formType,multiple:Ae}:null}});V.value=W==null?void 0:W.map(xe=>Ot(xe,[{prop:"type",value:"edit"},{prop:"columnType",value:hu(xe==null?void 0:xe.formType)||(xe==null?void 0:xe.columnType)}])),u==="createClick"&&(X.value="新增",Vi(!0))}},hi={START:"开始时间",END:"结束时间",HOURS:"工时"},mu=(u,h)=>Number(A.dayjs(h).diff(A.dayjs(u),"day",!0).toFixed(1)),Lt=u=>{var C;const h=c.itemData,B=(C=h==null?void 0:h.find(ie=>(ie==null?void 0:ie.key)==="header"))==null?void 0:C.contents,z=new Map;return B==null||B.forEach((ie,re)=>{const{label:W}=ie;z.set(W,re)}),!z.has(hi.START)||!z.has(hi.END)||!z.has(hi.HOURS)?u:u==null?void 0:u.map(ie=>{const re=ie==null?void 0:ie[hi.START],W=ie==null?void 0:ie[hi.END],xe=mu(re,W);return re&&W&&(ie[hi.HOURS]=`${xe}天`),ie})},Rt=(u,h,B=0)=>{if(B>((h==null?void 0:h.length)??""))return u;const z=h==null?void 0:h[B],P=new Map;for(const ie of u){const re=ie[z];P.has(re)||P.set(re,[]),P.get(re)&&P.get(re).push(ie)}const C=[];for(const[ie,re]of P){const[W,...xe]=re,Ae={...W};B+1===((h==null?void 0:h.length)??"")?Ae.children=re==null?void 0:re.map(je=>(je.level=A.cloneDeep(B)+1,je)).filter((je,Re)=>Re!==0):xe.length>0&&(Ae.children=Rt(xe,h,B+1)),Ae.level=B,C.push(Ae)}return C},$t=(u,h,B)=>{var P;if(!(h!=null&&h.contents)||((P=h==null?void 0:h.contents)==null?void 0:P.length)===0)return u;let z=[];return z=Rt(u,h==null?void 0:h.contents,0),z},Vt=async(u,h)=>{var za,Ye,Qa,ya,el,be,Ra,fa,Ea,wa,N,Y,$e,na,_e,sa,Na,nl,Wa,ul,dl,Fl,Ua,ml,Pa,ol,Ga,tl,wl,Dl,xr,Rl,gl,Tl,Xl,Nl,Yl,nr,Ul,vr,qr,mr,sr,dr,Pt,jt,Ht;const B=u==null?void 0:u.filter(ua=>(ua==null?void 0:ua.key)==="header");u==null||u.filter(ua=>(ua==null?void 0:ua.key)==="tableIndexColumn")[0];const z=u==null?void 0:u.filter(ua=>(ua==null?void 0:ua.key)==="childTree")[0];let P=!0;if((Qa=(Ye=(za=u==null?void 0:u.find(ua=>(ua==null?void 0:ua.key)==="filterAllType"))==null?void 0:za.value)==null?void 0:Ye.find(ua=>(ua==null?void 0:ua.value)==="onPamButtonContents"))!=null&&Qa.content){let ua=(be=(el=(ya=u==null?void 0:u.find(Sl=>(Sl==null?void 0:Sl.key)==="filterAllType"))==null?void 0:ya.value)==null?void 0:el.find(Sl=>(Sl==null?void 0:Sl.value)==="onPamButtonContents"))==null?void 0:be.content;ua=(Ra=ua==null?void 0:ua.split(":"))==null?void 0:Ra[1],ua=(fa=ua.slice(1,(ua==null?void 0:ua.length)-1))==null?void 0:fa.split(","),P=!!(ua!=null&&ua.find(Sl=>Sl==="操作"))}const C=u==null?void 0:u.find(ua=>(ua==null?void 0:ua.key)==="page"),ie=u==null?void 0:u.find(ua=>(ua==null?void 0:ua.key)==="rowButton"),re=u==null?void 0:u.find(ua=>(ua==null?void 0:ua.key)==="extraButton"),W=u==null?void 0:u.filter(ua=>(ua==null?void 0:ua.key)==="tableContents"),xe=u==null?void 0:u.filter(ua=>(ua==null?void 0:ua.key)==="bottomButton"),Ae=u==null?void 0:u.filter(ua=>(ua==null?void 0:ua.key)==="tableIndex");ba.value=(wa=(Ea=u==null?void 0:u.filter(ua=>(ua==null?void 0:ua.key)==="tableToForm"))==null?void 0:Ea[0])==null?void 0:wa.contents,ne.value=(C==null?void 0:C.contents)??!0;let je=[];Il.value===""?je=B==null?void 0:B[0]:je=(B==null?void 0:B.find(ua=>(ua==null?void 0:ua.selectLabel)==="("+Il.value+")"))??(B==null?void 0:B.find(ua=>!(ua!=null&&ua.selectLabel)));let Re=[];Il.value===""?Re=Ae==null?void 0:Ae[0]:Re=(Ae==null?void 0:Ae.find(ua=>(ua==null?void 0:ua.selectLabel)==="("+Il.value+")"))??(Ae==null?void 0:Ae.find(ua=>!(ua!=null&&ua.selectLabel)));let Ge=[],xa=[];if(((N=je==null?void 0:je.contents)==null?void 0:N.length)>0){let ua=[],Sl=je==null?void 0:je.contents;if(Array.isArray(Sl==null?void 0:Sl[0])&&((Y=Sl==null?void 0:Sl[0])!=null&&Y.every(Ya=>!(Ya!=null&&Ya.children)))&&(Sl=Sl==null?void 0:Sl[0]),Sl.some(Ya=>Array.isArray(Ya)&&(Ya==null?void 0:Ya.find(qe=>qe.children))))ua=($e=he.getGradeColumns(Sl,P))==null?void 0:$e[0],ua!=null&&ua.find(Ya=>(Ya==null?void 0:Ya.label)==="操作")||ua.push({label:"操作",prop:"operate",type:"operate"});else{let Ya=Sl.some(qe=>Array.isArray(qe))?Sl==null?void 0:Sl[0]:Sl;Ya!=null&&Ya.find(qe=>(qe==null?void 0:qe.label)==="操作")||Ya.push({label:"操作",prop:"operate",type:"operate"}),Ya==null||Ya.forEach((qe,er)=>{var Rr,zr,$r,Cr,ai,yi,gi,br,wn,$n,bi,an,Vn,Kt,Gt,Yt,Jt,Xt,Zt,Qt;if((zr=(Rr=Ee.value)==null?void 0:Rr.split("/"))==null||zr.forEach(ir=>{var yr,Cn,es;ir!==""&&((es=(Cn=(yr=ir==null?void 0:ir.split(w+"updateLoading"))==null?void 0:yr[0])==null?void 0:Cn.split(w+"loading"))==null||es[0])}),qe!=null&&qe.methodContent){let ir=(ai=(Cr=($r=qe==null?void 0:qe.methodContent)==null?void 0:$r.replace("@","%%#"))==null?void 0:Cr.split("%%#"))==null?void 0:ai[1];if(ir=ir==null?void 0:ir.slice(0,(ir==null?void 0:ir.length)-1),ir=he.contentTransArrayToAllNoExtra(ir??"",","),(yi=ir==null?void 0:ir.find(yr=>yr==null?void 0:yr.includes("@Button")))!=null&&yi.includes("Prop")&&((gi=ir==null?void 0:ir.find(yr=>yr==null?void 0:yr.includes("Type")))!=null&&gi.includes("Manual"))){let yr=(wn=(br=ir==null?void 0:ir.find(Cn=>Cn==null?void 0:Cn.includes("@Button")))==null?void 0:br.split(":"))==null?void 0:wn[1];yr=((an=(bi=($n=yr==null?void 0:yr.replaceAll("[",""))==null?void 0:$n.replaceAll("]",""))==null?void 0:bi.split(","))==null?void 0:an[1])??"算法执行",Ge.push(yr)}else if((Vn=ir==null?void 0:ir.find(yr=>yr==null?void 0:yr.includes("@Button")))!=null&&Vn.includes("Row")&&((Kt=ir==null?void 0:ir.find(yr=>yr==null?void 0:yr.includes("Type")))!=null&&Kt.includes("Manual"))){let yr=(Yt=(Gt=ir==null?void 0:ir.find(Cn=>Cn==null?void 0:Cn.includes("@Button")))==null?void 0:Gt.split(":"))==null?void 0:Yt[1];yr=((Zt=(Xt=(Jt=yr==null?void 0:yr.replaceAll("[",""))==null?void 0:Jt.replaceAll("]",""))==null?void 0:Xt.split(","))==null?void 0:Zt[1])??"算法执行",xa.push(yr)}}(Qt=ba.value)==null||Qt.find(ir=>(ir==null?void 0:ir.prop)===(qe==null?void 0:qe.prop)),ua.push({label:(qe==null?void 0:qe.label)==="操作"?P?"操作":"":(qe==null?void 0:qe.label)??"",prop:(qe==null?void 0:qe.label)==="操作"?"operate":(qe==null?void 0:qe.prop)??"a"+er,width:qe!=null&&qe.width?parseInt(qe.width):"",fixed:(qe==null?void 0:qe.fixed)??void 0,sortable:(qe==null?void 0:qe.sortable)??!1,filterable:(qe==null?void 0:qe.filterable)??!1,operable:(qe==null?void 0:qe.operable)??!1,showSummary:(qe==null?void 0:qe.showSummary)??!1,align:(qe==null?void 0:qe.align)??"left",showOverflowTooltip:(qe==null?void 0:qe.showOverflowTooltip)??!0,isNotDrag:(qe==null?void 0:qe.isNotDrag)??!1,isEditCol:(qe==null?void 0:qe.isEditCol)??!1,isOperate:(qe==null?void 0:qe.isOperate)??!1,id:(qe==null?void 0:qe.id)??er,type:(qe==null?void 0:qe.label)==="操作"?"operate":void 0,formType:(qe==null?void 0:qe.formType)??(qe!=null&&qe.groupSelect?"Select":""),disabled:qe==null?void 0:qe.disabled,options:(qe==null?void 0:qe.options)??[],value:(qe==null?void 0:qe.value)??"",isExistChild:(qe==null?void 0:qe.isExistChild)??!1,mainKey:(qe==null?void 0:qe.mainKey)??er===0,allSelectionContents:(qe==null?void 0:qe.allContents)??[],filterContent:qe==null?void 0:qe.filterContents,menus:qe==null?void 0:qe.menus,groups:qe==null?void 0:qe.groups,words:qe==null?void 0:qe.words,filter:qe==null?void 0:qe.filter,bindMenus:qe==null?void 0:qe.bindMenus,fatherPath:qe==null?void 0:qe.fatherPath,isMainPath:qe==null?void 0:qe.isMainPath,required:(qe==null?void 0:qe.required)??!1,relatedContents:qe==null?void 0:qe.relatedContents,functionName:qe==null?void 0:qe.functionName,functionRelatedWords:qe==null?void 0:qe.functionRelatedWords,calculatorFilter:qe==null?void 0:qe.calculatorFilter,relatedPages:qe==null?void 0:qe.relatedPages,multiple:(qe==null?void 0:qe.multiple)??!1,multipleLimit:qe==null?void 0:qe.multipleLimit})})}R.value=(na=xe==null?void 0:xe[0])==null?void 0:na.contents;const tn=he.getNewColumnChild(ua),Ut=Ya=>Array.isArray(Ya)?Ya.map(qe=>(Array.isArray(qe==null?void 0:qe.children)&&qe.children.length>0?(qe.sortable=!1,Ut(qe.children)):(qe==null?void 0:qe.prop)==="operate"||(qe==null?void 0:qe.label)==="操作"||(qe==null?void 0:qe.type)==="operate"||(qe.sortable=!1),qe)):Ya;Ut(tn),await eo(tn),l0(fe.value,tn),V.value=tn,Da.value=tn,r.value=(_e=V.value)==null?void 0:_e.map(Ya=>Ya==null?void 0:Ya.label);let sn=(Na=(sa=he.getAllLeafNodes(V.value))==null?void 0:sa.filter(Ya=>(Ya==null?void 0:Ya.type)!=="operate"))==null?void 0:Na.map((Ya,qe)=>({prop:(Ya==null?void 0:Ya.prop)??"a"+qe,column:Ya.label}));Dr.value=sn;let en=[];Il.value===""?en=W==null?void 0:W[0]:en=(W==null?void 0:W.find(Ya=>(Ya==null?void 0:Ya.selectLabel)==="("+Il.value+")"))??(W==null?void 0:W.find(Ya=>!(Ya!=null&&Ya.selectLabel)));let ei=Array.isArray((nl=en==null?void 0:en.contents)==null?void 0:nl[0])&&((Wa=en==null?void 0:en.contents)!=null&&Wa[0].every(Ya=>Array.isArray(Ya)))?(ul=en==null?void 0:en.contents)==null?void 0:ul[0]:en==null?void 0:en.contents;Re!=null&&Re.contents&&((dl=Re==null?void 0:Re.contents)==null?void 0:dl.length)!==0&&(ei=(Fl=A.cloneDeep(ei))==null?void 0:Fl.map((Ya,qe)=>{if(!Array.isArray(Ya)){let er={};for(let Rr in Ya)Rr!=="id"&&Rr!=="index"&&(er[Rr]=Ya[Rr]);Ya=Object.values(er)}return Ya}));const Nu=!!((Ua=V.value)!=null&&Ua.find(Ya=>Ya.prop==="index"));ei=uc(ei,Re==null?void 0:Re.contents,Nu);const vi=[];ei==null||ei.forEach((Ya,qe)=>{var Rr;let er={};if(Array.isArray(Ya)){let zr=[];Ya==null||Ya.filter($r=>!($r!=null&&$r.id)).forEach(($r,Cr)=>{var ai,yi,gi,br,wn,$n;if((ai=sn==null?void 0:sn[Cr])!=null&&ai.prop&&!Array.isArray($r)){let bi={};bi[sn[Cr].column]=$r,L!=null&&L.value&&((yi=L==null?void 0:L.value)==null?void 0:yi.length)>0&&((gi=L==null?void 0:L.value)!=null&&gi.find(an=>JSON.stringify(an==null?void 0:an[0])===JSON.stringify(bi)))&&(zr=(br=L==null?void 0:L.value)==null?void 0:br.find(an=>JSON.stringify(an==null?void 0:an[0])===JSON.stringify(bi))),zr&&zr.length>0?er[sn[Cr].prop]=zr!=null&&zr.find(an=>{var Vn;return((Vn=Object.keys(an))==null?void 0:Vn[0])===sn[Cr].column})?(wn=zr==null?void 0:zr.find(an=>{var Vn;return((Vn=Object.keys(an))==null?void 0:Vn[0])===sn[Cr].column}))==null?void 0:wn[sn[Cr].column]:$r:er[sn[Cr].prop]=$r}else Array.isArray($r)&&(($n=sn[Cr])!=null&&$n.prop?er[sn[Cr].prop]=$r:er.children=mt($r,sn))})}else er=Ya;if(Array.isArray(Ya)&&Ya.some(zr=>zr==null?void 0:zr.id)){const zr=(Rr=Ya==null?void 0:Ya.find($r=>$r.id))==null?void 0:Rr.id;vi.push(Object.assign(er,{id:io(zr)}))}else er.id?vi.push(er):vi.push(Object.assign(er,{id:qe.toString()}))});try{const Ya=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),qe=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null"),er=Ya==null?void 0:Ya.tableId,Rr=Ya==null?void 0:Ya.compIndex;if(er&&Array.isArray(qe)&&qe.length>0&&String(er)===String(c==null?void 0:c.parentTableId)&&String(Rr)===String(c==null?void 0:c.index)){const zr=new Set(vi.map(Cr=>String(Cr==null?void 0:Cr.id))),$r=qe.filter(Cr=>!zr.has(String(Cr)));if($r.length>0){const Cr=Ya==null?void 0:Ya.pageKey,ai=Cr!=null&&Cr.startsWith("/")?Cr.substring(1):Cr;((h==null?void 0:h[Cr])||(h==null?void 0:h[ai])||[]).filter(br=>{var wn,$n;return((wn=br==null?void 0:br.key)==null?void 0:wn.type)==="data"&&String(($n=br==null?void 0:br.key)==null?void 0:$n.tableId)===String(er)&&$r.includes(br==null?void 0:br.id)}).forEach(br=>{var wn;zr.has(String(br==null?void 0:br.id))||(vi.push({id:br==null?void 0:br.id,...((wn=br==null?void 0:br.value)==null?void 0:wn.tableData)||{}}),zr.add(String(br==null?void 0:br.id)))})}}}catch{}let mi=null;try{const Ya=`ocr_committed_temp_ids_v1:${String((c==null?void 0:c.parentTableId)??"")}:${String((c==null?void 0:c.index)??"")}`,qe=JSON.parse(sessionStorage.getItem(Ya)||"null");Array.isArray(qe)&&qe.length>0&&(mi=new Set(qe.map(er=>String(er))))}catch{}const qt=Array.from(((ml=Ta.value)==null?void 0:ml.values())||[]).filter(Ya=>!(!(Ya!=null&&Ya._isOCRRow&&(Ya==null?void 0:Ya._ocrTableId)===(c==null?void 0:c.index))||mi&&mi.has(String(Ya==null?void 0:Ya.id)))),Tu=(Ne.value||[]).map(Ya=>String(Ya==null?void 0:Ya.id)),Wt=ci(vi,Tu);if(Ne.value=$t(Wt,z,V.value),We.value=Wt,(Pa=We.value)==null||Pa.forEach(Ya=>{var qe;(qe=Ta.value)==null||qe.set(Ya.id,Ya)}),mi&&mi.size>0)try{const Ya=new Set(Array.from(mi.values()));Ne.value=(Ne.value||[]).filter(qe=>!Ya.has(String(qe==null?void 0:qe.id))),We.value=(We.value||[]).filter(qe=>!Ya.has(String(qe==null?void 0:qe.id))),Ya.forEach(qe=>{var er,Rr;try{(Rr=(er=Ta.value)==null?void 0:er.delete)==null||Rr.call(er,qe)}catch{}})}catch{}const uo=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),ot=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null");if(uo&&Array.isArray(ot)&&ot.length>0&&String(uo==null?void 0:uo.compIndex)===String(c==null?void 0:c.index)){const Ya=new Set((We.value||[]).map(qe=>String(qe==null?void 0:qe.id)));ot.filter(qe=>!Ya.has(String(qe)))}if(qt.length>0){const Ya=new Set((Ne.value||[]).map(er=>er==null?void 0:er.id)),qe=qt.filter(er=>!Ya.has(er.id));qe.length>0&&(Ne.value=[...Ne.value||[],...qe],We.value=[...We.value||[],...qe],qe.forEach(er=>{var Rr;return(Rr=Ta.value)==null?void 0:Rr.set(er.id,er)}))}}else V.value=[],De.value=[],Ne.value=[],We.value=[],Ta.value=new Map;if(xa=[...new Set(xa)],xa=xa==null?void 0:xa.map(ua=>({label:ua,type:"methodButton"})),((ol=ie==null?void 0:ie.contents)==null?void 0:ol.length)>0?ga.value=ie==null?void 0:ie.contents:ga.value=[],ga.value=[...ga.value,...xa],Ge=[...new Set(Ge)],Ge=Ge==null?void 0:Ge.map(ua=>({label:ua,type:"methodButton"})),((Ga=re==null?void 0:re.contents)==null?void 0:Ga.length)>0)if((Dl=(wl=(tl=u==null?void 0:u.find(ua=>(ua==null?void 0:ua.key)==="filterAllType"))==null?void 0:tl.value)==null?void 0:wl.find(ua=>(ua==null?void 0:ua.value)==="onButtonContents"))!=null&&Dl.content){let ua=(gl=(Rl=(xr=u==null?void 0:u.find(Sl=>(Sl==null?void 0:Sl.key)==="filterAllType"))==null?void 0:xr.value)==null?void 0:Rl.find(Sl=>(Sl==null?void 0:Sl.value)==="onButtonContents"))==null?void 0:gl.content;if(ua=(Tl=ua==null?void 0:ua.split(":"))==null?void 0:Tl[1],ua=(Xl=ua.slice(1,(ua==null?void 0:ua.length)-1))==null?void 0:Xl.split(","),Oe.value=(Nl=re==null?void 0:re.contents)==null?void 0:Nl.filter(Sl=>ua==null?void 0:ua.find(tn=>tn===(Sl==null?void 0:Sl.label))),Za.value=(Yl=re==null?void 0:re.contents)==null?void 0:Yl.filter(Sl=>ua==null?void 0:ua.find(tn=>tn===(Sl==null?void 0:Sl.label))),(nr=re==null?void 0:re.contents)!=null&&nr.some(Sl=>(Sl==null?void 0:Sl.label)==="OCR识别")&&!((Ul=Oe.value)!=null&&Ul.some(Sl=>(Sl==null?void 0:Sl.label)==="OCR识别"))){const Sl=(vr=re==null?void 0:re.contents)==null?void 0:vr.find(tn=>(tn==null?void 0:tn.label)==="OCR识别");Oe.value=[...Oe.value,Sl],Za.value=[...Za.value,Sl]}K.value=!!(ua!=null&&ua.find(Sl=>Sl==="搜索")),F.value=!!(ua!=null&&ua.find(Sl=>Sl==="块状显示"))}else Oe.value=re==null?void 0:re.contents,Za.value=re==null?void 0:re.contents;else Oe.value=[],Za.value=[];Oe.value=[...Oe.value,...Ge],Za.value=[...Za.value,...Ge],typeof Ee.value=="string"&&Ee.value==="设备管理/试验设备"&&(c==null?void 0:c.compName)==="设备列表"?((qr=Oe.value)!=null&&qr.some(ua=>(ua==null?void 0:ua.label)==="OCR识别")||(Oe.value=[...Oe.value||[],{label:"OCR识别"}]),(mr=Za.value)!=null&&mr.some(ua=>(ua==null?void 0:ua.label)==="OCR识别")||(Za.value=[...Za.value||[],{label:"OCR识别"}])):(Oe.value=(Oe.value||[]).filter(ua=>(ua==null?void 0:ua.label)!=="OCR识别"),Za.value=(Za.value||[]).filter(ua=>(ua==null?void 0:ua.label)!=="OCR识别")),(sr=Oe.value)!=null&&sr.some(ua=>(ua==null?void 0:ua.label)==="切换视图")||(Oe.value=[...Oe.value||[],{label:"切换视图"}]),(dr=Za.value)!=null&&dr.some(ua=>(ua==null?void 0:ua.label)==="切换视图")||(Za.value=[...Za.value||[],{label:"切换视图"}]),Va.value=((Pt=Ne==null?void 0:Ne.value)==null?void 0:Pt.length)??0,Lt(Ne.value),ln.value=Ne.value,Vl.value&&(V.value=(Ht=(jt=De.value)==null?void 0:jt.filter(ua=>(ua==null?void 0:ua.label)!=="操作"))==null?void 0:Ht.map(ua=>{var Sl;return{...ua,type:"edit",optionUrl:ua!=null&&ua.formMenuSelect&&((Sl=ua==null?void 0:ua.formMenuSelect)==null?void 0:Sl.length)>0?{groupSelect:ua==null?void 0:ua.groupSelect,menuSelect:ua==null?void 0:ua.formMenuSelect,selectRelateType:"",type:ua==null?void 0:ua.formType}:null}}),it())};e.watch(()=>[c.itemData,Il.value,Bn.value,pn.value,L==null?void 0:L.value],async()=>{var u,h,B,z,P,C;if((u=c==null?void 0:c.itemData)!=null&&u.find(ie=>(ie==null?void 0:ie.key)==="columnPath")&&!((h=Q.value)!=null&&h.find(ie=>{var re,W;return(ie==null?void 0:ie.key)===((W=(re=c==null?void 0:c.itemData)==null?void 0:re.find(xe=>(xe==null?void 0:xe.key)==="columnPath"))==null?void 0:W.contents)}))){let ie=Q.value,re={key:(z=(B=c==null?void 0:c.itemData)==null?void 0:B.find(W=>(W==null?void 0:W.key)==="columnPath"))==null?void 0:z.contents,value:(C=(P=c==null?void 0:c.itemData)==null?void 0:P.find(W=>(W==null?void 0:W.key)==="columnUsingPath"))==null?void 0:C.contents};ie!=null&&ie.find(W=>(W==null?void 0:W.key)===(re==null?void 0:re.key))?ie=ie==null?void 0:ie.map(W=>((W==null?void 0:W.key)===(re==null?void 0:re.key)&&(W.value=re.value),W)):ie.push(re),oa.setTableViewContents(ie)}await Vt(c.itemData,c.allMapContents)},{deep:!0,immediate:!0}),e.watch(()=>c==null?void 0:c.operatingForm,u=>{u!=null&&u.form&&(Ri(u==null?void 0:u.form),X.value=u==null?void 0:u.dialogTitle,Aa.value=!0,Z.value=!0)},{immediate:!0,deep:!0});const yu=()=>{var u;(u=S.value)!=null&&u.includes("read")&&(Vl.value=!Vl.value)},gu=()=>{_r.value=!_r.value};e.watch(()=>{var u;return(u=c==null?void 0:c.config)==null?void 0:u.viewport},u=>{var h;S.value=u,(u==null?void 0:u.length)===0?Vl.value=!1:(u!=null&&u.includes("read")||(Vl.value=!0),u!=null&&u.includes("edit")||(Vl.value=!1)),M.value=((h=c==null?void 0:c.config)==null?void 0:h.showIndex)||Vl.value},{immediate:!0}),e.watch(()=>Vl.value,u=>{var h;u?(it("viewChange"),oa.setCacheUpdatingData(null)):(Oe.value=Za.value,V.value=Da.value,H.value&&(oa.setTableLoading(c==null?void 0:c.index),Me("change",H.value))),M.value=u||((h=c==null?void 0:c.config)==null?void 0:h.showIndex),Gl.value=[]},{immediate:!0}),e.watch(()=>{var u;return(u=fn.value)==null?void 0:u.length},u=>{u===0&&(ge.currentPage=1)}),e.watch(()=>c==null?void 0:c.compNames,u=>{f.contents=[{label:"列表名",prop:"groupName",name:"列表名",type:"select",value:"",id:0,contents:u||[],width:1}]},{immediate:!0}),e.ref(!1);const bu=(u,h)=>{var B;it("createClick"),h===ge.pageSize&&(ge.currentPage=Math.ceil(((B=Ne.value)==null?void 0:B.length)/ge.pageSize))},ku=async(u,h,B)=>{var P,C,ie,re,W;const z=(h==null?void 0:h.property)??(h==null?void 0:h.prop);if(z&&so.includes(z)&&B!==void 0&&B!==null&&String(B).trim()!==""){const xe=String(B).trim();if(await nt(xe,u==null?void 0:u.id)){qa.ElMessage.warning("当前任务下通道号不能重复,请重新选择");const je=(P=Ne.value)==null?void 0:P.findIndex(Ge=>(Ge==null?void 0:Ge.id)===(u==null?void 0:u.id)),Re=je!==-1?(ie=(C=Ne.value)==null?void 0:C[je])==null?void 0:ie[z]:void 0;z&&(u[z]=Re??"");return}}if(Vl.value){const xe=u==null?void 0:u.id;xe!=null&&(v.value.has(xe)||v.value.set(xe,A.cloneDeep(u)),s.value.add(xe));const Ae=(re=Ne.value)==null?void 0:re.findIndex(je=>(je==null?void 0:je.id)===(u==null?void 0:u.id));Ae!==-1&&z&&(Ne.value[Ae]={...Ne.value[Ae],[z]:B}),co(B,u,h);return}co(B,u,h),ur.value=A.cloneDeep(u),Ca.value=u==null?void 0:u.id,Va.value=(W=Ne.value)==null?void 0:W.length,X.value=u!=null&&u._isTemp?"新增":"编辑",Vi(!1)},xu=async()=>{var u,h;try{const B=[];if(c!=null&&c.related&&Array.isArray(c.related)&&(console.log("props.related",c.related),c.related.forEach(z=>{if(typeof z=="string"&&z.includes("content_")){const P=z.split("_")[1];P&&(B.push(`content_${P}`),B.push(`struct_${P}`))}})),B.length===0&&(c!=null&&c.itemData)){const z=(h=(u=c.itemData)==null?void 0:u.find(P=>(P==null?void 0:P.key)==="contentTableId"))==null?void 0:h.contents;z&&(B.push(`content_${z}`),B.push(`struct_${z}`))}return B}catch(B){return console.error("获取 tableNames 失败:",B),[]}},wu=async(u,h,B)=>{var C,ie;if(!B||typeof B!="string"||B.trim()===""){const re=(h==null?void 0:h.property)??(h==null?void 0:h.prop),W=`${u==null?void 0:u.id}:${re}`;p.value.delete(W),g.value.set(W,!1);return}const z=(h==null?void 0:h.property)??(h==null?void 0:h.prop),P=`${u==null?void 0:u.id}:${z}`;g.value.set(P,!0);try{const re=await xu();if(re.length===0){console.warn("未找到同名表,跳过全局搜索"),p.value.delete(P),g.value.set(P,!1);return}const W=parseInt((C=cl.value)==null?void 0:C.plat_id);if(!W){console.warn("platId 无效,跳过全局搜索"),p.value.delete(P),g.value.set(P,!1);return}const xe=await A.getAllTables({platId:W,tableNames:re??[]}),Ae=((ie=xe==null?void 0:xe.data)==null?void 0:ie.result)||[],je=[],Re=[];for(let Ge=0;Ge<Ae.length;Ge+=2)Ge+1<Ae.length&&Re.push([Ae[Ge],Ae[Ge+1]]);Re.forEach(([Ge,xa])=>{var el;if(!Array.isArray(Ge)||Ge.length===0||!Array.isArray(xa)||xa.length===0)return;const Oa=xa[0];let za=((el=Oa==null?void 0:Oa.结构)==null?void 0:el.contents)??[];if(!Array.isArray(za)||za.length===0)return;let Ye=A.cloneDeep(za);if(Array.isArray(Ye==null?void 0:Ye[0])&&(Ye=he.getColumnChild(Ye[0])),!Array.isArray(Ye)||Ye.length===0||!Ye.some(be=>(be==null?void 0:be.prop)===z))return;[...Ge].sort((be,Ra)=>{const fa=Number((be==null?void 0:be.update_time)??0);return Number((Ra==null?void 0:Ra.update_time)??0)-fa}).slice(0,20).forEach(be=>{const Ra=be[z];if(Ra!=null){const fa=String(Ra);fa.toLowerCase().includes(B.toLowerCase())&&je.findIndex(wa=>{var N;return be.id&&((N=wa.rowData)==null?void 0:N.id)===be.id?!0:wa.label===fa})===-1&&je.push({label:fa,rowData:A.cloneDeep(be),sourceTable:(Oa==null?void 0:Oa.source_table)||""})}})}),p.value.set(P,je)}catch(re){console.error("全局搜索建议失败:",re),p.value.delete(P)}finally{g.value.set(P,!1)}},_u=(u,h,B)=>{if(!Vl.value)return;const z=(h==null?void 0:h.property)??(h==null?void 0:h.prop),P=(h==null?void 0:h.formType)||(h==null?void 0:h.columnType)||"";if(P&&P.toUpperCase()!=="INPUT"&&P!=="")return;const C=`${u==null?void 0:u.id}:${z}`;if(y.has(C)&&clearTimeout(y.get(C)),!B||B.trim()===""){p.value.delete(C),g.value.set(C,!1);return}const ie=setTimeout(()=>{wu(u,{prop:z,property:z},B),y.delete(C)},300);y.set(C,ie)};function Su(u,h){const B=`${u==null?void 0:u.id}:${(h==null?void 0:h.property)??(h==null?void 0:h.prop)}`;return p.value.get(B)||[]}const Eu=(u,h,B)=>{var Ae;if(!B||!B.rowData)return;const z=B.rowData,P=u==null?void 0:u.id,C=(h==null?void 0:h.property)??(h==null?void 0:h.prop),re=(he.getAllLeafNodes(V.value)||[]).filter(je=>(je==null?void 0:je.type)!=="operate"&&(je==null?void 0:je.label)!=="操作"&&(je==null?void 0:je.prop)!=="operate");re.forEach(je=>{const Re=je==null?void 0:je.prop;Re&&z[Re]!==void 0&&(u[Re]=z[Re])});const W=(Ae=Ne.value)==null?void 0:Ae.findIndex(je=>(je==null?void 0:je.id)===P);W!==-1&&re.forEach(je=>{const Re=je==null?void 0:je.prop;Re&&z[Re]!==void 0&&(Ne.value[W][Re]=z[Re])}),P!=null&&(v.value.has(P)||v.value.set(P,A.cloneDeep(u)),s.value.add(P));const xe=`${P}:${C}`;p.value.delete(xe),g.value.set(xe,!1),co(u[C],u,h)},Ur=u=>{var W,xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa;const{row:h,column:B,item:z,slotData:P}=u;let C=h!=null&&h[B==null?void 0:B.prop]||(h==null?void 0:h[B==null?void 0:B.prop])===0?((xe=(W=h==null?void 0:h[B==null?void 0:B.prop])==null?void 0:W[0])==null?void 0:xe.contents)??((h==null?void 0:h[B==null?void 0:B.prop])===0?"0":h==null?void 0:h[B==null?void 0:B.prop]):((je=(Ae=h==null?void 0:h[z==null?void 0:z.prop])==null?void 0:Ae[0])==null?void 0:je.contents)??(h==null?void 0:h[z==null?void 0:z.prop])??((Ge=(Re=P==null?void 0:P[z==null?void 0:z.prop])==null?void 0:Re[0])==null?void 0:Ge.contents)??(P==null?void 0:P[z==null?void 0:z.prop])??((za=(Oa=h==null?void 0:h[(xa=z==null?void 0:z.child)==null?void 0:xa.prop])==null?void 0:Oa[0])==null?void 0:za.contents)??(h==null?void 0:h[(Ye=z==null?void 0:z.child)==null?void 0:Ye.prop]),re=Array.isArray(C)&&!(C!=null&&C.every(ya=>typeof ya=="string"||typeof ya=="number"))?"查看":C;if(re=Array.isArray(re)?re.join(","):re,(B==null?void 0:B.formType)==="Date")if(!re||re===""||re===null||re===void 0)re="";else{const ya=A.dayjs(re,["YYYY-MM-DD","YYYY/MM/DD","YYYY年MM月DD日","YYYYMMDD"],!0);re=ya.isValid()?ya.format("YYYYMMDD"):re??""}return Array.isArray(B==null?void 0:B.relatedPages)&&((Qa=B==null?void 0:B.relatedPages)==null?void 0:Qa.length)>0&&(re="详情页"),re},Cu=u=>{var xe,Ae,je,Re,Ge,xa,Oa,za,Ye,Qa;const{row:h,column:B,item:z,slotData:P}=u;let C=h!=null&&h[B==null?void 0:B.prop]?((Ae=(xe=h==null?void 0:h[B==null?void 0:B.prop])==null?void 0:xe[0])==null?void 0:Ae.contents)??(h==null?void 0:h[B==null?void 0:B.prop]):((Re=(je=h==null?void 0:h[z==null?void 0:z.prop])==null?void 0:je[0])==null?void 0:Re.contents)??(h==null?void 0:h[z==null?void 0:z.prop])??((xa=(Ge=P==null?void 0:P[z==null?void 0:z.prop])==null?void 0:Ge[0])==null?void 0:xa.contents)??(P==null?void 0:P[z==null?void 0:z.prop])??((Ye=(za=h==null?void 0:h[(Oa=z==null?void 0:z.child)==null?void 0:Oa.prop])==null?void 0:za[0])==null?void 0:Ye.contents)??(h==null?void 0:h[(Qa=z==null?void 0:z.child)==null?void 0:Qa.prop]);const re=Array.isArray(C)&&!(C!=null&&C.every(ya=>typeof ya=="string"||typeof ya=="number")),W=Array.isArray(C)&&(C==null?void 0:C.find(ya=>ya==null?void 0:ya.url));return re&&W},Du=u=>{var P,C,ie,re;if(!(u!=null&&u.column))return!1;const h=Ee.value==="试验任务/任务管理",B=(c==null?void 0:c.compName)==="任务列表",z=((C=(P=u==null?void 0:u.column)==null?void 0:P.filter)==null?void 0:C.includes("@TextRGBA"))||((re=(ie=u==null?void 0:u.column)==null?void 0:ie.filter)==null?void 0:re.includes("@TextBackRGBA"));return h&&B&&z},Bu=(u,h)=>u.find(B=>Object.values(B).some(z=>z===h));return e.watch(()=>Te.value,async u=>{if(u){te.setContentLoading(!0),await e.nextTick();const h=Bu(Ne.value,u==null?void 0:u.data);if(!h)return te.setContentLoading(!1);await Oi(u==null?void 0:u.data,null,h,{data:u==null?void 0:u.data}),te.setContentLoading(!1)}},{deep:!0,immediate:!0}),e.watch(()=>c==null?void 0:c.cacheNewData,u=>{var h;u&&(Array.isArray(u)?u.forEach(B=>{var z,P,C,ie,re;if(换,String(B==null?void 0:B.compId)===String(c==null?void 0:c.index)&&(B!=null&&B.resId)&&((z=B==null?void 0:B.data)!=null&&z.id)){const W=(P=B==null?void 0:B.data)==null?void 0:P.id,xe=B==null?void 0:B.resId;if(Ne.value=(C=Ne.value)==null?void 0:C.map(Ae=>{if((Ae==null?void 0:Ae.id)===W){const je={...Ae,id:xe};return delete je._isOCRRow,delete je._ocrTableId,je}return Ae}),(re=(ie=Ta.value)==null?void 0:ie.has)!=null&&re.call(ie,W)){const je={...Ta.value.get(W)||{},id:xe};delete je._isOCRRow,delete je._ocrTableId,Ta.value.delete(W),Ta.value.set(xe,je)}rl(c==null?void 0:c.index,W,xe)}}):String(u==null?void 0:u.compId)===String(c==null?void 0:c.index)&&(Ne.value=(h=Ne.value)==null?void 0:h.map(B=>{var z;if((B==null?void 0:B.id)===((z=u==null?void 0:u.data)==null?void 0:z.id)){const P={...B,id:u==null?void 0:u.resId};return delete P._isOCRRow,delete P._ocrTableId,P}return B})))},{immediate:!0,deep:!0}),(u,h)=>{var Ye,Qa,ya,el;const B=e.resolveComponent("svg-icon"),z=e.resolveComponent("el-popover"),P=e.resolveComponent("el-switch"),C=e.resolveComponent("el-checkbox"),ie=e.resolveComponent("el-radio"),re=e.resolveComponent("el-radio-group"),W=e.resolveComponent("el-checkbox-group"),xe=e.resolveComponent("el-button"),Ae=e.resolveComponent("el-icon"),je=e.resolveComponent("el-progress"),Re=e.resolveComponent("el-alert"),Ge=e.resolveComponent("el-table-column"),xa=e.resolveComponent("el-table"),Oa=e.resolveComponent("el-upload"),za=e.resolveComponent("el-text");return e.openBlock(),e.createElementBlock("div",P0,[gn.value?(e.openBlock(),e.createBlock(ll.ssTable,{id:"excel-table",pageObj:ge,showIndex:M.value,isTree:(Ye=a.compItem)==null?void 0:Ye.isTree,summaryInfo:se,columns:V.value,defaultSort:de,isCardViewport:_r.value,checkedColumns:r.value,key:rn.value+V.value,tableData:fn.value,isEditViewport:Vl.value,isShowPagination:ne.value,isShowEdit:!1,isShowDelete:!1,allowSelect:D.value,onDbClickRow:En,extraButton:Oe.value,rowButton:ga.value,cacheExtraButtons:Za.value,isClearSelection:((Qa=Gl.value)==null?void 0:Qa.length)===0,onDoCurrentChange:Ni,onDoSizeChange:Lo,onSortChange:Ro,onContentClick:Oi,onRowClick:Yo,onSelectChange:Uo,onCellChange:ku,onCellInput:_u,onSelectSuggest:Eu,onChange:co,onPreview:ro,onSubmitEditingTable:Zi,onHandleColEditChange:Ji,onHandleColTypeChange:jr,onClickButton:lt,onAddNewRow:Po,bottomButton:R.value,allowRowAddOrDelete:Zn.value},e.createSlots({headerButton:e.withCtx(be=>{var Ra,fa,Ea,wa;return[a.showHeader?(e.openBlock(),e.createBlock(gf,{key:0,id:"tableHeaderButton",pageLayout:a.pageLayout,lockingPage:e.unref(da)===e.unref(Ee),filterValues:Go.value,selectNums:(Ra=Gl.value)==null?void 0:Ra.length,dataNums:(fa=Ne.value)==null?void 0:fa.length,compName:a.compName,isDevMode:a.isDevMode,buttons:be.buttons,menuFilter:(wa=(Ea=a.compItem)==null?void 0:Ea.component)==null?void 0:wa.menuFilter,onButtonClick:h[1]||(h[1]=(N,Y,$e)=>lt(N,Y,{extra:$e})),columns:V.value,onFilter:oo,onGetImportData:Vo,level:a.level,filterShow:K.value},null,8,["pageLayout","lockingPage","filterValues","selectNums","dataNums","compName","isDevMode","buttons","menuFilter","columns","level","filterShow"])):e.createCommentVNode("",!0)]}),viewport:e.withCtx(()=>{var be,Ra,fa,Ea;return[((be=Ne.value)==null?void 0:be.length)>0&&a.allowOperate&&F.value?(e.openBlock(),e.createElementBlock("div",U0,[(Ra=S.value)!=null&&Ra.includes("read")&&((fa=S.value)!=null&&fa.includes("edit"))&&((Ea=ga.value)!=null&&Ea.some(wa=>(wa==null?void 0:wa.label)==="编辑"))&&!_r.value&&e.unref(da)!==e.unref(Ee)?(e.openBlock(),e.createElementBlock("span",{key:0,title:"编辑表格",onClick:yu},[e.createVNode(B,{name:"editTable",class:"view-icon"})])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]}),rowCreate:e.withCtx(({row:be,index:Ra})=>[e.createElementVNode("span",{title:"新增",class:"row-create-wrap",onClick:fa=>bu(be,Ra)},[e.createVNode(B,{name:"rowCreate",style:{width:"10px",height:"10px"}})],8,q0)]),operateCol:e.withCtx(()=>[e.createVNode(z,{title:"选择显示列信息",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:du,onBeforeEnter:pu},{reference:e.withCtx(()=>[e.createElementVNode("span",W0,[e.createVNode(B,{name:"operate",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",K0,[h[20]||(h[20]=e.createElementVNode("div",{class:"group-title"},"表格操作",-1)),e.createVNode(P,{"model-value":$.value,"active-text":"排序","inactive-text":"",style:{"margin-right":"8px"},onChange:h[2]||(h[2]=be=>ao(be))},null,8,["model-value"]),h[21]||(h[21]=e.createElementVNode("div",{class:"group-title"},"表格列操作",-1)),e.createVNode(W,{modelValue:r.value,"onUpdate:modelValue":h[3]||(h[3]=be=>r.value=be),style:{height:"100%"},min:2,ref_key:"checkboxGroupRef",ref:t},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(nn.value,be=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:be.label},[e.createVNode(C,{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,G0)]),_:2},1032,["value"]),e.createVNode(z,{"popper-class":"col-operate-popover",title:"列操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(B,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Ra;return[e.createElementVNode("div",Y0,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Ra=Object.keys(be))==null?void 0:Ra.filter(fa=>{var Ea;return(Ea=E.value)==null?void 0:Ea.find(wa=>(wa==null?void 0:wa.value)===fa)}),fa=>{var Ea,wa;return e.openBlock(),e.createElementBlock("div",{key:fa},[j[fa]=="radio"?(e.openBlock(),e.createElementBlock("div",J0,[h[19]||(h[19]=e.createElementVNode("div",null,"固定:",-1)),e.createVNode(re,{"model-value":be==null?void 0:be[fa],onChange:N=>Kn(N,fa,be)},{default:e.withCtx(()=>{var N,Y;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Y=(N=E.value)==null?void 0:N.find($e=>($e==null?void 0:$e.value)===fa))==null?void 0:Y.options,$e=>(e.openBlock(),e.createBlock(ie,{key:$e==null?void 0:$e.value,label:$e==null?void 0:$e.value,value:$e==null?void 0:$e.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString($e==null?void 0:$e.label),1)]),_:2},1032,["label","value"]))),128))]}),_:2},1032,["model-value","onChange"])])):e.createCommentVNode("",!0),j[fa]=="switch"?(e.openBlock(),e.createBlock(P,{key:1,"model-value":be==null?void 0:be[fa],"active-text":(wa=(Ea=E.value)==null?void 0:Ea.find(N=>(N==null?void 0:N.value)===fa))==null?void 0:wa.label,onChange:N=>Kn(N,fa,be)},null,8,["model-value","active-text","onChange"])):e.createCommentVNode("",!0)])}),128))])]}),_:2},1024),e.createElementVNode("span",X0,[e.createVNode(B,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:1},8,["modelValue"])])):e.createCommentVNode("",!0)]),_:1})]),content:e.withCtx(be=>{var Ra,fa,Ea,wa,N,Y,$e,na,_e,sa,Na,nl,Wa,ul,dl,Fl,Ua,ml,Pa,ol;return[((Ra=be==null?void 0:be.column)==null?void 0:Ra.label)==="证书附件"||((fa=be==null?void 0:be.column)==null?void 0:fa.prop)==="证书附件"?(e.openBlock(),e.createElementBlock("div",Z0,[e.createVNode(B,{name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:e.withModifiers(Ga=>fi(be),["stop"]),title:"查看OCR图片"},null,8,["onClick"])])):Cu(be)?(e.openBlock(),e.createBlock(z,{key:1,"popper-class":"file-popover",placement:"right",trigger:"hover",effect:"light",width:"auto"},{reference:e.withCtx(()=>[e.createElementVNode("span",Q0,e.toDisplayString(Ur(be)),1)]),default:e.withCtx(()=>{var Ga,tl;return[e.createElementVNode("div",e3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((tl=be==null?void 0:be.row)==null?void 0:tl[(Ga=be==null?void 0:be.column)==null?void 0:Ga.prop],wl=>(e.openBlock(),e.createElementBlock("div",a3,[e.createElementVNode("div",{class:"prop-url",title:Yn(wl),onClick:Dl=>ui(wl)},e.toDisplayString(Yn(wl)),9,l3),e.createElementVNode("div",{class:"prop-download",onClick:Dl=>Wo(wl)}," 下载 ",8,r3)]))),256))])]}),_:2},1024)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[Du(be)?(e.openBlock(),e.createBlock(Fu,{key:0,value:Ur(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(Ur(be))&&((wa=(Ea=Ur(be))==null?void 0:Ea.toString())!=null&&wa.includes(".txt")||(Y=(N=Ur(be))==null?void 0:N.toString())!=null&&Y.includes(".cpt")||(na=($e=Ur(be))==null?void 0:$e.toString())!=null&&na.includes(".cyd"))?"var(--vertical-menuitem-active-bg)":"",textDecoration:!Array.isArray(Ur(be))&&((sa=(_e=Ur(be))==null?void 0:_e.toString())!=null&&sa.includes(".txt")||(nl=(Na=Ur(be))==null?void 0:Na.toString())!=null&&nl.includes(".cpt")||(ul=(Wa=Ur(be))==null?void 0:Wa.toString())!=null&&ul.includes(".cyd"))?"underline":"",cursor:!Array.isArray(Ur(be))&&((Fl=(dl=Ur(be))==null?void 0:dl.toString())!=null&&Fl.includes(".txt")||(ml=(Ua=Ur(be))==null?void 0:Ua.toString())!=null&&ml.includes(".cpt")||(ol=(Pa=Ur(be))==null?void 0:Pa.toString())!=null&&ol.includes(".cyd"))?"pointer":"",marginLeft:(be==null?void 0:be.colIndex)===0?`${((be==null?void 0:be.level)??0)*20}px`:0}),onClick:Ga=>{var tl;return qn(Ur(be),((tl=be==null?void 0:be.column)==null?void 0:tl.relatedPages)??[])}},e.toDisplayString(Ur(be)===0?"0":Ur(be)),13,n3))],64))]}),_:2},[((ya=ga.value)==null?void 0:ya.length)>0?{name:"actions",fn:e.withCtx(({item:be,fIndex:Ra})=>[e.createVNode(z,{title:"",placement:"left-start","popper-class":"menu-operate-popover"},{reference:e.withCtx(()=>[e.createVNode(B,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"},onClick:h[0]||(h[0]=e.withModifiers(()=>{},["stop"]))})]),default:e.withCtx(()=>[e.createElementVNode("div",j0,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Ii(ga.value,be),(fa,Ea)=>(e.openBlock(),e.createElementBlock("div",{class:"menu-config-item",key:Ea,onClick:e.withModifiers(wa=>lt(fa==null?void 0:fa.label,be,{extra:fa}),["stop"])},[e.createElementVNode("div",{style:e.normalizeStyle({color:fa==null?void 0:fa.textColor}),class:"extra-button-label"},e.toDisplayString(fa==null?void 0:fa.label),5)],8,H0))),128))])]),_:2},1024)]),key:"0"}:void 0]),1032,["pageObj","showIndex","isTree","summaryInfo","columns","defaultSort","isCardViewport","checkedColumns","tableData","isEditViewport","isShowPagination","allowSelect","extraButton","rowButton","cacheExtraButtons","isClearSelection","bottomButton","allowRowAddOrDelete"])):e.createCommentVNode("",!0),Vl.value?(e.openBlock(),e.createElementBlock("div",i3,[e.createVNode(xe,{id:"themeBorderButton",onClick:Ho},{default:e.withCtx(()=>h[22]||(h[22]=[e.createTextVNode("取消")])),_:1,__:[22]}),e.createVNode(xe,{class:"ok-button",id:"themeButton",onClick:Ai},{default:e.withCtx(()=>h[23]||(h[23]=[e.createTextVNode("保存")])),_:1,__:[23]})])):e.createCommentVNode("",!0),e.createVNode(wr.ssDialog,{title:X.value,visible:Z.value,width:cr.value,onBeforeDestroy:lo,style:{height:"74%"}},{default:e.withCtx(()=>[e.createElementVNode("div",o3,[e.createVNode(ll.ssForm,{ref_key:"formRef",ref:q,rowContents:Ha.value,showOperator:!1,onChange:fu,isEnableWrap:!1,onFixChangeValue:Ko,onClickTrigger:Gn,isEdit:Qe.value,onBlurChange:Qi,onCreate:si,onTagChange:An},null,8,["rowContents","isEdit"])])]),footer:e.withCtx(()=>[Aa.value?(e.openBlock(),e.createElementBlock("div",t3,[e.createVNode(xe,{onClick:h[4]||(h[4]=be=>Z.value=!1),id:"themeBorderButton"},{default:e.withCtx(()=>h[24]||(h[24]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[24]}),e.createVNode(xe,{class:"ok-button",onClick:h[5]||(h[5]=be=>Vi(!0)),id:"themeButton"},{default:e.withCtx(()=>h[25]||(h[25]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[25]})])):e.createCommentVNode("",!0)]),_:1},8,["title","visible","width"]),e.createVNode(wr.ssDialog,{title:X.value,visible:Je.value,width:ra.value,onBeforeDestroy:h[7]||(h[7]=be=>Je.value=!1)},{default:e.withCtx(()=>[e.createVNode(Tf)]),footer:e.withCtx(()=>[e.createElementVNode("div",s3,[e.createVNode(xe,{onClick:h[6]||(h[6]=be=>Je.value=!1),class:"cancel-button",id:"themeBorderButton"},{default:e.withCtx(()=>h[26]||(h[26]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[26]}),e.createVNode(xe,{class:"ok-button",onClick:Jo,id:"themeButton"},{default:e.withCtx(()=>h[27]||(h[27]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[27]})])]),_:1},8,["title","visible","width"]),le.value?(e.openBlock(),e.createBlock(ll.ssFilePreview,{key:2,fileDataList:ta.value,onDestroy:Li},null,8,["fileDataList"])):e.createCommentVNode("",!0),Fe.value?(e.openBlock(),e.createBlock(wr.ssDialog,{key:3,visible:Fe.value,onBeforeDestroy:cu,style:{height:"80vh",width:"80vw"},"body-class":"three-dialog-body","footer-class":"three-dialog-footer"},{default:e.withCtx(()=>[e.createVNode(So.ThreeViewerHost,{files:_a.value,threeData:T.value},null,8,["files","threeData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0),e.createVNode(wr.ssDialog,{title:"OCR扫描录入",visible:sl.value,"close-on-click-modal":!1,onBeforeDestroy:El,width:"1000px",dialogHeight:700,minWidth:900,minHeight:600,class:"ocr-upload-dialog",resizable:!0},{default:e.withCtx(()=>[h[38]||(h[38]=e.createElementVNode("div",{class:"ocr-header-bg"},null,-1)),e.createElementVNode("div",c3,[e.createElementVNode("div",u3,[e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:ia.value===1}])},h[28]||(h[28]=[e.createElementVNode("div",{class:"step-circle"},"1",-1),e.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件识别",-1)]),2),h[31]||(h[31]=e.createElementVNode("div",{class:"ocr-step-connector"},null,-1)),e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:ia.value===2}])},h[29]||(h[29]=[e.createElementVNode("div",{class:"step-circle"},"2",-1),e.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件确认",-1)]),2),h[32]||(h[32]=e.createElementVNode("div",{class:"ocr-step-connector"},null,-1)),e.createElementVNode("div",{class:e.normalizeClass(["ocr-step-item",{active:ia.value===3}])},h[30]||(h[30]=[e.createElementVNode("div",{class:"step-circle"},"3",-1),e.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件提交",-1)]),2)]),ia.value===1?(e.openBlock(),e.createElementBlock("div",d3,[e.createVNode(xe,{onClick:o,class:"ocr-action-btn",disabled:ma.value,size:"default"},{default:e.withCtx(()=>h[33]||(h[33]=[e.createTextVNode("扫描文件 ")])),_:1,__:[33]},8,["disabled"]),e.createVNode(xe,{onClick:Gr,class:"ocr-action-btn",disabled:ma.value,size:"default"},{default:e.withCtx(()=>h[34]||(h[34]=[e.createTextVNode("上传文件 ")])),_:1,__:[34]},8,["disabled"])])):e.createCommentVNode("",!0),ia.value===1?(e.openBlock(),e.createElementBlock("div",p3,[e.createElementVNode("div",f3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ka.value,(be,Ra)=>{var fa;return e.openBlock(),e.createElementBlock("div",{key:Ra,class:"ocr-file-item"},[e.createElementVNode("div",h3,[be.raw&&((fa=be.raw.type)!=null&&fa.startsWith("image/"))?(e.openBlock(),e.createElementBlock("img",{key:0,src:Hl(be),alt:"预览",class:"thumbnail-image"},null,8,v3)):(e.openBlock(),e.createElementBlock("div",m3,[e.createVNode(Ae,{size:40},{default:e.withCtx(()=>[e.createVNode(e.unref(qa.document_default))]),_:1})])),e.createElementVNode("div",{class:e.normalizeClass(["file-progress-ring",{uploading:Cl(be)==="uploading",processing:Cl(be)==="processing",completed:Cl(be)==="completed"||Cl(be)==="uploaded",failed:Cl(be)==="failed"}])},[(e.openBlock(),e.createElementBlock("svg",y3,[h[35]||(h[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:Cl(be)==="completed"||Cl(be)==="uploaded",uploading:Cl(be)==="uploading",processing:Cl(be)==="processing",failed:Cl(be)==="failed"}]),cx:"18",cy:"18",r:"16",fill:"none",stroke:Cl(be)==="failed"?"#f56c6c":Cl(be)==="completed"||Cl(be)==="uploaded"?"#67c23a":"#409eff","stroke-width":Cl(be)==="completed"||Cl(be)==="uploaded"||Cl(be)==="failed"?3:2,"stroke-dasharray":Hr(be),"stroke-dashoffset":"0","stroke-linecap":"round",transform:"rotate(-90 18 18)"},null,10,g3)])),Cl(be)==="completed"||Cl(be)==="uploaded"?(e.openBlock(),e.createElementBlock("div",b3,[e.createVNode(Ae,{class:"check-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(qa.check_default))]),_:1})])):e.createCommentVNode("",!0),Cl(be)==="failed"?(e.openBlock(),e.createElementBlock("div",k3,[e.createVNode(Ae,{class:"error-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(qa.close_default))]),_:1})])):e.createCommentVNode("",!0)],2),e.createElementVNode("div",{class:"file-delete-btn",onClick:Ea=>iu(Ra)},[e.createVNode(Ae,null,{default:e.withCtx(()=>[e.createVNode(e.unref(qa.close_default))]),_:1})],8,x3)]),e.createElementVNode("div",w3,e.toDisplayString(be.name||"文件名123"),1)])}),128))]),ka.value.length>0?(e.openBlock(),e.createElementBlock("div",_3,[e.createVNode(xe,{onClick:aa,class:"ocr-start-recognize-btn",disabled:ma.value||ka.value.length===0,size:"default"},{default:e.withCtx(()=>h[36]||(h[36]=[e.createTextVNode("开始识别 ")])),_:1,__:[36]},8,["disabled"])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),ia.value===1?(e.openBlock(),e.createElementBlock("div",S3,[e.createVNode(je,{percentage:ha.value,"stroke-width":8},null,8,["percentage"])])):e.createCommentVNode("",!0),ia.value===2?(e.openBlock(),e.createElementBlock("div",E3,[e.createElementVNode("div",C3,[e.createVNode(Re,{title:"请核对识别结果。",type:"info",closable:!1,"show-icon":""})]),e.createElementVNode("div",D3,[e.createVNode(xa,{data:Xe.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(Ge,{type:"index",label:"序号",width:"60",fixed:""}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Ze.value,be=>(e.openBlock(),e.createBlock(Ge,{key:be.prop,prop:be.prop,"min-width":be.minWidth||230,"class-name":be.isAccuracy?"accuracy-column":""},{header:e.withCtx(()=>[e.createElementVNode("div",B3,[e.createElementVNode("span",null,e.toDisplayString(be.label),1)])]),default:e.withCtx(({row:Ra,$index:fa})=>{var Ea,wa,N;return[be.isAccuracy?(e.openBlock(),e.createElementBlock("span",{key:0,class:"accuracy-value",style:e.normalizeStyle({color:bl(Ra[be.prop]),fontWeight:500})},e.toDisplayString(al(Ra[be.prop])),5)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[il.value!==fa?(e.openBlock(),e.createElementBlock("span",N3,e.toDisplayString(Ra[be.prop]),1)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(pl(be.prop)),{key:1,modelValue:Ra[be.prop],"onUpdate:modelValue":Y=>Ra[be.prop]=Y,size:"small",placeholder:"请输入"+be.label,content:((Ea=Ke(be.prop))==null?void 0:Ea.contents)??((wa=Ke(be.prop))==null?void 0:wa.options)??[],optionUrl:(N=Ke(be.prop))==null?void 0:N.optionUrl,onChange:Y=>Ka(fa,be.prop,Y),onFocus:Y=>Ia.value=be.prop,onBlur:h[8]||(h[8]=Y=>Ia.value="")},null,40,["modelValue","onUpdate:modelValue","placeholder","content","optionUrl","onChange","onFocus"]))],64))]}),_:2},1032,["prop","min-width","class-name"]))),128)),e.createVNode(Ge,{label:"编辑",width:"80",fixed:"right"},{default:e.withCtx(({$index:be})=>[il.value===be?(e.openBlock(),e.createBlock(Ae,{key:0,class:"ocr-edit-icon editing",style:{"margin-left":"12px"},onClick:e.withModifiers(Ra=>vl(be),["stop"])},{default:e.withCtx(()=>[e.createVNode(e.unref(qa.check_default))]),_:2},1032,["onClick"])):(e.openBlock(),e.createBlock(B,{key:1,name:"edit_101",class:"ocr-edit-icon",onClick:e.withModifiers(Ra=>vl(be),["stop"])},null,8,["onClick"]))]),_:1})]),_:1},8,["data"])])])):e.createCommentVNode("",!0),ia.value===3?(e.openBlock(),e.createElementBlock("div",T3,[e.createVNode(Ae,{size:"32",class:"ocr-success-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(qa.check_default))]),_:1}),h[37]||(h[37]=e.createElementVNode("div",{class:"ocr-success-text"},"文件提交成功",-1))])):e.createCommentVNode("",!0)]),e.createVNode(Oa,{ref:"ocrUploadRef","file-list":ka.value,"onUpdate:fileList":h[9]||(h[9]=be=>ka.value=be),multiple:"",action:"","auto-upload":!1,limit:20,accept:"image/*,application/pdf","on-change":He,"show-file-list":!1,class:"ocr-upload-input",style:{display:"none"}},null,8,["file-list"])]),footer:e.withCtx(()=>[ia.value!==3?(e.openBlock(),e.createElementBlock("div",A3,[e.createVNode(xe,{onClick:on,class:"ocr-start-recognize-btn",disabled:ia.value===1||ma.value},{default:e.withCtx(()=>h[39]||(h[39]=[e.createTextVNode(" 上一步 ")])),_:1,__:[39]},8,["disabled"]),e.createVNode(xe,{onClick:xn,class:"ocr-start-recognize-btn",disabled:ma.value},{default:e.withCtx(()=>h[40]||(h[40]=[e.createTextVNode(" 下一步 ")])),_:1,__:[40]},8,["disabled"])])):e.createCommentVNode("",!0)]),_:1},8,["visible"]),e.createVNode(Gf,{visible:pi.value,onConfirm:i,onCancel:h[10]||(h[10]=be=>pi.value=!1)},null,8,["visible"]),e.createVNode(xd,{visible:$a.value,"onUpdate:visible":h[11]||(h[11]=be=>$a.value=be),versions:we.value},null,8,["visible","versions"]),e.createVNode(td,{visible:ze.value,"onUpdate:visible":h[12]||(h[12]=be=>ze.value=be),images:_l.value,"default-image-name":Ol.value,"field-meta":il.value!==null?((el=Xe.value[il.value])==null?void 0:el.__ocrFieldMeta)||{}:{},"focused-field-name":Ia.value,onClose:h[13]||(h[13]=be=>ze.value=!1),class:"ocr-img-preview-dialog"},null,8,["visible","images","default-image-name","field-meta","focused-field-name"]),e.createVNode(Id,{visible:ql.value,"onUpdate:visible":h[14]||(h[14]=be=>ql.value=be),candidates:Wl.value,"name-prop":jl.value,"mfr-prop":ar.value,columns:V.value,onSubmit:Sr,onPreviewFile:Qn},null,8,["visible","candidates","name-prop","mfr-prop","columns"]),e.createVNode(Pd,{visible:va.value,"onUpdate:visible":h[15]||(h[15]=be=>va.value=be),ocrPreviewData:Xe.value,"onUpdate:ocrPreviewData":h[16]||(h[16]=be=>Xe.value=be),ocrSelectedFields:Sa.value,"onUpdate:ocrSelectedFields":h[17]||(h[17]=be=>Sa.value=be),ocrPreviewColumns:Ze.value,onConfirm:Xa,onFieldChange:h[18]||(h[18]=({rowIndex:be,prop:Ra,value:fa})=>Ka(be,Ra,fa))},null,8,["visible","ocrPreviewData","ocrSelectedFields","ocrPreviewColumns"]),e.createVNode(wr.ssDialog,{title:f.title,visible:f.show,width:f.width,onBeforeDestroy:ee},{default:e.withCtx(()=>[e.createElementVNode("div",z3,[e.createVNode(ll.ssForm,{rowContents:f==null?void 0:f.contents,formRules:f==null?void 0:f.formRules,showOperator:!1,buttonValue:f.buttonValue,isEdit:Qe.value,isStartJustify:!1,onOnButtonClick:ke},null,8,["rowContents","formRules","buttonValue","isEdit"])])]),_:1},8,["title","visible","width"]),e.createVNode(wr.ssDialog,{title:"",visible:m.show,width:m.width,alignCenter:!0,onBeforeDestroy:_},{header:e.withCtx(()=>[e.createElementVNode("div",null,[e.createElementVNode("div",M3,e.toDisplayString(m.title),1),e.createVNode(za,{size:"small",type:"danger",style:{width:"100%"}},{default:e.withCtx(()=>h[41]||(h[41]=[e.createTextVNode(" (选择【覆盖】,可能会影响到原数据的引用关系;选择【跳过】将会放弃重复数据的导入。请谨慎操作!) ")])),_:1,__:[41]})])]),footer:e.withCtx(()=>[e.createElementVNode("div",I3,[e.createVNode(za,{size:"small",style:{width:"100%","text-align":"left"},type:"info"},{default:e.withCtx(()=>[e.createTextVNode("引用模块:"+e.toDisplayString(Ln.value||"暂无"),1)]),_:1}),e.createElementVNode("div",O3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m==null?void 0:m.buttonValue,be=>(e.openBlock(),e.createBlock(xe,{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:Ra=>G(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(bf,{columns:m==null?void 0:m.columns,tableData:m==null?void 0:m.tableData},{content:e.withCtx(({row:be,item:Ra,slotData:fa,scope:Ea,column:wa,columnProp:N,$index:Y})=>[e.createTextVNode(e.toDisplayString((be==null?void 0:be[wa==null?void 0:wa.prop])||(be==null?void 0:be[wa==null?void 0:wa.label])||(be==null?void 0:be[wa==null?void 0:wa.property])||(fa==null?void 0:fa[wa==null?void 0:wa.property])),1)]),_:1},8,["columns","tableData"])]),_:1},8,["visible","width"])])}}},Bc=Zl._export_sfc(R3,[["__scopeId","data-v-11b04e78"]]),$3={key:1,class:"static-form-body"},V3=["onClick"],F3={key:1},P3=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}},emits:["update:backGroundImage"],setup(a,{emit:l}){const r=a,n=l,t=k=>{switch(k){case"占用":return"warning";case"注销":return"info";case"损坏":return"danger";case"可用":return"success";default:return""}},s=e.computed(()=>{var $;const k=($=r.itemData)==null?void 0:$.find(F=>(F==null?void 0:F.key)==="formContent"),b=(k==null?void 0:k.contents)||[];return(r.fields&&r.fields.length>0?r.fields:b).filter(F=>(F==null?void 0:F.label)||(F==null?void 0:F.isHideInForm)).map(F=>{let J=F==null?void 0:F.value;Array.isArray(J)&&(J=J.map(V=>V==null?"":typeof V=="object"?V.label??V.value??V.name??JSON.stringify(V):String(V)).filter(Boolean).join(",")),J!=null&&typeof J=="object"&&(J=J.label??J.value??J.name??JSON.stringify(J));const se=F.isHideInForm?"":F.label??"",ge=J==null||J===""?"-":String(J),Me=se==="使用状态";return{label:se,value:ge,isStatus:Me,tagType:Me?t(ge):"",width:F.width??1,field:F}})}),v=e.ref(null),d=e.ref(null),p=e.computed(()=>{const k=Number(r==null?void 0:r.textSize),b=he.rgbaToColor(r==null?void 0:r.textColor),w={},$={},F={},J={};return!Number.isNaN(k)&&k&&(w.fontSize=`${k}px`,$.fontSize=`${k+1}px`,F.fontSize=`${k}px`,J.fontSize=`${k}px`),b&&($.color=b,F.color=b,J.color=b),{item:w,label:$,value:F,empty:J}}),y=e.ref(""),g=e.ref(""),c=e.ref(!1),D=async k=>{if(k){g.value&&(URL.revokeObjectURL(g.value),g.value="");try{const b=await A.platformDownloadFile({url:k}),w=new Blob([b==null?void 0:b.data],{type:(b==null?void 0:b.headers["content-type"])||"image/*"});g.value=URL.createObjectURL(w)}catch{g.value=""}}};e.watch(()=>r==null?void 0:r.backGroundImage,k=>{k&&(y.value=k)},{immediate:!0}),e.watch(y,k=>{D(k)},{immediate:!0});const M=()=>{var k;(k=d.value)==null||k.click()},S=async k=>{var $,F,J;const b=k.target,w=($=b==null?void 0:b.files)==null?void 0:$[0];if(!w){b.value="";return}c.value=!0;try{const se=new FormData;se.append("file",w);const ge=await A.platformUploadFile(se),Me=(J=(F=ge==null?void 0:ge.data)==null?void 0:F.result)==null?void 0:J.url;Me?(y.value=Me,n("update:backGroundImage",Me),D(Me),qa.ElMessage.success("背景图片上传成功")):qa.ElMessage.error("背景图片上传失败")}catch{qa.ElMessage.error("背景图片上传失败")}finally{c.value=!1,b.value=""}},K=e.computed(()=>g.value?{backgroundImage:`url(${g.value})`,backgroundSize:"contain",backgroundPosition:"center",backgroundRepeat:"no-repeat"}:{}),I=k=>ll.getComponent(k),R=k=>{if(!k)return;const b=k.querySelector("input, textarea, .el-input__inner");b&&typeof b.focus=="function"&&b.focus()},j=(k,b,w)=>{r.disabled||(v.value=b,e.nextTick(()=>{R(w.currentTarget)}))},E=()=>{v.value=null},x=k=>{const b=k!=null&&k.width&&k.width>0?k.width:1,$=`calc((100% - ${(b-1)*48}px) / ${b})`;return{flex:`0 0 ${$}`,maxWidth:$,minWidth:"0",boxSizing:"border-box"}};return(k,b)=>{const w=e.resolveComponent("el-tag");return e.openBlock(),e.createElementBlock("div",{class:"static-form-card",style:e.normalizeStyle(K.value),onClick:b[2]||(b[2]=$=>(r==null?void 0:r.backGround)==="Yes"&&M())},[(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($=>M(),["stop"]))},[e.createElementVNode("input",{ref_key:"bgUploadRef",ref:d,type:"file",accept:"image/*",style:{display:"none"},onChange:S},null,544),b[3]||(b[3]=e.createElementVNode("img",{src:ll._imports_0,class:"bg-upload-icon",alt:"上传背景"},null,-1))])):e.createCommentVNode("",!0),s.value.length?(e.openBlock(),e.createElementBlock("div",$3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,($,F)=>{var J,se,ge,Me,V,fe,ae,de,De;return e.openBlock(),e.createElementBlock("div",{key:F,class:"static-form-item",style:e.normalizeStyle({...x($),...p.value.item}),onClick:b[1]||(b[1]=e.withModifiers(()=>{},["stop"]))},[$.label&&!((J=$==null?void 0:$.field)!=null&&J.isHideInForm)?(e.openBlock(),e.createElementBlock("div",{key:0,class:"static-form-label",style:e.normalizeStyle(p.value.label)},e.toDisplayString($.label)+": ",5)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"static-form-value",style:e.normalizeStyle(p.value.value),onClick:Fe=>{var ye;return(ye=$.field)!=null&&ye.isNoClick?null:j($,F,Fe)}},[v.value===F&&$.field?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(I(((se=$.field)==null?void 0:se.type)??"Input")),{key:0,modelValue:$.field.value,"onUpdate:modelValue":Fe=>$.field.value=Fe,isEdit:!0,disabled:(ge=$.field)==null?void 0:ge.disabled,content:((Me=$.field)==null?void 0:Me.contents)??[],optionUrl:$.field,originalValue:(V=$.field)==null?void 0:V.value,config:(fe=$.field)==null?void 0:fe.config,configModel:((ae=$.field)==null?void 0:ae.prop)??((de=$.field)==null?void 0:de.name),selectedTagList:((De=$.field)==null?void 0:De.selectValue)??[],onBlur:E,onBlurChange:E},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[$.isStatus?(e.openBlock(),e.createBlock(w,{key:0,type:$.tagType,size:"Default",effect:"plain"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString($.value??"-"),1)]),_:2},1032,["type"])):(e.openBlock(),e.createElementBlock("span",F3,e.toDisplayString($.value??"-"),1))],64))],12,V3)],4)}),128))])):(e.openBlock(),e.createElementBlock("div",{key:2,class:"static-form-empty",style:e.normalizeStyle(p.value.empty)}," 暂无数据 ",4))],4)}}}),Nc=Zl._export_sfc(P3,[["__scopeId","data-v-74b02d73"]]),j3={class:"form-content"},H3={title:"选择标签"},U3={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},q3={class:"col-operate-wrap"},W3={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},K3={__name:"index",props:{formRules:Object,itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,compName:{type:String,default:""},allMapContents:{type:Object},config:{type:Object,default:()=>{}}},emits:["change","contentChange","routeUrl","clickTrigger"],setup(a,{emit:l}){const r=()=>{v.value=!1,d.value=!1,p.value=[]},n=a;e.computed(()=>{var Z;const ne=(Z=Pe.value)==null?void 0:Z.split("/");return(ne==null?void 0:ne.some(q=>(q==null?void 0:q.includes("updateLoading"))||(q==null?void 0:q.includes("loading"))))?!1:De.value==="view"});const t=l,s=e.ref([]),v=e.ref(!1),d=e.ref(!1),p=e.ref([]),{getFileExtension:y}=So.useThreeSystem(),g=e.ref(),c=e.ref(!1),D=e.ref(!1),M=A.useUnit(A.pinia),{chooseTitle:S}=A.storeToRefs(M),K=e.ref([]),I=e.ref(),R=e.ref(!1),j=e.ref([]),E=cc(A.pinia),x=Ct(A.pinia),k=e.ref(!1),b=e.ref(),w=e.ref(),$=e.ref(),F=e.ref(),J=e.ref(),se=A.useLoginState(A.pinia),{loginUserInfo:ge}=A.storeToRefs(se),Me=e.ref(),V=e.ref(!0),fe=A.useModelComp(A.pinia),{tableViewContents:ae,itemData:de,isEdit:De,routeToChildPath:Fe,lockingPage:ye,homepageBackgroundTableId:T}=A.storeToRefs(fe),ue=e.ref(null),U=e.ref(!1),Se=e.ref(!1),Le=A.useMenuState(),{activeMenuPath:Pe}=A.storeToRefs(Le),la=he.useOriginalState(A.pinia),{originalPath:Da}=A.storeToRefs(la),{compType:le,hasEditable:ta}=Ys.useRole(),te=()=>!ta(n.config,{type:le.FORM});e.computed(()=>Pe.value==="设备管理/试验设备"&&n.compName==="设备概要");const ca=async()=>{var Z,q,Be;const ne=T==null?void 0:T.value,X=(Z=ge==null?void 0:ge.value)==null?void 0:Z.plat_id;if(!(!ne||!X))try{const Je=await A.getAllTables({platId:parseInt(X),tableNames:[`content_${ne}`,`struct_${ne}`],user_unique_id:"0"}),ra=((Be=(q=Je==null?void 0:Je.data)==null?void 0:q.result)==null?void 0:Be[0])??[],ba=String((n==null?void 0:n.index)??""),ga=ra==null?void 0:ra.find(Aa=>String(Aa==null?void 0:Aa.relatedForm_id)===ba);ga!=null&&ga.backgroundImg_url&&(F.value=ga.backgroundImg_url)}catch(Je){console.error("获取首页背景图片表数据失败:",Je)}},Ee=e.ref([]),oe=e.ref([{label:"编辑",value:"operable",checked:!1},{label:"禁用",value:"disabled",checked:!1}]),Te=async ne=>{Se.value=ne,await me("disabled",null,ne,!0)},Ue=async ne=>{await me("operable",null,ne,!0)};e.watch(()=>Pe.value,async()=>{s.value=[],p.value=[]},{deep:!0,immediate:!0});const oa=()=>{e.nextTick(()=>{Q()})},Ja=ne=>{var X;s.value=(X=s.value)==null?void 0:X.map(Z=>({...Z,isFormColHidden:!(ne!=null&&ne.includes(Z.label))}))};e.onUnmounted(()=>{ue.value=null});const L=ne=>{t("clickTrigger",ne)},H=async ne=>{var X,Z,q,Be,Je,ra;if(ne===""){let ba="";(X=s.value)==null||X.forEach(Oe=>{Oe!=null&&Oe.isMain&&(ba=Oe==null?void 0:Oe.value)});let ga=await he.getItemData(Fe.value,sessionStorage.getItem("systemKey"),"");ba=((ra=(Je=(Be=(q=(Z=ga==null?void 0:ga[0])==null?void 0:Z.compData)==null?void 0:q.find(Oe=>(Oe==null?void 0:Oe.key)==="mainRouters"))==null?void 0:Be.contents)==null?void 0:Je[0])==null?void 0:ra.routerContent)+Da.value+ba;let _a=await he.getItemData(ba,sessionStorage.getItem("systemKey"),"");R.value=!0,j.value=_a==null?void 0:_a.filter(Oe=>(Oe==null?void 0:Oe.comp)!=="methodButton"),t("routeUrl",j.value)}},Q=()=>{var X;const ne=(X=ue.value)==null?void 0:X.$el;ne&&Bl.Sortable.create(ne,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:Z=>{const{oldIndex:q,newIndex:Be}=Z;if(q===Be)return;const Je=s.value.splice(q,1)[0];s.value.splice(Be,0,Je)}})},me=async(ne,X,Z,q=!1)=>{try{fe.setRefreshCurStructure(!1)}catch{qa.ElMessage.error("编辑处理失败")}},ve=async(ne,X)=>{await me()},da=async(ne,X)=>{ne&&await me()},ea=async(ne,X,Z)=>{await me(X,Z,ne,!1)},ce=(ne,X)=>{Me.value===X?V.value=!1:V.value=!0,Me.value=X==null?void 0:X.changeProp},pa=async ne=>{var ra;F.value=ne;const X=n.itemData,Z=X==null?void 0:X.find(ba=>(ba==null?void 0:ba.key)==="backGroundImage");Z?Z.contents=ne:X==null||X.push({key:"backGroundImage",contents:ne}),t("change",{key:"backGroundImage",contents:ne});const q=T==null?void 0:T.value,Be=n==null?void 0:n.index,Je=(ra=ge==null?void 0:ge.value)==null?void 0:ra.plat_id;if(!(!q||!Je||!Be||!ne))try{await A.pageBatchAddApi({platId:parseInt(Je),changeContents:[{tableName:`content_${q}`,tableContents:[{backgroundImg_url:ne,relatedForm_id:String(Be)}]}],user_unique_id:"0"})}catch(ba){console.error("保存背景图片记录失败:",ba),qa.ElMessage.error("背景图片记录保存失败")}},Ne=async ne=>{var Z,q,Be,Je,ra,ba,ga,Aa,_a,Oe,Za,Ha,xl,Jl,kl;let X=[];if((Z=ne==null?void 0:ne.toString())!=null&&Z.includes(".urdf")){if(ne.includes(",")){qa.ElMessage.error("当前版本仅允许单个urdf预览!");return}p.value=[{url:ne,extension:y(ne)}],d.value=!0,v.value=!0;return}if((q=ne==null?void 0:ne.toString())!=null&&q.includes(".stl")||(Be=ne==null?void 0:ne.toString())!=null&&Be.includes(".STL")||(Je=ne==null?void 0:ne.toString())!=null&&Je.includes(".obj")||(ra=ne==null?void 0:ne.toString())!=null&&ra.includes(".mtl")){const ja=((ba=ne==null?void 0:ne.toString())==null?void 0:ba.split(",")).map(Ml=>({url:Ml,extension:y(Ml)}));p.value=ja,d.value=!1,v.value=!0;return}if((ga=ne==null?void 0:ne.toString())!=null&&ga.includes(".stl")||(Aa=ne==null?void 0:ne.toString())!=null&&Aa.includes(".STL")||(_a=ne==null?void 0:ne.toString())!=null&&_a.includes(".obj")||(Oe=ne==null?void 0:ne.toString())!=null&&Oe.includes(".mtl")){let Pl,ja=[],Ml={};if(Array.isArray(ne)?Pl=ne:Pl=ne==null?void 0:ne.split(","),Pl==null||Pl.forEach($l=>{$l.includes(".mtl")?ja.push($l):Ml.blob=Ml.blob?Ml.blob+","+$l:$l}),(ja==null?void 0:ja.length)>0&&(Ml.mtlBlobs=ja),(Ha=(Za=Object.values(Ml))==null?void 0:Za[0])!=null&&Ha.includes("http:"))X.push(Ml);else{const $l=new Blob([Ml.blob],{type:"application/octet-stream;charset=UTF-8"});let Ma=URL.createObjectURL($l),rl="";(xl=ne==null?void 0:ne.split("/"))==null||xl.forEach((sl,ma)=>{var ka;ma===((ka=ne==null?void 0:ne.split("/"))==null?void 0:ka.length)-1&&(rl=sl)}),(Jl=Ml.blob)!=null&&Jl.includes(".stl")&&(rl=(rl==null?void 0:rl.replaceAll(">",""))+".urdf"),I.value=[{name:rl,blobUrl:Ma}],D.value=!0}}else{const Pl=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),ja=await qa.axios.get(ne,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{Pl.close()}),Ml=new Blob([ja.data],{type:"application/octet-stream;charset=UTF-8"});let $l=URL.createObjectURL(Ml),Ma="";(kl=ne==null?void 0:ne.split("/"))==null||kl.forEach((rl,sl)=>{var ma;sl===((ma=ne==null?void 0:ne.split("/"))==null?void 0:ma.length)-1&&(Ma=rl)}),I.value=[{name:Ma,blobUrl:$l}],D.value=!0}(X==null?void 0:X.length)>0&&x.setBlobUrls(X)},We=()=>{D.value=!1},Ta=ne=>{var Je,ra,ba,ga;const X=(ra=(Je=ll.safeClone(n.itemData))==null?void 0:Je.find(Aa=>(Aa==null?void 0:Aa.key)==="formContent"))==null?void 0:ra.contents,Z=ll.safeClone(ne.content);let q={};Z&&((ba=Object.values(Z))==null?void 0:ba.length)>0&&((ga=Object.values(Z))==null||ga.forEach((Aa,_a)=>{q[X[_a].key]=Aa}));const Be={content:q,index:n==null?void 0:n.index,buttonName:ne==null?void 0:ne.buttonName};t("change",Be)};e.computed(()=>"http://222.92.178.198:62001");const Ca=async ne=>{var Za,Ha,xl,Jl,kl,Pl,ja,Ml,$l,Ma,rl,sl,ma,ka,La,$a;if(!ne)return;(Ha=(Za=n==null?void 0:n.itemData)==null?void 0:Za.find(we=>(we==null?void 0:we.key)==="parentFormPath"))==null||Ha.contents;let X=ae.value;(X==null?void 0:X.length)>0&&(X=X==null?void 0:X.map(we=>{var Ie,pe,ha,va;let ia=(Ie=we==null?void 0:we.key)==null?void 0:Ie.split("/");return(n==null?void 0:n.compName)===(ia==null?void 0:ia[0])&&(pe=s.value)!=null&&pe.find(Xe=>(Xe==null?void 0:Xe.prop)===(ia==null?void 0:ia[1]))&&(we.value=(va=(ha=s.value)==null?void 0:ha.find(Xe=>(Xe==null?void 0:Xe.prop)===(ia==null?void 0:ia[1])))==null?void 0:va.value),we}),fe.setTableViewContents(X));const Z=ll.safeClone(n.itemData);let q=Z==null?void 0:Z.map(we=>{var ia;return(we==null?void 0:we.key)==="formContent"&&((ia=we.contents)==null||ia.map((Ie,pe)=>{var ha,va,Xe,Ze,Ke,pl,Ve,Fa,Sa,il,Ia,ze,_l,Ol,ql,Wl,Ql,pr,Ll,fr,Vr;return Ie.type=(va=(ha=s.value)==null?void 0:ha.find(jl=>(jl==null?void 0:jl.prop)===(Ie==null?void 0:Ie.prop)))==null?void 0:va.type,Ie.options=Ie!=null&&Ie.options?Ie.options:((Ke=(Ze=(Xe=Ie==null?void 0:Ie.key)==null?void 0:Xe.split("$"))==null?void 0:Ze[1])==null?void 0:Ke.length)>0?(Sa=(Fa=Ru((Ve=(pl=Ie==null?void 0:Ie.key)==null?void 0:pl.split("$"))==null?void 0:Ve[1]))==null?void 0:Fa.split(","))==null?void 0:Sa.map(jl=>({label:jl,value:jl})):[],(il=Ie==null?void 0:Ie.key)!=null&&il.includes("$")&&(Ie.key=(ze=(Ia=Ie==null?void 0:Ie.key)==null?void 0:Ia.split("$"))==null?void 0:ze[0]),Ie.signature=(Ol=(_l=s.value)==null?void 0:_l.find(jl=>(jl==null?void 0:jl.prop)===(Ie==null?void 0:Ie.prop)))==null?void 0:Ol.signature,Ie.isLoginUser=(Wl=(ql=s.value)==null?void 0:ql.find(jl=>(jl==null?void 0:jl.prop)===(Ie==null?void 0:Ie.prop)))==null?void 0:Wl.isLoginUser,Ie.value=(Ql=Object.values(ne))==null?void 0:Ql[pe],Ie.isFormColHidden=(Ll=(pr=s.value)==null?void 0:pr.find(jl=>(jl==null?void 0:jl.prop)===(Ie==null?void 0:Ie.prop)))==null?void 0:Ll.isFormColHidden,Ie.isHideInForm=(Vr=(fr=s.value)==null?void 0:fr.find(jl=>(jl==null?void 0:jl.prop)===(Ie==null?void 0:Ie.prop)))==null?void 0:Vr.isHideInForm,Ie})),we}),Be=s.value,Je=(Jl=(xl=ll.safeClone(q))==null?void 0:xl.find(we=>(we==null?void 0:we.key)==="formContent"))==null?void 0:Jl.contents;if(Be=Be==null?void 0:Be.map(we=>{var ia,Ie;return(we==null?void 0:we.type)==="Select"&&((ia=we==null?void 0:we.allSelectionContents)==null?void 0:ia.length)>0&&(we.contactValue=ne),we.value=(Ie=Je==null?void 0:Je.find((pe,ha)=>((pe==null?void 0:pe.id)??ha)===(we==null?void 0:we.id)))==null?void 0:Ie.value,we}),!V.value){t("contentChange",{contents:q,index:n.index});return}let ra="",ba=(ja=(Pl=(kl=ll.safeClone(q))==null?void 0:kl.find(we=>(we==null?void 0:we.key)==="formContent"))==null?void 0:Pl.contents)==null?void 0:ja.find((we,ia)=>{var Ie,pe,ha;return(we==null?void 0:we.label)===Me.value||ia.toString()===((ha=(pe=(Ie=Me.value)==null?void 0:Ie.split("t"))==null?void 0:pe[1])==null?void 0:ha.toString())}),ga=(Ml=ba==null?void 0:ba.optionUrl)==null?void 0:Ml.menuSelect,Aa=!0;if((rl=(Ma=($l=ll.safeClone(q))==null?void 0:$l.find(we=>(we==null?void 0:we.key)==="formContent"))==null?void 0:Ma.contents)==null||rl.forEach(we=>{var ia,Ie,pe,ha,va,Xe;Aa&&((pe=(Ie=(ia=we==null?void 0:we.optionUrl)==null?void 0:ia.groupSelect)==null?void 0:Ie[1])!=null&&pe.includes("["))&&(ra=(va=(ha=we==null?void 0:we.optionUrl)==null?void 0:ha.groupSelect)==null?void 0:va[1],JSON.stringify(ga)===JSON.stringify((Xe=we==null?void 0:we.optionUrl)==null?void 0:Xe.menuSelect)&&(Aa=!1))}),(sl=ba==null?void 0:ba.optionUrl)!=null&&sl.menuSelect&&V.value){let we=await yt(ba),ia,Ie=(ma=ba==null?void 0:ba.optionUrl)==null?void 0:ma.menuSelect;if(we==null||we.forEach(pe=>{var ha,va,Xe,Ze,Ke,pl,Ve,Fa,Sa,il;ra===((va=(ha=ba==null?void 0:ba.optionUrl)==null?void 0:ha.groupSelect)==null?void 0:va[1])&&((Ke=(Ze=(Xe=ba==null?void 0:ba.optionUrl)==null?void 0:Xe.groupSelect)==null?void 0:Ze[1])!=null&&Ke.includes("["))&&((il=ll.safeClone(pe))==null?void 0:il[(Sa=(Fa=(Ve=(pl=ba==null?void 0:ba.optionUrl)==null?void 0:pl.groupSelect)==null?void 0:Ve[1])==null?void 0:Fa.replaceAll("[",""))==null?void 0:Sa.replaceAll("]","")])===(ba==null?void 0:ba.value)&&(ia=pe)}),ia){let pe=ll.safeClone(Be);pe=pe==null?void 0:pe.map(va=>{var Xe,Ze,Ke,pl,Ve,Fa,Sa,il,Ia,ze,_l;return(ia!=null&&ia[va==null?void 0:va.label]||ia!=null&&ia[(pl=(Ke=(Ze=(Xe=va==null?void 0:va.optionUrl)==null?void 0:Xe.groupSelect)==null?void 0:Ze[1])==null?void 0:Ke.replaceAll("[",""))==null?void 0:pl.replaceAll("]","")])&&((Sa=(Fa=(Ve=va==null?void 0:va.optionUrl)==null?void 0:Ve.groupSelect)==null?void 0:Fa[1])!=null&&Sa.includes("["))&&Ie!=null&&Ie.every(Ol=>{var ql,Wl;return(Wl=(ql=va==null?void 0:va.optionUrl)==null?void 0:ql.menuSelect)==null?void 0:Wl.includes(Ol)})&&(va.value=(ia==null?void 0:ia[va==null?void 0:va.label])||(ia==null?void 0:ia[(_l=(ze=(Ia=(il=va==null?void 0:va.optionUrl)==null?void 0:il.groupSelect)==null?void 0:Ia[1])==null?void 0:ze.replaceAll("[",""))==null?void 0:_l.replaceAll("]","")]),Array.isArray(va.value)&&va.value.every(Ol=>(Ol==null?void 0:Ol.url)&&(Ol==null?void 0:Ol.name))&&(va.type="Upload")),va}),pe=pe==null?void 0:pe.map(va=>{var Xe,Ze,Ke;return(Xe=va==null?void 0:va.optionUrl)!=null&&Xe.oldMenuSelect&&(va.optionUrl.menuSelect=(Ke=(Ze=ll.safeClone(va))==null?void 0:Ze.optionUrl)==null?void 0:Ke.oldMenuSelect),va}),s.value=ll.safeClone(pe);let ha=ll.safeClone(pe);ha=ha==null?void 0:ha.map(va=>{var Xe,Ze,Ke,pl,Ve,Fa;return(Ze=(Xe=va==null?void 0:va.optionUrl)==null?void 0:Xe.menuSelect)!=null&&Ze.some(Sa=>Sa==null?void 0:Sa.includes("["))&&(va.optionUrl.oldMenuSelect=(pl=(Ke=ll.safeClone(va))==null?void 0:Ke.optionUrl)==null?void 0:pl.menuSelect,va.optionUrl.menuSelect=(Fa=(Ve=va==null?void 0:va.optionUrl)==null?void 0:Ve.menuSelect)==null?void 0:Fa.map(Sa=>{var il,Ia,ze,_l;if(Sa!=null&&Sa.includes("[")){let Ol=(Ia=(il=Sa==null?void 0:Sa.replaceAll("[","").replaceAll("]",""))==null?void 0:il.split(":"))==null?void 0:Ia[1];Sa=(_l=(ze=ll.safeClone(pe))==null?void 0:ze.find(ql=>(ql==null?void 0:ql.label)===Ol))==null?void 0:_l.value}return Sa})),va}),s.value=ha}else s.value=Be;q=q==null?void 0:q.map(pe=>{var ha;return(pe==null?void 0:pe.key)==="formContent"&&(pe.contents=(ha=pe.contents)==null?void 0:ha.map(va=>{var Xe,Ze,Ke,pl;return va.value=((Ze=(Xe=s.value)==null?void 0:Xe.find(Ve=>(Ve==null?void 0:Ve.label)===(va==null?void 0:va.key)))==null?void 0:Ze.value)??(va==null?void 0:va.value),va.type=((pl=(Ke=s.value)==null?void 0:Ke.find(Ve=>(Ve==null?void 0:Ve.prop)===(va==null?void 0:va.key)))==null?void 0:pl.type)??(va==null?void 0:va.type),va})),pe})}V.value=!1,t("contentChange",{contents:q,index:n.index});let _a=[],Oe=[];if((La=ll.safeClone((ka=q==null?void 0:q.find(we=>(we==null?void 0:we.key)==="formContent"))==null?void 0:ka.contents))==null||La.forEach(we=>{var ia;Array.isArray(we==null?void 0:we.value)&&((ia=we==null?void 0:we.value)!=null&&ia.find(Ie=>{var pe;return(pe=Ie==null?void 0:Ie.url)==null?void 0:pe.includes(".obj")}))&&(Oe=we==null?void 0:we.value)}),(Oe==null?void 0:Oe.length)>0){const we=($a=ll.safeClone(Oe))==null?void 0:$a.filter(ia=>{var Ie;return(Ie=ia==null?void 0:ia.url)==null?void 0:Ie.includes(".obj")});we==null||we.forEach(ia=>{var pe,ha,va,Xe;const Ie=(pe=Oe==null?void 0:Oe.filter(Ze=>{var Ke;return(Ze==null?void 0:Ze.name)===(ia==null?void 0:ia.name)&&((Ke=Ze==null?void 0:Ze.url)==null?void 0:Ke.includes(".mtl"))}))==null?void 0:pe.map(Ze=>Ze==null?void 0:Ze.url);_a.push({objUrl:ia==null?void 0:ia.url,mtlUrls:((ha=Oe==null?void 0:Oe.filter(Ze=>{var Ke;return(Ze==null?void 0:Ze.name)===(ia==null?void 0:ia.name)&&((Ke=Ze==null?void 0:Ze.url)==null?void 0:Ke.includes(".mtl"))}))==null?void 0:ha.length)===1?(Xe=(va=Oe==null?void 0:Oe.filter(Ze=>{var Ke;return(Ze==null?void 0:Ze.name)===(ia==null?void 0:ia.name)&&((Ke=Ze==null?void 0:Ze.url)==null?void 0:Ke.includes(".mtl"))}))==null?void 0:va[0])==null?void 0:Xe.url:Ie})}),x.setObjUrl(_a)}},Qe=(ne,X,Z)=>{let q="";const Be=X==null?void 0:X.map(Je=>{var ra;return(ra=Je==null?void 0:Je.value)==null?void 0:ra.pageData});return Be==null||Be.forEach(Je=>{var ra;(Je==null?void 0:Je.name)===(ne==null?void 0:ne[0])&&((ra=Je==null?void 0:Je.compData)==null||ra.forEach(ba=>{var ga;(ba==null?void 0:ba.key)==="formContent"&&((ga=ba==null?void 0:ba.contents)==null||ga.forEach(Aa=>{var _a;(Aa==null?void 0:Aa.prop)===(ne==null?void 0:ne[1])&&(q=(Aa==null?void 0:Aa.value)===""?he.judgeContents((_a=ll.safeClone(Aa))==null?void 0:_a.optionUrl,Z):Aa==null?void 0:Aa.value)}))}))}),q},Va=(ne,X,Z,q)=>{var ba,ga;let Be="",Je="";(ba=ll.safeClone(X))==null||ba.forEach((Aa,_a)=>{Aa!=null&&Aa.includes("[")?Je=Je+Da.value+ne[_a]:Je=Je===""?Je+Aa:Je+"/"+Aa});let ra=(ga=q[Je])==null?void 0:ga.map(Aa=>{var _a;return(_a=Aa==null?void 0:Aa.value)==null?void 0:_a.pageData});return ra==null||ra.forEach(Aa=>{var _a;(Aa==null?void 0:Aa.name)===(Z==null?void 0:Z[0])&&((_a=Aa==null?void 0:Aa.compData)==null||_a.forEach(Oe=>{var Za;(Oe==null?void 0:Oe.key)==="formContent"&&((Za=Oe==null?void 0:Oe.contents)==null||Za.forEach(Ha=>{(Ha==null?void 0:Ha.prop)===(Z==null?void 0:Z[1])&&(Be=Ha==null?void 0:Ha.value)}))}))}),Be};return e.watch(()=>T==null?void 0:T.value,async()=>{await ca()},{immediate:!0}),e.watch(()=>n.itemData,async()=>{var Za,Ha,xl,Jl,kl,Pl,ja,Ml,$l,Ma,rl,sl,ma,ka,La,$a,we,ia,Ie,pe,ha,va,Xe;const ne=(Za=n.itemData)==null?void 0:Za.find(Ze=>(Ze==null?void 0:Ze.key)==="formContent"),X=(Ha=ll.safeClone(n.itemData))==null?void 0:Ha.find(Ze=>(Ze==null?void 0:Ze.key)==="formButton"),Z=(xl=ll.safeClone(n.itemData))==null?void 0:xl.find(Ze=>(Ze==null?void 0:Ze.key)==="formFlex"),q=(Jl=ll.safeClone(n.itemData))==null?void 0:Jl.find(Ze=>(Ze==null?void 0:Ze.key)==="formWrap"),Be=(kl=ll.safeClone(n.itemData))==null?void 0:kl.find(Ze=>(Ze==null?void 0:Ze.key)==="enableWrap"),Je=(Pl=ll.safeClone(n.itemData))==null?void 0:Pl.find(Ze=>(Ze==null?void 0:Ze.key)==="textSize"),ra=(ja=ll.safeClone(n.itemData))==null?void 0:ja.find(Ze=>(Ze==null?void 0:Ze.key)==="textRGBA"),ba=(Ml=ll.safeClone(n.itemData))==null?void 0:Ml.find(Ze=>(Ze==null?void 0:Ze.key)==="backGround"),ga=($l=ll.safeClone(n.itemData))==null?void 0:$l.find(Ze=>(Ze==null?void 0:Ze.key)==="backGroundImage");(q==null?void 0:q.contents)==="纵向"?c.value=!1:c.value=!0;const Aa=Number(Je==null?void 0:Je.contents);b.value=Number.isNaN(Aa)?void 0:Aa,w.value=ra==null?void 0:ra.contents,$.value=ba==null?void 0:ba.contents,F.value=ga==null?void 0:ga.contents;const _a=Be==null?void 0:Be.contents;if(_a===void 0?k.value=ri.BLOCK:typeof _a=="boolean"?k.value=_a?ri.ORDINARY:ri.BLOCK:k.value=_a,J.value=typeof(Z==null?void 0:Z.contents)!="boolean"?!(!(Z!=null&&Z.contents)===""||((Ma=Z==null?void 0:Z.contents)==null?void 0:Ma.toUpperCase())==="VERTICAL"):Z==null?void 0:Z.contents,((rl=ne==null?void 0:ne.contents)==null?void 0:rl.length)>0&&Array.isArray(ne==null?void 0:ne.contents)){let Ze=n.allMapContents;const Ke=(ma=(sl=ll.safeClone(ne))==null?void 0:sl.contents)==null?void 0:ma.map((ze,_l)=>{var Mr,Sr,Er,mn,Dr,ur,yn,ln,rn,_n,Bn,pn,lr;let Ol=(ze==null?void 0:ze.label)??(ze==null?void 0:ze.key)??"";ze==null||ze.type;let ql=(ze==null?void 0:ze.options)??[];if((Mr=ze==null?void 0:ze.key)!=null&&Mr.includes("$")&&(Ol=(Sr=ll.safeClone(ze==null?void 0:ze.key).split("$"))==null?void 0:Sr[0],((mn=(Er=ll.safeClone(ze==null?void 0:ze.key).split("$"))==null?void 0:Er[1])==null?void 0:mn.length)>0)){const[Il,Ar]=(ur=(Dr=ll.safeClone(ze==null?void 0:ze.key).split("$"))==null?void 0:Dr[1])==null?void 0:ur.split(/[()]/);(yn=he.FormType.find(cl=>(cl==null?void 0:cl.key)===Il))==null||yn.value,((ln=Ar==null?void 0:Ar.split(","))==null?void 0:ln.length)>0&&(ql=(rn=Ar==null?void 0:Ar.split(","))==null?void 0:rn.map(cl=>({label:cl,value:cl})))}let Wl=ze==null?void 0:ze.options;((_n=ze==null?void 0:ze.optionUrl)==null?void 0:_n.selectRelateType)==="自定义绑定"&&(Wl=(pn=(Bn=ze==null?void 0:ze.optionUrl)==null?void 0:Bn.defaultSelect)==null?void 0:pn.map(Il=>({label:Il,value:Il})));let Ql=(ze==null?void 0:ze.menuPath)??[],pr=(ze==null?void 0:ze.groups)??[],Ll=(ze==null?void 0:ze.columns)??[],fr=!1,Vr=(ze==null?void 0:ze.isFormColHidden)??!1,jl="",ar=ze!=null&&ze.value?ze.value:(Wl==null?void 0:Wl.length)>0?(lr=Wl==null?void 0:Wl[0])==null?void 0:lr.value:(ze==null?void 0:ze.value)??"",Fr=!1,Nr="Input";return((Wl==null?void 0:Wl.length)>0||(Ql==null?void 0:Ql.length)>0)&&(Nr="Select"),(Array.isArray(jl)&&(jl!=null&&jl.every(Il=>(Il==null?void 0:Il.name)&&(Il==null?void 0:Il.url)))||Array.isArray(ar)&&(ar!=null&&ar.every(Il=>(Il==null?void 0:Il.name)&&(Il==null?void 0:Il.url))))&&(Nr="upload"),ze!=null&&ze.isMainUrl&&(Nr="Url"),{label:Ol??"",name:Ol??"t"+_l,prop:Ol??ll.safeClone(ze==null?void 0:ze.key),type:(ze==null?void 0:ze.type)??Nr,value:(ze==null?void 0:ze.type)==="Date"&&ar===""?new Date:ar,id:(ze==null?void 0:ze.id)??_l,contents:(Wl==null?void 0:Wl.length)>0?Wl:ql??[],width:(ze==null?void 0:ze.width)??1,isLoginUser:fr,config:ze==null?void 0:ze.config,optionUrl:(ze==null?void 0:ze.optionUrl)??ze,isFormColHidden:Vr,isHideInForm:(ze==null?void 0:ze.isHideInForm)??!1,signature:Fr,isMain:ze==null?void 0:ze.isMain,required:(ze==null?void 0:ze.required)??!1,isMainUrl:ze==null?void 0:ze.isMainUrl,operable:(ze==null?void 0:ze.operable)??!1,disabled:(ze==null?void 0:ze.disabled)??!1,isSync:ze==null?void 0:ze.isSync,menus:Ql,groups:pr,words:Ll,allSelectionContents:ze==null?void 0:ze.allContents,filterContent:ze==null?void 0:ze.filterContents,isNoClick:(ze==null?void 0:ze.isNoClick)??!1}}),pl=Ke==null?void 0:Ke.map(ze=>ze==null?void 0:ze.value);let Ve="";pl==null||pl.forEach(ze=>{ze!==""&&ze!==void 0&&(Ve=Ve===""?ze:Ve+"/"+ze)}),E.setSelectArray(pl),E.setSelectString(Ve);let Fa=(ka=ll.safeClone(Ke))==null?void 0:ka.map(ze=>(ze!=null&&ze.value&&he.IsJson(ze==null?void 0:ze.value)&&Array.isArray(JSON.parse(ze==null?void 0:ze.value))&&(ze.value=JSON.parse(ze.value)),ze)),Sa={};Fa==null||Fa.forEach(ze=>{Sa[ze.label]=ze==null?void 0:ze.value}),Fa=Fa==null?void 0:Fa.map(ze=>{var _l,Ol,ql,Wl,Ql,pr,Ll,fr,Vr;if((ze==null?void 0:ze.type)==="Select"&&((_l=ze==null?void 0:ze.allSelectionContents)==null?void 0:_l.length)>0&&(ze.contactValue=Sa),(ql=(Ol=ze==null?void 0:ze.optionUrl)==null?void 0:Ol.menuSelect)!=null&&ql.some(jl=>jl==null?void 0:jl.includes("["))){let jl="";ze.optionUrl.oldMenuSelect=(Ql=(Wl=ll.safeClone(ze))==null?void 0:Wl.optionUrl)==null?void 0:Ql.menuSelect,ze.optionUrl.menuSelect=(Ll=(pr=ze==null?void 0:ze.optionUrl)==null?void 0:pr.menuSelect)==null?void 0:Ll.map(ar=>{var Fr,Nr,Pr,Mr,Sr,Er;if(ar!=null&&ar.includes("[")){let mn=(Nr=(Fr=ar==null?void 0:ar.replaceAll("[","").replaceAll("]",""))==null?void 0:Fr.split(":"))==null?void 0:Nr[1];jl=Qe((Pr=ar==null?void 0:ar.replaceAll("[","").replaceAll("]",""))==null?void 0:Pr.split(":"),Ze==null?void 0:Ze[Pe.value],Ze),ar=((Sr=(Mr=ll.safeClone(Fa))==null?void 0:Mr.find(Dr=>(Dr==null?void 0:Dr.label)===mn))==null?void 0:Sr.value)||Qe((Er=ar==null?void 0:ar.replaceAll("[","").replaceAll("]",""))==null?void 0:Er.split(":"),Ze==null?void 0:Ze[Pe.value],Ze)}return ar}),jl!==""&&ze.value===""&&(ze.value=Va(ze.optionUrl.menuSelect,ze.optionUrl.oldMenuSelect,(fr=ze==null?void 0:ze.optionUrl)==null?void 0:fr.groupSelect,Ze),Array.isArray(ze.value)&&((Vr=ze.value)!=null&&Vr.every(ar=>ar==null?void 0:ar.url))&&(ze.type="UPLOAD"))}return ze}),s.value=Fa,Se.value=((La=s.value)==null?void 0:La.every(ze=>ze==null?void 0:ze.disabled))||ye.value===Pe.value,U.value=($a=s.value)==null?void 0:$a.every(ze=>ze==null?void 0:ze.operable),Ee.value=(we=s.value)==null?void 0:we.map(ze=>ze==null?void 0:ze.label);let il=[],Ia=[];if((ia=ll.safeClone(s.value))==null||ia.forEach(ze=>{var _l;Array.isArray(ze==null?void 0:ze.value)&&((_l=ze==null?void 0:ze.value)!=null&&_l.find(Ol=>{var ql;return(ql=Ol==null?void 0:Ol.url)==null?void 0:ql.includes(".obj")}))&&(Ia=ze==null?void 0:ze.value)}),(Ia==null?void 0:Ia.length)>0){const ze=(Ie=ll.safeClone(Ia))==null?void 0:Ie.filter(_l=>{var Ol;return(Ol=_l==null?void 0:_l.url)==null?void 0:Ol.includes(".obj")});ze==null||ze.forEach(_l=>{var ql,Wl,Ql,pr;const Ol=(ql=Ia==null?void 0:Ia.filter(Ll=>{var fr;return(Ll==null?void 0:Ll.name)===(_l==null?void 0:_l.name)&&((fr=Ll==null?void 0:Ll.url)==null?void 0:fr.includes(".mtl"))}))==null?void 0:ql.map(Ll=>Ll==null?void 0:Ll.url);il.push({objUrl:_l==null?void 0:_l.url,mtlUrls:((Wl=Ia==null?void 0:Ia.filter(Ll=>{var fr;return(Ll==null?void 0:Ll.name)===(_l==null?void 0:_l.name)&&((fr=Ll==null?void 0:Ll.url)==null?void 0:fr.includes(".mtl"))}))==null?void 0:Wl.length)===1?(pr=(Ql=Ia==null?void 0:Ia.filter(Ll=>{var fr;return(Ll==null?void 0:Ll.name)===(_l==null?void 0:_l.name)&&((fr=Ll==null?void 0:Ll.url)==null?void 0:fr.includes(".mtl"))}))==null?void 0:Ql[0])==null?void 0:pr.url:Ol})}),x.setObjUrl(il)}(pe=ll.safeClone(s.value))==null||pe.forEach(ze=>{var _l,Ol,ql,Wl,Ql,pr,Ll,fr,Vr,jl,ar,Fr,Nr;if((Ol=(_l=ze==null?void 0:ze.value)==null?void 0:_l.toString())!=null&&Ol.includes(".stl")||(Wl=(ql=ze==null?void 0:ze.value)==null?void 0:ql.toString())!=null&&Wl.includes(".STL")||(pr=(Ql=ze==null?void 0:ze.value)==null?void 0:Ql.toString())!=null&&pr.includes(".obj")||(fr=(Ll=ze==null?void 0:ze.value)==null?void 0:Ll.toString())!=null&&fr.includes(".mtl")||(jl=(Vr=ze==null?void 0:ze.value)==null?void 0:Vr.toString())!=null&&jl.includes(".urdf")){let Pr={},Mr=[],Sr;Array.isArray(ze==null?void 0:ze.value)?Sr=ze==null?void 0:ze.value:Sr=(ar=ze==null?void 0:ze.value)==null?void 0:ar.split(","),Sr==null||Sr.forEach(Er=>{Er.includes(".mtl")?Mr.push(Er):Pr.blob=Pr.blob==="undefined"?Er:Pr.blob+","+Er}),(Mr==null?void 0:Mr.length)>0&&(Pr.mtlBlobs=Mr),(Nr=(Fr=Object.values(Pr))==null?void 0:Fr[0])!=null&&Nr.includes("http:")}})}else s.value=[];let Oe=ae.value;if((Oe==null?void 0:Oe.length)>0&&(Oe=Oe==null?void 0:Oe.map(Ze=>{var pl,Ve,Fa,Sa;let Ke=(pl=Ze==null?void 0:Ze.key)==null?void 0:pl.split("/");return(n==null?void 0:n.compName)===(Ke==null?void 0:Ke[0])&&(Ve=s.value)!=null&&Ve.find(il=>(il==null?void 0:il.prop)===(Ke==null?void 0:Ke[1]))&&(Ze.value=(Sa=(Fa=s.value)==null?void 0:Fa.find(il=>(il==null?void 0:il.prop)===(Ke==null?void 0:Ke[1])))==null?void 0:Sa.value),Ze}),fe.setTableViewContents(Oe)),n!=null&&n.formRules)g.value=n==null?void 0:n.formRules;else{let Ze={};(ha=ll.safeClone(s).value)==null||ha.forEach(Ke=>{((Ke==null?void 0:Ke.isMain)===!0||(Ke==null?void 0:Ke.required)===!0)&&(Ze[(Ke==null?void 0:Ke.prop)??(Ke==null?void 0:Ke.name)]=[{required:!0,message:`${(Ke==null?void 0:Ke.label)||(Ke==null?void 0:Ke.prop)||(Ke==null?void 0:Ke.name)}不能为空`}])}),g.value=Ze}if(((va=X==null?void 0:X.contents)==null?void 0:va.length)>0){const Ze=[];(Xe=X==null?void 0:X.contents)==null||Xe.forEach((Ke,pl)=>{(Ke==null?void 0:Ke.label)!==""&&Ze.push({label:(Ke==null?void 0:Ke.label)??"",id:(Ke==null?void 0:Ke.id)??pl,type:(Ke==null?void 0:Ke.type)??"",background:Ke==null?void 0:Ke.background})}),K.value=Ze}else K.value=[]},{deep:!0,immediate:!0}),e.watch(()=>ye.value,ne=>{Se.value=ne===Pe.value},{immediate:!0}),(ne,X)=>{var ba;const Z=e.resolveComponent("svg-icon"),q=e.resolveComponent("el-switch"),Be=e.resolveComponent("el-checkbox"),Je=e.resolveComponent("el-popover"),ra=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",j3,[k.value===e.unref(ri).TEXT?(e.openBlock(),e.createBlock(Nc,{key:0,itemData:a.itemData,compName:a.compName,fields:s.value,textSize:b.value,textColor:w.value,backGround:$.value,backGroundImage:F.value,disabled:Se.value||te(),"onUpdate:backGroundImage":pa},null,8,["itemData","compName","fields","textSize","textColor","backGround","backGroundImage","disabled"])):k.value===e.unref(ri).BLOCK?(e.openBlock(),e.createBlock(Ef,{key:1,items:(ba=s.value)==null?void 0:ba.map(ga=>({label:ga!=null&&ga.isHideInForm?"":ga==null?void 0:ga.label,value:ga==null?void 0:ga.value,width:(ga==null?void 0:ga.width)??1,field:ga})),textSize:b.value,textColor:w.value,backGround:$.value,backGroundImage:F.value,disabled:Se.value||te(),"onUpdate:backGroundImage":pa},null,8,["items","textSize","textColor","backGround","backGroundImage","disabled"])):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass({"form-shadow-box":k.value===e.unref(ri).ORDINARY})},[e.createVNode(ll.ssForm,{rowContents:s.value,formRules:g.value,buttonValue:K.value,isRowFlex:!1,isEnableWrap:!0,textSize:b.value,textColor:w.value,backGround:$.value,backGroundImage:F.value,onOnButtonClick:Ta,onChange:Ca,formDisabled:Se.value||te(),formLabelsOperable:U.value,isButtonRow:c.value,onPreview:Ne,onBlurChange:ce,onHandleColEditChange:ve,onHandleColTypeChange:da,onRouteUrl:H,onClickTrigger:L,"onUpdate:backGroundImage":pa},{operateCol:e.withCtx(({renderColumns:ga,formDisabled:Aa,formLabelsOperable:_a})=>[e.createVNode(Je,{title:"选择操作的标签",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:oa},{reference:e.withCtx(()=>[e.createElementVNode("span",H3,[e.createVNode(Z,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"}})])]),default:e.withCtx(()=>[e.createElementVNode("div",U3,[X[1]||(X[1]=e.createElementVNode("div",{class:"group-title"},"表单操作",-1)),e.createVNode(q,{"model-value":Aa,"active-text":"禁用","inactive-text":"",onChange:Te,style:{"margin-right":"8px"}},null,8,["model-value"]),e.createVNode(q,{"model-value":_a,"active-text":"编辑所有标签","inactive-text":"",onChange:Ue},null,8,["model-value"]),X[2]||(X[2]=e.createElementVNode("div",{class:"group-title"},"表单列操作",-1)),e.createVNode(ra,{modelValue:Ee.value,"onUpdate:modelValue":X[0]||(X[0]=Oe=>Ee.value=Oe),style:{height:"100%"},ref_key:"checkboxGroupRef",ref:ue,onChange:Ja},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ga,Oe=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:Oe.label},[e.createVNode(Be,{value:Oe.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(Oe.label),1)]),_:2},1032,["value"]),e.createVNode(Je,{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 Za;return[e.createElementVNode("div",q3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Za=Object.keys(Oe))==null?void 0:Za.filter(Ha=>{var xl;return(xl=oe.value)==null?void 0:xl.find(Jl=>(Jl==null?void 0:Jl.value)===Ha)}),Ha=>{var xl,Jl;return e.openBlock(),e.createElementBlock("div",{key:Ha},[e.createVNode(ll._sfc_main$1,{value:Oe==null?void 0:Oe[Ha],"active-text":(Jl=(xl=oe.value)==null?void 0:xl.find(kl=>(kl==null?void 0:kl.value)===Ha))==null?void 0:Jl.label,inactiveText:"",onChange:kl=>ea(kl,Ha,Oe)},null,8,["value","active-text","onChange"])])}),128))])]}),_:2},1024),e.createElementVNode("span",W3,[e.createVNode(Z,{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"])],2)),D.value?(e.openBlock(),e.createBlock(ll.ssFilePreview,{key:3,fileDataList:I.value,onDestroy:We},null,8,["fileDataList"])):e.createCommentVNode("",!0),v.value?(e.openBlock(),e.createBlock(wr.ssDialog,{key:4,visible:v.value,onBeforeDestroy:r,style:{height:"700px",width:"1000px"}},{default:e.withCtx(()=>[e.createVNode(So.ThreeViewerHost,{files:p.value,onGetAnimationData:ne.onAnimationData},null,8,["files","onGetAnimationData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0)])}}},ks=Zl._export_sfc(K3,[["__scopeId","data-v-7bb009b3"]]),zo=e.ref(0),Tc=a=>{var l;return!a||(a==null?void 0:a.length)===0?[]:(l=A.cloneDeep(a))==null?void 0:l.map(n=>(zo.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)??zo.value,children:Tc(n==null?void 0:n.children)},n))},G3=a=>{var r;return(r=A.cloneDeep(a))==null?void 0:r.map(n=>(zo.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)??zo.value,children:Tc(n==null?void 0:n.children)},n))},Ac=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===l)?(r=A.cloneDeep(a))==null?void 0:r.filter(t=>(t==null?void 0:t.id)!==l):(a=a==null?void 0:a.map(n=>(n.children=Ac(n==null?void 0:n.children,l),n)),a)},zc=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===(l==null?void 0:l.id))?(r=A.cloneDeep(a))==null?void 0:r.map(t=>((t==null?void 0:t.id)===(l==null?void 0:l.id)&&(t=l),t)):(a=a==null?void 0:a.map(n=>(n.children=zc(n==null?void 0:n.children,l),n)),a)},Mc=(a,l)=>{var r;return a!=null&&a.find(n=>{var t;return(n==null?void 0:n.id)===((t=l==null?void 0:l.contents)==null?void 0:t.id)})?(r=A.cloneDeep(a))==null?void 0:r.map(t=>{var s;return(t==null?void 0:t.id)===((s=l==null?void 0:l.contents)==null?void 0:s.id)&&(t=l==null?void 0:l.contents),t}):(a=a==null?void 0:a.map(n=>(n.children=Mc(n==null?void 0:n.children,l),n)),a)},Ic=(a,l)=>{var r;return a!=null&&a.find(n=>(n==null?void 0:n.id)===(l==null?void 0:l.id))?(r=A.cloneDeep(a))==null?void 0:r.map(t=>((t==null?void 0:t.id)===(l==null?void 0:l.id)&&(t!=null&&t.children||(t.children=[]),t.children.push(l.contents)),t)):(a=a==null?void 0:a.map(n=>(n.children=Ic(n==null?void 0:n.children,l),n)),a)},or=[{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"}],Y3=[{label:"查看",value:"view"},{label:"修改",value:"fix"},{label:"删除",value:"delete"},{label:"三维算例",value:"modelExample"}],J3=[{label:"新增",value:"add"}],Mn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:J3},{key:"background",label:"按钮背景色",type:"Color"}],In=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:Y3},{key:"textColor",label:"按钮颜色",type:"Color"}],X3={class:"table-header-child"},Z3={class:"table-header-child-main"},Q3={class:"table-header-child-content"},eh={class:"table-header-child-content-item"},ah={class:"fix-button"},lh={key:0},rh={class:"form-content"},nh={__name:"tableNewChild",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const r=a,n=l,t=e.ref(!1),s=e.ref(""),v=he.useTableComp(A.pinia),{tableIndex:d}=A.storeToRefs(v);e.ref(0);const p=e.ref(""),y=e.ref([]),g=e.ref([]),c=E=>{var k;t.value=!0;let x=[];or==null||or.forEach(b=>{let w=A.cloneDeep(d.value)+1;v.setTableIndex(w),x.push({label:b==null?void 0:b.label,name:b==null?void 0:b.label,type:b.type,value:E[b.key],id:d.value,contents:b==null?void 0:b.options})}),E!=null&&E.children&&((k=E==null?void 0:E.children)==null?void 0:k.length)>0&&x.push({children:E==null?void 0:E.children,isFormColHidden:!0}),p.value=E==null?void 0:E.id,y.value=x,g.value=x},D=E=>{n("fixChange",A.cloneDeep(E))},M=E=>{n("deleteChange",A.cloneDeep(E))},S=E=>{t.value=!0;let x=[];or==null||or.forEach(k=>{let b=A.cloneDeep(d.value)+1;v.setTableIndex(b),x.push({label:k==null?void 0:k.label,name:k==null?void 0:k.label,type:k.type,value:"",id:d.value,contents:k==null?void 0:k.options})}),s.value=E==null?void 0:E.id,y.value=x,g.value=x},K=E=>{let x=A.cloneDeep(g.value);x=x==null?void 0:x.map(k=>(k.children||(k.value=E==null?void 0:E[k.name]),k)),g.value=x},I=()=>{var x,k;y.value=g.value;let E={};if(p.value!=="")E.id=p.value,(x=y.value)==null||x.forEach(b=>{const w=or==null?void 0:or.find($=>($==null?void 0:$.label)===(b==null?void 0:b.label));w?E[w.key]=b.value:b!=null&&b.children&&b.children.length>0&&(E.children=b.children)}),t.value=!1,n("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"fix"});else{let b=A.cloneDeep(d.value)+1;v.setTableIndex(b),E.id="id"+d.value,(k=y.value)==null||k.forEach(w=>{const $=or==null?void 0:or.find(F=>(F==null?void 0:F.label)===(w==null?void 0:w.label));$?E[$.key]=w.value:w!=null&&w.children&&w.children.length>0&&(E.children=w.children)}),t.value=!1,n("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"add"})}p.value="",y.value=[],g.value=[]},R=()=>{t.value=!1,p.value="",s.value="",y.value=[],g.value=[]},j=E=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{n("deleteChange",E),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(E,x)=>{const k=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",X3,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r==null?void 0:r.tableChildContents,(b,w)=>(e.openBlock(),e.createElementBlock("div",Z3,[e.createElementVNode("div",Q3,[e.createElementVNode("div",eh,e.toDisplayString(b.label),1),e.createElementVNode("div",ah,[e.createVNode(k,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:$=>S(b)},null,8,["onClick"]),e.createVNode(k,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:$=>c(b)},null,8,["onClick"]),e.createVNode(k,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:$=>j(b)},null,8,["onClick"])])]),b!=null&&b.children&&b.children.length>0?(e.openBlock(),e.createElementBlock("div",lh,[e.createVNode(Oc,{tableChildContents:b==null?void 0:b.children,onDeleteChange:M,onFixChange:D},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode(wr.ssDialog,{visible:t.value,onBeforeDestroy:R,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",rh,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:y.value,key:y.value,isEnableWrap:!0,onChange:K},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:R,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:I},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},ih=Zl._export_sfc(nh,[["__scopeId","data-v-e0fef72d"]]),oh={class:"table-header-child"},th={class:"table-header-child-main"},sh={class:"table-header-child-content"},ch={class:"table-header-child-content-item"},uh={class:"fix-button"},dh={key:0},ph={class:"form-content"},fh={class:"dialog-footer"},hh={__name:"tableChildren",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const r=a,n=l,t=e.ref(!1),s=e.ref(""),v=he.useTableComp(A.pinia),{tableIndex:d}=A.storeToRefs(v),p=e.ref(""),y=e.ref([]),g=e.ref([]),c=E=>{n("fixChange",A.cloneDeep(E))},D=E=>{var k;t.value=!0;let x=[];or==null||or.forEach(b=>{let w=A.cloneDeep(d.value)+1;v.setTableIndex(w),x.push({label:b==null?void 0:b.label,name:b==null?void 0:b.label,type:b.type,value:E[b.key],id:d.value,contents:b==null?void 0:b.options})}),E!=null&&E.children&&((k=E==null?void 0:E.children)==null?void 0:k.length)>0&&x.push({children:E==null?void 0:E.children,isFormColHidden:!0}),p.value=E==null?void 0:E.id,y.value=x,g.value=x},M=E=>{t.value=!0;let x=[];or==null||or.forEach(k=>{let b=A.cloneDeep(d.value)+1;v.setTableIndex(b),x.push({label:k==null?void 0:k.label,name:k==null?void 0:k.label,type:k.type,value:"",id:d.value,contents:k==null?void 0:k.options})}),s.value=E==null?void 0:E.id,y.value=x,g.value=x},S=E=>{let x=A.cloneDeep(g.value);x=x==null?void 0:x.map(k=>(k.children||(k.value=E==null?void 0:E[k.name]),k)),g.value=x},K=()=>{var x,k;y.value=g.value;let E={};if(p.value!=="")E.id=p.value,(x=y.value)==null||x.forEach(b=>{const w=or==null?void 0:or.find($=>($==null?void 0:$.label)===(b==null?void 0:b.label));w?E[w.key]=b.value:b!=null&&b.children&&b.children.length>0&&(E.children=b.children)}),t.value=!1,n("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"fix"});else{let b=A.cloneDeep(d.value)+1;v.setTableIndex(b),E.id="idChild"+d.value,(k=y.value)==null||k.forEach(w=>{const $=or==null?void 0:or.find(F=>(F==null?void 0:F.label)===(w==null?void 0:w.label));$?E[$.key]=w.value:w!=null&&w.children&&w.children.length>0&&(E.children=w.children)}),t.value=!1,n("fixChange",{contents:A.cloneDeep(E),id:s.value,type:"add"})}p.value="",y.value=[],g.value=[]},I=()=>{t.value=!1,p.value="",s.value="",y.value=[],g.value=[]},R=E=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{n("deleteChange",E),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},j=E=>{n("deleteChange",E)};return(E,x)=>{const k=e.resolveComponent("svg-icon"),b=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",oh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r==null?void 0:r.tableChildContents,(w,$)=>(e.openBlock(),e.createElementBlock("div",th,[e.createElementVNode("div",sh,[e.createElementVNode("div",ch,e.toDisplayString(w.label),1),e.createElementVNode("div",uh,[e.createVNode(k,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:F=>M(w)},null,8,["onClick"]),e.createVNode(k,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:F=>D(w)},null,8,["onClick"]),e.createVNode(k,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:F=>R(w)},null,8,["onClick"])])]),w!=null&&w.children&&w.children.length>0?(e.openBlock(),e.createElementBlock("div",dh,[e.createVNode(ih,{tableChildContents:w==null?void 0:w.children,onDeleteChange:j,onFixChange:c},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode(wr.ssDialog,{visible:t.value,onBeforeDestroy:I,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",ph,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:y.value,key:y.value,isEnableWrap:!0,onChange:S},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",fh,[e.createVNode(b,{onClick:I,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>x[0]||(x[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(b,{class:"ok-button button",onClick:K,id:"themeButton"},{default:e.withCtx(()=>x[1]||(x[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},Oc=Zl._export_sfc(hh,[["__scopeId","data-v-ebd68fa1"]]),vh={class:"table-operate-content"},mh={class:"table-operate-item"},yh={class:"operate-title"},gh={class:"operate-content"},bh={class:"fix-content"},kh={class:"fix-content-label"},xh={class:"fix-button"},wh={key:0},_h={class:"operate-title"},Sh={class:"operate-content"},Eh={class:"fix-content"},Ch={class:"fix-content-label"},Dh={class:"fix-button"},Bh={class:"operate-title"},Nh={class:"operate-content"},Th={class:"fix-content"},Ah={class:"fix-content-label"},zh={class:"fix-button"},Mh={class:"operate-title"},Ih={class:"operate-content"},Oh={class:"fix-content"},Lh={class:"fix-content-label"},Rh={class:"fix-button"},$h={class:"operate-content"},Vh={style:{display:"flex","justify-content":"space-between"}},Fh={class:"form-content"},Ph={class:"dialog-footer"},jh={class:"form-content"},Hh={class:"dialog-footer"},Uh={class:"form-content"},qh={class:"dialog-footer"},Wh={class:"form-content"},Kh={class:"dialog-footer"},Gh={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,t=e.ref([]),s=e.ref(!1),v=e.ref(!1),d=e.ref([]),p=e.ref(!1),y=e.ref([]),g=e.ref(!1),c=e.ref([]),D=e.ref(""),M=e.ref(""),S=e.ref([]),K=e.ref([]),I=e.ref([]),R=e.ref([]),j=e.ref(!1),E=e.ref([]),x=e.ref([]),k=e.ref(0),b=e.ref([]),w=e.ref([]),$=e.ref([]),F=()=>{j.value=!0;let L=[];Mn==null||Mn.forEach(H=>{k.value++,L.push({label:H==null?void 0:H.label,name:H==null?void 0:H.label,type:H.type,value:(H==null?void 0:H.key)==="background"?"var(--ssComponent-primary-color)":"",id:k.value,contents:H==null?void 0:H.options})}),E.value=L,x.value=L},J=()=>{var H,Q,me;v.value=!0;let L=[];(me=(Q=(H=he.FormContent)==null?void 0:H.find(ve=>(ve==null?void 0:ve.key)==="Input"))==null?void 0:Q.value)==null||me.forEach(ve=>{k.value++,L.push({label:ve==null?void 0:ve.label,name:(ve==null?void 0:ve.name)||(ve==null?void 0:ve.label),type:ve.type,value:(ve==null?void 0:ve.label)==="类型"?"Input":"",id:k.value,contents:ve==null?void 0:ve.options})}),b.value=L,w.value=L},se=L=>{L||(b.value=w.value)},ge=async L=>{var H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca;if((L==null?void 0:L.类型)!==((Q=(H=w.value)==null?void 0:H.find(Qe=>(Qe==null?void 0:Qe.label)==="类型"))==null?void 0:Q.value)){let Qe=[],Va=await((da=(ve=(me=he.FormContent)==null?void 0:me.find(ne=>(ne==null?void 0:ne.key)===((L==null?void 0:L.类型)===""?"Input":L==null?void 0:L.类型)))==null?void 0:ve.value)==null?void 0:da.value)?await((We=(Ne=(pa=he.FormContent)==null?void 0:pa.find(ne=>(ne==null?void 0:ne.key)===((L==null?void 0:L.类型)===""?"Input":L==null?void 0:L.类型)))==null?void 0:Ne.value)==null?void 0:We.value):(ce=(ea=he.FormContent)==null?void 0:ea.find(ne=>(ne==null?void 0:ne.key)===((L==null?void 0:L.类型)===""?"Input":L==null?void 0:L.类型)))==null?void 0:ce.value;if(Va==null||Va.forEach(ne=>{k.value++,Qe.push({label:ne==null?void 0:ne.label,name:(ne==null?void 0:ne.name)||(ne==null?void 0:ne.label),type:ne.type,value:ne!=null&&ne.属性名?(L==null?void 0:L.prop)||(L==null?void 0:L.name)||(L==null?void 0:L.label):(L==null?void 0:L[ne.label])??"",id:k.value,contents:ne==null?void 0:ne.options,prop:(ne==null?void 0:ne.prop)||(ne==null?void 0:ne.name)||(ne==null?void 0:ne.label)})}),L!=null&&L.菜单选项&&((Ta=L==null?void 0:L.菜单选项)==null?void 0:Ta.length)>0){const ne=await he.menuToContentType(L==null?void 0:L.菜单选项);Qe=Qe==null?void 0:Qe.map(X=>((X==null?void 0:X.name)==="组信息选项"&&(X.contents=ne),X))}w.value=await he.selectToBase(A.cloneDeep(Qe)),b.value=await he.selectToBase(A.cloneDeep(Qe))}else{let Qe=A.cloneDeep(b.value);if(Qe=Qe==null?void 0:Qe.map(Va=>(Va.value=L==null?void 0:L[Va.name],Va)),L!=null&&L.菜单选项&&((Ca=L==null?void 0:L.菜单选项)==null?void 0:Ca.length)>0){const Va=await he.menuToContentType(L==null?void 0:L.菜单选项);Qe=Qe==null?void 0:Qe.map(ne=>((ne==null?void 0:ne.name)==="组信息选项"&&(ne.contents=Va),ne))}Qe=he.formToOptionsContents(Qe),w.value=await he.selectToBase(A.cloneDeep(Qe))}},Me=async L=>{await ge(L),b.value=w.value},V=(L,H)=>{if((H==null?void 0:H.type)=="Select"&&(L==null?void 0:L.key)==="selectRelateType"){const Q=H==null?void 0:H.optionUrl;return(Q==null?void 0:Q.selectRelateType)||H[L.key]}if((H==null?void 0:H.type)=="Select"&&(L==null?void 0:L.key)==="menuSelect"){const Q=H==null?void 0:H.optionUrl;return(Q==null?void 0:Q.menuSelect)||H[L.key]}if((H==null?void 0:H.type)=="Select"&&(L==null?void 0:L.key)==="groupSelect"){const Q=H==null?void 0:H.optionUrl;return(Q==null?void 0:Q.groupSelect)||H[L.key]}if((H==null?void 0:H.type)=="Select"&&(L==null?void 0:L.key)==="originalContent")return(H==null?void 0:H.value)||H[L.key];if((H==null?void 0:H.type)=="Select"&&(L==null?void 0:L.key)==="multiple"){const Q=H[L.key];return Xs(Q)?Q:L.default}return(L==null?void 0:L.label)==="类型"&&H[L.key]===""?"Input":(L==null?void 0:L.key)==="isFormColHidden"&&!H[L.key]?!1:H[L.key]},fe=async L=>{var me,ve,da,ea,ce,pa,Ne,We,Ta;v.value=!0;let H=[];const Q=await((da=(ve=(me=he.FormContent)==null?void 0:me.find(Ca=>(Ca==null?void 0:Ca.key)===((L==null?void 0:L.type)===""?"Input":L==null?void 0:L.type)))==null?void 0:ve.value)==null?void 0:da.value)?await((We=(Ne=(pa=he.FormContent)==null?void 0:pa.find(Ca=>(Ca==null?void 0:Ca.key)===((L==null?void 0:L.type)===""?"Input":L==null?void 0:L.type)))==null?void 0:Ne.value)==null?void 0:We.value):(ce=(ea=he.FormContent)==null?void 0:ea.find(Ca=>(Ca==null?void 0:Ca.key)===((L==null?void 0:L.type)===""?"Input":L==null?void 0:L.type)))==null?void 0:ce.value;if(Q==null||Q.forEach(Ca=>{k.value++,H.push({label:Ca==null?void 0:Ca.label,name:(Ca==null?void 0:Ca.name)||(Ca==null?void 0:Ca.label),type:Ca.type,value:(Ca==null?void 0:Ca.label)==="属性名"?(L==null?void 0:L.prop)||(L==null?void 0:L.name)||(L==null?void 0:L.label):V(Ca,L),id:k.value,contents:Ca==null?void 0:Ca.options})}),L!=null&&L.menuSelect&&((Ta=L==null?void 0:L.menuSelect)==null?void 0:Ta.length)>0){const Ca=await he.menuToContentType(L==null?void 0:L.menuSelect);H=H==null?void 0:H.map(Qe=>((Qe==null?void 0:Qe.name)==="组信息选项"&&(Qe.contents=Ca),Qe))}D.value=L==null?void 0:L.id,b.value=await he.selectToBase(he.formToOptionsContents(H)),w.value=await he.selectToBase(he.formToOptionsContents(H))},ae=L=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,Q;$.value=(H=A.cloneDeep($.value))==null?void 0:H.filter(me=>(me==null?void 0:me.id)!==(L==null?void 0:L.id)),n("change",(Q=A.cloneDeep(r.originalItemContents))==null?void 0:Q.map(me=>((me==null?void 0:me.key)==="tableToForm"&&(me.contents=$.value),me))),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},de=()=>{v.value=!1,b.value=[],D.value=""},De=async()=>{var me,ve,da,ea,ce,pa,Ne,We,Ta,Ca;b.value=w.value;let L={};D.value!==""?L.id=D.value:(k.value++,L.id="id"+k.value);let H=await((da=(ve=(me=he.FormContent)==null?void 0:me.find(Qe=>{var Va,ne;return(Qe==null?void 0:Qe.key)===(((ne=(Va=b.value)==null?void 0:Va.find(X=>(X==null?void 0:X.label)==="类型"))==null?void 0:ne.value)??"label")}))==null?void 0:ve.value)==null?void 0:da.value)??((ce=(ea=he.FormContent)==null?void 0:ea.find(Qe=>{var Va,ne;return(Qe==null?void 0:Qe.key)===(((ne=(Va=b.value)==null?void 0:Va.find(X=>(X==null?void 0:X.label)==="类型"))==null?void 0:ne.value)??"label")}))==null?void 0:ce.value);if((pa=b.value)==null||pa.forEach(Qe=>{const Va=H==null?void 0:H.find(ne=>(ne==null?void 0:ne.label)===(Qe==null?void 0:Qe.label));Va&&(L[Va.key]=Qe.value)}),L.name=L.label,(Ne=$.value)!=null&&Ne.find(Qe=>Qe.id===L.id))$.value=(We=$.value)==null?void 0:We.map(Qe=>(Qe.id===L.id&&(Qe=L),Qe));else{let Qe=A.cloneDeep($.value);$.value||($.value=[]),Qe.push(L),$.value=Qe}$.value=$.value.map(({id:Qe,...Va})=>Va),v.value=!1,D.value="";let Q=A.cloneDeep(r.originalItemContents);(Ta=A.cloneDeep(r.originalItemContents))!=null&&Ta.find(Qe=>(Qe==null?void 0:Qe.key)==="tableToForm")?Q=(Ca=A.cloneDeep(r.originalItemContents))==null?void 0:Ca.map(Qe=>((Qe==null?void 0:Qe.key)==="tableToForm"&&(Qe.contents=$.value),Qe)):Q.push({key:"tableToForm",contents:$.value}),n("change",Q)},Fe=L=>{j.value=!0;let H=[];Mn==null||Mn.forEach(Q=>{k.value++,H.push({label:Q==null?void 0:Q.label,name:Q==null?void 0:Q.label,type:Q.type,value:L[Q.key],id:k.value,contents:Q==null?void 0:Q.options})}),D.value=L==null?void 0:L.id,E.value=H,x.value=H};e.watch(()=>g.value,()=>{var H,Q;let L=A.cloneDeep(r.originalItemContents);(H=A.cloneDeep(r.originalItemContents))!=null&&H.find(me=>(me==null?void 0:me.key)==="page")?L=(Q=A.cloneDeep(r.originalItemContents))==null?void 0:Q.map(me=>((me==null?void 0:me.key)==="page"&&(me.contents=g.value),me)):L.push({key:"page",contents:g.value}),n("change",L)},{deep:!0});const ye=L=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,Q;K.value=(H=A.cloneDeep(K.value))==null?void 0:H.filter(me=>(me==null?void 0:me.id)!==(L==null?void 0:L.id)),n("change",(Q=A.cloneDeep(r.originalItemContents))==null?void 0:Q.map(me=>((me==null?void 0:me.key)==="extraButton"&&(me.contents=K.value),me))),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},T=()=>{var Q,me,ve,da,ea;E.value=x.value;let L={};if(D.value!==""?L.id=D.value:(k.value++,L.id="id"+k.value),(Q=E.value)==null||Q.forEach(ce=>{const pa=Mn==null?void 0:Mn.find(Ne=>(Ne==null?void 0:Ne.label)===(ce==null?void 0:ce.label));pa?L[pa.key]=ce.value:ce!=null&&ce.children&&ce.children.length>0&&(L.children=ce.children)}),(me=K.value)!=null&&me.find(ce=>ce.id===L.id))K.value=(ve=K.value)==null?void 0:ve.map(ce=>(ce.id===L.id&&(ce=L),ce));else{let ce=A.cloneDeep(K.value)??[];ce.push(L),K.value=ce}j.value=!1,D.value="";let H=A.cloneDeep(r.originalItemContents);(da=A.cloneDeep(r.originalItemContents))!=null&&da.find(ce=>(ce==null?void 0:ce.key)==="extraButton")?H=(ea=A.cloneDeep(r.originalItemContents))==null?void 0:ea.map(ce=>((ce==null?void 0:ce.key)==="extraButton"&&(ce.contents=K.value),ce)):H.push({key:"extraButton",contents:K.value}),n("change",H)},ue=L=>{let H=A.cloneDeep(x.value);H=H==null?void 0:H.map(Q=>(Q.children||(Q.value=L==null?void 0:L[Q.name]),Q)),x.value=H},U=()=>{j.value=!1,E.value=[],D.value=""},Se=L=>{p.value=!0;let H=[];In==null||In.forEach(Q=>{k.value++,H.push({label:Q==null?void 0:Q.label,name:Q==null?void 0:Q.label,type:Q.type,value:L[Q.key],id:k.value,contents:Q==null?void 0:Q.options})}),D.value=L==null?void 0:L.id,I.value=H,R.value=H},Le=L=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,Q;S.value=(H=A.cloneDeep(S.value))==null?void 0:H.filter(me=>(me==null?void 0:me.id)!==(L==null?void 0:L.id)),n("change",(Q=A.cloneDeep(r.originalItemContents))==null?void 0:Q.map(me=>((me==null?void 0:me.key)==="rowButton"&&(me.contents=S.value),me))),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},Pe=()=>{s.value=!0;let L=[];or==null||or.forEach(H=>{k.value++,L.push({label:H==null?void 0:H.label,name:H==null?void 0:H.label,type:H.type,value:"",id:k.value,contents:H==null?void 0:H.options})}),y.value=L,c.value=L},la=()=>{p.value=!0;let L=[];In==null||In.forEach(H=>{k.value++,L.push({label:H==null?void 0:H.label,name:H==null?void 0:H.label,type:H.type,value:"",id:k.value,contents:H==null?void 0:H.options})}),I.value=L,R.value=L},Da=L=>{let H=A.cloneDeep(R.value);H=H==null?void 0:H.map(Q=>(Q.children||(Q.value=L==null?void 0:L[Q.name]),Q)),R.value=H},le=()=>{var Q,me,ve,da,ea;I.value=R.value;let L={};if(D.value!==""?L.id=D.value:(k.value++,L.id="id"+k.value),(Q=I.value)==null||Q.forEach(ce=>{const pa=In==null?void 0:In.find(Ne=>(Ne==null?void 0:Ne.label)===(ce==null?void 0:ce.label));pa?L[pa.key]=ce.value:ce!=null&&ce.children&&ce.children.length>0&&(L.children=ce.children)}),(me=S.value)!=null&&me.find(ce=>ce.id===L.id))S.value=(ve=S.value)==null?void 0:ve.map(ce=>(ce.id===L.id&&(ce=L),ce));else{let ce=A.cloneDeep(S.value);ce.push(L),S.value=ce}p.value=!1,D.value="";let H=A.cloneDeep(r.originalItemContents);(da=A.cloneDeep(r.originalItemContents))!=null&&da.find(ce=>(ce==null?void 0:ce.key)==="rowButton")?H=(ea=A.cloneDeep(r.originalItemContents))==null?void 0:ea.map(ce=>((ce==null?void 0:ce.key)==="rowButton"&&(ce.contents=S.value),ce)):H.push({key:"rowButton",contents:S.value}),n("change",H)},ta=()=>{p.value=!1,D.value="",R.value=[],I.value=[]},te=L=>{s.value=!0;let H=[];or==null||or.forEach(Q=>{k.value++,H.push({label:Q==null?void 0:Q.label,name:Q==null?void 0:Q.label,type:Q.type,value:"",id:k.value,contents:Q==null?void 0:Q.options})}),y.value=H,M.value=L==null?void 0:L.id,c.value=H},ca=L=>{var H;d.value=Ac(A.cloneDeep(d.value),L==null?void 0:L.id),n("change",(H=A.cloneDeep(r.originalItemContents))==null?void 0:H.map(Q=>{var me;return(Q==null?void 0:Q.key)==="header"&&(Q.contents=(me=d.value)!=null&&me.some(ve=>ve==null?void 0:ve.children)?[d.value]:d.value),Q}))},Ee=L=>{var Q,me,ve;L.type==="fix"?L.id!==""?d.value=Mc(d.value,L):d.value=zc(d.value,L==null?void 0:L.contents):d.value=Ic(d.value,L),d.value=(Q=d.value)!=null&&Q.some(da=>da==null?void 0:da.children)?[d.value]:d.value,D.value="";let H=A.cloneDeep(r.originalItemContents);(me=A.cloneDeep(r.originalItemContents))!=null&&me.find(da=>(da==null?void 0:da.key)==="header")?H=(ve=A.cloneDeep(r.originalItemContents))==null?void 0:ve.map(da=>((da==null?void 0:da.key)==="header"&&(da.contents=d.value),da)):H.push({key:"header",contents:d.value}),n("change",H)},oe=L=>{var Q;s.value=!0;let H=[];or==null||or.forEach(me=>{k.value++,H.push({label:me==null?void 0:me.label,name:me==null?void 0:me.label,type:me.type,value:L[me.key],id:k.value,contents:me==null?void 0:me.options})}),L!=null&&L.children&&((Q=L==null?void 0:L.children)==null?void 0:Q.length)>0&&H.push({children:L==null?void 0:L.children,isFormColHidden:!0}),D.value=L==null?void 0:L.id,M.value="",y.value=H,c.value=H},Te=L=>{let H=A.cloneDeep(c.value);H=H==null?void 0:H.map(Q=>(Q.children||(Q.value=L==null?void 0:L[Q.name]),Q)),c.value=H},Ue=()=>{s.value=!1,D.value="",M.value="",c.value=[]},oa=()=>{var Q,me,ve,da,ea,ce;y.value=c.value;let L={};if(D.value!==""?L.id=D.value:(k.value++,L.id="id"+k.value),(Q=y.value)==null||Q.forEach(pa=>{const Ne=or==null?void 0:or.find(We=>(We==null?void 0:We.label)===(pa==null?void 0:pa.label));Ne?L[Ne.key]=pa.value:pa!=null&&pa.children&&pa.children.length>0&&(L.children=pa.children)}),(me=d.value)!=null&&me.find(pa=>pa.id===L.id))d.value=(ve=d.value)==null?void 0:ve.map(pa=>(pa.id===L.id&&(pa=L),pa));else{let pa=A.cloneDeep(d.value)??[];M.value===""?pa.push(L):pa=pa==null?void 0:pa.map(Ne=>(Ne.id===M.value&&(Ne.children||(Ne.children=[]),Ne.children.push(L)),Ne)),d.value=pa}d.value=(da=d.value)!=null&&da.some(pa=>pa==null?void 0:pa.children)?[d.value]:d.value,s.value=!1,D.value="",M.value="";let H=A.cloneDeep(r.originalItemContents);(ea=A.cloneDeep(r.originalItemContents))!=null&&ea.find(pa=>(pa==null?void 0:pa.key)==="header")?H=(ce=A.cloneDeep(r.originalItemContents))==null?void 0:ce.map(pa=>((pa==null?void 0:pa.key)==="header"&&(pa.contents=d.value),pa)):H.push({key:"header",contents:d.value}),n("change",H)},Ja=L=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var H,Q;d.value=(H=A.cloneDeep(d.value))==null?void 0:H.filter(me=>(me==null?void 0:me.id)!==(L==null?void 0:L.id)),n("change",(Q=A.cloneDeep(r.originalItemContents))==null?void 0:Q.map(me=>{var ve;return(me==null?void 0:me.key)==="header"&&(me.contents=(ve=d.value)!=null&&ve.some(da=>da==null?void 0:da.children)?[d.value]:d.value),me})),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return e.watch(()=>r.originalItemContents,()=>{var L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q;if(!(!r.originalItemContents||r.originalItemContents.length===0))if(t.value=A.cloneDeep(r.originalItemContents),d.value=(H=(L=t.value)==null?void 0:L.find(Be=>(Be==null?void 0:Be.key)==="header"))==null?void 0:H.contents,S.value=(me=(Q=t.value)==null?void 0:Q.find(Be=>(Be==null?void 0:Be.key)==="rowButton"))==null?void 0:me.contents,K.value=(da=(ve=t.value)==null?void 0:ve.find(Be=>(Be==null?void 0:Be.key)==="extraButton"))==null?void 0:da.contents,g.value=(ce=(ea=t.value)==null?void 0:ea.find(Be=>(Be==null?void 0:Be.key)==="page"))!=null&&ce.contents?!!((Ne=(pa=t.value)==null?void 0:pa.find(Be=>(Be==null?void 0:Be.key)==="page"))!=null&&Ne.contents):!1,$.value=(Ta=(We=t.value)==null?void 0:We.find(Be=>(Be==null?void 0:Be.key)==="tableToForm"))==null?void 0:Ta.contents,d.value=(Ca=d.value)==null?void 0:Ca.map((Be,Je)=>(Array.isArray(Be)?Be=G3(Be):Be={label:(Be==null?void 0:Be.label)??"",prop:(Be==null?void 0:Be.label)==="操作"?"operate":Be==null?void 0:Be.prop,width:Be!=null&&Be.width?parseInt(Be.width):"",fixed:(Be==null?void 0:Be.fixed)??void 0,sortable:(Be==null?void 0:Be.sortable)??!1,align:(Be==null?void 0:Be.align)??"left",showOverflowTooltip:(Be==null?void 0:Be.showOverflowTooltip)??!0,isNotDrag:(Be==null?void 0:Be.isNotDrag)??!1,isEditCol:(Be==null?void 0:Be.isEditCol)??!1,isOperate:(Be==null?void 0:Be.isOperate)??!1,id:(Be==null?void 0:Be.id)??Je,formMenuSelect:(Be==null?void 0:Be.formMenuSelect)??void 0,groupSelect:(Be==null?void 0:Be.groupSelect)??void 0},Be)),d.value=(Qe=d.value)!=null&&Qe.every(Be=>Array.isArray(Be))?(Va=d.value)==null?void 0:Va[0]:d.value,S.value=(ne=S.value)==null?void 0:ne.map((Be,Je)=>Be={label:(Be==null?void 0:Be.label)??"",type:(Be==null?void 0:Be.type)??"",textColor:(Be==null?void 0:Be.textColor)??"#000000",id:(Be==null?void 0:Be.id)??Je}),K.value=(X=K.value)==null?void 0:X.map((Be,Je)=>Be={label:(Be==null?void 0:Be.label)??"",type:(Be==null?void 0:Be.type)??"",background:(Be==null?void 0:Be.background)??"var(--ssComponent-primary-color)",id:(Be==null?void 0:Be.id)??Je}),$.value)$.value=(q=$.value)==null?void 0:q.map(Be=>{k.value++;let Je=Be;return Je.id=k.value,Je});else{let Be=[];const Je=(Z=he.getColumnChild(A.cloneDeep(d.value)))==null?void 0:Z.filter(ra=>(ra==null?void 0:ra.prop)!=="operate");Je==null||Je.forEach(ra=>{var ba;k.value++,Be.push({label:ra==null?void 0:ra.label,name:(ra==null?void 0:ra.prop)||(ra==null?void 0:ra.label),type:ra!=null&&ra.groupSelect?"Select":"Input",value:"",id:k.value,contents:ra==null?void 0:ra.options,menuSelect:ra==null?void 0:ra.formMenuSelect,groupSelect:(ba=ra==null?void 0:ra.groupSelect)==null?void 0:ba.split(":"),selectRelateType:"关联绑定列"})}),$.value=Be}},{deep:!0,immediate:!0}),(L,H)=>{const Q=e.resolveComponent("svg-icon"),me=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",vh,[e.createElementVNode("div",mh,[e.createElementVNode("div",yh,[H[2]||(H[2]=e.createElementVNode("div",null,e.toDisplayString("表头"),-1)),e.createVNode(me,{class:"icon-content",onClick:Pe,id:"themeButton"},{icon:e.withCtx(()=>[e.createVNode(Q,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[1]||(H[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",gh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(ve,da)=>(e.openBlock(),e.createElementBlock("div",{key:da},[e.createElementVNode("div",bh,[e.createElementVNode("div",kh,e.toDisplayString(ve==null?void 0:ve.label),1),e.createElementVNode("div",xh,[e.createVNode(Q,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ea=>te(ve)},null,8,["onClick"]),e.createVNode(Q,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ea=>oe(ve)},null,8,["onClick"]),e.createVNode(Q,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ea=>Ja(ve)},null,8,["onClick"])])]),ve!=null&&ve.children&&ve.children.length>0?(e.openBlock(),e.createElementBlock("div",wh,[e.createVNode(Oc,{tableChildContents:ve==null?void 0:ve.children,onDeleteChange:ca,onFixChange:Ee},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),128))]),e.createElementVNode("div",_h,[H[4]||(H[4]=e.createElementVNode("div",null,e.toDisplayString("行内按钮"),-1)),e.createVNode(me,{class:"icon-content",id:"themeButton",onClick:la},{icon:e.withCtx(()=>[e.createVNode(Q,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[3]||(H[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",Sh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(ve,da)=>(e.openBlock(),e.createElementBlock("div",{key:da},[e.createElementVNode("div",Eh,[e.createElementVNode("div",Ch,e.toDisplayString(ve==null?void 0:ve.label),1),e.createElementVNode("div",Dh,[e.createVNode(Q,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ea=>Se(ve)},null,8,["onClick"]),e.createVNode(Q,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ea=>Le(ve)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Bh,[H[6]||(H[6]=e.createElementVNode("div",null,e.toDisplayString("表外按钮"),-1)),e.createVNode(me,{class:"icon-content",id:"themeButton",onClick:F},{icon:e.withCtx(()=>[e.createVNode(Q,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[5]||(H[5]=e.createTextVNode(" 新增 "))]),_:1,__:[5]})]),e.createElementVNode("div",Nh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(K.value,(ve,da)=>(e.openBlock(),e.createElementBlock("div",{key:da},[e.createElementVNode("div",Th,[e.createElementVNode("div",Ah,e.toDisplayString(ve==null?void 0:ve.label),1),e.createElementVNode("div",zh,[e.createVNode(Q,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ea=>Fe(ve)},null,8,["onClick"]),e.createVNode(Q,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ea=>ye(ve)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Mh,[H[8]||(H[8]=e.createElementVNode("div",null,e.toDisplayString("表格弹框字段设置"),-1)),e.createVNode(me,{class:"icon-content",id:"themeButton",onClick:J},{icon:e.withCtx(()=>[e.createVNode(Q,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[H[7]||(H[7]=e.createTextVNode(" 新增 "))]),_:1,__:[7]})]),e.createElementVNode("div",Ih,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($.value,(ve,da)=>(e.openBlock(),e.createElementBlock("div",{key:da},[e.createElementVNode("div",Oh,[e.createElementVNode("div",Lh,e.toDisplayString(ve==null?void 0:ve.label),1),e.createElementVNode("div",Rh,[e.createVNode(Q,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:ea=>fe(ve)},null,8,["onClick"]),e.createVNode(Q,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ea=>ae(ve)},null,8,["onClick"])])])]))),128))]),H[10]||(H[10]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("分页"))],-1)),e.createElementVNode("div",$h,[e.createElementVNode("div",Vh,[H[9]||(H[9]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否分页"),-1)),e.createVNode(ll._sfc_main$1,{modelValue:g.value,"onUpdate:modelValue":H[0]||(H[0]=ve=>g.value=ve)},null,8,["modelValue"])])])]),e.createVNode(wr.ssDialog,{visible:s.value,onBeforeDestroy:Ue,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Fh,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:y.value,key:y.value,isEnableWrap:!0,onChange:Te},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Ph,[e.createVNode(me,{onClick:Ue,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[11]||(H[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(me,{class:"ok-button button",onClick:oa,id:"themeButton"},{default:e.withCtx(()=>H[12]||(H[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible"]),e.createVNode(wr.ssDialog,{visible:p.value,onBeforeDestroy:ta,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",jh,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:I.value,key:I.value,isEnableWrap:!0,onChange:Da},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Hh,[e.createVNode(me,{onClick:ta,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[13]||(H[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(me,{class:"ok-button button",onClick:le,id:"themeButton"},{default:e.withCtx(()=>H[14]||(H[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible"]),e.createVNode(wr.ssDialog,{visible:j.value,onBeforeDestroy:U,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Uh,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:ue},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",qh,[e.createVNode(me,{onClick:U,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[15]||(H[15]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[15]}),e.createVNode(me,{class:"ok-button button",onClick:T,id:"themeButton"},{default:e.withCtx(()=>H[16]||(H[16]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[16]})])]),_:1},8,["visible"]),e.createVNode(wr.ssDialog,{visible:v.value,onBeforeDestroy:de,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Wh,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:ge,onChangeVisible:se,onBlurChange:Me},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Kh,[e.createVNode(me,{onClick:de,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>H[17]||(H[17]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[17]}),e.createVNode(me,{class:"ok-button button",onClick:De,id:"themeButton"},{default:e.withCtx(()=>H[18]||(H[18]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[18]})])]),_:1},8,["visible"])])}}},Yh=Zl._export_sfc(Gh,[["__scopeId","data-v-7a6b87b5"]]),Jh=A.useModelComp(A.pinia),{pageMapState:Xh}=A.storeToRefs(Jh),Zh=A.useMenuState(A.pinia),{activeMenuPath:Qh}=A.storeToRefs(Zh),e2=e.ref(24),a2=e.ref(6),l2=e.ref(10),r2=e.ref(70),n2=e.ref(.18),i2=e.ref(45),o2=(a,l,r,n)=>{var t,s,v,d,p,y,g,c,D,M,S,K,I,R,j,E;return{x:((s=(t=a==null?void 0:a.value)==null?void 0:t.tableData)==null?void 0:s.x)||l%2*12,y:((d=(v=a==null?void 0:a.value)==null?void 0:v.tableData)==null?void 0:d.y)||l,w:((y=(p=a==null?void 0:a.value)==null?void 0:p.tableData)==null?void 0:y.w)||e2.value,h:((c=(g=a==null?void 0:a.value)==null?void 0:g.tableData)==null?void 0:c.h)||r,minW:((M=(D=a==null?void 0:a.value)==null?void 0:D.tableData)==null?void 0:M.minW)||a2.value,minH:((K=(S=a==null?void 0:a.value)==null?void 0:S.tableData)==null?void 0:K.minH)||n2.value,maxH:((R=(I=a==null?void 0:a.value)==null?void 0:I.tableData)==null?void 0:R.maxH)||i2.value,i:((E=(j=a==null?void 0:a.value)==null?void 0:j.tableData)==null?void 0:E.i)||l,id:(a==null?void 0:a.id)||l+"",component:n}},t2=(a,l)=>{var n,t,s,v,d,p,y,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(((v=(s=(t=a==null?void 0:a.compData)==null?void 0:t.find(D=>(D==null?void 0:D.key)==="tableContents"))==null?void 0:s.contents)==null?void 0:v.length)===0)return 2}else((d=a==null?void 0:a.comp)==null?void 0:d.toUpperCase())==="FORM"&&(r=((g=(y=(p=a==null?void 0:a.compData)==null?void 0:p.find(D=>(D==null?void 0:D.key)==="formContent"))==null?void 0:y.contents)==null?void 0:g.length)/5);return r*2},Lc=(a,l,r)=>{var v,d;const n=(d=(v=Xh.value)==null?void 0:v[Qh.value])==null?void 0:d.filter(p=>{var y;return((y=p==null?void 0:p.key)==null?void 0:y.type)==="gridLayout"}),t=n==null?void 0:n.find(p=>{var y,g,c;return((c=(g=(y=p==null?void 0:p.value)==null?void 0:y.tableData)==null?void 0:g.component)==null?void 0:c.id)===a.id}),s=t2(a);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((p,y)=>Lc(p,y))),{...o2(t,l,s,a)}},s2=(a,l)=>{if((a==null?void 0:a.length)===0)return[];const r=A.cloneDeep(a);return Array.isArray(a)?r==null?void 0:r.map((n,t)=>Lc(n,t)):[]},c2=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}]}]}}),u2=(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}),d2=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,t=e.ref([]);e.watch(()=>r.compType,d=>{var g;const p=c2(r==null?void 0:r.optionItems),y=d?(g=p[d==null?void 0:d.toUpperCase()])==null?void 0:g[r==null?void 0:r.target]:[];t.value=y==null?void 0:y.map(c=>{for(const[D,M]of Object.entries((r==null?void 0:r.comp)||{}))if((c==null?void 0:c.prop)===D)return{...c,value:M};return c})},{immediate:!0});const s=d=>ll.getComponent(d),v=d=>{var p,y;(d==null?void 0:d.prop)==="layout"&&(d==null?void 0:d.value)==="horizontal"?t.value=(p=t.value)==null?void 0:p.map(g=>{var c;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(c=g==null?void 0:g.options)==null?void 0:c.map(D=>({...D,disabled:!0}))}:(g==null?void 0:g.prop)==="isGridLayout"?{...g,disabled:!0}:g}):t.value=(y=t.value)==null?void 0:y.map(g=>{var c;return(g==null?void 0:g.prop)==="isStepLayout"?{...g,options:(c=g==null?void 0:g.options)==null?void 0:c.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:t.value,prop:d==null?void 0:d.prop})};return(d,p)=>{const y=e.resolveComponent("el-col"),g=e.resolveComponent("el-row");return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,c=>(e.openBlock(),e.createBlock(g,{class:"style-row",key:c==null?void 0:c.prop},{default:e.withCtx(()=>[e.createVNode(y,{span:6,class:"style-row-title"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(c==null?void 0:c.label)+":",1)]),_:2},1024),e.createVNode(y,{span:18,style:{display:"flex"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(s(c.type)),{modelValue:c.value,"onUpdate:modelValue":D=>c.value=D,content:c==null?void 0:c.options,optionUrl:c==null?void 0:c.optionUrl,disabled:c==null?void 0:c.disabled,activeText:c==null?void 0:c.activeText,inactiveText:c==null?void 0:c.inactiveText,onChange:D=>v(c)},null,40,["modelValue","onUpdate:modelValue","content","optionUrl","disabled","activeText","inactiveText","onChange"]))]),_:2},1024)]),_:2},1024))),128)}}}),p2=Zl._export_sfc(d2,[["__scopeId","data-v-6c233914"]]),f2=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,t=[{required:!0,message:"输入不能为空",trigger:"blur"}],s=e.ref([]),v=R=>R==null?void 0:R.reduce((j,E)=>(j[E==null?void 0:E.prop]=E==null?void 0:E.rule,j),{}),d=e.computed(()=>({formRules:v(s.value),buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"保存",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]})),p=e.ref([]),y=e.ref(""),g=(R,j,E)=>{var b;let x=[];(r==null?void 0:r.activeTabName)==="任务配置"?(x=[{label:"任务名称",prop:"任务名称",key:"任务名称",value:"",width:1,isFormColHidden:!1},{label:"任务关键词",prop:"任务关键词",key:"任务关键词",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"列名称",value:"列名称",children:R},{label:"按钮名称",value:"按钮名称",children:j}]},{label:"执行任务",prop:"执行任务",key:"执行任务",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"进度设置",value:"进度设置",children:[{label:"计时",value:"计时",children:[{label:"倒计时",value:"倒计时"},{label:"进行时",value:"进行时"}]},{label:"进度条",value:"进度条"}]},{label:"统计",value:"统计",children:[{label:"统计规则",value:"统计规则",children:[{label:"求和",value:"求和"},{label:"自定义",value:"自定义"}]}]}]},{label:"执行动作",prop:"执行动作",key:"执行动作",type:"select",value:[],width:1,isFormColHidden:!1,contents:[{label:"点击时",value:"点击时"},{label:"页面加载时",value:"页面加载时"}]},{label:"执行交互",prop:"执行交互",key:"执行交互",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"界面显示",value:"界面显示",children:[{label:"主页",value:"主页"},{label:"详情页",value:"详情页"}]},{label:"弹窗提示",value:"弹窗提示"},{label:"后台提交",value:"后台提交"}]},{label:"任务状态",prop:"任务状态",key:"任务状态",type:"radio",value:"启动",width:1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],s.value=[{prop:"任务名称",rule:t},{prop:"任务关键词",rule:t},{prop:"执行任务",rule:t},{prop:"执行动作",rule:t},{prop:"执行交互",rule:t}]):(r==null?void 0:r.activeTabName)==="任务关联"&&(x=[{prop:"关联名称",label:"关联名称",key:"关联名称",type:"input",value:"",isTableColHidden:!1,isFormColHidden:!1},{label:"关联形式",prop:"关联形式",key:"关联形式",type:"select",value:"流程式",width:1,isFormColHidden:!1,contents:[{label:"流程式",value:"流程式"}]},{label:"关联任务集合",prop:"关联任务集合",key:"关联任务集合",type:"tag",value:[],width:1,isFormColHidden:!1,contents:(b=r==null?void 0:r.relatedData)==null?void 0:b.map(w=>({label:w==null?void 0:w.任务名称,value:w==null?void 0:w.任务名称}))},{prop:"关联状态",label:"关联状态",key:"关联状态",type:"radio",value:"启动",isTableColHidden:!1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],s.value=[{prop:"关联名称",rule:t},{prop:"关联状态",rule:t},{prop:"关联形式",rule:t},{prop:"关联任务集合",rule:t}]);let k;return E&&(E==null?void 0:E.length)>0?k=[...x,...c(R,j,E)]:k=x,k},c=(R,j,E)=>{const x=[{label:"进度关键词",prop:"进度关键词",key:"进度关键词",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计算法源",prop:"统计算法源",key:"统计算法源",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计是否获取错误集",prop:"统计是否获取错误集",key:"统计是否获取错误集",type:"radio",value:!1,width:2,isFormColHidden:!1,contents:[{label:"是",value:!0},{label:"否",value:!1}]}];return E?x==null?void 0:x.filter(k=>E==null?void 0:E.includes(k==null?void 0:k.prop)):x},D=(R,j)=>{var w,$,F,J,se,ge,Me,V,fe;const E=((se=(J=(F=($=(w=r==null?void 0:r.comp)==null?void 0:w.compData)==null?void 0:$.find(ae=>(ae==null?void 0:ae.key)==="header"))==null?void 0:F.contents)==null?void 0:J.filter(ae=>(ae==null?void 0:ae.label)!=="操作"))==null?void 0:se.map(ae=>({value:ae==null?void 0:ae.prop,label:ae.label})))||[],x=/button/i,k=((fe=(V=(Me=(ge=r==null?void 0:r.comp)==null?void 0:ge.compData)==null?void 0:Me.filter(ae=>x.test(ae==null?void 0:ae.key)))==null?void 0:V.flatMap(ae=>ae==null?void 0:ae.contents))==null?void 0:fe.map(ae=>({value:ae==null?void 0:ae.label,label:ae.label})))||[],b=g(E,k,R);p.value=j?u2(b,j):b,R&&(R==null?void 0:R.length)>0&&s.value.push(...R==null?void 0:R.map(ae=>({prop:ae,rule:t})))};e.onMounted(()=>{D(null,r==null?void 0:r.extendItem)});const M=R=>{const j=R==null?void 0:R[y.value];if(y.value==="执行任务"){if(!(j!=null&&j.join("/")))return;const E=j==null?void 0:j.join("/");D(E==="统计/统计规则/自定义"?["统计算法源","统计是否获取错误集"]:E==="进度设置/进度条"?["进度关键词"]:null,R)}},S=R=>{n("change",{target:r==null?void 0:r.target,extendConfigs:R})},K=(R,j)=>{y.value=j==null?void 0:j.changeProp,M(R)},I=R=>{n("onButtonClick",R)};return(R,j)=>(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:p.value,key:p.value,isStartJustify:!1,isEnableWrap:!1,formRules:d.value.formRules,buttonValue:d.value.buttonValue,onChange:S,onBlurChange:K,onOnButtonClick:I},null,8,["rowContents","formRules","buttonValue"]))}}),h2=Zl._export_sfc(f2,[["__scopeId","data-v-7c660c1f"]]),v2={};function m2(a,l){return null}const y2=Zl._export_sfc(v2,[["render",m2]]),g2={class:"form-operate-content"},b2={class:"form-operate-item"},k2={class:"operate-title"},x2={class:"operate-content"},w2={class:"fix-content"},_2={class:"fix-button"},S2={class:"operate-title"},E2={class:"operate-content"},C2={class:"fix-content"},D2={class:"fix-button"},B2={style:{display:"flex","justify-content":"space-between"}},N2={class:"form-content"},T2={class:"dialog-footer"},A2={class:"form-content"},z2={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,t=e.ref(!1),s=e.ref([]),v=e.ref([]),d=e.ref(!1),p=e.ref([]),y=e.ref([]),g=e.ref(""),c=e.ref(!1),D=e.ref(0),M=e.ref([]),S=e.ref([]),K=(V,fe)=>{if((fe==null?void 0:fe.type)=="Select"&&(V==null?void 0:V.key)==="selectRelateType"){const ae=fe==null?void 0:fe.optionUrl;return(ae==null?void 0:ae.selectRelateType)||fe[V.key]}if((fe==null?void 0:fe.type)=="Select"&&(V==null?void 0:V.key)==="menuSelect"){const ae=fe==null?void 0:fe.optionUrl;return(ae==null?void 0:ae.menuSelect)||fe[V.key]}if((fe==null?void 0:fe.type)=="Select"&&(V==null?void 0:V.key)==="groupSelect"){const ae=fe==null?void 0:fe.optionUrl;return(ae==null?void 0:ae.groupSelect)||fe[V.key]}if((fe==null?void 0:fe.type)=="Select"&&(V==null?void 0:V.key)==="originalContent")return(fe==null?void 0:fe.value)||fe[V.key];if((fe==null?void 0:fe.type)=="Select"&&(V==null?void 0:V.key)==="multiple"){const ae=fe[V.key];return Xs(ae)?ae:V.default}return(V==null?void 0:V.label)==="类型"&&fe[V.key]===""?"Input":(V==null?void 0:V.key)==="isFormColHidden"&&!fe[V.key]?!1:fe[V.key]},I=async V=>{var de,De,Fe,ye,T,ue;t.value=!0;let fe=[];const ae=await((Fe=(De=(de=he.FormContent)==null?void 0:de.find(U=>(U==null?void 0:U.key)===((V==null?void 0:V.type)===""?"Input":V==null?void 0:V.type)))==null?void 0:De.value)==null?void 0:Fe.value)??((T=(ye=he.FormContent)==null?void 0:ye.find(U=>(U==null?void 0:U.key)===((V==null?void 0:V.type)===""?"Input":V==null?void 0:V.type)))==null?void 0:T.value);if(ae==null||ae.forEach(U=>{D.value++,fe.push({label:U==null?void 0:U.label,name:U==null?void 0:U.label,type:U.type,prop:U==null?void 0:U.prop,value:K(U,V),id:D.value,contents:U==null?void 0:U.options,width:(V==null?void 0:V.width)??1})}),V!=null&&V.menuSelect&&((ue=V==null?void 0:V.menuSelect)==null?void 0:ue.length)>0){const U=await he.menuToContentType(V==null?void 0:V.menuSelect);fe=fe==null?void 0:fe.map(Se=>((Se==null?void 0:Se.name)==="组信息选项"&&(Se.contents=U),Se))}g.value=V==null?void 0:V.id,s.value=await he.selectToBase(he.formToOptionsContents(fe)),v.value=await he.selectToBase(he.formToOptionsContents(fe))},R=V=>{var ae;d.value=!0;let fe=[];(ae=he.FormButton)==null||ae.forEach(de=>{D.value++,fe.push({label:de==null?void 0:de.label,name:de==null?void 0:de.label,type:de.type,value:(de==null?void 0:de.label)==="类型"&&V[de.key]===""?"normal":V[de.key],id:D.value,contents:de==null?void 0:de.options})}),M.value=fe,S.value=fe,g.value=V==null?void 0:V.id};e.watch(()=>c.value,()=>{var fe,ae;let V=A.cloneDeep(r.originalItemContents);(fe=A.cloneDeep(r.originalItemContents))!=null&&fe.find(de=>(de==null?void 0:de.key)==="enableWrap")?V=(ae=A.cloneDeep(r.originalItemContents))==null?void 0:ae.map(de=>((de==null?void 0:de.key)==="enableWrap"&&(de.contents=!c.value),de)):V.push({key:"enableWrap",contents:!c.value}),n("change",V)},{deep:!0});const j=()=>{var ae,de,De,Fe,ye;M.value=S.value;let V={};if(g.value!==""?V.id=g.value:(D.value++,V.id="id"+D.value),(ae=M.value)==null||ae.forEach(T=>{var U;const ue=(U=he.FormButton)==null?void 0:U.find(Se=>(Se==null?void 0:Se.label)===(T==null?void 0:T.label));ue&&(V[ue.key]=T.value)}),(de=p.value)!=null&&de.find(T=>T.id===V.id))p.value=(De=p.value)==null?void 0:De.map(T=>(T.id===V.id&&(T=V),T));else{let T=A.cloneDeep(p.value);p.value||(p.value=[]),T.push(V),p.value=T}d.value=!1,g.value="";let fe=A.cloneDeep(r.originalItemContents);(Fe=A.cloneDeep(r.originalItemContents))!=null&&Fe.find(T=>(T==null?void 0:T.key)==="formButton")?fe=(ye=A.cloneDeep(r.originalItemContents))==null?void 0:ye.map(T=>((T==null?void 0:T.key)==="formButton"&&(T.contents=p.value),T)):fe.push({key:"formButton",contents:p.value}),n("change",fe)},E=V=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var fe,ae;y.value=(fe=A.cloneDeep(y.value))==null?void 0:fe.filter(de=>(de==null?void 0:de.id)!==(V==null?void 0:V.id)),n("change",(ae=A.cloneDeep(r.originalItemContents))==null?void 0:ae.map(de=>((de==null?void 0:de.key)==="formContent"&&(de.contents=y.value),de))),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=V=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var fe,ae;p.value=(fe=A.cloneDeep(p.value))==null?void 0:fe.filter(de=>(de==null?void 0:de.id)!==(V==null?void 0:V.id)),n("change",(ae=A.cloneDeep(r.originalItemContents))==null?void 0:ae.map(de=>((de==null?void 0:de.key)==="formButton"&&(de.contents=p.value),de))),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},k=()=>{var fe;d.value=!0;let V=[];(fe=he.FormButton)==null||fe.forEach(ae=>{D.value++,V.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)==="类型"?"normal":"",id:D.value,contents:ae==null?void 0:ae.options})}),M.value=V,S.value=V},b=()=>{var fe,ae,de;t.value=!0;let V=[];(de=(ae=(fe=he.FormContent)==null?void 0:fe.find(De=>(De==null?void 0:De.key)==="Input"))==null?void 0:ae.value)==null||de.forEach(De=>{D.value++,V.push({label:De==null?void 0:De.label,name:De==null?void 0:De.label,type:De.type,value:(De==null?void 0:De.label)==="类型"?"Input":"",id:D.value,contents:De==null?void 0:De.options})}),s.value=V,v.value=V},w=V=>{let fe=A.cloneDeep(S.value);fe=fe==null?void 0:fe.map(ae=>(ae.value=V==null?void 0:V[ae.name],ae)),S.value=fe},$=V=>{const fe=V.find(De=>(De==null?void 0:De.name)==="类型");if((fe==null?void 0:fe.value)!="Select")return;const ae=V.find(De=>(De==null?void 0:De.name)==="多选"),de=V.find(De=>(De==null?void 0:De.name)==="初始值");ae!=null&&ae.value&&Eo.isString(de.value)&&(de.value=[de.value]),!(ae!=null&&ae.value)&&!Eo.isString(de.value)&&(de.value="")},F=async V=>{var fe,ae,de,De,Fe,ye,T,ue,U,Se,Le,Pe;if((V==null?void 0:V.类型)!==((ae=(fe=v.value)==null?void 0:fe.find(la=>(la==null?void 0:la.label)==="类型"))==null?void 0:ae.value)){let la=[];const Da=await((Fe=(De=(de=he.FormContent)==null?void 0:de.find(le=>(le==null?void 0:le.key)===((V==null?void 0:V.类型)===""?"Input":V==null?void 0:V.类型)))==null?void 0:De.value)==null?void 0:Fe.value)?await((Se=(U=(ue=he.FormContent)==null?void 0:ue.find(le=>(le==null?void 0:le.key)===((V==null?void 0:V.类型)===""?"Input":V==null?void 0:V.类型)))==null?void 0:U.value)==null?void 0:Se.value):(T=(ye=he.FormContent)==null?void 0:ye.find(le=>(le==null?void 0:le.key)===((V==null?void 0:V.类型)===""?"Input":V==null?void 0:V.类型)))==null?void 0:T.value;if(Da==null||Da.forEach(le=>{var te,ca;D.value++;const ta=Lu(le==null?void 0:le.default)?(V==null?void 0:V[le.label])??le.value??"":le==null?void 0:le.default;la.push({label:le==null?void 0:le.label,name:le==null?void 0:le.label,type:le.type,value:ta,prop:le==null?void 0:le.prop,id:D.value,contents:le==null?void 0:le.options,width:((ca=(te=v.value)==null?void 0:te[0])==null?void 0:ca.width)??1})}),V!=null&&V.菜单选项&&((Le=V==null?void 0:V.菜单选项)==null?void 0:Le.length)>0){const le=await he.menuToContentType(V==null?void 0:V.菜单选项);la=la==null?void 0:la.map(ta=>((ta==null?void 0:ta.name)==="组信息选项"&&(ta.contents=le),ta))}$(la),v.value=await he.selectToBase(A.cloneDeep(la)),s.value=await he.selectToBase(A.cloneDeep(la))}else{let la=A.cloneDeep(v.value);if(la=la==null?void 0:la.map(Da=>(Da.value=V==null?void 0:V[Da.name],Da)),V!=null&&V.菜单选项&&((Pe=V==null?void 0:V.菜单选项)==null?void 0:Pe.length)>0){const Da=await he.menuToContentType(V==null?void 0:V.菜单选项);la=la==null?void 0:la.map(le=>((le==null?void 0:le.name)==="组信息选项"&&(le.contents=Da),le))}la=he.formToOptionsContents(la),$(la),v.value=await he.selectToBase(A.cloneDeep(la))}},J=V=>{V||(s.value=v.value)},se=async V=>{await F(V),s.value=v.value},ge=Bl.debounce(async()=>{var de,De,Fe,ye,T,ue,U,Se,Le,Pe,la,Da;s.value=v.value;let V={};V.width=((De=(de=s.value)==null?void 0:de[0])==null?void 0:De.width)??1,g.value!==""?V.id=g.value:(D.value++,V.id="id"+D.value);let fe=await((T=(ye=(Fe=he.FormContent)==null?void 0:Fe.find(le=>{var ta,te;return(le==null?void 0:le.key)===(((te=(ta=s.value)==null?void 0:ta.find(ca=>(ca==null?void 0:ca.label)==="类型"))==null?void 0:te.value)??"label")}))==null?void 0:ye.value)==null?void 0:T.value)??((U=(ue=he.FormContent)==null?void 0:ue.find(le=>{var ta,te;return(le==null?void 0:le.key)===(((te=(ta=s.value)==null?void 0:ta.find(ca=>(ca==null?void 0:ca.label)==="类型"))==null?void 0:te.value)??"label")}))==null?void 0:U.value);if((Se=s.value)==null||Se.forEach(le=>{const ta=fe==null?void 0:fe.find(te=>(te==null?void 0:te.label)===(le==null?void 0:le.label));ta&&(V[ta.key]=le.value)}),V.width=V.width?V.width:1,V.key=V==null?void 0:V.label,V.isFormColHidden=V==null?void 0:V.isFormColHidden,(Le=y.value)!=null&&Le.find(le=>le.id===V.id))y.value=(Pe=y.value)==null?void 0:Pe.map(le=>(le.id===V.id&&(le=V),le));else{let le=A.cloneDeep(y.value);le.push(V),y.value=le}y.value=y.value.map(({id:le,...ta})=>ta),t.value=!1,g.value="";let ae=A.cloneDeep(r.originalItemContents);(la=A.cloneDeep(r.originalItemContents))!=null&&la.find(le=>(le==null?void 0:le.key)==="formContent")?ae=(Da=A.cloneDeep(r.originalItemContents))==null?void 0:Da.map(le=>((le==null?void 0:le.key)==="formContent"&&(le.contents=y.value),le)):ae.push({key:"formContent",contents:y.value}),n("change",ae)},300),Me=()=>{t.value=!1,d.value=!1,g.value="",v.value=[],S.value=[]};return e.watch(()=>r.originalItemContents,()=>{var fe,ae,de,De,Fe,ye;if(!r.originalItemContents||r.originalItemContents.length===0)return;const V=A.cloneDeep(r.originalItemContents);y.value=((fe=V==null?void 0:V.find(T=>(T==null?void 0:T.key)==="formContent"))==null?void 0:fe.contents)??[],p.value=((ae=V==null?void 0:V.find(T=>(T==null?void 0:T.key)==="formButton"))==null?void 0:ae.contents)??[],c.value=(de=V==null?void 0:V.find(T=>(T==null?void 0:T.key)==="enableWrap"))!=null&&de.contents?!((De=V==null?void 0:V.find(T=>(T==null?void 0:T.key)==="enableWrap"))!=null&&De.contents):!0,y.value=(Fe=A.cloneDeep(y.value))==null?void 0:Fe.map((T,ue)=>{var Se;let U=T;return U.id=(T==null?void 0:T.id)??ue,T!=null&&T.label||(T.label=(T==null?void 0:T.key)??(T==null?void 0:T.label)??""),T!=null&&T.type||(T.type=(T==null?void 0:T.type)??""),T.contents=((Se=T==null?void 0:T.options)==null?void 0:Se.length)===0?(T==null?void 0:T.contents)??"":T==null?void 0:T.options,U}),y.value=he.formToOptionsContents(y.value),p.value=(ye=p.value)==null?void 0:ye.map((T,ue)=>T={label:(T==null?void 0:T.label)??"",type:(T==null?void 0:T.type)??"",background:(T==null?void 0:T.background)??"var(--ssComponent-primary-color)",id:ue})},{deep:!0,immediate:!0}),(V,fe)=>{const ae=e.resolveComponent("svg-icon"),de=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",g2,[e.createElementVNode("div",b2,[e.createElementVNode("div",k2,[fe[2]||(fe[2]=e.createElementVNode("div",null,e.toDisplayString("表单内容"),-1)),e.createVNode(de,{class:"icon-content",id:"themeButton",onClick:b},{icon:e.withCtx(()=>[e.createVNode(ae,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[fe[1]||(fe[1]=e.createElementVNode("div",null,e.toDisplayString("新增"),-1))]),_:1,__:[1]})]),e.createElementVNode("div",x2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(De,Fe)=>(e.openBlock(),e.createElementBlock("div",{key:Fe},[e.createElementVNode("div",w2,[e.createElementVNode("div",null,e.toDisplayString(De.label),1),e.createElementVNode("div",_2,[e.createVNode(ae,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ye=>I(De)},null,8,["onClick"]),e.createVNode(ae,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ye=>E(De)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",S2,[fe[4]||(fe[4]=e.createElementVNode("div",null,e.toDisplayString("表单按钮"),-1)),e.createVNode(de,{class:"icon-content",id:"themeButton",onClick:k},{icon:e.withCtx(()=>[e.createVNode(ae,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[fe[3]||(fe[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",E2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(De,Fe)=>(e.openBlock(),e.createElementBlock("div",{key:Fe},[e.createElementVNode("div",C2,[e.createElementVNode("div",null,e.toDisplayString(De.label),1),e.createElementVNode("div",D2,[e.createVNode(ae,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ye=>R(De)},null,8,["onClick"]),e.createVNode(ae,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ye=>x(De)},null,8,["onClick"])])])]))),128))]),fe[6]||(fe[6]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("表单布局"))],-1)),e.createElementVNode("div",B2,[fe[5]||(fe[5]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否自动撑宽"),-1)),e.createVNode(ll._sfc_main$1,{modelValue:c.value,"onUpdate:modelValue":fe[0]||(fe[0]=De=>c.value=De)},null,8,["modelValue"])])]),e.createVNode(wr.ssDialog,{visible:t.value,onBeforeDestroy:Me,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",N2,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!0,onChange:F,onChangeVisible:J,onBlurChange:se},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",T2,[e.createVNode(de,{onClick:Me,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>fe[7]||(fe[7]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[7]}),e.createVNode(de,{class:"ok-button button",onClick:e.unref(ge),id:"themeButton"},{default:e.withCtx(()=>fe[8]||(fe[8]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[8]},8,["onClick"])])]),_:1},8,["visible"]),e.createVNode(wr.ssDialog,{visible:d.value,onBeforeDestroy:Me,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",A2,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:M.value,key:M.value,isEnableWrap:!0,onChange:w},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:Me,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:j},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},xs=Zl._export_sfc(z2,[["__scopeId","data-v-20850524"]]),M2={class:"step-module content"},I2={class:"module-data"},O2={class:"step-module layout"},L2={class:"form-content"},R2=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,t=e.ref([{label:"方向:",prop:"direction",type:"RADIO",contents:[{label:"水平",value:"horizontal"},{label:"垂直",value:"vertical"}],value:"horizontal"},{label:"是否居中:",prop:"alignCenter",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0},{label:"应用简洁风格",prop:"simple",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!1}]),s=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"标题",prop:"title",type:"input",value:""},{label:"描述",prop:"description",type:"input",value:""}]),v=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),d=e.reactive({visible:!1,width:"40%",title:"步骤条"}),p=e.ref("create"),y=e.ref({}),g=e.ref([]),c=I=>{var R;y.value=I,n("change",(R=S())==null?void 0:R.compData)},D=(I,R)=>{var j,E;switch(I){case"create":(j=s.value)==null||j.forEach(x=>{x.value=""}),p.value="create",d.visible=!0;break;case"update":(E=s.value)==null||E.forEach(x=>{x.value=R[x==null?void 0:x.prop]}),p.value="update",d.visible=!0;break;case"delete":g.value.splice(R,1),p.value="delete";break}},M=I=>{var R,j,E;if((I==null?void 0:I.buttonName)==="确认"){const x=A.cloneDeep(I==null?void 0:I.content);switch(Object.keys(x).forEach(k=>{x[k]===""&&delete x[k]}),p.value){case"create":g.value.push({...x,index:((R=g.value)==null?void 0:R.length)+1});break;case"update":g.value=(j=g.value)==null?void 0:j.map(k=>k.index===(x==null?void 0:x.index)?{...k,title:x==null?void 0:x.title,description:x==null?void 0:x.description}:k);break}n("change",(E=S())==null?void 0:E.compData),d.visible=!1}else d.visible=!1},S=()=>({comp:"Step",compData:[{key:"stepList",contents:g.value},{key:"stepConfig",contents:y.value}]}),K=()=>{d.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,I=>{var R,j;I&&(y.value=((R=I==null?void 0:I.find(E=>E.key==="stepConfig"))==null?void 0:R.contents)??{},g.value=((j=I==null?void 0:I.find(E=>E.key==="stepList"))==null?void 0:j.contents)??[])},{immediate:!0}),(I,R)=>{const j=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",M2,[R[2]||(R[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:R[0]||(R[0]=x=>D("create"))},{icon:e.withCtx(()=>[e.createVNode(j,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[R[1]||(R[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",I2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(x,k)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:k},[e.createElementVNode("span",null,e.toDisplayString(x==null?void 0:x.title),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>D("update",{...x,index:k+1})},{default:e.withCtx(()=>R[3]||(R[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>D("delete",k)},{default:e.withCtx(()=>R[4]||(R[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",O2,[R[5]||(R[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(ll.ssForm,{rowContents:t.value,onChange:c},null,8,["rowContents"])])]),e.createVNode(wr.ssDialog,{visible:d.visible,title:d.title,onBeforeDestroy:K,width:d.width},{default:e.withCtx(()=>[e.createElementVNode("div",L2,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:v.value,onOnButtonClick:M},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),$2=Zl._export_sfc(R2,[["__scopeId","data-v-7dbd17f2"]]),V2={class:"step-module content"},F2={class:"module-data"},P2={class:"step-module layout"},j2={class:"form-content"},H2=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,t=e.ref("create"),s=e.ref({}),v=e.ref([]),d=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}]),p=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"内容",prop:"content",type:"input",value:""},{label:"时间戳",prop:"timestamp",type:"datetime",value:""}]),y=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),g=e.reactive({visible:!1,width:"40%",title:"时间线"}),c=I=>{var R;s.value=I,n("change",(R=S())==null?void 0:R.compData)},D=(I,R)=>{var j,E;switch(I){case"create":(j=p.value)==null||j.forEach(x=>{x.value=""}),t.value="create",g.visible=!0;break;case"update":(E=p.value)==null||E.forEach(x=>{x.value=R[x==null?void 0:x.prop]}),t.value="update",g.visible=!0;break;case"delete":v.value.splice(R,1),t.value="delete";break}},M=I=>{var R,j,E,x;if((I==null?void 0:I.buttonName)==="确认"){const k=A.cloneDeep(I==null?void 0:I.content);switch(Object.keys(k).forEach(b=>{k[b]===""&&delete k[b]}),t.value){case"create":(j=v.value)==null||j.push({...k,index:((R=v.value)==null?void 0:R.length)+1});break;case"update":v.value=(E=v.value)==null?void 0:E.map(b=>b.index===(k==null?void 0:k.index)?{...b,content:k==null?void 0:k.content,timestamp:k==null?void 0:k.timestamp}:b);break}n("change",(x=S())==null?void 0:x.compData),g.visible=!1}else g.visible=!1},S=()=>({comp:"TimeLine",compData:[{key:"timeLineList",contents:v.value},{key:"timeLineConfig",contents:s.value}]}),K=()=>{g.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,I=>{var R,j;I&&(s.value=((R=I==null?void 0:I.find(E=>E.key==="timeLineConfig"))==null?void 0:R.contents)??{},v.value=((j=I==null?void 0:I.find(E=>E.key==="timeLineList"))==null?void 0:j.contents)??[])},{immediate:!0}),(I,R)=>{const j=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",V2,[R[2]||(R[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:R[0]||(R[0]=x=>D("create"))},{icon:e.withCtx(()=>[e.createVNode(j,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[R[1]||(R[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",F2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(v.value,(x,k)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:k},[e.createElementVNode("span",null,e.toDisplayString(x==null?void 0:x.content),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>D("update",{...x,index:k+1})},{default:e.withCtx(()=>R[3]||(R[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>D("delete",k)},{default:e.withCtx(()=>R[4]||(R[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",P2,[R[5]||(R[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(ll.ssForm,{rowContents:d.value,onChange:c},null,8,["rowContents"])])]),e.createVNode(wr.ssDialog,{visible:g.visible,title:g.title,onBeforeDestroy:K,width:g.width},{default:e.withCtx(()=>[e.createElementVNode("div",j2,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:p.value,key:p.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:y.value,onOnButtonClick:M},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),U2=Zl._export_sfc(H2,[["__scopeId","data-v-39ffc861"]]),q2={};function W2(a,l){return e.openBlock(),e.createElementBlock("div")}const K2=Zl._export_sfc(q2,[["render",W2]]),G2={class:"extra-content"},Y2={key:0},J2={key:1},X2={class:"dialog-footer"},Z2={__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),t=e.ref(),s=e.ref(),v=l,d=e.ref(!1),p=e.ref({}),y=e.ref({}),g=e.ref();e.watch(()=>[r.itemData],()=>{var x;const E=A.cloneDeep(r.itemData);t.value=(x=A.cloneDeep(E))==null?void 0:x.map(k=>{var b;if(k.key==="extra"){let w=[];(b=k.value)==null||b.forEach($=>{var F;w.push((F=Object.values($))==null?void 0:F[0])}),k.value=w}return k})},{deep:!0,immediate:!0});const c=(E,x,k,b)=>{var $;let w={};(($=E==null?void 0:E[0])==null?void 0:$.contents)==="详情"&&(d.value=!0,w[x]=E,s.value=E==null?void 0:E.filter(F=>(F==null?void 0:F.key)!=="tableContentName"),p.value=w,y.value=k,g.value=b.id)},D=E=>{var F,J,se,ge;const x=(J=(F=Object.values(A.cloneDeep(p.value)))==null?void 0:F[0])==null?void 0:J.filter(Me=>(Me==null?void 0:Me.key)==="tableContentName"),k=(ge=(se=Object.values(A.cloneDeep(p.value)))==null?void 0:se[0])==null?void 0:ge.filter(Me=>(Me==null?void 0:Me.key)!=="tableContentName"),b=k==null?void 0:k.map((Me,V)=>{var fe;return V===E.index&&(Me==null?void 0:Me.comp)==="Table"&&(Me.compData=(fe=Me.compData)==null?void 0:fe.map(ae=>{var de,De;return(ae==null?void 0:ae.key)==="tableContents"&&(ae.contents=(De=(de=E.content)==null?void 0:de.map(Fe=>{let ye={};for(let T in Fe)T!=="id"&&(ye[T]=Fe[T]);return ye}))==null?void 0:De.map(Fe=>Object.values(Fe))),ae})),Me});b.unshift(x==null?void 0:x[0]);let w=A.cloneDeep(p.value),$={};for(let Me in w)$[Me]=b;p.value=$},M=()=>{d.value=!1,p.value={},y.value={},g.value=void 0,n.value++},S=E=>{var F,J,se,ge;const x=(J=(F=Object.values(A.cloneDeep(p.value)))==null?void 0:F[0])==null?void 0:J.filter(Me=>(Me==null?void 0:Me.key)==="tableContentName"),k=(ge=(se=Object.values(A.cloneDeep(p.value)))==null?void 0:se[0])==null?void 0:ge.filter(Me=>(Me==null?void 0:Me.key)!=="tableContentName"),b=k==null?void 0:k.map((Me,V)=>(V===E.index&&(Me.compData=E.contents),Me));b.unshift(x==null?void 0:x[0]);let w=A.cloneDeep(p.value),$={};for(let Me in w)$[Me]=b;p.value=$},K=()=>{var x,k;let E={};for(let b in y.value)b===((x=Object.keys(p.value))==null?void 0:x[0])?E[b]=(k=Object.values(p.value))==null?void 0:k[0]:E[b]=y.value[b];v("change",{buttonName:"编辑",index:g.value,singleContent:E},"methodData"),d.value=!1,p.value={},y.value={},g.value=void 0},I=()=>{d.value=!1,p.value={},y.value={},g.value=void 0},R=E=>{v("change",E,"methodData")},j=E=>Bi(E);return(E,x)=>{const k=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",G2,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,(b,w)=>(e.openBlock(),e.createElementBlock("div",{key:n.value},[(b==null?void 0:b.key)==="extra"?(e.openBlock(),e.createElementBlock("div",Y2)):(e.openBlock(),e.createElementBlock("div",J2,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(j(b.comp)),{itemData:b==null?void 0:b.compData,childItemData:b==null?void 0:b.itemChildData,key:w,index:(b==null?void 0:b.id)??w,onContentClick:c,onChange:R},null,40,["itemData","childItemData","index"]))]))]))),128)),e.createVNode(wr.ssDialog,{visible:d.value,onBeforeDestroy:I},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(b,w)=>(e.openBlock(),e.createElementBlock("div",{key:w,class:"extra-dialog"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(j(b.comp)),{itemData:b==null?void 0:b.compData,onChange:D,childItemData:b==null?void 0:b.itemChildData,key:w,onContentChange:S,index:(b==null?void 0:b.id)??w,class:"extra-component"},null,40,["itemData","childItemData","index"]))]))),128))]),footer:e.withCtx(()=>[e.createElementVNode("div",X2,[e.createVNode(k,{class:"cancel-button footer-button",onClick:M,id:"themeBorderButton"},{default:e.withCtx(()=>x[0]||(x[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(k,{class:"confirm-button footer-button",onClick:K,id:"themeButton"},{default:e.withCtx(()=>x[1]||(x[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},Q2=Zl._export_sfc(Z2,[["__scopeId","data-v-2d9c5ab2"]]),e4={key:0,class:"method-content"},a4={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},setup(a){const l=e.ref([]),r=he.useOriginalState(A.pinia),{originalPath:n}=A.storeToRefs(r),t=a,s=e.ref(!1),v=e.ref(),d=he.useTableComp(A.pinia),{multipleTableConst:p}=A.storeToRefs(d),y=A.useModelComp(A.pinia),g=e.ref(!1),c=A.useMenuState(A.pinia),D=A.useLoginState(A.pinia),{itemData:M,isEdit:S,routeToChildPath:K,tableViewContents:I,lockingPage:R,payloadTypes:j}=A.storeToRefs(y),{activeMenuPath:E,platform:x,childMenu:k}=A.storeToRefs(c),{loginUserInfo:b}=A.storeToRefs(D),w=e.ref(!1),$=async()=>{var ye,T;(ye=l.value)!=null&&ye.find(ue=>(ue==null?void 0:ue.buttonName)==="保存")&&await ae((T=l.value)==null?void 0:T.find(ue=>(ue==null?void 0:ue.buttonName)==="保存")),await he.onSaveBack()};e.watch(()=>M.value,async()=>{S.value==="view"&&!w.value&&await Fe(A.cloneDeep(t.itemData)),w.value=!1},{deep:!0});const F=()=>{s.value=!1,v.value=void 0},J=ye=>ye.map(T=>{const ue={};for(const U in T){const Se=T[U];if(U.includes(p.value)){const Le=U.split(p.value);let Pe=ue;Le.forEach((la,Da)=>{Da===Le.length-1?Pe[la]=Se:(Pe[la]||(Pe[la]={}),Pe=Pe[la])})}else ue[U]=Se}return ue}),se=async(ye,T,ue=[])=>{var Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja;let U=(Se=A.cloneDeep(T))==null?void 0:Se.filter(L=>(L==null?void 0:L.comp)!=="methodButton");if(ye!=null&&ye.includes("[")){let L=(le=(Da=(la=(Pe=(Le=A.cloneDeep(ye))==null?void 0:Le.split("["))==null?void 0:Pe[1])==null?void 0:la.split("]"))==null?void 0:Da[0])==null?void 0:le.split(":"),H="";if(L!=null&&L[0]){let Q=(ta=U==null?void 0:U.find(me=>(me==null?void 0:me.name)===(L==null?void 0:L[0])))==null?void 0:ta.compData;if(!Q){let me=(te=ye==null?void 0:ye.split("["))==null?void 0:te[0],ve=await he.getItemData(me,sessionStorage.getItem("systemKey"),"",!1,"","",ue);Q=(ca=ve==null?void 0:ve.find(da=>(da==null?void 0:da.name)===(L==null?void 0:L[0])))==null?void 0:ca.compData}Q==null||Q.forEach(me=>{var ve,da,ea,ce,pa,Ne;if((me==null?void 0:me.key)==="formContent")(ve=me==null?void 0:me.contents)==null||ve.forEach(We=>{var Ta;(We==null?void 0:We.key)===(L==null?void 0:L[1])&&(Array.isArray(We==null?void 0:We.value)?H=We==null?void 0:We.value:H=(Ta=We==null?void 0:We.value)==null?void 0:Ta.toString())});else if((me==null?void 0:me.key)==="tableContents"){let We=[],Ta=(da=Q==null?void 0:Q.find(Qe=>(Qe==null?void 0:Qe.key)==="header"))==null?void 0:da.contents,Ca=(L==null?void 0:L[1])??"";if(Ta!=null&&Ta.every(Qe=>Array.isArray(Qe))){let Qe=he.getColumnChild((pa=Ta==null?void 0:Ta[0])==null?void 0:pa.filter(Va=>(Va==null?void 0:Va.label)!=="操作"));(Ne=me.contents)==null||Ne.forEach(Va=>{let ne={};Va=Va==null?void 0:Va.filter(X=>!(X!=null&&X.id)),Qe==null||Qe.forEach((X,Z)=>{let q=Va[Z];typeof Va[Z]=="number"&&(q=Va[Z].toString()),(Ca===""||Ca===X.prop)&&(ne[X.prop]=q)}),We.push(ne)}),We=J(We)}else{let Qe=(ea=Ta==null?void 0:Ta.map(Va=>Va==null?void 0:Va.label))==null?void 0:ea.filter(Va=>Va!=="操作");(ce=me.contents)==null||ce.forEach(Va=>{let ne={};Va=Va==null?void 0:Va.filter(X=>!(X!=null&&X.id)),Qe==null||Qe.forEach((X,Z)=>{let q=Va[Z];typeof Va[Z]=="number"&&(q=Va[Z].toString()),(Ca===""||Ca===X)&&(ne[X]=q)}),We.push(ne)})}H=We}})}return H}else if(ye!=null&&ye.includes("/")){let L={};return(Ee=A.cloneDeep(U))==null||Ee.forEach((H,Q)=>{var me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q,Be,Je,ra;if((H==null?void 0:H.comp)==="Table"){let ba=Array.isArray((da=(ve=(me=H==null?void 0:H.compData)==null?void 0:me.find(Oe=>(Oe==null?void 0:Oe.key)==="header"))==null?void 0:ve.contents)==null?void 0:da[0])?(Ne=(pa=(ce=(ea=H==null?void 0:H.compData)==null?void 0:ea.find(Oe=>(Oe==null?void 0:Oe.key)==="header"))==null?void 0:ce.contents)==null?void 0:pa[0])==null?void 0:Ne.some(Oe=>Oe==null?void 0:Oe.children):[],ga=(Ca=(Ta=(We=H==null?void 0:H.compData)==null?void 0:We.find(Oe=>(Oe==null?void 0:Oe.key)==="tableContents"))==null?void 0:Ta.contents)==null?void 0:Ca.map(Oe=>(Oe!=null&&Oe.find(Za=>Za==null?void 0:Za.id)&&(Oe=Oe.slice(1)),Oe)),Aa=(Z=(X=(ne=(Va=(Qe=H==null?void 0:H.compData)==null?void 0:Qe.find(Oe=>(Oe==null?void 0:Oe.key)==="header"))==null?void 0:Va.contents)==null?void 0:ne[0])==null?void 0:X[0])==null?void 0:Z.label,_a=(Be=(q=H==null?void 0:H.compData)==null?void 0:q.find(Oe=>(Oe==null?void 0:Oe.key)==="header"))==null?void 0:Be.contents;if(ba)(ba==null?void 0:ba.length)===0?L[H.name]=L!=null&&L[H.name]?L[H.name]:he.tableToForm(ga,_a):L[Aa]=he.tableToForm(ga,_a);else{const Oe=[];_a=_a.slice(1,_a.length-1),_a==null||_a.forEach((Za,Ha)=>{ga==null||ga.forEach(xl=>{Oe.push({key:Za.label+xl[0],value:xl[Ha+1]})})}),L["form"+Q]=Oe}}else{const ba=(ra=(Je=H.compData)==null?void 0:Je.find(Aa=>(Aa==null?void 0:Aa.key)==="formContent"))==null?void 0:ra.contents;L!=null&&L.form||(L.form=[]);const ga=[];ba==null||ba.forEach(Aa=>{Aa.key!==""&&(Aa={key:(Aa==null?void 0:Aa.key)??(Aa==null?void 0:Aa.label),value:Aa==null?void 0:Aa.value},ga.push(Aa))}),L.form=[...ga,...A.cloneDeep(L==null?void 0:L.form)]}}),L}else{if(ye==="createInsofDataApi"){let L=(oe=A.cloneDeep(T))==null?void 0:oe[0];return L={comp:(Te=A.cloneDeep(L))==null?void 0:Te.comp,compData:(Ue=A.cloneDeep(L))==null?void 0:Ue.compData,name:(oa=A.cloneDeep(L))==null?void 0:oa.name,isShow:(Ja=A.cloneDeep(L))==null?void 0:Ja.isShow},{key:{type:"structure",systemKey:sessionStorage.getItem("systemKey"),parentTable:"",pageKey:E.value},value:{pageData:L}}}return ye}},ge=async(ye,T,ue)=>{var Le,Pe,la;let U=await he.getItemData(T,sessionStorage.getItem("systemKey"),""),Se=U==null?void 0:U.find(Da=>(Da==null?void 0:Da.name)===(ue==null?void 0:ue[0]));if(Se){if((Se==null?void 0:Se.comp)==="Table"){let Da={};for(let Te in A.cloneDeep(ye))A.cloneDeep(ye)[Te]!=="loginUser"?Da[Te]=A.cloneDeep(ye)[Te]:Da[Te]=((Le=b.value)==null?void 0:Le.account)||((Pe=b.value)==null?void 0:Pe.账号);let le=[],ta=Da;Array.isArray(ye)||(ta=[Da]),ta==null||ta.forEach(Te=>{le.push({[Te[ue[1]]]:Te})});let te=[],ca=le==null?void 0:le.map(Te=>{var Ue;return(Ue=Object.keys(Te))==null?void 0:Ue[0]});U==null||U.forEach(Te=>{var Ue;(Te==null?void 0:Te.name)===(ue==null?void 0:ue[0])&&((Ue=Te==null?void 0:Te.compData)==null||Ue.forEach(oa=>{var Ja;(oa==null?void 0:oa.key)==="tableContents"&&((Ja=oa==null?void 0:oa.contents)==null||Ja.forEach(L=>{L!=null&&L.some(H=>ca.includes(H))&&te.push({[L.find(H=>H.id).id]:L.find(H=>ca.includes(H))})}))}))});let Ee=te==null?void 0:te.map(Te=>{var Ue;return(Ue=Object.keys(Te))==null?void 0:Ue[0]}),oe=[];if(Ee==null||Ee.forEach(Te=>{var Ja;let Ue=(Ja=te==null?void 0:te.find(L=>{var H;return((H=Object.keys(L))==null?void 0:H[0].toString())===Te.toString()}))==null?void 0:Ja[Te],oa=le==null?void 0:le.find(L=>{var H;return((H=Object.keys(L))==null?void 0:H[0])===Ue});oe.push({id:parseInt(Te),value:{tableData:oa[Ue]}})}),(oe==null?void 0:oe.length)>0)return oe}else if((Se==null?void 0:Se.comp)==="Form"){let Da=A.cloneDeep(Se);Da.compData=(la=Da.compData)==null?void 0:la.map(te=>{var ca;return(te==null?void 0:te.key)==="formContent"&&(te.contents=(ca=te.contents)==null?void 0:ca.map(Ee=>((Ee==null?void 0:Ee.key)===(ue==null?void 0:ue[1])&&(Ee.value=(ye==null?void 0:ye[Ee==null?void 0:Ee.prop])||ye),Ee))),te});let le={};for(let te in Da)te!=="id"&&(le[te]=Da[te]);let ta=[];if(ta.push({id:Se==null?void 0:Se.id,keyType:ue==null?void 0:ue[1],value:{pageData:le}}),(ta==null?void 0:ta.length)>0)return ta}}},Me=async(ye,T,ue)=>{var Le,Pe,la,Da,le,ta,te,ca,Ee,oe;let U=await he.getItemData(T,sessionStorage.getItem("systemKey"),""),Se=U==null?void 0:U.find(Te=>(Te==null?void 0:Te.name)===(ue==null?void 0:ue[0]));if(Se){if((Se==null?void 0:Se.comp)==="Table"){let Te={};for(let Ue in A.cloneDeep(ye))A.cloneDeep(ye)[Ue]!=="loginUser"?Te[Ue]=A.cloneDeep(ye)[Ue]:Te[Ue]=((Le=b.value)==null?void 0:Le.account)||((Pe=b.value)==null?void 0:Pe.账号);await Tr.createInsofDataApi({key:{type:"data",pageKey:T,tableId:Se==null?void 0:Se.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Te}})}else if((Se==null?void 0:Se.comp)==="Form"){let Te=A.cloneDeep(Se),Ue=Object.keys(ye),oa="";(Da=(la=A.cloneDeep(Te))==null?void 0:la.compData)==null||Da.forEach(ve=>{var da,ea;(ve==null?void 0:ve.key)==="formContent"&&((ea=(da=A.cloneDeep(ve))==null?void 0:da.contents)==null||ea.forEach(ce=>{var pa;Ue.includes(ce==null?void 0:ce.key)&&(ce==null?void 0:ce.value)===((pa=b.value)==null?void 0:pa.姓名)&&(oa=ce==null?void 0:ce.key)}))});let Ja=[];(le=Object.values(ye[oa]))==null||le.forEach(ve=>{ve!=null&&ve.includes("(")&&Ja.push(ve)}),Ja=[...new Set(Ja)];const L=Ja==null?void 0:Ja.map(async ve=>{var Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q,Be,Je;let da="";(Va=(Qe=(Ca=(Ta=(We=(Ne=A.cloneDeep(ve))==null?void 0:Ne.split("("))==null?void 0:We[1])==null?void 0:Ta.split(")"))==null?void 0:Ca[0])==null?void 0:Qe.split(":"))==null||Va.forEach(ra=>{da=da===""?da+ra.replaceAll("'",""):da+"/"+ra.replaceAll("'","")});let ea=[];(Je=(Be=(q=(Z=(X=(ne=A.cloneDeep(ve))==null?void 0:ne.split("<"))==null?void 0:X[1])==null?void 0:Z.split(">"))==null?void 0:q[0])==null?void 0:Be.split(":"))==null||Je.forEach(ra=>{ea.push(ra.replaceAll("'",""))});const ce=await he.getItemData(da,sessionStorage.getItem("systemKey"),"");let pa="";return ce==null||ce.forEach(ra=>{var ba;ra.name===(ea==null?void 0:ea[0])&&((ba=ra==null?void 0:ra.compData)==null||ba.forEach(ga=>{var Aa;(ga==null?void 0:ga.key)==="formContent"&&((Aa=ga.contents)==null||Aa.forEach(_a=>{(_a==null?void 0:_a.key)===(ea==null?void 0:ea[1])&&(pa=_a==null?void 0:_a.value)}))}))}),{[ve]:pa}}),H=await Promise.all(L);Te.compData=(te=(ta=A.cloneDeep(Te))==null?void 0:ta.compData)==null?void 0:te.map(ve=>{var da,ea;return(ve==null?void 0:ve.key)==="formContent"&&(ve.contents=(ea=(da=A.cloneDeep(ve))==null?void 0:da.contents)==null?void 0:ea.map(ce=>{var pa,Ne,We,Ta;return(pa=ye[oa])!=null&&pa[ce==null?void 0:ce.key]&&(ye[oa][ce==null?void 0:ce.key].includes("(")?ce.value=(Ne=H==null?void 0:H.find(Ca=>{var Qe;return((Qe=Object.keys(Ca))==null?void 0:Qe[0])===ye[oa][ce==null?void 0:ce.key]}))==null?void 0:Ne[ye[oa][ce==null?void 0:ce.key]]:ce.value=(Ta=(We=A.cloneDeep(ye))==null?void 0:We[oa])==null?void 0:Ta[ce==null?void 0:ce.key]),ce})),ve});const Q=await Tr.getInsofDataApi({key:{type:"structure",pageKey:T,systemKey:sessionStorage.getItem("systemKey")}});let me="";((ca=Q==null?void 0:Q.data)==null?void 0:ca.type)==="success"&&((oe=(Ee=Q==null?void 0:Q.data)==null?void 0:Ee.result)==null||oe.forEach(ve=>{var da,ea;((ea=(da=ve==null?void 0:ve.value)==null?void 0:da.pageData)==null?void 0:ea.name)===(ue==null?void 0:ue[0])&&(me=ve.id)}),await Tr.updateInsofDataApi({id:me,value:{pageData:Te}}))}}},V=(ye,T="",ue={})=>{for(const[U,Se]of Object.entries(ye)){const Le=T?`${T}.${U}`:U;Se!==null&&typeof Se=="object"&&!Array.isArray(Se)&&Object.prototype.toString.call(Se)!=="[object Date]"?V(Se,Le,ue):ue[Le]=Se}return ue},fe=async(ye,T,ue,U)=>{var Pe,la,Da,le,ta,te,ca,Ee,oe,Te,Ue,oa,Ja,L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta;let Se=await he.getItemData(T,sessionStorage.getItem("systemKey"),""),Le=Se==null?void 0:Se.find(Ca=>(Ca==null?void 0:Ca.name)===(ue==null?void 0:ue[0]));if(Le){if(!(ue!=null&&ue[1])&&(Le==null?void 0:Le.comp)==="Table"){let Ca={},Qe=[],Va=(la=(Pe=Le==null?void 0:Le.compData)==null?void 0:Pe.find(Z=>(Z==null?void 0:Z.key)==="header"))==null?void 0:la.contents;Va!=null&&Va.every(Z=>Array.isArray(Z))?Qe=(le=he.getColumnChild((Da=Va==null?void 0:Va[0])==null?void 0:Da.filter(Z=>(Z==null?void 0:Z.label)!=="操作")))==null?void 0:le.map(Z=>Z==null?void 0:Z.prop):Qe=Va==null?void 0:Va.map(Z=>Z==null?void 0:Z.label);for(let Z in A.cloneDeep(ye))if(A.cloneDeep(ye)[Z]!=="loginUser"){let q=V(A.cloneDeep(ye)[Z]),Be={};for(let Je in q)if(Qe!=null&&Qe.find(ra=>ra===Je))Be[Je]=q[Je];else if(Qe!=null&&Qe.find(ra=>(ra==null?void 0:ra.toUpperCase())===(Je==null?void 0:Je.toUpperCase()))){let ra=Qe==null?void 0:Qe.find(ba=>(ba==null?void 0:ba.toUpperCase())===(Je==null?void 0:Je.toUpperCase()));Be[ra]=q[Je]}Ca[Z]=Be}else Ca[Z]=((ta=b.value)==null?void 0:ta.account)||((te=b.value)==null?void 0:te.账号);let ne=await Tr.getInsofDataApi({keyLikes:{tableId:Le==null?void 0:Le.id}});if(((Ee=(ca=ne==null?void 0:ne.data)==null?void 0:ca.result)==null?void 0:Ee.length)>0){let Z=(Te=(oe=ne==null?void 0:ne.data)==null?void 0:oe.result)==null?void 0:Te.map(q=>q==null?void 0:q.id);(Z==null?void 0:Z.length)>0&&await Tr.batchDeleteInsofDataApi({ids:Z})}let X=[];if((Ue=Le==null?void 0:Le.compData)!=null&&Ue.find(Z=>(Z==null?void 0:Z.key)==="pageColumn")&&((L=(Ja=(oa=Le==null?void 0:Le.compData)==null?void 0:oa.find(Z=>(Z==null?void 0:Z.key)==="pageColumn"))==null?void 0:Ja.contents)!=null&&L.includes("["))){const Z=await Tr.getInsofDataApi({id:Le==null?void 0:Le.tableId});let q=((ve=(me=(Q=(H=Z==null?void 0:Z.data)==null?void 0:H.result)==null?void 0:Q[0])==null?void 0:me.key)==null?void 0:ve.pageKey)??"";(da=Object.values(Ca))==null||da.forEach(Be=>{X.push({key:{type:"data",pageKey:q,tableId:Le==null?void 0:Le.tableId,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Be}})})}else(ea=Object.values(Ca))==null||ea.forEach(Z=>{X.push({key:{type:"data",pageKey:T,tableId:Le==null?void 0:Le.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Z}})});(X==null?void 0:X.length)>0&&await Tr.batchAddInsofDataApi({dataList:X})}else if(!(ue!=null&&ue[1])&&(Le==null?void 0:Le.comp)==="Form"){let Ca=A.cloneDeep(Le);Ca.compData=(pa=(ce=A.cloneDeep(Ca))==null?void 0:ce.compData)==null?void 0:pa.map(ne=>{var X,Z;return(ne==null?void 0:ne.key)==="formContent"&&(ne.contents=(Z=(X=A.cloneDeep(ne))==null?void 0:X.contents)==null?void 0:Z.map(q=>{var Be,Je;return(Be=A.cloneDeep(ye))!=null&&Be[q==null?void 0:q.key]&&(q.value=(Je=A.cloneDeep(ye))==null?void 0:Je[q==null?void 0:q.key]),q})),ne});const Qe=await Tr.getInsofDataApi({key:{type:"structure",pageKey:T,systemKey:sessionStorage.getItem("systemKey")}});let Va="";((Ne=Qe==null?void 0:Qe.data)==null?void 0:Ne.type)==="success"&&((Ta=(We=Qe==null?void 0:Qe.data)==null?void 0:We.result)==null||Ta.forEach(ne=>{var X,Z;((Z=(X=ne==null?void 0:ne.value)==null?void 0:X.pageData)==null?void 0:Z.name)===(ue==null?void 0:ue[0])&&(Va=ne.id)}),await Tr.updateInsofDataApi({id:Va,value:{pageData:Ca}}))}}},ae=async ye=>{var T,ue,U,Se,Le,Pe,la,Da,le,ta,te,ca,Ee,oe;c.setImportLoading(!0);try{if(ye.api){let Te=new WeakMap,Ue=await he.getItemData((k==null?void 0:k.value)===""?E.value:k==null?void 0:k.value,sessionStorage.getItem("systemKey"),"",!1,"","",Te),oa="";if(Ue=Ue==null?void 0:Ue.map(ea=>{var ce,pa,Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q;if((ea==null?void 0:ea.comp)==="Form")ea.compData=(ce=ea.compData)==null?void 0:ce.map(Be=>{var Je;return(Be==null?void 0:Be.key)==="formContent"&&(Be.contents=(Je=Be.contents)==null?void 0:Je.map(ra=>{var ba;if((ra==null?void 0:ra.value)===""&&(ra==null?void 0:ra.type)==="Select"){let ga=he.judgeContents((ba=A.cloneDeep(ra))==null?void 0:ba.optionUrl,Te);ra.value=ra.value||ga}return ra})),Be});else if((ea==null?void 0:ea.comp)==="Table"&&(pa=ea.compData)!=null&&pa.find(Be=>(Be==null?void 0:Be.key)==="pageColumn")){let Be=(We=(Ne=ea.compData)==null?void 0:Ne.find(ga=>(ga==null?void 0:ga.key)==="pageColumn"))==null?void 0:We.contents,Je=((Ca=(Ta=ea.compData)==null?void 0:Ta.find(ga=>(ga==null?void 0:ga.key)==="pageGroup"))==null?void 0:Ca.contents)??"",ra=(ne=(Va=(Qe=Be==null?void 0:Be.split("["))==null?void 0:Qe[1])==null?void 0:Va.split("]"))==null?void 0:ne[0];oa=((X=Be==null?void 0:Be.split("["))==null?void 0:X[0])+((q=(Z=I.value)==null?void 0:Z.find(ga=>(ga==null?void 0:ga.key)===ra))==null?void 0:q.value)}return ea}),!(oa===""||oa==="")){const ea=await he.getItemData(oa,sessionStorage.getItem("systemKey"),"",!1,"","",Te);Ue=Ue==null?void 0:Ue.map(ce=>{var pa,Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q,Be,Je;if((ce==null?void 0:ce.comp)==="Table"&&(pa=ce.compData)!=null&&pa.find(ra=>(ra==null?void 0:ra.key)==="pageColumn")){let ra=(We=(Ne=ce.compData)==null?void 0:Ne.find(Oe=>(Oe==null?void 0:Oe.key)==="pageColumn"))==null?void 0:We.contents,ba=((Ca=(Ta=ce.compData)==null?void 0:Ta.find(Oe=>(Oe==null?void 0:Oe.key)==="pageGroup"))==null?void 0:Ca.contents)??"",ga=(ne=(Va=(Qe=ra==null?void 0:ra.split("["))==null?void 0:Qe[1])==null?void 0:Va.split("]"))==null?void 0:ne[0],Aa=((X=ra==null?void 0:ra.split("["))==null?void 0:X[0])+((q=(Z=I.value)==null?void 0:Z.find(Oe=>(Oe==null?void 0:Oe.key)===ga))==null?void 0:q.value),_a=(Be=ea==null?void 0:ea.find(Oe=>(Oe==null?void 0:Oe.name)===(ba===""?t==null?void 0:t.compName:ba)))==null?void 0:Be.compData;ce.compData=(Je=ce.compData)==null?void 0:Je.map(Oe=>{var Za;return(Oe==null?void 0:Oe.key)==="tableContents"&&(Oe.contents=(Za=_a==null?void 0:_a.find(Ha=>(Ha==null?void 0:Ha.key)==="tableContents"))==null?void 0:Za.contents),Oe})}return ce})}let Ja={};if(((ue=(T=ye==null?void 0:ye.extraValues)==null?void 0:T.input)==null?void 0:ue.length)>0){const ea=(Se=(U=ye==null?void 0:ye.extraValues)==null?void 0:U.input)==null?void 0:Se.map(async ce=>{var pa;de!=null&&de.find(Ne=>Ne===ce)?Ja=await se(ce,Ue):Ja[Object.keys(ce)[0]]=await se((pa=Object.values(ce))==null?void 0:pa[0],Ue,Te)});await Promise.all(ea)}else Ja=await se("/",Ue);let L=!1;(Pe=(Le=ye==null?void 0:ye.extraValues)==null?void 0:Le.output)==null||Pe.forEach(ea=>{var ce,pa;(pa=(ce=Object.values(ea))==null?void 0:ce[0])!=null&&pa.includes(".doc")&&(L=!0)});let H;if(L){const ea=A.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});H=await qa.axios.post(ye.api,Ja,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{ea.close()})}else H=await qa.axios.post(ye.api,Ja,{headers:{"Content-Type":"application/json"}});let Q=(ta=(le=(Da=(la=A.cloneDeep(ye))==null?void 0:la.extraValues)==null?void 0:Da.output)==null?void 0:le.map(ea=>{var ce,pa,Ne,We,Ta,Ca,Qe,Va,ne,X,Z,q,Be,Je,ra,ba;if(!((pa=(ce=Object.values(ea))==null?void 0:ce[0])!=null&&pa.includes(".doc"))){let ga=(X=(ne=(Va=(We=A.cloneDeep((Ne=Object.values(ea))==null?void 0:Ne[0]))==null?void 0:We.split("["))==null?void 0:Va[((Qe=(Ca=A.cloneDeep((Ta=Object.values(ea))==null?void 0:Ta[0]))==null?void 0:Ca.split("["))==null?void 0:Qe.length)-1])==null?void 0:ne.split("]"))==null?void 0:X[0],Aa=ga==null?void 0:ga.split(":"),_a=(Be=A.cloneDeep((Z=Object.values(ea))==null?void 0:Z[0]))==null?void 0:Be.substring(0,A.cloneDeep((q=Object.values(ea))==null?void 0:q[0]).lastIndexOf("["));if(_a=(ra=A.cloneDeep(_a))==null?void 0:ra.slice(0,((Je=A.cloneDeep(_a))==null?void 0:Je.length)-1),_a!=null&&_a.includes("[")){let Oe="";if((ba=he.contentTransArrayToAll(_a,"/"))==null||ba.forEach(Za=>{var Ha,xl,Jl,kl,Pl,ja,Ml;if(!(Za!=null&&Za.includes("[")))Oe=Oe===""?Oe+Za.replaceAll("/",""):Oe+"/"+Za.replaceAll("/","");else{let $l=A.cloneDeep(Za).slice(1,((Ha=A.cloneDeep(Za))==null?void 0:Ha.length)-1),Ma=(ja=(Pl=(kl=(Jl=(xl=A.cloneDeep($l))==null?void 0:xl.split("["))==null?void 0:Jl[1])==null?void 0:kl.split("]"))==null?void 0:Pl[0])==null?void 0:ja.split(":"),rl="",sl=(Ml=Ue==null?void 0:Ue.find(ma=>(ma==null?void 0:ma.name)===(Ma==null?void 0:Ma[0])))==null?void 0:Ml.compData;sl==null||sl.forEach(ma=>{var ka;(ma==null?void 0:ma.key)==="formContent"&&((ka=ma==null?void 0:ma.contents)==null||ka.forEach(La=>{(La==null?void 0:La.key)===(Ma==null?void 0:Ma[1])&&(rl=La==null?void 0:La.value)}))}),Oe=Oe===""?Oe+rl.replaceAll("/",""):Oe+"/"+rl.replaceAll("/","")}}),_a=Oe,_a[(_a==null?void 0:_a.length)-1]!=="/")return _a}}}))==null?void 0:ta.filter(ea=>ea);Q=[...new Set(A.cloneDeep(Q))];let me=Q==null?void 0:Q.map(async ea=>{let ce=await he.getItemData(ea,sessionStorage.getItem("systemKey"),"",!1,"","",Te);if((ce==null?void 0:ce.length)===0)return await he.getParentContents(ea)});await Promise.all(me);let ve=[],da=(Ee=(ca=(te=A.cloneDeep(ye))==null?void 0:te.extraValues)==null?void 0:ca.output)==null?void 0:Ee.map(async ea=>{var Va,ne,X,Z,q,Be,Je,ra,ba,ga,Aa,_a,Oe,Za,Ha,xl,Jl,kl,Pl,ja,Ml,$l,Ma,rl,sl,ma,ka,La,$a,we,ia,Ie,pe,ha,va,Xe,Ze,Ke,pl,Ve,Fa,Sa,il,Ia,ze,_l,Ol,ql,Wl,Ql,pr,Ll,fr,Vr,jl,ar,Fr,Nr,Pr,Mr,Sr,Er,mn,Dr,ur,yn,ln,rn,_n,Bn;if((ne=(Va=Object.values(ea))==null?void 0:Va[0])!=null&&ne.includes(".doc")){var ce=new Blob([H.data],{type:"application/octet-stream;charset=UTF-8"}),pa=H.headers["content-disposition"],Ne=new RegExp("filename=([^;]+\\.[^\\.;]+);*"),We=Ne.exec(pa),Ta=We==null?void 0:We[1],Ca=document.createElement("a"),Qe=window.URL.createObjectURL(ce);v.value=[{name:Ta,blobUrl:Qe}],s.value=!0}else{let pn=(ga=(ba=(ra=(Z=A.cloneDeep((X=Object.values(ea))==null?void 0:X[0]))==null?void 0:Z.split("["))==null?void 0:ra[((Je=(Be=A.cloneDeep((q=Object.values(ea))==null?void 0:q[0]))==null?void 0:Be.split("["))==null?void 0:Je.length)-1])==null?void 0:ba.split("]"))==null?void 0:ga[0],lr=pn==null?void 0:pn.split(":"),Il=(Oe=A.cloneDeep((Aa=Object.values(ea))==null?void 0:Aa[0]))==null?void 0:Oe.substring(0,A.cloneDeep((_a=Object.values(ea))==null?void 0:_a[0]).lastIndexOf("["));if(Il!=null&&Il.includes("[")?Il=(Ha=A.cloneDeep(Il))==null?void 0:Ha.slice(0,((Za=A.cloneDeep(Il))==null?void 0:Za.length)-1):Il===""&&(Il=E.value),Il=Il.replaceAll("<","[").replaceAll(">","]"),Il!=null&&Il.includes("[")){let cl="";(xl=he.contentTransArrayToAll(Il,"/"))==null||xl.forEach((cr,Vl)=>{var _r,Gl,hr,Or,gn,Nn,bn,Un,Ln,kn,Tn;if(!(cr!=null&&cr.includes("[")))cl=cl===""?cl+cr.replaceAll("/",""):cl+"/"+cr.replaceAll("/","");else{let Rn="",Qr="";(_r=A.cloneDeep(cr))!=null&&_r.includes("]")?(Rn=A.cloneDeep(cr).slice(1,((Gl=A.cloneDeep(cr))==null?void 0:Gl.length)-1),Qr=(bn=(Nn=(gn=(Or=(hr=A.cloneDeep(Rn))==null?void 0:hr.split("["))==null?void 0:Or[1])==null?void 0:gn.split("]"))==null?void 0:Nn[0])==null?void 0:bn.split(":")):(Rn=A.cloneDeep(cr).slice(1,(Un=A.cloneDeep(cr))==null?void 0:Un.length),Qr=(Ln=A.cloneDeep(Rn))==null?void 0:Ln.split("/"));let An="",qn=(kn=Ue==null?void 0:Ue.find(Lr=>(Lr==null?void 0:Lr.name)===(Qr==null?void 0:Qr[0])))==null?void 0:kn.compData;qn==null||qn.forEach(Lr=>{var Wn;(Lr==null?void 0:Lr.key)==="formContent"&&((Wn=Lr==null?void 0:Lr.contents)==null||Wn.forEach(fn=>{(fn==null?void 0:fn.key)===(Qr==null?void 0:Qr[1])&&(An=fn==null?void 0:fn.value)}))}),((Tn=he.contentTransArrayToAll(Il,"/"))==null?void 0:Tn.length)-1!==Vl?cl=cl===""?cl+An.replaceAll("/",""):cl+"/"+An.replaceAll("/",""):cl=cl+n.value+An.replaceAll("/","")}}),(Jl=E.value)!=null&&Jl.includes(cl)?Il=E.value:Il=cl}let Ar=A.cloneDeep((kl=Object.keys(ea))==null?void 0:kl[0]);if(((Pl=H==null?void 0:H.data)==null?void 0:Pl.statusCode)===200||((ja=H==null?void 0:H.data)==null?void 0:ja.code)===200){if((($l=(Ml=H==null?void 0:H.data)==null?void 0:Ml.data)!=null&&$l[Ar]||(rl=(Ma=H==null?void 0:H.data)==null?void 0:Ma.result)!=null&&rl[Ar])&&(lr==null?void 0:lr.length)===1)return await fe(((ma=(sl=H==null?void 0:H.data)==null?void 0:sl.data)==null?void 0:ma[Ar])||((La=(ka=H==null?void 0:H.data)==null?void 0:ka.result)==null?void 0:La[Ar]),A.cloneDeep(Il),lr,oa);if((we=($a=H==null?void 0:H.data)==null?void 0:$a.data)!=null&&we[Ar]||(Ie=(ia=H==null?void 0:H.data)==null?void 0:ia.result)!=null&&Ie[Ar]){let cl=await ge(((ha=(pe=H==null?void 0:H.data)==null?void 0:pe.data)==null?void 0:ha[Ar])||((Xe=(va=H==null?void 0:H.data)==null?void 0:va.result)==null?void 0:Xe[Ar]),A.cloneDeep(Il),lr);return cl&&(ve=[...ve,...cl]),cl}else{if(!((Ze=H==null?void 0:H.data)!=null&&Ze.data)){let cl=await he.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,"","",Te);cl=cl==null?void 0:cl.map(Vl=>{var _r;return(Vl==null?void 0:Vl.name)===(lr==null?void 0:lr[0])&&(Vl.compData=(_r=Vl.compData)==null?void 0:_r.map(Gl=>{var hr;return(Gl==null?void 0:Gl.key)==="formContent"&&(Gl.contents=(hr=Gl.contents)==null?void 0:hr.map(Or=>{var gn,Nn;return(Or==null?void 0:Or.key)===(lr==null?void 0:lr[1])&&(Or.value=(Nn=(gn=H==null?void 0:H.data)==null?void 0:gn.result)==null?void 0:Nn[Ar==null?void 0:Ar.replaceAll(":","")]),Or})),Gl})),Vl});let cr=[];(Ke=cl==null?void 0:cl.filter(Vl=>(Vl==null?void 0:Vl.comp)==="Form"))==null||Ke.forEach(async Vl=>{let _r={};for(let Gl in Vl)Gl!=="id"&&(_r[Gl]=Vl[Gl]);cr.push({id:Vl==null?void 0:Vl.id,value:{pageData:_r}})}),(cr==null?void 0:cr.length)>0&&await Tr.batchUpdateInsofDataApi({dataList:cr});return}if((lr==null?void 0:lr.length)===1){const cl=(Fa=(Ve=(pl=H==null?void 0:H.data)==null?void 0:pl.data)==null?void 0:Ve.path)==null?void 0:Fa.path;let cr="";(_l=(ze=(Ia=(il=(Sa=cl==null?void 0:cl.split("("))==null?void 0:Sa[1])==null?void 0:il.split(")"))==null?void 0:Ia[0])==null?void 0:ze.split(":"))==null||_l.forEach(Gl=>{var hr,Or;cr=cr===""?cr+((hr=Gl==null?void 0:Gl.replaceAll("'",""))==null?void 0:hr.trim()):cr+"/"+((Or=Gl==null?void 0:Gl.replaceAll("'",""))==null?void 0:Or.trim())});let Vl=[(pr=(Ql=(Wl=(ql=(Ol=cl==null?void 0:cl.split("<"))==null?void 0:Ol[1])==null?void 0:ql.split(">"))==null?void 0:Wl[0])==null?void 0:Ql.replaceAll("'",""))==null?void 0:pr.trim()],_r;return(Vr=(fr=(Ll=H==null?void 0:H.data)==null?void 0:Ll.data)==null?void 0:fr.data)!=null&&Vr[lr==null?void 0:lr[0]]?_r=await fe((Fr=(ar=(jl=H==null?void 0:H.data)==null?void 0:jl.data)==null?void 0:ar.data)==null?void 0:Fr[lr==null?void 0:lr[0]],cr,lr,oa):_r=await Me((Pr=(Nr=H==null?void 0:H.data)==null?void 0:Nr.data)==null?void 0:Pr.data,cr,Vl,Te),_r}else{const cl=(Er=(Sr=(Mr=H==null?void 0:H.data)==null?void 0:Mr.data)==null?void 0:Sr.path)==null?void 0:Er.path;let cr="";return(ln=(yn=(ur=(Dr=(mn=cl==null?void 0:cl.split("("))==null?void 0:mn[1])==null?void 0:Dr.split(")"))==null?void 0:ur[0])==null?void 0:yn.split(":"))==null||ln.forEach(_r=>{var Gl,hr;cr=cr===""?cr+((Gl=_r==null?void 0:_r.replaceAll("'",""))==null?void 0:Gl.trim()):cr+"/"+((hr=_r==null?void 0:_r.replaceAll("'",""))==null?void 0:hr.trim())}),await ge((Bn=(_n=(rn=H==null?void 0:H.data)==null?void 0:rn.data)==null?void 0:_n.data)==null?void 0:Bn[lr==null?void 0:lr[0]],cr,lr)}}}}});if(await Promise.all(da),(ve==null?void 0:ve.length)>0){let ea=[];ve==null||ve.forEach(Ne=>{ea!=null&&ea.find(We=>{var Ta,Ca,Qe,Va;return((Ca=(Ta=We==null?void 0:We.value)==null?void 0:Ta.pageData)==null?void 0:Ca.name)===((Va=(Qe=Ne==null?void 0:Ne.value)==null?void 0:Qe.pageData)==null?void 0:Va.name)})||ea.push(Ne)});let ce=[];ea==null||ea.forEach(Ne=>{var Ca,Qe,Va,ne;let We=A.cloneDeep(Ne);We.value.pageData.compData=(Ca=We.value.pageData.compData)==null?void 0:Ca.map(X=>{var Z;return(X==null?void 0:X.key)==="formContent"&&(X.contents=(Z=X.contents)==null?void 0:Z.map(q=>{var Je,ra,ba,ga;let Be=(Je=A.cloneDeep(ve))==null?void 0:Je.find(Aa=>(Aa==null?void 0:Aa.keyType)===(q==null?void 0:q.key));if(Be){let Aa=(ga=(ba=(ra=Be.value.pageData.compData)==null?void 0:ra.find(_a=>(_a==null?void 0:_a.key)==="formContent"))==null?void 0:ba.contents)==null?void 0:ga.find(_a=>(_a==null?void 0:_a.key)===(q==null?void 0:q.key));q.value=Aa==null?void 0:Aa.value}return q})),X}),ce.push({id:We==null?void 0:We.id,value:We==null?void 0:We.value});let Ta=[];(ne=(Va=(Qe=We==null?void 0:We.value)==null?void 0:Qe.pageData)==null?void 0:Va.compData)==null||ne.forEach(X=>{var Z;(X==null?void 0:X.key)==="formContent"&&((Z=X==null?void 0:X.contents)==null||Z.forEach(q=>{var Be,Je,ra,ba,ga,Aa;if((Je=(Be=q==null?void 0:q.optionUrl)==null?void 0:Be.menuSelect)!=null&&Je.find(_a=>_a==null?void 0:_a.includes("[")))if(Ta!=null&&Ta.find(_a=>{var Oe,Za,Ha;return((Oe=_a==null?void 0:_a.key)==null?void 0:Oe.join(","))===((Ha=(Za=q==null?void 0:q.optionUrl)==null?void 0:Za.menuSelect)==null?void 0:Ha.join(","))})){let _a=(ra=Ta==null?void 0:Ta.find(Oe=>{var Za,Ha,xl;return((Za=Oe==null?void 0:Oe.key)==null?void 0:Za.join(","))===((xl=(Ha=q==null?void 0:q.optionUrl)==null?void 0:Ha.menuSelect)==null?void 0:xl.join(","))}))==null?void 0:ra.value;_a.push({key:q==null?void 0:q.prop,groups:(ba=q==null?void 0:q.optionUrl)==null?void 0:ba.groupSelect,value:q==null?void 0:q.value}),Ta=Ta==null?void 0:Ta.map(Oe=>{var Za,Ha,xl;return((Za=Oe==null?void 0:Oe.key)==null?void 0:Za.join(","))===((xl=(Ha=q==null?void 0:q.optionUrl)==null?void 0:Ha.menuSelect)==null?void 0:xl.join(","))&&(Oe.value=_a),Oe})}else Ta.push({key:(ga=q==null?void 0:q.optionUrl)==null?void 0:ga.menuSelect,value:[{key:q==null?void 0:q.prop,groups:(Aa=q==null?void 0:q.optionUrl)==null?void 0:Aa.groupSelect,value:q==null?void 0:q.value}]})}))}),(Ta==null?void 0:Ta.length)>0&&(Ta=Ta==null?void 0:Ta.map(X=>{var q;let Z="";return(q=X==null?void 0:X.key)==null||q.forEach(Be=>{var Je;if(!(Be!=null&&Be.includes("[")))Z=Z===""?Z+Be:Z+"/"+Be;else{let ra="",ba=(Je=Be==null?void 0:Be.replaceAll("[","").replaceAll("]",""))==null?void 0:Je.split(":");Ue==null||Ue.forEach(ga=>{var Aa;(ga==null?void 0:ga.name)===(ba==null?void 0:ba[0])&&((Aa=ga==null?void 0:ga.compData)==null||Aa.forEach(_a=>{var Oe;(_a==null?void 0:_a.key)==="formContent"&&((Oe=_a==null?void 0:_a.contents)==null||Oe.forEach(Za=>{(Za==null?void 0:Za.prop)===(ba==null?void 0:ba[1])&&(ra=Za==null?void 0:Za.value)}))}))}),Z=Z+n.value+ra}}),X.key=Z,X})),Ta==null||Ta.forEach(X=>{var Je,ra,ba;let Z=(Je=Te[X.key])==null?void 0:Je.find(ga=>{var Aa,_a,Oe,Za,Ha,xl,Jl;return((_a=(Aa=ga==null?void 0:ga.value)==null?void 0:Aa.pageData)==null?void 0:_a.name)===((Ha=(Za=(Oe=X==null?void 0:X.value)==null?void 0:Oe[0])==null?void 0:Za.groups)==null?void 0:Ha[0])&&((Jl=(xl=ga==null?void 0:ga.value)==null?void 0:xl.pageData)==null?void 0:Jl.name)!==void 0}),q=Z==null?void 0:Z.id,Be=(ra=Z==null?void 0:Z.value)==null?void 0:ra.pageData;Be.compData=(ba=Be.compData)==null?void 0:ba.map(ga=>{var Aa;return(ga==null?void 0:ga.key)==="formContent"&&(ga.contents=(Aa=ga.contents)==null?void 0:Aa.map(_a=>{var Za;let Oe=(Za=X.value)==null?void 0:Za.find(Ha=>(Ha==null?void 0:Ha.key)===(_a==null?void 0:_a.prop));return Oe&&(_a.value=Oe.value),_a})),ga}),ce.push({id:q,value:{pageData:Be}})})});let pa=(oe=A.cloneDeep(ve))==null?void 0:oe[0];(ce==null?void 0:ce.length)>0&&await Tr.batchUpdateInsofDataApi({dataList:ce})}y.setFreshContent(!0)}c.setImportLoading(!1)}catch{qa.ElMessage.error("方法执行错误,请查看方法!"),c.setImportLoading(!1)}w.value=!0},de=["createInsofDataApi"],De=Bl.debounce(async ye=>{ae(ye)},100),Fe=async ye=>{var Pe,la,Da;const T=A.cloneDeep(ye);let ue,U=new WeakMap;ye!=null&&ye[0].path&&(ue=await(T==null?void 0:T.map(async(le,ta)=>{var Ja,L,H,Q,me,ve,da,ea,ce,pa,Ne,We,Ta,Ca,Qe,Va;const ca=(Ja=U[le==null?void 0:le.path])==null?void 0:Ja.filter(ne=>{var X;return((X=ne==null?void 0:ne.key)==null?void 0:X.type)==="data"});let Ee="";const oe=await he.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,U);ca==null||ca.forEach(ne=>{var X,Z,q,Be,Je;((Z=(X=ne==null?void 0:ne.value)==null?void 0:X.tableData)==null?void 0:Z.算法名称)===((q=T==null?void 0:T[ta])==null?void 0:q.method)&&(Ee=(Je=(Be=ne==null?void 0:ne.value)==null?void 0:Be.tableData)==null?void 0:Je.算法体)});const Te=await he.getItemData(le==null?void 0:le.path,sessionStorage.getItem("systemKey"),"",!1,[],!1,U);let Ue="",oa=(me=(Q=(H=(L=Te==null?void 0:Te[0])==null?void 0:L.compData)==null?void 0:H.find(ne=>(ne==null?void 0:ne.key)==="header"))==null?void 0:Q.contents)==null?void 0:me.findIndex(ne=>(ne==null?void 0:ne.prop)==="算法体");return(da=(ve=Te==null?void 0:Te[0])==null?void 0:ve.compData)==null||da.forEach(ne=>{var X;(ne==null?void 0:ne.key)==="tableContents"&&((X=ne==null?void 0:ne.contents)==null||X.forEach(Z=>{Z!=null&&Z.find(q=>q===(le==null?void 0:le.method))&&(Ue=Z[oa])}))}),{buttonName:((ea=T==null?void 0:T[ta])==null?void 0:ea.method)||((Ne=(pa=(ce=ca==null?void 0:ca[0])==null?void 0:ce.value)==null?void 0:pa.tableData)==null?void 0:Ne.算法名称),api:(Ee===""?(Ca=(Ta=(We=ca==null?void 0:ca[0])==null?void 0:We.value)==null?void 0:Ta.tableData)==null?void 0:Ca.算法体:Ee)||Ue,content:oe==null?void 0:oe.filter(ne=>ne.comp!=="methodButton"),extraContent:(Qe=A.cloneDeep(le.value))==null?void 0:Qe.slice(1),methodName:(le==null?void 0:le.path)??"",extraValues:(Va=T==null?void 0:T[ta])==null?void 0:Va.data}})));const Se=T==null?void 0:T.map(async le=>{var Te,Ue,oa,Ja,L,H;const ta=(Te=resAll.data.result)==null?void 0:Te.filter(Q=>{var me,ve,da;return((me=Q==null?void 0:Q.key)==null?void 0:me.parentTable)===""&&((ve=Q==null?void 0:Q.key)==null?void 0:ve.type)==="method"&&((da=Q==null?void 0:Q.key)==null?void 0:da.methodName)===Q.method}),te=ta==null?void 0:ta[0],ca=(Ue=resAll.data.result)==null?void 0:Ue.filter(Q=>{var me,ve;return((me=Q==null?void 0:Q.key)==null?void 0:me.type)==="methodData"&&((ve=Q==null?void 0:Q.key)==null?void 0:ve.tableId)===(te==null?void 0:te.id)}),Ee=await he.getItemData(E.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,U),oe=ca==null?void 0:ca[0];return{buttonName:(oa=te==null?void 0:te.key)==null?void 0:oa.methodKey,api:(L=(Ja=oe==null?void 0:oe.value)==null?void 0:Ja.tableData)==null?void 0:L[0],content:Ee==null?void 0:Ee.filter(Q=>Q.comp!=="methodButton"),extraContent:(H=A.cloneDeep(le.value))==null?void 0:H.slice(1),methodName:(le==null?void 0:le.method)??""}}),Le=(Pe=ye==null?void 0:ye[0])!=null&&Pe.path&&((la=ye==null?void 0:ye[0])==null?void 0:la.path)!==""?await Promise.all(ue):await Promise.all(Se);l.value=Le==null?void 0:Le.filter(le=>le==null?void 0:le.extraContent),(Da=l.value)==null||Da.forEach(le=>{var ta;le.api===""&&((ta=le.content)==null||ta.forEach(te=>{var ca;te.comp=="Table"&&y.setExtraContents(he.methodTableToContent(te.compData,(ca=le.extraContent)==null?void 0:ca[0]))}))})};return e.watch(()=>t.itemData,async()=>{S.value=="view"&&!w.value&&await Fe(A.cloneDeep(t.itemData)),w.value=!1},{immediate:!0,deep:!0}),(ye,T)=>{var ue,U,Se;return e.unref(S)!=="edit"?(e.openBlock(),e.createElementBlock("div",e4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((ue=l.value)==null?void 0:ue.filter(Le=>(Le==null?void 0:Le.buttonName)!=="保存"),Le=>{var Pe;return e.openBlock(),e.createElementBlock("div",null,[Le.api!==""?(e.openBlock(),e.createBlock(e.unref(ls._sfc_main),{key:0,disabled:e.unref(R)===e.unref(E)&&!((Pe=Le==null?void 0:Le.buttonName)!=null&&Pe.includes("预览")),class:"calculator-content",modelValue:Le.buttonName,onClickTrigger:la=>e.unref(De)(Le),loading:g.value},null,8,["disabled","modelValue","onClickTrigger","loading"])):e.createCommentVNode("",!0)])}),256)),e.createElementVNode("div",null,[e.unref(K)!==""&&((Se=e.unref(E))==null?void 0:Se[((U=e.unref(E))==null?void 0:U.length)-1])!==e.unref(n)?(e.openBlock(),e.createBlock(e.unref(ls._sfc_main),{key:0,class:"calculator-content",onClickTrigger:$,modelValue:"保存"})):e.createCommentVNode("",!0)]),s.value?(e.openBlock(),e.createBlock(ll.ssFilePreview,{key:0,fileDataList:v.value,onDestroy:F},null,8,["fileDataList"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},l4=Zl._export_sfc(a4,[["__scopeId","data-v-063aa9af"]]),r4={};function n4(a,l){return" 567 "}const i4=Zl._export_sfc(r4,[["render",n4]]),o4={class:"module content"},t4={class:"module data"},s4={class:"module layout"},c4={class:"form-content"},u4=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,t=e.reactive({visible:!1,width:"40%",title:"签名配置"}),s=e.ref("create"),v=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),d=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}]),p=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:""}]),y=e.ref({}),g=e.ref([]),c=()=>({comp:"Signature",compData:[{key:"signTypeList",contents:g.value},{key:"signConfig",contents:y.value}]}),D=I=>{var R;y.value=A.cloneDeep(I),n("change",(R=c())==null?void 0:R.compData)},M=I=>{var R,j;if((I==null?void 0:I.buttonName)==="确认"){const E=A.cloneDeep(I==null?void 0:I.content);switch(s.value){case"create":g.value.push({...E,index:((R=g.value)==null?void 0:R.length)+1});break}n("change",(j=c())==null?void 0:j.compData),t.visible=!1}else t.visible=!1},S=(I,R)=>{var j,E;switch(I){case"create":(j=p.value)==null||j.forEach(x=>{x.value=""}),s.value="create",t.visible=!0;break;case"update":(E=p.value)==null||E.forEach(x=>{x.value=R[x==null?void 0:x.prop]}),s.value="update",t.visible=!0;break;case"delete":g.value.splice(R,1),s.value="delete";break}},K=()=>{t.visible=!1};return e.watch(()=>r==null?void 0:r.itemContents,I=>{var R,j;I&&(y.value=((R=I==null?void 0:I.find(E=>E.key==="signConfig"))==null?void 0:R.contents)??{},g.value=((j=I==null?void 0:I.find(E=>E.key==="signTypeList"))==null?void 0:j.contents)??[])},{immediate:!0}),(I,R)=>{const j=e.resolveComponent("svg-icon"),E=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",o4,[R[2]||(R[2]=e.createElementVNode("h4",{class:"module-title"},"签名类型",-1)),e.createVNode(E,{class:"module-icon",id:"themeButton",onClick:R[0]||(R[0]=x=>S("create"))},{icon:e.withCtx(()=>[e.createVNode(j,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[R[1]||(R[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",t4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(x,k)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:k},[e.createElementVNode("span",null,e.toDisplayString(x==null?void 0:x.label),1),e.createElementVNode("div",null,[e.createVNode(E,{type:"primary",size:"small",onClick:b=>S("update",{...x,index:k+1})},{default:e.withCtx(()=>R[3]||(R[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(E,{type:"danger",size:"small",onClick:b=>S("delete",k)},{default:e.withCtx(()=>R[4]||(R[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",s4,[e.createVNode(ll.ssForm,{rowContents:d.value,onChange:D},null,8,["rowContents"])])]),e.createVNode(wr.ssDialog,{visible:t.visible,title:t.title,onBeforeDestroy:K,width:t.width},{default:e.withCtx(()=>[e.createElementVNode("div",c4,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:p.value,key:p.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:v.value,onOnButtonClick:M},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),d4=Zl._export_sfc(u4,[["__scopeId","data-v-487e0536"]]),p4=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,t=e.ref(0),s=e.computed(()=>{var c,D;return(c=r==null?void 0:r.stepConfig)!=null&&c.allowTrigger?t.value:(D=r==null?void 0:r.stepConfig)==null?void 0:D.active}),v=(c,D)=>{t.value=D-1,n("clickStep",c,D)};e.onMounted(()=>{var c;n("clickStep",(c=r==null?void 0:r.stepList)==null?void 0:c[0],0)});const d=c=>ll.getComponent(c),p=()=>{var D;const c=(D=r==null?void 0:r.stepList)==null?void 0:D.find((M,S)=>S+1===s.value);return console.log("findStep",c),c?c==null?void 0:c.children:[]},y=c=>{n("clickTrigger",c)},g=c=>{n("changeTrigger",c)};return(c,D)=>{var K,I,R,j,E;const M=e.resolveComponent("el-step"),S=e.resolveComponent("el-steps");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(S,{direction:(K=a.stepConfig)==null?void 0:K.direction,active:s.value,"finish-status":"success",simple:(I=a.stepConfig)==null?void 0:I.simple,"align-center":((R=a.stepConfig)==null?void 0:R.alignCenter)??!0},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.stepList,(x,k)=>(e.openBlock(),e.createBlock(M,{key:k,class:"step-item",onClick:b=>v(x,k+1)},{title:e.withCtx(()=>[e.renderSlot(c.$slots,"title",{title:x==null?void 0:x.title},void 0,!0)]),description:e.withCtx(()=>[e.renderSlot(c.$slots,"description",{descriptions:x==null?void 0:x.description},void 0,!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["direction","active","simple","align-center"]),(j=a.stepConfig)!=null&&j.allowTrigger&&((E=a.stepConfig)!=null&&E.active)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(p(),(x,k)=>(e.openBlock(),e.createElementBlock("div",{key:k,class:"step-cont-wrap"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d(x==null?void 0:x.type)),{modelValue:x.value,"onUpdate:modelValue":b=>x.value=b,onClickTrigger:y,onChangeTrigger:g,content:x==null?void 0:x.content},e.createSlots({_:2},[e.renderList(c.$slots,(b,w)=>({name:w,fn:e.withCtx($=>[e.renderSlot(c.$slots,w,e.mergeProps({ref_for:!0},$||{}),void 0,!0)])}))]),1064,["modelValue","onUpdate:modelValue","content"]))]))),128)):e.createCommentVNode("",!0)],64)}}}),f4=Zl._export_sfc(p4,[["__scopeId","data-v-fdbd6832"]]),h4=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]}},emits:["clickStep"],setup(a,{emit:l}){const r=a,n=l,t=e.ref({}),s=e.ref([]),v=(d,p)=>{n("clickStep",d,p)};return e.watch(()=>r==null?void 0:r.itemData,d=>{var c,D,M,S;t.value={direction:"horizontal",simple:!1,alignCenter:!0,allowTrigger:!0};let p=((c=d==null?void 0:d.find(K=>(K==null?void 0:K.key)==="stepName"))==null?void 0:c.contents)??[],y=[];(M=(D=d==null?void 0:d.find(K=>(K==null?void 0:K.key)==="header"))==null?void 0:D.contents)==null||M.forEach(K=>{y.push({label:K==null?void 0:K.label,prop:K==null?void 0:K.prop,name:K==null?void 0:K.prop,type:"text",disabled:!0})});let g=((S=d==null?void 0:d.find(K=>(K==null?void 0:K.key)==="tableContents"))==null?void 0:S.contents)??[];p=p==null?void 0:p.map((K,I)=>{let R=y==null?void 0:y.map(j=>{var E;return{...j,value:(E=g==null?void 0:g[I])==null?void 0:E[j==null?void 0:j.prop]}});return{title:K,description:R}}),s.value=p},{immediate:!0,deep:!0}),(d,p)=>{const y=e.resolveComponent("svg-icon");return e.openBlock(),e.createBlock(f4,{stepConfig:t.value,stepList:s.value,onClickStep:v},{icon:e.withCtx(()=>[e.createVNode(y,{name:"import"})]),title:e.withCtx(({title:g})=>[e.createTextVNode(e.toDisplayString(g),1)]),description:e.withCtx(({descriptions:g})=>[e.createVNode(ll.ssForm,{ref:"formRef",rowContents:g,showOperator:!0,isEnableWrap:!1,isEdit:!1},null,8,["rowContents"])]),_:1},8,["stepConfig","stepList"])}}}),v4=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"),t=e.resolveComponent("el-timeline");return e.openBlock(),e.createBlock(t,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.activities,(s,v)=>(e.openBlock(),e.createBlock(n,{key:v,timestamp:s.timestamp,placement:a.timeLineConfig.placement,center:a.timeLineConfig.isCenter,"hide-timestamp":!0,type:a.timeLineConfig.type,color:a.timeLineConfig.color,size:a.timeLineConfig.size,icon:a.timeLineConfig.icon,hollow:a.timeLineConfig.isHollow},{default:e.withCtx(()=>[e.renderSlot(l.$slots,"content",{content:s==null?void 0:s.content,timestamp:s==null?void 0:s.timestamp},void 0,!0)]),_:2},1032,["timestamp","placement","center","type","color","size","icon","hollow"]))),128))]),_:3})}}}),m4=Zl._export_sfc(v4,[["__scopeId","data-v-4172a886"]]),y4={class:"line-content"},g4={class:"line-time"},b4=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,t=>{var s,v;n.value=(s=t==null?void 0:t.find(d=>(d==null?void 0:d.key)==="timeLineList"))==null?void 0:s.contents,r.value=(v=t==null?void 0:t.find(d=>(d==null?void 0:d.key)==="timeLineConfig"))==null?void 0:v.contents},{immediate:!0}),(t,s)=>(e.openBlock(),e.createBlock(m4,{activities:n.value,timeLineConfig:r.value},{content:e.withCtx(({content:v,timestamp:d})=>[e.createElementVNode("span",y4,e.toDisplayString(v),1),e.createElementVNode("span",g4,e.toDisplayString(d),1)]),_:1},8,["activities","timeLineConfig"]))}}),k4=Zl._export_sfc(b4,[["__scopeId","data-v-b4d9deed"]]),x4={class:"tabs-content"},w4=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,t=e.ref();e.watch(()=>r==null?void 0:r.itemData,()=>{t.value=r==null?void 0:r.itemData},{immediate:!0,deep:!0});const s=D=>{n("change",D)},v=(D,M)=>{n("contentChange",D,M)},d=D=>{n("pageChange",D)},p=D=>{n("rowClick",D)},y=(D,M)=>{n("routeUrl",D,M)},g=D=>{n("clickTrigger",D)},c=(D,M)=>{n("clickMainKey",D,M)};return(D,M)=>{var S,K;return e.openBlock(),e.createElementBlock("div",x4,[(S=t.value)!=null&&S.length?(e.openBlock(),e.createBlock(ll.ssTab,{tabsContents:t.value,key:(K=t.value)==null?void 0:K.length},{pane:e.withCtx(({tab:I,index:R})=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Gi)(I==null?void 0:I.comp)),{related:I==null?void 0:I.relatedTables,compNames:r==null?void 0:r.compNames,compName:I==null?void 0:I.name,cacheNewData:r==null?void 0:r.cacheNewData,isDevMode:a.isDevMode,itemData:I==null?void 0:I.compData,childItemData:I==null?void 0:I.itemChildData,onChange:s,index:(I==null?void 0:I.id)??R,config:{showIndex:I==null?void 0:I.showIndex,allowMove:I==null?void 0:I.allowMove,viewport:I==null?void 0:I.viewport,status:I==null?void 0:I.status},onContentChange:v,onPageChange:d,onRowClick:p,onRouteUrl:y,parentTableId:I==null?void 0:I.tableId,allMapContents:a.allMapContents,children:I==null?void 0:I.children,level:1,onClickTrigger:g,onClickMainKey:c},null,40,["related","compNames","compName","cacheNewData","isDevMode","itemData","childItemData","index","config","parentTableId","allMapContents","children"]))]),_:1},8,["tabsContents"])):e.createCommentVNode("",!0)])}}}),_4=Zl._export_sfc(w4,[["__scopeId","data-v-1ea318b4"]]),S4={class:"type-select"},E4=["onClick"],C4={class:"list-icon"},D4={__name:"modelSelect",setup(a){const l=Hn(A.pinia),{itemData:r}=A.storeToRefs(l),n=t=>{const s=A.cloneDeep(r.value);s.push({comp:t.comp,name:t.name,compData:[]}),l.setItemData(s)};return(t,s)=>{const v=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",S4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(nu),(d,p)=>(e.openBlock(),e.createElementBlock("div",{class:"type-list",key:p},[e.createElementVNode("div",{class:"list-content",onClick:y=>n(d)},[e.createElementVNode("div",C4,[e.createVNode(v,{name:d.icon},null,8,["name"])]),e.createElementVNode("div",null,e.toDisplayString(d.name),1)],8,E4)]))),128))])}}},B4=Zl._export_sfc(D4,[["__scopeId","data-v-91799bf8"]]),N4={class:"fill-content"},T4={class:"operate-content"},A4={class:"collapse-title-content"},z4={class:"collapse-title-item"},M4={key:1},I4=["onClick"],O4={class:"icon-content"},L4={key:0,class:"edit-content"},R4=["onClick"],$4={class:"comp-child"},V4={__name:"modelFill",setup(a){const l=Hn(A.pinia),{itemData:r,originalData:n}=A.storeToRefs(l),t=e.ref([]);e.ref([]);const s=e.ref([]),v=e.ref([]),d=M=>{var K;let S=(K=A.cloneDeep(v.value))==null?void 0:K.map((I,R)=>(M===R&&(I.content=!0),I));v.value=S},p=M=>{var K;let S=(K=A.cloneDeep(v.value))==null?void 0:K.map((I,R)=>(M===R&&(I.content=!1),I));v.value=S,t.value=A.cloneDeep(r.value)},y=(M,S)=>{var j;let K=(j=A.cloneDeep(v.value))==null?void 0:j.map((E,x)=>(M===x&&(E.content=!1),E));v.value=K;const I=A.cloneDeep(r.value),R=I==null?void 0:I.filter((E,x)=>(x===M&&(E.name=S),E));l.setOriginalData(R),l.setItemData(R)};e.watch(()=>r.value,()=>{var M,S,K;!r.value||((M=r.value)==null?void 0:M.length)===0?t.value=[]:t.value=(S=A.cloneDeep(r.value))==null?void 0:S.filter(I=>(I==null?void 0:I.comp)!=="methodButton"),s.value=t.value,v.value=(K=A.cloneDeep(s.value))==null?void 0:K.map((I,R)=>({id:R,content:!1}))},{deep:!0,immediate:!0});const g=M=>Bi(M),c=(M,S,K)=>{var R,j;if(!M)return;let I=A.cloneDeep(r.value);I=(R=I==null?void 0:I.map((E,x)=>(x===K&&(E.compData=M),E)))==null?void 0:R.filter(E=>(E==null?void 0:E.comp)!=="methodButton"),v.value=(j=A.cloneDeep(I))==null?void 0:j.map((E,x)=>({id:x,content:!1})),l.setOriginalData(I),l.setItemData(I)},D=M=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const S=A.cloneDeep(r.value),K=S==null?void 0:S.filter((I,R)=>R!==M);l.setOriginalData(K),l.setItemData(K),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(M,S)=>{const K=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",N4,[S[1]||(S[1]=e.createElementVNode("div",{class:"fill-operate"},e.toDisplayString("操作栏"),-1)),e.createElementVNode("div",T4,[e.createVNode(Js.default,{class:"collapse-content",collapseContents:t.value},{title:e.withCtx(({item:I,index:R})=>{var j,E,x,k,b,w,$,F,J,se;return[e.createElementVNode("div",A4,[e.createElementVNode("div",z4,[(E=(j=v.value)==null?void 0:j.find(ge=>ge.id===R))!=null&&E.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"collapse-title",style:e.normalizeStyle({marginRight:I.name&&I.name!==""?"8px":"0px"})},e.toDisplayString(I.name),5)),(k=(x=v.value)==null?void 0:x.find(ge=>ge.id===R))!=null&&k.content?(e.openBlock(),e.createElementBlock("div",M4,[e.createVNode(ll.ssInput,{modelValue:I.name,"onUpdate:modelValue":ge=>I.name=ge,onClick:S[0]||(S[0]=e.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):e.createCommentVNode("",!0),(w=(b=v.value)==null?void 0:b.find(ge=>ge.id===R))!=null&&w.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:2,onClick:e.withModifiers(ge=>d(R),["stop"]),class:"icon-content"},[e.createVNode(K,{name:"Edit",style:{width:"16px",height:"16px"}})],8,I4))]),e.createElementVNode("div",O4,[(F=($=v.value)==null?void 0:$.find(ge=>ge.id===R))!=null&&F.content?(e.openBlock(),e.createElementBlock("div",L4,[e.createVNode(K,{name:"Cancel",style:{width:"16px",height:"16px"},class:"icon-content",onClick:e.withModifiers(ge=>p(R),["stop"])},null,8,["onClick"]),e.createVNode(K,{name:"Save",onClick:e.withModifiers(ge=>y(R,I.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):e.createCommentVNode("",!0),(se=(J=v.value)==null?void 0:J.find(ge=>ge.id===R))!=null&&se.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,onClick:e.withModifiers(ge=>D(R),["stop"]),class:"icon-content"},[e.createVNode(K,{name:"Delete",style:{width:"16px",height:"16px"}})],8,R4))])])]}),content:e.withCtx(({item:I,index:R})=>{var j,E;return[e.createElementVNode("div",$4,[e.createTextVNode(e.toDisplayString(g(I.comp+"Operate"))+" ",1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g(I.comp+"Operate")),{itemContents:I==null?void 0:I.compData,originalItemContents:(E=(j=s.value)==null?void 0:j.find((x,k)=>k===R))==null?void 0:E.compData,onChange:x=>c(x,I,R)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},F4=Zl._export_sfc(V4,[["__scopeId","data-v-a46a44b9"]]),P4={key:0,class:"show-content"},j4={style:{display:"flex"}},H4={__name:"modelShow",setup(a){const l=Hn(A.pinia),{itemData:r}=A.storeToRefs(l),n=e.ref([]);e.watch(()=>r.value,()=>{var s;!r.value||((s=r.value)==null?void 0:s.length)===0?n.value=[]:n.value=A.cloneDeep(r.value)},{deep:!0,immediate:!0});const t=s=>Bi(s);return(s,v)=>{var d;return((d=n.value)==null?void 0:d.length)>0?(e.openBlock(),e.createElementBlock("div",P4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.value,(p,y)=>(e.openBlock(),e.createElementBlock("div",{class:"item-content",key:y},[e.createElementVNode("div",j4,e.toDisplayString(p.name),1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t(p.comp)),{itemData:p==null?void 0:p.compData,childItemData:p==null?void 0:p.itemChildData,key:y},null,8,["itemData","childItemData"]))]))),128))])):e.createCommentVNode("",!0)}}},U4=Zl._export_sfc(H4,[["__scopeId","data-v-3f3e863e"]]),q4={class:"tabs-header"},W4={class:"tabs-list"},K4={class:"tab-name"},G4={class:"tab-actions"},Y4=["onClick"],J4=["onClick"],X4=["onClick"],Z4={class:"model-operate"},Q4={class:"model-select",style:{display:"unset"}},e6={class:"existing-components"},a6={class:"component-list"},l6=["onClick"],r6={class:"component-info"},n6={class:"component-type"},i6={class:"component-name"},o6={class:"model-fill"},t6={__name:"operate",props:{itemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,t=e.ref([]),s=e.ref(!1),v=e.ref(""),d=e.ref({title:""}),p=e.ref(-1),y=e.ref(!1),g=e.ref(-1),c=e.ref(new WeakMap),D=e.ref(null),M=Hn(A.pinia),{itemData:S}=A.storeToRefs(M),K=()=>{v.value="新增标签页",d.value.title="",p.value=-1,s.value=!0},I=ye=>{v.value="修改标签页",d.value.title=t.value[ye].title,p.value=ye,s.value=!0},R=ye=>{const T=x(ye);c.value.delete(T),t.value.splice(ye,1),Fe()},j=()=>{if(d.value.title.trim()){if(p.value===-1){const ye={title:d.value.title,value:d.value.title,label:d.value.title,children:[],id:E()};t.value.push(ye)}else t.value[p.value].title=d.value.title,t.value[p.value].value=d.value.title,t.value[p.value].label=d.value.title;s.value=!1,Fe()}},E=()=>`tab_${Date.now()}_${Math.random().toString(36).substr(2,9)}`,x=ye=>{const T=t.value[ye];return T.id||(T.id=E()),T.id},k=ye=>{var U;g.value=ye;const T=x(ye);D.value=A.cloneDeep(S.value);let ue=c.value.get(T);!ue&&((U=t.value[ye].children)==null?void 0:U.length)>0&&(ue=F(t.value[ye].children)),ue?M.setItemData(A.cloneDeep(ue)):M.setItemData([]),y.value=!0},b=e.computed(()=>{const ye=A.useModelComp(A.pinia),T=A.storeToRefs(ye).itemData.value;return console.log("可用组件数据",T),!T||!Array.isArray(T)?[]:T.filter(ue=>{var U;if(ue.comp==="Tabs"&&g.value>=0){const Se=x(g.value);if((U=ue.compData)==null?void 0:U.some(Pe=>{var la;return Pe.key==="stepList"&&((la=Pe.contents)==null?void 0:la.some(Da=>Da.id===Se))}))return!1}return!0})}),w=ye=>({Table:"表格",Form:"表单",Tabs:"标签页",Chart:"图表",Card:"卡片"})[ye]||ye,$=ye=>{var T;try{const ue=A.cloneDeep(ye);ue.id=Date.now()+Math.random(),ue.comp==="Tabs"&&((T=ue.compData)==null||T.forEach(Se=>{Se.key==="stepList"&&Se.contents&&Se.contents.forEach(Le=>{Le.id=E()})}));const U=A.cloneDeep(S.value);U.push(ue),M.setItemData(U)}catch(ue){console.error("添加组件失败:",ue)}},F=ye=>ye.map(T=>{var ue;switch(T.type){case"form":return{comp:"Form",name:T.value||"表单",compData:J(T.content)};case"table":return{comp:"Table",name:T.value||"表格",compData:se(T.content)};default:return{comp:"Unknown",name:T.value||"",compData:((ue=T.content)==null?void 0:ue.originalData)||[]}}}),J=ye=>{if(!ye)return[];const T=[];return ye.rowContents&&T.push({key:"formContent",contents:ye.rowContents}),ye.buttonValue&&T.push({key:"formButton",contents:ye.buttonValue}),typeof ye.isEnableWrap<"u"&&T.push({key:"enableWrap",contents:ye.isEnableWrap}),T},se=ye=>[],ge=()=>{if(g.value>=0&&g.value<t.value.length){const ye=x(g.value);c.value.set(ye,A.cloneDeep(S.value)),t.value[g.value].children=fe(S.value),console.log("保存后的数据",fe(S.value))}y.value=!1,g.value=-1,D.value=null,Fe()},Me=()=>{D.value&&M.setItemData(A.cloneDeep(D.value)),y.value=!1,g.value=-1,D.value=null},V=()=>{y.value&&Me()},fe=ye=>{if(!Array.isArray(ye))throw new Error("sourceData must be an array");return ye.map((T,ue)=>{if(!T||typeof T!="object")return T;const{comp:U,name:Se,compData:Le}=T;switch(U){case"Form":return{type:"form",content:ae(Le||[]),value:"表单"};case"Table":return{type:"table",content:de(Le||[]),value:"表格"};default:return{type:"xxx",content:De(Le||[]),value:""}}})},ae=ye=>{const T={formRules:{},rowContents:[],buttonValue:[],rowValues:[],isEnableWrap:!0,isRowFlex:!0,isButtonRow:!0,isEdit:!0,isStartJustify:!0},ue={formContent:"rowContents",enableWrap:"isEnableWrap",formButton:"buttonValue"};return ye.forEach((U,Se)=>{if(!U||typeof U!="object"){console.warn(`Invalid config at index ${Se}:`,U);return}const{key:Le,contents:Pe}=U,la=ue[Le];if(!la){console.warn(`Unknown Form config key: ${Le}`);return}Le==="enableWrap"?T[la]=!!Pe:T[la]=Array.isArray(Pe)?Pe:[]}),T},de=ye=>{const T={columns:[],tableData:[],extraButton:[],rowButton:[],currentPage:0,total:0,pageSize:0,isShowPagination:!0,isShowEdit:!0,isMoveColumn:!0,isShowDelete:!0},ue={header:"columns",tableContents:"tableData"};return ye.forEach((U,Se)=>{if(!U||typeof U!="object"){console.warn(`Invalid config at index ${Se}:`,U);return}const{key:Le,contents:Pe}=U,la=ue[Le];if(!la){console.warn(`Unknown Table config key: ${Le}`);return}T[la]=Array.isArray(Pe)?Pe:[]}),T},De=ye=>(console.log("Default conversion logic - to be implemented"),{originalData:ye,processed:!1,componentType:"unknown"}),Fe=()=>{const ye=[{key:"stepList",contents:t.value}];n("change",ye)};return e.watch(()=>r.itemContents,ye=>{if(ye&&ye.length>0){const T=ye.find(ue=>ue.key==="stepList");T&&T.contents&&(t.value=T.contents.map(ue=>({title:ue.title||"",value:ue.value||ue.title||"",label:ue.label||ue.title||"",children:ue.children||[],id:ue.id||E()})))}},{immediate:!0,deep:!0}),(ye,T)=>{const ue=e.resolveComponent("svg-icon"),U=e.resolveComponent("el-input"),Se=e.resolveComponent("el-form-item"),Le=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",q4,[T[6]||(T[6]=e.createElementVNode("h4",null,"标签页管理",-1)),e.createElementVNode("button",{onClick:K},[e.createVNode(ue,{name:"Plus",style:{width:"14px",height:"14px","margin-right":"4px"}}),T[5]||(T[5]=e.createTextVNode(" 新增标签页 "))])]),e.createElementVNode("div",W4,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,(Pe,la)=>(e.openBlock(),e.createElementBlock("div",{class:"tab-item",key:la},[e.createElementVNode("span",K4,e.toDisplayString(Pe.title),1),e.createElementVNode("div",G4,[e.createElementVNode("button",{onClick:Da=>I(la)},"修改标题",8,Y4),e.createElementVNode("button",{onClick:Da=>k(la)},"布局调整",8,J4),e.createElementVNode("button",{onClick:Da=>R(la)},"删除",8,X4)])]))),128))]),e.createVNode(wr.ssDialog,{modelValue:s.value,"onUpdate:modelValue":T[2]||(T[2]=Pe=>s.value=Pe),title:v.value,onBeforeDestroy:T[3]||(T[3]=Pe=>s.value=!1)},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:T[1]||(T[1]=Pe=>s.value=!1)},"取消"),e.createElementVNode("button",{type:"primary",onClick:j},"确定")]),default:e.withCtx(()=>[e.createVNode(Le,{model:d.value,"label-width":"80px"},{default:e.withCtx(()=>[e.createVNode(Se,{label:"标签名称",required:""},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:d.value.title,"onUpdate:modelValue":T[0]||(T[0]=Pe=>d.value.title=Pe),placeholder:"请输入标签页名称"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue","title"]),e.createVNode(wr.ssDialog,{modelValue:y.value,"onUpdate:modelValue":T[4]||(T[4]=Pe=>y.value=Pe),title:"布局调整",fullScreen:"",onBeforeDestroy:V},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:Me},"取消"),e.createElementVNode("button",{onClick:ge},"确定")]),default:e.withCtx(()=>[e.createElementVNode("div",Z4,[e.createElementVNode("div",Q4,[e.createVNode(B4),e.createElementVNode("div",e6,[T[8]||(T[8]=e.createElementVNode("h5",null,"添加已有组件",-1)),e.createElementVNode("div",a6,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,Pe=>(e.openBlock(),e.createElementBlock("div",{key:Pe.id,class:"component-item",onClick:la=>$(Pe)},[e.createElementVNode("div",r6,[e.createElementVNode("span",n6,e.toDisplayString(w(Pe.comp)),1),e.createElementVNode("span",i6,e.toDisplayString(Pe.name),1)]),T[7]||(T[7]=e.createElementVNode("button",{class:"add-btn"},"添加",-1))],8,l6))),128))])])]),(e.openBlock(),e.createElementBlock("div",{class:"model-show",key:ye.innerWidth},[e.createVNode(U4)])),e.createElementVNode("div",o6,[e.createVNode(F4)])])]),_:1},8,["modelValue"])])}}},s6=Zl._export_sfc(t6,[["__scopeId","data-v-9096ed0d"]]);function c6(){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 u6(a){return{type:"line",...a}}function d6(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",data:["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]},yAxis:[{type:"value"}],series:[]}}function p6(a){return{type:"bar",barWidth:"60%",...a}}function f6(){return{title:{text:"",left:"center"},tooltip:{trigger:"item"},series:[]}}function h6(a){return{type:"pie",radius:"50%",emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},...a}}const On={line:{initBaseoptions:c6,initSeries:u6},bar:{initBaseoptions:d6,initSeries:p6},pie:{initBaseoptions:f6,initSeries:h6}},ws=A.useMenuState(A.pinia),Rc=(a,l)=>{var g;const r=[],n=[],{group:t,nameCol:s,valueCol:v}=l||{},d=a==null?void 0:a.find(c=>{const{name:D}=c;return D===t});if(!d)return{names:r,values:n};const p=(g=d==null?void 0:d.compData)==null?void 0:g.find(c=>{const{key:D}=c;return D==="tableContents"});return((p==null?void 0:p.contents)||[]).forEach(c=>{const D=c==null?void 0:c[0];let M=!1;qa.isObject(D)&&(D!=null&&D.id)&&(M=!0);let S=s,K=v;M&&(S=S+1,K=K+1);const I=c==null?void 0:c[S],R=c==null?void 0:c[K];r.push(I),n.push(R)}),{names:r,values:n}},v6=async a=>{const{menu:l,mainKey:r,detailGroup:n,detailNameCol:t,detailValueCol:s,isSelfDetail:v}=a||{};let d=null;const p=sessionStorage.getItem("systemKey");if(v&&ws.activeMenuPath&&(d=await he.getItemData(`${ws.activeMenuPath}`,p,"")),!v){const y=l==null?void 0:l.join("/");d=await he.getItemData(`${y}^${r}`,p,"")}return Rc(d,{group:n,nameCol:t,valueCol:s})},m6=async a=>{const{menu:l,group:r,nameCol:n,valueCol:t}=a||{},s=l==null?void 0:l.join("/"),v=sessionStorage.getItem("systemKey"),d=await he.getItemData(s,v,"");return Rc(d,{group:r,nameCol:n,valueCol:t})},Bt=async(a,l)=>{const r={names:[],values:[]},{menu:n,group:t,nameCol:s,valueCol:v}=a||{};if(!n.length||!t)return r;const{mainKey:d,group:p,nameCol:y,valueCol:g,isSelfDetail:c}=l||{};return d&&p&&ll.isNumber(y)&&ll.isNumber(g)?await v6({menu:n,mainKey:d,detailGroup:p,detailNameCol:y,detailValueCol:g,isSelfDetail:c}):ll.isNumber(s)&&ll.isNumber(v)?await m6({menu:n,group:t,nameCol:s,valueCol:v}):r},y6=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:t}=a||{},s=On==null?void 0:On[n];if(!s)return;const{initBaseoptions:v,initSeries:d}=s,p=v();p.title.text=t??"";const{names:y,values:g}=await Bt(l,r);if(!y||!g)return p;p.xAxis.data=y;const c=d({data:g});return p.series.push(c),p},g6=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:t}=a||{},s=On==null?void 0:On[n];if(!s)return;const{initBaseoptions:v,initSeries:d}=s,p=v();p.title.text=t??"";const{names:y,values:g}=await Bt(l,r);if(!y||!g)return p;p.xAxis.data=y;const c=d({data:g});return p.series.push(c),p},b6=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:r})=>{const{type:n,title:t}=a||{},s=On==null?void 0:On[n];if(!s)return;const{initBaseoptions:v,initSeries:d}=s,p=v();p.title.text=t??"";const{names:y,values:g}=await Bt(l,r);if(!y||!g)return p;const c=[];for(let M=0;M<y.length;M++){const S=y[M],K=g[M];c.push({name:S,value:K})}const D=d({data:c});return p.series.push(D),p},k6=async(a=[])=>{var v,d,p;const l=((v=a==null?void 0:a.find(y=>y.key==="chartBaseConfig"))==null?void 0:v.contents)??{},r=((d=a==null?void 0:a.find(y=>y.key==="chartDataConfig"))==null?void 0:d.contents)??{},n=((p=a==null?void 0:a.find(y=>y.key==="chartDetailConfig"))==null?void 0:p.contents)??{},{type:t}=l;let s={};return t==="line"&&(s=await y6({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),t==="bar"&&(s=await g6({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),t==="pie"&&(s=await b6({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})),s},x6=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 t=l==null?void 0:l.itemData;r.value=await k6(t)});const n=e.computed(()=>(l==null?void 0:l.height)||"300px");return(t,s)=>(e.openBlock(),e.createElementBlock("div",{class:"eCharts",style:e.normalizeStyle({height:n.value})},[e.createVNode(Mu.ssChart,{optionContents:r.value},null,8,["optionContents"])],4))}}),w6=Zl._export_sfc(x6,[["__scopeId","data-v-d4c081e8"]]),_6={class:"chart-module layout"},S6={class:"chart-module content"},E6={class:"chart-module content"},C6={class:"form-content"},D6={class:"dialog-footer"},B6={class:"form-content"},N6={class:"dialog-footer"},T6={class:"form-content"},A6={class:"dialog-footer"},z6=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const r=a,n=l,t=e.reactive({visible:!1,width:"840",title:"基础配置"}),s=e.ref([]),v=()=>[{label:"类型",prop:"type",type:"select",contents:[{label:"柱状图",value:"bar"},{label:"饼图",value:"pie"},{label:"折线图",value:"line"}],value:""},{label:"标题",prop:"title",type:"input",value:""}],d=e.ref({}),p=()=>{var Ee;s.value=v(),(Ee=s.value)==null||Ee.forEach(oe=>{var Ue;const Te=oe==null?void 0:oe.prop;oe.value=(Ue=d==null?void 0:d.value)==null?void 0:Ue[Te]}),t.visible=!0},y=Ee=>{d.value=Ee},g=()=>{var Ee;t.visible=!1,n("change",(Ee=te())==null?void 0:Ee.compData)},c=e.reactive({visible:!1,width:"840",title:"数据配置"}),D=e.ref([]),M=()=>[{label:"菜单选项",prop:"menu",type:"cascader",contents:[]},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],S=e.ref({}),K=()=>{const Ee=D.value,oe=A.cloneDeep(Ee);return oe==null||oe.forEach(Te=>{var oa;const Ue=Te==null?void 0:Te.prop;Te.value=(oa=S.value)==null?void 0:oa[Ue]}),oe},I=Ee=>{var Te;S.value=Ee;const oe=K();D.value=oe,n("change",(Te=te())==null?void 0:Te.compData)},R=async()=>{const Ee=await he.getMenusContent(),oe=K();oe==null||oe.forEach(Te=>{(Te==null?void 0:Te.prop)==="menu"&&(Te.contents=Ee)}),D.value=oe,c.visible=!0,await Pe(S.value.menu),await le(S.value.group)},j=e.reactive({visible:!1,width:"840",title:"详情页配置"}),E=e.ref([]),x=()=>[{label:"详情页主键",prop:"mainKey",type:"select",contents:[]},{label:"使用当前详情页内容",prop:"isSelfDetail",type:"switch"},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],k=e.ref({}),b=()=>{const Ee=E.value,oe=A.cloneDeep(Ee);return oe==null||oe.forEach(Te=>{var oa;const Ue=Te==null?void 0:Te.prop;Te.value=(oa=k.value)==null?void 0:oa[Ue]}),oe},w=Ee=>{var Te;k.value=Ee;const oe=b();E.value=oe,n("change",(Te=te())==null?void 0:Te.compData)},$=async()=>{await V();const Ee=A.cloneDeep(F.value),oe=b();oe==null||oe.forEach(Te=>{var oa;const Ue=Te==null?void 0:Te.prop;Te.value=(oa=k==null?void 0:k.value)==null?void 0:oa[Ue],Ue==="mainKey"&&(Te.contents=Ee)}),E.value=oe,j.visible=!0},F=e.ref([]),J=e.ref([]),se=e.ref({}),ge=e.ref({}),Me=()=>{const{compData:Ee}=U.value||{},oe=Ee==null?void 0:Ee.find(Q=>{const{key:me}=Q;return me==="header"}),Te=(oe==null?void 0:oe.contents)||[],Ue=Te==null?void 0:Te.filter((Q,me)=>{const{label:ve}=Q;return ve!=="操作"}),oa=Ue==null?void 0:Ue.findIndex((Q,me)=>{const{isMainKey:ve}=Q;return ve});if(oa<0)return[];const Ja=Ee==null?void 0:Ee.find(Q=>{const{key:me}=Q;return me==="tableContents"}),L=(Ja==null?void 0:Ja.contents)||[];return L==null?void 0:L.map(Q=>{const me=Q==null?void 0:Q[0];let ve=oa;qa.isObject(me)&&(me!=null&&me.id)&&(ve=ve+1);const da=Q==null?void 0:Q[ve];return{label:da,value:da}})},V=async()=>{const Ee=await Me();F.value=Ee},fe=async Ee=>{const oe=sessionStorage.getItem("systemKey");return await he.getItemData(Ee,oe,"")},ae=async Ee=>{const oe=Ee;J.value=oe==null?void 0:oe.map(Te=>{const{name:Ue}=Te;return se.value[Ue]=Te,{label:Ue,value:Ue}})},de=Ee=>{const{comp:oe,compData:Te}=ge.value||{};if(oe==="Table"){let Ue=b();Ue=Ue.filter(oa=>{const{prop:Ja}=oa;return Ja!=="formItems"}),la(Ue,Te),E.value=Ue}},De=async()=>{var Te,Ue;const Ee=(Te=k==null?void 0:k.value)==null?void 0:Te.mainKey,oe=(Ue=S==null?void 0:S.value)==null?void 0:Ue.menu;if(Ee){const Ja=`${oe==null?void 0:oe.join("/")}^${Ee}`,L=await fe(Ja);await ae(L);const H=b();H==null||H.forEach(Q=>{(Q==null?void 0:Q.prop)==="group"&&(Q.contents=J.value)}),E.value=H}};e.watch(()=>{var Ee;return(Ee=k==null?void 0:k.value)==null?void 0:Ee.mainKey},async(Ee,oe)=>{Ee!=oe&&Ee&&await De()});const Fe=async Ee=>{const oe=se.value[Ee];ge.value=oe,await de()};e.watch(()=>{var Ee;return(Ee=k==null?void 0:k.value)==null?void 0:Ee.group},async(Ee,oe)=>{Ee!=oe&&Ee&&Fe(Ee)});const ye=async()=>{var oe;await De();const Ee=(oe=k.value)==null?void 0:oe.group;await Fe(Ee)},T=e.ref([]),ue=e.ref({}),U=e.ref({}),Se=async Ee=>{const oe=Ee==null?void 0:Ee.join("/"),Te=sessionStorage.getItem("systemKey");return await he.getItemData(oe,Te,"")},Le=async Ee=>{const oe=await Se(Ee);T.value=oe==null?void 0:oe.map(Te=>{const{name:Ue}=Te;return ue.value[Ue]=Te,{label:Ue,value:Ue}})},Pe=async(Ee,oe)=>{await Le(Ee);const Te=K();Te==null||Te.forEach(Ue=>{(Ue==null?void 0:Ue.prop)==="group"&&(Ue.contents=T.value)}),D.value=Te};e.watch(()=>{var Ee;return(Ee=S==null?void 0:S.value)==null?void 0:Ee.menu},async(Ee,oe)=>{const Te=Ee==null?void 0:Ee.join("/"),Ue=oe==null?void 0:oe.join("/");Te!=Ue&&await Pe(Ee)});const la=(Ee,oe)=>{const Te=oe==null?void 0:oe.find(L=>{const{key:H}=L;return H==="header"}),Ue=(Te==null?void 0:Te.contents)||[],oa=Ue==null?void 0:Ue.filter((L,H)=>{const{label:Q}=L;return Q!=="操作"}),Ja=oa==null?void 0:oa.map((L,H)=>{const{label:Q}=L;return{label:Q,value:H}});Ee==null||Ee.forEach(L=>{const H=L==null?void 0:L.prop;(H==="nameCol"||H==="valueCol")&&(L.contents=Ja)})},Da=Ee=>{const{comp:oe,compData:Te}=U.value||{};if(oe==="Table"){S.value.formItems=[];let Ue=K();Ue=Ue.filter(oa=>{const{prop:Ja}=oa;return Ja!=="formItems"}),la(Ue,Te),D.value=Ue}},le=async Ee=>{const oe=ue.value[Ee];U.value=oe,await Da()};e.watch(()=>{var Ee;return(Ee=S==null?void 0:S.value)==null?void 0:Ee.group},async(Ee,oe)=>{Ee!=oe&&le(Ee)});const ta=async()=>{var Te,Ue;const Ee=(Te=S.value)==null?void 0:Te.menu;await Pe(Ee);const oe=(Ue=S.value)==null?void 0:Ue.group;await le(oe)},te=()=>({comp:"chart",compData:[{key:"chartBaseConfig",contents:d.value},{key:"chartDataConfig",contents:S.value},{key:"chartDetailConfig",contents:k.value}]}),ca=()=>{t.visible=!1,c.visible=!1,j.visible=!1};return e.onMounted(async()=>{var oe,Te,Ue;D.value=M(),E.value=x();const Ee=r==null?void 0:r.itemContents;d.value=((oe=Ee==null?void 0:Ee.find(oa=>oa.key==="chartBaseConfig"))==null?void 0:oe.contents)??{},S.value=((Te=Ee==null?void 0:Ee.find(oa=>oa.key==="chartDataConfig"))==null?void 0:Te.contents)??{},await ta(),k.value=((Ue=Ee==null?void 0:Ee.find(oa=>oa.key==="chartDetailConfig"))==null?void 0:Ue.contents)??{},await ye()}),(Ee,oe)=>{const Te=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",_6,[oe[4]||(oe[4]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createVNode(Te,{id:"themeButton",onClick:oe[0]||(oe[0]=Ue=>p())},{default:e.withCtx(()=>oe[3]||(oe[3]=[e.createTextVNode(" 修改 ")])),_:1,__:[3]})]),e.createElementVNode("div",S6,[oe[6]||(oe[6]=e.createElementVNode("h4",{class:"module-title"},"数据配置",-1)),e.createVNode(Te,{id:"themeButton",onClick:oe[1]||(oe[1]=Ue=>R())},{default:e.withCtx(()=>oe[5]||(oe[5]=[e.createTextVNode(" 修改 ")])),_:1,__:[5]})]),e.createElementVNode("div",E6,[oe[8]||(oe[8]=e.createElementVNode("h4",{class:"module-title"},"详情数据配置",-1)),e.createVNode(Te,{id:"themeButton",onClick:oe[2]||(oe[2]=Ue=>$())},{default:e.withCtx(()=>oe[7]||(oe[7]=[e.createTextVNode(" 修改 ")])),_:1,__:[7]})])]),e.createVNode(wr.ssDialog,{visible:t.visible,title:t.title,onBeforeDestroy:ca,width:t.width},{default:e.withCtx(()=>[e.createElementVNode("div",C6,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:s.value,key:s.value,isEnableWrap:!0,onChange:y},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",D6,[e.createVNode(Te,{class:"cancel-button button",onClick:ca,id:"themeBorderButton"},{default:e.withCtx(()=>oe[9]||(oe[9]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[9]}),e.createVNode(Te,{class:"ok-button button",onClick:g,id:"themeButton"},{default:e.withCtx(()=>oe[10]||(oe[10]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[10]})])]),_:1},8,["visible","title","width"]),e.createVNode(wr.ssDialog,{visible:c.visible,title:c.title,onBeforeDestroy:ca,width:c.width},{default:e.withCtx(()=>[e.createElementVNode("div",B6,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:D.value,key:D.value,isEnableWrap:!0,onChange:I},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",N6,[e.createVNode(Te,{class:"cancel-button button",onClick:ca,id:"themeBorderButton"},{default:e.withCtx(()=>oe[11]||(oe[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(Te,{class:"ok-button button",onClick:ca,id:"themeButton"},{default:e.withCtx(()=>oe[12]||(oe[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible","title","width"]),e.createVNode(wr.ssDialog,{visible:j.visible,title:j.title,onBeforeDestroy:ca,width:j.width},{default:e.withCtx(()=>[e.createElementVNode("div",T6,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:w},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",A6,[e.createVNode(Te,{class:"cancel-button button",onClick:ca,id:"themeBorderButton"},{default:e.withCtx(()=>oe[13]||(oe[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(Te,{class:"ok-button button",onClick:ca,id:"themeButton"},{default:e.withCtx(()=>oe[14]||(oe[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible","title","width"])],64)}}}),M6=Zl._export_sfc(z6,[["__scopeId","data-v-fe119645"]]),I6={class:"layout"},O6=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 t=e.computed(()=>A.cloneDeep(n==null?void 0:n.itemData)||[]),s=e.computed(()=>{var g;const y=(g=t==null?void 0:t.value)==null?void 0:g.find(c=>{const{key:D}=c;return D==="baseConfig"});return y==null?void 0:y.contents}),v=e.computed(()=>{var g;const y=(g=t==null?void 0:t.value)==null?void 0:g.find(c=>{const{key:D}=c;return D==="children"});return y==null?void 0:y.contents}),d=e.computed(()=>{let y=A.cloneDeep(v.value)||[];const g=y.length;let c=0;const D=[];if(y=y.map(M=>{const S=M.span;return S?(M.span=Number(S),c=c+M.span):D.push(M),M}),c<24){const M=Math.floor((24-c)/g);D.forEach(S=>{S.span=M})}return y}),p=y=>{r("rowClick",y)};return(y,g)=>{var M;const c=e.resolveComponent("el-col"),D=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",I6,[e.createVNode(D,{style:e.normalizeStyle({height:(M=s.value)==null?void 0:M.height})},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(S,K)=>(e.openBlock(),e.createBlock(c,{span:S==null?void 0:S.span},{default:e.withCtx(()=>{var I;return[e.unref(Di)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Gi)(S.comp)),{key:e.unref(jn),compName:S.name,index:(S==null?void 0:S.id)??K,height:(I=s.value)==null?void 0:I.height,itemData:S==null?void 0:S.compData,childItemData:S==null?void 0:S.itemChildData,onChange:e.unref(No),onContentChange:e.unref(To),onPageChange:e.unref(Ao),onRowClick:p},null,40,["compName","index","height","itemData","childItemData","onChange","onContentChange","onPageChange"])):e.createCommentVNode("",!0)]}),_:2},1032,["span"]))),256))]),_:1},8,["style"])])}}}),L6=Zl._export_sfc(O6,[["__scopeId","data-v-ab9a36ed"]]),R6={class:"layout-operate"},$6={class:"layout-module"},V6={class:"collapse-title-item"},F6={class:"collapse-title"},P6={class:"icon-content"},j6=["onClick"],H6={class:"comp-child"},U6=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(()=>{K()});const t=e.ref({}),s=e.ref({}),v=e.ref([]),d=k=>[{label:"高度",prop:"height",type:"input",value:k==null?void 0:k.height}],p=k=>{s.value=k,n("change",x(),!0)},y=e.ref([]),g=e.ref([]),c=k=>[{label:"占比",prop:"span",type:"input",value:k==null?void 0:k.span}],D=e.computed(()=>{const k=r==null?void 0:r.itemContents;return A.cloneDeep(k)}),M=e.computed(()=>{const k=D==null?void 0:D.value,b=k==null?void 0:k.find(w=>{const{key:$}=w;return $==="baseConfig"});return b==null?void 0:b.contents}),S=e.computed(()=>{const k=D==null?void 0:D.value,b=k==null?void 0:k.find(w=>{const{key:$}=w;return $==="children"});return b==null?void 0:b.contents}),K=()=>{var k;t.value=D.value||{},y.value=(S==null?void 0:S.value)||[],v.value=d(),v.value=(k=v.value)==null?void 0:k.map(b=>{var $;const{prop:w}=b;return b.value=($=M.value)==null?void 0:$[w],b})};e.watch(()=>{var k;return(k=S==null?void 0:S.value)==null?void 0:k.length},()=>{var k;y.value=(S==null?void 0:S.value)||[],g.value=(k=S.value)==null?void 0:k.map(b=>c(b))},{immediate:!0});const I=(k,b)=>{const w=A.cloneDeep(S==null?void 0:S.value);w[b].span=k.span,y.value=w,n("change",x(),!0)},R=k=>Bi(k),j=(k,b,w)=>{if(!k)return;const $=A.cloneDeep(S==null?void 0:S.value);$[w]&&($[w].compData=k,y.value=$,n("change",x(),!0))},E=k=>{A.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{let b=A.cloneDeep(S==null?void 0:S.value);b=b==null?void 0:b.filter((w,$)=>k!==$),y.value=b,n("change",x(),!0),qa.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},x=()=>({compData:[{key:"baseConfig",contents:s.value},{key:"children",contents:y==null?void 0:y.value}]});return(k,b)=>{const w=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",R6,[e.createElementVNode("div",$6,[b[1]||(b[1]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createElementVNode("div",null,[e.createVNode(ll.ssForm,{rowContents:v.value,isEnableWrap:!0,onChange:b[0]||(b[0]=$=>p($))},null,8,["rowContents"])])]),e.createVNode(Js.default,{class:"collapse-content",collapseContents:S.value},{title:e.withCtx(({item:$,index:F})=>[e.createElementVNode("div",V6,[e.createElementVNode("div",F6,e.toDisplayString($.name),1),e.createElementVNode("div",P6,[e.createElementVNode("div",{onClick:e.withModifiers(J=>E(F),["stop"]),class:"icon-content"},[e.createVNode(w,{name:"Delete",style:{width:"16px",height:"16px"}})],8,j6)])])]),content:e.withCtx(({item:$,index:F})=>[e.createElementVNode("div",H6,[e.createElementVNode("div",null,[(e.openBlock(),e.createBlock(ll.ssForm,{rowContents:g.value[F],key:F,isEnableWrap:!0,onChange:J=>I(J,F)},null,8,["rowContents","onChange"]))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(R($.comp+"Operate")),{itemContents:$==null?void 0:$.compData,originalItemContents:$.compData,onChange:J=>j(J,$,F)},null,40,["itemContents","originalItemContents","onChange"]))])]),_:1},8,["collapseContents"])])}}}),q6=Zl._export_sfc(U6,[["__scopeId","data-v-ba05456e"]]),W6=typeof window<"u";var _s;W6&&((_s=window==null?void 0:window.navigator)!=null&&_s.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function cn(a){return a==null}function $c(){}const K6=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(K6)));function G6(){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(t=>{t(...r)})}}}function Ss(a,l=16){if(typeof a!="function")return $c;const r=(...s)=>{a(...s)};if(l<=0)return Vc(r);let n=0,t;return function(...s){const v=Date.now(),d=v-n;clearTimeout(t),d>=l?(n=v,r(...s)):t=setTimeout(()=>{n=Date.now(),r(...s)},Math.max(0,l-d))}}function Y6(a,l=100){if(typeof a!="function")return $c;const r=(...t)=>{a(...t)};if(l<=0)return Vc(r);let n;return function(...t){clearTimeout(n),n=setTimeout(()=>{r(...t)},l)}}function Vc(a){if(typeof a!="function")return a;let l=!1,r,n;return function(...t){return r=t,l||(l=!0,n=Promise.resolve().then(()=>(l=!1,n=void 0,a(...r)))),n}}const Ui=new Set,Fc=new WeakMap;function J6(){Ui.forEach(a=>{a(...Fc.get(a))}),Ui.clear()}function Yr(a,...l){if(typeof a!="function")return a;Fc.set(a,l),!Ui.has(a)&&(Ui.add(a),Ui.size===1&&Promise.resolve().then(J6))}const Pc=Symbol("LAYOUT_KEY"),jc=Symbol("EMITTER_KEY");function X6(a){let l=0,r;for(let n=0,t=a.length;n<t;n++)r=a[n].y+a[n].h,r>l&&(l=r);return l}function wt(a){const l=Array(a.length);for(let r=0,n=a.length;r<n;r++)l[r]=Z6(a[r]);return l}function Z6(a){return{...a}}function Hc(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 wi(a,l,r){const n=qc(a),t=Wc(a),s=Array(a.length);for(let v=0,d=t.length;v<d;v++){let p=t[v];p.static||(p=Q6(n,p,l,r),n.push(p)),s[a.findIndex(y=>y.i===p.i)]=p,p.moved=!1}return s}function Q6(a,l,r,n){if(r)for(;l.y>0&&!qi(a,l);)l.y--;else if(n){const s=n[l.i].y;for(;l.y>s&&!qi(a,l);)l.y--}let t;for(;t=qi(a,l);)l.y=t.y+t.h;return l}function e1(a,l){const r=qc(a);for(let n=0,t=a.length;n<t;n++){const s=a[n];if(s.x+s.w>l.cols&&(s.x=l.cols-s.w),s.x<0&&(s.x=0,s.w=l.cols),!s.static)r.push(s);else for(;qi(r,s);)s.y++}return a}function Es(a,l){for(let r=0,n=a.length;r<n;r++)if(a[r].i===l)return a[r]}function qi(a,l){for(let r=0,n=a.length;r<n;r++)if(Hc(a[r],l))return a[r]}function Uc(a,l){return a.filter(r=>Hc(r,l))}function qc(a){return a.filter(l=>l.static)}function _t(a,l,r,n,t=!1,s=!1){if(l.static)return a;const v=l.x,d=l.y,p=n&&l.y>n;typeof r=="number"&&(l.x=r),typeof n=="number"&&(l.y=n),l.moved=!0;let y=Wc(a);p&&(y=y.reverse());const g=Uc(y,l);if(s&&g.length)return l.x=v,l.y=d,l.moved=!1,a;for(let c=0,D=g.length;c<D;c++){const M=g[c];M.moved||l.y>M.y&&l.y-M.y>M.h/4||(M.static?a=Cs(a,M,l,t):a=Cs(a,l,M,t))}return a}function Cs(a,l,r,n){if(n){const t={x:r.x,y:r.y,w:r.w,h:r.h};if(t.y=Math.max(l.y-r.h,0),!qi(a,t))return _t(a,r,void 0,t.y,!1)}return _t(a,r,void 0,r.y+1,!1)}function a1(a,l,r,n){const t="translate3d("+l+"px,"+a+"px, 0)";return{transform:t,WebkitTransform:t,MozTransform:t,msTransform:t,OTransform:t,width:r+"px",height:n+"px",position:"absolute"}}function l1(a,l,r,n){const t="translate3d("+l*-1+"px,"+a+"px, 0)";return{transform:t,WebkitTransform:t,MozTransform:t,msTransform:t,OTransform:t,width:r+"px",height:n+"px",position:"absolute"}}function r1(a,l,r,n){return{top:a+"px",left:l+"px",width:r+"px",height:n+"px",position:"absolute"}}function n1(a,l,r,n){return{top:a+"px",right:l+"px",width:r+"px",height:n+"px",position:"absolute"}}function Wc(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 i1(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 t=0,s=a.length;t<s;t++){const v=a[t];for(let d=0;d<r.length;d++)if(typeof v[r[d]]!="number")throw new Error("VueGridLayout: "+l+"["+t+"]."+r[d]+" must be a number!");if(v.i===void 0||v.i===null)throw new Error("VueGridLayout: "+l+"["+t+"].i cannot be null!");if(typeof v.i!="number"&&typeof v.i!="string")throw new Error("VueGridLayout: "+l+"["+t+"].i must be a string or number!");if(n.indexOf(v.i)>=0)throw new Error("VueGridLayout: "+l+"["+t+"].i must be unique!");if(n.push(v.i),v.static!==void 0&&typeof v.static!="boolean")throw new Error("VueGridLayout: "+l+"["+t+"].static must be a boolean!")}}function o1(a,l="vgl"){const r=()=>`${l}-${a}`;return{b:r,be:n=>`${r()}__${n}`,bm:n=>`${r()}--${n}`,bem:(n,t)=>`${r()}__${n}--${t}`}}function Ds(a){return s1(a)}function s1(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(),t=a.clientX+r.scrollLeft-n.left,s=a.clientY+r.scrollTop-n.top;return{x:t,y:s}}function Bs(a,l,r,n){return c1(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 c1(a){return typeof a=="number"&&!Number.isNaN(a)}function u1(a,l){const r=Gc(a);let n=r[0];for(let t=1,s=r.length;t<s;t++){const v=r[t];l>a[v]&&(n=v)}return n}function Kc(a,l){if(!l[a])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+a+" is missing!");return l[a]}function d1(a,l,r,n,t,s,v){if(l[n])return wt(l[n]);let d=a;const p=Gc(r),y=p.slice(p.indexOf(n));for(let g=0,c=y.length;g<c;g++){const D=y[g];if(l[D]){d=l[D];break}}return d=wt(d||[]),wi(e1(d,{cols:s}),v)}function Gc(a){return Object.keys(a).sort((l,r)=>a[l]-a[r])}let p1="auto";function f1(){return typeof document<"u"}function Ns(){return f1()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir"):p1}var Pi={exports:{}},h1=Pi.exports,Ts;function v1(){return Ts||(Ts=1,function(a,l){(function(r,n){a.exports=n()})(h1,function(){function r(o,i){var f=Object.keys(o);if(Object.getOwnPropertySymbols){var m=Object.getOwnPropertySymbols(o);i&&(m=m.filter(function(_){return Object.getOwnPropertyDescriptor(o,_).enumerable})),f.push.apply(f,m)}return f}function n(o){for(var i=1;i<arguments.length;i++){var f=arguments[i]!=null?arguments[i]:{};i%2?r(Object(f),!0).forEach(function(m){p(o,m,f[m])}):Object.getOwnPropertyDescriptors?Object.defineProperties(o,Object.getOwnPropertyDescriptors(f)):r(Object(f)).forEach(function(m){Object.defineProperty(o,m,Object.getOwnPropertyDescriptor(f,m))})}return o}function t(o){return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(i){return typeof i}:function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},t(o)}function s(o,i){if(!(o instanceof i))throw new TypeError("Cannot call a class as a function")}function v(o,i){for(var f=0;f<i.length;f++){var m=i[f];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(o,K(m.key),m)}}function d(o,i,f){return i&&v(o.prototype,i),Object.defineProperty(o,"prototype",{writable:!1}),o}function p(o,i,f){return(i=K(i))in o?Object.defineProperty(o,i,{value:f,enumerable:!0,configurable:!0,writable:!0}):o[i]=f,o}function y(o,i){if(typeof i!="function"&&i!==null)throw new TypeError("Super expression must either be null or a function");o.prototype=Object.create(i&&i.prototype,{constructor:{value:o,writable:!0,configurable:!0}}),Object.defineProperty(o,"prototype",{writable:!1}),i&&c(o,i)}function g(o){return g=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(i){return i.__proto__||Object.getPrototypeOf(i)},g(o)}function c(o,i){return c=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,m){return f.__proto__=m,f},c(o,i)}function D(o){if(o===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o}function M(o){var i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}();return function(){var f,m=g(o);if(i){var _=g(this).constructor;f=Reflect.construct(m,arguments,_)}else f=m.apply(this,arguments);return function(O,G){if(G&&(typeof G=="object"||typeof G=="function"))return G;if(G!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return D(O)}(this,f)}}function S(){return S=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(o,i,f){var m=function(O,G){for(;!Object.prototype.hasOwnProperty.call(O,G)&&(O=g(O))!==null;);return O}(o,i);if(m){var _=Object.getOwnPropertyDescriptor(m,i);return _.get?_.get.call(arguments.length<3?o:f):_.value}},S.apply(this,arguments)}function K(o){var i=function(f,m){if(typeof f!="object"||f===null)return f;var _=f[Symbol.toPrimitive];if(_!==void 0){var O=_.call(f,m);if(typeof O!="object")return O;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(f)}(o,"string");return typeof i=="symbol"?i:i+""}var I=function(o){return!(!o||!o.Window)&&o instanceof o.Window},R=void 0,j=void 0;function E(o){R=o;var i=o.document.createTextNode("");i.ownerDocument!==o.document&&typeof o.wrap=="function"&&o.wrap(i)===i&&(o=o.wrap(o)),j=o}function x(o){return I(o)?o:(o.ownerDocument||o).defaultView||j.window}typeof window<"u"&&window&&E(window);var k=function(o){return!!o&&t(o)==="object"},b=function(o){return typeof o=="function"},w={window:function(o){return o===j||I(o)},docFrag:function(o){return k(o)&&o.nodeType===11},object:k,func:b,number:function(o){return typeof o=="number"},bool:function(o){return typeof o=="boolean"},string:function(o){return typeof o=="string"},element:function(o){if(!o||t(o)!=="object")return!1;var i=x(o)||j;return/object|function/.test(typeof Element>"u"?"undefined":t(Element))?o instanceof Element||o instanceof i.Element:o.nodeType===1&&typeof o.nodeName=="string"},plainObject:function(o){return k(o)&&!!o.constructor&&/function Object\b/.test(o.constructor.toString())},array:function(o){return k(o)&&o.length!==void 0&&b(o.splice)}};function $(o){var i=o.interaction;if(i.prepared.name==="drag"){var f=i.prepared.axis;f==="x"?(i.coords.cur.page.y=i.coords.start.page.y,i.coords.cur.client.y=i.coords.start.client.y,i.coords.velocity.client.y=0,i.coords.velocity.page.y=0):f==="y"&&(i.coords.cur.page.x=i.coords.start.page.x,i.coords.cur.client.x=i.coords.start.client.x,i.coords.velocity.client.x=0,i.coords.velocity.page.x=0)}}function F(o){var i=o.iEvent,f=o.interaction;if(f.prepared.name==="drag"){var m=f.prepared.axis;if(m==="x"||m==="y"){var _=m==="x"?"y":"x";i.page[_]=f.coords.start.page[_],i.client[_]=f.coords.start.client[_],i.delta[_]=0}}}var J={id:"actions/drag",install:function(o){var i=o.actions,f=o.Interactable,m=o.defaults;f.prototype.draggable=J.draggable,i.map.drag=J,i.methodDict.drag="draggable",m.actions.drag=J.defaults},listeners:{"interactions:before-action-move":$,"interactions:action-resume":$,"interactions:action-move":F,"auto-start:check":function(o){var i=o.interaction,f=o.interactable,m=o.buttons,_=f.options.drag;if(_&&_.enabled&&(!i.pointerIsDown||!/mouse|pointer/.test(i.pointerType)||(m&f.options.drag.mouseButtons)!=0))return o.action={name:"drag",axis:_.lockAxis==="start"?_.startAxis:_.lockAxis},!1}},draggable:function(o){return w.object(o)?(this.options.drag.enabled=o.enabled!==!1,this.setPerAction("drag",o),this.setOnEvents("drag",o),/^(xy|x|y|start)$/.test(o.lockAxis)&&(this.options.drag.lockAxis=o.lockAxis),/^(xy|x|y)$/.test(o.startAxis)&&(this.options.drag.startAxis=o.startAxis),this):w.bool(o)?(this.options.drag.enabled=o,this):this.options.drag},beforeMove:$,move:F,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor:function(){return"move"},filterEventType:function(o){return o.search("drag")===0}},se=J,ge={init:function(o){var i=o;ge.document=i.document,ge.DocumentFragment=i.DocumentFragment||Me,ge.SVGElement=i.SVGElement||Me,ge.SVGSVGElement=i.SVGSVGElement||Me,ge.SVGElementInstance=i.SVGElementInstance||Me,ge.Element=i.Element||Me,ge.HTMLElement=i.HTMLElement||ge.Element,ge.Event=i.Event,ge.Touch=i.Touch||Me,ge.PointerEvent=i.PointerEvent||i.MSPointerEvent},document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function Me(){}var V=ge,fe={init:function(o){var i=V.Element,f=o.navigator||{};fe.supportsTouch="ontouchstart"in o||w.func(o.DocumentTouch)&&V.document instanceof o.DocumentTouch,fe.supportsPointerEvent=f.pointerEnabled!==!1&&!!V.PointerEvent,fe.isIOS=/iP(hone|od|ad)/.test(f.platform),fe.isIOS7=/iP(hone|od|ad)/.test(f.platform)&&/OS 7[^\d]/.test(f.appVersion),fe.isIe9=/MSIE 9/.test(f.userAgent),fe.isOperaMobile=f.appName==="Opera"&&fe.supportsTouch&&/Presto/.test(f.userAgent),fe.prefixedMatchesSelector="matches"in i.prototype?"matches":"webkitMatchesSelector"in i.prototype?"webkitMatchesSelector":"mozMatchesSelector"in i.prototype?"mozMatchesSelector":"oMatchesSelector"in i.prototype?"oMatchesSelector":"msMatchesSelector",fe.pEventTypes=fe.supportsPointerEvent?V.PointerEvent===o.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,fe.wheelEvent=V.document&&"onmousewheel"in V.document?"mousewheel":"wheel"},supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null},ae=fe;function de(o,i){if(o.contains)return o.contains(i);for(;i;){if(i===o)return!0;i=i.parentNode}return!1}function De(o,i){for(;w.element(o);){if(ye(o,i))return o;o=Fe(o)}return null}function Fe(o){var i=o.parentNode;if(w.docFrag(i)){for(;(i=i.host)&&w.docFrag(i););return i}return i}function ye(o,i){return j!==R&&(i=i.replace(/\/deep\//g," ")),o[ae.prefixedMatchesSelector](i)}var T=function(o){return o.parentNode||o.host};function ue(o,i){for(var f,m=[],_=o;(f=T(_))&&_!==i&&f!==_.ownerDocument;)m.unshift(_),_=f;return m}function U(o,i,f){for(;w.element(o);){if(ye(o,i))return!0;if((o=Fe(o))===f)return ye(o,i)}return!1}function Se(o){return o.correspondingUseElement||o}function Le(o){var i=o instanceof V.SVGElement?o.getBoundingClientRect():o.getClientRects()[0];return i&&{left:i.left,right:i.right,top:i.top,bottom:i.bottom,width:i.width||i.right-i.left,height:i.height||i.bottom-i.top}}function Pe(o){var i,f=Le(o);if(!ae.isIOS7&&f){var m={x:(i=(i=x(o))||j).scrollX||i.document.documentElement.scrollLeft,y:i.scrollY||i.document.documentElement.scrollTop};f.left+=m.x,f.right+=m.x,f.top+=m.y,f.bottom+=m.y}return f}function la(o){for(var i=[];o;)i.push(o),o=Fe(o);return i}function Da(o){return!!w.string(o)&&(V.document.querySelector(o),!0)}function le(o,i){for(var f in i)o[f]=i[f];return o}function ta(o,i,f){return o==="parent"?Fe(f):o==="self"?i.getRect(f):De(f,o)}function te(o,i,f,m){var _=o;return w.string(_)?_=ta(_,i,f):w.func(_)&&(_=_.apply(void 0,m)),w.element(_)&&(_=Pe(_)),_}function ca(o){return o&&{x:"x"in o?o.x:o.left,y:"y"in o?o.y:o.top}}function Ee(o){return!o||"x"in o&&"y"in o||((o=le({},o)).x=o.left||0,o.y=o.top||0,o.width=o.width||(o.right||0)-o.x,o.height=o.height||(o.bottom||0)-o.y),o}function oe(o,i,f){o.left&&(i.left+=f.x),o.right&&(i.right+=f.x),o.top&&(i.top+=f.y),o.bottom&&(i.bottom+=f.y),i.width=i.right-i.left,i.height=i.bottom-i.top}function Te(o,i,f){var m=f&&o.options[f];return ca(te(m&&m.origin||o.options.origin,o,i,[o&&i]))||{x:0,y:0}}function Ue(o,i){var f=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(ke){return!0},m=arguments.length>3?arguments[3]:void 0;if(m=m||{},w.string(o)&&o.search(" ")!==-1&&(o=oa(o)),w.array(o))return o.forEach(function(ke){return Ue(ke,i,f,m)}),m;if(w.object(o)&&(i=o,o=""),w.func(i)&&f(o))m[o]=m[o]||[],m[o].push(i);else if(w.array(i))for(var _=0,O=i;_<O.length;_++){var G=O[_];Ue(o,G,f,m)}else if(w.object(i))for(var ee in i)Ue(oa(ee).map(function(ke){return"".concat(o).concat(ke)}),i[ee],f,m);return m}function oa(o){return o.trim().split(/ +/)}var Ja=function(o,i){return Math.sqrt(o*o+i*i)},L=["webkit","moz"];function H(o,i){o.__set||(o.__set={});var f=function(_){if(L.some(function(O){return _.indexOf(O)===0}))return 1;typeof o[_]!="function"&&_!=="__set"&&Object.defineProperty(o,_,{get:function(){return _ in o.__set?o.__set[_]:o.__set[_]=i[_]},set:function(O){o.__set[_]=O},configurable:!0})};for(var m in i)f(m);return o}function Q(o,i){o.page=o.page||{},o.page.x=i.page.x,o.page.y=i.page.y,o.client=o.client||{},o.client.x=i.client.x,o.client.y=i.client.y,o.timeStamp=i.timeStamp}function me(o){o.page.x=0,o.page.y=0,o.client.x=0,o.client.y=0}function ve(o){return o instanceof V.Event||o instanceof V.Touch}function da(o,i,f){return o=o||"page",(f=f||{}).x=i[o+"X"],f.y=i[o+"Y"],f}function ea(o,i){return i=i||{x:0,y:0},ae.isOperaMobile&&ve(o)?(da("screen",o,i),i.x+=window.scrollX,i.y+=window.scrollY):da("page",o,i),i}function ce(o){return w.number(o.pointerId)?o.pointerId:o.identifier}function pa(o,i,f){var m=i.length>1?We(i):i[0];ea(m,o.page),function(_,O){O=O||{},ae.isOperaMobile&&ve(_)?da("screen",_,O):da("client",_,O)}(m,o.client),o.timeStamp=f}function Ne(o){var i=[];return w.array(o)?(i[0]=o[0],i[1]=o[1]):o.type==="touchend"?o.touches.length===1?(i[0]=o.touches[0],i[1]=o.changedTouches[0]):o.touches.length===0&&(i[0]=o.changedTouches[0],i[1]=o.changedTouches[1]):(i[0]=o.touches[0],i[1]=o.touches[1]),i}function We(o){for(var i={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0},f=0;f<o.length;f++){var m=o[f];for(var _ in i)i[_]+=m[_]}for(var O in i)i[O]/=o.length;return i}function Ta(o){if(!o.length)return null;var i=Ne(o),f=Math.min(i[0].pageX,i[1].pageX),m=Math.min(i[0].pageY,i[1].pageY),_=Math.max(i[0].pageX,i[1].pageX),O=Math.max(i[0].pageY,i[1].pageY);return{x:f,y:m,left:f,top:m,right:_,bottom:O,width:_-f,height:O-m}}function Ca(o,i){var f=i+"X",m=i+"Y",_=Ne(o),O=_[0][f]-_[1][f],G=_[0][m]-_[1][m];return Ja(O,G)}function Qe(o,i){var f=i+"X",m=i+"Y",_=Ne(o),O=_[1][f]-_[0][f],G=_[1][m]-_[0][m];return 180*Math.atan2(G,O)/Math.PI}function Va(o){return w.string(o.pointerType)?o.pointerType:w.number(o.pointerType)?[void 0,void 0,"touch","pen","mouse"][o.pointerType]:/touch/.test(o.type||"")||o instanceof V.Touch?"touch":"mouse"}function ne(o){var i=w.func(o.composedPath)?o.composedPath():o.path;return[Se(i?i[0]:o.target),Se(o.currentTarget)]}var X=function(){function o(i){s(this,o),this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=i}return d(o,[{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),o}();Object.defineProperty(X.prototype,"interaction",{get:function(){return this._interaction._proxy},set:function(){}});var Z=function(o,i){for(var f=0;f<i.length;f++){var m=i[f];o.push(m)}return o},q=function(o){return Z([],o)},Be=function(o,i){for(var f=0;f<o.length;f++)if(i(o[f],f,o))return f;return-1},Je=function(o,i){return o[Be(o,i)]},ra=function(o){y(f,o);var i=M(f);function f(m,_,O){var G;s(this,f),(G=i.call(this,_._interaction)).dropzone=void 0,G.dragEvent=void 0,G.relatedTarget=void 0,G.draggable=void 0,G.propagationStopped=!1,G.immediatePropagationStopped=!1;var ee=O==="dragleave"?m.prev:m.cur,ke=ee.element,He=ee.dropzone;return G.type=O,G.target=ke,G.currentTarget=ke,G.dropzone=He,G.dragEvent=_,G.relatedTarget=_.target,G.draggable=_.interactable,G.timeStamp=_.timeStamp,G}return d(f,[{key:"reject",value:function(){var m=this,_=this._interaction.dropState;if(this.type==="dropactivate"||this.dropzone&&_.cur.dropzone===this.dropzone&&_.cur.element===this.target)if(_.prev.dropzone=this.dropzone,_.prev.element=this.target,_.rejected=!0,_.events.enter=null,this.stopImmediatePropagation(),this.type==="dropactivate"){var O=_.activeDrops,G=Be(O,function(ke){var He=ke.dropzone,Ce=ke.element;return He===m.dropzone&&Ce===m.target});_.activeDrops.splice(G,1);var ee=new f(_,this.dragEvent,"dropdeactivate");ee.dropzone=this.dropzone,ee.target=this.target,this.dropzone.fire(ee)}else this.dropzone.fire(new f(_,this.dragEvent,"dragleave"))}},{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),f}(X);function ba(o,i){for(var f=0,m=o.slice();f<m.length;f++){var _=m[f],O=_.dropzone,G=_.element;i.dropzone=O,i.target=G,O.fire(i),i.propagationStopped=i.immediatePropagationStopped=!1}}function ga(o,i){for(var f=function(O,G){for(var ee=[],ke=0,He=O.interactables.list;ke<He.length;ke++){var Ce=He[ke];if(Ce.options.drop.enabled){var aa=Ce.options.drop.accept;if(!(w.element(aa)&&aa!==G||w.string(aa)&&!ye(G,aa)||w.func(aa)&&!aa({dropzone:Ce,draggableElement:G})))for(var Ba=0,Xa=Ce.getAllElements();Ba<Xa.length;Ba++){var Ka=Xa[Ba];Ka!==G&&ee.push({dropzone:Ce,element:Ka,rect:Ce.getRect(Ka)})}}}return ee}(o,i),m=0;m<f.length;m++){var _=f[m];_.rect=_.dropzone.getRect(_.element)}return f}function Aa(o,i,f){for(var m=o.dropState,_=o.interactable,O=o.element,G=[],ee=0,ke=m.activeDrops;ee<ke.length;ee++){var He=ke[ee],Ce=He.dropzone,aa=He.element,Ba=He.rect,Xa=Ce.dropCheck(i,f,_,O,aa,Ba);G.push(Xa?aa:null)}var Ka=function(al){for(var bl,vl,El,Hl=[],Cl=0;Cl<al.length;Cl++){var zl=al[Cl],Al=al[bl];if(zl&&Cl!==bl)if(Al){var Hr=T(zl),rr=T(Al);if(Hr!==zl.ownerDocument)if(rr!==zl.ownerDocument)if(Hr!==rr){Hl=Hl.length?Hl:ue(Al);var Gr=void 0;if(Al instanceof V.HTMLElement&&zl instanceof V.SVGElement&&!(zl instanceof V.SVGSVGElement)){if(zl===rr)continue;Gr=zl.ownerSVGElement}else Gr=zl;for(var on=ue(Gr,Al.ownerDocument),xn=0;on[xn]&&on[xn]===Hl[xn];)xn++;var fi=[on[xn-1],on[xn],Hl[xn]];if(fi[0])for(var Qn=fi[0].lastChild;Qn;){if(Qn===fi[1]){bl=Cl,Hl=on;break}if(Qn===fi[2])break;Qn=Qn.previousSibling}}else El=Al,(parseInt(x(vl=zl).getComputedStyle(vl).zIndex,10)||0)>=(parseInt(x(El).getComputedStyle(El).zIndex,10)||0)&&(bl=Cl);else bl=Cl}else bl=Cl}return bl}(G);return m.activeDrops[Ka]||null}function _a(o,i,f){var m=o.dropState,_={enter:null,leave:null,activate:null,deactivate:null,move:null,drop:null};return f.type==="dragstart"&&(_.activate=new ra(m,f,"dropactivate"),_.activate.target=null,_.activate.dropzone=null),f.type==="dragend"&&(_.deactivate=new ra(m,f,"dropdeactivate"),_.deactivate.target=null,_.deactivate.dropzone=null),m.rejected||(m.cur.element!==m.prev.element&&(m.prev.dropzone&&(_.leave=new ra(m,f,"dragleave"),f.dragLeave=_.leave.target=m.prev.element,f.prevDropzone=_.leave.dropzone=m.prev.dropzone),m.cur.dropzone&&(_.enter=new ra(m,f,"dragenter"),f.dragEnter=m.cur.element,f.dropzone=m.cur.dropzone)),f.type==="dragend"&&m.cur.dropzone&&(_.drop=new ra(m,f,"drop"),f.dropzone=m.cur.dropzone,f.relatedTarget=m.cur.element),f.type==="dragmove"&&m.cur.dropzone&&(_.move=new ra(m,f,"dropmove"),f.dropzone=m.cur.dropzone)),_}function Oe(o,i){var f=o.dropState,m=f.activeDrops,_=f.cur,O=f.prev;i.leave&&O.dropzone.fire(i.leave),i.enter&&_.dropzone.fire(i.enter),i.move&&_.dropzone.fire(i.move),i.drop&&_.dropzone.fire(i.drop),i.deactivate&&ba(m,i.deactivate),f.prev.dropzone=_.dropzone,f.prev.element=_.element}function Za(o,i){var f=o.interaction,m=o.iEvent,_=o.event;if(m.type==="dragmove"||m.type==="dragend"){var O=f.dropState;i.dynamicDrop&&(O.activeDrops=ga(i,f.element));var G=m,ee=Aa(f,G,_);O.rejected=O.rejected&&!!ee&&ee.dropzone===O.cur.dropzone&&ee.element===O.cur.element,O.cur.dropzone=ee&&ee.dropzone,O.cur.element=ee&&ee.element,O.events=_a(f,0,G)}}var Ha={id:"actions/drop",install:function(o){var i=o.actions,f=o.interactStatic,m=o.Interactable,_=o.defaults;o.usePlugin(se),m.prototype.dropzone=function(O){return function(G,ee){if(w.object(ee)){if(G.options.drop.enabled=ee.enabled!==!1,ee.listeners){var ke=Ue(ee.listeners),He=Object.keys(ke).reduce(function(aa,Ba){return aa[/^(enter|leave)/.test(Ba)?"drag".concat(Ba):/^(activate|deactivate|move)/.test(Ba)?"drop".concat(Ba):Ba]=ke[Ba],aa},{}),Ce=G.options.drop.listeners;Ce&&G.off(Ce),G.on(He),G.options.drop.listeners=He}return w.func(ee.ondrop)&&G.on("drop",ee.ondrop),w.func(ee.ondropactivate)&&G.on("dropactivate",ee.ondropactivate),w.func(ee.ondropdeactivate)&&G.on("dropdeactivate",ee.ondropdeactivate),w.func(ee.ondragenter)&&G.on("dragenter",ee.ondragenter),w.func(ee.ondragleave)&&G.on("dragleave",ee.ondragleave),w.func(ee.ondropmove)&&G.on("dropmove",ee.ondropmove),/^(pointer|center)$/.test(ee.overlap)?G.options.drop.overlap=ee.overlap:w.number(ee.overlap)&&(G.options.drop.overlap=Math.max(Math.min(1,ee.overlap),0)),"accept"in ee&&(G.options.drop.accept=ee.accept),"checker"in ee&&(G.options.drop.checker=ee.checker),G}return w.bool(ee)?(G.options.drop.enabled=ee,G):G.options.drop}(this,O)},m.prototype.dropCheck=function(O,G,ee,ke,He,Ce){return function(aa,Ba,Xa,Ka,al,bl,vl){var El=!1;if(!(vl=vl||aa.getRect(bl)))return!!aa.options.drop.checker&&aa.options.drop.checker(Ba,Xa,El,aa,bl,Ka,al);var Hl=aa.options.drop.overlap;if(Hl==="pointer"){var Cl=Te(Ka,al,"drag"),zl=ea(Ba);zl.x+=Cl.x,zl.y+=Cl.y;var Al=zl.x>vl.left&&zl.x<vl.right,Hr=zl.y>vl.top&&zl.y<vl.bottom;El=Al&&Hr}var rr=Ka.getRect(al);if(rr&&Hl==="center"){var Gr=rr.left+rr.width/2,on=rr.top+rr.height/2;El=Gr>=vl.left&&Gr<=vl.right&&on>=vl.top&&on<=vl.bottom}return rr&&w.number(Hl)&&(El=Math.max(0,Math.min(vl.right,rr.right)-Math.max(vl.left,rr.left))*Math.max(0,Math.min(vl.bottom,rr.bottom)-Math.max(vl.top,rr.top))/(rr.width*rr.height)>=Hl),aa.options.drop.checker&&(El=aa.options.drop.checker(Ba,Xa,El,aa,bl,Ka,al)),El}(this,O,G,ee,ke,He,Ce)},f.dynamicDrop=function(O){return w.bool(O)?(o.dynamicDrop=O,f):o.dynamicDrop},le(i.phaselessTypes,{dragenter:!0,dragleave:!0,dropactivate:!0,dropdeactivate:!0,dropmove:!0,drop:!0}),i.methodDict.drop="dropzone",o.dynamicDrop=!1,_.actions.drop=Ha.defaults},listeners:{"interactions:before-action-start":function(o){var i=o.interaction;i.prepared.name==="drag"&&(i.dropState={cur:{dropzone:null,element:null},prev:{dropzone:null,element:null},rejected:null,events:null,activeDrops:[]})},"interactions:after-action-start":function(o,i){var f=o.interaction,m=(o.event,o.iEvent);if(f.prepared.name==="drag"){var _=f.dropState;_.activeDrops=[],_.events={},_.activeDrops=ga(i,f.element),_.events=_a(f,0,m),_.events.activate&&(ba(_.activeDrops,_.events.activate),i.fire("actions/drop:start",{interaction:f,dragEvent:m}))}},"interactions:action-move":Za,"interactions:after-action-move":function(o,i){var f=o.interaction,m=o.iEvent;if(f.prepared.name==="drag"){var _=f.dropState;Oe(f,_.events),i.fire("actions/drop:move",{interaction:f,dragEvent:m}),_.events={}}},"interactions:action-end":function(o,i){if(o.interaction.prepared.name==="drag"){var f=o.interaction,m=o.iEvent;Za(o,i),Oe(f,f.dropState.events),i.fire("actions/drop:end",{interaction:f,dragEvent:m})}},"interactions:stop":function(o){var i=o.interaction;if(i.prepared.name==="drag"){var f=i.dropState;f&&(f.activeDrops=null,f.events=null,f.cur.dropzone=null,f.cur.element=null,f.prev.dropzone=null,f.prev.element=null,f.rejected=!1)}}},getActiveDrops:ga,getDrop:Aa,getDropEvents:_a,fireDropEvents:Oe,filterEventType:function(o){return o.search("drag")===0||o.search("drop")===0},defaults:{enabled:!1,accept:null,overlap:"pointer"}},xl=Ha;function Jl(o){var i=o.interaction,f=o.iEvent,m=o.phase;if(i.prepared.name==="gesture"){var _=i.pointers.map(function(He){return He.pointer}),O=m==="start",G=m==="end",ee=i.interactable.options.deltaSource;if(f.touches=[_[0],_[1]],O)f.distance=Ca(_,ee),f.box=Ta(_),f.scale=1,f.ds=0,f.angle=Qe(_,ee),f.da=0,i.gesture.startDistance=f.distance,i.gesture.startAngle=f.angle;else if(G||i.pointers.length<2){var ke=i.prevEvent;f.distance=ke.distance,f.box=ke.box,f.scale=ke.scale,f.ds=0,f.angle=ke.angle,f.da=0}else f.distance=Ca(_,ee),f.box=Ta(_),f.scale=f.distance/i.gesture.startDistance,f.angle=Qe(_,ee),f.ds=f.scale-i.gesture.scale,f.da=f.angle-i.gesture.angle;i.gesture.distance=f.distance,i.gesture.angle=f.angle,w.number(f.scale)&&f.scale!==1/0&&!isNaN(f.scale)&&(i.gesture.scale=f.scale)}}var kl={id:"actions/gesture",before:["actions/drag","actions/resize"],install:function(o){var i=o.actions,f=o.Interactable,m=o.defaults;f.prototype.gesturable=function(_){return w.object(_)?(this.options.gesture.enabled=_.enabled!==!1,this.setPerAction("gesture",_),this.setOnEvents("gesture",_),this):w.bool(_)?(this.options.gesture.enabled=_,this):this.options.gesture},i.map.gesture=kl,i.methodDict.gesture="gesturable",m.actions.gesture=kl.defaults},listeners:{"interactions:action-start":Jl,"interactions:action-move":Jl,"interactions:action-end":Jl,"interactions:new":function(o){o.interaction.gesture={angle:0,distance:0,scale:1,startAngle:0,startDistance:0}},"auto-start:check":function(o){if(!(o.interaction.pointers.length<2)){var i=o.interactable.options.gesture;if(i&&i.enabled)return o.action={name:"gesture"},!1}}},defaults:{},getCursor:function(){return""},filterEventType:function(o){return o.search("gesture")===0}},Pl=kl;function ja(o,i,f,m,_,O,G){if(!i)return!1;if(i===!0){var ee=w.number(O.width)?O.width:O.right-O.left,ke=w.number(O.height)?O.height:O.bottom-O.top;if(G=Math.min(G,Math.abs((o==="left"||o==="right"?ee:ke)/2)),ee<0&&(o==="left"?o="right":o==="right"&&(o="left")),ke<0&&(o==="top"?o="bottom":o==="bottom"&&(o="top")),o==="left"){var He=ee>=0?O.left:O.right;return f.x<He+G}if(o==="top"){var Ce=ke>=0?O.top:O.bottom;return f.y<Ce+G}if(o==="right")return f.x>(ee>=0?O.right:O.left)-G;if(o==="bottom")return f.y>(ke>=0?O.bottom:O.top)-G}return!!w.element(m)&&(w.element(i)?i===m:U(m,i,_))}function Ml(o){var i=o.iEvent,f=o.interaction;if(f.prepared.name==="resize"&&f.resizeAxes){var m=i;f.interactable.options.resize.square?(f.resizeAxes==="y"?m.delta.x=m.delta.y:m.delta.y=m.delta.x,m.axes="xy"):(m.axes=f.resizeAxes,f.resizeAxes==="x"?m.delta.y=0:f.resizeAxes==="y"&&(m.delta.x=0))}}var $l,Ma,rl={id:"actions/resize",before:["actions/drag"],install:function(o){var i=o.actions,f=o.browser,m=o.Interactable,_=o.defaults;rl.cursors=function(O){return O.isIe9?{x:"e-resize",y:"s-resize",xy:"se-resize",top:"n-resize",left:"w-resize",bottom:"s-resize",right:"e-resize",topleft:"se-resize",bottomright:"se-resize",topright:"ne-resize",bottomleft:"ne-resize"}:{x:"ew-resize",y:"ns-resize",xy:"nwse-resize",top:"ns-resize",left:"ew-resize",bottom:"ns-resize",right:"ew-resize",topleft:"nwse-resize",bottomright:"nwse-resize",topright:"nesw-resize",bottomleft:"nesw-resize"}}(f),rl.defaultMargin=f.supportsTouch||f.supportsPointerEvent?20:10,m.prototype.resizable=function(O){return function(G,ee,ke){return w.object(ee)?(G.options.resize.enabled=ee.enabled!==!1,G.setPerAction("resize",ee),G.setOnEvents("resize",ee),w.string(ee.axis)&&/^x$|^y$|^xy$/.test(ee.axis)?G.options.resize.axis=ee.axis:ee.axis===null&&(G.options.resize.axis=ke.defaults.actions.resize.axis),w.bool(ee.preserveAspectRatio)?G.options.resize.preserveAspectRatio=ee.preserveAspectRatio:w.bool(ee.square)&&(G.options.resize.square=ee.square),G):w.bool(ee)?(G.options.resize.enabled=ee,G):G.options.resize}(this,O,o)},i.map.resize=rl,i.methodDict.resize="resizable",_.actions.resize=rl.defaults},listeners:{"interactions:new":function(o){o.interaction.resizeAxes="xy"},"interactions:action-start":function(o){(function(i){var f=i.iEvent,m=i.interaction;if(m.prepared.name==="resize"&&m.prepared.edges){var _=f,O=m.rect;m._rects={start:le({},O),corrected:le({},O),previous:le({},O),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},_.edges=m.prepared.edges,_.rect=m._rects.corrected,_.deltaRect=m._rects.delta}})(o),Ml(o)},"interactions:action-move":function(o){(function(i){var f=i.iEvent,m=i.interaction;if(m.prepared.name==="resize"&&m.prepared.edges){var _=f,O=m.interactable.options.resize.invert,G=O==="reposition"||O==="negate",ee=m.rect,ke=m._rects,He=ke.start,Ce=ke.corrected,aa=ke.delta,Ba=ke.previous;if(le(Ba,Ce),G){if(le(Ce,ee),O==="reposition"){if(Ce.top>Ce.bottom){var Xa=Ce.top;Ce.top=Ce.bottom,Ce.bottom=Xa}if(Ce.left>Ce.right){var Ka=Ce.left;Ce.left=Ce.right,Ce.right=Ka}}}else Ce.top=Math.min(ee.top,He.bottom),Ce.bottom=Math.max(ee.bottom,He.top),Ce.left=Math.min(ee.left,He.right),Ce.right=Math.max(ee.right,He.left);for(var al in Ce.width=Ce.right-Ce.left,Ce.height=Ce.bottom-Ce.top,Ce)aa[al]=Ce[al]-Ba[al];_.edges=m.prepared.edges,_.rect=Ce,_.deltaRect=aa}})(o),Ml(o)},"interactions:action-end":function(o){var i=o.iEvent,f=o.interaction;if(f.prepared.name==="resize"&&f.prepared.edges){var m=i;m.edges=f.prepared.edges,m.rect=f._rects.corrected,m.deltaRect=f._rects.delta}},"auto-start:check":function(o){var i=o.interaction,f=o.interactable,m=o.element,_=o.rect,O=o.buttons;if(_){var G=le({},i.coords.cur.page),ee=f.options.resize;if(ee&&ee.enabled&&(!i.pointerIsDown||!/mouse|pointer/.test(i.pointerType)||(O&ee.mouseButtons)!=0)){if(w.object(ee.edges)){var ke={left:!1,right:!1,top:!1,bottom:!1};for(var He in ke)ke[He]=ja(He,ee.edges[He],G,i._latestPointer.eventTarget,m,_,ee.margin||rl.defaultMargin);ke.left=ke.left&&!ke.right,ke.top=ke.top&&!ke.bottom,(ke.left||ke.right||ke.top||ke.bottom)&&(o.action={name:"resize",edges:ke})}else{var Ce=ee.axis!=="y"&&G.x>_.right-rl.defaultMargin,aa=ee.axis!=="x"&&G.y>_.bottom-rl.defaultMargin;(Ce||aa)&&(o.action={name:"resize",axes:(Ce?"x":"")+(aa?"y":"")})}return!o.action&&void 0}}}},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor:function(o){var i=o.edges,f=o.axis,m=o.name,_=rl.cursors,O=null;if(f)O=_[m+f];else if(i){for(var G="",ee=0,ke=["top","bottom","left","right"];ee<ke.length;ee++){var He=ke[ee];i[He]&&(G+=He)}O=_[G]}return O},filterEventType:function(o){return o.search("resize")===0},defaultMargin:null},sl=rl,ma={id:"actions",install:function(o){o.usePlugin(Pl),o.usePlugin(sl),o.usePlugin(se),o.usePlugin(xl)}},ka=0,La={request:function(o){return $l(o)},cancel:function(o){return Ma(o)},init:function(o){if($l=o.requestAnimationFrame,Ma=o.cancelAnimationFrame,!$l)for(var i=["ms","moz","webkit","o"],f=0;f<i.length;f++){var m=i[f];$l=o["".concat(m,"RequestAnimationFrame")],Ma=o["".concat(m,"CancelAnimationFrame")]||o["".concat(m,"CancelRequestAnimationFrame")]}$l=$l&&$l.bind(o),Ma=Ma&&Ma.bind(o),$l||($l=function(_){var O=Date.now(),G=Math.max(0,16-(O-ka)),ee=o.setTimeout(function(){_(O+G)},G);return ka=O+G,ee},Ma=function(_){return clearTimeout(_)})}},$a={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(o){$a.isScrolling=!0,La.cancel($a.i),o.autoScroll=$a,$a.interaction=o,$a.prevTime=$a.now(),$a.i=La.request($a.scroll)},stop:function(){$a.isScrolling=!1,$a.interaction&&($a.interaction.autoScroll=null),La.cancel($a.i)},scroll:function(){var o=$a.interaction,i=o.interactable,f=o.element,m=o.prepared.name,_=i.options[m].autoScroll,O=we(_.container,i,f),G=$a.now(),ee=(G-$a.prevTime)/1e3,ke=_.speed*ee;if(ke>=1){var He={x:$a.x*ke,y:$a.y*ke};if(He.x||He.y){var Ce=ia(O);w.window(O)?O.scrollBy(He.x,He.y):O&&(O.scrollLeft+=He.x,O.scrollTop+=He.y);var aa=ia(O),Ba={x:aa.x-Ce.x,y:aa.y-Ce.y};(Ba.x||Ba.y)&&i.fire({type:"autoscroll",target:f,interactable:i,delta:Ba,interaction:o,container:O})}$a.prevTime=G}$a.isScrolling&&(La.cancel($a.i),$a.i=La.request($a.scroll))},check:function(o,i){var f;return(f=o.options[i].autoScroll)==null?void 0:f.enabled},onInteractionMove:function(o){var i=o.interaction,f=o.pointer;if(i.interacting()&&$a.check(i.interactable,i.prepared.name))if(i.simulation)$a.x=$a.y=0;else{var m,_,O,G,ee=i.interactable,ke=i.element,He=i.prepared.name,Ce=ee.options[He].autoScroll,aa=we(Ce.container,ee,ke);if(w.window(aa))G=f.clientX<$a.margin,m=f.clientY<$a.margin,_=f.clientX>aa.innerWidth-$a.margin,O=f.clientY>aa.innerHeight-$a.margin;else{var Ba=Le(aa);G=f.clientX<Ba.left+$a.margin,m=f.clientY<Ba.top+$a.margin,_=f.clientX>Ba.right-$a.margin,O=f.clientY>Ba.bottom-$a.margin}$a.x=_?1:G?-1:0,$a.y=O?1:m?-1:0,$a.isScrolling||($a.margin=Ce.margin,$a.speed=Ce.speed,$a.start(i))}}};function we(o,i,f){return(w.string(o)?ta(o,i,f):o)||x(f)}function ia(o){return w.window(o)&&(o=window.document.body),{x:o.scrollLeft,y:o.scrollTop}}var Ie={id:"auto-scroll",install:function(o){var i=o.defaults,f=o.actions;o.autoScroll=$a,$a.now=function(){return o.now()},f.phaselessTypes.autoscroll=!0,i.perAction.autoScroll=$a.defaults},listeners:{"interactions:new":function(o){o.interaction.autoScroll=null},"interactions:destroy":function(o){o.interaction.autoScroll=null,$a.stop(),$a.interaction&&($a.interaction=null)},"interactions:stop":$a.stop,"interactions:action-move":function(o){return $a.onInteractionMove(o)}}},pe=Ie;function ha(o,i){var f=!1;return function(){return f||(j.console.warn(i),f=!0),o.apply(this,arguments)}}function va(o,i){return o.name=i.name,o.axis=i.axis,o.edges=i.edges,o}function Xe(o){return w.bool(o)?(this.options.styleCursor=o,this):o===null?(delete this.options.styleCursor,this):this.options.styleCursor}function Ze(o){return w.func(o)?(this.options.actionChecker=o,this):o===null?(delete this.options.actionChecker,this):this.options.actionChecker}var Ke={id:"auto-start/interactableMethods",install:function(o){var i=o.Interactable;i.prototype.getAction=function(f,m,_,O){var G=function(ee,ke,He,Ce,aa){var Ba=ee.getRect(Ce),Xa=ke.buttons||{0:1,1:4,3:8,4:16}[ke.button],Ka={action:null,interactable:ee,interaction:He,element:Ce,rect:Ba,buttons:Xa};return aa.fire("auto-start:check",Ka),Ka.action}(this,m,_,O,o);return this.options.actionChecker?this.options.actionChecker(f,m,G,this,O,_):G},i.prototype.ignoreFrom=ha(function(f){return this._backCompatOption("ignoreFrom",f)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),i.prototype.allowFrom=ha(function(f){return this._backCompatOption("allowFrom",f)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),i.prototype.actionChecker=Ze,i.prototype.styleCursor=Xe}};function pl(o,i,f,m,_){return i.testIgnoreAllow(i.options[o.name],f,m)&&i.options[o.name].enabled&&il(i,f,o,_)?o:null}function Ve(o,i,f,m,_,O,G){for(var ee=0,ke=m.length;ee<ke;ee++){var He=m[ee],Ce=_[ee],aa=He.getAction(i,f,o,Ce);if(aa){var Ba=pl(aa,He,Ce,O,G);if(Ba)return{action:Ba,interactable:He,element:Ce}}}return{action:null,interactable:null,element:null}}function Fa(o,i,f,m,_){var O=[],G=[],ee=m;function ke(Ce){O.push(Ce),G.push(ee)}for(;w.element(ee);){O=[],G=[],_.interactables.forEachMatch(ee,ke);var He=Ve(o,i,f,O,G,m,_);if(He.action&&!He.interactable.options[He.action.name].manualStart)return He;ee=Fe(ee)}return{action:null,interactable:null,element:null}}function Sa(o,i,f){var m=i.action,_=i.interactable,O=i.element;m=m||{name:null},o.interactable=_,o.element=O,va(o.prepared,m),o.rect=_&&m.name?_.getRect(O):null,_l(o,f),f.fire("autoStart:prepared",{interaction:o})}function il(o,i,f,m){var _=o.options,O=_[f.name].max,G=_[f.name].maxPerElement,ee=m.autoStart.maxInteractions,ke=0,He=0,Ce=0;if(!(O&&G&&ee))return!1;for(var aa=0,Ba=m.interactions.list;aa<Ba.length;aa++){var Xa=Ba[aa],Ka=Xa.prepared.name;if(Xa.interacting()&&(++ke>=ee||Xa.interactable===o&&((He+=Ka===f.name?1:0)>=O||Xa.element===i&&(Ce++,Ka===f.name&&Ce>=G))))return!1}return ee>0}function Ia(o,i){return w.number(o)?(i.autoStart.maxInteractions=o,this):i.autoStart.maxInteractions}function ze(o,i,f){var m=f.autoStart.cursorElement;m&&m!==o&&(m.style.cursor=""),o.ownerDocument.documentElement.style.cursor=i,o.style.cursor=i,f.autoStart.cursorElement=i?o:null}function _l(o,i){var f=o.interactable,m=o.element,_=o.prepared;if(o.pointerType==="mouse"&&f&&f.options.styleCursor){var O="";if(_.name){var G=f.options[_.name].cursorChecker;O=w.func(G)?G(_,f,m,o._interacting):i.actions.map[_.name].getCursor(_)}ze(o.element,O||"",i)}else i.autoStart.cursorElement&&ze(i.autoStart.cursorElement,"",i)}var Ol={id:"auto-start/base",before:["actions"],install:function(o){var i=o.interactStatic,f=o.defaults;o.usePlugin(Ke),f.base.actionChecker=null,f.base.styleCursor=!0,le(f.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),i.maxInteractions=function(m){return Ia(m,o)},o.autoStart={maxInteractions:1/0,withinInteractionLimit:il,cursorElement:null}},listeners:{"interactions:down":function(o,i){var f=o.interaction,m=o.pointer,_=o.event,O=o.eventTarget;f.interacting()||Sa(f,Fa(f,m,_,O,i),i)},"interactions:move":function(o,i){(function(f,m){var _=f.interaction,O=f.pointer,G=f.event,ee=f.eventTarget;_.pointerType!=="mouse"||_.pointerIsDown||_.interacting()||Sa(_,Fa(_,O,G,ee,m),m)})(o,i),function(f,m){var _=f.interaction;if(_.pointerIsDown&&!_.interacting()&&_.pointerWasMoved&&_.prepared.name){m.fire("autoStart:before-start",f);var O=_.interactable,G=_.prepared.name;G&&O&&(O.options[G].manualStart||!il(O,_.element,_.prepared,m)?_.stop():(_.start(_.prepared,O,_.element),_l(_,m)))}}(o,i)},"interactions:stop":function(o,i){var f=o.interaction,m=f.interactable;m&&m.options.styleCursor&&ze(f.element,"",i)}},maxInteractions:Ia,withinInteractionLimit:il,validateAction:pl},ql=Ol,Wl={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":function(o,i){var f=o.interaction,m=o.eventTarget,_=o.dx,O=o.dy;if(f.prepared.name==="drag"){var G=Math.abs(_),ee=Math.abs(O),ke=f.interactable.options.drag,He=ke.startAxis,Ce=G>ee?"x":G<ee?"y":"xy";if(f.prepared.axis=ke.lockAxis==="start"?Ce[0]:ke.lockAxis,Ce!=="xy"&&He!=="xy"&&He!==Ce){f.prepared.name=null;for(var aa=m,Ba=function(Ka){if(Ka!==f.interactable){var al=f.interactable.options.drag;if(!al.manualStart&&Ka.testIgnoreAllow(al,aa,m)){var bl=Ka.getAction(f.downPointer,f.downEvent,f,aa);if(bl&&bl.name==="drag"&&function(vl,El){if(!El)return!1;var Hl=El.options.drag.startAxis;return vl==="xy"||Hl==="xy"||Hl===vl}(Ce,Ka)&&ql.validateAction(bl,Ka,aa,m,i))return Ka}}};w.element(aa);){var Xa=i.interactables.forEachMatch(aa,Ba);if(Xa){f.prepared.name="drag",f.interactable=Xa,f.element=aa;break}aa=Fe(aa)}}}}}};function Ql(o){var i=o.prepared&&o.prepared.name;if(!i)return null;var f=o.interactable.options;return f[i].hold||f[i].delay}var pr={id:"auto-start/hold",install:function(o){var i=o.defaults;o.usePlugin(ql),i.perAction.hold=0,i.perAction.delay=0},listeners:{"interactions:new":function(o){o.interaction.autoStartHoldTimer=null},"autoStart:prepared":function(o){var i=o.interaction,f=Ql(i);f>0&&(i.autoStartHoldTimer=setTimeout(function(){i.start(i.prepared,i.interactable,i.element)},f))},"interactions:move":function(o){var i=o.interaction,f=o.duplicate;i.autoStartHoldTimer&&i.pointerWasMoved&&!f&&(clearTimeout(i.autoStartHoldTimer),i.autoStartHoldTimer=null)},"autoStart:before-start":function(o){var i=o.interaction;Ql(i)>0&&(i.prepared.name=null)}},getHoldDuration:Ql},Ll=pr,fr={id:"auto-start",install:function(o){o.usePlugin(ql),o.usePlugin(Ll),o.usePlugin(Wl)}},Vr=function(o){return/^(always|never|auto)$/.test(o)?(this.options.preventDefault=o,this):w.bool(o)?(this.options.preventDefault=o?"always":"never",this):this.options.preventDefault};function jl(o){var i=o.interaction,f=o.event;i.interactable&&i.interactable.checkAndPreventDefault(f)}var ar={id:"core/interactablePreventDefault",install:function(o){var i=o.Interactable;i.prototype.preventDefault=Vr,i.prototype.checkAndPreventDefault=function(f){return function(m,_,O){var G=m.options.preventDefault;if(G!=="never")if(G!=="always"){if(_.events.supportsPassive&&/^touch(start|move)$/.test(O.type)){var ee=x(O.target).document,ke=_.getDocOptions(ee);if(!ke||!ke.events||ke.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(O.type)||w.element(O.target)&&ye(O.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||O.preventDefault()}else O.preventDefault()}(this,o,f)},o.interactions.docEvents.push({type:"dragstart",listener:function(f){for(var m=0,_=o.interactions.list;m<_.length;m++){var O=_[m];if(O.element&&(O.element===f.target||de(O.element,f.target)))return void O.interactable.checkAndPreventDefault(f)}}})},listeners:["down","move","up","cancel"].reduce(function(o,i){return o["interactions:".concat(i)]=jl,o},{})};function Fr(o,i){if(i.phaselessTypes[o])return!0;for(var f in i.map)if(o.indexOf(f)===0&&o.substr(f.length)in i.phases)return!0;return!1}function Nr(o){var i={};for(var f in o){var m=o[f];w.plainObject(m)?i[f]=Nr(m):w.array(m)?i[f]=q(m):i[f]=m}return i}var Pr=function(){function o(i){s(this,o),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=i,this.result=Mr(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}return d(o,[{key:"start",value:function(i,f){var m,_,O=i.phase,G=this.interaction,ee=function(He){var Ce=He.interactable.options[He.prepared.name],aa=Ce.modifiers;return aa&&aa.length?aa:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(function(Ba){var Xa=Ce[Ba];return Xa&&Xa.enabled&&{options:Xa,methods:Xa._methods}}).filter(function(Ba){return!!Ba})}(G);this.prepareStates(ee),this.startEdges=le({},G.edges),this.edges=le({},this.startEdges),this.startOffset=(m=G.rect,_=f,m?{left:_.x-m.left,top:_.y-m.top,right:m.right-_.x,bottom:m.bottom-_.y}:{left:0,top:0,right:0,bottom:0}),this.startDelta={x:0,y:0};var ke=this.fillArg({phase:O,pageCoords:f,preEnd:!1});return this.result=Mr(),this.startAll(ke),this.result=this.setAll(ke)}},{key:"fillArg",value:function(i){var f=this.interaction;return i.interaction=f,i.interactable=f.interactable,i.element=f.element,i.rect||(i.rect=f.rect),i.edges||(i.edges=this.startEdges),i.startOffset=this.startOffset,i}},{key:"startAll",value:function(i){for(var f=0,m=this.states;f<m.length;f++){var _=m[f];_.methods.start&&(i.state=_,_.methods.start(i))}}},{key:"setAll",value:function(i){var f=i.phase,m=i.preEnd,_=i.skipModifiers,O=i.rect,G=i.edges;i.coords=le({},i.pageCoords),i.rect=le({},O),i.edges=le({},G);for(var ee=_?this.states.slice(_):this.states,ke=Mr(i.coords,i.rect),He=0;He<ee.length;He++){var Ce,aa=ee[He],Ba=aa.options,Xa=le({},i.coords),Ka=null;(Ce=aa.methods)!=null&&Ce.set&&this.shouldDo(Ba,m,f)&&(i.state=aa,Ka=aa.methods.set(i),oe(i.edges,i.rect,{x:i.coords.x-Xa.x,y:i.coords.y-Xa.y})),ke.eventProps.push(Ka)}le(this.edges,i.edges),ke.delta.x=i.coords.x-i.pageCoords.x,ke.delta.y=i.coords.y-i.pageCoords.y,ke.rectDelta.left=i.rect.left-O.left,ke.rectDelta.right=i.rect.right-O.right,ke.rectDelta.top=i.rect.top-O.top,ke.rectDelta.bottom=i.rect.bottom-O.bottom;var al=this.result.coords,bl=this.result.rect;if(al&&bl){var vl=ke.rect.left!==bl.left||ke.rect.right!==bl.right||ke.rect.top!==bl.top||ke.rect.bottom!==bl.bottom;ke.changed=vl||al.x!==ke.coords.x||al.y!==ke.coords.y}return ke}},{key:"applyToInteraction",value:function(i){var f=this.interaction,m=i.phase,_=f.coords.cur,O=f.coords.start,G=this.result,ee=this.startDelta,ke=G.delta;m==="start"&&le(this.startDelta,G.delta);for(var He=0,Ce=[[O,ee],[_,ke]];He<Ce.length;He++){var aa=Ce[He],Ba=aa[0],Xa=aa[1];Ba.page.x+=Xa.x,Ba.page.y+=Xa.y,Ba.client.x+=Xa.x,Ba.client.y+=Xa.y}var Ka=this.result.rectDelta,al=i.rect||f.rect;al.left+=Ka.left,al.right+=Ka.right,al.top+=Ka.top,al.bottom+=Ka.bottom,al.width=al.right-al.left,al.height=al.bottom-al.top}},{key:"setAndApply",value:function(i){var f=this.interaction,m=i.phase,_=i.preEnd,O=i.skipModifiers,G=this.setAll(this.fillArg({preEnd:_,phase:m,pageCoords:i.modifiedCoords||f.coords.cur.page}));if(this.result=G,!G.changed&&(!O||O<this.states.length)&&f.interacting())return!1;if(i.modifiedCoords){var ee=f.coords.cur.page,ke={x:i.modifiedCoords.x-ee.x,y:i.modifiedCoords.y-ee.y};G.coords.x+=ke.x,G.coords.y+=ke.y,G.delta.x+=ke.x,G.delta.y+=ke.y}this.applyToInteraction(i)}},{key:"beforeEnd",value:function(i){var f=i.interaction,m=i.event,_=this.states;if(_&&_.length){for(var O=!1,G=0;G<_.length;G++){var ee=_[G];i.state=ee;var ke=ee.options,He=ee.methods,Ce=He.beforeEnd&&He.beforeEnd(i);if(Ce)return this.endResult=Ce,!1;O=O||!O&&this.shouldDo(ke,!0,i.phase,!0)}O&&f.move({event:m,preEnd:!0})}}},{key:"stop",value:function(i){var f=i.interaction;if(this.states&&this.states.length){var m=le({states:this.states,interactable:f.interactable,element:f.element,rect:null},i);this.fillArg(m);for(var _=0,O=this.states;_<O.length;_++){var G=O[_];m.state=G,G.methods.stop&&G.methods.stop(m)}this.states=null,this.endResult=null}}},{key:"prepareStates",value:function(i){this.states=[];for(var f=0;f<i.length;f++){var m=i[f],_=m.options,O=m.methods,G=m.name;this.states.push({options:_,methods:O,index:f,name:G})}return this.states}},{key:"restoreInteractionCoords",value:function(i){var f=i.interaction,m=f.coords,_=f.rect,O=f.modification;if(O.result){for(var G=O.startDelta,ee=O.result,ke=ee.delta,He=ee.rectDelta,Ce=0,aa=[[m.start,G],[m.cur,ke]];Ce<aa.length;Ce++){var Ba=aa[Ce],Xa=Ba[0],Ka=Ba[1];Xa.page.x-=Ka.x,Xa.page.y-=Ka.y,Xa.client.x-=Ka.x,Xa.client.y-=Ka.y}_.left-=He.left,_.right-=He.right,_.top-=He.top,_.bottom-=He.bottom}}},{key:"shouldDo",value:function(i,f,m,_){return!(!i||i.enabled===!1||_&&!i.endOnly||i.endOnly&&!f||m==="start"&&!i.setStart)}},{key:"copyFrom",value:function(i){this.startOffset=i.startOffset,this.startDelta=i.startDelta,this.startEdges=i.startEdges,this.edges=i.edges,this.states=i.states.map(function(f){return Nr(f)}),this.result=Mr(le({},i.result.coords),le({},i.result.rect))}},{key:"destroy",value:function(){for(var i in this)this[i]=null}}]),o}();function Mr(o,i){return{rect:i,coords:o,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function Sr(o,i){var f=o.defaults,m={start:o.start,set:o.set,beforeEnd:o.beforeEnd,stop:o.stop},_=function(O){var G=O||{};for(var ee in G.enabled=G.enabled!==!1,f)ee in G||(G[ee]=f[ee]);var ke={options:G,methods:m,name:i,enable:function(){return G.enabled=!0,ke},disable:function(){return G.enabled=!1,ke}};return ke};return i&&typeof i=="string"&&(_._defaults=f,_._methods=m),_}function Er(o){var i=o.iEvent,f=o.interaction.modification.result;f&&(i.modifiers=f.eventProps)}var mn={id:"modifiers/base",before:["actions"],install:function(o){o.defaults.perAction.modifiers=[]},listeners:{"interactions:new":function(o){var i=o.interaction;i.modification=new Pr(i)},"interactions:before-action-start":function(o){var i=o.interaction,f=o.interaction.modification;f.start(o,i.coords.start.page),i.edges=f.edges,f.applyToInteraction(o)},"interactions:before-action-move":function(o){var i=o.interaction,f=i.modification,m=f.setAndApply(o);return i.edges=f.edges,m},"interactions:before-action-end":function(o){var i=o.interaction,f=i.modification,m=f.beforeEnd(o);return i.edges=f.startEdges,m},"interactions:action-start":Er,"interactions:action-move":Er,"interactions:action-end":Er,"interactions:after-action-start":function(o){return o.interaction.modification.restoreInteractionCoords(o)},"interactions:after-action-move":function(o){return o.interaction.modification.restoreInteractionCoords(o)},"interactions:stop":function(o){return o.interaction.modification.stop(o)}}},Dr=mn,ur={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}},yn=function(o){y(f,o);var i=M(f);function f(m,_,O,G,ee,ke,He){var Ce;s(this,f),(Ce=i.call(this,m)).relatedTarget=null,Ce.screenX=void 0,Ce.screenY=void 0,Ce.button=void 0,Ce.buttons=void 0,Ce.ctrlKey=void 0,Ce.shiftKey=void 0,Ce.altKey=void 0,Ce.metaKey=void 0,Ce.page=void 0,Ce.client=void 0,Ce.delta=void 0,Ce.rect=void 0,Ce.x0=void 0,Ce.y0=void 0,Ce.t0=void 0,Ce.dt=void 0,Ce.duration=void 0,Ce.clientX0=void 0,Ce.clientY0=void 0,Ce.velocity=void 0,Ce.speed=void 0,Ce.swipe=void 0,Ce.axes=void 0,Ce.preEnd=void 0,ee=ee||m.element;var aa=m.interactable,Ba=(aa&&aa.options||ur).deltaSource,Xa=Te(aa,ee,O),Ka=G==="start",al=G==="end",bl=Ka?D(Ce):m.prevEvent,vl=Ka?m.coords.start:al?{page:bl.page,client:bl.client,timeStamp:m.coords.cur.timeStamp}:m.coords.cur;return Ce.page=le({},vl.page),Ce.client=le({},vl.client),Ce.rect=le({},m.rect),Ce.timeStamp=vl.timeStamp,al||(Ce.page.x-=Xa.x,Ce.page.y-=Xa.y,Ce.client.x-=Xa.x,Ce.client.y-=Xa.y),Ce.ctrlKey=_.ctrlKey,Ce.altKey=_.altKey,Ce.shiftKey=_.shiftKey,Ce.metaKey=_.metaKey,Ce.button=_.button,Ce.buttons=_.buttons,Ce.target=ee,Ce.currentTarget=ee,Ce.preEnd=ke,Ce.type=He||O+(G||""),Ce.interactable=aa,Ce.t0=Ka?m.pointers[m.pointers.length-1].downTime:bl.t0,Ce.x0=m.coords.start.page.x-Xa.x,Ce.y0=m.coords.start.page.y-Xa.y,Ce.clientX0=m.coords.start.client.x-Xa.x,Ce.clientY0=m.coords.start.client.y-Xa.y,Ce.delta=Ka||al?{x:0,y:0}:{x:Ce[Ba].x-bl[Ba].x,y:Ce[Ba].y-bl[Ba].y},Ce.dt=m.coords.delta.timeStamp,Ce.duration=Ce.timeStamp-Ce.t0,Ce.velocity=le({},m.coords.velocity[Ba]),Ce.speed=Ja(Ce.velocity.x,Ce.velocity.y),Ce.swipe=al||G==="inertiastart"?Ce.getSwipe():null,Ce}return d(f,[{key:"getSwipe",value:function(){var m=this._interaction;if(m.prevEvent.speed<600||this.timeStamp-m.prevEvent.timeStamp>150)return null;var _=180*Math.atan2(m.prevEvent.velocityY,m.prevEvent.velocityX)/Math.PI;_<0&&(_+=360);var O=112.5<=_&&_<247.5,G=202.5<=_&&_<337.5;return{up:G,down:!G&&22.5<=_&&_<157.5,left:O,right:!O&&(292.5<=_||_<67.5),angle:_,speed:m.prevEvent.speed,velocity:{x:m.prevEvent.velocityX,y:m.prevEvent.velocityY}}}},{key:"preventDefault",value:function(){}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}}]),f}(X);Object.defineProperties(yn.prototype,{pageX:{get:function(){return this.page.x},set:function(o){this.page.x=o}},pageY:{get:function(){return this.page.y},set:function(o){this.page.y=o}},clientX:{get:function(){return this.client.x},set:function(o){this.client.x=o}},clientY:{get:function(){return this.client.y},set:function(o){this.client.y=o}},dx:{get:function(){return this.delta.x},set:function(o){this.delta.x=o}},dy:{get:function(){return this.delta.y},set:function(o){this.delta.y=o}},velocityX:{get:function(){return this.velocity.x},set:function(o){this.velocity.x=o}},velocityY:{get:function(){return this.velocity.y},set:function(o){this.velocity.y=o}}});var ln=d(function o(i,f,m,_,O){s(this,o),this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=i,this.pointer=f,this.event=m,this.downTime=_,this.downTarget=O}),rn=function(o){return o.interactable="",o.element="",o.prepared="",o.pointerIsDown="",o.pointerWasMoved="",o._proxy="",o}({}),_n=function(o){return o.start="",o.move="",o.end="",o.stop="",o.interacting="",o}({}),Bn=0,pn=function(){function o(i){var f=this,m=i.pointerType,_=i.scopeFire;s(this,o),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=ha(function(Ce){this.move(Ce)},"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=Bn++,this._scopeFire=_,this.pointerType=m;var O=this;this._proxy={};var G=function(Ce){Object.defineProperty(f._proxy,Ce,{get:function(){return O[Ce]}})};for(var ee in rn)G(ee);var ke=function(Ce){Object.defineProperty(f._proxy,Ce,{value:function(){return O[Ce].apply(O,arguments)}})};for(var He in _n)ke(He);this._scopeFire("interactions:new",{interaction:this})}return d(o,[{key:"pointerMoveTolerance",get:function(){return 1}},{key:"pointerDown",value:function(i,f,m){var _=this.updatePointer(i,f,m,!0),O=this.pointers[_];this._scopeFire("interactions:down",{pointer:i,event:f,eventTarget:m,pointerIndex:_,pointerInfo:O,type:"down",interaction:this})}},{key:"start",value:function(i,f,m){return!(this.interacting()||!this.pointerIsDown||this.pointers.length<(i.name==="gesture"?2:1)||!f.options[i.name].enabled)&&(va(this.prepared,i),this.interactable=f,this.element=m,this.rect=f.getRect(m),this.edges=this.prepared.edges?le({},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(i,f,m){this.simulation||this.modification&&this.modification.endResult||this.updatePointer(i,f,m,!1);var _,O,G=this.coords.cur.page.x===this.coords.prev.page.x&&this.coords.cur.page.y===this.coords.prev.page.y&&this.coords.cur.client.x===this.coords.prev.client.x&&this.coords.cur.client.y===this.coords.prev.client.y;this.pointerIsDown&&!this.pointerWasMoved&&(_=this.coords.cur.client.x-this.coords.start.client.x,O=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=Ja(_,O)>this.pointerMoveTolerance);var ee,ke,He,Ce=this.getPointerIndex(i),aa={pointer:i,pointerIndex:Ce,pointerInfo:this.pointers[Ce],event:f,type:"move",eventTarget:m,dx:_,dy:O,duplicate:G,interaction:this};G||(ee=this.coords.velocity,ke=this.coords.delta,He=Math.max(ke.timeStamp/1e3,.001),ee.page.x=ke.page.x/He,ee.page.y=ke.page.y/He,ee.client.x=ke.client.x/He,ee.client.y=ke.client.y/He,ee.timeStamp=He),this._scopeFire("interactions:move",aa),G||this.simulation||(this.interacting()&&(aa.type=null,this.move(aa)),this.pointerWasMoved&&Q(this.coords.prev,this.coords.cur))}},{key:"move",value:function(i){i&&i.event||me(this.coords.delta),(i=le({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},i||{})).phase="move",this._doPhase(i)}},{key:"pointerUp",value:function(i,f,m,_){var O=this.getPointerIndex(i);O===-1&&(O=this.updatePointer(i,f,m,!1));var G=/cancel$/i.test(f.type)?"cancel":"up";this._scopeFire("interactions:".concat(G),{pointer:i,pointerIndex:O,pointerInfo:this.pointers[O],event:f,eventTarget:m,type:G,curEventTarget:_,interaction:this}),this.simulation||this.end(f),this.removePointer(i,f)}},{key:"documentBlur",value:function(i){this.end(i),this._scopeFire("interactions:blur",{event:i,type:"blur",interaction:this})}},{key:"end",value:function(i){var f;this._ending=!0,i=i||this._latestPointer.event,this.interacting()&&(f=this._doPhase({event:i,interaction:this,phase:"end"})),this._ending=!1,f===!0&&this.stop()}},{key:"currentAction",value:function(){return this._interacting?this.prepared.name:null}},{key:"interacting",value:function(){return this._interacting}},{key:"stop",value:function(){this._scopeFire("interactions:stop",{interaction:this}),this.interactable=this.element=null,this._interacting=!1,this._stopped=!0,this.prepared.name=this.prevEvent=null}},{key:"getPointerIndex",value:function(i){var f=ce(i);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:Be(this.pointers,function(m){return m.id===f})}},{key:"getPointerInfo",value:function(i){return this.pointers[this.getPointerIndex(i)]}},{key:"updatePointer",value:function(i,f,m,_){var O,G,ee,ke=ce(i),He=this.getPointerIndex(i),Ce=this.pointers[He];return _=_!==!1&&(_||/(down|start)$/i.test(f.type)),Ce?Ce.pointer=i:(Ce=new ln(ke,i,f,null,null),He=this.pointers.length,this.pointers.push(Ce)),pa(this.coords.cur,this.pointers.map(function(aa){return aa.pointer}),this._now()),O=this.coords.delta,G=this.coords.prev,ee=this.coords.cur,O.page.x=ee.page.x-G.page.x,O.page.y=ee.page.y-G.page.y,O.client.x=ee.client.x-G.client.x,O.client.y=ee.client.y-G.client.y,O.timeStamp=ee.timeStamp-G.timeStamp,_&&(this.pointerIsDown=!0,Ce.downTime=this.coords.cur.timeStamp,Ce.downTarget=m,H(this.downPointer,i),this.interacting()||(Q(this.coords.start,this.coords.cur),Q(this.coords.prev,this.coords.cur),this.downEvent=f,this.pointerWasMoved=!1)),this._updateLatestPointer(i,f,m),this._scopeFire("interactions:update-pointer",{pointer:i,event:f,eventTarget:m,down:_,pointerInfo:Ce,pointerIndex:He,interaction:this}),He}},{key:"removePointer",value:function(i,f){var m=this.getPointerIndex(i);if(m!==-1){var _=this.pointers[m];this._scopeFire("interactions:remove-pointer",{pointer:i,event:f,eventTarget:null,pointerIndex:m,pointerInfo:_,interaction:this}),this.pointers.splice(m,1),this.pointerIsDown=!1}}},{key:"_updateLatestPointer",value:function(i,f,m){this._latestPointer.pointer=i,this._latestPointer.event=f,this._latestPointer.eventTarget=m}},{key:"destroy",value:function(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}},{key:"_createPreparedEvent",value:function(i,f,m,_){return new yn(this,i,this.prepared.name,f,this.element,m,_)}},{key:"_fireEvent",value:function(i){var f;(f=this.interactable)==null||f.fire(i),(!this.prevEvent||i.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=i)}},{key:"_doPhase",value:function(i){var f=i.event,m=i.phase,_=i.preEnd,O=i.type,G=this.rect;if(G&&m==="move"&&(oe(this.edges,G,this.coords.delta[this.interactable.options.deltaSource]),G.width=G.right-G.left,G.height=G.bottom-G.top),this._scopeFire("interactions:before-action-".concat(m),i)===!1)return!1;var ee=i.iEvent=this._createPreparedEvent(f,m,_,O);return this._scopeFire("interactions:action-".concat(m),i),m==="start"&&(this.prevEvent=ee),this._fireEvent(ee),this._scopeFire("interactions:after-action-".concat(m),i),!0}},{key:"_now",value:function(){return Date.now()}}]),o}();function lr(o){Il(o.interaction)}function Il(o){if(!function(f){return!(!f.offset.pending.x&&!f.offset.pending.y)}(o))return!1;var i=o.offset.pending;return cl(o.coords.cur,i),cl(o.coords.delta,i),oe(o.edges,o.rect,i),i.x=0,i.y=0,!0}function Ar(o){var i=o.x,f=o.y;this.offset.pending.x+=i,this.offset.pending.y+=f,this.offset.total.x+=i,this.offset.total.y+=f}function cl(o,i){var f=o.page,m=o.client,_=i.x,O=i.y;f.x+=_,f.y+=O,m.x+=_,m.y+=O}_n.offsetBy="";var cr={id:"offset",before:["modifiers","pointer-events","actions","inertia"],install:function(o){o.Interaction.prototype.offsetBy=Ar},listeners:{"interactions:new":function(o){o.interaction.offset={total:{x:0,y:0},pending:{x:0,y:0}}},"interactions:update-pointer":function(o){return function(i){i.pointerIsDown&&(cl(i.coords.cur,i.offset.total),i.offset.pending.x=0,i.offset.pending.y=0)}(o.interaction)},"interactions:before-action-start":lr,"interactions:before-action-move":lr,"interactions:before-action-end":function(o){var i=o.interaction;if(Il(i))return i.move({offset:!0}),i.end(),!1},"interactions:stop":function(o){var i=o.interaction;i.offset.total.x=0,i.offset.total.y=0,i.offset.pending.x=0,i.offset.pending.y=0}}},Vl=cr,_r=function(){function o(i){s(this,o),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=i}return d(o,[{key:"start",value:function(i){var f=this.interaction,m=Gl(f);if(!m||!m.enabled)return!1;var _=f.coords.velocity.client,O=Ja(_.x,_.y),G=this.modification||(this.modification=new Pr(f));if(G.copyFrom(f.modification),this.t0=f._now(),this.allowResume=m.allowResume,this.v0=O,this.currentOffset={x:0,y:0},this.startCoords=f.coords.cur.page,this.modifierArg=G.fillArg({pageCoords:this.startCoords,preEnd:!0,phase:"inertiastart"}),this.t0-f.coords.cur.timeStamp<50&&O>m.minSpeed&&O>m.endSpeed)this.startInertia();else{if(G.result=G.setAll(this.modifierArg),!G.result.changed)return!1;this.startSmoothEnd()}return f.modification.result.rect=null,f.offsetBy(this.targetOffset),f._doPhase({interaction:f,event:i,phase:"inertiastart"}),f.offsetBy({x:-this.targetOffset.x,y:-this.targetOffset.y}),f.modification.result.rect=null,this.active=!0,f.simulation=this,!0}},{key:"startInertia",value:function(){var i=this,f=this.interaction.coords.velocity.client,m=Gl(this.interaction),_=m.resistance,O=-Math.log(m.endSpeed/this.v0)/_;this.targetOffset={x:(f.x-O)/_,y:(f.y-O)/_},this.te=O,this.lambda_v0=_/this.v0,this.one_ve_v0=1-m.endSpeed/this.v0;var G=this.modification,ee=this.modifierArg;ee.pageCoords={x:this.startCoords.x+this.targetOffset.x,y:this.startCoords.y+this.targetOffset.y},G.result=G.setAll(ee),G.result.changed&&(this.isModified=!0,this.modifiedOffset={x:this.targetOffset.x+G.result.delta.x,y:this.targetOffset.y+G.result.delta.y}),this.onNextFrame(function(){return i.inertiaTick()})}},{key:"startSmoothEnd",value:function(){var i=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 i.smoothEndTick()})}},{key:"onNextFrame",value:function(i){var f=this;this.timeout=La.request(function(){f.active&&i()})}},{key:"inertiaTick",value:function(){var i,f,m,_,O,G,ee,ke=this,He=this.interaction,Ce=Gl(He).resistance,aa=(He._now()-this.t0)/1e3;if(aa<this.te){var Ba,Xa=1-(Math.exp(-Ce*aa)-this.lambda_v0)/this.one_ve_v0;this.isModified?(i=0,f=0,m=this.targetOffset.x,_=this.targetOffset.y,O=this.modifiedOffset.x,G=this.modifiedOffset.y,Ba={x:Or(ee=Xa,i,m,O),y:Or(ee,f,_,G)}):Ba={x:this.targetOffset.x*Xa,y:this.targetOffset.y*Xa};var Ka={x:Ba.x-this.currentOffset.x,y:Ba.y-this.currentOffset.y};this.currentOffset.x+=Ka.x,this.currentOffset.y+=Ka.y,He.offsetBy(Ka),He.move(),this.onNextFrame(function(){return ke.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 i=this,f=this.interaction,m=f._now()-this.t0,_=Gl(f).smoothEndDuration;if(m<_){var O={x:gn(m,0,this.targetOffset.x,_),y:gn(m,0,this.targetOffset.y,_)},G={x:O.x-this.currentOffset.x,y:O.y-this.currentOffset.y};this.currentOffset.x+=G.x,this.currentOffset.y+=G.y,f.offsetBy(G),f.move({skipModifiers:this.modifierCount}),this.onNextFrame(function(){return i.smoothEndTick()})}else f.offsetBy({x:this.targetOffset.x-this.currentOffset.x,y:this.targetOffset.y-this.currentOffset.y}),this.end()}},{key:"resume",value:function(i){var f=i.pointer,m=i.event,_=i.eventTarget,O=this.interaction;O.offsetBy({x:-this.currentOffset.x,y:-this.currentOffset.y}),O.updatePointer(f,m,_,!0),O._doPhase({interaction:O,event:m,phase:"resume"}),Q(O.coords.prev,O.coords.cur),this.stop()}},{key:"end",value:function(){this.interaction.move(),this.interaction.end(),this.stop()}},{key:"stop",value:function(){this.active=this.smoothEnd=!1,this.interaction.simulation=null,La.cancel(this.timeout)}}]),o}();function Gl(o){var i=o.interactable,f=o.prepared;return i&&i.options&&f.name&&i.options[f.name].inertia}var hr={id:"inertia",before:["modifiers","actions"],install:function(o){var i=o.defaults;o.usePlugin(Vl),o.usePlugin(Dr),o.actions.phases.inertiastart=!0,o.actions.phases.resume=!0,i.perAction.inertia={enabled:!1,resistance:10,minSpeed:100,endSpeed:10,allowResume:!0,smoothEndDuration:300}},listeners:{"interactions:new":function(o){var i=o.interaction;i.inertia=new _r(i)},"interactions:before-action-end":function(o){var i=o.interaction,f=o.event;return(!i._interacting||i.simulation||!i.inertia.start(f))&&null},"interactions:down":function(o){var i=o.interaction,f=o.eventTarget,m=i.inertia;if(m.active)for(var _=f;w.element(_);){if(_===i.element){m.resume(o);break}_=Fe(_)}},"interactions:stop":function(o){var i=o.interaction.inertia;i.active&&i.stop()},"interactions:before-action-resume":function(o){var i=o.interaction.modification;i.stop(o),i.start(o,o.interaction.coords.cur.page),i.applyToInteraction(o)},"interactions:before-action-inertiastart":function(o){return o.interaction.modification.setAndApply(o)},"interactions:action-resume":Er,"interactions:action-inertiastart":Er,"interactions:after-action-inertiastart":function(o){return o.interaction.modification.restoreInteractionCoords(o)},"interactions:after-action-resume":function(o){return o.interaction.modification.restoreInteractionCoords(o)}}};function Or(o,i,f,m){var _=1-o;return _*_*i+2*_*o*f+o*o*m}function gn(o,i,f,m){return-f*(o/=m)*(o-2)+i}var Nn=hr;function bn(o,i){for(var f=0;f<i.length;f++){var m=i[f];if(o.immediatePropagationStopped)break;m(o)}}var Un=function(){function o(i){s(this,o),this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=le({},i||{})}return d(o,[{key:"fire",value:function(i){var f,m=this.global;(f=this.types[i.type])&&bn(i,f),!i.propagationStopped&&m&&(f=m[i.type])&&bn(i,f)}},{key:"on",value:function(i,f){var m=Ue(i,f);for(i in m)this.types[i]=Z(this.types[i]||[],m[i])}},{key:"off",value:function(i,f){var m=Ue(i,f);for(i in m){var _=this.types[i];if(_&&_.length)for(var O=0,G=m[i];O<G.length;O++){var ee=G[O],ke=_.indexOf(ee);ke!==-1&&_.splice(ke,1)}}}},{key:"getRect",value:function(i){return null}}]),o}(),Ln=function(){function o(i){s(this,o),this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=i,H(this,i)}return d(o,[{key:"preventOriginalDefault",value:function(){this.originalEvent.preventDefault()}},{key:"stopPropagation",value:function(){this.originalEvent.stopPropagation()}},{key:"stopImmediatePropagation",value:function(){this.originalEvent.stopImmediatePropagation()}}]),o}();function kn(o){return w.object(o)?{capture:!!o.capture,passive:!!o.passive}:{capture:!!o,passive:!1}}function Tn(o,i){return o===i||(typeof o=="boolean"?!!i.capture===o&&!i.passive:!!o.capture==!!i.capture&&!!o.passive==!!i.passive)}var Rn={id:"events",install:function(o){var i,f=[],m={},_=[],O={add:G,remove:ee,addDelegate:function(Ce,aa,Ba,Xa,Ka){var al=kn(Ka);if(!m[Ba]){m[Ba]=[];for(var bl=0;bl<_.length;bl++){var vl=_[bl];G(vl,Ba,ke),G(vl,Ba,He,!0)}}var El=m[Ba],Hl=Je(El,function(Cl){return Cl.selector===Ce&&Cl.context===aa});Hl||(Hl={selector:Ce,context:aa,listeners:[]},El.push(Hl)),Hl.listeners.push({func:Xa,options:al})},removeDelegate:function(Ce,aa,Ba,Xa,Ka){var al,bl=kn(Ka),vl=m[Ba],El=!1;if(vl)for(al=vl.length-1;al>=0;al--){var Hl=vl[al];if(Hl.selector===Ce&&Hl.context===aa){for(var Cl=Hl.listeners,zl=Cl.length-1;zl>=0;zl--){var Al=Cl[zl];if(Al.func===Xa&&Tn(Al.options,bl)){Cl.splice(zl,1),Cl.length||(vl.splice(al,1),ee(aa,Ba,ke),ee(aa,Ba,He,!0)),El=!0;break}}if(El)break}}},delegateListener:ke,delegateUseCapture:He,delegatedEvents:m,documents:_,targets:f,supportsOptions:!1,supportsPassive:!1};function G(Ce,aa,Ba,Xa){if(Ce.addEventListener){var Ka=kn(Xa),al=Je(f,function(bl){return bl.eventTarget===Ce});al||(al={eventTarget:Ce,events:{}},f.push(al)),al.events[aa]||(al.events[aa]=[]),Je(al.events[aa],function(bl){return bl.func===Ba&&Tn(bl.options,Ka)})||(Ce.addEventListener(aa,Ba,O.supportsOptions?Ka:Ka.capture),al.events[aa].push({func:Ba,options:Ka}))}}function ee(Ce,aa,Ba,Xa){if(Ce.addEventListener&&Ce.removeEventListener){var Ka=Be(f,function(Hr){return Hr.eventTarget===Ce}),al=f[Ka];if(al&&al.events)if(aa!=="all"){var bl=!1,vl=al.events[aa];if(vl){if(Ba==="all"){for(var El=vl.length-1;El>=0;El--){var Hl=vl[El];ee(Ce,aa,Hl.func,Hl.options)}return}for(var Cl=kn(Xa),zl=0;zl<vl.length;zl++){var Al=vl[zl];if(Al.func===Ba&&Tn(Al.options,Cl)){Ce.removeEventListener(aa,Ba,O.supportsOptions?Cl:Cl.capture),vl.splice(zl,1),vl.length===0&&(delete al.events[aa],bl=!0);break}}}bl&&!Object.keys(al.events).length&&f.splice(Ka,1)}else for(aa in al.events)al.events.hasOwnProperty(aa)&&ee(Ce,aa,"all")}}function ke(Ce,aa){for(var Ba=kn(aa),Xa=new Ln(Ce),Ka=m[Ce.type],al=ne(Ce)[0],bl=al;w.element(bl);){for(var vl=0;vl<Ka.length;vl++){var El=Ka[vl],Hl=El.selector,Cl=El.context;if(ye(bl,Hl)&&de(Cl,al)&&de(Cl,bl)){var zl=El.listeners;Xa.currentTarget=bl;for(var Al=0;Al<zl.length;Al++){var Hr=zl[Al];Tn(Hr.options,Ba)&&Hr.func(Xa)}}}bl=Fe(bl)}}function He(Ce){return ke(Ce,!0)}return(i=o.document)==null||i.createElement("div").addEventListener("test",null,{get capture(){return O.supportsOptions=!0},get passive(){return O.supportsPassive=!0}}),o.events=O,O}},Qr={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search:function(o){for(var i=0,f=Qr.methodOrder;i<f.length;i++){var m=f[i],_=Qr[m](o);if(_)return _}return null},simulationResume:function(o){var i=o.pointerType,f=o.eventType,m=o.eventTarget,_=o.scope;if(!/down|start/i.test(f))return null;for(var O=0,G=_.interactions.list;O<G.length;O++){var ee=G[O],ke=m;if(ee.simulation&&ee.simulation.allowResume&&ee.pointerType===i)for(;ke;){if(ke===ee.element)return ee;ke=Fe(ke)}}return null},mouseOrPen:function(o){var i,f=o.pointerId,m=o.pointerType,_=o.eventType,O=o.scope;if(m!=="mouse"&&m!=="pen")return null;for(var G=0,ee=O.interactions.list;G<ee.length;G++){var ke=ee[G];if(ke.pointerType===m){if(ke.simulation&&!An(ke,f))continue;if(ke.interacting())return ke;i||(i=ke)}}if(i)return i;for(var He=0,Ce=O.interactions.list;He<Ce.length;He++){var aa=Ce[He];if(!(aa.pointerType!==m||/down/i.test(_)&&aa.simulation))return aa}return null},hasPointer:function(o){for(var i=o.pointerId,f=0,m=o.scope.interactions.list;f<m.length;f++){var _=m[f];if(An(_,i))return _}return null},idle:function(o){for(var i=o.pointerType,f=0,m=o.scope.interactions.list;f<m.length;f++){var _=m[f];if(_.pointers.length===1){var O=_.interactable;if(O&&(!O.options.gesture||!O.options.gesture.enabled))continue}else if(_.pointers.length>=2)continue;if(!_.interacting()&&i===_.pointerType)return _}return null}};function An(o,i){return o.pointers.some(function(f){return f.id===i})}var qn=Qr,Lr=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function Wn(o,i){return function(f){var m=i.interactions.list,_=Va(f),O=ne(f),G=O[0],ee=O[1],ke=[];if(/^touch/.test(f.type)){i.prevTouchTime=i.now();for(var He=0,Ce=f.changedTouches;He<Ce.length;He++){var aa=Ce[He],Ba={pointer:aa,pointerId:ce(aa),pointerType:_,eventType:f.type,eventTarget:G,curEventTarget:ee,scope:i},Xa=fn(Ba);ke.push([Ba.pointer,Ba.eventTarget,Ba.curEventTarget,Xa])}}else{var Ka=!1;if(!ae.supportsPointerEvent&&/mouse/.test(f.type)){for(var al=0;al<m.length&&!Ka;al++)Ka=m[al].pointerType!=="mouse"&&m[al].pointerIsDown;Ka=Ka||i.now()-i.prevTouchTime<500||f.timeStamp===0}if(!Ka){var bl={pointer:f,pointerId:ce(f),pointerType:_,eventType:f.type,curEventTarget:ee,eventTarget:G,scope:i},vl=fn(bl);ke.push([bl.pointer,bl.eventTarget,bl.curEventTarget,vl])}}for(var El=0;El<ke.length;El++){var Hl=ke[El],Cl=Hl[0],zl=Hl[1],Al=Hl[2];Hl[3][o](Cl,f,zl,Al)}}}function fn(o){var i=o.pointerType,f=o.scope,m={interaction:qn.search(o),searchDetails:o};return f.fire("interactions:find",m),m.interaction||f.interactions.new({pointerType:i})}function Ni(o,i){var f=o.doc,m=o.scope,_=o.options,O=m.interactions.docEvents,G=m.events,ee=G[i];for(var ke in m.browser.isIOS&&!_.events&&(_.events={passive:!1}),G.delegatedEvents)ee(f,ke,G.delegateListener),ee(f,ke,G.delegateUseCapture,!0);for(var He=_&&_.events,Ce=0;Ce<O.length;Ce++){var aa=O[Ce];ee(f,aa.type,aa.listener,He)}}var Lo={id:"core/interactions",install:function(o){for(var i={},f=0;f<Lr.length;f++){var m=Lr[f];i[m]=Wn(m,o)}var _,O=ae.pEventTypes;function G(){for(var ee=0,ke=o.interactions.list;ee<ke.length;ee++){var He=ke[ee];if(He.pointerIsDown&&He.pointerType==="touch"&&!He._interacting)for(var Ce=function(){var Xa=Ba[aa];o.documents.some(function(Ka){return de(Ka.doc,Xa.downTarget)})||He.removePointer(Xa.pointer,Xa.event)},aa=0,Ba=He.pointers;aa<Ba.length;aa++)Ce()}}(_=V.PointerEvent?[{type:O.down,listener:G},{type:O.down,listener:i.pointerDown},{type:O.move,listener:i.pointerMove},{type:O.up,listener:i.pointerUp},{type:O.cancel,listener:i.pointerUp}]:[{type:"mousedown",listener:i.pointerDown},{type:"mousemove",listener:i.pointerMove},{type:"mouseup",listener:i.pointerUp},{type:"touchstart",listener:G},{type:"touchstart",listener:i.pointerDown},{type:"touchmove",listener:i.pointerMove},{type:"touchend",listener:i.pointerUp},{type:"touchcancel",listener:i.pointerUp}]).push({type:"blur",listener:function(ee){for(var ke=0,He=o.interactions.list;ke<He.length;ke++)He[ke].documentBlur(ee)}}),o.prevTouchTime=0,o.Interaction=function(ee){y(He,ee);var ke=M(He);function He(){return s(this,He),ke.apply(this,arguments)}return d(He,[{key:"pointerMoveTolerance",get:function(){return o.interactions.pointerMoveTolerance},set:function(Ce){o.interactions.pointerMoveTolerance=Ce}},{key:"_now",value:function(){return o.now()}}]),He}(pn),o.interactions={list:[],new:function(ee){ee.scopeFire=function(He,Ce){return o.fire(He,Ce)};var ke=new o.Interaction(ee);return o.interactions.list.push(ke),ke},listeners:i,docEvents:_,pointerMoveTolerance:1},o.usePlugin(ar)},listeners:{"scope:add-document":function(o){return Ni(o,"add")},"scope:remove-document":function(o){return Ni(o,"remove")},"interactable:unset":function(o,i){for(var f=o.interactable,m=i.interactions.list.length-1;m>=0;m--){var _=i.interactions.list[m];_.interactable===f&&(_.stop(),i.fire("interactions:destroy",{interaction:_}),_.destroy(),i.interactions.list.length>2&&i.interactions.list.splice(m,1))}}},onDocSignal:Ni,doOnInteractions:Wn,methodNames:Lr},Ro=Lo,Sn=function(o){return o[o.On=0]="On",o[o.Off=1]="Off",o}(Sn||{}),$o=function(){function o(i,f,m,_){s(this,o),this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new Un,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=f.actions,this.target=i,this._context=f.context||m,this._win=x(Da(i)?this._context:i),this._doc=this._win.document,this._scopeEvents=_,this.set(f)}return d(o,[{key:"_defaults",get:function(){return{base:{},perAction:{},actions:{}}}},{key:"setOnEvents",value:function(i,f){return w.func(f.onstart)&&this.on("".concat(i,"start"),f.onstart),w.func(f.onmove)&&this.on("".concat(i,"move"),f.onmove),w.func(f.onend)&&this.on("".concat(i,"end"),f.onend),w.func(f.oninertiastart)&&this.on("".concat(i,"inertiastart"),f.oninertiastart),this}},{key:"updatePerActionListeners",value:function(i,f,m){var _,O=this,G=(_=this._actions.map[i])==null?void 0:_.filterEventType,ee=function(ke){return(G==null||G(ke))&&Fr(ke,O._actions)};(w.array(f)||w.object(f))&&this._onOff(Sn.Off,i,f,void 0,ee),(w.array(m)||w.object(m))&&this._onOff(Sn.On,i,m,void 0,ee)}},{key:"setPerAction",value:function(i,f){var m=this._defaults;for(var _ in f){var O=_,G=this.options[i],ee=f[O];O==="listeners"&&this.updatePerActionListeners(i,G.listeners,ee),w.array(ee)?G[O]=q(ee):w.plainObject(ee)?(G[O]=le(G[O]||{},Nr(ee)),w.object(m.perAction[O])&&"enabled"in m.perAction[O]&&(G[O].enabled=ee.enabled!==!1)):w.bool(ee)&&w.object(m.perAction[O])?G[O].enabled=ee:G[O]=ee}}},{key:"getRect",value:function(i){return i=i||(w.element(this.target)?this.target:null),w.string(this.target)&&(i=i||this._context.querySelector(this.target)),Pe(i)}},{key:"rectChecker",value:function(i){var f=this;return w.func(i)?(this.getRect=function(m){var _=le({},i.apply(f,m));return"width"in _||(_.width=_.right-_.left,_.height=_.bottom-_.top),_},this):i===null?(delete this.getRect,this):this.getRect}},{key:"_backCompatOption",value:function(i,f){if(Da(f)||w.object(f)){for(var m in this.options[i]=f,this._actions.map)this.options[m][i]=f;return this}return this.options[i]}},{key:"origin",value:function(i){return this._backCompatOption("origin",i)}},{key:"deltaSource",value:function(i){return i==="page"||i==="client"?(this.options.deltaSource=i,this):this.options.deltaSource}},{key:"getAllElements",value:function(){var i=this.target;return w.string(i)?Array.from(this._context.querySelectorAll(i)):w.func(i)&&i.getAllElements?i.getAllElements():w.element(i)?[i]:[]}},{key:"context",value:function(){return this._context}},{key:"inContext",value:function(i){return this._context===i.ownerDocument||de(this._context,i)}},{key:"testIgnoreAllow",value:function(i,f,m){return!this.testIgnore(i.ignoreFrom,f,m)&&this.testAllow(i.allowFrom,f,m)}},{key:"testAllow",value:function(i,f,m){return!i||!!w.element(m)&&(w.string(i)?U(m,i,f):!!w.element(i)&&de(i,m))}},{key:"testIgnore",value:function(i,f,m){return!(!i||!w.element(m))&&(w.string(i)?U(m,i,f):!!w.element(i)&&de(i,m))}},{key:"fire",value:function(i){return this.events.fire(i),this}},{key:"_onOff",value:function(i,f,m,_,O){w.object(f)&&!w.array(f)&&(_=m,m=null);var G=Ue(f,m,O);for(var ee in G){ee==="wheel"&&(ee=ae.wheelEvent);for(var ke=0,He=G[ee];ke<He.length;ke++){var Ce=He[ke];Fr(ee,this._actions)?this.events[i===Sn.On?"on":"off"](ee,Ce):w.string(this.target)?this._scopeEvents[i===Sn.On?"addDelegate":"removeDelegate"](this.target,this._context,ee,Ce,_):this._scopeEvents[i===Sn.On?"add":"remove"](this.target,ee,Ce,_)}}return this}},{key:"on",value:function(i,f,m){return this._onOff(Sn.On,i,f,m)}},{key:"off",value:function(i,f,m){return this._onOff(Sn.Off,i,f,m)}},{key:"set",value:function(i){var f=this._defaults;for(var m in w.object(i)||(i={}),this.options=Nr(f.base),this._actions.methodDict){var _=m,O=this._actions.methodDict[_];this.options[_]={},this.setPerAction(_,le(le({},f.perAction),f.actions[_])),this[O](i[_])}for(var G in i)G!=="getRect"?w.func(this[G])&&this[G](i[G]):this.rectChecker(i.getRect);return this}},{key:"unset",value:function(){if(w.string(this.target))for(var i in this._scopeEvents.delegatedEvents)for(var f=this._scopeEvents.delegatedEvents[i],m=f.length-1;m>=0;m--){var _=f[m],O=_.selector,G=_.context,ee=_.listeners;O===this.target&&G===this._context&&f.splice(m,1);for(var ke=ee.length-1;ke>=0;ke--)this._scopeEvents.removeDelegate(this.target,this._context,i,ee[ke][0],ee[ke][1])}else this._scopeEvents.remove(this.target,"all")}}]),o}(),Vo=function(){function o(i){var f=this;s(this,o),this.list=[],this.selectorMap={},this.scope=void 0,this.scope=i,i.addListeners({"interactable:unset":function(m){var _=m.interactable,O=_.target,G=w.string(O)?f.selectorMap[O]:O[f.scope.id],ee=Be(G,function(ke){return ke===_});G.splice(ee,1)}})}return d(o,[{key:"new",value:function(i,f){f=le(f||{},{actions:this.scope.actions});var m=new this.scope.Interactable(i,f,this.scope.document,this.scope.events);return this.scope.addDocument(m._doc),this.list.push(m),w.string(i)?(this.selectorMap[i]||(this.selectorMap[i]=[]),this.selectorMap[i].push(m)):(m.target[this.scope.id]||Object.defineProperty(i,this.scope.id,{value:[],configurable:!0}),i[this.scope.id].push(m)),this.scope.fire("interactable:new",{target:i,options:f,interactable:m,win:this.scope._win}),m}},{key:"getExisting",value:function(i,f){var m=f&&f.context||this.scope.document,_=w.string(i),O=_?this.selectorMap[i]:i[this.scope.id];if(O)return Je(O,function(G){return G._context===m&&(_||G.inContext(i))})}},{key:"forEachMatch",value:function(i,f){for(var m=0,_=this.list;m<_.length;m++){var O=_[m],G=void 0;if((w.string(O.target)?w.element(i)&&ye(i,O.target):i===O.target)&&O.inContext(i)&&(G=f(O)),G!==void 0)return G}}}]),o}(),Fo=function(){function o(){var i=this;s(this,o),this.id="__interact_scope_".concat(Math.floor(100*Math.random())),this.isInitialized=!1,this.listenerMaps=[],this.browser=ae,this.defaults=Nr(ur),this.Eventable=Un,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=function(m){var _=function O(G,ee){var ke=m.interactables.getExisting(G,ee);return ke||((ke=m.interactables.new(G,ee)).events.global=O.globalEvents),ke};return _.getPointerAverage=We,_.getTouchBBox=Ta,_.getTouchDistance=Ca,_.getTouchAngle=Qe,_.getElementRect=Pe,_.getElementClientRect=Le,_.matchesSelector=ye,_.closest=De,_.globalEvents={},_.version="1.10.27",_.scope=m,_.use=function(O,G){return this.scope.usePlugin(O,G),this},_.isSet=function(O,G){return!!this.scope.interactables.get(O,G&&G.context)},_.on=ha(function(O,G,ee){if(w.string(O)&&O.search(" ")!==-1&&(O=O.trim().split(/ +/)),w.array(O)){for(var ke=0,He=O;ke<He.length;ke++){var Ce=He[ke];this.on(Ce,G,ee)}return this}if(w.object(O)){for(var aa in O)this.on(aa,O[aa],G);return this}return Fr(O,this.scope.actions)?this.globalEvents[O]?this.globalEvents[O].push(G):this.globalEvents[O]=[G]:this.scope.events.add(this.scope.document,O,G,{options:ee}),this},"The interact.on() method is being deprecated"),_.off=ha(function(O,G,ee){if(w.string(O)&&O.search(" ")!==-1&&(O=O.trim().split(/ +/)),w.array(O)){for(var ke=0,He=O;ke<He.length;ke++){var Ce=He[ke];this.off(Ce,G,ee)}return this}if(w.object(O)){for(var aa in O)this.off(aa,O[aa],G);return this}var Ba;return Fr(O,this.scope.actions)?O in this.globalEvents&&(Ba=this.globalEvents[O].indexOf(G))!==-1&&this.globalEvents[O].splice(Ba,1):this.scope.events.remove(this.scope.document,O,G,ee),this},"The interact.off() method is being deprecated"),_.debug=function(){return this.scope},_.supportsTouch=function(){return ae.supportsTouch},_.supportsPointerEvent=function(){return ae.supportsPointerEvent},_.stop=function(){for(var O=0,G=this.scope.interactions.list;O<G.length;O++)G[O].stop();return this},_.pointerMoveTolerance=function(O){return w.number(O)?(this.scope.interactions.pointerMoveTolerance=O,this):this.scope.interactions.pointerMoveTolerance},_.addDocument=function(O,G){this.scope.addDocument(O,G)},_.removeDocument=function(O){this.scope.removeDocument(O)},_}(this),this.InteractEvent=yn,this.Interactable=void 0,this.interactables=new Vo(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=function(m){return i.removeDocument(m.target)};var f=this;this.Interactable=function(m){y(O,m);var _=M(O);function O(){return s(this,O),_.apply(this,arguments)}return d(O,[{key:"_defaults",get:function(){return f.defaults}},{key:"set",value:function(G){return S(g(O.prototype),"set",this).call(this,G),f.fire("interactable:set",{options:G,interactable:this}),this}},{key:"unset",value:function(){S(g(O.prototype),"unset",this).call(this);var G=f.interactables.list.indexOf(this);G<0||(f.interactables.list.splice(G,1),f.fire("interactable:unset",{interactable:this}))}}]),O}($o)}return d(o,[{key:"addListeners",value:function(i,f){this.listenerMaps.push({id:f,map:i})}},{key:"fire",value:function(i,f){for(var m=0,_=this.listenerMaps;m<_.length;m++){var O=_[m].map[i];if(O&&O(f,this,i)===!1)return!1}}},{key:"init",value:function(i){return this.isInitialized?this:function(f,m){return f.isInitialized=!0,w.window(m)&&E(m),V.init(m),ae.init(m),La.init(m),f.window=m,f.document=m.document,f.usePlugin(Ro),f.usePlugin(Rn),f}(this,i)}},{key:"pluginIsInstalled",value:function(i){var f=i.id;return f?!!this._plugins.map[f]:this._plugins.list.indexOf(i)!==-1}},{key:"usePlugin",value:function(i,f){if(!this.isInitialized)return this;if(this.pluginIsInstalled(i))return this;if(i.id&&(this._plugins.map[i.id]=i),this._plugins.list.push(i),i.install&&i.install(this,f),i.listeners&&i.before){for(var m=0,_=this.listenerMaps.length,O=i.before.reduce(function(ee,ke){return ee[ke]=!0,ee[Ti(ke)]=!0,ee},{});m<_;m++){var G=this.listenerMaps[m].id;if(G&&(O[G]||O[Ti(G)]))break}this.listenerMaps.splice(m,0,{id:i.id,map:i.listeners})}else i.listeners&&this.listenerMaps.push({id:i.id,map:i.listeners});return this}},{key:"addDocument",value:function(i,f){if(this.getDocIndex(i)!==-1)return!1;var m=x(i);f=f?le({},f):{},this.documents.push({doc:i,options:f}),this.events.documents.push(i),i!==this.document&&this.events.add(m,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:i,window:m,scope:this,options:f})}},{key:"removeDocument",value:function(i){var f=this.getDocIndex(i),m=x(i),_=this.documents[f].options;this.events.remove(m,"unload",this.onWindowUnload),this.documents.splice(f,1),this.events.documents.splice(f,1),this.fire("scope:remove-document",{doc:i,window:m,scope:this,options:_})}},{key:"getDocIndex",value:function(i){for(var f=0;f<this.documents.length;f++)if(this.documents[f].doc===i)return f;return-1}},{key:"getDocOptions",value:function(i){var f=this.getDocIndex(i);return f===-1?null:this.documents[f].options}},{key:"now",value:function(){return(this.window.Date||Date).now()}}]),o}();function Ti(o){return o&&o.replace(/\/.*$/,"")}var Ji=new Fo,jr=Ji.interactStatic,Po=typeof globalThis<"u"?globalThis:window;Ji.init(Po);var jo=Object.freeze({__proto__:null,edgeTarget:function(){},elements:function(){},grid:function(o){var i=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(function(m){var _=m[0],O=m[1];return _ in o||O in o}),f=function(m,_){for(var O=o.range,G=o.limits,ee=G===void 0?{left:-1/0,right:1/0,top:-1/0,bottom:1/0}:G,ke=o.offset,He=ke===void 0?{x:0,y:0}:ke,Ce={range:O,grid:o,x:null,y:null},aa=0;aa<i.length;aa++){var Ba=i[aa],Xa=Ba[0],Ka=Ba[1],al=Math.round((m-He.x)/o[Xa]),bl=Math.round((_-He.y)/o[Ka]);Ce[Xa]=Math.max(ee.left,Math.min(ee.right,al*o[Xa]+He.x)),Ce[Ka]=Math.max(ee.top,Math.min(ee.bottom,bl*o[Ka]+He.y))}return Ce};return f.grid=o,f.coordFields=i,f}}),Ai={id:"snappers",install:function(o){var i=o.interactStatic;i.snappers=le(i.snappers||{},jo),i.createSnapGrid=i.snappers.grid}},Ho=Ai,zi={start:function(o){var i=o.state,f=o.rect,m=o.edges,_=o.pageCoords,O=i.options,G=O.ratio,ee=O.enabled,ke=i.options,He=ke.equalDelta,Ce=ke.modifiers;G==="preserve"&&(G=f.width/f.height),i.startCoords=le({},_),i.startRect=le({},f),i.ratio=G,i.equalDelta=He;var aa=i.linkedEdges={top:m.top||m.left&&!m.bottom,left:m.left||m.top&&!m.right,bottom:m.bottom||m.right&&!m.top,right:m.right||m.bottom&&!m.left};if(i.xIsPrimaryAxis=!(!m.left&&!m.right),i.equalDelta){var Ba=(aa.left?1:-1)*(aa.top?1:-1);i.edgeSign={x:Ba,y:Ba}}else i.edgeSign={x:aa.left?-1:1,y:aa.top?-1:1};if(ee!==!1&&le(m,aa),Ce!=null&&Ce.length){var Xa=new Pr(o.interaction);Xa.copyFrom(o.interaction.modification),Xa.prepareStates(Ce),i.subModification=Xa,Xa.startAll(n({},o))}},set:function(o){var i=o.state,f=o.rect,m=o.coords,_=i.linkedEdges,O=le({},m),G=i.equalDelta?Xi:Zi;if(le(o.edges,_),G(i,i.xIsPrimaryAxis,m,f),!i.subModification)return null;var ee=le({},f);oe(_,ee,{x:m.x-O.x,y:m.y-O.y});var ke=i.subModification.setAll(n(n({},o),{},{rect:ee,edges:_,pageCoords:m,prevCoords:m,prevRect:ee})),He=ke.delta;return ke.changed&&(G(i,Math.abs(He.x)>Math.abs(He.y),ke.coords,ke.rect),le(m,ke.coords)),ke.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function Xi(o,i,f){var m=o.startCoords,_=o.edgeSign;i?f.y=m.y+(f.x-m.x)*_.y:f.x=m.x+(f.y-m.y)*_.x}function Zi(o,i,f,m){var _=o.startRect,O=o.startCoords,G=o.ratio,ee=o.edgeSign;if(i){var ke=m.width/G;f.y=O.y+(ke-_.height)*ee.y}else{var He=m.height*G;f.x=O.x+(He-_.width)*ee.x}}var Uo=Sr(zi,"aspectRatio"),Qi=function(){};Qi._defaults={};var si=Qi;function nn(o,i,f){return w.func(o)?te(o,i.interactable,i.element,[f.x,f.y,i]):te(o,i.interactable,i.element)}var Kn={start:function(o){var i=o.rect,f=o.startOffset,m=o.state,_=o.interaction,O=o.pageCoords,G=m.options,ee=G.elementRect,ke=le({left:0,top:0,right:0,bottom:0},G.offset||{});if(i&&ee){var He=nn(G.restriction,_,O);if(He){var Ce=He.right-He.left-i.width,aa=He.bottom-He.top-i.height;Ce<0&&(ke.left+=Ce,ke.right+=Ce),aa<0&&(ke.top+=aa,ke.bottom+=aa)}ke.left+=f.left-i.width*ee.left,ke.top+=f.top-i.height*ee.top,ke.right+=f.right-i.width*(1-ee.right),ke.bottom+=f.bottom-i.height*(1-ee.bottom)}m.offset=ke},set:function(o){var i=o.coords,f=o.interaction,m=o.state,_=m.options,O=m.offset,G=nn(_.restriction,f,i);if(G){var ee=function(ke){return!ke||"left"in ke&&"top"in ke||((ke=le({},ke)).left=ke.x||0,ke.top=ke.y||0,ke.right=ke.right||ke.left+ke.width,ke.bottom=ke.bottom||ke.top+ke.height),ke}(G);i.x=Math.max(Math.min(ee.right-O.right,i.x),ee.left+O.left),i.y=Math.max(Math.min(ee.bottom-O.bottom,i.y),ee.top+O.top)}},defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}},Mi=Sr(Kn,"restrict"),eo={top:1/0,left:1/0,bottom:-1/0,right:-1/0},ao={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function lo(o,i){for(var f=0,m=["top","left","bottom","right"];f<m.length;f++){var _=m[f];_ in o||(o[_]=i[_])}return o}var Gn={noInner:eo,noOuter:ao,start:function(o){var i,f=o.interaction,m=o.startOffset,_=o.state,O=_.options;O&&(i=ca(nn(O.offset,f,f.coords.start.page))),i=i||{x:0,y:0},_.offset={top:i.y+m.top,left:i.x+m.left,bottom:i.y-m.bottom,right:i.x-m.right}},set:function(o){var i=o.coords,f=o.edges,m=o.interaction,_=o.state,O=_.offset,G=_.options;if(f){var ee=le({},i),ke=nn(G.inner,m,ee)||{},He=nn(G.outer,m,ee)||{};lo(ke,eo),lo(He,ao),f.top?i.y=Math.min(Math.max(He.top+O.top,ee.y),ke.top+O.top):f.bottom&&(i.y=Math.max(Math.min(He.bottom+O.bottom,ee.y),ke.bottom+O.bottom)),f.left?i.x=Math.min(Math.max(He.left+O.left,ee.x),ke.left+O.left):f.right&&(i.x=Math.max(Math.min(He.right+O.right,ee.x),ke.right+O.right))}},defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}},ro=Sr(Gn,"restrictEdges"),Yn=le({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(o){}},Kn.defaults),no=Sr({start:Kn.start,set:Kn.set,defaults:Yn},"restrictRect"),io={width:-1/0,height:-1/0},Jn={width:1/0,height:1/0},qo=Sr({start:function(o){return Gn.start(o)},set:function(o){var i=o.interaction,f=o.state,m=o.rect,_=o.edges,O=f.options;if(_){var G=Ee(nn(O.min,i,o.coords))||io,ee=Ee(nn(O.max,i,o.coords))||Jn;f.options={endOnly:O.endOnly,inner:le({},Gn.noInner),outer:le({},Gn.noOuter)},_.top?(f.options.inner.top=m.bottom-G.height,f.options.outer.top=m.bottom-ee.height):_.bottom&&(f.options.inner.bottom=m.top+G.height,f.options.outer.bottom=m.top+ee.height),_.left?(f.options.inner.left=m.right-G.width,f.options.outer.left=m.right-ee.width):_.right&&(f.options.inner.right=m.left+G.width,f.options.outer.right=m.left+ee.width),Gn.set(o),f.options=O}},defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize"),ci={start:function(o){var i,f=o.interaction,m=o.interactable,_=o.element,O=o.rect,G=o.state,ee=o.startOffset,ke=G.options,He=ke.offsetWithOrigin?function(Ba){var Xa=Ba.interaction.element,Ka=ca(te(Ba.state.options.origin,null,null,[Xa])),al=Ka||Te(Ba.interactable,Xa,Ba.interaction.prepared.name);return al}(o):{x:0,y:0};if(ke.offset==="startCoords")i={x:f.coords.start.page.x,y:f.coords.start.page.y};else{var Ce=te(ke.offset,m,_,[f]);(i=ca(Ce)||{x:0,y:0}).x+=He.x,i.y+=He.y}var aa=ke.relativePoints;G.offsets=O&&aa&&aa.length?aa.map(function(Ba,Xa){return{index:Xa,relativePoint:Ba,x:ee.left-O.width*Ba.x+i.x,y:ee.top-O.height*Ba.y+i.y}}):[{index:0,relativePoint:null,x:i.x,y:i.y}]},set:function(o){var i=o.interaction,f=o.coords,m=o.state,_=m.options,O=m.offsets,G=Te(i.interactable,i.element,i.prepared.name),ee=le({},f),ke=[];_.offsetWithOrigin||(ee.x-=G.x,ee.y-=G.y);for(var He=0,Ce=O;He<Ce.length;He++)for(var aa=Ce[He],Ba=ee.x-aa.x,Xa=ee.y-aa.y,Ka=0,al=_.targets.length;Ka<al;Ka++){var bl=_.targets[Ka],vl=void 0;(vl=w.func(bl)?bl(Ba,Xa,i._proxy,aa,Ka):bl)&&ke.push({x:(w.number(vl.x)?vl.x:Ba)+aa.x,y:(w.number(vl.y)?vl.y:Xa)+aa.y,range:w.number(vl.range)?vl.range:_.range,source:bl,index:Ka,offset:aa})}for(var El={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}},Hl=0;Hl<ke.length;Hl++){var Cl=ke[Hl],zl=Cl.range,Al=Cl.x-ee.x,Hr=Cl.y-ee.y,rr=Ja(Al,Hr),Gr=rr<=zl;zl===1/0&&El.inRange&&El.range!==1/0&&(Gr=!1),El.target&&!(Gr?El.inRange&&zl!==1/0?rr/zl<El.distance/El.range:zl===1/0&&El.range!==1/0||rr<El.distance:!El.inRange&&rr<El.distance)||(El.target=Cl,El.distance=rr,El.range=zl,El.inRange=Gr,El.delta.x=Al,El.delta.y=Hr)}return El.inRange&&(f.x=El.target.x,f.y=El.target.y),m.closest=El,El},defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}},Xn=Sr(ci,"snap"),ui={start:function(o){var i=o.state,f=o.edges,m=i.options;if(!f)return null;o.state={options:{targets:null,relativePoints:[{x:f.left?0:1,y:f.top?0:1}],offset:m.offset||"self",origin:{x:0,y:0},range:m.range}},i.targetFields=i.targetFields||[["width","height"],["x","y"]],ci.start(o),i.offsets=o.state.offsets,o.state=i},set:function(o){var i=o.interaction,f=o.state,m=o.coords,_=f.options,O=f.offsets,G={x:m.x-O[0].x,y:m.y-O[0].y};f.options=le({},_),f.options.targets=[];for(var ee=0,ke=_.targets||[];ee<ke.length;ee++){var He=ke[ee],Ce=void 0;if(Ce=w.func(He)?He(G.x,G.y,i):He){for(var aa=0,Ba=f.targetFields;aa<Ba.length;aa++){var Xa=Ba[aa],Ka=Xa[0],al=Xa[1];if(Ka in Ce||al in Ce){Ce.x=Ce[Ka],Ce.y=Ce[al];break}}f.options.targets.push(Ce)}}var bl=ci.set(o);return f.options=_,bl},defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}},Wo=Sr(ui,"snapSize"),Ii={aspectRatio:Uo,restrictEdges:ro,restrict:Mi,restrictRect:no,restrictSize:qo,snapEdges:Sr({start:function(o){var i=o.edges;return i?(o.state.targetFields=o.state.targetFields||[[i.left?"left":"right",i.top?"top":"bottom"]],ui.start(o)):null},set:ui.set,defaults:le(Nr(ui.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})},"snapEdges"),snap:Xn,snapSize:Wo,spring:si,avoid:si,transform:si,rubberband:si},Ko={id:"modifiers",install:function(o){var i=o.interactStatic;for(var f in o.usePlugin(Dr),o.usePlugin(Ho),i.modifiers=Ii,Ii){var m=Ii[f],_=m._defaults,O=m._methods;_._methods=O,o.defaults.perAction[f]=_}}},Go=Ko,oo=function(o){y(f,o);var i=M(f);function f(m,_,O,G,ee,ke){var He;if(s(this,f),H(D(He=i.call(this,ee)),O),O!==_&&H(D(He),_),He.timeStamp=ke,He.originalEvent=O,He.type=m,He.pointerId=ce(_),He.pointerType=Va(_),He.target=G,He.currentTarget=null,m==="tap"){var Ce=ee.getPointerIndex(_);He.dt=He.timeStamp-ee.pointers[Ce].downTime;var aa=He.timeStamp-ee.tapTime;He.double=!!ee.prevTap&&ee.prevTap.type!=="doubletap"&&ee.prevTap.target===He.target&&aa<500}else m==="doubletap"&&(He.dt=_.timeStamp-ee.tapTime,He.double=!0);return He}return d(f,[{key:"_subtractOrigin",value:function(m){var _=m.x,O=m.y;return this.pageX-=_,this.pageY-=O,this.clientX-=_,this.clientY-=O,this}},{key:"_addOrigin",value:function(m){var _=m.x,O=m.y;return this.pageX+=_,this.pageY+=O,this.clientX+=_,this.clientY+=O,this}},{key:"preventDefault",value:function(){this.originalEvent.preventDefault()}}]),f}(X),Zn={id:"pointer-events/base",before:["inertia","modifiers","auto-start","actions"],install:function(o){o.pointerEvents=Zn,o.defaults.actions.pointerEvents=Zn.defaults,le(o.actions.phaselessTypes,Zn.types)},listeners:{"interactions:new":function(o){var i=o.interaction;i.prevTap=null,i.tapTime=0},"interactions:update-pointer":function(o){var i=o.down,f=o.pointerInfo;!i&&f.hold||(f.hold={duration:1/0,timeout:null})},"interactions:move":function(o,i){var f=o.interaction,m=o.pointer,_=o.event,O=o.eventTarget;o.duplicate||f.pointerIsDown&&!f.pointerWasMoved||(f.pointerIsDown&&Li(o),En({interaction:f,pointer:m,event:_,eventTarget:O,type:"move"},i))},"interactions:down":function(o,i){(function(f,m){for(var _=f.interaction,O=f.pointer,G=f.event,ee=f.eventTarget,ke=f.pointerIndex,He=_.pointers[ke].hold,Ce=la(ee),aa={interaction:_,pointer:O,event:G,eventTarget:ee,type:"hold",targets:[],path:Ce,node:null},Ba=0;Ba<Ce.length;Ba++){var Xa=Ce[Ba];aa.node=Xa,m.fire("pointerEvents:collect-targets",aa)}if(aa.targets.length){for(var Ka=1/0,al=0,bl=aa.targets;al<bl.length;al++){var vl=bl[al].eventable.options.holdDuration;vl<Ka&&(Ka=vl)}He.duration=Ka,He.timeout=setTimeout(function(){En({interaction:_,eventTarget:ee,pointer:O,event:G,type:"hold"},m)},Ka)}})(o,i),En(o,i)},"interactions:up":function(o,i){Li(o),En(o,i),function(f,m){var _=f.interaction,O=f.pointer,G=f.event,ee=f.eventTarget;_.pointerWasMoved||En({interaction:_,eventTarget:ee,pointer:O,event:G,type:"tap"},m)}(o,i)},"interactions:cancel":function(o,i){Li(o),En(o,i)}},PointerEvent:oo,fire:En,collectEventTargets:Oi,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 En(o,i){var f=o.interaction,m=o.pointer,_=o.event,O=o.eventTarget,G=o.type,ee=o.targets,ke=ee===void 0?Oi(o,i):ee,He=new oo(G,m,_,O,f,i.now());i.fire("pointerEvents:new",{pointerEvent:He});for(var Ce={interaction:f,pointer:m,event:_,eventTarget:O,targets:ke,type:G,pointerEvent:He},aa=0;aa<ke.length;aa++){var Ba=ke[aa];for(var Xa in Ba.props||{})He[Xa]=Ba.props[Xa];var Ka=Te(Ba.eventable,Ba.node);if(He._subtractOrigin(Ka),He.eventable=Ba.eventable,He.currentTarget=Ba.node,Ba.eventable.fire(He),He._addOrigin(Ka),He.immediatePropagationStopped||He.propagationStopped&&aa+1<ke.length&&ke[aa+1].node!==He.currentTarget)break}if(i.fire("pointerEvents:fired",Ce),G==="tap"){var al=He.double?En({interaction:f,pointer:m,event:_,eventTarget:O,type:"doubletap"},i):He;f.prevTap=al,f.tapTime=al.timeStamp}return He}function Oi(o,i){var f=o.interaction,m=o.pointer,_=o.event,O=o.eventTarget,G=o.type,ee=f.getPointerIndex(m),ke=f.pointers[ee];if(G==="tap"&&(f.pointerWasMoved||!ke||ke.downTarget!==O))return[];for(var He=la(O),Ce={interaction:f,pointer:m,event:_,eventTarget:O,type:G,path:He,targets:[],node:null},aa=0;aa<He.length;aa++){var Ba=He[aa];Ce.node=Ba,i.fire("pointerEvents:collect-targets",Ce)}return G==="hold"&&(Ce.targets=Ce.targets.filter(function(Xa){var Ka,al;return Xa.eventable.options.holdDuration===((Ka=f.pointers[ee])==null||(al=Ka.hold)==null?void 0:al.duration)})),Ce.targets}function Li(o){var i=o.interaction,f=o.pointerIndex,m=i.pointers[f].hold;m&&m.timeout&&(clearTimeout(m.timeout),m.timeout=null)}var Yo=Object.freeze({__proto__:null,default:Zn});function Jo(o){var i=o.interaction;i.holdIntervalHandle&&(clearInterval(i.holdIntervalHandle),i.holdIntervalHandle=null)}var Xo={id:"pointer-events/holdRepeat",install:function(o){o.usePlugin(Zn);var i=o.pointerEvents;i.defaults.holdRepeatInterval=0,i.types.holdrepeat=o.actions.phaselessTypes.holdrepeat=!0},listeners:["move","up","cancel","endall"].reduce(function(o,i){return o["pointerEvents:".concat(i)]=Jo,o},{"pointerEvents:new":function(o){var i=o.pointerEvent;i.type==="hold"&&(i.count=(i.count||0)+1)},"pointerEvents:fired":function(o,i){var f=o.interaction,m=o.pointerEvent,_=o.eventTarget,O=o.targets;if(m.type==="hold"&&O.length){var G=O[0].eventable.options.holdRepeatInterval;G<=0||(f.holdIntervalHandle=setTimeout(function(){i.pointerEvents.fire({interaction:f,eventTarget:_,type:"hold",pointer:m,event:m},i)},G))}}})},di=Xo,Zo={id:"pointer-events/interactableTargets",install:function(o){var i=o.Interactable;i.prototype.pointerEvents=function(m){return le(this.events.options,m),this};var f=i.prototype._backCompatOption;i.prototype._backCompatOption=function(m,_){var O=f.call(this,m,_);return O===this&&(this.events.options[m]=_),O}},listeners:{"pointerEvents:collect-targets":function(o,i){var f=o.targets,m=o.node,_=o.type,O=o.eventTarget;i.interactables.forEachMatch(m,function(G){var ee=G.events,ke=ee.options;ee.types[_]&&ee.types[_].length&&G.testIgnoreAllow(ke,m,O)&&f.push({node:m,eventable:ee,props:{interactable:G}})})},"interactable:new":function(o){var i=o.interactable;i.events.getRect=function(f){return i.getRect(f)}},"interactable:set":function(o,i){var f=o.interactable,m=o.options;le(f.events.options,i.pointerEvents.defaults),le(f.events.options,m.pointerEvents||{})}}},Qo=Zo,et={id:"pointer-events",install:function(o){o.usePlugin(Yo),o.usePlugin(di),o.usePlugin(Qo)}},at=et,to={id:"reflow",install:function(o){var i=o.Interactable;o.actions.phases.reflow=!0,i.prototype.reflow=function(f){return function(m,_,O){for(var G=m.getAllElements(),ee=O.window.Promise,ke=ee?[]:null,He=function(){var aa=G[Ce],Ba=m.getRect(aa);if(!Ba)return 1;var Xa,Ka=Je(O.interactions.list,function(vl){return vl.interacting()&&vl.interactable===m&&vl.element===aa&&vl.prepared.name===_.name});if(Ka)Ka.move(),ke&&(Xa=Ka._reflowPromise||new ee(function(vl){Ka._reflowResolve=vl}));else{var al=Ee(Ba),bl=function(vl){return{coords:vl,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:al.x,y:al.y},client:{x:al.x,y:al.y},timeStamp:O.now()});Xa=function(vl,El,Hl,Cl,zl){var Al=vl.interactions.new({pointerType:"reflow"}),Hr={interaction:Al,event:zl,pointer:zl,eventTarget:Hl,phase:"reflow"};Al.interactable=El,Al.element=Hl,Al.prevEvent=zl,Al.updatePointer(zl,zl,Hl,!0),me(Al.coords.delta),va(Al.prepared,Cl),Al._doPhase(Hr);var rr=vl.window,Gr=rr.Promise,on=Gr?new Gr(function(xn){Al._reflowResolve=xn}):void 0;return Al._reflowPromise=on,Al.start(Cl,El,Hl),Al._interacting?(Al.move(Hr),Al.end(zl)):(Al.stop(),Al._reflowResolve()),Al.removePointer(zl,zl),on}(O,m,aa,_,bl)}ke&&ke.push(Xa)},Ce=0;Ce<G.length&&!He();Ce++);return ke&&ee.all(ke).then(function(){return m})}(this,f,o)}},listeners:{"interactions:stop":function(o,i){var f=o.interaction;f.pointerType==="reflow"&&(f._reflowResolve&&f._reflowResolve(),function(m,_){m.splice(m.indexOf(_),1)}(i.interactions.list,f))}}},pi=to;if(jr.use(ar),jr.use(Vl),jr.use(at),jr.use(Nn),jr.use(Go),jr.use(fr),jr.use(ma),jr.use(pe),jr.use(pi),jr.default=jr,t(a)==="object"&&a)try{a.exports=jr}catch{}return jr.default=jr,jr})}(Pi,Pi.exports)),Pi.exports}var m1=v1();const As=A.getDefaultExportFromCjs(m1),Mo=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,t=r,s=e.inject(Pc),v=e.inject(jc);if(!s)throw new Error("[grid-layout-plus]: missing layout store, GridItem must under a GridLayout.");const d=e.shallowRef(null),p=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 y=!1,g=!1,c=NaN,D=NaN,M=NaN,S=NaN,K=-1,I=-1,R=-1,j=-1,E=n.x,x=n.y,k=n.w,b=n.h;const w=e.ref(),$=e.reactive({i:e.toRef(n,"i"),state:p,wrapper:w,calcXY:te});function F(ve){Ue(ve)}function J(){oa()}function se(ve){cn(n.isDraggable)&&(p.draggable=ve)}function ge(ve){cn(n.isResizable)&&(p.resizable=ve)}function Me(ve){cn(n.isBounded)&&(p.bounded=ve)}function V(ve){p.transformScale=ve}function fe(ve){p.rowHeight=ve}function ae(ve){p.maxRows=ve}function de(){p.rtl=Ns()==="rtl",oa()}function De(ve){p.cols=Math.floor(ve)}s.increaseItem($),e.onBeforeMount(()=>{p.rtl=Ns()==="rtl"}),e.onMounted(()=>{s.responsive&&s.lastBreakpoint?p.cols=Kc(s.lastBreakpoint,s.cols):p.cols=s.colNum,p.rowHeight=s.rowHeight,p.containerWidth=s.width!==null?s.width:100,p.margin=s.margin!==void 0?s.margin.map(Number):[10,10],p.maxRows=s.maxRows,cn(n.isDraggable)?p.draggable=s.isDraggable:p.draggable=n.isDraggable,cn(n.isResizable)?p.resizable=s.isResizable:p.resizable=n.isResizable,cn(n.isBounded)?p.bounded=s.isBounded:p.bounded=n.isBounded,p.transformScale=s.transformScale,p.useCssTransforms=s.useCssTransforms,p.useStyleCursor=s.useStyleCursor,e.watchEffect(()=>{E=n.x,x=n.y,b=n.h,k=n.w,Yr(Pe)}),v.on("updateWidth",F),v.on("compact",J),v.on("setDraggable",se),v.on("setResizable",ge),v.on("setBounded",Me),v.on("setTransformScale",V),v.on("setRowHeight",fe),v.on("setMaxRows",ae),v.on("directionchange",de),v.on("setColNum",De)}),e.onBeforeUnmount(()=>{v.off("updateWidth",F),v.off("compact",J),v.off("setDraggable",se),v.off("setResizable",ge),v.off("setBounded",Me),v.off("setTransformScale",V),v.off("setRowHeight",fe),v.off("setMaxRows",ae),v.off("directionchange",de),v.off("setColNum",De),d.value&&(d.value.unset(),d.value=null),s.decreaseItem($)}),l({state:p,wrapper:w});const Fe=typeof navigator<"u"?navigator.userAgent.toLowerCase().includes("android"):!1,ye=e.computed(()=>p.resizable&&!n.static),T=e.computed(()=>s.isMirrored?!p.rtl:p.rtl),ue=e.computed(()=>(p.draggable||p.resizable)&&!n.static),U=o1("item"),Se=e.computed(()=>({[U.b()]:!0,[U.bm("resizable")]:ye.value,[U.bm("static")]:n.static,[U.bm("resizing")]:p.isResizing,[U.bm("dragging")]:p.isDragging,[U.bm("transform")]:p.useCssTransforms,[U.bm("rtl")]:T.value,[U.bm("no-touch")]:Fe&&ue.value})),Le=e.computed(()=>[U.be("resizer"),T.value&&U.bem("resizer","rtl")].filter(Boolean));e.watch(()=>n.isDraggable,ve=>{p.draggable=ve}),e.watch(()=>n.static,()=>{Yr(H),Yr(me)}),e.watch(()=>p.draggable,()=>{Yr(H)}),e.watch(()=>n.isResizable,ve=>{p.resizable=ve}),e.watch(()=>n.isBounded,ve=>{p.bounded=ve}),e.watch(()=>p.resizable,()=>{Yr(me)}),e.watch(()=>p.rowHeight,()=>{Yr(Pe),Yr(la)}),e.watch([()=>p.cols,()=>p.containerWidth],()=>{Yr(me),Yr(Pe),Yr(la)}),e.watch([()=>n.minH,()=>n.maxH,()=>n.minW,()=>n.maxW],()=>{Yr(me)}),e.watch(T,()=>{Yr(me),Yr(Pe)}),e.watch([()=>s.margin,()=>s.margin[0],()=>s.margin[1]],()=>{const ve=s.margin;!ve||ve[0]===p.margin[0]&&ve[1]===p.margin[1]||(p.margin=ve.map(Number),Yr(Pe),Yr(la))});function Pe(){n.x+n.w>p.cols?(E=0,k=n.w>p.cols?p.cols:n.w):(E=n.x,k=n.w);const ve=ta(E,x,k,b);p.isDragging&&(ve.top=p.dragging.top,T.value?ve.right=p.dragging.left:ve.left=p.dragging.left),p.isResizing&&(ve.width=p.resizing.width,ve.height=p.resizing.height);let da;p.useCssTransforms?T.value?da=l1(ve.top,ve.right,ve.width,ve.height):da=a1(ve.top,ve.left,ve.width,ve.height):T.value?da=n1(ve.top,ve.right,ve.width,ve.height):da=r1(ve.top,ve.left,ve.width,ve.height),p.style=da}function la(){const ve={};for(const da of["width","height"]){const ea=p.style[da].match(/^(\d+)px$/);if(!ea)return;ve[da]=ea[1]}t("container-resized",n.i,n.h,n.w,ve.height,ve.width)}function Da(ve){if(n.static)return;const da=ve.type;if(da==="resizestart"&&p.isResizing||da!=="resizestart"&&!p.isResizing)return;const ea=Ds(ve);if(cn(ea))return;const{x:ce,y:pa}=ea,Ne={width:0,height:0};let We;switch(da){case"resizestart":{me(),K=k,I=b,We=ta(E,x,k,b),Ne.width=We.width,Ne.height=We.height,p.resizing=Ne,p.isResizing=!0;break}case"resizemove":{!ve.edges.right&&!ve.edges.left&&(M=ce),!ve.edges.top&&!ve.edges.bottom&&(S=pa);const Ta=Bs(M,S,ce,pa);T.value?Ne.width=p.resizing.width-Ta.deltaX/p.transformScale:Ne.width=p.resizing.width+Ta.deltaX/p.transformScale,Ne.height=p.resizing.height+Ta.deltaY/p.transformScale,p.resizing=Ne;break}case"resizeend":{We=ta(E,x,k,b),Ne.width=We.width,Ne.height=We.height,p.resizing={width:-1,height:-1},p.isResizing=!1;break}}We=Te(Ne.height,Ne.width),We.w<n.minW&&(We.w=n.minW),We.w>n.maxW&&(We.w=n.maxW),We.h<n.minH&&(We.h=n.minH),We.h>n.maxH&&(We.h=n.maxH),We.h<1&&(We.h=1),We.w<1&&(We.w=1),M=ce,S=pa,(k!==We.w||b!==We.h)&&t("resize",n.i,We.h,We.w,Ne.height,Ne.width),ve.type==="resizeend"&&(K!==k||I!==b)&&t("resized",n.i,We.h,We.w,Ne.height,Ne.width),v.emit("resizeEvent",ve.type,n.i,E,x,We.h,We.w)}function le(ve){if(n.static||p.isResizing)return;const da=ve.type;if(da==="dragstart"&&p.isDragging||da!=="dragstart"&&!p.isDragging)return;const ea=Ds(ve);if(cn(ea))return;const{x:ce,y:pa}=ea,Ne=ve.target;if(!Ne.offsetParent)return;const We={top:0,left:0};switch(da){case"dragstart":{R=E,j=x;const Ca=Ne.offsetParent.getBoundingClientRect(),Qe=Ne.getBoundingClientRect(),Va=Qe.left/p.transformScale,ne=Ca.left/p.transformScale,X=Qe.right/p.transformScale,Z=Ca.right/p.transformScale,q=Qe.top/p.transformScale,Be=Ca.top/p.transformScale;T.value?We.left=(X-Z)*-1:We.left=Va-ne,We.top=q-Be,p.dragging=We,p.isDragging=!0;break}case"dragmove":{const Ca=Bs(c,D,ce,pa);if(T.value?We.left=p.dragging.left-Ca.deltaX/p.transformScale:We.left=p.dragging.left+Ca.deltaX/p.transformScale,We.top=p.dragging.top+Ca.deltaY/p.transformScale,p.bounded){const Qe=Ne.offsetParent.clientHeight-Ee(n.h,p.rowHeight,p.margin[1]);We.top=oe(We.top,0,Qe);const Va=ca(),ne=p.containerWidth-Ee(n.w,Va,p.margin[0]);We.left=oe(We.left,0,ne)}p.dragging=We;break}case"dragend":{const Ca=Ne.offsetParent.getBoundingClientRect(),Qe=Ne.getBoundingClientRect(),Va=Qe.left/p.transformScale,ne=Ca.left/p.transformScale,X=Qe.right/p.transformScale,Z=Ca.right/p.transformScale,q=Qe.top/p.transformScale,Be=Ca.top/p.transformScale;T.value?We.left=(X-Z)*-1:We.left=Va-ne,We.top=q-Be,p.dragging={top:-1,left:-1},p.isDragging=!1;break}}let Ta;T.value,Ta=te(We.top,We.left),c=ce,D=pa,(E!==Ta.x||x!==Ta.y)&&t("move",n.i,Ta.x,Ta.y),ve.type==="dragend"&&(R!==E||j!==x)&&t("moved",n.i,Ta.x,Ta.y),v.emit("dragEvent",ve.type,n.i,Ta.x,Ta.y,b,k)}function ta(ve,da,ea,ce){const pa=ca();let Ne;return T.value?Ne={right:Math.round(pa*ve+(ve+1)*p.margin[0]),top:Math.round(p.rowHeight*da+(da+1)*p.margin[1]),width:ea===1/0?ea:Math.round(pa*ea+Math.max(0,ea-1)*p.margin[0]),height:ce===1/0?ce:Math.round(p.rowHeight*ce+Math.max(0,ce-1)*p.margin[1])}:Ne={left:Math.round(pa*ve+(ve+1)*p.margin[0]),top:Math.round(p.rowHeight*da+(da+1)*p.margin[1]),width:ea===1/0?ea:Math.round(pa*ea+Math.max(0,ea-1)*p.margin[0]),height:ce===1/0?ce:Math.round(p.rowHeight*ce+Math.max(0,ce-1)*p.margin[1])},Ne}function te(ve,da){const ea=ca();let ce=Math.round((da-p.margin[0])/(ea+p.margin[0])),pa=Math.round((ve-p.margin[1])/(p.rowHeight+p.margin[1]));return ce=Math.max(Math.min(ce,p.cols-k),0),pa=Math.max(Math.min(pa,p.maxRows-b),0),{x:ce,y:pa}}function ca(){return(p.containerWidth-p.margin[0]*(p.cols+1))/p.cols}function Ee(ve,da,ea){return Number.isFinite(ve)?Math.round(da*ve+Math.max(0,ve-1)*ea):ve}function oe(ve,da,ea){return Math.max(Math.min(ve,ea),da)}function Te(ve,da,ea=!1){const ce=ca();let pa=Math.round((da+p.margin[0])/(ce+p.margin[0])),Ne=0;return ea?Ne=Math.ceil((ve+p.margin[1])/(p.rowHeight+p.margin[1])):Ne=Math.round((ve+p.margin[1])/(p.rowHeight+p.margin[1])),pa=Math.max(Math.min(pa,p.cols-E),0),Ne=Math.max(Math.min(Ne,p.maxRows-x),0),{w:pa,h:Ne}}function Ue(ve,da){p.containerWidth=ve}function oa(){Pe()}function Ja(){!d.value&&w.value&&(d.value=As(w.value),p.useStyleCursor||d.value.styleCursor(!1))}const L=Ss(le);function H(){if(Ja(),!!d.value)if(p.draggable&&!n.static){const ve={ignoreFrom:n.dragIgnoreFrom,allowFrom:n.dragAllowFrom,...n.dragOption};d.value.draggable(ve),y||(y=!0,d.value.on("dragstart dragmove dragend",da=>{da.type==="dragmove"?L(da):le(da)}))}else d.value.draggable({enabled:!1})}const Q=Ss(Da);function me(){if(Ja(),!!d.value)if(p.resizable&&!n.static){const ve=ta(0,0,n.maxW,n.maxH),da=ta(0,0,n.minW,n.minH),ea={edges:{left:T.value?`.${Le.value[0]}`:!1,right:T.value?!1:`.${Le.value[0]}`,bottom:`.${Le.value[0]}`,top:!1},ignoreFrom:n.resizeIgnoreFrom,restrictSize:{min:{height:da.height*p.transformScale,width:da.width*p.transformScale},max:{height:ve.height*p.transformScale,width:ve.width*p.transformScale}},...n.resizeOption};n.preserveAspectRatio&&(ea.modifiers=[As.modifiers.aspectRatio({ratio:"preserve"})]),d.value.resizable(ea),g||(g=!0,d.value.on("resizestart resizemove resizeend",ce=>{ce.type==="resizemove"?Q(ce):Da(ce)}))}else d.value.resizable({enabled:!1})}return(ve,da)=>(e.openBlock(),e.createElementBlock("section",{ref_key:"wrapper",ref:w,class:e.normalizeClass(Se.value),style:e.normalizeStyle(p.style)},[e.renderSlot(ve.$slots,"default"),ye.value?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(Le.value)},null,2)):e.createCommentVNode("",!0)],6))}}),ti=typeof window<"u";var zs;ti&&(zs=window==null?void 0:window.navigator)!=null&&zs.userAgent&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Ms(a){return a!=null}function Is(){}const y1=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(y1)));const g1=ti&&("ontouchstart"in window||k1()>0),b1=g1?"pointerdown":"click";function k1(){return typeof navigator<"u"&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)||0}function x1(a,l,r=window.Event){const{type:n,bubbles:t=!1,cancelable:s=!1,...v}=l;if(!Ms(n)||n==="")return!1;let d;return Ms(r)?d=new r(n,{bubbles:t,cancelable:s}):(d=document.createEvent("HTMLEvents"),d.initEvent(n,t,s)),Object.assign(d,v),a.dispatchEvent(d)}const w1="clickoutside",_1=new Set;ti&&document.addEventListener(b1,a=>{const l=a.target,r=a.composedPath&&a.composedPath();_1.forEach(n=>{n!==l&&(r?!r.includes(n):!n.contains(l))&&(!n.__transferElement||n.__transferElement!==l&&!n.__transferElement.contains(l))&&x1(n,{type:w1})})},!0);const S1=[["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 wo;if(ti){for(const a of S1)if(a[1]in document){wo=a;break}}e.computed(()=>!1);const E1=new Set,C1=new WeakMap;if(ti&&wo){const a=wo[2],l=wo[4];document.addEventListener(l,()=>{if(E1.forEach(r=>{r.value=!1}),document[a]){const r=C1.get(document[a]);r&&(r.value=!0)}},!1)}const Yc=new Map;Yc.set("x",0);Yc.set("y",0);var ii=[],D1=function(){return ii.some(function(a){return a.activeTargets.length>0})},B1=function(){return ii.some(function(a){return a.skippedTargets.length>0})},Os="ResizeObserver loop completed with undelivered notifications.",N1=function(){var a;typeof ErrorEvent=="function"?a=new ErrorEvent("error",{message:Os}):(a=document.createEvent("Event"),a.initEvent("error",!1,!1),a.message=Os),window.dispatchEvent(a)},Yi;(function(a){a.BORDER_BOX="border-box",a.CONTENT_BOX="content-box",a.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(Yi||(Yi={}));var oi=function(a){return Object.freeze(a)},T1=function(){function a(l,r){this.inlineSize=l,this.blockSize=r,oi(this)}return a}(),Jc=function(){function a(l,r,n,t){return this.x=l,this.y=r,this.width=n,this.height=t,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,oi(this)}return a.prototype.toJSON=function(){var l=this,r=l.x,n=l.y,t=l.top,s=l.right,v=l.bottom,d=l.left,p=l.width,y=l.height;return{x:r,y:n,top:t,right:s,bottom:v,left:d,width:p,height:y}},a.fromRect=function(l){return new a(l.x,l.y,l.width,l.height)},a}(),Nt=function(a){return a instanceof SVGElement&&"getBBox"in a},Xc=function(a){if(Nt(a)){var l=a.getBBox(),r=l.width,n=l.height;return!r&&!n}var t=a,s=t.offsetWidth,v=t.offsetHeight;return!(s||v||a.getClientRects().length)},Ls=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)},A1=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},Wi=typeof window<"u"?window:{},go=new WeakMap,Rs=/auto|scroll/,z1=/^tb|vertical/,M1=/msie|trident/i.test(Wi.navigator&&Wi.navigator.userAgent),Dn=function(a){return parseFloat(a||"0")},Ei=function(a,l,r){return a===void 0&&(a=0),l===void 0&&(l=0),r===void 0&&(r=!1),new T1((r?l:a)||0,(r?a:l)||0)},$s=oi({devicePixelContentBoxSize:Ei(),borderBoxSize:Ei(),contentBoxSize:Ei(),contentRect:new Jc(0,0,0,0)}),Zc=function(a,l){if(l===void 0&&(l=!1),go.has(a)&&!l)return go.get(a);if(Xc(a))return go.set(a,$s),$s;var r=getComputedStyle(a),n=Nt(a)&&a.ownerSVGElement&&a.getBBox(),t=!M1&&r.boxSizing==="border-box",s=z1.test(r.writingMode||""),v=!n&&Rs.test(r.overflowY||""),d=!n&&Rs.test(r.overflowX||""),p=n?0:Dn(r.paddingTop),y=n?0:Dn(r.paddingRight),g=n?0:Dn(r.paddingBottom),c=n?0:Dn(r.paddingLeft),D=n?0:Dn(r.borderTopWidth),M=n?0:Dn(r.borderRightWidth),S=n?0:Dn(r.borderBottomWidth),K=n?0:Dn(r.borderLeftWidth),I=c+y,R=p+g,j=K+M,E=D+S,x=d?a.offsetHeight-E-a.clientHeight:0,k=v?a.offsetWidth-j-a.clientWidth:0,b=t?I+j:0,w=t?R+E:0,$=n?n.width:Dn(r.width)-b-k,F=n?n.height:Dn(r.height)-w-x,J=$+I+k+j,se=F+R+x+E,ge=oi({devicePixelContentBoxSize:Ei(Math.round($*devicePixelRatio),Math.round(F*devicePixelRatio),s),borderBoxSize:Ei(J,se,s),contentBoxSize:Ei($,F,s),contentRect:new Jc(c,p,$,F)});return go.set(a,ge),ge},Qc=function(a,l,r){var n=Zc(a,r),t=n.borderBoxSize,s=n.contentBoxSize,v=n.devicePixelContentBoxSize;switch(l){case Yi.DEVICE_PIXEL_CONTENT_BOX:return v;case Yi.BORDER_BOX:return t;default:return s}},I1=function(){function a(l){var r=Zc(l);this.target=l,this.contentRect=r.contentRect,this.borderBoxSize=oi([r.borderBoxSize]),this.contentBoxSize=oi([r.contentBoxSize]),this.devicePixelContentBoxSize=oi([r.devicePixelContentBoxSize])}return a}(),eu=function(a){if(Xc(a))return 1/0;for(var l=0,r=a.parentNode;r;)l+=1,r=r.parentNode;return l},O1=function(){var a=1/0,l=[];ii.forEach(function(s){if(s.activeTargets.length!==0){var v=[];s.activeTargets.forEach(function(d){var p=new I1(d.target),y=eu(d.target);v.push(p),d.lastReportedSize=Qc(d.target,d.observedBox),y<a&&(a=y)}),l.push(function(){s.callback.call(s.observer,v,s.observer)}),s.activeTargets.splice(0,s.activeTargets.length)}});for(var r=0,n=l;r<n.length;r++){var t=n[r];t()}return a},Vs=function(a){ii.forEach(function(l){l.activeTargets.splice(0,l.activeTargets.length),l.skippedTargets.splice(0,l.skippedTargets.length),l.observationTargets.forEach(function(r){r.isActive()&&(eu(r.target)>a?l.activeTargets.push(r):l.skippedTargets.push(r))})})},L1=function(){var a=0;for(Vs(a);D1();)a=O1(),Vs(a);return B1()&&N1(),a>0},ut,au=[],R1=function(){return au.splice(0).forEach(function(a){return a()})},$1=function(a){if(!ut){var l=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return R1()}).observe(r,n),ut=function(){r.textContent="".concat(l?l--:l++)}}au.push(a),ut()},V1=function(a){$1(function(){requestAnimationFrame(a)})},_o=0,F1=function(){return!!_o},P1=250,j1={attributes:!0,characterData:!0,childList:!0,subtree:!0},Fs=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],Ps=function(a){return a===void 0&&(a=0),Date.now()+a},dt=!1,H1=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=P1),!dt){dt=!0;var n=Ps(l);V1(function(){var t=!1;try{t=L1()}finally{if(dt=!1,l=n-Ps(),!F1())return;t?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,j1)};document.body?r():Wi.addEventListener("DOMContentLoaded",r)},a.prototype.start=function(){var l=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),Fs.forEach(function(r){return Wi.addEventListener(r,l.listener,!0)}))},a.prototype.stop=function(){var l=this;this.stopped||(this.observer&&this.observer.disconnect(),Fs.forEach(function(r){return Wi.removeEventListener(r,l.listener,!0)}),this.stopped=!0)},a}(),St=new H1,js=function(a){!_o&&a>0&&St.start(),_o+=a,!_o&&St.stop()},U1=function(a){return!Nt(a)&&!A1(a)&&getComputedStyle(a).display==="inline"},q1=function(){function a(l,r){this.target=l,this.observedBox=r||Yi.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return a.prototype.isActive=function(){var l=Qc(this.target,this.observedBox,!0);return U1(this.target)&&(this.lastReportedSize=l),this.lastReportedSize.inlineSize!==l.inlineSize||this.lastReportedSize.blockSize!==l.blockSize},a}(),W1=function(){function a(l,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=l,this.callback=r}return a}(),bo=new WeakMap,Hs=function(a,l){for(var r=0;r<a.length;r+=1)if(a[r].target===l)return r;return-1},ko=function(){function a(){}return a.connect=function(l,r){var n=new W1(l,r);bo.set(l,n)},a.observe=function(l,r,n){var t=bo.get(l),s=t.observationTargets.length===0;Hs(t.observationTargets,r)<0&&(s&&ii.push(t),t.observationTargets.push(new q1(r,n&&n.box)),js(1),St.schedule())},a.unobserve=function(l,r){var n=bo.get(l),t=Hs(n.observationTargets,r),s=n.observationTargets.length===1;t>=0&&(s&&ii.splice(ii.indexOf(n),1),n.observationTargets.splice(t,1),js(-1))},a.disconnect=function(l){var r=this,n=bo.get(l);n.observationTargets.slice().forEach(function(t){return r.unobserve(l,t.target)}),n.activeTargets.splice(0,n.activeTargets.length)},a}(),K1=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.");ko.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(!Ls(l))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");ko.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(!Ls(l))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");ko.unobserve(this,l)},a.prototype.disconnect=function(){ko.disconnect(this)},a.toString=function(){return"function ResizeObserver () { [polyfill code] }"},a}();const Io=new WeakMap;function G1(a){var l;for(let r=0,n=a.length;r<n;++r){const t=a[r],s=Io.get(t.target);if(typeof s=="function"){const{inlineSize:v,blockSize:d}=((l=t.borderBoxSize)==null?void 0:l[0])??{},{offsetWidth:p,offsetHeight:y}=t.target;s(Object.assign(t,{offsetWidth:p,offsetHeight:y,width:v??p,height:d??y}))}}}const lu=new(ti&&window.ResizeObserver||K1)(G1);function Us(a,l){Io.set(a,l),lu.observe(a)}function qs(a){Io.has(a)&&(lu.unobserve(a),Io.delete(a))}function Y1(a={}){let l=Is;const r=e.watch(()=>e.unref(a.target),t=>{l(),!(!t||typeof a.onResize!="function")&&(Us(t,a.onResize),l=()=>{qs(t),l=Is})},{immediate:!0}),n=()=>{r(),l()};return e.getCurrentScope()&&e.onScopeDispose(n),{observeResize:Us,unobserveResize:qs,unobserve:n}}const J1=e.ref(!1);e.computed(()=>J1.value);const Ws="__theme_style__",pt="__theme_observer__",Ks=e.reactive(new Map),Gs=new Map;e.watch(Ks,()=>{if(!ti)return;Gs.clear();const a=document.head.querySelector(`#${Ws}`);a&&document.head.removeChild(a);const l=document.createElement("style");let r=`.${pt} { width: 1px }`,n=1;for(const[t,[s,v]]of Ks.entries())r+=` html.${s} .${pt}, .${v} .${pt} { width: ${++n}px }`,Gs.set(n,t);l.textContent=r,l.id=Ws,document.head.appendChild(l)});const ru=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,t=r,s=e.reactive({width:-1,mergedStyle:{},lastLayoutLength:0,isDragging:!1,placeholder:{x:0,y:0,w:0,h:0,i:""},layouts:{},lastBreakpoint:null,originalLayout:null}),v=new Map,d=e.ref(n.layout),p=e.ref(),{observeResize:y,unobserveResize:g}=Y1(),c=G6();c.on("resizeEvent",D),c.on("dragEvent",M),e.onBeforeMount(()=>{t("layout-before-mount",d.value)}),e.onMounted(()=>{t("layout-mounted",d.value),e.nextTick(()=>{i1(d.value),s.originalLayout=d.value,e.nextTick(()=>{F(),p.value&&y(p.value,Y6(E,16)),wi(d.value,n.verticalCompact),t("layout-updated",d.value),j(),E()})})}),e.onBeforeUnmount(()=>{c.clearAll(),p.value&&g(p.value)});function D(se,ge,Me,V,fe,ae){w(se,ge,Me,V,fe,ae)}function M(se,ge,Me,V,fe,ae){b(se,ge,Me,V,fe,ae)}e.watch(()=>s.width,(se,ge)=>{e.nextTick(()=>{c.emit("updateWidth",se),ge===-1&&e.nextTick(()=>{t("layout-ready",d.value)}),j()})}),e.watch(()=>[n.layout,n.layout.length],()=>{d.value=n.layout,R()}),e.watch(()=>n.colNum,se=>{c.emit("setColNum",se)}),e.watch(()=>n.rowHeight,se=>{c.emit("setRowHeight",se)}),e.watch(()=>n.isDraggable,se=>{c.emit("setDraggable",se)}),e.watch(()=>n.isResizable,se=>{c.emit("setResizable",se)}),e.watch(()=>n.isBounded,se=>{c.emit("setBounded",se)}),e.watch(()=>n.transformScale,se=>{c.emit("setTransformScale",se)}),e.watch(()=>n.responsive,se=>{se||(t("update:layout",s.originalLayout),c.emit("setColNum",n.colNum)),E()}),e.watch(()=>n.maxRows,se=>{c.emit("setMaxRows",se)}),e.watch([()=>n.margin,()=>n.margin[1]],j),e.provide(Pc,e.reactive({...e.toRefs(n),...e.toRefs(s),increaseItem:S,decreaseItem:K})),e.provide(jc,c),l({state:s,getItem:I,resizeEvent:w,dragEvent:b,layoutUpdate:R});function S(se){v.set(se.i,se)}function K(se){v.delete(se.i)}function I(se){return v.get(se)}function R(){if(!cn(d.value)&&!cn(s.originalLayout)){if(d.value.length!==s.originalLayout.length){const se=J(d.value,s.originalLayout);if(se.length>0)if(d.value.length>s.originalLayout.length)s.originalLayout=s.originalLayout.concat(se);else{const ge=new Set(se.map(Me=>Me.i));s.originalLayout=s.originalLayout.filter(Me=>!ge.has(Me.i))}s.lastLayoutLength=d.value.length,F()}wi(d.value,n.verticalCompact),c.emit("updateWidth",s.width),j(),t("layout-updated",d.value)}}function j(){s.mergedStyle={height:x()}}function E(){p.value&&(s.width=p.value.offsetWidth),c.emit("resizeEvent")}function x(){if(!n.autoSize)return;const se=parseFloat(n.margin[1]);return X6(d.value)*(n.rowHeight+se)+se+"px"}let k;function b(se,ge,Me,V,fe,ae){let de=Es(d.value,ge);cn(de)&&(de={h:0,w:0,x:0,y:0,i:""}),se==="dragstart"&&!n.verticalCompact&&(k=d.value.reduce((De,{i:Fe,x:ye,y:T})=>({...De,[Fe]:{x:ye,y:T}}),{})),se==="dragmove"||se==="dragstart"?(s.placeholder.i=ge,s.placeholder.x=de.x,s.placeholder.y=de.y,s.placeholder.w=ae,s.placeholder.h=fe,e.nextTick(()=>{s.isDragging=!0}),c.emit("updateWidth",s.width)):e.nextTick(()=>{s.isDragging=!1}),d.value=_t(d.value,de,Me,V,!0,n.preventCollision),n.restoreOnDrag?(de.static=!0,wi(d.value,n.verticalCompact,k),de.static=!1):wi(d.value,n.verticalCompact),c.emit("compact"),j(),se==="dragend"&&(k=void 0,t("layout-updated",d.value))}function w(se,ge,Me,V,fe,ae){let de=Es(d.value,ge);cn(de)&&(de={h:0,w:0,x:0,y:0,i:""});let De;if(n.preventCollision){const Fe=Uc(d.value,{...de,w:ae,h:fe}).filter(ye=>ye.i!==de.i);if(De=Fe.length>0,De){let ye=1/0,T=1/0;Fe.forEach(ue=>{ue.x>de.x&&(ye=Math.min(ye,ue.x)),ue.y>de.y&&(T=Math.min(T,ue.y))}),Number.isFinite(ye)&&(de.w=ye-de.x),Number.isFinite(T)&&(de.h=T-de.y)}}De||(de.w=ae,de.h=fe),se==="resizestart"||se==="resizemove"?(s.placeholder.i=ge,s.placeholder.x=Me,s.placeholder.y=V,s.placeholder.w=de.w,s.placeholder.h=de.h,e.nextTick(()=>{s.isDragging=!0}),c.emit("updateWidth",s.width)):se&&e.nextTick(()=>{s.isDragging=!1}),n.responsive&&$(),wi(d.value,n.verticalCompact),c.emit("compact"),j(),se==="resizeend"&&t("layout-updated",d.value)}function $(){const se=u1(n.breakpoints,s.width);if(se===s.lastBreakpoint)return;const ge=Kc(se,n.cols);!cn(s.lastBreakpoint)&&!s.layouts[s.lastBreakpoint]&&(s.layouts[s.lastBreakpoint]=wt(d.value));const Me=d1(s.originalLayout,s.layouts,n.breakpoints,se,s.lastBreakpoint,ge,n.verticalCompact);s.layouts[se]=Me,s.lastBreakpoint!==se&&t("breakpoint-changed",se,Me),d.value=Me,t("update:layout",Me),s.lastBreakpoint=se,c.emit("setColNum",ge)}function F(){s.layouts=Object.assign({},n.responsiveLayouts)}function J(se,ge){const Me=new Set(ge.map(de=>de.i)),V=new Set(se.map(de=>de.i)),fe=se.filter(de=>!Me.has(de.i)),ae=ge.filter(de=>!V.has(de.i));return fe.concat(ae)}return(se,ge)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"wrapper",ref:p,class:"vgl-layout",style:e.normalizeStyle(s.mergedStyle)},[se.$slots.default?e.renderSlot(se.$slots,"default",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(d.value,Me=>(e.openBlock(),e.createBlock(Mo,e.mergeProps({key:Me.i,ref_for:!0},Me),{default:e.withCtx(()=>[e.renderSlot(se.$slots,"item",{item:Me})]),_:2},1040))),128)),e.withDirectives(e.createVNode(Mo,{class:"vgl-item--placeholder",x:s.placeholder.x,y:s.placeholder.y,w:s.placeholder.w,h:s.placeholder.h,i:s.placeholder.i},null,8,["x","y","w","h","i"]),[[e.vShow,s.isDragging]])],4))}});(function(){try{if(typeof document<"u"){var a=document.createElement("style");a.appendChild(document.createTextNode('.vgl-layout{--vgl-placeholder-bg: red;--vgl-placeholder-opacity: 20%;--vgl-placeholder-z-index: 2;--vgl-item-resizing-z-index: 3;--vgl-item-resizing-opacity: 60%;--vgl-item-dragging-z-index: 3;--vgl-item-dragging-opacity: 100%;--vgl-resizer-size: 10px;--vgl-resizer-border-color: #444;--vgl-resizer-border-width: 2px;position:relative;box-sizing:border-box;transition:height .2s ease}.vgl-item{position:absolute;box-sizing:border-box;transition:.2s ease;transition-property:left,top,right}.vgl-item--placeholder{z-index:var(--vgl-placeholder-z-index, 2);-webkit-user-select:none;-moz-user-select:none;user-select:none;background-color:var(--vgl-placeholder-bg, red);opacity:var(--vgl-placeholder-opacity, 20%);transition-duration:.1s}.vgl-item--no-touch{touch-action:none}.vgl-item--transform{right:auto;left:0;transition-property:transform}.vgl-item--transform.vgl-item--rtl{right:0;left:auto}.vgl-item--resizing{z-index:var(--vgl-item-resizing-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-resizing-opacity, 60%)}.vgl-item--dragging{z-index:var(--vgl-item-dragging-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-dragging-opacity, 100%);transition:none}.vgl-item__resizer{position:absolute;right:0;bottom:0;box-sizing:border-box;width:var(--vgl-resizer-size);height:var(--vgl-resizer-size);cursor:se-resize}.vgl-item__resizer:before{position:absolute;top:0;right:3px;bottom:3px;left:0;content:"";border:0 solid var(--vgl-resizer-border-color);border-right-width:var(--vgl-resizer-border-width);border-bottom-width:var(--vgl-resizer-border-width)}.vgl-item__resizer--rtl{right:auto;left:0;cursor:sw-resize}.vgl-item__resizer--rtl:before{top:0;right:0;bottom:3px;left:3px;border-right-width:0;border-bottom-width:var(--vgl-resizer-border-width);border-left-width:var(--vgl-resizer-border-width)}')),document.head.appendChild(a)}}catch(l){console.error("vite-plugin-css-injected-by-js",l)}})();const X1={key:0,class:"item-view-group"},Z1={key:0,class:"item-view-group"},Q1=e.defineComponent({__name:"index",props:{children:{type:Object,default:()=>{}},level:{type:Number,default:1}},emits:["rowClick","routeUrl","radioChange"],setup(a,{emit:l}){const r=A.useModelComp(A.pinia),{isEdit:n}=A.storeToRefs(r),t=Hn(A.pinia),s=l,v=a,d=e.ref(""),p=e.computed(()=>v==null?void 0:v.children),y=e.computed(()=>{var j,E,x,k;return((j=v==null?void 0:v.children)==null?void 0:j.length)>0&&((E=v==null?void 0:v.children)!=null&&E.every(b=>b==null?void 0:b.layout))?(k=(x=v==null?void 0:v.children)==null?void 0:x[0])==null?void 0:k.layout:"vertical"}),g=j=>{d.value=j,s("radioChange",j)},c=e.computed(()=>{var j,E;return((E=(j=v==null?void 0:v.children)==null?void 0:j[0])==null?void 0:E.isGridLayout)||!1}),D=e.ref((v==null?void 0:v.level)+1),M=e.computed(()=>{if(!(v!=null&&v.children)||!Array.isArray(v.children)||v.children.length<2)return!1;const j=v.children.some(x=>(x==null?void 0:x.name)==="测量系统配置表"&&(x==null?void 0:x.comp)==="ParentItem"),E=v.children.some(x=>(x==null?void 0:x.name)==="测量系统传递表"&&(x==null?void 0:x.comp)==="ParentItem");return j&&E}),S=e.computed(()=>{var E,x,k,b,w,$;let j=(E=v==null?void 0:v.children)==null?void 0:E.filter(F=>F==null?void 0:F.choice);if(t.setSelectTab((x=j==null?void 0:j[0])==null?void 0:x.choiceName),(d==null?void 0:d.value)!=="")return(k=v==null?void 0:v.children)==null?void 0:k.filter(F=>!(F!=null&&F.choiceName)||(F==null?void 0:F.choiceName)===(d==null?void 0:d.value));{let F=(w=(b=v==null?void 0:v.children)==null?void 0:b.find(J=>J==null?void 0:J.choice))==null?void 0:w.choiceName;return($=v==null?void 0:v.children)==null?void 0:$.filter(J=>!(J!=null&&J.choiceName)||(J==null?void 0:J.choiceName)===F)}}),K=j=>{const E=(j==null?void 0:j.menuFilter)||[];return Array.isArray(E)&&(E==null?void 0:E.some(x=>{const k=typeof x=="string"?x:JSON.stringify(x);return k==null?void 0:k.includes("HideGroup=Yes")}))};e.watch(()=>v==null?void 0:v.children,()=>{M.value},{deep:!0});const I=j=>{s("rowClick",j)},R=(j,E)=>{s("routeUrl",j,E)};return(j,E)=>c.value?(e.openBlock(),e.createBlock(e.unref(ru),{key:0,layout:p.value,"onUpdate:layout":E[0]||(E[0]=x=>p.value=x),"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(p.value,(x,k)=>(e.openBlock(),e.createBlock(e.unref(Mo),{key:x.i,x:x.x,y:x.y,"min-h":x.minH,"max-h":x.maxH,"min-w":x.minW,w:x.w,h:x.h,i:x.i},{default:e.withCtx(()=>{var b,w,$,F,J,se,ge,Me,V,fe,ae,de,De,Fe;return[e.createElementVNode("div",{style:e.normalizeStyle({gap:"16px",display:"flex",flexDirection:"column",paddingBottom:k===((b=v==null?void 0:v.children)==null?void 0:b.length)-1?"0px":"24px"})},[(($=(w=x==null?void 0:x.component)==null?void 0:w.comp)==null?void 0:$.toUpperCase())!=="TABLE"&&((F=x==null?void 0:x.component)!=null&&F.name)?(e.openBlock(),e.createElementBlock("div",X1,[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((J=x==null?void 0:x.component)==null?void 0:J.name),5)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Gi)((se=x==null?void 0:x.component)==null?void 0:se.comp)),{pageLayout:y.value,config:{showIndex:(ge=e.unref(tr)[k])==null?void 0:ge.showIndex,allowMove:(Me=e.unref(tr)[k])==null?void 0:Me.allowMove,viewport:(V=e.unref(tr)[k])==null?void 0:V.viewport,status:(fe=e.unref(tr)[k])==null?void 0:fe.status},related:x==null?void 0:x.relatedTables,compName:x==null?void 0:x.component.name,compNames:e.unref(wc),itemData:(ae=x==null?void 0:x.component)==null?void 0:ae.compData,childItemData:(de=x==null?void 0:x.component)==null?void 0:de.itemChildData,key:e.unref(jn),cacheNewData:e.unref(xc),onChange:e.unref(No),index:(x==null?void 0:x.id)??k,onContentChange:e.unref(To),onPageChange:e.unref(Ao),parentTableId:(De=x==null?void 0:x.component)==null?void 0:De.tableId,allMapContents:e.unref(bt),children:(Fe=x==null?void 0:x.component)==null?void 0:Fe.children,level:D.value,onRowClick:I,onRouteUrl:R,onClickTrigger:e.unref(_c),onClickMainKey:e.unref(Sc),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(S.value,(x,k)=>{var b,w;return e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({gap:"16px",display:(x==null?void 0:x.isShow)===!1?"none":"flex",flexDirection:"column",paddingBottom:parseInt(k)===((b=v==null?void 0:v.children)==null?void 0:b.length)-1?"0px":"24px"})},[((w=x==null?void 0:x.comp)==null?void 0:w.toUpperCase())!=="TABLE"&&x.name?(e.openBlock(),e.createElementBlock("div",Z1,[K(x)?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(x.name),5))])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(Gi)(x.comp)),{compName:x.name,groupNames:x==null?void 0:x.nameContents,config:{showIndex:x==null?void 0:x.showIndex,allowMove:x==null?void 0:x.allowMove,viewport:x==null?void 0:x.viewport,status:x==null?void 0:x.status},itemData:x==null?void 0:x.compData,related:x==null?void 0:x.relatedTables,childItemData:x==null?void 0:x.itemChildData,key:e.unref(jn),onChange:e.unref(No),index:(x==null?void 0:x.id)??k,onContentChange:e.unref(To),onPageChange:e.unref(Ao),parentTableId:x==null?void 0:x.tableId,allMapContents:e.unref(bt),children:x==null?void 0:x.children,level:D.value,onRowClick:I,onRouteUrl:R,onRadioChange:g},null,40,["compName","groupNames","config","itemData","related","childItemData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level"]))],4)}),256))}}),ev=Zl._export_sfc(Q1,[["__scopeId","data-v-bafbdd45"]]),av={class:"radio-group-container"},lv=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},emits:["radioChange"],setup(a,{emit:l}){const r=a,n=l,t=e.ref(),s=Hn(A.pinia),{selectTab:v}=A.storeToRefs(s);e.watch(()=>r==null?void 0:r.itemData,()=>{t.value=v.value},{immediate:!0,deep:!0});const d=p=>{t.value=p,n("radioChange",t.value)};return(p,y)=>(e.openBlock(),e.createElementBlock("div",av,[e.createVNode(ll.ssRadio,{modelValue:t.value,"onUpdate:modelValue":y[0]||(y[0]=g=>t.value=g),content:r==null?void 0:r.itemData,onChange:d},null,8,["modelValue","content"])]))}}),rv=Zl._export_sfc(lv,[["__scopeId","data-v-177d64c3"]]),nu=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"}]),nv={TABLE:Bc,FORM:ks,STATICFORM:Nc,TABLEOPERATE:Yh,TABLESTYLE:p2,TABLEEXTEND:h2,TABLEINTERACTION:y2,FORMOPERATE:xs,FOLD:K2,CALCULATOR:Q2,METHODBUTTON:l4,AVATARUPLOAD:as.ssAvatar,SIGNATURE:as.ssSignature,FORMTOP:ks,STEP:h4,STEPOPERATE:$2,TIMELINE:k4,TIMELINEOPERATE:U2,FORMTOPOPERATE:xs,SIGNATUREOPERATE:d4,AVATARUPLOADOPERATE:i4,TABS:_4,TABSOPERATE:s6,CHART:w6,CHARTOPERATE:M6,LAYOUT:L6,LAYOUTOPERATE:q6,PARENTITEM:ev,RADIO:rv};function Bi(a){return nv[a==null?void 0:a.toUpperCase()]||null}exports.De=ru;exports.activeStepInfo=_i;exports.addContents=Ki;exports.addVisibleDialog=Dt;exports.affixItems=S0;exports.allMapContents=bt;exports.analyzeMenu=ac;exports.cacheNewData=xc;exports.clickMainKey=Sc;exports.clickSavePage=_0;exports.clickStep=Cc;exports.clickTrigger=_c;exports.compId=jn;exports.compNames=wc;exports.compShow=Di;exports.existLayouts=z0;exports.fixChangeValue=Et;exports.generateLayouts=s2;exports.getComponent=Bi;exports.getComponents=Gi;exports.getPageConstruct=Yd;exports.getPageData=Kr;exports.getSliceContLength=$0;exports.gridRowHeight=r2;exports.gridRowHeightHmPg=l2;exports.isStepLayout=Dc;exports.onBack=x0;exports.onButtonChange=B0;exports.onChange=No;exports.onClick=w0;exports.onClickStep=M0;exports.onContentChange=To;exports.onExtendTaskEnd=A0;exports.onOk=N0;exports.onPageBack=O0;exports.onPageChange=Ao;exports.onSelectFixContent=k0;exports.renderShowItems=bc;exports.showItems=tr;exports.sliceTableLength=kc;exports.slotContent=nu;exports.ssTable=Bc;exports.st=Mo;exports.stepItems=V0;exports.tabChange=I0;exports.toolBar=T0;exports.useFormComp=Ct;exports.useModelLoader=wf;exports.verifyButton=L0;
|