Skip to content

Add fasting feature: FastingWindow model, tests, and views#2138

Open
gracechen636 wants to merge 4 commits intowger-project:masterfrom
gracechen636:fasting-feature
Open

Add fasting feature: FastingWindow model, tests, and views#2138
gracechen636 wants to merge 4 commits intowger-project:masterfrom
gracechen636:fasting-feature

Conversation

@gracechen636
Copy link
Copy Markdown

Proposed Changes

Add FastingWindow model to represent user fasting periods, including start/end times, optional goal duration, etc.

Provide convenience properties for active status and duration calculations.

Add unit tests covering model creation, behavior, and ordering.

Related Issue(s)
#2134

Do users need to run some commands in their local instances due to this PR
(e.g. database migration, deployment changes)?

Maybe.
This PR introduces a new model, so users may need to run database migrations:

python manage.py makemigrations
python manage.py migrate

@rolandgeider
Copy link
Copy Markdown
Member

NB: I'm planning to finish implementing the UI for the trophies, doing a release, and then merging this for the next one

# Conflicts:
#	.github/workflows/docker-base.yml
#	.github/workflows/docker-demo.yml
#	.github/workflows/docker.yml
#	AUTHORS.md
#	package-lock.json
#	package.json
#	pyproject.toml
#	uv.lock
#	wger/core/forms.py
#	wger/core/templates/template.html
#	wger/core/urls.py
#	wger/core/views/misc.py
#	wger/locale/de/LC_MESSAGES/django.po
#	wger/locale/fi/LC_MESSAGES/django.po
#	wger/locale/he/LC_MESSAGES/django.po
#	wger/locale/hi/LC_MESSAGES/django.po
#	wger/locale/nl/LC_MESSAGES/django.po
These were probably changed by some merge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants