feat(CRUD):增加颜色选择器

This commit is contained in:
妙码生花 2022-11-24 10:35:26 +08:00
parent aa589ff052
commit 21f0c07dca
3 changed files with 29 additions and 0 deletions

View File

@ -51,5 +51,7 @@ export default {
'remote select': 'Remote Select',
'city select': 'City select',
'icon select': 'Icon select',
'color picker': 'color picker',
color: 'color',
choice: ' Choice',
}

View File

@ -51,5 +51,7 @@ export default {
'remote select': '远程下拉',
'city select': '城市选择',
'icon select': '图标选择',
'color picker': '颜色选择器',
color: '颜色',
choice: '选择',
}

View File

@ -505,6 +505,22 @@ export const fieldItem: {
table: {},
form: {},
},
{
title: i18n.global.t('utils.color picker'),
name: 'color',
type: 'varchar',
length: 30,
precision: 0,
default: 'empty string',
null: false,
primaryKey: false,
unsigned: false,
autoIncrement: false,
comment: i18n.global.t('utils.color picker'),
designType: 'color',
table: {},
form: {},
},
],
}
@ -522,6 +538,7 @@ const tableBaseAttr = {
tags: 'Tags',
url: 'URL',
datetime: i18n.global.t('utils.time date'),
color: i18n.global.t('utils.color'),
},
},
operator: {
@ -886,6 +903,14 @@ export const designTypes: anyObj = {
},
form: formBaseAttr,
},
color: {
name: i18n.global.t('utils.color picker'),
table: {
render: getTableAttr('render', 'color'),
operator: getTableAttr('operator', 'false'),
},
form: formBaseAttr,
},
}
export const tableFieldsKey = ['quickSearchField', 'formFields', 'columnFields']