DBA Data[Home] [Help]

APPS.JAI_OM_WDD_PROCESSING_PKG dependencies on JAI_CONSTANTS

Line 212: pv_return_code := jai_constants.successful ;

208: v_tot_lc_shipped_qty NUMBER;
209: ln_unprocessed_recs NUMBER;
210:
211: BEGIN
212: pv_return_code := jai_constants.successful ;
213:
214: v_inventory_item_id :=pr_new.inventory_item_id ;
215: v_organization_id :=pr_new.organization_id ;
216: v_subinventory :=pr_new.subinventory ;

Line 275: pv_return_code := jai_constants.expected_error ;

271: CLOSE matched_receipt_cur1;
272:
273: IF nvl(pr_new.Released_status,'N') = 'C' THEN
274: IF nvl(v_shipped_quantity,0) <> nvl(v_matched_qty,0) THEN
275: pv_return_code := jai_constants.expected_error ;
276: pv_return_message := 'Matched Quantity -- ' || TO_CHAR(NVL(v_matched_qty,0)) ||
277: ' should be equal to Shipped Quantity -- ' || TO_CHAR(NVL(v_shipped_quantity,0));
278: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
279: FND_LOG.STRING(G_LEVEL_STATEMENT,

Line 289: pv_return_code := jai_constants.expected_error ;

285: END IF;
286:
287: if nvl(pr_new.Released_status,'N') = 'B' then
288: if nvl(v_matched_qty,0) > 0 then
289: pv_return_code := jai_constants.expected_error ;
290: pv_return_message := 'Please Unmatch the Delivery prior to backordering ' ;
291: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
292: FND_LOG.STRING(G_LEVEL_STATEMENT,
293: G_MODULE_NAME || v_api_name,

Line 331: pv_return_code := jai_constants.expected_error ;

327: CLOSE cur_tot_shipped_quantity;
328: END IF;
329:
330: IF NVL(v_lc_qty_matched,-999) <> NVL(v_tot_lc_shipped_qty,-888) THEN
331: pv_return_code := jai_constants.expected_error ;
332: pv_return_message := 'LC Matched Quantity -- ' || TO_CHAR(NVL(v_lc_qty_matched,0)) ||
333: ' should be equal to Shipped Quantity -- ' || TO_CHAR(NVL(v_lc_shipped_qty,0)) || ' for LC enabled Orders';
334: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
335: FND_LOG.STRING(G_LEVEL_STATEMENT,

Line 382: IF lv_process_flag = jai_constants.unexpected_error THEN

378: END IF;
379:
380: EXCEPTION
381: WHEN le_error THEN
382: IF lv_process_flag = jai_constants.unexpected_error THEN
383: lv_process_message := substr (lv_process_message || ' Object = JAI_OM_WDD_PROCESSING_PKG.DELIVER_DETAILS ', 1,1999) ;
384: END IF;
385:
386:

Line 781: AND upper(jtc.tax_type) in (upper(jai_constants.tax_type_cvd_edu_cess), upper(jai_constants.tax_type_exc_edu_cess));

777: (SELECT delivery_detail_id
778: FROM JAI_OM_WSH_LINES_ALL
779: WHERE delivery_id = cp_delivery_id
780: )
781: AND upper(jtc.tax_type) in (upper(jai_constants.tax_type_cvd_edu_cess), upper(jai_constants.tax_type_exc_edu_cess));
782:
783: ln_sh_cess_amount JAI_CMN_RG_OTHERS.DEBIT%TYPE;
784:
785: CURSOR c_sh_cess_amount (cp_delivery_id JAI_OM_WSH_LINES_ALL.DELIVERY_ID%TYPE) IS

Line 795: AND upper(jtc.tax_type) in (upper(jai_constants.tax_type_sh_exc_edu_cess),

791: (SELECT delivery_detail_id
792: FROM JAI_OM_WSH_LINES_ALL
793: WHERE delivery_id = cp_delivery_id
794: )
795: AND upper(jtc.tax_type) in (upper(jai_constants.tax_type_sh_exc_edu_cess),
796: upper(jai_constants.tax_type_sh_cvd_edu_cess)
797: );
798:
799: ln_cess_amount JAI_CMN_RG_OTHERS.DEBIT%TYPE;

Line 796: upper(jai_constants.tax_type_sh_cvd_edu_cess)

792: FROM JAI_OM_WSH_LINES_ALL
793: WHERE delivery_id = cp_delivery_id
794: )
795: AND upper(jtc.tax_type) in (upper(jai_constants.tax_type_sh_exc_edu_cess),
796: upper(jai_constants.tax_type_sh_cvd_edu_cess)
797: );
798:
799: ln_cess_amount JAI_CMN_RG_OTHERS.DEBIT%TYPE;
800: lv_process_flag VARCHAR2(5);

Line 817: AND tax_types.regime_code = jai_constants.vat_regime;

813: , jai_regime_tax_types_v tax_types
814: WHERE jsptl.delivery_detail_id = cp_del_det_id
815: AND jtc.tax_id = jsptl.tax_id
816: AND jtc.tax_type = tax_types.tax_type
817: AND tax_types.regime_code = jai_constants.vat_regime;
818:
819: CURSOR cur_get_regime_info (cp_organization_id JAI_RGM_ORG_REGNS_V.ORGANIZATION_ID%TYPE ,
820: cp_location_id JAI_RGM_ORG_REGNS_V.LOCATION_ID%TYPE
821: )

Line 828: AND attribute_type_code = jai_constants.rgm_attr_type_code_primary

824: attribute_value
825: FROM JAI_RGM_ORG_REGNS_V orrg
826: WHERE orrg.organization_id = cp_organization_id
827: AND orrg.location_id = cp_location_id
828: AND attribute_type_code = jai_constants.rgm_attr_type_code_primary
829: AND attribute_code = jai_constants.attr_code_regn_no
830: AND regime_code = jai_constants.vat_regime;
831:
832: CURSOR cur_chk_vat_proc_entry (cp_delivery_id JAI_OM_WSH_LINES_ALL.DELIVERY_ID%TYPE)

Line 829: AND attribute_code = jai_constants.attr_code_regn_no

825: FROM JAI_RGM_ORG_REGNS_V orrg
826: WHERE orrg.organization_id = cp_organization_id
827: AND orrg.location_id = cp_location_id
828: AND attribute_type_code = jai_constants.rgm_attr_type_code_primary
829: AND attribute_code = jai_constants.attr_code_regn_no
830: AND regime_code = jai_constants.vat_regime;
831:
832: CURSOR cur_chk_vat_proc_entry (cp_delivery_id JAI_OM_WSH_LINES_ALL.DELIVERY_ID%TYPE)
833: IS

Line 830: AND regime_code = jai_constants.vat_regime;

826: WHERE orrg.organization_id = cp_organization_id
827: AND orrg.location_id = cp_location_id
828: AND attribute_type_code = jai_constants.rgm_attr_type_code_primary
829: AND attribute_code = jai_constants.attr_code_regn_no
830: AND regime_code = jai_constants.vat_regime;
831:
832: CURSOR cur_chk_vat_proc_entry (cp_delivery_id JAI_OM_WSH_LINES_ALL.DELIVERY_ID%TYPE)
833: IS
834: SELECT 1

Line 885: pv_return_code := jai_constants.successful ;

881: l_func_curr_det jai_plsql_cache_pkg.func_curr_details;
882:
883:
884: BEGIN
885: pv_return_code := jai_constants.successful ;
886:
887: v_creation_date := sysdate;
888: v_created_by :=pr_new.Created_By;
889: v_last_update_date :=pr_new.Last_Update_Date;

Line 1009: pv_return_code := jai_constants.expected_error ;

1005: OPEN matched_receipt_cur1;
1006: FETCH matched_receipt_cur1 INTO v_matched_qty;
1007: CLOSE matched_receipt_cur1;
1008: IF NVL(v_shipped_quantity,0) <> NVL(v_matched_qty,0) THEN
1009: pv_return_code := jai_constants.expected_error ;
1010: pv_return_message := 'Matched Quantity -- ' || TO_CHAR(NVL(v_matched_qty,0)) ||
1011: ' should be equal to Shipped Quantity -- ' || TO_CHAR(NVL(v_shipped_quantity,0)) ;
1012: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1013: FND_LOG.STRING(G_LEVEL_STATEMENT,

Line 1257: open c_chk_rgm_tax_exists ( cp_regime_code => jai_constants.tcs_regime

1253: Check if TCS type of taxes exists, If yes using the threshold API found out the slab and the tax category id
1254: and delegate the call tax defaultation API
1255: */
1256: ln_tcs_exists := 0;
1257: open c_chk_rgm_tax_exists ( cp_regime_code => jai_constants.tcs_regime
1258: , cp_delivery_detail_id => v_delivery_detail_id);
1259: fetch c_chk_rgm_tax_exists into ln_tcs_exists;
1260: close c_chk_rgm_tax_exists ;
1261:

Line 1265: 'tcs regime code :' || jai_constants.tcs_regime ||

1261:
1262: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1263: FND_LOG.STRING(G_LEVEL_STATEMENT,
1264: G_MODULE_NAME || v_api_name,
1265: 'tcs regime code :' || jai_constants.tcs_regime ||
1266: ', delivery_detail_id :' || v_delivery_detail_id ||
1267: ', ln_tcs_exists :' || ln_tcs_exists);
1268: END IF;
1269:

Line 1274: open c_get_regime_id (cp_regime_code => jai_constants.tcs_regime);

1270: if nvl(ln_tcs_exists,0) >0 then
1271: /* TCS type of tax is present */
1272: fnd_file.put_line(FND_FILE.LOG,'Localization' );
1273:
1274: open c_get_regime_id (cp_regime_code => jai_constants.tcs_regime);
1275: fetch c_get_regime_id into ln_tcs_regime_id;
1276: close c_get_regime_id;
1277:
1278: jai_rgm_thhold_proc_pkg.get_threshold_slab_id

Line 1282: , p_party_type => jai_constants.party_type_customer

1278: jai_rgm_thhold_proc_pkg.get_threshold_slab_id
1279: (
1280: p_regime_id => ln_tcs_regime_id
1281: , p_organization_id => v_organization_id
1282: , p_party_type => jai_constants.party_type_customer
1283: , p_party_id => v_customer_id
1284: , p_org_id => v_org_id
1285: , p_source_trx_date => v_date_confirmed
1286: , p_threshold_slab_id => ln_threshold_slab_id

Line 1291: if lv_process_flag <> jai_constants.successful then

1287: , p_process_flag => lv_process_flag
1288: , p_process_message => lv_process_message
1289: );
1290:
1291: if lv_process_flag <> jai_constants.successful then
1292: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1293: FND_LOG.STRING(G_LEVEL_STATEMENT,
1294: G_MODULE_NAME || v_api_name,
1295: 'Error in jai_rgm_thhold_proc_pkg.get_threshold_slab_id. ' || lv_process_message);

Line 1321: if lv_process_flag <> jai_constants.successful then

1317: , p_process_flag => lv_process_flag
1318: , p_process_message => lv_process_message
1319: );
1320:
1321: if lv_process_flag <> jai_constants.successful then
1322: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1323: FND_LOG.STRING(G_LEVEL_STATEMENT,
1324: G_MODULE_NAME || v_api_name,
1325: 'Error in jai_rgm_thhold_proc_pkg.get_threshold_tax_cat_id. ' || lv_process_message);

Line 1347: and jtc.tax_type = jai_constants.tax_type_tcs;

1343: from JAI_OM_WSH_LINE_TAXES jsptl
1344: , JAI_CMN_TAXES_ALL jtc
1345: where jsptl.delivery_detail_id = v_delivery_detail_id
1346: and jsptl.tax_id = jtc.tax_id
1347: and jtc.tax_type = jai_constants.tax_type_tcs;
1348:
1349: /*
1350: ||Call the helper method to default surcharge taxes on top of the SO taxes using the tax category
1351: || The api jai_rgm_thhold_proc_pkg.default_thhold_taxes inserts lines as per the same specified in the TCS tax category

Line 1369: , p_source_event => jai_constants.source_ttype_delivery

1365: jai_rgm_thhold_proc_pkg.default_thhold_taxes
1366: (
1367: p_source_trx_id => ''
1368: , p_source_trx_line_id => v_delivery_detail_id
1369: , p_source_event => jai_constants.source_ttype_delivery
1370: , p_action => jai_constants.default_taxes
1371: , p_threshold_tax_cat_id => ln_threshold_tax_cat_id
1372: , p_tax_base_line_number => ln_base_line_no
1373: , p_last_line_number => ln_last_line_no

Line 1370: , p_action => jai_constants.default_taxes

1366: (
1367: p_source_trx_id => ''
1368: , p_source_trx_line_id => v_delivery_detail_id
1369: , p_source_event => jai_constants.source_ttype_delivery
1370: , p_action => jai_constants.default_taxes
1371: , p_threshold_tax_cat_id => ln_threshold_tax_cat_id
1372: , p_tax_base_line_number => ln_base_line_no
1373: , p_last_line_number => ln_last_line_no
1374: , p_currency_code => v_currency_code

Line 1386: if lv_process_flag <> jai_constants.successful then

1382: , p_process_flag => lv_process_flag
1383: , p_process_message => lv_process_message
1384: );
1385:
1386: if lv_process_flag <> jai_constants.successful then
1387: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1388: FND_LOG.STRING(G_LEVEL_STATEMENT,
1389: G_MODULE_NAME || v_api_name,
1390: 'Error in jai_rgm_thhold_proc_pkg.default_thhold_taxes. ' || lv_process_message);

Line 1596: lv_vat_invoice_no := jai_constants.not_applicable ;

1592: /*
1593: || VAT invoice number should be punched as 'NA' and accounting should happen
1594: || when 'VAT REVERSAL' type of tax exist and 'VAT' type of tax(es) doesn't exist
1595: */
1596: lv_vat_invoice_no := jai_constants.not_applicable ;
1597: lv_vat_inv_gen_status := 'C' ;
1598: END IF ;
1599:
1600: IF (nvl(ln_vat_cnt,0) > 0 OR nvl(ln_vat_reversal_exists,0) = 1 ) AND nvl (ln_vat_proc_cnt,0) = 0 THEN

Line 1653: jai_constants.party_type_customer,

1649: null ,
1650: null ,
1651: ln_bill_to_cust_id ,
1652: v_bill_to_org_id ,
1653: jai_constants.party_type_customer,
1654: v_creation_date ,
1655: v_created_by ,
1656: v_last_update_date ,
1657: v_last_update_login ,

Line 1701: IF lv_process_flag = jai_constants.expected_error OR

1697: p_process_flag => lv_process_flag ,
1698: p_process_message => lv_process_message
1699: );
1700:
1701: IF lv_process_flag = jai_constants.expected_error OR
1702: lv_process_flag = jai_constants.unexpected_error
1703: THEN
1704: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1705: FND_LOG.STRING(G_LEVEL_STATEMENT,

Line 1702: lv_process_flag = jai_constants.unexpected_error

1698: p_process_message => lv_process_message
1699: );
1700:
1701: IF lv_process_flag = jai_constants.expected_error OR
1702: lv_process_flag = jai_constants.unexpected_error
1703: THEN
1704: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1705: FND_LOG.STRING(G_LEVEL_STATEMENT,
1706: G_MODULE_NAME || v_api_name,

Line 1953: pv_return_code := jai_constants.expected_error ;

1949: v_reg_exp_date ,
1950: v_lou_flag);
1951:
1952: IF nvl(v_reg_exp_date,sysdate) < sysdate then
1953: pv_return_code := jai_constants.expected_error ;
1954: pv_return_message := 'Bonded Register Validity has Expired on ' || v_reg_exp_date ;
1955: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1956: FND_LOG.STRING(G_LEVEL_STATEMENT,
1957: G_MODULE_NAME || v_api_name,

Line 1965: pv_return_code := jai_constants.expected_error ;

1961: end if;
1962: -- logic is : to check if it is a letter of undertaking and only then if balance is a problem , raise an error
1963: v_tot_excise_amt := v_tot_excise_amt * v_curr_conv_rate;
1964: IF NVL(v_register_balance,0) < NVL(v_tot_excise_amt,0) and nvl(v_lou_flag,'N') = 'N' THEN
1965: pv_return_code := jai_constants.expected_error ;
1966: pv_return_message := 'Bonded Register Has Balance -> '||
1967: TO_CHAR(v_register_balance) ||
1968: ' ,which IS less than Excisable Amount -> ' ||
1969: TO_CHAR(v_tot_excise_amt) ;

Line 1984: pv_return_code := jai_constants.expected_error ;

1980: END IF;
1981:
1982: Exception
1983: When Others then
1984: pv_return_code := jai_constants.expected_error ;
1985: pv_return_message := substr(sqlerrm,1,200) ;
1986: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
1987: FND_LOG.STRING(G_LEVEL_STATEMENT,
1988: G_MODULE_NAME || v_api_name,

Line 2647: pv_return_code := jai_constants.successful ;

2643: ln_cnt NUMBER;
2644:
2645:
2646: BEGIN
2647: pv_return_code := jai_constants.successful ;
2648:
2649: OPEN c_check_lc_order;
2650: FETCH c_check_lc_order INTO v_check_lc_order;
2651: CLOSE c_check_lc_order;

Line 2854: pv_return_code := jai_constants.successful ;

2850: WHERE inventory_item_id = v_Inventory_Item_Id
2851: AND organization_id = v_organization_id;
2852:
2853: BEGIN
2854: pv_return_code := jai_constants.successful ;
2855:
2856: v_Organization_Id := pr_new.Organization_Id;
2857: v_shipped_quantity := NVL(pr_new.Shipped_Quantity,0);
2858: v_subinventory := pr_new.SUBINVENTORY;

Line 2896: pv_return_code := jai_constants.expected_error ;

2892: G_MODULE_NAME || v_api_name,
2893: 'Matched Quantity -- ' || TO_CHAR(NVL(v_matched_qty,0)) ||
2894: ' should be equal to Shipped Quantity -- ' || TO_CHAR(NVL(v_shipped_quantity,0)));
2895: END IF;
2896: pv_return_code := jai_constants.expected_error ;
2897: pv_return_message := 'Matched Quantity -- ' || TO_CHAR(NVL(v_matched_qty,0)) ||
2898: ' should be equal to Shipped Quantity -- ' || TO_CHAR(NVL(v_shipped_quantity,0)) ;
2899: END IF;
2900: END IF;

Line 2905: pv_return_code := jai_constants.unexpected_error;

2901: END IF;
2902:
2903: Exception
2904: When Others then
2905: pv_return_code := jai_constants.unexpected_error;
2906: pv_return_message := substr(sqlerrm,1,200) ;
2907: END VALIDATE_MATCHED_QTY;
2908:
2909: /*

Line 2953: pv_return_code := jai_constants.successful;

2949: v_conv_date DATE;
2950: v_curr_conv_rate NUMBER;
2951:
2952: BEGIN
2953: pv_return_code := jai_constants.successful;
2954: v_source_header_id :=pr_new.Source_Header_Id;
2955: v_source_line_id :=pr_new.Source_Line_Id;
2956:
2957: IF pr_new.org_id IS NOT NULL THEN

Line 2996: pv_return_code := jai_constants.unexpected_error ;

2992: CLOSE get_conv_detail_cur;
2993:
2994: Exception
2995: When Others then
2996: pv_return_code := jai_constants.unexpected_error ;
2997: pv_return_message := substr(sqlerrm,1,200) ;
2998: END VALIDATE_CURRENCY;
2999:
3000: /*

Line 3055: pv_return_code := jai_constants.successful;

3051: FROM JAI_RGM_DEFINITIONS
3052: WHERE REGIME_CODE = CP_REGIME_CODE;
3053:
3054: BEGIN
3055: pv_return_code := jai_constants.successful;
3056: v_delivery_detail_id := pr_new.delivery_detail_id;
3057: v_organization_id := pr_new.organization_id;
3058: v_customer_id := pr_new.CUSTOMER_ID;
3059: v_org_id := pr_new.ORG_ID;

Line 3065: open c_chk_rgm_tax_exists ( cp_regime_code => jai_constants.tcs_regime

3061: Check if TCS type of taxes exists, If yes using the threshold API found out the slab and the tax category id
3062: and delegate the call tax defaultation API
3063: */
3064: ln_tcs_exists := 0;
3065: open c_chk_rgm_tax_exists ( cp_regime_code => jai_constants.tcs_regime
3066: , cp_delivery_detail_id => v_delivery_detail_id);
3067: fetch c_chk_rgm_tax_exists into ln_tcs_exists;
3068: close c_chk_rgm_tax_exists ;
3069:

Line 3073: 'tcs regime code :' || jai_constants.tcs_regime ||

3069:
3070: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3071: FND_LOG.STRING(G_LEVEL_STATEMENT,
3072: G_MODULE_NAME || v_api_name,
3073: 'tcs regime code :' || jai_constants.tcs_regime ||
3074: ', delivery_detail_id :' || v_delivery_detail_id ||
3075: ', ln_tcs_exists :' || ln_tcs_exists);
3076: END IF;
3077:

Line 3082: open c_get_regime_id (cp_regime_code => jai_constants.tcs_regime);

3078: if nvl(ln_tcs_exists,0) >0 then
3079: /* TCS type of tax is present */
3080: fnd_file.put_line(FND_FILE.LOG,'Localization' );
3081:
3082: open c_get_regime_id (cp_regime_code => jai_constants.tcs_regime);
3083: fetch c_get_regime_id into ln_tcs_regime_id;
3084: close c_get_regime_id;
3085:
3086: -- Check for the Delivery Status

Line 3095: , p_party_type => jai_constants.party_type_customer

3091: jai_rgm_thhold_proc_pkg.get_threshold_slab_id
3092: (
3093: p_regime_id => ln_tcs_regime_id
3094: , p_organization_id => v_organization_id
3095: , p_party_type => jai_constants.party_type_customer
3096: , p_party_id => v_customer_id
3097: , p_org_id => v_org_id
3098: , p_source_trx_date => v_date_confirmed
3099: , p_threshold_slab_id => ln_threshold_slab_id

Line 3104: if lv_process_flag <> jai_constants.successful then

3100: , p_process_flag => lv_process_flag
3101: , p_process_message => lv_process_message
3102: );
3103:
3104: if lv_process_flag <> jai_constants.successful then
3105: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3106: FND_LOG.STRING(G_LEVEL_STATEMENT,
3107: G_MODULE_NAME || v_api_name,
3108: 'Error in jai_rgm_thhold_proc_pkg.get_threshold_slab_id. ' || lv_process_message);

Line 3134: if lv_process_flag <> jai_constants.successful then

3130: , p_process_flag => lv_process_flag
3131: , p_process_message => lv_process_message
3132: );
3133:
3134: if lv_process_flag <> jai_constants.successful then
3135: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3136: FND_LOG.STRING(G_LEVEL_STATEMENT,
3137: G_MODULE_NAME || v_api_name,
3138: 'Error in jai_rgm_thhold_proc_pkg.get_threshold_tax_cat_id. ' || lv_process_message);

Line 3150: pv_return_code := jai_constants.unexpected_error ;

3146: end if;
3147: end if;
3148: Exception
3149: When Others then
3150: pv_return_code := jai_constants.unexpected_error ;
3151: pv_return_message := substr(sqlerrm,1,200) ;
3152: END VALIDATE_TCS_TAXES;
3153:
3154: /*

Line 3195: AND jrttv.regime_code = jai_constants.tcs_regime;

3191: AND jspl.delivery_id = v_delivery_id
3192: AND jspl.delivery_detail_id = v_delivery_detail_id
3193: AND jsptl.tax_id = jtc.tax_id
3194: AND jtc.tax_type = jrttv.tax_type
3195: AND jrttv.regime_code = jai_constants.tcs_regime;
3196:
3197: CURSOR c_location_id IS
3198: SELECT NVL(Location_id,0)
3199: FROM JAI_INV_SUBINV_DTLS

Line 3204: pv_return_code := jai_constants.successful;

3200: WHERE Sub_Inventory_Name = v_subinventory
3201: AND organization_id = v_organization_id;
3202:
3203: BEGIN
3204: pv_return_code := jai_constants.successful;
3205:
3206: v_delivery_id := p_delivery_id;
3207: v_delivery_detail_id := pr_new.delivery_detail_id;
3208: v_organization_id := pr_new.organization_id;

Line 3230: p_organization_type => jai_constants.orgn_type_io ,

3226: || by calling the function jai_cmn_rgm_recording_pkg.get_account
3227: *********************************************************************************************************/
3228: v_liab_acc_ccid := jai_cmn_rgm_recording_pkg.get_account (
3229: p_regime_id => rec_cur_get_picking_taxes.regime_id ,
3230: p_organization_type => jai_constants.orgn_type_io ,
3231: p_organization_id => v_organization_id ,
3232: p_location_id => v_location_id ,
3233: p_tax_type => rec_cur_get_picking_taxes.tax_type ,
3234: p_account_name => jai_constants.liability

Line 3234: p_account_name => jai_constants.liability

3230: p_organization_type => jai_constants.orgn_type_io ,
3231: p_organization_id => v_organization_id ,
3232: p_location_id => v_location_id ,
3233: p_tax_type => rec_cur_get_picking_taxes.tax_type ,
3234: p_account_name => jai_constants.liability
3235: );
3236:
3237: v_int_liab_acc_ccid := jai_cmn_rgm_recording_pkg.get_account (
3238: p_regime_id => rec_cur_get_picking_taxes.regime_id ,

Line 3239: p_organization_type => jai_constants.orgn_type_io ,

3235: );
3236:
3237: v_int_liab_acc_ccid := jai_cmn_rgm_recording_pkg.get_account (
3238: p_regime_id => rec_cur_get_picking_taxes.regime_id ,
3239: p_organization_type => jai_constants.orgn_type_io ,
3240: p_organization_id => v_organization_id ,
3241: p_location_id => v_location_id ,
3242: p_tax_type => rec_cur_get_picking_taxes.tax_type ,
3243: p_account_name => jai_constants.liability_interim

Line 3243: p_account_name => jai_constants.liability_interim

3239: p_organization_type => jai_constants.orgn_type_io ,
3240: p_organization_id => v_organization_id ,
3241: p_location_id => v_location_id ,
3242: p_tax_type => rec_cur_get_picking_taxes.tax_type ,
3243: p_account_name => jai_constants.liability_interim
3244: );
3245:
3246:
3247:

Line 3255: pv_return_code := jai_constants.expected_error;

3251: /**********************************************************************************************************
3252: || Code Combination id has been returned as null from the function jai_cmn_rgm_recording_pkg.get_account
3253: || This is an error condition and the current processing has to be stopped
3254: **********************************************************************************************************/
3255: pv_return_code := jai_constants.expected_error;
3256: pv_return_message := 'Invalid Code combination ,please check the TCS Tax - Tax Accounting Setup';
3257: return;
3258: END IF;
3259: END LOOP;

Line 3263: pv_return_code := jai_constants.unexpected_error;

3259: END LOOP;
3260:
3261: EXCEPTION
3262: WHEN OTHERS THEN
3263: pv_return_code := jai_constants.unexpected_error;
3264: pv_return_message := 'Unexpected error in the jai_om_wdd_processing_pkg.validate_wsh_interim_accounting '||substr(sqlerrm,1,300);
3265:
3266: END VALIDATE_WSH_INTERIM_ACCT;
3267:

Line 3298: px_return_code := jai_constants.successful;

3294: lv_return_message VARCHAR2(240);
3295:
3296: BEGIN
3297:
3298: px_return_code := jai_constants.successful;
3299: lv_delivery_id := p_delivery_id;
3300:
3301: if check_status (pr_new => p_rec_new) = 'N' then
3302: return;

Line 3309: if lv_return_code <> jai_constants.successful then

3305: validate_matched_qty(pr_new => p_rec_new,
3306: pv_return_code => lv_return_code,
3307: pv_return_message => lv_return_message);
3308:
3309: if lv_return_code <> jai_constants.successful then
3310: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3311: FND_LOG.STRING(G_LEVEL_STATEMENT,
3312: G_MODULE_NAME || v_api_name,
3313: 'validate_matched_qty returned with ' || lv_return_code || lv_return_message);

Line 3331: if lv_return_code <> jai_constants.successful then

3327: validate_currency(pr_new => p_rec_new,
3328: pv_return_code => lv_return_code,
3329: pv_return_message => lv_return_message);
3330:
3331: if lv_return_code <> jai_constants.successful then
3332: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3333: FND_LOG.STRING(G_LEVEL_STATEMENT,
3334: G_MODULE_NAME || v_api_name,
3335: 'validate_currency returned with ' || lv_return_code || lv_return_message);

Line 3353: if lv_return_code <> jai_constants.successful then

3349: validate_tcs_taxes(pr_new => p_rec_new,
3350: pv_return_code => lv_return_code,
3351: pv_return_message => lv_return_message);
3352:
3353: if lv_return_code <> jai_constants.successful then
3354: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3355: FND_LOG.STRING(G_LEVEL_STATEMENT,
3356: G_MODULE_NAME || v_api_name,
3357: 'validate_tcs_taxes returned with ' || lv_return_code || lv_return_message);

Line 3376: /*if px_return_code <> jai_constants.successful then*/ -- commented out by zhiwei.xin for bug #16207271 on 5-FEB-2013

3372: pr_new => p_rec_new,
3373: pv_return_code => lv_return_code,
3374: pv_return_message => lv_return_message);
3375:
3376: /*if px_return_code <> jai_constants.successful then*/ -- commented out by zhiwei.xin for bug #16207271 on 5-FEB-2013
3377: if lv_return_code <> jai_constants.successful then -- added by zhiwei.xin for bug #16207271 on 5-FEB-2013
3378: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3379: FND_LOG.STRING(G_LEVEL_STATEMENT,
3380: G_MODULE_NAME || v_api_name,

Line 3377: if lv_return_code <> jai_constants.successful then -- added by zhiwei.xin for bug #16207271 on 5-FEB-2013

3373: pv_return_code => lv_return_code,
3374: pv_return_message => lv_return_message);
3375:
3376: /*if px_return_code <> jai_constants.successful then*/ -- commented out by zhiwei.xin for bug #16207271 on 5-FEB-2013
3377: if lv_return_code <> jai_constants.successful then -- added by zhiwei.xin for bug #16207271 on 5-FEB-2013
3378: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3379: FND_LOG.STRING(G_LEVEL_STATEMENT,
3380: G_MODULE_NAME || v_api_name,
3381: 'validate_wsh_interim_acct returned with ' || lv_return_code || lv_return_message);

Line 3400: lv_return_code := jai_constants.unexpected_error;

3396: px_exp_msg := lt_exp_msg;
3397:
3398: Exception
3399: When Others then
3400: lv_return_code := jai_constants.unexpected_error;
3401: lv_return_message := substr(sqlerrm,1,200) ;
3402: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3403: FND_LOG.STRING(G_LEVEL_STATEMENT,
3404: G_MODULE_NAME || v_api_name,

Line 3490: IF lv_return_code <> jai_constants.successful then

3486: G_MODULE_NAME || v_api_name,
3487: 'Validation processing returned with ' || lv_return_code);
3488: END IF;
3489:
3490: IF lv_return_code <> jai_constants.successful then
3491: raise le_val;
3492: END IF;
3493:
3494: PROCESS_INTERFACED (pr_old => null,

Line 3496: pv_action => jai_constants.updating,

3492: END IF;
3493:
3494: PROCESS_INTERFACED (pr_old => null,
3495: pr_new => rec_wdd,
3496: pv_action => jai_constants.updating,
3497: pv_return_code => lv_return_code,
3498: pv_return_message => lv_return_msg);
3499:
3500: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN

Line 3506: IF lv_return_code <> jai_constants.successful then

3502: G_MODULE_NAME || v_api_name,
3503: 'Interfaced processing returned with ' || lv_return_code || lv_return_msg);
3504: END IF;
3505:
3506: IF lv_return_code <> jai_constants.successful then
3507: raise le_sub;
3508: END IF;
3509:
3510: /* accounting entries for RG23D reversal */

Line 3521: IF lv_return_code <> jai_constants.successful then

3517: G_MODULE_NAME || v_api_name,
3518: 'accounting entries for RG23D reversal returned with ' || lv_return_code || lv_return_msg);
3519: END IF;
3520:
3521: IF lv_return_code <> jai_constants.successful then
3522: raise le_sub;
3523: END IF;
3524: END LOOP;
3525:

Line 3552: lv_return_code := jai_constants.unexpected_error;

3548: -- added for wsh exception handling on 4-JAN-2013 end.
3549: RETURN 'ERROR';
3550: WHEN OTHERS THEN
3551: -- added for wsh exception handling on 4-JAN-2013 begin
3552: lv_return_code := jai_constants.unexpected_error;
3553: lv_return_msg := substr(sqlerrm,1,200);
3554:
3555: rec_exp_msg.EXCEPTION_TYPE := 'E';
3556: rec_exp_msg.EXCEPTION_ENTITY := v_exp_entity;

Line 3618: pv_action => jai_constants.updating,

3614: FOR rec_wdd IN c_get_delivery_details (to_number(l_eventkey))
3615: LOOP
3616: PROCESS_RELEASED (pr_old => null,
3617: pr_new => rec_wdd,
3618: pv_action => jai_constants.updating,
3619: pv_return_code => lv_return_code,
3620: pv_return_message => lv_return_msg);
3621:
3622: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN

Line 3628: IF lv_return_code <> jai_constants.successful then

3624: G_MODULE_NAME || v_api_name,
3625: 'Released processing returned with ' || lv_return_code || lv_return_msg);
3626: END IF;
3627:
3628: IF lv_return_code <> jai_constants.successful then
3629: raise le_sub;
3630: END IF;
3631: END LOOP;
3632: END IF;

