@liujitcn/kratos-admin-system 0.0.54 → 0.0.55
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.
|
@@ -35,10 +35,6 @@ export interface BaseFile {
|
|
|
35
35
|
id: number;
|
|
36
36
|
/** 租户ID */
|
|
37
37
|
tenant_id: number;
|
|
38
|
-
/** 存储供应商 */
|
|
39
|
-
provider: number;
|
|
40
|
-
/** 存储桶名称 */
|
|
41
|
-
bucket_name: string;
|
|
42
38
|
/** 文件目录 */
|
|
43
39
|
file_directory: string;
|
|
44
40
|
/** 文件唯一标识 */
|
|
@@ -61,6 +57,8 @@ export interface BaseFile {
|
|
|
61
57
|
created_by: number;
|
|
62
58
|
/** 创建时间 */
|
|
63
59
|
created_at: string;
|
|
60
|
+
/** 文件访问方式:1公开,2需要访问令牌 */
|
|
61
|
+
access_mode: number;
|
|
64
62
|
}
|
|
65
63
|
/** Admin文件资产管理服务。 */
|
|
66
64
|
export interface BaseFileService {
|
|
@@ -49,10 +49,6 @@ export interface BaseFile {
|
|
|
49
49
|
id: number;
|
|
50
50
|
/** 租户ID */
|
|
51
51
|
tenant_id: number;
|
|
52
|
-
/** 存储供应商 */
|
|
53
|
-
provider: number;
|
|
54
|
-
/** 存储桶名称 */
|
|
55
|
-
bucket_name: string;
|
|
56
52
|
/** 文件目录 */
|
|
57
53
|
file_directory: string;
|
|
58
54
|
/** 文件唯一标识 */
|
|
@@ -75,6 +71,8 @@ export interface BaseFile {
|
|
|
75
71
|
created_by: number;
|
|
76
72
|
/** 创建时间 */
|
|
77
73
|
created_at: string;
|
|
74
|
+
/** 文件访问方式:1公开,2需要访问令牌 */
|
|
75
|
+
access_mode: number;
|
|
78
76
|
}
|
|
79
77
|
|
|
80
78
|
/** Admin文件资产管理服务。 */
|
|
@@ -44,7 +44,11 @@
|
|
|
44
44
|
/>
|
|
45
45
|
</template>
|
|
46
46
|
<template #imageValue>
|
|
47
|
-
<UploadImg
|
|
47
|
+
<UploadImg
|
|
48
|
+
v-model:image-url="formData.value"
|
|
49
|
+
upload-type="config"
|
|
50
|
+
:access-mode="configImageAccessMode"
|
|
51
|
+
/>
|
|
48
52
|
</template>
|
|
49
53
|
<template #richTextValue>
|
|
50
54
|
<WangEditor v-model:value="formData.value" upload-type="config" />
|
|
@@ -135,6 +139,7 @@ import type {
|
|
|
135
139
|
} from "@liujitcn/kratos-admin-system/rpc/system/admin/v1/base_config";
|
|
136
140
|
import type { BaseI18n } from "@liujitcn/kratos-admin-system/rpc/system/admin/v1/base_i18n";
|
|
137
141
|
import { BaseConfigSite } from "@liujitcn/kratos-admin-system/rpc/base/v1/config";
|
|
142
|
+
import { BaseFileAccessMode } from "@liujitcn/kratos-admin-core/rpc/base/v1/file";
|
|
138
143
|
import { Status } from "@liujitcn/kratos-admin-system/rpc/common/v1/enum";
|
|
139
144
|
import { BaseConfigType } from "@liujitcn/kratos-admin-system/rpc/system/admin/v1/base_config";
|
|
140
145
|
import { I18nTargetType } from "@liujitcn/kratos-admin-system/rpc/system/admin/v1/base_i18n";
|
|
@@ -364,6 +369,14 @@ const BASE_CONFIG_DICT_CODE_MAP: Record<string, string> = {
|
|
|
364
369
|
/** 当前字典类配置对应的字典编码,未配置映射时允许退回手动输入。 */
|
|
365
370
|
const dictValueCode = computed(() => BASE_CONFIG_DICT_CODE_MAP[formData.key] ?? "");
|
|
366
371
|
|
|
372
|
+
/** 需要匿名访问的系统图片配置键,其他图片配置继续按默认授权模式上传。 */
|
|
373
|
+
const PUBLIC_IMAGE_CONFIG_KEYS = new Set(["adminLogo", "appLogo", "background"]);
|
|
374
|
+
const configImageAccessMode = computed(() =>
|
|
375
|
+
PUBLIC_IMAGE_CONFIG_KEYS.has(formData.key)
|
|
376
|
+
? BaseFileAccessMode.BASE_FILE_ACCESS_MODE_PUBLIC
|
|
377
|
+
: BaseFileAccessMode.BASE_FILE_ACCESS_MODE_AUTHORIZED
|
|
378
|
+
);
|
|
379
|
+
|
|
367
380
|
/** 系统配置表单字段配置。 */
|
|
368
381
|
const formFields = computed<ProFormField[]>(() => [
|
|
369
382
|
{
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@liujitcn/kratos-admin-system",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.55",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "kratos-admin system management module",
|
|
7
7
|
"license": "MIT",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"sortablejs": "^1.15.2",
|
|
17
17
|
"swagger-ui-dist": "^5.32.15",
|
|
18
18
|
"vue-element-plus-x": "^2.0.3",
|
|
19
|
-
"@liujitcn/kratos-admin-core": "0.0.
|
|
19
|
+
"@liujitcn/kratos-admin-core": "0.0.55"
|
|
20
20
|
},
|
|
21
21
|
"peerDependencies": {
|
|
22
22
|
"@element-plus/icons-vue": "^2.3.1",
|