Example #1
0
        /// <summary>
        /// Goes to the Add Adjustment tab if we are not already there, clicks the Add Adjustment link, chooses an Adjustment Code from the select
        /// element, enters a start and end date, selects a leave code (this overload is for the Leave program adjustment). Then clicks the
        /// Add Adjustment button
        /// </summary>
        /// <param name="adjustmentCode">The exact text of the adjustment code that you want to chooose in the Adjustment Code select element</param>
        /// <param name="leaveStartDate"></param>
        /// <param name="leaveEndDate"></param>
        /// <param name="leaveCode"></param>
        internal void AddProgramAdjustment(LSConstants.AdjustmentCodes adjustmentCode, string leaveStartDate, string leaveEndDate, string leaveCode)
        {
            ClickAndWait(ProgramAdjustmentsTab);

            ClickAndWait(ProgAdjustTabAddAdjustLnk);

            ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("LEAVE");

            Browser.WaitForElement(Bys.ProgramPage.ProgAdjustTabAddAdjustFormLeaveStartDtTxt, ElementCriteria.IsVisible);
            ProgAdjustTabAddAdjustFormLeaveStartDtTxt.SendKeys(leaveStartDate);
            ProgAdjustTabAddAdjustFormLeaveEndDtTxt.SendKeys(leaveEndDate);
            ProgAdjustTabAddAdjustFormLeaveCodeSelElem.SelectByText(leaveCode);

            ClickAndWait(ProgAdjustTabAddAdjustFormAddAdjustBtn);
        }
Example #2
0
        /// <summary>
        /// Goes to the Add Adjustment tab if we are not already there, clicks the Add Adjustment link, chooses an Adjustment Code from the select
        /// element, then enters an effective date (this overload is for the reinstated, per program, pra program, voluntary program, international
        /// program, main program and resident program program adjustments). Then clicks the Add Adjustment button
        /// </summary>
        /// <param name="adjustmentCode">The exact text of the adjustment code that you want to chooose in the Adjustment Code select element</param>
        /// <param name="effectiveDate"></param>
        internal void AddProgramAdjustment(LSConstants.AdjustmentCodes adjustmentCode, string effectiveDate)
        {
            ClickAndWait(ProgramAdjustmentsTab);

            ClickAndWait(ProgAdjustTabAddAdjustLnk);

            switch (adjustmentCode)
            {
            case LSConstants.AdjustmentCodes.REINSTATEDNonCompliance:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("REINSTATED - NON COMPLIANCE");
                break;

            case LSConstants.AdjustmentCodes.REINSTATEDOther:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("REINSTATED - OTHER");
                break;

            case LSConstants.AdjustmentCodes.PERProgram:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("PER Program");
                break;

            case LSConstants.AdjustmentCodes.PRAProgram:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("PRA Program");
                break;

            case LSConstants.AdjustmentCodes.VoluntaryProgram:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("Voluntary Program");
                break;

            case LSConstants.AdjustmentCodes.InternationalProgram:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("International Program");
                break;

            case LSConstants.AdjustmentCodes.MainProgram:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("Main Program");
                break;

            case LSConstants.AdjustmentCodes.ResidentProgram:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("Resident Program");
                break;
            }

            Browser.WaitForElement(Bys.ProgramPage.ProgAdjustTabAddAdjustFormEffectiveDtRdo, ElementCriteria.IsVisible);
            ProgAdjustTabAddAdjustFormEffectiveDtRdo.Clear();
            ProgAdjustTabAddAdjustFormEffectiveDtRdo.SendKeys(effectiveDate);
            ProgAdjustTabAddAdjustFormEffectiveDtRdo.SendKeys(Keys.Tab);

            ClickAndWait(ProgAdjustTabAddAdjustFormAddAdjustBtn);
        }
Example #3
0
        /// <summary>
        /// Goes to the Add Adjustment tab if we are not already there, clicks the Add Adjustment link, chooses an Adjustment Code from the select
        /// element, and clicks on the Yes or No radio button (this overload is for the INTNL and Voluntary program adjustments). Then
        /// clicks the Add Adjustment button
        /// </summary>
        /// <param name="adjustmentCode">The exact text of the adjustment code that you want to chooose in the Adjustment Code select element</param>
        /// <param name="Rdo">The yes or no radio button element for INTNL or VOLUNTARY program adjustment</param>
        internal void AddProgramAdjustment(LSConstants.AdjustmentCodes adjustmentCode, IWebElement Rdo)
        {
            ClickAndWait(ProgramAdjustmentsTab);

            ClickAndWait(ProgAdjustTabAddAdjustLnk);

            switch (adjustmentCode)
            {
            case LSConstants.AdjustmentCodes.INTNL:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("INTNL");
                break;

            case LSConstants.AdjustmentCodes.VOLUNTARY:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("VOLUNTARY");
                break;
            }

            Thread.Sleep(1000);
            Rdo.Click();

            ClickAndWait(ProgAdjustTabAddAdjustFormAddAdjustBtn);
        }
Example #4
0
        /// <summary>
        /// Goes to the Add Adjustment tab if we are not already there, clicks the Add Adjustment link, chooses an Adjustment Code from the select
        /// element (this overload is for the ext1, ext2, ext2f, pra, per and temp adjustments). Then clicks the Add Adjustment button
        /// </summary>
        /// <param name="adjustmentCode">The exact text of the adjustment code that you want to chooose in the Adjustment Code select element</param>
        internal void AddProgramAdjustment(LSConstants.AdjustmentCodes adjustmentCode)
        {
            ClickAndWait(ProgramAdjustmentsTab);

            ClickAndWait(ProgAdjustTabAddAdjustLnk);

            switch (adjustmentCode)
            {
            case LSConstants.AdjustmentCodes.EXT1:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("EXT1");
                break;

            case LSConstants.AdjustmentCodes.EXT2:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("EXT2");
                break;

            case LSConstants.AdjustmentCodes.EXT2F:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("EXT2F");
                break;

            case LSConstants.AdjustmentCodes.PRA:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("PRA");
                break;

            case LSConstants.AdjustmentCodes.PER:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("PER");
                break;

            case LSConstants.AdjustmentCodes.TEMP:
                ProgAdjustTabAddAdjustFormAdjustCodeSelElem.SelectByText("TEMP");
                break;
            }

            ClickAndWait(ProgAdjustTabAddAdjustFormAddAdjustBtn);
            this.RefreshPage(true);
        }