more fixes and updates

This commit is contained in:
Andreas N 2014-12-19 23:03:03 +01:00
parent c1f0388da4
commit a764632538
2 changed files with 15 additions and 14 deletions

View File

@ -1,14 +1,15 @@
.panel.panel-default
.media
.media-body
%h6.media-heading.text-muted.answerbox--question-user
= user_screen_name q.user
asked
= time_ago_in_words(q.created_at)
ago
- if q.answer_count > 1
·
%a{href: show_user_question_path(q.user.screen_name, q.id)}
#{q.answer_count} answers
%p.answerbox--question-text
= q.content
.panel-body
.media
.media-body
%h6.media-heading.text-muted.answerbox--question-user
= user_screen_name q.user
asked
= time_ago_in_words(q.created_at)
ago
- if q.answer_count > 1
·
%a{href: show_user_question_path(q.user.screen_name, q.id)}
#{q.answer_count} answers
%p.answerbox--question-text
= q.content

View File

@ -1,5 +1,5 @@
$('#questions').append('<% @questions.each do |a|
%><%= j render 'shared/answerbox', a: a
%><%= j render 'shared/question', a: a
%><% end %>');
<% if @questions.next_page %>
$('#pagination').html('<%= j will_paginate @questions, renderer: BootstrapPagination::Rails, page_links: false %>');