diff options
-rw-r--r-- | Makefile | 5 | ||||
-rw-r--r-- | app/Controller/Gantt.php | 1 | ||||
-rw-r--r-- | app/Controller/Taskcreation.php | 1 | ||||
-rw-r--r-- | app/Controller/Taskmodification.php | 1 | ||||
-rw-r--r-- | app/ServiceProvider/GroupProvider.php | 5 | ||||
-rw-r--r-- | app/Template/user/sidebar.php | 17 | ||||
-rw-r--r-- | app/constants.php | 3 |
7 files changed, 26 insertions, 7 deletions
@@ -88,6 +88,11 @@ test-archive: @ rm -rf ${BUILD_DIR}/kanboard/.*.yml @ rm -rf ${BUILD_DIR}/kanboard/*.md @ rm -rf ${BUILD_DIR}/kanboard/*.markdown + @ rm -rf ${BUILD_DIR}/kanboard/Dockerfile + @ rm -rf ${BUILD_DIR}/kanboard/.docker + @ rm -rf ${BUILD_DIR}/kanboard/Vagrantfile + @ rm -rf ${BUILD_DIR}/kanboard/app.json + @ rm -rf ${BUILD_DIR}/kanboard/plugins/.gitignore @ cd ${BUILD_DIR}/kanboard && find ./vendor -name notes -type d -exec rm -rf {} +; @ cd ${BUILD_DIR}/kanboard && find ./vendor -name test -type d -exec rm -rf {} +; @ cd ${BUILD_DIR}/kanboard && find ./vendor -name tests -type d -exec rm -rf {} +; diff --git a/app/Controller/Gantt.php b/app/Controller/Gantt.php index 2d1edc08..5dbd1243 100644 --- a/app/Controller/Gantt.php +++ b/app/Controller/Gantt.php @@ -108,6 +108,7 @@ class Gantt extends Base ); $values = $this->hook->merge('controller:task:form:default', $values, array('default_values' => $values)); + $values = $this->hook->merge('controller:gantt:task:form:default', $values, array('default_values' => $values)); $this->response->html($this->template->render('gantt/task_creation', array( 'project' => $project, diff --git a/app/Controller/Taskcreation.php b/app/Controller/Taskcreation.php index e661587c..f1ac7272 100644 --- a/app/Controller/Taskcreation.php +++ b/app/Controller/Taskcreation.php @@ -29,6 +29,7 @@ class Taskcreation extends Base ); $values = $this->hook->merge('controller:task:form:default', $values, array('default_values' => $values)); + $values = $this->hook->merge('controller:task-creation:form:default', $values, array('default_values' => $values)); } $this->response->html($this->template->render('task_creation/form', array( diff --git a/app/Controller/Taskmodification.php b/app/Controller/Taskmodification.php index a321322d..306d34c0 100644 --- a/app/Controller/Taskmodification.php +++ b/app/Controller/Taskmodification.php @@ -80,6 +80,7 @@ class Taskmodification extends Base if (empty($values)) { $values = $task; $values = $this->hook->merge('controller:task:form:default', $values, array('default_values' => $values)); + $values = $this->hook->merge('controller:task-modification:form:default', $values, array('default_values' => $values)); } $values = $this->dateParser->format($values, array('date_due'), $this->config->get('application_date_format', 'm/d/Y')); diff --git a/app/ServiceProvider/GroupProvider.php b/app/ServiceProvider/GroupProvider.php index dff4b23a..b222b218 100644 --- a/app/ServiceProvider/GroupProvider.php +++ b/app/ServiceProvider/GroupProvider.php @@ -26,7 +26,10 @@ class GroupProvider implements ServiceProviderInterface public function register(Container $container) { $container['groupManager'] = new GroupManager; - $container['groupManager']->register(new DatabaseBackendGroupProvider($container)); + + if (DB_GROUP_PROVIDER) { + $container['groupManager']->register(new DatabaseBackendGroupProvider($container)); + } if (LDAP_AUTH && LDAP_GROUP_PROVIDER) { $container['groupManager']->register(new LdapBackendGroupProvider($container)); diff --git a/app/Template/user/sidebar.php b/app/Template/user/sidebar.php index 7e367443..765a1e6e 100644 --- a/app/Template/user/sidebar.php +++ b/app/Template/user/sidebar.php @@ -1,9 +1,11 @@ <div class="sidebar"> <h2><?= t('Information') ?></h2> <ul> - <li <?= $this->app->checkMenuSelection('user', 'show') ?>> - <?= $this->url->link(t('Summary'), 'user', 'show', array('user_id' => $user['id'])) ?> - </li> + <?php if ($this->user->hasAccess('user', 'show')): ?> + <li <?= $this->app->checkMenuSelection('user', 'show') ?>> + <?= $this->url->link(t('Summary'), 'user', 'show', array('user_id' => $user['id'])) ?> + </li> + <?php endif ?> <?php if ($this->user->isAdmin()): ?> <li> <?= $this->url->link(t('User dashboard'), 'app', 'index', array('user_id' => $user['id'])) ?> @@ -30,9 +32,12 @@ <h2><?= t('Actions') ?></h2> <ul> <?php if ($this->user->isAdmin() || $this->user->isCurrentUser($user['id'])): ?> - <li <?= $this->app->checkMenuSelection('user', 'edit') ?>> - <?= $this->url->link(t('Edit profile'), 'user', 'edit', array('user_id' => $user['id'])) ?> - </li> + + <?php if ($this->user->hasAccess('user', 'edit')): ?> + <li <?= $this->app->checkMenuSelection('user', 'edit') ?>> + <?= $this->url->link(t('Edit profile'), 'user', 'edit', array('user_id' => $user['id'])) ?> + </li> + <?php endif ?> <?php if ($user['is_ldap_user'] == 0): ?> <li <?= $this->app->checkMenuSelection('user', 'password') ?>> diff --git a/app/constants.php b/app/constants.php index be9bb6a7..1740494e 100644 --- a/app/constants.php +++ b/app/constants.php @@ -23,6 +23,9 @@ defined('DB_HOSTNAME') or define('DB_HOSTNAME', 'localhost'); defined('DB_NAME') or define('DB_NAME', 'kanboard'); defined('DB_PORT') or define('DB_PORT', null); +// Database backend group provider +defined('DB_GROUP_PROVIDER') or define('DB_GROUP_PROVIDER', true); + // LDAP configuration defined('LDAP_AUTH') or define('LDAP_AUTH', false); defined('LDAP_SERVER') or define('LDAP_SERVER', ''); |