Sha256: f5bcf58728e5a1ae0e720f4368f25bcd5a4c93ddbd2af279ef596c45bd963c54
Contents?: true
Size: 668 Bytes
Versions: 2
Compression:
Stored size: 668 Bytes
Contents
# encoding: UTF-8 require 'iqvoc/similar_terms' # XXX: should not be necessary!? class SimilarTermsController < ApplicationController def show authorize! :read, Iqvoc::Concept.base_class unless params[:terms] head 400 unless request.format.html? # non-GUI return end @terms = Iqvoc::InlineDataHelper.parse_inline_values(params[:terms]) lang = params[:lang] respond_to do |format| format.any(:html, :ttl, :rdf) do @results = Iqvoc::SimilarTerms.ranked(lang, *@terms) end format.text do render :text => Iqvoc::SimilarTerms.alphabetical(lang, *@terms).join("\n") end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
iqvoc_similar_terms-0.6.1 | app/controllers/similar_terms_controller.rb |
iqvoc_similar_terms-0.6.0 | app/controllers/similar_terms_controller.rb |