summaryrefslogtreecommitdiff
path: root/ishtar_common
diff options
context:
space:
mode:
Diffstat (limited to 'ishtar_common')
-rw-r--r--ishtar_common/management/commands/json_summary.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/ishtar_common/management/commands/json_summary.py b/ishtar_common/management/commands/json_summary.py
index 95ef1d66d..cbb83ef9d 100644
--- a/ishtar_common/management/commands/json_summary.py
+++ b/ishtar_common/management/commands/json_summary.py
@@ -7,10 +7,12 @@ import json
from django.core.management.base import BaseCommand
+from django.contrib.auth.models import User
from archaeological_operations.models import Operation, ArchaeologicalSite
from archaeological_context_records.models import ContextRecord
from archaeological_finds.models import Find
from archaeological_warehouse.models import Warehouse, Container
+from ishtar_common.models import Document
class Command(BaseCommand):
@@ -30,6 +32,10 @@ class Command(BaseCommand):
"warehouses": Warehouse.objects.count(),
"containers": Container.objects.filter(
container_type__stationary=False).count(),
+ "users": User.objects.filter(is_active=True).count(),
+ "documents": Document.objects.count(),
+ "documents_with_images":
+ Document.objects.filter(image__isnull=False).exclude(image='').count(),
}
sys.stdout.write(json.dumps(data))