Personal Agenda web app https://edwardbetts.com/agenda/
Find a file
Edward Betts 672ca4b849 Generalize and enhance yearly statistics
The accommodation page has been updated to provide a more comprehensive and dynamic view of travel statistics.

Previously, the page only displayed hard-coded statistics for total nights away and abroad for the year 2024. This required manual updates each year and didn't provide historical context.

This commit introduces the following changes:

*   **Dynamically Calculate Yearly Stats:** The `accommodation_list` view in `web_view.py` now calculates statistics for every year found in the accommodation data. It correctly handles stays that span across multiple years.
*   **Display All Years:** The `accommodation.html` template now iterates through a list of all calculated yearly stats, displaying a summary for each year automatically.
*   **Add Percentage of Year:** The template also calculates and displays what percentage of the year the "total nights" and "nights abroad" represent. This includes logic to correctly account for leap years (366 days) for an accurate calculation.

These changes make the statistics more informative and ensure the page remains relevant over time without needing further manual code adjustments.
2025-07-23 22:52:22 +01:00
agenda Add comprehensive tests and fix geomob URL bug 2025-07-20 01:31:19 +02:00
frontend Add empty index.js for webpack 2024-03-30 10:19:54 +00:00
static Add map size toggle button to trip page 2024-10-13 10:12:39 +01:00
templates Generalize and enhance yearly statistics 2025-07-23 22:52:22 +01:00
tests Add comprehensive test coverage for 8 modules 2025-07-20 11:39:49 +02:00
.eslintrc.js Add eslintrc.js 2024-05-05 14:56:36 +03:00
.gitignore Update gitignore 2023-10-21 09:27:40 +01:00
CLAUDE.md Update development guidelines for type annotations 2025-07-20 07:35:48 +02:00
get_airport.py Command to get airport YAML 2025-07-22 21:27:51 +01:00
LICENSE Initial commit 2023-10-02 23:45:14 +01:00
package.json Add eslintrc.js 2024-05-05 14:56:36 +03:00
parse_airbnb.py Refactor Airbnb parsing into reusable library 2025-07-18 10:35:26 +02:00
README.md Update README, new features 2023-11-23 21:22:44 +00:00
requirements.txt Improvements to trip list pages 2024-05-18 16:44:18 +02:00
run.fcgi Install location changed 2024-09-23 09:21:13 +01:00
update.py Add birthday email reminder functionality 2025-07-16 12:24:09 +02:00
validate_yaml.py Chronological order validation for YAML 2025-07-20 01:10:56 +02:00
web_view.py Generalize and enhance yearly statistics 2025-07-23 22:52:22 +01:00
webpack.config.js Avoid CDN for frontend CSS and Javascript 2024-03-30 10:18:21 +00:00

Personal agenda web app

Overview

The Agenda project is a comprehensive tool designed to keep track of various events and important dates, from holiday schedules to waste collection dates. It's an all-in-one solution for staying on top of your personal agenda.

Features

  • Event Management: Handles various types of events like birthdays, holidays, travel itineraries, conferences, and waste collection schedules.
  • Timezone Handling: Supports conversion and management of events across different time zones.
  • Data Sources Integration: Integrates with various sources like the UK and US holiday calendars, waste collection schedules, and space launch information.
  • Custom Event Scheduling: Allows defining custom recurring events using RRULE strings.
  • Dashboard View: Provides a web interface to display all upcoming events in an organized manner.

Installation

Prerequisites

  • Python 3
  • Flask
  • Other dependencies listed in requirements.txt

Setup

  1. Clone the repository:
    git clone https://git.4angle.com/edward/agenda
    
  2. Navigate to the project directory:
    cd agenda
    
  3. Install required Python packages:
    pip install -r requirements.txt
    

Configuration

  • Configure the config file with the necessary API keys and data directories.
  • Personal data such as birthdays, accommodation details, and travel plans should be placed in the specified data directory.

Usage

To run the web server:

python web_view.py

Access the web interface through a browser at http://localhost:5000/.

Modules Overview

The project is structured into several modules, each handling a specific aspect of the agenda:

  • Accommodation, Birthday, Calendar, Conference: Manage specific event types.
  • FX, GWR, Economist: Integrate with external data sources for financial information, railway schedules, and publication dates.
  • Sun, TheSpaceDevs, Travel: Calculate sunrise/sunset times, track space launches, and manage travel plans.
  • Waste Schedule, UK Holiday: Handle waste collection schedules and UK holidays.

Data Management

The data.py script is central to the functioning of the Agenda project. It compiles events from various sources and presents them in a unified format. Edit this file to modify or add new event sources.

Customization

You can customize the script to add or remove features and modify data sources as needed.

License

This project is licensed under the MIT License. Feel free to use, modify, and distribute it as per the license terms. See the LICENSE file for details.

Contact

If you have any questions or need assistance, feel free to contact the project maintainer: