Searching on a specific page type and using the page queryset
results in a missing FilterField message for "page_ptr_id".
The where node query is used to build the list of filters
and xxxx_ptr_id shows up when we use any inherited model and query
by the id. It's best to just ignore this as its useless to
filter search on a pointer field.
We could define it as a FilterField on the Page model, but this
way it prevents other indexed Django models from hitting the same problem.
Instead of checking for any kind of permission, the change permission is
used to allow/disallow peoples access to change a setting. The change
permission for each setting has added to the Group editing view with
`register_permission`.
The `wagtailsettings` module is useful enough that it should be included
in the Wagtail contrib section, to make it available to all Wagtail
developers.
All the code has been given a once-over to make sure it is nice and
polished before being copied in. As such, this is not a direct copy of
the `wagtailsettings` module. It should be backwards compatible though,
excepting the new location.
It has been moved to `wagtail.contrib.settings`, following the naming
scheme set out in #1504.
Documentation has been concatenated in to a single page, and added to
the contrib reference section.
The URLify function supplied by django does not need a length argument in order to work. The problem with supplying the length argument is that when you have Unicode characters that are translated to two characters in the slug version, the resulting slug will be missing one character for each such double character.
Example:
Æ or æ is translated as ae when slugified.
A call to URLify would then be: URLify("kjaftæði", 8) which would result in the slug "kjaftaed", since the slug is 9 characters in length due to æ being expanded to two characters. URLify("kjaftæði") works fine and returns "kjaftaedi".