ss-component-new 1.3.283 → 1.3.285

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (158) hide show
  1. package/dist/{MTLLoader-CZBprXNP.cjs → MTLLoader-CdxYhBAE.cjs} +1 -1
  2. package/dist/{MTLLoader-ByvO3xpX.js → MTLLoader-RsaYZtZ_.js} +1 -1
  3. package/dist/{OrbitControls-pu_IAkAV.cjs → OrbitControls-BNTHZN2P.cjs} +1 -1
  4. package/dist/{OrbitControls-gFOfDXco.js → OrbitControls-D4mDZcDl.js} +1 -1
  5. package/dist/{URDFLoader-CJmlsLyG.cjs → URDFLoader-B56WRl4z.cjs} +1 -1
  6. package/dist/{URDFLoader-DItN2Cwe.js → URDFLoader-BPNyxykV.js} +2 -2
  7. package/dist/{animationData-DCnGuqAH.js → animationData-D4Q3av_t.js} +3 -3
  8. package/dist/animationData-DiyxzUT8.cjs +1 -0
  9. package/dist/array-CpxgPs3a.cjs +1 -0
  10. package/dist/{array-B8KzZ5ux.js → array-DuZDl88A.js} +19 -18
  11. package/dist/clone-BrrxU6_J.js +8 -0
  12. package/dist/clone-Dn6v3xp6.cjs +1 -0
  13. package/dist/dayjs.min-DRU3LNcy.cjs +1 -0
  14. package/dist/dayjs.min-Dx_LN6Bu.js +366 -0
  15. package/dist/{eleIcon-BSJV_1ZM.js → eleIcon-BLNEA11T.js} +1 -1
  16. package/dist/{iconfont-DAGWcDwE.js → iconfont-DkmQztG1.js} +2 -2
  17. package/dist/{iconfont-Cgm0Wjk4.cjs → iconfont-Dq-DsQsx.cjs} +1 -1
  18. package/dist/icons/svg/softCancel.svg +1 -0
  19. package/dist/icons/svg/softConfirm.svg +1 -0
  20. package/dist/icons/svg/softRemove.svg +1 -0
  21. package/dist/index--6MSMD-8.cjs +1 -0
  22. package/dist/{index-Du7JJqdx.js → index--PidpjSy.js} +4 -3
  23. package/dist/index--ZVD8xbU.js +83 -0
  24. package/dist/{index-CDlw-J9H.js → index-8CZJn10Y.js} +2 -2
  25. package/dist/index-9I9R7yqt.cjs +15 -0
  26. package/dist/index-B6b9Lr8M.js +623 -0
  27. package/dist/{index-C0s4Fa0R.js → index-BEGr3hBb.js} +32 -31
  28. package/dist/index-BET-Jwi1.cjs +1 -0
  29. package/dist/index-BIV-s4QY.js +29 -0
  30. package/dist/{index-CHH8aozZ.js → index-BIkySu-W.js} +2 -2
  31. package/dist/index-BOHy6XZd.cjs +1 -0
  32. package/dist/{index-Bj-ss9u6.js → index-BcwDR57s.js} +2 -2
  33. package/dist/index-BdyYMxx4.cjs +1 -0
  34. package/dist/{index-DB9zlG2m.cjs → index-BeuuWlVO.cjs} +1 -1
  35. package/dist/index-BjZpJRk2.cjs +1 -0
  36. package/dist/index-BlAISTfa.cjs +1 -0
  37. package/dist/index-Bs0qreV1.cjs +1 -0
  38. package/dist/{index-_uOv3SVz.js → index-BsDMamej.js} +1 -1
  39. package/dist/{index-BkBMQfsT.js → index-C1dVsNLG.js} +1 -1
  40. package/dist/{index-CULs51Vg.js → index-C5bOtOIk.js} +4 -4
  41. package/dist/{index-UqJOpNhM.js → index-C7-Idrnv.js} +2 -2
  42. package/dist/index-C81Qb0f2.js +209 -0
  43. package/dist/index-CAcP6bx_.cjs +1 -0
  44. package/dist/index-CPFAai4T.cjs +2 -0
  45. package/dist/{index-K_IiVShj.js → index-CQS-NY65.js} +25 -24
  46. package/dist/index-CQcXApCn.cjs +1 -0
  47. package/dist/index-CUJ_cdPT.cjs +1 -0
  48. package/dist/{index-BjEIX08g.js → index-CV8QlXGI.js} +3 -3
  49. package/dist/index-CXgZFuTt.cjs +1 -0
  50. package/dist/{index-BZ_R-Jcp.js → index-CY_HG5Gj.js} +4 -4
  51. package/dist/index-Ca-FxCDv.cjs +1 -0
  52. package/dist/index-Cbb4eaBp.js +343 -0
  53. package/dist/{index-D02CK1_5.js → index-CdKgZ2A_.js} +22 -21
  54. package/dist/{index-KrjXZO_d.cjs → index-CdrBTtcu.cjs} +1 -1
  55. package/dist/{index-CPmO67dF.js → index-Cg7Mpfpj.js} +13 -13
  56. package/dist/{index-BZwKLYgT.cjs → index-CuHxF23O.cjs} +1 -1
  57. package/dist/{index-pCW3eQ8e.js → index-D-kGKttu.js} +15 -14
  58. package/dist/{index-Dr9e3mBT.js → index-D21dwfqO.js} +24 -24
  59. package/dist/index-D3qNUVY7.cjs +1 -0
  60. package/dist/{index-77VURUPj.cjs → index-DAwnZFmG.cjs} +1 -1
  61. package/dist/{index-Cy1XXdCZ.cjs → index-DLN6R2tJ.cjs} +1 -1
  62. package/dist/index-DTiolIgS.cjs +7 -0
  63. package/dist/{index-C8kDBsVW.js → index-DTsHI5xQ.js} +2 -2
  64. package/dist/index-DXWN-UJr.cjs +1 -0
  65. package/dist/{index-Cf5PK2bA.js → index-DXjgumn5.js} +5 -5
  66. package/dist/index-Df8bxCwR.js +665 -0
  67. package/dist/{index-B_rDLuPm.js → index-DfAmIlWW.js} +3355 -3351
  68. package/dist/{index-m6ZHCUtH.cjs → index-DiPWs_9n.cjs} +1 -1
  69. package/dist/{index-C2PJu8mA.js → index-DoEwWbTL.js} +1421 -1409
  70. package/dist/index-DsNHJYr-.cjs +1 -0
  71. package/dist/index-DtYkQPnf.cjs +1 -0
  72. package/dist/index-Dx0DeTSC.js +9370 -0
  73. package/dist/{index-B_CkJtn2.js → index-DxhNwr8X.js} +1 -1
  74. package/dist/{index-BusM6WrM.js → index-H_NM-ZF-.js} +2 -2
  75. package/dist/{index-D9SznbhK.js → index-JG59WTIq.js} +1 -1
  76. package/dist/index-QG4F5kTH.js +2755 -0
  77. package/dist/{index-CW0nTu7g.js → index-RSaGZhb3.js} +4 -4
  78. package/dist/index-W8p89C7t.cjs +1 -0
  79. package/dist/index-WTaP_KDd.cjs +1 -0
  80. package/dist/index-bPKGQ9bV.cjs +25 -0
  81. package/dist/{index-DpfXqgm2.js → index-cFt1QbzL.js} +33 -32
  82. package/dist/{index-B5tAsf_R.js → index-gFBtUdzh.js} +15 -14
  83. package/dist/{index-DVrEV4RS.cjs → index-mHmXlK2R.cjs} +1 -1
  84. package/dist/{index-wHrfokYf.cjs → index-qIpeOak9.cjs} +1 -1
  85. package/dist/index-vbxWL2yo.cjs +1 -0
  86. package/dist/{index.vue_vue_type_style_index_0_scoped_6b92e250_lang-mXh6sJo_.js → index.vue_vue_type_style_index_0_scoped_6b92e250_lang-DBQ_-V1_.js} +130 -129
  87. package/dist/{index.vue_vue_type_style_index_0_scoped_6b92e250_lang-GxCgBV8k.cjs → index.vue_vue_type_style_index_0_scoped_6b92e250_lang-DpyDtD61.cjs} +327 -327
  88. package/dist/isNil-CjWwlQS3.js +6 -0
  89. package/dist/isNil-x28vo2CT.cjs +1 -0
  90. package/dist/{isString-BLBZkTvd.js → isString-BA9CJNsy.js} +1 -1
  91. package/dist/{main-DECFHBC8.cjs → main-Avmwy4Fu.cjs} +2 -2
  92. package/dist/{main-Dglgquls.js → main-Qn9bfEMh.js} +4 -4
  93. package/dist/menu-CtG1loFf.js +5637 -0
  94. package/dist/menu-Hdw0L-Y2.cjs +12 -0
  95. package/dist/{menuIndex-6Fi3NW3Q.js → menuIndex-DmS5cMwB.js} +44 -42
  96. package/dist/menuIndex-DqY0uteo.cjs +1 -0
  97. package/dist/{request-B3-w_S8Z.js → request-CoGtW0Ux.js} +60 -60
  98. package/dist/ss-component.cjs +1 -1
  99. package/dist/ss-component.css +1 -1
  100. package/dist/ss-component.js +19 -18
  101. package/dist/ss-component2.cjs +1 -1
  102. package/dist/ss-component2.js +13 -13
  103. package/dist/threeModel-Dr6PqFqA.cjs +1 -0
  104. package/dist/{threeModel-BpjWJsnX.js → threeModel-L66n6sW7.js} +5 -5
  105. package/dist/{threePreview-DeEknsco.js → threePreview-BwElOyqr.js} +5 -5
  106. package/dist/threePreview-CWRtmSvh.cjs +1 -0
  107. package/dist/{threeSceneView-D5z_ADmg.js → threeSceneView-BEwen70K.js} +17 -15
  108. package/dist/{threeSceneView-C_ianMnn.cjs → threeSceneView-BpPiRRPf.cjs} +1 -1
  109. package/dist/{threeSceneViewForCPMPIP-CMDrp7Du.js → threeSceneViewForCPMPIP-BIiU_5px.js} +9 -9
  110. package/dist/{threeSceneViewForCPMPIP-BicBhum7.cjs → threeSceneViewForCPMPIP-DpwlxGoP.cjs} +1 -1
  111. package/dist/{threeTrackPathView-DDKn5Z5k.js → threeTrackPathView-BckFDqUs.js} +6 -6
  112. package/dist/threeTrackPathView-CamXHHnK.cjs +1 -0
  113. package/dist/threeViewerHost-DLLTNlTR.cjs +1 -0
  114. package/dist/{threeViewerHost-BgN5No1S.js → threeViewerHost-DQz7pHM9.js} +3 -3
  115. package/dist/{urdfTree-DYLobS3F.js → urdfTree-B6GL3kgV.js} +1 -1
  116. package/dist/{urdfTree-ghaTIId6.cjs → urdfTree-DDQw6tEb.cjs} +1 -1
  117. package/dist/{workpieceTreePanel-BAu_7YB6.cjs → workpieceTreePanel-B6AVU13A.cjs} +1 -1
  118. package/dist/{workpieceTreePanel-PUhlo13O.js → workpieceTreePanel-BvO881iH.js} +4 -4
  119. package/package.json +1 -1
  120. package/public/icons/svg/softCancel.svg +1 -0
  121. package/public/icons/svg/softConfirm.svg +1 -0
  122. package/public/icons/svg/softRemove.svg +1 -0
  123. package/dist/animationData-CIM8_iu6.cjs +0 -1
  124. package/dist/array-DlgywTCo.cjs +0 -1
  125. package/dist/clone-BjZYQq33.cjs +0 -1
  126. package/dist/clone-XNy-gcwO.js +0 -8
  127. package/dist/index-5zdMes-B.cjs +0 -1
  128. package/dist/index-7aU_bwDz.js +0 -8959
  129. package/dist/index-9Q1_s4bE.cjs +0 -1
  130. package/dist/index-B3yoiLPJ.cjs +0 -1
  131. package/dist/index-BAGLBch9.cjs +0 -1
  132. package/dist/index-BB392QRk.js +0 -672
  133. package/dist/index-BBxu8MeT.js +0 -89
  134. package/dist/index-BHLuFtij.cjs +0 -1
  135. package/dist/index-BIDFrngN.cjs +0 -1
  136. package/dist/index-BM4Blp7z.cjs +0 -1
  137. package/dist/index-BUxJL5W1.cjs +0 -1
  138. package/dist/index-BmTzLFkx.js +0 -630
  139. package/dist/index-BuAZTecX.cjs +0 -1
  140. package/dist/index-C-6jbR4D.cjs +0 -1
  141. package/dist/index-C6dVScaZ.js +0 -349
  142. package/dist/index-Cm-ohQUX.cjs +0 -1
  143. package/dist/index-D0k42JA4.cjs +0 -15
  144. package/dist/index-D4QFcxJ-.js +0 -9196
  145. package/dist/index-DGULgN2U.cjs +0 -1
  146. package/dist/index-DRBuICJi.cjs +0 -2
  147. package/dist/index-DeAnBGqU.cjs +0 -18
  148. package/dist/index-Dtq1IcgW.cjs +0 -1
  149. package/dist/index-RNu0IAS4.cjs +0 -1
  150. package/dist/index-RpaKc4Lu.cjs +0 -25
  151. package/dist/index-ZGUlK0ro.cjs +0 -1
  152. package/dist/index-ity_8Fmx.cjs +0 -1
  153. package/dist/index-vUaB-HgD.cjs +0 -1
  154. package/dist/menuIndex-SRHovjCX.cjs +0 -1
  155. package/dist/threeModel-BAzu1aRu.cjs +0 -1
  156. package/dist/threePreview-5dyC70n0.cjs +0 -1
  157. package/dist/threeTrackPathView-DHLZAc5E.cjs +0 -1
  158. package/dist/threeViewerHost-B_4KXwsO.cjs +0 -1
@@ -1,25 +0,0 @@
1
- "use strict";var yu=Object.defineProperty;var gu=(l,r,n)=>r in l?yu(l,r,{enumerable:!0,configurable:!0,writable:!0,value:n}):l[r]=n;var Rr=(l,r,n)=>gu(l,typeof r!="symbol"?r+"":r,n);const a=require("vue"),rl=require("./request-BC2w2vGr.cjs"),I=require("./index-DeAnBGqU.cjs"),pl=require("./index-D0k42JA4.cjs"),ql=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Pa=require("./index.vue_vue_type_style_index_0_scoped_6b92e250_lang-GxCgBV8k.cjs"),vr=require("./index-CUw6nGTo.cjs"),bi=require("./threeViewerHost-B_4KXwsO.cjs"),ca=require("./index-BZwKLYgT.cjs"),yr=require("./index-CW4qJdP8.cjs"),Jt=require("./index-C-6jbR4D.cjs");require("./index-77VURUPj.cjs");const Hs=require("./index-9Q1_s4bE.cjs");;/* empty css */const ki=require("./isString-DNBlKLZH.cjs"),Xt=require("./index.vue_vue_type_script_setup_true_lang-BKTJR2th.cjs"),Us=require("./index-BVaHwt5f.cjs"),bu=require("./index-KrjXZO_d.cjs"),An=require("./MTLLoader-CZBprXNP.cjs"),ku=require("./URDFLoader-CJmlsLyG.cjs");var xu="[object Boolean]";function qs(l){return l===!0||l===!1||rl.isObjectLike(l)&&rl.baseGetTag(l)==xu}function _u(l){return l===void 0}const wu=l=>l.match(/\((.*)\)/)[1],Cu={__name:"index",props:{isVisible:{type:Boolean,default:!1},title:{type:String,default:""},placement:{type:String,default:"bottom"},width:{type:Number,default:200},trigger:{type:String,default:"click"}},setup(l){const r=l,n=a.ref(null),o=a.ref(!1),s=a.ref(null);return a.watch(()=>r==null?void 0:r.isVisible,()=>{o.value=r==null?void 0:r.isVisible},{deep:!0,immediate:!0}),a.watch(()=>s.value,()=>{a.nextTick(()=>{var c,y;(y=(c=n.value)==null?void 0:c.updatePopper)==null||y.call(c)})},{deep:!0,immediate:!0}),(c,y)=>{const f=a.resolveComponent("el-popover");return a.openBlock(),a.createBlock(f,{visible:o.value,"onUpdate:visible":y[0]||(y[0]=v=>o.value=v),trigger:r.trigger,title:r==null?void 0:r.title,placement:r==null?void 0:r.placement,width:r==null?void 0:r.width,ref_key:"popOverRef",ref:n,"trigger-keys":"[]"},{reference:a.withCtx(()=>[a.createElementVNode("div",null,[a.renderSlot(c.$slots,"reference",{ref_key:"referenceRef",ref:s})])]),default:a.withCtx(()=>[a.createElementVNode("div",null,[a.renderSlot(c.$slots,"content")])]),_:3},8,["visible","trigger","title","placement","width"])}}},Eu={__name:"index",props:{value:{type:[String,Number],default:""}},setup(l){const r=l,n=a.computed(()=>{const o=String(r.value??"");return o==="已完成"?"task-status-completed":o==="进行中"?"task-status-running":o==="终止"||o==="暂停"?"task-status-stopped":""});return(o,s)=>l.value!==void 0&&l.value!==null?(a.openBlock(),a.createElementBlock("span",{key:0,class:a.normalizeClass(["task-status-tag",n.value])},a.toDisplayString(l.value===0?"0":l.value),3)):a.createCommentVNode("",!0)}},Su=ql._export_sfc(Eu,[["__scopeId","data-v-d81f59b4"]]);function Du(l,r,n,o={}){if(!l||!r||!n||n.length!==4)return;const s=l.getContext("2d");if(!s)return;const{color:c="rgba(255, 235, 59, 0.3)",strokeWidth:y=2,fillOpacity:f=.2}=o,v=l.getBoundingClientRect(),m=r.getBoundingClientRect(),u=r.naturalWidth,x=r.naturalHeight,E=m.width/u,B=m.height/x,w=Math.min(E,B),V=u*w,A=x*w,N=(v.width-V)/2,Y=(v.height-A)/2,b=n.map(([T,k])=>{const _=N+T*V,U=Y+k*A;return{x:_,y:U}});s.clearRect(0,0,l.width,l.height),s.beginPath(),s.moveTo(b[0].x,b[0].y);for(let T=1;T<b.length;T++)s.lineTo(b[T].x,b[T].y);s.closePath();const $=c.replace(/[\d.]+\)$/,`${f})`);s.fillStyle=$,s.fill(),s.strokeStyle=c.replace(/[\d.]+\)$/,"1)"),s.lineWidth=y,s.stroke()}function go(l){if(!l)return;const r=l.getContext("2d");r&&r.clearRect(0,0,l.width,l.height)}function Zt(l,r){if(!l||!r)return null;const n=l[r];return!n||!n.bboxNorm||!Array.isArray(n.bboxNorm)||n.bboxNorm.length!==4?null:{bboxNorm:n.bboxNorm,imageName:n.imageName||""}}const Nu={key:0,class:"ocr-img-preview-root"},Bu={class:"ocr-img-preview-window"},Tu={key:0,class:"img-preview-body"},Au={class:"img-preview-header"},zu={class:"img-header-left"},Mu={class:"img-name"},Ou={key:0,class:"img-header-right"},Iu={class:"img-index"},Lu={key:0,class:"img-thumb-list"},$u=["onClick"],Ru={key:1,class:"thumb-placeholder"},Vu={class:"thumb-name"},Pu={class:"img-preview-container"},Fu={key:0,class:"img-placeholder"},ju={key:2,class:"img-placeholder"},Hu={key:0},Uu={key:1},qu={key:1,class:"img-placeholder"},Wu=a.defineComponent({__name:"imgPreview",props:{visible:{type:Boolean,default:!1},images:{type:Array,default:()=>[]},defaultImageName:{type:String,default:""},fieldMeta:{type:Object,default:()=>({})},focusedFieldName:{type:String,default:""}},emits:["update:visible","close"],setup(l,{emit:r}){const n=l,o=r,s=a.computed({get:()=>n.visible,set:S=>o("update:visible",S)});let c=!1,y="",f=0,v=0,m=0,u=0,x=0,E=0,B=null;const w=S=>{var me,ue;const le=(ue=(me=S==null?void 0:S.target)==null?void 0:me.closest)==null?void 0:ue.call(me,".ocr-img-preview-window");return le||document.querySelector(".ocr-img-preview-window")},V=S=>{if(!S||S==="none")return{tx:0,ty:0};let le=S.match(/matrix\(([^)]+)\)/);if(le){const me=le[1].split(",").map(ue=>Number(ue.trim()));return{tx:(me==null?void 0:me[4])||0,ty:(me==null?void 0:me[5])||0}}if(le=S.match(/matrix3d\(([^)]+)\)/),le){const me=le[1].split(",").map(ue=>Number(ue.trim()));return{tx:(me==null?void 0:me[12])||0,ty:(me==null?void 0:me[13])||0}}return le=S.match(/translate\(\s*([-\d.]+)px\s*,\s*([-\d.]+)px\s*\)/),le?{tx:Number(le[1])||0,ty:Number(le[2])||0}:{tx:0,ty:0}},A=(S,le,me)=>{S.style.transform=`translate(${le}px, ${me}px)`},N=S=>{const le=w(S);if(!le)return;c=!0,B=le,y="move",f=S.clientX,v=S.clientY;const me=window.getComputedStyle(le),{tx:ue,ty:Ne}=V(me.transform);x=ue,E=Ne,document.addEventListener("mousemove",b),document.addEventListener("mouseup",$)},Y=(S,le)=>{const me=w(S);if(!me)return;c=!0,B=me,y=le,f=S.clientX,v=S.clientY;const ue=me.getBoundingClientRect();m=ue.width,u=ue.height;const Ne=window.getComputedStyle(me),{tx:pa,ty:_a}=V(Ne.transform);x=pa,E=_a,document.addEventListener("mousemove",b),document.addEventListener("mouseup",$)},b=S=>{if(!c||!B)return;const le=S.clientX-f,me=S.clientY-v,ue=360,Ne=420;let pa=m,_a=u,Wa=x,ee=E;if(y==="move"){Wa=x+le,ee=E+me,A(B,Wa,ee);return}if(y.includes("right")&&(pa=Math.max(ue,m+le)),y.includes("bottom")&&(_a=Math.max(Ne,u+me)),y.includes("left")){const la=m-le;la<ue?(pa=ue,Wa=x+(m-ue)):(pa=la,Wa=x+le)}if(y.includes("top")){const la=u-me;la<Ne?(_a=Ne,ee=E+(u-Ne)):(_a=la,ee=E+me)}B.style.width=`${pa}px`,B.style.height=`${_a}px`,A(B,Wa,ee)},$=()=>{c=!1,y="",B=null,document.removeEventListener("mousemove",b),document.removeEventListener("mouseup",$)},T=a.ref([]),k=a.ref(!1);a.watch(()=>n.images,async S=>{if(!Array.isArray(S)||S.length===0){T.value=[];return}k.value=!0;const le=[];for(const me of S)if(me.url&&!me.url.startsWith("blob:")&&!me.url.startsWith("http"))try{const ue=await Pa.downloadFile(me.url),Ne=URL.createObjectURL(ue);le.push({...me,blobUrl:Ne})}catch(ue){console.error(`Failed to load image for preview: ${me.url}`,ue),le.push({...me,blobUrl:""})}else le.push({...me,blobUrl:me.url});T.value=le,k.value=!1},{deep:!0,immediate:!0});const _=a.ref(0),U=a.ref(null),W=a.ref(null),ce=a.computed(()=>T.value[_.value]||null),Ee=()=>{if(!T.value.length){_.value=0;return}if(n.defaultImageName){const S=T.value.findIndex(le=>(le==null?void 0:le.name)===n.defaultImageName);_.value=S>=0?S:0}else _.value=0},Ie=S=>{if(!T.value.length)return;const le=Math.max(0,Math.min(S,T.value.length-1));_.value=le},De=()=>Ie(_.value-1),ne=()=>Ie(_.value+1),ge=S=>{if(!S)return;const le=T.value.findIndex(me=>(me==null?void 0:me.name)===S);le>=0&&(_.value=le)},X=()=>{if(!W.value)return;const S=W.value.parentElement;if(!S)return;const le=S.getBoundingClientRect();W.value.width=le.width,W.value.height=le.height},de=()=>{var ue,Ne;if(!W.value||!U.value||!n.focusedFieldName){W.value&&go(W.value);return}const S=(ue=U.value.$el)==null?void 0:ue.querySelector("img");if(!S)return;if(!S.complete||S.naturalWidth===0){S.onload=()=>{a.nextTick(()=>{de()})};return}const le=((Ne=ce.value)==null?void 0:Ne.name)||"",me=Zt(n.fieldMeta,n.focusedFieldName);if(!me){go(W.value);return}if(me.imageName!==le){go(W.value);return}X(),Du(W.value,S,me.bboxNorm)},Ke=()=>{a.nextTick(()=>{X(),de()})};a.watch(()=>n.focusedFieldName,()=>{if(!s.value)return;const S=Zt(n.fieldMeta,n.focusedFieldName);S!=null&&S.imageName&&ge(S.imageName),a.nextTick(()=>{de()})}),a.watch(()=>{var S;return(S=ce.value)==null?void 0:S.name},()=>{s.value&&a.nextTick(()=>{W.value&&go(W.value),de()})}),a.watch(()=>n.visible,S=>{S?(Ee(),a.nextTick(()=>{X(),de()})):W.value&&go(W.value)}),a.watch(()=>n.defaultImageName,()=>{s.value&&Ee()});let Ta=null;a.onMounted(()=>{var S;typeof ResizeObserver<"u"&&(Ta=new ResizeObserver(()=>{X(),a.nextTick(()=>{de()})}),(S=W.value)!=null&&S.parentElement&&Ta.observe(W.value.parentElement))}),a.onUnmounted(()=>{Ta&&(Ta.disconnect(),Ta=null),document.removeEventListener("mousemove",b),document.removeEventListener("mouseup",$)});const oe=()=>{W.value&&go(W.value),o("update:visible",!1),o("close")};return(S,le)=>{var _a,Wa;const me=a.resolveComponent("el-button"),ue=a.resolveComponent("el-image"),Ne=a.resolveComponent("Loading"),pa=a.resolveComponent("el-icon");return s.value?(a.openBlock(),a.createElementBlock("div",Nu,[le[12]||(le[12]=a.createElementVNode("div",{class:"ocr-img-preview-backdrop"},null,-1)),a.createElementVNode("div",Bu,[a.createElementVNode("div",{class:"ocr-img-preview-header",onMousedown:a.withModifiers(N,["stop"])},[le[8]||(le[8]=a.createElementVNode("span",{class:"ocr-img-preview-title"},"文件预览",-1)),a.createElementVNode("button",{type:"button",class:"ocr-img-preview-close",onClick:oe},"×")],32),a.createElementVNode("div",{class:"resizable-handle top",onMousedown:le[0]||(le[0]=a.withModifiers(ee=>Y(ee,"top"),["stop"]))},null,32),a.createElementVNode("div",{class:"resizable-handle right",onMousedown:le[1]||(le[1]=a.withModifiers(ee=>Y(ee,"right"),["stop"]))},null,32),a.createElementVNode("div",{class:"resizable-handle bottom",onMousedown:le[2]||(le[2]=a.withModifiers(ee=>Y(ee,"bottom"),["stop"]))},null,32),a.createElementVNode("div",{class:"resizable-handle left",onMousedown:le[3]||(le[3]=a.withModifiers(ee=>Y(ee,"left"),["stop"]))},null,32),a.createElementVNode("div",{class:"resizable-handle top-left",onMousedown:le[4]||(le[4]=a.withModifiers(ee=>Y(ee,"top-left"),["stop"]))},null,32),a.createElementVNode("div",{class:"resizable-handle top-right",onMousedown:le[5]||(le[5]=a.withModifiers(ee=>Y(ee,"top-right"),["stop"]))},null,32),a.createElementVNode("div",{class:"resizable-handle bottom-left",onMousedown:le[6]||(le[6]=a.withModifiers(ee=>Y(ee,"bottom-left"),["stop"]))},null,32),a.createElementVNode("div",{class:"resizable-handle bottom-right",onMousedown:le[7]||(le[7]=a.withModifiers(ee=>Y(ee,"bottom-right"),["stop"]))},null,32),ce.value?(a.openBlock(),a.createElementBlock("div",Tu,[a.createElementVNode("div",Au,[a.createElementVNode("div",zu,[a.createElementVNode("span",Mu,a.toDisplayString(ce.value.name?ce.value.name+(ce.value.url&&ce.value.url.lastIndexOf(".")!==-1?ce.value.url.substring(ce.value.url.lastIndexOf(".")):""):""),1)]),T.value.length>1?(a.openBlock(),a.createElementBlock("div",Ou,[a.createVNode(me,{size:"small",disabled:_.value===0,onClick:De},{default:a.withCtx(()=>le[9]||(le[9]=[a.createTextVNode("上一张")])),_:1,__:[9]},8,["disabled"]),a.createElementVNode("span",Iu,a.toDisplayString(_.value+1)+" / "+a.toDisplayString(T.value.length),1),a.createVNode(me,{size:"small",disabled:_.value===T.value.length-1,onClick:ne},{default:a.withCtx(()=>le[10]||(le[10]=[a.createTextVNode("下一张")])),_:1,__:[10]},8,["disabled"])])):a.createCommentVNode("",!0)]),T.value.length>1?(a.openBlock(),a.createElementBlock("div",Lu,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(T.value,(ee,la)=>(a.openBlock(),a.createElementBlock("div",{key:(ee.name||"")+"-"+la,class:a.normalizeClass(["img-thumb-item",{active:la===_.value}]),onClick:Ve=>Ie(la)},[ee!=null&&ee.blobUrl?(a.openBlock(),a.createBlock(ue,{key:0,src:ee.blobUrl,fit:"cover",class:"thumb-image","preview-src-list":[ee.blobUrl],"initial-index":0},null,8,["src","preview-src-list"])):(a.openBlock(),a.createElementBlock("div",Ru,"加载失败")),a.createElementVNode("div",Vu,a.toDisplayString(ee.name||"-"),1)],10,$u))),128))])):a.createCommentVNode("",!0),a.createElementVNode("div",Pu,[k.value?(a.openBlock(),a.createElementBlock("div",Fu,[a.createVNode(pa,{class:"is-loading"},{default:a.withCtx(()=>[a.createVNode(Ne)]),_:1}),le[11]||(le[11]=a.createElementVNode("span",null,"图片加载中...",-1))])):(_a=ce.value)!=null&&_a.blobUrl?(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[a.createVNode(ue,{ref_key:"imageRef",ref:U,src:ce.value.blobUrl,fit:"contain",class:"preview-image","preview-src-list":[ce.value.blobUrl],onLoad:Ke},null,8,["src","preview-src-list"]),a.createElementVNode("canvas",{ref_key:"canvasRef",ref:W,class:"highlight-canvas"},null,512)],64)):(a.openBlock(),a.createElementBlock("div",ju,[(Wa=ce.value)!=null&&Wa.url?(a.openBlock(),a.createElementBlock("span",Hu,"图片加载失败")):(a.openBlock(),a.createElementBlock("span",Uu,"暂无图片"))]))])])):(a.openBlock(),a.createElementBlock("div",qu,"暂无图片"))])])):a.createCommentVNode("",!0)}}}),Ku=ql._export_sfc(Wu,[["__scopeId","data-v-48a4ecb1"]]),Yu={class:"cert-preview-body"},Gu={key:0,class:"pdf-preview-container"},Ju={class:"thumbs"},Xu=["onClick"],Zu={class:"thumb-img"},Qu=["src"],ed={key:1,class:"thumb-loading"},ad={class:"thumb-title"},ld={class:"viewer"},rd={key:0,class:"viewer-img-wrap"},nd=["src"],od={key:1,class:"viewer-loading"},id=a.defineComponent({__name:"CertificatePreview",props:{visible:{type:Boolean},versions:{}},emits:["update:visible"],setup(l,{emit:r}){const n=l,o=r,s=a.ref(""),c=a.ref(""),y=a.computed(()=>(n.versions||[]).find(w=>String(w.versionId)===String(s.value))),f=a.ref({}),v=a.ref(""),m=a.ref("证书附件.pdf"),u=()=>{try{Object.values(f.value||{}).forEach(w=>{w&&URL.revokeObjectURL(w)}),v.value&&URL.revokeObjectURL(v.value)}catch{}f.value={},v.value=""},x=async w=>{if(!w||w.fileType==="pdf")return;const V=Array.isArray(w.images)?w.images:[];for(const A of V){const N=A==null?void 0:A.url;if(!(!N||f.value[N]))try{const Y=await I.platformDownloadFile({url:N}),b=URL.createObjectURL(Y.data);f.value={...f.value,[N]:b}}catch{}}},E=async w=>{var A;if(!w||w.fileType!=="pdf"){v.value="";return}const V=w.sourceUrl||"";if(!V){v.value="";return}if(v.value){try{URL.revokeObjectURL(v.value)}catch{}v.value=""}try{console.log("[CertificatePreview] 下载PDF附件:",{url:V,versionId:w==null?void 0:w.versionId,certNo:w==null?void 0:w.certNo});const N=await I.platformDownloadFile({url:V});console.log("[CertificatePreview] PDF响应:",{url:V,status:N==null?void 0:N.status,size:(A=N==null?void 0:N.data)==null?void 0:A.size});const Y=URL.createObjectURL(N.data);v.value=Y;const b=w.certNo?String(w.certNo):"";m.value=b?`${b}.pdf`:"证书附件.pdf"}catch(N){console.error("[CertificatePreview] PDF加载失败:",{url:V,error:N}),v.value=""}};a.watch(()=>n.visible,async w=>{var A;if(!w){u();return}const V=(A=n.versions)==null?void 0:A[0];s.value=(V==null?void 0:V.versionId)||"",await x(V),await E(V)},{immediate:!0}),a.watch(()=>s.value,async()=>{var V,A;const w=y.value;if(!w){c.value="",v.value="";return}if(w.fileType==="pdf"){c.value="",await E(w);return}v.value="",c.value=((A=(V=w.images)==null?void 0:V[0])==null?void 0:A.url)||"",await x(w)},{immediate:!0});const B=()=>{o("update:visible",!1),u()};return a.onBeforeUnmount(()=>{u()}),(w,V)=>{const A=a.resolveComponent("el-empty"),N=a.resolveComponent("el-tab-pane"),Y=a.resolveComponent("el-tabs"),b=a.resolveComponent("el-button"),$=a.resolveComponent("el-dialog");return a.openBlock(),a.createBlock($,{"model-value":w.visible,title:"证书附件预览",width:"1100px","close-on-click-modal":!1,onClose:B},{footer:a.withCtx(()=>[a.createVNode(b,{id:"themeBorderButton",onClick:B},{default:a.withCtx(()=>V[1]||(V[1]=[a.createTextVNode("关闭")])),_:1,__:[1]})]),default:a.withCtx(()=>[w.versions&&w.versions.length>0?(a.openBlock(),a.createBlock(Y,{key:0,modelValue:s.value,"onUpdate:modelValue":V[0]||(V[0]=T=>s.value=T),type:"card",class:"cert-version-tabs"},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(w.versions,T=>(a.openBlock(),a.createBlock(N,{key:T.versionId,name:T.versionId,label:T.label},{default:a.withCtx(()=>[a.createElementVNode("div",Yu,[T.fileType==="pdf"?(a.openBlock(),a.createElementBlock("div",Gu,[v.value?(a.openBlock(),a.createBlock(pl.SsFilePreview,{key:1,fileName:m.value,blobUrl:v.value},null,8,["fileName","blobUrl"])):(a.openBlock(),a.createBlock(A,{key:0,description:"加载中"}))])):(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[a.createElementVNode("div",Ju,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(T.images||[],k=>(a.openBlock(),a.createElementBlock("div",{key:k.url,class:a.normalizeClass(["thumb",{active:k.url===c.value}]),onClick:_=>c.value=k.url},[a.createElementVNode("div",Zu,[f.value[k.url]?(a.openBlock(),a.createElementBlock("img",{key:0,src:f.value[k.url]},null,8,Qu)):(a.openBlock(),a.createElementBlock("div",ed,"加载中"))]),a.createElementVNode("div",ad,a.toDisplayString(k.name),1)],10,Xu))),128))]),a.createElementVNode("div",ld,[c.value?(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[f.value[c.value]?(a.openBlock(),a.createElementBlock("div",rd,[a.createElementVNode("img",{class:"viewer-img",src:f.value[c.value]},null,8,nd)])):(a.openBlock(),a.createElementBlock("div",od,"加载中"))],64)):(a.openBlock(),a.createBlock(A,{key:0,description:"暂无图片"}))])],64))])]),_:2},1032,["name","label"]))),128))]),_:1},8,["modelValue"])):(a.openBlock(),a.createBlock(A,{key:1,description:"暂无可预览的证书附件"}))]),_:1},8,["model-value"])}}}),td=ql._export_sfc(id,[["__scopeId","data-v-220703c0"]]),sd={class:"ocr-candidate-wrap"},cd={class:"ocr-candidate-left"},ud={key:1},dd={key:0},pd={key:1},fd={key:2},hd={key:3},vd={key:0,class:"ocr-candidate-right"},md={class:"ocr-candidate-actions"},yd={key:1},gd={class:"dialog-footer"},bd={__name:"OCRCandidateDialog",props:{visible:{type:Boolean,default:!1},candidates:{type:Array,default:()=>[]},columns:{type:Array,default:()=>[]},nameProp:{type:String,default:""},mfrProp:{type:String,default:""}},emits:["update:visible","submit","preview-file"],setup(l,{emit:r}){const n=(_=[])=>{const U=[],W=ce=>{(ce||[]).forEach(Ee=>{if(!Ee)return;const Ie=Ee.children||Ee.childrens||Ee.columns;Array.isArray(Ie)&&Ie.length>0?W(Ie):U.push(Ee)})};return W(_),U},o=l,s=r,c=a.computed(()=>{var _;return((_=E.value)==null?void 0:_.allowAdd)!==!1}),y=a.computed(()=>{var _;return((_=E.value)==null?void 0:_.allowReplace)!==!1}),f=_=>{if(!_)return[];if(Array.isArray(_))return _;if(typeof _=="string")try{const U=JSON.parse(_);return Array.isArray(U)?U:[]}catch{return[]}return[]},v=_=>{s("preview-file",_)},m=a.ref([]),u=a.ref(0),x=a.ref("");a.watch(()=>o.candidates,_=>{var U,W;m.value=(_||[]).map(ce=>({...ce,...(ce==null?void 0:ce.ocrRow)||{},selectedTargetId:(ce==null?void 0:ce.selectedTargetId)||"",__decision:ce==null?void 0:ce.__decision})),u.value=0,x.value=((W=(U=m.value)==null?void 0:U[0])==null?void 0:W.selectedTargetId)||""},{immediate:!0,deep:!0}),a.watch(()=>o.visible,_=>{var U,W;_&&(u.value=0,x.value=((W=(U=m.value)==null?void 0:U[0])==null?void 0:W.selectedTargetId)||"")});const E=a.computed(()=>{var U;const _=Number(u.value||0);return((U=m.value||[])==null?void 0:U[_])||null}),B=a.computed(()=>(n(o.columns||[])||[]).filter(W=>W&&W.prop).filter(W=>W.type!=="operate"&&W.label!=="操作"&&W.prop!=="operate")),w=a.computed(()=>B.value.filter(_=>_.label!=="证书附件"&&_.prop!=="证书附件")),V=_=>{if(!_)return;const U=(m.value||[]).findIndex(W=>(W==null?void 0:W.idx)===(_==null?void 0:_.idx));U>-1&&(u.value=U,x.value=(_==null?void 0:_.selectedTargetId)||"")},A=_=>{if(!_){x.value="";return}x.value=String((_==null?void 0:_.id)??"")},N=(_,U="")=>{const W=Number(u.value||0),ce=m.value||[],Ee=ce[W];Ee&&(Ee.__decision=_,Ee.selectedTargetId=U,x.value=U,m.value=[...ce])},Y=()=>N("skip",""),b=()=>N("add",""),$=()=>{if(!x.value){rl.ElMessage.warning("请先选择要替换的目标记录");return}N("replace",x.value)},T=()=>{s("update:visible",!1)},k=()=>{const _=m.value||[];if(_.find(W=>(W==null?void 0:W.__decision)==="replace"&&!(W!=null&&W.selectedTargetId))){rl.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}s("submit",_),s("update:visible",!1)};return(_,U)=>{const W=a.resolveComponent("el-table-column"),ce=a.resolveComponent("svg-icon"),Ee=a.resolveComponent("el-table"),Ie=a.resolveComponent("el-button"),De=a.resolveComponent("el-alert");return a.openBlock(),a.createBlock(vr.ssDialog,{title:"OCR候选匹配",visible:l.visible,"close-on-click-modal":!1,width:"90%",style:{maxWidth:"1200px"},onBeforeDestroy:T},{default:a.withCtx(()=>{var ne,ge;return[a.createElementVNode("div",sd,[a.createElementVNode("div",cd,[U[0]||(U[0]=a.createElementVNode("div",{class:"ocr-candidate-title"},"待处理OCR行(可跳过)",-1)),a.createVNode(Ee,{data:m.value,border:"",stripe:"","max-height":"300",style:{width:"100%"},"highlight-current-row":"",onCurrentChange:V},{default:a.withCtx(()=>[a.createVNode(W,{type:"index",label:"序号",width:"60"}),(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(w.value,X=>(a.openBlock(),a.createBlock(W,{key:X.prop,label:X.label,prop:X.prop,"min-width":X.minWidth||160},{default:a.withCtx(({row:de})=>[X.label==="证书附件"||X.prop==="证书附件"?(a.openBlock(),a.createElementBlock(a.Fragment,{key:0},[f(de==null?void 0:de[X.prop]).length>0?(a.openBlock(),a.createBlock(ce,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:a.withModifiers(Ke=>v({row:de,prop:X.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(a.openBlock(),a.createElementBlock("span",ud,"-"))],64)):(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[a.createTextVNode(a.toDisplayString((de==null?void 0:de[X.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128)),a.createVNode(W,{label:"候选数",width:"90",fixed:"right"},{default:a.withCtx(({row:X})=>[a.createTextVNode(a.toDisplayString(((X==null?void 0:X.candidates)||[]).length),1)]),_:1}),a.createVNode(W,{label:"处理状态",width:"120",fixed:"right"},{default:a.withCtx(({row:X})=>[(X==null?void 0:X.__decision)==="replace"?(a.openBlock(),a.createElementBlock("span",dd,"替换")):(X==null?void 0:X.__decision)==="add"?(a.openBlock(),a.createElementBlock("span",pd,"新增")):(X==null?void 0:X.__decision)==="skip"?(a.openBlock(),a.createElementBlock("span",fd,"跳过")):(a.openBlock(),a.createElementBlock("span",hd,"未处理"))]),_:1})]),_:1},8,["data"])]),m.value&&m.value.length>0?(a.openBlock(),a.createElementBlock("div",vd,[U[4]||(U[4]=a.createElementVNode("div",{class:"ocr-candidate-title"},"当前行候选记录(同编号)",-1)),a.createElementVNode("div",md,[a.createVNode(Ie,{id:"themeBorderButton",onClick:Y},{default:a.withCtx(()=>U[1]||(U[1]=[a.createTextVNode("跳过本行")])),_:1,__:[1]}),a.createVNode(Ie,{id:"themeBorderButton",onClick:b,disabled:!c.value},{default:a.withCtx(()=>U[2]||(U[2]=[a.createTextVNode("新增本行")])),_:1,__:[2]},8,["disabled"]),a.createVNode(Ie,{class:"ok-button",id:"themeButton",onClick:$,disabled:!y.value||!x.value},{default:a.withCtx(()=>U[3]||(U[3]=[a.createTextVNode("替换选中记录")])),_:1,__:[3]},8,["disabled"])]),(((ne=E.value)==null?void 0:ne.candidates)||[]).length===0?(a.openBlock(),a.createBlock(De,{key:0,title:"该编号暂无候选记录,可选择“新增本行”或“跳过本行”。",type:"info",closable:!1,"show-icon":"",style:{margin:"8px 0"}})):a.createCommentVNode("",!0),a.createVNode(Ee,{data:((ge=E.value)==null?void 0:ge.candidates)||[],border:"",stripe:"","max-height":"300",style:{width:"100%"},onCurrentChange:A,"highlight-current-row":""},{default:a.withCtx(()=>[a.createVNode(W,{type:"index",label:"序号",width:"60"}),(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(B.value,X=>(a.openBlock(),a.createBlock(W,{key:X.prop,label:X.label,prop:X.prop,"min-width":X.minWidth||160},{default:a.withCtx(({row:de})=>[X.label==="证书附件"||X.prop==="证书附件"?(a.openBlock(),a.createElementBlock(a.Fragment,{key:0},[f(de==null?void 0:de[X.prop]).length>0?(a.openBlock(),a.createBlock(ce,{key:0,name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:a.withModifiers(Ke=>v({row:de,prop:X.prop}),["stop"]),title:"浏览"},null,8,["onClick"])):(a.openBlock(),a.createElementBlock("span",yd,"-"))],64)):(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[a.createTextVNode(a.toDisplayString((de==null?void 0:de[X.prop])??"-"),1)],64))]),_:2},1032,["label","prop","min-width"]))),128))]),_:1},8,["data"])])):a.createCommentVNode("",!0)])]}),footer:a.withCtx(()=>[a.createElementVNode("div",gd,[a.createVNode(Ie,{id:"themeBorderButton",onClick:T},{default:a.withCtx(()=>U[5]||(U[5]=[a.createTextVNode("取消")])),_:1,__:[5]}),a.createVNode(Ie,{class:"ok-button",id:"themeButton",onClick:k},{default:a.withCtx(()=>U[6]||(U[6]=[a.createTextVNode("提交已处理")])),_:1,__:[6]})])]),_:1},8,["visible"])}}},kd=ql._export_sfc(bd,[["__scopeId","data-v-89e0489c"]]),xd={class:"ocr-preview-content"},_d={class:"ocr-preview-tip"},wd={class:"ocr-preview-table"},Cd={style:{display:"flex","align-items":"center",gap:"8px"}},Ed={class:"dialog-footer"},Sd={__name:"OCRResultPreviewDialog",props:{visible:{type:Boolean,default:!1},ocrPreviewData:{type:Array,default:()=>[]},ocrPreviewColumns:{type:Array,default:()=>[]},ocrSelectedFields:{type:Array,default:()=>[]}},emits:["update:visible","update:ocrPreviewData","update:ocrSelectedFields","confirm","fieldChange"],setup(l,{emit:r}){const n=l,o=r,s=a.ref([]),c=a.ref([]),y=a.ref([]);a.watch(()=>n.visible,B=>{B&&(s.value=JSON.parse(JSON.stringify(n.ocrPreviewData)),c.value=JSON.parse(JSON.stringify(n.ocrPreviewColumns)),y.value=[...n.ocrSelectedFields])});const f=(B,w)=>{const V=[...y.value];if(w)V.includes(B)||V.push(B);else{const A=V.indexOf(B);A>-1&&V.splice(A,1)}y.value=V,o("update:ocrSelectedFields",V)},v=(B,w,V)=>{o("fieldChange",{rowIndex:B,prop:w,value:V})},m=()=>{o("update:ocrPreviewData",s.value),o("confirm",s.value),o("update:visible",!1)},u=()=>{o("update:visible",!1)},x=B=>typeof B!="number"?"-":`${(B*100).toFixed(1)}%`,E=B=>typeof B!="number"?"#606266":B>=.9?"#67c23a":B>=.7?"#e6a23c":"#f56c6c";return(B,w)=>{const V=a.resolveComponent("el-alert"),A=a.resolveComponent("el-table-column"),N=a.resolveComponent("el-checkbox"),Y=a.resolveComponent("el-input"),b=a.resolveComponent("el-table"),$=a.resolveComponent("el-button");return a.openBlock(),a.createBlock(vr.ssDialog,{title:"OCR识别结果预览",visible:l.visible,onBeforeDestroy:u,width:"90%",style:{maxWidth:"1200px"}},{default:a.withCtx(()=>[a.createElementVNode("div",xd,[a.createElementVNode("div",_d,[a.createVNode(V,{title:"请核对识别结果。系统将按 编号+名称+制造厂 规则匹配并替换;未唯一命中但有编号的,将进入候选选择;无编号则直接新增。",type:"info",closable:!1,"show-icon":""})]),a.createElementVNode("div",wd,[a.createVNode(b,{data:s.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:a.withCtx(()=>[a.createVNode(A,{type:"index",label:"序号",width:"60",fixed:""}),(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(c.value,T=>(a.openBlock(),a.createBlock(A,{key:T.prop,prop:T.prop,"min-width":T.minWidth||230,"class-name":T.isAccuracy?"accuracy-column":""},{header:a.withCtx(()=>[a.createElementVNode("div",Cd,[T.isAccuracy?a.createCommentVNode("",!0):(a.openBlock(),a.createBlock(N,{key:0,"model-value":y.value.includes(T.prop),onChange:k=>f(T.prop,k),onClick:w[0]||(w[0]=a.withModifiers(()=>{},["stop"]))},null,8,["model-value","onChange"])),a.createElementVNode("span",null,a.toDisplayString(T.label),1)])]),default:a.withCtx(({row:k,$index:_})=>[T.isAccuracy?(a.openBlock(),a.createElementBlock("span",{key:0,class:"accuracy-value",style:a.normalizeStyle({color:E(k[T.prop]),fontWeight:500})},a.toDisplayString(x(k[T.prop])),5)):(a.openBlock(),a.createBlock(Y,{key:1,modelValue:k[T.prop],"onUpdate:modelValue":U=>k[T.prop]=U,size:"small",placeholder:"请输入"+T.label,onChange:U=>v(_,T.prop,U)},null,8,["modelValue","onUpdate:modelValue","placeholder","onChange"]))]),_:2},1032,["prop","min-width","class-name"]))),128))]),_:1},8,["data"])])])]),footer:a.withCtx(()=>[a.createElementVNode("div",Ed,[a.createVNode($,{onClick:u,id:"themeBorderButton"},{default:a.withCtx(()=>w[1]||(w[1]=[a.createTextVNode("取消")])),_:1,__:[1]}),a.createVNode($,{class:"ok-button",onClick:m,id:"themeButton"},{default:a.withCtx(()=>w[2]||(w[2]=[a.createTextVNode("确认")])),_:1,__:[2]})])]),_:1},8,["visible"])}}},Dd=ql._export_sfc(Sd,[["__scopeId","data-v-df66eb1f"]]),_o=l=>{var o;let r=l;(r==null?void 0:r[0])==="("&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1));let n=(o=Pa.analyzeSplitToContent(r,","))==null?void 0:o.map(s=>((s==null?void 0:s[(s==null?void 0:s.length)-1])===","&&(s=s==null?void 0:s.slice(0,(s==null?void 0:s.length)-1)),st(s)));return n=n==null?void 0:n.join(","),n};let Ra="$R",lo="[Any]";const Nd=l=>{var y,f,v,m;let r={},n=l==null?void 0:l[0],o=(f=(y=n==null?void 0:n.replace("{",Ra))==null?void 0:y.split(Ra))==null?void 0:f[0];(o==null?void 0:o[0])==="*"&&(o=o==null?void 0:o.slice(1,o==null?void 0:o.length)),o=o==null?void 0:o.split(":"),r.group=o;let s=l==null?void 0:l[1],c;return s!=null&&s.includes("{")?c=(m=(v=s==null?void 0:s.replaceAll("{",""))==null?void 0:v.replaceAll("}",":"))==null?void 0:m.replaceAll(lo,""):c=s==null?void 0:s.replaceAll(lo,""),(c==null?void 0:c[0])==="$"&&(c=c==null?void 0:c.slice(1,c==null?void 0:c.length)),r.filter=c,r},Bd=l=>{var u,x,E,B,w,V,A;let r=[],n=[],o=l==null?void 0:l.map(N=>{var b;let Y=(b=Pa.analyzeSplitToContent(N,"@"))==null?void 0:b[0];return(Y==null?void 0:Y[(Y==null?void 0:Y.length)-1])==="@"&&(Y=Y==null?void 0:Y.slice(0,(Y==null?void 0:Y.length)-1)),Y}),s="",c=Pa.analyzeSplitToContent(o==null?void 0:o[0],":");n=(u=c==null?void 0:c.filter(N=>!(N!=null&&N.includes("{"))&&!(N!=null&&N.includes("["))))==null?void 0:u.join(""),(n==null?void 0:n[(n==null?void 0:n.length)-1])===":"&&(n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1)),(n==null?void 0:n[0])==="*"&&(n=n==null?void 0:n.slice(1,n==null?void 0:n.length)),n=n==null?void 0:n.split(":");let y=c==null?void 0:c.filter(N=>(N==null?void 0:N.includes("{"))||(N==null?void 0:N.includes("["))),f=(E=y==null?void 0:y[0])==null?void 0:E.slice(1,((x=y==null?void 0:y[0])==null?void 0:x.length)-1);f=(B=Pa.analyzeSplitToContent(f,","))==null?void 0:B.map(N=>((N==null?void 0:N[(N==null?void 0:N.length)-1])===","&&(N=N==null?void 0:N.slice(0,(N==null?void 0:N.length)-1)),N));let v="@"+((w=Pa.analyzeSplitToContent(l==null?void 0:l[0],"@"))==null?void 0:w[1]);((V=Pa.analyzeSplitToContent(v,":"))==null?void 0:V.length)>1&&(r=Eo((A=Pa.analyzeSplitToContent(v,":"))==null?void 0:A[1]),r=[r]);let m=[];return f==null||f.forEach((N,Y)=>{var Ie,De,ne,ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye;let b=(Ie=N==null?void 0:N.split("=="))==null?void 0:Ie[0],$=(De=N==null?void 0:N.split("=="))==null?void 0:De[1],T=[],k=[],_=[],U=[],W="Input",ce=[],Ee=[];if((N==null?void 0:N[0])!=="{"){if(($==null?void 0:$[0])==="$")$=$==null?void 0:$.slice(1,$==null?void 0:$.length),T=(ge=(ne=$==null?void 0:$.split("*"))==null?void 0:ne[0])==null?void 0:ge.split(":"),k=(S=(oe=(Ta=(Ke=(de=(X=$==null?void 0:$.split("*"))==null?void 0:X[1])==null?void 0:de.replace("{",Ra))==null?void 0:Ke.split(Ra))==null?void 0:Ta[0])==null?void 0:oe.split(":"))==null?void 0:S.filter(Ma=>Ma!==""),_=(me=(le=$==null?void 0:$.replace("{",Ra))==null?void 0:le.split(Ra))==null?void 0:me[1],_=_==null?void 0:_.replaceAll("}",""),_=_==null?void 0:_.split(":"),W="Select";else if(((ue=Pa.analyzeSplitToContent(N,"="))==null?void 0:ue.length)>1){let Ma=(Ne=b==null?void 0:b.split("="))==null?void 0:Ne[1];if(b=(pa=b==null?void 0:b.split("="))==null?void 0:pa[0],W="Select",!(N!=null&&N.includes("||")))Ma=(_a=Ma==null?void 0:Ma.split("/"))==null?void 0:_a.map(Ue=>((Ue==null?void 0:Ue[(Ue==null?void 0:Ue.length)-1])==="/"&&(Ue=Ue==null?void 0:Ue.slice(0,(Ue==null?void 0:Ue.length)-1)),Ue)),U=Ma==null?void 0:Ma.map(Ue=>({label:Ue==null?void 0:Ue.replaceAll("'",""),value:Ue==null?void 0:Ue.replaceAll("'","")}));else{let Ue=[];(Ve=(la=(ee=(Wa=N==null?void 0:N.replace("=",Ra))==null?void 0:Wa.split(Ra))==null?void 0:ee[1])==null?void 0:la.split("||"))==null||Ve.forEach(Ya=>{var ga,ba,$a;ce.push((ba=(ga=Ya==null?void 0:Ya.split("@Filter"))==null?void 0:ga[0])==null?void 0:ba.split("/")),Ue.push(($a=Ya==null?void 0:Ya.split("@Filter"))==null?void 0:$a[1])}),Ee=Ue==null?void 0:Ue.map(Ya=>(Ya=Ya==null?void 0:Ya.slice(1,(Ya==null?void 0:Ya.length)-1),Ya))}}else if(N!=null&&N.includes("@")&&!(N!=null&&N.includes("||"))){b=(Ge=(Re=(Te=(He=(ka=b==null?void 0:b.replace("(@",Ra))==null?void 0:ka.split(Ra))==null?void 0:He[0])==null?void 0:Te.replace("@",Ra))==null?void 0:Re.split(Ra))==null?void 0:Ge[0];let Ma=N!=null&&N.includes("(@")?"(@"+((Fa=(Ga=N==null?void 0:N.replace("(@",Ra))==null?void 0:Ga.split(Ra))==null?void 0:Fa[1]):"@"+((F=(P=N==null?void 0:N.replace("@",Ra))==null?void 0:P.split(Ra))==null?void 0:F[1]);if(Ma=(J=_o(Ma))==null?void 0:J.split(","),Ma!=null&&Ma.find(Ue=>Ue==null?void 0:Ue.includes("@Type"))){let Ue=(ie=Ma==null?void 0:Ma.find(Ya=>Ya==null?void 0:Ya.includes("@Type")))==null?void 0:ie.split("=");Ue!=null&&Ue.includes("File")&&(W="Upload"),Ue!=null&&Ue.includes("Date")&&(W="Date"),Ue!=null&&Ue.includes("DateTime")&&(W="DateTime"),Ue!=null&&Ue.includes("Time")&&(W="Time")}}m.push({prop:b,label:b,value:"",menuPath:T,groups:k,columns:_,width:f==null?void 0:f.length,options:U,type:W,allContents:ce,filterContents:Ee})}else{s=s+"@"+((se=Pa.analyzeSplitToContent(N,"@"))==null?void 0:se[1]);let Ma=(ma=Pa.analyzeSplitToContent(N,"@"))==null?void 0:ma[0];(Ma==null?void 0:Ma[(Ma==null?void 0:Ma.length)-1])==="@"&&(Ma=Ma==null?void 0:Ma.slice(0,(Ma==null?void 0:Ma.length)-1));let Ue=(oa=Ma==null?void 0:Ma.split("=="))==null?void 0:oa[0],Ya=(Oe=Ma==null?void 0:Ma.split("=="))==null?void 0:Oe[1],ga=(wa=(_e=Ya==null?void 0:Ya.split("*"))==null?void 0:_e[0])==null?void 0:wa.replace(lo,"");(ga==null?void 0:ga[0])==="$"&&(ga=ga==null?void 0:ga.slice(1,ga==null?void 0:ga.length)),ga=Pa.analyzeSplitToContent(ga,"$"),ga=(ve=ga==null?void 0:ga.map((ba,$a)=>{var Sa;return $a===0&&(ga==null?void 0:ga.length)>1&&(ba=(Sa=ba==null?void 0:ba.split(":"))==null?void 0:Sa[0]),(ga==null?void 0:ga.length)>1&&$a===(ga==null?void 0:ga.length)-1&&(ba=ba+":"),ba}))==null?void 0:ve.join(":"),T=(aa=(Xe=ga==null?void 0:ga.replaceAll("{",""))==null?void 0:Xe.replaceAll("}",""))==null?void 0:aa.split(":"),k=(Ce=(re=(va=(Le=(xa=(Pe=Ya==null?void 0:Ya.split("*"))==null?void 0:Pe[1])==null?void 0:xa.replace("{",Ra))==null?void 0:Le.split(Ra))==null?void 0:va[0])==null?void 0:re.split(":"))==null?void 0:Ce.filter(ba=>ba!==""),_=(fa=(Z=Ya==null?void 0:Ya.replace("{",Ra))==null?void 0:Z.split(Ra))==null?void 0:fa[1],_=_==null?void 0:_.replaceAll("}",""),Ue=Ue==null?void 0:Ue.slice(1,(Ue==null?void 0:Ue.length)-1),_=_==null?void 0:_.split(","),W="Select",(Ye=Ue==null?void 0:Ue.split(","))==null||Ye.forEach((ba,$a)=>{var Sa,Na;m.push({prop:ba,label:ba,value:"",menuPath:T,groups:k,columns:(Sa=_==null?void 0:_[$a])==null?void 0:Sa.split(":"),width:(Na=Ue==null?void 0:Ue.split(","))==null?void 0:Na.length,type:W})})}}),{groupName:n,formContents:m,contents:r,filter:s}},Eo=l=>{var o,s;let r=[],n=l.slice(1,(l==null?void 0:l.length)-1);if((n==null?void 0:n[0])!=="[")(o=Pa.analyzeSplitToContent(n,","))==null||o.forEach(c=>{(c==null?void 0:c[(c==null?void 0:c.length)-1])===","&&(c=c.slice(0,(c==null?void 0:c.length)-1)),r.push(c??"")});else{let c=[];(s=Pa.analyzeSplitToContent(n,","))==null||s.forEach(y=>{(y==null?void 0:y[(y==null?void 0:y.length)-1])===","&&(y=y==null?void 0:y.slice(0,(y==null?void 0:y.length)-1)),c.push(Eo(y))}),r=c}return r},tt=(l,r)=>{var A,N,Y,b,$,T,k,_,U,W,ce,Ee,Ie,De,ne,ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye,Ma,Ue,Ya,ga,ba,$a;let n,o=[],s=[],c=[],y=[],f=[],v=[],m=[],u="Input",x,E="",B="",w=[],V="";if(l!=null&&l.includes("@Pam")||l!=null&&l.includes("==")||l!=null&&l.includes("="))if(l!=null&&l.includes("@Pam")){let Sa=Pa.analyzeSplitToContent(l,"=");if((Sa==null?void 0:Sa.length)>1){l=Sa==null?void 0:Sa[0],l=l==null?void 0:l.slice(0,(l==null?void 0:l.length)-1);let Be=Sa==null?void 0:Sa[(Sa==null?void 0:Sa.length)-1];(Be==null?void 0:Be[0])==="&"&&(Be=Be==null?void 0:Be.slice(1,Be==null?void 0:Be.length)),B=(N=(A=Be==null?void 0:Be.replace("(",Ra))==null?void 0:A.split(Ra))==null?void 0:N[0];let tl=(b=(Y=Be==null?void 0:Be.replace(")",Ra))==null?void 0:Y.split(Ra))==null?void 0:b[0];tl=(T=($=tl==null?void 0:tl.replace("(",Ra))==null?void 0:$.split(Ra))==null?void 0:T[1],(tl==null?void 0:tl[0])==="{"&&(tl=tl==null?void 0:tl.slice(1,tl==null?void 0:tl.length)),(tl==null?void 0:tl[(tl==null?void 0:tl.length)-1])==="}"&&(tl=tl==null?void 0:tl.slice(0,(tl==null?void 0:tl.length)-1)),w=tl==null?void 0:tl.split(",");let Ea=(_=(k=Be==null?void 0:Be.replace(")",Ra))==null?void 0:k.split(Ra))==null?void 0:_[1];Ea&&Ea!==""&&(V=_o(Ea))}n=(W=(U=l==null?void 0:l.replace("@Pam",Ra))==null?void 0:U.split(Ra))==null?void 0:W[0];let Na=(Ee=(ce=l==null?void 0:l.replace("@Pam",Ra))==null?void 0:ce.split(Ra))==null?void 0:Ee[1];Na=Na==null?void 0:Na.slice(1,(Na==null?void 0:Na.length)-1),Na=(Ie=Pa.analyzeSplitToContent(Na,","))==null?void 0:Ie.map(Be=>(Be="@"+Be,Be));let Oa=Na==null?void 0:Na.find(Be=>Be==null?void 0:Be.includes("@Type"));Oa!=null&&Oa.includes("File")&&(u="Upload"),Oa!=null&&Oa.includes("Date")&&(u="Date"),Oa!=null&&Oa.includes("DateTime")&&(u="DateTime"),Oa!=null&&Oa.includes("Time")&&(u="Time"),x=Na==null?void 0:Na.find(Be=>Be==null?void 0:Be.includes("@IdentName")),x=x?(ne=(De=x==null?void 0:x.replace("=",Ra))==null?void 0:De.split(Ra))==null?void 0:ne[1]:n}else{if(n=(ge=l==null?void 0:l.split("=="))==null?void 0:ge[0],x=(X=l==null?void 0:l.split("=="))==null?void 0:X[0],l!=null&&l.includes("=")&&!(l!=null&&l.includes("=="))&&!((Ta=(Ke=(de=l==null?void 0:l.replace("=",Ra))==null?void 0:de.split(Ra))==null?void 0:Ke[1])!=null&&Ta.includes("||")))if(n=(oe=l==null?void 0:l.split("="))==null?void 0:oe[0],x=n,l!=null&&l.includes("(@")||l!=null&&l.includes("@")){if(l!=null&&l.includes("(@")){let Na=(S=l==null?void 0:l.split("(@"))==null?void 0:S[1];Na=Na==null?void 0:Na.slice(0,(Na==null?void 0:Na.length)-1),Na=(me=(le=Na==null?void 0:Na.replace("(",Ra))==null?void 0:le.split(Ra))==null?void 0:me[1],Na=Na==null?void 0:Na.slice(0,(Na==null?void 0:Na.length)-1),c==null||c.push(Na),l=(ue=l==null?void 0:l.split("(@"))==null?void 0:ue[0]}else{let Na=(Ne=l==null?void 0:l.split("@"))==null?void 0:Ne[1];Na=Na==null?void 0:Na.slice(0,(Na==null?void 0:Na.length)-1),Na=(_a=(pa=Na==null?void 0:Na.replace("(",Ra))==null?void 0:pa.split(Ra))==null?void 0:_a[1],Na=Na==null?void 0:Na.slice(0,(Na==null?void 0:Na.length)-1),c==null||c.push(Na),l=(Wa=l==null?void 0:l.split("@"))==null?void 0:Wa[0]}let Sa=(la=(ee=l==null?void 0:l.split("="))==null?void 0:ee[1])==null?void 0:la.split("/");s.push(Sa)}else o=(ka=Pa.analyzeSplitToContent((Ve=l==null?void 0:l.split("="))==null?void 0:Ve[1],"/"))==null?void 0:ka.map(Sa=>((Sa==null?void 0:Sa[(Sa==null?void 0:Sa.length)-1])==="/"&&(Sa=Sa==null?void 0:Sa.slice(0,(Sa==null?void 0:Sa.length)-1)),Sa)),o=o==null?void 0:o.map(Sa=>({label:Sa==null?void 0:Sa.replaceAll("'",""),value:Sa==null?void 0:Sa.replaceAll("'","")}));else if((Re=(Te=(He=l==null?void 0:l.replace("=",Ra))==null?void 0:He.split(Ra))==null?void 0:Te[1])!=null&&Re.includes("||")){n=(Ge=l==null?void 0:l.split("="))==null?void 0:Ge[0],x=(Ga=l==null?void 0:l.split("="))==null?void 0:Ga[0];let Sa=[];(J=(F=(P=(Fa=l==null?void 0:l.replace("=",Ra))==null?void 0:Fa.split(Ra))==null?void 0:P[1])==null?void 0:F.split("||"))==null||J.forEach(Na=>{var Oa,Be,tl;s.push((Be=(Oa=Na==null?void 0:Na.split("@Filter"))==null?void 0:Oa[0])==null?void 0:Be.split("/")),Sa.push((tl=Na==null?void 0:Na.split("@Filter"))==null?void 0:tl[1])}),c=Sa==null?void 0:Sa.map(Na=>(Na=Na==null?void 0:Na.slice(1,(Na==null?void 0:Na.length)-1),Na))}else{let Sa=l==null?void 0:l.split("=="),Na=(ie=Sa==null?void 0:Sa.filter(Oa=>(Oa==null?void 0:Oa[0])==="$"))==null?void 0:ie[0];if(Na&&!(Na!=null&&Na.includes("&"))){let Oa=(se=Na==null?void 0:Na.replace("*",Ra))==null?void 0:se.split(Ra),Be=(Oa==null?void 0:Oa[0])===""?r==null?void 0:r.value:Oa==null?void 0:Oa[0];Be=(oa=(ma=Be==null?void 0:Be.replaceAll("{",""))==null?void 0:ma.replaceAll("}",":"))==null?void 0:oa.replaceAll(lo,""),(Be==null?void 0:Be[0])==="$"&&(Be=(Oe=Be==null?void 0:Be.slice(1,Be==null?void 0:Be.length))==null?void 0:Oe.replaceAll(":","/")),y=Be==null?void 0:Be.split("/");let tl=(wa=(_e=Oa==null?void 0:Oa[1])==null?void 0:_e.replace("{",Ra))==null?void 0:wa.split(Ra),Ea=tl==null?void 0:tl[0];(Ea==null?void 0:Ea[(Ea==null?void 0:Ea.length)-1])===":"&&(Ea=Ea==null?void 0:Ea.slice(0,(Ea==null?void 0:Ea.length)-1)),f=Ea==null?void 0:Ea.split(":"),v=(Pe=(aa=(Xe=(ve=tl==null?void 0:tl[1])==null?void 0:ve.replace("}",Ra))==null?void 0:Xe.split(Ra))==null?void 0:aa[0])==null?void 0:Pe.split(":");let El=(va=(Le=(xa=tl==null?void 0:tl[(tl==null?void 0:tl.length)-1])==null?void 0:xa.replace("}",Ra))==null?void 0:Le.split(Ra))==null?void 0:va[1];El&&El!==""&&(E=_o(El))}if(Sa!=null&&Sa.some(Oa=>(Oa==null?void 0:Oa[0])==="&")){let Oa=(re=Sa==null?void 0:Sa.filter(Ea=>(Ea==null?void 0:Ea[0])==="&"))==null?void 0:re[0];(Oa==null?void 0:Oa[0])==="&"&&(Oa=Oa==null?void 0:Oa.slice(1,Oa==null?void 0:Oa.length)),B=(Z=(Ce=Oa==null?void 0:Oa.replace("(",Ra))==null?void 0:Ce.split(Ra))==null?void 0:Z[0];let Be=(Ye=(fa=Oa==null?void 0:Oa.replace(")",Ra))==null?void 0:fa.split(Ra))==null?void 0:Ye[0];Be=(Ue=(Ma=Be==null?void 0:Be.replace("(",Ra))==null?void 0:Ma.split(Ra))==null?void 0:Ue[1],(Be==null?void 0:Be[0])==="{"&&(Be=Be==null?void 0:Be.slice(1,Be==null?void 0:Be.length)),(Be==null?void 0:Be[(Be==null?void 0:Be.length)-1])==="}"&&(Be=Be==null?void 0:Be.slice(0,(Be==null?void 0:Be.length)-1)),w=Be==null?void 0:Be.split(",");let tl=(ga=(Ya=Oa==null?void 0:Oa.replace(")",Ra))==null?void 0:Ya.split(Ra))==null?void 0:ga[1];tl&&tl!==""&&(V=_o(tl))}else if(!Na){let Oa=Sa==null?void 0:Sa[(Sa==null?void 0:Sa.length)-1];Oa=Oa==null?void 0:Oa.slice(1,(Oa==null?void 0:Oa.length)-1),Oa=Pa.analyzeSplitToContent(Oa,","),Oa=Oa==null?void 0:Oa.map(Be=>((Be==null?void 0:Be[(Be==null?void 0:Be.length)-1])===","&&(Be=Be==null?void 0:Be.slice(0,(Be==null?void 0:Be.length)-1)),Be)),console.log(232,Oa),Oa=Oa==null?void 0:Oa.map(Be=>{var tl,Ea,El,ml;if(Be=Be==null?void 0:Be.replaceAll("$",""),console.log(2321,Be),Be!=null&&Be.includes("{")){let Fe="";Be=Be==null?void 0:Be.replaceAll("{","");let Va=Be==null?void 0:Be.split("}");Fe=((Ea=(tl=Va==null?void 0:Va[0])==null?void 0:tl.split(":"))==null?void 0:Ea[0])+":"+(Va==null?void 0:Va[1]),Be=Fe,Be=Be+":"}if(Be!=null&&Be.includes(lo)){let Fe="",Va=Be==null?void 0:Be.split(lo);Fe=((ml=(El=Va==null?void 0:Va[0])==null?void 0:El.split(":"))==null?void 0:ml[0])+":"+(Va==null?void 0:Va[1]),Be=Fe,Be=Be+":"}return console.log(2322,Be),Be=Be==null?void 0:Be.replaceAll(":","/"),Be}),m=Oa}}u="Select"}else n=l,x=l;return n!=null&&n.includes("@Pam")&&(n=($a=(ba=l==null?void 0:l.replace("@Pam",Ra))==null?void 0:ba.split(Ra))==null?void 0:$a[0],x=n),{label:n,prop:x,options:o,allContents:s,filterContents:c,menus:y,groups:f,words:v,align:"center",formType:u,filter:E,functionName:B,functionRelatedWords:w,calculatorFilter:V,relatedPages:m}},xi=(l,r)=>{var o,s,c,y,f,v,m,u,x,E,B,w,V,A,N,Y,b,$,T,k,_,U,W,ce,Ee,Ie,De,ne,ge;let n=[];if((l==null?void 0:l[0])==="{"&&(l==null?void 0:l[(l==null?void 0:l.length)-1])==="}"&&!((y=(c=(s=(o=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1))==null?void 0:o.replace(":",Ra))==null?void 0:s.split(Ra))==null?void 0:c[0])!=null&&y.includes(","))){let X=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1),de=(f=X==null?void 0:X.replace(":",Ra))==null?void 0:f.split(Ra);if(((v=Pa.analyzeSplitToContent(de==null?void 0:de[1],"="))==null?void 0:v.length)===1){let Ke=de==null?void 0:de[0],Ta=[];(x=Pa.analyzeSplitToContent((u=de==null?void 0:de[1])==null?void 0:u.slice(1,((m=de==null?void 0:de[1])==null?void 0:m.length)-1),","))==null||x.forEach(oe=>{var S,le;((S=Pa.analyzeSplitToContent(oe,"="))==null?void 0:S.length)>1?((oe==null?void 0:oe[(oe==null?void 0:oe.length)-1])===","&&(oe=oe==null?void 0:oe.slice(0,(oe==null?void 0:oe.length)-1)),Ta=[...Ta,...xi(oe,r)]):((oe==null?void 0:oe[(oe==null?void 0:oe.length)-1])===","&&(oe=oe==null?void 0:oe.slice(0,(oe==null?void 0:oe.length)-1)),Ta.push((le=xi(oe,r))==null?void 0:le[0]))}),n==null||n.push({label:Ke,prop:Ke,children:Ta,align:"center"})}else{let Ke=[];if(((E=Pa.analyzeSplitToContent(X,"="))==null?void 0:E.length)>=2){let oe=(B=Pa.analyzeSplitToContent(X,"="))==null?void 0:B[1],S=(w=Pa.analyzeSplitToContent(oe,"/"))==null?void 0:w.map(le=>((le==null?void 0:le[(le==null?void 0:le.length)-1])==="/"&&(le=le==null?void 0:le.slice(0,(le==null?void 0:le.length)-1)),le));Ke=S==null?void 0:S.map(le=>(le=Eo(le),le))}let Ta=($=(b=(Y=(N=(A=(V=X==null?void 0:X.replace("{",Ra))==null?void 0:V.split(Ra))==null?void 0:A[1])==null?void 0:N.replace("}",Ra))==null?void 0:Y.split(Ra))==null?void 0:b[0])==null?void 0:$.split(",");Ta==null||Ta.forEach((oe,S)=>{(Ke==null?void 0:Ke.length)>0&&S===0?n==null||n.push({label:oe,prop:oe,align:"center",formType:"Select",relatedContents:Ke==null?void 0:Ke.map(le=>{let me={};return Ta==null||Ta.forEach((ue,Ne)=>{me[ue]=le==null?void 0:le[Ne]}),me}),options:Ke==null?void 0:Ke.map(le=>({label:le==null?void 0:le[0],value:le==null?void 0:le[0]})),mainKey:!0}):n==null||n.push({label:oe,prop:oe,align:"center"})})}}else if((l==null?void 0:l[0])==="{")if(((T=Pa.analyzeSplitToContent(l,"="))==null?void 0:T.length)===2&&((_=(k=Pa.analyzeSplitToContent(l,"="))==null?void 0:k[1])==null?void 0:_[0])==="["){let X=[];if(((U=Pa.analyzeSplitToContent(l,"="))==null?void 0:U.length)>=2){let Ke=(W=Pa.analyzeSplitToContent(l,"="))==null?void 0:W[1],Ta=(ce=Pa.analyzeSplitToContent(Ke,"/"))==null?void 0:ce.map(oe=>((oe==null?void 0:oe[(oe==null?void 0:oe.length)-1])==="/"&&(oe=oe==null?void 0:oe.slice(0,(oe==null?void 0:oe.length)-1)),oe));X=Ta==null?void 0:Ta.map(oe=>(oe=Eo(oe),oe))}let de=(Ie=(Ee=l==null?void 0:l.replace("}",Ra))==null?void 0:Ee.split(Ra))==null?void 0:Ie[0];de=(De=de==null?void 0:de.slice(1,de==null?void 0:de.length))==null?void 0:De.split(","),de==null||de.forEach((Ke,Ta)=>{(X==null?void 0:X.length)>0&&Ta===0?n==null||n.push({label:Ke,prop:Ke,align:"center",formType:"Select",relatedContents:X==null?void 0:X.map(oe=>{let S={};return de==null||de.forEach((le,me)=>{S[le]=oe==null?void 0:oe[me]}),S}),options:X==null?void 0:X.map(oe=>({label:oe==null?void 0:oe[0],value:oe==null?void 0:oe[0]})),mainKey:!0}):n==null||n.push({label:Ke,prop:Ke,align:"center"})})}else(ne=Pa.analyzeSplitToContent(l,","))==null||ne.forEach(X=>{var de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye,Ma;if((X==null?void 0:X[(X==null?void 0:X.length)-1])===","&&(X=X==null?void 0:X.slice(0,(X==null?void 0:X.length)-1)),(X==null?void 0:X[0])==="{"){let Ue=Pa.analyzeSplitToContent(X,"="),Ya=Ue==null?void 0:Ue[(Ue==null?void 0:Ue.length)-1],ga=[],ba=[],$a=[],Sa=[],Na=[],Oa=(de=Ya==null?void 0:Ya.replace("*",Ra))==null?void 0:de.split(Ra),Be=(Oa==null?void 0:Oa[0])===""?r==null?void 0:r.value:Oa==null?void 0:Oa[0];if((Be==null?void 0:Be[0])==="$"&&((oe=(Ta=(Ke=Be==null?void 0:Be.replace("@",Ra))==null?void 0:Ke.split(Ra))==null?void 0:Ta[0])!=null&&oe.includes("{"))&&(Be=(S=Be==null?void 0:Be.replace("{",""))==null?void 0:S.replace("}",":")),Be=Be==null?void 0:Be.replaceAll(lo,""),(Be==null?void 0:Be[(Be==null?void 0:Be.length)-1])===":"&&(Be=Be!=null&&Be.includes("(@")?((le=Be==null?void 0:Be.split("(@"))==null?void 0:le[0])+":":((me=Be==null?void 0:Be.split("@"))==null?void 0:me[0])+":"),(Be==null?void 0:Be[0])==="$"&&(Be=(ue=Be==null?void 0:Be.slice(1,Be==null?void 0:Be.length))==null?void 0:ue.replaceAll(":","/")),Be!=null&&Be.includes("$")){let Va=(Ne=Be==null?void 0:Be.split("$"))==null?void 0:Ne[0];Va=(pa=Va==null?void 0:Va.split("/"))==null?void 0:pa[0],Be=Va+"/"+((_a=Be==null?void 0:Be.split("$"))==null?void 0:_a[1])+"/"}(Be==null?void 0:Be[(Be==null?void 0:Be.length)-1])==="/"&&(Be==null?void 0:Be[(Be==null?void 0:Be.length)-2])==="/"&&(Be=Be==null?void 0:Be.slice(0,(Be==null?void 0:Be.length)-1)),ga=Be==null?void 0:Be.split("/");let tl=(ee=(Wa=Oa==null?void 0:Oa[1])==null?void 0:Wa.replace("{",Ra))==null?void 0:ee.split(Ra);if((ka=(Ve=(la=Oa==null?void 0:Oa[1])==null?void 0:la.split("(@"))==null?void 0:Ve[0])!=null&&ka.includes("&&")||(Re=(Te=(He=Oa==null?void 0:Oa[1])==null?void 0:He.split("@"))==null?void 0:Te[0])!=null&&Re.includes("&&")){let Va=(Ge=Oa==null?void 0:Oa[1])!=null&&Ge.includes("(@")?(P=(Fa=(Ga=Oa==null?void 0:Oa[1])==null?void 0:Ga.split("(@"))==null?void 0:Fa[0])==null?void 0:P.split("&&"):(ie=(J=(F=Oa==null?void 0:Oa[1])==null?void 0:F.split("@"))==null?void 0:J[0])==null?void 0:ie.split("&&");Sa=Va==null?void 0:Va.map(xe=>{var Ze,Je;return(xe==null?void 0:xe[0])==="*"&&(xe=xe==null?void 0:xe.slice(1,xe==null?void 0:xe.length)),xe=(Je=(Ze=xe==null?void 0:xe.replace("{",Ra))==null?void 0:Ze.split(Ra))==null?void 0:Je[0],(xe==null?void 0:xe[(xe==null?void 0:xe.length)-1])===":"&&(xe=xe==null?void 0:xe.slice(0,(xe==null?void 0:xe.length)-1)),xe=xe==null?void 0:xe.split(":"),xe});let je=[];Va==null||Va.forEach((xe,Ze)=>{var Je,ea;(xe==null?void 0:xe[0])==="*"&&(xe=xe==null?void 0:xe.slice(1,xe==null?void 0:xe.length)),xe=(ea=(Je=xe==null?void 0:xe.replace("{",Ra))==null?void 0:Je.split(Ra))==null?void 0:ea[1],(xe==null?void 0:xe[(xe==null?void 0:xe.length)-1])==="}"&&(xe=xe==null?void 0:xe.slice(0,(xe==null?void 0:xe.length)-1)),xe=xe==null?void 0:xe.split(","),je.push(Ze===0?(xe==null?void 0:xe.length)-1:xe==null?void 0:xe.length),Na=[...Na,...xe]}),je=(se=Pa.prefixSum(je))==null?void 0:se.map(xe=>xe==null?void 0:xe.total),Sa=Sa==null?void 0:Sa.map((xe,Ze)=>({number:je==null?void 0:je[Ze],contents:xe}))}let Ea=tl==null?void 0:tl[0];(Ea==null?void 0:Ea[(Ea==null?void 0:Ea.length)-1])===":"&&(Ea=Ea==null?void 0:Ea.slice(0,(Ea==null?void 0:Ea.length)-1)),ba=Ea==null?void 0:Ea.split(":"),$a=(_e=(Oe=(oa=(ma=tl==null?void 0:tl[1])==null?void 0:ma.replace("}",Ra))==null?void 0:oa.split(Ra))==null?void 0:Oe[0])==null?void 0:_e.split(",");let El=(ve=Ue==null?void 0:Ue[0])==null?void 0:ve.slice(1,((wa=Ue==null?void 0:Ue[0])==null?void 0:wa.length)-2),ml="",Fe="";if((Xe=Ue==null?void 0:Ue[(Ue==null?void 0:Ue.length)-1])!=null&&Xe.includes("(@")?(Fe=(xa=(Pe=(aa=Ue==null?void 0:Ue[(Ue==null?void 0:Ue.length)-1])==null?void 0:aa.replace("(@",Ra))==null?void 0:Pe.split(Ra))==null?void 0:xa[1],Fe="(@"+Fe):(Le=Ue==null?void 0:Ue[(Ue==null?void 0:Ue.length)-1])!=null&&Le.includes("@")&&(Fe=(Ce=(re=(va=Ue==null?void 0:Ue[(Ue==null?void 0:Ue.length)-1])==null?void 0:va.replace("@",Ra))==null?void 0:re.split(Ra))==null?void 0:Ce[1],Fe="@"+Fe),((Z=Pa.analyzeSplitToContent(Fe,"&"))==null?void 0:Z.length)>1){let Va=(Ye=(fa=Pa.analyzeSplitToContent(Fe,"}"))==null?void 0:fa.map(je=>{var xe;return je!=null&&je.includes("@")||(je=""),je!=null&&je.includes("@")&&(je=(xe=Pa.analyzeSplitToContent(je,":"))==null?void 0:xe[0],(je==null?void 0:je[(je==null?void 0:je.length)-1])===":"&&(je=je==null?void 0:je.slice(0,(je==null?void 0:je.length)-1)),(je==null?void 0:je[0])==="("&&(je=je==null?void 0:je.slice(1,(je==null?void 0:je.length)-1))),je}))==null?void 0:Ye.filter(je=>je!=="");Fe=(Fe==null?void 0:Fe.length)===1?Va:"("+(Va==null?void 0:Va.join(","))+")"}Fe&&Fe!==""&&(ml=_o(Fe)),(Ma=El==null?void 0:El.split(","))==null||Ma.forEach((Va,je)=>{var xe,Ze,Je;n.push({label:Va,prop:Va,align:"center",menus:ga,groups:(Sa==null?void 0:Sa.length)===0?ba:(xe=Sa==null?void 0:Sa.find(ea=>(ea==null?void 0:ea.number)>=je))==null?void 0:xe.contents,words:(Na==null?void 0:Na.length)===0?(Ze=$a==null?void 0:$a[je])==null?void 0:Ze.split(":"):(Je=Na==null?void 0:Na[je])==null?void 0:Je.split(":"),formType:(ga==null?void 0:ga.length)>0?"Select":"Input",mainKey:je===0,filter:ml,isMainPath:(Sa==null?void 0:Sa.findIndex(ea=>(ea==null?void 0:ea.number)>=je))===0})})}else n.push({label:X,prop:X,align:"center"})});else{let X=(ge=Pa.analyzeSplitToContent(l,","))==null?void 0:ge.map(de=>((de==null?void 0:de[(de==null?void 0:de.length)-1])===","&&(de=de==null?void 0:de.slice(0,(de==null?void 0:de.length)-1)),de));X==null||X.forEach(de=>{n.push(tt(de,r))})}return n},Td=(l,r)=>{var y,f,v,m,u;let n=l;if(!l)return;let o="";((y=Pa.analyzeSplitToContent(l,"}"))==null?void 0:y.length)>1&&(n=(f=Pa.analyzeSplitToContent(l,"}"))==null?void 0:f[0],o=(v=Pa.analyzeSplitToContent(l,"}"))==null?void 0:v[1]),(l==null?void 0:l[0])==="{"&&(l==null?void 0:l[(l==null?void 0:l.length)-1])==="}"&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1));let s=[],c=[];return s.push({label:"排序",prop:"sort"}),s.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(m=Pa.analyzeSplitToContent(n,","))==null||m.forEach(x=>{var E;(x==null?void 0:x[(x==null?void 0:x.length)-1])===","&&(x=x==null?void 0:x.slice(0,(x==null?void 0:x.length)-1)),(x==null?void 0:x[0])==="{"?(E=xi(x,r))==null||E.forEach(B=>{s.push(B)}):s.push(tt(x,r))}),o!==""&&((o==null?void 0:o[0])=="{"&&(o=o==null?void 0:o.slice(1,(o==null?void 0:o.length)-1)),(u=Pa.analyzeSplitToContent(o,","))==null||u.forEach(x=>{var E;(x==null?void 0:x[(x==null?void 0:x.length)-1])===","&&(x=x==null?void 0:x.slice(0,(x==null?void 0:x.length)-1)),(x==null?void 0:x[0])==="{"?(E=xi(x,r))==null||E.forEach(B=>{c.push(B)}):c.push(tt(x,r))})),{columns:s,secondColumns:c}},st=l=>{var r,n,o;if(l!=null&&l.includes("@Filter")||l!=null&&l.includes("@Condition"))return l;{let s=(n=(r=l==null?void 0:l.replace("(",Ra))==null?void 0:r.split(Ra))==null?void 0:n[1];return s=s==null?void 0:s.slice(0,(s==null?void 0:s.length)-1),s=(o=Pa.analyzeSplitToContent(s,","))==null?void 0:o.map(c=>((c==null?void 0:c[(c==null?void 0:c.length)-1])===","&&(c=c==null?void 0:c.slice(0,(c==null?void 0:c.length)-1)),"@"+c)),s=s==null?void 0:s.join(","),l!=null&&l.includes("@Quote")&&(s!=null&&s.includes("@Type")||(s=s===""?s+"@Type=Manual":s+",@Type=Manual"),s!=null&&s.includes("@SonSync")||(s=s===""?s+"@SonSync=No":s+",@SonSync=No"),s!=null&&s.includes("@FatherSync")||(s=s===""?s+"@FatherSync=Yes":s+",@FatherSync=Yes")),s}},Qt=l=>{let r=l==null?void 0:l.map(n=>{var o,s;return{menus:n==null?void 0:n.menus,content:((o=n==null?void 0:n.menus)==null?void 0:o.join("/"))+Ra+((s=n==null?void 0:n.groups)==null?void 0:s.join("/"))}});return r=r==null?void 0:r.filter(n=>{var o;return(n==null?void 0:n.menus)&&((o=n==null?void 0:n.menus)==null?void 0:o.length)>0}),r=r==null?void 0:r.map(n=>n==null?void 0:n.content),r=[...new Set(r)],r=r==null?void 0:r.map(n=>{var o,s;return{menus:(o=n==null?void 0:n.split(Ra))==null?void 0:o[0],groups:((s=n==null?void 0:n.split(Ra))==null?void 0:s[1])??[]}}),r},Ad=(l,r,n="")=>{var N,Y,b,$,T,k,_,U,W,ce,Ee,Ie,De,ne,ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va;let o=[];if(((N=l==null?void 0:l[0])==null?void 0:N[0])!=="*"&&((Y=l==null?void 0:l[0])==null?void 0:Y[0])!=="$")return;let s=Pa.analyzeSplitToContent(l==null?void 0:l[0],":"),c=s==null?void 0:s.filter(re=>!((re==null?void 0:re[0])!=="{"&&(re==null?void 0:re[0])!=="["));o=(b=s==null?void 0:s.filter(re=>(re==null?void 0:re[0])!=="{"&&(re==null?void 0:re[0])!=="["))==null?void 0:b.join("");let y="",f="";if((o==null?void 0:o[(o==null?void 0:o.length)-1])===":"&&(o=o==null?void 0:o.slice(0,(o==null?void 0:o.length)-1)),o!=null&&o.includes("(@")&&(o==null?void 0:o[0])==="*"&&(y="(@"+(($=o==null?void 0:o.split("(@"))==null?void 0:$[1]),o=(T=o==null?void 0:o.split("(@"))==null?void 0:T[0]),o!=null&&o.includes("@")&&(o==null?void 0:o[0])==="*"&&(y="@"+((_=(k=o==null?void 0:o.replace("@",Ra))==null?void 0:k.split(Ra))==null?void 0:_[1]),o=(W=(U=o==null?void 0:o.replace("@",Ra))==null?void 0:U.split(Ra))==null?void 0:W[0]),(o==null?void 0:o[0])==="*"?(o=o==null?void 0:o.slice(1,o==null?void 0:o.length),o=o==null?void 0:o.split(":")):(f=I.cloneDeep(o)+":",o=[]),f=f+((c==null?void 0:c[0])??""),(f==null?void 0:f[(f==null?void 0:f.length)-1])===":"&&(f=f==null?void 0:f.slice(0,(f==null?void 0:f.length)-1)),y!==""&&f!=="")if((f==null?void 0:f[(f==null?void 0:f.length)-1])===")")if(f!=null&&f.includes("(@")){let re=(ce=f==null?void 0:f.split("(@"))==null?void 0:ce[0],Ce=(Ee=f==null?void 0:f.split("(@"))==null?void 0:Ee[1];Ce="(@"+(Ce==null?void 0:Ce.slice(0,(Ce==null?void 0:Ce.length)-1))+y,f=re+Ce}else{let re=(De=(Ie=f==null?void 0:f.replace("@",Ra))==null?void 0:Ie.split(Ra))==null?void 0:De[0],Ce=(ge=(ne=f==null?void 0:f.replace("@",Ra))==null?void 0:ne.split(Ra))==null?void 0:ge[1];Ce="(@"+Ce+y,f=re+Ce}else f=f+y;let v=c==null?void 0:c[1];(f==null?void 0:f[0])==="["&&(v=I.cloneDeep(f)+(v??""),f="");let m=v?Eo(v):[];!(m!=null&&m.every(re=>Array.isArray(re)))&&(m==null?void 0:m.length)>0&&(m=[m]);let u=(X=Pa.analyzeSplitToContent(f,"@"))!=null&&X[1]?"@"+((de=Pa.analyzeSplitToContent(f,"@"))==null?void 0:de[1]):"";if(f=(Ke=Pa.analyzeSplitToContent(f,"@"))==null?void 0:Ke[0],(f==null?void 0:f[0])==="$"&&(u=I.cloneDeep(f)+(u??""),f=""),n!=="")if(y!=="")u=(n==null?void 0:n[(n==null?void 0:n.length)-1])!==")"?n+y:(n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1))+","+y;else{let re="";if(n!=null&&n.includes("(@")){let Ce=(me=(le=(S=(oe=(Ta=n==null?void 0:n.replace("(@",Ra))==null?void 0:Ta.split(Ra))==null?void 0:oe[0])==null?void 0:S.replace("{",Ra))==null?void 0:le.split(Ra))==null?void 0:me[0];re=((Ce==null?void 0:Ce[(Ce==null?void 0:Ce.length)-1])===":"?Ce==null?void 0:Ce.slice(0,(Ce==null?void 0:Ce.length)-1):Ce)+"(@"+((Ne=(ue=n==null?void 0:n.replace("(@",Ra))==null?void 0:ue.split(Ra))==null?void 0:Ne[1])}else if(n!=null&&n.includes("@")){let Ce=(la=(ee=(Wa=(_a=(pa=n==null?void 0:n.replace("@",Ra))==null?void 0:pa.split(Ra))==null?void 0:_a[0])==null?void 0:Wa.replace("{",Ra))==null?void 0:ee.split(Ra))==null?void 0:la[0];re=((Ce==null?void 0:Ce[(Ce==null?void 0:Ce.length)-1])===":"?Ce==null?void 0:Ce.slice(0,(Ce==null?void 0:Ce.length)-1):Ce)+"@"+((ka=(Ve=n==null?void 0:n.replace("@",Ra))==null?void 0:Ve.split(Ra))==null?void 0:ka[1])}u=re===""?n:re}if(u!==""){(u==null?void 0:u[0])==="$"&&(u=u==null?void 0:u.slice(1,u==null?void 0:u.length)),(u==null?void 0:u[(u==null?void 0:u.length)-1])===":"&&(u=u==null?void 0:u.slice(0,(u==null?void 0:u.length)-1));let re="";if(u!=null&&u.includes("(@")){re=(Te=(He=u==null?void 0:u.replace("(@",Ra))==null?void 0:He.split(Ra))==null?void 0:Te[0];let Ce=(Ge=(Re=u==null?void 0:u.replace("(@",Ra))==null?void 0:Re.split(Ra))==null?void 0:Ge[1];Ce="@"+(Ce==null?void 0:Ce.slice(0,(Ce==null?void 0:Ce.length)-1));let Z=(Ga=Pa.analyzeSplitToContent(Ce,","))==null?void 0:Ga.map(fa=>((fa==null?void 0:fa[(fa==null?void 0:fa.length)-1])===","&&(fa=fa==null?void 0:fa.slice(0,(fa==null?void 0:fa.length)-1)),(fa==null?void 0:fa[(fa==null?void 0:fa.length)-1])!==")"&&(fa=fa+")"),st(fa)));u=re+"("+(Z==null?void 0:Z.join(","))+")"}else{re=(P=(Fa=u==null?void 0:u.replace("@",Ra))==null?void 0:Fa.split(Ra))==null?void 0:P[0];let Ce=(J=(F=u==null?void 0:u.replace("@",Ra))==null?void 0:F.split(Ra))==null?void 0:J[1];if(Ce){Ce="@"+Ce;let Z=(ie=Pa.analyzeSplitToContent(Ce,","))==null?void 0:ie.map(fa=>((fa==null?void 0:fa[(fa==null?void 0:fa.length)-1])!==")"&&(fa=fa+")"),st(fa)));u=re+"("+(Z==null?void 0:Z.join(","))+")"}else u=re}}(f==null?void 0:f[(f==null?void 0:f.length)-1])==="@"&&(f=f==null?void 0:f.slice(0,(f==null?void 0:f.length)-1));let x=Td(f,r),E=f===""?[]:(x==null?void 0:x.columns)??[],B=ca.getColumnChild(E),w=B;w=w==null?void 0:w.filter(re=>{var Ce,Z;return(re==null?void 0:re.filter)&&(re==null?void 0:re.filter)!==""&&(((Ce=re==null?void 0:re.filter)==null?void 0:Ce.includes("@SonSync"))||((Z=re==null?void 0:re.filter)==null?void 0:Z.includes("@FatherSync")))});let V=w==null?void 0:w.filter(re=>{var Ce,Z,fa;return((Ce=re==null?void 0:re.filter)==null?void 0:Ce.includes("@SonSync"))&&((fa=(Z=re==null?void 0:re.filter)==null?void 0:Z.split(","))==null?void 0:fa.find(Ye=>(Ye==null?void 0:Ye.includes("@SonSync"))&&(Ye==null?void 0:Ye.includes("Yes"))))}),A=w==null?void 0:w.filter(re=>{var Ce,Z,fa;return((Ce=re==null?void 0:re.filter)==null?void 0:Ce.includes("@FatherSync"))&&((fa=(Z=re==null?void 0:re.filter)==null?void 0:Z.split(","))==null?void 0:fa.find(Ye=>(Ye==null?void 0:Ye.includes("@FatherSync"))&&(Ye==null?void 0:Ye.includes("Yes"))))});if(B=B==null?void 0:B.map(re=>{var Ce,Z;return{menus:re==null?void 0:re.menus,content:((Ce=re==null?void 0:re.menus)==null?void 0:Ce.join("/"))+Ra+((Z=re==null?void 0:re.groups)==null?void 0:Z.join("/"))}}),A=Qt(A),V=Qt(V),B=B==null?void 0:B.filter(re=>{var Ce;return(re==null?void 0:re.menus)&&((Ce=re==null?void 0:re.menus)==null?void 0:Ce.length)>0}),B=B==null?void 0:B.map(re=>re==null?void 0:re.content),B=[...new Set(B)],B=B==null?void 0:B.map(re=>{var Ce,Z;return{menus:(Ce=re==null?void 0:re.split(Ra))==null?void 0:Ce[0],groups:((Z=re==null?void 0:re.split(Ra))==null?void 0:Z[1])??[]}}),E!=null&&E.some(re=>{var Ce;return Array.isArray(re==null?void 0:re.children)&&((Ce=re==null?void 0:re.children)==null?void 0:Ce.length)>0})&&(E=[E]),(m==null?void 0:m.length)>0&&(Array.isArray(m==null?void 0:m[0])&&((se=m==null?void 0:m[0])!=null&&se.every(re=>Array.isArray(re)))?m=m==null?void 0:m.map((re,Ce)=>(re=re.map((Z,fa)=>(Z.unshift("{}"),Z.unshift((fa+1).toString()),Z)),re)):m=m==null?void 0:m.map((re,Ce)=>(re.unshift("{}"),re.unshift((Ce+1).toString()),re))),x!=null&&x.secondColumns&&((ma=x==null?void 0:x.secondColumns)==null?void 0:ma.length)>0&&((m==null?void 0:m.length)>0?m=m==null?void 0:m.map((re,Ce)=>{var Z,fa;return Array.isArray(re==null?void 0:re[0])?re=re==null?void 0:re.map((Ye,Ma)=>{var Ue,Ya;return Ye.unshift((Ya=(Ue=x==null?void 0:x.secondColumns)==null?void 0:Ue[Ma])==null?void 0:Ya.prop),Ye}):re.unshift((fa=(Z=x==null?void 0:x.secondColumns)==null?void 0:Z[Ce])==null?void 0:fa.prop),re}):m=(oa=x==null?void 0:x.secondColumns)==null?void 0:oa.map((re,Ce)=>(re=[re==null?void 0:re.label],re.push(Ce),re)),E.unshift({label:"",prop:"disabled",sortable:!1})),(E==null?void 0:E.length)>0){let re=I.cloneDeep(E);Array.isArray(re==null?void 0:re[0])&&(re=re==null?void 0:re[0]);let Ce=ca.getColumnChild(re);Ce=Ce==null?void 0:Ce.map(Z=>Z==null?void 0:Z.filter),Ce=Ce==null?void 0:Ce.filter(Z=>Z&&Z!==""),Ce=[...new Set(Ce)],(Ce==null?void 0:Ce.length)>0&&(u=Ra+(u==null?void 0:u.slice(1,(u==null?void 0:u.length)-1))+(u!=null&&u.slice(1,(u==null?void 0:u.length)-1)?",":"")+((Oe=I.cloneDeep(Ce))==null?void 0:Oe.join(";")))}if((u==null?void 0:u[0])!=="("&&(u!=null&&u.includes("(@"))){let re=(wa=(_e=u==null?void 0:u.replace("(",Ra))==null?void 0:_e.split(Ra))==null?void 0:wa[0],Ce=[{menus:(Xe=(ve=re==null?void 0:re.split("*"))==null?void 0:ve[0])==null?void 0:Xe.replaceAll(":","/"),groups:(aa=re==null?void 0:re.split("*"))==null?void 0:aa[1]}],Z=(xa=(Pe=u==null?void 0:u.replace("(",Ra))==null?void 0:Pe.split(Ra))==null?void 0:xa[1];(Z==null?void 0:Z[(Z==null?void 0:Z.length)-1])===")"&&(Z=Z==null?void 0:Z.slice(0,(Z==null?void 0:Z.length)-1)),Z=Pa.analyzeSplitToContent(Z,","),(Le=Z==null?void 0:Z.find(fa=>fa==null?void 0:fa.includes("@FatherSync")))!=null&&Le.includes("Yes")&&(A=[...A,...Ce]),(va=Z==null?void 0:Z.find(fa=>fa==null?void 0:fa.includes("@SonSync")))!=null&&va.includes("Yes")&&(V=[...V,...Ce])}return{groupName:o,tableColumns:E,tableFilter:u,tableContents:m,columns:(x==null?void 0:x.secondColumns)??[],relatedQuotes:B,fatherSyncContents:A,sonSyncContents:V}},Ws=(l,r)=>(l=l==null?void 0:l.map((n,o)=>{var s,c,y,f;if(Array.isArray(n))n=n==null?void 0:n.map(v=>{var m,u,x,E;return v!=null&&v.isMainPath||(((m=v==null?void 0:v.children)==null?void 0:m.length)>0?v.children=Ws(v.children,r):((u=v==null?void 0:v.menus)==null?void 0:u.length)>0&&!((x=n==null?void 0:n[0])!=null&&x.isMainPath)&&(v.menus=(E=v.menus)==null?void 0:E.map((B,w)=>{var V,A;return((V=v.menus)==null?void 0:V.length)-1===w&&B===""&&(r==null?void 0:r.parentContent)+"/"!==((A=v.menus)==null?void 0:A.join("/"))&&(B=r==null?void 0:r.value),v}),v.bindMenus=v.menus)),v});else{if(o===0&&((s=n.menus)==null?void 0:s.length)>0&&(n.mainKey=!0),n!=null&&n.isMainPath)return n;((c=n.menus)==null?void 0:c.length)>0&&!((y=l==null?void 0:l[0])!=null&&y.isMainPath)&&(n.menus=(f=n.menus)==null?void 0:f.map((v,m)=>{var u,x;return((u=n.menus)==null?void 0:u.length)-1===m&&v===""&&(r==null?void 0:r.parentContent)+"/"!==((x=n.menus)==null?void 0:x.join("/"))&&(v=r==null?void 0:r.value),v}),n.bindMenus=n.menus)}return n}),l),zd=(l,r)=>(l=l==null?void 0:l.map(n=>((n==null?void 0:n.key)==="header"&&(n.contents=Ws(n.contents,r)),n)),l),ct=(l,r)=>{let n=l;return Array.isArray(n==null?void 0:n[0])?n=n==null?void 0:n.map(o=>(o=ct(o,r),o)):n=n==null?void 0:n.map(o=>{var s,c;return o!=null&&o.children&&((s=o==null?void 0:o.children)==null?void 0:s.length)>0?o.children=ct(o==null?void 0:o.children,r):o!=null&&o.words&&((c=o==null?void 0:o.words)==null?void 0:c.length)>0&&(r!=null&&r.find(y=>{var f,v,m,u;return((u=(f=o==null?void 0:o.prop)==null?void 0:f.split("."))==null?void 0:u[((m=(v=o==null?void 0:o.prop)==null?void 0:v.split("."))==null?void 0:m.length)-1])===y}))&&(o.mainKey=!0),o}),n};let or="$R";const Md=I.useUnit(I.pinia),{selectTitle:sn}=I.storeToRefs(Md),cn=[{key:"@MaxRow",value:"onNumSlice",order:1},{key:"@Type",value:"onRandomContents",order:2},{key:"@Filter",value:"onConditionContents",order:4},{key:"@FatherSync",value:"onFatherPaceContents",order:1},{key:"@SonSync",value:"onPaceContents",order:1},{key:"@MainPam",value:"onMainTagContents",order:3},{key:"@TopButton",value:"onButtonContents",order:1},{key:"@ColumnButton",value:"onPamButtonContents",order:1},{key:"@RowButton",value:"onRowButtonContents",order:1},{key:"@BottomButton",value:"onBottomButtonContents",order:1},{key:"@Related",value:"onRelated",order:1},{key:"@RowNum",value:"onRowNum",order:1},{key:"@FixRow",value:"onFixRow",order:1},{key:"@ReqItem",value:"onReqItem",order:1},{key:"@Condition",value:"onConditionContent",order:1},{key:"@Tab",value:"onTabs",order:1},{key:"@SinChoice",value:"onSinChoice",order:1},{key:"@TextSize",value:"onTextSize",order:1},{key:"@TextRGBA",value:"onTextRGBA",order:1},{key:"@Position",value:"onPosition",order:4},{key:"@Size",value:"onSize",order:4},{key:"@ShowType",value:"onShowType",order:1},{key:"@StepName",value:"onStepName",order:1},{key:"@Step",value:"onStep",order:1}];var ao=(l=>(l[l.ORDINARY=1]="ORDINARY",l[l.BLOCK=2]="BLOCK",l[l.TEXT=3]="TEXT",l))(ao||{});const Ks=l=>{if(l==null)return null;const r=String(l).trim();if(!r.startsWith("[")||!r.endsWith("]"))return null;const n=r.slice(1,-1).split(",").map(o=>Number(o.trim()));return n.length<2||n.some(o=>Number.isNaN(o))?null:[n[0],n[1]]},Ys=(l,r)=>{var V,A,N,Y,b;const n=Array.isArray(l)?l:[],o=n.find($=>($==null?void 0:$.key)==="formContent"),s=Array.isArray(o==null?void 0:o.contents)?o.contents:[],c=((V=n.find($=>($==null?void 0:$.key)==="_gridLayoutMeta"))==null?void 0:V.contents)??{},y=(s==null?void 0:s[0])??{};let f=((A=r==null?void 0:r.position)==null?void 0:A[0])??(c==null?void 0:c._positionStartRow)??(y==null?void 0:y._positionStartRow),v=((N=r==null?void 0:r.position)==null?void 0:N[1])??(c==null?void 0:c._positionRowSpan)??(y==null?void 0:y._positionRowSpan);(!f||Number.isNaN(f)||f<1)&&(f=1),(!v||Number.isNaN(v)||v<1)&&(v=1);let m=((Y=r==null?void 0:r.size)==null?void 0:Y[0])??(c==null?void 0:c._sizeStart)??(y==null?void 0:y._sizeStart),u=((b=r==null?void 0:r.size)==null?void 0:b[1])??(c==null?void 0:c._sizeEnd)??(y==null?void 0:y._sizeEnd);(m===void 0||Number.isNaN(m))&&(m=0),(u===void 0||Number.isNaN(u))&&(u=1),m=Math.max(0,Math.min(1,m)),u=Math.max(0,Math.min(1,u)),u<=m&&(m=0,u=1);const x=u-m,E=Math.max(1,Math.round(1/x));let B=n.map($=>{if(($==null?void 0:$.key)!=="formContent")return $;const T=Array.isArray($==null?void 0:$.contents)?$.contents:[];return{...$,contents:T.map(k=>({...k,width:E,_positionStartRow:f,_positionRowSpan:v,_sizeStart:m,_sizeEnd:u}))}});const w={_positionStartRow:f,_positionRowSpan:v,_sizeStart:m,_sizeEnd:u};return B.some($=>($==null?void 0:$.key)==="_gridLayoutMeta")?B=B.map($=>($==null?void 0:$.key)==="_gridLayoutMeta"?{...$,contents:w}:$):B.push({key:"_gridLayoutMeta",contents:w}),B},Od=l=>{const r=Ks(l==null?void 0:l.filter);return r?Ys(l==null?void 0:l.contents,{position:r}):l==null?void 0:l.contents},Id=l=>{const r=Ks(l==null?void 0:l.filter);return r?Ys(l==null?void 0:l.contents,{size:r}):l==null?void 0:l.contents},Ld=l=>{if((l==null?void 0:l.filter)!==void 0&&(l==null?void 0:l.filter)!==null&&(l==null?void 0:l.filter)!==""){let r=l==null?void 0:l.contents;const n=Number(l==null?void 0:l.filter);return r.push({key:"textSize",contents:Number.isNaN(n)?l==null?void 0:l.filter:n}),r}return l==null?void 0:l.contents},$d=l=>{if((l==null?void 0:l.filter)!==void 0&&(l==null?void 0:l.filter)!==null&&(l==null?void 0:l.filter)!==""){let r=l==null?void 0:l.contents;return r.push({key:"textRGBA",contents:l==null?void 0:l.filter}),r}return l==null?void 0:l.contents},Rd=l=>{var n;return(l==null?void 0:l.filter.toUpperCase())==="ALL"||(l==null?void 0:l.filter.toUpperCase())==="NONE"?l==null?void 0:l.contents:(n=l==null?void 0:l.contents)==null?void 0:n.map(o=>{var s;return(o==null?void 0:o.key)==="tableContents"&&(o.contents=(s=o.contents)==null?void 0:s.slice(0,parseInt(l==null?void 0:l.filter))),o})},Vd=async l=>{var r,n,o,s,c,y,f,v,m,u,x,E,B,w,V,A,N,Y,b,$,T,k,_,U,W,ce,Ee,Ie,De,ne;if((l==null?void 0:l.filter)==="Random")return(r=l==null?void 0:l.contents)==null?void 0:r.map(X=>((X==null?void 0:X.key)==="tableContents"&&(X.contents=Pa.shuffle(X.contents)),X));if((l==null?void 0:l.filter)==="Ordin"){let ge=l==null?void 0:l.contents;return ge.push({key:"enableWrap",contents:1}),ge}if((l==null?void 0:l.filter)==="Block"){let ge=l==null?void 0:l.contents;return ge.push({key:"enableWrap",contents:2}),ge}if((l==null?void 0:l.filter)==="Auto"){let ge=(o=(n=l==null?void 0:l.contents)==null?void 0:n.find(ue=>(ue==null?void 0:ue.key)==="header"))==null?void 0:o.contents;Array.isArray(ge==null?void 0:ge[0])&&(ge=ge==null?void 0:ge[0]),ge=ca.getColumnChild(ge);let X=ge==null?void 0:ge.filter(ue=>(ue==null?void 0:ue.filter)&&(ue==null?void 0:ue.filter)!==""),de=new Map,Ke=[];X==null||X.forEach(ue=>{var Ne,pa;de.get((Ne=ue==null?void 0:ue.menus)==null?void 0:Ne.join("/"))||(de.set((pa=ue==null?void 0:ue.menus)==null?void 0:pa.join("/"),ue),Ke.push(ue))});let Ta=(c=(s=sn==null?void 0:sn.value)==null?void 0:s.find(ue=>(ue==null?void 0:ue.condition)==="child"))==null?void 0:c.value,oe=Ke==null?void 0:Ke.map(ue=>{var Ne,pa,_a;return ue=(Ne=ue==null?void 0:ue.menus)==null?void 0:Ne.join("/"),(ue==null?void 0:ue[(ue==null?void 0:ue.length)-1])==="/"&&((_a=(pa=sn==null?void 0:sn.value)==null?void 0:pa.find(Wa=>(Wa==null?void 0:Wa.condition)==="child"))==null?void 0:_a.parentContent)+"/"!==ue?ue=ue+Ta:(ue==null?void 0:ue[(ue==null?void 0:ue.length)-1])==="/"&&(ue=ue==null?void 0:ue.slice(0,(ue==null?void 0:ue.length)-1)),ue}),S=Ke==null?void 0:Ke.map(ue=>ue==null?void 0:ue.groups),le=oe==null?void 0:oe.map(async ue=>{let Ne=await Vr(ue,!1);return{path:ue,contents:Ne}});le=await Promise.all(le);let me=le==null?void 0:le.map((ue,Ne)=>{var _a,Wa,ee,la,Ve,ka,He;let pa=(_a=ue==null?void 0:ue.contents)==null?void 0:_a.filter(Te=>{var Re,Ge;return(Te==null?void 0:Te.name)===((Ge=S==null?void 0:S[Ne])==null?void 0:Ge[((Re=S==null?void 0:S[Ne])==null?void 0:Re.length)-1])});return pa=(la=(ee=(Wa=pa==null?void 0:pa[0])==null?void 0:Wa.compData)==null?void 0:ee.find(Te=>(Te==null?void 0:Te.key)==="tableContents"))==null?void 0:la.contents,(ue==null?void 0:ue.path)===((ka=(Ve=sn==null?void 0:sn.value)==null?void 0:Ve.find(Te=>(Te==null?void 0:Te.condition)==="child"))==null?void 0:ka.parentContent)&&(pa=((He=pa==null?void 0:pa.map(Te=>{for(let Re in Te)if(Te[Re]===Ta)return Te}))==null?void 0:He.filter(Te=>Te))??[]),pa??[]});if(me=me==null?void 0:me.map(ue=>(ue=ue==null?void 0:ue.map(Ne=>{var _a;let pa={};for(let Wa in Ne)if(X!=null&&X.find(ee=>{var la,Ve;return((Ve=(la=ee==null?void 0:ee.words)==null?void 0:la[0])==null?void 0:Ve.replaceAll("'",""))===Wa})){let ee=(_a=X==null?void 0:X.find(la=>{var Ve,ka;return((ka=(Ve=la==null?void 0:la.words)==null?void 0:Ve[0])==null?void 0:ka.replaceAll("'",""))===Wa}))==null?void 0:_a.prop;pa[ee]=Ne==null?void 0:Ne[Wa]}return pa}),ue)),me=Pa.cartesianProduct(me),Array.isArray(me==null?void 0:me[0])&&(me=me==null?void 0:me[0]),(me==null?void 0:me.length)>0&&((x=(f=(y=X==null?void 0:X[0])==null?void 0:y.menus)==null?void 0:f.join("/"))==null?void 0:x[((u=(m=(v=X==null?void 0:X[0])==null?void 0:v.menus)==null?void 0:m.join("/"))==null?void 0:u.length)-1])==="/")return(E=l==null?void 0:l.contents)==null?void 0:E.map(Ne=>{var pa;return(Ne==null?void 0:Ne.key)==="tableContents"&&(me==null?void 0:me.length)>0&&(Ne.contents=((pa=Ne.contents)==null?void 0:pa.length)>0?Ne.contents:me),Ne})}if((l==null?void 0:l.filter)==="Text"){let ge=l==null?void 0:l.contents;return ge.push({key:"enableWrap",contents:3}),ge}if((l==null?void 0:l.filter)==="Manual"){let ge=[],X=[],de=(w=(B=l==null?void 0:l.contents)==null?void 0:B.find(S=>(S==null?void 0:S.key)==="filter"))==null?void 0:w.contents;(de==null?void 0:de[(de==null?void 0:de.length)-1])===")"?de=(A=(V=de==null?void 0:de.replace("(",or))==null?void 0:V.split(or))==null?void 0:A[0]:de="",de!==""&&(ge=((Y=(N=de==null?void 0:de.split("*"))==null?void 0:N[0])==null?void 0:Y.split(":"))??[],X=((_=(k=(T=($=(b=de==null?void 0:de.split("*"))==null?void 0:b[1])==null?void 0:$.replace("{",or))==null?void 0:T.split(or))==null?void 0:k[0])==null?void 0:_.split(":"))??[]);let Ke=(W=(U=l==null?void 0:l.contents)==null?void 0:U.find(S=>(S==null?void 0:S.key)==="filter"))==null?void 0:W.contents;Ke=(Ee=(ce=Ke==null?void 0:Ke.replace("(",or))==null?void 0:ce.split(or))==null?void 0:Ee[1],Ke=Ke==null?void 0:Ke.slice(0,(Ke==null?void 0:Ke.length)-1);let Ta=(Ie=l==null?void 0:l.contents)==null?void 0:Ie.map(S=>{var le,me,ue,Ne,pa,_a,Wa,ee,la;return(S==null?void 0:S.key)==="header"&&((le=S==null?void 0:S.contents)!=null&&le.every(Ve=>(Ve==null?void 0:Ve.mainKey)!==!0)&&Array.isArray(S==null?void 0:S.contents)&&!Array.isArray((me=S==null?void 0:S.contents)==null?void 0:me[0])?S.contents=(ue=S==null?void 0:S.contents)==null?void 0:ue.map((Ve,ka)=>{var He,Te,Re;return Ve!=null&&Ve.isMainPath||(ka===0?(Ve.mainKey=!0,Ve.formType="Select",Ve.bindMenus=ge,Ve.groups=((He=Ve.groups)==null?void 0:He.length)===0?X:Ve.groups,Ve.words=((Te=Ve.words)==null?void 0:Te.length)===0?[Ve==null?void 0:Ve.prop]:Ve.words,Ve.filter=Ke,(!(Ve!=null&&Ve.menus)||((Re=Ve==null?void 0:Ve.menus)==null?void 0:Re.length)===0)&&(Ve.menus=ge)):(Ve.mainKey=!1,Ve.bindMenus=ge)),Ve}):Array.isArray((Ne=S==null?void 0:S.contents)==null?void 0:Ne[0])&&((Wa=(_a=(pa=S==null?void 0:S.contents)==null?void 0:pa[0])==null?void 0:_a.filter(()=>(ge==null?void 0:ge.length)>0))==null?void 0:Wa.length)>0&&(S.contents[0]=(la=(ee=S==null?void 0:S.contents)==null?void 0:ee[0])==null?void 0:la.map((Ve,ka)=>{var He,Te,Re;return Ve!=null&&Ve.isMainPath||(ka===0?(Ve.mainKey=!0,Ve.formType="Select",Ve.bindMenus=ge,Ve.groups=((He=Ve.groups)==null?void 0:He.length)===0?X:Ve.groups,Ve.words=((Te=Ve.words)==null?void 0:Te.length)===0?[Ve==null?void 0:Ve.prop]:Ve.words,Ve.filter=Ke,(!(Ve!=null&&Ve.menus)||Array.isArray(Ve==null?void 0:Ve.menus)&&((Re=Ve==null?void 0:Ve.menus)==null?void 0:Re.length)===0)&&(ge==null?void 0:ge.length)>0&&(Ve.menus=ge)):(Ve.mainKey=!1,Ve.bindMenus=ge)),Ve}))),S}),oe=(De=Ta==null?void 0:Ta.find(S=>(S==null?void 0:S.key)==="header"))==null?void 0:De.contents;if(Array.isArray(oe==null?void 0:oe[0])&&(oe=oe==null?void 0:oe[0]),oe=ca.getColumnChild(oe),oe!=null&&oe.some(S=>{var le,me;return((me=S==null?void 0:S.menus)==null?void 0:me[((le=S==null?void 0:S.menus)==null?void 0:le.length)-1])===""})){let S=(ne=sn==null?void 0:sn.value)==null?void 0:ne.find(le=>(le==null?void 0:le.condition)==="child");Ta=zd(Ta,S)}return Ta}return l==null?void 0:l.contents},Pd=l=>{var o,s,c,y;let r=l==null?void 0:l.filter;if(r!=null&&r.includes("*")&&(r="({"+((s=(o=r==null?void 0:r.replace("{",or))==null?void 0:o.split(or))==null?void 0:s[1])),r=(c=r==null?void 0:r.replaceAll("{",""))==null?void 0:c.replaceAll("}",""),(r==null?void 0:r[0])!=="("&&(r="("+r+")"),r.slice(1,(r==null?void 0:r.length)-1)==="undefined")return l==null?void 0:l.contents;let n=ca.calculatorAndToOr(r);if((n==null?void 0:n.length)>0){let f=[];return n==null||n.forEach(m=>{let u={};for(let x in m){let E=x;E!=null&&E.includes("[")||(u[E]=m[x])}f.push(u)}),(y=l==null?void 0:l.contents)==null?void 0:y.map(m=>{var x,E,B;let u=(E=(x=l==null?void 0:l.contents)==null?void 0:x.find(w=>(w==null?void 0:w.key)==="header"))==null?void 0:E.contents;if(u=(B=ca.getEqualChild(u))==null?void 0:B.filter(w=>(w==null?void 0:w.label)!=="操作"),(m==null?void 0:m.key)==="tableContents"){let V=ca.tableToForm(m==null?void 0:m.contents,u);f==null||f.forEach(A=>{var N,Y;for(let b in A)!((N=V==null?void 0:V[0])!=null&&N.find($=>{var T;return($==null?void 0:$.key)===b||((T=$==null?void 0:$.key)==null?void 0:T.includes(b))}))&&!(V!=null&&V.find($=>{var T;return($==null?void 0:$.key)===b||((T=$==null?void 0:$.key)==null?void 0:T.includes(b))}))||(((Y=A[b])==null?void 0:Y[0])!=="!"?V=V==null?void 0:V.filter($=>{var T,k;return((T=$==null?void 0:$.find(_=>{var U;return(_==null?void 0:_.key)===b||((U=_==null?void 0:_.key)==null?void 0:U.includes(b))}))==null?void 0:T.value)===A[b]||Array.isArray(A==null?void 0:A[b])&&((k=A==null?void 0:A[b])==null?void 0:k.find(_=>{var U;return((U=$==null?void 0:$.find(W=>{var ce;return(W==null?void 0:W.key)===b||((ce=W==null?void 0:W.key)==null?void 0:ce.includes(b))}))==null?void 0:U.value)===_}))}):V=V==null?void 0:V.filter($=>{var T;return((T=$==null?void 0:$.find(k=>{var _;return(k==null?void 0:k.key)===b||((_=k==null?void 0:k.key)==null?void 0:_.includes(b))}))==null?void 0:T.value)!==A[b]}))}),(V==null?void 0:V.length)===0?m.contents=[]:m.contents=V==null?void 0:V.map(A=>{let N={};return A==null||A.forEach(Y=>{N[Y==null?void 0:Y.key]=Y==null?void 0:Y.value}),N})}return m})}return l==null?void 0:l.contents},Fd=l=>l==null?void 0:l.contents,jd=l=>l==null?void 0:l.contents,Hd=l=>{var r,n,o,s;if((l==null?void 0:l.filter)!==""&&(l!=null&&l.filter)){let c=(o=(n=l==null?void 0:l.filter)==null?void 0:n.slice(1,((r=l==null?void 0:l.filter)==null?void 0:r.length)-1))==null?void 0:o.split(",");return(s=l==null?void 0:l.contents)==null?void 0:s.map(f=>((f==null?void 0:f.key)==="header"&&(f.contents=ct(f.contents,c)),f))}return l==null?void 0:l.contents},Ud=l=>{var n;let r=(l==null?void 0:l.filter)??"";return(r==null?void 0:r[0])==="{"&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1)),r!==""?(n=l==null?void 0:l.contents)==null?void 0:n.map(s=>{var c;return(s==null?void 0:s.key)==="extraButton"&&(s.contents=(c=r==null?void 0:r.split(","))==null?void 0:c.map(y=>({label:y,prop:y}))),s}):l==null?void 0:l.contents},qd=l=>l==null?void 0:l.contents,Wd=l=>{var n;let r=(l==null?void 0:l.filter)??"";return(r==null?void 0:r[0])==="{"&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1)),r!==""?(n=l==null?void 0:l.contents)==null?void 0:n.map(s=>{var c;return(s==null?void 0:s.key)==="rowButton"&&(s.contents=(c=r==null?void 0:r.split(","))==null?void 0:c.map(y=>({label:y,prop:y}))),s}):l==null?void 0:l.contents},Kd=l=>{var n;let r=(l==null?void 0:l.filter)??"";if((r==null?void 0:r[0])==="{"&&(r=r==null?void 0:r.slice(1,(r==null?void 0:r.length)-1)),r!==""){let o=l==null?void 0:l.contents,s=(n=r==null?void 0:r.split(","))==null?void 0:n.map(c=>({label:c,prop:c}));return o.push({key:"bottomButton",contents:s}),o}return l==null?void 0:l.contents},Yd=l=>{var r,n,o,s;if(((r=l==null?void 0:l.filter)==null?void 0:r[0])!=="["){const c=parseInt(l==null?void 0:l.filter);return!c||Number.isNaN(c)?l==null?void 0:l.contents:(n=l==null?void 0:l.contents)==null?void 0:n.map(f=>{var v;return(f==null?void 0:f.key)==="formContent"&&(f.contents=(v=f.contents)==null?void 0:v.map(m=>(m.width=c,m))),f})}if(((o=l==null?void 0:l.filter)==null?void 0:o[0])==="["){let c=Eo(l==null?void 0:l.filter),y=Array.isArray(c)?c.map(v=>parseInt(v)).filter(v=>!!v&&!Number.isNaN(v)):[];return y.length?(s=l==null?void 0:l.contents)==null?void 0:s.map(v=>{if((v==null?void 0:v.key)==="formContent"){const m=v.contents??[];v.contents=m.map((u,x)=>{const E=x+1;let B=0,w=0;for(let A=0;A<y.length;A++){if(w+=y[A],E<=w){B=A;break}A===y.length-1&&(B=y.length-1)}const V=y[B]||y[y.length-1]||1;return u.width=V,u})}return v}):l==null?void 0:l.contents}return l==null?void 0:l.contents},Gd=l=>{var r;if((l==null?void 0:l.filter)!==""){let n=l==null?void 0:l.filter;return(n==null?void 0:n[0])==="{"&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1)),n=n==null?void 0:n.split(","),(r=l==null?void 0:l.contents)==null?void 0:r.map(s=>{var c,y,f;return(s==null?void 0:s.key)==="header"&&(Array.isArray((c=s==null?void 0:s.contents)==null?void 0:c[0])?s.contents[0]=(f=s.contents[0])==null?void 0:f.map(v=>(n!=null&&n.find(m=>m===(v==null?void 0:v.prop))&&(v.fixed="left"),v)):s.contents=(y=s.contents)==null?void 0:y.map(v=>(n!=null&&n.find(m=>m===(v==null?void 0:v.prop))&&(v.fixed="left"),v))),s})}return l==null?void 0:l.contents},Jd=l=>{var r;if((l==null?void 0:l.filter)!==""){let n=l==null?void 0:l.filter;(n==null?void 0:n[0])==="{"&&(n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1)),n=n==null?void 0:n.split(",");const o=c=>(n!=null&&n.find(y=>y===(c==null?void 0:c.prop))&&(c.required=!0),c!=null&&c.children&&Array.isArray(c.children)&&(c.children=c.children.map(y=>o(y))),c);return(r=l==null?void 0:l.contents)==null?void 0:r.map(c=>{var y,f,v;return(c==null?void 0:c.key)==="header"&&(Array.isArray((y=c==null?void 0:c.contents)==null?void 0:y[0])?c.contents[0]=(v=c.contents[0])==null?void 0:v.map(m=>o(m)):c.contents=(f=c.contents)==null?void 0:f.map(m=>o(m))),c})}return l==null?void 0:l.contents},Xd=async l=>{var o,s,c,y,f,v,m,u,x,E,B,w,V,A,N,Y,b;const r=I.useUnit(I.pinia),{chooseTitle:n}=I.storeToRefs(r);if((l==null?void 0:l.filter)==="true"){let $=await Vr(((s=(o=n==null?void 0:n.value)==null?void 0:o[0])==null?void 0:s.parentContent)??((y=(c=n==null?void 0:n.value)==null?void 0:c[0])==null?void 0:y.relatedContent),!1),T=(v=(f=n==null?void 0:n.value)==null?void 0:f[0])==null?void 0:v.value;(u=(m=$==null?void 0:$[0])==null?void 0:m.compData)!=null&&u.find(W=>(W==null?void 0:W.key)==="header")?$=(x=$==null?void 0:$[0])==null?void 0:x.compData:$=(B=(E=$==null?void 0:$.filter(W=>{var ce;return(ce=W==null?void 0:W.compData)==null?void 0:ce.find(Ee=>(Ee==null?void 0:Ee.key)==="header")}))==null?void 0:E[0])==null?void 0:B.compData;let k=(w=$==null?void 0:$.find(W=>(W==null?void 0:W.key)==="header"))==null?void 0:w.contents;Array.isArray(k==null?void 0:k[0])&&(k=k==null?void 0:k[0]),k=((V=k==null?void 0:k.find(W=>W==null?void 0:W.isMainKey))==null?void 0:V.prop)??((A=k==null?void 0:k[0])==null?void 0:A.prop);let _=(Y=(N=$==null?void 0:$.find(W=>(W==null?void 0:W.key)==="tableContents"))==null?void 0:N.contents)==null?void 0:Y.find(W=>(W==null?void 0:W[k])===T);return(b=l==null?void 0:l.contents)==null?void 0:b.map(W=>{var ce;return(W==null?void 0:W.key)==="formContent"&&(W.contents=(ce=W.contents)==null?void 0:ce.map(Ee=>(Ee.value=_==null?void 0:_[Ee==null?void 0:Ee.prop],Ee))),W})}return l==null?void 0:l.contents},Zd=l=>{var r,n,o,s,c;if((r=l==null?void 0:l.extra)!=null&&r.row){let y=l==null?void 0:l.filter;if(y!=null&&y.includes("*")&&(y="({"+((o=(n=y==null?void 0:y.replace("{",or))==null?void 0:n.split(or))==null?void 0:o[1])),y=(s=y==null?void 0:y.replaceAll("{",""))==null?void 0:s.replaceAll("}",""),(y==null?void 0:y[0])!=="("&&(y="("+y+")"),y.slice(1,(y==null?void 0:y.length)-1)==="undefined")return l==null?void 0:l.contents;let f=ca.calculatorAndToOr(y),v=f==null?void 0:f[0],m=(c=l==null?void 0:l.extra)==null?void 0:c.row,u=[];for(let x in v)(v==null?void 0:v[x])===(m==null?void 0:m[x])?u.push(!0):u.push(!1);return u!=null&&u.every(x=>x===!0)?l==null?void 0:l.contents:[]}else return l==null?void 0:l.contents},Qd=l=>{if(l!=null&&l.filter){let r=l==null?void 0:l.contents;return r.push({key:"tab",contents:l==null?void 0:l.filter}),r}return l==null?void 0:l.contents},ep=l=>{if(l!=null&&l.filter){let r=l==null?void 0:l.contents;return r.push({key:"choice",contents:l==null?void 0:l.filter}),r}return l==null?void 0:l.contents},ap=l=>{if(l!=null&&l.filter){let r=l==null?void 0:l.contents;return r.push({key:"fixType",contents:l==null?void 0:l.filter}),r}return l==null?void 0:l.contents},lp=l=>{var r;if(l!=null&&l.filter){let n=l==null?void 0:l.contents,o=l==null?void 0:l.filter;return(o==null?void 0:o[0])==="{"&&(o=o==null?void 0:o.slice(1,(o==null?void 0:o.length)-1)),o=(r=Pa.analyzeSplitToContent(o,","))==null?void 0:r.map(s=>((s==null?void 0:s[(s==null?void 0:s.length)-1])===","&&(s=s==null?void 0:s.slice(0,(s==null?void 0:s.length)-1)),s)),n.push({key:"stepName",contents:o}),n}return l==null?void 0:l.contents},rp=l=>{if(l!=null&&l.filter){let r=l==null?void 0:l.contents;return r.push({key:"step",contents:l==null?void 0:l.filter}),r}return l==null?void 0:l.contents},Gs={onNumSlice:Rd,onRandomContents:Vd,onConditionContents:Pd,onFatherPaceContents:Fd,onPaceContents:jd,onMainTagContents:Hd,onButtonContents:Ud,onPamButtonContents:qd,onRowButtonContents:Wd,onRelated:Xd,onRowNum:Yd,onFixRow:Gd,onReqItem:Jd,onBottomButtonContents:Kd,onConditionContent:Zd,onTabs:Qd,onSinChoice:ep,onTextSize:Ld,onTextRGBA:$d,onPosition:Od,onSize:Id,onShowType:ap,onStepName:lp,onStep:rp},np=async(l,r)=>{var c,y,f,v,m,u,x,E,B,w,V,A,N,Y,b,$,T,k,_;let n="";if(((c=l==null?void 0:l.find(U=>(U==null?void 0:U.key)==="filter"))==null?void 0:c.contents)!==""&&(n=(y=l==null?void 0:l.find(U=>(U==null?void 0:U.key)==="filter"))==null?void 0:y.contents),n===""||!n)return l;(n==null?void 0:n[0])==="("?n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1):(n=(v=(f=n==null?void 0:n.replace("(",or))==null?void 0:f.split(or))==null?void 0:v[1],n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1));let o=(m=Pa.analyzeSplitToContent(n,","))==null?void 0:m.map(U=>((U==null?void 0:U[(U==null?void 0:U.length)-1])===","&&(U=U==null?void 0:U.slice(0,(U==null?void 0:U.length)-1)),U!=null&&U.includes("(")||(U=U==null?void 0:U.replaceAll(":","=")),U)),s=l;for(let U in o){let W,ce="";(u=o==null?void 0:o[U])!=null&&u.includes("(")?(W=(B=(E=(x=o==null?void 0:o[U])==null?void 0:x.replace("(",or))==null?void 0:E.split(or))==null?void 0:B[0],ce="("+((A=(V=(w=o==null?void 0:o[U])==null?void 0:w.replace("(",or))==null?void 0:V.split(or))==null?void 0:A[1])):(W=(b=(Y=(N=o==null?void 0:o[U])==null?void 0:N.replace("=",or))==null?void 0:Y.split(or))==null?void 0:b[0],ce=(k=(T=($=o==null?void 0:o[U])==null?void 0:$.replace("=",or))==null?void 0:T.split(or))==null?void 0:k[1]);let Ee=(_=cn==null?void 0:cn.find(Ie=>(Ie==null?void 0:Ie.key)===W))==null?void 0:_.value;if(Ee){const Ie=Gs[Ee];s=await Ie({contents:s,filter:ce})}}return s},kt=async(l,r)=>{var y,f,v,m,u,x,E,B,w,V,A,N,Y,b,$,T,k,_,U,W;let n="";if(((y=l==null?void 0:l.find(ce=>(ce==null?void 0:ce.key)==="filter"))==null?void 0:y.contents)!==""&&(n=(f=l==null?void 0:l.find(ce=>(ce==null?void 0:ce.key)==="filter"))==null?void 0:f.contents),n===""||!n)return l;(n==null?void 0:n[0])===","&&(n=n==null?void 0:n.slice(1,n==null?void 0:n.length)),(n==null?void 0:n[0])==="("?n=n==null?void 0:n.slice(1,(n==null?void 0:n.length)-1):(n==null?void 0:n[0])==="@"||(n=(m=(v=n==null?void 0:n.replace("(",or))==null?void 0:v.split(or))==null?void 0:m[1],n=n==null?void 0:n.slice(0,(n==null?void 0:n.length)-1));let o=(u=Pa.analyzeSplitToContent(n,","))==null?void 0:u.map(ce=>((ce==null?void 0:ce[(ce==null?void 0:ce.length)-1])===","&&(ce=ce==null?void 0:ce.slice(0,(ce==null?void 0:ce.length)-1)),ce!=null&&ce.includes("(")||(ce=ce==null?void 0:ce.replaceAll(":","=")),ce)),s=l,c=new Map;o==null||o.forEach(ce=>{var Ie,De,ne;let Ee=(Ie=ce==null?void 0:ce.split("="))==null?void 0:Ie[0];if(Ee==="@MainPam"&&c.get(Ee)){let ge=c.get(Ee);ge=ge==null?void 0:ge.slice(0,(ge==null?void 0:ge.length)-1);let X=(ne=(De=ce==null?void 0:ce.replace("{",or))==null?void 0:De.split(or))==null?void 0:ne[1];X=ge+","+X,c.set(Ee,X)}else c.set(Ee,ce)}),o=Array.from(c.values()),o=o==null?void 0:o.sort((ce,Ee)=>{var Ie,De;return((Ie=cn==null?void 0:cn.find(ne=>Ee==null?void 0:Ee.includes(ne==null?void 0:ne.key)))==null?void 0:Ie.order)-((De=cn==null?void 0:cn.find(ne=>ce==null?void 0:ce.includes(ne==null?void 0:ne.key)))==null?void 0:De.order)});for(let ce in o){let Ee,Ie="";(x=o==null?void 0:o[ce])!=null&&x.includes("(")&&((E=o==null?void 0:o[ce])!=null&&E.includes("@Filter"))?(Ee=(V=(w=(B=o==null?void 0:o[ce])==null?void 0:B.replace("(",or))==null?void 0:w.split(or))==null?void 0:V[0],Ie="("+((Y=(N=(A=o==null?void 0:o[ce])==null?void 0:A.replace("(",or))==null?void 0:N.split(or))==null?void 0:Y[1])):(Ee=(T=($=(b=o==null?void 0:o[ce])==null?void 0:b.replace("=",or))==null?void 0:$.split(or))==null?void 0:T[0],Ie=(U=(_=(k=o==null?void 0:o[ce])==null?void 0:k.replace("=",or))==null?void 0:_.split(or))==null?void 0:U[1]);let De=(W=cn==null?void 0:cn.find(ne=>(ne==null?void 0:ne.key)===Ee))==null?void 0:W.value;if(De){const ne=Gs[De];s=await ne({contents:s,filter:Ie,extra:r})}}return s};let ti="$R";const op=I.useUnit(I.pinia),{selectTitle:ip}=I.storeToRefs(op);let tp=[{label:"新增",prop:"新增"},{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],sp=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"},{label:"复制新增",prop:"复制新增"},{label:"删除",prop:"删除"}],cp=[{label:"导入",prop:"导入",type:"upload"},{label:"导出",prop:"导出",type:"popover",contents:[{label:"导出选中"},{label:"导出全部"}]}],up=[{label:"查看",prop:"查看"},{label:"编辑",prop:"编辑"}];const es=async(l,r,n=!0)=>{let o=[],s=l==null?void 0:l.map(async c=>{var x,E,B,w,V,A,N,Y,b,$,T,k,_,U,W,ce,Ee,Ie,De,ne,ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye,Ma,Ue,Ya,ga,ba,$a,Sa,Na,Oa,Be,tl;let y=(w=(B=(E=(x=c==null?void 0:c.contents)==null?void 0:x.find(Ea=>{var El;return(El=Ea==null?void 0:Ea.key)==null?void 0:El.includes("struct")}))==null?void 0:E.value)==null?void 0:B[0])==null?void 0:w.类型,f=Object.values(c==null?void 0:c.name);f=f==null?void 0:f.reverse();let v=(V=c==null?void 0:c.contents)==null?void 0:V.map(Ea=>Ea==null?void 0:Ea.key),m={comp:y,isShow:c==null?void 0:c.is_show,name:f==null?void 0:f[0],id:c==null?void 0:c.object_id,relatedTables:v,menuFilter:(A=c==null?void 0:c.filter)==null?void 0:A.menuFilter,status:c==null?void 0:c.status,fatherSyncContents:(N=c==null?void 0:c.filter)==null?void 0:N.fatherSyncs,relatedQuotes:(Y=c==null?void 0:c.filter)==null?void 0:Y.quotes,sonSyncContents:(b=c==null?void 0:c.filter)==null?void 0:b.sonSyncs};for(let Ea in f)parseInt(Ea)>=1&&(m[`name${parseInt(Ea)-1}`]=f[Ea]);let u=(T=($=c==null?void 0:c.filter)==null?void 0:$.menuFilter)==null?void 0:T.split(",");if(((k=u==null?void 0:u.filter(Ea=>Ea==null?void 0:Ea.includes("@Filter")))==null?void 0:k.length)>0){let Ea=u==null?void 0:u.filter(xe=>xe==null?void 0:xe.includes("@Filter"));Ea=Ea==null?void 0:Ea[0],Ea=(U=(_=Ea==null?void 0:Ea.replace("(",ti))==null?void 0:_.split(ti))==null?void 0:U[1],Ea=Ea==null?void 0:Ea.slice(0,(Ea==null?void 0:Ea.length)-1),Ea!=null&&Ea.includes("*")&&(Ea=(ce=(W=Ea==null?void 0:Ea.replace("{",ti))==null?void 0:W.split(ti))==null?void 0:ce[1],Ea=Ea==null?void 0:Ea.replace("}","")),Ea=ca.calculatorAndToOr(Ea);let El=(r==null?void 0:r.originPath)??"";(El==null?void 0:El[(El==null?void 0:El.length)-1])==="/"&&(El=El==null?void 0:El.slice(0,(El==null?void 0:El.length)-1));let ml=await Vr(El,!1),Fe=(Ee=ml==null?void 0:ml.filter(xe=>(xe==null?void 0:xe.comp)==="Table"))==null?void 0:Ee[0];Fe=(De=(Ie=Fe==null?void 0:Fe.compData)==null?void 0:Ie.find(xe=>(xe==null?void 0:xe.key)==="tableContents"))==null?void 0:De.contents;let Va=(ge=(ne=ip.value)==null?void 0:ne.find(xe=>(xe==null?void 0:xe.condition)==="child"))==null?void 0:ge.value;Fe=(X=Fe==null?void 0:Fe.map(xe=>{for(let Ze in xe)if((xe==null?void 0:xe[Ze])===Va)return xe}))==null?void 0:X.filter(xe=>xe),Fe=Fe==null?void 0:Fe[0],Ea=Ea==null?void 0:Ea[0];let je=[];for(let xe in Ea){let Ze="";rl.isObject(Fe)&&(Ze=(Ke=(de=Object.keys(Fe))==null?void 0:de.filter(Je=>Je==null?void 0:Je.includes("."+xe)))==null?void 0:Ke[0]),Ze!==""&&(Fe!=null&&Fe[Ze])&&(Ea==null?void 0:Ea[xe])===(Fe==null?void 0:Fe[Ze])||Fe!=null&&Fe[xe]&&(Ea==null?void 0:Ea[xe])===(Fe==null?void 0:Fe[xe])?je.push(!0):je.push(!1)}if(je!=null&&je.some(xe=>xe===!1)&&((oe=r==null?void 0:r.originPath)==null?void 0:oe[((Ta=r==null?void 0:r.originPath)==null?void 0:Ta.length)-1])!=="/")return}if(y==="Table"||y==="Method"){let Ea=((S=c==null?void 0:c.contents)==null?void 0:S.find(q=>{var ra;return(ra=q==null?void 0:q.key)==null?void 0:ra.includes("content")}))||[],El=[];m.comp="Table",Ea.value=(le=Ea==null?void 0:Ea.value)==null?void 0:le.sort((q,ra)=>parseInt(q==null?void 0:q.id)-parseInt(ra==null?void 0:ra.id)),Ea.value=(me=Ea==null?void 0:Ea.value)==null?void 0:me.map(q=>{let ra={};for(let ya in q)JSON.stringify(q==null?void 0:q[ya])==="{}"?ra[ya]="":ra[ya]=q==null?void 0:q[ya];return ra}),El.push({key:"tableContents",contents:Ea==null?void 0:Ea.value});let ml=(Wa=(_a=(pa=(Ne=(ue=c==null?void 0:c.contents)==null?void 0:ue.find(q=>{var ra;return(ra=q==null?void 0:q.key)==null?void 0:ra.includes("struct")}))==null?void 0:Ne.value)==null?void 0:pa[0])==null?void 0:_a.结构)==null?void 0:Wa.contents;Array.isArray(ml==null?void 0:ml[0])?ml[0]=(ee=ml==null?void 0:ml[0])==null?void 0:ee.filter(q=>(q==null?void 0:q.prop)!=="sort"&&(q==null?void 0:q.prop)!=="relatedId"):ml=ml==null?void 0:ml.filter(q=>(q==null?void 0:q.prop)!=="sort"&&(q==null?void 0:q.prop)!=="relatedId"),El.push({key:"header",contents:ml}),El.push({key:"filter",contents:(Te=(He=(ka=(Ve=(la=c==null?void 0:c.contents)==null?void 0:la.find(q=>{var ra;return(ra=q==null?void 0:q.key)==null?void 0:ra.includes("struct")}))==null?void 0:Ve.value)==null?void 0:ka[0])==null?void 0:He.引用)==null?void 0:Te.contents});let Fe=tp,Va=I.cloneDeep(sp);y==="Method"&&Va.push({label:"生成方法",prop:"生成方法"}),!Array.isArray(ml==null?void 0:ml[0])&&((Re=ml==null?void 0:ml[0])==null?void 0:Re.prop)==="disabled"&&(Fe=cp,Va=up);const je=["推力","真空","压力","温度","流量"],xe=m.name;xe&&je.includes(xe)&&(Fe=[...Fe],Fe.push({label:"导出paraform",prop:"导出paraform",type:"methodButton"}));let Ze=[];if(!Array.isArray(ml==null?void 0:ml[0])&&(ml!=null&&ml.some(q=>{var ra;return(q==null?void 0:q.calculatorFilter)&&((ra=q==null?void 0:q.calculatorFilter)==null?void 0:ra.includes("Manual"))}))){let q=(Ge=ml==null?void 0:ml.map(ra=>ra==null?void 0:ra.calculatorFilter))==null?void 0:Ge.filter(ra=>ra&&(ra==null?void 0:ra.includes("Manual")));q==null||q.forEach(ra=>{var we;let ya=Pa.analyzeSplitToContent(ra,",");if(ya=ya==null?void 0:ya.map(Se=>((Se==null?void 0:Se[(Se==null?void 0:Se.length)-1])===","&&(Se=Se==null?void 0:Se.slice(0,(Se==null?void 0:Se.length)-1)),Se)),ya!=null&&ya.find(Se=>(Se==null?void 0:Se.includes("Extent"))&&(Se==null?void 0:Se.includes("Row")))&&(ya!=null&&ya.find(Se=>(Se==null?void 0:Se.includes("Button"))&&(Se==null?void 0:Se.includes(","))))){let Se=ya==null?void 0:ya.find(qa=>qa==null?void 0:qa.includes("@Button"));Se=(we=Se==null?void 0:Se.split("="))==null?void 0:we[1],Se=Se==null?void 0:Se.slice(1,(Se==null?void 0:Se.length)-1),Se=Se==null?void 0:Se.split(","),Se=Se==null?void 0:Se[(Se==null?void 0:Se.length)-1],Ze.push(Se)}}),Ze=[...new Set(Ze)],Ze=Ze==null?void 0:Ze.map(ra=>({label:ra,prop:ra,type:"methodButton"}))}else if(Array.isArray(ml==null?void 0:ml[0])&&((Ga=ca.getColumnChild(ml==null?void 0:ml[0]))!=null&&Ga.some(q=>{var ra;return(q==null?void 0:q.calculatorFilter)&&((ra=q==null?void 0:q.calculatorFilter)==null?void 0:ra.includes("Manual"))}))){let q=(P=(Fa=ca.getColumnChild(ml==null?void 0:ml[0]))==null?void 0:Fa.map(ra=>ra==null?void 0:ra.calculatorFilter))==null?void 0:P.filter(ra=>ra&&(ra==null?void 0:ra.includes("Manual")));q==null||q.forEach(ra=>{var we;let ya=Pa.analyzeSplitToContent(ra,",");if(ya=ya==null?void 0:ya.map(Se=>((Se==null?void 0:Se[(Se==null?void 0:Se.length)-1])===","&&(Se=Se==null?void 0:Se.slice(0,(Se==null?void 0:Se.length)-1)),Se)),ya!=null&&ya.find(Se=>(Se==null?void 0:Se.includes("Extent"))&&(Se==null?void 0:Se.includes("Row")))&&(ya!=null&&ya.find(Se=>(Se==null?void 0:Se.includes("Button"))&&(Se==null?void 0:Se.includes(","))))){let Se=ya==null?void 0:ya.find(qa=>qa==null?void 0:qa.includes("@Button"));Se=(we=Se==null?void 0:Se.split("="))==null?void 0:we[1],Se=Se==null?void 0:Se.slice(1,(Se==null?void 0:Se.length)-1),Se=Se==null?void 0:Se.split(","),Se=Se==null?void 0:Se[(Se==null?void 0:Se.length)-1],Ze.push(Se)}}),Ze=[...new Set(Ze)],Ze=Ze==null?void 0:Ze.map(ra=>({label:ra,prop:ra,type:"methodButton"}))}El.push({key:"extraButton",contents:Fe}),El.push({key:"rowButton",contents:[...Va,...Ze]}),m.compData=await kt(El,r),(F=m.compData)!=null&&F.find(q=>(q==null?void 0:q.key)==="tab")&&(m.tab=(ie=(J=m.compData)==null?void 0:J.find(q=>(q==null?void 0:q.key)==="tab"))==null?void 0:ie.contents),(se=m.compData)!=null&&se.find(q=>(q==null?void 0:q.key)==="step")&&(m.step=(oa=(ma=m.compData)==null?void 0:ma.find(q=>(q==null?void 0:q.key)==="step"))==null?void 0:oa.contents),(Oe=m.compData)!=null&&Oe.find(q=>(q==null?void 0:q.key)==="choice")&&(m.choice=(wa=(_e=m.compData)==null?void 0:_e.find(q=>(q==null?void 0:q.key)==="choice"))==null?void 0:wa.contents);let Je="",ea=(ve=m==null?void 0:m.compData)==null?void 0:ve.filter(q=>(q==null?void 0:q.key)==="fixType");(ea==null?void 0:ea.length)>0&&n&&(Je=(Xe=ea==null?void 0:ea[0])==null?void 0:Xe.contents,m.comp=Je)}else if(y==="Form"){let Ea=[],El=(xa=(Pe=(aa=c==null?void 0:c.contents)==null?void 0:aa.find(Fe=>{var Va;return(Va=Fe==null?void 0:Fe.key)==null?void 0:Va.includes("content")}))==null?void 0:Pe.value)==null?void 0:xa[0],ml=(Ye=(fa=(Z=(Ce=(re=(va=(Le=c==null?void 0:c.contents)==null?void 0:Le.find(Fe=>{var Va;return(Va=Fe==null?void 0:Fe.key)==null?void 0:Va.includes("struct")}))==null?void 0:va.value)==null?void 0:re[0])==null?void 0:Ce.结构)==null?void 0:Z.contents)==null?void 0:fa.map(Fe=>(Fe.value=El==null?void 0:El[Fe==null?void 0:Fe.prop],Fe)))==null?void 0:Ye.filter(Fe=>(Fe==null?void 0:Fe.prop)!=="sort"&&(Fe==null?void 0:Fe.prop)!=="relatedId");Ea.push({key:"filter",contents:(ba=(ga=(Ya=(Ue=(Ma=c==null?void 0:c.contents)==null?void 0:Ma.find(Fe=>{var Va;return(Va=Fe==null?void 0:Fe.key)==null?void 0:Va.includes("struct")}))==null?void 0:Ue.value)==null?void 0:Ya[0])==null?void 0:ga.引用)==null?void 0:ba.contents}),Ea.push({key:"formContent",contents:ml}),m.compData=await np(Ea),($a=m.compData)!=null&&$a.find(Fe=>(Fe==null?void 0:Fe.key)==="tab")&&(m.tab=(Na=(Sa=m.compData)==null?void 0:Sa.find(Fe=>(Fe==null?void 0:Fe.key)==="tab"))==null?void 0:Na.contents),(Oa=m.compData)!=null&&Oa.find(Fe=>(Fe==null?void 0:Fe.key)==="step")&&(m.step=(tl=(Be=m.compData)==null?void 0:Be.find(Fe=>(Fe==null?void 0:Fe.key)==="step"))==null?void 0:tl.contents)}return m});return o=await Promise.all(s),o},dp=I.useLoginState(I.pinia),{loginUserInfo:bo}=I.storeToRefs(dp),ut=async(l,r,n="Manual",o=[])=>{var v;let s=l,c;Array.isArray(r==null?void 0:r[0])?c=ca.getColumnChild(r==null?void 0:r[0]):c=r;let y=(v=c==null?void 0:c.filter(m=>{var u;return(m==null?void 0:m.calculatorFilter)&&((u=m==null?void 0:m.calculatorFilter)==null?void 0:u.includes(n))||(m==null?void 0:m.calculatorFilter)===""&&(m==null?void 0:m.functionName)}))==null?void 0:v.map(m=>({prop:m==null?void 0:m.prop,label:m==null?void 0:m.label,methods:m==null?void 0:m.calculatorFilter,functionName:m==null?void 0:m.functionName,functionRelatedWords:m==null?void 0:m.functionRelatedWords})),f=s==null?void 0:s.map(async m=>(m=await yp(m,y,c,n,s,o),m));return f=await Promise.all(f),f},pp=l=>{let r=l==null?void 0:l.contents,n=l==null?void 0:l.valueString,o=l==null?void 0:l.prop,s=l==null?void 0:l.headers,c;return Array.isArray(r)&&(r==null?void 0:r.length)!==1&&(r=ca.getValueToObjectValue(r,ca.getColumnContents(s))),n==null||n.forEach(y=>{var f;if(r!=null&&r[y]){let v=r==null?void 0:r[y];c=c?v?Pa.isEqual(v.toString(),c.toString()):void 0:v}else{let v=(f=s==null?void 0:s.find(u=>(u==null?void 0:u.label)===y))==null?void 0:f.prop,m=(r==null?void 0:r[v])??0;c=c?m?Pa.isEqual(m.toString(),c.toString()):void 0:m}}),r[o]=c===void 0?void 0:c?1:0,r},fr=l=>{const[r,n,o]=I.cloneDeep(l).split(":").map(Number);let s=+l;return!l||!(l!=null&&l.includes(":"))?s:(r??0)*3600+(n??0)*60+(o??0)},Un=l=>{const r=c=>c.toString().padStart(2,"0"),n=Math.floor(l/3600),o=Math.floor(l%3600/60),s=l%60;return`${r(n)}:${r(o)}:${parseInt(r(s))}`},fp=l=>{let r=l==null?void 0:l.contents,n=l==null?void 0:l.valueString,o=l==null?void 0:l.prop,s=l==null?void 0:l.headers,c=l==null?void 0:l.typeString,y=l==null?void 0:l.allContents,f=0;if(Array.isArray(r)&&(r==null?void 0:r.length)!==1&&(r=ca.getValueToObjectValue(r,ca.getColumnContents(s))),n==null||n.forEach(v=>{var m,u,x,E,B,w,V,A,N;if(r!=null&&r[v]){if(c==="Row")if(!((u=((m=r==null?void 0:r[v])==null?void 0:m.toString())??"")!=null&&u.includes(":"))&&!((x=f==null?void 0:f.toString())!=null&&x.includes(":"))){let Y=+(r==null?void 0:r[v]);f=f+Y}else f=fr(f.toString())+fr((E=r==null?void 0:r[v])==null?void 0:E.toString()),f=Un(f)}else if(c==="Row"){let Y=(B=s==null?void 0:s.find(b=>(b==null?void 0:b.label)===v))==null?void 0:B.prop;if(!((V=Number.isNaN(r==null?void 0:r[Y])?"":(w=r==null?void 0:r[Y])==null?void 0:w.toString())!=null&&V.includes(":"))&&!((A=f==null?void 0:f.toString())!=null&&A.includes(":"))){let b=+((r==null?void 0:r[Y])??0);f=f+b}else f=fr(f==null?void 0:f.toString())+fr((N=(r==null?void 0:r[Y])??0)==null?void 0:N.toString()),f=Un(f)}}),c==="Column"){let v=[];n==null||n.forEach(m=>{let u=y==null?void 0:y.map(x=>{var E;return(x==null?void 0:x[m])??(x==null?void 0:x[(E=s==null?void 0:s.find(B=>(B==null?void 0:B.label)===m))==null?void 0:E.prop])});v=[...v,...u]}),f=v.reduce((m,u)=>{let x=0;Number.isNaN(m)||(x=+m);let E=0;return Number.isNaN(u)||(E=+u),x+E},0)}return r[o]=f,r},hp=l=>{let r=l==null?void 0:l.contents,n=l==null?void 0:l.valueString,o=l==null?void 0:l.prop,s=l==null?void 0:l.headers,c=l==null?void 0:l.typeString,y=l==null?void 0:l.allContents,f=0;if(Array.isArray(r)&&(r==null?void 0:r.length)!==1&&(r=ca.getValueToObjectValue(r,ca.getColumnContents(s))),n==null||n.forEach(v=>{var m,u,x,E,B,w,V;if(r!=null&&r[v]){if(c==="Row")if(!((u=(m=r==null?void 0:r[v])==null?void 0:m.toString())!=null&&u.includes(":"))&&!((x=f==null?void 0:f.toString())!=null&&x.includes(":"))){let A=+(r==null?void 0:r[v]);f=f===0?f+A:f-A}else f=f===0?fr(f.toString())+fr(r==null?void 0:r[v].toString()):fr(f.toString())-fr(r==null?void 0:r[v].toString()),f=Un(f)}else if(c==="Row"){let A=(E=s==null?void 0:s.find(N=>(N==null?void 0:N.label)===v))==null?void 0:E.prop;if(!((w=Number.isNaN(r==null?void 0:r[A])?"":(B=r==null?void 0:r[A])==null?void 0:B.toString())!=null&&w.includes(":"))&&!((V=f==null?void 0:f.toString())!=null&&V.includes(":"))){let N=+((r==null?void 0:r[A])??0);f=f===0?f+N:f-N}else f=f===0?fr(f.toString())+fr(((r==null?void 0:r[A])??0).toString()):fr(f.toString())-fr(((r==null?void 0:r[A])??0).toString()),f=Un(f)}}),c==="Column"){let v=[];n==null||n.forEach(m=>{let u=y==null?void 0:y.map(x=>{var E;return(x==null?void 0:x[m])??(x==null?void 0:x[(E=s==null?void 0:s.find(B=>(B==null?void 0:B.label)===m))==null?void 0:E.prop])});v=[...v,...u]}),f=v.reduce((m,u)=>{let x=0;Number.isNaN(m)||(x=+m);let E=0;return Number.isNaN(u)||(E=+u),x-E},0)}return r[o]=f,r},vp=l=>{let r=l==null?void 0:l.contents,n=l==null?void 0:l.valueString,o=l==null?void 0:l.prop,s=l==null?void 0:l.headers,c=l==null?void 0:l.typeString,y=l==null?void 0:l.allContents,f=0;if(Array.isArray(r)&&(r==null?void 0:r.length)!==1&&(r=ca.getValueToObjectValue(r,ca.getColumnContents(s))),n==null||n.forEach(v=>{var m,u,x,E,B,w,V;if(r!=null&&r[v]){if(c==="Row")if(!((u=(m=r==null?void 0:r[v])==null?void 0:m.toString())!=null&&u.includes(":"))&&!((x=f==null?void 0:f.toString())!=null&&x.includes(":"))){let A=+(r==null?void 0:r[v]);f=f===0?f+A:f*A}else f=f===0?fr(f.toString())+fr(r==null?void 0:r[v].toString()):fr(f.toString())*fr(r==null?void 0:r[v].toString()),f=Un(f)}else if(c==="Row"){let A=(E=s==null?void 0:s.find(N=>(N==null?void 0:N.label)===v))==null?void 0:E.prop;if(!(r!=null&&r[A]))f=void 0;else if(!((w=Number.isNaN(r==null?void 0:r[A])?"":(B=r==null?void 0:r[A])==null?void 0:B.toString())!=null&&w.includes(":"))&&!((V=f==null?void 0:f.toString())!=null&&V.includes(":"))){let N=+((r==null?void 0:r[A])??0);f=f===0?f+N:f*N}else f=f===0?fr(f.toString())+fr(((r==null?void 0:r[A])??0).toString()):fr(f.toString())*fr(((r==null?void 0:r[A])??0).toString()),f=Un(f)}}),c==="Column"){let v=[];n==null||n.forEach(m=>{let u=y==null?void 0:y.map(x=>{var E;return(x==null?void 0:x[m])??(x==null?void 0:x[(E=s==null?void 0:s.find(B=>(B==null?void 0:B.label)===m))==null?void 0:E.prop])});v=[...v,...u]}),f=v.reduce((m,u)=>{let x=0;Number.isNaN(m)||(x=+m);let E=0;return Number.isNaN(u)||(E=+u),x*E},0)}return r[o]=f,r},mp=l=>{let r=l==null?void 0:l.contents,n=l==null?void 0:l.valueString,o=l==null?void 0:l.prop,s=l==null?void 0:l.headers,c=l==null?void 0:l.typeString,y=l==null?void 0:l.allContents,f=0;if(Array.isArray(r)&&(r==null?void 0:r.length)!==1&&(r=ca.getValueToObjectValue(r,ca.getColumnContents(s))),n==null||n.forEach(v=>{var m,u,x,E,B,w,V;if(r!=null&&r[v]){if(c==="Row")if(!((u=(m=r==null?void 0:r[v])==null?void 0:m.toString())!=null&&u.includes(":"))&&!((x=f==null?void 0:f.toString())!=null&&x.includes(":"))){let A=+(r==null?void 0:r[v]);f=f===0?f+A:f/A}else f=f===0?fr(f.toString())+fr(r==null?void 0:r[v].toString()):fr(f.toString())/fr(r==null?void 0:r[v].toString()),f=Un(f)}else if(c==="Row"){let A=(E=s==null?void 0:s.find(N=>(N==null?void 0:N.label)===v))==null?void 0:E.prop;if(!((w=Number.isNaN(r==null?void 0:r[A])?"":(B=r==null?void 0:r[A])==null?void 0:B.toString())!=null&&w.includes(":"))&&!((V=f==null?void 0:f.toString())!=null&&V.includes(":"))){let N=+((r==null?void 0:r[A])??0);f=f===0?f+N:f/N}else f=f===0?fr(f.toString())+fr(((r==null?void 0:r[A])??0).toString()):fr(f.toString())/fr(((r==null?void 0:r[A])??0).toString()),f=Un(f)}}),c==="Column"){let v=[];n==null||n.forEach(m=>{let u=y==null?void 0:y.map(x=>{var E;return(x==null?void 0:x[m])??(x==null?void 0:x[(E=s==null?void 0:s.find(B=>(B==null?void 0:B.label)===m))==null?void 0:E.prop])});v=[...v,...u]}),f=v.reduce((m,u)=>{let x=0;Number.isNaN(m)||(x=+m);let E=0;return Number.isNaN(u)||(E=+u),x/E},0)}return r[o]=f.toFixed(2),r},si={Sum:fp,Substract:hp,Multiple:vp,Divide:mp,Compare:pp},yp=async(l,r,n,o="Auto",s,c=[])=>{var u,x,E,B,w,V,A,N,Y,b,$,T,k,_,U,W,ce,Ee,Ie,De,ne;let y=l,f=[],v=await I.getPageDataApi({platId:parseInt((u=bo==null?void 0:bo.value)==null?void 0:u.plat_id),pageName:"menu"});v=(B=(E=(x=v==null?void 0:v.data)==null?void 0:x.result)==null?void 0:E.filter(ge=>(ge==null?void 0:ge.property_name)===""))==null?void 0:B[0];let m=[];if(v!=null&&v.object_name){v=v==null?void 0:v.object_name;let ge=await I.getPageDataApi({platId:parseInt((w=bo==null?void 0:bo.value)==null?void 0:w.plat_id),pageName:v});ge=(b=(Y=(N=(A=(V=ge==null?void 0:ge.data)==null?void 0:V.result)==null?void 0:A[0])==null?void 0:N.contents)==null?void 0:Y.find(X=>{var de;return(de=X==null?void 0:X.key)==null?void 0:de.includes("content")}))==null?void 0:b.value,f=($=ge==null?void 0:ge.map(X=>({functionName:X==null?void 0:X.函数名称,functionContent:X==null?void 0:X.输出值})))==null?void 0:$.filter(X=>(X==null?void 0:X.functionContent)!==""),f==null||f.forEach(X=>{m.push(X.functionName),si[X.functionName]=new Function("return "+X.functionContent)()})}if((r==null?void 0:r.length)===0)return y;for(let ge in r){let X=(T=r==null?void 0:r[ge])==null?void 0:T.functionName;const de=si==null?void 0:si[X];let Ke=(k=r==null?void 0:r[ge])==null?void 0:k.methods;if(Ke=Pa.analyzeSplitToContent(Ke,","),(_=Ke==null?void 0:Ke.find(Ta=>Ta==null?void 0:Ta.includes("@Type")))!=null&&_.includes(o)||(Ke==null?void 0:Ke.length)===0){let Ta=((ce=(W=(U=Ke==null?void 0:Ke.find(oe=>oe==null?void 0:oe.includes("@Extent")))==null?void 0:U.replace(":","="))==null?void 0:W.split("="))==null?void 0:ce[1])??[];if(await new Function("return ")(),(m==null?void 0:m.length)>0&&m.find(oe=>oe===X)){let oe="";try{let le=(Ee=r==null?void 0:r[ge])==null?void 0:Ee.functionRelatedWords,me=(c==null?void 0:c.length)>0?c==null?void 0:c.map(Ne=>{var pa;return Ne==null?void 0:Ne[(pa=r==null?void 0:r[ge])==null?void 0:pa.prop]}):["0"];me=me==null?void 0:me.map(Ne=>Ne==null?void 0:Ne.slice((Ne==null?void 0:Ne.length)-5,Ne==null?void 0:Ne.length)),me=me==null?void 0:me.map(Ne=>Pa.isNumber(parseInt(Ne))&&parseInt(Ne)?parseInt(Ne):0);let ue=Math.max(...me);le=le==null?void 0:le.map(Ne=>{if(Ne!=null&&Ne.includes("'"))return Ne==null?void 0:Ne.replaceAll("'","");if(Ne!=null&&Ne.includes("@"))return ue+1;{let pa=Object.keys(y);return Ne=(y==null?void 0:y[Ne])??(y==null?void 0:y[pa==null?void 0:pa.find(_a=>_a==null?void 0:_a.includes("."+Ne))]),Ne}}),oe=de(...le)}catch(le){rl.ElMessage.warning("关联数据出现错误,"+le.message)}let S=(Ie=r==null?void 0:r[ge])==null?void 0:Ie.prop;y[S]=oe}else y=de({contents:y,valueString:(De=r==null?void 0:r[ge])==null?void 0:De.functionRelatedWords,prop:(ne=r==null?void 0:r[ge])==null?void 0:ne.prop,headers:n,typeString:Ta,allContents:s})}}return y},gp=I.useLoginState(I.pinia),{loginUserInfo:Hr}=I.storeToRefs(gp),bp=I.useMenuState(I.pinia),{activeMenuPath:as,currentMenuPath:ci}=I.storeToRefs(bp),Js=I.useUnit(I.pinia);let ls="$R";const{selectTitle:wo}=I.storeToRefs(Js),Xs=async(l,r)=>{var y,f,v,m,u,x,E,B,w,V,A,N,Y;let n=as.value,o="",s=((y=wo==null?void 0:wo.value)==null?void 0:y.find(b=>(b==null?void 0:b.condition)==="child"&&!(b!=null&&b.relatedContent)))??void 0;(l==null?void 0:l.length)===0||(n=r?n:(f=l==null?void 0:l[0])==null?void 0:f.object_name,o=(v=l==null?void 0:l[0])==null?void 0:v.father_name);let c=[];if(o!==""){let b=o;(b==null?void 0:b[(b==null?void 0:b.length)-1])==="/"&&(b=b==null?void 0:b.slice(0,(b==null?void 0:b.length)-1));let $=await Vr(b,!1);$=(m=$==null?void 0:$[0])==null?void 0:m.compData;let T=(u=$==null?void 0:$.find(_=>(_==null?void 0:_.key)==="header"))==null?void 0:u.contents;T=((x=T==null?void 0:T.find(_=>_==null?void 0:_.isMainKey))==null?void 0:x.prop)??((E=T==null?void 0:T[0])==null?void 0:E.prop);let k=(w=(B=$==null?void 0:$.find(_=>(_==null?void 0:_.key)==="tableContents"))==null?void 0:B.contents)==null?void 0:w.map(_=>({label:_==null?void 0:_[T],value:_==null?void 0:_[T]}));c=(V=o==null?void 0:o.split("/"))==null?void 0:V.map(_=>(_===""?s?(s.isShow=!0,_=s):_={value:_,condition:"child",options:k,parentContent:(o==null?void 0:o[(o==null?void 0:o.length)-1])==="/"?o==null?void 0:o.slice(0,(o==null?void 0:o.length)-1):o,isShow:!0}:_={condition:"parent",value:_.trim(),isShow:!0},_))}if(n!==""){let b=(A=n==null?void 0:n.split("/"))==null?void 0:A.map($=>($={condition:"normal",value:$.trim(),isShow:!0},$));((N=b==null?void 0:b[0])==null?void 0:N.value)===((Y=c==null?void 0:c[0])==null?void 0:Y.value)&&(b=b==null?void 0:b.filter(($,T)=>T!==0)),c=[...c??[],...b??[]]}o===""&&s&&((s==null?void 0:s.parentContent)!==as.value&&(s.isShow=!1),(s==null?void 0:s.value)!==""&&c.push(s)),Js.setSelectTitle(c)},kp=async l=>{var c,y,f,v,m,u,x,E,B;let r=await I.getPageDataApi({platId:parseInt((c=Hr==null?void 0:Hr.value)==null?void 0:c.plat_id),pageName:"menu"}),n=(y=r==null?void 0:r.data)==null?void 0:y.result,o=(u=(m=(v=(f=l==null?void 0:l.filter(w=>(w==null?void 0:w.comp)==="Table"))==null?void 0:f[0])==null?void 0:v.compData)==null?void 0:m.find(w=>(w==null?void 0:w.key)==="filter"))==null?void 0:u.contents;o=(B=(E=(x=o==null?void 0:o.replace("(",ls))==null?void 0:x.split(ls))==null?void 0:E[0])==null?void 0:B.replaceAll(":","/");let s=n==null?void 0:n.filter(w=>{var V;return(w==null?void 0:w.object_name)===ci.value+"/"||((V=ci.value)==null?void 0:V.includes(o))&&o+"/"===(w==null?void 0:w.object_name)});return(s==null?void 0:s.length)>0&&(l=l==null?void 0:l.map(w=>{var V;return(w==null?void 0:w.comp)==="Table"&&(w.compData=(V=w==null?void 0:w.compData)==null?void 0:V.map(A=>{var N,Y,b;return(A==null?void 0:A.key)==="header"&&(Array.isArray((N=A.contents)==null?void 0:N[0])?A.contents[0]=(b=A.contents[0])==null?void 0:b.map(($,T)=>{var k;return T===0&&($.isExistChild=!0,(k=ci.value)!=null&&k.includes(o)&&($.fatherPath=o)),$}):A.contents=(Y=A.contents)==null?void 0:Y.map(($,T)=>{var k;return T===0&&($.isExistChild=!0,(k=ci.value)!=null&&k.includes(o)&&($.fatherPath=o)),$})),A})),w})),l},Vr=async(l,r,n={})=>{var y,f,v,m,u,x,E,B,w,V,A,N;let o=await I.getPageDataApi({platId:parseInt((y=Hr==null?void 0:Hr.value)==null?void 0:y.plat_id),pageName:l}),s=(f=o==null?void 0:o.data)==null?void 0:f.result;if((s==null?void 0:s.length)===0&&(n!=null&&n.originPath)&&(n==null?void 0:n.originPath)!==l){let Y=await I.getPageDataApi({platId:parseInt((v=Hr==null?void 0:Hr.value)==null?void 0:v.plat_id),pageName:n==null?void 0:n.originPath});if(((u=(m=Y==null?void 0:Y.data)==null?void 0:m.result)==null?void 0:u.length)>0){let b=await es((x=Y==null?void 0:Y.data)==null?void 0:x.result,n,!1);b=b==null?void 0:b.map(async k=>{var W,ce,Ee,Ie,De,ne,ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa;let _=[],U=(W=Object.keys(k))==null?void 0:W.filter(P=>P==null?void 0:P.includes("name"));for(let P in k)U!=null&&U.find(F=>F===P)&&_.push(k==null?void 0:k[P]);if(_=_.reverse(),(k==null?void 0:k.comp)==="Table"){let P=(Ie=(Ee=(ce=k==null?void 0:k.compData)==null?void 0:ce.find(J=>(J==null?void 0:J.key)==="tableContents"))==null?void 0:Ee.contents)==null?void 0:Ie.map(J=>{let ie={};for(let se in J)se!=="id"&&se!=="create_time"&&se!=="update_time"&&se!=="sort"&&se!=="create_user_id"&&se!=="update_user_id"&&se!=="department_id"&&se!=="relatedId"&&(ie[se]=J==null?void 0:J[se]);return J=Object.values(ie),J}),F=(ne=(De=k==null?void 0:k.compData)==null?void 0:De.find(J=>(J==null?void 0:J.key)==="header"))==null?void 0:ne.contents;if(Array.isArray(F==null?void 0:F[0])?(F[0].push({label:"排序",prop:"sort"}),F[0].push({label:"relatedId",prop:"relatedId",formType:"Upload"}),(ge=F[0])!=null&&ge.find(J=>(J==null?void 0:J.prop)==="disabled")&&(F[0]=(X=F[0])==null?void 0:X.filter(J=>(J==null?void 0:J.prop)!=="disabled"),F[0].unshift({label:"",prop:"disabled",sortable:!1}))):(F.push({label:"排序",prop:"sort"}),F.push({label:"relatedId",prop:"relatedId",formType:"Upload"}),F!=null&&F.find(J=>(J==null?void 0:J.prop)==="disabled")&&(F=F==null?void 0:F.filter(J=>(J==null?void 0:J.prop)!=="disabled"),F.unshift({label:"",prop:"disabled",sortable:!1}))),F!=null&&F.some(J=>{var ie;return(J==null?void 0:J.calculatorFilter)&&((ie=J==null?void 0:J.calculatorFilter)==null?void 0:ie.includes("Auto"))})&&(P=await ut(P,F,"Auto"),P=P==null?void 0:P.map(J=>Object.values(J))),k!=null&&k.fatherSyncContents){Array.isArray((de=k==null?void 0:k.fatherSyncContents)==null?void 0:de[0])&&(k.fatherSyncContents=(Ke=k==null?void 0:k.fatherSyncContents)==null?void 0:Ke[0]);let J=(Ta=wo.value)==null?void 0:Ta.find(ie=>(ie==null?void 0:ie.condition)==="child");k.fatherSyncContents=(oe=k==null?void 0:k.fatherSyncContents)==null?void 0:oe.map(ie=>{var se,ma,oa,Oe,_e,wa;return((ma=ie==null?void 0:ie.menus)==null?void 0:ma[((se=ie==null?void 0:ie.menus)==null?void 0:se.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"!==(ie==null?void 0:ie.menus)?ie.menus=(ie==null?void 0:ie.menus)+(J==null?void 0:J.value):((Oe=ie==null?void 0:ie.menus)==null?void 0:Oe[((oa=ie==null?void 0:ie.menus)==null?void 0:oa.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"===(ie==null?void 0:ie.menus)&&(ie.menus=(wa=ie.menus)==null?void 0:wa.slice(0,((_e=ie.menus)==null?void 0:_e.length)-1)),ie})}if(k!=null&&k.sonSyncContents){Array.isArray((S=k==null?void 0:k.sonSyncContents)==null?void 0:S[0])&&(k.sonSyncContents=(le=k==null?void 0:k.sonSyncContents)==null?void 0:le[0]);let J=(me=wo.value)==null?void 0:me.find(ie=>(ie==null?void 0:ie.condition)==="child");k.sonSyncContents=(ue=k==null?void 0:k.sonSyncContents)==null?void 0:ue.map(ie=>{var se,ma,oa,Oe,_e,wa;return((ma=ie==null?void 0:ie.menus)==null?void 0:ma[((se=ie==null?void 0:ie.menus)==null?void 0:se.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"!==(ie==null?void 0:ie.menus)?ie.menus=(ie==null?void 0:ie.menus)+(J==null?void 0:J.value):((Oe=ie==null?void 0:ie.menus)==null?void 0:Oe[((oa=ie==null?void 0:ie.menus)==null?void 0:oa.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"===(ie==null?void 0:ie.menus)&&(ie.menus=(wa=ie.menus)==null?void 0:wa.slice(0,((_e=ie.menus)==null?void 0:_e.length)-1)),ie})}if(k!=null&&k.relatedQuotes){Array.isArray((Ne=k==null?void 0:k.relatedQuotes)==null?void 0:Ne[0])&&(k.relatedQuotes=(pa=k==null?void 0:k.relatedQuotes)==null?void 0:pa[0]);let J=(_a=wo.value)==null?void 0:_a.find(ie=>(ie==null?void 0:ie.condition)==="child");k.relatedQuotes=(Wa=k==null?void 0:k.relatedQuotes)==null?void 0:Wa.map(ie=>{var se,ma,oa,Oe,_e,wa;return((ma=ie==null?void 0:ie.menus)==null?void 0:ma[((se=ie==null?void 0:ie.menus)==null?void 0:se.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"!==(ie==null?void 0:ie.menus)?ie.menus=(ie==null?void 0:ie.menus)+(J==null?void 0:J.value):((Oe=ie==null?void 0:ie.menus)==null?void 0:Oe[((oa=ie==null?void 0:ie.menus)==null?void 0:oa.length)-1])==="/"&&(J==null?void 0:J.parentContent)+"/"===(ie==null?void 0:ie.menus)&&(ie.menus=(wa=ie.menus)==null?void 0:wa.slice(0,((_e=ie.menus)==null?void 0:_e.length)-1)),ie})}k={filter:(la=(ee=k==null?void 0:k.compData)==null?void 0:ee.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:la.contents,key:k==null?void 0:k.comp,name:_,tableColumns:F,tableContents:P,menuFilter:k==null?void 0:k.menuFilter,fatherSyncContents:k==null?void 0:k.fatherSyncContents,relatedQuotes:k==null?void 0:k.relatedQuotes,sonSyncContents:k==null?void 0:k.sonSyncContents}}else{let P=(He=(ka=(Ve=k==null?void 0:k.compData)==null?void 0:Ve.find(J=>(J==null?void 0:J.key)==="formContent"))==null?void 0:ka.contents)==null?void 0:He.map(J=>(J==null?void 0:J.value)??"");P=[P];let F=(Ge=(Re=(Te=k==null?void 0:k.compData)==null?void 0:Te.find(J=>(J==null?void 0:J.key)==="formContent"))==null?void 0:Re.contents)==null?void 0:Ge.map(J=>(J.value="",J));k={contents:P,filter:(Fa=(Ga=k==null?void 0:k.compData)==null?void 0:Ga.find(J=>(J==null?void 0:J.key)==="filter"))==null?void 0:Fa.contents,key:k==null?void 0:k.comp,name:_,value:F,fatherSyncContents:k==null?void 0:k.fatherSyncContents,relatedQuotes:k==null?void 0:k.relatedQuotes,sonSyncContents:k==null?void 0:k.sonSyncContents}}return k.isShow=!1,k}),b=await Promise.all(b);let $=[{key:"menuPath",contents:[{path:l,fatherPath:(w=(B=(E=Y==null?void 0:Y.data)==null?void 0:E.result)==null?void 0:B[0])==null?void 0:w.father_name,isShow:!1}]},{key:l,contents:b}];await I.createPlatFormDataApi({platId:parseInt((V=Hr==null?void 0:Hr.value)==null?void 0:V.plat_id),changeData:$});let T=await I.getPageDataApi({platId:parseInt((A=Hr==null?void 0:Hr.value)==null?void 0:A.plat_id),pageName:l});s=(N=T==null?void 0:T.data)==null?void 0:N.result}}r&&await Xs(s,!!(n!=null&&n.originPath));let c=await es(s,n);return r&&(c=await kp(c)),c==null?void 0:c.filter(Y=>Y)},rs=async l=>{var o,s,c,y,f,v,m,u,x,E,B;let r=(o=l==null?void 0:l.menus)==null?void 0:o.join("/");l!=null&&l.endChildMenu&&(l==null?void 0:l.endChildMenu)!==""&&(r==null?void 0:r[(r==null?void 0:r.length)-1])==="/"&&(r=r+(l==null?void 0:l.endChildMenu)),(r==null?void 0:r[(r==null?void 0:r.length)-1])==="/"&&(r=r+((c=(s=l.value)==null?void 0:s.split(" "))==null?void 0:c[0]));let n=await Vr(r,!1);if(n=(y=n==null?void 0:n.filter(w=>{var V,A;return(w==null?void 0:w.name)===((A=l==null?void 0:l.groups)==null?void 0:A[((V=l==null?void 0:l.groups)==null?void 0:V.length)-1])}))==null?void 0:y[0],(v=(f=n==null?void 0:n.compData)==null?void 0:f.find(w=>(w==null?void 0:w.key)==="tableContents"))!=null&&v.contents){n=(u=(m=n==null?void 0:n.compData)==null?void 0:m.find(V=>(V==null?void 0:V.key)==="tableContents"))==null?void 0:u.contents;let w=((x=l==null?void 0:l.words)==null?void 0:x[0])??(l==null?void 0:l.prop);return n=n==null?void 0:n.filter(V=>{var A,N,Y,b;return(V==null?void 0:V[l!=null&&l.endChildMenu?w:(A=l==null?void 0:l.words)==null?void 0:A[0]])===(l!=null&&l.relatedWords&&((N=l==null?void 0:l.relatedWords)==null?void 0:N.length)>0?(b=(Y=l.value)==null?void 0:Y.split(" "))==null?void 0:b[0]:l.value)}),n==null?void 0:n[0]}else{let w=(B=(E=n==null?void 0:n.compData)==null?void 0:E.find(A=>(A==null?void 0:A.key)==="formContent"))==null?void 0:B.contents,V={};return w==null||w.forEach(A=>{V[A.prop]=A.value}),V}},xp={key:0,class:"extra-button-content"},_p={class:"table-operator-wrap"},wp={key:0,class:"extra-button-filter"},Cp={key:1,class:"extra-header"},Ep=["onClick"],Sp={class:"table-op-text"},Dp={class:"table-op-text"},Np={class:"drop-menu",style:{width:"120px"}},Bp=["onClick"],Tp={key:0},Ap={key:1},zp=["onClick"],Mp={class:"table-op-text"},Op={key:1,class:"extra-button-content tabs-button-wrapper"},Ip={class:"table-operator-wrap"},Lp={class:"extra-button-filter"},$p={key:0,class:"extra-header"},Rp={class:"table-op-action"},Vp={class:"table-op-text"},Pp={class:"drop-menu",style:{width:"120px"}},Fp={key:0},jp={key:1},Hp=["onClick"],Up={class:"table-op-text"},qp={__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(l,{emit:r}){const n=r,o=l,s=a.ref(""),c=a.ref(!1),y=a.ref([]),f=a.ref([{label:"清空",background:"#999999"},{label:"确认"}]),v=[{label:"新增",icon:"new"},{label:"导入",icon:"import_101"},{label:"导出",icon:"export_101"},{label:"导出paraform",icon:"export_101"},{label:"OCR识别",icon:"OCR识别"},{label:"切换视图",icon:"cardViewport_101"}];function m(k,_){return k.map(U=>{const W={...U};return _.forEach(ce=>{delete W[ce]}),W})}function u(k){if(!k||k.t!=="n")return(k==null?void 0:k.v)??"";const _=k.v;if(k.z){const U=String(k.z).toLowerCase(),W=["yyyy/mm/dd","yyyy-mm-dd","yyyy.mm.dd","yy/mm/dd","yy-mm-dd","yy.mm.dd","mm/dd/yy","mm-dd-yy","mm.dd.yy","dd/mm/yy","dd-mm-yy","dd.mm.yy","m/d/yy","m/d/yyyy","d/m/yy","d/m/yyyy","yyyy年","yy年","m月","d日","yyyy年m月d日","yy年m月d日","[$-f800]","[$-f400]"];for(const Ie of W)if(U.includes(Ie))return x(_);const ce=/[ymdhms]/.test(U),Ee=/^[0#\.\,\s]+$/.test(U.replace(/[\\\/\-:]/g,""));if(ce&&!Ee)return x(_)}if(_>=1&&_<=73050){if(_<5e3)return _;if(_>=5e3&&_<4e4){const U=Math.floor((_-25569)/365.25)+1970;return U>=1970&&U<=2e3&&k.z&&/[ymd]/.test(String(k.z).toLowerCase())?x(_):_}if(_>=4e4)return x(_)}return _}function x(k){if(typeof k!="number")return k;try{const _=new Date((k-25569)*86400*1e3);if(isNaN(_.getTime()))return k;const U=_.getFullYear(),W=String(_.getMonth()+1).padStart(2,"0"),ce=String(_.getDate()).padStart(2,"0");return`${U}-${W}-${ce}`}catch{return k}}const E=k=>{const _=k.raw;if(!_)return;const U=new FileReader;U.onload=W=>{try{const ce=new Uint8Array(W.target.result),Ee=ca.readSync(ce,{type:"array"}),Ie=Ee.SheetNames[0],De=Ee.Sheets[Ie],ge=ca.utils.decode_range(De["!ref"]).e.c+1,X=new Array(ge).fill(""),de=[];for(const le in De){if(le[0]==="!")continue;const{r:me,c:ue}=ca.utils.decode_cell(le),Ne=De[le];let pa=u(Ne);if((pa==null||pa==="")&&(pa=""),me===0)X[ue]=pa;else{if(!de[me-1]){de[me-1]={};for(let _a=0;_a<ge;_a++)de[me-1][`col_${_a}`]=""}de[me-1][`col_${ue}`]=pa}}for(let le=0;le<ge;le++)X[le]===void 0&&(X[le]="");const Ke=[];for(let le=0;le<X.length;le++)(!X[le]||X[le].toString().trim()==="")&&Ke.push(le);let Ta,oe;(Ke==null?void 0:Ke.length)>0?(rl.ElMessage.warning("存在键为空的列,已自动过滤,请检查补充"),Ta=X.filter((le,me)=>!Ke.includes(me)),oe=m(de,Ke==null?void 0:Ke.map(le=>`col_${le}`))):(Ta=X,oe=de);const S=de==null?void 0:de[0];if(!(S!=null&&S.hasOwnProperty("col_0")))return rl.ElMessage.error("导入的数据列不匹配,请检查是否错位");n("getImportData",Ta,oe)}catch(ce){throw rl.ElMessage.error(ce.message),new Error(ce.message)}},U.readAsArrayBuffer(_)},B=k=>{var U;const _=(U=y.value)==null?void 0:U.reduce((W,ce,Ee)=>(Ee===0?W[ce.label]=k:W[ce.label]=ce==null?void 0:ce.value,W),{});n("filter",_,k,!0)},w=(k,_={})=>{n("buttonClick",k,"",_)},V=k=>{var _,U;y.value=(U=(_=ca.getColumnChild(I.cloneDeep(k)))==null?void 0:_.filter(W=>(W==null?void 0:W.label)!==""&&(W==null?void 0:W.label)!=="操作"))==null?void 0:U.map(W=>({label:(W==null?void 0:W.label)??"",value:"",name:(W==null?void 0:W.prop)??"",isFormColHidden:W==null?void 0:W.isTableColHidden,width:2,prop:(W==null?void 0:W.prop)??""}))},A=a.ref(!1),N=k=>{var _;if((k==null?void 0:k.buttonName)==="确认"&&(n("filter",k==null?void 0:k.content),A.value=(k==null?void 0:k.content)&&Object.values(k==null?void 0:k.content).length>0),(k==null?void 0:k.buttonName)==="清空"){const U=I.cloneDeep(k==null?void 0:k.content);for(const W in U)U[W]="";y.value=(_=y.value)==null?void 0:_.map(W=>({...W,value:""})),n("filter",U),A.value=!1}c.value=!1},Y=()=>{c.value=!c.value},b=()=>{var _,U;y.value=(_=y.value)==null?void 0:_.map(W=>({...W,value:""}));const k=(U=y.value)==null?void 0:U.reduce((W,ce)=>(W[ce.label]=ce.value,W),{});n("filter",k)},$=a.ref(null);let T;return T=k=>{var ce;if(!c.value)return;const _=(ce=$==null?void 0:$.value)==null?void 0:ce.$el,U=_==null?void 0:_.contains(k.target);let W=!1;document.querySelectorAll(".el-popover, .el-popper").forEach(Ee=>{Ee.contains(k.target)&&(W=!0)}),!U&&!W&&(c.value=!1)},a.onMounted(()=>{document.addEventListener("click",T),V(o.columns)}),a.onBeforeUnmount(()=>{document.removeEventListener("click",T)}),a.watch(()=>o.columns,()=>{V(o.columns)},{deep:!0,immediate:!0}),(k,_)=>{var De,ne,ge,X,de,Ke,Ta,oe;const U=a.resolveComponent("el-icon"),W=a.resolveComponent("svg-icon"),ce=a.resolveComponent("el-input"),Ee=a.resolveComponent("el-upload"),Ie=a.resolveComponent("el-button");return l.pageLayout==="vertical"?(a.openBlock(),a.createElementBlock("div",xp,[a.createElementVNode("div",{class:a.normalizeClass(l.compName?"table-name-wrap":""),style:a.normalizeStyle({background:(o==null?void 0:o.level)>1?"transparent":"var(--ssgroup-background)",paddingLeft:((o==null?void 0:o.level)-1)*12+"px",fontWeight:600-((o==null?void 0:o.level)-1)*100>=400?600-((o==null?void 0:o.level)-1)*100:400,fontSize:17-(o==null?void 0:o.level)>=14?17-(o==null?void 0:o.level)+"px":"14px"})},a.toDisplayString(l.compName),7),a.createElementVNode("div",_p,[o!=null&&o.filterShow?(a.openBlock(),a.createElementBlock("div",wp,[a.createVNode(Cu,{trigger:"contextmenu",ref_key:"popOverRef",ref:$,title:"",width:800,placement:"bottom-start",isVisible:c.value,"onUpdate:isVisible":_[4]||(_[4]=S=>c.value=S)},{reference:a.withCtx(()=>{var S,le,me,ue;return[a.createVNode(ce,{modelValue:s.value,"onUpdate:modelValue":_[0]||(_[0]=Ne=>s.value=Ne),style:{"min-width":"80px"},placeholder:A.value?(me=(le=(S=l.filterValues)==null?void 0:S.filter(Ne=>Ne))==null?void 0:le.slice(0,3))==null?void 0:me.join("/"):"搜索","prefix-icon":a.unref(rl.search_default),clearable:"",onInput:B,disabled:((ue=y.value)==null?void 0:ue.length)===0},{suffix:a.withCtx(()=>{var Ne,pa;return[!s.value&&((pa=(Ne=l.filterValues)==null?void 0:Ne.filter(_a=>_a))!=null&&pa.join("/"))?(a.openBlock(),a.createBlock(U,{key:0,style:{cursor:"pointer"},onClick:b},{default:a.withCtx(()=>[a.createVNode(a.unref(rl.circle_close_default))]),_:1})):a.createCommentVNode("",!0)]}),append:a.withCtx(()=>[a.createElementVNode("span",{title:"条件查询",onClick:a.withModifiers(Y,["stop"])},[a.createVNode(W,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]}),content:a.withCtx(()=>[a.createElementVNode("div",{class:"form-content-value",onKeydown:_[1]||(_[1]=a.withModifiers(()=>{},["stop"])),onKeyup:_[2]||(_[2]=a.withModifiers(()=>{},["stop"])),onKeypress:_[3]||(_[3]=a.withModifiers(()=>{},["stop"]))},[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:y.value,buttonValue:f.value,isRowFlex:!0,isEnableWrap:!1,isButtonRow:!1,key:f.value,isStartJustify:!1,onOnButtonClick:N},null,8,["rowContents","buttonValue"]))],32)]),_:1},8,["isVisible"])])):a.createCommentVNode("",!0),l.buttons&&((De=l.buttons)==null?void 0:De.length)>0?(a.openBlock(),a.createElementBlock("div",Cp,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList((ne=l.buttons)==null?void 0:ne.filter(S=>l.isDevMode||(S==null?void 0:S.label)!=="修改模板"),(S,le)=>{var me;return a.openBlock(),a.createElementBlock("div",{class:"extra-contents",key:le},[(S==null?void 0:S.type)==="upload"?(a.openBlock(),a.createBlock(Ee,{key:0,class:"upload-button-wrap","on-change":E,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1,disabled:!!l.lockingPage},{default:a.withCtx(()=>{var ue;return[a.createElementVNode("div",{class:a.normalizeClass(["table-op-action",{"is-disabled":!!l.lockingPage}]),onClick:Ne=>w(S==null?void 0:S.label)},[a.createVNode(W,{class:"table-op-icon",name:(ue=v==null?void 0:v.find(Ne=>(Ne==null?void 0:Ne.label)===(S==null?void 0:S.label)))==null?void 0:ue.icon},null,8,["name"]),a.createElementVNode("span",Sp,a.toDisplayString(S==null?void 0:S.label),1)],10,Ep)]}),_:2},1032,["disabled"])):a.createCommentVNode("",!0),(S==null?void 0:S.type)==="popover"?(a.openBlock(),a.createBlock(pl._sfc_main,{key:1},{dropTitle:a.withCtx(()=>{var ue;return[a.createElementVNode("div",{class:a.normalizeClass(["table-op-action",{"is-disabled":!!l.lockingPage}])},[a.createVNode(W,{class:"table-op-icon",name:(ue=v==null?void 0:v.find(Ne=>(Ne==null?void 0:Ne.label)===(S==null?void 0:S.label)))==null?void 0:ue.icon},null,8,["name"]),a.createElementVNode("span",Dp,a.toDisplayString(S==null?void 0:S.label),1)],2)]}),dropMenu:a.withCtx(()=>[a.createElementVNode("div",Np,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(S==null?void 0:S.contents,ue=>{var Ne,pa;return a.openBlock(),a.createElementBlock("div",{key:ue==null?void 0:ue.label,class:a.normalizeClass(["table-op-drop-item",{"is-disabled":!!l.lockingPage}]),onClick:_a=>!l.lockingPage&&w(ue==null?void 0:ue.label)},[a.createTextVNode(a.toDisplayString(ue==null?void 0:ue.label),1),(Ne=ue==null?void 0:ue.label)!=null&&Ne.includes("选中")?(a.openBlock(),a.createElementBlock("span",Tp,"("+a.toDisplayString(l.selectNums)+")",1)):a.createCommentVNode("",!0),(pa=ue==null?void 0:ue.label)!=null&&pa.includes("全部")?(a.openBlock(),a.createElementBlock("span",Ap,"("+a.toDisplayString(l.dataNums)+")",1)):a.createCommentVNode("",!0)],10,Bp)}),128))])]),_:2},1024)):a.createCommentVNode("",!0),!(S!=null&&S.type)||(S==null?void 0:S.type)==="methodButton"?(a.openBlock(),a.createElementBlock("div",{key:2,id:"themeButton",class:a.normalizeClass(["table-op-action",{"is-disabled":!!l.lockingPage}]),onClick:ue=>!l.lockingPage&&w(S==null?void 0:S.label,S)},[a.createVNode(W,{class:"table-op-icon",name:(me=v==null?void 0:v.find(ue=>(ue==null?void 0:ue.label)===(S==null?void 0:S.label)))==null?void 0:me.icon},null,8,["name"]),a.createElementVNode("span",Mp,a.toDisplayString(S==null?void 0:S.label),1)],10,zp)):a.createCommentVNode("",!0)])}),128))])):a.createCommentVNode("",!0)])])):(a.openBlock(),a.createElementBlock("div",Op,[a.createElementVNode("div",Ip,[a.createElementVNode("div",Lp,[a.createVNode(ce,{modelValue:s.value,"onUpdate:modelValue":_[5]||(_[5]=S=>s.value=S),style:{"min-width":"80px"},placeholder:A.value?(de=(X=(ge=l.filterValues)==null?void 0:ge.filter(S=>S))==null?void 0:X.slice(0,3))==null?void 0:de.join("/"):"搜索","prefix-icon":a.unref(rl.search_default),clearable:"",onInput:B,disabled:((Ke=y.value)==null?void 0:Ke.length)===0},{suffix:a.withCtx(()=>{var S,le;return[!s.value&&((le=(S=l.filterValues)==null?void 0:S.filter(me=>me))!=null&&le.join("/"))?(a.openBlock(),a.createBlock(U,{key:0,style:{cursor:"pointer"},onClick:b},{default:a.withCtx(()=>[a.createVNode(a.unref(rl.circle_close_default))]),_:1})):a.createCommentVNode("",!0)]}),append:a.withCtx(()=>[a.createElementVNode("span",{title:"条件查询",onClick:a.withModifiers(Y,["stop"])},[a.createVNode(W,{name:"query",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),_:1},8,["modelValue","placeholder","prefix-icon","disabled"])]),l.buttons&&((Ta=l.buttons)==null?void 0:Ta.length)>0?(a.openBlock(),a.createElementBlock("div",$p,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList((oe=l.buttons)==null?void 0:oe.filter(S=>l.isDevMode||(S==null?void 0:S.label)!=="修改模板"),(S,le)=>{var me;return a.openBlock(),a.createElementBlock("div",{class:"extra-contents",key:le},[(S==null?void 0:S.type)==="upload"?(a.openBlock(),a.createBlock(Ee,{key:0,class:"upload-button-wrap","on-change":E,accept:".xlsx,.xls","auto-upload":!1,action:"#","show-file-list":!1},{default:a.withCtx(()=>{var ue;return[a.createElementVNode("div",Rp,[a.createVNode(W,{class:"table-op-icon",name:(ue=v==null?void 0:v.find(Ne=>(Ne==null?void 0:Ne.label)===(S==null?void 0:S.label)))==null?void 0:ue.icon},null,8,["name"]),a.createElementVNode("span",Vp,a.toDisplayString(S==null?void 0:S.label),1)])]}),_:2},1024)):a.createCommentVNode("",!0),(S==null?void 0:S.type)==="popover"?(a.openBlock(),a.createBlock(pl._sfc_main,{key:1},{dropTitle:a.withCtx(()=>[(S==null?void 0:S.type)==="popover"?(a.openBlock(),a.createBlock(Ie,{key:0,style:{background:"transparent",color:"#000000"}},{icon:a.withCtx(()=>{var ue;return[a.createVNode(W,{class:"table-op-icon",name:(ue=v==null?void 0:v.find(Ne=>(Ne==null?void 0:Ne.label)===(S==null?void 0:S.label)))==null?void 0:ue.icon},null,8,["name"])]}),default:a.withCtx(()=>[a.createTextVNode(" "+a.toDisplayString(S==null?void 0:S.label),1)]),_:2},1024)):a.createCommentVNode("",!0)]),dropMenu:a.withCtx(()=>[a.createElementVNode("div",Pp,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(S==null?void 0:S.contents,ue=>(a.openBlock(),a.createBlock(Ie,{key:ue==null?void 0:ue.label,style:{width:"100%",margin:"0",border:"none",display:"flex","justify-content":"flex-start"},onClick:Ne=>w(ue==null?void 0:ue.label)},{default:a.withCtx(()=>{var Ne,pa;return[a.createTextVNode(a.toDisplayString(ue==null?void 0:ue.label),1),(Ne=ue==null?void 0:ue.label)!=null&&Ne.includes("选中")?(a.openBlock(),a.createElementBlock("span",Fp,"("+a.toDisplayString(l.selectNums)+")",1)):a.createCommentVNode("",!0),(pa=ue==null?void 0:ue.label)!=null&&pa.includes("全部")?(a.openBlock(),a.createElementBlock("span",jp,"("+a.toDisplayString(l.dataNums)+")",1)):a.createCommentVNode("",!0)]}),_:2},1032,["onClick"]))),128))])]),_:2},1024)):a.createCommentVNode("",!0),!(S!=null&&S.type)||(S==null?void 0:S.type)==="methodButton"?(a.openBlock(),a.createElementBlock("div",{key:2,class:a.normalizeClass(["table-op-action",{"is-disabled":!!l.lockingPage}]),id:"themeButton",onClick:ue=>!l.lockingPage&&w(S==null?void 0:S.label,S)},[a.createVNode(W,{class:"table-op-icon",name:(me=v==null?void 0:v.find(ue=>(ue==null?void 0:ue.label)===(S==null?void 0:S.label)))==null?void 0:me.icon},null,8,["name"]),a.createElementVNode("span",Up,a.toDisplayString(S==null?void 0:S.label),1)],10,Hp)):a.createCommentVNode("",!0)])}),128))])):a.createCommentVNode("",!0)])]))}}},Wp=ql._export_sfc(qp,[["__scopeId","data-v-3a44c010"]]),Kp={__name:"index",props:{columns:Array,tableData:Array},setup(l){return(r,n)=>{const o=a.resolveComponent("el-table-column"),s=a.resolveComponent("el-table");return a.openBlock(),a.createBlock(s,{data:l.tableData,style:{width:"100%"},stripe:"","max-height":"500"},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(l.columns,c=>{var y;return a.openBlock(),a.createBlock(o,{key:c==null?void 0:c.prop,label:c==null?void 0:c.label,prop:c==null?void 0:c.prop,fixed:(c==null?void 0:c.prop)==="operate"?"right":c==null?void 0:c.fixed,align:(c==null?void 0:c.align)??"left","show-overflow-tooltip":(c==null?void 0:c.showOverflowTooltip)??!0,width:c==null?void 0:c.width,"min-width":(c==null?void 0:c.minWidth)||((c==null?void 0:c.prop)==="operate"?80:(((y=c==null?void 0:c.label)==null?void 0:y.length)*2||4)*27)},{default:a.withCtx(f=>[a.renderSlot(r.$slots,"content",{row:f.row,column:f.column,$index:f.$index,scope:f}),(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(c.children,(v,m)=>(a.openBlock(),a.createBlock(pl._sfc_main$2,{key:m,column:v,tableData:l.tableData},a.createSlots({_:2},[a.renderList(r.$slots,(u,x)=>({name:x,fn:a.withCtx(({row:E,slotData:B,item:w,column:V})=>[a.renderSlot(r.$slots,x,a.mergeProps({ref_for:!0},B??E,{item:w??v,slotData:B??E,row:E,column:V,columnProp:v}))])}))]),1032,["column","tableData"]))),128))]),_:2},1032,["label","prop","fixed","align","show-overflow-tooltip","width","min-width"])}),128))]),_:3},8,["data"])}}};class Yp extends Pa.Loader{constructor(r){super(r),this.littleEndian=!0}load(r,n,o,s){const c=this,y=new Pa.FileLoader(c.manager);y.setPath(c.path),y.setResponseType("arraybuffer"),y.setRequestHeader(c.requestHeader),y.setWithCredentials(c.withCredentials),y.load(r,function(f){try{n(c.parse(f))}catch(v){s?s(v):console.error(v),c.manager.itemError(r)}},o,s)}_getDataView(r,n,o,s){switch(o){case"F":return s===8?r.getFloat64(n,this.littleEndian):r.getFloat32(n,this.littleEndian);case"I":return s===1?r.getInt8(n):s===2?r.getInt16(n,this.littleEndian):r.getInt32(n,this.littleEndian);case"U":return s===1?r.getUint8(n):s===2?r.getUint16(n,this.littleEndian):r.getUint32(n,this.littleEndian)}}parse(r){function n(B,w){const V=B.length,A=new Uint8Array(w);let N=0,Y=0,b,$,T;do if(b=B[N++],b<32){if(b++,Y+b>w)throw new Error("Output buffer is not large enough");if(N+b>V)throw new Error("Invalid compressed data");do A[Y++]=B[N++];while(--b)}else{if($=b>>5,T=Y-((b&31)<<8)-1,N>=V)throw new Error("Invalid compressed data");if($===7&&($+=B[N++],N>=V))throw new Error("Invalid compressed data");if(T-=B[N++],Y+$+2>w)throw new Error("Output buffer is not large enough");if(T<0)throw new Error("Invalid compressed data");if(T>=Y)throw new Error("Invalid compressed data");do A[Y++]=A[T++];while(--$+2)}while(N<V);return A}function o(B){const w={},V=new Uint8Array(B);let A="",N="",Y=0,b=!1;const $=V.length;for(;Y<$&&b===!1;){const U=String.fromCharCode(V[Y++]);U===`
2
- `||U==="\r"?(N.trim().toLowerCase().startsWith("data")&&(b=!0),N=""):N+=U,A+=U}const T=A.search(/[\r\n]DATA\s(\S*)\s/i),k=/[\r\n]DATA\s(\S*)\s/i.exec(A.slice(T-1));if(w.data=k[1],w.headerLen=k[0].length+T,w.str=A.slice(0,w.headerLen),w.str=w.str.replace(/#.*/gi,""),w.version=/^VERSION (.*)/im.exec(w.str),w.fields=/^FIELDS (.*)/im.exec(w.str),w.size=/^SIZE (.*)/im.exec(w.str),w.type=/^TYPE (.*)/im.exec(w.str),w.count=/^COUNT (.*)/im.exec(w.str),w.width=/^WIDTH (.*)/im.exec(w.str),w.height=/^HEIGHT (.*)/im.exec(w.str),w.viewpoint=/^VIEWPOINT (.*)/im.exec(w.str),w.points=/^POINTS (.*)/im.exec(w.str),w.version!==null&&(w.version=parseFloat(w.version[1])),w.fields=w.fields!==null?w.fields[1].split(" "):[],w.type!==null&&(w.type=w.type[1].split(" ")),w.width!==null&&(w.width=parseInt(w.width[1])),w.height!==null&&(w.height=parseInt(w.height[1])),w.viewpoint!==null&&(w.viewpoint=w.viewpoint[1]),w.points!==null&&(w.points=parseInt(w.points[1],10)),w.points===null&&(w.points=w.width*w.height),w.size!==null&&(w.size=w.size[1].split(" ").map(function(U){return parseInt(U,10)})),w.count!==null)w.count=w.count[1].split(" ").map(function(U){return parseInt(U,10)});else{w.count=[];for(let U=0,W=w.fields.length;U<W;U++)w.count.push(1)}w.offset={};let _=0;for(let U=0,W=w.fields.length;U<W;U++)w.data==="ascii"?w.offset[w.fields[U]]=U:(w.offset[w.fields[U]]=_,_+=w.size[U]*w.count[U]);return w.rowSize=_,w}const s=o(r),c=[],y=[],f=[],v=[],m=[],u=new Pa.Color;if(s.data==="ascii"){const B=s.offset,A=new TextDecoder().decode(r).slice(s.headerLen).split(`
3
- `);for(let N=0,Y=A.length;N<Y;N++){if(A[N]==="")continue;const b=A[N].split(" ");if(B.x!==void 0&&(c.push(parseFloat(b[B.x])),c.push(parseFloat(b[B.y])),c.push(parseFloat(b[B.z]))),B.rgb!==void 0){const $=s.fields.findIndex(Ee=>Ee==="rgb"),T=s.type[$],k=parseFloat(b[B.rgb]);let _=k;if(T==="F"){const Ee=new Float32Array(1);Ee[0]=k,_=new Int32Array(Ee.buffer)[0]}const U=(_>>16&255)/255,W=(_>>8&255)/255,ce=(_>>0&255)/255;u.setRGB(U,W,ce,Pa.SRGBColorSpace),f.push(u.r,u.g,u.b)}B.normal_x!==void 0&&(y.push(parseFloat(b[B.normal_x])),y.push(parseFloat(b[B.normal_y])),y.push(parseFloat(b[B.normal_z]))),B.intensity!==void 0&&v.push(parseFloat(b[B.intensity])),B.label!==void 0&&m.push(parseInt(b[B.label]))}}if(s.data==="binary_compressed"){const B=new Uint32Array(r.slice(s.headerLen,s.headerLen+8)),w=B[0],V=B[1],A=n(new Uint8Array(r,s.headerLen+8,w),V),N=new DataView(A.buffer),Y=s.offset;for(let b=0;b<s.points;b++){if(Y.x!==void 0){const $=s.fields.indexOf("x"),T=s.fields.indexOf("y"),k=s.fields.indexOf("z");c.push(this._getDataView(N,s.points*Y.x+s.size[$]*b,s.type[$],s.size[$])),c.push(this._getDataView(N,s.points*Y.y+s.size[T]*b,s.type[T],s.size[T])),c.push(this._getDataView(N,s.points*Y.z+s.size[k]*b,s.type[k],s.size[k]))}if(Y.rgb!==void 0){const $=s.fields.indexOf("rgb"),T=N.getUint8(s.points*Y.rgb+s.size[$]*b+2)/255,k=N.getUint8(s.points*Y.rgb+s.size[$]*b+1)/255,_=N.getUint8(s.points*Y.rgb+s.size[$]*b+0)/255;u.setRGB(T,k,_,Pa.SRGBColorSpace),f.push(u.r,u.g,u.b)}if(Y.normal_x!==void 0){const $=s.fields.indexOf("normal_x"),T=s.fields.indexOf("normal_y"),k=s.fields.indexOf("normal_z");y.push(this._getDataView(N,s.points*Y.normal_x+s.size[$]*b,s.type[$],s.size[$])),y.push(this._getDataView(N,s.points*Y.normal_y+s.size[T]*b,s.type[T],s.size[T])),y.push(this._getDataView(N,s.points*Y.normal_z+s.size[k]*b,s.type[k],s.size[k]))}if(Y.intensity!==void 0){const $=s.fields.indexOf("intensity");v.push(this._getDataView(N,s.points*Y.intensity+s.size[$]*b,s.type[$],s.size[$]))}if(Y.label!==void 0){const $=s.fields.indexOf("label");m.push(N.getInt32(s.points*Y.label+s.size[$]*b,this.littleEndian))}}}if(s.data==="binary"){const B=new DataView(r,s.headerLen),w=s.offset;for(let V=0,A=0;V<s.points;V++,A+=s.rowSize){if(w.x!==void 0){const N=s.fields.indexOf("x"),Y=s.fields.indexOf("y"),b=s.fields.indexOf("z");c.push(this._getDataView(B,A+w.x,s.type[N],s.size[N])),c.push(this._getDataView(B,A+w.y,s.type[Y],s.size[Y])),c.push(this._getDataView(B,A+w.z,s.type[b],s.size[b]))}if(w.rgb!==void 0){const N=B.getUint8(A+w.rgb+2)/255,Y=B.getUint8(A+w.rgb+1)/255,b=B.getUint8(A+w.rgb+0)/255;u.setRGB(N,Y,b,Pa.SRGBColorSpace),f.push(u.r,u.g,u.b)}if(w.normal_x!==void 0){const N=s.fields.indexOf("normal_x"),Y=s.fields.indexOf("normal_y"),b=s.fields.indexOf("normal_z");y.push(this._getDataView(B,A+w.normal_x,s.type[N],s.size[N])),y.push(this._getDataView(B,A+w.normal_y,s.type[Y],s.size[Y])),y.push(this._getDataView(B,A+w.normal_z,s.type[b],s.size[b]))}if(w.intensity!==void 0){const N=s.fields.indexOf("intensity");v.push(this._getDataView(B,A+w.intensity,s.type[N],s.size[N]))}w.label!==void 0&&m.push(B.getInt32(A+w.label,this.littleEndian))}}const x=new Pa.BufferGeometry;c.length>0&&x.setAttribute("position",new Pa.Float32BufferAttribute(c,3)),y.length>0&&x.setAttribute("normal",new Pa.Float32BufferAttribute(y,3)),f.length>0&&x.setAttribute("color",new Pa.Float32BufferAttribute(f,3)),v.length>0&&x.setAttribute("intensity",new Pa.Float32BufferAttribute(v,1)),m.length>0&&x.setAttribute("label",new Pa.Int32BufferAttribute(m,1)),x.computeBoundingSphere();const E=new Pa.PointsMaterial({size:.005});return f.length>0&&(E.vertexColors=!0),new Pa.Points(x,E)}}const Gp=I.useModelComp(I.pinia),{systemPath:ns}=I.storeToRefs(Gp),ui=a.ref(),os=new WeakMap;function Jp(l,r,n,o,s){const c=async E=>{try{const B=await I.platformDownloadFile({url:E});if(B.status!==200)throw new Error(`下载失败: ${B.status}`);return B.data}catch(B){throw console.error("addModelFromUrl失败:",B),B}},y=E=>new Promise((B,w)=>{const V=new FileReader;V.onload=A=>{try{const N=A.target.result,b=new An.MTLLoader().parse(N);b.preload(),B(b)}catch(N){w(N)}},V.onerror=()=>{w(new Error("MTL文件读取失败"))},V.readAsText(E)}),f=async E=>{const B={materials:{},create:function(w){return this.materials[w]?this.materials[w]:(console.warn(`Material '${w}' not found, using default material`),new Pa.MeshPhongMaterial({color:8947848,side:Pa.DoubleSide}))},getAsArray:function(){const w=[];for(const V in this.materials)w.push(this.materials[V]);return w},preload:function(){for(const w in this.materials)this.materials[w].map&&(this.materials[w].map.needsUpdate=!0)}};for(const w of E){const V=await y(w);Object.assign(B.materials,V.materials)}return B.preload(),B},v=async(E,B=[])=>new Promise((w,V)=>{const A=new FileReader;A.onload=async N=>{try{const Y=N.target.result;let b=null;B&&B.length>0&&(B.length===1?b=await y(B[0]):b=await f(B));const $=new An.OBJLoader;b&&$.setMaterials(b);const T=$.parse(Y);b||T.traverse(k=>{k.isMesh&&(k.material=new Pa.MeshPhongMaterial({color:8947848,side:Pa.DoubleSide}))}),w(T)}catch(Y){V(Y)}},A.onerror=()=>{V(new Error("OBJ文件读取失败"))},A.readAsText(E)}),m=async E=>{var B;try{n.value=!0;const{scene:w}=l();if(!w)throw new Error("Scene not initialized");s();const V=[];for(let A=0;A<E.length;A++){const N=E[A];o.value=`正在加载模型 ${A+1}/${E.length}...`;const Y=await c(N.objUrl),b=((B=N.objUrl)==null?void 0:B.split("/").pop())||`model_${A}.obj`,$=new File([Y],b,{type:Y.type});let T=[];if(N.mtlUrls){const _=Array.isArray(N.mtlUrls)?N.mtlUrls:[N.mtlUrls];for(let U=0;U<_.length;U++){const W=_[U],ce=await c(W),Ee=(W==null?void 0:W.split("/").pop())||`material_${A}_${U}.mtl`,Ie=new File([ce],Ee,{type:ce.type});T.push(Ie)}}const k=await v($,T);w.add(k),r.value.push(k),V.push(k)}return n.value=!1,V}catch(w){throw console.error("加载模型失败:",w),n.value=!1,w}},u=async(E,B,w=[],V=[])=>{let A;const N=E.toLowerCase();switch(N){case".txt":case".cpt":case".obj":const Y=await B.text();if(N===".txt"||N===".cpt"){const ee=/^(?!.*\bf\b)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?(-?\d*\.?\d+)[^\n]*?$/gm,Ve=[...Y.matchAll(ee)].map(Te=>({x:parseFloat(Te[1]),y:parseFloat(Te[2]),z:parseFloat(Te[3])})),ka=new Pa.BufferGeometry,He=Ve.flatMap(Te=>[Te.x,Te.y,Te.z]);if(ka.setAttribute("position",new Pa.Float32BufferAttribute(He,3)),N===".txt"){const Te=new Pa.PointsMaterial({color:"#5B5C99",size:1,sizeAttenuation:!1});A=new Pa.Points(ka,Te)}else if(N===".cpt"){const Te=new Pa.LineBasicMaterial({color:"#5B5C99",linewidth:100});A=new Pa.Line(ka,Te)}}else if(N===".obj"){const ee=new An.OBJLoader;if(w&&w.length>0){const la=new An.MTLLoader;for(const Ve of w){const ka=await Ve.text(),He=la.parse(ka);He.preload(),ee.setMaterials(He);break}}A=ee.parse(Y),(!w||w.length===0)&&A.traverse(la=>{la.isMesh&&(la.material=new Pa.MeshPhongMaterial({color:"#B3B3D4"})),la instanceof Pa.Mesh&&(la.material.side=Pa.DoubleSide)})}break;case".stl":const b=await B.arrayBuffer(),T=new An.STLLoader().parse(b),k=new Pa.MeshPhongMaterial({color:"#B3B3D4",side:Pa.DoubleSide});A=new Pa.Mesh(T,k);break;case".nc":const _=["Mach_B_Axis_0.STL","Mach_C_Axis_0.STL","Mach_X_Axis_0.STL","Mach_Y_Axis_0.STL","Mach_Z_Axis_0.STL","Mach_Spindle_0.STL"],U={"Mach_Y_Axis_0.STL":"rgb(128,118,152)","Mach_B_Axis_0.STL":"rgb(204,143,89)","Mach_C_Axis_0.STL":"rgb(145,245,251)","Mach_X_Axis_0.STL":"rgb(125,158,192)","Mach_Z_Axis_0.STL":"rgb(248,228,118)","Mach_Spindle_0.STL":"rgb(145,145,145)"},W=new Pa.Group,ce=_.map(ee=>new Promise((la,Ve)=>{new An.STLLoader().load(ns.value===""?`/model/${ee}`:`${ns.value}\\${ee}`,He=>{const Te=new Pa.MeshPhongMaterial({color:U[ee]||"#B3B3D4",side:Pa.DoubleSide}),Re=new Pa.Mesh(He,Te);la(Re)},void 0,Ve)}));try{(await Promise.all(ce)).forEach(la=>W.add(la)),A=W}catch(ee){throw console.error("加载NC文件对应的STL文件失败:",ee),new Error("无法加载.NC文件对应的STL文件")}break;case".pcd":const Ee=new Yp,Ie=new Pa.Group;try{const ee=await rl.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/target.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),la=new Blob([ee.data],{type:"application/octet-stream;charset=UTF-8"}),Ve=await rl.axios.get("http://139.196.154.85:20026/chfs/shared/重大专项/重大专项文件/final.pcd",{responseType:"blob",headers:{"Content-Type":"application/json"}}),ka=new Blob([Ve.data],{type:"application/octet-stream;charset=UTF-8"}),He=await new Promise((Re,Ge)=>{const Ga=URL.createObjectURL(la);Ee.load(Ga,Fa=>{const P=new Float32Array(Fa.geometry.attributes.position.count*3);for(let F=0;F<Fa.geometry.attributes.position.count;F++)P[F*3]=1,P[F*3+1]=0,P[F*3+2]=0;Fa.geometry.setAttribute("color",new Pa.BufferAttribute(P,3)),Fa.material.vertexColors=!0,Fa.scale.set(.3,.3,.3),URL.revokeObjectURL(Ga),Re(Fa)},void 0,Ge)}),Te=await new Promise((Re,Ge)=>{const Ga=URL.createObjectURL(ka);Ee.load(Ga,Fa=>{const P=new Float32Array(Fa.geometry.attributes.position.count*3);for(let F=0;F<Fa.geometry.attributes.position.count;F++)P[F*3]=0,P[F*3+1]=1,P[F*3+2]=0;Fa.geometry.setAttribute("color",new Pa.BufferAttribute(P,3)),Fa.material.vertexColors=!0,Fa.scale.set(.3,.3,.3),URL.revokeObjectURL(Ga),Re(Fa)},void 0,Ge)});Ie.add(He),Ie.add(Te),A=Ie}catch(ee){throw console.error("PCD文件加载失败:",ee),new Error("无法加载PCD文件")}break;case".urdf":const De=URL.createObjectURL(B),ne=new ku.URDFLoader,ge="http://139.196.154.85:20026/chfs/shared/机器人/urdf/SmallBender_R-2000iC-165F/meshes",X={maxConcurrentLoads:4,enableCache:!0,enableLOD:!0,simplifyGeometry:!0,shareMaterials:!0,enableInstancing:!0},de=new WeakMap,Ke=new WeakMap,Ta=new WeakMap,oe=async ee=>{if(de.has(ee))return console.log(`从缓存加载: ${ee}`),de.get(ee);try{const la=await rl.axios.get(`${ge}/${ee}`,{responseType:"blob",headers:{"Content-Type":"application/json"},timeout:6e5}),Ve=new Blob([la.data],{type:"application/octet-stream;charset=UTF-8"});return X.enableCache&&de.set(ee,Ve),Ve}catch(la){throw console.error(`加载文件失败: ${ee}`,la),new Error(`无法加载文件: ${ee}`)}},S=(ee="default")=>{if(Ke.has(ee))return Ke.get(ee);const la=new Pa.MeshPhongMaterial({color:12303291,shininess:30,transparent:!1,alphaTest:.1,side:Pa.FrontSide});return Ke.set(ee,la),la},le=ee=>{try{ee.isBufferGeometry&&ee.mergeVertices&&ee.mergeVertices(),ee.computeVertexNormals&&ee.computeVertexNormals(),ee.computeBoundingSphere&&ee.computeBoundingSphere(),ee.deleteAttribute&&ee.deleteAttribute("uv2")}catch(la){console.warn("几何体优化失败,使用原始几何体:",la)}return ee},me=async(ee,la,Ve)=>{const ka=`stl_${la}`;if(Ta.has(ka)){const Ge=Ta.get(ka);return new Pa.Mesh(Ge,S())}const He=await ee.arrayBuffer();let Re=new An.STLLoader(Ve).parse(He);return Re=le(Re),Ta.set(ka,Re),new Pa.Mesh(Re,S())},ue=async(ee,la,Ve)=>{const ka=`obj_${la}`;if(de.has(ka))return de.get(ka).clone();const He=await ee.text(),Te=new An.OBJLoader(Ve),Re=la.replace(".obj",".mtl");try{const Fa=await(await oe(Re)).text(),F=new An.MTLLoader(Ve).parse(Fa);F.preload(),Te.setMaterials(F)}catch{console.warn(`MTL文件加载失败,使用默认材质: ${Re}`)}const Ge=Te.parse(He);return Ge.traverse(Ga=>{Ga.isMesh&&(Ga.geometry=le(Ga.geometry),Ga.castShadow=!0,Ga.receiveShadow=!0,Ga.renderOrder=1)}),de.set(ka,Ge),Ge},Ne=(ee,la)=>{const Ve=new Pa.LOD;if(Ve.addLevel(ee,0),ee.geometry){const ka=ee.geometry.clone(),He=new Pa.Mesh(ka,ee.material);Ve.addLevel(He,50)}return Ve};let pa=0,_a=0;const Wa=[];ne.loadMeshCb=async(ee,la,Ve,ka,He)=>{const Te=ee.split("/").pop(),Re=Ve||(()=>{});pa++;const Ge=new Promise(async(Ga,Fa)=>{try{const P=await oe(Te);if(!P||P.size===0)throw new Error(`文件为空: ${Te}`);const F=Te.split(".").pop().toLowerCase();let J;switch(F){case"stl":J=await me(P,Te,la);break;case"obj":J=await ue(P,Te,la);break;default:throw new Error(`不支持的文件格式: ${F}`)}X.enableLOD&&J.isMesh&&(J=Ne(J,Te)),Re(J),_a++,ka&&ka({loaded:_a,total:pa,progress:_a/pa}),Ga(J)}catch(P){console.error(`mesh文件加载失败: ${Te}`,P);const F=new Pa.Group;Re(F),Ga(F);const J=new Pa.BoxGeometry(.1,.1,.1),ie=new Pa.MeshStandardMaterial({color:16711680,wireframe:!0});return new Pa.Mesh(J,ie)}});Wa.push(Ge)};try{if(!De){ui.value=void 0;break}if(A=await ne.loadAsync(De),console.log(`URDF文件加载完成,等待${pa}个mesh文件加载...`),Wa.length>0)try{await Promise.allSettled(Wa),console.log(`所有mesh文件处理完成,成功加载: ${_a}/${pa}`)}catch(Ve){console.warn("部分mesh文件加载失败,但继续显示模型",Ve)}A.traverse(Ve=>{Ve.isMesh&&(Ve.castShadow=!0,Ve.receiveShadow=!0,Ve.renderOrder=1,Ve.material&&(Ve.material.needsUpdate=!0))}),console.time("计算包围盒");const ee=new Pa.Box3;ee.expandByObject(A);const la=`urdf_${Date.now()}`;A.userData.boundingBox=ee.clone(),A.userData.modelId=la,os.set(la,{box:ee.clone(),center:ee.getCenter(new Pa.Vector3),size:ee.getSize(new Pa.Vector3),maxSize:Math.max(...ee.getSize(new Pa.Vector3).toArray())}),ui.value=A,console.log("URDF模型加载完成并优化")}catch(ee){console.error("URDF加载失败:",ee),ui.value=void 0}finally{De&&URL.revokeObjectURL(De)}break;default:throw new Error(`不支持的文件格式: ${E}`)}return A};return{addModelsFromUrls:m,loadModelByDefaultPath:async E=>{console.log(E);try{n.value=!0,o.value="正在加载模型...";const{scene:B}=l();if(!B)throw new Error("Scene not initialized");s(),await new Promise(V=>setTimeout(V,100));const w=[];for(let V=0;V<E.length;V++){const A=E[V],N=await u(A.suffix,A.blob,A.mtlBlobs||[],A.meshFiles||[]);N&&(B.add(N),r.value.push(N),w.push(N))}return n.value=!1,o.value="",w}catch(B){throw console.error("加载模型失败:",B),n.value=!1,o.value="",B}},urdfModel:ui,modelBoundingBoxes:os}}window._iconfont_svg_string_4827314='<svg><symbol id="icon-chart-new" viewBox="0 0 1024 1024"><path d="M960 768V448h-64v320h-64v64H192v-64h-64V256h64v-64h256v-64H192V64H0v192h64v512H0v192h192v-64h640v64h192V768h-64zM64 128h64v64H64v-64z m0 768v-64h64v64H64z m896 0h-64v-64h64v64zM256 768V256h128v512H256z m192-320h128v320H448V448z m192 192h128v128H640V640zM512 288c0-17.664 14.336-32 32-32h160V96c0-17.664 14.336-32 32-32s32 14.336 32 32v160h160c17.664 0 32 14.336 32 32s-14.336 32-32 32H768v160c0 17.664-14.336 32-32 32s-32-14.336-32-32V320H544c-17.664 0-32-14.336-32-32z" ></path></symbol><symbol id="icon-ai13" viewBox="0 0 1024 1024"><path d="M863.719038 159.366637l-705.295378 0c-48.443315 0-88.129176 39.690978-88.129176 88.161922l0 528.943904c0 48.474015 39.685861 88.161922 88.129176 88.161922l705.295378 0c48.443315 0 88.134293-39.687908 88.134293-88.161922l0-528.943904C951.853331 199.056592 912.162354 159.366637 863.719038 159.366637M643.272277 776.472464l-484.84964 0 0-176.324868 484.84964 0L643.272277 776.472464zM643.272277 556.053332l-484.84964 0 0-176.296215 484.84964 0L643.272277 556.053332zM863.719038 776.472464 687.394171 776.472464l0-396.659065 176.324868 0L863.719038 776.472464z" ></path></symbol><symbol id="icon-qiehuanwenjianjia" viewBox="0 0 1024 1024"><path d="M409.6 102.4L512 204.8h307.2a102.4 102.4 0 0 1 102.144 94.72l0.256 7.68v512a102.4 102.4 0 0 1-94.72 102.144l-7.68 0.256H512v-76.8h281.6a51.2 51.2 0 0 0 50.842-45.21l0.358-5.99V332.8a51.2 51.2 0 0 0-45.21-50.842l-5.99-0.358H486.4L384 179.2H230.4a51.2 51.2 0 0 0-50.842 45.21l-0.358 5.99v179.2h-76.8V204.8a102.4 102.4 0 0 1 94.72-102.144l7.68-0.256h204.8z m217.6 588.8a38.4 38.4 0 1 1 0 76.8H358.4v99.584a25.6 25.6 0 0 1-41.83 19.814L132.3 736.614a25.6 25.6 0 0 1 16.231-45.414zM447.59 389.99l3.84 2.612L635.7 543.386a25.6 25.6 0 0 1-11.623 45.004l-4.608 0.41H140.8a38.4 38.4 0 0 1-5.222-76.442L140.8 512h268.8v-99.584a25.6 25.6 0 0 1 37.99-22.426z" ></path></symbol><symbol id="icon-baogao" viewBox="0 0 1104 1024"><path d="M265.401 1024a174.066 174.066 0 0 1-173.56-173.56V315.3a4.194 4.194 0 0 0-4.338-4.34H41.22A39.63 39.63 0 0 1 0 273.356V123.66C0 55.684 59.3 0 132.339 0h648.678a132.411 132.411 0 0 1 132.339 132.339v553.22a4.194 4.194 0 0 0 4.339 4.34h146.079a40.714 40.714 0 0 1 41.22 41.22v159.819a132.411 132.411 0 0 1-132.339 132.339l-707.254 0.723z m653.017-260.339A4.194 4.194 0 0 0 914.08 768v123.661a59.3 59.3 0 0 0 118.599 0V768a4.194 4.194 0 0 0-4.339-4.339z m-749.198-452.7a4.194 4.194 0 0 0-4.339 4.338v534.419a100.737 100.737 0 0 0 100.52 100.52h582.147a3.977 3.977 0 0 0 3.616-2.17 4.628 4.628 0 0 0 0-4.34 132.7 132.7 0 0 1-10.848-52.79V133.062a59.3 59.3 0 0 0-118.598 0v140.294a39.195 39.195 0 0 1-41.22 37.604zM132.34 73.762c-32.542 0-59.3 22.418-59.3 49.898v109.92a4.194 4.194 0 0 0 4.34 4.34h566.237a4.194 4.194 0 0 0 4.339-4.34V133.063a132.7 132.7 0 0 1 10.847-52.79c0.723-1.447 0-2.893 0-4.34a3.977 3.977 0 0 0-3.616-2.17z m169.22 692.068a36.881 36.881 0 0 1 0-73.763h402.08a36.881 36.881 0 0 1 0 73.763z m0-196.701a36.881 36.881 0 1 1 0-73.763h402.08a36.881 36.881 0 1 1 0 73.763z" ></path></symbol><symbol id="icon-xinghao" viewBox="0 0 1024 1024"><path d="M580.583 425.004c52.988-24.574 104.44-49.276 152.82-73.594 48.381-24.703 87.034-42.877 115.704-54.268 28.67-11.136 51.58-17.023 69.115-17.023a104.952 104.952 0 0 1 74.235 28.798 93.177 93.177 0 0 1 31.485 71.802c0 16.383-5.12 33.534-15.358 51.069-10.24 17.534-21.247 28.926-32.638 33.79-105.976 41.468-222.832 72.058-350.054 90.872 23.038 20.99 51.452 49.405 85.113 84.474 33.79 35.582 51.453 54.268 52.86 56.7 12.416 17.023 29.566 38.397 51.837 63.74 22.142 25.597 37.501 45.18 46.076 59.643a99.833 99.833 0 0 1 13.055 52.092 93.817 93.817 0 0 1-29.693 68.731 103.16 103.16 0 0 1-76.41 29.694c-31.23 0-66.172-24.318-105.337-72.443-39.037-48.124-89.465-135.158-151.029-260.46A12540.003 12540.003 0 0 1 386.677 862.22a387.3 387.3 0 0 1-61.563 81.53 96.889 96.889 0 0 1-67.835 27.774 101.625 101.625 0 0 1-76.026-31.358c-19.711-20.862-30.078-43.517-30.078-66.939 0-22.142 4.095-38.909 12.287-50.172 75.514-102.393 154.356-191.602 236.782-266.605a2401.103 2401.103 0 0 1-184.818-35.709 1163.818 1163.818 0 0 1-172.531-57.724c-9.984-5.12-19.583-16.382-29.054-33.917A104.696 104.696 0 0 1 0.018 380.72a93.433 93.433 0 0 1 31.358-71.675 102.648 102.648 0 0 1 72.186-28.926c19.839 0 44.285 5.887 73.979 17.79 29.438 11.904 67.067 29.054 112.632 51.453 45.564 22.526 97.656 47.74 155.892 75.514a1833.849 1833.849 0 0 1-26.494-177.267 1574.54 1574.54 0 0 1-10.367-137.078c0-30.205 9.599-56.06 28.798-78.074A95.481 95.481 0 0 1 512.62 0.076c29.822 0 54.012 10.75 73.339 32.51 19.454 21.886 29.054 50.683 29.054 86.649 0 9.855-1.664 29.182-4.48 58.491-2.56 29.182-7.04 64.252-12.16 105.465-5.375 41.34-11.39 88.697-17.79 141.813z" fill="#FF4444" ></path></symbol><symbol id="icon-mima" viewBox="0 0 1024 1024"><path d="M776.86 376.04c-22.05 0-40.16-16.24-43.91-37.98-18.08-104.98-109.79-185.1-219.84-185.1s-201.76 80.13-219.84 185.1c-3.74 21.73-21.85 37.98-43.91 37.98-27.05 0-48.82-24.04-44.44-50.73 24.3-148.16 153.25-261.58 308.19-261.58S796.99 177.15 821.3 325.31c4.38 26.69-17.39 50.73-44.44 50.73zM850.18 418.32H180.33c-37.98 0-68.76 30.79-68.76 68.76v403.71c0 37.98 30.79 68.76 68.76 68.76h665.36c37.97 0 68.75-30.77 68.77-68.74l0.19-408c0.02-35.61-28.85-64.49-64.47-64.49zM557.73 762.56c0 24.64-19.97 44.62-44.62 44.62-24.64 0-44.62-19.97-44.62-44.62v-89.23c0-24.64 19.97-44.62 44.62-44.62 24.64 0 44.62 19.98 44.62 44.62v89.23z" ></path></symbol><symbol id="icon-zhanghao" viewBox="0 0 1024 1024"><path d="M407.61 578.87c-174.46 0-304.73 113.04-304.73 277.2v17.69c0 85.81 139.6 85.81 316.37 85.81h187.73c169.75 0 316.37 0 316.37-85.81v-17.69c0-164.16-130.28-277.2-304.73-277.2H407.61zM503.71 535.67c138.19 0 250.63-105.81 250.63-235.94 0-130.06-112.44-235.86-250.63-235.86-138.11 0-250.56 105.81-250.56 235.86 0 130.13 112.45 235.94 250.56 235.94z" ></path></symbol><symbol id="icon-xiangqingye-37" viewBox="0 0 1024 1024"><path d="M368.64 34.133333H112.64C68.266667 34.133333 34.133333 68.266667 34.133333 112.64v256c0 23.893333 17.066667 40.96 40.96 40.96s40.96-17.066667 40.96-40.96V116.053333h252.586667c23.893333 0 40.96-17.066667 40.96-40.96S389.12 34.133333 368.64 34.133333zM911.36 34.133333h-256c-23.893333 0-40.96 17.066667-40.96 40.96s17.066667 40.96 40.96 40.96h252.586667v252.586667c0 23.893333 17.066667 40.96 40.96 40.96s40.96-17.066667 40.96-40.96V112.64C989.866667 68.266667 955.733333 34.133333 911.36 34.133333zM368.64 907.946667H116.053333v-252.586667c0-23.893333-17.066667-40.96-40.96-40.96S34.133333 634.88 34.133333 655.36v256C34.133333 955.733333 68.266667 989.866667 112.64 989.866667h256c23.893333 0 40.96-17.066667 40.96-40.96s-20.48-40.96-40.96-40.96zM948.906667 617.813333c-23.893333 0-40.96 17.066667-40.96 40.96v252.586667h-252.586667c-23.893333 0-40.96 17.066667-40.96 40.96s17.066667 40.96 40.96 40.96h256c40.96 0 78.506667-34.133333 78.506667-78.506667v-256c0-23.893333-17.066667-40.96-40.96-40.96z" fill="#3366CC" ></path><path d="M416.426667 488.106667L307.2 344.746667c-13.653333-17.066667-34.133333-20.48-51.2-6.826667-17.066667 13.653333-20.48 34.133333-6.826667 51.2L337.92 512l-95.573333 126.293333c-13.653333 17.066667-10.24 37.546667 6.826666 51.2 6.826667 3.413333 13.653333 6.826667 20.48 6.826667 10.24 0 23.893333-6.826667 30.72-13.653333l112.64-146.773334c10.24-17.066667 10.24-34.133333 3.413334-47.786666z" fill="#F4A914" ></path><path d="M597.333333 488.106667L488.106667 341.333333c-13.653333-17.066667-34.133333-20.48-51.2-6.826666-17.066667 13.653333-20.48 34.133333-6.826667 51.2l92.16 122.88-95.573333 126.293333c-13.653333 17.066667-10.24 37.546667 6.826666 51.2 6.826667 3.413333 13.653333 6.826667 20.48 6.826667 10.24 0 23.893333-6.826667 30.72-13.653334l112.64-146.773333c10.24-13.653333 10.24-30.72 0-44.373333z" fill="#F4A914" ></path><path d="M778.24 488.106667L669.013333 341.333333c-13.653333-17.066667-34.133333-20.48-51.2-6.826666-17.066667 13.653333-20.48 34.133333-6.826666 51.2l92.16 122.88-95.573334 126.293333c-6.826667 6.826667-6.826667 17.066667-6.826666 27.306667 0 10.24 6.826667 17.066667 13.653333 23.893333 6.826667 3.413333 13.653333 6.826667 23.893333 6.826667 10.24 0 23.893333-6.826667 30.72-13.653334l112.64-146.773333c6.826667-13.653333 6.826667-30.72-3.413333-44.373333z" fill="#F4A914" ></path></symbol><symbol id="icon-gongzhuangmoju" viewBox="0 0 1024 1024"><path d="M192 170.666667A106.965333 106.965333 0 0 0 85.333333 277.333333V426.666667h256l42.666667 85.333333h256l42.666667-85.333333h256V277.333333A106.965333 106.965333 0 0 0 832 170.666667z" fill="#3B709C" ></path><path d="M384 512l-42.666667-85.333333h341.333334l-42.666667 85.333333z m-298.666667-85.333333V256a85.333333 85.333333 0 0 1 85.333334-85.333333h682.666666a85.333333 85.333333 0 0 1 85.333334 85.333333v170.666667zM853.333333 853.333333H170.666667a85.333333 85.333333 0 0 1-85.333334-85.333333v-256h213.333334l42.666666 85.333333h341.333334l42.666666-85.333333h213.333334v256a85.333333 85.333333 0 0 1-85.333334 85.333333z" fill="#2C6798" ></path></symbol><symbol id="icon-jiagongguochengxinxi" viewBox="0 0 1024 1024"><path d="M345.216 664.192a315.84 315.84 0 0 1 93.12-224.64 315.84 315.84 0 0 1 100.992-68.16 315.392 315.392 0 0 1 123.648-24.96 315.392 315.392 0 0 1 158.72 42.368v-264a24.768 24.768 0 0 0-24.768-24.768H559.296a32.64 32.64 0 0 1 0.704 6.976v133.184c0 19.2-15.616 34.816-34.816 34.816H395.072a34.816 34.816 0 0 1-34.752-34.816v-133.12a32.64 32.64 0 0 1 0.64-6.976H123.456a24.768 24.768 0 0 0-24.768 24.832v676.544c0 13.76 11.072 24.832 24.768 24.832h266.24a316.224 316.224 0 0 1-44.416-162.112zM662.976 406.4a257.792 257.792 0 1 0 0 515.52 257.792 257.792 0 0 0 0-515.52z m112.256 293.376a104.704 104.704 0 0 1-107.328 25.216l-68.48 68.48a46.528 46.528 0 0 1-65.728-65.664l68.48-68.48a104.512 104.512 0 0 1 140.8-129.28l-67.072 67.072 10.88 42.88 43.328 11.328 67.072-67.136c16.64 38.336 9.216 84.416-21.952 115.584z m-220.16 51.456a20.928 20.928 0 1 0 41.856 0 20.928 20.928 0 0 0-41.856 0z" ></path></symbol><symbol id="icon-pingtaiguanli" viewBox="0 0 1024 1024"><path d="M1024 806.4V25.6c0-12.8-12.8-25.6-25.6-25.6H25.6C12.8 0 0 12.8 0 25.6v780.8h435.2v166.4H236.8v51.2h556.8v-51.2H588.8v-166.4H1024zM320 281.6c-12.8-12.8-19.2-25.6-32-32l44.8-76.8c44.8 25.6 96 12.8 121.6-32 12.8-12.8 12.8-32 12.8-44.8h89.6c0 51.2 38.4 83.2 89.6 83.2 12.8 0 32-6.4 44.8-12.8l44.8 76.8c-44.8 25.6-57.6 76.8-32 115.2 12.8 12.8 19.2 25.6 32 32l-44.8 76.8c-44.8-19.2-96-6.4-121.6 38.4-12.8 12.8-12.8 25.6-12.8 44.8H467.2c0-44.8-38.4-83.2-89.6-83.2-12.8 0-32 6.4-44.8 12.8l-44.8-83.2c38.4-25.6 51.2-76.8 32-115.2zM102.4 704v-51.2h825.6v51.2H102.4zM512 416c51.2 0 96-38.4 96-89.6S569.6 236.8 512 236.8c-51.2 0-96 38.4-96 89.6 0 51.2 44.8 89.6 96 89.6z" ></path></symbol><symbol id="icon-zhucaidanguanli" viewBox="0 0 1169 1024"><path d="M787.333831 588.946093a75.189984 75.189984 0 0 0-75.093984 75.092984 75.189984 75.189984 0 0 0 75.093984 75.093984 75.165984 75.165984 0 0 0 75.067984-75.093984 75.165984 75.165984 0 0 0-75.067984-75.092984m0 222.841953a147.919968 147.919968 0 0 1-147.748968-147.748969c0-81.455982 66.291986-147.747968 147.748968-147.747968 81.431983 0 147.747968 66.291986 147.747968 147.747968 0 81.480982-66.315986 147.748968-147.747968 147.748969m89.452981 102.106978c0.342 0.244 1.317 0.585 2.315999 0.585h0.122l71.484985-39.496992c-1.706-4.022999-9.605998-23.478995-9.605998-43.739991a113.858976 113.858976 0 0 1 107.739977-113.613975c0.853-4.729999 5.557999-31.524993 5.557998-51.639989s-4.704999-46.88399-5.558998-51.637989a113.858976 113.858976 0 0 1-107.738977-113.565976c0-20.357996 7.923998-39.813991 9.605998-43.81299l-70.313985-39.057992-0.293-0.025a5.339999 5.339999 0 0 0-2.706 0.732 196.753958 196.753958 0 0 1-26.014994 21.819995c-21.698995 15.238997-42.153991 22.967995-60.951987 22.967995-18.919996 0-39.594991-7.874998-61.390987-23.405995a194.705958 194.705958 0 0 1-26.160994-22.283995 5.777999 5.777999 0 0 0-2.729999-0.707h-0.245l-72.824985 40.032992c1.706 4.046999 9.580998 23.479995 9.580998 43.73999A113.858976 113.858976 0 0 1 528.895886 614.350088c-0.854 4.729999-5.509999 31.524993-5.509998 51.638989s4.655999 46.90899 5.533998 51.662989a113.858976 113.858976 0 0 1 107.763977 113.589975c0 20.334996-7.972998 39.863991-9.679998 43.788991l68.973985 38.545992h0.146c1.024 0 1.95-0.365 2.317-0.585a200.849957 200.849957 0 0 1 26.428994-23.161995c22.088995-16.188997 43.079991-24.429995 62.414987-24.429995 19.552996 0 40.715991 8.387998 62.950986 24.917995 14.920997 11.068998 25.258995 22.185995 26.550995 23.575995m22.673995 108.397976c-13.774997-0.025-27.135994-5.704999-35.765993-15.213996-11.775997-12.896997-49.005989-46.44599-79.530982-46.44599-30.280993 0-68.119985 33.767993-78.993984 45.54399-8.606998 9.386998-21.869995 14.969997-35.498992 14.969997-6.484999 0-12.604997-1.243-18.187996-3.706l-0.975-0.414-92.69698-51.833988-0.926-0.683a44.46999 44.46999 0 0 1-14.920996-53.735989c0.049-0.146 8.532998-19.699996 8.532998-37.594992a98.376979 98.376979 0 0 0-98.254979-98.254978h-3.900999c-15.505997 0-28.159994-13.799997-32.182993-35.108993-0.341-1.706-7.923998-42.178991-7.923999-74.044984 0-31.913993 7.557998-72.361984 7.899999-74.117984 4.119999-21.576995 16.992996-35.449992 32.816993-35.083993h3.266999a98.400979 98.400979 0 0 0 98.279979-98.303978c0-17.846996-8.484998-37.399992-8.558998-37.619992a44.34899 44.34899 0 0 1 15.067996-53.661989l0.95-0.658 97.840979-53.759988 1.024-0.415c5.485999-2.364999 11.507998-3.534999 17.895996-3.534999 13.604997 0 26.891994 5.436999 35.595992 14.628997 11.580998 12.116997 48.17699 43.641991 77.774984 43.64199 29.354994 0 65.755986-30.914993 77.287983-42.812991 8.654998-8.996998 21.844995-14.335997 35.302992-14.335997 6.509999 0 12.653997 1.219 18.285997 3.657l0.974999 0.414 94.47698 52.516988 0.95 0.658c16.895996 11.751997 23.332995 34.889993 14.945997 53.735989-0.049 0.146-8.532998 19.699996-8.532999 37.545992a98.400979 98.400979 0 0 0 98.254979 98.279978h3.291c15.774997-0.341 28.719994 13.506997 32.816993 35.107993 0.317 1.707 7.899998 42.203991 7.899998 74.069984 0 31.889993-7.582998 72.410984-7.948998 74.117984-4.046999 21.551995-16.992996 35.424992-32.767993 35.059993h-3.291a98.400979 98.400979 0 0 0-98.254979 98.278978c0 17.846996 8.483998 37.449992 8.556999 37.619992a44.42199 44.42199 0 0 1-15.017997 53.710989l-0.927 0.683-96.133979 53.100988-0.975 0.415a44.88499 44.88499 0 0 1-17.846996 3.583999z m222.061952-705.339848a48.76199 48.76199 0 1 1-97.523979 0V121.977194c0-13.457997-10.873998-24.453995-24.307995-24.453995h-877.859811c-13.262997 0-24.306995 10.970998-24.306995 24.453995v584.995874c0 13.457997 10.873998 24.453995 24.307995 24.453995h219.500953a48.76199 48.76199 0 1 1 0 97.523979H48.907989A48.76199 48.76199 0 0 1 0 780.190052V48.76221C0 21.822215 21.893995 0.00022 48.907989 0.00022h1023.706781a48.76199 48.76199 0 0 1 48.907989 48.76199v268.189942zM219.427953 975.23701c0-26.940994 21.991995-48.76199 48.981989-48.761989h194.607959a48.76199 48.76199 0 1 1 0 97.523979H268.433942a48.76199 48.76199 0 0 1-49.005989-48.76199z" ></path></symbol><symbol id="icon-caidanguanli" viewBox="0 0 1024 1024"><path d="M414.2 78H158.6c-41.5 0-75.3 33.8-75.3 75.3v255.5c0 41.5 33.8 75.3 75.3 75.3h255.5c41.5 0 75.3-33.8 75.3-75.3V153.3c0-41.5-33.7-75.3-75.2-75.3z m5.2 330.8c0 2.9-2.4 5.3-5.3 5.3H158.6c-2.9 0-5.3-2.4-5.3-5.3V153.3c0-2.9 2.4-5.3 5.3-5.3h255.5c2.9 0 5.3 2.4 5.3 5.3v255.5zM414.2 544.8H158.6c-41.5 0-75.3 33.8-75.3 75.3v255.5c0 41.5 33.8 75.3 75.3 75.3h255.5c41.5 0 75.3-33.8 75.3-75.3V620.1c0-41.5-33.7-75.3-75.2-75.3z m5.2 330.8c0 2.9-2.4 5.3-5.3 5.3H158.6c-2.9 0-5.3-2.4-5.3-5.3V620.1c0-2.9 2.4-5.3 5.3-5.3h255.5c2.9 0 5.3 2.4 5.3 5.3v255.5zM908.8 119.3H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35zM908.8 343.8H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35zM908.8 568.3H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35zM908.8 792.8H607.2c-19.3 0-35 15.7-35 35s15.7 35 35 35h301.6c19.3 0 35-15.7 35-35s-15.7-35-35-35z" ></path></symbol><symbol id="icon-jueseguanli" viewBox="0 0 1024 1024"><path d="M874.9 577.3c-26.1-27.2-56.8-48.9-90.3-64.1 5.4-4.6 10.6-9.6 15.5-14.8 32.3-34.7 50.1-79.8 50.1-127.2 0-102.9-83.7-186.7-186.7-186.7-11 0-21.8 0.9-32.5 2.8-7.1-9.6-14.9-18.7-23.4-27.2-44.6-44.6-103.9-69.2-167-69.2s-122.4 24.6-167 69.2-69.2 103.9-69.2 167 24.6 122.4 69.2 167c10.8 10.8 22.4 20.4 34.8 28.7-4.9 1.8-9.7 3.8-14.5 5.8-44.9 19-85.2 46.2-119.9 80.8-34.6 34.6-61.8 75-80.8 119.9-19.7 46.5-29.6 95.9-29.6 146.8 0 17.7 1.2 35.5 3.7 52.9l69.3-9.7c-2-14.2-3-28.7-3-43.1 0-169.4 137.8-307.1 307.1-307.1s307.1 137.8 307.1 307.1c0 14.4-1 28.9-3 43.1l69.3 9.7c2.4-17.4 3.7-35.2 3.7-52.9 0-50.9-10-100.3-29.6-146.8-19-44.9-46.2-85.2-80.8-119.9-34.6-34.6-74.9-61.8-119.9-80.8-4.8-2-9.7-4-14.6-5.8 12.3-8.4 24-18 34.8-28.7 44.6-44.6 69.2-103.9 69.2-167 0-25-3.9-49.4-11.3-72.6 63.4 1.1 114.7 53 114.7 116.6 0 45.5-26.6 85.6-65.3 104.7-16.3 8.1-26.8 24.4-26.8 42.6v1c0 21.2 14.1 40 34.6 45.5 94.9 25.8 163.8 112.4 163.8 215 0 10.5-0.7 21-2.2 31.3l69.3 9.7c1.9-13.5 2.9-27.3 2.9-41-0.1-75.8-29.1-147.8-81.7-202.6z m-434.3-84c-91.6 0-166.2-74.6-166.2-166.2S349 160.9 440.6 160.9s166.2 74.6 166.2 166.2-74.5 166.2-166.2 166.2z" ></path></symbol><symbol id="icon-zhiweiguanli" viewBox="0 0 1024 1024"><path d="M878.4 243.5h-91.2v-41.2c0-58.6-47.7-106.2-106.2-106.2H354.2c-58.6 0-106.2 47.7-106.2 106.2v41.2h-91.2c-43.2 0-78.4 35.1-78.4 78.4V856c0 43.2 35.1 78.4 78.4 78.4h721.5c43.2 0 78.4-35.1 78.4-78.4V321.8c0-43.2-35.1-78.3-78.3-78.3zM318 202.3c0-20 16.2-36.2 36.2-36.2H681c20 0 36.2 16.3 36.2 36.2v41.2H318v-41.2zM156.8 313.5h721.5c4.6 0 8.4 3.7 8.4 8.4V554H692.4c-14.8-45.3-57.4-78.2-107.6-78.2H450.4c-50.2 0-92.9 32.9-107.6 78.2H148.5V321.8c0-4.6 3.7-8.3 8.3-8.3zM628 588.9c0 23.8-19.4 43.2-43.2 43.2H450.4c-23.8 0-43.2-19.4-43.2-43.2 0-23.8 19.4-43.2 43.2-43.2h134.3c23.9 0 43.3 19.4 43.3 43.2z m250.4 275.5H156.8c-4.6 0-8.4-3.7-8.4-8.4V623.9h194.3c14.8 45.3 57.4 78.2 107.6 78.2h134.3c50.2 0 92.9-32.9 107.6-78.2h194.3V856c0.2 4.6-3.5 8.4-8.1 8.4z" ></path></symbol><symbol id="icon-bumenguanli" viewBox="0 0 1024 1024"><path d="M322.5 62h384.6v70H322.5z" ></path><path d="M870.2 62h-59.3v70h59.3c7.2 0 13 5.8 13 13v733.9c0 7.2-5.8 13-13 13h-720c-7.2 0-13-5.8-13-13V145c0-7.2 5.8-13 13-13h68.6V62h-68.6c-45.8 0-83 37.2-83 83v733.9c0 45.8 37.2 83 83 83h720c45.8 0 83-37.2 83-83V145c0-45.8-37.3-83-83-83z" ></path><path d="M295 806.2c-0.5-5.7-0.7-11.6-0.7-17.3 0-119 96.8-215.8 215.8-215.8S726 669.8 726 788.8c0 5.8-0.2 11.6-0.7 17.3l69.8 5.6c0.6-7.6 0.9-15.3 0.9-22.9 0-76.4-29.7-148.1-83.7-202.1-29.7-29.8-64.9-52.1-103.3-66.2 45.6-31.5 75.5-84.1 75.5-143.5 0-96.1-78.2-174.4-174.4-174.4-96.1 0-174.4 78.2-174.4 174.4 0 59.5 29.9 112 75.5 143.5C373 534.6 337.8 557 308 586.7c-54 54-83.7 125.8-83.7 202.1 0 7.6 0.3 15.3 0.9 22.9l69.8-5.5z m215.2-533.6c57.5 0 104.4 46.8 104.4 104.4 0 57.5-46.8 104.4-104.4 104.4-57.5 0-104.4-46.8-104.4-104.4 0-57.6 46.8-104.4 104.4-104.4z" ></path></symbol><symbol id="icon-gerenzhongxin" viewBox="0 0 1024 1024"><path d="M930.4 337.3c-22.7-53.7-55.2-101.9-96.6-143.3-41.4-41.4-89.6-73.9-143.3-96.6C634.9 73.9 575.9 62 515.1 62c-60.8 0-119.9 11.9-175.5 35.4-53.7 22.7-101.9 55.2-143.3 96.6-41.4 41.4-73.9 89.6-96.6 143.3-23.5 55.6-35.4 114.6-35.4 175.5 0 50.5 8.3 100.1 24.7 147.4l66.1-22.9c-13.8-39.9-20.8-81.8-20.8-124.5 0-209.9 170.8-380.7 380.7-380.7 209.9 0 380.8 170.8 380.8 380.7 0 41.6-6.7 82.5-19.8 121.5l66.3 22.3c15.6-46.2 23.5-94.7 23.5-143.9 0-60.8-11.9-119.8-35.4-175.4z" ></path><path d="M656.9 422.2c0-76.9-62.6-139.5-139.5-139.5s-139.5 62.6-139.5 139.5 62.6 139.5 139.5 139.5 139.5-62.6 139.5-139.5z m-209 0c0-38.3 31.2-69.5 69.5-69.5s69.5 31.2 69.5 69.5-31.2 69.5-69.5 69.5-69.5-31.2-69.5-69.5zM713.8 627.8c-62-27.2-128.1-40.9-196.4-40.9-69 0-135.7 14-198.2 41.7-60.4 26.7-114.1 64.9-159.5 113.3l-20.3 21.7 18.1 23.6c41.2 53.6 94.8 98 155 128.3 63.2 31.8 131.3 48 202.6 48 71.9 0 140.6-16.4 204.2-48.8 60.7-30.9 114.5-76 155.6-130.4l17.9-23.7-20.5-21.6c-45.3-47.6-98.6-85-158.5-111.2zM515.1 893.5c-109 0-210.3-45.3-282.5-125.4 77.7-71.9 177.7-111.2 284.8-111.2 105.8 0 204.9 38.4 282.2 108.8-72.2 81.6-174.3 127.8-284.5 127.8z" ></path></symbol><symbol id="icon-yonghuguanli" viewBox="0 0 1024 1024"><path d="M751.4 553.2c-42.5-38.5-92.1-67.1-145.5-84.6 53.2-38.9 87.8-101.8 87.8-172.7C693.7 178 597.7 82 479.8 82c-57.1 0-110.8 22.2-151.2 62.6C288.2 185 266 238.7 266 295.8s22.2 110.8 62.6 151.2c7.8 7.8 16.2 15 25 21.4-10.5 3.5-20.9 7.3-31.2 11.7-48.2 20.4-91.4 49.5-128.5 86.7s-66.3 80.4-86.7 128.5c-21.1 49.9-31.8 102.9-31.8 157.4 0 24.8 2.3 49.7 6.8 73.9l68.8-12.7c-3.7-20-5.6-40.6-5.6-61.2 0-184.4 150-334.4 334.4-334.4 83.2 0 163 30.8 224.5 86.6l47.1-51.7zM479.8 152c79.3 0 143.9 64.5 143.9 143.9s-64.5 143.9-143.9 143.9S336 375.2 336 295.9 400.5 152 479.8 152zM726.3 665.3h213.8v70H726.3zM503 831.6h437.1v70H503z" ></path></symbol><symbol id="icon-app" viewBox="0 0 1024 1024"><path d="M363.485867 865.117867h305.5616c21.6576 0 39.2192-17.194667 39.2192-38.4s-17.5616-38.4-39.2192-38.4H363.485867c-21.6576 0-39.2192 17.194667-39.2192 38.4s17.5616 38.4 39.2192 38.4z" fill="#A6ADB4" ></path><path d="M945.288533 699.835733a40.448 40.448 0 0 0-43.195733 43.1872v147.037867a46.865067 46.865067 0 0 1-45.960533 48.708267H166.766933a46.882133 46.882133 0 0 1-45.038933-48.708267v-147.029333a40.439467 40.439467 0 1 0-80.887467 0v147.029333a125.883733 125.883733 0 0 0 125.9264 128.657067h693.0432c70.203733-1.006933 126.4384-58.461867 125.9264-128.657067v-147.029333a40.430933 40.430933 0 0 0-40.448-43.195734zM40.840533 127.735467v147.959466a39.517867 39.517867 0 0 0 79.044267 0V127.735467a45.943467 45.943467 0 0 1 46.882133-47.786667h693.0432a46.882133 46.882133 0 0 1 45.960534 47.786667v147.959466a39.509333 39.509333 0 0 0 39.517866 39.509334 40.448 40.448 0 0 0 40.448-39.509334V127.735467C986.248533 58.052267 930.423467 1.024 860.7232 0H166.775467A125.934933 125.934933 0 0 0 40.840533 127.744z m168.4992 427.972266H326.229333L357.316267 640H418.133333L295.150933 315.733333h-52.701866L119.466667 640h60.817066l29.056-84.292267zM269.124267 392.533333L307.2 503.466667h-76.8l38.724267-110.933334z m231.552 131.959467h32.631466a123.246933 123.246933 0 0 0 88.192-28.535467c23.389867-19.959467 36.394667-49.134933 35.413334-79.488 1.6384-28.245333-9.838933-55.722667-31.249067-74.743466a127.573333 127.573333 0 0 0-84.0192-25.813334H443.733333V640h56.942934V524.4928zM503.466667 366.933333h32.136533c42.180267 0 61.602133 17.493333 61.602133 53.162667 1.092267 16.0256-4.8128 31.701333-16.068266 42.666667a71.364267 71.364267 0 0 1-51.5584 14.677333H503.466667V366.933333z m286.293333-51.0976H691.2V640h57.3184V524.4672h32.853333c31.837867 1.928533 63.189333-8.311467 87.381334-28.544 23.543467-19.959467 36.625067-49.152 35.643733-79.505067 1.536-28.100267-9.710933-55.441067-30.754133-74.752a131.84 131.84 0 0 0-83.882667-25.8304z m39.4752 147.131734a73.813333 73.813333 0 0 1-49.527467 14.72H750.933333V366.933333h32.119467c42.1632 0 61.576533 17.527467 61.576533 53.2736 1.262933 15.957333-4.394667 31.650133-15.394133 42.752z" fill="#A6ADB4" ></path></symbol><symbol id="icon-yepian" viewBox="0 0 1024 1024"><path d="M807.936 99.328c-17.408 0-32.256 9.216-40.448 23.552h-348.16L284.672 355.84l35.84 35.84 126.976-219.648h321.536c8.192 12.8 22.528 20.992 38.912 20.992 25.6 0 46.592-20.992 46.592-46.592s-20.992-47.104-46.592-47.104z" ></path><path d="M301.056 50.688c-8.704 14.848-7.68 32.768 0 46.592L127.488 399.36l134.656 232.448 48.64-13.312L183.808 399.36l160.256-279.04c15.36-1.024 29.696-9.216 37.888-23.04 12.8-22.528 5.12-50.688-17.408-63.488s-50.688-5.632-63.488 16.896z" ></path><path d="M15.872 467.456c8.704 14.848 24.064 23.552 40.448 23.552L228.352 793.6l268.8 1.536 13.312-48.64-253.44-1.536-159.232-279.552c6.656-13.312 7.168-30.208-1.024-44.032-12.8-22.528-40.96-30.208-63.488-17.408-22.528 12.8-30.208 40.96-17.408 63.488z" ></path><path d="M216.064 924.672c17.408 0 32.256-9.216 40.448-23.552h348.16l134.144-232.448-35.84-35.84-126.976 219.648H254.976c-8.192-12.8-22.528-20.992-38.912-20.992-25.6 0-46.592 20.992-46.592 46.592s20.992 46.592 46.592 46.592z" ></path><path d="M722.944 973.312c8.704-14.848 7.68-32.768 0-46.592l173.568-302.08-134.656-232.448-48.64 13.312 127.488 219.136-160.256 279.04c-15.36 1.024-29.696 9.216-37.888 23.04-12.8 22.528-5.12 50.688 17.408 63.488 22.016 13.312 50.176 5.632 62.976-16.896z" ></path><path d="M1008.128 556.544c-8.704-14.848-24.064-23.552-40.448-23.552L795.648 230.4l-268.8-1.536-13.312 48.64 253.44 1.536 159.232 279.552c-6.656 13.312-7.168 30.208 1.024 44.032 12.8 22.528 40.96 30.208 63.488 17.408 22.528-12.8 30.208-40.96 17.408-63.488zM512 391.168C445.44 391.168 391.168 445.44 391.168 512S445.44 632.832 512 632.832s120.832-54.272 120.832-120.832S578.56 391.168 512 391.168z m0 196.096c-41.472 0-75.264-33.792-75.264-75.264s33.792-75.264 75.264-75.264 75.264 33.792 75.264 75.264-33.792 75.264-75.264 75.264z" ></path></symbol><symbol id="icon-left-circle-fill" viewBox="0 0 1024 1024"><path d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64z m104 316.9c0 10.2-4.9 19.9-13.2 25.9L457.4 512l145.4 105.2c8.3 6 13.2 15.6 13.2 25.9V690c0 6.5-7.4 10.3-12.7 6.5l-246-178c-4.4-3.2-4.4-9.7 0-12.9l246-178c5.3-3.8 12.7-0.1 12.7 6.5v46.8z" ></path></symbol><symbol id="icon-right-circle-fill" viewBox="0 0 1024 1024"><path d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64z m154.7 454.5l-246 178c-5.3 3.8-12.7 0-12.7-6.5v-46.9c0-10.2 4.9-19.9 13.2-25.9L566.6 512 421.2 406.8c-8.3-6-13.2-15.6-13.2-25.9V334c0-6.5 7.4-10.3 12.7-6.5l246 178c4.4 3.2 4.4 9.8 0 13z" ></path></symbol><symbol id="icon-xitongguanli" viewBox="0 0 1026 1024"><path d="M400.896 67.072H140.8c-24.064 0-46.592 11.264-59.392 29.696-9.216 12.8-14.848 27.648-14.848 44.544v259.584c0 40.96 33.28 74.24 74.24 74.24h259.584c40.96 0 74.24-33.28 74.24-74.24V141.312c0.512-40.96-33.28-74.24-73.728-74.24z m0 361.984v9.216-9.216z m335.872 83.456c18.432 0 35.328-7.168 48.128-20.48L939.008 337.92c12.8-12.8 20.48-29.696 20.48-48.128s-7.168-35.328-20.48-48.128l-154.112-155.648c-26.112-26.112-70.656-26.112-96.256 0l-154.112 154.112c-12.8 12.8-20.48 29.696-20.48 48.128 0 18.432 7.168 35.328 20.48 48.128l154.112 154.112c12.8 14.336 29.184 22.016 48.128 22.016z m0-369.152l146.432 146.432-146.432 146.432-144.896-146.432L736.768 143.36z m-335.872 406.016H140.8c-40.96 0-74.24 33.28-74.24 74.24v259.584c0 40.96 33.28 74.24 74.24 74.24h259.584c40.96 0 74.24-33.28 74.24-74.24v-259.584c0.512-40.448-33.28-74.24-73.728-74.24z m0 352.768v18.432-18.432z m484.352-352.768h-259.584c-40.96 0-74.24 33.28-74.24 74.24v259.584c0 40.96 33.28 74.24 74.24 74.24h259.584c40.96 0 74.24-33.28 74.24-74.24v-259.584c0-40.448-33.792-74.24-74.24-74.24z" ></path></symbol><symbol id="icon-gongjianku" viewBox="0 0 1024 1024"><path d="M798.72 320v446.976H223.232V320H63.488v532.48c0 41.472 33.792 75.264 75.264 75.264h745.472c41.472 0 75.264-33.792 75.264-75.264v-532.48H798.72z" ></path><path d="M608.256 494.592z m-10.24-4.608z" ></path><path d="M819.2 96.256H203.776c-41.472 0-75.264 33.792-75.264 75.264V286.72h128v448h510.464V286.72h128V171.008c-0.512-41.472-34.304-74.752-75.776-74.752z m-154.112 493.056l-12.8 12.8c-12.8 12.8-33.28 12.8-46.08 0L477.184 473.088c-33.792 11.776-72.704 4.608-99.328-22.528-27.136-27.136-34.304-66.048-22.528-99.84l38.4 38.4c12.8 12.8 33.28 12.8 46.08 0l12.8-12.8c12.8-12.8 12.8-33.28 0-46.08L414.208 291.84c33.792-11.776 72.704-4.096 99.84 22.528 27.136 27.136 34.304 66.048 22.528 99.84l128.512 128.512c12.288 13.312 12.288 33.792 0 46.592z" ></path></symbol><symbol id="icon-fangfaku" viewBox="0 0 1024 1024"><path d="M256 170.496v170.496h512V170.496h85.504c23.552 0 42.496 18.944 42.496 42.496V896c0 23.552-18.944 42.496-42.496 42.496H170.496c-23.552 0-42.496-18.944-42.496-42.496V212.992c0-23.552 18.944-42.496 42.496-42.496H256z m256 513.024H256v83.456h256v-83.456zM768 491.52H256v83.456h512V491.52zM341.504 85.504h341.504V256H341.504V85.504z" ></path></symbol><symbol id="icon-shebeiku" viewBox="0 0 1024 1024"><path d="M960 491.52v380.416c0 26.112-23.04 47.616-52.224 47.616H116.224c-29.184 0-52.224-21.504-52.224-47.616V491.52c0-26.112 23.04-47.616 52.224-47.616h791.552c28.672 0 52.224 21.504 52.224 47.616z m-149.504 156.16H213.504V783.36h596.992v-135.68z m149.504-500.736v186.88c0 23.04-20.992 42.496-46.592 42.496H110.592c-25.6 0-46.592-18.944-46.592-42.496V146.944c0-23.04 20.992-42.496 46.592-42.496h802.304c26.112 0 47.104 18.944 47.104 42.496z m-671.744 25.6c-41.472 0-74.752 30.208-74.752 68.096s33.792 68.096 74.752 68.096S363.008 278.528 363.008 240.64s-33.792-68.096-74.752-68.096z m224.256 0c-41.472 0-74.752 30.208-74.752 68.096s33.792 68.096 74.752 68.096 74.752-30.208 74.752-68.096-33.792-68.096-74.752-68.096z" ></path></symbol><symbol id="icon-wenjian" viewBox="0 0 1024 1024"><path d="M273.54647 325.996013h476.395357c19.444708-2.046811 36.842605 11.769166 39.40112 30.702171 2.046811 19.444708-11.769166 36.330903-31.213874 38.377714-2.558514 0.511703-5.117029 0.511703-7.675543 0H273.54647c-10.234057-0.511703-19.956411-4.605326-26.608548-11.257463-6.652137-6.652137-10.74576-15.351086-10.74576-24.561737 0.511703-19.956411 17.397897-35.307497 37.866011-34.284091v1.023406z m0 209.286467h476.395357c19.444708-2.046811 36.842605 11.769166 39.40112 30.702171 2.046811 19.444708-11.769166 36.330903-31.213874 38.377714-2.558514 0.511703-5.117029 0.511703-7.675543 0H273.54647c-9.722354 0-19.444708-3.58192-26.608548-10.234057-6.652137-6.652137-10.74576-15.351086-10.74576-24.561737 0.511703-19.444708 17.397897-35.307497 37.354308-34.284091z m0 185.748136h324.931312c19.444708 0 35.307497 15.862788 35.307497 34.795794 0 19.444708-15.862788 34.795794-35.307497 34.795794H273.54647c-9.722354-0.511703-19.444708-4.093623-26.608548-10.74576-6.652137-6.140434-10.74576-14.839383-10.74576-24.050034 0.511703-19.444708 17.397897-35.307497 37.354308-34.795794zM135.898402 0.041294h96.71184c17.397897-0.511703 33.772388 8.187246 43.494742 22.514926l53.217097 82.38416c4.605326 7.16384 12.792571 11.769166 20.979817 11.257462h322.884501c8.698949 0 16.886194-4.093623 21.49152-11.257462l53.217097-82.38416c9.722354-14.32768 26.096846-23.026628 43.494742-22.514926h97.223543c53.7288-1.535109 98.246948 39.912823 100.293759 93.12992v837.657572c-2.046811 52.705394-46.56496 94.153325-100.293759 93.12992h-752.203196c-53.7288 1.535109-98.758651-39.912823-100.293759-92.618217V93.171214C37.139751 39.954117 82.169603-1.493814 135.898402 0.041294z m82.895863 70.103291H135.898402c-6.652137 0-13.304274 2.558514-18.421303 6.652138-4.605326 4.093623-7.16384 10.234057-7.16384 16.374491v837.657572c0.511703 13.304274 11.769166 23.538331 25.07344 23.026629h752.203196c6.652137 0 13.304274-2.558514 18.421303-6.652138 4.605326-4.093623 7.16384-10.234057 7.16384-16.374491V93.171214c0.511703-6.140434-2.046811-12.280868-7.16384-16.374491-5.117029-4.605326-11.257463-6.652137-18.421303-6.652138h-82.895862l-46.053257 70.614994c-18.933006 28.65536-51.681988 45.541554-86.477783 45.029851H350.813601c-34.795794 0.511703-67.544777-16.374491-86.477782-45.029851l-45.541554-70.614994zM399.425372 0.041294h225.149256c19.956411-0.511703 36.842605 15.351086 37.866011 34.795795-0.511703 19.956411-17.397897 35.307497-37.866011 34.795794H399.425372c-10.234057-0.511703-19.956411-4.093623-27.120251-10.74576-6.652137-6.140434-10.74576-15.351086-10.234057-24.050034C362.582767 15.39238 378.957258-0.470408 399.425372 0.041294z" ></path></symbol><symbol id="icon-bianjimoban" viewBox="0 0 1025 1024"><path d="M127.110228 701.648461q0 26.438928 18.812314 45.251241t46.268123 18.812314l253.203575 0 0 128.12711-318.284012 0q-26.438928 0-49.82721-9.660377t-40.675273-26.947368-26.947368-40.675273-9.660377-50.844091l0-637.584906q0-26.438928 9.660377-49.82721t26.947368-40.675273 40.675273-27.455809 49.82721-10.168818l766.728898 0q26.438928 0 49.82721 10.168818t40.675273 27.455809 27.455809 40.675273 10.168818 49.82721l0 187.106256-128.12711 1.016882q-2.033764-25.422046-19.829196-43.217478t-44.234359-17.795432l-637.584906 0q-27.455809 0-46.268123 18.812314t-18.812314 45.251241l0 382.347567zM1016.881827 501.322741q6.101291 9.151936 7.626614 23.388282t-10.677259 28.472691q-11.1857 14.236346-18.303873 21.354518l-8.135055 8.135055-105.75571-95.586892q5.084409-6.101291 14.236346-14.744786t14.236346-13.727905q14.236346-14.236346 30.506455-12.711023t27.455809 6.609732q12.202582 5.084409 26.438928 18.812314t22.3714 29.998014zM613.179742 789.100298q3.050645-3.050645 14.236346-16.270109t27.96425-32.540218 37.116187-42.200596 40.675273-46.268123q48.810328-54.911619 108.806356-122.025819l107.789474 95.586892q-59.996028 68.131082-108.806356 123.042701-20.337637 23.388282-40.675273 46.268123t-37.116187 41.183714-27.455809 29.998014-12.711023 13.727905q-9.151936 12.202582-25.422046 20.337637-7.118173 5.084409-21.354518 11.1857t-29.998014 12.202582-29.489573 10.677259-20.846077 5.59285q-26.438928 5.084409-23.388282-22.3714 1.016882-7.118173 4.067527-21.862959t6.609732-30.506455 7.118173-28.981132 5.59285-18.303873q5.084409-13.219464 17.286991-28.472691z" ></path></symbol><symbol id="icon-shanchu1" viewBox="0 0 1024 1024"><path d="M78.768011 168.230165c0-30.999918 24.230644-56.076722 54.15419-56.076722L403.692131 112.153443 403.692131 56.076722c0-30.999918 24.230644-56.076722 54.15419-56.076722l108.306335 0c29.923546 0 54.155214 25.076803 54.155214 56.076722l0 56.077745 270.768906 0c29.923546 0 54.15419 25.076803 54.15419 56.076722l0 56.076722L78.768011 224.307909 78.768011 168.230165zM891.076776 336.461352l0 112.153443 0 519.30746c0 30.923181-24.231667 56.077745-54.153167 56.077745L187.076392 1024c-29.923546 0-54.15419-25.154564-54.15419-56.077745L132.922201 448.614796 132.922201 336.461352l0-56.077745 758.154574 0L891.076776 336.461352zM349.53794 448.614796c0-30.923181-24.230644-56.076722-54.15419-56.076722-29.922523 0-54.153167 25.153541-54.153167 56.076722l0 407.154017c0 30.923181 24.230644 56.077745 54.153167 56.077745 29.923546 0 54.15419-25.154564 54.15419-56.077745L349.53794 448.614796zM566.153679 448.614796c0-30.923181-24.230644-56.076722-54.15419-56.076722-29.922523 0-54.153167 25.153541-54.153167 56.076722l0 407.154017c0 30.923181 24.230644 56.077745 54.153167 56.077745 29.923546 0 54.15419-25.154564 54.15419-56.077745L566.153679 448.614796zM782.770441 448.614796c0-30.923181-24.231667-56.076722-54.155214-56.076722s-54.15419 25.153541-54.15419 56.076722l0 407.154017c0 30.923181 24.230644 56.077745 54.15419 56.077745s54.155214-25.154564 54.155214-56.077745L782.770441 448.614796z" ></path></symbol><symbol id="icon-edit" viewBox="0 0 1024 1024"><path d="M923.9 335.8c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.8-35.2-174.3-35.2S392.2 74.1 337 97.5c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3C75.3 391 63.5 449.7 63.5 510.1c0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c35.9-15.2 69.3-34.8 99.8-58.5l-0.1-0.1c9.1-7.4 14.8-18.6 14.8-31.2 0-22.3-18-40.3-40.3-40.3-9.2 0-17.7 3.1-24.5 8.3l-0.2-0.3c-62 47.9-139.7 76.4-223.9 76.4-202.3 0-366.9-164.6-366.9-366.9s164.7-366.9 367-366.9 366.9 164.6 366.9 366.9c0 66.2-17.6 128.3-48.4 182l0.4 0.2c-4.4 6.5-7 14.2-7 22.6 0 22.3 18 40.3 40.3 40.3 16 0 29.8-9.3 36.3-22.8l0.2 0.1c8.9-15.5 16.8-31.5 23.8-48.1 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.7-119.1-35.1-174.3z" ></path><path d="M693.7 626.5H507.6l-57.1 66.1h243.2zM663.2 411.4c7.5-7.6 7.5-23.5 0-31.3l-45.4-46.8c-7.7-7.6-22.9-7.6-30.4 0l-45.7 46.8 76.1 78.1 45.4-46.8zM328.8 614.5v78.1h76.1l197.5-218.7-76-77.9z" ></path></symbol><symbol id="icon-new" viewBox="0 0 1024 1024"><path d="M926.3 337.9c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.9-35.2-174.3-35.2S394.6 76.2 339.3 99.6c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3-23.4 55.2-35.2 113.9-35.2 174.3 0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c53.3-22.6 101.2-54.8 142.3-96 41.1-41.1 73.4-89 96-142.3 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.8-119.1-35.1-174.3zM513.7 879.1c-202.3 0-366.9-164.6-366.9-366.9s164.6-366.9 366.9-366.9c202.3 0 366.9 164.6 366.9 366.9S716 879.1 513.7 879.1z" ></path><path d="M695.7 469.2h-139v-139c0-23.6-19.3-43-43-43-23.6 0-43 19.3-43 43v139h-139c-23.6 0-43 19.3-43 43s19.3 43 43 43h139v139c0 23.7 19.3 43 43 43 23.6 0 43-19.3 43-43v-139h139c23.6 0 43-19.3 43-43s-19.4-43-43-43z" ></path></symbol><symbol id="icon-biaoqianye1" viewBox="0 0 1024 1024"><path d="M345.557333 128l110.677334 168.405333H938.666667V896H85.333333V128h260.224zM299.52 213.333333H170.666667v597.333334h682.666666V381.738667H410.197333L299.52 213.333333z" fill="#222222" ></path><path d="M597.333333 136.533333c0-4.693333 3.541333-8.533333 7.893334-8.533333h325.546666c4.352 0 7.893333 3.84 7.893334 8.533333v68.266667c0 4.693333-3.541333 8.533333-7.893334 8.533333h-325.546666C600.874667 213.333333 597.333333 209.493333 597.333333 204.8V136.533333z" fill="#222222" ></path></symbol><symbol id="icon-biaoqianye" viewBox="0 0 1024 1024"><path d="M376.6 494.8c5.1 4.8 7.9 11.7 7.6 18.7 0.4 7.1-2.5 14-7.6 18.7-5.3 4.7-12.3 7.2-19.3 6.9h-69.6v235.1c0.2 7.4-2.9 14.4-8.4 19.1-5.5 5.4-12.9 8.3-20.5 8.1-7.6 0.3-15.1-2.7-20.5-8.1-5.3-4.9-8.2-11.9-8.1-19.1v-235H161c-7.2 0.3-14.2-2.3-19.3-7.3-5.2-4.8-8-11.7-7.6-18.7-0.3-7 2.5-13.7 7.6-18.3 5.3-4.8 12.2-7.3 19.3-7h198.4c6.3 0 12.4 2.5 17.2 6.9z m215.7 70.1c5.2 5.1 8 12.2 7.7 19.6v189.9c0.3 7.2-2.5 14.2-7.7 19.1-4.8 5.3-11.7 8.3-18.9 8.1-7.1 0.1-13.9-2.7-18.9-7.7-4.8-5.2-7.6-12-7.6-19.1-18 19.5-42.9 30.8-69.2 31.4-19.7 0.3-38.9-5.3-55.5-15.9-17.2-10.7-31.2-26.1-40.3-44.4-19.3-40.4-19.3-87.6 0-128 8.9-18.4 22.9-33.8 40.3-44.4 16-10.5 34.8-16.1 53.9-15.9 26.3-0.1 51.8 9.8 71.2 27.7-0.2-7.3 2.6-14.4 7.7-19.6 10.6-10.2 27.2-10.2 37.8 0l-0.5-0.8z m-61.2 168.7c24.1-31.6 24.1-75.6 0-107.2-11.5-14.3-28.9-22.3-47.1-21.6-17.9-0.5-35.1 7.4-46.3 21.6-12.1 15-18.5 34-18.1 53.4-0.6 19.5 5.7 38.6 17.7 53.8 11.6 13.9 28.8 21.7 46.7 21.2 18.1 0.4 35.3-7.4 47.1-21.2zM835.4 573c17.1 10.7 31 25.9 40.3 44 9.9 19.8 14.9 41.8 14.5 64 0.4 22.3-4.6 44.4-14.5 64.4-9 18.3-23 33.7-40.3 44.4-16 10.6-34.8 16.1-53.9 15.9-13.9 0.2-27.7-2.9-40.3-9-11.6-5-22.1-12.2-31-21.2v2.8c0.2 7.2-2.5 14.2-7.5 19.4-5 5.1-11.9 8-19.1 7.9-7.1 0.3-14-2.5-18.9-7.7-5.2-5.1-8-12.2-7.6-19.6V497.2c-0.2-7.3 2.5-14.4 7.6-19.6 10.6-10.3 27.2-10.3 37.8 0 5.1 5.2 7.9 12.2 7.6 19.6v93.3c8-9.8 18-17.7 29.4-23.2 12.4-6.8 26.2-10.3 40.3-10.2 19.7-0.2 39 5.3 55.6 15.9z m-15.7 163c12.2-15.1 18.6-34.3 18.1-53.8 0.6-19.4-5.7-38.3-17.7-53.4-12-13.4-29-21.1-46.9-21.1s-34.9 7.7-46.9 21.1c-24.1 31.6-24.1 75.6 0 107.2 11.6 14.1 29 22.1 47.1 21.6 18.3-0.2 35.4-9.1 46.3-24v2.4zM708.1 253.5c-15.5 0-28-12.5-28-28V113.4c-0.1-8 0-15.9 0-23.8V77.9c0-15.5 12.5-28 28-28H886c17 0 32.9 6.6 45 18.6 11.3 11.3 17.8 26 18.6 41.8 0.1 0.7 0.1 1.4 0.1 2.1v113.2c0 15.5-12.5 28-28 28H708.1z m28-56h157.4v-84.1c0-2-0.8-3.9-2.2-5.4-1.4-1.4-3.4-2.2-5.4-2.2H736.1v91.7zM371.9 254.6c-15.5 0-28-12.5-28-28V78.9c0-15.4 12.5-27.9 27.9-28l213.4-1.1h0.1c17 0 32.9 6.6 45 18.6 12 12.1 18.6 28 18.6 45v113.2c0 15.5-12.5 28-28 28h-249z m28-56.1h193v-85.2c0-2-0.8-3.9-2.2-5.4-1.4-1.4-3.3-2.2-5.3-2.2l-185.5 0.9v91.9z" fill="#595959" ></path><path d="M72.4 974.2c-17.3 0-33.5-6.7-45.7-18.7-12.2-12.1-18.9-28.1-18.9-45.1V113.6c0-35.2 29-63.8 64.6-63.8h169c17.3 0 33.5 6.6 45.7 18.7 12.2 12 18.9 28.1 18.9 45.1V283c0 2 0.8 3.9 2.3 5.4 1.5 1.4 3.4 2.2 5.4 2.2h637.9c17.3 0 33.5 6.6 45.7 18.7 12.2 12 18.9 28 18.9 45.1v556c0 17.1-6.7 33.1-18.9 45.1s-28.4 18.7-45.7 18.7H72.4z m7.7-860.6c-4.3 0-7.7 3.4-7.7 7.6v788.7c0 2 0.8 4 2.3 5.4 1.4 1.4 3.4 2.2 5.4 2.2h871.5c2.1 0 4-0.8 5.4-2.2 1.5-1.4 2.3-3.3 2.3-5.4V350.6c0-2-0.8-3.9-2.2-5.3-1.5-1.5-3.4-2.3-5.4-2.3h-638c-17.3 0-33.5-6.7-45.7-18.7-12.2-12-18.9-28.1-18.9-45.1V121.1c0-2-0.8-3.9-2.3-5.4-1.4-1.4-3.4-2.2-5.4-2.2H80.1z" fill="#595959" ></path></symbol><symbol id="icon-buzhou" viewBox="0 0 1024 1024"><path d="M488.106667 792.462222h257.137777a28.444444 28.444444 0 0 0 28.444445-28.444444 28.444444 28.444444 0 0 0-28.444445-28.444445H488.106667a28.444444 28.444444 0 0 0-28.444445 28.444445 28.444444 28.444444 0 0 0 28.444445 28.444444zM242.346667 764.017778A80.782222 80.782222 0 1 0 341.333333 686.08v-96.142222a80.213333 80.213333 0 0 0 0-155.875556V337.92a80.782222 80.782222 0 1 0-39.822222 0v96.142222a80.213333 80.213333 0 0 0 0 155.875556v96.142222a80.782222 80.782222 0 0 0-59.164444 77.937778zM284.444444 259.982222a40.96 40.96 0 0 1 81.92 0 40.391111 40.391111 0 0 1-40.391111 40.96 40.391111 40.391111 0 0 1-41.528889-40.96zM284.444444 512a40.96 40.96 0 1 1 40.96 40.96A40.96 40.96 0 0 1 284.444444 512z m40.391112 211.057778a40.391111 40.391111 0 0 1 40.391111 40.96 40.96 40.96 0 0 1-81.92 0 40.391111 40.391111 0 0 1 39.253333-40.96zM488.106667 540.444444h257.137777a28.444444 28.444444 0 1 0 0-56.888888H488.106667a28.444444 28.444444 0 1 0 0 56.888888zM488.106667 288.426667h257.137777a28.444444 28.444444 0 0 0 28.444445-28.444445 28.444444 28.444444 0 0 0-28.444445-28.444444H488.106667a28.444444 28.444444 0 0 0-28.444445 28.444444 28.444444 28.444444 0 0 0 28.444445 28.444445z" fill="#151515" ></path><path d="M859.022222 79.644444H164.977778a22.755556 22.755556 0 0 0-22.755556 22.755556v819.2a22.755556 22.755556 0 0 0 22.755556 22.755556h694.044444a22.755556 22.755556 0 0 0 22.755556-22.755556V102.4a22.755556 22.755556 0 0 0-22.755556-22.755556z m-22.755555 819.2H187.733333V125.155556h648.533334z" fill="#151515" ></path></symbol><symbol id="icon-ok" viewBox="0 0 1024 1024"><path d="M926.3 337.9c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.9-35.2-174.3-35.2S394.6 76.2 339.3 99.6c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3-23.4 55.2-35.2 113.9-35.2 174.3 0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c53.3-22.6 101.2-54.8 142.3-96 41.1-41.1 73.4-89 96-142.3 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.8-119.1-35.1-174.3zM513.7 879.1c-202.3 0-366.9-164.6-366.9-366.9s164.6-366.9 366.9-366.9c202.3 0 366.9 164.6 366.9 366.9S716 879.1 513.7 879.1z" ></path><path d="M715.6 371.6c-15.7-15.7-41.4-15.7-57 0l-196 196-95.9-95.9c-15.7-15.7-41.4-15.7-57 0-15.7 15.7-15.7 41.4 0 57l124.5 124.5c15.7 15.7 41.4 15.7 57 0l224.5-224.5c15.6-15.7 15.6-41.4-0.1-57.1z" ></path></symbol><symbol id="icon-cancel" viewBox="0 0 1024 1024"><path d="M926.3 337.9c-22.6-53.3-54.8-101.2-96-142.3-41.1-41.1-89-73.4-142.3-96-55.2-23.4-113.9-35.2-174.3-35.2S394.6 76.2 339.3 99.6c-53.3 22.6-101.2 54.8-142.3 96-41.1 41.1-73.4 89-96 142.3-23.4 55.2-35.2 113.9-35.2 174.3 0 60.4 11.8 119.1 35.2 174.3 22.6 53.3 54.8 101.2 96 142.3 41.1 41.1 89 73.4 142.3 96 55.2 23.4 113.9 35.2 174.3 35.2s119.1-11.8 174.3-35.2c53.3-22.6 101.2-54.8 142.3-96 41.1-41.1 73.4-89 96-142.3 23.4-55.2 35.2-113.9 35.2-174.3 0.1-60.4-11.8-119.1-35.1-174.3zM513.7 879.1c-202.3 0-366.9-164.6-366.9-366.9s164.6-366.9 366.9-366.9c202.3 0 366.9 164.6 366.9 366.9S716 879.1 513.7 879.1z" ></path><path d="M697.9 329.1c-15.6-15.6-41-15.6-56.6 0L513 457.4 384.7 329.1c-15.6-15.6-41-15.6-56.6 0-15.6 15.6-15.6 41 0 56.6L456.4 514 328.1 642.3c-15.6 15.6-15.6 41 0 56.6 15.6 15.6 41 15.6 56.6 0L513 570.6l128.3 128.3c15.6 15.6 41 15.6 56.6 0 15.6-15.6 15.6-41 0-56.6L569.6 514l128.3-128.3c15.6-15.6 15.6-41.1 0-56.6z" ></path></symbol><symbol id="icon-savebaocun" viewBox="0 0 1024 1024"><path d="M778.7 97.2H247.3C165 97.2 98 164.3 98 246.7v532.2c0 82.4 67 149.4 149.3 149.4h531.5c82.3 0 149.3-67 149.3-149.4V246.7C928 164.3 861 97.2 778.7 97.2z m-452.2 79.9h373.1v83.7H331.9c-2.9 0-5.5-2.6-5.5-5.5v-78.2z m373 671.3h-373v-225h373.1v225z m148.7-69.6c0 38.1-30.8 69.2-68.8 69.5V612.9c0-38.3-31.1-69.4-69.3-69.4H316c-38.2 0-69.3 31.1-69.3 69.4v235.4c-38-0.3-68.8-31.4-68.8-69.5V246.7c0-38.1 30.8-69.2 68.8-69.5v78.2c0 47.1 38.3 85.4 85.3 85.4h378c38.2 0 69.3-31.1 69.3-69.4v-94.2c38 0.3 68.8 31.4 68.8 69.5v532.1z" ></path></symbol><symbol id="icon-shijianxian2" viewBox="0 0 1024 1024"><path d="M171.52 924.16v-107.52c0-19.968 15.872-35.84 35.84-35.84s35.84 15.872 35.84 35.84v107.52c0 19.968-15.872 35.84-35.84 35.84s-35.84-15.872-35.84-35.84z m0-322.56v-107.52c0-19.968 15.872-35.84 35.84-35.84s35.84 15.872 35.84 35.84v107.52c0 19.968-15.872 35.84-35.84 35.84s-35.84-15.872-35.84-35.84z m0-394.24v-107.52c0-19.968 15.872-35.84 35.84-35.84s35.84 15.872 35.84 35.84v107.52c0 19.968-15.872 35.84-35.84 35.84s-35.84-15.872-35.84-35.84z" ></path><path d="M350.72 350.72c0 79.36-64 143.36-143.36 143.36s-143.36-64-143.36-143.36 64-143.36 143.36-143.36 143.36 64 143.36 143.36z m-143.36-71.68c-39.424 0-71.68 32.256-71.68 71.68s32.256 71.68 71.68 71.68 71.68-32.256 71.68-71.68-32.256-71.68-71.68-71.68z m143.36 430.08c0 79.36-64 143.36-143.36 143.36s-143.36-64-143.36-143.36 64-143.36 143.36-143.36 143.36 64 143.36 143.36z m-143.36-71.68c-39.424 0-71.68 32.256-71.68 71.68s32.256 71.68 71.68 71.68 71.68-32.256 71.68-71.68-32.256-71.68-71.68-71.68z m716.8-286.72h-501.76c-19.968 0-35.84-15.872-35.84-35.84s15.872-35.84 35.84-35.84h501.76c19.968 0 35.84 15.872 35.84 35.84s-15.872 35.84-35.84 35.84z m-284.672 107.52H420.352c-18.432 0-33.792-15.36-33.792-33.792v-4.096c0-18.432 15.36-33.792 33.792-33.792h219.136c18.432 0 33.792 15.36 33.792 33.792v4.096c0 18.432-15.36 33.792-33.792 33.792z m284.672 250.88h-501.76c-19.968 0-35.84-15.872-35.84-35.84s15.872-35.84 35.84-35.84h501.76c19.968 0 35.84 15.872 35.84 35.84s-15.872 35.84-35.84 35.84z m-284.672 107.52H420.352c-18.432 0-33.792-15.36-33.792-33.792v-4.096c0-18.432 15.36-33.792 33.792-33.792h219.136c18.432 0 33.792 15.36 33.792 33.792v4.096c0 18.432-15.36 33.792-33.792 33.792z" ></path></symbol><symbol id="icon-buzhoutiao" viewBox="0 0 1024 1024"><path d="M0 0h1024v1024H0z" fill="#FFFFFF" fill-opacity="0" ></path><path d="M204 372c66.31 0 121.852 46.1 136.326 108h137.53c12.901-33.907 45.71-58 84.144-58 38.435 0 71.243 24.093 84.145 58h139.71c12.902-33.907 45.71-58 84.145-58 49.706 0 90 40.294 90 90s-40.294 90-90 90c-38.434 0-71.242-24.092-84.144-57.998H646.144C633.242 577.908 600.434 602 562 602c-38.434 0-71.242-24.092-84.144-57.998h-137.53C325.852 605.9 270.309 652 204 652c-77.32 0-140-62.68-140-140s62.68-140 140-140z m0 64c-41.974 0-76 34.026-76 76s34.026 76 76 76 76-34.026 76-76-34.026-76-76-76z m358 50c-14.36 0-26 11.64-26 26s11.64 26 26 26 26-11.64 26-26-11.64-26-26-26z m308 0c-14.36 0-26 11.64-26 26s11.64 26 26 26 26-11.64 26-26-11.64-26-26-26z" fill="#666666" ></path></symbol><symbol id="icon-m-qianming" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M573.44 646.656l-3.072 6.144c-8.192 12.288-14.336 25.088-19.456 38.912-6.656 18.944-3.072 36.352 16.896 43.008 34.816 11.264 72.704 9.216 106.496-4.608 9.216-3.072 11.264-4.096 34.304-12.8 16.384-6.656 33.792-12.8 51.2-17.408 1.024 0 2.048-0.512 3.072-1.024 10.24-2.048 6.656-5.632 16.896 1.024 3.584 3.072 8.704 4.096 13.312 3.072 4.608-1.024 5.632-3.072 8.192-7.68 5.632-8.192 3.584-19.456-4.608-25.088-18.944-12.8-22.528-10.24-41.472-6.144-1.536 0.512-3.072 0.512-4.096 1.024-18.944 5.12-37.376 11.264-55.808 18.432-22.016 8.704-24.064 9.728-32.768 12.288-24.576 10.24-52.224 12.8-78.336 6.144 4.608-11.264 10.24-22.016 16.896-32.256 1.536-2.048 2.56-4.096 3.584-6.144 8.704-13.824 15.36-29.184 18.432-45.056 4.096-19.456-7.68-38.4-27.136-42.496-0.512 0-1.536-0.512-2.048-0.512-27.648-6.656-59.392 3.072-148.992 37.888-81.92 32.256-117.76 41.984-129.024 35.84-4.096-2.56-8.704-3.072-13.312-1.536-9.728 2.56-15.36 12.8-12.8 22.016 1.024 4.608 4.096 8.192 8.192 10.752 23.04 8.704 48.64 7.68 71.168-2.048 29.696-9.216 59.392-19.456 88.064-32.256 77.824-30.72 111.104-40.448 126.976-36.352 3.072 1.024 3.072 0 2.56 3.072-2.56 12.288-7.168 23.552-13.312 33.792zM665.088 235.52c-19.456-17.92-49.664-17.408-68.608 1.024L312.32 519.68c-2.048 2.048-3.584 4.608-4.608 7.68l-22.528 80.896c-2.56 9.728 3.072 19.456 12.8 21.504 3.584 1.024 7.68 0.512 11.264-0.512l71.168-29.696c5.632-2.56 10.752-5.632 15.36-10.24l283.648-269.824 2.56-2.56c18.432-19.456 17.92-50.176-2.048-68.608l-1.024-1.024-13.824-11.776z" ></path></symbol><symbol id="icon-touxiang_avatar" viewBox="0 0 1024 1024"><path d="M925.866667 797.866667c-12.8-25.6-34.133333-46.933333-64-64-29.866667-21.333333-68.266667-34.133333-119.466667-42.666667-4.266667 0-29.866667-4.266667-59.733333-12.8-21.333333-4.266667-34.133333-8.533333-38.4-12.8v-17.066667c4.266667-51.2 29.866667-76.8 55.466666-106.666666 8.533333-8.533333 17.066667-21.333333 25.6-29.866667 29.866667-42.666667 34.133333-89.6 34.133334-98.133333 0-8.533333 0-17.066667-4.266667-21.333334-4.266667-8.533333-8.533333-12.8-12.8-21.333333 0-12.8 4.266667-21.333333 4.266667-29.866667 0-21.333333 4.266667-55.466667-4.266667-89.6 0-8.533333-4.266667-12.8-4.266667-21.333333-8.533333-25.6-17.066667-46.933333-34.133333-68.266667-4.266667-12.8-64-72.533333-234.666667-85.333333H401.066667c-4.266667 0-17.066667 0-25.6 4.266667-21.333333 4.266667-38.4 21.333333-42.666667 42.666666v21.333334c-8.533333 8.533333-55.466667 51.2-55.466667 102.4-4.266667 34.133333-4.266667 85.333333 0 123.733333-8.533333 8.533333-17.066667 21.333333-12.8 42.666667 0 12.8 4.266667 55.466667 34.133334 98.133333 8.533333 8.533333 17.066667 17.066667 25.6 29.866667 25.6 29.866667 51.2 55.466667 55.466666 106.666666v17.066667c-4.266667 4.266667-17.066667 8.533333-38.4 12.8-29.866667 8.533333-59.733333 12.8-64 12.8-46.933333 8.533333-85.333333 21.333333-115.2 42.666667-25.6 17.066667-46.933333 38.4-64 64-25.6 38.4-25.6 76.8-25.6 85.333333v21.333333c0 25.6 21.333333 46.933333 46.933334 46.933334H896c25.6 0 46.933333-21.333333 46.933333-46.933334v-17.066666c8.533333-12.8 8.533333-51.2-17.066666-89.6z m-546.133334-128c0 4.266667 0 4.266667 0 0v4.266666c-4.266667 0-4.266667 0 0-4.266666z m503.466667 213.333333l-742.4 4.266667v-4.266667s0-25.6 12.8-51.2c8.533333-17.066667 25.6-29.866667 42.666667-42.666667 25.6-17.066667 55.466667-25.6 89.6-34.133333 4.266667 0 34.133333-4.266667 68.266666-12.8 51.2-12.8 76.8-29.866667 85.333334-46.933333 0-4.266667 0-4.266667 4.266666-8.533334v-42.666666c-8.533333-72.533333-42.666667-115.2-72.533333-145.066667-8.533333-8.533333-12.8-17.066667-21.333333-21.333333-21.333333-29.866667-21.333333-59.733333-21.333334-64l4.266667-4.266667 8.533333-8.533333c4.266667-17.066667 0-25.6 0-29.866667-4.266667-34.133333-4.266667-81.066667 0-119.466667 0-29.866667 29.866667-55.466667 29.866667-55.466666 8.533333-4.266667 17.066667-12.8 21.333333-21.333334 0-4.266667 4.266667-4.266667 4.266667-8.533333v-25.6H465.066667c140.8 8.533333 192 59.733333 192 59.733333 8.533333 12.8 17.066667 25.6 21.333333 42.666667 4.266667 4.266667 4.266667 8.533333 4.266667 12.8 4.266667 29.866667 4.266667 55.466667 4.266666 76.8 0 12.8 0 21.333333-4.266666 38.4 0 12.8 0 25.6 8.533333 29.866667l4.266667 4.266666 4.266666 4.266667s0 34.133333-21.333333 64c-4.266667 8.533333-12.8 12.8-21.333333 21.333333-29.866667 29.866667-64 72.533333-72.533334 145.066667v42.666667c0 4.266667 0 4.266667 4.266667 8.533333 8.533333 21.333333 34.133333 34.133333 85.333333 46.933333 34.133333 8.533333 64 12.8 68.266667 12.8 38.4 8.533333 68.266667 17.066667 93.866667 34.133334 17.066667 12.8 34.133333 25.6 42.666666 42.666666 8.533333 25.6 8.533333 51.2 4.266667 55.466667z" ></path></symbol><symbol id="icon-m-mianban" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M884.15744 348.01152v49.152h-745.984v-49.152z" ></path><path d="M356.43392 846.99136h-49.152v-450.048h49.152z" ></path></symbol><symbol id="icon-m-xialakuang" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M510.464 639.488l207.872-254.976H302.08z" ></path></symbol><symbol id="icon-m-biaodan" viewBox="0 0 1024 1024"><path d="M122.88 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384H122.88c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H137.216c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M244.224 279.04h142.848v49.152H244.224zM244.224 425.472h142.848v49.152H244.224zM436.736 279.04h342.528v49.152H436.736zM436.736 425.472h342.528v49.152H436.736zM244.224 572.416h142.848v49.152H244.224zM436.736 572.416h342.528v172.544H436.736z" ></path></symbol><symbol id="icon-m-biaoge" viewBox="0 0 1024 1024"><path d="M122.368 165.888h778.24c-9.216 0-16.384-7.168-16.384-16.384v713.728c0-9.216 7.168-16.384 16.384-16.384h-778.24c9.216 0 16.384 7.168 16.384 16.384V150.016c0 8.192-6.656 15.872-16.384 15.872z m-32.768 684.544c0 26.112 20.992 47.104 47.104 47.104h750.08c26.112 0 47.104-20.992 47.104-47.104V162.304c0-26.112-20.992-47.104-47.104-47.104H136.704c-26.112 0-47.104 20.992-47.104 47.104v688.128z" ></path><path d="M249.344 347.648h49.152v499.2h-49.152zM584.704 347.648h49.152v499.2h-49.152zM137.728 165.888h746.496v181.76H137.728z" ></path><path d="M137.728 481.792h746.496v49.152H137.728zM137.728 664.576h746.496v49.152H137.728z" ></path></symbol><symbol id="icon-dashboard-o" viewBox="0 0 1024 1024"><path d="M880 622c17.673 0 32 14.327 32 32v226c0 17.673-14.327 32-32 32H582c-17.673 0-32-14.327-32-32V654c0-17.673 14.327-32 32-32h298zM442 476c17.673 0 32 14.327 32 32v372c0 17.673-14.327 32-32 32H144c-17.673 0-32-14.327-32-32V508c0-17.673 14.327-32 32-32h298z m406 210H614v162h234V686zM410 540H176v308h234V540z m470-428c17.673 0 32 14.327 32 32v372c0 17.673-14.327 32-32 32H582c-17.673 0-32-14.327-32-32V144c0-17.673 14.327-32 32-32h298z m-32 64H614v308h234V176z m-406-64c17.673 0 32 14.327 32 32v226c0 17.673-14.327 32-32 32H144c-17.673 0-32-14.327-32-32V144c0-17.673 14.327-32 32-32h298z m-32 64H176v162h234V176z" fill="#000000" fill-opacity=".65" ></path></symbol><symbol id="icon-line-layoutmasonryfensanbuju" viewBox="0 0 1024 1024"><path d="M896 128H128c-25.6 0-42.666667 17.066667-42.666667 42.666667v682.666666c0 25.6 17.066667 42.666667 42.666667 42.666667h768c25.6 0 42.666667-17.066667 42.666667-42.666667V170.666667c0-25.6-17.066667-42.666667-42.666667-42.666667zM170.666667 213.333333h298.666666v341.333334H170.666667V213.333333z m0 597.333334v-170.666667h298.666666v170.666667H170.666667z m682.666666 0h-298.666666v-341.333334h298.666666v341.333334z m0-426.666667h-298.666666V213.333333h298.666666v170.666667z" fill="#09121F" ></path></symbol><symbol id="icon-zidingyibuju" viewBox="0 0 1024 1024"><path d="M0 0v256h1024V0z m960 192H64V64h896zM0 1024h512V320H0z m64-640h384v576H64zM576 576h448v-256H576z m64-192h320v128H640zM576 1024h448V640H576z m64-320h320v256H640z" fill="#575869" ></path></symbol><symbol id="icon-daochu" viewBox="0 0 1024 1024"><path d="M394.6 689.8c-13.2 3.2-27.4-9.5-31.7-23.2-8.4-28.5-12.7-58.6-12.7-88.1 0-159.4 151.5-325.1 314.1-352.1v-5.3c0-1.6 0-3.7 0.5-5.3l0.5-2.1c1.6-11.6 5.8-38.5 32.2-55.4 10.6-6.9 22.2-10 34.3-10 14.8 0 26.9 5.3 34.3 9.5 1.6 0.5 2.6 1.6 4.2 2.6L929.2 286c17.4 13.2 28 34.8 28 57 0 22.7-10.6 44.3-28.5 57.5L770.5 525.7c-11.6 9-25.3 13.7-39.1 13.7-12.1 0-23.8-3.7-34.8-10.6-21.1-13.7-31.7-34.8-31.7-64.4v-1.1C559.3 475 442.2 569 416.3 657.6c-4.8 14.3-13.7 32.2-21.7 32.2z m335.7-466.6V256c0 17.4-13.7 31.7-31.1 32.7-125.6 6.9-257.6 131.4-279.7 254.4C486 458.7 595.2 390 699.7 397.4c17.4 1.1 30.6 15.3 30.6 32.7V465c0 4.7 0.5 6.9 0.5 7.9l157.3-124.6c2.1-1.6 2.6-3.2 2.6-5.3 0-2.1-1.1-4.2-2.6-5.3L731.9 214.3c-1.1 1.6-1.6 5.8-2.1 8.4l0.5 0.5z m0 0" ></path><path d="M715.6 916.3H188.3c-67 0-121.9-54.9-121.9-121.9v-568c0-67 54.9-121.9 121.9-121.9h436.5v69.7H188.3c-28.5 0-52.3 23.2-52.3 52.3V795c0 28.5 23.2 52.3 52.3 52.3h527.3c28.5 0 52.3-23.2 52.3-52.3V593.2H837v201.6c0 66.6-54.4 121.5-121.4 121.5z m0 0" ></path><path d="M183 566.9h112.4V626H183v-59.1z m0 154.1h296.1v59.1H183V721z m0-425.4h237v59.1H183v-59.1z m0 140.9h112.4v59.1H183v-59.1z m0 0" ></path></symbol><symbol id="icon-daoru" viewBox="0 0 1024 1024"><path d="M111.6 148.8c7.9 0 16.9 17.9 21.6 32.2 25.9 88.7 143 182.6 248.6 194.2v-1.1c0-29.6 10.6-50.7 31.7-64.4 11.1-6.9 22.7-10.6 34.8-10.6 13.7 0 27.4 4.8 39.1 13.7L645.8 438c17.9 13.2 28.5 34.8 28.5 57.5 0 22.2-10.6 43.8-28 57L487.4 678.2c-1.6 1.1-2.6 2.1-4.2 2.6-7.4 4.2-19.5 9.5-34.3 9.5-12.1 0-23.7-3.2-34.3-10-26.4-16.9-30.6-43.8-32.2-55.4l-0.5-2.1c-0.5-1.6-0.5-3.7-0.5-5.3v-5.3c-162.6-26.9-314.1-192.6-314.1-352 0-29.6 4.2-59.6 12.7-88.1 4.2-13.8 18.4-26.5 31.6-23.3z m335.2 467.1c0.5 2.6 1.1 6.9 2.1 8.4l156.2-123.5c1.6-1.1 2.6-3.2 2.6-5.3 0-2.1-0.5-3.7-2.6-5.3L447.8 365.7c0 1.1-0.5 3.2-0.5 7.9v34.8c0 17.4-13.2 31.7-30.6 32.7-104.5 7.4-213.8-61.2-280.3-145.7 22.2 123 154.1 247.5 279.7 254.4 17.4 1.1 31.1 15.3 31.1 32.7v32.7l-0.4 0.7z m0.5-0.5" ></path><path d="M309 916.3c-67 0-121.4-54.9-121.4-121.4V593.2h69.1v201.6c0 29 23.8 52.3 52.3 52.3h527.3c29 0 52.3-23.8 52.3-52.3V226.4c0-29-23.8-52.3-52.3-52.3H399.8v-69.7h436.5c67 0 121.9 54.9 121.9 121.9v567.9c0 67-54.9 121.9-121.9 121.9H309v0.2z m0 0" ></path><path d="M841.6 626H729.1v-59.1h112.4V626z m0 154.1H545.5V721h296.1v59.1z m0-425.4h-237v-59.1h237v59.1z m0 140.9H729.1v-59.1h112.4v59.1z m0-59.1" ></path></symbol><symbol id="icon-a-juxing1851" viewBox="0 0 1024 1024"><path d="M0 0h438.857143v1024H0V0z m512 0h512v438.857143H512V0z m0 512h219.428571v219.428571H512V512z m292.571429 0h219.428571v219.428571h-219.428571V512z m-292.571429 292.571429h73.142857v73.142857H512v-73.142857z m146.285714 0h73.142857v73.142857H658.285714v-73.142857z m-146.285714 146.285714h73.142857v73.142857H512v-73.142857z m146.285714 0h73.142857v73.142857H658.285714v-73.142857z m146.285715 0h73.142857v73.142857h-73.142857v-73.142857z m146.285714 0h73.142857v73.142857h-73.142857v-73.142857z m-146.285714-146.285714h73.142857v73.142857h-73.142857v-73.142857z m146.285714 0h73.142857v73.142857h-73.142857v-73.142857z" ></path></symbol><symbol id="icon-sxsz" viewBox="0 0 1024 1024"><path d="M304.5 152.6h415L927 512 719.5 871.4h-415L97 512z" fill="#386BF3" ></path><path d="M512 512m-145.25 0a145.25 145.25 0 1 0 290.5 0 145.25 145.25 0 1 0-290.5 0Z" fill="#3D4265" ></path></symbol><symbol id="icon-mx" viewBox="0 0 1024 1024"><path d="M511.9 325.12v248.55L727.15 449.4l-0.01-248.55z" fill="#C3D2FB" ></path><path d="M296.65 200.85L511.9 325.12v248.56L296.65 449.4z" fill="#3D4265" ></path><path d="M511.9 325.12l215.25-124.27L511.9 76.57 296.65 200.85z" fill="#386BF3" ></path><path d="M296.62 698.02v248.55L511.87 822.3l-0.01-248.56z" fill="#C3D2FB" ></path><path d="M81.37 573.74l215.25 124.28v248.55L81.37 822.3z" fill="#3D4265" ></path><path d="M296.62 698.02l215.25-124.28-215.25-124.27L81.37 573.74z" fill="#386BF3" ></path><path d="M727.03 698.02v248.55L942.28 822.3l-0.01-248.56z" fill="#C3D2FB" ></path><path d="M511.78 573.74l215.25 124.28v248.55L511.78 822.3z" fill="#3D4265" ></path><path d="M727.03 698.02l215.25-124.28-215.25-124.27-215.25 124.27z" fill="#386BF3" ></path></symbol><symbol id="icon-al" viewBox="0 0 1024 1024"><path d="M192 132h440v640H192z" fill="#386BF3" ></path><path d="M632 260h200v512H632z" fill="#C3D2FB" ></path><path d="M398.86 612L512 725.14 625.14 612H912v280H112V612z" fill="#3D4265" ></path></symbol><symbol id="icon-sf" viewBox="0 0 1024 1024"><path d="M511.82 512.5v435L888.54 730l-0.02-435z" fill="#C3D2FB" ></path><path d="M135.1 295l376.72 217.5v435L135.1 730z" fill="#3D4265" ></path><path d="M511.82 512.5L888.54 295 511.82 77.5 135.1 295z" fill="#386BF3" ></path></symbol><symbol id="icon-moxing" viewBox="0 0 1061 1024"><path d="M447.122 467.332L49.24 268.162A33.501 33.501 0 0 0 0.136 300.745v441.02a33.042 33.042 0 0 0 16.062 27.994l396.965 248.275a33.96 33.96 0 0 0 17.438 5.507 33.042 33.042 0 0 0 33.043-33.042V497.162a33.042 33.042 0 0 0-16.522-29.83z m598.889-203.76a33.042 33.042 0 0 0-31.666 0l-463.507 203.76a33.042 33.042 0 0 0-19.733 30.289v493.337a33.042 33.042 0 0 0 49.563 28.453l463.048-265.255a33.042 33.042 0 0 0 16.521-28.453V291.566a33.042 33.042 0 0 0-14.226-27.994z m-54.611-84.9a33.042 33.042 0 0 0-22.487-29.83L550.838 1.53a32.583 32.583 0 0 0-19.733 0L83.659 158.021a33.042 33.042 0 0 0-4.13 61.036l397.882 199.17a33.501 33.501 0 0 0 14.685 3.213 33.96 33.96 0 0 0 13.31 0L969.37 215.845a33.042 33.042 0 0 0 22.029-37.173z" fill="#5E5C5C" ></path></symbol><symbol id="icon-yanzhengyanzhengma" viewBox="0 0 1024 1024"><path d="M943.1 172c-2.4-0.2-245.1-25.3-413.8-147.8-5.1-3.7-11-5.6-17.3-5.6-6.2 0-12.2 1.9-17.3 5.6C326.9 146 83.3 171.8 80.9 172c-15.2 1.4-26.6 14.1-26.6 29.3 0 6.7 0.6 165.8 54.8 344.4 32.1 105.8 76.4 196.4 131.9 269.2 70.3 92.3 158.5 156 262 189.2 2.9 0.9 5.9 1.4 9 1.4s6.1-0.5 8.9-1.4c103.6-33.2 191.7-96.8 262-189.2 55.4-72.7 99.8-163.2 131.9-269.2 54.1-178.6 54.8-337.7 54.8-344.4C969.7 186.1 958.3 173.5 943.1 172zM910.1 227.2l-0.1 1.6c-2.9 58.1-13.4 174.4-51.4 299.9-66.7 220.1-183.1 360.1-346 416.1L512 945l-0.6-0.2C349 888.9 232.7 749.4 165.8 530.1c-39.8-130.5-49.4-254.2-51.8-301.4l-0.1-1.6 1.5-0.2c70.6-10.3 250.5-44.8 395.5-142.4l0.9-0.7 1 0.7C658 182.1 837.9 216.6 908.5 227L910.1 227.2z" ></path><path d="M641.8 351 467 580.3l-89-76.1c-5.3-4.5-12.1-7-19.1-7-8.6 0-16.8 3.7-22.4 10.3-10.5 12.3-9.1 31 3.3 41.5l112.7 96.4c5.2 4.4 12.4 7 19.6 7 0.9 0 1.8 0 2.7-0.1 8-0.8 15.4-5 20.3-11.4l193.7-254c4.8-6.3 6.8-14 5.7-21.8-1-7.8-5.1-14.7-11.3-19.5C670.1 335.6 651.6 338.1 641.8 351z" ></path></symbol><symbol id="icon-verify" viewBox="0 0 1024 1024"><path d="M713.856 93.44c44.672 9.344 79.36 15.488 105.024 18.944a332.8 332.8 0 0 0 28.864 3.008A110.08 110.08 0 0 1 944 223.36v348.672c0 71.232-36.288 168.32-80.704 219.328a737.216 737.216 0 0 1-100.672 106.496C683.264 966.208 599.232 1008 512 1008s-171.328-41.792-250.624-110.144c-26.88-23.168-51.2-47.808-72.832-72.512a409.152 409.152 0 0 1-24.768-30.208c-47.68-52.928-83.776-150.4-83.776-223.104V223.36c0-54.72 42.752-102.528 99.264-108.096 5.76-0.32 17.536-1.408 34.432-3.648a953.6 953.6 0 0 0 95.168-17.92c19.392-4.608 34.944-12.16 65.92-30.4l9.984-5.888C434.048 28.416 466.432 16 512 16c39.296 0 68.288 11.84 127.488 43.968l2.304 1.28c38.784 21.056 55.296 28.672 72.064 32.192z m-19.712 93.952c-29.376-6.144-50.688-16-98.176-41.856l-2.304-1.216C549.312 120.32 529.088 112 512 112c-24.192 0-42.88 7.168-78.656 28.16-4.736 2.88-4.736 2.88-9.728 5.76-38.784 22.912-61.12 33.664-92.48 41.216-37.76 8.96-72.96 15.36-104.768 19.648a556.8 556.8 0 0 1-39.68 4.16c-5.12 0.512-10.688 6.784-10.688 12.416v348.672c0 49.344 27.52 123.84 62.08 162.56a642.176 642.176 0 0 0 85.952 90.56c63.552 54.72 128.192 86.848 187.968 86.848 59.776 0 124.416-32.128 187.968-86.848a642.176 642.176 0 0 0 88.32-93.632c31.808-36.608 59.712-111.36 59.712-159.488V223.36c0-5.44-5.888-12.032-6.656-12.288-20.288-0.448-66.112-6.72-147.2-23.68zM400.128 488.704L487.68 576.256l185.088-185.088a48 48 0 0 1 67.84 67.84L521.6 678.144a48 48 0 0 1-67.84 0l-121.6-121.536a48 48 0 1 1 67.968-67.84z" fill="#768893" ></path></symbol><symbol id="icon-preview" viewBox="0 0 1024 1024"><path d="M854.36155804 32.02835121a114.60838884 114.60838884 0 0 1 114.21544637 105.17775738l0.39294247 9.43063278v170.60277392a49.1178817 49.1178817 0 0 1-97.77732893 6.68003145l-0.45843311-6.68003145V146.63674137a16.37262679 16.37262679 0 0 0-12.63966726-15.9796843l-3.73295954-0.39294246H130.1675186a16.37262679 16.37262679 0 0 0-15.91419368 12.57417659l-0.45843312 3.79845017v732.18388095a16.37262679 16.37262679 0 0 0 12.63966859 15.91419369l3.73295821 0.4584331h275.4530781a49.1178817 49.1178817 0 0 1 6.68003143 97.77732894l-6.68003143 0.4584331H130.1675186a114.60838884 114.60838884 0 0 1-114.21544639-105.24324667l-0.39294246-9.36514216V146.63674137a114.60838884 114.60838884 0 0 1 105.24324669-114.28093698l9.36514216-0.32745318h724.19403944z m-286.32450218 495.1082417a235.76582919 235.76582919 0 0 1 358.88798459 303.35203402l80.61881587 80.55332523a39.29430509 39.29430509 0 0 1-55.53595059 55.66693187l-80.61881589-80.61881587a235.83131983 235.83131983 0 0 1-303.35203398-358.88798459z m277.87622625 55.60144257a157.17721902 157.17721902 0 1 0-222.27478502 222.2747837 157.17721902 157.17721902 0 0 0 222.27478502-222.2747837z m-450.70567639-33.26917864a42.56883017 42.56883017 0 1 1 0 85.13766035H210.39339064a42.56883017 42.56883017 0 1 1 0-85.13766035h184.81421508z m0-158.68350096a42.56883017 42.56883017 0 1 1 0 85.13766036H210.39339064a42.56883017 42.56883017 0 1 1 0-85.13766036h184.81421508z m233.67013285-158.68350095a42.56883017 42.56883017 0 1 1 0 85.13766036h-418.48434793a42.56883017 42.56883017 0 1 1 0-85.13766036h418.48434793z" fill="#7f7f7f" ></path></symbol><symbol id="icon-yunshangchuan-xian" viewBox="0 0 1039 1024"><path d="M711.40656 345.248C667.88656 248.448 594.91056 208 481.83856 208c-118.848 0-219.328 96.512-256.736 267.76l-4.96 22.752-23.2 2.256c-83.744 8.192-120.176 54.176-131.36 144.4C54.30256 736.528 103.18256 816 193.85456 816h190.672a32 32 0 1 1 0 64H193.83856C58.68656 880-13.44144 762.72 2.07856 637.296 15.61456 528 65.80656 458.416 167.75856 440.224 215.27856 254.704 335.99856 144 481.83856 144c143.072 0 241.184 58.72 294.24 189.808 3.328-0.176 6.576-0.272 9.76-0.272 125.184 0 223.68 93.696 239.84 252.768 0.896 8.96 1.36 17.952 1.36 26.96C1027.03856 760.576 907.61456 880 760.30256 880h-120.064a32 32 0 1 1 0-64h120.064c111.968 0 202.72-90.768 202.72-202.736 0-6.848-0.32-13.68-1.024-20.48-12.912-127.088-84.544-195.248-176.16-195.248-23.136 0-55.68 7.232-96.928 22.032a32 32 0 1 1-21.616-60.224c15.584-5.6 30.288-10.304 44.112-14.08zM544.23856 598.512V848a32 32 0 0 1-64 0V598.512l-39.712 46.32a32 32 0 1 1-48.592-41.664l95.632-111.552a32.032 32.032 0 0 1 49.344 0l95.616 111.552a32 32 0 0 1-48.592 41.664l-39.696-46.32z" ></path></symbol><symbol id="icon-yulan" viewBox="0 0 1024 1024"><path d="M897.28 85.333333h-750.933333c-28.16 0-51.2 23.04-51.2 51.2v750.933334c0 28.16 23.04 51.2 51.2 51.2h276.906666c18.773333 0 34.133333-15.36 34.133334-34.133334s-15.36-34.133333-34.133334-34.133333H163.413333V153.6h716.8v275.626667c0 18.773333 15.36 34.133333 34.133334 34.133333s34.133333-15.36 34.133333-34.133333V136.533333c0-28.16-22.613333-51.2-51.2-51.2z" fill="#4C4C4C" ></path><path d="M649.813333 315.733333h-324.266666c-18.773333 0-34.133333-15.36-34.133334-34.133333s15.36-34.133333 34.133334-34.133333h324.266666c18.773333 0 34.133333 15.36 34.133334 34.133333s-14.933333 34.133333-34.133334 34.133333zM564.48 452.266667h-238.933333c-18.773333 0-34.133333-15.36-34.133334-34.133334s15.36-34.133333 34.133334-34.133333h238.933333c18.773333 0 34.133333 15.36 34.133333 34.133333s-14.933333 34.133333-34.133333 34.133334zM479.146667 588.8h-153.6c-18.773333 0-34.133333-15.36-34.133334-34.133333s15.36-34.133333 34.133334-34.133334h153.6c18.773333 0 34.133333 15.36 34.133333 34.133334s-14.933333 34.133333-34.133333 34.133333zM724.48 544c-94.293333 0-170.666667 76.373333-170.666667 170.666667s76.373333 170.666667 170.666667 170.666666 170.666667-76.373333 170.666667-170.666666-76.373333-170.666667-170.666667-170.666667z m0 273.066667c-56.32 0-102.4-46.08-102.4-102.4s46.08-102.4 102.4-102.4 102.4 46.08 102.4 102.4-45.653333 102.4-102.4 102.4z" fill="#4C4C4C" ></path><path d="M938.666667 928.853333c-13.226667 13.226667-34.986667 13.226667-48.213334 0l-72.533333-72.533333c-13.226667-13.226667-13.226667-34.986667 0-48.213333 13.226667-13.226667 34.986667-13.226667 48.213333 0l72.533334 72.533333c13.226667 13.226667 13.226667 34.56 0 48.213333z" fill="#4C4C4C" ></path></symbol><symbol id="icon-sousuo" viewBox="0 0 1024 1024"><path d="M1004.8 915.2l-243.2-243.2c0 0-6.4-6.4-6.4-6.4C800 595.2 832 505.6 832 416 832 185.6 646.4 0 416 0S0 185.6 0 416 185.6 832 416 832c89.6 0 179.2-32 243.2-83.2 0 6.4 6.4 6.4 6.4 6.4l243.2 243.2c25.6 25.6 70.4 25.6 96 6.4C1030.4 979.2 1030.4 940.8 1004.8 915.2zM64 416C64 224 224 64 416 64S768 224 768 416 608 768 416 768 64 608 64 416z" fill="#231815" ></path></symbol><symbol id="icon-ziliucheng" viewBox="0 0 1024 1024"><path d="M212.992 526.336 212.992 526.336 212.992 526.336 215.04 526.336 212.992 526.336Z" ></path><path d="M813.056 768l96.256 0c20.48 0 38.912 16.384 38.912 38.912l0 96.256c0 20.48-16.384 38.912-38.912 38.912l-96.256 0c-20.48 0-38.912-16.384-38.912-38.912l0-38.912-18.432 0c-53.248 0-96.256-43.008-96.256-96.256L659.456 614.4l-96.256 0 0 192.512c0 20.48-16.384 38.912-38.912 38.912L120.832 845.824c-20.48 0-38.912-16.384-38.912-38.912L81.92 401.408c0-20.48 16.384-38.912 38.912-38.912l192.512 0L313.344 190.464 120.832 190.464C98.304 190.464 81.92 174.08 81.92 151.552L81.92 112.64c0-20.48 16.384-38.912 38.912-38.912l788.48 0c20.48 0 38.912 16.384 38.912 38.912l0 38.912c0 20.48-16.384 38.912-38.912 38.912L331.776 190.464l0 174.08 192.512 0c20.48 0 38.912 16.384 38.912 38.912L563.2 593.92l96.256 0 0-153.6c0-53.248 43.008-96.256 96.256-96.256l18.432 0 0-38.912c0-20.48 16.384-38.912 38.912-38.912l96.256 0c20.48 0 38.912 16.384 38.912 38.912l0 96.256c0 20.48-16.384 38.912-38.912 38.912l-96.256 0c-20.48 0-38.912-16.384-38.912-38.912l0-38.912-18.432 0c-43.008 0-77.824 34.816-77.824 77.824L677.888 593.92l96.256 0 0-38.912c0-20.48 16.384-38.912 38.912-38.912l96.256 0c20.48 0 38.912 16.384 38.912 38.912l0 96.256c0 20.48-16.384 38.912-38.912 38.912l-96.256 0c-20.48 0-38.912-16.384-38.912-38.912L774.144 614.4l-96.256 0 0 153.6c0 43.008 34.816 77.824 77.824 77.824l18.432 0 0-38.912C774.144 784.384 792.576 768 813.056 768z" ></path></symbol><symbol id="icon-danyuange" viewBox="0 0 1024 1024"><path d="M467.970999 661.248453h-184.831769a70.655912 70.655912 0 0 0-54.527932 25.599968A82.431897 82.431897 0 0 0 204.803328 744.19235v196.607754A82.687897 82.687897 0 0 0 228.611298 998.400032a71.423911 71.423911 0 0 0 54.527932 25.599968h184.831769a73.727908 73.727908 0 0 0 55.039931-25.599968 81.919898 81.919898 0 0 0 23.551971-58.623927v-195.583755a81.919898 81.919898 0 0 0-23.551971-58.367927 72.959909 72.959909 0 0 0-55.039931-25.599968z m5.887993-84.991893A118.015852 118.015852 0 0 0 512.002944 549.376593 127.99984 127.99984 0 0 0 545.538902 460.800704V126.465122A133.119834 133.119834 0 0 0 537.602912 76.801184a123.391846 123.391846 0 0 0-25.599968-40.447949 118.015852 118.015852 0 0 0-37.119954-25.599968A104.703869 104.703869 0 0 0 428.547048 0.00128H116.995438A105.471868 105.471868 0 0 0 71.683494 9.985268a121.087849 121.087849 0 0 0-37.119953 25.599968A127.99984 127.99984 0 0 0 9.219572 76.801184 133.119834 133.119834 0 0 0 0.003584 126.465122V460.800704a127.99984 127.99984 0 0 0 34.559957 88.31989 121.087849 121.087849 0 0 0 37.119953 27.135966 105.471868 105.471868 0 0 0 45.311944 9.983987h311.55161a106.239867 106.239867 0 0 0 45.311944-9.983987z m527.35934-329.215589a71.67991 71.67991 0 0 0-54.783931-25.599968h-184.575769a72.959909 72.959909 0 0 0-55.295931 25.599968 81.919898 81.919898 0 0 0-23.551971 58.367927v195.583756a83.199896 83.199896 0 0 0 23.551971 59.647925 73.983908 73.983908 0 0 0 55.295931 25.599968H947.2024a72.447909 72.447909 0 0 0 54.783932-25.599968 84.991894 84.991894 0 0 0 22.015972-59.647925v-195.583756a82.943896 82.943896 0 0 0-22.783972-58.367927zM947.2024 661.248453h-185.343768a72.959909 72.959909 0 0 0-55.295931 25.599968 81.919898 81.919898 0 0 0-23.551971 58.367927v196.607755A81.919898 81.919898 0 0 0 706.562701 998.400032a73.983908 73.983908 0 0 0 55.295931 25.599968H947.2024a72.447909 72.447909 0 0 0 54.783932-25.599968 83.455896 83.455896 0 0 0 22.015972-57.599928v-196.607754a83.199896 83.199896 0 0 0-22.783972-58.367927 71.67991 71.67991 0 0 0-54.783931-25.599968z m0 0" ></path></symbol><symbol id="icon-rengongzhineng_filledbeifen" viewBox="0 0 1024 1024"><path d="M913.678222 374.556444c0-175.431111-160.782222-317.653333-359.139555-317.653333a382.577778 382.577778 0 0 0-254.663111 93.767111 270.108444 270.108444 0 0 0-91.335112 118.840889 318.350222 318.350222 0 0 0-20.849777 98.773333c-0.597333 38.840889 18.389333 76.871111 1.664 114.688-11.633778 26.453333-41.870222 48.824889-61.312 69.916445 0 0-54.442667 36.224 49.436444 41.173333 2.929778 0.142222 16.071111 62.222222 19.342222 76.430222a16.753778 16.753778 0 0 0-3.271111 10.752c0 11.904 15.004444 21.617778 33.450667 21.617778h11.278222c-24.362667 3.313778-41.955556 12.8-41.955555 26.026667 0 9.102222 11.562667 21.105778 28.842666 28.302222 0 0-21.333333 66.744889 10.296889 81.962667a36.977778 36.977778 0 0 0 21.333333 1.564444c44.856889 2.446222 125.155556-0.739556 169.784889-0.739555 0-0.810667 23.466667 127.146667 23.466667 127.146666h403.299556c0 0.64-38.769778-289.265778-38.769778-289.265777 70.968889-101.632 95.544889-192.611556 96.881778-268.643556 1.422222-11.491556 2.161778-23.068444 2.176-34.659556h0.042666zM701.155556 320.711111a72.632889 72.632889 0 0 1-65.706667-42.055111l-54.471111 31.544889a108.344889 108.344889 0 0 1-7.509334 107.975111l102.172445 59.192889a36.508444 36.508444 0 1 1-10.894222 25.984 35.555556 35.555556 0 0 1 2.019555-10.026667L561.777778 432.512a109.511111 109.511111 0 1 1 10.168889-138.154667l57.728-33.422222a72.718222 72.718222 0 1 1 71.466666 59.733333v0.042667z" fill="#323233" ></path></symbol><symbol id="icon-fuhao-huizhi" viewBox="0 0 1024 1024"><path d="M254.4 82.624L82.624 254.4a60.704 60.704 0 0 0 0 85.92L254.4 512l128.8-128.8-42.88-42.88-85.92 85.888-42.88-42.88 85.888-85.92-42.88-42.88-85.92 85.888-42.88-42.88 171.776-171.84 171.584 171.616L512 254.4l-171.776-171.84a60.576 60.576 0 0 0-85.76 0z m644.096 644.064l-171.808 171.808-42.88-42.912 85.888-85.888-42.88-42.88-85.92 85.856-42.88-42.88 85.888-85.888-42.912-42.912L512 769.6l171.776 171.776a60.704 60.704 0 0 0 85.92 0l171.776-171.776a60.704 60.704 0 0 0 0-85.92L769.6 512l-42.912 42.88 171.808 171.808zM680.8 211.328l131.968 131.872-43.968 44L636.8 255.2l44-43.872zM240.96 650.976l131.968 131.872-44 44-131.968-131.872 44-44zM680.704 123.424a124.544 124.544 0 0 1 176.288 0.096l43.584 43.52a124.704 124.704 0 0 1 0.096 176.16L355.264 888.416l-268.352 48.384 48.384-268.288L680.704 123.424zM334.4 821.344L857.472 298.656c23.84-23.872 23.552-63.264-0.8-87.52L813.12 167.616c-24.544-24.544-63.552-24.832-87.584-0.8L202.432 689.6l-27.52 159.424 159.52-27.616z" fill="#0A8CF0" ></path></symbol><symbol id="icon-shanchu" viewBox="0 0 1024 1024"><path d="M799.2 874.4c0 34.4-28.001 62.4-62.4 62.4H287.2c-34.4 0-62.4-28-62.4-62.4V212h574.4v662.4zM349.6 100c0-7.2 5.6-12.8 12.8-12.8h300c7.2 0 12.8 5.6 12.8 12.8v37.6H349.6V100z m636.8 37.6H749.6V100c0-48.001-39.2-87.2-87.2-87.2h-300c-48 0-87.2 39.199-87.2 87.2v37.6H37.6C16.8 137.6 0 154.4 0 175.2s16.8 37.6 37.6 37.6h112v661.6c0 76 61.6 137.6 137.6 137.6h449.6c76 0 137.6-61.6 137.6-137.6V212h112c20.8 0 37.6-16.8 37.6-37.6s-16.8-36.8-37.6-36.8zM512 824c20.8 0 37.6-16.8 37.6-37.6v-400c0-20.8-16.8-37.6-37.6-37.6s-37.6 16.8-37.6 37.6v400c0 20.8 16.8 37.6 37.6 37.6m-175.2 0c20.8 0 37.6-16.8 37.6-37.6v-400c0-20.8-16.8-37.6-37.6-37.6s-37.6 16.8-37.6 37.6v400c0.8 20.8 17.6 37.6 37.6 37.6m350.4 0c20.8 0 37.6-16.8 37.6-37.6v-400c0-20.8-16.8-37.6-37.6-37.6s-37.6 16.8-37.6 37.6v400c0 20.8 16.8 37.6 37.6 37.6" fill="#8A8A8A" ></path></symbol><symbol id="icon-jurassic_import-form" viewBox="0 0 1024 1024"><path d="M764.9 64H225.4l1.4 224.2 64-0.4-1-159.8h383.6v224H896v544H289.8l1-159.8-64-0.4-1.4 224.2H960V277.7L764.9 64z m-27.6 64.7L882.8 288H737.3V128.7z" fill="#707070" ></path><path d="M356.5 224h255.9v64H356.5z" fill="#707070" ></path><path d="M576.4 416h255.9v64H576.4zM512.5 576h319.8v64H512.5zM384.5 736h447.8v64H384.5z" fill="#707070" ></path><path d="M336.9 349H198.6l98.9 98.9H64v128.2h233.5L198.6 675h138.3l162.9-163z" fill="#707070" ></path></symbol><symbol id="icon-kaoheweidufenxi" viewBox="0 0 1024 1024"><path d="M815.542857 212.943238l118.296381 68.266667v168.033524l-201.532952 116.345904-0.487619-163.352381-125.366857-72.46019 209.091047-116.833524z m-89.673143-51.736381L519.314286 279.454476 305.785905 156.233143 511.561143 37.449143l214.308571 123.757714zM294.619429 887.466667L89.234286 768.877714V546.133333l205.677714 118.00381-0.292571 223.329524z m85.333333 49.249523l-0.097524-223.914666 133.607619 76.653714 132.632381-76.604952-1.024 222.744381-133.558857 77.043809-131.510857-75.922286zM434.468571 328.021333L295.253333 407.747048l-0.195047 156.672L89.234286 444.318476V281.258667l132.047238-76.263619 213.089524 123.026285z m86.113524 49.737143l126.780953 73.191619-0.780191 164.08381-133.12 76.897524-133.656381-78.019048-0.097524-157.403429 140.921905-78.750476z m413.257143 169.008762v222.110476l-200.655238 115.809524-0.633905-221.769143 201.289143-116.150857z" fill="#82529d" ></path></symbol><symbol id="icon-wenjianjia" viewBox="0 0 1024 1024"><path d="M855.04 385.024q19.456 2.048 38.912 10.24t33.792 23.04 21.504 37.376 2.048 54.272q-2.048 8.192-8.192 40.448t-14.336 74.24-18.432 86.528-19.456 76.288q-5.12 18.432-14.848 37.888t-25.088 35.328-36.864 26.112-51.2 10.24l-567.296 0q-21.504 0-44.544-9.216t-42.496-26.112-31.744-40.96-12.288-53.76l0-439.296q0-62.464 33.792-97.792t95.232-35.328l503.808 0q22.528 0 46.592 8.704t43.52 24.064 31.744 35.84 12.288 44.032l0 11.264-53.248 0q-40.96 0-95.744-0.512t-116.736-0.512-115.712-0.512-92.672-0.512l-47.104 0q-26.624 0-41.472 16.896t-23.04 44.544q-8.192 29.696-18.432 62.976t-18.432 61.952q-10.24 33.792-20.48 65.536-2.048 8.192-2.048 13.312 0 17.408 11.776 29.184t29.184 11.776q31.744 0 43.008-39.936l54.272-198.656q133.12 1.024 243.712 1.024l286.72 0z" ></path></symbol><symbol id="icon-biaoqian" viewBox="0 0 1024 1024"><path d="M934.912 516.096q23.552 26.624 19.456 49.664t-26.624 46.592l-324.608 327.68q-8.192 7.168-19.456 11.264t-23.04 4.608-23.04-2.56-18.432-10.24q-121.856-122.88-218.112-220.16l-80.896-80.896q-39.936-39.936-71.168-71.68t-51.2-51.2-20.992-21.504q-3.072-4.096-10.752-14.848t-6.656-25.088l0-19.456 0-40.96q0-23.552 0.512-52.736t0.512-58.88q1.024-70.656 2.048-156.672 2.048-13.312 6.144-24.064t15.36-22.016q10.24-11.264 22.016-16.384t22.016-5.12l329.728 0q2.048 0 9.216 0.512t10.24 1.536q6.144 2.048 11.264 5.12t10.24 8.192zM217.088 317.44q40.96 0 69.12-28.672t28.16-69.632-28.16-69.632-69.12-28.672q-20.48 0-37.888 7.68t-30.72 20.992-20.992 31.232-7.68 38.4 7.68 38.4 20.992 31.232 30.72 20.992 37.888 7.68z" fill="#ea9518" ></path></symbol><symbol id="icon-wenben" viewBox="0 0 1024 1024"><path d="M823.296 60.416q65.536 0 99.328 38.4t33.792 93.696l0 543.744q0 25.6-21.504 46.08l-171.008 163.84q-13.312 11.264-22.528 14.336t-23.552 3.072l-459.776 0q-23.552 0-47.104-9.728t-41.984-27.648-30.208-43.008-11.776-55.808l0-634.88q0-60.416 33.28-96.256t94.72-35.84l568.32 0zM608.256 702.464q13.312 0 22.528-9.216t9.216-22.528q0-14.336-9.216-23.04t-22.528-8.704l-320.512 0q-13.312 0-22.528 8.704t-9.216 23.04q0 13.312 9.216 22.528t22.528 9.216l320.512 0zM736.256 509.952q13.312 0 22.528-9.216t9.216-22.528-9.216-22.528-22.528-9.216l-448.512 0q-13.312 0-22.528 9.216t-9.216 22.528 9.216 22.528 22.528 9.216l448.512 0zM799.744 318.464q13.312 0 22.528-9.216t9.216-23.552q0-13.312-9.216-22.528t-22.528-9.216l-512 0q-13.312 0-22.528 9.216t-9.216 22.528q0 14.336 9.216 23.552t22.528 9.216l512 0z" fill="#db639b" ></path></symbol><symbol id="icon-yingyong" viewBox="0 0 1026 1024"><path d="M371.732817 94.172314q25.773475 0 44.112294 17.843175t18.338819 43.616651l0 247.821878q0 25.773475-18.338819 44.112294t-44.112294 18.338819l-247.821878 0q-25.773475 0-43.616651-18.338819t-17.843175-44.112294l0-247.821878q0-25.773475 17.843175-43.616651t43.616651-17.843175l247.821878 0zM371.732817 589.81607q25.773475 0 44.112294 17.843175t18.338819 43.616651l0 248.813166q0 25.773475-18.338819 43.616651t-44.112294 17.843175l-247.821878 0q-25.773475 0-43.616651-17.843175t-17.843175-43.616651l0-248.813166q0-25.773475 17.843175-43.616651t43.616651-17.843175l247.821878 0zM868.367861 589.81607q25.773475 0 43.616651 17.843175t17.843175 43.616651l0 248.813166q0 25.773475-17.843175 43.616651t-43.616651 17.843175l-247.821878 0q-25.773475 0-44.112294-17.843175t-18.338819-43.616651l0-248.813166q0-25.773475 18.338819-43.616651t44.112294-17.843175l247.821878 0zM1006.156825 203.21394q19.82575 19.82575 19.82575 46.590513t-19.82575 45.599226l-184.379477 184.379477q-19.82575 19.82575-46.094869 19.82575t-46.094869-19.82575l-184.379477-184.379477q-18.834463-18.834463-18.834463-45.599226t18.834463-46.590513l184.379477-184.379477q19.82575-18.834463 46.094869-18.834463t46.094869 18.834463z" fill="#0061b2" ></path></symbol><symbol id="icon-wenjianjia-copy" viewBox="0 0 1024 1024"><path d="M855.04 385.024q19.456 2.048 38.912 10.24t33.792 23.04 21.504 37.376 2.048 54.272q-2.048 8.192-8.192 40.448t-14.336 74.24-18.432 86.528-19.456 76.288q-5.12 18.432-14.848 37.888t-25.088 35.328-36.864 26.112-51.2 10.24l-567.296 0q-21.504 0-44.544-9.216t-42.496-26.112-31.744-40.96-12.288-53.76l0-439.296q0-62.464 33.792-97.792t95.232-35.328l503.808 0q22.528 0 46.592 8.704t43.52 24.064 31.744 35.84 12.288 44.032l0 11.264-53.248 0q-40.96 0-95.744-0.512t-116.736-0.512-115.712-0.512-92.672-0.512l-47.104 0q-26.624 0-41.472 16.896t-23.04 44.544q-8.192 29.696-18.432 62.976t-18.432 61.952q-10.24 33.792-20.48 65.536-2.048 8.192-2.048 13.312 0 17.408 11.776 29.184t29.184 11.776q31.744 0 43.008-39.936l54.272-198.656q133.12 1.024 243.712 1.024l286.72 0z" ></path></symbol></svg>',(l=>{var r=(n=(n=document.getElementsByTagName("script"))[n.length-1]).getAttribute("data-injectcss"),n=n.getAttribute("data-disable-injectsvg");if(!n){var o,s,c,y,f,v=function(x,E){E.parentNode.insertBefore(x,E)};if(r&&!l.__iconfont__svg__cssinject__){l.__iconfont__svg__cssinject__=!0;try{document.write("<style>.svgfont {display: inline-block;width: 1em;height: 1em;fill: currentColor;vertical-align: -0.1em;font-size:16px;}</style>")}catch(x){console&&console.log(x)}}o=function(){var x,E=document.createElement("div");E.innerHTML=l._iconfont_svg_string_4827314,(E=E.getElementsByTagName("svg")[0])&&(E.setAttribute("aria-hidden","true"),E.style.position="absolute",E.style.width=0,E.style.height=0,E.style.overflow="hidden",E=E,(x=document.body).firstChild?v(E,x.firstChild):x.appendChild(E))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(o,0):(s=function(){document.removeEventListener("DOMContentLoaded",s,!1),o()},document.addEventListener("DOMContentLoaded",s,!1)):document.attachEvent&&(c=o,y=l.document,f=!1,u(),y.onreadystatechange=function(){y.readyState=="complete"&&(y.onreadystatechange=null,m())})}function m(){f||(f=!0,c())}function u(){try{y.documentElement.doScroll("left")}catch{return void setTimeout(u,50)}m()}})(window);const Xp={class:"statistics-cards-container"},Zp=["onClick"],Qp=a.defineComponent({__name:"index",props:{items:{default:()=>[]},disabled:{type:Boolean,default:!1},textSize:{default:void 0},textColor:{default:void 0}},setup(l){const r=l,n=a.ref(null),o=x=>{if(Array.isArray(x)&&x.length>=3){const[E,B,w,V]=x;return V!==void 0?`rgba(${E}, ${B}, ${w}, ${V})`:`rgb(${E}, ${B}, ${w})`}if(typeof x=="string"){const E=x.trim();if(E.startsWith("[")&&E.endsWith("]")){const B=E.slice(1,-1).split(",").map(w=>Number(w.trim()));if(B.length>=3&&B.every(w=>!Number.isNaN(w))){const[w,V,A,N]=B;return N!==void 0?`rgba(${w}, ${V}, ${A}, ${N})`:`rgb(${w}, ${V}, ${A})`}}return E}},s=a.computed(()=>{const x=Number(r==null?void 0:r.textSize),E=o(r==null?void 0:r.textColor),B={},w={};return!Number.isNaN(x)&&x&&(B.fontSize=`${x}px`,w.fontSize=`${x}px`),E&&(B.color=E,w.color=E),{label:B,value:w}}),c=x=>pl.getComponent(x),y=x=>{if(!x)return;const E=x.querySelector("input, textarea, .el-input__inner");E&&typeof E.focus=="function"&&E.focus()},f=(x,E,B)=>{r.disabled||x.field&&(n.value=E,a.nextTick(()=>{y(B.currentTarget)}))},v=()=>{n.value=null},m=x=>{var B;const E=((B=x==null?void 0:x.field)==null?void 0:B.value)??(x==null?void 0:x.value);return E==null||E===""?"-":E},u=x=>{const E=x!=null&&x.width&&x.width>0?x.width:1,w=`calc((100% - ${(E-1)*16}px) / ${E})`;return{flex:`0 0 ${w}`,maxWidth:w,minWidth:"140px",boxSizing:"border-box"}};return(x,E)=>(a.openBlock(),a.createElementBlock("div",Xp,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(x.items,(B,w)=>{var V,A,N,Y,b,$,T,k;return a.openBlock(),a.createElementBlock("div",{class:"statistics-card",key:w,style:a.normalizeStyle(u(B))},[a.createElementVNode("div",{class:"statistics-label",style:a.normalizeStyle(s.value.label)},a.toDisplayString(B==null?void 0:B.label),5),a.createElementVNode("div",{class:"statistics-value",style:a.normalizeStyle(s.value.value),onClick:_=>f(B,w,_)},[n.value===w&&B.field?(a.openBlock(),a.createBlock(a.resolveDynamicComponent(c(((V=B.field)==null?void 0:V.type)??"Input")),{key:0,modelValue:B.field.value,"onUpdate:modelValue":_=>B.field.value=_,isEdit:!0,disabled:(A=B.field)==null?void 0:A.disabled,content:((N=B.field)==null?void 0:N.contents)??[],optionUrl:B.field,originalValue:(Y=B.field)==null?void 0:Y.value,config:(b=B.field)==null?void 0:b.config,configModel:(($=B.field)==null?void 0:$.prop)??((T=B.field)==null?void 0:T.name),selectedTagList:((k=B.field)==null?void 0:k.selectValue)??[],onBlur:v,onBlurChange:v},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[a.createTextVNode(a.toDisplayString(m(B)),1)],64))],12,Zp)],4)}),128))]))}}),ef=ql._export_sfc(Qp,[["__scopeId","data-v-bc3dcbbb"]]),Zs=I.defineStore("formToTableComp",{state:()=>({selectArray:[],selectString:""}),actions:{setSelectArray(l){this.selectArray=l},setSelectString(l){this.selectString=l}}}),af={class:"calculator-content"},lf={class:"calculator-child"},rf={class:"calculator-child"},nf=a.defineComponent({__name:"calculator",setup(l){const r=a.ref(),n=a.ref();return a.onMounted(()=>{r.value=[{type:"Upload",label:"输入",name:"input"}],n.value=[{type:"Upload",label:"输出",name:"output"}]}),(o,s)=>(a.openBlock(),a.createElementBlock("div",af,[a.createElementVNode("div",lf,[a.createVNode(pl.ssForm,{rowContents:r.value,isRowFlex:!0},null,8,["rowContents"])]),a.createElementVNode("div",rf,[a.createVNode(pl.ssForm,{rowContents:n.value,isEdit:!1,isRowFlex:!0},null,8,["rowContents"])])]))}}),of=ql._export_sfc(nf,[["__scopeId","data-v-73db0fe7"]]),dt=(l,r)=>{let n=l,o=r;return Array.isArray(n)&&(n=n==null?void 0:n.map((s,c)=>{if(Array.isArray(s)){let y={};return s=s==null?void 0:s.forEach((f,v)=>{var m;(m=o==null?void 0:o[v])!=null&&m.prop?y[o[v].prop]=f:Array.isArray(f)&&(y.children=dt(f,o))}),Object.assign(y,{id:c})}else return s})),n},Qs=(l,r,n)=>{let o=l,s=r;return o=o==null?void 0:o.map((c,y)=>{var f,v;return!Array.isArray(c)||!((f=s==null?void 0:s[y])!=null&&f.label)&&!n||(c.unshift(((v=s==null?void 0:s[y])==null?void 0:v.label)??""),c.some(m=>Array.isArray(m))&&(c=c==null?void 0:c.map(m=>{var u;return Array.isArray(m)&&(m=Qs(m,(u=s==null?void 0:s[y])==null?void 0:u.children,n)),m}))),c}),o},tf=(l,r,n)=>{if(r==="")return l==null?void 0:l.filter(o=>(o==null?void 0:o.id)!==n);{const o=r.split("-");return sf(l,o,n)}},sf=(l,r,n)=>{let o=l,s=r;return(s==null?void 0:s.length)===0?o=o==null?void 0:o.filter(c=>c.id!==n):o=o==null?void 0:o.map(c=>(c.id.toString()===(s==null?void 0:s[0])&&(s==null||s.shift(),c=ec(c,s,n)),c)),o},ec=(l,r,n)=>{var c,y;let o=l,s=r;return(s==null?void 0:s.length)===0?o.children=(c=o.children)==null?void 0:c.filter(f=>f.id!==n):o.children=(y=o.children)==null?void 0:y.map(f=>(f.id.toString()===(s==null?void 0:s[0])&&(s==null||s.shift(),f=ec(f,s,n)),f)),o},cf=(l,r,n)=>{if(r==="")return n;{const o=r.split("-");return uf(l,o,n)}},uf=(l,r,n)=>{let o=l,s=r;return(s==null?void 0:s.length)===0?o=n:o=o==null?void 0:o.map(c=>(c.id.toString()===(s==null?void 0:s[0])&&(s==null||s.shift(),c=ac(c,s,n)),c)),o},ac=(l,r,n)=>{var c;let o=l,s=r;return(s==null?void 0:s.length)===0?o.children=n:o.children=(c=o.children)==null?void 0:c.map(y=>(y.id.toString()===(s==null?void 0:s[0])&&(s==null||s.shift(),y=ac(y,s,n)),y)),o};class df{constructor(r={}){Rr(this,"url");Rr(this,"heartbeatInterval");Rr(this,"socket",null);Rr(this,"isConnected",!1);Rr(this,"heartTimer",null);Rr(this,"canvas",null);Rr(this,"ctx",null);Rr(this,"mainCamCutMode",0);Rr(this,"pMainShowStartX",0);Rr(this,"pMainShowStartY",0);Rr(this,"onLog");Rr(this,"onDevCount");Rr(this,"onResolution");Rr(this,"onCameraStatus");Rr(this,"onPhoto");this.url=r.url??"ws://127.0.0.1:22225",this.heartbeatInterval=r.heartbeatInterval??3e3}init(r,n,o){var y;(y=this.canvas)!=null&&y.parentNode&&this.canvas.parentNode.removeChild(this.canvas);const s=document.createElement("canvas");s.style.border="solid 1px #A0A0A0",s.id="MainCamCanvas",s.width=n,s.height=o;const c=s.getContext("2d");if(!c)throw new Error("无法获取 CanvasRenderingContext2D");r.appendChild(s),this.canvas=s,this.ctx=c}async connect(){this.socket&&(this.socket.readyState===WebSocket.OPEN||this.socket.readyState===WebSocket.CONNECTING)||await new Promise((r,n)=>{const o=new WebSocket(this.url);o.binaryType="arraybuffer",o.onopen=()=>{this.socket=o,this.isConnected=!0,this.startHeartbeat(),this.log("socket.onopen"),r()},o.onerror=s=>{this.isConnected=!1,this.log("socket.onerror"),n(s)},o.onclose=()=>{this.isConnected=!1,this.stopHeartbeat(),this.log("socket.onclose")},o.onmessage=s=>{this.handleMessage(s)}})}destroy(){var r;this.stopHeartbeat();try{this.closeCamera()}catch{}if(this.socket){try{this.socket.onmessage=null}catch{}try{this.socket.onopen=null}catch{}try{this.socket.onerror=null}catch{}try{this.socket.onclose=null}catch{}try{this.socket.close()}catch{}this.socket=null}this.isConnected=!1,(r=this.canvas)!=null&&r.parentNode&&this.canvas.parentNode.removeChild(this.canvas),this.canvas=null,this.ctx=null}getDevCount(){this.sendBytes(new Uint8Array([119,136,80]))}getResolution(r=0){this.sendBytes(new Uint8Array([119,136,81,r]))}chooseResolution(r){if(!Array.isArray(r)||r.length===0)return null;const n=r.find(s=>s.width===2592&&s.height===1944);return n||[...r].sort((s,c)=>c.width*c.height-s.width*s.height)[0]||null}openCamera(r=0,n=1280,o=720){if(!this.canvas)throw new Error("请先 init() 传入容器并创建 canvas");const s=new Uint8Array(12);s[0]=119,s[1]=136,s[2]=1,s[3]=r,s[4]=this.canvas.width>>8&255,s[5]=this.canvas.width&255,s[6]=this.canvas.height>>8&255,s[7]=this.canvas.height&255,s[8]=n>>8&255,s[9]=n&255,s[10]=o>>8&255,s[11]=o&255,this.sendBytes(s)}closeCamera(){this.sendBytes(new Uint8Array([119,136,2,0]))}photo(){const s=new Uint8Array(12);s[0]=119,s[1]=136,s[2]=16,s[3]=0,s[4]=0,s[5]=0,s[6]=0,s[7]=0,s[8]=1,s[9]=0,s[10]=0,s[11]=0,this.sendBytes(s)}bestSize(){this.sendBytes(new Uint8Array([119,136,5,0]))}rotateLeft(){this.sendBytes(new Uint8Array([119,136,7,0]))}rotateRight(){this.sendBytes(new Uint8Array([119,136,8,0]))}focus(){this.sendBytes(new Uint8Array([119,136,48,0]))}log(r){var n;(n=this.onLog)==null||n.call(this,r)}sendBytes(r){if(!this.socket||this.socket.readyState!==WebSocket.OPEN||!this.isConnected)throw new Error("socket 未连接");this.socket.send(r.buffer)}startHeartbeat(){this.stopHeartbeat(),this.heartTimer=window.setInterval(()=>{this.log("heartCheck...........")},this.heartbeatInterval)}stopHeartbeat(){this.heartTimer&&(clearInterval(this.heartTimer),this.heartTimer=null)}handleMessage(r){var s,c,y,f,v,m;const n=new Uint8Array(r.data);if(n.length<=0)return;if(n[0]===17&&n[1]===17&&n[2]===17){this.log("heart socket!!!!");return}if(n[0]!==85||n[1]!==102)return;const o=n[2];if(o===80){const u=n[3],x=n.length-4,E=new Uint8Array(x);for(let V=0;V<x;V++)E[V]=n[4+V];const w=decodeURIComponent(this.byteToString(E)).split("|");(s=this.onDevCount)==null||s.call(this,u,w);return}if(o===81){const u=n[3]||0,x=[];for(let E=0;E<u;E++){const B=(n[4+E*4+0]||0)*256+(n[4+E*4+1]||0),w=(n[4+E*4+2]||0)*256+(n[4+E*4+3]||0);x.push({width:B,height:w,text:`${B}*${w}`})}(c=this.onResolution)==null||c.call(this,u,x);return}if(o===1){n[3]===1&&((y=this.onCameraStatus)==null||y.call(this,"opened")),n[3]===3&&((f=this.onCameraStatus)==null||f.call(this,"closed"));return}if(o===16){if(n[3]===1){const x=n[4]*256+n[5],E=n[6]*65536+n[7]*256+n[8];let B="";if(x>0){const A=new Uint8Array(x);for(let N=0;N<x;N++)A[N]=n[9+N];B=decodeURIComponent(this.byteToString(A))}const w=new Uint8Array(E);for(let A=0;A<E;A++)w[A]=n[9+x+A];const V=this.uint8ArrayToString(w);(v=this.onPhoto)==null||v.call(this,{flag:0,imgPath:B,base64:V})}n[3]===2&&((m=this.onPhoto)==null||m.call(this,{flag:2,imgPath:"",base64:""}));return}if(o===204){if(!this.canvas||!this.ctx)return;const u=n[3]*256+n[4],x=n[5]*256+n[6];this.pMainShowStartX=n[7]*256+n[8],this.pMainShowStartY=n[9]*256+n[10],this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height);const E=this.ctx.createImageData(u,x);let B=11;for(let w=0;w<E.data.length;w+=4)E.data[w+0]=n[B],E.data[w+1]=n[B+1],E.data[w+2]=n[B+2],E.data[w+3]=255,B+=3;this.ctx.putImageData(E,this.pMainShowStartX,this.pMainShowStartY),this.mainCamCutMode;return}}uint8ArrayToString(r){let n="";for(let o=0;o<r.length;o++)n+=String.fromCharCode(r[o]);return n}byteToString(r){let n="";for(let o=0;o<r.length;o++)n+=String.fromCharCode(r[o]);return n}}const pf={style:{display:"flex",gap:"16px",height:"100%"}},ff={key:0,style:{color:"var(--el-text-color-secondary)"}},hf={style:{width:"420px",display:"flex","flex-direction":"column",gap:"16px"}},vf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px"}},mf={ref:"pictureBox",style:{height:"220px",border:"1px dashed var(--el-border-color)","border-radius":"4px",background:"var(--el-fill-color-lighter)",position:"relative",overflow:"auto",padding:"8px"}},yf={key:0,style:{height:"100%",display:"flex","align-items":"center","justify-content":"center",color:"var(--el-text-color-secondary)"}},gf={key:1,style:{display:"grid","grid-template-columns":"repeat(2, minmax(0, 1fr))",gap:"8px"}},bf=["src","onClick"],kf=["onClick"],xf={style:{border:"1px solid var(--el-border-color)","border-radius":"4px",padding:"12px",flex:"1","min-height":"0",display:"flex","flex-direction":"column"}},_f={class:"dialog-footer"},wf=a.defineComponent({__name:"index",props:{visible:{type:Boolean,default:!1}},emits:["confirm","cancel"],setup(l,{emit:r}){const n=l,o=r,s=a.ref(null),c=a.ref(!1),y=a.ref([]),f=a.ref(""),v=a.ref(!1),m=a.ref([]),u=new df({url:"ws://127.0.0.1:22225"});function x(W,ce){var X;const Ee=W.split(","),Ie=((X=Ee[0].match(/:(.*?);/))==null?void 0:X[1])??"image/jpeg",De=atob(Ee[1]);let ne=De.length;const ge=new Uint8Array(ne);for(;ne--;)ge[ne]=De.charCodeAt(ne);return new File([ge],ce,{type:Ie})}function E(){u.onLog=W=>{console.log("[GPY]",W)},u.onDevCount=(W,ce)=>{if(f.value+=`设备数量=${W},设备=${ce.join(",")}
4
- `,W>0){f.value+=`检测到设备,正在获取分辨率...
5
- `;try{u.getResolution(0)}catch(Ee){f.value+=`获取分辨率失败:${(Ee==null?void 0:Ee.message)??Ee}
6
- `}}else f.value+=`未检测到高拍仪设备!
7
- `},u.onResolution=(W,ce)=>{if(W<=0||!Array.isArray(ce)||ce.length===0){f.value+=`未获取到可用分辨率,回退使用 1280*720 打开...
8
- `;try{u.openCamera(0,1280,720)}catch(Ie){f.value+=`打开摄像头失败:${(Ie==null?void 0:Ie.message)??Ie}
9
- `}return}const Ee=u.chooseResolution(ce);if(!Ee){f.value+=`分辨率选择失败,回退使用 1280*720 打开...
10
- `;try{u.openCamera(0,1280,720)}catch(Ie){f.value+=`打开摄像头失败:${(Ie==null?void 0:Ie.message)??Ie}
11
- `}return}f.value+=`获取分辨率 ${Ee.text}成功,打开摄像头...
12
- `;try{u.closeCamera(),setTimeout(()=>{try{u.openCamera(0,Ee.width,Ee.height)}catch(Ie){f.value+=`打开摄像头失败:${(Ie==null?void 0:Ie.message)??Ie}
13
- `}},100)}catch{try{u.openCamera(0,Ee.width,Ee.height)}catch(Ie){f.value+=`打开摄像头失败:${(Ie==null?void 0:Ie.message)??Ie}
14
- `}}},u.onCameraStatus=W=>{W==="opened"?(c.value=!0,f.value+=`摄像头已打开
15
- `):(c.value=!1,f.value+=`摄像头已关闭
16
- `)},u.onPhoto=W=>{if(W.flag===0&&W.base64){const ce=`data:image/jpeg;base64,${W.base64}`,Ee=x(ce,`gpy-capture-${Date.now()}.jpg`);y.value.push({uid:`${Date.now()}_${Math.random().toString(16).slice(2)}`,url:ce,file:Ee}),f.value+=`拍照完成,已接收图片(当前 ${y.value.length} 张)
17
- `}else f.value+=`拍照失败 flag=${W.flag}
18
- `}}const B=async()=>{if(await a.nextTick(),!s.value)return;w(),E();const W=s.value.getBoundingClientRect();u.init(s.value,Math.floor(W.width),Math.floor(W.height)),f.value+=`正在连接设备服务...
19
- `,await u.connect(),f.value+=`正在获取设备数量...
20
- `,u.getDevCount()},w=()=>{try{u.destroy()}catch(W){console.error(W)}c.value=!1,y.value=[],f.value="",v.value=!1,m.value=[]};a.watch(()=>n.visible,W=>{W?B():w()});const V=()=>{try{u.bestSize()}catch(W){console.error(W)}},A=()=>{try{u.rotateLeft()}catch(W){console.error(W)}},N=()=>{try{u.rotateRight()}catch(W){console.error(W)}},Y=()=>{try{u.focus()}catch(W){console.error(W)}},b=()=>{f.value+=`正在拍照...
21
- `;try{u.photo()}catch(W){f.value+=`拍照调用失败:${(W==null?void 0:W.message)??W}
22
- `}},$=()=>{y.value.length>0?o("confirm",y.value.map(W=>W.file)):o("confirm",[])},T=W=>{W<0||W>=y.value.length||(y.value.splice(W,1),f.value+=`已删除一张图片(剩余 ${y.value.length} 张)
23
- `)},k=W=>{if(!W)return;const ce=`gpy-preview-${Date.now()}.jpg`;m.value=[{name:ce,blobUrl:W}],v.value=!0},_=()=>{v.value=!1},U=()=>{w(),o("cancel")};return(W,ce)=>{const Ee=a.resolveComponent("el-input"),Ie=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock(a.Fragment,null,[a.createVNode(vr.ssDialog,{title:"扫描录入",visible:n.visible,onBeforeDestroy:U,width:"1200px",style:{height:"80%"}},{default:a.withCtx(()=>[a.createElementVNode("div",pf,[a.createElementVNode("div",{ref_key:"cameraBox",ref:s,style:{flex:"1","min-width":"0",border:"1px solid var(--el-border-color)","border-radius":"4px",position:"relative",overflow:"hidden",display:"flex","align-items":"center","justify-content":"center",background:"var(--el-fill-color-lighter)"}},[c.value?a.createCommentVNode("",!0):(a.openBlock(),a.createElementBlock("div",ff,"初始化摄像头..."))],512),a.createElementVNode("div",hf,[a.createElementVNode("div",vf,[ce[0]||(ce[0]=a.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"拍照图片",-1)),a.createElementVNode("div",mf,[y.value.length===0?(a.openBlock(),a.createElementBlock("div",yf,"暂无图片")):(a.openBlock(),a.createElementBlock("div",gf,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(y.value,(De,ne)=>(a.openBlock(),a.createElementBlock("div",{key:De.uid,style:{position:"relative",border:"1px solid var(--el-border-color)","border-radius":"4px",overflow:"hidden",background:"#fafafa"}},[a.createElementVNode("img",{src:De.url,onClick:ge=>k(De.url),style:{width:"100%",height:"94px","object-fit":"contain",display:"block",background:"#fafafa",cursor:"zoom-in"},alt:"captured image",title:"点击放大"},null,8,bf),a.createElementVNode("div",{onClick:ge=>T(ne),style:{position:"absolute",top:"4px",right:"4px",width:"18px",height:"18px","border-radius":"50%",background:"rgba(0,0,0,0.55)",color:"#fff",display:"flex","align-items":"center","justify-content":"center",cursor:"pointer","font-size":"12px"},title:"删除"},"×",8,kf)]))),128))]))],512)]),a.createElementVNode("div",xf,[ce[1]||(ce[1]=a.createElementVNode("div",{style:{"font-weight":"600","margin-bottom":"8px"}},"操作记录",-1)),a.createVNode(Ee,{type:"textarea",value:f.value,readonly:"",rows:10,placeholder:"设备操作记录...",style:{flex:"1"}},null,8,["value"])])])])]),footer:a.withCtx(()=>[a.createElementVNode("div",_f,[a.createVNode(Ie,{onClick:V,disabled:!c.value,id:"themeBorderButton"},{default:a.withCtx(()=>ce[2]||(ce[2]=[a.createTextVNode("适屏")])),_:1,__:[2]},8,["disabled"]),a.createVNode(Ie,{onClick:A,disabled:!c.value,id:"themeBorderButton"},{default:a.withCtx(()=>ce[3]||(ce[3]=[a.createTextVNode("左旋")])),_:1,__:[3]},8,["disabled"]),a.createVNode(Ie,{onClick:N,disabled:!c.value,id:"themeBorderButton"},{default:a.withCtx(()=>ce[4]||(ce[4]=[a.createTextVNode("右旋")])),_:1,__:[4]},8,["disabled"]),a.createVNode(Ie,{onClick:Y,disabled:!c.value,id:"themeBorderButton"},{default:a.withCtx(()=>ce[5]||(ce[5]=[a.createTextVNode("对焦")])),_:1,__:[5]},8,["disabled"]),a.createVNode(Ie,{onClick:b,disabled:!c.value,id:"themeButton"},{default:a.withCtx(()=>ce[6]||(ce[6]=[a.createTextVNode("拍照")])),_:1,__:[6]},8,["disabled"]),ce[9]||(ce[9]=a.createElementVNode("div",{style:{flex:"1"}},null,-1)),a.createVNode(Ie,{onClick:$,disabled:y.value.length===0,id:"themeButton"},{default:a.withCtx(()=>ce[7]||(ce[7]=[a.createTextVNode("确认")])),_:1,__:[7]},8,["disabled"]),a.createVNode(Ie,{onClick:U,id:"themeBorderButton"},{default:a.withCtx(()=>ce[8]||(ce[8]=[a.createTextVNode("取消")])),_:1,__:[8]})])]),_:1},8,["visible"]),v.value?(a.openBlock(),a.createBlock(pl.ssFilePreview,{key:0,fileDataList:m.value,onDestroy:_},null,8,["fileDataList"])):a.createCommentVNode("",!0)],64)}}}),Cf=ql._export_sfc(wf,[["__scopeId","data-v-24a2050a"]]);function lc(l){return rl.axios.post("http://222.92.178.198:8000/api/v1/excel-chat",l)}function Ef(l){return rl.axios.get(l,{responseType:"blob"})}const is=I.useMenuState(I.pinia),Sf=async l=>{var c,y,f,v,m,u;let r=l==null?void 0:l.导入文件,n=l==null?void 0:l.函数参数,o=(c=r==null?void 0:r[0])==null?void 0:c.url,s="";if(!(o!=null&&o.includes("http"))||!(o!=null&&o.includes("https"))){is.setContentLoading(!0);const x=await I.platformDownloadFile({url:o});let E=x==null?void 0:x.data;const B=new FormData;B.append("file",E,((y=r==null?void 0:r[0])==null?void 0:y.name)+"."+((f=o==null?void 0:o.split("."))==null?void 0:f[1])),B.append("query",n);let w=await lc(B);w=(u=(m=(v=w==null?void 0:w.data)==null?void 0:v.data)==null?void 0:m.response)==null?void 0:u.replace("generateResult",l==null?void 0:l.函数名称),s=w,is.setContentLoading(!1)}return s},xt=I.defineStore("formComp",{state:()=>({objUrl:[],blobUrls:[]}),actions:{setObjUrl(l){this.objUrl=l},setBlobUrls(l){this.blobUrls=l}}}),_i={检校类型:["检校类型","证书类别"],证书编号:["证书编号"],设备名称:["设备名称","器具名称","样品名称","仪器名称","被校设备"],型号规格:["型号规格","型号/规格","型号"],出厂编号:["出厂编号","器具/管理编号","器具编号","管理编号","仪器编号"],制造厂:["制造厂","制造单位","制造厂商","制造商"],检校结果:["检校结果","检定结论","校准结果","校准/检定结果","检定结果"],依据文件:["依据文件","检定依据","检定所依据的技术文件","所依据/参照技术文件(代号/名称)","检定所依据的技术文件(编号/名称)","检定方法说明"],检校日期:["检校日期","校准日期","校验日期","检定日期","发证日期","发布日期","接收日期","签证日期"],有效日期:["有效日期","有效期","有效期至"]},ts={columnName:"OCR图片",acceptTypes:"image/*",maxSize:10,maxFiles:20,apiUrl:"http://139.196.154.85:20015/api/public/paddleOCR"};class Df{constructor(r){Rr(this,"config");this.config={...ts,...r}}updateConfig(r){this.config={...this.config,...r}}getConfig(){return{...this.config}}validateFileSize(r){const n=this.config.maxSize*1024*1024;return r.size<=n}validateFileType(r){return r.type.startsWith("image/")||r.type==="application/pdf"}getAuthorizationToken(){const r=rl.Local.get(rl.accessTokenKey);return r?`Bearer ${r}`:""}buildOCRRequest(r,n){return{title:n,form:{OCR图片文件:r}}}async recognize(r,n){const o=this.getAuthorizationToken(),s=this.buildOCRRequest(r,n),c=this.config.apiUrl||ts.apiUrl;return(await rl.axios.post(c,s,{headers:{"Content-Type":"application/json",Authorization:o}})).data}getFieldAliases(r){return _i[r]?_i[r]:[r]}extractTableHeaders(r){const n=[],o=new Set,s=y=>{const f=y==null?void 0:y.label;return!(!f||f==="操作"||f===this.config.columnName||(y==null?void 0:y.type)==="operate"||(y==null?void 0:y.prop)==="operate")},c=y=>{(y||[]).forEach(f=>{if(!f)return;const v=(f==null?void 0:f.children)||(f==null?void 0:f.child)||(f==null?void 0:f.columns);if(Array.isArray(v)&&v.length>0){c(v);return}if(s(f)){const m=f.label;if(!o.has(m)){o.add(m);const u=this.getFieldAliases(m);n.push(u)}}})};return c(r||[]),n}}function rc(l){return new Df(l)}rc();const pt=async(l,r)=>{var y,f,v,m,u,x,E,B,w,V,A,N,Y,b,$,T,k;let n=(f=(y=I.cloneDeep(l))==null?void 0:y.optionUrl)==null?void 0:f.menuSelect,o=[];n==null||n.forEach(_=>{});let s="",c=await ca.menuToParent(n);if(c==null||c.forEach(_=>{var U,W,ce,Ee;(_==null?void 0:_.name)===(((Ee=(ce=(W=(U=I.cloneDeep(l))==null?void 0:U.optionUrl)==null?void 0:W.groupSelect)==null?void 0:ce[0])==null?void 0:Ee.replaceAll("'",""))??"")&&(s=_==null?void 0:_.id)}),r){s=r;const _=await yr.getInsofDataApi({id:s}),U=(x=(u=(m=(v=_==null?void 0:_.data)==null?void 0:v.result)==null?void 0:m[0])==null?void 0:u.key)==null?void 0:x.pageKey;c=await ca.getItemData(U,sessionStorage.getItem("systemKey"),"")}if(s!==""){let _;r?_=(E=c==null?void 0:c.find(ce=>(ce==null?void 0:ce.id)===r))==null?void 0:E.compData:_=(B=c==null?void 0:c.find(ce=>{var Ee,Ie,De,ne;return(ce==null?void 0:ce.name)===(((Ie=(Ee=l==null?void 0:l.groupSelect)==null?void 0:Ee.split(":"))==null?void 0:Ie[0])||((ne=(De=l==null?void 0:l.optionUrl)==null?void 0:De.groupSelect)==null?void 0:ne[0]))}))==null?void 0:B.compData;let U=(V=(w=_==null?void 0:_.find(ce=>(ce==null?void 0:ce.key)==="header"))==null?void 0:w.contents)==null?void 0:V.map(ce=>ce==null?void 0:ce.label);(N=(A=_==null?void 0:_.find(ce=>(ce==null?void 0:ce.key)==="header"))==null?void 0:A.contents)!=null&&N.every(ce=>Array.isArray(ce))&&(U=($=ca.getColumnChild((b=(Y=_==null?void 0:_.find(ce=>(ce==null?void 0:ce.key)==="header"))==null?void 0:Y.contents)==null?void 0:b[0]))==null?void 0:$.map(ce=>ce==null?void 0:ce.prop));let W=(k=(T=_==null?void 0:_.find(ce=>(ce==null?void 0:ce.key)==="tableContents"))==null?void 0:T.contents)==null?void 0:k.map(ce=>{if(Array.isArray(ce))ce=ce==null?void 0:ce.filter(Ee=>!(Ee!=null&&Ee.id));else{let Ee={};for(let Ie in ce)Ie!=="id"&&(Ee[Ie]=ce==null?void 0:ce[Ie]);ce=Ee}return ce});W==null||W.forEach(ce=>{Array.isArray(ce)?o.push(ca.getValueToObjectValue(ce,U)):o.push(ce)})}return o},Nf=I.useMenuState(I.pinia),{activeMenuPath:O6}=I.storeToRefs(Nf),Bf=I.useUnit(I.pinia),{chooseTitle:I6}=I.storeToRefs(Bf),Tf="col-operate",_t=l=>`${Tf}-${l}`,Af=(l,r)=>{const n=new Map;l.forEach(s=>{const{prop:c}=s;n.set(c,s)});const o=s=>{Array.isArray(s)&&s.forEach(c=>{const{prop:y}=c||{},f=n.get(y);zf(f,c),Array.isArray(c==null?void 0:c.children)&&c.children.length>0&&o(c.children)})};return o(r),r},zf=(l,r)=>(l&&(r.sortable=l==null?void 0:l.sortable,r.filterable=l==null?void 0:l.filterable,r.showSummary=l==null?void 0:l.showSummary,r.operable=l==null?void 0:l.operable,r.fixed=l==null?void 0:l.fixed),r),Mf=(l,r)=>{const{sortable:n=!1,filterable:o=!1,showSummary:s=!1,operable:c=!1,fixed:y=!1}=r||{};return{prop:l,sortable:n,filterable:o,showSummary:s,operable:c,fixed:y}},Of=async l=>{var c,y;if(!l)return;const r=_t(l),n=await yr.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:r}}),o=(c=n==null?void 0:n.data)==null?void 0:c.code,s=(y=n==null?void 0:n.data)==null?void 0:y.result;if(o==200)return s==null?void 0:s[0]},If=async l=>{var c,y,f,v;if(!l)return;const r=_t(l),n=await yr.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:r}}),o=(c=n==null?void 0:n.data)==null?void 0:c.code,s=(y=n==null?void 0:n.data)==null?void 0:y.result;return o==200?(v=(f=s==null?void 0:s[0])==null?void 0:f.value)==null?void 0:v.columns:[]},Lf=async(l,r)=>{if(!l||!r)return;const n=_t(l);return await yr.createInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),uniqueKey:n},value:{columns:r}})},$f=async(l,r)=>!l||!r?void 0:await yr.updateInsofDataApi({id:l,value:{columns:r}}),ss=async(l,r)=>{const n=sessionStorage.getItem("systemKey");if(!l||!r||!n)return;const o=await Of(l);return o?await $f(o==null?void 0:o.id,r):await Lf(l,r)};var mi={exports:{}},Rf=mi.exports,cs;function Vf(){return cs||(cs=1,function(l,r){(function(n,o){o()})(Rf,function(){function n(m,u){return typeof u>"u"?u={autoBom:!1}:typeof u!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),u={autoBom:!u}),u.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(m.type)?new Blob(["\uFEFF",m],{type:m.type}):m}function o(m,u,x){var E=new XMLHttpRequest;E.open("GET",m),E.responseType="blob",E.onload=function(){v(E.response,u,x)},E.onerror=function(){console.error("could not download file")},E.send()}function s(m){var u=new XMLHttpRequest;u.open("HEAD",m,!1);try{u.send()}catch{}return 200<=u.status&&299>=u.status}function c(m){try{m.dispatchEvent(new MouseEvent("click"))}catch{var u=document.createEvent("MouseEvents");u.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),m.dispatchEvent(u)}}var y=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof I.commonjsGlobal=="object"&&I.commonjsGlobal.global===I.commonjsGlobal?I.commonjsGlobal:void 0,f=y.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),v=y.saveAs||(typeof window!="object"||window!==y?function(){}:"download"in HTMLAnchorElement.prototype&&!f?function(m,u,x){var E=y.URL||y.webkitURL,B=document.createElement("a");u=u||m.name||"download",B.download=u,B.rel="noopener",typeof m=="string"?(B.href=m,B.origin===location.origin?c(B):s(B.href)?o(m,u,x):c(B,B.target="_blank")):(B.href=E.createObjectURL(m),setTimeout(function(){E.revokeObjectURL(B.href)},4e4),setTimeout(function(){c(B)},0))}:"msSaveOrOpenBlob"in navigator?function(m,u,x){if(u=u||m.name||"download",typeof m!="string")navigator.msSaveOrOpenBlob(n(m,x),u);else if(s(m))o(m,u,x);else{var E=document.createElement("a");E.href=m,E.target="_blank",setTimeout(function(){c(E)})}}:function(m,u,x,E){if(E=E||open("","_blank"),E&&(E.document.title=E.document.body.innerText="downloading..."),typeof m=="string")return o(m,u,x);var B=m.type==="application/octet-stream",w=/constructor/i.test(y.HTMLElement)||y.safari,V=/CriOS\/[\d]+/.test(navigator.userAgent);if((V||B&&w||f)&&typeof FileReader<"u"){var A=new FileReader;A.onloadend=function(){var b=A.result;b=V?b:b.replace(/^data:[^;]*;/,"data:attachment/file;"),E?E.location.href=b:location=b,E=null},A.readAsDataURL(m)}else{var N=y.URL||y.webkitURL,Y=N.createObjectURL(m);E?E.location=Y:location.href=Y,E=null,setTimeout(function(){N.revokeObjectURL(Y)},4e4)}});y.saveAs=v.saveAs=v,l.exports=v})}(mi)),mi.exports}Vf();const Wn=I.defineStore("tabComp",{state:()=>({itemData:[],originalData:[],extraContents:[],nodeDev:"",isEdit:"view",isRefreshCurStructure:!1,isSubmitCurStructure:!1,curStructureCompIds:[],itemGridData:[],itemExtendData:void 0,payloadTypes:"",lockingPage:"",systemPath:void 0,pageMapState:void 0,cacheUpdatingData:void 0,freshContent:!1,tableLoading:!1,routeToChildPath:"",tableViewContents:[],activeItemIndex:0,fixMenuStatus:!1,refreshTable:!1,selectTab:""}),actions:{setItemData(l){this.itemData=l},setCurStructureCompIds(l){this.curStructureCompIds=l},setRefreshCurStructure(l){this.isRefreshCurStructure=l},setOriginalData(l){this.originalData=l},setExtraContents(l){this.extraContents=l},setNodeDev(l){this.nodeDev=l},setIsEdit(l){this.isEdit=l},setSelectTab(l){this.selectTab=l}}}),Pf=I.useLoginState(I.pinia),{loginUserInfo:lt}=I.storeToRefs(Pf),Ff=async l=>{var o,s,c;let r=await I.getAllTables({platId:parseInt((o=lt==null?void 0:lt.value)==null?void 0:o.plat_id),tableNames:[l]});return r=(c=(s=r==null?void 0:r.data)==null?void 0:s.result)==null?void 0:c[0],await Xs(r,!1),[{comp:"Table",isShow:!0,name:"日志管理",compData:[{key:"extraButton",contents:[]},{key:"rowButton",contents:[]},{key:"header",contents:[{label:"请求类型",prop:"request_method",formType:"Input",align:"center"},{label:"请求路径",prop:"request_url",formType:"Input",align:"center"},{label:"请求参数",prop:"request_param",formType:"Upload",align:"center"},{label:"返回结果",prop:"request_result",formType:"Upload",align:"center"},{label:"返回信息",prop:"request_message",formType:"Input",align:"center"},{label:"请求表格",prop:"request_table",formType:"Input",align:"center"},{label:"请求种类",prop:"request_type",formType:"Input",align:"center"},{label:"请求创建时间",prop:"create_time",formType:"Date",align:"center"},{label:"请求创建人",prop:"create_user_id",formType:"Input",align:"center"}]},{key:"tableContents",contents:r}]}]},jf=I.useLoginState(),{loginUserInfo:bl}=I.storeToRefs(jf);let di="$R";const _r=I.useModelComp(I.pinia),nc=a.ref(!1),{itemData:Hf,itemGridData:eo,curStructureCompIds:us,isSubmitCurStructure:Uf,routeToChildPath:qf,pageMapState:ft,itemExtendData:pi,refreshTable:ds}=I.storeToRefs(_r),Ti=Wn(I.pinia),Sr=I.useMenuState(I.pinia),er=a.shallowRef([]),{asideMenus:Wf,activeTopMenuPath:Kf,activeMenuPath:xl,platform:L6,buttonTriggerType:Yf,currentMenuPath:Ur}=I.storeToRefs(Sr),nn=I.useUnit(I.pinia),{selectTitle:Hn,chooseTitle:wi}=I.storeToRefs(nn);a.ref();const So=a.ref(!0),qn=a.ref(0),ht=a.ref([]);a.ref(!1);const wt=a.ref(!1),Po=a.ref(),oc=a.ref(),ic=a.ref(),Gf=()=>{_r.setItemGridData([]),_r.setIsEdit("edit"),_r.setSubmitCurStructure(xl.value!=="/平台管理/菜单管理")},Jf=()=>{_r.setIsEdit("view"),_r.setRefreshCurStructure(!0)},Xf=async l=>{var s;let r=Hn.value,n=r==null?void 0:r.findIndex(c=>(c==null?void 0:c.value)===(l==null?void 0:l.value)),o=r==null?void 0:r.filter((c,y)=>y<=n);nn.setSelectTitle(pl.safeClone(o)),o=(s=o==null?void 0:o.map(c=>c==null?void 0:c.value))==null?void 0:s.join("/"),Sr.setActiveMenuPath(null),Sr.setActiveMenuPath(o)},rt=async(l,r,n,o="contentConfig")=>{var s;try{if(!Array.isArray(l))return;let c,y;r==="create"?(c={dataList:l==null?void 0:l.map(v=>{var m;return{key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:n!=null&&n.startsWith("/")?n==null?void 0:n.substring(1):n,type:"structure",structureBelong:o,parentTable:"",version:1},value:{pageData:{...v,compData:(m=v==null?void 0:v.compData)==null?void 0:m.filter(u=>(u==null?void 0:u.key)!=="tableContents")}}}})},y=yr.batchAddInsofDataApi):r==="update"?(c={dataList:l==null?void 0:l.map(v=>{var m;return{id:v==null?void 0:v.id,value:{pageData:{...v,compData:(m=v==null?void 0:v.compData)==null?void 0:m.filter(u=>(u==null?void 0:u.key)!=="tableContents")}}}})},y=yr.batchUpdateInsofDataApi):r==="delete"&&(c={ids:l},y=yr.batchDeleteInsofDataApi);const f=await y(c);if(((s=f==null?void 0:f.data)==null?void 0:s.code)===200)return f.data.result;throw rl.ElMessage.error("保存响应失败"),new Error("保存响应失败")}catch{rl.ElMessage.error("保存响应失败")}},ps=async(l,r,n,o)=>{var s,c,y,f,v,m,u,x,E,B,w;try{const V=(c=(s=l==null?void 0:l.results)==null?void 0:s.filter(T=>!(T!=null&&T.id)||typeof(T==null?void 0:T.id)=="string"))==null?void 0:c.map(T=>({key:{pageKey:l==null?void 0:l.pageKey,systemKey:sessionStorage.getItem("systemKey"),type:r,relatedInfo:n},value:{tableData:T}})),A=(f=(y=l==null?void 0:l.results)==null?void 0:y.filter(T=>(T==null?void 0:T.id)&&typeof(T==null?void 0:T.id)=="number"))==null?void 0:f.map(T=>({id:T==null?void 0:T.id,value:{tableData:T}})),N=JSON.parse(JSON.stringify(l)),Y=(v=N==null?void 0:N.results)==null?void 0:v.map(T=>T.id);let b;n?b=(x=(u=(m=ft.value)==null?void 0:m[xl.value])==null?void 0:u.filter(T=>{var k,_,U;return((k=T==null?void 0:T.key)==null?void 0:k.type)===r&&((U=(_=T==null?void 0:T.key)==null?void 0:_.relatedInfo)==null?void 0:U.target)===o}))==null?void 0:x.map(T=>T==null?void 0:T.id):b=(w=(B=(E=ft.value)==null?void 0:E[xl.value])==null?void 0:B.filter(T=>{var k;return((k=T==null?void 0:T.key)==null?void 0:k.type)===r}))==null?void 0:w.map(T=>T==null?void 0:T.id);const $=b==null?void 0:b.filter(T=>!(Y!=null&&Y.includes(T))&&typeof T=="number");(V==null?void 0:V.length)>0&&await yr.batchAddInsofDataApi({dataList:V}),(A==null?void 0:A.length)>0&&await yr.batchUpdateInsofDataApi({dataList:A}),($==null?void 0:$.length)>0&&await yr.batchDeleteInsofDataApi({ids:$})}catch(V){throw new Error(V)}},Zf=async l=>{var m,u,x,E,B,w,V,A,N,Y;Sr.setContentLoading(!0);const r=JSON.parse(JSON.stringify(Hf.value));if(!Uf.value)return Sr.setCacheStructures({key:Yf.value,data:r}),rl.ElMessage.success("已暂存");const n=r==null?void 0:r.map(b=>b.id),o=n.filter(b=>{var $;return!(($=us.value)!=null&&$.includes(b))}),s=(m=us.value)==null?void 0:m.filter(b=>!n.includes(b)),c=[...o,...s].filter(b=>typeof b!==null&&typeof b<"u"),y=r==null?void 0:r.filter(b=>!b.id),f=r==null?void 0:r.filter(b=>b.id);let v=[];if(c&&(c==null?void 0:c.length)>0&&v.push(rt(c,"delete",l)),y&&(y==null?void 0:y.length)>0&&v.push(rt(y,"create",l)),f&&(f==null?void 0:f.length)>0&&v.push(rt(f,"update",l)),eo.value&&((u=eo.value)!=null&&u.isDelete&&((E=(x=eo.value)==null?void 0:x.results)==null?void 0:E.length)>0&&((w=(B=eo.value)==null?void 0:B.results)!=null&&w.every(b=>typeof b=="number"))?await yr.batchDeleteInsofDataApi({ids:(V=eo.value)==null?void 0:V.results}):(console.log("itemGridData.value",eo.value),v.push(await ps(eo.value,"gridLayout")))),pi.value)for(const b in pi.value)v.push(await ps((A=pi.value)==null?void 0:A[b],"extend",{target:b,compId:(Y=(N=pi.value)==null?void 0:N[b])==null?void 0:Y.compId},b));await Promise.all(v).then(()=>{rl.ElMessage.success("保存成功"),_r.setRefreshCurStructure(!0)}).catch(b=>{rl.ElMessage.success(b)}),Sr.setContentLoading(!1)},Fo=l=>Do(l),Qf=a.computed(()=>{var l;return(l=er.value)==null?void 0:l.filter(r=>(r==null?void 0:r.affix)&&(r==null?void 0:r.affix)!=="default")}),tc=a.computed(()=>{var l;return(l=er.value)==null?void 0:l.filter(r=>!(r!=null&&r.affix)||(r==null?void 0:r.affix)==="default")}),sc=a.ref(0),cc=a.ref(null),e0="ocr_committed_temp_ids_v1",a0=(l,r)=>`${e0}:${String(l??"")}:${String(r??"")}`,l0=(l,r,n)=>{try{const o=a0(l,r),s=sessionStorage.getItem(o),c=s?JSON.parse(s):[],y=Array.isArray(c)?c:[],f=Array.from(new Set([...y,...n||[]].map(v=>String(v)))).slice(-200);sessionStorage.setItem(o,JSON.stringify(f))}catch{}},Ci=async(l,r="data",n)=>{var s,c,y,f,v,m,u,x,E,B,w,V,A,N,Y,b,$,T,k,_,U,W,ce,Ee,Ie,De,ne,ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye,Ma,Ue,Ya,ga,ba,$a,Sa,Na,Oa,Be,tl,Ea,El,ml;let o=((y=(c=(s=Hn.value)==null?void 0:s.filter(Fe=>(Fe==null?void 0:Fe.condition)==="child"))==null?void 0:c[0])==null?void 0:y.value)??"";if((l==null?void 0:l.buttonName)==="新增"){let Fe=(f=l==null?void 0:l.fixContent)==null?void 0:f.map(q=>{let ra={};for(let ya in q)Array.isArray(q==null?void 0:q[ya])?ra[ya]=JSON.stringify(q==null?void 0:q[ya]):ra[ya]=q==null?void 0:q[ya];return ra}),Va=await I.quoteApi({platId:parseInt((v=bl==null?void 0:bl.value)==null?void 0:v.plat_id),type:"fatherSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});Va=(m=Va==null?void 0:Va.data)==null?void 0:m.result,Va=Va==null?void 0:Va.filter(q=>{var ra,ya;return!((q==null?void 0:q.fatherPath)!==""&&((ya=(ra=q==null?void 0:q.quote)==null?void 0:ra[0])==null?void 0:ya.menus)===(xl==null?void 0:xl.value))});let je=Va==null?void 0:Va.map(q=>{var Se,qa;let ra={},ya=Fe==null?void 0:Fe[0],we;return Array.isArray((Se=q==null?void 0:q.struct)==null?void 0:Se[0])?we=ca.getColumnChild((qa=q==null?void 0:q.struct)==null?void 0:qa[0]):we=q==null?void 0:q.struct,we==null||we.forEach(fe=>{var fl,Qa;ra[fe.prop]=((fl=fe==null?void 0:fe.words)!=null&&fl[0]?(ya==null?void 0:ya[(Qa=fe==null?void 0:fe.words)==null?void 0:Qa[0]])??(ya==null?void 0:ya[fe==null?void 0:fe.prop]):ya==null?void 0:ya[fe==null?void 0:fe.prop])??""}),ra.id="1",ra.relatedId=`[${ra.id}]`,delete ra.sort,{tableName:"content_"+(q==null?void 0:q.id),tableContents:[ra]}}),xe=[{tableName:(u=l==null?void 0:l.relatedContents)==null?void 0:u.find(q=>q==null?void 0:q.includes("content")),tableContents:Fe}];xe=[...xe,...je];let Ze=await I.quoteApi({platId:parseInt((x=bl==null?void 0:bl.value)==null?void 0:x.plat_id),type:"sonSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});Ze=(B=(E=Ze==null?void 0:Ze.data)==null?void 0:E.result)==null?void 0:B.filter(q=>!(xe!=null&&xe.find(ra=>(ra==null?void 0:ra.tableName)==="content_"+(q==null?void 0:q.id)))),Ze=Ze==null?void 0:Ze.filter(q=>{var ra,ya;return!((q==null?void 0:q.fatherPath)!==""&&((ya=(ra=q==null?void 0:q.quote)==null?void 0:ra[0])==null?void 0:ya.menus)===(xl==null?void 0:xl.value))});let Je=Ze==null?void 0:Ze.map(q=>{var Se,qa,fe,fl,Qa,_l,Ha;let ra={},ya=Fe==null?void 0:Fe[0],we;return Array.isArray((Se=q==null?void 0:q.struct)==null?void 0:Se[0])?we=ca.getColumnChild((qa=q==null?void 0:q.struct)==null?void 0:qa[0]):we=q==null?void 0:q.struct,((fl=(fe=we==null?void 0:we[0])==null?void 0:fe.words)!=null&&fl[0]?ya!=null&&ya[(_l=(Qa=we==null?void 0:we[0])==null?void 0:Qa.words)==null?void 0:_l[0]]:ya!=null&&ya[(Ha=we==null?void 0:we[0])==null?void 0:Ha.prop])?(we==null||we.forEach(il=>{var Ia,ul;ra[il.prop]=((Ia=il==null?void 0:il.words)!=null&&Ia[0]?(ya==null?void 0:ya[(ul=il==null?void 0:il.words)==null?void 0:ul[0]])??(ya==null?void 0:ya[il==null?void 0:il.prop]):ya==null?void 0:ya[il==null?void 0:il.prop])??""}),ra.id="1",ra.relatedId=`[${ra.id}]`,delete ra.sort):ra=void 0,{tableName:"content_"+(q==null?void 0:q.id),tableContents:[ra]}});Je=Je==null?void 0:Je.filter(q=>{var ra;return!((ra=q==null?void 0:q.tableContents)!=null&&ra.every(ya=>ya===void 0))}),xe=[...xe,...Je],await I.pageBatchAddApi({platId:parseInt((w=bl==null?void 0:bl.value)==null?void 0:w.plat_id),changeContents:xe});let ea=[];xe==null||xe.forEach(q=>{var ra;(ra=q==null?void 0:q.tableContents)==null||ra.forEach(ya=>{ea.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ya),request_result:"{}",is_delete:!1,request_table:q==null?void 0:q.tableName,request_type:"add"})})}),await I.pageBatchAddApi({platId:parseInt((V=bl==null?void 0:bl.value)==null?void 0:V.plat_id),changeContents:[{tableName:"log",tableContents:ea}]})}if((l==null?void 0:l.buttonName)==="OCR批量新增"){const Fe=((l==null?void 0:l.ocrRows)||[]).map(Ze=>Ze==null?void 0:Ze.id).filter(Ze=>Ze!=null),Va=((l==null?void 0:l.ocrRows)||[]).map(Ze=>{const Je={...Ze};return delete Je._isOCRRow,delete Je._ocrTableId,Object.keys(Je).forEach(ea=>{/(^|\.)证书附件$/.test(ea)&&Array.isArray(Je[ea])&&(Je[ea]=JSON.stringify(Je[ea].map(q=>({url:(q==null?void 0:q.url)||"",name:(q==null?void 0:q.name)||(q==null?void 0:q.fileName)||"",fileName:(q==null?void 0:q.fileName)||(q==null?void 0:q.name)||""})).filter(q=>q.url||q.name)))}),Je});let je=[{tableName:(A=l==null?void 0:l.relatedContents)==null?void 0:A.find(Ze=>Ze==null?void 0:Ze.includes("content")),tableContents:Va}];await I.pageBatchAddApi({platId:parseInt((N=bl==null?void 0:bl.value)==null?void 0:N.plat_id),changeContents:je});let xe=[];je==null||je.forEach(Ze=>{var Je;(Je=Ze==null?void 0:Ze.tableContents)==null||Je.forEach(ea=>{xe.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ea),request_result:"{}",is_delete:!1,request_table:Ze==null?void 0:Ze.tableName,request_type:"ocrBatchAdd"})})}),await I.pageBatchAddApi({platId:parseInt((Y=bl==null?void 0:bl.value)==null?void 0:Y.plat_id),changeContents:[{tableName:"log",tableContents:xe}]}),l0(l==null?void 0:l.parentTableId,l==null?void 0:l.index,Fe)}if((l==null?void 0:l.buttonName)==="编辑"){const Va=((l==null?void 0:l.fixContent)||(l==null?void 0:l.singleContent)||[]||[]).map(we=>{const Se={...we};return delete Se._isOCRRow,delete Se._ocrTableId,delete Se._isTemp,delete Se.tableEditType,delete Se.index,Se});let je=Va==null?void 0:Va.map(we=>{let Se={};for(let qa in we)Array.isArray(we==null?void 0:we[qa])?Se[qa]=JSON.stringify(we==null?void 0:we[qa]):Se[qa]=we==null?void 0:we[qa];return Se}),xe=await I.quoteApi({platId:parseInt((b=bl==null?void 0:bl.value)==null?void 0:b.plat_id),type:"fatherSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});xe=($=xe==null?void 0:xe.data)==null?void 0:$.result,xe=xe==null?void 0:xe.filter(we=>{var Se,qa;return!((we==null?void 0:we.fatherPath)!==""&&((qa=(Se=we==null?void 0:we.quote)==null?void 0:Se[0])==null?void 0:qa.menus)===(xl==null?void 0:xl.value))});let Ze=(T=je==null?void 0:je[0])==null?void 0:T.id,Je=[{tableName:(k=l==null?void 0:l.relatedContents)==null?void 0:k.find(we=>we==null?void 0:we.includes("content")),tableContents:je}],ea=(_=xe==null?void 0:xe.map(we=>{var qa,fe,fl,Qa,_l;let Se=(qa=we==null?void 0:we.contents)==null?void 0:qa.filter(Ha=>{var il,Ia;return JSON.stringify(Ha==null?void 0:Ha.relatedId)!=="{}"&&(Ha==null?void 0:Ha.relatedId)!==""&&(Ha!=null&&Ha.relatedId)?(il=Ha==null?void 0:Ha.relatedId)==null?void 0:il.includes(parseInt(Ze)):(Ha==null?void 0:Ha.sort)===((Ia=je==null?void 0:je[0])==null?void 0:Ia.sort)});if((Se==null?void 0:Se.length)>0){let Ha=je==null?void 0:je[0];Ha={...Ha,id:(fe=Se==null?void 0:Se[0])==null?void 0:fe.id};let il={},Ia=Ha,ul;return Array.isArray((fl=we==null?void 0:we.struct)==null?void 0:fl[0])?ul=ca.getColumnChild((Qa=we==null?void 0:we.struct)==null?void 0:Qa[0]):ul=we==null?void 0:we.struct,ul==null||ul.forEach(Ja=>{var Wl,Kl;il[Ja.prop]=((Wl=Ja==null?void 0:Ja.words)!=null&&Wl[0]?(Ia==null?void 0:Ia[(Kl=Ja==null?void 0:Ja.words)==null?void 0:Kl[0]])??(Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop]):Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop])??""}),il.id=(_l=Se==null?void 0:Se[0])==null?void 0:_l.id,delete il.sort,delete il.relatedId,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[il]}}else return}))==null?void 0:_.filter(we=>we);Je=[...Je,...ea];let q=await I.quoteApi({platId:parseInt((U=bl==null?void 0:bl.value)==null?void 0:U.plat_id),type:"sonSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});q=(ce=(W=q==null?void 0:q.data)==null?void 0:W.result)==null?void 0:ce.filter(we=>!(Je!=null&&Je.find(Se=>(Se==null?void 0:Se.tableName)==="content_"+(we==null?void 0:we.id)))),q=q==null?void 0:q.filter(we=>{var Se,qa;return!((we==null?void 0:we.fatherPath)!==""&&((qa=(Se=we==null?void 0:we.quote)==null?void 0:Se[0])==null?void 0:qa.menus)===(xl==null?void 0:xl.value))});let ra=(Ee=q==null?void 0:q.map(we=>{var qa,fe,fl,Qa,_l;let Se=(qa=we==null?void 0:we.contents)==null?void 0:qa.filter(Ha=>{var il,Ia,ul;return JSON.stringify(Ha==null?void 0:Ha.relatedId)!=="{}"&&(Ha==null?void 0:Ha.relatedId)!==""&&(Ha!=null&&Ha.relatedId)?(il=Ha==null?void 0:Ha.relatedId)==null?void 0:il.includes(parseInt(Ze)):(Ha==null?void 0:Ha.sort)===((Ia=je==null?void 0:je[0])==null?void 0:Ia.sort)||(Ha==null?void 0:Ha.sort)===(parseInt(((ul=je==null?void 0:je[0])==null?void 0:ul.sort)??"0")+1).toString()});if((Se==null?void 0:Se.length)>0){let Ha=je==null?void 0:je[0];Ha={...Ha,id:(fe=Se==null?void 0:Se[0])==null?void 0:fe.id};let il={},Ia=Ha,ul;return Array.isArray((fl=we==null?void 0:we.struct)==null?void 0:fl[0])?ul=ca.getColumnChild((Qa=we==null?void 0:we.struct)==null?void 0:Qa[0]):ul=we==null?void 0:we.struct,ul==null||ul.forEach(Ja=>{var Wl,Kl,$l,Fl;((Wl=Ja==null?void 0:Ja.words)!=null&&Wl[0]?(Ia==null?void 0:Ia[(Kl=Ja==null?void 0:Ja.words)==null?void 0:Kl[0]])??(Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop]):Ia!=null&&Ia[Ja==null?void 0:Ja.prop])&&(il[Ja.prop]=(($l=Ja==null?void 0:Ja.words)!=null&&$l[0]?(Ia==null?void 0:Ia[(Fl=Ja==null?void 0:Ja.words)==null?void 0:Fl[0]])??(Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop]):Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop])??"")}),il.id=(_l=Se==null?void 0:Se[0])==null?void 0:_l.id,delete il.sort,delete il.relatedId,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[il]}}else return}))==null?void 0:Ee.filter(we=>we);Je=[...Je,...ra],await I.pageBatchUpdateApi({platId:parseInt((Ie=bl==null?void 0:bl.value)==null?void 0:Ie.plat_id),changeContents:Je});let ya=[];Je==null||Je.forEach(we=>{var Se;(Se=we==null?void 0:we.tableContents)==null||Se.forEach(qa=>{ya.push({id:"1",request_method:"Post",request_url:"/platform/page/update",request_param:JSON.stringify(qa),request_result:"{}",is_delete:!1,request_table:we==null?void 0:we.tableName,request_type:"update"})})}),await I.pageBatchAddApi({platId:parseInt((De=bl==null?void 0:bl.value)==null?void 0:De.plat_id),changeContents:[{tableName:"log",tableContents:ya}]})}if((l==null?void 0:l.buttonName)==="删除"){let Fe=[{tableName:(ne=l==null?void 0:l.relatedContents)==null?void 0:ne.find(q=>q==null?void 0:q.includes("content")),tableContents:l==null?void 0:l.fixContent}],Va=await I.quoteApi({platId:parseInt((ge=bl==null?void 0:bl.value)==null?void 0:ge.plat_id),type:"fatherSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});Va=(X=Va==null?void 0:Va.data)==null?void 0:X.result,Va=Va==null?void 0:Va.filter(q=>{var ra,ya;return!((q==null?void 0:q.fatherPath)!==""&&((ya=(ra=q==null?void 0:q.quote)==null?void 0:ra[0])==null?void 0:ya.menus)===(xl==null?void 0:xl.value))});let je=(Ke=(de=l==null?void 0:l.fixContent)==null?void 0:de[0])==null?void 0:Ke.id,xe=(Ta=Va==null?void 0:Va.map(q=>{var ya,we,Se,qa,fe,fl;let ra=(ya=q==null?void 0:q.contents)==null?void 0:ya.filter(Qa=>{var _l,Ha,il;return JSON.stringify(Qa==null?void 0:Qa.relatedId)!=="{}"&&(Qa==null?void 0:Qa.relatedId)!==""&&(Qa!=null&&Qa.relatedId)?(_l=Qa==null?void 0:Qa.relatedId)==null?void 0:_l.includes(parseInt(je)):(Qa==null?void 0:Qa.sort)===((il=(Ha=l==null?void 0:l.fixContent)==null?void 0:Ha[0])==null?void 0:il.sort)});if((ra==null?void 0:ra.length)>0){let Qa=(we=l==null?void 0:l.fixContent)==null?void 0:we[0];Qa={...Qa,id:(Se=ra==null?void 0:ra[0])==null?void 0:Se.id};let _l={},Ha=Qa,il;return Array.isArray((qa=q==null?void 0:q.struct)==null?void 0:qa[0])?il=ca.getColumnChild((fe=q==null?void 0:q.struct)==null?void 0:fe[0]):il=q==null?void 0:q.struct,il==null||il.forEach(Ia=>{var ul,Ja;_l[Ia.prop]=((ul=Ia==null?void 0:Ia.words)!=null&&ul[0]?(Ha==null?void 0:Ha[(Ja=Ia==null?void 0:Ia.words)==null?void 0:Ja[0]])??(Ha==null?void 0:Ha[Ia==null?void 0:Ia.prop]):Ha==null?void 0:Ha[Ia==null?void 0:Ia.prop])??""}),_l.id=(fl=ra==null?void 0:ra[0])==null?void 0:fl.id,delete _l.sort,delete _l.relatedId,{tableName:"content_"+(q==null?void 0:q.id),tableContents:[_l]}}else return}))==null?void 0:Ta.filter(q=>q);Fe=[...Fe,...xe];let Ze=await I.quoteApi({platId:parseInt((oe=bl==null?void 0:bl.value)==null?void 0:oe.plat_id),type:"sonSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});Ze=(le=(S=Ze==null?void 0:Ze.data)==null?void 0:S.result)==null?void 0:le.filter(q=>!(Fe!=null&&Fe.find(ra=>(ra==null?void 0:ra.tableName)==="content_"+(q==null?void 0:q.id)))),Ze=Ze==null?void 0:Ze.filter(q=>{var ra,ya;return!((q==null?void 0:q.fatherPath)!==""&&((ya=(ra=q==null?void 0:q.quote)==null?void 0:ra[0])==null?void 0:ya.menus)===(xl==null?void 0:xl.value))});let Je=(me=Ze==null?void 0:Ze.map(q=>{var ya,we,Se,qa,fe,fl;let ra=(ya=q==null?void 0:q.contents)==null?void 0:ya.filter(Qa=>{var _l,Ha,il;return JSON.stringify(Qa==null?void 0:Qa.relatedId)!=="{}"&&(Qa==null?void 0:Qa.relatedId)!==""&&(Qa!=null&&Qa.relatedId)?(_l=Qa==null?void 0:Qa.relatedId)==null?void 0:_l.includes(parseInt(je)):(Qa==null?void 0:Qa.sort)===((il=(Ha=l==null?void 0:l.fixContent)==null?void 0:Ha[0])==null?void 0:il.sort)});if((ra==null?void 0:ra.length)>0){let Qa=(we=l==null?void 0:l.fixContent)==null?void 0:we[0];Qa={...Qa,id:(Se=ra==null?void 0:ra[0])==null?void 0:Se.id};let _l={},Ha=Qa,il;return Array.isArray((qa=q==null?void 0:q.struct)==null?void 0:qa[0])?il=ca.getColumnChild((fe=q==null?void 0:q.struct)==null?void 0:fe[0]):il=q==null?void 0:q.struct,il==null||il.forEach(Ia=>{var ul,Ja;_l[Ia.prop]=((ul=Ia==null?void 0:Ia.words)!=null&&ul[0]?(Ha==null?void 0:Ha[(Ja=Ia==null?void 0:Ia.words)==null?void 0:Ja[0]])??(Ha==null?void 0:Ha[Ia==null?void 0:Ia.prop]):Ha==null?void 0:Ha[Ia==null?void 0:Ia.prop])??""}),_l.id=(fl=ra==null?void 0:ra[0])==null?void 0:fl.id,delete _l.sort,delete _l.relatedId,{tableName:"content_"+(q==null?void 0:q.id),tableContents:[_l]}}else return}))==null?void 0:me.filter(q=>q);Fe=[...Fe,...Je],await I.pageBatchDeleteApi({platId:parseInt((ue=bl==null?void 0:bl.value)==null?void 0:ue.plat_id),changeContents:Fe});let ea=[];Fe==null||Fe.forEach(q=>{var ra;(ra=q==null?void 0:q.tableContents)==null||ra.forEach(ya=>{ea.push({id:"1",request_method:"Post",request_url:"/platform/page/delete",request_param:JSON.stringify(ya),request_result:"{}",is_delete:!1,request_table:q==null?void 0:q.tableName,request_type:"delete"})})}),await I.pageBatchAddApi({platId:parseInt((Ne=bl==null?void 0:bl.value)==null?void 0:Ne.plat_id),changeContents:[{tableName:"log",tableContents:ea}]})}if((l==null?void 0:l.buttonName)==="复制新增"){let Fe=await I.getPageDataApi({platId:parseInt((pa=bl==null?void 0:bl.value)==null?void 0:pa.plat_id),pageName:"menu"});if(Fe=(_a=Fe==null?void 0:Fe.data)==null?void 0:_a.result,Fe!=null&&Fe.find(Va=>(Va==null?void 0:Va.father_name)===xl.value+"/")){ic.value=l,oc.value=Fe==null?void 0:Fe.filter(xe=>(xe==null?void 0:xe.father_name)===xl.value+"/");let Va=(ee=(Wa=l==null?void 0:l.columns)==null?void 0:Wa.find(xe=>xe==null?void 0:xe.mainKey))==null?void 0:ee.prop,je=(Ve=(la=l==null?void 0:l.fixContent)==null?void 0:la[0])==null?void 0:Ve[Va];wt.value=!0,Po.value=[{prop:Va,label:Va,name:Va,value:je}]}else{let Va=(ka=l==null?void 0:l.fixContent)==null?void 0:ka.map(Ze=>{let Je={};for(let ea in Ze)Array.isArray(Ze==null?void 0:Ze[ea])?Je[ea]=JSON.stringify(Ze==null?void 0:Ze[ea]):Je[ea]=Ze==null?void 0:Ze[ea];return Je.relatedId="",Je}),je=[{tableName:(He=l==null?void 0:l.relatedContents)==null?void 0:He.find(Ze=>Ze==null?void 0:Ze.includes("content")),tableContents:Va}];await I.pageBatchAddApi({platId:parseInt((Te=bl==null?void 0:bl.value)==null?void 0:Te.plat_id),changeContents:je});let xe=[];je==null||je.forEach(Ze=>{var Je;(Je=Ze==null?void 0:Ze.tableContents)==null||Je.forEach(ea=>{xe.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(ea),request_result:"{}",is_delete:!1,request_table:Ze==null?void 0:Ze.tableName,request_type:"copyAdd"})})}),await I.pageBatchAddApi({platId:parseInt((Re=bl==null?void 0:bl.value)==null?void 0:Re.plat_id),changeContents:[{tableName:"log",tableContents:xe}]})}}if((l==null?void 0:l.buttonName)==="methodButton"){let Fe=((Fa=(Ga=(Ge=l==null?void 0:l.columns)==null?void 0:Ge.map(we=>we==null?void 0:we.filter))==null?void 0:Ga.filter(we=>we!==""))==null?void 0:Fa[0])??"";Fe=Pa.analyzeSplitToContent(Fe,","),Fe=(Fe==null?void 0:Fe.find(we=>we==null?void 0:we.includes("@Filter")))??"";let Va=(P=l==null?void 0:l.fixContent)==null?void 0:P.map(we=>{let Se={};for(let qa in we)Array.isArray(we==null?void 0:we[qa])?Se[qa]=JSON.stringify(we==null?void 0:we[qa]):Se[qa]=we==null?void 0:we[qa];return Se}),je=await I.quoteApi({platId:parseInt((F=bl==null?void 0:bl.value)==null?void 0:F.plat_id),type:"fatherSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});je=(J=je==null?void 0:je.data)==null?void 0:J.result,je=je==null?void 0:je.filter(we=>{var Se,qa;return!((we==null?void 0:we.fatherPath)!==""&&((qa=(Se=we==null?void 0:we.quote)==null?void 0:Se[0])==null?void 0:qa.menus)===(xl==null?void 0:xl.value))});let xe=(se=(ie=l==null?void 0:l.columns)==null?void 0:ie[0])==null?void 0:se.prop,Ze=(ma=Va==null?void 0:Va[0])==null?void 0:ma[xe],Je=[{tableName:(oa=l==null?void 0:l.relatedContents)==null?void 0:oa.find(we=>we==null?void 0:we.includes("content")),tableContents:Va}],ea=(Oe=je==null?void 0:je.map(we=>{var qa,fe,fl,Qa,_l;let Se=(qa=we==null?void 0:we.contents)==null?void 0:qa.filter(Ha=>{var il;return(il=Object.values(Ha))==null?void 0:il.find(Ia=>Ia===Ze)});if((Se==null?void 0:Se.length)>0){let Ha=Va==null?void 0:Va[0];Ha={...Ha,id:(fe=Se==null?void 0:Se[0])==null?void 0:fe.id};let il={},Ia=Ha,ul;return Array.isArray((fl=we==null?void 0:we.struct)==null?void 0:fl[0])?ul=ca.getColumnChild((Qa=we==null?void 0:we.struct)==null?void 0:Qa[0]):ul=we==null?void 0:we.struct,ul==null||ul.forEach(Ja=>{var Wl,Kl;il[Ja.prop]=((Wl=Ja==null?void 0:Ja.words)!=null&&Wl[0]?(Ia==null?void 0:Ia[(Kl=Ja==null?void 0:Ja.words)==null?void 0:Kl[0]])??(Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop]):Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop])??""}),il.id=(_l=Se==null?void 0:Se[0])==null?void 0:_l.id,delete il.sort,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[il]}}else return}))==null?void 0:Oe.filter(we=>we);Je=[...Je,...ea];let q=await I.quoteApi({platId:parseInt((_e=bl==null?void 0:bl.value)==null?void 0:_e.plat_id),type:"sonSyncs",related:[{menus:o!==""?xl.value+"/"+o:xl.value,groups:l==null?void 0:l.name}]});if(q=(ve=(wa=q==null?void 0:q.data)==null?void 0:wa.result)==null?void 0:ve.filter(we=>!(Je!=null&&Je.find(Se=>(Se==null?void 0:Se.tableName)==="content_"+(we==null?void 0:we.id)))),q=q==null?void 0:q.filter(we=>{var Se,qa;return!((we==null?void 0:we.fatherPath)!==""&&((qa=(Se=we==null?void 0:we.quote)==null?void 0:Se[0])==null?void 0:qa.menus)===(xl==null?void 0:xl.value))}),Fe&&Fe!==""){(Fe==null?void 0:Fe[(Fe==null?void 0:Fe.length)-1])===","&&(Fe=Fe==null?void 0:Fe.slice(0,(Fe==null?void 0:Fe.length)-1)),Fe=(aa=(Xe=Fe==null?void 0:Fe.replace("(",di))==null?void 0:Xe.split(di))==null?void 0:aa[1],Fe=Fe==null?void 0:Fe.slice(0,(Fe==null?void 0:Fe.length)-1),(Fe==null?void 0:Fe[0])==="*"&&(Fe="{"+((xa=(Pe=Fe==null?void 0:Fe.replace("{",di))==null?void 0:Pe.split(di))==null?void 0:xa[1])),Fe=(Le=Fe==null?void 0:Fe.replaceAll("{",""))==null?void 0:Le.replaceAll("}","");let we=ca.calculatorAndToOr(Fe);we=we==null?void 0:we[0];let Se;if((va=Object.values(we))!=null&&va.some(qa=>(qa==null?void 0:qa[0])==="*")){let qa=(Ce=(re=Hn.value)==null?void 0:re.find(fe=>(fe==null?void 0:fe.condition)==="child"))!=null&&Ce.value?(Ur==null?void 0:Ur.value)+"/"+((fa=(Z=Hn.value)==null?void 0:Z.find(fe=>(fe==null?void 0:fe.condition)==="child"))==null?void 0:fa.value):Ur==null?void 0:Ur.value;Se=await Vr(qa,!1)}for(let qa in we)if(((Ye=we==null?void 0:we[qa])==null?void 0:Ye[0])==="*"){let fe=(ga=(Ya=(Ue=we[qa])==null?void 0:Ue.slice(1,(Ma=we[qa])==null?void 0:Ma.length))==null?void 0:Ya.split(":"))==null?void 0:ga[0],fl=($a=(ba=we[qa])==null?void 0:ba.split(":"))==null?void 0:$a[1],Qa=(Sa=Se==null?void 0:Se.filter(_l=>(_l==null?void 0:_l.name)===fe))==null?void 0:Sa[0];Qa=(Oa=(Na=Qa==null?void 0:Qa.compData)==null?void 0:Na.find(_l=>(_l==null?void 0:_l.key)==="tableContents"))==null?void 0:Oa.contents,Qa=(Be=Qa==null?void 0:Qa[0])==null?void 0:Be[fl],we[qa]=Qa}Fe=((tl=Object.values(we))==null?void 0:tl[0])??""}let ra=(Ea=q==null?void 0:q.map(we=>{var qa,fe,fl,Qa,_l;let Se=(qa=we==null?void 0:we.contents)==null?void 0:qa.filter(Ha=>{var il;return(il=Object.values(Ha))==null?void 0:il.find(Ia=>Ia===(Fe===""?Ze:Fe))});if((Se==null?void 0:Se.length)>0){let Ha=Va==null?void 0:Va[0];Ha={...Ha,id:(fe=Se==null?void 0:Se[0])==null?void 0:fe.id};let il={},Ia=Ha,ul;return Array.isArray((fl=we==null?void 0:we.struct)==null?void 0:fl[0])?ul=ca.getColumnChild((Qa=we==null?void 0:we.struct)==null?void 0:Qa[0]):ul=we==null?void 0:we.struct,ul==null||ul.forEach(Ja=>{var Kl,$l,Fl,gr;let Wl=(Kl=l==null?void 0:l.columns)==null?void 0:Kl.find(rr=>{var kr,wr,Er;return((wr=(kr=rr==null?void 0:rr.words)==null?void 0:kr[0])==null?void 0:wr.replaceAll("'",""))===(Ja==null?void 0:Ja.prop)&&((Er=rr==null?void 0:rr.functionRelatedWords)==null?void 0:Er.length)>0});Wl=($l=Wl==null?void 0:Wl.prop)==null?void 0:$l.replaceAll("'",""),il[Ja.prop]=((Fl=Ja==null?void 0:Ja.words)!=null&&Fl[0]?(Ia==null?void 0:Ia[(gr=Ja==null?void 0:Ja.words)==null?void 0:gr[0]])??(Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop])??(Ia==null?void 0:Ia[Wl]):(Ia==null?void 0:Ia[Ja==null?void 0:Ja.prop])??(Ia==null?void 0:Ia[Wl]))??void 0}),il.id=(_l=Se==null?void 0:Se[0])==null?void 0:_l.id,delete il.sort,{tableName:"content_"+(we==null?void 0:we.id),tableContents:[il]}}else return}))==null?void 0:Ea.filter(we=>we);Je=[...Je,...ra],await I.pageBatchUpdateApi({platId:parseInt((El=bl==null?void 0:bl.value)==null?void 0:El.plat_id),changeContents:Je});let ya=[];Je==null||Je.forEach(we=>{var Se;(Se=we==null?void 0:we.tableContents)==null||Se.forEach(qa=>{ya.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(qa),request_result:"{}",is_delete:!1,request_table:we==null?void 0:we.tableName,request_type:"method"})})}),await I.pageBatchAddApi({platId:parseInt((ml=bl==null?void 0:bl.value)==null?void 0:ml.plat_id),changeContents:[{tableName:"log",tableContents:ya}]})}_r.setRefreshCurStructure(!0),await mt(l)},vt=async(l,r,n)=>{var s;let o=l==null?void 0:l.find(c=>(c==null?void 0:c.id)===r);if(o){let c=(s=o.compData)==null?void 0:s.map(y=>{var f;if((y==null?void 0:y.key)==="tableContents"){let v={...y,contents:n};return v.contents=(f=(v==null?void 0:v.contents)??[])==null?void 0:f.map(m=>{let u={};for(let x in m)JSON.stringify(m==null?void 0:m[x])==="{}"?u[x]="":u[x]=m==null?void 0:m[x];return u}),v}return y});return o.compData=await kt(c,{}),l=l==null?void 0:l.map(y=>((y==null?void 0:y.id)===(o==null?void 0:o.id)&&(y=o),y)),l}else{let c=l==null?void 0:l.filter(f=>{var v;return(f==null?void 0:f.children)&&((v=f==null?void 0:f.children)==null?void 0:v.length)>0||(f==null?void 0:f.comp)==="Tabs"}),y=c==null?void 0:c.map(async f=>{var v;return f!=null&&f.children&&((v=f==null?void 0:f.children)==null?void 0:v.length)>0?f.children=await vt(f==null?void 0:f.children,r,n):f.compData=await vt(f==null?void 0:f.compData,r,n),f});return c=await Promise.all(y),c}},mt=async l=>{var c,y,f,v,m,u,x;let r=(c=l==null?void 0:l.relatedContents)==null?void 0:c.filter(E=>E==null?void 0:E.includes("content_")),n=await I.getAllTables({platId:parseInt((y=bl==null?void 0:bl.value)==null?void 0:y.plat_id),tableNames:r});if(n=(v=(f=n==null?void 0:n.data)==null?void 0:f.result)==null?void 0:v[0],!n||!Array.isArray(n))return;n=n==null?void 0:n.map(E=>{E==null||delete E.source_table;const B={};for(let w in E){const V=E==null?void 0:E[w],A=V&&Object.prototype.toString.call(V)==="[object Object]"&&Object.keys(V).length===0,N=Array.isArray(V)&&V.length===0;V==null||V==="{}"||A||N?B[w]="":B[w]=V}return B});let o=(u=(m=r==null?void 0:r[0])==null?void 0:m.split("_"))==null?void 0:u[1],s=await vt(er.value,o,n);er.value=(x=er.value)==null?void 0:x.map(E=>{var B,w;return(B=s==null?void 0:s[0])!=null&&B.tabInform&&((w=s==null?void 0:s[0])==null?void 0:w.tabInform)===(E==null?void 0:E.tabInform)?E=s==null?void 0:s[0]:(E!=null&&E.name?(E==null?void 0:E.name)===(s==null?void 0:s.name):(E==null?void 0:E.id)===(s==null?void 0:s.id))&&(E=s),E})},r0=l=>{let r=Po.value;Po.value=r==null?void 0:r.map(n=>(n.value=l==null?void 0:l[n==null?void 0:n.prop],n))},n0=async()=>{var E,B,w,V,A,N,Y,b,$,T;let l=ic.value,r=oc.value,n=(B=(E=l==null?void 0:l.columns)==null?void 0:E.find(k=>k==null?void 0:k.mainKey))==null?void 0:B.prop,o=(V=(w=Po.value)==null?void 0:w[0])==null?void 0:V.value,s=(A=l==null?void 0:l.fixContent)==null?void 0:A.map(k=>{var U;let _={};for(let W in k)Array.isArray(k==null?void 0:k[W])?_[W]=JSON.stringify(k==null?void 0:k[W]):_[W]=k==null?void 0:k[W];return(U=l==null?void 0:l.columns)==null||U.forEach(W=>{(W==null?void 0:W.formType)==="Upload"&&(_==null?void 0:_[W==null?void 0:W.prop])===""&&(_[W==null?void 0:W.prop]="{}")}),_[n]=o,_}),c=[{tableName:(N=l==null?void 0:l.relatedContents)==null?void 0:N.find(k=>k==null?void 0:k.includes("content")),tableContents:s}];await I.pageBatchAddApi({platId:parseInt((Y=bl==null?void 0:bl.value)==null?void 0:Y.plat_id),changeContents:c}),r=r==null?void 0:r.filter(k=>{var _,U,W;return(W=k==null?void 0:k.object_name)==null?void 0:W.includes((U=(_=l==null?void 0:l.fixContent)==null?void 0:_[0])==null?void 0:U[n])});let y=[],f=new Map;r==null||r.forEach(k=>{y.push(`content_${k==null?void 0:k.object_id}`),y.push(`struct_${k==null?void 0:k.object_id}`),f.set(k==null?void 0:k.object_id,k)});let v=await I.getAllTables({platId:parseInt((b=bl==null?void 0:bl.value)==null?void 0:b.plat_id),tableNames:y});v=($=v==null?void 0:v.data)==null?void 0:$.result;let m=[],u=[];v=Pa.chunk(v,2),v==null||v.forEach(k=>{var W,ce,Ee,Ie,De,ne,ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa,ee;let _=f.get((Ie=(Ee=(ce=(W=k==null?void 0:k[1])==null?void 0:W[0])==null?void 0:ce.source_table)==null?void 0:Ee.split("_"))==null?void 0:Ie[1]),U=(ge=(ne=(De=_==null?void 0:_.object_name)==null?void 0:De.split("/"))==null?void 0:ne.filter((la,Ve)=>{var ka,He;return((He=(ka=_==null?void 0:_.object_name)==null?void 0:ka.split("/"))==null?void 0:He.length)-1!==Ve}))==null?void 0:ge.join("/");if(U=U+"/"+o,u!=null&&u.find(la=>(la==null?void 0:la.path)===U)||u.push({fatherPath:_==null?void 0:_.father_name,isShow:_==null?void 0:_.is_show,path:U}),((de=(X=k==null?void 0:k[1])==null?void 0:X[0])==null?void 0:de.类型)==="Table"){let la=((oe=(Ta=(Ke=k==null?void 0:k[1])==null?void 0:Ke[0])==null?void 0:Ta.结构)==null?void 0:oe.contents)??[],Ve=pl.safeClone(la);Array.isArray(Ve==null?void 0:Ve[0])&&(Ve=ca.getColumnChild(Ve==null?void 0:Ve[0]));let ka=[];if(((S=k==null?void 0:k[0])==null?void 0:S.length)>0&&(ka=(le=k==null?void 0:k[0])==null?void 0:le.map(He=>Ve==null?void 0:Ve.map(Re=>(Re=(He==null?void 0:He[Re==null?void 0:Re.prop])??"",Re)))),m!=null&&m.find(He=>(He==null?void 0:He.key)===U)){let He=(me=m==null?void 0:m.find(Re=>(Re==null?void 0:Re.key)===U))==null?void 0:me.contents;He.push({isShow:_==null?void 0:_.is_show,filter:((pa=(Ne=(ue=k==null?void 0:k[1])==null?void 0:ue[0])==null?void 0:Ne.引用)==null?void 0:pa.contents)??"",key:"Table",name:Object.values(_==null?void 0:_.name),tableColumns:la,tableContents:ka});let Te=m==null?void 0:m.findIndex(Re=>(Re==null?void 0:Re.key)===U);m[Te].contents=He}else m.push({key:U,contents:[{isShow:_==null?void 0:_.is_show,filter:((ee=(Wa=(_a=k==null?void 0:k[1])==null?void 0:_a[0])==null?void 0:Wa.引用)==null?void 0:ee.contents)??"",key:"Table",name:Object.values(_==null?void 0:_.name),tableColumns:la,tableContents:ka}]})}});let x=[];x.push({key:"menuPath",contents:u}),x=[...x,...m],await I.createPlatFormDataApi({platId:parseInt((T=bl==null?void 0:bl.value)==null?void 0:T.plat_id),changeData:x}),wt.value=!1,_r.setRefreshTable(!0)},Ei=async(l,r)=>{},Si=async l=>{er.value=await ca.getDeepDiffItems(l),_r.setItemData(er.value),_r.setOriginalData(er.value)};a.ref();const o0=a.ref(null),i0=()=>{var l,r;console.log("倒计时结束时"),I.ElMessageBox.alert(`超时未提交,【${(r=(l=xl.value)==null?void 0:l.split("/"))==null?void 0:r[0]}】失败`,"告警",{confirmButtonText:"确认",type:"error"})},uc=a.ref([]),t0=a.computed(()=>{var l,r;return(r=(l=ft.value)==null?void 0:l[xl.value])==null?void 0:r.filter(n=>{var o;return((o=n==null?void 0:n.key)==null?void 0:o.type)==="gridLayout"})});a.watch(()=>[Kf.value],()=>{nn.setSelectTitle([]),nn.setChooseTitle([])},{deep:!0});a.watch(()=>wi.value,async(l,r)=>{var o,s,c,y,f,v;if(JSON.stringify(l)===JSON.stringify(r))return;let n=(o=wi.value)==null?void 0:o.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==Ur.value);if((n==null?void 0:n.length)>0){Sr.setContentLoading(!0);let m=((s=n==null?void 0:n[0])==null?void 0:s.relatedContent)??(xl==null?void 0:xl.value),u=m+"/"+((c=n==null?void 0:n[0])==null?void 0:c.value),x=!!((y=n==null?void 0:n[0])!=null&&y.parentContent),E=await Vr(u,x,{originPath:m});E=(f=E==null?void 0:E.filter(V=>V))==null?void 0:f.map(V=>(V.isShow=!0,V)),console.log(E,"loadingContents");let B=await ca.getDeepDiffItems(E),w=B==null?void 0:B.filter(V=>V==null?void 0:V.choice);Ti.setSelectTab((v=w==null?void 0:w[0])==null?void 0:v.choiceName),B=B==null?void 0:B.filter(V=>{var A;return!(V!=null&&V.choiceName)||(V==null?void 0:V.choiceName)===((A=w==null?void 0:w[0])==null?void 0:A.choiceName)}),er.value=B,Sr.setContentLoading(!1)}});const s0=(l,r)=>{setTimeout(async()=>{var f,v,m;let n=(f=wi.value)==null?void 0:f.filter(u=>(u==null?void 0:u.condition)==="child"&&(u==null?void 0:u.value)!==""&&(u==null?void 0:u.parentContent)!==Ur.value),o=xl==null?void 0:xl.value,s=xl==null?void 0:xl.value;(n==null?void 0:n.length)>0&&(s=((v=n==null?void 0:n[0])==null?void 0:v.relatedContent)??(xl==null?void 0:xl.value),o=s+"/"+((m=n==null?void 0:n[0])==null?void 0:m.value));let c=await Vr(o,!1,{originPath:s});c=c==null?void 0:c.map(u=>(u.isShow=!0,u));let y=await ca.getDeepDiffItems(c);er.value=y==null?void 0:y.filter(u=>!(u!=null&&u.step)||(u==null?void 0:u.step)===(l==null?void 0:l.title))},10)},c0=l=>{setTimeout(async()=>{var y,f,v;let r=(y=wi.value)==null?void 0:y.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==Ur.value),n=xl==null?void 0:xl.value,o=xl==null?void 0:xl.value;(r==null?void 0:r.length)>0&&(o=((f=r==null?void 0:r[0])==null?void 0:f.relatedContent)??(xl==null?void 0:xl.value),n=o+"/"+((v=r==null?void 0:r[0])==null?void 0:v.value));let s=await Vr(n,!1,{originPath:o});s=s==null?void 0:s.map(m=>(m.isShow=!0,m)),Ti.setSelectTab(l);let c=await ca.getDeepDiffItems(s);er.value=c==null?void 0:c.filter(m=>!(m!=null&&m.choiceName)||(m==null?void 0:m.choiceName)===l)},10)};a.watch(()=>Wf.value,l=>{l!=null&&l.length||(er.value=[])},{immediate:!0});a.watch(()=>[xl.value],async l=>{var c,y,f,v;if(!xl.value)return;if(xl.value==="/"){er.value=[];return}Sr.setCurrentMenuPath(xl.value),_r.setLockingPage(""),er.value=[];let r=a.getCurrentInstance();(c=r==null?void 0:r.scope)==null||c.stop(),r=null,So.value=!1,Sr.setContentLoading(!0),nc.value=!0;let n=l==null?void 0:l[0],o=n,s=(y=Hn.value)==null?void 0:y.filter(m=>(m==null?void 0:m.condition)==="child"&&(m==null?void 0:m.value)!==""&&(m==null?void 0:m.parentContent)!==xl.value&&!(m!=null&&m.relatedContent));if((s==null?void 0:s.length)>0&&(n=n+"/"+((f=s==null?void 0:s[0])==null?void 0:f.value)),n==="系统管理/日志管理")er.value=await Ff("log");else{let m=await Vr(n,!0,{originPath:o});m=m==null?void 0:m.map(E=>(E.isShow=!0,E));let u=await ca.getDeepDiffItems(m),x=u==null?void 0:u.filter(E=>E==null?void 0:E.choice);Ti.setSelectTab((v=x==null?void 0:x[0])==null?void 0:v.choiceName),er.value=u==null?void 0:u.filter(E=>{var B;return!(E!=null&&E.choiceName)||(E==null?void 0:E.choiceName)===((B=x==null?void 0:x[0])==null?void 0:B.choiceName)})}Sr.setContentLoading(!1),_r.setExtraContents([]),nn.setSelectIndex(""),nn.setSelectMenu(""),_r.setItemData(er.value),_r.setOriginalData(er.value),_r.setRefreshTable(!1),a.nextTick(()=>{qn.value=qn.value++,So.value=!0})},{immediate:!0});a.watch(()=>[ds.value],async()=>{var l,r,n,o;if(ds.value){er.value=[];let s=a.getCurrentInstance();(l=s==null?void 0:s.scope)==null||l.stop(),s=null,So.value=!1,Sr.setContentLoading(!0),nc.value=!0;let c=Ur==null?void 0:Ur.value,y=c,f=(r=Hn.value)==null?void 0:r.filter(x=>(x==null?void 0:x.condition)==="child"&&(x==null?void 0:x.value)!==""&&(x==null?void 0:x.parentContent)!==(Ur==null?void 0:Ur.value));(f==null?void 0:f.length)>0&&(c=c+"/"+((n=f==null?void 0:f[0])==null?void 0:n.value));let v=await Vr(c,!0,{originPath:y});v=v==null?void 0:v.map(x=>(x.isShow=!0,x));let m=await ca.getDeepDiffItems(v),u=m==null?void 0:m.filter(x=>x==null?void 0:x.choice);if(Ti.setSelectTab((o=u==null?void 0:u[0])==null?void 0:o.choiceName),er.value=m==null?void 0:m.filter(x=>{var E;return!(x!=null&&x.choiceName)||(x==null?void 0:x.choiceName)===((E=u==null?void 0:u[0])==null?void 0:E.choiceName)}),Sr.setContentLoading(!1),_r.setExtraContents([]),nn.setSelectIndex(""),nn.setSelectMenu(""),_r.setItemData(er.value),_r.setOriginalData(er.value),_r.setRefreshTable(!1),(f==null?void 0:f.length)>0){let x=[...Hn.value,...f];nn.setSelectTitle(x)}a.nextTick(()=>{qn.value=qn.value++,So.value=!0})}},{immediate:!0,deep:!0});const u0=async()=>{Sr.setLinkMenuInfo(null),Sr.setActiveMenuPath(qf.value),er.value=null,_r.setRouteToChildPath(""),Sr.setChildMenu("")},d0=l=>new RegExp("button","i").test(l),p0=l=>/^[\u4e00-\u9fa5]+\/[\u4e00-\u9fa5]+\^(.+)$/.test(l),dc=l=>{if(p0(l)){const r=l==null?void 0:l.split("^");(r==null?void 0:r.length)>0&&(r!=null&&r[0])&&Sr.setLinkMenuInfo({path:r==null?void 0:r[0],data:r==null?void 0:r[1]})}},pc=async(l,r,n)=>{var E,B,w,V,A,N,Y,b,$,T,k,_;let o="",s="";for(let U in r)(r==null?void 0:r[U])===l&&(s=U);n==null||n.forEach(U=>{(U==null?void 0:U.prop)===s&&(o=U==null?void 0:U.fatherPath)});let c=o===""?xl.value:o;o!==""&&Sr.setCurrentMenuPath(c),Sr.setCurrentMenuPath(c+"/"+l),Sr.setContentLoading(!0),await Vr(c+"/"+l,!0,{originPath:c+"/",row:r});let y=await Vr(c,!1),f=(E=y==null?void 0:y.filter(U=>(U==null?void 0:U.comp)==="Table"))==null?void 0:E[0],v=((A=(V=(w=(B=f==null?void 0:f.compData)==null?void 0:B.find(U=>(U==null?void 0:U.key)==="header"))==null?void 0:w.contents)==null?void 0:V[0])==null?void 0:A.prop)??((T=($=(b=(Y=(N=f==null?void 0:f.compData)==null?void 0:N.find(U=>(U==null?void 0:U.key)==="header"))==null?void 0:Y.contents)==null?void 0:b[0])==null?void 0:$[0])==null?void 0:T.prop),m=(_=(k=f==null?void 0:f.compData)==null?void 0:k.find(U=>(U==null?void 0:U.key)==="tableContents"))==null?void 0:_.contents;m=m==null?void 0:m.map(U=>({label:U==null?void 0:U[v],value:U==null?void 0:U[v]}));let u=Hn.value,x={value:l,condition:"child",options:m,relatedContent:c,isShow:!0};u.push(x),nn.setSelectTitle(u),nn.setChooseTitle([x]),Sr.setContentLoading(!1),_r.setExtraContents([]),nn.setSelectIndex(""),nn.setSelectMenu(""),_r.setItemData(er.value),_r.setOriginalData(er.value)},f0=l=>{sc.value=l},xo=a.reactive({index:0,comp:null}),h0=a.computed(()=>{var l;return(l=er.value)==null?void 0:l.map((r,n)=>({id:r.id,name:r.name,status:v0(r,n)}))}),fc=(l,r)=>{var v,m,u,x,E;const n=r?l:l-2,o=(v=er.value)==null?void 0:v[n],s=(u=(m=o==null?void 0:o.compData)==null?void 0:m.find(B=>(B==null?void 0:B.key)==="header"))==null?void 0:u.contents,c=s==null?void 0:s.findIndex(B=>(B==null?void 0:B.isMainKey)&&(B==null?void 0:B.label)!=="操作"),y=c===-1?0:c,f=(E=(x=o==null?void 0:o.compData)==null?void 0:x.find(B=>(B==null?void 0:B.key)==="tableContents"))==null?void 0:E.contents;return{valid:f==null?void 0:f.every(B=>B==null?void 0:B[y+1]),length:(f==null?void 0:f.length)||0}},v0=(l,r)=>{var o;let n="process";if(((o=l==null?void 0:l.comp)==null?void 0:o.toUpperCase())==="TABLE"){const{valid:s,length:c}=fc(r,!0);xo.index===r?n="process":c===0?n="wait":n=s?"success":"error"}return n},hc=l=>{var n,o,s,c,y;const r=l+1;if(r>1&&((s=(o=(n=er.value)==null?void 0:n[l])==null?void 0:o.comp)==null?void 0:s.toUpperCase())==="TABLE"){const{valid:f}=fc(r);f?(xo.index=r,xo.comp=(c=er.value)==null?void 0:c[l]):rl.ElMessage({showClose:!0,type:"warning",message:"当前流程有输入未完成"})}else xo.index=r,xo.comp=(y=er.value)==null?void 0:y[l]},vc=a.computed(()=>{var l,r;return(r=(l=tc.value)==null?void 0:l[0])==null?void 0:r.isStepLayout});a.watch(()=>vc.value,l=>{l&&hc(0)},{immediate:!0});const m0={class:"table-content"},y0={class:"menu-config-wrap"},g0=["onClick"],b0={key:0,class:"viewport-wrap"},k0=["onClick"],x0={title:"选择显示列信息"},_0={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},w0=["title"],C0={class:"col-operate-wrap"},E0={key:0,class:"col-operate-radio-wrapper"},S0={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},D0={key:0,style:{display:"flex","justify-content":"center","align-items":"center"}},N0={class:"pop-view"},B0={class:"pop-wrapper"},T0={class:"file-list-pop"},A0=["title","onClick"],z0=["onClick"],M0=["onClick"],O0={key:1,style:{display:"flex","justify-content":"flex-end",gap:"8px","margin-top":"8px"}},I0={class:"form-content"},L0={key:0,class:"dialog-footer"},$0={class:"dialog-footer"},R0={class:"ocr-dialog-content"},V0={class:"ocr-steps"},P0={key:0,class:"ocr-action-buttons"},F0={key:1,class:"ocr-preview-area"},j0={class:"ocr-file-grid"},H0={class:"file-thumbnail"},U0=["src"],q0={key:1,class:"thumbnail-placeholder"},W0={class:"progress-svg",viewBox:"0 0 36 36"},K0=["stroke","stroke-width","stroke-dasharray"],Y0={key:0,class:"progress-icon"},G0={key:1,class:"progress-icon"},J0=["onClick"],X0={class:"file-name"},Z0={key:0,class:"ocr-recognize-button"},Q0={key:2,class:"ocr-progress-section"},e3={key:3,class:"ocr-confirm-area"},a3={class:"ocr-preview-tip"},l3={class:"ocr-preview-table"},r3={style:{display:"flex","align-items":"center",gap:"8px"}},n3={key:0},o3={key:4,class:"ocr-success-area"},i3={key:0,class:"ocr-dialog-footer"},t3={class:"form-content"},s3={style:{display:"flex","justify-content":"space-between",gap:"8px"}},c3={style:{display:"flex"}},fs="ss-ocr-upload-history",u3="ss-ocr-cert-history-v1",d3={__name:"index",props:{pageLayout:{type:String,default:"vertical"},related:{type:Array,default:[]},level:{type:Number,default:1},compName:{type:String,default:"",required:!1},compNames:{type:Array,default:()=>[],required:!1},compItem:{type:Object,default:()=>{}},operatingForm:{type:Object,default:()=>{}},cacheNewData:{type:Object,default:()=>{}},config:Object,parentTableId:{type:Number,default:0},itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,isDevMode:Boolean,changedContent:{type:Object,default:()=>{}},showHeader:{type:Boolean,default:!0},allowSelect:{type:Boolean,default:!0},allowOperate:{type:Boolean,default:!0},allMapContents:{type:Object,default:()=>{}}},emits:["getSliceContLength","clickMainKey","change","contentChange","onButtonClick","contentClick","pageChange","rowClick","routeUrl"],setup(l,{emit:r}){var It;const n=a.ref([]),o=xt(I.pinia),s=a.ref(null),c=a.ref(new Set),y=a.ref(new Map),f=a.ref(new Map),v=new Map,m=a.ref(new Map),u=l,x=a.ref((u==null?void 0:u.allowSelect)??!0),E=a.ref(((It=u==null?void 0:u.config)==null?void 0:It.showIndex)??!0),B=a.ref(),w=a.ref(!0),V=a.ref(!1),A=a.ref([]),N={sortable:"switch",filterable:"switch",showSummary:"switch",operable:"switch",fixed:"radio"},Y=a.ref([{label:"排序",value:"sortable",checked:!1},{label:"合计",value:"showSummary",checked:!1},{type:"radio",label:"固定",value:"fixed",checked:"",options:[{label:"无",value:!1},{label:"左",value:"left"},{label:"右",value:"right"}]}]),b=ca.useOriginalState(I.pinia);let $="$R";const{originalPath:T}=I.storeToRefs(b),k=T.value,_=a.computed(()=>{var h;const d=(h=ca.getAllLeafNodes(De.value)||[])==null?void 0:h.filter(z=>(z==null?void 0:z.type)!=="operate"&&(z==null?void 0:z.label)!=="操作"&&(z==null?void 0:z.prop)!=="operate");return d.length>0?d.every(z=>!!(z!=null&&z.sortable)):!1});a.computed(()=>{var h;return(h=De.value)==null?void 0:h.every(z=>z==null?void 0:z.filterable)}),a.computed(()=>{var h;return(h=De.value)==null?void 0:h.every(z=>z==null?void 0:z.operable)});const U=a.ref(!0),W=a.ref([]),ce=a.reactive({column:{},status:!1,text:"合计"}),Ee=a.reactive({currentPage:1,pageSize:10,total:0,pageSizes:[5,10,20]}),Ie=r,De=a.ref([]),ne=a.ref([]),ge=a.ref([]),X=a.reactive({prop:"",order:null}),de=a.ref([]),Ke=a.ref(!1),Ta=a.ref(!1),oe=a.ref(null),{isUseBackdrop:S,initTrackFileType:le,getFileExtension:me,setData:ue,getFileInfo:Ne,getFilesInfo:pa}=bi.useThreeSystem(),_a=a.ref([]),Wa=a.ref(!1),ee=a.ref(),la=I.useMenuState(),{importLoading:Ve,activeMenuPath:ka,contentLoading:He,linkMenuInfo:Te}=I.storeToRefs(la),Re=ca.useTableComp(I.pinia),Ge=I.useModelComp(I.pinia),Ga=Wn(I.pinia),{extraContents:Fa,cacheUpdatingData:P,tableViewContents:F,tableLoading:J,pageMapState:ie,lockingPage:se}=I.storeToRefs(Ge),{selectTab:ma}=I.storeToRefs(Ga),{compType:oa,hasEditable:Oe}=Hs.useRole(),_e=a.ref([]),wa=a.ref([]),ve=a.ref(new Map);a.ref(!1);const Xe=a.ref("");a.ref();const aa=a.ref(!0),Pe=a.ref(0),xa=a.ref(!0),Le=a.ref(""),va=a.ref(!1),re=a.ref(null);a.ref([]);const Ce=a.ref({label:"查看三维模型"}),Z=a.ref(!1),fa=a.ref(),Ye=a.ref([]),Ma=a.ref([]),Ue=a.ref(!1),Ya=a.ref([]),ga=a.ref([]),ba=a.ref([]),$a=a.ref([]),Sa=a.ref([]),Na=()=>{try{const d=localStorage.getItem(fs),h=d?JSON.parse(d):[];Sa.value=Array.isArray(h)?h:[]}catch{Sa.value=[]}},Oa=()=>{try{localStorage.setItem(fs,JSON.stringify(Sa.value||[]))}catch{}},Be=d=>{var Q,ae,j;if(!d)return;const h=d.url||((Q=d==null?void 0:d.uploadResult)==null?void 0:Q.url)||"",z=d.name||((ae=d==null?void 0:d.uploadResult)==null?void 0:ae.name)||((j=d==null?void 0:d.uploadResult)==null?void 0:j.fileName)||"";if(!h&&!z)return;const O={name:z,url:h,ts:Date.now()},R=String(O.name||"").trim().toLowerCase(),D=(Sa.value||[]).findIndex(he=>String((he==null?void 0:he.name)||"").trim().toLowerCase()===R);D>-1&&Sa.value.splice(D,1),Sa.value.unshift(O),Sa.value.length>20&&(Sa.value=Sa.value.slice(0,20)),Oa()};Na();const tl=(d,h)=>`${u3}:${String(d??"")}:${String(h??"")}`,Ea=(d,h)=>{try{const z=sessionStorage.getItem(tl(d,h)),O=z?JSON.parse(z):[];return Array.isArray(O)?O:[]}catch{return[]}},El=(d,h,z)=>{try{sessionStorage.setItem(tl(d,h),JSON.stringify(Array.isArray(z)?z:[]))}catch{}},ml=(d,h,z)=>{if(!h)return;const O=Ea(d,h),R=[z,...O||[]].filter(Boolean).slice(0,1);return El(d,h,R),R},Fe=(d,h,z)=>{if(!h||!z)return;const O=tl(d,h),R=tl(d,z);try{const D=sessionStorage.getItem(O);if(!D)return;const Q=(()=>{try{const he=JSON.parse(D);return Array.isArray(he)?he:[]}catch{return[]}})(),ae=Ea(d,z),j=[...Q,...ae||[]].filter(Boolean).sort((he,be)=>Number((be==null?void 0:be.ts)||0)-Number((he==null?void 0:he.ts)||0)).slice(0,1);sessionStorage.setItem(R,JSON.stringify(j)),sessionStorage.removeItem(O)}catch{}},Va=a.ref(!1),je=a.ref(!1),xe=a.ref([]),Ze=a.ref(null);a.ref(!1),a.ref([]),a.ref(""),a.ref("");const Je=a.ref(!1),ea=a.ref([]),q=a.ref(1),ra=a.ref(new Map),ya=a.ref(new Map),we=a.ref(0),Se=a.ref(!1),qa=a.ref([]),fe=a.ref([]),fl=d=>{var h;try{const z=(h=ca.getAllLeafNodes(De.value)||[])==null?void 0:h.filter(O=>(O==null?void 0:O.type)!=="operate"&&(O==null?void 0:O.label)!=="操作"&&(O==null?void 0:O.prop)!=="operate");return(z==null?void 0:z.find(O=>(O==null?void 0:O.prop)===d||(O==null?void 0:O.label)===d))||null}catch{return null}},Qa=d=>{const h=fl(d),z=(h==null?void 0:h.formType)||(h==null?void 0:h.columnType)||"Input";return pl.getComponent(z)||pl.getComponent("Input")},_l=a.ref([]),Ha=a.ref(null),il=a.ref([]),Ia=a.ref(null),ul=a.ref(""),Ja=a.ref(!1),Wl=a.ref([]),Kl=a.ref(""),$l=a.ref(!1),Fl=a.ref([]),gr=a.ref([]),rr=a.ref([]),kr=a.ref(null),wr=a.ref([]),Er=a.ref("");a.computed(()=>{var d;try{const h=(d=ca.getAllLeafNodes(De.value)||[])==null?void 0:d.filter(O=>(O==null?void 0:O.type)!=="operate"&&(O==null?void 0:O.label)!=="操作"&&(O==null?void 0:O.prop)!=="operate"),z=new Map;return h==null||h.forEach(O=>{O!=null&&O.label&&(O!=null&&O.prop)&&z.set(O.label,O.prop)}),z.get("编号")||""}catch{return""}});const un=a.computed(()=>{var d;try{const h=(d=ca.getAllLeafNodes(De.value)||[])==null?void 0:d.filter(O=>(O==null?void 0:O.type)!=="operate"&&(O==null?void 0:O.label)!=="操作"&&(O==null?void 0:O.prop)!=="operate"),z=new Map;return h==null||h.forEach(O=>{O!=null&&O.label&&(O!=null&&O.prop)&&z.set(O.label,O.prop)}),z.get("名称")||""}catch{return""}}),Jr=a.computed(()=>{var d;try{const h=(d=ca.getAllLeafNodes(De.value)||[])==null?void 0:d.filter(O=>(O==null?void 0:O.type)!=="operate"&&(O==null?void 0:O.label)!=="操作"&&(O==null?void 0:O.prop)!=="operate"),z=new Map;return h==null||h.forEach(O=>{O!=null&&O.label&&(O!=null&&O.prop)&&z.set(O.label,O.prop)}),z.get("制造厂")||""}catch{return""}}),dn=()=>{$l.value=!1,Fl.value=[],gr.value=[],rr.value=[],kr.value=null,wr.value=[],Er.value=""},Xr=d=>d==null?!1:typeof d=="string"?d.trim()!=="":Array.isArray(d)?d.length>0:!0,qr=(d,h)=>{const z=(d==null?void 0:d.ocrRow)||{};for(const R of Object.keys(z))R==="id"||R==="_isOCRRow"||R==="_ocrTableId"||Xr(z[R])&&(h[R]=z[R]);const O=wa.value.find(R=>R.id===h.id);if(O)for(const R of Object.keys(z))R==="id"||R==="_isOCRRow"||R==="_ocrTableId"||Xr(z[R])&&(O[R]=z[R]);ve.value&&ve.value.set(h.id,h),ml(u==null?void 0:u.index,h.id,d==null?void 0:d.versionItem),gr.value=[...gr.value||[],JSON.parse(JSON.stringify(h))]},pn=async(d,h=null)=>{var z,O,R,D,Q,ae,j;try{const he=(z=ca.getAllLeafNodes(De.value)||[])==null?void 0:z.filter(ia=>(ia==null?void 0:ia.type)!=="operate"&&(ia==null?void 0:ia.label)!=="操作"&&(ia==null?void 0:ia.prop)!=="operate"),be=new Map;he==null||he.forEach(ia=>{ia!=null&&ia.label&&(ia!=null&&ia.prop)&&be.set(ia.label,ia.prop)});const $e=be.get("系统编号")||be.get("编号");if(!$e){console.warn("未找到系统编号字段,跳过向检校记录表插入数据");return}const ze=h||kr.value;if((Array.isArray(ze==null?void 0:ze.result)?ze.result:[]).length===0){console.warn("OCR识别结果为空,跳过向检校记录表插入数据");return}for(let ia=0;ia<d.length;ia++){const ja=d[ia],Aa=ja[$e];if(!Aa){console.warn(`第 ${ia+1} 条匹配行缺少系统编号,跳过`);continue}const na=`设备管理/试验设备/${Aa}`,Xa=await I.getPageDataApi({platId:parseInt((O=Rl.value)==null?void 0:O.plat_id),pageName:na});if(!((R=Xa==null?void 0:Xa.data)!=null&&R.result)||!Array.isArray(Xa.data.result)){console.warn(`未找到详情页数据: ${na}`);continue}const sa=Xa.data.result.find(ta=>(ta==null?void 0:ta.property_name)==="校检记录");if(!sa){console.warn(`详情页 ${na} 中未找到校检记录表`);continue}const Ua=(D=sa.contents)==null?void 0:D.find(ta=>(ta==null?void 0:ta.key)&&ta.key.startsWith("content_"));if(!Ua||!Ua.key){console.warn("校检记录表中未找到 content item");continue}const te=Ua.key,Da=Array.isArray(Ua.value)?Ua.value:[];if(Da.length>=5){const ke=[...Da].sort((ua,za)=>{const dl=Number((ua==null?void 0:ua.create_time)||0),el=Number((za==null?void 0:za.create_time)||0);return dl-el})[0];ke!=null&&ke.id&&await I.pageBatchDeleteApi({platId:parseInt((Q=Rl.value)==null?void 0:Q.plat_id),changeContents:[{tableName:te,tableContents:[{id:ke.id}]}]})}const da=(ae=he==null?void 0:he.find(ta=>(ta==null?void 0:ta.label)==="证书附件"))==null?void 0:ae.prop,Ca=String(Date.now()),Ba={id:Ca},M=Da[0]||{},K=new Date().toISOString().split("T")[0];if(Object.keys(M||{}).forEach(ta=>{if(ta!=="id"){if(ta==="证书附件"){Ba[ta]="";return}if(ta==="校检日期"||ta==="检校日期"){Ba[ta]=ja[ta]||ja.校检日期||ja.检校日期||K;return}if(["校检周期","检校周期","校检结果","检校结果","计量状态","依据文件","证书编号"].includes(ta)){Ba[ta]=ja[ta]??"";return}Ba[ta]=ja[ta]??""}}),da&&ja[da]){const ta=ja[da];if(Array.isArray(ta)&&ta.length>0)Ba.证书附件=JSON.stringify(ta.map(ke=>({url:(ke==null?void 0:ke.url)||"",name:(ke==null?void 0:ke.name)||(ke==null?void 0:ke.fileName)||"",fileName:(ke==null?void 0:ke.fileName)||(ke==null?void 0:ke.name)||""})).filter(ke=>ke.url||ke.name));else if(typeof ta=="string")try{const ke=JSON.parse(ta);Ba.证书附件=ta}catch{Ba.证书附件=JSON.stringify([{url:ta,name:ta,fileName:ta}])}}console.log(te,"tableName","inspectionRecordRow",Ba),await I.pageBatchAddApi({platId:parseInt((j=Rl.value)==null?void 0:j.plat_id),changeContents:[{tableName:te,tableContents:[Ba]}]});const Ae=sa==null?void 0:sa.object_id;if(Ae&&Ca){const ta=da&&ja[da]?ja[da]:null;let ke=[],ua="",za=!1;if(Array.isArray(ta)&&ta.length>0){ke=ta.map(gl=>({name:(gl==null?void 0:gl.name)||(gl==null?void 0:gl.fileName)||"",url:(gl==null?void 0:gl.url)||""})).filter(gl=>gl.url||gl.name);const el=ta[0];ua=(el==null?void 0:el.url)||"";const yl=(el==null?void 0:el.name)||(el==null?void 0:el.fileName)||"";za=String(yl).toLowerCase().endsWith(".pdf")||String(ua).toLowerCase().endsWith(".pdf")}else if(typeof ta=="string")try{const el=JSON.parse(ta);Array.isArray(el)?(ke=el.map(yl=>({name:(yl==null?void 0:yl.name)||(yl==null?void 0:yl.fileName)||"",url:(yl==null?void 0:yl.url)||""})).filter(yl=>yl.url||yl.name),ke.length>0&&(ua=ke[0].url||"",za=String(ke[0].name).toLowerCase().endsWith(".pdf")||String(ua).toLowerCase().endsWith(".pdf"))):(ua=ta,za=String(ta).toLowerCase().endsWith(".pdf"))}catch{ua=ta,za=String(ta).toLowerCase().endsWith(".pdf")}const dl={ts:Date.now(),versionId:String(Date.now())+"_"+String(ia),label:new Date().toLocaleString(),certType:ja.证书类型||"",certNo:ja.证书编号||"",fileType:za?"pdf":"image",sourceUrl:za?ua:"",images:ke};ml(Ae,Ca,dl)}}}catch(he){console.error("向校检记录表插入OCR识别结果失败:",he),rl.ElMessage.error("向校检记录表插入数据失败,请查看控制台")}},on=d=>{const h=Array.isArray(d)?d:Fl.value||[];if(h.length===0){dn();return}if(h.find(D=>(D==null?void 0:D.__decision)==="replace"&&!(D!=null&&D.selectedTargetId))){rl.ElMessage.warning("存在“替换”但未选择目标记录的条目,请处理后再提交");return}h.forEach(D=>{var ae;const Q=D==null?void 0:D.__decision;if(!(!Q||Q==="skip")){if(Q==="add"){ml(u==null?void 0:u.index,(ae=D==null?void 0:D.ocrRow)==null?void 0:ae.id,D==null?void 0:D.versionItem),rr.value=[...rr.value||[],D.ocrRow];return}if(Q==="replace"){const j=D==null?void 0:D.selectedTargetId,he=(_e.value||[]).find(be=>String(be==null?void 0:be.id)===String(j));if(!he)return;qr(D,he)}}}),(gr.value||[]).length>0&&(_e.value=[..._e.value||[]]),(rr.value||[]).length>0&&(_e.value=[..._e.value||[],...rr.value||[]],wa.value=[...wa.value||[],...rr.value||[]],(rr.value||[]).forEach(D=>{var Q,ae;return(ae=(Q=ve.value)==null?void 0:Q.set)==null?void 0:ae.call(Q,D.id,D)})),Br.value=_e.value;const O=gr.value||[],R=rr.value||[];if(O.length>0&&(Ie("change",{buttonName:"编辑",singleContent:O,content:_e.value,relatedContents:u==null?void 0:u.related,index:u==null?void 0:u.index,parentTableId:u==null?void 0:u.parentTableId,columns:De.value,name:u==null?void 0:u.compName}),pn(O)),R.length>0){const D=kr.value;Ie("change",{buttonName:"OCR批量新增",content:_e.value,index:u==null?void 0:u.index,parentTableId:u==null?void 0:u.parentTableId,column:De.value,ocrRows:R,relatedContents:u==null?void 0:u.related,uploadedFiles:(Array.isArray(D==null?void 0:D.result)?D.result:[]).map(Q=>(Array.isArray(Q==null?void 0:Q.图片信息)?Q.图片信息:[]).map(ae=>({url:(ae==null?void 0:ae.url)||"",name:(ae==null?void 0:ae.name)||"",fileName:(ae==null?void 0:ae.name)||""})).filter(ae=>ae.url)),ocrResult:D,matchedCount:(O||[]).length,newCount:(R||[]).length})}rl.ElMessage.success("已提交候选处理结果"),dn()},Dr=rc(),Zr=a.computed(()=>Dr.getConfig()),Nr=a.ref(),Il=a.ref(),Wr=Zs(I.pinia),Br=a.ref(),vn=a.ref(0),io=I.useUnit(I.pinia),{selectIndex:Kn,selectMenu:In,selectTitle:mn}=I.storeToRefs(io),{selectString:Xl}=I.storeToRefs(Wr),xr=I.useLoginState(I.pinia),{loginUserInfo:Rl}=I.storeToRefs(xr),Hl=a.ref(720),Ml=a.ref(!1),cr=a.ref(!1),ar=a.ref([]),Pl=a.ref(),zr=a.ref(!0),Mr=a.ref(!0);a.ref([]);const yn=a.inject("contentRef");a.provide("contentRef",yn),a.provide("getSuggestListForCell",uu),a.provide("getSuggestLoadingForCell",(d,h)=>{const z=`${d==null?void 0:d.id}:${(h==null?void 0:h.prop)||(h==null?void 0:h.property)}`;return m.value.get(z)||!1}),a.watch(()=>{var d;return(d=_e.value)==null?void 0:d.length},d=>{Ee.total=d}),a.watch(()=>F.value,async()=>{var h,z,O,R,D,Q,ae,j,he,be,$e,ze,qe,ia,ja,Aa,na;if(((h=F.value)==null?void 0:h.length)===0||!((z=u==null?void 0:u.itemData)!=null&&z.find(Xa=>(Xa==null?void 0:Xa.key)==="columnPath"))||!((O=u==null?void 0:u.itemData)!=null&&O.find(Xa=>(Xa==null?void 0:Xa.key)==="pageColumn")))return;let d=(he=(j=(ae=(Q=(D=(R=u==null?void 0:u.itemData)==null?void 0:R.find(Xa=>(Xa==null?void 0:Xa.key)==="pageColumn"))==null?void 0:D.contents)==null?void 0:Q.split("["))==null?void 0:ae[1])==null?void 0:j.split("]"))==null?void 0:he[0];((qe=(ze=($e=(be=u==null?void 0:u.itemData)==null?void 0:be.find(Xa=>(Xa==null?void 0:Xa.key)==="pageColumn"))==null?void 0:$e.contents)==null?void 0:ze.split("["))==null?void 0:qe[0])+((ja=(ia=F.value)==null?void 0:ia.find(Xa=>(Xa==null?void 0:Xa.key)===d))==null?void 0:ja.value),(na=(Aa=u==null?void 0:u.itemData)==null?void 0:Aa.find(Xa=>(Xa==null?void 0:Xa.key)==="pageGroup"))==null||na.contents,Ot(compData,u.allMapContents)},{deep:!0});const Qr=d=>{var z,O,R,D,Q;const h=(O=(z=De.value)==null?void 0:z.filter(ae=>ae==null?void 0:ae.mainKey))==null?void 0:O.map(ae=>ae==null?void 0:ae.prop);if(h.length===0){const ae=(R=De.value)==null?void 0:R.map(j=>j==null?void 0:j.prop);return(D=ae==null?void 0:ae.map(j=>d==null?void 0:d[j]))==null?void 0:D.join("|")}return(Q=h==null?void 0:h.map(ae=>d==null?void 0:d[ae]))==null?void 0:Q.join("|")},Yn=d=>{var ae,j,he,be,$e;const h=(j=(ae=De.value)==null?void 0:ae.filter(ze=>ze==null?void 0:ze.required))==null?void 0:j.map(ze=>ze==null?void 0:ze.prop),z=[];if(d==null||d.forEach(ze=>{h==null||h.forEach(qe=>{const ia=ze[qe];(ia==null||ia==="")&&(z.includes(qe)||z.push(qe))})}),z.length>0)return rl.ElMessage.warning(`请填写必填项:${z.join("、")}`);const O=new Map,R=new Map;(he=_e.value)==null||he.forEach(ze=>{const qe=Qr(ze);O.set(qe,ze)}),d==null||d.forEach(ze=>{const qe=Qr(ze);R.set(qe,ze)});const D=d==null?void 0:d.filter(ze=>O.has(Qr(ze))),Q=(be=_e.value)==null?void 0:be.filter(ze=>R.has(Qr(ze)));return(D==null?void 0:D.length)>0&&(i.columns=($e=De.value)==null?void 0:$e.filter(ze=>(ze==null?void 0:ze.label)!=="操作"),i.existRows=Q,i.tableData=D,i.show=!0),d==null?void 0:d.filter(ze=>{const qe=Qr(ze);return!O.has(qe)})},Sn=a.ref(""),Gn=a.ref(null),gn=async()=>{var d,h,z,O,R,D;try{const Q=await I.quoteApi({related:[{menus:ka.value,groups:u==null?void 0:u.compName}],platId:parseInt((d=Rl.value)==null?void 0:d.plat_id)});if(((h=Q==null?void 0:Q.data)==null?void 0:h.code)===200){Gn.value=(z=Q==null?void 0:Q.data)==null?void 0:z.result;const ae=(O=De.value)==null?void 0:O.map(be=>(be==null?void 0:be.prop)||(be==null?void 0:be.label)),j=Dn(ae,(R=Q==null?void 0:Q.data)==null?void 0:R.result),he=j==null?void 0:j.flatMap(be=>be==null?void 0:be.quote);(he==null?void 0:he.length)>0&&(Sn.value=(D=he==null?void 0:he.map(be=>be==null?void 0:be.menus))==null?void 0:D.join("、"))}}catch(Q){throw new Error(Q)}};function Dn(d,h){var z;return(z=h.filter(O=>O.struct&&Array.isArray(O.struct)?O.struct.some(R=>R.words&&Array.isArray(R.words)?R.words.some(D=>d.includes(D)):!1):!1))==null?void 0:z.map(O=>{const R={...O};return R.struct&&Array.isArray(R.struct)&&(R.struct=R.struct.filter(D=>D.words&&Array.isArray(D.words)?D.words.some(Q=>d.includes(Q)):!1)),R})}const Ln=async(d,h)=>{var z,O,R,D,Q,ae,j,he,be,$e;try{Gn.value||await gn();const ze=h==null?void 0:h.map(Ua=>{const te=Object.keys(Ua),Da={};return te.forEach((da,Ca)=>{Da[d[Ca]]=Ua[da]}),Da}),qe=Yn(ze);if(!qe||(qe==null?void 0:qe.length)===0)return;const ia=[];let ja=(_e.value||[]).slice();(qe||[]).forEach(Ua=>{const te={...Ua};try{te.sort=Bn(0,ja)}catch{}ia.push(te),ja.unshift(te)});let Aa=await I.quoteApi({platId:parseInt((z=Rl==null?void 0:Rl.value)==null?void 0:z.plat_id),type:"fatherSyncs",related:[{menus:ka.value,groups:""},{menus:ka.value,groups:u==null?void 0:u.compName}]});Aa=(O=Aa==null?void 0:Aa.data)==null?void 0:O.result;let na=Aa==null?void 0:Aa.map(Ua=>({tableName:"content_"+(Ua==null?void 0:Ua.id),tableContents:ia==null?void 0:ia.map((te,Da)=>({id:Da,...te}))})),Xa=[{tableName:(R=u==null?void 0:u.related)==null?void 0:R.find(Ua=>Ua==null?void 0:Ua.includes("content")),tableContents:ia==null?void 0:ia.map((Ua,te)=>({id:te,...Ua}))}];Xa=[...Xa,...na];const sa=await I.pageBatchAddApi({platId:parseInt((D=Rl.value)==null?void 0:D.plat_id),changeContents:Xa});if(((Q=sa==null?void 0:sa.data)==null?void 0:Q.code)===200){const Ua={buttonName:"新增",columns:De.value,fixContent:ia==null?void 0:ia.map((Da,da)=>({id:da,...Da})),relatedContents:u==null?void 0:u.related};await mt(Ua),((ae=i==null?void 0:i.existRows)==null?void 0:ae.length)>0?rl.ElMessage.success("部分数据导入成功"):rl.ElMessage.success("数据导入成功");let te=[];Xa==null||Xa.forEach(Da=>{var da;(da=Da==null?void 0:Da.tableContents)==null||da.forEach(Ca=>{te.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(Ca),request_result:"{}",is_delete:!1,request_table:Da==null?void 0:Da.tableName,request_type:"export"})})}),await I.pageBatchAddApi({platId:parseInt((j=Rl==null?void 0:Rl.value)==null?void 0:j.plat_id),changeContents:[{tableName:"log",tableContents:te}]})}else{let Ua=[];Xa==null||Xa.forEach(te=>{var Da;(Da=te==null?void 0:te.tableContents)==null||Da.forEach(da=>{Ua.push({id:"1",request_method:"Post",request_url:"/platform/page/add",request_param:JSON.stringify(da),request_result:"{}",is_delete:!1,request_table:te==null?void 0:te.tableName,request_type:"error"})})}),await I.pageBatchAddApi({platId:parseInt((he=Rl==null?void 0:Rl.value)==null?void 0:he.plat_id),changeContents:[{tableName:"log",tableContents:Ua}]}),rl.ElMessage.error("数据导入响应失败")}}catch(ze){throw rl.ElMessage.error("数据导入处理失败"),await I.pageBatchAddApi({platId:parseInt((be=Rl==null?void 0:Rl.value)==null?void 0:be.plat_id),changeContents:[{tableName:"log",tableContents:[{id:"1",request_method:"Post",request_url:"",request_param:JSON.stringify(t1),request_result:JSON.stringify(ze),is_delete:!1,request_table:($e=u==null?void 0:u.related)==null?void 0:$e.find(qe=>qe==null?void 0:qe.includes("content")),request_type:"error"}]}]}),new Error(ze)}},Kr=async d=>{var D,Q,ae,j,he,be,$e;let h=ge.value;h!=null&&h.find(ze=>(d==null?void 0:d.key)===(ze==null?void 0:ze.key))&&(h=h==null?void 0:h.filter(ze=>(d==null?void 0:d.key)!==(ze==null?void 0:ze.key))),h.push({key:d==null?void 0:d.key,value:[(Q=d==null?void 0:d.value)==null?void 0:Q[((D=d==null?void 0:d.value)==null?void 0:D.length)-1]]});let z=$a.value;z=z==null?void 0:z.map(ze=>{var qe,ia;return(ze==null?void 0:ze.type)==="Select"&&(d==null?void 0:d.key)===(ze==null?void 0:ze.prop)&&Array.isArray(ze.value)&&(qe=ze.value)!=null&&qe.every(ja=>typeof ja=="string")&&(ze.selectValue=(ia=h==null?void 0:h.find(ja=>(ja==null?void 0:ja.key)===(ze==null?void 0:ze.prop)))==null?void 0:ia.value),ze});let O=(j=(ae=z==null?void 0:z.find(ze=>(ze==null?void 0:ze.prop)===(d==null?void 0:d.key)))==null?void 0:ae.optionUrl)==null?void 0:j.menuId,R=z==null?void 0:z.find(ze=>(ze==null?void 0:ze.prop)===(d==null?void 0:d.key));if(O){let ze=await pt(R==null?void 0:R.optionUrl,O),qe,ia=W.value,ja=($e=(be=(he=$a.value)==null?void 0:he.find(Aa=>{var na;return(na=R==null?void 0:R.optionUrl)==null?void 0:na.menuId}))==null?void 0:be.selectValue)==null?void 0:$e[0];if(ze==null||ze.forEach(Aa=>{var na,Xa,sa,Ua,te,Da,da,Ca,Ba,M;if(O){let K=(Xa=(na=$a.value)==null?void 0:na.find(ta=>{var ke,ua;return((ke=R==null?void 0:R.optionUrl)==null?void 0:ke.menuId)===((ua=ta==null?void 0:ta.optionUrl)==null?void 0:ua.menuId)}))==null?void 0:Xa.prop,Ae=(Ua=(sa=z==null?void 0:z.find(ta=>(ta==null?void 0:ta.prop)===K))==null?void 0:sa.selectValue)==null?void 0:Ua[0];K!=null&&K.includes("·")&&(K=(te=K==null?void 0:K.split("·"))==null?void 0:te[0],Ae=(Ba=(Ca=(da=d==null?void 0:d.value)==null?void 0:da[((Da=d==null?void 0:d.value)==null?void 0:Da.length)-1])==null?void 0:Ca.split(" "))==null?void 0:Ba[0]),ia!=null&&ia.find(ta=>(ta==null?void 0:ta.value)===ja)?qe=(M=ia==null?void 0:ia.find(ta=>(ta==null?void 0:ta.value)===ja))==null?void 0:M.objectValue:Aa[K]===Ae&&(qe=Aa)}}),qe){let Aa=z;Aa=Aa==null?void 0:Aa.map(na=>{var Xa,sa,Ua,te,Da,da;return O&&(qe!=null&&qe[na==null?void 0:na.prop])&&Le.value==="新增"&&(na==null?void 0:na.prop)!==(R==null?void 0:R.prop)?na.value=(qe==null?void 0:qe[na==null?void 0:na.prop])||(qe==null?void 0:qe[(te=(Ua=(sa=(Xa=na==null?void 0:na.optionUrl)==null?void 0:Xa.groupSelect)==null?void 0:sa[1])==null?void 0:Ua.replaceAll("[",""))==null?void 0:te.replaceAll("]","")]):na.value=(da=(Da=$a.value)==null?void 0:Da.find(Ca=>(Ca==null?void 0:Ca.prop)===(na==null?void 0:na.prop)))==null?void 0:da.value,na}),$a.value=Aa}}ge.value=h},Nn=async(d,h)=>{var z,O,R,D,Q;if((z=d==null?void 0:d.toString())!=null&&z.includes(".txt")||(O=d==null?void 0:d.toString())!=null&&O.includes(".cpt")||(R=d==null?void 0:d.toString())!=null&&R.includes(".cyd")){const ae=await rl.axios.get(d,{responseType:"blob",headers:{"Content-Type":"application/json"}}),j=new Blob([ae.data],{type:"application/octet-stream;charset=UTF-8"});let he=URL.createObjectURL(j);ee.value=[{name:(Q=d==null?void 0:d.split("/"))==null?void 0:Q[((D=d==null?void 0:d.split("/"))==null?void 0:D.length)-1],blobUrl:he}],Wa.value=!0}else Array.isArray(h)&&(h==null?void 0:h.length)>0&&Ie("routeUrl",{isEdit:!1,routerUrl:h})};a.onBeforeUnmount(()=>{Mr.value=!1;let d=vn.value;vn.value=d+1});const bn=a.reactive({prop:"",order:null}),Pr=a.computed(()=>{const d=(_e.value??[]).slice(),h=bn.prop||X.prop,z=bn.order||X.order;if(!h||!z)return d;const O=z==="ascending",R=Q=>{if(h)return Q&&Object.prototype.hasOwnProperty.call(Q,h)?Q[h]:h.includes(".")?h.split(".").reduce((ae,j)=>ae==null?ae:ae[j],Q):Q==null?void 0:Q[h]},D=Q=>{if(Q==null)return{ok:!1,value:NaN};if(typeof Q=="number")return{ok:Number.isFinite(Q),value:Q};const ae=String(Q).trim();if(ae==="")return{ok:!1,value:NaN};const j=ae.replace(/[,\s]/g,"");if(!/^[+-]?(\d+\.?\d*|\.\d+)$/.test(j))return{ok:!1,value:NaN};const he=Number(j);return{ok:Number.isFinite(he),value:he}};return d.sort((Q,ae)=>{const j=R(Q),he=R(ae);if(j==null&&he==null)return 0;if(j==null)return O?-1:1;if(he==null)return O?1:-1;const be=D(j),$e=D(he);if(be.ok&&$e.ok)return O?be.value-$e.value:$e.value-be.value;const ze=te=>{if(te==null)return{ok:!1,value:NaN};const Da=String(te).trim();if(Da==="")return{ok:!1,value:NaN};const da=Da.match(/^(-)?(\d+):(\d{1,2}):(\d{1,2})$/);if(!da)return{ok:!1,value:NaN};const Ca=da[1]?-1:1,Ba=Number(da[2]),M=Number(da[3]),K=Number(da[4]);return[Ba,M,K].some(Ae=>Number.isNaN(Ae))?{ok:!1,value:NaN}:M>=60||K>=60?{ok:!1,value:NaN}:{ok:!0,value:Ca*(Ba*3600+M*60+K)}},qe=ze(j),ia=ze(he);if(qe.ok&&ia.ok)return O?qe.value-ia.value:ia.value-qe.value;const ja=new Date(j).getTime(),Aa=new Date(he).getTime(),na=!Number.isNaN(ja),Xa=!Number.isNaN(Aa);if(na&&Xa)return O?ja-Aa:Aa-ja;const sa=String(j),Ua=String(he);return O?sa.localeCompare(Ua):Ua.localeCompare(sa)})}),$n=a.computed(()=>{var z;const d=(Ee.currentPage-1)*Ee.pageSize,h=d+Ee.pageSize;return Ie("getSliceContLength",Ee),(z=Pr.value)==null?void 0:z.slice(d,h)}),fn=d=>{Ee.currentPage=d,Ie("getSliceContLength",Ee)},No=d=>{var O;Ee.pageSize=d;const h=((O=_e.value)==null?void 0:O.length)??0,z=d>0?Math.ceil(h/d):1;Ee.currentPage>z&&(Ee.currentPage=z||1,rl.ElMessage.warning("当前页超出范围,已自动跳转到最后一页")),Ie("getSliceContLength",Ee)},Ai=({prop:d,order:h})=>{bn.prop=d,bn.order=h,Ee.currentPage=1};function zi(d){const h=[];function z(O,R=""){O.forEach(D=>{D.children&&D.children.length>0?z(D.children,D.prop):h.push(D.prop)})}return z(d),h}const kn=(d,h)=>{var ae,j,he,be;let z=(j=(ae=De.value)==null?void 0:ae.map($e=>$e==null?void 0:$e.prop))==null?void 0:j.filter($e=>$e!=="operate");((he=De.value)==null?void 0:he.some($e=>{var ze;return((ze=$e==null?void 0:$e.children)==null?void 0:ze.length)>0}))&&(z=zi((be=De.value)==null?void 0:be.filter($e=>($e==null?void 0:$e.prop)!=="operate")));let R;if(R=(d==null?void 0:d.length)===(z==null?void 0:z.length)?d:d.slice(0,z==null?void 0:z.length),!(R==null?void 0:R.every($e=>z==null?void 0:z.find(ze=>$e===ze))))return rl.ElMessage.error("导入的数据表头不匹配");Ln(R,h)},Mi=(d,h)=>{var R;const z=d==null?void 0:d.filter(D=>D!=="序号"),O=h==null?void 0:h.map(D=>{const Q=Object.entries(D);return Q.shift(),Object.fromEntries(Q)});Ge.setRefreshCurStructure(!1),((R=De.value)==null?void 0:R.length)===0||kn(z,O)},Oi=(d,h,z,O)=>{const R=[],D=[],Q=he=>Object.keys(he).length;for(const he in d)if(d[he]!==void 0){const be=d[he],$e=[];for(const[ze,qe]of Object.entries(be))$e.push(qe),D.length<Q(be)&&D.push(ze);R.push($e)}R.unshift(D);const ae=ca.utils.aoa_to_sheet(R),j=ca.utils.book_new();ca.utils.book_append_sheet(j,ae,O),ca.writeFileSync(j,`${h}.xlsx`),ar.value=[]},Ho=async(d,h,z,O=!1,R)=>{var D,Q,ae,j,he,be,$e,ze;try{Ge.setRefreshCurStructure(!1);const qe=await yr.getInsofDataApi({id:u==null?void 0:u.index});if(((D=qe==null?void 0:qe.data)==null?void 0:D.code)===200){let ia=(he=(j=(ae=(Q=qe==null?void 0:qe.data)==null?void 0:Q.result)==null?void 0:ae[0])==null?void 0:j.value)==null?void 0:he.pageData;O?ia={...ia,compData:($e=ia==null?void 0:ia.compData)==null?void 0:$e.map(Aa=>{var na;return(Aa==null?void 0:Aa.key)==="header"?{...Aa,contents:(na=Aa==null?void 0:Aa.contents)==null?void 0:na.map(Xa=>({...Xa,[d]:z}))}:Aa})}:ia={...ia,compData:(be=ia==null?void 0:ia.compData)==null?void 0:be.map(Aa=>{var na,Xa;return(Aa==null?void 0:Aa.key)==="header"?{...Aa,contents:(na=Aa==null?void 0:Aa.contents)==null?void 0:na.map(sa=>{if(Array.isArray(sa))sa=sa==null?void 0:sa.map(Ua=>(Ua==null?void 0:Ua.prop)===(h==null?void 0:h.prop)?{...Ua,[d]:z}:Ua);else if((sa==null?void 0:sa.prop)===(h==null?void 0:h.prop))return{...sa,[d]:z};return sa})}:(Aa==null?void 0:Aa.key)==="tableToForm"&&R?{...Aa,contents:(Xa=Aa==null?void 0:Aa.contents)==null?void 0:Xa.map(sa=>(sa==null?void 0:sa.prop)===(h==null?void 0:h.prop)?{...sa,[R]:z}:sa)}:Aa})};const ja=await yr.updateInsofDataApi({id:u==null?void 0:u.index,value:{pageData:ia}});((ze=ja==null?void 0:ja.data)==null?void 0:ze.code)===200?(rl.ElMessage.success("编辑成功"),Ge.setRefreshCurStructure(!0)):rl.ElMessage.error("编辑响应失败")}}catch(qe){rl.ElMessage.error(qe)}},Uo=async(d,h)=>{await Ho("label",h,d)},qo=async(d,h)=>{await Ho("columnType",h,d,!1,"type")},Or=async({newRow:d,targetIndex:h})=>{var R;if(!Oe(u.config,{type:oa.TABLE}))return;const O=(Ee.currentPage-1)*Ee.pageSize+(h??0);d._isTemp=!0;try{(d.sort===void 0||d.sort===null||String(d.sort).trim()==="")&&(d.sort=Bn(O,_e.value||[]))}catch{}_e.value.splice(O,0,d),await a.nextTick(),y.value.has(d.id)||y.value.set(d.id,I.cloneDeep(d)),_e.value=(R=_e.value)==null?void 0:R.map(D=>({...D,tableEditType:(D==null?void 0:D.id)===d.id?"edit":(D==null?void 0:D.tableEditType)??"text"})),c.value.add(d.id),Ml.value=!0},Ii=(d,h,z,O=[])=>(!Array.isArray(h)||h.length===0||h.forEach(R=>{const D=R==null?void 0:R.prop;if(!D)return;let Q=d==null?void 0:d[D];if(Q==null||String(Q).trim()==="")return;Q=String(Q);const ae=new Set([...(Array.isArray(z)?z:[]).filter(be=>(be==null?void 0:be.id)!==(d==null?void 0:d.id)).map(be=>be==null?void 0:be[D]).filter(be=>be!=null).map(be=>String(be)),...(Array.isArray(O)?O:[]).map(be=>be==null?void 0:be[D]).filter(be=>be!=null).map(be=>String(be))]);if(!ae.has(Q))return;let j=1,he="";for(;he=`${Q}(${j})`,!!ae.has(he);)j++;d[D]=he}),d),Bo=async()=>{var R,D,Q,ae,j,he,be,$e;const d=Array.from(c.value||[]);if(d.length===0)return;const h=(D=ca.getColumnChild((R=I.cloneDeep(De.value))==null?void 0:R.filter(ze=>(ze==null?void 0:ze.label)!=="操作")))==null?void 0:D.filter(ze=>(ze==null?void 0:ze.required)===!0);if((h==null?void 0:h.length)>0)for(let ze=0;ze<d.length;ze++){const qe=d[ze],ia=(Q=_e.value)==null?void 0:Q.find(ja=>(ja==null?void 0:ja.id)===qe);if(ia)for(let ja=0;ja<h.length;ja++){const Aa=h[ja],na=Aa==null?void 0:Aa.prop,Xa=(Aa==null?void 0:Aa.label)??na,sa=ia==null?void 0:ia[na];if(sa===""||sa===null||sa===void 0||Array.isArray(sa)&&sa.length===0){rl.ElMessage.error(`${Xa}不能为空`);return}}}const z=[],O=[];if(d.forEach(ze=>{var Xa;const qe=(Xa=_e.value)==null?void 0:Xa.find(sa=>(sa==null?void 0:sa.id)===ze);if(!qe)return;if(qe!=null&&qe._isTemp){const Ua=(ca.getAllLeafNodes(De.value)||[]).filter(M=>(M==null?void 0:M.mainKey)===!0||(M==null?void 0:M.isMainKey)===!0),te=_e.value.findIndex(M=>(M==null?void 0:M.id)===ze),Da=te>=0?te+1:_e.value.length+1;Ii(qe,Ua,_e.value,z);const da={id:Da.toString()};(qe==null?void 0:qe.sort)!==void 0&&(qe==null?void 0:qe.sort)!==null&&String(qe.sort).trim()!==""?da.sort=String(qe.sort):da.sort=Bn(te>=0?te:_e.value.length-1,_e.value||[]),(ca.getAllLeafNodes(De.value)||[]).filter(M=>(M==null?void 0:M.type)!=="operate"&&(M==null?void 0:M.label)!=="操作"&&(M==null?void 0:M.prop)!=="operate").forEach(M=>{const K=M==null?void 0:M.prop;if(K){const Ae=qe[K];Ae!==void 0?da[K]=Ae??"":da[K]=""}}),z.push(da);return}const ja=(ca.getAllLeafNodes(De.value)||[]).filter(sa=>(sa==null?void 0:sa.type)!=="operate"&&(sa==null?void 0:sa.label)!=="操作"&&(sa==null?void 0:sa.prop)!=="operate"),Aa=new Set(ja.map(sa=>sa==null?void 0:sa.prop).filter(Boolean)),na={};for(const sa of Aa)Object.prototype.hasOwnProperty.call(qe,sa)&&(na[sa]=qe[sa]);O.push({id:qe.id,value:{tableData:na}})}),Ge.setTableLoading(u==null?void 0:u.index),O.length>0){const ze=O.map(ia=>{const ja={id:ia.id,...ia.value.tableData};return delete ja._isOCRRow,delete ja._ocrTableId,delete ja._isTemp,delete ja.tableEditType,delete ja.index,ja}),qe=[{tableName:(ae=u==null?void 0:u.related)==null?void 0:ae.find(ia=>ia==null?void 0:ia.includes("content")),tableContents:ze}];try{await I.pageBatchUpdateApi({platId:parseInt((j=Rl.value)==null?void 0:j.plat_id),changeContents:qe})}catch(ia){rl.ElMessage.error(((be=(he=ia==null?void 0:ia.response)==null?void 0:he.data)==null?void 0:be.message)||(ia==null?void 0:ia.message)||"保存失败"),Ge.setTableLoading(!1);return}}if(z.length>0){const ze={fixContent:z,buttonName:"新增",relatedContents:u==null?void 0:u.related,name:u==null?void 0:u.compName,columns:De.value};Ie("change",ze)}rl.ElMessage.success("保存成功"),c.value.clear(),y.value.clear(),_e.value=($e=_e.value)==null?void 0:$e.map(ze=>({...ze,tableEditType:"text"})),Ml.value=!1,Ge.setRefreshCurStructure(!0)},Li=()=>{var h;const d=Array.from(c.value||[]);if(d.length===0){Ml.value=!1;return}d.forEach(z=>{var D,Q;const O=y.value.get(z),R=(D=_e.value)==null?void 0:D.find(ae=>(ae==null?void 0:ae.id)===z);if(R!=null&&R._isTemp){_e.value=_e.value.filter(ae=>(ae==null?void 0:ae.id)!==R.id);return}if(O){const ae=(Q=_e.value)==null?void 0:Q.findIndex(j=>(j==null?void 0:j.id)===z);ae!==-1&&(_e.value[ae]={..._e.value[ae],...O})}}),c.value.clear(),y.value.clear(),_e.value=(h=_e.value)==null?void 0:h.map(z=>({...z,tableEditType:"text"})),Ml.value=!1},To=a.ref(!1),Wo=async d=>{var R,D,Q,ae;if(!Ml.value||d!=null&&d.isComposing||(d==null?void 0:d.key)!=="Enter")return;const h=d==null?void 0:d.target;if(((D=(R=h==null?void 0:h.tagName)==null?void 0:R.toLowerCase)==null?void 0:D.call(R))==="textarea")return;const O=document.getElementById("excel-table");O&&!O.contains(h)||((Q=h==null?void 0:h.blur)==null||Q.call(h),(ae=d.preventDefault)==null||ae.call(d),await a.nextTick(),await Ko())},Ko=async()=>{if(P.value){Ml.value=!1;return}if(!To.value){To.value=!0;try{Array.from(c.value||[]).length>0?await Bo():Ml.value=!1}finally{Promise.resolve().then(()=>{To.value=!1})}}},$i=d=>{ar.value=d},Ri=(d,h)=>{Pl.value===h?zr.value=!1:zr.value=!0,Pl.value=h==null?void 0:h.changeProp},Yo=d=>{if(!d)return;const{item:h,value:z}=d,O=$a.value.find(R=>R.prop==h.prop);O&&O.contents.push({label:z,value:z})},xn=a.computed(()=>{var z,O,R;const d=(z=De.value)==null?void 0:z.some(D=>D==null?void 0:D.filterable);return document.documentElement.style.setProperty("--ssTable-header-filter-display",d?"inline-block":"none"),(R=(O=De.value)==null?void 0:O.filter(D=>(D==null?void 0:D.label)!=="操作"))==null?void 0:R.map(D=>({...D,filterable:!!(D!=null&&D.filterable),showSummary:!!(D!=null&&D.showSummary),operable:!!(D!=null&&D.operable),fixed:D==null?void 0:D.fixed}))}),_n=async(d,h,z)=>{const O=I.cloneDeep(De.value);await a.nextTick();const R=O==null?void 0:O.map(Q=>(z==null?void 0:z.label)===(Q==null?void 0:Q.label)?{...Q,[h]:d}:Q),D=Rn(R);await ss(u.index,D),De.value=R,ne.value=D},Rn=d=>{var R;const h=d||[];return((R=ca.getAllLeafNodes(h)||[])==null?void 0:R.filter(D=>(D==null?void 0:D.prop)&&(D==null?void 0:D.type)!=="operate"&&(D==null?void 0:D.label)!=="操作"&&(D==null?void 0:D.prop)!=="operate")).map(D=>{const{prop:Q}=D;return Mf(Q,D)})},Vi=async d=>{let h=await If(u.index);h||(h=Rn(d)),ne.value=h},Go=async(d,h)=>{const z=I.cloneDeep(De.value),O=Q=>Array.isArray(Q)?Q.map(ae=>{const j=Array.isArray(ae==null?void 0:ae.children)&&ae.children.length>0,he={...ae};return(he==null?void 0:he.prop)==="operate"||(he==null?void 0:he.label)==="操作"||(he==null?void 0:he.type)==="operate"?(he.sortable=!1,he.filterable=!1,he.operable=!1):he.sortable=j?!1:!!d,j&&(he.children=O(he.children)),he}):Q,R=O(z),D=Rn(R);await ss(u.index,D),De.value=R,ne.value=D,await a.nextTick(),vn.value=vn.value+1},Jo=()=>{va.value=!1},Xo=d=>{Ie("clickTrigger",d)},Vn=async d=>{var D,Q,ae,j,he,be,$e,ze,qe,ia,ja,Aa,na,Xa,sa;const h=d==null?void 0:d.row,z=d==null?void 0:d.rowData,O=d==null?void 0:d.suffix;if((D=h==null?void 0:h.toString())!=null&&D.includes(".urdf")||d!=null&&d.isUrdf||O!=null&&O.includes(".urdf")){if(h.includes(",")){rl.ElMessage.error("当前版本仅允许单个urdf预览!");return}if(S(h)){const te={files:[Ne(h)],data:{}};ue(te);return}Ya.value=[{url:h,extension:me(h)}],Ta.value=!0,oe.value={data:I.cloneDeep(z)},Ke.value=!0;return}let R=[];if((Q=h==null?void 0:h.toString())!=null&&Q.includes(".stl")||(ae=h==null?void 0:h.toString())!=null&&ae.includes(".STL")||(j=h==null?void 0:h.toString())!=null&&j.includes(".obj")||(he=h==null?void 0:h.toString())!=null&&he.includes(".mtl")){const Ua=(be=h==null?void 0:h.toString())==null?void 0:be.split(","),te=pa(Ua),Da=te==null?void 0:te[0];if(S(Da==null?void 0:Da.extension)){ue({files:te,data:{}});return}Ya.value=te,Ta.value=!1,Ke.value=!0;return}if(($e=h==null?void 0:h.toString())!=null&&$e.includes(".stl")||(ze=h==null?void 0:h.toString())!=null&&ze.includes(".STL")||(qe=h==null?void 0:h.toString())!=null&&qe.includes(".obj")||(ia=h==null?void 0:h.toString())!=null&&ia.includes(".mtl")||O!=null&&O.includes(".stl")||O!=null&&O.includes(".STL")||O!=null&&O.includes(".obj")||O!=null&&O.includes(".mtl")){let Ua,te=[],Da={};if(Array.isArray(h)?Ua=h:Ua=h==null?void 0:h.split(","),Ua==null||Ua.forEach(da=>{da.includes(".mtl")?te.push(da):Da.blob=Da.blob?Da.blob+","+da:da}),(te==null?void 0:te.length)>0&&(Da.mtlBlobs=te),O&&(Da.suffix=O),(Aa=(ja=Object.values(Da))==null?void 0:ja[0])!=null&&Aa.includes("http:"))R.push(Da);else{const da=new Blob([Da.blob],{type:"application/octet-stream;charset=UTF-8"});let Ca=URL.createObjectURL(da),Ba="";(na=h==null?void 0:h.split("/"))==null||na.forEach((M,K)=>{var Ae;K===((Ae=h==null?void 0:h.split("/"))==null?void 0:Ae.length)-1&&(Ba=M)}),(Xa=Da.blob)!=null&&Xa.includes(".stl")&&(Ba=(Ba==null?void 0:Ba.replaceAll(">",""))+".urdf"),ee.value=[{name:Ba,blobUrl:Ca}],Wa.value=!0}}else{const Ua=await rl.axios.get(h,{responseType:"blob",headers:{"Content-Type":"application/json"}}),te=new Blob([Ua.data],{type:"application/octet-stream;charset=UTF-8"});let Da=URL.createObjectURL(te),da="";if((sa=h==null?void 0:h.split("/"))==null||sa.forEach((Ca,Ba)=>{var M;Ba===((M=h==null?void 0:h.split("/"))==null?void 0:M.length)-1&&(da=Ca)}),S(da)){const Ca=le(da),Ba=Ne(h);ue({files:[Ba],data:{trackFileType:Ca}});return}ee.value=[{name:da,blobUrl:Da}],Wa.value=!0}(R==null?void 0:R.length)>0&&o.setBlobUrls(R)},Jn=d=>{var O,R,D,Q;if(d!=null&&d.downloadUrl)return d==null?void 0:d.name;const h=(Q=(O=d==null?void 0:d.url)==null?void 0:O.split("."))==null?void 0:Q[((D=(R=d==null?void 0:d.url)==null?void 0:R.split("."))==null?void 0:D.length)-1];return(d==null?void 0:d.name)+"."+h},Zo=d=>{if(!d)return"未知文件";try{const O=Jn(d);if(typeof O=="string"&&O.includes("."))return O}catch{}const h=(d==null?void 0:d.fileName)||(d==null?void 0:d.name)||"未知文件",z=(d==null?void 0:d.suffix)||"";return h.includes(".")?h:`${h}${z}`},Qo=d=>{if(d==null||typeof d=="number"||typeof d!="string")return d;const h=d.match(/^(\d+)\_(\d+)$/);if(!h)return d;const z=Number(h[1]),O=Number(h[2]);return!Number.isFinite(z)||!Number.isFinite(O)?d:String(z*1e3+O)},Xn=d=>{if(d==null)return null;const h=String(d).trim();if(!h)return null;const z=Number(h);return Number.isFinite(z)?z:null},Pi=d=>{if(d==null)return null;const h=String(d).trim();if(!h)return null;if(/^\d+$/.test(h)){const R=Number(h);return Number.isFinite(R)?h.length<=10?R*1e3:R:null}const z=h.includes("T")?h:h.replace(" ","T"),O=Date.parse(z);return Number.isFinite(O)?O:null},ei=(d,h=[])=>{const z=Array.isArray(d)?d.slice():[];if(z.length<=1)return z;const O=new Map((h||[]).map((Q,ae)=>[String(Q),ae])),R=z.some(Q=>Xn(Q==null?void 0:Q.sort)!==null),D=z.map((Q,ae)=>({r:Q,idx:ae,id:String((Q==null?void 0:Q.id)??""),sortVal:Xn(Q==null?void 0:Q.sort),createTimeMs:Pi(Q==null?void 0:Q.create_time),prevIdx:O.has(String(Q==null?void 0:Q.id))?O.get(String(Q==null?void 0:Q.id)):Number.POSITIVE_INFINITY}));return D.sort((Q,ae)=>{if(R){const be=Q.sortVal,$e=ae.sortVal;if(be===null&&$e!==null)return 1;if(be!==null&&$e===null)return-1;if(be!==null&&$e!==null&&be!==$e)return be-$e}const j=Q.createTimeMs,he=ae.createTimeMs;return j!==null&&he!==null&&j!==he?he-j:j!==null&&he===null?-1:j===null&&he!==null?1:Q.prevIdx!==ae.prevIdx?Q.prevIdx-ae.prevIdx:Q.idx-ae.idx}),D.map(Q=>Q.r)},Bn=(d,h=[])=>{const z=h==null?void 0:h[d-1],O=h==null?void 0:h[d],R=Xn(z==null?void 0:z.sort),D=Xn(O==null?void 0:O.sort);let Q=null;R!==null&&D!==null&&D>R?Q=(R+D)/2:R!==null?Q=R+1:D!==null?Q=Math.max(D-1,0):Q=(d??0)+1;const ae=Number(Q.toFixed(6));return String(Number.isFinite(ae)?ae:Q)},Fi=async d=>{let h=null,z=null;if(d!=null&&d.id){const R=I.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});try{const D=await I.platformDownloadFile(d);h=URL.createObjectURL(D.data),z=Zo(d)}finally{R.close()}}else if(d!=null&&d.downloadUrl){const R=await so(),D=I.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),Q=await rl.axios.post(d==null?void 0:d.url,null,{responseType:"blob",headers:{Authorization:R,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}).finally(()=>{D.close()}),ae=new Blob([Q.data],{type:"application/octet-stream;charset=UTF-8"});h=URL.createObjectURL(ae),z=d==null?void 0:d.name}else{const R=await I.platformDownloadFile({url:d==null?void 0:d.url});!d.url.toUpperCase().includes(".OBJ")&&!d.url.toUpperCase().includes(".STL")&&!d.url.toUpperCase().includes(".MTL")&&!d.url.toUpperCase().includes(".URDF")?(h=URL.createObjectURL(R.data),z=Jn(d)):h=d==null?void 0:d.url}if(S(h)){const R={row:`${h}`,suffix:me(z)};Vn(R);return}const O={name:z,blobUrl:h};ee.value=[O],Wa.value=!0},to=async d=>{let h=null,z=null;if(d!=null&&d.id){const D=await I.platformDownloadFile(d);h=URL.createObjectURL(D.data),z=Zo(d)}else if(d!=null&&d.downloadUrl){const D=await so(),Q=await rl.axios.post(d==null?void 0:d.url,null,{responseType:"blob",headers:{Authorization:D,baseURL:"http://139.196.154.85:20025","Content-Type":"application/json"}}),ae=new Blob([Q.data],{type:"application/octet-stream;charset=UTF-8"});h=URL.createObjectURL(ae),z=d==null?void 0:d.name}else{const D=await I.platformDownloadFile({url:d==null?void 0:d.url});h=URL.createObjectURL(D.data),z=Jn(d)}const O={name:z,blobUrl:h},R=document.createElement("a");R.href=O.blobUrl,R.download=O.name,R.style.display="none",document.body.appendChild(R),R.click(),setTimeout(()=>{document.body.removeChild(R)},100)},ji=(d,h)=>{var O;if(Object.values(h).length===0)return;let z=d;return Object.values(h).find(R=>{var D,Q,ae;return((D=R==null?void 0:R.toString())==null?void 0:D.includes(".txt"))||((Q=R==null?void 0:R.toString())==null?void 0:Q.includes(".cpt"))||((ae=R==null?void 0:R.toString())==null?void 0:ae.includes(".obj"))})?z=[...d,Ce.value]:(O=u==null?void 0:u.config)!=null&&O.allowMove&&(z=[...d,{label:"迁移"}]),z},Ao=()=>{V.value=!0},Hi=a.ref([]),Ui=async(d,h,z=!1)=>{var Q,ae,j,he;if(!d)return;if(z){_e.value=[...ve.value.values()].filter(be=>Object.values(be).some($e=>typeof $e=="string"?$e==null?void 0:$e.toLowerCase().includes(h==null?void 0:h.toLowerCase()):!1));return}let O={};for(let be in d)(d==null?void 0:d[be])!==""&&(O[be]=d==null?void 0:d[be]);if(JSON.stringify(O)==="{}"){_e.value=Array.from(((Q=ve.value)==null?void 0:Q.values())??[]);return}let R=(ae=u==null?void 0:u.related)==null?void 0:ae.find(be=>be==null?void 0:be.includes("content_")),D=await I.getFillFind({platId:parseInt((j=Rl==null?void 0:Rl.value)==null?void 0:j.plat_id),tableName:R,params:O});D=(he=D==null?void 0:D.data)==null?void 0:he.result,_e.value=D,Ge.setTableLoading(!1)},ai=async d=>{var z,O;if(!Oe(u.config,{type:oa.TABLE})||!d)return;((z=Array.from(c.value))==null?void 0:z.length)>0&&await Bo();const h=d==null?void 0:d.id;h!=null&&(c.value.clear(),y.value.clear(),y.value.has(h)||y.value.set(h,I.cloneDeep(d)),_e.value=(O=_e.value)==null?void 0:O.map(R=>({...R,tableEditType:(R==null?void 0:R.id)===h?"edit":"text"})),c.value.add(h),Ml.value=!0)},Pn=async(d,h,z,O)=>{O!=null&&O.isExistChild&&Ie("clickMainKey",d,z,De.value)},wn=()=>{Wa.value=!1},li=d=>{Ie("rowClick",d)};a.watch(()=>u.changedContent,()=>{var z,O;if(!u.changedContent)return;let d=(z=_e.value)==null?void 0:z.map(R=>{var D;return R.id===((D=u.changedContent)==null?void 0:D.id)&&(R={...u.changedContent,id:u.changedContent.newId?u.changedContent.newId:u.changedContent.id},delete R.newId),R});const h=(O=u.itemData)==null?void 0:O.map(R=>((R==null?void 0:R.key)==="tableContents"&&(R.contents=d),R));_e.value=d,Ie("contentChange",{contents:h,index:u.index}),Ie("change",{content:d,index:u==null?void 0:u.index,buttonName:"",id:u==null?void 0:u.index})},{deep:!0,immediate:!0});const zo=()=>{},qi=async()=>{const d=ka.value,h=sessionStorage.getItem("systemKey"),z=await ca.getItemData(d,h,""),O=(z==null?void 0:z.find(ae=>(ae==null?void 0:ae.name)==="方法明细"))||(z==null?void 0:z[0]),R=(O==null?void 0:O.compData)||[],D=R==null?void 0:R.find(ae=>{const j=ae==null?void 0:ae.key;return j==="formContent"||j==="tableContents"});return D==null?void 0:D.contents},so=async()=>{const h=rl.Local.get("access-token");return h?`Bearer ${h}`:""},Wi=async(d,{token:h,inputData:z}={})=>await rl.axios.post(d,z,{headers:{Authorization:h}}).catch(R=>(la.setImportLoading(!1),Promise.reject(R))),Ki=d=>{var O;let h={};const z=[];return h.form={},(O=I.cloneDeep(d))==null||O.forEach((R,D)=>{var Q,ae,j,he,be,$e,ze,qe,ia,ja,Aa,na,Xa,sa;if((R==null?void 0:R.comp)==="Table"){(ae=(Q=R==null?void 0:R.compData)==null?void 0:Q.find(da=>(da==null?void 0:da.key)==="header"))==null||ae.contents;let Ua=(be=(he=(j=R==null?void 0:R.compData)==null?void 0:j.find(da=>(da==null?void 0:da.key)==="tableContents"))==null?void 0:he.contents)==null?void 0:be.map(da=>da.slice(1));(ja=(ia=(qe=(ze=($e=R==null?void 0:R.compData)==null?void 0:$e.find(da=>(da==null?void 0:da.key)==="header"))==null?void 0:ze.contents)==null?void 0:qe[0])==null?void 0:ia[0])==null||ja.label;let te=(na=(Aa=R==null?void 0:R.compData)==null?void 0:Aa.find(da=>(da==null?void 0:da.key)==="header"))==null?void 0:na.contents,Da=[];Ua==null||Ua.forEach(da=>{let Ca=[];da==null||da.forEach((Ba,M)=>{var Ae;let K={};((Ae=te[M])==null?void 0:Ae.label)!=="操作"&&(K[te[M].label]=Ba,Ca.push(K))}),Da.push(Ca)}),h[R.name]=Da}else{const Ua=(sa=(Xa=R.compData)==null?void 0:Xa.find(te=>(te==null?void 0:te.key)==="formContent"))==null?void 0:sa.contents;Ua==null||Ua.forEach(te=>{var Da,da;if(te.prop!==""){let Ca=te==null?void 0:te.value;Array.isArray(Ca)?Ca=((Da=Ca==null?void 0:Ca[0])==null?void 0:Da.oldUrl)||"http://222.92.178.198:62001/"+((da=Ca==null?void 0:Ca[0])==null?void 0:da.url):Ca=Ca.toString(),te={key:(te==null?void 0:te.prop)??(te==null?void 0:te.label),value:Ca},z.push(te)}})}}),h.form=ca.getFormContents(z),h},Yi=d=>{const h=[],z=O=>{O&&typeof O=="object"&&!Array.isArray(O)?Object.values(O).forEach(z):h.push(O)};return z(d),h},Gi=async(d,h,z)=>{var te,Da,da,Ca,Ba,M,K,Ae,ta,ke,ua,za,dl,el,yl,gl,Vl;la.setImportLoading(!0),Ge.setFreshContent(!1);let O=await qi().catch(Za=>(la.setImportLoading(!1),Promise.reject(Za)));O=O==null?void 0:O.filter(Za=>{var kl;return((kl=Za==null?void 0:Za.find(Ka=>Ka==null?void 0:Ka.id))==null?void 0:kl.id)===(h==null?void 0:h.id)});let R=ca.getEqualChild([(te=De.value)==null?void 0:te.filter(Za=>(Za==null?void 0:Za.label)!=="操作")]);const D=(da=(Da=ca.tableToForm(O,R))==null?void 0:Da[0])==null?void 0:da.find(Za=>{const kl=Za==null?void 0:Za.key;return kl==="Interface"||kl==="方法体"}),Q=D==null?void 0:D.value;if(!Q){console.log("未搜索到isMain, 缺少算法执行接口"),la.setImportLoading(!1);return}const ae=De.value?ca.getEqualChild([De.value]):[],j=ae.find(Za=>{const kl=Za==null?void 0:Za.prop;return kl==="Input1"||kl==="输入数据.输入1"||kl==="样本输入数据"}),he=j==null?void 0:j.prop;let be=h==null?void 0:h[he];const $e=await so().catch(Za=>(la.setImportLoading(!1),Promise.reject(Za)));let ze=!0,qe="";(Ca=De.value)==null||Ca.forEach(Za=>{(Za==null?void 0:Za.prop)===he&&(ze=!!(Za!=null&&Za.childPath),qe=Za==null?void 0:Za.childPath)});let ia="";if(ze){let Za=(M=(Ba=De.value)==null?void 0:Ba.find(vl=>(vl==null?void 0:vl.isMainKey)===!0))==null?void 0:M.prop;ia=h==null?void 0:h[Za];let kl=qe==null?void 0:qe.split(k),Ka=[];kl==null||kl.forEach((vl,Sl)=>{(kl==null?void 0:kl.length)-1===Sl&&Ka.push(ia),Ka.push(vl)}),Ka=Ka==null?void 0:Ka[0];let hl=await ca.getItemData(Ka,sessionStorage.getItem("systemKey"),""),ll=hl==null?void 0:hl.filter(vl=>(vl==null?void 0:vl.name)===he);ll=ll==null?void 0:ll.map(vl=>{var Sl;return vl.compData=(Sl=vl==null?void 0:vl.compData)==null?void 0:Sl.map(Tl=>{var hr;return(Tl==null?void 0:Tl.key)==="tableContents"&&(Tl.contents=(hr=Tl==null?void 0:Tl.contents)==null?void 0:hr.filter(Ll=>(Ll==null?void 0:Ll[1])===(h==null?void 0:h[he]))),Tl}),vl}),(!ll||(ll==null?void 0:ll.length)===0)&&(ll=hl,ll=ll==null?void 0:ll.map(vl=>{var Sl;return vl.compData=(Sl=vl==null?void 0:vl.compData)==null?void 0:Sl.map(Tl=>{var hr;return(Tl==null?void 0:Tl.key)==="tableContents"&&(Tl.contents=(hr=Tl==null?void 0:Tl.contents)==null?void 0:hr.filter(Ll=>{var wl,zl;return(Ll==null?void 0:Ll[1])===(h==null?void 0:h[(zl=(wl=De==null?void 0:De.value)==null?void 0:wl[0])==null?void 0:zl.prop])})),Tl}),vl})),be=Ki(ll)}const ja=await Wi(Q,{token:$e,inputData:be}).catch(Za=>(la.setImportLoading(!1),Promise.reject(Za))),Aa=(K=ja==null?void 0:ja.data)==null?void 0:K.data,na=ae.find(Za=>(Za==null?void 0:Za.prop)==="Output1"),Xa=na==null?void 0:na.prop;let sa=[],Ua=[];if(Aa&&((Ae=Object.values(Aa))==null?void 0:Ae.length)>0){let Za=[];const kl=new FormData,Ka=(ta=Yi(Aa))==null?void 0:ta.map(async ll=>{var vl,Sl;if(!Array.isArray(ll)&&(ll!=null&&ll.includes("http"))){let Tl=await rl.axios.get(ll,{responseType:"blob"}),hr=(Sl=ll==null?void 0:ll.split("/"))==null?void 0:Sl[((vl=ll==null?void 0:ll.split("/"))==null?void 0:vl.length)-1];kl.append("files",Tl.data,hr)}else Za.push(ll)});if(await Promise.all(Ka),!ca.isFormDataEmpty(kl)){let ll=await I.uploadAmountApi(kl),vl=(ua=(ke=ll==null?void 0:ll.data)==null?void 0:ke.result)==null?void 0:ua.map(Sl=>{var Tl,hr,Ll,wl,zl,Ul;return{name:(Ul=(zl=(wl=(Tl=Sl==null?void 0:Sl.url)==null?void 0:Tl.split("/"))==null?void 0:wl[((Ll=(hr=Sl==null?void 0:Sl.url)==null?void 0:hr.split("/"))==null?void 0:Ll.length)-1])==null?void 0:zl.split("."))==null?void 0:Ul[0],url:Sl==null?void 0:Sl.url}});Za=[...Za,...vl]}let hl={};for(let ll in h)ll!=="id"&&(hl[ll]=h[ll]);hl[Xa]=Za,Ua.push({id:h==null?void 0:h.id,value:{tableData:hl}})}if((Ua==null?void 0:Ua.length)>0){const Za=Ua.map(Ka=>{const hl={id:Ka.id,...Ka.value.tableData};return delete hl._isOCRRow,delete hl._ocrTableId,delete hl._isTemp,delete hl.tableEditType,delete hl.index,hl}),kl=[{tableName:(za=u==null?void 0:u.related)==null?void 0:za.find(Ka=>Ka==null?void 0:Ka.includes("content")),tableContents:Za}];await I.pageBatchUpdateApi({platId:parseInt((dl=Rl.value)==null?void 0:dl.plat_id),changeContents:kl})}if((sa==null?void 0:sa.length)>0)try{await I.pageBatchAddApi({platId:parseInt((el=Rl.value)==null?void 0:el.plat_id),changeContents:[{tableName:(yl=u==null?void 0:u.related)==null?void 0:yl.find(Za=>Za==null?void 0:Za.includes("content")),tableContents:sa.map(Za=>{var Ka,hl,ll;const kl={id:((Ka=Za==null?void 0:Za.key)==null?void 0:Ka.id)??((hl=Za==null?void 0:Za.key)==null?void 0:hl.rowId)??(Za==null?void 0:Za.id),...((ll=Za==null?void 0:Za.value)==null?void 0:ll.tableData)||{}};return delete kl._isOCRRow,delete kl._ocrTableId,delete kl._isTemp,delete kl.tableEditType,delete kl.index,Object.keys(kl).forEach(vl=>{vl==="证书附件"&&Array.isArray(kl[vl])&&(kl[vl]=JSON.stringify(kl[vl]))}),kl})}]})}catch(Za){rl.ElMessage.error(((Vl=(gl=Za==null?void 0:Za.response)==null?void 0:gl.data)==null?void 0:Vl.message)||(Za==null?void 0:Za.message)||"保存失败"),Ge.setTableLoading(!1);return}Io(!0),la.setImportLoading(!1),Ge.setFreshContent(!0)},ri=(d,h)=>(d=d==null?void 0:d.map(z=>{var O,R;return z!=null&&z.children&&((O=z.children)!=null&&O.find(D=>D.id===(h==null?void 0:h.id))?z.children=(R=z.children)==null?void 0:R.filter(D=>(D==null?void 0:D.id)!==(h==null?void 0:h.id)):z.children=ri(z.children,h)),z}),d),co=a.ref(!1),Ji=()=>{co.value=!0},Xi=async d=>{var z,O,R,D;co.value=!1;const h=Array.isArray(d)?d:d?[d]:[];if(h.length!==0)for(const Q of h){const ae={name:Q.name||`capture-${Date.now()}.jpg`,url:URL.createObjectURL(Q),raw:Q,uid:Date.now()+Math.random()};xe.value.push(ae),Nl(ae,"uploading"),Ol(ae,0);try{const j=new FormData;j.append("file",Q,ae.name);const he=await I.platformUploadFile(j);ae.uploadResult=((z=he==null?void 0:he.data)==null?void 0:z.result)||{name:ae.name,url:"",fileName:ae.name},Be({name:((O=ae.uploadResult)==null?void 0:O.name)||ae.name,url:((R=ae.uploadResult)==null?void 0:R.url)||"",id:(D=ae.uploadResult)==null?void 0:D.id}),Nl(ae,"uploaded"),Ol(ae,100)}catch(j){console.error("文件上传失败:",j),rl.ElMessage.error(`文件 ${ae.name} 上传失败,请重试`),Nl(ae,"pending"),Ol(ae,0);const he=xe.value.findIndex(be=>be.uid===ae.uid);he>-1&&xe.value.splice(he,1)}}},t=a.reactive({title:"迁移至",show:!1,width:"20%",selectRow:null,from:u==null?void 0:u.index,to:null,contents:[],formRules:{groupName:[{required:!0,message:"输入不能为空",trigger:"blur"},{validator:(d,h,z)=>{h===(u==null?void 0:u.index)?z(new Error("选择源不能和目标源一致")):z()}}]},buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"确认",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]}),i=a.reactive({title:"温馨提示:检测到导入的以下数据,系统中已存在,请选择操作",show:!1,width:"70%",columns:[],tableData:[],existRows:[],buttonValue:[{label:"取消",value:"cancel",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"覆盖",render:"popover",value:"replace",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}],result:""}),p=()=>{i.show=!1},g=async d=>{var h,z,O,R,D,Q,ae,j;try{if(d==="cancel"&&(i.show=!1),d==="replace"&&((h=i==null?void 0:i.existRows)==null?void 0:h.length)>0){await I.pageBatchDeleteApi({platId:parseInt((z=Rl.value)==null?void 0:z.plat_id),changeContents:[{tableName:((O=u==null?void 0:u.related)==null?void 0:O.find(be=>be==null?void 0:be.includes("content_")))||((R=u==null?void 0:u.related)==null?void 0:R.find(be=>be==null?void 0:be.includes("content"))),tableContents:i==null?void 0:i.existRows}]});const he=await I.pageBatchAddApi({platId:parseInt((D=Rl.value)==null?void 0:D.plat_id),changeContents:[{tableName:(Q=u==null?void 0:u.related)==null?void 0:Q.find(be=>be==null?void 0:be.includes("content")),tableContents:(()=>{const be=(_e.value||[]).filter(ia=>!((i==null?void 0:i.existRows)||[]).some(ja=>String(ja==null?void 0:ja.id)===String(ia==null?void 0:ia.id))),$e=(i==null?void 0:i.tableData)||[],ze=[];let qe=be.slice();return $e.forEach(ia=>{const ja={...ia};try{ja.sort=Bn(0,qe)}catch{}ze.push(ja),qe.unshift(ja)}),ze.map((ia,ja)=>({id:ja,...ia}))})()}]});((ae=he==null?void 0:he.data)==null?void 0:ae.code)===200&&(await mt({buttonName:"新增",columns:De.value,fixContent:(j=i==null?void 0:i.tableData)==null?void 0:j.map((be,$e)=>({id:$e,...be})),relatedContents:u==null?void 0:u.related}),rl.ElMessage.success("数据导入替换成功"))}}catch{throw new Error(e)}finally{i.show=!1,i.columns=[],i.tableData=[],i.existRows=[]}},C=()=>{t.show=!1},L=d=>{var h,z;if((d==null?void 0:d.buttonName)==="取消")return t.show=!1;t.to=d==null?void 0:d.content,!(!(u!=null&&u.index)||!((h=t.to)!=null&&h.groupName))&&(u==null?void 0:u.index)!==((z=t.to)==null?void 0:z.groupName)&&(Ie("change",{buttonName:"迁移",value:{from:t.from,to:t.to,data:t.selectRow}}),t.show=!1)},H=async d=>{var h,z,O,R;if(d){if(!Dr.validateFileSize(d.raw)){rl.ElMessage.warning(`文件大小不能超过 ${Zr.value.maxSize}MB`);const D=xe.value.findIndex(Q=>Q.uid===d.uid);D>-1&&xe.value.splice(D,1),G();return}if(!Dr.validateFileType(d.raw)){rl.ElMessage.warning("请上传图片文件");const D=xe.value.findIndex(Q=>Q.uid===d.uid);D>-1&&xe.value.splice(D,1),G();return}Nl(d,"uploading"),Ol(d,0);try{const D=new FormData;D.append("file",d.raw,d.name);const Q=await I.platformUploadFile(D);d.uploadResult=((h=Q==null?void 0:Q.data)==null?void 0:h.result)||{name:d.name,url:"",fileName:d.name},Be({name:((z=d.uploadResult)==null?void 0:z.name)||d.name,url:((O=d.uploadResult)==null?void 0:O.url)||"",id:(R=d.uploadResult)==null?void 0:R.id}),Nl(d,"uploaded"),Ol(d,100)}catch(D){console.error("文件上传失败:",D),rl.ElMessage.error(`文件 ${d.name} 上传失败,请重试`),Nl(d,"pending"),Ol(d,0);const Q=xe.value.findIndex(ae=>ae.uid===d.uid);Q>-1&&xe.value.splice(Q,1)}finally{G()}}},G=()=>{a.nextTick(()=>{const d=document.querySelector('.ocr-upload-input input[type="file"]');d&&(d.value="")})},pe=async()=>{var z,O;if(sessionStorage.setItem("ocr_root_table_id",String((u==null?void 0:u.index)??"")),xe.value.length===0){rl.ElMessage.warning("请先选择要上传的图片");return}if(xe.value.filter(R=>{const D=cl(R);return D!=="uploaded"&&D!=="completed"&&D!=="failed"}).length>0){rl.ElMessage.warning("请等待所有文件上传完成后再开始识别");return}je.value=!0,we.value=0;let h=null;try{xe.value.forEach(na=>{Nl(na,"processing")});const R=Math.floor(Math.random()*10)+90;h=setInterval(()=>{we.value<R?we.value+=1:clearInterval(h)},50);const D=xe.value.map(na=>{var Xa,sa,Ua;return{name:((Xa=na.uploadResult)==null?void 0:Xa.name)||na.name,url:((sa=na.uploadResult)==null?void 0:sa.url)||"",fileName:((Ua=na.uploadResult)==null?void 0:Ua.fileName)||na.name}}),Q=Dr.extractTableHeaders(De.value),ae=D.map(na=>({name:(na==null?void 0:na.fileName)||(na==null?void 0:na.name),url:(na==null?void 0:na.url)||""})),j=await Dr.recognize(ae,Q);if(console.log(j,"ocrResult"),clearInterval(h),h=null,(j==null?void 0:j.code)===500||(j==null?void 0:j.type)==="error"||!(j!=null&&j.result)){we.value=0,xe.value.forEach(na=>{Nl(na,"failed"),Ol(na,0)}),rl.ElMessage.error((j==null?void 0:j.message)||"OCR识别失败,请重试"),je.value=!1;return}we.value=R;const he=Array.isArray(j==null?void 0:j.result)?j.result:[];if(he.length===0){we.value=0,xe.value.forEach(na=>{Nl(na,"failed"),Ol(na,0)}),rl.ElMessage.warning("OCR识别未返回有效数据"),je.value=!1;return}const be=new Set,$e=[];he.forEach((na,Xa)=>{const sa=na!=null&&na.数据&&typeof(na==null?void 0:na.数据)=="object"?na.数据:{},Ua=Array.isArray(na==null?void 0:na.图片信息)?na.图片信息:[],te=new Map;Ua.forEach(da=>{da!=null&&da.name&&te.set(da.name,da.url||"")});const Da={_index:Xa,_certType:(na==null?void 0:na.证书类型)||"",_certNo:(na==null?void 0:na.证书编号)||"",_ocrImages:Ua,__ocrFieldMeta:{}};Object.entries(sa).forEach(([da,Ca])=>{let Ba="",M=0,K=[],Ae="";Ca&&typeof Ca=="object"&&!Array.isArray(Ca)?(Ba=(Ca==null?void 0:Ca.value)??"",M=(Ca==null?void 0:Ca.score)??0,K=Array.isArray(Ca==null?void 0:Ca.bboxNorm)?Ca==null?void 0:Ca.bboxNorm:[],Ae=(Ca==null?void 0:Ca.imageName)||""):Array.isArray(Ca)&&Ca.length>=2?(Ba=Ca[0]??"",M=Ca[1]??0):(Ba=Ca??"",M=0),Da[da]=Ba,Da[`${da}_accuracy`]=M,be.add(da),Da.__ocrFieldMeta[da]={value:Ba,score:M,bboxNorm:K,imageName:Ae,imageUrl:Ae&&te.get(Ae)||"",images:Ua}}),$e.push(Da)});const ze=[],qe=new Set;$e.forEach(na=>{na&&be.forEach(Xa=>{const sa=na[`${Xa}_accuracy`];(typeof sa=="number"?sa>0:sa!=null&&String(sa).trim()!==""&&String(sa)!=="0")&&qe.add(Xa)})}),be.forEach(na=>{ze.push({prop:na,label:na,editable:!0,minWidth:230}),qe.has(na)&&ze.push({prop:`${na}_accuracy`,label:"准确率",editable:!1,minWidth:100,isAccuracy:!0})}),xe.value.forEach(na=>{Nl(na,"completed")}),we.value=100,fe.value=ze,qa.value=$e,_l.value=D,Ha.value=j;const ia=["出厂编号","设备名称","制造厂"],ja=ze.filter(na=>na&&!na.isAccuracy&&typeof na.prop=="string").map(na=>na.prop),Aa=["出厂编号","设备名称","制造厂"];il.value=ja.filter(na=>Aa.includes(na)),console.log("[OCR] 默认勾选字段 props:",il.value),q.value=2,je.value=!1,Se.value=!1}catch(R){console.error("OCR处理失败:",R),h&&(clearInterval(h),h=null),rl.ElMessage.error(((O=(z=R==null?void 0:R.response)==null?void 0:z.data)==null?void 0:O.message)||"OCR识别失败,请重试"),je.value=!1,we.value=0,xe.value.forEach(D=>{Nl(D,"pending"),Ol(D,0)})}},Me=d=>{if(d==null)return"";let h=String(d);return h=h.replace(/\s+/g," ").trim(),h=h.replace(/[!-~]/g,z=>String.fromCharCode(z.charCodeAt(0)-65248)),h=h.replace(/ /g," "),h=h.replace(/^(编号|No\.?|NO\.?|no\.?|SN\.?|sn\.?|序列号)\s*[::]?\s*/i,""),h},ye=()=>{var na,Xa;const d=_l.value,h=Ha.value,z=qa.value;if(!z||z.length===0){rl.ElMessage.warning("暂无数据可添加");return}const O=(na=ca.getAllLeafNodes(De.value)||[])==null?void 0:na.filter(sa=>(sa==null?void 0:sa.type)!=="operate"&&(sa==null?void 0:sa.label)!=="操作"&&(sa==null?void 0:sa.prop)!=="operate"),R=new Map,D=new Map,Q=(Xa=O==null?void 0:O.find(sa=>(sa==null?void 0:sa.label)==="证书附件"))==null?void 0:Xa.prop;O==null||O.forEach(sa=>{sa!=null&&sa.label&&(sa!=null&&sa.prop)&&(R.set(sa.label,sa.prop),D.set(sa.prop,sa.label))});const ae=Date.now(),j=sa=>String(ae*1e3+sa),he=[],be=[],$e=sa=>{const Ua=_i&&_i[sa]||[sa];for(const te of Ua){const Da=R.get(te);if(Da)return Da}return""},ze=$e("出厂编号"),qe=$e("设备名称"),ia=$e("制造厂"),ja=[],Aa=sa=>{var Ba,M;if(!Q)return[];const Ua=(Array.isArray(d)?d[sa]:null)||null,te=(Ua==null?void 0:Ua.url)||"",Da=(Ua==null?void 0:Ua.fileName)||(Ua==null?void 0:Ua.name)||"";return(String(Da).toLowerCase().endsWith(".pdf")||String(te).toLowerCase().endsWith(".pdf"))&&te?[{url:te,name:Da,fileName:Da}]:(Array.isArray((M=(Ba=h==null?void 0:h.result)==null?void 0:Ba[sa])==null?void 0:M.图片信息)?h.result[sa].图片信息:[]).map(K=>({url:(K==null?void 0:K.url)||"",name:(K==null?void 0:K.name)||"",fileName:(K==null?void 0:K.name)||""})).filter(K=>K.url)};if(z.forEach((sa,Ua)=>{var dl;const te={id:j(Ua),_isOCRRow:!0,_ocrTableId:u==null?void 0:u.index};for(const[el,yl]of R.entries())Object.prototype.hasOwnProperty.call(sa,el)&&(te[yl]=sa[el]);Q&&(te[Q]=Aa(Ua));const Da=(Array.isArray(h==null?void 0:h.result)?h.result[Ua]:null)||null,da=(Array.isArray(d)?d[Ua]:null)||null,Ca=(da==null?void 0:da.url)||"",Ba=(da==null?void 0:da.fileName)||(da==null?void 0:da.name)||"",M=String(Ba).toLowerCase().endsWith(".pdf")||String(Ca).toLowerCase().endsWith(".pdf"),K={ts:Date.now(),versionId:String(Date.now())+"_"+String(Ua),label:new Date().toLocaleString(),certType:(Da==null?void 0:Da.证书类型)||"",certNo:(Da==null?void 0:Da.证书编号)||"",fileType:M?"pdf":"image",sourceUrl:M?Ca:"",images:Array.isArray(Da==null?void 0:Da.图片信息)?Da.图片信息.map(el=>({name:(el==null?void 0:el.name)||"",url:(el==null?void 0:el.url)||""})).filter(el=>el.url):[]},Ae=el=>Me(el?te==null?void 0:te[el]:""),ta=Ae(ze),ke=Ae(qe),ua=Ae(ia);if(!!(ze&&qe&&ia&&ta&&ke&&ua)){const el=(_e.value||[]).find(yl=>{const gl=Me(ze?yl==null?void 0:yl[ze]:""),Vl=Me(qe?yl==null?void 0:yl[qe]:""),Za=Me(ia?yl==null?void 0:yl[ia]:"");return gl&&Vl&&Za&&gl===ta&&Vl===ke&&Za===ua});if(el){ja.push({idx:Ua,ocrRow:te,versionItem:K,ocrNo:ta,candidates:[el],selectedTargetId:String((el==null?void 0:el.id)??""),__decision:"replace",allowAdd:!1,allowReplace:!0});return}}if(ta&&ze){const el=(_e.value||[]).filter(yl=>{const gl=Me(ze?yl==null?void 0:yl[ze]:"");return gl&&gl===ta});if(el.length>0){ja.push({idx:Ua,ocrRow:te,versionItem:K,ocrNo:ta,candidates:el,selectedTargetId:"",__decision:"",allowAdd:!0,allowReplace:!0});return}}try{if(te.sort===void 0||te.sort===null||String(te.sort).trim()===""){const el=(_e.value||[]).map(gl=>Xn(gl==null?void 0:gl.sort)).filter(gl=>gl!==null),yl=el.length>0?Math.max(...el):((dl=_e.value)==null?void 0:dl.length)??0;te.sort=String(Number((yl+1).toFixed(6)))}}catch{}ml(u==null?void 0:u.index,te.id,K),ja.push({idx:Ua,ocrRow:te,versionItem:K,ocrNo:ta,candidates:[],selectedTargetId:"",__decision:"add",allowAdd:!0,allowReplace:!1})}),(ja||[]).length>0){Fl.value=(ja||[]).map(sa=>({...sa,selectedTargetId:(sa==null?void 0:sa.selectedTargetId)||""})),$l.value=!0,gr.value=be,rr.value=he,kr.value=h,wr.value=d,Er.value=Q||"";return}},Qe=(d,h,z)=>{qa.value[d]&&(qa.value[d][h]=z)},La=d=>d==null||d===0?"-":`${(Number(d)*100).toFixed(1)}%`,ol=d=>{if(d==null||d===0)return"#909399";const h=Number(d);return h>=.9?"#67c23a":h>=.7?"#e6a23c":"#f56c6c"},al=d=>{var z,O,R,D;if(Ia.value===d){Ia.value=null,Ja.value=!1,ul.value="";return}Ia.value=d,ul.value="";const h=(z=qa.value)==null?void 0:z[d];if(h&&Array.isArray(h._ocrImages)&&h._ocrImages.length>0){Wl.value=h._ocrImages.map(j=>({name:(j==null?void 0:j.name)||"",url:(j==null?void 0:j.url)||""})).filter(j=>j.name||j.url);const Q=h.__ocrFieldMeta||{},ae=(O=Object.values(Q))==null?void 0:O.find(j=>j==null?void 0:j.imageName);Kl.value=(ae==null?void 0:ae.imageName)||((D=(R=Wl.value)==null?void 0:R[0])==null?void 0:D.name)||"",Ja.value=Wl.value.length>0}else Wl.value=[],Ja.value=!1,Kl.value=""},sl=()=>{Va.value=!1,xe.value=[],Ze.value=null,q.value=1,ra.value.clear(),ya.value.clear(),we.value=0,Ja.value=!1},Cl=d=>d.raw?URL.createObjectURL(d.raw):d.url?d.url:"",cl=d=>{const h=d.uid||d.name;return ra.value.get(h)||"pending"},Bl=d=>{const h=d.uid||d.name;return ya.value.get(h)||0},Ol=(d,h)=>{const z=d.uid||d.name;ya.value.set(z,Math.min(100,Math.max(0,h)))},Yl=d=>{const h=cl(d),z=100.53;if(h==="completed"||h==="uploaded")return`${z} ${z}`;if(h==="failed")return`${z} ${z}`;if(h==="uploading"){const O=Bl(d);return`${z*(O/100)} ${z}`}else if(h==="processing")return`${z*.5} ${z}`;return`0 ${z}`},Nl=(d,h)=>{const z=d.uid||d.name;ra.value.set(z,h),(h==="completed"||h==="uploaded")&&Ol(d,100)},jl=()=>{a.nextTick(()=>{const d=document.querySelector('.ocr-upload-input input[type="file"]');if(d)d.value="",d.click();else{const h=document.createElement("input");h.type="file",h.multiple=!0,h.accept="image/*,application/pdf",h.style.display="none",h.onchange=async z=>{const O=Array.from(z.target.files||[]);for(const R of O){const D={name:R.name,raw:R,uid:Date.now()+Math.random()};xe.value.push(D),await H(D)}z.target.value="",document.body.removeChild(h)},document.body.appendChild(h),h.click()}})},Ir=()=>{q.value>1&&q.value--},mr=()=>{q.value===1?xe.value.length>0&&!je.value&&pe():q.value===2&&(ye(),q.value=3)},Fr=async d=>{await tn(d==null?void 0:d.row)},en=async({row:d,prop:h})=>{!d||!h||await tn(d,h)},tn=async(d,h)=>{var R,D;const z=d==null?void 0:d.id;if(!z){rl.ElMessage.warning("暂无可预览数据");return}let O=Ea(u==null?void 0:u.index,z);if(!O||O.length===0){const Q=sessionStorage.getItem("ocr_root_table_id"),ae=Q!==null?Number(Q):null;if(ae!=null&&ae!==""&&!Number.isNaN(ae)){const j=Ea(ae,z);Array.isArray(j)&&j.length>0&&(El(u==null?void 0:u.index,z,j),O=j)}}if(!O||O.length===0){const Q=(R=ca.getAllLeafNodes(De.value)||[])==null?void 0:R.filter(j=>(j==null?void 0:j.type)!=="operate"&&(j==null?void 0:j.label)!=="操作"&&(j==null?void 0:j.prop)!=="operate"),ae=h||((D=Q==null?void 0:Q.find(j=>(j==null?void 0:j.label)==="证书附件"))==null?void 0:D.prop);if(ae&&d[ae]){const j=d[ae];let he=[],be="",$e=!1;if(typeof j=="string")try{const ze=JSON.parse(j);Array.isArray(ze)&&(he=ze.map(qe=>({name:(qe==null?void 0:qe.name)||(qe==null?void 0:qe.fileName)||"",url:(qe==null?void 0:qe.url)||""})).filter(qe=>qe.url||qe.name),he.length>0&&(be=he[0].url||"",$e=String(he[0].name).toLowerCase().endsWith(".pdf")||String(be).toLowerCase().endsWith(".pdf")))}catch{be=j,$e=String(j).toLowerCase().endsWith(".pdf"),he=[{name:j,url:j}]}else Array.isArray(j)&&(he=j.map(ze=>({name:(ze==null?void 0:ze.name)||(ze==null?void 0:ze.fileName)||"",url:(ze==null?void 0:ze.url)||""})).filter(ze=>ze.url||ze.name),he.length>0&&(be=he[0].url||"",$e=String(he[0].name).toLowerCase().endsWith(".pdf")||String(be).toLowerCase().endsWith(".pdf")));if(he.length>0||be){const ze={ts:Date.now(),versionId:String(Date.now()),label:new Date().toLocaleString(),certType:d.证书类型||"",certNo:d.证书编号||"",fileType:$e?"pdf":"image",sourceUrl:$e?be:"",images:he};O=[ze],ml(u==null?void 0:u.index,z,ze)}}}if(!O||O.length===0){rl.ElMessage.warning("暂无可预览数据");return}ea.value=O,Je.value=!0},uo=d=>{xe.value=xe.value.filter((h,z)=>z!==d)},Tn=async(d,h,z)=>{var O,R,D,Q,ae,j,he,be,$e,ze,qe,ia,ja,Aa,na,Xa,sa,Ua,te,Da,da;if(Oe(u.config,{type:oa.TABLE,tableOperate:d})){if(Xe.value="",Ue.value=!0,aa.value=!0,Ie("onButtonClick",d,h),W.value=[],d==="删除")I.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var Ca,Ba,M,K;(Ca=_e.value)!=null&&Ca.find(Ae=>(Ae==null?void 0:Ae.id)===(h==null?void 0:h.id))?_e.value=(Ba=I.cloneDeep(_e.value))==null?void 0:Ba.filter(Ae=>(Ae==null?void 0:Ae.id)!==(h==null?void 0:h.id)):_e.value=ri(I.cloneDeep(_e.value),h);try{h!=null&&h.id&&((K=(M=ve.value)==null?void 0:M.has)!=null&&K.call(M,h==null?void 0:h.id))&&ve.value.delete(h.id)}catch{}tf(Br.value,In.value,h==null?void 0:h.id),Ge.setTableLoading(u==null?void 0:u.index),Ie("change",{content:_e.value,fixContent:[h],index:u==null?void 0:u.index,type:"delete",name:u==null?void 0:u.compName,buttonName:d,columns:De.value,relatedContents:u==null?void 0:u.related}),console.log(h,"item")});else if(d==="批量删除"){if(((O=ar.value)==null?void 0:O.length)===0)return rl.ElMessage.warning("请先勾选操作的数据");I.ElMessageBox.confirm("是否确认删除","温馨提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(async()=>{var M,K,Ae,ta,ke;const Ca=(M=ar.value)==null?void 0:M.map(ua=>ua.id);_e.value=(K=I.cloneDeep(_e.value))==null?void 0:K.filter(ua=>!(Ca!=null&&Ca.includes(ua.id))),Ge.setTableLoading(u==null?void 0:u.index),Ie("change",{content:_e.value,fixContent:ar.value,index:u==null?void 0:u.index,type:"delete",name:u==null?void 0:u.compName,buttonName:d,relatedContents:u==null?void 0:u.related,columns:De.value});const Ba=(Ca||[]).filter(Boolean);if(Ba.length>0&&Ba.every(ua=>ua!=null&&ua!=="")){const ua=(ar.value||[]).map(za=>{const dl={...za};return delete dl._isOCRRow,delete dl._ocrTableId,delete dl._isTemp,delete dl.tableEditType,delete dl.index,dl});await I.pageBatchDeleteApi({platId:parseInt((Ae=Rl.value)==null?void 0:Ae.plat_id),changeContents:[{tableName:((ta=u==null?void 0:u.related)==null?void 0:ta.find(za=>za==null?void 0:za.includes("content_")))||((ke=u==null?void 0:u.related)==null?void 0:ke.find(za=>za==null?void 0:za.includes("content"))),tableContents:ua}]})}})}else if(d==="复制新增"){Le.value="复制新增",I.cloneDeep(h);const Ca=(R=De.value)==null?void 0:R.find(Ba=>Ba==null?void 0:Ba.isMainKey);Ca||((D=De.value)==null||D[0]),Il.value=h,Io(!0)}else if(d==="新增")Le.value="新增",Mo(""),va.value=!0;else if(d==="编辑")Le.value="编辑",Mo(h),va.value=!0;else if(d==="查看")Le.value="查看",Mo(h),Ue.value=!1,aa.value=!1,va.value=!0;else if(d==="查看三维模型"){const Ca={};for(let M in h)M!=="id"&&(Ca[M]=h[M]);let Ba=(Q=Object.values(Ca))==null?void 0:Q[1];Re.setTableShowThree(Ba)}else if(d==="切换视图")nu();else if(((ae=z==null?void 0:z.extra)==null?void 0:ae.type)==="modelExample")Le.value=d,Z.value=!0;else if(d==="新建"){let Ca=ie.value,Ba=[];for(let ke in Ca)ke!=null&&ke.includes(`loading${((j=Rl.value)==null?void 0:j.account)||((he=Rl.value)==null?void 0:he.账号)}`)&&(Ba=[...Ba,...ke]);let M=[];for(let ke in Ca)ke!=null&&ke.includes(`updateLoading${((be=Rl.value)==null?void 0:be.account)||(($e=Rl.value)==null?void 0:$e.账号)}`)&&(M=[...M,...ke]);let K=Ba==null?void 0:Ba.map(ke=>ke==null?void 0:ke.id);const Ae=M==null?void 0:M.map(ke=>ke==null?void 0:ke.id);K=[...I.cloneDeep(K),...Ae],(K==null?void 0:K.length)>0&&(K!=null&&K.every(ke=>ke!==null&&ke))&&await yr.batchDeleteInsofDataApi({ids:K});const ta=(ze=ba.value)==null?void 0:ze.find(ke=>(ke==null?void 0:ke.label)==="新建");await Gc(!1,ta)}else if(d==="修改模板"){let Ca=I.cloneDeep(ka).value;Ge.setRouteToChildPath(Ca),la.setActiveMenuPath(Ca+k)}else if(d==="执行")Gi(d,h);else if(d==="导出paraform"){const Ca=I.ElLoading.service({lock:!0,text:"正在导出paraform...",background:"rgba(0, 0, 0, 0.7)"});try{const Ba=["推力","真空","压力","温度","流量"],M=wl=>{var zl,Ul,Al;return wl?typeof(wl==null?void 0:wl.value)=="string"?wl.value:((Al=(Ul=(zl=wl==null?void 0:wl._custom)==null?void 0:zl.value)==null?void 0:Ul.value)==null?void 0:Al.value)||"":""},K=Array.isArray(mn.value)?mn.value:[],Ae=M(K.find(wl=>(wl==null?void 0:wl.condition)==="child")),ta=String(Ae||"").slice(0,8),ke=wl=>{if(wl==null)return"";const zl=String(wl).trim();if(!zl)return"";if(/^\d{8}$/.test(zl))return zl;const Ul=zl.match(/^(\d{4})[-\/.](\d{1,2})[-\/.](\d{1,2})$/);if(Ul){const ur=Ul[1],dr=Ul[2].padStart(2,"0"),Gl=Ul[3].padStart(2,"0");return`${ur}${dr}${Gl}`}const Al=zl.replace(/\D/g,"");return Al.length>=8?Al.slice(0,8):""},ua=async wl=>{var zl,Ul;if(!wl)return"";try{const Al=await Vr("试验任务/任务管理",!1),ur=(tr,lr=[])=>{if(!Array.isArray(tr))return lr;for(const nr of tr)(nr==null?void 0:nr.comp)==="Table"&&(nr!=null&&nr.name)&&lr.push(nr),Array.isArray(nr==null?void 0:nr.children)&&ur(nr.children,lr),Array.isArray(nr==null?void 0:nr.tab)&&ur(nr.tab,lr),Array.isArray(nr==null?void 0:nr.choice)&&ur(nr.choice,lr);return lr},Gl=ur(Al||[]).find(tr=>(tr==null?void 0:tr.name)==="任务列表"),ir=((Ul=(zl=Gl==null?void 0:Gl.compData)==null?void 0:zl.find(tr=>(tr==null?void 0:tr.key)==="tableContents"))==null?void 0:Ul.contents)||[];if(!Array.isArray(ir)||ir.length===0)return"";const $r=ir.find(tr=>String((tr==null?void 0:tr["试验代号(名称)"])||"").slice(0,8)===wl);return ke($r==null?void 0:$r.计划试验时间)}catch(Al){return console.warn("获取任务列表计划试验时间失败:",Al),""}},za=(ka.value||"").replace(/\/+$/,""),dl=Ae?`${za}/${Ae}`:za,el=await Vr(dl||ka.value,!1),yl=String(ma.value||"").trim(),gl=wl=>String(wl||"").trim(),Vl=(wl,zl=[],Ul="")=>{if(!Array.isArray(wl))return zl;for(const Al of wl){const ur=gl((Al==null?void 0:Al.choiceName)||(Al==null?void 0:Al.name0)||Ul);(Al==null?void 0:Al.comp)==="Table"&&(Al==null?void 0:Al.name)&&Ba.includes(Al.name)&&(!yl||ur===yl)&&zl.push(Al),Array.isArray(Al==null?void 0:Al.children)&&Vl(Al.children,zl,ur),Array.isArray(Al==null?void 0:Al.tab)&&Vl(Al.tab,zl,ur),Array.isArray(Al==null?void 0:Al.choice)&&Vl(Al.choice,zl,ur)}return zl},Za=Vl(el||[]),kl=new Map;for(const wl of Za)wl!=null&&wl.name&&!kl.has(wl.name)&&kl.set(wl.name,wl);const Ka=Ba.map(wl=>kl.get(wl)).filter(Boolean);if(!Ka||Ka.length===0)return rl.ElMessage.warning("未找到需要导出的表(推力、真空、压力、温度、流量)");const hl=wl=>{const zl=new Map,Ul=(Al,ur=[])=>{if(Array.isArray(Al))for(const dr of Al){const Gl=((dr==null?void 0:dr.label)??"").toString().trim(),ir=Gl?[...ur,Gl]:[...ur];if(Array.isArray(dr==null?void 0:dr.children)&&dr.children.length>0)Ul(dr.children,ir);else{const tr=((dr==null?void 0:dr.prop)??"").toString();if(!tr)continue;const lr=Gl||tr,nr=(ir.length>0?[...ur,lr]:[lr]).join(".");zl.set(tr,nr)}}};return Ul(wl,[]),zl},ll=(wl,zl)=>{const Ul=hl(wl||[]),ur=(ca.getAllLeafNodes(wl||[])||[]).filter(Gl=>(Gl==null?void 0:Gl.prop)&&(Gl==null?void 0:Gl.type)!=="operate"&&(Gl==null?void 0:Gl.label)!=="操作"&&(Gl==null?void 0:Gl.prop)!=="operate"),dr=Array.isArray(zl)?zl:[];return dr.length===0?[]:dr.map(Gl=>{const ir={};return ur.forEach($r=>{const tr=String($r.prop),lr=Ul.get(tr)||String($r.label||$r.prop);ir[lr]=(Gl==null?void 0:Gl[tr])??""}),ir})},vl=Ka.map(wl=>{var dr,Gl;const zl=(wl==null?void 0:wl.compData)||[];let Ul=(dr=zl==null?void 0:zl.find(ir=>(ir==null?void 0:ir.key)==="header"))==null?void 0:dr.contents;Array.isArray(Ul==null?void 0:Ul[0])&&(Ul=Ul[0]);const Al=((Gl=zl==null?void 0:zl.find(ir=>(ir==null?void 0:ir.key)==="tableContents"))==null?void 0:Gl.contents)||[];if(!Array.isArray(Ul)||Ul.length===0||!Array.isArray(Al)||Al.length===0)return null;const ur=ll(Ul||[],Al||[]);return!Array.isArray(ur)||ur.length===0?null:{类型:wl==null?void 0:wl.name,数据:ur}}).filter(Boolean);if(!vl||vl.length===0)return rl.ElMessage.warning("没有可导出的数据(推力、真空、压力、温度、流量均为空)");const Sl=await ua(ta),Tl={试验代号:ta,试验日期:Sl,ParaForm:vl},hr=await so().catch(()=>""),Ll=await I.exportParaformApi(Tl,hr);if(((qe=Ll==null?void 0:Ll.data)==null?void 0:qe.code)===200&&((ja=(ia=Ll==null?void 0:Ll.data)==null?void 0:ia.result)!=null&&ja.Excel文件)){const wl=Ll.data.result.Excel文件,zl=await I.platformDownloadFile({url:wl}),Ul=new Blob([zl.data],{type:"application/vnd.ms-excel"}),Al=URL.createObjectURL(Ul),ur=I.dayjs().format("YYYYMMDD"),Gl=`${(ta||"UNKNOWN").trim()||"UNKNOWN"}_${ur}_paraform.xls`,ir=document.createElement("a");ir.href=Al,ir.download=Gl,ir.style.display="none",document.body.appendChild(ir),ir.click(),setTimeout(()=>{document.body.removeChild(ir),URL.revokeObjectURL(Al)},100);const $r=Array.isArray((na=(Aa=Ll==null?void 0:Ll.data)==null?void 0:Aa.result)==null?void 0:na.warnings)?Ll.data.result.warnings:[];if($r.length>0){const tr=$r.map((lr,nr)=>`${nr+1}. ${(lr==null?void 0:lr.field)||"未知字段"}:${(lr==null?void 0:lr.message)||""}`).join(`
24
- `);rl.ElMessage.warning({message:`导出成功,但存在以下提示:
25
- ${tr}`,duration:5e3,showClose:!0})}else rl.ElMessage.success("导出成功")}else rl.ElMessage.error(((Xa=Ll==null?void 0:Ll.data)==null?void 0:Xa.message)||"导出失败")}catch(Ba){console.error("导出paraform失败:",Ba),rl.ElMessage.error("导出失败:"+((Ba==null?void 0:Ba.message)||"未知错误"))}finally{Ca.close()}}else if(d!=null&&d.includes("导出")&&d!=="导出paraform"){if(d==="导出选中"&&((sa=ar.value)==null?void 0:sa.length)===0)return rl.ElMessage.warning(`请先勾选${d}的数据`);if(d==="导出全部"&&((Ua=_e.value)==null?void 0:Ua.length)===0)return rl.ElMessage.warning("暂无数据导出");let Ca=["序号",...(Da=(te=De.value)==null?void 0:te.map(Ae=>Ae==null?void 0:Ae.prop))==null?void 0:Da.filter(Ae=>Ae!=="操作")],Ba=d==="导出全部"?_e.value:ar.value;const M=["id","sort","tableEditType","create_time","update_time","source_table","create_user_id","update_user_id","department_id","relatedId"];Ba=Ba==null?void 0:Ba.map(Ae=>Object.fromEntries(Object.entries(Ae).filter(([ta])=>!M.includes(ta)))),Ca=["序号",...Ca],Ba=Ba==null?void 0:Ba.map((Ae,ta)=>({序号:ta+1,...Ae}));let K=(u==null?void 0:u.compName)||"表格信息";Oi(Ba,K,Ca,K)}else if(d==="OCR识别")Va.value=!0,xe.value=[],q.value=1,ra.value.clear(),ya.value.clear(),we.value=0;else if(d==="迁移")t.selectRow=h,t.show=!0;else if(d==="生成方法"){let Ca=await Sf(h),Ba;h!==""?Ba=[h]:Ba=I.cloneDeep(_e.value),Ba=Ba==null?void 0:Ba.map(K=>(K.输出值=Ca,K));const M={fixContent:Ba,buttonName:"编辑",relatedContents:u==null?void 0:u.related,columns:De.value,name:u==null?void 0:u.compName};Ie("change",M)}else if(((da=z==null?void 0:z.extra)==null?void 0:da.type)==="methodButton"){let Ca;h!==""?Ca=[h]:Ca=I.cloneDeep(_e.value);const M={fixContent:await ut(Ca,De==null?void 0:De.value,"Manual",_e.value),buttonName:"methodButton",relatedContents:u==null?void 0:u.related,columns:De.value,name:u==null?void 0:u.compName};Ie("change",M)}}},Kc=async(d,h)=>{var z,O,R,D,Q,ae,j,he,be,$e,ze,qe,ia,ja,Aa,na,Xa,sa,Ua,te;try{let Da,da;const Ca=(z=ie.value[ka.value+k])==null?void 0:z.filter(za=>{var dl;return((dl=za==null?void 0:za.key)==null?void 0:dl.type)==="structureMethod"}),Ba=(O=ie.value[ka.value+k])==null?void 0:O.filter(za=>{var dl;return((dl=za==null?void 0:za.key)==null?void 0:dl.type)==="structure"}),M=Ca==null?void 0:Ca.find(za=>{var dl,el;return((el=(dl=za==null?void 0:za.value)==null?void 0:dl.pageData)==null?void 0:el.method)==="保存"});if(!M)return;const K=(ae=(Q=ie.value[(D=(R=M==null?void 0:M.value)==null?void 0:R.pageData)==null?void 0:D.path])==null?void 0:Q.filter(za=>{var dl;return((dl=za==null?void 0:za.key)==null?void 0:dl.type)==="data"}))==null?void 0:ae.find(za=>{var dl,el,yl,gl;return((el=(dl=za==null?void 0:za.value)==null?void 0:dl.tableData)==null?void 0:el.算法名称)===((gl=(yl=M==null?void 0:M.value)==null?void 0:yl.pageData)==null?void 0:gl.method)});if(!K)return;const Ae={buttonName:(he=(j=M==null?void 0:M.value)==null?void 0:j.pageData)==null?void 0:he.method,api:($e=(be=K==null?void 0:K.value)==null?void 0:be.tableData)==null?void 0:$e.算法体,content:Ba==null?void 0:Ba.map(za=>{var dl;return(dl=za==null?void 0:za.value)==null?void 0:dl.pageData}),extraContent:[],extraValues:(qe=(ze=M==null?void 0:M.value)==null?void 0:ze.pageData)==null?void 0:qe.data,methodName:(ja=(ia=M==null?void 0:M.value)==null?void 0:ia.pageData)==null?void 0:ja.path};if(!d)return;const ta={...d,compData:(Aa=d==null?void 0:d.compData)==null?void 0:Aa.map(za=>{var dl;return(za==null?void 0:za.key)==="formContent"?{...za,contents:(dl=za==null?void 0:za.contents)==null?void 0:dl.map(el=>(el==null?void 0:el.prop)===h?{...el,value:""}:el)}:za})},ke={key:{pageKey:ka.value+k,parentTable:"",systemKey:sessionStorage.getItem("systemKey"),type:"structure"},value:{pageData:ta}},ua=await rl.axios.post(Ae.api,ke,{headers:{"Content-Type":"application/json"}});return((na=ua==null?void 0:ua.data)==null?void 0:na.code)===200&&(Da=(sa=(Xa=ua==null?void 0:ua.data)==null?void 0:Xa.result)==null?void 0:sa.latestReportCode,da=(te=(Ua=ua==null?void 0:ua.data)==null?void 0:Ua.result)==null?void 0:te.status),{newMainKeyValue:Da,newStatus:da}}catch(Da){throw rl.ElMessage.error(Da),new Error(Da)}},St=a.reactive({prop:"状态",value:""});a.ref(["系统自动生成信息","审批意见"]);const Yc=async(d,h,z)=>{var j,he;let O=d==null?void 0:d[h==null?void 0:h.prop],R=1,D,Q;const ae=I.cloneDeep(ka).value+k+O;if(ae){St.value="",D=(j=ie.value[ae])==null?void 0:j.filter(ze=>{var qe;return((qe=ze==null?void 0:ze.key)==null?void 0:qe.type)==="structure"});const be=D==null?void 0:D.find(ze=>{var qe,ia,ja;return((ja=(ia=(qe=ze==null?void 0:ze.value)==null?void 0:qe.pageData)==null?void 0:ia.comp)==null?void 0:ja.toUpperCase())==="FORM"});Q={...(he=be==null?void 0:be.value)==null?void 0:he.pageData,id:be==null?void 0:be.id};const $e=await Kc(Q,h==null?void 0:h.prop);if(St.value=$e==null?void 0:$e.newStatus,$e!=null&&$e.newMainKeyValue)return $e==null?void 0:$e.newMainKeyValue}if(_e.value.some(be=>(be==null?void 0:be[h==null?void 0:h.prop])===O)){const be=O;for(;_e.value.some($e=>($e==null?void 0:$e[h==null?void 0:h.prop])===`${be}(${R})`);)R++;O=`${be}(${R})`}return O},Gc=async(d,h,z)=>{var D,Q,ae,j;let O,R;if(await Yc(z==null?void 0:z.data,z==null?void 0:z.firstCol),O=I.cloneDeep(ka).value+k,R=I.cloneDeep(O)+`loading${((D=Rl.value)==null?void 0:D.account)||((Q=Rl.value)==null?void 0:Q.账号)}`,h){const he=(j=(ae=ie.value[R])==null?void 0:ae.filter(be=>{var $e;return(($e=be==null?void 0:be.key)==null?void 0:$e.parentTable)===""}))==null?void 0:j.map(be=>{var $e;return{id:be==null?void 0:be.id,...($e=be==null?void 0:be.value)==null?void 0:$e.pageData}});(he==null?void 0:he.length)>0||await ca.loadingConstruct(O,R,null,null,null),Ge.setRouteToChildPath(I.cloneDeep(ka).value),la.setActiveMenuPath(R)}else Ge.setRouteToChildPath(I.cloneDeep(ka).value),la.setActiveMenuPath(R)},Jc=()=>{Ke.value=!1,Ya.value=[],Ta.value=!1},Mo=d=>{var D,Q,ae,j,he,be,$e,ze,qe,ia,ja,Aa,na,Xa,sa,Ua,te,Da,da,Ca,Ba;const h=[];de.value=I.cloneDeep(De.value),(Q=ca.getColumnChild((D=I.cloneDeep(De.value))==null?void 0:D.filter(M=>(M==null?void 0:M.label)!=="操作")))==null||Q.forEach((M,K)=>{var Ae,ta,ke;M!=null&&M.formType&&((Ae=M==null?void 0:M.formType)==null?void 0:Ae.toUpperCase())==="SELECT"||M!=null&&M.menuId?h.push({label:(ta=M==null?void 0:M.prop)!=null&&ta.includes(".")?M==null?void 0:M.prop:(M==null?void 0:M.label)??(M==null?void 0:M.prop)??"",name:(M==null?void 0:M.prop)??"t"+K,prop:M==null?void 0:M.prop,type:"Select",value:(d==null?void 0:d[M==null?void 0:M.prop])??(M==null?void 0:M.value)??"",id:(M==null?void 0:M.id)??K,contents:(M==null?void 0:M.options)??[],width:1,isFormColHidden:M==null?void 0:M.isFormColHidden,relatedValueId:M==null?void 0:M.relatedValueId,disabled:M==null?void 0:M.disabled,menus:M==null?void 0:M.menus,groups:M==null?void 0:M.groups,words:M==null?void 0:M.words,allSelectionContents:(M==null?void 0:M.allSelectionContents)??[],filterContent:M==null?void 0:M.filterContent,disabled:(M==null?void 0:M.prop)==="disabled"?!0:M==null?void 0:M.disabled,filter:M==null?void 0:M.filter,bindMenus:M==null?void 0:M.bindMenus,isMainPath:M==null?void 0:M.isMainPath,required:(M==null?void 0:M.required)??!1,relatedContents:M==null?void 0:M.relatedContents,mainKey:M==null?void 0:M.mainKey,relatedContents:M==null?void 0:M.relatedContents,functionName:M==null?void 0:M.functionName,functionRelatedWords:M==null?void 0:M.functionRelatedWords,calculatorFilter:M==null?void 0:M.calculatorFilter}):h.push({label:(ke=M==null?void 0:M.prop)!=null&&ke.includes(".")?M==null?void 0:M.prop:(M==null?void 0:M.label)??(M==null?void 0:M.prop)??"",prop:M==null?void 0:M.prop,name:(M==null?void 0:M.prop)??"t"+K,type:!(M!=null&&M.formType)||(M==null?void 0:M.formType)===""?"Input":M==null?void 0:M.formType,value:(M==null?void 0:M.formType)==="Upload"?(d==null?void 0:d[M==null?void 0:M.prop])??"{}":(d==null?void 0:d[M==null?void 0:M.prop])??(M==null?void 0:M.value)??"",id:(M==null?void 0:M.id)??K,contents:(M==null?void 0:M.options)??[],width:1,isFormColHidden:M==null?void 0:M.isFormColHidden,disabled:(M==null?void 0:M.prop)==="disabled"?!0:M==null?void 0:M.disabled,relatedValueId:M==null?void 0:M.relatedValueId,menus:M==null?void 0:M.menus,groups:M==null?void 0:M.groups,words:M==null?void 0:M.words,filter:M==null?void 0:M.filter,bindMenus:M==null?void 0:M.bindMenus,isMainPath:M==null?void 0:M.isMainPath,required:(M==null?void 0:M.required)??!1,relatedContents:M==null?void 0:M.relatedContents,mainKey:M==null?void 0:M.mainKey,relatedContents:M==null?void 0:M.relatedContents,functionName:M==null?void 0:M.functionName,functionRelatedWords:M==null?void 0:M.functionRelatedWords,calculatorFilter:M==null?void 0:M.calculatorFilter})}),d===""||!d||(Xe.value=(d==null?void 0:d.id)??"");let z=ca.getColumnChild((ae=I.cloneDeep(De.value))==null?void 0:ae.filter(M=>(M==null?void 0:M.label)!=="操作"));Ye.value&&((j=Ye.value)==null?void 0:j.length)>0&&(Ye.value=(he=I.cloneDeep(Ye).value)==null?void 0:he.map(M=>{var Ae;let K=(M==null?void 0:M.prop)||((Ae=z==null?void 0:z.find(ta=>(ta==null?void 0:ta.label)===(M==null?void 0:M.label)))==null?void 0:Ae.prop);return K&&(M.value=d[K]),M})),$a.value=Ye.value&&((be=Ye.value)==null?void 0:be.length)>0?ca.getTableFormToForm(Ye.value):h,$a.value=(($e=$a.value)==null?void 0:$e.map(M=>({...M,disabled:(M==null?void 0:M.prop)==="disabled"?!0:M==null?void 0:M.disabled})))??$a.value;let O=[],R=((ia=(qe=(ze=u.itemData)==null?void 0:ze.filter(M=>(M==null?void 0:M.key)==="filter"))==null?void 0:qe[0])==null?void 0:ia.contents)??"";if(R=Pa.analyzeSplitToContent(R,","),(R==null?void 0:R.length)>0&&(O=R.flat()),(O==null?void 0:O.length)>0){let M=O==null?void 0:O.filter(ua=>ua==null?void 0:ua.includes("@Type"));if(M=M==null?void 0:M[(M==null?void 0:M.length)-1],(M==null?void 0:M[(M==null?void 0:M.length)-1])===","&&(M=M==null?void 0:M.slice(0,(M==null?void 0:M.length)-1)),M){let ua=(Aa=(ja=M==null?void 0:M.replace("=",$))==null?void 0:ja.split($))==null?void 0:Aa[1];((na=ua==null?void 0:ua.trim())==null?void 0:na.toUpperCase())==="MANUAL"&&(u==null||u.index,$a.value=(Xa=$a.value)==null?void 0:Xa.map((za,dl)=>za))}let K=(sa=$a.value)==null?void 0:sa.filter(ua=>ua==null?void 0:ua.mainKey),Ae;K==null||K.forEach(ua=>{var dl;if(Ae!==void 0)return;let za=ua==null?void 0:ua.menus;((dl=K==null?void 0:K.filter(el=>el==null?void 0:el.mainKey))==null?void 0:dl.length)>1&&(Ae=za,ua==null||ua.groups)});let ta=[],ke=new Map;if(K==null||K.forEach(ua=>{var za,dl,el,yl,gl,Vl,Za,kl,Ka,hl,ll,vl,Sl;if((za=ua==null?void 0:ua.prop)!=null&&za.includes(".")){let Tl=[];ke.get(((el=(dl=ua==null?void 0:ua.prop)==null?void 0:dl.split("."))==null?void 0:el[0])+(ua!=null&&ua.isMainPath?0:1)+((yl=ua==null?void 0:ua.groups)==null?void 0:yl[0]))&&(Tl=ke.get(((Vl=(gl=ua==null?void 0:ua.prop)==null?void 0:gl.split("."))==null?void 0:Vl[0])+(ua!=null&&ua.isMainPath?0:1)+((Za=ua==null?void 0:ua.groups)==null?void 0:Za[0]))),Tl.push(ua),ke.set(((Ka=(kl=ua==null?void 0:ua.prop)==null?void 0:kl.split("."))==null?void 0:Ka[0])+(ua!=null&&ua.isMainPath?0:1)+((hl=ua==null?void 0:ua.groups)==null?void 0:hl[0]),Tl)}else{let Tl=[];ke.get("normal"+(ua!=null&&ua.isMainPath?0:1)+((ll=ua==null?void 0:ua.groups)==null?void 0:ll[0]))&&(Tl=ke.get("normal"+(ua!=null&&ua.isMainPath?0:1)+((vl=ua==null?void 0:ua.groups)==null?void 0:vl[0]))),Tl.push(ua),ke.set("normal"+(ua!=null&&ua.isMainPath?0:1)+((Sl=ua==null?void 0:ua.groups)==null?void 0:Sl[0]),Tl)}}),ta=Array.from(ke.values()),(ta==null?void 0:ta.length)>0)for(let ua in ta){let za=ta==null?void 0:ta[ua];if((za==null?void 0:za.length)!==1){if((za==null?void 0:za.length)>1){let dl=za==null?void 0:za.map(hl=>hl==null?void 0:hl.prop),el=za==null?void 0:za.map(hl=>hl==null?void 0:hl.label),yl=za==null?void 0:za.map(hl=>hl==null?void 0:hl.value),gl=(Ua=I.cloneDeep(za))==null?void 0:Ua[0],Vl=(te=$a.value)==null?void 0:te.findIndex(hl=>(hl==null?void 0:hl.prop)===(gl==null?void 0:gl.prop)),Za=(Da=$a.value)==null?void 0:Da.slice(0,Vl),kl=(Ca=$a.value)==null?void 0:Ca.slice(Vl,(da=$a.value)==null?void 0:da.length);gl.label=el==null?void 0:el.join("·"),gl.value=yl==null?void 0:yl.join(" "),gl.value.trim()===""&&(gl.value=""),gl.prop=dl==null?void 0:dl.join("·");let Ka=za==null?void 0:za.map(hl=>{var ll;return(ll=hl==null?void 0:hl.words)==null?void 0:ll.join(".")});gl.relatedWords=Ka,gl.usingType="parent",kl.unshift(gl),$a.value=[...Za,...kl],$a.value=(Ba=$a.value)==null?void 0:Ba.map(hl=>(dl!=null&&dl.find(ll=>ll===(hl==null?void 0:hl.prop))&&(hl.isFormColHidden=!0,hl.relatedWords=Ka),hl))}}}}},Xc=()=>{var h;const d=(h=s.value)==null?void 0:h.$el;d&&Pa.Sortable.create(d,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:z=>{var Q;const{oldIndex:O,newIndex:R}=z;if(O===R)return;const D=xn.value.splice(O,1)[0];xn.value.splice(R,0,D),De.value=(Q=De.value)==null?void 0:Q.slice().sort((ae,j)=>{if(ae.label==="操作")return 1;if(j.label==="操作")return-1;const he=xn.value.findIndex($e=>$e.label===ae.label),be=xn.value.findIndex($e=>$e.label===j.label);return he-be})}})};a.onMounted(()=>{fa.value=window.innerWidth-240*2,window.addEventListener("keydown",Wo)});const Zc=()=>{a.nextTick(()=>{Xc()})},Zi=(d,h)=>{var O;if(!d&&!(d!=null&&d.children))return{contents:d,currentSelectContents:void 0};let z;return d.children=(O=d.children)==null?void 0:O.map(R=>{var D,Q;if((R==null?void 0:R.id)===Xe.value){let ae={};for(let j in R){let he=(D=h==null?void 0:h.find(be=>(be==null?void 0:be.prop)===j))==null?void 0:D.label;he?ae[j]=(Q=Il.value)==null?void 0:Q[he]:ae[j]=R[j]??""}R=Object.assign(ae,Il.value),z=R}else{let ae=Zi(R,h);R=ae==null?void 0:ae.contents,z=ae==null?void 0:ae.currentSelectContents}return R}),{contents:d,currentSelectContents:z}},Dt=(d,h)=>{let z,O;return d!=null&&d.find(R=>(R==null?void 0:R.id)===Xe.value)?z=d==null?void 0:d.map(R=>{var D,Q,ae;if((R==null?void 0:R.id)===Xe.value){let j={};for(let be in R){let $e=(D=h==null?void 0:h.find(ze=>(ze==null?void 0:ze.prop)===be))==null?void 0:D.label;$e?j[be]=((Q=Il.value)==null?void 0:Q[$e])??"":j[be]=R[be]??""}let he=Il.value;for(let be in j)(ae=Il.value)!=null&&ae[be]||(he[be]=(j==null?void 0:j[be])??"");R=he,O=R}return R}):z=d==null?void 0:d.map(R=>{var D,Q,ae,j;if((R==null?void 0:R.id)===Xe.value){let he={};for(let be in R){let $e=(D=h==null?void 0:h.find(ze=>(ze==null?void 0:ze.prop)===be))==null?void 0:D.label;$e?he[be]=(Q=Il.value)==null?void 0:Q[$e]:he[be]=R[be]??""}R=Object.assign(he,Il.value),O=R}else R=(ae=Zi(R,h))==null?void 0:ae.contents,O=(j=Zi(R,h))==null?void 0:j.currentSelectContents;return R}),{newContents:z,currentSelectContents:O}},Nt=(d,h,z)=>{var O,R;return d[h==null?void 0:h.prop]=z,typeof d.id=="number"&&(d.id=(O=d.id)==null?void 0:O.toString()),d.children&&((R=d.children)==null?void 0:R.length)>0&&(d.children=d.children.map(Nt)),d},Bt=d=>{var z;const h=[];return h.push({...d}),d!=null&&d.children&&Array.isArray(d.children)&&((z=d.children)==null||z.forEach(O=>{h.push(...Bt(O))})),(h==null?void 0:h.length)>0?h==null?void 0:h.map(O=>{const R={...O};return delete R.children,R}):[]},ni=["Pacific6000数据采集装置.通道号","通道号"],Oo=d=>{if(!d)return"";const h=ni.map(z=>d==null?void 0:d[z]).find(z=>z!=null&&String(z).trim()!=="");return h==null?"":String(h).trim()},Qi=async(d,h=void 0)=>{if(!d)return!1;try{const z=qe=>{var ia,ja,Aa;return qe?typeof(qe==null?void 0:qe.value)=="string"?qe.value:((Aa=(ja=(ia=qe==null?void 0:qe._custom)==null?void 0:ia.value)==null?void 0:ja.value)==null?void 0:Aa.value)||"":""},O=Array.isArray(mn.value)?mn.value:[],R=z(O.find(qe=>(qe==null?void 0:qe.condition)==="child")),D=(ka.value||"").replace(/\/+$/,""),Q=R?`${D}/${R}`:D,ae=await Vr(Q||ka.value,!1),j=String(ma.value||"").trim(),he=qe=>String(qe||"").trim(),be=(qe,ia=[],ja="")=>{if(!Array.isArray(qe))return ia;for(const Aa of qe){const na=he((Aa==null?void 0:Aa.choiceName)||(Aa==null?void 0:Aa.name0)||ja);(Aa==null?void 0:Aa.comp)==="Table"&&(!j||na===j)&&ia.push(Aa),Array.isArray(Aa==null?void 0:Aa.children)&&be(Aa.children,ia,na),Array.isArray(Aa==null?void 0:Aa.tab)&&be(Aa.tab,ia,na),Array.isArray(Aa==null?void 0:Aa.choice)&&be(Aa.choice,ia,na)}return ia},$e=be(ae||[]),ze=String((u==null?void 0:u.compName)||"");return $e.some(qe=>{var ja,Aa;const ia=((Aa=(ja=qe==null?void 0:qe.compData)==null?void 0:ja.find(na=>(na==null?void 0:na.key)==="tableContents"))==null?void 0:Aa.contents)||[];return!Array.isArray(ia)||ia.length===0?!1:ia.some(na=>{if(String((qe==null?void 0:qe.name)||"")===ze&&(na==null?void 0:na.id)===h)return!1;const sa=Oo(na);return!!sa&&sa===d})})}catch{return(_e.value||[]).some(O=>{if((O==null?void 0:O.id)===h)return!1;const R=Oo(O);return!!R&&R===d})}},Io=async(d=!0,h,z)=>{var he,be,$e,ze,qe,ia,ja,Aa,na,Xa,sa,Ua,te,Da,da,Ca,Ba,M,K,Ae,ta,ke,ua,za,dl,el,yl,gl,Vl,Za,kl;if(Il.value){const Ka=(be=ca.getColumnChild((he=I.cloneDeep(De.value))==null?void 0:he.filter(ll=>(ll==null?void 0:ll.label)!=="操作")))==null?void 0:be.filter(ll=>(ll==null?void 0:ll.required)===!0);for(let ll=0;ll<((Ka==null?void 0:Ka.length)??0);ll++){const vl=Ka[ll],Sl=vl==null?void 0:vl.prop,Tl=(vl==null?void 0:vl.label)??Sl,hr=($e=Il.value)==null?void 0:$e[Sl];if(hr===""||hr===null||hr===void 0||Array.isArray(hr)&&hr.length===0){rl.ElMessage.error(`${Tl}不能为空`);return}}const hl=Oo(Il.value);if(hl&&await Qi(hl,Xe.value||void 0)){rl.ElMessage.warning("当前任务下通道号不能重复,请重新选择");return}}let O=ca.getColumnChild((ze=I.cloneDeep(De.value))==null?void 0:ze.filter(Ka=>(Ka==null?void 0:Ka.label)!=="操作")),R,D=I.cloneDeep(_e.value);if(!Il.value){va.value=!1;return}if(Xe.value===""){Pe.value++;let Ka;Ka={id:Pe.value.toString()};try{Ka.sort=Bn(0,_e.value||[])}catch{}Ka!=null&&Ka.children&&(Ka={...Ka,children:(qe=Ka.children)==null?void 0:qe.map(ll=>Nt(ll,h,z))});const hl=Object.assign(Il.value,Ka);D.unshift(hl),R=hl}else D=(ia=Dt(D,O))==null?void 0:ia.newContents,R=(ja=Dt(D,O))==null?void 0:ja.currentSelectContents;const Q=(Aa=u.itemData)==null?void 0:Aa.filter(Ka=>(Ka==null?void 0:Ka.key)==="childTree")[0];if(((na=Q==null?void 0:Q.contents)==null?void 0:na.length)>0){Le.value="编辑";const Ka=[];D==null||D.forEach((vl,Sl)=>{var hr;let Tl={};if(Array.isArray(vl)){let Ll=[];vl==null||vl.filter(wl=>!(wl!=null&&wl.id)).forEach((wl,zl)=>{var Ul,Al,ur,dr,Gl,ir,$r;if((Al=(Ul=Nr.value)==null?void 0:Ul[zl])!=null&&Al.prop&&!Array.isArray(wl)){let tr={};tr[Nr.value[zl].column]=wl,Fa!=null&&Fa.value&&((ur=Fa==null?void 0:Fa.value)==null?void 0:ur.length)>0&&((dr=Fa==null?void 0:Fa.value)!=null&&dr.find(lr=>JSON.stringify(lr==null?void 0:lr[0])===JSON.stringify(tr)))&&(Ll=(Gl=Fa==null?void 0:Fa.value)==null?void 0:Gl.find(lr=>JSON.stringify(lr==null?void 0:lr[0])===JSON.stringify(tr))),Ll&&Ll.length>0?Tl[Nr.value[zl].prop]=Ll!=null&&Ll.find(lr=>{var nr;return((nr=Object.keys(lr))==null?void 0:nr[0])===Nr.value[zl].column})?(ir=Ll==null?void 0:Ll.find(lr=>{var nr;return((nr=Object.keys(lr))==null?void 0:nr[0])===Nr.value[zl].column}))==null?void 0:ir[Nr.value[zl].column]:wl:Tl[Nr.value[zl].prop]=wl}else Array.isArray(wl)&&(($r=Nr.value[zl])!=null&&$r.prop?Tl[Nr.value[zl].prop]=wl:Tl.children=dt(wl,Nr.value))})}else Tl=vl;if(Array.isArray(vl)&&vl.some(Ll=>Ll==null?void 0:Ll.id)){const Ll=(hr=vl==null?void 0:vl.find(wl=>wl.id))==null?void 0:hr.id;Ka.push(Object.assign(Tl,{id:Qo(Ll)}))}else Tl.id?Ka.push(Tl):Ka.push(Object.assign(Tl,{id:Sl.toString()}))});const hl=(_e.value||[]).map(vl=>String(vl==null?void 0:vl.id)),ll=ei(Ka,hl);_e.value=Mt(ll,Q,De.value)}At(_e.value),Br.value=_e.value;const ae=cf(Br.value,In.value,D);let j=[];if(P.value?(j=(Xa=I.cloneDeep(P).value.singleContent)==null?void 0:Xa.filter(Ka=>(Ka==null?void 0:Ka.id)!==(R==null?void 0:R.id)),j.push(R)):j=[R],Ml.value){const Ka={content:ae,singleContent:((sa=Q==null?void 0:Q.contents)==null?void 0:sa.length)>0?j==null?void 0:j.flatMap(Bt):j,index:u==null?void 0:u.index,buttonName:"编辑",column:De.value,parentTableId:u==null?void 0:u.parentTableId};Ge.setCacheUpdatingData(Ka)}if((Ua=De.value)==null||Ua.forEach(Ka=>{(Ka==null?void 0:Ka.formType)==="Upload"&&(R[Ka.prop]=R[Ka.prop]===""?"{}":typeof R[Ka.prop]!="string"?JSON.stringify(R[Ka.prop]):R[Ka.prop])}),d){(Ca=(da=(Da=(te=u.itemData)==null?void 0:te.find(ll=>(ll==null?void 0:ll.key)==="filterAllType"))==null?void 0:Da.value)==null?void 0:da.find(ll=>(ll==null?void 0:ll.value)==="onConditionContents"))==null||Ca.content;let Ka=(Ba=u.itemData)==null?void 0:Ba.filter(ll=>(ll==null?void 0:ll.key)==="filterAllType");Ka=Array.from(new Map(Ka.filter(Boolean).map((ll,vl)=>[ll.value,{...ll,_idx:vl}])).values()).sort((ll,vl)=>ll._idx-vl._idx).map(({_idx:ll,...vl})=>vl),Ka=(M=Ka==null?void 0:Ka[(Ka==null?void 0:Ka.length)-1])==null?void 0:M.value;const hl={fixContent:[R],buttonName:Le.value,relatedContents:u==null?void 0:u.related,columns:De.value,name:u==null?void 0:u.compName};Ge.setTableLoading(u==null?void 0:u.index),va.value=!1,Il.value=void 0,Ie("change",hl)}if((ta=(Ae=(K=$a.value)==null?void 0:K[0])==null?void 0:Ae.optionUrl)!=null&&ta.menuId){va.value=!1;let Ka=(ke=u.itemData)==null?void 0:ke.filter(hl=>(hl==null?void 0:hl.key)==="filterAllType");if((Ka==null?void 0:Ka.length)>0){let hl=Ka==null?void 0:Ka.map(Sl=>Sl==null?void 0:Sl.value),ll=(dl=(za=(ua=hl.flat().find(Sl=>{var Tl;return(Tl=Sl==null?void 0:Sl.content)==null?void 0:Tl.includes("@Num")}))==null?void 0:ua.content)==null?void 0:za.split(":"))==null?void 0:dl[1];((gl=(yl=(el=hl.flat().find(Sl=>{var Tl;return(Tl=Sl==null?void 0:Sl.content)==null?void 0:Tl.includes("@Type:")}))==null?void 0:el.content)==null?void 0:yl.split(":"))==null?void 0:gl[1])!=="Manual"&&(ll=parseInt(ll),_e.value=(kl=_e.value)==null?void 0:kl.slice(((Vl=_e.value)==null?void 0:Vl.length)-ll,(Za=_e.value)==null?void 0:Za.length))}}};a.onUnmounted(()=>{window.removeEventListener("keydown",Wo),De.value=[],_e.value=[],de.value=[],_a.value=[],Ye.value=[],Ma.value=[],Ya.value=[],ga.value=[],$a.value=[],ar.value=[],s.value=null,Sn.value=""});const oi=async(d,h,z)=>{var qe,ia,ja,Aa,na,Xa,sa,Ua,te,Da,da,Ca,Ba;Pl.value=(z==null?void 0:z.prop)??(z==null?void 0:z.property);const O=I.cloneDeep(u.itemData),R=((qe=O==null?void 0:O.find(M=>(M==null?void 0:M.key)==="header"))==null?void 0:qe.contents)??[];let D=R==null?void 0:R.find((M,K)=>{var Ae,ta,ke;return(M==null?void 0:M.prop)===Pl.value||(M==null?void 0:M.label)===Pl.value||(K==null?void 0:K.toString())===((ke=(ta=(Ae=Pl.value)==null?void 0:Ae.split("a"))==null?void 0:ta[1])==null?void 0:ke.toString())});const Q=ca.getColumnChild((ia=I.cloneDeep(De.value))==null?void 0:ia.filter(M=>(M==null?void 0:M.label)!=="操作"));if(D||(D=Q==null?void 0:Q.find(M=>(M==null?void 0:M.prop)===Pl.value||(M==null?void 0:M.label)===Pl.value)),D&&!((ja=D==null?void 0:D.menus)!=null&&ja.length)&&!((Aa=D==null?void 0:D.groups)!=null&&Aa.length)&&!((na=D==null?void 0:D.words)!=null&&na.length)){const M=(Xa=$a.value)==null?void 0:Xa.find(K=>(K==null?void 0:K.prop)===Pl.value);M&&(D={...D,menus:(M==null?void 0:M.menus)??(D==null?void 0:D.menus),groups:(M==null?void 0:M.groups)??(D==null?void 0:D.groups),words:(M==null?void 0:M.words)??(D==null?void 0:D.words),bindMenus:(M==null?void 0:M.bindMenus)??(D==null?void 0:D.bindMenus),isMainPath:(M==null?void 0:M.isMainPath)??(D==null?void 0:D.isMainPath),relatedContents:(M==null?void 0:M.relatedContents)??(D==null?void 0:D.relatedContents),endChildMenu:(M==null?void 0:M.endChildMenu)??(D==null?void 0:D.endChildMenu)})}if(D&&((sa=$a==null?void 0:$a.value)==null||sa.forEach(M=>{var K,Ae,ta,ke,ua;(M==null?void 0:M.prop)===(D==null?void 0:D.prop)&&(M!=null&&M.endChildMenu)&&((K=D==null?void 0:D.prop)!=null&&K.includes(".")&&((ta=(Ae=D==null?void 0:D.prop)==null?void 0:Ae.split("."))==null?void 0:ta[0])!==((ua=(ke=M==null?void 0:M.prop)==null?void 0:ke.split("."))==null?void 0:ua[0])?D.endChildMenu=M==null?void 0:M.value:D.endChildMenu=M==null?void 0:M.endChildMenu)})),!D)return;const ae=Pl.value,j=(Ua=_e.value)==null?void 0:Ua.findIndex(M=>(M==null?void 0:M.id)===(h==null?void 0:h.id));j!==-1&&ae&&(_e.value[j]={..._e.value[j],[ae]:d});const he=M=>{Array.isArray(M)&&M.forEach(K=>{Array.isArray(K==null?void 0:K.allSelectionContents)&&K.allSelectionContents.length>0&&(K.contactValue=_e.value[j]??h),Array.isArray(K==null?void 0:K.children)&&K.children.length>0&&he(K.children)})};he(De.value),D.value=d,D.endChildMenu=D.endChildMenu||"";let be=D!=null&&D.isMainPath&&(D!=null&&D.mainKey)?D==null?void 0:D.value:"";const $e=M=>{Array.isArray(M)&&M.forEach(K=>{var ta,ke;if(((K==null?void 0:K.type)==="Select"||(K==null?void 0:K.formType)&&K.formType.toUpperCase()==="SELECT"||(K==null?void 0:K.columnType)&&K.columnType.toUpperCase()==="SELECT")&&Array.isArray(K==null?void 0:K.menus)&&K.menus.length>0&&K.menus[K.menus.length-1]===""&&(D!=null&&D.isMainPath)&&(D!=null&&D.mainKey)){const ua=(ta=K==null?void 0:K.prop)!=null&&ta.includes(".")?K.prop.split(".")[0]:null,za=(ke=D==null?void 0:D.prop)!=null&&ke.includes(".")?D.prop.split(".")[0]:null;(!ua||!za||ua===za)&&(K.endChildMenu=be)}Array.isArray(K==null?void 0:K.children)&&K.children.length>0&&$e(K.children)})};if($e(De.value),!!(D!=null&&D.mainKey)&&Array.isArray(D==null?void 0:D.menus)&&(D==null?void 0:D.menus.length)>0&&(D!=null&&D.value)&&(D==null?void 0:D.value)!==""){let M=D!=null&&D.relatedContents&&((te=D==null?void 0:D.relatedContents)==null?void 0:te.length)>0?(Da=D==null?void 0:D.relatedContents)==null?void 0:Da.find(K=>{var Ae,ta,ke,ua;return(K==null?void 0:K[(ua=(Ae=D==null?void 0:D.prop)==null?void 0:Ae.split("."))==null?void 0:ua[((ke=(ta=D==null?void 0:D.prop)==null?void 0:ta.split("."))==null?void 0:ke.length)-1]])===(D==null?void 0:D.value)}):await rs(D);if(M){const K={...h};Q==null||Q.forEach(Ae=>{var ta,ke,ua,za,dl,el,yl,gl,Vl,Za,kl,Ka,hl,ll,vl,Sl;(Ae==null?void 0:Ae.prop)!==(D==null?void 0:D.prop)&&(D!=null&&D.relatedContents&&((ta=D==null?void 0:D.relatedContents)==null?void 0:ta.length)>0?(ke=Ae==null?void 0:Ae.prop)!=null&&ke.includes(".")&&((za=(ua=Ae==null?void 0:Ae.prop)==null?void 0:ua.split("."))==null?void 0:za[0])===((el=(dl=D==null?void 0:D.prop)==null?void 0:dl.split("."))==null?void 0:el[0])?K[Ae.prop]=M[(Za=(yl=Ae==null?void 0:Ae.prop)==null?void 0:yl.split("."))==null?void 0:Za[((Vl=(gl=Ae==null?void 0:Ae.prop)==null?void 0:gl.split("."))==null?void 0:Vl.length)-1]]??K[Ae.prop]:K[Ae.prop]=(M==null?void 0:M[Ae.prop])??K[Ae.prop]:Pa.same((D==null?void 0:D.menus)??[],(Ae==null?void 0:Ae.menus)??[])&&Pa.same((D==null?void 0:D.groups)??[],(Ae==null?void 0:Ae.groups)??[])&&!Pa.same((D==null?void 0:D.words)??[],(Ae==null?void 0:Ae.words)??[])?(kl=Ae==null?void 0:Ae.prop)!=null&&kl.includes(".")&&((hl=(Ka=Ae==null?void 0:Ae.prop)==null?void 0:Ka.split("."))==null?void 0:hl[0])!==((vl=(ll=D==null?void 0:D.prop)==null?void 0:ll.split("."))==null?void 0:vl[0])||(K[Ae.prop]=(M==null?void 0:M[(Sl=Ae==null?void 0:Ae.words)==null?void 0:Sl.join(".")])??(M==null?void 0:M[Ae.prop])??K[Ae.prop]):(!(Ae!=null&&Ae.isMainPath)&&Pa.same((D==null?void 0:D.bindMenus)??[],(Ae==null?void 0:Ae.bindMenus)??[]),K[Ae.prop]=(M==null?void 0:M[Ae.prop])??K[Ae.prop]))}),_e.value=(da=I.cloneDeep(_e.value))==null?void 0:da.map(Ae=>(Ae==null?void 0:Ae.id)===(h==null?void 0:h.id)?{...K,id:Ae==null?void 0:Ae.id}:Ae)}}if((Ca=D==null?void 0:D.optionUrl)!=null&&Ca.menuSelect){let M="";Q==null||Q.forEach(ta=>{var ke,ua,za,dl,el;M===""&&((za=(ua=(ke=ta==null?void 0:ta.optionUrl)==null?void 0:ke.groupSelect)==null?void 0:ua[1])!=null&&za.includes("["))&&(M=(el=(dl=ta==null?void 0:ta.optionUrl)==null?void 0:dl.groupSelect)==null?void 0:el[1])});let K=await pt(D),Ae;if(K==null||K.forEach(ta=>{var ke,ua,za,dl,el,yl,gl,Vl,Za,kl;M===((ua=(ke=D==null?void 0:D.optionUrl)==null?void 0:ke.groupSelect)==null?void 0:ua[1])&&((el=(dl=(za=D==null?void 0:D.optionUrl)==null?void 0:za.groupSelect)==null?void 0:dl[1])!=null&&el.includes("["))&&((kl=I.cloneDeep(ta))==null?void 0:kl[(Za=(Vl=(gl=(yl=D==null?void 0:D.optionUrl)==null?void 0:yl.groupSelect)==null?void 0:gl[1])==null?void 0:Vl.replaceAll("[",""))==null?void 0:Za.replaceAll("]","")])===(D==null?void 0:D.value)&&(Ae=ta)}),Ae){const ta={...h};Q==null||Q.forEach(ke=>{var ua,za,dl,el,yl,gl,Vl,Za,kl,Ka,hl;(Ae!=null&&Ae[ke==null?void 0:ke.label]||Ae!=null&&Ae[(el=(dl=(za=(ua=ke==null?void 0:ke.optionUrl)==null?void 0:ua.groupSelect)==null?void 0:za[1])==null?void 0:dl.replaceAll("[",""))==null?void 0:el.replaceAll("]","")])&&((Vl=(gl=(yl=ke==null?void 0:ke.optionUrl)==null?void 0:yl.groupSelect)==null?void 0:gl[1])!=null&&Vl.includes("["))&&(ta[ke.prop]=(Ae==null?void 0:Ae[ke==null?void 0:ke.label])||(Ae==null?void 0:Ae[(hl=(Ka=(kl=(Za=ke==null?void 0:ke.optionUrl)==null?void 0:Za.groupSelect)==null?void 0:kl[1])==null?void 0:Ka.replaceAll("[",""))==null?void 0:hl.replaceAll("]","")]))}),_e.value=(Ba=I.cloneDeep(_e.value))==null?void 0:Ba.map(ke=>(ke==null?void 0:ke.id)===(h==null?void 0:h.id)?{...ta,id:ke==null?void 0:ke.id}:ke)}}},Qc=async d=>{var qe,ia,ja,Aa,na,Xa,sa,Ua,te,Da,da,Ca,Ba,M;if(!d)return;const h=I.cloneDeep(Il.value||{});Il.value=d;const z=Oo(h),O=Oo(Il.value);if(O&&O!==z&&await Qi(O,Xe.value||void 0)){rl.ElMessage.warning("当前任务下通道号不能重复,请重新选择"),ni.forEach(Ae=>{if(Object.prototype.hasOwnProperty.call(Il.value||{},Ae)||Object.prototype.hasOwnProperty.call(h||{},Ae)){const ta=(h==null?void 0:h[Ae])??"";Il.value[Ae]=ta,d[Ae]=ta}}),$a.value=($a.value||[]).map(Ae=>{if(!(Ae!=null&&Ae.prop)||!ni.includes(Ae.prop))return Ae;const ta=(h==null?void 0:h[Ae.prop])??"";return{...Ae,value:ta,selectValue:ta===""?[]:[ta]}});return}let R=I.cloneDeep(u.itemData);R==null||R.map(K=>{var Ae,ta,ke,ua;return(K==null?void 0:K.key)==="header"&&(Array.isArray((Ae=K.contents)==null?void 0:Ae[0])?K.contents=(ke=ca.getColumnChild((ta=K.contents)==null?void 0:ta[0]))==null?void 0:ke.map((za,dl)=>{var el,yl,gl,Vl,Za,kl;return((gl=(yl=(el=$a.value)==null?void 0:el.find(Ka=>(Ka==null?void 0:Ka.prop)===(za==null?void 0:za.prop)))==null?void 0:yl.optionUrl)==null?void 0:gl.multiple)===!0&&!Array.isArray((Vl=Object.values(d))==null?void 0:Vl[dl])?za.value=[(Za=Object.values(d))==null?void 0:Za[dl]]:za.value=(kl=Object.values(d))==null?void 0:kl[dl],za}):K.contents=(ua=K.contents)==null?void 0:ua.map((za,dl)=>{var el,yl,gl,Vl,Za,kl;return((gl=(yl=(el=$a.value)==null?void 0:el.find(Ka=>(Ka==null?void 0:Ka.prop)===(za==null?void 0:za.prop)))==null?void 0:yl.optionUrl)==null?void 0:gl.multiple)===!0&&!Array.isArray((Vl=Object.values(d))==null?void 0:Vl[dl])?za.value=[(Za=Object.values(d))==null?void 0:Za[dl]]:za.value=(kl=Object.values(d))==null?void 0:kl[dl],za})),K});let D=$a.value,Q=(qe=R==null?void 0:R.find(K=>(K==null?void 0:K.key)==="header"))==null?void 0:qe.contents;if(Pl.value||(D=D==null?void 0:D.map(K=>{var Ae;return K.value=K.value??((Ae=Q==null?void 0:Q.find((ta,ke)=>(ta==null?void 0:ta.prop)===(K==null?void 0:K.name)))==null?void 0:Ae.value),K})),!zr.value)return;let ae=I.cloneDeep(Pl.value);(ia=Pl.value)!=null&&ia.includes("·")&&(Pl.value=(Aa=(ja=Pl.value)==null?void 0:ja.split("·"))==null?void 0:Aa[0]);let j=(Xa=(na=R==null?void 0:R.find(K=>(K==null?void 0:K.key)==="header"))==null?void 0:na.contents)==null?void 0:Xa.find((K,Ae)=>(K==null?void 0:K.prop)===Pl.value);(sa=$a==null?void 0:$a.value)==null||sa.forEach(K=>{var Ae,ta,ke,ua,za,dl,el,yl,gl;(K==null?void 0:K.prop)===(j==null?void 0:j.prop)&&(K!=null&&K.endChildMenu)&&((Ae=j==null?void 0:j.prop)!=null&&Ae.includes(".")&&((ke=(ta=j==null?void 0:j.prop)==null?void 0:ta.split("."))==null?void 0:ke[0])!==((za=(ua=K==null?void 0:K.prop)==null?void 0:ua.split("."))==null?void 0:za[0])?j.endChildMenu=(el=(dl=K==null?void 0:K.value)==null?void 0:dl.split(" "))==null?void 0:el[0]:j.endChildMenu=(gl=(yl=K==null?void 0:K.endChildMenu)==null?void 0:yl.split(" "))==null?void 0:gl[0])});let he=j!=null&&j.isMainPath&&(j!=null&&j.mainKey)?j==null?void 0:j.value:"",be=D,$e=ge.value;if($e!=null&&$e.find(K=>(j==null?void 0:j.prop)===(K==null?void 0:K.key))&&($e=$e==null?void 0:$e.filter(K=>(j==null?void 0:j.prop)!==(K==null?void 0:K.key))),$e!=null&&$e.find(K=>ae===(K==null?void 0:K.key))&&($e=$e==null?void 0:$e.filter(K=>ae!==(K==null?void 0:K.key))),(j==null?void 0:j.formType)==="Select"&&(be=be==null?void 0:be.map(K=>{var Ae,ta,ke,ua,za,dl,el,yl,gl,Vl,Za,kl,Ka,hl,ll,vl;return(K==null?void 0:K.type)==="Select"&&(((Ae=K==null?void 0:K.allSelectionContents)==null?void 0:Ae.length)>0&&(K.contactValue=d),((j==null?void 0:j.prop)===(K==null?void 0:K.prop)||ae===(K==null?void 0:K.prop))&&j&&(Array.isArray(j.value)&&((ta=j.value)==null?void 0:ta.length)>0&&((ke=j.value)!=null&&ke.every(Sl=>typeof Sl=="string"))?($e.push({key:K==null?void 0:K.prop,value:[(za=j.value)==null?void 0:za[((ua=j.value)==null?void 0:ua.length)-1]]}),K.selectValue=(dl=$e==null?void 0:$e.find(Sl=>(Sl==null?void 0:Sl.key)===(K==null?void 0:K.prop)))==null?void 0:dl.value):Array.isArray(j.value)&&((el=j.value)==null?void 0:el.length)===0?($e=[],K.selectValue=[],d[K==null?void 0:K.prop]=""):Array.isArray(K.value)&&$e.push({key:K==null?void 0:K.prop,value:[(yl=K.value)==null?void 0:yl[(K==null?void 0:K.length)-1]]})),((Vl=K==null?void 0:K.menus)==null?void 0:Vl[((gl=K==null?void 0:K.menus)==null?void 0:gl.length)-1])===""&&(j!=null&&j.isMainPath)&&(j!=null&&j.mainKey)&&((Za=K==null?void 0:K.prop)!=null&&Za.includes(".")&&((Ka=(kl=K==null?void 0:K.prop)==null?void 0:kl.split("."))==null?void 0:Ka[0])!==((ll=(hl=j==null?void 0:j.prop)==null?void 0:hl.split("."))==null?void 0:ll[0])||(K.endChildMenu=(vl=he==null?void 0:he.split(" "))==null?void 0:vl[0]))),K.value=(d==null?void 0:d[K==null?void 0:K.prop])??(K==null?void 0:K.value),K})),ge.value=$e,be!=null&&be.some(K=>(K==null?void 0:K.functionName)&&(K==null?void 0:K.functionName)!=="")){let K=await ut([d],De==null?void 0:De.value,"Auto",_e.value),Ae=[];(Ua=be==null?void 0:be.filter(ke=>(ke==null?void 0:ke.functionName)&&(ke==null?void 0:ke.functionName)!==""))==null||Ua.forEach(ke=>{var ua;((ua=ke==null?void 0:ke.functionRelatedWords)==null?void 0:ua.length)>0&&(Ae=[...Ae,...ke==null?void 0:ke.functionRelatedWords])}),Ae=Ae==null?void 0:Ae.filter(ke=>(ke==null?void 0:ke[0])!=="@");let ta=[];for(let ke in K==null?void 0:K[0])Ae!=null&&Ae.find(ua=>ke===ua||(ke==null?void 0:ke.includes("."+ua)))&&ta.push(((te=K==null?void 0:K[0])==null?void 0:te[ke])!=="");(K==null?void 0:K.length)>0&&ta.every(ke=>ke)&&(be=be==null?void 0:be.map(ke=>{var ua;return ke.value=((ua=K==null?void 0:K[0])==null?void 0:ua[ke==null?void 0:ke.prop])??ke.value,ke})),Il.value=K==null?void 0:K[0]}if($a.value=be,j=Object.assign({},j??{},{relatedWords:(da=(Da=$a==null?void 0:$a.value)==null?void 0:Da.find(K=>(K==null?void 0:K.prop)===(j==null?void 0:j.prop)))==null?void 0:da.relatedWords}),(j==null?void 0:j.mainKey)&&(j!=null&&j.value)&&(j==null?void 0:j.value)!==""){let K=j!=null&&j.relatedContents&&((Ca=j==null?void 0:j.relatedContents)==null?void 0:Ca.length)>0?(Ba=j==null?void 0:j.relatedContents)==null?void 0:Ba.find(Ae=>{var ta,ke,ua,za;return(Ae==null?void 0:Ae[(za=(ta=j==null?void 0:j.prop)==null?void 0:ta.split("."))==null?void 0:za[((ua=(ke=j==null?void 0:j.prop)==null?void 0:ke.split("."))==null?void 0:ua.length)-1]])===(j==null?void 0:j.value)}):await rs(j);if(K&&JSON.stringify(K)!=="{}"){let Ae=be;Ae=Ae==null?void 0:Ae.map(ke=>{var ua,za,dl,el,yl,gl,Vl,Za,kl,Ka,hl,ll,vl,Sl,Tl,hr,Ll,wl,zl,Ul,Al;return(j==null?void 0:j.prop)===(ke==null?void 0:ke.prop)?ke.value=(K==null?void 0:K[(ua=ke==null?void 0:ke.words)==null?void 0:ua.join(".")])??(K==null?void 0:K[ke==null?void 0:ke.prop])??K[(yl=(za=ke==null?void 0:ke.prop)==null?void 0:za.split("."))==null?void 0:yl[((el=(dl=ke==null?void 0:ke.prop)==null?void 0:dl.split("."))==null?void 0:el.length)-1]]:j!=null&&j.relatedContents&&((gl=j==null?void 0:j.relatedContents)==null?void 0:gl.length)>0?ke.value=(Vl=ke==null?void 0:ke.prop)!=null&&Vl.includes(".")&&((kl=(Za=ke==null?void 0:ke.prop)==null?void 0:Za.split("."))==null?void 0:kl[0])===((hl=(Ka=j==null?void 0:j.prop)==null?void 0:Ka.split("."))==null?void 0:hl[0])?K[(Tl=(ll=ke==null?void 0:ke.prop)==null?void 0:ll.split("."))==null?void 0:Tl[((Sl=(vl=ke==null?void 0:ke.prop)==null?void 0:vl.split("."))==null?void 0:Sl.length)-1]]:(K==null?void 0:K[ke==null?void 0:ke.prop])??(ke==null?void 0:ke.value):Pa.same((j==null?void 0:j.menus)??[],(ke==null?void 0:ke.menus)??[])&&Pa.same((j==null?void 0:j.groups)??[],(ke==null?void 0:ke.groups)??[])&&!Pa.same((j==null?void 0:j.words)??[],(ke==null?void 0:ke.words)??[])?(hr=ke==null?void 0:ke.prop)!=null&&hr.includes(".")&&((wl=(Ll=ke==null?void 0:ke.prop)==null?void 0:Ll.split("."))==null?void 0:wl[0])!==((Ul=(zl=j==null?void 0:j.prop)==null?void 0:zl.split("."))==null?void 0:Ul[0])||(ke.value=(K==null?void 0:K[(Al=ke==null?void 0:ke.words)==null?void 0:Al.join(".")])??(K==null?void 0:K[ke==null?void 0:ke.prop])??ke.value):(!(ke!=null&&ke.isMainPath)&&Pa.same((j==null?void 0:j.bindMenus)??[],(ke==null?void 0:ke.bindMenus)??[]),ke.value=(K==null?void 0:K[ke==null?void 0:ke.prop])??ke.value),ke}),$a.value=Ae;let ta={};(M=$a.value)==null||M.forEach(ke=>{ta[ke.prop]=ke==null?void 0:ke.value}),Il.value=ta}}zr.value=!0,V.value=!1},eu=d=>d?(d==null?void 0:d.toUpperCase())==="INPUT"?"TEXTAREA":d:"TEXTAREA",au=d=>{var D,Q;const h=(Q=(D=Ye.value)==null?void 0:D.find(ae=>(ae==null?void 0:ae.label)===(d==null?void 0:d.label)))==null?void 0:Q.multiple,z=d==null?void 0:d.prop;if((d==null?void 0:d.formType)!="Select")return;_e.value.forEach(ae=>{const j=ae==null?void 0:ae[z];h&&ki.isString(j)&&(ae[z]=[j]),!h&&!ki.isString(j)&&(ae[z]="")})},Tt=(d,h)=>{var z;return h==null||h.forEach(O=>{d[O==null?void 0:O.prop]=O==null?void 0:O.value}),d.children&&((z=d.children)==null?void 0:z.length)>0&&(d.children=d.children.map(O=>Tt(O,h))),d},et=d=>{var z,O,R,D,Q,ae;Mo("");const h=(z=$a.value)==null?void 0:z.reduce((j,he)=>(j[he.name]=he.value,j),{});if(((O=Object.keys(h))==null?void 0:O.length)>0){Il.value=h,Xe.value="",Pe.value=(R=_e.value)==null?void 0:R.length,ga.value=(D=ba.value)==null?void 0:D.filter(he=>(he==null?void 0:he.label)!=="新增");const j=(ae=(Q=de.value)==null?void 0:Q.filter(he=>(he==null?void 0:he.label)!=="操作"))==null?void 0:ae.map(he=>{var $e,ze,qe;const be=(ze=($e=Ye.value)==null?void 0:$e.find(ia=>(ia==null?void 0:ia.label)===(he==null?void 0:he.label)))==null?void 0:ze.multiple;return au(he),{...he,contents:(he==null?void 0:he.options)??[],optionUrl:he!=null&&he.formMenuSelect&&((qe=he==null?void 0:he.formMenuSelect)==null?void 0:qe.length)>0?{groupSelect:he==null?void 0:he.groupSelect,menuSelect:he==null?void 0:he.formMenuSelect,selectRelateType:"",type:he==null?void 0:he.formType,multiple:be}:null}});De.value=j==null?void 0:j.map(he=>Tt(he,[{prop:"type",value:"edit"},{prop:"columnType",value:eu(he==null?void 0:he.formType)||(he==null?void 0:he.columnType)}])),d==="createClick"&&(Le.value="新增",Io(!0))}},po={START:"开始时间",END:"结束时间",HOURS:"工时"},lu=(d,h)=>Number(I.dayjs(h).diff(I.dayjs(d),"day",!0).toFixed(1)),At=d=>{var D;const h=u.itemData,z=(D=h==null?void 0:h.find(Q=>(Q==null?void 0:Q.key)==="header"))==null?void 0:D.contents,O=new Map;return z==null||z.forEach((Q,ae)=>{const{label:j}=Q;O.set(j,ae)}),!O.has(po.START)||!O.has(po.END)||!O.has(po.HOURS)?d:d==null?void 0:d.map(Q=>{const ae=Q==null?void 0:Q[po.START],j=Q==null?void 0:Q[po.END],he=lu(ae,j);return ae&&j&&(Q[po.HOURS]=`${he}天`),Q})},zt=(d,h,z=0)=>{if(z>((h==null?void 0:h.length)??""))return d;const O=h==null?void 0:h[z],R=new Map;for(const Q of d){const ae=Q[O];R.has(ae)||R.set(ae,[]),R.get(ae)&&R.get(ae).push(Q)}const D=[];for(const[Q,ae]of R){const[j,...he]=ae,be={...j};z+1===((h==null?void 0:h.length)??"")?be.children=ae==null?void 0:ae.map($e=>($e.level=I.cloneDeep(z)+1,$e)).filter(($e,ze)=>ze!==0):he.length>0&&(be.children=zt(he,h,z+1)),be.level=z,D.push(be)}return D},Mt=(d,h,z)=>{var R;if(!(h!=null&&h.contents)||((R=h==null?void 0:h.contents)==null?void 0:R.length)===0)return d;let O=[];return O=zt(d,h==null?void 0:h.contents,0),O},Ot=async(d,h)=>{var Aa,na,Xa,sa,Ua,te,Da,da,Ca,Ba,M,K,Ae,ta,ke,ua,za,dl,el,yl,gl,Vl,Za,kl,Ka,hl,ll,vl,Sl,Tl,hr,Ll,wl,zl,Ul,Al,ur,dr,Gl,ir,$r,tr,lr,nr,Lt,$t,Rt;const z=d==null?void 0:d.filter(ha=>(ha==null?void 0:ha.key)==="header");d==null||d.filter(ha=>(ha==null?void 0:ha.key)==="tableIndexColumn")[0];const O=d==null?void 0:d.filter(ha=>(ha==null?void 0:ha.key)==="childTree")[0];let R=!0;if((Xa=(na=(Aa=d==null?void 0:d.find(ha=>(ha==null?void 0:ha.key)==="filterAllType"))==null?void 0:Aa.value)==null?void 0:na.find(ha=>(ha==null?void 0:ha.value)==="onPamButtonContents"))!=null&&Xa.content){let ha=(te=(Ua=(sa=d==null?void 0:d.find(Dl=>(Dl==null?void 0:Dl.key)==="filterAllType"))==null?void 0:sa.value)==null?void 0:Ua.find(Dl=>(Dl==null?void 0:Dl.value)==="onPamButtonContents"))==null?void 0:te.content;ha=(Da=ha==null?void 0:ha.split(":"))==null?void 0:Da[1],ha=(da=ha.slice(1,(ha==null?void 0:ha.length)-1))==null?void 0:da.split(","),R=!!(ha!=null&&ha.find(Dl=>Dl==="操作"))}const D=d==null?void 0:d.find(ha=>(ha==null?void 0:ha.key)==="page"),Q=d==null?void 0:d.find(ha=>(ha==null?void 0:ha.key)==="rowButton"),ae=d==null?void 0:d.find(ha=>(ha==null?void 0:ha.key)==="extraButton"),j=d==null?void 0:d.filter(ha=>(ha==null?void 0:ha.key)==="tableContents"),he=d==null?void 0:d.filter(ha=>(ha==null?void 0:ha.key)==="bottomButton"),be=d==null?void 0:d.filter(ha=>(ha==null?void 0:ha.key)==="tableIndex");Ye.value=(Ba=(Ca=d==null?void 0:d.filter(ha=>(ha==null?void 0:ha.key)==="tableToForm"))==null?void 0:Ca[0])==null?void 0:Ba.contents,xa.value=(D==null?void 0:D.contents)??!0;let $e=[];Xl.value===""?$e=z==null?void 0:z[0]:$e=(z==null?void 0:z.find(ha=>(ha==null?void 0:ha.selectLabel)==="("+Xl.value+")"))??(z==null?void 0:z.find(ha=>!(ha!=null&&ha.selectLabel)));let ze=[];Xl.value===""?ze=be==null?void 0:be[0]:ze=(be==null?void 0:be.find(ha=>(ha==null?void 0:ha.selectLabel)==="("+Xl.value+")"))??(be==null?void 0:be.find(ha=>!(ha!=null&&ha.selectLabel)));let qe=[],ia=[];if(((M=$e==null?void 0:$e.contents)==null?void 0:M.length)>0){let ha=[],Dl=$e==null?void 0:$e.contents;if(Array.isArray(Dl==null?void 0:Dl[0])&&((K=Dl==null?void 0:Dl[0])!=null&&K.every(nl=>!(nl!=null&&nl.children)))&&(Dl=Dl==null?void 0:Dl[0]),Dl.some(nl=>Array.isArray(nl)&&(nl==null?void 0:nl.find(We=>We.children))))ha=(Ae=ca.getGradeColumns(Dl,R))==null?void 0:Ae[0],ha!=null&&ha.find(nl=>(nl==null?void 0:nl.label)==="操作")||ha.push({label:"操作",prop:"operate",type:"operate"});else{let nl=Dl.some(We=>Array.isArray(We))?Dl==null?void 0:Dl[0]:Dl;nl!=null&&nl.find(We=>(We==null?void 0:We.label)==="操作")||nl.push({label:"操作",prop:"operate",type:"operate"}),nl==null||nl.forEach((We,Jl)=>{var Tr,Cr,Ar,br,Qn,vo,mo,pr,hn,Fn,yo,Gr,jn,jt,Ht,Ut,qt,Wt,Kt,Yt;if((Cr=(Tr=ka.value)==null?void 0:Tr.split("/"))==null||Cr.forEach(Zl=>{var sr,Cn,Gt;Zl!==""&&((Gt=(Cn=(sr=Zl==null?void 0:Zl.split(k+"updateLoading"))==null?void 0:sr[0])==null?void 0:Cn.split(k+"loading"))==null||Gt[0])}),We!=null&&We.methodContent){let Zl=(Qn=(br=(Ar=We==null?void 0:We.methodContent)==null?void 0:Ar.replace("@","%%#"))==null?void 0:br.split("%%#"))==null?void 0:Qn[1];if(Zl=Zl==null?void 0:Zl.slice(0,(Zl==null?void 0:Zl.length)-1),Zl=ca.contentTransArrayToAllNoExtra(Zl??"",","),(vo=Zl==null?void 0:Zl.find(sr=>sr==null?void 0:sr.includes("@Button")))!=null&&vo.includes("Prop")&&((mo=Zl==null?void 0:Zl.find(sr=>sr==null?void 0:sr.includes("Type")))!=null&&mo.includes("Manual"))){let sr=(hn=(pr=Zl==null?void 0:Zl.find(Cn=>Cn==null?void 0:Cn.includes("@Button")))==null?void 0:pr.split(":"))==null?void 0:hn[1];sr=((Gr=(yo=(Fn=sr==null?void 0:sr.replaceAll("[",""))==null?void 0:Fn.replaceAll("]",""))==null?void 0:yo.split(","))==null?void 0:Gr[1])??"算法执行",qe.push(sr)}else if((jn=Zl==null?void 0:Zl.find(sr=>sr==null?void 0:sr.includes("@Button")))!=null&&jn.includes("Row")&&((jt=Zl==null?void 0:Zl.find(sr=>sr==null?void 0:sr.includes("Type")))!=null&&jt.includes("Manual"))){let sr=(Ut=(Ht=Zl==null?void 0:Zl.find(Cn=>Cn==null?void 0:Cn.includes("@Button")))==null?void 0:Ht.split(":"))==null?void 0:Ut[1];sr=((Kt=(Wt=(qt=sr==null?void 0:sr.replaceAll("[",""))==null?void 0:qt.replaceAll("]",""))==null?void 0:Wt.split(","))==null?void 0:Kt[1])??"算法执行",ia.push(sr)}}(Yt=Ye.value)==null||Yt.find(Zl=>(Zl==null?void 0:Zl.prop)===(We==null?void 0:We.prop)),ha.push({label:(We==null?void 0:We.label)==="操作"?R?"操作":"":(We==null?void 0:We.label)??"",prop:(We==null?void 0:We.label)==="操作"?"operate":(We==null?void 0:We.prop)??"a"+Jl,width:We!=null&&We.width?parseInt(We.width):"",fixed:(We==null?void 0:We.fixed)??void 0,sortable:(We==null?void 0:We.sortable)??!1,filterable:(We==null?void 0:We.filterable)??!1,operable:(We==null?void 0:We.operable)??!1,showSummary:(We==null?void 0:We.showSummary)??!1,align:(We==null?void 0:We.align)??"left",showOverflowTooltip:(We==null?void 0:We.showOverflowTooltip)??!0,isNotDrag:(We==null?void 0:We.isNotDrag)??!1,isEditCol:(We==null?void 0:We.isEditCol)??!1,isOperate:(We==null?void 0:We.isOperate)??!1,id:(We==null?void 0:We.id)??Jl,type:(We==null?void 0:We.label)==="操作"?"operate":void 0,formType:(We==null?void 0:We.formType)??(We!=null&&We.groupSelect?"Select":""),disabled:We==null?void 0:We.disabled,options:(We==null?void 0:We.options)??[],value:(We==null?void 0:We.value)??"",isExistChild:(We==null?void 0:We.isExistChild)??!1,mainKey:(We==null?void 0:We.mainKey)??Jl===0,allSelectionContents:(We==null?void 0:We.allContents)??[],filterContent:We==null?void 0:We.filterContents,menus:We==null?void 0:We.menus,groups:We==null?void 0:We.groups,words:We==null?void 0:We.words,filter:We==null?void 0:We.filter,bindMenus:We==null?void 0:We.bindMenus,fatherPath:We==null?void 0:We.fatherPath,isMainPath:We==null?void 0:We.isMainPath,required:(We==null?void 0:We.required)??!1,relatedContents:We==null?void 0:We.relatedContents,functionName:We==null?void 0:We.functionName,functionRelatedWords:We==null?void 0:We.functionRelatedWords,calculatorFilter:We==null?void 0:We.calculatorFilter,relatedPages:We==null?void 0:We.relatedPages})})}A.value=(ta=he==null?void 0:he[0])==null?void 0:ta.contents;const an=ca.getNewColumnChild(ha),Vt=nl=>Array.isArray(nl)?nl.map(We=>(Array.isArray(We==null?void 0:We.children)&&We.children.length>0?(We.sortable=!1,Vt(We.children)):(We==null?void 0:We.prop)==="operate"||(We==null?void 0:We.label)==="操作"||(We==null?void 0:We.type)==="operate"||(We.sortable=!1),We)):nl;Vt(an),await Vi(an),Af(ne.value,an),De.value=an,_a.value=an,n.value=(ke=De.value)==null?void 0:ke.map(nl=>nl==null?void 0:nl.label);let ln=(za=(ua=ca.getAllLeafNodes(De.value))==null?void 0:ua.filter(nl=>(nl==null?void 0:nl.type)!=="operate"))==null?void 0:za.map((nl,We)=>({prop:(nl==null?void 0:nl.prop)??"a"+We,column:nl.label}));Nr.value=ln;let Yr=[];Xl.value===""?Yr=j==null?void 0:j[0]:Yr=(j==null?void 0:j.find(nl=>(nl==null?void 0:nl.selectLabel)==="("+Xl.value+")"))??(j==null?void 0:j.find(nl=>!(nl!=null&&nl.selectLabel)));let Zn=Array.isArray((dl=Yr==null?void 0:Yr.contents)==null?void 0:dl[0])&&((el=Yr==null?void 0:Yr.contents)!=null&&el[0].every(nl=>Array.isArray(nl)))?(yl=Yr==null?void 0:Yr.contents)==null?void 0:yl[0]:Yr==null?void 0:Yr.contents;ze!=null&&ze.contents&&((gl=ze==null?void 0:ze.contents)==null?void 0:gl.length)!==0&&(Zn=(Vl=I.cloneDeep(Zn))==null?void 0:Vl.map((nl,We)=>{if(!Array.isArray(nl)){let Jl={};for(let Tr in nl)Tr!=="id"&&Tr!=="index"&&(Jl[Tr]=nl[Tr]);nl=Object.values(Jl)}return nl}));const vu=!!((Za=De.value)!=null&&Za.find(nl=>nl.prop==="index"));Zn=Qs(Zn,ze==null?void 0:ze.contents,vu);const fo=[];Zn==null||Zn.forEach((nl,We)=>{var Tr;let Jl={};if(Array.isArray(nl)){let Cr=[];nl==null||nl.filter(Ar=>!(Ar!=null&&Ar.id)).forEach((Ar,br)=>{var Qn,vo,mo,pr,hn,Fn;if((Qn=ln==null?void 0:ln[br])!=null&&Qn.prop&&!Array.isArray(Ar)){let yo={};yo[ln[br].column]=Ar,Fa!=null&&Fa.value&&((vo=Fa==null?void 0:Fa.value)==null?void 0:vo.length)>0&&((mo=Fa==null?void 0:Fa.value)!=null&&mo.find(Gr=>JSON.stringify(Gr==null?void 0:Gr[0])===JSON.stringify(yo)))&&(Cr=(pr=Fa==null?void 0:Fa.value)==null?void 0:pr.find(Gr=>JSON.stringify(Gr==null?void 0:Gr[0])===JSON.stringify(yo))),Cr&&Cr.length>0?Jl[ln[br].prop]=Cr!=null&&Cr.find(Gr=>{var jn;return((jn=Object.keys(Gr))==null?void 0:jn[0])===ln[br].column})?(hn=Cr==null?void 0:Cr.find(Gr=>{var jn;return((jn=Object.keys(Gr))==null?void 0:jn[0])===ln[br].column}))==null?void 0:hn[ln[br].column]:Ar:Jl[ln[br].prop]=Ar}else Array.isArray(Ar)&&((Fn=ln[br])!=null&&Fn.prop?Jl[ln[br].prop]=Ar:Jl.children=dt(Ar,ln))})}else Jl=nl;if(Array.isArray(nl)&&nl.some(Cr=>Cr==null?void 0:Cr.id)){const Cr=(Tr=nl==null?void 0:nl.find(Ar=>Ar.id))==null?void 0:Tr.id;fo.push(Object.assign(Jl,{id:Qo(Cr)}))}else Jl.id?fo.push(Jl):fo.push(Object.assign(Jl,{id:We.toString()}))});try{const nl=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),We=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null"),Jl=nl==null?void 0:nl.tableId,Tr=nl==null?void 0:nl.compIndex;if(Jl&&Array.isArray(We)&&We.length>0&&String(Jl)===String(u==null?void 0:u.parentTableId)&&String(Tr)===String(u==null?void 0:u.index)){const Cr=new Set(fo.map(br=>String(br==null?void 0:br.id))),Ar=We.filter(br=>!Cr.has(String(br)));if(Ar.length>0){const br=nl==null?void 0:nl.pageKey,Qn=br!=null&&br.startsWith("/")?br.substring(1):br;((h==null?void 0:h[br])||(h==null?void 0:h[Qn])||[]).filter(pr=>{var hn,Fn;return((hn=pr==null?void 0:pr.key)==null?void 0:hn.type)==="data"&&String((Fn=pr==null?void 0:pr.key)==null?void 0:Fn.tableId)===String(Jl)&&Ar.includes(pr==null?void 0:pr.id)}).forEach(pr=>{var hn;Cr.has(String(pr==null?void 0:pr.id))||(fo.push({id:pr==null?void 0:pr.id,...((hn=pr==null?void 0:pr.value)==null?void 0:hn.tableData)||{}}),Cr.add(String(pr==null?void 0:pr.id)))})}}}catch{}let ho=null;try{const nl=`ocr_committed_temp_ids_v1:${String((u==null?void 0:u.parentTableId)??"")}:${String((u==null?void 0:u.index)??"")}`,We=JSON.parse(sessionStorage.getItem(nl)||"null");Array.isArray(We)&&We.length>0&&(ho=new Set(We.map(Jl=>String(Jl))))}catch{}const Pt=Array.from(((kl=ve.value)==null?void 0:kl.values())||[]).filter(nl=>!(!(nl!=null&&nl._isOCRRow&&(nl==null?void 0:nl._ocrTableId)===(u==null?void 0:u.index))||ho&&ho.has(String(nl==null?void 0:nl.id)))),mu=(_e.value||[]).map(nl=>String(nl==null?void 0:nl.id)),Ft=ei(fo,mu);if(_e.value=Mt(Ft,O,De.value),wa.value=Ft,(Ka=wa.value)==null||Ka.forEach(nl=>{var We;(We=ve.value)==null||We.set(nl.id,nl)}),ho&&ho.size>0)try{const nl=new Set(Array.from(ho.values()));_e.value=(_e.value||[]).filter(We=>!nl.has(String(We==null?void 0:We.id))),wa.value=(wa.value||[]).filter(We=>!nl.has(String(We==null?void 0:We.id))),nl.forEach(We=>{var Jl,Tr;try{(Tr=(Jl=ve.value)==null?void 0:Jl.delete)==null||Tr.call(Jl,We)}catch{}})}catch{}const ii=JSON.parse(sessionStorage.getItem("ocr_last_saved_table")||"null"),at=JSON.parse(sessionStorage.getItem("ocr_last_saved_ids")||"null");if(ii&&Array.isArray(at)&&at.length>0&&String(ii==null?void 0:ii.compIndex)===String(u==null?void 0:u.index)){const nl=new Set((wa.value||[]).map(We=>String(We==null?void 0:We.id)));at.filter(We=>!nl.has(String(We)))}if(Pt.length>0){const nl=new Set((_e.value||[]).map(Jl=>Jl==null?void 0:Jl.id)),We=Pt.filter(Jl=>!nl.has(Jl.id));We.length>0&&(_e.value=[..._e.value||[],...We],wa.value=[...wa.value||[],...We],We.forEach(Jl=>{var Tr;return(Tr=ve.value)==null?void 0:Tr.set(Jl.id,Jl)}))}}else De.value=[],de.value=[],_e.value=[],wa.value=[],ve.value=new Map;if(ia=[...new Set(ia)],ia=ia==null?void 0:ia.map(ha=>({label:ha,type:"methodButton"})),((hl=Q==null?void 0:Q.contents)==null?void 0:hl.length)>0?Ma.value=Q==null?void 0:Q.contents:Ma.value=[],Ma.value=[...Ma.value,...ia],qe=[...new Set(qe)],qe=qe==null?void 0:qe.map(ha=>({label:ha,type:"methodButton"})),((ll=ae==null?void 0:ae.contents)==null?void 0:ll.length)>0)if((Tl=(Sl=(vl=d==null?void 0:d.find(ha=>(ha==null?void 0:ha.key)==="filterAllType"))==null?void 0:vl.value)==null?void 0:Sl.find(ha=>(ha==null?void 0:ha.value)==="onButtonContents"))!=null&&Tl.content){let ha=(wl=(Ll=(hr=d==null?void 0:d.find(Dl=>(Dl==null?void 0:Dl.key)==="filterAllType"))==null?void 0:hr.value)==null?void 0:Ll.find(Dl=>(Dl==null?void 0:Dl.value)==="onButtonContents"))==null?void 0:wl.content;if(ha=(zl=ha==null?void 0:ha.split(":"))==null?void 0:zl[1],ha=(Ul=ha.slice(1,(ha==null?void 0:ha.length)-1))==null?void 0:Ul.split(","),ga.value=(Al=ae==null?void 0:ae.contents)==null?void 0:Al.filter(Dl=>ha==null?void 0:ha.find(an=>an===(Dl==null?void 0:Dl.label))),ba.value=(ur=ae==null?void 0:ae.contents)==null?void 0:ur.filter(Dl=>ha==null?void 0:ha.find(an=>an===(Dl==null?void 0:Dl.label))),(dr=ae==null?void 0:ae.contents)!=null&&dr.some(Dl=>(Dl==null?void 0:Dl.label)==="OCR识别")&&!((Gl=ga.value)!=null&&Gl.some(Dl=>(Dl==null?void 0:Dl.label)==="OCR识别"))){const Dl=(ir=ae==null?void 0:ae.contents)==null?void 0:ir.find(an=>(an==null?void 0:an.label)==="OCR识别");ga.value=[...ga.value,Dl],ba.value=[...ba.value,Dl]}w.value=!!(ha!=null&&ha.find(Dl=>Dl==="搜索")),U.value=!!(ha!=null&&ha.find(Dl=>Dl==="块状显示"))}else ga.value=ae==null?void 0:ae.contents,ba.value=ae==null?void 0:ae.contents;else ga.value=[],ba.value=[];ga.value=[...ga.value,...qe],ba.value=[...ba.value,...qe],typeof ka.value=="string"&&ka.value==="设备管理/试验设备"&&(u==null?void 0:u.compName)==="设备列表"?(($r=ga.value)!=null&&$r.some(ha=>(ha==null?void 0:ha.label)==="OCR识别")||(ga.value=[...ga.value||[],{label:"OCR识别"}]),(tr=ba.value)!=null&&tr.some(ha=>(ha==null?void 0:ha.label)==="OCR识别")||(ba.value=[...ba.value||[],{label:"OCR识别"}])):(ga.value=(ga.value||[]).filter(ha=>(ha==null?void 0:ha.label)!=="OCR识别"),ba.value=(ba.value||[]).filter(ha=>(ha==null?void 0:ha.label)!=="OCR识别")),(lr=ga.value)!=null&&lr.some(ha=>(ha==null?void 0:ha.label)==="切换视图")||(ga.value=[...ga.value||[],{label:"切换视图"}]),(nr=ba.value)!=null&&nr.some(ha=>(ha==null?void 0:ha.label)==="切换视图")||(ba.value=[...ba.value||[],{label:"切换视图"}]),Pe.value=((Lt=_e==null?void 0:_e.value)==null?void 0:Lt.length)??0,At(_e.value),Br.value=_e.value,Ml.value&&(De.value=(Rt=($t=de.value)==null?void 0:$t.filter(ha=>(ha==null?void 0:ha.label)!=="操作"))==null?void 0:Rt.map(ha=>{var Dl;return{...ha,type:"edit",optionUrl:ha!=null&&ha.formMenuSelect&&((Dl=ha==null?void 0:ha.formMenuSelect)==null?void 0:Dl.length)>0?{groupSelect:ha==null?void 0:ha.groupSelect,menuSelect:ha==null?void 0:ha.formMenuSelect,selectRelateType:"",type:ha==null?void 0:ha.formType}:null}}),et())};a.watch(()=>[u.itemData,Xl.value,Kn.value,In.value,Fa==null?void 0:Fa.value],async()=>{var d,h,z,O,R,D;if((d=u==null?void 0:u.itemData)!=null&&d.find(Q=>(Q==null?void 0:Q.key)==="columnPath")&&!((h=F.value)!=null&&h.find(Q=>{var ae,j;return(Q==null?void 0:Q.key)===((j=(ae=u==null?void 0:u.itemData)==null?void 0:ae.find(he=>(he==null?void 0:he.key)==="columnPath"))==null?void 0:j.contents)}))){let Q=F.value,ae={key:(O=(z=u==null?void 0:u.itemData)==null?void 0:z.find(j=>(j==null?void 0:j.key)==="columnPath"))==null?void 0:O.contents,value:(D=(R=u==null?void 0:u.itemData)==null?void 0:R.find(j=>(j==null?void 0:j.key)==="columnUsingPath"))==null?void 0:D.contents};Q!=null&&Q.find(j=>(j==null?void 0:j.key)===(ae==null?void 0:ae.key))?Q=Q==null?void 0:Q.map(j=>((j==null?void 0:j.key)===(ae==null?void 0:ae.key)&&(j.value=ae.value),j)):Q.push(ae),Ge.setTableViewContents(Q)}await Ot(u.itemData,u.allMapContents)},{deep:!0,immediate:!0}),a.watch(()=>u==null?void 0:u.operatingForm,d=>{d!=null&&d.form&&(Mo(d==null?void 0:d.form),Le.value=d==null?void 0:d.dialogTitle,Ue.value=!0,va.value=!0)},{immediate:!0,deep:!0});const ru=()=>{var d;(d=B.value)!=null&&d.includes("read")&&(Ml.value=!Ml.value)},nu=()=>{cr.value=!cr.value};a.watch(()=>{var d;return(d=u==null?void 0:u.config)==null?void 0:d.viewport},d=>{var h;B.value=d,(d==null?void 0:d.length)===0?Ml.value=!1:(d!=null&&d.includes("read")||(Ml.value=!0),d!=null&&d.includes("edit")||(Ml.value=!1)),E.value=((h=u==null?void 0:u.config)==null?void 0:h.showIndex)||Ml.value},{immediate:!0}),a.watch(()=>Ml.value,d=>{var h;d?(et("viewChange"),Ge.setCacheUpdatingData(null)):(ga.value=ba.value,De.value=_a.value,P.value&&(Ge.setTableLoading(u==null?void 0:u.index),Ie("change",P.value))),E.value=d||((h=u==null?void 0:u.config)==null?void 0:h.showIndex),ar.value=[]},{immediate:!0}),a.watch(()=>{var d;return(d=$n.value)==null?void 0:d.length},d=>{d===0&&(Ee.currentPage=1)}),a.watch(()=>u==null?void 0:u.compNames,d=>{t.contents=[{label:"列表名",prop:"groupName",name:"列表名",type:"select",value:"",id:0,contents:d||[],width:1}]},{immediate:!0}),a.ref(!1);const ou=(d,h)=>{var z;et("createClick"),h===Ee.pageSize&&(Ee.currentPage=Math.ceil(((z=_e.value)==null?void 0:z.length)/Ee.pageSize))},iu=async(d,h,z)=>{var R,D,Q,ae,j;const O=(h==null?void 0:h.property)??(h==null?void 0:h.prop);if(O&&ni.includes(O)&&z!==void 0&&z!==null&&String(z).trim()!==""){const he=String(z).trim();if(await Qi(he,d==null?void 0:d.id)){rl.ElMessage.warning("当前任务下通道号不能重复,请重新选择");const $e=(R=_e.value)==null?void 0:R.findIndex(qe=>(qe==null?void 0:qe.id)===(d==null?void 0:d.id)),ze=$e!==-1?(Q=(D=_e.value)==null?void 0:D[$e])==null?void 0:Q[O]:void 0;O&&(d[O]=ze??"");return}}if(Ml.value){const he=d==null?void 0:d.id;he!=null&&(y.value.has(he)||y.value.set(he,I.cloneDeep(d)),c.value.add(he));const be=(ae=_e.value)==null?void 0:ae.findIndex($e=>($e==null?void 0:$e.id)===(d==null?void 0:d.id));be!==-1&&O&&(_e.value[be]={..._e.value[be],[O]:z}),oi(z,d,h);return}oi(z,d,h),Il.value=I.cloneDeep(d),Xe.value=d==null?void 0:d.id,Pe.value=(j=_e.value)==null?void 0:j.length,Le.value=d!=null&&d._isTemp?"新增":"编辑",Io(!1)},tu=async()=>{var d,h;try{const z=[];if(u!=null&&u.related&&Array.isArray(u.related)&&(console.log("props.related",u.related),u.related.forEach(O=>{if(typeof O=="string"&&O.includes("content_")){const R=O.split("_")[1];R&&(z.push(`content_${R}`),z.push(`struct_${R}`))}})),z.length===0&&(u!=null&&u.itemData)){const O=(h=(d=u.itemData)==null?void 0:d.find(R=>(R==null?void 0:R.key)==="contentTableId"))==null?void 0:h.contents;O&&(z.push(`content_${O}`),z.push(`struct_${O}`))}return z}catch(z){return console.error("获取 tableNames 失败:",z),[]}},su=async(d,h,z)=>{var D,Q;if(!z||typeof z!="string"||z.trim()===""){const ae=(h==null?void 0:h.property)??(h==null?void 0:h.prop),j=`${d==null?void 0:d.id}:${ae}`;f.value.delete(j),m.value.set(j,!1);return}const O=(h==null?void 0:h.property)??(h==null?void 0:h.prop),R=`${d==null?void 0:d.id}:${O}`;m.value.set(R,!0);try{const ae=await tu();if(ae.length===0){console.warn("未找到同名表,跳过全局搜索"),f.value.delete(R),m.value.set(R,!1);return}const j=parseInt((D=Rl.value)==null?void 0:D.plat_id);if(!j){console.warn("platId 无效,跳过全局搜索"),f.value.delete(R),m.value.set(R,!1);return}const he=await I.getAllTables({platId:j,tableNames:ae}),be=((Q=he==null?void 0:he.data)==null?void 0:Q.result)||[],$e=[],ze=[];for(let qe=0;qe<be.length;qe+=2)qe+1<be.length&&ze.push([be[qe],be[qe+1]]);ze.forEach(([qe,ia])=>{var Ua;if(!Array.isArray(qe)||qe.length===0||!Array.isArray(ia)||ia.length===0)return;const ja=ia[0];let Aa=((Ua=ja==null?void 0:ja.结构)==null?void 0:Ua.contents)??[];if(!Array.isArray(Aa)||Aa.length===0)return;let na=I.cloneDeep(Aa);if(Array.isArray(na==null?void 0:na[0])&&(na=ca.getColumnChild(na[0])),!Array.isArray(na)||na.length===0||!na.some(te=>(te==null?void 0:te.prop)===O))return;[...qe].sort((te,Da)=>{const da=Number((te==null?void 0:te.update_time)??0);return Number((Da==null?void 0:Da.update_time)??0)-da}).slice(0,20).forEach(te=>{const Da=te[O];if(Da!=null){const da=String(Da);da.toLowerCase().includes(z.toLowerCase())&&$e.findIndex(Ba=>{var M;return te.id&&((M=Ba.rowData)==null?void 0:M.id)===te.id?!0:Ba.label===da})===-1&&$e.push({label:da,rowData:I.cloneDeep(te),sourceTable:(ja==null?void 0:ja.source_table)||""})}})}),f.value.set(R,$e)}catch(ae){console.error("全局搜索建议失败:",ae),f.value.delete(R)}finally{m.value.set(R,!1)}},cu=(d,h,z)=>{if(!Ml.value)return;const O=(h==null?void 0:h.property)??(h==null?void 0:h.prop),R=(h==null?void 0:h.formType)||(h==null?void 0:h.columnType)||"";if(R&&R.toUpperCase()!=="INPUT"&&R!=="")return;const D=`${d==null?void 0:d.id}:${O}`;if(v.has(D)&&clearTimeout(v.get(D)),!z||z.trim()===""){f.value.delete(D),m.value.set(D,!1);return}const Q=setTimeout(()=>{su(d,{prop:O,property:O},z),v.delete(D)},300);v.set(D,Q)};function uu(d,h){const z=`${d==null?void 0:d.id}:${(h==null?void 0:h.property)??(h==null?void 0:h.prop)}`;return f.value.get(z)||[]}const du=(d,h,z)=>{var be;if(!z||!z.rowData)return;const O=z.rowData,R=d==null?void 0:d.id,D=(h==null?void 0:h.property)??(h==null?void 0:h.prop),ae=(ca.getAllLeafNodes(De.value)||[]).filter($e=>($e==null?void 0:$e.type)!=="operate"&&($e==null?void 0:$e.label)!=="操作"&&($e==null?void 0:$e.prop)!=="operate");ae.forEach($e=>{const ze=$e==null?void 0:$e.prop;ze&&O[ze]!==void 0&&(d[ze]=O[ze])});const j=(be=_e.value)==null?void 0:be.findIndex($e=>($e==null?void 0:$e.id)===R);j!==-1&&ae.forEach($e=>{const ze=$e==null?void 0:$e.prop;ze&&O[ze]!==void 0&&(_e.value[j][ze]=O[ze])}),R!=null&&(y.value.has(R)||y.value.set(R,I.cloneDeep(d)),c.value.add(R));const he=`${R}:${D}`;f.value.delete(he),m.value.set(he,!1),oi(d[D],d,h)},Lr=d=>{var j,he,be,$e,ze,qe,ia,ja,Aa,na,Xa;const{row:h,column:z,item:O,slotData:R}=d;let D=h!=null&&h[z==null?void 0:z.prop]||(h==null?void 0:h[z==null?void 0:z.prop])===0?((he=(j=h==null?void 0:h[z==null?void 0:z.prop])==null?void 0:j[0])==null?void 0:he.contents)??((h==null?void 0:h[z==null?void 0:z.prop])===0?"0":h==null?void 0:h[z==null?void 0:z.prop]):(($e=(be=h==null?void 0:h[O==null?void 0:O.prop])==null?void 0:be[0])==null?void 0:$e.contents)??(h==null?void 0:h[O==null?void 0:O.prop])??((qe=(ze=R==null?void 0:R[O==null?void 0:O.prop])==null?void 0:ze[0])==null?void 0:qe.contents)??(R==null?void 0:R[O==null?void 0:O.prop])??((Aa=(ja=h==null?void 0:h[(ia=O==null?void 0:O.child)==null?void 0:ia.prop])==null?void 0:ja[0])==null?void 0:Aa.contents)??(h==null?void 0:h[(na=O==null?void 0:O.child)==null?void 0:na.prop]),ae=Array.isArray(D)&&!(D!=null&&D.every(sa=>typeof sa=="string"||typeof sa=="number"))?"查看":D;if(ae=Array.isArray(ae)?ae.join(","):ae,(z==null?void 0:z.formType)==="Date")if(!ae||ae===""||ae===null||ae===void 0)ae="";else{const sa=I.dayjs(ae,["YYYY-MM-DD","YYYY/MM/DD","YYYY年MM月DD日","YYYYMMDD"],!0);ae=sa.isValid()?sa.format("YYYYMMDD"):ae??""}return Array.isArray(z==null?void 0:z.relatedPages)&&((Xa=z==null?void 0:z.relatedPages)==null?void 0:Xa.length)>0&&(ae="详情页"),ae},pu=d=>{var he,be,$e,ze,qe,ia,ja,Aa,na,Xa;const{row:h,column:z,item:O,slotData:R}=d;let D=h!=null&&h[z==null?void 0:z.prop]?((be=(he=h==null?void 0:h[z==null?void 0:z.prop])==null?void 0:he[0])==null?void 0:be.contents)??(h==null?void 0:h[z==null?void 0:z.prop]):((ze=($e=h==null?void 0:h[O==null?void 0:O.prop])==null?void 0:$e[0])==null?void 0:ze.contents)??(h==null?void 0:h[O==null?void 0:O.prop])??((ia=(qe=R==null?void 0:R[O==null?void 0:O.prop])==null?void 0:qe[0])==null?void 0:ia.contents)??(R==null?void 0:R[O==null?void 0:O.prop])??((na=(Aa=h==null?void 0:h[(ja=O==null?void 0:O.child)==null?void 0:ja.prop])==null?void 0:Aa[0])==null?void 0:na.contents)??(h==null?void 0:h[(Xa=O==null?void 0:O.child)==null?void 0:Xa.prop]);const ae=Array.isArray(D)&&!(D!=null&&D.every(sa=>typeof sa=="string"||typeof sa=="number")),j=Array.isArray(D)&&(D==null?void 0:D.find(sa=>sa==null?void 0:sa.url));return ae&&j},fu=d=>{var R,D;if(!(d!=null&&d.column))return!1;const h=ka.value==="试验任务/任务管理",z=(u==null?void 0:u.compName)==="任务列表",O=((R=d==null?void 0:d.column)==null?void 0:R.label)==="任务状态"||((D=d==null?void 0:d.column)==null?void 0:D.prop)==="任务状态";return h&&z&&O},hu=(d,h)=>d.find(z=>Object.values(z).some(O=>O===h));return a.watch(()=>Te.value,async d=>{if(d){la.setContentLoading(!0),await a.nextTick();const h=hu(_e.value,d==null?void 0:d.data);if(!h)return la.setContentLoading(!1);await Pn(d==null?void 0:d.data,null,h,{data:d==null?void 0:d.data}),la.setContentLoading(!1)}},{deep:!0,immediate:!0}),a.watch(()=>u==null?void 0:u.cacheNewData,d=>{var h;d&&(Array.isArray(d)?d.forEach(z=>{var O,R,D,Q,ae;if(换,String(z==null?void 0:z.compId)===String(u==null?void 0:u.index)&&(z!=null&&z.resId)&&((O=z==null?void 0:z.data)!=null&&O.id)){const j=(R=z==null?void 0:z.data)==null?void 0:R.id,he=z==null?void 0:z.resId;if(_e.value=(D=_e.value)==null?void 0:D.map(be=>{if((be==null?void 0:be.id)===j){const $e={...be,id:he};return delete $e._isOCRRow,delete $e._ocrTableId,$e}return be}),(ae=(Q=ve.value)==null?void 0:Q.has)!=null&&ae.call(Q,j)){const $e={...ve.value.get(j)||{},id:he};delete $e._isOCRRow,delete $e._ocrTableId,ve.value.delete(j),ve.value.set(he,$e)}Fe(u==null?void 0:u.index,j,he)}}):String(d==null?void 0:d.compId)===String(u==null?void 0:u.index)&&(_e.value=(h=_e.value)==null?void 0:h.map(z=>{var O;if((z==null?void 0:z.id)===((O=d==null?void 0:d.data)==null?void 0:O.id)){const R={...z,id:d==null?void 0:d.resId};return delete R._isOCRRow,delete R._ocrTableId,R}return z})))},{immediate:!0,deep:!0}),(d,h)=>{var na,Xa,sa,Ua;const z=a.resolveComponent("svg-icon"),O=a.resolveComponent("el-popover"),R=a.resolveComponent("el-switch"),D=a.resolveComponent("el-checkbox"),Q=a.resolveComponent("el-radio"),ae=a.resolveComponent("el-radio-group"),j=a.resolveComponent("el-checkbox-group"),he=a.resolveComponent("el-button"),be=a.resolveComponent("el-icon"),$e=a.resolveComponent("el-progress"),ze=a.resolveComponent("el-alert"),qe=a.resolveComponent("el-table-column"),ia=a.resolveComponent("el-table"),ja=a.resolveComponent("el-upload"),Aa=a.resolveComponent("el-text");return a.openBlock(),a.createElementBlock("div",m0,[Mr.value?(a.openBlock(),a.createBlock(pl.ssTable,{id:"excel-table",pageObj:Ee,showIndex:E.value,isTree:(na=l.compItem)==null?void 0:na.isTree,summaryInfo:ce,columns:De.value,defaultSort:X,isCardViewport:cr.value,checkedColumns:n.value,key:vn.value+De.value,tableData:$n.value,isEditViewport:Ml.value,isShowPagination:xa.value,isShowEdit:!1,isShowDelete:!1,allowSelect:x.value,onDbClickRow:ai,extraButton:ga.value,rowButton:Ma.value,cacheExtraButtons:ba.value,isClearSelection:((Xa=ar.value)==null?void 0:Xa.length)===0,onDoCurrentChange:fn,onDoSizeChange:No,onSortChange:Ai,onContentClick:Pn,onRowClick:li,onSelectChange:$i,onCellChange:iu,onCellInput:cu,onSelectSuggest:du,onChange:oi,onPreview:Vn,onSubmitEditingTable:Ko,onHandleColEditChange:Uo,onHandleColTypeChange:qo,onClickButton:Tn,onAddNewRow:Or,bottomButton:A.value},a.createSlots({headerButton:a.withCtx(te=>{var Da,da;return[l.showHeader?(a.openBlock(),a.createBlock(Wp,{key:0,id:"tableHeaderButton",pageLayout:l.pageLayout,lockingPage:a.unref(se)===a.unref(ka),filterValues:Hi.value,selectNums:(Da=ar.value)==null?void 0:Da.length,dataNums:(da=_e.value)==null?void 0:da.length,compName:l.compName,isDevMode:l.isDevMode,buttons:te.buttons,onButtonClick:h[1]||(h[1]=(Ca,Ba,M)=>Tn(Ca,Ba,{extra:M})),columns:De.value,onFilter:Ui,onGetImportData:Mi,level:l.level,filterShow:w.value},null,8,["pageLayout","lockingPage","filterValues","selectNums","dataNums","compName","isDevMode","buttons","columns","level","filterShow"])):a.createCommentVNode("",!0)]}),viewport:a.withCtx(()=>{var te,Da,da,Ca;return[((te=_e.value)==null?void 0:te.length)>0&&l.allowOperate&&U.value?(a.openBlock(),a.createElementBlock("div",b0,[(Da=B.value)!=null&&Da.includes("read")&&((da=B.value)!=null&&da.includes("edit"))&&((Ca=Ma.value)!=null&&Ca.some(Ba=>(Ba==null?void 0:Ba.label)==="编辑"))&&!cr.value&&a.unref(se)!==a.unref(ka)?(a.openBlock(),a.createElementBlock("span",{key:0,title:"编辑表格",onClick:ru},[a.createVNode(z,{name:"editTable",class:"view-icon"})])):a.createCommentVNode("",!0)])):a.createCommentVNode("",!0)]}),rowCreate:a.withCtx(({row:te,index:Da})=>[a.createElementVNode("span",{title:"新增",class:"row-create-wrap",onClick:da=>ou(te,Da)},[a.createVNode(z,{name:"rowCreate",style:{width:"10px",height:"10px"}})],8,k0)]),operateCol:a.withCtx(()=>[a.createVNode(O,{title:"选择显示列信息",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:Zc},{reference:a.withCtx(()=>[a.createElementVNode("span",x0,[a.createVNode(z,{name:"operate",style:{width:"15px",height:"15px",cursor:"pointer"}})])]),default:a.withCtx(()=>[a.createElementVNode("div",_0,[h[20]||(h[20]=a.createElementVNode("div",{class:"group-title"},"表格操作",-1)),a.createVNode(R,{"model-value":_.value,"active-text":"排序","inactive-text":"",style:{"margin-right":"8px"},onChange:h[2]||(h[2]=te=>Go(te))},null,8,["model-value"]),h[21]||(h[21]=a.createElementVNode("div",{class:"group-title"},"表格列操作",-1)),a.createVNode(j,{modelValue:n.value,"onUpdate:modelValue":h[3]||(h[3]=te=>n.value=te),style:{height:"100%"},min:2,ref_key:"checkboxGroupRef",ref:s},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(xn.value,te=>(a.openBlock(),a.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:te.label},[a.createVNode(D,{value:te.label,style:{width:"100%",marginRight:0}},{default:a.withCtx(()=>[a.createElementVNode("span",{title:te.label,style:{display:"inline-block",width:"250px",overflow:"hidden","text-overflow":"ellipsis","white-space":"nowrap"}},a.toDisplayString(te.label),9,w0)]),_:2},1032,["value"]),a.createVNode(O,{"popper-class":"col-operate-popover",title:"列操作",placement:"left",teleported:!1,trigger:"hover"},{reference:a.withCtx(()=>[a.createVNode(z,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:a.withCtx(()=>{var Da;return[a.createElementVNode("div",C0,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList((Da=Object.keys(te))==null?void 0:Da.filter(da=>{var Ca;return(Ca=Y.value)==null?void 0:Ca.find(Ba=>(Ba==null?void 0:Ba.value)===da)}),da=>{var Ca,Ba;return a.openBlock(),a.createElementBlock("div",{key:da},[N[da]=="radio"?(a.openBlock(),a.createElementBlock("div",E0,[h[19]||(h[19]=a.createElementVNode("div",null,"固定:",-1)),a.createVNode(ae,{"model-value":te==null?void 0:te[da],onChange:M=>_n(M,da,te)},{default:a.withCtx(()=>{var M,K;return[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList((K=(M=Y.value)==null?void 0:M.find(Ae=>(Ae==null?void 0:Ae.value)===da))==null?void 0:K.options,Ae=>(a.openBlock(),a.createBlock(Q,{key:Ae==null?void 0:Ae.value,label:Ae==null?void 0:Ae.value,value:Ae==null?void 0:Ae.value},{default:a.withCtx(()=>[a.createTextVNode(a.toDisplayString(Ae==null?void 0:Ae.label),1)]),_:2},1032,["label","value"]))),128))]}),_:2},1032,["model-value","onChange"])])):a.createCommentVNode("",!0),N[da]=="switch"?(a.openBlock(),a.createBlock(R,{key:1,"model-value":te==null?void 0:te[da],"active-text":(Ba=(Ca=Y.value)==null?void 0:Ca.find(M=>(M==null?void 0:M.value)===da))==null?void 0:Ba.label,onChange:M=>_n(M,da,te)},null,8,["model-value","active-text","onChange"])):a.createCommentVNode("",!0)])}),128))])]}),_:2},1024),a.createElementVNode("span",S0,[a.createVNode(z,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:1},8,["modelValue"])])]),_:1})]),content:a.withCtx(te=>{var Da,da,Ca,Ba,M,K,Ae,ta,ke,ua,za,dl,el,yl,gl,Vl,Za,kl,Ka,hl;return[((Da=te==null?void 0:te.column)==null?void 0:Da.label)==="证书附件"||((da=te==null?void 0:te.column)==null?void 0:da.prop)==="证书附件"?(a.openBlock(),a.createElementBlock("div",D0,[a.createVNode(z,{name:"query",style:{width:"20px",height:"20px",color:"var(--ssComponent-theme-color)",cursor:"pointer"},onClick:a.withModifiers(ll=>Fr(te),["stop"]),title:"查看OCR图片"},null,8,["onClick"])])):pu(te)?(a.openBlock(),a.createBlock(O,{key:1,"popper-class":"file-popover",placement:"right",trigger:"hover",effect:"light",width:"auto"},{reference:a.withCtx(()=>[a.createElementVNode("span",N0,a.toDisplayString(Lr(te)),1)]),default:a.withCtx(()=>{var ll,vl;return[a.createElementVNode("div",B0,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList((vl=te==null?void 0:te.row)==null?void 0:vl[(ll=te==null?void 0:te.column)==null?void 0:ll.prop],Sl=>(a.openBlock(),a.createElementBlock("div",T0,[a.createElementVNode("div",{class:"prop-url",title:Jn(Sl),onClick:Tl=>Fi(Sl)},a.toDisplayString(Jn(Sl)),9,A0),a.createElementVNode("div",{class:"prop-download",onClick:Tl=>to(Sl)}," 下载 ",8,z0)]))),256))])]}),_:2},1024)):(a.openBlock(),a.createElementBlock(a.Fragment,{key:2},[fu(te)?(a.openBlock(),a.createBlock(Su,{key:0,value:Lr(te)},null,8,["value"])):(a.openBlock(),a.createElementBlock("div",{key:1,class:"table-cell-content",style:a.normalizeStyle({color:!Array.isArray(Lr(te))&&((Ba=(Ca=Lr(te))==null?void 0:Ca.toString())!=null&&Ba.includes(".txt")||(K=(M=Lr(te))==null?void 0:M.toString())!=null&&K.includes(".cpt")||(ta=(Ae=Lr(te))==null?void 0:Ae.toString())!=null&&ta.includes(".cyd"))?"var(--vertical-menuitem-active-bg)":"",textDecoration:!Array.isArray(Lr(te))&&((ua=(ke=Lr(te))==null?void 0:ke.toString())!=null&&ua.includes(".txt")||(dl=(za=Lr(te))==null?void 0:za.toString())!=null&&dl.includes(".cpt")||(yl=(el=Lr(te))==null?void 0:el.toString())!=null&&yl.includes(".cyd"))?"underline":"",cursor:!Array.isArray(Lr(te))&&((Vl=(gl=Lr(te))==null?void 0:gl.toString())!=null&&Vl.includes(".txt")||(kl=(Za=Lr(te))==null?void 0:Za.toString())!=null&&kl.includes(".cpt")||(hl=(Ka=Lr(te))==null?void 0:Ka.toString())!=null&&hl.includes(".cyd"))?"pointer":"",marginLeft:(te==null?void 0:te.colIndex)===0?`${((te==null?void 0:te.level)??0)*20}px`:0}),onClick:ll=>{var vl;return Nn(Lr(te),((vl=te==null?void 0:te.column)==null?void 0:vl.relatedPages)??[])}},a.toDisplayString(Lr(te)===0?"0":Lr(te)),13,M0))],64))]}),_:2},[((sa=Ma.value)==null?void 0:sa.length)>0?{name:"actions",fn:a.withCtx(({item:te,fIndex:Da})=>[a.createVNode(O,{title:"",placement:"left-start","popper-class":"menu-operate-popover"},{reference:a.withCtx(()=>[a.createVNode(z,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"},onClick:h[0]||(h[0]=a.withModifiers(()=>{},["stop"]))})]),default:a.withCtx(()=>[a.createElementVNode("div",y0,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(ji(Ma.value,te),(da,Ca)=>(a.openBlock(),a.createElementBlock("div",{class:"menu-config-item",key:Ca,onClick:a.withModifiers(Ba=>Tn(da==null?void 0:da.label,te,{extra:da}),["stop"])},[a.createElementVNode("div",{style:a.normalizeStyle({color:da==null?void 0:da.textColor}),class:"extra-button-label"},a.toDisplayString(da==null?void 0:da.label),5)],8,g0))),128))])]),_:2},1024)]),key:"0"}:void 0]),1032,["pageObj","showIndex","isTree","summaryInfo","columns","defaultSort","isCardViewport","checkedColumns","tableData","isEditViewport","isShowPagination","allowSelect","extraButton","rowButton","cacheExtraButtons","isClearSelection","bottomButton"])):a.createCommentVNode("",!0),Ml.value?(a.openBlock(),a.createElementBlock("div",O0,[a.createVNode(he,{id:"themeBorderButton",onClick:Li},{default:a.withCtx(()=>h[22]||(h[22]=[a.createTextVNode("取消")])),_:1,__:[22]}),a.createVNode(he,{class:"ok-button",id:"themeButton",onClick:Bo},{default:a.withCtx(()=>h[23]||(h[23]=[a.createTextVNode("保存")])),_:1,__:[23]})])):a.createCommentVNode("",!0),a.createVNode(vr.ssDialog,{title:Le.value,visible:va.value,width:Hl.value,onBeforeDestroy:Jo,style:{height:"74%"}},{default:a.withCtx(()=>[a.createElementVNode("div",I0,[a.createVNode(pl.ssForm,{ref_key:"formRef",ref:re,rowContents:$a.value,showOperator:!1,onChange:Qc,isEnableWrap:!1,onFixChangeValue:Ao,onClickTrigger:Xo,isEdit:aa.value,onBlurChange:Ri,onCreate:Yo,onTagChange:Kr},null,8,["rowContents","isEdit"])])]),footer:a.withCtx(()=>[Ue.value?(a.openBlock(),a.createElementBlock("div",L0,[a.createVNode(he,{onClick:h[4]||(h[4]=te=>va.value=!1),id:"themeBorderButton"},{default:a.withCtx(()=>h[24]||(h[24]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[24]}),a.createVNode(he,{class:"ok-button",onClick:h[5]||(h[5]=te=>Io(!0)),id:"themeButton"},{default:a.withCtx(()=>h[25]||(h[25]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[25]})])):a.createCommentVNode("",!0)]),_:1},8,["title","visible","width"]),a.createVNode(vr.ssDialog,{title:Le.value,visible:Z.value,width:fa.value,onBeforeDestroy:h[7]||(h[7]=te=>Z.value=!1)},{default:a.withCtx(()=>[a.createVNode(of)]),footer:a.withCtx(()=>[a.createElementVNode("div",$0,[a.createVNode(he,{onClick:h[6]||(h[6]=te=>Z.value=!1),class:"cancel-button",id:"themeBorderButton"},{default:a.withCtx(()=>h[26]||(h[26]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[26]}),a.createVNode(he,{class:"ok-button",onClick:zo,id:"themeButton"},{default:a.withCtx(()=>h[27]||(h[27]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[27]})])]),_:1},8,["title","visible","width"]),Wa.value?(a.openBlock(),a.createBlock(pl.ssFilePreview,{key:2,fileDataList:ee.value,onDestroy:wn},null,8,["fileDataList"])):a.createCommentVNode("",!0),Ke.value?(a.openBlock(),a.createBlock(vr.ssDialog,{key:3,visible:Ke.value,onBeforeDestroy:Jc,style:{height:"80vh",width:"80vw"},"body-class":"three-dialog-body","footer-class":"three-dialog-footer"},{default:a.withCtx(()=>[a.createVNode(bi.ThreeViewerHost,{files:Ya.value,threeData:oe.value},null,8,["files","threeData"])]),_:1},8,["visible"])):a.createCommentVNode("",!0),a.createVNode(vr.ssDialog,{title:"OCR扫描录入",visible:Va.value,"close-on-click-modal":!1,onBeforeDestroy:sl,width:"1000px",dialogHeight:700,minWidth:900,minHeight:600,class:"ocr-upload-dialog",resizable:!0},{default:a.withCtx(()=>[h[38]||(h[38]=a.createElementVNode("div",{class:"ocr-header-bg"},null,-1)),a.createElementVNode("div",R0,[a.createElementVNode("div",V0,[a.createElementVNode("div",{class:a.normalizeClass(["ocr-step-item",{active:q.value===1}])},h[28]||(h[28]=[a.createElementVNode("div",{class:"step-circle"},"1",-1),a.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件识别",-1)]),2),h[31]||(h[31]=a.createElementVNode("div",{class:"ocr-step-connector"},null,-1)),a.createElementVNode("div",{class:a.normalizeClass(["ocr-step-item",{active:q.value===2}])},h[29]||(h[29]=[a.createElementVNode("div",{class:"step-circle"},"2",-1),a.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件确认",-1)]),2),h[32]||(h[32]=a.createElementVNode("div",{class:"ocr-step-connector"},null,-1)),a.createElementVNode("div",{class:a.normalizeClass(["ocr-step-item",{active:q.value===3}])},h[30]||(h[30]=[a.createElementVNode("div",{class:"step-circle"},"3",-1),a.createElementVNode("div",{class:"step-label",style:{"font-weight":"800"}},"文件提交",-1)]),2)]),q.value===1?(a.openBlock(),a.createElementBlock("div",P0,[a.createVNode(he,{onClick:Ji,class:"ocr-action-btn",disabled:je.value,size:"default"},{default:a.withCtx(()=>h[33]||(h[33]=[a.createTextVNode("扫描文件 ")])),_:1,__:[33]},8,["disabled"]),a.createVNode(he,{onClick:jl,class:"ocr-action-btn",disabled:je.value,size:"default"},{default:a.withCtx(()=>h[34]||(h[34]=[a.createTextVNode("上传文件 ")])),_:1,__:[34]},8,["disabled"])])):a.createCommentVNode("",!0),q.value===1?(a.openBlock(),a.createElementBlock("div",F0,[a.createElementVNode("div",j0,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(xe.value,(te,Da)=>{var da;return a.openBlock(),a.createElementBlock("div",{key:Da,class:"ocr-file-item"},[a.createElementVNode("div",H0,[te.raw&&((da=te.raw.type)!=null&&da.startsWith("image/"))?(a.openBlock(),a.createElementBlock("img",{key:0,src:Cl(te),alt:"预览",class:"thumbnail-image"},null,8,U0)):(a.openBlock(),a.createElementBlock("div",q0,[a.createVNode(be,{size:40},{default:a.withCtx(()=>[a.createVNode(a.unref(rl.document_default))]),_:1})])),a.createElementVNode("div",{class:a.normalizeClass(["file-progress-ring",{uploading:cl(te)==="uploading",processing:cl(te)==="processing",completed:cl(te)==="completed"||cl(te)==="uploaded",failed:cl(te)==="failed"}])},[(a.openBlock(),a.createElementBlock("svg",W0,[h[35]||(h[35]=a.createElementVNode("circle",{class:"progress-ring-bg",cx:"18",cy:"18",r:"16",fill:"none",stroke:"#e4e7ed","stroke-width":"2"},null,-1)),a.createElementVNode("circle",{class:a.normalizeClass(["progress-ring-fill",{completed:cl(te)==="completed"||cl(te)==="uploaded",uploading:cl(te)==="uploading",processing:cl(te)==="processing",failed:cl(te)==="failed"}]),cx:"18",cy:"18",r:"16",fill:"none",stroke:cl(te)==="failed"?"#f56c6c":cl(te)==="completed"||cl(te)==="uploaded"?"#67c23a":"#409eff","stroke-width":cl(te)==="completed"||cl(te)==="uploaded"||cl(te)==="failed"?3:2,"stroke-dasharray":Yl(te),"stroke-dashoffset":"0","stroke-linecap":"round",transform:"rotate(-90 18 18)"},null,10,K0)])),cl(te)==="completed"||cl(te)==="uploaded"?(a.openBlock(),a.createElementBlock("div",Y0,[a.createVNode(be,{class:"check-icon"},{default:a.withCtx(()=>[a.createVNode(a.unref(rl.check_default))]),_:1})])):a.createCommentVNode("",!0),cl(te)==="failed"?(a.openBlock(),a.createElementBlock("div",G0,[a.createVNode(be,{class:"error-icon"},{default:a.withCtx(()=>[a.createVNode(a.unref(rl.close_default))]),_:1})])):a.createCommentVNode("",!0)],2),a.createElementVNode("div",{class:"file-delete-btn",onClick:Ca=>uo(Da)},[a.createVNode(be,null,{default:a.withCtx(()=>[a.createVNode(a.unref(rl.close_default))]),_:1})],8,J0)]),a.createElementVNode("div",X0,a.toDisplayString(te.name||"文件名123"),1)])}),128))]),xe.value.length>0?(a.openBlock(),a.createElementBlock("div",Z0,[a.createVNode(he,{onClick:pe,class:"ocr-start-recognize-btn",disabled:je.value||xe.value.length===0,size:"default"},{default:a.withCtx(()=>h[36]||(h[36]=[a.createTextVNode("开始识别 ")])),_:1,__:[36]},8,["disabled"])])):a.createCommentVNode("",!0)])):a.createCommentVNode("",!0),q.value===1?(a.openBlock(),a.createElementBlock("div",Q0,[a.createVNode($e,{percentage:we.value,"stroke-width":8},null,8,["percentage"])])):a.createCommentVNode("",!0),q.value===2?(a.openBlock(),a.createElementBlock("div",e3,[a.createElementVNode("div",a3,[a.createVNode(ze,{title:"请核对识别结果。",type:"info",closable:!1,"show-icon":""})]),a.createElementVNode("div",l3,[a.createVNode(ia,{data:qa.value,border:"",stripe:"","max-height":"400",style:{width:"100%"}},{default:a.withCtx(()=>[a.createVNode(qe,{type:"index",label:"序号",width:"60",fixed:""}),(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(fe.value,te=>(a.openBlock(),a.createBlock(qe,{key:te.prop,prop:te.prop,"min-width":te.minWidth||230,"class-name":te.isAccuracy?"accuracy-column":""},{header:a.withCtx(()=>[a.createElementVNode("div",r3,[a.createElementVNode("span",null,a.toDisplayString(te.label),1)])]),default:a.withCtx(({row:Da,$index:da})=>{var Ca,Ba,M;return[te.isAccuracy?(a.openBlock(),a.createElementBlock("span",{key:0,class:"accuracy-value",style:a.normalizeStyle({color:ol(Da[te.prop]),fontWeight:500})},a.toDisplayString(La(Da[te.prop])),5)):(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[Ia.value!==da?(a.openBlock(),a.createElementBlock("span",n3,a.toDisplayString(Da[te.prop]),1)):(a.openBlock(),a.createBlock(a.resolveDynamicComponent(Qa(te.prop)),{key:1,modelValue:Da[te.prop],"onUpdate:modelValue":K=>Da[te.prop]=K,size:"small",placeholder:"请输入"+te.label,content:((Ca=fl(te.prop))==null?void 0:Ca.contents)??((Ba=fl(te.prop))==null?void 0:Ba.options)??[],optionUrl:(M=fl(te.prop))==null?void 0:M.optionUrl,onChange:K=>Qe(da,te.prop,K),onFocus:K=>ul.value=te.prop,onBlur:h[8]||(h[8]=K=>ul.value="")},null,40,["modelValue","onUpdate:modelValue","placeholder","content","optionUrl","onChange","onFocus"]))],64))]}),_:2},1032,["prop","min-width","class-name"]))),128)),a.createVNode(qe,{label:"编辑",width:"80",fixed:"right"},{default:a.withCtx(({$index:te})=>[Ia.value===te?(a.openBlock(),a.createBlock(be,{key:0,class:"ocr-edit-icon editing",style:{"margin-left":"12px"},onClick:a.withModifiers(Da=>al(te),["stop"])},{default:a.withCtx(()=>[a.createVNode(a.unref(rl.check_default))]),_:2},1032,["onClick"])):(a.openBlock(),a.createBlock(z,{key:1,name:"edit_101",class:"ocr-edit-icon",onClick:a.withModifiers(Da=>al(te),["stop"])},null,8,["onClick"]))]),_:1})]),_:1},8,["data"])])])):a.createCommentVNode("",!0),q.value===3?(a.openBlock(),a.createElementBlock("div",o3,[a.createVNode(be,{size:"32",class:"ocr-success-icon"},{default:a.withCtx(()=>[a.createVNode(a.unref(rl.check_default))]),_:1}),h[37]||(h[37]=a.createElementVNode("div",{class:"ocr-success-text"},"文件提交成功",-1))])):a.createCommentVNode("",!0)]),a.createVNode(ja,{ref:"ocrUploadRef","file-list":xe.value,"onUpdate:fileList":h[9]||(h[9]=te=>xe.value=te),multiple:"",action:"","auto-upload":!1,limit:20,accept:"image/*,application/pdf","on-change":H,"show-file-list":!1,class:"ocr-upload-input",style:{display:"none"}},null,8,["file-list"])]),footer:a.withCtx(()=>[q.value!==3?(a.openBlock(),a.createElementBlock("div",i3,[a.createVNode(he,{onClick:Ir,class:"ocr-start-recognize-btn",disabled:q.value===1||je.value},{default:a.withCtx(()=>h[39]||(h[39]=[a.createTextVNode(" 上一步 ")])),_:1,__:[39]},8,["disabled"]),a.createVNode(he,{onClick:mr,class:"ocr-start-recognize-btn",disabled:je.value},{default:a.withCtx(()=>h[40]||(h[40]=[a.createTextVNode(" 下一步 ")])),_:1,__:[40]},8,["disabled"])])):a.createCommentVNode("",!0)]),_:1},8,["visible"]),a.createVNode(Cf,{visible:co.value,onConfirm:Xi,onCancel:h[10]||(h[10]=te=>co.value=!1)},null,8,["visible"]),a.createVNode(td,{visible:Je.value,"onUpdate:visible":h[11]||(h[11]=te=>Je.value=te),versions:ea.value},null,8,["visible","versions"]),a.createVNode(Ku,{visible:Ja.value,"onUpdate:visible":h[12]||(h[12]=te=>Ja.value=te),images:Wl.value,"default-image-name":Kl.value,"field-meta":Ia.value!==null?((Ua=qa.value[Ia.value])==null?void 0:Ua.__ocrFieldMeta)||{}:{},"focused-field-name":ul.value,onClose:h[13]||(h[13]=te=>Ja.value=!1),class:"ocr-img-preview-dialog"},null,8,["visible","images","default-image-name","field-meta","focused-field-name"]),a.createVNode(kd,{visible:$l.value,"onUpdate:visible":h[14]||(h[14]=te=>$l.value=te),candidates:Fl.value,"name-prop":un.value,"mfr-prop":Jr.value,columns:De.value,onSubmit:on,onPreviewFile:en},null,8,["visible","candidates","name-prop","mfr-prop","columns"]),a.createVNode(Dd,{visible:Se.value,"onUpdate:visible":h[15]||(h[15]=te=>Se.value=te),ocrPreviewData:qa.value,"onUpdate:ocrPreviewData":h[16]||(h[16]=te=>qa.value=te),ocrSelectedFields:il.value,"onUpdate:ocrSelectedFields":h[17]||(h[17]=te=>il.value=te),ocrPreviewColumns:fe.value,onConfirm:ye,onFieldChange:h[18]||(h[18]=({rowIndex:te,prop:Da,value:da})=>Qe(te,Da,da))},null,8,["visible","ocrPreviewData","ocrSelectedFields","ocrPreviewColumns"]),a.createVNode(vr.ssDialog,{title:t.title,visible:t.show,width:t.width,onBeforeDestroy:C},{default:a.withCtx(()=>[a.createElementVNode("div",t3,[a.createVNode(pl.ssForm,{rowContents:t==null?void 0:t.contents,formRules:t==null?void 0:t.formRules,showOperator:!1,buttonValue:t.buttonValue,isEdit:aa.value,isStartJustify:!1,onOnButtonClick:L},null,8,["rowContents","formRules","buttonValue","isEdit"])])]),_:1},8,["title","visible","width"]),a.createVNode(vr.ssDialog,{title:i.title,visible:i.show,width:i.width,alignCenter:!0,onBeforeDestroy:p},{header:a.withCtx(()=>[a.createVNode(Aa,{size:"small",type:"danger",style:{width:"100%"}},{default:a.withCtx(()=>h[41]||(h[41]=[a.createTextVNode("(选择【覆盖】,可能会影响到原数据的引用关系;选择【取消】将会放弃重复数据的导入。请谨慎操作!)")])),_:1,__:[41]})]),footer:a.withCtx(()=>[a.createElementVNode("div",s3,[a.createVNode(Aa,{size:"small",style:{width:"100%","text-align":"left"},type:"info"},{default:a.withCtx(()=>[a.createTextVNode("引用模块:"+a.toDisplayString(Sn.value||"暂无"),1)]),_:1}),a.createElementVNode("div",c3,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(i==null?void 0:i.buttonValue,te=>(a.openBlock(),a.createBlock(he,{key:te==null?void 0:te.label,style:a.normalizeStyle({background:te==null?void 0:te.background,color:te==null?void 0:te.color}),onClick:Da=>g(te==null?void 0:te.value)},{default:a.withCtx(()=>[a.createTextVNode(a.toDisplayString(te==null?void 0:te.label),1)]),_:2},1032,["style","onClick"]))),128))])])]),default:a.withCtx(()=>[a.createVNode(Kp,{columns:i==null?void 0:i.columns,tableData:i==null?void 0:i.tableData},{content:a.withCtx(({row:te,item:Da,slotData:da,scope:Ca,column:Ba,columnProp:M,$index:K})=>[a.createTextVNode(a.toDisplayString((te==null?void 0:te[(Ba==null?void 0:Ba.prop)||(Ba==null?void 0:Ba.label)])||(da==null?void 0:da[Ba==null?void 0:Ba.property])),1)]),_:1},8,["columns","tableData"])]),_:1},8,["title","visible","width"])])}}},mc=ql._export_sfc(d3,[["__scopeId","data-v-d6b5726c"]]),p3={class:"static-form-card"},f3={key:0,class:"static-form-body"},h3=["onClick"],v3={key:1},m3=a.defineComponent({__name:"index",props:{itemData:{default:()=>[]},fields:{default:()=>[]},compName:{default:""},title:{default:""},disabled:{type:Boolean,default:!1},textSize:{default:void 0},textColor:{default:void 0}},setup(l){const r=l,n=E=>{switch(E){case"占用":return"warning";case"注销":return"info";case"损坏":return"danger";case"可用":return"success";default:return""}},o=a.computed(()=>{var V;const E=(V=r.itemData)==null?void 0:V.find(A=>(A==null?void 0:A.key)==="formContent"),B=(E==null?void 0:E.contents)||[];return(r.fields&&r.fields.length>0?r.fields:B).filter(A=>!(A!=null&&A.isFormColHidden)&&(A==null?void 0:A.label)).map(A=>{let N=A==null?void 0:A.value;Array.isArray(N)&&(N=N.map(T=>T==null?"":typeof T=="object"?T.label??T.value??T.name??JSON.stringify(T):String(T)).filter(Boolean).join(",")),N!=null&&typeof N=="object"&&(N=N.label??N.value??N.name??JSON.stringify(N));const Y=A.label??"",b=N==null||N===""?"-":String(N),$=Y==="使用状态";return{label:Y,value:b,isStatus:$,tagType:$?n(b):"",width:A.width??1,field:A}})}),s=a.ref(null),c=E=>{if(Array.isArray(E)&&E.length>=3){const[B,w,V,A]=E;return A!==void 0?`rgba(${B}, ${w}, ${V}, ${A})`:`rgb(${B}, ${w}, ${V})`}if(typeof E=="string"){const B=E.trim();if(B.startsWith("[")&&B.endsWith("]")){const w=B.slice(1,-1).split(",").map(V=>Number(V.trim()));if(w.length>=3&&w.every(V=>!Number.isNaN(V))){const[V,A,N,Y]=w;return Y!==void 0?`rgba(${V}, ${A}, ${N}, ${Y})`:`rgb(${V}, ${A}, ${N})`}}return B}},y=a.computed(()=>{const E=Number(r==null?void 0:r.textSize),B=c(r==null?void 0:r.textColor),w={},V={},A={},N={};return!Number.isNaN(E)&&E&&(w.fontSize=`${E}px`,V.fontSize=`${E+1}px`,A.fontSize=`${E}px`,N.fontSize=`${E}px`),B&&(V.color=B,A.color=B,N.color=B),{item:w,label:V,value:A,empty:N}}),f=E=>pl.getComponent(E),v=E=>{if(!E)return;const B=E.querySelector("input, textarea, .el-input__inner");B&&typeof B.focus=="function"&&B.focus()},m=(E,B,w)=>{r.disabled||(s.value=B,a.nextTick(()=>{v(w.currentTarget)}))},u=()=>{s.value=null},x=E=>{const B=E!=null&&E.width&&E.width>0?E.width:1,V=`calc((100% - ${(B-1)*48}px) / ${B})`;return{flex:`0 0 ${V}`,maxWidth:V,minWidth:"0",boxSizing:"border-box"}};return(E,B)=>{const w=a.resolveComponent("el-tag");return a.openBlock(),a.createElementBlock("div",p3,[o.value.length?(a.openBlock(),a.createElementBlock("div",f3,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(o.value,(V,A)=>{var N,Y,b,$,T,k,_,U;return a.openBlock(),a.createElementBlock("div",{key:A,class:"static-form-item",style:a.normalizeStyle({...x(V),...y.value.item})},[a.createElementVNode("div",{class:"static-form-label",style:a.normalizeStyle(y.value.label)},a.toDisplayString(V.label)+": ",5),a.createElementVNode("div",{class:"static-form-value",style:a.normalizeStyle(y.value.value),onClick:W=>m(V,A,W)},[s.value===A&&V.field?(a.openBlock(),a.createBlock(a.resolveDynamicComponent(f(((N=V.field)==null?void 0:N.type)??"Input")),{key:0,modelValue:V.field.value,"onUpdate:modelValue":W=>V.field.value=W,isEdit:!0,disabled:(Y=V.field)==null?void 0:Y.disabled,content:((b=V.field)==null?void 0:b.contents)??[],optionUrl:V.field,originalValue:($=V.field)==null?void 0:$.value,config:(T=V.field)==null?void 0:T.config,configModel:((k=V.field)==null?void 0:k.prop)??((_=V.field)==null?void 0:_.name),selectedTagList:((U=V.field)==null?void 0:U.selectValue)??[],onBlur:u,onBlurChange:u},null,40,["modelValue","onUpdate:modelValue","disabled","content","optionUrl","originalValue","config","configModel","selectedTagList"])):(a.openBlock(),a.createElementBlock(a.Fragment,{key:1},[V.isStatus?(a.openBlock(),a.createBlock(w,{key:0,type:V.tagType,size:"Default",effect:"plain"},{default:a.withCtx(()=>[a.createTextVNode(a.toDisplayString(V.value??"-"),1)]),_:2},1032,["type"])):(a.openBlock(),a.createElementBlock("span",v3,a.toDisplayString(V.value??"-"),1))],64))],12,h3)],4)}),128))])):(a.openBlock(),a.createElementBlock("div",{key:1,class:"static-form-empty",style:a.normalizeStyle(y.value.empty)}," 暂无数据 ",4))])}}}),yc=ql._export_sfc(m3,[["__scopeId","data-v-351e0bf9"]]),y3={class:"form-content"},g3={title:"选择标签"},b3={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},k3={class:"col-operate-wrap"},x3={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},_3={__name:"index",props:{formRules:Object,itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,compName:{type:String,default:""},allMapContents:{type:Object},config:{type:Object,default:()=>{}}},emits:["change","contentChange","routeUrl","clickTrigger"],setup(l,{emit:r}){const n=()=>{y.value=!1,f.value=!1,v.value=[]},o=l;a.computed(()=>{var aa;const ve=(aa=me.value)==null?void 0:aa.split("/");return(ve==null?void 0:ve.some(Pe=>(Pe==null?void 0:Pe.includes("updateLoading"))||(Pe==null?void 0:Pe.includes("loading"))))?!1:X.value==="view"});const s=r,c=a.ref([]),y=a.ref(!1),f=a.ref(!1),v=a.ref([]),{getFileExtension:m}=bi.useThreeSystem(),u=a.ref(),x=a.ref(!1),E=a.ref(!1),B=I.useUnit(I.pinia),{chooseTitle:w}=I.storeToRefs(B),V=a.ref([]),A=a.ref(),N=a.ref(!1),Y=a.ref([]),b=Zs(I.pinia),$=xt(I.pinia),T=a.ref(!1),k=a.ref(),_=a.ref(),U=a.ref(),W=I.useLoginState(I.pinia),{loginUserInfo:ce}=I.storeToRefs(W),Ee=a.ref(),Ie=a.ref(!0),De=I.useModelComp(I.pinia),{tableViewContents:ne,itemData:ge,isEdit:X,routeToChildPath:de,lockingPage:Ke}=I.storeToRefs(De),Ta=a.ref(null),oe=a.ref(!1),S=a.ref(!1),le=I.useMenuState(),{activeMenuPath:me}=I.storeToRefs(le),ue=ca.useOriginalState(I.pinia),{originalPath:Ne}=I.storeToRefs(ue),{compType:pa,hasEditable:_a}=Hs.useRole(),Wa=()=>!_a(o.config,{type:pa.FORM});a.computed(()=>me.value==="设备管理/试验设备"&&o.compName==="设备概要");const ee=a.ref([]),la=a.ref([{label:"编辑",value:"operable",checked:!1},{label:"禁用",value:"disabled",checked:!1}]),Ve=async ve=>{S.value=ve,await Fa("disabled",null,ve,!0)},ka=async ve=>{await Fa("operable",null,ve,!0)};a.watch(()=>me.value,async()=>{c.value=[],v.value=[]},{deep:!0,immediate:!0});const He=()=>{a.nextTick(()=>{Ga()})},Te=ve=>{var Xe;c.value=(Xe=c.value)==null?void 0:Xe.map(aa=>({...aa,isFormColHidden:!(ve!=null&&ve.includes(aa.label))}))};a.onUnmounted(()=>{Ta.value=null});const Re=ve=>{s("clickTrigger",ve)},Ge=async ve=>{var Xe,aa,Pe,xa,Le,va;if(ve===""){let re="";(Xe=c.value)==null||Xe.forEach(Ye=>{Ye!=null&&Ye.isMain&&(re=Ye==null?void 0:Ye.value)});let Ce=await ca.getItemData(de.value,sessionStorage.getItem("systemKey"),"");re=((va=(Le=(xa=(Pe=(aa=Ce==null?void 0:Ce[0])==null?void 0:aa.compData)==null?void 0:Pe.find(Ye=>(Ye==null?void 0:Ye.key)==="mainRouters"))==null?void 0:xa.contents)==null?void 0:Le[0])==null?void 0:va.routerContent)+Ne.value+re;let fa=await ca.getItemData(re,sessionStorage.getItem("systemKey"),"");N.value=!0,Y.value=fa==null?void 0:fa.filter(Ye=>(Ye==null?void 0:Ye.comp)!=="methodButton"),s("routeUrl",Y.value)}},Ga=()=>{var Xe;const ve=(Xe=Ta.value)==null?void 0:Xe.$el;ve&&Pa.Sortable.create(ve,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:aa=>{const{oldIndex:Pe,newIndex:xa}=aa;if(Pe===xa)return;const Le=c.value.splice(Pe,1)[0];c.value.splice(xa,0,Le)}})},Fa=async(ve,Xe,aa,Pe=!1)=>{try{De.setRefreshCurStructure(!1)}catch{rl.ElMessage.error("编辑处理失败")}},P=async(ve,Xe)=>{await Fa()},F=async(ve,Xe)=>{ve&&await Fa()},J=async(ve,Xe,aa)=>{await Fa(Xe,aa,ve,!1)},ie=(ve,Xe)=>{Ee.value===Xe?Ie.value=!1:Ie.value=!0,Ee.value=Xe==null?void 0:Xe.changeProp},se=async ve=>{var aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye,Ma,Ue,Ya,ga,ba;let Xe=[];if((aa=ve==null?void 0:ve.toString())!=null&&aa.includes(".urdf")){if(ve.includes(",")){rl.ElMessage.error("当前版本仅允许单个urdf预览!");return}v.value=[{url:ve,extension:m(ve)}],f.value=!0,y.value=!0;return}if((Pe=ve==null?void 0:ve.toString())!=null&&Pe.includes(".stl")||(xa=ve==null?void 0:ve.toString())!=null&&xa.includes(".STL")||(Le=ve==null?void 0:ve.toString())!=null&&Le.includes(".obj")||(va=ve==null?void 0:ve.toString())!=null&&va.includes(".mtl")){const Sa=((re=ve==null?void 0:ve.toString())==null?void 0:re.split(",")).map(Na=>({url:Na,extension:m(Na)}));v.value=Sa,f.value=!1,y.value=!0;return}if((Ce=ve==null?void 0:ve.toString())!=null&&Ce.includes(".stl")||(Z=ve==null?void 0:ve.toString())!=null&&Z.includes(".STL")||(fa=ve==null?void 0:ve.toString())!=null&&fa.includes(".obj")||(Ye=ve==null?void 0:ve.toString())!=null&&Ye.includes(".mtl")){let $a,Sa=[],Na={};if(Array.isArray(ve)?$a=ve:$a=ve==null?void 0:ve.split(","),$a==null||$a.forEach(Oa=>{Oa.includes(".mtl")?Sa.push(Oa):Na.blob=Na.blob?Na.blob+","+Oa:Oa}),(Sa==null?void 0:Sa.length)>0&&(Na.mtlBlobs=Sa),(Ue=(Ma=Object.values(Na))==null?void 0:Ma[0])!=null&&Ue.includes("http:"))Xe.push(Na);else{const Oa=new Blob([Na.blob],{type:"application/octet-stream;charset=UTF-8"});let Be=URL.createObjectURL(Oa),tl="";(Ya=ve==null?void 0:ve.split("/"))==null||Ya.forEach((Ea,El)=>{var ml;El===((ml=ve==null?void 0:ve.split("/"))==null?void 0:ml.length)-1&&(tl=Ea)}),(ga=Na.blob)!=null&&ga.includes(".stl")&&(tl=(tl==null?void 0:tl.replaceAll(">",""))+".urdf"),A.value=[{name:tl,blobUrl:Be}],E.value=!0}}else{const $a=I.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),Sa=await rl.axios.get(ve,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{$a.close()}),Na=new Blob([Sa.data],{type:"application/octet-stream;charset=UTF-8"});let Oa=URL.createObjectURL(Na),Be="";(ba=ve==null?void 0:ve.split("/"))==null||ba.forEach((tl,Ea)=>{var El;Ea===((El=ve==null?void 0:ve.split("/"))==null?void 0:El.length)-1&&(Be=tl)}),A.value=[{name:Be,blobUrl:Oa}],E.value=!0}(Xe==null?void 0:Xe.length)>0&&$.setBlobUrls(Xe)},ma=()=>{E.value=!1},oa=ve=>{var Le,va,re,Ce;const Xe=(va=(Le=pl.safeClone(o.itemData))==null?void 0:Le.find(Z=>(Z==null?void 0:Z.key)==="formContent"))==null?void 0:va.contents,aa=pl.safeClone(ve.content);let Pe={};aa&&((re=Object.values(aa))==null?void 0:re.length)>0&&((Ce=Object.values(aa))==null||Ce.forEach((Z,fa)=>{Pe[Xe[fa].key]=Z}));const xa={content:Pe,index:o==null?void 0:o.index,buttonName:ve==null?void 0:ve.buttonName};s("change",xa)};a.computed(()=>"http://222.92.178.198:62001");const Oe=async ve=>{var Ma,Ue,Ya,ga,ba,$a,Sa,Na,Oa,Be,tl,Ea,El,ml,Fe,Va;if(!ve)return;(Ue=(Ma=o==null?void 0:o.itemData)==null?void 0:Ma.find(je=>(je==null?void 0:je.key)==="parentFormPath"))==null||Ue.contents;let Xe=ne.value;(Xe==null?void 0:Xe.length)>0&&(Xe=Xe==null?void 0:Xe.map(je=>{var Ze,Je,ea,q;let xe=(Ze=je==null?void 0:je.key)==null?void 0:Ze.split("/");return(o==null?void 0:o.compName)===(xe==null?void 0:xe[0])&&(Je=c.value)!=null&&Je.find(ra=>(ra==null?void 0:ra.prop)===(xe==null?void 0:xe[1]))&&(je.value=(q=(ea=c.value)==null?void 0:ea.find(ra=>(ra==null?void 0:ra.prop)===(xe==null?void 0:xe[1])))==null?void 0:q.value),je}),De.setTableViewContents(Xe));const aa=pl.safeClone(o.itemData);let Pe=aa==null?void 0:aa.map(je=>{var xe;return(je==null?void 0:je.key)==="formContent"&&((xe=je.contents)==null||xe.map((Ze,Je)=>{var ea,q,ra,ya,we,Se,qa,fe,fl,Qa,_l,Ha,il,Ia,ul,Ja,Wl,Kl,$l;return Ze.type=(q=(ea=c.value)==null?void 0:ea.find(Fl=>(Fl==null?void 0:Fl.prop)===(Ze==null?void 0:Ze.prop)))==null?void 0:q.type,Ze.options=Ze!=null&&Ze.options?Ze.options:((we=(ya=(ra=Ze==null?void 0:Ze.key)==null?void 0:ra.split("$"))==null?void 0:ya[1])==null?void 0:we.length)>0?(fl=(fe=wu((qa=(Se=Ze==null?void 0:Ze.key)==null?void 0:Se.split("$"))==null?void 0:qa[1]))==null?void 0:fe.split(","))==null?void 0:fl.map(Fl=>({label:Fl,value:Fl})):[],(Qa=Ze==null?void 0:Ze.key)!=null&&Qa.includes("$")&&(Ze.key=(Ha=(_l=Ze==null?void 0:Ze.key)==null?void 0:_l.split("$"))==null?void 0:Ha[0]),Ze.signature=(Ia=(il=c.value)==null?void 0:il.find(Fl=>(Fl==null?void 0:Fl.prop)===(Ze==null?void 0:Ze.prop)))==null?void 0:Ia.signature,Ze.isLoginUser=(Ja=(ul=c.value)==null?void 0:ul.find(Fl=>(Fl==null?void 0:Fl.prop)===(Ze==null?void 0:Ze.prop)))==null?void 0:Ja.isLoginUser,Ze.value=(Wl=Object.values(ve))==null?void 0:Wl[Je],Ze.isFormColHidden=($l=(Kl=c.value)==null?void 0:Kl.find(Fl=>(Fl==null?void 0:Fl.prop)===(Ze==null?void 0:Ze.prop)))==null?void 0:$l.isFormColHidden,Ze})),je}),xa=c.value,Le=(ga=(Ya=pl.safeClone(Pe))==null?void 0:Ya.find(je=>(je==null?void 0:je.key)==="formContent"))==null?void 0:ga.contents;if(xa=xa==null?void 0:xa.map(je=>{var xe,Ze;return(je==null?void 0:je.type)==="Select"&&((xe=je==null?void 0:je.allSelectionContents)==null?void 0:xe.length)>0&&(je.contactValue=ve),je.value=(Ze=Le==null?void 0:Le.find((Je,ea)=>((Je==null?void 0:Je.id)??ea)===(je==null?void 0:je.id)))==null?void 0:Ze.value,je}),!Ie.value){s("contentChange",{contents:Pe,index:o.index});return}let va="",re=(Sa=($a=(ba=pl.safeClone(Pe))==null?void 0:ba.find(je=>(je==null?void 0:je.key)==="formContent"))==null?void 0:$a.contents)==null?void 0:Sa.find((je,xe)=>{var Ze,Je,ea;return(je==null?void 0:je.label)===Ee.value||xe.toString()===((ea=(Je=(Ze=Ee.value)==null?void 0:Ze.split("t"))==null?void 0:Je[1])==null?void 0:ea.toString())}),Ce=(Na=re==null?void 0:re.optionUrl)==null?void 0:Na.menuSelect,Z=!0;if((tl=(Be=(Oa=pl.safeClone(Pe))==null?void 0:Oa.find(je=>(je==null?void 0:je.key)==="formContent"))==null?void 0:Be.contents)==null||tl.forEach(je=>{var xe,Ze,Je,ea,q,ra;Z&&((Je=(Ze=(xe=je==null?void 0:je.optionUrl)==null?void 0:xe.groupSelect)==null?void 0:Ze[1])!=null&&Je.includes("["))&&(va=(q=(ea=je==null?void 0:je.optionUrl)==null?void 0:ea.groupSelect)==null?void 0:q[1],JSON.stringify(Ce)===JSON.stringify((ra=je==null?void 0:je.optionUrl)==null?void 0:ra.menuSelect)&&(Z=!1))}),(Ea=re==null?void 0:re.optionUrl)!=null&&Ea.menuSelect&&Ie.value){let je=await pt(re),xe,Ze=(El=re==null?void 0:re.optionUrl)==null?void 0:El.menuSelect;if(je==null||je.forEach(Je=>{var ea,q,ra,ya,we,Se,qa,fe,fl,Qa;va===((q=(ea=re==null?void 0:re.optionUrl)==null?void 0:ea.groupSelect)==null?void 0:q[1])&&((we=(ya=(ra=re==null?void 0:re.optionUrl)==null?void 0:ra.groupSelect)==null?void 0:ya[1])!=null&&we.includes("["))&&((Qa=pl.safeClone(Je))==null?void 0:Qa[(fl=(fe=(qa=(Se=re==null?void 0:re.optionUrl)==null?void 0:Se.groupSelect)==null?void 0:qa[1])==null?void 0:fe.replaceAll("[",""))==null?void 0:fl.replaceAll("]","")])===(re==null?void 0:re.value)&&(xe=Je)}),xe){let Je=pl.safeClone(xa);Je=Je==null?void 0:Je.map(q=>{var ra,ya,we,Se,qa,fe,fl,Qa,_l,Ha,il;return(xe!=null&&xe[q==null?void 0:q.label]||xe!=null&&xe[(Se=(we=(ya=(ra=q==null?void 0:q.optionUrl)==null?void 0:ra.groupSelect)==null?void 0:ya[1])==null?void 0:we.replaceAll("[",""))==null?void 0:Se.replaceAll("]","")])&&((fl=(fe=(qa=q==null?void 0:q.optionUrl)==null?void 0:qa.groupSelect)==null?void 0:fe[1])!=null&&fl.includes("["))&&Ze!=null&&Ze.every(Ia=>{var ul,Ja;return(Ja=(ul=q==null?void 0:q.optionUrl)==null?void 0:ul.menuSelect)==null?void 0:Ja.includes(Ia)})&&(q.value=(xe==null?void 0:xe[q==null?void 0:q.label])||(xe==null?void 0:xe[(il=(Ha=(_l=(Qa=q==null?void 0:q.optionUrl)==null?void 0:Qa.groupSelect)==null?void 0:_l[1])==null?void 0:Ha.replaceAll("[",""))==null?void 0:il.replaceAll("]","")]),Array.isArray(q.value)&&q.value.every(Ia=>(Ia==null?void 0:Ia.url)&&(Ia==null?void 0:Ia.name))&&(q.type="Upload")),q}),Je=Je==null?void 0:Je.map(q=>{var ra,ya,we;return(ra=q==null?void 0:q.optionUrl)!=null&&ra.oldMenuSelect&&(q.optionUrl.menuSelect=(we=(ya=pl.safeClone(q))==null?void 0:ya.optionUrl)==null?void 0:we.oldMenuSelect),q}),c.value=pl.safeClone(Je);let ea=pl.safeClone(Je);ea=ea==null?void 0:ea.map(q=>{var ra,ya,we,Se,qa,fe;return(ya=(ra=q==null?void 0:q.optionUrl)==null?void 0:ra.menuSelect)!=null&&ya.some(fl=>fl==null?void 0:fl.includes("["))&&(q.optionUrl.oldMenuSelect=(Se=(we=pl.safeClone(q))==null?void 0:we.optionUrl)==null?void 0:Se.menuSelect,q.optionUrl.menuSelect=(fe=(qa=q==null?void 0:q.optionUrl)==null?void 0:qa.menuSelect)==null?void 0:fe.map(fl=>{var Qa,_l,Ha,il;if(fl!=null&&fl.includes("[")){let Ia=(_l=(Qa=fl==null?void 0:fl.replaceAll("[","").replaceAll("]",""))==null?void 0:Qa.split(":"))==null?void 0:_l[1];fl=(il=(Ha=pl.safeClone(Je))==null?void 0:Ha.find(ul=>(ul==null?void 0:ul.label)===Ia))==null?void 0:il.value}return fl})),q}),c.value=ea}else c.value=xa;Pe=Pe==null?void 0:Pe.map(Je=>{var ea;return(Je==null?void 0:Je.key)==="formContent"&&(Je.contents=(ea=Je.contents)==null?void 0:ea.map(q=>{var ra,ya,we,Se;return q.value=((ya=(ra=c.value)==null?void 0:ra.find(qa=>(qa==null?void 0:qa.label)===(q==null?void 0:q.key)))==null?void 0:ya.value)??(q==null?void 0:q.value),q.type=((Se=(we=c.value)==null?void 0:we.find(qa=>(qa==null?void 0:qa.prop)===(q==null?void 0:q.key)))==null?void 0:Se.type)??(q==null?void 0:q.type),q})),Je})}Ie.value=!1,s("contentChange",{contents:Pe,index:o.index});let fa=[],Ye=[];if((Fe=pl.safeClone((ml=Pe==null?void 0:Pe.find(je=>(je==null?void 0:je.key)==="formContent"))==null?void 0:ml.contents))==null||Fe.forEach(je=>{var xe;Array.isArray(je==null?void 0:je.value)&&((xe=je==null?void 0:je.value)!=null&&xe.find(Ze=>{var Je;return(Je=Ze==null?void 0:Ze.url)==null?void 0:Je.includes(".obj")}))&&(Ye=je==null?void 0:je.value)}),(Ye==null?void 0:Ye.length)>0){const je=(Va=pl.safeClone(Ye))==null?void 0:Va.filter(xe=>{var Ze;return(Ze=xe==null?void 0:xe.url)==null?void 0:Ze.includes(".obj")});je==null||je.forEach(xe=>{var Je,ea,q,ra;const Ze=(Je=Ye==null?void 0:Ye.filter(ya=>{var we;return(ya==null?void 0:ya.name)===(xe==null?void 0:xe.name)&&((we=ya==null?void 0:ya.url)==null?void 0:we.includes(".mtl"))}))==null?void 0:Je.map(ya=>ya==null?void 0:ya.url);fa.push({objUrl:xe==null?void 0:xe.url,mtlUrls:((ea=Ye==null?void 0:Ye.filter(ya=>{var we;return(ya==null?void 0:ya.name)===(xe==null?void 0:xe.name)&&((we=ya==null?void 0:ya.url)==null?void 0:we.includes(".mtl"))}))==null?void 0:ea.length)===1?(ra=(q=Ye==null?void 0:Ye.filter(ya=>{var we;return(ya==null?void 0:ya.name)===(xe==null?void 0:xe.name)&&((we=ya==null?void 0:ya.url)==null?void 0:we.includes(".mtl"))}))==null?void 0:q[0])==null?void 0:ra.url:Ze})}),$.setObjUrl(fa)}},_e=(ve,Xe,aa)=>{let Pe="";const xa=Xe==null?void 0:Xe.map(Le=>{var va;return(va=Le==null?void 0:Le.value)==null?void 0:va.pageData});return xa==null||xa.forEach(Le=>{var va;(Le==null?void 0:Le.name)===(ve==null?void 0:ve[0])&&((va=Le==null?void 0:Le.compData)==null||va.forEach(re=>{var Ce;(re==null?void 0:re.key)==="formContent"&&((Ce=re==null?void 0:re.contents)==null||Ce.forEach(Z=>{var fa;(Z==null?void 0:Z.prop)===(ve==null?void 0:ve[1])&&(Pe=(Z==null?void 0:Z.value)===""?ca.judgeContents((fa=pl.safeClone(Z))==null?void 0:fa.optionUrl,aa):Z==null?void 0:Z.value)}))}))}),Pe},wa=(ve,Xe,aa,Pe)=>{var re,Ce;let xa="",Le="";(re=pl.safeClone(Xe))==null||re.forEach((Z,fa)=>{Z!=null&&Z.includes("[")?Le=Le+Ne.value+ve[fa]:Le=Le===""?Le+Z:Le+"/"+Z});let va=(Ce=Pe[Le])==null?void 0:Ce.map(Z=>{var fa;return(fa=Z==null?void 0:Z.value)==null?void 0:fa.pageData});return va==null||va.forEach(Z=>{var fa;(Z==null?void 0:Z.name)===(aa==null?void 0:aa[0])&&((fa=Z==null?void 0:Z.compData)==null||fa.forEach(Ye=>{var Ma;(Ye==null?void 0:Ye.key)==="formContent"&&((Ma=Ye==null?void 0:Ye.contents)==null||Ma.forEach(Ue=>{(Ue==null?void 0:Ue.prop)===(aa==null?void 0:aa[1])&&(xa=Ue==null?void 0:Ue.value)}))}))}),xa};return a.watch(()=>o.itemData,async()=>{var fa,Ye,Ma,Ue,Ya,ga,ba,$a,Sa,Na,Oa,Be,tl,Ea,El,ml,Fe,Va,je,xe,Ze;const ve=(fa=o.itemData)==null?void 0:fa.find(Je=>(Je==null?void 0:Je.key)==="formContent"),Xe=(Ye=pl.safeClone(o.itemData))==null?void 0:Ye.find(Je=>(Je==null?void 0:Je.key)==="formButton"),aa=(Ma=pl.safeClone(o.itemData))==null?void 0:Ma.find(Je=>(Je==null?void 0:Je.key)==="formFlex"),Pe=(Ue=pl.safeClone(o.itemData))==null?void 0:Ue.find(Je=>(Je==null?void 0:Je.key)==="formWrap"),xa=(Ya=pl.safeClone(o.itemData))==null?void 0:Ya.find(Je=>(Je==null?void 0:Je.key)==="enableWrap"),Le=(ga=pl.safeClone(o.itemData))==null?void 0:ga.find(Je=>(Je==null?void 0:Je.key)==="textSize"),va=(ba=pl.safeClone(o.itemData))==null?void 0:ba.find(Je=>(Je==null?void 0:Je.key)==="textRGBA");(Pe==null?void 0:Pe.contents)==="纵向"?x.value=!1:x.value=!0;const re=Number(Le==null?void 0:Le.contents);k.value=Number.isNaN(re)?void 0:re,_.value=va==null?void 0:va.contents;const Ce=xa==null?void 0:xa.contents;if(Ce===void 0?T.value=ao.BLOCK:typeof Ce=="boolean"?T.value=Ce?ao.ORDINARY:ao.BLOCK:T.value=Ce,U.value=typeof(aa==null?void 0:aa.contents)!="boolean"?!(!(aa!=null&&aa.contents)===""||(($a=aa==null?void 0:aa.contents)==null?void 0:$a.toUpperCase())==="VERTICAL"):aa==null?void 0:aa.contents,((Sa=ve==null?void 0:ve.contents)==null?void 0:Sa.length)>0&&Array.isArray(ve==null?void 0:ve.contents)){let Je=o.allMapContents;const ea=(Oa=(Na=pl.safeClone(ve))==null?void 0:Na.contents)==null?void 0:Oa.map((fe,fl)=>{var kr,wr,Er,un,Jr,dn,Xr,qr,pn,on,Dr,Zr,Nr;let Qa=(fe==null?void 0:fe.label)??(fe==null?void 0:fe.key)??"";fe==null||fe.type;let _l=(fe==null?void 0:fe.options)??[];if((kr=fe==null?void 0:fe.key)!=null&&kr.includes("$")&&(Qa=(wr=pl.safeClone(fe==null?void 0:fe.key).split("$"))==null?void 0:wr[0],((un=(Er=pl.safeClone(fe==null?void 0:fe.key).split("$"))==null?void 0:Er[1])==null?void 0:un.length)>0)){const[Il,Wr]=(dn=(Jr=pl.safeClone(fe==null?void 0:fe.key).split("$"))==null?void 0:Jr[1])==null?void 0:dn.split(/[()]/);(Xr=ca.FormType.find(Br=>(Br==null?void 0:Br.key)===Il))==null||Xr.value,((qr=Wr==null?void 0:Wr.split(","))==null?void 0:qr.length)>0&&(_l=(pn=Wr==null?void 0:Wr.split(","))==null?void 0:pn.map(Br=>({label:Br,value:Br})))}let Ha=fe==null?void 0:fe.options;((on=fe==null?void 0:fe.optionUrl)==null?void 0:on.selectRelateType)==="自定义绑定"&&(Ha=(Zr=(Dr=fe==null?void 0:fe.optionUrl)==null?void 0:Dr.defaultSelect)==null?void 0:Zr.map(Il=>({label:Il,value:Il})));let il=(fe==null?void 0:fe.menuPath)??[],Ia=(fe==null?void 0:fe.groups)??[],ul=(fe==null?void 0:fe.columns)??[],Ja=!1,Wl=(fe==null?void 0:fe.isFormColHidden)??!1,Kl="",$l=fe!=null&&fe.value?fe.value:(Ha==null?void 0:Ha.length)>0?(Nr=Ha==null?void 0:Ha[0])==null?void 0:Nr.value:(fe==null?void 0:fe.value)??"",Fl=!1,gr="Input";return((Ha==null?void 0:Ha.length)>0||(il==null?void 0:il.length)>0)&&(gr="Select"),(Array.isArray(Kl)&&(Kl!=null&&Kl.every(Il=>(Il==null?void 0:Il.name)&&(Il==null?void 0:Il.url)))||Array.isArray($l)&&($l!=null&&$l.every(Il=>(Il==null?void 0:Il.name)&&(Il==null?void 0:Il.url))))&&(gr="upload"),fe!=null&&fe.isMainUrl&&(gr="Url"),{label:Qa??"",name:Qa??"t"+fl,prop:Qa??pl.safeClone(fe==null?void 0:fe.key),type:(fe==null?void 0:fe.type)??gr,value:(fe==null?void 0:fe.type)==="Date"&&$l===""?new Date:$l,id:(fe==null?void 0:fe.id)??fl,contents:(Ha==null?void 0:Ha.length)>0?Ha:_l??[],width:(fe==null?void 0:fe.width)??1,isLoginUser:Ja,config:fe==null?void 0:fe.config,optionUrl:(fe==null?void 0:fe.optionUrl)??fe,isFormColHidden:Wl,signature:Fl,isMain:fe==null?void 0:fe.isMain,required:(fe==null?void 0:fe.required)??!1,isMainUrl:fe==null?void 0:fe.isMainUrl,operable:(fe==null?void 0:fe.operable)??!1,disabled:(fe==null?void 0:fe.disabled)??!1,isSync:fe==null?void 0:fe.isSync,menus:il,groups:Ia,words:ul,allSelectionContents:fe==null?void 0:fe.allContents,filterContent:fe==null?void 0:fe.filterContents}}),q=ea==null?void 0:ea.map(fe=>fe==null?void 0:fe.value);let ra="";q==null||q.forEach(fe=>{fe!==""&&fe!==void 0&&(ra=ra===""?fe:ra+"/"+fe)}),b.setSelectArray(q),b.setSelectString(ra);let ya=(Be=pl.safeClone(ea))==null?void 0:Be.map(fe=>(fe!=null&&fe.value&&ca.IsJson(fe==null?void 0:fe.value)&&Array.isArray(JSON.parse(fe==null?void 0:fe.value))&&(fe.value=JSON.parse(fe.value)),fe)),we={};ya==null||ya.forEach(fe=>{we[fe.label]=fe==null?void 0:fe.value}),ya=ya==null?void 0:ya.map(fe=>{var fl,Qa,_l,Ha,il,Ia,ul,Ja,Wl;if((fe==null?void 0:fe.type)==="Select"&&((fl=fe==null?void 0:fe.allSelectionContents)==null?void 0:fl.length)>0&&(fe.contactValue=we),(_l=(Qa=fe==null?void 0:fe.optionUrl)==null?void 0:Qa.menuSelect)!=null&&_l.some(Kl=>Kl==null?void 0:Kl.includes("["))){let Kl="";fe.optionUrl.oldMenuSelect=(il=(Ha=pl.safeClone(fe))==null?void 0:Ha.optionUrl)==null?void 0:il.menuSelect,fe.optionUrl.menuSelect=(ul=(Ia=fe==null?void 0:fe.optionUrl)==null?void 0:Ia.menuSelect)==null?void 0:ul.map($l=>{var Fl,gr,rr,kr,wr,Er;if($l!=null&&$l.includes("[")){let un=(gr=(Fl=$l==null?void 0:$l.replaceAll("[","").replaceAll("]",""))==null?void 0:Fl.split(":"))==null?void 0:gr[1];Kl=_e((rr=$l==null?void 0:$l.replaceAll("[","").replaceAll("]",""))==null?void 0:rr.split(":"),Je==null?void 0:Je[me.value],Je),$l=((wr=(kr=pl.safeClone(ya))==null?void 0:kr.find(Jr=>(Jr==null?void 0:Jr.label)===un))==null?void 0:wr.value)||_e((Er=$l==null?void 0:$l.replaceAll("[","").replaceAll("]",""))==null?void 0:Er.split(":"),Je==null?void 0:Je[me.value],Je)}return $l}),Kl!==""&&fe.value===""&&(fe.value=wa(fe.optionUrl.menuSelect,fe.optionUrl.oldMenuSelect,(Ja=fe==null?void 0:fe.optionUrl)==null?void 0:Ja.groupSelect,Je),Array.isArray(fe.value)&&((Wl=fe.value)!=null&&Wl.every($l=>$l==null?void 0:$l.url))&&(fe.type="UPLOAD"))}return fe}),c.value=ya,S.value=((tl=c.value)==null?void 0:tl.every(fe=>fe==null?void 0:fe.disabled))||Ke.value===me.value,oe.value=(Ea=c.value)==null?void 0:Ea.every(fe=>fe==null?void 0:fe.operable),ee.value=(El=c.value)==null?void 0:El.map(fe=>fe==null?void 0:fe.label);let Se=[],qa=[];if((ml=pl.safeClone(c.value))==null||ml.forEach(fe=>{var fl;Array.isArray(fe==null?void 0:fe.value)&&((fl=fe==null?void 0:fe.value)!=null&&fl.find(Qa=>{var _l;return(_l=Qa==null?void 0:Qa.url)==null?void 0:_l.includes(".obj")}))&&(qa=fe==null?void 0:fe.value)}),(qa==null?void 0:qa.length)>0){const fe=(Fe=pl.safeClone(qa))==null?void 0:Fe.filter(fl=>{var Qa;return(Qa=fl==null?void 0:fl.url)==null?void 0:Qa.includes(".obj")});fe==null||fe.forEach(fl=>{var _l,Ha,il,Ia;const Qa=(_l=qa==null?void 0:qa.filter(ul=>{var Ja;return(ul==null?void 0:ul.name)===(fl==null?void 0:fl.name)&&((Ja=ul==null?void 0:ul.url)==null?void 0:Ja.includes(".mtl"))}))==null?void 0:_l.map(ul=>ul==null?void 0:ul.url);Se.push({objUrl:fl==null?void 0:fl.url,mtlUrls:((Ha=qa==null?void 0:qa.filter(ul=>{var Ja;return(ul==null?void 0:ul.name)===(fl==null?void 0:fl.name)&&((Ja=ul==null?void 0:ul.url)==null?void 0:Ja.includes(".mtl"))}))==null?void 0:Ha.length)===1?(Ia=(il=qa==null?void 0:qa.filter(ul=>{var Ja;return(ul==null?void 0:ul.name)===(fl==null?void 0:fl.name)&&((Ja=ul==null?void 0:ul.url)==null?void 0:Ja.includes(".mtl"))}))==null?void 0:il[0])==null?void 0:Ia.url:Qa})}),$.setObjUrl(Se)}(Va=pl.safeClone(c.value))==null||Va.forEach(fe=>{var fl,Qa,_l,Ha,il,Ia,ul,Ja,Wl,Kl,$l,Fl,gr;if((Qa=(fl=fe==null?void 0:fe.value)==null?void 0:fl.toString())!=null&&Qa.includes(".stl")||(Ha=(_l=fe==null?void 0:fe.value)==null?void 0:_l.toString())!=null&&Ha.includes(".STL")||(Ia=(il=fe==null?void 0:fe.value)==null?void 0:il.toString())!=null&&Ia.includes(".obj")||(Ja=(ul=fe==null?void 0:fe.value)==null?void 0:ul.toString())!=null&&Ja.includes(".mtl")||(Kl=(Wl=fe==null?void 0:fe.value)==null?void 0:Wl.toString())!=null&&Kl.includes(".urdf")){let rr={},kr=[],wr;Array.isArray(fe==null?void 0:fe.value)?wr=fe==null?void 0:fe.value:wr=($l=fe==null?void 0:fe.value)==null?void 0:$l.split(","),wr==null||wr.forEach(Er=>{Er.includes(".mtl")?kr.push(Er):rr.blob=rr.blob==="undefined"?Er:rr.blob+","+Er}),(kr==null?void 0:kr.length)>0&&(rr.mtlBlobs=kr),(gr=(Fl=Object.values(rr))==null?void 0:Fl[0])!=null&&gr.includes("http:")}})}else c.value=[];let Z=ne.value;if((Z==null?void 0:Z.length)>0&&(Z=Z==null?void 0:Z.map(Je=>{var q,ra,ya,we;let ea=(q=Je==null?void 0:Je.key)==null?void 0:q.split("/");return(o==null?void 0:o.compName)===(ea==null?void 0:ea[0])&&(ra=c.value)!=null&&ra.find(Se=>(Se==null?void 0:Se.prop)===(ea==null?void 0:ea[1]))&&(Je.value=(we=(ya=c.value)==null?void 0:ya.find(Se=>(Se==null?void 0:Se.prop)===(ea==null?void 0:ea[1])))==null?void 0:we.value),Je}),De.setTableViewContents(Z)),o!=null&&o.formRules)u.value=o==null?void 0:o.formRules;else{let Je={};(je=pl.safeClone(c).value)==null||je.forEach(ea=>{((ea==null?void 0:ea.isMain)===!0||(ea==null?void 0:ea.required)===!0)&&(Je[(ea==null?void 0:ea.prop)??(ea==null?void 0:ea.name)]=[{required:!0,message:`${(ea==null?void 0:ea.label)||(ea==null?void 0:ea.prop)||(ea==null?void 0:ea.name)}不能为空`}])}),u.value=Je}if(((xe=Xe==null?void 0:Xe.contents)==null?void 0:xe.length)>0){const Je=[];(Ze=Xe==null?void 0:Xe.contents)==null||Ze.forEach((ea,q)=>{(ea==null?void 0:ea.label)!==""&&Je.push({label:(ea==null?void 0:ea.label)??"",id:(ea==null?void 0:ea.id)??q,type:(ea==null?void 0:ea.type)??"",background:ea==null?void 0:ea.background})}),V.value=Je}else V.value=[]},{deep:!0,immediate:!0}),a.watch(()=>Ke.value,ve=>{S.value=ve===me.value},{immediate:!0}),(ve,Xe)=>{var re,Ce;const aa=a.resolveComponent("svg-icon"),Pe=a.resolveComponent("el-switch"),xa=a.resolveComponent("el-checkbox"),Le=a.resolveComponent("el-popover"),va=a.resolveComponent("el-checkbox-group");return a.openBlock(),a.createElementBlock("div",y3,[T.value===a.unref(ao).TEXT?(a.openBlock(),a.createBlock(yc,{key:0,itemData:l.itemData,compName:l.compName,fields:c.value,textSize:k.value,textColor:_.value,disabled:S.value||Wa()},null,8,["itemData","compName","fields","textSize","textColor","disabled"])):T.value===a.unref(ao).BLOCK?(a.openBlock(),a.createBlock(ef,{key:1,items:(Ce=(re=c.value)==null?void 0:re.filter(Z=>!(Z!=null&&Z.isFormColHidden)))==null?void 0:Ce.map(Z=>({label:Z==null?void 0:Z.label,value:Z==null?void 0:Z.value,width:(Z==null?void 0:Z.width)??1,field:Z})),textSize:k.value,textColor:_.value,disabled:S.value||Wa()},null,8,["items","textSize","textColor","disabled"])):(a.openBlock(),a.createElementBlock("div",{key:2,class:a.normalizeClass({"form-shadow-box":T.value===a.unref(ao).ORDINARY})},[a.createVNode(pl.ssForm,{rowContents:c.value,formRules:u.value,buttonValue:V.value,isRowFlex:!1,isEnableWrap:!0,textSize:k.value,textColor:_.value,onOnButtonClick:oa,onChange:Oe,formDisabled:S.value||Wa(),formLabelsOperable:oe.value,isButtonRow:x.value,onPreview:se,onBlurChange:ie,onHandleColEditChange:P,onHandleColTypeChange:F,onRouteUrl:Ge,onClickTrigger:Re},{operateCol:a.withCtx(({renderColumns:Z,formDisabled:fa,formLabelsOperable:Ye})=>[a.createVNode(Le,{title:"选择操作的标签",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:He},{reference:a.withCtx(()=>[a.createElementVNode("span",g3,[a.createVNode(aa,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"}})])]),default:a.withCtx(()=>[a.createElementVNode("div",b3,[Xe[1]||(Xe[1]=a.createElementVNode("div",{class:"group-title"},"表单操作",-1)),a.createVNode(Pe,{"model-value":fa,"active-text":"禁用","inactive-text":"",onChange:Ve,style:{"margin-right":"8px"}},null,8,["model-value"]),a.createVNode(Pe,{"model-value":Ye,"active-text":"编辑所有标签","inactive-text":"",onChange:ka},null,8,["model-value"]),Xe[2]||(Xe[2]=a.createElementVNode("div",{class:"group-title"},"表单列操作",-1)),a.createVNode(va,{modelValue:ee.value,"onUpdate:modelValue":Xe[0]||(Xe[0]=Ma=>ee.value=Ma),style:{height:"100%"},ref_key:"checkboxGroupRef",ref:Ta,onChange:Te},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(Z,Ma=>(a.openBlock(),a.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:Ma.label},[a.createVNode(xa,{value:Ma.label,style:{width:"100%",marginRight:0}},{default:a.withCtx(()=>[a.createElementVNode("span",null,a.toDisplayString(Ma.label),1)]),_:2},1032,["value"]),a.createVNode(Le,{title:"标签操作",placement:"left",teleported:!1,trigger:"hover"},{reference:a.withCtx(()=>[a.createVNode(aa,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:a.withCtx(()=>{var Ue;return[a.createElementVNode("div",k3,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList((Ue=Object.keys(Ma))==null?void 0:Ue.filter(Ya=>{var ga;return(ga=la.value)==null?void 0:ga.find(ba=>(ba==null?void 0:ba.value)===Ya)}),Ya=>{var ga,ba;return a.openBlock(),a.createElementBlock("div",{key:Ya},[a.createVNode(pl._sfc_main$1,{value:Ma==null?void 0:Ma[Ya],"active-text":(ba=(ga=la.value)==null?void 0:ga.find($a=>($a==null?void 0:$a.value)===Ya))==null?void 0:ba.label,inactiveText:"",onChange:$a=>J($a,Ya,Ma)},null,8,["value","active-text","onChange"])])}),128))])]}),_:2},1024),a.createElementVNode("span",x3,[a.createVNode(aa,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:2},1032,["modelValue"])])]),_:2},1024)]),_:1},8,["rowContents","formRules","buttonValue","textSize","textColor","formDisabled","formLabelsOperable","isButtonRow"])],2)),E.value?(a.openBlock(),a.createBlock(pl.ssFilePreview,{key:3,fileDataList:A.value,onDestroy:ma},null,8,["fileDataList"])):a.createCommentVNode("",!0),y.value?(a.openBlock(),a.createBlock(vr.ssDialog,{key:4,visible:y.value,onBeforeDestroy:n,style:{height:"700px",width:"1000px"}},{default:a.withCtx(()=>[a.createVNode(bi.ThreeViewerHost,{files:v.value,onGetAnimationData:ve.onAnimationData},null,8,["files","onGetAnimationData"])]),_:1},8,["visible"])):a.createCommentVNode("",!0)])}}},hs=ql._export_sfc(_3,[["__scopeId","data-v-c4708f41"]]),Di=a.ref(0),gc=l=>{var r;return!l||(l==null?void 0:l.length)===0?[]:(r=I.cloneDeep(l))==null?void 0:r.map(o=>(Di.value++,o={label:(o==null?void 0:o.label)??"",prop:(o==null?void 0:o.label)==="操作"?"operate":o==null?void 0:o.prop,width:o!=null&&o.width?parseInt(o.width):"",fixed:(o==null?void 0:o.fixed)??void 0,sortable:(o==null?void 0:o.sortable)??!1,align:(o==null?void 0:o.align)??"left",showOverflowTooltip:(o==null?void 0:o.showOverflowTooltip)??!0,isNotDrag:(o==null?void 0:o.isNotDrag)??!1,isEditCol:(o==null?void 0:o.isEditCol)??!1,isOperate:(o==null?void 0:o.isOperate)??!1,id:(o==null?void 0:o.id)??Di.value,children:gc(o==null?void 0:o.children)},o))},w3=l=>{var n;return(n=I.cloneDeep(l))==null?void 0:n.map(o=>(Di.value++,o={label:(o==null?void 0:o.label)??"",prop:(o==null?void 0:o.label)==="操作"?"operate":o==null?void 0:o.prop,width:o!=null&&o.width?parseInt(o.width):"",fixed:(o==null?void 0:o.fixed)??void 0,sortable:(o==null?void 0:o.sortable)??!1,align:(o==null?void 0:o.align)??"left",showOverflowTooltip:(o==null?void 0:o.showOverflowTooltip)??!0,isNotDrag:(o==null?void 0:o.isNotDrag)??!1,isEditCol:(o==null?void 0:o.isEditCol)??!1,isOperate:(o==null?void 0:o.isOperate)??!1,id:(o==null?void 0:o.id)??Di.value,children:gc(o==null?void 0:o.children)},o))},bc=(l,r)=>{var n;return l!=null&&l.find(o=>(o==null?void 0:o.id)===r)?(n=I.cloneDeep(l))==null?void 0:n.filter(s=>(s==null?void 0:s.id)!==r):(l=l==null?void 0:l.map(o=>(o.children=bc(o==null?void 0:o.children,r),o)),l)},kc=(l,r)=>{var n;return l!=null&&l.find(o=>(o==null?void 0:o.id)===(r==null?void 0:r.id))?(n=I.cloneDeep(l))==null?void 0:n.map(s=>((s==null?void 0:s.id)===(r==null?void 0:r.id)&&(s=r),s)):(l=l==null?void 0:l.map(o=>(o.children=kc(o==null?void 0:o.children,r),o)),l)},xc=(l,r)=>{var n;return l!=null&&l.find(o=>{var s;return(o==null?void 0:o.id)===((s=r==null?void 0:r.contents)==null?void 0:s.id)})?(n=I.cloneDeep(l))==null?void 0:n.map(s=>{var c;return(s==null?void 0:s.id)===((c=r==null?void 0:r.contents)==null?void 0:c.id)&&(s=r==null?void 0:r.contents),s}):(l=l==null?void 0:l.map(o=>(o.children=xc(o==null?void 0:o.children,r),o)),l)},_c=(l,r)=>{var n;return l!=null&&l.find(o=>(o==null?void 0:o.id)===(r==null?void 0:r.id))?(n=I.cloneDeep(l))==null?void 0:n.map(s=>((s==null?void 0:s.id)===(r==null?void 0:r.id)&&(s!=null&&s.children||(s.children=[]),s.children.push(r.contents)),s)):(l=l==null?void 0:l.map(o=>(o.children=_c(o==null?void 0:o.children,r),o)),l)},Ql=[{key:"label",label:"标签名",type:"Input"},{key:"prop",label:"属性名",type:"Input"},{key:"width",label:"宽度",type:"Input"},{key:"sortable",label:"是否支持排序",type:"Switch"},{key:"align",label:"文本所在位置",type:"Radio",options:[{label:"left",value:"左"},{label:"center",value:"中"},{label:"right",value:"右"}]},{key:"fixed",label:"是否固定列",type:"Switch"}],C3=[{label:"查看",value:"view"},{label:"修改",value:"fix"},{label:"删除",value:"delete"},{label:"三维算例",value:"modelExample"}],E3=[{label:"新增",value:"add"}],zn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:E3},{key:"background",label:"按钮背景色",type:"Color"}],Mn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:C3},{key:"textColor",label:"按钮颜色",type:"Color"}],S3={class:"table-header-child"},D3={class:"table-header-child-main"},N3={class:"table-header-child-content"},B3={class:"table-header-child-content-item"},T3={class:"fix-button"},A3={key:0},z3={class:"form-content"},M3={__name:"tableNewChild",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(l,{emit:r}){const n=l,o=r,s=a.ref(!1),c=a.ref(""),y=ca.useTableComp(I.pinia),{tableIndex:f}=I.storeToRefs(y);a.ref(0);const v=a.ref(""),m=a.ref([]),u=a.ref([]),x=b=>{var T;s.value=!0;let $=[];Ql==null||Ql.forEach(k=>{let _=I.cloneDeep(f.value)+1;y.setTableIndex(_),$.push({label:k==null?void 0:k.label,name:k==null?void 0:k.label,type:k.type,value:b[k.key],id:f.value,contents:k==null?void 0:k.options})}),b!=null&&b.children&&((T=b==null?void 0:b.children)==null?void 0:T.length)>0&&$.push({children:b==null?void 0:b.children,isFormColHidden:!0}),v.value=b==null?void 0:b.id,m.value=$,u.value=$},E=b=>{o("fixChange",I.cloneDeep(b))},B=b=>{o("deleteChange",I.cloneDeep(b))},w=b=>{s.value=!0;let $=[];Ql==null||Ql.forEach(T=>{let k=I.cloneDeep(f.value)+1;y.setTableIndex(k),$.push({label:T==null?void 0:T.label,name:T==null?void 0:T.label,type:T.type,value:"",id:f.value,contents:T==null?void 0:T.options})}),c.value=b==null?void 0:b.id,m.value=$,u.value=$},V=b=>{let $=I.cloneDeep(u.value);$=$==null?void 0:$.map(T=>(T.children||(T.value=b==null?void 0:b[T.name]),T)),u.value=$},A=()=>{var $,T;m.value=u.value;let b={};if(v.value!=="")b.id=v.value,($=m.value)==null||$.forEach(k=>{const _=Ql==null?void 0:Ql.find(U=>(U==null?void 0:U.label)===(k==null?void 0:k.label));_?b[_.key]=k.value:k!=null&&k.children&&k.children.length>0&&(b.children=k.children)}),s.value=!1,o("fixChange",{contents:I.cloneDeep(b),id:c.value,type:"fix"});else{let k=I.cloneDeep(f.value)+1;y.setTableIndex(k),b.id="id"+f.value,(T=m.value)==null||T.forEach(_=>{const U=Ql==null?void 0:Ql.find(W=>(W==null?void 0:W.label)===(_==null?void 0:_.label));U?b[U.key]=_.value:_!=null&&_.children&&_.children.length>0&&(b.children=_.children)}),s.value=!1,o("fixChange",{contents:I.cloneDeep(b),id:c.value,type:"add"})}v.value="",m.value=[],u.value=[]},N=()=>{s.value=!1,v.value="",c.value="",m.value=[],u.value=[]},Y=b=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{o("deleteChange",b),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(b,$)=>{const T=a.resolveComponent("svg-icon");return a.openBlock(),a.createElementBlock("div",S3,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(n==null?void 0:n.tableChildContents,(k,_)=>(a.openBlock(),a.createElementBlock("div",D3,[a.createElementVNode("div",N3,[a.createElementVNode("div",B3,a.toDisplayString(k.label),1),a.createElementVNode("div",T3,[a.createVNode(T,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:U=>w(k)},null,8,["onClick"]),a.createVNode(T,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:U=>x(k)},null,8,["onClick"]),a.createVNode(T,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:U=>Y(k)},null,8,["onClick"])])]),k!=null&&k.children&&k.children.length>0?(a.openBlock(),a.createElementBlock("div",A3,[a.createVNode(wc,{tableChildContents:k==null?void 0:k.children,onDeleteChange:B,onFixChange:E},null,8,["tableChildContents"])])):a.createCommentVNode("",!0)]))),256)),a.createVNode(vr.ssDialog,{visible:s.value,onBeforeDestroy:N,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",z3,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:V},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",{class:"dialog-footer"},[a.createElementVNode("div",{onClick:N,class:"cancel-button button"},a.toDisplayString("取消")),a.createElementVNode("div",{class:"ok-button button",onClick:A},a.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},O3=ql._export_sfc(M3,[["__scopeId","data-v-e0fef72d"]]),I3={class:"table-header-child"},L3={class:"table-header-child-main"},$3={class:"table-header-child-content"},R3={class:"table-header-child-content-item"},V3={class:"fix-button"},P3={key:0},F3={class:"form-content"},j3={class:"dialog-footer"},H3={__name:"tableChildren",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(l,{emit:r}){const n=l,o=r,s=a.ref(!1),c=a.ref(""),y=ca.useTableComp(I.pinia),{tableIndex:f}=I.storeToRefs(y),v=a.ref(""),m=a.ref([]),u=a.ref([]),x=b=>{o("fixChange",I.cloneDeep(b))},E=b=>{var T;s.value=!0;let $=[];Ql==null||Ql.forEach(k=>{let _=I.cloneDeep(f.value)+1;y.setTableIndex(_),$.push({label:k==null?void 0:k.label,name:k==null?void 0:k.label,type:k.type,value:b[k.key],id:f.value,contents:k==null?void 0:k.options})}),b!=null&&b.children&&((T=b==null?void 0:b.children)==null?void 0:T.length)>0&&$.push({children:b==null?void 0:b.children,isFormColHidden:!0}),v.value=b==null?void 0:b.id,m.value=$,u.value=$},B=b=>{s.value=!0;let $=[];Ql==null||Ql.forEach(T=>{let k=I.cloneDeep(f.value)+1;y.setTableIndex(k),$.push({label:T==null?void 0:T.label,name:T==null?void 0:T.label,type:T.type,value:"",id:f.value,contents:T==null?void 0:T.options})}),c.value=b==null?void 0:b.id,m.value=$,u.value=$},w=b=>{let $=I.cloneDeep(u.value);$=$==null?void 0:$.map(T=>(T.children||(T.value=b==null?void 0:b[T.name]),T)),u.value=$},V=()=>{var $,T;m.value=u.value;let b={};if(v.value!=="")b.id=v.value,($=m.value)==null||$.forEach(k=>{const _=Ql==null?void 0:Ql.find(U=>(U==null?void 0:U.label)===(k==null?void 0:k.label));_?b[_.key]=k.value:k!=null&&k.children&&k.children.length>0&&(b.children=k.children)}),s.value=!1,o("fixChange",{contents:I.cloneDeep(b),id:c.value,type:"fix"});else{let k=I.cloneDeep(f.value)+1;y.setTableIndex(k),b.id="idChild"+f.value,(T=m.value)==null||T.forEach(_=>{const U=Ql==null?void 0:Ql.find(W=>(W==null?void 0:W.label)===(_==null?void 0:_.label));U?b[U.key]=_.value:_!=null&&_.children&&_.children.length>0&&(b.children=_.children)}),s.value=!1,o("fixChange",{contents:I.cloneDeep(b),id:c.value,type:"add"})}v.value="",m.value=[],u.value=[]},A=()=>{s.value=!1,v.value="",c.value="",m.value=[],u.value=[]},N=b=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{o("deleteChange",b),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},Y=b=>{o("deleteChange",b)};return(b,$)=>{const T=a.resolveComponent("svg-icon"),k=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock("div",I3,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(n==null?void 0:n.tableChildContents,(_,U)=>(a.openBlock(),a.createElementBlock("div",L3,[a.createElementVNode("div",$3,[a.createElementVNode("div",R3,a.toDisplayString(_.label),1),a.createElementVNode("div",V3,[a.createVNode(T,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:W=>B(_)},null,8,["onClick"]),a.createVNode(T,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:W=>E(_)},null,8,["onClick"]),a.createVNode(T,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:W=>N(_)},null,8,["onClick"])])]),_!=null&&_.children&&_.children.length>0?(a.openBlock(),a.createElementBlock("div",P3,[a.createVNode(O3,{tableChildContents:_==null?void 0:_.children,onDeleteChange:Y,onFixChange:x},null,8,["tableChildContents"])])):a.createCommentVNode("",!0)]))),256)),a.createVNode(vr.ssDialog,{visible:s.value,onBeforeDestroy:A,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",F3,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:w},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",j3,[a.createVNode(k,{onClick:A,class:"cancel-button button",id:"themeBorderButton"},{default:a.withCtx(()=>$[0]||($[0]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[0]}),a.createVNode(k,{class:"ok-button button",onClick:V,id:"themeButton"},{default:a.withCtx(()=>$[1]||($[1]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},wc=ql._export_sfc(H3,[["__scopeId","data-v-ebd68fa1"]]),U3={class:"table-operate-content"},q3={class:"table-operate-item"},W3={class:"operate-title"},K3={class:"operate-content"},Y3={class:"fix-content"},G3={class:"fix-content-label"},J3={class:"fix-button"},X3={key:0},Z3={class:"operate-title"},Q3={class:"operate-content"},e1={class:"fix-content"},a1={class:"fix-content-label"},l1={class:"fix-button"},r1={class:"operate-title"},n1={class:"operate-content"},o1={class:"fix-content"},i1={class:"fix-content-label"},s1={class:"fix-button"},c1={class:"operate-title"},u1={class:"operate-content"},d1={class:"fix-content"},p1={class:"fix-content-label"},f1={class:"fix-button"},h1={class:"operate-content"},v1={style:{display:"flex","justify-content":"space-between"}},m1={class:"form-content"},y1={class:"dialog-footer"},g1={class:"form-content"},b1={class:"dialog-footer"},k1={class:"form-content"},x1={class:"dialog-footer"},_1={class:"form-content"},w1={class:"dialog-footer"},C1={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.ref([]),c=a.ref(!1),y=a.ref(!1),f=a.ref([]),v=a.ref(!1),m=a.ref([]),u=a.ref(!1),x=a.ref([]),E=a.ref(""),B=a.ref(""),w=a.ref([]),V=a.ref([]),A=a.ref([]),N=a.ref([]),Y=a.ref(!1),b=a.ref([]),$=a.ref([]),T=a.ref(0),k=a.ref([]),_=a.ref([]),U=a.ref([]),W=()=>{Y.value=!0;let P=[];zn==null||zn.forEach(F=>{T.value++,P.push({label:F==null?void 0:F.label,name:F==null?void 0:F.label,type:F.type,value:(F==null?void 0:F.key)==="background"?"var(--ssComponent-primary-color)":"",id:T.value,contents:F==null?void 0:F.options})}),b.value=P,$.value=P},ce=()=>{var F,J,ie;y.value=!0;let P=[];(ie=(J=(F=ca.FormContent)==null?void 0:F.find(se=>(se==null?void 0:se.key)==="Input"))==null?void 0:J.value)==null||ie.forEach(se=>{T.value++,P.push({label:se==null?void 0:se.label,name:(se==null?void 0:se.name)||(se==null?void 0:se.label),type:se.type,value:(se==null?void 0:se.label)==="类型"?"Input":"",id:T.value,contents:se==null?void 0:se.options})}),k.value=P,_.value=P},Ee=P=>{P||(k.value=_.value)},Ie=async P=>{var F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa;if((P==null?void 0:P.类型)!==((J=(F=_.value)==null?void 0:F.find(Pe=>(Pe==null?void 0:Pe.label)==="类型"))==null?void 0:J.value)){let Pe=[],xa=await((ma=(se=(ie=ca.FormContent)==null?void 0:ie.find(Le=>(Le==null?void 0:Le.key)===((P==null?void 0:P.类型)===""?"Input":P==null?void 0:P.类型)))==null?void 0:se.value)==null?void 0:ma.value)?await((ve=(wa=(_e=ca.FormContent)==null?void 0:_e.find(Le=>(Le==null?void 0:Le.key)===((P==null?void 0:P.类型)===""?"Input":P==null?void 0:P.类型)))==null?void 0:wa.value)==null?void 0:ve.value):(Oe=(oa=ca.FormContent)==null?void 0:oa.find(Le=>(Le==null?void 0:Le.key)===((P==null?void 0:P.类型)===""?"Input":P==null?void 0:P.类型)))==null?void 0:Oe.value;if(xa==null||xa.forEach(Le=>{T.value++,Pe.push({label:Le==null?void 0:Le.label,name:(Le==null?void 0:Le.name)||(Le==null?void 0:Le.label),type:Le.type,value:Le!=null&&Le.属性名?(P==null?void 0:P.prop)||(P==null?void 0:P.name)||(P==null?void 0:P.label):(P==null?void 0:P[Le.label])??"",id:T.value,contents:Le==null?void 0:Le.options,prop:(Le==null?void 0:Le.prop)||(Le==null?void 0:Le.name)||(Le==null?void 0:Le.label)})}),P!=null&&P.菜单选项&&((Xe=P==null?void 0:P.菜单选项)==null?void 0:Xe.length)>0){const Le=await ca.menuToContentType(P==null?void 0:P.菜单选项);Pe=Pe==null?void 0:Pe.map(va=>((va==null?void 0:va.name)==="组信息选项"&&(va.contents=Le),va))}_.value=await ca.selectToBase(I.cloneDeep(Pe)),k.value=await ca.selectToBase(I.cloneDeep(Pe))}else{let Pe=I.cloneDeep(k.value);if(Pe=Pe==null?void 0:Pe.map(xa=>(xa.value=P==null?void 0:P[xa.name],xa)),P!=null&&P.菜单选项&&((aa=P==null?void 0:P.菜单选项)==null?void 0:aa.length)>0){const xa=await ca.menuToContentType(P==null?void 0:P.菜单选项);Pe=Pe==null?void 0:Pe.map(Le=>((Le==null?void 0:Le.name)==="组信息选项"&&(Le.contents=xa),Le))}Pe=ca.formToOptionsContents(Pe),_.value=await ca.selectToBase(I.cloneDeep(Pe))}},De=async P=>{await Ie(P),k.value=_.value},ne=(P,F)=>{if((F==null?void 0:F.type)=="Select"&&(P==null?void 0:P.key)==="selectRelateType"){const J=F==null?void 0:F.optionUrl;return(J==null?void 0:J.selectRelateType)||F[P.key]}if((F==null?void 0:F.type)=="Select"&&(P==null?void 0:P.key)==="menuSelect"){const J=F==null?void 0:F.optionUrl;return(J==null?void 0:J.menuSelect)||F[P.key]}if((F==null?void 0:F.type)=="Select"&&(P==null?void 0:P.key)==="groupSelect"){const J=F==null?void 0:F.optionUrl;return(J==null?void 0:J.groupSelect)||F[P.key]}if((F==null?void 0:F.type)=="Select"&&(P==null?void 0:P.key)==="originalContent")return(F==null?void 0:F.value)||F[P.key];if((F==null?void 0:F.type)=="Select"&&(P==null?void 0:P.key)==="multiple"){const J=F[P.key];return qs(J)?J:P.default}return(P==null?void 0:P.label)==="类型"&&F[P.key]===""?"Input":(P==null?void 0:P.key)==="isFormColHidden"&&!F[P.key]?!1:F[P.key]},ge=async P=>{var ie,se,ma,oa,Oe,_e,wa,ve,Xe;y.value=!0;let F=[];const J=await((ma=(se=(ie=ca.FormContent)==null?void 0:ie.find(aa=>(aa==null?void 0:aa.key)===((P==null?void 0:P.type)===""?"Input":P==null?void 0:P.type)))==null?void 0:se.value)==null?void 0:ma.value)?await((ve=(wa=(_e=ca.FormContent)==null?void 0:_e.find(aa=>(aa==null?void 0:aa.key)===((P==null?void 0:P.type)===""?"Input":P==null?void 0:P.type)))==null?void 0:wa.value)==null?void 0:ve.value):(Oe=(oa=ca.FormContent)==null?void 0:oa.find(aa=>(aa==null?void 0:aa.key)===((P==null?void 0:P.type)===""?"Input":P==null?void 0:P.type)))==null?void 0:Oe.value;if(J==null||J.forEach(aa=>{T.value++,F.push({label:aa==null?void 0:aa.label,name:(aa==null?void 0:aa.name)||(aa==null?void 0:aa.label),type:aa.type,value:(aa==null?void 0:aa.label)==="属性名"?(P==null?void 0:P.prop)||(P==null?void 0:P.name)||(P==null?void 0:P.label):ne(aa,P),id:T.value,contents:aa==null?void 0:aa.options})}),P!=null&&P.menuSelect&&((Xe=P==null?void 0:P.menuSelect)==null?void 0:Xe.length)>0){const aa=await ca.menuToContentType(P==null?void 0:P.menuSelect);F=F==null?void 0:F.map(Pe=>((Pe==null?void 0:Pe.name)==="组信息选项"&&(Pe.contents=aa),Pe))}E.value=P==null?void 0:P.id,k.value=await ca.selectToBase(ca.formToOptionsContents(F)),_.value=await ca.selectToBase(ca.formToOptionsContents(F))},X=P=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var F,J;U.value=(F=I.cloneDeep(U.value))==null?void 0:F.filter(ie=>(ie==null?void 0:ie.id)!==(P==null?void 0:P.id)),o("change",(J=I.cloneDeep(n.originalItemContents))==null?void 0:J.map(ie=>((ie==null?void 0:ie.key)==="tableToForm"&&(ie.contents=U.value),ie))),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},de=()=>{y.value=!1,k.value=[],E.value=""},Ke=async()=>{var ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa;k.value=_.value;let P={};E.value!==""?P.id=E.value:(T.value++,P.id="id"+T.value);let F=await((ma=(se=(ie=ca.FormContent)==null?void 0:ie.find(Pe=>{var xa,Le;return(Pe==null?void 0:Pe.key)===(((Le=(xa=k.value)==null?void 0:xa.find(va=>(va==null?void 0:va.label)==="类型"))==null?void 0:Le.value)??"label")}))==null?void 0:se.value)==null?void 0:ma.value)??((Oe=(oa=ca.FormContent)==null?void 0:oa.find(Pe=>{var xa,Le;return(Pe==null?void 0:Pe.key)===(((Le=(xa=k.value)==null?void 0:xa.find(va=>(va==null?void 0:va.label)==="类型"))==null?void 0:Le.value)??"label")}))==null?void 0:Oe.value);if((_e=k.value)==null||_e.forEach(Pe=>{const xa=F==null?void 0:F.find(Le=>(Le==null?void 0:Le.label)===(Pe==null?void 0:Pe.label));xa&&(P[xa.key]=Pe.value)}),P.name=P.label,(wa=U.value)!=null&&wa.find(Pe=>Pe.id===P.id))U.value=(ve=U.value)==null?void 0:ve.map(Pe=>(Pe.id===P.id&&(Pe=P),Pe));else{let Pe=I.cloneDeep(U.value);U.value||(U.value=[]),Pe.push(P),U.value=Pe}U.value=U.value.map(({id:Pe,...xa})=>xa),y.value=!1,E.value="";let J=I.cloneDeep(n.originalItemContents);(Xe=I.cloneDeep(n.originalItemContents))!=null&&Xe.find(Pe=>(Pe==null?void 0:Pe.key)==="tableToForm")?J=(aa=I.cloneDeep(n.originalItemContents))==null?void 0:aa.map(Pe=>((Pe==null?void 0:Pe.key)==="tableToForm"&&(Pe.contents=U.value),Pe)):J.push({key:"tableToForm",contents:U.value}),o("change",J)},Ta=P=>{Y.value=!0;let F=[];zn==null||zn.forEach(J=>{T.value++,F.push({label:J==null?void 0:J.label,name:J==null?void 0:J.label,type:J.type,value:P[J.key],id:T.value,contents:J==null?void 0:J.options})}),E.value=P==null?void 0:P.id,b.value=F,$.value=F};a.watch(()=>u.value,()=>{var F,J;let P=I.cloneDeep(n.originalItemContents);(F=I.cloneDeep(n.originalItemContents))!=null&&F.find(ie=>(ie==null?void 0:ie.key)==="page")?P=(J=I.cloneDeep(n.originalItemContents))==null?void 0:J.map(ie=>((ie==null?void 0:ie.key)==="page"&&(ie.contents=u.value),ie)):P.push({key:"page",contents:u.value}),o("change",P)},{deep:!0});const oe=P=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var F,J;V.value=(F=I.cloneDeep(V.value))==null?void 0:F.filter(ie=>(ie==null?void 0:ie.id)!==(P==null?void 0:P.id)),o("change",(J=I.cloneDeep(n.originalItemContents))==null?void 0:J.map(ie=>((ie==null?void 0:ie.key)==="extraButton"&&(ie.contents=V.value),ie))),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},S=()=>{var J,ie,se,ma,oa;b.value=$.value;let P={};if(E.value!==""?P.id=E.value:(T.value++,P.id="id"+T.value),(J=b.value)==null||J.forEach(Oe=>{const _e=zn==null?void 0:zn.find(wa=>(wa==null?void 0:wa.label)===(Oe==null?void 0:Oe.label));_e?P[_e.key]=Oe.value:Oe!=null&&Oe.children&&Oe.children.length>0&&(P.children=Oe.children)}),(ie=V.value)!=null&&ie.find(Oe=>Oe.id===P.id))V.value=(se=V.value)==null?void 0:se.map(Oe=>(Oe.id===P.id&&(Oe=P),Oe));else{let Oe=I.cloneDeep(V.value)??[];Oe.push(P),V.value=Oe}Y.value=!1,E.value="";let F=I.cloneDeep(n.originalItemContents);(ma=I.cloneDeep(n.originalItemContents))!=null&&ma.find(Oe=>(Oe==null?void 0:Oe.key)==="extraButton")?F=(oa=I.cloneDeep(n.originalItemContents))==null?void 0:oa.map(Oe=>((Oe==null?void 0:Oe.key)==="extraButton"&&(Oe.contents=V.value),Oe)):F.push({key:"extraButton",contents:V.value}),o("change",F)},le=P=>{let F=I.cloneDeep($.value);F=F==null?void 0:F.map(J=>(J.children||(J.value=P==null?void 0:P[J.name]),J)),$.value=F},me=()=>{Y.value=!1,b.value=[],E.value=""},ue=P=>{v.value=!0;let F=[];Mn==null||Mn.forEach(J=>{T.value++,F.push({label:J==null?void 0:J.label,name:J==null?void 0:J.label,type:J.type,value:P[J.key],id:T.value,contents:J==null?void 0:J.options})}),E.value=P==null?void 0:P.id,A.value=F,N.value=F},Ne=P=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var F,J;w.value=(F=I.cloneDeep(w.value))==null?void 0:F.filter(ie=>(ie==null?void 0:ie.id)!==(P==null?void 0:P.id)),o("change",(J=I.cloneDeep(n.originalItemContents))==null?void 0:J.map(ie=>((ie==null?void 0:ie.key)==="rowButton"&&(ie.contents=w.value),ie))),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},pa=()=>{c.value=!0;let P=[];Ql==null||Ql.forEach(F=>{T.value++,P.push({label:F==null?void 0:F.label,name:F==null?void 0:F.label,type:F.type,value:"",id:T.value,contents:F==null?void 0:F.options})}),m.value=P,x.value=P},_a=()=>{v.value=!0;let P=[];Mn==null||Mn.forEach(F=>{T.value++,P.push({label:F==null?void 0:F.label,name:F==null?void 0:F.label,type:F.type,value:"",id:T.value,contents:F==null?void 0:F.options})}),A.value=P,N.value=P},Wa=P=>{let F=I.cloneDeep(N.value);F=F==null?void 0:F.map(J=>(J.children||(J.value=P==null?void 0:P[J.name]),J)),N.value=F},ee=()=>{var J,ie,se,ma,oa;A.value=N.value;let P={};if(E.value!==""?P.id=E.value:(T.value++,P.id="id"+T.value),(J=A.value)==null||J.forEach(Oe=>{const _e=Mn==null?void 0:Mn.find(wa=>(wa==null?void 0:wa.label)===(Oe==null?void 0:Oe.label));_e?P[_e.key]=Oe.value:Oe!=null&&Oe.children&&Oe.children.length>0&&(P.children=Oe.children)}),(ie=w.value)!=null&&ie.find(Oe=>Oe.id===P.id))w.value=(se=w.value)==null?void 0:se.map(Oe=>(Oe.id===P.id&&(Oe=P),Oe));else{let Oe=I.cloneDeep(w.value);Oe.push(P),w.value=Oe}v.value=!1,E.value="";let F=I.cloneDeep(n.originalItemContents);(ma=I.cloneDeep(n.originalItemContents))!=null&&ma.find(Oe=>(Oe==null?void 0:Oe.key)==="rowButton")?F=(oa=I.cloneDeep(n.originalItemContents))==null?void 0:oa.map(Oe=>((Oe==null?void 0:Oe.key)==="rowButton"&&(Oe.contents=w.value),Oe)):F.push({key:"rowButton",contents:w.value}),o("change",F)},la=()=>{v.value=!1,E.value="",N.value=[],A.value=[]},Ve=P=>{c.value=!0;let F=[];Ql==null||Ql.forEach(J=>{T.value++,F.push({label:J==null?void 0:J.label,name:J==null?void 0:J.label,type:J.type,value:"",id:T.value,contents:J==null?void 0:J.options})}),m.value=F,B.value=P==null?void 0:P.id,x.value=F},ka=P=>{var F;f.value=bc(I.cloneDeep(f.value),P==null?void 0:P.id),o("change",(F=I.cloneDeep(n.originalItemContents))==null?void 0:F.map(J=>{var ie;return(J==null?void 0:J.key)==="header"&&(J.contents=(ie=f.value)!=null&&ie.some(se=>se==null?void 0:se.children)?[f.value]:f.value),J}))},He=P=>{var J,ie,se;P.type==="fix"?P.id!==""?f.value=xc(f.value,P):f.value=kc(f.value,P==null?void 0:P.contents):f.value=_c(f.value,P),f.value=(J=f.value)!=null&&J.some(ma=>ma==null?void 0:ma.children)?[f.value]:f.value,E.value="";let F=I.cloneDeep(n.originalItemContents);(ie=I.cloneDeep(n.originalItemContents))!=null&&ie.find(ma=>(ma==null?void 0:ma.key)==="header")?F=(se=I.cloneDeep(n.originalItemContents))==null?void 0:se.map(ma=>((ma==null?void 0:ma.key)==="header"&&(ma.contents=f.value),ma)):F.push({key:"header",contents:f.value}),o("change",F)},Te=P=>{var J;c.value=!0;let F=[];Ql==null||Ql.forEach(ie=>{T.value++,F.push({label:ie==null?void 0:ie.label,name:ie==null?void 0:ie.label,type:ie.type,value:P[ie.key],id:T.value,contents:ie==null?void 0:ie.options})}),P!=null&&P.children&&((J=P==null?void 0:P.children)==null?void 0:J.length)>0&&F.push({children:P==null?void 0:P.children,isFormColHidden:!0}),E.value=P==null?void 0:P.id,B.value="",m.value=F,x.value=F},Re=P=>{let F=I.cloneDeep(x.value);F=F==null?void 0:F.map(J=>(J.children||(J.value=P==null?void 0:P[J.name]),J)),x.value=F},Ge=()=>{c.value=!1,E.value="",B.value="",x.value=[]},Ga=()=>{var J,ie,se,ma,oa,Oe;m.value=x.value;let P={};if(E.value!==""?P.id=E.value:(T.value++,P.id="id"+T.value),(J=m.value)==null||J.forEach(_e=>{const wa=Ql==null?void 0:Ql.find(ve=>(ve==null?void 0:ve.label)===(_e==null?void 0:_e.label));wa?P[wa.key]=_e.value:_e!=null&&_e.children&&_e.children.length>0&&(P.children=_e.children)}),(ie=f.value)!=null&&ie.find(_e=>_e.id===P.id))f.value=(se=f.value)==null?void 0:se.map(_e=>(_e.id===P.id&&(_e=P),_e));else{let _e=I.cloneDeep(f.value)??[];B.value===""?_e.push(P):_e=_e==null?void 0:_e.map(wa=>(wa.id===B.value&&(wa.children||(wa.children=[]),wa.children.push(P)),wa)),f.value=_e}f.value=(ma=f.value)!=null&&ma.some(_e=>_e==null?void 0:_e.children)?[f.value]:f.value,c.value=!1,E.value="",B.value="";let F=I.cloneDeep(n.originalItemContents);(oa=I.cloneDeep(n.originalItemContents))!=null&&oa.find(_e=>(_e==null?void 0:_e.key)==="header")?F=(Oe=I.cloneDeep(n.originalItemContents))==null?void 0:Oe.map(_e=>((_e==null?void 0:_e.key)==="header"&&(_e.contents=f.value),_e)):F.push({key:"header",contents:f.value}),o("change",F)},Fa=P=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var F,J;f.value=(F=I.cloneDeep(f.value))==null?void 0:F.filter(ie=>(ie==null?void 0:ie.id)!==(P==null?void 0:P.id)),o("change",(J=I.cloneDeep(n.originalItemContents))==null?void 0:J.map(ie=>{var se;return(ie==null?void 0:ie.key)==="header"&&(ie.contents=(se=f.value)!=null&&se.some(ma=>ma==null?void 0:ma.children)?[f.value]:f.value),ie})),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return a.watch(()=>n.originalItemContents,()=>{var P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce;if(!(!n.originalItemContents||n.originalItemContents.length===0))if(s.value=I.cloneDeep(n.originalItemContents),f.value=(F=(P=s.value)==null?void 0:P.find(Z=>(Z==null?void 0:Z.key)==="header"))==null?void 0:F.contents,w.value=(ie=(J=s.value)==null?void 0:J.find(Z=>(Z==null?void 0:Z.key)==="rowButton"))==null?void 0:ie.contents,V.value=(ma=(se=s.value)==null?void 0:se.find(Z=>(Z==null?void 0:Z.key)==="extraButton"))==null?void 0:ma.contents,u.value=(Oe=(oa=s.value)==null?void 0:oa.find(Z=>(Z==null?void 0:Z.key)==="page"))!=null&&Oe.contents?!!((wa=(_e=s.value)==null?void 0:_e.find(Z=>(Z==null?void 0:Z.key)==="page"))!=null&&wa.contents):!1,U.value=(Xe=(ve=s.value)==null?void 0:ve.find(Z=>(Z==null?void 0:Z.key)==="tableToForm"))==null?void 0:Xe.contents,f.value=(aa=f.value)==null?void 0:aa.map((Z,fa)=>(Array.isArray(Z)?Z=w3(Z):Z={label:(Z==null?void 0:Z.label)??"",prop:(Z==null?void 0:Z.label)==="操作"?"operate":Z==null?void 0:Z.prop,width:Z!=null&&Z.width?parseInt(Z.width):"",fixed:(Z==null?void 0:Z.fixed)??void 0,sortable:(Z==null?void 0:Z.sortable)??!1,align:(Z==null?void 0:Z.align)??"left",showOverflowTooltip:(Z==null?void 0:Z.showOverflowTooltip)??!0,isNotDrag:(Z==null?void 0:Z.isNotDrag)??!1,isEditCol:(Z==null?void 0:Z.isEditCol)??!1,isOperate:(Z==null?void 0:Z.isOperate)??!1,id:(Z==null?void 0:Z.id)??fa,formMenuSelect:(Z==null?void 0:Z.formMenuSelect)??void 0,groupSelect:(Z==null?void 0:Z.groupSelect)??void 0},Z)),f.value=(Pe=f.value)!=null&&Pe.every(Z=>Array.isArray(Z))?(xa=f.value)==null?void 0:xa[0]:f.value,w.value=(Le=w.value)==null?void 0:Le.map((Z,fa)=>Z={label:(Z==null?void 0:Z.label)??"",type:(Z==null?void 0:Z.type)??"",textColor:(Z==null?void 0:Z.textColor)??"#000000",id:(Z==null?void 0:Z.id)??fa}),V.value=(va=V.value)==null?void 0:va.map((Z,fa)=>Z={label:(Z==null?void 0:Z.label)??"",type:(Z==null?void 0:Z.type)??"",background:(Z==null?void 0:Z.background)??"var(--ssComponent-primary-color)",id:(Z==null?void 0:Z.id)??fa}),U.value)U.value=(Ce=U.value)==null?void 0:Ce.map(Z=>{T.value++;let fa=Z;return fa.id=T.value,fa});else{let Z=[];const fa=(re=ca.getColumnChild(I.cloneDeep(f.value)))==null?void 0:re.filter(Ye=>(Ye==null?void 0:Ye.prop)!=="operate");fa==null||fa.forEach(Ye=>{var Ma;T.value++,Z.push({label:Ye==null?void 0:Ye.label,name:(Ye==null?void 0:Ye.prop)||(Ye==null?void 0:Ye.label),type:Ye!=null&&Ye.groupSelect?"Select":"Input",value:"",id:T.value,contents:Ye==null?void 0:Ye.options,menuSelect:Ye==null?void 0:Ye.formMenuSelect,groupSelect:(Ma=Ye==null?void 0:Ye.groupSelect)==null?void 0:Ma.split(":"),selectRelateType:"关联绑定列"})}),U.value=Z}},{deep:!0,immediate:!0}),(P,F)=>{const J=a.resolveComponent("svg-icon"),ie=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock("div",U3,[a.createElementVNode("div",q3,[a.createElementVNode("div",W3,[F[2]||(F[2]=a.createElementVNode("div",null,a.toDisplayString("表头"),-1)),a.createVNode(ie,{class:"icon-content",onClick:pa,id:"themeButton"},{icon:a.withCtx(()=>[a.createVNode(J,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[F[1]||(F[1]=a.createTextVNode(" 新增 "))]),_:1,__:[1]})]),a.createElementVNode("div",K3,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(f.value,(se,ma)=>(a.openBlock(),a.createElementBlock("div",{key:ma},[a.createElementVNode("div",Y3,[a.createElementVNode("div",G3,a.toDisplayString(se==null?void 0:se.label),1),a.createElementVNode("div",J3,[a.createVNode(J,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oa=>Ve(se)},null,8,["onClick"]),a.createVNode(J,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oa=>Te(se)},null,8,["onClick"]),a.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oa=>Fa(se)},null,8,["onClick"])])]),se!=null&&se.children&&se.children.length>0?(a.openBlock(),a.createElementBlock("div",X3,[a.createVNode(wc,{tableChildContents:se==null?void 0:se.children,onDeleteChange:ka,onFixChange:He},null,8,["tableChildContents"])])):a.createCommentVNode("",!0)]))),128))]),a.createElementVNode("div",Z3,[F[4]||(F[4]=a.createElementVNode("div",null,a.toDisplayString("行内按钮"),-1)),a.createVNode(ie,{class:"icon-content",id:"themeButton",onClick:_a},{icon:a.withCtx(()=>[a.createVNode(J,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[F[3]||(F[3]=a.createTextVNode(" 新增 "))]),_:1,__:[3]})]),a.createElementVNode("div",Q3,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(w.value,(se,ma)=>(a.openBlock(),a.createElementBlock("div",{key:ma},[a.createElementVNode("div",e1,[a.createElementVNode("div",a1,a.toDisplayString(se==null?void 0:se.label),1),a.createElementVNode("div",l1,[a.createVNode(J,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:oa=>ue(se)},null,8,["onClick"]),a.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oa=>Ne(se)},null,8,["onClick"])])])]))),128))]),a.createElementVNode("div",r1,[F[6]||(F[6]=a.createElementVNode("div",null,a.toDisplayString("表外按钮"),-1)),a.createVNode(ie,{class:"icon-content",id:"themeButton",onClick:W},{icon:a.withCtx(()=>[a.createVNode(J,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[F[5]||(F[5]=a.createTextVNode(" 新增 "))]),_:1,__:[5]})]),a.createElementVNode("div",n1,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(V.value,(se,ma)=>(a.openBlock(),a.createElementBlock("div",{key:ma},[a.createElementVNode("div",o1,[a.createElementVNode("div",i1,a.toDisplayString(se==null?void 0:se.label),1),a.createElementVNode("div",s1,[a.createVNode(J,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:oa=>Ta(se)},null,8,["onClick"]),a.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oa=>oe(se)},null,8,["onClick"])])])]))),128))]),a.createElementVNode("div",c1,[F[8]||(F[8]=a.createElementVNode("div",null,a.toDisplayString("表格弹框字段设置"),-1)),a.createVNode(ie,{class:"icon-content",id:"themeButton",onClick:ce},{icon:a.withCtx(()=>[a.createVNode(J,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[F[7]||(F[7]=a.createTextVNode(" 新增 "))]),_:1,__:[7]})]),a.createElementVNode("div",u1,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(U.value,(se,ma)=>(a.openBlock(),a.createElementBlock("div",{key:ma},[a.createElementVNode("div",d1,[a.createElementVNode("div",p1,a.toDisplayString(se==null?void 0:se.label),1),a.createElementVNode("div",f1,[a.createVNode(J,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:oa=>ge(se)},null,8,["onClick"]),a.createVNode(J,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oa=>X(se)},null,8,["onClick"])])])]))),128))]),F[10]||(F[10]=a.createElementVNode("div",{class:"operate-title"},[a.createElementVNode("div",null,a.toDisplayString("分页"))],-1)),a.createElementVNode("div",h1,[a.createElementVNode("div",v1,[F[9]||(F[9]=a.createElementVNode("div",{class:"operate-center-content"},a.toDisplayString("是否分页"),-1)),a.createVNode(pl._sfc_main$1,{modelValue:u.value,"onUpdate:modelValue":F[0]||(F[0]=se=>u.value=se)},null,8,["modelValue"])])])]),a.createVNode(vr.ssDialog,{visible:c.value,onBeforeDestroy:Ge,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",m1,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:m.value,key:m.value,isEnableWrap:!0,onChange:Re},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",y1,[a.createVNode(ie,{onClick:Ge,class:"cancel-button button",id:"themeBorderButton"},{default:a.withCtx(()=>F[11]||(F[11]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[11]}),a.createVNode(ie,{class:"ok-button button",onClick:Ga,id:"themeButton"},{default:a.withCtx(()=>F[12]||(F[12]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible"]),a.createVNode(vr.ssDialog,{visible:v.value,onBeforeDestroy:la,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",g1,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:A.value,key:A.value,isEnableWrap:!0,onChange:Wa},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",b1,[a.createVNode(ie,{onClick:la,class:"cancel-button button",id:"themeBorderButton"},{default:a.withCtx(()=>F[13]||(F[13]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[13]}),a.createVNode(ie,{class:"ok-button button",onClick:ee,id:"themeButton"},{default:a.withCtx(()=>F[14]||(F[14]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible"]),a.createVNode(vr.ssDialog,{visible:Y.value,onBeforeDestroy:me,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",k1,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:le},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",x1,[a.createVNode(ie,{onClick:me,class:"cancel-button button",id:"themeBorderButton"},{default:a.withCtx(()=>F[15]||(F[15]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[15]}),a.createVNode(ie,{class:"ok-button button",onClick:S,id:"themeButton"},{default:a.withCtx(()=>F[16]||(F[16]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[16]})])]),_:1},8,["visible"]),a.createVNode(vr.ssDialog,{visible:y.value,onBeforeDestroy:de,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",_1,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:k.value,key:k.value,isEnableWrap:!0,onChange:Ie,onChangeVisible:Ee,onBlurChange:De},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",w1,[a.createVNode(ie,{onClick:de,class:"cancel-button button",id:"themeBorderButton"},{default:a.withCtx(()=>F[17]||(F[17]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[17]}),a.createVNode(ie,{class:"ok-button button",onClick:Ke,id:"themeButton"},{default:a.withCtx(()=>F[18]||(F[18]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[18]})])]),_:1},8,["visible"])])}}},E1=ql._export_sfc(C1,[["__scopeId","data-v-7a6b87b5"]]),S1=I.useModelComp(I.pinia),{pageMapState:D1}=I.storeToRefs(S1),N1=I.useMenuState(I.pinia),{activeMenuPath:B1}=I.storeToRefs(N1),T1=a.ref(24),A1=a.ref(6),z1=a.ref(70),M1=a.ref(.18),O1=a.ref(45),I1=(l,r,n,o)=>{var s,c,y,f,v,m,u,x,E,B,w,V,A,N,Y,b;return{x:((c=(s=l==null?void 0:l.value)==null?void 0:s.tableData)==null?void 0:c.x)||r%2*12,y:((f=(y=l==null?void 0:l.value)==null?void 0:y.tableData)==null?void 0:f.y)||r,w:((m=(v=l==null?void 0:l.value)==null?void 0:v.tableData)==null?void 0:m.w)||T1.value,h:((x=(u=l==null?void 0:l.value)==null?void 0:u.tableData)==null?void 0:x.h)||n,minW:((B=(E=l==null?void 0:l.value)==null?void 0:E.tableData)==null?void 0:B.minW)||A1.value,minH:((V=(w=l==null?void 0:l.value)==null?void 0:w.tableData)==null?void 0:V.minH)||M1.value,maxH:((N=(A=l==null?void 0:l.value)==null?void 0:A.tableData)==null?void 0:N.maxH)||O1.value,i:((b=(Y=l==null?void 0:l.value)==null?void 0:Y.tableData)==null?void 0:b.i)||r,id:(l==null?void 0:l.id)||r+"",component:o}},L1=(l,r)=>{var o,s,c,y,f,v,m,u;let n=1;if(l!=null&&l.compData&&Array.isArray(l==null?void 0:l.compData))if(((o=l==null?void 0:l.comp)==null?void 0:o.toUpperCase())==="TABLE"){if(((y=(c=(s=l==null?void 0:l.compData)==null?void 0:s.find(E=>(E==null?void 0:E.key)==="tableContents"))==null?void 0:c.contents)==null?void 0:y.length)===0)return 2}else((f=l==null?void 0:l.comp)==null?void 0:f.toUpperCase())==="FORM"&&(n=((u=(m=(v=l==null?void 0:l.compData)==null?void 0:v.find(E=>(E==null?void 0:E.key)==="formContent"))==null?void 0:m.contents)==null?void 0:u.length)/5);return n*2},Cc=(l,r,n)=>{var y,f;const o=(f=(y=D1.value)==null?void 0:y[B1.value])==null?void 0:f.filter(v=>{var m;return((m=v==null?void 0:v.key)==null?void 0:m.type)==="gridLayout"}),s=o==null?void 0:o.find(v=>{var m,u,x;return((x=(u=(m=v==null?void 0:v.value)==null?void 0:m.tableData)==null?void 0:u.component)==null?void 0:x.id)===l.id}),c=L1(l);return l!=null&&l.children&&(l==null?void 0:l.children.length)>0&&(l.children=l.children.map((v,m)=>Cc(v,m))),{...I1(s,r,c,l)}},$1=(l,r)=>{if((l==null?void 0:l.length)===0)return[];const n=I.cloneDeep(l);return Array.isArray(l)?n==null?void 0:n.map((o,s)=>Cc(o,s)):[]},R1=l=>({TABLE:{overall:[{label:"栅格布局",prop:"isGridLayout",type:"switch",value:!1,disabled:!1,activeText:"启用",inactiveText:"默认"},{label:"界面布局",prop:"layout",type:"radio",value:"vertical",options:[{label:"垂直",value:"vertical"},{label:"水平",value:"horizontal"}]},{label:"流程式布局",prop:"isStepLayout",type:"radio",value:!1,options:[{label:"启用",value:!0,disabled:!1},{label:"禁用",value:!1,disabled:!1}]}],alone:[{label:"默认显示序号",prop:"showIndex",type:"radio",value:!1,options:[{label:"是",value:!0},{label:"否",value:!1}]},{label:"浏览视图配置",prop:"viewport",type:"checkbox",value:["read"],options:[{label:"只读视图",value:"read"},{label:"编辑视图",value:"edit"}]},{label:"是否选择迁移",prop:"allowMove",type:"radio",value:!1,options:[{label:"是",value:!0},{label:"否",value:!1}]}]}}),V1=(l,r)=>l==null?void 0:l.map(n=>{for(const o in r)if(o===(n==null?void 0:n.prop))return{...n,value:r[o]};return n}),P1=a.defineComponent({__name:"index",props:{compType:String,comp:Object,target:{type:String,default:"alone"},optionItems:Array},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.ref([]);a.watch(()=>n.compType,f=>{var u;const v=R1(n==null?void 0:n.optionItems),m=f?(u=v[f==null?void 0:f.toUpperCase()])==null?void 0:u[n==null?void 0:n.target]:[];s.value=m==null?void 0:m.map(x=>{for(const[E,B]of Object.entries((n==null?void 0:n.comp)||{}))if((x==null?void 0:x.prop)===E)return{...x,value:B};return x})},{immediate:!0});const c=f=>pl.getComponent(f),y=f=>{var v,m;(f==null?void 0:f.prop)==="layout"&&(f==null?void 0:f.value)==="horizontal"?s.value=(v=s.value)==null?void 0:v.map(u=>{var x;return(u==null?void 0:u.prop)==="isStepLayout"?{...u,options:(x=u==null?void 0:u.options)==null?void 0:x.map(E=>({...E,disabled:!0}))}:(u==null?void 0:u.prop)==="isGridLayout"?{...u,disabled:!0}:u}):s.value=(m=s.value)==null?void 0:m.map(u=>{var x;return(u==null?void 0:u.prop)==="isStepLayout"?{...u,options:(x=u==null?void 0:u.options)==null?void 0:x.map(E=>({...E,disabled:!1}))}:(u==null?void 0:u.prop)==="isGridLayout"?{...u,disabled:!1}:u}),o("change",{target:n==null?void 0:n.target,styleConfigs:s.value,prop:f==null?void 0:f.prop})};return(f,v)=>{const m=a.resolveComponent("el-col"),u=a.resolveComponent("el-row");return a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(s.value,x=>(a.openBlock(),a.createBlock(u,{class:"style-row",key:x==null?void 0:x.prop},{default:a.withCtx(()=>[a.createVNode(m,{span:6,class:"style-row-title"},{default:a.withCtx(()=>[a.createTextVNode(a.toDisplayString(x==null?void 0:x.label)+":",1)]),_:2},1024),a.createVNode(m,{span:18,style:{display:"flex"}},{default:a.withCtx(()=>[(a.openBlock(),a.createBlock(a.resolveDynamicComponent(c(x.type)),{modelValue:x.value,"onUpdate:modelValue":E=>x.value=E,content:x==null?void 0:x.options,optionUrl:x==null?void 0:x.optionUrl,disabled:x==null?void 0:x.disabled,activeText:x==null?void 0:x.activeText,inactiveText:x==null?void 0:x.inactiveText,onChange:E=>y(x)},null,40,["modelValue","onUpdate:modelValue","content","optionUrl","disabled","activeText","inactiveText","onChange"]))]),_:2},1024)]),_:2},1024))),128)}}}),F1=ql._export_sfc(P1,[["__scopeId","data-v-6c233914"]]),j1=a.defineComponent({__name:"index",props:{compType:String,activeTabName:String,comp:Object,extendItem:{type:Object,default:{}},target:{type:String,default:"alone"},relatedData:Array},emits:["change","onButtonClick"],setup(l,{emit:r}){const n=l,o=r,s=[{required:!0,message:"输入不能为空",trigger:"blur"}],c=a.ref([]),y=N=>N==null?void 0:N.reduce((Y,b)=>(Y[b==null?void 0:b.prop]=b==null?void 0:b.rule,Y),{}),f=a.computed(()=>({formRules:y(c.value),buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"保存",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]})),v=a.ref([]),m=a.ref(""),u=(N,Y,b)=>{var k;let $=[];(n==null?void 0:n.activeTabName)==="任务配置"?($=[{label:"任务名称",prop:"任务名称",key:"任务名称",value:"",width:1,isFormColHidden:!1},{label:"任务关键词",prop:"任务关键词",key:"任务关键词",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"列名称",value:"列名称",children:N},{label:"按钮名称",value:"按钮名称",children:Y}]},{label:"执行任务",prop:"执行任务",key:"执行任务",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"进度设置",value:"进度设置",children:[{label:"计时",value:"计时",children:[{label:"倒计时",value:"倒计时"},{label:"进行时",value:"进行时"}]},{label:"进度条",value:"进度条"}]},{label:"统计",value:"统计",children:[{label:"统计规则",value:"统计规则",children:[{label:"求和",value:"求和"},{label:"自定义",value:"自定义"}]}]}]},{label:"执行动作",prop:"执行动作",key:"执行动作",type:"select",value:[],width:1,isFormColHidden:!1,contents:[{label:"点击时",value:"点击时"},{label:"页面加载时",value:"页面加载时"}]},{label:"执行交互",prop:"执行交互",key:"执行交互",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"界面显示",value:"界面显示",children:[{label:"主页",value:"主页"},{label:"详情页",value:"详情页"}]},{label:"弹窗提示",value:"弹窗提示"},{label:"后台提交",value:"后台提交"}]},{label:"任务状态",prop:"任务状态",key:"任务状态",type:"radio",value:"启动",width:1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],c.value=[{prop:"任务名称",rule:s},{prop:"任务关键词",rule:s},{prop:"执行任务",rule:s},{prop:"执行动作",rule:s},{prop:"执行交互",rule:s}]):(n==null?void 0:n.activeTabName)==="任务关联"&&($=[{prop:"关联名称",label:"关联名称",key:"关联名称",type:"input",value:"",isTableColHidden:!1,isFormColHidden:!1},{label:"关联形式",prop:"关联形式",key:"关联形式",type:"select",value:"流程式",width:1,isFormColHidden:!1,contents:[{label:"流程式",value:"流程式"}]},{label:"关联任务集合",prop:"关联任务集合",key:"关联任务集合",type:"tag",value:[],width:1,isFormColHidden:!1,contents:(k=n==null?void 0:n.relatedData)==null?void 0:k.map(_=>({label:_==null?void 0:_.任务名称,value:_==null?void 0:_.任务名称}))},{prop:"关联状态",label:"关联状态",key:"关联状态",type:"radio",value:"启动",isTableColHidden:!1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],c.value=[{prop:"关联名称",rule:s},{prop:"关联状态",rule:s},{prop:"关联形式",rule:s},{prop:"关联任务集合",rule:s}]);let T;return b&&(b==null?void 0:b.length)>0?T=[...$,...x(N,Y,b)]:T=$,T},x=(N,Y,b)=>{const $=[{label:"进度关键词",prop:"进度关键词",key:"进度关键词",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计算法源",prop:"统计算法源",key:"统计算法源",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计是否获取错误集",prop:"统计是否获取错误集",key:"统计是否获取错误集",type:"radio",value:!1,width:2,isFormColHidden:!1,contents:[{label:"是",value:!0},{label:"否",value:!1}]}];return b?$==null?void 0:$.filter(T=>b==null?void 0:b.includes(T==null?void 0:T.prop)):$},E=(N,Y)=>{var _,U,W,ce,Ee,Ie,De,ne,ge;const b=((Ee=(ce=(W=(U=(_=n==null?void 0:n.comp)==null?void 0:_.compData)==null?void 0:U.find(X=>(X==null?void 0:X.key)==="header"))==null?void 0:W.contents)==null?void 0:ce.filter(X=>(X==null?void 0:X.label)!=="操作"))==null?void 0:Ee.map(X=>({value:X==null?void 0:X.prop,label:X.label})))||[],$=/button/i,T=((ge=(ne=(De=(Ie=n==null?void 0:n.comp)==null?void 0:Ie.compData)==null?void 0:De.filter(X=>$.test(X==null?void 0:X.key)))==null?void 0:ne.flatMap(X=>X==null?void 0:X.contents))==null?void 0:ge.map(X=>({value:X==null?void 0:X.label,label:X.label})))||[],k=u(b,T,N);v.value=Y?V1(k,Y):k,N&&(N==null?void 0:N.length)>0&&c.value.push(...N==null?void 0:N.map(X=>({prop:X,rule:s})))};a.onMounted(()=>{E(null,n==null?void 0:n.extendItem)});const B=N=>{const Y=N==null?void 0:N[m.value];if(m.value==="执行任务"){if(!(Y!=null&&Y.join("/")))return;const b=Y==null?void 0:Y.join("/");E(b==="统计/统计规则/自定义"?["统计算法源","统计是否获取错误集"]:b==="进度设置/进度条"?["进度关键词"]:null,N)}},w=N=>{o("change",{target:n==null?void 0:n.target,extendConfigs:N})},V=(N,Y)=>{m.value=Y==null?void 0:Y.changeProp,B(N)},A=N=>{o("onButtonClick",N)};return(N,Y)=>(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:v.value,key:v.value,isStartJustify:!1,isEnableWrap:!1,formRules:f.value.formRules,buttonValue:f.value.buttonValue,onChange:w,onBlurChange:V,onOnButtonClick:A},null,8,["rowContents","formRules","buttonValue"]))}}),H1=ql._export_sfc(j1,[["__scopeId","data-v-7c660c1f"]]),U1={};function q1(l,r){return null}const W1=ql._export_sfc(U1,[["render",q1]]),K1={class:"form-operate-content"},Y1={class:"form-operate-item"},G1={class:"operate-title"},J1={class:"operate-content"},X1={class:"fix-content"},Z1={class:"fix-button"},Q1={class:"operate-title"},e2={class:"operate-content"},a2={class:"fix-content"},l2={class:"fix-button"},r2={style:{display:"flex","justify-content":"space-between"}},n2={class:"form-content"},o2={class:"dialog-footer"},i2={class:"form-content"},t2={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.ref(!1),c=a.ref([]),y=a.ref([]),f=a.ref(!1),v=a.ref([]),m=a.ref([]),u=a.ref(""),x=a.ref(!1),E=a.ref(0),B=a.ref([]),w=a.ref([]),V=(ne,ge)=>{if((ge==null?void 0:ge.type)=="Select"&&(ne==null?void 0:ne.key)==="selectRelateType"){const X=ge==null?void 0:ge.optionUrl;return(X==null?void 0:X.selectRelateType)||ge[ne.key]}if((ge==null?void 0:ge.type)=="Select"&&(ne==null?void 0:ne.key)==="menuSelect"){const X=ge==null?void 0:ge.optionUrl;return(X==null?void 0:X.menuSelect)||ge[ne.key]}if((ge==null?void 0:ge.type)=="Select"&&(ne==null?void 0:ne.key)==="groupSelect"){const X=ge==null?void 0:ge.optionUrl;return(X==null?void 0:X.groupSelect)||ge[ne.key]}if((ge==null?void 0:ge.type)=="Select"&&(ne==null?void 0:ne.key)==="originalContent")return(ge==null?void 0:ge.value)||ge[ne.key];if((ge==null?void 0:ge.type)=="Select"&&(ne==null?void 0:ne.key)==="multiple"){const X=ge[ne.key];return qs(X)?X:ne.default}return(ne==null?void 0:ne.label)==="类型"&&ge[ne.key]===""?"Input":(ne==null?void 0:ne.key)==="isFormColHidden"&&!ge[ne.key]?!1:ge[ne.key]},A=async ne=>{var de,Ke,Ta,oe,S,le;s.value=!0;let ge=[];const X=await((Ta=(Ke=(de=ca.FormContent)==null?void 0:de.find(me=>(me==null?void 0:me.key)===((ne==null?void 0:ne.type)===""?"Input":ne==null?void 0:ne.type)))==null?void 0:Ke.value)==null?void 0:Ta.value)??((S=(oe=ca.FormContent)==null?void 0:oe.find(me=>(me==null?void 0:me.key)===((ne==null?void 0:ne.type)===""?"Input":ne==null?void 0:ne.type)))==null?void 0:S.value);if(X==null||X.forEach(me=>{E.value++,ge.push({label:me==null?void 0:me.label,name:me==null?void 0:me.label,type:me.type,prop:me==null?void 0:me.prop,value:V(me,ne),id:E.value,contents:me==null?void 0:me.options,width:(ne==null?void 0:ne.width)??1})}),ne!=null&&ne.menuSelect&&((le=ne==null?void 0:ne.menuSelect)==null?void 0:le.length)>0){const me=await ca.menuToContentType(ne==null?void 0:ne.menuSelect);ge=ge==null?void 0:ge.map(ue=>((ue==null?void 0:ue.name)==="组信息选项"&&(ue.contents=me),ue))}u.value=ne==null?void 0:ne.id,c.value=await ca.selectToBase(ca.formToOptionsContents(ge)),y.value=await ca.selectToBase(ca.formToOptionsContents(ge))},N=ne=>{var X;f.value=!0;let ge=[];(X=ca.FormButton)==null||X.forEach(de=>{E.value++,ge.push({label:de==null?void 0:de.label,name:de==null?void 0:de.label,type:de.type,value:(de==null?void 0:de.label)==="类型"&&ne[de.key]===""?"normal":ne[de.key],id:E.value,contents:de==null?void 0:de.options})}),B.value=ge,w.value=ge,u.value=ne==null?void 0:ne.id};a.watch(()=>x.value,()=>{var ge,X;let ne=I.cloneDeep(n.originalItemContents);(ge=I.cloneDeep(n.originalItemContents))!=null&&ge.find(de=>(de==null?void 0:de.key)==="enableWrap")?ne=(X=I.cloneDeep(n.originalItemContents))==null?void 0:X.map(de=>((de==null?void 0:de.key)==="enableWrap"&&(de.contents=!x.value),de)):ne.push({key:"enableWrap",contents:!x.value}),o("change",ne)},{deep:!0});const Y=()=>{var X,de,Ke,Ta,oe;B.value=w.value;let ne={};if(u.value!==""?ne.id=u.value:(E.value++,ne.id="id"+E.value),(X=B.value)==null||X.forEach(S=>{var me;const le=(me=ca.FormButton)==null?void 0:me.find(ue=>(ue==null?void 0:ue.label)===(S==null?void 0:S.label));le&&(ne[le.key]=S.value)}),(de=v.value)!=null&&de.find(S=>S.id===ne.id))v.value=(Ke=v.value)==null?void 0:Ke.map(S=>(S.id===ne.id&&(S=ne),S));else{let S=I.cloneDeep(v.value);v.value||(v.value=[]),S.push(ne),v.value=S}f.value=!1,u.value="";let ge=I.cloneDeep(n.originalItemContents);(Ta=I.cloneDeep(n.originalItemContents))!=null&&Ta.find(S=>(S==null?void 0:S.key)==="formButton")?ge=(oe=I.cloneDeep(n.originalItemContents))==null?void 0:oe.map(S=>((S==null?void 0:S.key)==="formButton"&&(S.contents=v.value),S)):ge.push({key:"formButton",contents:v.value}),o("change",ge)},b=ne=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var ge,X;m.value=(ge=I.cloneDeep(m.value))==null?void 0:ge.filter(de=>(de==null?void 0:de.id)!==(ne==null?void 0:ne.id)),o("change",(X=I.cloneDeep(n.originalItemContents))==null?void 0:X.map(de=>((de==null?void 0:de.key)==="formContent"&&(de.contents=m.value),de))),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},$=ne=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var ge,X;v.value=(ge=I.cloneDeep(v.value))==null?void 0:ge.filter(de=>(de==null?void 0:de.id)!==(ne==null?void 0:ne.id)),o("change",(X=I.cloneDeep(n.originalItemContents))==null?void 0:X.map(de=>((de==null?void 0:de.key)==="formButton"&&(de.contents=v.value),de))),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},T=()=>{var ge;f.value=!0;let ne=[];(ge=ca.FormButton)==null||ge.forEach(X=>{E.value++,ne.push({label:X==null?void 0:X.label,name:X==null?void 0:X.label,type:X.type,value:(X==null?void 0:X.label)==="类型"?"normal":"",id:E.value,contents:X==null?void 0:X.options})}),B.value=ne,w.value=ne},k=()=>{var ge,X,de;s.value=!0;let ne=[];(de=(X=(ge=ca.FormContent)==null?void 0:ge.find(Ke=>(Ke==null?void 0:Ke.key)==="Input"))==null?void 0:X.value)==null||de.forEach(Ke=>{E.value++,ne.push({label:Ke==null?void 0:Ke.label,name:Ke==null?void 0:Ke.label,type:Ke.type,value:(Ke==null?void 0:Ke.label)==="类型"?"Input":"",id:E.value,contents:Ke==null?void 0:Ke.options})}),c.value=ne,y.value=ne},_=ne=>{let ge=I.cloneDeep(w.value);ge=ge==null?void 0:ge.map(X=>(X.value=ne==null?void 0:ne[X.name],X)),w.value=ge},U=ne=>{const ge=ne.find(Ke=>(Ke==null?void 0:Ke.name)==="类型");if((ge==null?void 0:ge.value)!="Select")return;const X=ne.find(Ke=>(Ke==null?void 0:Ke.name)==="多选"),de=ne.find(Ke=>(Ke==null?void 0:Ke.name)==="初始值");X!=null&&X.value&&ki.isString(de.value)&&(de.value=[de.value]),!(X!=null&&X.value)&&!ki.isString(de.value)&&(de.value="")},W=async ne=>{var ge,X,de,Ke,Ta,oe,S,le,me,ue,Ne,pa;if((ne==null?void 0:ne.类型)!==((X=(ge=y.value)==null?void 0:ge.find(_a=>(_a==null?void 0:_a.label)==="类型"))==null?void 0:X.value)){let _a=[];const Wa=await((Ta=(Ke=(de=ca.FormContent)==null?void 0:de.find(ee=>(ee==null?void 0:ee.key)===((ne==null?void 0:ne.类型)===""?"Input":ne==null?void 0:ne.类型)))==null?void 0:Ke.value)==null?void 0:Ta.value)?await((ue=(me=(le=ca.FormContent)==null?void 0:le.find(ee=>(ee==null?void 0:ee.key)===((ne==null?void 0:ne.类型)===""?"Input":ne==null?void 0:ne.类型)))==null?void 0:me.value)==null?void 0:ue.value):(S=(oe=ca.FormContent)==null?void 0:oe.find(ee=>(ee==null?void 0:ee.key)===((ne==null?void 0:ne.类型)===""?"Input":ne==null?void 0:ne.类型)))==null?void 0:S.value;if(Wa==null||Wa.forEach(ee=>{var Ve,ka;E.value++;const la=_u(ee==null?void 0:ee.default)?(ne==null?void 0:ne[ee.label])??ee.value??"":ee==null?void 0:ee.default;_a.push({label:ee==null?void 0:ee.label,name:ee==null?void 0:ee.label,type:ee.type,value:la,prop:ee==null?void 0:ee.prop,id:E.value,contents:ee==null?void 0:ee.options,width:((ka=(Ve=y.value)==null?void 0:Ve[0])==null?void 0:ka.width)??1})}),ne!=null&&ne.菜单选项&&((Ne=ne==null?void 0:ne.菜单选项)==null?void 0:Ne.length)>0){const ee=await ca.menuToContentType(ne==null?void 0:ne.菜单选项);_a=_a==null?void 0:_a.map(la=>((la==null?void 0:la.name)==="组信息选项"&&(la.contents=ee),la))}U(_a),y.value=await ca.selectToBase(I.cloneDeep(_a)),c.value=await ca.selectToBase(I.cloneDeep(_a))}else{let _a=I.cloneDeep(y.value);if(_a=_a==null?void 0:_a.map(Wa=>(Wa.value=ne==null?void 0:ne[Wa.name],Wa)),ne!=null&&ne.菜单选项&&((pa=ne==null?void 0:ne.菜单选项)==null?void 0:pa.length)>0){const Wa=await ca.menuToContentType(ne==null?void 0:ne.菜单选项);_a=_a==null?void 0:_a.map(ee=>((ee==null?void 0:ee.name)==="组信息选项"&&(ee.contents=Wa),ee))}_a=ca.formToOptionsContents(_a),U(_a),y.value=await ca.selectToBase(I.cloneDeep(_a))}},ce=ne=>{ne||(c.value=y.value)},Ee=async ne=>{await W(ne),c.value=y.value},Ie=Pa.debounce(async()=>{var de,Ke,Ta,oe,S,le,me,ue,Ne,pa,_a,Wa;c.value=y.value;let ne={};ne.width=((Ke=(de=c.value)==null?void 0:de[0])==null?void 0:Ke.width)??1,u.value!==""?ne.id=u.value:(E.value++,ne.id="id"+E.value);let ge=await((S=(oe=(Ta=ca.FormContent)==null?void 0:Ta.find(ee=>{var la,Ve;return(ee==null?void 0:ee.key)===(((Ve=(la=c.value)==null?void 0:la.find(ka=>(ka==null?void 0:ka.label)==="类型"))==null?void 0:Ve.value)??"label")}))==null?void 0:oe.value)==null?void 0:S.value)??((me=(le=ca.FormContent)==null?void 0:le.find(ee=>{var la,Ve;return(ee==null?void 0:ee.key)===(((Ve=(la=c.value)==null?void 0:la.find(ka=>(ka==null?void 0:ka.label)==="类型"))==null?void 0:Ve.value)??"label")}))==null?void 0:me.value);if((ue=c.value)==null||ue.forEach(ee=>{const la=ge==null?void 0:ge.find(Ve=>(Ve==null?void 0:Ve.label)===(ee==null?void 0:ee.label));la&&(ne[la.key]=ee.value)}),ne.width=ne.width?ne.width:1,ne.key=ne==null?void 0:ne.label,ne.isFormColHidden=ne==null?void 0:ne.isFormColHidden,(Ne=m.value)!=null&&Ne.find(ee=>ee.id===ne.id))m.value=(pa=m.value)==null?void 0:pa.map(ee=>(ee.id===ne.id&&(ee=ne),ee));else{let ee=I.cloneDeep(m.value);ee.push(ne),m.value=ee}m.value=m.value.map(({id:ee,...la})=>la),s.value=!1,u.value="";let X=I.cloneDeep(n.originalItemContents);(_a=I.cloneDeep(n.originalItemContents))!=null&&_a.find(ee=>(ee==null?void 0:ee.key)==="formContent")?X=(Wa=I.cloneDeep(n.originalItemContents))==null?void 0:Wa.map(ee=>((ee==null?void 0:ee.key)==="formContent"&&(ee.contents=m.value),ee)):X.push({key:"formContent",contents:m.value}),o("change",X)},300),De=()=>{s.value=!1,f.value=!1,u.value="",y.value=[],w.value=[]};return a.watch(()=>n.originalItemContents,()=>{var ge,X,de,Ke,Ta,oe;if(!n.originalItemContents||n.originalItemContents.length===0)return;const ne=I.cloneDeep(n.originalItemContents);m.value=((ge=ne==null?void 0:ne.find(S=>(S==null?void 0:S.key)==="formContent"))==null?void 0:ge.contents)??[],v.value=((X=ne==null?void 0:ne.find(S=>(S==null?void 0:S.key)==="formButton"))==null?void 0:X.contents)??[],x.value=(de=ne==null?void 0:ne.find(S=>(S==null?void 0:S.key)==="enableWrap"))!=null&&de.contents?!((Ke=ne==null?void 0:ne.find(S=>(S==null?void 0:S.key)==="enableWrap"))!=null&&Ke.contents):!0,m.value=(Ta=I.cloneDeep(m.value))==null?void 0:Ta.map((S,le)=>{var ue;let me=S;return me.id=(S==null?void 0:S.id)??le,S!=null&&S.label||(S.label=(S==null?void 0:S.key)??(S==null?void 0:S.label)??""),S!=null&&S.type||(S.type=(S==null?void 0:S.type)??""),S.contents=((ue=S==null?void 0:S.options)==null?void 0:ue.length)===0?(S==null?void 0:S.contents)??"":S==null?void 0:S.options,me}),m.value=ca.formToOptionsContents(m.value),v.value=(oe=v.value)==null?void 0:oe.map((S,le)=>S={label:(S==null?void 0:S.label)??"",type:(S==null?void 0:S.type)??"",background:(S==null?void 0:S.background)??"var(--ssComponent-primary-color)",id:le})},{deep:!0,immediate:!0}),(ne,ge)=>{const X=a.resolveComponent("svg-icon"),de=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock("div",K1,[a.createElementVNode("div",Y1,[a.createElementVNode("div",G1,[ge[2]||(ge[2]=a.createElementVNode("div",null,a.toDisplayString("表单内容"),-1)),a.createVNode(de,{class:"icon-content",id:"themeButton",onClick:k},{icon:a.withCtx(()=>[a.createVNode(X,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[ge[1]||(ge[1]=a.createElementVNode("div",null,a.toDisplayString("新增"),-1))]),_:1,__:[1]})]),a.createElementVNode("div",J1,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(m.value,(Ke,Ta)=>(a.openBlock(),a.createElementBlock("div",{key:Ta},[a.createElementVNode("div",X1,[a.createElementVNode("div",null,a.toDisplayString(Ke.label),1),a.createElementVNode("div",Z1,[a.createVNode(X,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oe=>A(Ke)},null,8,["onClick"]),a.createVNode(X,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oe=>b(Ke)},null,8,["onClick"])])])]))),128))]),a.createElementVNode("div",Q1,[ge[4]||(ge[4]=a.createElementVNode("div",null,a.toDisplayString("表单按钮"),-1)),a.createVNode(de,{class:"icon-content",id:"themeButton",onClick:T},{icon:a.withCtx(()=>[a.createVNode(X,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[ge[3]||(ge[3]=a.createTextVNode(" 新增 "))]),_:1,__:[3]})]),a.createElementVNode("div",e2,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(v.value,(Ke,Ta)=>(a.openBlock(),a.createElementBlock("div",{key:Ta},[a.createElementVNode("div",a2,[a.createElementVNode("div",null,a.toDisplayString(Ke.label),1),a.createElementVNode("div",l2,[a.createVNode(X,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oe=>N(Ke)},null,8,["onClick"]),a.createVNode(X,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:oe=>$(Ke)},null,8,["onClick"])])])]))),128))]),ge[6]||(ge[6]=a.createElementVNode("div",{class:"operate-title"},[a.createElementVNode("div",null,a.toDisplayString("表单布局"))],-1)),a.createElementVNode("div",r2,[ge[5]||(ge[5]=a.createElementVNode("div",{class:"operate-center-content"},a.toDisplayString("是否自动撑宽"),-1)),a.createVNode(pl._sfc_main$1,{modelValue:x.value,"onUpdate:modelValue":ge[0]||(ge[0]=Ke=>x.value=Ke)},null,8,["modelValue"])])]),a.createVNode(vr.ssDialog,{visible:s.value,onBeforeDestroy:De,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",n2,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:c.value,key:c.value,isEnableWrap:!0,onChange:W,onChangeVisible:ce,onBlurChange:Ee},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",o2,[a.createVNode(de,{onClick:De,class:"cancel-button button",id:"themeBorderButton"},{default:a.withCtx(()=>ge[7]||(ge[7]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[7]}),a.createVNode(de,{class:"ok-button button",onClick:a.unref(Ie),id:"themeButton"},{default:a.withCtx(()=>ge[8]||(ge[8]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[8]},8,["onClick"])])]),_:1},8,["visible"]),a.createVNode(vr.ssDialog,{visible:f.value,onBeforeDestroy:De,width:840},{default:a.withCtx(()=>[a.createElementVNode("div",i2,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:B.value,key:B.value,isEnableWrap:!0,onChange:_},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",{class:"dialog-footer"},[a.createElementVNode("div",{onClick:De,class:"cancel-button button"},a.toDisplayString("取消")),a.createElementVNode("div",{class:"ok-button button",onClick:Y},a.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},vs=ql._export_sfc(t2,[["__scopeId","data-v-20850524"]]),s2={class:"step-module content"},c2={class:"module-data"},u2={class:"step-module layout"},d2={class:"form-content"},p2=a.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.ref([{label:"方向:",prop:"direction",type:"RADIO",contents:[{label:"水平",value:"horizontal"},{label:"垂直",value:"vertical"}],value:"horizontal"},{label:"是否居中:",prop:"alignCenter",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0},{label:"应用简洁风格",prop:"simple",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!1}]),c=a.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"标题",prop:"title",type:"input",value:""},{label:"描述",prop:"description",type:"input",value:""}]),y=a.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),f=a.reactive({visible:!1,width:"40%",title:"步骤条"}),v=a.ref("create"),m=a.ref({}),u=a.ref([]),x=A=>{var N;m.value=A,o("change",(N=w())==null?void 0:N.compData)},E=(A,N)=>{var Y,b;switch(A){case"create":(Y=c.value)==null||Y.forEach($=>{$.value=""}),v.value="create",f.visible=!0;break;case"update":(b=c.value)==null||b.forEach($=>{$.value=N[$==null?void 0:$.prop]}),v.value="update",f.visible=!0;break;case"delete":u.value.splice(N,1),v.value="delete";break}},B=A=>{var N,Y,b;if((A==null?void 0:A.buttonName)==="确认"){const $=I.cloneDeep(A==null?void 0:A.content);switch(Object.keys($).forEach(T=>{$[T]===""&&delete $[T]}),v.value){case"create":u.value.push({...$,index:((N=u.value)==null?void 0:N.length)+1});break;case"update":u.value=(Y=u.value)==null?void 0:Y.map(T=>T.index===($==null?void 0:$.index)?{...T,title:$==null?void 0:$.title,description:$==null?void 0:$.description}:T);break}o("change",(b=w())==null?void 0:b.compData),f.visible=!1}else f.visible=!1},w=()=>({comp:"Step",compData:[{key:"stepList",contents:u.value},{key:"stepConfig",contents:m.value}]}),V=()=>{f.visible=!1};return a.watch(()=>n==null?void 0:n.itemContents,A=>{var N,Y;A&&(m.value=((N=A==null?void 0:A.find(b=>b.key==="stepConfig"))==null?void 0:N.contents)??{},u.value=((Y=A==null?void 0:A.find(b=>b.key==="stepList"))==null?void 0:Y.contents)??[])},{immediate:!0}),(A,N)=>{const Y=a.resolveComponent("svg-icon"),b=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock(a.Fragment,null,[a.createElementVNode("div",null,[a.createElementVNode("div",s2,[N[2]||(N[2]=a.createElementVNode("h4",{class:"module-title"},"内容",-1)),a.createVNode(b,{class:"module-icon",id:"themeButton",onClick:N[0]||(N[0]=$=>E("create"))},{icon:a.withCtx(()=>[a.createVNode(Y,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[N[1]||(N[1]=a.createTextVNode(" 新增 "))]),_:1,__:[1]})]),a.createElementVNode("div",c2,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(u.value,($,T)=>(a.openBlock(),a.createElementBlock("div",{class:"module-data-item",key:T},[a.createElementVNode("span",null,a.toDisplayString($==null?void 0:$.title),1),a.createElementVNode("div",null,[a.createVNode(b,{type:"primary",size:"small",onClick:k=>E("update",{...$,index:T+1})},{default:a.withCtx(()=>N[3]||(N[3]=[a.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),a.createVNode(b,{type:"danger",size:"small",onClick:k=>E("delete",T)},{default:a.withCtx(()=>N[4]||(N[4]=[a.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),a.createElementVNode("div",u2,[N[5]||(N[5]=a.createElementVNode("div",{class:"module-title"},"布局",-1)),a.createVNode(pl.ssForm,{rowContents:s.value,onChange:x},null,8,["rowContents"])])]),a.createVNode(vr.ssDialog,{visible:f.visible,title:f.title,onBeforeDestroy:V,width:f.width},{default:a.withCtx(()=>[a.createElementVNode("div",d2,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:c.value,key:c.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:y.value,onOnButtonClick:B},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),f2=ql._export_sfc(p2,[["__scopeId","data-v-7dbd17f2"]]),h2={class:"step-module content"},v2={class:"module-data"},m2={class:"step-module layout"},y2={class:"form-content"},g2=a.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.ref("create"),c=a.ref({}),y=a.ref([]),f=a.ref([{label:"方向:",prop:"placement",type:"radio",contents:[{label:"底部",value:"bottom"},{label:"顶部",value:"top"}],value:"bottom"},{label:"节点类型:",prop:"type",type:"select",contents:[{label:"primary",value:"primary"},{label:"success",value:"success"},{label:"warning",value:"warning"},{label:"danger",value:"danger"},{label:"info",value:"info"}],value:"primary"},{label:"颜色:",prop:"color",type:"color",value:""},{label:"尺寸:",prop:"size",type:"radio",contents:[{label:"normal",value:"normal"},{label:"large",value:"large"}],value:"normal"},{label:"是否空心",prop:"isHollow",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0},{label:"是否居中",prop:"isCenter",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0}]),v=a.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"内容",prop:"content",type:"input",value:""},{label:"时间戳",prop:"timestamp",type:"datetime",value:""}]),m=a.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),u=a.reactive({visible:!1,width:"40%",title:"时间线"}),x=A=>{var N;c.value=A,o("change",(N=w())==null?void 0:N.compData)},E=(A,N)=>{var Y,b;switch(A){case"create":(Y=v.value)==null||Y.forEach($=>{$.value=""}),s.value="create",u.visible=!0;break;case"update":(b=v.value)==null||b.forEach($=>{$.value=N[$==null?void 0:$.prop]}),s.value="update",u.visible=!0;break;case"delete":y.value.splice(N,1),s.value="delete";break}},B=A=>{var N,Y,b,$;if((A==null?void 0:A.buttonName)==="确认"){const T=I.cloneDeep(A==null?void 0:A.content);switch(Object.keys(T).forEach(k=>{T[k]===""&&delete T[k]}),s.value){case"create":(Y=y.value)==null||Y.push({...T,index:((N=y.value)==null?void 0:N.length)+1});break;case"update":y.value=(b=y.value)==null?void 0:b.map(k=>k.index===(T==null?void 0:T.index)?{...k,content:T==null?void 0:T.content,timestamp:T==null?void 0:T.timestamp}:k);break}o("change",($=w())==null?void 0:$.compData),u.visible=!1}else u.visible=!1},w=()=>({comp:"TimeLine",compData:[{key:"timeLineList",contents:y.value},{key:"timeLineConfig",contents:c.value}]}),V=()=>{u.visible=!1};return a.watch(()=>n==null?void 0:n.itemContents,A=>{var N,Y;A&&(c.value=((N=A==null?void 0:A.find(b=>b.key==="timeLineConfig"))==null?void 0:N.contents)??{},y.value=((Y=A==null?void 0:A.find(b=>b.key==="timeLineList"))==null?void 0:Y.contents)??[])},{immediate:!0}),(A,N)=>{const Y=a.resolveComponent("svg-icon"),b=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock(a.Fragment,null,[a.createElementVNode("div",null,[a.createElementVNode("div",h2,[N[2]||(N[2]=a.createElementVNode("h4",{class:"module-title"},"内容",-1)),a.createVNode(b,{class:"module-icon",id:"themeButton",onClick:N[0]||(N[0]=$=>E("create"))},{icon:a.withCtx(()=>[a.createVNode(Y,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[N[1]||(N[1]=a.createTextVNode(" 新增 "))]),_:1,__:[1]})]),a.createElementVNode("div",v2,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(y.value,($,T)=>(a.openBlock(),a.createElementBlock("div",{class:"module-data-item",key:T},[a.createElementVNode("span",null,a.toDisplayString($==null?void 0:$.content),1),a.createElementVNode("div",null,[a.createVNode(b,{type:"primary",size:"small",onClick:k=>E("update",{...$,index:T+1})},{default:a.withCtx(()=>N[3]||(N[3]=[a.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),a.createVNode(b,{type:"danger",size:"small",onClick:k=>E("delete",T)},{default:a.withCtx(()=>N[4]||(N[4]=[a.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),a.createElementVNode("div",m2,[N[5]||(N[5]=a.createElementVNode("div",{class:"module-title"},"布局",-1)),a.createVNode(pl.ssForm,{rowContents:f.value,onChange:x},null,8,["rowContents"])])]),a.createVNode(vr.ssDialog,{visible:u.visible,title:u.title,onBeforeDestroy:V,width:u.width},{default:a.withCtx(()=>[a.createElementVNode("div",y2,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:v.value,key:v.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:m.value,onOnButtonClick:B},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),b2=ql._export_sfc(g2,[["__scopeId","data-v-39ffc861"]]),k2={};function x2(l,r){return a.openBlock(),a.createElementBlock("div")}const _2=ql._export_sfc(k2,[["render",x2]]),w2={class:"extra-content"},C2={key:0},E2={key:1},S2={class:"dialog-footer"},D2={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},emits:["change"],setup(l,{emit:r}){const n=l,o=a.ref(0),s=a.ref(),c=a.ref(),y=r,f=a.ref(!1),v=a.ref({}),m=a.ref({}),u=a.ref();a.watch(()=>[n.itemData],()=>{var $;const b=I.cloneDeep(n.itemData);s.value=($=I.cloneDeep(b))==null?void 0:$.map(T=>{var k;if(T.key==="extra"){let _=[];(k=T.value)==null||k.forEach(U=>{var W;_.push((W=Object.values(U))==null?void 0:W[0])}),T.value=_}return T})},{deep:!0,immediate:!0});const x=(b,$,T,k)=>{var U;let _={};((U=b==null?void 0:b[0])==null?void 0:U.contents)==="详情"&&(f.value=!0,_[$]=b,c.value=b==null?void 0:b.filter(W=>(W==null?void 0:W.key)!=="tableContentName"),v.value=_,m.value=T,u.value=k.id)},E=b=>{var W,ce,Ee,Ie;const $=(ce=(W=Object.values(I.cloneDeep(v.value)))==null?void 0:W[0])==null?void 0:ce.filter(De=>(De==null?void 0:De.key)==="tableContentName"),T=(Ie=(Ee=Object.values(I.cloneDeep(v.value)))==null?void 0:Ee[0])==null?void 0:Ie.filter(De=>(De==null?void 0:De.key)!=="tableContentName"),k=T==null?void 0:T.map((De,ne)=>{var ge;return ne===b.index&&(De==null?void 0:De.comp)==="Table"&&(De.compData=(ge=De.compData)==null?void 0:ge.map(X=>{var de,Ke;return(X==null?void 0:X.key)==="tableContents"&&(X.contents=(Ke=(de=b.content)==null?void 0:de.map(Ta=>{let oe={};for(let S in Ta)S!=="id"&&(oe[S]=Ta[S]);return oe}))==null?void 0:Ke.map(Ta=>Object.values(Ta))),X})),De});k.unshift($==null?void 0:$[0]);let _=I.cloneDeep(v.value),U={};for(let De in _)U[De]=k;v.value=U},B=()=>{f.value=!1,v.value={},m.value={},u.value=void 0,o.value++},w=b=>{var W,ce,Ee,Ie;const $=(ce=(W=Object.values(I.cloneDeep(v.value)))==null?void 0:W[0])==null?void 0:ce.filter(De=>(De==null?void 0:De.key)==="tableContentName"),T=(Ie=(Ee=Object.values(I.cloneDeep(v.value)))==null?void 0:Ee[0])==null?void 0:Ie.filter(De=>(De==null?void 0:De.key)!=="tableContentName"),k=T==null?void 0:T.map((De,ne)=>(ne===b.index&&(De.compData=b.contents),De));k.unshift($==null?void 0:$[0]);let _=I.cloneDeep(v.value),U={};for(let De in _)U[De]=k;v.value=U},V=()=>{var $,T;let b={};for(let k in m.value)k===(($=Object.keys(v.value))==null?void 0:$[0])?b[k]=(T=Object.values(v.value))==null?void 0:T[0]:b[k]=m.value[k];y("change",{buttonName:"编辑",index:u.value,singleContent:b},"methodData"),f.value=!1,v.value={},m.value={},u.value=void 0},A=()=>{f.value=!1,v.value={},m.value={},u.value=void 0},N=b=>{y("change",b,"methodData")},Y=b=>Do(b);return(b,$)=>{const T=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock("div",w2,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(s.value,(k,_)=>(a.openBlock(),a.createElementBlock("div",{key:o.value},[(k==null?void 0:k.key)==="extra"?(a.openBlock(),a.createElementBlock("div",C2)):(a.openBlock(),a.createElementBlock("div",E2,[(a.openBlock(),a.createBlock(a.resolveDynamicComponent(Y(k.comp)),{itemData:k==null?void 0:k.compData,childItemData:k==null?void 0:k.itemChildData,key:_,index:(k==null?void 0:k.id)??_,onContentClick:x,onChange:N},null,40,["itemData","childItemData","index"]))]))]))),128)),a.createVNode(vr.ssDialog,{visible:f.value,onBeforeDestroy:A},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(c.value,(k,_)=>(a.openBlock(),a.createElementBlock("div",{key:_,class:"extra-dialog"},[(a.openBlock(),a.createBlock(a.resolveDynamicComponent(Y(k.comp)),{itemData:k==null?void 0:k.compData,onChange:E,childItemData:k==null?void 0:k.itemChildData,key:_,onContentChange:w,index:(k==null?void 0:k.id)??_,class:"extra-component"},null,40,["itemData","childItemData","index"]))]))),128))]),footer:a.withCtx(()=>[a.createElementVNode("div",S2,[a.createVNode(T,{class:"cancel-button footer-button",onClick:B,id:"themeBorderButton"},{default:a.withCtx(()=>$[0]||($[0]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[0]}),a.createVNode(T,{class:"confirm-button footer-button",onClick:V,id:"themeButton"},{default:a.withCtx(()=>$[1]||($[1]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},N2=ql._export_sfc(D2,[["__scopeId","data-v-2d9c5ab2"]]),B2={key:0,class:"method-content"},T2={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},setup(l){const r=a.ref([]),n=ca.useOriginalState(I.pinia),{originalPath:o}=I.storeToRefs(n),s=l,c=a.ref(!1),y=a.ref(),f=ca.useTableComp(I.pinia),{multipleTableConst:v}=I.storeToRefs(f),m=I.useModelComp(I.pinia),u=a.ref(!1),x=I.useMenuState(I.pinia),E=I.useLoginState(I.pinia),{itemData:B,isEdit:w,routeToChildPath:V,tableViewContents:A,lockingPage:N,payloadTypes:Y}=I.storeToRefs(m),{activeMenuPath:b,platform:$,childMenu:T}=I.storeToRefs(x),{loginUserInfo:k}=I.storeToRefs(E),_=a.ref(!1),U=async()=>{var oe,S;(oe=r.value)!=null&&oe.find(le=>(le==null?void 0:le.buttonName)==="保存")&&await X((S=r.value)==null?void 0:S.find(le=>(le==null?void 0:le.buttonName)==="保存")),await ca.onSaveBack()};a.watch(()=>B.value,async()=>{w.value==="view"&&!_.value&&await Ta(I.cloneDeep(s.itemData)),_.value=!1},{deep:!0});const W=()=>{c.value=!1,y.value=void 0},ce=oe=>oe.map(S=>{const le={};for(const me in S){const ue=S[me];if(me.includes(v.value)){const Ne=me.split(v.value);let pa=le;Ne.forEach((_a,Wa)=>{Wa===Ne.length-1?pa[_a]=ue:(pa[_a]||(pa[_a]={}),pa=pa[_a])})}else le[me]=ue}return le}),Ee=async(oe,S,le=[])=>{var ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa;let me=(ue=I.cloneDeep(S))==null?void 0:ue.filter(P=>(P==null?void 0:P.comp)!=="methodButton");if(oe!=null&&oe.includes("[")){let P=(ee=(Wa=(_a=(pa=(Ne=I.cloneDeep(oe))==null?void 0:Ne.split("["))==null?void 0:pa[1])==null?void 0:_a.split("]"))==null?void 0:Wa[0])==null?void 0:ee.split(":"),F="";if(P!=null&&P[0]){let J=(la=me==null?void 0:me.find(ie=>(ie==null?void 0:ie.name)===(P==null?void 0:P[0])))==null?void 0:la.compData;if(!J){let ie=(Ve=oe==null?void 0:oe.split("["))==null?void 0:Ve[0],se=await ca.getItemData(ie,sessionStorage.getItem("systemKey"),"",!1,"","",le);J=(ka=se==null?void 0:se.find(ma=>(ma==null?void 0:ma.name)===(P==null?void 0:P[0])))==null?void 0:ka.compData}J==null||J.forEach(ie=>{var se,ma,oa,Oe,_e,wa;if((ie==null?void 0:ie.key)==="formContent")(se=ie==null?void 0:ie.contents)==null||se.forEach(ve=>{var Xe;(ve==null?void 0:ve.key)===(P==null?void 0:P[1])&&(Array.isArray(ve==null?void 0:ve.value)?F=ve==null?void 0:ve.value:F=(Xe=ve==null?void 0:ve.value)==null?void 0:Xe.toString())});else if((ie==null?void 0:ie.key)==="tableContents"){let ve=[],Xe=(ma=J==null?void 0:J.find(Pe=>(Pe==null?void 0:Pe.key)==="header"))==null?void 0:ma.contents,aa=(P==null?void 0:P[1])??"";if(Xe!=null&&Xe.every(Pe=>Array.isArray(Pe))){let Pe=ca.getColumnChild((_e=Xe==null?void 0:Xe[0])==null?void 0:_e.filter(xa=>(xa==null?void 0:xa.label)!=="操作"));(wa=ie.contents)==null||wa.forEach(xa=>{let Le={};xa=xa==null?void 0:xa.filter(va=>!(va!=null&&va.id)),Pe==null||Pe.forEach((va,re)=>{let Ce=xa[re];typeof xa[re]=="number"&&(Ce=xa[re].toString()),(aa===""||aa===va.prop)&&(Le[va.prop]=Ce)}),ve.push(Le)}),ve=ce(ve)}else{let Pe=(oa=Xe==null?void 0:Xe.map(xa=>xa==null?void 0:xa.label))==null?void 0:oa.filter(xa=>xa!=="操作");(Oe=ie.contents)==null||Oe.forEach(xa=>{let Le={};xa=xa==null?void 0:xa.filter(va=>!(va!=null&&va.id)),Pe==null||Pe.forEach((va,re)=>{let Ce=xa[re];typeof xa[re]=="number"&&(Ce=xa[re].toString()),(aa===""||aa===va)&&(Le[va]=Ce)}),ve.push(Le)})}F=ve}})}return F}else if(oe!=null&&oe.includes("/")){let P={};return(He=I.cloneDeep(me))==null||He.forEach((F,J)=>{var ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye;if((F==null?void 0:F.comp)==="Table"){let Ma=Array.isArray((ma=(se=(ie=F==null?void 0:F.compData)==null?void 0:ie.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:se.contents)==null?void 0:ma[0])?(wa=(_e=(Oe=(oa=F==null?void 0:F.compData)==null?void 0:oa.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:Oe.contents)==null?void 0:_e[0])==null?void 0:wa.some(ba=>ba==null?void 0:ba.children):[],Ue=(aa=(Xe=(ve=F==null?void 0:F.compData)==null?void 0:ve.find(ba=>(ba==null?void 0:ba.key)==="tableContents"))==null?void 0:Xe.contents)==null?void 0:aa.map(ba=>(ba!=null&&ba.find($a=>$a==null?void 0:$a.id)&&(ba=ba.slice(1)),ba)),Ya=(re=(va=(Le=(xa=(Pe=F==null?void 0:F.compData)==null?void 0:Pe.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:xa.contents)==null?void 0:Le[0])==null?void 0:va[0])==null?void 0:re.label,ga=(Z=(Ce=F==null?void 0:F.compData)==null?void 0:Ce.find(ba=>(ba==null?void 0:ba.key)==="header"))==null?void 0:Z.contents;if(Ma)(Ma==null?void 0:Ma.length)===0?P[F.name]=P!=null&&P[F.name]?P[F.name]:ca.tableToForm(Ue,ga):P[Ya]=ca.tableToForm(Ue,ga);else{const ba=[];ga=ga.slice(1,ga.length-1),ga==null||ga.forEach(($a,Sa)=>{Ue==null||Ue.forEach(Na=>{ba.push({key:$a.label+Na[0],value:Na[Sa+1]})})}),P["form"+J]=ba}}else{const Ma=(Ye=(fa=F.compData)==null?void 0:fa.find(Ya=>(Ya==null?void 0:Ya.key)==="formContent"))==null?void 0:Ye.contents;P!=null&&P.form||(P.form=[]);const Ue=[];Ma==null||Ma.forEach(Ya=>{Ya.key!==""&&(Ya={key:(Ya==null?void 0:Ya.key)??(Ya==null?void 0:Ya.label),value:Ya==null?void 0:Ya.value},Ue.push(Ya))}),P.form=[...Ue,...I.cloneDeep(P==null?void 0:P.form)]}}),P}else{if(oe==="createInsofDataApi"){let P=(Te=I.cloneDeep(S))==null?void 0:Te[0];return P={comp:(Re=I.cloneDeep(P))==null?void 0:Re.comp,compData:(Ge=I.cloneDeep(P))==null?void 0:Ge.compData,name:(Ga=I.cloneDeep(P))==null?void 0:Ga.name,isShow:(Fa=I.cloneDeep(P))==null?void 0:Fa.isShow},{key:{type:"structure",systemKey:sessionStorage.getItem("systemKey"),parentTable:"",pageKey:b.value},value:{pageData:P}}}return oe}},Ie=async(oe,S,le)=>{var Ne,pa,_a;let me=await ca.getItemData(S,sessionStorage.getItem("systemKey"),""),ue=me==null?void 0:me.find(Wa=>(Wa==null?void 0:Wa.name)===(le==null?void 0:le[0]));if(ue){if((ue==null?void 0:ue.comp)==="Table"){let Wa={};for(let Re in I.cloneDeep(oe))I.cloneDeep(oe)[Re]!=="loginUser"?Wa[Re]=I.cloneDeep(oe)[Re]:Wa[Re]=((Ne=k.value)==null?void 0:Ne.account)||((pa=k.value)==null?void 0:pa.账号);let ee=[],la=Wa;Array.isArray(oe)||(la=[Wa]),la==null||la.forEach(Re=>{ee.push({[Re[le[1]]]:Re})});let Ve=[],ka=ee==null?void 0:ee.map(Re=>{var Ge;return(Ge=Object.keys(Re))==null?void 0:Ge[0]});me==null||me.forEach(Re=>{var Ge;(Re==null?void 0:Re.name)===(le==null?void 0:le[0])&&((Ge=Re==null?void 0:Re.compData)==null||Ge.forEach(Ga=>{var Fa;(Ga==null?void 0:Ga.key)==="tableContents"&&((Fa=Ga==null?void 0:Ga.contents)==null||Fa.forEach(P=>{P!=null&&P.some(F=>ka.includes(F))&&Ve.push({[P.find(F=>F.id).id]:P.find(F=>ka.includes(F))})}))}))});let He=Ve==null?void 0:Ve.map(Re=>{var Ge;return(Ge=Object.keys(Re))==null?void 0:Ge[0]}),Te=[];if(He==null||He.forEach(Re=>{var Fa;let Ge=(Fa=Ve==null?void 0:Ve.find(P=>{var F;return((F=Object.keys(P))==null?void 0:F[0].toString())===Re.toString()}))==null?void 0:Fa[Re],Ga=ee==null?void 0:ee.find(P=>{var F;return((F=Object.keys(P))==null?void 0:F[0])===Ge});Te.push({id:parseInt(Re),value:{tableData:Ga[Ge]}})}),(Te==null?void 0:Te.length)>0)return Te}else if((ue==null?void 0:ue.comp)==="Form"){let Wa=I.cloneDeep(ue);Wa.compData=(_a=Wa.compData)==null?void 0:_a.map(Ve=>{var ka;return(Ve==null?void 0:Ve.key)==="formContent"&&(Ve.contents=(ka=Ve.contents)==null?void 0:ka.map(He=>((He==null?void 0:He.key)===(le==null?void 0:le[1])&&(He.value=(oe==null?void 0:oe[He==null?void 0:He.prop])||oe),He))),Ve});let ee={};for(let Ve in Wa)Ve!=="id"&&(ee[Ve]=Wa[Ve]);let la=[];if(la.push({id:ue==null?void 0:ue.id,keyType:le==null?void 0:le[1],value:{pageData:ee}}),(la==null?void 0:la.length)>0)return la}}},De=async(oe,S,le)=>{var Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te;let me=await ca.getItemData(S,sessionStorage.getItem("systemKey"),""),ue=me==null?void 0:me.find(Re=>(Re==null?void 0:Re.name)===(le==null?void 0:le[0]));if(ue){if((ue==null?void 0:ue.comp)==="Table"){let Re={};for(let Ge in I.cloneDeep(oe))I.cloneDeep(oe)[Ge]!=="loginUser"?Re[Ge]=I.cloneDeep(oe)[Ge]:Re[Ge]=((Ne=k.value)==null?void 0:Ne.account)||((pa=k.value)==null?void 0:pa.账号);await yr.createInsofDataApi({key:{type:"data",pageKey:S,tableId:ue==null?void 0:ue.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Re}})}else if((ue==null?void 0:ue.comp)==="Form"){let Re=I.cloneDeep(ue),Ge=Object.keys(oe),Ga="";(Wa=(_a=I.cloneDeep(Re))==null?void 0:_a.compData)==null||Wa.forEach(se=>{var ma,oa;(se==null?void 0:se.key)==="formContent"&&((oa=(ma=I.cloneDeep(se))==null?void 0:ma.contents)==null||oa.forEach(Oe=>{var _e;Ge.includes(Oe==null?void 0:Oe.key)&&(Oe==null?void 0:Oe.value)===((_e=k.value)==null?void 0:_e.姓名)&&(Ga=Oe==null?void 0:Oe.key)}))});let Fa=[];(ee=Object.values(oe[Ga]))==null||ee.forEach(se=>{se!=null&&se.includes("(")&&Fa.push(se)}),Fa=[...new Set(Fa)];const P=Fa==null?void 0:Fa.map(async se=>{var wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa;let ma="";(xa=(Pe=(aa=(Xe=(ve=(wa=I.cloneDeep(se))==null?void 0:wa.split("("))==null?void 0:ve[1])==null?void 0:Xe.split(")"))==null?void 0:aa[0])==null?void 0:Pe.split(":"))==null||xa.forEach(Ye=>{ma=ma===""?ma+Ye.replaceAll("'",""):ma+"/"+Ye.replaceAll("'","")});let oa=[];(fa=(Z=(Ce=(re=(va=(Le=I.cloneDeep(se))==null?void 0:Le.split("<"))==null?void 0:va[1])==null?void 0:re.split(">"))==null?void 0:Ce[0])==null?void 0:Z.split(":"))==null||fa.forEach(Ye=>{oa.push(Ye.replaceAll("'",""))});const Oe=await ca.getItemData(ma,sessionStorage.getItem("systemKey"),"");let _e="";return Oe==null||Oe.forEach(Ye=>{var Ma;Ye.name===(oa==null?void 0:oa[0])&&((Ma=Ye==null?void 0:Ye.compData)==null||Ma.forEach(Ue=>{var Ya;(Ue==null?void 0:Ue.key)==="formContent"&&((Ya=Ue.contents)==null||Ya.forEach(ga=>{(ga==null?void 0:ga.key)===(oa==null?void 0:oa[1])&&(_e=ga==null?void 0:ga.value)}))}))}),{[se]:_e}}),F=await Promise.all(P);Re.compData=(Ve=(la=I.cloneDeep(Re))==null?void 0:la.compData)==null?void 0:Ve.map(se=>{var ma,oa;return(se==null?void 0:se.key)==="formContent"&&(se.contents=(oa=(ma=I.cloneDeep(se))==null?void 0:ma.contents)==null?void 0:oa.map(Oe=>{var _e,wa,ve,Xe;return(_e=oe[Ga])!=null&&_e[Oe==null?void 0:Oe.key]&&(oe[Ga][Oe==null?void 0:Oe.key].includes("(")?Oe.value=(wa=F==null?void 0:F.find(aa=>{var Pe;return((Pe=Object.keys(aa))==null?void 0:Pe[0])===oe[Ga][Oe==null?void 0:Oe.key]}))==null?void 0:wa[oe[Ga][Oe==null?void 0:Oe.key]]:Oe.value=(Xe=(ve=I.cloneDeep(oe))==null?void 0:ve[Ga])==null?void 0:Xe[Oe==null?void 0:Oe.key]),Oe})),se});const J=await yr.getInsofDataApi({key:{type:"structure",pageKey:S,systemKey:sessionStorage.getItem("systemKey")}});let ie="";((ka=J==null?void 0:J.data)==null?void 0:ka.type)==="success"&&((Te=(He=J==null?void 0:J.data)==null?void 0:He.result)==null||Te.forEach(se=>{var ma,oa;((oa=(ma=se==null?void 0:se.value)==null?void 0:ma.pageData)==null?void 0:oa.name)===(le==null?void 0:le[0])&&(ie=se.id)}),await yr.updateInsofDataApi({id:ie,value:{pageData:Re}}))}}},ne=(oe,S="",le={})=>{for(const[me,ue]of Object.entries(oe)){const Ne=S?`${S}.${me}`:me;ue!==null&&typeof ue=="object"&&!Array.isArray(ue)&&Object.prototype.toString.call(ue)!=="[object Date]"?ne(ue,Ne,le):le[Ne]=ue}return le},ge=async(oe,S,le,me)=>{var pa,_a,Wa,ee,la,Ve,ka,He,Te,Re,Ge,Ga,Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe;let ue=await ca.getItemData(S,sessionStorage.getItem("systemKey"),""),Ne=ue==null?void 0:ue.find(aa=>(aa==null?void 0:aa.name)===(le==null?void 0:le[0]));if(Ne){if(!(le!=null&&le[1])&&(Ne==null?void 0:Ne.comp)==="Table"){let aa={},Pe=[],xa=(_a=(pa=Ne==null?void 0:Ne.compData)==null?void 0:pa.find(re=>(re==null?void 0:re.key)==="header"))==null?void 0:_a.contents;xa!=null&&xa.every(re=>Array.isArray(re))?Pe=(ee=ca.getColumnChild((Wa=xa==null?void 0:xa[0])==null?void 0:Wa.filter(re=>(re==null?void 0:re.label)!=="操作")))==null?void 0:ee.map(re=>re==null?void 0:re.prop):Pe=xa==null?void 0:xa.map(re=>re==null?void 0:re.label);for(let re in I.cloneDeep(oe))if(I.cloneDeep(oe)[re]!=="loginUser"){let Ce=ne(I.cloneDeep(oe)[re]),Z={};for(let fa in Ce)if(Pe!=null&&Pe.find(Ye=>Ye===fa))Z[fa]=Ce[fa];else if(Pe!=null&&Pe.find(Ye=>(Ye==null?void 0:Ye.toUpperCase())===(fa==null?void 0:fa.toUpperCase()))){let Ye=Pe==null?void 0:Pe.find(Ma=>(Ma==null?void 0:Ma.toUpperCase())===(fa==null?void 0:fa.toUpperCase()));Z[Ye]=Ce[fa]}aa[re]=Z}else aa[re]=((la=k.value)==null?void 0:la.account)||((Ve=k.value)==null?void 0:Ve.账号);let Le=await yr.getInsofDataApi({keyLikes:{tableId:Ne==null?void 0:Ne.id}});if(((He=(ka=Le==null?void 0:Le.data)==null?void 0:ka.result)==null?void 0:He.length)>0){let re=(Re=(Te=Le==null?void 0:Le.data)==null?void 0:Te.result)==null?void 0:Re.map(Ce=>Ce==null?void 0:Ce.id);(re==null?void 0:re.length)>0&&await yr.batchDeleteInsofDataApi({ids:re})}let va=[];if((Ge=Ne==null?void 0:Ne.compData)!=null&&Ge.find(re=>(re==null?void 0:re.key)==="pageColumn")&&((P=(Fa=(Ga=Ne==null?void 0:Ne.compData)==null?void 0:Ga.find(re=>(re==null?void 0:re.key)==="pageColumn"))==null?void 0:Fa.contents)!=null&&P.includes("["))){const re=await yr.getInsofDataApi({id:Ne==null?void 0:Ne.tableId});let Ce=((se=(ie=(J=(F=re==null?void 0:re.data)==null?void 0:F.result)==null?void 0:J[0])==null?void 0:ie.key)==null?void 0:se.pageKey)??"";(ma=Object.values(aa))==null||ma.forEach(Z=>{va.push({key:{type:"data",pageKey:Ce,tableId:Ne==null?void 0:Ne.tableId,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:Z}})})}else(oa=Object.values(aa))==null||oa.forEach(re=>{va.push({key:{type:"data",pageKey:S,tableId:Ne==null?void 0:Ne.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:re}})});(va==null?void 0:va.length)>0&&await yr.batchAddInsofDataApi({dataList:va})}else if(!(le!=null&&le[1])&&(Ne==null?void 0:Ne.comp)==="Form"){let aa=I.cloneDeep(Ne);aa.compData=(_e=(Oe=I.cloneDeep(aa))==null?void 0:Oe.compData)==null?void 0:_e.map(Le=>{var va,re;return(Le==null?void 0:Le.key)==="formContent"&&(Le.contents=(re=(va=I.cloneDeep(Le))==null?void 0:va.contents)==null?void 0:re.map(Ce=>{var Z,fa;return(Z=I.cloneDeep(oe))!=null&&Z[Ce==null?void 0:Ce.key]&&(Ce.value=(fa=I.cloneDeep(oe))==null?void 0:fa[Ce==null?void 0:Ce.key]),Ce})),Le});const Pe=await yr.getInsofDataApi({key:{type:"structure",pageKey:S,systemKey:sessionStorage.getItem("systemKey")}});let xa="";((wa=Pe==null?void 0:Pe.data)==null?void 0:wa.type)==="success"&&((Xe=(ve=Pe==null?void 0:Pe.data)==null?void 0:ve.result)==null||Xe.forEach(Le=>{var va,re;((re=(va=Le==null?void 0:Le.value)==null?void 0:va.pageData)==null?void 0:re.name)===(le==null?void 0:le[0])&&(xa=Le.id)}),await yr.updateInsofDataApi({id:xa,value:{pageData:aa}}))}}},X=async oe=>{var S,le,me,ue,Ne,pa,_a,Wa,ee,la,Ve,ka,He,Te;x.setImportLoading(!0);try{if(oe.api){let Re=new WeakMap,Ge=await ca.getItemData((T==null?void 0:T.value)===""?b.value:T==null?void 0:T.value,sessionStorage.getItem("systemKey"),"",!1,"","",Re),Ga="";if(Ge=Ge==null?void 0:Ge.map(oa=>{var Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce;if((oa==null?void 0:oa.comp)==="Form")oa.compData=(Oe=oa.compData)==null?void 0:Oe.map(Z=>{var fa;return(Z==null?void 0:Z.key)==="formContent"&&(Z.contents=(fa=Z.contents)==null?void 0:fa.map(Ye=>{var Ma;if((Ye==null?void 0:Ye.value)===""&&(Ye==null?void 0:Ye.type)==="Select"){let Ue=ca.judgeContents((Ma=I.cloneDeep(Ye))==null?void 0:Ma.optionUrl,Re);Ye.value=Ye.value||Ue}return Ye})),Z});else if((oa==null?void 0:oa.comp)==="Table"&&(_e=oa.compData)!=null&&_e.find(Z=>(Z==null?void 0:Z.key)==="pageColumn")){let Z=(ve=(wa=oa.compData)==null?void 0:wa.find(Ue=>(Ue==null?void 0:Ue.key)==="pageColumn"))==null?void 0:ve.contents,fa=((aa=(Xe=oa.compData)==null?void 0:Xe.find(Ue=>(Ue==null?void 0:Ue.key)==="pageGroup"))==null?void 0:aa.contents)??"",Ye=(Le=(xa=(Pe=Z==null?void 0:Z.split("["))==null?void 0:Pe[1])==null?void 0:xa.split("]"))==null?void 0:Le[0];Ga=((va=Z==null?void 0:Z.split("["))==null?void 0:va[0])+((Ce=(re=A.value)==null?void 0:re.find(Ue=>(Ue==null?void 0:Ue.key)===Ye))==null?void 0:Ce.value)}return oa}),!(Ga===""||Ga==="")){const oa=await ca.getItemData(Ga,sessionStorage.getItem("systemKey"),"",!1,"","",Re);Ge=Ge==null?void 0:Ge.map(Oe=>{var _e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa;if((Oe==null?void 0:Oe.comp)==="Table"&&(_e=Oe.compData)!=null&&_e.find(Ye=>(Ye==null?void 0:Ye.key)==="pageColumn")){let Ye=(ve=(wa=Oe.compData)==null?void 0:wa.find(ba=>(ba==null?void 0:ba.key)==="pageColumn"))==null?void 0:ve.contents,Ma=((aa=(Xe=Oe.compData)==null?void 0:Xe.find(ba=>(ba==null?void 0:ba.key)==="pageGroup"))==null?void 0:aa.contents)??"",Ue=(Le=(xa=(Pe=Ye==null?void 0:Ye.split("["))==null?void 0:Pe[1])==null?void 0:xa.split("]"))==null?void 0:Le[0],Ya=((va=Ye==null?void 0:Ye.split("["))==null?void 0:va[0])+((Ce=(re=A.value)==null?void 0:re.find(ba=>(ba==null?void 0:ba.key)===Ue))==null?void 0:Ce.value),ga=(Z=oa==null?void 0:oa.find(ba=>(ba==null?void 0:ba.name)===(Ma===""?s==null?void 0:s.compName:Ma)))==null?void 0:Z.compData;Oe.compData=(fa=Oe.compData)==null?void 0:fa.map(ba=>{var $a;return(ba==null?void 0:ba.key)==="tableContents"&&(ba.contents=($a=ga==null?void 0:ga.find(Sa=>(Sa==null?void 0:Sa.key)==="tableContents"))==null?void 0:$a.contents),ba})}return Oe})}let Fa={};if(((le=(S=oe==null?void 0:oe.extraValues)==null?void 0:S.input)==null?void 0:le.length)>0){const oa=(ue=(me=oe==null?void 0:oe.extraValues)==null?void 0:me.input)==null?void 0:ue.map(async Oe=>{var _e;de!=null&&de.find(wa=>wa===Oe)?Fa=await Ee(Oe,Ge):Fa[Object.keys(Oe)[0]]=await Ee((_e=Object.values(Oe))==null?void 0:_e[0],Ge,Re)});await Promise.all(oa)}else Fa=await Ee("/",Ge);let P=!1;(pa=(Ne=oe==null?void 0:oe.extraValues)==null?void 0:Ne.output)==null||pa.forEach(oa=>{var Oe,_e;(_e=(Oe=Object.values(oa))==null?void 0:Oe[0])!=null&&_e.includes(".doc")&&(P=!0)});let F;if(P){const oa=I.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});F=await rl.axios.post(oe.api,Fa,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{oa.close()})}else F=await rl.axios.post(oe.api,Fa,{headers:{"Content-Type":"application/json"}});let J=(la=(ee=(Wa=(_a=I.cloneDeep(oe))==null?void 0:_a.extraValues)==null?void 0:Wa.output)==null?void 0:ee.map(oa=>{var Oe,_e,wa,ve,Xe,aa,Pe,xa,Le,va,re,Ce,Z,fa,Ye,Ma;if(!((_e=(Oe=Object.values(oa))==null?void 0:Oe[0])!=null&&_e.includes(".doc"))){let Ue=(va=(Le=(xa=(ve=I.cloneDeep((wa=Object.values(oa))==null?void 0:wa[0]))==null?void 0:ve.split("["))==null?void 0:xa[((Pe=(aa=I.cloneDeep((Xe=Object.values(oa))==null?void 0:Xe[0]))==null?void 0:aa.split("["))==null?void 0:Pe.length)-1])==null?void 0:Le.split("]"))==null?void 0:va[0],Ya=Ue==null?void 0:Ue.split(":"),ga=(Z=I.cloneDeep((re=Object.values(oa))==null?void 0:re[0]))==null?void 0:Z.substring(0,I.cloneDeep((Ce=Object.values(oa))==null?void 0:Ce[0]).lastIndexOf("["));if(ga=(Ye=I.cloneDeep(ga))==null?void 0:Ye.slice(0,((fa=I.cloneDeep(ga))==null?void 0:fa.length)-1),ga!=null&&ga.includes("[")){let ba="";if((Ma=ca.contentTransArrayToAll(ga,"/"))==null||Ma.forEach($a=>{var Sa,Na,Oa,Be,tl,Ea,El;if(!($a!=null&&$a.includes("[")))ba=ba===""?ba+$a.replaceAll("/",""):ba+"/"+$a.replaceAll("/","");else{let ml=I.cloneDeep($a).slice(1,((Sa=I.cloneDeep($a))==null?void 0:Sa.length)-1),Fe=(Ea=(tl=(Be=(Oa=(Na=I.cloneDeep(ml))==null?void 0:Na.split("["))==null?void 0:Oa[1])==null?void 0:Be.split("]"))==null?void 0:tl[0])==null?void 0:Ea.split(":"),Va="",je=(El=Ge==null?void 0:Ge.find(xe=>(xe==null?void 0:xe.name)===(Fe==null?void 0:Fe[0])))==null?void 0:El.compData;je==null||je.forEach(xe=>{var Ze;(xe==null?void 0:xe.key)==="formContent"&&((Ze=xe==null?void 0:xe.contents)==null||Ze.forEach(Je=>{(Je==null?void 0:Je.key)===(Fe==null?void 0:Fe[1])&&(Va=Je==null?void 0:Je.value)}))}),ba=ba===""?ba+Va.replaceAll("/",""):ba+"/"+Va.replaceAll("/","")}}),ga=ba,ga[(ga==null?void 0:ga.length)-1]!=="/")return ga}}}))==null?void 0:la.filter(oa=>oa);J=[...new Set(I.cloneDeep(J))];let ie=J==null?void 0:J.map(async oa=>{let Oe=await ca.getItemData(oa,sessionStorage.getItem("systemKey"),"",!1,"","",Re);if((Oe==null?void 0:Oe.length)===0)return await ca.getParentContents(oa)});await Promise.all(ie);let se=[],ma=(He=(ka=(Ve=I.cloneDeep(oe))==null?void 0:Ve.extraValues)==null?void 0:ka.output)==null?void 0:He.map(async oa=>{var xa,Le,va,re,Ce,Z,fa,Ye,Ma,Ue,Ya,ga,ba,$a,Sa,Na,Oa,Be,tl,Ea,El,ml,Fe,Va,je,xe,Ze,Je,ea,q,ra,ya,we,Se,qa,fe,fl,Qa,_l,Ha,il,Ia,ul,Ja,Wl,Kl,$l,Fl,gr,rr,kr,wr,Er,un,Jr,dn,Xr,qr,pn,on,Dr,Zr,Nr,Il,Wr,Br,vn,io,Kn,In;if((Le=(xa=Object.values(oa))==null?void 0:xa[0])!=null&&Le.includes(".doc")){var Oe=new Blob([F.data],{type:"application/octet-stream;charset=UTF-8"}),_e=F.headers["content-disposition"],wa=new RegExp("filename=([^;]+\\.[^\\.;]+);*"),ve=wa.exec(_e),Xe=ve==null?void 0:ve[1],aa=document.createElement("a"),Pe=window.URL.createObjectURL(Oe);y.value=[{name:Xe,blobUrl:Pe}],c.value=!0}else{let mn=(Ue=(Ma=(Ye=(re=I.cloneDeep((va=Object.values(oa))==null?void 0:va[0]))==null?void 0:re.split("["))==null?void 0:Ye[((fa=(Z=I.cloneDeep((Ce=Object.values(oa))==null?void 0:Ce[0]))==null?void 0:Z.split("["))==null?void 0:fa.length)-1])==null?void 0:Ma.split("]"))==null?void 0:Ue[0],Xl=mn==null?void 0:mn.split(":"),xr=(ba=I.cloneDeep((Ya=Object.values(oa))==null?void 0:Ya[0]))==null?void 0:ba.substring(0,I.cloneDeep((ga=Object.values(oa))==null?void 0:ga[0]).lastIndexOf("["));if(xr!=null&&xr.includes("[")?xr=(Sa=I.cloneDeep(xr))==null?void 0:Sa.slice(0,(($a=I.cloneDeep(xr))==null?void 0:$a.length)-1):xr===""&&(xr=b.value),xr=xr.replaceAll("<","[").replaceAll(">","]"),xr!=null&&xr.includes("[")){let Hl="";(Na=ca.contentTransArrayToAll(xr,"/"))==null||Na.forEach((Ml,cr)=>{var ar,Pl,zr,Mr,yn,Qr,Yn,Sn,Gn,gn,Dn;if(!(Ml!=null&&Ml.includes("[")))Hl=Hl===""?Hl+Ml.replaceAll("/",""):Hl+"/"+Ml.replaceAll("/","");else{let Ln="",Kr="";(ar=I.cloneDeep(Ml))!=null&&ar.includes("]")?(Ln=I.cloneDeep(Ml).slice(1,((Pl=I.cloneDeep(Ml))==null?void 0:Pl.length)-1),Kr=(Yn=(Qr=(yn=(Mr=(zr=I.cloneDeep(Ln))==null?void 0:zr.split("["))==null?void 0:Mr[1])==null?void 0:yn.split("]"))==null?void 0:Qr[0])==null?void 0:Yn.split(":")):(Ln=I.cloneDeep(Ml).slice(1,(Sn=I.cloneDeep(Ml))==null?void 0:Sn.length),Kr=(Gn=I.cloneDeep(Ln))==null?void 0:Gn.split("/"));let Nn="",bn=(gn=Ge==null?void 0:Ge.find(Pr=>(Pr==null?void 0:Pr.name)===(Kr==null?void 0:Kr[0])))==null?void 0:gn.compData;bn==null||bn.forEach(Pr=>{var $n;(Pr==null?void 0:Pr.key)==="formContent"&&(($n=Pr==null?void 0:Pr.contents)==null||$n.forEach(fn=>{(fn==null?void 0:fn.key)===(Kr==null?void 0:Kr[1])&&(Nn=fn==null?void 0:fn.value)}))}),((Dn=ca.contentTransArrayToAll(xr,"/"))==null?void 0:Dn.length)-1!==cr?Hl=Hl===""?Hl+Nn.replaceAll("/",""):Hl+"/"+Nn.replaceAll("/",""):Hl=Hl+o.value+Nn.replaceAll("/","")}}),(Oa=b.value)!=null&&Oa.includes(Hl)?xr=b.value:xr=Hl}let Rl=I.cloneDeep((Be=Object.keys(oa))==null?void 0:Be[0]);if(((tl=F==null?void 0:F.data)==null?void 0:tl.statusCode)===200||((Ea=F==null?void 0:F.data)==null?void 0:Ea.code)===200){if(((ml=(El=F==null?void 0:F.data)==null?void 0:El.data)!=null&&ml[Rl]||(Va=(Fe=F==null?void 0:F.data)==null?void 0:Fe.result)!=null&&Va[Rl])&&(Xl==null?void 0:Xl.length)===1)return await ge(((xe=(je=F==null?void 0:F.data)==null?void 0:je.data)==null?void 0:xe[Rl])||((Je=(Ze=F==null?void 0:F.data)==null?void 0:Ze.result)==null?void 0:Je[Rl]),I.cloneDeep(xr),Xl,Ga);if((q=(ea=F==null?void 0:F.data)==null?void 0:ea.data)!=null&&q[Rl]||(ya=(ra=F==null?void 0:F.data)==null?void 0:ra.result)!=null&&ya[Rl]){let Hl=await Ie(((Se=(we=F==null?void 0:F.data)==null?void 0:we.data)==null?void 0:Se[Rl])||((fe=(qa=F==null?void 0:F.data)==null?void 0:qa.result)==null?void 0:fe[Rl]),I.cloneDeep(xr),Xl);return Hl&&(se=[...se,...Hl]),Hl}else{if(!((fl=F==null?void 0:F.data)!=null&&fl.data)){let Hl=await ca.getItemData(b.value,sessionStorage.getItem("systemKey"),"",!1,"","",Re);Hl=Hl==null?void 0:Hl.map(cr=>{var ar;return(cr==null?void 0:cr.name)===(Xl==null?void 0:Xl[0])&&(cr.compData=(ar=cr.compData)==null?void 0:ar.map(Pl=>{var zr;return(Pl==null?void 0:Pl.key)==="formContent"&&(Pl.contents=(zr=Pl.contents)==null?void 0:zr.map(Mr=>{var yn,Qr;return(Mr==null?void 0:Mr.key)===(Xl==null?void 0:Xl[1])&&(Mr.value=(Qr=(yn=F==null?void 0:F.data)==null?void 0:yn.result)==null?void 0:Qr[Rl==null?void 0:Rl.replaceAll(":","")]),Mr})),Pl})),cr});let Ml=[];(Qa=Hl==null?void 0:Hl.filter(cr=>(cr==null?void 0:cr.comp)==="Form"))==null||Qa.forEach(async cr=>{let ar={};for(let Pl in cr)Pl!=="id"&&(ar[Pl]=cr[Pl]);Ml.push({id:cr==null?void 0:cr.id,value:{pageData:ar}})}),(Ml==null?void 0:Ml.length)>0&&await yr.batchUpdateInsofDataApi({dataList:Ml});return}if((Xl==null?void 0:Xl.length)===1){const Hl=(il=(Ha=(_l=F==null?void 0:F.data)==null?void 0:_l.data)==null?void 0:Ha.path)==null?void 0:il.path;let Ml="";(Kl=(Wl=(Ja=(ul=(Ia=Hl==null?void 0:Hl.split("("))==null?void 0:Ia[1])==null?void 0:ul.split(")"))==null?void 0:Ja[0])==null?void 0:Wl.split(":"))==null||Kl.forEach(Pl=>{var zr,Mr;Ml=Ml===""?Ml+((zr=Pl==null?void 0:Pl.replaceAll("'",""))==null?void 0:zr.trim()):Ml+"/"+((Mr=Pl==null?void 0:Pl.replaceAll("'",""))==null?void 0:Mr.trim())});let cr=[(kr=(rr=(gr=(Fl=($l=Hl==null?void 0:Hl.split("<"))==null?void 0:$l[1])==null?void 0:Fl.split(">"))==null?void 0:gr[0])==null?void 0:rr.replaceAll("'",""))==null?void 0:kr.trim()],ar;return(un=(Er=(wr=F==null?void 0:F.data)==null?void 0:wr.data)==null?void 0:Er.data)!=null&&un[Xl==null?void 0:Xl[0]]?ar=await ge((Xr=(dn=(Jr=F==null?void 0:F.data)==null?void 0:Jr.data)==null?void 0:dn.data)==null?void 0:Xr[Xl==null?void 0:Xl[0]],Ml,Xl,Ga):ar=await De((pn=(qr=F==null?void 0:F.data)==null?void 0:qr.data)==null?void 0:pn.data,Ml,cr,Re),ar}else{const Hl=(Zr=(Dr=(on=F==null?void 0:F.data)==null?void 0:on.data)==null?void 0:Dr.path)==null?void 0:Zr.path;let Ml="";return(vn=(Br=(Wr=(Il=(Nr=Hl==null?void 0:Hl.split("("))==null?void 0:Nr[1])==null?void 0:Il.split(")"))==null?void 0:Wr[0])==null?void 0:Br.split(":"))==null||vn.forEach(ar=>{var Pl,zr;Ml=Ml===""?Ml+((Pl=ar==null?void 0:ar.replaceAll("'",""))==null?void 0:Pl.trim()):Ml+"/"+((zr=ar==null?void 0:ar.replaceAll("'",""))==null?void 0:zr.trim())}),await Ie((In=(Kn=(io=F==null?void 0:F.data)==null?void 0:io.data)==null?void 0:Kn.data)==null?void 0:In[Xl==null?void 0:Xl[0]],Ml,Xl)}}}}});if(await Promise.all(ma),(se==null?void 0:se.length)>0){let oa=[];se==null||se.forEach(wa=>{oa!=null&&oa.find(ve=>{var Xe,aa,Pe,xa;return((aa=(Xe=ve==null?void 0:ve.value)==null?void 0:Xe.pageData)==null?void 0:aa.name)===((xa=(Pe=wa==null?void 0:wa.value)==null?void 0:Pe.pageData)==null?void 0:xa.name)})||oa.push(wa)});let Oe=[];oa==null||oa.forEach(wa=>{var aa,Pe,xa,Le;let ve=I.cloneDeep(wa);ve.value.pageData.compData=(aa=ve.value.pageData.compData)==null?void 0:aa.map(va=>{var re;return(va==null?void 0:va.key)==="formContent"&&(va.contents=(re=va.contents)==null?void 0:re.map(Ce=>{var fa,Ye,Ma,Ue;let Z=(fa=I.cloneDeep(se))==null?void 0:fa.find(Ya=>(Ya==null?void 0:Ya.keyType)===(Ce==null?void 0:Ce.key));if(Z){let Ya=(Ue=(Ma=(Ye=Z.value.pageData.compData)==null?void 0:Ye.find(ga=>(ga==null?void 0:ga.key)==="formContent"))==null?void 0:Ma.contents)==null?void 0:Ue.find(ga=>(ga==null?void 0:ga.key)===(Ce==null?void 0:Ce.key));Ce.value=Ya==null?void 0:Ya.value}return Ce})),va}),Oe.push({id:ve==null?void 0:ve.id,value:ve==null?void 0:ve.value});let Xe=[];(Le=(xa=(Pe=ve==null?void 0:ve.value)==null?void 0:Pe.pageData)==null?void 0:xa.compData)==null||Le.forEach(va=>{var re;(va==null?void 0:va.key)==="formContent"&&((re=va==null?void 0:va.contents)==null||re.forEach(Ce=>{var Z,fa,Ye,Ma,Ue,Ya;if((fa=(Z=Ce==null?void 0:Ce.optionUrl)==null?void 0:Z.menuSelect)!=null&&fa.find(ga=>ga==null?void 0:ga.includes("[")))if(Xe!=null&&Xe.find(ga=>{var ba,$a,Sa;return((ba=ga==null?void 0:ga.key)==null?void 0:ba.join(","))===((Sa=($a=Ce==null?void 0:Ce.optionUrl)==null?void 0:$a.menuSelect)==null?void 0:Sa.join(","))})){let ga=(Ye=Xe==null?void 0:Xe.find(ba=>{var $a,Sa,Na;return(($a=ba==null?void 0:ba.key)==null?void 0:$a.join(","))===((Na=(Sa=Ce==null?void 0:Ce.optionUrl)==null?void 0:Sa.menuSelect)==null?void 0:Na.join(","))}))==null?void 0:Ye.value;ga.push({key:Ce==null?void 0:Ce.prop,groups:(Ma=Ce==null?void 0:Ce.optionUrl)==null?void 0:Ma.groupSelect,value:Ce==null?void 0:Ce.value}),Xe=Xe==null?void 0:Xe.map(ba=>{var $a,Sa,Na;return(($a=ba==null?void 0:ba.key)==null?void 0:$a.join(","))===((Na=(Sa=Ce==null?void 0:Ce.optionUrl)==null?void 0:Sa.menuSelect)==null?void 0:Na.join(","))&&(ba.value=ga),ba})}else Xe.push({key:(Ue=Ce==null?void 0:Ce.optionUrl)==null?void 0:Ue.menuSelect,value:[{key:Ce==null?void 0:Ce.prop,groups:(Ya=Ce==null?void 0:Ce.optionUrl)==null?void 0:Ya.groupSelect,value:Ce==null?void 0:Ce.value}]})}))}),(Xe==null?void 0:Xe.length)>0&&(Xe=Xe==null?void 0:Xe.map(va=>{var Ce;let re="";return(Ce=va==null?void 0:va.key)==null||Ce.forEach(Z=>{var fa;if(!(Z!=null&&Z.includes("[")))re=re===""?re+Z:re+"/"+Z;else{let Ye="",Ma=(fa=Z==null?void 0:Z.replaceAll("[","").replaceAll("]",""))==null?void 0:fa.split(":");Ge==null||Ge.forEach(Ue=>{var Ya;(Ue==null?void 0:Ue.name)===(Ma==null?void 0:Ma[0])&&((Ya=Ue==null?void 0:Ue.compData)==null||Ya.forEach(ga=>{var ba;(ga==null?void 0:ga.key)==="formContent"&&((ba=ga==null?void 0:ga.contents)==null||ba.forEach($a=>{($a==null?void 0:$a.prop)===(Ma==null?void 0:Ma[1])&&(Ye=$a==null?void 0:$a.value)}))}))}),re=re+o.value+Ye}}),va.key=re,va})),Xe==null||Xe.forEach(va=>{var fa,Ye,Ma;let re=(fa=Re[va.key])==null?void 0:fa.find(Ue=>{var Ya,ga,ba,$a,Sa,Na,Oa;return((ga=(Ya=Ue==null?void 0:Ue.value)==null?void 0:Ya.pageData)==null?void 0:ga.name)===((Sa=($a=(ba=va==null?void 0:va.value)==null?void 0:ba[0])==null?void 0:$a.groups)==null?void 0:Sa[0])&&((Oa=(Na=Ue==null?void 0:Ue.value)==null?void 0:Na.pageData)==null?void 0:Oa.name)!==void 0}),Ce=re==null?void 0:re.id,Z=(Ye=re==null?void 0:re.value)==null?void 0:Ye.pageData;Z.compData=(Ma=Z.compData)==null?void 0:Ma.map(Ue=>{var Ya;return(Ue==null?void 0:Ue.key)==="formContent"&&(Ue.contents=(Ya=Ue.contents)==null?void 0:Ya.map(ga=>{var $a;let ba=($a=va.value)==null?void 0:$a.find(Sa=>(Sa==null?void 0:Sa.key)===(ga==null?void 0:ga.prop));return ba&&(ga.value=ba.value),ga})),Ue}),Oe.push({id:Ce,value:{pageData:Z}})})});let _e=(Te=I.cloneDeep(se))==null?void 0:Te[0];(Oe==null?void 0:Oe.length)>0&&await yr.batchUpdateInsofDataApi({dataList:Oe})}m.setFreshContent(!0)}x.setImportLoading(!1)}catch{rl.ElMessage.error("方法执行错误,请查看方法!"),x.setImportLoading(!1)}_.value=!0},de=["createInsofDataApi"],Ke=Pa.debounce(async oe=>{X(oe)},100),Ta=async oe=>{var pa,_a,Wa;const S=I.cloneDeep(oe);let le,me=new WeakMap;oe!=null&&oe[0].path&&(le=await(S==null?void 0:S.map(async(ee,la)=>{var Fa,P,F,J,ie,se,ma,oa,Oe,_e,wa,ve,Xe,aa,Pe,xa;const ka=(Fa=me[ee==null?void 0:ee.path])==null?void 0:Fa.filter(Le=>{var va;return((va=Le==null?void 0:Le.key)==null?void 0:va.type)==="data"});let He="";const Te=await ca.getItemData(b.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,me);ka==null||ka.forEach(Le=>{var va,re,Ce,Z,fa;((re=(va=Le==null?void 0:Le.value)==null?void 0:va.tableData)==null?void 0:re.算法名称)===((Ce=S==null?void 0:S[la])==null?void 0:Ce.method)&&(He=(fa=(Z=Le==null?void 0:Le.value)==null?void 0:Z.tableData)==null?void 0:fa.算法体)});const Re=await ca.getItemData(ee==null?void 0:ee.path,sessionStorage.getItem("systemKey"),"",!1,[],!1,me);let Ge="",Ga=(ie=(J=(F=(P=Re==null?void 0:Re[0])==null?void 0:P.compData)==null?void 0:F.find(Le=>(Le==null?void 0:Le.key)==="header"))==null?void 0:J.contents)==null?void 0:ie.findIndex(Le=>(Le==null?void 0:Le.prop)==="算法体");return(ma=(se=Re==null?void 0:Re[0])==null?void 0:se.compData)==null||ma.forEach(Le=>{var va;(Le==null?void 0:Le.key)==="tableContents"&&((va=Le==null?void 0:Le.contents)==null||va.forEach(re=>{re!=null&&re.find(Ce=>Ce===(ee==null?void 0:ee.method))&&(Ge=re[Ga])}))}),{buttonName:((oa=S==null?void 0:S[la])==null?void 0:oa.method)||((wa=(_e=(Oe=ka==null?void 0:ka[0])==null?void 0:Oe.value)==null?void 0:_e.tableData)==null?void 0:wa.算法名称),api:(He===""?(aa=(Xe=(ve=ka==null?void 0:ka[0])==null?void 0:ve.value)==null?void 0:Xe.tableData)==null?void 0:aa.算法体:He)||Ge,content:Te==null?void 0:Te.filter(Le=>Le.comp!=="methodButton"),extraContent:(Pe=I.cloneDeep(ee.value))==null?void 0:Pe.slice(1),methodName:(ee==null?void 0:ee.path)??"",extraValues:(xa=S==null?void 0:S[la])==null?void 0:xa.data}})));const ue=S==null?void 0:S.map(async ee=>{var Re,Ge,Ga,Fa,P,F;const la=(Re=resAll.data.result)==null?void 0:Re.filter(J=>{var ie,se,ma;return((ie=J==null?void 0:J.key)==null?void 0:ie.parentTable)===""&&((se=J==null?void 0:J.key)==null?void 0:se.type)==="method"&&((ma=J==null?void 0:J.key)==null?void 0:ma.methodName)===J.method}),Ve=la==null?void 0:la[0],ka=(Ge=resAll.data.result)==null?void 0:Ge.filter(J=>{var ie,se;return((ie=J==null?void 0:J.key)==null?void 0:ie.type)==="methodData"&&((se=J==null?void 0:J.key)==null?void 0:se.tableId)===(Ve==null?void 0:Ve.id)}),He=await ca.getItemData(b.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,me),Te=ka==null?void 0:ka[0];return{buttonName:(Ga=Ve==null?void 0:Ve.key)==null?void 0:Ga.methodKey,api:(P=(Fa=Te==null?void 0:Te.value)==null?void 0:Fa.tableData)==null?void 0:P[0],content:He==null?void 0:He.filter(J=>J.comp!=="methodButton"),extraContent:(F=I.cloneDeep(ee.value))==null?void 0:F.slice(1),methodName:(ee==null?void 0:ee.method)??""}}),Ne=(pa=oe==null?void 0:oe[0])!=null&&pa.path&&((_a=oe==null?void 0:oe[0])==null?void 0:_a.path)!==""?await Promise.all(le):await Promise.all(ue);r.value=Ne==null?void 0:Ne.filter(ee=>ee==null?void 0:ee.extraContent),(Wa=r.value)==null||Wa.forEach(ee=>{var la;ee.api===""&&((la=ee.content)==null||la.forEach(Ve=>{var ka;Ve.comp=="Table"&&m.setExtraContents(ca.methodTableToContent(Ve.compData,(ka=ee.extraContent)==null?void 0:ka[0]))}))})};return a.watch(()=>s.itemData,async()=>{w.value=="view"&&!_.value&&await Ta(I.cloneDeep(s.itemData)),_.value=!1},{immediate:!0,deep:!0}),(oe,S)=>{var le,me,ue;return a.unref(w)!=="edit"?(a.openBlock(),a.createElementBlock("div",B2,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList((le=r.value)==null?void 0:le.filter(Ne=>(Ne==null?void 0:Ne.buttonName)!=="保存"),Ne=>{var pa;return a.openBlock(),a.createElementBlock("div",null,[Ne.api!==""?(a.openBlock(),a.createBlock(a.unref(Xt._sfc_main),{key:0,disabled:a.unref(N)===a.unref(b)&&!((pa=Ne==null?void 0:Ne.buttonName)!=null&&pa.includes("预览")),class:"calculator-content",modelValue:Ne.buttonName,onClickTrigger:_a=>a.unref(Ke)(Ne),loading:u.value},null,8,["disabled","modelValue","onClickTrigger","loading"])):a.createCommentVNode("",!0)])}),256)),a.createElementVNode("div",null,[a.unref(V)!==""&&((ue=a.unref(b))==null?void 0:ue[((me=a.unref(b))==null?void 0:me.length)-1])!==a.unref(o)?(a.openBlock(),a.createBlock(a.unref(Xt._sfc_main),{key:0,class:"calculator-content",onClickTrigger:U,modelValue:"保存"})):a.createCommentVNode("",!0)]),c.value?(a.openBlock(),a.createBlock(pl.ssFilePreview,{key:0,fileDataList:y.value,onDestroy:W},null,8,["fileDataList"])):a.createCommentVNode("",!0)])):a.createCommentVNode("",!0)}}},A2=ql._export_sfc(T2,[["__scopeId","data-v-063aa9af"]]),z2={};function M2(l,r){return" 567 "}const O2=ql._export_sfc(z2,[["render",M2]]),I2={class:"module content"},L2={class:"module data"},$2={class:"module layout"},R2={class:"form-content"},V2=a.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.reactive({visible:!1,width:"40%",title:"签名配置"}),c=a.ref("create"),y=a.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),f=a.ref([{label:"宽度(%):",prop:"signPadWidth",type:"number",value:"30"},{label:"弹窗名称:",prop:"dialogTitle",type:"input",value:""},{label:"弹窗宽度(%):",prop:"dialogWidth",type:"number",value:"30"},{label:"弹窗显示:",prop:"dialogShow",type:"radio",contents:[{label:"显示",value:!0},{label:"隐藏",value:!1}],value:!1,isFormColHidden:!0},{label:"路径:",prop:"url",type:"input",value:"",isFormColHidden:!0}]),v=a.computed(()=>[{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"类型:",prop:"label",type:"select",contents:[{label:"电子签名",value:"电子签名"},{label:"签字版",value:"签字版"},{label:"上传签名",value:"上传签名"}],value:""},{label:"图标",prop:"icon",type:"inputPopover",value:""}]),m=a.ref({}),u=a.ref([]),x=()=>({comp:"Signature",compData:[{key:"signTypeList",contents:u.value},{key:"signConfig",contents:m.value}]}),E=A=>{var N;m.value=I.cloneDeep(A),o("change",(N=x())==null?void 0:N.compData)},B=A=>{var N,Y;if((A==null?void 0:A.buttonName)==="确认"){const b=I.cloneDeep(A==null?void 0:A.content);switch(c.value){case"create":u.value.push({...b,index:((N=u.value)==null?void 0:N.length)+1});break}o("change",(Y=x())==null?void 0:Y.compData),s.visible=!1}else s.visible=!1},w=(A,N)=>{var Y,b;switch(A){case"create":(Y=v.value)==null||Y.forEach($=>{$.value=""}),c.value="create",s.visible=!0;break;case"update":(b=v.value)==null||b.forEach($=>{$.value=N[$==null?void 0:$.prop]}),c.value="update",s.visible=!0;break;case"delete":u.value.splice(N,1),c.value="delete";break}},V=()=>{s.visible=!1};return a.watch(()=>n==null?void 0:n.itemContents,A=>{var N,Y;A&&(m.value=((N=A==null?void 0:A.find(b=>b.key==="signConfig"))==null?void 0:N.contents)??{},u.value=((Y=A==null?void 0:A.find(b=>b.key==="signTypeList"))==null?void 0:Y.contents)??[])},{immediate:!0}),(A,N)=>{const Y=a.resolveComponent("svg-icon"),b=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock(a.Fragment,null,[a.createElementVNode("div",null,[a.createElementVNode("div",I2,[N[2]||(N[2]=a.createElementVNode("h4",{class:"module-title"},"签名类型",-1)),a.createVNode(b,{class:"module-icon",id:"themeButton",onClick:N[0]||(N[0]=$=>w("create"))},{icon:a.withCtx(()=>[a.createVNode(Y,{name:"Plus",class:"icon-size"})]),default:a.withCtx(()=>[N[1]||(N[1]=a.createTextVNode(" 新增 "))]),_:1,__:[1]})]),a.createElementVNode("div",L2,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(u.value,($,T)=>(a.openBlock(),a.createElementBlock("div",{class:"module-data-item",key:T},[a.createElementVNode("span",null,a.toDisplayString($==null?void 0:$.label),1),a.createElementVNode("div",null,[a.createVNode(b,{type:"primary",size:"small",onClick:k=>w("update",{...$,index:T+1})},{default:a.withCtx(()=>N[3]||(N[3]=[a.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),a.createVNode(b,{type:"danger",size:"small",onClick:k=>w("delete",T)},{default:a.withCtx(()=>N[4]||(N[4]=[a.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),a.createElementVNode("div",$2,[a.createVNode(pl.ssForm,{rowContents:f.value,onChange:E},null,8,["rowContents"])])]),a.createVNode(vr.ssDialog,{visible:s.visible,title:s.title,onBeforeDestroy:V,width:s.width},{default:a.withCtx(()=>[a.createElementVNode("div",R2,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:v.value,key:v.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:y.value,onOnButtonClick:B},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),P2=ql._export_sfc(V2,[["__scopeId","data-v-487e0536"]]),F2=a.defineComponent({__name:"index",props:{stepConfig:{type:Object,default:{}},stepList:{type:Array,default:()=>[]}},emits:["clickStep","clickTrigger","changeTrigger"],setup(l,{emit:r}){const n=l,o=r,s=a.ref(0),c=a.computed(()=>{var x,E;return(x=n==null?void 0:n.stepConfig)!=null&&x.allowTrigger?s.value:(E=n==null?void 0:n.stepConfig)==null?void 0:E.active}),y=(x,E)=>{s.value=E-1,o("clickStep",x,E)};a.onMounted(()=>{var x;o("clickStep",(x=n==null?void 0:n.stepList)==null?void 0:x[0],0)});const f=x=>pl.getComponent(x),v=()=>{var E;const x=(E=n==null?void 0:n.stepList)==null?void 0:E.find((B,w)=>w+1===c.value);return console.log("findStep",x),x?x==null?void 0:x.children:[]},m=x=>{o("clickTrigger",x)},u=x=>{o("changeTrigger",x)};return(x,E)=>{var V,A,N,Y,b;const B=a.resolveComponent("el-step"),w=a.resolveComponent("el-steps");return a.openBlock(),a.createElementBlock(a.Fragment,null,[a.createVNode(w,{direction:(V=l.stepConfig)==null?void 0:V.direction,active:c.value,"finish-status":"success",simple:(A=l.stepConfig)==null?void 0:A.simple,"align-center":((N=l.stepConfig)==null?void 0:N.alignCenter)??!0},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(l.stepList,($,T)=>(a.openBlock(),a.createBlock(B,{key:T,class:"step-item",onClick:k=>y($,T+1)},{title:a.withCtx(()=>[a.renderSlot(x.$slots,"title",{title:$==null?void 0:$.title},void 0,!0)]),description:a.withCtx(()=>[a.renderSlot(x.$slots,"description",{descriptions:$==null?void 0:$.description},void 0,!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["direction","active","simple","align-center"]),(Y=l.stepConfig)!=null&&Y.allowTrigger&&((b=l.stepConfig)!=null&&b.active)?(a.openBlock(!0),a.createElementBlock(a.Fragment,{key:0},a.renderList(v(),($,T)=>(a.openBlock(),a.createElementBlock("div",{key:T,class:"step-cont-wrap"},[(a.openBlock(),a.createBlock(a.resolveDynamicComponent(f($==null?void 0:$.type)),{modelValue:$.value,"onUpdate:modelValue":k=>$.value=k,onClickTrigger:m,onChangeTrigger:u,content:$==null?void 0:$.content},a.createSlots({_:2},[a.renderList(x.$slots,(k,_)=>({name:_,fn:a.withCtx(U=>[a.renderSlot(x.$slots,_,a.mergeProps({ref_for:!0},U||{}),void 0,!0)])}))]),1064,["modelValue","onUpdate:modelValue","content"]))]))),128)):a.createCommentVNode("",!0)],64)}}}),j2=ql._export_sfc(F2,[["__scopeId","data-v-fdbd6832"]]),H2=a.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]}},emits:["clickStep"],setup(l,{emit:r}){const n=l,o=r,s=a.ref({}),c=a.ref([]),y=(f,v)=>{o("clickStep",f,v)};return a.watch(()=>n==null?void 0:n.itemData,f=>{var x,E,B,w;s.value={direction:"horizontal",simple:!1,alignCenter:!0,allowTrigger:!0};let v=((x=f==null?void 0:f.find(V=>(V==null?void 0:V.key)==="stepName"))==null?void 0:x.contents)??[],m=[];(B=(E=f==null?void 0:f.find(V=>(V==null?void 0:V.key)==="header"))==null?void 0:E.contents)==null||B.forEach(V=>{m.push({label:V==null?void 0:V.label,prop:V==null?void 0:V.prop,name:V==null?void 0:V.prop,type:"text",disabled:!0})});let u=((w=f==null?void 0:f.find(V=>(V==null?void 0:V.key)==="tableContents"))==null?void 0:w.contents)??[];v=v==null?void 0:v.map((V,A)=>{let N=m==null?void 0:m.map(Y=>{var b;return{...Y,value:(b=u==null?void 0:u[A])==null?void 0:b[Y==null?void 0:Y.prop]}});return{title:V,description:N}}),c.value=v},{immediate:!0,deep:!0}),(f,v)=>{const m=a.resolveComponent("svg-icon");return a.openBlock(),a.createBlock(j2,{stepConfig:s.value,stepList:c.value,onClickStep:y},{icon:a.withCtx(()=>[a.createVNode(m,{name:"import"})]),title:a.withCtx(({title:u})=>[a.createTextVNode(a.toDisplayString(u),1)]),description:a.withCtx(({descriptions:u})=>[a.createVNode(pl.ssForm,{ref:"formRef",rowContents:u,showOperator:!0,isEnableWrap:!1,isEdit:!1},null,8,["rowContents"])]),_:1},8,["stepConfig","stepList"])}}}),U2=a.defineComponent({__name:"index",props:{activities:{type:Array,default:()=>[]},timeLineConfig:{type:Object,default:()=>{}}},setup(l){return(r,n)=>{const o=a.resolveComponent("el-timeline-item"),s=a.resolveComponent("el-timeline");return a.openBlock(),a.createBlock(s,null,{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(l.activities,(c,y)=>(a.openBlock(),a.createBlock(o,{key:y,timestamp:c.timestamp,placement:l.timeLineConfig.placement,center:l.timeLineConfig.isCenter,"hide-timestamp":!0,type:l.timeLineConfig.type,color:l.timeLineConfig.color,size:l.timeLineConfig.size,icon:l.timeLineConfig.icon,hollow:l.timeLineConfig.isHollow},{default:a.withCtx(()=>[a.renderSlot(r.$slots,"content",{content:c==null?void 0:c.content,timestamp:c==null?void 0:c.timestamp},void 0,!0)]),_:2},1032,["timestamp","placement","center","type","color","size","icon","hollow"]))),128))]),_:3})}}}),q2=ql._export_sfc(U2,[["__scopeId","data-v-4172a886"]]),W2={class:"line-content"},K2={class:"line-time"},Y2=a.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(l){const r=l,n=a.ref({}),o=a.ref([]);return a.watch(()=>r==null?void 0:r.itemData,s=>{var c,y;o.value=(c=s==null?void 0:s.find(f=>(f==null?void 0:f.key)==="timeLineList"))==null?void 0:c.contents,n.value=(y=s==null?void 0:s.find(f=>(f==null?void 0:f.key)==="timeLineConfig"))==null?void 0:y.contents},{immediate:!0}),(s,c)=>(a.openBlock(),a.createBlock(q2,{activities:o.value,timeLineConfig:n.value},{content:a.withCtx(({content:y,timestamp:f})=>[a.createElementVNode("span",W2,a.toDisplayString(y),1),a.createElementVNode("span",K2,a.toDisplayString(f),1)]),_:1},8,["activities","timeLineConfig"]))}}),G2=ql._export_sfc(Y2,[["__scopeId","data-v-b4d9deed"]]),J2={class:"tabs-content"},X2=a.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},tabsData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,compNames:{type:String,default:""},cacheNewData:{type:Object},isDevMode:{type:Boolean},allMapContents:{type:Array,default:()=>[]}},emits:["change","contentChange","pageChange","rowClick","routeUrl","clickTrigger","clickMainKey"],setup(l,{emit:r}){const n=l,o=r,s=a.ref();a.watch(()=>n==null?void 0:n.itemData,()=>{s.value=n==null?void 0:n.itemData},{immediate:!0,deep:!0});const c=E=>{o("change",E)},y=(E,B)=>{o("contentChange",E,B)},f=E=>{o("pageChange",E)},v=E=>{o("rowClick",E)},m=(E,B)=>{o("routeUrl",E,B)},u=E=>{o("clickTrigger",E)},x=(E,B)=>{o("clickMainKey",E,B)};return(E,B)=>{var w,V;return a.openBlock(),a.createElementBlock("div",J2,[(w=s.value)!=null&&w.length?(a.openBlock(),a.createBlock(pl.ssTab,{tabsContents:s.value,key:(V=s.value)==null?void 0:V.length},{pane:a.withCtx(({tab:A,index:N})=>[(a.openBlock(),a.createBlock(a.resolveDynamicComponent(a.unref(Fo)(A==null?void 0:A.comp)),{related:A==null?void 0:A.relatedTables,compNames:n==null?void 0:n.compNames,compName:A==null?void 0:A.name,cacheNewData:n==null?void 0:n.cacheNewData,isDevMode:l.isDevMode,itemData:A==null?void 0:A.compData,childItemData:A==null?void 0:A.itemChildData,onChange:c,index:(A==null?void 0:A.id)??N,config:{showIndex:A==null?void 0:A.showIndex,allowMove:A==null?void 0:A.allowMove,viewport:A==null?void 0:A.viewport},onContentChange:y,onPageChange:f,onRowClick:v,onRouteUrl:m,parentTableId:A==null?void 0:A.tableId,allMapContents:l.allMapContents,children:A==null?void 0:A.children,level:1,onClickTrigger:u,onClickMainKey:x},null,40,["related","compNames","compName","cacheNewData","isDevMode","itemData","childItemData","index","config","parentTableId","allMapContents","children"]))]),_:1},8,["tabsContents"])):a.createCommentVNode("",!0)])}}}),Z2=ql._export_sfc(X2,[["__scopeId","data-v-ded4e0d9"]]),Q2={class:"type-select"},eh=["onClick"],ah={class:"list-icon"},lh={__name:"modelSelect",setup(l){const r=Wn(I.pinia),{itemData:n}=I.storeToRefs(r),o=s=>{const c=I.cloneDeep(n.value);c.push({comp:s.comp,name:s.name,compData:[]}),r.setItemData(c)};return(s,c)=>{const y=a.resolveComponent("svg-icon");return a.openBlock(),a.createElementBlock("div",Q2,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(a.unref(Wc),(f,v)=>(a.openBlock(),a.createElementBlock("div",{class:"type-list",key:v},[a.createElementVNode("div",{class:"list-content",onClick:m=>o(f)},[a.createElementVNode("div",ah,[a.createVNode(y,{name:f.icon},null,8,["name"])]),a.createElementVNode("div",null,a.toDisplayString(f.name),1)],8,eh)]))),128))])}}},rh=ql._export_sfc(lh,[["__scopeId","data-v-91799bf8"]]),nh={class:"fill-content"},oh={class:"operate-content"},ih={class:"collapse-title-content"},th={class:"collapse-title-item"},sh={key:1},ch=["onClick"],uh={class:"icon-content"},dh={key:0,class:"edit-content"},ph=["onClick"],fh={class:"comp-child"},hh={__name:"modelFill",setup(l){const r=Wn(I.pinia),{itemData:n,originalData:o}=I.storeToRefs(r),s=a.ref([]);a.ref([]);const c=a.ref([]),y=a.ref([]),f=B=>{var V;let w=(V=I.cloneDeep(y.value))==null?void 0:V.map((A,N)=>(B===N&&(A.content=!0),A));y.value=w},v=B=>{var V;let w=(V=I.cloneDeep(y.value))==null?void 0:V.map((A,N)=>(B===N&&(A.content=!1),A));y.value=w,s.value=I.cloneDeep(n.value)},m=(B,w)=>{var Y;let V=(Y=I.cloneDeep(y.value))==null?void 0:Y.map((b,$)=>(B===$&&(b.content=!1),b));y.value=V;const A=I.cloneDeep(n.value),N=A==null?void 0:A.filter((b,$)=>($===B&&(b.name=w),b));r.setOriginalData(N),r.setItemData(N)};a.watch(()=>n.value,()=>{var B,w,V;!n.value||((B=n.value)==null?void 0:B.length)===0?s.value=[]:s.value=(w=I.cloneDeep(n.value))==null?void 0:w.filter(A=>(A==null?void 0:A.comp)!=="methodButton"),c.value=s.value,y.value=(V=I.cloneDeep(c.value))==null?void 0:V.map((A,N)=>({id:N,content:!1}))},{deep:!0,immediate:!0});const u=B=>Do(B),x=(B,w,V)=>{var N,Y;if(!B)return;let A=I.cloneDeep(n.value);A=(N=A==null?void 0:A.map((b,$)=>($===V&&(b.compData=B),b)))==null?void 0:N.filter(b=>(b==null?void 0:b.comp)!=="methodButton"),y.value=(Y=I.cloneDeep(A))==null?void 0:Y.map((b,$)=>({id:$,content:!1})),r.setOriginalData(A),r.setItemData(A)},E=B=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const w=I.cloneDeep(n.value),V=w==null?void 0:w.filter((A,N)=>N!==B);r.setOriginalData(V),r.setItemData(V),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(B,w)=>{const V=a.resolveComponent("svg-icon");return a.openBlock(),a.createElementBlock("div",nh,[w[1]||(w[1]=a.createElementVNode("div",{class:"fill-operate"},a.toDisplayString("操作栏"),-1)),a.createElementVNode("div",oh,[a.createVNode(Us.default,{class:"collapse-content",collapseContents:s.value},{title:a.withCtx(({item:A,index:N})=>{var Y,b,$,T,k,_,U,W,ce,Ee;return[a.createElementVNode("div",ih,[a.createElementVNode("div",th,[(b=(Y=y.value)==null?void 0:Y.find(Ie=>Ie.id===N))!=null&&b.content?a.createCommentVNode("",!0):(a.openBlock(),a.createElementBlock("div",{key:0,class:"collapse-title",style:a.normalizeStyle({marginRight:A.name&&A.name!==""?"8px":"0px"})},a.toDisplayString(A.name),5)),(T=($=y.value)==null?void 0:$.find(Ie=>Ie.id===N))!=null&&T.content?(a.openBlock(),a.createElementBlock("div",sh,[a.createVNode(pl.ssInput,{modelValue:A.name,"onUpdate:modelValue":Ie=>A.name=Ie,onClick:w[0]||(w[0]=a.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):a.createCommentVNode("",!0),(_=(k=y.value)==null?void 0:k.find(Ie=>Ie.id===N))!=null&&_.content?a.createCommentVNode("",!0):(a.openBlock(),a.createElementBlock("div",{key:2,onClick:a.withModifiers(Ie=>f(N),["stop"]),class:"icon-content"},[a.createVNode(V,{name:"Edit",style:{width:"16px",height:"16px"}})],8,ch))]),a.createElementVNode("div",uh,[(W=(U=y.value)==null?void 0:U.find(Ie=>Ie.id===N))!=null&&W.content?(a.openBlock(),a.createElementBlock("div",dh,[a.createVNode(V,{name:"Cancel",style:{width:"16px",height:"16px"},class:"icon-content",onClick:a.withModifiers(Ie=>v(N),["stop"])},null,8,["onClick"]),a.createVNode(V,{name:"Save",onClick:a.withModifiers(Ie=>m(N,A.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):a.createCommentVNode("",!0),(Ee=(ce=y.value)==null?void 0:ce.find(Ie=>Ie.id===N))!=null&&Ee.content?a.createCommentVNode("",!0):(a.openBlock(),a.createElementBlock("div",{key:1,onClick:a.withModifiers(Ie=>E(N),["stop"]),class:"icon-content"},[a.createVNode(V,{name:"Delete",style:{width:"16px",height:"16px"}})],8,ph))])])]}),content:a.withCtx(({item:A,index:N})=>{var Y,b;return[a.createElementVNode("div",fh,[a.createTextVNode(a.toDisplayString(u(A.comp+"Operate"))+" ",1),(a.openBlock(),a.createBlock(a.resolveDynamicComponent(u(A.comp+"Operate")),{itemContents:A==null?void 0:A.compData,originalItemContents:(b=(Y=c.value)==null?void 0:Y.find(($,T)=>T===N))==null?void 0:b.compData,onChange:$=>x($,A,N)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},vh=ql._export_sfc(hh,[["__scopeId","data-v-a46a44b9"]]),mh={key:0,class:"show-content"},yh={style:{display:"flex"}},gh={__name:"modelShow",setup(l){const r=Wn(I.pinia),{itemData:n}=I.storeToRefs(r),o=a.ref([]);a.watch(()=>n.value,()=>{var c;!n.value||((c=n.value)==null?void 0:c.length)===0?o.value=[]:o.value=I.cloneDeep(n.value)},{deep:!0,immediate:!0});const s=c=>Do(c);return(c,y)=>{var f;return((f=o.value)==null?void 0:f.length)>0?(a.openBlock(),a.createElementBlock("div",mh,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(o.value,(v,m)=>(a.openBlock(),a.createElementBlock("div",{class:"item-content",key:m},[a.createElementVNode("div",yh,a.toDisplayString(v.name),1),(a.openBlock(),a.createBlock(a.resolveDynamicComponent(s(v.comp)),{itemData:v==null?void 0:v.compData,childItemData:v==null?void 0:v.itemChildData,key:m},null,8,["itemData","childItemData"]))]))),128))])):a.createCommentVNode("",!0)}}},bh=ql._export_sfc(gh,[["__scopeId","data-v-3f3e863e"]]),kh={class:"tabs-header"},xh={class:"tabs-list"},_h={class:"tab-name"},wh={class:"tab-actions"},Ch=["onClick"],Eh=["onClick"],Sh=["onClick"],Dh={class:"model-operate"},Nh={class:"model-select",style:{display:"unset"}},Bh={class:"existing-components"},Th={class:"component-list"},Ah=["onClick"],zh={class:"component-info"},Mh={class:"component-type"},Oh={class:"component-name"},Ih={class:"model-fill"},Lh={__name:"operate",props:{itemContents:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.ref([]),c=a.ref(!1),y=a.ref(""),f=a.ref({title:""}),v=a.ref(-1),m=a.ref(!1),u=a.ref(-1),x=a.ref(new WeakMap),E=a.ref(null),B=Wn(I.pinia),{itemData:w}=I.storeToRefs(B),V=()=>{y.value="新增标签页",f.value.title="",v.value=-1,c.value=!0},A=oe=>{y.value="修改标签页",f.value.title=s.value[oe].title,v.value=oe,c.value=!0},N=oe=>{const S=$(oe);x.value.delete(S),s.value.splice(oe,1),Ta()},Y=()=>{if(f.value.title.trim()){if(v.value===-1){const oe={title:f.value.title,value:f.value.title,label:f.value.title,children:[],id:b()};s.value.push(oe)}else s.value[v.value].title=f.value.title,s.value[v.value].value=f.value.title,s.value[v.value].label=f.value.title;c.value=!1,Ta()}},b=()=>`tab_${Date.now()}_${Math.random().toString(36).substr(2,9)}`,$=oe=>{const S=s.value[oe];return S.id||(S.id=b()),S.id},T=oe=>{var me;u.value=oe;const S=$(oe);E.value=I.cloneDeep(w.value);let le=x.value.get(S);!le&&((me=s.value[oe].children)==null?void 0:me.length)>0&&(le=W(s.value[oe].children)),le?B.setItemData(I.cloneDeep(le)):B.setItemData([]),m.value=!0},k=a.computed(()=>{const oe=I.useModelComp(I.pinia),S=I.storeToRefs(oe).itemData.value;return console.log("可用组件数据",S),!S||!Array.isArray(S)?[]:S.filter(le=>{var me;if(le.comp==="Tabs"&&u.value>=0){const ue=$(u.value);if((me=le.compData)==null?void 0:me.some(pa=>{var _a;return pa.key==="stepList"&&((_a=pa.contents)==null?void 0:_a.some(Wa=>Wa.id===ue))}))return!1}return!0})}),_=oe=>({Table:"表格",Form:"表单",Tabs:"标签页",Chart:"图表",Card:"卡片"})[oe]||oe,U=oe=>{var S;try{const le=I.cloneDeep(oe);le.id=Date.now()+Math.random(),le.comp==="Tabs"&&((S=le.compData)==null||S.forEach(ue=>{ue.key==="stepList"&&ue.contents&&ue.contents.forEach(Ne=>{Ne.id=b()})}));const me=I.cloneDeep(w.value);me.push(le),B.setItemData(me)}catch(le){console.error("添加组件失败:",le)}},W=oe=>oe.map(S=>{var le;switch(S.type){case"form":return{comp:"Form",name:S.value||"表单",compData:ce(S.content)};case"table":return{comp:"Table",name:S.value||"表格",compData:Ee(S.content)};default:return{comp:"Unknown",name:S.value||"",compData:((le=S.content)==null?void 0:le.originalData)||[]}}}),ce=oe=>{if(!oe)return[];const S=[];return oe.rowContents&&S.push({key:"formContent",contents:oe.rowContents}),oe.buttonValue&&S.push({key:"formButton",contents:oe.buttonValue}),typeof oe.isEnableWrap<"u"&&S.push({key:"enableWrap",contents:oe.isEnableWrap}),S},Ee=oe=>[],Ie=()=>{if(u.value>=0&&u.value<s.value.length){const oe=$(u.value);x.value.set(oe,I.cloneDeep(w.value)),s.value[u.value].children=ge(w.value),console.log("保存后的数据",ge(w.value))}m.value=!1,u.value=-1,E.value=null,Ta()},De=()=>{E.value&&B.setItemData(I.cloneDeep(E.value)),m.value=!1,u.value=-1,E.value=null},ne=()=>{m.value&&De()},ge=oe=>{if(!Array.isArray(oe))throw new Error("sourceData must be an array");return oe.map((S,le)=>{if(!S||typeof S!="object")return S;const{comp:me,name:ue,compData:Ne}=S;switch(me){case"Form":return{type:"form",content:X(Ne||[]),value:"表单"};case"Table":return{type:"table",content:de(Ne||[]),value:"表格"};default:return{type:"xxx",content:Ke(Ne||[]),value:""}}})},X=oe=>{const S={formRules:{},rowContents:[],buttonValue:[],rowValues:[],isEnableWrap:!0,isRowFlex:!0,isButtonRow:!0,isEdit:!0,isStartJustify:!0},le={formContent:"rowContents",enableWrap:"isEnableWrap",formButton:"buttonValue"};return oe.forEach((me,ue)=>{if(!me||typeof me!="object"){console.warn(`Invalid config at index ${ue}:`,me);return}const{key:Ne,contents:pa}=me,_a=le[Ne];if(!_a){console.warn(`Unknown Form config key: ${Ne}`);return}Ne==="enableWrap"?S[_a]=!!pa:S[_a]=Array.isArray(pa)?pa:[]}),S},de=oe=>{const S={columns:[],tableData:[],extraButton:[],rowButton:[],currentPage:0,total:0,pageSize:0,isShowPagination:!0,isShowEdit:!0,isMoveColumn:!0,isShowDelete:!0},le={header:"columns",tableContents:"tableData"};return oe.forEach((me,ue)=>{if(!me||typeof me!="object"){console.warn(`Invalid config at index ${ue}:`,me);return}const{key:Ne,contents:pa}=me,_a=le[Ne];if(!_a){console.warn(`Unknown Table config key: ${Ne}`);return}S[_a]=Array.isArray(pa)?pa:[]}),S},Ke=oe=>(console.log("Default conversion logic - to be implemented"),{originalData:oe,processed:!1,componentType:"unknown"}),Ta=()=>{const oe=[{key:"stepList",contents:s.value}];o("change",oe)};return a.watch(()=>n.itemContents,oe=>{if(oe&&oe.length>0){const S=oe.find(le=>le.key==="stepList");S&&S.contents&&(s.value=S.contents.map(le=>({title:le.title||"",value:le.value||le.title||"",label:le.label||le.title||"",children:le.children||[],id:le.id||b()})))}},{immediate:!0,deep:!0}),(oe,S)=>{const le=a.resolveComponent("svg-icon"),me=a.resolveComponent("el-input"),ue=a.resolveComponent("el-form-item"),Ne=a.resolveComponent("el-form");return a.openBlock(),a.createElementBlock("div",null,[a.createElementVNode("div",kh,[S[6]||(S[6]=a.createElementVNode("h4",null,"标签页管理",-1)),a.createElementVNode("button",{onClick:V},[a.createVNode(le,{name:"Plus",style:{width:"14px",height:"14px","margin-right":"4px"}}),S[5]||(S[5]=a.createTextVNode(" 新增标签页 "))])]),a.createElementVNode("div",xh,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(s.value,(pa,_a)=>(a.openBlock(),a.createElementBlock("div",{class:"tab-item",key:_a},[a.createElementVNode("span",_h,a.toDisplayString(pa.title),1),a.createElementVNode("div",wh,[a.createElementVNode("button",{onClick:Wa=>A(_a)},"修改标题",8,Ch),a.createElementVNode("button",{onClick:Wa=>T(_a)},"布局调整",8,Eh),a.createElementVNode("button",{onClick:Wa=>N(_a)},"删除",8,Sh)])]))),128))]),a.createVNode(vr.ssDialog,{modelValue:c.value,"onUpdate:modelValue":S[2]||(S[2]=pa=>c.value=pa),title:y.value,onBeforeDestroy:S[3]||(S[3]=pa=>c.value=!1)},{footer:a.withCtx(()=>[a.createElementVNode("button",{onClick:S[1]||(S[1]=pa=>c.value=!1)},"取消"),a.createElementVNode("button",{type:"primary",onClick:Y},"确定")]),default:a.withCtx(()=>[a.createVNode(Ne,{model:f.value,"label-width":"80px"},{default:a.withCtx(()=>[a.createVNode(ue,{label:"标签名称",required:""},{default:a.withCtx(()=>[a.createVNode(me,{modelValue:f.value.title,"onUpdate:modelValue":S[0]||(S[0]=pa=>f.value.title=pa),placeholder:"请输入标签页名称"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue","title"]),a.createVNode(vr.ssDialog,{modelValue:m.value,"onUpdate:modelValue":S[4]||(S[4]=pa=>m.value=pa),title:"布局调整",fullScreen:"",onBeforeDestroy:ne},{footer:a.withCtx(()=>[a.createElementVNode("button",{onClick:De},"取消"),a.createElementVNode("button",{onClick:Ie},"确定")]),default:a.withCtx(()=>[a.createElementVNode("div",Dh,[a.createElementVNode("div",Nh,[a.createVNode(rh),a.createElementVNode("div",Bh,[S[8]||(S[8]=a.createElementVNode("h5",null,"添加已有组件",-1)),a.createElementVNode("div",Th,[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(k.value,pa=>(a.openBlock(),a.createElementBlock("div",{key:pa.id,class:"component-item",onClick:_a=>U(pa)},[a.createElementVNode("div",zh,[a.createElementVNode("span",Mh,a.toDisplayString(_(pa.comp)),1),a.createElementVNode("span",Oh,a.toDisplayString(pa.name),1)]),S[7]||(S[7]=a.createElementVNode("button",{class:"add-btn"},"添加",-1))],8,Ah))),128))])])]),(a.openBlock(),a.createElementBlock("div",{class:"model-show",key:oe.innerWidth},[a.createVNode(bh)])),a.createElementVNode("div",Ih,[a.createVNode(vh)])])]),_:1},8,["modelValue"])])}}},$h=ql._export_sfc(Lh,[["__scopeId","data-v-9096ed0d"]]);function Rh(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis"},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",axisLabel:{interval:0},data:[]},yAxis:{type:"value"},series:[]}}function Vh(l){return{type:"line",...l}}function Ph(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",data:["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]},yAxis:[{type:"value"}],series:[]}}function Fh(l){return{type:"bar",barWidth:"60%",...l}}function jh(){return{title:{text:"",left:"center"},tooltip:{trigger:"item"},series:[]}}function Hh(l){return{type:"pie",radius:"50%",emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},...l}}const On={line:{initBaseoptions:Rh,initSeries:Vh},bar:{initBaseoptions:Ph,initSeries:Fh},pie:{initBaseoptions:jh,initSeries:Hh}},ms=I.useMenuState(I.pinia),Ec=(l,r)=>{var u;const n=[],o=[],{group:s,nameCol:c,valueCol:y}=r||{},f=l==null?void 0:l.find(x=>{const{name:E}=x;return E===s});if(!f)return{names:n,values:o};const v=(u=f==null?void 0:f.compData)==null?void 0:u.find(x=>{const{key:E}=x;return E==="tableContents"});return((v==null?void 0:v.contents)||[]).forEach(x=>{const E=x==null?void 0:x[0];let B=!1;rl.isObject(E)&&(E!=null&&E.id)&&(B=!0);let w=c,V=y;B&&(w=w+1,V=V+1);const A=x==null?void 0:x[w],N=x==null?void 0:x[V];n.push(A),o.push(N)}),{names:n,values:o}},Uh=async l=>{const{menu:r,mainKey:n,detailGroup:o,detailNameCol:s,detailValueCol:c,isSelfDetail:y}=l||{};let f=null;const v=sessionStorage.getItem("systemKey");if(y&&ms.activeMenuPath&&(f=await ca.getItemData(`${ms.activeMenuPath}`,v,"")),!y){const m=r==null?void 0:r.join("/");f=await ca.getItemData(`${m}^${n}`,v,"")}return Ec(f,{group:o,nameCol:s,valueCol:c})},qh=async l=>{const{menu:r,group:n,nameCol:o,valueCol:s}=l||{},c=r==null?void 0:r.join("/"),y=sessionStorage.getItem("systemKey"),f=await ca.getItemData(c,y,"");return Ec(f,{group:n,nameCol:o,valueCol:s})},Ct=async(l,r)=>{const n={names:[],values:[]},{menu:o,group:s,nameCol:c,valueCol:y}=l||{};if(!o.length||!s)return n;const{mainKey:f,group:v,nameCol:m,valueCol:u,isSelfDetail:x}=r||{};return f&&v&&pl.isNumber(m)&&pl.isNumber(u)?await Uh({menu:o,mainKey:f,detailGroup:v,detailNameCol:m,detailValueCol:u,isSelfDetail:x}):pl.isNumber(c)&&pl.isNumber(y)?await qh({menu:o,group:s,nameCol:c,valueCol:y}):n},Wh=async({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})=>{const{type:o,title:s}=l||{},c=On==null?void 0:On[o];if(!c)return;const{initBaseoptions:y,initSeries:f}=c,v=y();v.title.text=s??"";const{names:m,values:u}=await Ct(r,n);if(!m||!u)return v;v.xAxis.data=m;const x=f({data:u});return v.series.push(x),v},Kh=async({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})=>{const{type:o,title:s}=l||{},c=On==null?void 0:On[o];if(!c)return;const{initBaseoptions:y,initSeries:f}=c,v=y();v.title.text=s??"";const{names:m,values:u}=await Ct(r,n);if(!m||!u)return v;v.xAxis.data=m;const x=f({data:u});return v.series.push(x),v},Yh=async({chartBaseConfig:l,chartDataConfig:r,chartDetailConfig:n})=>{const{type:o,title:s}=l||{},c=On==null?void 0:On[o];if(!c)return;const{initBaseoptions:y,initSeries:f}=c,v=y();v.title.text=s??"";const{names:m,values:u}=await Ct(r,n);if(!m||!u)return v;const x=[];for(let B=0;B<m.length;B++){const w=m[B],V=u[B];x.push({name:w,value:V})}const E=f({data:x});return v.series.push(E),v},Gh=async(l=[])=>{var y,f,v;const r=((y=l==null?void 0:l.find(m=>m.key==="chartBaseConfig"))==null?void 0:y.contents)??{},n=((f=l==null?void 0:l.find(m=>m.key==="chartDataConfig"))==null?void 0:f.contents)??{},o=((v=l==null?void 0:l.find(m=>m.key==="chartDetailConfig"))==null?void 0:v.contents)??{},{type:s}=r;let c={};return s==="line"&&(c=await Wh({chartBaseConfig:r,chartDataConfig:n,chartDetailConfig:o})),s==="bar"&&(c=await Kh({chartBaseConfig:r,chartDataConfig:n,chartDetailConfig:o})),s==="pie"&&(c=await Yh({chartBaseConfig:r,chartDataConfig:n,chartDetailConfig:o})),c},Jh=a.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}},height:{type:String,default:"300px"}},setup(l){const r=l,n=a.ref({});a.onMounted(async()=>{const s=r==null?void 0:r.itemData;n.value=await Gh(s)});const o=a.computed(()=>(r==null?void 0:r.height)||"300px");return(s,c)=>(a.openBlock(),a.createElementBlock("div",{class:"eCharts",style:a.normalizeStyle({height:o.value})},[a.createVNode(bu.ssChart,{optionContents:n.value},null,8,["optionContents"])],4))}}),Xh=ql._export_sfc(Jh,[["__scopeId","data-v-d4c081e8"]]),Zh={class:"chart-module layout"},Qh={class:"chart-module content"},e4={class:"chart-module content"},a4={class:"form-content"},l4={class:"dialog-footer"},r4={class:"form-content"},n4={class:"dialog-footer"},o4={class:"form-content"},i4={class:"dialog-footer"},t4=a.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r,s=a.reactive({visible:!1,width:"840",title:"基础配置"}),c=a.ref([]),y=()=>[{label:"类型",prop:"type",type:"select",contents:[{label:"柱状图",value:"bar"},{label:"饼图",value:"pie"},{label:"折线图",value:"line"}],value:""},{label:"标题",prop:"title",type:"input",value:""}],f=a.ref({}),v=()=>{var He;c.value=y(),(He=c.value)==null||He.forEach(Te=>{var Ge;const Re=Te==null?void 0:Te.prop;Te.value=(Ge=f==null?void 0:f.value)==null?void 0:Ge[Re]}),s.visible=!0},m=He=>{f.value=He},u=()=>{var He;s.visible=!1,o("change",(He=Ve())==null?void 0:He.compData)},x=a.reactive({visible:!1,width:"840",title:"数据配置"}),E=a.ref([]),B=()=>[{label:"菜单选项",prop:"menu",type:"cascader",contents:[]},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],w=a.ref({}),V=()=>{const He=E.value,Te=I.cloneDeep(He);return Te==null||Te.forEach(Re=>{var Ga;const Ge=Re==null?void 0:Re.prop;Re.value=(Ga=w.value)==null?void 0:Ga[Ge]}),Te},A=He=>{var Re;w.value=He;const Te=V();E.value=Te,o("change",(Re=Ve())==null?void 0:Re.compData)},N=async()=>{const He=await ca.getMenusContent(),Te=V();Te==null||Te.forEach(Re=>{(Re==null?void 0:Re.prop)==="menu"&&(Re.contents=He)}),E.value=Te,x.visible=!0,await pa(w.value.menu),await ee(w.value.group)},Y=a.reactive({visible:!1,width:"840",title:"详情页配置"}),b=a.ref([]),$=()=>[{label:"详情页主键",prop:"mainKey",type:"select",contents:[]},{label:"使用当前详情页内容",prop:"isSelfDetail",type:"switch"},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],T=a.ref({}),k=()=>{const He=b.value,Te=I.cloneDeep(He);return Te==null||Te.forEach(Re=>{var Ga;const Ge=Re==null?void 0:Re.prop;Re.value=(Ga=T.value)==null?void 0:Ga[Ge]}),Te},_=He=>{var Re;T.value=He;const Te=k();b.value=Te,o("change",(Re=Ve())==null?void 0:Re.compData)},U=async()=>{await ne();const He=I.cloneDeep(W.value),Te=k();Te==null||Te.forEach(Re=>{var Ga;const Ge=Re==null?void 0:Re.prop;Re.value=(Ga=T==null?void 0:T.value)==null?void 0:Ga[Ge],Ge==="mainKey"&&(Re.contents=He)}),b.value=Te,Y.visible=!0},W=a.ref([]),ce=a.ref([]),Ee=a.ref({}),Ie=a.ref({}),De=()=>{const{compData:He}=me.value||{},Te=He==null?void 0:He.find(J=>{const{key:ie}=J;return ie==="header"}),Re=(Te==null?void 0:Te.contents)||[],Ge=Re==null?void 0:Re.filter((J,ie)=>{const{label:se}=J;return se!=="操作"}),Ga=Ge==null?void 0:Ge.findIndex((J,ie)=>{const{isMainKey:se}=J;return se});if(Ga<0)return[];const Fa=He==null?void 0:He.find(J=>{const{key:ie}=J;return ie==="tableContents"}),P=(Fa==null?void 0:Fa.contents)||[];return P==null?void 0:P.map(J=>{const ie=J==null?void 0:J[0];let se=Ga;rl.isObject(ie)&&(ie!=null&&ie.id)&&(se=se+1);const ma=J==null?void 0:J[se];return{label:ma,value:ma}})},ne=async()=>{const He=await De();W.value=He},ge=async He=>{const Te=sessionStorage.getItem("systemKey");return await ca.getItemData(He,Te,"")},X=async He=>{const Te=He;ce.value=Te==null?void 0:Te.map(Re=>{const{name:Ge}=Re;return Ee.value[Ge]=Re,{label:Ge,value:Ge}})},de=He=>{const{comp:Te,compData:Re}=Ie.value||{};if(Te==="Table"){let Ge=k();Ge=Ge.filter(Ga=>{const{prop:Fa}=Ga;return Fa!=="formItems"}),_a(Ge,Re),b.value=Ge}},Ke=async()=>{var Re,Ge;const He=(Re=T==null?void 0:T.value)==null?void 0:Re.mainKey,Te=(Ge=w==null?void 0:w.value)==null?void 0:Ge.menu;if(He){const Fa=`${Te==null?void 0:Te.join("/")}^${He}`,P=await ge(Fa);await X(P);const F=k();F==null||F.forEach(J=>{(J==null?void 0:J.prop)==="group"&&(J.contents=ce.value)}),b.value=F}};a.watch(()=>{var He;return(He=T==null?void 0:T.value)==null?void 0:He.mainKey},async(He,Te)=>{He!=Te&&He&&await Ke()});const Ta=async He=>{const Te=Ee.value[He];Ie.value=Te,await de()};a.watch(()=>{var He;return(He=T==null?void 0:T.value)==null?void 0:He.group},async(He,Te)=>{He!=Te&&He&&Ta(He)});const oe=async()=>{var Te;await Ke();const He=(Te=T.value)==null?void 0:Te.group;await Ta(He)},S=a.ref([]),le=a.ref({}),me=a.ref({}),ue=async He=>{const Te=He==null?void 0:He.join("/"),Re=sessionStorage.getItem("systemKey");return await ca.getItemData(Te,Re,"")},Ne=async He=>{const Te=await ue(He);S.value=Te==null?void 0:Te.map(Re=>{const{name:Ge}=Re;return le.value[Ge]=Re,{label:Ge,value:Ge}})},pa=async(He,Te)=>{await Ne(He);const Re=V();Re==null||Re.forEach(Ge=>{(Ge==null?void 0:Ge.prop)==="group"&&(Ge.contents=S.value)}),E.value=Re};a.watch(()=>{var He;return(He=w==null?void 0:w.value)==null?void 0:He.menu},async(He,Te)=>{const Re=He==null?void 0:He.join("/"),Ge=Te==null?void 0:Te.join("/");Re!=Ge&&await pa(He)});const _a=(He,Te)=>{const Re=Te==null?void 0:Te.find(P=>{const{key:F}=P;return F==="header"}),Ge=(Re==null?void 0:Re.contents)||[],Ga=Ge==null?void 0:Ge.filter((P,F)=>{const{label:J}=P;return J!=="操作"}),Fa=Ga==null?void 0:Ga.map((P,F)=>{const{label:J}=P;return{label:J,value:F}});He==null||He.forEach(P=>{const F=P==null?void 0:P.prop;(F==="nameCol"||F==="valueCol")&&(P.contents=Fa)})},Wa=He=>{const{comp:Te,compData:Re}=me.value||{};if(Te==="Table"){w.value.formItems=[];let Ge=V();Ge=Ge.filter(Ga=>{const{prop:Fa}=Ga;return Fa!=="formItems"}),_a(Ge,Re),E.value=Ge}},ee=async He=>{const Te=le.value[He];me.value=Te,await Wa()};a.watch(()=>{var He;return(He=w==null?void 0:w.value)==null?void 0:He.group},async(He,Te)=>{He!=Te&&ee(He)});const la=async()=>{var Re,Ge;const He=(Re=w.value)==null?void 0:Re.menu;await pa(He);const Te=(Ge=w.value)==null?void 0:Ge.group;await ee(Te)},Ve=()=>({comp:"chart",compData:[{key:"chartBaseConfig",contents:f.value},{key:"chartDataConfig",contents:w.value},{key:"chartDetailConfig",contents:T.value}]}),ka=()=>{s.visible=!1,x.visible=!1,Y.visible=!1};return a.onMounted(async()=>{var Te,Re,Ge;E.value=B(),b.value=$();const He=n==null?void 0:n.itemContents;f.value=((Te=He==null?void 0:He.find(Ga=>Ga.key==="chartBaseConfig"))==null?void 0:Te.contents)??{},w.value=((Re=He==null?void 0:He.find(Ga=>Ga.key==="chartDataConfig"))==null?void 0:Re.contents)??{},await la(),T.value=((Ge=He==null?void 0:He.find(Ga=>Ga.key==="chartDetailConfig"))==null?void 0:Ge.contents)??{},await oe()}),(He,Te)=>{const Re=a.resolveComponent("el-button");return a.openBlock(),a.createElementBlock(a.Fragment,null,[a.createElementVNode("div",null,[a.createElementVNode("div",Zh,[Te[4]||(Te[4]=a.createElementVNode("div",{class:"module-title"},"基础配置",-1)),a.createVNode(Re,{id:"themeButton",onClick:Te[0]||(Te[0]=Ge=>v())},{default:a.withCtx(()=>Te[3]||(Te[3]=[a.createTextVNode(" 修改 ")])),_:1,__:[3]})]),a.createElementVNode("div",Qh,[Te[6]||(Te[6]=a.createElementVNode("h4",{class:"module-title"},"数据配置",-1)),a.createVNode(Re,{id:"themeButton",onClick:Te[1]||(Te[1]=Ge=>N())},{default:a.withCtx(()=>Te[5]||(Te[5]=[a.createTextVNode(" 修改 ")])),_:1,__:[5]})]),a.createElementVNode("div",e4,[Te[8]||(Te[8]=a.createElementVNode("h4",{class:"module-title"},"详情数据配置",-1)),a.createVNode(Re,{id:"themeButton",onClick:Te[2]||(Te[2]=Ge=>U())},{default:a.withCtx(()=>Te[7]||(Te[7]=[a.createTextVNode(" 修改 ")])),_:1,__:[7]})])]),a.createVNode(vr.ssDialog,{visible:s.visible,title:s.title,onBeforeDestroy:ka,width:s.width},{default:a.withCtx(()=>[a.createElementVNode("div",a4,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:c.value,key:c.value,isEnableWrap:!0,onChange:m},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",l4,[a.createVNode(Re,{class:"cancel-button button",onClick:ka,id:"themeBorderButton"},{default:a.withCtx(()=>Te[9]||(Te[9]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[9]}),a.createVNode(Re,{class:"ok-button button",onClick:u,id:"themeButton"},{default:a.withCtx(()=>Te[10]||(Te[10]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[10]})])]),_:1},8,["visible","title","width"]),a.createVNode(vr.ssDialog,{visible:x.visible,title:x.title,onBeforeDestroy:ka,width:x.width},{default:a.withCtx(()=>[a.createElementVNode("div",r4,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:E.value,key:E.value,isEnableWrap:!0,onChange:A},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",n4,[a.createVNode(Re,{class:"cancel-button button",onClick:ka,id:"themeBorderButton"},{default:a.withCtx(()=>Te[11]||(Te[11]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[11]}),a.createVNode(Re,{class:"ok-button button",onClick:ka,id:"themeButton"},{default:a.withCtx(()=>Te[12]||(Te[12]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible","title","width"]),a.createVNode(vr.ssDialog,{visible:Y.visible,title:Y.title,onBeforeDestroy:ka,width:Y.width},{default:a.withCtx(()=>[a.createElementVNode("div",o4,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:_},null,8,["rowContents"]))])]),footer:a.withCtx(()=>[a.createElementVNode("div",i4,[a.createVNode(Re,{class:"cancel-button button",onClick:ka,id:"themeBorderButton"},{default:a.withCtx(()=>Te[13]||(Te[13]=[a.createTextVNode(a.toDisplayString("取消"))])),_:1,__:[13]}),a.createVNode(Re,{class:"ok-button button",onClick:ka,id:"themeButton"},{default:a.withCtx(()=>Te[14]||(Te[14]=[a.createTextVNode(a.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible","title","width"])],64)}}}),s4=ql._export_sfc(t4,[["__scopeId","data-v-fe119645"]]),c4={class:"layout"},u4=a.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}}},emits:["rowClick"],setup(l,{emit:r}){const n=r,o=l;a.onMounted(async()=>{});const s=a.computed(()=>I.cloneDeep(o==null?void 0:o.itemData)||[]),c=a.computed(()=>{var u;const m=(u=s==null?void 0:s.value)==null?void 0:u.find(x=>{const{key:E}=x;return E==="baseConfig"});return m==null?void 0:m.contents}),y=a.computed(()=>{var u;const m=(u=s==null?void 0:s.value)==null?void 0:u.find(x=>{const{key:E}=x;return E==="children"});return m==null?void 0:m.contents}),f=a.computed(()=>{let m=I.cloneDeep(y.value)||[];const u=m.length;let x=0;const E=[];if(m=m.map(B=>{const w=B.span;return w?(B.span=Number(w),x=x+B.span):E.push(B),B}),x<24){const B=Math.floor((24-x)/u);E.forEach(w=>{w.span=B})}return m}),v=m=>{n("rowClick",m)};return(m,u)=>{var B;const x=a.resolveComponent("el-col"),E=a.resolveComponent("el-row");return a.openBlock(),a.createElementBlock("div",c4,[a.createVNode(E,{style:a.normalizeStyle({height:(B=c.value)==null?void 0:B.height})},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(f.value,(w,V)=>(a.openBlock(),a.createBlock(x,{span:w==null?void 0:w.span},{default:a.withCtx(()=>{var A;return[a.unref(So)?(a.openBlock(),a.createBlock(a.resolveDynamicComponent(a.unref(Fo)(w.comp)),{key:a.unref(qn),compName:w.name,index:(w==null?void 0:w.id)??V,height:(A=c.value)==null?void 0:A.height,itemData:w==null?void 0:w.compData,childItemData:w==null?void 0:w.itemChildData,onChange:a.unref(Ci),onContentChange:a.unref(Ei),onPageChange:a.unref(Si),onRowClick:v},null,40,["compName","index","height","itemData","childItemData","onChange","onContentChange","onPageChange"])):a.createCommentVNode("",!0)]}),_:2},1032,["span"]))),256))]),_:1},8,["style"])])}}}),d4=ql._export_sfc(u4,[["__scopeId","data-v-ab9a36ed"]]),p4={class:"layout-operate"},f4={class:"layout-module"},h4={class:"collapse-title-item"},v4={class:"collapse-title"},m4={class:"icon-content"},y4=["onClick"],g4={class:"comp-child"},b4=a.defineComponent({__name:"operate",props:{itemContents:{type:Object,default:()=>{}},originalItemContents:{type:Array,default:()=>[]},itemChildData:{type:Array,default:()=>[]}},emits:["change"],setup(l,{emit:r}){const n=l,o=r;a.onMounted(()=>{V()});const s=a.ref({}),c=a.ref({}),y=a.ref([]),f=T=>[{label:"高度",prop:"height",type:"input",value:T==null?void 0:T.height}],v=T=>{c.value=T,o("change",$(),!0)},m=a.ref([]),u=a.ref([]),x=T=>[{label:"占比",prop:"span",type:"input",value:T==null?void 0:T.span}],E=a.computed(()=>{const T=n==null?void 0:n.itemContents;return I.cloneDeep(T)}),B=a.computed(()=>{const T=E==null?void 0:E.value,k=T==null?void 0:T.find(_=>{const{key:U}=_;return U==="baseConfig"});return k==null?void 0:k.contents}),w=a.computed(()=>{const T=E==null?void 0:E.value,k=T==null?void 0:T.find(_=>{const{key:U}=_;return U==="children"});return k==null?void 0:k.contents}),V=()=>{var T;s.value=E.value||{},m.value=(w==null?void 0:w.value)||[],y.value=f(),y.value=(T=y.value)==null?void 0:T.map(k=>{var U;const{prop:_}=k;return k.value=(U=B.value)==null?void 0:U[_],k})};a.watch(()=>{var T;return(T=w==null?void 0:w.value)==null?void 0:T.length},()=>{var T;m.value=(w==null?void 0:w.value)||[],u.value=(T=w.value)==null?void 0:T.map(k=>x(k))},{immediate:!0});const A=(T,k)=>{const _=I.cloneDeep(w==null?void 0:w.value);_[k].span=T.span,m.value=_,o("change",$(),!0)},N=T=>Do(T),Y=(T,k,_)=>{if(!T)return;const U=I.cloneDeep(w==null?void 0:w.value);U[_]&&(U[_].compData=T,m.value=U,o("change",$(),!0))},b=T=>{I.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{let k=I.cloneDeep(w==null?void 0:w.value);k=k==null?void 0:k.filter((_,U)=>T!==U),m.value=k,o("change",$(),!0),rl.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},$=()=>({compData:[{key:"baseConfig",contents:c.value},{key:"children",contents:m==null?void 0:m.value}]});return(T,k)=>{const _=a.resolveComponent("svg-icon");return a.openBlock(),a.createElementBlock("div",p4,[a.createElementVNode("div",f4,[k[1]||(k[1]=a.createElementVNode("div",{class:"module-title"},"基础配置",-1)),a.createElementVNode("div",null,[a.createVNode(pl.ssForm,{rowContents:y.value,isEnableWrap:!0,onChange:k[0]||(k[0]=U=>v(U))},null,8,["rowContents"])])]),a.createVNode(Us.default,{class:"collapse-content",collapseContents:w.value},{title:a.withCtx(({item:U,index:W})=>[a.createElementVNode("div",h4,[a.createElementVNode("div",v4,a.toDisplayString(U.name),1),a.createElementVNode("div",m4,[a.createElementVNode("div",{onClick:a.withModifiers(ce=>b(W),["stop"]),class:"icon-content"},[a.createVNode(_,{name:"Delete",style:{width:"16px",height:"16px"}})],8,y4)])])]),content:a.withCtx(({item:U,index:W})=>[a.createElementVNode("div",g4,[a.createElementVNode("div",null,[(a.openBlock(),a.createBlock(pl.ssForm,{rowContents:u.value[W],key:W,isEnableWrap:!0,onChange:ce=>A(ce,W)},null,8,["rowContents","onChange"]))]),(a.openBlock(),a.createBlock(a.resolveDynamicComponent(N(U.comp+"Operate")),{itemContents:U==null?void 0:U.compData,originalItemContents:U.compData,onChange:ce=>Y(ce,U,W)},null,40,["itemContents","originalItemContents","onChange"]))])]),_:1},8,["collapseContents"])])}}}),k4=ql._export_sfc(b4,[["__scopeId","data-v-ba05456e"]]),x4=typeof window<"u";var ys;x4&&((ys=window==null?void 0:window.navigator)!=null&&ys.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function rn(l){return l==null}function Sc(){}const _4=Object.freeze({aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"});Object.freeze(new Set(Object.keys(_4)));function w4(){const l=new Map;return{on(r,n){const o=l.get(r);o!=null&&o.add(n)||l.set(r,new Set([n]))},off(r,n){const o=l.get(r);o&&o.delete(n)},clear(r){const n=l.get(r);n&&n.clear()},clearAll(){l.clear()},emit(r,...n){const o=l.get(r);o&&o.forEach(s=>{s(...n)})}}}function gs(l,r=16){if(typeof l!="function")return Sc;const n=(...c)=>{l(...c)};if(r<=0)return Dc(n);let o=0,s;return function(...c){const y=Date.now(),f=y-o;clearTimeout(s),f>=r?(o=y,n(...c)):s=setTimeout(()=>{o=Date.now(),n(...c)},Math.max(0,r-f))}}function C4(l,r=100){if(typeof l!="function")return Sc;const n=(...s)=>{l(...s)};if(r<=0)return Dc(n);let o;return function(...s){clearTimeout(o),o=setTimeout(()=>{n(...s)},r)}}function Dc(l){if(typeof l!="function")return l;let r=!1,n,o;return function(...s){return n=s,r||(r=!0,o=Promise.resolve().then(()=>(r=!1,o=void 0,l(...n)))),o}}const $o=new Set,Nc=new WeakMap;function E4(){$o.forEach(l=>{l(...Nc.get(l))}),$o.clear()}function jr(l,...r){if(typeof l!="function")return l;Nc.set(l,r),!$o.has(l)&&($o.add(l),$o.size===1&&Promise.resolve().then(E4))}const Bc=Symbol("LAYOUT_KEY"),Tc=Symbol("EMITTER_KEY");function S4(l){let r=0,n;for(let o=0,s=l.length;o<s;o++)n=l[o].y+l[o].h,n>r&&(r=n);return r}function yt(l){const r=Array(l.length);for(let n=0,o=l.length;n<o;n++)r[n]=D4(l[n]);return r}function D4(l){return{...l}}function Ac(l,r){return!(l===r||l.x+l.w<=r.x||l.x>=r.x+r.w||l.y+l.h<=r.y||l.y>=r.y+r.h)}function ko(l,r,n){const o=Mc(l),s=Oc(l),c=Array(l.length);for(let y=0,f=s.length;y<f;y++){let v=s[y];v.static||(v=N4(o,v,r,n),o.push(v)),c[l.findIndex(m=>m.i===v.i)]=v,v.moved=!1}return c}function N4(l,r,n,o){if(n)for(;r.y>0&&!Ro(l,r);)r.y--;else if(o){const c=o[r.i].y;for(;r.y>c&&!Ro(l,r);)r.y--}let s;for(;s=Ro(l,r);)r.y=s.y+s.h;return r}function B4(l,r){const n=Mc(l);for(let o=0,s=l.length;o<s;o++){const c=l[o];if(c.x+c.w>r.cols&&(c.x=r.cols-c.w),c.x<0&&(c.x=0,c.w=r.cols),!c.static)n.push(c);else for(;Ro(n,c);)c.y++}return l}function bs(l,r){for(let n=0,o=l.length;n<o;n++)if(l[n].i===r)return l[n]}function Ro(l,r){for(let n=0,o=l.length;n<o;n++)if(Ac(l[n],r))return l[n]}function zc(l,r){return l.filter(n=>Ac(n,r))}function Mc(l){return l.filter(r=>r.static)}function gt(l,r,n,o,s=!1,c=!1){if(r.static)return l;const y=r.x,f=r.y,v=o&&r.y>o;typeof n=="number"&&(r.x=n),typeof o=="number"&&(r.y=o),r.moved=!0;let m=Oc(l);v&&(m=m.reverse());const u=zc(m,r);if(c&&u.length)return r.x=y,r.y=f,r.moved=!1,l;for(let x=0,E=u.length;x<E;x++){const B=u[x];B.moved||r.y>B.y&&r.y-B.y>B.h/4||(B.static?l=ks(l,B,r,s):l=ks(l,r,B,s))}return l}function ks(l,r,n,o){if(o){const s={x:n.x,y:n.y,w:n.w,h:n.h};if(s.y=Math.max(r.y-n.h,0),!Ro(l,s))return gt(l,n,void 0,s.y,!1)}return gt(l,n,void 0,n.y+1,!1)}function T4(l,r,n,o){const s="translate3d("+r+"px,"+l+"px, 0)";return{transform:s,WebkitTransform:s,MozTransform:s,msTransform:s,OTransform:s,width:n+"px",height:o+"px",position:"absolute"}}function A4(l,r,n,o){const s="translate3d("+r*-1+"px,"+l+"px, 0)";return{transform:s,WebkitTransform:s,MozTransform:s,msTransform:s,OTransform:s,width:n+"px",height:o+"px",position:"absolute"}}function z4(l,r,n,o){return{top:l+"px",left:r+"px",width:n+"px",height:o+"px",position:"absolute"}}function M4(l,r,n,o){return{top:l+"px",right:r+"px",width:n+"px",height:o+"px",position:"absolute"}}function Oc(l){return Array.from(l).sort(function(r,n){return r.y===n.y&&r.x===n.x?0:r.y>n.y||r.y===n.y&&r.x>n.x?1:-1})}function O4(l,r){r=r||"Layout";const n=["x","y","w","h"],o=[];if(!Array.isArray(l))throw new Error(r+" must be an array!");for(let s=0,c=l.length;s<c;s++){const y=l[s];for(let f=0;f<n.length;f++)if(typeof y[n[f]]!="number")throw new Error("VueGridLayout: "+r+"["+s+"]."+n[f]+" must be a number!");if(y.i===void 0||y.i===null)throw new Error("VueGridLayout: "+r+"["+s+"].i cannot be null!");if(typeof y.i!="number"&&typeof y.i!="string")throw new Error("VueGridLayout: "+r+"["+s+"].i must be a string or number!");if(o.indexOf(y.i)>=0)throw new Error("VueGridLayout: "+r+"["+s+"].i must be unique!");if(o.push(y.i),y.static!==void 0&&typeof y.static!="boolean")throw new Error("VueGridLayout: "+r+"["+s+"].static must be a boolean!")}}function I4(l,r="vgl"){const n=()=>`${r}-${l}`;return{b:n,be:o=>`${n()}__${o}`,bm:o=>`${n()}--${o}`,bem:(o,s)=>`${n()}__${o}--${s}`}}function xs(l){return L4(l)}function L4(l){var r;const n=((r=l.target)==null?void 0:r.offsetParent)||document.body,o=l.offsetParent===document.body?{left:0,top:0}:n.getBoundingClientRect(),s=l.clientX+n.scrollLeft-o.left,c=l.clientY+n.scrollTop-o.top;return{x:s,y:c}}function _s(l,r,n,o){return $4(l)?{deltaX:n-l,deltaY:o-r,lastX:l,lastY:r,x:n,y:o}:{deltaX:0,deltaY:0,lastX:n,lastY:o,x:n,y:o}}function $4(l){return typeof l=="number"&&!Number.isNaN(l)}function R4(l,r){const n=Lc(l);let o=n[0];for(let s=1,c=n.length;s<c;s++){const y=n[s];r>l[y]&&(o=y)}return o}function Ic(l,r){if(!r[l])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+l+" is missing!");return r[l]}function V4(l,r,n,o,s,c,y){if(r[o])return yt(r[o]);let f=l;const v=Lc(n),m=v.slice(v.indexOf(o));for(let u=0,x=m.length;u<x;u++){const E=m[u];if(r[E]){f=r[E];break}}return f=yt(f||[]),ko(B4(f,{cols:c}),y)}function Lc(l){return Object.keys(l).sort((r,n)=>l[r]-l[n])}let P4="auto";function F4(){return typeof document<"u"}function ws(){return F4()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir"):P4}var Lo={exports:{}},j4=Lo.exports,Cs;function H4(){return Cs||(Cs=1,function(l,r){(function(n,o){l.exports=o()})(j4,function(){function n(t,i){var p=Object.keys(t);if(Object.getOwnPropertySymbols){var g=Object.getOwnPropertySymbols(t);i&&(g=g.filter(function(C){return Object.getOwnPropertyDescriptor(t,C).enumerable})),p.push.apply(p,g)}return p}function o(t){for(var i=1;i<arguments.length;i++){var p=arguments[i]!=null?arguments[i]:{};i%2?n(Object(p),!0).forEach(function(g){v(t,g,p[g])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(p)):n(Object(p)).forEach(function(g){Object.defineProperty(t,g,Object.getOwnPropertyDescriptor(p,g))})}return t}function s(t){return s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(i){return typeof i}:function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},s(t)}function c(t,i){if(!(t instanceof i))throw new TypeError("Cannot call a class as a function")}function y(t,i){for(var p=0;p<i.length;p++){var g=i[p];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(t,V(g.key),g)}}function f(t,i,p){return i&&y(t.prototype,i),Object.defineProperty(t,"prototype",{writable:!1}),t}function v(t,i,p){return(i=V(i))in t?Object.defineProperty(t,i,{value:p,enumerable:!0,configurable:!0,writable:!0}):t[i]=p,t}function m(t,i){if(typeof i!="function"&&i!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(i&&i.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),i&&x(t,i)}function u(t){return u=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(i){return i.__proto__||Object.getPrototypeOf(i)},u(t)}function x(t,i){return x=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(p,g){return p.__proto__=g,p},x(t,i)}function E(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function B(t){var i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}();return function(){var p,g=u(t);if(i){var C=u(this).constructor;p=Reflect.construct(g,arguments,C)}else p=g.apply(this,arguments);return function(L,H){if(H&&(typeof H=="object"||typeof H=="function"))return H;if(H!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return E(L)}(this,p)}}function w(){return w=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(t,i,p){var g=function(L,H){for(;!Object.prototype.hasOwnProperty.call(L,H)&&(L=u(L))!==null;);return L}(t,i);if(g){var C=Object.getOwnPropertyDescriptor(g,i);return C.get?C.get.call(arguments.length<3?t:p):C.value}},w.apply(this,arguments)}function V(t){var i=function(p,g){if(typeof p!="object"||p===null)return p;var C=p[Symbol.toPrimitive];if(C!==void 0){var L=C.call(p,g);if(typeof L!="object")return L;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(p)}(t,"string");return typeof i=="symbol"?i:i+""}var A=function(t){return!(!t||!t.Window)&&t instanceof t.Window},N=void 0,Y=void 0;function b(t){N=t;var i=t.document.createTextNode("");i.ownerDocument!==t.document&&typeof t.wrap=="function"&&t.wrap(i)===i&&(t=t.wrap(t)),Y=t}function $(t){return A(t)?t:(t.ownerDocument||t).defaultView||Y.window}typeof window<"u"&&window&&b(window);var T=function(t){return!!t&&s(t)==="object"},k=function(t){return typeof t=="function"},_={window:function(t){return t===Y||A(t)},docFrag:function(t){return T(t)&&t.nodeType===11},object:T,func:k,number:function(t){return typeof t=="number"},bool:function(t){return typeof t=="boolean"},string:function(t){return typeof t=="string"},element:function(t){if(!t||s(t)!=="object")return!1;var i=$(t)||Y;return/object|function/.test(typeof Element>"u"?"undefined":s(Element))?t instanceof Element||t instanceof i.Element:t.nodeType===1&&typeof t.nodeName=="string"},plainObject:function(t){return T(t)&&!!t.constructor&&/function Object\b/.test(t.constructor.toString())},array:function(t){return T(t)&&t.length!==void 0&&k(t.splice)}};function U(t){var i=t.interaction;if(i.prepared.name==="drag"){var p=i.prepared.axis;p==="x"?(i.coords.cur.page.y=i.coords.start.page.y,i.coords.cur.client.y=i.coords.start.client.y,i.coords.velocity.client.y=0,i.coords.velocity.page.y=0):p==="y"&&(i.coords.cur.page.x=i.coords.start.page.x,i.coords.cur.client.x=i.coords.start.client.x,i.coords.velocity.client.x=0,i.coords.velocity.page.x=0)}}function W(t){var i=t.iEvent,p=t.interaction;if(p.prepared.name==="drag"){var g=p.prepared.axis;if(g==="x"||g==="y"){var C=g==="x"?"y":"x";i.page[C]=p.coords.start.page[C],i.client[C]=p.coords.start.client[C],i.delta[C]=0}}}var ce={id:"actions/drag",install:function(t){var i=t.actions,p=t.Interactable,g=t.defaults;p.prototype.draggable=ce.draggable,i.map.drag=ce,i.methodDict.drag="draggable",g.actions.drag=ce.defaults},listeners:{"interactions:before-action-move":U,"interactions:action-resume":U,"interactions:action-move":W,"auto-start:check":function(t){var i=t.interaction,p=t.interactable,g=t.buttons,C=p.options.drag;if(C&&C.enabled&&(!i.pointerIsDown||!/mouse|pointer/.test(i.pointerType)||(g&p.options.drag.mouseButtons)!=0))return t.action={name:"drag",axis:C.lockAxis==="start"?C.startAxis:C.lockAxis},!1}},draggable:function(t){return _.object(t)?(this.options.drag.enabled=t.enabled!==!1,this.setPerAction("drag",t),this.setOnEvents("drag",t),/^(xy|x|y|start)$/.test(t.lockAxis)&&(this.options.drag.lockAxis=t.lockAxis),/^(xy|x|y)$/.test(t.startAxis)&&(this.options.drag.startAxis=t.startAxis),this):_.bool(t)?(this.options.drag.enabled=t,this):this.options.drag},beforeMove:U,move:W,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor:function(){return"move"},filterEventType:function(t){return t.search("drag")===0}},Ee=ce,Ie={init:function(t){var i=t;Ie.document=i.document,Ie.DocumentFragment=i.DocumentFragment||De,Ie.SVGElement=i.SVGElement||De,Ie.SVGSVGElement=i.SVGSVGElement||De,Ie.SVGElementInstance=i.SVGElementInstance||De,Ie.Element=i.Element||De,Ie.HTMLElement=i.HTMLElement||Ie.Element,Ie.Event=i.Event,Ie.Touch=i.Touch||De,Ie.PointerEvent=i.PointerEvent||i.MSPointerEvent},document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function De(){}var ne=Ie,ge={init:function(t){var i=ne.Element,p=t.navigator||{};ge.supportsTouch="ontouchstart"in t||_.func(t.DocumentTouch)&&ne.document instanceof t.DocumentTouch,ge.supportsPointerEvent=p.pointerEnabled!==!1&&!!ne.PointerEvent,ge.isIOS=/iP(hone|od|ad)/.test(p.platform),ge.isIOS7=/iP(hone|od|ad)/.test(p.platform)&&/OS 7[^\d]/.test(p.appVersion),ge.isIe9=/MSIE 9/.test(p.userAgent),ge.isOperaMobile=p.appName==="Opera"&&ge.supportsTouch&&/Presto/.test(p.userAgent),ge.prefixedMatchesSelector="matches"in i.prototype?"matches":"webkitMatchesSelector"in i.prototype?"webkitMatchesSelector":"mozMatchesSelector"in i.prototype?"mozMatchesSelector":"oMatchesSelector"in i.prototype?"oMatchesSelector":"msMatchesSelector",ge.pEventTypes=ge.supportsPointerEvent?ne.PointerEvent===t.MSPointerEvent?{up:"MSPointerUp",down:"MSPointerDown",over:"mouseover",out:"mouseout",move:"MSPointerMove",cancel:"MSPointerCancel"}:{up:"pointerup",down:"pointerdown",over:"pointerover",out:"pointerout",move:"pointermove",cancel:"pointercancel"}:null,ge.wheelEvent=ne.document&&"onmousewheel"in ne.document?"mousewheel":"wheel"},supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null},X=ge;function de(t,i){if(t.contains)return t.contains(i);for(;i;){if(i===t)return!0;i=i.parentNode}return!1}function Ke(t,i){for(;_.element(t);){if(oe(t,i))return t;t=Ta(t)}return null}function Ta(t){var i=t.parentNode;if(_.docFrag(i)){for(;(i=i.host)&&_.docFrag(i););return i}return i}function oe(t,i){return Y!==N&&(i=i.replace(/\/deep\//g," ")),t[X.prefixedMatchesSelector](i)}var S=function(t){return t.parentNode||t.host};function le(t,i){for(var p,g=[],C=t;(p=S(C))&&C!==i&&p!==C.ownerDocument;)g.unshift(C),C=p;return g}function me(t,i,p){for(;_.element(t);){if(oe(t,i))return!0;if((t=Ta(t))===p)return oe(t,i)}return!1}function ue(t){return t.correspondingUseElement||t}function Ne(t){var i=t instanceof ne.SVGElement?t.getBoundingClientRect():t.getClientRects()[0];return i&&{left:i.left,right:i.right,top:i.top,bottom:i.bottom,width:i.width||i.right-i.left,height:i.height||i.bottom-i.top}}function pa(t){var i,p=Ne(t);if(!X.isIOS7&&p){var g={x:(i=(i=$(t))||Y).scrollX||i.document.documentElement.scrollLeft,y:i.scrollY||i.document.documentElement.scrollTop};p.left+=g.x,p.right+=g.x,p.top+=g.y,p.bottom+=g.y}return p}function _a(t){for(var i=[];t;)i.push(t),t=Ta(t);return i}function Wa(t){return!!_.string(t)&&(ne.document.querySelector(t),!0)}function ee(t,i){for(var p in i)t[p]=i[p];return t}function la(t,i,p){return t==="parent"?Ta(p):t==="self"?i.getRect(p):Ke(p,t)}function Ve(t,i,p,g){var C=t;return _.string(C)?C=la(C,i,p):_.func(C)&&(C=C.apply(void 0,g)),_.element(C)&&(C=pa(C)),C}function ka(t){return t&&{x:"x"in t?t.x:t.left,y:"y"in t?t.y:t.top}}function He(t){return!t||"x"in t&&"y"in t||((t=ee({},t)).x=t.left||0,t.y=t.top||0,t.width=t.width||(t.right||0)-t.x,t.height=t.height||(t.bottom||0)-t.y),t}function Te(t,i,p){t.left&&(i.left+=p.x),t.right&&(i.right+=p.x),t.top&&(i.top+=p.y),t.bottom&&(i.bottom+=p.y),i.width=i.right-i.left,i.height=i.bottom-i.top}function Re(t,i,p){var g=p&&t.options[p];return ka(Ve(g&&g.origin||t.options.origin,t,i,[t&&i]))||{x:0,y:0}}function Ge(t,i){var p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(pe){return!0},g=arguments.length>3?arguments[3]:void 0;if(g=g||{},_.string(t)&&t.search(" ")!==-1&&(t=Ga(t)),_.array(t))return t.forEach(function(pe){return Ge(pe,i,p,g)}),g;if(_.object(t)&&(i=t,t=""),_.func(i)&&p(t))g[t]=g[t]||[],g[t].push(i);else if(_.array(i))for(var C=0,L=i;C<L.length;C++){var H=L[C];Ge(t,H,p,g)}else if(_.object(i))for(var G in i)Ge(Ga(G).map(function(pe){return"".concat(t).concat(pe)}),i[G],p,g);return g}function Ga(t){return t.trim().split(/ +/)}var Fa=function(t,i){return Math.sqrt(t*t+i*i)},P=["webkit","moz"];function F(t,i){t.__set||(t.__set={});var p=function(C){if(P.some(function(L){return C.indexOf(L)===0}))return 1;typeof t[C]!="function"&&C!=="__set"&&Object.defineProperty(t,C,{get:function(){return C in t.__set?t.__set[C]:t.__set[C]=i[C]},set:function(L){t.__set[C]=L},configurable:!0})};for(var g in i)p(g);return t}function J(t,i){t.page=t.page||{},t.page.x=i.page.x,t.page.y=i.page.y,t.client=t.client||{},t.client.x=i.client.x,t.client.y=i.client.y,t.timeStamp=i.timeStamp}function ie(t){t.page.x=0,t.page.y=0,t.client.x=0,t.client.y=0}function se(t){return t instanceof ne.Event||t instanceof ne.Touch}function ma(t,i,p){return t=t||"page",(p=p||{}).x=i[t+"X"],p.y=i[t+"Y"],p}function oa(t,i){return i=i||{x:0,y:0},X.isOperaMobile&&se(t)?(ma("screen",t,i),i.x+=window.scrollX,i.y+=window.scrollY):ma("page",t,i),i}function Oe(t){return _.number(t.pointerId)?t.pointerId:t.identifier}function _e(t,i,p){var g=i.length>1?ve(i):i[0];oa(g,t.page),function(C,L){L=L||{},X.isOperaMobile&&se(C)?ma("screen",C,L):ma("client",C,L)}(g,t.client),t.timeStamp=p}function wa(t){var i=[];return _.array(t)?(i[0]=t[0],i[1]=t[1]):t.type==="touchend"?t.touches.length===1?(i[0]=t.touches[0],i[1]=t.changedTouches[0]):t.touches.length===0&&(i[0]=t.changedTouches[0],i[1]=t.changedTouches[1]):(i[0]=t.touches[0],i[1]=t.touches[1]),i}function ve(t){for(var i={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0},p=0;p<t.length;p++){var g=t[p];for(var C in i)i[C]+=g[C]}for(var L in i)i[L]/=t.length;return i}function Xe(t){if(!t.length)return null;var i=wa(t),p=Math.min(i[0].pageX,i[1].pageX),g=Math.min(i[0].pageY,i[1].pageY),C=Math.max(i[0].pageX,i[1].pageX),L=Math.max(i[0].pageY,i[1].pageY);return{x:p,y:g,left:p,top:g,right:C,bottom:L,width:C-p,height:L-g}}function aa(t,i){var p=i+"X",g=i+"Y",C=wa(t),L=C[0][p]-C[1][p],H=C[0][g]-C[1][g];return Fa(L,H)}function Pe(t,i){var p=i+"X",g=i+"Y",C=wa(t),L=C[1][p]-C[0][p],H=C[1][g]-C[0][g];return 180*Math.atan2(H,L)/Math.PI}function xa(t){return _.string(t.pointerType)?t.pointerType:_.number(t.pointerType)?[void 0,void 0,"touch","pen","mouse"][t.pointerType]:/touch/.test(t.type||"")||t instanceof ne.Touch?"touch":"mouse"}function Le(t){var i=_.func(t.composedPath)?t.composedPath():t.path;return[ue(i?i[0]:t.target),ue(t.currentTarget)]}var va=function(){function t(i){c(this,t),this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=i}return f(t,[{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),t}();Object.defineProperty(va.prototype,"interaction",{get:function(){return this._interaction._proxy},set:function(){}});var re=function(t,i){for(var p=0;p<i.length;p++){var g=i[p];t.push(g)}return t},Ce=function(t){return re([],t)},Z=function(t,i){for(var p=0;p<t.length;p++)if(i(t[p],p,t))return p;return-1},fa=function(t,i){return t[Z(t,i)]},Ye=function(t){m(p,t);var i=B(p);function p(g,C,L){var H;c(this,p),(H=i.call(this,C._interaction)).dropzone=void 0,H.dragEvent=void 0,H.relatedTarget=void 0,H.draggable=void 0,H.propagationStopped=!1,H.immediatePropagationStopped=!1;var G=L==="dragleave"?g.prev:g.cur,pe=G.element,Me=G.dropzone;return H.type=L,H.target=pe,H.currentTarget=pe,H.dropzone=Me,H.dragEvent=C,H.relatedTarget=C.target,H.draggable=C.interactable,H.timeStamp=C.timeStamp,H}return f(p,[{key:"reject",value:function(){var g=this,C=this._interaction.dropState;if(this.type==="dropactivate"||this.dropzone&&C.cur.dropzone===this.dropzone&&C.cur.element===this.target)if(C.prev.dropzone=this.dropzone,C.prev.element=this.target,C.rejected=!0,C.events.enter=null,this.stopImmediatePropagation(),this.type==="dropactivate"){var L=C.activeDrops,H=Z(L,function(pe){var Me=pe.dropzone,ye=pe.element;return Me===g.dropzone&&ye===g.target});C.activeDrops.splice(H,1);var G=new p(C,this.dragEvent,"dropdeactivate");G.dropzone=this.dropzone,G.target=this.target,this.dropzone.fire(G)}else this.dropzone.fire(new p(C,this.dragEvent,"dragleave"))}},{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),p}(va);function Ma(t,i){for(var p=0,g=t.slice();p<g.length;p++){var C=g[p],L=C.dropzone,H=C.element;i.dropzone=L,i.target=H,L.fire(i),i.propagationStopped=i.immediatePropagationStopped=!1}}function Ue(t,i){for(var p=function(L,H){for(var G=[],pe=0,Me=L.interactables.list;pe<Me.length;pe++){var ye=Me[pe];if(ye.options.drop.enabled){var Qe=ye.options.drop.accept;if(!(_.element(Qe)&&Qe!==H||_.string(Qe)&&!oe(H,Qe)||_.func(Qe)&&!Qe({dropzone:ye,draggableElement:H})))for(var La=0,ol=ye.getAllElements();La<ol.length;La++){var al=ol[La];al!==H&&G.push({dropzone:ye,element:al,rect:ye.getRect(al)})}}}return G}(t,i),g=0;g<p.length;g++){var C=p[g];C.rect=C.dropzone.getRect(C.element)}return p}function Ya(t,i,p){for(var g=t.dropState,C=t.interactable,L=t.element,H=[],G=0,pe=g.activeDrops;G<pe.length;G++){var Me=pe[G],ye=Me.dropzone,Qe=Me.element,La=Me.rect,ol=ye.dropCheck(i,p,C,L,Qe,La);H.push(ol?Qe:null)}var al=function(sl){for(var Cl,cl,Bl,Ol=[],Yl=0;Yl<sl.length;Yl++){var Nl=sl[Yl],jl=sl[Cl];if(Nl&&Yl!==Cl)if(jl){var Ir=S(Nl),mr=S(jl);if(Ir!==Nl.ownerDocument)if(mr!==Nl.ownerDocument)if(Ir!==mr){Ol=Ol.length?Ol:le(jl);var Fr=void 0;if(jl instanceof ne.HTMLElement&&Nl instanceof ne.SVGElement&&!(Nl instanceof ne.SVGSVGElement)){if(Nl===mr)continue;Fr=Nl.ownerSVGElement}else Fr=Nl;for(var en=le(Fr,jl.ownerDocument),tn=0;en[tn]&&en[tn]===Ol[tn];)tn++;var uo=[en[tn-1],en[tn],Ol[tn]];if(uo[0])for(var Tn=uo[0].lastChild;Tn;){if(Tn===uo[1]){Cl=Yl,Ol=en;break}if(Tn===uo[2])break;Tn=Tn.previousSibling}}else Bl=jl,(parseInt($(cl=Nl).getComputedStyle(cl).zIndex,10)||0)>=(parseInt($(Bl).getComputedStyle(Bl).zIndex,10)||0)&&(Cl=Yl);else Cl=Yl}else Cl=Yl}return Cl}(H);return g.activeDrops[al]||null}function ga(t,i,p){var g=t.dropState,C={enter:null,leave:null,activate:null,deactivate:null,move:null,drop:null};return p.type==="dragstart"&&(C.activate=new Ye(g,p,"dropactivate"),C.activate.target=null,C.activate.dropzone=null),p.type==="dragend"&&(C.deactivate=new Ye(g,p,"dropdeactivate"),C.deactivate.target=null,C.deactivate.dropzone=null),g.rejected||(g.cur.element!==g.prev.element&&(g.prev.dropzone&&(C.leave=new Ye(g,p,"dragleave"),p.dragLeave=C.leave.target=g.prev.element,p.prevDropzone=C.leave.dropzone=g.prev.dropzone),g.cur.dropzone&&(C.enter=new Ye(g,p,"dragenter"),p.dragEnter=g.cur.element,p.dropzone=g.cur.dropzone)),p.type==="dragend"&&g.cur.dropzone&&(C.drop=new Ye(g,p,"drop"),p.dropzone=g.cur.dropzone,p.relatedTarget=g.cur.element),p.type==="dragmove"&&g.cur.dropzone&&(C.move=new Ye(g,p,"dropmove"),p.dropzone=g.cur.dropzone)),C}function ba(t,i){var p=t.dropState,g=p.activeDrops,C=p.cur,L=p.prev;i.leave&&L.dropzone.fire(i.leave),i.enter&&C.dropzone.fire(i.enter),i.move&&C.dropzone.fire(i.move),i.drop&&C.dropzone.fire(i.drop),i.deactivate&&Ma(g,i.deactivate),p.prev.dropzone=C.dropzone,p.prev.element=C.element}function $a(t,i){var p=t.interaction,g=t.iEvent,C=t.event;if(g.type==="dragmove"||g.type==="dragend"){var L=p.dropState;i.dynamicDrop&&(L.activeDrops=Ue(i,p.element));var H=g,G=Ya(p,H,C);L.rejected=L.rejected&&!!G&&G.dropzone===L.cur.dropzone&&G.element===L.cur.element,L.cur.dropzone=G&&G.dropzone,L.cur.element=G&&G.element,L.events=ga(p,0,H)}}var Sa={id:"actions/drop",install:function(t){var i=t.actions,p=t.interactStatic,g=t.Interactable,C=t.defaults;t.usePlugin(Ee),g.prototype.dropzone=function(L){return function(H,G){if(_.object(G)){if(H.options.drop.enabled=G.enabled!==!1,G.listeners){var pe=Ge(G.listeners),Me=Object.keys(pe).reduce(function(Qe,La){return Qe[/^(enter|leave)/.test(La)?"drag".concat(La):/^(activate|deactivate|move)/.test(La)?"drop".concat(La):La]=pe[La],Qe},{}),ye=H.options.drop.listeners;ye&&H.off(ye),H.on(Me),H.options.drop.listeners=Me}return _.func(G.ondrop)&&H.on("drop",G.ondrop),_.func(G.ondropactivate)&&H.on("dropactivate",G.ondropactivate),_.func(G.ondropdeactivate)&&H.on("dropdeactivate",G.ondropdeactivate),_.func(G.ondragenter)&&H.on("dragenter",G.ondragenter),_.func(G.ondragleave)&&H.on("dragleave",G.ondragleave),_.func(G.ondropmove)&&H.on("dropmove",G.ondropmove),/^(pointer|center)$/.test(G.overlap)?H.options.drop.overlap=G.overlap:_.number(G.overlap)&&(H.options.drop.overlap=Math.max(Math.min(1,G.overlap),0)),"accept"in G&&(H.options.drop.accept=G.accept),"checker"in G&&(H.options.drop.checker=G.checker),H}return _.bool(G)?(H.options.drop.enabled=G,H):H.options.drop}(this,L)},g.prototype.dropCheck=function(L,H,G,pe,Me,ye){return function(Qe,La,ol,al,sl,Cl,cl){var Bl=!1;if(!(cl=cl||Qe.getRect(Cl)))return!!Qe.options.drop.checker&&Qe.options.drop.checker(La,ol,Bl,Qe,Cl,al,sl);var Ol=Qe.options.drop.overlap;if(Ol==="pointer"){var Yl=Re(al,sl,"drag"),Nl=oa(La);Nl.x+=Yl.x,Nl.y+=Yl.y;var jl=Nl.x>cl.left&&Nl.x<cl.right,Ir=Nl.y>cl.top&&Nl.y<cl.bottom;Bl=jl&&Ir}var mr=al.getRect(sl);if(mr&&Ol==="center"){var Fr=mr.left+mr.width/2,en=mr.top+mr.height/2;Bl=Fr>=cl.left&&Fr<=cl.right&&en>=cl.top&&en<=cl.bottom}return mr&&_.number(Ol)&&(Bl=Math.max(0,Math.min(cl.right,mr.right)-Math.max(cl.left,mr.left))*Math.max(0,Math.min(cl.bottom,mr.bottom)-Math.max(cl.top,mr.top))/(mr.width*mr.height)>=Ol),Qe.options.drop.checker&&(Bl=Qe.options.drop.checker(La,ol,Bl,Qe,Cl,al,sl)),Bl}(this,L,H,G,pe,Me,ye)},p.dynamicDrop=function(L){return _.bool(L)?(t.dynamicDrop=L,p):t.dynamicDrop},ee(i.phaselessTypes,{dragenter:!0,dragleave:!0,dropactivate:!0,dropdeactivate:!0,dropmove:!0,drop:!0}),i.methodDict.drop="dropzone",t.dynamicDrop=!1,C.actions.drop=Sa.defaults},listeners:{"interactions:before-action-start":function(t){var i=t.interaction;i.prepared.name==="drag"&&(i.dropState={cur:{dropzone:null,element:null},prev:{dropzone:null,element:null},rejected:null,events:null,activeDrops:[]})},"interactions:after-action-start":function(t,i){var p=t.interaction,g=(t.event,t.iEvent);if(p.prepared.name==="drag"){var C=p.dropState;C.activeDrops=[],C.events={},C.activeDrops=Ue(i,p.element),C.events=ga(p,0,g),C.events.activate&&(Ma(C.activeDrops,C.events.activate),i.fire("actions/drop:start",{interaction:p,dragEvent:g}))}},"interactions:action-move":$a,"interactions:after-action-move":function(t,i){var p=t.interaction,g=t.iEvent;if(p.prepared.name==="drag"){var C=p.dropState;ba(p,C.events),i.fire("actions/drop:move",{interaction:p,dragEvent:g}),C.events={}}},"interactions:action-end":function(t,i){if(t.interaction.prepared.name==="drag"){var p=t.interaction,g=t.iEvent;$a(t,i),ba(p,p.dropState.events),i.fire("actions/drop:end",{interaction:p,dragEvent:g})}},"interactions:stop":function(t){var i=t.interaction;if(i.prepared.name==="drag"){var p=i.dropState;p&&(p.activeDrops=null,p.events=null,p.cur.dropzone=null,p.cur.element=null,p.prev.dropzone=null,p.prev.element=null,p.rejected=!1)}}},getActiveDrops:Ue,getDrop:Ya,getDropEvents:ga,fireDropEvents:ba,filterEventType:function(t){return t.search("drag")===0||t.search("drop")===0},defaults:{enabled:!1,accept:null,overlap:"pointer"}},Na=Sa;function Oa(t){var i=t.interaction,p=t.iEvent,g=t.phase;if(i.prepared.name==="gesture"){var C=i.pointers.map(function(Me){return Me.pointer}),L=g==="start",H=g==="end",G=i.interactable.options.deltaSource;if(p.touches=[C[0],C[1]],L)p.distance=aa(C,G),p.box=Xe(C),p.scale=1,p.ds=0,p.angle=Pe(C,G),p.da=0,i.gesture.startDistance=p.distance,i.gesture.startAngle=p.angle;else if(H||i.pointers.length<2){var pe=i.prevEvent;p.distance=pe.distance,p.box=pe.box,p.scale=pe.scale,p.ds=0,p.angle=pe.angle,p.da=0}else p.distance=aa(C,G),p.box=Xe(C),p.scale=p.distance/i.gesture.startDistance,p.angle=Pe(C,G),p.ds=p.scale-i.gesture.scale,p.da=p.angle-i.gesture.angle;i.gesture.distance=p.distance,i.gesture.angle=p.angle,_.number(p.scale)&&p.scale!==1/0&&!isNaN(p.scale)&&(i.gesture.scale=p.scale)}}var Be={id:"actions/gesture",before:["actions/drag","actions/resize"],install:function(t){var i=t.actions,p=t.Interactable,g=t.defaults;p.prototype.gesturable=function(C){return _.object(C)?(this.options.gesture.enabled=C.enabled!==!1,this.setPerAction("gesture",C),this.setOnEvents("gesture",C),this):_.bool(C)?(this.options.gesture.enabled=C,this):this.options.gesture},i.map.gesture=Be,i.methodDict.gesture="gesturable",g.actions.gesture=Be.defaults},listeners:{"interactions:action-start":Oa,"interactions:action-move":Oa,"interactions:action-end":Oa,"interactions:new":function(t){t.interaction.gesture={angle:0,distance:0,scale:1,startAngle:0,startDistance:0}},"auto-start:check":function(t){if(!(t.interaction.pointers.length<2)){var i=t.interactable.options.gesture;if(i&&i.enabled)return t.action={name:"gesture"},!1}}},defaults:{},getCursor:function(){return""},filterEventType:function(t){return t.search("gesture")===0}},tl=Be;function Ea(t,i,p,g,C,L,H){if(!i)return!1;if(i===!0){var G=_.number(L.width)?L.width:L.right-L.left,pe=_.number(L.height)?L.height:L.bottom-L.top;if(H=Math.min(H,Math.abs((t==="left"||t==="right"?G:pe)/2)),G<0&&(t==="left"?t="right":t==="right"&&(t="left")),pe<0&&(t==="top"?t="bottom":t==="bottom"&&(t="top")),t==="left"){var Me=G>=0?L.left:L.right;return p.x<Me+H}if(t==="top"){var ye=pe>=0?L.top:L.bottom;return p.y<ye+H}if(t==="right")return p.x>(G>=0?L.right:L.left)-H;if(t==="bottom")return p.y>(pe>=0?L.bottom:L.top)-H}return!!_.element(g)&&(_.element(i)?i===g:me(g,i,C))}function El(t){var i=t.iEvent,p=t.interaction;if(p.prepared.name==="resize"&&p.resizeAxes){var g=i;p.interactable.options.resize.square?(p.resizeAxes==="y"?g.delta.x=g.delta.y:g.delta.y=g.delta.x,g.axes="xy"):(g.axes=p.resizeAxes,p.resizeAxes==="x"?g.delta.y=0:p.resizeAxes==="y"&&(g.delta.x=0))}}var ml,Fe,Va={id:"actions/resize",before:["actions/drag"],install:function(t){var i=t.actions,p=t.browser,g=t.Interactable,C=t.defaults;Va.cursors=function(L){return L.isIe9?{x:"e-resize",y:"s-resize",xy:"se-resize",top:"n-resize",left:"w-resize",bottom:"s-resize",right:"e-resize",topleft:"se-resize",bottomright:"se-resize",topright:"ne-resize",bottomleft:"ne-resize"}:{x:"ew-resize",y:"ns-resize",xy:"nwse-resize",top:"ns-resize",left:"ew-resize",bottom:"ns-resize",right:"ew-resize",topleft:"nwse-resize",bottomright:"nwse-resize",topright:"nesw-resize",bottomleft:"nesw-resize"}}(p),Va.defaultMargin=p.supportsTouch||p.supportsPointerEvent?20:10,g.prototype.resizable=function(L){return function(H,G,pe){return _.object(G)?(H.options.resize.enabled=G.enabled!==!1,H.setPerAction("resize",G),H.setOnEvents("resize",G),_.string(G.axis)&&/^x$|^y$|^xy$/.test(G.axis)?H.options.resize.axis=G.axis:G.axis===null&&(H.options.resize.axis=pe.defaults.actions.resize.axis),_.bool(G.preserveAspectRatio)?H.options.resize.preserveAspectRatio=G.preserveAspectRatio:_.bool(G.square)&&(H.options.resize.square=G.square),H):_.bool(G)?(H.options.resize.enabled=G,H):H.options.resize}(this,L,t)},i.map.resize=Va,i.methodDict.resize="resizable",C.actions.resize=Va.defaults},listeners:{"interactions:new":function(t){t.interaction.resizeAxes="xy"},"interactions:action-start":function(t){(function(i){var p=i.iEvent,g=i.interaction;if(g.prepared.name==="resize"&&g.prepared.edges){var C=p,L=g.rect;g._rects={start:ee({},L),corrected:ee({},L),previous:ee({},L),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},C.edges=g.prepared.edges,C.rect=g._rects.corrected,C.deltaRect=g._rects.delta}})(t),El(t)},"interactions:action-move":function(t){(function(i){var p=i.iEvent,g=i.interaction;if(g.prepared.name==="resize"&&g.prepared.edges){var C=p,L=g.interactable.options.resize.invert,H=L==="reposition"||L==="negate",G=g.rect,pe=g._rects,Me=pe.start,ye=pe.corrected,Qe=pe.delta,La=pe.previous;if(ee(La,ye),H){if(ee(ye,G),L==="reposition"){if(ye.top>ye.bottom){var ol=ye.top;ye.top=ye.bottom,ye.bottom=ol}if(ye.left>ye.right){var al=ye.left;ye.left=ye.right,ye.right=al}}}else ye.top=Math.min(G.top,Me.bottom),ye.bottom=Math.max(G.bottom,Me.top),ye.left=Math.min(G.left,Me.right),ye.right=Math.max(G.right,Me.left);for(var sl in ye.width=ye.right-ye.left,ye.height=ye.bottom-ye.top,ye)Qe[sl]=ye[sl]-La[sl];C.edges=g.prepared.edges,C.rect=ye,C.deltaRect=Qe}})(t),El(t)},"interactions:action-end":function(t){var i=t.iEvent,p=t.interaction;if(p.prepared.name==="resize"&&p.prepared.edges){var g=i;g.edges=p.prepared.edges,g.rect=p._rects.corrected,g.deltaRect=p._rects.delta}},"auto-start:check":function(t){var i=t.interaction,p=t.interactable,g=t.element,C=t.rect,L=t.buttons;if(C){var H=ee({},i.coords.cur.page),G=p.options.resize;if(G&&G.enabled&&(!i.pointerIsDown||!/mouse|pointer/.test(i.pointerType)||(L&G.mouseButtons)!=0)){if(_.object(G.edges)){var pe={left:!1,right:!1,top:!1,bottom:!1};for(var Me in pe)pe[Me]=Ea(Me,G.edges[Me],H,i._latestPointer.eventTarget,g,C,G.margin||Va.defaultMargin);pe.left=pe.left&&!pe.right,pe.top=pe.top&&!pe.bottom,(pe.left||pe.right||pe.top||pe.bottom)&&(t.action={name:"resize",edges:pe})}else{var ye=G.axis!=="y"&&H.x>C.right-Va.defaultMargin,Qe=G.axis!=="x"&&H.y>C.bottom-Va.defaultMargin;(ye||Qe)&&(t.action={name:"resize",axes:(ye?"x":"")+(Qe?"y":"")})}return!t.action&&void 0}}}},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor:function(t){var i=t.edges,p=t.axis,g=t.name,C=Va.cursors,L=null;if(p)L=C[g+p];else if(i){for(var H="",G=0,pe=["top","bottom","left","right"];G<pe.length;G++){var Me=pe[G];i[Me]&&(H+=Me)}L=C[H]}return L},filterEventType:function(t){return t.search("resize")===0},defaultMargin:null},je=Va,xe={id:"actions",install:function(t){t.usePlugin(tl),t.usePlugin(je),t.usePlugin(Ee),t.usePlugin(Na)}},Ze=0,Je={request:function(t){return ml(t)},cancel:function(t){return Fe(t)},init:function(t){if(ml=t.requestAnimationFrame,Fe=t.cancelAnimationFrame,!ml)for(var i=["ms","moz","webkit","o"],p=0;p<i.length;p++){var g=i[p];ml=t["".concat(g,"RequestAnimationFrame")],Fe=t["".concat(g,"CancelAnimationFrame")]||t["".concat(g,"CancelRequestAnimationFrame")]}ml=ml&&ml.bind(t),Fe=Fe&&Fe.bind(t),ml||(ml=function(C){var L=Date.now(),H=Math.max(0,16-(L-Ze)),G=t.setTimeout(function(){C(L+H)},H);return Ze=L+H,G},Fe=function(C){return clearTimeout(C)})}},ea={defaults:{enabled:!1,margin:60,container:null,speed:300},now:Date.now,interaction:null,i:0,x:0,y:0,isScrolling:!1,prevTime:0,margin:0,speed:0,start:function(t){ea.isScrolling=!0,Je.cancel(ea.i),t.autoScroll=ea,ea.interaction=t,ea.prevTime=ea.now(),ea.i=Je.request(ea.scroll)},stop:function(){ea.isScrolling=!1,ea.interaction&&(ea.interaction.autoScroll=null),Je.cancel(ea.i)},scroll:function(){var t=ea.interaction,i=t.interactable,p=t.element,g=t.prepared.name,C=i.options[g].autoScroll,L=q(C.container,i,p),H=ea.now(),G=(H-ea.prevTime)/1e3,pe=C.speed*G;if(pe>=1){var Me={x:ea.x*pe,y:ea.y*pe};if(Me.x||Me.y){var ye=ra(L);_.window(L)?L.scrollBy(Me.x,Me.y):L&&(L.scrollLeft+=Me.x,L.scrollTop+=Me.y);var Qe=ra(L),La={x:Qe.x-ye.x,y:Qe.y-ye.y};(La.x||La.y)&&i.fire({type:"autoscroll",target:p,interactable:i,delta:La,interaction:t,container:L})}ea.prevTime=H}ea.isScrolling&&(Je.cancel(ea.i),ea.i=Je.request(ea.scroll))},check:function(t,i){var p;return(p=t.options[i].autoScroll)==null?void 0:p.enabled},onInteractionMove:function(t){var i=t.interaction,p=t.pointer;if(i.interacting()&&ea.check(i.interactable,i.prepared.name))if(i.simulation)ea.x=ea.y=0;else{var g,C,L,H,G=i.interactable,pe=i.element,Me=i.prepared.name,ye=G.options[Me].autoScroll,Qe=q(ye.container,G,pe);if(_.window(Qe))H=p.clientX<ea.margin,g=p.clientY<ea.margin,C=p.clientX>Qe.innerWidth-ea.margin,L=p.clientY>Qe.innerHeight-ea.margin;else{var La=Ne(Qe);H=p.clientX<La.left+ea.margin,g=p.clientY<La.top+ea.margin,C=p.clientX>La.right-ea.margin,L=p.clientY>La.bottom-ea.margin}ea.x=C?1:H?-1:0,ea.y=L?1:g?-1:0,ea.isScrolling||(ea.margin=ye.margin,ea.speed=ye.speed,ea.start(i))}}};function q(t,i,p){return(_.string(t)?la(t,i,p):t)||$(p)}function ra(t){return _.window(t)&&(t=window.document.body),{x:t.scrollLeft,y:t.scrollTop}}var ya={id:"auto-scroll",install:function(t){var i=t.defaults,p=t.actions;t.autoScroll=ea,ea.now=function(){return t.now()},p.phaselessTypes.autoscroll=!0,i.perAction.autoScroll=ea.defaults},listeners:{"interactions:new":function(t){t.interaction.autoScroll=null},"interactions:destroy":function(t){t.interaction.autoScroll=null,ea.stop(),ea.interaction&&(ea.interaction=null)},"interactions:stop":ea.stop,"interactions:action-move":function(t){return ea.onInteractionMove(t)}}},we=ya;function Se(t,i){var p=!1;return function(){return p||(Y.console.warn(i),p=!0),t.apply(this,arguments)}}function qa(t,i){return t.name=i.name,t.axis=i.axis,t.edges=i.edges,t}function fe(t){return _.bool(t)?(this.options.styleCursor=t,this):t===null?(delete this.options.styleCursor,this):this.options.styleCursor}function fl(t){return _.func(t)?(this.options.actionChecker=t,this):t===null?(delete this.options.actionChecker,this):this.options.actionChecker}var Qa={id:"auto-start/interactableMethods",install:function(t){var i=t.Interactable;i.prototype.getAction=function(p,g,C,L){var H=function(G,pe,Me,ye,Qe){var La=G.getRect(ye),ol=pe.buttons||{0:1,1:4,3:8,4:16}[pe.button],al={action:null,interactable:G,interaction:Me,element:ye,rect:La,buttons:ol};return Qe.fire("auto-start:check",al),al.action}(this,g,C,L,t);return this.options.actionChecker?this.options.actionChecker(p,g,H,this,L,C):H},i.prototype.ignoreFrom=Se(function(p){return this._backCompatOption("ignoreFrom",p)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),i.prototype.allowFrom=Se(function(p){return this._backCompatOption("allowFrom",p)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),i.prototype.actionChecker=fl,i.prototype.styleCursor=fe}};function _l(t,i,p,g,C){return i.testIgnoreAllow(i.options[t.name],p,g)&&i.options[t.name].enabled&&ul(i,p,t,C)?t:null}function Ha(t,i,p,g,C,L,H){for(var G=0,pe=g.length;G<pe;G++){var Me=g[G],ye=C[G],Qe=Me.getAction(i,p,t,ye);if(Qe){var La=_l(Qe,Me,ye,L,H);if(La)return{action:La,interactable:Me,element:ye}}}return{action:null,interactable:null,element:null}}function il(t,i,p,g,C){var L=[],H=[],G=g;function pe(ye){L.push(ye),H.push(G)}for(;_.element(G);){L=[],H=[],C.interactables.forEachMatch(G,pe);var Me=Ha(t,i,p,L,H,g,C);if(Me.action&&!Me.interactable.options[Me.action.name].manualStart)return Me;G=Ta(G)}return{action:null,interactable:null,element:null}}function Ia(t,i,p){var g=i.action,C=i.interactable,L=i.element;g=g||{name:null},t.interactable=C,t.element=L,qa(t.prepared,g),t.rect=C&&g.name?C.getRect(L):null,Kl(t,p),p.fire("autoStart:prepared",{interaction:t})}function ul(t,i,p,g){var C=t.options,L=C[p.name].max,H=C[p.name].maxPerElement,G=g.autoStart.maxInteractions,pe=0,Me=0,ye=0;if(!(L&&H&&G))return!1;for(var Qe=0,La=g.interactions.list;Qe<La.length;Qe++){var ol=La[Qe],al=ol.prepared.name;if(ol.interacting()&&(++pe>=G||ol.interactable===t&&((Me+=al===p.name?1:0)>=L||ol.element===i&&(ye++,al===p.name&&ye>=H))))return!1}return G>0}function Ja(t,i){return _.number(t)?(i.autoStart.maxInteractions=t,this):i.autoStart.maxInteractions}function Wl(t,i,p){var g=p.autoStart.cursorElement;g&&g!==t&&(g.style.cursor=""),t.ownerDocument.documentElement.style.cursor=i,t.style.cursor=i,p.autoStart.cursorElement=i?t:null}function Kl(t,i){var p=t.interactable,g=t.element,C=t.prepared;if(t.pointerType==="mouse"&&p&&p.options.styleCursor){var L="";if(C.name){var H=p.options[C.name].cursorChecker;L=_.func(H)?H(C,p,g,t._interacting):i.actions.map[C.name].getCursor(C)}Wl(t.element,L||"",i)}else i.autoStart.cursorElement&&Wl(i.autoStart.cursorElement,"",i)}var $l={id:"auto-start/base",before:["actions"],install:function(t){var i=t.interactStatic,p=t.defaults;t.usePlugin(Qa),p.base.actionChecker=null,p.base.styleCursor=!0,ee(p.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),i.maxInteractions=function(g){return Ja(g,t)},t.autoStart={maxInteractions:1/0,withinInteractionLimit:ul,cursorElement:null}},listeners:{"interactions:down":function(t,i){var p=t.interaction,g=t.pointer,C=t.event,L=t.eventTarget;p.interacting()||Ia(p,il(p,g,C,L,i),i)},"interactions:move":function(t,i){(function(p,g){var C=p.interaction,L=p.pointer,H=p.event,G=p.eventTarget;C.pointerType!=="mouse"||C.pointerIsDown||C.interacting()||Ia(C,il(C,L,H,G,g),g)})(t,i),function(p,g){var C=p.interaction;if(C.pointerIsDown&&!C.interacting()&&C.pointerWasMoved&&C.prepared.name){g.fire("autoStart:before-start",p);var L=C.interactable,H=C.prepared.name;H&&L&&(L.options[H].manualStart||!ul(L,C.element,C.prepared,g)?C.stop():(C.start(C.prepared,L,C.element),Kl(C,g)))}}(t,i)},"interactions:stop":function(t,i){var p=t.interaction,g=p.interactable;g&&g.options.styleCursor&&Wl(p.element,"",i)}},maxInteractions:Ja,withinInteractionLimit:ul,validateAction:_l},Fl=$l,gr={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":function(t,i){var p=t.interaction,g=t.eventTarget,C=t.dx,L=t.dy;if(p.prepared.name==="drag"){var H=Math.abs(C),G=Math.abs(L),pe=p.interactable.options.drag,Me=pe.startAxis,ye=H>G?"x":H<G?"y":"xy";if(p.prepared.axis=pe.lockAxis==="start"?ye[0]:pe.lockAxis,ye!=="xy"&&Me!=="xy"&&Me!==ye){p.prepared.name=null;for(var Qe=g,La=function(al){if(al!==p.interactable){var sl=p.interactable.options.drag;if(!sl.manualStart&&al.testIgnoreAllow(sl,Qe,g)){var Cl=al.getAction(p.downPointer,p.downEvent,p,Qe);if(Cl&&Cl.name==="drag"&&function(cl,Bl){if(!Bl)return!1;var Ol=Bl.options.drag.startAxis;return cl==="xy"||Ol==="xy"||Ol===cl}(ye,al)&&Fl.validateAction(Cl,al,Qe,g,i))return al}}};_.element(Qe);){var ol=i.interactables.forEachMatch(Qe,La);if(ol){p.prepared.name="drag",p.interactable=ol,p.element=Qe;break}Qe=Ta(Qe)}}}}}};function rr(t){var i=t.prepared&&t.prepared.name;if(!i)return null;var p=t.interactable.options;return p[i].hold||p[i].delay}var kr={id:"auto-start/hold",install:function(t){var i=t.defaults;t.usePlugin(Fl),i.perAction.hold=0,i.perAction.delay=0},listeners:{"interactions:new":function(t){t.interaction.autoStartHoldTimer=null},"autoStart:prepared":function(t){var i=t.interaction,p=rr(i);p>0&&(i.autoStartHoldTimer=setTimeout(function(){i.start(i.prepared,i.interactable,i.element)},p))},"interactions:move":function(t){var i=t.interaction,p=t.duplicate;i.autoStartHoldTimer&&i.pointerWasMoved&&!p&&(clearTimeout(i.autoStartHoldTimer),i.autoStartHoldTimer=null)},"autoStart:before-start":function(t){var i=t.interaction;rr(i)>0&&(i.prepared.name=null)}},getHoldDuration:rr},wr=kr,Er={id:"auto-start",install:function(t){t.usePlugin(Fl),t.usePlugin(wr),t.usePlugin(gr)}},un=function(t){return/^(always|never|auto)$/.test(t)?(this.options.preventDefault=t,this):_.bool(t)?(this.options.preventDefault=t?"always":"never",this):this.options.preventDefault};function Jr(t){var i=t.interaction,p=t.event;i.interactable&&i.interactable.checkAndPreventDefault(p)}var dn={id:"core/interactablePreventDefault",install:function(t){var i=t.Interactable;i.prototype.preventDefault=un,i.prototype.checkAndPreventDefault=function(p){return function(g,C,L){var H=g.options.preventDefault;if(H!=="never")if(H!=="always"){if(C.events.supportsPassive&&/^touch(start|move)$/.test(L.type)){var G=$(L.target).document,pe=C.getDocOptions(G);if(!pe||!pe.events||pe.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(L.type)||_.element(L.target)&&oe(L.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||L.preventDefault()}else L.preventDefault()}(this,t,p)},t.interactions.docEvents.push({type:"dragstart",listener:function(p){for(var g=0,C=t.interactions.list;g<C.length;g++){var L=C[g];if(L.element&&(L.element===p.target||de(L.element,p.target)))return void L.interactable.checkAndPreventDefault(p)}}})},listeners:["down","move","up","cancel"].reduce(function(t,i){return t["interactions:".concat(i)]=Jr,t},{})};function Xr(t,i){if(i.phaselessTypes[t])return!0;for(var p in i.map)if(t.indexOf(p)===0&&t.substr(p.length)in i.phases)return!0;return!1}function qr(t){var i={};for(var p in t){var g=t[p];_.plainObject(g)?i[p]=qr(g):_.array(g)?i[p]=Ce(g):i[p]=g}return i}var pn=function(){function t(i){c(this,t),this.states=[],this.startOffset={left:0,right:0,top:0,bottom:0},this.startDelta=void 0,this.result=void 0,this.endResult=void 0,this.startEdges=void 0,this.edges=void 0,this.interaction=void 0,this.interaction=i,this.result=on(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}return f(t,[{key:"start",value:function(i,p){var g,C,L=i.phase,H=this.interaction,G=function(Me){var ye=Me.interactable.options[Me.prepared.name],Qe=ye.modifiers;return Qe&&Qe.length?Qe:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(function(La){var ol=ye[La];return ol&&ol.enabled&&{options:ol,methods:ol._methods}}).filter(function(La){return!!La})}(H);this.prepareStates(G),this.startEdges=ee({},H.edges),this.edges=ee({},this.startEdges),this.startOffset=(g=H.rect,C=p,g?{left:C.x-g.left,top:C.y-g.top,right:g.right-C.x,bottom:g.bottom-C.y}:{left:0,top:0,right:0,bottom:0}),this.startDelta={x:0,y:0};var pe=this.fillArg({phase:L,pageCoords:p,preEnd:!1});return this.result=on(),this.startAll(pe),this.result=this.setAll(pe)}},{key:"fillArg",value:function(i){var p=this.interaction;return i.interaction=p,i.interactable=p.interactable,i.element=p.element,i.rect||(i.rect=p.rect),i.edges||(i.edges=this.startEdges),i.startOffset=this.startOffset,i}},{key:"startAll",value:function(i){for(var p=0,g=this.states;p<g.length;p++){var C=g[p];C.methods.start&&(i.state=C,C.methods.start(i))}}},{key:"setAll",value:function(i){var p=i.phase,g=i.preEnd,C=i.skipModifiers,L=i.rect,H=i.edges;i.coords=ee({},i.pageCoords),i.rect=ee({},L),i.edges=ee({},H);for(var G=C?this.states.slice(C):this.states,pe=on(i.coords,i.rect),Me=0;Me<G.length;Me++){var ye,Qe=G[Me],La=Qe.options,ol=ee({},i.coords),al=null;(ye=Qe.methods)!=null&&ye.set&&this.shouldDo(La,g,p)&&(i.state=Qe,al=Qe.methods.set(i),Te(i.edges,i.rect,{x:i.coords.x-ol.x,y:i.coords.y-ol.y})),pe.eventProps.push(al)}ee(this.edges,i.edges),pe.delta.x=i.coords.x-i.pageCoords.x,pe.delta.y=i.coords.y-i.pageCoords.y,pe.rectDelta.left=i.rect.left-L.left,pe.rectDelta.right=i.rect.right-L.right,pe.rectDelta.top=i.rect.top-L.top,pe.rectDelta.bottom=i.rect.bottom-L.bottom;var sl=this.result.coords,Cl=this.result.rect;if(sl&&Cl){var cl=pe.rect.left!==Cl.left||pe.rect.right!==Cl.right||pe.rect.top!==Cl.top||pe.rect.bottom!==Cl.bottom;pe.changed=cl||sl.x!==pe.coords.x||sl.y!==pe.coords.y}return pe}},{key:"applyToInteraction",value:function(i){var p=this.interaction,g=i.phase,C=p.coords.cur,L=p.coords.start,H=this.result,G=this.startDelta,pe=H.delta;g==="start"&&ee(this.startDelta,H.delta);for(var Me=0,ye=[[L,G],[C,pe]];Me<ye.length;Me++){var Qe=ye[Me],La=Qe[0],ol=Qe[1];La.page.x+=ol.x,La.page.y+=ol.y,La.client.x+=ol.x,La.client.y+=ol.y}var al=this.result.rectDelta,sl=i.rect||p.rect;sl.left+=al.left,sl.right+=al.right,sl.top+=al.top,sl.bottom+=al.bottom,sl.width=sl.right-sl.left,sl.height=sl.bottom-sl.top}},{key:"setAndApply",value:function(i){var p=this.interaction,g=i.phase,C=i.preEnd,L=i.skipModifiers,H=this.setAll(this.fillArg({preEnd:C,phase:g,pageCoords:i.modifiedCoords||p.coords.cur.page}));if(this.result=H,!H.changed&&(!L||L<this.states.length)&&p.interacting())return!1;if(i.modifiedCoords){var G=p.coords.cur.page,pe={x:i.modifiedCoords.x-G.x,y:i.modifiedCoords.y-G.y};H.coords.x+=pe.x,H.coords.y+=pe.y,H.delta.x+=pe.x,H.delta.y+=pe.y}this.applyToInteraction(i)}},{key:"beforeEnd",value:function(i){var p=i.interaction,g=i.event,C=this.states;if(C&&C.length){for(var L=!1,H=0;H<C.length;H++){var G=C[H];i.state=G;var pe=G.options,Me=G.methods,ye=Me.beforeEnd&&Me.beforeEnd(i);if(ye)return this.endResult=ye,!1;L=L||!L&&this.shouldDo(pe,!0,i.phase,!0)}L&&p.move({event:g,preEnd:!0})}}},{key:"stop",value:function(i){var p=i.interaction;if(this.states&&this.states.length){var g=ee({states:this.states,interactable:p.interactable,element:p.element,rect:null},i);this.fillArg(g);for(var C=0,L=this.states;C<L.length;C++){var H=L[C];g.state=H,H.methods.stop&&H.methods.stop(g)}this.states=null,this.endResult=null}}},{key:"prepareStates",value:function(i){this.states=[];for(var p=0;p<i.length;p++){var g=i[p],C=g.options,L=g.methods,H=g.name;this.states.push({options:C,methods:L,index:p,name:H})}return this.states}},{key:"restoreInteractionCoords",value:function(i){var p=i.interaction,g=p.coords,C=p.rect,L=p.modification;if(L.result){for(var H=L.startDelta,G=L.result,pe=G.delta,Me=G.rectDelta,ye=0,Qe=[[g.start,H],[g.cur,pe]];ye<Qe.length;ye++){var La=Qe[ye],ol=La[0],al=La[1];ol.page.x-=al.x,ol.page.y-=al.y,ol.client.x-=al.x,ol.client.y-=al.y}C.left-=Me.left,C.right-=Me.right,C.top-=Me.top,C.bottom-=Me.bottom}}},{key:"shouldDo",value:function(i,p,g,C){return!(!i||i.enabled===!1||C&&!i.endOnly||i.endOnly&&!p||g==="start"&&!i.setStart)}},{key:"copyFrom",value:function(i){this.startOffset=i.startOffset,this.startDelta=i.startDelta,this.startEdges=i.startEdges,this.edges=i.edges,this.states=i.states.map(function(p){return qr(p)}),this.result=on(ee({},i.result.coords),ee({},i.result.rect))}},{key:"destroy",value:function(){for(var i in this)this[i]=null}}]),t}();function on(t,i){return{rect:i,coords:t,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function Dr(t,i){var p=t.defaults,g={start:t.start,set:t.set,beforeEnd:t.beforeEnd,stop:t.stop},C=function(L){var H=L||{};for(var G in H.enabled=H.enabled!==!1,p)G in H||(H[G]=p[G]);var pe={options:H,methods:g,name:i,enable:function(){return H.enabled=!0,pe},disable:function(){return H.enabled=!1,pe}};return pe};return i&&typeof i=="string"&&(C._defaults=p,C._methods=g),C}function Zr(t){var i=t.iEvent,p=t.interaction.modification.result;p&&(i.modifiers=p.eventProps)}var Nr={id:"modifiers/base",before:["actions"],install:function(t){t.defaults.perAction.modifiers=[]},listeners:{"interactions:new":function(t){var i=t.interaction;i.modification=new pn(i)},"interactions:before-action-start":function(t){var i=t.interaction,p=t.interaction.modification;p.start(t,i.coords.start.page),i.edges=p.edges,p.applyToInteraction(t)},"interactions:before-action-move":function(t){var i=t.interaction,p=i.modification,g=p.setAndApply(t);return i.edges=p.edges,g},"interactions:before-action-end":function(t){var i=t.interaction,p=i.modification,g=p.beforeEnd(t);return i.edges=p.startEdges,g},"interactions:action-start":Zr,"interactions:action-move":Zr,"interactions:action-end":Zr,"interactions:after-action-start":function(t){return t.interaction.modification.restoreInteractionCoords(t)},"interactions:after-action-move":function(t){return t.interaction.modification.restoreInteractionCoords(t)},"interactions:stop":function(t){return t.interaction.modification.stop(t)}}},Il=Nr,Wr={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}},Br=function(t){m(p,t);var i=B(p);function p(g,C,L,H,G,pe,Me){var ye;c(this,p),(ye=i.call(this,g)).relatedTarget=null,ye.screenX=void 0,ye.screenY=void 0,ye.button=void 0,ye.buttons=void 0,ye.ctrlKey=void 0,ye.shiftKey=void 0,ye.altKey=void 0,ye.metaKey=void 0,ye.page=void 0,ye.client=void 0,ye.delta=void 0,ye.rect=void 0,ye.x0=void 0,ye.y0=void 0,ye.t0=void 0,ye.dt=void 0,ye.duration=void 0,ye.clientX0=void 0,ye.clientY0=void 0,ye.velocity=void 0,ye.speed=void 0,ye.swipe=void 0,ye.axes=void 0,ye.preEnd=void 0,G=G||g.element;var Qe=g.interactable,La=(Qe&&Qe.options||Wr).deltaSource,ol=Re(Qe,G,L),al=H==="start",sl=H==="end",Cl=al?E(ye):g.prevEvent,cl=al?g.coords.start:sl?{page:Cl.page,client:Cl.client,timeStamp:g.coords.cur.timeStamp}:g.coords.cur;return ye.page=ee({},cl.page),ye.client=ee({},cl.client),ye.rect=ee({},g.rect),ye.timeStamp=cl.timeStamp,sl||(ye.page.x-=ol.x,ye.page.y-=ol.y,ye.client.x-=ol.x,ye.client.y-=ol.y),ye.ctrlKey=C.ctrlKey,ye.altKey=C.altKey,ye.shiftKey=C.shiftKey,ye.metaKey=C.metaKey,ye.button=C.button,ye.buttons=C.buttons,ye.target=G,ye.currentTarget=G,ye.preEnd=pe,ye.type=Me||L+(H||""),ye.interactable=Qe,ye.t0=al?g.pointers[g.pointers.length-1].downTime:Cl.t0,ye.x0=g.coords.start.page.x-ol.x,ye.y0=g.coords.start.page.y-ol.y,ye.clientX0=g.coords.start.client.x-ol.x,ye.clientY0=g.coords.start.client.y-ol.y,ye.delta=al||sl?{x:0,y:0}:{x:ye[La].x-Cl[La].x,y:ye[La].y-Cl[La].y},ye.dt=g.coords.delta.timeStamp,ye.duration=ye.timeStamp-ye.t0,ye.velocity=ee({},g.coords.velocity[La]),ye.speed=Fa(ye.velocity.x,ye.velocity.y),ye.swipe=sl||H==="inertiastart"?ye.getSwipe():null,ye}return f(p,[{key:"getSwipe",value:function(){var g=this._interaction;if(g.prevEvent.speed<600||this.timeStamp-g.prevEvent.timeStamp>150)return null;var C=180*Math.atan2(g.prevEvent.velocityY,g.prevEvent.velocityX)/Math.PI;C<0&&(C+=360);var L=112.5<=C&&C<247.5,H=202.5<=C&&C<337.5;return{up:H,down:!H&&22.5<=C&&C<157.5,left:L,right:!L&&(292.5<=C||C<67.5),angle:C,speed:g.prevEvent.speed,velocity:{x:g.prevEvent.velocityX,y:g.prevEvent.velocityY}}}},{key:"preventDefault",value:function(){}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}}]),p}(va);Object.defineProperties(Br.prototype,{pageX:{get:function(){return this.page.x},set:function(t){this.page.x=t}},pageY:{get:function(){return this.page.y},set:function(t){this.page.y=t}},clientX:{get:function(){return this.client.x},set:function(t){this.client.x=t}},clientY:{get:function(){return this.client.y},set:function(t){this.client.y=t}},dx:{get:function(){return this.delta.x},set:function(t){this.delta.x=t}},dy:{get:function(){return this.delta.y},set:function(t){this.delta.y=t}},velocityX:{get:function(){return this.velocity.x},set:function(t){this.velocity.x=t}},velocityY:{get:function(){return this.velocity.y},set:function(t){this.velocity.y=t}}});var vn=f(function t(i,p,g,C,L){c(this,t),this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=i,this.pointer=p,this.event=g,this.downTime=C,this.downTarget=L}),io=function(t){return t.interactable="",t.element="",t.prepared="",t.pointerIsDown="",t.pointerWasMoved="",t._proxy="",t}({}),Kn=function(t){return t.start="",t.move="",t.end="",t.stop="",t.interacting="",t}({}),In=0,mn=function(){function t(i){var p=this,g=i.pointerType,C=i.scopeFire;c(this,t),this.interactable=null,this.element=null,this.rect=null,this._rects=void 0,this.edges=null,this._scopeFire=void 0,this.prepared={name:null,axis:null,edges:null},this.pointerType=void 0,this.pointers=[],this.downEvent=null,this.downPointer={},this._latestPointer={pointer:null,event:null,eventTarget:null},this.prevEvent=null,this.pointerIsDown=!1,this.pointerWasMoved=!1,this._interacting=!1,this._ending=!1,this._stopped=!0,this._proxy=void 0,this.simulation=null,this.doMove=Se(function(ye){this.move(ye)},"The interaction.doMove() method has been renamed to interaction.move()"),this.coords={start:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},prev:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},cur:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},delta:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},velocity:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0}},this._id=In++,this._scopeFire=C,this.pointerType=g;var L=this;this._proxy={};var H=function(ye){Object.defineProperty(p._proxy,ye,{get:function(){return L[ye]}})};for(var G in io)H(G);var pe=function(ye){Object.defineProperty(p._proxy,ye,{value:function(){return L[ye].apply(L,arguments)}})};for(var Me in Kn)pe(Me);this._scopeFire("interactions:new",{interaction:this})}return f(t,[{key:"pointerMoveTolerance",get:function(){return 1}},{key:"pointerDown",value:function(i,p,g){var C=this.updatePointer(i,p,g,!0),L=this.pointers[C];this._scopeFire("interactions:down",{pointer:i,event:p,eventTarget:g,pointerIndex:C,pointerInfo:L,type:"down",interaction:this})}},{key:"start",value:function(i,p,g){return!(this.interacting()||!this.pointerIsDown||this.pointers.length<(i.name==="gesture"?2:1)||!p.options[i.name].enabled)&&(qa(this.prepared,i),this.interactable=p,this.element=g,this.rect=p.getRect(g),this.edges=this.prepared.edges?ee({},this.prepared.edges):{left:!0,right:!0,top:!0,bottom:!0},this._stopped=!1,this._interacting=this._doPhase({interaction:this,event:this.downEvent,phase:"start"})&&!this._stopped,this._interacting)}},{key:"pointerMove",value:function(i,p,g){this.simulation||this.modification&&this.modification.endResult||this.updatePointer(i,p,g,!1);var C,L,H=this.coords.cur.page.x===this.coords.prev.page.x&&this.coords.cur.page.y===this.coords.prev.page.y&&this.coords.cur.client.x===this.coords.prev.client.x&&this.coords.cur.client.y===this.coords.prev.client.y;this.pointerIsDown&&!this.pointerWasMoved&&(C=this.coords.cur.client.x-this.coords.start.client.x,L=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=Fa(C,L)>this.pointerMoveTolerance);var G,pe,Me,ye=this.getPointerIndex(i),Qe={pointer:i,pointerIndex:ye,pointerInfo:this.pointers[ye],event:p,type:"move",eventTarget:g,dx:C,dy:L,duplicate:H,interaction:this};H||(G=this.coords.velocity,pe=this.coords.delta,Me=Math.max(pe.timeStamp/1e3,.001),G.page.x=pe.page.x/Me,G.page.y=pe.page.y/Me,G.client.x=pe.client.x/Me,G.client.y=pe.client.y/Me,G.timeStamp=Me),this._scopeFire("interactions:move",Qe),H||this.simulation||(this.interacting()&&(Qe.type=null,this.move(Qe)),this.pointerWasMoved&&J(this.coords.prev,this.coords.cur))}},{key:"move",value:function(i){i&&i.event||ie(this.coords.delta),(i=ee({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},i||{})).phase="move",this._doPhase(i)}},{key:"pointerUp",value:function(i,p,g,C){var L=this.getPointerIndex(i);L===-1&&(L=this.updatePointer(i,p,g,!1));var H=/cancel$/i.test(p.type)?"cancel":"up";this._scopeFire("interactions:".concat(H),{pointer:i,pointerIndex:L,pointerInfo:this.pointers[L],event:p,eventTarget:g,type:H,curEventTarget:C,interaction:this}),this.simulation||this.end(p),this.removePointer(i,p)}},{key:"documentBlur",value:function(i){this.end(i),this._scopeFire("interactions:blur",{event:i,type:"blur",interaction:this})}},{key:"end",value:function(i){var p;this._ending=!0,i=i||this._latestPointer.event,this.interacting()&&(p=this._doPhase({event:i,interaction:this,phase:"end"})),this._ending=!1,p===!0&&this.stop()}},{key:"currentAction",value:function(){return this._interacting?this.prepared.name:null}},{key:"interacting",value:function(){return this._interacting}},{key:"stop",value:function(){this._scopeFire("interactions:stop",{interaction:this}),this.interactable=this.element=null,this._interacting=!1,this._stopped=!0,this.prepared.name=this.prevEvent=null}},{key:"getPointerIndex",value:function(i){var p=Oe(i);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:Z(this.pointers,function(g){return g.id===p})}},{key:"getPointerInfo",value:function(i){return this.pointers[this.getPointerIndex(i)]}},{key:"updatePointer",value:function(i,p,g,C){var L,H,G,pe=Oe(i),Me=this.getPointerIndex(i),ye=this.pointers[Me];return C=C!==!1&&(C||/(down|start)$/i.test(p.type)),ye?ye.pointer=i:(ye=new vn(pe,i,p,null,null),Me=this.pointers.length,this.pointers.push(ye)),_e(this.coords.cur,this.pointers.map(function(Qe){return Qe.pointer}),this._now()),L=this.coords.delta,H=this.coords.prev,G=this.coords.cur,L.page.x=G.page.x-H.page.x,L.page.y=G.page.y-H.page.y,L.client.x=G.client.x-H.client.x,L.client.y=G.client.y-H.client.y,L.timeStamp=G.timeStamp-H.timeStamp,C&&(this.pointerIsDown=!0,ye.downTime=this.coords.cur.timeStamp,ye.downTarget=g,F(this.downPointer,i),this.interacting()||(J(this.coords.start,this.coords.cur),J(this.coords.prev,this.coords.cur),this.downEvent=p,this.pointerWasMoved=!1)),this._updateLatestPointer(i,p,g),this._scopeFire("interactions:update-pointer",{pointer:i,event:p,eventTarget:g,down:C,pointerInfo:ye,pointerIndex:Me,interaction:this}),Me}},{key:"removePointer",value:function(i,p){var g=this.getPointerIndex(i);if(g!==-1){var C=this.pointers[g];this._scopeFire("interactions:remove-pointer",{pointer:i,event:p,eventTarget:null,pointerIndex:g,pointerInfo:C,interaction:this}),this.pointers.splice(g,1),this.pointerIsDown=!1}}},{key:"_updateLatestPointer",value:function(i,p,g){this._latestPointer.pointer=i,this._latestPointer.event=p,this._latestPointer.eventTarget=g}},{key:"destroy",value:function(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}},{key:"_createPreparedEvent",value:function(i,p,g,C){return new Br(this,i,this.prepared.name,p,this.element,g,C)}},{key:"_fireEvent",value:function(i){var p;(p=this.interactable)==null||p.fire(i),(!this.prevEvent||i.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=i)}},{key:"_doPhase",value:function(i){var p=i.event,g=i.phase,C=i.preEnd,L=i.type,H=this.rect;if(H&&g==="move"&&(Te(this.edges,H,this.coords.delta[this.interactable.options.deltaSource]),H.width=H.right-H.left,H.height=H.bottom-H.top),this._scopeFire("interactions:before-action-".concat(g),i)===!1)return!1;var G=i.iEvent=this._createPreparedEvent(p,g,C,L);return this._scopeFire("interactions:action-".concat(g),i),g==="start"&&(this.prevEvent=G),this._fireEvent(G),this._scopeFire("interactions:after-action-".concat(g),i),!0}},{key:"_now",value:function(){return Date.now()}}]),t}();function Xl(t){xr(t.interaction)}function xr(t){if(!function(p){return!(!p.offset.pending.x&&!p.offset.pending.y)}(t))return!1;var i=t.offset.pending;return Hl(t.coords.cur,i),Hl(t.coords.delta,i),Te(t.edges,t.rect,i),i.x=0,i.y=0,!0}function Rl(t){var i=t.x,p=t.y;this.offset.pending.x+=i,this.offset.pending.y+=p,this.offset.total.x+=i,this.offset.total.y+=p}function Hl(t,i){var p=t.page,g=t.client,C=i.x,L=i.y;p.x+=C,p.y+=L,g.x+=C,g.y+=L}Kn.offsetBy="";var Ml={id:"offset",before:["modifiers","pointer-events","actions","inertia"],install:function(t){t.Interaction.prototype.offsetBy=Rl},listeners:{"interactions:new":function(t){t.interaction.offset={total:{x:0,y:0},pending:{x:0,y:0}}},"interactions:update-pointer":function(t){return function(i){i.pointerIsDown&&(Hl(i.coords.cur,i.offset.total),i.offset.pending.x=0,i.offset.pending.y=0)}(t.interaction)},"interactions:before-action-start":Xl,"interactions:before-action-move":Xl,"interactions:before-action-end":function(t){var i=t.interaction;if(xr(i))return i.move({offset:!0}),i.end(),!1},"interactions:stop":function(t){var i=t.interaction;i.offset.total.x=0,i.offset.total.y=0,i.offset.pending.x=0,i.offset.pending.y=0}}},cr=Ml,ar=function(){function t(i){c(this,t),this.active=!1,this.isModified=!1,this.smoothEnd=!1,this.allowResume=!1,this.modification=void 0,this.modifierCount=0,this.modifierArg=void 0,this.startCoords=void 0,this.t0=0,this.v0=0,this.te=0,this.targetOffset=void 0,this.modifiedOffset=void 0,this.currentOffset=void 0,this.lambda_v0=0,this.one_ve_v0=0,this.timeout=void 0,this.interaction=void 0,this.interaction=i}return f(t,[{key:"start",value:function(i){var p=this.interaction,g=Pl(p);if(!g||!g.enabled)return!1;var C=p.coords.velocity.client,L=Fa(C.x,C.y),H=this.modification||(this.modification=new pn(p));if(H.copyFrom(p.modification),this.t0=p._now(),this.allowResume=g.allowResume,this.v0=L,this.currentOffset={x:0,y:0},this.startCoords=p.coords.cur.page,this.modifierArg=H.fillArg({pageCoords:this.startCoords,preEnd:!0,phase:"inertiastart"}),this.t0-p.coords.cur.timeStamp<50&&L>g.minSpeed&&L>g.endSpeed)this.startInertia();else{if(H.result=H.setAll(this.modifierArg),!H.result.changed)return!1;this.startSmoothEnd()}return p.modification.result.rect=null,p.offsetBy(this.targetOffset),p._doPhase({interaction:p,event:i,phase:"inertiastart"}),p.offsetBy({x:-this.targetOffset.x,y:-this.targetOffset.y}),p.modification.result.rect=null,this.active=!0,p.simulation=this,!0}},{key:"startInertia",value:function(){var i=this,p=this.interaction.coords.velocity.client,g=Pl(this.interaction),C=g.resistance,L=-Math.log(g.endSpeed/this.v0)/C;this.targetOffset={x:(p.x-L)/C,y:(p.y-L)/C},this.te=L,this.lambda_v0=C/this.v0,this.one_ve_v0=1-g.endSpeed/this.v0;var H=this.modification,G=this.modifierArg;G.pageCoords={x:this.startCoords.x+this.targetOffset.x,y:this.startCoords.y+this.targetOffset.y},H.result=H.setAll(G),H.result.changed&&(this.isModified=!0,this.modifiedOffset={x:this.targetOffset.x+H.result.delta.x,y:this.targetOffset.y+H.result.delta.y}),this.onNextFrame(function(){return i.inertiaTick()})}},{key:"startSmoothEnd",value:function(){var i=this;this.smoothEnd=!0,this.isModified=!0,this.targetOffset={x:this.modification.result.delta.x,y:this.modification.result.delta.y},this.onNextFrame(function(){return i.smoothEndTick()})}},{key:"onNextFrame",value:function(i){var p=this;this.timeout=Je.request(function(){p.active&&i()})}},{key:"inertiaTick",value:function(){var i,p,g,C,L,H,G,pe=this,Me=this.interaction,ye=Pl(Me).resistance,Qe=(Me._now()-this.t0)/1e3;if(Qe<this.te){var La,ol=1-(Math.exp(-ye*Qe)-this.lambda_v0)/this.one_ve_v0;this.isModified?(i=0,p=0,g=this.targetOffset.x,C=this.targetOffset.y,L=this.modifiedOffset.x,H=this.modifiedOffset.y,La={x:Mr(G=ol,i,g,L),y:Mr(G,p,C,H)}):La={x:this.targetOffset.x*ol,y:this.targetOffset.y*ol};var al={x:La.x-this.currentOffset.x,y:La.y-this.currentOffset.y};this.currentOffset.x+=al.x,this.currentOffset.y+=al.y,Me.offsetBy(al),Me.move(),this.onNextFrame(function(){return pe.inertiaTick()})}else Me.offsetBy({x:this.modifiedOffset.x-this.currentOffset.x,y:this.modifiedOffset.y-this.currentOffset.y}),this.end()}},{key:"smoothEndTick",value:function(){var i=this,p=this.interaction,g=p._now()-this.t0,C=Pl(p).smoothEndDuration;if(g<C){var L={x:yn(g,0,this.targetOffset.x,C),y:yn(g,0,this.targetOffset.y,C)},H={x:L.x-this.currentOffset.x,y:L.y-this.currentOffset.y};this.currentOffset.x+=H.x,this.currentOffset.y+=H.y,p.offsetBy(H),p.move({skipModifiers:this.modifierCount}),this.onNextFrame(function(){return i.smoothEndTick()})}else p.offsetBy({x:this.targetOffset.x-this.currentOffset.x,y:this.targetOffset.y-this.currentOffset.y}),this.end()}},{key:"resume",value:function(i){var p=i.pointer,g=i.event,C=i.eventTarget,L=this.interaction;L.offsetBy({x:-this.currentOffset.x,y:-this.currentOffset.y}),L.updatePointer(p,g,C,!0),L._doPhase({interaction:L,event:g,phase:"resume"}),J(L.coords.prev,L.coords.cur),this.stop()}},{key:"end",value:function(){this.interaction.move(),this.interaction.end(),this.stop()}},{key:"stop",value:function(){this.active=this.smoothEnd=!1,this.interaction.simulation=null,Je.cancel(this.timeout)}}]),t}();function Pl(t){var i=t.interactable,p=t.prepared;return i&&i.options&&p.name&&i.options[p.name].inertia}var zr={id:"inertia",before:["modifiers","actions"],install:function(t){var i=t.defaults;t.usePlugin(cr),t.usePlugin(Il),t.actions.phases.inertiastart=!0,t.actions.phases.resume=!0,i.perAction.inertia={enabled:!1,resistance:10,minSpeed:100,endSpeed:10,allowResume:!0,smoothEndDuration:300}},listeners:{"interactions:new":function(t){var i=t.interaction;i.inertia=new ar(i)},"interactions:before-action-end":function(t){var i=t.interaction,p=t.event;return(!i._interacting||i.simulation||!i.inertia.start(p))&&null},"interactions:down":function(t){var i=t.interaction,p=t.eventTarget,g=i.inertia;if(g.active)for(var C=p;_.element(C);){if(C===i.element){g.resume(t);break}C=Ta(C)}},"interactions:stop":function(t){var i=t.interaction.inertia;i.active&&i.stop()},"interactions:before-action-resume":function(t){var i=t.interaction.modification;i.stop(t),i.start(t,t.interaction.coords.cur.page),i.applyToInteraction(t)},"interactions:before-action-inertiastart":function(t){return t.interaction.modification.setAndApply(t)},"interactions:action-resume":Zr,"interactions:action-inertiastart":Zr,"interactions:after-action-inertiastart":function(t){return t.interaction.modification.restoreInteractionCoords(t)},"interactions:after-action-resume":function(t){return t.interaction.modification.restoreInteractionCoords(t)}}};function Mr(t,i,p,g){var C=1-t;return C*C*i+2*C*t*p+t*t*g}function yn(t,i,p,g){return-p*(t/=g)*(t-2)+i}var Qr=zr;function Yn(t,i){for(var p=0;p<i.length;p++){var g=i[p];if(t.immediatePropagationStopped)break;g(t)}}var Sn=function(){function t(i){c(this,t),this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=ee({},i||{})}return f(t,[{key:"fire",value:function(i){var p,g=this.global;(p=this.types[i.type])&&Yn(i,p),!i.propagationStopped&&g&&(p=g[i.type])&&Yn(i,p)}},{key:"on",value:function(i,p){var g=Ge(i,p);for(i in g)this.types[i]=re(this.types[i]||[],g[i])}},{key:"off",value:function(i,p){var g=Ge(i,p);for(i in g){var C=this.types[i];if(C&&C.length)for(var L=0,H=g[i];L<H.length;L++){var G=H[L],pe=C.indexOf(G);pe!==-1&&C.splice(pe,1)}}}},{key:"getRect",value:function(i){return null}}]),t}(),Gn=function(){function t(i){c(this,t),this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=i,F(this,i)}return f(t,[{key:"preventOriginalDefault",value:function(){this.originalEvent.preventDefault()}},{key:"stopPropagation",value:function(){this.originalEvent.stopPropagation()}},{key:"stopImmediatePropagation",value:function(){this.originalEvent.stopImmediatePropagation()}}]),t}();function gn(t){return _.object(t)?{capture:!!t.capture,passive:!!t.passive}:{capture:!!t,passive:!1}}function Dn(t,i){return t===i||(typeof t=="boolean"?!!i.capture===t&&!i.passive:!!t.capture==!!i.capture&&!!t.passive==!!i.passive)}var Ln={id:"events",install:function(t){var i,p=[],g={},C=[],L={add:H,remove:G,addDelegate:function(ye,Qe,La,ol,al){var sl=gn(al);if(!g[La]){g[La]=[];for(var Cl=0;Cl<C.length;Cl++){var cl=C[Cl];H(cl,La,pe),H(cl,La,Me,!0)}}var Bl=g[La],Ol=fa(Bl,function(Yl){return Yl.selector===ye&&Yl.context===Qe});Ol||(Ol={selector:ye,context:Qe,listeners:[]},Bl.push(Ol)),Ol.listeners.push({func:ol,options:sl})},removeDelegate:function(ye,Qe,La,ol,al){var sl,Cl=gn(al),cl=g[La],Bl=!1;if(cl)for(sl=cl.length-1;sl>=0;sl--){var Ol=cl[sl];if(Ol.selector===ye&&Ol.context===Qe){for(var Yl=Ol.listeners,Nl=Yl.length-1;Nl>=0;Nl--){var jl=Yl[Nl];if(jl.func===ol&&Dn(jl.options,Cl)){Yl.splice(Nl,1),Yl.length||(cl.splice(sl,1),G(Qe,La,pe),G(Qe,La,Me,!0)),Bl=!0;break}}if(Bl)break}}},delegateListener:pe,delegateUseCapture:Me,delegatedEvents:g,documents:C,targets:p,supportsOptions:!1,supportsPassive:!1};function H(ye,Qe,La,ol){if(ye.addEventListener){var al=gn(ol),sl=fa(p,function(Cl){return Cl.eventTarget===ye});sl||(sl={eventTarget:ye,events:{}},p.push(sl)),sl.events[Qe]||(sl.events[Qe]=[]),fa(sl.events[Qe],function(Cl){return Cl.func===La&&Dn(Cl.options,al)})||(ye.addEventListener(Qe,La,L.supportsOptions?al:al.capture),sl.events[Qe].push({func:La,options:al}))}}function G(ye,Qe,La,ol){if(ye.addEventListener&&ye.removeEventListener){var al=Z(p,function(Ir){return Ir.eventTarget===ye}),sl=p[al];if(sl&&sl.events)if(Qe!=="all"){var Cl=!1,cl=sl.events[Qe];if(cl){if(La==="all"){for(var Bl=cl.length-1;Bl>=0;Bl--){var Ol=cl[Bl];G(ye,Qe,Ol.func,Ol.options)}return}for(var Yl=gn(ol),Nl=0;Nl<cl.length;Nl++){var jl=cl[Nl];if(jl.func===La&&Dn(jl.options,Yl)){ye.removeEventListener(Qe,La,L.supportsOptions?Yl:Yl.capture),cl.splice(Nl,1),cl.length===0&&(delete sl.events[Qe],Cl=!0);break}}}Cl&&!Object.keys(sl.events).length&&p.splice(al,1)}else for(Qe in sl.events)sl.events.hasOwnProperty(Qe)&&G(ye,Qe,"all")}}function pe(ye,Qe){for(var La=gn(Qe),ol=new Gn(ye),al=g[ye.type],sl=Le(ye)[0],Cl=sl;_.element(Cl);){for(var cl=0;cl<al.length;cl++){var Bl=al[cl],Ol=Bl.selector,Yl=Bl.context;if(oe(Cl,Ol)&&de(Yl,sl)&&de(Yl,Cl)){var Nl=Bl.listeners;ol.currentTarget=Cl;for(var jl=0;jl<Nl.length;jl++){var Ir=Nl[jl];Dn(Ir.options,La)&&Ir.func(ol)}}}Cl=Ta(Cl)}}function Me(ye){return pe(ye,!0)}return(i=t.document)==null||i.createElement("div").addEventListener("test",null,{get capture(){return L.supportsOptions=!0},get passive(){return L.supportsPassive=!0}}),t.events=L,L}},Kr={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search:function(t){for(var i=0,p=Kr.methodOrder;i<p.length;i++){var g=p[i],C=Kr[g](t);if(C)return C}return null},simulationResume:function(t){var i=t.pointerType,p=t.eventType,g=t.eventTarget,C=t.scope;if(!/down|start/i.test(p))return null;for(var L=0,H=C.interactions.list;L<H.length;L++){var G=H[L],pe=g;if(G.simulation&&G.simulation.allowResume&&G.pointerType===i)for(;pe;){if(pe===G.element)return G;pe=Ta(pe)}}return null},mouseOrPen:function(t){var i,p=t.pointerId,g=t.pointerType,C=t.eventType,L=t.scope;if(g!=="mouse"&&g!=="pen")return null;for(var H=0,G=L.interactions.list;H<G.length;H++){var pe=G[H];if(pe.pointerType===g){if(pe.simulation&&!Nn(pe,p))continue;if(pe.interacting())return pe;i||(i=pe)}}if(i)return i;for(var Me=0,ye=L.interactions.list;Me<ye.length;Me++){var Qe=ye[Me];if(!(Qe.pointerType!==g||/down/i.test(C)&&Qe.simulation))return Qe}return null},hasPointer:function(t){for(var i=t.pointerId,p=0,g=t.scope.interactions.list;p<g.length;p++){var C=g[p];if(Nn(C,i))return C}return null},idle:function(t){for(var i=t.pointerType,p=0,g=t.scope.interactions.list;p<g.length;p++){var C=g[p];if(C.pointers.length===1){var L=C.interactable;if(L&&(!L.options.gesture||!L.options.gesture.enabled))continue}else if(C.pointers.length>=2)continue;if(!C.interacting()&&i===C.pointerType)return C}return null}};function Nn(t,i){return t.pointers.some(function(p){return p.id===i})}var bn=Kr,Pr=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function $n(t,i){return function(p){var g=i.interactions.list,C=xa(p),L=Le(p),H=L[0],G=L[1],pe=[];if(/^touch/.test(p.type)){i.prevTouchTime=i.now();for(var Me=0,ye=p.changedTouches;Me<ye.length;Me++){var Qe=ye[Me],La={pointer:Qe,pointerId:Oe(Qe),pointerType:C,eventType:p.type,eventTarget:H,curEventTarget:G,scope:i},ol=fn(La);pe.push([La.pointer,La.eventTarget,La.curEventTarget,ol])}}else{var al=!1;if(!X.supportsPointerEvent&&/mouse/.test(p.type)){for(var sl=0;sl<g.length&&!al;sl++)al=g[sl].pointerType!=="mouse"&&g[sl].pointerIsDown;al=al||i.now()-i.prevTouchTime<500||p.timeStamp===0}if(!al){var Cl={pointer:p,pointerId:Oe(p),pointerType:C,eventType:p.type,curEventTarget:G,eventTarget:H,scope:i},cl=fn(Cl);pe.push([Cl.pointer,Cl.eventTarget,Cl.curEventTarget,cl])}}for(var Bl=0;Bl<pe.length;Bl++){var Ol=pe[Bl],Yl=Ol[0],Nl=Ol[1],jl=Ol[2];Ol[3][t](Yl,p,Nl,jl)}}}function fn(t){var i=t.pointerType,p=t.scope,g={interaction:bn.search(t),searchDetails:t};return p.fire("interactions:find",g),g.interaction||p.interactions.new({pointerType:i})}function No(t,i){var p=t.doc,g=t.scope,C=t.options,L=g.interactions.docEvents,H=g.events,G=H[i];for(var pe in g.browser.isIOS&&!C.events&&(C.events={passive:!1}),H.delegatedEvents)G(p,pe,H.delegateListener),G(p,pe,H.delegateUseCapture,!0);for(var Me=C&&C.events,ye=0;ye<L.length;ye++){var Qe=L[ye];G(p,Qe.type,Qe.listener,Me)}}var Ai={id:"core/interactions",install:function(t){for(var i={},p=0;p<Pr.length;p++){var g=Pr[p];i[g]=$n(g,t)}var C,L=X.pEventTypes;function H(){for(var G=0,pe=t.interactions.list;G<pe.length;G++){var Me=pe[G];if(Me.pointerIsDown&&Me.pointerType==="touch"&&!Me._interacting)for(var ye=function(){var ol=La[Qe];t.documents.some(function(al){return de(al.doc,ol.downTarget)})||Me.removePointer(ol.pointer,ol.event)},Qe=0,La=Me.pointers;Qe<La.length;Qe++)ye()}}(C=ne.PointerEvent?[{type:L.down,listener:H},{type:L.down,listener:i.pointerDown},{type:L.move,listener:i.pointerMove},{type:L.up,listener:i.pointerUp},{type:L.cancel,listener:i.pointerUp}]:[{type:"mousedown",listener:i.pointerDown},{type:"mousemove",listener:i.pointerMove},{type:"mouseup",listener:i.pointerUp},{type:"touchstart",listener:H},{type:"touchstart",listener:i.pointerDown},{type:"touchmove",listener:i.pointerMove},{type:"touchend",listener:i.pointerUp},{type:"touchcancel",listener:i.pointerUp}]).push({type:"blur",listener:function(G){for(var pe=0,Me=t.interactions.list;pe<Me.length;pe++)Me[pe].documentBlur(G)}}),t.prevTouchTime=0,t.Interaction=function(G){m(Me,G);var pe=B(Me);function Me(){return c(this,Me),pe.apply(this,arguments)}return f(Me,[{key:"pointerMoveTolerance",get:function(){return t.interactions.pointerMoveTolerance},set:function(ye){t.interactions.pointerMoveTolerance=ye}},{key:"_now",value:function(){return t.now()}}]),Me}(mn),t.interactions={list:[],new:function(G){G.scopeFire=function(Me,ye){return t.fire(Me,ye)};var pe=new t.Interaction(G);return t.interactions.list.push(pe),pe},listeners:i,docEvents:C,pointerMoveTolerance:1},t.usePlugin(dn)},listeners:{"scope:add-document":function(t){return No(t,"add")},"scope:remove-document":function(t){return No(t,"remove")},"interactable:unset":function(t,i){for(var p=t.interactable,g=i.interactions.list.length-1;g>=0;g--){var C=i.interactions.list[g];C.interactable===p&&(C.stop(),i.fire("interactions:destroy",{interaction:C}),C.destroy(),i.interactions.list.length>2&&i.interactions.list.splice(g,1))}}},onDocSignal:No,doOnInteractions:$n,methodNames:Pr},zi=Ai,kn=function(t){return t[t.On=0]="On",t[t.Off=1]="Off",t}(kn||{}),Mi=function(){function t(i,p,g,C){c(this,t),this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new Sn,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=p.actions,this.target=i,this._context=p.context||g,this._win=$(Wa(i)?this._context:i),this._doc=this._win.document,this._scopeEvents=C,this.set(p)}return f(t,[{key:"_defaults",get:function(){return{base:{},perAction:{},actions:{}}}},{key:"setOnEvents",value:function(i,p){return _.func(p.onstart)&&this.on("".concat(i,"start"),p.onstart),_.func(p.onmove)&&this.on("".concat(i,"move"),p.onmove),_.func(p.onend)&&this.on("".concat(i,"end"),p.onend),_.func(p.oninertiastart)&&this.on("".concat(i,"inertiastart"),p.oninertiastart),this}},{key:"updatePerActionListeners",value:function(i,p,g){var C,L=this,H=(C=this._actions.map[i])==null?void 0:C.filterEventType,G=function(pe){return(H==null||H(pe))&&Xr(pe,L._actions)};(_.array(p)||_.object(p))&&this._onOff(kn.Off,i,p,void 0,G),(_.array(g)||_.object(g))&&this._onOff(kn.On,i,g,void 0,G)}},{key:"setPerAction",value:function(i,p){var g=this._defaults;for(var C in p){var L=C,H=this.options[i],G=p[L];L==="listeners"&&this.updatePerActionListeners(i,H.listeners,G),_.array(G)?H[L]=Ce(G):_.plainObject(G)?(H[L]=ee(H[L]||{},qr(G)),_.object(g.perAction[L])&&"enabled"in g.perAction[L]&&(H[L].enabled=G.enabled!==!1)):_.bool(G)&&_.object(g.perAction[L])?H[L].enabled=G:H[L]=G}}},{key:"getRect",value:function(i){return i=i||(_.element(this.target)?this.target:null),_.string(this.target)&&(i=i||this._context.querySelector(this.target)),pa(i)}},{key:"rectChecker",value:function(i){var p=this;return _.func(i)?(this.getRect=function(g){var C=ee({},i.apply(p,g));return"width"in C||(C.width=C.right-C.left,C.height=C.bottom-C.top),C},this):i===null?(delete this.getRect,this):this.getRect}},{key:"_backCompatOption",value:function(i,p){if(Wa(p)||_.object(p)){for(var g in this.options[i]=p,this._actions.map)this.options[g][i]=p;return this}return this.options[i]}},{key:"origin",value:function(i){return this._backCompatOption("origin",i)}},{key:"deltaSource",value:function(i){return i==="page"||i==="client"?(this.options.deltaSource=i,this):this.options.deltaSource}},{key:"getAllElements",value:function(){var i=this.target;return _.string(i)?Array.from(this._context.querySelectorAll(i)):_.func(i)&&i.getAllElements?i.getAllElements():_.element(i)?[i]:[]}},{key:"context",value:function(){return this._context}},{key:"inContext",value:function(i){return this._context===i.ownerDocument||de(this._context,i)}},{key:"testIgnoreAllow",value:function(i,p,g){return!this.testIgnore(i.ignoreFrom,p,g)&&this.testAllow(i.allowFrom,p,g)}},{key:"testAllow",value:function(i,p,g){return!i||!!_.element(g)&&(_.string(i)?me(g,i,p):!!_.element(i)&&de(i,g))}},{key:"testIgnore",value:function(i,p,g){return!(!i||!_.element(g))&&(_.string(i)?me(g,i,p):!!_.element(i)&&de(i,g))}},{key:"fire",value:function(i){return this.events.fire(i),this}},{key:"_onOff",value:function(i,p,g,C,L){_.object(p)&&!_.array(p)&&(C=g,g=null);var H=Ge(p,g,L);for(var G in H){G==="wheel"&&(G=X.wheelEvent);for(var pe=0,Me=H[G];pe<Me.length;pe++){var ye=Me[pe];Xr(G,this._actions)?this.events[i===kn.On?"on":"off"](G,ye):_.string(this.target)?this._scopeEvents[i===kn.On?"addDelegate":"removeDelegate"](this.target,this._context,G,ye,C):this._scopeEvents[i===kn.On?"add":"remove"](this.target,G,ye,C)}}return this}},{key:"on",value:function(i,p,g){return this._onOff(kn.On,i,p,g)}},{key:"off",value:function(i,p,g){return this._onOff(kn.Off,i,p,g)}},{key:"set",value:function(i){var p=this._defaults;for(var g in _.object(i)||(i={}),this.options=qr(p.base),this._actions.methodDict){var C=g,L=this._actions.methodDict[C];this.options[C]={},this.setPerAction(C,ee(ee({},p.perAction),p.actions[C])),this[L](i[C])}for(var H in i)H!=="getRect"?_.func(this[H])&&this[H](i[H]):this.rectChecker(i.getRect);return this}},{key:"unset",value:function(){if(_.string(this.target))for(var i in this._scopeEvents.delegatedEvents)for(var p=this._scopeEvents.delegatedEvents[i],g=p.length-1;g>=0;g--){var C=p[g],L=C.selector,H=C.context,G=C.listeners;L===this.target&&H===this._context&&p.splice(g,1);for(var pe=G.length-1;pe>=0;pe--)this._scopeEvents.removeDelegate(this.target,this._context,i,G[pe][0],G[pe][1])}else this._scopeEvents.remove(this.target,"all")}}]),t}(),Oi=function(){function t(i){var p=this;c(this,t),this.list=[],this.selectorMap={},this.scope=void 0,this.scope=i,i.addListeners({"interactable:unset":function(g){var C=g.interactable,L=C.target,H=_.string(L)?p.selectorMap[L]:L[p.scope.id],G=Z(H,function(pe){return pe===C});H.splice(G,1)}})}return f(t,[{key:"new",value:function(i,p){p=ee(p||{},{actions:this.scope.actions});var g=new this.scope.Interactable(i,p,this.scope.document,this.scope.events);return this.scope.addDocument(g._doc),this.list.push(g),_.string(i)?(this.selectorMap[i]||(this.selectorMap[i]=[]),this.selectorMap[i].push(g)):(g.target[this.scope.id]||Object.defineProperty(i,this.scope.id,{value:[],configurable:!0}),i[this.scope.id].push(g)),this.scope.fire("interactable:new",{target:i,options:p,interactable:g,win:this.scope._win}),g}},{key:"getExisting",value:function(i,p){var g=p&&p.context||this.scope.document,C=_.string(i),L=C?this.selectorMap[i]:i[this.scope.id];if(L)return fa(L,function(H){return H._context===g&&(C||H.inContext(i))})}},{key:"forEachMatch",value:function(i,p){for(var g=0,C=this.list;g<C.length;g++){var L=C[g],H=void 0;if((_.string(L.target)?_.element(i)&&oe(i,L.target):i===L.target)&&L.inContext(i)&&(H=p(L)),H!==void 0)return H}}}]),t}(),Ho=function(){function t(){var i=this;c(this,t),this.id="__interact_scope_".concat(Math.floor(100*Math.random())),this.isInitialized=!1,this.listenerMaps=[],this.browser=X,this.defaults=qr(Wr),this.Eventable=Sn,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=function(g){var C=function L(H,G){var pe=g.interactables.getExisting(H,G);return pe||((pe=g.interactables.new(H,G)).events.global=L.globalEvents),pe};return C.getPointerAverage=ve,C.getTouchBBox=Xe,C.getTouchDistance=aa,C.getTouchAngle=Pe,C.getElementRect=pa,C.getElementClientRect=Ne,C.matchesSelector=oe,C.closest=Ke,C.globalEvents={},C.version="1.10.27",C.scope=g,C.use=function(L,H){return this.scope.usePlugin(L,H),this},C.isSet=function(L,H){return!!this.scope.interactables.get(L,H&&H.context)},C.on=Se(function(L,H,G){if(_.string(L)&&L.search(" ")!==-1&&(L=L.trim().split(/ +/)),_.array(L)){for(var pe=0,Me=L;pe<Me.length;pe++){var ye=Me[pe];this.on(ye,H,G)}return this}if(_.object(L)){for(var Qe in L)this.on(Qe,L[Qe],H);return this}return Xr(L,this.scope.actions)?this.globalEvents[L]?this.globalEvents[L].push(H):this.globalEvents[L]=[H]:this.scope.events.add(this.scope.document,L,H,{options:G}),this},"The interact.on() method is being deprecated"),C.off=Se(function(L,H,G){if(_.string(L)&&L.search(" ")!==-1&&(L=L.trim().split(/ +/)),_.array(L)){for(var pe=0,Me=L;pe<Me.length;pe++){var ye=Me[pe];this.off(ye,H,G)}return this}if(_.object(L)){for(var Qe in L)this.off(Qe,L[Qe],H);return this}var La;return Xr(L,this.scope.actions)?L in this.globalEvents&&(La=this.globalEvents[L].indexOf(H))!==-1&&this.globalEvents[L].splice(La,1):this.scope.events.remove(this.scope.document,L,H,G),this},"The interact.off() method is being deprecated"),C.debug=function(){return this.scope},C.supportsTouch=function(){return X.supportsTouch},C.supportsPointerEvent=function(){return X.supportsPointerEvent},C.stop=function(){for(var L=0,H=this.scope.interactions.list;L<H.length;L++)H[L].stop();return this},C.pointerMoveTolerance=function(L){return _.number(L)?(this.scope.interactions.pointerMoveTolerance=L,this):this.scope.interactions.pointerMoveTolerance},C.addDocument=function(L,H){this.scope.addDocument(L,H)},C.removeDocument=function(L){this.scope.removeDocument(L)},C}(this),this.InteractEvent=Br,this.Interactable=void 0,this.interactables=new Oi(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=function(g){return i.removeDocument(g.target)};var p=this;this.Interactable=function(g){m(L,g);var C=B(L);function L(){return c(this,L),C.apply(this,arguments)}return f(L,[{key:"_defaults",get:function(){return p.defaults}},{key:"set",value:function(H){return w(u(L.prototype),"set",this).call(this,H),p.fire("interactable:set",{options:H,interactable:this}),this}},{key:"unset",value:function(){w(u(L.prototype),"unset",this).call(this);var H=p.interactables.list.indexOf(this);H<0||(p.interactables.list.splice(H,1),p.fire("interactable:unset",{interactable:this}))}}]),L}(Mi)}return f(t,[{key:"addListeners",value:function(i,p){this.listenerMaps.push({id:p,map:i})}},{key:"fire",value:function(i,p){for(var g=0,C=this.listenerMaps;g<C.length;g++){var L=C[g].map[i];if(L&&L(p,this,i)===!1)return!1}}},{key:"init",value:function(i){return this.isInitialized?this:function(p,g){return p.isInitialized=!0,_.window(g)&&b(g),ne.init(g),X.init(g),Je.init(g),p.window=g,p.document=g.document,p.usePlugin(zi),p.usePlugin(Ln),p}(this,i)}},{key:"pluginIsInstalled",value:function(i){var p=i.id;return p?!!this._plugins.map[p]:this._plugins.list.indexOf(i)!==-1}},{key:"usePlugin",value:function(i,p){if(!this.isInitialized)return this;if(this.pluginIsInstalled(i))return this;if(i.id&&(this._plugins.map[i.id]=i),this._plugins.list.push(i),i.install&&i.install(this,p),i.listeners&&i.before){for(var g=0,C=this.listenerMaps.length,L=i.before.reduce(function(G,pe){return G[pe]=!0,G[Uo(pe)]=!0,G},{});g<C;g++){var H=this.listenerMaps[g].id;if(H&&(L[H]||L[Uo(H)]))break}this.listenerMaps.splice(g,0,{id:i.id,map:i.listeners})}else i.listeners&&this.listenerMaps.push({id:i.id,map:i.listeners});return this}},{key:"addDocument",value:function(i,p){if(this.getDocIndex(i)!==-1)return!1;var g=$(i);p=p?ee({},p):{},this.documents.push({doc:i,options:p}),this.events.documents.push(i),i!==this.document&&this.events.add(g,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:i,window:g,scope:this,options:p})}},{key:"removeDocument",value:function(i){var p=this.getDocIndex(i),g=$(i),C=this.documents[p].options;this.events.remove(g,"unload",this.onWindowUnload),this.documents.splice(p,1),this.events.documents.splice(p,1),this.fire("scope:remove-document",{doc:i,window:g,scope:this,options:C})}},{key:"getDocIndex",value:function(i){for(var p=0;p<this.documents.length;p++)if(this.documents[p].doc===i)return p;return-1}},{key:"getDocOptions",value:function(i){var p=this.getDocIndex(i);return p===-1?null:this.documents[p].options}},{key:"now",value:function(){return(this.window.Date||Date).now()}}]),t}();function Uo(t){return t&&t.replace(/\/.*$/,"")}var qo=new Ho,Or=qo.interactStatic,Ii=typeof globalThis<"u"?globalThis:window;qo.init(Ii);var Bo=Object.freeze({__proto__:null,edgeTarget:function(){},elements:function(){},grid:function(t){var i=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(function(g){var C=g[0],L=g[1];return C in t||L in t}),p=function(g,C){for(var L=t.range,H=t.limits,G=H===void 0?{left:-1/0,right:1/0,top:-1/0,bottom:1/0}:H,pe=t.offset,Me=pe===void 0?{x:0,y:0}:pe,ye={range:L,grid:t,x:null,y:null},Qe=0;Qe<i.length;Qe++){var La=i[Qe],ol=La[0],al=La[1],sl=Math.round((g-Me.x)/t[ol]),Cl=Math.round((C-Me.y)/t[al]);ye[ol]=Math.max(G.left,Math.min(G.right,sl*t[ol]+Me.x)),ye[al]=Math.max(G.top,Math.min(G.bottom,Cl*t[al]+Me.y))}return ye};return p.grid=t,p.coordFields=i,p}}),Li={id:"snappers",install:function(t){var i=t.interactStatic;i.snappers=ee(i.snappers||{},Bo),i.createSnapGrid=i.snappers.grid}},To=Li,Wo={start:function(t){var i=t.state,p=t.rect,g=t.edges,C=t.pageCoords,L=i.options,H=L.ratio,G=L.enabled,pe=i.options,Me=pe.equalDelta,ye=pe.modifiers;H==="preserve"&&(H=p.width/p.height),i.startCoords=ee({},C),i.startRect=ee({},p),i.ratio=H,i.equalDelta=Me;var Qe=i.linkedEdges={top:g.top||g.left&&!g.bottom,left:g.left||g.top&&!g.right,bottom:g.bottom||g.right&&!g.top,right:g.right||g.bottom&&!g.left};if(i.xIsPrimaryAxis=!(!g.left&&!g.right),i.equalDelta){var La=(Qe.left?1:-1)*(Qe.top?1:-1);i.edgeSign={x:La,y:La}}else i.edgeSign={x:Qe.left?-1:1,y:Qe.top?-1:1};if(G!==!1&&ee(g,Qe),ye!=null&&ye.length){var ol=new pn(t.interaction);ol.copyFrom(t.interaction.modification),ol.prepareStates(ye),i.subModification=ol,ol.startAll(o({},t))}},set:function(t){var i=t.state,p=t.rect,g=t.coords,C=i.linkedEdges,L=ee({},g),H=i.equalDelta?Ko:$i;if(ee(t.edges,C),H(i,i.xIsPrimaryAxis,g,p),!i.subModification)return null;var G=ee({},p);Te(C,G,{x:g.x-L.x,y:g.y-L.y});var pe=i.subModification.setAll(o(o({},t),{},{rect:G,edges:C,pageCoords:g,prevCoords:g,prevRect:G})),Me=pe.delta;return pe.changed&&(H(i,Math.abs(Me.x)>Math.abs(Me.y),pe.coords,pe.rect),ee(g,pe.coords)),pe.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function Ko(t,i,p){var g=t.startCoords,C=t.edgeSign;i?p.y=g.y+(p.x-g.x)*C.y:p.x=g.x+(p.y-g.y)*C.x}function $i(t,i,p,g){var C=t.startRect,L=t.startCoords,H=t.ratio,G=t.edgeSign;if(i){var pe=g.width/H;p.y=L.y+(pe-C.height)*G.y}else{var Me=g.height*H;p.x=L.x+(Me-C.width)*G.x}}var Ri=Dr(Wo,"aspectRatio"),Yo=function(){};Yo._defaults={};var xn=Yo;function _n(t,i,p){return _.func(t)?Ve(t,i.interactable,i.element,[p.x,p.y,i]):Ve(t,i.interactable,i.element)}var Rn={start:function(t){var i=t.rect,p=t.startOffset,g=t.state,C=t.interaction,L=t.pageCoords,H=g.options,G=H.elementRect,pe=ee({left:0,top:0,right:0,bottom:0},H.offset||{});if(i&&G){var Me=_n(H.restriction,C,L);if(Me){var ye=Me.right-Me.left-i.width,Qe=Me.bottom-Me.top-i.height;ye<0&&(pe.left+=ye,pe.right+=ye),Qe<0&&(pe.top+=Qe,pe.bottom+=Qe)}pe.left+=p.left-i.width*G.left,pe.top+=p.top-i.height*G.top,pe.right+=p.right-i.width*(1-G.right),pe.bottom+=p.bottom-i.height*(1-G.bottom)}g.offset=pe},set:function(t){var i=t.coords,p=t.interaction,g=t.state,C=g.options,L=g.offset,H=_n(C.restriction,p,i);if(H){var G=function(pe){return!pe||"left"in pe&&"top"in pe||((pe=ee({},pe)).left=pe.x||0,pe.top=pe.y||0,pe.right=pe.right||pe.left+pe.width,pe.bottom=pe.bottom||pe.top+pe.height),pe}(H);i.x=Math.max(Math.min(G.right-L.right,i.x),G.left+L.left),i.y=Math.max(Math.min(G.bottom-L.bottom,i.y),G.top+L.top)}},defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}},Vi=Dr(Rn,"restrict"),Go={top:1/0,left:1/0,bottom:-1/0,right:-1/0},Jo={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function Xo(t,i){for(var p=0,g=["top","left","bottom","right"];p<g.length;p++){var C=g[p];C in t||(t[C]=i[C])}return t}var Vn={noInner:Go,noOuter:Jo,start:function(t){var i,p=t.interaction,g=t.startOffset,C=t.state,L=C.options;L&&(i=ka(_n(L.offset,p,p.coords.start.page))),i=i||{x:0,y:0},C.offset={top:i.y+g.top,left:i.x+g.left,bottom:i.y-g.bottom,right:i.x-g.right}},set:function(t){var i=t.coords,p=t.edges,g=t.interaction,C=t.state,L=C.offset,H=C.options;if(p){var G=ee({},i),pe=_n(H.inner,g,G)||{},Me=_n(H.outer,g,G)||{};Xo(pe,Go),Xo(Me,Jo),p.top?i.y=Math.min(Math.max(Me.top+L.top,G.y),pe.top+L.top):p.bottom&&(i.y=Math.max(Math.min(Me.bottom+L.bottom,G.y),pe.bottom+L.bottom)),p.left?i.x=Math.min(Math.max(Me.left+L.left,G.x),pe.left+L.left):p.right&&(i.x=Math.max(Math.min(Me.right+L.right,G.x),pe.right+L.right))}},defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}},Jn=Dr(Vn,"restrictEdges"),Zo=ee({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(t){}},Rn.defaults),Qo=Dr({start:Rn.start,set:Rn.set,defaults:Zo},"restrictRect"),Xn={width:-1/0,height:-1/0},Pi={width:1/0,height:1/0},ei=Dr({start:function(t){return Vn.start(t)},set:function(t){var i=t.interaction,p=t.state,g=t.rect,C=t.edges,L=p.options;if(C){var H=He(_n(L.min,i,t.coords))||Xn,G=He(_n(L.max,i,t.coords))||Pi;p.options={endOnly:L.endOnly,inner:ee({},Vn.noInner),outer:ee({},Vn.noOuter)},C.top?(p.options.inner.top=g.bottom-H.height,p.options.outer.top=g.bottom-G.height):C.bottom&&(p.options.inner.bottom=g.top+H.height,p.options.outer.bottom=g.top+G.height),C.left?(p.options.inner.left=g.right-H.width,p.options.outer.left=g.right-G.width):C.right&&(p.options.inner.right=g.left+H.width,p.options.outer.right=g.left+G.width),Vn.set(t),p.options=L}},defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize"),Bn={start:function(t){var i,p=t.interaction,g=t.interactable,C=t.element,L=t.rect,H=t.state,G=t.startOffset,pe=H.options,Me=pe.offsetWithOrigin?function(La){var ol=La.interaction.element,al=ka(Ve(La.state.options.origin,null,null,[ol])),sl=al||Re(La.interactable,ol,La.interaction.prepared.name);return sl}(t):{x:0,y:0};if(pe.offset==="startCoords")i={x:p.coords.start.page.x,y:p.coords.start.page.y};else{var ye=Ve(pe.offset,g,C,[p]);(i=ka(ye)||{x:0,y:0}).x+=Me.x,i.y+=Me.y}var Qe=pe.relativePoints;H.offsets=L&&Qe&&Qe.length?Qe.map(function(La,ol){return{index:ol,relativePoint:La,x:G.left-L.width*La.x+i.x,y:G.top-L.height*La.y+i.y}}):[{index:0,relativePoint:null,x:i.x,y:i.y}]},set:function(t){var i=t.interaction,p=t.coords,g=t.state,C=g.options,L=g.offsets,H=Re(i.interactable,i.element,i.prepared.name),G=ee({},p),pe=[];C.offsetWithOrigin||(G.x-=H.x,G.y-=H.y);for(var Me=0,ye=L;Me<ye.length;Me++)for(var Qe=ye[Me],La=G.x-Qe.x,ol=G.y-Qe.y,al=0,sl=C.targets.length;al<sl;al++){var Cl=C.targets[al],cl=void 0;(cl=_.func(Cl)?Cl(La,ol,i._proxy,Qe,al):Cl)&&pe.push({x:(_.number(cl.x)?cl.x:La)+Qe.x,y:(_.number(cl.y)?cl.y:ol)+Qe.y,range:_.number(cl.range)?cl.range:C.range,source:Cl,index:al,offset:Qe})}for(var Bl={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}},Ol=0;Ol<pe.length;Ol++){var Yl=pe[Ol],Nl=Yl.range,jl=Yl.x-G.x,Ir=Yl.y-G.y,mr=Fa(jl,Ir),Fr=mr<=Nl;Nl===1/0&&Bl.inRange&&Bl.range!==1/0&&(Fr=!1),Bl.target&&!(Fr?Bl.inRange&&Nl!==1/0?mr/Nl<Bl.distance/Bl.range:Nl===1/0&&Bl.range!==1/0||mr<Bl.distance:!Bl.inRange&&mr<Bl.distance)||(Bl.target=Yl,Bl.distance=mr,Bl.range=Nl,Bl.inRange=Fr,Bl.delta.x=jl,Bl.delta.y=Ir)}return Bl.inRange&&(p.x=Bl.target.x,p.y=Bl.target.y),g.closest=Bl,Bl},defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}},Fi=Dr(Bn,"snap"),to={start:function(t){var i=t.state,p=t.edges,g=i.options;if(!p)return null;t.state={options:{targets:null,relativePoints:[{x:p.left?0:1,y:p.top?0:1}],offset:g.offset||"self",origin:{x:0,y:0},range:g.range}},i.targetFields=i.targetFields||[["width","height"],["x","y"]],Bn.start(t),i.offsets=t.state.offsets,t.state=i},set:function(t){var i=t.interaction,p=t.state,g=t.coords,C=p.options,L=p.offsets,H={x:g.x-L[0].x,y:g.y-L[0].y};p.options=ee({},C),p.options.targets=[];for(var G=0,pe=C.targets||[];G<pe.length;G++){var Me=pe[G],ye=void 0;if(ye=_.func(Me)?Me(H.x,H.y,i):Me){for(var Qe=0,La=p.targetFields;Qe<La.length;Qe++){var ol=La[Qe],al=ol[0],sl=ol[1];if(al in ye||sl in ye){ye.x=ye[al],ye.y=ye[sl];break}}p.options.targets.push(ye)}}var Cl=Bn.set(t);return p.options=C,Cl},defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}},ji=Dr(to,"snapSize"),Ao={aspectRatio:Ri,restrictEdges:Jn,restrict:Vi,restrictRect:Qo,restrictSize:ei,snapEdges:Dr({start:function(t){var i=t.edges;return i?(t.state.targetFields=t.state.targetFields||[[i.left?"left":"right",i.top?"top":"bottom"]],to.start(t)):null},set:to.set,defaults:ee(qr(to.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})},"snapEdges"),snap:Fi,snapSize:ji,spring:xn,avoid:xn,transform:xn,rubberband:xn},Hi={id:"modifiers",install:function(t){var i=t.interactStatic;for(var p in t.usePlugin(Il),t.usePlugin(To),i.modifiers=Ao,Ao){var g=Ao[p],C=g._defaults,L=g._methods;C._methods=L,t.defaults.perAction[p]=C}}},Ui=Hi,ai=function(t){m(p,t);var i=B(p);function p(g,C,L,H,G,pe){var Me;if(c(this,p),F(E(Me=i.call(this,G)),L),L!==C&&F(E(Me),C),Me.timeStamp=pe,Me.originalEvent=L,Me.type=g,Me.pointerId=Oe(C),Me.pointerType=xa(C),Me.target=H,Me.currentTarget=null,g==="tap"){var ye=G.getPointerIndex(C);Me.dt=Me.timeStamp-G.pointers[ye].downTime;var Qe=Me.timeStamp-G.tapTime;Me.double=!!G.prevTap&&G.prevTap.type!=="doubletap"&&G.prevTap.target===Me.target&&Qe<500}else g==="doubletap"&&(Me.dt=C.timeStamp-G.tapTime,Me.double=!0);return Me}return f(p,[{key:"_subtractOrigin",value:function(g){var C=g.x,L=g.y;return this.pageX-=C,this.pageY-=L,this.clientX-=C,this.clientY-=L,this}},{key:"_addOrigin",value:function(g){var C=g.x,L=g.y;return this.pageX+=C,this.pageY+=L,this.clientX+=C,this.clientY+=L,this}},{key:"preventDefault",value:function(){this.originalEvent.preventDefault()}}]),p}(va),Pn={id:"pointer-events/base",before:["inertia","modifiers","auto-start","actions"],install:function(t){t.pointerEvents=Pn,t.defaults.actions.pointerEvents=Pn.defaults,ee(t.actions.phaselessTypes,Pn.types)},listeners:{"interactions:new":function(t){var i=t.interaction;i.prevTap=null,i.tapTime=0},"interactions:update-pointer":function(t){var i=t.down,p=t.pointerInfo;!i&&p.hold||(p.hold={duration:1/0,timeout:null})},"interactions:move":function(t,i){var p=t.interaction,g=t.pointer,C=t.event,L=t.eventTarget;t.duplicate||p.pointerIsDown&&!p.pointerWasMoved||(p.pointerIsDown&&zo(t),wn({interaction:p,pointer:g,event:C,eventTarget:L,type:"move"},i))},"interactions:down":function(t,i){(function(p,g){for(var C=p.interaction,L=p.pointer,H=p.event,G=p.eventTarget,pe=p.pointerIndex,Me=C.pointers[pe].hold,ye=_a(G),Qe={interaction:C,pointer:L,event:H,eventTarget:G,type:"hold",targets:[],path:ye,node:null},La=0;La<ye.length;La++){var ol=ye[La];Qe.node=ol,g.fire("pointerEvents:collect-targets",Qe)}if(Qe.targets.length){for(var al=1/0,sl=0,Cl=Qe.targets;sl<Cl.length;sl++){var cl=Cl[sl].eventable.options.holdDuration;cl<al&&(al=cl)}Me.duration=al,Me.timeout=setTimeout(function(){wn({interaction:C,eventTarget:G,pointer:L,event:H,type:"hold"},g)},al)}})(t,i),wn(t,i)},"interactions:up":function(t,i){zo(t),wn(t,i),function(p,g){var C=p.interaction,L=p.pointer,H=p.event,G=p.eventTarget;C.pointerWasMoved||wn({interaction:C,eventTarget:G,pointer:L,event:H,type:"tap"},g)}(t,i)},"interactions:cancel":function(t,i){zo(t),wn(t,i)}},PointerEvent:ai,fire:wn,collectEventTargets:li,defaults:{holdDuration:600,ignoreFrom:null,allowFrom:null,origin:{x:0,y:0}},types:{down:!0,move:!0,up:!0,cancel:!0,tap:!0,doubletap:!0,hold:!0}};function wn(t,i){var p=t.interaction,g=t.pointer,C=t.event,L=t.eventTarget,H=t.type,G=t.targets,pe=G===void 0?li(t,i):G,Me=new ai(H,g,C,L,p,i.now());i.fire("pointerEvents:new",{pointerEvent:Me});for(var ye={interaction:p,pointer:g,event:C,eventTarget:L,targets:pe,type:H,pointerEvent:Me},Qe=0;Qe<pe.length;Qe++){var La=pe[Qe];for(var ol in La.props||{})Me[ol]=La.props[ol];var al=Re(La.eventable,La.node);if(Me._subtractOrigin(al),Me.eventable=La.eventable,Me.currentTarget=La.node,La.eventable.fire(Me),Me._addOrigin(al),Me.immediatePropagationStopped||Me.propagationStopped&&Qe+1<pe.length&&pe[Qe+1].node!==Me.currentTarget)break}if(i.fire("pointerEvents:fired",ye),H==="tap"){var sl=Me.double?wn({interaction:p,pointer:g,event:C,eventTarget:L,type:"doubletap"},i):Me;p.prevTap=sl,p.tapTime=sl.timeStamp}return Me}function li(t,i){var p=t.interaction,g=t.pointer,C=t.event,L=t.eventTarget,H=t.type,G=p.getPointerIndex(g),pe=p.pointers[G];if(H==="tap"&&(p.pointerWasMoved||!pe||pe.downTarget!==L))return[];for(var Me=_a(L),ye={interaction:p,pointer:g,event:C,eventTarget:L,type:H,path:Me,targets:[],node:null},Qe=0;Qe<Me.length;Qe++){var La=Me[Qe];ye.node=La,i.fire("pointerEvents:collect-targets",ye)}return H==="hold"&&(ye.targets=ye.targets.filter(function(ol){var al,sl;return ol.eventable.options.holdDuration===((al=p.pointers[G])==null||(sl=al.hold)==null?void 0:sl.duration)})),ye.targets}function zo(t){var i=t.interaction,p=t.pointerIndex,g=i.pointers[p].hold;g&&g.timeout&&(clearTimeout(g.timeout),g.timeout=null)}var qi=Object.freeze({__proto__:null,default:Pn});function so(t){var i=t.interaction;i.holdIntervalHandle&&(clearInterval(i.holdIntervalHandle),i.holdIntervalHandle=null)}var Wi={id:"pointer-events/holdRepeat",install:function(t){t.usePlugin(Pn);var i=t.pointerEvents;i.defaults.holdRepeatInterval=0,i.types.holdrepeat=t.actions.phaselessTypes.holdrepeat=!0},listeners:["move","up","cancel","endall"].reduce(function(t,i){return t["pointerEvents:".concat(i)]=so,t},{"pointerEvents:new":function(t){var i=t.pointerEvent;i.type==="hold"&&(i.count=(i.count||0)+1)},"pointerEvents:fired":function(t,i){var p=t.interaction,g=t.pointerEvent,C=t.eventTarget,L=t.targets;if(g.type==="hold"&&L.length){var H=L[0].eventable.options.holdRepeatInterval;H<=0||(p.holdIntervalHandle=setTimeout(function(){i.pointerEvents.fire({interaction:p,eventTarget:C,type:"hold",pointer:g,event:g},i)},H))}}})},Ki=Wi,Yi={id:"pointer-events/interactableTargets",install:function(t){var i=t.Interactable;i.prototype.pointerEvents=function(g){return ee(this.events.options,g),this};var p=i.prototype._backCompatOption;i.prototype._backCompatOption=function(g,C){var L=p.call(this,g,C);return L===this&&(this.events.options[g]=C),L}},listeners:{"pointerEvents:collect-targets":function(t,i){var p=t.targets,g=t.node,C=t.type,L=t.eventTarget;i.interactables.forEachMatch(g,function(H){var G=H.events,pe=G.options;G.types[C]&&G.types[C].length&&H.testIgnoreAllow(pe,g,L)&&p.push({node:g,eventable:G,props:{interactable:H}})})},"interactable:new":function(t){var i=t.interactable;i.events.getRect=function(p){return i.getRect(p)}},"interactable:set":function(t,i){var p=t.interactable,g=t.options;ee(p.events.options,i.pointerEvents.defaults),ee(p.events.options,g.pointerEvents||{})}}},Gi=Yi,ri={id:"pointer-events",install:function(t){t.usePlugin(qi),t.usePlugin(Ki),t.usePlugin(Gi)}},co=ri,Ji={id:"reflow",install:function(t){var i=t.Interactable;t.actions.phases.reflow=!0,i.prototype.reflow=function(p){return function(g,C,L){for(var H=g.getAllElements(),G=L.window.Promise,pe=G?[]:null,Me=function(){var Qe=H[ye],La=g.getRect(Qe);if(!La)return 1;var ol,al=fa(L.interactions.list,function(cl){return cl.interacting()&&cl.interactable===g&&cl.element===Qe&&cl.prepared.name===C.name});if(al)al.move(),pe&&(ol=al._reflowPromise||new G(function(cl){al._reflowResolve=cl}));else{var sl=He(La),Cl=function(cl){return{coords:cl,get page(){return this.coords.page},get client(){return this.coords.client},get timeStamp(){return this.coords.timeStamp},get pageX(){return this.coords.page.x},get pageY(){return this.coords.page.y},get clientX(){return this.coords.client.x},get clientY(){return this.coords.client.y},get pointerId(){return this.coords.pointerId},get target(){return this.coords.target},get type(){return this.coords.type},get pointerType(){return this.coords.pointerType},get buttons(){return this.coords.buttons},preventDefault:function(){}}}({page:{x:sl.x,y:sl.y},client:{x:sl.x,y:sl.y},timeStamp:L.now()});ol=function(cl,Bl,Ol,Yl,Nl){var jl=cl.interactions.new({pointerType:"reflow"}),Ir={interaction:jl,event:Nl,pointer:Nl,eventTarget:Ol,phase:"reflow"};jl.interactable=Bl,jl.element=Ol,jl.prevEvent=Nl,jl.updatePointer(Nl,Nl,Ol,!0),ie(jl.coords.delta),qa(jl.prepared,Yl),jl._doPhase(Ir);var mr=cl.window,Fr=mr.Promise,en=Fr?new Fr(function(tn){jl._reflowResolve=tn}):void 0;return jl._reflowPromise=en,jl.start(Yl,Bl,Ol),jl._interacting?(jl.move(Ir),jl.end(Nl)):(jl.stop(),jl._reflowResolve()),jl.removePointer(Nl,Nl),en}(L,g,Qe,C,Cl)}pe&&pe.push(ol)},ye=0;ye<H.length&&!Me();ye++);return pe&&G.all(pe).then(function(){return g})}(this,p,t)}},listeners:{"interactions:stop":function(t,i){var p=t.interaction;p.pointerType==="reflow"&&(p._reflowResolve&&p._reflowResolve(),function(g,C){g.splice(g.indexOf(C),1)}(i.interactions.list,p))}}},Xi=Ji;if(Or.use(dn),Or.use(cr),Or.use(co),Or.use(Qr),Or.use(Ui),Or.use(Er),Or.use(xe),Or.use(we),Or.use(Xi),Or.default=Or,s(l)==="object"&&l)try{l.exports=Or}catch{}return Or.default=Or,Or})}(Lo,Lo.exports)),Lo.exports}var U4=H4();const Es=I.getDefaultExportFromCjs(U4),Ni=a.defineComponent({__name:"grid-item",props:{isDraggable:{type:Boolean,default:void 0},isResizable:{type:Boolean,default:void 0},isBounded:{type:Boolean,default:void 0},static:{type:Boolean,default:!1},minH:{default:1},minW:{default:1},maxH:{default:1/0},maxW:{default:1/0},x:{},y:{},w:{},h:{},i:{},dragIgnoreFrom:{default:"a, button"},dragAllowFrom:{default:void 0},resizeIgnoreFrom:{default:"a, button"},preserveAspectRatio:{type:Boolean,default:!1},dragOption:{default:()=>({})},resizeOption:{default:()=>({})}},emits:["container-resized","resize","resized","move","moved"],setup(l,{expose:r,emit:n}){const o=l,s=n,c=a.inject(Bc),y=a.inject(Tc);if(!c)throw new Error("[grid-layout-plus]: missing layout store, GridItem must under a GridLayout.");const f=a.shallowRef(null),v=a.reactive({cols:1,containerWidth:100,rowHeight:30,margin:[10,10],maxRows:1/0,draggable:void 0,resizable:void 0,bounded:void 0,transformScale:1,useCssTransforms:!0,useStyleCursor:!0,isDragging:!1,dragging:{top:-1,left:-1},isResizing:!1,resizing:{width:-1,height:-1},style:{},rtl:!1});let m=!1,u=!1,x=NaN,E=NaN,B=NaN,w=NaN,V=-1,A=-1,N=-1,Y=-1,b=o.x,$=o.y,T=o.w,k=o.h;const _=a.ref(),U=a.reactive({i:a.toRef(o,"i"),state:v,wrapper:_,calcXY:Ve});function W(se){Ge(se)}function ce(){Ga()}function Ee(se){rn(o.isDraggable)&&(v.draggable=se)}function Ie(se){rn(o.isResizable)&&(v.resizable=se)}function De(se){rn(o.isBounded)&&(v.bounded=se)}function ne(se){v.transformScale=se}function ge(se){v.rowHeight=se}function X(se){v.maxRows=se}function de(){v.rtl=ws()==="rtl",Ga()}function Ke(se){v.cols=Math.floor(se)}c.increaseItem(U),a.onBeforeMount(()=>{v.rtl=ws()==="rtl"}),a.onMounted(()=>{c.responsive&&c.lastBreakpoint?v.cols=Ic(c.lastBreakpoint,c.cols):v.cols=c.colNum,v.rowHeight=c.rowHeight,v.containerWidth=c.width!==null?c.width:100,v.margin=c.margin!==void 0?c.margin.map(Number):[10,10],v.maxRows=c.maxRows,rn(o.isDraggable)?v.draggable=c.isDraggable:v.draggable=o.isDraggable,rn(o.isResizable)?v.resizable=c.isResizable:v.resizable=o.isResizable,rn(o.isBounded)?v.bounded=c.isBounded:v.bounded=o.isBounded,v.transformScale=c.transformScale,v.useCssTransforms=c.useCssTransforms,v.useStyleCursor=c.useStyleCursor,a.watchEffect(()=>{b=o.x,$=o.y,k=o.h,T=o.w,jr(pa)}),y.on("updateWidth",W),y.on("compact",ce),y.on("setDraggable",Ee),y.on("setResizable",Ie),y.on("setBounded",De),y.on("setTransformScale",ne),y.on("setRowHeight",ge),y.on("setMaxRows",X),y.on("directionchange",de),y.on("setColNum",Ke)}),a.onBeforeUnmount(()=>{y.off("updateWidth",W),y.off("compact",ce),y.off("setDraggable",Ee),y.off("setResizable",Ie),y.off("setBounded",De),y.off("setTransformScale",ne),y.off("setRowHeight",ge),y.off("setMaxRows",X),y.off("directionchange",de),y.off("setColNum",Ke),f.value&&(f.value.unset(),f.value=null),c.decreaseItem(U)}),r({state:v,wrapper:_});const Ta=typeof navigator<"u"?navigator.userAgent.toLowerCase().includes("android"):!1,oe=a.computed(()=>v.resizable&&!o.static),S=a.computed(()=>c.isMirrored?!v.rtl:v.rtl),le=a.computed(()=>(v.draggable||v.resizable)&&!o.static),me=I4("item"),ue=a.computed(()=>({[me.b()]:!0,[me.bm("resizable")]:oe.value,[me.bm("static")]:o.static,[me.bm("resizing")]:v.isResizing,[me.bm("dragging")]:v.isDragging,[me.bm("transform")]:v.useCssTransforms,[me.bm("rtl")]:S.value,[me.bm("no-touch")]:Ta&&le.value})),Ne=a.computed(()=>[me.be("resizer"),S.value&&me.bem("resizer","rtl")].filter(Boolean));a.watch(()=>o.isDraggable,se=>{v.draggable=se}),a.watch(()=>o.static,()=>{jr(F),jr(ie)}),a.watch(()=>v.draggable,()=>{jr(F)}),a.watch(()=>o.isResizable,se=>{v.resizable=se}),a.watch(()=>o.isBounded,se=>{v.bounded=se}),a.watch(()=>v.resizable,()=>{jr(ie)}),a.watch(()=>v.rowHeight,()=>{jr(pa),jr(_a)}),a.watch([()=>v.cols,()=>v.containerWidth],()=>{jr(ie),jr(pa),jr(_a)}),a.watch([()=>o.minH,()=>o.maxH,()=>o.minW,()=>o.maxW],()=>{jr(ie)}),a.watch(S,()=>{jr(ie),jr(pa)}),a.watch([()=>c.margin,()=>c.margin[0],()=>c.margin[1]],()=>{const se=c.margin;!se||se[0]===v.margin[0]&&se[1]===v.margin[1]||(v.margin=se.map(Number),jr(pa),jr(_a))});function pa(){o.x+o.w>v.cols?(b=0,T=o.w>v.cols?v.cols:o.w):(b=o.x,T=o.w);const se=la(b,$,T,k);v.isDragging&&(se.top=v.dragging.top,S.value?se.right=v.dragging.left:se.left=v.dragging.left),v.isResizing&&(se.width=v.resizing.width,se.height=v.resizing.height);let ma;v.useCssTransforms?S.value?ma=A4(se.top,se.right,se.width,se.height):ma=T4(se.top,se.left,se.width,se.height):S.value?ma=M4(se.top,se.right,se.width,se.height):ma=z4(se.top,se.left,se.width,se.height),v.style=ma}function _a(){const se={};for(const ma of["width","height"]){const oa=v.style[ma].match(/^(\d+)px$/);if(!oa)return;se[ma]=oa[1]}s("container-resized",o.i,o.h,o.w,se.height,se.width)}function Wa(se){if(o.static)return;const ma=se.type;if(ma==="resizestart"&&v.isResizing||ma!=="resizestart"&&!v.isResizing)return;const oa=xs(se);if(rn(oa))return;const{x:Oe,y:_e}=oa,wa={width:0,height:0};let ve;switch(ma){case"resizestart":{ie(),V=T,A=k,ve=la(b,$,T,k),wa.width=ve.width,wa.height=ve.height,v.resizing=wa,v.isResizing=!0;break}case"resizemove":{!se.edges.right&&!se.edges.left&&(B=Oe),!se.edges.top&&!se.edges.bottom&&(w=_e);const Xe=_s(B,w,Oe,_e);S.value?wa.width=v.resizing.width-Xe.deltaX/v.transformScale:wa.width=v.resizing.width+Xe.deltaX/v.transformScale,wa.height=v.resizing.height+Xe.deltaY/v.transformScale,v.resizing=wa;break}case"resizeend":{ve=la(b,$,T,k),wa.width=ve.width,wa.height=ve.height,v.resizing={width:-1,height:-1},v.isResizing=!1;break}}ve=Re(wa.height,wa.width),ve.w<o.minW&&(ve.w=o.minW),ve.w>o.maxW&&(ve.w=o.maxW),ve.h<o.minH&&(ve.h=o.minH),ve.h>o.maxH&&(ve.h=o.maxH),ve.h<1&&(ve.h=1),ve.w<1&&(ve.w=1),B=Oe,w=_e,(T!==ve.w||k!==ve.h)&&s("resize",o.i,ve.h,ve.w,wa.height,wa.width),se.type==="resizeend"&&(V!==T||A!==k)&&s("resized",o.i,ve.h,ve.w,wa.height,wa.width),y.emit("resizeEvent",se.type,o.i,b,$,ve.h,ve.w)}function ee(se){if(o.static||v.isResizing)return;const ma=se.type;if(ma==="dragstart"&&v.isDragging||ma!=="dragstart"&&!v.isDragging)return;const oa=xs(se);if(rn(oa))return;const{x:Oe,y:_e}=oa,wa=se.target;if(!wa.offsetParent)return;const ve={top:0,left:0};switch(ma){case"dragstart":{N=b,Y=$;const aa=wa.offsetParent.getBoundingClientRect(),Pe=wa.getBoundingClientRect(),xa=Pe.left/v.transformScale,Le=aa.left/v.transformScale,va=Pe.right/v.transformScale,re=aa.right/v.transformScale,Ce=Pe.top/v.transformScale,Z=aa.top/v.transformScale;S.value?ve.left=(va-re)*-1:ve.left=xa-Le,ve.top=Ce-Z,v.dragging=ve,v.isDragging=!0;break}case"dragmove":{const aa=_s(x,E,Oe,_e);if(S.value?ve.left=v.dragging.left-aa.deltaX/v.transformScale:ve.left=v.dragging.left+aa.deltaX/v.transformScale,ve.top=v.dragging.top+aa.deltaY/v.transformScale,v.bounded){const Pe=wa.offsetParent.clientHeight-He(o.h,v.rowHeight,v.margin[1]);ve.top=Te(ve.top,0,Pe);const xa=ka(),Le=v.containerWidth-He(o.w,xa,v.margin[0]);ve.left=Te(ve.left,0,Le)}v.dragging=ve;break}case"dragend":{const aa=wa.offsetParent.getBoundingClientRect(),Pe=wa.getBoundingClientRect(),xa=Pe.left/v.transformScale,Le=aa.left/v.transformScale,va=Pe.right/v.transformScale,re=aa.right/v.transformScale,Ce=Pe.top/v.transformScale,Z=aa.top/v.transformScale;S.value?ve.left=(va-re)*-1:ve.left=xa-Le,ve.top=Ce-Z,v.dragging={top:-1,left:-1},v.isDragging=!1;break}}let Xe;S.value,Xe=Ve(ve.top,ve.left),x=Oe,E=_e,(b!==Xe.x||$!==Xe.y)&&s("move",o.i,Xe.x,Xe.y),se.type==="dragend"&&(N!==b||Y!==$)&&s("moved",o.i,Xe.x,Xe.y),y.emit("dragEvent",se.type,o.i,Xe.x,Xe.y,k,T)}function la(se,ma,oa,Oe){const _e=ka();let wa;return S.value?wa={right:Math.round(_e*se+(se+1)*v.margin[0]),top:Math.round(v.rowHeight*ma+(ma+1)*v.margin[1]),width:oa===1/0?oa:Math.round(_e*oa+Math.max(0,oa-1)*v.margin[0]),height:Oe===1/0?Oe:Math.round(v.rowHeight*Oe+Math.max(0,Oe-1)*v.margin[1])}:wa={left:Math.round(_e*se+(se+1)*v.margin[0]),top:Math.round(v.rowHeight*ma+(ma+1)*v.margin[1]),width:oa===1/0?oa:Math.round(_e*oa+Math.max(0,oa-1)*v.margin[0]),height:Oe===1/0?Oe:Math.round(v.rowHeight*Oe+Math.max(0,Oe-1)*v.margin[1])},wa}function Ve(se,ma){const oa=ka();let Oe=Math.round((ma-v.margin[0])/(oa+v.margin[0])),_e=Math.round((se-v.margin[1])/(v.rowHeight+v.margin[1]));return Oe=Math.max(Math.min(Oe,v.cols-T),0),_e=Math.max(Math.min(_e,v.maxRows-k),0),{x:Oe,y:_e}}function ka(){return(v.containerWidth-v.margin[0]*(v.cols+1))/v.cols}function He(se,ma,oa){return Number.isFinite(se)?Math.round(ma*se+Math.max(0,se-1)*oa):se}function Te(se,ma,oa){return Math.max(Math.min(se,oa),ma)}function Re(se,ma,oa=!1){const Oe=ka();let _e=Math.round((ma+v.margin[0])/(Oe+v.margin[0])),wa=0;return oa?wa=Math.ceil((se+v.margin[1])/(v.rowHeight+v.margin[1])):wa=Math.round((se+v.margin[1])/(v.rowHeight+v.margin[1])),_e=Math.max(Math.min(_e,v.cols-b),0),wa=Math.max(Math.min(wa,v.maxRows-$),0),{w:_e,h:wa}}function Ge(se,ma){v.containerWidth=se}function Ga(){pa()}function Fa(){!f.value&&_.value&&(f.value=Es(_.value),v.useStyleCursor||f.value.styleCursor(!1))}const P=gs(ee);function F(){if(Fa(),!!f.value)if(v.draggable&&!o.static){const se={ignoreFrom:o.dragIgnoreFrom,allowFrom:o.dragAllowFrom,...o.dragOption};f.value.draggable(se),m||(m=!0,f.value.on("dragstart dragmove dragend",ma=>{ma.type==="dragmove"?P(ma):ee(ma)}))}else f.value.draggable({enabled:!1})}const J=gs(Wa);function ie(){if(Fa(),!!f.value)if(v.resizable&&!o.static){const se=la(0,0,o.maxW,o.maxH),ma=la(0,0,o.minW,o.minH),oa={edges:{left:S.value?`.${Ne.value[0]}`:!1,right:S.value?!1:`.${Ne.value[0]}`,bottom:`.${Ne.value[0]}`,top:!1},ignoreFrom:o.resizeIgnoreFrom,restrictSize:{min:{height:ma.height*v.transformScale,width:ma.width*v.transformScale},max:{height:se.height*v.transformScale,width:se.width*v.transformScale}},...o.resizeOption};o.preserveAspectRatio&&(oa.modifiers=[Es.modifiers.aspectRatio({ratio:"preserve"})]),f.value.resizable(oa),u||(u=!0,f.value.on("resizestart resizemove resizeend",Oe=>{Oe.type==="resizemove"?J(Oe):Wa(Oe)}))}else f.value.resizable({enabled:!1})}return(se,ma)=>(a.openBlock(),a.createElementBlock("section",{ref_key:"wrapper",ref:_,class:a.normalizeClass(ue.value),style:a.normalizeStyle(v.style)},[a.renderSlot(se.$slots,"default"),oe.value?(a.openBlock(),a.createElementBlock("span",{key:0,class:a.normalizeClass(Ne.value)},null,2)):a.createCommentVNode("",!0)],6))}}),oo=typeof window<"u";var Ss;oo&&(Ss=window==null?void 0:window.navigator)!=null&&Ss.userAgent&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Ds(l){return l!=null}function Ns(){}const q4=Object.freeze({aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"});Object.freeze(new Set(Object.keys(q4)));const W4=oo&&("ontouchstart"in window||Y4()>0),K4=W4?"pointerdown":"click";function Y4(){return typeof navigator<"u"&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)||0}function G4(l,r,n=window.Event){const{type:o,bubbles:s=!1,cancelable:c=!1,...y}=r;if(!Ds(o)||o==="")return!1;let f;return Ds(n)?f=new n(o,{bubbles:s,cancelable:c}):(f=document.createEvent("HTMLEvents"),f.initEvent(o,s,c)),Object.assign(f,y),l.dispatchEvent(f)}const J4="clickoutside",X4=new Set;oo&&document.addEventListener(K4,l=>{const r=l.target,n=l.composedPath&&l.composedPath();X4.forEach(o=>{o!==r&&(n?!n.includes(o):!o.contains(r))&&(!o.__transferElement||o.__transferElement!==r&&!o.__transferElement.contains(r))&&G4(o,{type:J4})})},!0);const Z4=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]];let yi;if(oo){for(const l of Z4)if(l[1]in document){yi=l;break}}a.computed(()=>!1);const Q4=new Set,e6=new WeakMap;if(oo&&yi){const l=yi[2],r=yi[4];document.addEventListener(r,()=>{if(Q4.forEach(n=>{n.value=!1}),document[l]){const n=e6.get(document[l]);n&&(n.value=!0)}},!1)}const $c=new Map;$c.set("x",0);$c.set("y",0);var ro=[],a6=function(){return ro.some(function(l){return l.activeTargets.length>0})},l6=function(){return ro.some(function(l){return l.skippedTargets.length>0})},Bs="ResizeObserver loop completed with undelivered notifications.",r6=function(){var l;typeof ErrorEvent=="function"?l=new ErrorEvent("error",{message:Bs}):(l=document.createEvent("Event"),l.initEvent("error",!1,!1),l.message=Bs),window.dispatchEvent(l)},jo;(function(l){l.BORDER_BOX="border-box",l.CONTENT_BOX="content-box",l.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(jo||(jo={}));var no=function(l){return Object.freeze(l)},n6=function(){function l(r,n){this.inlineSize=r,this.blockSize=n,no(this)}return l}(),Rc=function(){function l(r,n,o,s){return this.x=r,this.y=n,this.width=o,this.height=s,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,no(this)}return l.prototype.toJSON=function(){var r=this,n=r.x,o=r.y,s=r.top,c=r.right,y=r.bottom,f=r.left,v=r.width,m=r.height;return{x:n,y:o,top:s,right:c,bottom:y,left:f,width:v,height:m}},l.fromRect=function(r){return new l(r.x,r.y,r.width,r.height)},l}(),Et=function(l){return l instanceof SVGElement&&"getBBox"in l},Vc=function(l){if(Et(l)){var r=l.getBBox(),n=r.width,o=r.height;return!n&&!o}var s=l,c=s.offsetWidth,y=s.offsetHeight;return!(c||y||l.getClientRects().length)},Ts=function(l){var r;if(l instanceof Element)return!0;var n=(r=l==null?void 0:l.ownerDocument)===null||r===void 0?void 0:r.defaultView;return!!(n&&l instanceof n.Element)},o6=function(l){switch(l.tagName){case"INPUT":if(l.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},Vo=typeof window<"u"?window:{},fi=new WeakMap,As=/auto|scroll/,i6=/^tb|vertical/,t6=/msie|trident/i.test(Vo.navigator&&Vo.navigator.userAgent),En=function(l){return parseFloat(l||"0")},Co=function(l,r,n){return l===void 0&&(l=0),r===void 0&&(r=0),n===void 0&&(n=!1),new n6((n?r:l)||0,(n?l:r)||0)},zs=no({devicePixelContentBoxSize:Co(),borderBoxSize:Co(),contentBoxSize:Co(),contentRect:new Rc(0,0,0,0)}),Pc=function(l,r){if(r===void 0&&(r=!1),fi.has(l)&&!r)return fi.get(l);if(Vc(l))return fi.set(l,zs),zs;var n=getComputedStyle(l),o=Et(l)&&l.ownerSVGElement&&l.getBBox(),s=!t6&&n.boxSizing==="border-box",c=i6.test(n.writingMode||""),y=!o&&As.test(n.overflowY||""),f=!o&&As.test(n.overflowX||""),v=o?0:En(n.paddingTop),m=o?0:En(n.paddingRight),u=o?0:En(n.paddingBottom),x=o?0:En(n.paddingLeft),E=o?0:En(n.borderTopWidth),B=o?0:En(n.borderRightWidth),w=o?0:En(n.borderBottomWidth),V=o?0:En(n.borderLeftWidth),A=x+m,N=v+u,Y=V+B,b=E+w,$=f?l.offsetHeight-b-l.clientHeight:0,T=y?l.offsetWidth-Y-l.clientWidth:0,k=s?A+Y:0,_=s?N+b:0,U=o?o.width:En(n.width)-k-T,W=o?o.height:En(n.height)-_-$,ce=U+A+T+Y,Ee=W+N+$+b,Ie=no({devicePixelContentBoxSize:Co(Math.round(U*devicePixelRatio),Math.round(W*devicePixelRatio),c),borderBoxSize:Co(ce,Ee,c),contentBoxSize:Co(U,W,c),contentRect:new Rc(x,v,U,W)});return fi.set(l,Ie),Ie},Fc=function(l,r,n){var o=Pc(l,n),s=o.borderBoxSize,c=o.contentBoxSize,y=o.devicePixelContentBoxSize;switch(r){case jo.DEVICE_PIXEL_CONTENT_BOX:return y;case jo.BORDER_BOX:return s;default:return c}},s6=function(){function l(r){var n=Pc(r);this.target=r,this.contentRect=n.contentRect,this.borderBoxSize=no([n.borderBoxSize]),this.contentBoxSize=no([n.contentBoxSize]),this.devicePixelContentBoxSize=no([n.devicePixelContentBoxSize])}return l}(),jc=function(l){if(Vc(l))return 1/0;for(var r=0,n=l.parentNode;n;)r+=1,n=n.parentNode;return r},c6=function(){var l=1/0,r=[];ro.forEach(function(c){if(c.activeTargets.length!==0){var y=[];c.activeTargets.forEach(function(f){var v=new s6(f.target),m=jc(f.target);y.push(v),f.lastReportedSize=Fc(f.target,f.observedBox),m<l&&(l=m)}),r.push(function(){c.callback.call(c.observer,y,c.observer)}),c.activeTargets.splice(0,c.activeTargets.length)}});for(var n=0,o=r;n<o.length;n++){var s=o[n];s()}return l},Ms=function(l){ro.forEach(function(r){r.activeTargets.splice(0,r.activeTargets.length),r.skippedTargets.splice(0,r.skippedTargets.length),r.observationTargets.forEach(function(n){n.isActive()&&(jc(n.target)>l?r.activeTargets.push(n):r.skippedTargets.push(n))})})},u6=function(){var l=0;for(Ms(l);a6();)l=c6(),Ms(l);return l6()&&r6(),l>0},nt,Hc=[],d6=function(){return Hc.splice(0).forEach(function(l){return l()})},p6=function(l){if(!nt){var r=0,n=document.createTextNode(""),o={characterData:!0};new MutationObserver(function(){return d6()}).observe(n,o),nt=function(){n.textContent="".concat(r?r--:r++)}}Hc.push(l),nt()},f6=function(l){p6(function(){requestAnimationFrame(l)})},gi=0,h6=function(){return!!gi},v6=250,m6={attributes:!0,characterData:!0,childList:!0,subtree:!0},Os=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],Is=function(l){return l===void 0&&(l=0),Date.now()+l},ot=!1,y6=function(){function l(){var r=this;this.stopped=!0,this.listener=function(){return r.schedule()}}return l.prototype.run=function(r){var n=this;if(r===void 0&&(r=v6),!ot){ot=!0;var o=Is(r);f6(function(){var s=!1;try{s=u6()}finally{if(ot=!1,r=o-Is(),!h6())return;s?n.run(1e3):r>0?n.run(r):n.start()}})}},l.prototype.schedule=function(){this.stop(),this.run()},l.prototype.observe=function(){var r=this,n=function(){return r.observer&&r.observer.observe(document.body,m6)};document.body?n():Vo.addEventListener("DOMContentLoaded",n)},l.prototype.start=function(){var r=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),Os.forEach(function(n){return Vo.addEventListener(n,r.listener,!0)}))},l.prototype.stop=function(){var r=this;this.stopped||(this.observer&&this.observer.disconnect(),Os.forEach(function(n){return Vo.removeEventListener(n,r.listener,!0)}),this.stopped=!0)},l}(),bt=new y6,Ls=function(l){!gi&&l>0&&bt.start(),gi+=l,!gi&&bt.stop()},g6=function(l){return!Et(l)&&!o6(l)&&getComputedStyle(l).display==="inline"},b6=function(){function l(r,n){this.target=r,this.observedBox=n||jo.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return l.prototype.isActive=function(){var r=Fc(this.target,this.observedBox,!0);return g6(this.target)&&(this.lastReportedSize=r),this.lastReportedSize.inlineSize!==r.inlineSize||this.lastReportedSize.blockSize!==r.blockSize},l}(),k6=function(){function l(r,n){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=r,this.callback=n}return l}(),hi=new WeakMap,$s=function(l,r){for(var n=0;n<l.length;n+=1)if(l[n].target===r)return n;return-1},vi=function(){function l(){}return l.connect=function(r,n){var o=new k6(r,n);hi.set(r,o)},l.observe=function(r,n,o){var s=hi.get(r),c=s.observationTargets.length===0;$s(s.observationTargets,n)<0&&(c&&ro.push(s),s.observationTargets.push(new b6(n,o&&o.box)),Ls(1),bt.schedule())},l.unobserve=function(r,n){var o=hi.get(r),s=$s(o.observationTargets,n),c=o.observationTargets.length===1;s>=0&&(c&&ro.splice(ro.indexOf(o),1),o.observationTargets.splice(s,1),Ls(-1))},l.disconnect=function(r){var n=this,o=hi.get(r);o.observationTargets.slice().forEach(function(s){return n.unobserve(r,s.target)}),o.activeTargets.splice(0,o.activeTargets.length)},l}(),x6=function(){function l(r){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof r!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");vi.connect(this,r)}return l.prototype.observe=function(r,n){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Ts(r))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");vi.observe(this,r,n)},l.prototype.unobserve=function(r){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Ts(r))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");vi.unobserve(this,r)},l.prototype.disconnect=function(){vi.disconnect(this)},l.toString=function(){return"function ResizeObserver () { [polyfill code] }"},l}();const Bi=new WeakMap;function _6(l){var r;for(let n=0,o=l.length;n<o;++n){const s=l[n],c=Bi.get(s.target);if(typeof c=="function"){const{inlineSize:y,blockSize:f}=((r=s.borderBoxSize)==null?void 0:r[0])??{},{offsetWidth:v,offsetHeight:m}=s.target;c(Object.assign(s,{offsetWidth:v,offsetHeight:m,width:y??v,height:f??m}))}}}const Uc=new(oo&&window.ResizeObserver||x6)(_6);function Rs(l,r){Bi.set(l,r),Uc.observe(l)}function Vs(l){Bi.has(l)&&(Uc.unobserve(l),Bi.delete(l))}function w6(l={}){let r=Ns;const n=a.watch(()=>a.unref(l.target),s=>{r(),!(!s||typeof l.onResize!="function")&&(Rs(s,l.onResize),r=()=>{Vs(s),r=Ns})},{immediate:!0}),o=()=>{n(),r()};return a.getCurrentScope()&&a.onScopeDispose(o),{observeResize:Rs,unobserveResize:Vs,unobserve:o}}const C6=a.ref(!1);a.computed(()=>C6.value);const Ps="__theme_style__",it="__theme_observer__",Fs=a.reactive(new Map),js=new Map;a.watch(Fs,()=>{if(!oo)return;js.clear();const l=document.head.querySelector(`#${Ps}`);l&&document.head.removeChild(l);const r=document.createElement("style");let n=`.${it} { width: 1px }`,o=1;for(const[s,[c,y]]of Fs.entries())n+=` html.${c} .${it}, .${y} .${it} { width: ${++o}px }`,js.set(o,s);r.textContent=n,r.id=Ps,document.head.appendChild(r)});const qc=a.defineComponent({__name:"grid-layout",props:{autoSize:{type:Boolean,default:!0},colNum:{default:12},rowHeight:{default:150},maxRows:{default:1/0},margin:{default:()=>[10,10]},isDraggable:{type:Boolean,default:!0},isResizable:{type:Boolean,default:!0},isMirrored:{type:Boolean,default:!1},isBounded:{type:Boolean,default:!1},useCssTransforms:{type:Boolean,default:!0},verticalCompact:{type:Boolean,default:!0},restoreOnDrag:{type:Boolean,default:!1},layout:{},responsive:{type:Boolean,default:!1},responsiveLayouts:{default:()=>({})},transformScale:{default:1},breakpoints:{default:()=>({lg:1200,md:996,sm:768,xs:480,xxs:0})},cols:{default:()=>({lg:12,md:10,sm:6,xs:4,xxs:2})},preventCollision:{type:Boolean,default:!1},useStyleCursor:{type:Boolean,default:!0}},emits:["layout-before-mount","layout-mounted","layout-updated","breakpoint-changed","update:layout","layout-ready"],setup(l,{expose:r,emit:n}){const o=l,s=n,c=a.reactive({width:-1,mergedStyle:{},lastLayoutLength:0,isDragging:!1,placeholder:{x:0,y:0,w:0,h:0,i:""},layouts:{},lastBreakpoint:null,originalLayout:null}),y=new Map,f=a.ref(o.layout),v=a.ref(),{observeResize:m,unobserveResize:u}=w6(),x=w4();x.on("resizeEvent",E),x.on("dragEvent",B),a.onBeforeMount(()=>{s("layout-before-mount",f.value)}),a.onMounted(()=>{s("layout-mounted",f.value),a.nextTick(()=>{O4(f.value),c.originalLayout=f.value,a.nextTick(()=>{W(),v.value&&m(v.value,C4(b,16)),ko(f.value,o.verticalCompact),s("layout-updated",f.value),Y(),b()})})}),a.onBeforeUnmount(()=>{x.clearAll(),v.value&&u(v.value)});function E(Ee,Ie,De,ne,ge,X){_(Ee,Ie,De,ne,ge,X)}function B(Ee,Ie,De,ne,ge,X){k(Ee,Ie,De,ne,ge,X)}a.watch(()=>c.width,(Ee,Ie)=>{a.nextTick(()=>{x.emit("updateWidth",Ee),Ie===-1&&a.nextTick(()=>{s("layout-ready",f.value)}),Y()})}),a.watch(()=>[o.layout,o.layout.length],()=>{f.value=o.layout,N()}),a.watch(()=>o.colNum,Ee=>{x.emit("setColNum",Ee)}),a.watch(()=>o.rowHeight,Ee=>{x.emit("setRowHeight",Ee)}),a.watch(()=>o.isDraggable,Ee=>{x.emit("setDraggable",Ee)}),a.watch(()=>o.isResizable,Ee=>{x.emit("setResizable",Ee)}),a.watch(()=>o.isBounded,Ee=>{x.emit("setBounded",Ee)}),a.watch(()=>o.transformScale,Ee=>{x.emit("setTransformScale",Ee)}),a.watch(()=>o.responsive,Ee=>{Ee||(s("update:layout",c.originalLayout),x.emit("setColNum",o.colNum)),b()}),a.watch(()=>o.maxRows,Ee=>{x.emit("setMaxRows",Ee)}),a.watch([()=>o.margin,()=>o.margin[1]],Y),a.provide(Bc,a.reactive({...a.toRefs(o),...a.toRefs(c),increaseItem:w,decreaseItem:V})),a.provide(Tc,x),r({state:c,getItem:A,resizeEvent:_,dragEvent:k,layoutUpdate:N});function w(Ee){y.set(Ee.i,Ee)}function V(Ee){y.delete(Ee.i)}function A(Ee){return y.get(Ee)}function N(){if(!rn(f.value)&&!rn(c.originalLayout)){if(f.value.length!==c.originalLayout.length){const Ee=ce(f.value,c.originalLayout);if(Ee.length>0)if(f.value.length>c.originalLayout.length)c.originalLayout=c.originalLayout.concat(Ee);else{const Ie=new Set(Ee.map(De=>De.i));c.originalLayout=c.originalLayout.filter(De=>!Ie.has(De.i))}c.lastLayoutLength=f.value.length,W()}ko(f.value,o.verticalCompact),x.emit("updateWidth",c.width),Y(),s("layout-updated",f.value)}}function Y(){c.mergedStyle={height:$()}}function b(){v.value&&(c.width=v.value.offsetWidth),x.emit("resizeEvent")}function $(){if(!o.autoSize)return;const Ee=parseFloat(o.margin[1]);return S4(f.value)*(o.rowHeight+Ee)+Ee+"px"}let T;function k(Ee,Ie,De,ne,ge,X){let de=bs(f.value,Ie);rn(de)&&(de={h:0,w:0,x:0,y:0,i:""}),Ee==="dragstart"&&!o.verticalCompact&&(T=f.value.reduce((Ke,{i:Ta,x:oe,y:S})=>({...Ke,[Ta]:{x:oe,y:S}}),{})),Ee==="dragmove"||Ee==="dragstart"?(c.placeholder.i=Ie,c.placeholder.x=de.x,c.placeholder.y=de.y,c.placeholder.w=X,c.placeholder.h=ge,a.nextTick(()=>{c.isDragging=!0}),x.emit("updateWidth",c.width)):a.nextTick(()=>{c.isDragging=!1}),f.value=gt(f.value,de,De,ne,!0,o.preventCollision),o.restoreOnDrag?(de.static=!0,ko(f.value,o.verticalCompact,T),de.static=!1):ko(f.value,o.verticalCompact),x.emit("compact"),Y(),Ee==="dragend"&&(T=void 0,s("layout-updated",f.value))}function _(Ee,Ie,De,ne,ge,X){let de=bs(f.value,Ie);rn(de)&&(de={h:0,w:0,x:0,y:0,i:""});let Ke;if(o.preventCollision){const Ta=zc(f.value,{...de,w:X,h:ge}).filter(oe=>oe.i!==de.i);if(Ke=Ta.length>0,Ke){let oe=1/0,S=1/0;Ta.forEach(le=>{le.x>de.x&&(oe=Math.min(oe,le.x)),le.y>de.y&&(S=Math.min(S,le.y))}),Number.isFinite(oe)&&(de.w=oe-de.x),Number.isFinite(S)&&(de.h=S-de.y)}}Ke||(de.w=X,de.h=ge),Ee==="resizestart"||Ee==="resizemove"?(c.placeholder.i=Ie,c.placeholder.x=De,c.placeholder.y=ne,c.placeholder.w=de.w,c.placeholder.h=de.h,a.nextTick(()=>{c.isDragging=!0}),x.emit("updateWidth",c.width)):Ee&&a.nextTick(()=>{c.isDragging=!1}),o.responsive&&U(),ko(f.value,o.verticalCompact),x.emit("compact"),Y(),Ee==="resizeend"&&s("layout-updated",f.value)}function U(){const Ee=R4(o.breakpoints,c.width);if(Ee===c.lastBreakpoint)return;const Ie=Ic(Ee,o.cols);!rn(c.lastBreakpoint)&&!c.layouts[c.lastBreakpoint]&&(c.layouts[c.lastBreakpoint]=yt(f.value));const De=V4(c.originalLayout,c.layouts,o.breakpoints,Ee,c.lastBreakpoint,Ie,o.verticalCompact);c.layouts[Ee]=De,c.lastBreakpoint!==Ee&&s("breakpoint-changed",Ee,De),f.value=De,s("update:layout",De),c.lastBreakpoint=Ee,x.emit("setColNum",Ie)}function W(){c.layouts=Object.assign({},o.responsiveLayouts)}function ce(Ee,Ie){const De=new Set(Ie.map(de=>de.i)),ne=new Set(Ee.map(de=>de.i)),ge=Ee.filter(de=>!De.has(de.i)),X=Ie.filter(de=>!ne.has(de.i));return ge.concat(X)}return(Ee,Ie)=>(a.openBlock(),a.createElementBlock("div",{ref_key:"wrapper",ref:v,class:"vgl-layout",style:a.normalizeStyle(c.mergedStyle)},[Ee.$slots.default?a.renderSlot(Ee.$slots,"default",{key:0}):(a.openBlock(!0),a.createElementBlock(a.Fragment,{key:1},a.renderList(f.value,De=>(a.openBlock(),a.createBlock(Ni,a.mergeProps({key:De.i,ref_for:!0},De),{default:a.withCtx(()=>[a.renderSlot(Ee.$slots,"item",{item:De})]),_:2},1040))),128)),a.withDirectives(a.createVNode(Ni,{class:"vgl-item--placeholder",x:c.placeholder.x,y:c.placeholder.y,w:c.placeholder.w,h:c.placeholder.h,i:c.placeholder.i},null,8,["x","y","w","h","i"]),[[a.vShow,c.isDragging]])],4))}});(function(){try{if(typeof document<"u"){var l=document.createElement("style");l.appendChild(document.createTextNode('.vgl-layout{--vgl-placeholder-bg: red;--vgl-placeholder-opacity: 20%;--vgl-placeholder-z-index: 2;--vgl-item-resizing-z-index: 3;--vgl-item-resizing-opacity: 60%;--vgl-item-dragging-z-index: 3;--vgl-item-dragging-opacity: 100%;--vgl-resizer-size: 10px;--vgl-resizer-border-color: #444;--vgl-resizer-border-width: 2px;position:relative;box-sizing:border-box;transition:height .2s ease}.vgl-item{position:absolute;box-sizing:border-box;transition:.2s ease;transition-property:left,top,right}.vgl-item--placeholder{z-index:var(--vgl-placeholder-z-index, 2);-webkit-user-select:none;-moz-user-select:none;user-select:none;background-color:var(--vgl-placeholder-bg, red);opacity:var(--vgl-placeholder-opacity, 20%);transition-duration:.1s}.vgl-item--no-touch{touch-action:none}.vgl-item--transform{right:auto;left:0;transition-property:transform}.vgl-item--transform.vgl-item--rtl{right:0;left:auto}.vgl-item--resizing{z-index:var(--vgl-item-resizing-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-resizing-opacity, 60%)}.vgl-item--dragging{z-index:var(--vgl-item-dragging-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-dragging-opacity, 100%);transition:none}.vgl-item__resizer{position:absolute;right:0;bottom:0;box-sizing:border-box;width:var(--vgl-resizer-size);height:var(--vgl-resizer-size);cursor:se-resize}.vgl-item__resizer:before{position:absolute;top:0;right:3px;bottom:3px;left:0;content:"";border:0 solid var(--vgl-resizer-border-color);border-right-width:var(--vgl-resizer-border-width);border-bottom-width:var(--vgl-resizer-border-width)}.vgl-item__resizer--rtl{right:auto;left:0;cursor:sw-resize}.vgl-item__resizer--rtl:before{top:0;right:0;bottom:3px;left:3px;border-right-width:0;border-bottom-width:var(--vgl-resizer-border-width);border-left-width:var(--vgl-resizer-border-width)}')),document.head.appendChild(l)}}catch(r){console.error("vite-plugin-css-injected-by-js",r)}})();const E6={key:0,class:"item-view-group"},S6={key:0,class:"item-view-group"},D6=a.defineComponent({__name:"index",props:{children:{type:Object,default:()=>{}},level:{type:Number,default:1}},emits:["rowClick","routeUrl","radioChange"],setup(l,{emit:r}){const n=I.useModelComp(I.pinia),{isEdit:o}=I.storeToRefs(n),s=Wn(I.pinia),c=r,y=l,f=a.ref(""),v=a.computed(()=>y==null?void 0:y.children),m=a.computed(()=>{var N,Y,b,$;return((N=y==null?void 0:y.children)==null?void 0:N.length)>0&&((Y=y==null?void 0:y.children)!=null&&Y.every(T=>T==null?void 0:T.layout))?($=(b=y==null?void 0:y.children)==null?void 0:b[0])==null?void 0:$.layout:"vertical"}),u=N=>{f.value=N,c("radioChange",N)},x=a.computed(()=>{var N,Y;return((Y=(N=y==null?void 0:y.children)==null?void 0:N[0])==null?void 0:Y.isGridLayout)||!1}),E=a.ref((y==null?void 0:y.level)+1),B=a.computed(()=>{if(!(y!=null&&y.children)||!Array.isArray(y.children)||y.children.length<2)return!1;const N=y.children.some(b=>(b==null?void 0:b.name)==="测量系统配置表"&&(b==null?void 0:b.comp)==="ParentItem"),Y=y.children.some(b=>(b==null?void 0:b.name)==="测量系统传递表"&&(b==null?void 0:b.comp)==="ParentItem");return N&&Y}),w=a.computed(()=>{var Y,b,$,T,k,_;let N=(Y=y==null?void 0:y.children)==null?void 0:Y.filter(U=>U==null?void 0:U.choice);if(s.setSelectTab((b=N==null?void 0:N[0])==null?void 0:b.choiceName),(f==null?void 0:f.value)!=="")return($=y==null?void 0:y.children)==null?void 0:$.filter(U=>!(U!=null&&U.choiceName)||(U==null?void 0:U.choiceName)===(f==null?void 0:f.value));{let U=(k=(T=y==null?void 0:y.children)==null?void 0:T.find(W=>W==null?void 0:W.choice))==null?void 0:k.choiceName;return(_=y==null?void 0:y.children)==null?void 0:_.filter(W=>!(W!=null&&W.choiceName)||(W==null?void 0:W.choiceName)===U)}});a.watch(()=>y==null?void 0:y.children,()=>{B.value},{deep:!0});const V=N=>{c("rowClick",N)},A=(N,Y)=>{c("routeUrl",N,Y)};return(N,Y)=>x.value?(a.openBlock(),a.createBlock(a.unref(qc),{key:0,layout:v.value,"onUpdate:layout":Y[0]||(Y[0]=b=>v.value=b),"is-draggable":a.unref(o)==="edit","is-resizable":a.unref(o)==="edit","col-num":24,margin:[8,16]},{default:a.withCtx(()=>[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(v.value,(b,$)=>(a.openBlock(),a.createBlock(a.unref(Ni),{key:b.i,x:b.x,y:b.y,"min-h":b.minH,"max-h":b.maxH,"min-w":b.minW,w:b.w,h:b.h,i:b.i},{default:a.withCtx(()=>{var T,k,_,U,W,ce,Ee,Ie,De,ne,ge,X,de,Ke;return[a.createElementVNode("div",{style:a.normalizeStyle({gap:"16px",display:"flex",flexDirection:"column",paddingBottom:$===((T=y==null?void 0:y.children)==null?void 0:T.length)-1?"0px":"24px"})},[((_=(k=b==null?void 0:b.component)==null?void 0:k.comp)==null?void 0:_.toUpperCase())!=="TABLE"&&((U=b==null?void 0:b.component)!=null&&U.name)?(a.openBlock(),a.createElementBlock("div",E6,[a.createElementVNode("div",{class:"group-name-wrap",style:a.normalizeStyle({paddingLeft:(parseInt(E.value.toString())-1)*12+"px",fontWeight:600-(E.value-1)*100>=400?600-(E.value-1)*100:400,fontSize:17-E.value>=14?17-E.value+"px":"14px"})},a.toDisplayString((W=b==null?void 0:b.component)==null?void 0:W.name),5)])):a.createCommentVNode("",!0),(a.openBlock(),a.createBlock(a.resolveDynamicComponent(a.unref(Fo)((ce=b==null?void 0:b.component)==null?void 0:ce.comp)),{pageLayout:m.value,config:{showIndex:(Ee=a.unref(er)[$])==null?void 0:Ee.showIndex,allowMove:(Ie=a.unref(er)[$])==null?void 0:Ie.allowMove,viewport:(De=a.unref(er)[$])==null?void 0:De.viewport,status:(ne=a.unref(er)[$])==null?void 0:ne.status},related:b==null?void 0:b.relatedTables,compName:b==null?void 0:b.component.name,compNames:a.unref(uc),itemData:(ge=b==null?void 0:b.component)==null?void 0:ge.compData,childItemData:(X=b==null?void 0:b.component)==null?void 0:X.itemChildData,key:a.unref(qn),cacheNewData:a.unref(cc),onChange:a.unref(Ci),index:(b==null?void 0:b.id)??$,onContentChange:a.unref(Ei),onPageChange:a.unref(Si),parentTableId:(de=b==null?void 0:b.component)==null?void 0:de.tableId,allMapContents:a.unref(ht),children:(Ke=b==null?void 0:b.component)==null?void 0:Ke.children,level:E.value,onRowClick:V,onRouteUrl:A,onClickTrigger:a.unref(dc),onClickMainKey:a.unref(pc),onRadioChange:u},null,40,["pageLayout","config","related","compName","compNames","itemData","childItemData","cacheNewData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level","onClickTrigger","onClickMainKey"]))],4)]}),_:2},1032,["x","y","min-h","max-h","min-w","w","h","i"]))),128))]),_:1},8,["layout","is-draggable","is-resizable"])):(a.openBlock(!0),a.createElementBlock(a.Fragment,{key:1},a.renderList(w.value,(b,$)=>{var T,k;return a.openBlock(),a.createElementBlock("div",{style:a.normalizeStyle({gap:"16px",display:(b==null?void 0:b.isShow)===!1?"none":"flex",flexDirection:"column",paddingBottom:parseInt($)===((T=y==null?void 0:y.children)==null?void 0:T.length)-1?"0px":"24px"})},[((k=b==null?void 0:b.comp)==null?void 0:k.toUpperCase())!=="TABLE"&&b.name?(a.openBlock(),a.createElementBlock("div",S6,[a.createElementVNode("div",{class:"group-name-wrap",style:a.normalizeStyle({paddingLeft:parseInt(E.value.toString())>1?"12px":"0px",fontWeight:600-(E.value-1)*100>=400?600-(E.value-1)*100:400,fontSize:17-E.value>=14?17-E.value+"px":"14px"})},a.toDisplayString(b.name),5)])):a.createCommentVNode("",!0),(a.openBlock(),a.createBlock(a.resolveDynamicComponent(a.unref(Fo)(b.comp)),{compName:b.name,config:{showIndex:b==null?void 0:b.showIndex,allowMove:b==null?void 0:b.allowMove,viewport:b==null?void 0:b.viewport,status:b==null?void 0:b.status},itemData:b==null?void 0:b.compData,related:b==null?void 0:b.relatedTables,childItemData:b==null?void 0:b.itemChildData,key:a.unref(qn),onChange:a.unref(Ci),index:(b==null?void 0:b.id)??$,onContentChange:a.unref(Ei),onPageChange:a.unref(Si),parentTableId:b==null?void 0:b.tableId,allMapContents:a.unref(ht),children:b==null?void 0:b.children,level:E.value,onRowClick:V,onRouteUrl:A,onRadioChange:u},null,40,["compName","config","itemData","related","childItemData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level"]))],4)}),256))}}),N6=ql._export_sfc(D6,[["__scopeId","data-v-822d7221"]]),B6={class:"radio-group-container"},T6=a.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},emits:["radioChange"],setup(l,{emit:r}){const n=l,o=r,s=a.ref(),c=Wn(I.pinia),{selectTab:y}=I.storeToRefs(c);a.watch(()=>n==null?void 0:n.itemData,()=>{s.value=y.value},{immediate:!0,deep:!0});const f=v=>{s.value=v,o("radioChange",s.value)};return(v,m)=>(a.openBlock(),a.createElementBlock("div",B6,[a.createVNode(pl.ssRadio,{modelValue:s.value,"onUpdate:modelValue":m[0]||(m[0]=u=>s.value=u),content:n==null?void 0:n.itemData,onChange:f},null,8,["modelValue","content"])]))}}),A6=ql._export_sfc(T6,[["__scopeId","data-v-177d64c3"]]),Wc=a.ref([{name:"表格",type:"table",comp:"Table",icon:"Table"},{name:"表单",type:"form",comp:"Form",icon:"Form"},{name:"折叠",type:"fold",comp:"Fold",icon:"Fold"},{name:"头像",type:"avatar",comp:"AvatarUpload",icon:"Avatar"},{name:"签名",type:"signature",comp:"Signature",icon:"Signature"},{name:"步骤条",type:"step",comp:"Step",icon:"Step"},{name:"时间线",type:"timeLine",comp:"TimeLine",icon:"TimeLine"},{name:"标签页",type:"tabs",comp:"Tabs",icon:"Tabs"},{name:"图表",type:"chart",comp:"Chart",icon:"chart-new"},{name:"行内布局",type:"layout",comp:"Layout",icon:"ai13"}]),z6={TABLE:mc,FORM:hs,STATICFORM:yc,TABLEOPERATE:E1,TABLESTYLE:F1,TABLEEXTEND:H1,TABLEINTERACTION:W1,FORMOPERATE:vs,FOLD:_2,CALCULATOR:N2,METHODBUTTON:A2,AVATARUPLOAD:Jt.ssAvatar,SIGNATURE:Jt.ssSignature,FORMTOP:hs,STEP:H2,STEPOPERATE:f2,TIMELINE:G2,TIMELINEOPERATE:b2,FORMTOPOPERATE:vs,SIGNATUREOPERATE:P2,AVATARUPLOADOPERATE:O2,TABS:Z2,TABSOPERATE:$h,CHART:Xh,CHARTOPERATE:s4,LAYOUT:d4,LAYOUTOPERATE:k4,PARENTITEM:N6,RADIO:A6};function Do(l){return z6[l==null?void 0:l.toUpperCase()]||null}exports.De=qc;exports.activeStepInfo=xo;exports.addContents=Po;exports.addVisibleDialog=wt;exports.affixItems=Qf;exports.allMapContents=ht;exports.analyzeFilter=_o;exports.analyzeForm=Bd;exports.analyzeQuoteForm=Nd;exports.analyzeTable=Ad;exports.cacheNewData=cc;exports.clickMainKey=pc;exports.clickSavePage=Zf;exports.clickStep=hc;exports.clickTrigger=dc;exports.compId=qn;exports.compNames=uc;exports.compShow=So;exports.createRobotContent=lc;exports.existLayouts=t0;exports.fixChangeValue=kt;exports.generateLayouts=$1;exports.getComponent=Do;exports.getComponents=Fo;exports.getPageData=Vr;exports.getSliceContLength=f0;exports.gridRowHeight=z1;exports.isStepLayout=vc;exports.onBack=Jf;exports.onButtonChange=r0;exports.onChange=Ci;exports.onClick=Xf;exports.onClickStep=s0;exports.onContentChange=Ei;exports.onExtendTaskEnd=i0;exports.onOk=n0;exports.onPageBack=u0;exports.onPageChange=Si;exports.onSelectFixContent=Gf;exports.renderShowItems=tc;exports.robotFile=Ef;exports.showItems=er;exports.sliceTableLength=sc;exports.slotContent=Wc;exports.ssTable=mc;exports.st=Ni;exports.stepItems=h0;exports.tabChange=c0;exports.toolBar=o0;exports.useFormComp=xt;exports.useModelLoader=Jp;exports.verifyButton=d0;