added logging for user property creation

This commit is contained in:
Thomas Nahuel Rusiecki 2024-12-09 18:38:09 -03:00
parent 0c837416e1
commit 26b9b2e4d9

View file

@ -187,6 +187,11 @@ class AddUserPropertyView(DashboardView, CreateView):
form.instance.type = Property.Type.USER
messages.success(self.request, _("User property successfully added."))
device_logger.info(
f"Created user property (key='{form.instance.key}', value='{form.instance.value}') by user {self.request.user}, for evidence uuid: {self.property.uuid}."
)
response = super().form_valid(form)
return response