@fctc/interface-logic 4.5.0 → 4.5.2

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/services.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  // src/services/action-service/index.ts
2
- import { useCallback as useCallback35 } from "react";
2
+ import { useCallback as useCallback40 } from "react";
3
3
 
4
4
  // src/constants/api/uri-constant.ts
5
5
  var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
@@ -4360,6 +4360,191 @@ var completeCurrentStageService = (env) => {
4360
4360
  };
4361
4361
  };
4362
4362
 
4363
+ // src/services/pos-service/supabase/add-floor.ts
4364
+ import { useCallback as useCallback33 } from "react";
4365
+ var addFloorSupabaseService = () => {
4366
+ const supabase = useSupabaseOptional();
4367
+ const addFloorSupabase = useCallback33(
4368
+ async (values) => {
4369
+ if (!supabase) {
4370
+ console.error("Supabase client not initialized");
4371
+ return null;
4372
+ }
4373
+ try {
4374
+ const { data, error } = await supabase.from("restaurant_floors" /* RESTAURANT_FLOORS */).insert({
4375
+ name: values.name,
4376
+ sequence: values.sequence ?? 1,
4377
+ pos_config_ids: values.pos_config_ids ?? [],
4378
+ table_ids: values.table_ids ?? []
4379
+ }).select("id, name").single();
4380
+ if (error) {
4381
+ console.error("Error adding floor:", error);
4382
+ return null;
4383
+ }
4384
+ return [[data.id, data.name]];
4385
+ } catch (error) {
4386
+ console.error("Error adding floor:", error);
4387
+ return null;
4388
+ }
4389
+ },
4390
+ [supabase]
4391
+ );
4392
+ return {
4393
+ addFloorSupabase
4394
+ };
4395
+ };
4396
+
4397
+ // src/services/pos-service/supabase/add-table.ts
4398
+ import { useCallback as useCallback34 } from "react";
4399
+ var addTableSupabaseService = () => {
4400
+ const supabase = useSupabaseOptional();
4401
+ const addTableSupabase = useCallback34(
4402
+ async (values) => {
4403
+ if (!supabase) {
4404
+ console.error("Supabase client not initialized");
4405
+ return null;
4406
+ }
4407
+ try {
4408
+ const { data, error } = await supabase.from("restaurant_tables" /* RESTAURANT_TABLES */).insert({
4409
+ floor_id: values.floor_id,
4410
+ table_number: values.table_number ?? 0,
4411
+ seats: values.seats ?? 1
4412
+ }).select("id, table_number").single();
4413
+ if (error) {
4414
+ console.error("Error adding table:", error);
4415
+ return null;
4416
+ }
4417
+ return [[data.id, data.table_number]];
4418
+ } catch (error) {
4419
+ console.error("Error adding table:", error);
4420
+ return null;
4421
+ }
4422
+ },
4423
+ [supabase]
4424
+ );
4425
+ return {
4426
+ addTableSupabase
4427
+ };
4428
+ };
4429
+
4430
+ // src/services/pos-service/supabase/update-floor.ts
4431
+ import { useCallback as useCallback35 } from "react";
4432
+ var updateFloorSupabaseService = () => {
4433
+ const supabase = useSupabaseOptional();
4434
+ const updateFloorSupabase = useCallback35(
4435
+ async (values) => {
4436
+ if (!supabase) {
4437
+ console.error("Supabase client not initialized");
4438
+ return false;
4439
+ }
4440
+ try {
4441
+ const { id, ...updateData } = values;
4442
+ const { error } = await supabase.from("restaurant_floors" /* RESTAURANT_FLOORS */).update(updateData).eq("id", id);
4443
+ if (error) {
4444
+ console.error("Error updating floor:", error);
4445
+ return false;
4446
+ }
4447
+ return true;
4448
+ } catch (error) {
4449
+ console.error("Error updating floor:", error);
4450
+ return false;
4451
+ }
4452
+ },
4453
+ [supabase]
4454
+ );
4455
+ return {
4456
+ updateFloorSupabase
4457
+ };
4458
+ };
4459
+
4460
+ // src/services/pos-service/supabase/update-table.ts
4461
+ import { useCallback as useCallback36 } from "react";
4462
+ var updateTableSupabaseService = () => {
4463
+ const supabase = useSupabaseOptional();
4464
+ const updateTableSupabase = useCallback36(
4465
+ async (values) => {
4466
+ if (!supabase) {
4467
+ console.error("Supabase client not initialized");
4468
+ return false;
4469
+ }
4470
+ try {
4471
+ const { id, ...updateData } = values;
4472
+ const { error } = await supabase.from("restaurant_tables" /* RESTAURANT_TABLES */).update(updateData).eq("id", id);
4473
+ if (error) {
4474
+ console.error("Error updating table:", error);
4475
+ return false;
4476
+ }
4477
+ return true;
4478
+ } catch (error) {
4479
+ console.error("Error updating table:", error);
4480
+ return false;
4481
+ }
4482
+ },
4483
+ [supabase]
4484
+ );
4485
+ return {
4486
+ updateTableSupabase
4487
+ };
4488
+ };
4489
+
4490
+ // src/services/pos-service/supabase/delete-floor.ts
4491
+ import { useCallback as useCallback37 } from "react";
4492
+ var deleteFloorSupabaseService = () => {
4493
+ const supabase = useSupabaseOptional();
4494
+ const deleteFloorSupabase = useCallback37(
4495
+ async (values) => {
4496
+ if (!supabase) {
4497
+ console.error("Supabase client not initialized");
4498
+ return false;
4499
+ }
4500
+ try {
4501
+ const { error } = await supabase.from("restaurant_floors" /* RESTAURANT_FLOORS */).delete().eq("id", values.id);
4502
+ if (error) {
4503
+ console.error("Error deleting floor:", error);
4504
+ return false;
4505
+ }
4506
+ return true;
4507
+ } catch (error) {
4508
+ console.error("Error deleting floor:", error);
4509
+ return false;
4510
+ }
4511
+ },
4512
+ [supabase]
4513
+ );
4514
+ return {
4515
+ deleteFloorSupabase
4516
+ };
4517
+ };
4518
+
4519
+ // src/services/pos-service/supabase/delete-table.ts
4520
+ import { useCallback as useCallback38 } from "react";
4521
+ var deleteTableSupabaseService = () => {
4522
+ const supabase = useSupabaseOptional();
4523
+ const deleteTableSupabase = useCallback38(
4524
+ async (values) => {
4525
+ if (!supabase) {
4526
+ console.error("Supabase client not initialized");
4527
+ return false;
4528
+ }
4529
+ try {
4530
+ const { error } = await supabase.from("restaurant_tables" /* RESTAURANT_TABLES */).delete().eq("id", values.id);
4531
+ if (error) {
4532
+ console.error("Error deleting table:", error);
4533
+ return false;
4534
+ }
4535
+ return true;
4536
+ } catch (error) {
4537
+ console.error("Error deleting table:", error);
4538
+ return false;
4539
+ }
4540
+ },
4541
+ [supabase]
4542
+ );
4543
+ return {
4544
+ deleteTableSupabase
4545
+ };
4546
+ };
4547
+
4363
4548
  // src/services/pos-service/index.ts
