DBA Data[Home] [Help]

APPS.EAM_WO_VALIDATE_PVT dependencies on WIP_CONSTANTS

Line 1176: IF ( p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED

1172: and nvl(p_old_eam_wo_rec.rebuild_serial_number,'null_old_serial_number') <>
1173: nvl(p_eam_wo_rec.rebuild_serial_number,'null_old_serial_number') )
1174: THEN
1175:
1176: IF ( p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED
1177: and p_old_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED )
1178: THEN
1179: EAM_WORKORDER_UTIL_PKG.CK_MATERIAL_ALLOC_ON_HOLD(X_Org_Id => p_eam_wo_rec.organization_id,
1180: X_Wip_Id => p_eam_wo_rec.wip_entity_id,

Line 1177: and p_old_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED )

1173: nvl(p_eam_wo_rec.rebuild_serial_number,'null_old_serial_number') )
1174: THEN
1175:
1176: IF ( p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED
1177: and p_old_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED )
1178: THEN
1179: EAM_WORKORDER_UTIL_PKG.CK_MATERIAL_ALLOC_ON_HOLD(X_Org_Id => p_eam_wo_rec.organization_id,
1180: X_Wip_Id => p_eam_wo_rec.wip_entity_id,
1181: X_Rep_Id => -1,

Line 1487: if p_eam_wo_rec.firm_planned_flag not in (wip_constants.yes, wip_constants.no) then

1483: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating firm_planned_flag . . . '); END IF;
1484:
1485: begin
1486:
1487: if p_eam_wo_rec.firm_planned_flag not in (wip_constants.yes, wip_constants.no) then
1488:
1489: raise fnd_api.g_exc_unexpected_error;
1490:
1491: end if;

Line 1716: p_eam_wo_rec.status_type not in (wip_constants.unreleased, wip_constants.released, wip_constants.hold, wip_constants.draft)) then

1712:
1713: begin
1714:
1715: if (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_CREATE and
1716: p_eam_wo_rec.status_type not in (wip_constants.unreleased, wip_constants.released, wip_constants.hold, wip_constants.draft)) then
1717:
1718: raise fnd_api.g_exc_unexpected_error;
1719:
1720: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then

Line 1721: if(p_eam_wo_rec.status_type not in (wip_constants.unreleased, wip_constants.released, wip_constants.comp_chrg,wip_constants.comp_nochrg, wip_constants.closed,

1717:
1718: raise fnd_api.g_exc_unexpected_error;
1719:
1720: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then
1721: if(p_eam_wo_rec.status_type not in (wip_constants.unreleased, wip_constants.released, wip_constants.comp_chrg,wip_constants.comp_nochrg, wip_constants.closed,
1722: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)
1723: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1724: /* Added the check so that status will not be updated to status Draft */
1725: --fix for 3389850.cannot change status from complete_no_charges to any status other than complete,closed.cannot change to complete_no_charges from status other than

Line 1722: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)

1718: raise fnd_api.g_exc_unexpected_error;
1719:
1720: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then
1721: if(p_eam_wo_rec.status_type not in (wip_constants.unreleased, wip_constants.released, wip_constants.comp_chrg,wip_constants.comp_nochrg, wip_constants.closed,
1722: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)
1723: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1724: /* Added the check so that status will not be updated to status Draft */
1725: --fix for 3389850.cannot change status from complete_no_charges to any status other than complete,closed.cannot change to complete_no_charges from status other than
1726: --complete

Line 1723: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))

1719:
1720: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then
1721: if(p_eam_wo_rec.status_type not in (wip_constants.unreleased, wip_constants.released, wip_constants.comp_chrg,wip_constants.comp_nochrg, wip_constants.closed,
1722: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)
1723: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1724: /* Added the check so that status will not be updated to status Draft */
1725: --fix for 3389850.cannot change status from complete_no_charges to any status other than complete,closed.cannot change to complete_no_charges from status other than
1726: --complete
1727: OR (p_old_eam_wo_rec.status_type=wip_constants.comp_nochrg AND p_eam_wo_rec.status_type NOT IN (wip_constants.comp_chrg,wip_constants.closed,wip_constants.comp_nochrg) )

Line 1727: OR (p_old_eam_wo_rec.status_type=wip_constants.comp_nochrg AND p_eam_wo_rec.status_type NOT IN (wip_constants.comp_chrg,wip_constants.closed,wip_constants.comp_nochrg) )

1723: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1724: /* Added the check so that status will not be updated to status Draft */
1725: --fix for 3389850.cannot change status from complete_no_charges to any status other than complete,closed.cannot change to complete_no_charges from status other than
1726: --complete
1727: OR (p_old_eam_wo_rec.status_type=wip_constants.comp_nochrg AND p_eam_wo_rec.status_type NOT IN (wip_constants.comp_chrg,wip_constants.closed,wip_constants.comp_nochrg) )
1728: /* Bug 3431204 - Should be able to link a Complete No charges WO to another
1729: Complete NO Charges WO */
1730: OR (p_eam_wo_rec.status_type=wip_constants.comp_nochrg
1731: AND p_old_eam_wo_rec.status_type NOT IN

Line 1730: OR (p_eam_wo_rec.status_type=wip_constants.comp_nochrg

1726: --complete
1727: OR (p_old_eam_wo_rec.status_type=wip_constants.comp_nochrg AND p_eam_wo_rec.status_type NOT IN (wip_constants.comp_chrg,wip_constants.closed,wip_constants.comp_nochrg) )
1728: /* Bug 3431204 - Should be able to link a Complete No charges WO to another
1729: Complete NO Charges WO */
1730: OR (p_eam_wo_rec.status_type=wip_constants.comp_nochrg
1731: AND p_old_eam_wo_rec.status_type NOT IN
1732: (wip_constants.comp_chrg, wip_constants.comp_nochrg,wip_constants.closed,wip_constants.fail_close))) then
1733:
1734: raise fnd_api.g_exc_unexpected_error;

Line 1732: (wip_constants.comp_chrg, wip_constants.comp_nochrg,wip_constants.closed,wip_constants.fail_close))) then

1728: /* Bug 3431204 - Should be able to link a Complete No charges WO to another
1729: Complete NO Charges WO */
1730: OR (p_eam_wo_rec.status_type=wip_constants.comp_nochrg
1731: AND p_old_eam_wo_rec.status_type NOT IN
1732: (wip_constants.comp_chrg, wip_constants.comp_nochrg,wip_constants.closed,wip_constants.fail_close))) then
1733:
1734: raise fnd_api.g_exc_unexpected_error;
1735:
1736: end if;

