Welcome | Get started | Dive | Contribute | Topics | Reference | Changes | More

voga3 : A fictive dance school in Estonia

The lino_book.projects.voga3 demo project uses Lino Voga for managing a fictive dance school in Estonia. The dance school organizes group trainings and individual trainings. Teachers are either engaged employees or freelancers paid per hour by the participants. Scheduling individual lessons is a dynamic process where the pupils decide individually whether the can come to a suggested appointment, often very short-term.

This page contains code snippets (lines starting with >>>), which are being tested during our development workflow. The following snippet initializes the demo project used throughout this page.

>>> from lino_book.projects.voga3.startup import *
>>> dd.demo_date()
...
datetime.date(2025, 7, 14)
>>> mary = users.User.objects.get(username="mary")
>>> print(mary.user_type)
400 (Pupil)
>>> print(courses.Pupil.objects.get(id=mary.partner.id))
Mary Morgan (N)
>>> course = rt.models.courses.Course.objects.get(id=11)
>>> print(course)
011C FG (Functional gymnastics)
>>> event = course.get_existing_auto_events().first()
>>> print(list(course.suggest_cal_guests(event)))
[Guest(event=651,partner=54,role=1,state=<cal.GuestStates.invited:10>), Guest(event=651,partner=56,role=1,state=<cal.GuestStates.invited:10>)]
>>> rt.models.cal.Event.get_default_table()
lino_xl.lib.cal.ui.Events
>>> ar = rt.login("robin")
>>> obj = publisher.Page.objects.get(pk=14)
>>> dd.plugins.publisher.renderer.obj2url(ar, obj)
'/p/14'