DBA Data[Home] [Help]

APPS.JAI_RCV_THIRD_PARTY_PKG dependencies on RCV_TRANSACTIONS

Line 29: generated, third_party_flag in JAI_RCV_TRANSACTIONS is set to 'G'

25: third party invoices only once. All RECEIVE and CORRECT of RECEIVE
26: type of transactions are considered for generating third party invoices.
27:
28: If a CORRECT to RECEIVE happens after third party invoice is
29: generated, third_party_flag in JAI_RCV_TRANSACTIONS is set to 'G'
30: to indicate that third party invoice has already been generated.
31:
32: This clean up also has introduced two tables which help in tracking
33: third party invoices.

Line 79: (c) Removed two separate conditions on jai_rcv_Transactions

75: (1) Added conditions in procedure process_receipt
76: in cursor c_thirdparty_tax_rec.
77: (a) Added shipment header id condition
78: (b) added aliases.
79: (c) Removed two separate conditions on jai_rcv_Transactions
80: and clubbed into a single one.
81: (2) Added aliases for the following cursors.
82: (a) c_get_thirdparty_count
83: (b) c_get_thirdparty_null_site_cnt

Line 148: lv_ttype_receive JAI_RCV_TRANSACTIONS.transaction_type%type;

144: )
145: is
146:
147: /* Added by Ramananda for removal of SQL LITERALs */
148: lv_ttype_receive JAI_RCV_TRANSACTIONS.transaction_type%type;
149: lv_ttype_correct JAI_RCV_TRANSACTIONS.transaction_type%type;
150:
151: cursor c_pending_tp_receipts(cp_org_id number) is
152: /* modified cursor - included org_id parameter for bug 4695630 */

Line 149: lv_ttype_correct JAI_RCV_TRANSACTIONS.transaction_type%type;

145: is
146:
147: /* Added by Ramananda for removal of SQL LITERALs */
148: lv_ttype_receive JAI_RCV_TRANSACTIONS.transaction_type%type;
149: lv_ttype_correct JAI_RCV_TRANSACTIONS.transaction_type%type;
150:
151: cursor c_pending_tp_receipts(cp_org_id number) is
152: /* modified cursor - included org_id parameter for bug 4695630 */
153: /* Modified by Ramananda for removal of SQL LITERALs :bug#4428980*/

Line 155: from JAI_RCV_TRANSACTIONS jrt

151: cursor c_pending_tp_receipts(cp_org_id number) is
152: /* modified cursor - included org_id parameter for bug 4695630 */
153: /* Modified by Ramananda for removal of SQL LITERALs :bug#4428980*/
154: select shipment_header_id -- Bug 4941642
155: from JAI_RCV_TRANSACTIONS jrt
156: where ( transaction_type = lv_ttype_receive --'RECEIVE'
157: or
158: (transaction_type = lv_ttype_correct and parent_transaction_type = lv_ttype_receive) --'CORRECT', 'RECEIVE'
159: )

Line 301: update JAI_RCV_TRANSACTIONS jrt

297: );
298:
299:
300: if nvl(p_simulation, 'N') <> 'Y' then
301: update JAI_RCV_TRANSACTIONS jrt
302: set third_party_flag = lv_process_flag
303: where shipment_header_id = r_pending_tp_receipts.shipment_header_id
304: and ( transaction_type = 'RECEIVE'
305: or

Line 405: cursor c_rcv_transactions

401: select receipt_num
402: from rcv_shipment_headers
403: where shipment_header_id = p_shipment_header_id;
404:
405: cursor c_rcv_transactions
406: (p_shipment_header_id number)is
407: select
408: vendor_id,
409: vendor_site_id, --added by eric for inclusive tax on 20-dec-2007

Line 419: from rcv_transactions

415: currency_code,
416: currency_conversion_type,
417: currency_conversion_date,
418: currency_conversion_rate
419: from rcv_transactions
420: where shipment_header_id = p_shipment_header_id
421: and transaction_type = 'RECEIVE';
422:
423: /* Added by Ramananda for removal of SQL LITERALs */

Line 424: lv_ttype_receive JAI_RCV_TRANSACTIONS.transaction_type%type;

420: where shipment_header_id = p_shipment_header_id
421: and transaction_type = 'RECEIVE';
422:
423: /* Added by Ramananda for removal of SQL LITERALs */
424: lv_ttype_receive JAI_RCV_TRANSACTIONS.transaction_type%type;
425: lv_ttype_correct JAI_RCV_TRANSACTIONS.transaction_type%type;
426:
427: /* Bug 4941642. Added by Lakshmi Gopalsami
428: Added aliases for the following cursors and

Line 425: lv_ttype_correct JAI_RCV_TRANSACTIONS.transaction_type%type;

421: and transaction_type = 'RECEIVE';
422:
423: /* Added by Ramananda for removal of SQL LITERALs */
424: lv_ttype_receive JAI_RCV_TRANSACTIONS.transaction_type%type;
425: lv_ttype_correct JAI_RCV_TRANSACTIONS.transaction_type%type;
426:
427: /* Bug 4941642. Added by Lakshmi Gopalsami
428: Added aliases for the following cursors and
429: Added alias and shipment_header_id and

Line 448: from JAI_RCV_TRANSACTIONS jrt

444: where jrlt.shipment_header_id = p_shipment_header_id
445: and EXISTS
446: (
447: select 1
448: from JAI_RCV_TRANSACTIONS jrt
449: where jrt.shipment_header_id = jrlt.shipment_header_id
450: AND jrt.shipment_line_id = jrlt.shipment_line_id
451: AND ( jrt.transaction_type = lv_ttype_receive --'RECEIVE'
452: or

Line 481: from JAI_RCV_TRANSACTIONS jrt

477: where jrlt.shipment_header_id = p_shipment_header_id
478: and EXISTS
479: (
480: select 1
481: from JAI_RCV_TRANSACTIONS jrt
482: where jrt.shipment_header_id = jrlt.shipment_header_id
483: AND jrt.shipment_line_id = jrlt.shipment_line_id
484: AND ( jrt.transaction_type = lv_ttype_receive --'RECEIVE'
485: or

Line 515: from JAI_RCV_TRANSACTIONS jrt

511: where jrlt.shipment_header_id = p_shipment_header_id
512: and EXISTS
513: (
514: select 1
515: from JAI_RCV_TRANSACTIONS jrt
516: where jrt.shipment_header_id = jrlt.shipment_header_id
517: AND jrt.shipment_line_id = jrlt.shipment_line_id
518: AND ( jrt.transaction_type = lv_ttype_receive
519: or

Line 604: from JAI_RCV_TRANSACTIONS

600: from dual;
601:
602: cursor c_check_if_already_processed(p_shipment_header_id number) is
603: select count(transaction_id)
604: from JAI_RCV_TRANSACTIONS
605: where shipment_header_id = p_shipment_header_id
606: and third_party_flag not in ('N', 'X');
607:
608:

Line 618: r_rcv_transactions c_rcv_transactions%rowtype;

614: ln_accrual_account number;
615: ld_goods_received_date date;
616: lv_receipt_num rcv_shipment_headers.receipt_num%type;
617:
618: r_rcv_transactions c_rcv_transactions%rowtype;
619: r_get_vendor_details c_get_vendor_details%rowtype;
620:
621: lv_description ap_invoices_interface.description%type;
622: ln_tax_amount number;

Line 623: lv_currency_conversion_type rcv_transactions.currency_conversion_type%type;

619: r_get_vendor_details c_get_vendor_details%rowtype;
620:
621: lv_description ap_invoices_interface.description%type;
622: ln_tax_amount number;
623: lv_currency_conversion_type rcv_transactions.currency_conversion_type%type;
624: lv_currency_conversion_rate rcv_transactions.currency_conversion_rate%type;
625: lv_currency_conversion_date date;
626: ln_uid number; --File.Sql.35 Cbabu := fnd_global.user_id;
627: ln_inv_run_no number;

Line 624: lv_currency_conversion_rate rcv_transactions.currency_conversion_rate%type;

620:
621: lv_description ap_invoices_interface.description%type;
622: ln_tax_amount number;
623: lv_currency_conversion_type rcv_transactions.currency_conversion_type%type;
624: lv_currency_conversion_rate rcv_transactions.currency_conversion_rate%type;
625: lv_currency_conversion_date date;
626: ln_uid number; --File.Sql.35 Cbabu := fnd_global.user_id;
627: ln_inv_run_no number;
628: lv_invoice_num ap_invoices_all.invoice_num%type;

Line 651: lv_orig_currcy_conver_type rcv_transactions.currency_conversion_type%type; --added by eric for inclusive tax on 20-dec-2007

647: ln_lines_to_insert NUMBER default 1; --added by eric for inclusive tax on 20-dec-2007
648: ln_tax_line_amount NUMBER; --added by eric for inclusive tax on 20-dec-2007
649: orig_vndr_details_rec c_get_vendor_details%rowtype; --added by eric for inclusive tax on 20-dec-2007
650: ld_orig_goods_recv_date DATE; --added by eric for inclusive tax on 20-dec-2007
651: lv_orig_currcy_conver_type rcv_transactions.currency_conversion_type%type; --added by eric for inclusive tax on 20-dec-2007
652: lv_orig_currcy_conver_rate rcv_transactions.currency_conversion_rate%type; --added by eric for inclusive tax on 20-dec-2007
653: lv_orig_currcy_conver_date date; --added by eric for inclusive tax on 20-dec-2007
654:
655: --added the below cursor for bug#6988610 by eric on Apr 24,2008 ,begin

Line 652: lv_orig_currcy_conver_rate rcv_transactions.currency_conversion_rate%type; --added by eric for inclusive tax on 20-dec-2007

648: ln_tax_line_amount NUMBER; --added by eric for inclusive tax on 20-dec-2007
649: orig_vndr_details_rec c_get_vendor_details%rowtype; --added by eric for inclusive tax on 20-dec-2007
650: ld_orig_goods_recv_date DATE; --added by eric for inclusive tax on 20-dec-2007
651: lv_orig_currcy_conver_type rcv_transactions.currency_conversion_type%type; --added by eric for inclusive tax on 20-dec-2007
652: lv_orig_currcy_conver_rate rcv_transactions.currency_conversion_rate%type; --added by eric for inclusive tax on 20-dec-2007
653: lv_orig_currcy_conver_date date; --added by eric for inclusive tax on 20-dec-2007
654:
655: --added the below cursor for bug#6988610 by eric on Apr 24,2008 ,begin
656: -----------------------------------------------------------------------

Line 674: from JAI_RCV_TRANSACTIONS jrt

670: , jai_cmn_taxes_all jcta --added by eric for inclusive tax
671: where
672: ( jrtv.transaction_id, jrtv.shipment_line_id ) IN
673: ( select transaction_id, shipment_line_id
674: from JAI_RCV_TRANSACTIONS jrt
675: where shipment_header_id = pn_shipment_header_id
676: and ( transaction_type = lv_ttype_receive --'RECEIVE'
677: or
678: (transaction_type = lv_ttype_correct

Line 733: open c_rcv_transactions(p_shipment_header_id);

729: end if;
730:
731:
732: /* Validation#1 : Check if PO details exist */
733: open c_rcv_transactions(p_shipment_header_id);
734: fetch c_rcv_transactions into r_rcv_transactions;
735: close c_rcv_transactions;
736:
737: if r_rcv_transactions.vendor_id is null then

Line 734: fetch c_rcv_transactions into r_rcv_transactions;

730:
731:
732: /* Validation#1 : Check if PO details exist */
733: open c_rcv_transactions(p_shipment_header_id);
734: fetch c_rcv_transactions into r_rcv_transactions;
735: close c_rcv_transactions;
736:
737: if r_rcv_transactions.vendor_id is null then
738:

Line 735: close c_rcv_transactions;

731:
732: /* Validation#1 : Check if PO details exist */
733: open c_rcv_transactions(p_shipment_header_id);
734: fetch c_rcv_transactions into r_rcv_transactions;
735: close c_rcv_transactions;
736:
737: if r_rcv_transactions.vendor_id is null then
738:
739: if p_debug >= 1 then

Line 737: if r_rcv_transactions.vendor_id is null then

733: open c_rcv_transactions(p_shipment_header_id);
734: fetch c_rcv_transactions into r_rcv_transactions;
735: close c_rcv_transactions;
736:
737: if r_rcv_transactions.vendor_id is null then
738:
739: if p_debug >= 1 then
740: Fnd_File.put_line(Fnd_File.LOG,
741: ' Debug Level 1 : Details from rcv_transactions are not found for this shipment header, cannot process' );

Line 741: ' Debug Level 1 : Details from rcv_transactions are not found for this shipment header, cannot process' );

