|
@@ -75,8 +75,26 @@ class LastRecordTable extends StatelessWidget {
|
|
|
// var controller = Get.find<HealthCheckListController>();
|
|
|
var tableRows = <TableRow>[];
|
|
|
for (var i = 0; i < tableData.length; i++) {
|
|
|
- final rowData = tableData[i];
|
|
|
+ final List<String> rowData = tableData[i];
|
|
|
final label = rowData[0];
|
|
|
+ List<Widget> children = [];
|
|
|
+ for (String child in rowData) {
|
|
|
+ if (rowData.indexOf(child) == 3) {
|
|
|
+ continue;
|
|
|
+ }
|
|
|
+ if (checkKey == "HEITCMC") {
|
|
|
+ children.add(_buildConstitutionDataCell(child));
|
|
|
+ }
|
|
|
+ if (label == '心电测量') {
|
|
|
+ children.add(_buildImageDataCell(child));
|
|
|
+ } else if (label == '十二导心电(30秒)') {
|
|
|
+ children.add(_buildImageDataCell(child));
|
|
|
+ } else if (label == '十二导分析结果') {
|
|
|
+ children.add(_buildEcg12DataCell(child));
|
|
|
+ } else {
|
|
|
+ children.add(_buildDataCell(child));
|
|
|
+ }
|
|
|
+ }
|
|
|
tableRows.add(
|
|
|
TableRow(
|
|
|
decoration: i % 2 == 0
|
|
@@ -84,22 +102,7 @@ class LastRecordTable extends StatelessWidget {
|
|
|
: const BoxDecoration(
|
|
|
color: Color.fromRGBO(233, 244, 255, 1),
|
|
|
),
|
|
|
- children: tableData[i].map(
|
|
|
- (cellData) {
|
|
|
- if (checkKey == "HEITCMC") {
|
|
|
- return _buildConstitutionDataCell(cellData);
|
|
|
- }
|
|
|
- if (label == '心电测量') {
|
|
|
- return _buildImageDataCell(cellData);
|
|
|
- } else if (label == '十二导心电(30秒)') {
|
|
|
- return _buildImageDataCell(cellData);
|
|
|
- } else if (label == '十二导分析结果') {
|
|
|
- return _buildEcg12DataCell(cellData);
|
|
|
- }
|
|
|
-
|
|
|
- return _buildDataCell(cellData);
|
|
|
- },
|
|
|
- ).toList(),
|
|
|
+ children: children,
|
|
|
),
|
|
|
);
|
|
|
}
|