@fctc/interface-logic 2.9.5 → 2.9.6
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/configs.d.mts +6 -6
- package/dist/configs.d.ts +6 -6
- package/dist/configs.js +1005 -30
- package/dist/configs.mjs +1005 -30
- package/dist/environment.d.mts +1 -1
- package/dist/environment.d.ts +1 -1
- package/dist/environment.js +1005 -30
- package/dist/environment.mjs +1005 -30
- package/dist/provider.d.mts +2 -1
- package/dist/provider.d.ts +2 -1
- package/dist/provider.js +67 -30
- package/dist/provider.mjs +67 -30
- package/dist/{session-storage-ARp_lhTD.d.mts → session-storage-DP3fkZ2Q.d.mts} +11 -1
- package/dist/{session-storage-ARp_lhTD.d.ts → session-storage-DP3fkZ2Q.d.ts} +11 -1
- package/package.json +90 -90
package/dist/provider.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { L as LocalStorageUtilsType, S as SessionStorageUtilsType } from './session-storage-
|
|
3
|
+
import { L as LocalStorageUtilsType, S as SessionStorageUtilsType } from './session-storage-DP3fkZ2Q.mjs';
|
|
4
4
|
import { useForgotPassword, useForgotPasswordSSO, useGetProvider, useIsValidToken, useLoginCredential, useLoginSocial, useResetPassword, useResetPasswordSSO, useUpdatePassword, useLogout, useGetAccessByCode, useValidateActionToken, useGetCompanyInfo, useGetCurrentCompany, useGetListCompany, useExecuteImport, useExportExcel, useGetFieldExport, useGetFileExcel, useParsePreview, useUploadFileExcel, useUploadIdFile, useChangeStatus, useDeleteComment, useGetComment, useGetFormView, useGetImage, useSendComment, useUploadImage, useDelete, useGetAll, useGetConversionRate, useGetCurrency, useGetDetail, useGetFieldOnChange, useGetListMyBankAccount, useModel, useOdooDataTransform, useOnChangeForm, useSave, useGetProfile, useGetUser, useSwitchLocale, useButton, useDuplicateRecord, useGet2FAMethods, useGetActionDetail, useGetCalendar, useGetGroups, useGetListData, useGetMenu, useGetPrintReport, useGetProGressBar, useGetResequence, useGetSelection, useGetView, useLoadAction, useLoadMessage, usePrint, useRemoveRow, useRunAction, useSignInSSO, useVerify2FA, useGrantAccess, useRemoveTotpSetup, useRequestSetupTotp, useSettingsWebRead2fa, useVerifyTotp, useUploadFile, useCreateEntity, useGetASession, useCreateSession, useDeleteEntity, useGetList, useGetPos, useHandleClosingSession, useManageSession, useUpdateClosedSession, useUpdateEntity, useLoadDataPosSession, useManageOnChange, useGenSerialNumber, useGetOrderLine, useGetProductImage, useAddEntity, useCheckPayment } from './hooks.mjs';
|
|
5
5
|
import '@tanstack/react-query';
|
|
6
6
|
import './view-type-xxw9OeSR.mjs';
|
|
@@ -44,6 +44,7 @@ interface EnvConfig {
|
|
|
44
44
|
localStorageUtils?: LocalStorageUtilsType;
|
|
45
45
|
sessionStorageUtils?: SessionStorageUtilsType;
|
|
46
46
|
envFile?: any;
|
|
47
|
+
xNode?: string;
|
|
47
48
|
}
|
|
48
49
|
declare function EnvProvider({ children, localStorageUtils: localStorageUtil, sessionStorageUtils: sessionStorageUtil, }: {
|
|
49
50
|
children: React.ReactNode;
|
package/dist/provider.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { L as LocalStorageUtilsType, S as SessionStorageUtilsType } from './session-storage-
|
|
3
|
+
import { L as LocalStorageUtilsType, S as SessionStorageUtilsType } from './session-storage-DP3fkZ2Q.js';
|
|
4
4
|
import { useForgotPassword, useForgotPasswordSSO, useGetProvider, useIsValidToken, useLoginCredential, useLoginSocial, useResetPassword, useResetPasswordSSO, useUpdatePassword, useLogout, useGetAccessByCode, useValidateActionToken, useGetCompanyInfo, useGetCurrentCompany, useGetListCompany, useExecuteImport, useExportExcel, useGetFieldExport, useGetFileExcel, useParsePreview, useUploadFileExcel, useUploadIdFile, useChangeStatus, useDeleteComment, useGetComment, useGetFormView, useGetImage, useSendComment, useUploadImage, useDelete, useGetAll, useGetConversionRate, useGetCurrency, useGetDetail, useGetFieldOnChange, useGetListMyBankAccount, useModel, useOdooDataTransform, useOnChangeForm, useSave, useGetProfile, useGetUser, useSwitchLocale, useButton, useDuplicateRecord, useGet2FAMethods, useGetActionDetail, useGetCalendar, useGetGroups, useGetListData, useGetMenu, useGetPrintReport, useGetProGressBar, useGetResequence, useGetSelection, useGetView, useLoadAction, useLoadMessage, usePrint, useRemoveRow, useRunAction, useSignInSSO, useVerify2FA, useGrantAccess, useRemoveTotpSetup, useRequestSetupTotp, useSettingsWebRead2fa, useVerifyTotp, useUploadFile, useCreateEntity, useGetASession, useCreateSession, useDeleteEntity, useGetList, useGetPos, useHandleClosingSession, useManageSession, useUpdateClosedSession, useUpdateEntity, useLoadDataPosSession, useManageOnChange, useGenSerialNumber, useGetOrderLine, useGetProductImage, useAddEntity, useCheckPayment } from './hooks.js';
|
|
5
5
|
import '@tanstack/react-query';
|
|
6
6
|
import './view-type-xxw9OeSR.js';
|
|
@@ -44,6 +44,7 @@ interface EnvConfig {
|
|
|
44
44
|
localStorageUtils?: LocalStorageUtilsType;
|
|
45
45
|
sessionStorageUtils?: SessionStorageUtilsType;
|
|
46
46
|
envFile?: any;
|
|
47
|
+
xNode?: string;
|
|
47
48
|
}
|
|
48
49
|
declare function EnvProvider({ children, localStorageUtils: localStorageUtil, sessionStorageUtils: sessionStorageUtil, }: {
|
|
49
50
|
children: React.ReactNode;
|
package/dist/provider.js
CHANGED
|
@@ -5250,10 +5250,41 @@ var localStorageUtils = () => {
|
|
|
5250
5250
|
|
|
5251
5251
|
// src/utils/storage/session-storage.ts
|
|
5252
5252
|
var sessionStorageUtils = () => {
|
|
5253
|
-
const
|
|
5254
|
-
|
|
5253
|
+
const getMenuFocus = () => {
|
|
5254
|
+
const menuFocus = sessionStorage.getItem("menuFocus");
|
|
5255
|
+
return menuFocus ? JSON.parse(menuFocus) : {
|
|
5256
|
+
id: void 0,
|
|
5257
|
+
service: ""
|
|
5258
|
+
};
|
|
5259
|
+
};
|
|
5260
|
+
const setMenuFocus2 = (menuTree) => {
|
|
5261
|
+
sessionStorage.setItem("menuFocus", JSON.stringify({ ...menuTree }));
|
|
5262
|
+
};
|
|
5263
|
+
const getActionData = () => {
|
|
5264
|
+
const actionData = sessionStorage.getItem("actionData");
|
|
5265
|
+
return actionData ? JSON.parse(actionData) : {};
|
|
5266
|
+
};
|
|
5267
|
+
const setActionData = (actData) => {
|
|
5268
|
+
sessionStorage.setItem("actionData", JSON.stringify(actData));
|
|
5269
|
+
};
|
|
5270
|
+
const getViewData = () => {
|
|
5271
|
+
const viewData = sessionStorage.getItem("viewData");
|
|
5272
|
+
return viewData ? JSON.parse(viewData) : {};
|
|
5273
|
+
};
|
|
5274
|
+
const getBrowserSession = () => {
|
|
5275
|
+
const actionData = sessionStorage.getItem("browserSession");
|
|
5276
|
+
return actionData ? JSON.parse(actionData) : null;
|
|
5277
|
+
};
|
|
5278
|
+
const setViewData = (viewData) => {
|
|
5279
|
+
sessionStorage.setItem("viewData", JSON.stringify(viewData));
|
|
5255
5280
|
};
|
|
5256
5281
|
return {
|
|
5282
|
+
getMenuFocus,
|
|
5283
|
+
setMenuFocus: setMenuFocus2,
|
|
5284
|
+
setActionData,
|
|
5285
|
+
getActionData,
|
|
5286
|
+
getViewData,
|
|
5287
|
+
setViewData,
|
|
5257
5288
|
getBrowserSession
|
|
5258
5289
|
};
|
|
5259
5290
|
};
|
|
@@ -5261,12 +5292,16 @@ var sessionStorageUtils = () => {
|
|
|
5261
5292
|
// src/configs/axios-client.ts
|
|
5262
5293
|
var axiosClient = {
|
|
5263
5294
|
init(config) {
|
|
5295
|
+
console.log("config", config);
|
|
5264
5296
|
const localStorage2 = config?.localStorageUtils ?? localStorageUtils();
|
|
5265
5297
|
const sessionStorage2 = config?.sessionStorageUtils ?? sessionStorageUtils();
|
|
5266
5298
|
const db = config?.db;
|
|
5267
5299
|
const database = config?.config?.database;
|
|
5268
5300
|
let isRefreshing = false;
|
|
5269
5301
|
let failedQueue = [];
|
|
5302
|
+
const { env } = useEnv();
|
|
5303
|
+
const xNode = config?.xNode;
|
|
5304
|
+
const service = sessionStorageUtils().getMenuFocus().service || env?.default_service;
|
|
5270
5305
|
const processQueue = (error, token = null) => {
|
|
5271
5306
|
failedQueue?.forEach((prom) => {
|
|
5272
5307
|
if (error) {
|
|
@@ -5421,46 +5456,48 @@ var axiosClient = {
|
|
|
5421
5456
|
function formatUrl(url, db2) {
|
|
5422
5457
|
return url + (db2 ? "?db=" + db2 : "");
|
|
5423
5458
|
}
|
|
5424
|
-
const getBaseUrl = (baseUrl
|
|
5425
|
-
const service = serviceName || config?.default_service;
|
|
5459
|
+
const getBaseUrl = (baseUrl) => {
|
|
5426
5460
|
return config?.default_service === "" ? `${baseUrl.replace(/\/$/, "")}/api/v2` : `${baseUrl.replace(/\/$/, "")}/${service}/api/v2`;
|
|
5427
5461
|
};
|
|
5462
|
+
const getHeaders = (header) => {
|
|
5463
|
+
const headers = {
|
|
5464
|
+
...header,
|
|
5465
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5466
|
+
};
|
|
5467
|
+
return headers;
|
|
5468
|
+
};
|
|
5428
5469
|
const responseBody = (response) => response;
|
|
5429
5470
|
const requests = {
|
|
5430
|
-
get: (url, headers
|
|
5431
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5432
|
-
headers
|
|
5471
|
+
get: (url, headers) => instance.get(
|
|
5472
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5473
|
+
getHeaders(headers)
|
|
5433
5474
|
).then(responseBody),
|
|
5434
|
-
post: async (url, body, headers
|
|
5435
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5475
|
+
post: async (url, body, headers) => instance.post(
|
|
5476
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5436
5477
|
body,
|
|
5437
|
-
headers
|
|
5478
|
+
getHeaders(headers)
|
|
5438
5479
|
).then(responseBody),
|
|
5439
|
-
post_excel: (url, body, headers
|
|
5440
|
-
|
|
5441
|
-
|
|
5442
|
-
|
|
5443
|
-
|
|
5444
|
-
headers
|
|
5445
|
-
"Content-Type": typeof window !== "undefined" ? "application/json" : "application/javascript",
|
|
5446
|
-
Accept: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
5447
|
-
...headers
|
|
5448
|
-
}
|
|
5480
|
+
post_excel: (url, body, headers) => instance.post(formatUrl(getBaseUrl(config?.baseUrl) + url, db), body, {
|
|
5481
|
+
responseType: "arraybuffer",
|
|
5482
|
+
headers: {
|
|
5483
|
+
"Content-Type": typeof window !== "undefined" ? "application/json" : "application/javascript",
|
|
5484
|
+
Accept: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
5485
|
+
...headers
|
|
5449
5486
|
}
|
|
5450
|
-
).then(responseBody),
|
|
5451
|
-
put: (url, body, headers
|
|
5452
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5487
|
+
}).then(responseBody),
|
|
5488
|
+
put: (url, body, headers) => instance.put(
|
|
5489
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5453
5490
|
body,
|
|
5454
|
-
headers
|
|
5491
|
+
getHeaders(headers)
|
|
5455
5492
|
).then(responseBody),
|
|
5456
|
-
patch: (url, body, headers
|
|
5457
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5493
|
+
patch: (url, body, headers) => instance.patch(
|
|
5494
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5458
5495
|
body,
|
|
5459
|
-
headers
|
|
5496
|
+
getHeaders(headers)
|
|
5460
5497
|
).then(responseBody),
|
|
5461
|
-
delete: (url, headers
|
|
5462
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5463
|
-
headers
|
|
5498
|
+
delete: (url, headers) => instance.delete(
|
|
5499
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5500
|
+
getHeaders(headers)
|
|
5464
5501
|
).then(responseBody)
|
|
5465
5502
|
};
|
|
5466
5503
|
return requests;
|
package/dist/provider.mjs
CHANGED
|
@@ -5207,10 +5207,41 @@ var localStorageUtils = () => {
|
|
|
5207
5207
|
|
|
5208
5208
|
// src/utils/storage/session-storage.ts
|
|
5209
5209
|
var sessionStorageUtils = () => {
|
|
5210
|
-
const
|
|
5211
|
-
|
|
5210
|
+
const getMenuFocus = () => {
|
|
5211
|
+
const menuFocus = sessionStorage.getItem("menuFocus");
|
|
5212
|
+
return menuFocus ? JSON.parse(menuFocus) : {
|
|
5213
|
+
id: void 0,
|
|
5214
|
+
service: ""
|
|
5215
|
+
};
|
|
5216
|
+
};
|
|
5217
|
+
const setMenuFocus2 = (menuTree) => {
|
|
5218
|
+
sessionStorage.setItem("menuFocus", JSON.stringify({ ...menuTree }));
|
|
5219
|
+
};
|
|
5220
|
+
const getActionData = () => {
|
|
5221
|
+
const actionData = sessionStorage.getItem("actionData");
|
|
5222
|
+
return actionData ? JSON.parse(actionData) : {};
|
|
5223
|
+
};
|
|
5224
|
+
const setActionData = (actData) => {
|
|
5225
|
+
sessionStorage.setItem("actionData", JSON.stringify(actData));
|
|
5226
|
+
};
|
|
5227
|
+
const getViewData = () => {
|
|
5228
|
+
const viewData = sessionStorage.getItem("viewData");
|
|
5229
|
+
return viewData ? JSON.parse(viewData) : {};
|
|
5230
|
+
};
|
|
5231
|
+
const getBrowserSession = () => {
|
|
5232
|
+
const actionData = sessionStorage.getItem("browserSession");
|
|
5233
|
+
return actionData ? JSON.parse(actionData) : null;
|
|
5234
|
+
};
|
|
5235
|
+
const setViewData = (viewData) => {
|
|
5236
|
+
sessionStorage.setItem("viewData", JSON.stringify(viewData));
|
|
5212
5237
|
};
|
|
5213
5238
|
return {
|
|
5239
|
+
getMenuFocus,
|
|
5240
|
+
setMenuFocus: setMenuFocus2,
|
|
5241
|
+
setActionData,
|
|
5242
|
+
getActionData,
|
|
5243
|
+
getViewData,
|
|
5244
|
+
setViewData,
|
|
5214
5245
|
getBrowserSession
|
|
5215
5246
|
};
|
|
5216
5247
|
};
|
|
@@ -5218,12 +5249,16 @@ var sessionStorageUtils = () => {
|
|
|
5218
5249
|
// src/configs/axios-client.ts
|
|
5219
5250
|
var axiosClient = {
|
|
5220
5251
|
init(config) {
|
|
5252
|
+
console.log("config", config);
|
|
5221
5253
|
const localStorage2 = config?.localStorageUtils ?? localStorageUtils();
|
|
5222
5254
|
const sessionStorage2 = config?.sessionStorageUtils ?? sessionStorageUtils();
|
|
5223
5255
|
const db = config?.db;
|
|
5224
5256
|
const database = config?.config?.database;
|
|
5225
5257
|
let isRefreshing = false;
|
|
5226
5258
|
let failedQueue = [];
|
|
5259
|
+
const { env } = useEnv();
|
|
5260
|
+
const xNode = config?.xNode;
|
|
5261
|
+
const service = sessionStorageUtils().getMenuFocus().service || env?.default_service;
|
|
5227
5262
|
const processQueue = (error, token = null) => {
|
|
5228
5263
|
failedQueue?.forEach((prom) => {
|
|
5229
5264
|
if (error) {
|
|
@@ -5378,46 +5413,48 @@ var axiosClient = {
|
|
|
5378
5413
|
function formatUrl(url, db2) {
|
|
5379
5414
|
return url + (db2 ? "?db=" + db2 : "");
|
|
5380
5415
|
}
|
|
5381
|
-
const getBaseUrl = (baseUrl
|
|
5382
|
-
const service = serviceName || config?.default_service;
|
|
5416
|
+
const getBaseUrl = (baseUrl) => {
|
|
5383
5417
|
return config?.default_service === "" ? `${baseUrl.replace(/\/$/, "")}/api/v2` : `${baseUrl.replace(/\/$/, "")}/${service}/api/v2`;
|
|
5384
5418
|
};
|
|
5419
|
+
const getHeaders = (header) => {
|
|
5420
|
+
const headers = {
|
|
5421
|
+
...header,
|
|
5422
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5423
|
+
};
|
|
5424
|
+
return headers;
|
|
5425
|
+
};
|
|
5385
5426
|
const responseBody = (response) => response;
|
|
5386
5427
|
const requests = {
|
|
5387
|
-
get: (url, headers
|
|
5388
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5389
|
-
headers
|
|
5428
|
+
get: (url, headers) => instance.get(
|
|
5429
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5430
|
+
getHeaders(headers)
|
|
5390
5431
|
).then(responseBody),
|
|
5391
|
-
post: async (url, body, headers
|
|
5392
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5432
|
+
post: async (url, body, headers) => instance.post(
|
|
5433
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5393
5434
|
body,
|
|
5394
|
-
headers
|
|
5435
|
+
getHeaders(headers)
|
|
5395
5436
|
).then(responseBody),
|
|
5396
|
-
post_excel: (url, body, headers
|
|
5397
|
-
|
|
5398
|
-
|
|
5399
|
-
|
|
5400
|
-
|
|
5401
|
-
headers
|
|
5402
|
-
"Content-Type": typeof window !== "undefined" ? "application/json" : "application/javascript",
|
|
5403
|
-
Accept: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
5404
|
-
...headers
|
|
5405
|
-
}
|
|
5437
|
+
post_excel: (url, body, headers) => instance.post(formatUrl(getBaseUrl(config?.baseUrl) + url, db), body, {
|
|
5438
|
+
responseType: "arraybuffer",
|
|
5439
|
+
headers: {
|
|
5440
|
+
"Content-Type": typeof window !== "undefined" ? "application/json" : "application/javascript",
|
|
5441
|
+
Accept: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
5442
|
+
...headers
|
|
5406
5443
|
}
|
|
5407
|
-
).then(responseBody),
|
|
5408
|
-
put: (url, body, headers
|
|
5409
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5444
|
+
}).then(responseBody),
|
|
5445
|
+
put: (url, body, headers) => instance.put(
|
|
5446
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5410
5447
|
body,
|
|
5411
|
-
headers
|
|
5448
|
+
getHeaders(headers)
|
|
5412
5449
|
).then(responseBody),
|
|
5413
|
-
patch: (url, body, headers
|
|
5414
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5450
|
+
patch: (url, body, headers) => instance.patch(
|
|
5451
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5415
5452
|
body,
|
|
5416
|
-
headers
|
|
5453
|
+
getHeaders(headers)
|
|
5417
5454
|
).then(responseBody),
|
|
5418
|
-
delete: (url, headers
|
|
5419
|
-
formatUrl(getBaseUrl(config?.baseUrl
|
|
5420
|
-
headers
|
|
5455
|
+
delete: (url, headers) => instance.delete(
|
|
5456
|
+
formatUrl(getBaseUrl(config?.baseUrl) + url, db),
|
|
5457
|
+
getHeaders(headers)
|
|
5421
5458
|
).then(responseBody)
|
|
5422
5459
|
};
|
|
5423
5460
|
return requests;
|
|
@@ -8,8 +8,18 @@ declare const localStorageUtils: () => {
|
|
|
8
8
|
type LocalStorageUtilsType = ReturnType<typeof localStorageUtils>;
|
|
9
9
|
|
|
10
10
|
declare const sessionStorageUtils: () => {
|
|
11
|
-
|
|
11
|
+
getMenuFocus: () => IMenu;
|
|
12
|
+
setMenuFocus: (menuTree: IMenu) => void;
|
|
13
|
+
setActionData: (actData: any) => void;
|
|
14
|
+
getActionData: () => any | null;
|
|
15
|
+
getViewData: () => any | null;
|
|
16
|
+
setViewData: (viewData: any) => void;
|
|
17
|
+
getBrowserSession: () => string | null;
|
|
12
18
|
};
|
|
19
|
+
interface IMenu {
|
|
20
|
+
id: number | undefined;
|
|
21
|
+
service: string;
|
|
22
|
+
}
|
|
13
23
|
type SessionStorageUtilsType = ReturnType<typeof sessionStorageUtils>;
|
|
14
24
|
|
|
15
25
|
export type { LocalStorageUtilsType as L, SessionStorageUtilsType as S };
|
|
@@ -8,8 +8,18 @@ declare const localStorageUtils: () => {
|
|
|
8
8
|
type LocalStorageUtilsType = ReturnType<typeof localStorageUtils>;
|
|
9
9
|
|
|
10
10
|
declare const sessionStorageUtils: () => {
|
|
11
|
-
|
|
11
|
+
getMenuFocus: () => IMenu;
|
|
12
|
+
setMenuFocus: (menuTree: IMenu) => void;
|
|
13
|
+
setActionData: (actData: any) => void;
|
|
14
|
+
getActionData: () => any | null;
|
|
15
|
+
getViewData: () => any | null;
|
|
16
|
+
setViewData: (viewData: any) => void;
|
|
17
|
+
getBrowserSession: () => string | null;
|
|
12
18
|
};
|
|
19
|
+
interface IMenu {
|
|
20
|
+
id: number | undefined;
|
|
21
|
+
service: string;
|
|
22
|
+
}
|
|
13
23
|
type SessionStorageUtilsType = ReturnType<typeof sessionStorageUtils>;
|
|
14
24
|
|
|
15
25
|
export type { LocalStorageUtilsType as L, SessionStorageUtilsType as S };
|
package/package.json
CHANGED
|
@@ -1,90 +1,90 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@fctc/interface-logic",
|
|
3
|
-
"version": "2.9.
|
|
4
|
-
"types": "dist/index.d.ts",
|
|
5
|
-
"main": "dist/index.cjs",
|
|
6
|
-
"module": "dist/index.mjs",
|
|
7
|
-
"exports": {
|
|
8
|
-
".": {
|
|
9
|
-
"types": "./dist/index.d.ts",
|
|
10
|
-
"import": "./dist/index.mjs",
|
|
11
|
-
"require": "./dist/index.cjs"
|
|
12
|
-
},
|
|
13
|
-
"./configs": {
|
|
14
|
-
"types": "./dist/configs.d.ts",
|
|
15
|
-
"import": "./dist/configs.mjs",
|
|
16
|
-
"require": "./dist/configs.cjs"
|
|
17
|
-
},
|
|
18
|
-
"./constants": {
|
|
19
|
-
"types": "./dist/constants.d.ts",
|
|
20
|
-
"import": "./dist/constants.mjs",
|
|
21
|
-
"require": "./dist/constants.cjs"
|
|
22
|
-
},
|
|
23
|
-
"./environment": {
|
|
24
|
-
"types": "./dist/environment.d.ts",
|
|
25
|
-
"import": "./dist/environment.mjs",
|
|
26
|
-
"require": "./dist/environment.cjs"
|
|
27
|
-
},
|
|
28
|
-
"./hooks": {
|
|
29
|
-
"types": "./dist/hooks.d.ts",
|
|
30
|
-
"import": "./dist/hooks.mjs",
|
|
31
|
-
"require": "./dist/hooks.cjs"
|
|
32
|
-
},
|
|
33
|
-
"./provider": {
|
|
34
|
-
"types": "./dist/provider.d.ts",
|
|
35
|
-
"import": "./dist/provider.mjs",
|
|
36
|
-
"require": "./dist/provider.cjs"
|
|
37
|
-
},
|
|
38
|
-
"./services": {
|
|
39
|
-
"types": "./dist/services.d.ts",
|
|
40
|
-
"import": "./dist/services.mjs",
|
|
41
|
-
"require": "./dist/services.cjs"
|
|
42
|
-
},
|
|
43
|
-
"./store": {
|
|
44
|
-
"types": "./dist/store.d.ts",
|
|
45
|
-
"import": "./dist/store.mjs",
|
|
46
|
-
"require": "./dist/store.cjs"
|
|
47
|
-
},
|
|
48
|
-
"./utils": {
|
|
49
|
-
"types": "./dist/utils.d.ts",
|
|
50
|
-
"import": "./dist/utils.mjs",
|
|
51
|
-
"require": "./dist/utils.cjs"
|
|
52
|
-
},
|
|
53
|
-
"./types": {
|
|
54
|
-
"types": "./dist/types.d.ts",
|
|
55
|
-
"import": "./dist/types.mjs",
|
|
56
|
-
"require": "./dist/types.cjs"
|
|
57
|
-
},
|
|
58
|
-
"./models": {
|
|
59
|
-
"types": "./dist/models.d.ts",
|
|
60
|
-
"import": "./dist/models.mjs",
|
|
61
|
-
"require": "./dist/models.cjs"
|
|
62
|
-
}
|
|
63
|
-
},
|
|
64
|
-
"files": [
|
|
65
|
-
"dist"
|
|
66
|
-
],
|
|
67
|
-
"scripts": {
|
|
68
|
-
"build": "tsup",
|
|
69
|
-
"test": "jest"
|
|
70
|
-
},
|
|
71
|
-
"peerDependencies": {
|
|
72
|
-
"react": "18.0.0",
|
|
73
|
-
"@tanstack/react-query": "^5.83.0"
|
|
74
|
-
},
|
|
75
|
-
"dependencies": {
|
|
76
|
-
"@reduxjs/toolkit": "^2.8.2",
|
|
77
|
-
"@tanstack/react-query": "^5.83.0",
|
|
78
|
-
"axios": "^1.11.0",
|
|
79
|
-
"moment": "^2.30.1",
|
|
80
|
-
"react-redux": "^9.2.0"
|
|
81
|
-
},
|
|
82
|
-
"devDependencies": {
|
|
83
|
-
"@types/react": "^18.3.1",
|
|
84
|
-
"react": "18.0.0",
|
|
85
|
-
"jest": "^29.7.0",
|
|
86
|
-
"tsup": "^8.0.0",
|
|
87
|
-
"typescript": "^5.8.2"
|
|
88
|
-
},
|
|
89
|
-
"packageManager": "yarn@1.22.0"
|
|
90
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@fctc/interface-logic",
|
|
3
|
+
"version": "2.9.6",
|
|
4
|
+
"types": "dist/index.d.ts",
|
|
5
|
+
"main": "dist/index.cjs",
|
|
6
|
+
"module": "dist/index.mjs",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"types": "./dist/index.d.ts",
|
|
10
|
+
"import": "./dist/index.mjs",
|
|
11
|
+
"require": "./dist/index.cjs"
|
|
12
|
+
},
|
|
13
|
+
"./configs": {
|
|
14
|
+
"types": "./dist/configs.d.ts",
|
|
15
|
+
"import": "./dist/configs.mjs",
|
|
16
|
+
"require": "./dist/configs.cjs"
|
|
17
|
+
},
|
|
18
|
+
"./constants": {
|
|
19
|
+
"types": "./dist/constants.d.ts",
|
|
20
|
+
"import": "./dist/constants.mjs",
|
|
21
|
+
"require": "./dist/constants.cjs"
|
|
22
|
+
},
|
|
23
|
+
"./environment": {
|
|
24
|
+
"types": "./dist/environment.d.ts",
|
|
25
|
+
"import": "./dist/environment.mjs",
|
|
26
|
+
"require": "./dist/environment.cjs"
|
|
27
|
+
},
|
|
28
|
+
"./hooks": {
|
|
29
|
+
"types": "./dist/hooks.d.ts",
|
|
30
|
+
"import": "./dist/hooks.mjs",
|
|
31
|
+
"require": "./dist/hooks.cjs"
|
|
32
|
+
},
|
|
33
|
+
"./provider": {
|
|
34
|
+
"types": "./dist/provider.d.ts",
|
|
35
|
+
"import": "./dist/provider.mjs",
|
|
36
|
+
"require": "./dist/provider.cjs"
|
|
37
|
+
},
|
|
38
|
+
"./services": {
|
|
39
|
+
"types": "./dist/services.d.ts",
|
|
40
|
+
"import": "./dist/services.mjs",
|
|
41
|
+
"require": "./dist/services.cjs"
|
|
42
|
+
},
|
|
43
|
+
"./store": {
|
|
44
|
+
"types": "./dist/store.d.ts",
|
|
45
|
+
"import": "./dist/store.mjs",
|
|
46
|
+
"require": "./dist/store.cjs"
|
|
47
|
+
},
|
|
48
|
+
"./utils": {
|
|
49
|
+
"types": "./dist/utils.d.ts",
|
|
50
|
+
"import": "./dist/utils.mjs",
|
|
51
|
+
"require": "./dist/utils.cjs"
|
|
52
|
+
},
|
|
53
|
+
"./types": {
|
|
54
|
+
"types": "./dist/types.d.ts",
|
|
55
|
+
"import": "./dist/types.mjs",
|
|
56
|
+
"require": "./dist/types.cjs"
|
|
57
|
+
},
|
|
58
|
+
"./models": {
|
|
59
|
+
"types": "./dist/models.d.ts",
|
|
60
|
+
"import": "./dist/models.mjs",
|
|
61
|
+
"require": "./dist/models.cjs"
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"files": [
|
|
65
|
+
"dist"
|
|
66
|
+
],
|
|
67
|
+
"scripts": {
|
|
68
|
+
"build": "tsup",
|
|
69
|
+
"test": "jest"
|
|
70
|
+
},
|
|
71
|
+
"peerDependencies": {
|
|
72
|
+
"react": "18.0.0",
|
|
73
|
+
"@tanstack/react-query": "^5.83.0"
|
|
74
|
+
},
|
|
75
|
+
"dependencies": {
|
|
76
|
+
"@reduxjs/toolkit": "^2.8.2",
|
|
77
|
+
"@tanstack/react-query": "^5.83.0",
|
|
78
|
+
"axios": "^1.11.0",
|
|
79
|
+
"moment": "^2.30.1",
|
|
80
|
+
"react-redux": "^9.2.0"
|
|
81
|
+
},
|
|
82
|
+
"devDependencies": {
|
|
83
|
+
"@types/react": "^18.3.1",
|
|
84
|
+
"react": "18.0.0",
|
|
85
|
+
"jest": "^29.7.0",
|
|
86
|
+
"tsup": "^8.0.0",
|
|
87
|
+
"typescript": "^5.8.2"
|
|
88
|
+
},
|
|
89
|
+
"packageManager": "yarn@1.22.0"
|
|
90
|
+
}
|