[Home] [Help]
44: 12/10/2007 Kevin Cheng Update the logic for inclusive tax calculation
45:
46: 05-Mar-08 Jia Li Added clause logic for bug# 6846048
47: Issue: When unit selling price is changed because of discounts,
48: inclusive taxes are getting added to the tax amount in the JAI_OM_OE_SO_LINES table.
49: So at ship confirm time, comparing the tax amount in the lines table with the sum of exclusive taxes
50: in the taxes table was not matching and hence the trigger was returning an error.
51: Fix: Ensuring that only exclusive taxes are added to the tax amount in the jai_om_oe_so_lines table.
52:
47: Issue: When unit selling price is changed because of discounts,
48: inclusive taxes are getting added to the tax amount in the JAI_OM_OE_SO_LINES table.
49: So at ship confirm time, comparing the tax amount in the lines table with the sum of exclusive taxes
50: in the taxes table was not matching and hence the trigger was returning an error.
51: Fix: Ensuring that only exclusive taxes are added to the tax amount in the jai_om_oe_so_lines table.
52:
53: 22-Oct-2008 CSahoo - bug#4918667, File Version 120.14.12010000.2
54: Issue :- In case of retrobilling functionality, there was a divide by zero error which is caused.
55: The parameter p_line_quantity is being used as a denominator, and in case it is zero
347: IS
348: SELECT
349: '1'
350: FROM
351: JAI_OM_OE_SO_LINES jsl
352: WHERE
353: jsl.excise_exempt_type IS NOT NULL AND
354: jsl.line_id = p_line_id ;
355:
446: 10. 10-Dec-007 Kevin Cheng Update the logic for inclusive tax calculation
447:
448: 11. 05-Mar-08 Jia Li Added clause logic for bug# 6846048
449: Issue: When unit selling price is changed because of discounts,
450: inclusive taxes are getting added to the tax amount in the JAI_OM_OE_SO_LINES table.
451: So at ship confirm time, comparing the tax amount in the lines table with the sum of exclusive taxes
452: in the taxes table was not matching and hence the trigger was returning an error.
453: Fix: Ensuring that only exclusive taxes are added to the tax amount in the jai_om_oe_so_lines table.
454:
449: Issue: When unit selling price is changed because of discounts,
450: inclusive taxes are getting added to the tax amount in the JAI_OM_OE_SO_LINES table.
451: So at ship confirm time, comparing the tax amount in the lines table with the sum of exclusive taxes
452: in the taxes table was not matching and hence the trigger was returning an error.
453: Fix: Ensuring that only exclusive taxes are added to the tax amount in the jai_om_oe_so_lines table.
454:
455: Future Dependencies For the release Of this Object:-
456: (Please add a row in the section below only if your bug introduces a dependency due to spec change/ A new call to a object/
457: A datamodel change )
1508: p_last_update_login IN NUMBER
1509: ) IS
1510:
1511: -- P_TAX_AMOUNT input parameter will contain the line_tax_amount after successful completion of the procedure which
1512: -- can be used to update the line amount in JAI_OM_OE_SO_LINES
1513:
1514: TYPE num_tab IS TABLE OF NUMBER(20,3) INDEX BY BINARY_INTEGER;
1515: TYPE tax_amt_num_tab IS TABLE OF NUMBER(20,3) INDEX BY BINARY_INTEGER;
1516:
1674: IS
1675: SELECT
1676: '1'
1677: FROM
1678: JAI_OM_OE_SO_LINES jsl
1679: WHERE
1680: jsl.excise_exempt_type IS NOT NULL AND
1681: jsl.line_id = p_line_id ;
1682:
2372: v_reference_line_id oe_order_lines_all.reference_line_id%TYPE; -- used for return lines
2373: v_item_type_code oe_order_lines_all.item_type_code%TYPE;
2374: v_unit_selling_price oe_order_lines_all.unit_selling_price%TYPE;
2375: v_operating_id oe_order_lines_all.org_id%TYPE;
2376: v_old_assessable_value JAI_OM_OE_SO_LINES.assessable_value%TYPE;
2377: v_line_amount NUMBER := 0;
2378:
2379: v_original_system_reference VARCHAR2(50);
2380: v_customer_id Number;
2464: base.SOURCE_DOCUMENT_TYPE_ID, ja.assessable_value,
2465: NVL(head.org_id,0) org_id1, head.SOLD_TO_ORG_ID, head.SOURCE_DOCUMENT_ID hsdi, head.order_number,
2466: head.price_list_id, head.ORDER_CATEGORY_CODE, head.ORIG_SYS_DOCUMENT_REF, head.TRANSACTIONAL_CURR_CODE,
2467: head.conversion_type_code, head.conversion_rate, head.CONVERSION_RATE_DATE, nvl(head.ORDERED_DATE, head.creation_date) ordered_date
2468: FROM oe_order_headers_all head, oe_order_lines_all base, JAI_OM_OE_SO_LINES ja
2469: WHERE head.header_id = base.header_id
2470: and base.line_id = ja.line_id
2471: and base.OPEN_FLAG = 'Y'
2472: and base.line_category_code = 'ORDER'
2791: v_last_update_login
2792: );
2793: -- added by cbabu for Bug#2496481, end
2794:
2795: UPDATE JAI_OM_OE_SO_LINES
2796: SET assessable_value = v_assessable_value,
2797: tax_amount = nvl(v_line_tax_amount,0),
2798: line_amount = v_line_amount,
2799: line_tot_amount = v_line_amount + nvl(v_line_tax_amount,0),