add new lesson mode and started code refraction

This commit is contained in:
Rene Kievits
2025-12-20 04:31:15 +01:00
parent 6438660b03
commit 4428a2b7be
101 changed files with 12255 additions and 8172 deletions

View File

@@ -1,7 +1,7 @@
import { login, logout } from '../controllers/auth.controller.js';
import { sync } from '../controllers/sync.controller.js';
import { submitReview } from '../controllers/review.controller.js';
import { getStats, getQueue, getCollection, updateSettings } from '../controllers/collection.controller.js';
import { submitReview, submitLesson } from '../controllers/review.controller.js';
import { getStats, getQueue, getLessonQueue, getCollection, updateSettings } from '../controllers/collection.controller.js';
async function routes(fastify, options) {
fastify.post('/api/auth/login', login);
@@ -12,8 +12,10 @@ async function routes(fastify, options) {
privateParams.post('/api/auth/logout', logout);
privateParams.post('/api/sync', sync);
privateParams.post('/api/review', submitReview);
privateParams.post('/api/lesson', submitLesson);
privateParams.get('/api/stats', getStats);
privateParams.get('/api/queue', getQueue);
privateParams.get('/api/lessons', getLessonQueue);
privateParams.get('/api/collection', getCollection);
privateParams.post('/api/settings', updateSettings);
});