package cz.moneta.test.dsl.util.task.auto.smartauto.application;

import cz.moneta.test.dsl.Harness;
import cz.moneta.test.dsl.auto.smartauto.QueuePage;
import cz.moneta.test.dsl.auto.smartauto.VehiclePage;

import java.util.function.Function;

public class ApplicationTasks {

    private final Harness harness;

    public ApplicationTasks(Harness harness) {
        this.harness = harness;
    }

    public Function<VehiclePage, QueuePage> sendApplication() {
        return start -> start.clickToQueue()
                .clickQueueAccept()
                .checkHeadingSendApplication();
    }

    public Function<VehiclePage, QueuePage> sendSubsidyApplication() {
        return start -> start.clickToQueue()
                .clickSubsidyAcceptButton()
                .clickQueueAccept()
                .checkHeadingSendApplication();
    }

    public Function<VehiclePage, QueuePage> sendApplicationPGRLF() {
        return start -> start.clickToQueue()
                .clickAcceptSubsidyCheckbox()
                .clickAcceptPGRLF()
                .scrollToAccept()
                .clickQueueAccept()
                .checkHeadingSendApplication();
    }
}
