@zauru-sdk/services 2.0.53 → 2.0.55

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.
@@ -1,7 +1,7 @@
1
1
  import { redirect } from "@remix-run/node";
2
2
  import { commitSession, getSession } from "./sessions/sessions.js";
3
3
  import chalk from "chalk";
4
- import httpZauru from "./zauru/httpZauru.js";
4
+ import { httpZauru } from "./zauru/httpZauru.js";
5
5
  import { getAgencyInfo, getEmployeeInfo, getOauthUserInfo, getProfileInformation, } from "./zauru/zauru-profiles.js";
6
6
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
7
7
  import { getVariables } from "./zauru/zauru-variables.js";
@@ -32,5 +32,4 @@ axiosInstance.interceptors.response.use(function (response) {
32
32
  console.log(chalk.red(`${msgError}`));
33
33
  throw new Error(msgError);
34
34
  });
35
- const httpZauru = axiosInstance;
36
- export default httpZauru;
35
+ export const httpZauru = axiosInstance;
@@ -1,5 +1,5 @@
1
1
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  /**
4
4
  * updateAutomaticNumber
5
5
  * @param headers
@@ -1,5 +1,5 @@
1
1
  import { arrayToObject, handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  import { getGraphQLAPIHeaders } from "../common.js";
4
4
  import httpGraphQLAPI from "./httpGraphQL.js";
5
5
  import { getShipmentsStringQuery } from "@zauru-sdk/graphql";
@@ -2,7 +2,7 @@ import { arrayToObject, handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
2
  import { getGraphQLAPIHeaders } from "../common.js";
3
3
  import httpGraphQLAPI from "./httpGraphQL.js";
4
4
  import { getBundleByNameStringQuery, getBundlesByItemCategoryIdStringQuery, } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  /**
7
7
  * getBundlesByItemCategoryId
8
8
  */
