DBA Data[Home] [Help]

APPS.IBE_ORDER_SAVE_PVT dependencies on IBE_UTIL

Line 23: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

19:
20:
21: BEGIN
22:
23: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
24: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Get_Order_Status');
25: END IF;
26:
27: OPEN c_gethdrstatus(p_header_id);

Line 24: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Get_Order_Status');

20:
21: BEGIN
22:
23: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
24: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Get_Order_Status');
25: END IF;
26:
27: OPEN c_gethdrstatus(p_header_id);
28: FETCH c_gethdrstatus INTO l_gethdrstatus;

Line 38: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

34: x_last_update_date := l_gethdrstatus.last_update_date;
35: END IF;
36: CLOSE c_gethdrstatus;
37:
38: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
39: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:Get_Order_Status');
40: END IF;
41:
42: END Get_Order_Status;

Line 39: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:Get_Order_Status');

35: END IF;
36: CLOSE c_gethdrstatus;
37:
38: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
39: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:Get_Order_Status');
40: END IF;
41:
42: END Get_Order_Status;
43:

Line 77: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

73: l_msg_type VARCHAR2(30);
74:
75: BEGIN
76:
77: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
78: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Retrieve_OE_Messages');
79: END IF;
80:
81: OE_MSG_PUB.Count_And_Get

Line 78: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Retrieve_OE_Messages');

74:
75: BEGIN
76:
77: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
78: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Retrieve_OE_Messages');
79: END IF;
80:
81: OE_MSG_PUB.Count_And_Get
82: ( p_count => l_msg_count,

Line 138: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

134: END IF;
135:
136: x_msg_data := l_msg_context||l_msg_data;
137:
138: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
139: Ibe_Util.debug('Retrieve_OE_Messages - x_msg_data: '||x_msg_data);
140: END IF;
141:
142: l_len_sqlerrm := Length(x_msg_data) ;

Line 139: Ibe_Util.debug('Retrieve_OE_Messages - x_msg_data: '||x_msg_data);

135:
136: x_msg_data := l_msg_context||l_msg_data;
137:
138: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
139: Ibe_Util.debug('Retrieve_OE_Messages - x_msg_data: '||x_msg_data);
140: END IF;
141:
142: l_len_sqlerrm := Length(x_msg_data) ;
143: WHILE l_len_sqlerrm >= i

Line 155: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

151: END IF;
152: END LOOP;
153: END IF;
154:
155: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
156: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:Retrieve_OE_Messages');
157: END IF;
158:
159: END Retrieve_OE_Messages;

Line 156: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:Retrieve_OE_Messages');

152: END LOOP;
153: END IF;
154:
155: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
156: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:Retrieve_OE_Messages');
157: END IF;
158:
159: END Retrieve_OE_Messages;
160:

Line 170: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

166: IS
167:
168: BEGIN
169:
170: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
171: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Deactivate Order: ' || p_party_id || ' : '||p_cust_account_id);
172: END IF;
173:
174:

Line 171: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Deactivate Order: ' || p_party_id || ' : '||p_cust_account_id);

167:
168: BEGIN
169:
170: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
171: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:Deactivate Order: ' || p_party_id || ' : '||p_cust_account_id);
172: END IF;
173:
174:
175: IBE_ACTIVE_QUOTES_ALL_PKG.Update_row(

Line 187: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

183: X_LAST_UPDATE_LOGIN => 1,
184: X_RECORD_TYPE => 'ORDER');
185:
186:
187: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
188: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:DeactivateOrder');
189: END IF;
190:
191: END DeactivateOrder;

Line 188: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:DeactivateOrder');

184: X_RECORD_TYPE => 'ORDER');
185:
186:
187: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
188: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:DeactivateOrder');
189: END IF;
190:
191: END DeactivateOrder;
192:

Line 219: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

215:
216:
217: BEGIN
218:
219: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
220: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:ActivateOrder');
221: END IF;
222:
223: open c_check_pr_aqa( p_party_id,p_cust_account_id,p_currency_code);

Line 220: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:ActivateOrder');

216:
217: BEGIN
218:
219: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
220: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:ActivateOrder');
221: END IF;
222:
223: open c_check_pr_aqa( p_party_id,p_cust_account_id,p_currency_code);
224: fetch c_check_pr_aqa into rec_check_pr_aqa;

Line 227: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

223: open c_check_pr_aqa( p_party_id,p_cust_account_id,p_currency_code);
224: fetch c_check_pr_aqa into rec_check_pr_aqa;
225: if (c_check_pr_aqa%notfound) then
226:
227: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
228: Ibe_Util.debug('Pending Return Not Exists');
229: END IF;
230: IBE_ACTIVE_QUOTES_ALL_PKG.Insert_row(
231: X_OBJECT_VERSION_NUMBER => 1,

Line 228: Ibe_Util.debug('Pending Return Not Exists');

224: fetch c_check_pr_aqa into rec_check_pr_aqa;
225: if (c_check_pr_aqa%notfound) then
226:
227: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
228: Ibe_Util.debug('Pending Return Not Exists');
229: END IF;
230: IBE_ACTIVE_QUOTES_ALL_PKG.Insert_row(
231: X_OBJECT_VERSION_NUMBER => 1,
232: X_ORDER_HEADER_ID => p_order_header_id,

Line 246: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

242: X_ORG_ID => mo_global.GET_CURRENT_ORG_ID());
243:
244:
245: else
246: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
247: Ibe_Util.debug('Pending Return Already Exists');
248: END IF;
249:
250: IBE_ACTIVE_QUOTES_ALL_PKG.update_row(

Line 247: Ibe_Util.debug('Pending Return Already Exists');

243:
244:
245: else
246: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
247: Ibe_Util.debug('Pending Return Already Exists');
248: END IF;
249:
250: IBE_ACTIVE_QUOTES_ALL_PKG.update_row(
251: X_OBJECT_VERSION_NUMBER => 1,

Line 264: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

260:
261:
262: END IF;
263:
264: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
265: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:ActivateOrder');
266: END IF;
267:
268: END ActivateOrder;

Line 265: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:ActivateOrder');

261:
262: END IF;
263:
264: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
265: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:ActivateOrder');
266: END IF;
267:
268: END ActivateOrder;
269:

Line 296: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

292: l_parseKey varchar2(40) :='ORDER_SAVE_LINE_IDS';
293:
294: BEGIN
295:
296: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
297: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:DefaultFromLineSiteId');
298: END IF;
299:
300: for lineIdx in 1..p_line_tbl.count

Line 297: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:DefaultFromLineSiteId');

293:
294: BEGIN
295:
296: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
297: Ibe_Util.debug('Begin IBE_ORDER_SAVE_PVT:DefaultFromLineSiteId');
298: END IF;
299:
300: for lineIdx in 1..p_line_tbl.count
301: loop

Line 310: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

306: END IF;
307: end loop;
308:
309:
310: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
311: Ibe_util.debug('p_line_ids set: '||p_line_ids);
312: end if;
313:
314: /** This API is called for parsing the where condition PlSQL Bind Variables Std. **/

Line 311: Ibe_util.debug('p_line_ids set: '||p_line_ids);

307: end loop;
308:
309:
310: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
311: Ibe_util.debug('p_line_ids set: '||p_line_ids);
312: end if;
313:
314: /** This API is called for parsing the where condition PlSQL Bind Variables Std. **/
315: IBE_LEAD_IMPORT_PVT.parseInput (p_line_ids, 'CHAR', l_parseKey,l_parseNum, l_line_id_query);

Line 323: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

319: 'WHERE csu.status = ''A'' AND site_use_code = :siteusecode '||
320: 'AND csu.site_use_id IN ('||l_line_id_query||')';
321:
322:
323: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
324: IBE_Util.debug('qry executed: '|| l_tmp_query);
325: end if;
326: open psitetype_tmp for l_tmp_query using p_siteuse_type,l_parseKey;
327: fetch psitetype_tmp into l_linesite_use_id;

Line 324: IBE_Util.debug('qry executed: '|| l_tmp_query);

320: 'AND csu.site_use_id IN ('||l_line_id_query||')';
321:
322:
323: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
324: IBE_Util.debug('qry executed: '|| l_tmp_query);
325: end if;
326: open psitetype_tmp for l_tmp_query using p_siteuse_type,l_parseKey;
327: fetch psitetype_tmp into l_linesite_use_id;
328: close psitetype_tmp;

Line 329: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

325: end if;
326: open psitetype_tmp for l_tmp_query using p_siteuse_type,l_parseKey;
327: fetch psitetype_tmp into l_linesite_use_id;
328: close psitetype_tmp;
329: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
330: IBE_Util.debug('site use id from line: '|| l_linesite_use_id);
331: end if;
332: x_site_use_id := l_linesite_use_id;
333:

Line 330: IBE_Util.debug('site use id from line: '|| l_linesite_use_id);

326: open psitetype_tmp for l_tmp_query using p_siteuse_type,l_parseKey;
327: fetch psitetype_tmp into l_linesite_use_id;
328: close psitetype_tmp;
329: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
330: IBE_Util.debug('site use id from line: '|| l_linesite_use_id);
331: end if;
332: x_site_use_id := l_linesite_use_id;
333:
334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

330: IBE_Util.debug('site use id from line: '|| l_linesite_use_id);
331: end if;
332: x_site_use_id := l_linesite_use_id;
333:
334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
335: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:DefaultFromLineSiteId');
336: END IF;
337:
338: END DefaultFromLineSiteId;

Line 335: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:DefaultFromLineSiteId');

331: end if;
332: x_site_use_id := l_linesite_use_id;
333:
334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
335: Ibe_Util.debug('End IBE_ORDER_SAVE_PVT:DefaultFromLineSiteId');
336: END IF;
337:
338: END DefaultFromLineSiteId;
339:

Line 357: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

353: l_line_rec c_get_lineInfo%rowType;
354:
355: BEGIN
356:
357: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
358: IBE_Util.Debug('IBE_ORDER_SAVE_PVT:MergeLines - START');
359: END IF;
360: open c_get_lineInfo(p_order_line_rec.return_attribute2,
361: p_order_line_rec.return_attribute1,

Line 358: IBE_Util.Debug('IBE_ORDER_SAVE_PVT:MergeLines - START');

354:
355: BEGIN
356:
357: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
358: IBE_Util.Debug('IBE_ORDER_SAVE_PVT:MergeLines - START');
359: END IF;
360: open c_get_lineInfo(p_order_line_rec.return_attribute2,
361: p_order_line_rec.return_attribute1,
362: p_header_id

Line 367: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

363: );
364: Fetch c_get_lineInfo into l_line_rec;
365:
366: if (c_get_lineInfo%found) then
367: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
368: Ibe_Util.Debug('MergeLines Already a record exists.');
369: END IF;
370: x_line_rec := OE_ORDER_PUB.G_MISS_LINE_REC;
371: x_line_rec.item_type_code := p_order_line_rec.item_type_code;

Line 368: Ibe_Util.Debug('MergeLines Already a record exists.');

364: Fetch c_get_lineInfo into l_line_rec;
365:
366: if (c_get_lineInfo%found) then
367: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
368: Ibe_Util.Debug('MergeLines Already a record exists.');
369: END IF;
370: x_line_rec := OE_ORDER_PUB.G_MISS_LINE_REC;
371: x_line_rec.item_type_code := p_order_line_rec.item_type_code;
372: x_line_rec.ordered_quantity := p_order_line_rec.ordered_quantity + l_line_rec.ordered_quantity;

Line 376: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

372: x_line_rec.ordered_quantity := p_order_line_rec.ordered_quantity + l_line_rec.ordered_quantity;
373: x_line_rec.line_id := l_line_rec.line_id;
374: x_line_rec.operation := OE_Globals.G_OPR_UPDATE;
375: else
376: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
377: Ibe_Util.Debug('MergeLines else part: No previous record');
378: end if;
379: x_line_rec := p_order_line_rec;
380: x_line_rec.operation := OE_GLOBALS.G_OPR_CREATE;

Line 377: Ibe_Util.Debug('MergeLines else part: No previous record');

373: x_line_rec.line_id := l_line_rec.line_id;
374: x_line_rec.operation := OE_Globals.G_OPR_UPDATE;
375: else
376: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
377: Ibe_Util.Debug('MergeLines else part: No previous record');
378: end if;
379: x_line_rec := p_order_line_rec;
380: x_line_rec.operation := OE_GLOBALS.G_OPR_CREATE;
381: end if;

Line 384: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

380: x_line_rec.operation := OE_GLOBALS.G_OPR_CREATE;
381: end if;
382: close c_get_lineInfo;
383:
384: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
385: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:MergeLines');
386: END IF;
387: END MergeLines;
388:

Line 385: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:MergeLines');

381: end if;
382: close c_get_lineInfo;
383:
384: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
385: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:MergeLines');
386: END IF;
387: END MergeLines;
388:
389:

Line 403: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

399: l_linetypeinfo c_linetypeinfo%rowtype;
400:
401: BEGIN
402:
403: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
404: IBE_Util.Debug('BEgin IBE_ORDER_SAVE_PVT:DefaultLineTypes');
405: END IF;
406: open c_linetypeInfo(p_header_type_id);
407: fetch c_linetypeinfo into l_linetypeinfo;

Line 404: IBE_Util.Debug('BEgin IBE_ORDER_SAVE_PVT:DefaultLineTypes');

400:
401: BEGIN
402:
403: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
404: IBE_Util.Debug('BEgin IBE_ORDER_SAVE_PVT:DefaultLineTypes');
405: END IF;
406: open c_linetypeInfo(p_header_type_id);
407: fetch c_linetypeinfo into l_linetypeinfo;
408: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 408: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

404: IBE_Util.Debug('BEgin IBE_ORDER_SAVE_PVT:DefaultLineTypes');
405: END IF;
406: open c_linetypeInfo(p_header_type_id);
407: fetch c_linetypeinfo into l_linetypeinfo;
408: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
409: IBE_util.debug('line type id info' || c_linetypeinfo%rowcount);
410: end if;
411: x_line_type_id := l_linetypeinfo.DEFAULT_INBOUND_LINE_TYPE_ID;
412: close c_linetypeinfo;

Line 409: IBE_util.debug('line type id info' || c_linetypeinfo%rowcount);

405: END IF;
406: open c_linetypeInfo(p_header_type_id);
407: fetch c_linetypeinfo into l_linetypeinfo;
408: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
409: IBE_util.debug('line type id info' || c_linetypeinfo%rowcount);
410: end if;
411: x_line_type_id := l_linetypeinfo.DEFAULT_INBOUND_LINE_TYPE_ID;
412: close c_linetypeinfo;
413:

Line 414: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

410: end if;
411: x_line_type_id := l_linetypeinfo.DEFAULT_INBOUND_LINE_TYPE_ID;
412: close c_linetypeinfo;
413:
414: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
415: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:DefaultLineTypes');
416: END IF;
417:
418: END DefaultLineTypes;

Line 415: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:DefaultLineTypes');

411: x_line_type_id := l_linetypeinfo.DEFAULT_INBOUND_LINE_TYPE_ID;
412: close c_linetypeinfo;
413:
414: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
415: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:DefaultLineTypes');
416: END IF;
417:
418: END DefaultLineTypes;
419:

Line 450: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

446: l_orderhdr_typeid NUMBER;
447:
448: BEGIN
449:
450: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
451: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: DefaultLineRecord');
452: END IF;
453: For j IN 1..p_order_line_tbl.COUNT
454: Loop

Line 451: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: DefaultLineRecord');

447:
448: BEGIN
449:
450: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
451: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: DefaultLineRecord');
452: END IF;
453: For j IN 1..p_order_line_tbl.COUNT
454: Loop
455: l_order_line_tbl(j) := p_order_line_tbl(j);

Line 478: IF (IBE_UTIL.G_DEBUGON = l_true) then

474:
475: DefaultLineTypes(p_header_type_id => l_orderhdr_typeid
476: ,x_line_type_id => l_linetype_id);
477:
478: IF (IBE_UTIL.G_DEBUGON = l_true) then
479: IBE_util.debug('p_save_type: ' || p_save_type);
480: end if;
481:
482: For i in 1..l_order_line_tbl.COUNT

Line 479: IBE_util.debug('p_save_type: ' || p_save_type);

475: DefaultLineTypes(p_header_type_id => l_orderhdr_typeid
476: ,x_line_type_id => l_linetype_id);
477:
478: IF (IBE_UTIL.G_DEBUGON = l_true) then
479: IBE_util.debug('p_save_type: ' || p_save_type);
480: end if;
481:
482: For i in 1..l_order_line_tbl.COUNT
483: LOOP

Line 504: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

500: MergeLines(p_header_id => p_order_header_rec.HEADER_ID,
501: p_order_line_rec => l_order_line_tbl(i),
502: x_line_rec => lx_line_rec);
503:
504: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
505: ibe_util.Debug('Save:line_tbl.ordered_quantity' || lx_line_rec.ORDERED_QUANTITY);
506: ibe_util.Debug('Save:line_tbl.operation ' || lx_line_rec.operation);
507: END IF;
508: l_order_line_tbl(i) := lx_line_rec;

Line 505: ibe_util.Debug('Save:line_tbl.ordered_quantity' || lx_line_rec.ORDERED_QUANTITY);

501: p_order_line_rec => l_order_line_tbl(i),
502: x_line_rec => lx_line_rec);
503:
504: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
505: ibe_util.Debug('Save:line_tbl.ordered_quantity' || lx_line_rec.ORDERED_QUANTITY);
506: ibe_util.Debug('Save:line_tbl.operation ' || lx_line_rec.operation);
507: END IF;
508: l_order_line_tbl(i) := lx_line_rec;
509:

Line 506: ibe_util.Debug('Save:line_tbl.operation ' || lx_line_rec.operation);

502: x_line_rec => lx_line_rec);
503:
504: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
505: ibe_util.Debug('Save:line_tbl.ordered_quantity' || lx_line_rec.ORDERED_QUANTITY);
506: ibe_util.Debug('Save:line_tbl.operation ' || lx_line_rec.operation);
507: END IF;
508: l_order_line_tbl(i) := lx_line_rec;
509:
510: /* The following IF LOOP would be executed when there is already an active pending Return And

Line 539: IF (IBE_UTIL.G_DEBUGON = l_true) then

535: THEN
536: IF (l_linetype_id is not null AND l_linetype_id <> FND_API.G_MISS_NUM)
537: THEN
538: l_order_line_tbl(i).line_type_id := l_linetype_id;
539: IF (IBE_UTIL.G_DEBUGON = l_true) then
540: ibe_util.debug('line type id..'||l_order_line_tbl(i).line_type_id);
541: end if;
542: ELSE
543: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_LINE_TYPE_ID_MISS');

Line 540: ibe_util.debug('line type id..'||l_order_line_tbl(i).line_type_id);

536: IF (l_linetype_id is not null AND l_linetype_id <> FND_API.G_MISS_NUM)
537: THEN
538: l_order_line_tbl(i).line_type_id := l_linetype_id;
539: IF (IBE_UTIL.G_DEBUGON = l_true) then
540: ibe_util.debug('line type id..'||l_order_line_tbl(i).line_type_id);
541: end if;
542: ELSE
543: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_LINE_TYPE_ID_MISS');
544: FND_Msg_Pub.Add;

Line 554: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

550:
551: /* This flow will be executed when both HEader and Line level are 'CREATE'.
552: ie first time creation of a Return */
553:
554: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
555: ibe_util.Debug('Inside Line Values Defaulting flow');
556: END IF;
557: l_order_line_tbl(i).operation := OE_GLOBALS.G_OPR_CREATE;
558: l_order_line_tbl(i).line_category_code := 'RETURN';

Line 555: ibe_util.Debug('Inside Line Values Defaulting flow');

551: /* This flow will be executed when both HEader and Line level are 'CREATE'.
552: ie first time creation of a Return */
553:
554: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
555: ibe_util.Debug('Inside Line Values Defaulting flow');
556: END IF;
557: l_order_line_tbl(i).operation := OE_GLOBALS.G_OPR_CREATE;
558: l_order_line_tbl(i).line_category_code := 'RETURN';
559: l_order_line_tbl(i).return_context := 'ORDER';

Line 582: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

578: THEN
579: IF (l_linetype_id is not null AND l_linetype_id <> FND_API.G_MISS_NUM)
580: THEN
581: l_order_line_tbl(i).line_type_id := l_linetype_id;
582: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
583: ibe_util.debug('line type id..'||l_order_line_tbl(i).line_type_id);
584: end if;
585: ELSE
586: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_LINE_TYPE_ID_MISS');

Line 583: ibe_util.debug('line type id..'||l_order_line_tbl(i).line_type_id);

579: IF (l_linetype_id is not null AND l_linetype_id <> FND_API.G_MISS_NUM)
580: THEN
581: l_order_line_tbl(i).line_type_id := l_linetype_id;
582: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
583: ibe_util.debug('line type id..'||l_order_line_tbl(i).line_type_id);
584: end if;
585: ELSE
586: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_LINE_TYPE_ID_MISS');
587: FND_Msg_Pub.Add;

Line 605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

601: Loop
602: x_order_line_tbl(k) := l_order_line_tbl(k);
603: End Loop;
604:
605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
606: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultLineRecord');
607: END IF;
608:
609: END DefaultLineRecord;

Line 606: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultLineRecord');

602: x_order_line_tbl(k) := l_order_line_tbl(k);
603: End Loop;
604:
605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
606: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultLineRecord');
607: END IF;
608:
609: END DefaultLineRecord;
610:

Line 630: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

626: l_active_returnid NUMBER:= FND_API.G_MISS_NUM;
627:
628: BEGIN
629:
630: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
631: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: GetActiveReturnOrder');
632: END IF;
633:
634: OPEN c_getactive_pendret(p_cust_acct_id,

Line 631: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: GetActiveReturnOrder');

627:
628: BEGIN
629:
630: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
631: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: GetActiveReturnOrder');
632: END IF;
633:
634: OPEN c_getactive_pendret(p_cust_acct_id,
635: p_curr_code,

Line 647: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

643: END IF;
644:
645: CLOSE c_getactive_pendret;
646:
647: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
648: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT: GetActiveReturnOrder');
649: END IF;
650:
651: END GetActiveReturnOrder;

Line 648: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT: GetActiveReturnOrder');

644:
645: CLOSE c_getactive_pendret;
646:
647: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
648: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT: GetActiveReturnOrder');
649: END IF;
650:
651: END GetActiveReturnOrder;
652:

Line 678: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

674: l_preApprove_prof VARCHAR2(10) := 'N';
675:
676: BEGIN
677:
678: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
679: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: DefaultHeaderRecord');
680: END IF;
681:
682: x_order_header_rec := p_order_header_rec;

Line 679: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: DefaultHeaderRecord');

675:
676: BEGIN
677:
678: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
679: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT: DefaultHeaderRecord');
680: END IF;
681:
682: x_order_header_rec := p_order_header_rec;
683:

Line 684: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

680: END IF;
681:
682: x_order_header_rec := p_order_header_rec;
683:
684: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
685: Ibe_util.Debug('p_save_type: ' || p_save_type ||'::'||x_order_header_rec.header_id);
686: Ibe_util.Debug('category_code ' || x_order_header_rec.ORDER_CATEGORY_CODE);
687: END IF;
688:

Line 685: Ibe_util.Debug('p_save_type: ' || p_save_type ||'::'||x_order_header_rec.header_id);

681:
682: x_order_header_rec := p_order_header_rec;
683:
684: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
685: Ibe_util.Debug('p_save_type: ' || p_save_type ||'::'||x_order_header_rec.header_id);
686: Ibe_util.Debug('category_code ' || x_order_header_rec.ORDER_CATEGORY_CODE);
687: END IF;
688:
689:

Line 686: Ibe_util.Debug('category_code ' || x_order_header_rec.ORDER_CATEGORY_CODE);

682: x_order_header_rec := p_order_header_rec;
683:
684: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
685: Ibe_util.Debug('p_save_type: ' || p_save_type ||'::'||x_order_header_rec.header_id);
686: Ibe_util.Debug('category_code ' || x_order_header_rec.ORDER_CATEGORY_CODE);
687: END IF;
688:
689:
690: IF (p_save_type = SAVE_ADDITEMS) THEN

Line 712: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

708: IF (x_order_header_rec.header_id is not null AND
709: x_order_header_rec.header_id <> FND_API.G_MISS_NUM)
710: THEN
711:
712: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
713: Ibe_util.Debug('Header id is not null, so cheking its status');
714: END IF;
715:
716: Get_Order_Status(p_header_id => x_order_header_rec.header_id

Line 713: Ibe_util.Debug('Header id is not null, so cheking its status');

709: x_order_header_rec.header_id <> FND_API.G_MISS_NUM)
710: THEN
711:
712: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
713: Ibe_util.Debug('Header id is not null, so cheking its status');
714: END IF;
715:
716: Get_Order_Status(p_header_id => x_order_header_rec.header_id
717: ,x_order_status => l_flow_status_code

Line 720: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

716: Get_Order_Status(p_header_id => x_order_header_rec.header_id
717: ,x_order_status => l_flow_status_code
718: ,x_last_update_date => l_last_update_date);
719:
720: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
721: Ibe_util.Debug('last_update_date sent from ui: '||
722: to_char(x_order_header_rec.last_update_date,'dd-mm-yyyy hh:mi:ss'));
723: Ibe_util.Debug('last_update_date from db: '||
724: to_char(l_last_update_date,'dd-mm-yyyy hh:mi:ss'));

Line 721: Ibe_util.Debug('last_update_date sent from ui: '||

717: ,x_order_status => l_flow_status_code
718: ,x_last_update_date => l_last_update_date);
719:
720: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
721: Ibe_util.Debug('last_update_date sent from ui: '||
722: to_char(x_order_header_rec.last_update_date,'dd-mm-yyyy hh:mi:ss'));
723: Ibe_util.Debug('last_update_date from db: '||
724: to_char(l_last_update_date,'dd-mm-yyyy hh:mi:ss'));
725: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);

Line 723: Ibe_util.Debug('last_update_date from db: '||

719:
720: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
721: Ibe_util.Debug('last_update_date sent from ui: '||
722: to_char(x_order_header_rec.last_update_date,'dd-mm-yyyy hh:mi:ss'));
723: Ibe_util.Debug('last_update_date from db: '||
724: to_char(l_last_update_date,'dd-mm-yyyy hh:mi:ss'));
725: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);
726: END IF;
727:

Line 725: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);

721: Ibe_util.Debug('last_update_date sent from ui: '||
722: to_char(x_order_header_rec.last_update_date,'dd-mm-yyyy hh:mi:ss'));
723: Ibe_util.Debug('last_update_date from db: '||
724: to_char(l_last_update_date,'dd-mm-yyyy hh:mi:ss'));
725: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);
726: END IF;
727:
728: IF ((l_flow_status_code = 'BOOKED' OR l_flow_status_code='CLOSED' OR
729: l_flow_status_code = 'CANCELLED')

Line 737: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

733: FND_Msg_Pub.Add;
734: RAISE FND_API.G_EXC_ERROR;
735: ELSE
736: x_order_header_rec.operation := OE_Globals.G_OPR_UPDATE;
737: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
738: Ibe_util.Debug('Return not booked loop: ' ||x_order_header_rec.operation);
739: END IF;
740: END IF;
741:

Line 738: Ibe_util.Debug('Return not booked loop: ' ||x_order_header_rec.operation);

734: RAISE FND_API.G_EXC_ERROR;
735: ELSE
736: x_order_header_rec.operation := OE_Globals.G_OPR_UPDATE;
737: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
738: Ibe_util.Debug('Return not booked loop: ' ||x_order_header_rec.operation);
739: END IF;
740: END IF;
741:
742: ELSIF (x_order_header_rec.ORDER_CATEGORY_CODE) = 'RETURN' THEN

Line 749: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

745: ,p_curr_code => x_order_header_rec.transactional_curr_code
746: ,p_party_id => p_party_id
747: ,x_order_header_id => l_order_header_id);
748:
749: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
750: Ibe_util.Debug('Active pending Return: '||l_order_header_id);
751: END IF;
752:
753: IF(l_order_header_id is null OR l_order_header_id = FND_API.G_MISS_NUM) THEN

Line 750: Ibe_util.Debug('Active pending Return: '||l_order_header_id);

746: ,p_party_id => p_party_id
747: ,x_order_header_id => l_order_header_id);
748:
749: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
750: Ibe_util.Debug('Active pending Return: '||l_order_header_id);
751: END IF;
752:
753: IF(l_order_header_id is null OR l_order_header_id = FND_API.G_MISS_NUM) THEN
754:

Line 774: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

770: RAISE FND_API.G_EXC_ERROR;
771: END IF;
772: end if; -- if order type id
773:
774: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
775: Ibe_util.Debug('Order Type Id: ' ||x_order_header_rec.order_type_id);
776: END IF;
777:
778: -- Get the User's Session ORG_ID

Line 775: Ibe_util.Debug('Order Type Id: ' ||x_order_header_rec.order_type_id);

771: END IF;
772: end if; -- if order type id
773:
774: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
775: Ibe_util.Debug('Order Type Id: ' ||x_order_header_rec.order_type_id);
776: END IF;
777:
778: -- Get the User's Session ORG_ID
779: l_user_orgid := mo_global.GET_CURRENT_ORG_ID();

Line 780: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

776: END IF;
777:
778: -- Get the User's Session ORG_ID
779: l_user_orgid := mo_global.GET_CURRENT_ORG_ID();
780: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
781: Ibe_util.Debug('Current Org id : ' ||l_user_orgid);
782: END IF;
783:
784: -- Get the Sales Rep Number from the ASO Utility package

Line 781: Ibe_util.Debug('Current Org id : ' ||l_user_orgid);

777:
778: -- Get the User's Session ORG_ID
779: l_user_orgid := mo_global.GET_CURRENT_ORG_ID();
780: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
781: Ibe_util.Debug('Current Org id : ' ||l_user_orgid);
782: END IF;
783:
784: -- Get the Sales Rep Number from the ASO Utility package
785: l_salesrep_number := ASO_UTILITY_PVT.GET_OU_ATTRIBUTE_VALUE(aso_utility_pvt.GET_DEFAULT_SALESREP,l_user_orgid);

Line 786: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

782: END IF;
783:
784: -- Get the Sales Rep Number from the ASO Utility package
785: l_salesrep_number := ASO_UTILITY_PVT.GET_OU_ATTRIBUTE_VALUE(aso_utility_pvt.GET_DEFAULT_SALESREP,l_user_orgid);
786: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
787: Ibe_util.Debug('Sales Rep Number for Current Org : ' ||l_salesrep_number);
788: END IF;
789: -- Bug 5255625, Proper error message when default salesrep is not set
790: IF (l_salesrep_number is null) THEN

Line 787: Ibe_util.Debug('Sales Rep Number for Current Org : ' ||l_salesrep_number);

783:
784: -- Get the Sales Rep Number from the ASO Utility package
785: l_salesrep_number := ASO_UTILITY_PVT.GET_OU_ATTRIBUTE_VALUE(aso_utility_pvt.GET_DEFAULT_SALESREP,l_user_orgid);
786: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
787: Ibe_util.Debug('Sales Rep Number for Current Org : ' ||l_salesrep_number);
788: END IF;
789: -- Bug 5255625, Proper error message when default salesrep is not set
790: IF (l_salesrep_number is null) THEN
791: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_SALESREPID_MISS');

Line 799: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

795: -- Get the sales rep id from the sales rep number using the JTF table
796: select SALESREP_ID into l_salesrep_id from JTF_RS_SALESREPS where SALESREP_NUMBER = l_salesrep_number and ORG_ID = l_user_orgid;
797: END IF;
798:
799: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
800: Ibe_util.Debug('Sales Rep Id : ' ||l_salesrep_id);
801: END IF;
802: --l_salesrep_id := FND_PROFILE.VALUE('ASO_DEFAULT_PERSON_ID');
803:

Line 800: Ibe_util.Debug('Sales Rep Id : ' ||l_salesrep_id);

796: select SALESREP_ID into l_salesrep_id from JTF_RS_SALESREPS where SALESREP_NUMBER = l_salesrep_number and ORG_ID = l_user_orgid;
797: END IF;
798:
799: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
800: Ibe_util.Debug('Sales Rep Id : ' ||l_salesrep_id);
801: END IF;
802: --l_salesrep_id := FND_PROFILE.VALUE('ASO_DEFAULT_PERSON_ID');
803:
804: IF (l_salesrep_id is null) THEN

Line 813: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

809: x_order_header_rec.salesrep_id := l_salesrep_id;
810: END IF;
811: x_order_header_rec.source_document_type_id := 13; -- iStore Account
812:
813: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
814: Ibe_util.Debug('OM::Get_Code_Release_Level: ' ||OE_CODE_CONTROL.Get_Code_Release_Level);
815: END IF;
816:
817: l_preApprove_prof := FND_PROFILE.VALUE('IBE_ENABLE_RETURN_PREBOOK');

Line 814: Ibe_util.Debug('OM::Get_Code_Release_Level: ' ||OE_CODE_CONTROL.Get_Code_Release_Level);

810: END IF;
811: x_order_header_rec.source_document_type_id := 13; -- iStore Account
812:
813: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
814: Ibe_util.Debug('OM::Get_Code_Release_Level: ' ||OE_CODE_CONTROL.Get_Code_Release_Level);
815: END IF;
816:
817: l_preApprove_prof := FND_PROFILE.VALUE('IBE_ENABLE_RETURN_PREBOOK');
818: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 818: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

814: Ibe_util.Debug('OM::Get_Code_Release_Level: ' ||OE_CODE_CONTROL.Get_Code_Release_Level);
815: END IF;
816:
817: l_preApprove_prof := FND_PROFILE.VALUE('IBE_ENABLE_RETURN_PREBOOK');
818: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
819: Ibe_util.Debug('Enable Pre-Approval Profile value: ' ||l_preApprove_prof);
820: END IF;
821:
822: IF (x_order_header_rec.order_category_code = 'RETURN' AND

Line 819: Ibe_util.Debug('Enable Pre-Approval Profile value: ' ||l_preApprove_prof);

815: END IF;
816:
817: l_preApprove_prof := FND_PROFILE.VALUE('IBE_ENABLE_RETURN_PREBOOK');
818: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
819: Ibe_util.Debug('Enable Pre-Approval Profile value: ' ||l_preApprove_prof);
820: END IF;
821:
822: IF (x_order_header_rec.order_category_code = 'RETURN' AND
823: OE_CODE_CONTROL.Get_Code_Release_Level > '110509' AND

Line 840: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

836: -- and the user tries to create a return without sending active pending return's HeaderId
837: -- in oe_order_header_rec.header_id. So here defaulting should be done from existing active pending
838: -- return's header record.
839:
840: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
841: IBE_Util.Debug('Inside Header Record update defaulting flow');
842: END IF;
843: x_order_header_rec.header_id := l_order_header_id;
844: open c_defaulthdr_rec(l_order_header_id);

Line 841: IBE_Util.Debug('Inside Header Record update defaulting flow');

837: -- in oe_order_header_rec.header_id. So here defaulting should be done from existing active pending
838: -- return's header record.
839:
840: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
841: IBE_Util.Debug('Inside Header Record update defaulting flow');
842: END IF;
843: x_order_header_rec.header_id := l_order_header_id;
844: open c_defaulthdr_rec(l_order_header_id);
845: fetch c_defaulthdr_rec into l_ordertype_id;

Line 856: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

852: x_order_header_rec.operation := OE_Globals.G_OPR_UPDATE;
853:
854: END IF; -- if order_header_id
855:
856: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
857: Ibe_util.Debug('Operation: ' ||x_order_header_rec.operation);
858: END IF;
859:
860: ELSIF (x_order_header_rec.ORDER_CATEGORY_CODE) = 'ORDER' OR (x_order_header_rec.ORDER_CATEGORY_CODE) = 'MIXED'

Line 857: Ibe_util.Debug('Operation: ' ||x_order_header_rec.operation);

853:
854: END IF; -- if order_header_id
855:
856: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
857: Ibe_util.Debug('Operation: ' ||x_order_header_rec.operation);
858: END IF;
859:
860: ELSIF (x_order_header_rec.ORDER_CATEGORY_CODE) = 'ORDER' OR (x_order_header_rec.ORDER_CATEGORY_CODE) = 'MIXED'
861: THEN

Line 866: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

862: -- For future enhancements.
863: null;
864: END IF; --IF ORDER_CATEG_CODE
865:
866: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
867: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultHeaderRecord');
868: END IF;
869:
870: END DefaultHeaderRecord;

Line 867: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultHeaderRecord');

863: null;
864: END IF; --IF ORDER_CATEG_CODE
865:
866: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
867: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultHeaderRecord');
868: END IF;
869:
870: END DefaultHeaderRecord;
871:

Line 887: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

883: l_order_category_code VARCHAR2(30);
884:
885: BEGIN
886:
887: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
888: Ibe_util.Debug('Begin IBE_Order_Save_Pvt.CancelOrder');
889: END IF;
890:
891: x_order_header_rec := p_order_header_rec;

Line 888: Ibe_util.Debug('Begin IBE_Order_Save_Pvt.CancelOrder');

884:
885: BEGIN
886:
887: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
888: Ibe_util.Debug('Begin IBE_Order_Save_Pvt.CancelOrder');
889: END IF;
890:
891: x_order_header_rec := p_order_header_rec;
892:

Line 900: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

896: x_order_header_rec.FLOW_STATUS_CODE := l_header_rec.FLOW_STATUS_CODE;
897: x_order_header_rec.ORDER_CATEGORY_CODE := l_header_rec.ORDER_CATEGORY_CODE;
898: end loop;
899:
900: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
901: Ibe_util.Debug('CancelOrder - FLOW_STATUS_CODE: '||x_order_header_rec.FLOW_STATUS_CODE);
902: Ibe_util.Debug('CancelOrder - ORDER_CATEGORY_CODE: '||x_order_header_rec.ORDER_CATEGORY_CODE);
903: END IF;
904:

Line 901: Ibe_util.Debug('CancelOrder - FLOW_STATUS_CODE: '||x_order_header_rec.FLOW_STATUS_CODE);

897: x_order_header_rec.ORDER_CATEGORY_CODE := l_header_rec.ORDER_CATEGORY_CODE;
898: end loop;
899:
900: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
901: Ibe_util.Debug('CancelOrder - FLOW_STATUS_CODE: '||x_order_header_rec.FLOW_STATUS_CODE);
902: Ibe_util.Debug('CancelOrder - ORDER_CATEGORY_CODE: '||x_order_header_rec.ORDER_CATEGORY_CODE);
903: END IF;
904:
905: IF (x_order_header_rec.FLOW_STATUS_CODE in ('ENTERED','WORKING') AND

Line 902: Ibe_util.Debug('CancelOrder - ORDER_CATEGORY_CODE: '||x_order_header_rec.ORDER_CATEGORY_CODE);

898: end loop;
899:
900: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
901: Ibe_util.Debug('CancelOrder - FLOW_STATUS_CODE: '||x_order_header_rec.FLOW_STATUS_CODE);
902: Ibe_util.Debug('CancelOrder - ORDER_CATEGORY_CODE: '||x_order_header_rec.ORDER_CATEGORY_CODE);
903: END IF;
904:
905: IF (x_order_header_rec.FLOW_STATUS_CODE in ('ENTERED','WORKING') AND
906: x_order_header_rec.ORDER_CATEGORY_CODE = 'RETURN') THEN

Line 920: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

916:
917: END IF;
918:
919:
920: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
921: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:CancelOrder');
922: END IF;
923:
924: END CancelOrder;

Line 921: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:CancelOrder');

917: END IF;
918:
919:
920: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
921: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:CancelOrder');
922: END IF;
923:
924: END CancelOrder;
925:

Line 959: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

955: l_party_id NUMBER;
956:
957: BEGIN
958:
959: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
960: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress');
961: end if;
962:
963: -- Initialize API return status to success

Line 960: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress');

956:
957: BEGIN
958:
959: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
960: Ibe_util.Debug('Begin IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress');
961: end if;
962:
963: -- Initialize API return status to success
964: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 974: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

970: loop
971: x_order_line_tbl(lineIdx) := p_order_line_tbl(lineIdx);
972: end loop;
973:
974: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
975: Ibe_util.Debug('Inside DefaultHdrLineAddress party_id' ||p_party_id);
976: END IF;
977:
978: OPEN c_party_type(p_party_id);

Line 975: Ibe_util.Debug('Inside DefaultHdrLineAddress party_id' ||p_party_id);

971: x_order_line_tbl(lineIdx) := p_order_line_tbl(lineIdx);
972: end loop;
973:
974: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
975: Ibe_util.Debug('Inside DefaultHdrLineAddress party_id' ||p_party_id);
976: END IF;
977:
978: OPEN c_party_type(p_party_id);
979: FETCH c_party_type into l_party_type;

Line 981: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

977:
978: OPEN c_party_type(p_party_id);
979: FETCH c_party_type into l_party_type;
980: CLOSE c_party_type;
981: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
982: Ibe_util.Debug('DefaultHdrLineAddress l_party_type'||l_party_type);
983: END IF;
984:
985: -- No need to default any address for line level because OE always

Line 982: Ibe_util.Debug('DefaultHdrLineAddress l_party_type'||l_party_type);

978: OPEN c_party_type(p_party_id);
979: FETCH c_party_type into l_party_type;
980: CLOSE c_party_type;
981: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
982: Ibe_util.Debug('DefaultHdrLineAddress l_party_type'||l_party_type);
983: END IF;
984:
985: -- No need to default any address for line level because OE always
986: -- override the values at line level referencing from original order lines.

Line 1021: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1017: ,x_msg_data => x_msg_data
1018: ,x_msg_count => x_msg_count
1019: );
1020:
1021: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1022: Ibe_util.Debug('DefaultHdrLineAddress: After call to Get_Cust_Acct_Site_Use-ShipTO '||x_return_status);
1023: END IF;
1024:
1025:

Line 1022: Ibe_util.Debug('DefaultHdrLineAddress: After call to Get_Cust_Acct_Site_Use-ShipTO '||x_return_status);

1018: ,x_msg_count => x_msg_count
1019: );
1020:
1021: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1022: Ibe_util.Debug('DefaultHdrLineAddress: After call to Get_Cust_Acct_Site_Use-ShipTO '||x_return_status);
1023: END IF;
1024:
1025:
1026: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN

Line 1033: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1029: FND_Msg_Pub.Add;
1030: RAISE FND_API.G_EXC_ERROR;
1031: END IF;
1032:
1033: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1034: Ibe_util.Debug('DefaultHdrLineAddress: '||lx_header_siteuse_id);
1035: END IF;
1036:
1037: IF (lx_header_siteuse_id is not null AND lx_header_siteuse_id <> FND_API.G_MISS_NUM)

Line 1034: Ibe_util.Debug('DefaultHdrLineAddress: '||lx_header_siteuse_id);

1030: RAISE FND_API.G_EXC_ERROR;
1031: END IF;
1032:
1033: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1034: Ibe_util.Debug('DefaultHdrLineAddress: '||lx_header_siteuse_id);
1035: END IF;
1036:
1037: IF (lx_header_siteuse_id is not null AND lx_header_siteuse_id <> FND_API.G_MISS_NUM)
1038: THEN

Line 1057: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1053: x_order_header_rec.ship_to_org_id := lx_header_siteuse_id;
1054: ELSE
1055:
1056:
1057: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1058: Ibe_util.Debug('DefaultHdrLineAddress: Final Attempt- Ship To');
1059: END IF;
1060:
1061: -- If final attempt also fails, no other go, Raise An Exception

Line 1058: Ibe_util.Debug('DefaultHdrLineAddress: Final Attempt- Ship To');

1054: ELSE
1055:
1056:
1057: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1058: Ibe_util.Debug('DefaultHdrLineAddress: Final Attempt- Ship To');
1059: END IF;
1060:
1061: -- If final attempt also fails, no other go, Raise An Exception
1062: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_SHIPTO_ADDR');

Line 1091: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1087: ,x_msg_count => x_msg_count
1088: );
1089:
1090:
1091: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1092: Ibe_util.Debug('DefaultHdrLineAddress: After call to Get_Cust_Acct_Site_Use-BillTO '||x_return_status);
1093: END IF;
1094:
1095: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN

Line 1092: Ibe_util.Debug('DefaultHdrLineAddress: After call to Get_Cust_Acct_Site_Use-BillTO '||x_return_status);

1088: );
1089:
1090:
1091: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1092: Ibe_util.Debug('DefaultHdrLineAddress: After call to Get_Cust_Acct_Site_Use-BillTO '||x_return_status);
1093: END IF;
1094:
1095: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
1096: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_BILLTO_ADDR');

