mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-24 18:14:22 +00:00
14 lines
303 B
Python
14 lines
303 B
Python
|
from ninja import ModelSchema
|
||
|
|
||
|
from core.schemas import SimpleUserSchema
|
||
|
from counter.models import Counter
|
||
|
|
||
|
|
||
|
class CounterSchema(ModelSchema):
|
||
|
barmen_list: list[SimpleUserSchema]
|
||
|
is_open: bool
|
||
|
|
||
|
class Meta:
|
||
|
model = Counter
|
||
|
fields = ["id", "name", "type", "club", "products"]
|