From 9baae6293fb7c0b2634aa8d3185f3ab1df6e8276 Mon Sep 17 00:00:00 2001 From: Thomas Rusiecki Date: Tue, 10 Dec 2024 16:54:58 -0300 Subject: [PATCH] erase_server type now userproperty --- evidence/forms.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/evidence/forms.py b/evidence/forms.py index a47ace0..ede0e3a 100644 --- a/evidence/forms.py +++ b/evidence/forms.py @@ -186,9 +186,9 @@ class EraseServerForm(forms.Form): self.pk = None self.uuid = kwargs.pop('uuid', None) self.user = kwargs.pop('user') - instance = SystemProperty.objects.filter( + instance = UserProperty.objects.filter( uuid=self.uuid, - type=SystemProperty.Type.ERASE_SERVER, + type=UserProperty.Type.ERASE_SERVER, key='ERASE_SERVER', owner=self.user.institution ).first() @@ -201,9 +201,9 @@ class EraseServerForm(forms.Form): def clean(self): self.erase_server = self.cleaned_data.get('erase_server', False) - self.instance = SystemProperty.objects.filter( + self.instance = UserProperty.objects.filter( uuid=self.uuid, - type=Property.Type.ERASE_SERVER, + type=UserProperty.Type.ERASE_SERVER, key='ERASE_SERVER', owner=self.user.institution ).first() @@ -222,9 +222,9 @@ class EraseServerForm(forms.Form): if self.instance: return - SystemProperty.objects.create( + UserProperty.objects.create( uuid=self.uuid, - type=Property.Type.ERASE_SERVER, + type=UserProperty.Type.ERASE_SERVER, key='ERASE_SERVER', value=self.erase_server, owner=self.user.institution,