Line 1120: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1116: THEN
1117: x_order_header_rec.invoice_to_org_id := lx_header_siteuse_id;
1118: ELSE
1119: -- If final attempt also fails, no other go,Raise An Exception
1120: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1121: Ibe_util.Debug('DefaultHdrLineAddress: Final Attempt- Bill To');
1122: END IF;
1123:
1124: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_BILLTO_ADDR');

Line 1121: Ibe_util.Debug('DefaultHdrLineAddress: Final Attempt- Bill To');

1117: x_order_header_rec.invoice_to_org_id := lx_header_siteuse_id;
1118: ELSE
1119: -- If final attempt also fails, no other go,Raise An Exception
1120: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1121: Ibe_util.Debug('DefaultHdrLineAddress: Final Attempt- Bill To');
1122: END IF;
1123:
1124: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_BILLTO_ADDR');
1125: FND_Msg_Pub.Add;

Line 1137: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1133: FND_Msg_Pub.Add;
1134: RAISE FND_API.G_EXC_ERROR;
1135: END IF;
1136:
1137: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1138: Ibe_util.Debug('DefaultHdrLineAddress ship_to_org_id: ' || x_order_header_rec.ship_to_org_id);
1139: Ibe_util.Debug('DefaultHdrLineAddress bill_to_org_id: ' || x_order_header_rec.invoice_to_org_id);
1140: END IF;
1141:

Line 1138: Ibe_util.Debug('DefaultHdrLineAddress ship_to_org_id: ' || x_order_header_rec.ship_to_org_id);

1134: RAISE FND_API.G_EXC_ERROR;
1135: END IF;
1136:
1137: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1138: Ibe_util.Debug('DefaultHdrLineAddress ship_to_org_id: ' || x_order_header_rec.ship_to_org_id);
1139: Ibe_util.Debug('DefaultHdrLineAddress bill_to_org_id: ' || x_order_header_rec.invoice_to_org_id);
1140: END IF;
1141:
1142: /**************** B2C LineLevel *******************/

Line 1139: Ibe_util.Debug('DefaultHdrLineAddress bill_to_org_id: ' || x_order_header_rec.invoice_to_org_id);

1135: END IF;
1136:
1137: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1138: Ibe_util.Debug('DefaultHdrLineAddress ship_to_org_id: ' || x_order_header_rec.ship_to_org_id);
1139: Ibe_util.Debug('DefaultHdrLineAddress bill_to_org_id: ' || x_order_header_rec.invoice_to_org_id);
1140: END IF;
1141:
1142: /**************** B2C LineLevel *******************/
1143:

Line 1206: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1202: x_order_header_rec.invoice_to_contact_id := l_cust_acct_role_id;
1203: END IF;
1204: end if;
1205:
1206: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1207: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress');
1208: END IF;
1209:
1210: FND_MSG_PUB.Count_And_Get

Line 1207: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress');

1203: END IF;
1204: end if;
1205:
1206: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1207: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress');
1208: END IF;
1209:
1210: FND_MSG_PUB.Count_And_Get
1211: ( p_count => x_msg_count,

Line 1221: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1217: x_return_status := FND_API.G_RET_STS_ERROR;
1218: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
1219: p_count => x_msg_count ,
1220: p_data => x_msg_data);
1221: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1222: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()'|| sqlerrm);
1223: END IF;
1224:
1225: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

Line 1222: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()'|| sqlerrm);

1218: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
1219: p_count => x_msg_count ,
1220: p_data => x_msg_data);
1221: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1222: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()'|| sqlerrm);
1223: END IF;
1224:
1225: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
1226: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 1230: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1226: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1227: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
1228: p_count => x_msg_count ,
1229: p_data => x_msg_data);
1230: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1231: IBE_Util.Debug('UNEXPError IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()' || sqlerrm);
1232: END IF;
1233:
1234: WHEN OTHERS THEN

Line 1231: IBE_Util.Debug('UNEXPError IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()' || sqlerrm);

1227: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
1228: p_count => x_msg_count ,
1229: p_data => x_msg_data);
1230: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1231: IBE_Util.Debug('UNEXPError IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()' || sqlerrm);
1232: END IF;
1233:
1234: WHEN OTHERS THEN
1235: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 1244: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1240:
1241: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
1242: p_count => x_msg_count ,
1243: p_data => x_msg_data);
1244: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1245: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()' || sqlerrm);
1246: END IF;
1247:
1248: END DefaultHdrLineAddress;

Line 1245: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()' || sqlerrm);

1241: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
1242: p_count => x_msg_count ,
1243: p_data => x_msg_data);
1244: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1245: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:DefaultHdrLineAddress()' || sqlerrm);
1246: END IF;
1247:
1248: END DefaultHdrLineAddress;
1249:

Line 1280: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1276: lineid_tmp lineid_type;
1277:
1278: BEGIN
1279:
1280: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1281: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1282: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);
1283: END IF;
1284:

Line 1281: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');

1277:
1278: BEGIN
1279:
1280: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1281: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1282: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);
1283: END IF;
1284:
1285: for i in 1..p_order_line_tbl.count

Line 1282: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);

1278: BEGIN
1279:
1280: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1281: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1282: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);
1283: END IF;
1284:
1285: for i in 1..p_order_line_tbl.count
1286: loop

Line 1309: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1305: -- J
1306: -- Uncommenting all the above lines since the bug has been fixed by OM as per Bug# 3336052
1307: -- Prereq for this is ONT.J
1308:
1309: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1310: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1311: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);
1312: END IF;
1313:

Line 1310: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');

1306: -- Uncommenting all the above lines since the bug has been fixed by OM as per Bug# 3336052
1307: -- Prereq for this is ONT.J
1308:
1309: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1310: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1311: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);
1312: END IF;
1313:
1314: l_shipto_org_id := p_order_header_rec.ship_to_org_id; --Bug# 3334581

Line 1311: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);

1307: -- Prereq for this is ONT.J
1308:
1309: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1310: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1311: IBE_Util.Debug('setlineshipinvoiceids invoicetoorgid: '|| p_order_header_rec.invoice_to_org_id);
1312: END IF;
1313:
1314: l_shipto_org_id := p_order_header_rec.ship_to_org_id; --Bug# 3334581
1315: l_invoiceto_org_id := p_order_header_rec.invoice_to_org_id;

Line 1317: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1313:
1314: l_shipto_org_id := p_order_header_rec.ship_to_org_id; --Bug# 3334581
1315: l_invoiceto_org_id := p_order_header_rec.invoice_to_org_id;
1316:
1317: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1318: IBE_Util.Debug('Order header_id: '|| p_order_header_rec.header_id);
1319: END IF;
1320:
1321: for l_get_hdr_ids in c_get_hdr_ids(p_order_header_rec.header_id)

Line 1318: IBE_Util.Debug('Order header_id: '|| p_order_header_rec.header_id);

1314: l_shipto_org_id := p_order_header_rec.ship_to_org_id; --Bug# 3334581
1315: l_invoiceto_org_id := p_order_header_rec.invoice_to_org_id;
1316:
1317: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1318: IBE_Util.Debug('Order header_id: '|| p_order_header_rec.header_id);
1319: END IF;
1320:
1321: for l_get_hdr_ids in c_get_hdr_ids(p_order_header_rec.header_id)
1322: loop

Line 1350: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1346: -- fetch line ids NOT IN the set from oe_order_lines _all
1347: -- basically to update the other existing lines also.
1348:
1349: l_linetbl_count := l_order_line_tbl.count;
1350: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1351: IBE_Util.Debug('No. of lines to be updated: '|| l_linetbl_count);
1352: END IF;
1353:
1354: for lineIdx in 1..l_order_line_tbl.count

Line 1351: IBE_Util.Debug('No. of lines to be updated: '|| l_linetbl_count);

1347: -- basically to update the other existing lines also.
1348:
1349: l_linetbl_count := l_order_line_tbl.count;
1350: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1351: IBE_Util.Debug('No. of lines to be updated: '|| l_linetbl_count);
1352: END IF;
1353:
1354: for lineIdx in 1..l_order_line_tbl.count
1355: loop

Line 1359: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1355: loop
1356: p_lineids_set := p_lineids_set || ','|| l_order_line_tbl(lineIdx).line_id;
1357: end loop;
1358:
1359: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1360: IBE_Util.Debug('Line Ids to be parsed: '|| p_lineids_set);
1361: END IF;
1362:
1363: IBE_LEAD_IMPORT_PVT.parseInput (p_lineids_set, 'CHAR', l_parseKey, l_parseNum, l_all_lineids_query);

Line 1360: IBE_Util.Debug('Line Ids to be parsed: '|| p_lineids_set);

1356: p_lineids_set := p_lineids_set || ','|| l_order_line_tbl(lineIdx).line_id;
1357: end loop;
1358:
1359: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1360: IBE_Util.Debug('Line Ids to be parsed: '|| p_lineids_set);
1361: END IF;
1362:
1363: IBE_LEAD_IMPORT_PVT.parseInput (p_lineids_set, 'CHAR', l_parseKey, l_parseNum, l_all_lineids_query);
1364:

Line 1365: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1361: END IF;
1362:
1363: IBE_LEAD_IMPORT_PVT.parseInput (p_lineids_set, 'CHAR', l_parseKey, l_parseNum, l_all_lineids_query);
1364:
1365: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1366: IBE_Util.Debug('After calling Lead_Import package');
1367: END IF;
1368:
1369: l_linetmp_qry := 'select line_id from oe_order_lines_all '||

Line 1366: IBE_Util.Debug('After calling Lead_Import package');

1362:
1363: IBE_LEAD_IMPORT_PVT.parseInput (p_lineids_set, 'CHAR', l_parseKey, l_parseNum, l_all_lineids_query);
1364:
1365: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1366: IBE_Util.Debug('After calling Lead_Import package');
1367: END IF;
1368:
1369: l_linetmp_qry := 'select line_id from oe_order_lines_all '||
1370: 'where header_id= :1 and '||

Line 1373: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1369: l_linetmp_qry := 'select line_id from oe_order_lines_all '||
1370: 'where header_id= :1 and '||
1371: 'line_id NOT IN('|| l_all_lineids_query ||')';
1372:
1373: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1374: IBE_Util.Debug('Line qry to be executed: '|| l_linetmp_qry);
1375: END IF;
1376:
1377: open lineid_tmp for l_linetmp_qry using p_order_header_rec.header_id,l_parseKey;

Line 1374: IBE_Util.Debug('Line qry to be executed: '|| l_linetmp_qry);

1370: 'where header_id= :1 and '||
1371: 'line_id NOT IN('|| l_all_lineids_query ||')';
1372:
1373: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1374: IBE_Util.Debug('Line qry to be executed: '|| l_linetmp_qry);
1375: END IF;
1376:
1377: open lineid_tmp for l_linetmp_qry using p_order_header_rec.header_id,l_parseKey;
1378: loop

Line 1381: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1377: open lineid_tmp for l_linetmp_qry using p_order_header_rec.header_id,l_parseKey;
1378: loop
1379: fetch lineid_tmp into l_lineid;
1380: exit when lineid_tmp%notfound;
1381: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1382: IBE_Util.debug('line id from line: '|| l_lineid);
1383: end if;
1384: l_linetbl_count := l_linetbl_count +1;
1385: l_order_line_tbl(l_linetbl_count) := OE_Order_PUB.G_MISS_LINE_REC;

Line 1382: IBE_Util.debug('line id from line: '|| l_lineid);

1378: loop
1379: fetch lineid_tmp into l_lineid;
1380: exit when lineid_tmp%notfound;
1381: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1382: IBE_Util.debug('line id from line: '|| l_lineid);
1383: end if;
1384: l_linetbl_count := l_linetbl_count +1;
1385: l_order_line_tbl(l_linetbl_count) := OE_Order_PUB.G_MISS_LINE_REC;
1386: l_order_line_tbl(l_linetbl_count).line_id := l_lineid;

Line 1399: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1395: loop
1396: x_order_line_tbl(j) := l_order_line_tbl(j);
1397: end loop;
1398:
1399: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1400: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1401: END IF;
1402:
1403: END SetLineShipInvoiceIds;

Line 1400: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:setlineshipinvoiceids');

1396: x_order_line_tbl(j) := l_order_line_tbl(j);
1397: end loop;
1398:
1399: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1400: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:setlineshipinvoiceids');
1401: END IF;
1402:
1403: END SetLineShipInvoiceIds;
1404:

Line 1461: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1457: l_line_type VARCHAR2(30) := '';
1458:
1459: BEGIN
1460:
1461: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1462: IBE_Util.Debug('OE_Order_Save_PVT.SaveMDLRelatedOperations -BEGIN');
1463: IBE_Util.Debug('p_context_type - p_save_type: ' ||p_context_type ||' :: '||p_save_type);
1464: END IF;
1465:

Line 1462: IBE_Util.Debug('OE_Order_Save_PVT.SaveMDLRelatedOperations -BEGIN');

1458:
1459: BEGIN
1460:
1461: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1462: IBE_Util.Debug('OE_Order_Save_PVT.SaveMDLRelatedOperations -BEGIN');
1463: IBE_Util.Debug('p_context_type - p_save_type: ' ||p_context_type ||' :: '||p_save_type);
1464: END IF;
1465:
1466: for i in 1.. p_order_line_tbl.COUNT

Line 1463: IBE_Util.Debug('p_context_type - p_save_type: ' ||p_context_type ||' :: '||p_save_type);

1459: BEGIN
1460:
1461: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1462: IBE_Util.Debug('OE_Order_Save_PVT.SaveMDLRelatedOperations -BEGIN');
1463: IBE_Util.Debug('p_context_type - p_save_type: ' ||p_context_type ||' :: '||p_save_type);
1464: END IF;
1465:
1466: for i in 1.. p_order_line_tbl.COUNT
1467: loop

Line 1472: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1468: l_order_line_tbl(i) := p_order_line_tbl(i);
1469: end loop;
1470:
1471: l_linetbl_count := (l_order_line_tbl.count);
1472: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1473: IBE_Util.Debug('l_linetbl_count: '||l_linetbl_count);
1474: END IF;
1475:
1476: if p_context_type = 'SAVE' and p_save_type =SAVE_REMOVEITEMS then

Line 1473: IBE_Util.Debug('l_linetbl_count: '||l_linetbl_count);

1469: end loop;
1470:
1471: l_linetbl_count := (l_order_line_tbl.count);
1472: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1473: IBE_Util.Debug('l_linetbl_count: '||l_linetbl_count);
1474: END IF;
1475:
1476: if p_context_type = 'SAVE' and p_save_type =SAVE_REMOVEITEMS then
1477: for i in 1..l_order_line_tbl.count

Line 1480: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1476: if p_context_type = 'SAVE' and p_save_type =SAVE_REMOVEITEMS then
1477: for i in 1..l_order_line_tbl.count
1478: loop
1479:
1480: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1481: IBE_Util.Debug('item_type_code: ' || l_order_line_tbl(i).item_type_code);
1482: END IF;
1483:
1484: if (l_order_line_tbl(i).ITEM_TYPE_CODE IN ('MODEL','KIT'))

Line 1481: IBE_Util.Debug('item_type_code: ' || l_order_line_tbl(i).item_type_code);

1477: for i in 1..l_order_line_tbl.count
1478: loop
1479:
1480: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1481: IBE_Util.Debug('item_type_code: ' || l_order_line_tbl(i).item_type_code);
1482: END IF;
1483:
1484: if (l_order_line_tbl(i).ITEM_TYPE_CODE IN ('MODEL','KIT'))
1485: then

Line 1486: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1482: END IF;
1483:
1484: if (l_order_line_tbl(i).ITEM_TYPE_CODE IN ('MODEL','KIT'))
1485: then
1486: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1487: IBE_Util.Debug('Inside MDL check loop');
1488: END IF;
1489: for l_childlineid_rec in l_childlineid_cur(l_order_line_tbl(i).LINE_ID,p_order_header_id)
1490: loop

Line 1487: IBE_Util.Debug('Inside MDL check loop');

1483:
1484: if (l_order_line_tbl(i).ITEM_TYPE_CODE IN ('MODEL','KIT'))
1485: then
1486: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1487: IBE_Util.Debug('Inside MDL check loop');
1488: END IF;
1489: for l_childlineid_rec in l_childlineid_cur(l_order_line_tbl(i).LINE_ID,p_order_header_id)
1490: loop
1491: l_linetbl_count := l_linetbl_count+1;

Line 1505: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1501:
1502: for i in 1..l_order_line_tbl.count
1503: loop
1504:
1505: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1506: IBE_Util.Debug('item_type_code: ' || l_order_line_tbl(i).item_type_code);
1507: END IF;
1508:
1509: if (l_order_line_tbl(i).item_type_code IN ('MODEL','KIT'))

Line 1506: IBE_Util.Debug('item_type_code: ' || l_order_line_tbl(i).item_type_code);

1502: for i in 1..l_order_line_tbl.count
1503: loop
1504:
1505: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1506: IBE_Util.Debug('item_type_code: ' || l_order_line_tbl(i).item_type_code);
1507: END IF;
1508:
1509: if (l_order_line_tbl(i).item_type_code IN ('MODEL','KIT'))
1510: then

Line 1515: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1511: for l_tmpparent_rec in l_tmpparent_cur(l_order_line_tbl(i).LINE_ID)
1512: loop
1513: l_origparent_qty :=l_tmpparent_rec.ORDERED_QUANTITY;
1514: end loop;
1515: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1516: IBE_Util.Debug('l_origparent_qty: ' || l_origparent_qty);
1517: END IF;
1518:
1519: for l_childlineid_rec in l_childlineid_cur(l_order_line_tbl(i).LINE_ID,p_order_header_id)

Line 1516: IBE_Util.Debug('l_origparent_qty: ' || l_origparent_qty);

1512: loop
1513: l_origparent_qty :=l_tmpparent_rec.ORDERED_QUANTITY;
1514: end loop;
1515: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1516: IBE_Util.Debug('l_origparent_qty: ' || l_origparent_qty);
1517: END IF;
1518:
1519: for l_childlineid_rec in l_childlineid_cur(l_order_line_tbl(i).LINE_ID,p_order_header_id)
1520: loop

Line 1530: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1526: if(l_order_line_tbl(i).ORDERED_QUANTITY is not null
1527: AND l_order_line_tbl(i).ORDERED_QUANTITY <> FND_API.G_MISS_NUM)
1528: then
1529: l_new_qty := l_order_line_tbl(i).ORDERED_QUANTITY;
1530: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1531: IBE_Util.Debug('Incoming qty: ' || l_new_qty);
1532: END IF;
1533: l_origchild_qty := l_childlineid_rec.ORDERED_QUANTITY;
1534: IF (l_origparent_qty = 0) THEN

Line 1531: IBE_Util.Debug('Incoming qty: ' || l_new_qty);

1527: AND l_order_line_tbl(i).ORDERED_QUANTITY <> FND_API.G_MISS_NUM)
1528: then
1529: l_new_qty := l_order_line_tbl(i).ORDERED_QUANTITY;
1530: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1531: IBE_Util.Debug('Incoming qty: ' || l_new_qty);
1532: END IF;
1533: l_origchild_qty := l_childlineid_rec.ORDERED_QUANTITY;
1534: IF (l_origparent_qty = 0) THEN
1535: l_order_line_tbl(l_linetbl_count).ORDERED_QUANTITY

Line 1566: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1562: loop
1563: l_line_type := c_linetmp_rec.ITEM_TYPE_CODE;
1564: end loop;
1565:
1566: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1567: IBE_Util.Debug('l_line_type: ' || l_line_type);
1568: END IF;
1569:
1570: -- if model item then propagate contactIds and OrgIds to all children

Line 1567: IBE_Util.Debug('l_line_type: ' || l_line_type);

1563: l_line_type := c_linetmp_rec.ITEM_TYPE_CODE;
1564: end loop;
1565:
1566: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1567: IBE_Util.Debug('l_line_type: ' || l_line_type);
1568: END IF;
1569:
1570: -- if model item then propagate contactIds and OrgIds to all children
1571: if (l_line_type IN ('MODEL','KIT')) then

Line 1605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1601:
1602: end loop; --main for loop
1603: end if; --main if
1604:
1605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1606: IBE_Util.Debug('l_order_line_tbl.count: '||l_order_line_tbl.count);
1607: END IF;
1608:
1609: for k in 1..l_order_line_tbl.count

Line 1606: IBE_Util.Debug('l_order_line_tbl.count: '||l_order_line_tbl.count);

1602: end loop; --main for loop
1603: end if; --main if
1604:
1605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1606: IBE_Util.Debug('l_order_line_tbl.count: '||l_order_line_tbl.count);
1607: END IF;
1608:
1609: for k in 1..l_order_line_tbl.count
1610: loop

Line 1613: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1609: for k in 1..l_order_line_tbl.count
1610: loop
1611: x_order_line_tbl(k) := l_order_line_tbl(k);
1612: x_order_line_tbl(k).item_type_code := FND_API.G_MISS_CHAR;
1613: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1614: IBE_Util.Debug('x_order_line_tbl.LineId: ' || x_order_line_tbl(k).LINE_ID);
1615: IBE_Util.Debug('x_order_line_tbl.orderd_qty: ' || x_order_line_tbl(k).ORDERED_QUANTITY);
1616: IBE_Util.Debug('x_order_line_tbl.reason_code: ' || x_order_line_tbl(k).RETURN_REASON_CODE);
1617: IBE_Util.Debug('x_order_line_tbl.invoice contact: ' || x_order_line_tbl(k).INVOICE_TO_CONTACT_ID);

Line 1614: IBE_Util.Debug('x_order_line_tbl.LineId: ' || x_order_line_tbl(k).LINE_ID);

1610: loop
1611: x_order_line_tbl(k) := l_order_line_tbl(k);
1612: x_order_line_tbl(k).item_type_code := FND_API.G_MISS_CHAR;
1613: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1614: IBE_Util.Debug('x_order_line_tbl.LineId: ' || x_order_line_tbl(k).LINE_ID);
1615: IBE_Util.Debug('x_order_line_tbl.orderd_qty: ' || x_order_line_tbl(k).ORDERED_QUANTITY);
1616: IBE_Util.Debug('x_order_line_tbl.reason_code: ' || x_order_line_tbl(k).RETURN_REASON_CODE);
1617: IBE_Util.Debug('x_order_line_tbl.invoice contact: ' || x_order_line_tbl(k).INVOICE_TO_CONTACT_ID);
1618: IBE_Util.Debug('x_order_line_tbl.invoice org: ' || x_order_line_tbl(k).INVOICE_TO_ORG_ID);

Line 1615: IBE_Util.Debug('x_order_line_tbl.orderd_qty: ' || x_order_line_tbl(k).ORDERED_QUANTITY);

1611: x_order_line_tbl(k) := l_order_line_tbl(k);
1612: x_order_line_tbl(k).item_type_code := FND_API.G_MISS_CHAR;
1613: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1614: IBE_Util.Debug('x_order_line_tbl.LineId: ' || x_order_line_tbl(k).LINE_ID);
1615: IBE_Util.Debug('x_order_line_tbl.orderd_qty: ' || x_order_line_tbl(k).ORDERED_QUANTITY);
1616: IBE_Util.Debug('x_order_line_tbl.reason_code: ' || x_order_line_tbl(k).RETURN_REASON_CODE);
1617: IBE_Util.Debug('x_order_line_tbl.invoice contact: ' || x_order_line_tbl(k).INVOICE_TO_CONTACT_ID);
1618: IBE_Util.Debug('x_order_line_tbl.invoice org: ' || x_order_line_tbl(k).INVOICE_TO_ORG_ID);
1619: END IF;

Line 1616: IBE_Util.Debug('x_order_line_tbl.reason_code: ' || x_order_line_tbl(k).RETURN_REASON_CODE);

1612: x_order_line_tbl(k).item_type_code := FND_API.G_MISS_CHAR;
1613: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1614: IBE_Util.Debug('x_order_line_tbl.LineId: ' || x_order_line_tbl(k).LINE_ID);
1615: IBE_Util.Debug('x_order_line_tbl.orderd_qty: ' || x_order_line_tbl(k).ORDERED_QUANTITY);
1616: IBE_Util.Debug('x_order_line_tbl.reason_code: ' || x_order_line_tbl(k).RETURN_REASON_CODE);
1617: IBE_Util.Debug('x_order_line_tbl.invoice contact: ' || x_order_line_tbl(k).INVOICE_TO_CONTACT_ID);
1618: IBE_Util.Debug('x_order_line_tbl.invoice org: ' || x_order_line_tbl(k).INVOICE_TO_ORG_ID);
1619: END IF;
1620: end loop;

Line 1617: IBE_Util.Debug('x_order_line_tbl.invoice contact: ' || x_order_line_tbl(k).INVOICE_TO_CONTACT_ID);

1613: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1614: IBE_Util.Debug('x_order_line_tbl.LineId: ' || x_order_line_tbl(k).LINE_ID);
1615: IBE_Util.Debug('x_order_line_tbl.orderd_qty: ' || x_order_line_tbl(k).ORDERED_QUANTITY);
1616: IBE_Util.Debug('x_order_line_tbl.reason_code: ' || x_order_line_tbl(k).RETURN_REASON_CODE);
1617: IBE_Util.Debug('x_order_line_tbl.invoice contact: ' || x_order_line_tbl(k).INVOICE_TO_CONTACT_ID);
1618: IBE_Util.Debug('x_order_line_tbl.invoice org: ' || x_order_line_tbl(k).INVOICE_TO_ORG_ID);
1619: END IF;
1620: end loop;
1621:

Line 1618: IBE_Util.Debug('x_order_line_tbl.invoice org: ' || x_order_line_tbl(k).INVOICE_TO_ORG_ID);

1614: IBE_Util.Debug('x_order_line_tbl.LineId: ' || x_order_line_tbl(k).LINE_ID);
1615: IBE_Util.Debug('x_order_line_tbl.orderd_qty: ' || x_order_line_tbl(k).ORDERED_QUANTITY);
1616: IBE_Util.Debug('x_order_line_tbl.reason_code: ' || x_order_line_tbl(k).RETURN_REASON_CODE);
1617: IBE_Util.Debug('x_order_line_tbl.invoice contact: ' || x_order_line_tbl(k).INVOICE_TO_CONTACT_ID);
1618: IBE_Util.Debug('x_order_line_tbl.invoice org: ' || x_order_line_tbl(k).INVOICE_TO_ORG_ID);
1619: END IF;
1620: end loop;
1621:
1622: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 1622: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1618: IBE_Util.Debug('x_order_line_tbl.invoice org: ' || x_order_line_tbl(k).INVOICE_TO_ORG_ID);
1619: END IF;
1620: end loop;
1621:
1622: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1623: IBE_Util.Debug('OE_Order_Save_PVT.SaveMDLRelatedOperations -END');
1624: END IF;
1625:
1626: END SaveMDLRelatedOperations;

Line 1623: IBE_Util.Debug('OE_Order_Save_PVT.SaveMDLRelatedOperations -END');

1619: END IF;
1620: end loop;
1621:
1622: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1623: IBE_Util.Debug('OE_Order_Save_PVT.SaveMDLRelatedOperations -END');
1624: END IF;
1625:
1626: END SaveMDLRelatedOperations;
1627:

Line 1642: IF (IBE_UTIL.G_DEBUGON = l_true) then

1638: l_db_user_id NUMBER;
1639:
1640: BEGIN
1641:
1642: IF (IBE_UTIL.G_DEBUGON = l_true) then
1643: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - BEGIN');
1644: IBE_UTIL.DEBUG('User id obtained from environment is: '||l_env_user_id);
1645: IBE_UTIL.DEBUG('Incoming Header Id: '||p_order_header_id);
1646: END IF;

Line 1643: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - BEGIN');

1639:
1640: BEGIN
1641:
1642: IF (IBE_UTIL.G_DEBUGON = l_true) then
1643: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - BEGIN');
1644: IBE_UTIL.DEBUG('User id obtained from environment is: '||l_env_user_id);
1645: IBE_UTIL.DEBUG('Incoming Header Id: '||p_order_header_id);
1646: END IF;
1647:

Line 1644: IBE_UTIL.DEBUG('User id obtained from environment is: '||l_env_user_id);

1640: BEGIN
1641:
1642: IF (IBE_UTIL.G_DEBUGON = l_true) then
1643: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - BEGIN');
1644: IBE_UTIL.DEBUG('User id obtained from environment is: '||l_env_user_id);
1645: IBE_UTIL.DEBUG('Incoming Header Id: '||p_order_header_id);
1646: END IF;
1647:
1648: -- Initialize API return status to success

Line 1645: IBE_UTIL.DEBUG('Incoming Header Id: '||p_order_header_id);

1641:
1642: IF (IBE_UTIL.G_DEBUGON = l_true) then
1643: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - BEGIN');
1644: IBE_UTIL.DEBUG('User id obtained from environment is: '||l_env_user_id);
1645: IBE_UTIL.DEBUG('Incoming Header Id: '||p_order_header_id);
1646: END IF;
1647:
1648: -- Initialize API return status to success
1649: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 1655: IF (IBE_UTIL.G_DEBUGON = l_true) then

1651: open c_createdby_info(p_order_header_id);
1652: fetch c_createdby_info into l_db_user_id;
1653: close c_createdby_info;
1654:
1655: IF (IBE_UTIL.G_DEBUGON = l_true) then
1656: IBE_UTIL.DEBUG('User id obtained from db is: '|| l_db_user_id);
1657: END IF;
1658:
1659: IF (l_db_user_id <> l_env_user_id)

Line 1656: IBE_UTIL.DEBUG('User id obtained from db is: '|| l_db_user_id);

1652: fetch c_createdby_info into l_db_user_id;
1653: close c_createdby_info;
1654:
1655: IF (IBE_UTIL.G_DEBUGON = l_true) then
1656: IBE_UTIL.DEBUG('User id obtained from db is: '|| l_db_user_id);
1657: END IF;
1658:
1659: IF (l_db_user_id <> l_env_user_id)
1660: THEN

Line 1661: IF (IBE_UTIL.G_DEBUGON = l_true) then

1657: END IF;
1658:
1659: IF (l_db_user_id <> l_env_user_id)
1660: THEN
1661: IF (IBE_UTIL.G_DEBUGON = l_true) then
1662: IBE_UTIL.DEBUG('Inside If');
1663: END IF;
1664: FND_Message.Set_Name('IBE', 'IBE_OT_ERR_USERACCESS');
1665: FND_Msg_Pub.Add;

Line 1662: IBE_UTIL.DEBUG('Inside If');

1658:
1659: IF (l_db_user_id <> l_env_user_id)
1660: THEN
1661: IF (IBE_UTIL.G_DEBUGON = l_true) then
1662: IBE_UTIL.DEBUG('Inside If');
1663: END IF;
1664: FND_Message.Set_Name('IBE', 'IBE_OT_ERR_USERACCESS');
1665: FND_Msg_Pub.Add;
1666: RAISE FND_API.G_EXC_ERROR;

Line 1669: IF (IBE_UTIL.G_DEBUGON = l_true) then

1665: FND_Msg_Pub.Add;
1666: RAISE FND_API.G_EXC_ERROR;
1667: END IF;
1668:
1669: IF (IBE_UTIL.G_DEBUGON = l_true) then
1670: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - END');
1671: END IF;
1672:
1673: END ValidateOrderAccess;

Line 1670: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - END');

1666: RAISE FND_API.G_EXC_ERROR;
1667: END IF;
1668:
1669: IF (IBE_UTIL.G_DEBUGON = l_true) then
1670: IBE_UTIL.DEBUG('Order_Save_Pvt: ValidateOrderAccess - END');
1671: END IF;
1672:
1673: END ValidateOrderAccess;
1674:

Line 1747: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1743:
1744:
1745: BEGIN
1746:
1747: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1748: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:CheckOverReturnQty()');
1749: IBE_Util.Debug('Incoming Order Header Id: '|| p_order_header_id);
1750: END IF;
1751:

Line 1748: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:CheckOverReturnQty()');

1744:
1745: BEGIN
1746:
1747: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1748: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:CheckOverReturnQty()');
1749: IBE_Util.Debug('Incoming Order Header Id: '|| p_order_header_id);
1750: END IF;
1751:
1752: -- Initialize API return status to success

Line 1749: IBE_Util.Debug('Incoming Order Header Id: '|| p_order_header_id);

1745: BEGIN
1746:
1747: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1748: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:CheckOverReturnQty()');
1749: IBE_Util.Debug('Incoming Order Header Id: '|| p_order_header_id);
1750: END IF;
1751:
1752: -- Initialize API return status to success
1753: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 1770: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1766: -- x_error_tbl --> It maintains all the qty validation failing Line Ids
1767: -- returned from OM API call.
1768: ***********/
1769:
1770: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1771: IBE_Util.Debug('Line Ids Sent To OM for Qty Validations');
1772: END IF;
1773: OPEN QtyChkLineCur(p_order_header_id);
1774: LOOP

Line 1771: IBE_Util.Debug('Line Ids Sent To OM for Qty Validations');

1767: -- returned from OM API call.
1768: ***********/
1769:
1770: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1771: IBE_Util.Debug('Line Ids Sent To OM for Qty Validations');
1772: END IF;
1773: OPEN QtyChkLineCur(p_order_header_id);
1774: LOOP
1775: FETCH QtyChkLineCur INTO QtyChkLineRec;

Line 1778: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1774: LOOP
1775: FETCH QtyChkLineCur INTO QtyChkLineRec;
1776: EXIT WHEN QtyChkLineCur%NOTFOUND;
1777: l_order_line_tbl(lineTblCnt) := OE_Order_PUB.G_MISS_LINE_REC;
1778: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1779: IBE_Util.Debug('Line Id: '||QtyChkLineRec.LINE_ID);
1780: END IF;
1781: l_order_line_tbl(lineTblCnt).LINE_ID := QtyChkLineRec.LINE_ID;
1782: l_order_line_tbl(lineTblCnt).REFERENCE_LINE_ID := QtyChkLineRec.REFERENCE_LINE_ID;

Line 1779: IBE_Util.Debug('Line Id: '||QtyChkLineRec.LINE_ID);

1775: FETCH QtyChkLineCur INTO QtyChkLineRec;
1776: EXIT WHEN QtyChkLineCur%NOTFOUND;
1777: l_order_line_tbl(lineTblCnt) := OE_Order_PUB.G_MISS_LINE_REC;
1778: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1779: IBE_Util.Debug('Line Id: '||QtyChkLineRec.LINE_ID);
1780: END IF;
1781: l_order_line_tbl(lineTblCnt).LINE_ID := QtyChkLineRec.LINE_ID;
1782: l_order_line_tbl(lineTblCnt).REFERENCE_LINE_ID := QtyChkLineRec.REFERENCE_LINE_ID;
1783: l_order_line_tbl(lineTblCnt).ORDERED_QUANTITY := QtyChkLineRec.ORDERED_QUANTITY;

Line 1792: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1788: lineTblCnt := lineTblCnt+1;
1789: END LOOP;
1790: CLOSE QtyChkLineCur;
1791:
1792: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1793: IBE_Util.Debug('l_order_line_tbl size: '|| l_order_line_tbl.COUNT);
1794: IBE_Util.Debug('Before Calling OE_RMA_GRP.Is_Over_Return()');
1795: END IF;
1796:

Line 1793: IBE_Util.Debug('l_order_line_tbl size: '|| l_order_line_tbl.COUNT);

1789: END LOOP;
1790: CLOSE QtyChkLineCur;
1791:
1792: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1793: IBE_Util.Debug('l_order_line_tbl size: '|| l_order_line_tbl.COUNT);
1794: IBE_Util.Debug('Before Calling OE_RMA_GRP.Is_Over_Return()');
1795: END IF;
1796:
1797: OE_RMA_GRP.Is_Over_Return(p_api_version => 1.0

Line 1794: IBE_Util.Debug('Before Calling OE_RMA_GRP.Is_Over_Return()');

1790: CLOSE QtyChkLineCur;
1791:
1792: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1793: IBE_Util.Debug('l_order_line_tbl size: '|| l_order_line_tbl.COUNT);
1794: IBE_Util.Debug('Before Calling OE_RMA_GRP.Is_Over_Return()');
1795: END IF;
1796:
1797: OE_RMA_GRP.Is_Over_Return(p_api_version => 1.0
1798: , p_line_tbl => l_order_line_tbl

Line 1806: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1802: , x_msg_data => x_msg_data
1803: );
1804:
1805:
1806: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1807: IBE_Util.Debug('After Calling Is_Over_Return - return_status: '|| x_return_status);
1808: END IF;
1809:
1810: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then

Line 1807: IBE_Util.Debug('After Calling Is_Over_Return - return_status: '|| x_return_status);

1803: );
1804:
1805:
1806: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1807: IBE_Util.Debug('After Calling Is_Over_Return - return_status: '|| x_return_status);
1808: END IF;
1809:
1810: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then
1811: IF (IBE_UTIL.G_DEBUGON = l_true) then

Line 1811: IF (IBE_UTIL.G_DEBUGON = l_true) then

1807: IBE_Util.Debug('After Calling Is_Over_Return - return_status: '|| x_return_status);
1808: END IF;
1809:
1810: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then
1811: IF (IBE_UTIL.G_DEBUGON = l_true) then
1812: IBE_UTIL.DEBUG('Error Table Count: ' || x_error_tbl.count);
1813: end if;
1814:
1815: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 1812: IBE_UTIL.DEBUG('Error Table Count: ' || x_error_tbl.count);

1808: END IF;
1809:
1810: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then
1811: IF (IBE_UTIL.G_DEBUGON = l_true) then
1812: IBE_UTIL.DEBUG('Error Table Count: ' || x_error_tbl.count);
1813: end if;
1814:
1815: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1816: IBE_Util.Debug('Line Quantity Validation Details Returned from OM');

Line 1815: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1811: IF (IBE_UTIL.G_DEBUGON = l_true) then
1812: IBE_UTIL.DEBUG('Error Table Count: ' || x_error_tbl.count);
1813: end if;
1814:
1815: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1816: IBE_Util.Debug('Line Quantity Validation Details Returned from OM');
1817: ENd IF;
1818: for j in 1.. x_error_tbl.count
1819: loop

Line 1816: IBE_Util.Debug('Line Quantity Validation Details Returned from OM');

1812: IBE_UTIL.DEBUG('Error Table Count: ' || x_error_tbl.count);
1813: end if;
1814:
1815: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1816: IBE_Util.Debug('Line Quantity Validation Details Returned from OM');
1817: ENd IF;
1818: for j in 1.. x_error_tbl.count
1819: loop
1820: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 1820: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1816: IBE_Util.Debug('Line Quantity Validation Details Returned from OM');
1817: ENd IF;
1818: for j in 1.. x_error_tbl.count
1819: loop
1820: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1821: IBE_Util.Debug('line_id= '||x_error_tbl(j).line_id||' : '||
1822: 'prev_qty= '||x_error_tbl(j).previous_quantity||' : '||
1823: 'curr_qty= '||x_error_tbl(j).current_quantity||' : '||
1824: 'orig_qty= '||x_error_tbl(j).original_quantity||' : '||

Line 1821: IBE_Util.Debug('line_id= '||x_error_tbl(j).line_id||' : '||

1817: ENd IF;
1818: for j in 1.. x_error_tbl.count
1819: loop
1820: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1821: IBE_Util.Debug('line_id= '||x_error_tbl(j).line_id||' : '||
1822: 'prev_qty= '||x_error_tbl(j).previous_quantity||' : '||
1823: 'curr_qty= '||x_error_tbl(j).current_quantity||' : '||
1824: 'orig_qty= '||x_error_tbl(j).original_quantity||' : '||
1825: 'ret_stat= '||x_error_tbl(j).return_status);

Line 1830: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1826: END IF;
1827: p_tmp_error_lineIds := p_tmp_error_lineIds || ','||x_error_tbl(j).LINE_ID;
1828: end loop;
1829:
1830: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1831: Ibe_util.debug('l_tmp_error_lineIds set: '||p_tmp_error_lineIds);
1832: end if;
1833:
1834: IBE_LEAD_IMPORT_PVT.parseInput (p_tmp_error_lineIds, 'CHAR', l_parseKey, l_parseNum, l_tmp_error_lineIds);

Line 1831: Ibe_util.debug('l_tmp_error_lineIds set: '||p_tmp_error_lineIds);

1827: p_tmp_error_lineIds := p_tmp_error_lineIds || ','||x_error_tbl(j).LINE_ID;
1828: end loop;
1829:
1830: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1831: Ibe_util.debug('l_tmp_error_lineIds set: '||p_tmp_error_lineIds);
1832: end if;
1833:
1834: IBE_LEAD_IMPORT_PVT.parseInput (p_tmp_error_lineIds, 'CHAR', l_parseKey, l_parseNum, l_tmp_error_lineIds);
1835:

Line 1859: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1855: 'FROM oe_order_lines_all '||
1856: 'WHERE line_id in('||l_tmp_error_lineIds||')))';
1857:
1858:
1859: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1860: IBE_Util.debug('qry executed: '|| l_qty_tmp_query);
1861: end if;
1862:
1863: open qty_error_cur for l_qty_tmp_query using l_parseKey;

Line 1860: IBE_Util.debug('qry executed: '|| l_qty_tmp_query);

1856: 'WHERE line_id in('||l_tmp_error_lineIds||')))';
1857:
1858:
1859: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1860: IBE_Util.debug('qry executed: '|| l_qty_tmp_query);
1861: end if;
1862:
1863: open qty_error_cur for l_qty_tmp_query using l_parseKey;
1864: LOOP

Line 1868: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1864: LOOP
1865: FETCH qty_error_cur INTO l_tmp_orderNo,l_tmp_pNo,l_tmp_itemdesc,l_tmp_lineId,l_tmp_itemtype;
1866: EXIT WHEN qty_error_cur%NOTFOUND;
1867: l_tmp_order_line_tbl(l_tmp_lineTblCnt).ORIG_ORDER_LINE_ID := l_tmp_lineId;
1868: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1869: IBE_Util.debug('l_tmp_lineId: '|| l_tmp_lineId);
1870: end if;
1871: l_tmp_order_line_tbl(l_tmp_lineTblCnt).ORDERED_ITEM := l_tmp_pNo;
1872: l_tmp_order_line_tbl(l_tmp_lineTblCnt).ORDER_NUMBER := l_tmp_orderNo;

Line 1869: IBE_Util.debug('l_tmp_lineId: '|| l_tmp_lineId);

1865: FETCH qty_error_cur INTO l_tmp_orderNo,l_tmp_pNo,l_tmp_itemdesc,l_tmp_lineId,l_tmp_itemtype;
1866: EXIT WHEN qty_error_cur%NOTFOUND;
1867: l_tmp_order_line_tbl(l_tmp_lineTblCnt).ORIG_ORDER_LINE_ID := l_tmp_lineId;
1868: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1869: IBE_Util.debug('l_tmp_lineId: '|| l_tmp_lineId);
1870: end if;
1871: l_tmp_order_line_tbl(l_tmp_lineTblCnt).ORDERED_ITEM := l_tmp_pNo;
1872: l_tmp_order_line_tbl(l_tmp_lineTblCnt).ORDER_NUMBER := l_tmp_orderNo;
1873: l_tmp_order_line_tbl(l_tmp_lineTblCnt).ITEM_TYPE_CODE := l_tmp_itemtype;

Line 1915: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1911: -- For instance, l_tmp_order_line_tbl --> ModParentId1 and
1912: -- x_error_tbl --> ChldId1,ChldId2.
1913: -- To identify such flows l_errorflow var is introduced.
1914:
1915: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1916: IBE_Util.debug('ibe:temp Err and OM:error Table Counts: '|| l_tmp_order_line_tbl.count|| ' , '||x_error_tbl.count);
1917: end if;
1918:
1919: ---- New Changes for sorting in sync w/ UI

Line 1916: IBE_Util.debug('ibe:temp Err and OM:error Table Counts: '|| l_tmp_order_line_tbl.count|| ' , '||x_error_tbl.count);

1912: -- x_error_tbl --> ChldId1,ChldId2.
1913: -- To identify such flows l_errorflow var is introduced.
1914:
1915: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1916: IBE_Util.debug('ibe:temp Err and OM:error Table Counts: '|| l_tmp_order_line_tbl.count|| ' , '||x_error_tbl.count);
1917: end if;
1918:
1919: ---- New Changes for sorting in sync w/ UI
1920: -- Setting the Quantity details as this is needed for STD item Error Message.

Line 1938: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1934: END LOOP;
1935: l_tmp_index1:=l_tmp_order_line_tbl.NEXT(l_tmp_index1);
1936: END LOOP;
1937:
1938: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1939: IBE_Util.debug('After retrieving the quantity details for the failing lineids from OM error table');
1940: end if;
1941:
1942: /*** Now start to Append the FND stack having the original Plsql table sent to

Line 1939: IBE_Util.debug('After retrieving the quantity details for the failing lineids from OM error table');

1935: l_tmp_index1:=l_tmp_order_line_tbl.NEXT(l_tmp_index1);
1936: END LOOP;
1937:
1938: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1939: IBE_Util.debug('After retrieving the quantity details for the failing lineids from OM error table');
1940: end if;
1941:
1942: /*** Now start to Append the FND stack having the original Plsql table sent to
1943: OM, for qty validations, as

Line 1957: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1953: IF (l_tmp_order_line_tbl(l_index2).item_type_code='STANDARD') then
1954: tempQty := (l_tmp_order_line_tbl(l_index2).orig_ordered_qty) -
1955: (l_tmp_order_line_tbl(l_index2).already_return_qty);
1956:
1957: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1958: IBE_Util.debug('STD-Item: Fails for Qty: Order#='||l_tmp_order_line_tbl(l_index2).order_number
1959: ||' : '||trim(l_tmp_order_line_tbl(l_index2).description)||' : '
1960: ||'allowed Qty = '||tempQty);
1961: end if;

Line 1958: IBE_Util.debug('STD-Item: Fails for Qty: Order#='||l_tmp_order_line_tbl(l_index2).order_number

1954: tempQty := (l_tmp_order_line_tbl(l_index2).orig_ordered_qty) -
1955: (l_tmp_order_line_tbl(l_index2).already_return_qty);
1956:
1957: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1958: IBE_Util.debug('STD-Item: Fails for Qty: Order#='||l_tmp_order_line_tbl(l_index2).order_number
1959: ||' : '||trim(l_tmp_order_line_tbl(l_index2).description)||' : '
1960: ||'allowed Qty = '||tempQty);
1961: end if;
1962: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_LINE_OVER_QTY');

Line 1970: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

1966: FND_MESSAGE.Set_Token('QTY', tempQty);
1967: FND_Msg_Pub.Add;
1968:
1969: ELSIF(l_tmp_order_line_tbl(l_index2).item_type_code IN ('MODEL','KIT')) then
1970: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1971: IBE_Util.debug('MDL-Item: Fails for Qty: Order#='||l_tmp_order_line_tbl(l_index2).order_number||
1972: ' : '||trim(l_tmp_order_line_tbl(l_index2).description));
1973: end if;
1974: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_MDL_LINE_OVER_QTY');

Line 1971: IBE_Util.debug('MDL-Item: Fails for Qty: Order#='||l_tmp_order_line_tbl(l_index2).order_number||

1967: FND_Msg_Pub.Add;
1968:
1969: ELSIF(l_tmp_order_line_tbl(l_index2).item_type_code IN ('MODEL','KIT')) then
1970: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
1971: IBE_Util.debug('MDL-Item: Fails for Qty: Order#='||l_tmp_order_line_tbl(l_index2).order_number||
1972: ' : '||trim(l_tmp_order_line_tbl(l_index2).description));
1973: end if;
1974: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_MDL_LINE_OVER_QTY');
1975: FND_MESSAGE.Set_Token('ORD', l_tmp_order_line_tbl(l_index2).order_number);

Line 2017: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2013:
2014: FND_MSG_PUB.Count_And_Get ( p_count => x_msg_count,
2015: p_data => x_msg_data);
2016:
2017: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2018: IBE_Util.Debug('End OE_ORDER_SAVE_PVT.CheckReturnQty()');
2019: END IF;
2020:
2021:

Line 2018: IBE_Util.Debug('End OE_ORDER_SAVE_PVT.CheckReturnQty()');

2014: FND_MSG_PUB.Count_And_Get ( p_count => x_msg_count,
2015: p_data => x_msg_data);
2016:
2017: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2018: IBE_Util.Debug('End OE_ORDER_SAVE_PVT.CheckReturnQty()');
2019: END IF;
2020:
2021:
2022: EXCEPTION

Line 2029: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2025: x_return_status := FND_API.G_RET_STS_ERROR;
2026: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2027: p_count => x_msg_count ,
2028: p_data => x_msg_data);
2029: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2030: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:CheckOverReturnQty()'|| sqlerrm);
2031: END IF;
2032:
2033: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

Line 2030: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:CheckOverReturnQty()'|| sqlerrm);

2026: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2027: p_count => x_msg_count ,
2028: p_data => x_msg_data);
2029: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2030: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:CheckOverReturnQty()'|| sqlerrm);
2031: END IF;
2032:
2033: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
2034: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 2038: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2034: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2035: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2036: p_count => x_msg_count ,
2037: p_data => x_msg_data);
2038: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2039: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:CheckOverReturnQty()' || sqlerrm);
2040: END IF;
2041: WHEN OTHERS THEN
2042: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 2039: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:CheckOverReturnQty()' || sqlerrm);

2035: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2036: p_count => x_msg_count ,
2037: p_data => x_msg_data);
2038: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2039: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:CheckOverReturnQty()' || sqlerrm);
2040: END IF;
2041: WHEN OTHERS THEN
2042: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2043:

Line 2052: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2048:
2049: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2050: p_count => x_msg_count ,
2051: p_data => x_msg_data);
2052: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2053: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:CheckOverReturnQty()' || sqlerrm);
2054: END IF;
2055:
2056: END CheckOverReturnQty;

Line 2053: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:CheckOverReturnQty()' || sqlerrm);

2049: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2050: p_count => x_msg_count ,
2051: p_data => x_msg_data);
2052: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2053: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:CheckOverReturnQty()' || sqlerrm);
2054: END IF;
2055:
2056: END CheckOverReturnQty;
2057:

Line 2085: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2081: BEGIN
2082:
2083: x_return_status := FND_API.G_RET_STS_SUCCESS;
2084:
2085: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2086: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN order_hdr_id: '||p_order_header_id);
2087: end if;
2088:
2089: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2086: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN order_hdr_id: '||p_order_header_id);

2082:
2083: x_return_status := FND_API.G_RET_STS_SUCCESS;
2084:
2085: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2086: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN order_hdr_id: '||p_order_header_id);
2087: end if;
2088:
2089: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2090: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN site_use_type : '||p_site_use_type);

Line 2089: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2085: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2086: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN order_hdr_id: '||p_order_header_id);
2087: end if;
2088:
2089: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2090: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN site_use_type : '||p_site_use_type);
2091: end if;
2092:
2093:

Line 2090: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN site_use_type : '||p_site_use_type);

2086: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN order_hdr_id: '||p_order_header_id);
2087: end if;
2088:
2089: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2090: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN site_use_type : '||p_site_use_type);
2091: end if;
2092:
2093:
2094: if(p_user_type = 'PARTY_RELATIONSHIP') then

Line 2188: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2184: 'and status=''A'')';
2185: end if; -- if p_site_use_type
2186: end if; -- p_user_type
2187:
2188: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2189: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);
2190: end if;
2191: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2192: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);

Line 2189: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);

2185: end if; -- if p_site_use_type
2186: end if; -- p_user_type
2187:
2188: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2189: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);
2190: end if;
2191: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2192: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);
2193: end if;

Line 2191: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2187:
2188: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2189: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);
2190: end if;
2191: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2192: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);
2193: end if;
2194:
2195: open Addr_error_cur for l_addr_validate_qry using p_order_header_id;

Line 2192: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);

2188: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2189: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);
2190: end if;
2191: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2192: IBE_Util.debug('Qry executed for Address validation: '||l_addr_validate_qry);
2193: end if;
2194:
2195: open Addr_error_cur for l_addr_validate_qry using p_order_header_id;
2196: loop

Line 2203: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2199: tmpCount := tmpCount+1;
2200: FailLines := FND_API.G_TRUE;
2201: end loop;
2202:
2203: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2204: IBE_Util.debug('Check whether any lines failed: '||FailLines);
2205: end if;
2206:
2207: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2204: IBE_Util.debug('Check whether any lines failed: '||FailLines);

2200: FailLines := FND_API.G_TRUE;
2201: end loop;
2202:
2203: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2204: IBE_Util.debug('Check whether any lines failed: '||FailLines);
2205: end if;
2206:
2207: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2208: IBE_Util.debug('Check whether any lines failed: '||FailLines);

Line 2207: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2203: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2204: IBE_Util.debug('Check whether any lines failed: '||FailLines);
2205: end if;
2206:
2207: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2208: IBE_Util.debug('Check whether any lines failed: '||FailLines);
2209: end if;
2210:
2211: if(FND_API.to_boolean(FailLines)) then

Line 2208: IBE_Util.debug('Check whether any lines failed: '||FailLines);

2204: IBE_Util.debug('Check whether any lines failed: '||FailLines);
2205: end if;
2206:
2207: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2208: IBE_Util.debug('Check whether any lines failed: '||FailLines);
2209: end if;
2210:
2211: if(FND_API.to_boolean(FailLines)) then
2212: x_return_status := FND_API.G_RET_STS_ERROR;

Line 2230: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2226: if(p_site_use_type='SHIP_TO' AND p_user_type = 'PERSON') then
2227: X_failed_line_ids(failCnt) := 'SHIPADDR:HDR';
2228: end if;
2229: l_index:=l_tmpfail_line_id.NEXT(l_index);
2230: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2231: IBE_Util.debug('Line ID Failed for Addr: '|| X_failed_line_ids(failCnt));
2232: end if;
2233: end loop;
2234: end if;

Line 2231: IBE_Util.debug('Line ID Failed for Addr: '|| X_failed_line_ids(failCnt));

2227: X_failed_line_ids(failCnt) := 'SHIPADDR:HDR';
2228: end if;
2229: l_index:=l_tmpfail_line_id.NEXT(l_index);
2230: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2231: IBE_Util.debug('Line ID Failed for Addr: '|| X_failed_line_ids(failCnt));
2232: end if;
2233: end loop;
2234: end if;
2235:

Line 2236: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2232: end if;
2233: end loop;
2234: end if;
2235:
2236: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2237: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate END '||x_return_status);
2238: end if;
2239:
2240:

Line 2237: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate END '||x_return_status);

2233: end loop;
2234: end if;
2235:
2236: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2237: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate END '||x_return_status);
2238: end if;
2239:
2240:
2241: END TCA_AddressValidate;

Line 2269: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2265: BEGIN
2266:
2267: x_return_status := FND_API.G_RET_STS_SUCCESS;
2268:
2269: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2270: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN');
2271: end if;
2272:
2273: if (p_site_use_type ='BILL_TO') then

Line 2270: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN');

2266:
2267: x_return_status := FND_API.G_RET_STS_SUCCESS;
2268:
2269: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2270: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate BEGIN');
2271: end if;
2272:
2273: if (p_site_use_type ='BILL_TO') then
2274: l_contact_validate_qry:='SELECT LINES.LINE_ID '||

Line 2306: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2302: 'AND ACCT_ROLE.STATUS = ''I''';
2303:
2304: end if; -- if p_site_use_type
2305:
2306: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2307: IBE_Util.debug('Contact Query Executed: '||l_contact_validate_qry);
2308: end if;
2309:
2310: open Contact_error_cur for l_contact_validate_qry using p_order_header_id;

Line 2307: IBE_Util.debug('Contact Query Executed: '||l_contact_validate_qry);

2303:
2304: end if; -- if p_site_use_type
2305:
2306: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2307: IBE_Util.debug('Contact Query Executed: '||l_contact_validate_qry);
2308: end if;
2309:
2310: open Contact_error_cur for l_contact_validate_qry using p_order_header_id;
2311: loop

Line 2318: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2314: tmpCount := tmpCount+1;
2315: FailLines := FND_API.G_TRUE;
2316: end loop;
2317:
2318: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2319: IBE_Util.debug('Whether Any Lines failed for Contact check: '|| FailLines);
2320: end if;
2321:
2322: if(FND_API.to_boolean(FailLines)) then

Line 2319: IBE_Util.debug('Whether Any Lines failed for Contact check: '|| FailLines);

2315: FailLines := FND_API.G_TRUE;
2316: end loop;
2317:
2318: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2319: IBE_Util.debug('Whether Any Lines failed for Contact check: '|| FailLines);
2320: end if;
2321:
2322: if(FND_API.to_boolean(FailLines)) then
2323: x_return_status := FND_API.G_RET_STS_ERROR;

Line 2336: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2332: X_failed_line_ids(failCnt) := 'SHIPCTNT:'||l_tmpfail_line_id(l_index);
2333: end if;
2334: l_index:=l_tmpfail_line_id.NEXT(l_index);
2335: end loop;
2336: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2337: IBE_Util.debug('Line Id failed for Contact check: '|| X_failed_line_ids(failCnt));
2338: end if;
2339: end if;
2340:

Line 2337: IBE_Util.debug('Line Id failed for Contact check: '|| X_failed_line_ids(failCnt));

2333: end if;
2334: l_index:=l_tmpfail_line_id.NEXT(l_index);
2335: end loop;
2336: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2337: IBE_Util.debug('Line Id failed for Contact check: '|| X_failed_line_ids(failCnt));
2338: end if;
2339: end if;
2340:
2341: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2341: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2337: IBE_Util.debug('Line Id failed for Contact check: '|| X_failed_line_ids(failCnt));
2338: end if;
2339: end if;
2340:
2341: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2342: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate END '||x_return_status);
2343: end if;
2344:
2345: END TCA_ContactValidate;

Line 2342: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate END '||x_return_status);

2338: end if;
2339: end if;
2340:
2341: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2342: IBE_Util.debug('IBE_Order_Save_Pvt.TCA_AddressValidate END '||x_return_status);
2343: end if;
2344:
2345: END TCA_ContactValidate;
2346:

Line 2383: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2379:
2380:
2381: BEGIN
2382:
2383: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2384: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:Complete_RetLine_Validation()');
2385: END IF;
2386:
2387: X_failed_line_ids := JTF_VARCHAR2_TABLE_300();

Line 2384: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:Complete_RetLine_Validation()');

2380:
2381: BEGIN
2382:
2383: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2384: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:Complete_RetLine_Validation()');
2385: END IF;
2386:
2387: X_failed_line_ids := JTF_VARCHAR2_TABLE_300();
2388:

Line 2405: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2401:
2402:
2403:
2404:
2405: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2406: IBE_Util.Debug('Before calling TCA_AddressValidate for billto: ');
2407: END IF;
2408:
2409: TCA_AddressValidate(p_order_header_id => p_order_header_id,

Line 2406: IBE_Util.Debug('Before calling TCA_AddressValidate for billto: ');

2402:
2403:
2404:
2405: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2406: IBE_Util.Debug('Before calling TCA_AddressValidate for billto: ');
2407: END IF;
2408:
2409: TCA_AddressValidate(p_order_header_id => p_order_header_id,
2410: p_user_type => p_user_type,

Line 2416: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2412: X_failed_line_ids => x_TCAfail_LineIds,
2413: x_return_status => l_return_status
2414: );
2415:
2416: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2417: IBE_Util.Debug('After calling TCA_AddressValidate Billto: '||l_return_status);
2418: END IF;
2419:
2420: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

Line 2417: IBE_Util.Debug('After calling TCA_AddressValidate Billto: '||l_return_status);

2413: x_return_status => l_return_status
2414: );
2415:
2416: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2417: IBE_Util.Debug('After calling TCA_AddressValidate Billto: '||l_return_status);
2418: END IF;
2419:
2420: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
2421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2417: IBE_Util.Debug('After calling TCA_AddressValidate Billto: '||l_return_status);
2418: END IF;
2419:
2420: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
2421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2422: IBE_Util.Debug('Address Failing Line count Billto:'|| x_TCAfail_LineIds.count);
2423: END IF;
2424: tCount := X_failed_line_ids.count;
2425: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;

Line 2422: IBE_Util.Debug('Address Failing Line count Billto:'|| x_TCAfail_LineIds.count);

2418: END IF;
2419:
2420: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
2421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2422: IBE_Util.Debug('Address Failing Line count Billto:'|| x_TCAfail_LineIds.count);
2423: END IF;
2424: tCount := X_failed_line_ids.count;
2425: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;
2426:

Line 2435: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2431: X_failed_line_ids(tCount) := x_TCAfail_LineIds(TCAFailLineCnt);
2432: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2433: end loop;
2434:
2435: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2436: IBE_Util.Debug('Total failLine Ids in Addr Loop Bill to: '|| X_failed_line_ids.count);
2437: for k in 1..X_failed_line_ids.count
2438: loop
2439: IBE_Util.Debug('Total failLine Ids in Addr Loop Billto: '|| X_failed_line_ids(k));

Line 2436: IBE_Util.Debug('Total failLine Ids in Addr Loop Bill to: '|| X_failed_line_ids.count);

2432: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2433: end loop;
2434:
2435: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2436: IBE_Util.Debug('Total failLine Ids in Addr Loop Bill to: '|| X_failed_line_ids.count);
2437: for k in 1..X_failed_line_ids.count
2438: loop
2439: IBE_Util.Debug('Total failLine Ids in Addr Loop Billto: '|| X_failed_line_ids(k));
2440: end loop;

Line 2439: IBE_Util.Debug('Total failLine Ids in Addr Loop Billto: '|| X_failed_line_ids(k));

2435: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2436: IBE_Util.Debug('Total failLine Ids in Addr Loop Bill to: '|| X_failed_line_ids.count);
2437: for k in 1..X_failed_line_ids.count
2438: loop
2439: IBE_Util.Debug('Total failLine Ids in Addr Loop Billto: '|| X_failed_line_ids(k));
2440: end loop;
2441: END IF;
2442:
2443:

Line 2458: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2454: X_failed_line_ids => x_TCAfail_LineIds,
2455: x_return_status => ll_return_status
2456: );
2457:
2458: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2459: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2460: END IF;
2461: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2462: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2459: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);

2455: x_return_status => ll_return_status
2456: );
2457:
2458: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2459: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2460: END IF;
2461: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2462: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2463: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);

Line 2462: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2458: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2459: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2460: END IF;
2461: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2462: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2463: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);
2464: END IF;
2465: tCount := X_failed_line_ids.count;
2466: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;

Line 2463: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);

2459: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2460: END IF;
2461: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2462: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2463: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);
2464: END IF;
2465: tCount := X_failed_line_ids.count;
2466: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;
2467:

Line 2476: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2472: X_failed_line_ids(tCount) := x_TCAfail_LineIds(TCAFailLineCnt);
2473: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2474: end loop;
2475:
2476: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2477: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);
2478: for k in 1..X_failed_line_ids.count
2479: loop
2480: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));

Line 2477: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);

2473: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2474: end loop;
2475:
2476: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2477: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);
2478: for k in 1..X_failed_line_ids.count
2479: loop
2480: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));
2481: end loop;

Line 2480: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));

2476: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2477: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);
2478: for k in 1..X_failed_line_ids.count
2479: loop
2480: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));
2481: end loop;
2482: END IF;
2483:
2484: end if;

Line 2491: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2487: Set the Message if either the contact or address is invalid
2488: */
2489: if(l_return_status =FND_API.G_RET_STS_ERROR
2490: OR ll_return_status =FND_API.G_RET_STS_ERROR) then
2491: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2492: IBE_Util.Debug('Invalid Billing Details- Settig the Error to FND stack');
2493: END IF;
2494: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_INVALID_BILLDET');
2495: FND_Msg_Pub.Add;

Line 2492: IBE_Util.Debug('Invalid Billing Details- Settig the Error to FND stack');

2488: */
2489: if(l_return_status =FND_API.G_RET_STS_ERROR
2490: OR ll_return_status =FND_API.G_RET_STS_ERROR) then
2491: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2492: IBE_Util.Debug('Invalid Billing Details- Settig the Error to FND stack');
2493: END IF;
2494: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_INVALID_BILLDET');
2495: FND_Msg_Pub.Add;
2496: end if;

Line 2498: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2494: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_INVALID_BILLDET');
2495: FND_Msg_Pub.Add;
2496: end if;
2497:
2498: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2499: IBE_Util.Debug('Before calling TCA_AddressValidate: BILL_TO');
2500: END IF;
2501:
2502: -- For Ship To Contact and Address Validation

Line 2499: IBE_Util.Debug('Before calling TCA_AddressValidate: BILL_TO');

2495: FND_Msg_Pub.Add;
2496: end if;
2497:
2498: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2499: IBE_Util.Debug('Before calling TCA_AddressValidate: BILL_TO');
2500: END IF;
2501:
2502: -- For Ship To Contact and Address Validation
2503: TCA_AddressValidate(p_order_header_id => p_order_header_id,

Line 2510: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2506: X_failed_line_ids => x_TCAfail_LineIds,
2507: x_return_status => l_return_status
2508: );
2509:
2510: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2511: IBE_Util.Debug('After calling TCA_AddressValidate Ship to: '||l_return_status);
2512: END IF;
2513:
2514: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

Line 2511: IBE_Util.Debug('After calling TCA_AddressValidate Ship to: '||l_return_status);

2507: x_return_status => l_return_status
2508: );
2509:
2510: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2511: IBE_Util.Debug('After calling TCA_AddressValidate Ship to: '||l_return_status);
2512: END IF;
2513:
2514: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
2515: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2515: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2511: IBE_Util.Debug('After calling TCA_AddressValidate Ship to: '||l_return_status);
2512: END IF;
2513:
2514: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
2515: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2516: IBE_Util.Debug('Address Failing Line count Shipto:'|| x_TCAfail_LineIds.count);
2517: END IF;
2518: tCount := X_failed_line_ids.count;
2519: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;

Line 2516: IBE_Util.Debug('Address Failing Line count Shipto:'|| x_TCAfail_LineIds.count);

2512: END IF;
2513:
2514: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
2515: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2516: IBE_Util.Debug('Address Failing Line count Shipto:'|| x_TCAfail_LineIds.count);
2517: END IF;
2518: tCount := X_failed_line_ids.count;
2519: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;
2520:

Line 2529: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2525: X_failed_line_ids(tCount) := x_TCAfail_LineIds(TCAFailLineCnt);
2526: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2527: end loop;
2528:
2529: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2530: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids.count);
2531: for k in 1..X_failed_line_ids.count
2532: loop
2533: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids(k));

Line 2530: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids.count);

2526: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2527: end loop;
2528:
2529: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2530: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids.count);
2531: for k in 1..X_failed_line_ids.count
2532: loop
2533: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids(k));
2534: end loop;

Line 2533: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids(k));

2529: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2530: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids.count);
2531: for k in 1..X_failed_line_ids.count
2532: loop
2533: IBE_Util.Debug('Total failLine Ids in Addr Loop:Shipto '|| X_failed_line_ids(k));
2534: end loop;
2535: END IF;
2536:
2537:

Line 2546: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2542: X_failed_line_ids => x_TCAfail_LineIds,
2543: x_return_status => ll_return_status
2544: );
2545:
2546: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2547: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2548: END IF;
2549: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2550: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2547: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);

2543: x_return_status => ll_return_status
2544: );
2545:
2546: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2547: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2548: END IF;
2549: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2550: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2551: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);

Line 2550: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2546: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2547: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2548: END IF;
2549: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2550: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2551: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);
2552: END IF;
2553: tCount := X_failed_line_ids.count;
2554: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;

Line 2551: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);

2547: IBE_Util.Debug('After calling TCA_ContactValidate: '||ll_return_status);
2548: END IF;
2549: IF ll_return_status = FND_API.G_RET_STS_ERROR THEN
2550: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2551: IBE_Util.Debug('Failing Line count:'|| x_TCAfail_LineIds.count);
2552: END IF;
2553: tCount := X_failed_line_ids.count;
2554: TCAFailLineCnt := x_TCAfail_LineIds.FIRST;
2555:

Line 2564: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2560: X_failed_line_ids(tCount) := x_TCAfail_LineIds(TCAFailLineCnt);
2561: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2562: end loop;
2563:
2564: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2565: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);
2566: for k in 1..X_failed_line_ids.count
2567: loop
2568: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));

Line 2565: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);

2561: TCAFailLineCnt := x_TCAfail_LineIds.NEXT(TCAFailLineCnt);
2562: end loop;
2563:
2564: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2565: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);
2566: for k in 1..X_failed_line_ids.count
2567: loop
2568: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));
2569: end loop;

Line 2568: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));

2564: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2565: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids.count);
2566: for k in 1..X_failed_line_ids.count
2567: loop
2568: IBE_Util.Debug('Total failLine Ids in Contact Loop: '|| X_failed_line_ids(k));
2569: end loop;
2570: END IF;
2571:
2572: end if;

Line 2583: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2579:
2580:
2581: if(l_return_status =FND_API.G_RET_STS_ERROR
2582: OR ll_return_status =FND_API.G_RET_STS_ERROR) then
2583: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2584: IBE_Util.Debug('Invalid Billing Details- Settig the Error to FND stack');
2585: END IF;
2586: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_INVALID_SHIPDET');
2587: FND_Msg_Pub.Add;

Line 2584: IBE_Util.Debug('Invalid Billing Details- Settig the Error to FND stack');

2580:
2581: if(l_return_status =FND_API.G_RET_STS_ERROR
2582: OR ll_return_status =FND_API.G_RET_STS_ERROR) then
2583: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2584: IBE_Util.Debug('Invalid Billing Details- Settig the Error to FND stack');
2585: END IF;
2586: FND_MESSAGE.Set_Name('IBE','IBE_ERR_OT_INVALID_SHIPDET');
2587: FND_Msg_Pub.Add;
2588: end if;

Line 2591: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2587: FND_Msg_Pub.Add;
2588: end if;
2589:
2590:
2591: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2592: IBE_Util.Debug('Before Calling CheckOverRetQty');
2593: END IF;
2594:
2595: -- Now verify the Over Return Quantity

Line 2592: IBE_Util.Debug('Before Calling CheckOverRetQty');

2588: end if;
2589:
2590:
2591: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2592: IBE_Util.Debug('Before Calling CheckOverRetQty');
2593: END IF;
2594:
2595: -- Now verify the Over Return Quantity
2596:

Line 2605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2601: ,x_msg_count => x_msg_count
2602: ,x_msg_data => x_msg_data
2603: );
2604:
2605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2606: IBE_Util.Debug('After Calling CheckOverRetQty');
2607: END IF;
2608:
2609: IF x_return_status = FND_API.G_RET_STS_ERROR THEN

Line 2606: IBE_Util.Debug('After Calling CheckOverRetQty');

2602: ,x_msg_data => x_msg_data
2603: );
2604:
2605: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2606: IBE_Util.Debug('After Calling CheckOverRetQty');
2607: END IF;
2608:
2609: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
2610: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 2610: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2606: IBE_Util.Debug('After Calling CheckOverRetQty');
2607: END IF;
2608:
2609: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
2610: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2611: IBE_Util.Debug('No. of Lines failing after Qty validations:'|| x_qtyfail_LineIds.count);
2612: END IF;
2613: tCount := X_failed_line_ids.count;
2614: QtyFailLineCnt := x_qtyfail_LineIds.FIRST;

Line 2611: IBE_Util.Debug('No. of Lines failing after Qty validations:'|| x_qtyfail_LineIds.count);

2607: END IF;
2608:
2609: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
2610: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2611: IBE_Util.Debug('No. of Lines failing after Qty validations:'|| x_qtyfail_LineIds.count);
2612: END IF;
2613: tCount := X_failed_line_ids.count;
2614: QtyFailLineCnt := x_qtyfail_LineIds.FIRST;
2615:

Line 2624: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2620: X_failed_line_ids(tCount) := x_qtyfail_LineIds(QtyFailLineCnt);
2621: QtyFailLineCnt := x_qtyfail_LineIds.NEXT(QtyFailLineCnt);
2622: end loop;
2623:
2624: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2625: IBE_Util.Debug('Total failLine Ids In final loop: '|| X_failed_line_ids.count);
2626: for k in 1..X_failed_line_ids.count
2627: loop
2628: IBE_Util.Debug('Total failLine Ids in final Loop: '|| X_failed_line_ids(k));

Line 2625: IBE_Util.Debug('Total failLine Ids In final loop: '|| X_failed_line_ids.count);

2621: QtyFailLineCnt := x_qtyfail_LineIds.NEXT(QtyFailLineCnt);
2622: end loop;
2623:
2624: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2625: IBE_Util.Debug('Total failLine Ids In final loop: '|| X_failed_line_ids.count);
2626: for k in 1..X_failed_line_ids.count
2627: loop
2628: IBE_Util.Debug('Total failLine Ids in final Loop: '|| X_failed_line_ids(k));
2629: end loop;

Line 2628: IBE_Util.Debug('Total failLine Ids in final Loop: '|| X_failed_line_ids(k));

2624: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2625: IBE_Util.Debug('Total failLine Ids In final loop: '|| X_failed_line_ids.count);
2626: for k in 1..X_failed_line_ids.count
2627: loop
2628: IBE_Util.Debug('Total failLine Ids in final Loop: '|| X_failed_line_ids(k));
2629: end loop;
2630: END IF;
2631: ELSIF x_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
2632: raise FND_API.G_EXC_UNEXPECTED_ERROR;

Line 2635: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2631: ELSIF x_return_status = FND_API.G_RET_STS_UNEXP_ERROR THEN
2632: raise FND_API.G_EXC_UNEXPECTED_ERROR;
2633: END IF;
2634:
2635: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2636: IBE_Util.Debug('Total Failing LineCounts:'||tCount);
2637: END IF;
2638: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2639: IBE_Util.Debug(' Total Failing LineCounts:'||tCount);

Line 2636: IBE_Util.Debug('Total Failing LineCounts:'||tCount);

2632: raise FND_API.G_EXC_UNEXPECTED_ERROR;
2633: END IF;
2634:
2635: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2636: IBE_Util.Debug('Total Failing LineCounts:'||tCount);
2637: END IF;
2638: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2639: IBE_Util.Debug(' Total Failing LineCounts:'||tCount);
2640: END IF;

Line 2638: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2634:
2635: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2636: IBE_Util.Debug('Total Failing LineCounts:'||tCount);
2637: END IF;
2638: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2639: IBE_Util.Debug(' Total Failing LineCounts:'||tCount);
2640: END IF;
2641:
2642: -- If there are validation failing line IDs then set the status as ERROR.

Line 2639: IBE_Util.Debug(' Total Failing LineCounts:'||tCount);

2635: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2636: IBE_Util.Debug('Total Failing LineCounts:'||tCount);
2637: END IF;
2638: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2639: IBE_Util.Debug(' Total Failing LineCounts:'||tCount);
2640: END IF;
2641:
2642: -- If there are validation failing line IDs then set the status as ERROR.
2643:

Line 2648: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2644: IF (X_failed_line_ids.count > 0) THEN
2645: raise FND_API.G_EXC_ERROR;
2646: ENd IF;
2647:
2648: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2649: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate');
2650: END IF;
2651:
2652: FND_MSG_PUB.Count_And_Get

Line 2649: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate');

2645: raise FND_API.G_EXC_ERROR;
2646: ENd IF;
2647:
2648: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2649: Ibe_util.Debug('End IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate');
2650: END IF;
2651:
2652: FND_MSG_PUB.Count_And_Get
2653: ( p_count => x_msg_count,

Line 2663: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2659: x_return_status := FND_API.G_RET_STS_ERROR;
2660: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2661: p_count => x_msg_count ,
2662: p_data => x_msg_data);
2663: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2664: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()'|| sqlerrm);
2665: END IF;
2666:
2667: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

Line 2664: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()'|| sqlerrm);

2660: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2661: p_count => x_msg_count ,
2662: p_data => x_msg_data);
2663: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2664: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()'|| sqlerrm);
2665: END IF;
2666:
2667: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
2668: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 2672: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2668: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2669: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2670: p_count => x_msg_count ,
2671: p_data => x_msg_data);
2672: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2673: IBE_Util.Debug('UNEXPError IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()' || sqlerrm);
2674: END IF;
2675:
2676: WHEN OTHERS THEN

Line 2673: IBE_Util.Debug('UNEXPError IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()' || sqlerrm);

2669: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2670: p_count => x_msg_count ,
2671: p_data => x_msg_data);
2672: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2673: IBE_Util.Debug('UNEXPError IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()' || sqlerrm);
2674: END IF;
2675:
2676: WHEN OTHERS THEN
2677: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 2686: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2682:
2683: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2684: p_count => x_msg_count ,
2685: p_data => x_msg_data);
2686: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2687: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()' || sqlerrm);
2688: END IF;
2689:
2690: END Complete_RetOrder_Validate;

Line 2687: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()' || sqlerrm);

2683: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
2684: p_count => x_msg_count ,
2685: p_data => x_msg_data);
2686: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2687: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:Complete_RetOrder_Validate()' || sqlerrm);
2688: END IF;
2689:
2690: END Complete_RetOrder_Validate;
2691:

Line 2793: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2789: --X_failed_line_ids JTF_VARCHAR2_TABLE_300;
2790: /******/
2791: BEGIN
2792:
2793: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2794: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:Save(): ' || p_save_type);
2795: END IF;
2796:
2797:

Line 2794: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:Save(): ' || p_save_type);

2790: /******/
2791: BEGIN
2792:
2793: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2794: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:Save(): ' || p_save_type);
2795: END IF;
2796:
2797:
2798: -- Standard Start of API savepoint

Line 2826: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2822:
2823: l_order_header_rec := p_order_header_rec;
2824:
2825:
2826: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2827: IBE_Util.Debug('Begin p_order_header_rec' ||p_order_header_rec.header_id ||'::'|| p_party_id);
2828: END IF;
2829:
2830: -- Call Default Header Record

Line 2827: IBE_Util.Debug('Begin p_order_header_rec' ||p_order_header_rec.header_id ||'::'|| p_party_id);

2823: l_order_header_rec := p_order_header_rec;
2824:
2825:
2826: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2827: IBE_Util.Debug('Begin p_order_header_rec' ||p_order_header_rec.header_id ||'::'|| p_party_id);
2828: END IF;
2829:
2830: -- Call Default Header Record
2831: DefaultHeaderRecord(l_order_header_rec

Line 2838: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2834: ,lx_order_header_rec);
2835:
2836: l_order_header_rec := lx_order_header_rec;
2837:
2838: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2839: IBE_Util.Debug('Save:order_hdr_rec.operation: ' || l_order_header_rec.operation);
2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);
2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);

Line 2839: IBE_Util.Debug('Save:order_hdr_rec.operation: ' || l_order_header_rec.operation);

2835:
2836: l_order_header_rec := lx_order_header_rec;
2837:
2838: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2839: IBE_Util.Debug('Save:order_hdr_rec.operation: ' || l_order_header_rec.operation);
2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);
2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);

Line 2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);

2836: l_order_header_rec := lx_order_header_rec;
2837:
2838: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2839: IBE_Util.Debug('Save:order_hdr_rec.operation: ' || l_order_header_rec.operation);
2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);
2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);

Line 2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);

2837:
2838: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2839: IBE_Util.Debug('Save:order_hdr_rec.operation: ' || l_order_header_rec.operation);
2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);
2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);
2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);

Line 2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);

2838: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2839: IBE_Util.Debug('Save:order_hdr_rec.operation: ' || l_order_header_rec.operation);
2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);
2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);
2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);
2846: IBE_Util.Debug('Save:order_hdr_rec.trans_curr_code: ' || l_order_header_rec.transactional_curr_code);

Line 2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);

2839: IBE_Util.Debug('Save:order_hdr_rec.operation: ' || l_order_header_rec.operation);
2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);
2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);
2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);
2846: IBE_Util.Debug('Save:order_hdr_rec.trans_curr_code: ' || l_order_header_rec.transactional_curr_code);
2847: IBE_Util.Debug('Save:order_hdr_rec.flow_stat_code: ' || l_order_header_rec.flow_status_code);

Line 2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);

2840: IBE_Util.Debug('Save:order_hdr_rec.sold_to_org_id: ' || l_order_header_rec.SOLD_TO_ORG_ID);
2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);
2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);
2846: IBE_Util.Debug('Save:order_hdr_rec.trans_curr_code: ' || l_order_header_rec.transactional_curr_code);
2847: IBE_Util.Debug('Save:order_hdr_rec.flow_stat_code: ' || l_order_header_rec.flow_status_code);
2848: END IF;

Line 2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);

2841: IBE_Util.Debug('Save:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);
2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);
2846: IBE_Util.Debug('Save:order_hdr_rec.trans_curr_code: ' || l_order_header_rec.transactional_curr_code);
2847: IBE_Util.Debug('Save:order_hdr_rec.flow_stat_code: ' || l_order_header_rec.flow_status_code);
2848: END IF;
2849:

Line 2846: IBE_Util.Debug('Save:order_hdr_rec.trans_curr_code: ' || l_order_header_rec.transactional_curr_code);

2842: IBE_Util.Debug('Save:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);
2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);
2846: IBE_Util.Debug('Save:order_hdr_rec.trans_curr_code: ' || l_order_header_rec.transactional_curr_code);
2847: IBE_Util.Debug('Save:order_hdr_rec.flow_stat_code: ' || l_order_header_rec.flow_status_code);
2848: END IF;
2849:
2850:

Line 2847: IBE_Util.Debug('Save:order_hdr_rec.flow_stat_code: ' || l_order_header_rec.flow_status_code);

2843: IBE_Util.Debug('Save:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2844: IBE_Util.Debug('Save:order_hdr_rec.order type id: ' || l_order_header_rec.ORDER_TYPE_ID);
2845: IBE_Util.Debug('Save:order_hdr_rec.org id: ' || l_order_header_rec.ORG_ID);
2846: IBE_Util.Debug('Save:order_hdr_rec.trans_curr_code: ' || l_order_header_rec.transactional_curr_code);
2847: IBE_Util.Debug('Save:order_hdr_rec.flow_stat_code: ' || l_order_header_rec.flow_status_code);
2848: END IF;
2849:
2850:
2851: /********** User Authentication *************/

Line 2893: IF (IBE_UTIL.G_DEBUGON = l_true) then

2889: IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) then
2890: raise FND_API.G_EXC_ERROR;
2891: END IF;
2892:
2893: IF (IBE_UTIL.G_DEBUGON = l_true) then
2894: Ibe_Util.DEBUG('ship_to_org_id returned: ' || lx_order_header_rec.ship_to_org_id);
2895: Ibe_Util.DEBUG('bill_to_org_id returned: ' || lx_order_header_rec.invoice_to_org_id);
2896: end if;
2897:

Line 2894: Ibe_Util.DEBUG('ship_to_org_id returned: ' || lx_order_header_rec.ship_to_org_id);

2890: raise FND_API.G_EXC_ERROR;
2891: END IF;
2892:
2893: IF (IBE_UTIL.G_DEBUGON = l_true) then
2894: Ibe_Util.DEBUG('ship_to_org_id returned: ' || lx_order_header_rec.ship_to_org_id);
2895: Ibe_Util.DEBUG('bill_to_org_id returned: ' || lx_order_header_rec.invoice_to_org_id);
2896: end if;
2897:
2898: IF(lx_order_header_rec.invoice_to_org_id is null OR lx_order_header_rec.invoice_to_org_id = FND_API.G_MISS_NUM)

Line 2895: Ibe_Util.DEBUG('bill_to_org_id returned: ' || lx_order_header_rec.invoice_to_org_id);

2891: END IF;
2892:
2893: IF (IBE_UTIL.G_DEBUGON = l_true) then
2894: Ibe_Util.DEBUG('ship_to_org_id returned: ' || lx_order_header_rec.ship_to_org_id);
2895: Ibe_Util.DEBUG('bill_to_org_id returned: ' || lx_order_header_rec.invoice_to_org_id);
2896: end if;
2897:
2898: IF(lx_order_header_rec.invoice_to_org_id is null OR lx_order_header_rec.invoice_to_org_id = FND_API.G_MISS_NUM)
2899: THEN

Line 2906: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2902: RAISE FND_API.G_EXC_ERROR;
2903: END IF;
2904:
2905: l_order_header_rec := lx_order_header_rec;
2906: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2907: IBE_Util.Debug('Save :order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2908: IBE_Util.Debug('Save :order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2909: IBE_Util.Debug('Save :order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2910:

Line 2907: IBE_Util.Debug('Save :order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);

2903: END IF;
2904:
2905: l_order_header_rec := lx_order_header_rec;
2906: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2907: IBE_Util.Debug('Save :order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2908: IBE_Util.Debug('Save :order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2909: IBE_Util.Debug('Save :order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2910:
2911: END IF;

Line 2908: IBE_Util.Debug('Save :order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);

2904:
2905: l_order_header_rec := lx_order_header_rec;
2906: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2907: IBE_Util.Debug('Save :order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2908: IBE_Util.Debug('Save :order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2909: IBE_Util.Debug('Save :order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2910:
2911: END IF;
2912: FOR i in 1..lx_line_tbl.COUNT

Line 2909: IBE_Util.Debug('Save :order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);

2905: l_order_header_rec := lx_order_header_rec;
2906: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2907: IBE_Util.Debug('Save :order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
2908: IBE_Util.Debug('Save :order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
2909: IBE_Util.Debug('Save :order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
2910:
2911: END IF;
2912: FOR i in 1..lx_line_tbl.COUNT
2913: LOOP

Line 2937: IF (IBE_UTIL.G_DEBUGON = l_true) then

2933: IF ((l_user_type = 'PERSON') AND
2934: (l_order_header_rec.operation = OE_Globals.G_OPR_UPDATE) AND
2935: (p_submit_control_rec.cancel_flag <> 'Y'))
2936: THEN
2937: IF (IBE_UTIL.G_DEBUGON = l_true) then
2938: Ibe_Util.DEBUG('calling SetLine ids API');
2939: END IF;
2940: SetLineShipInvoiceIds(
2941: p_order_header_rec => l_order_header_rec

Line 2938: Ibe_Util.DEBUG('calling SetLine ids API');

2934: (l_order_header_rec.operation = OE_Globals.G_OPR_UPDATE) AND
2935: (p_submit_control_rec.cancel_flag <> 'Y'))
2936: THEN
2937: IF (IBE_UTIL.G_DEBUGON = l_true) then
2938: Ibe_Util.DEBUG('calling SetLine ids API');
2939: END IF;
2940: SetLineShipInvoiceIds(
2941: p_order_header_rec => l_order_header_rec
2942: ,p_order_line_tbl => l_order_line_tbl

Line 2948: IF (IBE_UTIL.G_DEBUGON = l_true) then

2944:
2945: for j in 1..lx_line_tbl.count
2946: loop
2947: l_order_line_tbl(j) := lx_line_tbl(j);
2948: IF (IBE_UTIL.G_DEBUGON = l_true) then
2949: Ibe_Util.DEBUG('Line Level Values after setting: '||l_order_line_tbl(j).line_id||' : '||
2950: l_order_line_tbl(j).ship_to_org_id||' : '||l_order_line_tbl(j).invoice_to_org_id);
2951: END IF;
2952: end loop;

Line 2949: Ibe_Util.DEBUG('Line Level Values after setting: '||l_order_line_tbl(j).line_id||' : '||

2945: for j in 1..lx_line_tbl.count
2946: loop
2947: l_order_line_tbl(j) := lx_line_tbl(j);
2948: IF (IBE_UTIL.G_DEBUGON = l_true) then
2949: Ibe_Util.DEBUG('Line Level Values after setting: '||l_order_line_tbl(j).line_id||' : '||
2950: l_order_line_tbl(j).ship_to_org_id||' : '||l_order_line_tbl(j).invoice_to_org_id);
2951: END IF;
2952: end loop;
2953:

Line 2956: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2952: end loop;
2953:
2954: END IF; -- if operation = update
2955:
2956: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2957: FOR i in 1..l_order_line_tbl.COUNT
2958: LOOP
2959: IBE_Util.Debug('Save:line_tbl.operation: ' || l_order_line_tbl(i).OPERATION);
2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);

Line 2959: IBE_Util.Debug('Save:line_tbl.operation: ' || l_order_line_tbl(i).OPERATION);

2955:
2956: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2957: FOR i in 1..l_order_line_tbl.COUNT
2958: LOOP
2959: IBE_Util.Debug('Save:line_tbl.operation: ' || l_order_line_tbl(i).OPERATION);
2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);
2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);
2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);

Line 2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);

2956: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2957: FOR i in 1..l_order_line_tbl.COUNT
2958: LOOP
2959: IBE_Util.Debug('Save:line_tbl.operation: ' || l_order_line_tbl(i).OPERATION);
2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);
2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);
2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);

Line 2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);

2957: FOR i in 1..l_order_line_tbl.COUNT
2958: LOOP
2959: IBE_Util.Debug('Save:line_tbl.operation: ' || l_order_line_tbl(i).OPERATION);
2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);
2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);
2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);

Line 2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);

2958: LOOP
2959: IBE_Util.Debug('Save:line_tbl.operation: ' || l_order_line_tbl(i).OPERATION);
2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);
2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);
2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);

Line 2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);

2959: IBE_Util.Debug('Save:line_tbl.operation: ' || l_order_line_tbl(i).OPERATION);
2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);
2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);
2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);
2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);

Line 2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);

2960: IBE_Util.Debug('Save:line_tbl.line_id: ' || l_order_line_tbl(i).LINE_ID);
2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);
2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);
2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);
2968: IBE_Util.Debug('Save:line_tbl.ret atr2: ' || l_order_line_tbl(i).return_attribute2);

Line 2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);

2961: IBE_Util.Debug('Save:line_tbl.line_type_id: ' || l_order_line_tbl(i).LINE_TYPE_ID);
2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);
2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);
2968: IBE_Util.Debug('Save:line_tbl.ret atr2: ' || l_order_line_tbl(i).return_attribute2);
2969: IBE_Util.Debug('Save:line_tbl.rcode: ' || l_order_line_tbl(i).return_reason_code);

Line 2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);

2962: IBE_Util.Debug('Save:line_tbl.qty: ' || l_order_line_tbl(i).ORDERED_QUANTITY);
2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);
2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);
2968: IBE_Util.Debug('Save:line_tbl.ret atr2: ' || l_order_line_tbl(i).return_attribute2);
2969: IBE_Util.Debug('Save:line_tbl.rcode: ' || l_order_line_tbl(i).return_reason_code);
2970: END LOOP;

Line 2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);

2963: IBE_Util.Debug('Save:line_tbl.inv to org id: ' || l_order_line_tbl(i).INVOICE_TO_ORG_ID);
2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);
2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);
2968: IBE_Util.Debug('Save:line_tbl.ret atr2: ' || l_order_line_tbl(i).return_attribute2);
2969: IBE_Util.Debug('Save:line_tbl.rcode: ' || l_order_line_tbl(i).return_reason_code);
2970: END LOOP;
2971: END IF;

Line 2968: IBE_Util.Debug('Save:line_tbl.ret atr2: ' || l_order_line_tbl(i).return_attribute2);

2964: IBE_Util.Debug('Save:line_tbl.ship to org id: ' || l_order_line_tbl(i).SHIP_TO_ORG_ID);
2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);
2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);
2968: IBE_Util.Debug('Save:line_tbl.ret atr2: ' || l_order_line_tbl(i).return_attribute2);
2969: IBE_Util.Debug('Save:line_tbl.rcode: ' || l_order_line_tbl(i).return_reason_code);
2970: END LOOP;
2971: END IF;
2972:

Line 2969: IBE_Util.Debug('Save:line_tbl.rcode: ' || l_order_line_tbl(i).return_reason_code);

2965: IBE_Util.Debug('Save:line_tbl.return_context: ' || l_order_line_tbl(i).RETURN_CONTEXT);
2966: IBE_Util.Debug('Save:line_tbl.line categ: ' || l_order_line_tbl(i).LINE_CATEGORY_CODE);
2967: IBE_Util.Debug('Save:line_tbl.ret atr1: ' || l_order_line_tbl(i).return_attribute1);
2968: IBE_Util.Debug('Save:line_tbl.ret atr2: ' || l_order_line_tbl(i).return_attribute2);
2969: IBE_Util.Debug('Save:line_tbl.rcode: ' || l_order_line_tbl(i).return_reason_code);
2970: END LOOP;
2971: END IF;
2972:
2973:

Line 2976: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

2972:
2973:
2974: /************ Hard Delete logic for Pending Return ****/
2975:
2976: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2977: IBE_Util.Debug('ibe_order_save_pvt:cancel_flag ' ||p_submit_control_rec.cancel_flag);
2978: END IF;
2979:
2980: if (p_submit_control_rec.cancel_flag = 'Y') then

Line 2977: IBE_Util.Debug('ibe_order_save_pvt:cancel_flag ' ||p_submit_control_rec.cancel_flag);

2973:
2974: /************ Hard Delete logic for Pending Return ****/
2975:
2976: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
2977: IBE_Util.Debug('ibe_order_save_pvt:cancel_flag ' ||p_submit_control_rec.cancel_flag);
2978: END IF;
2979:
2980: if (p_submit_control_rec.cancel_flag = 'Y') then
2981: CancelOrder(l_order_header_rec,lx_order_header_rec);

Line 2983: IF (IBE_UTIL.G_DEBUGON = l_true) then

2979:
2980: if (p_submit_control_rec.cancel_flag = 'Y') then
2981: CancelOrder(l_order_header_rec,lx_order_header_rec);
2982: l_order_header_rec := lx_order_header_rec;
2983: IF (IBE_UTIL.G_DEBUGON = l_true) then
2984: ibe_util.debug('after cancelorder header_id:' ||l_order_header_rec.header_id);
2985: ibe_util.debug('after cancelorder operation:' ||l_order_header_rec.operation);
2986: end if;
2987:

Line 2984: ibe_util.debug('after cancelorder header_id:' ||l_order_header_rec.header_id);

2980: if (p_submit_control_rec.cancel_flag = 'Y') then
2981: CancelOrder(l_order_header_rec,lx_order_header_rec);
2982: l_order_header_rec := lx_order_header_rec;
2983: IF (IBE_UTIL.G_DEBUGON = l_true) then
2984: ibe_util.debug('after cancelorder header_id:' ||l_order_header_rec.header_id);
2985: ibe_util.debug('after cancelorder operation:' ||l_order_header_rec.operation);
2986: end if;
2987:
2988: IF(l_order_header_rec.operation = OE_Globals.G_OPR_DELETE) THEN

Line 2985: ibe_util.debug('after cancelorder operation:' ||l_order_header_rec.operation);

2981: CancelOrder(l_order_header_rec,lx_order_header_rec);
2982: l_order_header_rec := lx_order_header_rec;
2983: IF (IBE_UTIL.G_DEBUGON = l_true) then
2984: ibe_util.debug('after cancelorder header_id:' ||l_order_header_rec.header_id);
2985: ibe_util.debug('after cancelorder operation:' ||l_order_header_rec.operation);
2986: end if;
2987:
2988: IF(l_order_header_rec.operation = OE_Globals.G_OPR_DELETE) THEN
2989: l_cancel_flow := FND_API.G_TRUE;

Line 3018: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3014: loop
3015: l_order_line_tbl(i) := lx_line_tbl(i);
3016: end loop;
3017:
3018: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3019: IBE_Util.Debug('LineTbl cnt returned from SAveMDL API:'||l_order_line_tbl.count);
3020: END IF;
3021: END IF; -- order_category_code = 'RETURN' check
3022: END IF; -- main if for savemdlrel... call

Line 3019: IBE_Util.Debug('LineTbl cnt returned from SAveMDL API:'||l_order_line_tbl.count);

3015: l_order_line_tbl(i) := lx_line_tbl(i);
3016: end loop;
3017:
3018: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3019: IBE_Util.Debug('LineTbl cnt returned from SAveMDL API:'||l_order_line_tbl.count);
3020: END IF;
3021: END IF; -- order_category_code = 'RETURN' check
3022: END IF; -- main if for savemdlrel... call
3023:

Line 3030: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3026:
3027: IF (l_order_header_rec.order_category_code = 'RETURN'
3028: AND p_save_type = SAVE_REMOVEITEMS) THEN
3029:
3030: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3031: IBE_Util.debug('Inside Last Item Removal-Hard Delete If Loop');
3032: end if;
3033:
3034: for lineIdx in 1..l_order_line_tbl.count

Line 3031: IBE_Util.debug('Inside Last Item Removal-Hard Delete If Loop');

3027: IF (l_order_header_rec.order_category_code = 'RETURN'
3028: AND p_save_type = SAVE_REMOVEITEMS) THEN
3029:
3030: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3031: IBE_Util.debug('Inside Last Item Removal-Hard Delete If Loop');
3032: end if;
3033:
3034: for lineIdx in 1..l_order_line_tbl.count
3035: loop

Line 3047: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3043: l_dl_tmp_qry := 'SELECT count(*) from oe_order_lines_all '||
3044: 'WHERE header_id= :dl_header_id '||
3045: 'AND line_id NOT IN('||l_dl_line_id_qry||')';
3046:
3047: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3048: IBE_Util.debug('qry for finding if last item is removed: '|| l_dl_tmp_qry);
3049: end if;
3050:
3051: open l_dl_tmp for l_dl_tmp_qry using p_order_header_rec.header_id,l_parseKey;

Line 3048: IBE_Util.debug('qry for finding if last item is removed: '|| l_dl_tmp_qry);

3044: 'WHERE header_id= :dl_header_id '||
3045: 'AND line_id NOT IN('||l_dl_line_id_qry||')';
3046:
3047: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3048: IBE_Util.debug('qry for finding if last item is removed: '|| l_dl_tmp_qry);
3049: end if;
3050:
3051: open l_dl_tmp for l_dl_tmp_qry using p_order_header_rec.header_id,l_parseKey;
3052: fetch l_dl_tmp into No_Of_ExistingLines;

Line 3055: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3051: open l_dl_tmp for l_dl_tmp_qry using p_order_header_rec.header_id,l_parseKey;
3052: fetch l_dl_tmp into No_Of_ExistingLines;
3053: close l_dl_tmp;
3054:
3055: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3056: IBE_Util.debug('No. Of lines Existing in the ReturnOrder: '|| l_dl_tmp_qry);
3057: end if;
3058:
3059: IF (No_Of_ExistingLines = 0) THEN -- No More Lines in The Return Order so can be hard deleted.

Line 3056: IBE_Util.debug('No. Of lines Existing in the ReturnOrder: '|| l_dl_tmp_qry);

3052: fetch l_dl_tmp into No_Of_ExistingLines;
3053: close l_dl_tmp;
3054:
3055: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3056: IBE_Util.debug('No. Of lines Existing in the ReturnOrder: '|| l_dl_tmp_qry);
3057: end if;
3058:
3059: IF (No_Of_ExistingLines = 0) THEN -- No More Lines in The Return Order so can be hard deleted.
3060: CancelOrder(l_order_header_rec,lx_order_header_rec);

Line 3062: IF (IBE_UTIL.G_DEBUGON = l_true) then

3058:
3059: IF (No_Of_ExistingLines = 0) THEN -- No More Lines in The Return Order so can be hard deleted.
3060: CancelOrder(l_order_header_rec,lx_order_header_rec);
3061: l_order_header_rec := lx_order_header_rec;
3062: IF (IBE_UTIL.G_DEBUGON = l_true) then
3063: ibe_util.debug('after Remove-Cancelorder header_id:' ||l_order_header_rec.header_id);
3064: ibe_util.debug('after Remove-cancelorder operation:' ||l_order_header_rec.operation);
3065: end if;
3066:

Line 3063: ibe_util.debug('after Remove-Cancelorder header_id:' ||l_order_header_rec.header_id);

3059: IF (No_Of_ExistingLines = 0) THEN -- No More Lines in The Return Order so can be hard deleted.
3060: CancelOrder(l_order_header_rec,lx_order_header_rec);
3061: l_order_header_rec := lx_order_header_rec;
3062: IF (IBE_UTIL.G_DEBUGON = l_true) then
3063: ibe_util.debug('after Remove-Cancelorder header_id:' ||l_order_header_rec.header_id);
3064: ibe_util.debug('after Remove-cancelorder operation:' ||l_order_header_rec.operation);
3065: end if;
3066:
3067: IF(l_order_header_rec.operation = OE_Globals.G_OPR_DELETE) THEN

Line 3064: ibe_util.debug('after Remove-cancelorder operation:' ||l_order_header_rec.operation);

3060: CancelOrder(l_order_header_rec,lx_order_header_rec);
3061: l_order_header_rec := lx_order_header_rec;
3062: IF (IBE_UTIL.G_DEBUGON = l_true) then
3063: ibe_util.debug('after Remove-Cancelorder header_id:' ||l_order_header_rec.header_id);
3064: ibe_util.debug('after Remove-cancelorder operation:' ||l_order_header_rec.operation);
3065: end if;
3066:
3067: IF(l_order_header_rec.operation = OE_Globals.G_OPR_DELETE) THEN
3068: l_cancel_flow := FND_API.G_TRUE;

Line 3079: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3075:
3076:
3077: /****************** ORDER Booking FLOW ******************/
3078:
3079: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3080: IBE_Util.Debug('Save:submit-control_rec.submit_flag ' || p_submit_control_rec.submit_flag);
3081: END IF;
3082:
3083: IF p_submit_control_rec.submit_flag = 'Y' THEN

Line 3080: IBE_Util.Debug('Save:submit-control_rec.submit_flag ' || p_submit_control_rec.submit_flag);

3076:
3077: /****************** ORDER Booking FLOW ******************/
3078:
3079: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3080: IBE_Util.Debug('Save:submit-control_rec.submit_flag ' || p_submit_control_rec.submit_flag);
3081: END IF;
3082:
3083: IF p_submit_control_rec.submit_flag = 'Y' THEN
3084:

Line 3089: IF (IBE_UTIL.G_DEBUGON = l_true) then

3085: -- If it is 'post 11590' OE flow and if it is a Return:
3086: -- New, Submit_Order() API should be called for booking it.
3087: -- SO validate the qty, before calling submit_order().
3088:
3089: IF (IBE_UTIL.G_DEBUGON = l_true) then
3090: IBE_UTIL.DEBUG('order_category_code: ' ||l_order_header_rec.order_category_code );
3091: IBE_UTIL.DEBUG('OE-Get_Code_Release_Level ' || OE_CODE_CONTROL.Get_Code_Release_Level);
3092: end if;
3093:

Line 3090: IBE_UTIL.DEBUG('order_category_code: ' ||l_order_header_rec.order_category_code );

3086: -- New, Submit_Order() API should be called for booking it.
3087: -- SO validate the qty, before calling submit_order().
3088:
3089: IF (IBE_UTIL.G_DEBUGON = l_true) then
3090: IBE_UTIL.DEBUG('order_category_code: ' ||l_order_header_rec.order_category_code );
3091: IBE_UTIL.DEBUG('OE-Get_Code_Release_Level ' || OE_CODE_CONTROL.Get_Code_Release_Level);
3092: end if;
3093:
3094: -- As per Bug# 3522453, a new profile is introduced to drive pre-booking approval

Line 3091: IBE_UTIL.DEBUG('OE-Get_Code_Release_Level ' || OE_CODE_CONTROL.Get_Code_Release_Level);

3087: -- SO validate the qty, before calling submit_order().
3088:
3089: IF (IBE_UTIL.G_DEBUGON = l_true) then
3090: IBE_UTIL.DEBUG('order_category_code: ' ||l_order_header_rec.order_category_code );
3091: IBE_UTIL.DEBUG('OE-Get_Code_Release_Level ' || OE_CODE_CONTROL.Get_Code_Release_Level);
3092: end if;
3093:
3094: -- As per Bug# 3522453, a new profile is introduced to drive pre-booking approval
3095: -- flows. So check for flow_status_code if it is "WORKING", then go with

Line 3104: IF (IBE_UTIL.G_DEBUGON = l_true) then

3100: Get_Order_Status(p_header_id => l_order_header_rec.header_id
3101: ,x_order_status => l_flow_status_code
3102: ,x_last_update_date => l_last_update_date);
3103:
3104: IF (IBE_UTIL.G_DEBUGON = l_true) then
3105: IBE_UTIL.DEBUG('SAVE - Pending Return flow_status_code: ' ||l_flow_status_code);
3106: end if;
3107:
3108: IF (l_order_header_rec.order_category_code = 'RETURN' AND

Line 3105: IBE_UTIL.DEBUG('SAVE - Pending Return flow_status_code: ' ||l_flow_status_code);

3101: ,x_order_status => l_flow_status_code
3102: ,x_last_update_date => l_last_update_date);
3103:
3104: IF (IBE_UTIL.G_DEBUGON = l_true) then
3105: IBE_UTIL.DEBUG('SAVE - Pending Return flow_status_code: ' ||l_flow_status_code);
3106: end if;
3107:
3108: IF (l_order_header_rec.order_category_code = 'RETURN' AND
3109: l_flow_status_code = 'WORKING') THEN

Line 3111: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3107:
3108: IF (l_order_header_rec.order_category_code = 'RETURN' AND
3109: l_flow_status_code = 'WORKING') THEN
3110:
3111: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3112: IBE_Util.Debug('Before Complete Validate API');
3113: END IF;
3114:
3115: Complete_RetOrder_Validate(

Line 3112: IBE_Util.Debug('Before Complete Validate API');

3108: IF (l_order_header_rec.order_category_code = 'RETURN' AND
3109: l_flow_status_code = 'WORKING') THEN
3110:
3111: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3112: IBE_Util.Debug('Before Complete Validate API');
3113: END IF;
3114:
3115: Complete_RetOrder_Validate(
3116: P_order_header_id => l_order_header_rec.header_id

Line 3124: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3120: ,x_msg_count => x_msg_count
3121: ,x_msg_data => x_msg_data
3122: );
3123:
3124: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3125: IBE_Util.Debug('After Complete Validate API: '|| x_return_status);
3126: END IF;
3127:
3128: IF x_return_status = FND_API.G_RET_STS_ERROR THEN

Line 3125: IBE_Util.Debug('After Complete Validate API: '|| x_return_status);

3121: ,x_msg_data => x_msg_data
3122: );
3123:
3124: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3125: IBE_Util.Debug('After Complete Validate API: '|| x_return_status);
3126: END IF;
3127:
3128: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
3129: raise FND_API.G_EXC_ERROR;

Line 3160: IF (IBE_UTIL.G_DEBUGON = l_true) then

3156:
3157: -- bug# 3069333
3158: OE_STANDARD_WF.SAVE_MESSAGES_OFF;
3159:
3160: IF (IBE_UTIL.G_DEBUGON = l_true) then
3161: IBE_UTIL.DEBUG('l_ProcessOrder_Flow: ' || l_ProcessOrder_Flow );
3162: end if;
3163:
3164: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

Line 3161: IBE_UTIL.DEBUG('l_ProcessOrder_Flow: ' || l_ProcessOrder_Flow );

3157: -- bug# 3069333
3158: OE_STANDARD_WF.SAVE_MESSAGES_OFF;
3159:
3160: IF (IBE_UTIL.G_DEBUGON = l_true) then
3161: IBE_UTIL.DEBUG('l_ProcessOrder_Flow: ' || l_ProcessOrder_Flow );
3162: end if;
3163:
3164: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3165: IBE_Util.Debug('Save Before Process Order:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);

Line 3164: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3160: IF (IBE_UTIL.G_DEBUGON = l_true) then
3161: IBE_UTIL.DEBUG('l_ProcessOrder_Flow: ' || l_ProcessOrder_Flow );
3162: end if;
3163:
3164: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3165: IBE_Util.Debug('Save Before Process Order:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
3166: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
3167: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
3168: END IF;

Line 3165: IBE_Util.Debug('Save Before Process Order:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);

3161: IBE_UTIL.DEBUG('l_ProcessOrder_Flow: ' || l_ProcessOrder_Flow );
3162: end if;
3163:
3164: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3165: IBE_Util.Debug('Save Before Process Order:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
3166: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
3167: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
3168: END IF;
3169:

Line 3166: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);

3162: end if;
3163:
3164: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3165: IBE_Util.Debug('Save Before Process Order:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
3166: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
3167: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
3168: END IF;
3169:
3170: IF(FND_API.to_Boolean(l_ProcessOrder_Flow)) THEN

Line 3167: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);

3163:
3164: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3165: IBE_Util.Debug('Save Before Process Order:order_hdr_rec.ship_to_org_id: ' || l_order_header_rec.SHIP_TO_ORG_ID);
3166: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.Invoice_to_org_id: ' || l_order_header_rec.INVOICE_TO_ORG_ID);
3167: IBE_Util.Debug('Save Bef Process Ord:order_hdr_rec.header_id: ' || l_order_header_rec.HEADER_ID);
3168: END IF;
3169:
3170: IF(FND_API.to_Boolean(l_ProcessOrder_Flow)) THEN
3171:

Line 3174: IF (IBE_UTIL.G_DEBUGON = l_true) then

3170: IF(FND_API.to_Boolean(l_ProcessOrder_Flow)) THEN
3171:
3172: /*************--call process order;--*****************/
3173:
3174: IF (IBE_UTIL.G_DEBUGON = l_true) then
3175: IBE_UTIL.DEBUG('Save - Before Calling Process_Order()');
3176: end if;
3177:
3178: OE_Order_GRP.Process_Order

Line 3175: IBE_UTIL.DEBUG('Save - Before Calling Process_Order()');

3171:
3172: /*************--call process order;--*****************/
3173:
3174: IF (IBE_UTIL.G_DEBUGON = l_true) then
3175: IBE_UTIL.DEBUG('Save - Before Calling Process_Order()');
3176: end if;
3177:
3178: OE_Order_GRP.Process_Order
3179: ( p_api_version_number => 1.0

Line 3224: IF (IBE_UTIL.G_DEBUGON = l_true) then

3220: , x_Lot_Serial_val_tbl => l_lot_serial_val_tbl
3221: , x_action_request_tbl => l_action_request_tbl
3222: );
3223:
3224: IF (IBE_UTIL.G_DEBUGON = l_true) then
3225: IBE_UTIL.DEBUG('Save After Calling Process_Order() : ' || x_return_status);
3226: IBE_UTIL.DEBUG('header id from OE Save: ' || lx_order_header_rec.header_id);
3227: end if;
3228:

Line 3225: IBE_UTIL.DEBUG('Save After Calling Process_Order() : ' || x_return_status);

3221: , x_action_request_tbl => l_action_request_tbl
3222: );
3223:
3224: IF (IBE_UTIL.G_DEBUGON = l_true) then
3225: IBE_UTIL.DEBUG('Save After Calling Process_Order() : ' || x_return_status);
3226: IBE_UTIL.DEBUG('header id from OE Save: ' || lx_order_header_rec.header_id);
3227: end if;
3228:
3229: for j in 1 .. x_msg_count

Line 3226: IBE_UTIL.DEBUG('header id from OE Save: ' || lx_order_header_rec.header_id);

3222: );
3223:
3224: IF (IBE_UTIL.G_DEBUGON = l_true) then
3225: IBE_UTIL.DEBUG('Save After Calling Process_Order() : ' || x_return_status);
3226: IBE_UTIL.DEBUG('header id from OE Save: ' || lx_order_header_rec.header_id);
3227: end if;
3228:
3229: for j in 1 .. x_msg_count
3230: loop

Line 3232: IF (IBE_UTIL.G_DEBUGON = l_true) then

3228:
3229: for j in 1 .. x_msg_count
3230: loop
3231: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
3232: IF (IBE_UTIL.G_DEBUGON = l_true) then
3233: IBE_UTIL.DEBUG('Message from OE Save: ' || x_msg_data );
3234: end if;
3235: end loop;
3236:

Line 3233: IBE_UTIL.DEBUG('Message from OE Save: ' || x_msg_data );

3229: for j in 1 .. x_msg_count
3230: loop
3231: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
3232: IF (IBE_UTIL.G_DEBUGON = l_true) then
3233: IBE_UTIL.DEBUG('Message from OE Save: ' || x_msg_data );
3234: end if;
3235: end loop;
3236:
3237: -- This check is for catching Booking Related Exceptions Only.

Line 3249: IF (IBE_UTIL.G_DEBUGON = l_true) then

3245: AND p_submit_control_rec.submit_flag = 'Y'
3246: AND (l_action_request_tbl.EXISTS(1) AND
3247: l_action_request_tbl(1).return_status <> FND_API.G_RET_STS_SUCCESS))
3248: THEN
3249: IF (IBE_UTIL.G_DEBUGON = l_true) then
3250: IBE_UTIL.DEBUG('Error in ProcessOrder Booking Flow' );
3251: end if;
3252: retrieve_oe_messages;
3253: x_return_status := FND_API.G_RET_STS_ERROR;

Line 3250: IBE_UTIL.DEBUG('Error in ProcessOrder Booking Flow' );

3246: AND (l_action_request_tbl.EXISTS(1) AND
3247: l_action_request_tbl(1).return_status <> FND_API.G_RET_STS_SUCCESS))
3248: THEN
3249: IF (IBE_UTIL.G_DEBUGON = l_true) then
3250: IBE_UTIL.DEBUG('Error in ProcessOrder Booking Flow' );
3251: end if;
3252: retrieve_oe_messages;
3253: x_return_status := FND_API.G_RET_STS_ERROR;
3254: RAISE FND_API.G_EXC_ERROR;

Line 3259: IF (IBE_UTIL.G_DEBUGON = l_true) then

3255: END IF;
3256:
3257: -- This check is for catching all generic Exceptions.
3258: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then
3259: IF (IBE_UTIL.G_DEBUGON = l_true) then
3260: IBE_UTIL.DEBUG('Error in Procees Order Flow: '||x_return_status );
3261: end if;
3262: retrieve_oe_messages;
3263: IF x_return_status = FND_API.G_RET_STS_ERROR THEN

Line 3260: IBE_UTIL.DEBUG('Error in Procees Order Flow: '||x_return_status );

3256:
3257: -- This check is for catching all generic Exceptions.
3258: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then
3259: IF (IBE_UTIL.G_DEBUGON = l_true) then
3260: IBE_UTIL.DEBUG('Error in Procees Order Flow: '||x_return_status );
3261: end if;
3262: retrieve_oe_messages;
3263: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
3264: raise FND_API.G_EXC_ERROR;

Line 3281: IF (IBE_UTIL.G_DEBUGON = l_true) then

