@vancone/console-component 0.1.0-beta.15 → 0.1.0-beta.16
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/package.json
CHANGED
|
@@ -10,7 +10,7 @@ var Re = (s, a, o) => a in s ? Ze(s, a, { enumerable: !0, configurable: !0, writ
|
|
|
10
10
|
tt.call(a, o) && Re(s, o, a[o]);
|
|
11
11
|
return s;
|
|
12
12
|
}, Ve = (s, a) => We(s, $e(a));
|
|
13
|
-
import { openBlock as n, createElementBlock as U, defineComponent as
|
|
13
|
+
import { openBlock as n, createElementBlock as U, defineComponent as pe, reactive as le, resolveComponent as y, createVNode as d, withCtx as r, createElementVNode as i, Fragment as ee, renderList as se, toDisplayString as Q, normalizeStyle as Ge, ref as E, onMounted as Oe, unref as v, createCommentVNode as K, createTextVNode as N, createBlock as I, resolveDynamicComponent as Se, computed as xe, watch as he, createStaticVNode as ot, nextTick as De, normalizeClass as Te, resolveDirective as Ke, withDirectives as Pe } from "vue";
|
|
14
14
|
import { useRoute as _e, useRouter as Be } from "vue-router";
|
|
15
15
|
import at from "axios";
|
|
16
16
|
import { ElMessage as Ue, ElMessageBox as nt } from "element-plus";
|
|
@@ -74,7 +74,7 @@ function Ct() {
|
|
|
74
74
|
function yt() {
|
|
75
75
|
return ie.get("https://console.vancone.com/api/console/app?pageSize=1000");
|
|
76
76
|
}
|
|
77
|
-
const wt = { class: "app-catalog-wrapper" }, At = { style: { width: "calc(100% - 330px)" } }, kt = { class: "catalog-wrapper" }, _t = { class: "service-list" }, It = ["href"], Et = /* @__PURE__ */
|
|
77
|
+
const wt = { class: "app-catalog-wrapper" }, At = { style: { width: "calc(100% - 330px)" } }, kt = { class: "catalog-wrapper" }, _t = { class: "service-list" }, It = ["href"], Et = /* @__PURE__ */ pe({
|
|
78
78
|
__name: "AppCatalog",
|
|
79
79
|
props: {
|
|
80
80
|
visible: { type: Boolean }
|
|
@@ -257,7 +257,7 @@ function Vt(s, a) {
|
|
|
257
257
|
i("path", { d: "M358.4 871.2H45.152C19.936 871.2 0 843.904 0 819.2s19.936-50.624 45.152-50.624h56.64l-1.088-283.168c0-204.608 164.032-374.56 337.056-412.576v-1.28C437.76 32.032 470.496 0 510.848 0s73.088 32.032 73.088 71.552v1.28C756.96 110.848 922.08 280.8 922.08 485.408v283.168h55.008c25.216 0 46.944 25.92 46.944 50.624s-21.696 52-46.944 52H665.632c-.416 84.48-69.024 152.8-153.6 152.8s-153.184-68.352-153.6-152.8zm102.4 0c.416 27.904 23.168 50.4 51.2 50.4s50.784-22.496 51.2-50.4zm357.216-103.328v-282.56c0-179.808-149.536-329.984-307.104-329.984S204.544 305.472 204.544 485.312v282.56z" }, null, -1)
|
|
258
258
|
]));
|
|
259
259
|
}
|
|
260
|
-
const Dt = { render: Vt }, Tt = { class: "header" }, Kt = { class: "right" }, Pt = { class: "icon-wrapper" }, Lt = { class: "user-wrapper" }, jt = { style: { "font-size": "11px", "font-weight": "bold" } }, Xt = { class: "user-popover-header" }, Yt = { style: { "font-size": "15px", "font-weight": "bold" } }, qt = ["onClick"], Ht = /* @__PURE__ */
|
|
260
|
+
const Dt = { render: Vt }, Tt = { class: "header" }, Kt = { class: "right" }, Pt = { class: "icon-wrapper" }, Lt = { class: "user-wrapper" }, jt = { style: { "font-size": "11px", "font-weight": "bold" } }, Xt = { class: "user-popover-header" }, Yt = { style: { "font-size": "15px", "font-weight": "bold" } }, qt = ["onClick"], Ht = /* @__PURE__ */ pe({
|
|
261
261
|
__name: "Header",
|
|
262
262
|
props: {
|
|
263
263
|
title: {},
|
|
@@ -471,7 +471,7 @@ const Dt = { render: Vt }, Tt = { class: "header" }, Kt = { class: "right" }, Pt
|
|
|
471
471
|
]);
|
|
472
472
|
};
|
|
473
473
|
}
|
|
474
|
-
}), Ye = /* @__PURE__ */ re(Ht, [["__scopeId", "data-v-a9821cf9"]]), Jt = { class: "menu-icon-wrapper" }, zt = { class: "menu-icon-wrapper" }, Nt = /* @__PURE__ */
|
|
474
|
+
}), Ye = /* @__PURE__ */ re(Ht, [["__scopeId", "data-v-a9821cf9"]]), Jt = { class: "menu-icon-wrapper" }, zt = { class: "menu-icon-wrapper" }, Nt = /* @__PURE__ */ pe({
|
|
475
475
|
__name: "SideMenuItem",
|
|
476
476
|
props: {
|
|
477
477
|
menu: {}
|
|
@@ -520,7 +520,7 @@ const Dt = { render: Vt }, Tt = { class: "header" }, Kt = { class: "right" }, Pt
|
|
|
520
520
|
}, 8, ["index"]));
|
|
521
521
|
};
|
|
522
522
|
}
|
|
523
|
-
}), Zt = /* @__PURE__ */ re(Nt, [["__scopeId", "data-v-e3b5500a"]]),
|
|
523
|
+
}), Zt = /* @__PURE__ */ re(Nt, [["__scopeId", "data-v-e3b5500a"]]), de = E({}), Wt = {}, $t = E([]), eo = {
|
|
524
524
|
xmlns: "http://www.w3.org/2000/svg",
|
|
525
525
|
width: "32",
|
|
526
526
|
height: "32",
|
|
@@ -535,7 +535,7 @@ function to(s, a) {
|
|
|
535
535
|
}, null, -1)
|
|
536
536
|
]));
|
|
537
537
|
}
|
|
538
|
-
const oo = { render: to }, ao = { class: "menu-wrapper" }, no = { class: "menu-button-wrapper" }, lo = /* @__PURE__ */
|
|
538
|
+
const oo = { render: to }, ao = { class: "menu-wrapper" }, no = { class: "menu-button-wrapper" }, lo = /* @__PURE__ */ pe({
|
|
539
539
|
__name: "SideMenu",
|
|
540
540
|
props: {
|
|
541
541
|
menuCollapsed: { type: Boolean }
|
|
@@ -583,7 +583,7 @@ const oo = { render: to }, ao = { class: "menu-wrapper" }, no = { class: "menu-b
|
|
|
583
583
|
]);
|
|
584
584
|
};
|
|
585
585
|
}
|
|
586
|
-
}), qe = /* @__PURE__ */ re(lo, [["__scopeId", "data-v-f9a7b402"]]), so = { class: "container" }, ro = /* @__PURE__ */
|
|
586
|
+
}), qe = /* @__PURE__ */ re(lo, [["__scopeId", "data-v-f9a7b402"]]), so = { class: "container" }, ro = /* @__PURE__ */ pe({
|
|
587
587
|
__name: "ConsoleApp",
|
|
588
588
|
props: {
|
|
589
589
|
title: {},
|
|
@@ -657,7 +657,7 @@ function bo(s, a) {
|
|
|
657
657
|
const o = y("router-view");
|
|
658
658
|
return n(), I(o);
|
|
659
659
|
}
|
|
660
|
-
const Co = /* @__PURE__ */ re(vo, [["render", bo]]), yo = { class: "card-wrapper" }, wo = ["onClick"], Ao = { class: "card-inner-wrapper" }, ko = { class: "card-title" }, _o = { class: "icon" }, Io = /* @__PURE__ */
|
|
660
|
+
const Co = /* @__PURE__ */ re(vo, [["render", bo]]), yo = { class: "card-wrapper" }, wo = ["onClick"], Ao = { class: "card-inner-wrapper" }, ko = { class: "card-title" }, _o = { class: "icon" }, Io = /* @__PURE__ */ pe({
|
|
661
661
|
__name: "TabCard",
|
|
662
662
|
props: {
|
|
663
663
|
cards: {},
|
|
@@ -742,7 +742,7 @@ const ke = (s) => {
|
|
|
742
742
|
}, Eo = {
|
|
743
743
|
key: 1,
|
|
744
744
|
class: "view-span"
|
|
745
|
-
}, So = /* @__PURE__ */
|
|
745
|
+
}, So = /* @__PURE__ */ pe({
|
|
746
746
|
__name: "FormView",
|
|
747
747
|
props: {
|
|
748
748
|
id: {},
|
|
@@ -952,7 +952,7 @@ const ke = (s) => {
|
|
|
952
952
|
]);
|
|
953
953
|
};
|
|
954
954
|
}
|
|
955
|
-
}), Je = /* @__PURE__ */ re(So, [["__scopeId", "data-v-aeba890e"]]), Mo = { class: "dialog-footer" }, Qo = { class: "operation-button-wrapper" }, xo = /* @__PURE__ */
|
|
955
|
+
}), Je = /* @__PURE__ */ re(So, [["__scopeId", "data-v-aeba890e"]]), Mo = { class: "dialog-footer" }, Qo = { class: "operation-button-wrapper" }, xo = /* @__PURE__ */ pe({
|
|
956
956
|
__name: "FormDialog",
|
|
957
957
|
props: {
|
|
958
958
|
id: {},
|
|
@@ -1037,7 +1037,7 @@ const ke = (s) => {
|
|
|
1037
1037
|
}, 8, ["model-value"]);
|
|
1038
1038
|
};
|
|
1039
1039
|
}
|
|
1040
|
-
}), ze = /* @__PURE__ */ re(xo, [["__scopeId", "data-v-d1628662"]]), Bo = { class: "toolbar" }, Uo = { class: "tool-buttons" }, Go = { class: "tool-buttons" }, Oo = { key: 1 }, Fo = /* @__PURE__ */
|
|
1040
|
+
}), ze = /* @__PURE__ */ re(xo, [["__scopeId", "data-v-d1628662"]]), Bo = { class: "toolbar" }, Uo = { class: "tool-buttons" }, Go = { class: "tool-buttons" }, Oo = { key: 1 }, Fo = /* @__PURE__ */ pe({
|
|
1041
1041
|
__name: "TableView",
|
|
1042
1042
|
props: {
|
|
1043
1043
|
model: {}
|
|
@@ -1174,7 +1174,7 @@ const ke = (s) => {
|
|
|
1174
1174
|
refresh: h,
|
|
1175
1175
|
updateConfigAndRefresh: T
|
|
1176
1176
|
}), (l, f) => {
|
|
1177
|
-
const B = y("el-checkbox"), Z = y("el-badge"), H = y("el-button"), oe = y("el-icon"), ce = y("el-tooltip"), ae = y("el-input"), ne = y("el-table-column"), $ = y("router-link"), j = y("el-tag"),
|
|
1177
|
+
const B = y("el-checkbox"), Z = y("el-badge"), H = y("el-button"), oe = y("el-icon"), ce = y("el-tooltip"), ae = y("el-input"), ne = y("el-table-column"), $ = y("router-link"), j = y("el-tag"), ue = y("el-popconfirm"), me = y("el-table"), ye = y("el-pagination"), Ne = Ke("loading");
|
|
1178
1178
|
return n(), U("div", {
|
|
1179
1179
|
class: Te({ "table-view-wrapper": e.showPane })
|
|
1180
1180
|
}, [
|
|
@@ -1342,7 +1342,7 @@ const ke = (s) => {
|
|
|
1342
1342
|
]),
|
|
1343
1343
|
_: 2
|
|
1344
1344
|
}, 1032, ["onClick"]),
|
|
1345
|
-
d(
|
|
1345
|
+
d(ue, {
|
|
1346
1346
|
title: "Are you sure to delete this?",
|
|
1347
1347
|
onConfirm: (ge) => _(J.$index, J.row)
|
|
1348
1348
|
}, {
|
|
@@ -1420,7 +1420,7 @@ const ke = (s) => {
|
|
|
1420
1420
|
}), Qe = /* @__PURE__ */ re(Fo, [["__scopeId", "data-v-d37a3022"]]), Ro = { class: "nav-bar" }, Vo = {
|
|
1421
1421
|
key: 0,
|
|
1422
1422
|
class: "info-card-wrapper"
|
|
1423
|
-
}, Do = { class: "icon-wrapper" }, To = { class: "info-wrapper" }, Ko = { class: "title-wrapper" }, Po = { class: "tabs-wrapper" }, Lo = { class: "dialog-footer" }, jo = /* @__PURE__ */
|
|
1423
|
+
}, Do = { class: "icon-wrapper" }, To = { class: "info-wrapper" }, Ko = { class: "title-wrapper" }, Po = { class: "tabs-wrapper" }, Lo = { class: "dialog-footer" }, jo = /* @__PURE__ */ pe({
|
|
1424
1424
|
__name: "DetailPage",
|
|
1425
1425
|
setup(s) {
|
|
1426
1426
|
const { t: a } = Ie(), o = _e(), g = Be(), t = xe(() => o.query.id), e = E(!1), b = E(!1), c = E("view"), C = E(), A = E(-1), V = E(), R = E(), X = E("summary"), P = E(""), z = E(""), D = E(""), O = E(0), k = le({
|
|
@@ -1430,9 +1430,9 @@ const ke = (s) => {
|
|
|
1430
1430
|
let Y = [];
|
|
1431
1431
|
he([
|
|
1432
1432
|
() => g.currentRoute.value,
|
|
1433
|
-
|
|
1433
|
+
de
|
|
1434
1434
|
], () => {
|
|
1435
|
-
T();
|
|
1435
|
+
console.log("model list changed", de), T();
|
|
1436
1436
|
}, {
|
|
1437
1437
|
immediate: !0,
|
|
1438
1438
|
deep: !0
|
|
@@ -1490,15 +1490,17 @@ const ke = (s) => {
|
|
|
1490
1490
|
var M, F, L;
|
|
1491
1491
|
W.splice(0);
|
|
1492
1492
|
const _ = o.params.model;
|
|
1493
|
-
if (
|
|
1493
|
+
if (de.value[_] === void 0) {
|
|
1494
|
+
console.warn("Model not exist:", _);
|
|
1494
1495
|
return;
|
|
1496
|
+
}
|
|
1495
1497
|
ke(k);
|
|
1496
|
-
const w = Ce(
|
|
1498
|
+
const w = Ce(de.value[_]);
|
|
1497
1499
|
Object.assign(k, w), A.value = -1, X.value = "summary";
|
|
1498
1500
|
const x = (F = (M = k.pageConfig) == null ? void 0 : M.detailPage) == null ? void 0 : F.tabs;
|
|
1499
1501
|
if (x)
|
|
1500
1502
|
for (let p of x) {
|
|
1501
|
-
const S = Ce(
|
|
1503
|
+
const S = Ce(de.value[p.modelKey]);
|
|
1502
1504
|
if (W.push(S), p.type === "table") {
|
|
1503
1505
|
S.tableConfig || (S.tableConfig = {});
|
|
1504
1506
|
let u = S.tableConfig;
|
|
@@ -1556,10 +1558,10 @@ const ke = (s) => {
|
|
|
1556
1558
|
i("div", Ro, [
|
|
1557
1559
|
d(M, null, {
|
|
1558
1560
|
default: r(() => {
|
|
1559
|
-
var j,
|
|
1561
|
+
var j, ue;
|
|
1560
1562
|
return [
|
|
1561
1563
|
d(x, {
|
|
1562
|
-
to: { path: `/${(
|
|
1564
|
+
to: { path: `/${(ue = (j = k == null ? void 0 : k.breadcrumbRoute) != null ? j : k == null ? void 0 : k.route) != null ? ue : ""}` }
|
|
1563
1565
|
}, {
|
|
1564
1566
|
default: r(() => {
|
|
1565
1567
|
var me;
|
|
@@ -1603,9 +1605,9 @@ const ke = (s) => {
|
|
|
1603
1605
|
dropdown: r(() => [
|
|
1604
1606
|
d(S, null, {
|
|
1605
1607
|
default: r(() => {
|
|
1606
|
-
var j,
|
|
1608
|
+
var j, ue;
|
|
1607
1609
|
return [
|
|
1608
|
-
(n(!0), U(ee, null, se((
|
|
1610
|
+
(n(!0), U(ee, null, se((ue = (j = k.pageConfig) == null ? void 0 : j.detailPage) == null ? void 0 : ue.operationButtons, (me) => (n(), I(p, {
|
|
1609
1611
|
onClick: (ye) => me.function(C.value.formData)
|
|
1610
1612
|
}, {
|
|
1611
1613
|
default: r(() => [
|
|
@@ -1667,7 +1669,7 @@ const ke = (s) => {
|
|
|
1667
1669
|
onTabClick: q
|
|
1668
1670
|
}, {
|
|
1669
1671
|
default: r(() => {
|
|
1670
|
-
var j,
|
|
1672
|
+
var j, ue;
|
|
1671
1673
|
return [
|
|
1672
1674
|
d(f, {
|
|
1673
1675
|
label: v(a)("common.basic.summary"),
|
|
@@ -1685,7 +1687,7 @@ const ke = (s) => {
|
|
|
1685
1687
|
]),
|
|
1686
1688
|
_: 1
|
|
1687
1689
|
}, 8, ["label"]),
|
|
1688
|
-
(n(!0), U(ee, null, se((
|
|
1690
|
+
(n(!0), U(ee, null, se((ue = (j = k.pageConfig) == null ? void 0 : j.detailPage) == null ? void 0 : ue.tabs, (me) => {
|
|
1689
1691
|
var ye;
|
|
1690
1692
|
return n(), I(f, {
|
|
1691
1693
|
label: v(a)((ye = me.name) != null ? ye : "")
|
|
@@ -1750,7 +1752,7 @@ const ke = (s) => {
|
|
|
1750
1752
|
], 64);
|
|
1751
1753
|
};
|
|
1752
1754
|
}
|
|
1753
|
-
}), Xo = /* @__PURE__ */ re(jo, [["__scopeId", "data-v-
|
|
1755
|
+
}), Xo = /* @__PURE__ */ re(jo, [["__scopeId", "data-v-e255f44d"]]), Yo = { class: "page-title" }, qo = /* @__PURE__ */ pe({
|
|
1754
1756
|
__name: "TablePage",
|
|
1755
1757
|
setup(s) {
|
|
1756
1758
|
const { t: a } = Ie(), o = _e(), g = Be(), t = E(), e = E([]), b = le({
|
|
@@ -1761,7 +1763,7 @@ const ke = (s) => {
|
|
|
1761
1763
|
var V, R, X, P, z;
|
|
1762
1764
|
e.value = [], b.pageConfig && ((R = (V = b.pageConfig) == null ? void 0 : V.tablePage) != null && R.tabViewAttributes) && (e.value = (z = (P = (X = b.pageConfig) == null ? void 0 : X.tablePage) == null ? void 0 : P.tabViewAttributes) == null ? void 0 : z.map((D) => {
|
|
1763
1765
|
let O;
|
|
1764
|
-
return D.modelKey &&
|
|
1766
|
+
return D.modelKey && de.value[D.modelKey] ? O = Ce(de.value[D.modelKey]) : O = Ce(b), D.queryParams && (O.tableConfig || (O.tableConfig = {}), O.tableConfig.queryParams = D.queryParams), D.fields && (O.fields = D.fields), D.modelKey && (O.breadcrumbRoute = b.route), {
|
|
1765
1767
|
key: D.key,
|
|
1766
1768
|
label: D.label,
|
|
1767
1769
|
icon: D.icon,
|
|
@@ -1772,19 +1774,19 @@ const ke = (s) => {
|
|
|
1772
1774
|
}
|
|
1773
1775
|
function A() {
|
|
1774
1776
|
var X, P;
|
|
1775
|
-
console.log("Init table page, loading model:", o.params.model), console.log("Current model list",
|
|
1777
|
+
console.log("Init table page, loading model:", o.params.model), console.log("Current model list", de.value);
|
|
1776
1778
|
const V = o.params.model;
|
|
1777
|
-
if (
|
|
1779
|
+
if (de.value[V] === void 0) {
|
|
1778
1780
|
console.warn("Model not found", V);
|
|
1779
1781
|
return;
|
|
1780
1782
|
}
|
|
1781
1783
|
ke(b);
|
|
1782
|
-
const R = Ce(
|
|
1784
|
+
const R = Ce(de.value[V]);
|
|
1783
1785
|
Object.assign(b, R), (P = (X = b.pageConfig) == null ? void 0 : X.tablePage) != null && P.tabViewAttributes || Object.assign(c, b), C();
|
|
1784
1786
|
}
|
|
1785
1787
|
return he([
|
|
1786
1788
|
() => g.currentRoute.value,
|
|
1787
|
-
|
|
1789
|
+
de
|
|
1788
1790
|
], () => {
|
|
1789
1791
|
A();
|
|
1790
1792
|
}, {
|
|
@@ -1839,6 +1841,6 @@ export {
|
|
|
1839
1841
|
Mt as en,
|
|
1840
1842
|
Me as i18n,
|
|
1841
1843
|
$t as menuList,
|
|
1842
|
-
|
|
1844
|
+
de as modelList,
|
|
1843
1845
|
Qt as zh
|
|
1844
1846
|
};
|