Line 3752: lv_return_code := jai_constants.unexpected_error;

3748:
3749: RETURN 'ERROR';
3750:
3751: WHEN OTHERS THEN
3752: lv_return_code := jai_constants.unexpected_error;
3753: lv_return_msg := substr(sqlerrm,1,200);
3754:
3755: rec_exp_msg.EXCEPTION_TYPE := 'E';
3756: rec_exp_msg.EXCEPTION_ENTITY := v_exp_entity;

Line 3823: where regime_code = jai_constants.vat_regime;

3819: cursor c_get_vat_regime
3820: is
3821: select regime_id
3822: from JAI_RGM_DEFINITIONS
3823: where regime_code = jai_constants.vat_regime;
3824:
3825: cursor c_deliver_date(p_delivery_id JAI_RGM_INVOICE_GEN_T.delivery_id%type)
3826: is
3827: select delivery_date

Line 3841: AND attribute_type_code = jai_constants.rgm_attr_type_code_primary

3837: CURSOR c_reg_num(cp_regime_id number,cp_organization_id wsh_delivery_details.ORGANIZATION_ID%TYPE , cp_location_id wsh_delivery_details.ship_to_location_id%TYPE ) IS
3838: SELECT attribute_Value
3839: FROM JAI_RGM_ORG_REGNS_V
3840: WHERE regime_id = cp_regime_id
3841: AND attribute_type_code = jai_constants.rgm_attr_type_code_primary
3842: AND attribute_code = jai_constants.attr_code_regn_no
3843: AND organization_id = cp_organization_id
3844: AND location_id = cp_location_id;
3845:

