Created
November 3, 2015 15:23
-
-
Save erikpantzar/c7f065b9f9ab18f3353a to your computer and use it in GitHub Desktop.
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
| var queryObj = { | |
| query: "organic", | |
| categories: ['refreshments'] | |
| brands: [] | |
| }; | |
| var searchObject = { | |
| "QueryString": queryObj.query, | |
| "DirectResults_FromIndex": 0, | |
| "DirectResults_ToIndex": 19, | |
| "RecomendedResults_FromIndex": 0, | |
| "RecomendedResults_ToIndex": 19, | |
| "UserId": "sNa8ziAYS5", | |
| "Faceting": { | |
| "Categories": queryObj.categories, | |
| "Brands": queryObj.brands | |
| }, | |
| "IP": "000.000.000.00" | |
| }; | |
| $http.post(api.loop54.search, searchObject, {withCredentials: false}) | |
| .then(function(response) { | |
| search.result = response.data; | |
| callback(response); | |
| console.group('Query w Facets'); | |
| console.log(queryObj); | |
| console.log(search.result); | |
| console.groupEnd(); | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment