mirror of
https://github.com/vatesfr/xen-orchestra.git
synced 2026-11-09 17:06:13 -06:00
User can be created with a specified permission.
This commit is contained in:
@@ -61,6 +61,14 @@
|
||||
<span class="add-on"><i class="icon-key"></i></span>
|
||||
<input class="span2" type="password" placeholder="Password" name="password" />
|
||||
</div>
|
||||
<div>
|
||||
<select name="permission">
|
||||
<option value="none" selected="selected">None</option>
|
||||
<option value="read">Read</option>
|
||||
<option value="write">Write</option>
|
||||
<option value="admin">Administration</option>
|
||||
</select>
|
||||
</div>
|
||||
<button type="submit" class="btn btn-primary">
|
||||
<i class="icon-plus"></i> Create user
|
||||
</button>
|
||||
|
||||
@@ -39,7 +39,7 @@ if (isset($_GET['a']))
|
||||
}
|
||||
if ($action === 'create')
|
||||
{
|
||||
$xo->user->create($_POST['name'], $_POST['password']);
|
||||
$xo->user->create($_POST['name'], $_POST['password'], $_POST['permission']);
|
||||
$application->redirect($referer ?: './');
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user