javascript - datatable.colReorder 未定义
问题描述
绘制后我需要更改列顺序。这是我所做的
$(document).ready(function () {
var $datatable = $('.dataTable').DataTable();
$datatable.on( 'draw', function () {
console.log( "DONE" );
$datatable.colReorder.move( 4, 2 );
} );
});
输出如下
DONE view:1972:21
TypeError: $datatable.colReorder is undefined
解决方案
推荐阅读
- python - Pandas-屏蔽两个数据帧之间的行/列,其中索引不共享
- sql - 尝试在 DB2 的 SPROC 中重命名多个表时出错
- r - 从文件中选择一个部分 r studio
- scheme - 如何解决来自定义变量的错误?
- python - 在服务器上运行的 Python 可以与用户的操作系统交互吗?
- reactjs - React Native:放置全局状态变量的位置
- swift - CAShapeLayer 未按需要渲染
- python - 在抓取 JSON 响应时跳过 NOT Available 值
- angular - Angular 中 Typescript 中联合类型的行为
- javascript - 如何从嵌套的承诺中获取最终承诺链中的数据