Closed sashsvamir closed 8 years ago
Also problem happens when you delete item: all relations of these item still keep in database.
Oh, i'm sorry, problem was in configuration of mysql database (my.cnf), this config was disabling InnoDb engine by set active key skip-innodb. The task of removing (and renaming) items from RBAC tables call from DbManager class of Yii2 and implements by 'Cascade Update' feature (by using foreign key of mysql table). Because foreign keys supported only by InnoDb, this Cascade Updating not happens. Now problem was fixed and all works as intended.
When i try to rename any items (assignment, role, permission), this item still stay at database, also relations of these items (child) still in db. Can this behaviour give any problems in future? Right now i can see first problem of this behaviour: if you add in future any item (role, permission or assignment) with same name, which was renamed before, you get all relations of older items with same name.