Merge "Update default_project param on create user"
This commit is contained in:
commit
749e436c63
@ -329,7 +329,7 @@ def user_create(request, name=None, email=None, password=None, project=None,
|
||||
return VERSIONS.upgrade_v2_user(user)
|
||||
else:
|
||||
return manager.create(name, password=password, email=email,
|
||||
project=project, enabled=enabled,
|
||||
default_project=project, enabled=enabled,
|
||||
domain=domain, description=description)
|
||||
except keystone_exceptions.Conflict:
|
||||
raise exceptions.Conflict()
|
||||
|
@ -147,14 +147,15 @@ class CreateUserForm(PasswordMixin, BaseUserForm):
|
||||
desc = data["description"]
|
||||
if "email" in data:
|
||||
data['email'] = data['email'] or None
|
||||
new_user = api.keystone.user_create(request,
|
||||
name=data['name'],
|
||||
email=data['email'],
|
||||
description=desc,
|
||||
password=data['password'],
|
||||
project=data['project'],
|
||||
enabled=data['enabled'],
|
||||
domain=domain.id)
|
||||
new_user = \
|
||||
api.keystone.user_create(request,
|
||||
name=data['name'],
|
||||
email=data['email'],
|
||||
description=desc,
|
||||
password=data['password'],
|
||||
project=data['project'] or None,
|
||||
enabled=data['enabled'],
|
||||
domain=domain.id)
|
||||
messages.success(request,
|
||||
_('User "%s" was successfully created.')
|
||||
% data['name'])
|
||||
|
Loading…
x
Reference in New Issue
Block a user