@@ -1,5 +1,5 @@
1
1
  import { formatDateToUTC, handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  import { getGraphQLAPIHeaders, getVariablesByName } from "../common.js";
4
4
  import httpGraphQLAPI from "./httpGraphQL.js";
5
5
  import { getConsolidatesBetweenDatesStringQuery } from "@zauru-sdk/graphql";
@@ -1,5 +1,5 @@
1
1
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  /**
4
4
  * getDelivery
5
5
  * @param headers
@@ -1,6 +1,6 @@
1
1
  import { getVariablesByName } from "../common.js";
2
2
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
3
- import httpZauru from "./httpZauru.js";
3
+ import { httpZauru } from "./httpZauru.js";
4
4
  /**
5
5
  *
6
6
  * @param headers
@@ -2,7 +2,7 @@ import { arrayToObject, convertToFormData, handlePossibleAxiosErrors, } from "@z
2
2
  import { getGraphQLAPIHeaders } from "../common.js";
3
3
  import httpGraphQLAPI from "./httpGraphQL.js";
4
4
  import { getAllFormsStringQuery, getFormByNameStringQuery, getFormSubmissionByIdStringQuery, getFormsByDocumentTypeStringQuery, getFormsStringQuery, getInvoiceFormSubmissionsByAgencyIdStringQuery, getInvoiceFormSubmissionsByInvoiceIdStringQuery, getLastInvoiceFormSubmissionStringQuery, getMyCaseFormSubmissionsStringQuery, } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  /**
7
7
  * getForms
8
8
  */
@@ -2,7 +2,7 @@ import { arrayToObject, handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
2
  import { getGraphQLAPIHeaders } from "../common.js";
3
3
  import httpGraphQLAPI from "./httpGraphQL.js";
4
4
  import { getInvoicesByAgencyIdStringQuery } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  /**
7
7
  * getInvoicesByAgencyId
8
8
  */
@@ -2,7 +2,7 @@ import { extractValueBetweenTags, handlePossibleAxiosErrors, } from "@zauru-sdk/
2
2
  import { getGraphQLAPIHeaders } from "../common.js";
3
3
  import httpGraphQLAPI from "./httpGraphQL.js";
4
4
  import { getItemByNameStringQuery, getItemCategoryByIdStringQuery, getItemsByCategoryStringQuery, getItemsBySuperCategoryStringQuery, getItemsStringQuery, getSuperCategoryByIdStringQuery, } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  //============================ FORMATEADO DE ITEMS
7
7
  function extractIdFromURL(input) {
8
8
  const regex = /\/items\/(\d+)/;
@@ -1,7 +1,7 @@
1
1
  import { getBasketsSchema, handlePossibleAxiosErrors, reduceAdd, truncateDecimals, } from "@zauru-sdk/common";
2
2
  import moment from "moment";
3
3
  import { getGraphQLAPIHeaders, getVariablesByName } from "../common.js";
4
- import httpZauru from "./httpZauru.js";
4
+ import { httpZauru } from "./httpZauru.js";
5
5
  import { createLoteRecord } from "./zauru-lote-record.js";
6
6
  import httpGraphQLAPI from "./httpGraphQL.js";
7
7
  import { getLotStocksByAgencyIdStringQuery, getLotsByNameStringQuery, } from "@zauru-sdk/graphql";
@@ -2,7 +2,7 @@ import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
2
  import httpGraphQLAPI from "./httpGraphQL.js";
3
3
  import { getGraphQLAPIHeaders } from "../common.js";
4
4
  import { getClientCategoriesStringQuery, getPayeeByIdStringQuery, getPayeeCategoriesByNotesMatchStringQuery, getPayeeCategoriesStringQuery, getPayeeCategoryByIdStringQuery, getPayeesStringQuery, getProviderCategoriesStringQuery, getProvidersStringQuery, } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  /**
7
7
  * getPayees
8
8
  * @param headers
@@ -2,7 +2,7 @@ import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
2
  import { getGraphQLAPIHeaders } from "../common.js";
3
3
  import httpGraphQLAPI from "./httpGraphQL.js";
4
4
  import { getPaymentTermByIdStringQuery, getPaymentTermsStringQuery, } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  /**
7
7
  * getPaymentTerms
8
8
  */
@@ -1,5 +1,5 @@
1
1
  import { arrayToObject, handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  /**
4
4
  * createInvoice
5
5
  * @param headers
@@ -1,5 +1,5 @@
1
1
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  /**
4
4
  * createPriceList
5
5
  * @param session
@@ -1,4 +1,4 @@
1
- import httpZauru from "./httpZauru.js";
1
+ import { httpZauru } from "./httpZauru.js";
2
2
  import httpOauth from "./httpOauth.js";
3
3
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
4
4
  import { config } from "@zauru-sdk/config";
@@ -1,5 +1,5 @@
1
1
  import { arrayToObject, convertToFormData, formatDateToUTC, getBasketsSchema, handlePossibleAxiosErrors, reduceAdd, } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  import { getGraphQLAPIHeaders, getVariablesByName } from "../common.js";
4
4
  import httpGraphQLAPI from "./httpGraphQL.js";
5
5
  import { getLast100ReceptionsStringQuery, getPurchaseOrderByIdNumberStringQuery, getPurchaseOrderStringQuery, getPurchaseOrdersBetweenDatesStringQuery, } from "@zauru-sdk/graphql";
@@ -1,5 +1,5 @@
1
1
  import { arrayToObject, getDatePickerCurrentDate, handlePossibleAxiosErrors, } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  /**
4
4
  * createNewReception
5
5
  * @param headers
@@ -2,7 +2,7 @@ import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
2
  import { getGraphQLAPIHeaders } from "../common.js";
3
3
  import httpGraphQLAPI from "./httpGraphQL.js";
4
4
  import { getShipmentsStringQuery } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  /**
7
7
  * getShipments
8
8
  */
@@ -1,5 +1,5 @@
1
1
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  import { getGraphQLAPIHeaders } from "../common.js";
4
4
  import httpGraphQLAPI from "./httpGraphQL.js";
5
5
  import { getSuggestedPricesStringQuery } from "@zauru-sdk/graphql";
@@ -1,5 +1,5 @@
1
1
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  /**
4
4
  * createTag
5
5
  * @param headers
@@ -1,5 +1,5 @@
1
1
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  /**
4
4
  *
5
5
  * @param headers
@@ -1,5 +1,5 @@
1
1
  import chalk from "chalk";
2
- import httpZauru from "./httpZauru.js";
2
+ import { httpZauru } from "./httpZauru.js";
3
3
  import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
4
4
  /**
5
5
  * getVariables Function for get all zauru variables
@@ -2,7 +2,7 @@ import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
2
2
  import { getGraphQLAPIHeaders, getVariablesByName } from "../common.js";
3
3
  import httpGraphQLAPI from "./httpGraphQL.js";
4
4
  import { getWebAppRowStringQuery, getWebAppRowsByWebAppTableIdStringQuery, } from "@zauru-sdk/graphql";
5
- import httpZauru from "./httpZauru.js";
5
+ import { httpZauru } from "./httpZauru.js";
6
6
  /**
7
7
  * getWebAppRow
8
8
  * @param headers
@@ -1,2 +1 @@
1
- declare const httpZauru: import("axios").AxiosInstance;
2
- export default httpZauru;
1
+ export declare const httpZauru: import("axios").AxiosInstance;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zauru-sdk/services",
3
- "version": "2.0.53",
3
+ "version": "2.0.55",
4
4
  "description": "Servicios de consulta a Zauru",
5
5
  "main": "./dist/esm/index.js",
6
6
  "module": "./dist/esm/index.js",
@@ -31,5 +31,5 @@
31
31
  "axios": "^1.6.7",
32
32
  "chalk": "5.3.0"
33
33
  },
34
- "gitHead": "7052c88abd3f37cbe402ed396bdc4c7ee8242556"
34
+ "gitHead": "d267ebc71c86b810518cccc6645c648c6453f447"
35
35
  }