Line 3842: AND attribute_code = jai_constants.attr_code_regn_no

3838: SELECT attribute_Value
3839: FROM JAI_RGM_ORG_REGNS_V
3840: WHERE regime_id = cp_regime_id
3841: AND attribute_type_code = jai_constants.rgm_attr_type_code_primary
3842: AND attribute_code = jai_constants.attr_code_regn_no
3843: AND organization_id = cp_organization_id
3844: AND location_id = cp_location_id;
3845:
3846: BEGIN

Line 3914: ',p_process_action : ' || jai_constants.om_action_gen_inv_n_accnt ||

3910: ',p_delivery_id_from : ' || lv_delivery_id ||
3911: ',p_delivery_id_to : ' || lv_delivery_id ||
3912: ',pv_delivery_date_from : ' || to_char(lv_delivery_date,'yyyy-MM-dd HH24:MI:SS') ||
3913: ',pv_delivery_date_to : ' || to_char(lv_delivery_date,'yyyy-MM-dd HH24:MI:SS') ||
3914: ',p_process_action : ' || jai_constants.om_action_gen_inv_n_accnt ||
3915: ',p_single_invoice_num : ' || 'N' ||
3916: ',p_override_invoice_date : ' || to_char(sysdate,'yyyy-MM-dd HH24:MI:SS') ||
3917: ',p_debug : ' || jai_constants.no ||
3918: ',p_called_from : ' || 'BE');

