@fctc/interface-logic 1.7.9 → 1.7.10
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 +4 -1
- package/dist/configs.d.ts +4 -1
- package/dist/configs.js +12 -15
- package/dist/configs.mjs +12 -15
- package/dist/environment.d.mts +36 -19
- package/dist/environment.d.ts +36 -19
- package/dist/environment.js +92 -76
- package/dist/environment.mjs +90 -76
- package/dist/hooks.d.mts +7 -2
- package/dist/hooks.d.ts +7 -2
- package/dist/hooks.js +230 -189
- package/dist/hooks.mjs +189 -149
- package/dist/provider.d.mts +3 -4
- package/dist/provider.d.ts +3 -4
- package/dist/provider.js +89 -79
- package/dist/provider.mjs +89 -79
- package/dist/services.d.mts +2 -1
- package/dist/services.d.ts +2 -1
- package/dist/services.js +104 -79
- package/dist/services.mjs +104 -79
- package/dist/store.d.mts +569 -18
- package/dist/store.d.ts +569 -18
- package/dist/store.js +4 -4
- package/dist/store.mjs +4 -4
- package/dist/types.d.mts +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/{view-type-D8ukwj_2.d.mts → view-type-BGJfDe73.d.mts} +1 -1
- package/dist/{view-type-D8ukwj_2.d.ts → view-type-BGJfDe73.d.ts} +1 -1
- package/package.json +1 -1
- package/dist/store-DvWeB4jm.d.mts +0 -294
- package/dist/store-DvWeB4jm.d.ts +0 -294
package/dist/hooks.mjs
CHANGED
|
@@ -2232,9 +2232,9 @@ var sessionStorageUtils = () => {
|
|
|
2232
2232
|
// src/configs/axios-client.ts
|
|
2233
2233
|
var axiosClient = {
|
|
2234
2234
|
init(config) {
|
|
2235
|
-
const localStorage2 = config
|
|
2236
|
-
const sessionStorage2 = config
|
|
2237
|
-
const db = config
|
|
2235
|
+
const localStorage2 = config.localStorageUtils ?? localStorageUtils();
|
|
2236
|
+
const sessionStorage2 = config.sessionStorageUtils ?? sessionStorageUtils();
|
|
2237
|
+
const db = config.db;
|
|
2238
2238
|
let isRefreshing = false;
|
|
2239
2239
|
let failedQueue = [];
|
|
2240
2240
|
const processQueue = (error, token = null) => {
|
|
@@ -2253,19 +2253,16 @@ var axiosClient = {
|
|
|
2253
2253
|
timeout: 5e4,
|
|
2254
2254
|
paramsSerializer: (params) => new URLSearchParams(params).toString()
|
|
2255
2255
|
});
|
|
2256
|
-
instance.interceptors.request.use(
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
Promise.reject(error);
|
|
2267
|
-
}
|
|
2268
|
-
);
|
|
2256
|
+
instance.interceptors.request.use(async (config2) => {
|
|
2257
|
+
const { useRefreshToken, useActionToken, actionToken } = config2;
|
|
2258
|
+
if (useActionToken && actionToken) {
|
|
2259
|
+
config2.headers["Action-Token"] = actionToken;
|
|
2260
|
+
}
|
|
2261
|
+
const getToken = useRefreshToken ? localStorage2.getRefreshToken : localStorage2.getAccessToken;
|
|
2262
|
+
const token = await getToken?.();
|
|
2263
|
+
if (token) config2.headers["Authorization"] = `Bearer ${token}`;
|
|
2264
|
+
return config2;
|
|
2265
|
+
}, Promise.reject);
|
|
2269
2266
|
instance.interceptors.response.use(
|
|
2270
2267
|
(response) => {
|
|
2271
2268
|
return handleResponse(response);
|
|
@@ -3020,69 +3017,84 @@ var envStore = configureStore({
|
|
|
3020
3017
|
});
|
|
3021
3018
|
|
|
3022
3019
|
// src/environment/EnvStore.ts
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
|
|
3030
|
-
|
|
3020
|
+
var EnvStore = class {
|
|
3021
|
+
envStore;
|
|
3022
|
+
baseUrl;
|
|
3023
|
+
requests;
|
|
3024
|
+
context;
|
|
3025
|
+
defaultCompany;
|
|
3026
|
+
config;
|
|
3027
|
+
companies;
|
|
3028
|
+
user;
|
|
3029
|
+
db;
|
|
3030
|
+
localStorageUtils;
|
|
3031
|
+
sessionStorageUtils;
|
|
3032
|
+
refreshTokenEndpoint;
|
|
3033
|
+
constructor(envStore2, localStorageUtils2, sessionStorageUtils2) {
|
|
3034
|
+
this.envStore = envStore2;
|
|
3035
|
+
this.localStorageUtils = localStorageUtils2;
|
|
3036
|
+
this.sessionStorageUtils = sessionStorageUtils2;
|
|
3037
|
+
this.setup();
|
|
3038
|
+
}
|
|
3039
|
+
setup() {
|
|
3040
|
+
const env2 = this.envStore.getState().env;
|
|
3041
|
+
this.baseUrl = env2?.baseUrl;
|
|
3042
|
+
this.requests = env2?.requests;
|
|
3043
|
+
this.context = env2?.context;
|
|
3044
|
+
this.defaultCompany = env2?.defaultCompany;
|
|
3045
|
+
this.config = env2?.config;
|
|
3046
|
+
this.companies = env2?.companies || [];
|
|
3047
|
+
this.user = env2?.user;
|
|
3048
|
+
this.db = env2?.db;
|
|
3049
|
+
this.refreshTokenEndpoint = env2?.refreshTokenEndpoint;
|
|
3050
|
+
}
|
|
3051
|
+
setupEnv(envConfig) {
|
|
3052
|
+
const dispatch = this.envStore.dispatch;
|
|
3053
|
+
const env2 = {
|
|
3031
3054
|
...envConfig,
|
|
3032
|
-
localStorageUtils:
|
|
3033
|
-
sessionStorageUtils:
|
|
3034
|
-
}
|
|
3035
|
-
|
|
3036
|
-
|
|
3037
|
-
|
|
3038
|
-
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
);
|
|
3043
|
-
|
|
3044
|
-
|
|
3045
|
-
|
|
3046
|
-
|
|
3047
|
-
|
|
3048
|
-
}
|
|
3049
|
-
|
|
3050
|
-
|
|
3051
|
-
|
|
3052
|
-
|
|
3053
|
-
|
|
3054
|
-
|
|
3055
|
-
|
|
3056
|
-
|
|
3057
|
-
|
|
3058
|
-
|
|
3059
|
-
|
|
3060
|
-
|
|
3061
|
-
|
|
3062
|
-
|
|
3063
|
-
|
|
3064
|
-
|
|
3065
|
-
|
|
3066
|
-
|
|
3067
|
-
|
|
3068
|
-
}
|
|
3069
|
-
|
|
3070
|
-
getEnvData,
|
|
3071
|
-
setupEnv,
|
|
3072
|
-
setLangValue,
|
|
3073
|
-
setUidValue,
|
|
3074
|
-
setAllowCompaniesValue,
|
|
3075
|
-
setCompaniesValue,
|
|
3076
|
-
setDefaultCompanyValue,
|
|
3077
|
-
setUserInfoValue
|
|
3078
|
-
};
|
|
3079
|
-
}
|
|
3055
|
+
localStorageUtils: this.localStorageUtils,
|
|
3056
|
+
sessionStorageUtils: this.sessionStorageUtils
|
|
3057
|
+
};
|
|
3058
|
+
const requests = axiosClient.init(env2);
|
|
3059
|
+
dispatch(setEnv({ ...env2, requests }));
|
|
3060
|
+
this.setup();
|
|
3061
|
+
}
|
|
3062
|
+
setUid(uid) {
|
|
3063
|
+
const dispatch = this.envStore.dispatch;
|
|
3064
|
+
dispatch(setUid(uid));
|
|
3065
|
+
this.setup();
|
|
3066
|
+
}
|
|
3067
|
+
setLang(lang) {
|
|
3068
|
+
const dispatch = this.envStore.dispatch;
|
|
3069
|
+
dispatch(setLang(lang));
|
|
3070
|
+
this.setup();
|
|
3071
|
+
}
|
|
3072
|
+
setAllowCompanies(allowCompanies) {
|
|
3073
|
+
const dispatch = this.envStore.dispatch;
|
|
3074
|
+
dispatch(setAllowCompanies(allowCompanies));
|
|
3075
|
+
this.setup();
|
|
3076
|
+
}
|
|
3077
|
+
setCompanies(companies) {
|
|
3078
|
+
const dispatch = this.envStore.dispatch;
|
|
3079
|
+
dispatch(setCompanies(companies));
|
|
3080
|
+
this.setup();
|
|
3081
|
+
}
|
|
3082
|
+
setDefaultCompany(company) {
|
|
3083
|
+
const dispatch = this.envStore.dispatch;
|
|
3084
|
+
dispatch(setDefaultCompany(company));
|
|
3085
|
+
this.setup();
|
|
3086
|
+
}
|
|
3087
|
+
setUserInfo(userInfo) {
|
|
3088
|
+
const dispatch = this.envStore.dispatch;
|
|
3089
|
+
dispatch(setUser(userInfo));
|
|
3090
|
+
this.setup();
|
|
3091
|
+
}
|
|
3092
|
+
};
|
|
3080
3093
|
var env = null;
|
|
3081
3094
|
function getEnv() {
|
|
3082
|
-
if (!env)
|
|
3083
|
-
env =
|
|
3084
|
-
|
|
3085
|
-
return env?.getEnvData();
|
|
3095
|
+
if (!env)
|
|
3096
|
+
env = new EnvStore(envStore, localStorageUtils(), sessionStorageUtils());
|
|
3097
|
+
return env;
|
|
3086
3098
|
}
|
|
3087
3099
|
|
|
3088
3100
|
// src/services/action-service/index.ts
|
|
@@ -3347,6 +3359,20 @@ var AuthService = {
|
|
|
3347
3359
|
}
|
|
3348
3360
|
});
|
|
3349
3361
|
},
|
|
3362
|
+
async isValidActionToken(actionToken, path) {
|
|
3363
|
+
const env2 = getEnv();
|
|
3364
|
+
return env2?.requests?.post(
|
|
3365
|
+
path,
|
|
3366
|
+
{},
|
|
3367
|
+
{
|
|
3368
|
+
headers: {
|
|
3369
|
+
"Content-Type": "application/json"
|
|
3370
|
+
},
|
|
3371
|
+
useActionToken: true,
|
|
3372
|
+
actionToken
|
|
3373
|
+
}
|
|
3374
|
+
);
|
|
3375
|
+
},
|
|
3350
3376
|
async loginSocial({
|
|
3351
3377
|
db,
|
|
3352
3378
|
state,
|
|
@@ -4111,7 +4137,7 @@ var model_service_default = ModelService;
|
|
|
4111
4137
|
var UserService = {
|
|
4112
4138
|
async getProfile(path) {
|
|
4113
4139
|
const env2 = getEnv();
|
|
4114
|
-
return env2
|
|
4140
|
+
return env2?.requests?.get(path ?? "/userinfo" /* PROFILE_PATH */, {
|
|
4115
4141
|
headers: {
|
|
4116
4142
|
"Content-Type": "application/x-www-form-urlencoded"
|
|
4117
4143
|
}
|
|
@@ -4430,8 +4456,7 @@ var ViewService = {
|
|
|
4430
4456
|
},
|
|
4431
4457
|
async getVersion() {
|
|
4432
4458
|
const env2 = getEnv();
|
|
4433
|
-
|
|
4434
|
-
return env2?.requests?.get("", {
|
|
4459
|
+
return env2?.requests.get("", {
|
|
4435
4460
|
headers: {
|
|
4436
4461
|
"Content-Type": "application/json"
|
|
4437
4462
|
}
|
|
@@ -4748,19 +4773,33 @@ var useGetAccessByCode = () => {
|
|
|
4748
4773
|
};
|
|
4749
4774
|
var use_get_access_by_code_default = useGetAccessByCode;
|
|
4750
4775
|
|
|
4751
|
-
// src/hooks/
|
|
4776
|
+
// src/hooks/auth/use-validate-action-token.ts
|
|
4752
4777
|
import { useMutation as useMutation12 } from "@tanstack/react-query";
|
|
4753
|
-
var
|
|
4778
|
+
var useValidateActionToken = () => {
|
|
4754
4779
|
return useMutation12({
|
|
4780
|
+
mutationFn: ({
|
|
4781
|
+
actionToken,
|
|
4782
|
+
path
|
|
4783
|
+
}) => {
|
|
4784
|
+
return auth_service_default.isValidActionToken(actionToken, path);
|
|
4785
|
+
}
|
|
4786
|
+
});
|
|
4787
|
+
};
|
|
4788
|
+
var use_validate_action_token_default = useValidateActionToken;
|
|
4789
|
+
|
|
4790
|
+
// src/hooks/company/use-get-company-info.ts
|
|
4791
|
+
import { useMutation as useMutation13 } from "@tanstack/react-query";
|
|
4792
|
+
var useGetCompanyInfo = () => {
|
|
4793
|
+
return useMutation13({
|
|
4755
4794
|
mutationFn: (id) => company_service_default.getInfoCompany(id)
|
|
4756
4795
|
});
|
|
4757
4796
|
};
|
|
4758
4797
|
var use_get_company_info_default = useGetCompanyInfo;
|
|
4759
4798
|
|
|
4760
4799
|
// src/hooks/company/use-get-current-company.ts
|
|
4761
|
-
import { useMutation as
|
|
4800
|
+
import { useMutation as useMutation14 } from "@tanstack/react-query";
|
|
4762
4801
|
var useGetCurrentCompany = () => {
|
|
4763
|
-
return
|
|
4802
|
+
return useMutation14({
|
|
4764
4803
|
mutationFn: () => company_service_default.getCurrentCompany()
|
|
4765
4804
|
});
|
|
4766
4805
|
};
|
|
@@ -4787,9 +4826,9 @@ var useGetListCompany = (companyIDs = []) => {
|
|
|
4787
4826
|
var use_get_list_company_default = useGetListCompany;
|
|
4788
4827
|
|
|
4789
4828
|
// src/hooks/excel/use-export-excel.ts
|
|
4790
|
-
import { useMutation as
|
|
4829
|
+
import { useMutation as useMutation15 } from "@tanstack/react-query";
|
|
4791
4830
|
var useExportExcel = () => {
|
|
4792
|
-
return
|
|
4831
|
+
return useMutation15({
|
|
4793
4832
|
mutationFn: ({
|
|
4794
4833
|
model,
|
|
4795
4834
|
domain,
|
|
@@ -4814,9 +4853,9 @@ var useExportExcel = () => {
|
|
|
4814
4853
|
var use_export_excel_default = useExportExcel;
|
|
4815
4854
|
|
|
4816
4855
|
// src/hooks/excel/use-get-field-export.ts
|
|
4817
|
-
import { useMutation as
|
|
4856
|
+
import { useMutation as useMutation16 } from "@tanstack/react-query";
|
|
4818
4857
|
var useGetFieldExport = () => {
|
|
4819
|
-
return
|
|
4858
|
+
return useMutation16({
|
|
4820
4859
|
mutationFn: ({
|
|
4821
4860
|
ids,
|
|
4822
4861
|
model,
|
|
@@ -4863,9 +4902,9 @@ var useGetFileExcel = ({ model }) => {
|
|
|
4863
4902
|
var use_get_file_excel_default = useGetFileExcel;
|
|
4864
4903
|
|
|
4865
4904
|
// src/hooks/excel/use-parse-preview.ts
|
|
4866
|
-
import { useMutation as
|
|
4905
|
+
import { useMutation as useMutation17 } from "@tanstack/react-query";
|
|
4867
4906
|
var useParsePreview = () => {
|
|
4868
|
-
return
|
|
4907
|
+
return useMutation17({
|
|
4869
4908
|
mutationFn: ({
|
|
4870
4909
|
id,
|
|
4871
4910
|
selectedSheet,
|
|
@@ -4882,9 +4921,9 @@ var useParsePreview = () => {
|
|
|
4882
4921
|
var use_parse_preview_default = useParsePreview;
|
|
4883
4922
|
|
|
4884
4923
|
// src/hooks/excel/use-upload-file.ts
|
|
4885
|
-
import { useMutation as
|
|
4924
|
+
import { useMutation as useMutation18 } from "@tanstack/react-query";
|
|
4886
4925
|
var useUploadFile = () => {
|
|
4887
|
-
return
|
|
4926
|
+
return useMutation18({
|
|
4888
4927
|
mutationFn: ({ formData }) => excel_service_default.uploadFile({
|
|
4889
4928
|
formData
|
|
4890
4929
|
})
|
|
@@ -4893,9 +4932,9 @@ var useUploadFile = () => {
|
|
|
4893
4932
|
var use_upload_file_default = useUploadFile;
|
|
4894
4933
|
|
|
4895
4934
|
// src/hooks/excel/use-upload-id-file.ts
|
|
4896
|
-
import { useMutation as
|
|
4935
|
+
import { useMutation as useMutation19 } from "@tanstack/react-query";
|
|
4897
4936
|
var useUploadIdFile = () => {
|
|
4898
|
-
return
|
|
4937
|
+
return useMutation19({
|
|
4899
4938
|
mutationFn: ({ formData }) => excel_service_default.uploadIdFile({
|
|
4900
4939
|
formData
|
|
4901
4940
|
})
|
|
@@ -4904,9 +4943,9 @@ var useUploadIdFile = () => {
|
|
|
4904
4943
|
var use_upload_id_file_default = useUploadIdFile;
|
|
4905
4944
|
|
|
4906
4945
|
// src/hooks/excel/uss-execute-import.ts
|
|
4907
|
-
import { useMutation as
|
|
4946
|
+
import { useMutation as useMutation20 } from "@tanstack/react-query";
|
|
4908
4947
|
var useExecuteImport = () => {
|
|
4909
|
-
return
|
|
4948
|
+
return useMutation20({
|
|
4910
4949
|
mutationFn: ({
|
|
4911
4950
|
fields,
|
|
4912
4951
|
columns,
|
|
@@ -4927,9 +4966,9 @@ var useExecuteImport = () => {
|
|
|
4927
4966
|
var uss_execute_import_default = useExecuteImport;
|
|
4928
4967
|
|
|
4929
4968
|
// src/hooks/form/use-change-status.ts
|
|
4930
|
-
import { useMutation as
|
|
4969
|
+
import { useMutation as useMutation21 } from "@tanstack/react-query";
|
|
4931
4970
|
var useChangeStatus = () => {
|
|
4932
|
-
return
|
|
4971
|
+
return useMutation21({
|
|
4933
4972
|
mutationFn: ({ data }) => {
|
|
4934
4973
|
return form_service_default.changeStatus({
|
|
4935
4974
|
data
|
|
@@ -4940,9 +4979,9 @@ var useChangeStatus = () => {
|
|
|
4940
4979
|
var use_change_status_default = useChangeStatus;
|
|
4941
4980
|
|
|
4942
4981
|
// src/hooks/form/use-delete-comment.ts
|
|
4943
|
-
import { useMutation as
|
|
4982
|
+
import { useMutation as useMutation22 } from "@tanstack/react-query";
|
|
4944
4983
|
var useDeleteComment = () => {
|
|
4945
|
-
return
|
|
4984
|
+
return useMutation22({
|
|
4946
4985
|
mutationFn: ({ data }) => form_service_default.deleteComment({
|
|
4947
4986
|
data
|
|
4948
4987
|
})
|
|
@@ -5007,9 +5046,9 @@ var useGetImage = ({
|
|
|
5007
5046
|
var use_get_image_default = useGetImage;
|
|
5008
5047
|
|
|
5009
5048
|
// src/hooks/form/use-send-comment.ts
|
|
5010
|
-
import { useMutation as
|
|
5049
|
+
import { useMutation as useMutation23 } from "@tanstack/react-query";
|
|
5011
5050
|
var useSendComment = () => {
|
|
5012
|
-
return
|
|
5051
|
+
return useMutation23({
|
|
5013
5052
|
mutationFn: ({ data }) => form_service_default.sentComment({
|
|
5014
5053
|
data
|
|
5015
5054
|
})
|
|
@@ -5018,9 +5057,9 @@ var useSendComment = () => {
|
|
|
5018
5057
|
var use_send_comment_default = useSendComment;
|
|
5019
5058
|
|
|
5020
5059
|
// src/hooks/form/use-upload-image.ts
|
|
5021
|
-
import { useMutation as
|
|
5060
|
+
import { useMutation as useMutation24 } from "@tanstack/react-query";
|
|
5022
5061
|
var useUploadImage = () => {
|
|
5023
|
-
return
|
|
5062
|
+
return useMutation24({
|
|
5024
5063
|
mutationFn: ({ data }) => form_service_default.uploadImage({
|
|
5025
5064
|
data
|
|
5026
5065
|
})
|
|
@@ -5029,9 +5068,9 @@ var useUploadImage = () => {
|
|
|
5029
5068
|
var use_upload_image_default = useUploadImage;
|
|
5030
5069
|
|
|
5031
5070
|
// src/hooks/model/use-delete.ts
|
|
5032
|
-
import { useMutation as
|
|
5071
|
+
import { useMutation as useMutation25 } from "@tanstack/react-query";
|
|
5033
5072
|
var useDelete = () => {
|
|
5034
|
-
return
|
|
5073
|
+
return useMutation25({
|
|
5035
5074
|
mutationFn: ({ ids, model }) => model_service_default.delete({ ids, model })
|
|
5036
5075
|
});
|
|
5037
5076
|
};
|
|
@@ -5085,9 +5124,9 @@ var useGetCurrency = () => {
|
|
|
5085
5124
|
var use_get_currency_default = useGetCurrency;
|
|
5086
5125
|
|
|
5087
5126
|
// src/hooks/model/use-get-detail.ts
|
|
5088
|
-
import { useMutation as
|
|
5127
|
+
import { useMutation as useMutation26 } from "@tanstack/react-query";
|
|
5089
5128
|
var useGetDetail = () => {
|
|
5090
|
-
return
|
|
5129
|
+
return useMutation26({
|
|
5091
5130
|
mutationFn: ({
|
|
5092
5131
|
model,
|
|
5093
5132
|
ids,
|
|
@@ -5280,9 +5319,9 @@ var useOdooDataTransform = () => {
|
|
|
5280
5319
|
var use_odoo_data_transform_default = useOdooDataTransform;
|
|
5281
5320
|
|
|
5282
5321
|
// src/hooks/model/use-onchange-form.ts
|
|
5283
|
-
import { useMutation as
|
|
5322
|
+
import { useMutation as useMutation27 } from "@tanstack/react-query";
|
|
5284
5323
|
var useOnChangeForm = () => {
|
|
5285
|
-
return
|
|
5324
|
+
return useMutation27({
|
|
5286
5325
|
mutationFn: ({
|
|
5287
5326
|
ids,
|
|
5288
5327
|
model,
|
|
@@ -5303,9 +5342,9 @@ var useOnChangeForm = () => {
|
|
|
5303
5342
|
var use_onchange_form_default = useOnChangeForm;
|
|
5304
5343
|
|
|
5305
5344
|
// src/hooks/model/use-save.ts
|
|
5306
|
-
import { useMutation as
|
|
5345
|
+
import { useMutation as useMutation28 } from "@tanstack/react-query";
|
|
5307
5346
|
var useSave = () => {
|
|
5308
|
-
return
|
|
5347
|
+
return useMutation28({
|
|
5309
5348
|
mutationFn: ({
|
|
5310
5349
|
ids,
|
|
5311
5350
|
model,
|
|
@@ -5319,18 +5358,18 @@ var useSave = () => {
|
|
|
5319
5358
|
var use_save_default = useSave;
|
|
5320
5359
|
|
|
5321
5360
|
// src/hooks/user/use-get-profile.ts
|
|
5322
|
-
import { useMutation as
|
|
5361
|
+
import { useMutation as useMutation29 } from "@tanstack/react-query";
|
|
5323
5362
|
var useGetProfile = (path) => {
|
|
5324
|
-
return
|
|
5363
|
+
return useMutation29({
|
|
5325
5364
|
mutationFn: () => user_service_default.getProfile(path)
|
|
5326
5365
|
});
|
|
5327
5366
|
};
|
|
5328
5367
|
var use_get_profile_default = useGetProfile;
|
|
5329
5368
|
|
|
5330
5369
|
// src/hooks/user/use-get-user.ts
|
|
5331
|
-
import { useMutation as
|
|
5370
|
+
import { useMutation as useMutation30 } from "@tanstack/react-query";
|
|
5332
5371
|
var useGetUser = () => {
|
|
5333
|
-
return
|
|
5372
|
+
return useMutation30({
|
|
5334
5373
|
mutationFn: ({ id, context }) => user_service_default.getUser({
|
|
5335
5374
|
id,
|
|
5336
5375
|
context
|
|
@@ -5340,9 +5379,9 @@ var useGetUser = () => {
|
|
|
5340
5379
|
var use_get_user_default = useGetUser;
|
|
5341
5380
|
|
|
5342
5381
|
// src/hooks/user/use-switch-locale.ts
|
|
5343
|
-
import { useMutation as
|
|
5382
|
+
import { useMutation as useMutation31 } from "@tanstack/react-query";
|
|
5344
5383
|
var useSwitchLocale = () => {
|
|
5345
|
-
return
|
|
5384
|
+
return useMutation31({
|
|
5346
5385
|
mutationFn: ({ data }) => {
|
|
5347
5386
|
return user_service_default.switchUserLocale({
|
|
5348
5387
|
id: data.id,
|
|
@@ -5354,9 +5393,9 @@ var useSwitchLocale = () => {
|
|
|
5354
5393
|
var use_switch_locale_default = useSwitchLocale;
|
|
5355
5394
|
|
|
5356
5395
|
// src/hooks/view/use-button.ts
|
|
5357
|
-
import { useMutation as
|
|
5396
|
+
import { useMutation as useMutation32 } from "@tanstack/react-query";
|
|
5358
5397
|
var useButton = () => {
|
|
5359
|
-
return
|
|
5398
|
+
return useMutation32({
|
|
5360
5399
|
mutationFn: ({
|
|
5361
5400
|
model,
|
|
5362
5401
|
ids,
|
|
@@ -5376,9 +5415,9 @@ var useButton = () => {
|
|
|
5376
5415
|
var use_button_default = useButton;
|
|
5377
5416
|
|
|
5378
5417
|
// src/hooks/view/use-duplicate-record.ts
|
|
5379
|
-
import { useMutation as
|
|
5418
|
+
import { useMutation as useMutation33 } from "@tanstack/react-query";
|
|
5380
5419
|
var useDuplicateRecord = () => {
|
|
5381
|
-
return
|
|
5420
|
+
return useMutation33({
|
|
5382
5421
|
mutationFn: ({
|
|
5383
5422
|
id,
|
|
5384
5423
|
model,
|
|
@@ -5504,9 +5543,9 @@ var useGetMenu = (context, enabled) => {
|
|
|
5504
5543
|
var use_get_menu_default = useGetMenu;
|
|
5505
5544
|
|
|
5506
5545
|
// src/hooks/view/use-get-print-report.ts
|
|
5507
|
-
import { useMutation as
|
|
5546
|
+
import { useMutation as useMutation34 } from "@tanstack/react-query";
|
|
5508
5547
|
var useGetPrintReport = () => {
|
|
5509
|
-
return
|
|
5548
|
+
return useMutation34({
|
|
5510
5549
|
mutationFn: ({ id }) => action_service_default.getPrintReportName({
|
|
5511
5550
|
id
|
|
5512
5551
|
})
|
|
@@ -5570,9 +5609,9 @@ var useGetView = (viewParams, actData) => {
|
|
|
5570
5609
|
var use_get_view_default = useGetView;
|
|
5571
5610
|
|
|
5572
5611
|
// src/hooks/view/use-load-action.ts
|
|
5573
|
-
import { useMutation as
|
|
5612
|
+
import { useMutation as useMutation35 } from "@tanstack/react-query";
|
|
5574
5613
|
var useLoadAction = () => {
|
|
5575
|
-
return
|
|
5614
|
+
return useMutation35({
|
|
5576
5615
|
mutationFn: ({
|
|
5577
5616
|
idAction,
|
|
5578
5617
|
context
|
|
@@ -5598,9 +5637,9 @@ var useLoadMessage = () => {
|
|
|
5598
5637
|
var use_load_message_default = useLoadMessage;
|
|
5599
5638
|
|
|
5600
5639
|
// src/hooks/view/use-print.ts
|
|
5601
|
-
import { useMutation as
|
|
5640
|
+
import { useMutation as useMutation36 } from "@tanstack/react-query";
|
|
5602
5641
|
var usePrint = () => {
|
|
5603
|
-
return
|
|
5642
|
+
return useMutation36({
|
|
5604
5643
|
mutationFn: ({ id, report, db }) => action_service_default.print({
|
|
5605
5644
|
id,
|
|
5606
5645
|
report,
|
|
@@ -5611,9 +5650,9 @@ var usePrint = () => {
|
|
|
5611
5650
|
var use_print_default = usePrint;
|
|
5612
5651
|
|
|
5613
5652
|
// src/hooks/view/use-remove-row.ts
|
|
5614
|
-
import { useMutation as
|
|
5653
|
+
import { useMutation as useMutation37 } from "@tanstack/react-query";
|
|
5615
5654
|
var useRemoveRow = () => {
|
|
5616
|
-
return
|
|
5655
|
+
return useMutation37({
|
|
5617
5656
|
mutationFn: ({
|
|
5618
5657
|
model,
|
|
5619
5658
|
ids,
|
|
@@ -5645,9 +5684,9 @@ var useGetResequence = (model, resIds, context, offset) => {
|
|
|
5645
5684
|
var use_resequence_default = useGetResequence;
|
|
5646
5685
|
|
|
5647
5686
|
// src/hooks/view/use-run-action.ts
|
|
5648
|
-
import { useMutation as
|
|
5687
|
+
import { useMutation as useMutation38 } from "@tanstack/react-query";
|
|
5649
5688
|
var useRunAction = () => {
|
|
5650
|
-
return
|
|
5689
|
+
return useMutation38({
|
|
5651
5690
|
mutationFn: ({
|
|
5652
5691
|
idAction,
|
|
5653
5692
|
context
|
|
@@ -5660,9 +5699,9 @@ var useRunAction = () => {
|
|
|
5660
5699
|
var use_run_action_default = useRunAction;
|
|
5661
5700
|
|
|
5662
5701
|
// src/hooks/view/use-signin-sso.ts
|
|
5663
|
-
import { useMutation as
|
|
5702
|
+
import { useMutation as useMutation39 } from "@tanstack/react-query";
|
|
5664
5703
|
var useSignInSSO = () => {
|
|
5665
|
-
return
|
|
5704
|
+
return useMutation39({
|
|
5666
5705
|
mutationFn: ({
|
|
5667
5706
|
redirect_uri,
|
|
5668
5707
|
state,
|
|
@@ -5683,9 +5722,9 @@ var useSignInSSO = () => {
|
|
|
5683
5722
|
var use_signin_sso_default = useSignInSSO;
|
|
5684
5723
|
|
|
5685
5724
|
// src/hooks/view/use-verify-2FA.ts
|
|
5686
|
-
import { useMutation as
|
|
5725
|
+
import { useMutation as useMutation40 } from "@tanstack/react-query";
|
|
5687
5726
|
var useVerify2FA = () => {
|
|
5688
|
-
return
|
|
5727
|
+
return useMutation40({
|
|
5689
5728
|
mutationFn: ({
|
|
5690
5729
|
method,
|
|
5691
5730
|
with_context,
|
|
@@ -5706,9 +5745,9 @@ var useVerify2FA = () => {
|
|
|
5706
5745
|
var use_verify_2FA_default = useVerify2FA;
|
|
5707
5746
|
|
|
5708
5747
|
// src/hooks/view/uset-get-2FA-method.ts
|
|
5709
|
-
import { useMutation as
|
|
5748
|
+
import { useMutation as useMutation41 } from "@tanstack/react-query";
|
|
5710
5749
|
var useGet2FAMethods = () => {
|
|
5711
|
-
return
|
|
5750
|
+
return useMutation41({
|
|
5712
5751
|
mutationFn: ({
|
|
5713
5752
|
method,
|
|
5714
5753
|
with_context
|
|
@@ -5723,9 +5762,9 @@ var useGet2FAMethods = () => {
|
|
|
5723
5762
|
var uset_get_2FA_method_default = useGet2FAMethods;
|
|
5724
5763
|
|
|
5725
5764
|
// src/hooks/view/use-get-fields-view-security.ts
|
|
5726
|
-
import { useMutation as
|
|
5765
|
+
import { useMutation as useMutation42 } from "@tanstack/react-query";
|
|
5727
5766
|
var useGetFieldsViewSecurity = () => {
|
|
5728
|
-
return
|
|
5767
|
+
return useMutation42({
|
|
5729
5768
|
mutationFn: ({
|
|
5730
5769
|
method,
|
|
5731
5770
|
token,
|
|
@@ -5742,9 +5781,9 @@ var useGetFieldsViewSecurity = () => {
|
|
|
5742
5781
|
var use_get_fields_view_security_default = useGetFieldsViewSecurity;
|
|
5743
5782
|
|
|
5744
5783
|
// src/hooks/view/use-grant-access.ts
|
|
5745
|
-
import { useMutation as
|
|
5784
|
+
import { useMutation as useMutation43 } from "@tanstack/react-query";
|
|
5746
5785
|
var useGrantAccess = () => {
|
|
5747
|
-
return
|
|
5786
|
+
return useMutation43({
|
|
5748
5787
|
mutationFn: ({
|
|
5749
5788
|
redirect_uri,
|
|
5750
5789
|
state,
|
|
@@ -5763,9 +5802,9 @@ var useGrantAccess = () => {
|
|
|
5763
5802
|
var use_grant_access_default = useGrantAccess;
|
|
5764
5803
|
|
|
5765
5804
|
// src/hooks/view/use-remove-totp-setup.ts
|
|
5766
|
-
import { useMutation as
|
|
5805
|
+
import { useMutation as useMutation44 } from "@tanstack/react-query";
|
|
5767
5806
|
var useRemoveTotpSetup = () => {
|
|
5768
|
-
return
|
|
5807
|
+
return useMutation44({
|
|
5769
5808
|
mutationFn: ({ method, token }) => {
|
|
5770
5809
|
return view_service_default.removeTotpSetUp({
|
|
5771
5810
|
method,
|
|
@@ -5777,9 +5816,9 @@ var useRemoveTotpSetup = () => {
|
|
|
5777
5816
|
var use_remove_totp_setup_default = useRemoveTotpSetup;
|
|
5778
5817
|
|
|
5779
5818
|
// src/hooks/view/use-request-setup-totp.ts
|
|
5780
|
-
import { useMutation as
|
|
5819
|
+
import { useMutation as useMutation45 } from "@tanstack/react-query";
|
|
5781
5820
|
var useRequestSetupTotp = () => {
|
|
5782
|
-
return
|
|
5821
|
+
return useMutation45({
|
|
5783
5822
|
mutationFn: ({ method, token }) => {
|
|
5784
5823
|
return view_service_default.requestSetupTotp({
|
|
5785
5824
|
method,
|
|
@@ -5791,9 +5830,9 @@ var useRequestSetupTotp = () => {
|
|
|
5791
5830
|
var use_request_setup_totp_default = useRequestSetupTotp;
|
|
5792
5831
|
|
|
5793
5832
|
// src/hooks/view/use-settings-web-read-2fa.ts
|
|
5794
|
-
import { useMutation as
|
|
5833
|
+
import { useMutation as useMutation46 } from "@tanstack/react-query";
|
|
5795
5834
|
var useSettingsWebRead2fa = () => {
|
|
5796
|
-
return
|
|
5835
|
+
return useMutation46({
|
|
5797
5836
|
mutationFn: ({
|
|
5798
5837
|
method,
|
|
5799
5838
|
token,
|
|
@@ -5812,9 +5851,9 @@ var useSettingsWebRead2fa = () => {
|
|
|
5812
5851
|
var use_settings_web_read_2fa_default = useSettingsWebRead2fa;
|
|
5813
5852
|
|
|
5814
5853
|
// src/hooks/view/use-verify-totp.ts
|
|
5815
|
-
import { useMutation as
|
|
5854
|
+
import { useMutation as useMutation47 } from "@tanstack/react-query";
|
|
5816
5855
|
var useVerifyTotp = () => {
|
|
5817
|
-
return
|
|
5856
|
+
return useMutation47({
|
|
5818
5857
|
mutationFn: ({
|
|
5819
5858
|
method,
|
|
5820
5859
|
action_token,
|
|
@@ -5896,6 +5935,7 @@ export {
|
|
|
5896
5935
|
use_upload_file_default as useUploadFile,
|
|
5897
5936
|
use_upload_id_file_default as useUploadIdFile,
|
|
5898
5937
|
use_upload_image_default as useUploadImage,
|
|
5938
|
+
use_validate_action_token_default as useValidateActionToken,
|
|
5899
5939
|
use_verify_2FA_default as useVerify2FA,
|
|
5900
5940
|
use_verify_totp_default as useVerifyTotp
|
|
5901
5941
|
};
|
package/dist/provider.d.mts
CHANGED
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
1
|
import { ReactNode } from 'react';
|
|
3
2
|
|
|
4
3
|
declare const MainProvider: ({ children }: {
|
|
5
4
|
children: ReactNode;
|
|
6
|
-
}) =>
|
|
5
|
+
}) => JSX.Element;
|
|
7
6
|
|
|
8
7
|
declare const ReactQueryProvider: ({ children }: {
|
|
9
8
|
children: ReactNode;
|
|
10
|
-
}) =>
|
|
9
|
+
}) => JSX.Element;
|
|
11
10
|
|
|
12
11
|
declare const VersionGate: ({ children }: {
|
|
13
12
|
children: ReactNode;
|
|
14
|
-
}) =>
|
|
13
|
+
}) => JSX.Element | null;
|
|
15
14
|
|
|
16
15
|
export { MainProvider, ReactQueryProvider, VersionGate };
|