4217 Commits

Author SHA1 Message Date
Thomas Gelf
b7521f48b9 Util\Translator: show correct language list
List was showing useless stuff such as LC_MESSAGES and no language
but the default one. We should have a look whether LC_MESSAGES is
really needed, it looks so ugly.
2014-06-25 10:31:03 +02:00
Thomas Gelf
2746b5ff9f ConfigController: switch over to new config tabs
Module configuration now takes place in module detail view and does no
longer pollute our config tabs. Modules are now able to provide a bunch
of own config tabs, we don't really care what they use them for.
2014-06-24 21:31:59 +02:00
Thomas Gelf
b38bcfc19b Widget\FilterEditor: correct expression output
Filter expressions should be filled into form fields exactly as we
expect them at parse time.

fixes #6568
2014-06-24 21:00:01 +02:00
Thomas Gelf
47b893e1ea Widget\FilterEditor: handle custom vars
There was an issue with custom vars as they made only partially part
of the column dropdown. Sorted columns and tried to beautify column
names.

fixes #6569
2014-06-24 20:57:41 +02:00
Thomas Gelf
3f9f4bb9e1 ModuleActionController: module object shortcut
This helps modules with the need to know more about themselves. No
more App -> Module Manager -> Module voodoo.
2014-06-24 20:54:39 +02:00
Thomas Gelf
13ef06c700 Modules\Module: modules should register config tabs
This allows modules to register their config tabs and provides a
convenient way to fetch a modules fully instanced config tabs.
2014-06-24 20:47:03 +02:00
Thomas Gelf
b7b99cfd67 Widget\AlertMessageBox: fix broken widget
This widget is pretty useless as the error view script can to it's
job. Interestingly nobody missed it, even the render() call was wrong.

I guess we will remove this soon, but for now it's fixed. Looks ugly,
but works.
2014-06-24 20:30:41 +02:00
Alexander Klimov
219869607d Make preferences INI path NOT be configurable
fixes #6567
2014-06-24 18:29:28 +02:00
Alexander Klimov
f2693613d1 Make preferences INI path NOT be configurable
refs #6567
2014-06-24 18:00:40 +02:00
Alexander Klimov
3e31ff65a4 Prefer dirname rather than pathinfo 2014-06-24 15:57:13 +02:00
Alexander Klimov
6daccae30e Optimize IcingaConfig::resolvePath 2014-06-24 15:45:19 +02:00
Alexander Klimov
6e4bf73c36 Compute config file paths properly
fixes #6564
fixes #6534
2014-06-24 14:54:31 +02:00
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
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
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
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
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
Thomas Gelf
ea44de8698 ActionController/translate: detect domain only once 2014-06-22 20:09:23 +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
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
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
Thomas Gelf
373e1c5ecb Web\Controller: re-introduce ModuleActionController
This will help getting rid of a couple of if/else constructs
2014-06-22 12:03:37 +02:00
Thomas Gelf
469eb3dc98 Web\Url: remove forgotten "debug" line 2014-06-22 11:59:24 +02:00
Thomas Gelf
b3cdeee35d monitoring/timeline: should benefit from new filter
Different changes have been applied:

* Allow integer unix timestamps as parameters for timestamp columns
* Remove alias-rewriting from Url class
* Remove all traces of raw_timestamp
* Use new filters
2014-06-21 03:09:40 +02:00
Thomas Gelf
78193137f0 config/modules: show metadata, improve usability
Well... I didn't want to commit this before creating single-button
forms for enabling/disabling modules. However part of this accidentally
made it through, so let's finish it.

Still some work to do, but it already looks far better like this.

refs #4095
2014-06-21 02:27:27 +02:00
Thomas Gelf
216c2ca770 Autorefresh: should work also on initial page load
fixes #6296
2014-06-21 01:54:32 +02:00
Thomas Gelf
e2f7a1054e CSV/JSON export: work with new query interfaces
NB: I do not like the fact that we have to do as follows:

  DataView->getQuery()->fetchWhatever();

Guess this is worth a few more proxy functions.
2014-06-21 00:09:11 +02:00
Thomas Gelf
c0c7a815f8 Merge remote-tracking branch 'origin/master' into feature/query-interfaces-6018 2014-06-20 19:18:38 +02:00
Thomas Gelf
a904ff51aa monitoring/eventhistory: improve query performance
This takes care of timestamp columns, modifies queries in a way not
depending on db functions, filters are passed through to subqueries
for better performance.
2014-06-20 19:14:34 +02:00