Sha256: d9545d1de11b081f2bc942a20b05583e13e519d22c716c90ef472da187071641

Contents?: true

Size: 1.03 KB

Versions: 17

Compression:

Stored size: 1.03 KB

Contents

- if features?(:audited)
  .well.well-sm
    - if @resource.version.nil?
      - previous_version = @resource.audits.last.try(:version)
      - next_version = nil
    - else
      - previous_version = @resource.version > 0 ? @resource.version - 1 : nil
      - next_version     = @resource.version < @resource.audits.count ? @resource.version + 1 : nil


    - if previous_version
      = link_to(url_for(action: 'version', version: previous_version), class: 'btn btn-primary btn-responsive') do
        %span.glyphicon.glyphicon-chevron-left
        %span.btn-text= t('.previous')

    .pull-right
      - if next_version
        = link_to(url_for(action: 'version', version: next_version), class: 'btn btn-primary btn-responsive') do
          %span.glyphicon.glyphicon-chevron-right
          %span.btn-text= t('.next')

      - if @resource.version == @resource.audits.count
        = link_to(url_for(action: :show), class: 'btn btn-primary btn-responsive') do
          %span.btn-text= t('.actual')
          %span.glyphicon.glyphicon-chevron-right

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
itsf_backend-5.0.0.pre app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-4.2.3 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-4.2.2 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-4.2.1 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-4.2.0 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-4.0.1 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-4.0.0 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.1.1 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.1.0 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.7 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.6 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.5 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.4 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.3 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.2 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.1 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml
itsf_backend-3.0.0 app/views/itsf/backend/resource/base/_show_extra_actions.html.haml