DBA Data[Home] [Help]

APPS.JAI_OM_WDD_TRIGGER_PKG dependencies on JAI_OM_WSH_LINE_TAXES

Line 101: DELETE JAI_OM_WSH_LINE_TAXES

97: Else
98: DELETE JAI_OM_WSH_LINES_ALL
99: WHERE delivery_detail_id = v_DELIVERY_DETAIL_ID;
100:
101: DELETE JAI_OM_WSH_LINE_TAXES
102: WHERE delivery_detail_id = v_DELIVERY_DETAIL_ID;
103: End If;
104:
105: END ARD_T1 ;

Line 1487: FROM JAI_OM_WSH_LINE_TAXES

1483: AND A.Tax_Id = b.Tax_Id
1484: ORDER BY A.Tax_Line_No;
1485: CURSOR Pick_Tax_Line_Count_Cur(P_Tax_Id NUMBER) IS
1486: SELECT COUNT(*)
1487: FROM JAI_OM_WSH_LINE_TAXES
1488: WHERE Delivery_Detail_Id = v_delivery_detail_id
1489: AND Tax_Id = P_Tax_Id;
1490: CURSOR Get_Tot_Tax_Amount_Cur IS
1491: SELECT SUM(A.Tax_Amount)

Line 1492: FROM JAI_OM_WSH_LINE_TAXES A,

1488: WHERE Delivery_Detail_Id = v_delivery_detail_id
1489: AND Tax_Id = P_Tax_Id;
1490: CURSOR Get_Tot_Tax_Amount_Cur IS
1491: SELECT SUM(A.Tax_Amount)
1492: FROM JAI_OM_WSH_LINE_TAXES A,
1493: JAI_CMN_TAXES_ALL b
1494: WHERE A.Delivery_Detail_Id = v_delivery_detail_id
1495: AND b.Tax_Id = A.Tax_Id
1496: AND b.Tax_Type <> 'TDS';

Line 1727: FROM JAI_OM_WSH_LINE_TAXES jsptl ,

