fix(const):修改变量引用路径

master
钟良源 3 months ago
parent 5b48a57de2
commit 855bb5b6e2

@ -1,19 +1,18 @@
import { globalOption, patternTrim } from '../globalOption'; import { globalOption, patternTrim } from '../globalOption';
import { componentBaseTagsUrl } from '@/api/isdp/componentBase';
export const releaseMaping = { export const releaseMaping = {
0: { 0: {
label: '未公开', label: '未公开',
type: 'info', type: 'info'
}, },
'-1': { '-1': {
label: '未公开', label: '未公开',
type: 'info', type: 'info'
}, },
1: { 1: {
label: '已公开', label: '已公开',
type: 'success', type: 'success'
}, }
}; };
export const option = { export const option = {
@ -42,11 +41,11 @@ export const option = {
{ {
required: true, required: true,
message: '组件名称不能为空', message: '组件名称不能为空',
trigger: 'blur', trigger: 'blur'
}, },
patternTrim, patternTrim,
{ max: 20, message: '组件名称最长为20字符' }, { max: 20, message: '组件名称最长为20字符' }
], ]
}, },
{ {
label: '项目名', label: '项目名',
@ -59,11 +58,11 @@ export const option = {
{ required: true, message: '项目名不能为空' }, { required: true, message: '项目名不能为空' },
{ {
pattern: /^([a-z][a-z0-9]*[_-]?)+$/, pattern: /^([a-z][a-z0-9]*[_-]?)+$/,
message: '项目名由小写字母、数字、"-"、"_"组成,以小写字母开头,且“-”、"_"后第一个字符需为小写字母', message: '项目名由小写字母、数字、"-"、"_"组成,以小写字母开头,且“-”、"_"后第一个字符需为小写字母'
}, },
{ max: 30, message: '项目名最长为30个字符' }, { max: 30, message: '项目名最长为30个字符' },
patternTrim, patternTrim
], ]
}, },
{ {
label: '版本号', label: '版本号',
@ -78,15 +77,15 @@ export const option = {
{ {
required: true, required: true,
message: '请输入组件版本号', message: '请输入组件版本号',
trigger: 'blur', trigger: 'blur'
}, },
// { // {
// pattern: /^\d+(\.\d+){0,3}$/, // pattern: /^\d+(\.\d+){0,3}$/,
// message: "版本只能是由数字组成的x.x或x.x.x格式", // message: "版本只能是由数字组成的x.x或x.x.x格式",
// trigger: "blur" // trigger: "blur"
// }, // },
{ max: 20, message: '版本号最长为20字符' }, { max: 20, message: '版本号最长为20字符' }
], ]
}, },
{ {
label: '分类', label: '分类',
@ -97,10 +96,10 @@ export const option = {
dicUrl: '/api/blade-system/dict-biz/dictionary-tree?code=component_classify', dicUrl: '/api/blade-system/dict-biz/dictionary-tree?code=component_classify',
props: { props: {
label: 'dictValue', label: 'dictValue',
value: 'dictKey', value: 'dictKey'
}, },
span: 9, span: 9,
rules: [{ required: true, message: '分类不能为空' }], rules: [{ required: true, message: '分类不能为空' }]
// search: true, // search: true,
}, },
{ {
@ -115,9 +114,9 @@ export const option = {
placeholder: '请选择代码语言', placeholder: '请选择代码语言',
props: { props: {
label: 'dictValue', label: 'dictValue',
value: 'dictKey', value: 'dictKey'
}, },
rules: [{ required: true, message: '代码语言不能为空' }], rules: [{ required: true, message: '代码语言不能为空' }]
}, },
{ {
label: '标签', label: '标签',
@ -129,8 +128,8 @@ export const option = {
filterable: true, filterable: true,
placeholder: '请选择标签', placeholder: '请选择标签',
span: 24, span: 24,
dicUrl: componentBaseTagsUrl, dicUrl: '/api/blade-isdp/componentBase/tags',
hide: true, hide: true
}, },
{ {
label: '描述', label: '描述',
@ -141,7 +140,7 @@ export const option = {
minRows: 2, minRows: 2,
maxLen: 100, maxLen: 100,
rules: [{ max: 200, message: '最长为200个字符' }], rules: [{ max: 200, message: '最长为200个字符' }],
span: 24, span: 24
}, },
{ {
label: '图标', label: '图标',
@ -152,13 +151,13 @@ export const option = {
action: '/api/blade-isdp/fileSystem/fileUpload', action: '/api/blade-isdp/fileSystem/fileUpload',
propsHttp: { propsHttp: {
res: 'data', res: 'data',
url: 'link', url: 'link'
}, },
fileType: 'img', fileType: 'img',
limit: 1, limit: 1,
fileSize: 1024, fileSize: 1024,
accept: 'image/png, image/jpeg, image/jpg', accept: 'image/png, image/jpeg, image/jpg',
tip: '图片尺寸不超过300*300像素大小限制为1mb以内', tip: '图片尺寸不超过300*300像素大小限制为1mb以内'
}, },
{ {
label: '公开状态', label: '公开状态',
@ -166,14 +165,14 @@ export const option = {
type: 'input', type: 'input',
slot: true, slot: true,
display: false, display: false,
width: 90, width: 90
}, },
{ {
label: '修改时间', label: '修改时间',
prop: 'updateTime', prop: 'updateTime',
type: 'input', type: 'input',
width: 130, width: 130,
display: false, display: false
}, }
], ]
}; };

Loading…
Cancel
Save