Line 1990: if(p_eam_wo_rec.wip_supply_type is not null and p_eam_wo_rec.wip_supply_type not in (wip_constants.push, wip_constants.bulk, wip_constants.based_on_bom)) then

1986: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating wip_supply_type . . . '); END IF;
1987:
1988: begin
1989:
1990: if(p_eam_wo_rec.wip_supply_type is not null and p_eam_wo_rec.wip_supply_type not in (wip_constants.push, wip_constants.bulk, wip_constants.based_on_bom)) then
1991: --not a valid supply type
1992:
1993: raise fnd_api.g_exc_unexpected_error;
1994:

Line 2129: AND nvl(mp.project_reference_enabled, 2) = wip_constants.yes

2125: WHERE mpv.project_id = ppp.project_id
2126: AND mpv.project_id = p_eam_wo_rec.project_id
2127: AND ppp.organization_id = p_eam_wo_rec.organization_id
2128: AND ppp.organization_id = mp.organization_id
2129: AND nvl(mp.project_reference_enabled, 2) = wip_constants.yes
2130: /* Commented for bug#5346213 Start
2131: AND (mpv.completion_date IS NULL OR mpv.completion_date >= l_min_date)
2132: AND (ppp.end_date_active IS NULL OR ppp.end_date_active >= l_min_date);
2133: Commented for bug#5346213 End */

Line 2500: and class_type = wip_constants.eam

2496: select disable_date
2497: into l_disable_date
2498: from wip_accounting_classes
2499: where class_code = p_eam_wo_rec.class_code
2500: and class_type = wip_constants.eam
2501: and organization_id = p_eam_wo_rec.organization_id;
2502:
2503: if(l_disable_date is not null and
2504: l_disable_date < nvl(p_eam_wo_rec.due_date, p_eam_wo_rec.requested_start_date)) then

