1 PACKAGE okl_sla_acc_sources_pvt AUTHID CURRENT_USER AS
2 /*$Header: OKLRSLAS.pls 120.16 2007/12/27 14:26:32 zrehman noship $*/
3
4 ------------------------------------------------------------------------------
5 -- Global Variables
6 ------------------------------------------------------------------------------
7 G_PKG_NAME CONSTANT VARCHAR2(200) := 'OKL_SLA_ACC_SOURCES_PVT ';
8 G_APP_NAME CONSTANT VARCHAR2(3) := OKL_API.G_APP_NAME;
9 G_UNEXPECTED_ERROR CONSTANT VARCHAR2(200) := 'OKL_CONTRACTS_UNEXPECTED_ERROR';
10 G_SQLERRM_TOKEN CONSTANT VARCHAR2(200) := 'SQLERRM';
11 G_SQLCODE_TOKEN CONSTANT VARCHAR2(200) := 'SQLCODE';
12 G_COMMIT_AFTER_RECORDS CONSTANT NUMBER := 500;
13 G_COMMIT_COUNT NUMBER := 0;
14 G_REQUIRED_VALUE CONSTANT VARCHAR2(200) := OKL_API.G_REQUIRED_VALUE;
15 G_COL_NAME_TOKEN CONSTANT VARCHAR2(200) := OKL_API.G_COL_NAME_TOKEN;
16 G_INVALID_VALUE CONSTANT VARCHAR2(200) := OKL_API.G_INVALID_VALUE;
17
18 -- Constants declared for the source tables
19 G_TRX_CONTRACTS CONSTANT VARCHAR2(30) := 'OKL_TRX_CONTRACTS';
20 G_TXL_CONTRACTS CONSTANT VARCHAR2(30) := 'OKL_TXL_CNTRCT_LNS';
21 G_TRX_ASSETS CONSTANT VARCHAR2(30) := 'OKL_TRX_ASSETS';
22 G_TXL_ASSETS CONSTANT VARCHAR2(30) := 'OKL_TXL_ASSETS_B';
23 G_TXD_ASSETS CONSTANT VARCHAR2(30) := 'OKL_TXD_ASSETS_B';
24 G_TRX_AR_INVOICES_B CONSTANT VARCHAR2(30) := 'OKL_TRX_AR_INVOICES_B';
25 G_TRX_AR_ADJSTS_B CONSTANT VARCHAR2(30) := 'OKL_TRX_AR_ADJSTS_B';
26 G_TXD_AR_LN_DTLS_B CONSTANT VARCHAR2(30) := 'OKL_TXD_AR_LN_DTLS_B';
27 G_TXL_ADJSTS_LNS_B CONSTANT VARCHAR2(30) := 'OKL_TXL_ADJSTS_LNS_B';
28 G_TRX_AP_INVOICES_B CONSTANT VARCHAR2(30) := 'OKL_TRX_AP_INVOICES_B';
29 G_TXL_AP_INV_LNS_B CONSTANT VARCHAR2(30) := 'OKL_TXL_AP_INV_LNS_B';
30 G_FA_DEPRN_SUMMARY CONSTANT VARCHAR2(30) := 'FA_DEPRN_SUMMARY';
31 G_AR_CASH_RECEIPTS CONSTANT VARCHAR2(30) := 'AR_CASH_RECEIPTS';
32 -- Constants declared for the Event classes
33 G_BOOKING CONSTANT VARCHAR2(50) := 'BOOKING';
34 G_REBOOK CONSTANT VARCHAR2(50) := 'REBOOK';
35 G_RE_LEASE CONSTANT VARCHAR2(50) := 'RE_LEASE';
36 G_GLP CONSTANT VARCHAR2(50) := 'GENERAL_LOSS_PROVISION';
37 G_SLP CONSTANT VARCHAR2(50) := 'SPECIFIC_LOSS_PROVISION';
38 G_TERMINATION CONSTANT VARCHAR2(50) := 'TERMINATION';
39 G_EVERGREEN CONSTANT VARCHAR2(50) := 'EVERGREEN';
40 G_ACCRUAL CONSTANT VARCHAR2(50) := 'ACCRUAL';
41 G_RECEIPT_APPLICATION CONSTANT VARCHAR2(50) := 'RECEIPT_APPLICATION';
42 G_PRINCIPAL_ADJUSTMENT CONSTANT VARCHAR2(50) := 'PRINCIPAL_ADJUSTMENT';
43 G_ASSET_DISPOSITION CONSTANT VARCHAR2(50) := 'ASSET_DISPOSITION';
44 G_SPLIT_ASSET CONSTANT VARCHAR2(50) := 'SPLIT_ASSET';
45 G_MISCELLANEOUS CONSTANT VARCHAR2(50) := 'MISCELLANEOUS';
46 G_UPFRONT_TAX CONSTANT VARCHAR2(50) := 'UPFRONT_TAX';
47 -- Constants declared for the Lease or Investor Type
48 G_LEASE CONSTANT VARCHAR2(50) := 'LEASE';
49 G_INVESTOR CONSTANT VARCHAR2(50) := 'INVESTOR';
50 -- Constants for the Profile Name Declarations
51 G_OKL_DEPRN_WORKERS CONSTANT VARCHAR2(30) := 'OKL_DEPRN_WORKERS';
52 G_LIMIT_SIZE CONSTANT NUMBER := 10000;
53 -- Global Constants for the Error Message Names
54 G_OKL_DEPRN_WORKER_ERROR CONSTANT VARCHAR2(30) := 'OKL_DEPRN_WORKER_ERROR';
55 G_OBJECT_TYPE_DEP_KHR CONSTANT VARCHAR2(30) := 'DEPRECIATION_CONTRACT';
56 ------------------------------------------------------------------------------
57 -- Record Type
58 ------------------------------------------------------------------------------
59 TYPE account_dist_rec_type IS RECORD (
60 id okl_trns_acc_dstrs.id%TYPE
61 ,template_id okl_trns_acc_dstrs.template_id%TYPE
62 );
63 TYPE account_dist_tbl_type IS TABLE OF account_dist_rec_type
64 INDEX BY BINARY_INTEGER;
65
66 -- Start : PRASJAIN : Bug# 6268782
67 SUBTYPE tel_tbl_tbl_type IS okl_tel_pvt.tel_tbl_tbl_type;
68 SUBTYPE fxl_tbl_tbl_type IS okl_fxl_pvt.fxl_tbl_tbl_type;
69
70 TYPE led_lang_rec_type IS RECORD(
71 language VARCHAR2(12)
72 ,contract_status VARCHAR2(90)
73 ,inv_agrmnt_status VARCHAR2(90)
74 );
75
76 TYPE led_lang_tbl_type IS TABLE OF led_lang_rec_type
77 INDEX BY BINARY_INTEGER;
78 -- End : PRASJAIN : Bug# 6268782
79
80 -- Subtyping the record structures
81 SUBTYPE tehv_rec_type IS okl_teh_pvt.tehv_rec_type;
82 SUBTYPE tehv_tbl_type IS okl_teh_pvt.tehv_tbl_type;
83
84 SUBTYPE telv_rec_type IS okl_tel_pvt.telv_rec_type;
85 SUBTYPE telv_tbl_type IS okl_tel_pvt.telv_tbl_type;
86
87 SUBTYPE fxhv_rec_type IS okl_fxh_pvt.fxhv_rec_type;
88 SUBTYPE fxhv_tbl_type IS okl_fxh_pvt.fxhv_tbl_type;
89
90 SUBTYPE fxlv_rec_type IS okl_fxl_pvt.fxlv_rec_type;
91 SUBTYPE fxlv_tbl_type IS okl_fxl_pvt.fxlv_tbl_type;
92
93 SUBTYPE asev_rec_type IS okl_acct_sources_pvt.asev_rec_type;
94 SUBTYPE asev_tbl_type IS okl_acct_sources_pvt.asev_tbl_type;
95
96 SUBTYPE rxhv_rec_type IS okl_rxh_pvt.rxhv_rec_type;
97 SUBTYPE rxhv_tbl_type IS okl_rxh_pvt.rxhv_tbl_type;
98
99 SUBTYPE rxlv_rec_type IS okl_rxl_pvt.rxlv_rec_type;
100 SUBTYPE rxlv_tbl_type IS okl_rxl_pvt.rxlv_tbl_type;
101
102 SUBTYPE pxhv_rec_type IS okl_pxh_pvt.pxhv_rec_type;
103 SUBTYPE pxhv_tbl_type IS okl_pxh_pvt.pxhv_tbl_type;
104
105 SUBTYPE pxlv_rec_type IS okl_pxl_pvt.pxlv_rec_type;
106 SUBTYPE pxlv_tbl_type IS okl_pxl_pvt.pxlv_tbl_type;
107
108 -- Start : PRASJAIN : Bug# 6268782
109 SUBTYPE teh_rec_type IS okl_teh_pvt.teh_rec_type;
110 SUBTYPE tehl_tbl_type IS okl_teh_pvt.tehl_tbl_type;
111
112 SUBTYPE tel_rec_type IS okl_tel_pvt.tel_rec_type;
113 SUBTYPE tel_tbl_type IS okl_tel_pvt.tel_tbl_type;
114 SUBTYPE tell_tbl_type IS okl_tel_pvt.tell_tbl_type;
115
116 SUBTYPE fxh_rec_type IS okl_fxh_pvt.fxh_rec_type;
117 SUBTYPE fxhl_tbl_type IS okl_fxh_pvt.fxhl_tbl_type;
118
119 SUBTYPE fxl_rec_type IS okl_fxl_pvt.fxl_rec_type;
120 SUBTYPE fxll_tbl_type IS okl_fxl_pvt.fxll_tbl_type;
121
122 SUBTYPE rxh_rec_type IS okl_rxh_pvt.rxh_rec_type;
123 SUBTYPE rxhl_tbl_type IS okl_rxh_pvt.rxhl_tbl_type;
124
125 SUBTYPE rxl_rec_type IS okl_rxl_pvt.rxl_rec_type;
126 SUBTYPE rxll_tbl_type IS okl_rxl_pvt.rxll_tbl_type;
127
128 SUBTYPE pxh_rec_type IS okl_pxh_pvt.pxh_rec_type;
129 SUBTYPE pxhl_tbl_type IS okl_pxh_pvt.pxhl_tbl_type;
130
131 SUBTYPE pxl_rec_type IS okl_pxl_pvt.pxl_rec_type;
132 SUBTYPE pxll_tbl_type IS okl_pxl_pvt.pxll_tbl_type;
133 -- End : PRASJAIN : Bug# 6268782
134
135 -------------------------------------------------------------------------------
136 -- Generic record structure to hold khr header sources for FA/AR/AP transaction
137 -------------------------------------------------------------------------------
138 TYPE khr_source_rec_type IS RECORD (
139 khr_id NUMBER
140 ,contract_number VARCHAR2(120)
141 ,contract_status VARCHAR2(90)
142 ,contract_currency_code VARCHAR2(80)
143 ,contract_effective_from DATE
144 ,customer_name VARCHAR2(360)
145 ,customer_account_number VARCHAR2(30)
146 ,product_name VARCHAR2(150)
147 ,book_classification_code VARCHAR2(30)
148 ,tax_owner_code VARCHAR2(150)
149 ,rev_rec_method_code VARCHAR2(150)
150 ,int_calc_method_code VARCHAR2(150)
151 ,vendor_program_number VARCHAR2(120)
152 ,po_order_number VARCHAR2(150)
153 ,converted_number VARCHAR2(30)
154 ,converted_account_flag VARCHAR2(3)
155 ,assignable_flag VARCHAR2(3)
156 ,accrual_override_flag VARCHAR2(3)
157 ,rent_ia_contract_number VARCHAR2(120)
158 ,rent_ia_product_name VARCHAR2(150)
159 ,rent_ia_accounting_code VARCHAR2(450)
160 ,res_ia_contract_number VARCHAR2(120)
161 ,res_ia_product_name VARCHAR2(150)
162 ,res_ia_accounting_code VARCHAR2(450)
163 ,khr_attribute_category VARCHAR2(90)
164 ,khr_attribute1 VARCHAR2(450)
165 ,khr_attribute2 VARCHAR2(450)
166 ,khr_attribute3 VARCHAR2(450)
167 ,khr_attribute4 VARCHAR2(450)
168 ,khr_attribute5 VARCHAR2(450)
169 ,khr_attribute6 VARCHAR2(450)
170 ,khr_attribute7 VARCHAR2(450)
171 ,khr_attribute8 VARCHAR2(450)
172 ,khr_attribute9 VARCHAR2(450)
173 ,khr_attribute10 VARCHAR2(450)
174 ,khr_attribute11 VARCHAR2(450)
175 ,khr_attribute12 VARCHAR2(450)
176 ,khr_attribute13 VARCHAR2(450)
177 ,khr_attribute14 VARCHAR2(450)
178 ,khr_attribute15 VARCHAR2(450)
179 ,cust_attribute_category VARCHAR2(90)
180 ,cust_attribute1 VARCHAR2(450)
181 ,cust_attribute2 VARCHAR2(450)
182 ,cust_attribute3 VARCHAR2(450)
183 ,cust_attribute4 VARCHAR2(450)
184 ,cust_attribute5 VARCHAR2(450)
185 ,cust_attribute6 VARCHAR2(450)
186 ,cust_attribute7 VARCHAR2(450)
187 ,cust_attribute8 VARCHAR2(450)
188 ,cust_attribute9 VARCHAR2(450)
189 ,cust_attribute10 VARCHAR2(450)
190 ,cust_attribute11 VARCHAR2(450)
191 ,cust_attribute12 VARCHAR2(450)
192 ,cust_attribute13 VARCHAR2(450)
193 ,cust_attribute14 VARCHAR2(450)
194 ,cust_attribute15 VARCHAR2(450)
195 ,contract_status_code VARCHAR2(90)
196 ,scs_code VARCHAR2(30)
197 ,inv_agrmnt_number VARCHAR2(120)
198 ,inv_agrmnt_effective_from DATE
199 ,inv_agrmnt_product_name VARCHAR2(150)
200 ,inv_agrmnt_currency_code VARCHAR2(80)
201 ,inv_agrmnt_synd_code VARCHAR2(30)
202 ,inv_agrmnt_pool_number VARCHAR2(120)
203 ,inv_agrmnt_status_code VARCHAR2(30)
204 ,inv_agrmnt_status VARCHAR2(90)
205 -- added by zrehman Bug#6707320 for Party Merge impact on Accounting sources tables
206 ,customer_id NUMBER
207 ,cust_account_id NUMBER
208 );
209 -----------------------------------------------------------------------------------
210 -- Generic record structure to hold khr / kle line sources for FA/AR/AP transaction
211 -----------------------------------------------------------------------------------
212 TYPE kle_source_rec_type IS RECORD (
213 khr_id NUMBER
214 ,kle_id NUMBER
215 ,contract_line_number VARCHAR2(150)
216 ,asset_number VARCHAR2(150)
217 ,asset_vendor_name VARCHAR2(240)
218 ,installed_site_id VARCHAR2(100)
219 ,fixed_asset_location_name VARCHAR2(250)
220 ,line_type_code VARCHAR2(30)
221 ,line_attribute_category VARCHAR2(90)
222 ,line_attribute1 VARCHAR2(450)
223 ,line_attribute2 VARCHAR2(450)
224 ,line_attribute3 VARCHAR2(450)
225 ,line_attribute4 VARCHAR2(450)
226 ,line_attribute5 VARCHAR2(450)
227 ,line_attribute6 VARCHAR2(450)
228 ,line_attribute7 VARCHAR2(450)
229 ,line_attribute8 VARCHAR2(450)
230 ,line_attribute9 VARCHAR2(450)
231 ,line_attribute10 VARCHAR2(450)
232 ,line_attribute11 VARCHAR2(450)
233 ,line_attribute12 VARCHAR2(450)
234 ,line_attribute13 VARCHAR2(450)
235 ,line_attribute14 VARCHAR2(450)
236 ,line_attribute15 VARCHAR2(450)
237 -- added by zrehman for Bug#6707320 Party Merge impact on Accounting sources tables
238 ,asset_vendor_id NUMBER
239 );
240 -- PL/SQL TYPE Declarations
241 TYPE deprn_asset_rec_type IS RECORD (
242 kle_id NUMBER, -- Id of Line Style FREE_FORM1
243 asset_id NUMBER -- Id of Line Style FIXED_ASSET
244 );
245
246 TYPE deprn_asset_tbl_type IS TABLE OF deprn_asset_rec_type
247 INDEX BY BINARY_INTEGER;
248
249 -- Type Declarations
250 TYPE worker_load_rec IS RECORD (
251 worker_number NUMBER
252 ,worker_load NUMBER
253 ,used BOOLEAN
254 );
255 TYPE worker_load_tab IS TABLE OF worker_load_rec
256 INDEX BY BINARY_INTEGER;
257 ---------------------------------------------------------------------------
258 -- Procedures AND Functions
259 ---------------------------------------------------------------------------
260 PROCEDURE populate_tcn_sources(
261 p_api_version IN NUMBER
262 ,p_init_msg_list IN VARCHAR2
263 ,px_trans_hdr_rec IN OUT NOCOPY tehv_rec_type
264 ,p_acc_sources_rec IN asev_rec_type
265 ,x_return_status OUT NOCOPY VARCHAR2
266 ,x_msg_count OUT NOCOPY NUMBER
267 ,x_msg_data OUT NOCOPY VARCHAR2
268 );
269 -- API Accepting a Single Record
270 -- This API will be called by the Accounting Engine Old Signatures
271 PROCEDURE populate_tcl_sources(
272 p_api_version IN NUMBER
273 ,p_init_msg_list IN VARCHAR2
274 ,px_trans_line_rec IN OUT NOCOPY telv_rec_type
275 ,p_acc_sources_rec IN asev_rec_type
276 ,x_return_status OUT NOCOPY VARCHAR2
277 ,x_msg_count OUT NOCOPY NUMBER
278 ,x_msg_data OUT NOCOPY VARCHAR2
279 );
280
281 -- This API captures the Sources at the Extension Line Level
282 -- and uses the Bulk Insert feature to store them.
283 -- This API will be called by Populate Sources API which is called by
284 -- the new Accounting Engine Signature.
285 PROCEDURE populate_tcl_sources(
286 p_api_version IN NUMBER
287 ,p_init_msg_list IN VARCHAR2
288 ,p_trans_hdr_rec IN tehv_rec_type
289 ,p_acc_sources_tbl IN asev_tbl_type
290 ,p_trans_line_tbl IN telv_tbl_type -- Added by PRASJAIN Bug#6134235
291 ,x_trans_line_tbl OUT NOCOPY telv_tbl_type
292 ,x_return_status OUT NOCOPY VARCHAR2
293 ,x_msg_count OUT NOCOPY NUMBER
294 ,x_msg_data OUT NOCOPY VARCHAR2
295 );
296
297 ---------------------------------------------------------------------------
298 -- Start of comments
299 -- API name : populate_sources
300 -- Pre-reqs : None
301 -- Function : Use this API to populate sources at the Transaction Header
302 -- level and at the Transaction Line level too.
303 -- Parameters :
304 -- IN : p_trans_hdr_rec.source_id IN NUMBER Required
305 -- Pass Transaction Header id.
306 -- p_trans_hdr_rec.source_table IN VARCHAR2 Required
307 -- Pass the table name of the Transaction Header.
308 -- Eg. OKL_TRX_CONTRACTS, OKL_TRX_ASSETS
309 -- p_trans_line_tbl trans_line_tbl_type Required.
310 -- p_trans_line_tbl(i).source_id IN NUMBER Required
311 -- Pass the Transaction Line id
312 -- p_trans_line_tbl(i).source_table VARCHAR2(30) Required
313 -- Pass the table name of the Transaction Table.
314 -- Eg. OKL_TXL_CNTRCT_LNS, OKL_TXL_ASSET_LINES ..
315 -- Version : 1.0
316 -- History : Ravindranath Gooty created
317 -- End of comments
318 ---------------------------------------------------------------------------
319 PROCEDURE populate_sources(
320 p_api_version IN NUMBER
321 ,p_init_msg_list IN VARCHAR2
322 ,p_trans_hdr_rec IN tehv_rec_type
323 ,p_trans_line_tbl IN telv_tbl_type
324 ,p_acc_sources_tbl IN asev_tbl_type
325 ,x_return_status OUT NOCOPY VARCHAR2
326 ,x_msg_count OUT NOCOPY NUMBER
327 ,x_msg_data OUT NOCOPY VARCHAR2
328 );
329
330 ------------------------------------------------------------------------------
331 -- Start of comments
332 -- API name : populate_sources
333 -- Pre-reqs : None
334 -- Function : populate sources for OKL FA Transactions
335 -- Parameters :
336 -- IN :
337 -- fxhv_rec_type.source_id IN NUMBER Required
338 -- fxhv_rec_type.source_table IN VARCHAR2 Required
339 -- fxhv_rec_type.khr_id IN NUMBER Required
340 -- fxhv_rec_type.try_id IN NUMBER Required
341 -- fxlv_rec_type.source_id IN NUMBER Required
342 -- fxlv_rec_type.source_table IN VARCHAR2 Required
343 -- fxlv_rec_type.kle_id IN NUMBER Required
344 -- fxlv_rec_type.asset_id IN NUMBER Required
345 -- fxlv_rec_type.fa_transaction_id IN NUMBER Required
346 -- fxlv_rec_type.asset_book_type_name IN VARCHAR2 Required
347 -- History : Prashant Jain created
348 -- Version : 1.0
349 -- End of comments
350 ------------------------------------------------------------------------------
351 PROCEDURE populate_sources(
352 p_api_version IN NUMBER
353 ,p_init_msg_list IN VARCHAR2
354 ,p_fxhv_rec IN fxhv_rec_type
355 ,p_fxlv_rec IN fxlv_rec_type
356 ,x_return_status OUT NOCOPY VARCHAR2
357 ,x_msg_count OUT NOCOPY NUMBER
358 ,x_msg_data OUT NOCOPY VARCHAR2
359 );
360
361 ------------------------------------------------------------------------------
362 -- Start of comments
363 -- API name : populate_ar_sources
364 -- Pre-reqs : None
365 -- Function : populate sources for OKL AR Transactions
366 -- Parameters :
367 -- IN : rxhv_rec_type.source_id IN NUMBER Required
368 -- rxhv_rec_type.source_table IN VARCHAR2 Required
369
370 -- rxhv_rec_type.khr_id IN NUMBER Required
371 -- rxhv_rec_type.try_id IN NUMBER Required
372 -- rxlv_rec_type.kle_id IN NUMBER Not Mandatory
373 -- rxlv_rec_type.sty_id IN NUMBER Required
374 -- rxlv_rec_type.source_id IN NUMBER Required
375 -- rxlv_rec_type.source_table IN VARCHAR2 Required
376 -- History : Prashant Jain created
377 -- Version : 1.0
378 -- End of comments
379 ------------------------------------------------------------------------------
380 PROCEDURE populate_ar_sources(
381 p_api_version IN NUMBER
382 ,p_init_msg_list IN VARCHAR2
383 ,p_rxhv_rec IN rxhv_rec_type
384 ,p_rxlv_rec IN rxlv_rec_type
385 ,p_acc_sources_rec IN asev_rec_type
386 ,x_return_status OUT NOCOPY VARCHAR2
387 ,x_msg_count OUT NOCOPY NUMBER
388 ,x_msg_data OUT NOCOPY VARCHAR2
389 );
390
391 ------------------------------------------------------------------------------
392 -- Start of comments
393 -- API name : populate_ap_sources
394 -- Pre-reqs : None
395 -- Function : populate sources for OKL AP Transactions
396 -- Parameters :
397 -- IN : pxhv_rec_type.source_id IN NUMBER Required
398 -- pxhv_rec_type.source_table IN VARCHAR2 Required
399
400 -- pxhv_rec_type.khr_id IN NUMBER Required
401 -- pxhv_rec_type.try_id IN NUMBER Required
402 -- pxlv_rec_type.kle_id IN NUMBER Not Mandatory
403 -- pxlv_rec_type.sty_id IN NUMBER Required
404 -- pxlv_rec_type.source_id IN NUMBER Required
405 -- pxlv_rec_type.source_table IN VARCHAR2 Required
406 -- History : Prashant Jain created
407 -- Version : 1.0
408 -- End of comments
409 ------------------------------------------------------------------------------
410 PROCEDURE populate_ap_sources(
411 p_api_version IN NUMBER
412 ,p_init_msg_list IN VARCHAR2
413 ,p_pxhv_rec IN pxhv_rec_type
414 ,p_pxlv_rec IN pxlv_rec_type
415 ,p_acc_sources_rec IN asev_rec_type
416 ,x_return_status OUT NOCOPY VARCHAR2
417 ,x_msg_count OUT NOCOPY NUMBER
418 ,x_msg_data OUT NOCOPY VARCHAR2
419 );
420
421 ------------------------------------------------------------------------------
422 -- Start of comments
423 -- API name : populate_sources
424 -- Pre-reqs : None
425 -- Function : populate sources for OKL AR Transactions
426 -- Parameters :
427 -- IN :
428 -- rxhv_rec_type.source_id IN NUMBER Required
429 -- rxhv_rec_type.source_table IN VARCHAR2 Required
430 -- rxlv_tbl_type.source_id IN NUMBER Required
431 -- rxlv_tbl_type.source_table IN VARCHAR2 Required
432 -- History : Prashant Jain created
433 -- Version : 1.0
434 -- End of comments
435 ------------------------------------------------------------------------------
436 PROCEDURE populate_sources(
437 p_api_version IN NUMBER
438 ,p_init_msg_list IN VARCHAR2
439 ,p_rxhv_rec IN rxhv_rec_type
440 ,p_rxlv_tbl IN rxlv_tbl_type
441 ,p_acc_sources_tbl IN asev_tbl_type
442 ,x_return_status OUT NOCOPY VARCHAR2
443 ,x_msg_count OUT NOCOPY NUMBER
444 ,x_msg_data OUT NOCOPY VARCHAR2
445 );
446
447 ------------------------------------------------------------------------------
448 -- Start of comments
449 -- API name : populate_sources
450 -- Pre-reqs : None
451 -- Function : populate sources for OKL AP Transactions
452 -- Parameters :
453 -- IN :
454 -- pxhv_rec_type.source_id IN NUMBER Required
455 -- pxhv_rec_type.source_table IN VARCHAR2 Required
456 -- History : Prashant Jain created
457 -- Version : 1.0
458 -- End of comments
459 ------------------------------------------------------------------------------
460 PROCEDURE populate_sources(
461 p_api_version IN NUMBER
462 ,p_init_msg_list IN VARCHAR2
463 ,p_pxhv_rec IN pxhv_rec_type
464 ,p_pxlv_tbl IN pxlv_tbl_type
465 ,p_acc_sources_tbl IN asev_tbl_type
466 ,x_return_status OUT NOCOPY VARCHAR2
467 ,x_msg_count OUT NOCOPY NUMBER
468 ,x_msg_data OUT NOCOPY VARCHAR2
469 );
470
471 PROCEDURE delete_trx_extension(
472 p_api_version IN NUMBER
473 ,p_init_msg_list IN VARCHAR2
474 ,p_trans_hdr_rec IN tehv_rec_type
475 ,x_trans_line_tbl OUT NOCOPY telv_tbl_type
476 ,x_return_status OUT NOCOPY VARCHAR2
477 ,x_msg_count OUT NOCOPY NUMBER
478 ,x_msg_data OUT NOCOPY VARCHAR2
479 );
480
481 ------------------------------------------------------------------------------
482 -- Start of comments
483 -- API name : delete_fa_extension
484 -- Pre-reqs : None
485 -- Function : populate sources for OKL FA Transactions
486 -- Parameters :
487 -- IN : p_fxhv_rec.source_id Mandatory
488 -- p_fxhv_rec.source_Table Mandatory
489 --
490 -- History : Ravindranath Gooty created
491 -- Version : 1.0
492 -- End of comments
493 ------------------------------------------------------------------------------
494 PROCEDURE delete_fa_extension(
495 p_api_version IN NUMBER
496 ,p_init_msg_list IN VARCHAR2
497 ,p_fxhv_rec IN fxhv_rec_type
498 ,x_fxlv_tbl OUT NOCOPY fxlv_tbl_type
499 ,x_return_status OUT NOCOPY VARCHAR2
500 ,x_msg_count OUT NOCOPY NUMBER
501 ,x_msg_data OUT NOCOPY VARCHAR2
502 );
503
504 ------------------------------------------------------------------------------
505 -- Start of comments
506 -- API name : delete_ar_extension
507 -- Pre-reqs : None
508 -- Function : populate sources for OKL AR Transactions
509 -- Parameters :
510 -- IN : p_rxhv_rec.source_id Mandatory
511 -- p_rxhv_rec.source_Table Mandatory
512 --
513 -- History : Ravindranath Gooty created
514 -- Version : 1.0
515 -- End of comments
516 ------------------------------------------------------------------------------
517 PROCEDURE delete_ar_extension(
518 p_api_version IN NUMBER
519 ,p_init_msg_list IN VARCHAR2
520 ,p_rxhv_rec IN rxhv_rec_type
521 ,x_rxlv_tbl OUT NOCOPY rxlv_tbl_type
522 ,x_return_status OUT NOCOPY VARCHAR2
523 ,x_msg_count OUT NOCOPY NUMBER
524 ,x_msg_data OUT NOCOPY VARCHAR2
525 );
526
527 ------------------------------------------------------------------------------
528 -- Start of comments
529 -- API name : delete_ap_extension
530 -- Pre-reqs : None
531 -- Function : populate sources for OKL AP Transactions
532 -- Parameters :
533 -- IN : p_pxhv_rec.source_id Mandatory
534 -- p_pxhv_rec.source_Table Mandatory
535 --
536 -- History : Ravindranath Gooty created
537 -- Version : 1.0
538 -- End of comments
539 ------------------------------------------------------------------------------
540 PROCEDURE delete_ap_extension(
541 p_api_version IN NUMBER
542 ,p_init_msg_list IN VARCHAR2
543 ,p_pxhv_rec IN pxhv_rec_type
544 ,x_pxlv_tbl OUT NOCOPY pxlv_tbl_type
545 ,x_return_status OUT NOCOPY VARCHAR2
546 ,x_msg_count OUT NOCOPY NUMBER
547 ,x_msg_data OUT NOCOPY VARCHAR2
548 );
549 ------------------------------------------------------------------------------
550 -- Start of comments
551 -- API name : populate_sources
552 -- Pre-reqs : None
553 -- Function : populate sources for OKL FA Depreciation Transactions
554 -- Parameters :
555 -- IN :
556 -- History : Ravindranath Gooty Created
557 -- Version : 1.0
558 -- End of comments
559 ------------------------------------------------------------------------------
560 PROCEDURE populate_sources(
561 p_api_version IN NUMBER
562 ,p_init_msg_list IN VARCHAR2
563 ,p_khr_id IN NUMBER
564 ,p_deprn_asset_tbl IN deprn_asset_tbl_type
565 ,p_deprn_run_id IN NUMBER
566 ,p_book_type_code IN VARCHAR2
567 ,p_period_counter IN NUMBER
568 ,x_return_status OUT NOCOPY VARCHAR2
569 ,x_msg_count OUT NOCOPY NUMBER
570 ,x_msg_data OUT NOCOPY VARCHAR2
571 );
572
573 ------------------------------------------------------------------------------
574 -- Start of comments
575 -- API name : populate_deprn_sources
576 -- Pre-reqs : None
577 -- Function : populate sources for OKL AP Transactions
578 -- Parameters :
579 -- IN : Asset Book Type Code Mandatory
580 -- Period Counter Mandatory
581 -- Worker ID Mandatory
582 -- Max. Deprn. Run ID Mandatory
583 --
584 -- History : Ravindranath Gooty created
585 -- Version : 1.0
586 -- Description: API called by the Parallel worker for the
587 -- OKL: FA Capture Sources for Depreciation Transaction
588 -- End of comments
589 ------------------------------------------------------------------------------
590 PROCEDURE populate_deprn_sources(
591 errbuf OUT NOCOPY VARCHAR2
592 ,retcode OUT NOCOPY NUMBER
593 ,p_book_type_code IN VARCHAR2
594 ,p_period_counter IN VARCHAR2
595 ,p_worker_id IN VARCHAR2
596 ,p_max_deprn_run_id IN VARCHAR2
597 );
598
599 ------------------------------------------------------------------------------
600 -- Start of comments
601 -- API name : populate_deprn_sources_conc
602 -- Pre-reqs : None
603 -- Function : populate sources for OKL AP Transactions
604 -- Parameters :
605 -- IN : Asset Book Type Code Mandatory
606 -- Period Counter Mandatory
607 -- History : Ravindranath Gooty created
608 -- Version : 1.0
609 -- Description: API called by the Master Program of the conc. job
610 -- OKL: FA Capture Sources for Depreciation Transaction
611 -- End of comments
612 ------------------------------------------------------------------------------
613 PROCEDURE populate_deprn_sources_conc(
614 errbuf OUT NOCOPY VARCHAR2
615 ,retcode OUT NOCOPY NUMBER
616 ,p_book_type_code IN VARCHAR2
617 ,p_period_counter IN NUMBER
618 );
619
620 ------------------------------------------------------------------------------
621 -- Start of comments
622 -- API name : populate_sources
623 -- Pre-reqs : None
624 -- Function : populate sources for OKL Receipt Transactions
625 -- Parameters :
626 -- IN :
627 -- History : Ravindranath Gooty Created
628 -- Version : 1.0
629 -- End of comments
630 ------------------------------------------------------------------------------
631 PROCEDURE populate_sources(
632 p_api_version IN NUMBER
633 ,p_init_msg_list IN VARCHAR2
634 ,p_rxh_rec IN rxh_rec_type
635 ,x_return_status OUT NOCOPY VARCHAR2
636 ,x_msg_count OUT NOCOPY NUMBER
637 ,x_msg_data OUT NOCOPY VARCHAR2
638 );
639
640 END okl_sla_acc_sources_pvt;