【发布时间】:2020-06-20 14:30:17
【问题描述】:
如何在 Flutter 中隐藏 DataTable 的列标题?
DataTable in Flutter
DataTable(
headingRowHeight: 0,
columns: <DataColumn>[
DataColumn(label: Text("Name")),
DataColumn(label: Text("Hour")),
DataColumn(label: Text("Tag")),
DataColumn(label: Text("Date")),
DataColumn(label: Text("Action")),
], rows: lstCourse.map((e) => DataRow(
cells: <DataCell>[
DataCell(Text(e.Name)),
DataCell(Text(e.Hour_Text)),
DataCell(Text(e.Tag)),
DataCell(Text(e.StartDate_Text)),
DataCell(RaisedButton(onPressed: (){}, child: Text("Đăng ký"),)),
]
)).toList()
);
我试图在 DataTable 类中找到一些选项,但似乎不存在
【问题讨论】:
-
设置
headingRowHeight= 0.0 ? -
@Kahou 设置 headerRowHeight 不起作用
-
您能否编辑您的问题以添加相关的 html 和代码(作为文本,而不是链接)?可能有多种可能的解决方案,但这取决于您的表是如何定义的。
-
@andrewjames 已经更新
-
你能显示表格的 html 定义吗?或者显示 HTML 是如何生成的?
标签: flutter dart mobile datatable