Explorar el Código

前端邮箱掩码错误处理

kouchengxing hace 3 años
padre
commit
2eb72d63ab
Se han modificado 2 ficheros con 3 adiciones y 2 borrados
  1. 2 1
      dgtis-ui/src/main.js
  2. 1 1
      dgtis-ui/src/utils/ruoyi.js

+ 2 - 1
dgtis-ui/src/main.js

@@ -20,7 +20,7 @@ import './assets/icons' // icon
 import './permission' // permission control
 import { getDicts } from "@/api/system/dict/data";
 import { getConfigKey } from "@/api/system/config";
-import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, handleTree,levelText,telNo,cardNo,getArea } from "@/utils/ruoyi";
+import { parseTime, resetForm,emailYm, addDateRange, selectDictLabel, selectDictLabels, handleTree,levelText,telNo,cardNo,getArea } from "@/utils/ruoyi";
 import Pagination from "@/components/Pagination";
 //自定义表格工具扩展
 import RightToolbar from "@/components/RightToolbar"
@@ -39,6 +39,7 @@ Vue.prototype.handleTree = handleTree
 Vue.prototype.levelText = levelText
 Vue.prototype.cardNo = cardNo
 Vue.prototype.telNo = telNo
+Vue.prototype.emailYm = emailYm
 Vue.prototype.getArea = getArea
 
 Vue.prototype.msgSuccess = function (msg) {

+ 1 - 1
dgtis-ui/src/utils/ruoyi.js

@@ -228,7 +228,7 @@ export function getArea(val){
 // 邮箱掩码
 export function emailYm(email){
   if(email){
-    let mystr ="****" +email.substr(email.indexOf("@"), email.length);
+    let mystr ="****" +email.substring(email.indexOf("@"), email.length);
     return mystr;
   }else{
     return '';