diff options
Diffstat (limited to 'app/Template/project')
-rw-r--r-- | app/Template/project/edit.php | 10 | ||||
-rw-r--r-- | app/Template/project/index.php | 19 | ||||
-rw-r--r-- | app/Template/project/roles.php | 7 | ||||
-rw-r--r-- | app/Template/project/show.php | 4 | ||||
-rw-r--r-- | app/Template/project/sidebar.php | 6 |
5 files changed, 25 insertions, 21 deletions
diff --git a/app/Template/project/edit.php b/app/Template/project/edit.php index 188107d1..3a273f32 100644 --- a/app/Template/project/edit.php +++ b/app/Template/project/edit.php @@ -11,18 +11,26 @@ <?= $this->form->label(t('Identifier'), 'identifier') ?> <?= $this->form->text('identifier', $values, $errors, array('maxlength="50"')) ?> - <p class="form-help"><?= t('The project identifier is an optional alphanumeric code used to identify your project.') ?></p> + <p class="form-help"><?= t('The project identifier is optional and must be alphanumeric, example: MYPROJECT.') ?></p> + <?= $this->form->label(t('Project owner'), 'owner_id') ?> + <?= $this->form->select('owner_id', $owners, $values, $errors) ?> + + <hr> <?= $this->form->label(t('Start date'), 'start_date') ?> <?= $this->form->text('start_date', $values, $errors, array('maxlength="10"'), 'form-date') ?> <?= $this->form->label(t('End date'), 'end_date') ?> <?= $this->form->text('end_date', $values, $errors, array('maxlength="10"'), 'form-date') ?> + <p class="form-help"><?= t('Those dates are useful for the project Gantt chart.') ?></p> <?php if ($this->user->hasProjectAccess('project', 'create', $project['id'])): ?> + <hr> <?= $this->form->checkbox('is_private', t('Private project'), 1, $project['is_private'] == 1) ?> + <p class="form-help"><?= t('Private projects do not have users and groups management.') ?></p> <?php endif ?> + <hr> <?= $this->form->label(t('Description'), 'description') ?> <div class="form-tabs"> diff --git a/app/Template/project/index.php b/app/Template/project/index.php index c7d74f8b..3d2a33ea 100644 --- a/app/Template/project/index.php +++ b/app/Template/project/index.php @@ -23,9 +23,9 @@ <th class="column-15"><?= $paginator->order(t('Project'), 'name') ?></th> <th class="column-8"><?= $paginator->order(t('Start date'), 'start_date') ?></th> <th class="column-8"><?= $paginator->order(t('End date'), 'end_date') ?></th> + <th class="column-15"><?= $paginator->order(t('Owner'), 'owner_id') ?></th> <?php if ($this->user->hasAccess('projectuser', 'managers')): ?> - <th class="column-12"><?= t('Managers') ?></th> - <th class="column-12"><?= t('Members') ?></th> + <th class="column-10"><?= t('Users') ?></th> <?php endif ?> <th><?= t('Columns') ?></th> </tr> @@ -66,16 +66,15 @@ <td> <?= $project['end_date'] ?> </td> + <td> + <?php if ($project['owner_id'] > 0): ?> + <?= $this->e($project['owner_name'] ?: $project['owner_username']) ?> + <?php endif ?> + </td> <?php if ($this->user->hasAccess('projectuser', 'managers')): ?> <td> - <?= $this->render('project/roles', array('roles' => $project, 'role' => \Kanboard\Core\Security\Role::PROJECT_MANAGER)) ?> - </td> - <td> - <?php if ($project['is_everybody_allowed'] == 1): ?> - <?= t('Everybody') ?> - <?php else: ?> - <?= $this->render('project/roles', array('roles' => $project, 'role' => \Kanboard\Core\Security\Role::PROJECT_MEMBER)) ?> - <?php endif ?> + <i class="fa fa-users fa-fw"></i> + <a href="#" class="tooltip" title="<?= t('Members') ?>" data-href="<?= $this->url->href('Projectuser', 'users', array('project_id' => $project['id'])) ?>"><?= t('Members') ?></a> </td> <?php endif ?> <td class="dashboard-project-stats"> diff --git a/app/Template/project/roles.php b/app/Template/project/roles.php deleted file mode 100644 index d4cd43cb..00000000 --- a/app/Template/project/roles.php +++ /dev/null @@ -1,7 +0,0 @@ -<?php if (! empty($roles[$role])): ?> - <ul class="no-bullet"> - <?php foreach ($roles[$role] as $user_id => $user_name): ?> - <li><?= $this->url->link($this->e($user_name), 'projectuser', 'opens', array('user_id' => $user_id)) ?></li> - <?php endforeach ?> - </ul> -<?php endif ?>
\ No newline at end of file diff --git a/app/Template/project/show.php b/app/Template/project/show.php index 5a65a26e..5f1aefc1 100644 --- a/app/Template/project/show.php +++ b/app/Template/project/show.php @@ -4,6 +4,10 @@ <ul class="listing"> <li><strong><?= $project['is_active'] ? t('Active') : t('Inactive') ?></strong></li> + <?php if ($project['owner_id'] > 0): ?> + <li><?= t('Project owner: ') ?><strong><?= $this->e($project['owner_name'] ?: $project['owner_username']) ?></strong></li> + <?php endif ?> + <?php if ($project['is_private']): ?> <li><i class="fa fa-lock"></i> <?= t('This project is private') ?></li> <?php endif ?> diff --git a/app/Template/project/sidebar.php b/app/Template/project/sidebar.php index 025c410d..e798195d 100644 --- a/app/Template/project/sidebar.php +++ b/app/Template/project/sidebar.php @@ -11,6 +11,9 @@ <?php endif ?> <?php if ($this->user->hasProjectAccess('project', 'edit', $project['id'])): ?> + <li <?= $this->app->checkMenuSelection('project', 'edit') ?>> + <?= $this->url->link(t('Edit project'), 'project', 'edit', array('project_id' => $project['id'])) ?> + </li> <li <?= $this->app->checkMenuSelection('project', 'share') ?>> <?= $this->url->link(t('Public access'), 'project', 'share', array('project_id' => $project['id'])) ?> </li> @@ -20,9 +23,6 @@ <li <?= $this->app->checkMenuSelection('project', 'integrations') ?>> <?= $this->url->link(t('Integrations'), 'project', 'integrations', array('project_id' => $project['id'])) ?> </li> - <li <?= $this->app->checkMenuSelection('project', 'edit') ?>> - <?= $this->url->link(t('Edit project'), 'project', 'edit', array('project_id' => $project['id'])) ?> - </li> <li <?= $this->app->checkMenuSelection('column') ?>> <?= $this->url->link(t('Columns'), 'column', 'index', array('project_id' => $project['id'])) ?> </li> |