OK,
I’m creating a permission plugin and using user(role) blueprints in site/blueprints/users/…
Like for instance a “viewer” role.
When I use a viewer.yml file I can add this user-role to any user in the control panel when logged in as Admin. But when I use a viewer.php (programmable) blueprint, this one is not picked up in the control panel ie users section, so I cannot apply the viewer-user-role to a user…
Do we have to register these php-blueprints explicitly? I thought Kirby would pick these up automagically?
Thanks in advance again (:-
Example: functioning user-role blueprint site/blueprints/users/viewer.yml:
title: Viewer
description: Can only view
permissions:
access:
panel: true
settings: false
users: false
site: true
Non-functioning programmable version site/blueprints/users/viewer.php:
<?php
// site/blueprints/users/viewer.php
return [
'title' => 'Viewer (from PHP)',
'description' => 'This is a test to see if a PHP blueprint can be loaded.',
'permissions' => [
'access' => [
'panel' => true
]
]
];