DBA Data[Home] [Help]

APPS.FV_LOCKBOX_FC_PKG dependencies on FV_LOCKBOX_IPA_TEMP

Line 15: v_temp_id fv_lockbox_ipa_temp.temp_id%TYPE;

11: v_transmission_id ar_transmissions_all.transmission_id%TYPE;
12: v_batch_id ar_batches.batch_id%TYPE;
13: v_org_id ar_batches.org_id%TYPE;
14: v_invoice_id ra_customer_trx.customer_trx_id%TYPE;
15: v_temp_id fv_lockbox_ipa_temp.temp_id%TYPE;
16: v_debit_memo_id ra_customer_trx.customer_trx_id%TYPE;
17: v_amount ar_payment_schedules.amount_due_remaining%TYPE;
18: v_priority fv_finance_charge_controls.priority%TYPE;
19: v_payment_schedule_id ar_payment_schedules.payment_schedule_id%TYPE;

Line 26: v_appl_dm_id fv_lockbox_ipa_temp.debit_memo_id%TYPE;

22: v_sold_to_customer ar_interim_cash_rcpt_lines_all.sold_to_customer%TYPE;
23: v_transaction_code ar_interim_cash_receipts.ussgl_transaction_code%TYPE;
24: v_appl_inv_amt number;
25: v_appl_amt_remain number;
26: v_appl_dm_id fv_lockbox_ipa_temp.debit_memo_id%TYPE;
27: v_dm_amt fv_lockbox_ipa_temp.amount%TYPE;
28: v_prioirty fv_lockbox_ipa_temp.priority%TYPE;
29: v_dm_pay_sch_id fv_lockbox_ipa_temp.payment_schedule_id%TYPE;
30: v_origin varchar2(1);

Line 27: v_dm_amt fv_lockbox_ipa_temp.amount%TYPE;

23: v_transaction_code ar_interim_cash_receipts.ussgl_transaction_code%TYPE;
24: v_appl_inv_amt number;
25: v_appl_amt_remain number;
26: v_appl_dm_id fv_lockbox_ipa_temp.debit_memo_id%TYPE;
27: v_dm_amt fv_lockbox_ipa_temp.amount%TYPE;
28: v_prioirty fv_lockbox_ipa_temp.priority%TYPE;
29: v_dm_pay_sch_id fv_lockbox_ipa_temp.payment_schedule_id%TYPE;
30: v_origin varchar2(1);
31: v_cash_receipt_id number;

Line 28: v_prioirty fv_lockbox_ipa_temp.priority%TYPE;

24: v_appl_inv_amt number;
25: v_appl_amt_remain number;
26: v_appl_dm_id fv_lockbox_ipa_temp.debit_memo_id%TYPE;
27: v_dm_amt fv_lockbox_ipa_temp.amount%TYPE;
28: v_prioirty fv_lockbox_ipa_temp.priority%TYPE;
29: v_dm_pay_sch_id fv_lockbox_ipa_temp.payment_schedule_id%TYPE;
30: v_origin varchar2(1);
31: v_cash_receipt_id number;
32: v_cash_receipt_line_id_ctr number;

Line 29: v_dm_pay_sch_id fv_lockbox_ipa_temp.payment_schedule_id%TYPE;

25: v_appl_amt_remain number;
26: v_appl_dm_id fv_lockbox_ipa_temp.debit_memo_id%TYPE;
27: v_dm_amt fv_lockbox_ipa_temp.amount%TYPE;
28: v_prioirty fv_lockbox_ipa_temp.priority%TYPE;
29: v_dm_pay_sch_id fv_lockbox_ipa_temp.payment_schedule_id%TYPE;
30: v_origin varchar2(1);
31: v_cash_receipt_id number;
32: v_cash_receipt_line_id_ctr number;
33: v_cash_receipt_line_id number;

