Commit Graph

43 Commits

Author SHA1 Message Date
Thomas Gelf 2b61a0e7c4 CompatController: use default exception 2018-10-01 11:59:02 +02:00
Thomas Gelf 6d139752fe QueryBasedTables: make search() public 2018-09-04 11:08:37 +02:00
Thomas Gelf b790c7410a Pagination: do not count twice for the same query 2018-09-04 11:08:37 +02:00
Thomas Gelf 14a3039f65 controllers, libs: less noise from exceptions 2018-08-08 10:07:39 +02:00
Thomas Gelf 71ad8553cf ComatController: add missing use 2018-08-06 13:59:57 +02:00
Thomas Gelf 33ff71ce94 Url: hide Icinga Exceptions 2018-06-14 10:14:08 +02:00
Thomas Gelf 0026e7fd61 ipl/Web: avoid Icinga Exceptions 2018-06-14 08:51:40 +02:00
Thomas Gelf 31a6ab0cf2 IcingaHostServiceTable, others: cleanup, fix...
...blacklist-styling
2018-05-30 00:45:08 +02:00
Thomas Gelf 319b000407 ipl: phpdoc, cleanup 2018-05-06 09:08:37 +02:00
Thomas Gelf df7c77a0f6 ipl-related fixes 2018-05-05 18:29:17 +02:00
Thomas Gelf 988319dcf6 ipl-related: use HtmlDocument instead of Html 2018-05-05 01:25:24 +02:00
Thomas Gelf 955695682d Use BaseHtmlElement and more 2018-05-05 01:11:55 +02:00
Thomas Gelf 403df971a1 dipl: align with ipl, first step 2018-05-05 00:18:45 +02:00
Thomas Gelf be0d41459f ipl: code cleanup 2018-05-04 22:55:24 +02:00
David McBride 8e28f7f9c8 Avoid failing when attempting to render NULL column-set
PHP 7.2 is stricter about invoking count() with parameters which
are not countable:

 https://secure.php.net/manual/en/migration72.incompatible.php

This case is triggered in QueryBasedTable, for example when reviewing
the Activity Log:

 count(): Parameter must be an array or an object that implements Countable (QueryBasedTable.php:115)
 #0 [internal function]: Icinga\Application\ApplicationBootstrap->Icinga\Application\{closure}(2, 'count(): Parame...', '/usr/share/icin...', 115, Array)
 #1 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Web/Table/QueryBasedTable.php(115): count(NULL)
 #2 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Html/BaseElement.php(133): dipl\Web\Table\QueryBasedTable->renderContent()
 #3 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Html/Html.php(171): dipl\Html\BaseElement->render()
 #4 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Html/BaseElement.php(105): dipl\Html\Html->render()
 #5 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Html/BaseElement.php(133): dipl\Html\BaseElement->renderContent()
 #6 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Html/Html.php(259): dipl\Html\BaseElement->render()
 #7 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Zf1/SimpleViewRenderer.php(47): dipl\Html\Html->__toString()
 #8 /usr/share/icingaweb2/modules/director/library/vendor/ipl/Zf1/SimpleViewRenderer.php(66): dipl\Zf1\SimpleViewRenderer->render()
 #9 /usr/share/icingaweb2/library/vendor/Zend/Controller/Action/HelperBroker.php(272): dipl\Zf1\SimpleViewRenderer->postDispatch()
 #10 /usr/share/icingaweb2/library/vendor/Zend/Controller/Action.php(518): Zend_Controller_Action_HelperBroker->notifyPostDispatch()
 #11 /usr/share/php/Icinga/Web/Controller/Dispatcher.php(76): Zend_Controller_Action->dispatch('activitiesActio...')
 #12 /usr/share/icingaweb2/library/vendor/Zend/Controller/Front.php(937): Icinga\Web\Controller\Dispatcher->dispatch(Object(Icinga\Web\Request), Object(Icinga\Web\Response))
 #13 /usr/share/php/Icinga/Application/Web.php(389): Zend_Controller_Front->dispatch(Object(Icinga\Web\Request), Object(Icinga\Web\Response))
 #14 /usr/share/php/Icinga/Application/webrouter.php(109): Icinga\Application\Web->dispatch()
 #15 /usr/share/icingaweb2/public/index.php(4): require_once('/usr/share/php/...')
 #16 {main}

