Sha256: db2a79ef6f0cee76eb7c90d3ec9e3017b8497edd53acbaf6f5dbbdfa55703082
Contents?: true
Size: 395 Bytes
Versions: 10
Compression:
Stored size: 395 Bytes
Contents
require 'rdf' require 'cgi' class AuthoritiesController < ApplicationController def query s = params.fetch("q", "") hits = if params[:term] == "location" GeoNamesResource.find_location(s) else begin LocalAuthority.entries_by_term(params[:model], params[:term], s) rescue [] end end render json: hits end end
Version data entries
10 entries across 10 versions & 1 rubygems