chore: add changelog and documentation updates
All checks were successful
CI / lint-and-test (push) Successful in 17s
All checks were successful
CI / lint-and-test (push) Successful in 17s
- Created a new `CHANGELOG.md` file to document all notable changes to the project, adhering to the Keep a Changelog format. - Updated `CONTRIBUTING.md` to include instructions for building and previewing documentation using MkDocs. - Added `mkdocs.yml` configuration for documentation generation, including navigation structure and theme settings. - Enhanced various documentation files, including API reference, architecture overview, configuration reference, and runbook, to provide comprehensive guidance for users and developers. - Included new sections in the README for changelog and documentation links, improving accessibility to project information.
This commit is contained in:
@@ -36,7 +36,21 @@ def run_import(
|
||||
hour_utc: int,
|
||||
minute_utc: int,
|
||||
) -> tuple[int, int, int, int]:
|
||||
"""Run import: delete range per user, insert duty/unavailable/vacation. Returns (num_users, num_duty, num_unavailable, num_vacation)."""
|
||||
"""Run duty-schedule import: delete range per user, insert duty/unavailable/vacation.
|
||||
|
||||
For each entry: get_or_create_user_by_full_name, delete_duties_in_range for
|
||||
the result date range, then insert duties (handover time in UTC), unavailable
|
||||
(all-day), and vacation (consecutive ranges).
|
||||
|
||||
Args:
|
||||
session: DB session.
|
||||
result: Parsed duty schedule (start_date, end_date, entries).
|
||||
hour_utc: Handover hour in UTC (0-23).
|
||||
minute_utc: Handover minute in UTC (0-59).
|
||||
|
||||
Returns:
|
||||
Tuple (num_users, num_duty, num_unavailable, num_vacation).
|
||||
"""
|
||||
from_date_str = result.start_date.isoformat()
|
||||
to_date_str = result.end_date.isoformat()
|
||||
num_duty = num_unavailable = num_vacation = 0
|
||||
|
||||
Reference in New Issue
Block a user