修改验证方式

This commit is contained in:
RenCheng 2025-04-26 13:49:37 +08:00
parent 62fa53b067
commit b7e23f1210

View File

@ -26,9 +26,14 @@
:wrapperCol="wrapperCol" label="端口号" >
<a-input v-decorator="['port',{
rules: [
{ required: true, message: '端口号不能为空' },
{ min: 1, max: 5, message: '长度1-5位' },
{ type: 'number', message: '端口号必须为数字'}
{
required: true,
message: '端口号不能为空'
},
{
pattern: /^\d{1,5}$/,
message: '请输入1-5位的数字'
}
],
validateTrigger: 'change'
}]" :disabled="testConnBool"></a-input>
@ -208,7 +213,7 @@ import { datasyncqueryPage,
this.getselect();
let model = {};
model.ip = "";
model.port = "";
model.port = 0;
model.username = '';
model.password = '';
model.database = '';