Line 3917: ',p_debug : ' || jai_constants.no ||

3913: ',pv_delivery_date_to : ' || to_char(lv_delivery_date,'yyyy-MM-dd HH24:MI:SS') ||
3914: ',p_process_action : ' || jai_constants.om_action_gen_inv_n_accnt ||
3915: ',p_single_invoice_num : ' || 'N' ||
3916: ',p_override_invoice_date : ' || to_char(sysdate,'yyyy-MM-dd HH24:MI:SS') ||
3917: ',p_debug : ' || jai_constants.no ||
3918: ',p_called_from : ' || 'BE');
3919: END IF;
3920:
3921: -- VAT Invoice Generation / Accounting

Line 3934: p_process_action => jai_constants.om_action_gen_inv_n_accnt,

3930: p_delivery_id_from => lv_delivery_id,
3931: p_delivery_id_to => lv_delivery_id,
3932: pv_delivery_date_from => to_char(lv_delivery_date,'yyyy-MM-dd HH24:MI:SS'),
3933: pv_delivery_date_to => to_char(lv_delivery_date,'yyyy-MM-dd HH24:MI:SS'),
3934: p_process_action => jai_constants.om_action_gen_inv_n_accnt,
3935: p_single_invoice_num => 'N',
3936: p_override_invoice_date => sysdate,
3937: p_debug => jai_constants.no,
3938: p_called_from => 'BE');

Line 3937: p_debug => jai_constants.no,

3933: pv_delivery_date_to => to_char(lv_delivery_date,'yyyy-MM-dd HH24:MI:SS'),
3934: p_process_action => jai_constants.om_action_gen_inv_n_accnt,
3935: p_single_invoice_num => 'N',
3936: p_override_invoice_date => sysdate,
3937: p_debug => jai_constants.no,
3938: p_called_from => 'BE');
3939:
3940: IF (G_LEVEL_STATEMENT >= G_CURRENT_RUNTIME_LEVEL) THEN
3941: FND_LOG.STRING(G_LEVEL_STATEMENT,