Add user InvitationDialog

This commit is contained in:
Johannes Zellner
2025-03-28 20:39:54 +01:00
parent b89f55f9b9
commit d68db98d62
5 changed files with 100 additions and 9 deletions
+11
View File
@@ -157,6 +157,17 @@ function create() {
if (result.status !== 202) return [result];
return [null];
},
async inviteLink(id) {
let result;
try {
result = await fetcher.get(`${API_ORIGIN}/api/v1/users/${id}/invite_link`, { access_token: accessToken });
} catch (e) {
return [e];
}
if (result.status !== 200) return [result];
return [null, result.body.inviteLink];
},
};
}