Fix bugs.
This commit is contained in:
parent
f60a30d0dc
commit
96db4615fc
|
@ -148,7 +148,7 @@ class Admin::VenueManagementBillsController < Admin::VenueAdminController
|
||||||
@venue_management = VenueManagementMain.find(@venue_management_bill.venue_management_main_id)
|
@venue_management = VenueManagementMain.find(@venue_management_bill.venue_management_main_id)
|
||||||
end
|
end
|
||||||
def copy
|
def copy
|
||||||
@venue_management_bill_to_copy = VenueManagementBill.find(params[:id])
|
@venue_management_bill_to_copy = VenueManagementBill.find(params[:bill_id])
|
||||||
attributes = @venue_management_bill_to_copy.attributes.except("_id","updated_at","created_at")
|
attributes = @venue_management_bill_to_copy.attributes.except("_id","updated_at","created_at")
|
||||||
VenueManagementBill.fields.each do |k,v|
|
VenueManagementBill.fields.each do |k,v|
|
||||||
if v.options[:localize]
|
if v.options[:localize]
|
||||||
|
|
|
@ -26,6 +26,7 @@
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
<h3 style="padding-left: 1.25em;"><%= t('venue_management.title') %> : <%= @venue_management_bill.venue_management_main.title %></h3>
|
||||||
<!-- Input Area -->
|
<!-- Input Area -->
|
||||||
<div class="input-area">
|
<div class="input-area">
|
||||||
<% new_record = @venue_management_bill.new_record? && params["action"] != "copy" %>
|
<% new_record = @venue_management_bill.new_record? && params["action"] != "copy" %>
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
<ul class="nav nav-pills">
|
<ul class="nav nav-pills">
|
||||||
<% if can_edit_or_delete?(@venue_management || bill.venue_management_main) %>
|
<% if can_edit_or_delete?(@venue_management || bill.venue_management_main) %>
|
||||||
<li><%= link_to t(:edit), edit_admin_venue_management_bill_path(bill.id) %></li>
|
<li><%= link_to t(:edit), edit_admin_venue_management_bill_path(bill.id) %></li>
|
||||||
<li><%= link_to t(:copy), copy_admin_venue_management_bills_path(:id=>bill.id) %></li>
|
<li><%= link_to t(:copy), copy_admin_venue_management_bills_path(:id=>bill.venue_management_main_id,:bill_id=>bill.id) %></li>
|
||||||
<li><a href="#" class="delete text-error" rel="/admin/venue_management_bills/<%=bill.id.to_s%>"><%= t(:delete_) %></a></li>
|
<li><a href="#" class="delete text-error" rel="/admin/venue_management_bills/<%=bill.id.to_s%>"><%= t(:delete_) %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -456,7 +456,7 @@
|
||||||
<label class="control-label muted"><%= t("venue_management.#{area}") %></label>
|
<label class="control-label muted"><%= t("venue_management.#{area}") %></label>
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
<div class="textarea">
|
<div class="textarea">
|
||||||
<%= f.fields_for :area_translations do |f| %>
|
<%= f.fields_for "#{area}_translations" do |f| %>
|
||||||
<%= f.text_field locale, class: "input-block-level", :value => (@venue_management.send("#{area}_translations")[locale] rescue nil),placeholder: t("venue_management.#{area}") %>
|
<%= f.text_field locale, class: "input-block-level", :value => (@venue_management.send("#{area}_translations")[locale] rescue nil),placeholder: t("venue_management.#{area}") %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue