user_privileges files not recalculated after moving roles in hierarchy
If you move a role to a different position in the hierarchy, the user_privileges
files aren't recalculated.
For example, let's say you have roles A and B in the same level of hierarchy and your records are private. That means users cannot see each others' records. Then you move role A below B. That would mean, that users in role B can now see records from users in A. But that doesn't happen.
It seems that the user_privileges
files are not recalculated.
The action Settings_Roles_MoveAjax_Action
is supposed to do that:
But it seems that something inside createUserSharingPrivilegesfile()
fails to do it.
However, if I run this script:
require_once 'vtlib/Vtiger/Module.php';
require_once 'include/utils/VtlibUtils.php';
require_once 'config.inc.php';
require_once 'includes/Loader.php';
require_once 'modules/Users/CreateUserPrivilegeFile.php';
vimport ('includes.runtime.EntryPoint');
$current_user = Users::getActiveAdminUser();
vtlib_RecreateUserPrivilegeFiles();
The files do get recreated.
I doulbe checked it was not a files permissions issue.