DBA Data[Home] [Help]

APPS.JAI_TRX_REPO_EXTRACT_PKG dependencies on JAI_CONSTANTS

Line 128: or (p_query_settled_flag = jai_constants.yes)

124: and (p_location_id is null or recs.location_id = p_location_id )
125: and trunc(transaction_date) between nvl (p_from_trx_date, trunc(transaction_date)) and nvl (p_to_trx_date, trunc(transaction_date))
126: and recs.regime_code = p_regime_code
127: and ( (p_query_settled_flag = 'N' and (recs.settlement_id is null))
128: or (p_query_settled_flag = jai_constants.yes)
129: )
130: and ( (p_query_only_null_srvtype = 'Y' and (recs.service_type_code is null))
131: or (p_query_only_null_srvtype = 'N')
132: )

Line 271: p_process_flag := jai_constants.SUCCESSFUL;

267: begin
268:
269: lv_member_name := 'EXTRACT_RGM_TRXS';
270: set_debug_context;
271: p_process_flag := jai_constants.SUCCESSFUL;
272: jai_cmn_debug_contexts_pkg.register ( pv_context => lv_context
273: , pn_reg_id => ln_reg_id
274: );
275:

Line 306: if p_process_flag <> jai_constants.SUCCESSFUL then

302: , p_trx_repo_extract_rec => lr_trx_repo_extract
303: , p_process_message => p_process_message
304: , p_process_flag => p_process_flag
305: );
306: if p_process_flag <> jai_constants.SUCCESSFUL then
307: return;
308: end if;
309:
310: /* { Changes by nprashar , For bug 7172723 */

Line 519: if p_process_flag <> jai_constants.SUCCESSFUL then

515: , p_process_flag => p_process_flag
516: , p_trx_repo_extract => lr_trx_repo_extract
517: );
518:
519: if p_process_flag <> jai_constants.SUCCESSFUL then
520: return;
521: end if;
522: /*added by csahoo for bug#6457710,start*/
523: elsif r_docs.transaction_source = 'PROJECTS' then

Line 535: if p_process_flag <> jai_constants.SUCCESSFUL then

531: , p_process_flag => p_process_flag
532: , p_trx_repo_extract => lr_trx_repo_extract
533: );
534:
535: if p_process_flag <> jai_constants.SUCCESSFUL then
536: return;
537: end if;
538: /*bug#6457710,end*/
539:

Line 552: if p_process_flag <> jai_constants.SUCCESSFUL then

548: , p_process_flag => p_process_flag
549: , p_trx_repo_extract => lr_trx_repo_extract
550: );
551:
552: if p_process_flag <> jai_constants.SUCCESSFUL then
553: return;
554: end if;
555:
556: elsif r_docs.transaction_source = 'PURCHASING' then

Line 583: elsif r_docs.transaction_source = jai_constants.G_AP_STANDALONE_INVOICE then

579: );
580:
581: --Till Here Bug#6843479
582: --Elsif added for Bug#6977917 on 2008/04/08
583: elsif r_docs.transaction_source = jai_constants.G_AP_STANDALONE_INVOICE then
584: jai_trx_repo_extract_pkg.get_document_details
585: ( p_document_id => r_docs.document_id
586: , p_document_line_id => r_docs.document_line_id
587: , p_document_source => r_docs.transaction_source

Line 609: lr_trx_repo_extract.updatable_flag := jai_constants.NO;

605: );
606: if lv_service_type_code is not null then
607:
608: lr_trx_repo_extract.service_type_code := lv_service_type_code;
609: lr_trx_repo_extract.updatable_flag := jai_constants.NO;
610: lr_trx_repo_extract.processed_flag := jai_constants.NO;
611:
612: end if;
613:

Line 610: lr_trx_repo_extract.processed_flag := jai_constants.NO;

606: if lv_service_type_code is not null then
607:
608: lr_trx_repo_extract.service_type_code := lv_service_type_code;
609: lr_trx_repo_extract.updatable_flag := jai_constants.NO;
610: lr_trx_repo_extract.processed_flag := jai_constants.NO;
611:
612: end if;
613:
614: lr_trx_repo_extract.document_line_id := lr_trx_repo_extract.document_line_num; --Added by Lion for bug#6911533

Line 740: p_process_flag := jai_constants.unexpected_error;

736: jai_cmn_debug_contexts_pkg.deregister (pn_reg_id => ln_reg_id);
737:
738: exception
739: when others then
740: p_process_flag := jai_constants.unexpected_error;
741: p_process_message := lv_context||'->'||sqlerrm;
742: jai_cmn_debug_contexts_pkg.print(ln_reg_id,lv_context||'->'||sqlerrm,jai_cmn_debug_contexts_pkg.summary);
743: jai_cmn_debug_contexts_pkg.print_stack;
744: end extract_rgm_trxs;

