202011-17 antd table按表格里的日期去排序操作 表格内容根据票据日期升序(这里是已经排序后的效果)上代码代码中data的内容如下根据paper_date排序,因为目前这种格式不支持比较,需要先转换成时间戳newDate(aTimeString).getTime()之后再用装换后的时间戳去比较,比较用到的函数是.sort,一下是用来比较的代码data.sort(function(a,b){letaTimeString=a.paper_date;letbTimeString=b.paper_date;letaTime=newDate(aTimeString).getTime();... 继续阅读 >
202010-08 vuejs element table 表格添加行,修改,单独删除行,批量删除行操作 1.表格动态添加,也可删除<template><divclass="TestWord"><el-button@click="addLine">添加行数</el-button><el-button@click="save">保存</el-button><el-table:data="tableData"style="width:100%"><el-table-columnprop="bookname"label="书名"><templateslot-scope="scope"><el-inputv-model="scope.row.bookname"placeholder="书名"></el-input></template></... 继续阅读 >