4364
4549
  var serviceFactories = [
4365
4550
  addEntityService,
@@ -4391,7 +4576,13 @@ var serviceFactories = [
4391
4576
  updateClosedSessionService,
4392
4577
  updateEntityService,
4393
4578
  updateOrderStatusService,
4394
- completeCurrentStageService
4579
+ completeCurrentStageService,
4580
+ addFloorSupabaseService,
4581
+ addTableSupabaseService,
4582
+ updateFloorSupabaseService,
4583
+ updateTableSupabaseService,
4584
+ deleteFloorSupabaseService,
4585
+ deleteTableSupabaseService
4395
4586
  ];
4396
4587
  var usePosService = () => {
4397
4588
  const { env } = useEnv();
@@ -4493,15 +4684,27 @@ import { useMutation as useMutation87 } from "@tanstack/react-query";
4493
4684
  // src/hooks/pos/supabase/use-add-floor.ts
4494
4685
  import { useMutation as useMutation88 } from "@tanstack/react-query";
4495
4686
 
4496
- // src/services/pos-service/supabase/add-floor.ts
4497
- import { useCallback as useCallback33 } from "react";
4498
-
4499
- // src/services/pos-service/supabase/add-table.ts
4500
- import { useCallback as useCallback34 } from "react";
4687
+ // src/services/pos-service/supabase/create-order.ts
4688
+ import { useCallback as useCallback39 } from "react";
4501
4689
 
4502
4690
  // src/hooks/pos/supabase/use-add-table.ts
4503
4691
  import { useMutation as useMutation89 } from "@tanstack/react-query";
4504
4692
 
4693
+ // src/hooks/pos/supabase/use-update-floor.ts
4694
+ import { useMutation as useMutation90 } from "@tanstack/react-query";
4695
+
4696
+ // src/hooks/pos/supabase/use-update-table.ts
4697
+ import { useMutation as useMutation91 } from "@tanstack/react-query";
4698
+
4699
+ // src/hooks/pos/supabase/use-delete-floor.ts
4700
+ import { useMutation as useMutation92 } from "@tanstack/react-query";
4701
+
4702
+ // src/hooks/pos/supabase/use-delete-table.ts
4703
+ import { useMutation as useMutation93 } from "@tanstack/react-query";
4704
+
4705
+ // src/hooks/pos/supabase/use-create-order.ts
4706
+ import { useMutation as useMutation94 } from "@tanstack/react-query";
4707
+
4505
4708
  // src/provider/service-provider.tsx
4506
4709
  import { jsx as jsx7 } from "react/jsx-runtime";
4507
4710
  var ServiceContext = createContext3(null);
@@ -4513,7 +4716,7 @@ import { Fragment as Fragment2, jsx as jsx8 } from "react/jsx-runtime";
4513
4716
  // src/services/action-service/index.ts
4514
4717
  function useActionService() {
4515
4718
  const { env } = useEnv();
4516
- const loadAction = useCallback35(
4719
+ const loadAction = useCallback40(
4517
4720
  async ({
4518
4721
  idAction,
4519
4722
  context,
@@ -4537,7 +4740,7 @@ function useActionService() {
4537
4740
  },
4538
4741
  [env]
4539
4742
  );
4540
- const callButton = useCallback35(
4743
+ const callButton = useCallback40(
4541
4744
  async ({
4542
4745
  model,
4543
4746
  ids = [],
@@ -4571,7 +4774,7 @@ function useActionService() {
4571
4774
  },
4572
4775
  [env]
4573
4776
  );
4574
- const removeRows = useCallback35(
4777
+ const removeRows = useCallback40(
4575
4778
  async ({
4576
4779
  model,
4577
4780
  ids,
@@ -4597,7 +4800,7 @@ function useActionService() {
4597
4800
  },
4598
4801
  [env]
4599
4802
  );
4600
- const duplicateRecord = useCallback35(
4803
+ const duplicateRecord = useCallback40(
4601
4804
  async ({
4602
4805
  model,
4603
4806
  id,
@@ -4623,7 +4826,7 @@ function useActionService() {
4623
4826
  },
4624
4827
  [env]
4625
4828
  );
4626
- const getPrintReportName = useCallback35(
4829
+ const getPrintReportName = useCallback40(
4627
4830
  async ({ id }) => {
4628
4831
  const jsonData = {
4629
4832
  model: "ir.actions.report",
@@ -4641,7 +4844,7 @@ function useActionService() {
4641
4844
  },
4642
4845
  [env]
4643
4846
  );
4644
- const print = useCallback35(
4847
+ const print = useCallback40(
4645
4848
  async ({ id, report, db }) => {
4646
4849
  const jsonData = {
4647
4850
  report,
@@ -4659,7 +4862,7 @@ function useActionService() {
4659
4862
  },
4660
4863
  [env]
4661
4864
  );
4662
- const runAction = useCallback35(
4865
+ const runAction = useCallback40(
4663
4866
  async ({
4664
4867
  idAction,
4665
4868
  context,
@@ -4686,7 +4889,7 @@ function useActionService() {
4686
4889
  },
4687
4890
  [env]
4688
4891
  );
4689
- const generateSerialNumber = useCallback35(
4892
+ const generateSerialNumber = useCallback40(
4690
4893
  async ({
4691
4894
  kwargs,
4692
4895
  context,
@@ -4724,11 +4927,11 @@ function useActionService() {
4724
4927
  }
4725
4928
 
4726
4929
  // src/services/auth-service/index.ts
4727
- import { useCallback as useCallback36 } from "react";
4930
+ import { useCallback as useCallback41 } from "react";
4728
4931
  function useAuthService() {
4729
4932
  const { env } = useEnv();
4730
4933
  const supabase = useSupabaseOptional();
4731
- const login = useCallback36(
4934
+ const login = useCallback41(
4732
4935
  async (body) => {
4733
4936
  const payload = Object.fromEntries(
4734
4937
  Object.entries({
@@ -4753,7 +4956,7 @@ function useAuthService() {
4753
4956
  },
4754
4957
  [env]
4755
4958
  );
4756
- const loginSupabase = useCallback36(
4959
+ const loginSupabase = useCallback41(
4757
4960
  async (body) => {
4758
4961
  if (!supabase) {
4759
4962
  return {
@@ -4769,7 +4972,7 @@ function useAuthService() {
4769
4972
  },
4770
4973
  [supabase]
4771
4974
  );
4772
- const forgotPassword = useCallback36(
4975
+ const forgotPassword = useCallback41(
4773
4976
  async (email) => {
4774
4977
  const bodyData = {
4775
4978
  login: email,
@@ -4783,7 +4986,7 @@ function useAuthService() {
4783
4986
  },
4784
4987
  [env]
4785
4988
  );
4786
- const forgotPasswordSSO = useCallback36(
4989
+ const forgotPasswordSSO = useCallback41(
4787
4990
  async ({
4788
4991
  email,
4789
4992
  with_context,
@@ -4806,7 +5009,7 @@ function useAuthService() {
4806
5009
  },
4807
5010
  [env]
4808
5011
  );
4809
- const resetPassword = useCallback36(
5012
+ const resetPassword = useCallback41(
4810
5013
  async (data, token) => {
4811
5014
  const bodyData = {
4812
5015
  token,
@@ -4821,7 +5024,7 @@ function useAuthService() {
4821
5024
  },
4822
5025
  [env]
4823
5026
  );
4824
- const resetPasswordSSO = useCallback36(
5027
+ const resetPasswordSSO = useCallback41(
4825
5028
  async ({
4826
5029
  method,
4827
5030
  password,
@@ -4844,7 +5047,7 @@ function useAuthService() {
4844
5047
  },
4845
5048
  [env]
4846
5049
  );
4847
- const updatePassword = useCallback36(
5050
+ const updatePassword = useCallback41(
4848
5051
  async (data, token) => {
4849
5052
  const bodyData = {
4850
5053
  token,
@@ -4859,7 +5062,7 @@ function useAuthService() {
4859
5062
  },
4860
5063
  [env]
4861
5064
  );
4862
- const isValidToken = useCallback36(
5065
+ const isValidToken = useCallback41(
4863
5066
  async (token) => {
4864
5067
  const bodyData = {
4865
5068
  token
@@ -4872,7 +5075,7 @@ function useAuthService() {
4872
5075
  },
4873
5076
  [env]
4874
5077
  );
4875
- const isValidActionToken = useCallback36(
5078
+ const isValidActionToken = useCallback41(
4876
5079
  async (actionToken) => {
4877
5080
  const bodyData = {};
4878
5081
  return env?.requests?.post("/action-token/validate" /* VALIDATE_ACTION_TOKEN */, bodyData, {
@@ -4885,7 +5088,7 @@ function useAuthService() {
4885
5088
  },
4886
5089
  [env]
4887
5090
  );
4888
- const loginSocial = useCallback36(
5091
+ const loginSocial = useCallback41(
4889
5092
  async ({
4890
5093
  db,
4891
5094
  state,
@@ -4903,13 +5106,13 @@ function useAuthService() {
4903
5106
  },
4904
5107
  [env]
4905
5108
  );
4906
- const getProviders = useCallback36(
5109
+ const getProviders = useCallback41(
4907
5110
  async (db) => {
4908
5111
  return env?.requests?.get("/oauth/providers", { params: { db } });
4909
5112
  },
4910
5113
  [env]
4911
5114
  );
4912
- const getAccessByCode = useCallback36(
5115
+ const getAccessByCode = useCallback41(
4913
5116
  async (code) => {
4914
5117
  const data = new URLSearchParams();
4915
5118
  data.append("code", code);
@@ -4929,7 +5132,7 @@ function useAuthService() {
4929
5132
  },
4930
5133
  [env]
4931
5134
  );
4932
- const logout = useCallback36(
5135
+ const logout = useCallback41(
4933
5136
  async (service) => {
4934
5137
  return env?.requests?.post(
4935
5138
  "/logout" /* LOGOUT */,
@@ -4946,7 +5149,7 @@ function useAuthService() {
4946
5149
  },
4947
5150
  [env]
4948
5151
  );
4949
- const getTenantMapping = useCallback36(
5152
+ const getTenantMapping = useCallback41(
4950
5153
  async ({ shortName, service }) => {
4951
5154
  const bodyData = {
4952
5155
  short_name: shortName
@@ -4964,7 +5167,7 @@ function useAuthService() {
4964
5167
  },
4965
5168
  [env]
4966
5169
  );
4967
- const getToken = useCallback36(
5170
+ const getToken = useCallback41(
4968
5171
  async ({
4969
5172
  phone,
4970
5173
  name,
@@ -5009,10 +5212,10 @@ function useAuthService() {
5009
5212
  }
5010
5213
 
5011
5214
  // src/services/company-service/index.ts
5012
- import { useCallback as useCallback37 } from "react";
5215
+ import { useCallback as useCallback42 } from "react";
5013
5216
  function useCompanyService() {
5014
5217
  const { env } = useEnv();
5015
- const getCurrentCompany = useCallback37(
5218
+ const getCurrentCompany = useCallback42(
5016
5219
  async (service, extraHeaders) => {
5017
5220
  return await env.requests.get(
5018
5221
  "/company" /* COMPANY_PATH */,
@@ -5029,7 +5232,7 @@ function useCompanyService() {
5029
5232
  },
5030
5233
  [env]
5031
5234
  );
5032
- const getInfoCompany = useCallback37(
5235
+ const getInfoCompany = useCallback42(
5033
5236
  async (id, service) => {
5034
5237
  const jsonData = {
5035
5238
  ids: [id],
@@ -5065,10 +5268,10 @@ function useCompanyService() {
5065
5268
  }
5066
5269
 
5067
5270
  // src/services/excel-service/index.ts
5068
- import { useCallback as useCallback38 } from "react";
5271
+ import { useCallback as useCallback43 } from "react";
5069
5272
  function useExcelService() {
5070
5273
  const { env } = useEnv();
5071
- const uploadFileExcel = useCallback38(
5274
+ const uploadFileExcel = useCallback43(
5072
5275
  async ({
5073
5276
  formData,
5074
5277
  service,
@@ -5085,7 +5288,7 @@ function useExcelService() {
5085
5288
  },
5086
5289
  [env]
5087
5290
  );
5088
- const uploadIdFile = useCallback38(
5291
+ const uploadIdFile = useCallback43(
5089
5292
  async ({
5090
5293
  formData,
5091
5294
  service,
@@ -5102,7 +5305,7 @@ function useExcelService() {
5102
5305
  },
5103
5306
  [env]
5104
5307
  );
5105
- const parsePreview = useCallback38(
5308
+ const parsePreview = useCallback43(
5106
5309
  async ({
5107
5310
  id,
5108
5311
  selectedSheet,
@@ -5151,7 +5354,7 @@ function useExcelService() {
5151
5354
  },
5152
5355
  [env]
5153
5356
  );
5154
- const executeImport = useCallback38(
5357
+ const executeImport = useCallback43(
5155
5358
  async ({
5156
5359
  columns,
5157
5360
  fields,
@@ -5185,7 +5388,7 @@ function useExcelService() {
5185
5388
  },
5186
5389
  [env]
5187
5390
  );
5188
- const getFileExcel = useCallback38(
5391
+ const getFileExcel = useCallback43(
5189
5392
  async ({
5190
5393
  model,
5191
5394
  service,
@@ -5209,7 +5412,7 @@ function useExcelService() {
5209
5412
  },
5210
5413
  [env]
5211
5414
  );
5212
- const getFieldExport = useCallback38(
5415
+ const getFieldExport = useCallback43(
5213
5416
  async ({
5214
5417
  ids,
5215
5418
  model,
@@ -5249,7 +5452,7 @@ function useExcelService() {
5249
5452
  },
5250
5453
  [env]
5251
5454
  );
5252
- const exportExcel = useCallback38(
5455
+ const exportExcel = useCallback43(
5253
5456
  async ({
5254
5457
  model,
5255
5458
  domain,
@@ -5297,10 +5500,10 @@ function useExcelService() {
5297
5500
  }
5298
5501
 
5299
5502
  // src/services/form-service/index.ts
5300
- import { useCallback as useCallback39 } from "react";
5503
+ import { useCallback as useCallback44 } from "react";
5301
5504
  function useFormService() {
5302
5505
  const { env } = useEnv();
5303
- const getComment = useCallback39(
5506
+ const getComment = useCallback44(
5304
5507
  async ({ data }) => {
5305
5508
  const jsonData = {
5306
5509
  thread_id: data.thread_id,
@@ -5318,7 +5521,7 @@ function useFormService() {
5318
5521
  },
5319
5522
  [env]
5320
5523
  );
5321
- const getThreadData = useCallback39(
5524
+ const getThreadData = useCallback44(
5322
5525
  async ({
5323
5526
  data,
5324
5527
  xNode,
@@ -5345,7 +5548,7 @@ function useFormService() {
5345
5548
  },
5346
5549
  [env]
5347
5550
  );
5348
- const getThreadMessages = useCallback39(
5551
+ const getThreadMessages = useCallback44(
5349
5552
  async ({
5350
5553
  data,
5351
5554
  xNode,
@@ -5371,7 +5574,7 @@ function useFormService() {
5371
5574
  },
5372
5575
  [env]
5373
5576
  );
5374
- const sentComment = useCallback39(
5577
+ const sentComment = useCallback44(
5375
5578
  async ({ data }) => {
5376
5579
  const jsonData = {
5377
5580
  context: {
@@ -5399,7 +5602,7 @@ function useFormService() {
5399
5602
  },
5400
5603
  [env]
5401
5604
  );
5402
- const deleteComment = useCallback39(
5605
+ const deleteComment = useCallback44(
5403
5606
  async ({ data }) => {
5404
5607
  const jsonData = {
5405
5608
  attachment_ids: [],
@@ -5415,7 +5618,7 @@ function useFormService() {
5415
5618
  },
5416
5619
  [env]
5417
5620
  );
5418
- const getImage = useCallback39(
5621
+ const getImage = useCallback44(
5419
5622
  async ({ data }) => {
5420
5623
  return env.requests.get(
5421
5624
  `${"/web/image" /* IMAGE_PATH */}?filename=${data.filename}&unique=${data.checksum}&width=1920&height=300`,
@@ -5428,7 +5631,7 @@ function useFormService() {
5428
5631
  },
5429
5632
  [env]
5430
5633
  );
5431
- const uploadImage = useCallback39(
5634
+ const uploadImage = useCallback44(
5432
5635
  async ({
5433
5636
  formData,
5434
5637
  service,
@@ -5447,7 +5650,7 @@ function useFormService() {
5447
5650
  },
5448
5651
  [env]
5449
5652
  );
5450
- const uploadFile = useCallback39(
5653
+ const uploadFile = useCallback44(
5451
5654
  async ({
5452
5655
  formData,
5453
5656
  service,
@@ -5467,7 +5670,7 @@ function useFormService() {
5467
5670
  },
5468
5671
  [env]
5469
5672
  );
5470
- const getFormView = useCallback39(
5673
+ const getFormView = useCallback44(
5471
5674
  async ({ data }) => {
5472
5675
  const jsonData = {
5473
5676
  model: data.model,
@@ -5483,7 +5686,7 @@ function useFormService() {
5483
5686
  },
5484
5687
  [env]
5485
5688
  );
5486
- const changeStatus = useCallback39(
5689
+ const changeStatus = useCallback44(
5487
5690
  async ({ data }) => {
5488
5691
  const vals = {
5489
5692
  [data.name]: data.stage_id
@@ -5512,7 +5715,7 @@ function useFormService() {
5512
5715
  },
5513
5716
  [env]
5514
5717
  );
5515
- const getExternalTab = useCallback39(
5718
+ const getExternalTab = useCallback44(
5516
5719
  async ({ method, context, service, xNode }) => {
5517
5720
  return env?.requests?.post(
5518
5721
  "/call" /* CALL_PATH */,
@@ -5547,10 +5750,10 @@ function useFormService() {
5547
5750
  }
5548
5751
 
5549
5752
  // src/services/kanban-service/index.ts
5550
- import { useCallback as useCallback40 } from "react";
5753
+ import { useCallback as useCallback45 } from "react";
5551
5754
  function useKanbanService() {
5552
5755
  const { env } = useEnv();
5553
- const getGroups = useCallback40(
5756
+ const getGroups = useCallback45(
5554
5757
  async ({ model, width_context }) => {
5555
5758
  const jsonData = {
5556
5759
  model,
@@ -5570,7 +5773,7 @@ function useKanbanService() {
5570
5773
  },
5571
5774
  [env]
5572
5775
  );
5573
- const getProgressBar = useCallback40(
5776
+ const getProgressBar = useCallback45(
5574
5777
  async ({ field, color, model, width_context }) => {
5575
5778
  const jsonData = {
5576
5779
  model,
@@ -5600,10 +5803,10 @@ function useKanbanService() {
5600
5803
  }
5601
5804
 
5602
5805
  // src/services/model-service/index.ts
5603
- import { useCallback as useCallback41 } from "react";
5806
+ import { useCallback as useCallback46 } from "react";
5604
5807
  function useModelService() {
5605
5808
  const { env } = useEnv();
5606
- const getListMyBankAccount = useCallback41(
5809
+ const getListMyBankAccount = useCallback46(
5607
5810
  async ({
5608
5811
  domain,
5609
5812
  spectification,
@@ -5627,7 +5830,7 @@ function useModelService() {
5627
5830
  },
5628
5831
  [env]
5629
5832
  );
5630
- const getCurrency = useCallback41(async () => {
5833
+ const getCurrency = useCallback46(async () => {
5631
5834
  const jsonData = {
5632
5835
  model: "res.currency",
5633
5836
  method: "web_search_read",
@@ -5647,7 +5850,7 @@ function useModelService() {
5647
5850
  }
5648
5851
  });
5649
5852
  }, [env]);
5650
- const getConversionRate = useCallback41(async () => {
5853
+ const getConversionRate = useCallback46(async () => {
5651
5854
  const jsonData = {
5652
5855
  model: "res.currency",
5653
5856
  method: "web_search_read",
@@ -5673,7 +5876,7 @@ function useModelService() {
5673
5876
  }
5674
5877
  });
5675
5878
  }, [env]);
5676
- const getAll = useCallback41(
5879
+ const getAll = useCallback46(
5677
5880
  async ({
5678
5881
  data,
5679
5882
  service,
@@ -5715,7 +5918,7 @@ function useModelService() {
5715
5918
  },
5716
5919
  [env]
5717
5920
  );
5718
- const getListCalendar = useCallback41(
5921
+ const getListCalendar = useCallback46(
5719
5922
  async ({ data }) => {
5720
5923
  const jsonReadGroup = data.type == "calendar" ? data?.fields : data.fields && data.fields.length > 0 && data.groupby && data.groupby.length > 0 && data.groupby[0] ? {
5721
5924
  fields: data.fields,
@@ -5746,7 +5949,7 @@ function useModelService() {
5746
5949
  },
5747
5950
  [env]
5748
5951
  );
5749
- const getList = useCallback41(
5952
+ const getList = useCallback46(
5750
5953
  async ({
5751
5954
  model,
5752
5955
  ids = [],
@@ -5778,7 +5981,7 @@ function useModelService() {
5778
5981
  },
5779
5982
  [env]
5780
5983
  );
5781
- const getDetail = useCallback41(
5984
+ const getDetail = useCallback46(
5782
5985
  async ({
5783
5986
  ids = [],
5784
5987
  model,
@@ -5810,7 +6013,7 @@ function useModelService() {
5810
6013
  },
5811
6014
  [env]
5812
6015
  );
5813
- const save = useCallback41(
6016
+ const save = useCallback46(
5814
6017
  async ({
5815
6018
  model,
5816
6019
  ids = [],
@@ -5845,7 +6048,7 @@ function useModelService() {
5845
6048
  },
5846
6049
  [env]
5847
6050
  );
5848
- const deleteApi = useCallback41(
6051
+ const deleteApi = useCallback46(
5849
6052
  async ({ ids = [], model, service }) => {
5850
6053
  const jsonData = {
5851
6054
  model,
@@ -5865,7 +6068,7 @@ function useModelService() {
5865
6068
  },
5866
6069
  [env]
5867
6070
  );
5868
- const onChange = useCallback41(
6071
+ const onChange = useCallback46(
5869
6072
  async ({
5870
6073
  ids = [],
5871
6074
  model,
@@ -5901,7 +6104,7 @@ function useModelService() {
5901
6104
  },
5902
6105
  [env]
5903
6106
  );
5904
- const getListFieldsOnchange = useCallback41(
6107
+ const getListFieldsOnchange = useCallback46(
5905
6108
  async ({
5906
6109
  model,
5907
6110
  service,
@@ -5925,7 +6128,7 @@ function useModelService() {
5925
6128
  },
5926
6129
  [env]
5927
6130
  );
5928
- const parseORMOdoo = useCallback41((data) => {
6131
+ const parseORMOdoo = useCallback46((data) => {
5929
6132
  for (const key in data) {
5930
6133
  if (key === "display_name") {
5931
6134
  delete data[key];
@@ -5936,7 +6139,7 @@ function useModelService() {
5936
6139
  }
5937
6140
  return { ...data };
5938
6141
  }, []);
5939
- const toDataJS = useCallback41(
6142
+ const toDataJS = useCallback46(
5940
6143
  (data, viewData, model) => {
5941
6144
  for (const key in data) {
5942
6145
  if (data[key] === false) {
@@ -5994,10 +6197,10 @@ function useModelService() {
5994
6197
  }
5995
6198
 
5996
6199
  // src/services/user-service/index.ts
5997
- import { useCallback as useCallback42 } from "react";
6200
+ import { useCallback as useCallback47 } from "react";
5998
6201
  function useUserService() {
5999
6202
  const { env } = useEnv();
6000
- const getProfile = useCallback42(
6203
+ const getProfile = useCallback47(
6001
6204
  async (service, path, extraHeaders) => {
6002
6205
  return env?.requests?.get(
6003
6206
  path || "/userinfo" /* PROFILE_PATH */,
@@ -6014,7 +6217,7 @@ function useUserService() {
6014
6217
  },
6015
6218
  [env]
6016
6219
  );
6017
- const getUser = useCallback42(
6220
+ const getUser = useCallback47(
6018
6221
  async ({ context, id }) => {
6019
6222
  const jsonData = {
6020
6223
  model: "res.users",
@@ -6052,7 +6255,7 @@ function useUserService() {
6052
6255
  },
6053
6256
  [env]
6054
6257
  );
6055
- const switchUserLocale = useCallback42(
6258
+ const switchUserLocale = useCallback47(
6056
6259
  async ({ id, values, service }) => {
6057
6260
  const jsonData = {
6058
6261
  model: "res.users",
@@ -6080,10 +6283,10 @@ function useUserService() {
6080
6283
  }
6081
6284
 
6082
6285
  // src/services/view-service/index.ts
6083
- import { useCallback as useCallback43 } from "react";
6286
+ import { useCallback as useCallback48 } from "react";
6084
6287
  function useViewService() {
6085
6288
  const { env } = useEnv();
6086
- const getView = useCallback43(
6289
+ const getView = useCallback48(
6087
6290
  async ({
6088
6291
  model,
6089
6292
  views,
@@ -6123,7 +6326,7 @@ function useViewService() {
6123
6326
  },
6124
6327
  [env]
6125
6328
  );
6126
- const getMenu = useCallback43(
6329
+ const getMenu = useCallback48(
6127
6330
  async (context, specification, domain, service) => {
6128
6331
  const jsonData = {
6129
6332
  model: "ir.ui.menu" /* MENU */,
@@ -6154,7 +6357,7 @@ function useViewService() {
6154
6357
  },
6155
6358
  [env]
6156
6359
  );
6157
- const getActionDetail = useCallback43(
6360
+ const getActionDetail = useCallback48(
6158
6361
  async (aid, context) => {
6159
6362
  const jsonData = {
6160
6363
  model: "ir.actions.act_window" /* WINDOW_ACTION */,
@@ -6184,7 +6387,7 @@ function useViewService() {
6184
6387
  },
6185
6388
  [env]
6186
6389
  );
6187
- const getResequence = useCallback43(
6390
+ const getResequence = useCallback48(
6188
6391
  async ({
6189
6392
  model,
6190
6393
  ids,
@@ -6214,7 +6417,7 @@ function useViewService() {
6214
6417
  },
6215
6418
  [env]
6216
6419
  );
6217
- const getSelectionItem = useCallback43(
6420
+ const getSelectionItem = useCallback48(
6218
6421
  async ({
6219
6422
  data,
6220
6423
  service,
@@ -6251,7 +6454,7 @@ function useViewService() {
6251
6454
  },
6252
6455
  [env]
6253
6456
  );
6254
- const loadMessages = useCallback43(async () => {
6457
+ const loadMessages = useCallback48(async () => {
6255
6458
  return env.requests.post(
6256
6459
  "/load_message_failures" /* LOAD_MESSAGE */,
6257
6460
  {},
@@ -6262,14 +6465,14 @@ function useViewService() {
6262
6465
  }
6263
6466
  );
6264
6467
  }, [env]);
6265
- const getVersion = useCallback43(async () => {
6468
+ const getVersion = useCallback48(async () => {
6266
6469
  return env?.requests?.get("", {
6267
6470
  headers: {
6268
6471
  "Content-Type": "application/json"
6269
6472
  }
6270
6473
  });
6271
6474
  }, [env]);
6272
- const grantAccess = useCallback43(
6475
+ const grantAccess = useCallback48(
6273
6476
  async ({
6274
6477
  redirect_uri,
6275
6478
  state,
@@ -6296,7 +6499,7 @@ function useViewService() {
6296
6499
  },
6297
6500
  [env]
6298
6501
  );
6299
- const removeTotpSetUp = useCallback43(
6502
+ const removeTotpSetUp = useCallback48(
6300
6503
  async ({ method, token }) => {
6301
6504
  const jsonData = {
6302
6505
  method,
@@ -6317,7 +6520,7 @@ function useViewService() {
6317
6520
  },
6318
6521
  [env]
6319
6522
  );
6320
- const requestSetupTotp = useCallback43(
6523
+ const requestSetupTotp = useCallback48(
6321
6524
  async ({ method, token }) => {
6322
6525
  const jsonData = {
6323
6526
  method,
@@ -6336,7 +6539,7 @@ function useViewService() {
6336
6539
  },
6337
6540
  [env]
6338
6541
  );
6339
- const settingsWebRead2fa = useCallback43(
6542
+ const settingsWebRead2fa = useCallback48(
6340
6543
  async ({
6341
6544
  method,
6342
6545
  model,
@@ -6364,7 +6567,7 @@ function useViewService() {
6364
6567
  },
6365
6568
  [env]
6366
6569
  );
6367
- const signInSSO = useCallback43(
6570
+ const signInSSO = useCallback48(
6368
6571
  async ({
6369
6572
  redirect_uri,
6370
6573
  state,
@@ -6396,7 +6599,7 @@ function useViewService() {
6396
6599
  },
6397
6600
  [env]
6398
6601
  );
6399
- const verify2FA = useCallback43(
6602
+ const verify2FA = useCallback48(
6400
6603
  ({
6401
6604
  method,
6402
6605
  with_context,
@@ -6429,7 +6632,7 @@ function useViewService() {
6429
6632
  },
6430
6633
  [env]
6431
6634
  );
6432
- const get2FAMethods = useCallback43(
6635
+ const get2FAMethods = useCallback48(
6433
6636
  ({ method, with_context }) => {
6434
6637
  const jsonData = {
6435
6638
  method,
@@ -6448,7 +6651,7 @@ function useViewService() {
6448
6651
  },
6449
6652
  [env]
6450
6653
  );
6451
- const verifyTotp = useCallback43(
6654
+ const verifyTotp = useCallback48(
6452
6655
  ({
6453
6656
  method,
6454
6657
  action_token,
@@ -6473,7 +6676,7 @@ function useViewService() {
6473
6676
  },
6474
6677
  [env]
6475
6678
  );
6476
- const getNotifications = useCallback43(
6679
+ const getNotifications = useCallback48(
6477
6680
  async ({
6478
6681
  service,
6479
6682
  xNode,
@@ -6493,7 +6696,7 @@ function useViewService() {
6493
6696
  },
6494
6697
  [env]
6495
6698
  );
6496
- const getCountry = useCallback43(
6699
+ const getCountry = useCallback48(
6497
6700
  async ({
6498
6701
  service,
6499
6702
  xNode,
@@ -6520,7 +6723,7 @@ function useViewService() {
6520
6723
  },
6521
6724
  [env]
6522
6725
  );
6523
- const getCity = useCallback43(
6726
+ const getCity = useCallback48(
6524
6727
  async ({
6525
6728
  service,
6526
6729
  xNode,
@@ -6547,7 +6750,7 @@ function useViewService() {
6547
6750
  },
6548
6751
  [env]
6549
6752
  );
6550
- const getWard = useCallback43(
6753
+ const getWard = useCallback48(
6551
6754
  async ({
6552
6755
  service,
6553
6756
  xNode,
@@ -6572,7 +6775,7 @@ function useViewService() {
6572
6775
  },
6573
6776
  [env]
6574
6777
  );
6575
- const getPartnerTitle = useCallback43(
6778
+ const getPartnerTitle = useCallback48(
6576
6779
  async ({
6577
6780
  service,
6578
6781
  xNode,
@@ -6624,10 +6827,10 @@ function useViewService() {
6624
6827
  }
6625
6828
 
6626
6829
  // src/services/dashboard-service/index.ts
6627
- import { useCallback as useCallback44 } from "react";
6830
+ import { useCallback as useCallback49 } from "react";
6628
6831
  function useDashboardService() {
6629
6832
  const { env } = useEnv();
6630
- const readGroup = useCallback44(
6833
+ const readGroup = useCallback49(
6631
6834
  async ({
6632
6835
  service,
6633
6836
  xNode,
@@ -6644,7 +6847,7 @@ function useDashboardService() {
6644
6847
  },
6645
6848
  [env]
6646
6849
  );
6647
- const getDataChart = useCallback44(
6850
+ const getDataChart = useCallback49(
6648
6851
  async ({
6649
6852
  service,
6650
6853
  xNode,