1 PACKAGE BODY AR_CUSTOM_PARAMS_HOOK_PKG AS
2 /*$Header: ARCUSPARB.pls 120.1 2010/08/03 20:19:25 mraymond noship $*/
3
4 PG_DEBUG VARCHAR2(1) := NVL(FND_PROFILE.value('AFLOG_ENABLED'), 'N');
5
6 /*===========================================================================+
7 * PROCEDURE *
8 * LOG() *
9 * DESCRIPTION *
10 * Writes the message to debug log. *
11 * SCOPE - LOCAL *
12 * ARGUMENTS *
13 * IN : p_msg - Message *
14 * OUT : NONE *
15 * RETURNS NONE *
16 * ALGORITHM *
17 * *
18 * NOTES - *
19 * *
20 * MODIFICATION HISTORY - 23/02/2010 - Created by RVIRIYAL *
21 * *
22 +===========================================================================*/
23 PROCEDURE log(p_msg IN VARCHAR2) IS
24 BEGIN
25 arp_standard.debug('ARCUSPARB' || p_msg || ' : ' || TO_CHAR(SYSDATE,'DD/MM/YY hh:mi:ss'));
26 END log;
27
28 /*===========================================================================+
29 * PROCEDURE *
30 * populateCAOwnerAttributes *
31 * DESCRIPTION *
32 * This procedure is invoked from ar_cao_assign_pkg before calling the *
33 * rules engine. The purpose of the procedure is to calculate the *
34 * attribute columns. Attribute columns are treated as the param value *
35 * based on which the custom param rules are evaluated. *
36 * *
37 * SCOPE - PUBLIC *
38 * ARGUMENTS - NONE *
39 * *
40 * RETURNS NONE *
41 * NOTES - *
42 * MODIFICATION HISTORY - 23/02/2010 - Created by RVIRIYAL *
43 * *
44 +===========================================================================*/
45
46 PROCEDURE populateCAOwnerAttributes AS
47 BEGIN
48 IF PG_DEBUG IN ('Y', 'C') THEN
49 log('AR_CUSTOM_PARAMS_HOOK_PKG.populateCAOwnerAttributes()+');
50 END IF;
51 /*
52 User needs to write code here to populate Attribute columns
53 */
54 IF PG_DEBUG IN ('Y', 'C') THEN
55 log('AR_CUSTOM_PARAMS_HOOK_PKG.populateCAOwnerAttributes()-');
56 END IF;
57
58
59 END;
60
61 /*===========================================================================+
62 * PROCEDURE *
63 * populateContingencyAttributes *
64 * DESCRIPTION *
65 * This procedure is invoked from ar_revenue_management_pvt before calling *
66 * rules engine. The purpose of the procedure is to calculate the *
67 * attribute columns. Attribute columns are treated as the param value *
68 * based on which the custom param rules are evaluated. *
69 * *
70 * SCOPE - PUBLIC *
71 * ARGUMENTS - p_source IN VARCHAR2(10) - values OM and ALL (default) *
72 * *
73 * RETURNS NONE *
74 * NOTES - *
75 * MODIFICATION HISTORY - 23/02/2010 - Created by RVIRIYAL *
76 * *
77 +===========================================================================*/
78
79 PROCEDURE populateContingencyAttributes(
80 p_source IN VARCHAR2 DEFAULT 'ALL') AS
81 BEGIN
82 IF PG_DEBUG IN ('Y', 'C') THEN
83 log('AR_CUSTOM_PARAMS_HOOK_PKG.populateContingencyAttributes()+');
84 END IF;
85
86 /*
87 User needs to write code here to populate Attribute columns.
88
89 IF p_source = 'OM', then source_line_id will be populated
90 with the line_id of the order in OM. Otherwise, source_line_id
91 will be the customer_trx_line_id of the invoice line in AR.
92
93 The columns you must set are ar_rdr_parameters_gt.attribute1 -
94 attribute10. They must match the names of the columns paired with
95 the custom parameters you defined.
96 */
97
98 IF PG_DEBUG IN ('Y', 'C') THEN
99 log('AR_CUSTOM_PARAMS_HOOK_PKG.populateContingencyAttributes()-');
100 END IF;
101
102 END;
103
104
105 END AR_CUSTOM_PARAMS_HOOK_PKG;