@fctc/interface-logic 5.0.7 → 5.0.9

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/index.mjs CHANGED
@@ -37,6 +37,9 @@ var MethodConstants = /* @__PURE__ */ ((MethodConstants2) => {
37
37
  MethodConstants2["CREATE_E_INVOICE"] = "create_e_invoice";
38
38
  MethodConstants2["GET_DATA_SELECT"] = "get_data_select";
39
39
  MethodConstants2["COMPLETE_CURRENT_STAGE"] = "complete_current_stage";
40
+ MethodConstants2["ACTION_APPLY_VOUCHER"] = "action_apply_voucher";
41
+ MethodConstants2["ACTION_REMOVE_VOUCHER"] = "action_remove_voucher";
42
+ MethodConstants2["SYNC_FROM_UI"] = "sync_from_ui";
40
43
  return MethodConstants2;
41
44
  })(MethodConstants || {});
42
45
 
@@ -88,6 +91,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
88
91
  UriConstants2["PUBLIC_USER_INFO"] = "/public/user/info";
89
92
  UriConstants2["FUNCTIONAL_MODULES"] = "/functional-modules";
90
93
  UriConstants2["ACTION_SERVER_HOME"] = "/action_server_home";
94
+ UriConstants2["APP_AUTHENTICATE"] = "/app/authenticate";
91
95
  return UriConstants2;
92
96
  })(UriConstants || {});
93
97
 
