@leaddreamer/inventorylogic 0.0.3-beta.89 → 0.0.3-beta.90
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -10
- package/business/Product/googleMerchantAPI.js +39 -40
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1844,8 +1844,8 @@ Typedefs, constants, support functions and database operations related to Produc
|
|
|
1844
1844
|
* [GoogleProduct](#module_GoogleProduct)
|
|
1845
1845
|
* _static_
|
|
1846
1846
|
* [.ggProductMap](#module_GoogleProduct.ggProductMap) : <code>GoogleProductAPI</code>
|
|
1847
|
-
* [.ggProductInputMap](#module_GoogleProduct.ggProductInputMap) : <code>GoogleProductAPI</code>
|
|
1848
1847
|
* [.ggProductAttributeMap](#module_GoogleProduct.ggProductAttributeMap) : <code>GoogleProductAttributes</code>
|
|
1848
|
+
* [.ggProductInputMap](#module_GoogleProduct.ggProductInputMap) : <code>GoogleProductAPI</code>
|
|
1849
1849
|
* [.ggProductFeedToProducts(feedJSON)](#module_GoogleProduct.ggProductFeedToProducts) ⇒ <code>Array.Products</code>
|
|
1850
1850
|
* [.productsToGgProductFeed(productsArray)](#module_GoogleProduct.productsToGgProductFeed)
|
|
1851
1851
|
* _inner_
|
|
@@ -1883,6 +1883,10 @@ Typedefs, constants, support functions and database operations related to Produc
|
|
|
1883
1883
|
### GoogleProduct.ggProductMap : <code>GoogleProductAPI</code>
|
|
1884
1884
|
A Map between GoogleProductAPI and Pricing Internal API
|
|
1885
1885
|
|
|
1886
|
+
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
1887
|
+
<a name="module_GoogleProduct.ggProductAttributeMap"></a>
|
|
1888
|
+
|
|
1889
|
+
### GoogleProduct.ggProductAttributeMap : <code>GoogleProductAttributes</code>
|
|
1886
1890
|
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
1887
1891
|
<a name="module_GoogleProduct.ggProductInputMap"></a>
|
|
1888
1892
|
|
|
@@ -1894,10 +1898,6 @@ found add a new top-level product.
|
|
|
1894
1898
|
Then look within varinats for a matching SKU; if found, use that
|
|
1895
1899
|
value for the index; if *not* found add the variant.
|
|
1896
1900
|
|
|
1897
|
-
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
1898
|
-
<a name="module_GoogleProduct.ggProductAttributeMap"></a>
|
|
1899
|
-
|
|
1900
|
-
### GoogleProduct.ggProductAttributeMap : <code>GoogleProductAttributes</code>
|
|
1901
1901
|
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
1902
1902
|
<a name="module_GoogleProduct.ggProductFeedToProducts"></a>
|
|
1903
1903
|
|
|
@@ -2347,8 +2347,8 @@ Typedefs, constants, support functions and database operations related to Produc
|
|
|
2347
2347
|
* [GoogleProduct](#module_GoogleProduct)
|
|
2348
2348
|
* _static_
|
|
2349
2349
|
* [.ggProductMap](#module_GoogleProduct.ggProductMap) : <code>GoogleProductAPI</code>
|
|
2350
|
-
* [.ggProductInputMap](#module_GoogleProduct.ggProductInputMap) : <code>GoogleProductAPI</code>
|
|
2351
2350
|
* [.ggProductAttributeMap](#module_GoogleProduct.ggProductAttributeMap) : <code>GoogleProductAttributes</code>
|
|
2351
|
+
* [.ggProductInputMap](#module_GoogleProduct.ggProductInputMap) : <code>GoogleProductAPI</code>
|
|
2352
2352
|
* [.ggProductFeedToProducts(feedJSON)](#module_GoogleProduct.ggProductFeedToProducts) ⇒ <code>Array.Products</code>
|
|
2353
2353
|
* [.productsToGgProductFeed(productsArray)](#module_GoogleProduct.productsToGgProductFeed)
|
|
2354
2354
|
* _inner_
|
|
@@ -2386,6 +2386,10 @@ Typedefs, constants, support functions and database operations related to Produc
|
|
|
2386
2386
|
### GoogleProduct.ggProductMap : <code>GoogleProductAPI</code>
|
|
2387
2387
|
A Map between GoogleProductAPI and Pricing Internal API
|
|
2388
2388
|
|
|
2389
|
+
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
2390
|
+
<a name="module_GoogleProduct.ggProductAttributeMap"></a>
|
|
2391
|
+
|
|
2392
|
+
### GoogleProduct.ggProductAttributeMap : <code>GoogleProductAttributes</code>
|
|
2389
2393
|
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
2390
2394
|
<a name="module_GoogleProduct.ggProductInputMap"></a>
|
|
2391
2395
|
|
|
@@ -2397,10 +2401,6 @@ found add a new top-level product.
|
|
|
2397
2401
|
Then look within varinats for a matching SKU; if found, use that
|
|
2398
2402
|
value for the index; if *not* found add the variant.
|
|
2399
2403
|
|
|
2400
|
-
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
2401
|
-
<a name="module_GoogleProduct.ggProductAttributeMap"></a>
|
|
2402
|
-
|
|
2403
|
-
### GoogleProduct.ggProductAttributeMap : <code>GoogleProductAttributes</code>
|
|
2404
2404
|
**Kind**: static constant of [<code>GoogleProduct</code>](#module_GoogleProduct)
|
|
2405
2405
|
<a name="module_GoogleProduct.ggProductFeedToProducts"></a>
|
|
2406
2406
|
|
|
@@ -292,46 +292,6 @@ export const ggProductMap = {
|
|
|
292
292
|
},
|
|
293
293
|
}
|
|
294
294
|
|
|
295
|
-
/**
|
|
296
|
-
* Map between GoogleProductAPI and internal Product Data
|
|
297
|
-
* Note that when gg >> internal, index is *discovered* by searching
|
|
298
|
-
* for a matching item_group_id <<>> id. if item_group_id is *not*
|
|
299
|
-
* found add a new top-level product.
|
|
300
|
-
* Then look within varinats for a matching SKU; if found, use that
|
|
301
|
-
* value for the index; if *not* found add the variant.
|
|
302
|
-
* @type {GoogleProductAPI}
|
|
303
|
-
* @const
|
|
304
|
-
*/
|
|
305
|
-
export const ggProductInputMap = {
|
|
306
|
-
//all assume variants.index prefix
|
|
307
|
-
"legacyLocal": {
|
|
308
|
-
target: "variants.index.platformData.googleData.legacyLocal"
|
|
309
|
-
},
|
|
310
|
-
"offerId": {
|
|
311
|
-
//immutable. Used to create.
|
|
312
|
-
target: "variants.index.sku",
|
|
313
|
-
},
|
|
314
|
-
"contentLanguage": {
|
|
315
|
-
//immutable. Used to create.
|
|
316
|
-
target: "variants.index.platformData.googleData.contentLanguage",
|
|
317
|
-
},
|
|
318
|
-
"feedLabel": {
|
|
319
|
-
//immutable. Used to create.
|
|
320
|
-
target: "variants.index.platformData.googleData.feedLabel",
|
|
321
|
-
},
|
|
322
|
-
"productAttributes": {
|
|
323
|
-
target: "",
|
|
324
|
-
formatter: "ggProductAttributeMap"
|
|
325
|
-
},
|
|
326
|
-
"customAttributes": {
|
|
327
|
-
target: "variants.index.platformData.googleData.customAttributes",
|
|
328
|
-
formatter: ggcustomAttributes,
|
|
329
|
-
},
|
|
330
|
-
"versionNumber": {
|
|
331
|
-
target: "variants.index.versionNumber",
|
|
332
|
-
},
|
|
333
|
-
}
|
|
334
|
-
|
|
335
295
|
/**
|
|
336
296
|
* @type {GoogleProductAttributes}
|
|
337
297
|
*/
|
|
@@ -426,6 +386,45 @@ export const ggProductAttributeMap = {
|
|
|
426
386
|
//shipping_label: null,
|
|
427
387
|
};
|
|
428
388
|
|
|
389
|
+
/**
|
|
390
|
+
* Map between GoogleProductAPI and internal Product Data
|
|
391
|
+
* Note that when gg >> internal, index is *discovered* by searching
|
|
392
|
+
* for a matching item_group_id <<>> id. if item_group_id is *not*
|
|
393
|
+
* found add a new top-level product.
|
|
394
|
+
* Then look within varinats for a matching SKU; if found, use that
|
|
395
|
+
* value for the index; if *not* found add the variant.
|
|
396
|
+
* @type {GoogleProductAPI}
|
|
397
|
+
* @const
|
|
398
|
+
*/
|
|
399
|
+
export const ggProductInputMap = {
|
|
400
|
+
//all assume variants.index prefix
|
|
401
|
+
"legacyLocal": {
|
|
402
|
+
target: "variants.index.platformData.googleData.legacyLocal"
|
|
403
|
+
},
|
|
404
|
+
"offerId": {
|
|
405
|
+
//immutable. Used to create.
|
|
406
|
+
target: "variants.index.sku",
|
|
407
|
+
},
|
|
408
|
+
"contentLanguage": {
|
|
409
|
+
//immutable. Used to create.
|
|
410
|
+
target: "variants.index.platformData.googleData.contentLanguage",
|
|
411
|
+
},
|
|
412
|
+
"feedLabel": {
|
|
413
|
+
//immutable. Used to create.
|
|
414
|
+
target: "variants.index.platformData.googleData.feedLabel",
|
|
415
|
+
},
|
|
416
|
+
"productAttributes": {
|
|
417
|
+
target: "",
|
|
418
|
+
formatter: "ggProductAttributeMap"
|
|
419
|
+
},
|
|
420
|
+
"customAttributes": {
|
|
421
|
+
target: "variants.index.platformData.googleData.customAttributes",
|
|
422
|
+
formatter: ggcustomAttributes,
|
|
423
|
+
},
|
|
424
|
+
"versionNumber": {
|
|
425
|
+
target: "variants.index.versionNumber",
|
|
426
|
+
},
|
|
427
|
+
}
|
|
429
428
|
|
|
430
429
|
/**
|
|
431
430
|
* Because Google Merchants uses a NON-hierarchical variants listing
|