| Quintiq file version 2.0 | 
| #parent: #root | 
| Method EnableDisableComponent () id:Method_DialogCreateEditUnit_EnableDisableComponent | 
| { | 
|   #keys: '[11660.0.1349223191]' | 
|   Body: | 
|   [* | 
|     // Enable / disable component | 
|     SelectionParent.Enabled( CheckBoxParent.Checked() ); | 
|      | 
|     //Enable / disable date | 
|     GUIDateTimeSelectorStart.Enabled( CheckBoxHasStart.Checked() ); | 
|     GUIDateTimeSelectorEnd.Enabled( CheckBoxHasEnd.Checked() ); | 
|      | 
|     // Enable / disable maximum quantity editor | 
|     EditorMaximumQuantity.Enabled( CheckBoxMaximumQuantity.Checked() ); | 
|      | 
|     // Enable / disable capacity smoothing components | 
|     EditorCapacitySmoothingPercentageDelta.Enabled( CheckBoxHasCapacitySmoothing.Checked() ); | 
|     RadioButtonGroupIsSmoothCapacityOverAllPeriods.Enabled( CheckBoxHasCapacitySmoothing.Checked() ); | 
|     CheckBoxIsOverlapCapacitySmoothing.Enabled( CheckBoxHasCapacitySmoothing.Checked() ); | 
|     EditorCapacitySmoothingLength.Enabled( CheckBoxHasCapacitySmoothing.Checked() and not [Boolean]RadioButtonGroupIsSmoothCapacityOverAllPeriods.BoundValue() ); | 
|      | 
|     // Enable / disable FrozenFutureDuration related | 
|     GUIDurationSelectorUserFrozenFutureDuration.Enabled( CheckBoxHasUserFrozenFutureDuration.Checked() ); | 
|      | 
|     capacitytype := RadioButtonGroupCapacityType.BoundValue() | 
|     istransport := capacitytype = GlobalParameters_MP::GetCapacityTypeTransportTime() | 
|                    or capacitytype = GlobalParameters_MP::GetCapacityTypeTransportQuantity(); | 
|      | 
|      | 
|     RadioButtonGroupIsUsingOutputForCapacity.Enabled( not istransport ); | 
|     GroupPanelCapacitySmoothing.Enabled( not istransport ); | 
|   *] | 
| } |