|
@ -28,7 +28,7 @@ class KorekturovanePDFAdmin(VersionAdmin): |
|
|
readonly_fields = ['cas', 'stran'] |
|
|
readonly_fields = ['cas', 'stran'] |
|
|
|
|
|
|
|
|
def get_readonly_fields(self, request, obj=None): |
|
|
def get_readonly_fields(self, request, obj=None): |
|
|
""" Nevím, proč to tu je - Jidáš """ |
|
|
""" Když pdf existuje, tak nedovolím měnit ani pdf.""" |
|
|
if obj: |
|
|
if obj: |
|
|
return self.readonly_fields + ['pdf'] |
|
|
return self.readonly_fields + ['pdf'] |
|
|
return self.readonly_fields |
|
|
return self.readonly_fields |
|
|