Skip to content

Commit

Permalink
fix: incorrect file name in task files view (#285)
Browse files Browse the repository at this point in the history
  • Loading branch information
monkeyWie authored Dec 2, 2023
1 parent 16b7a3d commit 6538766
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
5 changes: 3 additions & 2 deletions ui/flutter/lib/app/modules/task/views/task_files_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,9 @@ class TaskFilesView extends GetView<TaskFilesController> {
final meta = controller.task.value!.meta;
final file = fileList[index];
// if resource is single file, use opts.name as file name
final realFileName =
meta.res!.name.isEmpty ? file.name : "";
final realFileName = meta.res!.name.isEmpty
? (meta.opts.name.isEmpty ? file.name : meta.opts.name)
: "";
final fileRelativePath = file.filePath(realFileName);
final filePath = Util.safePathJoin(
[meta.opts.path, meta.res!.name, fileRelativePath]);
Expand Down
8 changes: 5 additions & 3 deletions ui/flutter/lib/app/views/buid_task_list_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -205,9 +205,11 @@ class BuildTaskListView extends GetView {
)),
],
),
LinearProgressIndicator(
value: getProgress(),
),
isDone()
? Container()
: LinearProgressIndicator(
value: getProgress(),
),
],
),
)).padding(horizontal: 14, top: 8);
Expand Down

0 comments on commit 6538766

Please sign in to comment.