forked from fnux/rt2zammad
Add support for injecting additional data when creating user
This commit is contained in:
parent
160e7bfa71
commit
3be167144a
1 changed files with 3 additions and 1 deletions
|
@ -35,7 +35,8 @@ TEMPLATE = """{
|
|||
"rt_pass": "",
|
||||
"rt_start": 1,
|
||||
"rt_end": 1000,
|
||||
"usermap": {}
|
||||
"usermap": {},
|
||||
"userdata": {}
|
||||
}
|
||||
"""
|
||||
|
||||
|
@ -165,6 +166,7 @@ def get_user(userdata, attr="login"):
|
|||
# Create new one
|
||||
if lemail not in USERMAP:
|
||||
kwargs = {"email": email}
|
||||
kwargs.update(config["userdata"])
|
||||
if "RealName" in userdata:
|
||||
realname = userdata["RealName"]
|
||||
if ", " in realname:
|
||||
|
|
Loading…
Reference in a new issue