add mail type and validation

This commit is contained in:
Julian Krauser 2025-04-25 12:13:26 +02:00
parent 2e3d0a755c
commit ce9f621b8b
11 changed files with 193 additions and 19 deletions

View file

@ -1,5 +1,11 @@
import express from "express";
import { isSetup, setAppIdentity, setClubIdentity, uploadClubImages } from "../controller/setupController";
import {
isSetup,
setAppIdentity,
setClubIdentity,
setMailConfig,
uploadClubImages,
} from "../controller/setupController";
import { finishInvite, inviteUser, verifyInvite } from "../controller/inviteController";
import ParamaterPassCheckHelper from "../helpers/parameterPassCheckHelper";
import { clubImageUpload } from "../middleware/multer";
@ -22,6 +28,10 @@ router.post("/app", async (req, res) => {
await setAppIdentity(req, res);
});
router.post("/mail", async (req, res) => {
await setMailConfig(req, res);
});
router.post("/verify", ParamaterPassCheckHelper.requiredIncludedMiddleware(["mail", "token"]), async (req, res) => {
await verifyInvite(req, res);
});