B2017-245 Disable the Save RO Button for Section and Procedure Titles

This commit is contained in:
Rich 2017-11-06 16:48:47 +00:00
parent 94bf1c70a4
commit 090b3cd452

View File

@ -232,7 +232,9 @@ namespace Volian.Controls.Library
string childroid = chld.roid.ToLower() + "0000";
childroid = childroid.Substring(0, 16);
bool isenh = MyRTB != null && MyRTB.MyItemInfo != null && MyRTB.MyItemInfo.IsEnhancedStep;
btnSaveRO.Enabled = !isenh && UserInfo.CanEdit(MyUserInfo, Mydvi) && ((_SavCurROLink == null) || !(childroid.Equals(SavROLink.ROID.ToLower()))); //added security check (UserInfo.CanEdit)
//B2017-245 Disable SAveRO buttton for Procedues and Sections
bool isNotStep = MyRTB != null && MyRTB.MyItemInfo != null && (MyRTB.MyItemInfo.IsProcedure || MyRTB.MyItemInfo.IsSection);
btnSaveRO.Enabled = !isNotStep && !isenh && UserInfo.CanEdit(MyUserInfo, Mydvi) && ((_SavCurROLink == null) || !(childroid.Equals(SavROLink.ROID.ToLower()))); //added security check (UserInfo.CanEdit)
btnCancelRO.Enabled = ((_SavCurROLink != null) && childroid != SavROLink.ROID.ToLower());
btnGoToRO.Enabled = UserInfo.CanEditROs(MyUserInfo, Mydvi); // Writers and Reviewers cannot edit ROs (run the RO Editor)
switch (chld.type)