diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index 0e054eb8..2ec665ad 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -135,16 +135,16 @@ %span{ lang: post.locale, dir: dir }= category = '/' unless post.front_matter['categories'].last == category - %td.text-nowrap - = post.created_at.strftime('%F') - %br/ - = post.order - %td.text-nowrap - .d-flex.flex-row.align-items-start - - if @usuarie || policy(post).edit? - = link_to t('posts.edit_post'), edit_site_post_path(@site, post.path), class: 'btn btn-secondary' - - if @usuarie || policy(post).destroy? - = link_to t('posts.destroy'), site_post_path(@site, post.path), class: 'btn btn-secondary', method: :delete, data: { confirm: t('posts.confirm_destroy') } + %td.text-nowrap + = post.created_at.strftime('%F') + %br/ + = post.order + %td.text-nowrap + .d-flex.flex-row.align-items-start + - if @usuarie || policy(post).edit? + = link_to t('posts.edit_post'), edit_site_post_path(@site, post.path), class: 'btn btn-secondary' + - if @usuarie || policy(post).destroy? + = link_to t('posts.destroy'), site_post_path(@site, post.path), class: 'btn btn-secondary', method: :delete, data: { confirm: t('posts.confirm_destroy') } -# Rescatar cualquier error en un post, notificarlo e ignorar su renderización.