0
0
mirror of https://github.com/wagtail/wagtail.git synced 2024-11-29 09:33:54 +01:00
Commit Graph

1550 Commits

Author SHA1 Message Date
Mikalai Radchuk
fb93a6d6b9 Allow to limit access to form submissions (#3016)
Add the filter_form_submissions_for_user hook

Thanks @kaedroho for the code review and docs.
2016-09-22 14:36:39 +03:00
Karl Hobley
9a57e39cfd Implemented annotate_score on SearchResults
This allows the user to retrieve the scores for each search result:

    for page in Page.objects.search("Hello").annotate_score('_score'):
        print(page.title, page._score)
2016-09-22 12:03:23 +01:00
Nick Smith
504759d267 #1446 add pagination to wagtailadmin.views.pages.move_choose_destination 2016-09-22 11:53:38 +01:00
Karl Hobley
ebe597610e API v2 docs (#2940) 2016-09-22 11:15:18 +01:00
Mikalai Radchuk
ae33f7192d Adds "Supported versions of Django"
Adds "Supported versions of Django" section
into "Wagtail's release process" document.
2016-09-21 18:50:44 +01:00
Mikalai Radchuk
d3568df5b3 Adds docs about release process 2016-09-21 18:50:21 +01:00
Karl Hobley
9d655a9f8a Changelog/release note for #2975 2016-09-21 13:33:13 +01:00
Stein Strindhaug
ffa21943d0 Increase legibility by increasing contrast
Raise contrast by slightly adjusting font-weight, color and font size (from 12.2px to 12.8px in the menu)
2016-09-21 12:02:23 +01:00
Matt Westcott
8dc1d9c342 Document the steps for creating a filter_spec migration for a custom image model 2016-09-20 15:38:36 +01:00
Mikalai Radchuk
b1d10db7f2 Release notes for #3002 2016-09-19 19:31:37 +03:00
Matt Westcott
89f4699a91 Fix underlines 2016-09-19 13:51:04 +01:00
Matt Westcott
86e60fd4a3 Mention where to access the styleguide - fixes #3009 2016-09-19 13:49:52 +01:00
Matt Westcott
c6666c6de5 Disable escape key on rich text fields - fixes #2998 2016-09-16 15:19:12 +01:00
Matt Westcott
8aa316c575 Correct description of 'title' class on FieldPanel - fixes #2990 2016-09-15 17:02:25 +01:00
Matt Westcott
b0aa210078 Recognise classname parameter on InlinePanel. Fixes #1316 2016-09-15 16:44:51 +01:00
Karl Hobley
4dc1ef05f8 Removed unused import from example
Thanks @timheap for spotting
2016-09-15 09:18:04 +01:00
Matt Westcott
a7af8f7da3 Release note for #2997 2016-09-14 16:54:02 +01:00
Karl Hobley
8b9b2ced36 Docs for new hooks 2016-09-14 16:52:28 +01:00
Matt Westcott
3b4c24e0b5 Release note for #2619 2016-09-08 12:10:53 +01:00
Matt Westcott
6c57aba8a2 Mark 1.7 as in development 2016-09-06 14:46:13 +01:00
Matt Westcott
1181a4ea8e Add content_panels declarations to i18n duplicate tree example code - fixes #2981 2016-09-06 10:44:33 +01:00
Tobias
ceec8c2d9f Update settings.rst
Fix typo.
2016-09-05 14:24:33 +02:00
Matt Westcott
29e7c0740b Release note for #2971 2016-09-05 11:48:26 +01:00
Luiz Boaretto
24feca5333 Fix typo on modeladmin docs 2016-09-04 12:43:39 -03:00
Matt Westcott
1d5475672e Release note for #2577 2016-09-01 16:20:57 +01:00
dirtycoder
959723eddb Create a panel to display informations about the submissions for form pages, fix #406 2016-09-01 15:22:30 +01:00
Matt Westcott
57b7f4b56e Release note for #2963 2016-09-01 15:07:05 +01:00
Janneke Janssen
722ea1d3d8 Update the docs for the custom image model to mention post_delete instead of pre_delete 2016-09-01 15:07:05 +01:00
Mikalai Radchuk
8a41baa87d Release notes for #2966 2016-09-01 17:02:55 +03:00
Mikalai Radchuk
7c3b38ad40 Move release notes for #2573 to the top
[skip ci]
2016-08-31 14:57:59 +03:00
Mikalai Radchuk
5598910a2b Release notes for #2573 2016-08-31 14:13:47 +03:00
Karl Hobley
daa82936d7 Elasticsearch 2 support (#2573)
* Created Elasticsearch 2 backend

* Added tests for Elasticsearch 2 backend

* Split models up into different indices

pages, images and documents are now in separate indices

* Prefix fields of child models to prevent mapping clashes

* Replaced index_analyzer with analyzer/search_analyzer

index_analyzer has been removed in Elasticsearch 2.0

https://www.elastic.co/guide/en/elasticsearch/reference/current/breaking_20_mapping_changes.html#_analyzer_mappings

There's no indication in Elasticsearch's docs that this wouldn't work on Elasticsearch 1.x. However, we found that the new configuration isn't reliable on Elasticsearch 1.6 and below (causes the test_query_analyzer test to fail randomly).

* Implemented new way of representing content types in search index

Instead of using a long string of model names that is queried using a
"prefix" query, we instead use a multi-value string field and query it
using a simple "match" query.

The only reason why this isn't implemented in the Elasticsearch 1.x
backend yet is backwards compatibility

* Added another child model of SearchTest with clashing field mapping

This checks that the namespacing of fields on child models is working properly (if it doesn't the update_index tests will fail)

* Added tests for get_model_root function

* fixup! Added tests for get_model_root function

* Docs updates for Elasticsearch 2 support

Also tweak examples to use elasticsearch2 backend by default

* Test against Elasticsearch 2 on travis
2016-08-31 13:46:57 +03:00
Karl Hobley
e29f9b2423 No longer say that ATOMIC_REBUILD is "Experimental"
We've used this in production on a few sites for over a year now and haven't hit any problems.
2016-08-31 09:54:35 +01:00
Matt Westcott
ae947642cd release note for #2562 2016-08-30 15:09:26 +01:00
Robert Rollins
f6b47235a3 Fixes the javascript error that was breaking the userbar on touch devices. 2016-08-30 12:22:59 +01:00
Matt Westcott
e6c0d4f33e Fix spelling of Janssen 2016-08-30 11:03:28 +01:00
Matt Westcott
73fd2d8820 Make indenting of bullet points consistent 2016-08-30 11:00:02 +01:00
Matt Westcott
f9f8399602 Release note for #2955 2016-08-30 10:59:14 +01:00
Karl Hobley
cdcdb4a4cd Update frontendcache.rst 2016-08-29 16:38:26 +01:00
Karl Hobley
692c4017f9 Changelog and release note for #1845 2016-08-29 15:24:53 +01:00
Rob Moorman
df45c215a2 Added support for AWS CloudFront in Frontend cache invalidation module (#1845)
* added base cloudfrontbackend and testcase

* added boto3 cloudfront client

* implemented create invalidation method
added error handling botocore

* added aws docs

* fixed typo

* flake8 fixes

* added boto3 configuration docs

* removed return

* purge path instead of full url

* added multisite hostname mapping

* added validation of DISTRIBUTION_ID

* renamed Cloudfront to CloudFront

* added note to include www in mapping
added tests for cloudfront site mapping

* removed deprecated has_key, used in
fixed _create_invalidation

* changed type checking of dict
removed debug line of code to check hostname

* fixed dict type checking condition
added assert t make sure no invalid cache is being purged

* changed import order

* fixed isort error

* more detailed error message for cloudfront
pep8 fixes 120 chars per line

* Log missing cloudfront distribution id as info

Was logging as error, but it may be possible that a developer wants cloudfront on only specific hostnames.

* , => .

* Docs edits

* Removed hard-dependency on boto3
2016-08-29 15:15:27 +01:00
Matt Westcott
36089e5723 Mention WAGTAIL_ALLOW_UNICODE_SLUGS setting in release notes 2016-08-26 16:23:31 +01:00
Matt Westcott
205e22cc55 Mark 1.6.1 as no longer in development 2016-08-26 11:28:46 +01:00
Mikalai Radchuk
b37e8ccbcf Change method name to AbstractEmailForm.send_mail
Also contails release notes for #2926
2016-08-26 12:06:23 +03:00
Mikalai Radchuk
c40ab3596a Release notes for #2942 2016-08-26 10:49:40 +03:00
Mikalai Radchuk
9b81d3b667 Release notes for #2937 2016-08-25 19:03:47 +03:00
Matt Westcott
fc308c9ced Add setting to disable Unicode slug support #2937
* Ship our own copies of urlify.js and xregexp.min.js

This avoids issues with missing files when using Django 1.8 or omitting django.contrib.admin from INSTALLED_APPS (#2927), and guards against any breaking changes to these files in future Django releases.

* Add a WAGTAIL_ALLOW_UNICODE_SLUGS setting
2016-08-25 19:03:37 +03:00
Janneke Janssen
603962146b Added documentation for editors to configure redirects 2016-08-25 11:18:55 +01:00
Elwin Buisman
fd8f4b22fb Bumped supported Django version to 1.10
Bumped supported Django version to 1.10 according to requirements in setup.py
2016-08-25 10:09:08 +01:00
Matt Westcott
9111483dec Force ChoiceBlock.get_searchable_content to text - fixes #2928 2016-08-24 18:48:10 +01:00
Matt Westcott
7bc819640d Restore PageManager behaviour by setting it on an abstract superclass of Page
Django's standard behaviour is to preserve managers that are set on abstract
superclasses, so this allows us to eliminate the metaclass hackery.

Fixes #2933
2016-08-23 20:12:22 +01:00
Karl Hobley
bfff095f8a Fixed minor formatting error in 1.6.1 release notes 2016-08-23 12:58:11 +01:00
Karl Hobley
7288644932 Changelog/release note for #2895 2016-08-23 12:56:27 +01:00
Karl Hobley
230f6eab5d Changelog/release note for #2922 2016-08-23 11:56:02 +01:00
David Burke
db54a9f0c4 Update IntegerBlock docs to show correct kwargs (#2930)
It should be max and min value - not length. See [here](07c3ba84fb/wagtail/wagtailcore/blocks/field_block.py (L306)).

So this would work 

`blocks.IntegerBlock(max_value=10, min_value=0)`

but this wouldn't do anything

`blocks.IntegerBlock(max_length=10, min_length=0)`
2016-08-20 02:38:00 +01:00
Mikalai Radchuk
f804174666 Marks names of default formats for translations 2016-08-18 20:43:17 +01:00
Matt Westcott
7c9dc029c7 Release note for #2877 2016-08-18 12:05:33 +01:00
Tim Heap
75e58efab8 Move version from wagtail.wagtailcore to wagtail
This is where developers expect it to be, similar to Django and other
projects. The version info still exists at the old `wagtail.wagtailcore`
location, for backwards compatibility.

Fixes #2557
2016-08-18 12:05:33 +01:00
Tim Heap
948cc5190d Use new VERSION tuple to build docs version 2016-08-18 12:05:33 +01:00
Matt Westcott
197d85ce9f Disable client-side validation on Django 1.10 for multipart forms
Client-side validation fails on forms with prefilled file upload fields -
see https://code.djangoproject.com/ticket/27037. This is fixed in Django 1.10.1,
so as a workaround we disable client-side validation (using the 'novalidate'
attribute) for forms with enctype="multipart/form-data" on Django 1.10 only.

Fixes #2897
2016-08-15 18:36:11 +01:00
Matt Westcott
e39fb5646c Release note for #2534 2016-08-11 12:04:10 +01:00
Matt Westcott
20df607918 Remove deprecated wagtail.wagtailimages.utils module 2016-08-09 20:11:31 +01:00
Matt Westcott
9080636903 Version-bump to start work on 1.7 2016-08-09 16:22:14 +01:00
Matt Westcott
bc7739e104 Add usage examples for EmailBlock, IntegerBlock, DecimalBlock
Thanks to @OktayAltay for the original pull request.
2016-08-08 20:15:45 +01:00
Mikalai Radchuk
fcea4ee30d Update "Upgrade considerations" for 1.6 (#2896)
`AbstractFormField.to_address` also requires migration.
We need to mention it in "Upgrade considerations" for Wagtail 1.6

[skip ci]
2016-08-08 14:56:36 +01:00
anatoly techtonik
b3ab3c4e02 Add another tutorial (#2894) 2016-08-05 11:20:55 +03:00
Tom Dyson
5ce99e85c4 credit Caltech (#2885) 2016-08-02 17:10:43 +01:00
Matt Westcott
7eed879c6f Revert "Mark Django 1.10 support as provisional"
This reverts commit 0384a18f37.
2016-08-02 16:11:38 +01:00
Matt Westcott
0384a18f37 Mark Django 1.10 support as provisional 2016-08-01 15:02:01 +01:00
Matt Westcott
36564ac0fa Version bump for 1.6rc1 2016-08-01 14:37:01 +01:00
Matt Westcott
ca02019404 Release note for #2838 2016-08-01 13:07:25 +01:00
Matt Westcott
43269fd763 Release note for #2869 2016-08-01 13:00:36 +01:00
Matt Westcott
043db8549d Release note for #2879 2016-08-01 11:36:02 +01:00
Eraldo Energy
1a956be2f2 Added file handling to support custom user add/edit forms. 2016-07-29 17:02:31 +01:00
Matt Westcott
cceb216536 Fix --schema-only to not expect an argument - fixes #2788 2016-07-29 16:41:28 +01:00
Matt Westcott
5dee12508d Mark django-medusa as no longer maintained 2016-07-29 15:54:52 +01:00
Matt Westcott
28c8ae3ab9 Revert "Refactor: remove Filter as a Django model."
This reverts commit 4d7bdfd160.

Conflicts:
	CHANGELOG.txt
	docs/releases/1.6.rst
2016-07-29 14:49:01 +01:00
Matt Westcott
5dfcdfb2a6 Release note for #2872 2016-07-28 11:41:12 +01:00
Karl Hobley
e4bb09fd8d Changelog/release note for #2811 2016-07-28 10:06: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
Matt Westcott
e9279c8512 Release note for #2663 2016-07-21 16:37:25 +01:00
Matt Westcott
c51177a0fa Release notes for #2858 / #2859 2016-07-21 12:03:53 +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
Tom Dyson
703c9984c6 Make /admin a link in the Getting Started tutorial 2016-07-20 09:41:03 +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
Matt Westcott
0714cddd54 Release note for #2848 2016-07-19 10:45:19 +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
Nik Nyby
389317c104 docs: fix typo (#2845) 2016-07-15 21:58:47 +03:00
Matt Westcott
bdd80dd33e Fix styling of email fields in AbstractEmailForm example (#2821)
classname="full" is incorrect here (it generates excessive padding); also, using a FieldRowPanel
can make the display neater.
2016-07-08 16:47:54 +03:00
Mikalai Radchuk
07ac5aa8ee Release notes for #2830 2016-07-08 16:15:19 +03:00
Matt Westcott
be1e1927c5 Promote include_block and unicode page slugs to major features 2016-07-07 11:20:43 +01:00
Robert Rollins
cbabc3d9c7 Page.dummy_request() now takes an optional request object argument.
When building a dummy request, you can now pass in the original request object
to add additional information to the dummy. Currently, that includes the
following headers:
REMOTE_ADDR
HTTP_X_FORWARDED_FOR
HTTP_COOKIE
HTTP_USER_AGENT

More may be added later.

This changes ensures that middleware which work on the client IP aren't flumuxed
by its absense, and also makes it possible for previews to be rendered as the
logged in user (they had previously been rendered using an AnnonymousUser).

Because the user's logged in state is now detectable in a Page previews, the
Wagtail userbar now hides itself explicitly during previews, rather than relying
on the fact that previews used to be built with AnonymousUser.
2016-07-06 20:28:05 +01:00
Vincent Audebert
14919f3b41 Possibility to delete a user #2371
As mentioned in the comments I didn't see the first pull request (https://github.com/torchbox/wagtail/pull/2509)
However, I think my changes were a tiny bit more complete in terms of UI/UX. I allow to delete a user directly from the user list + you can delete any user if you are superuser, except yourself. This way we are sure to keep at least one superuser but we can still delete superusers.
I added some tests from this PR to my code and also added the permission denied on the delete page.
2016-07-06 17:05:17 +01:00
Mikalai Radchuk
0b29ba80db Makes notes for settings module more visible (#2826) 2016-07-06 19:01:09 +03:00
Mikalai Radchuk
b79069b247 Release notes for #2786 2016-07-06 17:44:57 +03:00
Matt Westcott
dbc4c9b28e Adds the include_block template tag (#2786)
Update render and render_basic methods on Block to take a context kwarg

Update TableBlock to support passing extra context to render

Implement render_as_block on BoundBlock, StreamValue and StructValue.

Collectively, these are the objects encountered during template rendering which typically render
a block template when output inside {{ ... }} tags. Implementing render_as_block allows us to do
the same thing, but passing a template context as well.

Implement include_block tag

Support extra context vars on include_block via 'with foo=bar'

Support 'only' flag on include_block tag, to omit the parent context

Update StreamField documentation to cover the include_block tag

Rewrite 'BoundBlocks and values' docs based on the include_block tag

Add tests for blocks with legacy render / render_basic methods

Any bits of StreamField infrastructure that attempt to call render or render_basic
on a block with a 'context' kwarg, should (for now) also work on blocks that don't
accept the context kwarg, but output a RemovedInWagtail18Warning.

Explicitly test whether render / render_basic will accept a 'context' kwarg

This avoids unexpected behaviour when the method legitimately accepts a context
kwarg, but happens to throw an unrelated TypeError - in this situation, the final
output (or error diagnostics) will behave as if the context was never passed,
making debugging difficult. See https://github.com/torchbox/wagtail/pull/2786#discussion_r69563984
2016-07-06 17:44:02 +03:00