1
0
mirror of https://gitlab.crans.org/bde/nk20 synced 2024-12-23 07:52:23 +00:00

Changelogs are read-only protected

This commit is contained in:
Yohann D'ANELLO 2020-03-11 11:25:40 +01:00
parent 417cd5da04
commit 1379759803

View File

@ -15,3 +15,5 @@ class ChangelogSerializer(serializers.ModelSerializer):
class Meta:
model = Changelog
fields = '__all__'
# noinspection PyProtectedMember
read_only_fields = [f.name for f in model._meta.get_fields()] # Changelogs are read-only protected