Sha256: ab3a3eb7965dcc48edc15f202ae09954fa1ed06803efa71a7ea4c5b6fa2dd884

Contents?: true

Size: 344 Bytes

Versions: 20

Compression:

Stored size: 344 Bytes

Contents

module Commontator
  module ThreadsHelper
    def commontable_name(thread)
      config = thread.config
      config.commontable_name.blank? ? \
      thread.commontable.class.name : \
      config.commontable_name
    end
    
    def commontable_id(thread)
      thread.commontable.send(thread.config.commontable_id_method)
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
commontator-4.0.2 app/helpers/commontator/threads_helper.rb
commontator-2.0.2 app/helpers/commontator/threads_helper.rb
commontator-4.0.1 app/helpers/commontator/threads_helper.rb
commontator-4.0.0 app/helpers/commontator/threads_helper.rb
commontator-2.0.1 app/helpers/commontator/threads_helper.rb
commontator-2.0.0 app/helpers/commontator/threads_helper.rb
commontator-1.1.3 app/helpers/commontator/threads_helper.rb
commontator-1.1.2 app/helpers/commontator/threads_helper.rb
commontator-1.1.1 app/helpers/commontator/threads_helper.rb
commontator-1.1.0 app/helpers/commontator/threads_helper.rb
commontator-1.0.6 app/helpers/commontator/threads_helper.rb
commontator-1.0.5 app/helpers/commontator/threads_helper.rb
commontator-1.0.4 app/helpers/commontator/threads_helper.rb
commontator-1.0.3 app/helpers/commontator/threads_helper.rb
commontator-1.0.2 app/helpers/commontator/threads_helper.rb
commontator-1.0.1 app/helpers/commontator/threads_helper.rb
commontator-1.0.0 app/helpers/commontator/threads_helper.rb
commontator-0.5.14 app/helpers/commontator/threads_helper.rb
commontator-0.5.13 app/helpers/commontator/threads_helper.rb
commontator-0.5.12 app/helpers/commontator/threads_helper.rb