feat(officialTournament): add auto-registration for tournament participants
- Implemented a new endpoint to automatically register participants for official tournaments using the Click-TT service. - Added a corresponding method in the frontend to trigger the auto-registration process, enhancing user experience by simplifying participant management. - Updated the official tournament controller and routes to support the new functionality.
This commit is contained in:
@@ -1,7 +1,17 @@
|
||||
import express from 'express';
|
||||
import multer from 'multer';
|
||||
import { authenticate } from '../middleware/authMiddleware.js';
|
||||
import { uploadTournamentPdf, getParsedTournament, listOfficialTournaments, deleteOfficialTournament, updateOfficialTournament, upsertCompetitionMember, listClubParticipations, updateParticipantStatus } from '../controllers/officialTournamentController.js';
|
||||
import {
|
||||
uploadTournamentPdf,
|
||||
getParsedTournament,
|
||||
listOfficialTournaments,
|
||||
deleteOfficialTournament,
|
||||
updateOfficialTournament,
|
||||
upsertCompetitionMember,
|
||||
listClubParticipations,
|
||||
updateParticipantStatus,
|
||||
autoRegisterOfficialTournamentParticipants
|
||||
} from '../controllers/officialTournamentController.js';
|
||||
|
||||
const router = express.Router();
|
||||
const upload = multer({ storage: multer.memoryStorage() });
|
||||
@@ -16,7 +26,7 @@ router.patch('/:clubId/:id', updateOfficialTournament);
|
||||
router.delete('/:clubId/:id', deleteOfficialTournament);
|
||||
router.post('/:clubId/:id/participation', upsertCompetitionMember);
|
||||
router.post('/:clubId/:id/status', updateParticipantStatus);
|
||||
router.post('/:clubId/:id/auto-register', autoRegisterOfficialTournamentParticipants);
|
||||
|
||||
export default router;
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user