fix: schedule status system — auto-key, config order, label lookup

- Auto-generate status key from label (admin doesn't need to set keys)
- Remove visible key field from status config editor
- Order statuses/levels in filters by config order (matches admin panel)
- Shared findStatusConfig() for robust label lookup (by key, label, or derived key)
- Custom status badges in DayCard, GroupCard, MobileSchedule
- Simplified filter logic with clsStatus helper
- Removed dead code: TIME_PRESETS, StatusFilter type
- SelectField: blur input after selection to prevent re-open
This commit is contained in:
2026-03-28 00:33:55 +03:00
parent b322c969f2
commit bdeedcfcc8
9 changed files with 102 additions and 37 deletions
@@ -44,6 +44,11 @@ function ClassRow({
набор
</span>
)}
{cls.status && cls.status !== "hasSlots" && cls.status !== "recruiting" && (
<span className="shrink-0 rounded-full bg-gold/15 border border-gold/25 px-2 py-0.5 text-[10px] font-semibold text-gold">
{cls.status}
</span>
)}
</div>
<button
onClick={() => toggleFilterTrainer(cls.trainer)}