Perhaps over-simplistically, this failure can be avoided by first
checking the countability of the relevant value with isset().
2018-04-05 16:55:16 +02:00
Thomas Gelf feb80480ea QueryBasedTable: remove a superfluous empty line 2018-02-25 17:47:20 +01:00
Thomas Gelf d1e116a5a1 ipl: rename to dipl
fixes #1217
2017-10-09 15:23:27 +02:00
Thomas Gelf 8f1f3ec699 ZfQueryBasedTable: allow for ZfAdapter instances 2017-09-17 14:06:07 +02:00
Thomas Gelf 466a229041 QueryBasedTable: do not fail without paginator 2017-08-21 08:08:18 +02:00
Thomas Gelf 54c121f4a3 QueryBasedTable: add helper methods allowing...
...implementors to easily determine current "position"
2017-08-19 23:06:11 +02:00
Thomas Gelf 0dd7bcc43d ZfSortablePriority: add new table extension 2017-08-19 22:54:34 +02:00
Thomas Gelf 0e49d7beef CompatController: hints for phpcs violations...
...that are there for compat reasons
2017-08-18 16:40:49 +02:00
Thomas Gelf 374b6d4a60 NameValueTable: change method signature to not...
...switch context when used fluently
2017-08-18 00:00:00 +02:00
Thomas Gelf 4680fa5447 SimpleQueryBasedTable: add new table type...
...and move logic common with ZfQueryBasedTable to a new base class
2017-08-12 12:02:36 +02:00
Thomas Gelf 1a631b04db QuickSearch: add help/info title 2017-08-11 12:26:40 +02:00
Thomas Gelf 0e45c74a0c ipl\Controls: allow to prepend tabs 2017-07-29 00:13:43 +02:00
Thomas Gelf f89fab2a27 FilterRenderer: look up column aliases
...and allow to apply filter objects to ZfQueryBasedTable
2017-07-26 09:24:47 +02:00
Thomas Gelf b1d959a634 QuickSearch: render "around" title element 2017-07-24 08:48:59 +02:00
Thomas Gelf d33b31acae Controls: allow direct access to title element 2017-07-24 08:43:56 +02:00
Thomas Gelf 5579a927ad ZfQueryBasedTable: improve readability 2017-07-21 12:04:20 +02:00
Thomas Gelf 9dc50beee5 Controls: always prepend the title 2017-07-20 16:59:25 +02:00
Thomas Gelf 8e0235a7e1 ZfQueryBasedTable: render pagination to actions 2017-07-20 15:18:47 +02:00
Thomas Gelf 014963f96c Tables: get rid of assemble workaround 2017-07-20 14:58:23 +02:00
Thomas Gelf 270cb2f5af ZfQueryBasedTable: fix brackets 2017-07-20 11:58:55 +02:00
Thomas Gelf 406bc8bd72 NameValueTable: new ipl widget 2017-07-20 11:03:54 +02:00
Thomas Gelf cda6970594 ipl: Components are now Widgets 2017-07-20 10:19:32 +02:00
Thomas Gelf 547deb209c Paginator: allow paginatable to override default...
...limit when it already comes with a limit
2017-07-19 18:40:16 +02:00
Thomas Gelf 59881508bd ZfQueryBasedTable: allow to split on new day 2017-07-19 18:28:01 +02:00
Thomas Gelf 5938f5051a ActionBar: add setBaseTarget() helper 2017-07-14 13:21:42 +02:00
Thomas Gelf 0ea443cc84 ZfQueryBasedTable: readability 2017-07-14 13:21:42 +02:00
Thomas Gelf adf7920820 QuickSearch: get correctly encoded URL from form 2017-07-14 13:21:42 +02:00
Thomas Gelf 9845cddcb4 QureyBasedTable: move to ipl 2017-07-14 13:21:42 +02:00
Thomas Gelf e883ed70b3 ipl: add a clone and a conservative loader 2017-07-14 13:21:42 +02:00