Line 951: and jpollt.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)

947: ,jai_po_taxes jpollt
948: where jpoll.po_line_id = cp_po_line_id
949: and jpollt.line_location_id = jpoll.line_location_id
950: /*added the cess and sh cess tax types for bug#6457710*/
951: and jpollt.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)
952: --and jpollt.tax_type = 'Service'
953: group by service_type_code;
954:
955: cursor c_get_ra_line_srvtyp (cp_customer_trx_line_id jai_ar_trx_lines.customer_trx_line_id%type)

Line 965: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)

961: where jrctl.customer_trx_line_id = cp_customer_trx_line_id
962: and jrcttl.link_to_cust_trx_line_id = jrctl.customer_trx_line_id
963: and jtc.tax_id = jrcttl.tax_id
964: /*added the cess and sh cess tax types for bug#6457710*/
965: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)
966: --and jtc.tax_type = 'Service'
967: group by service_type_code;
968:
969: cursor c_get_so_line_srvtyp (cp_line_id JAI_OM_OE_SO_LINES.line_id%type ) is

Line 978: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)

974: where jsl.line_id = cp_line_id
975: and jsl.line_id = jstl.line_id
976: and jstl.tax_id = jtc.tax_id
977: /*added the cess and sh cess tax types for bug#6457710*/
978: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)
979: --and jtc.tax_type = 'Service'
980: group by service_type_code;
981:
982: /*The following cursor added by rchandan for RMA */

Line 994: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)

990: where jrl.rma_line_id = cp_line_id
991: and jrl.rma_line_id = jrtl.rma_line_id
992: and jrtl.tax_id = jtc.tax_id
993: /*added the cess and sh cess tax types for bug#6457710*/
994: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)
995: --and jtc.tax_type = 'Service'
996: group by service_type_code;
997:
998: -- Bug 5876390, 6012570

Line 1005: and jcdt.source_doc_type = jai_constants.PA_DRAFT_INVOICE

1001: select sum(tax_amt) service_tax_amount
1002: from jai_cmn_document_taxes jcdt
1003: , jai_cmn_taxes_all jtc
1004: where jcdt.source_doc_line_id = cp_line_id
1005: and jcdt.source_doc_type = jai_constants.PA_DRAFT_INVOICE
1006: and jcdt.tax_id = jtc.tax_id
1007: /*added the cess and sh cess tax types for bug#6457710*/
1008: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess);
1009: --and jtc.tax_type = 'Service';

Line 1008: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess);

1004: where jcdt.source_doc_line_id = cp_line_id
1005: and jcdt.source_doc_type = jai_constants.PA_DRAFT_INVOICE
1006: and jcdt.tax_id = jtc.tax_id
1007: /*added the cess and sh cess tax types for bug#6457710*/
1008: and jtc.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess);
1009: --and jtc.tax_type = 'Service';
1010:
1011: --Deleted by Lion for bug#6911533 on 2008/04/22
1012: /*

Line 1030: AND jcta.tax_type = jai_constants.tax_type_service

1026: AND jasl.invoice_line_number = jcdt.source_doc_line_id
1027: AND jcdt.source_doc_line_id = lp_line_id
1028: AND jcdt.source_doc_id = p_document_id
1029: AND jcta.tax_id = jcdt.tax_id
1030: AND jcta.tax_type = jai_constants.tax_type_service
1031: GROUP BY jasl.service_type_code;
1032: --------------------------------------------------------------------------
1033: */
1034:

Line 1051: AND jcta.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)

1047: AND jasl.parent_invoice_line_number = lp_line_id
1048: AND jasl.invoice_id = jcdt.source_doc_id
1049: AND jasl.invoice_line_number = jcdt.source_doc_line_id
1050: AND jcdt.tax_id =jcta.tax_id
1051: AND jcta.tax_type IN (jai_constants.tax_type_service,jai_constants.tax_type_service_edu_cess,jai_constants.tax_type_sh_service_edu_cess)
1052:
1053: GROUP BY jasl.service_type_code;
1054:
1055: CURSOR l_get_si_service_type_csr

Line 1105: p_process_flag := jai_constants.SUCCESSFUL;

1101: begin
1102:
1103: lv_member_name := 'GET_DOCUMENT_DETAILS';
1104: set_debug_context;
1105: p_process_flag := jai_constants.SUCCESSFUL;
1106: jai_cmn_debug_contexts_pkg.register ( pv_context => lv_context
1107: , pn_reg_id => ln_reg_id
1108: );
1109:

Line 1120: p_process_flag := jai_constants.EXPECTED_ERROR;

1116: );
1117:
1118: if p_document_line_id is null or p_document_source is null then
1119: p_process_message := 'Document references cannot be null, cannot continue to derive the document details';
1120: p_process_flag := jai_constants.EXPECTED_ERROR;
1121: return;
1122: end if;
1123:
1124: --

