Commit Graph

2138 Commits

Author SHA1 Message Date
Alexander Fuhr 2cbcea25cb Merge branch 'feature/ido-resource-validation-9203'
fixes 
resolves 
2015-05-15 15:59:18 +02:00
Johannes Meyer 99c511eefd Limiter: Do not use a hardcoded default limit 2015-05-15 15:22:22 +02:00
Johannes Meyer 9a043386de Controller: Make setupSortControl creating a Zend_Paginator on its own
We're accessing the url GET parameters `sort' and `dir' in a controller now.

fixes 
2015-05-15 14:37:41 +02:00
Johannes Meyer fbf0ad4339 Drop interface Browsable
We're not required to handle objects of Zend_Paginator in any way, so
creating such as part of a query is not necessary since QueryAdapter
accepts any instance of QueryInterface. (gets enforced in the near future)

refs 
2015-05-15 14:37:41 +02:00
Johannes Meyer ed5f646b6f SimpleQuery: Implement interface IteratorAggregate
I'd like to foreach such.
2015-05-15 14:37:41 +02:00
Johannes Meyer e04655e8cf Controller: Apply the user chosen sort rules when in compact view as well 2015-05-15 14:37:41 +02:00
Johannes Meyer ad8903660d Revert "SortBox::handleRequest(): set query order direction to asc if it's not given"
This reverts commit 59753acece.
2015-05-15 14:37:41 +02:00
Alexander Fuhr 9f35db71bf Form: Add typed notifications to the form
refs 
2015-05-15 13:04:01 +02:00
Alexander Fuhr 1eb11625ef Add new FormNotification Decorator to render form notifications
refs 
2015-05-15 13:02:54 +02:00
Alexander A. Klimov 59753acece SortBox::handleRequest(): set query order direction to asc if it's not given 2015-05-13 14:40:40 +02:00
Johannes Meyer e9fee2dad6 Repository: Handle column name ambiguousness automatically
refs 
2015-05-13 13:27:08 +02:00
Johannes Meyer 0a387573f3 Logger: Fix substitution of exception messages 2015-05-13 10:46:34 +02:00
Johannes Meyer f93c2de6be UserGroupBackend: Disable default backend type `ini'
We're not going to support this until a proper membership implementation
exists (or is required at all).

refs 
2015-05-13 10:45:54 +02:00
Johannes Meyer 223ecab991 DbUserGroupBackend: Make it possible to handle memberships
refs 
2015-05-13 10:34:39 +02:00
Johannes Meyer 47dfcf5e1d DbUserGroupBackend: Do not use the repository abstraction internally
That's overhead which is not necessary.

refs 
2015-05-13 10:34:00 +02:00
Johannes Meyer 7d982068a5 DbRepository: Ensure that we'll work with a instance of DbConnection
refs 
2015-05-13 09:52:29 +02:00
Johannes Meyer d5d0c67d2c IniRepository: Do not handle $target as a section's name
That's bullshit.

refs 
2015-05-13 09:48:46 +02:00
Johannes Meyer 104c1c6bba DbUserBackend: Utilize Zend_Db_Select when fetching the password hash 2015-05-13 09:16:24 +02:00
Johannes Meyer 7d08dd2765 DbConnection: Adjust insert and update to support custom type definitions
This strips the custom insert and update implementataions in
DbUserBackend down so that it does not need to do such low level stuff...

refs 
2015-05-13 09:15:18 +02:00
Johannes Meyer aa466ae721 Merge branch 'master' into feature/user-and-group-management-8826 2015-05-13 08:11:59 +02:00
Alexander A. Klimov d43513dcac Controller: use Icinga\Data\Sortable 2015-05-12 16:38:31 +02:00
Johannes Meyer c91d3e52ac Merge branch 'master' into feature/user-and-group-management-8826 2015-05-12 15:39:02 +02:00
Johannes Meyer 053c9cdcb3 Repository: Check whether a column is queried from the correct table
refs 
2015-05-12 15:38:29 +02:00
Alexander A. Klimov afa0dc0956 SortBox::handleRequest(): check whether $this->query !== null
refs 
2015-05-12 10:29:50 +02:00
Alexander A. Klimov e1c3d23d12 Icinga\Web\Controller::setupSortControl(): set query on the newly created SortBox (if given)
refs 
2015-05-11 16:28:23 +02:00
Alexander A. Klimov 32659647b9 Implement Icinga\Web\Widget\SortBox::handleRequest()
refs 
2015-05-11 16:09:20 +02:00
Johannes Meyer 44bbd93cbc DbUserBackend: Provide a custom insert and update implementation
As we're transmitting password hashes which may contain special chars
and the like, we need to utilize prepared statements with explicit types.

