add search functionality to views