feat: add completed chores to the display order in ChildView and update sorting priority
All checks were successful
Chore App Build, Test, and Push Docker Images / build-and-push (push) Successful in 2m50s

This commit is contained in:
2026-03-24 17:10:51 -04:00
parent ac29ee9bd0
commit f64311689b
2 changed files with 2 additions and 0 deletions

View File

@@ -65,6 +65,7 @@ When viewing the child's chores, kindnesses, penalties, rewards. The items shoul
1. Scheduled for today chores (with earliest deadline first when it applies) 1. Scheduled for today chores (with earliest deadline first when it applies)
2. General Chores 2. General Chores
3. Pending chores 3. Pending chores
4. Completed Chores
- Rewards - Rewards

View File

@@ -468,6 +468,7 @@ function choreDueLabel(item: ChildTask): string | null {
// ── Sorting ─────────────────────────────────────────────────────────────────── // ── Sorting ───────────────────────────────────────────────────────────────────
function childChoreSortPriority(item: ChildTask): number { function childChoreSortPriority(item: ChildTask): number {
if (isChoreCompletedToday(item)) return 3
if (item.pending_status === 'pending') return 2 if (item.pending_status === 'pending') return 2
if (!item.schedule) return 1 // general chore if (!item.schedule) return 1 // general chore
return 0 // scheduled for today return 0 // scheduled for today