app/views/georgia/pages/search.html.erb in georgia-0.7.8 vs app/views/georgia/pages/search.html.erb in georgia-0.8.0

- old
+ new

@@ -9,24 +9,23 @@ <thead> <th class='checkbox-cell'> <%= checkboxable_all_tag :pages %> </th> <th> - <%= link_to "#{icon_tag('bolt')} Flush Cache".html_safe, '#', class: 'btn btn-default btn-xs disabled js-flush-cache', role: 'button' if can?(:flush_cache, model) %> - <%= link_to "#{icon_tag('thumbs-up')} Publish".html_safe, '#', class: 'btn btn-default btn-xs disabled js-publish', role: 'button' if can?(:publish, model) %> - <%= link_to "#{icon_tag('thumbs-down')} Unpublish".html_safe, '#', class: 'btn btn-default btn-xs disabled js-unpublish', role: 'button' if can?(:unpublish, model) %> - <%= link_to "#{icon_tag('trash-o')} Delete".html_safe, '#', class: 'btn btn-default btn-xs disabled js-delete', role: 'button' if can?(:destroy, model) %> + <%= link_to("#{icon_tag('thumbs-up')} Publish".html_safe, '#', class: 'btn btn-default btn-xs disabled js-publish', role: 'button') if policy(Georgia::Page).publish? %> + <%= link_to("#{icon_tag('thumbs-down')} Unpublish".html_safe, '#', class: 'btn btn-default btn-xs disabled js-unpublish', role: 'button') if policy(Georgia::Page).unpublish? %> + <%= link_to("#{icon_tag('trash-o')} Delete".html_safe, '#', class: 'btn btn-default btn-xs disabled js-delete', role: 'button') if policy(Georgia::Page).destroy? %> </th> <th colspan='3'> <%= pagination_tag(@search) %> </th> </thead> <tbody> <%= render partial: 'georgia/pages/page', collection: @pages, as: :page %> </tbody> </table> <% else -%> - <h2>Yikes! There are <%= pluralize(0, instance_name.humanize.downcase) %>.</h2> + <h2>Yikes! You don't have any <%= instance_name.try(:humanize).try(:downcase).try(:pluralize) %> yet.</h2> <%= link_to "Get Started", '#', class: 'btn btn-primary btn--jumbo', data: {toggle: 'modal', target: '#page_form'} %> <% end -%> </section> \ No newline at end of file