mirror of
https://github.com/GopeedLab/gopeed.git
synced 2026-11-08 01:20:27 +00:00
feat(task): show a dash for completed tasks without a done time
Tasks completed before this change have no doneAt value; the drawer now always renders the Completed at row for completed tasks and falls back to a dash instead of hiding the row.
This commit is contained in:
1 parent
1d8a502ac4
commit
7bc7efed5b
2 files changed
+32
-2
No files matched your search
@@ -319,8 +319,14 @@ class _TaskInfoTab extends StatelessWidget {
|
||||
_InfoBlock(label: context.l10n.remaining, value: remaining),
|
||||
if (task.createdAt case final createdAt?)
|
||||
_InfoBlock(label: context.l10n.createdAt, value: _formatTaskDateTime(createdAt)),
|
||||
if (task.doneAt case final doneAt?)
|
||||
_InfoBlock(label: context.l10n.doneAt, value: _formatTaskDateTime(doneAt)),
|
||||
if (task.status == TaskStatus.completed)
|
||||
_InfoBlock(
|
||||
label: context.l10n.doneAt,
|
||||
value: switch (task.doneAt) {
|
||||
final doneAt? => _formatTaskDateTime(doneAt),
|
||||
_ => '—',
|
||||
},
|
||||
),
|
||||
Container(
|
||||
key: const ValueKey('task-details-info-divider'),
|
||||
height: 1,
|
||||
|
||||
Reference in new issue
Block a user