package cz.moneta.test.dsl.ib.settings.ib.ediponents.activate;

import cz.moneta.test.dsl.ib.IbPageFlow;
import cz.moneta.test.dsl.ib.components.MainMenu;
import cz.moneta.test.dsl.ib.settings.ib.SettingsVerticalMenu;
import cz.moneta.test.harness.support.web.CheckElementPresent;
import cz.moneta.test.harness.support.web.Click;
import cz.moneta.test.harness.support.web.Wait;

import static cz.moneta.test.dsl.ib.settings.ib.ediponents.activate.RequestActivateDisponentPage.ACTIVATE_DISPONENT_STEP_1;
import static cz.moneta.test.dsl.ib.settings.ib.ediponents.activate.RequestActivateDisponentPage.REQUEST_ACTIVATE_TITLE;

@Wait({REQUEST_ACTIVATE_TITLE, ACTIVATE_DISPONENT_STEP_1})
public interface RequestActivateDisponentPage extends IbPageFlow<RequestActivateDisponentPage>, MainMenu, SettingsVerticalMenu {
    String REQUEST_ACTIVATE_TITLE = "//img[@alt='Aktivace disponenta']";
    String ACTIVATE_DISPONENT_STEP_1 = "//img[@src='images_new/top_step1.gif']";
    String NEW_DISPONENT_ACTIVATE_STATUS = "//td[contains(text(),'Nový stav disponenta')]/following-sibling::td[contains(text(),'Aktivní')]";
    String ACTIVATE_CONTINUE_BUTTON = "//img[@alt='Pokračovat']";

    @CheckElementPresent(NEW_DISPONENT_ACTIVATE_STATUS)
    @Click(value = ACTIVATE_CONTINUE_BUTTON)
    CheckActivateDisponentPage checkActiveStatusAndClickToContinue();
}