Browse Source

fix: 镜像名称不支持大写字母

pull/160/head
cp3hnu 1 year ago
parent
commit
293a8d09f5
2 changed files with 4 additions and 4 deletions
  1. +2
    -2
      react-ui/src/pages/DevelopmentEnvironment/components/CreateMirrorModal/index.tsx
  2. +2
    -2
      react-ui/src/pages/Mirror/Create/index.tsx

+ 2
- 2
react-ui/src/pages/DevelopmentEnvironment/components/CreateMirrorModal/index.tsx View File

@@ -51,8 +51,8 @@ function CreateMirrorModal({ envId, onOk, ...rest }: CreateMirrorModalProps) {
message: '请输入镜像名称', message: '请输入镜像名称',
}, },
{ {
pattern: /^[a-zA-Z0-9/_-]*$/,
message: '只支持字母、数字、下划线(_)、中横线(-)、斜杠(/)',
pattern: /^[a-z0-9/_-]*$/,
message: '只支持小写字母、数字、下划线(_)、中横线(-)、斜杠(/)',
}, },
]} ]}
> >


+ 2
- 2
react-ui/src/pages/Mirror/Create/index.tsx View File

@@ -150,8 +150,8 @@ function MirrorCreate() {
message: '请输入镜像名称', message: '请输入镜像名称',
}, },
{ {
pattern: /^[a-zA-Z0-9/_-]*$/,
message: '只支持字母、数字、下划线(_)、中横线(-)、斜杠(/)',
pattern: /^[a-z0-9/_-]*$/,
message: '只支持小写字母、数字、下划线(_)、中横线(-)、斜杠(/)',
}, },
]} ]}
> >


Loading…
Cancel
Save