diff --git a/pages/tabbar/my/my.vue b/pages/tabbar/my/my.vue index 9bc5a31..feb798c 100644 --- a/pages/tabbar/my/my.vue +++ b/pages/tabbar/my/my.vue @@ -213,9 +213,10 @@ }) }, // 手机加星号 - tel(tel) { + tel(tel="0000000000") { + const telNum = tel.toString(); const reg = /^(\d{3})\d{4}(\d{4})$/; - return tel.replace(reg, '$1****$2') + return telNum.replace(reg, '$1****$2') }, //用户中心信息 checkInfo() {