mirror of
https://github.com/vercel/commerce.git
synced 2025-07-26 11:41:23 +00:00
feat: get favorite products
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
import { searchResultFragment } from '../fragments/search-result-fragment'
|
||||
|
||||
export const activeCustomerQuery = /* GraphQL */ `
|
||||
query activeCustomer {
|
||||
activeCustomer {
|
||||
@@ -11,15 +9,6 @@ export const activeCustomerQuery = /* GraphQL */ `
|
||||
items{
|
||||
product{
|
||||
id
|
||||
name
|
||||
slug
|
||||
assets{
|
||||
source
|
||||
preview
|
||||
}
|
||||
variants{
|
||||
price
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,27 @@
|
||||
export const getFavoriteProductQuery = /* GraphQL */ `
|
||||
query activeCustomer($options: FavoriteListOptions) {
|
||||
activeCustomer {
|
||||
id
|
||||
firstName
|
||||
lastName
|
||||
emailAddress
|
||||
favorites(options: $options){
|
||||
items{
|
||||
product{
|
||||
id
|
||||
name
|
||||
slug
|
||||
assets{
|
||||
source
|
||||
preview
|
||||
}
|
||||
variants{
|
||||
price
|
||||
}
|
||||
}
|
||||
}
|
||||
totalItems
|
||||
}
|
||||
}
|
||||
}
|
||||
`
|
Reference in New Issue
Block a user