mirror of
				https://github.com/paperless-ngx/paperless-ngx.git
				synced 2025-10-30 03:56:23 -05:00 
			
		
		
		
	basic statistics
This commit is contained in:
		| @@ -194,3 +194,14 @@ class SearchAutoCompleteView(APIView): | ||||
|             return Response(index.autocomplete(self.ix, term, limit)) | ||||
|         else: | ||||
|             return Response([]) | ||||
|  | ||||
|  | ||||
| class StatisticsView(APIView): | ||||
|  | ||||
|     permission_classes = (IsAuthenticated,) | ||||
|  | ||||
|     def get(self, request, format=None): | ||||
|         return Response({ | ||||
|             'documents_total': Document.objects.all().count(), | ||||
|             'documents_inbox': Document.objects.filter(tags__is_inbox_tag=True).distinct().count() | ||||
|         }) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Jonas Winkler
					Jonas Winkler