jQuery MiniUI

标题: 数据过多使用虚拟滚动时合并单元格方法失效 [打印本页]

作者: creasy-pita    时间: 2013-12-31 11:30:47     标题: 数据过多使用虚拟滚动时合并单元格方法失效

数据过多时使用虚拟滚动(virtualScroll=true)时调用grid.mergeCells()无效果

作者: felt    时间: 2013-12-31 13:19:05

你是怎样合并的
作者: creasy-pita    时间: 2013-12-31 13:33:52

本帖最后由 creasy-pita 于 2013-12-31 13:35 编辑

        $(function ()
        {...
grid.load();
GoMerge();
}
        function GoMerge(e)
        {
            var merges = new Array();
            for (var pos = 0; pos < 40; pos++)
            {
                merges.push({ rowIndex: 9 * pos, columnIndex: 0, rowSpan: 9, colSpan: 1 });
                merges.push({ rowIndex: 9 * pos, columnIndex: 1, rowSpan: 9, colSpan: 1 });
                merges.push({ rowIndex: 9 * pos, columnIndex: 2, rowSpan: 9, colSpan: 1 });
                merges.push({ rowIndex: 9 * pos, columnIndex: 3, rowSpan: 9, colSpan: 1 });
                merges.push({ rowIndex: 3 * pos, columnIndex: 4, rowSpan: 3, colSpan: 1 });
                merges.push({ rowIndex: 3 * pos, columnIndex: 5, rowSpan: 3, colSpan: 1 });
                merges.push({ rowIndex: 3 * pos + 3, columnIndex: 4, rowSpan: 3, colSpan: 1 });
                merges.push({ rowIndex: 3 * pos + 3, columnIndex: 5, rowSpan: 3, colSpan: 1 });
                merges.push({ rowIndex: 3 * pos + 6, columnIndex: 4, rowSpan: 3, colSpan: 1 });
                merges.push({ rowIndex: 3 * pos + 6, columnIndex: 5, rowSpan: 3, colSpan: 1 });   
            }
            grid.mergeCells(merges);
        }上面是代码,数据近1000,合并数较多

作者: creasy-pita    时间: 2013-12-31 13:39:26

本帖最后由 creasy-pita 于 2013-12-31 13:42 编辑
creasy-pita 发表于 2013-12-31 13:33
$(function ()
        {...
grid.load();

改用下边代码可以合并了,但是出现错位,列数时对的      
$(function ()
        {...
            grid.load(null, function ()
            {
                GoMerge()
            })
}
作者: factory    时间: 2013-12-31 13:50:48

creasy-pita 发表于 2013-12-31 13:33
$(function ()
        {...
grid.load();

虚拟滚动目前不支持合并单元格,后续我们处理下
作者: creasy-pita    时间: 2013-12-31 13:55:40

factory 发表于 2013-12-31 13:50
虚拟滚动目前不支持合并单元格,后续我们处理下

好的,谢谢啦
作者: creasy-pita    时间: 2013-12-31 14:07:11

creasy-pita 发表于 2013-12-31 13:55
好的,谢谢啦

请问,一般更新会在什么时候
作者: factory    时间: 2013-12-31 14:25:19

creasy-pita 发表于 2013-12-31 14:07
请问,一般更新会在什么时候

功能加上之后,会在下一个周一发布更新




欢迎光临 jQuery MiniUI (http://miniui.com/discuss/) Powered by Discuz! X2