Update Saqel Platform: 2026-09-08 17:51:07
This commit is contained in:
@@ -184,20 +184,20 @@ class TeacherProfileModel {
|
||||
grades = [profile['grades_taught'].toString()];
|
||||
}
|
||||
if (grades.isEmpty) {
|
||||
grades = ['الصف العاشر الأساسي', 'الأول ثانوي العلمي'];
|
||||
grades = [];
|
||||
}
|
||||
|
||||
return TeacherProfileModel(
|
||||
id: user['id'] is int ? user['id'] : 1,
|
||||
uuid: user['uuid']?.toString() ?? '',
|
||||
name: user['full_name']?.toString() ?? 'الأستاذ المعتمد',
|
||||
specialization: profile['specialization']?.toString() ?? 'الفيزياء',
|
||||
schoolName: profile['school_name']?.toString() ?? 'مدرسة الملك عبد الله الثاني للتميز',
|
||||
name: user['full_name']?.toString() ?? 'حساب معلم غير مكتمل',
|
||||
specialization: profile['specialization']?.toString() ?? 'بانتظار استكمال التخصص',
|
||||
schoolName: profile['school_name']?.toString() ?? '',
|
||||
gradesTaught: grades,
|
||||
bio: profile['bio']?.toString() ?? 'معلم معتمد في منصة صَقِل',
|
||||
rating: 4.9,
|
||||
studentsCount: 42,
|
||||
lessonsCount: 28,
|
||||
bio: profile['bio']?.toString() ?? '',
|
||||
rating: 0,
|
||||
studentsCount: 0,
|
||||
lessonsCount: 0,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@ class TeacherRepository {
|
||||
'phone_number': phoneNumber,
|
||||
'role': 'teacher',
|
||||
}),
|
||||
).timeout(const Duration(seconds: 6));
|
||||
).timeout(const Duration(seconds: 30));
|
||||
|
||||
return json.decode(response.body);
|
||||
} catch (e) {
|
||||
@@ -78,7 +78,7 @@ class TeacherRepository {
|
||||
if (fullName != null) 'full_name': fullName,
|
||||
'device_fingerprint': 'saqel_teacher_flutter',
|
||||
}),
|
||||
).timeout(const Duration(seconds: 6));
|
||||
).timeout(const Duration(seconds: 30));
|
||||
|
||||
final decoded = json.decode(response.body);
|
||||
if (decoded['status'] == 'success' && decoded['data']?['token'] != null) {
|
||||
|
||||
Reference in New Issue
Block a user