mirror of
https://github.com/graphql-python/graphene-django.git
synced 2025-12-08 02:34:16 +03:00
12 lines
275 B
Python
12 lines
275 B
Python
from graphene.relay import Connection
|
|
from graphene.types.scalars import Int
|
|
|
|
class CountableConnectionInitial(Connection):
|
|
class Meta:
|
|
abstract = True
|
|
|
|
total_count = Int()
|
|
|
|
def resolve_total_count(self, info, **kwargs):
|
|
return len(self.iterable)
|