jmash-core 0.1.14 → 0.1.15

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 (33) hide show
  1. package/dist/{401-C0q_e1zJ.mjs → 401-C-Z61lLd.mjs} +1 -1
  2. package/dist/{404-WP7omG9z.mjs → 404-B0xdJSOl.mjs} +1 -1
  3. package/dist/{BarChart-DjOjRVDo.mjs → BarChart-CVVuHHkX.mjs} +1 -1
  4. package/dist/assets/749f2ccf565925d5.jpg +0 -0
  5. package/dist/{index-CVxxMlrU.mjs → index-Bd-9PguH.mjs} +7673 -7393
  6. package/dist/index-BeclKUkp.mjs +26 -0
  7. package/dist/{index-CKwO5tJ6.mjs → index-CJ7wU_M7.mjs} +2 -2
  8. package/dist/{index-BWPCazOM.mjs → index-CQK8n-wP.mjs} +1 -1
  9. package/dist/{index-U1XG9RWU.mjs → index-DI57cJJp.mjs} +85 -78
  10. package/dist/{index-DlWOd_33.mjs → index-D_w6Hgrj.mjs} +3 -3
  11. package/dist/index.mjs +60 -58
  12. package/dist/{profile-BKMc1ACK.mjs → profile-6d2duxJR.mjs} +1 -1
  13. package/dist/{runAs-BkWJ96tl.mjs → runAs-faf8rkih.mjs} +1 -1
  14. package/dist/{runAs.vue_vue_type_script_setup_true_lang-DdgZ9dNt.mjs → runAs.vue_vue_type_script_setup_true_lang-owDiLD86.mjs} +1 -1
  15. package/dist/style.css +1 -1
  16. package/dist/{types-CIxV5TtA.mjs → types-3onZoSqF.mjs} +41 -38
  17. package/dist/{updatePwd-DdNcURoD.mjs → updatePwd-Bje9j_CP.mjs} +1 -1
  18. package/dist/{updatePwd.vue_vue_type_script_setup_true_lang-BiODj6l4.mjs → updatePwd.vue_vue_type_script_setup_true_lang-Z21pA8yn.mjs} +1 -1
  19. package/dts/src/api/auth/index.d.ts +8 -2
  20. package/dts/src/api/auth/types.d.ts +26 -0
  21. package/dts/src/components/JmashMultiImageUpload/index.vue.d.ts +1 -1
  22. package/dts/src/components/RegisterForm/index.vue.d.ts +2 -0
  23. package/dts/src/index.d.ts +3 -1
  24. package/dts/src/lang/package/zh-cn.d.ts +27 -0
  25. package/dts/src/layout/components/Sidebar/components/SidebarMenuItemTitle.vue.d.ts +1 -1
  26. package/dts/src/router/index.d.ts +1 -0
  27. package/dts/src/types/index.d.ts +1 -0
  28. package/dts/src/views/dashboard/components/BarChart.vue.d.ts +1 -1
  29. package/dts/src/views/dashboard/components/FunnelChart.vue.d.ts +1 -1
  30. package/dts/src/views/dashboard/components/PieChart.vue.d.ts +1 -1
  31. package/dts/src/views/dashboard/components/RadarChart.vue.d.ts +1 -1
  32. package/dts/src/views/register/index.vue.d.ts +2 -0
  33. package/package.json +1 -1