737: if r_rcv_transactions.vendor_id is null then
738:
739: if p_debug >= 1 then
740: Fnd_File.put_line(Fnd_File.LOG,
741: ' Debug Level 1 : Details from rcv_transactions are not found for this shipment header, cannot process' );
742: end if;
743:
744: p_process_flag := 'E';
745: p_process_message := 'Details from rcv_transactions are not found for this shipment header, cannot process';

Line 745: p_process_message := 'Details from rcv_transactions are not found for this shipment header, cannot process';

741: ' Debug Level 1 : Details from rcv_transactions are not found for this shipment header, cannot process' );
742: end if;
743:
744: p_process_flag := 'E';
745: p_process_message := 'Details from rcv_transactions are not found for this shipment header, cannot process';
746: goto exit_from_procedure;
747:
748: end if;
749:

Line 756: (p_shipment_header_id, r_rcv_transactions.vendor_id);

752: lv_ttype_correct := 'CORRECT' ;
753:
754: /* Validation#2 : Check if third party taxes exist */
755: open c_get_thirdparty_count
756: (p_shipment_header_id, r_rcv_transactions.vendor_id);
757: fetch c_get_thirdparty_count into ln_thirdparty_count;
758: close c_get_thirdparty_count;
759:
760: if nvl(ln_thirdparty_count, 0) = 0 then

