Quintiq file version 2.0
|
#parent: #root
|
Method ShowHideComponents () id:Method_DialogCreateEditStrategy_ShowHideComponents
|
{
|
#keys: '[146140.2.142759628]'
|
Body:
|
[*
|
// Show / hide components
|
|
data := DataHolderDialogData.Data();
|
inbound := exists( data, KPIWeight, kpiw, kpiw.KPI().IsMaximize() and kpiw.Level() = 1 );
|
invalidkpi := guard( not data.IsValidKPIWeight(), false )
|
procminqtyissue := exists( data, KPIWeight, kpiw, true, kpiw.KPIName() = Translations::MP_GlobalParameters_KPIProcessMinimumQuantity() and kpiw.Level() > 1 );
|
isvisible := inbound or invalidkpi or procminqtyissue;
|
text :='';
|
ImageOptimizerUnbounded.Visible( isvisible );
|
|
if( inbound )
|
{
|
text := Translations::MP_Designer_InboundStrategy_Warning();
|
}
|
else if( invalidkpi )
|
{
|
invalidkpiweightname := guard( select( data, InvalidKPIWeight, kpiweight, true ).KPIName(), "" )
|
text := Translations::Strategy_CanCopy_IsKPIWeightOK( invalidkpiweightname );
|
}
|
else if ( procminqtyissue )
|
{
|
text := Translations::MP_Designer_ProcessMinQtyWarning();
|
}
|
ImageOptimizerUnbounded.Tooltip( text );
|
*]
|
}
|