我在Angularjs应用程序中使用bootstrap table。我们可以通过将其visible属性设置为false来隐藏列,但现在我必须隐藏列,如果该列的所有字段都为null。那么有人可以建议我怎么做吗?
代码JS文件:
$scope.mediaTableControl = {
options: {
data: $scope.medias,
},
columns: [
{
field: 'DisplayId',
title: 'Media Id',
align: 'center',
valign: 'bottom',
sortable: true,
formatter: mediaIdFormatter
},
{
field: 'Created',
title: 'Date Received',
align: 'center',
valign: 'middle',
formatter: dateFormatter,
sortable: true
}
]
};
HTML文件代码:
<table bs-table-control="datasetTableControl" id="datasetTable"></table>