@fctc/interface-logic 1.7.8 → 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/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?.localStorageUtils ?? localStorageUtils();
2236
- const sessionStorage2 = config?.sessionStorageUtils ?? sessionStorageUtils();
2237
- const db = config?.db;
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
- async (config2) => {
2258
- const useRefreshToken = config2.useRefreshToken;
2259
- const token = useRefreshToken ? await localStorage2.getRefreshToken() : await localStorage2.getAccessToken();
2260
- if (token) {
2261
- config2.headers["Authorization"] = "Bearer " + token;
2262
- }
2263
- return config2;
2264
- },
2265
- (error) => {
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,81 +3017,84 @@ var envStore = configureStore({
3020
3017
  });
3021
3018
 
3022
3019
  // src/environment/EnvStore.ts
3023
- var EnvStore = class _EnvStore {
3024
- static instance = null;
3025
- static localStorageUtils;
3026
- static sessionStorageUtils;
3027
- constructor() {
3028
- }
3029
- static getInstance(localStorageUtils2, sessionStorageUtils2) {
3030
- if (!_EnvStore.instance) {
3031
- console.log("Creating new EnvStore instance");
3032
- _EnvStore.instance = new _EnvStore();
3033
- _EnvStore.localStorageUtils = localStorageUtils2;
3034
- _EnvStore.sessionStorageUtils = sessionStorageUtils2;
3035
- } else {
3036
- console.log("Returning existing EnvStore instance");
3037
- }
3038
- return _EnvStore.instance;
3039
- }
3040
- static getState() {
3041
- const state = envStore.getState().env;
3042
- console.log("Redux env state:", state);
3043
- return {
3044
- baseUrl: state?.baseUrl,
3045
- requests: state?.requests,
3046
- context: state?.context,
3047
- defaultCompany: state?.defaultCompany,
3048
- config: state?.config,
3049
- companies: state?.companies || [],
3050
- user: state?.user,
3051
- db: state?.db,
3052
- refreshTokenEndpoint: state?.refreshTokenEndpoint,
3053
- uid: state?.uid,
3054
- lang: state?.lang,
3055
- allowCompanies: state?.allowCompanies
3056
- };
3057
- }
3058
- static setupEnv(envConfig) {
3059
- const dispatch = envStore.dispatch;
3060
- const env = {
3061
- ..._EnvStore.getState(),
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 = {
3062
3054
  ...envConfig,
3063
- localStorageUtils: _EnvStore.localStorageUtils,
3064
- sessionStorageUtils: _EnvStore.sessionStorageUtils
3055
+ localStorageUtils: this.localStorageUtils,
3056
+ sessionStorageUtils: this.sessionStorageUtils
3065
3057
  };
3066
- console.log("Setting up env with config:", envConfig);
3067
- const requests = axiosClient.init(env);
3068
- console.log("axiosClient.init result:", requests);
3069
- dispatch(setEnv({ ...env, requests }));
3058
+ const requests = axiosClient.init(env2);
3059
+ dispatch(setEnv({ ...env2, requests }));
3060
+ this.setup();
3070
3061
  }
3071
- static setUid(uid) {
3072
- const dispatch = envStore.dispatch;
3062
+ setUid(uid) {
3063
+ const dispatch = this.envStore.dispatch;
3073
3064
  dispatch(setUid(uid));
3065
+ this.setup();
3074
3066
  }
3075
- static setLang(lang) {
3076
- const dispatch = envStore.dispatch;
3067
+ setLang(lang) {
3068
+ const dispatch = this.envStore.dispatch;
3077
3069
  dispatch(setLang(lang));
3070
+ this.setup();
3078
3071
  }
3079
- static setAllowCompanies(allowCompanies) {
3080
- const dispatch = envStore.dispatch;
3072
+ setAllowCompanies(allowCompanies) {
3073
+ const dispatch = this.envStore.dispatch;
3081
3074
  dispatch(setAllowCompanies(allowCompanies));
3075
+ this.setup();
3082
3076
  }
3083
- static setCompanies(companies) {
3084
- const dispatch = envStore.dispatch;
3077
+ setCompanies(companies) {
3078
+ const dispatch = this.envStore.dispatch;
3085
3079
  dispatch(setCompanies(companies));
3080
+ this.setup();
3086
3081
  }
3087
- static setDefaultCompany(company) {
3088
- const dispatch = envStore.dispatch;
3082
+ setDefaultCompany(company) {
3083
+ const dispatch = this.envStore.dispatch;
3089
3084
  dispatch(setDefaultCompany(company));
3085
+ this.setup();
3090
3086
  }
3091
- static setUserInfo(userInfo) {
3092
- const dispatch = envStore.dispatch;
3087
+ setUserInfo(userInfo) {
3088
+ const dispatch = this.envStore.dispatch;
3093
3089
  dispatch(setUser(userInfo));
3090
+ this.setup();
3094
3091
  }
3095
3092
  };
3093
+ var env = null;
3096
3094
  function getEnv() {
3097
- return EnvStore.getState();
3095
+ if (!env)
3096
+ env = new EnvStore(envStore, localStorageUtils(), sessionStorageUtils());
3097
+ return env;
3098
3098
  }
3099
3099
 
3100
3100
  // src/services/action-service/index.ts
@@ -3104,14 +3104,14 @@ var ActionService = {
3104
3104
  idAction,
3105
3105
  context
3106
3106
  }) {
3107
- const env = getEnv();
3107
+ const env2 = getEnv();
3108
3108
  const jsonData = {
3109
3109
  action_id: idAction,
3110
3110
  with_context: {
3111
3111
  ...context
3112
3112
  }
3113
3113
  };
3114
- return env.requests.post(`${"/load_action" /* LOAD_ACTION */}`, jsonData, {
3114
+ return env2.requests.post(`${"/load_action" /* LOAD_ACTION */}`, jsonData, {
3115
3115
  headers: {
3116
3116
  "Content-Type": "application/json"
3117
3117
  }
@@ -3125,14 +3125,14 @@ var ActionService = {
3125
3125
  method
3126
3126
  }) {
3127
3127
  try {
3128
- const env = getEnv();
3128
+ const env2 = getEnv();
3129
3129
  const jsonData = {
3130
3130
  model,
3131
3131
  method,
3132
3132
  ids,
3133
3133
  with_context: context
3134
3134
  };
3135
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3135
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3136
3136
  headers: {
3137
3137
  "Content-Type": "application/json"
3138
3138
  }
@@ -3148,14 +3148,14 @@ var ActionService = {
3148
3148
  ids,
3149
3149
  context
3150
3150
  }) {
3151
- const env = getEnv();
3151
+ const env2 = getEnv();
3152
3152
  const jsonData = {
3153
3153
  model,
3154
3154
  method: "unlink",
3155
3155
  ids,
3156
3156
  with_context: context
3157
3157
  };
3158
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3158
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3159
3159
  headers: {
3160
3160
  "Content-Type": "application/json"
3161
3161
  }
@@ -3167,14 +3167,14 @@ var ActionService = {
3167
3167
  id,
3168
3168
  context
3169
3169
  }) {
3170
- const env = getEnv();
3170
+ const env2 = getEnv();
3171
3171
  const jsonData = {
3172
3172
  model,
3173
3173
  method: "copy",
3174
3174
  ids: id,
3175
3175
  with_context: context
3176
3176
  };
3177
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3177
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3178
3178
  headers: {
3179
3179
  "Content-Type": "application/json"
3180
3180
  }
@@ -3182,7 +3182,7 @@ var ActionService = {
3182
3182
  },
3183
3183
  // Get Print Report
3184
3184
  async getPrintReportName({ id }) {
3185
- const env = getEnv();
3185
+ const env2 = getEnv();
3186
3186
  const jsonData = {
3187
3187
  model: "ir.actions.report",
3188
3188
  method: "web_read",
@@ -3193,7 +3193,7 @@ var ActionService = {
3193
3193
  }
3194
3194
  }
3195
3195
  };
3196
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3196
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3197
3197
  headers: {
3198
3198
  "Content-Type": "application/json"
3199
3199
  }
@@ -3201,7 +3201,7 @@ var ActionService = {
3201
3201
  },
3202
3202
  //Save Print Invoice
3203
3203
  async print({ id, report, db }) {
3204
- const env = getEnv();
3204
+ const env2 = getEnv();
3205
3205
  const jsonData = {
3206
3206
  report,
3207
3207
  id,
@@ -3211,7 +3211,7 @@ var ActionService = {
3211
3211
  };
3212
3212
  const queryString = toQueryString(jsonData);
3213
3213
  const urlWithParams = `${"/report" /* REPORT_PATH */}?${queryString}`;
3214
- return env.requests.get(urlWithParams, {
3214
+ return env2.requests.get(urlWithParams, {
3215
3215
  headers: {
3216
3216
  "Content-Type": "application/json"
3217
3217
  },
@@ -3223,7 +3223,7 @@ var ActionService = {
3223
3223
  idAction,
3224
3224
  context
3225
3225
  }) {
3226
- const env = getEnv();
3226
+ const env2 = getEnv();
3227
3227
  const jsonData = {
3228
3228
  action_id: idAction,
3229
3229
  with_context: {
@@ -3239,7 +3239,7 @@ var ActionService = {
3239
3239
  // active_model: model,
3240
3240
  // },
3241
3241
  };
3242
- return env.requests.post(`${"/run_action" /* RUN_ACTION_PATH */}`, jsonData, {
3242
+ return env2.requests.post(`${"/run_action" /* RUN_ACTION_PATH */}`, jsonData, {
3243
3243
  headers: {
3244
3244
  "Content-Type": "application/json"
3245
3245
  }
@@ -3251,30 +3251,30 @@ var action_service_default = ActionService;
3251
3251
  // src/services/auth-service/index.ts
3252
3252
  var AuthService = {
3253
3253
  async login(body) {
3254
- const env = getEnv();
3254
+ const env2 = getEnv();
3255
3255
  const payload = Object.fromEntries(
3256
3256
  Object.entries({
3257
3257
  username: body.email,
3258
3258
  password: body.password,
3259
- grant_type: env?.config?.grantType || "",
3260
- client_id: env?.config?.clientId || "",
3261
- client_secret: env?.config?.clientSecret || ""
3259
+ grant_type: env2?.config?.grantType || "",
3260
+ client_id: env2?.config?.clientId || "",
3261
+ client_secret: env2?.config?.clientSecret || ""
3262
3262
  }).filter(([_, value]) => !!value)
3263
3263
  );
3264
3264
  const encodedData = new URLSearchParams(payload).toString();
3265
- return env?.requests?.post(body.path, encodedData, {
3265
+ return env2?.requests?.post(body.path, encodedData, {
3266
3266
  headers: {
3267
3267
  "Content-Type": "application/x-www-form-urlencoded"
3268
3268
  }
3269
3269
  });
3270
3270
  },
3271
3271
  async forgotPassword(email) {
3272
- const env = getEnv();
3272
+ const env2 = getEnv();
3273
3273
  const bodyData = {
3274
3274
  login: email,
3275
3275
  url: `${window.location.origin}/reset-password`
3276
3276
  };
3277
- return env?.requests?.post("/reset_password" /* RESET_PASSWORD_PATH */, bodyData, {
3277
+ return env2?.requests?.post("/reset_password" /* RESET_PASSWORD_PATH */, bodyData, {
3278
3278
  headers: {
3279
3279
  "Content-Type": "application/json"
3280
3280
  }
@@ -3285,7 +3285,7 @@ var AuthService = {
3285
3285
  with_context,
3286
3286
  method
3287
3287
  }) {
3288
- const env = getEnv();
3288
+ const env2 = getEnv();
3289
3289
  const body = {
3290
3290
  method,
3291
3291
  kwargs: {
@@ -3295,20 +3295,20 @@ var AuthService = {
3295
3295
  },
3296
3296
  with_context
3297
3297
  };
3298
- return env?.requests?.post("/call" /* CALL_PATH */, body, {
3298
+ return env2?.requests?.post("/call" /* CALL_PATH */, body, {
3299
3299
  headers: {
3300
3300
  "Content-Type": "application/json"
3301
3301
  }
3302
3302
  });
3303
3303
  },
3304
3304
  async resetPassword(data, token) {
3305
- const env = getEnv();
3305
+ const env2 = getEnv();
3306
3306
  const bodyData = {
3307
3307
  token,
3308
3308
  password: data.password,
3309
3309
  new_password: data.confirmPassword
3310
3310
  };
3311
- return env?.requests?.post("/change_password" /* CHANGE_PASSWORD_PATH */, bodyData, {
3311
+ return env2?.requests?.post("/change_password" /* CHANGE_PASSWORD_PATH */, bodyData, {
3312
3312
  headers: {
3313
3313
  "Content-Type": "application/json"
3314
3314
  }
@@ -3319,7 +3319,7 @@ var AuthService = {
3319
3319
  password,
3320
3320
  with_context
3321
3321
  }) {
3322
- const env = getEnv();
3322
+ const env2 = getEnv();
3323
3323
  const bodyData = {
3324
3324
  method,
3325
3325
  kwargs: {
@@ -3329,43 +3329,57 @@ var AuthService = {
3329
3329
  },
3330
3330
  with_context
3331
3331
  };
3332
- return env?.requests?.post("/call" /* CALL_PATH */, bodyData, {
3332
+ return env2?.requests?.post("/call" /* CALL_PATH */, bodyData, {
3333
3333
  headers: {
3334
3334
  "Content-Type": "application/json"
3335
3335
  }
3336
3336
  });
3337
3337
  },
3338
3338
  async updatePassword(data, token) {
3339
- const env = getEnv();
3339
+ const env2 = getEnv();
3340
3340
  const bodyData = {
3341
3341
  token,
3342
3342
  old_password: data.oldPassword,
3343
3343
  new_password: data.newPassword
3344
3344
  };
3345
- return env?.requests?.post("/change_password_parent" /* UPDATE_PASSWORD_PATH */, bodyData, {
3345
+ return env2?.requests?.post("/change_password_parent" /* UPDATE_PASSWORD_PATH */, bodyData, {
3346
3346
  headers: {
3347
3347
  "Content-Type": "application/json"
3348
3348
  }
3349
3349
  });
3350
3350
  },
3351
3351
  async isValidToken(token) {
3352
- const env = getEnv();
3352
+ const env2 = getEnv();
3353
3353
  const bodyData = {
3354
3354
  token
3355
3355
  };
3356
- return env?.requests?.post("/check_token" /* TOKEN */, bodyData, {
3356
+ return env2?.requests?.post("/check_token" /* TOKEN */, bodyData, {
3357
3357
  headers: {
3358
3358
  "Content-Type": "application/json"
3359
3359
  }
3360
3360
  });
3361
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
+ },
3362
3376
  async loginSocial({
3363
3377
  db,
3364
3378
  state,
3365
3379
  access_token
3366
3380
  }) {
3367
- const env = getEnv();
3368
- return env?.requests?.post(
3381
+ const env2 = getEnv();
3382
+ return env2?.requests?.post(
3369
3383
  "/token/generate" /* GENTOKEN_SOCIAL */,
3370
3384
  { state, access_token },
3371
3385
  {
@@ -3376,18 +3390,18 @@ var AuthService = {
3376
3390
  );
3377
3391
  },
3378
3392
  async getProviders(db) {
3379
- const env = getEnv();
3380
- return env?.requests?.get("/oauth/providers", { params: { db } });
3393
+ const env2 = getEnv();
3394
+ return env2?.requests?.get("/oauth/providers", { params: { db } });
3381
3395
  },
3382
3396
  async getAccessByCode(code) {
3383
- const env = getEnv();
3397
+ const env2 = getEnv();
3384
3398
  const data = new URLSearchParams();
3385
3399
  data.append("code", code);
3386
3400
  data.append("grant_type", "authorization_code");
3387
- data.append("client_id", env?.config?.clientId || "");
3388
- data.append("redirect_uri", env?.config?.redirectUri || "");
3389
- return env?.requests?.post(
3390
- `${env?.baseUrl?.replace("/mms/", "/id/")}/${"/token" /* TOKEN_BY_CODE */}`,
3401
+ data.append("client_id", env2?.config?.clientId || "");
3402
+ data.append("redirect_uri", env2?.config?.redirectUri || "");
3403
+ return env2?.requests?.post(
3404
+ `${env2?.baseUrl?.replace("/mms/", "/id/")}/${"/token" /* TOKEN_BY_CODE */}`,
3391
3405
  data,
3392
3406
  {
3393
3407
  headers: {
@@ -3397,9 +3411,9 @@ var AuthService = {
3397
3411
  );
3398
3412
  },
3399
3413
  async logout(data) {
3400
- const env = getEnv();
3414
+ const env2 = getEnv();
3401
3415
  console.log(data);
3402
- return env?.requests?.post(
3416
+ return env2?.requests?.post(
3403
3417
  "/logout" /* LOGOUT */,
3404
3418
  {},
3405
3419
  {
@@ -3417,15 +3431,15 @@ var auth_service_default = AuthService;
3417
3431
  // src/services/company-service/index.ts
3418
3432
  var CompanyService = {
3419
3433
  async getCurrentCompany() {
3420
- const env = getEnv();
3421
- return await env.requests.get("/company" /* COMPANY_PATH */, {
3434
+ const env2 = getEnv();
3435
+ return await env2.requests.get("/company" /* COMPANY_PATH */, {
3422
3436
  headers: {
3423
3437
  "Content-Type": "application/json"
3424
3438
  }
3425
3439
  });
3426
3440
  },
3427
3441
  async getInfoCompany(id) {
3428
- const env = getEnv();
3442
+ const env2 = getEnv();
3429
3443
  const jsonData = {
3430
3444
  ids: [id],
3431
3445
  model: "res.company" /* COMPANY */,
@@ -3440,7 +3454,7 @@ var CompanyService = {
3440
3454
  }
3441
3455
  }
3442
3456
  };
3443
- return await env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
3457
+ return await env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
3444
3458
  headers: {
3445
3459
  "Content-Type": "application/json"
3446
3460
  }
@@ -3452,16 +3466,16 @@ var company_service_default = CompanyService;
3452
3466
  // src/services/excel-service/index.ts
3453
3467
  var ExcelService = {
3454
3468
  async uploadFile({ formData }) {
3455
- const env = getEnv();
3456
- return env.requests.post(`${"/upload/file" /* UPLOAD_FILE_PATH */}`, formData, {
3469
+ const env2 = getEnv();
3470
+ return env2.requests.post(`${"/upload/file" /* UPLOAD_FILE_PATH */}`, formData, {
3457
3471
  headers: {
3458
3472
  "Content-Type": "multipart/form-data"
3459
3473
  }
3460
3474
  });
3461
3475
  },
3462
3476
  async uploadIdFile({ formData }) {
3463
- const env = getEnv();
3464
- return env.requests.post(`${"/upload/file" /* UPLOAD_FILE_PATH */}`, formData, {
3477
+ const env2 = getEnv();
3478
+ return env2.requests.post(`${"/upload/file" /* UPLOAD_FILE_PATH */}`, formData, {
3465
3479
  headers: {
3466
3480
  "Content-Type": "multipart/form-data"
3467
3481
  }
@@ -3473,7 +3487,7 @@ var ExcelService = {
3473
3487
  isHeader,
3474
3488
  context
3475
3489
  }) {
3476
- const env = getEnv();
3490
+ const env2 = getEnv();
3477
3491
  const jsonData = {
3478
3492
  model: "base_import.import" /* BASE_IMPORT */,
3479
3493
  method: "parse_preview",
@@ -3503,7 +3517,7 @@ var ExcelService = {
3503
3517
  },
3504
3518
  with_context: context
3505
3519
  };
3506
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3520
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3507
3521
  headers: {
3508
3522
  "Content-Type": "multipart/form-data"
3509
3523
  }
@@ -3517,7 +3531,7 @@ var ExcelService = {
3517
3531
  dryrun,
3518
3532
  context
3519
3533
  }) {
3520
- const env = getEnv();
3534
+ const env2 = getEnv();
3521
3535
  const jsonData = {
3522
3536
  model: "base_import.import" /* BASE_IMPORT */,
3523
3537
  method: "execute_import",
@@ -3530,20 +3544,20 @@ var ExcelService = {
3530
3544
  },
3531
3545
  with_context: context
3532
3546
  };
3533
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3547
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3534
3548
  headers: {
3535
3549
  "Content-Type": "multipart/form-data"
3536
3550
  }
3537
3551
  });
3538
3552
  },
3539
3553
  async getFileExcel({ model }) {
3540
- const env = getEnv();
3554
+ const env2 = getEnv();
3541
3555
  const jsonData = {
3542
3556
  model,
3543
3557
  method: "get_import_templates" /* GET_IMPORT */,
3544
3558
  args: []
3545
3559
  };
3546
- return env.requests.post("/call" /* CALL_PATH */, jsonData);
3560
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData);
3547
3561
  },
3548
3562
  async getFieldExport({
3549
3563
  ids,
@@ -3557,7 +3571,7 @@ var ExcelService = {
3557
3571
  context,
3558
3572
  importCompat
3559
3573
  }) {
3560
- const env = getEnv();
3574
+ const env2 = getEnv();
3561
3575
  const jsonData = {
3562
3576
  model,
3563
3577
  import_compat: importCompat,
@@ -3572,7 +3586,7 @@ var ExcelService = {
3572
3586
  jsonData.prefix = prefix;
3573
3587
  jsonData.exclude = [null];
3574
3588
  }
3575
- return env.requests.post("/export/get_fields", jsonData);
3589
+ return env2.requests.post("/export/get_fields", jsonData);
3576
3590
  },
3577
3591
  async exportExcel({
3578
3592
  model,
@@ -3584,7 +3598,7 @@ var ExcelService = {
3584
3598
  context,
3585
3599
  groupby
3586
3600
  }) {
3587
- const env = getEnv();
3601
+ const env2 = getEnv();
3588
3602
  const jsonData = {
3589
3603
  model,
3590
3604
  domain,
@@ -3594,7 +3608,7 @@ var ExcelService = {
3594
3608
  with_context: context,
3595
3609
  groupby: groupby ?? []
3596
3610
  };
3597
- return env.requests.post_excel(`/export/${type}`, jsonData);
3611
+ return env2.requests.post_excel(`/export/${type}`, jsonData);
3598
3612
  }
3599
3613
  };
3600
3614
  var excel_service_default = ExcelService;
@@ -3603,7 +3617,7 @@ var excel_service_default = ExcelService;
3603
3617
  var FormService = {
3604
3618
  async getComment({ data }) {
3605
3619
  try {
3606
- const env = getEnv();
3620
+ const env2 = getEnv();
3607
3621
  const jsonData = {
3608
3622
  thread_id: data.thread_id,
3609
3623
  thread_model: data.thread_model,
@@ -3612,7 +3626,7 @@ var FormService = {
3612
3626
  lang: data.lang
3613
3627
  }
3614
3628
  };
3615
- return env.requests.post("/chatter/thread/messages" /* GET_MESSAGE */, jsonData, {
3629
+ return env2.requests.post("/chatter/thread/messages" /* GET_MESSAGE */, jsonData, {
3616
3630
  headers: {
3617
3631
  "Content-Type": "application/json"
3618
3632
  }
@@ -3624,7 +3638,7 @@ var FormService = {
3624
3638
  },
3625
3639
  async sentComment({ data }) {
3626
3640
  try {
3627
- const env = getEnv();
3641
+ const env2 = getEnv();
3628
3642
  const jsonData = {
3629
3643
  context: {
3630
3644
  tz: "Asia/Saigon",
@@ -3643,7 +3657,7 @@ var FormService = {
3643
3657
  thread_id: Number(data.thread_id),
3644
3658
  thread_model: data.thread_model
3645
3659
  };
3646
- return env.requests.post("/chatter/message/post" /* SENT_MESSAGE */, jsonData, {
3660
+ return env2.requests.post("/chatter/message/post" /* SENT_MESSAGE */, jsonData, {
3647
3661
  headers: {
3648
3662
  "Content-Type": "application/json"
3649
3663
  }
@@ -3655,14 +3669,14 @@ var FormService = {
3655
3669
  },
3656
3670
  async deleteComment({ data }) {
3657
3671
  try {
3658
- const env = getEnv();
3672
+ const env2 = getEnv();
3659
3673
  const jsonData = {
3660
3674
  attachment_ids: [],
3661
3675
  attachment_tokens: [],
3662
3676
  body: "",
3663
3677
  message_id: data.message_id
3664
3678
  };
3665
- return env.requests.post("/chatter/message/update_content" /* DELETE_MESSAGE */, jsonData, {
3679
+ return env2.requests.post("/chatter/message/update_content" /* DELETE_MESSAGE */, jsonData, {
3666
3680
  headers: {
3667
3681
  "Content-Type": "application/json"
3668
3682
  }
@@ -3674,8 +3688,8 @@ var FormService = {
3674
3688
  },
3675
3689
  async getImage({ data }) {
3676
3690
  try {
3677
- const env = getEnv();
3678
- return env.requests.get(
3691
+ const env2 = getEnv();
3692
+ return env2.requests.get(
3679
3693
  `${"/web/image" /* IMAGE_PATH */}?filename=${data.filename}&unique=${data.checksum}&width=1920&height=300`,
3680
3694
  {
3681
3695
  headers: {
@@ -3690,8 +3704,8 @@ var FormService = {
3690
3704
  },
3691
3705
  async uploadImage({ data }) {
3692
3706
  try {
3693
- const env = getEnv();
3694
- return env.requests.post("/mail/attachment/upload" /* UPLOAD_IMAGE */, data, {
3707
+ const env2 = getEnv();
3708
+ return env2.requests.post("/mail/attachment/upload" /* UPLOAD_IMAGE */, data, {
3695
3709
  headers: {
3696
3710
  "Content-Type": "multipart/form-data"
3697
3711
  }
@@ -3703,14 +3717,14 @@ var FormService = {
3703
3717
  },
3704
3718
  async getFormView({ data }) {
3705
3719
  try {
3706
- const env = getEnv();
3720
+ const env2 = getEnv();
3707
3721
  const jsonData = {
3708
3722
  model: data.model,
3709
3723
  method: "get_formview_action",
3710
3724
  ids: data.id ? [data.id] : [],
3711
3725
  with_context: data.context
3712
3726
  };
3713
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3727
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3714
3728
  headers: {
3715
3729
  "Content-Type": "application/json"
3716
3730
  }
@@ -3721,7 +3735,7 @@ var FormService = {
3721
3735
  }
3722
3736
  },
3723
3737
  async changeStatus({ data }) {
3724
- const env = getEnv();
3738
+ const env2 = getEnv();
3725
3739
  const vals = {
3726
3740
  [data.name]: data.stage_id
3727
3741
  };
@@ -3741,7 +3755,7 @@ var FormService = {
3741
3755
  specification: {}
3742
3756
  }
3743
3757
  };
3744
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
3758
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
3745
3759
  headers: {
3746
3760
  "Content-Type": "application/json"
3747
3761
  }
@@ -3756,7 +3770,7 @@ var KanbanServices = {
3756
3770
  model,
3757
3771
  width_context
3758
3772
  }) {
3759
- const env = getEnv();
3773
+ const env2 = getEnv();
3760
3774
  const jsonDataView = {
3761
3775
  model,
3762
3776
  method: "web_read_group",
@@ -3767,7 +3781,7 @@ var KanbanServices = {
3767
3781
  },
3768
3782
  width_context
3769
3783
  };
3770
- return env.requests.post("/call" /* CALL_PATH */, jsonDataView, {
3784
+ return env2.requests.post("/call" /* CALL_PATH */, jsonDataView, {
3771
3785
  headers: {
3772
3786
  "Content-Type": "application/json"
3773
3787
  }
@@ -3779,7 +3793,7 @@ var KanbanServices = {
3779
3793
  model,
3780
3794
  width_context
3781
3795
  }) {
3782
- const env = getEnv();
3796
+ const env2 = getEnv();
3783
3797
  const jsonDataView = {
3784
3798
  model,
3785
3799
  method: "read_progress_bar",
@@ -3793,7 +3807,7 @@ var KanbanServices = {
3793
3807
  },
3794
3808
  width_context
3795
3809
  };
3796
- return env.requests.post("/call" /* CALL_PATH */, jsonDataView, {
3810
+ return env2.requests.post("/call" /* CALL_PATH */, jsonDataView, {
3797
3811
  headers: {
3798
3812
  "Content-Type": "application/json"
3799
3813
  }
@@ -3810,7 +3824,7 @@ var ModelService = {
3810
3824
  spectification,
3811
3825
  model
3812
3826
  }) {
3813
- const env = getEnv();
3827
+ const env2 = getEnv();
3814
3828
  const jsonData = {
3815
3829
  model,
3816
3830
  method: "web_search_read",
@@ -3821,14 +3835,14 @@ var ModelService = {
3821
3835
  offset: 0
3822
3836
  }
3823
3837
  };
3824
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
3838
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
3825
3839
  headers: {
3826
3840
  "Content-Type": "application/json"
3827
3841
  }
3828
3842
  });
3829
3843
  },
3830
3844
  async getCurrency() {
3831
- const env = getEnv();
3845
+ const env2 = getEnv();
3832
3846
  const jsonData = {
3833
3847
  model: "res.currency",
3834
3848
  method: "web_search_read",
@@ -3842,14 +3856,14 @@ var ModelService = {
3842
3856
  offset: 0
3843
3857
  }
3844
3858
  };
3845
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
3859
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
3846
3860
  headers: {
3847
3861
  "Content-Type": "application/json"
3848
3862
  }
3849
3863
  });
3850
3864
  },
3851
3865
  async getConversionRate() {
3852
- const env = getEnv();
3866
+ const env2 = getEnv();
3853
3867
  const jsonData = {
3854
3868
  model: "res.currency",
3855
3869
  method: "web_search_read",
@@ -3869,14 +3883,14 @@ var ModelService = {
3869
3883
  offset: 0
3870
3884
  }
3871
3885
  };
3872
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
3886
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
3873
3887
  headers: {
3874
3888
  "Content-Type": "application/json"
3875
3889
  }
3876
3890
  });
3877
3891
  },
3878
3892
  async getAll({ data }) {
3879
- const env = getEnv();
3893
+ const env2 = getEnv();
3880
3894
  const jsonReadGroup = data.type == "calendar" ? { fields: data?.fields } : data.fields && data.fields.length > 0 && data.groupby && data.groupby.length > 0 && data.groupby[0] ? {
3881
3895
  fields: data.fields,
3882
3896
  groupby: data.groupby
@@ -3897,14 +3911,14 @@ var ModelService = {
3897
3911
  ...jsonReadGroup
3898
3912
  }
3899
3913
  };
3900
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
3914
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
3901
3915
  headers: {
3902
3916
  "Content-Type": "application/json"
3903
3917
  }
3904
3918
  });
3905
3919
  },
3906
3920
  async getListCalendar({ data }) {
3907
- const env = getEnv();
3921
+ const env2 = getEnv();
3908
3922
  const jsonReadGroup = data.type == "calendar" ? data?.fields : data.fields && data.fields.length > 0 && data.groupby && data.groupby.length > 0 && data.groupby[0] ? {
3909
3923
  fields: data.fields,
3910
3924
  groupby: data.groupby
@@ -3926,7 +3940,7 @@ var ModelService = {
3926
3940
  ...jsonReadGroup
3927
3941
  }
3928
3942
  };
3929
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
3943
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
3930
3944
  headers: {
3931
3945
  "Content-Type": "application/json"
3932
3946
  }
@@ -3942,7 +3956,7 @@ var ModelService = {
3942
3956
  context = {},
3943
3957
  limit = 10
3944
3958
  }) {
3945
- const env = getEnv();
3959
+ const env2 = getEnv();
3946
3960
  const jsonData = {
3947
3961
  model,
3948
3962
  method: "web_search_read" /* WEB_SEARCH_READ */,
@@ -3956,7 +3970,7 @@ var ModelService = {
3956
3970
  order
3957
3971
  }
3958
3972
  };
3959
- return env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
3973
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
3960
3974
  headers: {
3961
3975
  "Content-Type": "application/json"
3962
3976
  }
@@ -3968,7 +3982,7 @@ var ModelService = {
3968
3982
  specification,
3969
3983
  context
3970
3984
  }) {
3971
- const env = getEnv();
3985
+ const env2 = getEnv();
3972
3986
  const jsonData = {
3973
3987
  model,
3974
3988
  method: "web_read" /* WEB_READ */,
@@ -3978,7 +3992,7 @@ var ModelService = {
3978
3992
  specification
3979
3993
  }
3980
3994
  };
3981
- return env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
3995
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
3982
3996
  headers: {
3983
3997
  "Content-Type": "application/json"
3984
3998
  }
@@ -3992,7 +4006,7 @@ var ModelService = {
3992
4006
  context = {},
3993
4007
  path
3994
4008
  }) {
3995
- const env = getEnv();
4009
+ const env2 = getEnv();
3996
4010
  const jsonData = {
3997
4011
  model,
3998
4012
  method: "web_save" /* WEB_SAVE */,
@@ -4003,20 +4017,20 @@ var ModelService = {
4003
4017
  specification
4004
4018
  }
4005
4019
  };
4006
- return env?.requests?.post(path ?? "/call" /* CALL_PATH */, jsonData, {
4020
+ return env2?.requests?.post(path ?? "/call" /* CALL_PATH */, jsonData, {
4007
4021
  headers: {
4008
4022
  "Content-Type": "application/json"
4009
4023
  }
4010
4024
  });
4011
4025
  },
4012
4026
  async delete({ ids = [], model }) {
4013
- const env = getEnv();
4027
+ const env2 = getEnv();
4014
4028
  const jsonData = {
4015
4029
  model,
4016
4030
  method: "unlink" /* UNLINK */,
4017
4031
  ids
4018
4032
  };
4019
- return env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4033
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4020
4034
  headers: {
4021
4035
  "Content-Type": "application/json"
4022
4036
  }
@@ -4030,7 +4044,7 @@ var ModelService = {
4030
4044
  context,
4031
4045
  fieldChange
4032
4046
  }) {
4033
- const env = getEnv();
4047
+ const env2 = getEnv();
4034
4048
  const jsonData = {
4035
4049
  model,
4036
4050
  method: "onchange" /* ONCHANGE */,
@@ -4042,19 +4056,19 @@ var ModelService = {
4042
4056
  specification
4043
4057
  ]
4044
4058
  };
4045
- return env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4059
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4046
4060
  headers: {
4047
4061
  "Content-Type": "application/json"
4048
4062
  }
4049
4063
  });
4050
4064
  },
4051
4065
  async getListFieldsOnchange({ model }) {
4052
- const env = getEnv();
4066
+ const env2 = getEnv();
4053
4067
  const jsonData = {
4054
4068
  model,
4055
4069
  method: "get_fields_onchange" /* GET_ONCHANGE_FIELDS */
4056
4070
  };
4057
- return env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4071
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4058
4072
  headers: {
4059
4073
  "Content-Type": "application/json"
4060
4074
  }
@@ -4122,15 +4136,15 @@ var model_service_default = ModelService;
4122
4136
  // src/services/user-service/index.ts
4123
4137
  var UserService = {
4124
4138
  async getProfile(path) {
4125
- const env = getEnv();
4126
- return env.requests.get(path ?? "/userinfo" /* PROFILE_PATH */, {
4139
+ const env2 = getEnv();
4140
+ return env2?.requests?.get(path ?? "/userinfo" /* PROFILE_PATH */, {
4127
4141
  headers: {
4128
4142
  "Content-Type": "application/x-www-form-urlencoded"
4129
4143
  }
4130
4144
  });
4131
4145
  },
4132
4146
  async getUser({ context, id }) {
4133
- const env = getEnv();
4147
+ const env2 = getEnv();
4134
4148
  const jsonData = {
4135
4149
  model: "res.users",
4136
4150
  method: "web_read",
@@ -4159,20 +4173,20 @@ var UserService = {
4159
4173
  }
4160
4174
  }
4161
4175
  };
4162
- return env.requests.post("/call" /* CALL_PATH */, jsonData, {
4176
+ return env2.requests.post("/call" /* CALL_PATH */, jsonData, {
4163
4177
  headers: {
4164
4178
  "Content-Type": "application/json"
4165
4179
  }
4166
4180
  });
4167
4181
  },
4168
4182
  switchUserLocale: async ({ id, values }) => {
4169
- const env = getEnv();
4183
+ const env2 = getEnv();
4170
4184
  const jsonData = {
4171
4185
  model: "res.users",
4172
4186
  domain: [["id", "=", id]],
4173
4187
  values
4174
4188
  };
4175
- return env?.requests.post(UriConstants?.CREATE_UPDATE_PATH, jsonData, {
4189
+ return env2?.requests.post(UriConstants?.CREATE_UPDATE_PATH, jsonData, {
4176
4190
  headers: {
4177
4191
  "Content-Type": "application/json"
4178
4192
  }
@@ -4190,7 +4204,7 @@ var ViewService = {
4190
4204
  options = {},
4191
4205
  aid
4192
4206
  }) {
4193
- const env = getEnv();
4207
+ const env2 = getEnv();
4194
4208
  const defaultOptions = {
4195
4209
  load_filters: true,
4196
4210
  toolbar: true,
@@ -4205,14 +4219,14 @@ var ViewService = {
4205
4219
  },
4206
4220
  with_context: context
4207
4221
  };
4208
- return env?.requests?.post("/call" /* CALL_PATH */, jsonDataView, {
4222
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonDataView, {
4209
4223
  headers: {
4210
4224
  "Content-Type": "application/json"
4211
4225
  }
4212
4226
  });
4213
4227
  },
4214
4228
  async getMenu(context) {
4215
- const env = getEnv();
4229
+ const env2 = getEnv();
4216
4230
  const jsonData = {
4217
4231
  model: "ir.ui.menu" /* MENU */,
4218
4232
  method: "web_search_read" /* WEB_SEARCH_READ */,
@@ -4349,14 +4363,14 @@ var ViewService = {
4349
4363
  ]
4350
4364
  }
4351
4365
  };
4352
- return env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4366
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4353
4367
  headers: {
4354
4368
  "Content-Type": "application/json"
4355
4369
  }
4356
4370
  });
4357
4371
  },
4358
4372
  async getActionDetail(aid, context) {
4359
- const env = getEnv();
4373
+ const env2 = getEnv();
4360
4374
  const jsonData = {
4361
4375
  model: "ir.actions.act_window" /* WINDOW_ACTION */,
4362
4376
  method: "web_read" /* WEB_READ */,
@@ -4377,7 +4391,7 @@ var ViewService = {
4377
4391
  }
4378
4392
  }
4379
4393
  };
4380
- return env?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4394
+ return env2?.requests?.post("/call" /* CALL_PATH */, jsonData, {
4381
4395
  headers: {
4382
4396
  "Content-Type": "application/json"
4383
4397
  }
@@ -4389,7 +4403,7 @@ var ViewService = {
4389
4403
  context,
4390
4404
  offset
4391
4405
  }) {
4392
- const env = getEnv();
4406
+ const env2 = getEnv();
4393
4407
  const jsonData = {
4394
4408
  model,
4395
4409
  with_context: context,
@@ -4397,14 +4411,14 @@ var ViewService = {
4397
4411
  field: "sequence",
4398
4412
  ...offset > 0 ? { offset } : {}
4399
4413
  };
4400
- return env?.requests.post("/web/dataset/resequence", jsonData, {
4414
+ return env2?.requests.post("/web/dataset/resequence", jsonData, {
4401
4415
  headers: {
4402
4416
  "Content-Type": "application/json"
4403
4417
  }
4404
4418
  });
4405
4419
  },
4406
4420
  async getSelectionItem({ data }) {
4407
- const env = getEnv();
4421
+ const env2 = getEnv();
4408
4422
  const jsonData = {
4409
4423
  model: data.model,
4410
4424
  ids: [],
@@ -4422,15 +4436,15 @@ var ViewService = {
4422
4436
  }
4423
4437
  }
4424
4438
  };
4425
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4439
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4426
4440
  headers: {
4427
4441
  "Content-Type": "application/json"
4428
4442
  }
4429
4443
  });
4430
4444
  },
4431
4445
  async loadMessages() {
4432
- const env = getEnv();
4433
- return env.requests.post(
4446
+ const env2 = getEnv();
4447
+ return env2.requests.post(
4434
4448
  "/load_message_failures" /* LOAD_MESSAGE */,
4435
4449
  {},
4436
4450
  {
@@ -4441,9 +4455,8 @@ var ViewService = {
4441
4455
  );
4442
4456
  },
4443
4457
  async getVersion() {
4444
- const env = getEnv();
4445
- console.log("env?.requests", env, env?.requests);
4446
- return env?.requests?.get("", {
4458
+ const env2 = getEnv();
4459
+ return env2?.requests.get("", {
4447
4460
  headers: {
4448
4461
  "Content-Type": "application/json"
4449
4462
  }
@@ -4453,12 +4466,12 @@ var ViewService = {
4453
4466
  method,
4454
4467
  with_context
4455
4468
  }) {
4456
- const env = getEnv();
4469
+ const env2 = getEnv();
4457
4470
  const jsonData = {
4458
4471
  method,
4459
4472
  with_context
4460
4473
  };
4461
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4474
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4462
4475
  headers: {
4463
4476
  "Content-Type": "application/json"
4464
4477
  }
@@ -4471,7 +4484,7 @@ var ViewService = {
4471
4484
  device,
4472
4485
  location
4473
4486
  }) {
4474
- const env = getEnv();
4487
+ const env2 = getEnv();
4475
4488
  const jsonData = {
4476
4489
  method,
4477
4490
  kwargs: {
@@ -4483,7 +4496,7 @@ var ViewService = {
4483
4496
  },
4484
4497
  with_context
4485
4498
  };
4486
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4499
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4487
4500
  headers: {
4488
4501
  "Content-Type": "application/json"
4489
4502
  },
@@ -4497,7 +4510,7 @@ var ViewService = {
4497
4510
  response_type,
4498
4511
  path
4499
4512
  }) {
4500
- const env = getEnv();
4513
+ const env2 = getEnv();
4501
4514
  const params = new URLSearchParams({
4502
4515
  response_type,
4503
4516
  client_id,
@@ -4505,7 +4518,7 @@ var ViewService = {
4505
4518
  state
4506
4519
  });
4507
4520
  const url = `${path}?${params.toString()}`;
4508
- return env?.requests.get(url, {
4521
+ return env2?.requests.get(url, {
4509
4522
  headers: {
4510
4523
  "Content-Type": "application/json"
4511
4524
  },
@@ -4518,14 +4531,14 @@ var ViewService = {
4518
4531
  client_id,
4519
4532
  scopes
4520
4533
  }) {
4521
- const env = getEnv();
4534
+ const env2 = getEnv();
4522
4535
  const jsonData = {
4523
4536
  redirect_uri,
4524
4537
  state,
4525
4538
  client_id,
4526
4539
  scopes
4527
4540
  };
4528
- return env?.requests.post("/grant-access" /* GRANT_ACCESS */, jsonData, {
4541
+ return env2?.requests.post("/grant-access" /* GRANT_ACCESS */, jsonData, {
4529
4542
  headers: {
4530
4543
  "Content-Type": "application/json"
4531
4544
  },
@@ -4537,7 +4550,7 @@ var ViewService = {
4537
4550
  token,
4538
4551
  views
4539
4552
  }) {
4540
- const env = getEnv();
4553
+ const env2 = getEnv();
4541
4554
  const jsonData = {
4542
4555
  method,
4543
4556
  kwargs: {
@@ -4547,7 +4560,7 @@ var ViewService = {
4547
4560
  token
4548
4561
  }
4549
4562
  };
4550
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4563
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4551
4564
  headers: {
4552
4565
  "Content-Type": "application/json"
4553
4566
  }
@@ -4559,7 +4572,7 @@ var ViewService = {
4559
4572
  kwargs,
4560
4573
  token
4561
4574
  }) {
4562
- const env = getEnv();
4575
+ const env2 = getEnv();
4563
4576
  const jsonData = {
4564
4577
  method,
4565
4578
  model,
@@ -4568,21 +4581,21 @@ var ViewService = {
4568
4581
  token
4569
4582
  }
4570
4583
  };
4571
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4584
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4572
4585
  headers: {
4573
4586
  "Content-Type": "application/json"
4574
4587
  }
4575
4588
  });
4576
4589
  },
4577
4590
  async requestSetupTotp({ method, token }) {
4578
- const env = getEnv();
4591
+ const env2 = getEnv();
4579
4592
  const jsonData = {
4580
4593
  method,
4581
4594
  with_context: {
4582
4595
  token
4583
4596
  }
4584
4597
  };
4585
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4598
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4586
4599
  headers: {
4587
4600
  "Content-Type": "application/json"
4588
4601
  }
@@ -4593,7 +4606,7 @@ var ViewService = {
4593
4606
  action_token,
4594
4607
  code
4595
4608
  }) {
4596
- const env = getEnv();
4609
+ const env2 = getEnv();
4597
4610
  const jsonData = {
4598
4611
  method,
4599
4612
  kwargs: {
@@ -4605,21 +4618,21 @@ var ViewService = {
4605
4618
  action_token
4606
4619
  }
4607
4620
  };
4608
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4621
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4609
4622
  headers: {
4610
4623
  "Content-Type": "application/json"
4611
4624
  }
4612
4625
  });
4613
4626
  },
4614
4627
  async removeTotpSetUp({ method, token }) {
4615
- const env = getEnv();
4628
+ const env2 = getEnv();
4616
4629
  const jsonData = {
4617
4630
  method,
4618
4631
  with_context: {
4619
4632
  token
4620
4633
  }
4621
4634
  };
4622
- return env?.requests.post("/call" /* CALL_PATH */, jsonData, {
4635
+ return env2?.requests.post("/call" /* CALL_PATH */, jsonData, {
4623
4636
  headers: {
4624
4637
  "Content-Type": "application/json"
4625
4638
  }
@@ -4760,19 +4773,33 @@ var useGetAccessByCode = () => {
4760
4773
  };
4761
4774
  var use_get_access_by_code_default = useGetAccessByCode;
4762
4775
 
4763
- // src/hooks/company/use-get-company-info.ts
4776
+ // src/hooks/auth/use-validate-action-token.ts
4764
4777
  import { useMutation as useMutation12 } from "@tanstack/react-query";
4765
- var useGetCompanyInfo = () => {
4778
+ var useValidateActionToken = () => {
4766
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({
4767
4794
  mutationFn: (id) => company_service_default.getInfoCompany(id)
4768
4795
  });
4769
4796
  };
4770
4797
  var use_get_company_info_default = useGetCompanyInfo;
4771
4798
 
4772
4799
  // src/hooks/company/use-get-current-company.ts
4773
- import { useMutation as useMutation13 } from "@tanstack/react-query";
4800
+ import { useMutation as useMutation14 } from "@tanstack/react-query";
4774
4801
  var useGetCurrentCompany = () => {
4775
- return useMutation13({
4802
+ return useMutation14({
4776
4803
  mutationFn: () => company_service_default.getCurrentCompany()
4777
4804
  });
4778
4805
  };
@@ -4799,9 +4826,9 @@ var useGetListCompany = (companyIDs = []) => {
4799
4826
  var use_get_list_company_default = useGetListCompany;
4800
4827
 
4801
4828
  // src/hooks/excel/use-export-excel.ts
4802
- import { useMutation as useMutation14 } from "@tanstack/react-query";
4829
+ import { useMutation as useMutation15 } from "@tanstack/react-query";
4803
4830
  var useExportExcel = () => {
4804
- return useMutation14({
4831
+ return useMutation15({
4805
4832
  mutationFn: ({
4806
4833
  model,
4807
4834
  domain,
@@ -4826,9 +4853,9 @@ var useExportExcel = () => {
4826
4853
  var use_export_excel_default = useExportExcel;
4827
4854
 
4828
4855
  // src/hooks/excel/use-get-field-export.ts
4829
- import { useMutation as useMutation15 } from "@tanstack/react-query";
4856
+ import { useMutation as useMutation16 } from "@tanstack/react-query";
4830
4857
  var useGetFieldExport = () => {
4831
- return useMutation15({
4858
+ return useMutation16({
4832
4859
  mutationFn: ({
4833
4860
  ids,
4834
4861
  model,
@@ -4875,9 +4902,9 @@ var useGetFileExcel = ({ model }) => {
4875
4902
  var use_get_file_excel_default = useGetFileExcel;
4876
4903
 
4877
4904
  // src/hooks/excel/use-parse-preview.ts
4878
- import { useMutation as useMutation16 } from "@tanstack/react-query";
4905
+ import { useMutation as useMutation17 } from "@tanstack/react-query";
4879
4906
  var useParsePreview = () => {
4880
- return useMutation16({
4907
+ return useMutation17({
4881
4908
  mutationFn: ({
4882
4909
  id,
4883
4910
  selectedSheet,
@@ -4894,9 +4921,9 @@ var useParsePreview = () => {
4894
4921
  var use_parse_preview_default = useParsePreview;
4895
4922
 
4896
4923
  // src/hooks/excel/use-upload-file.ts
4897
- import { useMutation as useMutation17 } from "@tanstack/react-query";
4924
+ import { useMutation as useMutation18 } from "@tanstack/react-query";
4898
4925
  var useUploadFile = () => {
4899
- return useMutation17({
4926
+ return useMutation18({
4900
4927
  mutationFn: ({ formData }) => excel_service_default.uploadFile({
4901
4928
  formData
4902
4929
  })
@@ -4905,9 +4932,9 @@ var useUploadFile = () => {
4905
4932
  var use_upload_file_default = useUploadFile;
4906
4933
 
4907
4934
  // src/hooks/excel/use-upload-id-file.ts
4908
- import { useMutation as useMutation18 } from "@tanstack/react-query";
4935
+ import { useMutation as useMutation19 } from "@tanstack/react-query";
4909
4936
  var useUploadIdFile = () => {
4910
- return useMutation18({
4937
+ return useMutation19({
4911
4938
  mutationFn: ({ formData }) => excel_service_default.uploadIdFile({
4912
4939
  formData
4913
4940
  })
@@ -4916,9 +4943,9 @@ var useUploadIdFile = () => {
4916
4943
  var use_upload_id_file_default = useUploadIdFile;
4917
4944
 
4918
4945
  // src/hooks/excel/uss-execute-import.ts
4919
- import { useMutation as useMutation19 } from "@tanstack/react-query";
4946
+ import { useMutation as useMutation20 } from "@tanstack/react-query";
4920
4947
  var useExecuteImport = () => {
4921
- return useMutation19({
4948
+ return useMutation20({
4922
4949
  mutationFn: ({
4923
4950
  fields,
4924
4951
  columns,
@@ -4939,9 +4966,9 @@ var useExecuteImport = () => {
4939
4966
  var uss_execute_import_default = useExecuteImport;
4940
4967
 
4941
4968
  // src/hooks/form/use-change-status.ts
4942
- import { useMutation as useMutation20 } from "@tanstack/react-query";
4969
+ import { useMutation as useMutation21 } from "@tanstack/react-query";
4943
4970
  var useChangeStatus = () => {
4944
- return useMutation20({
4971
+ return useMutation21({
4945
4972
  mutationFn: ({ data }) => {
4946
4973
  return form_service_default.changeStatus({
4947
4974
  data
@@ -4952,9 +4979,9 @@ var useChangeStatus = () => {
4952
4979
  var use_change_status_default = useChangeStatus;
4953
4980
 
4954
4981
  // src/hooks/form/use-delete-comment.ts
4955
- import { useMutation as useMutation21 } from "@tanstack/react-query";
4982
+ import { useMutation as useMutation22 } from "@tanstack/react-query";
4956
4983
  var useDeleteComment = () => {
4957
- return useMutation21({
4984
+ return useMutation22({
4958
4985
  mutationFn: ({ data }) => form_service_default.deleteComment({
4959
4986
  data
4960
4987
  })
@@ -5019,9 +5046,9 @@ var useGetImage = ({
5019
5046
  var use_get_image_default = useGetImage;
5020
5047
 
5021
5048
  // src/hooks/form/use-send-comment.ts
5022
- import { useMutation as useMutation22 } from "@tanstack/react-query";
5049
+ import { useMutation as useMutation23 } from "@tanstack/react-query";
5023
5050
  var useSendComment = () => {
5024
- return useMutation22({
5051
+ return useMutation23({
5025
5052
  mutationFn: ({ data }) => form_service_default.sentComment({
5026
5053
  data
5027
5054
  })
@@ -5030,9 +5057,9 @@ var useSendComment = () => {
5030
5057
  var use_send_comment_default = useSendComment;
5031
5058
 
5032
5059
  // src/hooks/form/use-upload-image.ts
5033
- import { useMutation as useMutation23 } from "@tanstack/react-query";
5060
+ import { useMutation as useMutation24 } from "@tanstack/react-query";
5034
5061
  var useUploadImage = () => {
5035
- return useMutation23({
5062
+ return useMutation24({
5036
5063
  mutationFn: ({ data }) => form_service_default.uploadImage({
5037
5064
  data
5038
5065
  })
@@ -5041,9 +5068,9 @@ var useUploadImage = () => {
5041
5068
  var use_upload_image_default = useUploadImage;
5042
5069
 
5043
5070
  // src/hooks/model/use-delete.ts
5044
- import { useMutation as useMutation24 } from "@tanstack/react-query";
5071
+ import { useMutation as useMutation25 } from "@tanstack/react-query";
5045
5072
  var useDelete = () => {
5046
- return useMutation24({
5073
+ return useMutation25({
5047
5074
  mutationFn: ({ ids, model }) => model_service_default.delete({ ids, model })
5048
5075
  });
5049
5076
  };
@@ -5097,9 +5124,9 @@ var useGetCurrency = () => {
5097
5124
  var use_get_currency_default = useGetCurrency;
5098
5125
 
5099
5126
  // src/hooks/model/use-get-detail.ts
5100
- import { useMutation as useMutation25 } from "@tanstack/react-query";
5127
+ import { useMutation as useMutation26 } from "@tanstack/react-query";
5101
5128
  var useGetDetail = () => {
5102
- return useMutation25({
5129
+ return useMutation26({
5103
5130
  mutationFn: ({
5104
5131
  model,
5105
5132
  ids,
@@ -5292,9 +5319,9 @@ var useOdooDataTransform = () => {
5292
5319
  var use_odoo_data_transform_default = useOdooDataTransform;
5293
5320
 
5294
5321
  // src/hooks/model/use-onchange-form.ts
5295
- import { useMutation as useMutation26 } from "@tanstack/react-query";
5322
+ import { useMutation as useMutation27 } from "@tanstack/react-query";
5296
5323
  var useOnChangeForm = () => {
5297
- return useMutation26({
5324
+ return useMutation27({
5298
5325
  mutationFn: ({
5299
5326
  ids,
5300
5327
  model,
@@ -5315,9 +5342,9 @@ var useOnChangeForm = () => {
5315
5342
  var use_onchange_form_default = useOnChangeForm;
5316
5343
 
5317
5344
  // src/hooks/model/use-save.ts
5318
- import { useMutation as useMutation27 } from "@tanstack/react-query";
5345
+ import { useMutation as useMutation28 } from "@tanstack/react-query";
5319
5346
  var useSave = () => {
5320
- return useMutation27({
5347
+ return useMutation28({
5321
5348
  mutationFn: ({
5322
5349
  ids,
5323
5350
  model,
@@ -5331,18 +5358,18 @@ var useSave = () => {
5331
5358
  var use_save_default = useSave;
5332
5359
 
5333
5360
  // src/hooks/user/use-get-profile.ts
5334
- import { useMutation as useMutation28 } from "@tanstack/react-query";
5361
+ import { useMutation as useMutation29 } from "@tanstack/react-query";
5335
5362
  var useGetProfile = (path) => {
5336
- return useMutation28({
5363
+ return useMutation29({
5337
5364
  mutationFn: () => user_service_default.getProfile(path)
5338
5365
  });
5339
5366
  };
5340
5367
  var use_get_profile_default = useGetProfile;
5341
5368
 
5342
5369
  // src/hooks/user/use-get-user.ts
5343
- import { useMutation as useMutation29 } from "@tanstack/react-query";
5370
+ import { useMutation as useMutation30 } from "@tanstack/react-query";
5344
5371
  var useGetUser = () => {
5345
- return useMutation29({
5372
+ return useMutation30({
5346
5373
  mutationFn: ({ id, context }) => user_service_default.getUser({
5347
5374
  id,
5348
5375
  context
@@ -5352,9 +5379,9 @@ var useGetUser = () => {
5352
5379
  var use_get_user_default = useGetUser;
5353
5380
 
5354
5381
  // src/hooks/user/use-switch-locale.ts
5355
- import { useMutation as useMutation30 } from "@tanstack/react-query";
5382
+ import { useMutation as useMutation31 } from "@tanstack/react-query";
5356
5383
  var useSwitchLocale = () => {
5357
- return useMutation30({
5384
+ return useMutation31({
5358
5385
  mutationFn: ({ data }) => {
5359
5386
  return user_service_default.switchUserLocale({
5360
5387
  id: data.id,
@@ -5366,9 +5393,9 @@ var useSwitchLocale = () => {
5366
5393
  var use_switch_locale_default = useSwitchLocale;
5367
5394
 
5368
5395
  // src/hooks/view/use-button.ts
5369
- import { useMutation as useMutation31 } from "@tanstack/react-query";
5396
+ import { useMutation as useMutation32 } from "@tanstack/react-query";
5370
5397
  var useButton = () => {
5371
- return useMutation31({
5398
+ return useMutation32({
5372
5399
  mutationFn: ({
5373
5400
  model,
5374
5401
  ids,
@@ -5388,9 +5415,9 @@ var useButton = () => {
5388
5415
  var use_button_default = useButton;
5389
5416
 
5390
5417
  // src/hooks/view/use-duplicate-record.ts
5391
- import { useMutation as useMutation32 } from "@tanstack/react-query";
5418
+ import { useMutation as useMutation33 } from "@tanstack/react-query";
5392
5419
  var useDuplicateRecord = () => {
5393
- return useMutation32({
5420
+ return useMutation33({
5394
5421
  mutationFn: ({
5395
5422
  id,
5396
5423
  model,
@@ -5516,9 +5543,9 @@ var useGetMenu = (context, enabled) => {
5516
5543
  var use_get_menu_default = useGetMenu;
5517
5544
 
5518
5545
  // src/hooks/view/use-get-print-report.ts
5519
- import { useMutation as useMutation33 } from "@tanstack/react-query";
5546
+ import { useMutation as useMutation34 } from "@tanstack/react-query";
5520
5547
  var useGetPrintReport = () => {
5521
- return useMutation33({
5548
+ return useMutation34({
5522
5549
  mutationFn: ({ id }) => action_service_default.getPrintReportName({
5523
5550
  id
5524
5551
  })
@@ -5582,9 +5609,9 @@ var useGetView = (viewParams, actData) => {
5582
5609
  var use_get_view_default = useGetView;
5583
5610
 
5584
5611
  // src/hooks/view/use-load-action.ts
5585
- import { useMutation as useMutation34 } from "@tanstack/react-query";
5612
+ import { useMutation as useMutation35 } from "@tanstack/react-query";
5586
5613
  var useLoadAction = () => {
5587
- return useMutation34({
5614
+ return useMutation35({
5588
5615
  mutationFn: ({
5589
5616
  idAction,
5590
5617
  context
@@ -5610,9 +5637,9 @@ var useLoadMessage = () => {
5610
5637
  var use_load_message_default = useLoadMessage;
5611
5638
 
5612
5639
  // src/hooks/view/use-print.ts
5613
- import { useMutation as useMutation35 } from "@tanstack/react-query";
5640
+ import { useMutation as useMutation36 } from "@tanstack/react-query";
5614
5641
  var usePrint = () => {
5615
- return useMutation35({
5642
+ return useMutation36({
5616
5643
  mutationFn: ({ id, report, db }) => action_service_default.print({
5617
5644
  id,
5618
5645
  report,
@@ -5623,9 +5650,9 @@ var usePrint = () => {
5623
5650
  var use_print_default = usePrint;
5624
5651
 
5625
5652
  // src/hooks/view/use-remove-row.ts
5626
- import { useMutation as useMutation36 } from "@tanstack/react-query";
5653
+ import { useMutation as useMutation37 } from "@tanstack/react-query";
5627
5654
  var useRemoveRow = () => {
5628
- return useMutation36({
5655
+ return useMutation37({
5629
5656
  mutationFn: ({
5630
5657
  model,
5631
5658
  ids,
@@ -5657,9 +5684,9 @@ var useGetResequence = (model, resIds, context, offset) => {
5657
5684
  var use_resequence_default = useGetResequence;
5658
5685
 
5659
5686
  // src/hooks/view/use-run-action.ts
5660
- import { useMutation as useMutation37 } from "@tanstack/react-query";
5687
+ import { useMutation as useMutation38 } from "@tanstack/react-query";
5661
5688
  var useRunAction = () => {
5662
- return useMutation37({
5689
+ return useMutation38({
5663
5690
  mutationFn: ({
5664
5691
  idAction,
5665
5692
  context
@@ -5672,9 +5699,9 @@ var useRunAction = () => {
5672
5699
  var use_run_action_default = useRunAction;
5673
5700
 
5674
5701
  // src/hooks/view/use-signin-sso.ts
5675
- import { useMutation as useMutation38 } from "@tanstack/react-query";
5702
+ import { useMutation as useMutation39 } from "@tanstack/react-query";
5676
5703
  var useSignInSSO = () => {
5677
- return useMutation38({
5704
+ return useMutation39({
5678
5705
  mutationFn: ({
5679
5706
  redirect_uri,
5680
5707
  state,
@@ -5695,9 +5722,9 @@ var useSignInSSO = () => {
5695
5722
  var use_signin_sso_default = useSignInSSO;
5696
5723
 
5697
5724
  // src/hooks/view/use-verify-2FA.ts
5698
- import { useMutation as useMutation39 } from "@tanstack/react-query";
5725
+ import { useMutation as useMutation40 } from "@tanstack/react-query";
5699
5726
  var useVerify2FA = () => {
5700
- return useMutation39({
5727
+ return useMutation40({
5701
5728
  mutationFn: ({
5702
5729
  method,
5703
5730
  with_context,
@@ -5718,9 +5745,9 @@ var useVerify2FA = () => {
5718
5745
  var use_verify_2FA_default = useVerify2FA;
5719
5746
 
5720
5747
  // src/hooks/view/uset-get-2FA-method.ts
5721
- import { useMutation as useMutation40 } from "@tanstack/react-query";
5748
+ import { useMutation as useMutation41 } from "@tanstack/react-query";
5722
5749
  var useGet2FAMethods = () => {
5723
- return useMutation40({
5750
+ return useMutation41({
5724
5751
  mutationFn: ({
5725
5752
  method,
5726
5753
  with_context
@@ -5735,9 +5762,9 @@ var useGet2FAMethods = () => {
5735
5762
  var uset_get_2FA_method_default = useGet2FAMethods;
5736
5763
 
5737
5764
  // src/hooks/view/use-get-fields-view-security.ts
5738
- import { useMutation as useMutation41 } from "@tanstack/react-query";
5765
+ import { useMutation as useMutation42 } from "@tanstack/react-query";
5739
5766
  var useGetFieldsViewSecurity = () => {
5740
- return useMutation41({
5767
+ return useMutation42({
5741
5768
  mutationFn: ({
5742
5769
  method,
5743
5770
  token,
@@ -5754,9 +5781,9 @@ var useGetFieldsViewSecurity = () => {
5754
5781
  var use_get_fields_view_security_default = useGetFieldsViewSecurity;
5755
5782
 
5756
5783
  // src/hooks/view/use-grant-access.ts
5757
- import { useMutation as useMutation42 } from "@tanstack/react-query";
5784
+ import { useMutation as useMutation43 } from "@tanstack/react-query";
5758
5785
  var useGrantAccess = () => {
5759
- return useMutation42({
5786
+ return useMutation43({
5760
5787
  mutationFn: ({
5761
5788
  redirect_uri,
5762
5789
  state,
@@ -5775,9 +5802,9 @@ var useGrantAccess = () => {
5775
5802
  var use_grant_access_default = useGrantAccess;
5776
5803
 
5777
5804
  // src/hooks/view/use-remove-totp-setup.ts
5778
- import { useMutation as useMutation43 } from "@tanstack/react-query";
5805
+ import { useMutation as useMutation44 } from "@tanstack/react-query";
5779
5806
  var useRemoveTotpSetup = () => {
5780
- return useMutation43({
5807
+ return useMutation44({
5781
5808
  mutationFn: ({ method, token }) => {
5782
5809
  return view_service_default.removeTotpSetUp({
5783
5810
  method,
@@ -5789,9 +5816,9 @@ var useRemoveTotpSetup = () => {
5789
5816
  var use_remove_totp_setup_default = useRemoveTotpSetup;
5790
5817
 
5791
5818
  // src/hooks/view/use-request-setup-totp.ts
5792
- import { useMutation as useMutation44 } from "@tanstack/react-query";
5819
+ import { useMutation as useMutation45 } from "@tanstack/react-query";
5793
5820
  var useRequestSetupTotp = () => {
5794
- return useMutation44({
5821
+ return useMutation45({
5795
5822
  mutationFn: ({ method, token }) => {
5796
5823
  return view_service_default.requestSetupTotp({
5797
5824
  method,
@@ -5803,9 +5830,9 @@ var useRequestSetupTotp = () => {
5803
5830
  var use_request_setup_totp_default = useRequestSetupTotp;
5804
5831
 
5805
5832
  // src/hooks/view/use-settings-web-read-2fa.ts
5806
- import { useMutation as useMutation45 } from "@tanstack/react-query";
5833
+ import { useMutation as useMutation46 } from "@tanstack/react-query";
5807
5834
  var useSettingsWebRead2fa = () => {
5808
- return useMutation45({
5835
+ return useMutation46({
5809
5836
  mutationFn: ({
5810
5837
  method,
5811
5838
  token,
@@ -5824,9 +5851,9 @@ var useSettingsWebRead2fa = () => {
5824
5851
  var use_settings_web_read_2fa_default = useSettingsWebRead2fa;
5825
5852
 
5826
5853
  // src/hooks/view/use-verify-totp.ts
5827
- import { useMutation as useMutation46 } from "@tanstack/react-query";
5854
+ import { useMutation as useMutation47 } from "@tanstack/react-query";
5828
5855
  var useVerifyTotp = () => {
5829
- return useMutation46({
5856
+ return useMutation47({
5830
5857
  mutationFn: ({
5831
5858
  method,
5832
5859
  action_token,
@@ -5908,6 +5935,7 @@ export {
5908
5935
  use_upload_file_default as useUploadFile,
5909
5936
  use_upload_id_file_default as useUploadIdFile,
5910
5937
  use_upload_image_default as useUploadImage,
5938
+ use_validate_action_token_default as useValidateActionToken,
5911
5939
  use_verify_2FA_default as useVerify2FA,
5912
5940
  use_verify_totp_default as useVerifyTotp
5913
5941
  };