fix:优化角色管理用户管理和接口白名单的页面显示

This commit is contained in:
victory
2023-03-22 22:39:08 +08:00
committed by H0nGzA1
parent a304a49107
commit 4d17a7d9df
3 changed files with 40 additions and 58 deletions

View File

@@ -78,18 +78,6 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
},
},
},
search: {
title: '关键词',
column: {show: false},
type: 'text',
search: {show: true},
form: {
show: false,
component: {
placeholder: '输入关键词搜索',
},
},
},
id: {
title: 'ID',
type: 'text',
@@ -103,7 +91,7 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
search: {show: true},
column: {
minWidth: 120,
sortable: true,
sortable: "custom",
},
form: {
rules: [{required: true, message: '角色名称必填'}],
@@ -118,7 +106,7 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
search: {show: false},
column: {
width: 120,
sortable: true,
sortable: "custom",
},
form: {
rules: [{required: true, message: '权限标识必填'}],
@@ -131,9 +119,10 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
type: 'number',
column: {
width: 90,
sortable: true,
sortable: "custom",
},
form: {
rules: [{required: true, message: '排序必填'}],
value: 1,
},
},
@@ -157,9 +146,10 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
}),
column: {
width: 130,
sortable: true,
sortable: "custom",
},
form: {
rules: [{required: true, message: '是否管理员必填'}],
value: false,
},
},
@@ -183,9 +173,10 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
}),
column: {
width: 90,
sortable: true,
sortable: "custom",
},
form: {
rules: [{required: true, message: '状态必填'}],
value: true,
},
},
@@ -195,7 +186,7 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
search: {show: false},
column: {
width: 170,
sortable: true,
sortable: "custom",
},
form: {
show: false,
@@ -209,7 +200,7 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
type: 'text',
search: {show: false},
column: {
sortable: true,
sortable: "custom",
width: 170,
},
form: {
@@ -219,18 +210,17 @@ export const createCrudOptions = function ({crudExpose,rolePermission}: {crudExp
},
},
},
description: {
title: '备注',
type: 'textarea',
search: {show: false},
form: {
component: {
maxlength: 200,
placeholder: '输入备注',
},
},
},
// description: {
// title: '备注',
// type: 'textarea',
// search: {show: false},
// form: {
// component: {
// maxlength: 200,
// placeholder: '输入备注',
// },
// },
// },
},
},
};

View File

@@ -54,29 +54,6 @@ export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExp
columnSetDisabled: true, //禁止在列设置中选择
},
},
search: {
title: '关键词',
column: {
show: false
},
search: {
show: true,
component: {
props: {
clearable: true
},
placeholder: '请输入关键词'
}
},
form: {
show: false,
component: {
props: {
clearable: true
}
}
},
},
username: {
title: '账号',
search: {

View File

@@ -28,6 +28,14 @@ export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExp
editRequest,
delRequest,
},
form: {
col: {span: 24},
labelWidth: '110px',
wrapper: {
is: 'el-dialog',
width: '600px',
},
},
columns: {
_index: {
title: '序号',
@@ -70,7 +78,7 @@ export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExp
},
method: {
title: '请求方式',
sortable: true,
sortable: "custom",
search: {
disabled: false,
},
@@ -93,6 +101,10 @@ export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExp
label: 'DELETE',
value: 3,
},
{
label: 'PATCH',
value: 4,
}
],
}),
form: {
@@ -113,7 +125,7 @@ export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExp
},
url: {
title: '接口地址',
sortable: true,
sortable: "custom",
search: {
disabled: true,
},
@@ -155,9 +167,11 @@ export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExp
class: { yxtInput: true },
},
helper: {
render(h) {
return <el-alert title="请正确填写,以免请求时被拦截。匹配单例使用正则,例如:/api/xx/.*?/" type="warning" />;
position: "label",
tooltip: {
placement: "top-start"
},
text: "请正确填写,以免请求时被拦截。匹配单例使用正则,例如:/api/xx/.*?/"
},
},
},
@@ -173,6 +187,7 @@ export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExp
}),
form: {
value: true,
rules: [{ required: true, message: '必填项' }],
component: {
span: 12,
},