@zauru-sdk/graphql 2.0.56 → 2.0.59

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.
@@ -101,6 +101,7 @@ export declare const getSuggestedPricesStringQuery: (config?: {
101
101
  withItems: boolean;
102
102
  withItemCategories: boolean;
103
103
  onlyCurrent: boolean;
104
+ item_super_category_id?: number;
104
105
  }) => string;
105
106
  export declare const getPaymentTermsStringQuery: (config?: {
106
107
  includeDiscounts: boolean;
@@ -1195,6 +1195,9 @@ const getSuggestedPricesStringQuery = (config = {
1195
1195
  onlyCurrent: false,
1196
1196
  }) => {
1197
1197
  const conditions = [];
1198
+ if (config.item_super_category_id) {
1199
+ conditions.push(`item: { item_category: { item_super_category_id: { _eq: ${config.item_super_category_id} } } }`);
1200
+ }
1198
1201
  if (config.onlyCurrent) {
1199
1202
  conditions.push("current: { _eq: true }");
1200
1203
  }
@@ -1224,7 +1227,7 @@ const getSuggestedPricesStringQuery = (config = {
1224
1227
  }`
1225
1228
  : "";
1226
1229
  return `query getSuggestedPrices {
1227
- suggested_prices ${whereClause} {
1230
+ suggested_prices (${whereClause}) {
1228
1231
  id
1229
1232
  current
1230
1233
  currency_id
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zauru-sdk/graphql",
3
- "version": "2.0.56",
3
+ "version": "2.0.59",
4
4
  "description": "Queries de uso común para las aplicación de Zauru.",
5
5
  "main": "./dist/esm/index.js",
6
6
  "module": "./dist/esm/index.js",
@@ -21,5 +21,5 @@
21
21
  "devDependencies": {
22
22
  "typescript": "^5.1.6"
23
23
  },
24
- "gitHead": "f9ddbf6017cf7b1afff51c9e4edfb11ba2ea1bb6"
24
+ "gitHead": "af9f6f6e6e78e9effa761dd0afe9608996777344"
25
25
  }