mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-04-02 13:45:10 -05:00
Update serialisers.py
This commit is contained in:
parent
60796c770d
commit
1978209870
@ -862,14 +862,15 @@ class CustomFieldInstanceSerializer(serializers.ModelSerializer):
|
||||
]
|
||||
|
||||
|
||||
class UserSerializer(serializers.ModelSerializer):
|
||||
class BasicUserSerializer(serializers.ModelSerializer):
|
||||
# Different than paperless.serializers.UserSerializer
|
||||
class Meta:
|
||||
model = User
|
||||
fields = ["id", "username", "first_name", "last_name"]
|
||||
|
||||
|
||||
class NotesSerializer(serializers.ModelSerializer):
|
||||
user = UserSerializer()
|
||||
user = BasicUserSerializer()
|
||||
|
||||
class Meta:
|
||||
model = Note
|
||||
|
Loading…
x
Reference in New Issue
Block a user