Sha256: d45ebddebb7e73f6085d458f943f6da166a2373be76f8931f3201a28de97f31b

Contents?: true

Size: 1.6 KB

Versions: 3

Compression:

Stored size: 1.6 KB

Contents

- if @page.group.present? && @page.group != Group.everyone
  = render partial: 'shared/authorization_info', locals: {subject: 'page', page: @page}

.row
  - if @page.has_flag? :intranet_root
    %div.col-xs-12.col-md-4.col-md-push-8
      = render partial: 'root/start_page_elements'
    %div.col-xs-12.col-md-8.col-md-pull-4
      = render partial: 'shared/upcoming_events', locals: {events: current_user.try(:upcoming_events).try(:limit, 5) || []}
      = render partial: 'root/what_is_new', locals: {pages: @news_pages}
      = render @page
  - else
    %div.col-md-12
      = render @page

- # officers
- # We show the officers box only if there are any officers groups, since this is used only for special pages
- # at the moment. Most global admins won't assign officers to pages.
- #
- if @page.find_officers_groups.any?
  = render partial: 'officers/officers_box', locals: {structureable: @page}

%div.col3

  - if can?(:create_page_for, @page)
    - # No nested blog posts!
    - # The user might suspect to create a sibling, but really would create a nested blog post.
    - # Note: `@page.type` could be 'Page' for the PagesController. But `Page.find(@page.id)` finds the type in the database.
    - #
    - if (Page.find(@page.id).type != 'BlogPost')  
      %div.blog_tools.box
        = link_to blog_posts_path(parent_id: @page.id), :class => "btn btn-success", :method => :post, :remote => :true do
          = icon :plus
          = I18n.t(:add_blog_entry)
  
  - if @blog_entries.count > 0
    #blog_entries
      - for blog_entry_page in @blog_entries
        = render partial: 'pages/page', object: blog_entry_page

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
your_platform-1.0.1 app/views/pages/show.html.haml
your_platform-1.0.0 app/views/pages/show.html.haml
your_platform-0.0.2 app/views/pages/show.html.haml