Fix check for `delete_url_name` attribute in generic `DeleteView`

Fixes #9861
pull/9864/head
Matt Westcott 2023-01-09 13:32:08 +00:00 zatwierdzone przez Matt Westcott
rodzic fb4837371f
commit b0259a4990
4 zmienionych plików z 4 dodań i 1 usunięć

Wyświetl plik

@ -54,6 +54,7 @@ Changelog
* Fix: Close the userbar when clicking its toggle (Albina Starykova)
* Fix: Add a border around the userbar menu in Windows high-contrast mode so it can be identified (Albina Starykova)
* Fix: Make sure browser font resizing applies to the userbar (Albina Starykova)
* Fix: Fix check for `delete_url_name` attribute in generic `DeleteView` (Alex Simpson)
* Docs: Add custom permissions section to permissions documentation page (Dan Hayden)
* Docs: Add documentation for how to get started with contributing translations for the Wagtail admin (Ogunbanjo Oluwadamilare)
* Docs: Officially recommend `fnm` over `nvm` in development documentation (LB (Ben) Johnston)

Wyświetl plik

@ -680,6 +680,7 @@ Contributors
* dr-rompecabezas
* Rishabh jain
* Jhonatan Lopes
* Alex Simpson
Translators
===========

Wyświetl plik

@ -78,6 +78,7 @@ This feature was developed by Jake Howard.
* Close the userbar when clicking its toggle (Albina Starykova)
* Add a border around the userbar menu in Windows high-contrast mode so it can be identified (Albina Starykova)
* Make sure browser font resizing applies to the userbar (Albina Starykova)
* Fix check for `delete_url_name` attribute in generic `DeleteView` (Alex Simpson)
### Documentation

Wyświetl plik

@ -652,7 +652,7 @@ class DeleteView(
return str(self.object)
def get_delete_url(self):
if not self.index_url_name:
if not self.delete_url_name:
raise ImproperlyConfigured(
"Subclasses of wagtail.admin.views.generic.models.DeleteView must provide a "
"delete_url_name attribute or a get_delete_url method"