mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-31 01:34:12 +02:00
SyncRuleForm: refine descriptions
This commit is contained in:
parent
c216d896e9
commit
97e2a73a48
@ -30,35 +30,50 @@ class SyncRuleForm extends DirectorObjectForm
|
|||||||
|
|
||||||
$this->addElement('select', 'object_type', array(
|
$this->addElement('select', 'object_type', array(
|
||||||
'label' => $this->translate('Object Type'),
|
'label' => $this->translate('Object Type'),
|
||||||
'description' => $this->translate('Choose a object type'),
|
'description' => $this->translate('Choose an object type'),
|
||||||
'required' => true,
|
'required' => true,
|
||||||
'multiOptions' => $this->optionalEnum($availableTypes)
|
'multiOptions' => $this->optionalEnum($availableTypes)
|
||||||
));
|
));
|
||||||
|
|
||||||
$this->addElement('select', 'update_policy', array(
|
$this->addElement('select', 'update_policy', array(
|
||||||
'label' => $this->translate('Update Policity'),
|
'label' => $this->translate('Update Policity'),
|
||||||
'description' => $this->translate('Whether the field should be merged, replaced or ignored'),
|
'description' => $this->translate(
|
||||||
|
'Define what should happen when an object with a matching key'
|
||||||
|
. " already exists. You could merge it's properties (import source"
|
||||||
|
. ' wins), replace it completely with the imported object or ignore'
|
||||||
|
. ' it (helpful for one-time imports)'
|
||||||
|
),
|
||||||
'required' => true,
|
'required' => true,
|
||||||
'multiOptions' => $this->optionalEnum(array(
|
'multiOptions' => $this->optionalEnum(array(
|
||||||
'merge' => 'merge',
|
'merge' => $this->translate('Merge'),
|
||||||
'override' => 'replace',
|
'override' => $this->translate('Replace'),
|
||||||
'ignore' => 'ignore'
|
'ignore' => $this->translate('Ignore'),
|
||||||
))
|
))
|
||||||
));
|
));
|
||||||
|
|
||||||
$this->addElement('select', 'purge_existing', array(
|
$this->addElement('select', 'purge_existing', array(
|
||||||
'label' => $this->translate('Purge'),
|
'label' => $this->translate('Purge'),
|
||||||
'description' => $this->translate('Purge existing values.'),
|
'description' => $this->translate(
|
||||||
'required' => true,
|
'Whether to purge existing objects. This means that objects of'
|
||||||
|
. ' the same type will be removed from Director in case they no'
|
||||||
|
. ' longer exist at your import source.'
|
||||||
|
),
|
||||||
|
'required' => true,
|
||||||
'multiOptions' => $this->optionalEnum(array(
|
'multiOptions' => $this->optionalEnum(array(
|
||||||
'y' => 'yes',
|
'y' => $this->translate('Yes'),
|
||||||
'n' => 'no'
|
'n' => $this->translate('No')
|
||||||
))
|
))
|
||||||
));
|
));
|
||||||
|
|
||||||
$this->addElement('text', 'filter_expression', array(
|
$this->addElement('text', 'filter_expression', array(
|
||||||
'label' => $this->translate('Filter Expression'),
|
'label' => $this->translate('Filter Expression'),
|
||||||
'description' => $this->translate('This allows to filter for specific parts'),
|
'description' => sprintf(
|
||||||
|
$this->translate(
|
||||||
|
'Sync only part of your imported objects with this rule. Icinga Web 2'
|
||||||
|
. ' filter syntax is allowed, so this could look as follows: %s'
|
||||||
|
),
|
||||||
|
'(host=a|host=b)&!ip=127.*'
|
||||||
|
),
|
||||||
));
|
));
|
||||||
|
|
||||||
$this->setButtons();
|
$this->setButtons();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user