Line 778: (p_shipment_header_id, r_rcv_transactions.vendor_id);

774: lv_ttype_receive := 'RECEIVE' ;
775: lv_ttype_correct := 'CORRECT' ;
776:
777: open c_get_thirdparty_null_site_cnt
778: (p_shipment_header_id, r_rcv_transactions.vendor_id);
779: fetch c_get_thirdparty_null_site_cnt into ln_thirdparty_null_site_cnt;
780: close c_get_thirdparty_null_site_cnt;
781:
782: if nvl(ln_thirdparty_null_site_cnt, 0) > 0 then

Line 801: (p_shipment_header_id, r_rcv_transactions.vendor_id);

797: /* Added by Ramananda for removal of SQL LITERALs */
798: lv_ttype_receive := 'RECEIVE' ;
799: lv_ttype_correct := 'CORRECT' ;
800: open c_get_tparty_invalid_comb_cnt
801: (p_shipment_header_id, r_rcv_transactions.vendor_id);
802: fetch c_get_tparty_invalid_comb_cnt into ln_tparty_invalid_comb_cnt;
803: close c_get_tparty_invalid_comb_cnt;
804:
805: if nvl(ln_tparty_invalid_comb_cnt, 0) > 0 then

Line 832: if r_rcv_transactions.po_distribution_id is not null then

828: open c_rcv_shipment_headers(p_shipment_header_id);
829: fetch c_rcv_shipment_headers into lv_receipt_num;
830: close c_rcv_shipment_headers;
831:
832: if r_rcv_transactions.po_distribution_id is not null then
833:
834: open c_get_po_dist_account(r_rcv_transactions.po_distribution_id);
835: fetch c_get_po_dist_account into ln_accrual_account;
836: close c_get_po_dist_account;

Line 834: open c_get_po_dist_account(r_rcv_transactions.po_distribution_id);

830: close c_rcv_shipment_headers;
831:
832: if r_rcv_transactions.po_distribution_id is not null then
833:
834: open c_get_po_dist_account(r_rcv_transactions.po_distribution_id);
835: fetch c_get_po_dist_account into ln_accrual_account;
836: close c_get_po_dist_account;
837:
838: elsif r_rcv_transactions.po_line_location_id is not null then

Line 838: elsif r_rcv_transactions.po_line_location_id is not null then

834: open c_get_po_dist_account(r_rcv_transactions.po_distribution_id);
835: fetch c_get_po_dist_account into ln_accrual_account;
836: close c_get_po_dist_account;
837:
838: elsif r_rcv_transactions.po_line_location_id is not null then
839:
840: open c_get_latest_po_dist_account(r_rcv_transactions.po_line_location_id);
841: fetch c_get_latest_po_dist_account into ln_accrual_account;
842: close c_get_latest_po_dist_account;

Line 840: open c_get_latest_po_dist_account(r_rcv_transactions.po_line_location_id);

836: close c_get_po_dist_account;
837:
838: elsif r_rcv_transactions.po_line_location_id is not null then
839:
840: open c_get_latest_po_dist_account(r_rcv_transactions.po_line_location_id);
841: fetch c_get_latest_po_dist_account into ln_accrual_account;
842: close c_get_latest_po_dist_account;
843:
844: end if;

Line 855: r_rcv_transactions.organization_id,

851:
852: -- get the functional currency
853: jai_rcv_utils_pkg.get_func_curr
854: (
855: r_rcv_transactions.organization_id,
856: lv_func_currency,
857: ln_gl_set_of_books_id
858: );
859:

Line 869: (3) Removed two separate conditions on jai_rcv_Transactions

