fix routeParam issue and refactor search controller
fix route param issue in search controller