@fctc/interface-logic 2.8.6 → 2.8.8
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/constants.d.mts +2 -1
- package/dist/constants.d.ts +2 -1
- package/dist/constants.js +1 -0
- package/dist/constants.mjs +1 -0
- package/dist/hooks.d.mts +18 -1
- package/dist/hooks.d.ts +18 -1
- package/dist/hooks.js +114 -1
- package/dist/hooks.mjs +112 -1
- package/dist/provider.d.mts +3 -1
- package/dist/provider.d.ts +3 -1
- package/dist/provider.js +113 -2
- package/dist/provider.mjs +113 -2
- package/dist/services.d.mts +15 -0
- package/dist/services.d.ts +15 -0
- package/dist/services.js +66 -1
- package/dist/services.mjs +66 -1
- package/package.json +1 -1
package/dist/constants.d.mts
CHANGED
|
@@ -53,7 +53,8 @@ declare enum UriConstants {
|
|
|
53
53
|
GRANT_ACCESS = "/grant-access",
|
|
54
54
|
TOKEN_BY_CODE = "/token",
|
|
55
55
|
LOGOUT = "/logout",
|
|
56
|
-
CREATE_UPDATE = "/create_update"
|
|
56
|
+
CREATE_UPDATE = "/create_update",
|
|
57
|
+
SEARCH_READ = "/search_read"
|
|
57
58
|
}
|
|
58
59
|
|
|
59
60
|
declare enum FieldTypeConstants {
|
package/dist/constants.d.ts
CHANGED
|
@@ -53,7 +53,8 @@ declare enum UriConstants {
|
|
|
53
53
|
GRANT_ACCESS = "/grant-access",
|
|
54
54
|
TOKEN_BY_CODE = "/token",
|
|
55
55
|
LOGOUT = "/logout",
|
|
56
|
-
CREATE_UPDATE = "/create_update"
|
|
56
|
+
CREATE_UPDATE = "/create_update",
|
|
57
|
+
SEARCH_READ = "/search_read"
|
|
57
58
|
}
|
|
58
59
|
|
|
59
60
|
declare enum FieldTypeConstants {
|
package/dist/constants.js
CHANGED
|
@@ -97,6 +97,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
97
97
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
98
98
|
UriConstants2["LOGOUT"] = "/logout";
|
|
99
99
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
100
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
100
101
|
return UriConstants2;
|
|
101
102
|
})(UriConstants || {});
|
|
102
103
|
|
package/dist/constants.mjs
CHANGED
|
@@ -59,6 +59,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
59
59
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
60
60
|
UriConstants2["LOGOUT"] = "/logout";
|
|
61
61
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
62
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
62
63
|
return UriConstants2;
|
|
63
64
|
})(UriConstants || {});
|
|
64
65
|
|
package/dist/hooks.d.mts
CHANGED
|
@@ -484,4 +484,21 @@ declare const useGetOrderLine: () => _tanstack_react_query.UseMutationResult<unk
|
|
|
484
484
|
xNode: string;
|
|
485
485
|
}, unknown>;
|
|
486
486
|
|
|
487
|
-
|
|
487
|
+
declare const useGetProductImage: () => _tanstack_react_query.UseMutationResult<unknown, Error, {
|
|
488
|
+
model: string;
|
|
489
|
+
fields: any;
|
|
490
|
+
limit: number;
|
|
491
|
+
offset: number;
|
|
492
|
+
domain: any;
|
|
493
|
+
service: string;
|
|
494
|
+
xNode: string;
|
|
495
|
+
}, unknown>;
|
|
496
|
+
|
|
497
|
+
declare const useAddEntity: () => _tanstack_react_query.UseMutationResult<unknown, Error, {
|
|
498
|
+
model: string;
|
|
499
|
+
values: any;
|
|
500
|
+
service: string;
|
|
501
|
+
xNode: string;
|
|
502
|
+
}, unknown>;
|
|
503
|
+
|
|
504
|
+
export { useAddEntity, useButton, useChangeStatus, useCreateEntity, useCreateSession, useDelete, useDeleteComment, useDeleteEntity, useDuplicateRecord, useExecuteImport, useExportExcel, useForgotPassword, useForgotPasswordSSO, useGenSerialNumber, useGet2FAMethods, useGetASession, useGetAccessByCode, useGetActionDetail, useGetAll, useGetCalendar, useGetComment, useGetCompanyInfo, useGetConversionRate, useGetCurrency, useGetCurrentCompany, useGetDetail, useGetFieldExport, useGetFieldOnChange, useGetFileExcel, useGetFormView, useGetGroups, useGetImage, useGetList, useGetListCompany, useGetListData, useGetListMyBankAccount, useGetMenu, useGetOrderLine, useGetPos, useGetPrintReport, useGetProGressBar, useGetProductImage, 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
|
@@ -484,4 +484,21 @@ declare const useGetOrderLine: () => _tanstack_react_query.UseMutationResult<unk
|
|
|
484
484
|
xNode: string;
|
|
485
485
|
}, unknown>;
|
|
486
486
|
|
|
487
|
-
|
|
487
|
+
declare const useGetProductImage: () => _tanstack_react_query.UseMutationResult<unknown, Error, {
|
|
488
|
+
model: string;
|
|
489
|
+
fields: any;
|
|
490
|
+
limit: number;
|
|
491
|
+
offset: number;
|
|
492
|
+
domain: any;
|
|
493
|
+
service: string;
|
|
494
|
+
xNode: string;
|
|
495
|
+
}, unknown>;
|
|
496
|
+
|
|
497
|
+
declare const useAddEntity: () => _tanstack_react_query.UseMutationResult<unknown, Error, {
|
|
498
|
+
model: string;
|
|
499
|
+
values: any;
|
|
500
|
+
service: string;
|
|
501
|
+
xNode: string;
|
|
502
|
+
}, unknown>;
|
|
503
|
+
|
|
504
|
+
export { useAddEntity, useButton, useChangeStatus, useCreateEntity, useCreateSession, useDelete, useDeleteComment, useDeleteEntity, useDuplicateRecord, useExecuteImport, useExportExcel, useForgotPassword, useForgotPasswordSSO, useGenSerialNumber, useGet2FAMethods, useGetASession, useGetAccessByCode, useGetActionDetail, useGetAll, useGetCalendar, useGetComment, useGetCompanyInfo, useGetConversionRate, useGetCurrency, useGetCurrentCompany, useGetDetail, useGetFieldExport, useGetFieldOnChange, useGetFileExcel, useGetFormView, useGetGroups, useGetImage, useGetList, useGetListCompany, useGetListData, useGetListMyBankAccount, useGetMenu, useGetOrderLine, useGetPos, useGetPrintReport, useGetProGressBar, useGetProductImage, 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
|
@@ -30,6 +30,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
30
30
|
// src/hooks.ts
|
|
31
31
|
var hooks_exports = {};
|
|
32
32
|
__export(hooks_exports, {
|
|
33
|
+
useAddEntity: () => use_add_entity_default,
|
|
33
34
|
useButton: () => use_button_default,
|
|
34
35
|
useChangeStatus: () => use_change_status_default,
|
|
35
36
|
useCreateEntity: () => use_create_entity_default,
|
|
@@ -70,6 +71,7 @@ __export(hooks_exports, {
|
|
|
70
71
|
useGetPos: () => use_get_pos_default,
|
|
71
72
|
useGetPrintReport: () => use_get_print_report_default,
|
|
72
73
|
useGetProGressBar: () => use_get_progress_bar_default,
|
|
74
|
+
useGetProductImage: () => use_get_product_image_default,
|
|
73
75
|
useGetProfile: () => use_get_profile_default,
|
|
74
76
|
useGetProvider: () => use_get_provider_default,
|
|
75
77
|
useGetResequence: () => use_resequence_default,
|
|
@@ -152,6 +154,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
152
154
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
153
155
|
UriConstants2["LOGOUT"] = "/logout";
|
|
154
156
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
157
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
155
158
|
return UriConstants2;
|
|
156
159
|
})(UriConstants || {});
|
|
157
160
|
|
|
@@ -4850,6 +4853,31 @@ function useViewService() {
|
|
|
4850
4853
|
},
|
|
4851
4854
|
[env]
|
|
4852
4855
|
);
|
|
4856
|
+
const addEntity = (0, import_react14.useCallback)(
|
|
4857
|
+
({
|
|
4858
|
+
model,
|
|
4859
|
+
values,
|
|
4860
|
+
xNode,
|
|
4861
|
+
service
|
|
4862
|
+
}) => {
|
|
4863
|
+
const jsonData = {
|
|
4864
|
+
model,
|
|
4865
|
+
values
|
|
4866
|
+
};
|
|
4867
|
+
return env?.requests.post(
|
|
4868
|
+
"/call" /* CALL_PATH */,
|
|
4869
|
+
jsonData,
|
|
4870
|
+
{
|
|
4871
|
+
headers: {
|
|
4872
|
+
"Content-Type": "application/json",
|
|
4873
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4874
|
+
}
|
|
4875
|
+
},
|
|
4876
|
+
service
|
|
4877
|
+
);
|
|
4878
|
+
},
|
|
4879
|
+
[env]
|
|
4880
|
+
);
|
|
4853
4881
|
const getList = (0, import_react14.useCallback)(
|
|
4854
4882
|
({
|
|
4855
4883
|
model,
|
|
@@ -5066,6 +5094,37 @@ function useViewService() {
|
|
|
5066
5094
|
},
|
|
5067
5095
|
[env]
|
|
5068
5096
|
);
|
|
5097
|
+
const getProductImage = (0, import_react14.useCallback)(
|
|
5098
|
+
({
|
|
5099
|
+
model,
|
|
5100
|
+
fields,
|
|
5101
|
+
limit,
|
|
5102
|
+
offset,
|
|
5103
|
+
domain,
|
|
5104
|
+
xNode,
|
|
5105
|
+
service
|
|
5106
|
+
}) => {
|
|
5107
|
+
const jsonData = {
|
|
5108
|
+
model,
|
|
5109
|
+
fields,
|
|
5110
|
+
limit,
|
|
5111
|
+
offset,
|
|
5112
|
+
domain
|
|
5113
|
+
};
|
|
5114
|
+
return env?.requests.post(
|
|
5115
|
+
"/search_read" /* SEARCH_READ */,
|
|
5116
|
+
jsonData,
|
|
5117
|
+
{
|
|
5118
|
+
headers: {
|
|
5119
|
+
"Content-Type": "application/json",
|
|
5120
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5121
|
+
}
|
|
5122
|
+
},
|
|
5123
|
+
service
|
|
5124
|
+
);
|
|
5125
|
+
},
|
|
5126
|
+
[env]
|
|
5127
|
+
);
|
|
5069
5128
|
return {
|
|
5070
5129
|
getView,
|
|
5071
5130
|
getMenu,
|
|
@@ -5094,7 +5153,9 @@ function useViewService() {
|
|
|
5094
5153
|
deleteEntity,
|
|
5095
5154
|
loadDataPosSession,
|
|
5096
5155
|
manageOnChange,
|
|
5097
|
-
getOrderLine
|
|
5156
|
+
getOrderLine,
|
|
5157
|
+
getProductImage,
|
|
5158
|
+
addEntity
|
|
5098
5159
|
};
|
|
5099
5160
|
}
|
|
5100
5161
|
|
|
@@ -6760,8 +6821,59 @@ var useGetOrderLine = () => {
|
|
|
6760
6821
|
});
|
|
6761
6822
|
};
|
|
6762
6823
|
var use_get_order_line_default = useGetOrderLine;
|
|
6824
|
+
|
|
6825
|
+
// src/hooks/view/use-get-product-image.ts
|
|
6826
|
+
var import_react_query84 = require("@tanstack/react-query");
|
|
6827
|
+
var useGetProductImage = () => {
|
|
6828
|
+
const { getProductImage } = useViewService();
|
|
6829
|
+
return (0, import_react_query84.useMutation)({
|
|
6830
|
+
mutationFn: ({
|
|
6831
|
+
model,
|
|
6832
|
+
fields,
|
|
6833
|
+
limit,
|
|
6834
|
+
offset,
|
|
6835
|
+
domain,
|
|
6836
|
+
xNode,
|
|
6837
|
+
service
|
|
6838
|
+
}) => {
|
|
6839
|
+
return getProductImage({
|
|
6840
|
+
model,
|
|
6841
|
+
fields,
|
|
6842
|
+
limit,
|
|
6843
|
+
offset,
|
|
6844
|
+
domain,
|
|
6845
|
+
xNode,
|
|
6846
|
+
service
|
|
6847
|
+
});
|
|
6848
|
+
}
|
|
6849
|
+
});
|
|
6850
|
+
};
|
|
6851
|
+
var use_get_product_image_default = useGetProductImage;
|
|
6852
|
+
|
|
6853
|
+
// src/hooks/view/use-add-entity.ts
|
|
6854
|
+
var import_react_query85 = require("@tanstack/react-query");
|
|
6855
|
+
var useAddEntity = () => {
|
|
6856
|
+
const { addEntity } = useViewService();
|
|
6857
|
+
return (0, import_react_query85.useMutation)({
|
|
6858
|
+
mutationFn: ({
|
|
6859
|
+
model,
|
|
6860
|
+
values,
|
|
6861
|
+
xNode,
|
|
6862
|
+
service
|
|
6863
|
+
}) => {
|
|
6864
|
+
return addEntity({
|
|
6865
|
+
model,
|
|
6866
|
+
values,
|
|
6867
|
+
xNode,
|
|
6868
|
+
service
|
|
6869
|
+
});
|
|
6870
|
+
}
|
|
6871
|
+
});
|
|
6872
|
+
};
|
|
6873
|
+
var use_add_entity_default = useAddEntity;
|
|
6763
6874
|
// Annotate the CommonJS export names for ESM import in node:
|
|
6764
6875
|
0 && (module.exports = {
|
|
6876
|
+
useAddEntity,
|
|
6765
6877
|
useButton,
|
|
6766
6878
|
useChangeStatus,
|
|
6767
6879
|
useCreateEntity,
|
|
@@ -6802,6 +6914,7 @@ var use_get_order_line_default = useGetOrderLine;
|
|
|
6802
6914
|
useGetPos,
|
|
6803
6915
|
useGetPrintReport,
|
|
6804
6916
|
useGetProGressBar,
|
|
6917
|
+
useGetProductImage,
|
|
6805
6918
|
useGetProfile,
|
|
6806
6919
|
useGetProvider,
|
|
6807
6920
|
useGetResequence,
|
package/dist/hooks.mjs
CHANGED
|
@@ -34,6 +34,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
34
34
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
35
35
|
UriConstants2["LOGOUT"] = "/logout";
|
|
36
36
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
37
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
37
38
|
return UriConstants2;
|
|
38
39
|
})(UriConstants || {});
|
|
39
40
|
|
|
@@ -4732,6 +4733,31 @@ function useViewService() {
|
|
|
4732
4733
|
},
|
|
4733
4734
|
[env]
|
|
4734
4735
|
);
|
|
4736
|
+
const addEntity = useCallback10(
|
|
4737
|
+
({
|
|
4738
|
+
model,
|
|
4739
|
+
values,
|
|
4740
|
+
xNode,
|
|
4741
|
+
service
|
|
4742
|
+
}) => {
|
|
4743
|
+
const jsonData = {
|
|
4744
|
+
model,
|
|
4745
|
+
values
|
|
4746
|
+
};
|
|
4747
|
+
return env?.requests.post(
|
|
4748
|
+
"/call" /* CALL_PATH */,
|
|
4749
|
+
jsonData,
|
|
4750
|
+
{
|
|
4751
|
+
headers: {
|
|
4752
|
+
"Content-Type": "application/json",
|
|
4753
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4754
|
+
}
|
|
4755
|
+
},
|
|
4756
|
+
service
|
|
4757
|
+
);
|
|
4758
|
+
},
|
|
4759
|
+
[env]
|
|
4760
|
+
);
|
|
4735
4761
|
const getList = useCallback10(
|
|
4736
4762
|
({
|
|
4737
4763
|
model,
|
|
@@ -4948,6 +4974,37 @@ function useViewService() {
|
|
|
4948
4974
|
},
|
|
4949
4975
|
[env]
|
|
4950
4976
|
);
|
|
4977
|
+
const getProductImage = useCallback10(
|
|
4978
|
+
({
|
|
4979
|
+
model,
|
|
4980
|
+
fields,
|
|
4981
|
+
limit,
|
|
4982
|
+
offset,
|
|
4983
|
+
domain,
|
|
4984
|
+
xNode,
|
|
4985
|
+
service
|
|
4986
|
+
}) => {
|
|
4987
|
+
const jsonData = {
|
|
4988
|
+
model,
|
|
4989
|
+
fields,
|
|
4990
|
+
limit,
|
|
4991
|
+
offset,
|
|
4992
|
+
domain
|
|
4993
|
+
};
|
|
4994
|
+
return env?.requests.post(
|
|
4995
|
+
"/search_read" /* SEARCH_READ */,
|
|
4996
|
+
jsonData,
|
|
4997
|
+
{
|
|
4998
|
+
headers: {
|
|
4999
|
+
"Content-Type": "application/json",
|
|
5000
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5001
|
+
}
|
|
5002
|
+
},
|
|
5003
|
+
service
|
|
5004
|
+
);
|
|
5005
|
+
},
|
|
5006
|
+
[env]
|
|
5007
|
+
);
|
|
4951
5008
|
return {
|
|
4952
5009
|
getView,
|
|
4953
5010
|
getMenu,
|
|
@@ -4976,7 +5033,9 @@ function useViewService() {
|
|
|
4976
5033
|
deleteEntity,
|
|
4977
5034
|
loadDataPosSession,
|
|
4978
5035
|
manageOnChange,
|
|
4979
|
-
getOrderLine
|
|
5036
|
+
getOrderLine,
|
|
5037
|
+
getProductImage,
|
|
5038
|
+
addEntity
|
|
4980
5039
|
};
|
|
4981
5040
|
}
|
|
4982
5041
|
|
|
@@ -6642,7 +6701,58 @@ var useGetOrderLine = () => {
|
|
|
6642
6701
|
});
|
|
6643
6702
|
};
|
|
6644
6703
|
var use_get_order_line_default = useGetOrderLine;
|
|
6704
|
+
|
|
6705
|
+
// src/hooks/view/use-get-product-image.ts
|
|
6706
|
+
import { useMutation as useMutation62 } from "@tanstack/react-query";
|
|
6707
|
+
var useGetProductImage = () => {
|
|
6708
|
+
const { getProductImage } = useViewService();
|
|
6709
|
+
return useMutation62({
|
|
6710
|
+
mutationFn: ({
|
|
6711
|
+
model,
|
|
6712
|
+
fields,
|
|
6713
|
+
limit,
|
|
6714
|
+
offset,
|
|
6715
|
+
domain,
|
|
6716
|
+
xNode,
|
|
6717
|
+
service
|
|
6718
|
+
}) => {
|
|
6719
|
+
return getProductImage({
|
|
6720
|
+
model,
|
|
6721
|
+
fields,
|
|
6722
|
+
limit,
|
|
6723
|
+
offset,
|
|
6724
|
+
domain,
|
|
6725
|
+
xNode,
|
|
6726
|
+
service
|
|
6727
|
+
});
|
|
6728
|
+
}
|
|
6729
|
+
});
|
|
6730
|
+
};
|
|
6731
|
+
var use_get_product_image_default = useGetProductImage;
|
|
6732
|
+
|
|
6733
|
+
// src/hooks/view/use-add-entity.ts
|
|
6734
|
+
import { useMutation as useMutation63 } from "@tanstack/react-query";
|
|
6735
|
+
var useAddEntity = () => {
|
|
6736
|
+
const { addEntity } = useViewService();
|
|
6737
|
+
return useMutation63({
|
|
6738
|
+
mutationFn: ({
|
|
6739
|
+
model,
|
|
6740
|
+
values,
|
|
6741
|
+
xNode,
|
|
6742
|
+
service
|
|
6743
|
+
}) => {
|
|
6744
|
+
return addEntity({
|
|
6745
|
+
model,
|
|
6746
|
+
values,
|
|
6747
|
+
xNode,
|
|
6748
|
+
service
|
|
6749
|
+
});
|
|
6750
|
+
}
|
|
6751
|
+
});
|
|
6752
|
+
};
|
|
6753
|
+
var use_add_entity_default = useAddEntity;
|
|
6645
6754
|
export {
|
|
6755
|
+
use_add_entity_default as useAddEntity,
|
|
6646
6756
|
use_button_default as useButton,
|
|
6647
6757
|
use_change_status_default as useChangeStatus,
|
|
6648
6758
|
use_create_entity_default as useCreateEntity,
|
|
@@ -6683,6 +6793,7 @@ export {
|
|
|
6683
6793
|
use_get_pos_default as useGetPos,
|
|
6684
6794
|
use_get_print_report_default as useGetPrintReport,
|
|
6685
6795
|
use_get_progress_bar_default as useGetProGressBar,
|
|
6796
|
+
use_get_product_image_default as useGetProductImage,
|
|
6686
6797
|
use_get_profile_default as useGetProfile,
|
|
6687
6798
|
use_get_provider_default as useGetProvider,
|
|
6688
6799
|
use_resequence_default as useGetResequence,
|
package/dist/provider.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
3
|
import { L as LocalStorageUtilsType, S as SessionStorageUtilsType } from './session-storage-ARp_lhTD.mjs';
|
|
4
|
-
import { useForgotPassword, useForgotPasswordSSO, useGetProvider, useIsValidToken, useLoginCredential, useLoginSocial, useResetPassword, useResetPasswordSSO, useUpdatePassword, useLogout, useGetAccessByCode, useValidateActionToken, useGetCompanyInfo, useGetCurrentCompany, useGetListCompany, useExecuteImport, useExportExcel, useGetFieldExport, useGetFileExcel, useParsePreview, useUploadFileExcel, useUploadIdFile, useChangeStatus, useDeleteComment, useGetComment, useGetFormView, useGetImage, useSendComment, useUploadImage, useDelete, useGetAll, useGetConversionRate, useGetCurrency, useGetDetail, useGetFieldOnChange, useGetListMyBankAccount, useModel, useOdooDataTransform, useOnChangeForm, useSave, useGetProfile, useGetUser, useSwitchLocale, useButton, useDuplicateRecord, useGet2FAMethods, useGetActionDetail, useGetCalendar, useGetGroups, useGetListData, useGetMenu, useGetPrintReport, useGetProGressBar, useGetResequence, useGetSelection, useGetView, useLoadAction, useLoadMessage, usePrint, useRemoveRow, useRunAction, useSignInSSO, useVerify2FA, useGrantAccess, useRemoveTotpSetup, useRequestSetupTotp, useSettingsWebRead2fa, useVerifyTotp, useUploadFile, useCreateEntity, useGetASession, useCreateSession, useDeleteEntity, useGetList, useGetPos, useHandleClosingSession, useManageSession, useUpdateClosedSession, useUpdateEntity, useLoadDataPosSession, useManageOnChange, useGenSerialNumber, useGetOrderLine } from './hooks.mjs';
|
|
4
|
+
import { useForgotPassword, useForgotPasswordSSO, useGetProvider, useIsValidToken, useLoginCredential, useLoginSocial, useResetPassword, useResetPasswordSSO, useUpdatePassword, useLogout, useGetAccessByCode, useValidateActionToken, useGetCompanyInfo, useGetCurrentCompany, useGetListCompany, useExecuteImport, useExportExcel, useGetFieldExport, useGetFileExcel, useParsePreview, useUploadFileExcel, useUploadIdFile, useChangeStatus, useDeleteComment, useGetComment, useGetFormView, useGetImage, useSendComment, useUploadImage, useDelete, useGetAll, useGetConversionRate, useGetCurrency, useGetDetail, useGetFieldOnChange, useGetListMyBankAccount, useModel, useOdooDataTransform, useOnChangeForm, useSave, useGetProfile, useGetUser, useSwitchLocale, useButton, useDuplicateRecord, useGet2FAMethods, useGetActionDetail, useGetCalendar, useGetGroups, useGetListData, useGetMenu, useGetPrintReport, useGetProGressBar, useGetResequence, useGetSelection, useGetView, useLoadAction, useLoadMessage, usePrint, useRemoveRow, useRunAction, useSignInSSO, useVerify2FA, useGrantAccess, useRemoveTotpSetup, useRequestSetupTotp, useSettingsWebRead2fa, useVerifyTotp, useUploadFile, useCreateEntity, useGetASession, useCreateSession, useDeleteEntity, useGetList, useGetPos, useHandleClosingSession, useManageSession, useUpdateClosedSession, useUpdateEntity, useLoadDataPosSession, useManageOnChange, useGenSerialNumber, useGetOrderLine, useGetProductImage, useAddEntity } from './hooks.mjs';
|
|
5
5
|
import '@tanstack/react-query';
|
|
6
6
|
import './view-type-xxw9OeSR.mjs';
|
|
7
7
|
import './base-model-type-DD8uZnDP.mjs';
|
|
@@ -147,6 +147,8 @@ interface ServiceContextType {
|
|
|
147
147
|
useManageOnChange: typeof useManageOnChange;
|
|
148
148
|
useGenSerialNumber: typeof useGenSerialNumber;
|
|
149
149
|
useGetOrderLine: typeof useGetOrderLine;
|
|
150
|
+
useGetProductImage: typeof useGetProductImage;
|
|
151
|
+
useAddEntity: typeof useAddEntity;
|
|
150
152
|
}
|
|
151
153
|
declare const ServiceProvider: ({ children, }: {
|
|
152
154
|
children: React.ReactNode;
|
package/dist/provider.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
3
|
import { L as LocalStorageUtilsType, S as SessionStorageUtilsType } from './session-storage-ARp_lhTD.js';
|
|
4
|
-
import { useForgotPassword, useForgotPasswordSSO, useGetProvider, useIsValidToken, useLoginCredential, useLoginSocial, useResetPassword, useResetPasswordSSO, useUpdatePassword, useLogout, useGetAccessByCode, useValidateActionToken, useGetCompanyInfo, useGetCurrentCompany, useGetListCompany, useExecuteImport, useExportExcel, useGetFieldExport, useGetFileExcel, useParsePreview, useUploadFileExcel, useUploadIdFile, useChangeStatus, useDeleteComment, useGetComment, useGetFormView, useGetImage, useSendComment, useUploadImage, useDelete, useGetAll, useGetConversionRate, useGetCurrency, useGetDetail, useGetFieldOnChange, useGetListMyBankAccount, useModel, useOdooDataTransform, useOnChangeForm, useSave, useGetProfile, useGetUser, useSwitchLocale, useButton, useDuplicateRecord, useGet2FAMethods, useGetActionDetail, useGetCalendar, useGetGroups, useGetListData, useGetMenu, useGetPrintReport, useGetProGressBar, useGetResequence, useGetSelection, useGetView, useLoadAction, useLoadMessage, usePrint, useRemoveRow, useRunAction, useSignInSSO, useVerify2FA, useGrantAccess, useRemoveTotpSetup, useRequestSetupTotp, useSettingsWebRead2fa, useVerifyTotp, useUploadFile, useCreateEntity, useGetASession, useCreateSession, useDeleteEntity, useGetList, useGetPos, useHandleClosingSession, useManageSession, useUpdateClosedSession, useUpdateEntity, useLoadDataPosSession, useManageOnChange, useGenSerialNumber, useGetOrderLine } from './hooks.js';
|
|
4
|
+
import { useForgotPassword, useForgotPasswordSSO, useGetProvider, useIsValidToken, useLoginCredential, useLoginSocial, useResetPassword, useResetPasswordSSO, useUpdatePassword, useLogout, useGetAccessByCode, useValidateActionToken, useGetCompanyInfo, useGetCurrentCompany, useGetListCompany, useExecuteImport, useExportExcel, useGetFieldExport, useGetFileExcel, useParsePreview, useUploadFileExcel, useUploadIdFile, useChangeStatus, useDeleteComment, useGetComment, useGetFormView, useGetImage, useSendComment, useUploadImage, useDelete, useGetAll, useGetConversionRate, useGetCurrency, useGetDetail, useGetFieldOnChange, useGetListMyBankAccount, useModel, useOdooDataTransform, useOnChangeForm, useSave, useGetProfile, useGetUser, useSwitchLocale, useButton, useDuplicateRecord, useGet2FAMethods, useGetActionDetail, useGetCalendar, useGetGroups, useGetListData, useGetMenu, useGetPrintReport, useGetProGressBar, useGetResequence, useGetSelection, useGetView, useLoadAction, useLoadMessage, usePrint, useRemoveRow, useRunAction, useSignInSSO, useVerify2FA, useGrantAccess, useRemoveTotpSetup, useRequestSetupTotp, useSettingsWebRead2fa, useVerifyTotp, useUploadFile, useCreateEntity, useGetASession, useCreateSession, useDeleteEntity, useGetList, useGetPos, useHandleClosingSession, useManageSession, useUpdateClosedSession, useUpdateEntity, useLoadDataPosSession, useManageOnChange, useGenSerialNumber, useGetOrderLine, useGetProductImage, useAddEntity } from './hooks.js';
|
|
5
5
|
import '@tanstack/react-query';
|
|
6
6
|
import './view-type-xxw9OeSR.js';
|
|
7
7
|
import './base-model-type-DD8uZnDP.js';
|
|
@@ -147,6 +147,8 @@ interface ServiceContextType {
|
|
|
147
147
|
useManageOnChange: typeof useManageOnChange;
|
|
148
148
|
useGenSerialNumber: typeof useGenSerialNumber;
|
|
149
149
|
useGetOrderLine: typeof useGetOrderLine;
|
|
150
|
+
useGetProductImage: typeof useGetProductImage;
|
|
151
|
+
useAddEntity: typeof useAddEntity;
|
|
150
152
|
}
|
|
151
153
|
declare const ServiceProvider: ({ children, }: {
|
|
152
154
|
children: React.ReactNode;
|
package/dist/provider.js
CHANGED
|
@@ -727,6 +727,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
727
727
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
728
728
|
UriConstants2["LOGOUT"] = "/logout";
|
|
729
729
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
730
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
730
731
|
return UriConstants2;
|
|
731
732
|
})(UriConstants || {});
|
|
732
733
|
|
|
@@ -4784,6 +4785,31 @@ function useViewService() {
|
|
|
4784
4785
|
},
|
|
4785
4786
|
[env]
|
|
4786
4787
|
);
|
|
4788
|
+
const addEntity = (0, import_react10.useCallback)(
|
|
4789
|
+
({
|
|
4790
|
+
model,
|
|
4791
|
+
values,
|
|
4792
|
+
xNode,
|
|
4793
|
+
service
|
|
4794
|
+
}) => {
|
|
4795
|
+
const jsonData = {
|
|
4796
|
+
model,
|
|
4797
|
+
values
|
|
4798
|
+
};
|
|
4799
|
+
return env?.requests.post(
|
|
4800
|
+
"/call" /* CALL_PATH */,
|
|
4801
|
+
jsonData,
|
|
4802
|
+
{
|
|
4803
|
+
headers: {
|
|
4804
|
+
"Content-Type": "application/json",
|
|
4805
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4806
|
+
}
|
|
4807
|
+
},
|
|
4808
|
+
service
|
|
4809
|
+
);
|
|
4810
|
+
},
|
|
4811
|
+
[env]
|
|
4812
|
+
);
|
|
4787
4813
|
const getList = (0, import_react10.useCallback)(
|
|
4788
4814
|
({
|
|
4789
4815
|
model,
|
|
@@ -5000,6 +5026,37 @@ function useViewService() {
|
|
|
5000
5026
|
},
|
|
5001
5027
|
[env]
|
|
5002
5028
|
);
|
|
5029
|
+
const getProductImage = (0, import_react10.useCallback)(
|
|
5030
|
+
({
|
|
5031
|
+
model,
|
|
5032
|
+
fields,
|
|
5033
|
+
limit,
|
|
5034
|
+
offset,
|
|
5035
|
+
domain,
|
|
5036
|
+
xNode,
|
|
5037
|
+
service
|
|
5038
|
+
}) => {
|
|
5039
|
+
const jsonData = {
|
|
5040
|
+
model,
|
|
5041
|
+
fields,
|
|
5042
|
+
limit,
|
|
5043
|
+
offset,
|
|
5044
|
+
domain
|
|
5045
|
+
};
|
|
5046
|
+
return env?.requests.post(
|
|
5047
|
+
"/search_read" /* SEARCH_READ */,
|
|
5048
|
+
jsonData,
|
|
5049
|
+
{
|
|
5050
|
+
headers: {
|
|
5051
|
+
"Content-Type": "application/json",
|
|
5052
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5053
|
+
}
|
|
5054
|
+
},
|
|
5055
|
+
service
|
|
5056
|
+
);
|
|
5057
|
+
},
|
|
5058
|
+
[env]
|
|
5059
|
+
);
|
|
5003
5060
|
return {
|
|
5004
5061
|
getView,
|
|
5005
5062
|
getMenu,
|
|
@@ -5028,7 +5085,9 @@ function useViewService() {
|
|
|
5028
5085
|
deleteEntity,
|
|
5029
5086
|
loadDataPosSession,
|
|
5030
5087
|
manageOnChange,
|
|
5031
|
-
getOrderLine
|
|
5088
|
+
getOrderLine,
|
|
5089
|
+
getProductImage,
|
|
5090
|
+
addEntity
|
|
5032
5091
|
};
|
|
5033
5092
|
}
|
|
5034
5093
|
|
|
@@ -7113,6 +7172,56 @@ var useGetOrderLine = () => {
|
|
|
7113
7172
|
};
|
|
7114
7173
|
var use_get_order_line_default = useGetOrderLine;
|
|
7115
7174
|
|
|
7175
|
+
// src/hooks/view/use-get-product-image.ts
|
|
7176
|
+
var import_react_query84 = require("@tanstack/react-query");
|
|
7177
|
+
var useGetProductImage = () => {
|
|
7178
|
+
const { getProductImage } = useViewService();
|
|
7179
|
+
return (0, import_react_query84.useMutation)({
|
|
7180
|
+
mutationFn: ({
|
|
7181
|
+
model,
|
|
7182
|
+
fields,
|
|
7183
|
+
limit,
|
|
7184
|
+
offset,
|
|
7185
|
+
domain,
|
|
7186
|
+
xNode,
|
|
7187
|
+
service
|
|
7188
|
+
}) => {
|
|
7189
|
+
return getProductImage({
|
|
7190
|
+
model,
|
|
7191
|
+
fields,
|
|
7192
|
+
limit,
|
|
7193
|
+
offset,
|
|
7194
|
+
domain,
|
|
7195
|
+
xNode,
|
|
7196
|
+
service
|
|
7197
|
+
});
|
|
7198
|
+
}
|
|
7199
|
+
});
|
|
7200
|
+
};
|
|
7201
|
+
var use_get_product_image_default = useGetProductImage;
|
|
7202
|
+
|
|
7203
|
+
// src/hooks/view/use-add-entity.ts
|
|
7204
|
+
var import_react_query85 = require("@tanstack/react-query");
|
|
7205
|
+
var useAddEntity = () => {
|
|
7206
|
+
const { addEntity } = useViewService();
|
|
7207
|
+
return (0, import_react_query85.useMutation)({
|
|
7208
|
+
mutationFn: ({
|
|
7209
|
+
model,
|
|
7210
|
+
values,
|
|
7211
|
+
xNode,
|
|
7212
|
+
service
|
|
7213
|
+
}) => {
|
|
7214
|
+
return addEntity({
|
|
7215
|
+
model,
|
|
7216
|
+
values,
|
|
7217
|
+
xNode,
|
|
7218
|
+
service
|
|
7219
|
+
});
|
|
7220
|
+
}
|
|
7221
|
+
});
|
|
7222
|
+
};
|
|
7223
|
+
var use_add_entity_default = useAddEntity;
|
|
7224
|
+
|
|
7116
7225
|
// src/provider/service-provider.tsx
|
|
7117
7226
|
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
7118
7227
|
var ServiceContext = (0, import_react13.createContext)(null);
|
|
@@ -7202,7 +7311,9 @@ var ServiceProvider = ({
|
|
|
7202
7311
|
useLoadDataPosSession: use_load_data_pos_session_default,
|
|
7203
7312
|
useManageOnChange: use_manage_on_change_default,
|
|
7204
7313
|
useGenSerialNumber: use_gen_serial_number_default,
|
|
7205
|
-
useGetOrderLine: use_get_order_line_default
|
|
7314
|
+
useGetOrderLine: use_get_order_line_default,
|
|
7315
|
+
useGetProductImage: use_get_product_image_default,
|
|
7316
|
+
useAddEntity: use_add_entity_default
|
|
7206
7317
|
};
|
|
7207
7318
|
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ServiceContext.Provider, { value: services, children });
|
|
7208
7319
|
};
|
package/dist/provider.mjs
CHANGED
|
@@ -684,6 +684,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
684
684
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
685
685
|
UriConstants2["LOGOUT"] = "/logout";
|
|
686
686
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
687
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
687
688
|
return UriConstants2;
|
|
688
689
|
})(UriConstants || {});
|
|
689
690
|
|
|
@@ -4741,6 +4742,31 @@ function useViewService() {
|
|
|
4741
4742
|
},
|
|
4742
4743
|
[env]
|
|
4743
4744
|
);
|
|
4745
|
+
const addEntity = useCallback9(
|
|
4746
|
+
({
|
|
4747
|
+
model,
|
|
4748
|
+
values,
|
|
4749
|
+
xNode,
|
|
4750
|
+
service
|
|
4751
|
+
}) => {
|
|
4752
|
+
const jsonData = {
|
|
4753
|
+
model,
|
|
4754
|
+
values
|
|
4755
|
+
};
|
|
4756
|
+
return env?.requests.post(
|
|
4757
|
+
"/call" /* CALL_PATH */,
|
|
4758
|
+
jsonData,
|
|
4759
|
+
{
|
|
4760
|
+
headers: {
|
|
4761
|
+
"Content-Type": "application/json",
|
|
4762
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4763
|
+
}
|
|
4764
|
+
},
|
|
4765
|
+
service
|
|
4766
|
+
);
|
|
4767
|
+
},
|
|
4768
|
+
[env]
|
|
4769
|
+
);
|
|
4744
4770
|
const getList = useCallback9(
|
|
4745
4771
|
({
|
|
4746
4772
|
model,
|
|
@@ -4957,6 +4983,37 @@ function useViewService() {
|
|
|
4957
4983
|
},
|
|
4958
4984
|
[env]
|
|
4959
4985
|
);
|
|
4986
|
+
const getProductImage = useCallback9(
|
|
4987
|
+
({
|
|
4988
|
+
model,
|
|
4989
|
+
fields,
|
|
4990
|
+
limit,
|
|
4991
|
+
offset,
|
|
4992
|
+
domain,
|
|
4993
|
+
xNode,
|
|
4994
|
+
service
|
|
4995
|
+
}) => {
|
|
4996
|
+
const jsonData = {
|
|
4997
|
+
model,
|
|
4998
|
+
fields,
|
|
4999
|
+
limit,
|
|
5000
|
+
offset,
|
|
5001
|
+
domain
|
|
5002
|
+
};
|
|
5003
|
+
return env?.requests.post(
|
|
5004
|
+
"/search_read" /* SEARCH_READ */,
|
|
5005
|
+
jsonData,
|
|
5006
|
+
{
|
|
5007
|
+
headers: {
|
|
5008
|
+
"Content-Type": "application/json",
|
|
5009
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5010
|
+
}
|
|
5011
|
+
},
|
|
5012
|
+
service
|
|
5013
|
+
);
|
|
5014
|
+
},
|
|
5015
|
+
[env]
|
|
5016
|
+
);
|
|
4960
5017
|
return {
|
|
4961
5018
|
getView,
|
|
4962
5019
|
getMenu,
|
|
@@ -4985,7 +5042,9 @@ function useViewService() {
|
|
|
4985
5042
|
deleteEntity,
|
|
4986
5043
|
loadDataPosSession,
|
|
4987
5044
|
manageOnChange,
|
|
4988
|
-
getOrderLine
|
|
5045
|
+
getOrderLine,
|
|
5046
|
+
getProductImage,
|
|
5047
|
+
addEntity
|
|
4989
5048
|
};
|
|
4990
5049
|
}
|
|
4991
5050
|
|
|
@@ -7070,6 +7129,56 @@ var useGetOrderLine = () => {
|
|
|
7070
7129
|
};
|
|
7071
7130
|
var use_get_order_line_default = useGetOrderLine;
|
|
7072
7131
|
|
|
7132
|
+
// src/hooks/view/use-get-product-image.ts
|
|
7133
|
+
import { useMutation as useMutation62 } from "@tanstack/react-query";
|
|
7134
|
+
var useGetProductImage = () => {
|
|
7135
|
+
const { getProductImage } = useViewService();
|
|
7136
|
+
return useMutation62({
|
|
7137
|
+
mutationFn: ({
|
|
7138
|
+
model,
|
|
7139
|
+
fields,
|
|
7140
|
+
limit,
|
|
7141
|
+
offset,
|
|
7142
|
+
domain,
|
|
7143
|
+
xNode,
|
|
7144
|
+
service
|
|
7145
|
+
}) => {
|
|
7146
|
+
return getProductImage({
|
|
7147
|
+
model,
|
|
7148
|
+
fields,
|
|
7149
|
+
limit,
|
|
7150
|
+
offset,
|
|
7151
|
+
domain,
|
|
7152
|
+
xNode,
|
|
7153
|
+
service
|
|
7154
|
+
});
|
|
7155
|
+
}
|
|
7156
|
+
});
|
|
7157
|
+
};
|
|
7158
|
+
var use_get_product_image_default = useGetProductImage;
|
|
7159
|
+
|
|
7160
|
+
// src/hooks/view/use-add-entity.ts
|
|
7161
|
+
import { useMutation as useMutation63 } from "@tanstack/react-query";
|
|
7162
|
+
var useAddEntity = () => {
|
|
7163
|
+
const { addEntity } = useViewService();
|
|
7164
|
+
return useMutation63({
|
|
7165
|
+
mutationFn: ({
|
|
7166
|
+
model,
|
|
7167
|
+
values,
|
|
7168
|
+
xNode,
|
|
7169
|
+
service
|
|
7170
|
+
}) => {
|
|
7171
|
+
return addEntity({
|
|
7172
|
+
model,
|
|
7173
|
+
values,
|
|
7174
|
+
xNode,
|
|
7175
|
+
service
|
|
7176
|
+
});
|
|
7177
|
+
}
|
|
7178
|
+
});
|
|
7179
|
+
};
|
|
7180
|
+
var use_add_entity_default = useAddEntity;
|
|
7181
|
+
|
|
7073
7182
|
// src/provider/service-provider.tsx
|
|
7074
7183
|
import { jsx as jsx6 } from "react/jsx-runtime";
|
|
7075
7184
|
var ServiceContext = createContext2(null);
|
|
@@ -7159,7 +7268,9 @@ var ServiceProvider = ({
|
|
|
7159
7268
|
useLoadDataPosSession: use_load_data_pos_session_default,
|
|
7160
7269
|
useManageOnChange: use_manage_on_change_default,
|
|
7161
7270
|
useGenSerialNumber: use_gen_serial_number_default,
|
|
7162
|
-
useGetOrderLine: use_get_order_line_default
|
|
7271
|
+
useGetOrderLine: use_get_order_line_default,
|
|
7272
|
+
useGetProductImage: use_get_product_image_default,
|
|
7273
|
+
useAddEntity: use_add_entity_default
|
|
7163
7274
|
};
|
|
7164
7275
|
return /* @__PURE__ */ jsx6(ServiceContext.Provider, { value: services, children });
|
|
7165
7276
|
};
|
package/dist/services.d.mts
CHANGED
|
@@ -371,6 +371,21 @@ declare function useViewService(): {
|
|
|
371
371
|
service: string;
|
|
372
372
|
xNode: string;
|
|
373
373
|
}) => any;
|
|
374
|
+
getProductImage: ({ model, fields, limit, offset, domain, xNode, service, }: {
|
|
375
|
+
model: string;
|
|
376
|
+
fields: any;
|
|
377
|
+
limit: number;
|
|
378
|
+
offset: number;
|
|
379
|
+
domain: any;
|
|
380
|
+
service: string;
|
|
381
|
+
xNode: string;
|
|
382
|
+
}) => any;
|
|
383
|
+
addEntity: ({ model, values, xNode, service, }: {
|
|
384
|
+
model: string;
|
|
385
|
+
values: any;
|
|
386
|
+
service: string;
|
|
387
|
+
xNode: string;
|
|
388
|
+
}) => any;
|
|
374
389
|
};
|
|
375
390
|
|
|
376
391
|
export { useActionService, useAuthService, useCompanyService, useExcelService, useFormService, useKanbanService, useModelService, useUserService, useViewService };
|
package/dist/services.d.ts
CHANGED
|
@@ -371,6 +371,21 @@ declare function useViewService(): {
|
|
|
371
371
|
service: string;
|
|
372
372
|
xNode: string;
|
|
373
373
|
}) => any;
|
|
374
|
+
getProductImage: ({ model, fields, limit, offset, domain, xNode, service, }: {
|
|
375
|
+
model: string;
|
|
376
|
+
fields: any;
|
|
377
|
+
limit: number;
|
|
378
|
+
offset: number;
|
|
379
|
+
domain: any;
|
|
380
|
+
service: string;
|
|
381
|
+
xNode: string;
|
|
382
|
+
}) => any;
|
|
383
|
+
addEntity: ({ model, values, xNode, service, }: {
|
|
384
|
+
model: string;
|
|
385
|
+
values: any;
|
|
386
|
+
service: string;
|
|
387
|
+
xNode: string;
|
|
388
|
+
}) => any;
|
|
374
389
|
};
|
|
375
390
|
|
|
376
391
|
export { useActionService, useAuthService, useCompanyService, useExcelService, useFormService, useKanbanService, useModelService, useUserService, useViewService };
|
package/dist/services.js
CHANGED
|
@@ -75,6 +75,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
75
75
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
76
76
|
UriConstants2["LOGOUT"] = "/logout";
|
|
77
77
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
78
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
78
79
|
return UriConstants2;
|
|
79
80
|
})(UriConstants || {});
|
|
80
81
|
|
|
@@ -3094,6 +3095,12 @@ var import_react_query82 = require("@tanstack/react-query");
|
|
|
3094
3095
|
// src/hooks/view/use-get-order-line.ts
|
|
3095
3096
|
var import_react_query83 = require("@tanstack/react-query");
|
|
3096
3097
|
|
|
3098
|
+
// src/hooks/view/use-get-product-image.ts
|
|
3099
|
+
var import_react_query84 = require("@tanstack/react-query");
|
|
3100
|
+
|
|
3101
|
+
// src/hooks/view/use-add-entity.ts
|
|
3102
|
+
var import_react_query85 = require("@tanstack/react-query");
|
|
3103
|
+
|
|
3097
3104
|
// src/provider/service-provider.tsx
|
|
3098
3105
|
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
3099
3106
|
var ServiceContext = (0, import_react4.createContext)(null);
|
|
@@ -4996,6 +5003,31 @@ function useViewService() {
|
|
|
4996
5003
|
},
|
|
4997
5004
|
[env]
|
|
4998
5005
|
);
|
|
5006
|
+
const addEntity = (0, import_react14.useCallback)(
|
|
5007
|
+
({
|
|
5008
|
+
model,
|
|
5009
|
+
values,
|
|
5010
|
+
xNode,
|
|
5011
|
+
service
|
|
5012
|
+
}) => {
|
|
5013
|
+
const jsonData = {
|
|
5014
|
+
model,
|
|
5015
|
+
values
|
|
5016
|
+
};
|
|
5017
|
+
return env?.requests.post(
|
|
5018
|
+
"/call" /* CALL_PATH */,
|
|
5019
|
+
jsonData,
|
|
5020
|
+
{
|
|
5021
|
+
headers: {
|
|
5022
|
+
"Content-Type": "application/json",
|
|
5023
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5024
|
+
}
|
|
5025
|
+
},
|
|
5026
|
+
service
|
|
5027
|
+
);
|
|
5028
|
+
},
|
|
5029
|
+
[env]
|
|
5030
|
+
);
|
|
4999
5031
|
const getList = (0, import_react14.useCallback)(
|
|
5000
5032
|
({
|
|
5001
5033
|
model,
|
|
@@ -5212,6 +5244,37 @@ function useViewService() {
|
|
|
5212
5244
|
},
|
|
5213
5245
|
[env]
|
|
5214
5246
|
);
|
|
5247
|
+
const getProductImage = (0, import_react14.useCallback)(
|
|
5248
|
+
({
|
|
5249
|
+
model,
|
|
5250
|
+
fields,
|
|
5251
|
+
limit,
|
|
5252
|
+
offset,
|
|
5253
|
+
domain,
|
|
5254
|
+
xNode,
|
|
5255
|
+
service
|
|
5256
|
+
}) => {
|
|
5257
|
+
const jsonData = {
|
|
5258
|
+
model,
|
|
5259
|
+
fields,
|
|
5260
|
+
limit,
|
|
5261
|
+
offset,
|
|
5262
|
+
domain
|
|
5263
|
+
};
|
|
5264
|
+
return env?.requests.post(
|
|
5265
|
+
"/search_read" /* SEARCH_READ */,
|
|
5266
|
+
jsonData,
|
|
5267
|
+
{
|
|
5268
|
+
headers: {
|
|
5269
|
+
"Content-Type": "application/json",
|
|
5270
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5271
|
+
}
|
|
5272
|
+
},
|
|
5273
|
+
service
|
|
5274
|
+
);
|
|
5275
|
+
},
|
|
5276
|
+
[env]
|
|
5277
|
+
);
|
|
5215
5278
|
return {
|
|
5216
5279
|
getView,
|
|
5217
5280
|
getMenu,
|
|
@@ -5240,7 +5303,9 @@ function useViewService() {
|
|
|
5240
5303
|
deleteEntity,
|
|
5241
5304
|
loadDataPosSession,
|
|
5242
5305
|
manageOnChange,
|
|
5243
|
-
getOrderLine
|
|
5306
|
+
getOrderLine,
|
|
5307
|
+
getProductImage,
|
|
5308
|
+
addEntity
|
|
5244
5309
|
};
|
|
5245
5310
|
}
|
|
5246
5311
|
// Annotate the CommonJS export names for ESM import in node:
|
package/dist/services.mjs
CHANGED
|
@@ -31,6 +31,7 @@ var UriConstants = /* @__PURE__ */ ((UriConstants2) => {
|
|
|
31
31
|
UriConstants2["TOKEN_BY_CODE"] = "/token";
|
|
32
32
|
UriConstants2["LOGOUT"] = "/logout";
|
|
33
33
|
UriConstants2["CREATE_UPDATE"] = "/create_update";
|
|
34
|
+
UriConstants2["SEARCH_READ"] = "/search_read";
|
|
34
35
|
return UriConstants2;
|
|
35
36
|
})(UriConstants || {});
|
|
36
37
|
|
|
@@ -3050,6 +3051,12 @@ import { useMutation as useMutation60 } from "@tanstack/react-query";
|
|
|
3050
3051
|
// src/hooks/view/use-get-order-line.ts
|
|
3051
3052
|
import { useMutation as useMutation61 } from "@tanstack/react-query";
|
|
3052
3053
|
|
|
3054
|
+
// src/hooks/view/use-get-product-image.ts
|
|
3055
|
+
import { useMutation as useMutation62 } from "@tanstack/react-query";
|
|
3056
|
+
|
|
3057
|
+
// src/hooks/view/use-add-entity.ts
|
|
3058
|
+
import { useMutation as useMutation63 } from "@tanstack/react-query";
|
|
3059
|
+
|
|
3053
3060
|
// src/provider/service-provider.tsx
|
|
3054
3061
|
import { jsx as jsx6 } from "react/jsx-runtime";
|
|
3055
3062
|
var ServiceContext = createContext2(null);
|
|
@@ -4952,6 +4959,31 @@ function useViewService() {
|
|
|
4952
4959
|
},
|
|
4953
4960
|
[env]
|
|
4954
4961
|
);
|
|
4962
|
+
const addEntity = useCallback10(
|
|
4963
|
+
({
|
|
4964
|
+
model,
|
|
4965
|
+
values,
|
|
4966
|
+
xNode,
|
|
4967
|
+
service
|
|
4968
|
+
}) => {
|
|
4969
|
+
const jsonData = {
|
|
4970
|
+
model,
|
|
4971
|
+
values
|
|
4972
|
+
};
|
|
4973
|
+
return env?.requests.post(
|
|
4974
|
+
"/call" /* CALL_PATH */,
|
|
4975
|
+
jsonData,
|
|
4976
|
+
{
|
|
4977
|
+
headers: {
|
|
4978
|
+
"Content-Type": "application/json",
|
|
4979
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4980
|
+
}
|
|
4981
|
+
},
|
|
4982
|
+
service
|
|
4983
|
+
);
|
|
4984
|
+
},
|
|
4985
|
+
[env]
|
|
4986
|
+
);
|
|
4955
4987
|
const getList = useCallback10(
|
|
4956
4988
|
({
|
|
4957
4989
|
model,
|
|
@@ -5168,6 +5200,37 @@ function useViewService() {
|
|
|
5168
5200
|
},
|
|
5169
5201
|
[env]
|
|
5170
5202
|
);
|
|
5203
|
+
const getProductImage = useCallback10(
|
|
5204
|
+
({
|
|
5205
|
+
model,
|
|
5206
|
+
fields,
|
|
5207
|
+
limit,
|
|
5208
|
+
offset,
|
|
5209
|
+
domain,
|
|
5210
|
+
xNode,
|
|
5211
|
+
service
|
|
5212
|
+
}) => {
|
|
5213
|
+
const jsonData = {
|
|
5214
|
+
model,
|
|
5215
|
+
fields,
|
|
5216
|
+
limit,
|
|
5217
|
+
offset,
|
|
5218
|
+
domain
|
|
5219
|
+
};
|
|
5220
|
+
return env?.requests.post(
|
|
5221
|
+
"/search_read" /* SEARCH_READ */,
|
|
5222
|
+
jsonData,
|
|
5223
|
+
{
|
|
5224
|
+
headers: {
|
|
5225
|
+
"Content-Type": "application/json",
|
|
5226
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5227
|
+
}
|
|
5228
|
+
},
|
|
5229
|
+
service
|
|
5230
|
+
);
|
|
5231
|
+
},
|
|
5232
|
+
[env]
|
|
5233
|
+
);
|
|
5171
5234
|
return {
|
|
5172
5235
|
getView,
|
|
5173
5236
|
getMenu,
|
|
@@ -5196,7 +5259,9 @@ function useViewService() {
|
|
|
5196
5259
|
deleteEntity,
|
|
5197
5260
|
loadDataPosSession,
|
|
5198
5261
|
manageOnChange,
|
|
5199
|
-
getOrderLine
|
|
5262
|
+
getOrderLine,
|
|
5263
|
+
getProductImage,
|
|
5264
|
+
addEntity
|
|
5200
5265
|
};
|
|
5201
5266
|
}
|
|
5202
5267
|
export {
|