DBA Data[Home] [Help]

APPS.EAM_WO_VALIDATE_PVT dependencies on WIP_CONSTANTS

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

1092: and nvl(p_old_eam_wo_rec.rebuild_serial_number,'null_old_serial_number') <>
1093: nvl(p_eam_wo_rec.rebuild_serial_number,'null_old_serial_number') )
1094: THEN
1095:
1096: IF ( p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED
1097: and p_old_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED )
1098: THEN
1099: EAM_WORKORDER_UTIL_PKG.CK_MATERIAL_ALLOC_ON_HOLD(X_Org_Id => p_eam_wo_rec.organization_id,
1100: X_Wip_Id => p_eam_wo_rec.wip_entity_id,

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

1093: nvl(p_eam_wo_rec.rebuild_serial_number,'null_old_serial_number') )
1094: THEN
1095:
1096: IF ( p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED
1097: and p_old_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED )
1098: THEN
1099: EAM_WORKORDER_UTIL_PKG.CK_MATERIAL_ALLOC_ON_HOLD(X_Org_Id => p_eam_wo_rec.organization_id,
1100: X_Wip_Id => p_eam_wo_rec.wip_entity_id,
1101: X_Rep_Id => -1,

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

1403: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating firm_planned_flag . . . '); END IF;
1404:
1405: begin
1406:
1407: if p_eam_wo_rec.firm_planned_flag not in (wip_constants.yes, wip_constants.no) then
1408:
1409: raise fnd_api.g_exc_unexpected_error;
1410:
1411: end if;

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

1632:
1633: begin
1634:
1635: if (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_CREATE and
1636: p_eam_wo_rec.status_type not in (wip_constants.unreleased, wip_constants.released, wip_constants.hold, wip_constants.draft)) then
1637:
1638: raise fnd_api.g_exc_unexpected_error;
1639:
1640: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then

Line 1641: 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,

1637:
1638: raise fnd_api.g_exc_unexpected_error;
1639:
1640: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then
1641: 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,
1642: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)
1643: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1644: /* Added the check so that status will not be updated to status Draft */
1645: --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 1642: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)

1638: raise fnd_api.g_exc_unexpected_error;
1639:
1640: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then
1641: 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,
1642: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)
1643: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1644: /* Added the check so that status will not be updated to status Draft */
1645: --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
1646: --complete

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

1639:
1640: elsif (p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE) then
1641: 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,
1642: wip_constants.hold, wip_constants.cancelled, wip_constants.pend_sched, wip_constants.draft)
1643: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1644: /* Added the check so that status will not be updated to status Draft */
1645: --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
1646: --complete
1647: 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 1647: 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) )

1643: OR ( p_eam_wo_rec.status_type in (wip_constants.draft) and p_old_eam_wo_rec.status_type not in (wip_constants.draft))
1644: /* Added the check so that status will not be updated to status Draft */
1645: --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
1646: --complete
1647: 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) )
1648: /* Bug 3431204 - Should be able to link a Complete No charges WO to another
1649: Complete NO Charges WO */
1650: OR (p_eam_wo_rec.status_type=wip_constants.comp_nochrg
1651: AND p_old_eam_wo_rec.status_type NOT IN

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

1646: --complete
1647: 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) )
1648: /* Bug 3431204 - Should be able to link a Complete No charges WO to another
1649: Complete NO Charges WO */
1650: OR (p_eam_wo_rec.status_type=wip_constants.comp_nochrg
1651: AND p_old_eam_wo_rec.status_type NOT IN
1652: (wip_constants.comp_chrg, wip_constants.comp_nochrg,wip_constants.closed,wip_constants.fail_close))) then
1653:
1654: raise fnd_api.g_exc_unexpected_error;

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

1648: /* Bug 3431204 - Should be able to link a Complete No charges WO to another
1649: Complete NO Charges WO */
1650: OR (p_eam_wo_rec.status_type=wip_constants.comp_nochrg
1651: AND p_old_eam_wo_rec.status_type NOT IN
1652: (wip_constants.comp_chrg, wip_constants.comp_nochrg,wip_constants.closed,wip_constants.fail_close))) then
1653:
1654: raise fnd_api.g_exc_unexpected_error;
1655:
1656: end if;

Line 1910: 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

1906: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating wip_supply_type . . . '); END IF;
1907:
1908: begin
1909:
1910: 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
1911: --not a valid supply type
1912:
1913: raise fnd_api.g_exc_unexpected_error;
1914:

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

2045: WHERE mpv.project_id = ppp.project_id
2046: AND mpv.project_id = p_eam_wo_rec.project_id
2047: AND ppp.organization_id = p_eam_wo_rec.organization_id
2048: AND ppp.organization_id = mp.organization_id
2049: AND nvl(mp.project_reference_enabled, 2) = wip_constants.yes
2050: /* Commented for bug#5346213 Start
2051: AND (mpv.completion_date IS NULL OR mpv.completion_date >= l_min_date)
2052: AND (ppp.end_date_active IS NULL OR ppp.end_date_active >= l_min_date);
2053: Commented for bug#5346213 End */

