fixed roles controller for implementing the tests correctly
implemented transformation and storage of permissions for roles
implemented matrices for permission assignment