-
-
Save mikecmpbll/1bb59e596591c68bf229 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
search_all = LOCAL_SETTINGS["single_site_search"] | |
if params[:ref].present? | |
spaces = Space.where(id: { params[:ref] }, parent_id: nil }) | |
spaces = spaces.eager_loads(slots: :companies).where(companies: { parent_id: current_company_id }) unless search_all | |
render partial: 'call_centre_results' and return | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment