diff options
| author | Roy <roy.mail.net@gmail.com> | 2018-02-23 12:03:18 +0200 |
|---|---|---|
| committer | Roy <roy.mail.net@gmail.com> | 2018-02-23 12:03:18 +0200 |
| commit | fadf83a50071ffba21db05eceff10c51c18f5fb3 (patch) | |
| tree | 9a568aae8d298bfbc2135afaff0b91f9de711793 /Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher/MainWindowVM.cs | |
| parent | 042b4d3e7b0af729792ca20e086756c36d2f5768 (diff) | |
| download | Tango-fadf83a50071ffba21db05eceff10c51c18f5fb3.tar.gz Tango-fadf83a50071ffba21db05eceff10c51c18f5fb3.zip | |
Machine Studio Update & Publish.
Improved user roles & permissions structure.
Added permission for version publish.
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher/MainWindowVM.cs')
| -rw-r--r-- | Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher/MainWindowVM.cs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher/MainWindowVM.cs b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher/MainWindowVM.cs index 2ceb36994..34d2f1b1f 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher/MainWindowVM.cs +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Publisher/MainWindowVM.cs @@ -12,6 +12,7 @@ using System.Threading.Tasks; using System.Windows; using Tango.Core.Commands; using Tango.Core.Cryptography; +using Tango.Core.Helpers; using Tango.MachineStudio.Common.Update; using Tango.Settings; using Tango.SharedUI; @@ -121,6 +122,7 @@ namespace Tango.MachineStudio.Publisher Task.Factory.StartNew(() => { IsUpdating = true; + String tempFile = String.Empty; try { @@ -132,7 +134,7 @@ namespace Tango.MachineStudio.Publisher Comments = Comments, }); - String tempFile = Path.Combine(Path.GetTempPath(), response.FileName); + tempFile = Path.Combine(Path.GetTempPath(), response.FileName); using (ZipFile zip = new ZipFile()) { @@ -174,6 +176,11 @@ namespace Tango.MachineStudio.Publisher } } + _client.NotifyUploadCompleted(new UploadCompletedRequest() + { + Token = response.Token, + }); + UpdateVersions(); } catch (Exception ex) @@ -183,6 +190,7 @@ namespace Tango.MachineStudio.Publisher finally { IsUpdating = false; + PathHelper.TryDeleteFile(tempFile); } }); } |
