학교 전용 공부 타이머(열품타) + 학년별 랭킹 기능 추가

학생 참여 유도를 위해 공부 시작/종료 타이머와 학년별(오늘/이번주/전체)
랭킹 화면을 대시보드에 추가. 로그인 응답에 학년 정보를 포함시켜
세션 저장/복원 전체 경로에 전달되도록 함.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-14 14:58:55 +09:00
co-authored by Claude Sonnet 5
parent 26e54a1798
commit a59a3054fb
9 changed files with 662 additions and 2 deletions
+20
View File
@@ -19,6 +19,7 @@ import 'launchpad_transition.dart';
import 'login_screen.dart';
import 'nfc_poccket_checkin_screen.dart';
import 'nfc_tag_writer_screen.dart';
import 'study_timer_screen.dart';
import 'teacher_attendance_page.dart';
import 'teacher_student_management_page.dart';
@@ -27,6 +28,7 @@ class MainDashboard extends StatefulWidget {
final String? userName;
final String role; // 'student' | 'teacher' | 'admin'
final bool isDeviceMatched;
final int? grade; // 🎓 공부 타이머 학년별 랭킹에서 본인 학년을 기본값으로 쓰기 위함.
const MainDashboard({
super.key,
@@ -34,6 +36,7 @@ class MainDashboard extends StatefulWidget {
this.userName,
required this.role,
this.isDeviceMatched = true,
this.grade,
});
@override
@@ -312,6 +315,23 @@ class _MainDashboardState extends State<MainDashboard> {
),
),
));
tiles.add((
id: 'study_timer',
child: _buildModernCard(
icon: Icons.timer_rounded,
title: '공부 타이머',
subtitle: '열품타 | 학년별 공부 랭킹',
color: AppPalette.ink,
onTap: () => pushLaunchpad(
context,
(context) => StudyTimerScreen(
studentId: _displayId,
studentName: _displayName,
grade: widget.grade,
),
),
),
));
}
if (_isTeacherOrAbove) {