Home > Cloud Cruiser 3 > Administering > Managing customers > Customer activities and attributes > Setting up discounts and surcharges > Running a discount/surcharge job

Running a discount/surcharge job

Table of contents
No headers

A sample job file is located at < install_dir >/job_samples/discount_surcharge.xml . The job calls CCRecordCollectTasklet to collect adjustments to load for a given day based on discounts/surcharges defined in the system. Adjustments are applied at the same level in the overall account structure as the customer record associated with the discount/surcharge.

When selecting a Select Date for the job, be aware that for a discount/surcharge set as Daily , any run on any Select Date will pick up the discount/surcharge. When a discount is set to Monthly , only a run with a Select Date on the last day of the month will pick it up the discount/surcharge. Monthly adjustments are treated as period level adjustments and are only applied to accounts with a period ending on the job's Select Date.

NOTE: If after running the job, the discount/surcharge is incorrect, you can remove the discount/surcharge that has been applied by going to the Job Loads page and deleting the jobs that created the discount/surcharge.

More complex processing is possible by setting the targetLevel property to the proper level in your account structure to apply all adjustments. Discounts/surcharges can then be associated at a higher level in the structure to affect multiple accounts.

For example:

<bean class="com.cloudcruiser.batch.CCRecordCollectTasklet">
  <property name="active" value="true"/>
  <property name="feedName" value="discounts"/>
  <property name="collector">
    <bean class="com.cloudcruiser.batch.collect.CCDiscountSurchargeCollector">
      <property name="targetIdentifier" value="adjustmentName"/>
      <property name="targetLevel" value="Department"/>
    </bean>
  </property>
</bean>

The targetIdentifier property sets the name of an identifier to hold discount/surcharge name per adjustment record for drill down support. No identifier is added by default.

<property name="targetIdentifier" value="adjustmentName"/>

The targetLevel property sets an explicit account structure level at which all discount/surcharge adjustments are applied.

<property name="targetLevel" value="Department"/>

The targetLevel is defined as Department, and must be a valid account structure level defined in the application.

By default, adjustments are applied at the same level at which they were defined. This means that a $10 discount for a business unit would be applied once to that business unit. The level at which all adjustments are applied can be explicitly set here. For example, a $10 discount for a business unit could be applied to each department within the unit by setting the target level to 'Department'. The target level must be a valid account structure level defined in the application.

Last modified

Tags

This page has no custom tags.

Classifications

This page has no classifications.
© Copyright 2018 Hewlett Packard Enterprise Development LP