Refactor searching methods to models