|
|
@@ -125,16 +125,26 @@ class GeneralSection extends BaseSection
|
|
|
$this->addField($field);
|
|
|
}
|
|
|
//memory
|
|
|
+
|
|
|
+ logModuleCall(
|
|
|
+ 'proxmoxCloud',
|
|
|
+ __FUNCTION__,
|
|
|
+ $vm->status(),
|
|
|
+ 'Debug',
|
|
|
+ $this->configuration()->serverMemory->min
|
|
|
+ );
|
|
|
+
|
|
|
if(!$vm->isRunning()) {
|
|
|
$field = new Range('memory', $this->resourceManager->memory()->getMin(), $this->resourceManager->memory()->free());
|
|
|
$field->addValidator(new NumberValidator($this->resourceManager->memory()->getMin(), $this->resourceManager->memory()->free(),true));
|
|
|
+ $field->setDefaultValue($this->configuration()->serverMemory->min);
|
|
|
$field->setDescription('description');
|
|
|
} else {
|
|
|
$field = new Range('memory', $vm->config()['memory'], $this->resourceManager->memory()->free());
|
|
|
$field->addValidator(new NumberValidator($vm->config()['memory'], $this->resourceManager->memory()->free(),true));
|
|
|
+ $field->setDefaultValue($vm->config()['memory']);
|
|
|
$field->setDescription('Zur Speicherreduzierung muß die VM heruntergefahren sein!');
|
|
|
}
|
|
|
- $field->setDefaultValue($vm->config()['memory']);
|
|
|
$this->addField($field);
|
|
|
/**
|
|
|
* @deprecated
|