added code to filter by animal type id, refactored methods into entities and views / controller -- added animal_type_id to JSON