sysone-api-mapper 1.0.151 → 1.0.152
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.
- package/dist/src/adapters/financeAdapter.d.ts +1 -0
- package/dist/src/adapters/financeAdapter.js +2 -1
- package/dist/src/contexts/actionsContext.d.ts +2 -1
- package/dist/src/contexts/apiContext.d.ts +3 -2
- package/dist/src/contexts/apiContext.js +1 -1
- package/dist/src/contexts/translationContext.d.ts +2 -1
- package/dist/src/mapper/endpointsConfig.d.ts +671 -656
- package/dist/src/mapper/endpointsConfig.js +8 -0
- package/package.json +5 -2
|
@@ -5,6 +5,7 @@ const Mapper_1 = require("../mapper/Mapper");
|
|
|
5
5
|
const financeAdapter = (tenant) => ({
|
|
6
6
|
getCurrencies: () => (0, Mapper_1.apiMapper)("GET_CURRENCIES", tenant),
|
|
7
7
|
getPaymentFrecuencies: () => (0, Mapper_1.apiMapper)("GET_PAYMENT_FRECUENCIES", tenant),
|
|
8
|
-
getBanks: () => (0, Mapper_1.apiMapper)("GET_BANKS", tenant)
|
|
8
|
+
getBanks: () => (0, Mapper_1.apiMapper)("GET_BANKS", tenant),
|
|
9
|
+
getCardTypes: () => (0, Mapper_1.apiMapper)("GET_CREDIT_CARD_TYPES", tenant)
|
|
9
10
|
});
|
|
10
11
|
exports.financeAdapter = financeAdapter;
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
export
|
|
1
|
+
import type { Api } from "../adapters/createApiAdapter";
|
|
2
|
+
export declare const ApiContext: import("react").Context<Api | undefined>;
|
|
3
|
+
export declare const useApi: () => Api;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.useApi = exports.ApiContext = void 0;
|
|
4
4
|
const react_1 = require("react");
|
|
5
|
-
exports.ApiContext = (0, react_1.createContext)(
|
|
5
|
+
exports.ApiContext = (0, react_1.createContext)(undefined);
|
|
6
6
|
const useApi = () => {
|
|
7
7
|
const ctx = (0, react_1.useContext)(exports.ApiContext);
|
|
8
8
|
if (!ctx)
|