Modifed the input buttons to correctly bind the relevant data to the scope