예제 #1
0
        public static bool SelectSiteRowCheckboxAssignPlanGrid(List <FlagManagementData> ItemstoSelect, out List <String> FailedItemsList)
        {
            bool isSuccess           = true;
            bool areAllChckboxSelect = true;

            FailedItemsList = new List <String>();
            try
            {
                foreach (FlagManagementData ItemOptions in ItemstoSelect)
                {
                    if (ItemOptions.SiteID != null)
                    {
                        if (ItemOptions.CheckONOrOff.ToUpper() == "ON")
                        {
                            isSuccess = Control_ActionUtilities.CheckCheckbox(DL_FlagManagementPage.RowCheckBoxAssignGrid(ItemOptions.SiteID));
                        }
                        else if (ItemOptions.CheckONOrOff.ToUpper() == "OFF")
                        {
                            isSuccess = Control_ActionUtilities.UncheckCheckbox(DL_FlagManagementPage.RowCheckBoxAssignGrid(ItemOptions.SiteID));
                        }
                        if (!isSuccess)
                        {
                            FailedItemsList.Add(ItemOptions.SiteID);
                            areAllChckboxSelect = false;
                        }
                    }
                }
                return(areAllChckboxSelect);
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(areAllChckboxSelect);
        }
예제 #2
0
 public static bool SelectForms(List <UnschedueledEventFormsData> dataList)
 {
     try
     {
         foreach (UnschedueledEventFormsData data in dataList)
         {
             IControl formCheckbox = DL_AddUnscheduledEventStep2Page.GetFormCheckbox(data.FormName);
             if (!Control_PropertyUtilities.IsControlNull(formCheckbox))
             {
                 if (!Control_ActionUtilities.CheckCheckbox(formCheckbox))
                 {
                     return(false);
                 }
             }
             else
             {
                 return(false);
             }
         }
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 public static bool CheckStructueFixedcheckbox()
 {
     try
     {
         return(Control_ActionUtilities.CheckCheckbox(DS_Forms.StructureFixedCheckBox));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 public static bool AllCodeListItemsCheck()
 {
     try
     {
         return(Control_ActionUtilities.CheckCheckbox(CodeListsPage.CheckAllCodeListItems));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
예제 #5
0
 public static bool CheckAllProcessesCheckBox()
 {
     try
     {
         return(Control_ActionUtilities.CheckCheckbox(DS_StudyProperties.CheckAllProcesses));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 public static bool CheckEnablePaperDataEntryCheckbox()
 {
     try
     {
         return(Control_ActionUtilities.CheckCheckbox(DL_Study_EditPreferences_PaperEntryPage.Checkbox_EnablePaperDataEntry));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 public static bool CheckAllowOneUserBothTheEntriesCheckbox()
 {
     try
     {
         return(Control_ActionUtilities.CheckCheckbox(DL_Study_EditPreferences_PaperEntryPage.Checkbox_AllowOneUserToComplete));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
예제 #8
0
 public static bool CheckAllLabUnitCheckBox()
 {
     try
     {
         return(Control_ActionUtilities.CheckCheckbox(MapLabDictionary.CheckAllLabUnit));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
예제 #9
0
 static bool SelectRequestCheckbox(String eventName, String formName)
 {
     try
     {
         IControl checkbox = DL_RequestSignaturePage.GetRequestCheckboxForForm(eventName, formName);
         if (!Control_PropertyUtilities.IsControlNull(checkbox))
         {
             return(Control_ActionUtilities.CheckCheckbox(checkbox));
         }
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 static bool SelectFreezeThawCheckboxEventForm(String eventName, String formName, string checkboxName)
 {
     try
     {
         IControl checkbox = DL_FreezeThawCRFs.GetFreezeThawCheckboxForForm(eventName, formName, checkboxName);
         if (!Control_PropertyUtilities.IsControlNull(checkbox))
         {
             return(Control_ActionUtilities.CheckCheckbox(checkbox));
         }
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
예제 #11
0
 public static bool SelectCheckboxForFormQuestion(string FormName, string QuestionNo, string QuestionPrmt, string ProtocolVer)
 {
     try
     {
         IControl chkBox = DL_CreateFlagDataGroupPage.GetProtocolChkBoxForFormQuestion(FormName, QuestionNo, QuestionPrmt, ProtocolVer);
         if (Control_PropertyUtilities.IsControlNull(chkBox))
         {
             return(false);
         }
         return(Control_ActionUtilities.CheckCheckbox(chkBox));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 public static bool SelectViewDeletedReferenceRanges()
 {
     try
     {
         IControl chkBox = DL_Lab_Mrr_Delete.ViewDeletedReferenceRangesCheckBox;
         if (Control_PropertyUtilities.IsControlNull(chkBox))
         {
             return(false);
         }
         return(Control_ActionUtilities.CheckCheckbox(chkBox));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
 public static bool SearchInImportLabDictionaryErrors(string SelectDropDownOption, string dropDownList)
 {
     BrowserUtilities.DS_SwitchToFrame();
     try
     {
         ImportLabDictionaryPage.ErrorType.WebElement.Click();
         IControl dropDownOption = ImportLabDictionaryPage.SelectErrorFromDropDown(SelectDropDownOption, dropDownList);
         Control_ActionUtilities.CheckCheckbox(dropDownOption);
         BrowserUtilities.SwitchToWindow();
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
예제 #14
0
 public static bool SelectSelectAllCheckboxAssignPlanGrid(string CheckboxOnOff)
 {
     try
     {
         if (CheckboxOnOff.ToUpper() == "ON")
         {
             return(Control_ActionUtilities.CheckCheckbox(DL_FlagManagementPage.SelectAllPatientsSitesCheckbox));
         }
         else if (CheckboxOnOff.ToUpper() == "OFF")
         {
             return(Control_ActionUtilities.UncheckCheckbox(DL_FlagManagementPage.SelectAllPatientsSitesCheckbox));
         }
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
예제 #15
0
 public static bool ChkOnOrOffSelectAllChkBoxInEventFormRelation(string SelectOnOff)
 {
     try
     {
         if (SelectOnOff.ToUpper() == "ON")
         {
             return(Control_ActionUtilities.UncheckCheckbox(DL_CreateFlagDataGroupPage.GetSelectAllChkBoxInEventFormRelation));
         }
         else if (SelectOnOff.ToUpper() == "OFF")
         {
             return(Control_ActionUtilities.CheckCheckbox(DL_CreateFlagDataGroupPage.GetSelectAllChkBoxInEventFormRelation));
         }
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
예제 #16
0
        public static bool SelectCheckboxAddNewFlagDataGroup(string chkboxOnOff)
        {
            bool isSuccess = true;

            try
            {
                if (chkboxOnOff.ToUpper() == "ON")
                {
                    isSuccess = Control_ActionUtilities.CheckCheckbox(DL_CreateFlagPlanPage.AddNewDataGrpChk);
                }
                else if (chkboxOnOff.ToUpper() == "OFF")
                {
                    isSuccess = Control_ActionUtilities.UncheckCheckbox(DL_CreateFlagPlanPage.AddNewDataGrpChk);
                }
                return(isSuccess);
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(false);
        }
예제 #17
0
        public static bool ChkOrUnChkSelectAllEventFormChkBoxInEventFormRelation(List <FlagManagementData> EventFormData, out List <string> FailedEventForms)
        {
            FailedEventForms = new List <string>();
            bool isSuccess;
            bool areAllEventsSuccess = true;

            try
            {
                foreach (FlagManagementData eventFormName in EventFormData)
                {
                    if (eventFormName.CheckONOrOff.ToUpper() == "ON")
                    {
                        isSuccess = Control_ActionUtilities.CheckCheckbox(DL_CreateFlagDataGroupPage.GetChkBoxInFormEventRelation(eventFormName.EventName, eventFormName.FormName));
                    }
                    else if (eventFormName.CheckONOrOff.ToUpper() == "OFF")
                    {
                        isSuccess = Control_ActionUtilities.UncheckCheckbox(DL_CreateFlagDataGroupPage.GetChkBoxInFormEventRelation(eventFormName.EventName, eventFormName.FormName));
                    }
                    else
                    {
                        isSuccess = false;
                    }
                    if (!isSuccess)
                    {
                        FailedEventForms.Add(eventFormName.EventName + "->" + eventFormName.FormName);
                        areAllEventsSuccess = false;
                    }
                }
                return(areAllEventsSuccess);
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(false);
        }