Fix product.meta_keywords not searchable

This commit is contained in:
Matt-Yorkley
2019-10-06 22:30:56 +01:00
parent dd6d0d25da
commit 2539b84b33
2 changed files with 2 additions and 6 deletions

View File

@@ -53,7 +53,7 @@ Darkswarm.controller "ProductsCtrl", ($scope, $filter, $rootScope, Products, Ord
id: $scope.order_cycle.order_cycle_id,
page: $scope.page,
per_page: $scope.per_page,
'q[name_or_supplier_name_cont]': $scope.query,
'q[name_or_meta_keywords_or_supplier_name_cont]': $scope.query,
'q[properites_in_any][]': $scope.activeProperties,
'q[primary_taxon_id_in_any][]': $scope.activeTaxons
}
@@ -64,7 +64,7 @@ Darkswarm.controller "ProductsCtrl", ($scope, $filter, $rootScope, Products, Ord
id: $scope.order_cycle.order_cycle_id,
page: $scope.page + 1,
per_page: $scope.per_page,
'q[name_or_supplier_name_cont]': $scope.query,
'q[name_or_meta_keywords_or_supplier_name_cont]': $scope.query,
'q[properites_in_any][]': $scope.activeProperties,
'q[primary_taxon_id_in_any][]': $scope.activeTaxons
}

View File

@@ -214,10 +214,6 @@ feature "As a consumer I want to shop with a distributor", js: true do
fill_in "search", with: "Meer" # For product named "Meercats"
expect(page).to have_content product2.name
expect(page).not_to have_content product.name
fill_in "search", with: "Dome" # For product with meta_keywords "Domestic"
expect(page).to have_content product.name
expect(page).not_to have_content product2.name
end
it "returns search results for products where the search term matches one of the product's variant names" do