No description
  • Python 60.8%
  • HTML 27.7%
  • JavaScript 7.9%
  • Dockerfile 2.2%
  • CSS 1.4%
Find a file
Matthieu Peterschmitt 1d83e54fda
Some checks failed
Lint / fix (push) Has been skipped
Lint / check (push) Failing after 12s
Build and publish container image / build (push) Successful in 3m29s
Add form submission progress states
- Log `Member.save()` and thumbnail generation timing for performance
  monitoring.
- Add `form-progress.js` to provide visual feedback (spinner and
  "Envoi…" label)
  on HTMX form submission.
- Add CSS spinner styles to `base.html` for button feedback.
2026-07-23 17:59:20 +02:00
.github/workflows fix(actions): add login 2026-07-23 13:39:43 +02:00
config Optimize media serving and member model 2026-07-23 17:05:05 +02:00
members Add form submission progress states 2026-07-23 17:59:20 +02:00
static Add form submission progress states 2026-07-23 17:59:20 +02:00
templates Add form submission progress states 2026-07-23 17:59:20 +02:00
.dockerignore ci: add container image and lint/fix workflows 2026-07-23 12:46:37 +02:00
.env.example csrf 2026-07-23 14:29:17 +02:00
.gitignore ci: add container image and lint/fix workflows 2026-07-23 12:46:37 +02:00
Dockerfile Update media storage to use external volume in Docker 2026-07-23 16:40:50 +02:00
manage.py ci: add container image and lint/fix workflows 2026-07-23 12:46:37 +02:00
pyproject.toml ci: add container image and lint/fix workflows 2026-07-23 12:46:37 +02:00
README.md ci: add container image and lint/fix workflows 2026-07-23 12:46:37 +02:00
uv.lock ci: add container image and lint/fix workflows 2026-07-23 12:46:37 +02:00

Trombinoscope scouts

Application web mobile-first pour les chefs : trombinoscope des membres d'un groupe scout. Photos, tison, patrouille, année d'entrée ; ajout, édition, archivage et suppression. Accès réservé (connexion).

Stack : Django 6 + HTMX, base SQLite (partagée sur un serveur), CSS Tailwind v4. Le code est en anglais, l'interface en français.

Démarrage (développement)

# 1. Dépendances (uv gère l'environnement)
uv sync

# 2. Configuration
cp .env.example .env          # puis générer une SECRET_KEY :
uv run python -c "from django.core.management.utils import get_random_secret_key as k; print(k())"

# 3. Base de données + compte chef
uv run python manage.py migrate
uv run python manage.py createsuperuser

# 4. (Optionnel) données de démo
uv run python manage.py seed_demo

# 5. Lancer
uv run python manage.py runserver

App : http://127.0.0.1:8000/ · Admin Django : http://127.0.0.1:8000/admin/

CSS (Tailwind)

Le binaire Tailwind est dans bin/tailwindcss (non versionné). Recompiler après avoir modifié des templates ou static/src/input.css :

./bin/tailwindcss -i static/src/input.css -o static/css/app.css --minify
# ou en watch pendant le dev :
./bin/tailwindcss -i static/src/input.css -o static/css/app.css --watch

Tests

uv run python manage.py test members

Gestion des membres

  • Ajouter / modifier : bouton « + Ajouter » (modale HTMX) ou fiche détail. Sur mobile, le champ photo ouvre l'appareil photo. Une miniature carrée est générée automatiquement.
  • Rechercher / filtrer : recherche live (nom, prénom, tison), filtre par patrouille, bascule « Archivés » — sans rechargement (HTMX).
  • Archiver : bouton sur chaque carte (réversible). Préférer l'archivage à la suppression pour garder l'historique.
  • Supprimer : depuis la fiche détail, avec confirmation (irréversible).
  • Les patrouilles et les comptes chefs se gèrent dans l'admin Django.

Production (aperçu)

  • .env : DEBUG=False, SECRET_KEY fort, ALLOWED_HOSTS, éventuellement DATABASE_URL (Postgres) et CSRF_TRUSTED_ORIGINS.
  • uv run python manage.py collectstatic (WhiteNoise sert les statiques).
  • Servir via gunicorn config.wsgi derrière un reverse-proxy (nginx) qui sert aussi /media/ (photos).