如下数据绑定,设置了 position visible: false,excel导出时会把position添加到隐藏栏位中。
请问,不需要将position导出也不要添加到隐藏栏位中,如何处理?
var datasource = [
{ name: 'Alice', age: 27, birthday: '1985/08/31', position: 'PM' }
];
var colInfos = [
{ name: 'name', displayName: 'Display Name', size: 120 },
{ name: 'birthday', displayName: 'Birthday', formatter: 'd/M/yy', size: 120 },
{ name: 'age', displayName: 'Age', size: 120},
{ name: 'position', displayName: 'Position', size: 120, visible: false },
];
sheet.autoGenerateColumns = false;
sheet.bindColumns(colInfos);
sheet.setDataSource(datasource);
|
|