Previous  Next          Contents  Index  Navigation  Glossary  Library

Descriptive Flexfields in the Enter Receipts Window

You can define descriptive flexfields to record additional information in the Enter Receipts window in Oracle Web Employees. For example, you can define custom fields that appear for every expense item an employee enters in the Enter Receipts page. The values your employees enter in these additional fields you define are stored in the numbered ATTRIBUTE columns of the AP_EXPENSE_REPORT_LINES table. You can choose to import these ATTRIBUTE values into the AP_INVOICE_DISTRIBUTIONS table when you submit the Payables Invoice Import program. You can then use this information for custom reports or custom programs.

You can also define context-sensitive fields that appear only when the employee selects a particular expense type. For example, the employee is entering a receipt. When the employee enters Airfare as the expense type, custom fields appear for airline name, ticket number, and class of travel. When the employee enters Mileage as the expense type, custom fields appear for distance and the mileage rate. Note that context-sensitive fields can be based only on expense type.

Calculate Amount Button

In addition to storing additional information, for a given expense type you can add a Calculate Amount button to the set of custom fields you define through a descriptive flexfield definition. If you add your own custom calculation PL/SQL code in the apwdfcfb.pls file, then when your employees enter values in the custom fields and choose the Calculate Amount button, Web Employees will call your custom PL/SQL code. Web Employees will then perform calculations on the values that employees entered in the custom fields, and populate the Receipt Total field in the Enter Receipts window. For example, you can customize your Enter Receipts window so that during receipt entry when your employees enter Mileage as the expense type, a custom Distance field appears. The employee enters a value for this field and then chooses the Calculate Amount button. Your PL/SQL code will multiply the Distance value by mileage rate you have defined in either your custom PL/SQL code or in the descriptive flexfield default field, and automatically enter the result in the Receipt Total field.

If the reimbursement currency is different from the receipt currency, you can customize the PL/SQL code to populate the Receipt Total instead of the Total Amount. The Enter Receipts window will then calculate the receipt total in the reimbursement currency and enter that value in the Total Amount field.

You add a Calculate Amount button to the Enter Receipts window by enabling the Calculate Amount option for an expense item in the Expense Report Templates window in Payables.

Customizing Flexfield Routines

Web Employees provides four routines that can be customized to achieve the desired flexfield behavior. The four routines are included in the $AP_TOP/admin/sql/apwdfcfb.pls file. Web Employees provides a "hook" to each of these routines. You can edit them to provide custom, default values and poplist values, or to provide custom calculation and validation logic. They are:

Suggestion: To use custom data stored in the Oracle Applications database with the four provided procedures, you must register all new custom tables within Oracle Applications. See: Oracle Applications Developer's Guide.

Attention: You are responsible for the support and upgrade of the logic within the procedures that you write, which may be impacted by database or other changes between releases of the Oracle Applications.

Suggestion: Make a copy of all custom code and place it in a directory protected from upgrade. After an upgrade, if appropriate, reapply any custom code.

Defining Descriptive Flexfields for Expense Reporting

The Oracle Applications Flexfields Guide describes in detail how to define descriptive flexfields. The following discussion will provide some hints for defining descriptive flexfields for Expense reporting. Use this document in conjunction with the Oracle Applications Flexfields Guide.

To enable the Expense Report Line flexfield in the Enter Receipts window in Oracle Web Employees, enable the WebExpenses:Enable DescFlex profile option. Payables also uses the Expense Report Line flexfield for the Expense Reports window in Payables. If you want flexfields to appear in the Payables Expense Reports window but not in the Enter Receipts page in Web Employees, leave the segment Description null in the Segment window.

Prerequisites

   To define descriptive flexfields for the Enter Receipts window:

Attention: You must enter the Context Field Values Name exactly as you enter it in the Expense Item field of the Expense Report Templates window or the context-sensitive flexfield will not appear.

Attention: You must enter a value for the segment Description field, or the custom field will not appear on the Enter Receipts page. Segments with a null Description will appear only on the Payables Expense Reports window. Segments that are defined without a value in the Description field are not visible to Web Employees users, but if you define custom defaulting for a segment, the underlying database column may still be populated (these values will be visible in the Payables Expense Reports window).

Attention: When a segment is linked to a standard poplist, either Independent or Table validation must be used. If a segment is linked to a custom poplist, Table validation must be used.

Attention: To define custom error messages with any custom validation you use in the CUSTOMVALIDATEDFLEXVALUES procedure, pass the relevant error text to the procedure. You do not need to set up custom error messages in an Application Object Library (AOL) table for use with this procedure.

Suggestion: Before verifying that that the Descriptive Flexfield definition you created or extended works properly with Web Employees, verify its usage first within the Payables Expense Reports window. This may help identify errors in your Flexfield definition.


         Previous  Next          Contents  Index  Navigation  Glossary  Library