CDS标准视图:安排维护计划的调用 I_MAINTENANCEPLANSCHEDULE
视图名称:安排维护计划的调用 I_MAINTENANCEPLANSCHEDULE
视图类型:
视图代码:
点击查看代码
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.sqlViewName: 'IMPLASCHED'
@AccessControl.authorizationCheck: #CHECK
@ClientHandling.algorithm: #SESSION_VARIABLE
@EndUserText.label: 'Scheduled calls for Maintenance Plan'
@Metadata.ignorePropagatedAnnotations: true
@ObjectModel: {
modelingPattern: #NONE,
supportedCapabilities: [#CDS_MODELING_DATA_SOURCE],
semanticKey: [ 'MaintenancePlan','MaintenancePlanCallNumber' ],
usageType: {
dataClass: #MASTER,
serviceQuality: #C,
sizeCategory: #M
}
}
@VDM.viewType: #COMPOSITE
@AbapCatalog.preserveKey: true
define view I_MaintenancePlanSchedule
as select from I_MaintPlanCallHistory
association [0..1] to I_MaintCallSchedulingType as _SchedulingType on _SchedulingType.SchedulingType = $projection.SchedulingType
association [0..1] to P_MaintenanceSingleCycle as _MaintenanceSingleCycle on _MaintenanceSingleCycle.MaintenancePlan = $projection.MaintenancePlan
association [0..1] to I_UnitOfMeasure as _MaintTaskPerformanceUnit on _MaintTaskPerformanceUnit.UnitOfMeasure = $projection.MaintenanceTaskPerformanceUnit
association [0..1] to P_MaintCallCompltnDateTime as _MaintCallCompltnDateTime on _MaintCallCompltnDateTime.MaintenancePlan = $projection.MaintenancePlan
and _MaintCallCompltnDateTime.MaintenanceCall = $projection.MaintenancePlanCallNumber
association [1..1] to I_MaintenancePlanBasic as _MaintenancePlan on _MaintenancePlan.MaintenancePlan = $projection.MaintenancePlan
association [1..*] to I_MaintPlanCallHrznCalcTypeTxt as _CallHrznCalcTypeTxt on _CallHrznCalcTypeTxt.MaintenanceCallHorizonCalcType = $projection.MaintenanceCallHorizonCalcType
{
@ObjectModel.foreignKey.association: '_MaintenancePlan'
key MaintenancePlan,
key MaintenancePlanCallNumber,
key MaintenancePackage,
MaintenanceStrategy as MaintenanceStrategy,
@ObjectModel.foreignKey.association: '_SchedulingType'
SchedulingType as SchedulingType,
SchedulingStatus as SchedulingStatus,
_MaintenanceSingleCycle.MeasuringPoint as MeasuringPoint,
@ObjectModel.foreignKey.association: '_MaintTaskPerformanceUnit'
case _MaintenanceSingleCycle.MaintenanceTaskPerformanceUnit
when '' then _MaintenancePackage.MaintenanceTaskPerformanceUnit
else _MaintenanceSingleCycle.MaintenanceTaskPerformanceUnit
end as MaintenanceTaskPerformanceUnit,
MaintenanceCallNextPlannedDate as MaintenanceCallNextPlannedDate,
MaintenanceCallDate as MaintenanceCallDate,
case CompletionDate
when '00000000' then _MaintCallCompltnDateTime.CompletionDate
else CompletionDate
end as CompletionDate,
_MaintCallCompltnDateTime.CompletionTime as CompletionTime,
CycleSetSequence as CycleSetSequence,
MaintCallCompltnCntrRdng as MaintCallCompltnCntrRdng,
@Semantics.quantity.unitOfMeasure: 'MaintenanceTaskPerformanceUnit'
MaintCallNextPlndCntrRdng as MaintCallNextPlndCntrRdng,
MaintenanceCallIsOutstanding as MaintenanceCallIsOutstanding,
MaintCallIsInvokedOnPlndDate as MaintCallIsInvokedOnPlndDate,
MaintCallHorizonIsNotReached as MaintCallHorizonIsNotReached,
MaintPlanLastScheduledDate as MaintPlanLastScheduledDate,
ReleasedByUserName,
cast ('' as abap.char(256) ) as MaintPlnCnctntdDuePackagesTxt,
_MaintenancePlan.MaintenanceCallHorizonCalcType as MaintenanceCallHorizonCalcType,
MaintPlanPrdcssrCallCompltnDte,
MaintenancePlanManualCallDate,
/* Associations - locally defined */
_MaintenancePlan,
_SchedulingType,
_MaintTaskPerformanceUnit,
_ReleasedByUserName,
_CallHrznCalcTypeTxt,
_MaintenancePackage
}
事务代码:
视图结构:
字段名称 | 技术名称 |
---|---|
维护计划 | MAINTENANCEPLAN |
调用号 | MAINTENANCEPLANCALLNUMBER |
维护包 | MAINTENANCEPACKAGE |
策略 | MAINTENANCESTRATEGY |
计划类型 | SCHEDULINGTYPE |
计划状态 | SCHEDULINGSTATUS |
测量点 | MEASURINGPOINT |
单位 | MAINTENANCETASKPERFORMANCEUNIT |
计划日期 | MAINTENANCECALLNEXTPLANNEDDATE |
调用日期 | MAINTENANCECALLDATE |
最后完成 | COMPLETIONDATE |
COMPLETIONTIME | |
循环集顺序 | CYCLESETSEQUENCE |
公司确认的读数 | MAINTCALLCOMPLTNCNTRRDNG |
TL 计数器 | MAINTCALLNEXTPLNDCNTRRDNG |
计划状态 | MAINTENANCECALLISOUTSTANDING |
计划状态 | MAINTCALLISINVOKEDONPLNDDATE |
计划状态 | MAINTCALLHORIZONISNOTREACHED |
调用日期 | MAINTPLANLASTSCHEDULEDDATE |
名称 | RELEASEDBYUSERNAME |
MAINTPLNCNCTNTDDUEPACKAGESTXT | |
计算类型 | MAINTENANCECALLHORIZONCALCTYPE |
前趋完成 | MAINTPLANPRDCSSRCALLCOMPLTNDTE |
手工调用 | MAINTENANCEPLANMANUALCALLDATE |
本文来自博客园,作者:观兴,转载请注明原文链接:https://www.cnblogs.com/guanxing/p/18659214