0
0
mirror of https://github.com/wagtail/wagtail.git synced 2024-12-01 11:41:20 +01:00
Commit Graph

6671 Commits

Author SHA1 Message Date
Matt Westcott
2773ffb31a Revert "Split remove_filter_model migration to prevent Postgres errors - fixes #2754"
This reverts commit 87e9c63dbf.
2016-07-29 14:47:15 +01:00
Karl Hobley
2ea14994ff Fixed bug causing nested objects to be mapped with parents mapping class (#2572)
Nested objects that are defined using RelatedFields were being mapped into Elasticsearch using the parent model's mapping.

For example, if we index a page with tags, the tags were being mapped with the Page mapping instead of the Tag mapping.

This doesn't make any difference for Elasticsearch 1, but Elasticsearch 2 needs to prefix fields if there are defined on a child model and it was doing this across the related fields as well.

This fix is covered by the tests coming in the Elasticsearch 2 backend.
2016-07-29 13:16:26 +03:00
Karl Hobley
210b8532d9 [Elasticsearch 2] Make deciding index column names the responsibility of the search backend (#2571)
We need to prefix some fields in Elasticsearch 2 but not Elasticsearch 1. Moving this code into the ElasticsearchMapping class allows us to override it.

It also makes sense to have this sort of thing in the backend rather than the core as other search backends we add in the future may want different behaviour as well.
2016-07-29 12:38:56 +03:00
Karl Hobley
95563dabb7 Added parse_boolean function
This commit adds the ability to use true/false on boolean fields and also validates integers properly
2016-07-29 10:39:48 +03:00
Karl Hobley
6115f84e38 Implement API v2 fields changes (RFC 5) (#2484) 2016-07-28 18:22:11 +03:00
Matt Westcott
5dfcdfb2a6 Release note for #2872 2016-07-28 11:41:12 +01:00
Fábio Macêdo Mendes
a3b850f37e Stop instance-bound descriptors from breaking RoutablePageMixin (#2872)
Fixes #2870
2016-07-28 11:38:02 +01:00
Karl Hobley
e4bb09fd8d Changelog/release note for #2811 2016-07-28 10:06:50 +01:00
Karl Hobley
4c62d8f4a3 Tweaks to the output of the update_index command (#2873) 2016-07-27 17:30:50 +01:00
Matt Westcott
6886e89e41 Tweak wording for include_block tag documentation 2016-07-27 17:04:19 +01:00
Mikalai Radchuk
d696d6bf9f Adds docs for a Jinja2 version of include_block 2016-07-27 16:52:14 +01:00
Matt Westcott
3c5c69138c Mention jinja2 include_block tag in 1.6 release notes 2016-07-27 16:52:14 +01:00
Mikalai Radchuk
c2548c5b30 Tests for a Jinja2 version of heading_block tag
Conflicts:
	wagtail/wagtailcore/tests/test_jinja2.py
2016-07-27 16:52:14 +01:00
Mikalai Radchuk
a6d021d146 A Jinja2 version of {% include_block %} tag 2016-07-27 16:52:14 +01:00
Matt Westcott
ad1f6716c5 Add Sean Muck to contributors 2016-07-27 14:31:01 +01:00
Matt Westcott
751aceb261 Remove now-unnecessary dirty form checks on save/preview shortcuts
Save is handled by the 'is this a form submission' check, and preview was probably
never needed at all (preview opens in a new window and does not unload the page,
unless there's a validation error, which is handled separately)
2016-07-27 14:30:26 +01:00
Matt Westcott
aa9025c798 Make validation errors on formsets trigger the alwaysDirty flag
When the page edit form is redisplayed on validation errors, we set alwaysDirty on the
dirty form handler logic so that navigating away triggers the unsaved changes warning
even if no further changes are made. However, the old code tested `form.errors`, which
fails to catch validation errors originating from formsets.
2016-07-27 14:30:26 +01:00
Matt Westcott
c1a2646b10 Remove ignoredButtonsSelector logic, redundant now that we're checking for a form submit event instead 2016-07-27 14:30:26 +01:00
Sean Muck
45f3bd0a75 Prevent alert after pressing enter while saving page. Fixes #2798 2016-07-27 14:30:26 +01:00
Matt Westcott
321c016433 Fix specificity of login button CSS, to restore large button style.
Thanks to @sebworks for the bug report and investigation!
2016-07-26 17:17:15 +01:00
Matt Westcott
4108e51871 Add Adriaan Tijsseling to contributors 2016-07-26 15:35:22 +01:00
Adriaan Tijsseling
168823c676 item_closing_tag should actually be closing_tag as defined in modeladmin_tags.py (#2868) 2016-07-26 15:34:34 +01:00
Matt Westcott
e9279c8512 Release note for #2663 2016-07-21 16:37:25 +01:00
Matt Westcott
07c3ba84fb Avoid referring to block.field.required, as per https://github.com/torchbox/wagtail/pull/2663/files#r71692451 2016-07-21 13:42:29 +01:00
Matt Westcott
5b2311e1e0 Add test for presence of 'required' class 2016-07-21 13:25:46 +01:00
riceyrice
4a2a1cee5f Add colon after block labels to correspond with colon after field labels 2016-07-21 13:19:08 +01:00
riceyrice
d0288de2f8 Add asterisk after required blocks in StreamField 2016-07-21 13:02:47 +01:00
Matt Westcott
c51177a0fa Release notes for #2858 / #2859 2016-07-21 12:03:53 +01:00
Matt Westcott
71cf921407 Prevent double-escaping of rich text blocks on Jinja2
Fixes #2542. Thanks to @aaugustin for the bug report and patch.
2016-07-21 11:58:08 +01:00
Matt Westcott
6d6da5c1a9 Prevent double-escaping of block template output on Jinja2 - fixes #2541
Thanks to @aaugustin for the report and detailed analysis of the problem!
2016-07-21 11:57:49 +01:00
Matt Westcott
7b9399019b Give Jinja2 templates their own location in testapp
The Jinja2 template config here isn't currently used at all - having
the same APP_DIRS / DIRS config as the Django template engine (which
has higher precedence) means that it will never be selected for
rendering templates, and the existing jinja2 tests bypass Django's
template engine selection and call the jinja2 engine directly.

By giving jinja2 templates their own dedicated location, we can reliably
control which engine is used for which templates.
2016-07-21 11:57:49 +01:00
Matt Westcott
832646eb25 Make WAGTAIL_ROOT point to the actual Wagtail root...
Ever since the test settings got their own file, this has pointed to
the 'tests' folder instead. Luckily this had no ill effects, since
it's only used as the base for the temporary STATIC_ROOT / MEDIA_ROOT
folders.
2016-07-21 11:57:49 +01:00
Chris Darko
bd226fcedf Fix use of Page instead of specific_class
Uses specific_class.url instead of Page.url for getting the 'view_live' URL
in the success message following Page publication.
2016-07-21 11:55:10 +01:00
Karl Hobley
23ee8c923b [Elasticsearch 2] Rewrote update_index command to support rebuilding multiple indices in the same backend (#2570)
* Added get_index_for_model method to Elasticsearch

* Rewrote update_index command to support rebuilding multiple indices
2016-07-20 14:31:42 +01:00
Karl Hobley
3f457f853a [Elasticsearch 2] Renamed search backend classes (#2569)
* Renamed search backend classes

* DBSearch => DatabaseSearch

* ElasticSearchBackend => ElasticsearchSearchBackend

This probably looks a little funny. I need to inject the number 2 into this name somewhere for the Elasticsearch 2 backend. I think Elasticsearch2SearchBackend is the best name so need rename the current backend for consistency.

* Deprecation warning for referencing renamed backend in settings
2016-07-20 10:54:29 +01:00
Tom Dyson
703c9984c6 Make /admin a link in the Getting Started tutorial 2016-07-20 09:41:03 +01:00
Tom Dyson
32f7ed8ac1 wagtail->Wagtail in wagtail start output (#2856) 2016-07-20 01:08:12 +01:00
Gagaro
16c279d705 fix: #1735 Unable to use models with a StreamField inside Inline Panels 2016-07-19 19:32:16 +01:00
Matt Westcott
7d8c7ec758 Add 'issue tracking' docs (#2794) 2016-07-19 16:17:54 +01:00
Karl Hobley
e592cbf65c Implement support for ordering and searching at the same time over the API (#2732)
When the API was originally created, this was not possible to do with Wagtail search. So I added a check to prevent people from doing it.

Custom ordering was implemented in Wagtailsearch in #1815 so this can now be switched on.
2016-07-19 16:09:41 +01:00
Matt Westcott
e3483a8bd3 Add 'download' attribute to document download links (#2808)
Partially fixes #2513 - Firefox and Chrome (and hopefully Edge >=13) do not trigger
onbeforeunload events when following these links. Safari and IE don't currently
support it, though.
2016-07-19 16:05:46 +01:00
Karl Hobley
d9a3d5200f Django 1.11: Added ALLOWED_HOSTS to a few tests (#2853)
ALLOWED_HOSTS is now required in tests. See: 17e661641d
2016-07-19 15:26:26 +01:00
Karl Hobley
290c786c02 rollback to Drone 0.4
Should solve the reliability issues
2016-07-19 15:20:29 +01:00
Matt Westcott
f5cc8a3f2a Remove dubious GroupForm test that fails on Django 1.10rc1 (#2854)
test_group_form_includes_non_registered_permissions_in_initial_data fails in
Django 1.10rc1 because the native value of a ManyToManyField (as reflected in
form.initial) is now a queryset rather than a list of PKs. However, this test
is not actually testing anything meaningful. It asserts that the initial
value of the 'permissions' field includes any permissions the group has which
are not included in registered_permissions; however, since these permissions
don't appear in the form, it's inconsequential whether they're included or not.
2016-07-19 15:12:57 +01:00
Karl Hobley
ef56a3ebcb Fixed search tests (#2850)
A test was mutating the search_fields attribute of the SearchTest model causing subsequent tests that depended on the previous value to fail.
2016-07-19 13:24:32 +01:00
Matt Westcott
15ef4fcca7 Revert "Elasticsearch: Replaced usage of index_analyzer (#2568)"
This reverts commit d14150eb43.
2016-07-19 12:12:48 +01:00
Matt Westcott
0714cddd54 Release note for #2848 2016-07-19 10:45:19 +01:00
Danielle Madeley
e128921cfb Support https links for Flickr (#2848) 2016-07-19 10:37:16 +01:00
Matt Westcott
d3bdd64cc5 Add release notes for 1.5.3
Conflicts:
	CHANGELOG.txt
	docs/releases/index.rst
2016-07-18 19:15:27 +01:00
Matt Westcott
0308795490 Add release notes for 1.4.6
Conflicts:
	CHANGELOG.txt
	docs/releases/index.rst
2016-07-18 19:14:28 +01:00