/// <summary> /// Select Class Announcements Type From Dropdown. /// </summary> /// <param name="announcementType">This is Announcement Type.</param> public void SelectClassAnnouncementsTypeFromDropdown(string announcementType) { //Select Class Announcements Type From Dropdown logger.LogMethodEntry("AnnouncementDefaultUXPage", "SelectClassAnnouncementsTypeFromDropdown", base.IsTakeScreenShotDuringEntryExit); try { //Declaration of class object AnnouncementDefaultUXPage announcementDefaultUxPage = new AnnouncementDefaultUXPage(); //Select the frame announcementDefaultUxPage.SelectGlobalAnnouncementframe(); //Wait for the element base.WaitForElement(By.Id(AnnouncementDefaultUXPageResource. AnnouncementDefaultUX_Page_ViewBy_DropDown_Id_Locator)); // Select system announcement in 'View by' Dropdown base.SelectDropDownValueThroughTextById(AnnouncementDefaultUXPageResource. AnnouncementDefaultUX_Page_ViewBy_DropDown_Id_Locator, announcementType); Thread.Sleep(Convert.ToInt32(AnnouncementDefaultUXPageResource. AnnouncementDefaultUX_Page_ThreadSleep_Value)); } catch (Exception e) { ExceptionHandler.HandleException(e); } logger.LogMethodExit("AnnouncementDefaultUXPage", "SelectClassAnnouncementsTypeFromDropdown", base.IsTakeScreenShotDuringEntryExit); }
/// <summary> /// Create course Announcement in CS /// </summary> public void CreateCourseAnnouncementInCs() { logger.LogMethodEntry("CreateAnnouncementUXPage", "CreateCourseAnnouncementInCs" , base.IsTakeScreenShotDuringEntryExit); try { //Declaration of class object AnnouncementDefaultUXPage announcementDefaultUxPage = new AnnouncementDefaultUXPage(); //Select Announcement Frame announcementDefaultUxPage.SelectAnnouncementFrameInCs(); //Click on the CreateAnnouncement Button new AnnouncementDefaultUXPage().ClickCreateAnnouncementButton(); //Enter Annoucement Subject And Description this.EnterAnnoucementSubjectAndDescription(); //Select Announcement frame new AnnouncementDefaultUXPage().SelectAnnouncementFrameInCs(); //Click on To.. Button this.ClickAnnouncementToButton(); //Select Announcement frame new AnnouncementDefaultUXPage().SelectAnnouncementFrameInCs(); // Add Recipients new AnnouncementRecipientListUXPage().AddRecipients(); //Select Announcement Frame announcementDefaultUxPage.SelectAnnouncementFrameInCs(); // Click Create Button this.ClickAnnouncementCreateButton(); } catch (Exception e) { ExceptionHandler.HandleException(e); } logger.LogMethodExit("CreateAnnouncementUXPage", "CreateCourseAnnouncementInCs", base.IsTakeScreenShotDuringEntryExit); }
/// <summary> /// Create Class Announcement In GlobalHome. /// </summary> /// <param name="announcementType">This is Announcement Type Enum.</param> public void CreateClassAnnouncementInGlobalHome( Announcement.AnnouncementTypeEnum announcementType) { // Create Class Announcement In GlobalHome logger.LogMethodEntry("CreateAnnouncementPage", "CreateClassAnnouncementInGlobalHome", base.IsTakeScreenShotDuringEntryExit); try { //Declaration of class object AnnouncementDefaultUXPage announcementDefaultUxPage = new AnnouncementDefaultUXPage(); //Select the frame announcementDefaultUxPage.SelectGlobalAnnouncementframe(); //Click on the 'Create Announcement' button new AnnouncementDefaultUXPage().ClickCreateAnnouncementButton(); //Select the frame announcementDefaultUxPage.SelectGlobalAnnouncementframe(); //Click on To.. Button ClickAnnouncementToButton(); //Select the frame announcementDefaultUxPage.SelectGlobalAnnouncementframe(); //Click on the 'Add Recipients' Button new AnnouncementRecipientListUXPage().AddRecipients(); base.SwitchToDefaultPageContent(); //Select the frame announcementDefaultUxPage.SelectGlobalAnnouncementframe(); //Enter Annoucement Subject And Description string getAnnouncementSubject = this.EnterAnnoucementSubjectAndDescription(); //Select the frame announcementDefaultUxPage.SelectGlobalAnnouncementframe(); // Click Create Button this.ClickAnnouncementCreateButton(); // Store Announcement Details in Memory StoreAnnouncementDetailsInMemory(getAnnouncementSubject, announcementType); } catch (Exception e) { ExceptionHandler.HandleException(e); } logger.LogMethodExit("CreateAnnouncementPage", "CreateClassAnnouncementInGlobalHome", base.IsTakeScreenShotDuringEntryExit); }
/// <summary> /// Create course Announcement. /// </summary> /// <returns>Announcement Details.</returns> public string CreateCourseAnnouncement() { logger.LogMethodEntry("CreateAnnouncementUXPage", "CreateCourseAnnouncement" , base.IsTakeScreenShotDuringEntryExit); //Generate New Guid announcement Name Guid announcementGuid = Guid.NewGuid(); try { //Click ManageAll Button new MyPegasusUXPage().ClickAnnouncementManageAllButton(); //Declaration of class object AnnouncementDefaultUXPage announcementDefaultUxPage = new AnnouncementDefaultUXPage(); //Select Announcement Frame announcementDefaultUxPage.SelectAnnouncementFrame(); //Click on the CreateAnnouncement Button new AnnouncementDefaultUXPage().ClickCreateAnnouncementButton(); //Enter subject text this.EnterAnnouncementSubject(announcementGuid.ToString()); //Enter description text this.EnterAnnouncementDescription(announcementGuid.ToString()); //Select Announcement frame new AnnouncementDefaultUXPage().SelectAnnouncementFrame(); //Click on To.. Button ClickAnnouncementToButton(); //Select Announcement frame new AnnouncementDefaultUXPage().SelectAnnouncementFrame(); // Add Recipients new AnnouncementRecipientListUXPage().AddRecipients(); //Select Announcement Frame announcementDefaultUxPage.SelectAnnouncementFrame(); // Click Create Button this.ClickAnnouncementCreateButton(); } catch (Exception e) { ExceptionHandler.HandleException(e); } logger.LogMethodExit("CreateAnnouncementUXPage", "CreateCourseAnnouncement", base.IsTakeScreenShotDuringEntryExit); return(announcementGuid.ToString()); }