@das-fed/utils 6.4.0-hot.44 → 6.4.0-hot.45

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 (78) hide show
  1. package/api-services/i18n/index.js.gz +0 -0
  2. package/api-services/index.js +1504 -1820
  3. package/api-services/index.js.gz +0 -0
  4. package/api-services/modules/app-manage/index.js +1329 -1663
  5. package/api-services/modules/app-manage/index.js.gz +0 -0
  6. package/api-services/modules/authentication/index.js +1318 -1634
  7. package/api-services/modules/authentication/index.js.gz +0 -0
  8. package/api-services/modules/bems/index.js +1321 -1637
  9. package/api-services/modules/bems/index.js.gz +0 -0
  10. package/api-services/modules/contract/index.js +1311 -1623
  11. package/api-services/modules/contract/index.js.gz +0 -0
  12. package/api-services/modules/duty-manage/index.js +1339 -1673
  13. package/api-services/modules/duty-manage/index.js.gz +0 -0
  14. package/api-services/modules/enterpriseright/index.js +1318 -1634
  15. package/api-services/modules/enterpriseright/index.js.gz +0 -0
  16. package/api-services/modules/file/index.js +1392 -1708
  17. package/api-services/modules/file/index.js.gz +0 -0
  18. package/api-services/modules/gateway-edge/index.js +1318 -1634
  19. package/api-services/modules/gateway-edge/index.js.gz +0 -0
  20. package/api-services/modules/index.js +1536 -1852
  21. package/api-services/modules/index.js.gz +0 -0
  22. package/api-services/modules/iot/index.js +1363 -1661
  23. package/api-services/modules/iot/index.js.gz +0 -0
  24. package/api-services/modules/justauth/index.js +1332 -1630
  25. package/api-services/modules/justauth/index.js.gz +0 -0
  26. package/api-services/modules/knowledge/index.js +1339 -1655
  27. package/api-services/modules/knowledge/index.js.gz +0 -0
  28. package/api-services/modules/link/index.js +1328 -1626
  29. package/api-services/modules/link/index.js.gz +0 -0
  30. package/api-services/modules/permission/index.js +1318 -1634
  31. package/api-services/modules/permission/index.js.gz +0 -0
  32. package/api-services/modules/platformManage/index.js +1335 -1633
  33. package/api-services/modules/platformManage/index.js.gz +0 -0
  34. package/api-services/modules/portal/index.js +1328 -1626
  35. package/api-services/modules/portal/index.js.gz +0 -0
  36. package/api-services/modules/space-manage/index.js +1328 -1626
  37. package/api-services/modules/space-manage/index.js.gz +0 -0
  38. package/api-services/modules/super-admin/index.js +1334 -1632
  39. package/api-services/modules/super-admin/index.js.gz +0 -0
  40. package/api-services/modules/supplier/index.js +1338 -1654
  41. package/api-services/modules/supplier/index.js.gz +0 -0
  42. package/api-services/modules/supplychain-manage/index.js +1319 -1631
  43. package/api-services/modules/supplychain-manage/index.js.gz +0 -0
  44. package/api-services/modules/systemConfiguration/index.js +1325 -1623
  45. package/api-services/modules/systemConfiguration/index.js.gz +0 -0
  46. package/api-services/modules/tool/index.js +1339 -1655
  47. package/api-services/modules/tool/index.js.gz +0 -0
  48. package/api-services/src/create-service/index.js +1338 -1654
  49. package/api-services/src/create-service/index.js.gz +0 -0
  50. package/common-info/getInfoFromUrl/index.js.gz +0 -0
  51. package/common-info/index.d.ts +5 -1
  52. package/common-info/index.js +84 -58
  53. package/common-info/index.js.gz +0 -0
  54. package/common-info/set-personal-info/index.js +593 -842
  55. package/common-info/set-personal-info/index.js.gz +0 -0
  56. package/common-info/type.d.ts +14 -0
  57. package/common-tools/extract-file-name/index.js +785 -1034
  58. package/common-tools/extract-file-name/index.js.gz +0 -0
  59. package/common-tools/get-url-params/index.js.gz +0 -0
  60. package/create-api-service/index.js +1348 -1646
  61. package/create-api-service/index.js.gz +0 -0
  62. package/create-api-service/sso/index.js +727 -976
  63. package/create-api-service/sso/index.js.gz +0 -0
  64. package/curring-http/index.js +1105 -1354
  65. package/curring-http/index.js.gz +0 -0
  66. package/directive/auth/index.js +41 -48
  67. package/directive/auth/index.js.gz +0 -0
  68. package/esm-map.json +3 -1
  69. package/hooks/use-get-auth/index.js.gz +0 -0
  70. package/nextTiken/index.js.gz +0 -0
  71. package/package.json +4 -4
  72. package/pinyin-first-character/index.js +21049 -19969
  73. package/pinyin-first-character/index.js.gz +0 -0
  74. package/style/index.js +2 -4
  75. package/style/index.js.gz +0 -0
  76. package/use-low-code/index.js.gz +0 -0
  77. package/vue/hooks/use-model-value/index.d.ts +5 -1
  78. package/webSocket-service/index.js.gz +0 -0
@@ -1,5 +1,9 @@
1
- import { UserInfo, PersonalInfo, TenantInfo, HomeInfo, PersonalConfigInfo, ProjectInfo, ProjectMessage, SubAppsInfo, TabInfo, permissionBtnInfo } from './type';
1
+ import { UserInfo, PersonalInfo, TenantInfo, HomeInfo, PersonalConfigInfo, ProjectInfo, ProjectMessage, SubAppsInfo, TabInfo, permissionBtnInfo, menuItemTs } from './type';
2
2
 
3
+ /** 获取当前应用详情 */
4
+ export declare const getMenuItemInfo: (val?: any) => menuItemTs;
5
+ /** 获取所有权限code详情 */
6
+ export declare const getAuthobj: () => any;
3
7
  /** 获取token */
4
8
  export declare const getToken: any;
5
9
  /** 获取账户详情 */
@@ -1,19 +1,52 @@
1
- import { getConfig as u } from "@das-fed/utils/config";
2
- import { getUrlParams as d } from "@das-fed/utils/common-tools";
3
- import { getAccessToken as I } from "@das-fed/utils/token-tools";
4
- import { getTokenFromQuery as S, getProjectInfoFromQuery as y } from "@das-fed/utils/common-info/getInfoFromUrl";
5
- const N = I, A = () => {
6
- var r;
1
+ import { getConfig as p } from "@das-fed/utils/config";
2
+ import { getAccessToken as g } from "@das-fed/utils/token-tools";
3
+ import { getTokenFromQuery as d, getProjectInfoFromQuery as i } from "@das-fed/utils/common-info/getInfoFromUrl";
4
+ const P = (e) => {
5
+ let t = e || JSON.parse(sessionStorage.getItem("menuItem") || "{}");
6
+ return {
7
+ authCodes: t.rightFuncCodes ?? [],
8
+ routeUrl: t.routeUrl ?? "",
9
+ parentId: t.parentId ?? "",
10
+ id: t.id ?? "",
11
+ appId: t.appId ?? "",
12
+ menuAppearance: t.menuAppearance ?? "",
13
+ name: t.name ?? "",
14
+ type: (t == null ? void 0 : t.type) ?? ""
15
+ };
16
+ }, m = () => {
17
+ const e = JSON.parse(sessionStorage.getItem("menuList") || "[]"), t = {};
18
+ return e.forEach((s) => {
19
+ s.routeUrl && (s.rightFuncCodes && s.rightFuncCodes.forEach((r) => t[r] = []), s.children && s.children.forEach((r) => {
20
+ if (r.rightFuncCodes && r.rightFuncCodes[0] && !r.children) {
21
+ const o = r.rightFuncCodes[0].lastIndexOf("."), n = r.rightFuncCodes[0].slice(0, o);
22
+ t[n] = [], r.rightFuncCodes.forEach((a) => {
23
+ const c = a.lastIndexOf(".");
24
+ t[n].push({ code: a.slice(c + 1) });
25
+ });
26
+ }
27
+ r.children && r.children.forEach((o) => {
28
+ if (o.rightFuncCodes) {
29
+ const n = o.rightFuncCodes[0].lastIndexOf("."), a = o.rightFuncCodes[0].slice(0, n);
30
+ t[a] = [], o.rightFuncCodes.forEach((c) => {
31
+ const l = c.lastIndexOf(".");
32
+ t[a].push({ code: c.slice(l + 1) });
33
+ });
34
+ }
35
+ });
36
+ }));
37
+ }), t;
38
+ }, I = g, b = () => {
39
+ var s;
7
40
  let e = JSON.parse(sessionStorage.getItem("tenantInfo") || "{}");
8
41
  return {
9
42
  id: e.id ?? "",
10
43
  name: e.userName ?? "",
11
44
  flag: e.flag ?? null,
12
- tenantId: ((r = e == null ? void 0 : e.tenant) == null ? void 0 : r.id) ?? ""
45
+ tenantId: ((s = e == null ? void 0 : e.tenant) == null ? void 0 : s.id) ?? ""
13
46
  };
14
- }, J = () => {
47
+ }, f = () => {
15
48
  let e = JSON.parse(sessionStorage.getItem("userInfo") || "{}");
16
- const t = u();
49
+ const t = p();
17
50
  return JSON.stringify(e) === "{}" && t.personalInfo && (e = t.personalInfo), {
18
51
  id: e.id ?? "",
19
52
  name: e.name ?? "",
@@ -44,9 +77,9 @@ const N = I, A = () => {
44
77
  address: e.address ?? "",
45
78
  description: e.description ?? ""
46
79
  };
47
- }, M = () => sessionStorage.getItem("languages"), C = () => {
80
+ }, T = () => sessionStorage.getItem("languages"), y = () => {
48
81
  let e = JSON.parse(sessionStorage.getItem("projectInfo") || "{}");
49
- const t = u();
82
+ const t = p();
50
83
  return JSON.stringify(e) === "{}" && t.projectInfo && (e = t.projectInfo), {
51
84
  id: (e == null ? void 0 : e.id) ?? 0,
52
85
  code: (e == null ? void 0 : e.code) ?? 0,
@@ -60,7 +93,7 @@ const N = I, A = () => {
60
93
  leaf: (e == null ? void 0 : e.leaf) ?? !1,
61
94
  optional: (e == null ? void 0 : e.leaf) ?? !0
62
95
  };
63
- }, v = () => {
96
+ }, F = () => {
64
97
  let e = JSON.parse(sessionStorage.getItem("project-message") || "{}");
65
98
  return {
66
99
  id: (e == null ? void 0 : e.id) ?? 0,
@@ -85,7 +118,7 @@ const N = I, A = () => {
85
118
  autoTimezone: (e == null ? void 0 : e.autoTimezone) ?? !1,
86
119
  currency: (e == null ? void 0 : e.currency) ?? {}
87
120
  };
88
- }, f = () => {
121
+ }, J = () => {
89
122
  const e = JSON.parse(sessionStorage.getItem("home-config") || "{}");
90
123
  return {
91
124
  applicationCode: (e == null ? void 0 : e.applicationCode) ?? "",
@@ -96,22 +129,13 @@ const N = I, A = () => {
96
129
  displayPosition: (e == null ? void 0 : e.displayPosition) ?? 1,
97
130
  type: (e == null ? void 0 : e.type) ?? null
98
131
  };
99
- }, k = () => {
132
+ }, A = () => {
100
133
  const e = JSON.parse(sessionStorage.getItem("personal-config") || "{}");
101
134
  return {
102
135
  style: (e == null ? void 0 : e.style) ?? "",
103
136
  skinStyle: (e == null ? void 0 : e.skinStyle) ?? ""
104
137
  };
105
- }, j = (e, t) => {
106
- var g;
107
- const r = "permission-btn", a = m(), o = d(location.href, "app") || "", s = t || o || a.currentSubAppCode;
108
- if (!s) return;
109
- const n = d(location.href, "menu") || "", l = e || n || a.currentSubApp.currentMenuCode, c = JSON.parse(sessionStorage.getItem(r) || "{}");
110
- if (!c || JSON.stringify(c) === "{}") return;
111
- const p = (g = c[s]) == null ? void 0 : g[l];
112
- if (p)
113
- return p.length ? p : c[s]["origin-auth"] ? c[s]["origin-auth"][l] ?? [] : [];
114
- }, D = (e, t) => j(e, t) ?? [], m = () => {
138
+ }, C = (e, t) => e ? m()[e] : void 0, x = (e, t) => C(e) ?? [], h = () => {
115
139
  const e = JSON.parse(sessionStorage.getItem("subApps") || "{}");
116
140
  return {
117
141
  appcategorys: e.appcategorys ?? [],
@@ -120,20 +144,20 @@ const N = I, A = () => {
120
144
  subAppList: e.subAppList ?? [],
121
145
  menuCollapses: e.menuCollapses ?? []
122
146
  };
123
- }, U = (e, t = !1) => {
124
- var a, o;
125
- const r = m().subAppList;
147
+ }, E = (e, t = !1) => {
148
+ var r, o;
149
+ const s = h().subAppList;
126
150
  if (e)
127
- return t ? ((a = r == null ? void 0 : r.find((s) => s.code === e)) == null ? void 0 : a.originalMenus) ?? [] : ((o = r == null ? void 0 : r.find((s) => s.code === e)) == null ? void 0 : o.menus) ?? [];
151
+ return t ? ((r = s == null ? void 0 : s.find((n) => n.code === e)) == null ? void 0 : r.originalMenus) ?? [] : ((o = s == null ? void 0 : s.find((n) => n.code === e)) == null ? void 0 : o.menus) ?? [];
128
152
  {
129
- let s = {};
130
- return t ? r == null || r.forEach((n) => {
131
- s[n.code] = n.originalMenus ?? [];
132
- }) : r == null || r.forEach((n) => {
133
- s[n.code] = n.menus ?? [];
134
- }), s;
153
+ let n = {};
154
+ return t ? s == null || s.forEach((a) => {
155
+ n[a.code] = a.originalMenus ?? [];
156
+ }) : s == null || s.forEach((a) => {
157
+ n[a.code] = a.menus ?? [];
158
+ }), n;
135
159
  }
136
- }, E = () => {
160
+ }, M = () => {
137
161
  const e = JSON.parse(sessionStorage.getItem("tabs") || "{}");
138
162
  return {
139
163
  currentCode: e.currentCode ?? "",
@@ -141,31 +165,33 @@ const N = I, A = () => {
141
165
  tabMap: e.tabMap ?? {},
142
166
  preTab: e.preTab ?? {}
143
167
  };
144
- }, z = () => {
145
- const e = u(), t = sessionStorage.getItem("minioAddress");
168
+ }, k = () => {
169
+ const e = p(), t = sessionStorage.getItem("minioAddress");
146
170
  return t || (e.baseURL ? e.baseURL : location.origin);
147
- }, x = () => ({
171
+ }, U = () => ({
148
172
  instanceInfo: JSON.parse(sessionStorage.getItem("instance") || "{}").instanceInfo ?? {}
149
- }), F = () => localStorage.getItem("fav-icon") || "./logo.svg";
150
- N() || S();
151
- var i;
152
- (i = C()) != null && i.id || y();
173
+ }), v = () => localStorage.getItem("fav-icon") || "./logo.svg";
174
+ I() || d();
175
+ var u;
176
+ (u = y()) != null && u.id || i();
153
177
  export {
154
- F as getFavIcon,
155
- f as getHomeInfo,
156
- x as getInstanceInfo,
157
- M as getLanguages,
158
- U as getMenus,
159
- z as getMinioAddress,
160
- j as getPageAuth,
161
- D as getPageAuthBtn,
162
- k as getPersonalConfig,
163
- J as getPersonalInfo,
164
- C as getProjectInfo,
165
- v as getProjectMessage,
166
- m as getSubApps,
167
- E as getTabInfo,
178
+ m as getAuthobj,
179
+ v as getFavIcon,
180
+ J as getHomeInfo,
181
+ U as getInstanceInfo,
182
+ T as getLanguages,
183
+ P as getMenuItemInfo,
184
+ E as getMenus,
185
+ k as getMinioAddress,
186
+ C as getPageAuth,
187
+ x as getPageAuthBtn,
188
+ A as getPersonalConfig,
189
+ f as getPersonalInfo,
190
+ y as getProjectInfo,
191
+ F as getProjectMessage,
192
+ h as getSubApps,
193
+ M as getTabInfo,
168
194
  O as getTenantInfo,
169
- N as getToken,
170
- A as getUserInfo
195
+ I as getToken,
196
+ b as getUserInfo
171
197
  };
Binary file