app/views/comments/_form.html.erb in tkh_content-0.9.15 vs app/views/comments/_form.html.erb in tkh_content-0.9.16
- old
+ new
@@ -1,15 +1,15 @@
<%= simple_form_for @comment, :html => { class: 'form-horizontal' } do |f| %>
<%= f.error_notification %>
-
+
<div class="form-inputs">
<%= @comment.author.name %><br />
- <%= link_to @comment.page.title, @comment.page %><br />
- <%= f.input :short_title, hint: 'ideally one word only, used for the menu' %><br />
- <%= render 'comments/status_buttons' %><br />
+ <%= link_to (@comment.commentable.title || @comment.commentable.name), @comment.commentable %><br />
+ <%#= f.input :short_title, hint: 'ideally one word only, used for the menu' %><br />
+ <%= render 'comments/status_buttons', comment: @comment %><br />
<%= f.input :body, :input_html => { :rows => 3 } %>
</div>
-
+
<div class="form-actions">
<%= f.button :submit, :class => 'btn btn-primary' %>
</div>
<% end %>