随笔分类 - 前端工具库
摘要:html <Form :label-width="100" :rules="ruleValidate" :model="editInfo" ref="addNewForm"> <Row> <Col span="24"> <Form-item prop="name" label="挂件名称"> <In
阅读全文
摘要:function formatDecimal(num, decimal) { num = num.toString() let index = num.indexOf('.') if (index !== -1) { num = num.substring(0, decimal + index +
阅读全文
摘要:/** * 将数值格式化成金额形式 * * @param num 数值(Number或者String) * @param precision 精度,默认不变 * @param separator 分隔符,默认为逗号 * @return 金额格式的字符串,如'1,234,567',默认返回NaN *
阅读全文
摘要:timeToDate(time, format){ var t = new Date(time); var tf = function(i){return (i < 10 ? '0' : '') + i}; return format.replace(/yyyy|MM|dd|HH|mm|ss/g,
阅读全文
摘要:.loading{ display: inline-block; height: .24rem; width: .24rem; border-radius: 100%; border: 2px solid #666; border-bottom-color: transparent; positio
阅读全文
摘要:完整demo <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>de
阅读全文
摘要:<html> <head> <p style="font-size: 20px;color: red;">使用a标签方式将json导出csv文件</p> <button onclick='tableToExcel()'>导出</button> </head> <body> <script> function tableToExcel(){ //要导出的json数据 const jsonData =
阅读全文
摘要:1、formdata对象append增加值,打印对象无效? 实际取值方式:( formData.get, getAll, keys) 引用:https://developer.mozilla.org/zh-CN/docs/Web/API/FormData/Using_FormData_Objects
阅读全文
摘要:function getDate() { var myDate = new Date(); var month = myDate.getMonth() + 1; var day = myDate.getDate(); month = (month.toString(...
阅读全文
摘要:effect : 'coverflow',// cube // 切换效果
阅读全文