feat: Introduce announcements service, integrate MinIO for lesson media with presigned URLs, and restrict editing of pending courses.

This commit is contained in:
JakkrapartXD 2026-01-26 15:15:46 +07:00
parent 5f8e0a3687
commit bbfb62093e
5 changed files with 145 additions and 4 deletions

View file

@ -352,7 +352,7 @@ export class CoursesInstructorService {
if (!course) {
throw new NotFoundError('Course not found');
}
if (course.status === 'APPROVED') {
if (course.status === 'APPROVED' || course.status === 'PENDING') {
throw new ForbiddenError('Course is already approved Cannot Edit');
}
}