- add_introspection_rules([
- (
- [JSONField], # Class(es) these apply to
- [], # Positional arguments (not used)
- {}, # Keyword argument
- ), ], ["^catalogue\.fields\.JSONField"])
-except ImportError:
- pass
+class JQueryAutoCompleteSearchField(forms.CharField):
+ def __init__(self, options={}, *args, **kwargs):
+ if 'widget' not in kwargs:
+ kwargs['widget'] = JQueryAutoCompleteSearchWidget(options)
+
+ super(JQueryAutoCompleteSearchField, self).__init__(*args, **kwargs)