1723: v_lou_flag Varchar2(1);
1724:
1725: CURSOR c_cess_amount (cp_delivery_id JAI_OM_WSH_LINES_ALL.DELIVERY_ID%TYPE) IS
1726: SELECT nvl(sum(jsptl.func_tax_amount),0) tax_amount
1727: FROM JAI_OM_WSH_LINE_TAXES jsptl ,
1728: JAI_CMN_TAXES_ALL jtc
1729: WHERE jtc.tax_id = jsptl.tax_id
1730: AND delivery_detail_id in
1731: (SELECT delivery_detail_id

Line 1745: FROM JAI_OM_WSH_LINE_TAXES jsptl ,

1741: /* Cursor is responsible to get secondary and higher cess */
1742:
1743: CURSOR c_sh_cess_amount (cp_delivery_id JAI_OM_WSH_LINES_ALL.DELIVERY_ID%TYPE) IS
1744: SELECT nvl(sum(jsptl.func_tax_amount),0) tax_amount
1745: FROM JAI_OM_WSH_LINE_TAXES jsptl ,
1746: JAI_CMN_TAXES_ALL jtc
1747: WHERE jtc.tax_id = jsptl.tax_id
1748: AND delivery_detail_id in
1749: (SELECT delivery_detail_id

Line 1774: FROM JAI_OM_WSH_LINE_TAXES jsptl,

1770:
1771: CURSOR cur_chk_vat_exists (cp_del_det_id JAI_OM_WSH_LINES_ALL.DELIVERY_DETAIL_ID%TYPE)
1772: IS
1773: SELECT 1
1774: FROM JAI_OM_WSH_LINE_TAXES jsptl,
1775: JAI_CMN_TAXES_ALL jtc
1776: , jai_regime_tax_types_v tax_types
1777: WHERE jsptl.delivery_detail_id = cp_del_det_id
1778: AND jtc.tax_id = jsptl.tax_id

Line 1805: || Check if only 'VAT REVERSAL' tax type is present in JAI_OM_WSH_LINE_TAXES

1801: -- End of Bug#4215808
1802:
1803: /*
1804: || Added by csahoo for bug#5680459
1805: || Check if only 'VAT REVERSAL' tax type is present in JAI_OM_WSH_LINE_TAXES
1806: */
1807: CURSOR c_chk_vat_reversal (cp_del_det_id JAI_OM_WSH_LINES_ALL.delivery_detail_id%TYPE,
1808: cp_tax_type JAI_CMN_TAXES_ALL.tax_type%TYPE )
1809: IS

Line 1811: FROM JAI_OM_WSH_LINE_TAXES jsptl,

1807: CURSOR c_chk_vat_reversal (cp_del_det_id JAI_OM_WSH_LINES_ALL.delivery_detail_id%TYPE,
1808: cp_tax_type JAI_CMN_TAXES_ALL.tax_type%TYPE )
1809: IS
1810: SELECT 1
1811: FROM JAI_OM_WSH_LINE_TAXES jsptl,
1812: JAI_CMN_TAXES_ALL jtc
1813: WHERE jsptl.delivery_detail_id = cp_del_det_id
1814: AND jtc.tax_id = jsptl.tax_id
1815: AND jtc.tax_type = cp_tax_type ;

Line 1843: , CP_DELIVERY_DETAIL_ID JAI_OM_WSH_LINE_TAXES.DELIVERY_DETAIL_ID%TYPE

1839: WHERE REGIME_CODE = CP_REGIME_CODE;
1840:
1841: /** Check if taxes with taxType as defined in the regime setup exists for given regime code */
1842: CURSOR C_CHK_RGM_TAX_EXISTS ( CP_REGIME_CODE JAI_RGM_DEFINITIONS.REGIME_CODE%TYPE
1843: , CP_DELIVERY_DETAIL_ID JAI_OM_WSH_LINE_TAXES.DELIVERY_DETAIL_ID%TYPE
1844: )
1845: IS
1846: SELECT COUNT(1)
1847: FROM JAI_REGIME_TAX_TYPES_V JRTTV

Line 1848: , JAI_OM_WSH_LINE_TAXES JSPT

1844: )
1845: IS
1846: SELECT COUNT(1)
1847: FROM JAI_REGIME_TAX_TYPES_V JRTTV
1848: , JAI_OM_WSH_LINE_TAXES JSPT
1849: , JAI_CMN_TAXES_ALL JTC
1850: WHERE JTC.TAX_ID = JSPT.TAX_ID
1851: AND JTC.TAX_TYPE = JRTTV.TAX_TYPE
1852: AND REGIME_CODE = CP_REGIME_CODE

Line 1946: JAI_OM_WSH_LINE_TAXES.

1942: Initial code used to check that if the organization is a Trading organization,item is tradable and excisable
1943: then used to assume that a match receipt has been done and get the sum (tax_amount), sum(base_tax_amount),
1944: sum(func_tax_amount) for a delivery_detail_id and tax_id from the JAI_CMN_MATCH_TAXES table and
1945: populate this into the tax_amount, base_tax_amount and func_tax_amount columns of the table
1946: JAI_OM_WSH_LINE_TAXES.
1947:
1948: This approach used to fail, as many a times a record never used to exists in the JAI_CMN_MATCH_TAXES table
1949: for the delivery_detail_id and tax_id even though the organization is declared as a trading organization,
1950: Item is tradable and excisable.

Line 2558: Before this fix, Null value used to get inserted into taxes in table JAI_OM_WSH_LINE_TAXES for Bond register with

2554: to the other three checks (of organization being a trading organization, Item being tradable and excisable ):-
2555: The order attached to the bond register is one of 'Trading Domestic With Excise' or 'Export With Excise'
2556: hence applying the check that
2557: v_trad_register_code IN ( '23D_DOMESTIC_EXCISE','23D_EXPORT_EXCISE') .
2558: Before this fix, Null value used to get inserted into taxes in table JAI_OM_WSH_LINE_TAXES for Bond register with
2559: 'Trading Domestic Without Excise' and 'Export Without Excise' ( problem stated in the bug )
2560: */
2561: IF NVL(v_trading_flag,'N') = 'Y' AND
2562: NVL(v_item_trading_flag,'N') = 'Y' AND

Line 2683: -- Check for the existence of Tax Lines in JAI_OM_WSH_LINE_TAXES

2679: ||', v_add_excise_duty_amount -> '|| v_add_excise_duty_amount
2680: ||', v_oth_excise_duty_amount -> '|| v_oth_excise_duty_amount
2681: );
2682: END IF; --3
2683: -- Check for the existence of Tax Lines in JAI_OM_WSH_LINE_TAXES
2684: OPEN Pick_Tax_Line_Count_Cur(rec.tax_id);
2685: FETCH Pick_Tax_Line_Count_Cur INTO v_picking_tax_lines_count;
2686: CLOSE Pick_Tax_Line_Count_Cur;
2687: IF v_picking_tax_lines_count = 0 THEN --4

