From 2e882cbeda6a8a0f4dd193896386192f0f5ba0a7 Mon Sep 17 00:00:00 2001
From: 马宇豪 <978517621@qq.com>
Date: Thu, 06 Jul 2023 15:52:24 +0800
Subject: [PATCH] 修改
---
src/views/Admin/components/userMod.vue | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/src/views/Admin/components/userMod.vue b/src/views/Admin/components/userMod.vue
index 499ef98..da6f1d4 100644
--- a/src/views/Admin/components/userMod.vue
+++ b/src/views/Admin/components/userMod.vue
@@ -81,7 +81,7 @@
<script>
import {addUser, updateUser} from '@/api/user'
-import {verifyPasswordPowerful, verifyPhone} from "@/util/validate";
+import {verifyPasswordPowerful, verifyPhone, verifySimplePhone} from "@/util/validate";
export default {
name: 'userMod',
props: ['unitType'],
@@ -101,7 +101,7 @@
if(value === ''){
callback(new Error('请输入手机号'))
}else{
- if(!verifyPhone(value)){
+ if(!verifySimplePhone(value)){
callback(new Error('手机号格式有误'))
}else{
callback()
@@ -257,7 +257,7 @@
// }
// t.form.province = t.findNodeByCode(t.areaData,code.substr(0,2)).name
// t.form.town = ''
- t.form.company = label[0] + '自然灾害综合预警监测中心'
+ t.form.company = label[0] + '自然灾害综合监测预警中心'
}
},
@@ -279,6 +279,7 @@
if(res.data.code == 100){
this.$message.success('新增用户成功')
this.$emit('refresh')
+ this.visible = false
}else{
this.$message.error(res.data.msg)
}
@@ -289,12 +290,12 @@
if(res.data.code == 100){
this.$message.success('修改用户成功')
this.$emit('refresh')
+ this.visible = false
}else{
this.$message.error(res.data.msg)
}
})
}
- this.visible = false
} else {
console.log('error submit!!');
return false;
--
Gitblit v1.9.2