yanweiyuan3
2023-09-11 7804ec7a70a7ffe3116daec64154c15842f8c513
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Quintiq file version 2.0
#parent: #root
Method GetUtilizationReportParameters (
  internal[GUIComponent] parent,
  output NamedValueTree parameters,
  output String format
) as Number id:Method_DialogGenerateUtilizationReport_GetUtilizationReportParameters
{
  #keys: '[107654.0.854358686]'
  Body:
  [*
    // This should be done by an overloaded GetReportParameters,
    // but super.GetReportParameters() is an error. Why?
    
    result := this.GetReportParameters( parent, parameters, format );
    
    if ( result > 0 )
    {
      capbelowhandle := parameters.GetHandle( "CapacityBelowThreshold" );
      capabovehandle := parameters.GetHandle( "CapacityAboveThreshold" );
      parameters.Root().AddChild( capbelowhandle, [Real]EditorWarningCapacity.Text() );
      parameters.Root().AddChild( capabovehandle, [Real]EditorOverloadCapacity.Text() );
    }
    
    return result;
  *]
}