4217 Commits

Author SHA1 Message Date
Eric Lippmann
a68ccecb28 Revert "Do not use htmlspecialchars in widgets"
This reverts commit 2ff43abcf5860f4002d4fbb2aee930b22ab93ea6.

`Widget::escape()' does not exist. But `Widget::view()::espcae()' does.
2014-07-23 12:28:04 +02:00
Alexander Klimov
2ff43abcf5 Do not use htmlspecialchars in widgets
refs #6759
2014-07-23 12:12:05 +02:00
Johannes Meyer
8b2cc3a558 Do not consider <button type=submit> when checking form completion
refs #5525
2014-07-23 10:58:45 +02:00
Johannes Meyer
0bf0213547 Rename Form::addElement to Form::createElement
Since we are using mainly createElement and addElement is only an alias for
createElement if no object is passed our changes to addElement can safely
be moved to createElement.

refs #5525
2014-07-23 10:57:46 +02:00
Johannes Meyer
25c9ee567d Add missing use statement for Zend_View_Abstract 2014-07-23 10:54:22 +02:00
Eric Lippmann
e005333806 Merge branch 'master' into feature/display-documentation-4820 2014-07-22 12:25:58 +02:00
Matthias Jentsch
0eaaaf2f29 Make bar charts thicker 2014-07-22 11:32:52 +02:00
Matthias Jentsch
4b8bb99fa1 Fix svg text rotation in firefox
Use the SVG transform attribute instead of the writing-mode attribute to support firefox.
2014-07-22 11:26:35 +02:00
Matthias Jentsch
0a500efd8a Determine the max value in LinearUnit dynamically
The range between min and max should always be divisable by the amount of
ticks, to ensure that the vertical lines are always at a full discrete value.

fixes #6769
2014-07-21 17:21:54 +02:00
Johannes Meyer
75e09f2c69 Do not consider submit buttons when checking form completion
refs #5525
2014-07-21 15:25:00 +02:00
Alexander Klimov
cebd71b2ff Fix "Fatal error: Interface 'Icinga\Data\DatasourceInterface' not found in Icinga\Protocol\File\Reader"
fixes #6722
2014-07-21 14:14:13 +02:00
Alexander Klimov
c5ecbf250d lib: add FileReaderException for file reader specific errors
refs #6722
2014-07-21 14:11:08 +02:00
Alexander Klimov
6df7be7ee5 File/Query: Fix applyFilter' and order' not matching SimpleQuery's interfaces
refs #6722
2014-07-21 14:09:40 +02:00
Matthias Jentsch
091ddbe552 Partiall revert bfc54b7e
Refactor Url->getParams() to return an instance of UrlParam instead of an array.

fixes #6760
2014-07-21 09:22:19 +02:00
Johannes Meyer
f5ac592645 Do not consider disabled elements when checking form completion
Values of disabled inputs are not sent by browsers.

refs #5525
2014-07-21 08:57:41 +02:00
Alexander Klimov
5ea02b41ea Optimize variable names and positions, cast array direct to object 2014-07-18 17:35:24 +02:00
Thomas Gelf
2a204897b4 DbQuery: improve method description
Not English mine this was, copy paste did I ;)
2014-07-18 16:48:52 +02:00
Thomas Gelf
209894d857 DbQuery: add dummy isTimestamp function
Not the best solution, but helps for now.

fixes #6675
2014-07-18 16:35:29 +02:00
Johannes Meyer
f4ff2c90f2 It's a form's responsibility how its submit button should look like
refs #5525
2014-07-18 09:54:36 +02:00
Johannes Meyer
6ac471c598 Also mention the viewscript functionality of Form::loadDefaultDecorators()
refs #5525
2014-07-18 09:52:50 +02:00
Johannes Meyer
8f0b9899a3 We cannot know what kind of data is passed to Form::isValid()
refs #5525
2014-07-18 09:52:05 +02:00
Johannes Meyer
78a6175acc Make form creation lazy and implement the new validation mechanism
Form creation must not depend on specific function calls. If a forms' elements are required and missing, create them. Form::isValid() must be
able to determine whether a form can be processed or not without to rely
on a particular button value.

refs #5525
2014-07-18 09:51:15 +02:00
Johannes Meyer
37fd3deb67 Rename initCsrfToken to addCsrfToken and move it upwards
Form::addCsrfToken() should be public and fluent to ensure more
flexibility.

refs #5525
2014-07-18 09:43:03 +02:00
Johannes Meyer
58188c5cc1 We only want to rely on Form::isValid() when about to process forms
As the new auto-submission implementation does not depend on whether
a submit button was pressed or not we need another way to determine
whether a form should be processed.

refs #5525
2014-07-18 09:33:09 +02:00
Johannes Meyer
802c095bf8 Configuration values need to be inserted to forms explicitly
It's the controllers' responsibility to ensure that forms are populated with
configuration values on GET requests.

refs #5525
2014-07-18 09:27:10 +02:00
Johannes Meyer
21cd503ee7 Form buttons need to be added explicitly
We either demand the user to add a submit button or provide a implicit
function call to be implemented by him, adding additional elements once
the form gets rendered.

