1 Package Body ota_tea_upd as
2 /* $Header: ottea01t.pkb 120.1 2005/06/09 01:16:02 jbharath noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- | Private Global Definitions |
6 -- ----------------------------------------------------------------------------
7 --
8 g_package varchar2(33) := ' ota_tea_upd.'; -- Global package name
9 --
10 -- ----------------------------------------------------------------------------
11 -- |------------------------------< update_dml >------------------------------|
12 -- ----------------------------------------------------------------------------
13 -- {Start Of Comments}
14 --
15 -- Description:
16 -- This procedure controls the actual dml update logic. The functions of this
17 -- procedure are as follows:
18 -- 1) Increment the object_version_number by 1 if the object_version_number
19 -- is defined as an attribute for this entity.
20 -- 2) To set and unset the g_api_dml status as required (as we are about to
21 -- perform dml).
22 -- 3) To update the specified row in the schema using the primary key in
23 -- the predicates.
24 -- 4) To trap any constraint violations that may have occurred.
25 -- 5) To raise any other errors.
26 --
27 -- Pre Conditions:
28 -- This is an internal private procedure which must be called from the upd
29 -- procedure.
30 --
31 -- In Arguments:
32 -- A Pl/Sql record structre.
33 --
34 -- Post Success:
35 -- The specified row will be updated in the schema.
36 --
37 -- Post Failure:
38 -- On the update dml failure it is important to note that we always reset the
39 -- g_api_dml status to false.
40 -- If a check, unique or parent integrity constraint violation is raised the
41 -- constraint_error procedure will be called.
42 -- If any other error is reported, the error will be raised after the
43 -- g_api_dml status is reset.
44 --
45 -- Developer Implementation Notes:
46 -- The update 'set' arguments list should be modified if any of your
47 -- attributes are not updateable.
48 --
49 -- Access Status:
50 -- Internal Development Use Only.
51 --
52 -- {End Of Comments}
53 -- ----------------------------------------------------------------------------
54 Procedure update_dml(p_rec in out nocopy ota_tea_shd.g_rec_type) is
55 --
56 l_proc varchar2(72) := g_package||'update_dml';
57 --
58 Begin
59 hr_utility.set_location('Entering:'||l_proc, 5);
60 --
61 --
62 ota_tea_shd.g_api_dml := true; -- Set the api dml status
63 --
64 -- Update the ota_event_associations Row
65 --
66 update ota_event_associations
67 set
68 event_association_id = p_rec.event_association_id,
69 event_id = p_rec.event_id,
70 customer_id = p_rec.customer_id,
71 organization_id = p_rec.organization_id,
72 job_id = p_rec.job_id,
73 position_id = p_rec.position_id,
74 comments = p_rec.comments,
75 tea_information_category = p_rec.tea_information_category,
76 tea_information1 = p_rec.tea_information1,
77 tea_information2 = p_rec.tea_information2,
78 tea_information3 = p_rec.tea_information3,
79 tea_information4 = p_rec.tea_information4,
80 tea_information5 = p_rec.tea_information5,
81 tea_information6 = p_rec.tea_information6,
82 tea_information7 = p_rec.tea_information7,
83 tea_information8 = p_rec.tea_information8,
84 tea_information9 = p_rec.tea_information9,
85 tea_information10 = p_rec.tea_information10,
86 tea_information11 = p_rec.tea_information11,
87 tea_information12 = p_rec.tea_information12,
88 tea_information13 = p_rec.tea_information13,
89 tea_information14 = p_rec.tea_information14,
90 tea_information15 = p_rec.tea_information15,
91 tea_information16 = p_rec.tea_information16,
92 tea_information17 = p_rec.tea_information17,
93 tea_information18 = p_rec.tea_information18,
94 tea_information19 = p_rec.tea_information19,
95 tea_information20 = p_rec.tea_information20
96 where event_association_id = p_rec.event_association_id;
97 --
98 ota_tea_shd.g_api_dml := false; -- Unset the api dml status
99 --
100 hr_utility.set_location(' Leaving:'||l_proc, 10);
101 --
102 Exception
103 When hr_api.check_integrity_violated Then
104 -- A check constraint has been violated
105 ota_tea_shd.g_api_dml := false; -- Unset the api dml status
106 ota_tea_shd.constraint_error
107 (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
108 When hr_api.parent_integrity_violated Then
109 -- Parent integrity has been violated
110 ota_tea_shd.g_api_dml := false; -- Unset the api dml status
111 ota_tea_shd.constraint_error
112 (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
113 When hr_api.unique_integrity_violated Then
114 -- Unique integrity has been violated
115 ota_tea_shd.g_api_dml := false; -- Unset the api dml status
116 ota_tea_shd.constraint_error
117 (p_constraint_name => hr_api.strip_constraint_name(SQLERRM));
118 When Others Then
119 ota_tea_shd.g_api_dml := false; -- Unset the api dml status
120 Raise;
121 End update_dml;
122 --
123 -- ----------------------------------------------------------------------------
124 -- |------------------------------< pre_update >------------------------------|
125 -- ----------------------------------------------------------------------------
126 -- {Start Of Comments}
127 --
128 -- Description:
129 -- This private procedure contains any processing which is required before
130 -- the update dml.
131 --
132 -- Pre Conditions:
133 -- This is an internal procedure which is called from the upd procedure.
134 --
135 -- In Arguments:
136 -- A Pl/Sql record structre.
137 --
138 -- Post Success:
139 -- Processing continues.
140 --
141 -- Post Failure:
142 -- If an error has occurred, an error message and exception will be raised
143 -- but not handled.
144 --
145 -- Developer Implementation Notes:
146 -- Any pre-processing required before the update dml is issued should be
147 -- coded within this procedure. It is important to note that any 3rd party
148 -- maintenance should be reviewed before placing in this procedure.
149 --
150 -- Access Status:
151 -- Internal Development Use Only.
152 --
153 -- {End Of Comments}
154 -- ----------------------------------------------------------------------------
155 Procedure pre_update(p_rec in ota_tea_shd.g_rec_type) is
156 --
157 l_proc varchar2(72) := g_package||'pre_update';
158 --
159 Begin
160 hr_utility.set_location('Entering:'||l_proc, 5);
161 --
162 hr_utility.set_location(' Leaving:'||l_proc, 10);
163 End pre_update;
164 --
165 -- ----------------------------------------------------------------------------
166 -- |-----------------------------< post_update >------------------------------|
167 -- ----------------------------------------------------------------------------
168 -- {Start Of Comments}
169 --
170 -- Description:
171 -- This private procedure contains any processing which is required after the
172 -- update dml.
173 --
174 -- Pre Conditions:
175 -- This is an internal procedure which is called from the upd procedure.
176 --
177 -- In Arguments:
178 -- A Pl/Sql record structre.
179 --
180 -- Post Success:
181 -- Processing continues.
182 --
183 -- Post Failure:
184 -- If an error has occurred, an error message and exception will be raised
185 -- but not handled.
186 --
187 -- Developer Implementation Notes:
188 -- Any post-processing required after the update dml is issued should be
189 -- coded within this procedure. It is important to note that any 3rd party
190 -- maintenance should be reviewed before placing in this procedure.
191 --
192 -- Access Status:
193 -- Internal Development Use Only.
194 --
195 -- {End Of Comments}
196 -- ----------------------------------------------------------------------------
197 Procedure post_update ( p_business_group_id in number
198 ,p_validate in boolean
199 ,p_price_basis in varchar2
200 ,p_event_id in number
201 ,p_customer_id in number
202 ,p_booking_id in out nocopy number
203 ,p_tdb_object_version_number in out nocopy number
204 ,p_booking_status_type_id in number
205 ,p_date_status_changed in date
206 ,p_status_change_comments in varchar2
207 ,p_booking_contact_id in number
208 ,p_contact_address_id in number
209 ,p_delegate_contact_phone in varchar2
210 ,p_delegate_contact_fax in varchar2
211 ,p_internal_booking_flag in varchar2
212 ,p_source_of_booking in varchar2
213 ,p_number_of_places in number
214 ,p_date_booking_placed in date
215 ,p_update_finance_line in varchar2
216 ,p_tfl_object_version_number in out nocopy number
217 ,p_finance_header_id in number
218 ,p_currency_code in varchar2
219 ,p_standard_amount in number
220 ,p_unitary_amount in number
221 ,p_money_amount in number
222 ,p_booking_deal_id in number
223 ,p_booking_deal_type in varchar2
224 ,p_finance_line_id in out nocopy number
225 ,p_delegate_contact_email in varchar2
226 ) is
227 --
228 l_proc varchar2(72) := g_package||'post_update';
229 l_number number;
230 l_cancel_finance_line boolean;
231 --
232 Begin
233 hr_utility.set_location('Entering:'||l_proc, 5);
234 --
235 if p_update_finance_line in ('C','Y') then
236 l_cancel_finance_line := (p_update_finance_line = 'C');
237 ota_finance.maintain_finance_line
238 (p_finance_header_id => p_finance_header_id,
239 p_booking_id => p_booking_id ,
240 p_currency_code => p_currency_code ,
241 p_standard_amount => p_standard_amount,
242 p_unitary_amount => p_unitary_amount ,
243 p_money_amount => p_money_amount ,
244 p_booking_deal_id => p_booking_deal_id ,
245 p_booking_deal_type => p_booking_deal_type,
246 p_object_version_number => p_tfl_object_version_number,
247 p_finance_line_id => p_finance_line_id,
248 p_cancel_finance_line => l_cancel_finance_line);
249 end if;
250 ota_event_associations_pkg.maintain_delegate_bookings
251 (p_validate => p_validate
252 ,p_price_basis => p_price_basis
253 ,p_business_group_id => p_business_group_id
254 ,p_event_id => p_event_id
255 ,p_customer_id => p_customer_id
256 ,p_booking_id => p_booking_id
257 ,p_tdb_object_version_number => p_tdb_object_version_number
258 ,p_booking_status_type_id => p_booking_status_type_id
259 ,p_date_status_changed => p_date_status_changed
260 ,p_status_change_comments => p_status_change_comments
261 ,p_booking_contact_id => p_booking_contact_id
262 ,p_contact_address_id => p_contact_address_id
263 ,p_delegate_contact_phone => p_delegate_contact_phone
264 ,p_delegate_contact_fax => p_delegate_contact_fax
265 ,p_internal_booking_flag => p_internal_booking_flag
266 ,p_source_of_booking => p_source_of_booking
267 ,p_number_of_places => p_number_of_places
268 ,p_date_booking_placed => p_date_booking_placed
269 ,p_update_finance_line => p_update_finance_line
270 ,p_tfl_object_version_number => p_tfl_object_version_number
271 ,p_finance_header_id => p_finance_header_id
272 ,p_currency_code => p_currency_code
273 ,p_standard_amount => p_standard_amount
274 ,p_unitary_amount => p_unitary_amount
275 ,p_money_amount => p_money_amount
276 ,p_booking_deal_id => p_booking_deal_id
277 ,p_booking_deal_type => p_booking_deal_type
278 ,p_finance_line_id => p_finance_line_id
279 ,p_delegate_contact_email => p_delegate_contact_email
280 );
281 --
282 hr_utility.set_location(' Leaving:'||l_proc, 10);
283 End post_update;
284
285 --
286 -- ----------------------------------------------------------------------------
287 -- |-----------------------------< convert_defs >-----------------------------|
288 -- ----------------------------------------------------------------------------
289 -- {Start Of Comments}
290 --
291 -- Description:
292 -- The Convert_Defs function has one very important function:
293 -- It must return the record structure for the row with all system defaulted
294 -- values converted into its corresponding argument value for update. When
295 -- we attempt to update a row through the Upd business process , certain
296 -- arguments can be defaulted which enables flexibility in the calling of
297 -- the upd process (e.g. only attributes which need to be updated need to be
298 -- specified). For the upd business process to determine which attributes
299 -- have NOT been specified we need to check if the argument has a reserved
300 -- system default value. Therefore, for all attributes which have a
301 -- corresponding reserved system default mechanism specified we need to
302 -- check if a system default is being used. If a system default is being
303 -- used then we convert the defaulted value into its corresponding attribute
304 -- value held in the g_old_rec data structure.
305 --
306 -- Pre Conditions:
307 -- This private function can only be called from the upd process.
308 --
309 -- In Arguments:
310 -- A Pl/Sql record structre.
311 --
312 -- Post Success:
313 -- The record structure will be returned with all system defaulted argument
314 -- values converted into its current row attribute value.
315 --
316 -- Post Failure:
317 -- No direct error handling is required within this function. Any possible
318 -- errors within this function will be a PL/SQL value error due to conversion
319 -- of datatypes or data lengths.
320 --
321 -- Developer Implementation Notes:
322 -- None.
323 --
324 -- Access Status:
325 -- Internal Development Use Only.
326 --
327 -- {End Of Comments}
328 -- ----------------------------------------------------------------------------
329 Function convert_defs(p_rec in out nocopy ota_tea_shd.g_rec_type)
330 Return ota_tea_shd.g_rec_type is
331 --
332 l_proc varchar2(72) := g_package||'convert_defs';
333 --
334 Begin
335 --
336 hr_utility.set_location('Entering:'||l_proc, 5);
337 --
338 -- We must now examine each argument value in the
339 -- p_rec plsql record structure
340 -- to see if a system default is being used. If a system default
341 -- is being used then we must set to the 'current' argument value.
342 --
343 If (p_rec.event_id = hr_api.g_number) then
344 p_rec.event_id :=
345 ota_tea_shd.g_old_rec.event_id;
346 End If;
347 If (p_rec.customer_id = hr_api.g_number) then
348 p_rec.customer_id :=
349 ota_tea_shd.g_old_rec.customer_id;
350 End If;
351 If (p_rec.organization_id = hr_api.g_number) then
352 p_rec.organization_id :=
353 ota_tea_shd.g_old_rec.organization_id;
354 End If;
355 If (p_rec.job_id = hr_api.g_number) then
356 p_rec.job_id :=
357 ota_tea_shd.g_old_rec.job_id;
358 End If;
359 If (p_rec.position_id = hr_api.g_number) then
360 p_rec.position_id :=
361 ota_tea_shd.g_old_rec.position_id;
362 End If;
363 If (p_rec.comments = hr_api.g_varchar2) then
364 p_rec.comments :=
365 ota_tea_shd.g_old_rec.comments;
366 End If;
367 If (p_rec.tea_information_category = hr_api.g_varchar2) then
368 p_rec.tea_information_category :=
369 ota_tea_shd.g_old_rec.tea_information_category;
370 End If;
371 If (p_rec.tea_information1 = hr_api.g_varchar2) then
372 p_rec.tea_information1 :=
373 ota_tea_shd.g_old_rec.tea_information1;
374 End If;
375 If (p_rec.tea_information2 = hr_api.g_varchar2) then
376 p_rec.tea_information2 :=
377 ota_tea_shd.g_old_rec.tea_information2;
378 End If;
379 If (p_rec.tea_information3 = hr_api.g_varchar2) then
380 p_rec.tea_information3 :=
381 ota_tea_shd.g_old_rec.tea_information3;
382 End If;
383 If (p_rec.tea_information4 = hr_api.g_varchar2) then
384 p_rec.tea_information4 :=
385 ota_tea_shd.g_old_rec.tea_information4;
386 End If;
387 If (p_rec.tea_information5 = hr_api.g_varchar2) then
388 p_rec.tea_information5 :=
389 ota_tea_shd.g_old_rec.tea_information5;
390 End If;
391 If (p_rec.tea_information6 = hr_api.g_varchar2) then
392 p_rec.tea_information6 :=
393 ota_tea_shd.g_old_rec.tea_information6;
394 End If;
395 If (p_rec.tea_information7 = hr_api.g_varchar2) then
396 p_rec.tea_information7 :=
397 ota_tea_shd.g_old_rec.tea_information7;
398 End If;
399 If (p_rec.tea_information8 = hr_api.g_varchar2) then
400 p_rec.tea_information8 :=
401 ota_tea_shd.g_old_rec.tea_information8;
402 End If;
403 If (p_rec.tea_information9 = hr_api.g_varchar2) then
404 p_rec.tea_information9 :=
405 ota_tea_shd.g_old_rec.tea_information9;
406 End If;
407 If (p_rec.tea_information10 = hr_api.g_varchar2) then
408 p_rec.tea_information10 :=
409 ota_tea_shd.g_old_rec.tea_information10;
410 End If;
411 If (p_rec.tea_information11 = hr_api.g_varchar2) then
412 p_rec.tea_information11 :=
413 ota_tea_shd.g_old_rec.tea_information11;
414 End If;
415 If (p_rec.tea_information12 = hr_api.g_varchar2) then
416 p_rec.tea_information12 :=
417 ota_tea_shd.g_old_rec.tea_information12;
418 End If;
419 If (p_rec.tea_information13 = hr_api.g_varchar2) then
420 p_rec.tea_information13 :=
421 ota_tea_shd.g_old_rec.tea_information13;
422 End If;
423 If (p_rec.tea_information14 = hr_api.g_varchar2) then
424 p_rec.tea_information14 :=
425 ota_tea_shd.g_old_rec.tea_information14;
426 End If;
427 If (p_rec.tea_information15 = hr_api.g_varchar2) then
428 p_rec.tea_information15 :=
429 ota_tea_shd.g_old_rec.tea_information15;
430 End If;
431 If (p_rec.tea_information16 = hr_api.g_varchar2) then
432 p_rec.tea_information16 :=
433 ota_tea_shd.g_old_rec.tea_information16;
434 End If;
435 If (p_rec.tea_information17 = hr_api.g_varchar2) then
436 p_rec.tea_information17 :=
437 ota_tea_shd.g_old_rec.tea_information17;
438 End If;
439 If (p_rec.tea_information18 = hr_api.g_varchar2) then
440 p_rec.tea_information18 :=
441 ota_tea_shd.g_old_rec.tea_information18;
442 End If;
443 If (p_rec.tea_information19 = hr_api.g_varchar2) then
444 p_rec.tea_information19 :=
445 ota_tea_shd.g_old_rec.tea_information19;
446 End If;
447 If (p_rec.tea_information20 = hr_api.g_varchar2) then
448 p_rec.tea_information20 :=
449 ota_tea_shd.g_old_rec.tea_information20;
450 End If;
451 --
452 -- Return the plsql record structure.
453 --
454 hr_utility.set_location(' Leaving:'||l_proc, 10);
455 Return(p_rec);
456 --
457 End convert_defs;
458 --
459 -- ----------------------------------------------------------------------------
460 -- |---------------------------------< upd >----------------------------------|
461 -- ----------------------------------------------------------------------------
462 Procedure upd
463 (
464 p_rec in out nocopy ota_tea_shd.g_rec_type,
465 p_validate in boolean
466 ,p_association_type in varchar2
467 ,p_business_group_id in number
468 ,p_price_basis in varchar2
469 ,p_booking_id in out nocopy number
470 ,p_tdb_object_version_number in out nocopy number
471 ,p_booking_status_type_id in number
472 ,p_date_status_changed in date
473 ,p_status_change_comments in varchar2
474 ,p_booking_contact_id in number
475 ,p_contact_address_id in number
476 ,p_delegate_contact_phone in varchar2
477 ,p_delegate_contact_fax in varchar2
478 ,p_internal_booking_flag in varchar2
479 ,p_source_of_booking in varchar2
480 ,p_number_of_places in number
481 ,p_date_booking_placed in date
482 ,p_tfl_object_version_number in out nocopy number
483 ,p_update_finance_line in varchar2
484 ,p_finance_header_id in number
485 ,p_currency_code in varchar2
486 ,p_standard_amount in number
487 ,p_unitary_amount in number
488 ,p_money_amount in number
489 ,p_booking_deal_id in number
490 ,p_booking_deal_type in varchar2
491 ,p_finance_line_id in out nocopy number
492 ,p_delegate_contact_email in varchar2
493 ) is
494 --
495 l_proc varchar2(72) := g_package||'upd';
496 --
497 Begin
498 hr_utility.set_location('Entering:'||l_proc, 5);
499 --
500 -- Determine if the business process is to be validated.
501 --
502 If p_validate then
503 --
504 -- Issue the savepoint.
505 --
506 SAVEPOINT upd_ota_tea;
507 End If;
508 --
509 -- We must lock the row which we need to update.
510 --
511 ota_tea_shd.lck
512 (
513 p_rec.event_association_id
514 ,p_booking_id
515 ,p_tdb_object_version_number
516 );
517 --
518 -- 1. During an update system defaults are used to determine if
519 -- arguments have been defaulted or not. We must therefore
520 -- derive the full record structure values to be updated.
521 --
522 -- 2. Call the supporting update validate operations.
523 --
524 ota_tea_bus.update_validate(convert_defs(p_rec)
525 ,p_association_type);
526 --
527 -- Call the supporting pre-update operation
528 --
529 pre_update(p_rec);
530 --
531 -- Update the row.
532 --
533 update_dml(p_rec);
534 --
535 -- Call the supporting post-update operation
536 --
537 post_update(
538 p_business_group_id
539 ,p_validate
540 ,p_price_basis
541 ,p_rec.event_id
542 ,p_rec.customer_id
543 ,p_booking_id
544 ,p_tdb_object_version_number
545 ,p_booking_status_type_id
546 ,p_date_status_changed
547 ,p_status_change_comments
548 ,p_booking_contact_id
549 ,p_contact_address_id
550 ,p_delegate_contact_phone
551 ,p_delegate_contact_fax
552 ,p_internal_booking_flag
553 ,p_source_of_booking
554 ,p_number_of_places
555 ,p_date_booking_placed
556 ,p_update_finance_line
557 ,p_tfl_object_version_number
558 ,p_finance_header_id
559 ,p_currency_code
560 ,p_standard_amount
561 ,p_unitary_amount
562 ,p_money_amount
563 ,p_booking_deal_id
564 ,p_booking_deal_type
565 ,p_finance_line_id
566 ,p_delegate_contact_email
567 );
568 --
569 -- If we are validating then raise the Validate_Enabled exception
570 --
571 If p_validate then
572 Raise HR_Api.Validate_Enabled;
573 End If;
574 --
575 hr_utility.set_location(' Leaving:'||l_proc, 10);
576 Exception
577 When HR_Api.Validate_Enabled Then
578 --
579 -- As the Validate_Enabled exception has been raised
580 -- we must rollback to the savepoint
581 --
582 ROLLBACK TO upd_ota_tea;
583 End upd;
584 --
585 -- ----------------------------------------------------------------------------
586 -- |---------------------------------< upd >----------------------------------|
587 -- ----------------------------------------------------------------------------
588 --
589 Procedure upd
590 (
591 p_event_association_id in number,
592 p_event_id in number default hr_api.g_number,
593 p_customer_id in number default hr_api.g_number,
594 p_organization_id in number default hr_api.g_number,
595 p_job_id in number default hr_api.g_number,
596 p_position_id in number default hr_api.g_number,
597 p_comments in varchar2 default hr_api.g_varchar2,
598 p_tea_information_category in varchar2 default hr_api.g_varchar2,
599 p_tea_information1 in varchar2 default hr_api.g_varchar2,
600 p_tea_information2 in varchar2 default hr_api.g_varchar2,
601 p_tea_information3 in varchar2 default hr_api.g_varchar2,
602 p_tea_information4 in varchar2 default hr_api.g_varchar2,
603 p_tea_information5 in varchar2 default hr_api.g_varchar2,
604 p_tea_information6 in varchar2 default hr_api.g_varchar2,
605 p_tea_information7 in varchar2 default hr_api.g_varchar2,
606 p_tea_information8 in varchar2 default hr_api.g_varchar2,
607 p_tea_information9 in varchar2 default hr_api.g_varchar2,
608 p_tea_information10 in varchar2 default hr_api.g_varchar2,
609 p_tea_information11 in varchar2 default hr_api.g_varchar2,
610 p_tea_information12 in varchar2 default hr_api.g_varchar2,
611 p_tea_information13 in varchar2 default hr_api.g_varchar2,
612 p_tea_information14 in varchar2 default hr_api.g_varchar2,
613 p_tea_information15 in varchar2 default hr_api.g_varchar2,
614 p_tea_information16 in varchar2 default hr_api.g_varchar2,
615 p_tea_information17 in varchar2 default hr_api.g_varchar2,
616 p_tea_information18 in varchar2 default hr_api.g_varchar2,
617 p_tea_information19 in varchar2 default hr_api.g_varchar2,
618 p_tea_information20 in varchar2 default hr_api.g_varchar2,
619 p_validate in boolean default false
620 ,p_association_type in varchar2
621 ,p_business_group_id in number default null
622 ,p_price_basis in varchar2 default null
623 ,p_booking_id in out nocopy number
624 ,p_tdb_object_version_number in out nocopy number
625 ,p_booking_status_type_id in number default null
626 ,p_date_status_changed in date default null
627 ,p_status_change_comments in varchar2 default null
628 ,p_booking_contact_id in number default null
629 ,p_contact_address_id in number default null
630 ,p_delegate_contact_phone in varchar2 default null
631 ,p_delegate_contact_fax in varchar2 default null
632 ,p_internal_booking_flag in varchar2 default null
633 ,p_source_of_booking in varchar2 default null
634 ,p_number_of_places in number default null
635 ,p_date_booking_placed in date default null
636 ,p_tfl_object_version_number in out nocopy number
637 ,p_update_finance_line in varchar2 default null
638 ,p_finance_header_id in number default null
639 ,p_currency_code in varchar2 default null
640 ,p_standard_amount in number default null
641 ,p_unitary_amount in number default null
642 ,p_money_amount in number default null
643 ,p_booking_deal_id in number default null
644 ,p_booking_deal_type in varchar2 default null
645 ,p_finance_line_id in out nocopy number
646 ,p_delegate_contact_email in varchar2
647 ) is
648 --
649 l_rec ota_tea_shd.g_rec_type;
650 l_proc varchar2(72) := g_package||'upd';
651 --
652 Begin
653 hr_utility.set_location('Entering:'||l_proc, 5);
654 --
655 -- Call conversion function to turn arguments into the
656 -- l_rec structure.
657 --
658 l_rec :=
659 ota_tea_shd.convert_args
660 (
661 p_event_association_id,
662 p_event_id,
663 p_customer_id,
664 p_organization_id,
665 p_job_id,
666 p_position_id,
667 p_comments,
668 p_tea_information_category,
669 p_tea_information1,
670 p_tea_information2,
671 p_tea_information3,
672 p_tea_information4,
673 p_tea_information5,
674 p_tea_information6,
675 p_tea_information7,
676 p_tea_information8,
677 p_tea_information9,
678 p_tea_information10,
679 p_tea_information11,
680 p_tea_information12,
681 p_tea_information13,
682 p_tea_information14,
683 p_tea_information15,
684 p_tea_information16,
685 p_tea_information17,
686 p_tea_information18,
687 p_tea_information19,
688 p_tea_information20
689 );
690 --
691 -- Having converted the arguments into the
692 -- plsql record structure we call the corresponding record
693 -- business process.
694 --
695 upd(l_rec
696 ,p_validate
697 ,p_association_type
698 ,p_business_group_id
699 ,p_price_basis
700 ,p_booking_id
701 ,p_tdb_object_version_number
702 ,p_booking_status_type_id
703 ,p_date_status_changed
704 ,p_status_change_comments
705 ,p_booking_contact_id
706 ,p_contact_address_id
707 ,p_delegate_contact_phone
708 ,p_delegate_contact_fax
709 ,p_internal_booking_flag
710 ,p_source_of_booking
711 ,p_number_of_places
712 ,p_date_booking_placed
713 ,p_tfl_object_version_number
714 ,p_update_finance_line
715 ,p_finance_header_id
716 ,p_currency_code
717 ,p_standard_amount
718 ,p_unitary_amount
719 ,p_money_amount
720 ,p_booking_deal_id
721 ,p_booking_deal_type
722 ,p_finance_line_id
723 ,p_delegate_contact_email
724 );
725 --
726 --
727 hr_utility.set_location(' Leaving:'||l_proc, 10);
728 End upd;
729 --
730 Procedure upd
731 (
732 p_event_association_id in number,
733 p_event_id in number default hr_api.g_number,
734 p_customer_id in number default hr_api.g_number,
735 p_comments in varchar2 default hr_api.g_varchar2,
736 p_tea_information_category in varchar2 default hr_api.g_varchar2,
737 p_tea_information1 in varchar2 default hr_api.g_varchar2,
738 p_tea_information2 in varchar2 default hr_api.g_varchar2,
739 p_tea_information3 in varchar2 default hr_api.g_varchar2,
740 p_tea_information4 in varchar2 default hr_api.g_varchar2,
741 p_tea_information5 in varchar2 default hr_api.g_varchar2,
742 p_tea_information6 in varchar2 default hr_api.g_varchar2,
743 p_tea_information7 in varchar2 default hr_api.g_varchar2,
744 p_tea_information8 in varchar2 default hr_api.g_varchar2,
745 p_tea_information9 in varchar2 default hr_api.g_varchar2,
746 p_tea_information10 in varchar2 default hr_api.g_varchar2,
747 p_tea_information11 in varchar2 default hr_api.g_varchar2,
748 p_tea_information12 in varchar2 default hr_api.g_varchar2,
749 p_tea_information13 in varchar2 default hr_api.g_varchar2,
750 p_tea_information14 in varchar2 default hr_api.g_varchar2,
751 p_tea_information15 in varchar2 default hr_api.g_varchar2,
752 p_tea_information16 in varchar2 default hr_api.g_varchar2,
753 p_tea_information17 in varchar2 default hr_api.g_varchar2,
754 p_tea_information18 in varchar2 default hr_api.g_varchar2,
755 p_tea_information19 in varchar2 default hr_api.g_varchar2,
756 p_tea_information20 in varchar2 default hr_api.g_varchar2,
757 p_validate in boolean
758 ,p_business_group_id in number
759 ,p_price_basis in varchar2
760 ,p_booking_id in out nocopy number
761 ,p_tdb_object_version_number in out nocopy number
762 ,p_booking_status_type_id in number
763 ,p_date_status_changed in date
764 ,p_status_change_comments in varchar2
765 ,p_booking_contact_id in number
766 ,p_contact_address_id in number
767 ,p_delegate_contact_phone in varchar2
768 ,p_delegate_contact_fax in varchar2
769 ,p_internal_booking_flag in varchar2
770 ,p_source_of_booking in varchar2
771 ,p_number_of_places in number
772 ,p_date_booking_placed in date
773 ,p_tfl_object_version_number in out nocopy number
774 ,p_update_finance_line in varchar2
775 ,p_finance_header_id in number
776 ,p_currency_code in varchar2
777 ,p_standard_amount in number
778 ,p_unitary_amount in number
779 ,p_money_amount in number
780 ,p_booking_deal_id in number
781 ,p_booking_deal_type in varchar2
782 ,p_finance_line_id in out nocopy number
783 , p_delegate_contact_email in varchar2
784 ) is
785 begin
786 upd(
787 p_event_association_id => p_event_association_id
788 ,p_event_id => p_event_id
789 ,p_customer_id => p_customer_id
790 ,p_organization_id => null
791 ,p_job_id => null
792 ,p_position_id => null
793 ,p_comments => p_comments
794 ,p_tea_information_category => p_tea_information_category
795 ,p_tea_information1 => p_tea_information1
796 ,p_tea_information2 => p_tea_information2
797 ,p_tea_information3 => p_tea_information3
798 ,p_tea_information4 => p_tea_information4
799 ,p_tea_information5 => p_tea_information5
800 ,p_tea_information6 => p_tea_information6
801 ,p_tea_information7 => p_tea_information7
802 ,p_tea_information8 => p_tea_information8
803 ,p_tea_information9 => p_tea_information9
804 ,p_tea_information10 => p_tea_information10
805 ,p_tea_information11 => p_tea_information11
806 ,p_tea_information12 => p_tea_information12
807 ,p_tea_information13 => p_tea_information13
808 ,p_tea_information14 => p_tea_information14
809 ,p_tea_information15 => p_tea_information15
810 ,p_tea_information16 => p_tea_information16
811 ,p_tea_information17 => p_tea_information17
812 ,p_tea_information18 => p_tea_information18
813 ,p_tea_information19 => p_tea_information19
814 ,p_tea_information20 => p_tea_information20
815 ,p_validate => p_validate
816 ,p_association_type => 'C'
817 ,p_business_group_id => p_business_group_id
818 ,p_price_basis => p_price_basis
819 ,p_booking_id => p_booking_id
820 ,p_tdb_object_version_number => p_tdb_object_version_number
821 ,p_booking_status_type_id => p_booking_status_type_id
822 ,p_date_status_changed => p_date_status_changed
823 ,p_status_change_comments => p_status_change_comments
824 ,p_booking_contact_id => p_booking_contact_id
825 ,p_contact_address_id => p_contact_address_id
826 ,p_delegate_contact_phone => p_delegate_contact_phone
827 ,p_delegate_contact_fax => p_delegate_contact_fax
828 ,p_internal_booking_flag => p_internal_booking_flag
829 ,p_source_of_booking => p_source_of_booking
830 ,p_number_of_places => p_number_of_places
831 ,p_date_booking_placed => p_date_booking_placed
832 ,p_tfl_object_version_number => p_tfl_object_version_number
833 ,p_update_finance_line => p_update_finance_line
834 ,p_finance_header_id => p_finance_header_id
835 ,p_currency_code => p_currency_code
836 ,p_standard_amount => p_standard_amount
837 ,p_unitary_amount => p_unitary_amount
838 ,p_money_amount => p_money_amount
839 ,p_booking_deal_id => p_booking_deal_id
840 ,p_booking_deal_type => p_booking_deal_type
841 ,p_finance_line_id => p_finance_line_id
842 ,p_delegate_contact_email => p_delegate_contact_email
843 );
844 end upd;
845 --
846 Procedure upd
847 (
848 p_event_association_id in number,
849 p_event_id in number,
850 p_organization_id in number,
851 p_job_id in number,
852 p_position_id in number,
853 p_comments in varchar2,
854 p_tea_information_category in varchar2,
855 p_tea_information1 in varchar2,
856 p_tea_information2 in varchar2,
857 p_tea_information3 in varchar2,
858 p_tea_information4 in varchar2,
859 p_tea_information5 in varchar2,
860 p_tea_information6 in varchar2,
861 p_tea_information7 in varchar2,
862 p_tea_information8 in varchar2,
863 p_tea_information9 in varchar2,
864 p_tea_information10 in varchar2,
865 p_tea_information11 in varchar2,
866 p_tea_information12 in varchar2,
867 p_tea_information13 in varchar2,
868 p_tea_information14 in varchar2,
869 p_tea_information15 in varchar2,
870 p_tea_information16 in varchar2,
871 p_tea_information17 in varchar2,
872 p_tea_information18 in varchar2,
873 p_tea_information19 in varchar2,
874 p_tea_information20 in varchar2,
875 p_validate in boolean
876 ) is
877 --
878 l_booking_id number;
879 l_tdb_object_version_number number;
880 l_tfl_object_version_number number;
881 l_finance_line_id number;
882 --
883 begin
884 upd(
885 p_event_association_id => p_event_association_id
886 ,p_event_id => p_event_id
887 ,p_customer_id => null
888 ,p_organization_id => p_organization_id
889 ,p_job_id => p_job_id
890 ,p_position_id => p_position_id
891 ,p_comments => p_comments
892 ,p_tea_information_category => p_tea_information_category
893 ,p_tea_information1 => p_tea_information1
894 ,p_tea_information2 => p_tea_information2
895 ,p_tea_information3 => p_tea_information3
896 ,p_tea_information4 => p_tea_information4
897 ,p_tea_information5 => p_tea_information5
898 ,p_tea_information6 => p_tea_information6
899 ,p_tea_information7 => p_tea_information7
900 ,p_tea_information8 => p_tea_information8
901 ,p_tea_information9 => p_tea_information9
902 ,p_tea_information10 => p_tea_information10
903 ,p_tea_information11 => p_tea_information11
904 ,p_tea_information12 => p_tea_information12
905 ,p_tea_information13 => p_tea_information13
906 ,p_tea_information14 => p_tea_information14
907 ,p_tea_information15 => p_tea_information15
908 ,p_tea_information16 => p_tea_information16
909 ,p_tea_information17 => p_tea_information17
910 ,p_tea_information18 => p_tea_information18
911 ,p_tea_information19 => p_tea_information19
912 ,p_tea_information20 => p_tea_information20
913 ,p_validate => p_validate
914 ,p_association_type => 'A'
915 ,p_business_group_id => null
916 ,p_price_basis => null
917 ,p_booking_id => l_booking_id
918 ,p_tdb_object_version_number => l_tdb_object_version_number
919 ,p_booking_status_type_id => null
920 ,p_date_status_changed => null
921 ,p_status_change_comments => null
922 ,p_booking_contact_id => null
923 ,p_contact_address_id => null
924 ,p_delegate_contact_phone => null
925 ,p_delegate_contact_fax => null
926 ,p_internal_booking_flag => null
927 ,p_source_of_booking => null
928 ,p_number_of_places => null
929 ,p_date_booking_placed => null
930 ,p_tfl_object_version_number => l_tfl_object_version_number
931 ,p_update_finance_line => null
932 ,p_finance_header_id => null
933 ,p_currency_code => null
934 ,p_standard_amount => null
935 ,p_unitary_amount => null
936 ,p_money_amount => null
937 ,p_booking_deal_id => null
938 ,p_booking_deal_type => null
939 ,p_finance_line_id => l_finance_line_id
940 ,p_delegate_contact_email => null
941 );
942 end upd;
943 end ota_tea_upd;