diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2023-07-06 11:34:33 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2023-07-06 11:46:39 +0200 |
commit | 04834bbea2984400b3a3d33ed4e32fc04affff1f (patch) | |
tree | d0baf37b61616ac0455eccc95214289088ce6396 /archaeological_operations/widgets.py | |
parent | e15763bbcee86bf867c43586d32a59acef30daa0 (diff) | |
download | Ishtar-04834bbea2984400b3a3d33ed4e32fc04affff1f.tar.bz2 Ishtar-04834bbea2984400b3a3d33ed4e32fc04affff1f.zip |
🚧 work on autofocus fix
Diffstat (limited to 'archaeological_operations/widgets.py')
-rw-r--r-- | archaeological_operations/widgets.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/archaeological_operations/widgets.py b/archaeological_operations/widgets.py index f2a2d3d66..7519bf0a8 100644 --- a/archaeological_operations/widgets.py +++ b/archaeological_operations/widgets.py @@ -66,6 +66,11 @@ class OAWidget(forms.TextInput): def render(self, name, value, attrs=None, renderer=None): if not value: value = "" + attrs.update(self.attrs) + if "class" not in attrs: + attrs["class"] = "widget-oa" + else: + attrs["class"] += " widget-oa" final_attrs = flatatt(self.build_attrs(attrs, {"name": name, "value": value})) oa_prefix = get_current_profile(force=False).operation_prefix or "" dct = { |