Line 1371: IF (p_document_source = jai_constants.G_AP_STANDALONE_INVOICE)

1367:
1368: end if;
1369: -- Added by Bill Shi for standalone invoice on 2007/09/27
1370: --------------------------------------------------------------------------
1371: IF (p_document_source = jai_constants.G_AP_STANDALONE_INVOICE)
1372: THEN
1373: OPEN l_get_si_details_csr;
1374: FETCH l_get_si_details_csr INTO l_si_details_rec;
1375: CLOSE l_get_si_details_csr;

Line 1386: jai_constants.G_AP_STANDALONE_INVOICE;

1382: );
1383: END IF;
1384:
1385: p_trx_repo_extract.transaction_source :=
1386: jai_constants.G_AP_STANDALONE_INVOICE;
1387: p_trx_repo_extract.party_name :=
1388: l_si_details_rec.party_name ;
1389: p_trx_repo_extract.document_number :=
1390: l_si_details_rec.document_number;

Line 1450: END IF; -- (p_document_source = jai_constants.AP_STANDALONE_INVOICE)

1446: --then do not default service type from document
1447: p_trx_repo_extract.service_type_code := lv_service_type;
1448: END IF; -- (nvl(p_called_from,'$#$') NOT IN ('JAINRPRW'))
1449:
1450: END IF; -- (p_document_source = jai_constants.AP_STANDALONE_INVOICE)
1451: --------------------------------------------------------------------------
1452: /** Deregister procedure and return*/
1453: <>
1454: jai_cmn_debug_contexts_pkg.deregister (pn_reg_id => ln_reg_id);

Line 1458: p_process_flag := jai_constants.unexpected_error;

1454: jai_cmn_debug_contexts_pkg.deregister (pn_reg_id => ln_reg_id);
1455:
1456: exception
1457: when others then
1458: p_process_flag := jai_constants.unexpected_error;
1459: p_process_message := lv_context||'->'||sqlerrm;
1460: jai_cmn_debug_contexts_pkg.print(ln_reg_id,lv_context||'->'||sqlerrm,jai_cmn_debug_contexts_pkg.summary);
1461: jai_cmn_debug_contexts_pkg.print_stack;
1462: end get_document_details ;

Line 1485: if p_process_flag = jai_constants.SUCCESSFUL then

1481: , p_trx_repo_extract_rec => lr_trx_repo_ext_rec
1482: , p_process_flag => p_process_flag
1483: , p_process_message => p_process_message
1484: );
1485: if p_process_flag = jai_constants.SUCCESSFUL then
1486: p_organization_id := lr_trx_repo_ext_rec.organization_id;
1487: p_location_id := lr_trx_repo_ext_rec.location_id;
1488: p_service_type_code := lr_trx_repo_ext_rec.service_type_code;
1489: end if;

Line 1616: p_process_flag := jai_constants.EXPECTED_ERROR;

1612: fetch c_get_refs_rec into lr_refs_rec;
1613: close c_get_refs_rec;
1614:
1615: if lr_refs_rec.reference_id is null then
1616: p_process_flag := jai_constants.EXPECTED_ERROR;
1617: p_process_message := 'Invalid reference id. Unable to location a repository reference for P_REFERENCE_ID='||p_reference_id;
1618: return;
1619: end if;
1620:

Line 1626: p_process_flag := jai_constants.EXPECTED_ERROR;

1622: if lr_refs_rec.source is null
1623: or lr_refs_rec.invoice_id is null
1624: or lr_refs_rec.item_line_id is null
1625: then
1626: p_process_flag := jai_constants.EXPECTED_ERROR;
1627: p_process_message := 'Unable to find transaction references in the repository. Source='|| lr_refs_rec.source
1628: ||', InvoiceID='|| lr_refs_rec.invoice_id
1629: ||', ItemLineID=' ||lr_refs_rec.item_line_id ;
1630: return;

Line 1683: p_process_flag := jai_constants.SUCCESSFUL;

1679: -- if called from Repository Review UI then do not default service type from document
1680: p_trx_repo_extract_rec.service_type_code := lr_service_type;
1681: end if;
1682:
1683: p_process_flag := jai_constants.SUCCESSFUL;
1684: ELSE
1685:
1686: jai_trx_repo_extract_pkg.derrive_doc_from_ref
1687: ( p_reference_source => lr_refs_rec.source

Line 1699: if p_process_flag <> jai_constants.SUCCESSFUL then

1695: ln_doc_line_id := p_trx_repo_extract_rec.document_line_id;
1696: lv_trx_src := p_trx_repo_extract_rec.transaction_source;
1697:
1698:
1699: if p_process_flag <> jai_constants.SUCCESSFUL then
1700: return;
1701: end if;
1702:
1703: jai_trx_repo_extract_pkg.get_document_details

Line 1711: if p_process_flag <> jai_constants.SUCCESSFUL then

1707: , p_process_message => p_process_message
1708: , p_process_flag => p_process_flag
1709: , p_trx_repo_extract => p_trx_repo_extract_rec
1710: );
1711: if p_process_flag <> jai_constants.SUCCESSFUL then
1712: return;
1713: end if;
1714:
1715: ENd IF;

Line 1729: where processed_flag = jai_constants.NO;

1725: cursor c_get_recs_to_update
1726: is
1727: select *
1728: from jai_trx_repo_extract_gt
1729: where processed_flag = jai_constants.NO;
1730:
1731: ln_reg_id number;
1732:
1733: begin

Line 1739: p_process_flag := jai_constants.SUCCESSFUL;

1735: lv_member_name := 'UPDATE_SERVICE_TYPE';
1736: set_debug_context;
1737:
1738: /* Initialize the process variables */
1739: p_process_flag := jai_constants.SUCCESSFUL;
1740:
1741: jai_cmn_debug_contexts_pkg.register (lv_context, ln_reg_id);
1742: jai_cmn_debug_contexts_pkg.print (ln_reg_id, 'Begin loop for C_GET_RECS_TO_UPDATE', jai_cmn_debug_contexts_pkg.summary);
1743: for rec in c_get_recs_to_update

Line 1805: elsif rec.transaction_source = jai_constants.G_AP_STANDALONE_INVOICE then

1801: ,'No of rows updated in trx table='||sql%rowcount
1802: );
1803: --Added by Lion for bug#6911533 on 2008/04/22
1804: -------------------------------------------------------------------------
1805: elsif rec.transaction_source = jai_constants.G_AP_STANDALONE_INVOICE then
1806:
1807: update JAI_AP_INVOICE_LINES set service_type_code = rec.service_type_code
1808: , last_update_date = sysdate
1809: , last_updated_by = lv_user_id

Line 1903: p_process_flag := jai_constants.unexpected_error;

1899: jai_cmn_debug_contexts_pkg.deregister (pn_reg_id => ln_reg_id);
1900:
1901: exception
1902: when others then
1903: p_process_flag := jai_constants.unexpected_error;
1904: p_process_message := lv_context||'->'||sqlerrm;
1905: jai_cmn_debug_contexts_pkg.print(ln_reg_id,lv_context||'->'||sqlerrm,jai_cmn_debug_contexts_pkg.summary);
1906: jai_cmn_debug_contexts_pkg.print_stack;
1907:

Line 2133: p_trx_repo_extract_rec.transaction_source := jai_constants.G_AP_STANDALONE_INVOICE;

2129: lp_invoice_id => p_reference_invoice_id
2130: , lp_invoice_line_number => p_reference_item_line_id );
2131: FETCH l_get_si_reference_csr INTO l_si_reference_rec;
2132:
2133: p_trx_repo_extract_rec.transaction_source := jai_constants.G_AP_STANDALONE_INVOICE;
2134: p_trx_repo_extract_rec.document_id := l_si_reference_rec.invoice_id;
2135: p_trx_repo_extract_rec.document_line_id :=
2136: l_si_reference_rec.invoice_line_number;
2137:

Line 2151: p_process_flag := jai_constants.unexpected_error;

2147: jai_cmn_debug_contexts_pkg.deregister (pn_reg_id => ln_reg_id);
2148:
2149: exception
2150: when others then
2151: p_process_flag := jai_constants.unexpected_error;
2152: p_process_message := lv_context||'->'||sqlerrm;
2153: jai_cmn_debug_contexts_pkg.print(ln_reg_id,lv_context||'->'||sqlerrm,jai_cmn_debug_contexts_pkg.summary);
2154: jai_cmn_debug_contexts_pkg.print_stack;
2155:

Line 2183: if lv_process_flag = jai_constants.SUCCESSFUL then

2179: , p_service_type_code => lv_service_type_code
2180: , p_process_flag => lv_process_flag
2181: , p_process_message => lv_process_message
2182: );
2183: if lv_process_flag = jai_constants.SUCCESSFUL then
2184: return lv_service_type_code;
2185: else
2186: return null;
2187: end if;

Line 2281: elsif p_transaction_source = jai_constants.G_AP_STANDALONE_INVOICE then

2277: close c_get_po_settled_srvtyp ;
2278:
2279: --Added by Lion for bug#6911533 on 2008/04/22
2280: ------------------------------------------------------------------------
2281: elsif p_transaction_source = jai_constants.G_AP_STANDALONE_INVOICE then
2282:
2283: open c_get_aps_settled_srvtyp;
2284: fetch c_get_aps_settled_srvtyp into lv_service_type;
2285: close c_get_aps_settled_srvtyp ;