SMI Exam Schedule & Status Fix — 2026-08-04

1. Student exam availability
- Normalized legacy Published/Open/Active status values.
- Start time opens the exam exactly at the configured time.
- End time closes the exam exactly at the configured time.
- Attempt expiration is capped by the exam closing time.
- Future, open, and closed states are shown accurately.

2. Student exam cards
- Added exact Opens and Closes values.
- Completed students see "تم الاختبار".
- Completed students retain result access after global closure when automatic result display is enabled or the result is manually released.
- Students without attempts see a disabled closed state after the deadline.

3. Teacher and admin controls
- Added clear lifecycle labels: Open now, Scheduled, Window ended, Closed manually.
- Publishing an exam with an expired old End At uses Reopen Now and clears the stale end time.
- Future schedules remain unchanged and open automatically at their configured time.

4. Participation reporting
- Teacher Students Results now lists every enrolled student.
- Admin Submissions filter shows a complete participation roster for the selected exam.
- Added Completed, In Progress, and Not Taken counts.

No exam questions, answers, grading rules, codes, retake logic, or other project pages were removed.

5. Schedule form reliability
- In the teacher form, entered Start At / End At values now take precedence over the default Open Now checkbox.
- A schedule can no longer be silently erased when the teacher enters dates without manually clearing the checkbox.
