上一页 1 ··· 6 7 8 9 10 11 12 13 下一页
摘要: 这个是密码的拦截 : [{ required: true, validator: validatePass4, trigger: "blur" }], 同级关系下写下方法,类似定义一个方法,用变量接收 // value 值 是 你 密码拦截的值, callback 是返回的信息,rule 是规则 v 阅读全文
posted @ 2021-05-25 17:03 薛定谔_猫 阅读(858) 评论(0) 推荐(0)
摘要: var fileName = this.from.doc.substring(this.from.doc.lastIndexOf('/')+1); //文件名 var extName = fileName.substring(fileName.lastIndexOf('.')+1); //后缀名 阅读全文
posted @ 2021-05-25 10:32 薛定谔_猫 阅读(1184) 评论(0) 推荐(0)
摘要: JS // 获取并且格式化时间 formatter (thistime, fmt) { let $this = new Date(thistime) let o = { 'M+': $this.getMonth() + 1, 'd+': $this.getDate(), 'h+': $this.ge 阅读全文
posted @ 2021-05-24 13:55 薛定谔_猫 阅读(3995) 评论(0) 推荐(1)
摘要: template部分: 头像外部加一个 div <div class="user-info-head"> </div> css 部分 <style scoped lang="scss"> .user-info-head { position: relative; display: inline-bl 阅读全文
posted @ 2021-05-24 11:13 薛定谔_猫 阅读(581) 评论(0) 推荐(0)
摘要: 正则表达式: @input="form.userName = form.userName.replace(/\s+/g,'')" ( 禁止输入空格) @input="form.phone = form.phone.replace(/[^\d]/g, '')" ( 只能输入数字 ) @input="f 阅读全文
posted @ 2021-05-23 14:06 薛定谔_猫 阅读(1377) 评论(0) 推荐(0)
摘要: //限制身份证号码的输入 if( !(/(^\d{15}$)|(^\d{17}([0-9]|X)$)/.test(this.verification.cardNo)) ){ this.$u.toast('输入的身份证号长度不对,或者号码不符合规定!15位号码应全为数字,18位号码末位可以为数字或X。 阅读全文
posted @ 2021-05-21 16:48 薛定谔_猫 阅读(1939) 评论(0) 推荐(0)
摘要: 由于花费了我不少时间才找到的组件,所以记录一下,后面方便自己好找一些,也算是分享出来给各位前端一起用。 npm 下载npm install vue2-flip-countdown --save template 部分 <div style="margin-top:20px;"> <flip-coun 阅读全文
posted @ 2021-05-17 10:28 薛定谔_猫 阅读(950) 评论(0) 推荐(0)
摘要: npm install vuedraggable import draggable from "vuedraggable"; // v-model="preface" <draggable chosenClass="chosen" ghost-class="ghost" animation="500 阅读全文
posted @ 2021-04-19 17:26 薛定谔_猫 阅读(88) 评论(0) 推荐(0)
摘要: npm i echarts -S 下载 echarts 图表 mian.js 文件 引入图表并且全局挂载 //echarts 图表 import echarts from 'echarts' Vue.prototype.$echarts = echarts 在用到的vue文件里 <div class 阅读全文
posted @ 2021-04-02 11:02 薛定谔_猫 阅读(649) 评论(0) 推荐(0)
摘要: 有俩种方法可以用 第一种方法: 解析:直接解析并且下载后端的乱码 this.download('后端给的导出excel的方法', { ...this.queryParams }, `job_${new Date().getTime()}.xlsx`) 第二种方法: 封装一个api,里面写你的方法,在 阅读全文
posted @ 2021-01-28 11:18 薛定谔_猫 阅读(1377) 评论(0) 推荐(0)
上一页 1 ··· 6 7 8 9 10 11 12 13 下一页