Commit Graph

2591 Commits

Author SHA1 Message Date
Alexander Klimov 9bab7c0323 Signal that resolvePath doesn't support Windows
refs #6564
2014-06-24 13:22:43 +02:00
Alexander Klimov ff87588d96 Don't let config path seem absolute where it isn't
refs #6534
2014-06-24 10:12:07 +02:00
Thomas Gelf 1385667edc js/responsiveness: respect singlecolumn layouts
Target _next now depends on current layout
2014-06-24 07:46:37 +02:00
Thomas Gelf 0604d30348 js/loader: stop pending subcontainer requests
When redrawing a container we should cancel it's subcontainers pending
requests. This also fixes stopPendingRequestsFor(), it didn't really
work before.
2014-06-24 07:01:37 +02:00
Thomas Gelf 90bb20f4c3 js/ui: add toggleDebug function 2014-06-24 06:41:57 +02:00
Thomas Gelf 473a705e2e Assign unique ids to dashlets and subcontainers
Without this we have no chance to cancel pending requests for dashlets.

fixes #6552
2014-06-24 06:40:08 +02:00
Thomas Gelf ef0963af38 js/events: ignore javascript: in links 2014-06-24 06:35:52 +02:00
Thomas Gelf 1efd1d183e GeneralForm: replace ignorant button
It makes no sense to add submit buttons without telling the form
that there is such, especially in combination with autosubmitting
elements.

refs #5967
2014-06-23 15:46:15 +02:00
Johannes Meyer c563479888 Use Icinga\Util\File instead of fopen 2014-06-23 15:02:06 +02:00
Johannes Meyer 9066a0c2fa Fix deadlock when writing to the command pipe while noone is listening 2014-06-23 15:02:06 +02:00
Johannes Meyer 2862c5667c Make Icinga\Util\File an object
Was a class with just one static function beforehand and is now a fully
object oriented alternative for how files and pipes can be handled.
PHP warnings emitted by fopen, fwrite, fread and chmod are catched
and thrown as exceptions.
2014-06-23 15:02:06 +02:00
Thomas Gelf 51c57520ad iconSubmitForm: replace with labelSubmitForm
There is no way in ZF to have an input[type=submit] with an unescaped
label ( = value). I temporarily replaced all iconSubmitForms with
inputs labelled with "X" - as all we used them for were delete
operations.
2014-06-23 14:42:26 +02:00
Matthias Jentsch 010466f8f9 Replace sizeof with count
Do not use sizeof to get the length of an array, as the function name 'sizeof'
is misleading
2014-06-23 14:19:55 +02:00
Thomas Gelf d199a8b036 CommandForm: input[type=submit] instead of button
No need for a "button" here. As they have been broken in ZF for
a long while we should better stay with input[type=submit]

fixes #5978
2014-06-23 14:10:15 +02:00
Thomas Gelf 6f19bb13b8 js/loader: ignore focus on autosubmitting elements
Autorefresh response is not rendered while your focus sits in a form.
This is not so useful for autosubmitting elements, let's ignore them.
2014-06-23 14:04:02 +02:00
Matthias Jentsch 77a9dd1e6e Throw exception on fetchDN, when no row exists
Instead of fetchDN, authentication now uses hasUser to check if the user
exists before querying the password, to prevent the exception from messing
up the whole authentication process
2014-06-23 14:02:45 +02:00
Thomas Gelf 4d42b4d2c4 ScheduleDowntimeForm: replace obsolete ::fromRequest
A serious fix would involve passing the current backend to our
command forms.
2014-06-23 13:35:58 +02:00
Thomas Gelf ba9a633b73 Web\Form: relax form submission check
We have to live with some badly designed forms right now. Some have
submit buttons but don't know about, others don't have such but link
to foreign controllers fiddling with the form and adding different
button AFTER the form got submitted - it's a mess.

Relaxing the submission check to "just check whether btn_submit has
a value" fixes most of this. However I do not consider this being a
solution for the long run.

fixes #6423
fixes #5967
refs #6540
2014-06-23 13:31:34 +02:00
Matthias Jentsch bde6e29c61 Display a message instead of empty service matrix
refs #6535
2014-06-23 12:24:27 +02:00
Thomas Gelf 0efd44e1b0 CommandForm: don't clear class
autosubmit class got cleared for no reason after enabling autosubmission.
Please note that the fact that their submission leads to a new form is
another issue.

fixes #6540
2014-06-23 11:27:06 +02:00
Thomas Gelf a1acd52ad9 SearchController: disable autorefresh
Makes no sense as search dashlets refresh themselves.

