service 3
This commit is contained in:
@@ -21,7 +21,20 @@ try {
|
||||
$user = $stmt->fetch(PDO::FETCH_ASSOC);
|
||||
|
||||
if ($user) {
|
||||
// التحقق من حالة الحساب
|
||||
if ($user['status'] === 'pending') {
|
||||
jsonError("حسابك قيد المراجعة حالياً. يرجى الانتظار للموافقة.");
|
||||
exit();
|
||||
} elseif ($user['status'] === 'suspended') {
|
||||
jsonError("هذا الحساب معلق. يرجى التواصل مع الإدارة.");
|
||||
exit();
|
||||
} elseif ($user['status'] !== 'approved') {
|
||||
jsonError("لم يتم تفعيل حسابك بعد.");
|
||||
exit();
|
||||
}
|
||||
|
||||
// التحقق من كلمة المرور
|
||||
|
||||
if (password_verify($password, $user['password'])) {
|
||||
|
||||
// فك تشفير البيانات للعرض في التطبيق
|
||||
|
||||
Reference in New Issue
Block a user