feat: Refactor notes functionality into blueprint
- Moved notes-related routes (viewing/editing workout notes) from `app.py` into a new blueprint at `routes/notes.py`. - Integrated notes-specific database logic (fetching and updating notes) directly into `routes/notes.py` helper functions, removing the corresponding methods from `db.py` for better encapsulation. - Registered the new `notes_bp` blueprint in `app.py`. - Removed the original notes route definitions from `app.py`. - Updated `url_for` calls in `templates/partials/workout_note.html` to reference the new blueprint endpoints (e.g., `notes.get_person_notes`). - Updated `templates/changelog/changelog.html` to document this refactoring in its own entry.
This commit is contained in:
@@ -10,6 +10,24 @@
|
||||
<div class="prose max-w-none">
|
||||
<p>Updates and changes to the site will be documented here, with the most recent changes listed first.</p>
|
||||
|
||||
<!-- New Entry for Calendar Year View Fix -->
|
||||
<hr class="my-6">
|
||||
<h2 class="text-xl font-semibold mb-2">March 31, 2025</h2>
|
||||
<ul class="list-disc pl-5 space-y-1">
|
||||
<li>Fixed `AttributeError` in calendar year view caused by passing a date string instead of a date
|
||||
object to the template.</li>
|
||||
</ul>
|
||||
|
||||
<!-- New Entry for Notes Refactoring -->
|
||||
<hr class="my-6">
|
||||
<h2 class="text-xl font-semibold mb-2">March 31, 2025</h2>
|
||||
<ul class="list-disc pl-5 space-y-1">
|
||||
<li>Refactored notes functionality (viewing/editing workout notes) into its own blueprint
|
||||
(`routes/notes.py`).</li>
|
||||
<li>Moved notes-specific database logic from `db.py` into the `routes/notes.py` blueprint for better
|
||||
encapsulation.</li>
|
||||
</ul>
|
||||
|
||||
<!-- New Entry for Refactoring -->
|
||||
<hr class="my-6">
|
||||
<h2 class="text-xl font-semibold mb-2">March 30, 2025</h2>
|
||||
|
||||
Reference in New Issue
Block a user