ss-component-new 1.2.210 → 1.2.211
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{MTLLoader-CMQuFz2U.js → MTLLoader-67H7fk80.js} +1 -1
- package/dist/{MTLLoader-Dn7qvdQE.cjs → MTLLoader-CL8XSHGp.cjs} +1 -1
- package/dist/{OrbitControls-BwOP9BCH.js → OrbitControls-C6M2yrLB.js} +1 -1
- package/dist/{OrbitControls-CKmqHTFG.cjs → OrbitControls-CnIsW8aw.cjs} +1 -1
- package/dist/{URDFLoader-LcNMUu2Q.cjs → URDFLoader-BX5IuzJ8.cjs} +1 -1
- package/dist/{URDFLoader-B4mwog0r.js → URDFLoader-DoVjA77Z.js} +2 -2
- package/dist/{animationData-CF8iySCX.js → animationData-BjKOHbzr.js} +1 -1
- package/dist/{animationData-CttWJgEw.cjs → animationData-DwRMSEcR.cjs} +1 -1
- package/dist/{array-D7pDQ0ai.cjs → array-CJjaF-30.cjs} +1 -1
- package/dist/{array-BjZvjLNf.js → array-Cmui25df.js} +1 -1
- package/dist/{iconfont-DLz03Pua.js → iconfont-C6xrTLDV.js} +2 -2
- package/dist/{iconfont-v_9e6_Wr.cjs → iconfont-alw7deIH.cjs} +1 -1
- package/dist/{index-D2BxLiKo.cjs → index-0ZaO0N8Y.cjs} +1 -1
- package/dist/{index-DXOFx4Js.js → index-3e98Utf1.js} +2 -2
- package/dist/{index-D5o0yFsY.js → index-B16xvnZZ.js} +1 -1
- package/dist/{index-BQcDZ9zY.cjs → index-B6eyscWd.cjs} +1 -1
- package/dist/{index-9ygxLpV4.cjs → index-BA5lzuZs.cjs} +1 -1
- package/dist/{index-CzgAT9P9.js → index-BJ607Cgr.js} +2 -2
- package/dist/{index-D9VJiqIr.js → index-BJ6EviJu.js} +1 -1
- package/dist/{index-CTXsrOke.js → index-BWYzx9On.js} +1 -1
- package/dist/{index-CTVosZpD.cjs → index-BXqsy0Nl.cjs} +1 -1
- package/dist/{index-P7IneBeG.js → index-BZWgeRjN.js} +3 -3
- package/dist/{index-dVe4jXXP.cjs → index-BiZxAQWz.cjs} +1 -1
- package/dist/index-BlzC7uD8.js +3577 -0
- package/dist/{index-rat8ooKP.cjs → index-BmVUsjsm.cjs} +1 -1
- package/dist/{index-C5mK6G4B.js → index-C251JILB.js} +8 -8
- package/dist/{index-CfvIJnQ4.js → index-CAi-JNl0.js} +1 -1
- package/dist/{index-Ccucb-4Z.cjs → index-CN4uUlDb.cjs} +1 -1
- package/dist/{index-C_IeP5sH.js → index-CqyCNXc9.js} +1 -1
- package/dist/{index-CZpCcMJo.cjs → index-Ct9aTte1.cjs} +1 -1
- package/dist/{index-C5rlnhuB.cjs → index-Ct_sBp18.cjs} +1 -1
- package/dist/index-CvD54iz8.cjs +1 -0
- package/dist/{index-DUWL4jpR.js → index-CwI3-CUs.js} +1 -1
- package/dist/{index-NSTwCJrr.cjs → index-D-nlJ3o0.cjs} +1 -1
- package/dist/{index-C6epDMmF.cjs → index-D737Q5uV.cjs} +1 -1
- package/dist/{index-DqpK4iid.js → index-D9R32sv-.js} +4 -4
- package/dist/index-DA6AZg6p.cjs +1 -0
- package/dist/{index-np8quoQc.cjs → index-DAkcroe-.cjs} +1 -1
- package/dist/{index-4xWViEpw.js → index-DBP65bJO.js} +1 -1
- package/dist/{index-Co21kVZ9.cjs → index-DEFMo4Ss.cjs} +1 -1
- package/dist/{index-BOo0k-6s.cjs → index-DHbfeZj9.cjs} +2 -2
- package/dist/{index-FamU_pWj.js → index-DOvORsix.js} +1 -1
- package/dist/{index-2kxli95n.cjs → index-DTCncP0c.cjs} +1 -1
- package/dist/{index-BFmB_GNc.js → index-DcxH1zsA.js} +1 -1
- package/dist/{index-O1tZfdsI.js → index-DgqJP4cy.js} +16 -16
- package/dist/{index-ywaZJRUe.js → index-DjhgSTgp.js} +1 -1
- package/dist/{index-Gx0qq15p.js → index-DlWLHCf4.js} +1 -1
- package/dist/{index-B3ES4Imr.cjs → index-DuLX_CSd.cjs} +1 -1
- package/dist/{index-DtC6p78s.cjs → index-Dymvy1ct.cjs} +1 -1
- package/dist/index-RlPP0mDo.js +12475 -0
- package/dist/{index-Dgk4f0E3.js → index-VDplKeDq.js} +4 -4
- package/dist/{index-CRPwb5Di.cjs → index-XIKgdyQI.cjs} +1 -1
- package/dist/{index-BV2AdsW7.js → index-bAoJwc65.js} +7 -7
- package/dist/{index-CZmf9W1N.cjs → index-d8S_KBKB.cjs} +1 -1
- package/dist/{index-BqLlm8pl.cjs → index-kFQ6-6dk.cjs} +1 -1
- package/dist/{index-BM6eQMuj.js → index-li-CtQ8f.js} +3 -3
- package/dist/{index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-B1f3iFI0.js → index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-BvTCBcSN.js} +8 -8
- package/dist/{index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-CLOMtzqw.cjs → index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-CMQ255im.cjs} +2 -2
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CgpQQnQo.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-Bz8QgjF-.js} +26750 -26754
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BbQEEyFK.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-DLa0ds0U.cjs} +265 -265
- package/dist/{index.vue_vue_type_style_index_0_scoped_140f5e74_lang-yEFItRs3.js → index.vue_vue_type_style_index_0_scoped_140f5e74_lang-2KtqLt8T.js} +4 -4
- package/dist/{index.vue_vue_type_style_index_0_scoped_140f5e74_lang-C5U5tv8m.cjs → index.vue_vue_type_style_index_0_scoped_140f5e74_lang-BQTgA0X7.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_1_lang-Qda9sMCN.js → index.vue_vue_type_style_index_1_lang-B3X_PfQc.js} +4 -4
- package/dist/{index.vue_vue_type_style_index_1_lang-D3s2wGtB.cjs → index.vue_vue_type_style_index_1_lang-YbKSvTqR.cjs} +2 -2
- package/dist/{main-B4kLVLRo.js → main-Cor_kytv.js} +3 -3
- package/dist/{main-ZKhN5hVB.cjs → main-DDz9fSdf.cjs} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +2 -2
- package/dist/ss-component.js +9 -9
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +10 -10
- package/dist/{threeModel-C6-ohRly.cjs → threeModel-2290Sh5Q.cjs} +1 -1
- package/dist/{threeModel-CCD_TCIt.js → threeModel-ml0tLJ6d.js} +4 -4
- package/dist/{threePreview--ajzp9ef.js → threePreview-2xz8Hw38.js} +3 -3
- package/dist/{threePreview-C_GqKG7E.cjs → threePreview-C3CVwE-Y.cjs} +1 -1
- package/dist/{threeSceneView-BuDjh1PW.cjs → threeSceneView-B4nKIou-.cjs} +1 -1
- package/dist/{threeSceneView-2SkyZMLQ.js → threeSceneView-DDpsp26F.js} +8 -8
- package/dist/{threeSceneViewForCPMPIP-BAHntlai.js → threeSceneViewForCPMPIP-9PDSLEqZ.js} +7 -7
- package/dist/{threeSceneViewForCPMPIP-PKZiN1Hi.cjs → threeSceneViewForCPMPIP-yuW3lgix.cjs} +1 -1
- package/dist/{threeTrackPathView-DQXfAyfj.js → threeTrackPathView-BH4W5aAJ.js} +3 -3
- package/dist/{threeTrackPathView-CaZJjtlj.cjs → threeTrackPathView-_RjI4stL.cjs} +1 -1
- package/dist/{threeViewerHost-BnEGRoC_.js → threeViewerHost-CdKrfyfa.js} +2 -2
- package/dist/{threeViewerHost-wJDeMzT0.cjs → threeViewerHost-Di0GKXwU.cjs} +1 -1
- package/dist/{urdfTree-CY-l53qd.js → urdfTree-DkFmyNMl.js} +1 -1
- package/dist/{urdfTree-Bvjb6fr9.cjs → urdfTree-MhNihTDQ.cjs} +1 -1
- package/dist/{workpieceTreePanel-WyflfVY-.js → workpieceTreePanel-BFPFWqV3.js} +4 -4
- package/dist/{workpieceTreePanel-Y4Qc_oSv.cjs → workpieceTreePanel-BeRnxO8B.cjs} +1 -1
- package/package.json +1 -1
- package/dist/index-CaHvkH1f.js +0 -3385
- package/dist/index-Cbbw4bt5.cjs +0 -1
- package/dist/index-DDJsccuu.cjs +0 -1
- package/dist/index-DZYnK5D6.js +0 -12425
- package/dist/obj/model.mtl +0 -42
- package/dist/obj/model.obj +0 -26110
- package/public/obj/model.mtl +0 -42
- package/public/obj/model.obj +0 -26110
package/dist/index-Cbbw4bt5.cjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const l=require("vue"),A=require("./index-DOItJqcJ.cjs"),de=require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BbQEEyFK.cjs"),Sl=require("./index-BOo0k-6s.cjs"),pr=require("./threeViewerHost-wJDeMzT0.cjs"),Ca=require("./index-CXC0u8pm.cjs"),Oo=require("./index.vue_vue_type_style_index_1_lang-D3s2wGtB.cjs"),Aa=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Il=require("./index-9ygxLpV4.cjs");require("./index-KaxOq1_-.cjs");const tr=require("./isString-Do5yyRUw.cjs"),Da=q=>q.match(/\((.*)\)/)[1],fr={__name:"index",props:{isVisible:{type:Boolean,default:!1},title:{type:String,default:""},placement:{type:String,default:"bottom"},width:{type:Number,default:200}},setup(q){const ce=q,oe=l.ref(null),z=l.ref(!1),V=l.ref(null);return l.watch(()=>ce==null?void 0:ce.isVisible,()=>{z.value=ce==null?void 0:ce.isVisible},{deep:!0,immediate:!0}),l.watch(()=>V.value,()=>{l.nextTick(()=>{var s,pe;(pe=(s=oe.value)==null?void 0:s.updatePopper)==null||pe.call(s)})},{deep:!0,immediate:!0}),(s,pe)=>{const Te=l.resolveComponent("el-popover");return l.openBlock(),l.createBlock(Te,{visible:z.value,title:ce==null?void 0:ce.title,placement:ce==null?void 0:ce.placement,width:ce==null?void 0:ce.width,ref_key:"popOverRef",ref:oe},{reference:l.withCtx(()=>[l.createElementVNode("div",null,[l.renderSlot(s.$slots,"reference",{ref_key:"referenceRef",ref:V})])]),default:l.withCtx(()=>[l.createElementVNode("div",null,[l.renderSlot(s.$slots,"content")])]),_:3},8,["visible","title","placement","width"])}}},wo={key:0,class:"extra-button-content"},Uo={class:"table-operator-wrap"},jo={key:0,class:"extra-button-filter"},Lo={class:"form-content-value"},Mo={key:1,class:"extra-header"},$o={class:"drop-menu",style:{width:"120px"}},Po={key:0},Fo={key:1},Ro={key:1,class:"extra-button-content tabs-button-wrapper"},Ko={class:"table-operator-wrap"},zo={class:"extra-button-filter"},Vo={class:"form-content-value"},qo={key:0,class:"extra-header"},Jo={class:"drop-menu",style:{width:"120px"}},Wo={key:0},Go={key:1},Ho={__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:()=>[]}},emits:["buttonClick","filter","getImportData"],setup(q,{emit:ce}){const oe=ce,z=q,V=l.ref(""),s=l.ref(!1),pe=l.ref([]),Te=l.ref([{label:"取消",background:"#999999"},{label:"清空",background:"#999999"},{label:"确认"}]),Pe=[{label:"新增",icon:"Plus"},{label:"导入",icon:"import"},{label:"导出",icon:"export"},{label:"OCR识别",icon:"ocr"}],Ae=me=>{const Oe=me.raw;if(!Oe)return;const Re=new FileReader;Re.onload=he=>{try{const Le=new Uint8Array(he.target.result),al=de.readSync(Le,{type:"array"}),Fe=al.SheetNames[0],ne=al.Sheets[Fe],rl=de.utils.decode_range(ne["!ref"]).e.c+1,X=new Array(rl).fill(""),T=[];for(const Q in ne){if(Q[0]==="!")continue;const{r:ve,c:Ee}=de.utils.decode_cell(Q);let ol=ne[Q].v;if(ne[Q].t==="n"&&ol>0&&ol<1e6&&(ol=new Date((ol-25569)*86400*1e3).toISOString().split("T")[0]),(ol==null||ol==="")&&(ol=""),ve===0)X[Ee]=ol;else{if(!T[ve-1]){T[ve-1]={};for(let Cl=0;Cl<rl;Cl++)T[ve-1][`col_${Cl}`]=""}T[ve-1][`col_${Ee}`]=ol}}for(let Q=0;Q<rl;Q++)X[Q]===void 0&&(X[Q]="");const Me=T==null?void 0:T[0];if(!(Me!=null&&Me.hasOwnProperty("col_0")))return A.ElMessage.error("导入的数据列不匹配,请检查是否错位");oe("getImportData",X,T)}catch(Le){throw A.ElMessage.error(Le.message),new Error(Le.message)}},Re.readAsArrayBuffer(Oe)},hl=me=>{var Re;const Oe=(Re=pe.value)==null?void 0:Re.reduce((he,Le,al)=>(al===0?he[Le.label]=me:he[Le.label]=Le==null?void 0:Le.value,he),{});oe("filter",Oe,me,!0)},Ol=me=>{oe("buttonClick",me)},Pl=me=>{var Oe,Re;pe.value=(Re=(Oe=de.getColumnChild(A.cloneDeep(me)))==null?void 0:Oe.filter(he=>(he==null?void 0:he.label)!==""&&(he==null?void 0:he.label)!=="操作"))==null?void 0:Re.map(he=>({label:(he==null?void 0:he.label)??"",value:"",name:(he==null?void 0:he.label)??"",isFormColHidden:he==null?void 0:he.isTableColHidden,width:2}))},wl=l.ref(!1),Fl=me=>{var Oe;if((me==null?void 0:me.buttonName)==="确认"&&(oe("filter",me==null?void 0:me.content),wl.value=(me==null?void 0:me.content)&&Object.values(me==null?void 0:me.content).length>0),(me==null?void 0:me.buttonName)==="清空"){const Re=A.cloneDeep(me==null?void 0:me.content);for(const he in Re)Re[he]="";pe.value=(Oe=pe.value)==null?void 0:Oe.map(he=>({...he,value:""})),oe("filter",Re),wl.value=!1}s.value=!1},ll=()=>{var Oe,Re;pe.value=(Oe=pe.value)==null?void 0:Oe.map(he=>({...he,value:""}));const me=(Re=pe.value)==null?void 0:Re.reduce((he,Le)=>(he[Le.label]=Le.value,he),{});oe("filter",me)};return l.onMounted(()=>{Pl(z.columns)}),l.watch(()=>z.columns,()=>{Pl(z.columns)},{deep:!0,immediate:!0}),(me,Oe)=>{var ne,I,rl,X;const Re=l.resolveComponent("el-icon"),he=l.resolveComponent("svg-icon"),Le=l.resolveComponent("el-input"),al=l.resolveComponent("el-button"),Fe=l.resolveComponent("el-upload");return q.pageLayout==="vertical"?(l.openBlock(),l.createElementBlock("div",wo,[l.createElementVNode("div",{class:l.normalizeClass(q.compName?"table-name-wrap":""),style:l.normalizeStyle({background:(z==null?void 0:z.level)>1?"transparent":"var(--ssgroup-background)",paddingLeft:((z==null?void 0:z.level)-1)*12+"px",fontWeight:600-((z==null?void 0:z.level)-1)*100>=400?600-((z==null?void 0:z.level)-1)*100:400,fontSize:17-(z==null?void 0:z.level)>=14?17-(z==null?void 0:z.level)+"px":"14px"})},l.toDisplayString(q.compName),7),l.createElementVNode("div",Uo,[z!=null&&z.filterShow?(l.openBlock(),l.createElementBlock("div",jo,[l.createVNode(fr,{title:"",width:800,placement:"bottom-start",isVisible:s.value},{reference:l.withCtx(()=>{var T,Me,Q,ve;return[l.createVNode(Le,{modelValue:V.value,"onUpdate:modelValue":Oe[1]||(Oe[1]=Ee=>V.value=Ee),style:{"min-width":"80px"},placeholder:wl.value?(Q=(Me=(T=q.filterValues)==null?void 0:T.filter(Ee=>Ee))==null?void 0:Me.slice(0,3))==null?void 0:Q.join("/"):"搜索","prefix-icon":l.unref(A.search_default),clearable:"",onInput:hl,disabled:((ve=pe.value)==null?void 0:ve.length)===0},{suffix:l.withCtx(()=>{var Ee,ol;return[!V.value&&((ol=(Ee=q.filterValues)==null?void 0:Ee.filter(Cl=>Cl))!=null&&ol.join("/"))?(l.openBlock(),l.createBlock(Re,{key:0,style:{cursor:"pointer"},onClick:ll},{default:l.withCtx(()=>[l.createVNode(l.unref(A.circle_close_default))]),_:1})):l.createCommentVNode("",!0)]}),append:l.withCtx(()=>[l.createElementVNode("span",{title:"条件查询",onClick:Oe[0]||(Oe[0]=Ee=>s.value=!s.value)},[l.createVNode(he,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]}),content:l.withCtx(()=>[l.createElementVNode("div",Lo,[(l.openBlock(),l.createBlock(Sl.ssForm,{rowContents:pe.value,buttonValue:Te.value,isRowFlex:!0,isEnableWrap:!1,isButtonRow:!1,key:Te.value,isStartJustify:!1,onOnButtonClick:Fl},null,8,["rowContents","buttonValue"]))])]),_:1},8,["isVisible"])])):l.createCommentVNode("",!0),q.buttons&&((ne=q.buttons)==null?void 0:ne.length)>0?(l.openBlock(),l.createElementBlock("div",Mo,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList((I=q.buttons)==null?void 0:I.filter(T=>q.isDevMode||(T==null?void 0:T.label)!=="修改模板"),(T,Me)=>(l.openBlock(),l.createElementBlock("div",{class:"extra-contents",key:Me},[(T==null?void 0:T.type)==="upload"?(l.openBlock(),l.createBlock(Fe,{key:0,class:"upload-button-wrap","on-change":Ae,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1,disabled:!!q.lockingPage},{default:l.withCtx(()=>[l.createVNode(al,{disabled:!!q.lockingPage,style:l.normalizeStyle({background:(T==null?void 0:T.background)??"var(--ssbutton-theme-bg)",color:(T==null?void 0:T.color)??"var(--ssbutton-theme-color)"})},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(T==null?void 0:T.label),1)]),_:2},1032,["disabled","style"])]),_:2},1032,["disabled"])):l.createCommentVNode("",!0),(T==null?void 0:T.type)==="popover"?(l.openBlock(),l.createBlock(Sl._sfc_main,{key:1},{dropTitle:l.withCtx(()=>[(T==null?void 0:T.type)==="popover"?(l.openBlock(),l.createBlock(al,{key:0,disabled:!!q.lockingPage,style:l.normalizeStyle({background:(T==null?void 0:T.background)??"var(--ssbutton-theme-bg)",color:(T==null?void 0:T.color)??"var(--ssbutton-theme-color)"})},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(T==null?void 0:T.label),1)]),_:2},1032,["disabled","style"])):l.createCommentVNode("",!0)]),dropMenu:l.withCtx(()=>[l.createElementVNode("div",$o,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(T==null?void 0:T.contents,Q=>(l.openBlock(),l.createBlock(al,{key:Q==null?void 0:Q.label,disabled:!!q.lockingPage,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:ve=>Ol(Q==null?void 0:Q.label)},{default:l.withCtx(()=>{var ve,Ee;return[l.createTextVNode(l.toDisplayString(Q==null?void 0:Q.label),1),(ve=Q==null?void 0:Q.label)!=null&&ve.includes("选中")?(l.openBlock(),l.createElementBlock("span",Po,"("+l.toDisplayString(q.selectNums)+")",1)):l.createCommentVNode("",!0),(Ee=Q==null?void 0:Q.label)!=null&&Ee.includes("全部")?(l.openBlock(),l.createElementBlock("span",Fo,"("+l.toDisplayString(q.dataNums)+")",1)):l.createCommentVNode("",!0)]}),_:2},1032,["disabled","onClick"]))),128))])]),_:2},1024)):l.createCommentVNode("",!0),T!=null&&T.type?l.createCommentVNode("",!0):(l.openBlock(),l.createBlock(al,{key:2,id:"themeButton",disabled:!!q.lockingPage,style:l.normalizeStyle({background:(T==null?void 0:T.background)??"var(--ssbutton-theme-bg)",color:(T==null?void 0:T.color)??"var(--ssbutton-theme-color)"}),onClick:Q=>Ol(T==null?void 0:T.label)},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(T==null?void 0:T.label),1)]),_:2},1032,["disabled","style","onClick"]))]))),128))])):l.createCommentVNode("",!0)])])):(l.openBlock(),l.createElementBlock("div",Ro,[l.createElementVNode("div",Ko,[l.createElementVNode("div",zo,[l.createVNode(fr,{title:"",width:800,placement:"bottom-start",isVisible:s.value},{reference:l.withCtx(()=>{var T,Me,Q,ve;return[l.createVNode(Le,{modelValue:V.value,"onUpdate:modelValue":Oe[3]||(Oe[3]=Ee=>V.value=Ee),style:{"min-width":"80px"},placeholder:wl.value?(Q=(Me=(T=q.filterValues)==null?void 0:T.filter(Ee=>Ee))==null?void 0:Me.slice(0,3))==null?void 0:Q.join("/"):"搜索","prefix-icon":l.unref(A.search_default),clearable:"",onInput:hl,disabled:((ve=pe.value)==null?void 0:ve.length)===0},{suffix:l.withCtx(()=>{var Ee,ol;return[!V.value&&((ol=(Ee=q.filterValues)==null?void 0:Ee.filter(Cl=>Cl))!=null&&ol.join("/"))?(l.openBlock(),l.createBlock(Re,{key:0,style:{cursor:"pointer"},onClick:ll},{default:l.withCtx(()=>[l.createVNode(l.unref(A.circle_close_default))]),_:1})):l.createCommentVNode("",!0)]}),append:l.withCtx(()=>[l.createElementVNode("span",{title:"条件查询",onClick:Oe[2]||(Oe[2]=Ee=>s.value=!s.value)},[l.createVNode(he,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]}),content:l.withCtx(()=>[l.createElementVNode("div",Vo,[(l.openBlock(),l.createBlock(Sl.ssForm,{rowContents:pe.value,buttonValue:Te.value,isRowFlex:!0,isEnableWrap:!1,isButtonRow:!1,key:Te.value,isStartJustify:!1,onOnButtonClick:Fl},null,8,["rowContents","buttonValue"]))])]),_:1},8,["isVisible"])]),q.buttons&&((rl=q.buttons)==null?void 0:rl.length)>0?(l.openBlock(),l.createElementBlock("div",qo,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList((X=q.buttons)==null?void 0:X.filter(T=>q.isDevMode||(T==null?void 0:T.label)!=="修改模板"),(T,Me)=>(l.openBlock(),l.createElementBlock("div",{class:"extra-contents",key:Me},[(T==null?void 0:T.type)==="upload"?(l.openBlock(),l.createBlock(Fe,{key:0,class:"upload-button-wrap","on-change":Ae,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1},{default:l.withCtx(()=>[l.createVNode(al,{style:{background:"transparent",color:"#666666"}},{icon:l.withCtx(()=>{var Q;return[l.createVNode(he,{name:(Q=Pe==null?void 0:Pe.find(ve=>(ve==null?void 0:ve.label)===(T==null?void 0:T.label)))==null?void 0:Q.icon},null,8,["name"])]}),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(T==null?void 0:T.label),1)]),_:2},1024)]),_:2},1024)):l.createCommentVNode("",!0),(T==null?void 0:T.type)==="popover"?(l.openBlock(),l.createBlock(Sl._sfc_main,{key:1},{dropTitle:l.withCtx(()=>[(T==null?void 0:T.type)==="popover"?(l.openBlock(),l.createBlock(al,{key:0,style:{background:"transparent",color:"#666666"}},{icon:l.withCtx(()=>{var Q;return[l.createVNode(he,{name:(Q=Pe==null?void 0:Pe.find(ve=>(ve==null?void 0:ve.label)===(T==null?void 0:T.label)))==null?void 0:Q.icon},null,8,["name"])]}),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(T==null?void 0:T.label),1)]),_:2},1024)):l.createCommentVNode("",!0)]),dropMenu:l.withCtx(()=>[l.createElementVNode("div",Jo,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(T==null?void 0:T.contents,Q=>(l.openBlock(),l.createBlock(al,{key:Q==null?void 0:Q.label,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:ve=>Ol(Q==null?void 0:Q.label)},{default:l.withCtx(()=>{var ve,Ee;return[l.createTextVNode(l.toDisplayString(Q==null?void 0:Q.label),1),(ve=Q==null?void 0:Q.label)!=null&&ve.includes("选中")?(l.openBlock(),l.createElementBlock("span",Wo,"("+l.toDisplayString(q.selectNums)+")",1)):l.createCommentVNode("",!0),(Ee=Q==null?void 0:Q.label)!=null&&Ee.includes("全部")?(l.openBlock(),l.createElementBlock("span",Go,"("+l.toDisplayString(q.dataNums)+")",1)):l.createCommentVNode("",!0)]}),_:2},1032,["onClick"]))),128))])]),_:2},1024)):l.createCommentVNode("",!0),T!=null&&T.type?l.createCommentVNode("",!0):(l.openBlock(),l.createBlock(al,{key:2,id:"themeButton",style:l.normalizeStyle({background:"transparent",color:(T==null?void 0:T.label)==="新增"?"var(--ssbutton-theme-bg)":"#666666"}),onClick:Q=>Ol(T==null?void 0:T.label)},{icon:l.withCtx(()=>{var Q;return[l.createVNode(he,{name:(Q=Pe==null?void 0:Pe.find(ve=>(ve==null?void 0:ve.label)===(T==null?void 0:T.label)))==null?void 0:Q.icon},null,8,["name"])]}),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(T==null?void 0:T.label),1)]),_:2},1032,["style","onClick"]))]))),128))])):l.createCommentVNode("",!0)])]))}}},Qo=Aa._export_sfc(Ho,[["__scopeId","data-v-03b0d8fa"]]),Xo=l.defineComponent({__name:"batch",props:{lockingPage:Boolean,buttons:{type:Array,default:()=>[]},selectTableItems:{type:Array,default:()=>[]},columns:{type:Array,default:()=>[]}},emits:["buttonClick"],setup(q,{emit:ce}){const oe=q,z=ce,V=pe=>{z("buttonClick",pe)},s=pe=>{var Te;return pe!=null&&pe.includes("删除")?((Te=oe.selectTableItems)==null?void 0:Te.length)>0?"warning-active-type":"warning-type":"default-type"};return(pe,Te)=>{const Pe=l.resolveComponent("el-button");return l.openBlock(),l.createElementBlock("div",null,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(q.buttons,Ae=>(l.openBlock(),l.createBlock(Pe,{key:Ae==null?void 0:Ae.label,disabled:!!q.lockingPage,class:l.normalizeClass(s(Ae==null?void 0:Ae.label)),onClick:hl=>V(Ae==null?void 0:Ae.label)},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(Ae==null?void 0:Ae.label),1)]),_:2},1032,["disabled","class","onClick"]))),128))])}}}),Io=Aa._export_sfc(Xo,[["__scopeId","data-v-70b12973"]]),hr=A.defineStore("formToTableComp",{state:()=>({selectArray:[],selectString:""}),actions:{setSelectArray(q){this.selectArray=q},setSelectString(q){this.selectString=q}}}),Yo={class:"calculator-content"},Zo={class:"calculator-child"},en={class:"calculator-child"},ln=l.defineComponent({__name:"calculator",setup(q){const ce=l.ref(),oe=l.ref();return l.onMounted(()=>{ce.value=[{type:"Upload",label:"输入",name:"input"}],oe.value=[{type:"Upload",label:"输出",name:"output"}]}),(z,V)=>(l.openBlock(),l.createElementBlock("div",Yo,[l.createElementVNode("div",Zo,[l.createVNode(Sl.ssForm,{rowContents:ce.value,isRowFlex:!0},null,8,["rowContents"])]),l.createElementVNode("div",en,[l.createVNode(Sl.ssForm,{rowContents:oe.value,isEdit:!1,isRowFlex:!0},null,8,["rowContents"])])]))}}),an=Aa._export_sfc(ln,[["__scopeId","data-v-73db0fe7"]]),Fa=(q,ce)=>{let oe=q,z=ce;return Array.isArray(oe)&&(oe=oe==null?void 0:oe.map((V,s)=>{if(Array.isArray(V)){let pe={};return V=V==null?void 0:V.forEach((Te,Pe)=>{var Ae;(Ae=z==null?void 0:z[Pe])!=null&&Ae.prop?pe[z[Pe].prop]=Te:Array.isArray(Te)&&(pe.children=Fa(Te,z))}),Object.assign(pe,{id:s})}else return V})),oe},yr=(q,ce,oe)=>{let z=q,V=ce;return z=z==null?void 0:z.map((s,pe)=>{var Te,Pe;return!Array.isArray(s)||!((Te=V==null?void 0:V[pe])!=null&&Te.label)&&!oe||(s.unshift(((Pe=V==null?void 0:V[pe])==null?void 0:Pe.label)??""),s.some(Ae=>Array.isArray(Ae))&&(s=s==null?void 0:s.map(Ae=>{var hl;return Array.isArray(Ae)&&(Ae=yr(Ae,(hl=V==null?void 0:V[pe])==null?void 0:hl.children,oe)),Ae}))),s}),z},rn=(q,ce,oe)=>{if(ce==="")return q==null?void 0:q.filter(z=>(z==null?void 0:z.id)!==oe);{const z=ce.split("-");return on(q,z,oe)}},on=(q,ce,oe)=>{let z=q,V=ce;return(V==null?void 0:V.length)===0?z=z==null?void 0:z.filter(s=>s.id!==oe):z=z==null?void 0:z.map(s=>(s.id.toString()===(V==null?void 0:V[0])&&(V==null||V.shift(),s=gr(s,V,oe)),s)),z},gr=(q,ce,oe)=>{var s,pe;let z=q,V=ce;return(V==null?void 0:V.length)===0?z.children=(s=z.children)==null?void 0:s.filter(Te=>Te.id!==oe):z.children=(pe=z.children)==null?void 0:pe.map(Te=>(Te.id.toString()===(V==null?void 0:V[0])&&(V==null||V.shift(),Te=gr(Te,V,oe)),Te)),z},nn=(q,ce,oe)=>{if(ce==="")return oe;{const z=ce.split("-");return sn(q,z,oe)}},sn=(q,ce,oe)=>{let z=q,V=ce;return(V==null?void 0:V.length)===0?z=oe:z=z==null?void 0:z.map(s=>(s.id.toString()===(V==null?void 0:V[0])&&(V==null||V.shift(),s=vr(s,V,oe)),s)),z},vr=(q,ce,oe)=>{var s;let z=q,V=ce;return(V==null?void 0:V.length)===0?z.children=oe:z.children=(s=z.children)==null?void 0:s.map(pe=>(pe.id.toString()===(V==null?void 0:V[0])&&(V==null||V.shift(),pe=vr(pe,V,oe)),pe)),z},br=A.defineStore("formComp",{state:()=>({objUrl:[],blobUrls:[]}),actions:{setObjUrl(q){this.objUrl=q},setBlobUrls(q){this.blobUrls=q}}}),un=200,cn="success",dn="",pn=[{证书类型:"检定证书",证书编号:"RG112024-03918",数据:{编号:"1",名称:"1","型号/规格":"1",出厂编号:"1",制造厂:"1",所属试验台:"1",所属系统:"1",对应子系统:"1",启用日期:"1",负责人:"1",使用状态:"1",使用寿命:"1",管理措施:"1"}},{证书类型:"检定证书",证书编号:"RG112024-03918",数据:{编号:"2",名称:"2","型号/规格":"2",出厂编号:"2",制造厂:"2",所属试验台:"2",所属系统:"2",对应子系统:"2",启用日期:"2",负责人:"2",使用状态:"2",使用寿命:"2",管理措施:"2"}}],tn={code:un,type:cn,message:dn,result:pn},Ta=async(q,ce)=>{var pe,Te,Pe,Ae,hl,Ol,Pl,wl,Fl,ll,me,Oe,Re,he,Le,al,Fe;let oe=(Te=(pe=A.cloneDeep(q))==null?void 0:pe.optionUrl)==null?void 0:Te.menuSelect,z=[];oe==null||oe.forEach(ne=>{});let V="",s=await de.menuToParent(oe);if(s==null||s.forEach(ne=>{var I,rl,X,T;(ne==null?void 0:ne.name)===(((T=(X=(rl=(I=A.cloneDeep(q))==null?void 0:I.optionUrl)==null?void 0:rl.groupSelect)==null?void 0:X[0])==null?void 0:T.replaceAll("'",""))??"")&&(V=ne==null?void 0:ne.id)}),ce){V=ce;const ne=await A.getInsofDataApi({id:V}),I=(Ol=(hl=(Ae=(Pe=ne==null?void 0:ne.data)==null?void 0:Pe.result)==null?void 0:Ae[0])==null?void 0:hl.key)==null?void 0:Ol.pageKey;s=await de.getItemData(I,sessionStorage.getItem("systemKey"),"")}if(V!==""){let ne;ce?ne=(Pl=s==null?void 0:s.find(X=>(X==null?void 0:X.id)===ce))==null?void 0:Pl.compData:ne=(wl=s==null?void 0:s.find(X=>{var T,Me,Q,ve;return(X==null?void 0:X.name)===(((Me=(T=q==null?void 0:q.groupSelect)==null?void 0:T.split(":"))==null?void 0:Me[0])||((ve=(Q=q==null?void 0:q.optionUrl)==null?void 0:Q.groupSelect)==null?void 0:ve[0]))}))==null?void 0:wl.compData;let I=(ll=(Fl=ne==null?void 0:ne.find(X=>(X==null?void 0:X.key)==="header"))==null?void 0:Fl.contents)==null?void 0:ll.map(X=>X==null?void 0:X.label);(Oe=(me=ne==null?void 0:ne.find(X=>(X==null?void 0:X.key)==="header"))==null?void 0:me.contents)!=null&&Oe.every(X=>Array.isArray(X))&&(I=(Le=de.getColumnChild((he=(Re=ne==null?void 0:ne.find(X=>(X==null?void 0:X.key)==="header"))==null?void 0:Re.contents)==null?void 0:he[0]))==null?void 0:Le.map(X=>X==null?void 0:X.prop));let rl=(Fe=(al=ne==null?void 0:ne.find(X=>(X==null?void 0:X.key)==="tableContents"))==null?void 0:al.contents)==null?void 0:Fe.map(X=>{if(Array.isArray(X))X=X==null?void 0:X.filter(T=>!(T!=null&&T.id));else{let T={};for(let Me in X)Me!=="id"&&(T[Me]=X==null?void 0:X[Me]);X=T}return X});rl==null||rl.forEach(X=>{Array.isArray(X)?z.push(de.getValueToObjectValue(X,I)):z.push(X)})}return z},fn={class:"table-content"},hn={class:"menu-config-wrap"},yn=["onClick"],gn={key:0,class:"viewport-wrap"},vn=["onClick"],bn={title:"选择显示列信息"},kn={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},mn=["title"],Sn={class:"col-operate-wrap"},xn={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},Cn={key:0,style:{display:"flex","justify-content":"center","align-items":"center"}},Dn={class:"pop-wrapper"},Tn={key:0,class:"file-list-pop"},An=["title","onClick"],Nn=["onClick"],En={class:"pop-view"},_n={class:"pop-wrapper"},Bn={class:"file-list-pop"},On=["title","onClick"],wn=["onClick"],Un=["onClick"],jn={class:"form-content"},Ln={key:0,class:"dialog-footer"},Mn={class:"dialog-footer"},$n={style:{display:"flex","justify-content":"space-between",width:"100%","align-items":"center"}},Pn=["title"],Fn={class:"icon",style:{display:"flex",gap:"8px"}},Rn={class:"dialog-footer"},Kn={class:"form-content"},zn={__name:"index",props:{pageLayout:{type:String,default:"vertical"},level:{type:Number,default:1},compName:{type:String,default:"",required:!1},compNames:{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:!1},allowOperate:{type:Boolean,default:!0},allMapContents:{type:Object,default:()=>{}}},emits:["getSliceContLength","clickMainKey","change","contentChange","onButtonClick","contentClick","pageChange","rowClick","routeUrl"],setup(q,{emit:ce}){var dr;const oe=l.ref([]),z=br(A.pinia),V=l.ref(null),s=q,pe=l.ref(s==null?void 0:s.allowSelect),Te=l.ref((dr=s==null?void 0:s.config)==null?void 0:dr.showIndex),Pe=l.ref(),Ae=l.ref(!0),hl=l.ref(!1),Ol=l.ref([{label:"排序",value:"sortable",checked:!1},{label:"筛选",value:"filterable",checked:!1},{label:"合计",value:"showSummary",checked:!1},{label:"编辑",value:"operable",checked:!1}]),Pl=de.useOriginalState(A.pinia);let wl="$R";const{originalPath:Fl}=A.storeToRefs(Pl),ll=Fl.value,me=l.ref(!1),Oe=l.ref(!1),Re=l.ref(!1),he=l.ref(!0),Le=l.ref([]),al=l.reactive({column:{},status:!1,text:"合计"}),Fe=l.reactive({currentPage:1,pageSize:10,total:0,pageSizes:[5,10,20,50,100]}),ne=ce,I=l.ref([]),rl=l.ref([]),X=l.reactive({prop:"",order:null}),T=l.ref([]),Me=l.ref(!1),Q=l.ref(!1),ve=l.ref(null),{isUseBackdrop:Ee,initTrackFileType:ol,getFileExtension:Cl,setData:Na,getFileInfo:Ra,getFilesInfo:kr}=pr.useThreeSystem(),Ea=l.ref([]),Rl=l.ref(!1),Vl=l.ref(),Ye=Ca.useMenuState(),{importLoading:qn,activeMenuPath:we,contentLoading:Jn,linkMenuInfo:mr}=A.storeToRefs(Ye),Sr=de.useTableComp(A.pinia),qe=Ca.useModelComp(A.pinia),{extraContents:Ue,cacheUpdatingData:Yl,tableViewContents:Zl,tableLoading:Wn,pageMapState:ql,lockingPage:ya}=A.storeToRefs(qe),Z=l.ref([]),$l=l.ref([]),Jl=l.ref(new Map);l.ref(!1);const Ul=l.ref("");l.ref();const ga=l.ref(!0),Wl=l.ref(0),Ka=l.ref(!0),yl=l.ref(""),jl=l.ref(!1),xr=l.ref({label:"查看三维模型"}),va=l.ref(!1),_a=l.ref(),xl=l.ref([]),Dl=l.ref([]),ba=l.ref(!1),ea=l.ref([]),Ll=l.ref([]),Tl=l.ref([]),be=l.ref([]),ka=l.ref(!1),la=l.ref(!1),Ml=l.ref([]),Cr=l.ref(null),Ba=l.ref(!1),Oa=l.ref([]),za=l.ref(""),wa=l.ref(""),aa=Oo.createOCRService(),Dr=l.computed(()=>aa.getConfig()),Al=l.ref(),cl=l.ref(),Tr=hr(A.pinia),ra=l.ref(),Ua=l.ref(0),Ar=de.useUnit(A.pinia),{selectIndex:Nr,selectMenu:oa,selectTitle:Gn}=A.storeToRefs(Ar),{selectString:Kl}=A.storeToRefs(Tr),Er=A.useLoginState(A.pinia),{loginUserInfo:Gl}=A.storeToRefs(Er),_r=l.ref(720),Nl=l.ref(!1),ma=l.ref(!1),El=l.ref([]),_l=l.ref(),na=l.ref(!0),Va=l.ref(!0),zl=l.ref([]),Br=l.inject("contentRef");l.provide("contentRef",Br),l.watch(()=>{var e;return(e=Z.value)==null?void 0:e.length},e=>{Fe.total=e}),l.watch(()=>Zl.value,async()=>{var c,t,i,f,v,N,S,D,j,E,L,d,O,$,M,k,_,m;if(((c=Zl.value)==null?void 0:c.length)===0||!((t=s==null?void 0:s.itemData)!=null&&t.find(B=>(B==null?void 0:B.key)==="columnPath"))||!((i=s==null?void 0:s.itemData)!=null&&i.find(B=>(B==null?void 0:B.key)==="pageColumn")))return;let e=(j=(D=(S=(N=(v=(f=s==null?void 0:s.itemData)==null?void 0:f.find(B=>(B==null?void 0:B.key)==="pageColumn"))==null?void 0:v.contents)==null?void 0:N.split("["))==null?void 0:S[1])==null?void 0:D.split("]"))==null?void 0:j[0],a=((O=(d=(L=(E=s==null?void 0:s.itemData)==null?void 0:E.find(B=>(B==null?void 0:B.key)==="pageColumn"))==null?void 0:L.contents)==null?void 0:d.split("["))==null?void 0:O[0])+((M=($=Zl.value)==null?void 0:$.find(B=>(B==null?void 0:B.key)===e))==null?void 0:M.value),o=((_=(k=s==null?void 0:s.itemData)==null?void 0:k.find(B=>(B==null?void 0:B.key)==="pageGroup"))==null?void 0:_.contents)??"",r=await de.getItemData(a,sessionStorage.getItem("systemKey"),""),n=(m=r==null?void 0:r.find(B=>(B==null?void 0:B.name)===(o===""?s==null?void 0:s.compName:o)))==null?void 0:m.compData;sr(n,s.allMapContents)},{deep:!0});const Or=async(e,a)=>{var o,r,n,c,t;try{const i=await A.getInsofDataApi({id:(s==null?void 0:s.parentTableId)||(s==null?void 0:s.index)});let f;((o=i==null?void 0:i.data)==null?void 0:o.code)===200&&(f=((n=(r=i==null?void 0:i.data)==null?void 0:r.result)==null?void 0:n[0])||null);const v={type:"data",pageKey:s!=null&&s.parentTableId?(c=f==null?void 0:f.key)==null?void 0:c.pageKey:we.value,tableId:(s==null?void 0:s.parentTableId)||(s==null?void 0:s.index),systemKey:sessionStorage.getItem("systemKey")},N=a==null?void 0:a.map(j=>{const E=Object.keys(j),L={};return E.forEach((d,O)=>{L[e[O]]=j[d]}),L}),S=N==null?void 0:N.map(j=>({key:v,value:{tableData:j}})),D=await A.batchAddInsofDataApi({dataList:S});((t=D==null?void 0:D.data)==null?void 0:t.code)===200?(qe.setRefreshCurStructure(!0),A.ElMessage.success("导入数据成功")):A.ElMessage.error("导入数据响应失败")}catch(i){throw A.ElMessage.error("导入数据处理失败"),new Error(i)}},wr=async e=>{var c,t,i,f,v,N,S;let a=rl.value;a!=null&&a.find(D=>(e==null?void 0:e.key)===(D==null?void 0:D.key))&&(a=a==null?void 0:a.filter(D=>(e==null?void 0:e.key)!==(D==null?void 0:D.key))),a.push({key:e==null?void 0:e.key,value:[(t=e==null?void 0:e.value)==null?void 0:t[((c=e==null?void 0:e.value)==null?void 0:c.length)-1]]});let o=be.value;o=o==null?void 0:o.map(D=>{var j,E;return(D==null?void 0:D.type)==="Select"&&(e==null?void 0:e.key)===(D==null?void 0:D.prop)&&Array.isArray(D.value)&&(j=D.value)!=null&&j.every(L=>typeof L=="string")&&(D.selectValue=(E=a==null?void 0:a.find(L=>(L==null?void 0:L.key)===(D==null?void 0:D.prop)))==null?void 0:E.value),D});let r=(f=(i=o==null?void 0:o.find(D=>(D==null?void 0:D.prop)===(e==null?void 0:e.key)))==null?void 0:i.optionUrl)==null?void 0:f.menuId,n=o==null?void 0:o.find(D=>(D==null?void 0:D.prop)===(e==null?void 0:e.key));if(r){let D=await Ta(n==null?void 0:n.optionUrl,r),j,E=Le.value,L=(S=(N=(v=be.value)==null?void 0:v.find(d=>{var O;return(O=n==null?void 0:n.optionUrl)==null?void 0:O.menuId}))==null?void 0:N.selectValue)==null?void 0:S[0];if(D==null||D.forEach(d=>{var O,$,M,k,_,m,B,b,H,F;if(r){let G=($=(O=be.value)==null?void 0:O.find(w=>{var ue,R;return((ue=n==null?void 0:n.optionUrl)==null?void 0:ue.menuId)===((R=w==null?void 0:w.optionUrl)==null?void 0:R.menuId)}))==null?void 0:$.prop,u=(k=(M=o==null?void 0:o.find(w=>(w==null?void 0:w.prop)===G))==null?void 0:M.selectValue)==null?void 0:k[0];G!=null&&G.includes("·")&&(G=(_=G==null?void 0:G.split("·"))==null?void 0:_[0],u=(H=(b=(B=e==null?void 0:e.value)==null?void 0:B[((m=e==null?void 0:e.value)==null?void 0:m.length)-1])==null?void 0:b.split(" "))==null?void 0:H[0]),E!=null&&E.find(w=>(w==null?void 0:w.value)===L)?j=(F=E==null?void 0:E.find(w=>(w==null?void 0:w.value)===L))==null?void 0:F.objectValue:d[G]===u&&(j=d)}}),j){let d=o;d=d==null?void 0:d.map(O=>{var $,M,k,_,m,B;return r&&(j!=null&&j[O==null?void 0:O.prop])&&yl.value==="新增"&&(O==null?void 0:O.prop)!==(n==null?void 0:n.prop)?O.value=(j==null?void 0:j[O==null?void 0:O.prop])||(j==null?void 0:j[(_=(k=(M=($=O==null?void 0:O.optionUrl)==null?void 0:$.groupSelect)==null?void 0:M[1])==null?void 0:k.replaceAll("[",""))==null?void 0:_.replaceAll("]","")]):O.value=(B=(m=be.value)==null?void 0:m.find(b=>(b==null?void 0:b.prop)===(O==null?void 0:O.prop)))==null?void 0:B.value,O}),be.value=d}}rl.value=a},Ur=async e=>{var a,o,r,n,c;if((a=e==null?void 0:e.toString())!=null&&a.includes(".txt")||(o=e==null?void 0:e.toString())!=null&&o.includes(".cpt")||(r=e==null?void 0:e.toString())!=null&&r.includes(".cyd")){const t=await A.axios.get(e,{responseType:"blob",headers:{"Content-Type":"application/json"}}),i=new Blob([t.data],{type:"application/octet-stream;charset=UTF-8"});let f=URL.createObjectURL(i);Vl.value=[{name:(c=e==null?void 0:e.split("/"))==null?void 0:c[((n=e==null?void 0:e.split("/"))==null?void 0:n.length)-1],blobUrl:f}],Rl.value=!0}};l.onBeforeUnmount(()=>{Va.value=!1;let e=Ua.value;Ua.value=e+1});const qa=l.computed(()=>{var r,n;const e=(Fe.currentPage-1)*Fe.pageSize,a=e+Fe.pageSize,o=(r=I.value)==null?void 0:r.find(c=>{var t;return(c==null?void 0:c.sortable)&&((t=c==null?void 0:c.label)==null?void 0:t.includes("时间"))});return o&&(X.order="descending",X.prop=o==null?void 0:o.prop),ne("getSliceContLength",Fe),(n=Z.value)==null?void 0:n.slice(e,a)}),jr=e=>{Fe.currentPage=e,ne("getSliceContLength",Fe)},Lr=e=>{var a;Fe.pageSize=e,e*Fe.currentPage>((a=Z.value)==null?void 0:a.length)&&(Fe.currentPage=1,Fe.pageSize=10,A.ElMessage.warning("分页无效,返回第一页")),ne("getSliceContLength",Fe)},Mr=(e,a)=>{var t,i;const o=(i=(t=I.value)==null?void 0:t.map(f=>f==null?void 0:f.prop))==null?void 0:i.filter(f=>f!=="operate");let r;const n=(e==null?void 0:e.length)===(o==null?void 0:o.length);if(e!=null&&e.includes("序号"))return A.ElMessage.error("导入的数据不需要包含序号列");if(r=n?e:e.slice(0,o==null?void 0:o.length),!(r==null?void 0:r.every(f=>o==null?void 0:o.find(v=>f===v))))return A.ElMessage.error("导入的数据表头不匹配");Or(r,a)},$r=(e,a)=>{var o;qe.setRefreshCurStructure(!1),((o=I.value)==null?void 0:o.length)===0||Mr(e,a)},Pr=(e,a,o,r)=>{const n=[],c=[],t=v=>Object.keys(v).length;for(const v in e)if(e[v]!==void 0){const N=e[v],S=[];for(const[D,j]of Object.entries(N))S.push(j),c.length<t(N)&&c.push(D);n.push(S)}n.unshift(c);const i=de.utils.aoa_to_sheet(n),f=de.utils.book_new();de.utils.book_append_sheet(f,i,r),de.writeFileSync(f,`${a}.xlsx`),El.value=[]},Sa=async(e,a,o,r=!1,n)=>{var c,t,i,f,v,N,S,D;try{qe.setRefreshCurStructure(!1);const j=await A.getInsofDataApi({id:s==null?void 0:s.index});if(((c=j==null?void 0:j.data)==null?void 0:c.code)===200){let E=(v=(f=(i=(t=j==null?void 0:j.data)==null?void 0:t.result)==null?void 0:i[0])==null?void 0:f.value)==null?void 0:v.pageData;r?E={...E,compData:(S=E==null?void 0:E.compData)==null?void 0:S.map(d=>{var O;return(d==null?void 0:d.key)==="header"?{...d,contents:(O=d==null?void 0:d.contents)==null?void 0:O.map($=>({...$,[e]:o}))}:d})}:E={...E,compData:(N=E==null?void 0:E.compData)==null?void 0:N.map(d=>{var O,$;return(d==null?void 0:d.key)==="header"?{...d,contents:(O=d==null?void 0:d.contents)==null?void 0:O.map(M=>(M==null?void 0:M.prop)===(a==null?void 0:a.prop)?{...M,[e]:o}:M)}:(d==null?void 0:d.key)==="tableToForm"&&n?{...d,contents:($=d==null?void 0:d.contents)==null?void 0:$.map(M=>(M==null?void 0:M.prop)===(a==null?void 0:a.prop)?{...M,[n]:o}:M)}:d})};const L=await A.updateInsofDataApi({id:s==null?void 0:s.index,value:{pageData:E}});((D=L==null?void 0:L.data)==null?void 0:D.code)===200?(A.ElMessage.success("编辑成功"),qe.setRefreshCurStructure(!0)):A.ElMessage.error("编辑响应失败")}}catch(j){A.ElMessage.error(j)}},Fr=async(e,a)=>{await Sa("label",a,e)},Rr=async(e,a)=>{await Sa("columnType",a,e,!1,"type")},Kr=()=>{Yl.value?Nl.value=!1:ur()},zr=e=>{El.value=e},Vr=(e,a)=>{_l.value===a?na.value=!1:na.value=!0,_l.value=a==null?void 0:a.changeProp},qr=e=>{if(!e)return;const{item:a,value:o}=e,r=be.value.find(n=>n.prop==a.prop);r&&r.contents.push({label:o,value:o})},ia=l.computed(()=>{var o,r,n;const e=(o=I.value)==null?void 0:o.some(c=>c==null?void 0:c.filterable);return document.documentElement.style.setProperty("--ssTable-header-filter-display",e?"inline-block":"none"),(n=(r=I.value)==null?void 0:r.filter(c=>(c==null?void 0:c.label)!=="操作"))==null?void 0:n.map(c=>({...c,filterable:!!(c!=null&&c.filterable),showSummary:!!(c!=null&&c.showSummary),operable:!!(c!=null&&c.operable)}))}),Jr=async(e,a,o)=>{const r=A.cloneDeep(I.value);await l.nextTick(),I.value=r==null?void 0:r.map(n=>(o==null?void 0:o.label)===(n==null?void 0:n.label)?{...n,[a]:e}:n),await Sa(a,o,e)},ja=async(e,a)=>{await Sa(a,null,e,!0)},Wr=()=>{jl.value=!1},Gr=e=>{ne("clickTrigger",e)},Ja=async e=>{var c,t,i,f,v,N,S,D,j,E,L,d,O,$,M;const a=e==null?void 0:e.row,o=e==null?void 0:e.rowData,r=e==null?void 0:e.suffix;if((c=a==null?void 0:a.toString())!=null&&c.includes(".urdf")||e!=null&&e.isUrdf||r!=null&&r.includes(".urdf")){if(a.includes(",")){A.ElMessage.error("当前版本仅允许单个urdf预览!");return}if(Ee(a)){const _={files:[Ra(a)],data:{}};Na(_);return}ea.value=[{url:a,extension:Cl(a)}],Q.value=!0,ve.value={data:A.cloneDeep(o)},Me.value=!0;return}let n=[];if((t=a==null?void 0:a.toString())!=null&&t.includes(".stl")||(i=a==null?void 0:a.toString())!=null&&i.includes(".STL")||(f=a==null?void 0:a.toString())!=null&&f.includes(".obj")||(v=a==null?void 0:a.toString())!=null&&v.includes(".mtl")){const k=(N=a==null?void 0:a.toString())==null?void 0:N.split(","),_=kr(k),m=_==null?void 0:_[0];if(Ee(m==null?void 0:m.extension)){Na({files:_,data:{}});return}ea.value=_,Q.value=!1,Me.value=!0;return}if((S=a==null?void 0:a.toString())!=null&&S.includes(".stl")||(D=a==null?void 0:a.toString())!=null&&D.includes(".STL")||(j=a==null?void 0:a.toString())!=null&&j.includes(".obj")||(E=a==null?void 0:a.toString())!=null&&E.includes(".mtl")||r!=null&&r.includes(".stl")||r!=null&&r.includes(".STL")||r!=null&&r.includes(".obj")||r!=null&&r.includes(".mtl")){let k,_=[],m={};if(Array.isArray(a)?k=a:k=a==null?void 0:a.split(","),k==null||k.forEach(B=>{B.includes(".mtl")?_.push(B):m.blob=m.blob?m.blob+","+B:B}),(_==null?void 0:_.length)>0&&(m.mtlBlobs=_),r&&(m.suffix=r),(d=(L=Object.values(m))==null?void 0:L[0])!=null&&d.includes("http:"))n.push(m);else{const B=new Blob([m.blob],{type:"application/octet-stream;charset=UTF-8"});let b=URL.createObjectURL(B),H="";(O=a==null?void 0:a.split("/"))==null||O.forEach((F,G)=>{var u;G===((u=a==null?void 0:a.split("/"))==null?void 0:u.length)-1&&(H=F)}),($=m.blob)!=null&&$.includes(".stl")&&(H=(H==null?void 0:H.replaceAll(">",""))+".urdf"),Vl.value=[{name:H,blobUrl:b}],Rl.value=!0}}else{const k=await A.axios.get(a,{responseType:"blob",headers:{"Content-Type":"application/json"}}),_=new Blob([k.data],{type:"application/octet-stream;charset=UTF-8"});let m=URL.createObjectURL(_),B="";if((M=a==null?void 0:a.split("/"))==null||M.forEach((b,H)=>{var F;H===((F=a==null?void 0:a.split("/"))==null?void 0:F.length)-1&&(B=b)}),Ee(B)){const b=ol(B),H=Ra(a);Na({files:[H],data:{trackFileType:b}});return}Vl.value=[{name:B,blobUrl:m}],Rl.value=!0}(n==null?void 0:n.length)>0&&z.setBlobUrls(n)},Hl=e=>{var r,n,c,t;if(e!=null&&e.downloadUrl)return e==null?void 0:e.name;const a=(t=(r=e==null?void 0:e.url)==null?void 0:r.split("."))==null?void 0:t[((c=(n=e==null?void 0:e.url)==null?void 0:n.split("."))==null?void 0:c.length)-1];return(e==null?void 0:e.name)+"."+a},Wa=async e=>{let a=null,o=null;if(e!=null&&e.downloadUrl){const n=await La(),c=Sl.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),t=await A.axios.post(e==null?void 0:e.url,null,{responseType:"blob",headers:{Authorization:n,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}).finally(()=>{c.close()}),i=new Blob([t.data],{type:"application/octet-stream;charset=UTF-8"});a=URL.createObjectURL(i),o=e==null?void 0:e.name}else{const n=await de.downloadAvatarApi({url:e==null?void 0:e.url});!e.url.toUpperCase().includes(".OBJ")&&!e.url.toUpperCase().includes(".STL")&&!e.url.toUpperCase().includes(".MTL")&&!e.url.toUpperCase().includes(".URDF")?(a=URL.createObjectURL(n.data),o=Hl(e)):a=e==null?void 0:e.url}if(Ee(a)){const n={row:`${a}`,suffix:Cl(o)};Ja(n);return}const r={name:o,blobUrl:a};Vl.value=[r],Rl.value=!0},Ga=async e=>{let a=null,o=null;if(e!=null&&e.downloadUrl){const c=await La(),t=await A.axios.post(e==null?void 0:e.url,null,{responseType:"blob",headers:{Authorization:c,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}),i=new Blob([t.data],{type:"application/octet-stream;charset=UTF-8"});a=URL.createObjectURL(i),o=e==null?void 0:e.name}else{const c=await de.downloadAvatarApi({url:e==null?void 0:e.url});a=URL.createObjectURL(c.data),o=Hl(e)}const r={name:o,blobUrl:a},n=document.createElement("a");n.href=r.blobUrl,n.download=r.name,n.style.display="none",document.body.appendChild(n),n.click(),setTimeout(()=>{document.body.removeChild(n)},100)},Hr=(e,a)=>{var r;if(Object.values(a).length===0)return;let o=e;return Object.values(a).find(n=>{var c,t,i;return((c=n==null?void 0:n.toString())==null?void 0:c.includes(".txt"))||((t=n==null?void 0:n.toString())==null?void 0:t.includes(".cpt"))||((i=n==null?void 0:n.toString())==null?void 0:i.includes(".obj"))})?o=[...e,xr.value]:(r=s==null?void 0:s.config)!=null&&r.allowMove&&(o=[...e,{label:"迁移"}]),o},Qr=(e,a={})=>[...e==null?void 0:e.values()].filter(o=>Object.keys(a).every(r=>{var t;const n=o[r],c=(t=a[r])==null?void 0:t.toLowerCase();return c&&n&&typeof n=="string"?n.toLowerCase().includes(c):!0})),Xr=()=>{hl.value=!0},Ha=l.ref([]),Ir=async(e,a,o=!1)=>{var r;if(e){if(qe.setTableLoading(!0),Ha.value=Object.values(e),e&&((r=Object.values(e))!=null&&r.every(n=>!n)))return Z.value=$l.value;if(o){Z.value=[...Jl.value.values()].filter(n=>Object.values(n).some(c=>typeof c=="string"?c==null?void 0:c.toLowerCase().includes(a==null?void 0:a.toLowerCase()):!1));return}Z.value=Qr(Jl.value,e),qe.setTableLoading(!1)}},Yr=async e=>{},Qa=async(e,a,o,r)=>{var n,c,t,i,f,v,N,S,D,j,E,L,d,O,$,M,k,_,m,B;if(ne("clickMainKey",o),(r==null?void 0:r.isExistChild)===!0){let b=(n=r==null?void 0:r.columnType)==null?void 0:n.prop,H=r==null?void 0:r.data;if(zl.value=await de.getItemData(we.value,sessionStorage.getItem("systemKey"),""),!zl.value){let G=(i=(t=(c=we.value)==null?void 0:c.split("/"))==null?void 0:t.filter((u,w)=>{var ue,R;return w!==((R=(ue=we.value)==null?void 0:ue.split("/"))==null?void 0:R.length)-1}))==null?void 0:i.join("/");zl.value=await de.getItemData(G,sessionStorage.getItem("systemKey"),"")}let F=(f=zl.value)==null?void 0:f.filter(G=>(G==null?void 0:G.name)===b);zl.value=F==null?void 0:F.map(G=>{var u;return G.compData=(u=G.compData)==null?void 0:u.map(w=>{var ue,R;return(w==null?void 0:w.key)==="tableContents"&&(ue=w==null?void 0:w.contents)!=null&&ue.every(C=>C==null?void 0:C.find(U=>U==null?void 0:U.id))&&(w.contents=(R=w==null?void 0:w.contents)==null?void 0:R.filter(C=>(C==null?void 0:C[1])===H)),w}),G}),ne("routeUrl",zl.value,{isEdit:!0,routerUrl:we.value});return}if((r==null?void 0:r.data)==="查看"&&(e!=null&&e.every(b=>(b==null?void 0:b.url)&&(b==null?void 0:b.name)))){let b=A.cloneDeep(e);b=await((v=A.cloneDeep(b))==null?void 0:v.map(async F=>{var w,ue,R,C;const G=await de.downloadAvatarApi({url:F==null?void 0:F.url});let u=URL.createObjectURL(G.data);return{name:(F==null?void 0:F.name)+"."+((C=(w=F==null?void 0:F.url)==null?void 0:w.split("."))==null?void 0:C[((R=(ue=F==null?void 0:F.url)==null?void 0:ue.split("."))==null?void 0:R.length)-1]),blobUrl:u}}));let H=await Promise.all(b);Vl.value=H,Rl.value=!0}if(A.cloneDeep(I.value),(r==null?void 0:r.isMainKey)===!0){Ye.setActiveMenuPath(void 0),qe.setRouteToChildPath(void 0),qe.setFixMenuStatus(!0);let b=(S=(N=s.itemData)==null?void 0:N.find(F=>(F==null?void 0:F.key)==="contentTableId"))==null?void 0:S.contents,H=(j=(D=s.itemData)==null?void 0:D.find(F=>(F==null?void 0:F.key)==="relatedFilter"))==null?void 0:j.index;if(H!==0){let F=(L=(E=I.value)==null?void 0:E[H])==null?void 0:L.prop;if((o==null?void 0:o[F])===(r==null?void 0:r.data)){let G=await A.getInsofDataApi({id:b}),u=(M=($=(O=(d=G==null?void 0:G.data)==null?void 0:d.result)==null?void 0:O[0])==null?void 0:$.key)==null?void 0:M.pageKey;Ye.setActiveMenuPath(u+"/"+(r==null?void 0:r.data))}else{let G=await A.getInsofDataApi({key:{pageKey:A.cloneDeep(we).value+"/"+(r==null?void 0:r.data),systemKey:sessionStorage.getItem("systemKey")}});((_=(k=G==null?void 0:G.data)==null?void 0:k.result)==null?void 0:_.length)>0&&Ye.setActiveMenuPath(A.cloneDeep(we).value+"/"+(r==null?void 0:r.data))}}else{let F=await A.getInsofDataApi({key:{pageKey:A.cloneDeep(we).value+"/"+(r==null?void 0:r.data),systemKey:sessionStorage.getItem("systemKey")}});((B=(m=F==null?void 0:F.data)==null?void 0:m.result)==null?void 0:B.length)>0&&Ye.setActiveMenuPath(A.cloneDeep(we).value+"/"+(r==null?void 0:r.data))}}},Zr=()=>{Rl.value=!1},eo=e=>{ne("rowClick",e)};l.watch(()=>s.changedContent,()=>{var o,r;if(!s.changedContent)return;let e=(o=Z.value)==null?void 0:o.map(n=>{var c;return n.id===((c=s.changedContent)==null?void 0:c.id)&&(n={...s.changedContent,id:s.changedContent.newId?s.changedContent.newId:s.changedContent.id},delete n.newId),n});const a=(r=s.itemData)==null?void 0:r.map(n=>((n==null?void 0:n.key)==="tableContents"&&(n.contents=e),n));Z.value=e,ne("contentChange",{contents:a,index:s.index}),ne("change",{content:e,index:s==null?void 0:s.index,buttonName:"",id:s==null?void 0:s.index})},{deep:!0,immediate:!0});const lo=()=>{},ao=async()=>{const e=we.value,a=sessionStorage.getItem("systemKey"),o=await de.getItemData(e,a,""),r=(o==null?void 0:o.find(i=>(i==null?void 0:i.name)==="方法明细"))||(o==null?void 0:o[0]),n=(r==null?void 0:r.compData)||[],c=n==null?void 0:n.find(i=>{const f=i==null?void 0:i.key;return f==="formContent"||f==="tableContents"});return c==null?void 0:c.contents},La=async()=>`Bearer ${A.Local.get("access-token")}`,ro=async(e,{token:a,inputData:o}={})=>await A.axios.post(e,o,{headers:{Authorization:a}}).catch(n=>(Ye.setImportLoading(!1),Promise.reject(n))),oo=e=>{var r;let a={};const o=[];return a.form={},(r=A.cloneDeep(e))==null||r.forEach((n,c)=>{var t,i,f,v,N,S,D,j,E,L,d,O,$,M;if((n==null?void 0:n.comp)==="Table"){(i=(t=n==null?void 0:n.compData)==null?void 0:t.find(B=>(B==null?void 0:B.key)==="header"))==null||i.contents;let k=(N=(v=(f=n==null?void 0:n.compData)==null?void 0:f.find(B=>(B==null?void 0:B.key)==="tableContents"))==null?void 0:v.contents)==null?void 0:N.map(B=>B.slice(1));(L=(E=(j=(D=(S=n==null?void 0:n.compData)==null?void 0:S.find(B=>(B==null?void 0:B.key)==="header"))==null?void 0:D.contents)==null?void 0:j[0])==null?void 0:E[0])==null||L.label;let _=(O=(d=n==null?void 0:n.compData)==null?void 0:d.find(B=>(B==null?void 0:B.key)==="header"))==null?void 0:O.contents,m=[];k==null||k.forEach(B=>{let b=[];B==null||B.forEach((H,F)=>{var u;let G={};((u=_[F])==null?void 0:u.label)!=="操作"&&(G[_[F].label]=H,b.push(G))}),m.push(b)}),a[n.name]=m}else{const k=(M=($=n.compData)==null?void 0:$.find(_=>(_==null?void 0:_.key)==="formContent"))==null?void 0:M.contents;k==null||k.forEach(_=>{var m,B;if(_.prop!==""){let b=_==null?void 0:_.value;Array.isArray(b)?b=((m=b==null?void 0:b[0])==null?void 0:m.oldUrl)||"http://222.92.178.198:62001/"+((B=b==null?void 0:b[0])==null?void 0:B.url):b=b.toString(),_={key:(_==null?void 0:_.prop)??(_==null?void 0:_.label),value:b},o.push(_)}})}}),a.form=de.getFormContents(o),a},no=e=>{const a=[],o=r=>{r&&typeof r=="object"&&!Array.isArray(r)?Object.values(r).forEach(o):a.push(r)};return o(e),a},io=async(e,a,o)=>{var _,m,B,b,H,F,G,u,w,ue,R;Ye.setImportLoading(!0),qe.setFreshContent(!1);let r=await ao().catch(C=>(Ye.setImportLoading(!1),Promise.reject(C)));r=r==null?void 0:r.filter(C=>{var U;return((U=C==null?void 0:C.find(le=>le==null?void 0:le.id))==null?void 0:U.id)===(a==null?void 0:a.id)});let n=de.getEqualChild([(_=I.value)==null?void 0:_.filter(C=>(C==null?void 0:C.label)!=="操作")]);const c=(B=(m=de.tableToForm(r,n))==null?void 0:m[0])==null?void 0:B.find(C=>{const U=C==null?void 0:C.key;return U==="Interface"||U==="方法体"}),t=c==null?void 0:c.value;if(!t){console.log("未搜索到isMain, 缺少算法执行接口"),Ye.setImportLoading(!1);return}const i=I.value?de.getEqualChild([I.value]):[],f=i.find(C=>{const U=C==null?void 0:C.prop;return U==="Input1"||U==="输入数据.输入1"||U==="样本输入数据"}),v=f==null?void 0:f.prop;let N=a==null?void 0:a[v];const S=await La().catch(C=>(Ye.setImportLoading(!1),Promise.reject(C)));let D=!0,j="";(b=I.value)==null||b.forEach(C=>{(C==null?void 0:C.prop)===v&&(D=!!(C!=null&&C.childPath),j=C==null?void 0:C.childPath)});let E="";if(D){let C=(F=(H=I.value)==null?void 0:H.find(fe=>(fe==null?void 0:fe.isMainKey)===!0))==null?void 0:F.prop;E=a==null?void 0:a[C];let U=j==null?void 0:j.split(ll),le=[];U==null||U.forEach((fe,te)=>{(U==null?void 0:U.length)-1===te&&le.push(E),le.push(fe)}),le=le==null?void 0:le[0];let ee=await de.getItemData(le,sessionStorage.getItem("systemKey"),""),Y=ee==null?void 0:ee.filter(fe=>(fe==null?void 0:fe.name)===v);Y=Y==null?void 0:Y.map(fe=>{var te;return fe.compData=(te=fe==null?void 0:fe.compData)==null?void 0:te.map(J=>{var ie;return(J==null?void 0:J.key)==="tableContents"&&(J.contents=(ie=J==null?void 0:J.contents)==null?void 0:ie.filter(je=>(je==null?void 0:je[1])===(a==null?void 0:a[v]))),J}),fe}),(!Y||(Y==null?void 0:Y.length)===0)&&(Y=ee,Y=Y==null?void 0:Y.map(fe=>{var te;return fe.compData=(te=fe==null?void 0:fe.compData)==null?void 0:te.map(J=>{var ie;return(J==null?void 0:J.key)==="tableContents"&&(J.contents=(ie=J==null?void 0:J.contents)==null?void 0:ie.filter(je=>{var g,K;return(je==null?void 0:je[1])===(a==null?void 0:a[(K=(g=I==null?void 0:I.value)==null?void 0:g[0])==null?void 0:K.prop])})),J}),fe})),N=oo(Y)}const L=await ro(t,{token:S,inputData:N}).catch(C=>(Ye.setImportLoading(!1),Promise.reject(C))),d=(G=L==null?void 0:L.data)==null?void 0:G.data,O=i.find(C=>(C==null?void 0:C.prop)==="Output1"),$=O==null?void 0:O.prop;let M=[],k=[];if(d&&((u=Object.values(d))==null?void 0:u.length)>0){let C=[];const U=new FormData,le=(w=no(d))==null?void 0:w.map(async Y=>{var fe,te;if(!Array.isArray(Y)&&(Y!=null&&Y.includes("http"))){let J=await A.axios.get(Y,{responseType:"blob"}),ie=(te=Y==null?void 0:Y.split("/"))==null?void 0:te[((fe=Y==null?void 0:Y.split("/"))==null?void 0:fe.length)-1];U.append("files",J.data,ie)}else C.push(Y)});if(await Promise.all(le),!de.isFormDataEmpty(U)){let Y=await de.uploadAmountApi(U),fe=(R=(ue=Y==null?void 0:Y.data)==null?void 0:ue.result)==null?void 0:R.map(te=>{var J,ie,je,g,K,re;return{name:(re=(K=(g=(J=te==null?void 0:te.url)==null?void 0:J.split("/"))==null?void 0:g[((je=(ie=te==null?void 0:te.url)==null?void 0:ie.split("/"))==null?void 0:je.length)-1])==null?void 0:K.split("."))==null?void 0:re[0],url:te==null?void 0:te.url}});C=[...C,...fe]}let ee={};for(let Y in a)Y!=="id"&&(ee[Y]=a[Y]);ee[$]=C,k.push({id:a==null?void 0:a.id,value:{tableData:ee}})}(k==null?void 0:k.length)>0&&await A.batchUpdateInsofDataApi({dataList:k}),(M==null?void 0:M.length)>0&&await A.batchAddInsofDataApi({dataList:M}),ca(!0),Ye.setImportLoading(!1),qe.setFreshContent(!0)},Xa=(e,a)=>(e=e==null?void 0:e.map(o=>{var r,n;return o!=null&&o.children&&((r=o.children)!=null&&r.find(c=>c.id===(a==null?void 0:a.id))?o.children=(n=o.children)==null?void 0:n.filter(c=>(c==null?void 0:c.id)!==(a==null?void 0:a.id)):o.children=Xa(o.children,a)),o}),e),Je=l.reactive({title:"迁移至",show:!1,width:"20%",selectRow:null,from:s==null?void 0:s.index,to:null,contents:[],formRules:{groupName:[{required:!0,message:"输入不能为空",trigger:"blur"},{validator:(e,a,o)=>{a===(s==null?void 0:s.index)?o(new Error("选择源不能和目标源一致")):o()}}]},buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"确认",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]}),so=()=>{Je.show=!1},uo=e=>{var a,o;if((e==null?void 0:e.buttonName)==="取消")return Je.show=!1;Je.to=e==null?void 0:e.content,!(!(s!=null&&s.index)||!((a=Je.to)!=null&&a.groupName))&&(s==null?void 0:s.index)!==((o=Je.to)==null?void 0:o.groupName)&&(ne("change",{buttonName:"迁移",value:{from:Je.from,to:Je.to,data:Je.selectRow}}),Je.show=!1)},co=e=>{if(e){if(!aa.validateFileSize(e.raw)){A.ElMessage.warning(`文件大小不能超过 ${Dr.value.maxSize}MB`);return}if(!aa.validateFileType(e.raw)){A.ElMessage.warning("请上传图片文件");return}}},po=async()=>{var e,a,o;if(Ml.value.length===0){A.ElMessage.warning("请先选择要上传的图片");return}la.value=!0;try{const r=Ml.value.map(async N=>{var j,E,L,d;const S=new FormData;S.append("file",N.raw,N.name);const D=await Sl.uploadFileApi(S);return{name:((E=(j=D==null?void 0:D.data)==null?void 0:j.result)==null?void 0:E.fileName)??N.name,url:((d=(L=D==null?void 0:D.data)==null?void 0:L.result)==null?void 0:d.url)??""}}),n=await Promise.all(r),c=aa.extractTableHeaders(I.value),i=!1?tn:await aa.recognize(n,c);console.log("OCR识别结果:",i);const f=Array.isArray(i==null?void 0:i.result)?i.result:[];let v=[];if(f.length>0){const N=(e=de.getAllLeafNodes(I.value)||[])==null?void 0:e.filter(E=>(E==null?void 0:E.type)!=="operate"&&(E==null?void 0:E.label)!=="操作"&&(E==null?void 0:E.prop)!=="operate"),S=new Map;N==null||N.forEach(E=>{E!=null&&E.label&&(E!=null&&E.prop)&&S.set(E.label,E.prop)});const D=Date.now(),j=E=>`${D}_${E}`;v=f.map((E,L)=>{const d=E!=null&&E.数据&&typeof(E==null?void 0:E.数据)=="object"?E.数据:{},O={id:j(L),_isOCRRow:!0};for(const[$,M]of S.entries())Object.prototype.hasOwnProperty.call(d,$)&&(O[M]=d[$]);return O}),Z.value=[...Z.value||[],...v],$l.value=[...$l.value||[],...v],v.forEach(E=>{var L,d;return(d=(L=Jl.value)==null?void 0:L.set)==null?void 0:d.call(L,E.id,E)}),ra.value=Z.value}A.ElMessage.success(`成功上传 ${n.length} 张图片并完成OCR识别`),ne("change",{content:Z.value,index:s==null?void 0:s.index,type:"ocrRecognitionCompleted",buttonName:"OCR识别完成",uploadedFiles:n,ocrResult:i,column:I.value}),ka.value=!1,Ml.value=[]}catch(r){console.error("OCR处理失败:",r),A.ElMessage.error(((o=(a=r==null?void 0:r.response)==null?void 0:a.data)==null?void 0:o.message)||"OCR识别失败,请重试")}finally{la.value=!1}},Ia=()=>{ka.value=!1,Ml.value=[],Cr.value=null},to=async e=>{za.value=e==null?void 0:e.name;const a=e.raw;wa.value=URL.createObjectURL(a),Oa.value=[{name:za.value,blobUrl:wa.value}],Ba.value=!0},fo=()=>{Ba.value=!1,Oa.value=[],wa.value=""},ho=e=>{Ml.value=Ml.value.filter((a,o)=>o!==e)},xa=async(e,a,o)=>{var r,n,c,t,i,f,v,N,S,D,j,E,L,d,O;if(Ul.value="",ba.value=!0,ga.value=!0,ne("onButtonClick",e,a),Le.value=[],e==="删除")Ca.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var $,M;($=Z.value)!=null&&$.find(k=>(k==null?void 0:k.id)===(a==null?void 0:a.id))?Z.value=(M=A.cloneDeep(Z.value))==null?void 0:M.filter(k=>(k==null?void 0:k.id)!==(a==null?void 0:a.id)):Z.value=Xa(A.cloneDeep(Z.value),a),rn(ra.value,oa.value,a==null?void 0:a.id),qe.setTableLoading(s==null?void 0:s.index),ne("change",{content:Z.value,singleContent:a,index:s==null?void 0:s.index,type:"delete",buttonName:e,column:I.value})});else if(e==="批量删除"){if(((r=El.value)==null?void 0:r.length)===0)return A.ElMessage.warning("请先勾选操作的数据");Ca.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var M,k;const $=(M=El.value)==null?void 0:M.map(_=>_.id);Z.value=(k=A.cloneDeep(Z.value))==null?void 0:k.filter(_=>!($!=null&&$.includes(_.id))),qe.setTableLoading(s==null?void 0:s.index),ne("change",{content:Z.value,singleContent:null,selectItems:El.value,index:s==null?void 0:s.index,type:"batchDelete",buttonName:e,column:I.value})})}else if(e==="复制新增"){yl.value="新增";const $=A.cloneDeep(a),M=(n=I.value)==null?void 0:n.find(m=>m==null?void 0:m.isMainKey),k=M||((c=I.value)==null?void 0:c[0]),_=(t=Tl.value)==null?void 0:t.find(m=>(m==null?void 0:m.label)==="新建");await Za(!0,_,{data:$,firstCol:k})}else if(e==="新增")yl.value="新增",ua(""),jl.value=!0;else if(e==="编辑")yl.value="编辑",ua(a),jl.value=!0;else if(e==="查看")yl.value="查看",ua(a),ba.value=!1,ga.value=!1,jl.value=!0;else if(e==="查看三维模型"){const $={};for(let k in a)k!=="id"&&($[k]=a[k]);let M=(i=Object.values($))==null?void 0:i[1];Sr.setTableShowThree(M)}else if(((f=o==null?void 0:o.extra)==null?void 0:f.type)==="modelExample")yl.value=e,va.value=!0;else if(e==="新建"){let $=ql.value,M=[];for(let b in $)b!=null&&b.includes(`loading${((v=Gl.value)==null?void 0:v.account)||((N=Gl.value)==null?void 0:N.账号)}`)&&(M=[...M,...b]);let k=[];for(let b in $)b!=null&&b.includes(`updateLoading${((S=Gl.value)==null?void 0:S.account)||((D=Gl.value)==null?void 0:D.账号)}`)&&(k=[...k,...b]);let _=M==null?void 0:M.map(b=>b==null?void 0:b.id);const m=k==null?void 0:k.map(b=>b==null?void 0:b.id);_=[...A.cloneDeep(_),...m],(_==null?void 0:_.length)>0&&(_!=null&&_.every(b=>b!==null&&b))&&await A.batchDeleteInsofDataApi({ids:_});const B=(j=Tl.value)==null?void 0:j.find(b=>(b==null?void 0:b.label)==="新建");await Za(!1,B)}else if(e==="修改模板"){let $=A.cloneDeep(we).value;qe.setRouteToChildPath($),Ye.setActiveMenuPath($+ll)}else if(e==="执行")io(e,a);else if(e!=null&&e.includes("导出")){if(e==="导出选中"&&((E=El.value)==null?void 0:E.length)===0)return A.ElMessage.warning(`请先勾选${e}的数据`);if(e==="导出全部"&&((L=Z.value)==null?void 0:L.length)===0)return A.ElMessage.warning("暂无数据导出");const $=(O=(d=I.value)==null?void 0:d.map(k=>k==null?void 0:k.label))==null?void 0:O.filter(k=>k!=="操作"),M=e==="导出全部"?A.cloneDeep(Z.value):A.cloneDeep(El.value);M==null||M.forEach(k=>{k==null||delete k.id}),Pr(M,s==null?void 0:s.compName,$,s==null?void 0:s.compName)}else e==="OCR识别"?(ka.value=!0,Ml.value=[]):e==="迁移"&&(Je.selectRow=a,Je.show=!0)},yo=async e=>{var o,r,n,c,t,i;const a=await A.getInsofDataApi({key:{pageKey:e,type:"structure",systemKey:sessionStorage.getItem("systemKey")}});if(((o=a==null?void 0:a.data)==null?void 0:o.code)===200)return Array.isArray((r=a==null?void 0:a.data)==null?void 0:r.result)&&((c=(n=a==null?void 0:a.data)==null?void 0:n.result)==null?void 0:c.length)>0?(i=(t=a==null?void 0:a.data)==null?void 0:t.result)==null?void 0:i.map(f=>{var v;return{id:f==null?void 0:f.id,...(v=f==null?void 0:f.value)==null?void 0:v.pageData}}):[]},go=async(e,a)=>{var o,r,n,c,t,i,f,v,N,S,D,j,E,L,d,O,$,M,k,_;try{let m,B;const b=(o=ql.value[we.value+ll])==null?void 0:o.filter(C=>{var U;return((U=C==null?void 0:C.key)==null?void 0:U.type)==="structureMethod"}),H=(r=ql.value[we.value+ll])==null?void 0:r.filter(C=>{var U;return((U=C==null?void 0:C.key)==null?void 0:U.type)==="structure"}),F=b==null?void 0:b.find(C=>{var U,le;return((le=(U=C==null?void 0:C.value)==null?void 0:U.pageData)==null?void 0:le.method)==="保存"});if(!F)return;const G=(i=(t=ql.value[(c=(n=F==null?void 0:F.value)==null?void 0:n.pageData)==null?void 0:c.path])==null?void 0:t.filter(C=>{var U;return((U=C==null?void 0:C.key)==null?void 0:U.type)==="data"}))==null?void 0:i.find(C=>{var U,le,ee,Y;return((le=(U=C==null?void 0:C.value)==null?void 0:U.tableData)==null?void 0:le.算法名称)===((Y=(ee=F==null?void 0:F.value)==null?void 0:ee.pageData)==null?void 0:Y.method)});if(!G)return;const u={buttonName:(v=(f=F==null?void 0:F.value)==null?void 0:f.pageData)==null?void 0:v.method,api:(S=(N=G==null?void 0:G.value)==null?void 0:N.tableData)==null?void 0:S.算法体,content:H==null?void 0:H.map(C=>{var U;return(U=C==null?void 0:C.value)==null?void 0:U.pageData}),extraContent:[],extraValues:(j=(D=F==null?void 0:F.value)==null?void 0:D.pageData)==null?void 0:j.data,methodName:(L=(E=F==null?void 0:F.value)==null?void 0:E.pageData)==null?void 0:L.path};if(!e)return;const w={...e,compData:(d=e==null?void 0:e.compData)==null?void 0:d.map(C=>{var U;return(C==null?void 0:C.key)==="formContent"?{...C,contents:(U=C==null?void 0:C.contents)==null?void 0:U.map(le=>(le==null?void 0:le.prop)===a?{...le,value:""}:le)}:C})},ue={key:{pageKey:we.value+ll,parentTable:"",systemKey:sessionStorage.getItem("systemKey"),type:"structure"},value:{pageData:w}},R=await A.axios.post(u.api,ue,{headers:{"Content-Type":"application/json"}});return((O=R==null?void 0:R.data)==null?void 0:O.code)===200&&(m=(M=($=R==null?void 0:R.data)==null?void 0:$.result)==null?void 0:M.latestReportCode,B=(_=(k=R==null?void 0:R.data)==null?void 0:k.result)==null?void 0:_.status),{newMainKeyValue:m,newStatus:B}}catch(m){throw A.ElMessage.error(m),new Error(m)}},Ya=(e,a,o,r)=>{var n;ne("contentChange",{contents:(n=e==null?void 0:e.compData)==null?void 0:n.map(c=>{var t;return(c==null?void 0:c.key)==="formContent"?{...c,contents:(t=c==null?void 0:c.contents)==null?void 0:t.map(i=>(i==null?void 0:i.key)===a?{...i,value:o}:sa.value&&(i==null?void 0:i.prop)===sa.prop?{...i,value:sa.value}:i)}:c}),index:e==null?void 0:e.id},r)},sa=l.reactive({prop:"状态",value:""}),vo=l.ref(["系统自动生成信息","审批意见"]),bo=async(e,a,o)=>{var f,v;let r=e==null?void 0:e[a==null?void 0:a.prop],n=1,c,t;const i=A.cloneDeep(we).value+ll+r;if(i){sa.value="",c=(f=ql.value[i])==null?void 0:f.filter(D=>{var j;return((j=D==null?void 0:D.key)==null?void 0:j.type)==="structure"});const N=c==null?void 0:c.find(D=>{var j,E,L;return((L=(E=(j=D==null?void 0:D.value)==null?void 0:j.pageData)==null?void 0:E.comp)==null?void 0:L.toUpperCase())==="FORM"});t={...(v=N==null?void 0:N.value)==null?void 0:v.pageData,id:N==null?void 0:N.id};const S=await go(t,a==null?void 0:a.prop);if(sa.value=S==null?void 0:S.newStatus,S!=null&&S.newMainKeyValue)return S==null?void 0:S.newMainKeyValue}if(Z.value.some(N=>(N==null?void 0:N[a==null?void 0:a.prop])===r)){const N=r;for(;Z.value.some(S=>(S==null?void 0:S[a==null?void 0:a.prop])===`${N}(${n})`);)n++;r=`${N}(${n})`}return r},Za=async(e,a,o)=>{var t,i,f,v,N,S,D,j;let r,n;const c=await bo(o==null?void 0:o.data,o==null?void 0:o.firstCol);if(e?(r=A.cloneDeep(we).value+ll+((v=o==null?void 0:o.data)==null?void 0:v[(f=o==null?void 0:o.firstCol)==null?void 0:f.prop]),n=A.cloneDeep(we).value+ll+c):(r=A.cloneDeep(we).value+ll,n=A.cloneDeep(r)+`loading${((t=Gl.value)==null?void 0:t.account)||((i=Gl.value)==null?void 0:i.账号)}`),a){const E=(S=(N=ql.value[n])==null?void 0:N.filter(L=>{var d;return((d=L==null?void 0:L.key)==null?void 0:d.parentTable)===""}))==null?void 0:S.map(L=>{var d;return{id:L==null?void 0:L.id,...(d=L==null?void 0:L.value)==null?void 0:d.pageData}});if((E==null?void 0:E.length)>0)if(e){const L=E==null?void 0:E.find(d=>{var O;return((O=d==null?void 0:d.comp)==null?void 0:O.toUpperCase())==="FORM"});L&&Ya(L,(D=o==null?void 0:o.firstCol)==null?void 0:D.label,c,we.value)}else qe.setRouteToChildPath(A.cloneDeep(we).value),Ye.setActiveMenuPath(n);else if(await de.loadingConstruct(r,n,null,null,e?vo.value:null),e){const L=await yo(n);if((L==null?void 0:L.length)>0){const d=L==null?void 0:L.find(O=>{var $;return(($=O==null?void 0:O.comp)==null?void 0:$.toUpperCase())==="FORM"});d&&Ya(d,(j=o==null?void 0:o.firstCol)==null?void 0:j.label,c,we.value)}}else qe.setRouteToChildPath(A.cloneDeep(we).value),Ye.setActiveMenuPath(n)}else e?(Ul.value="",cl.value=o==null?void 0:o.data,ca(!0,o==null?void 0:o.firstCol,c)):(qe.setRouteToChildPath(A.cloneDeep(we).value),Ye.setActiveMenuPath(n))},ko=()=>{Me.value=!1,ea.value=[],Q.value=!1},ua=e=>{var t,i,f,v,N,S,D,j,E,L,d,O,$,M,k,_,m,B,b,H,F,G;const a=[];let o=[];for(let u in e)Array.isArray(e==null?void 0:e[u])&&o.push(u);T.value=A.cloneDeep(I.value),(i=de.getColumnChild((t=A.cloneDeep(I.value))==null?void 0:t.filter(u=>(u==null?void 0:u.label)!=="操作")))==null||i.forEach((u,w)=>{var ue,R,C;o.find(U=>U===(u==null?void 0:u.prop))||(u!=null&&u.formType&&((ue=u==null?void 0:u.formType)==null?void 0:ue.toUpperCase())==="SELECT"||u!=null&&u.menuId?a.push({label:(R=u==null?void 0:u.prop)!=null&&R.includes(".")?u==null?void 0:u.prop:(u==null?void 0:u.label)||(u==null?void 0:u.prop)||"",name:(u==null?void 0:u.prop)??"t"+w,prop:u==null?void 0:u.prop,type:"Select",value:(e==null?void 0:e[u==null?void 0:u.prop])??(u==null?void 0:u.value)??"",id:(u==null?void 0:u.id)??w,contents:(u==null?void 0:u.options)??[],width:1,isFormColHidden:u==null?void 0:u.isFormColHidden,relatedValueId:u==null?void 0:u.relatedValueId,disabled:u==null?void 0:u.disabled,optionUrl:{groupSelect:u==null?void 0:u.groupSelect,menuSelect:u==null?void 0:u.formMenuSelect,type:"Select",selectRelateType:u==null?void 0:u.selectRelateType,allSelectionContents:(u==null?void 0:u.allSelectionContents)??[],selectFilter:u==null?void 0:u.selectFilter,menuId:u==null?void 0:u.menuId,filterContent:u==null?void 0:u.filterContent}}):a.push({label:(C=u==null?void 0:u.prop)!=null&&C.includes(".")?u==null?void 0:u.prop:(u==null?void 0:u.label)||(u==null?void 0:u.prop)||"",prop:u==null?void 0:u.prop,name:(u==null?void 0:u.prop)??"t"+w,type:!(u!=null&&u.formType)||(u==null?void 0:u.formType)===""?"Input":u==null?void 0:u.formType,value:(e==null?void 0:e[u==null?void 0:u.prop])??(u==null?void 0:u.value)??"",id:(u==null?void 0:u.id)??w,contents:(u==null?void 0:u.options)??[],width:1,isFormColHidden:u==null?void 0:u.isFormColHidden,disabled:u==null?void 0:u.disabled,relatedValueId:u==null?void 0:u.relatedValueId}))}),e===""||!e||(Ul.value=(e==null?void 0:e.id)??"");let r=de.getColumnChild((f=A.cloneDeep(I.value))==null?void 0:f.filter(u=>(u==null?void 0:u.label)!=="操作"));xl.value&&((v=xl.value)==null?void 0:v.length)>0&&(xl.value=(N=A.cloneDeep(xl).value)==null?void 0:N.map(u=>{var ue;let w=(u==null?void 0:u.prop)||((ue=r==null?void 0:r.find(R=>(R==null?void 0:R.label)===(u==null?void 0:u.label)))==null?void 0:ue.prop);return w&&(u.value=e[w]),u})),be.value=xl.value&&((S=xl.value)==null?void 0:S.length)>0?de.getTableFormToForm(xl.value):a;let n=[],c=(D=s.itemData)==null?void 0:D.filter(u=>(u==null?void 0:u.key)==="filterAllType");if((c==null?void 0:c.length)>0&&(n=(c==null?void 0:c.map(w=>w==null?void 0:w.value)).flat()),(n==null?void 0:n.length)>0){let u=(E=n==null?void 0:n.filter(R=>{var C;return(C=R==null?void 0:R.content)==null?void 0:C.includes("@Type")}))==null?void 0:E[((j=n==null?void 0:n.filter(R=>{var C;return(C=R==null?void 0:R.content)==null?void 0:C.includes("@Type")}))==null?void 0:j.length)-1];if(u!=null&&u.content){let R=(O=(d=(L=u==null?void 0:u.content)==null?void 0:L.replace(":",wl))==null?void 0:d.split(wl))==null?void 0:O[1];if((($=R==null?void 0:R.trim())==null?void 0:$.toUpperCase())==="MANUAL"){let C=(B=(m=(M=s.itemData)==null?void 0:M.filter(U=>(U==null?void 0:U.key)==="contentTableId"))==null?void 0:m[((_=(k=s.itemData)==null?void 0:k.filter(U=>(U==null?void 0:U.key)==="contentTableId"))==null?void 0:_.length)-1])==null?void 0:B.contents;be.value=(b=be.value)==null?void 0:b.map((U,le)=>{var ee,Y;return(ee=U==null?void 0:U.optionUrl)!=null&&ee.menuId&&(U.type="Select",(Y=U==null?void 0:U.optionUrl)!=null&&Y.menuId&&(U.optionUrl.menuId=U.optionUrl.menuId??C,U.optionUrl.menuFilter=n,yl.value==="新增"&&(U.optionUrl.multiple=!0,U.optionUrl.multipleLimit=5))),U})}}let w=(H=be.value)==null?void 0:H.filter(R=>{var C,U;return((C=R==null?void 0:R.optionUrl)==null?void 0:C.menuId)&&((U=R==null?void 0:R.optionUrl)==null?void 0:U.menuId)!==""}),ue;if(w==null||w.forEach(R=>{var U,le;if(ue!==void 0)return;let C=(U=R==null?void 0:R.optionUrl)==null?void 0:U.menuId;((le=w==null?void 0:w.filter(ee=>{var Y;return((Y=ee==null?void 0:ee.optionUrl)==null?void 0:Y.menuId)===C}))==null?void 0:le.length)>1&&(ue=C)}),w=w==null?void 0:w.filter(R=>{var C;return((C=R==null?void 0:R.optionUrl)==null?void 0:C.menuId)===ue}),(w==null?void 0:w.length)>1){let R=w==null?void 0:w.map(ee=>ee==null?void 0:ee.prop),C=w==null?void 0:w.map(ee=>ee==null?void 0:ee.label),U=w==null?void 0:w.map(ee=>ee==null?void 0:ee.value),le=(F=A.cloneDeep(w))==null?void 0:F[0];le.label=C==null?void 0:C.join("·"),le.value=U==null?void 0:U.join(" "),le.value.trim()===""&&(le.value=""),le.prop=R==null?void 0:R.join("·"),le.usingType="parent",be.value.unshift(le),be.value=(G=be.value)==null?void 0:G.map(ee=>(R!=null&&R.find(Y=>Y===(ee==null?void 0:ee.prop))&&(ee.isFormColHidden=!0),ee))}}},mo=()=>{var a;const e=(a=V.value)==null?void 0:a.$el;e&&de.Sortable.create(e,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:o=>{var t;const{oldIndex:r,newIndex:n}=o;if(r===n)return;const c=ia.value.splice(r,1)[0];ia.value.splice(n,0,c),I.value=(t=I.value)==null?void 0:t.slice().sort((i,f)=>{if(i.label==="操作")return 1;if(f.label==="操作")return-1;const v=ia.value.findIndex(S=>S.label===i.label),N=ia.value.findIndex(S=>S.label===f.label);return v-N})}})};l.onMounted(()=>{_a.value=window.innerWidth-240*2});const So=()=>{l.nextTick(()=>{mo()})},Ma=(e,a)=>{var r;if(!e&&!(e!=null&&e.children))return{contents:e,currentSelectContents:void 0};let o;return e.children=(r=e.children)==null?void 0:r.map(n=>{var c,t;if((n==null?void 0:n.id)===Ul.value){let i={};for(let f in n){let v=(c=a==null?void 0:a.find(N=>(N==null?void 0:N.prop)===f))==null?void 0:c.label;v?i[f]=(t=cl.value)==null?void 0:t[v]:i[f]=n[f]}n=Object.assign(i,cl.value),o=n}else{let i=Ma(n,a);n=i==null?void 0:i.contents,o=i==null?void 0:i.currentSelectContents}return n}),{contents:e,currentSelectContents:o}},er=(e,a)=>{let o,r;return e!=null&&e.find(n=>(n==null?void 0:n.id)===Ul.value)?o=e==null?void 0:e.map(n=>{var c,t;if((n==null?void 0:n.id)===Ul.value){let i={};for(let f in n){let v=(c=a==null?void 0:a.find(N=>(N==null?void 0:N.prop)===f))==null?void 0:c.label;v?i[f]=(t=cl.value)==null?void 0:t[v]:i[f]=n[f]}n=Object.assign(i,cl.value),r=n}return n}):o=e==null?void 0:e.map(n=>{var c,t,i,f;if((n==null?void 0:n.id)===Ul.value){let v={};for(let N in n){let S=(c=a==null?void 0:a.find(D=>(D==null?void 0:D.prop)===N))==null?void 0:c.label;S?v[N]=(t=cl.value)==null?void 0:t[S]:v[N]=n[N]}n=Object.assign(v,cl.value),r=n}else n=(i=Ma(n,a))==null?void 0:i.contents,r=(f=Ma(n,a))==null?void 0:f.currentSelectContents;return n}),{newContents:o,currentSelectContents:r}},lr=(e,a,o)=>{var r,n;return e[a==null?void 0:a.prop]=o,typeof e.id=="number"&&(e.id=(r=e.id)==null?void 0:r.toString()),e.children&&((n=e.children)==null?void 0:n.length)>0&&(e.children=e.children.map(lr)),e},$a=e=>{var o;const a=[];return a.push({...e}),e!=null&&e.children&&Array.isArray(e.children)&&((o=e.children)==null||o.forEach(r=>{a.push(...$a(r))})),(a==null?void 0:a.length)>0?a==null?void 0:a.map(r=>{const n={...r};return delete n.children,n}):[]},ca=(e=!0,a,o)=>{var v,N,S,D,j,E,L,d,O,$,M,k,_,m,B,b,H,F,G,u,w,ue,R,C,U,le,ee,Y,fe,te;let r=de.getColumnChild((v=A.cloneDeep(I.value))==null?void 0:v.filter(J=>(J==null?void 0:J.label)!=="操作")),n,c=A.cloneDeep(Z.value);if(!cl.value){jl.value=!1;return}if(Ul.value===""){Wl.value++;let J;a&&o?J={id:Wl.value.toString(),[a==null?void 0:a.prop]:o,children:cl.value.children}:J={id:Wl.value.toString()},J!=null&&J.children&&(J={...J,children:(N=J.children)==null?void 0:N.map(ie=>lr(ie,a,o))}),c.push(Object.assign(cl.value,J)),n=Object.assign(cl.value,J)}else c=(S=er(c,r))==null?void 0:S.newContents,n=(D=er(c,r))==null?void 0:D.currentSelectContents;const t=(j=s.itemData)==null?void 0:j.filter(J=>(J==null?void 0:J.key)==="childTree")[0];if(((E=t==null?void 0:t.contents)==null?void 0:E.length)>0){yl.value="编辑";const J=[];c==null||c.forEach((ie,je)=>{var K;let g={};if(Array.isArray(ie)){let re=[];ie==null||ie.filter(ye=>!(ye!=null&&ye.id)).forEach((ye,Se)=>{var p,ae,_e,x,Ne,Be,ze;if((ae=(p=Al.value)==null?void 0:p[Se])!=null&&ae.prop&&!Array.isArray(ye)){let Ke={};Ke[Al.value[Se].column]=ye,Ue!=null&&Ue.value&&((_e=Ue==null?void 0:Ue.value)==null?void 0:_e.length)>0&&((x=Ue==null?void 0:Ue.value)!=null&&x.find(De=>JSON.stringify(De==null?void 0:De[0])===JSON.stringify(Ke)))&&(re=(Ne=Ue==null?void 0:Ue.value)==null?void 0:Ne.find(De=>JSON.stringify(De==null?void 0:De[0])===JSON.stringify(Ke))),re&&re.length>0?g[Al.value[Se].prop]=re!=null&&re.find(De=>{var $e;return(($e=Object.keys(De))==null?void 0:$e[0])===Al.value[Se].column})?(Be=re==null?void 0:re.find(De=>{var $e;return(($e=Object.keys(De))==null?void 0:$e[0])===Al.value[Se].column}))==null?void 0:Be[Al.value[Se].column]:ye:g[Al.value[Se].prop]=ye}else Array.isArray(ye)&&((ze=Al.value[Se])!=null&&ze.prop?g[Al.value[Se].prop]=ye:g.children=Fa(ye,Al.value))})}else g=ie;Array.isArray(ie)&&ie.some(re=>re==null?void 0:re.id)?J.push(Object.assign(g,{id:(K=ie==null?void 0:ie.find(re=>re.id))==null?void 0:K.id})):g.id?J.push(g):J.push(Object.assign(g,{id:je.toString()}))}),Z.value=ir(J,t,I.value)}or(Z.value),ra.value=Z.value;const i=nn(ra.value,oa.value,c);let f=[];if(Yl.value?(f=(L=A.cloneDeep(Yl).value.singleContent)==null?void 0:L.filter(J=>(J==null?void 0:J.id)!==(n==null?void 0:n.id)),f.push(n)):f=[n],Nl.value){const J={content:i,singleContent:((d=t==null?void 0:t.contents)==null?void 0:d.length)>0?f==null?void 0:f.flatMap($a):f,index:s==null?void 0:s.index,buttonName:"编辑",column:I.value,parentTableId:s==null?void 0:s.parentTableId};qe.setCacheUpdatingData(J)}if(e){let J=(k=(M=($=(O=s.itemData)==null?void 0:O.find(g=>(g==null?void 0:g.key)==="filterAllType"))==null?void 0:$.value)==null?void 0:M.find(g=>(g==null?void 0:g.value)==="onConditionContents"))==null?void 0:k.content,ie=(_=s.itemData)==null?void 0:_.filter(g=>(g==null?void 0:g.key)==="filterAllType");ie=Array.from(new Map(ie.filter(Boolean).map((g,K)=>[g.value,{...g,_idx:K}])).values()).sort((g,K)=>g._idx-K._idx).map(({_idx:g,...K})=>K),ie=(m=ie==null?void 0:ie[(ie==null?void 0:ie.length)-1])==null?void 0:m.value;const je={content:i,singleContent:((B=t==null?void 0:t.contents)==null?void 0:B.length)>0?$a(n):n,index:s==null?void 0:s.index,buttonName:yl.value,column:I.value,parentTableId:s==null?void 0:s.parentTableId,filter:J,allFilter:ie,pathIndex:(H=(b=s.itemData)==null?void 0:b.find(g=>(g==null?void 0:g.key)==="relatedFilter"))==null?void 0:H.index,rowContents:be.value,addArrayValues:Le.value};qe.setTableLoading(s==null?void 0:s.index),jl.value=!1,cl.value=void 0,ne("change",je)}if((u=(G=(F=be.value)==null?void 0:F[0])==null?void 0:G.optionUrl)!=null&&u.menuId){jl.value=!1;let J=(w=s.itemData)==null?void 0:w.filter(ie=>(ie==null?void 0:ie.key)==="filterAllType");if((J==null?void 0:J.length)>0){let ie=J==null?void 0:J.map(K=>K==null?void 0:K.value),je=(C=(R=(ue=ie.flat().find(K=>{var re;return(re=K==null?void 0:K.content)==null?void 0:re.includes("@Num")}))==null?void 0:ue.content)==null?void 0:R.split(":"))==null?void 0:C[1];((ee=(le=(U=ie.flat().find(K=>{var re;return(re=K==null?void 0:K.content)==null?void 0:re.includes("@Type:")}))==null?void 0:U.content)==null?void 0:le.split(":"))==null?void 0:ee[1])!=="Manual"&&(je=parseInt(je),Z.value=(te=Z.value)==null?void 0:te.slice(((Y=Z.value)==null?void 0:Y.length)-je,(fe=Z.value)==null?void 0:fe.length))}}};l.onUnmounted(()=>{I.value=[],Z.value=[],T.value=[],Ea.value=[],xl.value=[],Dl.value=[],ea.value=[],Ll.value=[],be.value=[],El.value=[],V.value=null});const ar=async(e,a,o)=>{var v,N,S,D,j,E,L,d,O,$,M;_l.value=o==null?void 0:o.prop;const r=A.cloneDeep(s.itemData),n=r==null?void 0:r.map(k=>{var _;return(k==null?void 0:k.key)==="header"&&((_=k.contents)==null||_.map((m,B)=>{var b,H,F,G,u,w,ue,R,C,U,le,ee,Y,fe,te,J,ie,je,g;return m.type=m!=null&&m.type?m.type:(G=(F=(H=(b=m==null?void 0:m.key)==null?void 0:b.split("$"))==null?void 0:H[1])==null?void 0:F.split("("))!=null&&G[0]?(w=(u=de.FormType)==null?void 0:u.find(K=>{var re,ye,Se,p;return(K==null?void 0:K.key)===((p=(Se=(ye=(re=m==null?void 0:m.key)==null?void 0:re.split("$"))==null?void 0:ye[1])==null?void 0:Se.split("("))==null?void 0:p[0])}))==null?void 0:w.value:"Input",m.options=m!=null&&m.options?m.options:((C=(R=(ue=m==null?void 0:m.key)==null?void 0:ue.split("$"))==null?void 0:R[1])==null?void 0:C.length)>0?(Y=(ee=Da((le=(U=m==null?void 0:m.key)==null?void 0:U.split("$"))==null?void 0:le[1]))==null?void 0:ee.split(","))==null?void 0:Y.map(K=>({label:K,value:K})):[],(fe=m==null?void 0:m.key)!=null&&fe.includes("$")&&(m.key=(J=(te=m==null?void 0:m.key)==null?void 0:te.split("$"))==null?void 0:J[0]),m.value=(ie=Object.values(a))==null?void 0:ie[B],m.optionUrl=m!=null&&m.formMenuSelect&&((je=m==null?void 0:m.formMenuSelect)==null?void 0:je.length)>0?{groupSelect:(g=m==null?void 0:m.groupSelect)==null?void 0:g.split(/[::]/).map(K=>K.trim()),menuSelect:m==null?void 0:m.formMenuSelect,selectRelateType:"",type:(m==null?void 0:m.formType)??(m!=null&&m.groupSelect?"Select":"")}:null,m})),k});let c=A.cloneDeep(be.value),t=(N=(v=A.cloneDeep(n))==null?void 0:v.find(k=>(k==null?void 0:k.key)==="header"))==null?void 0:N.contents;c=c==null?void 0:c.map(k=>{var _;return k.value=(_=t==null?void 0:t.find((m,B)=>B===(k==null?void 0:k.id)))==null?void 0:_.value,k});let i="",f=(j=(D=(S=A.cloneDeep(n))==null?void 0:S.find(k=>(k==null?void 0:k.key)==="header"))==null?void 0:D.contents)==null?void 0:j.find((k,_)=>{var m,B,b;return(k==null?void 0:k.label)===_l.value||(_==null?void 0:_.toString())===((b=(B=(m=_l.value)==null?void 0:m.split("a"))==null?void 0:B[1])==null?void 0:b.toString())});if((d=(L=(E=A.cloneDeep(n))==null?void 0:E.find(k=>(k==null?void 0:k.key)==="header"))==null?void 0:L.contents)==null||d.forEach(k=>{var _,m,B,b,H;i===""&&((B=(m=(_=k==null?void 0:k.optionUrl)==null?void 0:_.groupSelect)==null?void 0:m[1])!=null&&B.includes("["))&&(i=(H=(b=k==null?void 0:k.optionUrl)==null?void 0:b.groupSelect)==null?void 0:H[1])}),(O=f==null?void 0:f.optionUrl)!=null&&O.menuSelect){let k=await Ta(f),_;if(k==null||k.forEach(m=>{var B,b,H,F,G,u,w,ue,R,C;i===((b=(B=f==null?void 0:f.optionUrl)==null?void 0:B.groupSelect)==null?void 0:b[1])&&((G=(F=(H=f==null?void 0:f.optionUrl)==null?void 0:H.groupSelect)==null?void 0:F[1])!=null&&G.includes("["))&&((C=A.cloneDeep(m))==null?void 0:C[(R=(ue=(w=(u=f==null?void 0:f.optionUrl)==null?void 0:u.groupSelect)==null?void 0:w[1])==null?void 0:ue.replaceAll("[",""))==null?void 0:R.replaceAll("]","")])===(f==null?void 0:f.value)&&(_=m)}),_){let m=A.cloneDeep(c);m=m==null?void 0:m.map(b=>{var H,F,G,u,w,ue,R,C,U,le,ee;return(_!=null&&_[b==null?void 0:b.label]||_!=null&&_[(u=(G=(F=(H=b==null?void 0:b.optionUrl)==null?void 0:H.groupSelect)==null?void 0:F[1])==null?void 0:G.replaceAll("[",""))==null?void 0:u.replaceAll("]","")])&&((R=(ue=(w=b==null?void 0:b.optionUrl)==null?void 0:w.groupSelect)==null?void 0:ue[1])!=null&&R.includes("["))&&(b.value=(_==null?void 0:_[b==null?void 0:b.label])||(_==null?void 0:_[(ee=(le=(U=(C=b==null?void 0:b.optionUrl)==null?void 0:C.groupSelect)==null?void 0:U[1])==null?void 0:le.replaceAll("[",""))==null?void 0:ee.replaceAll("]","")])),b}),Z.value=($=A.cloneDeep(Z.value))==null?void 0:$.map(b=>{if((b==null?void 0:b.id)===(a==null?void 0:a.id)){const H={};return m==null||m.forEach(F=>{H[F.name]=F.value}),H.id=b==null?void 0:b.id,H}return b});let B=A.cloneDeep(m);B=B==null?void 0:B.map(b=>{var H,F,G,u;return(F=(H=b==null?void 0:b.optionUrl)==null?void 0:H.menuSelect)!=null&&F.some(w=>w==null?void 0:w.includes)&&(b.optionUrl.menuSelect=(u=(G=b==null?void 0:b.optionUrl)==null?void 0:G.menuSelect)==null?void 0:u.map(w=>{var ue,R,C,U;if(w!=null&&w.includes("[")){let le=(R=(ue=w==null?void 0:w.replaceAll("[","").replaceAll("]",""))==null?void 0:ue.split(":"))==null?void 0:R[1];w=(U=(C=A.cloneDeep(m))==null?void 0:C.find(ee=>(ee==null?void 0:ee.label)===le))==null?void 0:U.value}return w})),b}),Z.value=(M=A.cloneDeep(Z.value))==null?void 0:M.map(b=>{if((b==null?void 0:b.id)===(a==null?void 0:a.id)){const H={};return B==null||B.forEach(F=>{H[F.name]=F.value}),H.id=b==null?void 0:b.id,H}return b})}}},xo=async e=>{var j,E,L,d,O,$,M,k,_,m,B,b,H,F,G,u,w,ue,R,C,U,le,ee,Y,fe,te,J,ie,je;if(!e)return;cl.value=e;const a=A.cloneDeep(s.itemData);let o=a==null?void 0:a.map(g=>{var K,re,ye,Se;return(g==null?void 0:g.key)==="header"&&(Array.isArray((K=g.contents)==null?void 0:K[0])?g.contents=(ye=de.getColumnChild((re=g.contents)==null?void 0:re[0]))==null?void 0:ye.map((p,ae)=>{var _e,x,Ne,Be,ze,Ke,De,$e,Xe,Ie,Ge,ke,xe,Ze,il,sl,pl,nl,gl,vl,bl,kl,h,W;return p.type=p!=null&&p.type?p.type:(Be=(Ne=(x=(_e=p==null?void 0:p.key)==null?void 0:_e.split("$"))==null?void 0:x[1])==null?void 0:Ne.split("("))!=null&&Be[0]?(Ke=(ze=de.FormType)==null?void 0:ze.find(se=>{var el,ge,Ve,tl;return(se==null?void 0:se.key)===((tl=(Ve=(ge=(el=p==null?void 0:p.key)==null?void 0:el.split("$"))==null?void 0:ge[1])==null?void 0:Ve.split("("))==null?void 0:tl[0])}))==null?void 0:Ke.value:"Input",p.options=p!=null&&p.options?p.options:((Xe=($e=(De=p==null?void 0:p.key)==null?void 0:De.split("$"))==null?void 0:$e[1])==null?void 0:Xe.length)>0?(xe=(ke=Da((Ge=(Ie=p==null?void 0:p.key)==null?void 0:Ie.split("$"))==null?void 0:Ge[1]))==null?void 0:ke.split(","))==null?void 0:xe.map(se=>({label:se,value:se})):[],(Ze=p==null?void 0:p.key)!=null&&Ze.includes("$")&&(p.key=(sl=(il=p==null?void 0:p.key)==null?void 0:il.split("$"))==null?void 0:sl[0]),((gl=(nl=(pl=be.value)==null?void 0:pl.find(se=>(se==null?void 0:se.prop)===(p==null?void 0:p.prop)))==null?void 0:nl.optionUrl)==null?void 0:gl.multiple)===!0&&!Array.isArray((vl=Object.values(e))==null?void 0:vl[ae])?p.value=[(bl=Object.values(e))==null?void 0:bl[ae]]:p.value=(kl=Object.values(e))==null?void 0:kl[ae],p.optionUrl=p!=null&&p.formMenuSelect&&((h=p==null?void 0:p.formMenuSelect)==null?void 0:h.length)>0?{groupSelect:(W=p==null?void 0:p.groupSelect)==null?void 0:W.split(/[::]/).map(se=>se.trim()),menuSelect:p==null?void 0:p.formMenuSelect,selectRelateType:"",type:(p==null?void 0:p.formType)??(p!=null&&p.groupSelect?"Select":"")}:null,p}):g.contents=(Se=g.contents)==null?void 0:Se.map((p,ae)=>{var _e,x,Ne,Be,ze,Ke,De,$e,Xe,Ie,Ge,ke,xe,Ze,il,sl,pl,nl,gl,vl,bl,kl,h,W;return p.type=p!=null&&p.type?p.type:(Be=(Ne=(x=(_e=p==null?void 0:p.key)==null?void 0:_e.split("$"))==null?void 0:x[1])==null?void 0:Ne.split("("))!=null&&Be[0]?(Ke=(ze=de.FormType)==null?void 0:ze.find(se=>{var el,ge,Ve,tl;return(se==null?void 0:se.key)===((tl=(Ve=(ge=(el=p==null?void 0:p.key)==null?void 0:el.split("$"))==null?void 0:ge[1])==null?void 0:Ve.split("("))==null?void 0:tl[0])}))==null?void 0:Ke.value:"Input",p.options=p!=null&&p.options?p.options:((Xe=($e=(De=p==null?void 0:p.key)==null?void 0:De.split("$"))==null?void 0:$e[1])==null?void 0:Xe.length)>0?(xe=(ke=Da((Ge=(Ie=p==null?void 0:p.key)==null?void 0:Ie.split("$"))==null?void 0:Ge[1]))==null?void 0:ke.split(","))==null?void 0:xe.map(se=>({label:se,value:se})):[],(Ze=p==null?void 0:p.key)!=null&&Ze.includes("$")&&(p.key=(sl=(il=p==null?void 0:p.key)==null?void 0:il.split("$"))==null?void 0:sl[0]),((gl=(nl=(pl=be.value)==null?void 0:pl.find(se=>(se==null?void 0:se.prop)===(p==null?void 0:p.prop)))==null?void 0:nl.optionUrl)==null?void 0:gl.multiple)===!0&&!Array.isArray((vl=Object.values(e))==null?void 0:vl[ae])?p.value=[(bl=Object.values(e))==null?void 0:bl[ae]]:p.value=(kl=Object.values(e))==null?void 0:kl[ae],p.optionUrl=p!=null&&p.formMenuSelect&&((h=p==null?void 0:p.formMenuSelect)==null?void 0:h.length)>0?{groupSelect:(W=p==null?void 0:p.groupSelect)==null?void 0:W.split(/[::]/).map(se=>se.trim()),menuSelect:p==null?void 0:p.formMenuSelect,selectRelateType:"",type:(p==null?void 0:p.formType)??(p!=null&&p.groupSelect?"Select":"")}:null,p})),g}),r=be.value,n=(E=(j=A.cloneDeep(o))==null?void 0:j.find(g=>(g==null?void 0:g.key)==="header"))==null?void 0:E.contents;if(n=n==null?void 0:n.filter(g=>(g==null?void 0:g.label)!=="操作"),n.push({label:"操作",type:"operate"}),r=r==null?void 0:r.map(g=>{var K;return g.value=g.value??((K=n==null?void 0:n.find((re,ye)=>(re==null?void 0:re.prop)===(g==null?void 0:g.name)))==null?void 0:K.value),g}),!na.value)return;let c="",t=A.cloneDeep(_l.value);(L=_l.value)!=null&&L.includes("·")&&(_l.value=(O=(d=_l.value)==null?void 0:d.split("·"))==null?void 0:O[0]);let i=(k=(M=($=A.cloneDeep(o))==null?void 0:$.find(g=>(g==null?void 0:g.key)==="header"))==null?void 0:M.contents)==null?void 0:k.find((g,K)=>{var re,ye,Se;return(g==null?void 0:g.prop)===_l.value||(K==null?void 0:K.toString())===((Se=(ye=(re=_l.value)==null?void 0:re.split("a"))==null?void 0:ye[1])==null?void 0:Se.toString())}),f=(_=i==null?void 0:i.optionUrl)==null?void 0:_.menuSelect,v=!0;(b=(B=(m=A.cloneDeep(o))==null?void 0:m.find(g=>(g==null?void 0:g.key)==="header"))==null?void 0:B.contents)==null||b.forEach(g=>{var K,re,ye,Se,p,ae;v&&((ye=(re=(K=g==null?void 0:g.optionUrl)==null?void 0:K.groupSelect)==null?void 0:re[1])!=null&&ye.includes("["))&&(c=(p=(Se=g==null?void 0:g.optionUrl)==null?void 0:Se.groupSelect)==null?void 0:p[1],JSON.stringify(f)===JSON.stringify((ae=g==null?void 0:g.optionUrl)==null?void 0:ae.menuSelect)&&(v=!1))});let N=A.cloneDeep(r),S=rl.value;S!=null&&S.find(g=>(i==null?void 0:i.prop)===(g==null?void 0:g.key))&&(S=S==null?void 0:S.filter(g=>(i==null?void 0:i.prop)!==(g==null?void 0:g.key))),S!=null&&S.find(g=>t===(g==null?void 0:g.key))&&(S=S==null?void 0:S.filter(g=>t!==(g==null?void 0:g.key))),N=N==null?void 0:N.map(g=>{var K,re,ye,Se,p,ae,_e,x,Ne;return(g==null?void 0:g.type)==="Select"&&(((re=(K=g==null?void 0:g.optionUrl)==null?void 0:K.allSelectionContents)==null?void 0:re.length)>0&&(g.optionUrl.contactValue=e),((i==null?void 0:i.prop)===(g==null?void 0:g.prop)||t===(g==null?void 0:g.prop))&&i&&(Array.isArray(i.value)&&((ye=i.value)==null?void 0:ye.length)>0&&((Se=i.value)!=null&&Se.every(Be=>typeof Be=="string"))?(S.push({key:g==null?void 0:g.prop,value:[(ae=i.value)==null?void 0:ae[((p=i.value)==null?void 0:p.length)-1]]}),g.selectValue=(_e=S==null?void 0:S.find(Be=>(Be==null?void 0:Be.key)===(g==null?void 0:g.prop)))==null?void 0:_e.value):Array.isArray(i.value)&&((x=i.value)==null?void 0:x.length)===0?(S=[],g.selectValue=[],e[g==null?void 0:g.prop]=""):Array.isArray(g.value)&&S.push({key:g==null?void 0:g.prop,value:[(Ne=g.value)==null?void 0:Ne[(g==null?void 0:g.length)-1]]}))),g.value=e==null?void 0:e[g==null?void 0:g.prop],g}),rl.value=S,be.value=A.cloneDeep(N);let D=(i==null?void 0:i.menuId)??((G=(F=(H=be.value)==null?void 0:H.find(g=>{var K;return(K=g==null?void 0:g.optionUrl)==null?void 0:K.menuId}))==null?void 0:F.optionUrl)==null?void 0:G.menuId);if((u=i==null?void 0:i.optionUrl)!=null&&u.menuSelect&&na.value||D){let g=await Ta(i,D),K;if(g==null||g.forEach(p=>{var ae,_e,x,Ne,Be,ze,Ke,De,$e,Xe,Ie,Ge,ke,xe,Ze,il,sl,pl,nl,gl,vl,bl,kl,h,W,se,el;if(!D&&c===((_e=(ae=i==null?void 0:i.optionUrl)==null?void 0:ae.groupSelect)==null?void 0:_e[1])&&((Be=(Ne=(x=i==null?void 0:i.optionUrl)==null?void 0:x.groupSelect)==null?void 0:Ne[1])!=null&&Be.includes("["))&&((Xe=A.cloneDeep(p))==null?void 0:Xe[($e=(De=(Ke=(ze=i==null?void 0:i.optionUrl)==null?void 0:ze.groupSelect)==null?void 0:Ke[1])==null?void 0:De.replaceAll("[",""))==null?void 0:$e.replaceAll("]","")])===(i==null?void 0:i.value)&&(K=p),D){let ge=(Ge=(Ie=be.value)==null?void 0:Ie.find(P=>{var y;return(i==null?void 0:i.menuId)===((y=P==null?void 0:P.optionUrl)==null?void 0:y.menuId)}))==null?void 0:Ge.prop,Ve=e[ge];if(ge!=null&&ge.includes("·"))if(!Array.isArray(e[ge]))Ve=(xe=(ke=e[ge])==null?void 0:ke.split(" "))==null?void 0:xe[0],ge=(Ze=ge==null?void 0:ge.split("·"))==null?void 0:Ze[0];else{ge=(il=ge==null?void 0:ge.split("·"))==null?void 0:il[0];let P=(pl=(sl=N==null?void 0:N.find(y=>(y==null?void 0:y.prop)===ge))==null?void 0:sl.selectValue)==null?void 0:pl[0];Ve=(nl=P==null?void 0:P.split(" "))==null?void 0:nl[0]}let tl=(vl=(gl=N==null?void 0:N.find(P=>{var y;return(P==null?void 0:P.prop)===ge||((y=P==null?void 0:P.prop)==null?void 0:y.includes("."+ge))}))==null?void 0:gl.selectValue)==null?void 0:vl[0];if(ge!=null&&ge.includes(".")&&(ge=(kl=ge==null?void 0:ge.split("."))==null?void 0:kl[((bl=ge==null?void 0:ge.split("."))==null?void 0:bl.length)-1]),Array.isArray(Ve)&&!tl&&(tl=Ve==null?void 0:Ve[0]),p[ge]===(Array.isArray(Ve)?tl:Ve)&&(i==null?void 0:i.directiveLabel)==="#isMain"){if(t!=null&&t.includes("·")){let P=t==null?void 0:t.split("·"),y=(el=(se=(W=Array.isArray(e==null?void 0:e[t])?(h=e==null?void 0:e[t])==null?void 0:h[0]:e==null?void 0:e[t])==null?void 0:W.split(" "))==null?void 0:se.filter(Ce=>Ce&&Ce!==""))==null?void 0:el.map(Ce=>Ce==null?void 0:Ce.trim());P==null||P.forEach((Ce,He)=>{p[Ce]=y==null?void 0:y[He]})}K=p}}}),hl.value&&(i==null?void 0:i.directiveLabel)==="#isMain"&&(Le.value=[]),!K){if(hl.value&&(i==null?void 0:i.directiveLabel)==="#isMain")if(t!=null&&t.includes("·")){let p=e,ae=(R=(ue=(w=e==null?void 0:e[t])==null?void 0:w.split(" "))==null?void 0:ue.filter(x=>x&&x!==""))==null?void 0:R.map(x=>x==null?void 0:x.trim());(C=t==null?void 0:t.split("·"))==null||C.forEach((x,Ne)=>{p[x]=ae[Ne]});let _e=(U=be.value)==null?void 0:U.find(x=>(x==null?void 0:x.prop)===t);p[_e.prop]=[_e.value],K=p}else{let p=(le=be.value)==null?void 0:le.find(ae=>(ae==null?void 0:ae.prop)===(i==null?void 0:i.prop));e[p.prop]=[p.value],K=e}else if((i==null?void 0:i.directiveLabel)==="#isMain"){let p={};(ee=be.value)==null||ee.forEach(ae=>{var _e,x;(ae==null?void 0:ae.prop)===t?p[ae.prop]=(_e=ae==null?void 0:ae.selectValue)!=null&&_e[0]?[(x=ae==null?void 0:ae.selectValue)==null?void 0:x[0]]:"":p[ae.prop]=""}),K=p}}if(K){let p=A.cloneDeep(r);p=p==null?void 0:p.map(x=>{var Be,ze,Ke,De,$e,Xe,Ie,Ge,ke,xe,Ze,il,sl,pl,nl,gl,vl,bl,kl,h,W,se,el,ge,Ve,tl,P,y,Ce,He,We,ul,fl;(K!=null&&K[x==null?void 0:x.prop]||K!=null&&K[(De=(Ke=(ze=(Be=x==null?void 0:x.optionUrl)==null?void 0:Be.groupSelect)==null?void 0:ze[1])==null?void 0:Ke.replaceAll("[",""))==null?void 0:De.replaceAll("]","")])&&((Ie=(Xe=($e=x==null?void 0:x.optionUrl)==null?void 0:$e.groupSelect)==null?void 0:Xe[1])!=null&&Ie.includes("["))&&(x!=null&&x.relatedValueId)&&(x.value=(K==null?void 0:K[x==null?void 0:x.prop])||(K==null?void 0:K[(Ze=(xe=(ke=(Ge=x==null?void 0:x.optionUrl)==null?void 0:Ge.groupSelect)==null?void 0:ke[1])==null?void 0:xe.replaceAll("[",""))==null?void 0:Ze.replaceAll("]","")]));let Ne=K==null?void 0:K[x==null?void 0:x.prop];return(il=x==null?void 0:x.prop)!=null&&il.includes(".")&&((pl=(sl=i==null?void 0:i.prop)==null?void 0:sl.split("."))==null?void 0:pl[0])===((gl=(nl=x==null?void 0:x.prop)==null?void 0:nl.split("."))==null?void 0:gl[0])&&(Ne=K==null?void 0:K[(h=(vl=x==null?void 0:x.prop)==null?void 0:vl.split("."))==null?void 0:h[((kl=(bl=x==null?void 0:x.prop)==null?void 0:bl.split("."))==null?void 0:kl.length)-1]]),D&&(Ne||Ne==="")&&(x!=null&&x.relatedValueId)&&yl.value==="新增"&&((x==null?void 0:x.prop)!==(i==null?void 0:i.prop)||t!=null&&t.includes((i==null?void 0:i.prop)+"·")||t!=null&&t.includes("·"+(x==null?void 0:x.prop)))?x.value=Ne||(K==null?void 0:K[(ge=(el=(se=(W=x==null?void 0:x.optionUrl)==null?void 0:W.groupSelect)==null?void 0:se[1])==null?void 0:el.replaceAll("[",""))==null?void 0:ge.replaceAll("]","")]):(t!=null&&t.includes("·"+(x==null?void 0:x.prop))||t!=null&&t.includes("."))&&(x==null?void 0:x.prop)!==(i==null?void 0:i.prop)?x.value=Ne??"":((Ve=x==null?void 0:x.optionUrl)==null?void 0:Ve.multiple)===!0&&!Array.isArray((P=(tl=be.value)==null?void 0:tl.find(Qe=>(Qe==null?void 0:Qe.prop)===(x==null?void 0:x.prop)))==null?void 0:P.value)?x.value=((Ce=(y=be.value)==null?void 0:y.find(Qe=>(Qe==null?void 0:Qe.prop)===(x==null?void 0:x.prop)))==null?void 0:Ce.value)===""?[]:[(We=(He=be.value)==null?void 0:He.find(Qe=>(Qe==null?void 0:Qe.prop)===(x==null?void 0:x.prop)))==null?void 0:We.value]:x.value=(fl=(ul=be.value)==null?void 0:ul.find(Qe=>(Qe==null?void 0:Qe.prop)===(x==null?void 0:x.prop)))==null?void 0:fl.value,x}),be.value=A.cloneDeep(p);let ae=A.cloneDeep(p);ae=ae==null?void 0:ae.map(x=>{var Ne,Be,ze,Ke,De,$e,Xe,Ie,Ge;return(Be=(Ne=x==null?void 0:x.optionUrl)==null?void 0:Ne.menuSelect)!=null&&Be.some(ke=>ke==null?void 0:ke.includes("["))&&(x.optionUrl.oldMenuSelect=(Ke=(ze=A.cloneDeep(x))==null?void 0:ze.optionUrl)==null?void 0:Ke.menuSelect,x.optionUrl.menuSelect=($e=(De=x==null?void 0:x.optionUrl)==null?void 0:De.menuSelect)==null?void 0:$e.map(ke=>{var xe,Ze,il,sl;if(ke!=null&&ke.includes("[")){let pl=(Ze=(xe=ke==null?void 0:ke.replaceAll("[","").replaceAll("]",""))==null?void 0:xe.split(":"))==null?void 0:Ze[1];ke=(sl=(il=A.cloneDeep(p))==null?void 0:il.find(nl=>(nl==null?void 0:nl.label)===pl))==null?void 0:sl.value}return ke})),((i==null?void 0:i.prop)===(x==null?void 0:x.prop)||t===(x==null?void 0:x.prop))&&Array.isArray(i.value)&&(Xe=i.value)!=null&&Xe.every(ke=>typeof ke=="string")&&(x.selectValue=((Ie=S==null?void 0:S.find(ke=>(ke==null?void 0:ke.key)===(x==null?void 0:x.prop)))==null?void 0:Ie.value)??((Ge=x.value)==null?void 0:Ge[0])),x}),be.value=ae;let _e={};(Y=be.value)==null||Y.forEach(x=>{_e[x.prop]=x==null?void 0:x.value}),cl.value=_e}let re=Le.value,ye={};(fe=be.value)==null||fe.forEach(p=>{var ae,_e,x,Ne,Be,ze,Ke,De,$e,Xe,Ie;if(((p==null?void 0:p.directiveLabel)==="#isMain"||(ae=p==null?void 0:p.optionUrl)!=null&&ae.menuId)&&Array.isArray(p==null?void 0:p.value)){if(ye[p.prop]=(x=p.value)==null?void 0:x[((_e=p.value)==null?void 0:_e.length)-1],(Ne=p==null?void 0:p.prop)!=null&&Ne.includes("·")){let Ge=(Ke=(ze=(Be=p==null?void 0:p.prop)==null?void 0:Be.split("·"))==null?void 0:ze.filter(xe=>xe&&xe!==""))==null?void 0:Ke.map(xe=>xe==null?void 0:xe.trim()),ke=(Ie=(Xe=($e=(De=p==null?void 0:p.selectValue)==null?void 0:De[0])==null?void 0:$e.split(" "))==null?void 0:Xe.filter(xe=>xe&&xe!==""))==null?void 0:Ie.map(xe=>xe==null?void 0:xe.trim());Ge==null||Ge.forEach((xe,Ze)=>{ye[xe]=ke==null?void 0:ke[Ze]})}}else ye[p.prop]=(ye==null?void 0:ye[p==null?void 0:p.prop])??p.value});let Se=(te=be.value)==null?void 0:te.find(p=>{var ae;return(p==null?void 0:p.directiveLabel)==="#isMain"||((ae=p==null?void 0:p.optionUrl)==null?void 0:ae.menuId)});(i==null?void 0:i.directiveLabel)==="#isMain"?re.push({label:i==null?void 0:i.prop,value:(ie=i==null?void 0:i.value)==null?void 0:ie[((J=i==null?void 0:i.value)==null?void 0:J.length)-1],objectValue:ye}):((je=Se==null?void 0:Se.value)==null?void 0:je.length)>0&&(re=re==null?void 0:re.map(p=>{var ae;return(p==null?void 0:p.value)===((ae=Se==null?void 0:Se.selectValue)==null?void 0:ae[0])&&(p.objectValue=ye),p})),Le.value=re}na.value=!0,hl.value=!1},Co=e=>e?(e==null?void 0:e.toUpperCase())==="INPUT"?"TEXTAREA":e:"TEXTAREA",Do=e=>{var c,t;const a=(t=(c=xl.value)==null?void 0:c.find(i=>(i==null?void 0:i.label)===(e==null?void 0:e.label)))==null?void 0:t.multiple,o=e==null?void 0:e.prop;if((e==null?void 0:e.formType)!="Select")return;Z.value.forEach(i=>{const f=i==null?void 0:i[o];a&&tr.isString(f)&&(i[o]=[f]),!a&&!tr.isString(f)&&(i[o]="")})},rr=(e,a)=>{var o;return a==null||a.forEach(r=>{e[r==null?void 0:r.prop]=r==null?void 0:r.value}),e.children&&((o=e.children)==null?void 0:o.length)>0&&(e.children=e.children.map(r=>rr(r,a))),e},Pa=e=>{var o,r,n,c,t,i;ua("");const a=(o=be.value)==null?void 0:o.reduce((f,v)=>(f[v.name]=v.value,f),{});if(((r=Object.keys(a))==null?void 0:r.length)>0){cl.value=a,Ul.value="",Wl.value=(n=Z.value)==null?void 0:n.length,Ll.value=(c=Tl.value)==null?void 0:c.filter(v=>(v==null?void 0:v.label)!=="新增");const f=(i=(t=T.value)==null?void 0:t.filter(v=>(v==null?void 0:v.label)!=="操作"))==null?void 0:i.map(v=>{var S,D,j;const N=(D=(S=xl.value)==null?void 0:S.find(E=>(E==null?void 0:E.label)===(v==null?void 0:v.label)))==null?void 0:D.multiple;return Do(v),{...v,contents:(v==null?void 0:v.options)??[],optionUrl:v!=null&&v.formMenuSelect&&((j=v==null?void 0:v.formMenuSelect)==null?void 0:j.length)>0?{groupSelect:v==null?void 0:v.groupSelect,menuSelect:v==null?void 0:v.formMenuSelect,selectRelateType:"",type:v==null?void 0:v.formType,multiple:N}:null}});I.value=f==null?void 0:f.map(v=>rr(v,[{prop:"type",value:"edit"},{prop:"columnType",value:Co(v==null?void 0:v.formType)||(v==null?void 0:v.columnType)}])),e==="createClick"&&ca(!1)}},Ql={START:"开始时间",END:"结束时间",HOURS:"工时"},To=(e,a)=>Number(de.dayjs(a).diff(de.dayjs(e),"day",!0).toFixed(1)),or=e=>{var c;const a=s.itemData,o=(c=a==null?void 0:a.find(t=>(t==null?void 0:t.key)==="header"))==null?void 0:c.contents,r=new Map;return o==null||o.forEach((t,i)=>{const{label:f}=t;r.set(f,i)}),!r.has(Ql.START)||!r.has(Ql.END)||!r.has(Ql.HOURS)?e:e==null?void 0:e.map(t=>{const i=t==null?void 0:t[Ql.START],f=t==null?void 0:t[Ql.END],v=To(i,f);return i&&f&&(t[Ql.HOURS]=`${v}天`),t})},nr=(e,a,o=0)=>{if(o>((a==null?void 0:a.length)??""))return e;const r=a==null?void 0:a[o],n=new Map;for(const t of e){const i=t[r];n.has(i)||n.set(i,[]),n.get(i)&&n.get(i).push(t)}const c=[];for(const[t,i]of n){const[f,...v]=i,N={...f};o+1===((a==null?void 0:a.length)??"")?N.children=i==null?void 0:i.map(S=>(S.level=A.cloneDeep(o)+1,S)).filter((S,D)=>D!==0):v.length>0&&(N.children=nr(v,a,o+1)),N.level=o,c.push(N)}return c},ir=(e,a,o)=>{var n;if(!(a!=null&&a.contents)||((n=a==null?void 0:a.contents)==null?void 0:n.length)===0)return e;let r=[];return r=nr(e,a==null?void 0:a.contents,0),r},sr=(e,a)=>{var j,E,L,d,O,$,M,k,_,m,B,b,H,F,G,u,w,ue,R,C,U,le,ee,Y,fe,te,J,ie,je,g,K,re,ye,Se,p,ae,_e,x,Ne,Be,ze,Ke,De,$e,Xe,Ie,Ge,ke,xe,Ze,il,sl,pl,nl,gl,vl,bl,kl;const o=e==null?void 0:e.filter(h=>(h==null?void 0:h.key)==="header");e==null||e.filter(h=>(h==null?void 0:h.key)==="tableIndexColumn")[0];const r=e==null?void 0:e.filter(h=>(h==null?void 0:h.key)==="childTree")[0];let n=!0;if((L=(E=(j=e==null?void 0:e.find(h=>(h==null?void 0:h.key)==="filterAllType"))==null?void 0:j.value)==null?void 0:E.find(h=>(h==null?void 0:h.value)==="onPamButtonContents"))!=null&&L.content){let h=($=(O=(d=e==null?void 0:e.find(W=>(W==null?void 0:W.key)==="filterAllType"))==null?void 0:d.value)==null?void 0:O.find(W=>(W==null?void 0:W.value)==="onPamButtonContents"))==null?void 0:$.content;h=(M=h==null?void 0:h.split(":"))==null?void 0:M[1],h=(k=h.slice(1,(h==null?void 0:h.length)-1))==null?void 0:k.split(","),n=!!(h!=null&&h.find(W=>W==="操作"))}let c=a;const t=e==null?void 0:e.find(h=>(h==null?void 0:h.key)==="page"),i=e==null?void 0:e.find(h=>(h==null?void 0:h.key)==="rowButton"),f=e==null?void 0:e.find(h=>(h==null?void 0:h.key)==="extraButton"),v=e==null?void 0:e.filter(h=>(h==null?void 0:h.key)==="tableContents"),N=e==null?void 0:e.filter(h=>(h==null?void 0:h.key)==="tableIndex");xl.value=(m=(_=e==null?void 0:e.filter(h=>(h==null?void 0:h.key)==="tableToForm"))==null?void 0:_[0])==null?void 0:m.contents,Ka.value=(t==null?void 0:t.contents)??!0;let S=[];Kl.value===""?S=o==null?void 0:o[0]:S=(o==null?void 0:o.find(h=>(h==null?void 0:h.selectLabel)==="("+Kl.value+")"))??(o==null?void 0:o.find(h=>!(h!=null&&h.selectLabel)));let D=[];if(Kl.value===""?D=N==null?void 0:N[0]:D=(N==null?void 0:N.find(h=>(h==null?void 0:h.selectLabel)==="("+Kl.value+")"))??(N==null?void 0:N.find(h=>!(h!=null&&h.selectLabel))),((B=S==null?void 0:S.contents)==null?void 0:B.length)>0){let h=[];if(S!=null&&S.contents.some(P=>Array.isArray(P)&&(P==null?void 0:P.find(y=>y.children))))oa.value===""?h=(H=(b=de.getGradeColumns(S==null?void 0:S.contents,n))==null?void 0:b[0])==null?void 0:H.filter(P=>!Array.isArray(P)):(oa.value.split("-"),h=(F=de.getGradeColumns(S==null?void 0:S.contents,n))==null?void 0:F[0]);else{let P=S!=null&&S.contents.some(y=>Array.isArray(y))?(G=S==null?void 0:S.contents)==null?void 0:G[0]:S==null?void 0:S.contents;P==null||P.forEach((y,Ce)=>{var ul,fl,Qe,da,pa;let He="";(fl=(ul=we.value)==null?void 0:ul.split("/"))==null||fl.forEach(Bl=>{var ta,fa,Xl;if(Bl!==""){let ml=(Xl=(fa=(ta=Bl==null?void 0:Bl.split(ll+"updateLoading"))==null?void 0:ta[0])==null?void 0:fa.split(ll+"loading"))==null?void 0:Xl[0];He=He===""?He+ml:He+"/"+ml}}),He=He+ll+(y==null?void 0:y.directiveLabel);const We=(Qe=xl.value)==null?void 0:Qe.find(Bl=>(Bl==null?void 0:Bl.prop)===(y==null?void 0:y.prop));h.push({label:(y==null?void 0:y.label)==="操作"?n?"操作":"":(y==null?void 0:y.label)??"",prop:(y==null?void 0:y.label)==="操作"?"operate":(y==null?void 0:y.prop)??"a"+Ce,width:y!=null&&y.width?parseInt(y.width):"",fixed:(y==null?void 0:y.fixed)??void 0,sortable:(y==null?void 0:y.sortable)??!1,filterable:(y==null?void 0:y.filterable)??!1,operable:(y==null?void 0:y.operable)??!1,showSummary:(y==null?void 0:y.showSummary)??!1,align:(y==null?void 0:y.align)??"left",showOverflowTooltip:(y==null?void 0:y.showOverflowTooltip)??!0,isNotDrag:(y==null?void 0:y.isNotDrag)??!1,isEditCol:(y==null?void 0:y.isEditCol)??!1,isOperate:(y==null?void 0:y.isOperate)??!1,id:(y==null?void 0:y.id)??Ce,type:(y==null?void 0:y.label)==="操作"?"operate":void 0,formType:(y==null?void 0:y.formType)??(y!=null&&y.groupSelect?"Select":""),isTableColHidden:y==null?void 0:y.isTableColHidden,isFormColHidden:y==null?void 0:y.isFormColHidden,disabled:y==null?void 0:y.disabled,options:(y==null?void 0:y.options)??[],value:(y==null?void 0:y.value)??"",formMenuSelect:(y==null?void 0:y.formMenuSelect)??[],isRoute:(y==null?void 0:y.isRoute)??!1,groupSelect:y!=null&&y.groupSelect?(da=y==null?void 0:y.groupSelect)==null?void 0:da.replaceAll('"',"").split(":"):[],isMainKey:(y==null?void 0:y.isMainKey)||(y==null?void 0:y.directiveLabel)==="#isMain",columnType:(We==null?void 0:We.type)||(y==null?void 0:y.columnType)||"TEXTAREA",directiveLabel:y==null?void 0:y.directiveLabel,directiveColor:(y==null?void 0:y.directiveColor)??!1,isExistChild:!!(y!=null&&y.directiveLabel&&!(c!=null&&c[He])&&!((pa=y==null?void 0:y.directiveLabel)!=null&&pa.includes("@"))&&(y==null?void 0:y.directiveLabel)!=="#isMain"),childPath:(y==null?void 0:y.directiveLabel)!=="#isMain"?He:void 0,allSelectionContents:(y==null?void 0:y.allSelectionContents)??[],selectFilter:y==null?void 0:y.selectFilter,menuId:y==null?void 0:y.menuId,filterContent:y==null?void 0:y.filterContent,relatedValueId:y==null?void 0:y.relatedValueId})})}I.value=de.getNewColumnChild(h),Ea.value=de.getNewColumnChild(h),oe.value=(u=I.value)==null?void 0:u.map(P=>P==null?void 0:P.label),Oe.value=(w=I.value)==null?void 0:w.every(P=>P==null?void 0:P.filterable),Re.value=(ue=I.value)==null?void 0:ue.every(P=>P==null?void 0:P.operable),me.value=(R=I.value)==null?void 0:R.every(P=>P==null?void 0:P.sortable);let W=(U=(C=de.getAllLeafNodes(I.value))==null?void 0:C.filter(P=>(P==null?void 0:P.type)!=="operate"))==null?void 0:U.map((P,y)=>({prop:(P==null?void 0:P.prop)??"a"+y,column:P.label}));Al.value=W;let se=[];Kl.value===""?se=v==null?void 0:v[0]:se=(v==null?void 0:v.find(P=>(P==null?void 0:P.selectLabel)==="("+Kl.value+")"))??(v==null?void 0:v.find(P=>!(P!=null&&P.selectLabel)));let el=Array.isArray((le=se==null?void 0:se.contents)==null?void 0:le[0])&&((ee=se==null?void 0:se.contents)!=null&&ee[0].every(P=>Array.isArray(P)))?(Y=se==null?void 0:se.contents)==null?void 0:Y[0]:se==null?void 0:se.contents;D!=null&&D.contents&&((fe=D==null?void 0:D.contents)==null?void 0:fe.length)!==0&&(el=(te=A.cloneDeep(el))==null?void 0:te.map((P,y)=>{if(!Array.isArray(P)){let Ce={};for(let He in P)He!=="id"&&He!=="index"&&(Ce[He]=P[He]);P=Object.values(Ce)}return P}));const ge=!!((J=I.value)!=null&&J.find(P=>P.prop==="index"));el=yr(el,D==null?void 0:D.contents,ge);const Ve=[];el==null||el.forEach((P,y)=>{var He;let Ce={};if(Array.isArray(P)){let We=[];P==null||P.filter(ul=>!(ul!=null&&ul.id)).forEach((ul,fl)=>{var Qe,da,pa,Bl,ta,fa;if((Qe=W==null?void 0:W[fl])!=null&&Qe.prop&&!Array.isArray(ul)){let Xl={};Xl[W[fl].column]=ul,Ue!=null&&Ue.value&&((da=Ue==null?void 0:Ue.value)==null?void 0:da.length)>0&&((pa=Ue==null?void 0:Ue.value)!=null&&pa.find(ml=>JSON.stringify(ml==null?void 0:ml[0])===JSON.stringify(Xl)))&&(We=(Bl=Ue==null?void 0:Ue.value)==null?void 0:Bl.find(ml=>JSON.stringify(ml==null?void 0:ml[0])===JSON.stringify(Xl))),We&&We.length>0?Ce[W[fl].prop]=We!=null&&We.find(ml=>{var ha;return((ha=Object.keys(ml))==null?void 0:ha[0])===W[fl].column})?(ta=We==null?void 0:We.find(ml=>{var ha;return((ha=Object.keys(ml))==null?void 0:ha[0])===W[fl].column}))==null?void 0:ta[W[fl].column]:ul:Ce[W[fl].prop]=ul}else Array.isArray(ul)&&((fa=W[fl])!=null&&fa.prop?Ce[W[fl].prop]=ul:Ce.children=Fa(ul,W))})}else Ce=P;Array.isArray(P)&&P.some(We=>We==null?void 0:We.id)?Ve.push(Object.assign(Ce,{id:(He=P==null?void 0:P.find(We=>We.id))==null?void 0:He.id})):Ce.id?Ve.push(Ce):Ve.push(Object.assign(Ce,{id:y.toString()}))}),Z.value=ir(Ve,r,I.value),$l.value=Ve,(ie=$l.value)==null||ie.forEach(P=>{var y;(y=Jl.value)==null||y.set(P.id,P)});const tl=Array.from(((je=Jl.value)==null?void 0:je.values())||[]).filter(P=>P==null?void 0:P._isOCRRow);if(tl.length>0){const P=new Set((Z.value||[]).map(Ce=>Ce==null?void 0:Ce.id)),y=tl.filter(Ce=>!P.has(Ce.id));y.length>0&&(Z.value=[...Z.value||[],...y],$l.value=[...$l.value||[],...y])}}else I.value=[],T.value=[],Z.value=[],$l.value=[],Jl.value=new Map;if(((g=i==null?void 0:i.contents)==null?void 0:g.length)>0)if((ye=(re=(K=e==null?void 0:e.find(h=>(h==null?void 0:h.key)==="filterAllType"))==null?void 0:K.value)==null?void 0:re.find(h=>(h==null?void 0:h.value)==="onRowButtonContents"))!=null&&ye.content){let h=(ae=(p=(Se=e==null?void 0:e.find(W=>(W==null?void 0:W.key)==="filterAllType"))==null?void 0:Se.value)==null?void 0:p.find(W=>(W==null?void 0:W.value)==="onButtonContents"))==null?void 0:ae.content;h=(_e=h==null?void 0:h.split(":"))==null?void 0:_e[1],h=(x=h.slice(1,(h==null?void 0:h.length)-1))==null?void 0:x.split(","),Dl.value=(Ne=i==null?void 0:i.contents)==null?void 0:Ne.filter(W=>h==null?void 0:h.find(se=>se===(W==null?void 0:W.label)))}else Dl.value=i==null?void 0:i.contents;else Dl.value=[];if((Be=Dl.value)!=null&&Be.some(h=>(h==null?void 0:h.label)==="OCR识别")||(Dl.value=[...Dl.value,{label:"OCR识别"}]),((ze=f==null?void 0:f.contents)==null?void 0:ze.length)>0)if(($e=(De=(Ke=e==null?void 0:e.find(h=>(h==null?void 0:h.key)==="filterAllType"))==null?void 0:Ke.value)==null?void 0:De.find(h=>(h==null?void 0:h.value)==="onButtonContents"))!=null&&$e.content){let h=(Ge=(Ie=(Xe=e==null?void 0:e.find(W=>(W==null?void 0:W.key)==="filterAllType"))==null?void 0:Xe.value)==null?void 0:Ie.find(W=>(W==null?void 0:W.value)==="onButtonContents"))==null?void 0:Ge.content;h=(ke=h==null?void 0:h.split(":"))==null?void 0:ke[1],h=(xe=h.slice(1,(h==null?void 0:h.length)-1))==null?void 0:xe.split(","),Ll.value=(Ze=f==null?void 0:f.contents)==null?void 0:Ze.filter(W=>h==null?void 0:h.find(se=>se===(W==null?void 0:W.label))),Tl.value=(il=f==null?void 0:f.contents)==null?void 0:il.filter(W=>h==null?void 0:h.find(se=>se===(W==null?void 0:W.label))),Ae.value=!!(h!=null&&h.find(W=>W==="搜索")),he.value=!!(h!=null&&h.find(W=>W==="块状显示"))}else Ll.value=f==null?void 0:f.contents,Tl.value=f==null?void 0:f.contents;else Ll.value=[],Tl.value=[];((sl=Ll.value)==null?void 0:sl.length)>0&&(Ll.value=(pl=Ll.value)==null?void 0:pl.filter(h=>(h==null?void 0:h.label)!=="OCR识别")),((nl=Tl.value)==null?void 0:nl.length)>0&&(Tl.value=(gl=Tl.value)==null?void 0:gl.filter(h=>(h==null?void 0:h.label)!=="OCR识别")),Wl.value=((vl=Z==null?void 0:Z.value)==null?void 0:vl.length)??0,or(Z.value),ra.value=Z.value,Nl.value&&(I.value=(kl=(bl=T.value)==null?void 0:bl.filter(h=>(h==null?void 0:h.label)!=="操作"))==null?void 0:kl.map(h=>{var W;return{...h,type:"edit",optionUrl:h!=null&&h.formMenuSelect&&((W=h==null?void 0:h.formMenuSelect)==null?void 0:W.length)>0?{groupSelect:h==null?void 0:h.groupSelect,menuSelect:h==null?void 0:h.formMenuSelect,selectRelateType:"",type:h==null?void 0:h.formType}:null}}),Pa())};l.watch(()=>[s.itemData,Kl.value,Nr.value,oa.value,Ue==null?void 0:Ue.value],async()=>{var e,a,o,r,n,c;if((e=s==null?void 0:s.itemData)!=null&&e.find(t=>(t==null?void 0:t.key)==="columnPath")&&!((a=Zl.value)!=null&&a.find(t=>{var i,f;return(t==null?void 0:t.key)===((f=(i=s==null?void 0:s.itemData)==null?void 0:i.find(v=>(v==null?void 0:v.key)==="columnPath"))==null?void 0:f.contents)}))){let t=Zl.value,i={key:(r=(o=s==null?void 0:s.itemData)==null?void 0:o.find(f=>(f==null?void 0:f.key)==="columnPath"))==null?void 0:r.contents,value:(c=(n=s==null?void 0:s.itemData)==null?void 0:n.find(f=>(f==null?void 0:f.key)==="columnUsingPath"))==null?void 0:c.contents};t!=null&&t.find(f=>(f==null?void 0:f.key)===(i==null?void 0:i.key))?t=t==null?void 0:t.map(f=>((f==null?void 0:f.key)===(i==null?void 0:i.key)&&(f.value=i.value),f)):t.push(i),qe.setTableViewContents(t)}sr(s.itemData,s.allMapContents)},{deep:!0,immediate:!0}),l.watch(()=>s==null?void 0:s.operatingForm,e=>{e!=null&&e.form&&(ua(e==null?void 0:e.form),yl.value=e==null?void 0:e.dialogTitle,ba.value=!0,jl.value=!0)},{immediate:!0,deep:!0});const ur=()=>{var e;(e=Pe.value)!=null&&e.includes("read")&&(Nl.value=!Nl.value)},Ao=()=>{ma.value=!ma.value};l.watch(()=>{var e;return(e=s==null?void 0:s.config)==null?void 0:e.viewport},e=>{var a;Pe.value=e,(e==null?void 0:e.length)===0?Nl.value=!1:(e!=null&&e.includes("read")||(Nl.value=!0),e!=null&&e.includes("edit")||(Nl.value=!1)),Te.value=((a=s==null?void 0:s.config)==null?void 0:a.showIndex)||Nl.value},{immediate:!0}),l.watch(()=>Nl.value,e=>{var a;e?(Pa("viewChange"),qe.setCacheUpdatingData(null)):(Ll.value=Tl.value,I.value=Ea.value,Yl.value&&(qe.setTableLoading(s==null?void 0:s.index),ne("change",Yl.value))),pe.value=e,Te.value=e||((a=s==null?void 0:s.config)==null?void 0:a.showIndex)},{immediate:!0}),l.watch(()=>{var e;return(e=qa.value)==null?void 0:e.length},e=>{e===0&&(Fe.currentPage=1)}),l.watch(()=>s==null?void 0:s.compNames,e=>{Je.contents=[{label:"列表名",prop:"groupName",name:"列表名",type:"select",value:"",id:0,contents:e||[],width:1}]},{immediate:!0}),l.ref(!1);const No=(e,a)=>{var o;Pa("createClick"),a===Fe.pageSize&&(Fe.currentPage=Math.ceil(((o=Z.value)==null?void 0:o.length)/Fe.pageSize))},Eo=(e,a,o)=>{var r;ar(o,e,a),cl.value=A.cloneDeep(e),Ul.value=e==null?void 0:e.id,Wl.value=(r=Z.value)==null?void 0:r.length,yl.value=typeof(e==null?void 0:e.id)=="string"?"新增":"编辑",ca(!1)},dl=e=>{var f,v,N,S,D,j,E,L,d,O;const{row:a,column:o,item:r,slotData:n}=e;let c=a!=null&&a[o==null?void 0:o.prop]||(a==null?void 0:a[o==null?void 0:o.prop])===0?((v=(f=a==null?void 0:a[o==null?void 0:o.prop])==null?void 0:f[0])==null?void 0:v.contents)??((a==null?void 0:a[o==null?void 0:o.prop])===0?"0":a==null?void 0:a[o==null?void 0:o.prop]):((S=(N=a==null?void 0:a[r==null?void 0:r.prop])==null?void 0:N[0])==null?void 0:S.contents)??(a==null?void 0:a[r==null?void 0:r.prop])??((j=(D=n==null?void 0:n[r==null?void 0:r.prop])==null?void 0:D[0])==null?void 0:j.contents)??(n==null?void 0:n[r==null?void 0:r.prop])??((d=(L=a==null?void 0:a[(E=r==null?void 0:r.child)==null?void 0:E.prop])==null?void 0:L[0])==null?void 0:d.contents)??(a==null?void 0:a[(O=r==null?void 0:r.child)==null?void 0:O.prop]),i=Array.isArray(c)&&!(c!=null&&c.every($=>typeof $=="string"||typeof $=="number"))?"查看":c;return i=Array.isArray(i)?i.join(","):i,i},_o=e=>{var v,N,S,D,j,E,L,d,O,$;const{row:a,column:o,item:r,slotData:n}=e;let c=a!=null&&a[o==null?void 0:o.prop]?((N=(v=a==null?void 0:a[o==null?void 0:o.prop])==null?void 0:v[0])==null?void 0:N.contents)??(a==null?void 0:a[o==null?void 0:o.prop]):((D=(S=a==null?void 0:a[r==null?void 0:r.prop])==null?void 0:S[0])==null?void 0:D.contents)??(a==null?void 0:a[r==null?void 0:r.prop])??((E=(j=n==null?void 0:n[r==null?void 0:r.prop])==null?void 0:j[0])==null?void 0:E.contents)??(n==null?void 0:n[r==null?void 0:r.prop])??((O=(d=a==null?void 0:a[(L=r==null?void 0:r.child)==null?void 0:L.prop])==null?void 0:d[0])==null?void 0:O.contents)??(a==null?void 0:a[($=r==null?void 0:r.child)==null?void 0:$.prop]);const i=Array.isArray(c)&&!(c!=null&&c.every(M=>typeof M=="string"||typeof M=="number")),f=Array.isArray(c)&&(c==null?void 0:c.find(M=>M==null?void 0:M.url));return i&&f},cr=e=>{var t,i,f,v,N,S,D,j,E,L;const{row:a,column:o,item:r,slotData:n}=e||{};let c=a!=null&&a[o==null?void 0:o.prop]?((i=(t=a==null?void 0:a[o==null?void 0:o.prop])==null?void 0:t[0])==null?void 0:i.contents)??(a==null?void 0:a[o==null?void 0:o.prop]):((v=(f=a==null?void 0:a[r==null?void 0:r.prop])==null?void 0:f[0])==null?void 0:v.contents)??(a==null?void 0:a[r==null?void 0:r.prop])??((S=(N=n==null?void 0:n[r==null?void 0:r.prop])==null?void 0:N[0])==null?void 0:S.contents)??(n==null?void 0:n[r==null?void 0:r.prop])??((E=(j=a==null?void 0:a[(D=r==null?void 0:r.child)==null?void 0:D.prop])==null?void 0:j[0])==null?void 0:E.contents)??(a==null?void 0:a[(L=r==null?void 0:r.child)==null?void 0:L.prop]);return Array.isArray(c)?(c==null?void 0:c.filter(d=>(d==null?void 0:d.url)||(d==null?void 0:d.downloadUrl)))??[]:[]},Bo=(e,a)=>e.find(o=>Object.values(o).some(r=>r===a));return l.watch(()=>mr.value,async e=>{if(e){Ye.setContentLoading(!0),await l.nextTick();const a=Bo(Z.value,e==null?void 0:e.data);if(!a)return Ye.setContentLoading(!1);await Qa(e==null?void 0:e.data,null,a,{data:e==null?void 0:e.data,isMainKey:!0}),Ye.setContentLoading(!1)}},{deep:!0,immediate:!0}),l.watch(()=>s==null?void 0:s.cacheNewData,e=>{var a;e&&(Array.isArray(e)||(e==null?void 0:e.compId)===(s==null?void 0:s.index)&&(Z.value=(a=Z.value)==null?void 0:a.map(o=>{var r;return(o==null?void 0:o.id)===((r=e==null?void 0:e.data)==null?void 0:r.id)?{...o,id:e==null?void 0:e.resId}:o})))},{immediate:!0,deep:!0}),(e,a)=>{var D,j,E,L;const o=l.resolveComponent("svg-icon"),r=l.resolveComponent("el-popover"),n=l.resolveComponent("el-switch"),c=l.resolveComponent("el-checkbox"),t=l.resolveComponent("el-checkbox-group"),i=l.resolveComponent("el-button"),f=l.resolveComponent("LookComponent"),v=l.resolveComponent("el-icon"),N=l.resolveComponent("el-upload"),S=l.resolveDirective("loading");return l.openBlock(),l.createElementBlock("div",fn,[Va.value?(l.openBlock(),l.createBlock(Sl.ssTable,{id:"excel-table",pageObj:Fe,showIndex:Te.value,isTree:(D=q.compItem)==null?void 0:D.isTree,summaryInfo:al,columns:I.value,defaultSort:X,isCardViewport:ma.value,checkedColumns:oe.value,key:Ua.value+JSON.stringify(I.value),tableData:qa.value,isEditViewport:Nl.value,isShowPagination:Ka.value,isShowEdit:!1,isShowDelete:!1,allowSelect:pe.value,onDbClickRow:Yr,extraButton:Ll.value,rowButton:Dl.value,cacheExtraButtons:Tl.value,isClearSelection:((j=El.value)==null?void 0:j.length)===0,onDoCurrentChange:jr,onDoSizeChange:Lr,onContentClick:Qa,onRowClick:eo,onSelectChange:zr,onCellChange:Eo,onChange:ar,onPreview:Ja,onSubmitEditingTable:Kr,onHandleColEditChange:Fr,onHandleColTypeChange:Rr,onClickButton:xa},l.createSlots({headerButton:l.withCtx(d=>{var O,$;return[q.showHeader?(l.openBlock(),l.createBlock(Qo,{key:0,pageLayout:q.pageLayout,lockingPage:l.unref(ya)===l.unref(we),filterValues:Ha.value,selectNums:(O=El.value)==null?void 0:O.length,dataNums:($=Z.value)==null?void 0:$.length,compName:q.compName,isDevMode:q.isDevMode,buttons:d.buttons,onButtonClick:a[1]||(a[1]=M=>xa(M,"",{})),columns:I.value,onFilter:Ir,onGetImportData:$r,level:q.level,filterShow:Ae.value},null,8,["pageLayout","lockingPage","filterValues","selectNums","dataNums","compName","isDevMode","buttons","columns","level","filterShow"])):l.createCommentVNode("",!0)]}),viewport:l.withCtx(()=>{var d,O,$,M;return[((d=Z.value)==null?void 0:d.length)>0&&q.allowOperate&&he.value?(l.openBlock(),l.createElementBlock("div",gn,[(O=Pe.value)!=null&&O.includes("read")&&(($=Pe.value)!=null&&$.includes("edit"))&&((M=Dl.value)!=null&&M.some(k=>(k==null?void 0:k.label)==="编辑"))&&!ma.value&&l.unref(ya)!==l.unref(we)?(l.openBlock(),l.createElementBlock("span",{key:0,title:"编辑表格",onClick:ur},[l.createVNode(o,{name:"editTable",class:"view-icon"})])):l.createCommentVNode("",!0),l.createElementVNode("span",{title:"卡片视图",onClick:Ao},[l.createVNode(o,{name:"cardViewport",class:"view-icon"})])])):l.createCommentVNode("",!0)]}),rowCreate:l.withCtx(({row:d,index:O})=>[l.createElementVNode("span",{title:"新增",class:"row-create-wrap",onClick:$=>No(d,O)},[l.createVNode(o,{name:"rowCreate",style:{width:"10px",height:"10px"}})],8,vn)]),operateCol:l.withCtx(()=>[l.createVNode(r,{title:"选择显示列信息",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:So},{reference:l.withCtx(()=>[l.createElementVNode("span",bn,[l.createVNode(o,{name:"operate",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),default:l.withCtx(()=>[l.createElementVNode("div",kn,[a[14]||(a[14]=l.createElementVNode("div",{class:"group-title"},"表格操作",-1)),l.createVNode(n,{"model-value":me.value,"active-text":"排序","inactive-text":"",style:{"margin-right":"8px"},onChange:a[3]||(a[3]=d=>ja(d,"sortable"))},null,8,["model-value"]),l.createVNode(n,{"model-value":Oe.value,"active-text":"筛选","inactive-text":"",style:{"margin-right":"8px"},onChange:a[4]||(a[4]=d=>ja(d,"filterable"))},null,8,["model-value"]),l.createVNode(n,{"model-value":Re.value,"active-text":"编辑所有表头","inactive-text":"",onChange:a[5]||(a[5]=d=>ja(d,"operable"))},null,8,["model-value"]),a[15]||(a[15]=l.createElementVNode("div",{class:"group-title"},"表格列操作",-1)),l.createVNode(t,{modelValue:oe.value,"onUpdate:modelValue":a[6]||(a[6]=d=>oe.value=d),style:{height:"100%"},min:2,ref_key:"checkboxGroupRef",ref:V},{default:l.withCtx(()=>[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(ia.value,d=>(l.openBlock(),l.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:d.label},[l.createVNode(c,{value:d.label,style:{width:"100%",marginRight:0}},{default:l.withCtx(()=>[l.createElementVNode("span",{title:d.label,style:{display:"inline-block",width:"250px",overflow:"hidden","text-overflow":"ellipsis","white-space":"nowrap"}},l.toDisplayString(d.label),9,mn)]),_:2},1032,["value"]),l.createVNode(r,{title:"列操作",placement:"left",teleported:!1,trigger:"hover"},{reference:l.withCtx(()=>[l.createVNode(o,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:l.withCtx(()=>{var O;return[l.createElementVNode("div",Sn,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList((O=Object.keys(d))==null?void 0:O.filter($=>{var M;return(M=Ol.value)==null?void 0:M.find(k=>(k==null?void 0:k.value)===$)}),$=>{var M,k;return l.openBlock(),l.createElementBlock("div",{key:$},[l.createVNode(n,{"model-value":d==null?void 0:d[$],"active-text":(k=(M=Ol.value)==null?void 0:M.find(_=>(_==null?void 0:_.value)===$))==null?void 0:k.label,onChange:_=>Jr(_,$,d)},null,8,["model-value","active-text","onChange"])])}),128))])]}),_:2},1024),l.createElementVNode("span",xn,[l.createVNode(o,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:1},8,["modelValue"])])]),_:1})]),content:l.withCtx(d=>{var O,$,M,k,_,m,B,b,H,F,G,u,w,ue,R,C,U,le,ee,Y;return[((O=d==null?void 0:d.column)==null?void 0:O.label)==="OCR图片"||(($=d==null?void 0:d.column)==null?void 0:$.prop)==="OCR图片"?(l.openBlock(),l.createElementBlock("div",Cn,[l.createVNode(r,{"popper-class":"file-popover",placement:"right",trigger:"click",effect:"light",width:"auto"},{reference:l.withCtx(()=>[l.createVNode(o,{name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:a[7]||(a[7]=l.withModifiers(()=>{},["stop"])),title:"查看OCR图片"})]),default:l.withCtx(()=>{var fe;return[l.createElementVNode("div",Dn,[((fe=cr(d))==null?void 0:fe.length)===0?(l.openBlock(),l.createElementBlock("div",Tn,a[16]||(a[16]=[l.createElementVNode("div",{class:"prop-url"},"暂无图片",-1)]))):(l.openBlock(!0),l.createElementBlock(l.Fragment,{key:1},l.renderList(cr(d),te=>(l.openBlock(),l.createElementBlock("div",{class:"file-list-pop",key:(te==null?void 0:te.url)||(te==null?void 0:te.name)},[l.createElementVNode("div",{class:"prop-url",title:Hl(te),onClick:J=>Wa(te)},l.toDisplayString(Hl(te)),9,An),l.createElementVNode("div",{class:"prop-download",onClick:J=>Ga(te)}," 下载 ",8,Nn)]))),128))])]}),_:2},1024)])):_o(d)?(l.openBlock(),l.createBlock(r,{key:1,"popper-class":"file-popover",placement:"right",trigger:"hover",effect:"light",width:"auto"},{reference:l.withCtx(()=>[l.createElementVNode("span",En,l.toDisplayString(dl(d)),1)]),default:l.withCtx(()=>{var fe,te;return[l.createElementVNode("div",_n,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList((te=d==null?void 0:d.row)==null?void 0:te[(fe=d==null?void 0:d.column)==null?void 0:fe.prop],J=>(l.openBlock(),l.createElementBlock("div",Bn,[l.createElementVNode("div",{class:"prop-url",title:Hl(J),onClick:ie=>Wa(J)},l.toDisplayString(Hl(J)),9,On),l.createElementVNode("div",{class:"prop-download",onClick:ie=>Ga(J)}," 下载 ",8,wn)]))),256))])]}),_:2},1024)):(l.openBlock(),l.createElementBlock("div",{key:2,style:l.normalizeStyle({color:!Array.isArray(dl(d))&&((k=(M=dl(d))==null?void 0:M.toString())!=null&&k.includes(".txt")||(m=(_=dl(d))==null?void 0:_.toString())!=null&&m.includes(".cpt")||(b=(B=dl(d))==null?void 0:B.toString())!=null&&b.includes(".cyd"))?"var(--vertical-menuitem-active-bg)":"",textDecoration:!Array.isArray(dl(d))&&((F=(H=dl(d))==null?void 0:H.toString())!=null&&F.includes(".txt")||(u=(G=dl(d))==null?void 0:G.toString())!=null&&u.includes(".cpt")||(ue=(w=dl(d))==null?void 0:w.toString())!=null&&ue.includes(".cyd"))?"underline":"",cursor:!Array.isArray(dl(d))&&((C=(R=dl(d))==null?void 0:R.toString())!=null&&C.includes(".txt")||(le=(U=dl(d))==null?void 0:U.toString())!=null&&le.includes(".cpt")||(Y=(ee=dl(d))==null?void 0:ee.toString())!=null&&Y.includes(".cyd"))?"pointer":"",marginLeft:(d==null?void 0:d.colIndex)===0?`${((d==null?void 0:d.level)??0)*20}px`:0}),onClick:fe=>Ur(dl(d))},l.toDisplayString(dl(d)===0?"0":dl(d)),13,Un))]}),_:2},[((E=Dl.value)==null?void 0:E.length)>0&&l.unref(ya)!==l.unref(we)?{name:"actions",fn:l.withCtx(({item:d})=>[l.createVNode(r,{title:"",placement:"left-start","popper-class":"menu-operate-popover"},{reference:l.withCtx(()=>[l.createVNode(o,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"},onClick:a[0]||(a[0]=l.withModifiers(()=>{},["stop"]))})]),default:l.withCtx(()=>[l.createElementVNode("div",hn,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(Hr(Dl.value,d),(O,$)=>(l.openBlock(),l.createElementBlock("div",{class:"menu-config-item",key:$,onClick:l.withModifiers(M=>xa(O==null?void 0:O.label,d,{extra:O}),["stop"])},[l.createElementVNode("div",{style:l.normalizeStyle({color:O==null?void 0:O.textColor}),class:"extra-button-label"},l.toDisplayString(O==null?void 0:O.label),5)],8,yn))),128))])]),_:2},1024)]),key:"0"}:void 0,((L=Z.value)==null?void 0:L.length)>0?{name:"batchButton",fn:l.withCtx(d=>[l.withDirectives(l.createVNode(Io,{lockingPage:l.unref(ya)===l.unref(we),buttons:d.buttons,selectTableItems:El.value,onButtonClick:a[2]||(a[2]=O=>xa(O,"",{}))},null,8,["lockingPage","buttons","selectTableItems"]),[[l.vShow,pe.value]]),l.withDirectives(l.createElementVNode("div",null,null,512),[[l.vShow,!pe.value]])]),key:"1"}:void 0]),1032,["pageObj","showIndex","isTree","summaryInfo","columns","defaultSort","isCardViewport","checkedColumns","tableData","isEditViewport","isShowPagination","allowSelect","extraButton","rowButton","cacheExtraButtons","isClearSelection"])):l.createCommentVNode("",!0),l.createVNode(Il.ssDialog,{title:yl.value,visible:jl.value,width:_r.value,onBeforeDestroy:Wr,style:{height:"74%"}},{default:l.withCtx(()=>[l.createElementVNode("div",jn,[l.createVNode(Sl.ssForm,{rowContents:be.value,isEnableWrap:!1,showOperator:!1,onChange:xo,onFixChangeValue:Xr,onClickTrigger:Gr,isEdit:ga.value,onBlurChange:Vr,onCreate:qr,onTagChange:wr},null,8,["rowContents","isEdit"])])]),footer:l.withCtx(()=>[ba.value?(l.openBlock(),l.createElementBlock("div",Ln,[l.createVNode(i,{onClick:a[8]||(a[8]=d=>jl.value=!1),id:"themeBorderButton"},{default:l.withCtx(()=>a[17]||(a[17]=[l.createTextVNode(l.toDisplayString("取消"))])),_:1,__:[17]}),l.createVNode(i,{class:"ok-button",onClick:a[9]||(a[9]=d=>ca(!0)),id:"themeButton"},{default:l.withCtx(()=>a[18]||(a[18]=[l.createTextVNode(l.toDisplayString("确认"))])),_:1,__:[18]})])):l.createCommentVNode("",!0)]),_:1},8,["title","visible","width"]),l.createVNode(Il.ssDialog,{title:yl.value,visible:va.value,width:_a.value,onBeforeDestroy:a[11]||(a[11]=d=>va.value=!1)},{default:l.withCtx(()=>[l.createVNode(an)]),footer:l.withCtx(()=>[l.createElementVNode("div",Mn,[l.createVNode(i,{onClick:a[10]||(a[10]=d=>va.value=!1),class:"cancel-button",id:"themeBorderButton"},{default:l.withCtx(()=>a[19]||(a[19]=[l.createTextVNode(l.toDisplayString("取消"))])),_:1,__:[19]}),l.createVNode(i,{class:"ok-button",onClick:lo,id:"themeButton"},{default:l.withCtx(()=>a[20]||(a[20]=[l.createTextVNode(l.toDisplayString("确认"))])),_:1,__:[20]})])]),_:1},8,["title","visible","width"]),Rl.value?(l.openBlock(),l.createBlock(Sl.ssFilePreview,{key:1,fileDataList:Vl.value,onDestroy:Zr},null,8,["fileDataList"])):l.createCommentVNode("",!0),Me.value?(l.openBlock(),l.createBlock(Il.ssDialog,{key:2,visible:Me.value,onBeforeDestroy:ko,style:{height:"80vh",width:"80vw"},"body-class":"three-dialog-body","footer-class":"three-dialog-footer"},{default:l.withCtx(()=>[l.createVNode(pr.ThreeViewerHost,{files:ea.value,threeData:ve.value},null,8,["files","threeData"])]),_:1},8,["visible"])):l.createCommentVNode("",!0),l.createVNode(Il.ssDialog,{visible:e.componentVisible,onBeforeDestroy:a[12]||(a[12]=d=>e.componentVisible=!1),width:_a.value,style:{height:"70vh"}},{default:l.withCtx(()=>[l.createVNode(f,{dialogItem:zl.value},null,8,["dialogItem"])]),_:1},8,["visible","width"]),l.createVNode(Il.ssDialog,{title:"上传OCR图片",visible:ka.value,onBeforeDestroy:Ia,width:"600px"},{default:l.withCtx(()=>[l.withDirectives((l.openBlock(),l.createElementBlock("div",null,[l.createVNode(N,{"file-list":Ml.value,"onUpdate:fileList":a[13]||(a[13]=d=>Ml.value=d),multiple:"",drag:"",action:"","auto-upload":!1,limit:20,accept:"image/*","on-change":co,class:"upload-content"},{tip:l.withCtx(()=>a[21]||(a[21]=[l.createElementVNode("div",{class:"el-upload__tip tip-content"}," 请上传图片文件,大小不超过10MB ",-1)])),default:l.withCtx(()=>[l.createVNode(v,{class:"el-icon--upload"},{default:l.withCtx(()=>[l.createVNode(l.unref(A.upload_filled_default))]),_:1}),a[22]||(a[22]=l.createElementVNode("div",{class:"el-upload__text"},[l.createTextVNode(" 将图片拖到此处或"),l.createElementVNode("em",null,"点击上传")],-1))]),file:l.withCtx(({file:d,index:O})=>[l.createElementVNode("div",$n,[l.createElementVNode("div",{class:"upload-content-title",style:{flex:"1",overflow:"hidden","text-overflow":"ellipsis","white-space":"nowrap"},title:d==null?void 0:d.name},l.toDisplayString(d==null?void 0:d.name),9,Pn),l.createElementVNode("div",Fn,[l.createVNode(o,{class:"icon-blue",name:"EyeFill",style:{width:"15px",height:"15px",cursor:"pointer",color:"var(--ssform-label-color)"},onClick:$=>to(d),title:"预览"},null,8,["onClick"]),l.createVNode(o,{class:"icon-blue",name:"Cancel",style:{width:"15px",height:"15px",cursor:"pointer",color:"var(--ssform-label-color)"},onClick:$=>ho(O),title:"删除"},null,8,["onClick"])])])]),_:1},8,["file-list"])])),[[S,la.value]])]),footer:l.withCtx(()=>[l.createElementVNode("div",Rn,[l.createVNode(i,{onClick:Ia,id:"themeBorderButton",disabled:la.value},{default:l.withCtx(()=>a[23]||(a[23]=[l.createTextVNode("取消")])),_:1,__:[23]},8,["disabled"]),l.createVNode(i,{class:"ok-button",onClick:po,id:"themeButton",disabled:la.value},{default:l.withCtx(()=>a[24]||(a[24]=[l.createTextVNode("确认")])),_:1,__:[24]},8,["disabled"])])]),_:1},8,["visible"]),Ba.value?(l.openBlock(),l.createBlock(Sl.ssFilePreview,{key:3,fileDataList:Oa.value,onDestroy:fo},null,8,["fileDataList"])):l.createCommentVNode("",!0),l.createVNode(Il.ssDialog,{title:Je.title,visible:Je.show,width:Je.width,onBeforeDestroy:so},{default:l.withCtx(()=>[l.createElementVNode("div",Kn,[l.createVNode(Sl.ssForm,{rowContents:Je==null?void 0:Je.contents,formRules:Je==null?void 0:Je.formRules,showOperator:!1,buttonValue:Je.buttonValue,isEdit:ga.value,isStartJustify:!1,isEnableWrap:!1,onOnButtonClick:uo},null,8,["rowContents","formRules","buttonValue","isEdit"])])]),_:1},8,["title","visible","width"])])}}},Vn=Aa._export_sfc(zn,[["__scopeId","data-v-24de0450"]]);exports.formGetOptions=Da;exports.getSelectRow=Ta;exports.ssTable=Vn;exports.useFormComp=br;exports.useFormToTableComp=hr;
|