Update Saqel Platform: 2026-09-08 18:49:45

This commit is contained in:
Hamza-Ayed
2026-09-08 18:49:45 +03:00
parent dd8b95035f
commit 9198a2f974
4 changed files with 15 additions and 22 deletions
@@ -2,6 +2,7 @@ import 'package:flutter_bloc/flutter_bloc.dart';
import 'dart:typed_data';
import '../../data/models/teacher_models.dart';
import '../../data/repositories/teacher_repository.dart';
import '../../core/utils/app_logger.dart';
/**
* ==============================================================================
@@ -179,6 +180,7 @@ class TeacherStudioCubit extends Cubit<TeacherStudioState> {
emit(state.copyWith(curriculumTree: tree, isCurriculumLoading: false));
selectGrade(key);
} catch (e) {
AppLogger.error('Studio upload failed', error: e, tag: 'TEACHER_STUDIO');
emit(state.copyWith(
isCurriculumLoading: false, errorMessage: e.toString()));
}
@@ -77,19 +77,10 @@ class _TeacherAuthScreenState extends State<TeacherAuthScreen> {
SaqelToast.showError(context, 'يرجى إدخال رمز التحقق المكون من 6 أرقام');
return;
}
final hasAnyProfileData = _fullNameController.text.trim().isNotEmpty ||
_selectedSubject != null ||
_schoolController.text.trim().isNotEmpty ||
_selectedGrades.isNotEmpty;
final hasCompleteProfileData = _fullNameController.text.trim().isNotEmpty &&
_selectedSubject != null &&
_schoolController.text.trim().isNotEmpty &&
_selectedGrades.isNotEmpty;
if (hasAnyProfileData && !hasCompleteProfileData) {
SaqelToast.showError(context,
'إما اترك بيانات الملف فارغة لتسجيل الدخول، أو أكملها كلها لإنشاء ملف معلم جديد');
return;
}
context.read<TeacherAuthCubit>().verifyOtp(
phone,
otp,