Previous  Next          Contents  Index  Navigation  Glossary  Library

Writing AR Transaction Type Extensions

Oracle Projects provides a template package and procedure that you use as the basis of your AR transaction type extension procedures. The name of the template package is pa_client_extn_inv_transfer. The name of the procedure is get_ar_trx_type.

Print out the following files before you begin writing AR transaction type extensions. The files are located in the Oracle Projects admin/sql directory.

PAXITRXB.pls AR Transaction Type Extension Package Body Template. This file contains the procedure that you can modify to implement the AR transaction type extension.
PAXITRXS.pls AR Transaction Type Extension Package Specification Template. If you create procedures outside the predefined procedure within the pa_client_extn_inv_transfer package, you must also modify this file to include those new procedures.

Suggestion: After you write the procedure, do not forget to compile it and store it in the database. See: Writing PL/SQL Procedures.

Package Procedure

pa_client_extn_inv_transfer.get_ar_trx_type

Table 1 - 123 lists the parameters that Oracle Projects provides for the AR transaction type extension.

Parameter Usage Type Description
p_project_id
 
IN NUMBER Identifier of the project to which the draft invoice number is attached.
p_draft_ invoice_num IN NUMBER The draft invoice number.
p_invoice_class IN VARCHAR2 The class of the invoice.
p_invoice_amount IN NUMBER Amount on the invoice.
p_ar_trx_type_id IN NUMBER Identifier of the AR Transaction Type to be used for the invoice. Oracle Projects uses its setup tables to determine the default AR transaction type and then passes it to the template.
x_ar_trx_type_id OUT NUMBER Identifier of the AR Transaction Type determined by the extension. After validation, Oracle Projects uses this transaction type to interface invoices to Oracle Receivables.
x_status OUT NUMBER Status of the procedure:
0 = successful execution
<0 = Oracle8 error
>0 = application error

Additional Information About Parameters

Using Invoice Class

The valid values of x_invoice_class are:

INVOICE regular invoice
CREDIT_MEMO crediting invoice
WRITE_OFF write-off invoice
CANCEL canceling invoice

Using Status

Use the x_status parameter to handle error conditions for your procedure. This parameter indicates the processing status of your extension as follows:

x_status = 0 The extension executed successfully.
x_status < 0 An Oracle8 error occurred and the process did not complete. Oracle Projects writes an error message to the process log file.
x_status > 0 An application error occurred. Oracle Projects writes a rejection reason to the PA_DISTRIBUTION_WARNINGS table. The invoice is not approved or released.


         Previous  Next          Contents  Index  Navigation  Glossary  Library