[icinga-checkins] icinga.org: icingaweb2-module-director/master: IcingaObject: render assign_filter property

git at icinga.org git at icinga.org
Tue Oct 25 04:39:58 CEST 2016


Module: icingaweb2-module-director
Branch: master
Commit: 6ed24f93dab6e3b4bcc0a84fa1b4c8aeec2303e1
URL:    https://git.icinga.org/?p=icingaweb2-module-director.git;a=commit;h=6ed24f93dab6e3b4bcc0a84fa1b4c8aeec2303e1

Author: Thomas Gelf <thomas at gelf.net>
Date:   Fri Oct 21 18:15:41 2016 +0000

IcingaObject: render assign_filter property

---

 library/Director/Objects/IcingaObject.php |   12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/library/Director/Objects/IcingaObject.php b/library/Director/Objects/IcingaObject.php
index 6d1a7cb..636896a 100644
--- a/library/Director/Objects/IcingaObject.php
+++ b/library/Director/Objects/IcingaObject.php
@@ -3,6 +3,7 @@
 namespace Icinga\Module\Director\Objects;
 
 use Icinga\Module\Director\CustomVariable\CustomVariables;
+use Icinga\Module\Director\IcingaConfig\AssignRenderer;
 use Icinga\Module\Director\Data\Db\DbObject;
 use Icinga\Module\Director\Db\Cache\PrefetchCache;
 use Icinga\Module\Director\Db;
@@ -1933,6 +1934,17 @@ abstract class IcingaObject extends DbObject implements IcingaConfigRenderer
         return $str;
     }
 
+    /**
+     * @codingStandardsIgnoreStart
+     */
+    public function renderAssign_Filter()
+    {
+        // @codingStandardsIgnoreEnd
+        return '    ' . AssignRenderer::forFilter(
+            Filter::fromQueryString($this->assign_filter)
+        )->renderAssign();
+    }
+
     public function toLegacyConfigString()
     {
         $str = implode(array(



More information about the icinga-checkins mailing list