Bring Spree changes on admin/products/new.js.erb

We copied it from Spree to then append a little change on it. Since the
original version changed in Spree 2.0 we need to update our copy.
This commit is contained in:
Pau Perez
2018-11-08 10:38:36 +00:00
parent 6bc14f4bab
commit 18c51dc596

View File

@@ -1,5 +1,5 @@
<%# This chunk is just a copy of Spree's core/app/views/spree/admin/products/new.js.erb %>
$("#new_product").html('<%= escape_javascript(render :template => "spree/admin/products/new", :formats => [:html], :handlers => [:erb]) %>');
<%# This chunk is just a copy of Spree's backend/app/views/spree/admin/products/new.js.erb %>
$("#new_product_wrapper").html('<%= escape_javascript(render :template => "spree/admin/products/new", :formats => [:html], :handlers => [:erb]) %>');
handle_date_picker_fields();
<% unless Rails.env.test? %>
$('.select2').select2();