Skip to content

armgit / spree

Public Imported from GitHub
0

Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.

V-3036 FIX missing content on vendors products view (#12602)

brozekaa401bc01cb8
diff --git a/admin/app/views/spree/admin/products/_filters.html.erb b/admin/app/views/spree/admin/products/_filters.html.erb
index 536ca41e3a..f665eac25c 100644
--- a/admin/app/views/spree/admin/products/_filters.html.erb
+++ b/admin/app/views/spree/admin/products/_filters.html.erb
@@ -1,4 +1,14 @@
-<%= search_form_for product_list_filters_search_form_path, class: "filter-wrap border-bottom", data: {controller: "filters reveal", reveal_hidden_class: "d-none"} do |f| %>
+<% frame_name ||= nil %>
+
+<%= search_form_for product_list_filters_search_form_path,
+ class: "filter-wrap border-bottom",
+ data: {
+ controller: "filters reveal",
+ reveal_hidden_class: "d-none",
+ filters_url_value: request.url
+ } do |f| %>
+ <%= hidden_field_tag :frame_name, frame_name if frame_name.present? %>
+
<div class="d-flex flex-column flex-lg-row gap-2">
<%= render 'spree/admin/shared/filters_search_bar', param: :multi_search %>
diff --git a/admin/app/views/spree/admin/products/index.html.erb b/admin/app/views/spree/admin/products/index.html.erb
index 4e3c5e5ebf..2f71b593d8 100644
--- a/admin/app/views/spree/admin/products/index.html.erb
+++ b/admin/app/views/spree/admin/products/index.html.erb
@@ -3,7 +3,7 @@
<div class="card-lg p-0">
<% if params[:frame_name].present? %>
<%= turbo_frame_tag params[:frame_name], autoscroll: true, data: { autoscroll_block: :start, autoscroll_behavior: :smooth } do %>
- <%= render 'filters' %>
+ <%= render 'filters', frame_name: params[:frame_name] %>
<%= render 'list' %>
<% end %>
<% else %>