Created
October 9, 2020 17:53
-
-
Save mbraga-sfdc/c20026a257324cd752cf0935aab00e88 to your computer and use it in GitHub Desktop.
This file contains 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
/** | |
* Get list of all orders for the user | |
* | |
* type String json or xml | |
* pOSTDATA List Creates a new employee in DB (optional) | |
* returns List | |
**/ | |
exports.typePost_orderPOST = function(type,pOSTDATA) { | |
return new Promise(function(resolve, reject) { | |
var examples = {}; | |
examples['application/json'] = [ { | |
"Item Total Price" : 1998.0, | |
"Order Item ID" : 643, | |
"Order ID" : 298, | |
"Total Order Price" : 3996.0 | |
}, { | |
"Item Total Price" : 1998.0, | |
"Order Item ID" : 643, | |
"Order ID" : 298, | |
"Total Order Price" : 3996.0 | |
} ]; | |
if (Object.keys(examples).length > 0) { | |
resolve(examples[Object.keys(examples)[0]]); | |
} else { | |
resolve(); | |
} | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment