DBA Data[Home] [Help]

APPS.EAM_OPERATIONS_JSP dependencies on FND_API

Line 158: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE

154: -- and convert it the the message that can be accepted by JSP pages
155: --------------------------------------------------------------------------
156: procedure complete_operation
157: ( p_api_version IN NUMBER := 1.0
158: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
159: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
160: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
161: ,p_record_version_number IN NUMBER := NULL
162: ,x_return_status OUT NOCOPY VARCHAR2

Line 159: ,p_commit IN VARCHAR2 := FND_API.G_FALSE

155: --------------------------------------------------------------------------
156: procedure complete_operation
157: ( p_api_version IN NUMBER := 1.0
158: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
159: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
160: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
161: ,p_record_version_number IN NUMBER := NULL
162: ,x_return_status OUT NOCOPY VARCHAR2
163: ,x_msg_count OUT NOCOPY NUMBER

Line 160: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE

156: procedure complete_operation
157: ( p_api_version IN NUMBER := 1.0
158: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
159: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
160: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
161: ,p_record_version_number IN NUMBER := NULL
162: ,x_return_status OUT NOCOPY VARCHAR2
163: ,x_msg_count OUT NOCOPY NUMBER
164: ,x_msg_data OUT NOCOPY VARCHAR2

Line 239: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,

235:
236:
237: eam_debug.init_err_stack('eam_operations_jsp.complete_operation');
238:
239: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,
240: p_api_version,
241: l_api_name,
242: g_pkg_name)
243: THEN

Line 244: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

240: p_api_version,
241: l_api_name,
242: g_pkg_name)
243: THEN
244: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
245: END IF;
246:
247: IF FND_API.TO_BOOLEAN(p_init_msg_list)
248: THEN

Line 247: IF FND_API.TO_BOOLEAN(p_init_msg_list)

243: THEN
244: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
245: END IF;
246:
247: IF FND_API.TO_BOOLEAN(p_init_msg_list)
248: THEN
249: FND_MSG_PUB.initialize;
250: END IF;
251:

Line 252: x_return_status := FND_API.G_RET_STS_SUCCESS;

248: THEN
249: FND_MSG_PUB.initialize;
250: END IF;
251:
252: x_return_status := FND_API.G_RET_STS_SUCCESS;
253:
254: -- check if data is stale or not
255: -- using last_update_date as indicator
256: BEGIN

Line 283: x_return_status := FND_API.G_RET_STS_ERROR;

279:
280:
281: IF l_db_last_update_date <> p_stored_last_update_date THEN
282: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_WO_STALED_DATA');
283: x_return_status := FND_API.G_RET_STS_ERROR;
284: END IF;
285: IF ( (p_transaction_type = 1 AND l_db_status = 'Y') or
286: (p_transaction_type = 2 and nvl(l_db_status,'N') = 'N' )) THEN
287: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_WO_STALED_DATA');

Line 288: x_return_status := FND_API.G_RET_STS_ERROR;

284: END IF;
285: IF ( (p_transaction_type = 1 AND l_db_status = 'Y') or
286: (p_transaction_type = 2 and nvl(l_db_status,'N') = 'N' )) THEN
287: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_WO_STALED_DATA');
288: x_return_status := FND_API.G_RET_STS_ERROR;
289: END IF;
290: IF ( not( p_shutdown_start_date is null and p_shutdown_end_date is null) and
291: ( p_shutdown_start_date is null or p_shutdown_end_date is null) ) THEN
292: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_SHUTDOWN_DATE_MISS');

Line 293: x_return_status := FND_API.G_RET_STS_ERROR;

289: END IF;
290: IF ( not( p_shutdown_start_date is null and p_shutdown_end_date is null) and
291: ( p_shutdown_start_date is null or p_shutdown_end_date is null) ) THEN
292: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_SHUTDOWN_DATE_MISS');
293: x_return_status := FND_API.G_RET_STS_ERROR;
294: END IF;
295: --changed the following if condition as part of bug 5476770
296: IF ( p_shutdown_start_date is not null and p_shutdown_end_date is not null and
297: p_shutdown_end_date > sysdate ) THEN

Line 299: x_return_status := FND_API.G_RET_STS_ERROR;

295: --changed the following if condition as part of bug 5476770
296: IF ( p_shutdown_start_date is not null and p_shutdown_end_date is not null and
297: p_shutdown_end_date > sysdate ) THEN
298: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_SHUTDOWN_DATE_IN_FUTURE');
299: x_return_status := FND_API.G_RET_STS_ERROR;
300: ELSIF ( p_shutdown_start_date is not null and p_shutdown_end_date is not null and
301: p_shutdown_start_date > p_shutdown_end_date ) THEN
302: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_SHUTDOWN_DATE_BAD');
303: x_return_status := FND_API.G_RET_STS_ERROR;

Line 303: x_return_status := FND_API.G_RET_STS_ERROR;

299: x_return_status := FND_API.G_RET_STS_ERROR;
300: ELSIF ( p_shutdown_start_date is not null and p_shutdown_end_date is not null and
301: p_shutdown_start_date > p_shutdown_end_date ) THEN
302: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_SHUTDOWN_DATE_BAD');
303: x_return_status := FND_API.G_RET_STS_ERROR;
304: END IF;
305: --end of change for bug 5476770
306: IF (l_act_duration < 0) THEN
307: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_COMP_DURATION_BAD');

Line 308: x_return_status := FND_API.G_RET_STS_ERROR;

304: END IF;
305: --end of change for bug 5476770
306: IF (l_act_duration < 0) THEN
307: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_COMP_DURATION_BAD');
308: x_return_status := FND_API.G_RET_STS_ERROR;
309: END IF;
310:
311: EXCEPTION WHEN NO_DATA_FOUND THEN -- Bug 3133704 .changed WHEN OTHERS to WHEN NO_DATA_FOUND
312: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_OP_NOT_FOUND');

Line 313: x_return_status := FND_API.G_RET_STS_ERROR;

309: END IF;
310:
311: EXCEPTION WHEN NO_DATA_FOUND THEN -- Bug 3133704 .changed WHEN OTHERS to WHEN NO_DATA_FOUND
312: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_OP_NOT_FOUND');
313: x_return_status := FND_API.G_RET_STS_ERROR;
314: END;
315:
316:
317: /* Fix for Bug 2100416 */

Line 328: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

324:
325: if (l_act_st_date is not null) and (l_act_duration is not null) then
326: if (l_act_end_date > sysdate) then
327: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_END_LATER_THAN_TODAY');
328: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
329: end if;
330: /* The following line is commented out for bug no:2728447 */
331: -- if (p_actual_start_date < l_open_acct_per_date) then
332: /*Fix for bug 3235163*/

Line 336: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

332: /*Fix for bug 3235163*/
333: --Previously end date was checked with closed period.Changed that to check transaction_date
334: if (p_transaction_date < l_open_acct_per_date) then
335: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_TRANSACTION_DATE_INVALID');
336: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
337: end if;
338: /*End of fix for bug 3235163*/
339: end if;
340:

Line 354: x_return_status := FND_API.G_RET_STS_ERROR; --Bug .

350: and ml.meaning = p_reconciliation_code;
351: end if;
352: EXCEPTION WHEN NO_DATA_FOUND THEN -- Bug 3133704,changed OTHERS to NO_DATA_FOUND
353: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_RECONCILIATION_CODE_INV');
354: x_return_status := FND_API.G_RET_STS_ERROR; --Bug .
355: END;
356:
357: -- if validate not passed then raise error
358: l_msg_count := FND_MSG_PUB.count_msg;

Line 361: (p_encoded => FND_API.G_FALSE,

357: -- if validate not passed then raise error
358: l_msg_count := FND_MSG_PUB.count_msg;
359: IF l_msg_count = 1 THEN
360: eam_execution_jsp.Get_Messages
361: (p_encoded => FND_API.G_FALSE,
362: p_msg_index => 1,
363: p_msg_count => l_msg_count,
364: p_msg_data => l_msg_data, -- removed g_miss_char
365: p_data => l_data,

Line 374: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

370: x_msg_count := l_msg_count;
371: END IF;
372:
373: IF l_msg_count > 0 THEN
374: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
375: RAISE FND_API.G_EXC_ERROR;
376: END IF;
377:
378: -------------------------------------------

Line 375: RAISE FND_API.G_EXC_ERROR;

371: END IF;
372:
373: IF l_msg_count > 0 THEN
374: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
375: RAISE FND_API.G_EXC_ERROR;
376: END IF;
377:
378: -------------------------------------------
379: -- how to compute date by interval, how many hours a day???

Line 434: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

430: end;
431:
432: if( l_err_code >0) then
433: -- add_message(p_app_short_name => 'EAM', p_msg_name => l_err_msg);
434: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
435: end if;
436:
437: l_msg_count := FND_MSG_PUB.count_msg;
438: IF l_msg_count = 1 THEN

Line 440: (p_encoded => FND_API.G_FALSE,

436:
437: l_msg_count := FND_MSG_PUB.count_msg;
438: IF l_msg_count = 1 THEN
439: eam_execution_jsp.Get_Messages
440: (p_encoded => FND_API.G_FALSE,
441: p_msg_index => 1,
442: p_msg_count => l_msg_count,
443: p_msg_data => l_msg_data, -- removed g_miss_char
444: p_data => l_data,

Line 453: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

449: x_msg_count := l_msg_count;
450: END IF;
451:
452: IF l_msg_count > 0 THEN
453: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
454: RAISE FND_API.G_EXC_ERROR;
455: END IF;
456:
457: IF FND_API.TO_BOOLEAN(P_COMMIT)

Line 454: RAISE FND_API.G_EXC_ERROR;

450: END IF;
451:
452: IF l_msg_count > 0 THEN
453: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
454: RAISE FND_API.G_EXC_ERROR;
455: END IF;
456:
457: IF FND_API.TO_BOOLEAN(P_COMMIT)
458: THEN

Line 457: IF FND_API.TO_BOOLEAN(P_COMMIT)

453: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
454: RAISE FND_API.G_EXC_ERROR;
455: END IF;
456:
457: IF FND_API.TO_BOOLEAN(P_COMMIT)
458: THEN
459: COMMIT WORK;
460: END IF;
461:

Line 462: EXCEPTION WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

458: THEN
459: COMMIT WORK;
460: END IF;
461:
462: EXCEPTION WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
463: ROLLBACK TO complete_workorder;
464:
465:
466: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.complete_operation',

Line 468: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

464:
465:
466: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.complete_operation',
467: p_procedure_name => EAM_DEBUG.G_err_stack);
468: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
469: WHEN FND_API.G_EXC_ERROR THEN
470: ROLLBACK TO complete_workorder;
471:
472:

Line 469: WHEN FND_API.G_EXC_ERROR THEN

465:
466: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.complete_operation',
467: p_procedure_name => EAM_DEBUG.G_err_stack);
468: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
469: WHEN FND_API.G_EXC_ERROR THEN
470: ROLLBACK TO complete_workorder;
471:
472:
473: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.complete_operation',

Line 475: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

471:
472:
473: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.complete_operation',
474: p_procedure_name => EAM_DEBUG.G_err_stack);
475: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
476: WHEN OTHERS THEN
477: ROLLBACK TO complete_workorder;
478:
479:

Line 482: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

478:
479:
480: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.complete_operation',
481: p_procedure_name => EAM_DEBUG.G_err_stack);
482: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
483: END complete_operation;
484:
485: ------------------------------------------------------------------------------------
486: -- performing operation handover for jsp pages

Line 491: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE

487: -- use the column last_update_date for optimistic locking
488: ------------------------------------------------------------------------------------
489: procedure operation_handover
490: ( p_api_version IN NUMBER := 1.0
491: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
492: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
493: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
494: ,p_record_version_number IN NUMBER := NULL
495: ,x_return_status OUT NOCOPY VARCHAR2

Line 492: ,p_commit IN VARCHAR2 := FND_API.G_FALSE

488: ------------------------------------------------------------------------------------
489: procedure operation_handover
490: ( p_api_version IN NUMBER := 1.0
491: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
492: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
493: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
494: ,p_record_version_number IN NUMBER := NULL
495: ,x_return_status OUT NOCOPY VARCHAR2
496: ,x_msg_count OUT NOCOPY NUMBER

Line 493: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE

489: procedure operation_handover
490: ( p_api_version IN NUMBER := 1.0
491: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
492: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
493: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
494: ,p_record_version_number IN NUMBER := NULL
495: ,x_return_status OUT NOCOPY VARCHAR2
496: ,x_msg_count OUT NOCOPY NUMBER
497: ,x_msg_data OUT NOCOPY VARCHAR2

Line 586: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,

582:
583:
584: eam_debug.init_err_stack('eam_operations_jsp.operation_handover');
585:
586: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,
587: p_api_version,
588: l_api_name,
589: g_pkg_name)
590: THEN

Line 591: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

587: p_api_version,
588: l_api_name,
589: g_pkg_name)
590: THEN
591: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
592: END IF;
593:
594: IF FND_API.TO_BOOLEAN(p_init_msg_list)
595: THEN

Line 594: IF FND_API.TO_BOOLEAN(p_init_msg_list)

590: THEN
591: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
592: END IF;
593:
594: IF FND_API.TO_BOOLEAN(p_init_msg_list)
595: THEN
596: FND_MSG_PUB.initialize;
597: END IF;
598:

Line 602: x_return_status := FND_API.G_RET_STS_SUCCESS;

598:
599: EAM_WORKORDER_UTIL_PKG.log_path(l_output_dir);
600:
601:
602: x_return_status := FND_API.G_RET_STS_SUCCESS;
603:
604: -----------------------------------------------------------------
605: -- validation
606: -- check if data is stale or not

Line 633: x_return_status := FND_API.G_RET_STS_ERROR;

629:
630: -- checking stuff
631: IF l_db_last_update_date <> nvl(p_stored_last_update_date, l_db_last_update_date) THEN
632: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_OP_STALED_DATA');
633: x_return_status := FND_API.G_RET_STS_ERROR;
634: END IF;
635: IF ( nvl(l_completed, 'N') = 'Y' ) THEN
636: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_CANT_STATUS_Y');
637: x_return_status := FND_API.G_RET_STS_ERROR;

Line 637: x_return_status := FND_API.G_RET_STS_ERROR;

633: x_return_status := FND_API.G_RET_STS_ERROR;
634: END IF;
635: IF ( nvl(l_completed, 'N') = 'Y' ) THEN
636: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_CANT_STATUS_Y');
637: x_return_status := FND_API.G_RET_STS_ERROR;
638: END IF;
639:
640: IF (p_start_date > p_completion_date) THEN
641: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_DATE_BAD');

Line 642: x_return_status := FND_API.G_RET_STS_ERROR;

638: END IF;
639:
640: IF (p_start_date > p_completion_date) THEN
641: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_DATE_BAD');
642: x_return_status := FND_API.G_RET_STS_ERROR;
643: END IF;
644:
645:
646: select count(*)

Line 651: x_return_status := FND_API.G_RET_STS_ERROR;

647: into l_count from wip_operations
648: where wip_entity_id = p_wip_entity_id and operation_seq_num = p_new_op_seq_num;
649: IF( l_count > 0 ) THEN
650: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_OP_EXISTED');
651: x_return_status := FND_API.G_RET_STS_ERROR;
652: END IF;
653:
654: -- Bug 3133704 . removed count for department_code within an org. For a given org id , dept code is unique.
655: select department_id

Line 662: x_return_status := FND_API.G_RET_STS_ERROR;

658: where organization_id = l_org_id
659: and department_code like p_assigned_department;
660: if(l_department_id = l_old_dept_id) then
661: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_DEPT_SAME');
662: x_return_status := FND_API.G_RET_STS_ERROR;
663: end if;
664:
665:
666: EXCEPTION WHEN NO_DATA_FOUND THEN

Line 668: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

664:
665:
666: EXCEPTION WHEN NO_DATA_FOUND THEN
667: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_OP_NOT_FOUND');
668: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
669: END;
670:
671: -- if validate not passed then raise error
672: l_msg_count := FND_MSG_PUB.count_msg;

Line 675: (p_encoded => FND_API.G_FALSE,

671: -- if validate not passed then raise error
672: l_msg_count := FND_MSG_PUB.count_msg;
673: IF l_msg_count = 1 THEN
674: eam_execution_jsp.Get_Messages
675: (p_encoded => FND_API.G_FALSE,
676: p_msg_index => 1,
677: p_msg_count => l_msg_count,
678: p_msg_data => l_msg_data, -- removed g_miss_char
679: p_data => l_data,

Line 688: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

684: x_msg_count := l_msg_count;
685: END IF;
686:
687: IF l_msg_count > 0 THEN
688: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
689: RAISE FND_API.G_EXC_ERROR;
690: END IF;
691:
692: ---------------------------------------------------

Line 689: RAISE FND_API.G_EXC_ERROR;

685: END IF;
686:
687: IF l_msg_count > 0 THEN
688: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
689: RAISE FND_API.G_EXC_ERROR;
690: END IF;
691:
692: ---------------------------------------------------
693: -- prepare for DML

Line 749: IF (x_return_status = FND_API.G_RET_STS_SUCCESS) THEN

745: );
746:
747: end if;
748:
749: IF (x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
750:
751:
752: select max(transaction_id) into l_transaction_id
753: from eam_op_completion_txns

Line 886: (p_encoded => FND_API.G_FALSE,

882: -- check error
883: l_msg_count := FND_MSG_PUB.count_msg;
884: IF l_msg_count = 1 THEN
885: eam_execution_jsp.Get_Messages
886: (p_encoded => FND_API.G_FALSE,
887: p_msg_index => 1,
888: p_msg_count => l_msg_count,
889: p_msg_data => l_msg_data,
890: p_data => l_data,

Line 899: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

895: x_msg_count := l_msg_count;
896: END IF;
897:
898: IF (l_msg_count > 0 AND Nvl(x_return_status,'E') <> 'S') THEN
899: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
900: RAISE FND_API.G_EXC_ERROR;
901: END IF;
902:
903:

Line 900: RAISE FND_API.G_EXC_ERROR;

896: END IF;
897:
898: IF (l_msg_count > 0 AND Nvl(x_return_status,'E') <> 'S') THEN
899: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
900: RAISE FND_API.G_EXC_ERROR;
901: END IF;
902:
903:
904: IF FND_API.TO_BOOLEAN(P_COMMIT)

Line 904: IF FND_API.TO_BOOLEAN(P_COMMIT)

900: RAISE FND_API.G_EXC_ERROR;
901: END IF;
902:
903:
904: IF FND_API.TO_BOOLEAN(P_COMMIT)
905: THEN
906: COMMIT WORK;
907: END IF;
908:

Line 909: EXCEPTION WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

905: THEN
906: COMMIT WORK;
907: END IF;
908:
909: EXCEPTION WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
910: ROLLBACK TO operation_handover;
911:
912: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover',
913: p_procedure_name => EAM_DEBUG.G_err_stack);

Line 914: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

910: ROLLBACK TO operation_handover;
911:
912: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover',
913: p_procedure_name => EAM_DEBUG.G_err_stack);
914: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
915: WHEN FND_API.G_EXC_ERROR THEN
916: ROLLBACK TO operation_handover;
917:
918:

Line 915: WHEN FND_API.G_EXC_ERROR THEN

911:
912: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover',
913: p_procedure_name => EAM_DEBUG.G_err_stack);
914: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
915: WHEN FND_API.G_EXC_ERROR THEN
916: ROLLBACK TO operation_handover;
917:
918:
919: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover',

Line 921: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

917:
918:
919: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover',
920: p_procedure_name => EAM_DEBUG.G_err_stack);
921: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
922: WHEN OTHERS THEN
923: ROLLBACK TO operation_handover;
924:
925:

Line 928: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

924:
925:
926: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover',
927: p_procedure_name => EAM_DEBUG.G_err_stack);
928: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
929: g_debug_sqlerrm := SQLERRM;
930:
931: END operation_handover;
932:

Line 1024: x_return_status := FND_API.G_RET_STS_SUCCESS;

1020:
1021: BEGIN
1022: -- copy: xxx-> newop
1023:
1024: x_return_status := FND_API.G_RET_STS_SUCCESS;
1025:
1026: FOR nxtOpCurVar IN nxtOpCur LOOP
1027:
1028:

Line 1048: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1044: END IF;
1045:
1046: IF (p_operation_start_date < l_actual_end_date) THEN
1047: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_INV_START_DATE');
1048: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1049: END IF;
1050:
1051: IF NVL(l_completed,'N') = 'N' THEN
1052: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_INVALID_COMPLETE_OP2');

Line 1053: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1049: END IF;
1050:
1051: IF NVL(l_completed,'N') = 'N' THEN
1052: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_INVALID_COMPLETE_OP2');
1053: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1054: END IF;
1055:
1056:
1057: EXCEPTION WHEN NO_DATA_FOUND THEN -- Bug 3133704, others -> no_data_found

Line 1059: x_return_status := FND_API.G_RET_STS_ERROR;

1055:
1056:
1057: EXCEPTION WHEN NO_DATA_FOUND THEN -- Bug 3133704, others -> no_data_found
1058: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_OP_NOTFOUND');
1059: x_return_status := FND_API.G_RET_STS_ERROR;
1060: END;
1061:
1062: IF x_return_status = FND_API.G_RET_STS_SUCCESS THEN
1063:

Line 1062: IF x_return_status = FND_API.G_RET_STS_SUCCESS THEN

1058: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_OP_NOTFOUND');
1059: x_return_status := FND_API.G_RET_STS_ERROR;
1060: END;
1061:
1062: IF x_return_status = FND_API.G_RET_STS_SUCCESS THEN
1063:
1064: nxtOpCurVar.next_operation := p_new_op_seq_num;
1065: nxtOpCurVar.last_updated_by := FND_GLOBAL.user_id;
1066: nxtOpCurVar.last_update_login := FND_GLOBAL.user_id;

Line 1153: x_return_status := FND_API.G_RET_STS_ERROR;

1149: END IF;
1150:
1151: IF (NVL(l_completed, 'N' ) = 'Y') THEN
1152: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_INVALID_COMPLETE_OP1');
1153: x_return_status := FND_API.G_RET_STS_ERROR;
1154: END IF;
1155:
1156: IF (l_actual_start_date < p_operation_completion_date ) THEN
1157: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_INV_END_DATE');

Line 1158: x_return_status := FND_API.G_RET_STS_ERROR;

1154: END IF;
1155:
1156: IF (l_actual_start_date < p_operation_completion_date ) THEN
1157: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_INV_END_DATE');
1158: x_return_status := FND_API.G_RET_STS_ERROR;
1159: END IF;
1160:
1161: EXCEPTION WHEN NO_DATA_FOUND THEN -- Bug 3133704, others -> no_data_found
1162: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_OP_NOTFOUND');

Line 1163: x_return_status := FND_API.G_RET_STS_ERROR;

1159: END IF;
1160:
1161: EXCEPTION WHEN NO_DATA_FOUND THEN -- Bug 3133704, others -> no_data_found
1162: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_OP_NOTFOUND');
1163: x_return_status := FND_API.G_RET_STS_ERROR;
1164: END;
1165:
1166: IF x_return_status = FND_API.G_RET_STS_SUCCESS THEN
1167:

Line 1166: IF x_return_status = FND_API.G_RET_STS_SUCCESS THEN

1162: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_OP_NOTFOUND');
1163: x_return_status := FND_API.G_RET_STS_ERROR;
1164: END;
1165:
1166: IF x_return_status = FND_API.G_RET_STS_SUCCESS THEN
1167:
1168: prvOpCurVar.prior_operation := p_new_op_seq_num;
1169: prvOpCurVar.Last_Updated_By := FND_GLOBAL.user_id;
1170: prvOpCurVar.Last_Update_Login := FND_GLOBAL.user_id;

Line 1236: RAISE FND_API.G_EXC_ERROR;

1232: END LOOP; -- end loop for prvOpCurVar
1233:
1234:
1235: EXCEPTION WHEN NO_DATA_FOUND THEN
1236: RAISE FND_API.G_EXC_ERROR;
1237: END copy_operation_network;
1238:
1239:
1240: ---------------------------------------------------------------------------------------

Line 1245: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE

1241: -- handover the selected resources of one operation
1242: ---------------------------------------------------------------------------------------
1243: procedure operation_handover_resource
1244: ( p_api_version IN NUMBER := 1.0
1245: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
1246: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
1247: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
1248: ,p_record_version_number IN NUMBER := NULL
1249: ,x_return_status OUT NOCOPY VARCHAR2

Line 1246: ,p_commit IN VARCHAR2 := FND_API.G_FALSE

1242: ---------------------------------------------------------------------------------------
1243: procedure operation_handover_resource
1244: ( p_api_version IN NUMBER := 1.0
1245: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
1246: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
1247: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
1248: ,p_record_version_number IN NUMBER := NULL
1249: ,x_return_status OUT NOCOPY VARCHAR2
1250: ,x_msg_count OUT NOCOPY NUMBER

Line 1247: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE

1243: procedure operation_handover_resource
1244: ( p_api_version IN NUMBER := 1.0
1245: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
1246: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
1247: ,p_validate_only IN VARCHAR2 := FND_API.G_TRUE
1248: ,p_record_version_number IN NUMBER := NULL
1249: ,x_return_status OUT NOCOPY VARCHAR2
1250: ,x_msg_count OUT NOCOPY NUMBER
1251: ,x_msg_data OUT NOCOPY VARCHAR2

Line 1262: ,p_complete_rollback IN VARCHAR2 := FND_API.G_FALSE -- Added parameter to handle rollback for Mobile Handover Page.

1258: ,p_duration IN NUMBER
1259: ,p_new_op_start_date IN DATE
1260: ,p_new_op_end_date IN DATE
1261: ,p_employee_id IN NUMBER -- instance id
1262: ,p_complete_rollback IN VARCHAR2 := FND_API.G_FALSE -- Added parameter to handle rollback for Mobile Handover Page.
1263: ) IS
1264:
1265: curRow wip_operation_resources%ROWTYPE;
1266: newRow wip_operation_resources%ROWTYPE;

Line 1337: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,

1333: SAVEPOINT operation_handover_resource;
1334:
1335: eam_debug.init_err_stack('eam_operations_jsp.operation_handover_resource');
1336:
1337: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,
1338: p_api_version,
1339: l_api_name,
1340: g_pkg_name)
1341: THEN

Line 1342: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

1338: p_api_version,
1339: l_api_name,
1340: g_pkg_name)
1341: THEN
1342: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1343: END IF;
1344:
1345: IF FND_API.TO_BOOLEAN(p_init_msg_list)
1346: THEN

Line 1345: IF FND_API.TO_BOOLEAN(p_init_msg_list)

1341: THEN
1342: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1343: END IF;
1344:
1345: IF FND_API.TO_BOOLEAN(p_init_msg_list)
1346: THEN
1347: FND_MSG_PUB.initialize;
1348: END IF;
1349:

Line 1352: x_return_status := FND_API.G_RET_STS_SUCCESS;

1348: END IF;
1349:
1350: EAM_WORKORDER_UTIL_PKG.log_path(l_output_dir);
1351:
1352: x_return_status := FND_API.G_RET_STS_SUCCESS;
1353:
1354: -----------------------------------------------------------------
1355: -- validation
1356: if(p_duration <0) then

Line 1358: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1354: -----------------------------------------------------------------
1355: -- validation
1356: if(p_duration <0) then
1357: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_DURATION');
1358: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1359: else
1360: l_duration := trunc(p_duration * 60 * 60, 0) / ( 24 * 60 * 60);
1361: end if;
1362:

Line 1373: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1369: where wip_entity_id = p_wip_entity_id
1370: and operation_seq_num = p_new_op_seq_num;
1371: Exception when others then
1372: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_OP_NOTFOUND');
1373: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1374: END;
1375: /* Fix for Bug 2108778 */
1376:
1377: begin

Line 1395: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1391: where department_code=p_department);
1392: if(l_dept=null) then
1393: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_DEPT_INVALID'
1394: ,p_token1 => 'RESOURCE_SEQ_NUM', p_value1 => p_resource_seq_num ,p_token2 => 'DEPARTMENT',p_value2 =>p_department);
1395: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1396: END IF;
1397: end;
1398:
1399: -- get the resource

