DBA Data[Home] [Help]

PACKAGE: APPS.PY_FI_TAX_CARD

Source


1 PACKAGE py_fi_tax_card AS
2 /* $Header: pyfitaxc.pkh 120.1 2007/02/22 11:51:18 dbehera noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |--------------------------------< ins >---------------------------------|
6 -- ----------------------------------------------------------------------------
7 -- {Start Of Comments}
8 --
9 -- Description:
10 --      This API will insert a tax and tax card entry for a Finland Assignment.
11 --      This API delegates to the create_element_entry procedure of the
12 --      pay_element_entry_api package.
13 --
14 -- Prerequisites:
15 --      The element link should exist for the given assignment
16 --      and business group.
17 --
18 -- In Parameters:
19 --      Name                            Reqd            Type                    Description
20 --      p_legislation_code              Yes             VARCHAR2                The Legislation Code.
21 --      p_effective_date                Yes             DATE                    The current effective date
22 --      p_assignment_id                 Yes             VARCHAR2                Assignment ID of the record.
23 --      p_person_id                     Yes             VARCHAR2                Person ID for the record.
24 --      p_business_group_id             Yes             VARCHAR2                Current Business Group Id.
25 --      p_element_entry_id_tc           Yes             VARCHAR2                Element entry Id for Tax Card Element.
26 --      p_element_entry_id_t            Yes             VARCHAR2                Element entry Id for Tax Element.
27 --      p_taxcard_type                                  VARCHAR2                Tax Card Type.
28 --      p_method_of_receipt                             VARCHAR2                Method of Receipt.
29 --      p_base_rate                                     NUMBER                  Base Rate.
30 --      p_tax_municipality                              VARCHAR2                Tax Municipality
31 --      p_additional_rate                               NUMBER                  Additional Rate.
32 --      p_override_manual_upd                           VARCHAR2                Override Manual Update Flag.
33 --      p_previous_income                               NUMBER                  Previous Income.
34 --      p_yearly_income_limit                           NUMBER                  Yearly Income Limit.
35 --      p_date_returned                                 DATE                    Date Returned.
36 --      p_registration_date                             DATE                    Registration Date.
37 --      p_lower_income_percentage          Number                Lower Income Percentage
38 --      p_primary_employment                            VARCHAR2                Primary Employment Flag.
39 --      p_extra_income_rate                             NUMBER                  Extra Income Rate.
40 --      p_extra_income_add_rate                         NUMBER                  Extra Income Additional Rate.
41 --      p_extra_income_limit                            NUMBER                  Extra Income Limit.
42 --      p_prev_extra_income                             NUMBER                  Previous Extra Income.
43 --
44 -- Post Success:
45 --      The API successfully inserts a tax card and/or tax entry.
46 --
47 -- Post Failure:
48 --      The API will raise an error.
49 --
50 -- Access Status:
51 --      Private. For Internal Development Use only.
52 --
53 -- {End Of Comments}
54 --
55    PROCEDURE ins (
56         p_legislation_code              IN      VARCHAR2
57         ,p_effective_date               IN      DATE
58         ,p_assignment_id                IN      VARCHAR2
59         ,p_person_id                    IN      VARCHAR2
60         ,p_business_group_id            IN      VARCHAR2
61         ,p_element_entry_id_tc          IN      VARCHAR2
62         ,p_element_entry_id_t           IN      VARCHAR2
63         ,p_taxcard_type                 IN      VARCHAR2        DEFAULT NULL
64         ,p_method_of_receipt            IN      VARCHAR2        DEFAULT NULL
65         ,p_base_rate                    IN      NUMBER          DEFAULT NULL
66         ,p_tax_municipality             IN      VARCHAR2        DEFAULT NULL
67         ,p_additional_rate              IN      NUMBER          DEFAULT NULL
68         ,p_override_manual_upd          IN      VARCHAR2        DEFAULT NULL
69         ,p_previous_income              IN      NUMBER          DEFAULT NULL
70         ,p_yearly_income_limit          IN      NUMBER          DEFAULT NULL
71         ,p_date_returned                IN      DATE            DEFAULT NULL
72         ,p_registration_date            IN      DATE            DEFAULT NULL
73 	,p_lower_income_percentage          IN      NUMBER          DEFAULT NULL
74         ,p_primary_employment           IN      VARCHAR2        DEFAULT NULL
75         ,p_extra_income_rate            IN      NUMBER          DEFAULT NULL
76         ,p_extra_income_add_rate        IN      NUMBER          DEFAULT NULL
77         ,p_extra_income_limit           IN      NUMBER          DEFAULT NULL
78         ,p_prev_extra_income            IN      NUMBER          DEFAULT NULL);
79 --
80 -- ----------------------------------------------------------------------------
81 -- |----------------------< insert_taxcard >----------------------------------|
82 -- ----------------------------------------------------------------------------
83 -- {Start Of Comments}
84 --
85 -- Description:
86 --      This API will insert a tax card entry for a Finland Assignment.
87 --      This API delegates to the create_element_entry procedure of the
88 --      pay_element_entry_api package.
89 --
90 -- Prerequisites:
91 --      The element link should exist for the given assignment
92 --      and business group.
93 --
94 -- In Parameters:
95 --      Name                            Reqd            Type                    Description
96 --      p_legislation_code              Yes             VARCHAR2                The Legislation Code.
97 --      p_effective_date                Yes             DATE                    The current effective date
98 --      p_assignment_id                 Yes             VARCHAR2                Assignment ID of the record.
99 --      p_person_id                     Yes             VARCHAR2                Person ID for the record.
100 --      p_business_group_id             Yes             VARCHAR2                Current Business Group Id.
101 --      p_element_entry_id_tc           Yes             VARCHAR2                Element entry Id for Tax Card Element.
102 --      p_element_entry_id_t            Yes             VARCHAR2                Element entry Id for Tax Element.
103 --      p_taxcard_type                                  VARCHAR2                Tax Card Type.
104 --      p_method_of_receipt                             VARCHAR2                Method of Receipt.
105 --      p_base_rate                                     NUMBER                  Base Rate.
106 --      p_tax_municipality                              VARCHAR2                Tax Municipality
107 --      p_additional_rate                               NUMBER                  Additional Rate.
108 --      p_override_manual_upd                           VARCHAR2                Override Manual Update Flag.
109 --      p_previous_income                               NUMBER                  Previous Income.
110 --      p_yearly_income_limit                           NUMBER                  Yearly Income Limit.
111 --      p_date_returned                                 DATE                    Date Returned.
112 --      p_registration_date                             DATE                    Registration Date.
113 --      p_lower_income_percentage          Number                Lower Income Percentage
114 --
115 -- Post Success:
116 --      The API successfully inserts the tax card entry.
117 --
118 -- Post Failure:
119 --      The API will raise an error.
120 --
121 -- Access Status:
122 --      Private. For Internal Development Use only.
123 --
124 -- {End Of Comments}
125 --
126 PROCEDURE insert_taxcard (
127         p_legislation_code              IN      VARCHAR2
128         ,p_effective_date               IN      DATE
129         ,p_assignment_id                IN      VARCHAR2
130         ,p_person_id                    IN      VARCHAR2
131         ,p_business_group_id            IN      VARCHAR2
132         ,p_element_entry_id_tc          IN      VARCHAR2
133         ,p_taxcard_type                 IN      VARCHAR2        DEFAULT NULL
134         ,p_method_of_receipt            IN      VARCHAR2        DEFAULT NULL
135         ,p_base_rate                    IN      NUMBER          DEFAULT NULL
136         ,p_tax_municipality             IN      VARCHAR2        DEFAULT NULL
137         ,p_additional_rate              IN      NUMBER          DEFAULT NULL
138         ,p_override_manual_upd          IN      VARCHAR2        DEFAULT NULL
139         ,p_previous_income              IN      NUMBER          DEFAULT NULL
140         ,p_yearly_income_limit          IN      NUMBER          DEFAULT NULL
141         ,p_date_returned                IN      DATE            DEFAULT NULL
142         ,p_registration_date            IN      DATE            DEFAULT NULL
143 	,p_lower_income_percentage              IN      NUMBER          DEFAULT NULL);
144 --
145 -- ----------------------------------------------------------------------------
146 -- |------------------------< insert_tax >-------------------------------------|
147 -- ----------------------------------------------------------------------------
148 -- {Start Of Comments}
149 --
150 -- Description:
151 --      This API will insert a tax  entry for a Finland Assignment.
152 --      This API delegates to the create_element_entry procedure of the
153 --      pay_element_entry_api package.
154 --
155 -- Prerequisites:
156 --      The element link should exist for the given assignment
157 --      and business group.
158 --
159 -- In Parameters:
160 --      Name                            Reqd            Type                    Description
161 --      p_legislation_code              Yes             VARCHAR2                The Legislation Code.
162 --      p_effective_date                Yes             DATE                    The current effective date
163 --      p_assignment_id                 Yes             VARCHAR2                Assignment ID of the record.
164 --      p_person_id                     Yes             VARCHAR2                Person ID for the record.
165 --      p_business_group_id             Yes             VARCHAR2                Current Business Group Id.
166 --      p_element_entry_id_tc           Yes             VARCHAR2                Element entry Id for Tax Card Element.
167 --      p_element_entry_id_t            Yes             VARCHAR2                Element entry Id for Tax Element.
168 --      p_primary_employment                            VARCHAR2                Primary Employment Flag.
169 --      p_extra_income_rate                             NUMBER                  Extra Income Rate.
170 --      p_extra_income_add_rate                         NUMBER                  Extra Income Additional Rate.
171 --      p_extra_income_limit                            NUMBER                  Extra Income Limit.
172 --      p_prev_extra_income                             NUMBER                  Previous Extra Income.
173 --
174 -- Post Success:
175 --      The API successfully inserts the tax card entry.
176 --
177 -- Post Failure:
178 --      The API will raise an error.
179 --
180 -- Access Status:
181 --      Private. For Internal Development Use only.
182 --
183 -- {End Of Comments}
184 --
185   PROCEDURE insert_tax (
186         p_legislation_code              IN      VARCHAR2
187         ,p_effective_date               IN      DATE
188         ,p_assignment_id                IN      VARCHAR2
189         ,p_person_id                    IN      VARCHAR2
190         ,p_business_group_id            IN      VARCHAR2
191         ,p_element_entry_id_t           IN      VARCHAR2
192         ,p_primary_employment           IN      VARCHAR2        DEFAULT NULL
193         ,p_extra_income_rate            IN      NUMBER          DEFAULT NULL
194         ,p_extra_income_add_rate        IN      NUMBER          DEFAULT NULL
195         ,p_extra_income_limit           IN      NUMBER          DEFAULT NULL
196         ,p_prev_extra_income            IN      NUMBER          DEFAULT NULL);
197 --
198 -- ----------------------------------------------------------------------------
199 -- |--------------------------------< upd >-----------------------------------|
200 -- ----------------------------------------------------------------------------
201 -- {Start Of Comments}
202 --
203 -- Description:
204 --      This API will update a tax and tax card entry for a Finland Assignment.
205 --      This API delegates to the update_element_entry procedure of the
206 --      pay_element_entry_api package.
207 --
208 -- Prerequisites:
212 --
209 --      The element entry (of element type 'Tax Card' and 'Tax) and the
210 --      corresponding element link should exist for the given assignment
211 --      and business group.
213 -- In Parameters:
214 --      Name                            Reqd            Type                    Description
215 --      p_legislation_code              Yes             VARCHAR2                The Legislation Code.
216 --      p_effective_date                Yes             DATE                    The current effective date
217 --      p_assignment_id                 Yes             VARCHAR2                Assignment ID of the record.
218 --      p_person_id                     Yes             VARCHAR2                Person ID for the record.
219 --      p_business_group_id             Yes             VARCHAR2                Current Business Group Id.
220 --      p_element_entry_id_tc           Yes             VARCHAR2                Element entry Id for Tax Card Element.
221 --      p_element_entry_id_t            Yes             VARCHAR2                Element entry Id for Tax Element.
222 --      p_taxcard_type                                  VARCHAR2                Tax Card Type.
223 --      p_method_of_receipt                             VARCHAR2                Method of Receipt.
224 --      p_base_rate                                     NUMBER                  Base Rate.
225 --      p_tax_municipality                              VARCHAR2                Tax Municipality
226 --      p_additional_rate                               NUMBER                  Additional Rate.
227 --      p_override_manual_upd                           VARCHAR2                Override Manual Update Flag.
228 --      p_previous_income                               NUMBER                  Previous Income.
229 --      p_yearly_income_limit                           NUMBER                  Yearly Income Limit.
230 --      p_date_returned                                 DATE                    Date Returned.
231 --      p_registration_date                             DATE                    Registration Date.
232 --      p_lower_income_percentage          Number                Lower Income Percentage
233 --      p_primary_employment                            VARCHAR2                Primary Employment Flag.
234 --      p_extra_income_rate                             NUMBER                  Extra Income Rate.
235 --      p_extra_income_add_rate                         NUMBER                  Extra Income Additional Rate.
236 --      p_extra_income_limit                            NUMBER                  Extra Income Limit.
237 --      p_prev_extra_income                             NUMBER                  Previous Extra Income.
238 --      p_input_value_id1                               VARCHAR2                Input Value Id for Entry 1
239 --      p_input_value_id2                               VARCHAR2                Input Value Id for Entry 2
240 --      p_input_value_id3                               VARCHAR2                Input Value Id for Entry 3
241 --      p_input_value_id4                               VARCHAR2                Input Value Id for Entry 4
242 --      p_input_value_id5                               VARCHAR2                Input Value Id for Entry 5
243 --      p_input_value_id6                               VARCHAR2                Input Value Id for Entry 6
244 --      p_input_value_id7                               VARCHAR2                Input Value Id for Entry 7
245 --      p_input_value_id8                               VARCHAR2                Input Value Id for Entry 8
246 --      p_input_value_id9                               VARCHAR2                Input Value Id for Entry 9
247 --      p_input_value_id10                              VARCHAR2                Input Value Id for Entry 10
248 --      p_input_value_id11                              VARCHAR2                Input Value Id for Entry 11
249 --      p_input_value_id12                              VARCHAR2                Input Value Id for Entry 12
250 --      p_input_value_id13                              VARCHAR2                Input Value Id for Entry 13
251 --      p_input_value_id14                              VARCHAR2                Input Value Id for Entry 14
252 --      p_input_value_id15                              VARCHAR2                Input Value Id for Entry 15
253 --      p_input_value_id16                              VARCHAR2                Input Value Id for Entry 16
254 --      p_datetrack_update_mode                         VARCHAR2                The date track mode.
255 --      p_object_version_number_tc                      VARCHAR2                Object Version Number for Tax Card.
256 --      p_object_version_number_t                       VARCHAR2                Object Version Number for Tax.
257 --
258 -- Post Success:
259 --      The API successfully updates the tax card and/or tax entry.
260 --
261 -- Post Failure:
262 --      The API will raise an error.
263 --
264 -- Access Status:
265 --      Private. For Internal Development Use only.
266 --
267 -- {End Of Comments}
268 --
269 PROCEDURE upd (
270         p_legislation_code                      IN      VARCHAR2
271         ,p_effective_date                       IN      DATE
272         ,p_assignment_id                        IN      VARCHAR2
273         ,p_person_id                            IN      VARCHAR2
274         ,p_business_group_id                    IN      VARCHAR2
275         ,p_element_entry_id_tc                  IN      VARCHAR2
276         ,p_element_entry_id_t                   IN      VARCHAR2
277         ,p_taxcard_type                         IN      VARCHAR2        DEFAULT NULL
278         ,p_method_of_receipt                    IN      VARCHAR2        DEFAULT NULL
279         ,p_base_rate                            IN      NUMBER          DEFAULT NULL
280         ,p_tax_municipality                     IN      VARCHAR2        DEFAULT NULL
281         ,p_additional_rate                      IN      NUMBER          DEFAULT NULL
285         ,p_date_returned                        IN      DATE            DEFAULT NULL
282         ,p_override_manual_upd                  IN      VARCHAR2        DEFAULT NULL
283         ,p_previous_income                      IN      NUMBER          DEFAULT NULL
284         ,p_yearly_income_limit                  IN      NUMBER          DEFAULT NULL
286         ,p_registration_date                    IN      DATE            DEFAULT NULL
287 	,p_lower_income_percentage  IN      NUMBER          DEFAULT NULL
288         ,p_primary_employment                   IN      VARCHAR2        DEFAULT NULL
289         ,p_extra_income_rate                    IN      NUMBER          DEFAULT NULL
290         ,p_extra_income_add_rate                IN      NUMBER          DEFAULT NULL
291         ,p_extra_income_limit                   IN      NUMBER          DEFAULT NULL
292         ,p_prev_extra_income                    IN      NUMBER          DEFAULT NULL
293         ,p_input_value_id1                      IN      VARCHAR2        DEFAULT NULL
294         ,p_input_value_id2                      IN      VARCHAR2        DEFAULT NULL
295         ,p_input_value_id3                      IN      VARCHAR2        DEFAULT NULL
296         ,p_input_value_id4                      IN      VARCHAR2        DEFAULT NULL
297         ,p_input_value_id5                      IN      VARCHAR2        DEFAULT NULL
298         ,p_input_value_id6                      IN      VARCHAR2        DEFAULT NULL
299         ,p_input_value_id7                      IN      VARCHAR2        DEFAULT NULL
300         ,p_input_value_id8                      IN      VARCHAR2        DEFAULT NULL
301         ,p_input_value_id9                      IN      VARCHAR2        DEFAULT NULL
302         ,p_input_value_id10                     IN      VARCHAR2        DEFAULT NULL
303         ,p_input_value_id11                     IN      VARCHAR2        DEFAULT NULL
304         ,p_input_value_id12                     IN      VARCHAR2        DEFAULT NULL
305         ,p_input_value_id13                     IN      VARCHAR2        DEFAULT NULL
306         ,p_input_value_id14                     IN      VARCHAR2        DEFAULT NULL
307         ,p_input_value_id15                     IN      VARCHAR2        DEFAULT NULL
308        ,p_input_value_id16                     IN      VARCHAR2        DEFAULT NULL
309         ,p_datetrack_update_mode                IN      VARCHAR2        DEFAULT NULL
310         ,p_object_version_number_tc             IN      VARCHAR2
311         ,p_object_version_number_t              IN      VARCHAR2        DEFAULT NULL);
312 --
313 -- ----------------------------------------------------------------------------
314 -- |----------------------< update_taxcard >----------------------------------|
315 -- ----------------------------------------------------------------------------
316 -- {Start Of Comments}
317 --
318 -- Description:
319 --      This API will update a tax card entry for a Finland Assignment.
320 --      This API delegates to the update_element_entry procedure of the
321 --      pay_element_entry_api package.
322 --
323 -- Prerequisites:
324 --      The element entry (of element type 'Tax Card' ) and the
325 --      corresponding element link should exist for the given assignment
326 --      and business group.
327 --
328 -- In Parameters:
329 --      Name                            Reqd            Type                    Description
330 --      p_legislation_code              Yes             VARCHAR2                The Legislation Code.
331 --      p_effective_date                Yes             DATE                    The current effective date
332 --      p_assignment_id                 Yes             VARCHAR2                Assignment ID of the record.
333 --      p_person_id                     Yes             VARCHAR2                Person ID for the record.
334 --      p_business_group_id             Yes             VARCHAR2                Current Business Group Id.
335 --      p_element_entry_id_tc           Yes             VARCHAR2                Element entry Id for Tax Card Element.
336 --      p_taxcard_type                                  VARCHAR2                Tax Card Type.
337 --      p_method_of_receipt                             VARCHAR2                Method of Receipt.
338 --      p_base_rate                                     NUMBER                  Base Rate.
339 --      p_tax_municipality                              VARCHAR2                Tax Municipality
340 --      p_additional_rate                               NUMBER                  Additional Rate.
341 --      p_override_manual_upd                           VARCHAR2                Override Manual Update Flag.
342 --      p_previous_income                               NUMBER                  Previous Income.
343 --      p_yearly_income_limit                           NUMBER                  Yearly Income Limit.
344 --      p_date_returned                                 DATE                    Date Returned.
345 --      p_registration_date                             DATE                    Registration Date.
346 --      p_lower_income_percentage          Number                Lower Income Percentage
347 --      p_input_value_id1                               VARCHAR2                Input Value Id for Entry 1
348 --      p_input_value_id2                               VARCHAR2                Input Value Id for Entry 2
349 --      p_input_value_id3                               VARCHAR2                Input Value Id for Entry 3
350 --      p_input_value_id4                               VARCHAR2                Input Value Id for Entry 4
351 --      p_input_value_id5                               VARCHAR2                Input Value Id for Entry 5
352 --      p_input_value_id6                               VARCHAR2                Input Value Id for Entry 6
353 --      p_input_value_id7                               VARCHAR2                Input Value Id for Entry 7
357 --      p_input_value_id11                              VARCHAR2                Input Value Id for Entry 11
354 --      p_input_value_id8                               VARCHAR2                Input Value Id for Entry 8
355 --      p_input_value_id9                               VARCHAR2                Input Value Id for Entry 9
356 --      p_input_value_id10                              VARCHAR2                Input Value Id for Entry 10
358 --      p_datetrack_update_mode                         VARCHAR2                The date track mode.
359 --      p_object_version_number                         VARCHAR2                Object Version Number for Tax Card.
360 --
361 -- Post Success:
362 --      The API successfully updates the tax card and/or tax entry.
363 --
364 -- Post Failure:
365 --      The API will raise an error.
366 --
367 -- Access Status:
368 --      Private. For Internal Development Use only.
369 --
370 -- {End Of Comments}
371 --
372         PROCEDURE update_taxcard (
373         p_legislation_code              IN      VARCHAR2
374         ,p_effective_date               IN      DATE
375         ,p_assignment_id                IN      VARCHAR2
376         ,p_person_id                    IN      VARCHAR2
377         ,p_business_group_id            IN      VARCHAR2
378         ,p_element_entry_id_tc          IN      VARCHAR2
379         ,p_taxcard_type                 IN      VARCHAR2        DEFAULT NULL
380         ,p_method_of_receipt            IN      VARCHAR2        DEFAULT NULL
381         ,p_base_rate                    IN      NUMBER          DEFAULT NULL
382         ,p_tax_municipality             IN      VARCHAR2        DEFAULT NULL
383         ,p_additional_rate              IN      NUMBER          DEFAULT NULL
384         ,p_override_manual_upd          IN      VARCHAR2        DEFAULT NULL
385         ,p_previous_income              IN      NUMBER          DEFAULT NULL
386         ,p_yearly_income_limit          IN      NUMBER          DEFAULT NULL
387         ,p_date_returned                IN      DATE            DEFAULT NULL
388         ,p_registration_date            IN      DATE            DEFAULT NULL
389 	,p_lower_income_percentage        IN      NUMBER          DEFAULT NULL
390         ,p_input_value_id1              IN      VARCHAR2        DEFAULT NULL
391         ,p_input_value_id2              IN      VARCHAR2        DEFAULT NULL
392         ,p_input_value_id3              IN      VARCHAR2        DEFAULT NULL
393         ,p_input_value_id4              IN      VARCHAR2        DEFAULT NULL
394         ,p_input_value_id5              IN      VARCHAR2        DEFAULT NULL
395         ,p_input_value_id6              IN      VARCHAR2        DEFAULT NULL
396         ,p_input_value_id7              IN      VARCHAR2        DEFAULT NULL
397         ,p_input_value_id8              IN      VARCHAR2        DEFAULT NULL
398         ,p_input_value_id9              IN      VARCHAR2        DEFAULT NULL
399         ,p_input_value_id10             IN      VARCHAR2        DEFAULT NULL
400 	,p_input_value_id11             IN      VARCHAR2        DEFAULT NULL
401         ,p_datetrack_update_mode        IN      VARCHAR2        DEFAULT NULL
402         ,p_object_version_number        IN      VARCHAR2);
403 --
404 -- ----------------------------------------------------------------------------
405 -- |-------------------------< update_tax >-----------------------------------|
406 -- ----------------------------------------------------------------------------
407 -- {Start Of Comments}
408 --
409 -- Description:
410 --      This API will update a tax entry for a Finland Assignment.
411 --      This API delegates to the update_element_entry procedure of the
412 --      pay_element_entry_api package.
413 --
414 -- Prerequisites:
415 --      The element entry (of element type  'Tax) and the
416 --      corresponding element link should exist for the given assignment
417 --      and business group.
418 --
419 -- In Parameters:
420 --      Name                            Reqd            Type                    Description
421 --      p_legislation_code              Yes             VARCHAR2                The Legislation Code.
422 --      p_effective_date                Yes             DATE                    The current effective date
423 --      p_assignment_id                 Yes             VARCHAR2                Assignment ID of the record.
424 --      p_person_id                     Yes             VARCHAR2                Person ID for the record.
425 --      p_business_group_id             Yes             VARCHAR2                Current Business Group Id.
426 --      p_element_entry_id_t            Yes             VARCHAR2                Element entry Id for Tax Element.
427 --      p_primary_employment                            VARCHAR2                Primary Employment Flag.
428 --      p_extra_income_rate                             NUMBER                  Extra Income Rate.
429 --      p_extra_income_add_rate                         NUMBER                  Extra Income Additional Rate.
430 --      p_extra_income_limit                            NUMBER                  Extra Income Limit.
431 --      p_prev_extra_income                             NUMBER                  Previous Extra Income.
432 --      p_input_value_id1                               VARCHAR2                Input Value Id for Entry 1
433 --      p_input_value_id2                               VARCHAR2                Input Value Id for Entry 2
434 --      p_input_value_id3                               VARCHAR2                Input Value Id for Entry 3
435 --      p_input_value_id4                               VARCHAR2                Input Value Id for Entry 4
436 --      p_input_value_id5                               VARCHAR2                Input Value Id for Entry 5
437 --      p_datetrack_update_mode                         VARCHAR2                The date track mode.
441 --      The API successfully updates the tax card and/or tax entry.
438 --      p_object_version_number                         VARCHAR2                Object Version Number for Tax.
439 --
440 -- Post Success:
442 --
443 -- Post Failure:
444 --      The API will raise an error.
445 --
446 -- Access Status:
447 --      Private. For Internal Development Use only.
448 --
449 -- {End Of Comments}
450 --
451         PROCEDURE update_tax (
452         p_legislation_code              IN      VARCHAR2
453         ,p_effective_date               IN      DATE
454         ,p_assignment_id                IN      VARCHAR2
455         ,p_person_id                    IN      VARCHAR2
456         ,p_business_group_id            IN      VARCHAR2
457         ,p_element_entry_id_t           IN      VARCHAR2
458         ,p_primary_employment           IN      VARCHAR2        DEFAULT NULL
459         ,p_extra_income_rate            IN      NUMBER          DEFAULT NULL
460         ,p_extra_income_add_rate        IN      NUMBER          DEFAULT NULL
461         ,p_extra_income_limit           IN      NUMBER          DEFAULT NULL
462         ,p_prev_extra_income            IN      NUMBER          DEFAULT NULL
463         ,p_input_value_id1              IN      VARCHAR2        DEFAULT NULL
464         ,p_input_value_id2              IN      VARCHAR2        DEFAULT NULL
465         ,p_input_value_id3              IN      VARCHAR2        DEFAULT NULL
466         ,p_input_value_id4              IN      VARCHAR2        DEFAULT NULL
467         ,p_input_value_id5              IN      VARCHAR2        DEFAULT NULL
468         ,p_datetrack_update_mode        IN      VARCHAR2        DEFAULT NULL
469         ,p_object_version_number        IN      VARCHAR2);
470 --
471 -- ----------------------------------------------------------------------------
472 -- |------------------------< find_dt_upd_modes >-----------------------------|
473 -- ----------------------------------------------------------------------------
474 -- {Start Of Comments}
475 --
476 -- Description:
477 --   This API returns the DT modes for pay_element_entries_f for a given
478 --      element_entry_id (base key value) on a specified date
479 --
480 -- Prerequisites:
481 --   The element_entry (p_base_key_value) must exist as of the effective date
482 --   of the change (p_effective_date).
483 --
484 -- In Parameters:
485 --      Name                            Reqd            Type            Description
486 --      p_effective_date                Yes             DATE            The effective date of the change.
487 --      p_base_key_value                Yes             NUMBER          ID of the element entry.
488 --
489 --
490 -- Post Success:
491 --
492 --   The API sets the following out parameters:
493 --
494 --      Name                            Type            Description
495 --      p_correction                    BOOLEAN         True if  correction mode is valid.
496 --      p_update                        BOOLEAN         True if update mode is valid.
497 --      p_update_override               BOOLEAN         True if update override mode is valid.
498 --      p_update_change_insert          BOOLEAN         True if update change insert mode is valid.
499 --      p_update_start_date             DATE            Start date for Update record.
500 --      p_update_end_date               DATE            End date for Update record.
501 --      p_override_start_date           DATE            Start date for Override.
502 --      p_override_end_date             DATE            End date for Overrride.
503 --      p_upd_chg_start_date            DATE            Start date for Update Change.
504 --      p_upd_chg_end_date              DATE            End date for Update Change.
505 
506 -- Post Failure:
507 --   The API will raise an error.
508 --
509 -- Access Status:
510 --   Private. For Internal Development Use only.
511 --
512 -- {End Of Comments}
513 --
514 PROCEDURE  find_dt_upd_modes(
515         p_effective_date                IN              DATE
516         ,p_base_key_value               IN              NUMBER
517         ,p_correction                   OUT NOCOPY      BOOLEAN
518         ,p_update                       OUT NOCOPY      BOOLEAN
519         ,p_update_override              OUT NOCOPY      BOOLEAN
520         ,p_update_change_insert         OUT NOCOPY      BOOLEAN
521         ,p_correction_start_date        OUT NOCOPY      DATE
522         ,p_correction_end_date          OUT NOCOPY      DATE
523         ,p_update_start_date            OUT NOCOPY      DATE
524         ,p_update_end_date              OUT NOCOPY      DATE
525         ,p_override_start_date          OUT NOCOPY      DATE
526         ,p_override_end_date            OUT NOCOPY      DATE
527         ,p_upd_chg_start_date           OUT NOCOPY      DATE
528         ,p_upd_chg_end_date             OUT NOCOPY      DATE);
529 --
530 -- ----------------------------------------------------------------------------
531 -- |----------------------------< is_primary_asg >----------------------------|
532 -- ----------------------------------------------------------------------------
533 -- {Start Of Comments}
534 --
535 -- Description:
536 --   This API returns true / false based on whether the given
537 --      assignment Id is a Primary Assignment or not.
538 --
539 -- Prerequisites:
540 --   The assignment Id should exist as of the effective date specified.
541 --
542 -- In Parameters:
543 --      Name                    Reqd            Type                                            Description
544 --      p_effective_date        Yes             VARCHAR2                                        The effective date of the change.
548 -- Post Success:
545 --      p_assignment_id         Yes             per_all_assignments_f.assignment_id%TYPE        ID of the assignment
546 --
547 --
549 --      The function returns true if the assignment is Primary and false otherwise
550 --
551 -- Access Status:
552 --   Private. For Internal Development Use only.
553 --
554 -- {End Of Comments}
555   FUNCTION is_primary_asg (
556         p_assignment_id                 IN      per_all_assignments_f.assignment_id%TYPE,
557         p_effective_date                IN      VARCHAR2) RETURN BOOLEAN;
558 --
559 -- ----------------------------------------------------------------------------
560 -- |---------------------------< is_element_attached >------------------------|
561 -- ----------------------------------------------------------------------------
562 -- {Start Of Comments}
563 --
564 -- Description:
565 --   This API returns true / false based on whether the given
566 --      element is attached to the assignment Id on the given effective date
567 --
568 -- Prerequisites:
569 --   The assignment and the element entry should exist as of the effective date specified.
570 --
571 -- In Parameters:
572 --      Name                    Reqd            Type                                            Description
573 --      p_effective_date        Yes             VARCHAR2                                        The effective date of the change.
574 --      p_assignment_id         Yes             per_all_assignments_f.assignment_id%TYPE        ID of the assignment
575 --      p_business_group_id     Yes             pay_element_links_f.business_group_id%TYPE      Business Group Id.
576 --      p_element_name  Yes                     pay_element_types_f.element_name%TYPE           Name of the Element to be checked.
577 --
578 --
579 -- Post Success:
580 --      The function returns true if the element is attached to the assignment and false otherwise.
581 --
582 -- Access Status:
583 --   Private. For Internal Development Use only.
584 --
585 -- {End Of Comments}
586   FUNCTION is_element_attached (
587         p_assignment_id                 IN      pay_element_entries_f.assignment_id%TYPE,
588         p_business_group_id             IN      pay_element_links_f.business_group_id%TYPE,
589         p_element_name          IN      pay_element_types_f.element_name%TYPE,
590         p_effective_date                        IN      VARCHAR2) RETURN BOOLEAN;
591 --
592 -- ----------------------------------------------------------------------------
593 -- |---------------< is_element_started_today >-------------------------------|
594 -- ----------------------------------------------------------------------------
595 -- {Start Of Comments}
596 --
597 -- Description:
598 --   This API returns true / false based on whether the given
599 --      elements start date is the effective date.
600 --
601 -- Prerequisites:
602 --   The assignment and the element entry should exist as of the effective date specified.
603 --
604 -- In Parameters:
605 --      Name                            Reqd            Type                                            Description
606 --      p_effective_date                Yes             VARCHAR2                                        The effective date of the change.
607 --      p_assignment_id                 Yes             per_all_assignments_f.assignment_id%TYPE        ID of the assignment
608 --      p_element_name  Yes                             pay_element_types_f.element_name%TYPE           Name of the Element to be checked.
609 --
610 --
611 -- Post Success:
612 --      The function returns true if the start date of the element is equals the effectived date
613 --
614 -- Access Status:
615 --   Private. For Internal Development Use only.
616 --
617 -- {End Of Comments}
618   FUNCTION is_element_started_today (
619         p_assignment_id          IN      pay_element_entries_f.assignment_id%TYPE,
620         p_element_name           IN      pay_element_types_f.element_name%TYPE,
621         p_effective_date         IN      VARCHAR2) RETURN BOOLEAN;
622 --
623 -- ----------------------------------------------------------------------------
624 -- |------------------< find_element_entry_id >-------------------------------|
625 -- ----------------------------------------------------------------------------
626 -- {Start Of Comments}
627 --
628 -- Description:
629 --   This API returns the element entry id of the element whose name is specified , that is attached to
630 --       the assignment on the given effective date
631 --
632 -- Prerequisites:
633 --   The assignment and the element entry should exist as of the effective date specified.
634 --
635 -- In Parameters:
636 --      Name                            Reqd            Type                                            Description
637 --      p_effective_date                Yes             VARCHAR2                                        The effective date of the change.
638 --      p_assignment_id                 Yes             per_all_assignments_f.assignment_id%TYPE        ID of the assignment
639 --      p_business_group_id             Yes             pay_element_links_f.business_group_id%TYPE      Business Group Id.
640 --      p_element_name                  Yes             pay_element_types_f.element_name%TYPE           Name of the Element to be checked.
641 --
642 --
643 -- Post Success:
644 --      The function returns  the id of the element entry.
645 --
646 -- Access Status:
647 --   Private. For Internal Development Use only.
648 --
649 -- {End Of Comments}
650   FUNCTION find_element_entry_id (
651         p_assignment_id                 IN      pay_element_entries_f.assignment_id%TYPE,
652         p_business_group_id             IN      pay_element_links_f.business_group_id%TYPE,
653         p_element_name                  IN      pay_element_types_f.element_name%TYPE,
654         p_effective_date                IN      VARCHAR2) RETURN pay_element_entries_f.element_entry_id%TYPE;
655 
656 END py_fi_tax_card;
657