Line 3036: if (p_eam_wo_rec.status_type in (WIP_CONSTANTS.HOLD,WIP_CONSTANTS.RELEASED) and

3032: l_date_released_calc DATE;
3033: l_min_open_period_date DATE;
3034: begin
3035:
3036: if (p_eam_wo_rec.status_type in (WIP_CONSTANTS.HOLD,WIP_CONSTANTS.RELEASED) and
3037: nvl(p_old_eam_wo_rec.status_type,0) not in(WIP_CONSTANTS.RELEASED, WIP_CONSTANTS.HOLD) and
3038: p_old_eam_wo_rec.date_released is null) then
3039:
3040: IF (p_eam_wo_rec.scheduled_start_date < sysdate) THEN

Line 3037: nvl(p_old_eam_wo_rec.status_type,0) not in(WIP_CONSTANTS.RELEASED, WIP_CONSTANTS.HOLD) and

3033: l_min_open_period_date DATE;
3034: begin
3035:
3036: if (p_eam_wo_rec.status_type in (WIP_CONSTANTS.HOLD,WIP_CONSTANTS.RELEASED) and
3037: nvl(p_old_eam_wo_rec.status_type,0) not in(WIP_CONSTANTS.RELEASED, WIP_CONSTANTS.HOLD) and
3038: p_old_eam_wo_rec.date_released is null) then
3039:
3040: IF (p_eam_wo_rec.scheduled_start_date < sysdate) THEN
3041: select nvl(min(period_start_date),p_eam_wo_rec.scheduled_start_date)

Line 3056: IF(p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED AND p_eam_wo_rec.date_released IS NOT NULL) THEN

3052:
3053: --date_released will be defaulted just before change_status procedure call in EAMVWOPB.pls.
3054: --hence if date_released is NULL, get the defaulted value but do not stamp defaulted value in work order record
3055: -- as date_released should be populated only when there is no workflow/workflow is approved
3056: IF(p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED AND p_eam_wo_rec.date_released IS NOT NULL) THEN
3057: l_date_released_calc := TRUNC(p_eam_wo_rec.date_released);
3058: END IF;
3059:
3060: select 1

Line 3279: and p_eam_wo_rec.status_type not in (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED) /* Bug no 3349197 */

3275:
3276:
3277:
3278: if p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE
3279: and p_eam_wo_rec.status_type not in (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED) /* Bug no 3349197 */
3280: and not(p_eam_wo_rec.status_type=WIP_CONSTANTS.RELEASED and (p_old_eam_wo_rec.status_type IN (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED,WIP_CONSTANTS.CANCELLED))) /*Bug No 3476156*/
3281: and p_eam_wo_rec.material_issue_by_mo <> p_old_eam_wo_rec.material_issue_by_mo then
3282:
3283: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN

Line 3280: and not(p_eam_wo_rec.status_type=WIP_CONSTANTS.RELEASED and (p_old_eam_wo_rec.status_type IN (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED,WIP_CONSTANTS.CANCELLED))) /*Bug No 3476156*/

3276:
3277:
3278: if p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE
3279: and p_eam_wo_rec.status_type not in (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED) /* Bug no 3349197 */
3280: and not(p_eam_wo_rec.status_type=WIP_CONSTANTS.RELEASED and (p_old_eam_wo_rec.status_type IN (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED,WIP_CONSTANTS.CANCELLED))) /*Bug No 3476156*/
3281: and p_eam_wo_rec.material_issue_by_mo <> p_old_eam_wo_rec.material_issue_by_mo then
3282:
3283: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN
3284: EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating material_issue_by_mo flag . .wip_entity_id' || p_eam_wo_rec.wip_entity_id);

Line 3288: if ((p_eam_wo_rec.status_type = WIP_CONSTANTS.HOLD) OR (p_eam_wo_rec.status_type=WIP_CONSTANTS.RELEASED and p_old_eam_wo_rec.status_type=WIP_CONSTANTS.HOLD)) then /*Bug no 3476156*/

3284: EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating material_issue_by_mo flag . .wip_entity_id' || p_eam_wo_rec.wip_entity_id);
3285: EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating material_issue_by_mo flag . .org_id' || p_eam_wo_rec.organization_id);
3286: END IF;
3287:
3288: if ((p_eam_wo_rec.status_type = WIP_CONSTANTS.HOLD) OR (p_eam_wo_rec.status_type=WIP_CONSTANTS.RELEASED and p_old_eam_wo_rec.status_type=WIP_CONSTANTS.HOLD)) then /*Bug no 3476156*/
3289: -- If material allocation has been done then raise error
3290: EAM_WORKORDER_UTIL_PKG.CK_MATERIAL_ALLOC_ON_HOLD(X_Org_Id => p_eam_wo_rec.organization_id,
3291: X_Wip_Id => p_eam_wo_rec.wip_entity_id,
3292: X_Rep_Id => -1,

Line 3477: IF p_eam_wo_rec.status_type not in (wip_constants.draft, wip_constants.unreleased,wip_constants.cancelled, wip_constants.hold)

3473:
3474: -- agaurav - Added the check that owning_department is not mandatory
3475: -- - in the statuses DRAFT and UNRELEASED.
3476:
3477: IF p_eam_wo_rec.status_type not in (wip_constants.draft, wip_constants.unreleased,wip_constants.cancelled, wip_constants.hold)
3478: THEN
3479: IF p_eam_wo_rec.owning_department IS NULL
3480: THEN
3481: l_token_tbl(1).token_name := 'WIP_ENTITY_NAME';

Line 3744: IF ( p_eam_wo_rec.status_type in ( WIP_CONSTANTS.RELEASED )

3740:
3741: END IF;
3742:
3743: /* Added the validation that rebuild serial number is mandatory in status Released */
3744: IF ( p_eam_wo_rec.status_type in ( WIP_CONSTANTS.RELEASED )
3745: and p_eam_wo_rec.rebuild_serial_number is NULL
3746: and p_eam_wo_rec.asset_group_id is NULL
3747: and p_eam_wo_rec.maintenance_object_type = 3
3748: and p_eam_wo_rec.maintenance_object_source = 1)