Line 1422: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1418:
1419: Exception when others then
1420: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_RSRC_NOTFOUND'
1421: ,p_token1 => 'RESOURCE_SEQ_NUM', p_value1 => p_resource_seq_num);
1422: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1423:
1424:
1425: END;
1426:

Line 1442: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1438: Exception when others then
1439: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_DEPT_INV'
1440: ,p_token1 => 'RESOURCE_SEQ_NUM', p_value1 => p_resource_seq_num
1441: ,p_token2 => 'ERR', p_value2 => SQLERRM );
1442: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1443: END;
1444:
1445:
1446: -- verify that resource can be handover to that department

Line 1447: if (x_return_status = FND_API.G_RET_STS_SUCCESS ) then

1443: END;
1444:
1445:
1446: -- verify that resource can be handover to that department
1447: if (x_return_status = FND_API.G_RET_STS_SUCCESS ) then
1448: select count(*)
1449: into l_num_non_compatible_resources
1450: from wip_operation_resources wor
1451: where wor.wip_entity_id = p_wip_entity_id

Line 1462: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1458: );
1459: if( l_num_non_compatible_resources >0) then
1460: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_DEPT_NOTOK'
1461: ,p_token1 => 'RESOURCE_SEQ_NUM', p_value1 => p_resource_seq_num);
1462: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1463: end if;
1464: end if;
1465: end if;
1466:

Line 1475: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1471: where wdj.wip_entity_id = p_wip_entity_id;
1472:
1473: if(l_start_quantity <> 1 ) then
1474: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_HANDOVER_S_QUANTITY_INV');
1475: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1476: end if;
1477:
1478:
1479: if( x_return_status = FND_API.G_RET_STS_SUCCESS) then

Line 1479: if( x_return_status = FND_API.G_RET_STS_SUCCESS) then

1475: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1476: end if;
1477:
1478:
1479: if( x_return_status = FND_API.G_RET_STS_SUCCESS) then
1480: BEGIN
1481:
1482: SELECT 1 INTO l_res_valid
1483: FROM wip_operation_resources

Line 1599: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1595: and papf.effective_end_date);
1596:
1597: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_RI_ALREADY_EXISTS'
1598: ,p_token1 => 'INSTANCE_NAME', p_value1 => l_employee_name);
1599: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1600: END IF; -- end of l_inst_valid check
1601:
1602: EAM_PROCESS_WO_PUB.Process_WO
1603: ( p_bo_identifier => 'EAM'

Line 1665: (p_encoded => FND_API.G_FALSE,

1661: -- check error
1662: l_msg_count := FND_MSG_PUB.count_msg;
1663: IF l_msg_count = 1 THEN
1664: eam_execution_jsp.Get_Messages
1665: (p_encoded => FND_API.G_FALSE,
1666: p_msg_index => 1,
1667: p_msg_count => l_msg_count,
1668: p_msg_data => l_msg_data, -- removed g_miss_char
1669: p_data => l_data,

Line 1678: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1674: x_msg_count := l_msg_count;
1675: END IF;
1676:
1677: IF l_msg_count > 0 THEN
1678: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1679: RAISE FND_API.G_EXC_ERROR;
1680: END IF;
1681:
1682: IF FND_API.TO_BOOLEAN(P_COMMIT)

Line 1679: RAISE FND_API.G_EXC_ERROR;

1675: END IF;
1676:
1677: IF l_msg_count > 0 THEN
1678: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1679: RAISE FND_API.G_EXC_ERROR;
1680: END IF;
1681:
1682: IF FND_API.TO_BOOLEAN(P_COMMIT)
1683: THEN

Line 1682: IF FND_API.TO_BOOLEAN(P_COMMIT)

1678: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1679: RAISE FND_API.G_EXC_ERROR;
1680: END IF;
1681:
1682: IF FND_API.TO_BOOLEAN(P_COMMIT)
1683: THEN
1684: COMMIT WORK;
1685: END IF;
1686:

Line 1687: EXCEPTION WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

1683: THEN
1684: COMMIT WORK;
1685: END IF;
1686:
1687: EXCEPTION WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
1688: IF FND_API.TO_BOOLEAN(p_complete_rollback)
1689: THEN
1690: ROLLBACK; -- Complete rollback for Mobile Handover Page
1691: ELSE

Line 1688: IF FND_API.TO_BOOLEAN(p_complete_rollback)

1684: COMMIT WORK;
1685: END IF;
1686:
1687: EXCEPTION WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
1688: IF FND_API.TO_BOOLEAN(p_complete_rollback)
1689: THEN
1690: ROLLBACK; -- Complete rollback for Mobile Handover Page
1691: ELSE
1692: ROLLBACK TO operation_handover_resource; -- Method rollback for Desktop HandoverPage.

Line 1696: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1692: ROLLBACK TO operation_handover_resource; -- Method rollback for Desktop HandoverPage.
1693: END IF;
1694: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover_resource',
1695: p_procedure_name => EAM_DEBUG.G_err_stack);
1696: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1697:
1698: WHEN FND_API.G_EXC_ERROR THEN
1699: IF FND_API.TO_BOOLEAN(p_complete_rollback)
1700: THEN

Line 1698: WHEN FND_API.G_EXC_ERROR THEN

1694: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover_resource',
1695: p_procedure_name => EAM_DEBUG.G_err_stack);
1696: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1697:
1698: WHEN FND_API.G_EXC_ERROR THEN
1699: IF FND_API.TO_BOOLEAN(p_complete_rollback)
1700: THEN
1701: ROLLBACK; -- Complete rollback for Mobile Handover Page
1702: ELSE

Line 1699: IF FND_API.TO_BOOLEAN(p_complete_rollback)

1695: p_procedure_name => EAM_DEBUG.G_err_stack);
1696: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1697:
1698: WHEN FND_API.G_EXC_ERROR THEN
1699: IF FND_API.TO_BOOLEAN(p_complete_rollback)
1700: THEN
1701: ROLLBACK; -- Complete rollback for Mobile Handover Page
1702: ELSE
1703: ROLLBACK TO operation_handover_resource; -- Method rollback for Desktop HandoverPage.

