DBA Data[Home] [Help]

APPS.OE_SALES_CAN_UTIL dependencies on OE_DEBUG_PUB

Line 49: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

45: l_return_status VARCHAR2(1);
46: l_line_rec OE_Order_PUB.Line_Rec_Type;
47:
48: --
49: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
50: --
51: Begin
52:
53: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 56: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.UPDATE_LINE' ) ;

52:
53: x_return_status := FND_API.G_RET_STS_SUCCESS;
54:
55: IF l_debug_level > 0 THEN
56: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.UPDATE_LINE' ) ;
57: END IF;
58:
59: -- Set control flags.
60:

Line 76: oe_debug_pub.add( 'BEFORE CALLING LOCK ROW' ) ;

72:
73: -- Read line from cache
74:
75: IF l_debug_level > 0 THEN
76: oe_debug_pub.add( 'BEFORE CALLING LOCK ROW' ) ;
77: END IF;
78:
79: /* Fix for Bug 1763178. Passing line record instead of table. */
80:

Line 88: oe_debug_pub.add( 'AFTER CALLING LOCK ROW' ) ;

84: ,x_return_status => l_return_status
85: );
86:
87: IF l_debug_level > 0 THEN
88: oe_debug_pub.add( 'AFTER CALLING LOCK ROW' ) ;
89: END IF;
90:
91: IF l_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
92: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 118: oe_debug_pub.add( 'BEFORE CALLING PROCESS ORDER' ) ;

