1
0

feat(web): 增加权属管理界面

This commit is contained in:
2024-11-26 14:02:15 +08:00
parent e76236be62
commit 851fc02ce5
7 changed files with 144 additions and 48 deletions

View File

@@ -2,17 +2,13 @@ import './dialog-resource.css'
import {
apiGet,
apiPost,
formInputClearable,
horizontalFormOptions,
inputFileFormItemCommonOptions,
size1GB,
size500MB
} from "../constants.js";
const clearable = {
clearable: true,
clearValueOnEmpty: true,
}
function inputFileFormItemUpdateFieldOptions(target) {
let value = {}
value[target] = '${event.data.value}'
@@ -51,13 +47,13 @@ function detailForm() {
name: 'name',
label: '资源名称',
required: true,
...clearable,
...formInputClearable,
},
{
type: 'textarea',
name: 'description',
label: '资源描述',
...clearable,
...formInputClearable,
showCounter: true,
trimContents: true,
minRows: 2,
@@ -90,19 +86,19 @@ function detailForm() {
label: 'API地址',
name: 'apiUrl',
required: true,
...clearable,
...formInputClearable,
},
{
type: 'input-text',
label: '用户名',
name: 'apiUsername',
...clearable,
...formInputClearable,
},
{
type: 'input-password',
label: '密码',
name: 'apiPassword',
...clearable,
...formInputClearable,
},
]
},
@@ -149,19 +145,19 @@ function detailForm() {
label: 'JDBC',
name: 'databaseJdbc',
required: true,
...clearable,
...formInputClearable,
},
{
type: 'input-text',
label: '用户名',
name: 'databaseUsername',
...clearable,
...formInputClearable,
},
{
type: 'input-password',
label: '密码',
name: 'databasePassword',
...clearable,
...formInputClearable,
},
]
},
@@ -210,33 +206,33 @@ function detailForm() {
label: 'FTP地址',
name: 'ftpUrl',
required: true,
...clearable,
...formInputClearable,
},
{
type: 'input-text',
label: 'FTP账号',
name: 'ftpUsername',
...clearable,
...formInputClearable,
},
{
type: 'input-password',
label: 'FTP密码',
name: 'ftpPassword',
...clearable,
...formInputClearable,
},
{
type: 'input-text',
label: '相对路径',
name: 'ftpPath',
description: '若为空,则使用用户根目录',
...clearable,
...formInputClearable,
},
{
type: 'input-text',
label: '文件筛选',
name: 'ftpRegexFilter',
description: '正则表达式,用于匹配文件的路径,只有符合筛选条件的文件才会被采集;若为空则默认采集全部文件',
...clearable,
...formInputClearable,
},
]
},