Line 128: and exists (select 'x' from fv_lockbox_ipa_temp f

124: 0 sold_to_customer, ussgl_transaction_code
125: from ar_interim_cash_receipts aicr
126: where batch_id = cv_batch_id
127: and customer_trx_id is not null
128: and exists (select 'x' from fv_lockbox_ipa_temp f
129: where f.invoice_id = aicr.customer_trx_id
130: and f.batch_id = aicr.batch_id)
131: union
132: select customer_trx_id, aicrl.payment_amount amount, 'L' origin,

Line 139: and exists (select 'x' from fv_lockbox_ipa_temp f

135: from ar_interim_cash_rcpt_lines_all aicrl
136: where batch_id = cv_batch_id
137: and org_id = cv_org_id
138: and customer_trx_id is not null
139: and exists (select 'x' from fv_lockbox_ipa_temp f
140: where f.invoice_id = aicrl.customer_trx_id
141: and f.batch_id = aicrl.batch_id);
142:
143: cursor c_finchrg_total(cv_trans_id fv_lockbox_ipa_temp.transmission_id%TYPE,

Line 143: cursor c_finchrg_total(cv_trans_id fv_lockbox_ipa_temp.transmission_id%TYPE,

139: and exists (select 'x' from fv_lockbox_ipa_temp f
140: where f.invoice_id = aicrl.customer_trx_id
141: and f.batch_id = aicrl.batch_id);
142:
143: cursor c_finchrg_total(cv_trans_id fv_lockbox_ipa_temp.transmission_id%TYPE,
144: cv_batch_id fv_lockbox_ipa_temp.batch_id%TYPE,
145: cv_invoice_id fv_lockbox_ipa_temp.invoice_id%TYPE) is
146: select debit_memo_id, amount, priority, payment_schedule_id
147: from fv_lockbox_ipa_temp

Line 144: cv_batch_id fv_lockbox_ipa_temp.batch_id%TYPE,

140: where f.invoice_id = aicrl.customer_trx_id
141: and f.batch_id = aicrl.batch_id);
142:
143: cursor c_finchrg_total(cv_trans_id fv_lockbox_ipa_temp.transmission_id%TYPE,
144: cv_batch_id fv_lockbox_ipa_temp.batch_id%TYPE,
145: cv_invoice_id fv_lockbox_ipa_temp.invoice_id%TYPE) is
146: select debit_memo_id, amount, priority, payment_schedule_id
147: from fv_lockbox_ipa_temp
148: where transmission_id = cv_trans_id

Line 145: cv_invoice_id fv_lockbox_ipa_temp.invoice_id%TYPE) is

141: and f.batch_id = aicrl.batch_id);
142:
143: cursor c_finchrg_total(cv_trans_id fv_lockbox_ipa_temp.transmission_id%TYPE,
144: cv_batch_id fv_lockbox_ipa_temp.batch_id%TYPE,
145: cv_invoice_id fv_lockbox_ipa_temp.invoice_id%TYPE) is
146: select debit_memo_id, amount, priority, payment_schedule_id
147: from fv_lockbox_ipa_temp
148: where transmission_id = cv_trans_id
149: and batch_id = cv_batch_id

Line 147: from fv_lockbox_ipa_temp

143: cursor c_finchrg_total(cv_trans_id fv_lockbox_ipa_temp.transmission_id%TYPE,
144: cv_batch_id fv_lockbox_ipa_temp.batch_id%TYPE,
145: cv_invoice_id fv_lockbox_ipa_temp.invoice_id%TYPE) is
146: select debit_memo_id, amount, priority, payment_schedule_id
147: from fv_lockbox_ipa_temp
148: where transmission_id = cv_trans_id
149: and batch_id = cv_batch_id
150: and invoice_id = cv_invoice_id
151: order by priority;

Line 168: -- clear records out of fv_lockbox_ipa_temp for current transmission

164: FV_UTILITY.DEBUG_MESG(FND_LOG.LEVEL_STATEMENT, l_module_name,'STARTING THE MAIN PROCESS. PROCESSING TRANSMISSION '||
165: 'ID '||to_char(v_transmission_id));
166: END IF;
167:
168: -- clear records out of fv_lockbox_ipa_temp for current transmission
169: delete from fv_lockbox_ipa_temp
170: where transmission_id = v_transmission_id;
171:
172: -- finding all batches within the transmission.

Line 169: delete from fv_lockbox_ipa_temp

165: 'ID '||to_char(v_transmission_id));
166: END IF;
167:
168: -- clear records out of fv_lockbox_ipa_temp for current transmission
169: delete from fv_lockbox_ipa_temp
170: where transmission_id = v_transmission_id;
171:
172: -- finding all batches within the transmission.
173: FOR c_batches_rec IN c_batches(v_transmission_id) LOOP

