DBA Data[Home] [Help]

PACKAGE: APPS.PSB_WS_POS1

Source


1 PACKAGE PSB_WS_POS1 AS
2 /* $Header: PSBVWP1S.pls 120.5 2005/07/28 16:50:52 shtripat ship $ */
3 
4   TYPE g_poscalc_rec_type IS RECORD
5      ( pay_element_id   NUMBER,
6        element_type     VARCHAR2(1),
7        element_set_id   NUMBER,
8        element_cost     NUMBER,
9        budget_year_id   NUMBER,
10        period1_amount   NUMBER, period2_amount NUMBER, period3_amount NUMBER,
11        period4_amount   NUMBER, period5_amount NUMBER, period6_amount NUMBER,
12        period7_amount   NUMBER, period8_amount NUMBER, period9_amount NUMBER,
13        period10_amount  NUMBER, period11_amount NUMBER, period12_amount NUMBER,
14        period13_amount  NUMBER, period14_amount NUMBER, period15_amount NUMBER,
15        period16_amount  NUMBER, period17_amount NUMBER, period18_amount NUMBER,
16        period19_amount  NUMBER, period20_amount NUMBER, period21_amount NUMBER,
17        period22_amount  NUMBER, period23_amount NUMBER, period24_amount NUMBER,
18        period25_amount  NUMBER, period26_amount NUMBER, period27_amount NUMBER,
19        period28_amount  NUMBER, period29_amount NUMBER, period30_amount NUMBER,
20        period31_amount  NUMBER, period32_amount NUMBER, period33_amount NUMBER,
21        period34_amount  NUMBER, period35_amount NUMBER, period36_amount NUMBER,
22        period37_amount  NUMBER, period38_amount NUMBER, period39_amount NUMBER,
23        period40_amount  NUMBER, period41_amount NUMBER, period42_amount NUMBER,
24        period43_amount  NUMBER, period44_amount NUMBER, period45_amount NUMBER,
25        period46_amount  NUMBER, period47_amount NUMBER, period48_amount NUMBER,
26        period49_amount  NUMBER, period50_amount NUMBER, period51_amount NUMBER,
27        period52_amount  NUMBER, period53_amount NUMBER, period54_amount NUMBER,
28        period55_amount  NUMBER, period56_amount NUMBER, period57_amount NUMBER,
29        period58_amount  NUMBER, period59_amount NUMBER, period60_amount NUMBER );
30 
31   TYPE g_poscalc_tbl_type IS TABLE OF g_poscalc_rec_type
32       INDEX BY BINARY_INTEGER;
33 
34   g_pc_costs                   g_poscalc_tbl_type;
35   g_num_pc_costs               NUMBER;
36 
37   TYPE g_posdist_rec_type IS RECORD
38      ( ccid             NUMBER,
39        element_type     VARCHAR2(1),
40        element_set_id   NUMBER,
41        budget_year_id   NUMBER,
42        ytd_amount       NUMBER,
43        period1_amount   NUMBER, period2_amount NUMBER, period3_amount NUMBER,
44        period4_amount   NUMBER, period5_amount NUMBER, period6_amount NUMBER,
45        period7_amount   NUMBER, period8_amount NUMBER, period9_amount NUMBER,
46        period10_amount  NUMBER, period11_amount NUMBER, period12_amount NUMBER,
47        period13_amount  NUMBER, period14_amount NUMBER, period15_amount NUMBER,
48        period16_amount  NUMBER, period17_amount NUMBER, period18_amount NUMBER,
49        period19_amount  NUMBER, period20_amount NUMBER, period21_amount NUMBER,
50        period22_amount  NUMBER, period23_amount NUMBER, period24_amount NUMBER,
51        period25_amount  NUMBER, period26_amount NUMBER, period27_amount NUMBER,
52        period28_amount  NUMBER, period29_amount NUMBER, period30_amount NUMBER,
53        period31_amount  NUMBER, period32_amount NUMBER, period33_amount NUMBER,
54        period34_amount  NUMBER, period35_amount NUMBER, period36_amount NUMBER,
55        period37_amount  NUMBER, period38_amount NUMBER, period39_amount NUMBER,
56        period40_amount  NUMBER, period41_amount NUMBER, period42_amount NUMBER,
57        period43_amount  NUMBER, period44_amount NUMBER, period45_amount NUMBER,
58        period46_amount  NUMBER, period47_amount NUMBER, period48_amount NUMBER,
59        period49_amount  NUMBER, period50_amount NUMBER, period51_amount NUMBER,
60        period52_amount  NUMBER, period53_amount NUMBER, period54_amount NUMBER,
61        period55_amount  NUMBER, period56_amount NUMBER, period57_amount NUMBER,
62        period58_amount  NUMBER, period59_amount NUMBER, period60_amount NUMBER );
63 
64   TYPE g_posdist_tbl_type IS TABLE OF g_posdist_rec_type
65       INDEX BY BINARY_INTEGER;
66 
67   g_pd_costs                   g_posdist_tbl_type;
68   g_num_pd_costs               NUMBER;
69 
70   TYPE g_element_rec_type IS RECORD
71      ( pay_element_id          NUMBER,
72        element_name            VARCHAR2(30),
73        processing_type         VARCHAR2(1),
74        max_element_value_type  VARCHAR2(2),
75        max_element_value       NUMBER,
76        option_flag             VARCHAR2(1),
77        overwrite_flag          VARCHAR2(1),
78        salary_flag             VARCHAR2(1),
79        salary_type             VARCHAR2(10),
80        follow_salary           VARCHAR2(1),
81        period_type             VARCHAR2(10),
82        process_period_type     VARCHAR2(10) );
83 
84   TYPE g_element_tbl_type IS TABLE OF g_element_rec_type
85       INDEX BY BINARY_INTEGER;
86 
87   g_elements                   g_element_tbl_type;
88   g_num_elements               NUMBER;
89 
90   TYPE g_saldist_rec_type IS RECORD
91      ( ccid        NUMBER,
92        amount      NUMBER,
93        percent     NUMBER,
94        start_date  DATE,
95        end_date    DATE );
96 
97   TYPE g_saldist_tbl_type IS TABLE OF g_saldist_rec_type
98       INDEX BY BINARY_INTEGER;
99 
100   g_salary_dist                g_saldist_tbl_type;
101   g_num_salary_dist            NUMBER;
102 
103   g_salary_budget_group_id     NUMBER;
104   g_budget_group_numyrs        NUMBER;
105 
106   TYPE g_elemdist_rec_type IS RECORD
107      ( account_line_id  NUMBER,
108        ccid             NUMBER,
109        ytd_amount       NUMBER,
110        period1_amount NUMBER, period2_amount NUMBER, period3_amount NUMBER,
111        period4_amount NUMBER, period5_amount NUMBER, period6_amount NUMBER,
112        period7_amount NUMBER, period8_amount NUMBER, period9_amount NUMBER,
113        period10_amount NUMBER, period11_amount NUMBER, period12_amount NUMBER,
114        period13_amount NUMBER, period14_amount NUMBER, period15_amount NUMBER,
115        period16_amount NUMBER, period17_amount NUMBER, period18_amount NUMBER,
116        period19_amount NUMBER, period20_amount NUMBER, period21_amount NUMBER,
117        period22_amount NUMBER, period23_amount NUMBER, period24_amount NUMBER,
118        period25_amount NUMBER, period26_amount NUMBER, period27_amount NUMBER,
119        period28_amount NUMBER, period29_amount NUMBER, period30_amount NUMBER,
120        period31_amount NUMBER, period32_amount NUMBER, period33_amount NUMBER,
121        period34_amount NUMBER, period35_amount NUMBER, period36_amount NUMBER,
122        period37_amount NUMBER, period38_amount NUMBER, period39_amount NUMBER,
123        period40_amount NUMBER, period41_amount NUMBER, period42_amount NUMBER,
124        period43_amount NUMBER, period44_amount NUMBER, period45_amount NUMBER,
125        period46_amount NUMBER, period47_amount NUMBER, period48_amount NUMBER,
126        period49_amount NUMBER, period50_amount NUMBER, period51_amount NUMBER,
127        period52_amount NUMBER, period53_amount NUMBER, period54_amount NUMBER,
128        period55_amount NUMBER, period56_amount NUMBER, period57_amount NUMBER,
129        period58_amount NUMBER, period59_amount NUMBER, period60_amount NUMBER,
130        redist_flag      VARCHAR2(1) );
131 
132   TYPE g_elemdist_tbl_type IS TABLE OF g_elemdist_rec_type
133     INDEX BY BINARY_INTEGER;
134 
135   g_element_dist               g_elemdist_tbl_type;
136   g_num_element_dist           NUMBER;
137 
138   g_fte_id                     NUMBER;
139   g_default_wklyhrs_id         NUMBER;
140 
141   -- Added for bug#3212814
142   g_default_wklyhrs_vt_flag    VARCHAR2(1);
143 
144   g_adjdate_id                 NUMBER;
145   g_hiredate_id                NUMBER;
146 
147   g_data_extract_id            NUMBER;
148   g_business_group_id          NUMBER;
149   g_attr_busgrp_id             NUMBER;
150 
151   g_fte                        NUMBER;
152   g_default_weekly_hours       NUMBER;
153   g_adjustment_date            DATE;
154   g_hiredate                   DATE;
155 
156   g_global_worksheet_id        NUMBER;
157   g_local_copy_flag            VARCHAR2(1);
158 
159   g_budget_calendar_id         NUMBER;
160   g_budget_group_id            NUMBER;
161 
162 /* ----------------------------------------------------------------------- */
163 
164   --    API name        : Initialize_Calc
165   --    Type            : Private <Implementation>
166   --    Pre-reqs        :
167   --                    .
168   --    Version : Current version       1.0
169   --                      Initial version       1.0
170   --                            Created 12/08/1997 by Supriyo Ghosh
171   --
172   --    Notes           : Initializes global array for Position Costs
173   --
174 
175 PROCEDURE Initialize_Calc
176 ( p_init_index  NUMBER := FND_API.G_MISS_NUM
177 );
178 
179 /* ----------------------------------------------------------------------- */
180 
181   --    API name        : Initialize_Dist
182   --    Type            : Private <Implementation>
183   --    Pre-reqs        :
184   --                    .
185   --    Version : Current version       1.0
186   --                      Initial version       1.0
187   --                            Created 12/08/1997 by Supriyo Ghosh
188   --
189   --    Notes           : Initializes global array for Cost Distributions
190   --
191 
192 PROCEDURE Initialize_Dist;
193 
194 /* ----------------------------------------------------------------------- */
195 
196   --    API name        : Initialize_Salary_Dist
197   --    Type            : Private <Implementation>
198   --    Pre-reqs        :
199   --                    .
200   --    Version : Current version       1.0
201   --                      Initial version       1.0
202   --                            Created 12/08/1997 by Supriyo Ghosh
203   --
204   --    Notes           : Initializes global array for Salary Distribution
205   --
206 
207 PROCEDURE Initialize_Salary_Dist;
208 
209 /* ----------------------------------------------------------------------- */
210 
211   --    API name        : Initialize_Element_Dist
212   --    Type            : Private <Implementation>
213   --    Pre-reqs        :
214   --                    .
215   --    Version : Current version       1.0
216   --                      Initial version       1.0
217   --                            Created 12/08/1997 by Supriyo Ghosh
218   --
219   --    Notes           : Initializes global array for Redistributing Elements
220   --                      following Salary
221   --
222 
223 PROCEDURE Initialize_Element_Dist;
224 
225 /* ----------------------------------------------------------------------- */
226 
227   --    API name        : Check_Allowed
228   --    Type            : Private <Implementation>
229   --    Pre-reqs        :
230   --                    .
231   --    Version : Current version       1.0
232   --                      Initial version       1.0
233   --                            Created 02/06/1998 by Supriyo Ghosh
234   --
235   --    Notes           : Check if Position Budget Group is within Budget Group
236   --                      Hierarchy for the Worksheet
237   --
238 
239 FUNCTION Check_Allowed
240 ( p_api_version               IN  NUMBER,
241   p_validation_level          IN  NUMBER := FND_API.G_VALID_LEVEL_NONE,
242   p_worksheet_id              IN  NUMBER,
243   p_position_budget_group_id  IN  NUMBER
244 ) RETURN VARCHAR2;
245 
246 /* ----------------------------------------------------------------------- */
247 
248   --    API name        : Cache_Elements
249   --    Type            : Private <Implementation>
250   --    Pre-reqs        :
251   --                    .
252   --    Version : Current version       1.0
253   --                      Initial version       1.0
254   --                            Created 12/08/1997 by Supriyo Ghosh
255   --
256   --    Notes           : Cache Elements
257   --
258 
259 PROCEDURE Cache_Elements
260 ( p_return_status      OUT  NOCOPY  VARCHAR2,
261   p_data_extract_id    IN   NUMBER,
262   p_business_group_id  IN   NUMBER,
263   p_worksheet_id       IN   NUMBER
264 );
265 
266 /* ----------------------------------------------------------------------- */
267 
268   --    API name        : Cache_Named_Attributes
269   --    Type            : Private <Implementation>
270   --    Pre-reqs        :
271   --                    .
272   --    Version : Current version       1.0
273   --                      Initial version       1.0
274   --                            Created 12/08/1997 by Supriyo Ghosh
275   --
276   --    Notes           : Cache Named Position Attributes
277   --
278 
279 PROCEDURE Cache_Named_Attributes
280 ( p_return_status      OUT  NOCOPY  VARCHAR2,
281   p_business_group_id  IN   NUMBER
282 );
283 
284 /* ----------------------------------------------------------------------- */
285 
286   --    API name        : Cache_Named_Attribute_Values
287   --    Type            : Private <Implementation>
288   --    Pre-reqs        :
289   --                    .
290   --    Version : Current version       1.0
291   --                      Initial version       1.0
292   --                            Created 12/08/1997 by Supriyo Ghosh
293   --
294   --    Notes           : Cache Named Position Attribute Values
295   --
296 
297 PROCEDURE Cache_Named_Attribute_Values
298 ( p_return_status    OUT  NOCOPY  VARCHAR2,
299   p_worksheet_id     IN   NUMBER,
300   p_data_extract_id  IN   NUMBER,
301   p_position_id      IN   NUMBER,
302   /* start bug 4104890 */
303   p_local_parameter_flag     IN   VARCHAR2 := 'N'
304   /* End bug 4104890 */
305 );
306 
307 /* ----------------------------------------------------------------------- */
308 
309   --    API name        : HRMS_Factor
310   --    Type            : Private <Implementation>
311   --    Pre-reqs        :
312   --                    .
313   --    Version : Current version       1.0
314   --                      Initial version       1.0
315   --                            Created 12/08/1997 by Supriyo Ghosh
316   --
317   --    Notes           : Return conversion factor
318   --
319 
320 PROCEDURE HRMS_Factor
321 ( p_return_status       OUT  NOCOPY  VARCHAR2,
322   p_hrms_period_type    IN   VARCHAR2,
323   p_budget_period_type  IN   VARCHAR2,
324   p_position_name       IN   VARCHAR2,
325   p_element_name        IN   VARCHAR2,
326   p_start_date          IN   DATE,
327   p_end_date            IN   DATE,
328   p_factor              OUT  NOCOPY  NUMBER
329 );
330 
331 /* ----------------------------------------------------------------------- */
332 
333   --    API name        : Cache_Salary_Dist
334   --    Type            : Private <Implementation>
335   --    Pre-reqs        :
336   --                    .
337   --    Version : Current version       1.0
338   --                      Initial version       1.0
339   --                            Created 12/08/1997 by Supriyo Ghosh
340   --                            Changed 04/29/1998 by Supriyo Ghosh
341   --                                    Added p_position_name
342   --                            Changed 04/17/2001 by Supriyo Ghosh
343   --                                    Added p_worksheet_id
344   --
345   --    Notes           : Cache Salary Distribution
346   --
347 
348 PROCEDURE Cache_Salary_Dist
349 ( p_return_status         OUT  NOCOPY  VARCHAR2,
350   p_worksheet_id          IN   NUMBER,
351   p_root_budget_group_id  IN   NUMBER,
352   p_data_extract_id       IN   NUMBER,
353   p_flex_code             IN   NUMBER,
354   p_position_id           IN   NUMBER,
355   p_position_name         IN   VARCHAR2,
356   p_start_date            IN   DATE,
357   p_end_date              IN   DATE
358 );
359 
360 /* ----------------------------------------------------------------------- */
361 
362   --    API name        : Create_Position_Lines
363   --    Type            : Private <Implementation>
364   --    Pre-reqs        : FND_API, FND_MESSAGE
365   --                    .
366   --    Version : Current version       1.0
367   --                      Initial version       1.0
368   --                            Created 12/08/1997 by Supriyo Ghosh
369   --
370   --    Notes           : Create Position Instance for a specific
371   --                      Global Worksheet or a local copy of Worksheet
372   --
373 
374 PROCEDURE Create_Position_Lines
375 ( p_api_version               IN   NUMBER,
376   p_validation_level          IN   NUMBER := FND_API.G_VALID_LEVEL_NONE,
377   p_return_status             OUT  NOCOPY  VARCHAR2,
378   p_position_line_id          OUT  NOCOPY  NUMBER,
379   p_worksheet_id              IN   NUMBER,
380   p_position_id               IN   NUMBER,
381   p_budget_group_id           IN   NUMBER,
382   p_copy_of_position_line_id  IN   NUMBER := FND_API.G_MISS_NUM
383 );
384 
385 /* ----------------------------------------------------------------------- */
386 
387   --    API name        : Create_Position_Matrix
388   --    Type            : Private <Implementation>
389   --    Pre-reqs        : FND_API, FND_MESSAGE
390   --                    .
391   --    Version : Current version       1.0
392   --                      Initial version       1.0
393   --                            Created 12/08/1997 by Supriyo Ghosh
394   --
395   --    Notes           : Create Position Matrix
396   --
397 
398 PROCEDURE Create_Position_Matrix
399 ( p_api_version       IN   NUMBER,
400   p_validation_level  IN   NUMBER := FND_API.G_VALID_LEVEL_NONE,
401   p_return_status     OUT  NOCOPY  VARCHAR2,
402   p_worksheet_id      IN   NUMBER,
403   p_position_line_id  IN   NUMBER,
404   p_freeze_flag       IN   VARCHAR2 := FND_API.G_FALSE,
405   p_view_line_flag    IN   VARCHAR2 := FND_API.G_TRUE
406 );
407 
408 /* ----------------------------------------------------------------------- */
409 
410   --    API name        : Create_FTE_Lines
411   --    Type            : Private <Implementation>
412   --    Pre-reqs        : FND_API, FND_MESSAGE
413   --                    .
414   --    Version : Current version       1.0
415   --                      Initial version       1.0
416   --                            Created 12/08/1997 by Supriyo Ghosh
417   --
418   --    Notes           : Create Worksheet Position FTE Lines
419   --
420 
421 PROCEDURE Create_FTE_Lines
422 ( p_api_version         IN   NUMBER,
423   p_validation_level    IN   NUMBER := FND_API.G_VALID_LEVEL_NONE,
424   p_return_status       OUT  NOCOPY  VARCHAR2,
425   p_fte_line_id         OUT  NOCOPY  NUMBER,
426   p_check_spfl_exists   IN   VARCHAR2 := FND_API.G_TRUE,
427   p_recalculate_flag    IN   VARCHAR2 := FND_API.G_FALSE,
428   p_worksheet_id        IN   NUMBER,
429   p_flex_mapping_set_id IN   NUMBER := FND_API.G_MISS_NUM,
430   p_position_line_id    IN   NUMBER,
431   p_budget_year_id      IN   NUMBER,
432   p_budget_group_id     IN   NUMBER := FND_API.G_MISS_NUM,
433   p_annual_fte          IN   NUMBER := FND_API.G_MISS_NUM,
434   p_service_package_id  IN   NUMBER,
435   p_stage_set_id        IN   NUMBER,
436   p_start_stage_seq     IN   NUMBER := FND_API.G_MISS_NUM,
437   p_current_stage_seq   IN   NUMBER,
438   p_end_stage_seq       IN   NUMBER := FND_API.G_MISS_NUM,
439   p_period_fte          IN   PSB_WS_ACCT1.g_prdamt_tbl_type
440 );
441 
442 /* ----------------------------------------------------------------------- */
443 
444   --    API name        : Create_FTE_Lines
445   --    Type            : Private <Implementation>
446   --    Pre-reqs        : FND_API, FND_MESSAGE
447   --                    .
448   --    Version : Current version       1.0
449   --                      Initial version       1.0
450   --                            Created 12/08/1997 by Supriyo Ghosh
451   --
452   --    Notes           : Update Worksheet Position FTE Lines
453   --
454 
455 PROCEDURE Create_FTE_Lines
456 ( p_api_version         IN   NUMBER,
457   p_validation_level    IN   NUMBER := FND_API.G_VALID_LEVEL_NONE,
458   p_return_status       OUT  NOCOPY  VARCHAR2,
459   p_check_stages        IN   VARCHAR2 := FND_API.G_TRUE,
460   p_worksheet_id        IN   NUMBER,
461   p_fte_line_id         IN   NUMBER,
462   p_service_package_id  IN   NUMBER := FND_API.G_MISS_NUM,
463   p_current_stage_seq   IN   NUMBER := FND_API.G_MISS_NUM,
464   p_period_fte          IN   PSB_WS_ACCT1.g_prdamt_tbl_type,
465   p_budget_group_id     IN   NUMBER := FND_API.G_MISS_NUM
466 );
467 
468 /* ----------------------------------------------------------------------- */
469   --    API name        : Create_Element_Lines
470   --    Type            : Private <Implementation>
471   --    Pre-reqs        : FND_API, FND_MESSAGE
472   --                    .
473   --    Version : Current version       1.0
474   --                      Initial version       1.0
475   --                            Created 12/09/1997 by Supriyo Ghosh
476   --
477   --    Notes           : Create Worksheet Element Lines
478   --
479 
480 PROCEDURE Create_Element_Lines
481 ( p_api_version             IN   NUMBER,
482   p_validation_level        IN   NUMBER := FND_API.G_VALID_LEVEL_NONE,
483   p_return_status           OUT  NOCOPY  VARCHAR2,
484   p_element_line_id         OUT  NOCOPY  NUMBER,
485   p_check_spel_exists       IN   VARCHAR2 := FND_API.G_TRUE,
486   p_position_line_id        IN   NUMBER,
487   p_budget_year_id          IN   NUMBER,
488   p_pay_element_id          IN   NUMBER,
489   p_currency_code           IN   VARCHAR2,
490   p_element_cost            IN   NUMBER,
491   p_element_set_id          IN   NUMBER,
492   p_service_package_id      IN   NUMBER,
493   p_stage_set_id            IN   NUMBER,
494   p_start_stage_seq         IN   NUMBER := FND_API.G_MISS_NUM,
495   p_current_stage_seq       IN   NUMBER,
496   p_end_stage_seq           IN   NUMBER := FND_API.G_MISS_NUM,
497   p_functional_transaction  IN   VARCHAR2 := NULL
498 );
499 
500 /* ----------------------------------------------------------------------- */
501 
502   --    API name        : Create_Element_Lines
503   --    Type            : Private <Implementation>
504   --    Pre-reqs        : FND_API, FND_MESSAGE
505   --                    .
506   --    Version : Current version       1.0
507   --                      Initial version       1.0
508   --                            Created 08/12/1998 by Supriyo Ghosh
509   --
510   --    Notes           : Update Worksheet Position Element Lines
511   --
512 
513 PROCEDURE Create_Element_Lines
514 ( p_api_version             IN   NUMBER,
515   p_validation_level        IN   NUMBER := FND_API.G_VALID_LEVEL_NONE,
516   p_return_status           OUT  NOCOPY  VARCHAR2,
517   p_check_stages            IN   VARCHAR2 := FND_API.G_TRUE,
518   p_element_line_id         IN   NUMBER,
519   p_service_package_id      IN   NUMBER := FND_API.G_MISS_NUM,
520   p_current_stage_seq       IN   NUMBER := FND_API.G_MISS_NUM,
521   p_element_cost            IN   NUMBER := FND_API.G_MISS_NUM
522 );
523 
524 /* ----------------------------------------------------------------------- */
525 
526   --    API name        : Update_Annual_FTE
527   --    Type            : Private <Implementation>
528   --    Pre-reqs        : FND_API, FND_MESSAGE
529   --                    .
530   --    Version : Current version       1.0
531   --                      Initial version       1.0
532   --                            Created 12/10/1997 by Supriyo Ghosh
533   --
534   --    Notes           : Compute Annualized FTE for Position Instance
535   --
536 
537 PROCEDURE Update_Annual_FTE
538 ( p_api_version         IN   NUMBER,
539   p_validation_level    IN   NUMBER := FND_API.G_VALID_LEVEL_NONE,
540   p_return_status       OUT  NOCOPY  VARCHAR2,
541   p_worksheet_id        IN   NUMBER,
542   p_position_line_id    IN   NUMBER,
543   p_budget_year_id      IN   NUMBER,
544   p_service_package_id  IN   NUMBER,
545   p_stage_set_id        IN   NUMBER,
546   p_current_stage_seq   IN   NUMBER,
547   p_budget_group_id     IN   NUMBER
548 );
549 
550 /* ----------------------------------------------------------------------- */
551 
552   --    API name        : Distribute_Following_Elements
553   --    Type            : Private <Implementation>
554   --    Pre-reqs        : FND_API, FND_MESSAGE
555   --                    .
556   --    Version : Current version       1.0
557   --                      Initial version       1.0
558   --                            Created 12/09/1997 by Supriyo Ghosh
559   --
560   --    Notes           : Distribute Following Elements
561   --
562 
563 PROCEDURE Distribute_Following_Elements
564 ( p_return_status      OUT  NOCOPY  VARCHAR2,
565   p_redistribute       IN   VARCHAR2 := FND_API.G_FALSE,
566   p_pay_element_id     IN   NUMBER,
567   p_data_extract_id    IN   NUMBER,
568   p_flex_code          IN   NUMBER,
569   p_business_group_id  IN   NUMBER,
570   p_rounding_factor    IN   NUMBER,
571   p_position_line_id   IN   NUMBER,
572   p_position_id        IN   NUMBER,
573   p_budget_year_id     IN   NUMBER,
574   p_start_date         IN   DATE,
575   p_end_date           IN   DATE
576 );
577 
578 /* ----------------------------------------------------------------------- */
579 
580   --    API name        : Get_Debug
581   --    Type            : Private
582   --    Pre-reqs        : None
583 
584 FUNCTION Get_Debug RETURN VARCHAR2;
585 
586 /* ----------------------------------------------------------------------- */
587 /* Bug No 2278216 Start */
588 
589   TYPE g_prddist_rec_type IS RECORD
590      ( ccid                     NUMBER,
591        element_type             VARCHAR2(1),
592        element_set_id           NUMBER,
593        budget_year_id           NUMBER,
594        period_start_date        DATE,
595        period_end_date          DATE,
596        percent                  NUMBER);
597 
598   TYPE g_prddist_tbl_type IS TABLE OF g_prddist_rec_type
599       INDEX BY BINARY_INTEGER;
600 
601   g_periods                   g_prddist_tbl_type;
602   g_num_periods               NUMBER;
603 
604 /* ----------------------------------------------------------------------- */
605 
606 PROCEDURE Initialize_Period_Dist;
607 
608 /* ----------------------------------------------------------------------- */
609 
610 PROCEDURE Distribute_Periods
611 ( p_return_status            OUT  NOCOPY  VARCHAR2,
612   p_ccid                     IN   NUMBER,
613   p_element_type             IN   VARCHAR2,
614   p_element_set_id           IN   NUMBER,
615   p_budget_year_id           IN   NUMBER,
616   p_dist_start_date          IN   DATE,
617   p_dist_end_date            IN   DATE,
618   p_start_date               IN   DATE,
619   p_end_date                 IN   DATE,
620   p_element_index            IN   NUMBER,
621   p_dist_index               IN   NUMBER,
622   p_percent                  IN   NUMBER
623 );
624 
625 /* Bug No 2278216 End */
626 /* ----------------------------------------------------------------------- */
627 
628 END PSB_WS_POS1;