Commit Graph

5511 Commits

Author SHA1 Message Date
Mariusz Felisiak 4bb30fe5d5 Refs #26601 -- Made get_response argument required and don't accept None in middleware classes.
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak 6b4941dd57 Refs #27468 -- Removed support for the pre-Django 3.1 user sessions.
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak 8250145a0c Refs #31274 -- Removed support for the pre-Django 3.1 encoding format of sessions.
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak 66b4046d68 Refs #27468 -- Removed support for the pre-Django 3.1 password reset tokens.
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak 831a05b185 Refs #27604 -- Removed support for the pre-Django 3.1 encoding format in CookieStorage.
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak d134b0b93e Refs #15902 -- Stopped set_language() storing user's language in the session.
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Matthias Kestenholz 257dfce6c8
Refs #31259 -- Improved some color contrasts for admin dark theme. 2021-01-14 14:06:02 +01:00
Jon Moroney 76ae6ccf85 Fixed #31358 -- Increased salt entropy of password hashers.
Co-authored-by: Florian Apolloner <florian@apolloner.eu>
2021-01-14 11:20:28 +01:00
mimi89999 b5cef91a91 Fixed #31259 -- Added admin dark theme. 2021-01-14 08:27:29 +01:00
Florian Apolloner 64cc9dcdad Refs #31358 -- Added constant for get_random_string()'s default alphabet. 2021-01-13 20:40:40 +01:00
Nick Pope 9204485396
Fixed #16117 -- Added decorators for admin action and display functions.
Refs #25134, #32099.
2021-01-13 17:19:22 +01:00
Hannes Ljungberg 83fcfc9ec8 Fixed #26167 -- Added support for functional indexes.
Thanks Simon Charette, Mads Jensen, and Mariusz Felisiak for reviews.

Co-authored-by: Markus Holtermann <info@markusholtermann.eu>
2021-01-13 11:47:50 +01:00
Tim Graham e3ece0144a Removed redundant database vendor helpers in gis_tests/utils.py. 2021-01-13 09:22:44 +01:00
Tim Graham 9f91122ed8 Added SpatialFeatures.empty_intersection_returns_none. 2021-01-13 09:22:44 +01:00
Jon Dufresne ba31b01034
Fixed #31747 -- Fixed model enumeration via admin URLs.
Co-authored-by: Carlton Gibson <carlton.gibson@noumenal.es>
2021-01-12 14:37:56 +01:00
Johannes Maron 3071660acf
Fixed #29010, Fixed #29138 -- Added limit_choices_to and to_field support to autocomplete fields.
* Fixed #29010 -- Added limit_choices_to support to autocomplete fields.
* Fixed #29138 -- Allowed autocomplete fields to target a custom
  to_field rather than the PK.
2021-01-12 11:37:38 +01:00
Michel Le Bihan 16d27fb806
Refs #32018 -- Corrected color variables for paginator and header links in admin.
Follow up to cd3019bc10.
2021-01-12 06:34:25 +01:00
Michel Le Bihan cd3019bc10
Refs #32018 -- Used --header-link-color for header links in admin. 2021-01-11 11:42:59 +01:00
Florian Apolloner 2d6179c819 Fixed #32191 -- Made CookieStorage use RFC 6265 compliant format.
Co-authored-by: Craig Smith <hello@craigiansmith.com.au>
2021-01-07 13:00:53 +01:00
Matthias Kestenholz 0a802233ec
Fixed #32018 -- Extracted admin colors into CSS variables.
Defined all colors used in the admin CSS as variables. Implemented the
following standardizations and accessibility improvements while at it:

- Improved the contrast of text to not use ratios of less than 3:1 anymore.
- Most hover states already used desaturated and darkened colors.
  Changed object tools to follow the same rule instead of showing the
  primary color on hover.

Various places used similar colors; those have been merged with the goal
of reducing the count of CSS variables. Contrasts have been improved in
a few places.

- Many borders used slightly different colors (e.g. #eaeaea vs. #eee)
- Help texts used #999, this has been changed to --body-quiet-color
  (#666) which has a better contrast.

Introduced fast color transitions on links and buttons.
2021-01-07 10:07:19 +01:00
Viktor Grabov 6a054f7681
Fixed #32322 -- Fixed autocomplete widget wrapping. 2021-01-06 09:32:13 +01:00
Tim Graham 060e6bdd1f
Replaced DatabaseFeatures.supports_left_right_lookups with skipUnlessGISLookup. 2021-01-02 21:39:48 +01:00
Mariusz Felisiak ce30e750e6
Used model's Options.label where applicable.
Follow up to b7a3a6c9ef.
2020-12-29 08:56:39 +01:00
Florian Apolloner c76d51b3ad Refs #31358 -- Fixed decoding salt in Argon2PasswordHasher.
Argon2 encodes the salt as base64 for representation in the final hash
output. To be able to accurately return the used salt from decode(),
add padding, b64decode, and decode from latin1 (for the remote
possibility that someone supplied a custom hash consisting solely of
bytes -- this would require a manual construction of the hash though,
Django's interface does not allow for that).
2020-12-28 11:02:08 +01:00
Florian Apolloner 1b7086b2ea Refs #31358 -- Simplified Argon2PasswordHasher.must_update() by using decode(). 2020-12-28 11:02:03 +01:00
François Freitag b11ec9a69e Fixed #32301 -- Made clearsessions raise CommandError when clear_expired() is not implemented. 2020-12-28 09:30:16 +01:00
Hannes Ljungberg d23cb83c99 Refs #26167 -- Made DatabaseSchemaEditor._create_index_sql()'s fields argument optional and kwarg-only. 2020-12-23 11:16:13 +01:00
Tom Forbes b5e12d490a Fixed #31007 -- Allowed specifying type of auto-created primary keys.
This also changes the default type of auto-created primary keys
for new apps and projects to BigAutoField.
2020-12-15 11:25:46 +01:00
Hasan Ramezani 275dd4ebba
Fixed #32178 -- Allowed database backends to skip tests and mark expected failures.
Co-authored-by: Tim Graham <timograham@gmail.com>
2020-12-10 18:00:57 +01:00
Timo Ludwig d8dfff2ab0 Fixed #32235 -- Made ReadOnlyPasswordHashField disabled by default. 2020-12-03 09:32:08 +01:00
Tim Graham 371022a20d
Added SpatialFeatures.supports_tolerance_parameter. 2020-11-30 07:29:00 +01:00
Mariusz Felisiak 3828427f63 Refs #31978 -- Fixed hint in admin's password reset confirmation form for custom username fields.
Thanks Jaap Roes for the report.
2020-11-30 06:34:22 +01:00
Giannis Adamopoulos 7603036bd0 Fixed #21021 -- Changed BaseGeometryWidget's default geometry type to 'Geometry'. 2020-11-28 09:14:40 +01:00
Mariusz Felisiak 931c6e982c Refs #32230 -- Made LayerMapping support pathlib.Path. 2020-11-28 07:41:54 +01:00
Hasan Ramezani b37be072a2 Fixed #32230 -- Made DataSource support pathlib.Path. 2020-11-28 07:36:19 +01:00
Hannes Ljungberg 33403bf80f Refs #27095 -- Allowed (non-nested) arrays containing expressions for ArrayField lookups. 2020-11-26 10:57:58 +01:00
Author: Nick Pope 20f2b822f8 Added explicit HTMLElement.dir attribute in templates. 2020-11-20 11:09:46 +01:00
Florian Apolloner d10425f9c7 Simplified MessageEncoder instantiation with default separators. 2020-11-20 10:27:09 +01:00
Nick Pope 67a1ae68a8
Refs #24474 -- Changed AdminSite.empty_value_display property to an attribute.
This was implemented with a property getter and setter when introduced
in 0207bdd2d4.

There is nothing special occurring here though - a simple read from and
assign to the underlying private attribute.
2020-11-14 07:24:07 +01:00
Nick Pope fed8129276
Unified admin action description generation.
Actions added to AdminSite.actions would not have the first character
of their description capitalized.

Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-11-13 21:41:18 +01:00
Tim Graham c9e8544321
Added SpatialFeatures.unsupported_geojson_options. 2020-11-11 07:39:15 +01:00
Claude Paroz 187482d743
Avoided direct styles in admin templates.
Direct styles might be forbidden by Content Security Policies.
2020-11-10 21:32:15 +01:00
Tim Graham dbb4a86fa7 Renamed BaseSpatialOperations.geography to BaseSpatialFeatures.supports_geography. 2020-11-09 08:12:00 +01:00
Tim Graham 69ffaa297c Removed BaseSpatialOperations.geometry.
Unused since 26996e2d55.
2020-11-09 07:57:02 +01:00
Artur Beltsov 18c8ced81e Fixed #32169 -- Added distinct support to JSONBAgg. 2020-11-04 21:22:54 +01:00
Martin Thoma 302caa40e4 Made small readability improvements. 2020-10-28 20:20:20 +01:00
Hasan Ramezani 4eb756793b
Refs #28215 -- Marked auth credentials as sensitive variables.
Co-authored-by: Collin Anderson <collin@onetencommunications.com>
2020-10-28 14:21:53 +01:00
Gagan Deep 982e860b73 Fixed #32062 -- Added %b support to Date.strftime.
This enables the admin to display the month as locale's abbreviated
name if %b is used in the date format.
2020-10-28 11:11:37 +01:00
Josh Santos 36bc47069c Fixed #32127 -- Fixed admin change-form textarea layout for mid-sized displays. 2020-10-27 16:06:11 +01:00
Carlton Gibson e17ee44688 Fixed #32128 -- Added asgiref 3.3 compatibility.
Thread sensitive parameter is True by default from asgiref v3.3.0.
Added an explicit thread_sensitive=False to previously implicit uses.
2020-10-27 11:24:07 +01:00