@jeecg/online 3.7.1-RC → 3.7.4-beta

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 (143) hide show
  1. package/AccountLoginForm-84cbd344.mjs +254 -0
  2. package/AiModal-26903538.mjs +84 -0
  3. package/AppForgetPassword-52443f23.mjs +310 -0
  4. package/AppLogin-ecf798fa.mjs +287 -0
  5. package/AppLoginHeader-4432c584.mjs +27 -0
  6. package/AppNameEmail-3303a037.mjs +180 -0
  7. package/AppRegister-79a62c59.mjs +303 -0
  8. package/AppTenant-f0bef7ca.mjs +373 -0
  9. package/AppThirdForm-fd8b4604.mjs +189 -0
  10. package/AuthButtonConfig-d5bffca0.mjs +156 -0
  11. package/AuthButtonTree-b0bd6c40.mjs +165 -0
  12. package/{AuthDataConfig-5c3a8e6b.mjs → AuthDataConfig-d3b7afa4.mjs} +23 -23
  13. package/{AuthDataTree-dd7a1240.mjs → AuthDataTree-f14a98d9.mjs} +43 -43
  14. package/{AuthFieldConfig-9f6fa06c.mjs → AuthFieldConfig-f1e224cc.mjs} +71 -71
  15. package/AuthFieldTree-5cc0da05.mjs +232 -0
  16. package/{AuthManagerDrawer-76f15e8d.mjs → AuthManagerDrawer-32556109.mjs} +6 -6
  17. package/{AuthSetterModal-f5d2e87f.mjs → AuthSetterModal-364f1f67.mjs} +9 -9
  18. package/BuiltInButtonList-bb6cf95c.mjs +10 -0
  19. package/BuiltInButtonList.vue_vue_type_script_setup_true_lang-07d0b7d0.mjs +338 -0
  20. package/CgformAddressModal-1131274c.mjs +260 -0
  21. package/CgformCopyList-5fba0810.mjs +252 -0
  22. package/{CgformModal-21c5c387.mjs → CgformModal-c4a4e0c2.mjs} +190 -194
  23. package/{CgreportModal-edefa8e3.mjs → CgreportModal-8a84aae5.mjs} +181 -168
  24. package/{CheckDictTable-1bc8322d.mjs → CheckDictTable-8a938e3a.mjs} +3 -3
  25. package/CodeFileListModal-a924902a.mjs +159 -0
  26. package/{CodeFileViewModal-2fe911f4.mjs → CodeFileViewModal-405e2b58.mjs} +66 -66
  27. package/CodeGeneratorModal-2e1dc13d.mjs +281 -0
  28. package/CustomButtonList-c453b654.mjs +274 -0
  29. package/{DBAttributeTable-285d40db.mjs → DBAttributeTable-1a45c7b7.mjs} +3 -3
  30. package/{DbToOnlineModal-5dcb67c3.mjs → DbToOnlineModal-f28ff0a3.mjs} +53 -54
  31. package/{DetailForm-deecbf3d.mjs → DetailForm-c592b8d8.mjs} +5 -5
  32. package/DropMenuItem-1e49abea.mjs +44 -0
  33. package/{EnhanceJavaModal-45c66cd5.mjs → EnhanceJavaModal-d5a93f2a.mjs} +62 -62
  34. package/{EnhanceJsHistory-fab3102e.mjs → EnhanceJsHistory-8ddb0657.mjs} +35 -35
  35. package/{EnhanceJsModal-175357a1.mjs → EnhanceJsModal-dc4f9ade.mjs} +104 -104
  36. package/{EnhanceSqlModal-7ea1b300.mjs → EnhanceSqlModal-984f045d.mjs} +67 -67
  37. package/ErrorTip-bb616e32.mjs +7 -0
  38. package/ErrorTip.vue_vue_type_script_setup_true_lang-49d35987.mjs +60 -0
  39. package/{ExtendConfigModal-a89ae052.mjs → ExtendConfigModal-7d70f362.mjs} +2 -2
  40. package/{FieldExtendJsonModal-32135634.mjs → FieldExtendJsonModal-bf04d70e.mjs} +2 -2
  41. package/{FileSelectModal-1643c8b9.mjs → FileSelectModal-ffc69d4a.mjs} +23 -23
  42. package/{ForeignKeyTable-7f7e28a7.mjs → ForeignKeyTable-92decaea.mjs} +3 -3
  43. package/{IndexTable-cdcc2b48.mjs → IndexTable-2ded2014.mjs} +3 -3
  44. package/JModalTip-a927f85d.mjs +49 -0
  45. package/{JOnlineSearchSelect-22aae934.mjs → JOnlineSearchSelect-04ec87d0.mjs} +1 -1
  46. package/{LeftDepart-d5615ed9.mjs → LeftDepart-52cb6743.mjs} +1 -1
  47. package/LeftRole-b0e0b496.mjs +86 -0
  48. package/{LeftUser-22baa378.mjs → LeftUser-dd4b10e2.mjs} +30 -30
  49. package/{LinkTableConfigModal-9242d750.mjs → LinkTableConfigModal-7eeb3e58.mjs} +43 -31
  50. package/{LinkTableFieldConfigModal-24adc50c.mjs → LinkTableFieldConfigModal-b078fcef.mjs} +1 -1
  51. package/{LinkTableListPiece-f3a8e0d7.mjs → LinkTableListPiece-e016b8e6.mjs} +1 -1
  52. package/{ModalFormDemo-711418db.mjs → ModalFormDemo-aaa719a7.mjs} +1 -1
  53. package/OnlCgformErpList-5c5acdaa.mjs +488 -0
  54. package/OnlCgformErpSubTable-e1b88312.mjs +441 -0
  55. package/{OnlCgformInnerSubTable-6c23781f.mjs → OnlCgformInnerSubTable-6b6fa15a.mjs} +38 -38
  56. package/OnlCgformInnerTableList-b283a525.mjs +474 -0
  57. package/OnlCgformTabList-91e3dd78.mjs +424 -0
  58. package/OnlineAutoList-84475f1b.mjs +513 -0
  59. package/OnlineAutoModal-95f46901.mjs +260 -0
  60. package/OnlineAutoTreeList-20b9ce04.mjs +523 -0
  61. package/OnlineCustomModal-c8b1e780.mjs +232 -0
  62. package/{OnlineDetailModal-d5895734.mjs → OnlineDetailModal-5b412bb9.mjs} +74 -65
  63. package/OnlineForm-58282699.mjs +1012 -0
  64. package/{OnlineFormDetail-022ca117.mjs → OnlineFormDetail-fc087725.mjs} +7 -7
  65. package/{OnlineFormUrlAdd-9715d70a.mjs → OnlineFormUrlAdd-bc9105bb.mjs} +9 -9
  66. package/{OnlineFormUrlDetail-8f864b1a.mjs → OnlineFormUrlDetail-ad912560.mjs} +11 -11
  67. package/{OnlineFormUrlEdit-ac985b36.mjs → OnlineFormUrlEdit-f2fa79ff.mjs} +9 -9
  68. package/OnlineFormUrlSuccess-76813d45.mjs +59 -0
  69. package/OnlineQueryForm-9248341f.mjs +484 -0
  70. package/{OnlineSearchFormItem-6c557343.mjs → OnlineSearchFormItem-1e437bd3.mjs} +82 -82
  71. package/{OnlineSelectCascade-05c40fef.mjs → OnlineSelectCascade-d631ed72.mjs} +1 -1
  72. package/{OnlineSubFormDetail-58e896ce.mjs → OnlineSubFormDetail-8be879b9.mjs} +52 -53
  73. package/{OnlineTabAutoModal-47b18ad6.mjs → OnlineTabAutoModal-c9ca3c24.mjs} +108 -95
  74. package/{OnlineTabDetailModal-82de1465.mjs → OnlineTabDetailModal-fd4c9a72.mjs} +36 -36
  75. package/OnlineTabForm-1940e88b.mjs +814 -0
  76. package/{OnlineTabFormDetail-8d0c40c0.mjs → OnlineTabFormDetail-2aa67564.mjs} +17 -17
  77. package/{PageAttributeTable-25e3b7da.mjs → PageAttributeTable-66e7b485.mjs} +108 -108
  78. package/PhoneLoginForm-86437a9d.mjs +214 -0
  79. package/{ProcessOnlineForm-148632fe.mjs → ProcessOnlineForm-98ede18d.mjs} +32 -32
  80. package/{QueryTable-f7bfca7f.mjs → QueryTable-65d3f54f.mjs} +3 -3
  81. package/SetSwitchOptions-f914bc17.mjs +62 -0
  82. package/ShareAddView-657f0f8b.mjs +86 -0
  83. package/ShareEditView-1b945fd3.mjs +92 -0
  84. package/ShareView-222ed3d8.mjs +80 -0
  85. package/ShareView.vue_vue_type_script_setup_true_lang-44fbeaff.mjs +162 -0
  86. package/SingleView-23b0cb4e.mjs +68 -0
  87. package/SingleView.vue_vue_type_style_index_0_lang-e0f2f6c0.mjs +131 -0
  88. package/SuperQuery-46032e66.mjs +974 -0
  89. package/{SuperQueryValComponent-7ad86d4b.mjs → SuperQueryValComponent-5a9ccfd4.mjs} +1 -1
  90. package/{SuperQueryValComponent.vue_vue_type_script_lang-e9196096.mjs → SuperQueryValComponent.vue_vue_type_script_lang-8fe34917.mjs} +11 -11
  91. package/{auth.api-ea1d33d4.mjs → auth.api-53df4c33.mjs} +17 -17
  92. package/{auth.data-511e5197.mjs → auth.data-626c5083.mjs} +16 -12
  93. package/button.data-fe45d43b.mjs +12 -0
  94. package/{cgform.data-475d4984.mjs → cgform.data-0ca62d09.mjs} +4 -1
  95. package/{enhance.data-a67572e1.mjs → enhance.data-6601ff44.mjs} +1 -1
  96. package/index-19eaef11.mjs +11 -0
  97. package/index-1a2e8832.mjs +135 -0
  98. package/{index-f30613d1.mjs → index-2fb8e07f.mjs} +59 -59
  99. package/index-5e89258d.mjs +8 -0
  100. package/index-9e1e1e53.mjs +57 -0
  101. package/{index-30e0e923.mjs → index-a039036e.mjs} +272 -262
  102. package/index-c5a79b0b.mjs +219 -0
  103. package/index-cce225be.mjs +110 -0
  104. package/index-f2c2d1cf.mjs +74 -0
  105. package/main.index.js +1 -1
  106. package/package.json +1 -1
  107. package/shareStore-7de6c7a6.mjs +67 -0
  108. package/style.css +1 -1
  109. package/useCgformList-f3cb9156.mjs +378 -0
  110. package/useExtendComponent-bb98e568.mjs +4460 -0
  111. package/useListButton-98908683.mjs +719 -0
  112. package/{useSchemas-a9c75b0f.mjs → useSchemas-b074f3a1.mjs} +33 -0
  113. package/{useTableSync-d7e9f18d.mjs → useTableSync-075826a1.mjs} +1 -1
  114. package/utils-9fce7606.mjs +16 -0
  115. package/AiModal-6de335e3.mjs +0 -84
  116. package/AuthButtonConfig-89763932.mjs +0 -154
  117. package/AuthButtonTree-2d87d0b3.mjs +0 -157
  118. package/AuthFieldTree-e326fc38.mjs +0 -232
  119. package/CgformCopyList-365b3e8f.mjs +0 -251
  120. package/CodeFileListModal-24601898.mjs +0 -159
  121. package/CodeGeneratorModal-f09fe903.mjs +0 -282
  122. package/CustomButtonList-f07bc695.mjs +0 -397
  123. package/JModalTip-b055ab60.mjs +0 -49
  124. package/LeftRole-2ed8a2bf.mjs +0 -86
  125. package/OnlCgformErpList-58acdfa0.mjs +0 -470
  126. package/OnlCgformErpSubTable-9b1e1938.mjs +0 -426
  127. package/OnlCgformInnerTableList-4b5e14ed.mjs +0 -458
  128. package/OnlCgformTabList-019ad753.mjs +0 -408
  129. package/OnlineAutoList-48589d09.mjs +0 -493
  130. package/OnlineAutoModal-c2928847.mjs +0 -239
  131. package/OnlineAutoTreeList-3baa1d00.mjs +0 -503
  132. package/OnlineCustomModal-9e17b6ce.mjs +0 -232
  133. package/OnlineForm-9f1153ba.mjs +0 -985
  134. package/OnlineFormUrlSuccess-3dfc54ab.mjs +0 -59
  135. package/OnlineQueryForm-eedb9a60.mjs +0 -466
  136. package/OnlineTabForm-27655c83.mjs +0 -817
  137. package/SetSwitchOptions-b2af757f.mjs +0 -62
  138. package/SuperQuery-a8592995.mjs +0 -967
  139. package/index-1d1a6e56.mjs +0 -57
  140. package/useCgformList-f41d4dc1.mjs +0 -426
  141. package/useExtendComponent-dcae5c78.mjs +0 -4399
  142. package/useListButton-bfac4ecf.mjs +0 -697
  143. /package/{OnlineForm.vue_vue_type_style_index_0_scoped_4657b304_lang-4ed993c7.mjs → OnlineForm.vue_vue_type_style_index_0_scoped_3f26e7bd_lang-4ed993c7.mjs} +0 -0
