add legs and update complete status of trip.