From 74df89fafdc1cd2ed9f1b99fe54e926eb38c80a3 Mon Sep 17 00:00:00 2001 From: Roy Ben Shabat Date: Wed, 9 Sep 2020 15:54:02 +0300 Subject: Added firewall exception to FSE installer. Added new permission FSE_Run Procedure Project File. --- .../Advanced Installer Projects/FSE Installer.aip | 27 ++++++++++++++++------ .../ViewModels/ProcedureRunnerViewVM.cs | 7 ++++++ .../Tango.BL/Enumerations/Permissions.cs | 6 +++++ 3 files changed, 33 insertions(+), 7 deletions(-) (limited to 'Software/Visual_Studio') diff --git a/Software/Visual_Studio/Advanced Installer Projects/FSE Installer.aip b/Software/Visual_Studio/Advanced Installer Projects/FSE Installer.aip index 2e7633b3f..f8e32a2d0 100644 --- a/Software/Visual_Studio/Advanced Installer Projects/FSE Installer.aip +++ b/Software/Visual_Studio/Advanced Installer Projects/FSE Installer.aip @@ -64,6 +64,7 @@ + @@ -377,9 +378,10 @@ - - - + + + + @@ -754,6 +756,7 @@ + @@ -812,6 +815,7 @@ + @@ -879,6 +883,8 @@ + + @@ -905,7 +911,9 @@ + + @@ -1234,6 +1242,7 @@ + @@ -1264,14 +1273,18 @@ - - + + + + + + + + - - diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures/ViewModels/ProcedureRunnerViewVM.cs b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures/ViewModels/ProcedureRunnerViewVM.cs index 6ccc77669..6bf798b4f 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures/ViewModels/ProcedureRunnerViewVM.cs +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures/ViewModels/ProcedureRunnerViewVM.cs @@ -4,6 +4,7 @@ using System.IO; using System.Linq; using System.Threading.Tasks; using Tango.BL.Entities; +using Tango.BL.Enumerations; using Tango.Core; using Tango.Core.Commands; using Tango.FSE.Common; @@ -295,6 +296,12 @@ namespace Tango.FSE.Procedures.ViewModels private async void HandlerProcedureFileAssociation(FileAssociationPackage package) { + if (!CurrentUser.HasPermission(Permissions.FSE_RunProcedureProjectFile)) + { + await NotificationProvider.ShowError("Current user profile does not allow loading unpublished procedures."); + return; + } + if (File.Exists(package.File)) { try diff --git a/Software/Visual_Studio/Tango.BL/Enumerations/Permissions.cs b/Software/Visual_Studio/Tango.BL/Enumerations/Permissions.cs index 578a95ec8..8591cf826 100644 --- a/Software/Visual_Studio/Tango.BL/Enumerations/Permissions.cs +++ b/Software/Visual_Studio/Tango.BL/Enumerations/Permissions.cs @@ -265,5 +265,11 @@ namespace Tango.BL.Enumerations [Description("Allows viewing published procedure projects with internal visibility")] FSE_ViewInternalPublishedProcedures = 1019, + /// + /// (Allows running a floating procedure project file.) + /// + [Description("Allows running a floating procedure project file.")] + FSE_RunProcedureProjectFile = 1020, + } } -- cgit v1.3.1