Cloning Surcharges with Workflow Channels

You can clone Surcharges with Workflow Channels with some simple setup configurations. First, you must update the business rules on Surcharges. Next, you must configure a Workflow Channel to clone the Surcharge. This topic guides you through the configuration.

The surcharges clone when you click Generate Quote on the Pricing Console. If there is more than one Surcharge to clone, just add it as another item on the same Workflow Channel. Also, you may want to restrict Surcharges to clone for only certain Contract Types. If so, just configure additional conditions.

Note:  Instead of using workflow channels to clone surcharges, the R100 release introduced the option of setting a surcharge type to clone surcharges during the Quick Create of the Pricing Batch. See Surcharge Types and Creating Pricing for more information about using that method to clone surcharges.

Configure the Business Rules

In this step, you want to update Business Rules on Surcharges to run on the Quick Create and Default pipelines. You must configure the following rules: SetSurchargePricingBatchID, SetBillRate, UpdateProfitability, AddSurcharge, RecalPayPeriodSurcharge.

To configure the business rules:

  1. Go to System Admin AdvancedManage Rules.
    The Custom Logic Rules display.
  2. In More, search for Rule Type > Biz Logic, Dataform > Surcharge, to locate the methods (see screenshot).
  3. Open ( Jump) a Method Name, such as SetSurchargePricingBatchID.
    The Rule Details form opens.
  4. In Execution Pipeline, add Default and QuickCreate (if not present).
  5. Click Save.
  6. Repeat this procedure for all 5 rules.

Configure a Workflow Channel to clone the Surcharge

In this section, you will configure a Workflow Channel with Triggering Form = Pricing Batch and Execution Pipeline = QuickCreate. If there is more than one Surcharge to clone, add it as another item on the same Workflow Channel.

Step 1: Initial

In this step, we create the Channel descriptor. In the top section, we define the Channel name and the Dataform from which the Workflow will be triggered, as well as who owns the Channel. The Workflow Action configures the triggering action for the first workflow as well as what form or task will be generated.

To configure a Workflow Channel:

  1. Go to System Admin Workflow Channels.
    The Workflow Channels dashboard opens.
  2. Click Add to begin creating your new workflow.
    The Choose Workflow Triggering Type dialog opens with "What type of triggering will the new Workflow use?".
  3. Select Real Time.
  4. Complete the form fields.

Channel Name

Provide a unique Channel Name. For example, Surcharge Clone from Pricing Batch during Quick Create.

Triggering Form

Select Pricing Batch.

Execute On

Select Update.

Execution Pipeline

Select QuickCreate.

Workspace Template

Keep the default: All Templates.

Channel Description

Provide a brief description of this channel.

Channel Owner

Defaults to the current user. Set it to the owner of this process.

Workflow Action This section is dedicated to the primary triggering condition for the channel.
No Primary Trigger Select this option.

Triggered Form

Select Surcharge.

The wizard progresses to Step 2 Content.

Step 2: Content

Information entered into the fields is copied to each cloned object created by this channel.

Let the Business Rules manage the default values on the Surcharge. Ensure that only the Surcharge Type fields are visible on this step. If other fields are exposed, they will be cloned as shown and override the default values usually handled by the Business Rules. To remove the visibility of these extra fields, on Field Properties, set the fields as not triggerable.

  1. In Item Name, enter a brief description of what this workflow does.
  2. In Surcharge Type, click the link None.
    The Surcharge Type Options dialog box opens.
  3. Select Admin Workspace.
  4. In Record, select an appropriate Surcharge, such as Client Setup.
  5. Click Ok.
    You are returned to the wizard.
  6. Click Next.

Step 3: Notifications

  • Click Next. You can skip this step.

Step 4 Conditions

This is where you add conditions. A Workflow Channel requires at least one condition. A Pricing Batch is always added with the Status set to New, so this is a safe assumption. This is where you configure Pricing Batch = New and any other additional conditions that may be applicable such as Contract Type = X.

  1. Select Only trigger this workflow once.
  2. Select Publish.
  3. Click Add.
    A row opens to add a condition.

Source

Select Pricing Batch.

Field

Select Status (luBatchStatus).

Operator

Select Equals.

Value

Select New.

Label

Leave empty or provide a Label if you need to use Condition Expression.

  1. Click Finish.

Note:  In Step 1, we do not use a Primary Trigger Condition because a field must be dirty. A Stored Procedure creates the Pricing Batch outside of Biz Logic; therefore, it is not dirty. After created, the Pricing Batch is then saved back through the Dataform Pipeline as an Update and run through Biz Logic. When this happens, the Batch Status is not evaluated as dirty.

  1. Publish and test your workflow.