summaryrefslogtreecommitdiffstats
path: root/application/forms/BasketForm.php
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-14 13:17:47 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-14 13:17:47 +0000
commit5419d4428c86c488a43124f85e5407d7cbae6541 (patch)
tree772c4221a20fd7d1b3e7e67c6e21755a50e80fd7 /application/forms/BasketForm.php
parentAdding upstream version 1.10.2. (diff)
downloadicingaweb2-module-director-upstream.tar.xz
icingaweb2-module-director-upstream.zip
Adding upstream version 1.11.1.upstream/1.11.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--application/forms/BasketForm.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/application/forms/BasketForm.php b/application/forms/BasketForm.php
index 8ff6cca..4ac942c 100644
--- a/application/forms/BasketForm.php
+++ b/application/forms/BasketForm.php
@@ -52,9 +52,9 @@ class BasketForm extends DirectorObjectForm
$types = $this->getAvailableTypes();
$options = [
- 'IGNORE' => $this->translate('Ignore'),
- 'ALL' => $this->translate('All of them'),
- '[]' => $this->translate('Custom Selection'),
+ Basket::SELECTION_NONE => $this->translate('Ignore'),
+ Basket::SELECTION_ALL => $this->translate('All of them'),
+ Basket::SELECTION_CUSTOM => $this->translate('Custom Selection'),
];
$this->addHtmlHint($this->translate(
@@ -92,13 +92,13 @@ class BasketForm extends DirectorObjectForm
/** @var Basket $object */
$values = [];
foreach ($this->getAvailableTypes() as $type => $label) {
- $values[$type] = 'IGNORE';
+ $values[$type] = Basket::SELECTION_NONE;
}
foreach ($object->getChosenObjects() as $type => $selection) {
if ($selection === true) {
- $values[$type] = 'ALL';
+ $values[$type] = Basket::SELECTION_ALL;
} elseif (is_array($selection)) {
- $values[$type] = '[]';
+ $values[$type] = Basket::SELECTION_CUSTOM;
}
}