feat(grade10): add chemistry, biology, and earth sciences virtual labs, fix video CDN playback, teacher submissions SQL, and enable authenticated lesson reading
This commit is contained in:
@@ -336,10 +336,19 @@ class TeacherStudioCubit extends Cubit<TeacherStudioState> {
|
||||
clearError: true,
|
||||
));
|
||||
try {
|
||||
final preflight = await repository.preflightSubmission(
|
||||
var preflight = await repository.preflightSubmission(
|
||||
curriculumLessonId: selectedCurriculumLessonId!,
|
||||
idempotencyKey: _newIdempotencyKey(),
|
||||
);
|
||||
if (preflight['status']?.toString() == 'existing_submission' && preflight['submission_id'] != null) {
|
||||
// إذا كانت الحصة مسجلة مسبقاً، نطلب تلقائياً إنشاء نسخة مرشحة للاستبدال
|
||||
preflight = await repository.preflightSubmission(
|
||||
curriculumLessonId: selectedCurriculumLessonId!,
|
||||
idempotencyKey: _newIdempotencyKey(),
|
||||
replacement: true,
|
||||
submissionId: preflight['submission_id'].toString(),
|
||||
);
|
||||
}
|
||||
if (preflight['status']?.toString() != 'ready_for_upload') {
|
||||
emit(state.copyWith(
|
||||
isAuditing: false,
|
||||
|
||||
Reference in New Issue
Block a user