Line 2420: and class_type = wip_constants.eam

2416: select disable_date
2417: into l_disable_date
2418: from wip_accounting_classes
2419: where class_code = p_eam_wo_rec.class_code
2420: and class_type = wip_constants.eam
2421: and organization_id = p_eam_wo_rec.organization_id;
2422:
2423: if(l_disable_date is not null and
2424: l_disable_date < nvl(p_eam_wo_rec.due_date, p_eam_wo_rec.requested_start_date)) then

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

2952: l_date_released_calc DATE;
2953: l_min_open_period_date DATE;
2954: begin
2955:
2956: if (p_eam_wo_rec.status_type in (WIP_CONSTANTS.HOLD,WIP_CONSTANTS.RELEASED) and
2957: nvl(p_old_eam_wo_rec.status_type,0) not in(WIP_CONSTANTS.RELEASED, WIP_CONSTANTS.HOLD) and
2958: p_old_eam_wo_rec.date_released is null) then
2959:
2960: IF (p_eam_wo_rec.scheduled_start_date < sysdate) THEN

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

2953: l_min_open_period_date DATE;
2954: begin
2955:
2956: if (p_eam_wo_rec.status_type in (WIP_CONSTANTS.HOLD,WIP_CONSTANTS.RELEASED) and
2957: nvl(p_old_eam_wo_rec.status_type,0) not in(WIP_CONSTANTS.RELEASED, WIP_CONSTANTS.HOLD) and
2958: p_old_eam_wo_rec.date_released is null) then
2959:
2960: IF (p_eam_wo_rec.scheduled_start_date < sysdate) THEN
2961: select nvl(min(period_start_date),p_eam_wo_rec.scheduled_start_date)

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

2972:
2973: --date_released will be defaulted just before change_status procedure call in EAMVWOPB.pls.
2974: --hence if date_released is NULL, get the defaulted value but do not stamp defaulted value in work order record
2975: -- as date_released should be populated only when there is no workflow/workflow is approved
2976: IF(p_eam_wo_rec.status_type = WIP_CONSTANTS.RELEASED AND p_eam_wo_rec.date_released IS NOT NULL) THEN
2977: l_date_released_calc := TRUNC(p_eam_wo_rec.date_released);
2978: END IF;
2979:
2980: select 1

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

3179:
3180:
3181:
3182: if p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE
3183: and p_eam_wo_rec.status_type not in (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED) /* Bug no 3349197 */
3184: 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*/
3185: and p_eam_wo_rec.material_issue_by_mo <> p_old_eam_wo_rec.material_issue_by_mo then
3186:
3187: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN

Line 3184: 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*/

3180:
3181:
3182: if p_eam_wo_rec.transaction_type = EAM_PROCESS_WO_PVT.G_OPR_UPDATE
3183: and p_eam_wo_rec.status_type not in (WIP_CONSTANTS.DRAFT,WIP_CONSTANTS.UNRELEASED) /* Bug no 3349197 */
3184: 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*/
3185: and p_eam_wo_rec.material_issue_by_mo <> p_old_eam_wo_rec.material_issue_by_mo then
3186:
3187: IF EAM_PROCESS_WO_PVT.GET_DEBUG = 'Y' THEN
3188: EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating material_issue_by_mo flag . .wip_entity_id' || p_eam_wo_rec.wip_entity_id);

Line 3192: 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*/

3188: EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating material_issue_by_mo flag . .wip_entity_id' || p_eam_wo_rec.wip_entity_id);
3189: EAM_ERROR_MESSAGE_PVT.Write_Debug('Validating material_issue_by_mo flag . .org_id' || p_eam_wo_rec.organization_id);
3190: END IF;
3191:
3192: 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*/
3193: -- If material allocation has been done then raise error
3194: EAM_WORKORDER_UTIL_PKG.CK_MATERIAL_ALLOC_ON_HOLD(X_Org_Id => p_eam_wo_rec.organization_id,
3195: X_Wip_Id => p_eam_wo_rec.wip_entity_id,
3196: X_Rep_Id => -1,

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

3377:
3378: -- agaurav - Added the check that owning_department is not mandatory
3379: -- - in the statuses DRAFT and UNRELEASED.
3380:
3381: IF p_eam_wo_rec.status_type not in (wip_constants.draft, wip_constants.unreleased,wip_constants.cancelled, wip_constants.hold)
3382: THEN
3383: IF p_eam_wo_rec.owning_department IS NULL
3384: THEN
3385: l_token_tbl(1).token_name := 'WIP_ENTITY_NAME';

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

3644:
3645: END IF;
3646:
3647: /* Added the validation that rebuild serial number is mandatory in status Released */
3648: IF ( p_eam_wo_rec.status_type in ( WIP_CONSTANTS.RELEASED )
3649: and p_eam_wo_rec.rebuild_serial_number is NULL
3650: and p_eam_wo_rec.asset_group_id is NULL
3651: and p_eam_wo_rec.maintenance_object_type = 3
3652: and p_eam_wo_rec.maintenance_object_source = 1)