refs #6536
2014-06-23 10:50:55 +02:00
Thomas Gelf ea44de8698 ActionController/translate: detect domain only once 2014-06-22 20:09:23 +02:00
Thomas Gelf 3fc1205175 AuthenticationController: use Auth() helper function 2014-06-22 20:08:55 +02:00
Thomas Gelf 23ed744747 params/_render: replace it everywhere
Cleaning up controllers and JS, using headers only and respecting
history.
2014-06-22 20:07:44 +02:00
Thomas Gelf aded901aa5 js/loader: reload CSS BEFORE redirecting 2014-06-22 20:01:10 +02:00
Thomas Gelf 41b8b8cf31 js/loader: remove history-related noisy log entry 2014-06-22 19:58:58 +02:00
Thomas Gelf 180a6f08f5 js/loader: notifications should survive new layout
Once replacing the whole layout we used to override notifications.
This is now fixed, they are going to be detached and re-attached
before and after re-rendering the page content.
2014-06-22 19:55:50 +02:00
Thomas Gelf 7444ab7d26 js/ui: add notice when reloading CSS 2014-06-22 19:47:15 +02:00
Thomas Gelf 61600ae2d4 ModuleActionController: fix typo 2014-06-22 19:39:54 +02:00
Thomas Gelf 997587d729 Chart\InlinePie: remove ugly default border 2014-06-22 16:38:12 +02:00
Thomas Gelf 216f0f3f55 isIframe: clean up, load less html and js
We use isIframe only when we have no JS, therefore it makes no sense
to load JS files in an iFrame. Also removed sidebar.
2014-06-22 16:30:06 +02:00
Thomas Gelf 3b84078b2f Params/_render: get rid of it, start with iframe 2014-06-22 16:18:23 +02:00
Thomas Gelf bb23d0636c ModuleActionController: use isXhr() 2014-06-22 16:04:55 +02:00
Thomas Gelf 3774eb6889 ActionController: add isXhr() method
Makes things easier as we use this a lot
2014-06-22 15:36:41 +02:00
Thomas Gelf 331d756a2a ActionController: isolate ignoreXhrBody
This function is only a workaround for broken forms not redirecting
after submission. Will hopefully be removed soon.
2014-06-22 15:33:38 +02:00
Thomas Gelf b4f8ef74fa ActionController: remove obsolete code 2014-06-22 15:20:55 +02:00
Thomas Gelf 631603aba3 ActionController: create postDispatchXhr
Moved XHR-specific stuff to a dedicated post-dispatch function
2014-06-22 15:17:28 +02:00
Thomas Gelf cf995b366b ActionController: cleanup postDispatch
Make XHR handling more readable, move module-related stuff to the
module controller
2014-06-22 15:11:08 +02:00
Thomas Gelf 7d6fd45466 Application\Web: use same request everywhere 2014-06-22 14:13:00 +02:00
Thomas Gelf dfe2448921 CSS/menu: remove text shadow from active submenu 2014-06-22 14:08:16 +02:00
Thomas Gelf 2a0e72273a ChartController: use correct ActionController
...and some code cleanup
2014-06-22 14:08:04 +02:00
Thomas Gelf de19745eb2 ActionController: move moduleInit to Module controller 2014-06-22 13:54:02 +02:00
Thomas Gelf 2cd25b7376 ActionController: if/else should be easy to read 2014-06-22 13:52:40 +02:00
Thomas Gelf b7fc0b67a8 Web/controllers: use own Request/Response objects
* introduces Icinga\Web\Response
* uses ModuleActionController where necessary
* no module translationDomain voodoo in base ActionController
2014-06-22 13:49:21 +02:00
Thomas Gelf ef5e1b54fd Web\Window: fix it's usage, add helper function
Improved window handling, fixed controllers using it.
2014-06-22 13:21:21 +02:00
Thomas Gelf b350e3640d Web\Window: move window handle to dedicated class
One more step in cleaning up our ActionController
2014-06-22 13:01:48 +02:00
Thomas Gelf d69a6d1640 ActionController: remove getRequestUrl
Thie removes complexity and makes redirection to login less error-
prone.
2014-06-22 12:23:34 +02:00
Thomas Gelf 9608d8254d ActionController: remove addModuleContainer
This method was obsolete
2014-06-22 12:09:07 +02:00
Thomas Gelf 4980b700da ActionController: __construct() as first function 2014-06-22 12:07:50 +02:00
Thomas Gelf a4955df1a9 controller->Auth(): one more lazy-loading helper
Not sure about the capital A, but doesn't look so bad - and similar
to Config().
2014-06-22 12:06:09 +02:00