timetracker/games/graphql/queries/platform.py

12 lines
278 B
Python
Raw Permalink Normal View History

2023-11-29 20:58:33 +00:00
import graphene
from games.graphql.types import Platform
from games.models import Platform as PlatformModel
class Query(graphene.ObjectType):
platforms = graphene.List(Platform)
def resolve_platforms(self, info, **kwargs):
return PlatformModel.objects.all()