@@ -1,12 +1,12 @@
1
- import { createElementBlock as I, openBlock as y, createElementVNode as u, defineComponent as B, ref as V, reactive as f, resolveComponent as i, Fragment as D, createVNode as t, withCtx as l, createTextVNode as _, toDisplayString as v } from "vue";
2
- import { t as E, b as w, v as N, w as q, x as R } from "./index-CVxxMlrU.mjs";
3
- const S = {
1
+ import { createElementBlock as y, openBlock as k, createElementVNode as u, defineComponent as M, ref as I, reactive as f, resolveComponent as i, Fragment as $, createVNode as t, withCtx as l, createTextVNode as _, toDisplayString as C } from "vue";
2
+ import { t as z, v, b as w, w as A, x as B } from "./index-Bd-9PguH.mjs";
3
+ const N = {
4
4
  viewBox: "0 0 1024 1024",
5
5
  width: "1.2em",
6
6
  height: "1.2em"
7
7
  };
8
- function A(k, c) {
9
- return y(), I("svg", S, c[0] || (c[0] = [
8
+ function T(x, c) {
9
+ return k(), y("svg", N, c[0] || (c[0] = [
10
10
  u("path", {
11
11
  fill: "currentColor",
12
12
  d: "M160 160v704h704V160zm-32-64h768a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H128a32 32 0 0 1-32-32V128a32 32 0 0 1 32-32"
@@ -17,10 +17,10 @@ function A(k, c) {
17
17
  }, null, -1)
18
18
  ]));
19
19
  }
20
- const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { class: "image-slot" }, j = { class: "dialog-footer" }, J = /* @__PURE__ */ B({
20
+ const q = { name: "ep-picture", render: T }, S = { class: "h-[40px]" }, L = { class: "image-slot" }, O = { class: "dialog-footer" }, Y = /* @__PURE__ */ M({
21
21
  __name: "types",
22
- setup(k) {
23
- const c = V(), m = f({
22
+ setup(x) {
23
+ const c = I(), m = f({
24
24
  title: "",
25
25
  visible: !1
26
26
  }), n = f({
@@ -32,22 +32,22 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
32
32
  captchaId: "",
33
33
  captchaCode: "",
34
34
  validCode: ""
35
- }), g = V(), C = f({
35
+ }), g = I(), h = f({
36
36
  captchaCode: [{ required: !0, message: "请输入验证码", trigger: "blur" }],
37
37
  name: [{ required: !0, message: "请输入邮箱或手机号", trigger: "blur" }]
38
38
  // validCode: [
39
39
  // { required: true, message: "请输入6位数字的验证码", trigger: "blur" },
40
40
  // ],
41
41
  });
42
- function h() {
43
- E().then(({ data: a }) => {
42
+ function b() {
43
+ z().then(({ data: a }) => {
44
44
  o.captchaId = a.captchaId, c.value = a.base64Image, m.visible = !0, o.captchaCode = "";
45
45
  });
46
46
  }
47
- function x() {
48
- h();
47
+ function D() {
48
+ b();
49
49
  }
50
- const F = async () => {
50
+ const P = async () => {
51
51
  var a;
52
52
  await ((a = g.value) == null ? void 0 : a.validate((e) => {
53
53
  if (e) {
@@ -56,9 +56,12 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
56
56
  tenant: w().user.tenant,
57
57
  name: o.name,
58
58
  captchaId: o.captchaId,
59
- captchaCode: o.captchaCode
59
+ captchaCode: o.captchaCode,
60
+ sendValidCode: !0,
61
+ directoryId: v.APP_DIRECTORY_ID,
62
+ product: v.APP_PRODUCT
60
63
  };
61
- N(p).then(({ data: r }) => {
64
+ A(p).then(({ data: r }) => {
62
65
  console.log(r);
63
66
  const s = window.setInterval(() => {
64
67
  n.content = n.timers + "s后重新发送", n.timers--, n.disabled = !0, n.timers < 0 && (n.timers = 60, n.disabled = !1, n.content = "重新发送验证码", window.clearInterval(s));
@@ -67,28 +70,28 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
67
70
  }
68
71
  }));
69
72
  };
70
- function M() {
73
+ function R() {
71
74
  const a = {
72
75
  tenant: w().user.tenant,
73
76
  directoryId: "jmash",
74
77
  name: o.name,
75
78
  validCode: o.validCode,
76
- clientId: q.APP_CLIENT_ID,
79
+ clientId: v.APP_CLIENT_ID,
77
80
  scope: ""
78
81
  };
79
- R(a).then((e) => {
82
+ B(a).then((e) => {
80
83
  console.log(e);
81
84
  });
82
85
  }
83
86
  return (a, e) => {
84
- const p = i("el-input"), r = i("el-form-item"), s = i("el-button"), b = i("el-form"), U = L, $ = i("el-image"), z = i("el-dialog");
85
- return y(), I(D, null, [
86
- t(b, {
87
+ const p = i("el-input"), r = i("el-form-item"), s = i("el-button"), V = i("el-form"), U = q, E = i("el-image"), F = i("el-dialog");
88
+ return k(), y($, null, [
89
+ t(V, {
87
90
  ref_key: "ruleFormRef",
88
91
  ref: g,
89
92
  size: "large",
90
93
  model: o,
91
- rules: C
94
+ rules: h
92
95
  }, {
93
96
  default: l(() => [
94
97
  t(r, { prop: "name" }, {
@@ -113,10 +116,10 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
113
116
  append: l(() => [
114
117
  t(s, {
115
118
  disabled: n.disabled,
116
- onClick: x
119
+ onClick: D
117
120
  }, {
118
121
  default: l(() => [
119
- _(v(n.content), 1)
122
+ _(C(n.content), 1)
120
123
  ]),
121
124
  _: 1
122
125
  }, 8, ["disabled"])
@@ -131,7 +134,7 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
131
134
  t(s, {
132
135
  type: "primary",
133
136
  class: "w-full",
134
- onClick: M
137
+ onClick: R
135
138
  }, {
136
139
  default: l(() => e[5] || (e[5] = [
137
140
  _(" 登录 ")
@@ -145,39 +148,39 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
145
148
  ]),
146
149
  _: 1
147
150
  }, 8, ["model", "rules"]),
148
- t(z, {
151
+ t(F, {
149
152
  title: "提示",
150
153
  modelValue: m.visible,
151
154
  "onUpdate:modelValue": e[4] || (e[4] = (d) => m.visible = d),
152
155
  width: "500px"
153
156
  }, {
154
157
  footer: l(() => [
155
- u("div", j, [
158
+ u("div", O, [
156
159
  t(s, {
157
160
  onClick: e[3] || (e[3] = (d) => m.visible = !1)
158
161
  }, {
159
162
  default: l(() => [
160
- _(v(a.$t("common.cancel")), 1)
163
+ _(C(a.$t("common.cancel")), 1)
161
164
  ]),
162
165
  _: 1
163
166
  }),
164
167
  t(s, {
165
168
  type: "primary",
166
- onClick: F
169
+ onClick: P
167
170
  }, {
168
171
  default: l(() => [
169
- _(v(a.$t("common.confirm")), 1)
172
+ _(C(a.$t("common.confirm")), 1)
170
173
  ]),
171
174
  _: 1
172
175
  })
173
176
  ])
174
177
  ]),
175
178
  default: l(() => [
176
- t(b, {
179
+ t(V, {
177
180
  ref: "pwdFormRef",
178
181
  size: "large",
179
182
  model: o,
180
- rules: C
183
+ rules: h
181
184
  }, {
182
185
  default: l(() => [
183
186
  t(r, { prop: "captchaCode" }, {
@@ -189,14 +192,14 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
189
192
  placeholder: a.$t("login.captchaCode"),
190
193
  class: "w-[60%]"
191
194
  }, null, 8, ["modelValue", "placeholder"]),
192
- u("div", P, [
193
- t($, {
195
+ u("div", S, [
196
+ t(E, {
194
197
  src: c.value,
195
- onClick: h,
198
+ onClick: b,
196
199
  class: "w-[130px] h-[40px] cursor-pointer"
197
200
  }, {
198
201
  error: l(() => [
199
- u("div", T, [
202
+ u("div", L, [
200
203
  t(U)
201
204
  ])
202
205
  ]),
@@ -217,5 +220,5 @@ const L = { name: "ep-picture", render: A }, P = { class: "h-[40px]" }, T = { cl
217
220
  }
218
221
  });
219
222
  export {
220
- J as default
223
+ Y as default
221
224
  };
@@ -1,4 +1,4 @@
1
- import { _ as f } from "./updatePwd.vue_vue_type_script_setup_true_lang-BiODj6l4.mjs";
1
+ import { _ as f } from "./updatePwd.vue_vue_type_script_setup_true_lang-Z21pA8yn.mjs";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as q, ref as v, toRefs as E, reactive as V, resolveComponent as i, createBlock as O, openBlock as A, unref as t, isRef as D, withCtx as n, createVNode as r, createElementVNode as U, createTextVNode as g, toDisplayString as _ } from "vue";
2
2
  import { ElMessage as B } from "element-plus";
3
- import { y as b, aD as I } from "./index-CVxxMlrU.mjs";
3
+ import { y as b, aD as I } from "./index-Bd-9PguH.mjs";
4
4
  import { useI18n as S } from "vue-i18n";
5
5
  const z = { class: "dialog-footer" }, G = /* @__PURE__ */ q({
6
6
  __name: "updatePwd",
@@ -1,5 +1,5 @@
1
1
  import type { AxiosPromise } from "axios";
2
- import type { CaptchaResult, LoginData, LoginResult, UserInfo, RolesPerms, LoginQrcodeResp, LoginQrcodeReq, MyOrganList } from "./types";
2
+ import type { CaptchaResult, LoginData, LoginResult, UserInfo, RolesPerms, LoginQrcodeResp, LoginQrcodeReq, MyOrganList, RegisterForm, SendValidCodeReq } from "./types";
3
3
  /**
4
4
  * 登录API
5
5
  *
@@ -7,6 +7,12 @@ import type { CaptchaResult, LoginData, LoginResult, UserInfo, RolesPerms, Login
7
7
  * @returns
8
8
  */
9
9
  export declare function loginApi(data: LoginData): AxiosPromise<LoginResult>;
10
+ /**
11
+ * 手机号邮箱注册登录
12
+ * @param token
13
+ * @returns
14
+ */
15
+ export declare function registerApi(data: RegisterForm): AxiosPromise<LoginResult>;
10
16
  /**
11
17
  * 刷新Token
12
18
  */
@@ -22,7 +28,7 @@ export declare function getCaptchaApi(): AxiosPromise<CaptchaResult>;
22
28
  /**
23
29
  * 获取手机号验证码
24
30
  */
25
- export declare function sendcode(data: any): AxiosPromise<CaptchaResult>;
31
+ export declare function sendcode(data: SendValidCodeReq): AxiosPromise<CaptchaResult>;
26
32
  /**
27
33
  * 通过验证码登录
28
34
  */
@@ -252,4 +252,30 @@ export interface MyOrganModel {
252
252
  appName: string;
253
253
  appQrcodeUrl: string;
254
254
  }
255
+ export interface RegisterForm {
256
+ captchaCode?: string;
257
+ captchaId?: string;
258
+ tenant?: string;
259
+ requestId: string;
260
+ directoryId?: string;
261
+ clientId?: string;
262
+ name: string;
263
+ validCode: string;
264
+ realName?: string;
265
+ nickName: string;
266
+ avatar?: string;
267
+ birthDate?: string;
268
+ gender?: string;
269
+ pwd: string;
270
+ repeatPwd: string;
271
+ }
272
+ export interface SendValidCodeReq {
273
+ tenant: string;
274
+ directoryId: string;
275
+ name: string;
276
+ captchaId: string;
277
+ captchaCode: string;
278
+ product: string;
279
+ sendValidCode: boolean;
280
+ }
255
281
  export {};
@@ -59,7 +59,7 @@ declare const _default: import("vue").DefineComponent<globalThis.ExtractPropType
59
59
  width: number;
60
60
  pictureUrl: unknown[];
61
61
  height: number;
62
- listType: "text" | "picture" | "picture-card";
62
+ listType: "picture" | "text" | "picture-card";
63
63
  limit: number;
64
64
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
65
65
  export default _default;
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ export default _default;
@@ -27,12 +27,14 @@ import routerRef from "./router";
27
27
  export { routerRef };
28
28
  import directive from "./directive";
29
29
  export { directive };
30
- export { Layout, LoginPage, MultiFactorLoginPage, ProfilePage, Error401Page, Error404Page, DashboardPage, RedirectPage, ChangeOrgan, } from "./router";
30
+ export { Layout, LoginPage, MultiFactorLoginPage, ProfilePage, Error401Page, Error404Page, DashboardPage, RedirectPage, ChangeOrgan, RegisterPage, } from "./router";
31
31
  import i18n from "./lang/index";
32
32
  export { i18n };
33
33
  import "element-plus/theme-chalk/dark/css-vars.css";
34
34
  import "./styles/index.scss";
35
35
  import "uno.css";
36
+ import RegisterForm from "./components/RegisterForm/index.vue";
37
+ export { RegisterForm };
36
38
  import type { IToolbarConfig, IEditorConfig, IDomEditor } from "@wangeditor-next/editor";
37
39
  export type { IToolbarConfig, IEditorConfig, IDomEditor };
38
40
  import "element-plus/theme-chalk/index.css";
@@ -154,5 +154,32 @@ declare const _default: {
154
154
  imageLtRequired: string;
155
155
  fileLtRequired: string;
156
156
  };
157
+ register: {
158
+ register: string;
159
+ getValidCode: string;
160
+ name: string;
161
+ nemeMobileError: string;
162
+ nameRequired: string;
163
+ captchaCode: string;
164
+ captchaCodeRequired: string;
165
+ validCode: string;
166
+ validCodeRequired: string;
167
+ validCodeTime: string;
168
+ realName: string;
169
+ realNameRequired: string;
170
+ nickName: string;
171
+ nickNameRequired: string;
172
+ avatar: string;
173
+ birthDate: string;
174
+ birthDateRequired: string;
175
+ gender: string;
176
+ genderRequired: string;
177
+ pwd: string;
178
+ pwdRequired: string;
179
+ repeatPwd: string;
180
+ repeatPwdRequired: string;
181
+ pwdRules: string;
182
+ comparePwd: string;
183
+ };
157
184
  };
158
185
  export default _default;
@@ -25,8 +25,8 @@ declare const _default: import("vue").DefineComponent<globalThis.ExtractPropType
25
25
  default: string;
26
26
  };
27
27
  }>> & Readonly<{}>, {
28
+ name: string;
28
29
  title: string;
29
30
  icon: string;
30
- name: string;
31
31
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
32
32
  export default _default;
@@ -2,6 +2,7 @@ import { type Ref } from "vue";
2
2
  import type { RouteRecordRaw, Router } from "vue-router";
3
3
  export declare const Layout: () => Promise<typeof import("@/layout/index.vue")>;
4
4
  export declare const LoginPage: () => Promise<typeof import("@/views/login/index.vue")>;
5
+ export declare const RegisterPage: () => Promise<typeof import("@/views/register/index.vue")>;
5
6
  export declare const MultiFactorLoginPage: () => Promise<typeof import("@/views/login/components/types.vue")>;
6
7
  export declare const ProfilePage: () => Promise<typeof import("@/views/my/profile.vue")>;
7
8
  export declare const Error401Page: () => Promise<typeof import("@/views/error-page/401.vue")>;
@@ -24,6 +24,7 @@ export interface VueMetaEnv {
24
24
  APP_REDIRECT?: string;
25
25
  /** 二维码登录超时时间 */
26
26
  APP_TIMEOUT?: number;
27
+ APP_PRODUCT?: string;
27
28
  }
28
29
  export interface TableColumn {
29
30
  label: string;
@@ -37,8 +37,8 @@ declare const _default: import("vue").DefineComponent<globalThis.ExtractPropType
37
37
  required: true;
38
38
  };
39
39
  }>> & Readonly<{}>, {
40
- id: string;
41
40
  width: string;
41
+ id: string;
42
42
  height: string;
43
43
  className: string;
44
44
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -37,8 +37,8 @@ declare const _default: import("vue").DefineComponent<globalThis.ExtractPropType
37
37
  required: true;
38
38
  };
39
39
  }>> & Readonly<{}>, {
40
- id: string;
41
40
  width: string;
41
+ id: string;
42
42
  height: string;
43
43
  className: string;
44
44
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -37,8 +37,8 @@ declare const _default: import("vue").DefineComponent<globalThis.ExtractPropType
37
37
  required: true;
38
38
  };
39
39
  }>> & Readonly<{}>, {
40
- id: string;
41
40
  width: string;
41
+ id: string;
42
42
  height: string;
43
43
  className: string;
44
44
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -37,8 +37,8 @@ declare const _default: import("vue").DefineComponent<globalThis.ExtractPropType
37
37
  required: true;
38
38
  };
39
39
  }>> & Readonly<{}>, {
40
- id: string;
41
40
  width: string;
41
+ id: string;
42
42
  height: string;
43
43
  className: string;
44
44
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jmash-core",
3
- "version": "0.1.14",
3
+ "version": "0.1.15",
4
4
  "private": false,
5
5
  "module": "dist/index.mjs",
6
6
  "types": "dts/src/index.d.ts",