Sha256: 88b2a722d0a8242fce85ff736c42bad1f87850af493503d8767ca1beeccc6488

Contents?: true

Size: 1.33 KB

Versions: 2

Compression:

Stored size: 1.33 KB

Contents

<%
  author ||= false
  date ||= false
  section ||= false
  sections ||= []
%>
<tr class="<%= [page.status_label.downcase,((page.autopublish?) ? 'autopublish' : nil), ((page.pinned?) ? 'pinned' : nil)].join(' ') %>">
  <td class="name">
    <%= link_to_if(policy(page).edit?,
                   page_name(page),
                   edit_admin_page_url(@locale, page),
                   class: 'name_link') %>
    <% if page.autopublish? %>
      <br />
      <small>
        This page will be published
        <strong><%= publish_time(page.published_at) %></strong>
      </small>
    <% end %>
  </td>
  <% if date %>
    <td class="date">
      <%= page_date_range(page) %>
    </td>
  <% end %>
  <td>
    <% if page.published? %>
      <% if page.published_at.year == Time.zone.now.year %>
        <%= l(page.published_at, format: :pages_date) %>
      <% else %>
        <%= l(page.published_at, format: :pages_full) %>
      <% end %>
    <% else %>
      <% if page.status_label == 'Published' %>
        <em>Not published</em>
      <% else %>
        <em><%= page.status_label %></em>
      <% end %>
    <% end %>
  </td>
  <% if author %>
    <td>
      <%= link_to(page.author.name, admin_user_path(page.author)) %>
    </td>
  <% end %>
  <% if section %>
    <td>
      <%= news_section_name(page.parent, sections) %>
    </td>
  <% end %>
</tr>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
pages_core-3.12.1 app/views/admin/pages/_list_item.html.erb
pages_core-3.12.0 app/views/admin/pages/_list_item.html.erb