Saving an orgas profile resets this orga to ambassador permissions
Having an orga members profile in our region as an ambassador you reset this persons orga permissions (kind of*) to ambassador. While rolle
stays the same (4
) in fs_foodsaver
the orgateam
field gets reset to 0
.
Currently orga permissions are handled very differently in the code. Some places check for rolle == 4
and some for orgateam == 1
. This is why I wrote kind of ;-)
While fixing this – keep in mind – we aim to split orga permissions into more granular ones. You can already find permission classes here: https://gitlab.com/foodsharing-dev/foodsharing/-/tree/master/src/Permissions
Little bit unrelated:
As orga
isn't a role where you need to pass a quiz but only is a permission I would go with removing rolle
4 and only use orgateam
and edit it via techDatabase. See: !1126 (closed) and !1140 (closed)