Line 2688: INSERT INTO JAI_OM_WSH_LINE_TAXES(Delivery_Detail_Id,

2684: OPEN Pick_Tax_Line_Count_Cur(rec.tax_id);
2685: FETCH Pick_Tax_Line_Count_Cur INTO v_picking_tax_lines_count;
2686: CLOSE Pick_Tax_Line_Count_Cur;
2687: IF v_picking_tax_lines_count = 0 THEN --4
2688: INSERT INTO JAI_OM_WSH_LINE_TAXES(Delivery_Detail_Id,
2689: Tax_Line_No,
2690: Precedence_1,
2691: Precedence_2,
2692: Precedence_3,

Line 2739: UPDATE JAI_OM_WSH_LINE_TAXES

2735: v_last_updated_by,
2736: v_last_update_login
2737: );
2738: ELSE --4
2739: UPDATE JAI_OM_WSH_LINE_TAXES
2740: SET Tax_Amount = v_tax_amount,
2741: base_tax_amount = v_base_tax_amount, /*12850620*/
2742: func_tax_amount = v_func_tax_amount, /*12850620*/
2743: Last_Update_Date = v_last_update_date,

Line 2841: from JAI_OM_WSH_LINE_TAXES

2837:
2838: /* Get line number after which threshold taxes needs to be defaulted */
2839: select max(tax_line_no)
2840: into ln_last_line_no
2841: from JAI_OM_WSH_LINE_TAXES
2842: where delivery_detail_id = v_delivery_detail_id;
2843:
2844: /* Get line number of the base tax (tax_type=TCS) for calculating the surcharge basically to set a precedence */
2845: select max(tax_line_no)

Line 2847: from JAI_OM_WSH_LINE_TAXES jsptl

2843:
2844: /* Get line number of the base tax (tax_type=TCS) for calculating the surcharge basically to set a precedence */
2845: select max(tax_line_no)
2846: into ln_base_line_no
2847: from JAI_OM_WSH_LINE_TAXES jsptl
2848: , JAI_CMN_TAXES_ALL jtc
2849: where jsptl.delivery_detail_id = v_delivery_detail_id
2850: and jsptl.tax_id = jtc.tax_id
2851: and jtc.tax_type = jai_constants.tax_type_tcs;

Line 2856: || into the JAI_OM_WSH_LINE_TAXES table

2852:
2853: /*
2854: ||Call the helper method to default surcharge taxes on top of the SO taxes using the tax category
2855: || The api jai_rgm_thhold_proc_pkg.default_thhold_taxes inserts lines as per the same specified in the TCS tax category
2856: || into the JAI_OM_WSH_LINE_TAXES table
2857: */
2858:
2859: /* jai_cmn_debug_contexts_pkg.print (ln_reg_id, 'Calling JAI_RGM_THHOLD_PROC_PKG.DEFAULT_THHOLD_TAXES');*/ --commented by bgowrava for bug#5631784
2860:

Line 3119: || Check if only 'VAT REVERSAL' tax type is present in JAI_OM_WSH_LINE_TAXES

3115:
3116:
3117: /*
3118: || Added by csahoo for bug#5680459
3119: || Check if only 'VAT REVERSAL' tax type is present in JAI_OM_WSH_LINE_TAXES
3120: */
3121: IF nvl(ln_vat_cnt,0) = 0 THEN /* If taxes of type 'VAT' are not present */
3122: lv_vat_reversal := 'VAT REVERSAL' ;
3123: OPEN c_chk_vat_reversal(cp_del_det_id => v_delivery_detail_id,

Line 3710: FROM jai_om_wsh_line_taxes a,jai_cmn_taxes_all b

3706:
3707: /*Added following cursor for Bug#10213327 by abezgam*/
3708: CURSOR c_inclusive_flag (CP_DDID IN NUMBER )IS
3709: SELECT count(*)
3710: FROM jai_om_wsh_line_taxes a,jai_cmn_taxes_all b
3711: where a.delivery_Detail_id=cp_ddid
3712: and a.tax_id=b.tax_id
3713: and upper(b.tax_type) like '%EXCISE%'
3714: AND B.INCLUSIVE_TAX_FLAG='Y';