3277: IF((p_submit_control_rec.submit_flag = 'Y')
3278: AND(l_order_header_rec.order_category_code = 'RETURN' AND
3279: l_flow_status_code = 'WORKING'))THEN
3280:
3281: IF (IBE_UTIL.G_DEBUGON = l_true) then
3282: IBE_UTIL.DEBUG('Before Calling OE_RMA_GRP.Submit_Order');
3283: end if;
3284:
3285: OE_RMA_GRP.Submit_Order( p_api_version => 1.0

Line 3282: IBE_UTIL.DEBUG('Before Calling OE_RMA_GRP.Submit_Order');

3278: AND(l_order_header_rec.order_category_code = 'RETURN' AND
3279: l_flow_status_code = 'WORKING'))THEN
3280:
3281: IF (IBE_UTIL.G_DEBUGON = l_true) then
3282: IBE_UTIL.DEBUG('Before Calling OE_RMA_GRP.Submit_Order');
3283: end if;
3284:
3285: OE_RMA_GRP.Submit_Order( p_api_version => 1.0
3286: , p_header_id => l_order_header_rec.header_id

Line 3291: IF (IBE_UTIL.G_DEBUGON = l_true) then

3287: , x_return_status => x_return_status
3288: , x_msg_count => x_msg_count
3289: , x_msg_data => x_msg_data);
3290:
3291: IF (IBE_UTIL.G_DEBUGON = l_true) then
3292: IBE_UTIL.DEBUG('After Calling Submit_Order - return_stats: '||x_return_status);
3293: IBE_UTIL.DEBUG('x_msg_count: '||x_msg_count);
3294: end if;
3295:

Line 3292: IBE_UTIL.DEBUG('After Calling Submit_Order - return_stats: '||x_return_status);

3288: , x_msg_count => x_msg_count
3289: , x_msg_data => x_msg_data);
3290:
3291: IF (IBE_UTIL.G_DEBUGON = l_true) then
3292: IBE_UTIL.DEBUG('After Calling Submit_Order - return_stats: '||x_return_status);
3293: IBE_UTIL.DEBUG('x_msg_count: '||x_msg_count);
3294: end if;
3295:
3296: --for logging appropriate error message

Line 3293: IBE_UTIL.DEBUG('x_msg_count: '||x_msg_count);

3289: , x_msg_data => x_msg_data);
3290:
3291: IF (IBE_UTIL.G_DEBUGON = l_true) then
3292: IBE_UTIL.DEBUG('After Calling Submit_Order - return_stats: '||x_return_status);
3293: IBE_UTIL.DEBUG('x_msg_count: '||x_msg_count);
3294: end if;
3295:
3296: --for logging appropriate error message
3297: if(x_msg_count is not null AND x_msg_count > 0) then

Line 3301: IF (IBE_UTIL.G_DEBUGON = l_true) then

3297: if(x_msg_count is not null AND x_msg_count > 0) then
3298: for j in 1 .. x_msg_count
3299: loop
3300: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
3301: IF (IBE_UTIL.G_DEBUGON = l_true) then
3302: IBE_UTIL.DEBUG('Message from OE Save: ' || x_msg_data );
3303: end if;
3304: end loop;
3305: end if;

Line 3302: IBE_UTIL.DEBUG('Message from OE Save: ' || x_msg_data );

3298: for j in 1 .. x_msg_count
3299: loop
3300: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
3301: IF (IBE_UTIL.G_DEBUGON = l_true) then
3302: IBE_UTIL.DEBUG('Message from OE Save: ' || x_msg_data );
3303: end if;
3304: end loop;
3305: end if;
3306:

Line 3326: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3322: from oe_order_headers_all where header_id=sh_hdr_id;
3323: Begin
3324: open c_submit_hdrattr(x_order_header_id);
3325: fetch c_submit_hdrattr into x_order_number,x_last_update_date,x_flow_status_code;
3326: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3327: IBE_UTIL.DEBUG('order number after submit: ' || x_order_number );
3328: END IF;
3329: close c_submit_hdrattr;
3330: End;

Line 3327: IBE_UTIL.DEBUG('order number after submit: ' || x_order_number );

3323: Begin
3324: open c_submit_hdrattr(x_order_header_id);
3325: fetch c_submit_hdrattr into x_order_number,x_last_update_date,x_flow_status_code;
3326: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3327: IBE_UTIL.DEBUG('order number after submit: ' || x_order_number );
3328: END IF;
3329: close c_submit_hdrattr;
3330: End;
3331:

Line 3334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3330: End;
3331:
3332: END If;
3333:
3334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3335: IBE_UTIL.DEBUG('header id returned from OE: ' || x_order_header_id );
3336: IBE_UTIL.DEBUG('x_flow_status_code: ' || x_flow_status_code );
3337: IBE_UTIL.DEBUG('calling ibe_active_quotes_all package handler: ' || l_cancel_flow);
3338: END IF;

Line 3335: IBE_UTIL.DEBUG('header id returned from OE: ' || x_order_header_id );

3331:
3332: END If;
3333:
3334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3335: IBE_UTIL.DEBUG('header id returned from OE: ' || x_order_header_id );
3336: IBE_UTIL.DEBUG('x_flow_status_code: ' || x_flow_status_code );
3337: IBE_UTIL.DEBUG('calling ibe_active_quotes_all package handler: ' || l_cancel_flow);
3338: END IF;
3339:

Line 3336: IBE_UTIL.DEBUG('x_flow_status_code: ' || x_flow_status_code );

3332: END If;
3333:
3334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3335: IBE_UTIL.DEBUG('header id returned from OE: ' || x_order_header_id );
3336: IBE_UTIL.DEBUG('x_flow_status_code: ' || x_flow_status_code );
3337: IBE_UTIL.DEBUG('calling ibe_active_quotes_all package handler: ' || l_cancel_flow);
3338: END IF;
3339:
3340: IF (FND_API.to_Boolean(l_cancel_flow)

Line 3337: IBE_UTIL.DEBUG('calling ibe_active_quotes_all package handler: ' || l_cancel_flow);

3333:
3334: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3335: IBE_UTIL.DEBUG('header id returned from OE: ' || x_order_header_id );
3336: IBE_UTIL.DEBUG('x_flow_status_code: ' || x_flow_status_code );
3337: IBE_UTIL.DEBUG('calling ibe_active_quotes_all package handler: ' || l_cancel_flow);
3338: END IF;
3339:
3340: IF (FND_API.to_Boolean(l_cancel_flow)
3341: OR ((p_save_type = SAVE_NORMAL AND p_submit_control_rec.submit_flag = 'Y')

Line 3351: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3347: ActivateOrder(x_order_header_id,p_party_id,l_order_header_rec.sold_to_org_id,
3348: l_order_header_rec.transactional_curr_code);
3349: END IF;
3350:
3351: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3352: IBE_UTIL.DEBUG('back from ibe_active_quotes_all package handler');
3353: END IF;
3354:
3355: -- Calling Notification to the user After successfully booking the order.

Line 3352: IBE_UTIL.DEBUG('back from ibe_active_quotes_all package handler');

3348: l_order_header_rec.transactional_curr_code);
3349: END IF;
3350:
3351: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3352: IBE_UTIL.DEBUG('back from ibe_active_quotes_all package handler');
3353: END IF;
3354:
3355: -- Calling Notification to the user After successfully booking the order.
3356: -- This would send a notification to the user about the conformation of the Return.

Line 3360: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3356: -- This would send a notification to the user about the conformation of the Return.
3357:
3358: IF (p_save_type = SAVE_NORMAL AND p_submit_control_rec.submit_flag = 'Y') THEN
3359:
3360: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3361: IBE_UTIL.debug('IBE_ORDER_SAVE_PVT: Before calling Notification API');
3362: END IF;
3363:
3364: IBE_WORKFLOW_PVT.NotifyReturnOrderStatus(

Line 3361: IBE_UTIL.debug('IBE_ORDER_SAVE_PVT: Before calling Notification API');

3357:
3358: IF (p_save_type = SAVE_NORMAL AND p_submit_control_rec.submit_flag = 'Y') THEN
3359:
3360: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3361: IBE_UTIL.debug('IBE_ORDER_SAVE_PVT: Before calling Notification API');
3362: END IF;
3363:
3364: IBE_WORKFLOW_PVT.NotifyReturnOrderStatus(
3365: p_api_version => 1,

Line 3374: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3370: x_return_status => x_return_status,
3371: x_msg_count => x_msg_count,
3372: x_msg_data => x_msg_data
3373: );
3374: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3375: IBE_UTIL.debug('IBE_ORDER_SAVE_PVT: Notification API is called');
3376: END IF;
3377:
3378: IF x_return_status = FND_API.G_RET_STS_ERROR THEN

Line 3375: IBE_UTIL.debug('IBE_ORDER_SAVE_PVT: Notification API is called');

3371: x_msg_count => x_msg_count,
3372: x_msg_data => x_msg_data
3373: );
3374: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3375: IBE_UTIL.debug('IBE_ORDER_SAVE_PVT: Notification API is called');
3376: END IF;
3377:
3378: IF x_return_status = FND_API.G_RET_STS_ERROR THEN
3379: RAISE FND_API.G_EXC_ERROR;

Line 3399: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3395: THEN
3396: COMMIT WORK;
3397: END IF;
3398:
3399: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3400: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:Save)');
3401: END IF;
3402:
3403: -- Standard call to get message count and if count is 1, get message info.

Line 3400: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:Save)');

3396: COMMIT WORK;
3397: END IF;
3398:
3399: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3400: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:Save)');
3401: END IF;
3402:
3403: -- Standard call to get message count and if count is 1, get message info.
3404:

Line 3415: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3411: x_return_status := FND_API.G_RET_STS_ERROR;
3412: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3413: p_count => x_msg_count ,
3414: p_data => x_msg_data);
3415: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3416: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:Save()'|| sqlerrm);
3417: END IF;
3418:
3419: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

Line 3416: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:Save()'|| sqlerrm);

3412: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3413: p_count => x_msg_count ,
3414: p_data => x_msg_data);
3415: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3416: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:Save()'|| sqlerrm);
3417: END IF;
3418:
3419: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3420: ROLLBACK TO SAVE_ORDER_SAVE_PVT;

Line 3425: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3421: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3422: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3423: p_count => x_msg_count ,
3424: p_data => x_msg_data);
3425: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3426: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:Save()' || sqlerrm);
3427: END IF;
3428: WHEN OTHERS THEN
3429: ROLLBACK TO SAVE_ORDER_SAVE_PVT;

Line 3426: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:Save()' || sqlerrm);

3422: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3423: p_count => x_msg_count ,
3424: p_data => x_msg_data);
3425: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3426: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:Save()' || sqlerrm);
3427: END IF;
3428: WHEN OTHERS THEN
3429: ROLLBACK TO SAVE_ORDER_SAVE_PVT;
3430: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 3440: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3436:
3437: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3438: p_count => x_msg_count ,
3439: p_data => x_msg_data);
3440: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3441: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:Save()' || sqlerrm);
3442: END IF;
3443:
3444:

Line 3441: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:Save()' || sqlerrm);

3437: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3438: p_count => x_msg_count ,
3439: p_data => x_msg_data);
3440: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3441: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:Save()' || sqlerrm);
3442: END IF;
3443:
3444:
3445: END Save;

Line 3542: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3538: BEGIN
3539:
3540: x_error_lineids := JTF_VARCHAR2_TABLE_300();
3541:
3542: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3543: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:CheckConstraints()');
3544: END IF;
3545:
3546: -- Standard Start of API savepoint

Line 3543: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:CheckConstraints()');

3539:
3540: x_error_lineids := JTF_VARCHAR2_TABLE_300();
3541:
3542: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3543: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:CheckConstraints()');
3544: END IF;
3545:
3546: -- Standard Start of API savepoint
3547: SAVEPOINT ORDER_CHKCONSTRAINT;

Line 3568: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3564: x_return_status := FND_API.G_RET_STS_SUCCESS;
3565:
3566:
3567: -- Start OF API body --
3568: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3569: IBE_Util.Debug('In chkconstraint()');
3570: END IF;
3571:
3572: -- SET HEADER RECORD

Line 3569: IBE_Util.Debug('In chkconstraint()');

3565:
3566:
3567: -- Start OF API body --
3568: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3569: IBE_Util.Debug('In chkconstraint()');
3570: END IF;
3571:
3572: -- SET HEADER RECORD
3573: l_order_header_rec := p_order_header_rec;

Line 3589: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3585: END IF;
3586:
3587: -- Get the User's Session ORG_ID
3588: l_user_orgid := mo_global.GET_CURRENT_ORG_ID();
3589: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3590: Ibe_util.Debug('Current Org id : ' ||l_user_orgid);
3591: END IF;
3592:
3593: -- Get the Sales Rep Number from the ASO Utility package

Line 3590: Ibe_util.Debug('Current Org id : ' ||l_user_orgid);

3586:
3587: -- Get the User's Session ORG_ID
3588: l_user_orgid := mo_global.GET_CURRENT_ORG_ID();
3589: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3590: Ibe_util.Debug('Current Org id : ' ||l_user_orgid);
3591: END IF;
3592:
3593: -- Get the Sales Rep Number from the ASO Utility package
3594: l_salesrep_number := ASO_UTILITY_PVT.GET_OU_ATTRIBUTE_VALUE(aso_utility_pvt.GET_DEFAULT_SALESREP,l_user_orgid);

Line 3595: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3591: END IF;
3592:
3593: -- Get the Sales Rep Number from the ASO Utility package
3594: l_salesrep_number := ASO_UTILITY_PVT.GET_OU_ATTRIBUTE_VALUE(aso_utility_pvt.GET_DEFAULT_SALESREP,l_user_orgid);
3595: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3596: Ibe_util.Debug('Sales Rep Number for Current Org : ' ||l_salesrep_number);
3597: END IF;
3598:
3599: -- Bug 5359687, Proper error message when default salesrep is not set

Line 3596: Ibe_util.Debug('Sales Rep Number for Current Org : ' ||l_salesrep_number);

3592:
3593: -- Get the Sales Rep Number from the ASO Utility package
3594: l_salesrep_number := ASO_UTILITY_PVT.GET_OU_ATTRIBUTE_VALUE(aso_utility_pvt.GET_DEFAULT_SALESREP,l_user_orgid);
3595: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3596: Ibe_util.Debug('Sales Rep Number for Current Org : ' ||l_salesrep_number);
3597: END IF;
3598:
3599: -- Bug 5359687, Proper error message when default salesrep is not set
3600: IF (l_salesrep_number is null) THEN

Line 3609: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3605: -- Get the sales rep id from the sales rep number using the JTF table
3606: select SALESREP_ID into l_salesrep_id from JTF_RS_SALESREPS where SALESREP_NUMBER = l_salesrep_number and ORG_ID = l_user_orgid;
3607: END IF;
3608:
3609: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3610: Ibe_util.Debug('Sales Rep Id : ' ||l_salesrep_id);
3611: END IF;
3612:
3613: --l_salesrep_id := FND_PROFILE.VALUE('ASO_DEFAULT_PERSON_ID');

Line 3610: Ibe_util.Debug('Sales Rep Id : ' ||l_salesrep_id);

3606: select SALESREP_ID into l_salesrep_id from JTF_RS_SALESREPS where SALESREP_NUMBER = l_salesrep_number and ORG_ID = l_user_orgid;
3607: END IF;
3608:
3609: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3610: Ibe_util.Debug('Sales Rep Id : ' ||l_salesrep_id);
3611: END IF;
3612:
3613: --l_salesrep_id := FND_PROFILE.VALUE('ASO_DEFAULT_PERSON_ID');
3614:

Line 3623: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3619: ELSE
3620: l_order_header_rec.salesrep_id := l_salesrep_id;
3621: END IF;
3622:
3623: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3624: IBE_Util.Debug('chkconstraint-l_order_header_rec.header_id:' || l_order_header_rec.header_id);
3625: IBE_Util.Debug('chkconstraint-l_order_header_rec.sold_to_org_id:' || l_order_header_rec.sold_to_org_id);
3626: IBE_Util.Debug('chkconstraint-l_order_header_rec.operation:' || l_order_header_rec.operation);
3627: IBE_Util.Debug('chkconstraint-l_order_header_rec.order_type_id:' || l_order_header_rec.order_type_id);

Line 3624: IBE_Util.Debug('chkconstraint-l_order_header_rec.header_id:' || l_order_header_rec.header_id);

3620: l_order_header_rec.salesrep_id := l_salesrep_id;
3621: END IF;
3622:
3623: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3624: IBE_Util.Debug('chkconstraint-l_order_header_rec.header_id:' || l_order_header_rec.header_id);
3625: IBE_Util.Debug('chkconstraint-l_order_header_rec.sold_to_org_id:' || l_order_header_rec.sold_to_org_id);
3626: IBE_Util.Debug('chkconstraint-l_order_header_rec.operation:' || l_order_header_rec.operation);
3627: IBE_Util.Debug('chkconstraint-l_order_header_rec.order_type_id:' || l_order_header_rec.order_type_id);
3628: END IF;

Line 3625: IBE_Util.Debug('chkconstraint-l_order_header_rec.sold_to_org_id:' || l_order_header_rec.sold_to_org_id);

3621: END IF;
3622:
3623: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3624: IBE_Util.Debug('chkconstraint-l_order_header_rec.header_id:' || l_order_header_rec.header_id);
3625: IBE_Util.Debug('chkconstraint-l_order_header_rec.sold_to_org_id:' || l_order_header_rec.sold_to_org_id);
3626: IBE_Util.Debug('chkconstraint-l_order_header_rec.operation:' || l_order_header_rec.operation);
3627: IBE_Util.Debug('chkconstraint-l_order_header_rec.order_type_id:' || l_order_header_rec.order_type_id);
3628: END IF;
3629:

Line 3626: IBE_Util.Debug('chkconstraint-l_order_header_rec.operation:' || l_order_header_rec.operation);

3622:
3623: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3624: IBE_Util.Debug('chkconstraint-l_order_header_rec.header_id:' || l_order_header_rec.header_id);
3625: IBE_Util.Debug('chkconstraint-l_order_header_rec.sold_to_org_id:' || l_order_header_rec.sold_to_org_id);
3626: IBE_Util.Debug('chkconstraint-l_order_header_rec.operation:' || l_order_header_rec.operation);
3627: IBE_Util.Debug('chkconstraint-l_order_header_rec.order_type_id:' || l_order_header_rec.order_type_id);
3628: END IF;
3629:
3630:

Line 3627: IBE_Util.Debug('chkconstraint-l_order_header_rec.order_type_id:' || l_order_header_rec.order_type_id);

3623: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3624: IBE_Util.Debug('chkconstraint-l_order_header_rec.header_id:' || l_order_header_rec.header_id);
3625: IBE_Util.Debug('chkconstraint-l_order_header_rec.sold_to_org_id:' || l_order_header_rec.sold_to_org_id);
3626: IBE_Util.Debug('chkconstraint-l_order_header_rec.operation:' || l_order_header_rec.operation);
3627: IBE_Util.Debug('chkconstraint-l_order_header_rec.order_type_id:' || l_order_header_rec.order_type_id);
3628: END IF;
3629:
3630:
3631: -- SET LINE RECORD

