feat: add invited_by attribute
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
e347b1eed1
commit
3138a2964f
@ -58,7 +58,9 @@ def form_keycloak_register(
|
|||||||
username: str = Form(...),
|
username: str = Form(...),
|
||||||
email: str = Form(...),
|
email: str = Form(...),
|
||||||
password: str = Form(...),
|
password: str = Form(...),
|
||||||
|
invited_by: str = Form(...),
|
||||||
):
|
):
|
||||||
|
|
||||||
payload = {
|
payload = {
|
||||||
"email": email,
|
"email": email,
|
||||||
"username": username,
|
"username": username,
|
||||||
@ -74,6 +76,7 @@ def form_keycloak_register(
|
|||||||
"realmRoles": [
|
"realmRoles": [
|
||||||
"user_default",
|
"user_default",
|
||||||
],
|
],
|
||||||
|
"attributes": {"invited_by": username},
|
||||||
}
|
}
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
@ -20,6 +20,8 @@
|
|||||||
<label for="password">Password:</label>
|
<label for="password">Password:</label>
|
||||||
<input type="password" name="password" />
|
<input type="password" name="password" />
|
||||||
|
|
||||||
|
<input type="hidden" name="invited_by" value="{{ username }}"/>
|
||||||
|
|
||||||
<input type="submit" />
|
<input type="submit" />
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user