随笔分类 -  vue

知识点
摘要:1、template <el-input prefix-icon="el-icon-search" placeholder="输入关键词搜索" v-model="searchKeyword" style="width: 300px;border: #cccccc" clearable></el-in 阅读全文
posted @ 2022-10-20 11:47 sosolucky 阅读(61) 评论(0) 推荐(0) 编辑
摘要:解决方法// 展开折叠getUpDown (idx) { this.rooms[idx].upDownShow = !this.rooms[idx].upDownShow this.$forceUpdate() // 因为数据层次太多,render函数没有自动更新,需手动强制刷新渲染。}, 阅读全文
posted @ 2022-06-14 10:51 sosolucky 阅读(106) 评论(0) 推荐(0) 编辑
摘要:1、npm install --save js-md5 2、main.js引入 import md5 from 'js-md5' Vue.prototype.$md5 = md5用的组件使用 this.$md5(this.loginForm.password) 阅读全文
posted @ 2021-12-22 10:15 sosolucky 阅读(377) 评论(0) 推荐(0) 编辑
摘要:1、Excel.js export function createXlsFile (jsonData) { let table = '<table>' // 生成表头 let row = '<tr>' for (let i = 0; i < jsonData.th.length; i++) { ro 阅读全文
posted @ 2021-01-06 14:40 sosolucky 阅读(255) 评论(0) 推荐(0) 编辑
摘要:1 node.js安装 https://nodejs.org/en/ 下载好 安装点下一步 2 vue 安装 npm install --global vue-cli // 全局安装 查看安装成功 vue -V // 大V 3 webpack 安装 npm install webpack -g // 阅读全文
posted @ 2020-08-10 15:16 sosolucky 阅读(159) 评论(0) 推荐(0) 编辑
摘要:<template> <el-date-picker v-model="alarmDate" type="daterange" unlink-panels range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" :pic 阅读全文
posted @ 2020-07-24 15:00 sosolucky 阅读(1095) 评论(0) 推荐(0) 编辑
摘要:index.html <title> 网页导航栏添加logo及标题</title> <link rel="icon" type="image/x-icon" href="/static/anfang_favicon.ico"/> <script type="text/javascript"> var 阅读全文
posted @ 2020-07-13 18:43 sosolucky 阅读(1708) 评论(0) 推荐(0) 编辑
摘要:1. 找到/node_modules/sockjs-client/dist/sockjs.js 2.找到代码的 1605行 try { // self.xhr.send(payload); } catch (e) { self.emit('finish', 0, ''); self._cleanup 阅读全文
posted @ 2020-03-16 11:04 sosolucky 阅读(8229) 评论(0) 推荐(1) 编辑
摘要:在 node_modules/element-ui/lib/element-ui.common.js 补上以下代码(function (window) { try { new MouseEvent('test'); return false; // No need to polyfill } cat 阅读全文
posted @ 2020-03-16 09:57 sosolucky 阅读(427) 评论(0) 推荐(0) 编辑
摘要:1、背景图片 在main.js写 Vue.prototype.drawAndShareImage = async (width, height, url, text, callback) => { var canvas = document.createElement('canvas') canva 阅读全文
posted @ 2020-02-26 11:44 sosolucky 阅读(2467) 评论(0) 推荐(0) 编辑
摘要:在main.js写 // eslint-disable-next-line no-extend-nativeArray.prototype.indexOf = function (val) { for (let i = 0; i < this.length; i++) { if (this[i] v 阅读全文
posted @ 2020-02-26 11:36 sosolucky 阅读(2408) 评论(0) 推荐(0) 编辑
摘要:1、时间格式化js validate.js export default { format (fmt) { let o = { 'y+': this.getFullYear(), // 年 'M+': this.getMonth() + 1, // 月份 'd+': this.getDate(), 阅读全文
posted @ 2020-02-26 11:31 sosolucky 阅读(1014) 评论(0) 推荐(0) 编辑
摘要:记录这条问题完全因为太气人了 使用tabs一定要注意:要用<el-row> <el-col :span="数字"></el-col> </el-row> 包裹起来 <el-row> <el-col :span=''24''> <el-tabs v-model="activeName" @tab-cl 阅读全文
posted @ 2020-01-08 17:31 sosolucky 阅读(305) 评论(0) 推荐(0) 编辑
摘要:1、HTML <audio ref='audio' > <source type="audio/mpeg"></audio> 2、script data () { return { src: '', alarmSrc: [ {src: '/static/audio/callalarm.mp3'}, 阅读全文
posted @ 2019-12-03 17:43 sosolucky 阅读(2943) 评论(0) 推荐(0) 编辑
摘要:报错 TypeError: Cannot read property 'resetFields' of undefined resetForm(formName) { if (this.$refs[formName]!==undefined) { this.$refs[formName].reset 阅读全文
posted @ 2019-11-26 18:28 sosolucky 阅读(850) 评论(0) 推荐(0) 编辑
摘要:星期四 2019-11-14 17:27:09 HTML <span>{{nowWeek}}</span> &nbsp; &nbsp;<span>{{nowDate}}</span> &nbsp; &nbsp;<span>{{nowTime}}</span> data data () { retur 阅读全文
posted @ 2019-11-14 17:28 sosolucky 阅读(5995) 评论(0) 推荐(0) 编辑
摘要:一、下载vuex npm install vuex --save 在src下创建store文件夹下放store.js 在main.js引入 二、下载vuex-persistedsate npm i -S vuex-persistedstate 在store.js使用 阅读全文
posted @ 2019-09-17 10:52 sosolucky 阅读(164) 评论(0) 推荐(0) 编辑
摘要:<script src='https://cdn.polyfill.io/v2/polyfill.min.js'></script> 阅读全文
posted @ 2019-09-10 14:51 sosolucky 阅读(83) 评论(0) 推荐(0) 编辑
摘要:第一种方式 一、安装 npm install -S file-saver xlsx npm install -D script-loader 1)在src目录下新建vendor文件夹,里面放入Blob.js和Export2Excel.js及Export2Zip.js三个JS文件 链接:https:/ 阅读全文
posted @ 2019-09-05 10:43 sosolucky 阅读(368) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2019-08-26 11:27 sosolucky 阅读(685) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示