DBA Data[Home] [Help]

PACKAGE BODY: APPS.BEN_ACTY_RT_DEDUCT_SCHED_API

Source


1 Package Body ben_ACTY_RT_DEDUCT_SCHED_api as
2 /* $Header: beadsapi.pkb 120.0 2005/05/28 00:22:01 appldev noship $ */
3 --
4 -- Package Variables
5 --
6 g_package  varchar2(33) := '  ben_ACTY_RT_DEDUCT_SCHED_api.';
7 --
8 -- ----------------------------------------------------------------------------
9 -- |------------------------< create_ACTY_RT_DEDUCT_SCHED >----------------------|
10 -- ----------------------------------------------------------------------------
11 --
12 procedure create_ACTY_RT_DEDUCT_SCHED
13   (p_validate                       in  boolean   default false
14   ,p_acty_rt_ded_sched_id           out nocopy number
15   ,p_effective_start_date           out nocopy date
16   ,p_effective_end_date             out nocopy date
17   ,p_business_group_id              in  number    default null
18   ,p_ded_sched_py_freq_id           in  number    default null
19   ,p_acty_base_rt_id                in  number    default null
20   ,p_ded_sched_rl                   in  number    default null
21   ,p_ded_sched_cd                   in  varchar2  default null
22   ,p_ads_attribute_category         in  varchar2  default null
23   ,p_ads_attribute1                 in  varchar2  default null
24   ,p_ads_attribute2                 in  varchar2  default null
25   ,p_ads_attribute3                 in  varchar2  default null
26   ,p_ads_attribute4                 in  varchar2  default null
27   ,p_ads_attribute5                 in  varchar2  default null
28   ,p_ads_attribute6                 in  varchar2  default null
29   ,p_ads_attribute7                 in  varchar2  default null
30   ,p_ads_attribute8                 in  varchar2  default null
31   ,p_ads_attribute9                 in  varchar2  default null
32   ,p_ads_attribute10                in  varchar2  default null
33   ,p_ads_attribute11                in  varchar2  default null
34   ,p_ads_attribute12                in  varchar2  default null
35   ,p_ads_attribute13                in  varchar2  default null
36   ,p_ads_attribute14                in  varchar2  default null
37   ,p_ads_attribute15                in  varchar2  default null
38   ,p_ads_attribute16                in  varchar2  default null
39   ,p_ads_attribute17                in  varchar2  default null
40   ,p_ads_attribute18                in  varchar2  default null
41   ,p_ads_attribute19                in  varchar2  default null
42   ,p_ads_attribute20                in  varchar2  default null
43   ,p_ads_attribute21                in  varchar2  default null
44   ,p_ads_attribute22                in  varchar2  default null
45   ,p_ads_attribute23                in  varchar2  default null
46   ,p_ads_attribute24                in  varchar2  default null
47   ,p_ads_attribute25                in  varchar2  default null
48   ,p_ads_attribute26                in  varchar2  default null
49   ,p_ads_attribute27                in  varchar2  default null
50   ,p_ads_attribute28                in  varchar2  default null
51   ,p_ads_attribute29                in  varchar2  default null
52   ,p_ads_attribute30                in  varchar2  default null
53   ,p_object_version_number          out nocopy number
54   ,p_effective_date                 in  date
55   ) is
56   --
57   -- Declare cursors and local variables
58   --
59   l_acty_rt_ded_sched_id ben_acty_rt_ded_sched_f.acty_rt_ded_sched_id%TYPE;
60   l_effective_start_date ben_acty_rt_ded_sched_f.effective_start_date%TYPE;
61   l_effective_end_date ben_acty_rt_ded_sched_f.effective_end_date%TYPE;
62   l_proc varchar2(72) := g_package||'create_ACTY_RT_DEDUCT_SCHED';
63   l_object_version_number ben_acty_rt_ded_sched_f.object_version_number%TYPE;
64   --
65 begin
66   --
67   hr_utility.set_location('Entering:'|| l_proc, 10);
68   --
69   -- Issue a savepoint if operating in validation only mode
70   --
71   savepoint create_ACTY_RT_DEDUCT_SCHED;
72   --
73   hr_utility.set_location(l_proc, 20);
74   --
75   -- Process Logic
76   --
77   begin
78     --
79     -- Start of API User Hook for the before hook of create_ACTY_RT_DEDUCT_SCHED
80     --
81     ben_ACTY_RT_DEDUCT_SCHED_bk1.create_ACTY_RT_DEDUCT_SCHED_b
82       (
83        p_business_group_id              =>  p_business_group_id
84       ,p_ded_sched_py_freq_id           =>  p_ded_sched_py_freq_id
85       ,p_acty_base_rt_id                =>  p_acty_base_rt_id
86       ,p_ded_sched_rl                   =>  p_ded_sched_rl
87       ,p_ded_sched_cd                   =>  p_ded_sched_cd
88       ,p_ads_attribute_category         =>  p_ads_attribute_category
89       ,p_ads_attribute1                 =>  p_ads_attribute1
90       ,p_ads_attribute2                 =>  p_ads_attribute2
91       ,p_ads_attribute3                 =>  p_ads_attribute3
92       ,p_ads_attribute4                 =>  p_ads_attribute4
93       ,p_ads_attribute5                 =>  p_ads_attribute5
94       ,p_ads_attribute6                 =>  p_ads_attribute6
95       ,p_ads_attribute7                 =>  p_ads_attribute7
96       ,p_ads_attribute8                 =>  p_ads_attribute8
97       ,p_ads_attribute9                 =>  p_ads_attribute9
98       ,p_ads_attribute10                =>  p_ads_attribute10
99       ,p_ads_attribute11                =>  p_ads_attribute11
100       ,p_ads_attribute12                =>  p_ads_attribute12
101       ,p_ads_attribute13                =>  p_ads_attribute13
102       ,p_ads_attribute14                =>  p_ads_attribute14
103       ,p_ads_attribute15                =>  p_ads_attribute15
104       ,p_ads_attribute16                =>  p_ads_attribute16
105       ,p_ads_attribute17                =>  p_ads_attribute17
106       ,p_ads_attribute18                =>  p_ads_attribute18
107       ,p_ads_attribute19                =>  p_ads_attribute19
108       ,p_ads_attribute20                =>  p_ads_attribute20
109       ,p_ads_attribute21                =>  p_ads_attribute21
110       ,p_ads_attribute22                =>  p_ads_attribute22
111       ,p_ads_attribute23                =>  p_ads_attribute23
112       ,p_ads_attribute24                =>  p_ads_attribute24
113       ,p_ads_attribute25                =>  p_ads_attribute25
114       ,p_ads_attribute26                =>  p_ads_attribute26
115       ,p_ads_attribute27                =>  p_ads_attribute27
116       ,p_ads_attribute28                =>  p_ads_attribute28
117       ,p_ads_attribute29                =>  p_ads_attribute29
118       ,p_ads_attribute30                =>  p_ads_attribute30
119       ,p_effective_date                 => trunc(p_effective_date)
120       );
121   exception
122     when hr_api.cannot_find_prog_unit then
123       hr_api.cannot_find_prog_unit_error
124         (
125          p_module_name => 'CREATE_ACTY_RT_DEDUCT_SCHED'
126         ,p_hook_type   => 'BP'
127         );
128     --
129     -- End of API User Hook for the before hook of create_ACTY_RT_DEDUCT_SCHED
130     --
131   end;
132   --
133   ben_ads_ins.ins
134     (
135      p_acty_rt_ded_sched_id          => l_acty_rt_ded_sched_id
136     ,p_effective_start_date          => l_effective_start_date
137     ,p_effective_end_date            => l_effective_end_date
138     ,p_business_group_id             => p_business_group_id
139     ,p_ded_sched_py_freq_id          => p_ded_sched_py_freq_id
140     ,p_acty_base_rt_id               => p_acty_base_rt_id
141     ,p_ded_sched_rl                  => p_ded_sched_rl
142     ,p_ded_sched_cd                  => p_ded_sched_cd
143     ,p_ads_attribute_category        => p_ads_attribute_category
144     ,p_ads_attribute1                => p_ads_attribute1
145     ,p_ads_attribute2                => p_ads_attribute2
146     ,p_ads_attribute3                => p_ads_attribute3
147     ,p_ads_attribute4                => p_ads_attribute4
148     ,p_ads_attribute5                => p_ads_attribute5
149     ,p_ads_attribute6                => p_ads_attribute6
150     ,p_ads_attribute7                => p_ads_attribute7
151     ,p_ads_attribute8                => p_ads_attribute8
152     ,p_ads_attribute9                => p_ads_attribute9
153     ,p_ads_attribute10               => p_ads_attribute10
154     ,p_ads_attribute11               => p_ads_attribute11
155     ,p_ads_attribute12               => p_ads_attribute12
156     ,p_ads_attribute13               => p_ads_attribute13
157     ,p_ads_attribute14               => p_ads_attribute14
158     ,p_ads_attribute15               => p_ads_attribute15
159     ,p_ads_attribute16               => p_ads_attribute16
160     ,p_ads_attribute17               => p_ads_attribute17
161     ,p_ads_attribute18               => p_ads_attribute18
162     ,p_ads_attribute19               => p_ads_attribute19
163     ,p_ads_attribute20               => p_ads_attribute20
164     ,p_ads_attribute21               => p_ads_attribute21
165     ,p_ads_attribute22               => p_ads_attribute22
166     ,p_ads_attribute23               => p_ads_attribute23
167     ,p_ads_attribute24               => p_ads_attribute24
168     ,p_ads_attribute25               => p_ads_attribute25
169     ,p_ads_attribute26               => p_ads_attribute26
170     ,p_ads_attribute27               => p_ads_attribute27
171     ,p_ads_attribute28               => p_ads_attribute28
172     ,p_ads_attribute29               => p_ads_attribute29
173     ,p_ads_attribute30               => p_ads_attribute30
174     ,p_object_version_number         => l_object_version_number
175     ,p_effective_date                => trunc(p_effective_date)
176     );
177   --
178   begin
179     --
180     -- Start of API User Hook for the after hook of create_ACTY_RT_DEDUCT_SCHED
181     --
182     ben_ACTY_RT_DEDUCT_SCHED_bk1.create_ACTY_RT_DEDUCT_SCHED_a
183       (
184        p_acty_rt_ded_sched_id           =>  l_acty_rt_ded_sched_id
185       ,p_effective_start_date           =>  l_effective_start_date
186       ,p_effective_end_date             =>  l_effective_end_date
187       ,p_business_group_id              =>  p_business_group_id
188       ,p_ded_sched_py_freq_id           =>  p_ded_sched_py_freq_id
189       ,p_acty_base_rt_id                =>  p_acty_base_rt_id
190       ,p_ded_sched_rl                   =>  p_ded_sched_rl
191       ,p_ded_sched_cd                   =>  p_ded_sched_cd
192       ,p_ads_attribute_category         =>  p_ads_attribute_category
193       ,p_ads_attribute1                 =>  p_ads_attribute1
194       ,p_ads_attribute2                 =>  p_ads_attribute2
195       ,p_ads_attribute3                 =>  p_ads_attribute3
196       ,p_ads_attribute4                 =>  p_ads_attribute4
197       ,p_ads_attribute5                 =>  p_ads_attribute5
198       ,p_ads_attribute6                 =>  p_ads_attribute6
199       ,p_ads_attribute7                 =>  p_ads_attribute7
200       ,p_ads_attribute8                 =>  p_ads_attribute8
201       ,p_ads_attribute9                 =>  p_ads_attribute9
202       ,p_ads_attribute10                =>  p_ads_attribute10
203       ,p_ads_attribute11                =>  p_ads_attribute11
204       ,p_ads_attribute12                =>  p_ads_attribute12
205       ,p_ads_attribute13                =>  p_ads_attribute13
206       ,p_ads_attribute14                =>  p_ads_attribute14
207       ,p_ads_attribute15                =>  p_ads_attribute15
208       ,p_ads_attribute16                =>  p_ads_attribute16
209       ,p_ads_attribute17                =>  p_ads_attribute17
210       ,p_ads_attribute18                =>  p_ads_attribute18
211       ,p_ads_attribute19                =>  p_ads_attribute19
212       ,p_ads_attribute20                =>  p_ads_attribute20
213       ,p_ads_attribute21                =>  p_ads_attribute21
214       ,p_ads_attribute22                =>  p_ads_attribute22
215       ,p_ads_attribute23                =>  p_ads_attribute23
216       ,p_ads_attribute24                =>  p_ads_attribute24
217       ,p_ads_attribute25                =>  p_ads_attribute25
218       ,p_ads_attribute26                =>  p_ads_attribute26
219       ,p_ads_attribute27                =>  p_ads_attribute27
220       ,p_ads_attribute28                =>  p_ads_attribute28
221       ,p_ads_attribute29                =>  p_ads_attribute29
222       ,p_ads_attribute30                =>  p_ads_attribute30
223       ,p_object_version_number          =>  l_object_version_number
224       ,p_effective_date                      => trunc(p_effective_date)
225       );
226   exception
227     when hr_api.cannot_find_prog_unit then
228       hr_api.cannot_find_prog_unit_error
229         (p_module_name => 'CREATE_ACTY_RT_DEDUCT_SCHED'
230         ,p_hook_type   => 'AP'
231         );
232     --
233     -- End of API User Hook for the after hook of create_ACTY_RT_DEDUCT_SCHED
234     --
235   end;
236   --
237   hr_utility.set_location(l_proc, 60);
238   --
239   -- When in validation only mode raise the Validate_Enabled exception
240   --
241   if p_validate then
242     raise hr_api.validate_enabled;
243   end if;
244   --
245   -- Set all output arguments
246   --
247   p_acty_rt_ded_sched_id := l_acty_rt_ded_sched_id;
248   p_effective_start_date := l_effective_start_date;
249   p_effective_end_date := l_effective_end_date;
250   p_object_version_number := l_object_version_number;
251   --
252   hr_utility.set_location(' Leaving:'||l_proc, 70);
253   --
254 exception
255   --
256   when hr_api.validate_enabled then
257     --
258     -- As the Validate_Enabled exception has been raised
259     -- we must rollback to the savepoint
260     --
261     ROLLBACK TO create_ACTY_RT_DEDUCT_SCHED;
262     --
263     -- Only set output warning arguments
264     -- (Any key or derived arguments must be set to null
265     -- when validation only mode is being used.)
266     --
267     p_acty_rt_ded_sched_id := null;
268     p_effective_start_date := null;
269     p_effective_end_date := null;
270     p_object_version_number  := null;
271     hr_utility.set_location(' Leaving:'||l_proc, 80);
272     --
273   when others then
274     --
275     -- A validation or unexpected error has occured
276     --
277     ROLLBACK TO create_ACTY_RT_DEDUCT_SCHED;
278     -- NOCOPY Changes
279     p_acty_rt_ded_sched_id := null;
280     p_effective_start_date := null;
281     p_effective_end_date := null;
282     p_object_version_number := null ;
283     hr_utility.set_location(' Leaving:'||l_proc, 90);
284     raise;
285     --
286 end create_ACTY_RT_DEDUCT_SCHED;
287 -- ----------------------------------------------------------------------------
288 -- |------------------------< update_ACTY_RT_DEDUCT_SCHED >--- ------------------|
289 -- ----------------------------------------------------------------------------
290 --
291 procedure update_ACTY_RT_DEDUCT_SCHED
292   (p_validate                       in  boolean   default false
293   ,p_acty_rt_ded_sched_id           in  number
294   ,p_effective_start_date           out nocopy date
295   ,p_effective_end_date             out nocopy date
296   ,p_business_group_id              in  number    default hr_api.g_number
297   ,p_ded_sched_py_freq_id           in  number    default hr_api.g_number
298   ,p_acty_base_rt_id                in  number    default hr_api.g_number
299   ,p_ded_sched_rl                   in  number    default hr_api.g_number
300   ,p_ded_sched_cd                   in  varchar2  default hr_api.g_varchar2
301   ,p_ads_attribute_category         in  varchar2  default hr_api.g_varchar2
302   ,p_ads_attribute1                 in  varchar2  default hr_api.g_varchar2
303   ,p_ads_attribute2                 in  varchar2  default hr_api.g_varchar2
304   ,p_ads_attribute3                 in  varchar2  default hr_api.g_varchar2
305   ,p_ads_attribute4                 in  varchar2  default hr_api.g_varchar2
306   ,p_ads_attribute5                 in  varchar2  default hr_api.g_varchar2
307   ,p_ads_attribute6                 in  varchar2  default hr_api.g_varchar2
308   ,p_ads_attribute7                 in  varchar2  default hr_api.g_varchar2
309   ,p_ads_attribute8                 in  varchar2  default hr_api.g_varchar2
310   ,p_ads_attribute9                 in  varchar2  default hr_api.g_varchar2
311   ,p_ads_attribute10                in  varchar2  default hr_api.g_varchar2
312   ,p_ads_attribute11                in  varchar2  default hr_api.g_varchar2
313   ,p_ads_attribute12                in  varchar2  default hr_api.g_varchar2
314   ,p_ads_attribute13                in  varchar2  default hr_api.g_varchar2
315   ,p_ads_attribute14                in  varchar2  default hr_api.g_varchar2
316   ,p_ads_attribute15                in  varchar2  default hr_api.g_varchar2
317   ,p_ads_attribute16                in  varchar2  default hr_api.g_varchar2
321   ,p_ads_attribute20                in  varchar2  default hr_api.g_varchar2
318   ,p_ads_attribute17                in  varchar2  default hr_api.g_varchar2
319   ,p_ads_attribute18                in  varchar2  default hr_api.g_varchar2
320   ,p_ads_attribute19                in  varchar2  default hr_api.g_varchar2
322   ,p_ads_attribute21                in  varchar2  default hr_api.g_varchar2
323   ,p_ads_attribute22                in  varchar2  default hr_api.g_varchar2
324   ,p_ads_attribute23                in  varchar2  default hr_api.g_varchar2
325   ,p_ads_attribute24                in  varchar2  default hr_api.g_varchar2
326   ,p_ads_attribute25                in  varchar2  default hr_api.g_varchar2
327   ,p_ads_attribute26                in  varchar2  default hr_api.g_varchar2
328   ,p_ads_attribute27                in  varchar2  default hr_api.g_varchar2
329   ,p_ads_attribute28                in  varchar2  default hr_api.g_varchar2
330   ,p_ads_attribute29                in  varchar2  default hr_api.g_varchar2
331   ,p_ads_attribute30                in  varchar2  default hr_api.g_varchar2
332   ,p_object_version_number          in out nocopy number
333   ,p_effective_date                 in  date
334   ,p_datetrack_mode                 in  varchar2
335   ) is
336   --
337   -- Declare cursors and local variables
338   --
339   l_proc varchar2(72) := g_package||'update_ACTY_RT_DEDUCT_SCHED';
340   l_object_version_number ben_acty_rt_ded_sched_f.object_version_number%TYPE;
341   l_effective_start_date ben_acty_rt_ded_sched_f.effective_start_date%TYPE;
342   l_effective_end_date ben_acty_rt_ded_sched_f.effective_end_date%TYPE;
343   --
344 begin
345   --
346   hr_utility.set_location('Entering:'|| l_proc, 10);
347   --
348   -- Issue a savepoint if operating in validation only mode
349   --
350   savepoint update_ACTY_RT_DEDUCT_SCHED;
351   --
352   hr_utility.set_location(l_proc, 20);
353   --
354   -- Process Logic
355   --
356   l_object_version_number := p_object_version_number;
357   --
358   begin
359     --
360     -- Start of API User Hook for the before hook of update_ACTY_RT_DEDUCT_SCHED
361     --
362     ben_ACTY_RT_DEDUCT_SCHED_bk2.update_ACTY_RT_DEDUCT_SCHED_b
363       (
364        p_acty_rt_ded_sched_id           =>  p_acty_rt_ded_sched_id
365       ,p_business_group_id              =>  p_business_group_id
366       ,p_ded_sched_py_freq_id           =>  p_ded_sched_py_freq_id
367       ,p_acty_base_rt_id                =>  p_acty_base_rt_id
368       ,p_ded_sched_rl                   =>  p_ded_sched_rl
369       ,p_ded_sched_cd                   =>  p_ded_sched_cd
370       ,p_ads_attribute_category         =>  p_ads_attribute_category
371       ,p_ads_attribute1                 =>  p_ads_attribute1
372       ,p_ads_attribute2                 =>  p_ads_attribute2
373       ,p_ads_attribute3                 =>  p_ads_attribute3
374       ,p_ads_attribute4                 =>  p_ads_attribute4
375       ,p_ads_attribute5                 =>  p_ads_attribute5
376       ,p_ads_attribute6                 =>  p_ads_attribute6
377       ,p_ads_attribute7                 =>  p_ads_attribute7
378       ,p_ads_attribute8                 =>  p_ads_attribute8
379       ,p_ads_attribute9                 =>  p_ads_attribute9
380       ,p_ads_attribute10                =>  p_ads_attribute10
381       ,p_ads_attribute11                =>  p_ads_attribute11
382       ,p_ads_attribute12                =>  p_ads_attribute12
383       ,p_ads_attribute13                =>  p_ads_attribute13
384       ,p_ads_attribute14                =>  p_ads_attribute14
385       ,p_ads_attribute15                =>  p_ads_attribute15
386       ,p_ads_attribute16                =>  p_ads_attribute16
387       ,p_ads_attribute17                =>  p_ads_attribute17
388       ,p_ads_attribute18                =>  p_ads_attribute18
389       ,p_ads_attribute19                =>  p_ads_attribute19
390       ,p_ads_attribute20                =>  p_ads_attribute20
391       ,p_ads_attribute21                =>  p_ads_attribute21
392       ,p_ads_attribute22                =>  p_ads_attribute22
393       ,p_ads_attribute23                =>  p_ads_attribute23
394       ,p_ads_attribute24                =>  p_ads_attribute24
395       ,p_ads_attribute25                =>  p_ads_attribute25
396       ,p_ads_attribute26                =>  p_ads_attribute26
397       ,p_ads_attribute27                =>  p_ads_attribute27
398       ,p_ads_attribute28                =>  p_ads_attribute28
399       ,p_ads_attribute29                =>  p_ads_attribute29
400       ,p_ads_attribute30                =>  p_ads_attribute30
401       ,p_object_version_number          =>  p_object_version_number
402     ,p_effective_date                      => trunc(p_effective_date)
403     ,p_datetrack_mode                      => p_datetrack_mode
404       );
405   exception
406     when hr_api.cannot_find_prog_unit then
407       hr_api.cannot_find_prog_unit_error
408         (p_module_name => 'UPDATE_ACTY_RT_DEDUCT_SCHED'
409         ,p_hook_type   => 'BP'
410         );
411     --
412     -- End of API User Hook for the before hook of update_ACTY_RT_DEDUCT_SCHED
413     --
414   end;
415   --
416   ben_ads_upd.upd
417     (
418      p_acty_rt_ded_sched_id          => p_acty_rt_ded_sched_id
419     ,p_effective_start_date          => l_effective_start_date
420     ,p_effective_end_date            => l_effective_end_date
421     ,p_business_group_id             => p_business_group_id
422     ,p_ded_sched_py_freq_id          => p_ded_sched_py_freq_id
426     ,p_ads_attribute_category        => p_ads_attribute_category
423     ,p_acty_base_rt_id               => p_acty_base_rt_id
424     ,p_ded_sched_rl                  => p_ded_sched_rl
425     ,p_ded_sched_cd                  => p_ded_sched_cd
427     ,p_ads_attribute1                => p_ads_attribute1
428     ,p_ads_attribute2                => p_ads_attribute2
429     ,p_ads_attribute3                => p_ads_attribute3
430     ,p_ads_attribute4                => p_ads_attribute4
431     ,p_ads_attribute5                => p_ads_attribute5
432     ,p_ads_attribute6                => p_ads_attribute6
433     ,p_ads_attribute7                => p_ads_attribute7
434     ,p_ads_attribute8                => p_ads_attribute8
435     ,p_ads_attribute9                => p_ads_attribute9
436     ,p_ads_attribute10               => p_ads_attribute10
437     ,p_ads_attribute11               => p_ads_attribute11
438     ,p_ads_attribute12               => p_ads_attribute12
439     ,p_ads_attribute13               => p_ads_attribute13
440     ,p_ads_attribute14               => p_ads_attribute14
441     ,p_ads_attribute15               => p_ads_attribute15
442     ,p_ads_attribute16               => p_ads_attribute16
443     ,p_ads_attribute17               => p_ads_attribute17
444     ,p_ads_attribute18               => p_ads_attribute18
445     ,p_ads_attribute19               => p_ads_attribute19
446     ,p_ads_attribute20               => p_ads_attribute20
447     ,p_ads_attribute21               => p_ads_attribute21
448     ,p_ads_attribute22               => p_ads_attribute22
449     ,p_ads_attribute23               => p_ads_attribute23
450     ,p_ads_attribute24               => p_ads_attribute24
451     ,p_ads_attribute25               => p_ads_attribute25
452     ,p_ads_attribute26               => p_ads_attribute26
453     ,p_ads_attribute27               => p_ads_attribute27
454     ,p_ads_attribute28               => p_ads_attribute28
455     ,p_ads_attribute29               => p_ads_attribute29
456     ,p_ads_attribute30               => p_ads_attribute30
457     ,p_object_version_number         => l_object_version_number
458     ,p_effective_date                => trunc(p_effective_date)
459     ,p_datetrack_mode                => p_datetrack_mode
460     );
461   --
462   begin
463     --
464     -- Start of API User Hook for the after hook of update_ACTY_RT_DEDUCT_SCHED
465     --
466     ben_ACTY_RT_DEDUCT_SCHED_bk2.update_ACTY_RT_DEDUCT_SCHED_a
467       (
468        p_acty_rt_ded_sched_id           =>  p_acty_rt_ded_sched_id
469       ,p_effective_start_date           =>  l_effective_start_date
470       ,p_effective_end_date             =>  l_effective_end_date
471       ,p_business_group_id              =>  p_business_group_id
472       ,p_ded_sched_py_freq_id           =>  p_ded_sched_py_freq_id
473       ,p_acty_base_rt_id                =>  p_acty_base_rt_id
474       ,p_ded_sched_rl                   =>  p_ded_sched_rl
475       ,p_ded_sched_cd                   =>  p_ded_sched_cd
476       ,p_ads_attribute_category         =>  p_ads_attribute_category
477       ,p_ads_attribute1                 =>  p_ads_attribute1
478       ,p_ads_attribute2                 =>  p_ads_attribute2
479       ,p_ads_attribute3                 =>  p_ads_attribute3
480       ,p_ads_attribute4                 =>  p_ads_attribute4
481       ,p_ads_attribute5                 =>  p_ads_attribute5
482       ,p_ads_attribute6                 =>  p_ads_attribute6
483       ,p_ads_attribute7                 =>  p_ads_attribute7
484       ,p_ads_attribute8                 =>  p_ads_attribute8
485       ,p_ads_attribute9                 =>  p_ads_attribute9
486       ,p_ads_attribute10                =>  p_ads_attribute10
487       ,p_ads_attribute11                =>  p_ads_attribute11
488       ,p_ads_attribute12                =>  p_ads_attribute12
489       ,p_ads_attribute13                =>  p_ads_attribute13
490       ,p_ads_attribute14                =>  p_ads_attribute14
491       ,p_ads_attribute15                =>  p_ads_attribute15
492       ,p_ads_attribute16                =>  p_ads_attribute16
493       ,p_ads_attribute17                =>  p_ads_attribute17
494       ,p_ads_attribute18                =>  p_ads_attribute18
495       ,p_ads_attribute19                =>  p_ads_attribute19
496       ,p_ads_attribute20                =>  p_ads_attribute20
497       ,p_ads_attribute21                =>  p_ads_attribute21
498       ,p_ads_attribute22                =>  p_ads_attribute22
499       ,p_ads_attribute23                =>  p_ads_attribute23
500       ,p_ads_attribute24                =>  p_ads_attribute24
501       ,p_ads_attribute25                =>  p_ads_attribute25
502       ,p_ads_attribute26                =>  p_ads_attribute26
503       ,p_ads_attribute27                =>  p_ads_attribute27
504       ,p_ads_attribute28                =>  p_ads_attribute28
505       ,p_ads_attribute29                =>  p_ads_attribute29
506       ,p_ads_attribute30                =>  p_ads_attribute30
507       ,p_object_version_number          =>  l_object_version_number
508       ,p_effective_date                     => trunc(p_effective_date)
509       ,p_datetrack_mode                     => p_datetrack_mode
510       );
511   exception
512     when hr_api.cannot_find_prog_unit then
513       hr_api.cannot_find_prog_unit_error
514         (p_module_name => 'UPDATE_ACTY_RT_DEDUCT_SCHED'
515         ,p_hook_type   => 'AP'
516         );
517     --
518     -- End of API User Hook for the after hook of update_ACTY_RT_DEDUCT_SCHED
519     --
520   end;
521   --
522   hr_utility.set_location(l_proc, 60);
523   --
527     raise hr_api.validate_enabled;
524   -- When in validation only mode raise the Validate_Enabled exception
525   --
526   if p_validate then
528   end if;
529   --
530   -- Set all output arguments
531   --
532   p_object_version_number := l_object_version_number;
533   p_effective_start_date := l_effective_start_date;
534   p_effective_end_date := l_effective_end_date;
535   --
536   hr_utility.set_location(' Leaving:'||l_proc, 70);
537   --
538 exception
539   --
540   when hr_api.validate_enabled then
541     --
542     -- As the Validate_Enabled exception has been raised
543     -- we must rollback to the savepoint
544     --
545     ROLLBACK TO update_ACTY_RT_DEDUCT_SCHED;
546     --
547     -- Only set output warning arguments
548     -- (Any key or derived arguments must be set to null
549     -- when validation only mode is being used.)
550     --
551     hr_utility.set_location(' Leaving:'||l_proc, 80);
552     --
553   when others then
554     --
555     -- A validation or unexpected error has occured
556     --
557     ROLLBACK TO update_ACTY_RT_DEDUCT_SCHED;
558     -- NOCOPY Changes
559     p_effective_start_date := null;
560     p_effective_end_date := null;
561     p_object_version_number := l_object_version_number ;
562     hr_utility.set_location(' Leaving:'||l_proc, 90);
563     raise;
564     --
565 end update_ACTY_RT_DEDUCT_SCHED;
566 -- ----------------------------------------------------------------------------
567 -- |------------------------< delete_ACTY_RT_DEDUCT_SCHED >----------------------|
568 -- ----------------------------------------------------------------------------
569 --
570 procedure delete_ACTY_RT_DEDUCT_SCHED
571   (p_validate                       in  boolean  default false
572   ,p_acty_rt_ded_sched_id           in  number
573   ,p_effective_start_date           out nocopy date
574   ,p_effective_end_date             out nocopy date
575   ,p_object_version_number          in out nocopy number
576   ,p_effective_date                 in  date
577   ,p_datetrack_mode                 in  varchar2
578   ) is
579   --
580   -- Declare cursors and local variables
581   --
582   l_proc varchar2(72) := g_package||'update_ACTY_RT_DEDUCT_SCHED';
583   l_object_version_number ben_acty_rt_ded_sched_f.object_version_number%TYPE;
584   l_effective_start_date ben_acty_rt_ded_sched_f.effective_start_date%TYPE;
585   l_effective_end_date ben_acty_rt_ded_sched_f.effective_end_date%TYPE;
586   --
587 begin
588   --
589   hr_utility.set_location('Entering:'|| l_proc, 10);
590   --
591   -- Issue a savepoint if operating in validation only mode
592   --
593   savepoint delete_ACTY_RT_DEDUCT_SCHED;
594   --
595   hr_utility.set_location(l_proc, 20);
596   --
597   -- Process Logic
598   --
599   l_object_version_number := p_object_version_number;
600   --
601   --
602   begin
603     --
604     -- Start of API User Hook for the before hook of delete_ACTY_RT_DEDUCT_SCHED
605     --
606     ben_ACTY_RT_DEDUCT_SCHED_bk3.delete_ACTY_RT_DEDUCT_SCHED_b
607       (
608        p_acty_rt_ded_sched_id           =>  p_acty_rt_ded_sched_id
609       ,p_object_version_number          =>  p_object_version_number
610     ,p_effective_date                      => trunc(p_effective_date)
611     ,p_datetrack_mode                      => p_datetrack_mode
612       );
613   exception
614     when hr_api.cannot_find_prog_unit then
615       hr_api.cannot_find_prog_unit_error
616         (p_module_name => 'DELETE_ACTY_RT_DEDUCT_SCHED'
617         ,p_hook_type   => 'BP'
618         );
619     --
620     -- End of API User Hook for the before hook of delete_ACTY_RT_DEDUCT_SCHED
621     --
622   end;
623   --
624   ben_ads_del.del
625     (
626      p_acty_rt_ded_sched_id          => p_acty_rt_ded_sched_id
627     ,p_effective_start_date          => l_effective_start_date
628     ,p_effective_end_date            => l_effective_end_date
629     ,p_object_version_number         => l_object_version_number
630     ,p_effective_date                => p_effective_date
631     ,p_datetrack_mode                => p_datetrack_mode
632     );
633   --
634   begin
635     --
636     -- Start of API User Hook for the after hook of delete_ACTY_RT_DEDUCT_SCHED
637     --
638     ben_ACTY_RT_DEDUCT_SCHED_bk3.delete_ACTY_RT_DEDUCT_SCHED_a
639       (
640        p_acty_rt_ded_sched_id           =>  p_acty_rt_ded_sched_id
641       ,p_effective_start_date           =>  l_effective_start_date
642       ,p_effective_end_date             =>  l_effective_end_date
643       ,p_object_version_number          =>  l_object_version_number
644     ,p_effective_date                      => trunc(p_effective_date)
645     ,p_datetrack_mode                      => p_datetrack_mode
646       );
647   exception
648     when hr_api.cannot_find_prog_unit then
649       hr_api.cannot_find_prog_unit_error
650         (p_module_name => 'DELETE_ACTY_RT_DEDUCT_SCHED'
651         ,p_hook_type   => 'AP'
652         );
653     --
654     -- End of API User Hook for the after hook of delete_ACTY_RT_DEDUCT_SCHED
655     --
656   end;
657   --
658   hr_utility.set_location(l_proc, 60);
659   --
660   -- When in validation only mode raise the Validate_Enabled exception
661   --
662   if p_validate then
663     raise hr_api.validate_enabled;
664   end if;
668 exception
665   --
666   hr_utility.set_location(' Leaving:'||l_proc, 70);
667   --
669   --
670   when hr_api.validate_enabled then
671     --
672     -- As the Validate_Enabled exception has been raised
673     -- we must rollback to the savepoint
674     --
675     ROLLBACK TO delete_ACTY_RT_DEDUCT_SCHED;
676     --
677     -- Only set output warning arguments
678     -- (Any key or derived arguments must be set to null
679     -- when validation only mode is being used.)
680     --
681     p_effective_start_date := null;
682     p_effective_end_date := null;
683     --
684   when others then
685     --
686     -- A validation or unexpected error has occured
687     --
688     ROLLBACK TO delete_ACTY_RT_DEDUCT_SCHED;
689     -- NOCOPY Changes
690     p_effective_start_date := null;
691     p_effective_end_date := null;
692     p_object_version_number := l_object_version_number ;
693     hr_utility.set_location(' Leaving:'||l_proc, 90);
694     raise;
695     --
696 end delete_ACTY_RT_DEDUCT_SCHED;
697 --
698 -- ----------------------------------------------------------------------------
699 -- |-------------------------------< lck >------------------------------------|
700 -- ----------------------------------------------------------------------------
701 --
702 procedure lck
703   (
704    p_acty_rt_ded_sched_id                   in     number
705   ,p_object_version_number          in     number
706   ,p_effective_date                 in     date
707   ,p_datetrack_mode                 in     varchar2
708   ,p_validation_start_date          out nocopy    date
709   ,p_validation_end_date            out nocopy    date
710   ) is
711   --
712   --
713   -- Declare cursors and local variables
714   --
715   l_proc varchar2(72) := g_package||'lck';
716   l_validation_start_date date;
717   l_validation_end_date date;
718   --
719 begin
720   --
721   hr_utility.set_location('Entering:'|| l_proc, 10);
722   --
723   ben_ads_shd.lck
724     (
725       p_acty_rt_ded_sched_id                 => p_acty_rt_ded_sched_id
726      ,p_validation_start_date      => l_validation_start_date
727      ,p_validation_end_date        => l_validation_end_date
728      ,p_object_version_number      => p_object_version_number
729      ,p_effective_date             => p_effective_date
730      ,p_datetrack_mode             => p_datetrack_mode
731     );
732   --
733   hr_utility.set_location(' Leaving:'||l_proc, 70);
734   --
735 end lck;
736 --
737 end ben_ACTY_RT_DEDUCT_SCHED_api;