Change categories when editing a rule

#165 
I would also try moving rule_4 to a new parent since it has some children (rule_5).