refs 
2015-05-11 16:00:24 +02:00
Alexander A. Klimov 17ebe07e57 Implement Icinga\Web\Widget\SortBox::setQuery()
refs 
2015-05-11 15:37:00 +02:00
Alexander A. Klimov 295254d1d5 Rename Icinga\Web\Widget\SortBox::applyRequest() to ...::setRequest()
refs 
2015-05-11 14:07:57 +02:00
Alexander A. Klimov 152c6a8f7f Merge Monitoring_ListController::hasBetterUrl() into Icinga\Web\Controller::init()
refs 
2015-05-11 13:36:58 +02:00
Matthias Jentsch 25f397042b Merge branch 'master' into feature/improve-multi-select-view-8565
Conflicts:
	modules/monitoring/application/controllers/HostsController.php
	modules/monitoring/application/controllers/ServicesController.php
	modules/monitoring/application/views/scripts/hosts/show.phtml
	modules/monitoring/application/views/scripts/list/hosts.phtml
	modules/monitoring/application/views/scripts/partials/host/objects-header.phtml
	modules/monitoring/application/views/scripts/partials/service/objects-header.phtml
	modules/monitoring/application/views/scripts/services/show.phtml
	modules/monitoring/public/css/module.less
	public/js/icinga/behavior/tooltip.js
2015-05-11 13:28:43 +02:00
Johannes Meyer b3957c556b DbUserGroupBackend: Properly utilize the insert and update capability
refs 
2015-05-11 13:28:01 +02:00
Johannes Meyer ca166b0175 DbRepository: Add insert, update and delete capabilities
refs 
2015-05-11 13:26:41 +02:00
Johannes Meyer 3aaa6d39a1 DbConnection: Make it possible to insert, update and delete table rows
refs 
2015-05-11 13:25:50 +02:00
Johannes Meyer 30bc1db6ee IniRepository: There is no need to fetch the results using a query
Icinga\Application\Config is iterable.

refs 
2015-05-11 07:46:36 +02:00
Johannes Meyer f1c82fc318 IniUserGroupBackend: Convert timestamps and arrays...
...to formatted datetime strings and comma separated strings respectively

refs 
2015-05-08 15:28:10 +02:00
Johannes Meyer 59ec11f047 IniUserGroupBackend: Extend IniRepository
We are now able to insert, update and delete user groups stored in INI files

refs 
2015-05-08 15:26:35 +02:00
Johannes Meyer 6ef4bbe210 Introduce class IniRepository
refs 
2015-05-08 15:22:51 +02:00
Johannes Meyer 8690056e1c Introduce interface Updatable
refs 
2015-05-08 15:18:56 +02:00
Johannes Meyer 2c1fac9da8 Introduce interface Reducible
refs 
2015-05-08 15:18:42 +02:00
Johannes Meyer 84f20ecb5f Introduce interface Extensible
refs 
2015-05-08 15:18:28 +02:00
Johannes Meyer 12ff708ac0 Introduce exception StatementException
refs 
2015-05-08 15:17:36 +02:00
Johannes Meyer 938da806ca Repository: Recurse a filter in the repository instead of in the query
This allows to recurse and adjust a filter outside the query context as well