865: (
866: /*Bug 4941642. Added by Lakshmi Gopalsami
867: (1) Added shipment header id condition
868: (2) added aliases.
869: (3) Removed two separate conditions on jai_rcv_Transactions
870: and clubbed into a single one.
871: */
872: select
873: jrtv.vendor_id

Line 885: from JAI_RCV_TRANSACTIONS jrt

881: , jai_cmn_taxes_all jcta --added by eric for inclusive tax
882: where
883: ( jrtv.transaction_id, jrtv.shipment_line_id ) IN
884: ( select transaction_id, shipment_line_id
885: from JAI_RCV_TRANSACTIONS jrt
886: where shipment_header_id = p_shipment_header_id
887: and ( transaction_type = lv_ttype_receive --'RECEIVE'
888: or
889: (transaction_type = lv_ttype_correct

Line 898: and jrtv.vendor_id <> r_rcv_transactions.vendor_id /* bug#3957167 */

894: )
895: and jrtv.tax_type not in (jai_constants.tax_type_tds,jai_constants.tax_type_modvat_recovery) --'TDS', 'Modvat Recovery')
896: and jrtv.vendor_id > 0
897: and nvl(jrtv.tax_amount, 0) is not null
898: and jrtv.vendor_id <> r_rcv_transactions.vendor_id /* bug#3957167 */
899: and jrtv.shipment_header_id = p_shipment_header_id
900: and jrtv.tax_id = jcta.tax_id --added by eric for inclusive tax
901: GROUP BY
902: jrtv.vendor_id

Line 1025: lv_currency_conversion_type := r_rcv_transactions.currency_conversion_type;

1021:
1022: ln_tax_amount := c_thirdparty_tax_rec.tax_amount;
1023:
1024: if c_thirdparty_tax_rec.currency <> lv_func_currency then
1025: lv_currency_conversion_type := r_rcv_transactions.currency_conversion_type;
1026: lv_currency_conversion_rate := r_rcv_transactions.currency_conversion_rate;
1027: lv_currency_conversion_date := r_rcv_transactions.currency_conversion_date;
1028: else
1029: lv_currency_conversion_type := null;

Line 1026: lv_currency_conversion_rate := r_rcv_transactions.currency_conversion_rate;

1022: ln_tax_amount := c_thirdparty_tax_rec.tax_amount;
1023:
1024: if c_thirdparty_tax_rec.currency <> lv_func_currency then
1025: lv_currency_conversion_type := r_rcv_transactions.currency_conversion_type;
1026: lv_currency_conversion_rate := r_rcv_transactions.currency_conversion_rate;
1027: lv_currency_conversion_date := r_rcv_transactions.currency_conversion_date;
1028: else
1029: lv_currency_conversion_type := null;
1030: lv_currency_conversion_rate := null;

Line 1027: lv_currency_conversion_date := r_rcv_transactions.currency_conversion_date;

1023:
1024: if c_thirdparty_tax_rec.currency <> lv_func_currency then
1025: lv_currency_conversion_type := r_rcv_transactions.currency_conversion_type;
1026: lv_currency_conversion_rate := r_rcv_transactions.currency_conversion_rate;
1027: lv_currency_conversion_date := r_rcv_transactions.currency_conversion_date;
1028: else
1029: lv_currency_conversion_type := null;
1030: lv_currency_conversion_rate := null;
1031: lv_currency_conversion_date := null;

Line 1178: OPEN c_get_vendor_site_dtls(r_rcv_transactions.vendor_site_id);

1174: CLOSE get_totl_incl_tax_amount;
1175: -----------------------------------------------------------------------
1176: --added by eric for BUG#6988610 on Apr-24,2008, End
1177:
1178: OPEN c_get_vendor_site_dtls(r_rcv_transactions.vendor_site_id);
1179: FETCH c_get_vendor_site_dtls
1180: INTO orig_vndr_details_rec;
1181: CLOSE c_get_vendor_site_dtls;
1182:

Line 1189: OPEN c_get_vendor_details(r_rcv_transactions.vendor_id);

1185: OR orig_vndr_details_rec.payment_method_lookup_code IS NULL
1186: OR orig_vndr_details_rec.pay_group_lookup_code IS NULL
1187: )
1188: THEN
1189: OPEN c_get_vendor_details(r_rcv_transactions.vendor_id);
1190: FETCH c_get_vendor_details
1191: INTO orig_vndr_details_rec;
1192: CLOSE c_get_vendor_details;
1193: END IF; -- IF( orig_vndr_details_rec.terms_id IS NULL)

Line 1195: OPEN c_get_goods_received_date(r_rcv_transactions.vendor_id , r_rcv_transactions.vendor_site_id);

1191: INTO orig_vndr_details_rec;
1192: CLOSE c_get_vendor_details;
1193: END IF; -- IF( orig_vndr_details_rec.terms_id IS NULL)
1194:
1195: OPEN c_get_goods_received_date(r_rcv_transactions.vendor_id , r_rcv_transactions.vendor_site_id);
1196: FETCH c_get_goods_received_date
1197: INTO ld_orig_goods_recv_date;
1198: CLOSE c_get_goods_received_date;
1199:

Line 1200: IF r_rcv_transactions.currency_code <> lv_func_currency then

1196: FETCH c_get_goods_received_date
1197: INTO ld_orig_goods_recv_date;
1198: CLOSE c_get_goods_received_date;
1199:
1200: IF r_rcv_transactions.currency_code <> lv_func_currency then
1201: lv_orig_currcy_conver_type := r_rcv_transactions.currency_conversion_type;
1202: lv_orig_currcy_conver_rate := r_rcv_transactions.currency_conversion_rate;
1203: lv_orig_currcy_conver_date := r_rcv_transactions.currency_conversion_date;
1204: ELSE

Line 1201: lv_orig_currcy_conver_type := r_rcv_transactions.currency_conversion_type;

1197: INTO ld_orig_goods_recv_date;
1198: CLOSE c_get_goods_received_date;
1199:
1200: IF r_rcv_transactions.currency_code <> lv_func_currency then
1201: lv_orig_currcy_conver_type := r_rcv_transactions.currency_conversion_type;
1202: lv_orig_currcy_conver_rate := r_rcv_transactions.currency_conversion_rate;
1203: lv_orig_currcy_conver_date := r_rcv_transactions.currency_conversion_date;
1204: ELSE
1205: lv_orig_currcy_conver_type := null;

Line 1202: lv_orig_currcy_conver_rate := r_rcv_transactions.currency_conversion_rate;

1198: CLOSE c_get_goods_received_date;
1199:
1200: IF r_rcv_transactions.currency_code <> lv_func_currency then
1201: lv_orig_currcy_conver_type := r_rcv_transactions.currency_conversion_type;
1202: lv_orig_currcy_conver_rate := r_rcv_transactions.currency_conversion_rate;
1203: lv_orig_currcy_conver_date := r_rcv_transactions.currency_conversion_date;
1204: ELSE
1205: lv_orig_currcy_conver_type := null;
1206: lv_orig_currcy_conver_rate := null;

Line 1203: lv_orig_currcy_conver_date := r_rcv_transactions.currency_conversion_date;

1199:
1200: IF r_rcv_transactions.currency_code <> lv_func_currency then
1201: lv_orig_currcy_conver_type := r_rcv_transactions.currency_conversion_type;
1202: lv_orig_currcy_conver_rate := r_rcv_transactions.currency_conversion_rate;
1203: lv_orig_currcy_conver_date := r_rcv_transactions.currency_conversion_date;
1204: ELSE
1205: lv_orig_currcy_conver_type := null;
1206: lv_orig_currcy_conver_rate := null;
1207: lv_orig_currcy_conver_date := null;

Line 1218: p_vendor_id => r_rcv_transactions.vendor_id, --changed by eric for inclusive tax

1214: p_invoice_id => ln_interface_invoice_id,
1215: p_invoice_num => lv_invoice_num,
1216: p_invoice_type_lookup_code => 'CREDIT', /* CREDIT Memo*/ --changed by eric for inclusive tax
1217: p_invoice_date => SYSDATE,
1218: p_vendor_id => r_rcv_transactions.vendor_id, --changed by eric for inclusive tax
1219: p_vendor_site_id => r_rcv_transactions.vendor_site_id, --changed by eric for inclusive tax
1220: --p_invoice_amount => ROUND(-ln_tax_amount,2), --changed by eric for inclusive tax,deleted by eric for bug#6988610
1221: p_invoice_amount => ROUND(-ln_totl_incl_tax_amount,2), --changed by eric for bug#6988610 on Apr 23,2008
1222: p_invoice_currency_code => r_rcv_transactions.currency_code, --changed by eric for inclusive tax

Line 1219: p_vendor_site_id => r_rcv_transactions.vendor_site_id, --changed by eric for inclusive tax

1215: p_invoice_num => lv_invoice_num,
1216: p_invoice_type_lookup_code => 'CREDIT', /* CREDIT Memo*/ --changed by eric for inclusive tax
1217: p_invoice_date => SYSDATE,
1218: p_vendor_id => r_rcv_transactions.vendor_id, --changed by eric for inclusive tax
1219: p_vendor_site_id => r_rcv_transactions.vendor_site_id, --changed by eric for inclusive tax
1220: --p_invoice_amount => ROUND(-ln_tax_amount,2), --changed by eric for inclusive tax,deleted by eric for bug#6988610
1221: p_invoice_amount => ROUND(-ln_totl_incl_tax_amount,2), --changed by eric for bug#6988610 on Apr 23,2008
1222: p_invoice_currency_code => r_rcv_transactions.currency_code, --changed by eric for inclusive tax
1223: p_exchange_rate => lv_orig_currcy_conver_type, --changed by eric for inclusive tax

Line 1222: p_invoice_currency_code => r_rcv_transactions.currency_code, --changed by eric for inclusive tax

1218: p_vendor_id => r_rcv_transactions.vendor_id, --changed by eric for inclusive tax
1219: p_vendor_site_id => r_rcv_transactions.vendor_site_id, --changed by eric for inclusive tax
1220: --p_invoice_amount => ROUND(-ln_tax_amount,2), --changed by eric for inclusive tax,deleted by eric for bug#6988610
1221: p_invoice_amount => ROUND(-ln_totl_incl_tax_amount,2), --changed by eric for bug#6988610 on Apr 23,2008
1222: p_invoice_currency_code => r_rcv_transactions.currency_code, --changed by eric for inclusive tax
1223: p_exchange_rate => lv_orig_currcy_conver_type, --changed by eric for inclusive tax
1224: p_exchange_rate_type => lv_orig_currcy_conver_rate, --changed by eric for inclusive tax
1225: p_exchange_date => lv_orig_currcy_conver_date, --changed by eric for inclusive tax
1226: p_terms_id => orig_vndr_details_rec.terms_id, --changed by eric for inclusive tax

Line 1269: (3) Removed two separate conditions on jai_rcv_Transactions

1265:
1266: /*Bug 4941642. Added by Lakshmi Gopalsami
1267: (1) Added shipment header id condition
1268: (2) added aliases.
1269: (3) Removed two separate conditions on jai_rcv_Transactions
1270: and clubbed into a single one.
1271: */
1272: FOR Tax_rec IN
1273: ( SELECT

Line 1282: FROM JAI_RCV_TRANSACTIONS jrt

1278: , jai_cmn_taxes_all jcta --added by eric for inclusive tax
1279: WHERE jrlt.shipment_header_id = p_shipment_header_id
1280: AND (jrlt.transaction_id, jrlt.shipment_line_id) in
1281: ( SELECT jrt.transaction_id,jrt.shipment_line_id
1282: FROM JAI_RCV_TRANSACTIONS jrt
1283: WHERE jrt.shipment_header_id = p_shipment_header_id
1284: AND ( jrt.transaction_type = lv_ttype_receive
1285: or
1286: (jrt.transaction_type = lv_ttype_correct

Line 1295: AND jrlt.vendor_id <> r_rcv_transactions.vendor_id

1291: )
1292: AND jrlt.tax_type NOT IN (jai_constants.tax_type_tds,jai_constants.tax_type_modvat_recovery) --'TDS', 'Modvat Recovery')
1293: AND jrlt.vendor_id > 0
1294: AND nvl(jrlt.tax_amount, 0) IS NOT NULL
1295: AND jrlt.vendor_id <> r_rcv_transactions.vendor_id
1296: AND jrlt.vendor_id = c_thirdparty_tax_rec.vendor_id
1297: AND jrlt.vendor_site_id = c_thirdparty_tax_rec.vendor_site_id
1298: AND jrlt.currency = c_thirdparty_tax_rec.currency
1299: AND jrlt.tax_id = jcta.tax_id --added by eric for inclusive tax

Line 1405: p_accounting_date => r_rcv_transactions.transaction_date,

1401: p_line_type_lookup_code => 'ITEM', --added by eric FOR BUG bug#6790599
1402: --Modified by eric for inclusive tax ,begin
1403: p_amount => ln_tax_line_amount,-- round(tax_Rec.tax_amount,2),
1404: --Modified by eric for inclusive tax ,end
1405: p_accounting_date => r_rcv_transactions.transaction_date,
1406: p_description => lv_description,
1407: p_dist_code_combination_id => ln_accrual_account,
1408: p_assets_tracking_flag => lv_assets_tracking_flag,
1409: p_created_by => ln_uid,