ss-component-new 1.1.821 → 1.1.822
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{OrbitControls-D6pgin7s.js → OrbitControls-Cm4Xs_Bq.js} +1 -1
- package/dist/{OrbitControls-Ff5ikkUQ.cjs → OrbitControls-D-XDZGf-.cjs} +1 -1
- package/dist/{STLLoader-BNh7D2zV.cjs → STLLoader-BxpEhvEg.cjs} +161 -161
- package/dist/{STLLoader-LGKv5i3H.js → STLLoader-DofhZbOw.js} +522 -593
- package/dist/{array-D1hKYLwI.cjs → array-Bfmx0w6P.cjs} +2 -2
- package/dist/{array-C60T9pDZ.js → array-DbAuNWGt.js} +1 -1
- package/dist/{iconfont-v9CcCMwF.js → iconfont-DQodgJo8.js} +73 -75
- package/dist/iconfont-Di4uXnX1.cjs +1 -0
- package/dist/icons/svg/editTable.svg +1 -1
- package/dist/icons/svg/export.svg +1 -0
- package/dist/icons/svg/model.svg +1 -0
- package/dist/icons/svg/three.svg +1 -0
- package/dist/index-1i-XlS2m.js +101 -0
- package/dist/{index-BdsJiFeW.cjs → index-6jSC3unU.cjs} +1 -1
- package/dist/{index-2kzGjuzu.js → index-6zbHinQ6.js} +10 -9
- package/dist/index-B-oe2x1V.cjs +109 -0
- package/dist/index-B-qent3l.cjs +1 -0
- package/dist/{index-CukZ8eDZ.js → index-BBo52W9F.js} +4 -4
- package/dist/index-BOev8isw.cjs +21 -0
- package/dist/index-BQgnYD51.js +6492 -0
- package/dist/{index-owcnOlVq.js → index-BYW-ix_Q.js} +5 -5
- package/dist/{index-4_M1SpeV.js → index-Bi1gr72d.js} +14 -14
- package/dist/{index-DnVaHi8q.js → index-BmHmnXS9.js} +7 -7
- package/dist/index-BoS30LXH.cjs +1 -0
- package/dist/index-BuBMi9JA.cjs +1 -0
- package/dist/{index-Zi9xLtwj.js → index-BvE05H-i.js} +2 -2
- package/dist/index-BwpOMKef.cjs +1 -0
- package/dist/index-C18ZPRC7.cjs +1 -0
- package/dist/{index-HVJSfh2g.js → index-CJx2DcDb.js} +21 -19
- package/dist/{index-B3cUSGXB.js → index-CL59qQ_W.js} +9 -8
- package/dist/{index-DDsJpzfR.js → index-CLdN0W98.js} +47 -47
- package/dist/index-CPP7L10q.cjs +1 -0
- package/dist/index-CSWIBSmo.cjs +1 -0
- package/dist/{index-DEobyz7r.js → index-CTgZZ96L.js} +6 -5
- package/dist/{index-WXpPDsev.js → index-CZ1ui4mT.js} +1 -1
- package/dist/index-CfQvGqaX.cjs +1 -0
- package/dist/index-CgJYAzeA.cjs +1 -0
- package/dist/index-ChtmIuBu.js +29771 -0
- package/dist/index-CjFcaJcL.cjs +1 -0
- package/dist/index-CjTmkzBO.js +24 -0
- package/dist/{index-Dtw4WkUo.cjs → index-CngO0AUc.cjs} +1 -1
- package/dist/index-CqCPdyGu.js +1248 -0
- package/dist/index-Cr6pWv0l.cjs +1 -0
- package/dist/{index-Cw95lvvp.js → index-D8Msszln.js} +223 -223
- package/dist/index-DDvUG6fk.js +22 -0
- package/dist/{index-CdMrhxHS.js → index-DMlIMlyC.js} +10 -10
- package/dist/{index-3Cdyqd1B.cjs → index-DOBeGYzT.cjs} +1 -1
- package/dist/index-DP0k43fj.cjs +1 -0
- package/dist/index-DTxccgVM.cjs +1 -0
- package/dist/{index-JAJeIBYE.cjs → index-DVAGljX0.cjs} +1 -1
- package/dist/{index-B5Vi6RBj.cjs → index-DVCrYVKw.cjs} +1 -1
- package/dist/{index-Dxoxm0Cc.js → index-DZWNGFC0.js} +22 -22
- package/dist/{index-CY2iphpd.cjs → index-DbniLh9G.cjs} +1 -1
- package/dist/index-Dj_ofPeK.cjs +1 -0
- package/dist/{index-DtogzZej.js → index-DocnYz5P.js} +1 -1
- package/dist/index-DrL7vroa.js +319 -0
- package/dist/index-Dt2McMki.js +13668 -0
- package/dist/{index-Cphx1eY1.js → index-Gba1Qfcc.js} +7 -8
- package/dist/{index-DMb9Vu-7.js → index-IUkCD4R_.js} +1 -1
- package/dist/{index-DAyzDsjs.js → index-K6BRW_Bw.js} +1 -1
- package/dist/{index-DzM8zZqe.js → index-OH9t-y2p.js} +4 -4
- package/dist/index-PNDdZKYG.cjs +1 -0
- package/dist/{index-Dn04IPFM.js → index-QETLKFyV.js} +10 -10
- package/dist/{index-BWHtpT9o.cjs → index-RgTvyK54.cjs} +1 -1
- package/dist/{index-Cuj-fGNO.cjs → index-VAIU8vMN.cjs} +1 -1
- package/dist/{index-CF_0RdqV.cjs → index-dukFqRog.cjs} +1 -1
- package/dist/{index-C9Boo2Cw.cjs → index-dyoOdMKX.cjs} +1 -1
- package/dist/index-f9bwREQl.cjs +1 -0
- package/dist/index-rPc9VS0S.cjs +1 -0
- package/dist/index-tPamnhR2.js +236 -0
- package/dist/{index-H3kf9EQv.js → index-tX2Hs05F.js} +11 -10
- package/dist/{index-DEU-pXeW.js → index-uvns6W6E.js} +1838 -1812
- package/dist/index-weauvEnW.cjs +4 -0
- package/dist/{index-B8xEed7C.cjs → index-wlnPb2aB.cjs} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-iyZtrhDf.js → index.vue_vue_type_script_setup_true_lang-C4G6mB7R.js} +28 -28
- package/dist/{index.vue_vue_type_script_setup_true_lang-CaYQQb8M.cjs → index.vue_vue_type_script_setup_true_lang-CWi4UVPF.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-qefZ9E5G.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CtN9Ij0Y.js} +53 -23
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CTcahF4Z.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-mQIxU0SD.cjs} +90 -90
- package/dist/{index.vue_vue_type_style_index_0_scoped_6bfd62db_lang-Cxjh1E1z.js → index.vue_vue_type_style_index_0_scoped_1966237d_lang-D3xcEtDT.js} +6488 -6474
- package/dist/{index.vue_vue_type_style_index_0_scoped_6bfd62db_lang-0eNHRdYw.cjs → index.vue_vue_type_style_index_0_scoped_1966237d_lang-DwIFJsxs.cjs} +14 -14
- package/dist/{index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-kymzIBO8.js → index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-D5CTJUDi.js} +17 -17
- package/dist/{index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-GlR2V0TC.cjs → index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-VPQBXOPW.cjs} +1 -1
- package/dist/index.vue_vue_type_style_index_1_lang-DraQDAAw.cjs +32 -0
- package/dist/index.vue_vue_type_style_index_1_lang-hffXwR3x.js +7028 -0
- package/dist/isUndefined-4Qg9wncf.js +84 -0
- package/dist/isUndefined-BEt4O79g.cjs +1 -0
- package/dist/{main-C6I42yaU.js → main-CBCk94h5.js} +30 -29
- package/dist/main-DO_PN7jt.cjs +1 -0
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +2 -2
- package/dist/ss-component.js +11 -11
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +12 -12
- package/dist/threeModel-GKSAzHfe.cjs +1 -0
- package/dist/{threeModel-BEt5OVCP.js → threeModel-RJwJMtfW.js} +91 -92
- package/dist/{threePreview-BUZRvBRx.js → threePreview-BSqdALPK.js} +3 -3
- package/dist/{threePreview-Dyzqu5s7.cjs → threePreview-CKvbwCiX.cjs} +1 -1
- package/dist/threeSceneView-BVbVe_Et.js +1277 -0
- package/dist/threeSceneView-KvCERteS.cjs +5 -0
- package/dist/{threeViewerHost-IhSFkCeD.js → threeViewerHost-AuhfL2Cn.js} +55 -57
- package/dist/threeViewerHost-D0pu5wk5.cjs +1 -0
- package/package.json +1 -1
- package/public/icons/svg/editTable.svg +1 -1
- package/public/icons/svg/export.svg +1 -0
- package/public/icons/svg/model.svg +1 -0
- package/public/icons/svg/three.svg +1 -0
- package/dist/animationData-B2T3Oamw.js +0 -108
- package/dist/animationData-Db_9HBoM.cjs +0 -1
- package/dist/iconfont-CZj6ltAs.cjs +0 -1
- package/dist/index-2KKrCkl8.cjs +0 -1
- package/dist/index-2OWkrGDh.js +0 -24
- package/dist/index-B1iXzkUF.cjs +0 -1
- package/dist/index-BBB4VObc.cjs +0 -11
- package/dist/index-BIVWMqJQ.cjs +0 -1
- package/dist/index-BWpZSzL1.cjs +0 -1
- package/dist/index-BllULnvx.cjs +0 -1
- package/dist/index-BvO1uTn0.js +0 -21
- package/dist/index-C2bI4adc.js +0 -8628
- package/dist/index-C9pN8_un.js +0 -548
- package/dist/index-CPdKWCSo.cjs +0 -1
- package/dist/index-CQfFbeTJ.cjs +0 -1
- package/dist/index-CZJOPfp5.js +0 -1152
- package/dist/index-Cb0q1Y5b.cjs +0 -1
- package/dist/index-Cfomm0G1.cjs +0 -109
- package/dist/index-CvvFU_QA.cjs +0 -1
- package/dist/index-DYMLmifU.cjs +0 -1
- package/dist/index-DfPyuGyq.js +0 -101
- package/dist/index-Dm2qfeUm.cjs +0 -1
- package/dist/index-DtX1F0sz.cjs +0 -4
- package/dist/index-Du3VUDcF.cjs +0 -1
- package/dist/index-VWNqRYy9.js +0 -36270
- package/dist/index-kmj8K3JX.cjs +0 -1
- package/dist/index-ndZw4AQJ.cjs +0 -1
- package/dist/index-y5FEcncv.cjs +0 -1
- package/dist/index.vue_vue_type_style_index_1_lang-Bmwy3cgo.cjs +0 -42
- package/dist/index.vue_vue_type_style_index_1_lang-Rs1M3B8e.js +0 -11984
- package/dist/main-2gDZp_zL.cjs +0 -1
- package/dist/threeModel-DgOcIXVI.cjs +0 -1
- package/dist/threeSceneView-BZx98QgN.js +0 -1450
- package/dist/threeSceneView-DSkGJN5d.cjs +0 -5
- package/dist/threeViewerHost-T_51aUg5.cjs +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { defineAsyncComponent as te, computed as P, onMounted as
|
|
2
|
-
import {
|
|
3
|
-
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
4
|
-
import {
|
|
5
|
-
import { s as me } from "./index-
|
|
1
|
+
import { defineAsyncComponent as te, computed as P, onMounted as V, resolveComponent as se, createBlock as N, openBlock as U, withCtx as re, resolveDynamicComponent as ne, defineComponent as oe, defineProps as le, ref as M, watch as ae, reactive as ue } from "vue";
|
|
2
|
+
import { bt as ce, p as ie, s as pe, bu as ge, g as ve } from "./index-Dt2McMki.js";
|
|
3
|
+
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CtN9Ij0Y.js";
|
|
4
|
+
import { u as fe, a as he, E as Me } from "./index.vue_vue_type_style_index_1_lang-hffXwR3x.js";
|
|
5
|
+
import { s as me } from "./index-uvns6W6E.js";
|
|
6
6
|
import { useRouter as ye } from "vue-router";
|
|
7
7
|
import { a as Ce, e as de, f as Ae } from "./index-CT5lsL4r.js";
|
|
8
|
-
import { g as we } from "./index-
|
|
9
|
-
const F = te(() => import("./index-
|
|
8
|
+
import { g as we } from "./index-BQgnYD51.js";
|
|
9
|
+
const F = te(() => import("./index-uvns6W6E.js").then((p) => p.l));
|
|
10
10
|
F.install = (p) => {
|
|
11
11
|
p.component("ssMenu", F);
|
|
12
12
|
};
|
|
@@ -16,8 +16,8 @@ const ke = {
|
|
|
16
16
|
name: String
|
|
17
17
|
},
|
|
18
18
|
setup(p) {
|
|
19
|
-
const u = p, w = P(() =>
|
|
20
|
-
return
|
|
19
|
+
const u = p, w = P(() => ce[u.name]);
|
|
20
|
+
return V(() => {
|
|
21
21
|
}), (k, g) => {
|
|
22
22
|
const S = se("el-icon");
|
|
23
23
|
return U(), N(S, null, {
|
|
@@ -41,7 +41,7 @@ const ke = {
|
|
|
41
41
|
type: String,
|
|
42
42
|
default: "vertical"
|
|
43
43
|
}
|
|
44
|
-
}), u =
|
|
44
|
+
}), u = fe(), w = he(ie), k = M(0), g = ye(), { asideMenus: S, menuTriggerType: W, platform: $ } = pe(u), z = P(() => p == null ? void 0 : p.mode), b = P(() => {
|
|
45
45
|
let e = [...S.value];
|
|
46
46
|
if ((e == null ? void 0 : e.length) === 0)
|
|
47
47
|
return g.push("/"), [];
|
|
@@ -50,8 +50,8 @@ const ke = {
|
|
|
50
50
|
}), H = async (e) => {
|
|
51
51
|
w.setRouteToChildPath(""), u.setMenuTriggerType("click"), u.setActiveMenuPath(e == null ? void 0 : e.path), u.setActiveAsideMenu(e), e.isRouter ? g.push(e.path) : g.push("/");
|
|
52
52
|
}, J = async (e) => {
|
|
53
|
-
const t =
|
|
54
|
-
u.setActiveAsideMenu(t), w.setRouteToChildPath(""),
|
|
53
|
+
const t = ge(b.value, "path", e);
|
|
54
|
+
u.setActiveAsideMenu(t), w.setRouteToChildPath(""), W.value === "click" ? k.value === 1 ? u.setActiveMenuPath(sessionStorage.getItem("pageKey")) : u.setActiveMenuPath(e) : (u.setMenuTriggerType("click"), u.setActiveMenuPath(e)), e != null && e.startsWith("/") ? g.push(e) : g.push("/"), k.value++;
|
|
55
55
|
}, K = (e) => {
|
|
56
56
|
u.setActiveMenuPath(e);
|
|
57
57
|
}, T = (e) => {
|
|
@@ -60,14 +60,14 @@ const ke = {
|
|
|
60
60
|
t.style.setProperty(o.name, o.value);
|
|
61
61
|
});
|
|
62
62
|
};
|
|
63
|
-
|
|
63
|
+
V(() => {
|
|
64
64
|
k.value = 1;
|
|
65
65
|
});
|
|
66
66
|
const L = P(() => {
|
|
67
67
|
const e = sessionStorage.getItem("authority");
|
|
68
68
|
return e ? JSON.parse(e) : [];
|
|
69
69
|
});
|
|
70
|
-
ae(() =>
|
|
70
|
+
ae(() => $.value, (e) => {
|
|
71
71
|
e === "browser" ? T(Ce) : e === "client" && (T(de), T(Ae));
|
|
72
72
|
}, { immediate: !0 });
|
|
73
73
|
const j = (e, t) => {
|
|
@@ -99,7 +99,7 @@ const ke = {
|
|
|
99
99
|
var y, h, B;
|
|
100
100
|
if (!(e != null && e.structureIds) || ((y = e == null ? void 0 : e.structureIds) == null ? void 0 : y.length) === 0) return;
|
|
101
101
|
const l = (B = (h = e == null ? void 0 : e.structureIds) == null ? void 0 : h.filter((r) => (r == null ? void 0 : r.key) === "dialogConfig")) == null ? void 0 : B.map((r) => r == null ? void 0 : r.id);
|
|
102
|
-
let s = l == null ? void 0 : l.map((r) =>
|
|
102
|
+
let s = l == null ? void 0 : l.map((r) => ve({ id: r }));
|
|
103
103
|
const a = await Promise.all(s);
|
|
104
104
|
if (a == null ? void 0 : a.every((r) => {
|
|
105
105
|
var n;
|
|
@@ -144,7 +144,7 @@ const ke = {
|
|
|
144
144
|
data: e
|
|
145
145
|
}), u.setIsRefreshMenus(!0);
|
|
146
146
|
}, Z = async (e, t) => {
|
|
147
|
-
i.type = Y(t == null ? void 0 : t.operateType), await X(t, i.type, e), v.value = e, x.value = t, (t == null ? void 0 : t.operateType) !== "删除" ? (i.show = (t == null ? void 0 : t.trigger) === "openDialog", i.title = (t == null ? void 0 : t.operateType) + "菜单") :
|
|
147
|
+
i.type = Y(t == null ? void 0 : t.operateType), await X(t, i.type, e), v.value = e, x.value = t, (t == null ? void 0 : t.operateType) !== "删除" ? (i.show = (t == null ? void 0 : t.trigger) === "openDialog", i.title = (t == null ? void 0 : t.operateType) + "菜单") : Me.confirm(`是否确认要删除【${e == null ? void 0 : e.title}】`, "", {
|
|
148
148
|
confirmButtonText: "确认",
|
|
149
149
|
cancelButtonText: "取消",
|
|
150
150
|
type: "warning"
|
|
@@ -181,7 +181,7 @@ const ke = {
|
|
|
181
181
|
dialogInfo: i,
|
|
182
182
|
beforeDialogDestroy: I,
|
|
183
183
|
clickMenuIcon: Z,
|
|
184
|
-
mode:
|
|
184
|
+
mode: z,
|
|
185
185
|
renderMenuList: b,
|
|
186
186
|
clickMenu: H,
|
|
187
187
|
openMenu: J,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const s=require("vue"),
|
|
1
|
+
"use strict";const s=require("vue"),k=require("./index-BOev8isw.cjs");require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-mQIxU0SD.cjs");const F=require("./index.vue_vue_type_style_index_1_lang-DraQDAAw.cjs"),te=require("./index-weauvEnW.cjs"),se=require("vue-router"),R=require("./index-9_UaEHGu.cjs"),re=require("./index-CSWIBSmo.cjs"),D=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./index-weauvEnW.cjs")).then(v=>v.index));D.install=v=>{v.component("ssMenu",D)};const N={__name:"index",props:{name:String},setup(v){const a=v,A=s.computed(()=>k.ElIcons[a.name]);return s.onMounted(()=>{}),(w,g)=>{const P=s.resolveComponent("el-icon");return s.openBlock(),s.createBlock(P,null,{default:s.withCtx(()=>[(s.openBlock(),s.createBlock(s.resolveDynamicComponent(A.value)))]),_:1})}}},ne=s.defineComponent({name:"menu",components:{ssMenu:D,DynamicIcon:N,ssDialog:te.ssDialog},setup(){const v=s.defineProps({mode:{type:String,default:"vertical"}}),a=F.useMenuState(),A=F.useModelComp(k.pinia),w=s.ref(0),g=se.useRouter(),{asideMenus:P,menuTriggerType:U,platform:V}=k.storeToRefs(a),W=s.computed(()=>v==null?void 0:v.mode),b=s.computed(()=>{let e=[...P.value];if((e==null?void 0:e.length)===0)return g.push("/"),[];const t=j(e,K.value);return t.isFlag||(e=t==null?void 0:t.data),e}),z=async e=>{A.setRouteToChildPath(""),a.setMenuTriggerType("click"),a.setActiveMenuPath(e==null?void 0:e.path),a.setActiveAsideMenu(e),e.isRouter?g.push(e.path):g.push("/")},H=async e=>{const t=k.findNodeByPropInTree(b.value,"path",e);a.setActiveAsideMenu(t),A.setRouteToChildPath(""),U.value==="click"?w.value===1?a.setActiveMenuPath(sessionStorage.getItem("pageKey")):a.setActiveMenuPath(e):(a.setMenuTriggerType("click"),a.setActiveMenuPath(e)),e!=null&&e.startsWith("/")?g.push(e):g.push("/"),w.value++},J=e=>{a.setActiveMenuPath(e)},T=e=>{const t=document.documentElement;e==null||e.forEach(o=>{t.style.setProperty(o.name,o.value)})};s.onMounted(()=>{w.value=1});const K=s.computed(()=>{const e=sessionStorage.getItem("authority");return e?JSON.parse(e):[]});s.watch(()=>V.value,e=>{e==="browser"?T(R.browserVerticalMenuClasses):e==="client"&&(T(R.clientHorizontalMenuClasses),T(R.clientVerticalMenuClasses))},{immediate:!0});const L=(e,t)=>{function o(u){u==null||u.forEach(r=>{var f,y;const c=(f=r==null?void 0:r.path)!=null&&f.startsWith("/")?(y=r==null?void 0:r.path)==null?void 0:y.substring(1):r==null?void 0:r.path;r.show=t==null?void 0:t.some(M=>M==null?void 0:M.includes(c)),r.children&&o(r.children)})}return o(e),e},j=(e,t)=>{if(Array.isArray(t)){const o=Array.from(new Set(t==null?void 0:t.map(u=>u.substring(0,u.lastIndexOf("/")))));return{data:L(e,o),isFlag:!1}}else return{isFlag:(t==null?void 0:t.toUpperCase())==="SUPERADMIN"}},p=s.reactive({show:!1,title:"菜单配置",width:"30%",type:"create"}),G=e=>re.getComponent(e),Q=s.ref({}),S=s.ref([]),X=async(e,t,o)=>{var y,M,E;if(!(e!=null&&e.structureIds)||((y=e==null?void 0:e.structureIds)==null?void 0:y.length)===0)return;const u=(E=(M=e==null?void 0:e.structureIds)==null?void 0:M.filter(n=>(n==null?void 0:n.key)==="dialogConfig"))==null?void 0:E.map(n=>n==null?void 0:n.id);let r=u==null?void 0:u.map(n=>k.getInsofDataApi({id:n}));const c=await Promise.all(r);if(c==null?void 0:c.every(n=>{var l;return((l=n==null?void 0:n.data)==null?void 0:l.code)===200})){const n=c==null?void 0:c.map(l=>{var C,m,i,_,x,$,O;return{id:(i=(m=(C=l==null?void 0:l.data)==null?void 0:C.result)==null?void 0:m[0])==null?void 0:i.id,...(O=($=(x=(_=l==null?void 0:l.data)==null?void 0:_.result)==null?void 0:x[0])==null?void 0:$.value)==null?void 0:O.pageData}});t==="create"&&(S.value=n),t==="update"&&(S.value=n==null?void 0:n.map(l=>{var C,m;return((C=l==null?void 0:l.comp)==null?void 0:C.toUpperCase())==="FORM"?{...l,compData:(m=l==null?void 0:l.compData)==null?void 0:m.map(i=>{var _;return(i==null?void 0:i.key)==="formContent"?{...i,contents:(_=i==null?void 0:i.contents)==null?void 0:_.map(x=>({...x,value:o==null?void 0:o.title}))}:i})}:l}))}},d=s.ref({}),h=s.ref({}),Y=e=>{switch(e){case"新增":return"create";case"编辑":return"update";case"删除":return"delete"}},q=s.ref({}),B=e=>{a.setCacheInputMenu({type:p.type,data:e}),a.setIsRefreshMenus(!0)},Z=async(e,t)=>{p.type=Y(t==null?void 0:t.operateType),await X(t,p.type,e),h.value=e,q.value=t,(t==null?void 0:t.operateType)!=="删除"?(p.show=(t==null?void 0:t.trigger)==="openDialog",p.title=(t==null?void 0:t.operateType)+"菜单"):F.ElMessageBox.confirm(`是否确认要删除【${e==null?void 0:e.title}】`,"",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{B(e)})},I=()=>{p.show=!1},ee=e=>e==null?void 0:e.filter(t=>t.allowInherit);return{handleCompChange:e=>{var o,u;const t=(o=e==null?void 0:e.contents)==null?void 0:o.find(r=>r.key==="formContent");t&&(d.value=(u=t==null?void 0:t.contents)==null?void 0:u.reduce((r,c)=>(r[c.key]=c.value,r.prop=c.key,r),{}))},dialogForm:Q,dialogRenderComps:S,getComponents:G,clickSubmitForm:()=>{var o,u,r,c,f;let e;p.type==="create"&&(e=((o=h.value)==null?void 0:o.path)+"/"+d.value[(u=d.value)==null?void 0:u.prop]),p.type==="update"&&(e=(r=h.value)==null?void 0:r.path);const t={...h.value,config:ee((c=h.value)==null?void 0:c.config),children:[],childMenus:[],title:d.value[(f=d.value)==null?void 0:f.prop],path:e};console.log("clickSubmitForm",q.value,h.value,t),B(t),p.show=!1},dialogInfo:p,beforeDialogDestroy:I,clickMenuIcon:Z,mode:W,renderMenuList:b,clickMenu:z,openMenu:H,closeMenu:J,changeMenuStyle:T}}});exports._sfc_main=ne;exports._sfc_main$1=N;exports.ssMenu=D;
|