0
0
mirror of https://github.com/wagtail/wagtail.git synced 2024-11-29 17:36:49 +01:00
Commit Graph

36 Commits

Author SHA1 Message Date
LB Johnston
995809a318 Adopt data attribute usage of SwapController (w-swap) for all header searches
- Removes six inline scripts completely, no longer relying on window.headerSearch
- Update the fallback Stimulus Swap controller afterLoad to be a deprecated method
- Add upgrade considerations
- Fix regression from d554cbe310 where manually submitting page search results would load the partial, not full page response
- Closes #9950
2023-07-18 07:09:28 +10:00
Sage Abdullah
0bebe532e8 Add docs and tests for snippets inspect view 2023-07-17 17:19:11 +01:00
Sage Abdullah
0550b03dad
Allow customising the spreadsheet file name via SnippetViewSet.export_filename 2023-07-12 09:18:11 +01:00
Sage Abdullah
428b7914e2
Add docs and tests for exporting snippets listing 2023-07-12 09:18:09 +01:00
Sage Abdullah
6ec734f836 Add separate headings for each snippets view customisation 2023-05-24 11:06:00 +01:00
Sage Abdullah
7ba2098d1a Add docs and tests for grouped snippets registration 2023-04-19 15:13:42 +01:00
Sage Abdullah
5fb4d6316f Allow SnippetViewSet.model to be defined directly on the class 2023-04-19 15:13:42 +01:00
Sage Abdullah
dde58c718d Add docs and tests for separate menu item registrations for Snippets 2023-04-19 15:13:42 +01:00
Sage Abdullah
66c0ef48e9 Add docs for setting panels/edit_handler on SnippetViewSet 2023-04-19 13:24:17 +01:00
Sage Abdullah
167471b1f7 Allow customising the search_fields and search backend to use via SnippetViewSet (#10290) 2023-04-18 00:06:09 +01:00
Sage Abdullah
3965ceedfa Allow default ordering of Snippets IndexView to be specified via SnippetViewSet (#10276) 2023-04-17 23:58:20 +01:00
Sage Abdullah
87cbf01894 Add docs and tests for overriding SnippetViewSet.get_queryset() 2023-04-14 12:34:11 +01:00
Sage Abdullah
dc6c0b0949 Allow overriding SnippetViewSet template prefix 2023-04-13 17:53:58 +01:00
Sage Abdullah
f2ab3ae774 Add docs and tests for Snippets template overrides 2023-04-13 17:53:58 +01:00
Sage Abdullah
1992c72791 Add missing docs for chooser_viewset_class 2023-04-13 17:53:58 +01:00
Sage Abdullah
bcbaafd116 Add docs and tests for snippets listing filters via list_filter 2023-04-03 10:24:30 +02:00
Sage Abdullah
f533ab219d Allow customising the number of snippets per page on the listing view 2023-03-23 14:15:42 +00:00
Sage Abdullah
b713a1753e Allow admin URL customisation for snippet chooser views via SnippetViewSet 2023-03-23 13:54:59 +00:00
Sage Abdullah
e6d920d435 Add docs and tests for snippets admin URL customisation 2023-03-23 13:54:49 +00:00
Daniel Kirkham
198388bf55 Add docs and tests for customising snippet icons 2023-03-22 15:15:30 +00:00
Matt Westcott
c5513d098a Implement mechanism to pass the 'multiple' URL parameter (and any other specified ones) on links / form actions within generic chooser modal 2023-01-18 14:31:08 +00:00
Matt Westcott
3872de44d7 Add chooser view endpoints for returning multiple results
Extend the existing 'chosen' view so that it returns a single-item list when the URL parameter `multiple` is passed, and add a 'chosen_multiple' view that accepts multiple `id` URL parameters and returns the corresponding results as a list.
2023-01-18 14:31:08 +00:00
Sage Abdullah
1952ecbb63
Add the ability to lock snippets that extend LockableMixin 2022-12-14 11:10:14 +00:00
Sage Abdullah
0a0bd30fad Allow customising snippet listing columns with list_display 2022-09-28 10:39:48 +01:00
Sage Abdullah
a7249a851f Document SnippetViewSet and how to customise it 2022-09-27 10:18:18 +01:00
Matt Westcott
9aeb2e3e49 Ensure telepath adapter gets registered for document chooser widget
Fixes #9010. `wagtail.documents.widgets` is no longer reliably imported on startup now that the chooser widget is constructed within wagtail.documents.views.chooser instead, so the telepath adapter wasn't getting register. This meant that DocumentChooserBlocks in StreamField were using the base chooser implementation, which didn't include customisations such as populating the title field from the file upload field. Fix this by making ChooserViewSet responsible for registering the telepath adapter.
2022-08-17 18:24:18 +01:00
Matt Westcott
b4bc681865 Fix DocumentChooserBlock deconstruction for custom document models
Fixes #8989. The previous fix #9004 failed for custom document models because ChooserViewset assigns an internal name for the ChooserBlock class based on the model name, and if this is anything other than Document it won't match the name DocumentChooserBlock that it's exposed under in wagtail.documents.blocks. Fix this by replacing the `block_class` property with a `get_block_class` method that lets us specify the class name. As a bonus, user code that defines chooser blocks no longer has to directly hack the `__module__` attribute.
2022-08-16 20:50:04 +01:00
Matt Westcott
f9fe6d0ca8 Documentation for generating chooser blocks via ChooserViewSet 2022-08-10 14:53:41 +10:00
Matt Westcott
161dd69c8a Implement generating a StreamField ChooserBlock from ChooserViewSet 2022-08-10 14:53:41 +10:00
Matt Westcott
02d836fe3e Make per_page configurable on viewsets 2022-08-05 08:34:14 +10:00
Matt Westcott
30054eda39 Add a 'create' view with a GET request handler 2022-07-04 13:48:35 +01:00
Matt Westcott
4dd3483617 Add a (non-functional) 'create' form to generic chooser modal 2022-07-04 13:48:35 +01:00
Matt Westcott
372965ef6a Put headers in markdown rather than rst 2022-06-12 15:47:24 +10:00
Matt Westcott
865df1153b Documentation for ChooserViewSet 2022-06-12 15:47:24 +10:00
Matt Westcott
b00d19b3a0 Documentation for ModelViewSet 2022-06-12 15:47:24 +10:00
Matt Westcott
b4d3cf1c30 Docs for base ViewSet class 2022-06-12 15:47:24 +10:00