Просмотр исходного кода

feat module 1,2,4 : add new collection and metafields menu group in product query

master
nadia 1 день назад
Родитель
Сommit
a9c00e1b32
1 измененных файлов: 14 добавлений и 0 удалений
  1. 14
    0
      src/services/ProductService.js

+ 14
- 0
src/services/ProductService.js Просмотреть файл

@@ -53,10 +53,17 @@ const getProducts = async () => {
53 53
           collections(first: 10) {
54 54
             nodes {
55 55
               title
56
+              handle
56 57
               image {
57 58
                 url
58 59
               }
59 60
               updatedAt
61
+              metafield(namespace: "custom", key: "menu_group") {
62
+                namespace
63
+                key
64
+                type
65
+                value
66
+              }
60 67
             }
61 68
           }
62 69
           variants(first: 200) {
@@ -139,9 +146,16 @@ const getProduct = async (handle = "") => {
139 146
       collections(first: 10) {
140 147
         nodes {
141 148
           title
149
+          handle
142 150
           image {
143 151
             url
144 152
           }
153
+          metafield(namespace: "custom", key: "menu_group") {
154
+            namespace
155
+            key
156
+            type
157
+            value
158
+          }
145 159
         }
146 160
       }
147 161
       variants(first: 200) {

Загрузка…
Отмена
Сохранить