fix(设备台账):电话号码格式化1.2
This commit is contained in:
parent
457c6d6ab0
commit
f5af0ea37b
@ -167,7 +167,7 @@
|
||||
<el-input v-else v-model="formObj.vendorNo" maxlength="50"></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-col :span="8">
|
||||
<el-form-item label="联系方式:" prop="weight">
|
||||
<div v-if="onlyView">
|
||||
{{ formObj.weight }}
|
||||
@ -176,7 +176,7 @@
|
||||
<el-input v-else v-model="formObj.weight" maxlength="50" @input = "handleInput"></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-col :span="10">
|
||||
<el-form-item label="设备使用部门:" prop="useDept">
|
||||
<div v-if="onlyView">
|
||||
{{ formObj.useDept }}
|
||||
@ -1088,12 +1088,6 @@ export default {
|
||||
if (this.formObj.weight.length > 11) {
|
||||
this.formObj.weight = this.formObj.weight.slice(0, 11);
|
||||
}
|
||||
const phoneRegex = /^1[3-9]\d{9}$/;
|
||||
if (!phoneRegex.test(value)) {
|
||||
// 如果不符合手机号码格式,可以在这里进行提示或重置输入框的值等操作
|
||||
this.$message.error('输入的不是有效的电话号码');
|
||||
this.formObj.weight = '';
|
||||
}
|
||||
},
|
||||
showEqpGroupDialog(key) {
|
||||
this.eqpGroupDialogVisible = true;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user