refs 
2015-05-08 12:15:02 +02:00
Johannes Meyer f383ddd00a Repository: Add support for client side value conversion
refs 
2015-05-07 14:49:13 +02:00
Johannes Meyer f83d16acb2 RepositoryQuery: Do not lose the repository context during pagination
refs 
2015-05-07 14:45:47 +02:00
Johannes Meyer eac5e398be Repository: Initialize the internal column and table maps lazily as well
refs 
2015-05-07 09:04:50 +02:00
Johannes Meyer 99be358714 Repository: Make it possible to initialize column properties lazily
refs 
2015-05-07 08:28:32 +02:00
Johannes Meyer ba4330de43 Repository: We do not overwrite properties, we're initializing them
refs 
2015-05-07 08:03:07 +02:00
Johannes Meyer 4d83b2f93d Authentication\Manager: Fix invalid class path in use statement
refs 
2015-05-06 12:18:57 +02:00
Johannes Meyer 16a7b010bc SimpleQuery: Ignore limit and offset when counting 2015-05-06 10:41:39 +02:00
Johannes Meyer 4044e56a03 LdapUserBackend: Provide filter column `user'
refs 
2015-05-06 10:27:26 +02:00
Johannes Meyer 108f55128f Ldap\Query: Fix access of a filter's expression 2015-05-06 10:24:50 +02:00
Johannes Meyer cfa9176192 ArrayDatasource: use array_shift in fetchRow() instead of index access
Since associative arrays are supported, the numeric index 0 might not be
the first entry in the result.
2015-05-06 10:10:29 +02:00
Johannes Meyer 7b2ed3bef7 ArrayDatasource: Create a new result when counting
There is usually no limit and offset when a query is going to be counted
so the cached result must not be used.
2015-05-06 10:08:07 +02:00
Johannes Meyer f2ad2838f4 ArrayDatasource: Apply a query's limit and offset when creating the result 2015-05-06 09:39:43 +02:00
Johannes Meyer d63381c002 ArrayDatasource: Add missing and fix existing documentation 2015-05-06 09:12:48 +02:00
Johannes Meyer 9c799dca22 IniUserGroupBackend: Automatically set section names on column `name'
refs 
2015-05-06 08:41:54 +02:00
Johannes Meyer b1cbc1422b ArrayDatasource: Add support for associative arrays
Keys are now preserved in case a non-numeric one is found. By using
setKeyColumn() it is now also possible to map such a key to a specific
column of a row generated by createResult().
2015-05-06 08:40:02 +02:00
Johannes Meyer f1f1710f47 Config: Add method getConfigObject to access the internal ConfigObject 2015-05-06 08:07:42 +02:00
Johannes Meyer 89029308ef IniUserGroupBackend: Extend Repository and implement UserGroupBackendInterface
Note that it was necessary to change the structure of ini files providing
the membership information. They need to be structured like our db
table rows now.

refs 
2015-05-05 15:24:18 +02:00
Johannes Meyer 5cc7f26728 ConfigObject: Extend ArrayDatasource
This makes it possible to use a ini file as repository!!!1
One thing is missing: Section names are currently ignored and should be
mapped to a virtual column.

refs 
2015-05-05 15:21:34 +02:00
Alexander Fuhr be696e5adf LogFileIterator: Fix missing closing bracket 2015-05-05 12:50:35 +02:00
Alexander Fuhr 612fefba9c Fix the permission wildcards assertion
fixes 
2015-05-05 12:36:26 +02:00
Johannes Meyer de68d78938 DbUserGroupBackend: Add case insensitive filter columns `group' and `parent'
refs 
2015-05-05 09:34:49 +02:00
Johannes Meyer 37e47f0d3f DbUserBackend: Add case insensitive filter column `user'
refs 
2015-05-05 09:34:23 +02:00
Johannes Meyer 58233b0072 DbUserGroupBackend: Extend DbRepository and implement UserGroupBackendInterface
refs 
2015-05-05 09:23:29 +02:00
Johannes Meyer b1454c199a Introduce interface UserGroupBackendInterface
refs 
2015-05-05 08:27:11 +02:00
Johannes Meyer 7b2fc1ba41 Make class UserGroupBackend being just a factory for user group backends
refs 
2015-05-05 08:26:38 +02:00
Johannes Meyer bd136d39f4 SimpleQuery: Make compare() alias aware
refs 
refs 
2015-05-05 07:31:50 +02:00
Johannes Meyer d71df6a9b8 Revert "SimpleQuery: Make compare() alias aware"
This reverts commit 6612e4c1ae.
2015-05-05 07:30:42 +02:00
Johannes Meyer d171dd2ec9 Introduce controller UserController
Still only able to list users, more to follow...

refs 
2015-05-04 17:04:50 +02:00
Johannes Meyer d0a353c3da Ldap\Connection: Fix result counting
Missed to adjust this once I refactored the query execution..

refs 
2015-05-04 16:24:17 +02:00
Johannes Meyer 3e8ef5cc0f Ldap\Query: Quick fix for naive filter support
Since this will ignore any logical clauses and operators it must be
considered a quick fix and be dropped once real filter support exists.

refs 
2015-05-04 16:17:14 +02:00
Johannes Meyer f9089c3e0c RepositoryQuery: Ensure compatibility with the FilterEditor widget
refs 
2015-05-04 15:56:58 +02:00
Johannes Meyer 842b043f7f LdapUserBackend: Use is_active as well as a default sort column
refs 
2015-05-04 15:56:13 +02:00
Johannes Meyer b86a0024c3 DbUserBackend: Use is_active as well as a default sort column
refs 
2015-05-04 15:55:36 +02:00
Johannes Meyer c441117324 LdapUserBackend: Extend Repository and implement UserBackendInterface
refs 
2015-05-04 12:18:25 +02:00
Johannes Meyer e74194c18e ExternalBackend: Implement UserBackendInterface
refs 
2015-05-04 12:15:50 +02:00
Johannes Meyer 99ac0b78ea DbUserBackend: Extend DbRepository and implement UserBackendInterface
refs 
2015-05-04 12:15:05 +02:00
Johannes Meyer 7b41fc020a AuthChain: Yield UserBackendInterface instead of UserBackend
refs 
2015-05-04 11:44:41 +02:00
Johannes Meyer 1824eb9c3b Make class UserBackend being just a factory for user backends
refs 
2015-05-04 11:43:53 +02:00
Johannes Meyer 68657c02ee Introduce interface Icinga\Authentication\User\UserBackendInterface
refs 
2015-05-04 11:40:17 +02:00
Johannes Meyer 870e75c99c Introduce class Icinga\Repository\DbRepository
refs 
2015-05-04 11:39:12 +02:00
Johannes Meyer fa1906ee7d Introduce class Icinga\Repository\RepositoryQuery
refs 
2015-05-04 11:38:21 +02:00
Johannes Meyer 3b93b84ecf Introduce class Icinga\Repository\Repository
refs 
2015-05-04 11:37:48 +02:00
Johannes Meyer 7b7a7c9299 Ldap\Connection: Add proper order support
Will now utilize SimpleQuery::compare() to provide support for multiple
order columns.

refs 
refs 
2015-05-04 11:36:38 +02:00
Johannes Meyer 6612e4c1ae SimpleQuery: Make compare() alias aware
refs 
refs 
2015-05-04 11:34:39 +02:00
Johannes Meyer 664017573f Ldap\Connection: Add query alias support
refs 
2015-05-04 11:32:03 +02:00
Johannes Meyer 5baa0590b1 Ldap\Query: Extend SimpleQuery and add missing documentation
refs 
refs 
2015-05-04 11:26:27 +02:00
Johannes Meyer 99213432f5 Ldap\Connection: Rename fetchDN() to fetchDn()
We're using CamelCase names for methods.
2015-05-04 11:16:16 +02:00
Johannes Meyer 7178026b8b Ldap\Connection: Implement interface Selectable
refs 
2015-05-04 11:15:20 +02:00
Johannes Meyer ecd059dec5 DbConnection: select() returns a DbQuery, not a Query 2015-05-04 11:13:38 +02:00
Johannes Meyer e7789ed640 SimpleQuery: Rename unused property `table' to `target'
`target' is already in use, but was not declared. `table' was declared but not
used anywhere. So `table' is now `target'.
2015-05-04 11:12:43 +02:00
Johannes Meyer ca5ef2da2b Merge Queryable into QueryInterface
A *Query*Interface describes an object as being queryable, now.

refs 
2015-05-04 11:07:50 +02:00
Alexander A. Klimov ab0b478e4f Icinga\Web\Widget\Tabextension\DashboardAction::apply(): translate label "Add To Dashboard" 2015-04-30 17:49:42 +02:00
Alexander A. Klimov ffe23a184f Don't display "Add To Dashboard" on the dashboard
resolves 
2015-04-30 17:47:23 +02:00
Alexander Fuhr 7f28c0a237 Implement ProblemMenuItemRenderer
refs # 4139
2015-04-30 16:06:05 +02:00
Johannes Meyer d09ea2845d Merge branch 'master' into feature/user-and-group-management-8826 2015-04-30 15:20:40 +02:00
Johannes Meyer 3da144f199 Revert "Sort LDAP user list"
This reverts commit d4dc0177c0.
2015-04-28 15:57:33 +02:00
Alexander A. Klimov 7c0be30def Handle and display multiline log messages correctly 2015-04-24 17:36:49 +02:00