Remove feature "Allow everybody to access to this project"

This commit is contained in:
Frederic Guillot
2017-10-27 16:16:11 -07:00
parent 0b9c3b0a5b
commit cc6618901b
47 changed files with 53 additions and 320 deletions

View File

@@ -2,36 +2,18 @@
<h2><?= t('Allowed Users') ?></h2>
</div>
<?php if ($project['is_everybody_allowed']): ?>
<div class="alert"><?= t('Everybody have access to this project.') ?></div>
<?php else: ?>
<?= $this->render('project_permission/users', array(
'project' => $project,
'roles' => $roles,
'users' => $users,
'errors' => $errors,
'values' => $values,
)) ?>
<?= $this->render('project_permission/users', array(
'project' => $project,
'roles' => $roles,
'users' => $users,
'errors' => $errors,
'values' => $values,
)) ?>
<?= $this->render('project_permission/groups', array(
'project' => $project,
'roles' => $roles,
'groups' => $groups,
'errors' => $errors,
'values' => $values,
)) ?>
<?php endif ?>
<?php if ($project['is_private'] == 0): ?>
<hr/>
<form method="post" action="<?= $this->url->href('ProjectPermissionController', 'allowEverybody', array('project_id' => $project['id'])) ?>">
<?= $this->form->csrf() ?>
<?= $this->form->hidden('id', array('id' => $project['id'])) ?>
<?= $this->form->checkbox('is_everybody_allowed', t('Allow everybody to access to this project'), 1, $project['is_everybody_allowed']) ?>
<div class="form-actions">
<button type="submit" class="btn btn-blue"><?= t('Save') ?></button>
</div>
</form>
<?php endif ?>
<?= $this->render('project_permission/groups', array(
'project' => $project,
'roles' => $roles,
'groups' => $groups,
'errors' => $errors,
'values' => $values,
)) ?>