mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-01 02:03:22 +00:00
Remove "profiles" from /shops
This commit is contained in:
@@ -89,13 +89,13 @@
|
||||
= t :groups_hubs
|
||||
|
||||
= render "shared/components/enterprise_search"
|
||||
= render "shops/filters", resource: "group_hubs", property_filters: "| searchEnterprises:query | taxons:activeTaxons | shipping:shippingTypes | showHubProfiles:show_profiles"
|
||||
= render "shops/filters", resource: "group_hubs", property_filters: "| searchEnterprises:query | taxons:activeTaxons | shipping:shippingTypes"
|
||||
|
||||
.row
|
||||
.small-12.columns
|
||||
.active_table
|
||||
%hub.active_table_node.row.animate-repeat{id: "{{hub.hash}}",
|
||||
"ng-repeat" => "hub in filteredEnterprises = (group_hubs | searchEnterprises:query | taxons:activeTaxons | shipping:shippingTypes | showHubProfiles:show_profiles | properties:activeProperties:'distributed_properties' | orderBy:['-active', '+orders_close_at'])",
|
||||
"ng-repeat" => "hub in filteredEnterprises = (group_hubs | searchEnterprises:query | taxons:activeTaxons | shipping:shippingTypes | properties:activeProperties:'distributed_properties' | orderBy:['-active', '+orders_close_at'])",
|
||||
"ng-class" => "{'is_profile' : hub.category == 'hub_profile', 'closed' : !open(), 'open' : open(), 'inactive' : !hub.active, 'current' : current()}",
|
||||
"ng-controller" => "GroupEnterpriseNodeCtrl"}
|
||||
.small-12.columns
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
.small-12.medium-6.columns.text-right
|
||||
.profile-checkbox
|
||||
%button.button.secondary.tiny.right.help-btn.ng-scope{:popover => t(:components_profiles_popover, sitename: Spree::Config[:site_name]), "popover-placement" => "left"}><
|
||||
%i.ofn-i_013-help
|
||||
%label
|
||||
%input{"ng-model" => "show_profiles", type: "checkbox", name: "profile"}
|
||||
= t :components_profiles_show
|
||||
@@ -1,10 +1,8 @@
|
||||
- resource ||= "visibleMatches"
|
||||
- property_filters ||= "| closedShops:show_closed | taxons:activeTaxons | shipping:shippingTypes | showHubProfiles:show_profiles"
|
||||
- property_filters ||= "| closedShops:show_closed | taxons:activeTaxons | shipping:shippingTypes"
|
||||
|
||||
.row
|
||||
= render 'shared/components/filter_controls'
|
||||
-# .small-12.medium-6.columns
|
||||
= render 'shared/components/show_profiles'
|
||||
|
||||
.row.animate-show.filter-row{"ng-show" => "filtersActive"}
|
||||
.small-12.columns
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
.active_table
|
||||
%hub.active_table_node.row{"ng-repeat" => "hub in #{enterprises}Filtered = (#{enterprises} | closedShops:show_closed | taxons:activeTaxons | properties:activeProperties:'distributed_properties' | shipping:shippingTypes | showHubProfiles:show_profiles | orderBy:['-active', '+distance', '+orders_close_at'])",
|
||||
%hub.active_table_node.row{"ng-repeat" => "hub in #{enterprises}Filtered = (#{enterprises} | closedShops:show_closed | taxons:activeTaxons | properties:activeProperties:'distributed_properties' | shipping:shippingTypes | orderBy:['-active', '+distance', '+orders_close_at'])",
|
||||
"ng-class" => "{'is_profile' : hub.category == 'hub_profile', 'closed' : !open(), 'open' : open(), 'inactive' : !hub.active, 'current' : current()}",
|
||||
"ng-controller" => "HubNodeCtrl",
|
||||
id: "{{hub.hash}}"}
|
||||
|
||||
@@ -55,21 +55,6 @@ feature 'Shops', js: true do
|
||||
follow_active_table_node distributor.name
|
||||
expect(page).to have_current_path enterprise_shop_path(distributor)
|
||||
end
|
||||
|
||||
describe "showing profiles" do
|
||||
before do
|
||||
check "Show profiles"
|
||||
end
|
||||
|
||||
it "still shows hubs" do
|
||||
expect(page).to have_content distributor.name
|
||||
end
|
||||
|
||||
# https://github.com/openfoodfoundation/openfoodnetwork/issues/1718
|
||||
it "shows profiles" do
|
||||
expect(page).to have_content profile.name
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
describe "showing available hubs" do
|
||||
|
||||
Reference in New Issue
Block a user