Quintiq file version 2.0
|
#parent: #root
|
Method GetHasValidUnit (
|
output Strings feedback_o,
|
output Strings sanitycheckfeedback_o
|
) declarative remote as Boolean
|
{
|
Description: 'Check if the operation is created with valid unit.'
|
TextBody:
|
[*
|
// DWE2 Feb-22-2016 (created)
|
isvalid := not this.Unit().IsChildOfAggregatedCapacity();
|
|
if( not isnull( feedback_o ) and not isvalid )
|
{
|
name := MacroPlan::GetSubstituteName( this.Name() ); // To avoid empty name/name too long
|
feedback_o.Add( SanityCheckMessage::GetFormattedMessage( Translations::MP_Process_Instance( this.DefinitionName(), name ),
|
Translations::MP_Operation_CanCreate_NotAggregatedUnit() ) );
|
sanitycheckfeedback_o.Add( SanityCheckCategoryLevel::GetSanityCheckCategoryUnclassifiedError() );
|
}
|
|
return isvalid;
|
*]
|
}
|