Sha256: cb56d1901760e5ad6b0fcd516d6cc1b007058539a672c63ca34a76f4d799a72b

Contents?: true

Size: 440 Bytes

Versions: 12

Compression:

Stored size: 440 Bytes

Contents

# -*- coding: utf-8 -*-
module TrophyHelper
 def display_trophy_link(user, noid)
   trophyclass = "trophy-off"
   trophytitle= "Highlight File on Profile"
   if user.trophies.map(&:generic_file_id).include? noid
     trophyclass = "trophy-on"
   end

   return link_to raw("<i class='#{trophyclass} icon-trophy'></i> #{trophytitle}"),"", :class=> 'trophy-class', :title => trophytitle, :id => noid,  :remote=>true # link to trophy
 end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
sufia-3.6.1 app/helpers/trophy_helper.rb
sufia-3.6.0 app/helpers/trophy_helper.rb
sufia-3.5.0 app/helpers/trophy_helper.rb
sufia-3.4.0 app/helpers/trophy_helper.rb
sufia-3.4.0.rc4 app/helpers/trophy_helper.rb
sufia-3.4.0.rc3 app/helpers/trophy_helper.rb
sufia-3.3.1 app/helpers/trophy_helper.rb
sufia-3.4.0.rc2 app/helpers/trophy_helper.rb
sufia-3.4.0.rc1 app/helpers/trophy_helper.rb
sufia-3.3.0 app/helpers/trophy_helper.rb
sufia-3.2.1 app/helpers/trophy_helper.rb
sufia-3.1.3 app/helpers/trophy_helper.rb