Dojo Gridx 列禁止调整宽度
要禁止Gridx中的列调整宽度,可以通过设置列的'resizable'属性为false来实现。例如:
var columns = [
{field: 'id', name: 'ID', width: '50px', resizable: false},
{field: 'name', name: 'Name', width: '150px', resizable: false},
{field: 'age', name: 'Age', width: '50px', resizable: false}
];
var grid = new Grid({
id: 'myGrid',
store: store,
structure: columns
}, 'gridNode');
在上面的示例中,每个列的'resizable'属性都设置为false,因此用户将无法调整列的宽度。
原文地址: https://www.cveoy.top/t/topic/ogIf 著作权归作者所有。请勿转载和采集!