No project description provided
Project description
Django Autocomplete
substring occurrence search module.
Allows the use of celery, if it is in the mood. The following settings are required in settings.py
AUTOCOMPLETER = {
'SERILEZER_CLASSES': 'your_module_name.autocomplete',
'LIMIT': 5,
'CELERY': True
}
Where:
- SERILEZER_CLASSES - indicates django_autompleter where to look for serialization ticket offices. The serialization class inherits from the base class SearcherSerializer. In the example below, we indicate which fields from the Publication model we want to return when requested.
from autocompleter import SearcherSerializer
class PublicationsSerializer(SearcherSerializer):
class Meta:
model = Publication
fields = (
'id',
'title',
)
- LIMIT - indicates the number of records received that must be returned.
- CELERY - indicates the start of the autocomputer as a celery task. It is important, in this case, your project must have celery.py settings.
example:
from autocompleter import Autocompleter
autocomplete_coonection = Autocompleter()
result = autocomplete_coonection.get(
model=Publication,# search data model
column="title",#column of the model to search for
value=value # value
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for django_autocompleter-0.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 97efe607c9898ffe8e272bc2432d335977347fa47030ef30d1751a778e476bfb |
|
MD5 | 3a331678c06f4c8f29d14773fcb0bb0a |
|
BLAKE2b-256 | 223a3a4ef1a25667995029f333c972ef1ea51348b176f0ba6184343befb47a21 |
Close
Hashes for django_autocompleter-0.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e973336ef96976c1480f9c914741f3fd826e4ba13f175ee296455bb738c3fc14 |
|
MD5 | a35710659dd1b8d532e3df526a73916b |
|
BLAKE2b-256 | 27392aaca1afb3e9fc232b271ece59cca2df18d22bbef55b7a58ce9acd1948f7 |