Access rights clean-up for PL

This commit is contained in:
Milan Hanajik 2023-05-19 15:39:27 +02:00
parent e6fc3c25d6
commit 3bc8b55429
5 changed files with 13 additions and 9 deletions

View File

@ -356,7 +356,7 @@ namespace TBF.Rig.Sequences
}
while (StateMachine.Procedure == null); /// Make sure a valid procedure is selected
#if KEMPNO_50 || KRAKOW_50 || TORUN_50 || WARSAW_50 || WARSAW_END
#if LANG_PL
///
/// Approval of a legalizator
///

View File

@ -6,6 +6,7 @@ using System.Collections.Generic;
using System.Windows.Forms;
using NHibernate;
using log4net;
using Common;
using Config.Entities;
using TBF.Rig;
using TBF.Resources;
@ -34,7 +35,9 @@ namespace TBF.UI.Bench.Metrology
/// SharedDlgButtons configuration
sharedButtons.ParentForm = this;
sharedButtons.RequiredGroupMembership = new Common.GID[] { Common.GID.Metrologists, Common.GID.MetrologicalAuthority };
sharedButtons.RequiredGroupMembership = new GID[] { GID.Metrologists,
GID.MetrologicalAuthority,
GID.WaterMeterAuthority };
sharedButtons.OptionalButtons = SharedButtons.Buttons.Add | SharedButtons.Buttons.Remove;
sharedButtons.Unlocked += unlockButton_Click;
sharedButtons.OKClicked += okButton_Click;

View File

@ -71,7 +71,7 @@ namespace TBF.UI.Bench.TestProfiles
/// SharedDlgButtons configuration
sharedButtons.ParentForm = parentForm;
sharedButtons.RequiredGroupMembership = new Common.GID[] { Common.GID.MetrologicalAuthority };
sharedButtons.RequiredGroupMembership = new GID[] { GID.MetrologicalAuthority };
sharedButtons.OptionalButtons = SharedButtons.Buttons.Add |
SharedButtons.Buttons.Remove |
SharedButtons.Buttons.Up |

View File

@ -6,6 +6,7 @@ using System.Collections.Generic;
using System.Windows.Forms;
using NHibernate;
using log4net;
using Common;
using Config.Entities;
using TBF.Rig;
using TBF.Resources;
@ -34,10 +35,10 @@ namespace TBF.UI.Bench.Uncertainties
/// SharedDlgButtons configuration
sharedButtons.ParentForm = this;
#if KEMPNO_50
sharedButtons.RequiredGroupMembership = new Common.GID[] { Common.GID.MetrologicalAuthority };
#if LANG_PL
sharedButtons.RequiredGroupMembership = new GID[] { GID.MetrologicalAuthority };
#else
sharedButtons.RequiredGroupMembership = new Common.GID[] { Common.GID.Metrologists };
sharedButtons.RequiredGroupMembership = new GID[] { GID.Metrologists, GID.MetrologicalAuthority };
#endif
sharedButtons.OptionalButtons = SharedButtons.Buttons.Add | SharedButtons.Buttons.Remove;
sharedButtons.Unlocked += unlockButton_Click;

View File

@ -1,7 +1,7 @@
///
/// Copyright (c) 2013-2022 Sensus Slovensko a.s.
///
#if ORACLE_DB || KEMPNO_50 || KRAKOW_50 || TORUN_50 || WARSAW_50 || WARSAW_END
#if LANG_PL
#define SHOW_Q_TG
#endif
@ -135,7 +135,7 @@ namespace TBF.UI.Procedures
/// Dynamic SharedDlgButtons configuration
sharedButtons.ParentForm = parentForm;
#if KEMPNO_50 || KRAKOW_50 || TORUN_50 || WARSAW_50 || WARSAW_END
#if LANG_PL
sharedButtons.RequiredGroupMembership = procedure.Protected ? new GID[] { GID.WaterMeterAuthority }
: new GID[] { GID.TestingSpecialists, GID.WaterMeterAuthority };
#else
@ -360,7 +360,7 @@ namespace TBF.UI.Procedures
LoadUISettings();
/// Enable/disable/show/hide controls in General tab
#if KEMPNO_50 || KRAKOW_50 || TORUN_50 || WARSAW_50 || WARSAW_END
#if LANG_PL
altProcNameLabel.Visible = true;
altProcNameTextBox.Visible = true;
//altProcPeriodLabel.Visible = true;