Skip to content

feat(admin): show pending task count in grade management table header#3829

Merged
KATO-Hiro merged 2 commits into
stagingfrom
#3813
Jul 8, 2026
Merged

feat(admin): show pending task count in grade management table header#3829
KATO-Hiro merged 2 commits into
stagingfrom
#3813

Conversation

@KATO-Hiro

@KATO-Hiro KATO-Hiro commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

close #3813

Summary by CodeRabbit

  • New Features

    • グレード一覧の見出しに、全件数・表示件数に加えて「Pending 件数」を表示するようになりました。
    • 進行中のタスク数がひと目で分かり、一覧の状況把握がしやすくなりました。
  • Tests

    • Pending 件数の集計に関するテストを追加し、混在・全件 Pending・空データなどのケースを確認できるようにしました。

KATO-Hiro and others added 2 commits July 8, 2026 07:40
Adds countPendingTasks() utility and wires it into TaskGradeTable.svelte so
admins can see at a glance how many tasks are still ungraded (PENDING) across
the whole dataset, independent of the current search filter.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 72ef3b9e-1ea9-493f-babb-5839c6a8789e

📥 Commits

Reviewing files that changed from the base of the PR and between e675644 and 2ddd3d5.

📒 Files selected for processing (3)
  • src/routes/(admin)/tasks/grade/_components/TaskGradeTable.svelte
  • src/routes/(admin)/tasks/grade/_utils/grade_table_filter.test.ts
  • src/routes/(admin)/tasks/grade/_utils/grade_table_filter.ts

📝 Walkthrough

Walkthrough

グレード管理画面の見出しにPending件数を表示する機能を追加しました。grade_table_filter.tscountPendingTasks 関数を新規実装し、TaskGradeTable.svelte から呼び出して見出しに反映、対応するユニットテストも追加されています。

Changes

Pending件数表示

Layer / File(s) Summary
countPendingTasks関数とテスト
src/routes/(admin)/tasks/grade/_utils/grade_table_filter.ts, src/routes/(admin)/tasks/grade/_utils/grade_table_filter.test.ts
TaskGrade をインポートし、全タスク中の PENDING 件数を数える countPendingTasks を新規追加。混在・全件PENDING・空配列などのケースを検証するテストを追加。
画面見出しへの反映
src/routes/(admin)/tasks/grade/_components/TaskGradeTable.svelte
countPendingTasks をインポートし pendingCount$derived で算出、見出しに Pending {pendingCount} 問 を追加表示。

Estimated code review effort: 1 (Trivial) | ~5 minutes

Sequence Diagram(s)

sequenceDiagram
  participant TaskGradeTable
  participant grade_table_filter

  TaskGradeTable->>grade_table_filter: countPendingTasks(tasks)
  grade_table_filter-->>TaskGradeTable: pendingCount
  TaskGradeTable->>TaskGradeTable: 見出しにpendingCountを表示
Loading

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed タイトルはadminのgrade管理表ヘッダーにpending件数を表示する変更を簡潔に示しています。
Linked Issues check ✅ Passed #3813の「pendingの総問題数を表示する」要件に対し、ヘッダー表示と集計ユーティリティ追加で一致しています。
Out of Scope Changes check ✅ Passed 変更点は集計表示と関連テストに限定され、リンク課題に対して明確な範囲外の追加は見当たりません。
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch #3813

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@KATO-Hiro KATO-Hiro left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@KATO-Hiro KATO-Hiro merged commit 0e4831c into staging Jul 8, 2026
3 checks passed
@KATO-Hiro KATO-Hiro deleted the #3813 branch July 8, 2026 07:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[feat] 「グレード管理」で pending の総問題数を表示できるようにしましょう

1 participant