@fctc/interface-logic 2.7.7 → 2.7.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/hooks.d.mts CHANGED
@@ -466,7 +466,6 @@ declare const useManageOnChange: () => _tanstack_react_query.UseMutationResult<u
466
466
  args: any;
467
467
  service: string;
468
468
  xNode: string;
469
- method: string;
470
469
  }, unknown>;
471
470
 
472
471
  export { useButton, useChangeStatus, useCreateEntity, useCreateSession, useDelete, useDeleteComment, useDeleteEntity, useDuplicateRecord, useExecuteImport, useExportExcel, useForgotPassword, useForgotPasswordSSO, useGet2FAMethods, useGetASession, useGetAccessByCode, useGetActionDetail, useGetAll, useGetCalendar, useGetComment, useGetCompanyInfo, useGetConversionRate, useGetCurrency, useGetCurrentCompany, useGetDetail, useGetFieldExport, useGetFieldOnChange, useGetFileExcel, useGetFormView, useGetGroups, useGetImage, useGetList, useGetListCompany, useGetListData, useGetListMyBankAccount, useGetMenu, useGetPos, useGetPrintReport, useGetProGressBar, useGetProfile, useGetProvider, useGetResequence, useGetSelection, useGetUser, useGetView, useGrantAccess, useHandleClosingSession, useIsValidToken, useLoadAction, useLoadDataPosSession, useLoadMessage, useLoginCredential, useLoginSocial, useLogout, useManageOnChange, useManageSession, useModel, useOdooDataTransform, useOnChangeForm, useParsePreview, usePrint, useRemoveRow, useRemoveTotpSetup, useRequestSetupTotp, useResetPassword, useResetPasswordSSO, useRunAction, useSave, useSendComment, useSettingsWebRead2fa, useSignInSSO, useSwitchLocale, useUpdateClosedSession, useUpdateEntity, useUpdatePassword, useUploadFile, useUploadFileExcel, useUploadIdFile, useUploadImage, useValidateActionToken, useVerify2FA, useVerifyTotp };
package/dist/hooks.d.ts CHANGED
@@ -466,7 +466,6 @@ declare const useManageOnChange: () => _tanstack_react_query.UseMutationResult<u
466
466
  args: any;
467
467
  service: string;
468
468
  xNode: string;
469
- method: string;
470
469
  }, unknown>;
471
470
 
472
471
  export { useButton, useChangeStatus, useCreateEntity, useCreateSession, useDelete, useDeleteComment, useDeleteEntity, useDuplicateRecord, useExecuteImport, useExportExcel, useForgotPassword, useForgotPasswordSSO, useGet2FAMethods, useGetASession, useGetAccessByCode, useGetActionDetail, useGetAll, useGetCalendar, useGetComment, useGetCompanyInfo, useGetConversionRate, useGetCurrency, useGetCurrentCompany, useGetDetail, useGetFieldExport, useGetFieldOnChange, useGetFileExcel, useGetFormView, useGetGroups, useGetImage, useGetList, useGetListCompany, useGetListData, useGetListMyBankAccount, useGetMenu, useGetPos, useGetPrintReport, useGetProGressBar, useGetProfile, useGetProvider, useGetResequence, useGetSelection, useGetUser, useGetView, useGrantAccess, useHandleClosingSession, useIsValidToken, useLoadAction, useLoadDataPosSession, useLoadMessage, useLoginCredential, useLoginSocial, useLogout, useManageOnChange, useManageSession, useModel, useOdooDataTransform, useOnChangeForm, useParsePreview, usePrint, useRemoveRow, useRemoveTotpSetup, useRequestSetupTotp, useResetPassword, useResetPasswordSSO, useRunAction, useSave, useSendComment, useSettingsWebRead2fa, useSignInSSO, useSwitchLocale, useUpdateClosedSession, useUpdateEntity, useUpdatePassword, useUploadFile, useUploadFileExcel, useUploadIdFile, useUploadImage, useValidateActionToken, useVerify2FA, useVerifyTotp };
package/dist/hooks.js CHANGED
@@ -3122,6 +3122,31 @@ function useActionService() {
3122
3122
  },
3123
3123
  [env]
3124
3124
  );
3125
+ const generateSerialNumber = (0, import_react6.useCallback)(
3126
+ async ({
3127
+ kwargs,
3128
+ context,
3129
+ service,
3130
+ xNode
3131
+ }) => {
3132
+ const jsonData = {
3133
+ model: "stok.move",
3134
+ method: "action_generate_lot_line_vals",
3135
+ with_context: { ...context },
3136
+ kwargs
3137
+ };
3138
+ return env.requests.post(
3139
+ "/call" /* CALL_PATH */,
3140
+ jsonData,
3141
+ {
3142
+ headers: { "Content-Type": "application/json" },
3143
+ ...xNode ? { "X-Node": xNode } : {}
3144
+ },
3145
+ service
3146
+ );
3147
+ },
3148
+ [env]
3149
+ );
3125
3150
  return {
3126
3151
  loadAction,
3127
3152
  callButton,
@@ -3129,7 +3154,8 @@ function useActionService() {
3129
3154
  duplicateRecord,
3130
3155
  getPrintReportName,
3131
3156
  print,
3132
- runAction
3157
+ runAction,
3158
+ generateSerialNumber
3133
3159
  };
3134
3160
  }
3135
3161
 
@@ -4982,7 +5008,6 @@ function useViewService() {
4982
5008
  const manageOnChange = (0, import_react14.useCallback)(
4983
5009
  ({
4984
5010
  model,
4985
- method,
4986
5011
  ids,
4987
5012
  args,
4988
5013
  xNode,
@@ -4990,7 +5015,7 @@ function useViewService() {
4990
5015
  }) => {
4991
5016
  const jsonData = {
4992
5017
  model,
4993
- method,
5018
+ method: "onchange" /* ONCHANGE */,
4994
5019
  ids,
4995
5020
  args
4996
5021
  };
@@ -6639,12 +6664,10 @@ var useManageOnChange = () => {
6639
6664
  ids,
6640
6665
  args,
6641
6666
  service,
6642
- xNode,
6643
- method
6667
+ xNode
6644
6668
  }) => {
6645
6669
  return manageOnChange({
6646
6670
  model,
6647
- method,
6648
6671
  ids,
6649
6672
  args,
6650
6673
  service,
@@ -6654,6 +6677,9 @@ var useManageOnChange = () => {
6654
6677
  });
6655
6678
  };
6656
6679
  var use_manage_on_change_default = useManageOnChange;
6680
+
6681
+ // src/hooks/view/use-gen-serial-number.ts
6682
+ var import_react_query82 = require("@tanstack/react-query");
6657
6683
  // Annotate the CommonJS export names for ESM import in node:
6658
6684
  0 && (module.exports = {
6659
6685
  useButton,
package/dist/hooks.mjs CHANGED
@@ -3006,6 +3006,31 @@ function useActionService() {
3006
3006
  },
3007
3007
  [env]
3008
3008
  );
3009
+ const generateSerialNumber = useCallback2(
3010
+ async ({
3011
+ kwargs,
3012
+ context,
3013
+ service,
3014
+ xNode
3015
+ }) => {
3016
+ const jsonData = {
3017
+ model: "stok.move",
3018
+ method: "action_generate_lot_line_vals",
3019
+ with_context: { ...context },
3020
+ kwargs
3021
+ };
3022
+ return env.requests.post(
3023
+ "/call" /* CALL_PATH */,
3024
+ jsonData,
3025
+ {
3026
+ headers: { "Content-Type": "application/json" },
3027
+ ...xNode ? { "X-Node": xNode } : {}
3028
+ },
3029
+ service
3030
+ );
3031
+ },
3032
+ [env]
3033
+ );
3009
3034
  return {
3010
3035
  loadAction,
3011
3036
  callButton,
@@ -3013,7 +3038,8 @@ function useActionService() {
3013
3038
  duplicateRecord,
3014
3039
  getPrintReportName,
3015
3040
  print,
3016
- runAction
3041
+ runAction,
3042
+ generateSerialNumber
3017
3043
  };
3018
3044
  }
3019
3045
 
@@ -4866,7 +4892,6 @@ function useViewService() {
4866
4892
  const manageOnChange = useCallback10(
4867
4893
  ({
4868
4894
  model,
4869
- method,
4870
4895
  ids,
4871
4896
  args,
4872
4897
  xNode,
@@ -4874,7 +4899,7 @@ function useViewService() {
4874
4899
  }) => {
4875
4900
  const jsonData = {
4876
4901
  model,
4877
- method,
4902
+ method: "onchange" /* ONCHANGE */,
4878
4903
  ids,
4879
4904
  args
4880
4905
  };
@@ -6523,12 +6548,10 @@ var useManageOnChange = () => {
6523
6548
  ids,
6524
6549
  args,
6525
6550
  service,
6526
- xNode,
6527
- method
6551
+ xNode
6528
6552
  }) => {
6529
6553
  return manageOnChange({
6530
6554
  model,
6531
- method,
6532
6555
  ids,
6533
6556
  args,
6534
6557
  service,
@@ -6538,6 +6561,9 @@ var useManageOnChange = () => {
6538
6561
  });
6539
6562
  };
6540
6563
  var use_manage_on_change_default = useManageOnChange;
6564
+
6565
+ // src/hooks/view/use-gen-serial-number.ts
6566
+ import { useMutation as useMutation60 } from "@tanstack/react-query";
6541
6567
  export {
6542
6568
  use_button_default as useButton,
6543
6569
  use_change_status_default as useChangeStatus,
package/dist/provider.js CHANGED
@@ -3058,6 +3058,31 @@ function useActionService() {
3058
3058
  },
3059
3059
  [env]
3060
3060
  );
3061
+ const generateSerialNumber = (0, import_react2.useCallback)(
3062
+ async ({
3063
+ kwargs,
3064
+ context,
3065
+ service,
3066
+ xNode
3067
+ }) => {
3068
+ const jsonData = {
3069
+ model: "stok.move",
3070
+ method: "action_generate_lot_line_vals",
3071
+ with_context: { ...context },
3072
+ kwargs
3073
+ };
3074
+ return env.requests.post(
3075
+ "/call" /* CALL_PATH */,
3076
+ jsonData,
3077
+ {
3078
+ headers: { "Content-Type": "application/json" },
3079
+ ...xNode ? { "X-Node": xNode } : {}
3080
+ },
3081
+ service
3082
+ );
3083
+ },
3084
+ [env]
3085
+ );
3061
3086
  return {
3062
3087
  loadAction,
3063
3088
  callButton,
@@ -3065,7 +3090,8 @@ function useActionService() {
3065
3090
  duplicateRecord,
3066
3091
  getPrintReportName,
3067
3092
  print,
3068
- runAction
3093
+ runAction,
3094
+ generateSerialNumber
3069
3095
  };
3070
3096
  }
3071
3097
 
@@ -4918,7 +4944,6 @@ function useViewService() {
4918
4944
  const manageOnChange = (0, import_react10.useCallback)(
4919
4945
  ({
4920
4946
  model,
4921
- method,
4922
4947
  ids,
4923
4948
  args,
4924
4949
  xNode,
@@ -4926,7 +4951,7 @@ function useViewService() {
4926
4951
  }) => {
4927
4952
  const jsonData = {
4928
4953
  model,
4929
- method,
4954
+ method: "onchange" /* ONCHANGE */,
4930
4955
  ids,
4931
4956
  args
4932
4957
  };
@@ -6993,12 +7018,10 @@ var useManageOnChange = () => {
6993
7018
  ids,
6994
7019
  args,
6995
7020
  service,
6996
- xNode,
6997
- method
7021
+ xNode
6998
7022
  }) => {
6999
7023
  return manageOnChange({
7000
7024
  model,
7001
- method,
7002
7025
  ids,
7003
7026
  args,
7004
7027
  service,
@@ -7009,6 +7032,9 @@ var useManageOnChange = () => {
7009
7032
  };
7010
7033
  var use_manage_on_change_default = useManageOnChange;
7011
7034
 
7035
+ // src/hooks/view/use-gen-serial-number.ts
7036
+ var import_react_query82 = require("@tanstack/react-query");
7037
+
7012
7038
  // src/provider/service-provider.tsx
7013
7039
  var import_jsx_runtime6 = require("react/jsx-runtime");
7014
7040
  var ServiceContext = (0, import_react13.createContext)(null);
package/dist/provider.mjs CHANGED
@@ -3015,6 +3015,31 @@ function useActionService() {
3015
3015
  },
3016
3016
  [env]
3017
3017
  );
3018
+ const generateSerialNumber = useCallback(
3019
+ async ({
3020
+ kwargs,
3021
+ context,
3022
+ service,
3023
+ xNode
3024
+ }) => {
3025
+ const jsonData = {
3026
+ model: "stok.move",
3027
+ method: "action_generate_lot_line_vals",
3028
+ with_context: { ...context },
3029
+ kwargs
3030
+ };
3031
+ return env.requests.post(
3032
+ "/call" /* CALL_PATH */,
3033
+ jsonData,
3034
+ {
3035
+ headers: { "Content-Type": "application/json" },
3036
+ ...xNode ? { "X-Node": xNode } : {}
3037
+ },
3038
+ service
3039
+ );
3040
+ },
3041
+ [env]
3042
+ );
3018
3043
  return {
3019
3044
  loadAction,
3020
3045
  callButton,
@@ -3022,7 +3047,8 @@ function useActionService() {
3022
3047
  duplicateRecord,
3023
3048
  getPrintReportName,
3024
3049
  print,
3025
- runAction
3050
+ runAction,
3051
+ generateSerialNumber
3026
3052
  };
3027
3053
  }
3028
3054
 
@@ -4875,7 +4901,6 @@ function useViewService() {
4875
4901
  const manageOnChange = useCallback9(
4876
4902
  ({
4877
4903
  model,
4878
- method,
4879
4904
  ids,
4880
4905
  args,
4881
4906
  xNode,
@@ -4883,7 +4908,7 @@ function useViewService() {
4883
4908
  }) => {
4884
4909
  const jsonData = {
4885
4910
  model,
4886
- method,
4911
+ method: "onchange" /* ONCHANGE */,
4887
4912
  ids,
4888
4913
  args
4889
4914
  };
@@ -6950,12 +6975,10 @@ var useManageOnChange = () => {
6950
6975
  ids,
6951
6976
  args,
6952
6977
  service,
6953
- xNode,
6954
- method
6978
+ xNode
6955
6979
  }) => {
6956
6980
  return manageOnChange({
6957
6981
  model,
6958
- method,
6959
6982
  ids,
6960
6983
  args,
6961
6984
  service,
@@ -6966,6 +6989,9 @@ var useManageOnChange = () => {
6966
6989
  };
6967
6990
  var use_manage_on_change_default = useManageOnChange;
6968
6991
 
6992
+ // src/hooks/view/use-gen-serial-number.ts
6993
+ import { useMutation as useMutation60 } from "@tanstack/react-query";
6994
+
6969
6995
  // src/provider/service-provider.tsx
6970
6996
  import { jsx as jsx6 } from "react/jsx-runtime";
6971
6997
  var ServiceContext = createContext2(null);
@@ -43,6 +43,12 @@ declare function useActionService(): {
43
43
  service?: string;
44
44
  xNode?: string;
45
45
  }) => Promise<any>;
46
+ generateSerialNumber: ({ kwargs, context, service, xNode, }: {
47
+ kwargs: any;
48
+ context: ContextApi;
49
+ service?: string;
50
+ xNode?: string;
51
+ }) => Promise<any>;
46
52
  };
47
53
 
48
54
  declare function useAuthService(): {
@@ -350,9 +356,8 @@ declare function useViewService(): {
350
356
  service: string;
351
357
  xNode: string;
352
358
  }) => any;
353
- manageOnChange: ({ model, method, ids, args, xNode, service, }: {
359
+ manageOnChange: ({ model, ids, args, xNode, service, }: {
354
360
  model: string;
355
- method: string;
356
361
  ids: any;
357
362
  args: any;
358
363
  service: string;
@@ -43,6 +43,12 @@ declare function useActionService(): {
43
43
  service?: string;
44
44
  xNode?: string;
45
45
  }) => Promise<any>;
46
+ generateSerialNumber: ({ kwargs, context, service, xNode, }: {
47
+ kwargs: any;
48
+ context: ContextApi;
49
+ service?: string;
50
+ xNode?: string;
51
+ }) => Promise<any>;
46
52
  };
47
53
 
48
54
  declare function useAuthService(): {
@@ -350,9 +356,8 @@ declare function useViewService(): {
350
356
  service: string;
351
357
  xNode: string;
352
358
  }) => any;
353
- manageOnChange: ({ model, method, ids, args, xNode, service, }: {
359
+ manageOnChange: ({ model, ids, args, xNode, service, }: {
354
360
  model: string;
355
- method: string;
356
361
  ids: any;
357
362
  args: any;
358
363
  service: string;
package/dist/services.js CHANGED
@@ -3088,6 +3088,9 @@ var import_react_query80 = require("@tanstack/react-query");
3088
3088
  // src/hooks/view/use-manage-on-change.ts
3089
3089
  var import_react_query81 = require("@tanstack/react-query");
3090
3090
 
3091
+ // src/hooks/view/use-gen-serial-number.ts
3092
+ var import_react_query82 = require("@tanstack/react-query");
3093
+
3091
3094
  // src/provider/service-provider.tsx
3092
3095
  var import_jsx_runtime6 = require("react/jsx-runtime");
3093
3096
  var ServiceContext = (0, import_react4.createContext)(null);
@@ -3264,6 +3267,31 @@ function useActionService() {
3264
3267
  },
3265
3268
  [env]
3266
3269
  );
3270
+ const generateSerialNumber = (0, import_react6.useCallback)(
3271
+ async ({
3272
+ kwargs,
3273
+ context,
3274
+ service,
3275
+ xNode
3276
+ }) => {
3277
+ const jsonData = {
3278
+ model: "stok.move",
3279
+ method: "action_generate_lot_line_vals",
3280
+ with_context: { ...context },
3281
+ kwargs
3282
+ };
3283
+ return env.requests.post(
3284
+ "/call" /* CALL_PATH */,
3285
+ jsonData,
3286
+ {
3287
+ headers: { "Content-Type": "application/json" },
3288
+ ...xNode ? { "X-Node": xNode } : {}
3289
+ },
3290
+ service
3291
+ );
3292
+ },
3293
+ [env]
3294
+ );
3267
3295
  return {
3268
3296
  loadAction,
3269
3297
  callButton,
@@ -3271,7 +3299,8 @@ function useActionService() {
3271
3299
  duplicateRecord,
3272
3300
  getPrintReportName,
3273
3301
  print,
3274
- runAction
3302
+ runAction,
3303
+ generateSerialNumber
3275
3304
  };
3276
3305
  }
3277
3306
 
@@ -5124,7 +5153,6 @@ function useViewService() {
5124
5153
  const manageOnChange = (0, import_react14.useCallback)(
5125
5154
  ({
5126
5155
  model,
5127
- method,
5128
5156
  ids,
5129
5157
  args,
5130
5158
  xNode,
@@ -5132,7 +5160,7 @@ function useViewService() {
5132
5160
  }) => {
5133
5161
  const jsonData = {
5134
5162
  model,
5135
- method,
5163
+ method: "onchange" /* ONCHANGE */,
5136
5164
  ids,
5137
5165
  args
5138
5166
  };
package/dist/services.mjs CHANGED
@@ -3044,6 +3044,9 @@ import { useMutation as useMutation58 } from "@tanstack/react-query";
3044
3044
  // src/hooks/view/use-manage-on-change.ts
3045
3045
  import { useMutation as useMutation59 } from "@tanstack/react-query";
3046
3046
 
3047
+ // src/hooks/view/use-gen-serial-number.ts
3048
+ import { useMutation as useMutation60 } from "@tanstack/react-query";
3049
+
3047
3050
  // src/provider/service-provider.tsx
3048
3051
  import { jsx as jsx6 } from "react/jsx-runtime";
3049
3052
  var ServiceContext = createContext2(null);
@@ -3220,6 +3223,31 @@ function useActionService() {
3220
3223
  },
3221
3224
  [env]
3222
3225
  );
3226
+ const generateSerialNumber = useCallback2(
3227
+ async ({
3228
+ kwargs,
3229
+ context,
3230
+ service,
3231
+ xNode
3232
+ }) => {
3233
+ const jsonData = {
3234
+ model: "stok.move",
3235
+ method: "action_generate_lot_line_vals",
3236
+ with_context: { ...context },
3237
+ kwargs
3238
+ };
3239
+ return env.requests.post(
3240
+ "/call" /* CALL_PATH */,
3241
+ jsonData,
3242
+ {
3243
+ headers: { "Content-Type": "application/json" },
3244
+ ...xNode ? { "X-Node": xNode } : {}
3245
+ },
3246
+ service
3247
+ );
3248
+ },
3249
+ [env]
3250
+ );
3223
3251
  return {
3224
3252
  loadAction,
3225
3253
  callButton,
@@ -3227,7 +3255,8 @@ function useActionService() {
3227
3255
  duplicateRecord,
3228
3256
  getPrintReportName,
3229
3257
  print,
3230
- runAction
3258
+ runAction,
3259
+ generateSerialNumber
3231
3260
  };
3232
3261
  }
3233
3262
 
@@ -5080,7 +5109,6 @@ function useViewService() {
5080
5109
  const manageOnChange = useCallback10(
5081
5110
  ({
5082
5111
  model,
5083
- method,
5084
5112
  ids,
5085
5113
  args,
5086
5114
  xNode,
@@ -5088,7 +5116,7 @@ function useViewService() {
5088
5116
  }) => {
5089
5117
  const jsonData = {
5090
5118
  model,
5091
- method,
5119
+ method: "onchange" /* ONCHANGE */,
5092
5120
  ids,
5093
5121
  args
5094
5122
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fctc/interface-logic",
3
- "version": "2.7.7",
3
+ "version": "2.7.9",
4
4
  "types": "dist/index.d.ts",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.mjs",