Sha256: ccdf6bcdabc91395f529e13480ee5e258e6648efc7766531f4e312a0724b1f73

Contents?: true

Size: 455 Bytes

Versions: 12

Compression:

Stored size: 455 Bytes

Contents

require 'foreman_openscap/version'

module ForemanOpenscapHelper
  def scap_doc_link(section = '', text = _('documentation'))
    link_to(
      text,
      scap_doc_url(section),
      :rel => 'external noopener noreferrer', :target => '_blank'
    )
  end

  def scap_doc_url(section = '')
    version = ForemanOpenscap::VERSION.split('.')[0..-2].join('.')
    "https://theforeman.org/plugins/foreman_openscap/#{version}/index.html#{section}"
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
foreman_openscap-1.0.9 app/helpers/foreman_openscap_helper.rb
foreman_openscap-2.0.0 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.8 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.7 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.6 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.5 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.4 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.3 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.2 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.1 app/helpers/foreman_openscap_helper.rb
foreman_openscap-1.0.0 app/helpers/foreman_openscap_helper.rb
foreman_openscap-0.12.3 app/helpers/foreman_openscap_helper.rb