From 7ef87320a047a3610d4ca83dca56cfc5e21bc6c8 Mon Sep 17 00:00:00 2001 From: Matthias Date: Thu, 22 Jul 2021 23:44:25 +0200 Subject: [PATCH] abstract edit --- InvenTree/common/views.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/InvenTree/common/views.py b/InvenTree/common/views.py index f953dffa81..f182b03e0d 100644 --- a/InvenTree/common/views.py +++ b/InvenTree/common/views.py @@ -45,8 +45,8 @@ class SettingEdit(AjaxUpdateView): ctx['key'] = setting.key ctx['value'] = setting.value - ctx['name'] = models.InvenTreeSetting.get_setting_name(setting.key) - ctx['description'] = models.InvenTreeSetting.get_setting_description(setting.key) + ctx['name'] = self.model.get_setting_name(setting.key) + ctx['description'] = self.model.get_setting_description(setting.key) return ctx @@ -69,12 +69,12 @@ class SettingEdit(AjaxUpdateView): self.object.value = str2bool(setting.value) form.fields['value'].value = str2bool(setting.value) - name = models.InvenTreeSetting.get_setting_name(setting.key) + name = self.model.get_setting_name(setting.key) if name: form.fields['value'].label = name - description = models.InvenTreeSetting.get_setting_description(setting.key) + description = self.model.get_setting_description(setting.key) if description: form.fields['value'].help_text = description