free-fe-core-modules 0.0.9 → 0.0.11
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/components/Dialog/BasicDialog.vue +1 -1
- package/components/ThemeSwitch/index.vue +12 -2
- package/composible/useObjectData.js +3 -3
- package/free-field/Fields/PermissionEditor.vue +1 -1
- package/i18n/en-us/index.js +25 -1
- package/i18n/zh-cn/index.js +91 -66
- package/index.js +2 -1
- package/package.json +1 -1
- package/view/dict/index.vue +1 -1
- package/view/menu/index.vue +2 -2
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
</template>
|
|
103
103
|
|
|
104
104
|
<script>
|
|
105
|
-
import { defineComponent, ref, computed } from 'vue';
|
|
105
|
+
import { defineComponent, ref, computed, watch } from 'vue';
|
|
106
106
|
import { useFormValidator } from '../../composible/useFormValidator';
|
|
107
107
|
import FreeField from '../../free-field/composible/fieldWrapper';
|
|
108
108
|
import EIcon from '../Basic/EIcon.vue';
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<
|
|
3
|
+
<div class="theme-components-list" v-if="theme">
|
|
4
|
+
<component
|
|
5
|
+
v-for="(tc, idx) in themeComponents[theme]"
|
|
6
|
+
:key="idx"
|
|
7
|
+
:is="tc"></component>
|
|
8
|
+
</div>
|
|
4
9
|
<q-btn
|
|
5
10
|
flat
|
|
6
11
|
:icon="icon"
|
|
@@ -46,7 +51,12 @@ export default defineComponent({
|
|
|
46
51
|
Object.keys(this.ctx.modules)
|
|
47
52
|
.filter((m) => this.ctx.modules[m].IsTheme)
|
|
48
53
|
.forEach((m) => {
|
|
49
|
-
Object.assign(components, this.ctx.modules[m].components || {});
|
|
54
|
+
// Object.assign(components, this.ctx.modules[m].components || {});
|
|
55
|
+
// can have same theme from diff modules
|
|
56
|
+
Object.keys(this.ctx.modules[m].components || {}).forEach((ck) => {
|
|
57
|
+
components[ck] = components[ck] || [];
|
|
58
|
+
components[ck].push(this.ctx.modules[m].components[ck]);
|
|
59
|
+
});
|
|
50
60
|
});
|
|
51
61
|
|
|
52
62
|
return components;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref, getCurrentInstance, watch, watchEffect
|
|
1
|
+
import { ref, unref, getCurrentInstance, watch, watchEffect } from "vue";
|
|
2
2
|
|
|
3
3
|
export const objectDataProps = {
|
|
4
4
|
GetData: Function,
|
|
@@ -44,12 +44,12 @@ export function useObjectData(props, ctx) {
|
|
|
44
44
|
|
|
45
45
|
if (typeof getData === 'function') {
|
|
46
46
|
Promise.resolve(getData(...args)).then((d) => {
|
|
47
|
-
Object.assign(data.value, d
|
|
47
|
+
Object.assign(data.value, unref(d));
|
|
48
48
|
}).finally(() => {
|
|
49
49
|
callsLeft.value --;
|
|
50
50
|
});
|
|
51
51
|
} else {
|
|
52
|
-
Object.assign(data.value, getData
|
|
52
|
+
Object.assign(data.value, unref(getData));
|
|
53
53
|
callsLeft.value --;
|
|
54
54
|
}
|
|
55
55
|
}
|
|
@@ -138,7 +138,7 @@ export default defineComponent({
|
|
|
138
138
|
watch(hasThis, (v) => {
|
|
139
139
|
if (v) {
|
|
140
140
|
// checked from unchecked
|
|
141
|
-
fieldData.value = fieldData.value || {};
|
|
141
|
+
fieldData.value = fieldData.value || { has: true };
|
|
142
142
|
} else {
|
|
143
143
|
// unchecked from checked
|
|
144
144
|
fieldData.value = undefined;
|
package/i18n/en-us/index.js
CHANGED
|
@@ -67,4 +67,28 @@ export default {
|
|
|
67
67
|
validatorPwd3Description: "Passwords 6-16 characters in length, must contain numbers, uppercase letters, lowercase letters, special characters",
|
|
68
68
|
validatorPwd4Name: "Password (strength four)",
|
|
69
69
|
validatorPwd4Description: "A password of 6-16 digits in length must contain numbers, at least 2 uppercase letters, at least 2 lowercase letters, special characters",
|
|
70
|
-
|
|
70
|
+
|
|
71
|
+
删除确认: "Do you want to delete {type} '{name}'?",
|
|
72
|
+
菜单: 'menu',
|
|
73
|
+
字典项: 'dictionary',
|
|
74
|
+
|
|
75
|
+
自定义: 'customize',
|
|
76
|
+
自定义路径: 'customized path',
|
|
77
|
+
系统管理: 'system management',
|
|
78
|
+
菜单管理: 'menu management',
|
|
79
|
+
返回: 'back',
|
|
80
|
+
暂无数据: 'NO DATA',
|
|
81
|
+
审核中: 'under review',
|
|
82
|
+
审核通过: 'reviewed',
|
|
83
|
+
审核不通过: 'review failed',
|
|
84
|
+
添加: 'add',
|
|
85
|
+
字典管理: 'dictionary management',
|
|
86
|
+
日期: 'date',
|
|
87
|
+
代码: 'code',
|
|
88
|
+
信息: 'info',
|
|
89
|
+
描述: 'description',
|
|
90
|
+
错误代码管理: 'error code management',
|
|
91
|
+
代码数: '',
|
|
92
|
+
系统设置: 'system settings',
|
|
93
|
+
保存: 'save',
|
|
94
|
+
}
|
package/i18n/zh-cn/index.js
CHANGED
|
@@ -1,73 +1,98 @@
|
|
|
1
1
|
export default {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
2
|
+
justNow: '刚刚',
|
|
3
|
+
secondsAgo: '秒之前',
|
|
4
|
+
minutesAgo: '分钟之前',
|
|
5
|
+
hoursAgo: '小时之前',
|
|
6
|
+
daysAgo: '天之前',
|
|
7
|
+
monthsAgo: '月之前',
|
|
8
|
+
yearsAgo: '年之前',
|
|
9
|
+
SwitchTheme: '切换样式',
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
11
|
+
validatorNotEmptyName: "非空",
|
|
12
|
+
validatorNotEmptyDescription: "不能为空",
|
|
13
|
+
validatorMobilePhoneName: "手机号",
|
|
14
|
+
validatorMobilePhoneDescription: "中国手机号码格式",
|
|
15
|
+
validatorEmailName: "邮箱",
|
|
16
|
+
validatorEmailDescription: "",
|
|
17
|
+
validatorPhoneOrEmailName: "手机号或邮箱",
|
|
18
|
+
validatorPhoneOrEmailDescription: "",
|
|
19
|
+
validatorChinaIDNumberName: "中国身份证号码",
|
|
20
|
+
validatorChinaIDNumberDescription: "",
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
22
|
+
validatorOnlyNumberName: "只能是数字",
|
|
23
|
+
validatorOnlyNumberDescription: "",
|
|
24
|
+
validatorOnlyCharName: "只能是字母",
|
|
25
|
+
validatorOnlyCharDescription: "",
|
|
26
|
+
validatorOnlyUpCharName: "只能是大写字母",
|
|
27
|
+
validatorOnlyUpCharDescription: "",
|
|
28
|
+
validatorOnlyLowerCharName: "只能是小写字母",
|
|
29
|
+
validatorOnlyLowerCharDescription: "",
|
|
30
|
+
validatorOnlyChineseName: "只能是中文",
|
|
31
|
+
validatorOnlyChineseDescription: "",
|
|
32
|
+
validatorOnlyCCName: "只能是中文或字母",
|
|
33
|
+
validatorOnlyCCDescription: "",
|
|
34
|
+
validatorOnlyCCNName: "只能是中文或字母或数字",
|
|
35
|
+
validatorOnlyCCNDescription: "",
|
|
36
|
+
validatorOnlyCNName: "只能是中文或数字",
|
|
37
|
+
validatorOnlyCNDescription: "",
|
|
38
|
+
validatorOnlyCNUName: "只能是中文或数字或下划线",
|
|
39
|
+
validatorOnlyCNUDescription: "",
|
|
40
|
+
validatorOnlyCNSName: "只能是中文或数字或特殊字符",
|
|
41
|
+
validatorOnlyCNSDescription:
|
|
42
|
+
`只能是中文或数字或("."、{'@'}、"<"、">"、"_"、"?")`,
|
|
43
43
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
44
|
+
validatorOnlyIntegerName: "只能是整数",
|
|
45
|
+
validatorOnlyIntegerDescription: "",
|
|
46
|
+
validatorOnlyPIName: "只能是正整数",
|
|
47
|
+
validatorOnlyPIDescription: "",
|
|
48
|
+
validatorOnlyPIZName: "只能是正整数或零",
|
|
49
|
+
validatorOnlyPIZDescription: "",
|
|
50
|
+
validatorOnlyNIName: "只能是负整数",
|
|
51
|
+
validatorOnlyNIDescription: "",
|
|
52
|
+
validatorOnlyNIZName: "只能是负整数或零",
|
|
53
|
+
validatorOnlyNIZDescription: "",
|
|
54
54
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
55
|
+
validatorUrlName: "URL地址",
|
|
56
|
+
validatorUrlDescription: "",
|
|
57
|
+
validatorOfficePhoneName: "固定电话号码",
|
|
58
|
+
validatorOfficePhoneDescription: "固定电话号码(区号-号码)",
|
|
59
|
+
validatorChinaZipName: "中国邮政编码",
|
|
60
|
+
validatorChinaZipDescription: "",
|
|
61
|
+
|
|
62
|
+
validatorPwd1Name: "密码(强度一)",
|
|
63
|
+
validatorPwd1Description: "长度在6-16位之间的任意密码",
|
|
64
|
+
validatorPwd2Name: "密码(强度二)",
|
|
65
|
+
validatorPwd2Description:
|
|
66
|
+
"长度在6-16位的密码,必须包含数字、大写字母、小写字母",
|
|
67
|
+
validatorPwd3Name: "密码(强度三)",
|
|
68
|
+
validatorPwd3Description:
|
|
69
|
+
"长度在6-16位的密码,必须包含数字、大写字母、小写字母、特殊字符",
|
|
70
|
+
validatorPwd4Name: "密码(强度四)",
|
|
71
|
+
validatorPwd4Description:
|
|
72
|
+
"长度在6-16位的密码,必须包含数字、至少2个大写字母、至少2个小写字母、特殊字符",
|
|
73
|
+
|
|
74
|
+
删除确认: "确认删除{type}'{name}'吗?",
|
|
75
|
+
菜单: '菜单',
|
|
76
|
+
字典项: '字典项',
|
|
77
|
+
|
|
78
|
+
自定义: '自定义',
|
|
79
|
+
自定义路径: '自定义路径',
|
|
80
|
+
系统管理: '系统管理',
|
|
81
|
+
菜单管理: '菜单管理',
|
|
82
|
+
返回: '返回',
|
|
83
|
+
暂无数据: '暂 无 数 据',
|
|
84
|
+
审核中: '审核中',
|
|
85
|
+
审核通过: '审核通过',
|
|
86
|
+
审核不通过: '审核不通过',
|
|
87
|
+
添加: '添加',
|
|
88
|
+
字典管理: '字典管理',
|
|
89
|
+
日期: '日期',
|
|
90
|
+
代码: '代码',
|
|
91
|
+
信息: '信息',
|
|
92
|
+
描述: '描述',
|
|
93
|
+
错误代码管理: '错误代码管理',
|
|
94
|
+
代码数: '代码数',
|
|
95
|
+
系统设置: '系统设置',
|
|
96
|
+
保存: '保存',
|
|
61
97
|
|
|
62
|
-
validatorPwd1Name: "密码(强度一)",
|
|
63
|
-
validatorPwd1Description: "长度在6-16位之间的任意密码",
|
|
64
|
-
validatorPwd2Name: "密码(强度二)",
|
|
65
|
-
validatorPwd2Description:
|
|
66
|
-
"长度在6-16位的密码,必须包含数字、大写字母、小写字母",
|
|
67
|
-
validatorPwd3Name: "密码(强度三)",
|
|
68
|
-
validatorPwd3Description:
|
|
69
|
-
"长度在6-16位的密码,必须包含数字、大写字母、小写字母、特殊字符",
|
|
70
|
-
validatorPwd4Name: "密码(强度四)",
|
|
71
|
-
validatorPwd4Description:
|
|
72
|
-
"长度在6-16位的密码,必须包含数字、至少2个大写字母、至少2个小写字母、特殊字符",
|
|
73
98
|
}
|
package/index.js
CHANGED
|
@@ -310,6 +310,7 @@ export default (app, root) => {
|
|
|
310
310
|
Name: "Enabled",
|
|
311
311
|
Label: "启用",
|
|
312
312
|
Type: "Boolean",
|
|
313
|
+
showLabel: true,
|
|
313
314
|
},
|
|
314
315
|
{
|
|
315
316
|
Name: "Description",
|
|
@@ -394,4 +395,4 @@ export default (app, root) => {
|
|
|
394
395
|
validatorPwd4: (d) => /^.*(?=.{6,16})(?=.*\d)(?=.*[A-Z]{2,})(?=.*[a-z]{2,})(?=.*[!@#$%^&*?\(\)]).*$/.test(d),
|
|
395
396
|
},
|
|
396
397
|
}
|
|
397
|
-
};
|
|
398
|
+
};
|
package/package.json
CHANGED
package/view/dict/index.vue
CHANGED
|
@@ -237,7 +237,7 @@ export default defineComponent({
|
|
|
237
237
|
|
|
238
238
|
this.$MsgDialog({
|
|
239
239
|
type: '',
|
|
240
|
-
content:
|
|
240
|
+
content: this.$t('删除确认', { type: this.$t('字典项'), name: n.Name }),
|
|
241
241
|
canCancel: true,
|
|
242
242
|
okText: this.$t('okButtonText'),
|
|
243
243
|
cancelText: this.$t('cancelButtonText'),
|
package/view/menu/index.vue
CHANGED
|
@@ -116,7 +116,7 @@ export default defineComponent({
|
|
|
116
116
|
selectedMenuNode,
|
|
117
117
|
editingMenu,
|
|
118
118
|
menuFields,
|
|
119
|
-
data,
|
|
119
|
+
data,
|
|
120
120
|
refreshData,
|
|
121
121
|
validate,
|
|
122
122
|
};
|
|
@@ -226,7 +226,7 @@ export default defineComponent({
|
|
|
226
226
|
|
|
227
227
|
this.$MsgDialog({
|
|
228
228
|
type: '',
|
|
229
|
-
content:
|
|
229
|
+
content: this.$t('删除确认', {type: this.$t('菜单'), name: n.Label}),
|
|
230
230
|
canCancel: true,
|
|
231
231
|
okText: this.$t('okButtonText'),
|
|
232
232
|
cancelText: this.$t('cancelButtonText'),
|