Completed functionality of the DetailViewController