@nodeart/dal
Advanced tools
Comparing version 1.0.1 to 1.0.2
{ | ||
"name": "@nodeart/dal", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "Bridge for database connector(for now only Firebase).", | ||
@@ -12,5 +12,5 @@ "main": "index.ts", | ||
"dependencies": { | ||
"@nodeart/firebaseconnector": "^1.0.3", | ||
"@nodeart/firebaseconnector": "^1.0.4", | ||
"@angular/core": "2.2.0" | ||
} | ||
} |
@@ -12,2 +12,6 @@ import { esIndex } from './consts'; | ||
addGeneralCategory(generalCategoryForm){ | ||
this.connector.addGeneralCategory(generalCategoryForm); | ||
} | ||
addCategory(categoryForm){ | ||
@@ -25,6 +29,2 @@ this.connector.addCategory(categoryForm); | ||
addAttrToCategory(categoryId){ | ||
this.connector.getFirebaseDB().list('category/' + categoryId + "/attrs") | ||
} | ||
addProduct(product){ | ||
@@ -49,3 +49,4 @@ this.connector.addProduct(product); | ||
getBasketProductsByIds(queryObj){ | ||
getProductsByIds(queryObj){ | ||
return this.connector.requestData(esIndex, 'product', queryObj); | ||
@@ -62,2 +63,6 @@ } | ||
getСomparison(id){ | ||
return this.connector.getComparison(id); | ||
} | ||
addProductToBasket(id, product){ | ||
@@ -71,5 +76,17 @@ return this.connector.addProductToBasket(id, product); | ||
addProductToComparison(id, product){ | ||
return this.connector.addProductToComparison(id, product); | ||
} | ||
removeProductFromComparison(id, idInComparison){ | ||
return this.connector.removeProductFromComparison(id, idInComparison); | ||
} | ||
searchProducts(queryObj){ | ||
return this.connector.requestData(esIndex, 'product', queryObj); | ||
} | ||
getPriceRanges(queryObj){ | ||
return this.connector.requestAggregations(esIndex, 'product', queryObj); | ||
} | ||
@@ -83,2 +100,10 @@ filterProducts(queryObj){ | ||
} | ||
getGeneralCategory(queryObj){ | ||
return this.connector.requestData(esIndex, 'general-category', queryObj); | ||
} | ||
getGeneralCategories(queryObj){ | ||
return this.connector.requestData(esIndex, 'general-category', queryObj); | ||
} | ||
@@ -89,2 +114,6 @@ getCategories(queryObj){ | ||
getProductsByCategoryIds(queryObj){ | ||
return this.connector.requestData(esIndex, 'product', queryObj); | ||
} | ||
getProducts(queryObj){ | ||
@@ -121,3 +150,3 @@ return this.connector.requestData(esIndex, 'product', queryObj); | ||
} | ||
checkOldSessionFlow(deviceId){ | ||
@@ -124,0 +153,0 @@ this.connector.checkOldSessionFlow(deviceId); |
5013
145