Skip to content

Commit

Permalink
Make admin page smartphone friendly
Browse files Browse the repository at this point in the history
  • Loading branch information
morygonzalez authored and Hitoshi Nakashima committed Dec 23, 2016
1 parent 22d20de commit 78e6d1a
Show file tree
Hide file tree
Showing 11 changed files with 932 additions and 606 deletions.
33 changes: 17 additions & 16 deletions public/admin/comments/index.haml
Original file line number Diff line number Diff line change
@@ -1,21 +1,22 @@
%h2= t('listing_comments')
%p.spam= link_to t('delete_spam'), url("/admin/comments/spam"), :class => 'button', :confirm => t('are_you_sure'), :method => :delete
%table.comments
%tr
%th= t('comment_status')
%th= t('comment.body')
%th= t('comment.name')
%th= t('comment.created_at')
%th(colspan="2")
- @comments.each_with_index do |comment, i|
%tr{:class => (i + 1).odd? ? 'odd' : 'even'}
- status = case comment.status; when Comment::APPROVED; t('comment_approved'); when Comment::MODERATED; t('comment_moderated'); when Comment::SPAM; t('comment_spam'); end
%td= status
%td.body= link_to truncate(strip_tags(comment.body)), url(comment.link)
%td= h(comment.name)
%td= l(comment.created_at, :format => :long)
%td= link_to t('edit'), url("/admin/comments/#{comment.id}/edit"), :class => 'button'
%td= link_to t('delete'), url("/admin/comments/#{comment.id}"), :class => 'button', :confirm => t('are_you_sure'), :method => :delete
#table_wrapper
%table.comments
%tr
%th= t('comment_status')
%th= t('comment.body')
%th= t('comment.name')
%th= t('comment.created_at')
%th(colspan="2")
- @comments.each_with_index do |comment, i|
%tr{:class => (i + 1).odd? ? 'odd' : 'even'}
- status = case comment.status; when Comment::APPROVED; t('comment_approved'); when Comment::MODERATED; t('comment_moderated'); when Comment::SPAM; t('comment_spam'); end
%td= status
%td.body= link_to truncate(strip_tags(comment.body)), url(comment.link)
%td= h(comment.name)
%td= l(comment.created_at, :format => :long)
%td= link_to t('edit'), url("/admin/comments/#{comment.id}/edit"), :class => 'button'
%td= link_to t('delete'), url("/admin/comments/#{comment.id}"), :class => 'button', :confirm => t('are_you_sure'), :method => :delete
.pager
%ul
- if @comments.pager.previous_page
Expand Down
Loading

0 comments on commit 78e6d1a

Please sign in to comment.