++ed by:

1 non-PAUSE user.

jonasbn

NAME

Workflow::Condition::GreedyOR

DESCRIPTION

Using nested conditions (See Workflow::Condition::Nested), this evaluates all given conditions, returning the count of successful checks. If none of the nested conditions are true, an exeption is thrown.

SYNOPSIS

In condition.xml:

    <condition name="cond1" ... />
    <condition name="cond2" ... />
    <condition name="cond3" ... />

    <condition name="count_approvals" class="Workflow::Condition::GreedyOR">
        <param name="condition" value="cond1" />
        <param name="condition" value="cond2" />
        <param name="condition" value="cond3" />
    </condition>

    <condition name="check_approvals" class="Workflow::Condition::CheckReturn">
        <param name="condition" value="count_approvals" />
        <!-- operator "ge" means: greater than or equal to -->
        <param name="operator"  value="ge" />
        <param name="argument"  value="$context->{approvals_needed}" />
    </condition>

In workflow.xml:

    <state name="CHECK_APPROVALS" autorun="yes">
        <action name="null_1" resulting_state="APPROVED">
            <condition name="check_approvals" />
        </action>
        <action name="null_2" resulting_state="REJECTED">
            <condition name="!check_approvals" />
        </action>
    </state>

PARAMETERS

The following parameters may be configured in the param entity of the condition in the XML configuration:

condition, conditionN

The condition parameter may be specified as either a list of repeating entries ∨ with a unique integer appended to the E<condition> string:

    <param name="condition" value="first_condition_to_test" />
    <param name="condition" value="second_condition_to_test" />

    <param name="condition1" value="first_condition_to_test" />
    <param name="condition2" value="second_condition_to_test" />

1 POD Error

The following errors were encountered while parsing the POD:

Around line 54:

Unknown E content in E<condition>