重复任务自动完成与项目页口径对齐(v3.8)

This commit is contained in:
XIGE
2026-12-01 16:28:21 +08:00
parent ce48d805fc
commit 44b0baacca
6 changed files with 95 additions and 46 deletions

View File

@@ -382,7 +382,10 @@ class TasksFragment : Fragment(R.layout.fragment_tasks) {
private fun toRow(task: Task, spans: Map<Long, SessionSpan>): TaskAdapter.Row.Item {
val project = projects.firstOrNull { it.id == task.projectId }
val overdue = task.due > 0 && task.due < Dates.todayStart()
// 重复任务按周期滚动,本轮没做不算逾期(下一轮生成时会自动结束旧实例);
// 只有不重复的任务才标「已逾期」
val overdue = task.due > 0 && task.due < Dates.todayStart() &&
task.repeatType == com.focusbox.app.model.Repeat.NONE
return TaskAdapter.Row.Item(
task = task,
projectName = project?.name ?: getString(R.string.inbox),