随笔分类 -  js

摘要:/** * [dateAddDays 从某个日期增加n天后的日期] * @param {[string]} dateStr [日期字符串] * @param {[int]} dayCount [增加的天数] * @return {[string]}[增加n天后的日期字符串] */ function 阅读全文
posted @ 2021-02-05 08:46 Janni 阅读(84) 评论(0) 推荐(0) 编辑
摘要:1.this的指向(this 永远指向最后调用它的那个对象) var name = "windowsName"; function a() { var name = "Cherry"; console.log(this.name); // windowsName console.log("inner 阅读全文
posted @ 2021-01-27 13:55 Janni 阅读(85) 评论(0) 推荐(0) 编辑
摘要:1.创建flexible.js文件 import store from '@/store' //设置基础字号 const baseSize = 16 //设置基本缩放比 let scaleRate = 1; // 设置 rem 函数 function setRem() { // 当前页面宽度相对于 阅读全文
posted @ 2020-12-17 14:21 Janni 阅读(616) 评论(0) 推荐(0) 编辑
摘要:uniapp中使用colorUI 1.开始 下载源码解压获得/Colorui-UniApp文件夹,复制目录下的 /colorui 文件夹到你的项目根目录 App.vue 引入关键Css main.css icon.css <style> /* 引入colorui主体 */ @import "colo 阅读全文
posted @ 2020-08-18 16:07 Janni 阅读(9505) 评论(0) 推荐(1) 编辑
摘要:checkSettingsForm.qaModel.search('抽查') 1 阅读全文
posted @ 2020-06-03 15:03 Janni 阅读(1054) 评论(0) 推荐(0) 编辑
摘要:时间戳转日期 //parseInt()字符串转数字 //new Date()放入时间戳,没有放默认当前时间 this.tableData[i].createTime = this.formatDate(new Date(parseInt(this.tableData[i].createTime))) 阅读全文
posted @ 2020-05-30 14:51 Janni 阅读(2437) 评论(0) 推荐(0) 编辑
摘要:// 排序 this.tableData.sort(function (a, b) { console.log(a[x]) var x = 'inAccessCode'//要排序字段 if (a[x] < b[x]) { return -1 } if (a[x] > b[x]) { return 1 阅读全文
posted @ 2020-05-30 14:44 Janni 阅读(5061) 评论(0) 推荐(0) 编辑

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