@@ -4744,6 +4748,10 @@ var ServiceProvider = ({
4744
4748
  useGetCountry: use_get_country_default,
4745
4749
  useGetPartnerTitle: use_get_partner_title_default,
4746
4750
  useCompleteCurrentStage: use_complete_current_stage_default,
4751
+ useAppAuthenticate: use_app_authenticate_default,
4752
+ useApplyVoucher: use_apply_voucher_default,
4753
+ useRemoveVoucher: use_remove_voucher_default,
4754
+ useSyncFromUi: use_sync_from_ui_default,
4747
4755
  useLoginTenantUser: use_login_tenant_user_default,
4748
4756
  useAddFloor: use_add_floor_default,
4749
4757
  useAddTable: use_add_table_default,
@@ -4776,6 +4784,7 @@ var ServiceProvider = ({
4776
4784
  useDeleteCategory: use_delete_category_default,
4777
4785
  useUpdateProduct: use_update_product_default,
4778
4786
  useDeleteProduct: use_delete_product_default,
4787
+ useTogglePosRestaurant: use_toggle_pos_restaurant_default,
4779
4788
  useActionServerHome: use_action_server_home_default
4780
4789
  };
4781
4790
  return /* @__PURE__ */ jsx6(ServiceContext.Provider, { value: services, children });
@@ -8292,11 +8301,143 @@ var getFunctionalModulesService = (env2) => {
8292
8301
  };
8293
8302
  };
8294
8303
 
8295
- // src/services/pos-service/supabase/add-floor.ts
8304
+ // src/services/pos-service/app-authenticate.ts
8296
8305
  import { useCallback as useCallback43 } from "react";
8306
+ var appAuthenticateService = (env2) => {
8307
+ const appAuthenticate = useCallback43(
8308
+ ({
8309
+ xNode,
8310
+ service,
8311
+ appKey,
8312
+ activationCode,
8313
+ clientId,
8314
+ clientSecret
8315
+ }) => {
8316
+ const jsonData = {
8317
+ app_key: appKey,
8318
+ activation_code: activationCode,
8319
+ client_id: clientId,
8320
+ client_secret: clientSecret
8321
+ };
8322
+ return env2?.requests.post(
8323
+ "/app/authenticate" /* APP_AUTHENTICATE */,
8324
+ jsonData,
8325
+ {
8326
+ headers: {
8327
+ "Content-Type": "application/json",
8328
+ ...xNode ? { "X-Node": xNode } : {}
8329
+ }
8330
+ },
8331
+ service
8332
+ );
8333
+ },
8334
+ [env2]
8335
+ );
8336
+ return {
8337
+ appAuthenticate
8338
+ };
8339
+ };
8340
+
8341
+ // src/services/pos-service/apply-voucher.ts
8342
+ import { useCallback as useCallback44 } from "react";
8343
+ var applyVoucherService = (env2) => {
8344
+ const applyVoucher = useCallback44(
8345
+ ({ xNode, service, ids, voucherCode }) => {
8346
+ const jsonData = {
8347
+ model: "pos.order" /* POS_ORDER */,
8348
+ method: "action_apply_voucher" /* ACTION_APPLY_VOUCHER */,
8349
+ ids,
8350
+ kwargs: {
8351
+ voucher_code: voucherCode
8352
+ }
8353
+ };
8354
+ return env2?.requests.post(
8355
+ "/call" /* CALL_PATH */,
8356
+ jsonData,
8357
+ {
8358
+ headers: {
8359
+ "Content-Type": "application/json",
8360
+ ...xNode ? { "X-Node": xNode } : {}
8361
+ }
8362
+ },
8363
+ service
8364
+ );
8365
+ },
8366
+ [env2]
8367
+ );
8368
+ return {
8369
+ applyVoucher
8370
+ };
8371
+ };
8372
+
8373
+ // src/services/pos-service/remove-voucher.ts
8374
+ import { useCallback as useCallback45 } from "react";
8375
+ var removeVoucherService = (env2) => {
8376
+ const removeVoucher = useCallback45(
8377
+ ({ xNode, service, ids, programId }) => {
8378
+ const jsonData = {
8379
+ model: "pos.order" /* POS_ORDER */,
8380
+ method: "action_remove_voucher" /* ACTION_REMOVE_VOUCHER */,
8381
+ ids,
8382
+ kwargs: {
8383
+ program_id: programId
8384
+ }
8385
+ };
8386
+ return env2?.requests.post(
8387
+ "/call" /* CALL_PATH */,
8388
+ jsonData,
8389
+ {
8390
+ headers: {
8391
+ "Content-Type": "application/json",
8392
+ ...xNode ? { "X-Node": xNode } : {}
8393
+ }
8394
+ },
8395
+ service
8396
+ );
8397
+ },
8398
+ [env2]
8399
+ );
8400
+ return {
8401
+ removeVoucher
8402
+ };
8403
+ };
8404
+
8405
+ // src/services/pos-service/sync-from-ui.ts
8406
+ import { useCallback as useCallback46 } from "react";
8407
+ var syncFromUiService = (env2) => {
8408
+ const syncFromUi = useCallback46(
8409
+ ({ xNode, service, orders }) => {
8410
+ const jsonData = {
8411
+ method: "sync_from_ui" /* SYNC_FROM_UI */,
8412
+ model: "pos.order" /* POS_ORDER */,
8413
+ kwargs: {
8414
+ orders
8415
+ }
8416
+ };
8417
+ return env2?.requests.post(
8418
+ "/call" /* CALL_PATH */,
8419
+ jsonData,
8420
+ {
8421
+ headers: {
8422
+ "Content-Type": "application/json",
8423
+ ...xNode ? { "X-Node": xNode } : {}
8424
+ }
8425
+ },
8426
+ service
8427
+ );
8428
+ },
8429
+ [env2]
8430
+ );
8431
+ return {
8432
+ syncFromUi
8433
+ };
8434
+ };
8435
+
8436
+ // src/services/pos-service/supabase/add-floor.ts
8437
+ import { useCallback as useCallback47 } from "react";
8297
8438
  var addFloorSupabaseService = () => {
8298
8439
  const supabase = useSupabaseOptional();
8299
- const addFloorSupabase = useCallback43(
8440
+ const addFloorSupabase = useCallback47(
8300
8441
  async (values) => {
8301
8442
  if (!supabase) {
8302
8443
  console.error("Supabase client not initialized");
@@ -8327,10 +8468,10 @@ var addFloorSupabaseService = () => {
8327
8468
  };
8328
8469
 
8329
8470
  // src/services/pos-service/supabase/add-table.ts
8330
- import { useCallback as useCallback44 } from "react";
8471
+ import { useCallback as useCallback48 } from "react";
8331
8472
  var addTableSupabaseService = () => {
8332
8473
  const supabase = useSupabaseOptional();
8333
- const addTableSupabase = useCallback44(
8474
+ const addTableSupabase = useCallback48(
8334
8475
  async (values) => {
8335
8476
  if (!supabase) {
8336
8477
  console.error("Supabase client not initialized");
@@ -8360,10 +8501,10 @@ var addTableSupabaseService = () => {
8360
8501
  };
8361
8502
 
8362
8503
  // src/services/pos-service/supabase/update-floor.ts
8363
- import { useCallback as useCallback45 } from "react";
8504
+ import { useCallback as useCallback49 } from "react";
8364
8505
  var updateFloorSupabaseService = () => {
8365
8506
  const supabase = useSupabaseOptional();
8366
- const updateFloorSupabase = useCallback45(
8507
+ const updateFloorSupabase = useCallback49(
8367
8508
  async (values) => {
8368
8509
  if (!supabase) {
8369
8510
  console.error("Supabase client not initialized");
@@ -8390,10 +8531,10 @@ var updateFloorSupabaseService = () => {
8390
8531
  };
8391
8532
 
8392
8533
  // src/services/pos-service/supabase/update-table.ts
8393
- import { useCallback as useCallback46 } from "react";
8534
+ import { useCallback as useCallback50 } from "react";
8394
8535
  var updateTableSupabaseService = () => {
8395
8536
  const supabase = useSupabaseOptional();
8396
- const updateTableSupabase = useCallback46(
8537
+ const updateTableSupabase = useCallback50(
8397
8538
  async (values) => {
8398
8539
  if (!supabase) {
8399
8540
  console.error("Supabase client not initialized");
@@ -8420,10 +8561,10 @@ var updateTableSupabaseService = () => {
8420
8561
  };
8421
8562
 
8422
8563
  // src/services/pos-service/supabase/delete-floor.ts
8423
- import { useCallback as useCallback47 } from "react";
8564
+ import { useCallback as useCallback51 } from "react";
8424
8565
  var deleteFloorSupabaseService = () => {
8425
8566
  const supabase = useSupabaseOptional();
8426
- const deleteFloorSupabase = useCallback47(
8567
+ const deleteFloorSupabase = useCallback51(
8427
8568
  async (values) => {
8428
8569
  if (!supabase) {
8429
8570
  console.error("Supabase client not initialized");
@@ -8449,10 +8590,10 @@ var deleteFloorSupabaseService = () => {
8449
8590
  };
8450
8591
 
8451
8592
  // src/services/pos-service/supabase/delete-table.ts
8452
- import { useCallback as useCallback48 } from "react";
8593
+ import { useCallback as useCallback52 } from "react";
8453
8594
  var deleteTableSupabaseService = () => {
8454
8595
  const supabase = useSupabaseOptional();
8455
- const deleteTableSupabase = useCallback48(
8596
+ const deleteTableSupabase = useCallback52(
8456
8597
  async (values) => {
8457
8598
  if (!supabase) {
8458
8599
  console.error("Supabase client not initialized");
@@ -8478,10 +8619,10 @@ var deleteTableSupabaseService = () => {
8478
8619
  };
8479
8620
 
8480
8621
  // src/services/pos-service/supabase/create-order.ts
8481
- import { useCallback as useCallback49 } from "react";
8622
+ import { useCallback as useCallback53 } from "react";
8482
8623
  var createOrderSupabaseService = () => {
8483
8624
  const supabase = useSupabaseOptional();
8484
- const createOrderSupabase = useCallback49(
8625
+ const createOrderSupabase = useCallback53(
8485
8626
  async (values) => {
8486
8627
  if (!supabase) {
8487
8628
  console.error("Supabase client not initialized");
@@ -8516,10 +8657,10 @@ var createOrderSupabaseService = () => {
8516
8657
  };
8517
8658
 
8518
8659
  // src/services/pos-service/supabase/add-product-to-order.ts
8519
- import { useCallback as useCallback50 } from "react";
8660
+ import { useCallback as useCallback54 } from "react";
8520
8661
  var addProductToOrderSupabaseService = () => {
8521
8662
  const supabase = useSupabaseOptional();
8522
- const addProductToOrderSupabase = useCallback50(
8663
+ const addProductToOrderSupabase = useCallback54(
8523
8664
  async (values) => {
8524
8665
  if (!supabase) {
8525
8666
  console.error("Supabase client not initialized");
@@ -8556,10 +8697,10 @@ var addProductToOrderSupabaseService = () => {
8556
8697
  };
8557
8698
 
8558
8699
  // src/services/pos-service/supabase/update-order-total-amount.ts
8559
- import { useCallback as useCallback51 } from "react";
8700
+ import { useCallback as useCallback55 } from "react";
8560
8701
  var updateOrderTotalAmountSupabaseService = () => {
8561
8702
  const supabase = useSupabaseOptional();
8562
- const updateOrderTotalAmountSupabase = useCallback51(
8703
+ const updateOrderTotalAmountSupabase = useCallback55(
8563
8704
  async (values) => {
8564
8705
  if (!supabase) {
8565
8706
  console.error("Supabase client not initialized");
@@ -8589,10 +8730,10 @@ var updateOrderTotalAmountSupabaseService = () => {
8589
8730
  };
8590
8731
 
8591
8732
  // src/services/pos-service/supabase/update-order-line.ts
8592
- import { useCallback as useCallback52 } from "react";
8733
+ import { useCallback as useCallback56 } from "react";
8593
8734
  var updateOrderLineSupabaseService = () => {
8594
8735
  const supabase = useSupabaseOptional();
8595
- const updateOrderLineSupabase = useCallback52(
8736
+ const updateOrderLineSupabase = useCallback56(
8596
8737
  async (values) => {
8597
8738
  if (!supabase) {
8598
8739
  console.error("Supabase client not initialized");
@@ -8624,10 +8765,10 @@ var updateOrderLineSupabaseService = () => {
8624
8765
  };
8625
8766
 
8626
8767
  // src/services/pos-service/supabase/update-order.ts
8627
- import { useCallback as useCallback53 } from "react";
8768
+ import { useCallback as useCallback57 } from "react";
8628
8769
  var updateOrderSupabaseService = () => {
8629
8770
  const supabase = useSupabaseOptional();
8630
- const updateOrderSupabase = useCallback53(
8771
+ const updateOrderSupabase = useCallback57(
8631
8772
  async (values) => {
8632
8773
  if (!supabase) {
8633
8774
  console.error("Supabase client not initialized");
@@ -8661,10 +8802,10 @@ var updateOrderSupabaseService = () => {
8661
8802
  };
8662
8803
 
8663
8804
  // src/services/pos-service/supabase/delete-order.ts
8664
- import { useCallback as useCallback54 } from "react";
8805
+ import { useCallback as useCallback58 } from "react";
8665
8806
  var deleteOrderSupabaseService = () => {
8666
8807
  const supabase = useSupabaseOptional();
8667
- const deleteOrderSupabase = useCallback54(
8808
+ const deleteOrderSupabase = useCallback58(
8668
8809
  async (values) => {
8669
8810
  if (!supabase) {
8670
8811
  console.error("Supabase client not initialized");
@@ -8690,10 +8831,10 @@ var deleteOrderSupabaseService = () => {
8690
8831
  };
8691
8832
 
8692
8833
  // src/services/pos-service/supabase/delete-order-line.ts
8693
- import { useCallback as useCallback55 } from "react";
8834
+ import { useCallback as useCallback59 } from "react";
8694
8835
  var deleteOrderLineSupabaseService = () => {
8695
8836
  const supabase = useSupabaseOptional();
8696
- const deleteOrderLineSupabase = useCallback55(
8837
+ const deleteOrderLineSupabase = useCallback59(
8697
8838
  async (values) => {
8698
8839
  if (!supabase) {
8699
8840
  console.error("Supabase client not initialized");
@@ -8719,10 +8860,10 @@ var deleteOrderLineSupabaseService = () => {
8719
8860
  };
8720
8861
 
8721
8862
  // src/services/pos-service/supabase/add-category.ts
8722
- import { useCallback as useCallback56 } from "react";
8863
+ import { useCallback as useCallback60 } from "react";
8723
8864
  var addCategorySupabaseService = () => {
8724
8865
  const supabase = useSupabaseOptional();
8725
- const addCategorySupabase = useCallback56(
8866
+ const addCategorySupabase = useCallback60(
8726
8867
  async (values) => {
8727
8868
  if (!supabase) {
8728
8869
  console.error("Supabase client not initialized");
@@ -8750,10 +8891,10 @@ var addCategorySupabaseService = () => {
8750
8891
  };
8751
8892
 
8752
8893
  // src/services/pos-service/supabase/add-product.ts
8753
- import { useCallback as useCallback57 } from "react";
8894
+ import { useCallback as useCallback61 } from "react";
8754
8895
  var addProductSupabaseService = () => {
8755
8896
  const supabase = useSupabaseOptional();
8756
- const addProductSupabase = useCallback57(
8897
+ const addProductSupabase = useCallback61(
8757
8898
  async (values) => {
8758
8899
  if (!supabase) {
8759
8900
  console.error("Supabase client not initialized");
@@ -8795,10 +8936,10 @@ var addProductSupabaseService = () => {
8795
8936
  };
8796
8937
 
8797
8938
  // src/services/pos-service/supabase/add-payment-method.ts
8798
- import { useCallback as useCallback58 } from "react";
8939
+ import { useCallback as useCallback62 } from "react";
8799
8940
  var addPaymentMethodSupabaseService = () => {
8800
8941
  const supabase = useSupabaseOptional();
8801
- const addPaymentMethodSupabase = useCallback58(
8942
+ const addPaymentMethodSupabase = useCallback62(
8802
8943
  async (values) => {
8803
8944
  if (!supabase) {
8804
8945
  console.error("Supabase client not initialized");
@@ -8829,10 +8970,10 @@ var addPaymentMethodSupabaseService = () => {
8829
8970
  };
8830
8971
 
8831
8972
  // src/services/pos-service/supabase/update-session-payment-methods.ts
8832
- import { useCallback as useCallback59 } from "react";
8973
+ import { useCallback as useCallback63 } from "react";
8833
8974
  var updateSessionPaymentMethodsSupabaseService = () => {
8834
8975
  const supabase = useSupabaseOptional();
8835
- const updateSessionPaymentMethodsSupabase = useCallback59(
8976
+ const updateSessionPaymentMethodsSupabase = useCallback63(
8836
8977
  async (values) => {
8837
8978
  if (!supabase) {
8838
8979
  console.error("Supabase client not initialized");
@@ -8861,10 +9002,10 @@ var updateSessionPaymentMethodsSupabaseService = () => {
8861
9002
  };
8862
9003
 
8863
9004
  // src/services/pos-service/supabase/create-payment.ts
8864
- import { useCallback as useCallback60 } from "react";
9005
+ import { useCallback as useCallback64 } from "react";
8865
9006
  var createPaymentSupabaseService = () => {
8866
9007
  const supabase = useSupabaseOptional();
8867
- const createPaymentSupabase = useCallback60(
9008
+ const createPaymentSupabase = useCallback64(
8868
9009
  async (values) => {
8869
9010
  if (!supabase) {
8870
9011
  console.error("Supabase client not initialized");
@@ -8905,10 +9046,10 @@ var createPaymentSupabaseService = () => {
8905
9046
  };
8906
9047
 
8907
9048
  // src/services/pos-service/supabase/create-customer.ts
8908
- import { useCallback as useCallback61 } from "react";
9049
+ import { useCallback as useCallback65 } from "react";
8909
9050
  var createCustomerSupabaseService = () => {
8910
9051
  const supabase = useSupabaseOptional();
8911
- const createCustomerSupabase = useCallback61(
9052
+ const createCustomerSupabase = useCallback65(
8912
9053
  async (values) => {
8913
9054
  if (!supabase) {
8914
9055
  console.error("Supabase client not initialized");
@@ -8946,10 +9087,10 @@ var createCustomerSupabaseService = () => {
8946
9087
  };
8947
9088
 
8948
9089
  // src/services/pos-service/supabase/update-customer.ts
8949
- import { useCallback as useCallback62 } from "react";
9090
+ import { useCallback as useCallback66 } from "react";
8950
9091
  var updateCustomerSupabaseService = () => {
8951
9092
  const supabase = useSupabaseOptional();
8952
- const updateCustomerSupabase = useCallback62(
9093
+ const updateCustomerSupabase = useCallback66(
8953
9094
  async (values) => {
8954
9095
  if (!supabase) {
8955
9096
  console.error("Supabase client not initialized");
@@ -8980,10 +9121,10 @@ var updateCustomerSupabaseService = () => {
8980
9121
  };
8981
9122
 
8982
9123
  // src/services/pos-service/supabase/delete-customer.ts
8983
- import { useCallback as useCallback63 } from "react";
9124
+ import { useCallback as useCallback67 } from "react";
8984
9125
  var deleteCustomerSupabaseService = () => {
8985
9126
  const supabase = useSupabaseOptional();
8986
- const deleteCustomerSupabase = useCallback63(
9127
+ const deleteCustomerSupabase = useCallback67(
8987
9128
  async (values) => {
8988
9129
  if (!supabase) {
8989
9130
  console.error("Supabase client not initialized");
@@ -9009,10 +9150,10 @@ var deleteCustomerSupabaseService = () => {
9009
9150
  };
9010
9151
 
9011
9152
  // src/services/pos-service/supabase/upload-image.ts
9012
- import { useCallback as useCallback64 } from "react";
9153
+ import { useCallback as useCallback68 } from "react";
9013
9154
  var uploadImageSupabaseService = () => {
9014
9155
  const supabase = useSupabaseOptional();
9015
- const uploadImageSupabase = useCallback64(
9156
+ const uploadImageSupabase = useCallback68(
9016
9157
  async (file, tenantId) => {
9017
9158
  if (!supabase) {
9018
9159
  console.error("Supabase client not initialized");
@@ -9047,9 +9188,9 @@ var uploadImageSupabaseService = () => {
9047
9188
  };
9048
9189
 
9049
9190
  // src/services/pos-service/supabase/get-list-users.ts
9050
- import { useCallback as useCallback65 } from "react";
9191
+ import { useCallback as useCallback69 } from "react";
9051
9192
  var getListUsersService = (env2) => {
9052
- const getListUsers = useCallback65(
9193
+ const getListUsers = useCallback69(
9053
9194
  ({ tenantId }) => {
9054
9195
  const jsonData = {
9055
9196
  model: "tenant.users",
@@ -9070,9 +9211,9 @@ var getListUsersService = (env2) => {
9070
9211
  };
9071
9212
 
9072
9213
  // src/services/pos-service/supabase/get-list-roles.ts
9073
- import { useCallback as useCallback66 } from "react";
9214
+ import { useCallback as useCallback70 } from "react";
9074
9215
  var getListRolesService = (env2) => {
9075
- const getListRoles = useCallback66(
9216
+ const getListRoles = useCallback70(
9076
9217
  ({ tenantId }) => {
9077
9218
  const jsonData = {
9078
9219
  model: "tenant.roles",
@@ -9093,9 +9234,9 @@ var getListRolesService = (env2) => {
9093
9234
  };
9094
9235
 
9095
9236
  // src/services/pos-service/supabase/assign-role.ts
9096
- import { useCallback as useCallback67 } from "react";
9237
+ import { useCallback as useCallback71 } from "react";
9097
9238
  var assignRoleService = (env2) => {
9098
- const assignRole = useCallback67(
9239
+ const assignRole = useCallback71(
9099
9240
  ({
9100
9241
  tenantId,
9101
9242
  userId,
@@ -9124,10 +9265,10 @@ var assignRoleService = (env2) => {
9124
9265
  };
9125
9266
 
9126
9267
  // src/services/pos-service/supabase/get-states.ts
9127
- import { useCallback as useCallback68 } from "react";
9268
+ import { useCallback as useCallback72 } from "react";
9128
9269
  var getStatesSupabaseService = () => {
9129
9270
  const supabase = useSupabaseOptional();
9130
- const getStatesSupabase = useCallback68(async () => {
9271
+ const getStatesSupabase = useCallback72(async () => {
9131
9272
  if (!supabase) return { length: 0, records: [] };
9132
9273
  const { data, error } = await supabase.from("states" /* STATES */).select("*");
9133
9274
  if (error) {
@@ -9143,10 +9284,10 @@ var getStatesSupabaseService = () => {
9143
9284
  };
9144
9285
 
9145
9286
  // src/services/pos-service/supabase/get-wards.ts
9146
- import { useCallback as useCallback69 } from "react";
9287
+ import { useCallback as useCallback73 } from "react";
9147
9288
  var getWardsSupabaseService = () => {
9148
9289
  const supabase = useSupabaseOptional();
9149
- const getWardsSupabase = useCallback69(async () => {
9290
+ const getWardsSupabase = useCallback73(async () => {
9150
9291
  if (!supabase) return { length: 0, records: [] };
9151
9292
  const { data, error } = await supabase.from("wards" /* WARDS */).select("*");
9152
9293
  if (error) {
@@ -9162,10 +9303,10 @@ var getWardsSupabaseService = () => {
9162
9303
  };
9163
9304
 
9164
9305
  // src/services/pos-service/supabase/get-partner-titles.ts
9165
- import { useCallback as useCallback70 } from "react";
9306
+ import { useCallback as useCallback74 } from "react";
9166
9307
  var getPartnerTitlesSupabaseService = () => {
9167
9308
  const supabase = useSupabaseOptional();
9168
- const getPartnerTitlesSupabase = useCallback70(async () => {
9309
+ const getPartnerTitlesSupabase = useCallback74(async () => {
9169
9310
  if (!supabase) return { length: 0, records: [] };
9170
9311
  const { data, error } = await supabase.from("partner_titles" /* PARTNER_TITLES */).select("*");
9171
9312
  if (error) {
@@ -9181,9 +9322,9 @@ var getPartnerTitlesSupabaseService = () => {
9181
9322
  };
9182
9323
 
9183
9324
  // src/services/pos-service/supabase/get-supa-current-user.ts
9184
- import { useCallback as useCallback71 } from "react";
9325
+ import { useCallback as useCallback75 } from "react";
9185
9326
  var getSupaCurrentUser = (env2) => {
9186
- const getSupaCurrentUser2 = useCallback71(
9327
+ const getSupaCurrentUser2 = useCallback75(
9187
9328
  ({ tenantId }) => {
9188
9329
  return env2?.requests.get("/api/v2/auth/me" /* SUPABASE_CURRENT_USER */, {
9189
9330
  headers: {
@@ -9200,10 +9341,10 @@ var getSupaCurrentUser = (env2) => {
9200
9341
  };
9201
9342
 
9202
9343
  // src/services/pos-service/supabase/update-category.ts
9203
- import { useCallback as useCallback72 } from "react";
9344
+ import { useCallback as useCallback76 } from "react";
9204
9345
  var updateCategorySupabaseService = () => {
9205
9346
  const supabase = useSupabaseOptional();
9206
- const updateCategorySupabase = useCallback72(
9347
+ const updateCategorySupabase = useCallback76(
9207
9348
  async (values) => {
9208
9349
  if (!supabase) {
9209
9350
  console.error("Supabase client not initialized");
@@ -9230,10 +9371,10 @@ var updateCategorySupabaseService = () => {
9230
9371
  };
9231
9372
 
9232
9373
  // src/services/pos-service/supabase/delete-category.ts
9233
- import { useCallback as useCallback73 } from "react";
9374
+ import { useCallback as useCallback77 } from "react";
9234
9375
  var deleteCategorySupabaseService = () => {
9235
9376
  const supabase = useSupabaseOptional();
9236
- const deleteCategorySupabase = useCallback73(
9377
+ const deleteCategorySupabase = useCallback77(
9237
9378
  async (values) => {
9238
9379
  if (!supabase) {
9239
9380
  console.error("Supabase client not initialized");
@@ -9259,10 +9400,10 @@ var deleteCategorySupabaseService = () => {
9259
9400
  };
9260
9401
 
9261
9402
  // src/services/pos-service/supabase/update-product.ts
9262
- import { useCallback as useCallback74 } from "react";
9403
+ import { useCallback as useCallback78 } from "react";
9263
9404
  var updateProductSupabaseService = () => {
9264
9405
  const supabase = useSupabaseOptional();
9265
- const updateProductSupabase = useCallback74(
9406
+ const updateProductSupabase = useCallback78(
9266
9407
  async (values) => {
9267
9408
  if (!supabase) {
9268
9409
  console.error("Supabase client not initialized");
@@ -9290,10 +9431,10 @@ var updateProductSupabaseService = () => {
9290
9431
  };
9291
9432
 
9292
9433
  // src/services/pos-service/supabase/delete-product.ts
9293
- import { useCallback as useCallback75 } from "react";
9434
+ import { useCallback as useCallback79 } from "react";
9294
9435
  var deleteProductSupabaseService = () => {
9295
9436
  const supabase = useSupabaseOptional();
9296
- const deleteProductSupabase = useCallback75(
9437
+ const deleteProductSupabase = useCallback79(
9297
9438
  async (values) => {
9298
9439
  if (!supabase) {
9299
9440
  console.error("Supabase client not initialized");
@@ -9318,6 +9459,35 @@ var deleteProductSupabaseService = () => {
9318
9459
  };
9319
9460
  };
9320
9461
 
9462
+ // src/services/pos-service/supabase/toggle-pos-restaurant.ts
9463
+ import { useCallback as useCallback80 } from "react";
9464
+ var togglePosRestaurantSupabaseService = () => {
9465
+ const supabase = useSupabaseOptional();
9466
+ const togglePosRestaurantSupabase = useCallback80(
9467
+ async (values) => {
9468
+ if (!supabase) {
9469
+ console.error("Supabase client not initialized");
9470
+ return null;
9471
+ }
9472
+ try {
9473
+ const { data, error } = await supabase.from("pos_configs" /* POS_CONFIGS */).update({ module_pos_restaurant: values.module_pos_restaurant }).eq("id", values.config_id).select("id").single();
9474
+ if (error) {
9475
+ console.error("Error toggling pos restaurant mode:", error);
9476
+ return null;
9477
+ }
9478
+ return [data.id];
9479
+ } catch (error) {
9480
+ console.error("Error toggling pos restaurant mode:", error);
9481
+ return null;
9482
+ }
9483
+ },
9484
+ [supabase]
9485
+ );
9486
+ return {
9487
+ togglePosRestaurantSupabase
9488
+ };
9489
+ };
9490
+
9321
9491
  // src/services/pos-service/index.ts
9322
9492
  var serviceFactories = [
9323
9493
  addEntityService,
@@ -9350,6 +9520,10 @@ var serviceFactories = [
9350
9520
  updateEntityService,
9351
9521
  updateOrderStatusService,
9352
9522
  completeCurrentStageService,
9523
+ appAuthenticateService,
9524
+ applyVoucherService,
9525
+ removeVoucherService,
9526
+ syncFromUiService,
9353
9527
  addFloorSupabaseService,
9354
9528
  addTableSupabaseService,
9355
9529
  updateFloorSupabaseService,
@@ -9383,7 +9557,8 @@ var serviceFactories = [
9383
9557
  updateCategorySupabaseService,
9384
9558
  deleteCategorySupabaseService,
9385
9559
  updateProductSupabaseService,
9386
- deleteProductSupabaseService
9560
+ deleteProductSupabaseService,
9561
+ togglePosRestaurantSupabaseService
9387
9562
  ];
9388
9563
  var usePosService = () => {
9389
9564
  const { env: env2 } = useEnv();
@@ -10280,9 +10455,9 @@ var BaseModel = class {
10280
10455
  };
10281
10456
 
10282
10457
  // src/hooks/model/use-model.ts
10283
- import { useCallback as useCallback76 } from "react";
10458
+ import { useCallback as useCallback81 } from "react";
10284
10459
  var useModel = () => {
10285
- const initModel = useCallback76((modelData) => {
10460
+ const initModel = useCallback81((modelData) => {
10286
10461
  switch (modelData?.name) {
10287
10462
  default:
10288
10463
  return new BaseModel(modelData);
@@ -11412,315 +11587,365 @@ var useCompleteCurrentStage = () => {
11412
11587
  };
11413
11588
  var use_complete_current_stage_default = useCompleteCurrentStage;
11414
11589
 
11415
- // src/hooks/pos/supabase/use-add-floor.ts
11590
+ // src/hooks/pos/use-app-authenticate.ts
11416
11591
  import { useMutation as useMutation89 } from "@tanstack/react-query";
11592
+ var useAppAuthenticate = () => {
11593
+ const pos = usePosService();
11594
+ return useMutation89({
11595
+ mutationFn: pos.appAuthenticate
11596
+ });
11597
+ };
11598
+ var use_app_authenticate_default = useAppAuthenticate;
11599
+
11600
+ // src/hooks/pos/use-apply-voucher.ts
11601
+ import { useMutation as useMutation90 } from "@tanstack/react-query";
11602
+ var useApplyVoucher = () => {
11603
+ const pos = usePosService();
11604
+ return useMutation90({
11605
+ mutationFn: pos.applyVoucher
11606
+ });
11607
+ };
11608
+ var use_apply_voucher_default = useApplyVoucher;
11609
+
11610
+ // src/hooks/pos/use-remove-voucher.ts
11611
+ import { useMutation as useMutation91 } from "@tanstack/react-query";
11612
+ var useRemoveVoucher = () => {
11613
+ const pos = usePosService();
11614
+ return useMutation91({
11615
+ mutationFn: pos.removeVoucher
11616
+ });
11617
+ };
11618
+ var use_remove_voucher_default = useRemoveVoucher;
11619
+
11620
+ // src/hooks/pos/use-sync-from-ui.ts
11621
+ import { useMutation as useMutation92 } from "@tanstack/react-query";
11622
+ var useSyncFromUi = () => {
11623
+ const pos = usePosService();
11624
+ return useMutation92({
11625
+ mutationFn: pos.syncFromUi
11626
+ });
11627
+ };
11628
+ var use_sync_from_ui_default = useSyncFromUi;
11629
+
11630
+ // src/hooks/pos/supabase/use-add-floor.ts
11631
+ import { useMutation as useMutation93 } from "@tanstack/react-query";
11417
11632
  var useAddFloor = () => {
11418
11633
  const { addFloorSupabase } = addFloorSupabaseService();
11419
- return useMutation89({
11634
+ return useMutation93({
11420
11635
  mutationFn: addFloorSupabase
11421
11636
  });
11422
11637
  };
11423
11638
  var use_add_floor_default = useAddFloor;
11424
11639
 
11425
11640
  // src/hooks/pos/supabase/use-add-table.ts
11426
- import { useMutation as useMutation90 } from "@tanstack/react-query";
11641
+ import { useMutation as useMutation94 } from "@tanstack/react-query";
11427
11642
  var useAddTable = () => {
11428
11643
  const { addTableSupabase } = addTableSupabaseService();
11429
- return useMutation90({
11644
+ return useMutation94({
11430
11645
  mutationFn: addTableSupabase
11431
11646
  });
11432
11647
  };
11433
11648
  var use_add_table_default = useAddTable;
11434
11649
 
11435
11650
  // src/hooks/pos/supabase/use-update-floor.ts
11436
- import { useMutation as useMutation91 } from "@tanstack/react-query";
11651
+ import { useMutation as useMutation95 } from "@tanstack/react-query";
11437
11652
  var useUpdateFloor = () => {
11438
11653
  const { updateFloorSupabase } = updateFloorSupabaseService();
11439
- return useMutation91({
11654
+ return useMutation95({
11440
11655
  mutationFn: updateFloorSupabase
11441
11656
  });
11442
11657
  };
11443
11658
  var use_update_floor_default = useUpdateFloor;
11444
11659
 
11445
11660
  // src/hooks/pos/supabase/use-update-table.ts
11446
- import { useMutation as useMutation92 } from "@tanstack/react-query";
11661
+ import { useMutation as useMutation96 } from "@tanstack/react-query";
11447
11662
  var useUpdateTable = () => {
11448
11663
  const { updateTableSupabase } = updateTableSupabaseService();
11449
- return useMutation92({
11664
+ return useMutation96({
11450
11665
  mutationFn: updateTableSupabase
11451
11666
  });
11452
11667
  };
11453
11668
  var use_update_table_default = useUpdateTable;
11454
11669
 
11455
11670
  // src/hooks/pos/supabase/use-delete-floor.ts
11456
- import { useMutation as useMutation93 } from "@tanstack/react-query";
11671
+ import { useMutation as useMutation97 } from "@tanstack/react-query";
11457
11672
  var useDeleteFloor = () => {
11458
11673
  const { deleteFloorSupabase } = deleteFloorSupabaseService();
11459
- return useMutation93({
11674
+ return useMutation97({
11460
11675
  mutationFn: deleteFloorSupabase
11461
11676
  });
11462
11677
  };
11463
11678
  var use_delete_floor_default = useDeleteFloor;
11464
11679
 
11465
11680
  // src/hooks/pos/supabase/use-delete-table.ts
11466
- import { useMutation as useMutation94 } from "@tanstack/react-query";
11681
+ import { useMutation as useMutation98 } from "@tanstack/react-query";
11467
11682
  var useDeleteTable = () => {
11468
11683
  const { deleteTableSupabase } = deleteTableSupabaseService();
11469
- return useMutation94({
11684
+ return useMutation98({
11470
11685
  mutationFn: deleteTableSupabase
11471
11686
  });
11472
11687
  };
11473
11688
  var use_delete_table_default = useDeleteTable;
11474
11689
 
11475
11690
  // src/hooks/pos/supabase/use-create-order.ts
11476
- import { useMutation as useMutation95 } from "@tanstack/react-query";
11691
+ import { useMutation as useMutation99 } from "@tanstack/react-query";
11477
11692
  var useCreateOrder = () => {
11478
11693
  const { createOrderSupabase } = createOrderSupabaseService();
11479
- return useMutation95({
11694
+ return useMutation99({
11480
11695
  mutationFn: createOrderSupabase
11481
11696
  });
11482
11697
  };
11483
11698
  var use_create_order_default = useCreateOrder;
11484
11699
 
11485
11700
  // src/hooks/pos/supabase/use-add-category.ts
11486
- import { useMutation as useMutation96 } from "@tanstack/react-query";
11701
+ import { useMutation as useMutation100 } from "@tanstack/react-query";
11487
11702
  var useAddCategory = () => {
11488
11703
  const { addCategorySupabase } = addCategorySupabaseService();
11489
- return useMutation96({
11704
+ return useMutation100({
11490
11705
  mutationFn: addCategorySupabase
11491
11706
  });
11492
11707
  };
11493
11708
  var use_add_category_default = useAddCategory;
11494
11709
 
11495
11710
  // src/hooks/pos/supabase/use-add-product-to-order.ts
11496
- import { useMutation as useMutation97 } from "@tanstack/react-query";
11711
+ import { useMutation as useMutation101 } from "@tanstack/react-query";
11497
11712
  var useAddProductToOrder = () => {
11498
11713
  const { addProductToOrderSupabase } = addProductToOrderSupabaseService();
11499
- return useMutation97({
11714
+ return useMutation101({
11500
11715
  mutationFn: addProductToOrderSupabase
11501
11716
  });
11502
11717
  };
11503
11718
  var use_add_product_to_order_default = useAddProductToOrder;
11504
11719
 
11505
11720
  // src/hooks/pos/supabase/use-update-order-total-amount.ts
11506
- import { useMutation as useMutation98 } from "@tanstack/react-query";
11721
+ import { useMutation as useMutation102 } from "@tanstack/react-query";
11507
11722
  var useUpdateOrderTotalAmount = () => {
11508
11723
  const { updateOrderTotalAmountSupabase } = updateOrderTotalAmountSupabaseService();
11509
- return useMutation98({
11724
+ return useMutation102({
11510
11725
  mutationFn: updateOrderTotalAmountSupabase
11511
11726
  });
11512
11727
  };
11513
11728
  var use_update_order_total_amount_default = useUpdateOrderTotalAmount;
11514
11729
 
11515
11730
  // src/hooks/pos/supabase/use-update-order-line.ts
11516
- import { useMutation as useMutation99 } from "@tanstack/react-query";
11731
+ import { useMutation as useMutation103 } from "@tanstack/react-query";
11517
11732
  var useUpdateOrderLine = () => {
11518
11733
  const { updateOrderLineSupabase } = updateOrderLineSupabaseService();
11519
- return useMutation99({
11734
+ return useMutation103({
11520
11735
  mutationFn: updateOrderLineSupabase
11521
11736
  });
11522
11737
  };
11523
11738
  var use_update_order_line_default = useUpdateOrderLine;
11524
11739
 
11525
11740
  // src/hooks/pos/supabase/use-update-order.ts
11526
- import { useMutation as useMutation100 } from "@tanstack/react-query";
11741
+ import { useMutation as useMutation104 } from "@tanstack/react-query";
11527
11742
  var useUpdateOrder = () => {
11528
11743
  const { updateOrderSupabase } = updateOrderSupabaseService();
11529
- return useMutation100({
11744
+ return useMutation104({
11530
11745
  mutationFn: updateOrderSupabase
11531
11746
  });
11532
11747
  };
11533
11748
  var use_update_order_default = useUpdateOrder;
11534
11749
 
11535
11750
  // src/hooks/pos/supabase/use-delete-order.ts
11536
- import { useMutation as useMutation101 } from "@tanstack/react-query";
11751
+ import { useMutation as useMutation105 } from "@tanstack/react-query";
11537
11752
  var useDeleteOrder = () => {
11538
11753
  const { deleteOrderSupabase } = deleteOrderSupabaseService();
11539
- return useMutation101({
11754
+ return useMutation105({
11540
11755
  mutationFn: deleteOrderSupabase
11541
11756
  });
11542
11757
  };
11543
11758
  var use_delete_order_default = useDeleteOrder;
11544
11759
 
11545
11760
  // src/hooks/pos/supabase/use-delete-order-line.ts
11546
- import { useMutation as useMutation102 } from "@tanstack/react-query";
11761
+ import { useMutation as useMutation106 } from "@tanstack/react-query";
11547
11762
  var useDeleteOrderLine = () => {
11548
11763
  const { deleteOrderLineSupabase } = deleteOrderLineSupabaseService();
11549
- return useMutation102({
11764
+ return useMutation106({
11550
11765
  mutationFn: deleteOrderLineSupabase
11551
11766
  });
11552
11767
  };
11553
11768
  var use_delete_order_line_default = useDeleteOrderLine;
11554
11769
 
11555
11770
  // src/hooks/pos/supabase/use-add-product.ts
11556
- import { useMutation as useMutation103 } from "@tanstack/react-query";
11771
+ import { useMutation as useMutation107 } from "@tanstack/react-query";
11557
11772
  var useAddProduct = () => {
11558
11773
  const { addProductSupabase } = addProductSupabaseService();
11559
- return useMutation103({
11774
+ return useMutation107({
11560
11775
  mutationFn: addProductSupabase
11561
11776
  });
11562
11777
  };
11563
11778
  var use_add_product_default = useAddProduct;
11564
11779
 
11565
11780
  // src/hooks/pos/use-get-functional-modules.ts
11566
- import { useMutation as useMutation104 } from "@tanstack/react-query";
11781
+ import { useMutation as useMutation108 } from "@tanstack/react-query";
11567
11782
  var useGetFunctionalModules = () => {
11568
11783
  const pos = usePosService();
11569
- return useMutation104({
11784
+ return useMutation108({
11570
11785
  mutationFn: pos.getFunctionalModules
11571
11786
  });
11572
11787
  };
11573
11788
  var use_get_functional_modules_default = useGetFunctionalModules;
11574
11789
 
11575
11790
  // src/hooks/pos/supabase/use-add-payment-method.ts
11576
- import { useMutation as useMutation105 } from "@tanstack/react-query";
11791
+ import { useMutation as useMutation109 } from "@tanstack/react-query";
11577
11792
  var useAddPaymentMethod = () => {
11578
11793
  const { addPaymentMethodSupabase } = addPaymentMethodSupabaseService();
11579
- return useMutation105({
11794
+ return useMutation109({
11580
11795
  mutationFn: addPaymentMethodSupabase
11581
11796
  });
11582
11797
  };
11583
11798
  var use_add_payment_method_default = useAddPaymentMethod;
11584
11799
 
11585
11800
  // src/hooks/pos/supabase/use-update-session-payment-methods.ts
11586
- import { useMutation as useMutation106 } from "@tanstack/react-query";
11801
+ import { useMutation as useMutation110 } from "@tanstack/react-query";
11587
11802
  var useUpdateSessionPaymentMethods = () => {
11588
11803
  const { updateSessionPaymentMethodsSupabase } = updateSessionPaymentMethodsSupabaseService();
11589
- return useMutation106({
11804
+ return useMutation110({
11590
11805
  mutationFn: updateSessionPaymentMethodsSupabase
11591
11806
  });
11592
11807
  };
11593
11808
  var use_update_session_payment_methods_default = useUpdateSessionPaymentMethods;
11594
11809
 
11595
11810
  // src/hooks/pos/supabase/use-create-payment.ts
11596
- import { useMutation as useMutation107 } from "@tanstack/react-query";
11811
+ import { useMutation as useMutation111 } from "@tanstack/react-query";
11597
11812
  var useCreatePayment = () => {
11598
11813
  const { createPaymentSupabase } = createPaymentSupabaseService();
11599
- return useMutation107({
11814
+ return useMutation111({
11600
11815
  mutationFn: createPaymentSupabase
11601
11816
  });
11602
11817
  };
11603
11818
  var use_create_payment_default = useCreatePayment;
11604
11819
 
11605
11820
  // src/hooks/pos/supabase/use-create-customer.ts
11606
- import { useMutation as useMutation108 } from "@tanstack/react-query";
11821
+ import { useMutation as useMutation112 } from "@tanstack/react-query";
11607
11822
  var useCreateCustomer = () => {
11608
11823
  const { createCustomerSupabase } = createCustomerSupabaseService();
11609
- return useMutation108({
11824
+ return useMutation112({
11610
11825
  mutationFn: createCustomerSupabase
11611
11826
  });
11612
11827
  };
11613
11828
  var use_create_customer_default = useCreateCustomer;
11614
11829
 
11615
11830
  // src/hooks/pos/supabase/use-update-customer.ts
11616
- import { useMutation as useMutation109 } from "@tanstack/react-query";
11831
+ import { useMutation as useMutation113 } from "@tanstack/react-query";
11617
11832
  var useUpdateCustomer = () => {
11618
11833
  const { updateCustomerSupabase } = updateCustomerSupabaseService();
11619
- return useMutation109({
11834
+ return useMutation113({
11620
11835
  mutationFn: updateCustomerSupabase
11621
11836
  });
11622
11837
  };
11623
11838
  var use_update_customer_default = useUpdateCustomer;
11624
11839
 
11625
11840
  // src/hooks/pos/supabase/use-delete-customer.ts
11626
- import { useMutation as useMutation110 } from "@tanstack/react-query";
11841
+ import { useMutation as useMutation114 } from "@tanstack/react-query";
11627
11842
  var useDeleteCustomer = () => {
11628
11843
  const { deleteCustomerSupabase } = deleteCustomerSupabaseService();
11629
- return useMutation110({
11844
+ return useMutation114({
11630
11845
  mutationFn: deleteCustomerSupabase
11631
11846
  });
11632
11847
  };
11633
11848
  var use_delete_customer_default = useDeleteCustomer;
11634
11849
 
11635
11850
  // src/hooks/pos/supabase/use-supa-upload-image.ts
11636
- import { useMutation as useMutation111 } from "@tanstack/react-query";
11851
+ import { useMutation as useMutation115 } from "@tanstack/react-query";
11637
11852
  var useSupaUploadImage = () => {
11638
11853
  const { uploadImageSupabase } = uploadImageSupabaseService();
11639
- return useMutation111({
11854
+ return useMutation115({
11640
11855
  mutationFn: ({ file, tenantId }) => uploadImageSupabase(file, tenantId)
11641
11856
  });
11642
11857
  };
11643
11858
  var use_supa_upload_image_default = useSupaUploadImage;
11644
11859
 
11645
11860
  // src/hooks/pos/supabase/use-get-list-users.ts
11646
- import { useMutation as useMutation112 } from "@tanstack/react-query";
11861
+ import { useMutation as useMutation116 } from "@tanstack/react-query";
11647
11862
  var useGetListUsers = () => {
11648
11863
  const pos = usePosService();
11649
- return useMutation112({
11864
+ return useMutation116({
11650
11865
  mutationFn: pos.getListUsers
11651
11866
  });
11652
11867
  };
11653
11868
  var use_get_list_users_default = useGetListUsers;
11654
11869
 
11655
11870
  // src/hooks/pos/supabase/use-get-list-roles.ts
11656
- import { useMutation as useMutation113 } from "@tanstack/react-query";
11871
+ import { useMutation as useMutation117 } from "@tanstack/react-query";
11657
11872
  var useGetListRoles = () => {
11658
11873
  const pos = usePosService();
11659
- return useMutation113({
11874
+ return useMutation117({
11660
11875
  mutationFn: pos.getListRoles
11661
11876
  });
11662
11877
  };
11663
11878
  var use_get_list_roles_default = useGetListRoles;
11664
11879
 
11665
11880
  // src/hooks/pos/supabase/use-assign-role.ts
11666
- import { useMutation as useMutation114 } from "@tanstack/react-query";
11881
+ import { useMutation as useMutation118 } from "@tanstack/react-query";
11667
11882
  var useAssignRole = () => {
11668
11883
  const pos = usePosService();
11669
- return useMutation114({
11884
+ return useMutation118({
11670
11885
  mutationFn: pos.assignRole
11671
11886
  });
11672
11887
  };
11673
11888
  var use_assign_role_default = useAssignRole;
11674
11889
 
11675
11890
  // src/hooks/pos/supabase/use-get-supa-current-user.ts
11676
- import { useMutation as useMutation115 } from "@tanstack/react-query";
11891
+ import { useMutation as useMutation119 } from "@tanstack/react-query";
11677
11892
  var useGetSupaCurrentUser = () => {
11678
11893
  const pos = usePosService();
11679
- return useMutation115({
11894
+ return useMutation119({
11680
11895
  mutationFn: pos.getSupaCurrentUser
11681
11896
  });
11682
11897
  };
11683
11898
  var use_get_supa_current_user_default = useGetSupaCurrentUser;
11684
11899
 
11685
11900
  // src/hooks/pos/supabase/use-update-category.ts
11686
- import { useMutation as useMutation116 } from "@tanstack/react-query";
11901
+ import { useMutation as useMutation120 } from "@tanstack/react-query";
11687
11902
  var useUpdateCategory = () => {
11688
11903
  const pos = usePosService();
11689
- return useMutation116({
11904
+ return useMutation120({
11690
11905
  mutationFn: pos.updateCategorySupabase
11691
11906
  });
11692
11907
  };
11693
11908
  var use_update_category_default = useUpdateCategory;
11694
11909
 
11695
11910
  // src/hooks/pos/supabase/use-delete-category.ts
11696
- import { useMutation as useMutation117 } from "@tanstack/react-query";
11911
+ import { useMutation as useMutation121 } from "@tanstack/react-query";
11697
11912
  var useDeleteCategory = () => {
11698
11913
  const pos = usePosService();
11699
- return useMutation117({
11914
+ return useMutation121({
11700
11915
  mutationFn: pos.deleteCategorySupabase
11701
11916
  });
11702
11917
  };
11703
11918
  var use_delete_category_default = useDeleteCategory;
11704
11919
 
11705
11920
  // src/hooks/pos/supabase/use-update-product.ts
11706
- import { useMutation as useMutation118 } from "@tanstack/react-query";
11921
+ import { useMutation as useMutation122 } from "@tanstack/react-query";
11707
11922
  var useUpdateProduct = () => {
11708
11923
  const pos = usePosService();
11709
- return useMutation118({
11924
+ return useMutation122({
11710
11925
  mutationFn: pos.updateProductSupabase
11711
11926
  });
11712
11927
  };
11713
11928
  var use_update_product_default = useUpdateProduct;
11714
11929
 
11715
11930
  // src/hooks/pos/supabase/use-delete-product.ts
11716
- import { useMutation as useMutation119 } from "@tanstack/react-query";
11931
+ import { useMutation as useMutation123 } from "@tanstack/react-query";
11717
11932
  var useDeleteProduct = () => {
11718
11933
  const pos = usePosService();
11719
- return useMutation119({
11934
+ return useMutation123({
11720
11935
  mutationFn: pos.deleteProductSupabase
11721
11936
  });
11722
11937
  };
11723
11938
  var use_delete_product_default = useDeleteProduct;
11939
+
11940
+ // src/hooks/pos/supabase/use-toggle-pos-restaurant.ts
11941
+ import { useMutation as useMutation124 } from "@tanstack/react-query";
11942
+ var useTogglePosRestaurant = () => {
11943
+ const pos = usePosService();
11944
+ return useMutation124({
11945
+ mutationFn: pos.togglePosRestaurantSupabase
11946
+ });
11947
+ };
11948
+ var use_toggle_pos_restaurant_default = useTogglePosRestaurant;
11724
11949
  export {
11725
11950
  BaseModel,
11726
11951
  ComponentType,
@@ -11867,8 +12092,10 @@ export {
11867
12092
  use_add_product_default as useAddProduct,
11868
12093
  use_add_product_to_order_default as useAddProductToOrder,
11869
12094
  use_add_table_default as useAddTable,
12095
+ use_app_authenticate_default as useAppAuthenticate,
11870
12096
  useAppDispatch,
11871
12097
  useAppSelector,
12098
+ use_apply_voucher_default as useApplyVoucher,
11872
12099
  use_assign_role_default as useAssignRole,
11873
12100
  useAuthService,
11874
12101
  use_button_default as useButton,
@@ -11985,6 +12212,7 @@ export {
11985
12212
  use_read_group_default as useReadGroup,
11986
12213
  use_remove_row_default as useRemoveRow,
11987
12214
  use_remove_totp_setup_default as useRemoveTotpSetup,
12215
+ use_remove_voucher_default as useRemoveVoucher,
11988
12216
  use_request_setup_totp_default as useRequestSetupTotp,
11989
12217
  use_reset_password_default as useResetPassword,
11990
12218
  use_reset_password_sso_default as useResetPasswordSSO,
@@ -11999,7 +12227,9 @@ export {
11999
12227
  use_supa_upload_image_default as useSupaUploadImage,
12000
12228
  useSupabase,
12001
12229
  use_switch_locale_default as useSwitchLocale,
12230
+ use_sync_from_ui_default as useSyncFromUi,
12002
12231
  useTabModel,
12232
+ use_toggle_pos_restaurant_default as useTogglePosRestaurant,
12003
12233
  use_update_category_default as useUpdateCategory,
12004
12234
  use_update_closed_session_default as useUpdateClosedSession,
12005
12235
  use_update_customer_default as useUpdateCustomer,