Update Saqel Platform: 2026-09-08 18:49:45
This commit is contained in:
@@ -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,
|
||||
|
||||
Reference in New Issue
Block a user