diff --git a/app/views/admin/asks/_edit_box_for_index.html.erb b/app/views/admin/asks/_edit_box_for_index.html.erb
new file mode 100644
index 0000000..95240ca
--- /dev/null
+++ b/app/views/admin/asks/_edit_box_for_index.html.erb
@@ -0,0 +1,9 @@
+
\ No newline at end of file
diff --git a/app/views/admin/asks/_index.html.erb b/app/views/admin/asks/_index.html.erb
index 74d1f46..9dfa6eb 100644
--- a/app/views/admin/asks/_index.html.erb
+++ b/app/views/admin/asks/_index.html.erb
@@ -188,7 +188,7 @@
situation_trans = AskTicketStatus.all.map{|a| [a.key, a.title]}.to_h
last_serial_number = @ask_setting.last_serial_number
display_length = [last_serial_number.to_s.length + 1, 4].max
- edit_button_display_index = @table_fields.count > 3 ? 2 : @table_fields.count
+ edit_box_display_index = @table_fields.count > 3 ? 2 : @table_fields.count
%>
<% @askquestions.each do |b| %>
@@ -196,17 +196,6 @@
ask_show_url = Page.where(:module=>'ask').first.url rescue nil
edit_button_can_show = true
%>
- <% content_for :edit_button do %>
-
- <% end %>
<% if is_editable %><% end %> |
<% @table_fields.each_with_index do |f,i| %>
@@ -238,8 +227,8 @@
<% when 'ip' %>
<%= b.ip %>
<% end %>
- <% if edit_button_display_index == i %>
- <%= yield :edit_button %>
+ <% if edit_box_display_index == i %>
+ <%= render partial: 'edit_box_for_index', :locals => {is_editable: is_editable, b: b} %>
<% end %>
|
<% end %>