fix error
This commit is contained in:
parent
e5c79ad013
commit
3b2f8277a4
|
@ -0,0 +1,9 @@
|
||||||
|
<div class="quick-edit">
|
||||||
|
<ul class="nav nav-pills">
|
||||||
|
<% if is_editable %>
|
||||||
|
<li><a href="/<%= I18n.locale %>/admin/asks/<%=b.id.to_s%>/edit"><%= t(:edit) %></a></li>
|
||||||
|
<li><a href="#" class="delete text-error" rel="/admin/asks/<%=b.id.to_s%>"><%= t(:delete_) %></a></li>
|
||||||
|
<% end %>
|
||||||
|
<li><a href="/<%= I18n.locale %>/admin/asks/<%=b.id.to_s%>/print" target="_blank"><%= t('ask.print') %></a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
|
@ -188,7 +188,7 @@
|
||||||
situation_trans = AskTicketStatus.all.map{|a| [a.key, a.title]}.to_h
|
situation_trans = AskTicketStatus.all.map{|a| [a.key, a.title]}.to_h
|
||||||
last_serial_number = @ask_setting.last_serial_number
|
last_serial_number = @ask_setting.last_serial_number
|
||||||
display_length = [last_serial_number.to_s.length + 1, 4].max
|
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| %>
|
<% @askquestions.each do |b| %>
|
||||||
<tr>
|
<tr>
|
||||||
|
@ -196,17 +196,6 @@
|
||||||
ask_show_url = Page.where(:module=>'ask').first.url rescue nil
|
ask_show_url = Page.where(:module=>'ask').first.url rescue nil
|
||||||
edit_button_can_show = true
|
edit_button_can_show = true
|
||||||
%>
|
%>
|
||||||
<% content_for :edit_button do %>
|
|
||||||
<div class="quick-edit">
|
|
||||||
<ul class="nav nav-pills">
|
|
||||||
<% if is_editable %>
|
|
||||||
<li><a href="/<%= I18n.locale %>/admin/asks/<%=b.id.to_s%>/edit"><%= t(:edit) %></a></li>
|
|
||||||
<li><a href="#" class="delete text-error" rel="/admin/asks/<%=b.id.to_s%>"><%= t(:delete_) %></a></li>
|
|
||||||
<% end %>
|
|
||||||
<li><a href="/<%= I18n.locale %>/admin/asks/<%=b.id.to_s%>/print" target="_blank"><%= t('ask.print') %></a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
|
||||||
<td><% if is_editable %><input type="checkbox" class="batch_select" data-id="<%= b.id %>"><% end %></td>
|
<td><% if is_editable %><input type="checkbox" class="batch_select" data-id="<%= b.id %>"><% end %></td>
|
||||||
<% @table_fields.each_with_index do |f,i| %>
|
<% @table_fields.each_with_index do |f,i| %>
|
||||||
<td>
|
<td>
|
||||||
|
@ -238,8 +227,8 @@
|
||||||
<% when 'ip' %>
|
<% when 'ip' %>
|
||||||
<%= b.ip %>
|
<%= b.ip %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if edit_button_display_index == i %>
|
<% if edit_box_display_index == i %>
|
||||||
<%= yield :edit_button %>
|
<%= render partial: 'edit_box_for_index', :locals => {is_editable: is_editable, b: b} %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</td>
|
</td>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
Loading…
Reference in New Issue