Skip to content

Commit

Permalink
magento change product image query to search
Browse files Browse the repository at this point in the history
  • Loading branch information
IncognitaDev committed Dec 18, 2024
1 parent 0d52e33 commit 0e86a21
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion magento/utils/cart.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ export async function getCartImages(
>(
{
variables: {
filter: { sku: { in: skus.map((sku) => sku) } },
search: `${skus.join(" ")}`,
pageSize: skus.length,
},
...GetProductImages,
Expand Down
2 changes: 2 additions & 0 deletions magento/utils/clientGraphql/queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -289,10 +289,12 @@ export const GetProductImages = {
fragments: [mediaGallery],
query: gql`
query GetProduct(
$search: String
$filter: ProductAttributeFilterInput
$pageSize: Int
) {
products(
search: $search
filter: $filter
pageSize: $pageSize
currentPage: 1
Expand Down

0 comments on commit 0e86a21

Please sign in to comment.