Line 1707: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1703: ROLLBACK TO operation_handover_resource; -- Method rollback for Desktop HandoverPage.
1704: END IF;
1705: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover_resource',
1706: p_procedure_name => EAM_DEBUG.G_err_stack);
1707: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1708:
1709: WHEN OTHERS THEN
1710: IF FND_API.TO_BOOLEAN(p_complete_rollback)
1711: THEN

Line 1710: IF FND_API.TO_BOOLEAN(p_complete_rollback)

1706: p_procedure_name => EAM_DEBUG.G_err_stack);
1707: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1708:
1709: WHEN OTHERS THEN
1710: IF FND_API.TO_BOOLEAN(p_complete_rollback)
1711: THEN
1712: ROLLBACK; -- Complete rollback for Mobile Handover Page
1713: ELSE
1714: ROLLBACK TO operation_handover_resource; -- Method rollback for Desktop HandoverPage.

Line 1718: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1714: ROLLBACK TO operation_handover_resource; -- Method rollback for Desktop HandoverPage.
1715: END IF;
1716: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'eam_operations_jsp.operation_handover_resource',
1717: p_procedure_name => EAM_DEBUG.G_err_stack);
1718: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1719:
1720: END operation_handover_resource;
1721:
1722:

Line 1855: raise FND_API.G_EXC_ERROR;

1851: x_res_status := l_invalid_resource;
1852:
1853: -- Bug 3133704 changed when_others
1854: EXCEPTION WHEN NO_DATA_FOUND THEN
1855: raise FND_API.G_EXC_ERROR;
1856:
1857: END validate_insert;
1858:
1859:

Line 1863: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1859:
1860: -- Insert into WIP_OPERATION_RESOURCES from Add Resources JSP
1861:
1862: procedure insert_into_wor( p_api_version IN NUMBER
1863: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1864: ,p_commit IN VARCHAR2 := fnd_api.g_false
1865: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1866: ,p_wip_entity_id IN NUMBER
1867: ,p_operation_seq_num IN NUMBER

Line 1864: ,p_commit IN VARCHAR2 := fnd_api.g_false

1860: -- Insert into WIP_OPERATION_RESOURCES from Add Resources JSP
1861:
1862: procedure insert_into_wor( p_api_version IN NUMBER
1863: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1864: ,p_commit IN VARCHAR2 := fnd_api.g_false
1865: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1866: ,p_wip_entity_id IN NUMBER
1867: ,p_operation_seq_num IN NUMBER
1868: ,p_organization_id IN NUMBER

Line 1865: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full

1861:
1862: procedure insert_into_wor( p_api_version IN NUMBER
1863: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1864: ,p_commit IN VARCHAR2 := fnd_api.g_false
1865: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1866: ,p_wip_entity_id IN NUMBER
1867: ,p_operation_seq_num IN NUMBER
1868: ,p_organization_id IN NUMBER
1869: ,p_usage_rate IN NUMBER

Line 1965: IF NOT fnd_api.compatible_api_call(

1961: SAVEPOINT get_insert_into_wor_pvt;
1962:
1963: l_stmt_num := 20;
1964: -- Standard call to check for call compatibility.
1965: IF NOT fnd_api.compatible_api_call(
1966: l_api_version
1967: ,p_api_version
1968: ,l_api_name
1969: ,g_pkg_name) THEN

Line 1970: RAISE fnd_api.g_exc_unexpected_error;

1966: l_api_version
1967: ,p_api_version
1968: ,l_api_name
1969: ,g_pkg_name) THEN
1970: RAISE fnd_api.g_exc_unexpected_error;
1971: END IF;
1972:
1973: l_stmt_num := 30;
1974: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 1975: IF fnd_api.to_boolean(p_init_msg_list) THEN

1971: END IF;
1972:
1973: l_stmt_num := 30;
1974: -- Initialize message list if p_init_msg_list is set to TRUE.
1975: IF fnd_api.to_boolean(p_init_msg_list) THEN
1976: fnd_msg_pub.initialize;
1977: END IF;
1978:
1979: l_stmt_num := 40;

Line 1981: x_return_status := fnd_api.g_ret_sts_success;

1977: END IF;
1978:
1979: l_stmt_num := 40;
1980: -- Initialize API return status to success
1981: x_return_status := fnd_api.g_ret_sts_success;
1982:
1983: l_stmt_num := 50;
1984: -- API body
1985:

Line 2210: IF fnd_api.to_boolean(p_commit)

2206:
2207:
2208: -- End of API body.
2209: -- Standard check of p_commit.
2210: IF fnd_api.to_boolean(p_commit)
2211: and x_return_status = 'S' THEN
2212: COMMIT WORK;
2213: END IF;
2214:

Line 2226: WHEN fnd_api.g_exc_error THEN

2222: fnd_msg_pub.count_and_get(
2223: p_count => x_msg_count
2224: ,p_data => x_msg_data);
2225: EXCEPTION
2226: WHEN fnd_api.g_exc_error THEN
2227: ROLLBACK TO get_insert_into_wor_pvt;
2228: x_return_status := fnd_api.g_ret_sts_error;
2229: fnd_msg_pub.count_and_get(
2230: -- p_encoded => FND_API.g_false

Line 2228: x_return_status := fnd_api.g_ret_sts_error;

2224: ,p_data => x_msg_data);
2225: EXCEPTION
2226: WHEN fnd_api.g_exc_error THEN
2227: ROLLBACK TO get_insert_into_wor_pvt;
2228: x_return_status := fnd_api.g_ret_sts_error;
2229: fnd_msg_pub.count_and_get(
2230: -- p_encoded => FND_API.g_false
2231: p_count => x_msg_count
2232: ,p_data => x_msg_data);

Line 2230: -- p_encoded => FND_API.g_false

2226: WHEN fnd_api.g_exc_error THEN
2227: ROLLBACK TO get_insert_into_wor_pvt;
2228: x_return_status := fnd_api.g_ret_sts_error;
2229: fnd_msg_pub.count_and_get(
2230: -- p_encoded => FND_API.g_false
2231: p_count => x_msg_count
2232: ,p_data => x_msg_data);
2233:
2234: WHEN fnd_api.g_exc_unexpected_error THEN

Line 2234: WHEN fnd_api.g_exc_unexpected_error THEN

2230: -- p_encoded => FND_API.g_false
2231: p_count => x_msg_count
2232: ,p_data => x_msg_data);
2233:
2234: WHEN fnd_api.g_exc_unexpected_error THEN
2235: ROLLBACK TO get_insert_into_wor_pvt;
2236: x_return_status := fnd_api.g_ret_sts_unexp_error;
2237:
2238: fnd_msg_pub.count_and_get(

Line 2236: x_return_status := fnd_api.g_ret_sts_unexp_error;

2232: ,p_data => x_msg_data);
2233:
2234: WHEN fnd_api.g_exc_unexpected_error THEN
2235: ROLLBACK TO get_insert_into_wor_pvt;
2236: x_return_status := fnd_api.g_ret_sts_unexp_error;
2237:
2238: fnd_msg_pub.count_and_get(
2239: p_count => x_msg_count
2240: ,p_data => x_msg_data);

Line 2244: x_return_status := fnd_api.g_ret_sts_unexp_error;

2240: ,p_data => x_msg_data);
2241:
2242: WHEN OTHERS THEN
2243: ROLLBACK TO get_insert_into_wor_pvt;
2244: x_return_status := fnd_api.g_ret_sts_unexp_error;
2245: IF fnd_msg_pub.check_msg_level(
2246: fnd_msg_pub.g_msg_lvl_unexp_error) THEN
2247: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2248: END IF;

Line 2474: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2470:
2471:
2472: PROCEDURE insert_into_wro(
2473: p_api_version IN NUMBER
2474: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2475: ,p_commit IN VARCHAR2 := fnd_api.g_false
2476: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2477: ,p_wip_entity_id IN NUMBER
2478: ,p_organization_id IN NUMBER

Line 2475: ,p_commit IN VARCHAR2 := fnd_api.g_false

2471:
2472: PROCEDURE insert_into_wro(
2473: p_api_version IN NUMBER
2474: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2475: ,p_commit IN VARCHAR2 := fnd_api.g_false
2476: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2477: ,p_wip_entity_id IN NUMBER
2478: ,p_organization_id IN NUMBER
2479: ,p_concatenated_segments IN VARCHAR2

Line 2476: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full

2472: PROCEDURE insert_into_wro(
2473: p_api_version IN NUMBER
2474: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2475: ,p_commit IN VARCHAR2 := fnd_api.g_false
2476: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2477: ,p_wip_entity_id IN NUMBER
2478: ,p_organization_id IN NUMBER
2479: ,p_concatenated_segments IN VARCHAR2
2480: ,p_description IN VARCHAR2

Line 2498: ,p_one_step_issue IN varchar2:=fnd_api.g_false

2494: ,x_msg_count OUT NOCOPY NUMBER
2495: ,x_msg_data OUT NOCOPY VARCHAR2
2496: ,x_update_status OUT NOCOPY NUMBER
2497: ,p_supply_code IN NUMBER :=NULL
2498: ,p_one_step_issue IN varchar2:=fnd_api.g_false
2499: ,p_released_quantity IN NUMBER := NULL)
2500:
2501: IS
2502: l_api_name CONSTANT VARCHAR2(30) := 'insert_into_wro';

Line 2581: IF NOT fnd_api.compatible_api_call(

2577: SAVEPOINT get_insert_into_wro_pvt;
2578:
2579: l_stmt_num := 20;
2580: -- Standard call to check for call compatibility.
2581: IF NOT fnd_api.compatible_api_call(
2582: l_api_version
2583: ,p_api_version
2584: ,l_api_name
2585: ,g_pkg_name) THEN

Line 2586: RAISE fnd_api.g_exc_unexpected_error;

2582: l_api_version
2583: ,p_api_version
2584: ,l_api_name
2585: ,g_pkg_name) THEN
2586: RAISE fnd_api.g_exc_unexpected_error;
2587: END IF;
2588:
2589: l_stmt_num := 30;
2590: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 2591: IF fnd_api.to_boolean(p_init_msg_list) THEN

2587: END IF;
2588:
2589: l_stmt_num := 30;
2590: -- Initialize message list if p_init_msg_list is set to TRUE.
2591: IF fnd_api.to_boolean(p_init_msg_list) THEN
2592: fnd_msg_pub.initialize;
2593: END IF;
2594:
2595: l_stmt_num := 40;

Line 2597: x_return_status := fnd_api.g_ret_sts_success;

2593: END IF;
2594:
2595: l_stmt_num := 40;
2596: -- Initialize API return status to success
2597: x_return_status := fnd_api.g_ret_sts_success;
2598:
2599: l_stmt_num := 50;
2600: -- API body
2601:

Line 2682: if(p_one_step_issue = fnd_api.g_true) then

2678: /* To avoid the material allocation from the WO API
2679: ** for OneStep Issue page since allocation api will
2680: ** be called seperatly.
2681: */
2682: if(p_one_step_issue = fnd_api.g_true) then
2683: l_wo_changed := TRUE;
2684: select material_issue_by_mo into l_material_issue_by_mo_temp
2685: from wip_discrete_jobs
2686: where

Line 2874: IF fnd_api.to_boolean(p_commit)

2870:
2871:
2872: -- End of API body.
2873: -- Standard check of p_commit.
2874: IF fnd_api.to_boolean(p_commit)
2875: and x_return_status = 'S' THEN
2876: COMMIT WORK;
2877: END IF;
2878:

Line 2889: WHEN fnd_api.g_exc_error THEN

2885: fnd_msg_pub.count_and_get(
2886: p_count => x_msg_count
2887: ,p_data => x_msg_data);
2888: EXCEPTION
2889: WHEN fnd_api.g_exc_error THEN
2890: ROLLBACK TO get_insert_into_wro_pvt;
2891: x_return_status := fnd_api.g_ret_sts_error;
2892: fnd_msg_pub.count_and_get(
2893: -- p_encoded => FND_API.g_false

Line 2891: x_return_status := fnd_api.g_ret_sts_error;

2887: ,p_data => x_msg_data);
2888: EXCEPTION
2889: WHEN fnd_api.g_exc_error THEN
2890: ROLLBACK TO get_insert_into_wro_pvt;
2891: x_return_status := fnd_api.g_ret_sts_error;
2892: fnd_msg_pub.count_and_get(
2893: -- p_encoded => FND_API.g_false
2894: p_count => x_msg_count
2895: ,p_data => x_msg_data);

Line 2893: -- p_encoded => FND_API.g_false

2889: WHEN fnd_api.g_exc_error THEN
2890: ROLLBACK TO get_insert_into_wro_pvt;
2891: x_return_status := fnd_api.g_ret_sts_error;
2892: fnd_msg_pub.count_and_get(
2893: -- p_encoded => FND_API.g_false
2894: p_count => x_msg_count
2895: ,p_data => x_msg_data);
2896: WHEN fnd_api.g_exc_unexpected_error THEN
2897: ROLLBACK TO get_insert_into_wro_pvt;

Line 2896: WHEN fnd_api.g_exc_unexpected_error THEN

2892: fnd_msg_pub.count_and_get(
2893: -- p_encoded => FND_API.g_false
2894: p_count => x_msg_count
2895: ,p_data => x_msg_data);
2896: WHEN fnd_api.g_exc_unexpected_error THEN
2897: ROLLBACK TO get_insert_into_wro_pvt;
2898: x_return_status := fnd_api.g_ret_sts_unexp_error;
2899:
2900: fnd_msg_pub.count_and_get(

Line 2898: x_return_status := fnd_api.g_ret_sts_unexp_error;

2894: p_count => x_msg_count
2895: ,p_data => x_msg_data);
2896: WHEN fnd_api.g_exc_unexpected_error THEN
2897: ROLLBACK TO get_insert_into_wro_pvt;
2898: x_return_status := fnd_api.g_ret_sts_unexp_error;
2899:
2900: fnd_msg_pub.count_and_get(
2901: p_count => x_msg_count
2902: ,p_data => x_msg_data);

Line 2905: x_return_status := fnd_api.g_ret_sts_unexp_error;

2901: p_count => x_msg_count
2902: ,p_data => x_msg_data);
2903: WHEN OTHERS THEN
2904: ROLLBACK TO get_insert_into_wro_pvt;
2905: x_return_status := fnd_api.g_ret_sts_unexp_error;
2906: IF fnd_msg_pub.check_msg_level(
2907: fnd_msg_pub.g_msg_lvl_unexp_error) THEN
2908: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2909: END IF;

Line 2922: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2918: --Start of bug 12631479
2919: --This procedure is not called in R12.This was added to maintain dual check in between R12->R12.1
2920: PROCEDURE insert_into_wro(
2921: p_api_version IN NUMBER
2922: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2923: ,p_commit IN VARCHAR2 := fnd_api.g_false
2924: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2925: ,p_wip_entity_id IN NUMBER
2926: ,p_organization_id IN NUMBER

Line 2923: ,p_commit IN VARCHAR2 := fnd_api.g_false

2919: --This procedure is not called in R12.This was added to maintain dual check in between R12->R12.1
2920: PROCEDURE insert_into_wro(
2921: p_api_version IN NUMBER
2922: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2923: ,p_commit IN VARCHAR2 := fnd_api.g_false
2924: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2925: ,p_wip_entity_id IN NUMBER
2926: ,p_organization_id IN NUMBER
2927: ,p_concatenated_segments IN VARCHAR2

Line 2924: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full

2920: PROCEDURE insert_into_wro(
2921: p_api_version IN NUMBER
2922: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2923: ,p_commit IN VARCHAR2 := fnd_api.g_false
2924: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2925: ,p_wip_entity_id IN NUMBER
2926: ,p_organization_id IN NUMBER
2927: ,p_concatenated_segments IN VARCHAR2
2928: ,p_description IN VARCHAR2

Line 2946: ,p_one_step_issue IN varchar2:=fnd_api.g_false

2942: ,x_msg_count OUT NOCOPY NUMBER
2943: ,x_msg_data OUT NOCOPY VARCHAR2
2944: ,x_update_status OUT NOCOPY NUMBER
2945: ,p_supply_code IN NUMBER :=NULL
2946: ,p_one_step_issue IN varchar2:=fnd_api.g_false
2947: ,p_released_quantity IN NUMBER := NULL
2948: ,p_attribute_category IN VARCHAR2
2949: ,p_attribute1 IN VARCHAR2
2950: ,p_attribute2 IN VARCHAR2

Line 3049: IF NOT fnd_api.compatible_api_call(

3045: SAVEPOINT get_insert_into_wro_pvt;
3046:
3047: l_stmt_num := 20;
3048: -- Standard call to check for call compatibility.
3049: IF NOT fnd_api.compatible_api_call(
3050: l_api_version
3051: ,p_api_version
3052: ,l_api_name
3053: ,g_pkg_name) THEN

Line 3054: RAISE fnd_api.g_exc_unexpected_error;

3050: l_api_version
3051: ,p_api_version
3052: ,l_api_name
3053: ,g_pkg_name) THEN
3054: RAISE fnd_api.g_exc_unexpected_error;
3055: END IF;
3056:
3057: l_stmt_num := 30;
3058: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 3059: IF fnd_api.to_boolean(p_init_msg_list) THEN

3055: END IF;
3056:
3057: l_stmt_num := 30;
3058: -- Initialize message list if p_init_msg_list is set to TRUE.
3059: IF fnd_api.to_boolean(p_init_msg_list) THEN
3060: fnd_msg_pub.initialize;
3061: END IF;
3062:
3063: l_stmt_num := 40;

Line 3065: x_return_status := fnd_api.g_ret_sts_success;

3061: END IF;
3062:
3063: l_stmt_num := 40;
3064: -- Initialize API return status to success
3065: x_return_status := fnd_api.g_ret_sts_success;
3066:
3067: l_stmt_num := 50;
3068: -- API body
3069:

Line 3157: if(p_one_step_issue = fnd_api.g_true) then

3153: /* To avoid the material allocation from the WO API
3154: ** for OneStep Issue page since allocation api will
3155: ** be called seperatly.
3156: */
3157: if(p_one_step_issue = fnd_api.g_true) then
3158: l_wo_changed := TRUE;
3159: select material_issue_by_mo into l_material_issue_by_mo_temp
3160: from wip_discrete_jobs
3161: where

Line 3383: IF fnd_api.to_boolean(p_commit)

3379:
3380:
3381: -- End of API body.
3382: -- Standard check of p_commit.
3383: IF fnd_api.to_boolean(p_commit)
3384: and x_return_status = 'S' THEN
3385: COMMIT WORK;
3386: END IF;
3387:

Line 3398: WHEN fnd_api.g_exc_error THEN

3394: fnd_msg_pub.count_and_get(
3395: p_count => x_msg_count
3396: ,p_data => x_msg_data);
3397: EXCEPTION
3398: WHEN fnd_api.g_exc_error THEN
3399: ROLLBACK TO get_insert_into_wro_pvt;
3400: x_return_status := fnd_api.g_ret_sts_error;
3401: fnd_msg_pub.count_and_get(
3402: -- p_encoded => FND_API.g_false

Line 3400: x_return_status := fnd_api.g_ret_sts_error;

3396: ,p_data => x_msg_data);
3397: EXCEPTION
3398: WHEN fnd_api.g_exc_error THEN
3399: ROLLBACK TO get_insert_into_wro_pvt;
3400: x_return_status := fnd_api.g_ret_sts_error;
3401: fnd_msg_pub.count_and_get(
3402: -- p_encoded => FND_API.g_false
3403: p_count => x_msg_count
3404: ,p_data => x_msg_data);

Line 3402: -- p_encoded => FND_API.g_false

3398: WHEN fnd_api.g_exc_error THEN
3399: ROLLBACK TO get_insert_into_wro_pvt;
3400: x_return_status := fnd_api.g_ret_sts_error;
3401: fnd_msg_pub.count_and_get(
3402: -- p_encoded => FND_API.g_false
3403: p_count => x_msg_count
3404: ,p_data => x_msg_data);
3405: WHEN fnd_api.g_exc_unexpected_error THEN
3406: ROLLBACK TO get_insert_into_wro_pvt;

Line 3405: WHEN fnd_api.g_exc_unexpected_error THEN

3401: fnd_msg_pub.count_and_get(
3402: -- p_encoded => FND_API.g_false
3403: p_count => x_msg_count
3404: ,p_data => x_msg_data);
3405: WHEN fnd_api.g_exc_unexpected_error THEN
3406: ROLLBACK TO get_insert_into_wro_pvt;
3407: x_return_status := fnd_api.g_ret_sts_unexp_error;
3408:
3409: fnd_msg_pub.count_and_get(

Line 3407: x_return_status := fnd_api.g_ret_sts_unexp_error;

3403: p_count => x_msg_count
3404: ,p_data => x_msg_data);
3405: WHEN fnd_api.g_exc_unexpected_error THEN
3406: ROLLBACK TO get_insert_into_wro_pvt;
3407: x_return_status := fnd_api.g_ret_sts_unexp_error;
3408:
3409: fnd_msg_pub.count_and_get(
3410: p_count => x_msg_count
3411: ,p_data => x_msg_data);

Line 3414: x_return_status := fnd_api.g_ret_sts_unexp_error;

3410: p_count => x_msg_count
3411: ,p_data => x_msg_data);
3412: WHEN OTHERS THEN
3413: ROLLBACK TO get_insert_into_wro_pvt;
3414: x_return_status := fnd_api.g_ret_sts_unexp_error;
3415: IF fnd_msg_pub.check_msg_level(
3416: fnd_msg_pub.g_msg_lvl_unexp_error) THEN
3417: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
3418: END IF;

Line 3431: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

3427:
3428:
3429: PROCEDURE delete_resources (
3430: p_api_version IN NUMBER
3431: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3432: ,p_commit IN VARCHAR2 := fnd_api.g_false
3433: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
3434: ,p_wip_entity_id IN NUMBER
3435: ,p_operation_seq_num IN NUMBER

Line 3432: ,p_commit IN VARCHAR2 := fnd_api.g_false

3428:
3429: PROCEDURE delete_resources (
3430: p_api_version IN NUMBER
3431: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3432: ,p_commit IN VARCHAR2 := fnd_api.g_false
3433: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
3434: ,p_wip_entity_id IN NUMBER
3435: ,p_operation_seq_num IN NUMBER
3436: ,p_resource_seq_num IN NUMBER

Line 3433: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full

3429: PROCEDURE delete_resources (
3430: p_api_version IN NUMBER
3431: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3432: ,p_commit IN VARCHAR2 := fnd_api.g_false
3433: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
3434: ,p_wip_entity_id IN NUMBER
3435: ,p_operation_seq_num IN NUMBER
3436: ,p_resource_seq_num IN NUMBER
3437: ,x_return_status OUT NOCOPY VARCHAR2

Line 3510: IF NOT fnd_api.compatible_api_call(

3506: SAVEPOINT get_delete_resources_pvt;
3507:
3508: l_stmt_num := 20;
3509: -- Standard call to check for call compatibility.
3510: IF NOT fnd_api.compatible_api_call(
3511: l_api_version
3512: ,p_api_version
3513: ,l_api_name
3514: ,g_pkg_name) THEN

Line 3515: RAISE fnd_api.g_exc_unexpected_error;

3511: l_api_version
3512: ,p_api_version
3513: ,l_api_name
3514: ,g_pkg_name) THEN
3515: RAISE fnd_api.g_exc_unexpected_error;
3516: END IF;
3517:
3518: l_stmt_num := 30;
3519:

Line 3521: IF fnd_api.to_boolean(p_init_msg_list) THEN

3517:
3518: l_stmt_num := 30;
3519:
3520: -- Initialize message list if p_init_msg_list is set to TRUE.
3521: IF fnd_api.to_boolean(p_init_msg_list) THEN
3522: fnd_msg_pub.initialize;
3523: END IF;
3524:
3525: l_stmt_num := 40;

Line 3527: x_return_status := fnd_api.g_ret_sts_success;

3523: END IF;
3524:
3525: l_stmt_num := 40;
3526: -- Initialize API return status to success
3527: x_return_status := fnd_api.g_ret_sts_success;
3528:
3529: l_stmt_num := 50;
3530: -- API body
3531:

Line 3571: x_return_status := FND_API.G_RET_STS_ERROR;

3567: if(l_exists <> 0) then
3568:
3569: l_validate_st := 1;
3570: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => 'EAM_INSTANCES_EXIST');
3571: x_return_status := FND_API.G_RET_STS_ERROR;
3572: end if;
3573:
3574: end if; -- End of l_resource_id is not null ........
3575:

Line 3581: (p_encoded => FND_API.G_FALSE,

3577: l_msg_count := FND_MSG_PUB.count_msg;
3578: IF l_msg_count = 1 THEN
3579:
3580: eam_execution_jsp.Get_Messages
3581: (p_encoded => FND_API.G_FALSE,
3582: p_msg_index => 1,
3583: p_msg_count => l_msg_count,
3584: p_msg_data => l_msg_data,
3585: p_data => l_data,

Line 3594: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3590: x_msg_count := l_msg_count;
3591: END IF;
3592:
3593: IF l_msg_count > 0 THEN
3594: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3595: RAISE FND_API.G_EXC_ERROR;
3596: END IF;
3597:
3598:

Line 3595: RAISE FND_API.G_EXC_ERROR;

3591: END IF;
3592:
3593: IF l_msg_count > 0 THEN
3594: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3595: RAISE FND_API.G_EXC_ERROR;
3596: END IF;
3597:
3598:
3599:

Line 3665: IF fnd_api.to_boolean(p_commit)

3661:
3662:
3663: -- End of API body.
3664: -- Standard check of p_commit.
3665: IF fnd_api.to_boolean(p_commit)
3666: and x_return_status = 'S' THEN
3667: COMMIT WORK;
3668: END IF;
3669:

Line 3682: WHEN fnd_api.g_exc_error THEN

3678: p_count => x_msg_count
3679: ,p_data => x_msg_data);
3680:
3681: EXCEPTION
3682: WHEN fnd_api.g_exc_error THEN
3683: ROLLBACK TO get_delete_resources_pvt;
3684: x_return_status := fnd_api.g_ret_sts_error;
3685: fnd_msg_pub.count_and_get(
3686: -- p_encoded => FND_API.g_false

Line 3684: x_return_status := fnd_api.g_ret_sts_error;

3680:
3681: EXCEPTION
3682: WHEN fnd_api.g_exc_error THEN
3683: ROLLBACK TO get_delete_resources_pvt;
3684: x_return_status := fnd_api.g_ret_sts_error;
3685: fnd_msg_pub.count_and_get(
3686: -- p_encoded => FND_API.g_false
3687: p_count => x_msg_count
3688: ,p_data => x_msg_data);

Line 3686: -- p_encoded => FND_API.g_false

3682: WHEN fnd_api.g_exc_error THEN
3683: ROLLBACK TO get_delete_resources_pvt;
3684: x_return_status := fnd_api.g_ret_sts_error;
3685: fnd_msg_pub.count_and_get(
3686: -- p_encoded => FND_API.g_false
3687: p_count => x_msg_count
3688: ,p_data => x_msg_data);
3689:
3690: WHEN fnd_api.g_exc_unexpected_error THEN

Line 3690: WHEN fnd_api.g_exc_unexpected_error THEN

3686: -- p_encoded => FND_API.g_false
3687: p_count => x_msg_count
3688: ,p_data => x_msg_data);
3689:
3690: WHEN fnd_api.g_exc_unexpected_error THEN
3691: ROLLBACK TO get_delete_resources_pvt;
3692: x_return_status := fnd_api.g_ret_sts_unexp_error;
3693:
3694: fnd_msg_pub.count_and_get(

Line 3692: x_return_status := fnd_api.g_ret_sts_unexp_error;

3688: ,p_data => x_msg_data);
3689:
3690: WHEN fnd_api.g_exc_unexpected_error THEN
3691: ROLLBACK TO get_delete_resources_pvt;
3692: x_return_status := fnd_api.g_ret_sts_unexp_error;
3693:
3694: fnd_msg_pub.count_and_get(
3695: p_count => x_msg_count
3696: ,p_data => x_msg_data);

Line 3700: x_return_status := fnd_api.g_ret_sts_unexp_error;

3696: ,p_data => x_msg_data);
3697:
3698: WHEN OTHERS THEN
3699: ROLLBACK TO get_delete_resources_pvt;
3700: x_return_status := fnd_api.g_ret_sts_unexp_error;
3701: IF fnd_msg_pub.check_msg_level(
3702: fnd_msg_pub.g_msg_lvl_unexp_error) THEN
3703: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
3704: END IF;

Line 4223: x_error_flag := FND_API.G_RET_STS_SUCCESS;

4219: l_restrict_date_change NUMBER := 0;
4220: Begin
4221:
4222: l_op_already_available := 0;
4223: x_error_flag := FND_API.G_RET_STS_SUCCESS;
4224: x_error_mssg := '';
4225:
4226:
4227: --check for the availability of all the values

Line 4231: x_error_flag := FND_API.G_RET_STS_ERROR;

4227: --check for the availability of all the values
4228: if(p_dep_direction is null or p_from_operation is null or
4229: p_to_operation is null or p_sche_start_date is null or
4230: p_sche_end_date is null) then
4231: x_error_flag := FND_API.G_RET_STS_ERROR;
4232: x_error_mssg := 'EAM_NOT_ENOUGH_VALUES';
4233: return;
4234: end if;
4235:

Line 4238: x_error_flag := FND_API.G_RET_STS_ERROR;

4234: end if;
4235:
4236: -- check for from and to operation
4237: if(p_from_operation = p_to_operation) then
4238: x_error_flag := FND_API.G_RET_STS_ERROR;
4239: x_error_mssg := 'EAM_FROM_TO_OPERATION_EQUAL';
4240: return;
4241: end if;
4242:

Line 4244: x_error_flag := FND_API.G_RET_STS_ERROR;

4240: return;
4241: end if;
4242:
4243: if(p_sche_end_date < p_sche_start_date) then
4244: x_error_flag := FND_API.G_RET_STS_ERROR;
4245: x_error_mssg := 'EAM_START_LESS_END_DATE';
4246: return;
4247: end if;
4248:

Line 4266: x_error_flag := FND_API.G_RET_STS_ERROR;

4262: wip_entity_id = p_wip_entity_id and
4263: operation_seq_num = p_from_operation ;
4264: Exception
4265: when NO_DATA_FOUND then
4266: x_error_flag := FND_API.G_RET_STS_ERROR;
4267: x_error_mssg := 'EAM_FROM_OPERATION_NOT_FOUND';
4268: return;
4269: End; -- end of
4270:

Line 4287: x_error_flag := FND_API.G_RET_STS_ERROR;

4283: wip_entity_id = p_wip_entity_id and
4284: operation_seq_num = p_to_operation ;
4285: Exception
4286: when NO_DATA_FOUND then
4287: x_error_flag := FND_API.G_RET_STS_ERROR;
4288: x_error_mssg := 'EAM_TO_OPERATION_NOT_FOUND';
4289: return;
4290: End; -- end of
4291:

Line 4322: x_error_flag := FND_API.G_RET_STS_ERROR;

4318: end if;
4319:
4320:
4321: if(l_restrict_date_change > 0) then
4322: x_error_flag := FND_API.G_RET_STS_ERROR;
4323: x_error_mssg := 'EAM_SCHEDULED_DATE_CHANGE';
4324: return;
4325: elsif(l_restrict_date_change = 0) then
4326: update wip_operations

Line 4367: x_error_flag := FND_API.G_RET_STS_ERROR;

4363: and wip_entity_id = p_wip_entity_id);
4364: end if;
4365:
4366: if(l_restrict_date_change > 0) then
4367: x_error_flag := FND_API.G_RET_STS_ERROR;
4368: x_error_mssg := 'EAM_SCHEDULED_DATE_CHANGE';
4369: return;
4370: elsif(l_restrict_date_change = 0) then
4371: update wip_operations

Line 4389: x_error_flag := FND_API.G_RET_STS_ERROR;

4385:
4386:
4387: -- check for the scheduled completion and start date of from and to operation respectively
4388: if (l_to_scheduled_start_date < l_from_scheduled_end_date ) then
4389: x_error_flag := FND_API.G_RET_STS_ERROR;
4390: x_error_mssg := 'EAM_DEP_OP_START_DATE_INVALID';
4391: return;
4392: end if;
4393:

Line 4406: x_error_flag := FND_API.G_RET_STS_ERROR;

4402: start with prior_operation = p_to_operation
4403: connect by prior_operation = prior next_operation) ;
4404:
4405: if(l_loop_available <> 0) then
4406: x_error_flag := FND_API.G_RET_STS_ERROR;
4407: x_error_mssg := 'EAM_OPMDF_OP_DEP_LOOP';
4408: end if;
4409:
4410: End validate_new_link;

Line 4476: x_error_flag := FND_API.G_RET_STS_SUCCESS;

4472:
4473: EAM_WORKORDER_UTIL_PKG.log_path(l_output_dir);
4474:
4475:
4476: x_error_flag := FND_API.G_RET_STS_SUCCESS;
4477: x_error_mssg := '';
4478:
4479: -- validate the link
4480: validate_new_link(

Line 4490: if(x_error_flag <> FND_API.G_RET_STS_SUCCESS) then

4486: p_sche_end_date,
4487: x_error_flag ,
4488: x_error_mssg ) ;
4489:
4490: if(x_error_flag <> FND_API.G_RET_STS_SUCCESS) then
4491: FND_MSG_PUB.Initialize;
4492: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => x_error_mssg);
4493: eam_execution_jsp.Get_Messages(
4494: p_encoded => FND_API.G_FALSE,

Line 4494: p_encoded => FND_API.G_FALSE,

4490: if(x_error_flag <> FND_API.G_RET_STS_SUCCESS) then
4491: FND_MSG_PUB.Initialize;
4492: eam_execution_jsp.add_message(p_app_short_name => 'EAM', p_msg_name => x_error_mssg);
4493: eam_execution_jsp.Get_Messages(
4494: p_encoded => FND_API.G_FALSE,
4495: p_msg_index => 1,
4496: p_msg_count => 1,
4497: p_msg_data => l_mssg_data,
4498: p_data => l_data,

Line 4629: x_error_flag := FND_API.G_RET_STS_SUCCESS;

4625:
4626: EAM_WORKORDER_UTIL_PKG.log_path(l_output_dir);
4627:
4628:
4629: x_error_flag := FND_API.G_RET_STS_SUCCESS;
4630: x_error_mssg := '';
4631:
4632: -- initializing the structure of dependency network
4633: l_eam_op_network_rec.transaction_type := EAM_PROCESS_WO_PVT.G_OPR_DELETE;

Line 4989: ,p_init_msg_list IN VARCHAR2 := FND_API.G_TRUE

4985: /* API to delete operation from self service side */
4986:
4987: procedure delete_operation (
4988: p_api_version IN NUMBER := 1.0
4989: ,p_init_msg_list IN VARCHAR2 := FND_API.G_TRUE
4990: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
4991: ,p_organization_id IN NUMBER
4992: ,p_wip_entity_id IN NUMBER
4993: ,p_operation_seq_num IN NUMBER

Line 4990: ,p_commit IN VARCHAR2 := FND_API.G_FALSE

4986:
4987: procedure delete_operation (
4988: p_api_version IN NUMBER := 1.0
4989: ,p_init_msg_list IN VARCHAR2 := FND_API.G_TRUE
4990: ,p_commit IN VARCHAR2 := FND_API.G_FALSE
4991: ,p_organization_id IN NUMBER
4992: ,p_wip_entity_id IN NUMBER
4993: ,p_operation_seq_num IN NUMBER
4994: ,p_department_id IN NUMBER

Line 5003: l_return_status VARCHAR2(1) := FND_API.G_RET_STS_SUCCESS;

4999:
5000: l_api_name constant varchar2(30) := 'Delete_Operations';
5001: l_api_version CONSTANT NUMBER := 1.0;
5002: l_msg_data VARCHAR2(10000) ;
5003: l_return_status VARCHAR2(1) := FND_API.G_RET_STS_SUCCESS;
5004: l_msg_count NUMBER;
5005: l_message_text VARCHAR2(1000);
5006:
5007: l_eam_wo_rec EAM_PROCESS_WO_PUB.eam_wo_rec_type;

Line 5053: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,

5049:
5050: SAVEPOINT DELETE_OPERATION_JSP;
5051:
5052:
5053: IF NOT FND_API.COMPATIBLE_API_CALL(l_api_version,
5054: p_api_version,
5055: l_api_name,
5056: g_pkg_name)
5057: THEN

Line 5058: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5054: p_api_version,
5055: l_api_name,
5056: g_pkg_name)
5057: THEN
5058: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5059: END IF;
5060:
5061: IF FND_API.TO_BOOLEAN(p_init_msg_list)
5062: THEN

Line 5061: IF FND_API.TO_BOOLEAN(p_init_msg_list)

5057: THEN
5058: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5059: END IF;
5060:
5061: IF FND_API.TO_BOOLEAN(p_init_msg_list)
5062: THEN
5063: FND_MSG_PUB.initialize;
5064: END IF;
5065:

Line 5126: IF(l_return_status <> FND_API.G_RET_STS_SUCCESS) THEN

5122: l_msg_count := FND_MSG_PUB.count_msg;
5123: x_return_status := l_return_status;
5124: x_msg_count := l_msg_count;
5125:
5126: IF(l_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
5127: ROLLBACK TO DELETE_OPERATION_JSP;
5128: fnd_msg_pub.get(p_msg_index => FND_MSG_PUB.G_NEXT,
5129: p_encoded => 'F',
5130: p_data => l_message_text,

Line 5142: IF p_commit = FND_API.G_TRUE THEN

5138:
5139: x_msg_data := 'Error ';
5140: END IF;
5141:
5142: IF p_commit = FND_API.G_TRUE THEN
5143: COMMIT WORK;
5144: end if;
5145: EXCEPTION
5146:

Line 5150: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

5146:
5147: when others then
5148: ROLLBACK TO DELETE_OPERATION_JSP;
5149:
5150: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
5151: return;
5152:
5153:
5154: end delete_operation;

Line 5162: p_commit IN VARCHAR2 := FND_API.G_FALSE

5158: -----------------------------------------------------------------------------*/
5159:
5160: PROCEDURE update_wro
5161: (
5162: p_commit IN VARCHAR2 := FND_API.G_FALSE
5163: ,p_organization_id IN NUMBER
5164: ,p_wip_entity_id IN NUMBER
5165: ,p_operation_seq_num IN NUMBER
5166: ,p_inventory_item_id IN NUMBER

Line 5337: IF fnd_api.to_boolean(p_commit)

5333: ROLLBACK TO update_wro;
5334: END IF;
5335:
5336: -- Standard check of p_commit.
5337: IF fnd_api.to_boolean(p_commit)
5338: and x_return_status = 'S' THEN
5339: COMMIT WORK;
5340: END IF;
5341:

Line 5346: x_return_status := fnd_api.g_ret_sts_unexp_error;

5342:
5343: EXCEPTION
5344: WHEN OTHERS THEN
5345: ROLLBACK TO update_wro;
5346: x_return_status := fnd_api.g_ret_sts_unexp_error;
5347:
5348: END update_wro;
5349:
5350: PROCEDURE delete_instance (

Line 5352: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

5348: END update_wro;
5349:
5350: PROCEDURE delete_instance (
5351: p_api_version IN NUMBER
5352: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
5353: ,p_commit IN VARCHAR2 := fnd_api.g_false
5354: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
5355: ,p_wip_entity_id IN NUMBER
5356: ,p_organization_id IN NUMBER

Line 5353: ,p_commit IN VARCHAR2 := fnd_api.g_false

5349:
5350: PROCEDURE delete_instance (
5351: p_api_version IN NUMBER
5352: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
5353: ,p_commit IN VARCHAR2 := fnd_api.g_false
5354: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
5355: ,p_wip_entity_id IN NUMBER
5356: ,p_organization_id IN NUMBER
5357: ,p_operation_seq_num IN NUMBER

Line 5354: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full

5350: PROCEDURE delete_instance (
5351: p_api_version IN NUMBER
5352: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
5353: ,p_commit IN VARCHAR2 := fnd_api.g_false
5354: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
5355: ,p_wip_entity_id IN NUMBER
5356: ,p_organization_id IN NUMBER
5357: ,p_operation_seq_num IN NUMBER
5358: ,p_resource_seq_num IN NUMBER

Line 5424: IF NOT fnd_api.compatible_api_call(

5420: SAVEPOINT delete_instance_pvt;
5421:
5422: l_stmt_num := 20;
5423: -- Standard call to check for call compatibility.
5424: IF NOT fnd_api.compatible_api_call(
5425: l_api_version
5426: ,p_api_version
5427: ,l_api_name
5428: ,g_pkg_name) THEN

Line 5429: RAISE fnd_api.g_exc_unexpected_error;

5425: l_api_version
5426: ,p_api_version
5427: ,l_api_name
5428: ,g_pkg_name) THEN
5429: RAISE fnd_api.g_exc_unexpected_error;
5430: END IF;
5431:
5432: l_stmt_num := 30;
5433:

Line 5435: IF fnd_api.to_boolean(p_init_msg_list) THEN

5431:
5432: l_stmt_num := 30;
5433:
5434: -- Initialize message list if p_init_msg_list is set to TRUE.
5435: IF fnd_api.to_boolean(p_init_msg_list) THEN
5436: fnd_msg_pub.initialize;
5437: END IF;
5438:
5439: l_stmt_num := 40;

Line 5441: x_return_status := fnd_api.g_ret_sts_success;

5437: END IF;
5438:
5439: l_stmt_num := 40;
5440: -- Initialize API return status to success
5441: x_return_status := fnd_api.g_ret_sts_success;
5442:
5443: l_stmt_num := 50;
5444: -- API body
5445:

Line 5509: IF fnd_api.to_boolean(p_commit)

5505:
5506:
5507: -- End of API body.
5508: -- Standard check of p_commit.
5509: IF fnd_api.to_boolean(p_commit)
5510: and x_return_status = 'S' THEN
5511: COMMIT WORK;
5512: END IF;
5513:

Line 5526: WHEN fnd_api.g_exc_error THEN

5522: p_count => x_msg_count
5523: ,p_data => x_msg_data);
5524:
5525: EXCEPTION
5526: WHEN fnd_api.g_exc_error THEN
5527: ROLLBACK TO get_delete_resources_pvt;
5528: x_return_status := fnd_api.g_ret_sts_error;
5529: fnd_msg_pub.count_and_get(
5530: -- p_encoded => FND_API.g_false

Line 5528: x_return_status := fnd_api.g_ret_sts_error;

5524:
5525: EXCEPTION
5526: WHEN fnd_api.g_exc_error THEN
5527: ROLLBACK TO get_delete_resources_pvt;
5528: x_return_status := fnd_api.g_ret_sts_error;
5529: fnd_msg_pub.count_and_get(
5530: -- p_encoded => FND_API.g_false
5531: p_count => x_msg_count
5532: ,p_data => x_msg_data);

Line 5530: -- p_encoded => FND_API.g_false

5526: WHEN fnd_api.g_exc_error THEN
5527: ROLLBACK TO get_delete_resources_pvt;
5528: x_return_status := fnd_api.g_ret_sts_error;
5529: fnd_msg_pub.count_and_get(
5530: -- p_encoded => FND_API.g_false
5531: p_count => x_msg_count
5532: ,p_data => x_msg_data);
5533:
5534: WHEN fnd_api.g_exc_unexpected_error THEN

Line 5534: WHEN fnd_api.g_exc_unexpected_error THEN

5530: -- p_encoded => FND_API.g_false
5531: p_count => x_msg_count
5532: ,p_data => x_msg_data);
5533:
5534: WHEN fnd_api.g_exc_unexpected_error THEN
5535: ROLLBACK TO get_delete_resources_pvt;
5536: x_return_status := fnd_api.g_ret_sts_unexp_error;
5537:
5538: fnd_msg_pub.count_and_get(

Line 5536: x_return_status := fnd_api.g_ret_sts_unexp_error;

5532: ,p_data => x_msg_data);
5533:
5534: WHEN fnd_api.g_exc_unexpected_error THEN
5535: ROLLBACK TO get_delete_resources_pvt;
5536: x_return_status := fnd_api.g_ret_sts_unexp_error;
5537:
5538: fnd_msg_pub.count_and_get(
5539: p_count => x_msg_count
5540: ,p_data => x_msg_data);

Line 5544: x_return_status := fnd_api.g_ret_sts_unexp_error;

5540: ,p_data => x_msg_data);
5541:
5542: WHEN OTHERS THEN
5543: ROLLBACK TO get_delete_resources_pvt;
5544: x_return_status := fnd_api.g_ret_sts_unexp_error;
5545: IF fnd_msg_pub.check_msg_level(
5546: fnd_msg_pub.g_msg_lvl_unexp_error) THEN
5547: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
5548: END IF;