Add functionality to edit activities