84: -- For Process Order
85: l_line_rec OE_ORDER_PUB.line_rec_type;
86: l_old_line_tbl OE_ORDER_PUB.line_tbl_type;
87: l_line_tbl OE_ORDER_PUB.line_tbl_type;
88: l_control_rec OE_GLOBALS.control_rec_type;
89:
90: l_valid_employee VARCHAR2(25);
91: l_temp_employee_Id NUMBER; -- Temp ID got from profile option
92: l_order_source_id NUMBER;
164:
165:
166: /* Added for the bug 6118936 */
167:
168: l_user_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'USER_ID');
169: l_resp_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'RESPONSIBILITY_ID');
170: l_application_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'APPLICATION_ID');
171:
172:
165:
166: /* Added for the bug 6118936 */
167:
168: l_user_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'USER_ID');
169: l_resp_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'RESPONSIBILITY_ID');
170: l_application_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'APPLICATION_ID');
171:
172:
173: IF l_debug_level > 0 THEN
166: /* Added for the bug 6118936 */
167:
168: l_user_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'USER_ID');
169: l_resp_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'RESPONSIBILITY_ID');
170: l_application_id := wf_engine.GetItemAttrNumber( OE_GLOBALS.G_WFI_LIN , to_char(l_drop_ship_line_rec.line_id) , 'APPLICATION_ID');
171:
172:
173: IF l_debug_level > 0 THEN
174: oe_debug_pub.add('User id => ' ||l_user_id,1);
179:
180: /* End of bug 6118936 */
181:
182:
183: IF FND_PROFILE.VALUE('ONT_INCLUDED_ITEM_FREEZE_METHOD') = OE_GLOBALS.G_IIFM_PICK_RELEASE THEN
184: IF l_debug_level > 0 THEN
185: oe_debug_pub.add('may need to freeze inc items',5);
186: END IF;
187:
218: p_mode => p_mode);
219: IF l_debug_level > 0 THEN
220: oe_debug_pub.add('Source Type Code => '||l_drop_ship_line_rec.source_type_code,5);
221: END IF;
222: IF (l_drop_ship_line_rec.item_type_code <> OE_GLOBALS.G_ITEM_SERVICE) THEN
223: OPEN C_Payment_Type(l_drop_ship_line_rec.header_id);
224: FETCH C_Payment_Type INTO l_payment_type;
225: CLOSE C_Payment_Type;
226:
465: oe_debug_pub.add('Item type code ' || l_drop_ship_line_rec.item_type_code , 1 ) ;
466: END IF;
467:
468:
469: IF NOT OE_GLOBALS.Equal(l_drop_ship_line_rec.source_type_code, OE_GLOBALS.G_SOURCE_EXTERNAL) THEN
470: IF l_debug_level > 0 THEN
471: oe_debug_pub.add('Wrong source type '|| l_drop_ship_line_rec.line_id,3);
472: END IF;
473: l_drop_ship_line_rec.result := G_RES_NOT_APPLICABLE;
509: l_old_line_tbl(1) := l_line_rec;
510:
511: l_line_rec.schedule_ship_date := l_line_rec.request_date;
512:
513: l_line_rec.operation := OE_GLOBALS.G_OPR_UPDATE;
514: l_line_tbl(1) := l_line_rec;
515:
516: /* Start Audit Trail */
517: l_line_tbl(1).change_reason := 'SYSTEM';
522: l_control_rec.change_attributes := TRUE;
523: l_control_rec.validate_entity := TRUE;
524: l_control_rec.write_to_DB := TRUE;
525: l_control_rec.check_security := TRUE;
526: l_control_rec.process_entity := OE_GLOBALS.G_ENTITY_LINE;
527: l_control_rec.process := TRUE;
528:
529: -- Instruct API to retain its caches
530:
1117: AND sl.inventory_item_id = msi.inventory_item_id
1118: AND sl.ship_from_org_id = msi.organization_id
1119: AND mp.organization_id = msi.organization_id
1120: AND sl.ship_to_org_id = pla.site_use_id(+)
1121: AND sl.source_type_code = OE_GLOBALS.G_SOURCE_EXTERNAL;
1122:
1123: l_drop_ship_line_rec Drop_Ship_Line_Rec_Type;
1124: l_drop_ship_tbl Drop_Ship_Tbl_Type;
1125: l_line_count NUMBER;
1414: END IF;
1415:
1416: IF p_request_tbl(I).param15 = 'UPDATE' THEN
1417:
1418: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param1
1419: ,p_request_tbl(I).param8) THEN
1420:
1421: IF l_req_created = 'N' THEN
1422: l_ds_quantity := p_request_tbl(I).param8;
1441:
1442: END IF;
1443:
1444:
1445: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param2
1446: ,p_request_tbl(I).param9) THEN
1447: IF l_req_created = 'N' THEN
1448: l_ds_ordered_quantity_uom := p_request_tbl(I).param9;
1449: END IF;
1457:
1458:
1459: END IF;
1460:
1461: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param3
1462: ,p_request_tbl(I).param10) THEN
1463:
1464: l_ds_new_ship_to_location_id := Get_Shipto_Location_id(p_request_tbl(I).param10);
1465: l_ds_old_ship_to_location_id := Get_Shipto_Location_id(p_request_tbl(I).param3);
1463:
1464: l_ds_new_ship_to_location_id := Get_Shipto_Location_id(p_request_tbl(I).param10);
1465: l_ds_old_ship_to_location_id := Get_Shipto_Location_id(p_request_tbl(I).param3);
1466:
1467: IF NOT OE_GLOBALS.EQUAL(l_ds_new_ship_to_location_id,
1468: l_ds_old_ship_to_location_id) THEN
1469:
1470: IF l_req_created = 'N' THEN
1471: l_ds_ship_to_location_id := l_ds_new_ship_to_location_id;
1494: END IF;
1495:
1496:
1497:
1498: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param4
1499: ,p_request_tbl(I).param11) THEN
1500:
1501: IF l_req_created = 'N' THEN
1502: l_ds_ordered_quantity2 := p_request_tbl(I).param11;
1521:
1522: END IF;
1523:
1524:
1525: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param5
1526: ,p_request_tbl(I).param12) THEN
1527:
1528: IF l_req_created = 'N' THEN
1529: l_ds_ordered_quantity_uom2 := p_request_tbl(I).param12;
1537: END IF;
1538:
1539: END IF;
1540:
1541: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param6
1542: ,p_request_tbl(I).param13) THEN
1543:
1544: IF l_req_created = 'N' THEN
1545: l_ds_preferred_grade := p_request_tbl(I).param13;
1557:
1558:
1559: /*****Begin changes for bug#6918700*********/
1560:
1561: -- IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param7 ,p_request_tbl(I).param14) THEN
1562:
1563: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).date_param1 ,p_request_tbl(I).date_param2) THEN
1564: /*****End changes for bug#6918700*********/
1565:
1559: /*****Begin changes for bug#6918700*********/
1560:
1561: -- IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).param7 ,p_request_tbl(I).param14) THEN
1562:
1563: IF NOT OE_GLOBALS.EQUAL(p_request_tbl(I).date_param1 ,p_request_tbl(I).date_param2) THEN
1564: /*****End changes for bug#6918700*********/
1565:
1566: IF l_req_created = 'N' THEN
1567: /*****Begin changes for bug#6918700*********/