Commit Graph

392 Commits

Author SHA1 Message Date
Johannes Hoppe 0ee50d9866 Fixes pickel issue of lazy object 2016-01-27 10:01:19 +01:00
Johannes Hoppe 7d8908daab Fixes version number and QA issue 2016-01-26 17:55:56 +01:00
Johannes Hoppe 4a1b83ad1e Fixes security bug and adds secruity documentation
An attacker was able to use a `field_id` from a "secret" field
and use if on any even the default public select2 view and
receive the data without authentication.
2016-01-26 13:18:36 +01:00
mostafa-anm 33a00c1e39 Fixed #218 -- Add custom label support
Added `label_from_instance` method for model widgets to define custom option labels.

Closed #233
2016-01-19 08:50:09 +01:00
Andrew Dodd 89674ec375 Update conf.py
Minor copy-paste error.

Closed #240
2015-12-17 10:15:11 +01:00
Andrew Dodd e655ed7a59 Add setting to change source of select2 assets
These changes introduce additional (optional) configuration parameters.
The parameters allow the user of the library to select different JS/CSS
libraries from the ones shipped. In particular, this allows serving from
the local server and/or in private-network-only environments.

Refs #220
Closed #239
2015-12-15 19:57:48 +01:00
Elijah Karari 3c06873148 Replace "patterns" with list in url config
`django.conf.urls.patterns` has been remmoved in Django 1.9.

Closed #236
2015-12-10 16:05:29 +01:00
Johannes Hoppe 84e1abaf4e Remove model_mommy test dependency 2015-12-02 20:05:38 +01:00
Johannes Hoppe 6ebeb4c6d7 Fixed pep257 issues 2015-12-02 19:40:14 +01:00
Johannes Hoppe 7d8a7e7a9f Fixed pytest setup on travis 2015-12-02 19:32:28 +01:00
Johannes Hoppe 9ba75bb820 Updated test suite for python 3.5 support 2015-12-02 19:28:16 +01:00
Johannes Hoppe cfc7c2c541 Added pip-tools for requirement manageing
Updated requirements
2015-12-02 19:27:23 +01:00
Johannes Hoppe 6c5e2036ca Updated test suite and setup file for Django 1.9 release 2015-12-02 18:57:28 +01:00
Johannes Hoppe 4defb8112b Fixed #222 -- Display intital data for heavy widgets 2015-12-01 10:19:02 +01:00
Johannes Hoppe bb90be77b7 Fixed #231 -- Avoid fetching entire queryset from db
Patched ciritcal memory leak in ModelSelect2 widgets.
Boolean evaluation of queryset makes django fetch all
elements.

Thanks to @magicjohnson for discovering this issue
2015-11-30 13:17:02 +01:00
Johannes Hoppe 18647161a1 Fixed docs 2015-11-29 20:47:22 +01:00
Royendgel Silberie 3e6c1fc3ba fixing small typo
Closed #227
2015-11-29 20:03:01 +01:00
Johannes Hoppe 19a8d63bb1 Refactors tag widgets and adds light tag widget
Currently there was no light version of the tag widget.
A light version might come handy if you use a postgres
`ArrayField` and a corresponding `SimpleArrayField`.

Resolved #226
2015-11-23 11:54:51 +01:00
Anne Fleischer 0457617738 Fixed javaScript bug for multiple different select2 fields on one page
Closed #224
2015-11-18 00:03:02 +01:00
Anne Fleischer 974ba552b0 Converted initialization code into configurable jQuery plugin
Closed #211
2015-11-12 12:50:58 +01:00
Thomas Schreiber 2beb5d23c7 Fix HeavySelect2TagWidget to respect custom attrs and default overrides
Closed #214
2015-10-27 17:44:22 +01:00
Johannes Hoppe b8d53aa714 Added v5.2.0 changelog 2015-10-05 19:34:52 +02:00
Johannes Hoppe b0d2325c43 Resolved #209 -- Added pagination 2015-10-05 19:01:43 +02:00
Johannes Hoppe 9d1bcfee6a Fixed flake8 error 2015-10-05 19:01:21 +02:00
Johannes Hoppe 2c1eb8bc4a Fixed -- IndexError: pop from empty list 2015-10-05 12:59:35 +02:00
Johannes Hoppe a91e66bf9e Created v5.1.0 release 2015-10-01 14:09:41 +02:00
Johannes Hoppe 75c8c38e2d Impooved cacheing to reduce pickling issues
Not not the entire widget gets cached nor the entire queryset.
The query and gets pickeld separately.
2015-10-01 14:07:51 +02:00
Johannes Hoppe dc81c2b3b5 Added search term splitting 2015-10-01 13:05:52 +02:00
Johannes Hoppe 48ea7549a6 Freeze dev requirements to avoid travis error 2015-10-01 13:01:52 +02:00
Johannes Hoppe 485ea191cb Fixed filter_queryset bug
The reduce statement coundn't handle multiple lookup strings.
2015-09-30 10:28:37 +02:00
Johannes Hoppe 4d484163c2 Fixed packaging error 2015-09-29 15:12:57 +02:00
Johannes Hoppe 85f76d7ba5 Added external_req for read the docs 2015-09-29 14:51:57 +02:00
Johannes Hoppe e184f5fea6 Bump version number because v5.0.0 was taken on pypi due to mistake 2015-09-29 14:46:43 +02:00
Johannes Hoppe f301dc6f9d Added documentation 2015-09-29 14:33:06 +02:00
Johannes Hoppe 5dfd8553cc Added tests 2015-09-29 13:55:05 +02:00
Johannes Hoppe f80abb10f2 Added allow-clear support 2015-09-29 13:55:05 +02:00
Johannes Hoppe 6dad55eb11 Upgrade to select2 4.0 2015-09-29 13:55:05 +02:00
Johannes Hoppe 95297a362e Radical removal of all unneeded code 2015-09-29 13:54:23 +02:00
Johannes Hoppe 33b7dffca1 Removed own caching solution in favour of django caching
The old multiprocessing support was hard to maintain.
Since signing and caching are part of `django.core`
there is really no need to stick to our own solution.

As a result multimachine support and security are now always in place.
Fields are stored in Django's cache. The default cache used by select2
is called 'default' but can be cachanged overwriting the setting
`SELECT2_CACHE_BACKEND`.

Recommended cache backends are memcached, redis or a DB-cache.

Refactored AutoResponseView

The main reason for this refactoring is
the fact that the pagingnation was slow.

I dropped major parts of the initial code
and wrote a more django-like-approach.

Noteabley:
- get_results now retuns a QuerySet
- This commit drops django 1.6 support in favour of the JsonResponse (Backporting is possible).
2015-09-29 13:53:29 +02:00
Johannes Hoppe 29c74ae63e Fixed version number an changelog 2015-09-25 11:39:04 +02:00
Nirupam Biswas 905f691e01 New release updates 2015-09-25 00:27:03 +05:30
Johannes Hoppe b9400e235b Merge pull request #197 from DMOJ/static-patch
Make static work with CachedStaticFilesStorage
2015-08-27 10:48:53 +02:00
Quantum 5137c043ed Make static work with CachedStaticFilesStorage
`django.templatetags.static.static` doesn't return the hashed URL,
but `django.contrib.staticfiles.templatetags.staticfiles.static` does.
2015-08-26 16:38:26 -04:00
Johannes Hoppe 992ad4de01 Merge pull request #191 from bubenkoff/patch-1
Force unicode for widget choice labels
2015-08-11 16:30:34 +02:00
Anatoly Bubenkov e829422a3f avoid deprecated force_unicode 2015-08-10 14:19:46 +02:00
Anatoly Bubenkov 91160484ac correct force to use unicode 2015-08-10 09:42:08 +02:00
Anatoly Bubenkov d9c4a2cd5a Force unicode for widget choice labels 2015-08-10 09:39:02 +02:00
Johannes Hoppe 66a36c3ea2 Added tests for django master 2015-08-06 10:10:44 +02:00
Johannes Hoppe 4f84f01434 Fixed badges 2015-07-10 10:20:14 +02:00
Johannes Hoppe 68a6f44171 Added badges and moved changelog into separate file
Closed #188
2015-07-10 10:16:50 +02:00