From 8bceab05ae5be768550b286a3fac87572b7f13b8 Mon Sep 17 00:00:00 2001 From: chiu Date: Wed, 7 Jan 2026 09:34:57 +0000 Subject: [PATCH] Add administrator replies, \r\n conversion to br, CSS --- app/views/asks/published_index.erb | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/app/views/asks/published_index.erb b/app/views/asks/published_index.erb index 34ee025..0f39666 100644 --- a/app/views/asks/published_index.erb +++ b/app/views/asks/published_index.erb @@ -10,7 +10,7 @@ category_id = ask_question.category_id.to_s extra_info = ask_settings_info[category_id] %> -
+
<%= link_to ask_question.title,"#{data['url']}?item=#{ask_question.id}",title: ask_question.title %>
<%= ask_question.content %>
@@ -50,10 +50,17 @@ end %>
- <%= fv %> + <%= fv.to_s.gsub(/\r\n|\r|\n/, "
").html_safe %>
<% end %> <% end %> + <%# 顯示管理者回覆內容 %> + <% if ask_question.reply.present? %> +
+ 回覆: + <%= ask_question.reply.to_s.gsub(/\r\n|\r|\n/, "
").html_safe %> +
+ <% end %>
<% end %>