随笔分类 - vue
摘要:父组件 <template> <el-dialog :title="title" :visible.sync="open" width="1000px" append-to-body> <statement-preview :data-list="dataList" ref="statementPr
阅读全文
摘要:1.确定keep-alive标签是否存在 2.判断菜单上面路由地址是否与页面上name保持一致并且首字母大写
阅读全文
摘要:server: { port: 80, host: true, open: true, proxy: { [env.VITE_APP_BASE_API]: { target: env.VITE_APP_API, changeOrigin: true, rewrite: (p) => p.replac
阅读全文
摘要:1.导入xlsx、xlsx-style、file-saver npm install --save xlsx npm install --save xlsx-style npm install --save file-saver 2.防止xlsx-style报错 vue.config.js添加 ch
阅读全文
摘要:加减乘除运算 /** * @description: 加法运算 * @param {*} arg1 * @param {*} arg2 * @param {*} number 展示小数点后位数 * @return {*} */ export function operationAdd(arg1, a
阅读全文
摘要:在按钮点击后强制按钮失去焦点 1.在按钮点击的方法后加上失去焦点的方法 <el-button @click="showDetail(scope.row, $event)">详情</el-button> showDetail (rowData, event) { if (event.target.no
阅读全文
摘要:需求:系统顶部添加项目下拉框,顶部下拉框选项改变时其他模块下拉框同时改变。 1.开始进入系统的时候获取项目列表 页面调用接口 // 获取项目列表 store.dispatch("getProject").then(() => {}); store新建project.js 1 import { lis
阅读全文
摘要:<keep-alive>有下面三个属性 include 字符串,数组或正则表达式。只有名称匹配的组件会被缓存。 exclude 字符串,数组或正则表达式。任何名称匹配的组件都不会缓存。 max 数字。最多可以缓存多少组件实例。 使用数组时可动态加载。 重点!!! 这里存的数组是name值 而name
阅读全文
摘要:1.页面 <div ref="docsRef" id="fileView" class="view" :style="{ height: viewHeight + 'px' }"></div> <div v-if="fileType == 'pdf'" v-loading="loading" cla
阅读全文
摘要:1.npm 引入 npm install vue-quill-editor --save npm install quill --save 2.main引入 import VueQuillEditor from 'vue-quill-editor' import 'quill/dist/quill.
阅读全文
摘要:该情况是在form下嵌套多个for循环类型的form html页面 <el-form :model="dataForm" :rules="dataRule" ref="dataForm" style="height: 60vh;overflow: auto" label-width="150px"
阅读全文
摘要:
已知裂缝中心点位 /裂缝长度/角度 生成裂缝位置形状坐标图 效果图 页面代码 <el-row v-show="showChart"> <el-col :push="2" :span="20"> <div id="axis"></div> </el-col> </el-row> <el-button
阅读全文
已知裂缝中心点位 /裂缝长度/角度 生成裂缝位置形状坐标图 效果图 页面代码 <el-row v-show="showChart"> <el-col :push="2" :span="20"> <div id="axis"></div> </el-col> </el-row> <el-button
阅读全文
摘要:
1.页面 table上加 @select="pinSelect" ref="multipleTable" 2.定义字段 origin: -1, // 起点数 pin: false, // 默认shift不按住 3.页面加载时监听按键 mounted () { window.addEventListe
阅读全文
1.页面 table上加 @select="pinSelect" ref="multipleTable" 2.定义字段 origin: -1, // 起点数 pin: false, // 默认shift不按住 3.页面加载时监听按键 mounted () { window.addEventListe
阅读全文
摘要:
方法可分为两种 第一种 使用iviewUI 的split 面板分割组件 第二种就是自己写一个监听鼠标点击移动位置 一. 使用iview 的split 面板分割组件 这里是说明链接 https://www.cnblogs.com/wjian0916/p/16227825.html 二. 监听鼠标 1.
阅读全文
方法可分为两种 第一种 使用iviewUI 的split 面板分割组件 第二种就是自己写一个监听鼠标点击移动位置 一. 使用iview 的split 面板分割组件 这里是说明链接 https://www.cnblogs.com/wjian0916/p/16227825.html 二. 监听鼠标 1.
阅读全文
摘要:1.上图 2.引入 tui-image-editor npm i tui-image-editor 3.直接上代码 1 <template> 2 <el-dialog append-to-body :visible.sync="imgVisible" :title="imgName" width="
阅读全文
摘要:1、命令行临时使用指定镜像 npm --registry https://registry.npmmirror.com install express 2、永久使用指定镜像 npm config set registry https://registry.npmmirror.com 3、使用cnpm
阅读全文
摘要:
只能填数字 oninput="value=value.replace(/[^\d]/g, '')" 只能填数字和小数点 oninput="value=value.replace(/^\.+|[^\d.]/g,'')" 只能填数字和小数点 后两位 oninput="value=value.replac
阅读全文
只能填数字 oninput="value=value.replace(/[^\d]/g, '')" 只能填数字和小数点 oninput="value=value.replace(/^\.+|[^\d.]/g,'')" 只能填数字和小数点 后两位 oninput="value=value.replac
阅读全文
摘要:1. 接口api export function downTemplate(data) { return request({ url: 'bridge/bridegaccidentinfo/download', method: 'get', responseType: "blob", //设置接收数
阅读全文
摘要:function urlToBase64(url) { const img = new Image() img.onload = function () { const canvas = document.createElement('canvas') const ctx = canvas.getC
阅读全文

浙公网安备 33010602011771号