114: -- Call OE_Order_PVT.Process_order
115: g_ser_cascade := TRUE;
116:
117: IF l_debug_level > 0 THEN
118: oe_debug_pub.add( 'BEFORE CALLING PROCESS ORDER' ) ;
119: END IF;
120:
121: oe_order_pvt.Lines
122: ( p_validation_level => FND_API.G_VALID_LEVEL_NONE

Line 136: oe_debug_pub.add( 'AFTER CALLING PROCESS ORDER' ) ;

132: RAISE FND_API.G_EXC_ERROR;
133: END IF;
134:
135: IF l_debug_level > 0 THEN
136: oe_debug_pub.add( 'AFTER CALLING PROCESS ORDER' ) ;
137: END IF;
138:
139: /* jolin start comment out nocopy for notification project
140:

Line 151: oe_debug_pub.ADD('Update Line Process Order return UNEXP_ERROR');

147: , p_old_line_tbl => l_old_line_tbl
148: );
149:
150: IF l_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
151: oe_debug_pub.ADD('Update Line Process Order return UNEXP_ERROR');
152: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
153: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
154: oe_debug_pub.ADD('Update Line Process Order return RET_STS_ERROR');
155: RAISE FND_API.G_EXC_ERROR;

Line 154: oe_debug_pub.ADD('Update Line Process Order return RET_STS_ERROR');

150: IF l_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
151: oe_debug_pub.ADD('Update Line Process Order return UNEXP_ERROR');
152: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
153: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
154: oe_debug_pub.ADD('Update Line Process Order return RET_STS_ERROR');
155: RAISE FND_API.G_EXC_ERROR;
156: END IF;
157: jolin end */
158:

Line 162: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.UPDATE_LINE' ) ;

158:
159: g_ser_cascade := FALSE;
160:
161: IF l_debug_level > 0 THEN
162: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.UPDATE_LINE' ) ;
163: END IF;
164:
165: EXCEPTION
166: WHEN FND_API.G_EXC_ERROR THEN

Line 180: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;

176: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
177: WHEN OTHERS THEN
178: g_ser_cascade := FALSE;
179: IF l_debug_level > 0 THEN
180: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;
181: END IF;
182: IF oe_msg_pub.Check_MSg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
183: oe_msg_pub.Add_Exc_Msg
184: (G_PKG_NAME

Line 242: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

238:
239: l_require_reason BOOLEAN;
240:
241: --
242: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
243: --
244: BEGIN
245:
246: -- bug2743789 if cancellation is defined at entered level and audit parameter

Line 251: OE_DEBUG_PUB.add('Entering perform_line_change() with reason required flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);

247: -- defined at booked orders only, then cancel history record would be inserted
248: -- without reason code.
249:
250: IF l_debug_level > 0 THEN
251: OE_DEBUG_PUB.add('Entering perform_line_change() with reason required flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
252: END IF;
253:
254: l_order_quantity_uom := p_line_rec.order_quantity_uom; --bug 5702849
255: oe_debug_pub.add('5702849: Value of l_order_quantity_uom :'||l_order_quantity_uom);

Line 255: oe_debug_pub.add('5702849: Value of l_order_quantity_uom :'||l_order_quantity_uom);

251: OE_DEBUG_PUB.add('Entering perform_line_change() with reason required flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
252: END IF;
253:
254: l_order_quantity_uom := p_line_rec.order_quantity_uom; --bug 5702849
255: oe_debug_pub.add('5702849: Value of l_order_quantity_uom :'||l_order_quantity_uom);
256:
257: IF (p_line_rec.operation <> oe_globals.g_opr_create AND
258: -- p_line_rec.split_action_code <> 'SPLIT') THEN -- Bug 8841055
259: Nvl(p_line_rec.split_action_code,Fnd_Api.G_Miss_Char) <> 'SPLIT') THEN

Line 262: oe_debug_pub.add('Entering oe_sales_can_util.perform_line_change' ) ;

258: -- p_line_rec.split_action_code <> 'SPLIT') THEN -- Bug 8841055
259: Nvl(p_line_rec.split_action_code,Fnd_Api.G_Miss_Char) <> 'SPLIT') THEN
260:
261: IF l_debug_level > 0 THEN
262: oe_debug_pub.add('Entering oe_sales_can_util.perform_line_change' ) ;
263: END IF;
264:
265: x_return_status := FND_API.G_RET_STS_SUCCESS;
266:

Line 309: oe_debug_pub.add('Before calling update_service()',1) ;

305: */
306: l_require_reason := oe_sales_can_util.g_require_reason;
307:
308: IF l_debug_level > 0 THEN
309: oe_debug_pub.add('Before calling update_service()',1) ;
310: END IF;
311:
312: update_service(p_line_rec, p_old_line_rec, x_return_status);
313:

Line 315: oe_debug_pub.add('After calling update_service , return status : '||x_return_status,1) ;

311:
312: update_service(p_line_rec, p_old_line_rec, x_return_status);
313:
314: IF l_debug_level > 0 THEN
315: oe_debug_pub.add('After calling update_service , return status : '||x_return_status,1) ;
316: END IF;
317:
318: if x_return_status <> FND_API.G_RET_STS_SUCCESS then
319: if x_return_status = FND_API.G_RET_STS_ERROR then

Line 353: oe_debug_pub.add('Qty reduced on internal order',1);

349:
350: IF p_line_rec.source_document_type_id = 10 THEN
351: IF (nvl(p_line_rec.ordered_quantity,0) < nvl(p_old_line_rec.ordered_quantity,0)) THEN
352: IF l_debug_level > 0 THEN
353: oe_debug_pub.add('Qty reduced on internal order',1);
354: END IF;
355:
356: po_supply_id := p_line_rec.source_document_line_id;
357: po_header_id := p_line_rec.source_document_id; --Bug 5335066

Line 363: oe_debug_pub.add( 'SUPPLY ID EXISTS , BEFORE CALLING PO_SUPPLY.PO_REQ_SUPPLY ( ) ' ) ;

359:
360: IF po_supply_id IS NOT NULL THEN
361:
362: IF l_debug_level > 0 THEN
363: oe_debug_pub.add( 'SUPPLY ID EXISTS , BEFORE CALLING PO_SUPPLY.PO_REQ_SUPPLY ( ) ' ) ;
364: END IF;
365: -- INVCONV no requirement to change this
366:
367: IF p_line_rec.split_from_line_id IS NOT NULL THEN -- 6710187 start

Line 407: oe_debug_pub.add('After calling po_supply.po_req_supply()',1);

403: p_ordered_uom => l_order_quantity_uom);
404: --p_reservation_action added for bug4277603
405:
406: IF l_debug_level > 0 THEN
407: oe_debug_pub.add('After calling po_supply.po_req_supply()',1);
408: END IF;
409:
410: END IF;
411:

Line 425: OE_DEBUG_PUB.add('Audit Trail Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);

421: /* IR ISO Change Management project End */
422:
423:
424: IF l_debug_level > 0 THEN
425: OE_DEBUG_PUB.add('Audit Trail Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
426: oe_debug_pub.add('Line change reason : '||p_line_rec.change_reason,1);
427: END IF;
428:
429: -- #2743789 changes

Line 426: oe_debug_pub.add('Line change reason : '||p_line_rec.change_reason,1);

422:
423:
424: IF l_debug_level > 0 THEN
425: OE_DEBUG_PUB.add('Audit Trail Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
426: oe_debug_pub.add('Line change reason : '||p_line_rec.change_reason,1);
427: END IF;
428:
429: -- #2743789 changes
430: IF oe_sales_can_util.G_REQUIRE_REASON THEN

Line 433: oe_debug_pub.add('Change reason required',1);

429: -- #2743789 changes
430: IF oe_sales_can_util.G_REQUIRE_REASON THEN
431:
432: IF l_debug_level > 0 THEN
433: oe_debug_pub.add('Change reason required',1);
434: END IF;
435:
436: --Commented out hre following block of code for bug #3665150
437: /* IF OE_CODE_CONTROL.CODE_RELEASE_LEVEL >= '110508' THEN -- reinstated for 2653505

Line 443: oe_debug_pub.add('Cancellation Reason is Not Provided',1);

439: IF OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG <> 'N' THEN
440: IF p_line_rec.change_reason IS NULL OR
441: p_line_rec.change_reason = FND_API.G_MISS_CHAR THEN
442: IF l_debug_level > 0 THEN
443: oe_debug_pub.add('Cancellation Reason is Not Provided',1);
444: END IF;
445: fnd_message.set_name('ONT','OE_CAN_REASON_NOT');
446: oe_msg_pub.add;
447: raise FND_API.G_EXC_ERROR;

Line 455: oe_debug_pub.add('Cancellation Reason is Not Provided',1);

451: ELSE.*/
452: IF p_line_rec.change_reason IS NULL OR
453: p_line_rec.change_reason = FND_API.G_MISS_CHAR THEN
454: IF l_debug_level > 0 THEN
455: oe_debug_pub.add('Cancellation Reason is Not Provided',1);
456: END IF;
457: fnd_message.set_name('ONT','OE_CAN_REASON_NOT');
458: oe_msg_pub.add;
459: raise FND_API.G_EXC_ERROR;

Line 467: oe_debug_pub.add('Before calling record line history',5);

463:
464: IF p_line_rec.change_reason IS NOT NULL AND p_line_rec.change_reason <> FND_API.G_MISS_CHAR THEN
465:
466: IF l_debug_level > 0 THEN
467: oe_debug_pub.add('Before calling record line history',5);
468: END IF;
469:
470: --11.5.10 Versioning/Audit Trail updates
471: IF OE_CODE_CONTROL.CODE_RELEASE_LEVEL >= '110510' THEN

Line 504: oe_debug_pub.add('After calling record line history',5);

500: END IF;
501: END IF;
502:
503: IF l_debug_level > 0 THEN
504: oe_debug_pub.add('After calling record line history',5);
505: END IF;
506:
507: END IF;
508:

Line 516: oe_debug_pub.add( 'JPN: IT IS A OTA LINE' , 1 ) ;

512: l_is_ota_line := OE_OTA_UTIL.Is_OTA_Line(l_order_quantity_uom);
513:
514: If (l_is_ota_line) THEN
515: IF l_debug_level > 0 THEN
516: oe_debug_pub.add( 'JPN: IT IS A OTA LINE' , 1 ) ;
517: END IF;
518:
519: IF p_line_rec.ordered_quantity = 0 THEN
520: IF l_debug_level > 0 THEN

Line 521: oe_debug_pub.add( 'JPN: BEFORE CALLING NOTIFY_OTA' , 1 ) ;

517: END IF;
518:
519: IF p_line_rec.ordered_quantity = 0 THEN
520: IF l_debug_level > 0 THEN
521: oe_debug_pub.add( 'JPN: BEFORE CALLING NOTIFY_OTA' , 1 ) ;
522: END IF;
523:
524: oe_ota_util.Notify_OTA(
525: p_line_id => p_line_rec.line_id,

Line 532: oe_debug_pub.add( 'JPN: AFTER CALLING NOTIFY_OTA' , 1 ) ;

528: p_daemon_type => 'C',
529: x_return_status => l_return_status);
530:
531: IF l_debug_level > 0 THEN
532: oe_debug_pub.add( 'JPN: AFTER CALLING NOTIFY_OTA' , 1 ) ;
533: END IF;
534:
535: if l_return_status <> FND_API.G_RET_STS_SUCCESS then
536: if l_return_status = FND_API.G_RET_STS_ERROR then

Line 545: oe_debug_pub.add( 'JPN: NOT A OTA LINE' , 1 ) ;

541: end if;
542: end if;
543:
544: IF l_debug_level > 0 THEN
545: oe_debug_pub.add( 'JPN: NOT A OTA LINE' , 1 ) ;
546: END IF;
547: end if;
548:
549: -- Call to Remove from fullfillment sets

Line 560: oe_debug_pub.add( 'BEFORE CALLING OE_LINE_FULLFILL.CANCEL_LINE ( ) ' ) ;

556: -- added the following IF condition to fix bug 2230777
557: -- using OE_OE_FORM_CANCEL_LINE.g_ord_lvl_can for bug# 2922468
558: if NOT(OE_OE_FORM_CANCEL_LINE.g_ord_lvl_can) and NOT(g_par_ord_lvl_can)then
559: IF l_debug_level > 0 THEN
560: oe_debug_pub.add( 'BEFORE CALLING OE_LINE_FULLFILL.CANCEL_LINE ( ) ' ) ;
561: END IF;
562:
563: oe_line_fullfill.cancel_line(p_line_id => p_line_rec.line_id,
564: x_return_status => l_return_status);

Line 590: OE_DEBUG_PUB.ADD('Calling Wf Handle Error ');

586: If p_line_rec.ordered_quantity = 0 then
587: wf_engine.abortprocess(OE_Globals.G_WFI_LIN
588: ,to_char(p_line_rec.line_id)
589: ,l_line_process_name);
590: OE_DEBUG_PUB.ADD('Calling Wf Handle Error ');
591: Using Retry option to run close activity
592: OE_GLOBALS.G_RECURSION_MODE := 'Y';
593: wf_engine.handleerror(OE_Globals.G_WFI_LIN
594: ,to_char(p_line_rec.line_id)

Line 597: OE_DEBUG_PUB.ADD('After Calling Wf Handle Error ');

593: wf_engine.handleerror(OE_Globals.G_WFI_LIN
594: ,to_char(p_line_rec.line_id)
595: ,'CLOSE_LINE',
596: 'RETRY','CANCEL');
597: OE_DEBUG_PUB.ADD('After Calling Wf Handle Error ');
598: NULL;
599: OE_GLOBALS.G_RECURSION_MODE := 'N';
600: end if;
601: */

Line 611: oe_debug_pub.add( 'BEFORE CALLING RELEASE HOLDS' ) ;

607: l_order_tbl(1).line_id := p_line_rec.line_id;
608: l_release_reason_code := 'OM_CANCEL';
609:
610: IF l_debug_level > 0 THEN
611: oe_debug_pub.add( 'BEFORE CALLING RELEASE HOLDS' ) ;
612: END IF;
613:
614: OE_Holds_pub.release_holds(
615: p_order_tbl => l_order_tbl,

Line 624: oe_debug_pub.add( 'AFTER CALLING RELEASE HOLDS :' || L_RETURN_STATUS ) ;

620: x_msg_count => l_msg_count,
621: x_msg_data => l_msg_data);
622:
623: IF l_debug_level > 0 THEN
624: oe_debug_pub.add( 'AFTER CALLING RELEASE HOLDS :' || L_RETURN_STATUS ) ;
625: END IF;
626:
627: if l_return_status <> FND_API.G_RET_STS_SUCCESS then
628: if l_return_status = FND_API.G_RET_STS_ERROR then

Line 656: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.PERFORM_LINE_CHANGE' ) ;

652:
653: End if;
654:
655: IF l_debug_level > 0 THEN
656: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.PERFORM_LINE_CHANGE' ) ;
657: END IF;
658:
659: EXCEPTION
660: WHEN FND_API.G_EXC_ERROR THEN

Line 671: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || 'PERFORM_LINE_CHANGE' ) ;

667: END IF;
668: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
669: WHEN OTHERS THEN
670: IF l_debug_level > 0 THEN
671: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || 'PERFORM_LINE_CHANGE' ) ;
672: END IF;
673: IF oe_msg_pub.Check_MSg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
674: oe_msg_pub.Add_Exc_Msg
675: (G_PKG_NAME

Line 717: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

713: l_api_name VARCHAR2(30):= 'Check_Constraints';
714:
715: l_item_rec OE_ORDER_CACHE.item_rec_type; -- INVCONV
716: --
717: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
718: --
719: BEGIN
720: -- x_line_Rec := p_line_Rec;
721: IF (p_x_line_rec.operation <> oe_globals.g_opr_create AND

Line 726: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.CHECK_CONSTRAINTS' ) ;

722: nvl(p_x_line_rec.split_action_code,'X') <> 'SPLIT') THEN
723: -- OE_SALES_CAN_UTIL.G_REQUIRE_REASON := FALSE;
724:
725: IF l_debug_level > 0 THEN
726: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.CHECK_CONSTRAINTS' ) ;
727: END IF;
728: -- initialize API return status to success
729: l_return_status := FND_API.G_RET_STS_SUCCESS;
730:

Line 732: oe_debug_pub.add( 'CHECKING CONSTRAINTS FOR LINE ID '|| TO_CHAR ( P_X_LINE_REC.LINE_ID ) ) ;

728: -- initialize API return status to success
729: l_return_status := FND_API.G_RET_STS_SUCCESS;
730:
731: IF l_debug_level > 0 THEN
732: oe_debug_pub.add( 'CHECKING CONSTRAINTS FOR LINE ID '|| TO_CHAR ( P_X_LINE_REC.LINE_ID ) ) ;
733: END IF;
734:
735: if ( p_old_line_rec.cancelled_flag = 'Y') then
736: fnd_message.set_name('ONT', 'OE_CANCEL_NOTHING');

Line 801: oe_debug_pub.add( 'IN CHANGE REASON REQUIRED' ) ;

797: IF OE_SALES_CAN_UTIL.G_REQUIRE_REASON THEN
798:
799:
800: IF l_debug_level > 0 THEN
801: oe_debug_pub.add( 'IN CHANGE REASON REQUIRED' ) ;
802: END IF;
803:
804: IF p_x_line_rec.change_reason IS NULL THEN
805: /*fnd_message.set_name('ONT','OE_CAN_REASON_NOT');

Line 816: oe_debug_pub.add(' Get dual uom - tracking in P and S ');

812: IF oe_line_util.dual_uom_control -- INVCONV Process_Characteristics
813: (p_x_line_rec.inventory_item_id,p_X_line_rec.ship_from_org_id,l_item_rec) THEN
814: IF l_item_rec.tracking_quantity_ind = 'PS' THEN -- INVCONV
815: if l_debug_level > 0 then
816: oe_debug_pub.add(' Get dual uom - tracking in P and S ');
817: end if;
818:
819:
820: IF l_debug_level > 0 THEN

Line 821: oe_debug_pub.add( 'BEFORE CALLING CAL_CANCELLED_QTY2' ) ;

817: end if;
818:
819:
820: IF l_debug_level > 0 THEN
821: oe_debug_pub.add( 'BEFORE CALLING CAL_CANCELLED_QTY2' ) ;
822: END IF;
823:
824: p_x_line_rec.cancelled_quantity2 :=oe_sales_can_util.Cal_cancelled_qty2(
825: p_x_line_rec,

Line 829: oe_debug_pub.add( 'CANCELLED QUANTITY2 IS '||P_X_LINE_REC.CANCELLED_QUANTITY2 ) ;

825: p_x_line_rec,
826: p_old_line_rec);
827:
828: IF l_debug_level > 0 THEN
829: oe_debug_pub.add( 'CANCELLED QUANTITY2 IS '||P_X_LINE_REC.CANCELLED_QUANTITY2 ) ;
830: END IF;
831:
832: END IF; -- IF l_item_rec.tracking_quantity_ind = 'PS'
833:

Line 844: oe_debug_pub.add( 'IN CHANGE REASON REQUIRED' ) ;

840: IF OE_SALES_CAN_UTIL.G_REQUIRE_REASON THEN
841:
842:
843: IF l_debug_level > 0 THEN
844: oe_debug_pub.add( 'IN CHANGE REASON REQUIRED' ) ;
845: END IF;
846:
847: IF p_x_line_rec.change_reason IS NULL THEN
848: fnd_message.set_name('ONT','OE_CAN_REASON_NOT');

Line 857: oe_debug_pub.add( 'BEFORE CALLING CAL_CANCELLED_QTY' ) ;

853: -- Bug 7679175 End
854:
855:
856: IF l_debug_level > 0 THEN
857: oe_debug_pub.add( 'BEFORE CALLING CAL_CANCELLED_QTY' ) ;
858: END IF;
859:
860: p_x_line_rec.cancelled_quantity :=oe_sales_can_util.Cal_cancelled_qty(
861: p_x_line_rec,

Line 865: oe_debug_pub.add( 'CANCELLED QUANTITY IS '||P_X_LINE_REC.CANCELLED_QUANTITY ) ;

861: p_x_line_rec,
862: p_old_line_rec);
863:
864: IF l_debug_level > 0 THEN
865: oe_debug_pub.add( 'CANCELLED QUANTITY IS '||P_X_LINE_REC.CANCELLED_QUANTITY ) ;
866: END IF;
867:
868:
869:

Line 905: oe_debug_pub.add( 'CHECKING ORIGINAL CANCELLED_QUANTITY' ) ;

901:
902: -- bug 3542477, must calculate cancelled quantity in case user
903: -- reverts their selection
904: IF l_debug_level > 0 THEN
905: oe_debug_pub.add( 'CHECKING ORIGINAL CANCELLED_QUANTITY' ) ;
906: END IF;
907:
908: p_x_line_rec.cancelled_quantity :=oe_sales_can_util.Cal_cancelled_qty(
909: p_x_line_rec,

Line 918: oe_debug_pub.add(' Get dual uom - tracking in P and S ');

914: IF oe_line_util.dual_uom_control -- INVCONV Process_Characteristics
915: (p_x_line_rec.inventory_item_id,p_X_line_rec.ship_from_org_id,l_item_rec) THEN
916: IF l_item_rec.tracking_quantity_ind = 'PS' THEN -- INVCONV
917: if l_debug_level > 0 then
918: oe_debug_pub.add(' Get dual uom - tracking in P and S ');
919: end if;
920:
921:
922: IF l_debug_level > 0 THEN

Line 923: oe_debug_pub.add( 'BEFORE CALLING CAL_CANCELLED_QTY2' ) ;

919: end if;
920:
921:
922: IF l_debug_level > 0 THEN
923: oe_debug_pub.add( 'BEFORE CALLING CAL_CANCELLED_QTY2' ) ;
924: END IF;
925:
926: p_x_line_rec.cancelled_quantity2 :=oe_sales_can_util.Cal_cancelled_qty2(
927: p_x_line_rec,

Line 931: oe_debug_pub.add( 'CANCELLED QUANTITY2 IS '||P_X_LINE_REC.CANCELLED_QUANTITY2 ) ;

927: p_x_line_rec,
928: p_old_line_rec);
929:
930: IF l_debug_level > 0 THEN
931: oe_debug_pub.add( 'CANCELLED QUANTITY2 IS '||P_X_LINE_REC.CANCELLED_QUANTITY2 ) ;
932: END IF;
933:
934: END IF; -- IF l_item_rec.tracking_quantity_ind = 'PS'
935:

Line 945: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.CHECK_CONSTRAINTS' ) ;

941:
942: END IF;
943:
944: IF l_debug_level > 0 THEN
945: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.CHECK_CONSTRAINTS' ) ;
946: END IF;
947:
948: END IF;
949:

Line 962: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;

958: END IF;
959: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
960: WHEN OTHERS THEN
961: IF l_debug_level > 0 THEN
962: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;
963: END IF;
964: IF oe_msg_pub.Check_MSg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
965: oe_msg_pub.Add_Exc_Msg
966: (G_PKG_NAME

Line 1000: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

996: AND service_reference_type_code = 'ORDER' -- these two conditions added for bug 2946327
997: AND nvl(cancelled_flag, 'N') <> 'Y';
998:
999: --
1000: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1001: --
1002: BEGIN
1003:
1004: IF l_debug_level > 0 THEN

Line 1005: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.UPDATE_SERVICE' ) ;

1001: --
1002: BEGIN
1003:
1004: IF l_debug_level > 0 THEN
1005: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.UPDATE_SERVICE' ) ;
1006: END IF;
1007:
1008: for Serrec in get_service loop
1009: l_line_id := serrec.line_id;

Line 1018: oe_debug_pub.add( 'BEFORE CALLING UPDATELINE FOR LINE ID: '|| L_LINE_ID ) ;

1014: l_change_reason := p_line_rec.change_reason;
1015: l_change_comments := p_line_rec.change_comments;
1016:
1017: IF l_debug_level > 0 THEN
1018: oe_debug_pub.add( 'BEFORE CALLING UPDATELINE FOR LINE ID: '|| L_LINE_ID ) ;
1019: END IF;
1020:
1021: /* Call the UpdateLine only if ordered_quantity is greater than zero */
1022: IF( l_service_quantity <> 0 )then

Line 1033: oe_debug_pub.add( 'AFTER CALLING UPDATELINE , RETURN STATUS: '|| L_RETURN_STATUS ) ;

1029: x_msg_data);
1030: END IF;
1031:
1032: IF l_debug_level > 0 THEN
1033: oe_debug_pub.add( 'AFTER CALLING UPDATELINE , RETURN STATUS: '|| L_RETURN_STATUS ) ;
1034: END IF;
1035:
1036: end loop;
1037:

Line 1047: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.UPDATE_SERVICE' ) ;

1043: end if;
1044: end if;
1045:
1046: IF l_debug_level > 0 THEN
1047: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.UPDATE_SERVICE' ) ;
1048: END IF;
1049:
1050: EXCEPTION
1051: WHEN FND_API.G_EXC_ERROR THEN

Line 1062: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;

1058: END IF;
1059: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1060: WHEN OTHERS THEN
1061: IF l_debug_level > 0 THEN
1062: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;
1063: END IF;
1064: IF oe_msg_pub.Check_MSg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
1065: oe_msg_pub.Add_Exc_Msg
1066: (G_PKG_NAME

Line 1083: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

1079: l_old_ord_quantity number;
1080: l_old_can_quantity number;
1081: l_new_can_quantity number;
1082: --
1083: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1084: --
1085: begin
1086: IF NOT OE_GLOBALS.Equal(p_line_rec.ordered_quantity,p_old_line_rec.ordered_quantity)
1087: THEN

Line 1099: oe_debug_pub.add( 'NEW ORDERED QUANTITY IS: '||P_LINE_REC.ORDERED_QUANTITY ) ;

1095: from oe_order_lines
1096: where line_id = p_line_rec.line_id;
1097:
1098: IF l_debug_level > 0 THEN
1099: oe_debug_pub.add( 'NEW ORDERED QUANTITY IS: '||P_LINE_REC.ORDERED_QUANTITY ) ;
1100: END IF;
1101: IF l_debug_level > 0 THEN
1102: oe_debug_pub.add( 'OLD ORDERED QUANTITY IS: '||L_OLD_ORD_QUANTITY ) ;
1103: END IF;

Line 1102: oe_debug_pub.add( 'OLD ORDERED QUANTITY IS: '||L_OLD_ORD_QUANTITY ) ;

1098: IF l_debug_level > 0 THEN
1099: oe_debug_pub.add( 'NEW ORDERED QUANTITY IS: '||P_LINE_REC.ORDERED_QUANTITY ) ;
1100: END IF;
1101: IF l_debug_level > 0 THEN
1102: oe_debug_pub.add( 'OLD ORDERED QUANTITY IS: '||L_OLD_ORD_QUANTITY ) ;
1103: END IF;
1104: IF l_debug_level > 0 THEN
1105: oe_debug_pub.add( 'OLD CANCELLED QUANTITY IS: '||L_OLD_CAN_QUANTITY ) ;
1106: END IF;

Line 1105: oe_debug_pub.add( 'OLD CANCELLED QUANTITY IS: '||L_OLD_CAN_QUANTITY ) ;

1101: IF l_debug_level > 0 THEN
1102: oe_debug_pub.add( 'OLD ORDERED QUANTITY IS: '||L_OLD_ORD_QUANTITY ) ;
1103: END IF;
1104: IF l_debug_level > 0 THEN
1105: oe_debug_pub.add( 'OLD CANCELLED QUANTITY IS: '||L_OLD_CAN_QUANTITY ) ;
1106: END IF;
1107:
1108: IF (l_old_ord_quantity > p_line_rec.ordered_quantity)
1109: and nvl(oe_globals.g_pricing_recursion, 'N') = 'N' THEN

Line 1128: oe_debug_pub.add( 'NEW CANCELLED QUANTITY IS: '||L_NEW_CAN_QUANTITY ) ;

1124: END IF;
1125: -- End : 12695580
1126:
1127: IF l_debug_level > 0 THEN
1128: oe_debug_pub.add( 'NEW CANCELLED QUANTITY IS: '||L_NEW_CAN_QUANTITY ) ;
1129: END IF;
1130:
1131: RETURN l_new_can_quantity;
1132:

Line 1147: oe_debug_pub.add('Line Ord Qty already 0, Returning 0 as Cancelled Qty');

1143:
1144: RETURN 0;
1145:
1146: IF l_debug_level > 0 THEN
1147: oe_debug_pub.add('Line Ord Qty already 0, Returning 0 as Cancelled Qty');
1148: END IF;
1149: END IF;
1150:
1151: /* Following commented code has been replaced as fix for bug # 2136529

Line 1159: oe_debug_pub.ADD('rajeevcancell');

1155: (p_old_line_rec.ordered_quantity - p_line_rec.ordered_quantity);
1156:
1157: IF p_old_line_rec.cancelled_quantity = FND_API.G_MISS_NUM OR
1158: p_old_line_rec.cancelled_quantity is NULL THEN
1159: oe_debug_pub.ADD('rajeevcancell');
1160: RETURN l_ordered_quantity;
1161: ELSE
1162: oe_debug_pub.ADD('rajeevcancel2');
1163: RETURN (l_ordered_quantity +

Line 1162: oe_debug_pub.ADD('rajeevcancel2');

1158: p_old_line_rec.cancelled_quantity is NULL THEN
1159: oe_debug_pub.ADD('rajeevcancell');
1160: RETURN l_ordered_quantity;
1161: ELSE
1162: oe_debug_pub.ADD('rajeevcancel2');
1163: RETURN (l_ordered_quantity +
1164: p_old_line_rec.cancelled_quantity) ;
1165: END IF;
1166: ELSE

Line 1167: oe_debug_pub.ADD('rajeevcancel3');

1163: RETURN (l_ordered_quantity +
1164: p_old_line_rec.cancelled_quantity) ;
1165: END IF;
1166: ELSE
1167: oe_debug_pub.ADD('rajeevcancel3');
1168: RETURN p_line_rec.cancelled_quantity;
1169: END IF;
1170: END IF;
1171: ELSE

Line 1186: oe_debug_pub.ADD('rajeevcancelsecond');

1182: END IF;
1183: ELSE
1184: RETURN p_line_rec.cancelled_quantity;
1185: END IF;
1186: oe_debug_pub.ADD('rajeevcancelsecond');
1187:
1188: END IF;
1189: END IF;
1190: RETURN p_line_rec.cancelled_quantity;

Line 1195: oe_debug_pub.add('New ordered_quantity and Old ordered_quantity are equal ');

1191: */
1192:
1193: --Bug# 4009268
1194: IF OE_GLOBALS.Equal(p_line_rec.ordered_quantity,p_old_line_rec.ordered_quantity) THEN
1195: oe_debug_pub.add('New ordered_quantity and Old ordered_quantity are equal ');
1196: RETURN nvl(p_line_rec.cancelled_quantity,0);
1197: END IF;
1198:
1199: IF l_debug_level > 0 THEN

Line 1200: oe_debug_pub.add('Cal_Cancelled_qty - Returning 0 as Cancelled Qty at end ');

1196: RETURN nvl(p_line_rec.cancelled_quantity,0);
1197: END IF;
1198:
1199: IF l_debug_level > 0 THEN
1200: oe_debug_pub.add('Cal_Cancelled_qty - Returning 0 as Cancelled Qty at end ');
1201: END IF;
1202:
1203: return 0; -- INVCONV
1204:

Line 1228: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

1224: x_msg_data varchar2(255);
1225: l_on_operation_action varchar2(255);
1226: l_resp_id number := nvl(fnd_global.resp_id,-1);
1227: --
1228: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1229: --
1230: BEGIN
1231: IF l_debug_level > 0 THEN
1232: oe_debug_pub.add( 'IN CHECK CONSTRAINS FOR CANCELLATION' ) ;

Line 1232: oe_debug_pub.add( 'IN CHECK CONSTRAINS FOR CANCELLATION' ) ;

1228: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1229: --
1230: BEGIN
1231: IF l_debug_level > 0 THEN
1232: oe_debug_pub.add( 'IN CHECK CONSTRAINS FOR CANCELLATION' ) ;
1233: END IF;
1234: -- initialize API return status to success
1235: x_return_status := FND_API.G_RET_STS_SUCCESS;
1236: -- Prepare security record

Line 1250: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;

1246: END IF;
1247: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1248: WHEN OTHERS THEN
1249: IF l_debug_level > 0 THEN
1250: oe_debug_pub.add( 'UNEXPECTED ERROR IN ' || G_PKG_NAME || ':' || L_API_NAME ) ;
1251: END IF;
1252: IF oe_msg_pub.Check_MSg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
1253: oe_msg_pub.Add_Exc_Msg
1254: (G_PKG_NAME

Line 1289: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

1285: i NUMBER := 0;
1286: l_prg_line_count NUMBER;
1287:
1288: --
1289: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1290: --
1291: Begin
1292:
1293: IF l_debug_level > 0 THEN

Line 1294: OE_DEBUG_PUB.ADD('Entering oe_sales_can_util.perform_cancel_order',5);

1290: --
1291: Begin
1292:
1293: IF l_debug_level > 0 THEN
1294: OE_DEBUG_PUB.ADD('Entering oe_sales_can_util.perform_cancel_order',5);
1295: OE_DEBUG_PUB.ADD('perform cancel order header id : '||p_header_rec.header_id,5);
1296: OE_DEBUG_PUB.add('Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
1297: OE_DEBUG_PUB.add('Reason provided is : '||p_header_rec.change_reason,1);
1298: END IF;

Line 1295: OE_DEBUG_PUB.ADD('perform cancel order header id : '||p_header_rec.header_id,5);

1291: Begin
1292:
1293: IF l_debug_level > 0 THEN
1294: OE_DEBUG_PUB.ADD('Entering oe_sales_can_util.perform_cancel_order',5);
1295: OE_DEBUG_PUB.ADD('perform cancel order header id : '||p_header_rec.header_id,5);
1296: OE_DEBUG_PUB.add('Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
1297: OE_DEBUG_PUB.add('Reason provided is : '||p_header_rec.change_reason,1);
1298: END IF;
1299:

Line 1296: OE_DEBUG_PUB.add('Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);

1292:
1293: IF l_debug_level > 0 THEN
1294: OE_DEBUG_PUB.ADD('Entering oe_sales_can_util.perform_cancel_order',5);
1295: OE_DEBUG_PUB.ADD('perform cancel order header id : '||p_header_rec.header_id,5);
1296: OE_DEBUG_PUB.add('Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
1297: OE_DEBUG_PUB.add('Reason provided is : '||p_header_rec.change_reason,1);
1298: END IF;
1299:
1300: --g_ord_lvl_can := TRUE; Commented for bug# 2922468

Line 1297: OE_DEBUG_PUB.add('Reason provided is : '||p_header_rec.change_reason,1);

1293: IF l_debug_level > 0 THEN
1294: OE_DEBUG_PUB.ADD('Entering oe_sales_can_util.perform_cancel_order',5);
1295: OE_DEBUG_PUB.ADD('perform cancel order header id : '||p_header_rec.header_id,5);
1296: OE_DEBUG_PUB.add('Reason Required Flag : '||OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG,1);
1297: OE_DEBUG_PUB.add('Reason provided is : '||p_header_rec.change_reason,1);
1298: END IF;
1299:
1300: --g_ord_lvl_can := TRUE; Commented for bug# 2922468
1301:

Line 1304: oe_debug_pub.add( 'CHANGE REASON IS REQUIRED' ) ;

1300: --g_ord_lvl_can := TRUE; Commented for bug# 2922468
1301:
1302: IF (oe_sales_can_util.G_REQUIRE_REASON AND OE_GLOBALS.G_AUDIT_REASON_RQD_FLAG <> 'N') THEN
1303: IF l_debug_level > 0 THEN
1304: oe_debug_pub.add( 'CHANGE REASON IS REQUIRED' ) ;
1305: END IF;
1306: IF p_header_rec.change_reason IS NULL THEN
1307: fnd_message.set_name('ONT','OE_CAN_REASON_NOT');
1308: oe_msg_pub.add;

Line 1333: oe_debug_pub.add( 'LINE SELECTED FOR CANCELLATION , ID: '|| L_LINE_OLD_TBL ( J ) .LINE_ID , 1 ) ;

1329: IF nvl(l_line_old_tbl(j).top_model_line_id, l_line_old_tbl(j).line_id) = l_line_old_tbl(j).line_id OR
1330: nvl(l_line_old_tbl(j).model_remnant_flag, 'N') = 'Y' THEN
1331:
1332: IF l_debug_level > 0 THEN
1333: oe_debug_pub.add( 'LINE SELECTED FOR CANCELLATION , ID: '|| L_LINE_OLD_TBL ( J ) .LINE_ID , 1 ) ;
1334: END IF;
1335:
1336: /* Fix for bug # 2126033 */
1337: IF l_line_old_tbl(j).item_type_code = OE_Globals.G_ITEM_SERVICE AND

Line 1355: oe_debug_pub.add( 'SKIP , PARENT OF THIS SERVICE LINE EXISTS IN THE SAME ORDER' ) ;

1351: end;
1352:
1353: IF l_service_parent_exists = 'Y' THEN
1354: IF l_debug_level > 0 THEN
1355: oe_debug_pub.add( 'SKIP , PARENT OF THIS SERVICE LINE EXISTS IN THE SAME ORDER' ) ;
1356: END IF;
1357: goto end_loop;
1358: END IF;
1359: END IF;

Line 1376: oe_debug_pub.add( 'SKIP , THIS IS A PROMOTIONAL LINE' ) ;

1372: end;
1373:
1374: IF l_prg_line_count > 0 THEN
1375: IF l_debug_level > 0 THEN
1376: oe_debug_pub.add( 'SKIP , THIS IS A PROMOTIONAL LINE' ) ;
1377: END IF;
1378: goto end_loop;
1379: END IF;
1380:

Line 1382: oe_debug_pub.add( 'ADDING FOR CANCELLATION , LINE ID: '||L_LINE_OLD_TBL ( J ) .LINE_ID ) ;

1378: goto end_loop;
1379: END IF;
1380:
1381: IF l_debug_level > 0 THEN
1382: oe_debug_pub.add( 'ADDING FOR CANCELLATION , LINE ID: '||L_LINE_OLD_TBL ( J ) .LINE_ID ) ;
1383: END IF;
1384:
1385: i := i + 1;
1386:

Line 1400: oe_debug_pub.add( 'SKIPPING LINE ID: '||L_LINE_OLD_TBL ( J ) .LINE_ID||'-'|| L_LINE_OLD_TBL ( J ) .ITEM_TYPE_CODE ) ;

1396: l_line_tbl(i).flow_status_code := 'CANCELLED';
1397: l_line_tbl(i).open_flag := 'N'; */
1398: ELSE
1399: IF l_debug_level > 0 THEN
1400: oe_debug_pub.add( 'SKIPPING LINE ID: '||L_LINE_OLD_TBL ( J ) .LINE_ID||'-'|| L_LINE_OLD_TBL ( J ) .ITEM_TYPE_CODE ) ;
1401: END IF;
1402: END IF;
1403: ELSE
1404: IF l_debug_level > 0 THEN

Line 1405: oe_debug_pub.add( 'SKIPPING CANCELLED LINE ID: '||L_LINE_OLD_TBL ( J ) .LINE_ID||'-'|| L_LINE_OLD_TBL ( J ) .ITEM_TYPE_CODE ) ;

1401: END IF;
1402: END IF;
1403: ELSE
1404: IF l_debug_level > 0 THEN
1405: oe_debug_pub.add( 'SKIPPING CANCELLED LINE ID: '||L_LINE_OLD_TBL ( J ) .LINE_ID||'-'|| L_LINE_OLD_TBL ( J ) .ITEM_TYPE_CODE ) ;
1406: END IF;
1407: END IF; -- line not cancelled?
1408: <>
1409: null;

Line 1425: oe_debug_pub.add( 'UPDATE LINE PROCESS ORDER RETURN UNEXP_ERROR' ) ;

1421: END IF;
1422:
1423: IF l_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
1424: IF l_debug_level > 0 THEN
1425: oe_debug_pub.add( 'UPDATE LINE PROCESS ORDER RETURN UNEXP_ERROR' ) ;
1426: END IF;
1427: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1428: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
1429: IF l_debug_level > 0 THEN

Line 1430: oe_debug_pub.add( 'UPDATE LINE PROCESS ORDER RETURN RET_STS_ERROR' ) ;

1426: END IF;
1427: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1428: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
1429: IF l_debug_level > 0 THEN
1430: oe_debug_pub.add( 'UPDATE LINE PROCESS ORDER RETURN RET_STS_ERROR' ) ;
1431: END IF;
1432: RAISE FND_API.G_EXC_ERROR;
1433: END IF;
1434:

Line 1439: oe_debug_pub.ADD('Calling Payment Refund for multiple payments.');

1435:
1436: -- Need to process payment refund if there is any prepayment.
1437: IF OE_PREPAYMENT_UTIL.IS_MULTIPLE_PAYMENTS_ENABLED THEN
1438: IF l_debug_level > 0 THEN
1439: oe_debug_pub.ADD('Calling Payment Refund for multiple payments.');
1440: END IF;
1441:
1442: OE_Prepayment_PVT.Process_Payment_Refund
1443: ( p_header_rec => p_header_rec

Line 1449: oe_debug_pub.add('return status after calling process_payment_refund is: '||x_return_status, 3);

1445: , x_msg_data => l_msg_data
1446: , x_return_status => x_return_status
1447: );
1448: IF l_debug_level > 0 THEN
1449: oe_debug_pub.add('return status after calling process_payment_refund is: '||x_return_status, 3);
1450: END IF;
1451:
1452: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
1453: RAISE FND_API.G_EXC_ERROR;

Line 1460: oe_debug_pub.ADD('Calling Payment Refund.');

1456: END IF;
1457: ELSIF NVL(p_header_rec.payment_type_code,'NULL') = 'CREDIT_CARD'
1458: AND OE_PrePayment_UTIL.is_prepaid_order(p_header_rec) = 'Y'
1459: THEN
1460: oe_debug_pub.ADD('Calling Payment Refund.');
1461: OE_PrePayment_PVT.Process_PrePayment_Order
1462: ( p_header_rec => p_header_rec
1463: , p_calling_action => NULL
1464: , p_delayed_request => FND_API.G_FALSE

Line 1470: oe_debug_pub.add('return status after calling process_prepayment_order is: '||x_return_status, 3);

1466: , x_msg_data => l_msg_data
1467: , x_return_status => x_return_status
1468: );
1469: IF l_debug_level > 0 THEN
1470: oe_debug_pub.add('return status after calling process_prepayment_order is: '||x_return_status, 3);
1471: END IF;
1472:
1473: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
1474: RAISE FND_API.G_EXC_ERROR;

Line 1483: oe_debug_pub.add( 'CALLING RELEASE HOLD API RELEASE HOLD' ) ;

1479:
1480: -- Release Holds
1481:
1482: IF l_debug_level > 0 THEN
1483: oe_debug_pub.add( 'CALLING RELEASE HOLD API RELEASE HOLD' ) ;
1484: END IF;
1485:
1486: l_order_tbl(1).header_id := p_header_rec.header_id;
1487: l_release_reason_code := 'OM_CANCEL';

Line 1500: oe_debug_pub.add( 'THE HOLD RELEASED WITH STATUS :'|| L_RETURN_STATUS ) ;

1496: x_msg_data => l_msg_data
1497: );
1498:
1499: IF l_debug_level > 0 THEN
1500: oe_debug_pub.add( 'THE HOLD RELEASED WITH STATUS :'|| L_RETURN_STATUS ) ;
1501: END IF;
1502:
1503: if l_return_status <> FND_API.G_RET_STS_SUCCESS then
1504: if l_return_status = FND_API.G_RET_STS_ERROR then

Line 1520: oe_debug_pub.ADD('Before calling Payment Request');

1516: -- If Order has Credit Card approval, then Void the Authorization
1517: IF p_header_rec.credit_card_approval_code is NOT NULL THEN
1518:
1519: -- Call Payment Request to Void any existing Authorizations
1520: oe_debug_pub.ADD('Before calling Payment Request');
1521:
1522: OE_Verify_Payment_PUB.Payment_Request
1523: ( p_header_rec => p_header_rec
1524: , p_trxn_type => 'VOIDAUTHONLY'

Line 1555: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.PERFORM_CANCEL_ORDER' ) ;

1551:
1552: --g_ord_lvl_can := FALSE; Commented for bug# 2922468
1553:
1554: IF l_debug_level > 0 THEN
1555: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.PERFORM_CANCEL_ORDER' ) ;
1556: END IF;
1557:
1558: EXCEPTION
1559: WHEN FND_API.G_EXC_ERROR THEN

Line 1590: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

1586: x_msg_count NUMBER;
1587: x_msg_data VARCHAR2(30);
1588:
1589: --
1590: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1591: --
1592: BEGIN
1593:
1594: IF l_debug_level > 0 THEN

Line 1595: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.PERFORMLINECANCELLATION' ) ;

1591: --
1592: BEGIN
1593:
1594: IF l_debug_level > 0 THEN
1595: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.PERFORMLINECANCELLATION' ) ;
1596: END IF;
1597:
1598: l_control_rec.controlled_operation := TRUE;
1599: l_control_rec.change_attributes := TRUE;

Line 1616: oe_debug_pub.add( 'BEFORE CALLING PROCESS ORDER' ) ;

1612: l_line_tbl := p_line_tbl;
1613: l_old_line_tbl := p_line_old_tbl;
1614:
1615: IF l_debug_level > 0 THEN
1616: oe_debug_pub.add( 'BEFORE CALLING PROCESS ORDER' ) ;
1617: END IF;
1618:
1619: oe_order_pvt.Lines
1620: ( p_validation_level => FND_API.G_VALID_LEVEL_NONE

Line 1628: oe_debug_pub.add( 'AFTER CALLING PROCESS ORDER' ) ;

1624: , x_return_status => x_return_status
1625: );
1626:
1627: IF l_debug_level > 0 THEN
1628: oe_debug_pub.add( 'AFTER CALLING PROCESS ORDER' ) ;
1629: END IF;
1630:
1631: IF x_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
1632: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 1657: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.PERFORMLINECANCELLATION' ) ;

1653: end loop;
1654: END IF; -- 2653505
1655:
1656: IF l_debug_level > 0 THEN
1657: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.PERFORMLINECANCELLATION' ) ;
1658: END IF;
1659:
1660: EXCEPTION
1661: WHEN FND_API.G_EXC_ERROR THEN

Line 1686: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

1682: l_line_rec OE_Order_PUB.Line_Rec_Type;
1683: l_line_tbl OE_Order_PUB.Line_Tbl_Type;
1684:
1685: --
1686: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1687: --
1688: BEGIN
1689:
1690: IF l_debug_level > 0 THEN

Line 1691: oe_debug_pub.add( 'ENTERING OE_LINE_UTIL.QUERY_ROWS' , 1 ) ;

1687: --
1688: BEGIN
1689:
1690: IF l_debug_level > 0 THEN
1691: oe_debug_pub.add( 'ENTERING OE_LINE_UTIL.QUERY_ROWS' , 1 ) ;
1692: END IF;
1693:
1694:
1695: -- Return fetched table

Line 1697: oe_debug_pub.add( 'EXITING OE_LINE_UTIL.QUERY_ROWS' , 1 ) ;

1693:
1694:
1695: -- Return fetched table
1696: IF l_debug_level > 0 THEN
1697: oe_debug_pub.add( 'EXITING OE_LINE_UTIL.QUERY_ROWS' , 1 ) ;
1698: END IF;
1699:
1700: RETURN l_line_tbl;
1701:

Line 1731: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

1727: -- then those sets should be processed for fulfillment logic.
1728:
1729: PROCEDURE Call_Process_Fulfillment(p_header_id IN NUMBER)
1730: IS
1731: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1732: l_result_out VARCHAR2(240);
1733: l_return_status VARCHAR2(30);
1734: l_activity_result VARCHAR2(30) := 'NO_RESULT';
1735: l_activity_status VARCHAR2(8);

Line 1759: oe_debug_pub.add('Entering Oe_sales_can_util.Call_Process_Fulfillment API',2);

1755: and ol.open_flag = 'Y';
1756:
1757: BEGIN
1758: IF l_debug_level > 0 THEN
1759: oe_debug_pub.add('Entering Oe_sales_can_util.Call_Process_Fulfillment API',2);
1760: END IF;
1761:
1762: SAVEPOINT Process_Set;
1763:

Line 1777: oe_debug_pub.add('Fulfillment Set_id='||C_Set.set_id||',No. of lines='||l_lines_in_set,2);

1773: AND ol.cancelled_flag <> 'Y'
1774: AND ol.open_flag = 'Y';
1775:
1776: IF l_debug_level > 0 THEN
1777: oe_debug_pub.add('Fulfillment Set_id='||C_Set.set_id||',No. of lines='||l_lines_in_set,2);
1778: END IF;
1779:
1780: -- Count the lines that are awaiting fulfillment for this set
1781: IF l_lines_in_set > 0 THEN

Line 1796: oe_debug_pub.add('No. of lines in Fulfill:NOTIFIED ='||l_lines_awaiting,2);

1792: AND WIAS.activity_status = 'NOTIFIED'
1793: AND WIAS.Process_Activity = WPA.instance_id;
1794:
1795: IF l_debug_level > 0 THEN
1796: oe_debug_pub.add('No. of lines in Fulfill:NOTIFIED ='||l_lines_awaiting,2);
1797: END IF;
1798:
1799: IF l_lines_awaiting = l_lines_in_set THEN
1800: -- This is to pick up 1 line in the set in Fulfill:Notified

Line 1817: oe_debug_pub.add('All lines in fulfill:notified, hence calling OE_Line_Fullfill.Process_Fulfillment for line_id='||l_line_id||' , p_activity_id='||l_activity_id,2);

1813: AND WIAS.Process_Activity = WPA.instance_id
1814: AND ROWNUM = 1;
1815:
1816: IF l_debug_level > 0 THEN
1817: oe_debug_pub.add('All lines in fulfill:notified, hence calling OE_Line_Fullfill.Process_Fulfillment for line_id='||l_line_id||' , p_activity_id='||l_activity_id,2);
1818: END IF;
1819:
1820: OE_Line_Fullfill.Process_Fulfillment
1821: ( p_api_version_number => 1.0

Line 1831: oe_debug_pub.add('Exception from Process_Fulfillment:'||l_result_out,2);

1827: , x_msg_data => l_msg_data);
1828:
1829: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
1830: IF l_debug_level > 0 THEN
1831: oe_debug_pub.add('Exception from Process_Fulfillment:'||l_result_out,2);
1832: END IF;
1833: OE_MSG_PUB.Add_Text(p_message_text => l_msg_data);
1834: OE_MSG_PUB.Save_API_Messages;
1835:

Line 1851: oe_debug_pub.add('After Get_Activity_Result, ret status:'||l_return_status||' ,Fulfill:'||l_activity_status,3);

1847: ,x_activity_status_code => l_activity_status
1848: ,x_activity_id => l_activity_id );
1849:
1850: IF l_debug_level > 0 THEN
1851: oe_debug_pub.add('After Get_Activity_Result, ret status:'||l_return_status||' ,Fulfill:'||l_activity_status,3);
1852: END IF;
1853:
1854: IF l_return_status = FND_API.G_RET_STS_SUCCESS AND
1855: l_activity_status = 'NOTIFIED' THEN

Line 1857: oe_debug_pub.add('Calling wf_engine.CompleteActivityInternalName for lineID='||l_item_key,2);

1853:
1854: IF l_return_status = FND_API.G_RET_STS_SUCCESS AND
1855: l_activity_status = 'NOTIFIED' THEN
1856: IF l_debug_level > 0 THEN
1857: oe_debug_pub.add('Calling wf_engine.CompleteActivityInternalName for lineID='||l_item_key,2);
1858: END IF;
1859:
1860: Wf_Engine.CompleteActivityInternalName('OEOL', l_item_key, 'FULFILL_LINE', '#NULL',TRUE ); --15870313
1861:

Line 1863: oe_debug_pub.add('After calling wf_engine.CompleteActivityInternalName for lineID='||l_item_key,2);

1859:
1860: Wf_Engine.CompleteActivityInternalName('OEOL', l_item_key, 'FULFILL_LINE', '#NULL',TRUE ); --15870313
1861:
1862: IF l_debug_level > 0 THEN
1863: oe_debug_pub.add('After calling wf_engine.CompleteActivityInternalName for lineID='||l_item_key,2);
1864: END IF;
1865: END IF;
1866: END IF;
1867: END IF; -- l_lines_awaiting = l_lines_in_set check

Line 1875: oe_debug_pub.add('Exiting from Oe_sales_can_util.Call_Process_Fulfillment API',2);

1871: l_lines_in_set := NULL;
1872: END LOOP; -- Non closed fulfillment sets
1873:
1874: IF l_debug_level > 0 THEN
1875: oe_debug_pub.add('Exiting from Oe_sales_can_util.Call_Process_Fulfillment API',2);
1876: END IF;
1877: EXCEPTION
1878: WHEN Others THEN
1879: IF l_debug_level > 0 THEN

Line 1880: oe_debug_pub.add('OTHERS EXCEPTION in Oe_sales_can_util.Call_Process_Fulfillment API',2);

1876: END IF;
1877: EXCEPTION
1878: WHEN Others THEN
1879: IF l_debug_level > 0 THEN
1880: oe_debug_pub.add('OTHERS EXCEPTION in Oe_sales_can_util.Call_Process_Fulfillment API',2);
1881: END IF;
1882: END Call_Process_Fulfillment;
1883:
1884: PROCEDURE Cancel_Remaining_Order

Line 1912: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

1908: l_service_parent_exists VARCHAR2(1) := 'N';
1909: l_prg_line_count NUMBER;
1910:
1911: --
1912: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
1913: --
1914: Begin
1915:
1916: IF l_debug_level > 0 THEN

Line 1917: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.CANCEL_REMAINING_ORDER' ) ;

1913: --
1914: Begin
1915:
1916: IF l_debug_level > 0 THEN
1917: oe_debug_pub.add( 'ENTERING OE_SALES_CAN_UTIL.CANCEL_REMAINING_ORDER' ) ;
1918: END IF;
1919:
1920: x_return_status := FND_API.G_RET_STS_SUCCESS;
1921:

Line 1934: oe_debug_pub.add( 'CANCEL REMAINING ORDER HEADER ID: '||L_HEADER_ID ) ;

1930: l_header_id := p_header_rec.header_id;
1931: END IF;
1932:
1933: IF l_debug_level > 0 THEN
1934: oe_debug_pub.add( 'CANCEL REMAINING ORDER HEADER ID: '||L_HEADER_ID ) ;
1935: END IF;
1936:
1937: oe_line_util.Query_Rows( p_header_id => l_header_id
1938: , x_line_tbl => l_line_old_tbl

Line 1965: oe_debug_pub.add( 'LINE SELECTED FOR CANCELLATION , ID: '|| L_LINE_OLD_TBL ( I ) .LINE_ID , 1 ) ;

1961: IF nvl(l_line_old_tbl(i).top_model_line_id, l_line_old_tbl(i).line_id) = l_line_old_tbl(i).line_id OR
1962: nvl(l_line_old_tbl(i).model_remnant_flag, 'N') = 'Y' THEN
1963:
1964: IF l_debug_level > 0 THEN
1965: oe_debug_pub.add( 'LINE SELECTED FOR CANCELLATION , ID: '|| L_LINE_OLD_TBL ( I ) .LINE_ID , 1 ) ;
1966: END IF;
1967:
1968: /* Fix for bug # 2126033 */
1969: IF l_line_old_tbl(i).item_type_code = OE_Globals.G_ITEM_SERVICE AND

Line 1987: oe_debug_pub.add( 'SKIP , PARENT OF THIS SERVICE LINE EXISTS IN THE SAME ORDER' ) ;

1983: end;
1984:
1985: IF l_service_parent_exists = 'Y' THEN
1986: IF l_debug_level > 0 THEN
1987: oe_debug_pub.add( 'SKIP , PARENT OF THIS SERVICE LINE EXISTS IN THE SAME ORDER' ) ;
1988: END IF;
1989: goto end_loop;
1990: END IF;
1991: END IF;

Line 2013: oe_debug_pub.add( 'SKIP , THIS IS A PROMOTIONAL GOODS LINE' ) ;

2009: end;
2010:
2011: IF l_prg_line_count > 0 THEN
2012: IF l_debug_level > 0 THEN
2013: oe_debug_pub.add( 'SKIP , THIS IS A PROMOTIONAL GOODS LINE' ) ;
2014: END IF;
2015: goto end_loop;
2016: END IF;
2017:

Line 2019: oe_debug_pub.add( 'ADDING FOR CANCELLATION , LINE ID: '|| L_LINE_OLD_TBL ( I ) .LINE_ID ) ;

2015: goto end_loop;
2016: END IF;
2017:
2018: IF l_debug_level > 0 THEN
2019: oe_debug_pub.add( 'ADDING FOR CANCELLATION , LINE ID: '|| L_LINE_OLD_TBL ( I ) .LINE_ID ) ;
2020: END IF;
2021:
2022: J := J + 1;
2023:

Line 2046: oe_debug_pub.add( 'SKIPPING LINE ID: '||L_LINE_OLD_TBL ( I ) .LINE_ID||'-'|| L_LINE_OLD_TBL ( I ) .ITEM_TYPE_CODE ) ;

2042: --l_line_tbl(j).flow_status_code := 'CANCELLED';
2043: --l_line_tbl(j).open_flag := 'N';
2044: ELSE
2045: IF l_debug_level > 0 THEN
2046: oe_debug_pub.add( 'SKIPPING LINE ID: '||L_LINE_OLD_TBL ( I ) .LINE_ID||'-'|| L_LINE_OLD_TBL ( I ) .ITEM_TYPE_CODE ) ;
2047: END IF;
2048: END IF;
2049: ELSE
2050: IF l_debug_level > 0 THEN

Line 2051: oe_debug_pub.add( 'SKIPPING ALREADY SHIPPED OR CLOSED/CANCELLED LINE ID: '||L_LINE_OLD_TBL ( I ) .LINE_ID ) ;

2047: END IF;
2048: END IF;
2049: ELSE
2050: IF l_debug_level > 0 THEN
2051: oe_debug_pub.add( 'SKIPPING ALREADY SHIPPED OR CLOSED/CANCELLED LINE ID: '||L_LINE_OLD_TBL ( I ) .LINE_ID ) ;
2052: END IF;
2053: END If;
2054: <>
2055: null;

Line 2059: oe_debug_pub.add( 'CANCEL REMAINING ORDER - LINE COUNT '|| L_LINE_TBL.COUNT ) ;

2055: null;
2056: End Loop;
2057:
2058: IF l_debug_level > 0 THEN
2059: oe_debug_pub.add( 'CANCEL REMAINING ORDER - LINE COUNT '|| L_LINE_TBL.COUNT ) ;
2060: END IF;
2061:
2062: IF l_line_tbl.count = 0 THEN
2063: FND_MESSAGE.SET_NAME('ONT','OE_NO_ELIGIBLE_LINES');

Line 2070: oe_debug_pub.add( 'BEFORE CALLING PERFORM LINE CANCELLATION' ) ;

2066: RAISE FND_API.G_EXC_ERROR;
2067: END IF;
2068:
2069: IF l_debug_level > 0 THEN
2070: oe_debug_pub.add( 'BEFORE CALLING PERFORM LINE CANCELLATION' ) ;
2071: END IF;
2072:
2073: -- Call PeformLinecancellation to cancel each line
2074: PerformLinecancellation(l_line_tbl,

Line 2080: oe_debug_pub.add( 'PERFORM LINE CANCELLATION UNEXP_ERROR' ) ;

2076: x_return_status => l_return_status);
2077:
2078: IF l_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
2079: IF l_debug_level > 0 THEN
2080: oe_debug_pub.add( 'PERFORM LINE CANCELLATION UNEXP_ERROR' ) ;
2081: END IF;
2082: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
2083: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
2084: IF l_debug_level > 0 THEN

Line 2085: oe_debug_pub.add( 'PERFORM LINE CANCELLATION RET_STS_ERROR' ) ;

2081: END IF;
2082: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
2083: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
2084: IF l_debug_level > 0 THEN
2085: oe_debug_pub.add( 'PERFORM LINE CANCELLATION RET_STS_ERROR' ) ;
2086: END IF;
2087: RAISE FND_API.G_EXC_ERROR;
2088: END IF;
2089:

Line 2102: oe_debug_pub.add( 'Process_requests_and_notify UNEXP_ERROR' ) ;

2098: , p_old_line_tbl => l_x_line_old_tbl
2099: );
2100: IF l_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
2101: IF l_debug_level > 0 THEN
2102: oe_debug_pub.add( 'Process_requests_and_notify UNEXP_ERROR' ) ;
2103: END IF;
2104: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
2105: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
2106: IF l_debug_level > 0 THEN

Line 2107: oe_debug_pub.add( 'Process_requests_and_notify RET_STS_ERROR' ) ;

2103: END IF;
2104: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
2105: ELSIF l_return_status = FND_API.G_RET_STS_ERROR THEN
2106: IF l_debug_level > 0 THEN
2107: oe_debug_pub.add( 'Process_requests_and_notify RET_STS_ERROR' ) ;
2108: END IF;
2109: RAISE FND_API.G_EXC_ERROR;
2110: END IF;
2111: --end bug 4567339

Line 2117: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.CANCEL_REMAINING_ORDER' ) ;

2113: -- bug 4887806
2114: OE_SALES_CAN_UTIL.Call_Process_Fulfillment(p_header_id => p_header_id);
2115:
2116: IF l_debug_level > 0 THEN
2117: oe_debug_pub.add( 'EXITING OE_SALES_CAN_UTIL.CANCEL_REMAINING_ORDER' ) ;
2118: END IF;
2119:
2120: EXCEPTION
2121: WHEN FND_API.G_EXC_ERROR THEN

Line 2153: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

2149: select ordered_quantity from
2150: oe_order_lines_all
2151: where header_id = x_request_rec.entity_id
2152: and ordered_quantity <> 0;
2153: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
2154:
2155: BEGIN
2156: if l_debug_level > 0 then
2157: OE_DEBUG_PUB.ADD('Enter Cancel Workflow API - OEXUCANB ');

Line 2157: OE_DEBUG_PUB.ADD('Enter Cancel Workflow API - OEXUCANB ');

2153: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
2154:
2155: BEGIN
2156: if l_debug_level > 0 then
2157: OE_DEBUG_PUB.ADD('Enter Cancel Workflow API - OEXUCANB ');
2158: OE_DEBUG_PUB.ADD('Entity:' || x_request_rec.param1 );
2159: OE_DEBUG_PUB.ADD('Entity id:' || x_request_rec.entity_id );
2160: end if;
2161:

Line 2158: OE_DEBUG_PUB.ADD('Entity:' || x_request_rec.param1 );

2154:
2155: BEGIN
2156: if l_debug_level > 0 then
2157: OE_DEBUG_PUB.ADD('Enter Cancel Workflow API - OEXUCANB ');
2158: OE_DEBUG_PUB.ADD('Entity:' || x_request_rec.param1 );
2159: OE_DEBUG_PUB.ADD('Entity id:' || x_request_rec.entity_id );
2160: end if;
2161:
2162: IF x_request_rec.param1 = OE_GLOBALS.G_ENTITY_HEADER

Line 2159: OE_DEBUG_PUB.ADD('Entity id:' || x_request_rec.entity_id );

2155: BEGIN
2156: if l_debug_level > 0 then
2157: OE_DEBUG_PUB.ADD('Enter Cancel Workflow API - OEXUCANB ');
2158: OE_DEBUG_PUB.ADD('Entity:' || x_request_rec.param1 );
2159: OE_DEBUG_PUB.ADD('Entity id:' || x_request_rec.entity_id );
2160: end if;
2161:
2162: IF x_request_rec.param1 = OE_GLOBALS.G_ENTITY_HEADER
2163: THEN

Line 2166: OE_DEBUG_PUB.ADD('Before select ');

2162: IF x_request_rec.param1 = OE_GLOBALS.G_ENTITY_HEADER
2163: THEN
2164:
2165: if l_debug_level > 0 then
2166: OE_DEBUG_PUB.ADD('Before select ');
2167: end if;
2168: OPEN C2;
2169: FETCH C2 INTO l_ordered_quantity;
2170: CLOSE C2;

Line 2173: OE_DEBUG_PUB.ADD('Before cancelling header flow ');

2169: FETCH C2 INTO l_ordered_quantity;
2170: CLOSE C2;
2171: IF l_ordered_quantity IS NULL THEN
2172: if l_debug_level > 0 then
2173: OE_DEBUG_PUB.ADD('Before cancelling header flow ');
2174: end if;
2175:
2176: wf_engine.handleerror(OE_Globals.G_WFI_HDR
2177: ,to_char(x_request_rec.entity_id)

Line 2184: OE_DEBUG_PUB.ADD('after cancelling header flow ');

2180:
2181: END IF; -- Ordered quantity
2182:
2183: if l_debug_level > 0 then
2184: OE_DEBUG_PUB.ADD('after cancelling header flow ');
2185: end if;
2186:
2187: ELSIF x_request_rec.param1 = OE_GLOBALS.G_ENTITY_LINE
2188: THEN

Line 2191: OE_DEBUG_PUB.ADD('before select Cursoer C1 ');

2187: ELSIF x_request_rec.param1 = OE_GLOBALS.G_ENTITY_LINE
2188: THEN
2189:
2190: if l_debug_level > 0 then
2191: OE_DEBUG_PUB.ADD('before select Cursoer C1 ');
2192: end if;
2193: OPEN C1;
2194: FETCH C1 INTO l_ordered_quantity;
2195: CLOSE C1;

Line 2198: OE_DEBUG_PUB.ADD('Before cancelling line flow ');

2194: FETCH C1 INTO l_ordered_quantity;
2195: CLOSE C1;
2196: IF l_ordered_quantity = 0 THEN
2197: if l_debug_level > 0 then
2198: OE_DEBUG_PUB.ADD('Before cancelling line flow ');
2199: end if;
2200: Update oe_order_lines_all
2201: set cancelled_flag = 'Y' where
2202: line_id = x_request_rec.entity_id;

Line 2211: OE_DEBUG_PUB.ADD('after cancelling line flow ');

2207: 'RETRY','CANCEL');
2208: End if; -- Ordered quantity
2209:
2210: if l_debug_level > 0 then
2211: OE_DEBUG_PUB.ADD('after cancelling line flow ');
2212: end if;
2213:
2214: END IF;
2215:

Line 2252: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;

2248: l_old_ord_quantity2 number;
2249: l_old_can_quantity2 number;
2250: l_new_can_quantity2 number;
2251: --
2252: l_debug_level CONSTANT NUMBER := oe_debug_pub.g_debug_level;
2253: --
2254: begin
2255:
2256: IF l_debug_level > 0 THEN

Line 2257: oe_debug_pub.add( 'entering Cal_Cancelled_Qty2') ;

2253: --
2254: begin
2255:
2256: IF l_debug_level > 0 THEN
2257: oe_debug_pub.add( 'entering Cal_Cancelled_Qty2') ;
2258: END IF;
2259: IF NOT OE_GLOBALS.Equal(p_line_rec.ordered_quantity2,p_old_line_rec.ordered_quantity2)
2260: THEN
2261: IF l_debug_level > 0 THEN

Line 2262: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 1 ') ;

2258: END IF;
2259: IF NOT OE_GLOBALS.Equal(p_line_rec.ordered_quantity2,p_old_line_rec.ordered_quantity2)
2260: THEN
2261: IF l_debug_level > 0 THEN
2262: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 1 ') ;
2263: END IF;
2264:
2265: --IF (nvl(p_line_rec.line_category_code,' ') <> 'RETURN') THEN
2266:

Line 2276: oe_debug_pub.add( 'NEW ORDERED QUANTITY2 IS: '||P_LINE_REC.ORDERED_QUANTITY2 ) ;

2272: from oe_order_lines
2273: where line_id = p_line_rec.line_id;
2274:
2275: IF l_debug_level > 0 THEN
2276: oe_debug_pub.add( 'NEW ORDERED QUANTITY2 IS: '||P_LINE_REC.ORDERED_QUANTITY2 ) ;
2277: END IF;
2278: IF l_debug_level > 0 THEN
2279: oe_debug_pub.add( 'OLD ORDERED QUANTITY2 IS: '||L_OLD_ORD_QUANTITY2 ) ;
2280: END IF;

Line 2279: oe_debug_pub.add( 'OLD ORDERED QUANTITY2 IS: '||L_OLD_ORD_QUANTITY2 ) ;

2275: IF l_debug_level > 0 THEN
2276: oe_debug_pub.add( 'NEW ORDERED QUANTITY2 IS: '||P_LINE_REC.ORDERED_QUANTITY2 ) ;
2277: END IF;
2278: IF l_debug_level > 0 THEN
2279: oe_debug_pub.add( 'OLD ORDERED QUANTITY2 IS: '||L_OLD_ORD_QUANTITY2 ) ;
2280: END IF;
2281: IF l_debug_level > 0 THEN
2282: oe_debug_pub.add( 'OLD CANCELLED QUANTITY2 IS: '||L_OLD_CAN_QUANTITY2 ) ;
2283: END IF;

Line 2282: oe_debug_pub.add( 'OLD CANCELLED QUANTITY2 IS: '||L_OLD_CAN_QUANTITY2 ) ;

2278: IF l_debug_level > 0 THEN
2279: oe_debug_pub.add( 'OLD ORDERED QUANTITY2 IS: '||L_OLD_ORD_QUANTITY2 ) ;
2280: END IF;
2281: IF l_debug_level > 0 THEN
2282: oe_debug_pub.add( 'OLD CANCELLED QUANTITY2 IS: '||L_OLD_CAN_QUANTITY2 ) ;
2283: END IF;
2284:
2285: IF (l_old_ord_quantity2 > p_line_rec.ordered_quantity2)
2286: and nvl(oe_globals.g_pricing_recursion, 'N') = 'N' THEN

Line 2294: oe_debug_pub.add( 'NEW CANCELLED QUANTITY2 IS: '||L_NEW_CAN_QUANTITY2 ) ;

2290: l_new_can_quantity2 := l_old_can_quantity2;
2291: END IF;
2292:
2293: IF l_debug_level > 0 THEN
2294: oe_debug_pub.add( 'NEW CANCELLED QUANTITY2 IS: '||L_NEW_CAN_QUANTITY2 ) ;
2295: END IF;
2296:
2297: RETURN l_new_can_quantity2;
2298:

Line 2307: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 2 ') ;

2303: ** order right after quantity on the lines was updated to 0.
2304: ** Need to send the Cancelled Qty as Zero in such instances.
2305: */
2306: IF l_debug_level > 0 THEN
2307: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 2 ') ;
2308: END IF;
2309:
2310: IF p_line_rec.ordered_quantity2 = 0 AND
2311: p_old_line_rec.ordered_quantity2 = 0 AND

Line 2317: oe_debug_pub.add('Line Ord Qty2 already 0, Returning 0 as Cancelled Qty2');

2313:
2314: RETURN 0;
2315:
2316: IF l_debug_level > 0 THEN
2317: oe_debug_pub.add('Line Ord Qty2 already 0, Returning 0 as Cancelled Qty2');
2318: END IF;
2319: END IF;
2320:
2321: IF l_debug_level > 0 THEN

Line 2322: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 3 ') ;

2318: END IF;
2319: END IF;
2320:
2321: IF l_debug_level > 0 THEN
2322: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 3 ') ;
2323: END IF;
2324:
2325: /* Following commented code has been replaced as fix for bug # 2136529
2326:

Line 2333: oe_debug_pub.ADD('rajeevcancell');

2329: (p_old_line_rec.ordered_quantity - p_line_rec.ordered_quantity);
2330:
2331: IF p_old_line_rec.cancelled_quantity = FND_API.G_MISS_NUM OR
2332: p_old_line_rec.cancelled_quantity is NULL THEN
2333: oe_debug_pub.ADD('rajeevcancell');
2334: RETURN l_ordered_quantity;
2335: ELSE
2336: oe_debug_pub.ADD('rajeevcancel2');
2337: RETURN (l_ordered_quantity +

Line 2336: oe_debug_pub.ADD('rajeevcancel2');

2332: p_old_line_rec.cancelled_quantity is NULL THEN
2333: oe_debug_pub.ADD('rajeevcancell');
2334: RETURN l_ordered_quantity;
2335: ELSE
2336: oe_debug_pub.ADD('rajeevcancel2');
2337: RETURN (l_ordered_quantity +
2338: p_old_line_rec.cancelled_quantity) ;
2339: END IF;
2340: ELSE

Line 2341: oe_debug_pub.ADD('rajeevcancel3');

2337: RETURN (l_ordered_quantity +
2338: p_old_line_rec.cancelled_quantity) ;
2339: END IF;
2340: ELSE
2341: oe_debug_pub.ADD('rajeevcancel3');
2342: RETURN p_line_rec.cancelled_quantity;
2343: END IF;
2344: END IF;
2345: ELSE

Line 2360: oe_debug_pub.ADD('rajeevcancelsecond');

2356: END IF;
2357: ELSE
2358: RETURN p_line_rec.cancelled_quantity;
2359: END IF;
2360: oe_debug_pub.ADD('rajeevcancelsecond');
2361:
2362: END IF;
2363: END IF;
2364: RETURN p_line_rec.cancelled_quantity;

Line 2369: oe_debug_pub.add('New ordered_quantity2 and Old ordered_quantity2 are equal ');

2365: */
2366:
2367: --Bug# 4009268
2368: IF OE_GLOBALS.Equal(p_line_rec.ordered_quantity2,p_old_line_rec.ordered_quantity2) THEN
2369: oe_debug_pub.add('New ordered_quantity2 and Old ordered_quantity2 are equal ');
2370: RETURN p_line_rec.cancelled_quantity2;
2371: END IF;
2372:
2373: IF l_debug_level > 0 THEN

Line 2374: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 4 ') ;

2370: RETURN p_line_rec.cancelled_quantity2;
2371: END IF;
2372:
2373: IF l_debug_level > 0 THEN
2374: oe_debug_pub.add( 'in Cal_Cancelled_Qty2 4 ') ;
2375: END IF;
2376: RETURN 0;
2377:
2378: end Cal_Cancelled_qty2;