parlay96 / pl-table Goto Github PK
View Code? Open in Web Editor NEWA table based on element, 完美解决万级数据渲染卡顿问题
Home Page: http://www.umyui.com/
License: MIT License
A table based on element, 完美解决万级数据渲染卡顿问题
Home Page: http://www.umyui.com/
License: MIT License
引入'pl-table/themes/index.css'后,会污染项目中表格的样式,甚至是表单的样式
场景:一个报表页面,可以根据不同查找条件返回数据.
问题:当前后查找数据行数不一致的时候,会有一定概率出现数据显示不全(缺失部分数据),底下合计却是正确的.常见问题是,前一个结果行数比较少,后一个查找结果比较多,但是table只显示了和前面一个结果一样多行数的数据,其余数据丢失,但是底下的合计却是正确的.
这个问题发生概率很高,早上专门测试了一下,10分钟内出现了2,3次,不知道是否和页面的宽度变化有关系,实在毫无头绪,望给予提示.
我这边数据加载是用AJAX异步加载的,结果直接赋给pltable的数据变量.
就只看到一个 ”field-sort 显示字段是否排序 Boolean true”
还是默认打开的。
但是在表头就是显示不了排序的符号。
可能是缺少手动设置的排序方法,但是,这个方法我在field里写了sortMethod,也不行
原来element-ui是用下面这段代码实现的,现在这样用只有行样式会变化,复选框不会勾选。
handleRowClick: function (row, event, column) { this.$refs.tableRows.toggleRowSelection(); }
无论设置了 还是没设置都不起作用
element ui className 合并列 都不能使用吗?
现在采用的el-table 嵌套select和input框做可以编辑表格,当一次性加载多条时,因节点过多,页面会很卡,采用pl-table会有这种问题吗
表格设置row-height为20的时候,有fixed=“right”属性的列高度与没有fixed属性列高度出现差异,导致行无法对齐,请大佬看看
我现在是每页显示200条数据,然后拖动纵向滚动条的时候感觉有卡顿,不是很流畅,请问下应该怎么解决?
版本:2.4.8
问题描述:在仅一条数据渲染时,并且有横向滚动条时,并且表头和数据同步获取的情况下,表格高度计算错误少了滚动条的高度
问题模拟:https://jsfiddle.net/ufL2qht4/
页面el-tabs中使用pl-table,前两列固定,切换el-tabs时,表头的渲染和数据的渲染有什么改进吗
用 computed 當 datas 資料來源,computed 裡做了 filter 過濾,有時會出現資料沒全部顯示的問題,
此時只要捲軸動一下又會跑出來了,請問如何解?
比如我一开始就全选所有行,然后遍历tableData数据切换每一项的选中状态为false,但是全选框还是为全选状态
我想配置webpack的externals
在IE下报 对象不支持“forEach”属性或方法"
参考浏览器兼容性
做了以下处理还是没有作用
{
useBuiltIns: 'usage',
polyfills: [
'es6.promise',
'es6.symbol',
'es6.array.from',
'es6.array.for-each'
]
}
表格的选中行,总会因为各种操作就自动取消
比如:
1,页面高度发生改变;
2,页面有下拉框,一选中值;
3,各种弹出框
4,....
哪位大佬指点一下是否有类似的问题,element table没有这样子的问题.
你好,出错的时候,那个配置 怎么在vue.config.js里面配置
API文档中有写到
空数据时显示的文本内容,也可以通过 slot="empty" 设置
<template slot="empty">
<icon class="el-icon-warning-outline"></icon>
没有查询到符合条件的记录
</template>
但其实用slot的方式,没有正常显示
但是pl-table.js 8264行又有对这个empty slot的实现
_vm._t("empty")
当前版本 "pl-table": "^2.4.7",
headerRowClassName函数指定的class依然没有覆盖默认的element table 样式
需要通过/deep/来修改表头样式
主要是 background-color 与color样式
<pl-table headerRowClassName="haha"></pl-table>
<style>
.haha {
background-color: rgb(0, 51, 102) !important;
color: red;
text-align: center
}
</style>
color成功修改,但bg-color只修改了最右边的背景,子类的的没有没修改
<table><thead><tr class='haha'><th>
真正修改表头的背景颜色,需要
/deep/ .plTableBox .el-table th {
color: #fff;
background-color: rgb(0, 51, 102);
}
element有对应的表头属性可以设置
header-cell-style="{'background': 'rgb(0, 51, 102)', 'color': '#fff'}"
使用keep-alive包裹pl-table,pl-table在开启use-virtual后,pl-table 滚动一段距离,跳转到下一个页面,然后再返回当前页面,发现pl-table从第一行开始渲染的
已经尝试过给数据添加id 每页数据小于1000条 还是无法实现翻页保留勾选数据。
高度设置为500px,但实际表格高度未达到500,一屏仅能展示4条数据,如何让表格高度和父容器高度一致呢
示例:https://jsfiddle.net/6hpys8e3/2/
不是vue项目该如何引用?有没有cdn引用的方式(有的话提供一个地址)?
<pl-table-column
width="90"
label="失效数"
prop="failNum"
sortable>
</pl-table-column>
<el-table-column
v-for="(val, key) in slotSave"
:key="'failNum' + key"
:prop="'failNum' + key"
:label="key + '失效数'"
sortable
width="120">
<template slot-scope="scope">
xxx
</template>
</el-table-column>
pl-table可以使用原el-table的@header-click的事件,可以获取排序需要传给后端的值
<pl-table :datas="events"
use-virtual
:row-height="45"
:paginationShow="false">
</pl-table>
data(){
return {
events: {}
}}
当events声明为对象时,会造成浏览器标签页无响应, favicon一直在转,
卡死的标签cpu占用率维持在25%,消耗300MB内存
是有在轮询什么数据吗?
不应该先去执行typeof datas===array,
然后抛出数据异常错误吗?
那下个版本什么时候会发布?
<template slot-scope="scope"> <el-autocomplete v-model="scope.row.code" :fetch-suggestions="querySearch" placeholder="请输入内容" size="small" style="width: 100%" @select="handleSelect" show-word-limit ></el-autocomplete> </template>
不支持el-autocomplete
已设置 sortable=true,点击排序无反应
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.