[mod] backend-action:password_change_init

This commit is contained in:
roydfalk 2024-05-27 22:11:20 +02:00
parent 23ca09a8f3
commit 8e3656210e
2 changed files with 14 additions and 15 deletions

View file

@ -428,22 +428,10 @@ namespace _espe.backend
/**
*/
export async function member_password_change_initialize(
identifier : string
identifier : string,
url_template : string
) : Promise<string>
{
const url_template : string = (
"/"
+
lib_plankton.zoo_page.encode(
{
"name": "password_change_exec",
"parameters": {
"id": "{{id}}",
"token": "{{token}}",
}
}
)
);
return (
abstract_call(
"POST",

View file

@ -49,7 +49,18 @@ lib_plankton.zoo_page.register(
target_element.querySelector(".password_change_init-stat").textContent = lib_plankton.translate.get("page.password_change_init.status.wait");
const value = await get_value();
(
_espe.backend.member_password_change_initialize(value.identifier)
_espe.backend.member_password_change_initialize(
value.identifier,
lib_plankton.zoo_page.encode(
{
"name": "password_change_exec",
"parameters": {
"id": "{{id}}",
"token": "{{token}}",
}
}
)
)
.then(
() => {
target_element.querySelector(".password_change_init-stat").textContent = lib_plankton.translate.get("page.password_change_init.status.success");