1 Package hr_process_sit_ss AUTHID CURRENT_USER as
2 /* $Header: hrsitwrs.pkh 115.8 2002/12/10 01:03:58 lma noship $ */
3
4
5 gv_wf_review_region_item constant wf_item_attributes.name%type
6 := 'HR_REVIEW_REGION_ITEM';
7
8
9 ---- Declare a row of pereanalysis_criteria ----------------------------------
10 TYPE per_analysis_criteria_rec IS RECORD(
11 segment1 per_analysis_criteria.segment1%TYPE,
12 segment2 per_analysis_criteria.segment2%TYPE,
13 segment3 per_analysis_criteria.segment3%TYPE,
14 segment4 per_analysis_criteria.segment4%TYPE,
15 segment5 per_analysis_criteria.segment5%TYPE,
16 segment6 per_analysis_criteria.segment6%TYPE,
17 segment7 per_analysis_criteria.segment7%TYPE,
18 segment8 per_analysis_criteria.segment8%TYPE,
19 segment9 per_analysis_criteria.segment9%TYPE,
20 segment10 per_analysis_criteria.segment10%TYPE,
21 segment11 per_analysis_criteria.segment11%TYPE,
22 segment12 per_analysis_criteria.segment12%TYPE,
23 segment13 per_analysis_criteria.segment13%TYPE,
24 segment14 per_analysis_criteria.segment14%TYPE,
25 segment15 per_analysis_criteria.segment15%TYPE,
26 segment16 per_analysis_criteria.segment16%TYPE,
27 segment17 per_analysis_criteria.segment17%TYPE,
28 segment18 per_analysis_criteria.segment18%TYPE,
29 segment19 per_analysis_criteria.segment19%TYPE,
30 segment20 per_analysis_criteria.segment20%TYPE,
31 segment21 per_analysis_criteria.segment21%TYPE,
32 segment22 per_analysis_criteria.segment22%TYPE,
33 segment23 per_analysis_criteria.segment23%TYPE,
34 segment24 per_analysis_criteria.segment24%TYPE,
35 segment25 per_analysis_criteria.segment25%TYPE,
36 segment26 per_analysis_criteria.segment26%TYPE,
37 segment27 per_analysis_criteria.segment27%TYPE,
38 segment28 per_analysis_criteria.segment28%TYPE,
39 segment29 per_analysis_criteria.segment29%TYPE,
40 segment30 per_analysis_criteria.segment30%TYPE);
41 --
42 -- ----------------------------------------------------------------------------
43 -- |----------------------------< insert_sit >--------------------------------|
44 -- ----------------------------------------------------------------------------
45 -- Wrapper Package for API hr_process_sit_ss.
46 --
47 PROCEDURE save_transaction_data
48 (p_person_id in number
49 ,p_login_person_id in number
50 ,p_person_analysis_id in number
51 ,p_pea_object_version_number in number
52 ,p_effective_date in date default null
53 ,p_date_from in date default null
54 ,p_date_to in date default null
55 ,p_analysis_criteria_id in number
56 ,p_old_analysis_criteria_id in number
57 ,p_business_group_id in number
58 ,p_id_flex_num in number
59 ,p_structure_code in varchar2
60 ,p_structure_name in varchar2
61 ,p_item_type in varchar2
62 ,p_item_key in varchar2
63 ,p_activity_id in number
64 ,p_action in varchar2
65 ,p_flow_mode in varchar2 default null
66 ,p_transaction_step_id out nocopy number
67 ,p_error_message out nocopy long
68 ,p_attribute_category in varchar2
69 ,p_attribute1 in varchar2
70 ,p_attribute2 in varchar2
71 ,p_attribute3 in varchar2
72 ,p_attribute4 in varchar2
73 ,p_attribute5 in varchar2
74 ,p_attribute6 in varchar2
75 ,p_attribute7 in varchar2
76 ,p_attribute8 in varchar2
77 ,p_attribute9 in varchar2
78 ,p_attribute10 in varchar2
79 ,p_attribute11 in varchar2
80 ,p_attribute12 in varchar2
81 ,p_attribute13 in varchar2
82 ,p_attribute14 in varchar2
83 ,p_attribute15 in varchar2
84 ,p_attribute16 in varchar2
85 ,p_attribute17 in varchar2
86 ,p_attribute18 in varchar2
87 ,p_attribute19 in varchar2
88 ,p_attribute20 in varchar2
89 );
90
91 -- Description:
92 -- This API creates a special information record for a person identified by
93 -- person_id.
94 --
95 --
96 -- Prerequisites:
97 -- A person identified by person_id must exist in per_people_f.
98 -- Special Information Type identified by id_flex_num must be defined.
99 --
100 --
101 -- In Parameters:
102 -- Name Reqd Type Description
103 -- p_validate No number If 0, the database remains
104 -- unchanged. If 1 then the
105 -- special information data will
106 -- be created.
107 -- p_person_id Yes number ID person
108 -- p_business_group_id Yes number business group id
109 -- p_id_flex_num Yes number id flex number
110 -- p_structure_code Yes varchar2 structure code
111 -- p_structure_name Yes varchar2 structure name
112 -- p_effective_date Yes date The effective date for this
113 -- insert.
114 -- p_analysis_criteria_id Yes number If p_validate is false, uniquely
115 -- identifies the combination of
116 -- segments passed. If p_validate
117 -- is true, set to null.
118 -- p_date_from No date date from
119 -- p_date_to No date date to
120 --
121 -- Post Success:
122 -- A special information record is inserted and the following OUT parameters
123 -- are set.
124 --
125 -- Name Type Description
126 -- p_person_analysis_id number If p_validate is false, uniquely
127 -- identifies the person analysis
128 -- created. if p_validate is true,
129 -- set to null.
130 -- p_pea_object_version_number number If p_validate is false, set to
131 -- the version number of the
132 -- person analysis created. If
133 -- p_validate is true, set to null.
134 --
135 --
136 -- Post Failure:
137 -- API does not insert a special information record and raises an error.
138 --
139 -- Access Status:
140 -- Public.
141 --
142 -- {End Of Comments}
143 --
144 --
145 procedure insert_sit
146 (p_validate in number default 1
147 ,p_person_id in number
148 ,p_business_group_id in number
149 ,p_id_flex_num in number
150 ,p_effective_date in date
151 ,p_date_from in date default null
152 ,p_date_to in date default null
153 ,p_analysis_criteria_id in number
154 ,p_person_analysis_id out nocopy number
155 ,p_pea_object_version_number out nocopy number
156 ,p_login_person_id in number
157 ,p_item_type in varchar2
158 ,p_item_key in varchar2
159 ,p_activity_id in number
160 ,p_action in varchar2
161 ,p_save_mode in varchar2 default null
162 ,p_error_message out nocopy long
163 ,p_attribute_category in varchar2
164 ,p_attribute1 in varchar2
165 ,p_attribute2 in varchar2
166 ,p_attribute3 in varchar2
167 ,p_attribute4 in varchar2
168 ,p_attribute5 in varchar2
169 ,p_attribute6 in varchar2
170 ,p_attribute7 in varchar2
171 ,p_attribute8 in varchar2
172 ,p_attribute9 in varchar2
173 ,p_attribute10 in varchar2
174 ,p_attribute11 in varchar2
175 ,p_attribute12 in varchar2
176 ,p_attribute13 in varchar2
177 ,p_attribute14 in varchar2
178 ,p_attribute15 in varchar2
179 ,p_attribute16 in varchar2
180 ,p_attribute17 in varchar2
181 ,p_attribute18 in varchar2
182 ,p_attribute19 in varchar2
183 ,p_attribute20 in varchar2
184 );
185 --
186 --
187 -- ----------------------------------------------------------------------------
188 -- |--------------------------< update_sit >----------------------------------|
189 -- ----------------------------------------------------------------------------
190 -- {Start Of Comments}
191 --
192 -- Description:
193 -- This API updates a special information record for a person identified by
194 -- person_id.
195 --
196 --
197 -- Prerequisites:
198 -- A person identified by person_id must exist in per_people_f.
199 -- Special Information Type identified by id_flex_num must be defined.
200 --
201 --
202 -- In Parameters:
203 -- Name Reqd Type Description
204 -- p_validate No number If 0, the database remains
205 -- unchanged. If 1 then the
206 -- special information data will
207 -- be created.
208 -- p_person_analysis_id in number person analysis id
209 -- p_date_from in date date from
210 -- p_date_to in date date to
211 -- p_analysis_criteria_id in number If p_validate is false, uniquely
212 -- identifies the combination of
213 -- segments passed. If p_validate
214 -- is true, set to null.
215 --
216 -- Post Success:
217 -- A special information record is updated and the following OUT parameters
218 -- are set.
219 --
220 -- Name Type Description
221 -- p_pea_object_version_number number If p_validate is false, set to
222 -- the version number of the
223 -- person analysis updated. If
224 -- p_validate is true, set to null.
225 --
226 --
227 -- Post Failure:
228 -- API does not update a special information record and raises an error.
229 --
230 -- Access Status:
231 -- Public.
232 --
233 -- {End Of Comments}
234 --
235 --
236 procedure update_sit
237 (p_validate in number default 1
238 ,p_person_id in number
239 ,p_person_analysis_id in number
240 ,p_pea_object_version_number in out nocopy number
241 ,p_date_from in date default hr_api.g_date
242 ,p_date_to in date default hr_api.g_date
243 ,p_analysis_criteria_id in number
244 ,p_login_person_id in number
245 ,p_business_group_id in number
246 ,p_id_flex_num in number
247 ,p_item_type in varchar2
248 ,p_item_key in varchar2
249 ,p_activity_id in number
250 ,p_action in varchar2
251 ,p_save_mode in varchar2 default null
252 ,p_error_message out nocopy long
253 ,p_attribute_category in varchar2
254 ,p_attribute1 in varchar2
255 ,p_attribute2 in varchar2
256 ,p_attribute3 in varchar2
257 ,p_attribute4 in varchar2
258 ,p_attribute5 in varchar2
259 ,p_attribute6 in varchar2
260 ,p_attribute7 in varchar2
261 ,p_attribute8 in varchar2
262 ,p_attribute9 in varchar2
263 ,p_attribute10 in varchar2
264 ,p_attribute11 in varchar2
265 ,p_attribute12 in varchar2
266 ,p_attribute13 in varchar2
267 ,p_attribute14 in varchar2
268 ,p_attribute15 in varchar2
269 ,p_attribute16 in varchar2
270 ,p_attribute17 in varchar2
271 ,p_attribute18 in varchar2
272 ,p_attribute19 in varchar2
273 ,p_attribute20 in varchar2
274 );
275 --
276 -- ----------------------------------------------------------------------------
277 -- |----------------------------< delete_sit >------------------------------|
278 -- ----------------------------------------------------------------------------
279 -- {Start Of Comments}
280 --
281 -- Description:
282 -- This API deletes a SIT record on the PER_PERSON_ANALYSES table.
283 --
284 -- Prerequisites:
285 -- The SIT specified by p_perosn_analysis_id and p_pea_object_version_number
286 -- must exist.
287 --
288 -- In Parameters:
289 -- Name Reqd Type Description
290 -- p_validate N number If 0 , the database
291 -- remains unchanged. If 1
292 -- then the employee analysis row will
293 -- be deleted from the database.
294 -- p_person_analysis_id Y number Person Analysis id.
295 -- p_pea_object_version_number Y number Version number of the SIT
296 -- record on PER_PERSON_ANALYSES
297 -- not that of PER_ANALYSIS_CRITERIA
298 -- Post Success:
299 -- The API deletes the SIT record.
300 --
301 -- Post Failure:
302 -- The API does not delete the SIT and raises an error.
303 --
304 -- Access Status:
305 -- Public.
306 --
307 -- {End Of Comments}
308 --
309 procedure delete_sit
310 (p_validate in number default 1
311 ,p_person_id in number
312 ,p_person_analysis_id in number
313 ,p_pea_object_version_number in number
314 ,p_analysis_criteria_id in number
315 ,p_login_person_id in number
316 ,p_business_group_id in number
317 ,p_id_flex_num in number
318 ,p_item_type in varchar2
319 ,p_item_key in varchar2
320 ,p_activity_id in number
321 ,p_action in varchar2
322 ,p_save_mode in varchar2 default null
323 ,p_error_message out nocopy long
324 );
325 --
326
327 --
328 -- ----------------------------------------------------------------------------
329 -- |----------------------< get_segments_from_ccid >--------------------------|
330 -- ----------------------------------------------------------------------------
331 -- Wrapper Package for API hr_process_sit_ss.
332 --
333 -- Description:
334 -- This Function gets the segments info for the given per_anlaysis_criteria_id from
335 -- per_analysis_criteria table and returns as record type.
336 --
337 --
338 -- Prerequisites:
339 -- A person identified by person_id must exist in per_people_f.
340 -- Special Information Type identified by id_flex_num must be defined.
341 --
342 --
343 -- In Parameters:
344 -- Name Reqd Type Description
345 -- p_analysis_criteria_id Yes number anlaysis_criteria_id
346 --
347 -- Returns:
348 -- per_analysis_criteria_rec of per_analysis_criteria rec type.
349 -- --------------------------------------------------------------------------
350
351 FUNCTION get_segments_from_ccid(p_analysis_criteria_id IN NUMBER)
352 RETURN per_analysis_criteria_rec ;
353 --
354 -- ----------------------------------------------------------------------------
355 -- |-----------------------< get_transaction_data >---------------------------|
356 -- Wrapper Package for API hr_process_sit_ss.
357 --
358 -- Description:
359 -- This Function gets the transaction data for the given step id.
360 -- ----------------------------------------------------------------------------
361 PROCEDURE get_transaction_data
362 (p_transaction_step_id in number
363 ,p_person_id out nocopy number
364 ,p_login_person_id out nocopy number
365 ,p_person_analysis_id out nocopy number
366 ,p_pea_object_version_number out nocopy number
367 ,p_effective_date out nocopy date
368 ,p_date_from out nocopy date
369 ,p_date_to out nocopy date
370 ,p_analysis_criteria_id out nocopy number
371 ,p_old_analysis_criteria_id out nocopy number
372 ,p_business_group_id out nocopy number
373 ,p_id_flex_num out nocopy number
374 ,p_structure_code out nocopy varchar2
375 ,p_structure_name out nocopy varchar2
376 ,p_action out nocopy varchar2
377 ,p_error_message out nocopy long
378 ,p_attribute_category out nocopy varchar2
379 ,p_attribute1 out nocopy varchar2
380 ,p_attribute2 out nocopy varchar2
381 ,p_attribute3 out nocopy varchar2
382 ,p_attribute4 out nocopy varchar2
383 ,p_attribute5 out nocopy varchar2
384 ,p_attribute6 out nocopy varchar2
385 ,p_attribute7 out nocopy varchar2
386 ,p_attribute8 out nocopy varchar2
387 ,p_attribute9 out nocopy varchar2
388 ,p_attribute10 out nocopy varchar2
389 ,p_attribute11 out nocopy varchar2
390 ,p_attribute12 out nocopy varchar2
391 ,p_attribute13 out nocopy varchar2
392 ,p_attribute14 out nocopy varchar2
393 ,p_attribute15 out nocopy varchar2
394 ,p_attribute16 out nocopy varchar2
395 ,p_attribute17 out nocopy varchar2
396 ,p_attribute18 out nocopy varchar2
397 ,p_attribute19 out nocopy varchar2
398 ,p_attribute20 out nocopy varchar2
399 );
400
401 PROCEDURE process_api
402 (p_validate IN BOOLEAN DEFAULT FALSE
403 ,p_transaction_step_id IN NUMBER DEFAULT NULL
404 ,p_effective_date IN VARCHAR2 DEFAULT null
405 );
406
407
408 -- ----------------------------------------------------------------------------
409 -- |-----------------------< del_transaction_data >---------------------------|
410 -- Wrapper Package for API hr_process_sit_ss.
411 --
412 -- Description:
413 -- This Function dels the transaction data for the given item type, item key
414 -- and activity id.
415 -- ----------------------------------------------------------------------------
416
417 PROCEDURE del_transaction_data
418 (p_item_type in varchar2
419 ,p_item_key in varchar2
420 ,p_activity_id in varchar2
421 ,p_login_person_id in varchar2
422 ,p_flow_mode in varchar2 default null
423 );
424
425 end hr_process_sit_ss;