diff --git a/Services/MinioDownloadTask.cs b/Services/MinioDownloadTask.cs index 5d63252..749e99e 100644 --- a/Services/MinioDownloadTask.cs +++ b/Services/MinioDownloadTask.cs @@ -53,7 +53,7 @@ public class MinioDownloadTask : INotifyPropertyChanged [SugarColumn(ColumnName = "file_path")] public string FilePath { get; set; } - [SugarColumn(ColumnName = "status")] public string Status { get; private set; } = "等待中"; + [SugarColumn(ColumnName = "status")] public string Status { get; set; } = "等待中"; [SugarColumn(IsIgnore = true)] public string Progress @@ -70,13 +70,14 @@ public class MinioDownloadTask : INotifyPropertyChanged CancelCommand = new CustomCommand(OnCancel); } - public MinioDownloadTask(MinioService minio, string bucket, string objectKey) + public MinioDownloadTask(MinioService minio, string bucket, string objectKey, string downDir) { + Status = "等待中"; _minio = minio; Bucket = bucket; ObjectKey = objectKey; FileName = Path.GetFileName(objectKey); - FilePath = "f:\\dest"; + FilePath = downDir; PauseCommand = new CustomCommand(OnPause); CancelCommand = new CustomCommand(OnCancel); } @@ -103,7 +104,7 @@ public class MinioDownloadTask : INotifyPropertyChanged await client.Updateable(updateTask).IgnoreNullColumns().ExecuteCommandAsync(); } - Console.WriteLine($"{ObjectKey}文件下载中..."); + Console.WriteLine($"id {TaskId} path: {FilePath} key: {ObjectKey}文件下载中..."); updateTask.Status = "下载中"; await _minio.DownLoadObject(Bucket, ObjectKey, FilePath, ""); Status = "已完成"; diff --git a/View/Loyout/ExplorerControl.xaml b/View/Loyout/ExplorerControl.xaml index b73b1ed..71558b8 100644 --- a/View/Loyout/ExplorerControl.xaml +++ b/View/Loyout/ExplorerControl.xaml @@ -27,8 +27,8 @@