diff --git a/app/views/legislation/annotations/_comments_for.html.erb b/app/views/legislation/annotations/_comments_box.html.erb similarity index 100% rename from app/views/legislation/annotations/_comments_for.html.erb rename to app/views/legislation/annotations/_comments_box.html.erb diff --git a/app/views/legislation/annotations/comments.js.erb b/app/views/legislation/annotations/comments.js.erb index a058b00da..6ee83560e 100644 --- a/app/views/legislation/annotations/comments.js.erb +++ b/app/views/legislation/annotations/comments.js.erb @@ -1,2 +1,2 @@ -$("#comments-box").html("<%= j render('comments_for', annotation: @annotation) %>"); +$("#comments-box").html("<%= j render('comments_box', annotation: @annotation) %>"); diff --git a/app/views/legislation/annotations/show.html.erb b/app/views/legislation/annotations/show.html.erb index 6bf499f52..cdfa04447 100644 --- a/app/views/legislation/annotations/show.html.erb +++ b/app/views/legislation/annotations/show.html.erb @@ -27,7 +27,7 @@ - <%= render 'comments', commentable: @annotation %> + <%= render 'legislation/shared/comments', commentable: @annotation %> diff --git a/app/views/legislation/questions/_comments.html.erb b/app/views/legislation/questions/_comments.html.erb deleted file mode 100644 index c7b9591e8..000000000 --- a/app/views/legislation/questions/_comments.html.erb +++ /dev/null @@ -1,29 +0,0 @@ -<% cache [locale_and_user_status, @current_order, commentable_cache_key(@question), @comment_tree.comments, @comment_tree.comment_authors, @question.comments_count, @comment_flags] do %> -
-
-

- <%= t("legislation.questions.show.comments") %> - (<%= @question.comments_count %>) -

- - <%= render 'shared/wide_order_selector', i18n_namespace: "comments" %> - - <% if user_signed_in? %> - <%= render 'comments/form', {commentable: @question, parent_id: nil, toggeable: false} %> - <% else %> -
- -
- <%= t("debates.show.login_to_comment", - signin: link_to(t("votes.signin"), new_user_session_path), - signup: link_to(t("votes.signup"), new_user_registration_path)).html_safe %> -
- <% end %> - - <% @comment_tree.root_comments.each do |comment| %> - <%= render 'comments/comment', comment: comment %> - <% end %> - <%= paginate @comment_tree.root_comments %> -
-
-<% end %> diff --git a/app/views/legislation/questions/show.html.erb b/app/views/legislation/questions/show.html.erb index 808b5d331..4ad67a546 100644 --- a/app/views/legislation/questions/show.html.erb +++ b/app/views/legislation/questions/show.html.erb @@ -49,4 +49,4 @@ -<%= render 'comments' %> +<%= render 'legislation/shared/comments', commentable: @question %> diff --git a/app/views/legislation/annotations/_comments.html.erb b/app/views/legislation/shared/_comments.html.erb similarity index 95% rename from app/views/legislation/annotations/_comments.html.erb rename to app/views/legislation/shared/_comments.html.erb index 158c2f789..25b4ce18d 100644 --- a/app/views/legislation/annotations/_comments.html.erb +++ b/app/views/legislation/shared/_comments.html.erb @@ -2,7 +2,7 @@

- <%= t("legislation.annotations.show.comments") %> + <%= t("legislation.shared.comments") %> (<%= commentable.comments_count %>)

diff --git a/config/locales/en.yml b/config/locales/en.yml index a7fe21a91..0e6831657 100755 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -242,7 +242,6 @@ en: other: "%{count} comments" show: title: Comment - comments: Comments version_chooser: seeing_version: Commments for version see_text: See text draft @@ -305,7 +304,6 @@ en: debate: Debate show: answer_question: Submit answer - comments: Comments next_question: Next question first_question: First question share: Share @@ -322,6 +320,8 @@ en: verified_only: Only verified users can participate, %{verify_account}. verify_account: verify your account debate_phase_not_open: Debate phase has finished and answers are not accepted anymore + shared: + comments: Comments locale: English notifications: index: diff --git a/config/locales/es.yml b/config/locales/es.yml index 823115d12..6afbc6820 100755 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -242,7 +242,6 @@ es: other: "%{count} comentarios" show: title: Comentario - comments: Comentarios version_chooser: seeing_version: Comentarios para la versión see_text: Ver borrador del texto @@ -305,7 +304,6 @@ es: debate: Debate show: answer_question: Enviar respuesta - comments: Comentarios next_question: Siguiente pregunta first_question: Primera pregunta share: Compartir @@ -322,6 +320,8 @@ es: verified_only: Solo los usuarios verificados pueden participar en el debate, %{verify_account}. verify_account: verifica tu cuenta debate_phase_not_open: La fase de debate previo ya ha finalizado y en este momento no se aceptan respuestas + shared: + comments: Comentarios locale: Español notifications: index: