Add lessons
This commit is contained in:
@@ -77,7 +77,20 @@ export const participantAPI = {
|
||||
|
||||
// Execute lesson-specific actions (e.g., SQL query, interactive demos)
|
||||
executeLessonAction: (eventLessonId, action, data) =>
|
||||
api.post(`/lesson/${eventLessonId}/action/${action}`, data)
|
||||
api.post(`/lesson/${eventLessonId}/action/${action}`, data),
|
||||
|
||||
// Event leaderboard
|
||||
getEventLeaderboard: (eventId, filter = '') =>
|
||||
api.get(`/participant/event/${eventId}/leaderboard`, {
|
||||
params: filter ? { filter } : {}
|
||||
}),
|
||||
|
||||
// Event comments (hidden jackpot feature)
|
||||
addEventComment: (eventId, content) =>
|
||||
api.post(`/participant/event/${eventId}/comment`, { content }),
|
||||
|
||||
getEventComments: (eventId) =>
|
||||
api.get(`/participant/event/${eventId}/comments`)
|
||||
};
|
||||
|
||||
// Admin API
|
||||
@@ -117,6 +130,9 @@ export const adminAPI = {
|
||||
getEventAnalytics: (eventId) =>
|
||||
api.get(`/admin/events/${eventId}/analytics`),
|
||||
|
||||
getJackpotStats: (eventId) =>
|
||||
api.get(`/admin/events/${eventId}/jackpot-stats`),
|
||||
|
||||
// Lessons
|
||||
getAllLessons: () =>
|
||||
api.get('/admin/lessons'),
|
||||
|
||||
Reference in New Issue
Block a user