@befly-addon/admin 1.2.18 → 1.4.1

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.
@@ -83,7 +83,7 @@ import ILucideChevronDown from "~icons/lucide/chevron-down";
83
83
  import EditDialog from "./components/edit.vue";
84
84
  import DetailPanel from "@/components/DetailPanel.vue";
85
85
  import { $Http } from "@/plugins/http";
86
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
86
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
87
87
 
88
88
  definePage({
89
89
  meta: {
@@ -80,7 +80,7 @@ import ILucideChevronDown from "~icons/lucide/chevron-down";
80
80
  import EditDialog from "./components/edit.vue";
81
81
  import DetailPanel from "@/components/DetailPanel.vue";
82
82
  import { $Http } from "@/plugins/http";
83
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
83
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
84
84
 
85
85
  definePage({
86
86
  meta: {
@@ -91,7 +91,7 @@ import ILucideChevronDown from "~icons/lucide/chevron-down";
91
91
  import EditDialog from "./components/edit.vue";
92
92
  import DetailPanel from "@/components/DetailPanel.vue";
93
93
  import { $Http } from "@/plugins/http";
94
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
94
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
95
95
 
96
96
  definePage({
97
97
  meta: {
@@ -90,7 +90,7 @@ import ILucideSend from "~icons/lucide/send";
90
90
  import ILucideCheckCircle from "~icons/lucide/check-circle";
91
91
  import DetailPanel from "@/components/DetailPanel.vue";
92
92
  import { $Http } from "@/plugins/http";
93
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
93
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
94
94
 
95
95
  definePage({
96
96
  meta: {
@@ -54,7 +54,7 @@ import { Button as TButton, Table as TTable, Tag as TTag, Pagination as TPaginat
54
54
  import ILucideRotateCw from "~icons/lucide/rotate-cw";
55
55
  import DetailPanel from "@/components/DetailPanel.vue";
56
56
  import { $Http } from "@/plugins/http";
57
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
57
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
58
58
 
59
59
  definePage({
60
60
  meta: {
@@ -74,7 +74,7 @@ import { Button as TButton, Table as TTable, Tag as TTag, Pagination as TPaginat
74
74
  import ILucideRotateCw from "~icons/lucide/rotate-cw";
75
75
  import DetailPanel from "@/components/DetailPanel.vue";
76
76
  import { $Http } from "@/plugins/http";
77
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
77
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
78
78
 
79
79
  definePage({
80
80
  meta: {
@@ -70,7 +70,7 @@ import ILucideUser from "~icons/lucide/user";
70
70
  import ILucideLock from "~icons/lucide/lock";
71
71
  import { $Http } from "@/plugins/http";
72
72
  import { $Storage } from "@/plugins/storage";
73
- import { hashPassword } from "befly-shared/utils/hashPassword";
73
+ import { hashPassword } from "../../utils/hashPassword";
74
74
 
75
75
  definePage({
76
76
  meta: {
@@ -47,8 +47,8 @@ import {
47
47
  MessagePlugin
48
48
  } from "tdesign-vue-next";
49
49
  import { $Http } from "@/plugins/http";
50
- import { fieldClear } from "befly-shared/utils/fieldClear";
51
- import { hashPassword } from "befly-shared/utils/hashPassword";
50
+ import { fieldClear } from "@/../utils/fieldClear";
51
+ import { hashPassword } from "@/../utils/hashPassword";
52
52
 
53
53
  const $Prop = defineProps({
54
54
  modelValue: {
@@ -79,7 +79,7 @@ import ILucideChevronDown from "~icons/lucide/chevron-down";
79
79
  import EditDialog from "./components/edit.vue";
80
80
  import DetailPanel from "@/components/DetailPanel.vue";
81
81
  import { $Http } from "@/plugins/http";
82
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
82
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
83
83
 
84
84
  definePage({
85
85
  meta: {
@@ -55,7 +55,7 @@ import { Button as TButton, Table as TTable, Tag as TTag, Input as TInput, Messa
55
55
  import ILucideRotateCw from "~icons/lucide/rotate-cw";
56
56
  import ILucideSearch from "~icons/lucide/search";
57
57
  import { $Http } from "@/plugins/http";
58
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
58
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
59
59
  import DetailPanel from "@/components/DetailPanel.vue";
60
60
 
61
61
  definePage({
@@ -44,8 +44,8 @@ import { Button as TButton, Table as TTable, Tag as TTag, MessagePlugin } from "
44
44
  import ILucideRotateCw from "~icons/lucide/rotate-cw";
45
45
  import DetailPanel from "@/components/DetailPanel.vue";
46
46
  import { $Http } from "@/plugins/http";
47
- import { arrayToTree } from "befly-shared/utils/arrayToTree";
48
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
47
+ import { arrayToTree } from "@/utils/arrayToTree";
48
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
49
49
 
50
50
  definePage({
51
51
  meta: {
@@ -42,8 +42,8 @@ import {
42
42
  Button as TButton,
43
43
  MessagePlugin
44
44
  } from "tdesign-vue-next";
45
- import { fieldClear } from "befly-shared/utils/fieldClear";
46
45
  import { $Http } from "@/plugins/http";
46
+ import { fieldClear } from "@/../utils/fieldClear";
47
47
 
48
48
  const $Prop = defineProps({
49
49
  modelValue: {
@@ -44,7 +44,7 @@
44
44
  import { Dialog as TDialog, CheckboxGroup as TCheckboxGroup, Checkbox as TCheckbox, Button as TButton, Input as TInput, MessagePlugin } from "tdesign-vue-next";
45
45
  import ILucideSearch from "~icons/lucide/search";
46
46
  import { $Http } from "@/plugins/http";
47
- import { arrayToTree } from "befly-shared/utils/arrayToTree";
47
+ import { arrayToTree } from "@/../utils/arrayToTree";
48
48
 
49
49
  const $Prop = defineProps({
50
50
  modelValue: {
@@ -102,7 +102,7 @@ import MenuDialog from "./components/menu.vue";
102
102
  import ApiDialog from "./components/api.vue";
103
103
  import DetailPanel from "@/components/DetailPanel.vue";
104
104
  import { $Http } from "@/plugins/http";
105
- import { withDefaultColumns } from "befly-shared/utils/withDefaultColumns";
105
+ import { withDefaultColumns } from "@/utils/withDefaultColumns";
106
106
 
107
107
  definePage({
108
108
  meta: {
@@ -119,9 +119,9 @@ const $Data = $ref({
119
119
  currentRow: null,
120
120
  columns: withDefaultColumns([
121
121
  { colKey: "name", title: "角色名称" },
122
- { colKey: "code", title: "角色代码",width:150 },
123
- { colKey: "menuCount", title: "菜单数量", align: "center",width:100 },
124
- { colKey: "apiCount", title: "接口数量", align: "center",width:100 },
122
+ { colKey: "code", title: "角色代码", width: 150 },
123
+ { colKey: "menuCount", title: "菜单数量", align: "center", width: 100 },
124
+ { colKey: "apiCount", title: "接口数量", align: "center", width: 100 },
125
125
  { colKey: "sort", title: "排序" },
126
126
  { colKey: "state", title: "状态" },
127
127
  { colKey: "description", title: "描述" },
@@ -1,6 +1,5 @@
1
- import { normalizePathnameListInput } from "befly-shared/utils/normalizePathnameListInput";
2
-
3
1
  import adminRoleTable from "../../tables/role.json";
2
+ import { normalizePathnameListInput } from "../../utils/normalizePathnameListInput";
4
3
 
5
4
  export default {
6
5
  name: "保存角色接口权限",
package/apis/role/ins.ts CHANGED
@@ -1,6 +1,5 @@
1
- import { normalizePathnameListInput } from "befly-shared/utils/normalizePathnameListInput";
2
-
3
1
  import adminRoleTable from "../../tables/role.json";
2
+ import { normalizePathnameListInput } from "../../utils/normalizePathnameListInput";
4
3
 
5
4
  export default {
6
5
  name: "创建角色",
@@ -1,6 +1,5 @@
1
- import { normalizePathnameListInput } from "befly-shared/utils/normalizePathnameListInput";
2
-
3
1
  import adminRoleTable from "../../tables/role.json";
2
+ import { normalizePathnameListInput } from "../../utils/normalizePathnameListInput";
4
3
 
5
4
  export default {
6
5
  name: "保存角色菜单权限",
package/apis/role/upd.ts CHANGED
@@ -1,6 +1,5 @@
1
- import { normalizePathnameListInput } from "befly-shared/utils/normalizePathnameListInput";
2
-
3
1
  import adminRoleTable from "../../tables/role.json";
2
+ import { normalizePathnameListInput } from "../../utils/normalizePathnameListInput";
4
3
 
5
4
  export default {
6
5
  name: "更新角色",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@befly-addon/admin",
3
- "version": "1.2.18",
4
- "gitHead": "0914e9a6efb3f41136034f14d5f9cda4d5e7c3d0",
3
+ "version": "1.4.1",
4
+ "gitHead": "2ff9d8fc0422aa7332afdd7c19d16493004cdfcf",
5
5
  "private": false,
6
6
  "description": "Befly - 管理后台功能组件",
7
7
  "keywords": [
@@ -48,7 +48,6 @@
48
48
  "typecheck": "bunx tsgo -p tsconfig.json --noEmit"
49
49
  },
50
50
  "dependencies": {
51
- "befly-shared": "^1.3.11",
52
51
  "nodemailer": "^7.0.12",
53
52
  "ua-parser-js": "^2.0.7"
54
53
  },
package/plugins/email.ts CHANGED
@@ -18,6 +18,7 @@ const defaultConfig: EmailConfig = {
18
18
  };
19
19
 
20
20
  export default {
21
+ enable: true,
21
22
  deps: ["db", "logger", "config"],
22
23
  async handler(befly): Promise<EmailHelper> {
23
24
  // 从 befly.config.addons.admin.email 获取配置