package cz.moneta.test.dsl.forte.components;

import cz.moneta.test.dsl.forte.pages.contracts.*;
import cz.moneta.test.harness.support.web.Builder;
import cz.moneta.test.harness.support.web.Click;
import cz.moneta.test.harness.support.web.Wait;

import static cz.moneta.test.dsl.forte.components.BranchesMenu.CONTROL_MENU_UL;

@Wait(CONTROL_MENU_UL)
public interface ContractsMenu extends RoleSelection<ContractsMainPage>, Builder {
    String CONTROL_MENU_UL = LEFT_PANEL + "//ul[@class='control menu']";
    String PAYMENTS_LIST_LINK = CONTROL_MENU_UL + "//a[@href='/contracts/payments/']";
    String FIND_CONTRACTS_LINK = CONTROL_MENU_UL + "//a[@href='/contracts/find/']";

    String ENUMS_CDR_ACCOUNTS = CONTROL_MENU_UL + "//a[@href='/contracts/cdraccount/']";
    String ENUMS_CURRENCY = CONTROL_MENU_UL + "//a[@href='/contracts/currency/']";
    String ENUMS_COST_CENTERS = CONTROL_MENU_UL + "//a[@href='/contracts/costcenter/']";
    String ENUMS_DPH_RATES = CONTROL_MENU_UL + "//a[@href='/contracts/dph/']";
    String ENUMS_PAYMENT_CATEGORIES = CONTROL_MENU_UL + "//a[@href='/contracts/paymenttype/']";
    String ENUMS_PAYMENT_TERMS = CONTROL_MENU_UL + "//a[@href='/contracts/paymenttermtype/']";
    String ENUMS_VALORIZATION = CONTROL_MENU_UL + "//a[@href='/contracts/valorizationtype/']";
    String ENUMS_ACCOUNTING_BRIDGE = CONTROL_MENU_UL + "//a[@href='/contracts/bridge/']";
    String ENUMS_CHANGE_TYPES = CONTROL_MENU_UL + "//a[@href='/contracts/changetype/']";
    String ENUMS_DISCOUNT_RATES = CONTROL_MENU_UL + "//a[@href='/contracts/discountrate/']";
    String ENUMS_BLE = CONTROL_MENU_UL + "//a[@href='/contracts/bletype/']";

    @Click(PAYMENTS_LIST_LINK)
    ListPaymentsPage clickPaymentsList();

    @Click(FIND_CONTRACTS_LINK)
    FindContractsPage clickFindContracts();

    @Click(ENUMS_CDR_ACCOUNTS)
    ContractsUniversalEnumInterface clickEnumsCdrAccounts();

    @Click(ENUMS_CURRENCY)
    ContractsUniversalEnumInterface clickEnumsCurrency();

    @Click(ENUMS_COST_CENTERS)
    ContractsUniversalEnumInterface clickEnumsCostCenters();

    @Click(ENUMS_DPH_RATES)
    ContractsUniversalEnumInterface clickEnumsDphRates();

    @Click(ENUMS_PAYMENT_CATEGORIES)
    ContractsUniversalEnumInterface clickEnumsPaymentCategories();

    @Click(ENUMS_PAYMENT_TERMS)
    ContractsUniversalEnumInterface clickEnumsPaymentTerms();

    @Click(ENUMS_VALORIZATION)
    ContractsUniversalEnumInterface clickEnumsValorization();

    @Click(ENUMS_ACCOUNTING_BRIDGE)
    ContractsUniversalEnumInterface clickEnumsAccountingBridge();

    @Click(ENUMS_CHANGE_TYPES)
    ContractsUniversalEnumInterface clickEnumsChangeTypes();

    @Click(ENUMS_DISCOUNT_RATES)
    ContractsUniversalEnumInterface clickEnumsDiscountRates();

    @Click(ENUMS_BLE)
    ContractsUniversalEnumInterface clickEnumsBLE();

}