DBA Data[Home] [Help]

PACKAGE BODY: APPS.PA_COSTING_AUDIT_PKG

Source


1 Package Body Pa_Costing_Audit_Pkg as
2 /* $Header: PACSTAUB.pls 120.0 2005/05/29 12:36:42 appldev noship $ */
3 
4 /* Insert_Audit_Record inserts audit record into the PA_COSTING_AUDIT table
5    For FPM, the audit table is used to record the changes to the CWK implementation option -
6    'XFACE_CWK_TIMECARD_FLAG'.
7    The column values are as follows:
8           MODULE_CODE	'PAXSUDSI'
9           ACTIVITY_CODE	'XFACE_CWK_TC_FLAG_CHANGE'
10           ACTIVITY_DATE	Sysdate
11           DESCRIPTION	Import CWK timecards with PO integration change
12           PK01	        Org Id
13           REFERENCE1	Return Value of the API - Exists_Prj_Cwk_RbTC
14           REFERENCE2	Old Value of the flag
15           REFERENCE3	New value of the flag
16 */
17 
18   Procedure Insert_Audit_Record (
19    P_Module_Code              IN  VARCHAR2
20   ,P_Activity_Code            IN  VARCHAR2
21   ,P_Activity_Date            IN  DATE
22   ,P_Description              IN  VARCHAR2 Default Null
23   ,P_Pk01                     IN  VARCHAR2 Default Null
24   ,P_Pk02                     IN  VARCHAR2 Default Null
25   ,P_Pk03                     IN  VARCHAR2 Default Null
26   ,P_Reference1               IN  VARCHAR2 Default Null
27   ,P_Reference2               IN  VARCHAR2 Default Null
28   ,P_Reference3               IN  VARCHAR2 Default Null
29   ,P_Reference4               IN  VARCHAR2 Default Null
30   ,P_Reference5               IN  VARCHAR2 Default Null
31   ,P_Reference6               IN  VARCHAR2 Default Null
32   ,P_Reference7               IN  VARCHAR2 Default Null
33   ,P_Reference8               IN  VARCHAR2 Default Null
34   ,P_Reference9               IN  VARCHAR2 Default Null
35   ,P_Reference10              IN  VARCHAR2 Default Null
36   ,P_Creation_Date            IN  DATE
37   ,P_Created_By               IN  NUMBER
38   ,P_Last_Update_Date         IN  DATE
39   ,P_Last_Updated_By          IN  NUMBER
40   ,P_Last_Update_Login        IN  number
41   ,P_REQUEST_ID               IN  NUMBER Default Null
42   ,P_PROGRAM_APPLICATION_ID   IN  NUMBER Default Null
43   ,P_PROGRAM_ID               IN  NUMBER Default Null
44   ,P_PROGRAM_UPDATE_DATE      IN  DATE   Default Null)
45 
46   IS
47 
48    L_Description Varchar2(240);
49 
50  Begin
51 
52         If P_Activity_Code = 'XFACE_CWK_TC_FLAG_CHANGE' Then
53            L_Description := 'Import CWK timecards with PO integration change';
54         End If;
55 
56 	Insert INTO Pa_Costing_Audit (
57                Module_Code
58               ,Activity_Code
59               ,Activity_Date
60               ,Description
61               ,Pk01
62               ,Pk02
63               ,Pk03
64               ,Reference1
65               ,Reference2
66               ,Reference3
67               ,Reference4
68               ,Reference5
69               ,Reference6
70               ,Reference7
71               ,Reference8
72               ,Reference9
73               ,Reference10
74               ,Creation_Date
75               ,Created_By
76               ,Last_Update_Date
77               ,Last_Updated_By
78               ,Last_Update_Login
79               ,REQUEST_ID
80               ,PROGRAM_APPLICATION_ID
81               ,PROGRAM_ID
82               ,PROGRAM_UPDATE_DATE  )
83 	 values (
84                P_Module_Code
85               ,P_Activity_Code
86               ,P_Activity_Date
87               ,L_Description
88               ,P_Pk01
89               ,P_Pk02
90               ,P_Pk03
91               ,P_Reference1
92               ,P_Reference2
93               ,P_Reference3
94               ,P_Reference4
95               ,P_Reference5
96               ,P_Reference6
97               ,P_Reference7
98               ,P_Reference8
99               ,P_Reference9
100               ,P_Reference10
101               ,P_Creation_Date
102               ,P_Created_By
103               ,P_Last_Update_Date
104               ,P_Last_Updated_By
105               ,P_Last_Update_Login
106               ,P_REQUEST_ID
107               ,P_PROGRAM_APPLICATION_ID
108               ,P_PROGRAM_ID
109               ,P_PROGRAM_UPDATE_DATE
110           );
111 
112  Exception
113         When Others then
114                 Raise;
115 
116  End Insert_Audit_Record;
117 
118 END Pa_Costing_Audit_Pkg ;