Line 184: FV_UTILITY.DEBUG_MESG(FND_LOG.LEVEL_STATEMENT, l_module_name,'POPULATING FV_LOCKBOX_IPA_TEMP W/TOTALS OF DEBIT MEMOS');

180: v_org_id := c_batches_rec.org_id;
181:
182: IF (FND_LOG.LEVEL_STATEMENT >= FND_LOG.G_CURRENT_RUNTIME_LEVEL ) then
183: FV_UTILITY.DEBUG_MESG(FND_LOG.LEVEL_STATEMENT, l_module_name,'FINDING ALL RECEIPTS THAT ARE APPLIED TO INVOICES');
184: FV_UTILITY.DEBUG_MESG(FND_LOG.LEVEL_STATEMENT, l_module_name,'POPULATING FV_LOCKBOX_IPA_TEMP W/TOTALS OF DEBIT MEMOS');
185: END IF;
186: -- finding all the receipts applied to invoices within the batch
187: FOR c_invoices_rec IN c_invoices(v_batch_id,v_org_id) LOOP
188:

Line 200: SELECT fv_lockbox_ipa_temp_s.nextval

196: v_priority := c_debit_memo_rec.priority;
197: v_payment_schedule_id := c_debit_memo_rec.payment_schedule_id;
198:
199: BEGIN
200: SELECT fv_lockbox_ipa_temp_s.nextval
201: INTO v_temp_id
202: FROM dual;
203:
204: EXCEPTION

Line 207: v_errbuf := 'fv_lockbox_ipa_temp_s '||sqlerrm;

203:
204: EXCEPTION
205: WHEN others THEN
206: v_retcode := '2';
207: v_errbuf := 'fv_lockbox_ipa_temp_s '||sqlerrm;
208: FV_UTILITY.LOG_MESG(FND_LOG.LEVEL_ERROR, l_module_name||'.error1',v_errbuf);
209: ROLLBACK;
210: RAISE;
211: END;

Line 214: insert into fv_lockbox_ipa_temp(temp_id,

210: RAISE;
211: END;
212:
213: -- setting up debit memo temp data
214: insert into fv_lockbox_ipa_temp(temp_id,
215: invoice_id,
216: debit_memo_id,
217: amount,
218: priority,

Line 247: update fv_lockbox_ipa_temp

243: -- any debit memos in the batch. This is being done by finding
244: -- all finance charge debit memo's in the batch and reducing the
245: -- the total amount of the fc dm available to apply.
246:
247: update fv_lockbox_ipa_temp
248: set amount = amount - nvl(c_receipt_dms_rec.amount,0)
249: where debit_memo_id = c_receipt_dms_rec.customer_trx_id
250: and batch_id = v_batch_id
251: and transmission_id = v_transmission_id

Line 580: -- This process updates fv_lockbox_ipa_temp. It decreases the total amount

576:
577: -- ------------------------------------------------------------------------
578: -- PROCEDURE updated_lockbox_temp
579: -- ------------------------------------------------------------------------
580: -- This process updates fv_lockbox_ipa_temp. It decreases the total amount
581: -- available for application on a debit memo. This is done so that the process
582: -- knows the current amount available for application in a receipt.
583: -- ------------------------------------------------------------------------
584:

Line 590: update fv_lockbox_ipa_temp

586: l_module_name VARCHAR2(200) := g_module_name || 'update_lockbox_temp';
587:
588: BEGIN
589:
590: update fv_lockbox_ipa_temp
591: set amount = nvl(amount,0) - nvl(v_decrease_dm_amount,0)
592: where debit_memo_id = v_appl_dm_id -- current debit memo being processed
593: and invoice_id = v_appl_inv_id -- current invoice being processed
594: and batch_id = v_batch_id; -- curent batch being processed