上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 63 下一页
摘要: 根据windows日历,获取当前周,以及当前周的前2周和后4周,共7周的日期范围 export function getFormatDate(serverDate) { let list = [] // 二维数组 let formatDate = function (date, days) { le 阅读全文
posted @ 2021-08-27 14:27 吴小明- 阅读(589) 评论(0) 推荐(0) 编辑
摘要: 1、作为事件对象【原生事件】 <button @click="handleClick">按钮</button> <el-button @click="handleClick($event)">按钮</el-button> methods: { handleClick(e) { console.log 阅读全文
posted @ 2021-08-26 18:03 吴小明- 阅读(926) 评论(0) 推荐(0) 编辑
摘要: 1、utils/utils.js const namespace = 'mall' export function setItem(key, value) { let storage = window.localStorage.getItem(namespace) storage = storage 阅读全文
posted @ 2021-08-26 11:09 吴小明- 阅读(263) 评论(0) 推荐(0) 编辑
摘要: export const quertObject = (url) => { const queryString = url.split('?')[1] const obj = {} const arr = queryString.split('&') for (let i = 0; i < arr. 阅读全文
posted @ 2021-08-25 23:38 吴小明- 阅读(105) 评论(0) 推荐(0) 编辑
摘要: 当使用elementUI的按钮组件时 <el-button @click="handleClick1">按钮一</el-button> <el-button @click="handleClick2">按钮二</el-button> <el-button @click="handleClick3"> 阅读全文
posted @ 2021-08-25 22:02 吴小明- 阅读(919) 评论(0) 推荐(0) 编辑
摘要: 定义Child组件: <template> <transition name="slide"> <div id="child" v-show="isShow"> <h1>子组件</h1> <button @click="isShow=false">按钮</button> </div> </trans 阅读全文
posted @ 2021-08-25 20:37 吴小明- 阅读(83) 评论(0) 推荐(0) 编辑
摘要: 动态面包屑效果: 1、当路由为/home时,面包屑只展示一级 2、当路由为/home/manage时,面包屑显示一级和二级 3、当路由为/home/manage/list或/home/manage/test时,面包屑显示一级、二级、三级 实现: 1、components/BreadCrumb.vue 阅读全文
posted @ 2021-08-25 15:37 吴小明- 阅读(1269) 评论(0) 推荐(0) 编辑
摘要: 相同点: 1、都是用来放静态资源的 2、如果资源在html中使用,都是可以的 <img src="../../../assets/images/002.jpg"> <img src="../../../../static/images/002.jpg"> 3、资源通过import引入,都可以在htm 阅读全文
posted @ 2021-08-24 20:06 吴小明- 阅读(206) 评论(0) 推荐(0) 编辑
摘要: <template> <div class="star"> <span class="star-item on"></span> <span class="star-item off"></span> <span class="star-item half"></span> <hr> <span c 阅读全文
posted @ 2021-08-23 23:28 吴小明- 阅读(1820) 评论(0) 推荐(0) 编辑
摘要: <ul id="list"> <li id="li1">项目一</li> <li>项目二</li> <li>项目三</li> <li>项目四</li> </ul> const list = document.getElementById('list') const li1 = document.ge 阅读全文
posted @ 2021-08-23 20:20 吴小明- 阅读(98) 评论(0) 推荐(0) 编辑
上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 63 下一页