add edit functionality for categories