1 PACKAGE AP_WEB_DISC_PKG AS
2 /* $Header: apwdiscs.pls 120.9 2006/06/27 16:54:28 nammishr ship $ */
3
4 /* PROCEDURE ValidateDiscReport(UploadArea LONG,
5 AP_WEB_FULLNAME VARCHAR2 default NULL,
6 AP_WEB_EMPID VARCHAR2 default NULL); */
7
8 TYPE MiniString_Array IS TABLE OF VARCHAR2(25)
9 INDEX BY BINARY_INTEGER;
10 TYPE MedString_Array IS TABLE OF VARCHAR2(80)
11 INDEX BY BINARY_INTEGER;
12 TYPE BigString_Array IS TABLE OF VARCHAR2(240)
13 INDEX BY BINARY_INTEGER;
14 TYPE Number_Array IS TABLE OF NUMBER
15 INDEX BY BINARY_INTEGER;
16 TYPE Boolean_Array IS TABLE OF BOOLEAN
17 INDEX BY BINARY_INTEGER;
18 TYPE PromptsCursor IS REF CURSOR;
19
20
21
22 TYPE PROMPT_REC IS RECORD (
23 -- chiho:1170729:modify the data type:
24 prompt_text fnd_descr_flex_col_usage_vl.form_left_prompt%TYPE := '',
25 prompt_code fnd_descr_flex_col_usage_vl.end_user_column_name%TYPE := '',
26
27 required varchar2(2) := 'N',
28 duplicate varchar2(1) := 'N',
29 global_flag boolean := false);
30
31 -- Indicates the type of error encountered when parsing the spreadsheet
32 C_SetupError CONSTANT VARCHAR2(1) := 'S';
33 C_DataError CONSTANT VARCHAR2(1) := 'D';
34 C_Warning CONSTANT VARCHAR2(1) :='W';
35 C_NoError CONSTANT VARCHAR2(1) :=' ';
36
37 -- Indicates whether this is being run with the old tech stack (PLSQL)
38 -- or the new tech stack (OA Framework)
39 -- Used in ParseExpReport
40 C_OldStack CONSTANT VARCHAR2(1):= 'O';
41 C_NewStack CONSTANT VARCHAR2(1) := 'N';
42
43 TYPE DISC_PROMPTS_TABLE IS TABLE OF PROMPT_REC
44 INDEX BY BINARY_INTEGER;
45
46 TYPE RECEIPT_ERROR_REC IS RECORD (
47 error_text long := '',
48 error_fields varchar2(100) := '' );
49
50 TYPE RECEIPT_ERROR_STACK IS TABLE OF RECEIPT_ERROR_REC
51 INDEX BY BINARY_INTEGER;
52
53 TYPE SETUP_ERROR_STACK IS TABLE OF VARCHAR2(2000)
54 INDEX BY BINARY_INTEGER;
55
56
57 -- ParseExpReport to be accessed from AP_WEB_OA_DISC_PKG
58
59 PROCEDURE ParseExpReport(
60 p_user_id IN NUMBER, -- 2242176, fnd user id
61 p_exp in LONG,
62 p_table IN OUT NOCOPY disc_prompts_table,
63 p_costcenter in VARCHAR2,
64 P_IsSessionProjectEnabled IN VARCHAR2,
65 p_report_header_info IN OUT NOCOPY AP_WEB_DFLEX_PKG.ExpReportHeaderRec,
66 p_report_lines_info OUT NOCOPY AP_WEB_DFLEX_PKG.ExpReportLines_A,
67 Custom1_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
68 Custom2_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
69 Custom3_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
70 Custom4_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
71 Custom5_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
72 Custom6_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
73 Custom7_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
74 Custom8_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
75 Custom9_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
76 Custom10_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
77 Custom11_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
78 Custom12_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
79 Custom13_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
80 Custom14_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
81 Custom15_Array OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
82 P_DataDefaultedUpdateable OUT NOCOPY BOOLEAN,
83 p_errors OUT NOCOPY AP_WEB_UTILITIES_PKG.expError,
84 p_receipt_errors OUT NOCOPY AP_WEB_UTILITIES_PKG.receipt_error_stack,
85 p_error_type OUT NOCOPY VARCHAR2,
86 p_techstack IN VARCHAR2 DEFAULT C_OldStack -- Old or new tech stack
87 );
88
89 -- Added ValidateExpenseLines to be accessed from AP_WEB_OA_DISC_PKG
90
91 PROCEDURE discValidateExpLines(
92 p_report_header_info IN OUT NOCOPY AP_WEB_DFLEX_PKG.ExpReportHeaderRec,
93 p_report_lines_info IN OUT NOCOPY AP_WEB_DFLEX_PKG.ExpReportLines_A,
94 p_custom1_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
95 p_custom2_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
96 p_custom3_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
97 p_custom4_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
98 p_custom5_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
99 p_custom6_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
100 p_custom7_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
101 p_custom8_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
102 p_custom9_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
103 p_custom10_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
104 p_custom11_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
105 p_custom12_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
106 p_custom13_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
107 p_custom14_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
108 p_custom15_array IN OUT NOCOPY AP_WEB_DFLEX_PKG.CustomFields_A,
109 p_has_core_field_errors OUT NOCOPY BOOLEAN,
110 p_has_custom_field_errors OUT NOCOPY BOOLEAN,
111 p_receipts_errors OUT NOCOPY AP_WEB_UTILITIES_PKG.receipt_error_stack,
112 p_receipts_with_errors_count OUT NOCOPY BINARY_INTEGER,
113 p_IsSessionProjectEnabled IN VARCHAR2,
114 p_calculate_receipt_index IN BINARY_INTEGER DEFAULT NULL,
115 p_DataDefaultedUpdateable IN OUT NOCOPY BOOLEAN);
116
117 PROCEDURE AP_WEB_INIT_PROMPTS_ARRAY(p_user_id in number, -- 2242176
118 p_table in out nocopy DISC_PROMPTS_TABLE,
119 p_format_errors in out nocopy setup_error_stack);
120
121 PROCEDURE InverseRates(p_receipts IN OUT NOCOPY AP_WEB_DFLEX_PKG.ExpReportLines_A);
122
123 PROCEDURE ValidateForeignCurrencies(
124 p_report_header_info IN AP_WEB_DFLEX_PKG.ExpReportHeaderRec,
125 p_report_lines_info IN AP_WEB_DFLEX_PKG.ExpReportLines_A,
126 p_receipts_errors IN OUT NOCOPY AP_WEB_UTILITIES_PKG.receipt_error_stack);
127
128 ------------------------------------------------------------------------------------------------
129 -- Name: GetAKRegionPromptsCursor
130 -- Desc: get the cursor of the prompts for the given AK region code
131 -- Params: p_reg_code - the given AK region code
132 -- p_prompts_cursor - the returned cursor
133 -- Returns: true - succeeded
134 -- false - failed
135 --------------------------------------------------------------------------------
136 FUNCTION GetAKRegionPromptsCursor(
137 p_reg_code IN AK_REGION_ITEMS_VL.region_code%TYPE,
138 p_prompts_cursor OUT NOCOPY PromptsCursor)
139 RETURN BOOLEAN;
140 -----------------------------------------------------------------------------------------------
141
142 PROCEDURE getPrompts( c_region_application_id in number,
143 c_region_code in varchar2,
144 c_title out nocopy AK_REGIONS_VL.NAME%TYPE,
145 c_prompts out nocopy AP_WEB_UTILITIES_PKG.prompts_table);
146
147
148 END AP_WEB_DISC_PKG;
149