Some checks failed
CI / test (push) Has been cancelled
핵심 기능: - 단축근무·표준·반일 등 다양한 근무 패턴 (5개 프리셋 + 사용자 정의) - Windows 이벤트 뷰어 자동 출퇴근 감지 - 30분 단위 연장근무 적립/사용 시스템 - 1.0/0.5/0.25일 연차·반차·반반차 - 자동 점심·저녁·외출·자동 백업·화면 잠금 자동 외출 - 한국 공휴일 자동 등록 (음력 포함, holidays 패키지) - matplotlib 차트 기반 주간/월간/패턴 통계 - 미니 위젯 + 시스템 트레이 통합 - 한국어/English i18n - 자가 업데이트 (updater.exe + Gitea Releases) 아키텍처: - core/ (db, time_calculator, notifier, i18n, version, settings_keys) - ui/ (main_window + 9 dialogs + 3 controllers) - utils/ (backup, lock_detector, debug_log, updater_client, time_format) - tests/ (66 pytest 단위) + 통합/i18n GUI 검증 CI/CD: - .gitea/workflows/ci.yml: push 시 pytest + 통합 테스트 - .gitea/workflows/release.yml: v* 태그 push 시 두 .exe 자동 빌드 + Releases 첨부 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
26 lines
981 B
Python
26 lines
981 B
Python
import sqlite3
|
|
from datetime import date
|
|
|
|
conn = sqlite3.connect('database.db')
|
|
cursor = conn.cursor()
|
|
|
|
print("=== Recent overtime usage ===")
|
|
cursor.execute('SELECT date, used_minutes, reason FROM overtime_usage ORDER BY date DESC LIMIT 5')
|
|
for row in cursor.fetchall():
|
|
print(f"{row[0]}: {row[1]} min - {row[2]}")
|
|
|
|
print("\n=== Recent work records ===")
|
|
cursor.execute('SELECT date, clock_in, clock_out, lunch_break, dinner_break FROM work_records ORDER BY date DESC LIMIT 3')
|
|
for row in cursor.fetchall():
|
|
lunch = "Yes" if row[3] else "No"
|
|
dinner = "Yes" if row[4] if row[4] is not None else 0 else "No"
|
|
print(f"{row[0]}: {row[1]} ~ {row[2]}, Lunch:{lunch}, Dinner:{dinner}")
|
|
|
|
print(f"\n=== Today date: {date.today().isoformat()} ===")
|
|
today = date.today().isoformat()
|
|
cursor.execute('SELECT SUM(used_minutes) FROM overtime_usage WHERE date = ?', (today,))
|
|
used_today = cursor.fetchone()[0] or 0
|
|
print(f"Overtime used today: {used_today} minutes")
|
|
|
|
conn.close()
|