Line 3656: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3652: l_order_line_tbl(i).ship_to_org_id := l_line_rec.SHIP_TO_ORG_ID;
3653: l_order_line_tbl(i).invoice_to_org_id := l_line_rec.INVOICE_TO_ORG_ID;
3654: end loop;
3655:
3656: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3657: IBE_Util.Debug('chkconstraint-l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3658: IBE_Util.Debug('chkconstraint-l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3659: IBE_Util.Debug('chkconstraint-l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3660: IBE_Util.Debug('chkconstraint-l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);

Line 3657: IBE_Util.Debug('chkconstraint-l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);

3653: l_order_line_tbl(i).invoice_to_org_id := l_line_rec.INVOICE_TO_ORG_ID;
3654: end loop;
3655:
3656: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3657: IBE_Util.Debug('chkconstraint-l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3658: IBE_Util.Debug('chkconstraint-l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3659: IBE_Util.Debug('chkconstraint-l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3660: IBE_Util.Debug('chkconstraint-l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3661: END IF;

Line 3658: IBE_Util.Debug('chkconstraint-l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);

3654: end loop;
3655:
3656: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3657: IBE_Util.Debug('chkconstraint-l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3658: IBE_Util.Debug('chkconstraint-l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3659: IBE_Util.Debug('chkconstraint-l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3660: IBE_Util.Debug('chkconstraint-l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3661: END IF;
3662:

Line 3659: IBE_Util.Debug('chkconstraint-l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);

3655:
3656: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3657: IBE_Util.Debug('chkconstraint-l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3658: IBE_Util.Debug('chkconstraint-l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3659: IBE_Util.Debug('chkconstraint-l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3660: IBE_Util.Debug('chkconstraint-l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3661: END IF;
3662:
3663: END LOOP;

Line 3660: IBE_Util.Debug('chkconstraint-l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);

3656: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3657: IBE_Util.Debug('chkconstraint-l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3658: IBE_Util.Debug('chkconstraint-l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3659: IBE_Util.Debug('chkconstraint-l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3660: IBE_Util.Debug('chkconstraint-l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3661: END IF;
3662:
3663: END LOOP;
3664:

Line 3672: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3668: l_order_header_rec.ship_to_org_id := l_siteuse_id;
3669: DefaultFromLineSiteId(l_order_line_tbl,p_party_id,'INVOICE_TO',l_siteuse_id);
3670: l_order_header_rec.invoice_to_org_id := l_siteuse_id;
3671:
3672: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3673: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.shiporgid: ' || l_order_header_rec.ship_to_org_id);
3674: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.invoiceorgid: ' || l_order_header_rec.invoice_to_org_id);
3675: END IF;
3676:

Line 3673: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.shiporgid: ' || l_order_header_rec.ship_to_org_id);

3669: DefaultFromLineSiteId(l_order_line_tbl,p_party_id,'INVOICE_TO',l_siteuse_id);
3670: l_order_header_rec.invoice_to_org_id := l_siteuse_id;
3671:
3672: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3673: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.shiporgid: ' || l_order_header_rec.ship_to_org_id);
3674: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.invoiceorgid: ' || l_order_header_rec.invoice_to_org_id);
3675: END IF;
3676:
3677: -- FIRST CALL To Process_Order to create only the Header Record. Bug#2988993

Line 3674: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.invoiceorgid: ' || l_order_header_rec.invoice_to_org_id);

3670: l_order_header_rec.invoice_to_org_id := l_siteuse_id;
3671:
3672: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3673: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.shiporgid: ' || l_order_header_rec.ship_to_org_id);
3674: IBE_Util.Debug('Chkconsrnt-l_order_header_rec.invoiceorgid: ' || l_order_header_rec.invoice_to_org_id);
3675: END IF;
3676:
3677: -- FIRST CALL To Process_Order to create only the Header Record. Bug#2988993
3678: -- This would avoid the NoDataFound thrown from OM as reported in the bug.

Line 3714: IF (IBE_UTIL.G_DEBUGON = l_true) then

3710: , x_Lot_Serial_val_tbl => l_lot_serial_val_tbl
3711: , x_action_request_tbl => l_action_request_tbl
3712: );
3713:
3714: IF (IBE_UTIL.G_DEBUGON = l_true) then
3715: IBE_UTIL.DEBUG('Return Status of First-Call to Process_Order() : ' || x_return_status);
3716: IBE_UTIL.DEBUG('header id from OE: ' || lx_order_header_rec.header_id);
3717: end if;
3718:

Line 3715: IBE_UTIL.DEBUG('Return Status of First-Call to Process_Order() : ' || x_return_status);

3711: , x_action_request_tbl => l_action_request_tbl
3712: );
3713:
3714: IF (IBE_UTIL.G_DEBUGON = l_true) then
3715: IBE_UTIL.DEBUG('Return Status of First-Call to Process_Order() : ' || x_return_status);
3716: IBE_UTIL.DEBUG('header id from OE: ' || lx_order_header_rec.header_id);
3717: end if;
3718:
3719: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then

Line 3716: IBE_UTIL.DEBUG('header id from OE: ' || lx_order_header_rec.header_id);

3712: );
3713:
3714: IF (IBE_UTIL.G_DEBUGON = l_true) then
3715: IBE_UTIL.DEBUG('Return Status of First-Call to Process_Order() : ' || x_return_status);
3716: IBE_UTIL.DEBUG('header id from OE: ' || lx_order_header_rec.header_id);
3717: end if;
3718:
3719: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then
3720: retrieve_oe_messages;

Line 3744: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3740:
3741: FOR i in 1..l_order_line_tbl.COUNT
3742: LOOP
3743: l_order_line_tbl(i).header_id := lx_order_header_rec.header_id;
3744: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3745: IBE_Util.Debug('l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);
3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);

Line 3745: IBE_Util.Debug('l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);

3741: FOR i in 1..l_order_line_tbl.COUNT
3742: LOOP
3743: l_order_line_tbl(i).header_id := lx_order_header_rec.header_id;
3744: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3745: IBE_Util.Debug('l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);
3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);

Line 3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);

3742: LOOP
3743: l_order_line_tbl(i).header_id := lx_order_header_rec.header_id;
3744: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3745: IBE_Util.Debug('l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);
3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);

Line 3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);

3743: l_order_line_tbl(i).header_id := lx_order_header_rec.header_id;
3744: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3745: IBE_Util.Debug('l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);
3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);

Line 3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);

3744: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3745: IBE_Util.Debug('l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);
3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);
3752: IBE_Util.Debug('l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);

Line 3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);

3745: IBE_Util.Debug('l_order_line_tbl.lineId: ' || l_order_line_tbl(i).line_id);
3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);
3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);
3752: IBE_Util.Debug('l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3753: IBE_Util.Debug('l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);

Line 3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);

3746: IBE_Util.Debug('l_order_line_tbl.HEaderId: ' || l_order_line_tbl(i).header_id);
3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);
3752: IBE_Util.Debug('l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3753: IBE_Util.Debug('l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3754: END IF;

Line 3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);

3747: IBE_Util.Debug('l_order_line_tbl.retattr1: ' || l_order_line_tbl(i).return_attribute1);
3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);
3752: IBE_Util.Debug('l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3753: IBE_Util.Debug('l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3754: END IF;
3755: END LOOP;

Line 3752: IBE_Util.Debug('l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);

3748: IBE_Util.Debug('l_order_line_tbl.retattr2: ' || l_order_line_tbl(i).return_attribute2);
3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);
3752: IBE_Util.Debug('l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3753: IBE_Util.Debug('l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3754: END IF;
3755: END LOOP;
3756:

Line 3753: IBE_Util.Debug('l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);

3749: IBE_Util.Debug('l_order_line_tbl.retcontxt: ' || l_order_line_tbl(i).return_context);
3750: IBE_Util.Debug('l_order_line_tbl.linetypeid: ' || l_order_line_tbl(i).line_type_id);
3751: IBE_Util.Debug('l_order_line_tbl.operation: ' || l_order_line_tbl(i).operation);
3752: IBE_Util.Debug('l_order_line_tbl.shiptoOrgid: ' || l_order_line_tbl(i).ship_to_org_id);
3753: IBE_Util.Debug('l_order_line_tbl.invoicetoOrgid: ' || l_order_line_tbl(i).invoice_to_org_id);
3754: END IF;
3755: END LOOP;
3756:
3757:

Line 3805: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3801: l_line_return_status := lx_line_tbl(j).return_status;
3802: l_line_return_attr2 := lx_line_tbl(j).return_attribute2;
3803:
3804: If(l_line_return_status <> 'S')then
3805: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3806: IBE_UTIL.DEBUG('line id returned from OE' || l_line_id );
3807: IBE_UTIL.DEBUG('return status returned from OE' || l_line_return_status);
3808: IBE_UTIL.DEBUG('return attribute2 returned from OE' || l_line_return_attr2);
3809: END IF;

Line 3806: IBE_UTIL.DEBUG('line id returned from OE' || l_line_id );

3802: l_line_return_attr2 := lx_line_tbl(j).return_attribute2;
3803:
3804: If(l_line_return_status <> 'S')then
3805: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3806: IBE_UTIL.DEBUG('line id returned from OE' || l_line_id );
3807: IBE_UTIL.DEBUG('return status returned from OE' || l_line_return_status);
3808: IBE_UTIL.DEBUG('return attribute2 returned from OE' || l_line_return_attr2);
3809: END IF;
3810:

Line 3807: IBE_UTIL.DEBUG('return status returned from OE' || l_line_return_status);

3803:
3804: If(l_line_return_status <> 'S')then
3805: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3806: IBE_UTIL.DEBUG('line id returned from OE' || l_line_id );
3807: IBE_UTIL.DEBUG('return status returned from OE' || l_line_return_status);
3808: IBE_UTIL.DEBUG('return attribute2 returned from OE' || l_line_return_attr2);
3809: END IF;
3810:
3811: l_count := l_count + 1;

Line 3808: IBE_UTIL.DEBUG('return attribute2 returned from OE' || l_line_return_attr2);

3804: If(l_line_return_status <> 'S')then
3805: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3806: IBE_UTIL.DEBUG('line id returned from OE' || l_line_id );
3807: IBE_UTIL.DEBUG('return status returned from OE' || l_line_return_status);
3808: IBE_UTIL.DEBUG('return attribute2 returned from OE' || l_line_return_attr2);
3809: END IF;
3810:
3811: l_count := l_count + 1;
3812: Fail_TmpLineRec_Tbl(l_count) := lx_line_tbl(j).return_attribute2;

Line 3826: IF (IBE_UTIL.G_DEBUGON = l_true) then

3822: x_error_lineids(k) := Fail_TmpLineRec_Tbl(k);
3823: end loop;
3824: end if;
3825:
3826: IF (IBE_UTIL.G_DEBUGON = l_true) then
3827: IBE_Util.debug('ChkConstraint Error Messages count: ' || x_msg_count ||' : '||x_return_status);
3828: end if;
3829:
3830: for j in 1 .. x_msg_count

Line 3827: IBE_Util.debug('ChkConstraint Error Messages count: ' || x_msg_count ||' : '||x_return_status);

3823: end loop;
3824: end if;
3825:
3826: IF (IBE_UTIL.G_DEBUGON = l_true) then
3827: IBE_Util.debug('ChkConstraint Error Messages count: ' || x_msg_count ||' : '||x_return_status);
3828: end if;
3829:
3830: for j in 1 .. x_msg_count
3831: loop

Line 3833: IF (IBE_UTIL.G_DEBUGON = l_true) then

3829:
3830: for j in 1 .. x_msg_count
3831: loop
3832: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
3833: IF (IBE_UTIL.G_DEBUGON = l_true) then
3834: IBE_Util.debug('Chk Constraint Exception Message' || x_msg_data);
3835: end if;
3836: end loop;
3837:

Line 3834: IBE_Util.debug('Chk Constraint Exception Message' || x_msg_data);

3830: for j in 1 .. x_msg_count
3831: loop
3832: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
3833: IF (IBE_UTIL.G_DEBUGON = l_true) then
3834: IBE_Util.debug('Chk Constraint Exception Message' || x_msg_data);
3835: end if;
3836: end loop;
3837:
3838: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then

Line 3863: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3859: THEN
3860: COMMIT WORK;
3861: END IF;
3862:
3863: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3864: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:CHECKCONSTRAINT()');
3865: END IF;
3866:
3867: -- Standard call to get message count and if count is 1, get message info.

Line 3864: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:CHECKCONSTRAINT()');

3860: COMMIT WORK;
3861: END IF;
3862:
3863: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3864: IBE_Util.Debug('End OE_ORDER_SAVE_PVT:CHECKCONSTRAINT()');
3865: END IF;
3866:
3867: -- Standard call to get message count and if count is 1, get message info.
3868: FND_MSG_PUB.Count_And_Get ( p_count => x_msg_count,

Line 3879: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3875: x_return_status := FND_API.G_RET_STS_ERROR;
3876: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3877: p_count => x_msg_count ,
3878: p_data => x_msg_data);
3879: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3880: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()'|| sqlerrm);
3881: END IF;
3882:
3883: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

Line 3880: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()'|| sqlerrm);

3876: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3877: p_count => x_msg_count ,
3878: p_data => x_msg_data);
3879: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3880: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()'|| sqlerrm);
3881: END IF;
3882:
3883: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3884: ROLLBACK TO ORDER_CHKCONSTRAINT;

Line 3889: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3885: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3886: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3887: p_count => x_msg_count ,
3888: p_data => x_msg_data);
3889: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3890: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()' || sqlerrm);
3891: END IF;
3892:
3893: WHEN OTHERS THEN

Line 3890: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()' || sqlerrm);

3886: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3887: p_count => x_msg_count ,
3888: p_data => x_msg_data);
3889: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3890: IBE_Util.Debug('UNEXPECTEDError IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()' || sqlerrm);
3891: END IF;
3892:
3893: WHEN OTHERS THEN
3894: ROLLBACK TO ORDER_CHKCONSTRAINT;

Line 3904: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3900:
3901: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3902: p_count => x_msg_count ,
3903: p_data => x_msg_data);
3904: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3905: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()' || sqlerrm);
3906: END IF;
3907:
3908: END CheckConstraint;

Line 3905: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()' || sqlerrm);

3901: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
3902: p_count => x_msg_count ,
3903: p_data => x_msg_data);
3904: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3905: IBE_Util.Debug('Other IBE_ORDER_SAVE_PVT:CHECKCONSTRAINT()' || sqlerrm);
3906: END IF;
3907:
3908: END CheckConstraint;
3909:

Line 3972: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3968: l_last_update_date DATE;
3969:
3970: BEGIN
3971:
3972: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3973: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:UpdateLinebilling()');
3974: END IF;
3975:
3976: -- Standard Start of API savepoint

Line 3973: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:UpdateLinebilling()');

3969:
3970: BEGIN
3971:
3972: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3973: IBE_Util.Debug('Begin IBE_ORDER_SAVE_PVT:UpdateLinebilling()');
3974: END IF;
3975:
3976: -- Standard Start of API savepoint
3977: SAVEPOINT ORDER_UPDTLINEBILL;

Line 3998: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

3994: x_return_status := FND_API.G_RET_STS_SUCCESS;
3995:
3996: -- Start OF API body --
3997:
3998: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3999: IBE_Util.Debug('Calling Validate Order Access');
4000: END IF;
4001:
4002: /********** User Authentication *************/

Line 3999: IBE_Util.Debug('Calling Validate Order Access');

3995:
3996: -- Start OF API body --
3997:
3998: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
3999: IBE_Util.Debug('Calling Validate Order Access');
4000: END IF;
4001:
4002: /********** User Authentication *************/
4003:

Line 4015: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4011: raise FND_API.G_EXC_ERROR;
4012: END IF;
4013: END IF;
4014:
4015: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4016: Ibe_util.Debug('checking the Return status');
4017: END IF;
4018:
4019:

Line 4016: Ibe_util.Debug('checking the Return status');

4012: END IF;
4013: END IF;
4014:
4015: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4016: Ibe_util.Debug('checking the Return status');
4017: END IF;
4018:
4019:
4020: Get_Order_Status(p_header_id => p_order_header_id

Line 4024: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4020: Get_Order_Status(p_header_id => p_order_header_id
4021: ,x_order_status => l_flow_status_code
4022: ,x_last_update_date => l_last_update_date);
4023:
4024: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4025: Ibe_util.Debug('last_update_date sent from ui: '||p_last_update_date);
4026: Ibe_util.Debug('last_update_date from db: '||l_last_update_date);
4027: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);
4028: END IF;

Line 4025: Ibe_util.Debug('last_update_date sent from ui: '||p_last_update_date);

4021: ,x_order_status => l_flow_status_code
4022: ,x_last_update_date => l_last_update_date);
4023:
4024: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4025: Ibe_util.Debug('last_update_date sent from ui: '||p_last_update_date);
4026: Ibe_util.Debug('last_update_date from db: '||l_last_update_date);
4027: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);
4028: END IF;
4029:

Line 4026: Ibe_util.Debug('last_update_date from db: '||l_last_update_date);

4022: ,x_last_update_date => l_last_update_date);
4023:
4024: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4025: Ibe_util.Debug('last_update_date sent from ui: '||p_last_update_date);
4026: Ibe_util.Debug('last_update_date from db: '||l_last_update_date);
4027: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);
4028: END IF;
4029:
4030: IF ((l_flow_status_code = 'BOOKED' OR l_flow_status_code='CLOSED' OR

Line 4027: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);

4023:
4024: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4025: Ibe_util.Debug('last_update_date sent from ui: '||p_last_update_date);
4026: Ibe_util.Debug('last_update_date from db: '||l_last_update_date);
4027: Ibe_util.Debug('l_flow_status_code: '||l_flow_status_code);
4028: END IF;
4029:
4030: IF ((l_flow_status_code = 'BOOKED' OR l_flow_status_code='CLOSED' OR
4031: l_flow_status_code = 'CANCELLED')

Line 4054: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4050: --l_siteuse_type := 'SHIP_TO';
4051: l_siteuse_shipto := 'SHIP_TO';
4052: END IF;
4053:
4054: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4055: IBE_Util.Debug('UpdateLinebilling-l_siteuse_billto: '||l_siteuse_billto||' : l_siteuse_shipto: '||l_siteuse_shipto);
4056: END IF;
4057:
4058: -- Fetching Invoice To Org Id.

Line 4055: IBE_Util.Debug('UpdateLinebilling-l_siteuse_billto: '||l_siteuse_billto||' : l_siteuse_shipto: '||l_siteuse_shipto);

4051: l_siteuse_shipto := 'SHIP_TO';
4052: END IF;
4053:
4054: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4055: IBE_Util.Debug('UpdateLinebilling-l_siteuse_billto: '||l_siteuse_billto||' : l_siteuse_shipto: '||l_siteuse_shipto);
4056: END IF;
4057:
4058: -- Fetching Invoice To Org Id.
4059:

Line 4074: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4070: ,x_msg_data => x_msg_data
4071: );
4072:
4073: IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
4074: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4075: IBE_Util.Debug('UpdateLinebilling- Get_Cust_Account_Site_Use() fails raise exception');
4076: END IF;
4077:
4078: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_BILLTO_ADDR');

Line 4075: IBE_Util.Debug('UpdateLinebilling- Get_Cust_Account_Site_Use() fails raise exception');

4071: );
4072:
4073: IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
4074: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4075: IBE_Util.Debug('UpdateLinebilling- Get_Cust_Account_Site_Use() fails raise exception');
4076: END IF;
4077:
4078: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_BILLTO_ADDR');
4079: FND_Msg_Pub.Add;

Line 4083: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4079: FND_Msg_Pub.Add;
4080: RAISE FND_API.G_EXC_ERROR;
4081: END IF;
4082:
4083: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4084: IBE_Util.Debug('UpdateLinebilling-l_acct_siteuse_id: ' || l_billto_acct_siteuse_id);
4085: END IF;
4086: end if;
4087:

Line 4084: IBE_Util.Debug('UpdateLinebilling-l_acct_siteuse_id: ' || l_billto_acct_siteuse_id);

4080: RAISE FND_API.G_EXC_ERROR;
4081: END IF;
4082:
4083: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4084: IBE_Util.Debug('UpdateLinebilling-l_acct_siteuse_id: ' || l_billto_acct_siteuse_id);
4085: END IF;
4086: end if;
4087:
4088: if(l_siteuse_shipto = 'SHIP_TO') then

Line 4102: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4098: ,x_msg_data => x_msg_data
4099: );
4100:
4101: IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
4102: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4103: IBE_Util.Debug('UpdateLinebilling- Get_Cust_Account_Site_Use() fails raise exception');
4104: END IF;
4105:
4106: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_SHIPTO_ADDR');

Line 4103: IBE_Util.Debug('UpdateLinebilling- Get_Cust_Account_Site_Use() fails raise exception');

4099: );
4100:
4101: IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
4102: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4103: IBE_Util.Debug('UpdateLinebilling- Get_Cust_Account_Site_Use() fails raise exception');
4104: END IF;
4105:
4106: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_SHIPTO_ADDR');
4107: FND_Msg_Pub.Add;

Line 4110: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4106: FND_Message.Set_Name('IBE', 'IBE_ERR_OT_INVALID_SHIPTO_ADDR');
4107: FND_Msg_Pub.Add;
4108: RAISE FND_API.G_EXC_ERROR;
4109: END IF;
4110: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4111: IBE_Util.Debug('UpdateLinebilling-l_acct_siteuse_id: ' || l_shipto_acct_siteuse_id);
4112: END IF;
4113:
4114: end if;

Line 4111: IBE_Util.Debug('UpdateLinebilling-l_acct_siteuse_id: ' || l_shipto_acct_siteuse_id);

4107: FND_Msg_Pub.Add;
4108: RAISE FND_API.G_EXC_ERROR;
4109: END IF;
4110: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4111: IBE_Util.Debug('UpdateLinebilling-l_acct_siteuse_id: ' || l_shipto_acct_siteuse_id);
4112: END IF;
4113:
4114: end if;
4115:

Line 4131: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4127: l_order_line_tbl(1).ship_to_org_id := l_shipto_acct_siteuse_id;
4128: end if;
4129:
4130: -- Fetching InvoiceToContactId
4131: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4132: IBE_Util.Debug('billto_ party_id :: billto_custacct_id: '||p_billto_party_id||' :: '||p_billto_cust_acct_id);
4133: END IF;
4134:
4135: If(p_billto_party_id is not null AND

Line 4132: IBE_Util.Debug('billto_ party_id :: billto_custacct_id: '||p_billto_party_id||' :: '||p_billto_cust_acct_id);

4128: end if;
4129:
4130: -- Fetching InvoiceToContactId
4131: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4132: IBE_Util.Debug('billto_ party_id :: billto_custacct_id: '||p_billto_party_id||' :: '||p_billto_cust_acct_id);
4133: END IF;
4134:
4135: If(p_billto_party_id is not null AND
4136: p_billto_party_id <> FND_API.G_MISS_NUM AND

Line 4171: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4167: l_order_line_tbl(1).ship_to_contact_id := l_cust_acct_role_id;
4168: end if;
4169:
4170:
4171: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4172: IBE_Util.Debug('Line Id: '||l_order_line_tbl(1).line_id);
4173: IBE_Util.Debug('Line operation: ' ||l_order_line_tbl(1).operation);
4174: IBE_Util.Debug('Line invoiceToOrgId: ' ||l_order_line_tbl(1).invoice_to_org_id);
4175: IBE_Util.Debug('Line InvoiceToContactId: '||l_order_line_tbl(1).invoice_to_contact_id);

Line 4172: IBE_Util.Debug('Line Id: '||l_order_line_tbl(1).line_id);

4168: end if;
4169:
4170:
4171: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4172: IBE_Util.Debug('Line Id: '||l_order_line_tbl(1).line_id);
4173: IBE_Util.Debug('Line operation: ' ||l_order_line_tbl(1).operation);
4174: IBE_Util.Debug('Line invoiceToOrgId: ' ||l_order_line_tbl(1).invoice_to_org_id);
4175: IBE_Util.Debug('Line InvoiceToContactId: '||l_order_line_tbl(1).invoice_to_contact_id);
4176: ENd If;

Line 4173: IBE_Util.Debug('Line operation: ' ||l_order_line_tbl(1).operation);

4169:
4170:
4171: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4172: IBE_Util.Debug('Line Id: '||l_order_line_tbl(1).line_id);
4173: IBE_Util.Debug('Line operation: ' ||l_order_line_tbl(1).operation);
4174: IBE_Util.Debug('Line invoiceToOrgId: ' ||l_order_line_tbl(1).invoice_to_org_id);
4175: IBE_Util.Debug('Line InvoiceToContactId: '||l_order_line_tbl(1).invoice_to_contact_id);
4176: ENd If;
4177:

Line 4174: IBE_Util.Debug('Line invoiceToOrgId: ' ||l_order_line_tbl(1).invoice_to_org_id);

4170:
4171: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4172: IBE_Util.Debug('Line Id: '||l_order_line_tbl(1).line_id);
4173: IBE_Util.Debug('Line operation: ' ||l_order_line_tbl(1).operation);
4174: IBE_Util.Debug('Line invoiceToOrgId: ' ||l_order_line_tbl(1).invoice_to_org_id);
4175: IBE_Util.Debug('Line InvoiceToContactId: '||l_order_line_tbl(1).invoice_to_contact_id);
4176: ENd If;
4177:
4178: SaveMDLRelatedOperations(p_context_type => 'UPDATELINES',

Line 4175: IBE_Util.Debug('Line InvoiceToContactId: '||l_order_line_tbl(1).invoice_to_contact_id);

4171: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4172: IBE_Util.Debug('Line Id: '||l_order_line_tbl(1).line_id);
4173: IBE_Util.Debug('Line operation: ' ||l_order_line_tbl(1).operation);
4174: IBE_Util.Debug('Line invoiceToOrgId: ' ||l_order_line_tbl(1).invoice_to_org_id);
4175: IBE_Util.Debug('Line InvoiceToContactId: '||l_order_line_tbl(1).invoice_to_contact_id);
4176: ENd If;
4177:
4178: SaveMDLRelatedOperations(p_context_type => 'UPDATELINES',
4179: p_order_line_tbl => l_order_line_tbl,

Line 4189: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4185: loop
4186: l_order_line_tbl(i) := lx_line_tbl(i);
4187: end loop;
4188:
4189: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4190: IBE_Util.Debug('UpdateLine Linetbl cnt b4 processOrder '||l_order_line_tbl.count);
4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);
4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);

Line 4190: IBE_Util.Debug('UpdateLine Linetbl cnt b4 processOrder '||l_order_line_tbl.count);

4186: l_order_line_tbl(i) := lx_line_tbl(i);
4187: end loop;
4188:
4189: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4190: IBE_Util.Debug('UpdateLine Linetbl cnt b4 processOrder '||l_order_line_tbl.count);
4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);
4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);
4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);

Line 4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);

4187: end loop;
4188:
4189: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4190: IBE_Util.Debug('UpdateLine Linetbl cnt b4 processOrder '||l_order_line_tbl.count);
4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);
4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);
4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);
4195: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_CONTACT_ID);

Line 4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);

4188:
4189: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4190: IBE_Util.Debug('UpdateLine Linetbl cnt b4 processOrder '||l_order_line_tbl.count);
4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);
4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);
4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);
4195: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_CONTACT_ID);
4196: IBE_Util.Debug('check this: '||l_order_line_tbl(1).OPERATION);

Line 4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);

4189: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4190: IBE_Util.Debug('UpdateLine Linetbl cnt b4 processOrder '||l_order_line_tbl.count);
4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);
4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);
4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);
4195: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_CONTACT_ID);
4196: IBE_Util.Debug('check this: '||l_order_line_tbl(1).OPERATION);
4197: END IF;

Line 4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);

4190: IBE_Util.Debug('UpdateLine Linetbl cnt b4 processOrder '||l_order_line_tbl.count);
4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);
4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);
4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);
4195: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_CONTACT_ID);
4196: IBE_Util.Debug('check this: '||l_order_line_tbl(1).OPERATION);
4197: END IF;
4198:

Line 4195: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_CONTACT_ID);

4191: IBE_Util.Debug('check this: '||l_order_line_tbl(1).LINE_ID);
4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);
4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);
4195: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_CONTACT_ID);
4196: IBE_Util.Debug('check this: '||l_order_line_tbl(1).OPERATION);
4197: END IF;
4198:
4199: -- Calling Process Order

Line 4196: IBE_Util.Debug('check this: '||l_order_line_tbl(1).OPERATION);

4192: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_ORG_ID);
4193: IBE_Util.Debug('check this: '||l_order_line_tbl(1).INVOICE_TO_CONTACT_ID);
4194: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_ORG_ID);
4195: IBE_Util.Debug('check this: '||l_order_line_tbl(1).SHIP_TO_CONTACT_ID);
4196: IBE_Util.Debug('check this: '||l_order_line_tbl(1).OPERATION);
4197: END IF;
4198:
4199: -- Calling Process Order
4200: OE_Order_GRP.Process_Order

Line 4235: IF (IBE_UTIL.G_DEBUGON = l_true) then

4231: , x_Lot_Serial_val_tbl => l_lot_serial_val_tbl
4232: , x_action_request_tbl => l_action_request_tbl
4233: );
4234:
4235: IF (IBE_UTIL.G_DEBUGON = l_true) then
4236: IBE_UTIL.DEBUG('Return status from OE updatelinebill: ' || x_return_status);
4237: IBE_UTIL.DEBUG('header id from OE updatelinebill: ' || lx_order_header_rec.header_id);
4238: end if;
4239:

Line 4236: IBE_UTIL.DEBUG('Return status from OE updatelinebill: ' || x_return_status);

4232: , x_action_request_tbl => l_action_request_tbl
4233: );
4234:
4235: IF (IBE_UTIL.G_DEBUGON = l_true) then
4236: IBE_UTIL.DEBUG('Return status from OE updatelinebill: ' || x_return_status);
4237: IBE_UTIL.DEBUG('header id from OE updatelinebill: ' || lx_order_header_rec.header_id);
4238: end if;
4239:
4240: for j in 1 .. x_msg_count

Line 4237: IBE_UTIL.DEBUG('header id from OE updatelinebill: ' || lx_order_header_rec.header_id);

4233: );
4234:
4235: IF (IBE_UTIL.G_DEBUGON = l_true) then
4236: IBE_UTIL.DEBUG('Return status from OE updatelinebill: ' || x_return_status);
4237: IBE_UTIL.DEBUG('header id from OE updatelinebill: ' || lx_order_header_rec.header_id);
4238: end if;
4239:
4240: for j in 1 .. x_msg_count
4241: loop

Line 4243: IF (IBE_UTIL.G_DEBUGON = l_true) then

4239:
4240: for j in 1 .. x_msg_count
4241: loop
4242: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
4243: IF (IBE_UTIL.G_DEBUGON = l_true) then
4244: IBE_UTIL.DEBUG('Message from OE update line bill: ' || x_msg_data );
4245: end if;
4246: end loop;
4247:

Line 4244: IBE_UTIL.DEBUG('Message from OE update line bill: ' || x_msg_data );

4240: for j in 1 .. x_msg_count
4241: loop
4242: x_msg_data:= OE_MSG_PUB.get(fnd_msg_pub.g_next,FND_API.G_FALSE);
4243: IF (IBE_UTIL.G_DEBUGON = l_true) then
4244: IBE_UTIL.DEBUG('Message from OE update line bill: ' || x_msg_data );
4245: end if;
4246: end loop;
4247:
4248: IF x_return_status <> FND_API.G_RET_STS_SUCCESS then

Line 4267: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4263: THEN
4264: COMMIT WORK;
4265: END IF;
4266:
4267: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4268: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:UpdateLinebilling()');
4269: END IF;
4270:
4271: -- Standard call to get message count and if count is 1, get message info.

Line 4268: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:UpdateLinebilling()');

4264: COMMIT WORK;
4265: END IF;
4266:
4267: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4268: IBE_Util.Debug('End IBE_ORDER_SAVE_PVT:UpdateLinebilling()');
4269: END IF;
4270:
4271: -- Standard call to get message count and if count is 1, get message info.
4272: FND_MSG_PUB.Count_And_Get ( p_count => x_msg_count,

Line 4282: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4278: x_return_status := FND_API.G_RET_STS_ERROR;
4279: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
4280: p_count => x_msg_count ,
4281: p_data => x_msg_data);
4282: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4283: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()'|| sqlerrm);
4284: END IF;
4285:
4286: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

Line 4283: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()'|| sqlerrm);

4279: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
4280: p_count => x_msg_count ,
4281: p_data => x_msg_data);
4282: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4283: IBE_Util.Debug('Error IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()'|| sqlerrm);
4284: END IF;
4285:
4286: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
4287: ROLLBACK TO ORDER_UPDTLINEBILL;

Line 4292: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4288: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
4289: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
4290: p_count => x_msg_count ,
4291: p_data => x_msg_data);
4292: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4293: IBE_Util.Debug('UNEXPECTEDErr IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()' || sqlerrm);
4294: END IF;
4295:
4296: WHEN OTHERS THEN

Line 4293: IBE_Util.Debug('UNEXPECTEDErr IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()' || sqlerrm);

4289: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
4290: p_count => x_msg_count ,
4291: p_data => x_msg_data);
4292: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4293: IBE_Util.Debug('UNEXPECTEDErr IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()' || sqlerrm);
4294: END IF;
4295:
4296: WHEN OTHERS THEN
4297: ROLLBACK TO ORDER_UPDTLINEBILL;

Line 4307: IF (IBE_UTIL.G_DEBUGON = l_true) THEN

4303:
4304: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
4305: p_count => x_msg_count ,
4306: p_data => x_msg_data);
4307: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4308: IBE_Util.Debug('OtherExc IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()' || sqlerrm);
4309: END IF;
4310:
4311: END UpdateLineShippingBilling;

Line 4308: IBE_Util.Debug('OtherExc IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()' || sqlerrm);

4304: FND_Msg_Pub.Count_And_Get(p_encoded => FND_API.G_FALSE,
4305: p_count => x_msg_count ,
4306: p_data => x_msg_data);
4307: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
4308: IBE_Util.Debug('OtherExc IBE_ORDER_SAVE_PVT:UpdateLineShippingBilling()' || sqlerrm);
4309: END IF;
4310:
4311: END UpdateLineShippingBilling;
4312: