Hello community,
on a site with a simple blog, I am using Pages for blog categories. Therefore I created a template blog_categories as the categories PARENT page and another template blog_category for the CHILD pages. I configured blog_categories to only allow blog_category as children – and vice versa – blog_category to only allow blog_categories as parent. Having that set up, i created a field of InputfieldPage and configured it to have my (already added) blog_categories parent page as allowed parent and set template blog_category for selectable pages. I also checked "Allow new pages to be created from field".
For the super-user this works as expected: Categories (pages using blog_category) can be created within the InputfieldPage field while editing a blog post.
For my editor roll, i set up the following template permissions (beside the default view-permission):
blog_categories
– add children
blog_category
– create pages
– edit pages
Logged in as an user in editor role, I am able to create new categories in the page tree (as child pages to the categories parent). But when the the same user tries to create a new page from within the InputfieldPage, I get the "No access to add [template-name] pages to [path-of-parent]" error on no page is created.
After digging a little in wire/modules/Inputfield/InputfieldPage/InputfieldPage.module, I found that $page->publishable() returns false in the corresponding check.
But I don't understand why this returns false. In the page tree, the user in editor roll is able to publish/unpublish pages – also also to edit pages so it SEEMS there is a glitch in the permission check.
Note: I didn't install the predefined sytem permission "page-publish" because – as far as I understood – if not installed the page-edit permission should also indicate the permission for publishing a page.
On another site, using an slightly older version of ProcessWire, the same setup works fine. On the site in question, i am using 3.0.193 dev (DEV branch) – maybe that's the problem? Or I'am doing something wrong?
I am glad for any hint in the right direction!