@@ -0,0 +1,189 @@
1
+ var O = Object.defineProperty;
2
+ var F = Object.getOwnPropertySymbols;
3
+ var R = Object.prototype.hasOwnProperty, q = Object.prototype.propertyIsEnumerable;
4
+ var E = (t, e, n) => e in t ? O(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, _ = (t, e) => {
5
+ for (var n in e || (e = {}))
6
+ R.call(e, n) && E(t, n, e[n]);
7
+ if (F)
8
+ for (var n of F(e))
9
+ q.call(e, n) && E(t, n, e[n]);
10
+ return t;
11
+ };
12
+ var B = (t, e, n) => new Promise((m, g) => {
13
+ var h = (s) => {
14
+ try {
15
+ f(n.next(s));
16
+ } catch (r) {
17
+ g(r);
18
+ }
19
+ }, d = (s) => {
20
+ try {
21
+ f(n.throw(s));
22
+ } catch (r) {
23
+ g(r);
24
+ }
25
+ }, f = (s) => s.done ? m(s.value) : Promise.resolve(s.value).then(h, d);
26
+ f((n = n.apply(t, e)).next());
27
+ });
28
+ import { ref as c, unref as a, defineComponent as z, resolveComponent as G, withDirectives as Q, openBlock as J, createElementBlock as K, createElementVNode as p, createVNode as k, withCtx as L, createTextVNode as I, vShow as W } from "vue";
29
+ import { Form as $, Input as X } from "ant-design-vue";
30
+ import { CountdownInput as Y } from "/@/components/CountDown";
31
+ import { defHttp as D } from "/@/utils/http/axios";
32
+ import { useGlobSetting as Z } from "/@/hooks/setting";
33
+ import { useMessage as ee } from "/@/hooks/web/useMessage";
34
+ import { useUserStore as ne } from "/@/store/modules/user";
35
+ import { useI18n as te } from "/@/hooks/web/useI18n";
36
+ import { QuestionCircleFilled as oe } from "@ant-design/icons-vue";
37
+ import { _ as ie } from "./index-9e1e1e53.mjs";
38
+ import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
39
+ import "vue-router";
40
+ function se(t) {
41
+ const { createMessage: e, notification: n } = ee(), { t: m } = te(), g = Z(), h = ne(), d = c(""), f = c({}), s = c(!1), r = c(!1), b = c(""), T = c(!1), v = c(""), y = c("");
42
+ function S(o) {
43
+ let i = `${g.uploadUrl}/sys/thirdLogin/render/${o}`;
44
+ window.open(
45
+ i,
46
+ `login ${o}`,
47
+ "height=500, width=500, top=0, left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=n o, status=no"
48
+ ), d.value = o, f.value = {}, s.value = !1;
49
+ let l = function(j) {
50
+ let u = j.data;
51
+ if (typeof u == "string")
52
+ if (u === "登录失败")
53
+ e.warning(u);
54
+ else if (u.includes("绑定手机号")) {
55
+ r.value = !0;
56
+ let H = u.split(",");
57
+ b.value = H[1], t("type", { loginType: "thirdLogin" });
58
+ } else
59
+ w(u);
60
+ else
61
+ typeof u == "object" ? u.isObj === !0 && (T.value = !0, f.value = _({}, u)) : e.warning("不识别的信息传递");
62
+ window.removeEventListener("message", a(l), !1);
63
+ };
64
+ window.addEventListener("message", l, !1);
65
+ }
66
+ function w(o) {
67
+ a(s) === !1 && (s.value = !0, h.ThirdLogin({ token: o, thirdType: a(d) }).then((i) => {
68
+ i && i.userInfo ? n.success({
69
+ message: m("sys.login.loginSuccessTitle"),
70
+ description: `${m("sys.login.loginSuccessDesc")}: ${i.userInfo.realname}`,
71
+ duration: 3
72
+ }) : U(i);
73
+ }));
74
+ }
75
+ function U(o) {
76
+ n.error({
77
+ message: "登录失败",
78
+ description: ((o.response || {}).data || {}).message || o.message || "请求出现错误,请稍后再试",
79
+ duration: 4
80
+ });
81
+ }
82
+ function A() {
83
+ a(v) || C("请输入手机号"), a(y) || C("请输入验证码");
84
+ let o = {
85
+ mobile: a(v),
86
+ captcha: a(y),
87
+ thirdUserUuid: a(b)
88
+ };
89
+ D.post({ url: "/sys/thirdLogin/bindingThirdPhone", params: o }, { isTransformResponse: !1 }).then((i) => {
90
+ i.success ? (r.value = !1, w(i.result)) : e.warning(i.message);
91
+ }).catch((i) => {
92
+ e.warning(i.message);
93
+ });
94
+ }
95
+ function C(o) {
96
+ n.error({
97
+ message: "登录失败",
98
+ description: o,
99
+ duration: 4
100
+ });
101
+ }
102
+ function x() {
103
+ t("type", { loginType: "login" });
104
+ }
105
+ function P() {
106
+ t("type", { loginType: "register" });
107
+ }
108
+ function M() {
109
+ r.value = !1;
110
+ }
111
+ function N(o) {
112
+ return B(this, null, function* () {
113
+ let i = _({}, o);
114
+ i.thirdUserUuid = a(b), yield D.put({ url: "/sys/thirdLogin/registerBindThirdAccount", params: i }, { isTransformResponse: !1 }).then((l) => {
115
+ l.success ? (r.value = !1, w(l.result)) : e.warning(l.message);
116
+ }).catch((l) => {
117
+ e.warning(l.message);
118
+ });
119
+ });
120
+ }
121
+ function V(o) {
122
+ v.value = o.mobile, y.value = o.sms, A();
123
+ }
124
+ return {
125
+ thirdConfirmShow: T,
126
+ bindingAccount: r,
127
+ thirdHandleOk: A,
128
+ thirdPhone: v,
129
+ thirdCaptcha: y,
130
+ onThirdLogin: S,
131
+ loginAccountClick: x,
132
+ registerAccountClick: P,
133
+ hideBindThirdAccount: M,
134
+ bindThirdAccount: V,
135
+ createAccountBindThird: N
136
+ };
137
+ }
138
+ const re = $.Item, ue = X.Password, ae = z({
139
+ name: "AppThirdForm",
140
+ components: { FormItem: re, Form: $, InputPassword: ue, CountdownInput: Y, QuestionCircleFilled: oe },
141
+ setup(t, { emit: e }) {
142
+ return _({}, se(e));
143
+ }
144
+ });
145
+ const le = { class: "third-account" }, ce = { class: "content" }, de = { class: "enter-x bind-btn" }, pe = {
146
+ class: "enter-x bind-btn",
147
+ style: { "margin-top": "20px" }
148
+ };
149
+ function fe(t, e, n, m, g, h) {
150
+ const d = G("a-button");
151
+ return Q((J(), K("div", le, [
152
+ p("div", ce, [
153
+ e[2] || (e[2] = p("div", { class: "bind-title" }, [
154
+ p("span", null, "还未绑定敲敲云账号")
155
+ ], -1)),
156
+ e[3] || (e[3] = p("div", { class: "bind-title-desc" }, [
157
+ p("span", null, "请选择绑定已有帐户,或创建新帐号")
158
+ ], -1)),
159
+ p("div", de, [
160
+ k(d, {
161
+ type: "primary",
162
+ onClick: t.loginAccountClick
163
+ }, {
164
+ default: L(() => e[0] || (e[0] = [
165
+ I("登录并绑定")
166
+ ])),
167
+ _: 1
168
+ }, 8, ["onClick"])
169
+ ]),
170
+ p("div", pe, [
171
+ k(d, {
172
+ type: "primary",
173
+ onClick: t.registerAccountClick
174
+ }, {
175
+ default: L(() => e[1] || (e[1] = [
176
+ I("注册新账号")
177
+ ])),
178
+ _: 1
179
+ }, 8, ["onClick"])
180
+ ])
181
+ ])
182
+ ], 512)), [
183
+ [W, t.bindingAccount]
184
+ ]);
185
+ }
186
+ const Be = /* @__PURE__ */ ie(ae, [["render", fe], ["__scopeId", "data-v-c98a927f"]]);
187
+ export {
188
+ Be as default
189
+ };
@@ -0,0 +1,156 @@
1
+ var h = (i, u, c) => new Promise((p, m) => {
2
+ var g = (o) => {
3
+ try {
4
+ r(c.next(o));
5
+ } catch (l) {
6
+ m(l);
7
+ }
8
+ }, f = (o) => {
9
+ try {
10
+ r(c.throw(o));
11
+ } catch (l) {
12
+ m(l);
13
+ }
14
+ }, r = (o) => o.done ? p(o.value) : Promise.resolve(o.value).then(g, f);
15
+ r((c = c.apply(i, u)).next());
16
+ });
17
+ import { defineComponent as S, ref as T, watch as A, resolveComponent as w, openBlock as E, createElementBlock as $, createVNode as v, withCtx as x, createTextVNode as q } from "vue";
18
+ import { cloneDeep as F } from "lodash-es";
19
+ import { BasicTable as j, useTable as z } from "/@/components/Table";
20
+ import { f as O, g as U, h as V } from "./auth.api-53df4c33.mjs";
21
+ import { b as K, c as P } from "./auth.data-626c5083.mjs";
22
+ import { _ as G } from "./index-9e1e1e53.mjs";
23
+ import "/@/utils/http/axios";
24
+ import "/@/utils/index";
25
+ import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
26
+ import "/@/hooks/web/useMessage";
27
+ import "vue-router";
28
+ const H = S({
29
+ name: "AuthButtonConfig",
30
+ components: { BasicTable: j },
31
+ props: {
32
+ headId: {
33
+ type: String,
34
+ default: "",
35
+ required: !0
36
+ },
37
+ // 1单表 2主表 3附表
38
+ tableType: {
39
+ type: Number,
40
+ default: 1
41
+ }
42
+ },
43
+ setup(i) {
44
+ const u = T(""), c = T(2), p = T(3), m = T(5), [g, { reload: f, getTableRef: r, setPagination: o }] = z({
45
+ api: B,
46
+ rowKey: "code",
47
+ bordered: !0,
48
+ columns: K,
49
+ showIndexColumn: !1
50
+ });
51
+ A(
52
+ () => i.headId,
53
+ (t) => {
54
+ u.value = t.split("?")[0], r().value && o({ current: 1, pageSize: 10 }), f().catch(() => null);
55
+ },
56
+ { immediate: !0 }
57
+ );
58
+ const l = (t) => {
59
+ const e = F(P);
60
+ if (t.mainRelationType != null && t.mainThemeTemplate != null && i.tableType == 3) {
61
+ let a = [];
62
+ switch (t.mainThemeTemplate) {
63
+ case "normal":
64
+ case "innerTable":
65
+ case "tab":
66
+ t.mainRelationType == 1 ? a = [] : a = e.filter((n) => ["add", "update", "batch_delete"].includes(n.code));
67
+ break;
68
+ case "erp":
69
+ a = e.filter((n) => !["super_query"].includes(n.code));
70
+ break;
71
+ }
72
+ return a;
73
+ } else
74
+ return e;
75
+ };
76
+ function B(t) {
77
+ return h(this, null, function* () {
78
+ let e = yield O(u.value, t), { authList: a, buttonList: n } = e, d = [];
79
+ const y = l(e);
80
+ for (let s of y) {
81
+ const b = n.findIndex((C) => C.buttonCode === s.code), _ = {};
82
+ b !== -1 && (_.title = n[b].buttonName, n.splice(b, 1));
83
+ let N = {
84
+ status: 0,
85
+ page: p.value
86
+ }, R = a.find((C) => C.code == s.code);
87
+ Object.assign(s, N, R, _), d.push(s);
88
+ }
89
+ if (i.tableType == 3) {
90
+ const s = d.findIndex((b) => b.code === "super_query");
91
+ s != -1 && d.splice(s, 1);
92
+ }
93
+ return I(a, n, d);
94
+ });
95
+ }
96
+ function I(t, e, a) {
97
+ for (let n of e) {
98
+ let d = t.find((s) => s.code == n.buttonCode), y = {
99
+ code: n.buttonCode,
100
+ title: n.buttonName,
101
+ status: 0,
102
+ page: n.buttonStyle == "form" ? m.value : p.value
103
+ };
104
+ a.push(Object.assign(y, d));
105
+ }
106
+ return a;
107
+ }
108
+ function k(t, e) {
109
+ return h(this, null, function* () {
110
+ t ? L(e) : D(e);
111
+ });
112
+ }
113
+ function L(t) {
114
+ return h(this, null, function* () {
115
+ let e = yield U({
116
+ id: t.id,
117
+ code: t.code,
118
+ page: t.page,
119
+ cgformId: u.value,
120
+ type: c.value,
121
+ control: 5,
122
+ status: 1
123
+ });
124
+ t.id = e.id, t.status = 1;
125
+ });
126
+ }
127
+ function D(t) {
128
+ return h(this, null, function* () {
129
+ yield V(t.id), t.status = 0;
130
+ });
131
+ }
132
+ return { registerTable: g, onUpdateStatus: k };
133
+ }
134
+ }), J = { class: "auth-field-config" };
135
+ function M(i, u, c, p, m, g) {
136
+ const f = w("a-switch"), r = w("BasicTable");
137
+ return E(), $("div", J, [
138
+ v(r, { onRegister: i.registerTable }, {
139
+ switch: x(({ text: o, record: l }) => [
140
+ v(f, {
141
+ size: "small",
142
+ checked: l.status === 1,
143
+ onChange: (B) => i.onUpdateStatus(B, l)
144
+ }, null, 8, ["checked", "onChange"])
145
+ ]),
146
+ control: x(() => u[0] || (u[0] = [
147
+ q(" 可见 ")
148
+ ])),
149
+ _: 1
150
+ }, 8, ["onRegister"])
151
+ ]);
152
+ }
153
+ const ut = /* @__PURE__ */ G(H, [["render", M]]);
154
+ export {
155
+ ut as default
156
+ };
@@ -0,0 +1,165 @@
1
+ var h = (e, o, c) => new Promise((u, p) => {
2
+ var m = (r) => {
3
+ try {
4
+ n(c.next(r));
5
+ } catch (d) {
6
+ p(d);
7
+ }
8
+ }, l = (r) => {
9
+ try {
10
+ n(c.throw(r));
11
+ } catch (d) {
12
+ p(d);
13
+ }
14
+ }, n = (r) => r.done ? u(r.value) : Promise.resolve(r.value).then(m, l);
15
+ n((c = c.apply(e, o)).next());
16
+ });
17
+ import { defineComponent as N, ref as i, computed as w, watch as M, resolveComponent as g, openBlock as v, createElementBlock as b, createBlock as E, Fragment as S, createElementVNode as P, createVNode as k, withCtx as I, createTextVNode as B } from "vue";
18
+ import { useMessage as $ } from "/@/hooks/web/useMessage";
19
+ import { c as R } from "./auth.data-626c5083.mjs";
20
+ import { o as V, n as z, p as L } from "./auth.api-53df4c33.mjs";
21
+ import { _ as j } from "./index-9e1e1e53.mjs";
22
+ import "/@/utils/index";
23
+ import "/@/utils/http/axios";
24
+ import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
25
+ import "vue-router";
26
+ const q = N({
27
+ name: "AuthButtonTree",
28
+ props: {
29
+ cgformId: { type: String, required: !0 }
30
+ },
31
+ setup(e) {
32
+ const { createMessage: o, createSuccessModal: c } = $(), u = i(""), p = i(2), m = i(!0), l = i([]), n = i([]), r = i([]), d = i(""), C = w(() => !u.value);
33
+ M(() => e.cgformId, y, { immediate: !0 });
34
+ function y() {
35
+ return h(this, null, function* () {
36
+ if (!e.cgformId)
37
+ return;
38
+ let t = yield V(e.cgformId, p.value);
39
+ t.forEach((a) => {
40
+ for (const f of R)
41
+ if (a.code == f.code) {
42
+ a.title || (a.title = f.title);
43
+ break;
44
+ }
45
+ });
46
+ let s = [];
47
+ for (let a of t) {
48
+ let f = T(a);
49
+ s.push({ key: a.id, title: f });
50
+ }
51
+ r.value = s;
52
+ });
53
+ }
54
+ function D() {
55
+ y(), _(u.value, d.value);
56
+ }
57
+ function _(t, s) {
58
+ return h(this, null, function* () {
59
+ u.value = t, d.value = s, n.value = [], yield y();
60
+ let a = yield z({
61
+ roleId: t,
62
+ cgformId: e.cgformId,
63
+ type: p.value,
64
+ authMode: s
65
+ });
66
+ n.value = a.map((f) => f.authId);
67
+ });
68
+ }
69
+ function K() {
70
+ u.value = "", y();
71
+ }
72
+ function x() {
73
+ return h(this, null, function* () {
74
+ try {
75
+ const { success: t, message: s, result: a } = yield L(u.value, e.cgformId, {
76
+ authId: JSON.stringify(n.value),
77
+ authMode: d.value
78
+ });
79
+ t ? Array.isArray(a == null ? void 0 : a.disabledNames) ? c({
80
+ title: "保存成功",
81
+ content: `由于以下按钮未激活,所以权限未生效。<br>${a.disabledNames.join("<br>")}`
82
+ }) : o.success("保存成功") : o.error(s);
83
+ } catch (t) {
84
+ o.error("保存出现异常");
85
+ }
86
+ });
87
+ }
88
+ function T(t) {
89
+ let s = t.title + "-";
90
+ return t.code && t.code.includes("form_sub") ? s += "表单可见(附表)" : t.page == 3 ? s += "列表可见" : t.page == 5 && (s += "表单可见"), s;
91
+ }
92
+ function A(t) {
93
+ l.value = t, m.value = !1;
94
+ }
95
+ function F() {
96
+ u.value = "", n.value = [];
97
+ }
98
+ return {
99
+ loadChecked: _,
100
+ clear: F,
101
+ expandedKeys: l,
102
+ autoExpandParent: m,
103
+ checkedKeys: n,
104
+ treeData: r,
105
+ disabled: C,
106
+ onSave: x,
107
+ onExpand: A,
108
+ onRefresh: D,
109
+ clearChecked: K
110
+ };
111
+ }
112
+ });
113
+ const J = { class: "onl-auth-tree-btns" };
114
+ function O(e, o, c, u, p, m) {
115
+ const l = g("a-empty"), n = g("a-button"), r = g("a-tree");
116
+ return v(), b("div", null, [
117
+ e.disabled ? (v(), E(l, {
118
+ key: 0,
119
+ description: "请先选中左侧角色/部门/用户"
120
+ })) : e.treeData.length === 0 ? (v(), E(l, {
121
+ key: 1,
122
+ description: "无权限信息"
123
+ })) : (v(), b(S, { key: 2 }, [
124
+ P("div", J, [
125
+ k(n, {
126
+ onClick: e.onRefresh,
127
+ size: "small",
128
+ type: "primary",
129
+ preIcon: "ant-design:redo",
130
+ ghost: ""
131
+ }, {
132
+ default: I(() => o[1] || (o[1] = [
133
+ B("刷新")
134
+ ])),
135
+ _: 1
136
+ }, 8, ["onClick"]),
137
+ k(n, {
138
+ onClick: e.onSave,
139
+ size: "small",
140
+ type: "primary",
141
+ preIcon: "ant-design:save",
142
+ ghost: ""
143
+ }, {
144
+ default: I(() => o[2] || (o[2] = [
145
+ B("保存")
146
+ ])),
147
+ _: 1
148
+ }, 8, ["onClick"])
149
+ ]),
150
+ k(r, {
151
+ checkable: "",
152
+ checkedKeys: e.checkedKeys,
153
+ "onUpdate:checkedKeys": o[0] || (o[0] = (d) => e.checkedKeys = d),
154
+ expandedKeys: e.expandedKeys,
155
+ autoExpandParent: e.autoExpandParent,
156
+ treeData: e.treeData,
157
+ onExpand: e.onExpand
158
+ }, null, 8, ["checkedKeys", "expandedKeys", "autoExpandParent", "treeData", "onExpand"])
159
+ ], 64))
160
+ ]);
161
+ }
162
+ const ae = /* @__PURE__ */ j(q, [["render", O], ["__scopeId", "data-v-b62449eb"]]);
163
+ export {
164
+ ae as default
165
+ };
@@ -10,7 +10,7 @@ var M = (t, n, o) => n in t ? K(t, n, { enumerable: !0, configurable: !0, writab
10
10
  X.call(n, o) && M(t, o, n[o]);
11
11
  return t;
12
12
  }, k = (t, n) => Q(t, H(n));
13
- var A = (t, n, o) => new Promise((u, f) => {
13
+ var A = (t, n, o) => new Promise((c, f) => {
14
14
  var p = (a) => {
15
15
  try {
16
16
  i(o.next(a));
@@ -23,16 +23,16 @@ var A = (t, n, o) => new Promise((u, f) => {
23
23
  } catch (l) {
24
24
  f(l);
25
25
  }
26
- }, i = (a) => a.done ? u(a.value) : Promise.resolve(a.value).then(p, g);
26
+ }, i = (a) => a.done ? c(a.value) : Promise.resolve(a.value).then(p, g);
27
27
  i((o = o.apply(t, n)).next());
28
28
  });
29
- import { defineComponent as Y, ref as Z, watch as y, reactive as ee, nextTick as te, resolveComponent as r, openBlock as ne, createElementBlock as oe, createVNode as c, withCtx as d, createTextVNode as ae, mergeProps as ie } from "vue";
29
+ import { defineComponent as Y, ref as Z, watch as y, reactive as ee, nextTick as te, resolveComponent as r, openBlock as ne, createElementBlock as oe, createVNode as u, withCtx as d, createTextVNode as ae, mergeProps as ie } from "vue";
30
30
  import { BasicTable as le, TableAction as se, useTable as re } from "/@/components/Table";
31
- import { BasicModal as ce, useModal as ue } from "/@/components/Modal";
31
+ import { BasicModal as ue, useModal as ce } from "/@/components/Modal";
32
32
  import { BasicForm as me, useForm as de } from "/@/components/Form";
33
- import { i as fe, j as pe, k as ge, l as he } from "./auth.api-ea1d33d4.mjs";
34
- import { d as Ce, u as be, U as v } from "./auth.data-511e5197.mjs";
35
- import { _ as _e } from "./index-1d1a6e56.mjs";
33
+ import { i as fe, j as pe, k as ge, l as he } from "./auth.api-53df4c33.mjs";
34
+ import { d as Ce, u as be, U as v } from "./auth.data-626c5083.mjs";
35
+ import { _ as _e } from "./index-9e1e1e53.mjs";
36
36
  import "/@/utils/http/axios";
37
37
  import "/@/utils/index";
38
38
  import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
@@ -40,13 +40,13 @@ import "/@/hooks/web/useMessage";
40
40
  import "vue-router";
41
41
  const we = Y({
42
42
  name: "AuthDataConfig",
43
- components: { BasicTable: le, TableAction: se, BasicModal: ce, BasicForm: me },
43
+ components: { BasicTable: le, TableAction: se, BasicModal: ue, BasicForm: me },
44
44
  props: {
45
45
  cgformId: { type: String, required: !0 },
46
46
  authFields: { type: Array, required: !0 }
47
47
  },
48
48
  setup(t) {
49
- const n = Z(!1), [o, { reload: u, setLoading: f }] = re({
49
+ const n = Z(!1), [o, { reload: c, setLoading: f }] = re({
50
50
  api: (e) => fe(t.cgformId, e),
51
51
  rowKey: "id",
52
52
  bordered: !0,
@@ -62,7 +62,7 @@ const we = Y({
62
62
  }
63
63
  });
64
64
  y(n, (e) => f(e));
65
- const [p, { openModal: g, closeModal: i }] = ue(), a = ee({
65
+ const [p, { openModal: g, closeModal: i }] = ce(), a = ee({
66
66
  title: "",
67
67
  width: 800,
68
68
  confirmLoading: !1,
@@ -83,7 +83,7 @@ const we = Y({
83
83
  y(
84
84
  () => t.cgformId,
85
85
  () => {
86
- u().catch(() => null);
86
+ c().catch(() => null);
87
87
  },
88
88
  { immediate: !0 }
89
89
  );
@@ -100,14 +100,14 @@ const we = Y({
100
100
  T({ title: "编辑", record: e, isUpdate: !0 });
101
101
  }
102
102
  function L(e) {
103
- n.value = !0, he(e).then(u).finally(() => n.value = !1);
103
+ n.value = !0, he(e).then(c).finally(() => n.value = !1);
104
104
  }
105
105
  function E() {
106
106
  return A(this, null, function* () {
107
107
  try {
108
108
  a.confirmLoading = !0;
109
109
  let e = yield b();
110
- e = Object.assign({}, h, e), e.ruleOperator == v && (e.ruleColumn = ""), e.cgformId = t.cgformId, yield pe(e, l), u(), i();
110
+ e = Object.assign({}, h, e), e.ruleOperator == v && (e.ruleColumn = ""), e.cgformId = t.cgformId, yield pe(e, l), c(), i();
111
111
  } finally {
112
112
  a.confirmLoading = !1;
113
113
  }
@@ -183,47 +183,47 @@ const we = Y({
183
183
  };
184
184
  }
185
185
  });
186
- function Ae(t, n, o, u, f, p) {
186
+ function Ae(t, n, o, c, f, p) {
187
187
  const g = r("a-button"), i = r("a-switch"), a = r("TableAction"), l = r("BasicTable"), h = r("BasicForm"), m = r("a-spin"), _ = r("BasicModal");
188
188
  return ne(), oe("div", null, [
189
- c(l, {
189
+ u(l, {
190
190
  onRegister: t.registerTable,
191
191
  loading: t.loading
192
192
  }, {
193
193
  tableTitle: d(() => [
194
- c(g, {
194
+ u(g, {
195
195
  onClick: t.onAdd,
196
196
  type: "primary",
197
197
  preIcon: "ant-design:plus"
198
198
  }, {
199
- default: d(() => [
199
+ default: d(() => n[0] || (n[0] = [
200
200
  ae("新增")
201
- ]),
201
+ ])),
202
202
  _: 1
203
203
  }, 8, ["onClick"])
204
204
  ]),
205
205
  switch: d(({ text: C, record: b }) => [
206
- c(i, {
206
+ u(i, {
207
207
  size: "small",
208
208
  checked: b.status === 1,
209
209
  onClick: () => t.onUpdateStatus(b)
210
210
  }, null, 8, ["checked", "onClick"])
211
211
  ]),
212
212
  action: d(({ record: C }) => [
213
- c(a, {
213
+ u(a, {
214
214
  actions: t.getTableAction(C),
215
215
  dropDownActions: t.getDropDownAction(C)
216
216
  }, null, 8, ["actions", "dropDownActions"])
217
217
  ]),
218
218
  _: 1
219
219
  }, 8, ["onRegister", "loading"]),
220
- c(_, ie(t.formModalProps, { onOpenChange: t.handleOpenChange }), {
220
+ u(_, ie(t.formModalProps, { onOpenChange: t.handleOpenChange }), {
221
221
  default: d(() => [
222
- c(m, {
222
+ u(m, {
223
223
  spinning: t.formModalProps.confirmLoading
224
224
  }, {
225
225
  default: d(() => [
226
- c(h, { onRegister: t.registerForm }, null, 8, ["onRegister"])
226
+ u(h, { onRegister: t.registerForm }, null, 8, ["onRegister"])
227
227
  ]),
228
228
  _: 1
229
229
  }, 8, ["spinning"])