refs #5525
2014-07-18 09:24:49 +02:00
Johannes Meyer
47ae4d79dc Forms do not need a special title property
As our upcoming wizard has no menu and our tabs are hardcoded we do not
need a special "title" property anymore.

refs #5525
2014-07-18 09:21:11 +02:00
Johannes Meyer
1de2d0c14f Merge branch 'master' into bugfix/rebuild-form-builder-5525
Conflicts:
	application/forms/Authentication/LoginForm.php
	library/Icinga/Test/BaseTestCase.php
	library/Icinga/Web/Form.php
	library/Icinga/Web/Form/Decorator/BootstrapForm.php
2014-07-17 13:15:42 +02:00
Matthias Jentsch
bfc54b7e32 Fix array conversion of the Dashboard and its Components
Do not omit the parameters when converting the dashboard components to
an array. Add an array conversion to the UrlParams class.

refs #6691
2014-07-16 17:31:01 +02:00
Johannes Meyer
5c507d5d91 Fix notice that the session has been already started after retrieving its id 2014-07-16 15:39:40 +02:00
Johannes Meyer
eb977b7a55 Fix wrong variable assignment causing preferred languages not being set 2014-07-16 15:17:14 +02:00
Johannes Meyer
e5fdf78c98 Fix testing errors due to accessing the session id by using our container 2014-07-16 10:18:00 +02:00
Johannes Meyer
e6dee9fe89 Protect login against CSRF
refs #5626
2014-07-16 09:55:23 +02:00
Johannes Meyer
b40027b6c7 Purge session when logging out
fixes #6739
2014-07-16 09:55:22 +02:00
Johannes Meyer
19f05256a0 Only call session_start() when reading from session
fixes #6383
2014-07-16 09:55:22 +02:00
Johannes Meyer
c7c2ad3790 Improve preference changeset calculation
The calculation is still subject to the concrete writer implementation as its
parent Icinga\User\Preferences\PreferencesStore is only an abstraction
layer without any knowledge how the data is actually stored so it is not able
to determine how to handle differences.

fixes #6220
2014-07-15 14:54:57 +02:00
Johannes Meyer
3105c2059e Remove license headers from all files
refs #6309
2014-07-15 13:43:52 +02:00
Johannes Meyer
e567ad67c5 Display statehistory summary vertically
fixes #6636
2014-07-14 15:26:35 +02:00
Eric Lippmann
906c132dc0 Merge branch 'master' into feature/display-documentation-4820 2014-07-11 16:05:09 +02:00
Johannes Meyer
ab410de615 Make Icinga\Logger\Writer\FileWriter output more useful error messages
fixes #6464
2014-07-10 16:40:36 +02:00
Johannes Meyer
0dce204651 Refactor Icinga\Web\Form
We eagerly waited badly for a new approach to build forms, so here it is.
Should be the best compromise between the Zend_Form functionality and
our requirements regarding automatic submits.

refs #5525
2014-07-10 11:13:45 +02:00
Johannes Meyer
1a1263d9d8 Rename Icinga\Web\Form\Decorator\BootstrapForm
We do not use bootstrap anymore but do not want the default Zend
decorators either so this decorator got a more common name.

refs #5525
2014-07-10 11:09:48 +02:00
Matthias Jentsch
3ed67c9af6 Determine the scale factor correctly
Fix error in the logic of the context renderer, that lead to a wrong scale factor
when the width was bigger than the height
2014-07-09 18:13:40 +02:00
Matthias Jentsch
8d697a3d8e Fix coding style 2014-07-09 18:13:40 +02:00
Matthias Jentsch
ec3bafa026 Fix number formatting in chart classes
Use explizit number formatting instead of implicit type conversions when
rendering SVGs, to prevent a change of the locale from breaking the charts.

fixes #6585
2014-07-09 18:13:40 +02:00
Johannes Meyer
0fc2604af3 Use Icinga\Data\Db\DbConnection instead of Zend_Db_Select directly
fixes #6218
2014-07-09 10:41:54 +02:00
Thomas Gelf
49c679fe0f FilterEditor: hide "add" links
They where there to show how this should look like. Removed for now as
they are not implemented yet.

refs #6668
2014-07-08 17:21:36 +02:00
Johannes Meyer
bb2c85f90b Remove forgotten ActionController::requiresConfig() call
Should have been reverted by last commit but was not.
2014-07-07 16:12:26 +02:00
Johannes Meyer
82d2f5ac9b Revert "Merge branch 'feature/install-wizard-6136'"
This reverts commit 88d4262e7ca17430eb2385715f402becfc653797, reversing
changes made to 6fae333048d0ef2b95f52c8113143c79e10c4e50.

Conflicts:

	application/controllers/InstallController.php
	library/Icinga/Web/Controller/ActionController.php
2014-07-07 15:09:03 +02:00
Johannes Meyer
b3cb29d804 Make Icinga\Util\Tranlsator not only return locale codes with encodings
refs #6602
2014-07-07 09:09:22 +02:00