Last active
April 22, 2019 15:36
-
-
Save rgoytacaz/0f86debdd25079876ec76c26018d4810 to your computer and use it in GitHub Desktop.
CS list of product refId
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function() { | |
var productIds; | |
function productsCSV(){ | |
$.ajax({ | |
method: 'GET', | |
url:'/api/checkout/pub/orders/order-group/'+{{ORDER ID}}, | |
async: false | |
}).then(function(resp){ | |
productIds = resp[0].items.map(function(product){ return product.refId }).join(','); | |
}) | |
} | |
productsCSV(); | |
return productIds; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment