Quellcode durchsuchen

更改日志打印

样式分支
fyf vor 2 Jahren
Ursprung
Commit
b0a95aec58
2 geänderte Dateien mit 9 neuen und 4 gelöschten Zeilen
  1. +1
    -1
      BPASmartClient.IoT/DataVClient.cs
  2. +8
    -3
      BPASmartClient.IoT/Model/FileUpload.cs

+ 1
- 1
BPASmartClient.IoT/DataVClient.cs Datei anzeigen

@@ -299,7 +299,7 @@ namespace BPASmartClient.IoT
string FileName = result.data?.fileName;
string uploadId = result.data?.uploadId;
FileUpload.FileSend(DeviceDataV, uploadId, result.data.offset);
MessageLog.GetInstance.Show($"[阿里云上传]:请求上传云回执成功.");
//MessageLog.GetInstance.Show($"[阿里云上传]:请求上传云回执成功.");
}
else
MessageLog.GetInstance.Show($"[阿里云上传]:请求上传云回执失败.原因:{result.message}");


+ 8
- 3
BPASmartClient.IoT/Model/FileUpload.cs Datei anzeigen

@@ -84,7 +84,7 @@ namespace BPASmartClient.IoT.Model
//fileUpload.@params.extraParams.fileTag = new Dictionary<string, string> { {"Time", DateTime.Now.ToString("yyyy_M_d") },{"Name", "HBL.LogDir" } };

dataV.IOT_Publish(dataV.FileUpLoadTopic, Tools.JsonConvertTools(fileUpload));
MessageLog.GetInstance.Show($"[阿里云上传]:第[{i+1}]包数据,请求上传.");
//MessageLog.GetInstance.Show($"[阿里云上传]:第[{i+1}]包数据,请求上传.");

int count = 0;
while (modelResult == null)//等待上传完成
@@ -100,8 +100,13 @@ namespace BPASmartClient.IoT.Model

;

if(modelResult.code==200)
MessageLog.GetInstance.Show($"[阿里云上传]:第[{i + 1}]包,上传成功.");
if (modelResult.code == 200)
{
if (modelResult.data.complete)
{
MessageLog.GetInstance.Show($"[阿里云上传]:文件上传完成,总长度[{modelResult.data.bSize}]字节.");
}
}
else
MessageLog.GetInstance.Show($"[阿里云上传]:第[{i + 1}]包,上传失败.原因:{modelResult.message}");
;


Laden…
Abbrechen
Speichern