@fctc/interface-logic 4.2.4 → 4.2.6
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 +128 -127
- package/dist/hooks.d.ts +128 -127
- package/dist/hooks.js +1066 -1224
- package/dist/hooks.mjs +1059 -1217
- package/dist/provider.d.mts +2 -2
- package/dist/provider.d.ts +2 -2
- package/dist/provider.js +1220 -1378
- package/dist/provider.mjs +1069 -1227
- package/dist/services.d.mts +166 -130
- package/dist/services.d.ts +166 -130
- package/dist/services.js +2259 -2012
- package/dist/services.mjs +2253 -2007
- package/package.json +1 -1
package/dist/provider.mjs
CHANGED
|
@@ -4905,7 +4905,216 @@ function useViewService() {
|
|
|
4905
4905
|
},
|
|
4906
4906
|
[env]
|
|
4907
4907
|
);
|
|
4908
|
-
const
|
|
4908
|
+
const getNotifications = useCallback9(
|
|
4909
|
+
async ({
|
|
4910
|
+
service,
|
|
4911
|
+
xNode,
|
|
4912
|
+
body
|
|
4913
|
+
}) => {
|
|
4914
|
+
return env?.requests?.post(
|
|
4915
|
+
`${"/mail/data" /* GET_NOTIFICATION */}`,
|
|
4916
|
+
body,
|
|
4917
|
+
{
|
|
4918
|
+
headers: {
|
|
4919
|
+
"Content-Type": "application/json",
|
|
4920
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4921
|
+
}
|
|
4922
|
+
},
|
|
4923
|
+
service
|
|
4924
|
+
);
|
|
4925
|
+
},
|
|
4926
|
+
[env]
|
|
4927
|
+
);
|
|
4928
|
+
const getCountry = useCallback9(
|
|
4929
|
+
async ({
|
|
4930
|
+
service,
|
|
4931
|
+
xNode,
|
|
4932
|
+
ids,
|
|
4933
|
+
kwargs
|
|
4934
|
+
}) => {
|
|
4935
|
+
const body = {
|
|
4936
|
+
model: "res.country" /* COUNTRY */,
|
|
4937
|
+
ids,
|
|
4938
|
+
method: "get_data_select" /* GET_DATA_SELECT */,
|
|
4939
|
+
kwargs
|
|
4940
|
+
};
|
|
4941
|
+
return env?.requests?.post(
|
|
4942
|
+
"/call" /* CALL_PATH */,
|
|
4943
|
+
body,
|
|
4944
|
+
{
|
|
4945
|
+
headers: {
|
|
4946
|
+
"Content-Type": "application/json",
|
|
4947
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4948
|
+
}
|
|
4949
|
+
},
|
|
4950
|
+
service
|
|
4951
|
+
);
|
|
4952
|
+
},
|
|
4953
|
+
[env]
|
|
4954
|
+
);
|
|
4955
|
+
const getCity = useCallback9(
|
|
4956
|
+
async ({
|
|
4957
|
+
service,
|
|
4958
|
+
xNode,
|
|
4959
|
+
ids,
|
|
4960
|
+
kwargs
|
|
4961
|
+
}) => {
|
|
4962
|
+
const body = {
|
|
4963
|
+
model: "res.country.state" /* COUNTRY_STATE */,
|
|
4964
|
+
ids,
|
|
4965
|
+
method: "get_data_select" /* GET_DATA_SELECT */,
|
|
4966
|
+
kwargs
|
|
4967
|
+
};
|
|
4968
|
+
return env?.requests?.post(
|
|
4969
|
+
"/call" /* CALL_PATH */,
|
|
4970
|
+
body,
|
|
4971
|
+
{
|
|
4972
|
+
headers: {
|
|
4973
|
+
"Content-Type": "application/json",
|
|
4974
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
4975
|
+
}
|
|
4976
|
+
},
|
|
4977
|
+
service
|
|
4978
|
+
);
|
|
4979
|
+
},
|
|
4980
|
+
[env]
|
|
4981
|
+
);
|
|
4982
|
+
const getWard = useCallback9(
|
|
4983
|
+
async ({
|
|
4984
|
+
service,
|
|
4985
|
+
xNode,
|
|
4986
|
+
kwargs
|
|
4987
|
+
}) => {
|
|
4988
|
+
const body = {
|
|
4989
|
+
model: "res.country.ward" /* COUNTRY_WARD */,
|
|
4990
|
+
method: "get_data_select" /* GET_DATA_SELECT */,
|
|
4991
|
+
kwargs
|
|
4992
|
+
};
|
|
4993
|
+
return env?.requests?.post(
|
|
4994
|
+
"/call" /* CALL_PATH */,
|
|
4995
|
+
body,
|
|
4996
|
+
{
|
|
4997
|
+
headers: {
|
|
4998
|
+
"Content-Type": "application/json",
|
|
4999
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5000
|
+
}
|
|
5001
|
+
},
|
|
5002
|
+
service
|
|
5003
|
+
);
|
|
5004
|
+
},
|
|
5005
|
+
[env]
|
|
5006
|
+
);
|
|
5007
|
+
const getPartnerTitle = useCallback9(
|
|
5008
|
+
async ({
|
|
5009
|
+
service,
|
|
5010
|
+
xNode,
|
|
5011
|
+
kwargs,
|
|
5012
|
+
withContext
|
|
5013
|
+
}) => {
|
|
5014
|
+
const body = {
|
|
5015
|
+
model: "res.partner.title" /* RES_PARTNER_TITLE */,
|
|
5016
|
+
method: "get_data_select" /* GET_DATA_SELECT */,
|
|
5017
|
+
kwargs,
|
|
5018
|
+
with_context: withContext
|
|
5019
|
+
};
|
|
5020
|
+
return env?.requests?.post(
|
|
5021
|
+
"/call" /* CALL_PATH */,
|
|
5022
|
+
body,
|
|
5023
|
+
{
|
|
5024
|
+
headers: {
|
|
5025
|
+
"Content-Type": "application/json",
|
|
5026
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5027
|
+
}
|
|
5028
|
+
},
|
|
5029
|
+
service
|
|
5030
|
+
);
|
|
5031
|
+
},
|
|
5032
|
+
[env]
|
|
5033
|
+
);
|
|
5034
|
+
return {
|
|
5035
|
+
getView,
|
|
5036
|
+
getMenu,
|
|
5037
|
+
getActionDetail,
|
|
5038
|
+
getResequence,
|
|
5039
|
+
getSelectionItem,
|
|
5040
|
+
loadMessages,
|
|
5041
|
+
getVersion,
|
|
5042
|
+
grantAccess,
|
|
5043
|
+
removeTotpSetUp,
|
|
5044
|
+
requestSetupTotp,
|
|
5045
|
+
settingsWebRead2fa,
|
|
5046
|
+
signInSSO,
|
|
5047
|
+
verify2FA,
|
|
5048
|
+
get2FAMethods,
|
|
5049
|
+
verifyTotp,
|
|
5050
|
+
getNotifications,
|
|
5051
|
+
getCountry,
|
|
5052
|
+
getCity,
|
|
5053
|
+
getWard,
|
|
5054
|
+
getPartnerTitle
|
|
5055
|
+
};
|
|
5056
|
+
}
|
|
5057
|
+
|
|
5058
|
+
// src/services/dashboard-service/index.ts
|
|
5059
|
+
import { useCallback as useCallback10 } from "react";
|
|
5060
|
+
function useDashboardService() {
|
|
5061
|
+
const { env } = useEnv();
|
|
5062
|
+
const readGroup = useCallback10(
|
|
5063
|
+
async ({
|
|
5064
|
+
service,
|
|
5065
|
+
xNode,
|
|
5066
|
+
body
|
|
5067
|
+
}) => {
|
|
5068
|
+
return env.requests.post(
|
|
5069
|
+
"/read_group" /* READ_GROUP */,
|
|
5070
|
+
body,
|
|
5071
|
+
{
|
|
5072
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
5073
|
+
},
|
|
5074
|
+
service
|
|
5075
|
+
);
|
|
5076
|
+
},
|
|
5077
|
+
[env]
|
|
5078
|
+
);
|
|
5079
|
+
const getDataChart = useCallback10(
|
|
5080
|
+
async ({
|
|
5081
|
+
service,
|
|
5082
|
+
xNode,
|
|
5083
|
+
body,
|
|
5084
|
+
path,
|
|
5085
|
+
method = "POST"
|
|
5086
|
+
}) => {
|
|
5087
|
+
const headers = {
|
|
5088
|
+
"Content-Type": "application/json",
|
|
5089
|
+
"X-Node": xNode
|
|
5090
|
+
};
|
|
5091
|
+
if (method === "GET") {
|
|
5092
|
+
return env.requests.get(
|
|
5093
|
+
path,
|
|
5094
|
+
{
|
|
5095
|
+
headers
|
|
5096
|
+
},
|
|
5097
|
+
service
|
|
5098
|
+
);
|
|
5099
|
+
}
|
|
5100
|
+
return env.requests.post(
|
|
5101
|
+
path,
|
|
5102
|
+
body,
|
|
5103
|
+
{
|
|
5104
|
+
headers
|
|
5105
|
+
},
|
|
5106
|
+
service
|
|
5107
|
+
);
|
|
5108
|
+
},
|
|
5109
|
+
[env]
|
|
5110
|
+
);
|
|
5111
|
+
return { readGroup, getDataChart };
|
|
5112
|
+
}
|
|
5113
|
+
|
|
5114
|
+
// src/services/pos-service/get-a-session.ts
|
|
5115
|
+
import { useCallback as useCallback11 } from "react";
|
|
5116
|
+
var getASessionService = (env) => {
|
|
5117
|
+
const getASession = useCallback11(
|
|
4909
5118
|
async ({
|
|
4910
5119
|
model,
|
|
4911
5120
|
args,
|
|
@@ -4948,21 +5157,28 @@ function useViewService() {
|
|
|
4948
5157
|
},
|
|
4949
5158
|
[env]
|
|
4950
5159
|
);
|
|
4951
|
-
|
|
5160
|
+
return {
|
|
5161
|
+
getASession
|
|
5162
|
+
};
|
|
5163
|
+
};
|
|
5164
|
+
|
|
5165
|
+
// src/services/pos-service/add-entity.ts
|
|
5166
|
+
import { useCallback as useCallback12 } from "react";
|
|
5167
|
+
var addEntityService = (env) => {
|
|
5168
|
+
const addEntity = useCallback12(
|
|
4952
5169
|
({
|
|
4953
5170
|
model,
|
|
4954
|
-
domain,
|
|
4955
5171
|
values,
|
|
5172
|
+
xNode,
|
|
4956
5173
|
service,
|
|
4957
|
-
|
|
5174
|
+
isCreateEndpoint = false
|
|
4958
5175
|
}) => {
|
|
4959
5176
|
const jsonData = {
|
|
4960
5177
|
model,
|
|
4961
|
-
domain,
|
|
4962
5178
|
values
|
|
4963
5179
|
};
|
|
4964
5180
|
return env?.requests.post(
|
|
4965
|
-
"/
|
|
5181
|
+
isCreateEndpoint ? "/create" /* CREATE_PATH */ : "/call" /* CALL_PATH */,
|
|
4966
5182
|
jsonData,
|
|
4967
5183
|
{
|
|
4968
5184
|
headers: {
|
|
@@ -4975,22 +5191,30 @@ function useViewService() {
|
|
|
4975
5191
|
},
|
|
4976
5192
|
[env]
|
|
4977
5193
|
);
|
|
4978
|
-
|
|
5194
|
+
return {
|
|
5195
|
+
addEntity
|
|
5196
|
+
};
|
|
5197
|
+
};
|
|
5198
|
+
|
|
5199
|
+
// src/services/pos-service/change-order-preparation-state.ts
|
|
5200
|
+
import { useCallback as useCallback13 } from "react";
|
|
5201
|
+
var changOrderPreparationStateService = (env) => {
|
|
5202
|
+
const changeOrderPreparationState = useCallback13(
|
|
4979
5203
|
({
|
|
4980
|
-
|
|
4981
|
-
|
|
4982
|
-
|
|
4983
|
-
args,
|
|
4984
|
-
kwargs,
|
|
5204
|
+
orderId,
|
|
5205
|
+
stageId,
|
|
5206
|
+
preparationDisplayId,
|
|
4985
5207
|
xNode,
|
|
4986
5208
|
service
|
|
4987
5209
|
}) => {
|
|
4988
5210
|
const jsonData = {
|
|
4989
|
-
model
|
|
4990
|
-
method
|
|
4991
|
-
ids,
|
|
4992
|
-
|
|
4993
|
-
|
|
5211
|
+
model: "pos_preparation_display.order" /* POS_PREPARATION_ORDER */,
|
|
5212
|
+
method: "change_order_stage" /* CHANGE_ORDER_STAGE */,
|
|
5213
|
+
ids: orderId,
|
|
5214
|
+
kwargs: {
|
|
5215
|
+
stage_id: stageId,
|
|
5216
|
+
preparation_display_id: preparationDisplayId
|
|
5217
|
+
}
|
|
4994
5218
|
};
|
|
4995
5219
|
return env?.requests.post(
|
|
4996
5220
|
"/call" /* CALL_PATH */,
|
|
@@ -5006,20 +5230,27 @@ function useViewService() {
|
|
|
5006
5230
|
},
|
|
5007
5231
|
[env]
|
|
5008
5232
|
);
|
|
5009
|
-
|
|
5233
|
+
return {
|
|
5234
|
+
changeOrderPreparationState
|
|
5235
|
+
};
|
|
5236
|
+
};
|
|
5237
|
+
|
|
5238
|
+
// src/services/pos-service/check-payment.ts
|
|
5239
|
+
import { useCallback as useCallback14 } from "react";
|
|
5240
|
+
var checkPaymentService = (env) => {
|
|
5241
|
+
const checkPayment = useCallback14(
|
|
5010
5242
|
({
|
|
5011
5243
|
model,
|
|
5012
|
-
method,
|
|
5013
5244
|
ids,
|
|
5014
|
-
|
|
5245
|
+
withContext,
|
|
5015
5246
|
xNode,
|
|
5016
5247
|
service
|
|
5017
5248
|
}) => {
|
|
5018
5249
|
const jsonData = {
|
|
5019
5250
|
model,
|
|
5020
|
-
method
|
|
5251
|
+
method: "check" /* CHECK */,
|
|
5021
5252
|
ids,
|
|
5022
|
-
|
|
5253
|
+
with_context: withContext
|
|
5023
5254
|
};
|
|
5024
5255
|
return env?.requests.post(
|
|
5025
5256
|
"/call" /* CALL_PATH */,
|
|
@@ -5035,25 +5266,32 @@ function useViewService() {
|
|
|
5035
5266
|
},
|
|
5036
5267
|
[env]
|
|
5037
5268
|
);
|
|
5038
|
-
|
|
5039
|
-
|
|
5040
|
-
|
|
5041
|
-
|
|
5269
|
+
return {
|
|
5270
|
+
checkPayment
|
|
5271
|
+
};
|
|
5272
|
+
};
|
|
5273
|
+
|
|
5274
|
+
// src/services/pos-service/create-e-invoice.ts
|
|
5275
|
+
import { useCallback as useCallback15 } from "react";
|
|
5276
|
+
var createEInvoiceService = (env) => {
|
|
5277
|
+
const createEInvoice = useCallback15(
|
|
5278
|
+
async ({
|
|
5279
|
+
service,
|
|
5042
5280
|
xNode,
|
|
5043
|
-
|
|
5281
|
+
kwargs,
|
|
5282
|
+
ids,
|
|
5283
|
+
withContext
|
|
5044
5284
|
}) => {
|
|
5045
|
-
const
|
|
5046
|
-
model
|
|
5047
|
-
method: "
|
|
5048
|
-
|
|
5049
|
-
|
|
5050
|
-
|
|
5051
|
-
}
|
|
5052
|
-
]
|
|
5285
|
+
const body = {
|
|
5286
|
+
model: "pos.order" /* POS_ORDER */,
|
|
5287
|
+
method: "create_e_invoice" /* CREATE_E_INVOICE */,
|
|
5288
|
+
kwargs,
|
|
5289
|
+
ids,
|
|
5290
|
+
with_context: withContext
|
|
5053
5291
|
};
|
|
5054
|
-
return env?.requests
|
|
5055
|
-
"/call" /* CALL_PATH
|
|
5056
|
-
|
|
5292
|
+
return env?.requests?.post(
|
|
5293
|
+
`${"/call" /* CALL_PATH */}`,
|
|
5294
|
+
body,
|
|
5057
5295
|
{
|
|
5058
5296
|
headers: {
|
|
5059
5297
|
"Content-Type": "application/json",
|
|
@@ -5065,49 +5303,25 @@ function useViewService() {
|
|
|
5065
5303
|
},
|
|
5066
5304
|
[env]
|
|
5067
5305
|
);
|
|
5068
|
-
|
|
5306
|
+
return {
|
|
5307
|
+
createEInvoice
|
|
5308
|
+
};
|
|
5309
|
+
};
|
|
5310
|
+
|
|
5311
|
+
// src/services/pos-service/create-entity.ts
|
|
5312
|
+
import { useCallback as useCallback16 } from "react";
|
|
5313
|
+
var createEntityService = (env) => {
|
|
5314
|
+
const createEntity = useCallback16(
|
|
5069
5315
|
({
|
|
5070
5316
|
model,
|
|
5071
5317
|
args,
|
|
5072
|
-
domain,
|
|
5073
5318
|
xNode,
|
|
5074
5319
|
service
|
|
5075
5320
|
}) => {
|
|
5076
5321
|
const jsonData = {
|
|
5077
5322
|
model,
|
|
5078
|
-
method: "
|
|
5079
|
-
args
|
|
5080
|
-
kwargs: {
|
|
5081
|
-
domain,
|
|
5082
|
-
specification: {
|
|
5083
|
-
cash_control: {},
|
|
5084
|
-
current_session_id: {
|
|
5085
|
-
fields: {
|
|
5086
|
-
display_name: {}
|
|
5087
|
-
}
|
|
5088
|
-
},
|
|
5089
|
-
current_session_state: {},
|
|
5090
|
-
pos_session_state: {},
|
|
5091
|
-
pos_session_duration: {},
|
|
5092
|
-
currency_id: {
|
|
5093
|
-
fields: {
|
|
5094
|
-
display_name: {}
|
|
5095
|
-
}
|
|
5096
|
-
},
|
|
5097
|
-
name: {},
|
|
5098
|
-
pos_session_username: {},
|
|
5099
|
-
last_session_closing_date: {},
|
|
5100
|
-
last_session_closing_cash: {},
|
|
5101
|
-
number_of_rescue_session: {},
|
|
5102
|
-
current_user_id: {
|
|
5103
|
-
fields: {
|
|
5104
|
-
display_name: {}
|
|
5105
|
-
}
|
|
5106
|
-
},
|
|
5107
|
-
customer_display_type: {},
|
|
5108
|
-
module_pos_restaurant: {}
|
|
5109
|
-
}
|
|
5110
|
-
}
|
|
5323
|
+
method: "create" /* CREATE */,
|
|
5324
|
+
args
|
|
5111
5325
|
};
|
|
5112
5326
|
return env?.requests.post(
|
|
5113
5327
|
"/call" /* CALL_PATH */,
|
|
@@ -5123,20 +5337,31 @@ function useViewService() {
|
|
|
5123
5337
|
},
|
|
5124
5338
|
[env]
|
|
5125
5339
|
);
|
|
5126
|
-
|
|
5340
|
+
return {
|
|
5341
|
+
createEntity
|
|
5342
|
+
};
|
|
5343
|
+
};
|
|
5344
|
+
|
|
5345
|
+
// src/services/pos-service/create-pos-config.ts
|
|
5346
|
+
import { useCallback as useCallback17 } from "react";
|
|
5347
|
+
var createPosConfigService = (env) => {
|
|
5348
|
+
const createPosConfig = useCallback17(
|
|
5127
5349
|
({
|
|
5128
5350
|
model,
|
|
5129
|
-
|
|
5351
|
+
name,
|
|
5352
|
+
modulePosRestaurant,
|
|
5130
5353
|
xNode,
|
|
5131
5354
|
service
|
|
5132
5355
|
}) => {
|
|
5133
5356
|
const jsonData = {
|
|
5134
5357
|
model,
|
|
5135
|
-
|
|
5136
|
-
|
|
5358
|
+
values: {
|
|
5359
|
+
name,
|
|
5360
|
+
module_pos_restaurant: modulePosRestaurant
|
|
5361
|
+
}
|
|
5137
5362
|
};
|
|
5138
5363
|
return env?.requests.post(
|
|
5139
|
-
"/
|
|
5364
|
+
"/create" /* CREATE_PATH */,
|
|
5140
5365
|
jsonData,
|
|
5141
5366
|
{
|
|
5142
5367
|
headers: {
|
|
@@ -5149,20 +5374,32 @@ function useViewService() {
|
|
|
5149
5374
|
},
|
|
5150
5375
|
[env]
|
|
5151
5376
|
);
|
|
5152
|
-
|
|
5377
|
+
return {
|
|
5378
|
+
createPosConfig
|
|
5379
|
+
};
|
|
5380
|
+
};
|
|
5381
|
+
|
|
5382
|
+
// src/services/pos-service/create-session.ts
|
|
5383
|
+
import { useCallback as useCallback18 } from "react";
|
|
5384
|
+
var createSessionService = (env) => {
|
|
5385
|
+
const createSession = useCallback18(
|
|
5153
5386
|
({
|
|
5154
5387
|
model,
|
|
5155
|
-
|
|
5388
|
+
configId,
|
|
5156
5389
|
xNode,
|
|
5157
|
-
service
|
|
5158
|
-
isCreateEndpoint = false
|
|
5390
|
+
service
|
|
5159
5391
|
}) => {
|
|
5160
5392
|
const jsonData = {
|
|
5161
5393
|
model,
|
|
5162
|
-
|
|
5394
|
+
method: "create" /* CREATE */,
|
|
5395
|
+
args: [
|
|
5396
|
+
{
|
|
5397
|
+
config_id: configId
|
|
5398
|
+
}
|
|
5399
|
+
]
|
|
5163
5400
|
};
|
|
5164
5401
|
return env?.requests.post(
|
|
5165
|
-
|
|
5402
|
+
"/call" /* CALL_PATH */,
|
|
5166
5403
|
jsonData,
|
|
5167
5404
|
{
|
|
5168
5405
|
headers: {
|
|
@@ -5175,25 +5412,26 @@ function useViewService() {
|
|
|
5175
5412
|
},
|
|
5176
5413
|
[env]
|
|
5177
5414
|
);
|
|
5178
|
-
|
|
5415
|
+
return {
|
|
5416
|
+
createSession
|
|
5417
|
+
};
|
|
5418
|
+
};
|
|
5419
|
+
|
|
5420
|
+
// src/services/pos-service/delete-entity.ts
|
|
5421
|
+
import { useCallback as useCallback19 } from "react";
|
|
5422
|
+
var deleteEntityService = (env) => {
|
|
5423
|
+
const deleteEntity = useCallback19(
|
|
5179
5424
|
({
|
|
5180
5425
|
model,
|
|
5181
|
-
|
|
5426
|
+
ids,
|
|
5182
5427
|
xNode,
|
|
5183
5428
|
service,
|
|
5184
|
-
|
|
5185
|
-
offset,
|
|
5186
|
-
limit
|
|
5429
|
+
method
|
|
5187
5430
|
}) => {
|
|
5188
5431
|
const jsonData = {
|
|
5189
5432
|
model,
|
|
5190
|
-
|
|
5191
|
-
|
|
5192
|
-
domain,
|
|
5193
|
-
offset,
|
|
5194
|
-
limit,
|
|
5195
|
-
specification
|
|
5196
|
-
})
|
|
5433
|
+
ids,
|
|
5434
|
+
method
|
|
5197
5435
|
};
|
|
5198
5436
|
return env?.requests.post(
|
|
5199
5437
|
"/call" /* CALL_PATH */,
|
|
@@ -5209,22 +5447,29 @@ function useViewService() {
|
|
|
5209
5447
|
},
|
|
5210
5448
|
[env]
|
|
5211
5449
|
);
|
|
5212
|
-
|
|
5450
|
+
return {
|
|
5451
|
+
deleteEntity
|
|
5452
|
+
};
|
|
5453
|
+
};
|
|
5454
|
+
|
|
5455
|
+
// src/services/pos-service/generate-payment-qr-info.ts
|
|
5456
|
+
import { useCallback as useCallback20 } from "react";
|
|
5457
|
+
var generatePaymentQrInfoService = (env) => {
|
|
5458
|
+
const generatePaymentQRInfo = useCallback20(
|
|
5213
5459
|
({
|
|
5214
|
-
|
|
5215
|
-
|
|
5216
|
-
|
|
5217
|
-
isCreateEndpoint = true,
|
|
5460
|
+
orderId,
|
|
5461
|
+
amount,
|
|
5462
|
+
posSessionId,
|
|
5218
5463
|
xNode,
|
|
5219
5464
|
service
|
|
5220
5465
|
}) => {
|
|
5221
5466
|
const jsonData = {
|
|
5222
|
-
|
|
5223
|
-
|
|
5224
|
-
|
|
5467
|
+
order_id: orderId,
|
|
5468
|
+
amount,
|
|
5469
|
+
pos_session_id: posSessionId
|
|
5225
5470
|
};
|
|
5226
5471
|
return env?.requests.post(
|
|
5227
|
-
|
|
5472
|
+
"/payment/qr" /* PAYMENT_QR */,
|
|
5228
5473
|
jsonData,
|
|
5229
5474
|
{
|
|
5230
5475
|
headers: {
|
|
@@ -5237,24 +5482,29 @@ function useViewService() {
|
|
|
5237
5482
|
},
|
|
5238
5483
|
[env]
|
|
5239
5484
|
);
|
|
5240
|
-
|
|
5241
|
-
|
|
5242
|
-
|
|
5243
|
-
|
|
5244
|
-
|
|
5485
|
+
return {
|
|
5486
|
+
generatePaymentQRInfo
|
|
5487
|
+
};
|
|
5488
|
+
};
|
|
5489
|
+
|
|
5490
|
+
// src/services/pos-service/get-current-user.ts
|
|
5491
|
+
import { useCallback as useCallback21 } from "react";
|
|
5492
|
+
var getCurrentUserService = (env) => {
|
|
5493
|
+
const getCurrentUser = useCallback21(
|
|
5494
|
+
async ({
|
|
5245
5495
|
service,
|
|
5246
|
-
|
|
5496
|
+
xNode,
|
|
5497
|
+
oauthUid,
|
|
5498
|
+
extraHeaders
|
|
5247
5499
|
}) => {
|
|
5248
|
-
|
|
5249
|
-
|
|
5250
|
-
ids,
|
|
5251
|
-
method
|
|
5252
|
-
};
|
|
5253
|
-
return env?.requests.post(
|
|
5254
|
-
"/call" /* CALL_PATH */,
|
|
5255
|
-
jsonData,
|
|
5500
|
+
return env?.requests?.get(
|
|
5501
|
+
`${"/public/user/info" /* PUBLIC_USER_INFO */}/${oauthUid}`,
|
|
5256
5502
|
{
|
|
5257
|
-
headers: {
|
|
5503
|
+
headers: extraHeaders ? {
|
|
5504
|
+
...extraHeaders,
|
|
5505
|
+
"Content-Type": "application/json",
|
|
5506
|
+
...xNode ? { "X-Node": xNode } : {}
|
|
5507
|
+
} : {
|
|
5258
5508
|
"Content-Type": "application/json",
|
|
5259
5509
|
...xNode ? { "X-Node": xNode } : {}
|
|
5260
5510
|
}
|
|
@@ -5264,32 +5514,36 @@ function useViewService() {
|
|
|
5264
5514
|
},
|
|
5265
5515
|
[env]
|
|
5266
5516
|
);
|
|
5267
|
-
|
|
5517
|
+
return {
|
|
5518
|
+
getCurrentUser
|
|
5519
|
+
};
|
|
5520
|
+
};
|
|
5521
|
+
|
|
5522
|
+
// src/services/pos-service/get-list.ts
|
|
5523
|
+
import { useCallback as useCallback22 } from "react";
|
|
5524
|
+
var getListService = (env) => {
|
|
5525
|
+
const getList = useCallback22(
|
|
5268
5526
|
({
|
|
5269
5527
|
model,
|
|
5270
|
-
|
|
5528
|
+
domain,
|
|
5271
5529
|
xNode,
|
|
5272
5530
|
service,
|
|
5273
|
-
|
|
5274
|
-
|
|
5275
|
-
|
|
5531
|
+
specification,
|
|
5532
|
+
offset,
|
|
5533
|
+
limit
|
|
5276
5534
|
}) => {
|
|
5277
5535
|
const jsonData = {
|
|
5278
5536
|
model,
|
|
5279
|
-
method: "
|
|
5280
|
-
|
|
5281
|
-
|
|
5282
|
-
|
|
5283
|
-
|
|
5284
|
-
|
|
5285
|
-
}
|
|
5286
|
-
kwargs: {
|
|
5287
|
-
models_to_load: modelsToLoad
|
|
5288
|
-
}
|
|
5537
|
+
method: "web_search_read" /* WEB_SEARCH_READ */,
|
|
5538
|
+
kwargs: cleanObject({
|
|
5539
|
+
domain,
|
|
5540
|
+
offset,
|
|
5541
|
+
limit,
|
|
5542
|
+
specification
|
|
5543
|
+
})
|
|
5289
5544
|
};
|
|
5290
|
-
const url = searchParams ? `${"/call" /* CALL_PATH */}?${toQueryString(searchParams)}` : "/call" /* CALL_PATH */;
|
|
5291
5545
|
return env?.requests.post(
|
|
5292
|
-
|
|
5546
|
+
"/call" /* CALL_PATH */,
|
|
5293
5547
|
jsonData,
|
|
5294
5548
|
{
|
|
5295
5549
|
headers: {
|
|
@@ -5302,18 +5556,29 @@ function useViewService() {
|
|
|
5302
5556
|
},
|
|
5303
5557
|
[env]
|
|
5304
5558
|
);
|
|
5305
|
-
|
|
5559
|
+
return {
|
|
5560
|
+
getList
|
|
5561
|
+
};
|
|
5562
|
+
};
|
|
5563
|
+
|
|
5564
|
+
// src/services/pos-service/get-order-line.ts
|
|
5565
|
+
import { useCallback as useCallback23 } from "react";
|
|
5566
|
+
var getOrderLineService = (env) => {
|
|
5567
|
+
const getOrderLine = useCallback23(
|
|
5306
5568
|
({
|
|
5569
|
+
model,
|
|
5307
5570
|
ids,
|
|
5571
|
+
specification,
|
|
5308
5572
|
xNode,
|
|
5309
|
-
service
|
|
5310
|
-
withContext
|
|
5573
|
+
service
|
|
5311
5574
|
}) => {
|
|
5312
5575
|
const jsonData = {
|
|
5313
|
-
model
|
|
5314
|
-
method: "
|
|
5576
|
+
model,
|
|
5577
|
+
method: "web_read" /* WEB_READ */,
|
|
5315
5578
|
ids,
|
|
5316
|
-
|
|
5579
|
+
kwargs: {
|
|
5580
|
+
specification
|
|
5581
|
+
}
|
|
5317
5582
|
};
|
|
5318
5583
|
return env?.requests.post(
|
|
5319
5584
|
"/call" /* CALL_PATH */,
|
|
@@ -5329,22 +5594,25 @@ function useViewService() {
|
|
|
5329
5594
|
},
|
|
5330
5595
|
[env]
|
|
5331
5596
|
);
|
|
5332
|
-
|
|
5597
|
+
return {
|
|
5598
|
+
getOrderLine
|
|
5599
|
+
};
|
|
5600
|
+
};
|
|
5601
|
+
|
|
5602
|
+
// src/services/pos-service/get-pin-code.ts
|
|
5603
|
+
import { useCallback as useCallback24 } from "react";
|
|
5604
|
+
var getPinCodeService = (env) => {
|
|
5605
|
+
const getPinCode = useCallback24(
|
|
5333
5606
|
({
|
|
5334
|
-
|
|
5335
|
-
ids,
|
|
5336
|
-
args,
|
|
5607
|
+
serialNumber,
|
|
5337
5608
|
xNode,
|
|
5338
5609
|
service
|
|
5339
5610
|
}) => {
|
|
5340
5611
|
const jsonData = {
|
|
5341
|
-
|
|
5342
|
-
method: "onchange" /* ONCHANGE */,
|
|
5343
|
-
ids,
|
|
5344
|
-
args
|
|
5612
|
+
serial_number: serialNumber
|
|
5345
5613
|
};
|
|
5346
5614
|
return env?.requests.post(
|
|
5347
|
-
"/
|
|
5615
|
+
"/pos_device/get_pin_code" /* GET_PIN_CODE */,
|
|
5348
5616
|
jsonData,
|
|
5349
5617
|
{
|
|
5350
5618
|
headers: {
|
|
@@ -5357,57 +5625,60 @@ function useViewService() {
|
|
|
5357
5625
|
},
|
|
5358
5626
|
[env]
|
|
5359
5627
|
);
|
|
5360
|
-
|
|
5628
|
+
return {
|
|
5629
|
+
getPinCode
|
|
5630
|
+
};
|
|
5631
|
+
};
|
|
5632
|
+
|
|
5633
|
+
// src/services/pos-service/get-pos.ts
|
|
5634
|
+
import { useCallback as useCallback25 } from "react";
|
|
5635
|
+
var getPosService = (env) => {
|
|
5636
|
+
const getPOS = useCallback25(
|
|
5361
5637
|
({
|
|
5362
5638
|
model,
|
|
5363
|
-
|
|
5364
|
-
|
|
5639
|
+
args,
|
|
5640
|
+
domain,
|
|
5365
5641
|
xNode,
|
|
5366
5642
|
service
|
|
5367
5643
|
}) => {
|
|
5368
5644
|
const jsonData = {
|
|
5369
5645
|
model,
|
|
5370
|
-
method: "
|
|
5371
|
-
|
|
5646
|
+
method: "web_search_read" /* WEB_SEARCH_READ */,
|
|
5647
|
+
args,
|
|
5372
5648
|
kwargs: {
|
|
5373
|
-
|
|
5374
|
-
|
|
5375
|
-
|
|
5376
|
-
|
|
5377
|
-
|
|
5378
|
-
|
|
5379
|
-
|
|
5380
|
-
|
|
5381
|
-
|
|
5382
|
-
|
|
5649
|
+
domain,
|
|
5650
|
+
specification: {
|
|
5651
|
+
cash_control: {},
|
|
5652
|
+
current_session_id: {
|
|
5653
|
+
fields: {
|
|
5654
|
+
display_name: {}
|
|
5655
|
+
}
|
|
5656
|
+
},
|
|
5657
|
+
current_session_state: {},
|
|
5658
|
+
pos_session_state: {},
|
|
5659
|
+
pos_session_duration: {},
|
|
5660
|
+
currency_id: {
|
|
5661
|
+
fields: {
|
|
5662
|
+
display_name: {}
|
|
5663
|
+
}
|
|
5664
|
+
},
|
|
5665
|
+
name: {},
|
|
5666
|
+
pos_session_username: {},
|
|
5667
|
+
last_session_closing_date: {},
|
|
5668
|
+
last_session_closing_cash: {},
|
|
5669
|
+
number_of_rescue_session: {},
|
|
5670
|
+
current_user_id: {
|
|
5671
|
+
fields: {
|
|
5672
|
+
display_name: {}
|
|
5673
|
+
}
|
|
5674
|
+
},
|
|
5675
|
+
customer_display_type: {},
|
|
5676
|
+
module_pos_restaurant: {}
|
|
5383
5677
|
}
|
|
5384
|
-
}
|
|
5385
|
-
service
|
|
5386
|
-
);
|
|
5387
|
-
},
|
|
5388
|
-
[env]
|
|
5389
|
-
);
|
|
5390
|
-
const getProductImage = useCallback9(
|
|
5391
|
-
({
|
|
5392
|
-
model,
|
|
5393
|
-
fields,
|
|
5394
|
-
limit,
|
|
5395
|
-
offset,
|
|
5396
|
-
domain,
|
|
5397
|
-
xNode,
|
|
5398
|
-
service,
|
|
5399
|
-
searchParams
|
|
5400
|
-
}) => {
|
|
5401
|
-
const jsonData = {
|
|
5402
|
-
model,
|
|
5403
|
-
fields,
|
|
5404
|
-
limit,
|
|
5405
|
-
offset,
|
|
5406
|
-
domain
|
|
5678
|
+
}
|
|
5407
5679
|
};
|
|
5408
|
-
const url = searchParams ? `${"/search_read" /* SEARCH_READ */}?${toQueryString(searchParams)}` : "/search_read" /* SEARCH_READ */;
|
|
5409
5680
|
return env?.requests.post(
|
|
5410
|
-
|
|
5681
|
+
"/call" /* CALL_PATH */,
|
|
5411
5682
|
jsonData,
|
|
5412
5683
|
{
|
|
5413
5684
|
headers: {
|
|
@@ -5420,17 +5691,24 @@ function useViewService() {
|
|
|
5420
5691
|
},
|
|
5421
5692
|
[env]
|
|
5422
5693
|
);
|
|
5423
|
-
|
|
5694
|
+
return {
|
|
5695
|
+
getPOS
|
|
5696
|
+
};
|
|
5697
|
+
};
|
|
5698
|
+
|
|
5699
|
+
// src/services/pos-service/get-preparation-display-data.ts
|
|
5700
|
+
import { useCallback as useCallback26 } from "react";
|
|
5701
|
+
var getPreparationDisplayDataService = (env) => {
|
|
5702
|
+
const getPreparationDisplayData = useCallback26(
|
|
5424
5703
|
({
|
|
5425
|
-
model,
|
|
5426
5704
|
ids,
|
|
5427
|
-
withContext,
|
|
5428
5705
|
xNode,
|
|
5429
|
-
service
|
|
5706
|
+
service,
|
|
5707
|
+
withContext
|
|
5430
5708
|
}) => {
|
|
5431
5709
|
const jsonData = {
|
|
5432
|
-
model
|
|
5433
|
-
method: "
|
|
5710
|
+
model: "pos_preparation_display.display" /* POS_PREPARATION_DISPLAY */,
|
|
5711
|
+
method: "get_preparation_display_data" /* GET_PREPARATION_DISPLAY_DATA */,
|
|
5434
5712
|
ids,
|
|
5435
5713
|
with_context: withContext
|
|
5436
5714
|
};
|
|
@@ -5448,21 +5726,35 @@ function useViewService() {
|
|
|
5448
5726
|
},
|
|
5449
5727
|
[env]
|
|
5450
5728
|
);
|
|
5451
|
-
|
|
5729
|
+
return {
|
|
5730
|
+
getPreparationDisplayData
|
|
5731
|
+
};
|
|
5732
|
+
};
|
|
5733
|
+
|
|
5734
|
+
// src/services/pos-service/get-product-image.ts
|
|
5735
|
+
import { useCallback as useCallback27 } from "react";
|
|
5736
|
+
var getProductImageService = (env) => {
|
|
5737
|
+
const getProductImage = useCallback27(
|
|
5452
5738
|
({
|
|
5453
5739
|
model,
|
|
5454
|
-
|
|
5740
|
+
fields,
|
|
5741
|
+
limit,
|
|
5742
|
+
offset,
|
|
5743
|
+
domain,
|
|
5455
5744
|
xNode,
|
|
5456
5745
|
service,
|
|
5457
|
-
|
|
5746
|
+
searchParams
|
|
5458
5747
|
}) => {
|
|
5459
5748
|
const jsonData = {
|
|
5460
5749
|
model,
|
|
5461
|
-
|
|
5462
|
-
|
|
5750
|
+
fields,
|
|
5751
|
+
limit,
|
|
5752
|
+
offset,
|
|
5753
|
+
domain
|
|
5463
5754
|
};
|
|
5755
|
+
const url = searchParams ? `${"/search_read" /* SEARCH_READ */}?${toQueryString(searchParams)}` : "/search_read" /* SEARCH_READ */;
|
|
5464
5756
|
return env?.requests.post(
|
|
5465
|
-
|
|
5757
|
+
url,
|
|
5466
5758
|
jsonData,
|
|
5467
5759
|
{
|
|
5468
5760
|
headers: {
|
|
@@ -5475,20 +5767,26 @@ function useViewService() {
|
|
|
5475
5767
|
},
|
|
5476
5768
|
[env]
|
|
5477
5769
|
);
|
|
5478
|
-
|
|
5770
|
+
return {
|
|
5771
|
+
getProductImage
|
|
5772
|
+
};
|
|
5773
|
+
};
|
|
5774
|
+
|
|
5775
|
+
// src/services/pos-service/handle-close-session.ts
|
|
5776
|
+
import { useCallback as useCallback28 } from "react";
|
|
5777
|
+
var handleCloseSessionService = (env) => {
|
|
5778
|
+
const handleCloseSession = useCallback28(
|
|
5479
5779
|
({
|
|
5480
5780
|
model,
|
|
5481
5781
|
ids,
|
|
5482
|
-
method,
|
|
5483
5782
|
xNode,
|
|
5484
5783
|
service,
|
|
5485
|
-
|
|
5784
|
+
method
|
|
5486
5785
|
}) => {
|
|
5487
5786
|
const jsonData = {
|
|
5488
5787
|
model,
|
|
5489
5788
|
ids,
|
|
5490
|
-
method
|
|
5491
|
-
kwargs
|
|
5789
|
+
method
|
|
5492
5790
|
};
|
|
5493
5791
|
return env?.requests.post(
|
|
5494
5792
|
"/call" /* CALL_PATH */,
|
|
@@ -5504,23 +5802,31 @@ function useViewService() {
|
|
|
5504
5802
|
},
|
|
5505
5803
|
[env]
|
|
5506
5804
|
);
|
|
5507
|
-
|
|
5805
|
+
return {
|
|
5806
|
+
handleCloseSession
|
|
5807
|
+
};
|
|
5808
|
+
};
|
|
5809
|
+
|
|
5810
|
+
// src/services/pos-service/handle-closing-detail-session.ts
|
|
5811
|
+
import { useCallback as useCallback29 } from "react";
|
|
5812
|
+
var handleClosingDetailSessionService = (env) => {
|
|
5813
|
+
const handleClosingDetailSession = useCallback29(
|
|
5508
5814
|
({
|
|
5509
5815
|
model,
|
|
5510
|
-
|
|
5511
|
-
|
|
5816
|
+
ids,
|
|
5817
|
+
method,
|
|
5512
5818
|
xNode,
|
|
5513
|
-
service
|
|
5819
|
+
service,
|
|
5820
|
+
kwargs
|
|
5514
5821
|
}) => {
|
|
5515
5822
|
const jsonData = {
|
|
5516
5823
|
model,
|
|
5517
|
-
|
|
5518
|
-
|
|
5519
|
-
|
|
5520
|
-
}
|
|
5824
|
+
ids,
|
|
5825
|
+
method,
|
|
5826
|
+
kwargs
|
|
5521
5827
|
};
|
|
5522
5828
|
return env?.requests.post(
|
|
5523
|
-
"/
|
|
5829
|
+
"/call" /* CALL_PATH */,
|
|
5524
5830
|
jsonData,
|
|
5525
5831
|
{
|
|
5526
5832
|
headers: {
|
|
@@ -5533,11 +5839,19 @@ function useViewService() {
|
|
|
5533
5839
|
},
|
|
5534
5840
|
[env]
|
|
5535
5841
|
);
|
|
5536
|
-
|
|
5842
|
+
return {
|
|
5843
|
+
handleClosingDetailSession
|
|
5844
|
+
};
|
|
5845
|
+
};
|
|
5846
|
+
|
|
5847
|
+
// src/services/pos-service/handle-closing-session.ts
|
|
5848
|
+
import { useCallback as useCallback30 } from "react";
|
|
5849
|
+
var handleClosingSessionService = (env) => {
|
|
5850
|
+
const handleClosingSession = useCallback30(
|
|
5537
5851
|
({
|
|
5538
5852
|
model,
|
|
5539
5853
|
method,
|
|
5540
|
-
|
|
5854
|
+
ids,
|
|
5541
5855
|
kwargs,
|
|
5542
5856
|
xNode,
|
|
5543
5857
|
service
|
|
@@ -5545,7 +5859,7 @@ function useViewService() {
|
|
|
5545
5859
|
const jsonData = {
|
|
5546
5860
|
model,
|
|
5547
5861
|
method,
|
|
5548
|
-
|
|
5862
|
+
ids,
|
|
5549
5863
|
kwargs
|
|
5550
5864
|
};
|
|
5551
5865
|
return env?.requests.post(
|
|
@@ -5562,25 +5876,40 @@ function useViewService() {
|
|
|
5562
5876
|
},
|
|
5563
5877
|
[env]
|
|
5564
5878
|
);
|
|
5565
|
-
|
|
5879
|
+
return {
|
|
5880
|
+
handleClosingSession
|
|
5881
|
+
};
|
|
5882
|
+
};
|
|
5883
|
+
|
|
5884
|
+
// src/services/pos-service/load-data-pos-session.ts
|
|
5885
|
+
import { useCallback as useCallback31 } from "react";
|
|
5886
|
+
var loadDataPosSessionService = (env) => {
|
|
5887
|
+
const loadDataPosSession = useCallback31(
|
|
5566
5888
|
({
|
|
5567
|
-
|
|
5568
|
-
|
|
5569
|
-
preparationDisplayId,
|
|
5889
|
+
model,
|
|
5890
|
+
ids,
|
|
5570
5891
|
xNode,
|
|
5571
|
-
service
|
|
5892
|
+
service,
|
|
5893
|
+
withContext,
|
|
5894
|
+
modelsToLoad = [],
|
|
5895
|
+
searchParams
|
|
5572
5896
|
}) => {
|
|
5573
5897
|
const jsonData = {
|
|
5574
|
-
model
|
|
5575
|
-
method: "
|
|
5576
|
-
ids
|
|
5898
|
+
model,
|
|
5899
|
+
method: "load_data" /* LOAD_DATA */,
|
|
5900
|
+
ids,
|
|
5901
|
+
with_context: withContext ? withContext : {
|
|
5902
|
+
uid: 37,
|
|
5903
|
+
lang: "vi_VN",
|
|
5904
|
+
tz: "Asia/Saigon"
|
|
5905
|
+
},
|
|
5577
5906
|
kwargs: {
|
|
5578
|
-
|
|
5579
|
-
preparation_display_id: preparationDisplayId
|
|
5907
|
+
models_to_load: modelsToLoad
|
|
5580
5908
|
}
|
|
5581
5909
|
};
|
|
5910
|
+
const url = searchParams ? `${"/call" /* CALL_PATH */}?${toQueryString(searchParams)}` : "/call" /* CALL_PATH */;
|
|
5582
5911
|
return env?.requests.post(
|
|
5583
|
-
|
|
5912
|
+
url,
|
|
5584
5913
|
jsonData,
|
|
5585
5914
|
{
|
|
5586
5915
|
headers: {
|
|
@@ -5593,19 +5922,30 @@ function useViewService() {
|
|
|
5593
5922
|
},
|
|
5594
5923
|
[env]
|
|
5595
5924
|
);
|
|
5596
|
-
|
|
5925
|
+
return {
|
|
5926
|
+
loadDataPosSession
|
|
5927
|
+
};
|
|
5928
|
+
};
|
|
5929
|
+
|
|
5930
|
+
// src/services/pos-service/manage-onchange.ts
|
|
5931
|
+
import { useCallback as useCallback32 } from "react";
|
|
5932
|
+
var manageOnchangeService = (env) => {
|
|
5933
|
+
const manageOnChange = useCallback32(
|
|
5597
5934
|
({
|
|
5598
|
-
|
|
5599
|
-
|
|
5935
|
+
model,
|
|
5936
|
+
ids,
|
|
5937
|
+
args,
|
|
5600
5938
|
xNode,
|
|
5601
5939
|
service
|
|
5602
5940
|
}) => {
|
|
5603
5941
|
const jsonData = {
|
|
5604
|
-
|
|
5605
|
-
|
|
5942
|
+
model,
|
|
5943
|
+
method: "onchange" /* ONCHANGE */,
|
|
5944
|
+
ids,
|
|
5945
|
+
args
|
|
5606
5946
|
};
|
|
5607
|
-
return env?.requests.
|
|
5608
|
-
"/
|
|
5947
|
+
return env?.requests.post(
|
|
5948
|
+
"/call" /* CALL_PATH */,
|
|
5609
5949
|
jsonData,
|
|
5610
5950
|
{
|
|
5611
5951
|
headers: {
|
|
@@ -5618,18 +5958,30 @@ function useViewService() {
|
|
|
5618
5958
|
},
|
|
5619
5959
|
[env]
|
|
5620
5960
|
);
|
|
5621
|
-
|
|
5961
|
+
return {
|
|
5962
|
+
manageOnChange
|
|
5963
|
+
};
|
|
5964
|
+
};
|
|
5965
|
+
|
|
5966
|
+
// src/services/pos-service/manage-session.ts
|
|
5967
|
+
import { useCallback as useCallback33 } from "react";
|
|
5968
|
+
var manageSessionService = (env) => {
|
|
5969
|
+
const manageSession = useCallback33(
|
|
5622
5970
|
({
|
|
5623
|
-
|
|
5971
|
+
model,
|
|
5972
|
+
method,
|
|
5973
|
+
ids,
|
|
5974
|
+
args,
|
|
5975
|
+
kwargs,
|
|
5624
5976
|
xNode,
|
|
5625
5977
|
service
|
|
5626
5978
|
}) => {
|
|
5627
5979
|
const jsonData = {
|
|
5628
|
-
model
|
|
5629
|
-
method
|
|
5630
|
-
|
|
5631
|
-
|
|
5632
|
-
|
|
5980
|
+
model,
|
|
5981
|
+
method,
|
|
5982
|
+
ids,
|
|
5983
|
+
args,
|
|
5984
|
+
kwargs
|
|
5633
5985
|
};
|
|
5634
5986
|
return env?.requests.post(
|
|
5635
5987
|
"/call" /* CALL_PATH */,
|
|
@@ -5645,21 +5997,29 @@ function useViewService() {
|
|
|
5645
5997
|
},
|
|
5646
5998
|
[env]
|
|
5647
5999
|
);
|
|
5648
|
-
|
|
6000
|
+
return {
|
|
6001
|
+
manageSession
|
|
6002
|
+
};
|
|
6003
|
+
};
|
|
6004
|
+
|
|
6005
|
+
// src/services/pos-service/process-order.ts
|
|
6006
|
+
import { useCallback as useCallback34 } from "react";
|
|
6007
|
+
var processOrderService = (env) => {
|
|
6008
|
+
const processOrder = useCallback34(
|
|
5649
6009
|
({
|
|
5650
6010
|
orderId,
|
|
5651
|
-
amount,
|
|
5652
|
-
posSessionId,
|
|
5653
6011
|
xNode,
|
|
5654
6012
|
service
|
|
5655
6013
|
}) => {
|
|
5656
6014
|
const jsonData = {
|
|
5657
|
-
|
|
5658
|
-
|
|
5659
|
-
|
|
6015
|
+
model: "pos_preparation_display.order" /* POS_PREPARATION_ORDER */,
|
|
6016
|
+
method: "process_order" /* PROCESS_ORDER */,
|
|
6017
|
+
kwargs: {
|
|
6018
|
+
order_id: orderId
|
|
6019
|
+
}
|
|
5660
6020
|
};
|
|
5661
6021
|
return env?.requests.post(
|
|
5662
|
-
"/
|
|
6022
|
+
"/call" /* CALL_PATH */,
|
|
5663
6023
|
jsonData,
|
|
5664
6024
|
{
|
|
5665
6025
|
headers: {
|
|
@@ -5672,7 +6032,15 @@ function useViewService() {
|
|
|
5672
6032
|
},
|
|
5673
6033
|
[env]
|
|
5674
6034
|
);
|
|
5675
|
-
|
|
6035
|
+
return {
|
|
6036
|
+
processOrder
|
|
6037
|
+
};
|
|
6038
|
+
};
|
|
6039
|
+
|
|
6040
|
+
// src/services/pos-service/save-pin-code.ts
|
|
6041
|
+
import { useCallback as useCallback35 } from "react";
|
|
6042
|
+
var savePinCodeService = (env) => {
|
|
6043
|
+
const savePinCode = useCallback35(
|
|
5676
6044
|
({
|
|
5677
6045
|
serialNumber,
|
|
5678
6046
|
pinCode,
|
|
@@ -5697,17 +6065,31 @@ function useViewService() {
|
|
|
5697
6065
|
},
|
|
5698
6066
|
[env]
|
|
5699
6067
|
);
|
|
5700
|
-
|
|
6068
|
+
return {
|
|
6069
|
+
savePinCode
|
|
6070
|
+
};
|
|
6071
|
+
};
|
|
6072
|
+
|
|
6073
|
+
// src/services/pos-service/search-journal.ts
|
|
6074
|
+
import { useCallback as useCallback36 } from "react";
|
|
6075
|
+
var searchJournalService = (env) => {
|
|
6076
|
+
const searchJournal = useCallback36(
|
|
5701
6077
|
({
|
|
5702
|
-
|
|
6078
|
+
model,
|
|
6079
|
+
method,
|
|
6080
|
+
args,
|
|
6081
|
+
kwargs,
|
|
5703
6082
|
xNode,
|
|
5704
6083
|
service
|
|
5705
6084
|
}) => {
|
|
5706
6085
|
const jsonData = {
|
|
5707
|
-
|
|
6086
|
+
model,
|
|
6087
|
+
method,
|
|
6088
|
+
args,
|
|
6089
|
+
kwargs
|
|
5708
6090
|
};
|
|
5709
6091
|
return env?.requests.post(
|
|
5710
|
-
"/
|
|
6092
|
+
"/call" /* CALL_PATH */,
|
|
5711
6093
|
jsonData,
|
|
5712
6094
|
{
|
|
5713
6095
|
headers: {
|
|
@@ -5720,15 +6102,30 @@ function useViewService() {
|
|
|
5720
6102
|
},
|
|
5721
6103
|
[env]
|
|
5722
6104
|
);
|
|
5723
|
-
|
|
5724
|
-
|
|
6105
|
+
return {
|
|
6106
|
+
searchJournal
|
|
6107
|
+
};
|
|
6108
|
+
};
|
|
6109
|
+
|
|
6110
|
+
// src/services/pos-service/update-closed-session.ts
|
|
6111
|
+
import { useCallback as useCallback37 } from "react";
|
|
6112
|
+
var updateClosedSessionService = (env) => {
|
|
6113
|
+
const updateClosedSession = useCallback37(
|
|
6114
|
+
({
|
|
6115
|
+
model,
|
|
6116
|
+
domain,
|
|
6117
|
+
values,
|
|
5725
6118
|
service,
|
|
5726
|
-
xNode
|
|
5727
|
-
body
|
|
6119
|
+
xNode
|
|
5728
6120
|
}) => {
|
|
5729
|
-
|
|
5730
|
-
|
|
5731
|
-
|
|
6121
|
+
const jsonData = {
|
|
6122
|
+
model,
|
|
6123
|
+
domain,
|
|
6124
|
+
values
|
|
6125
|
+
};
|
|
6126
|
+
return env?.requests.post(
|
|
6127
|
+
"/create_update" /* CREATE_UPDATE */,
|
|
6128
|
+
jsonData,
|
|
5732
6129
|
{
|
|
5733
6130
|
headers: {
|
|
5734
6131
|
"Content-Type": "application/json",
|
|
@@ -5740,127 +6137,31 @@ function useViewService() {
|
|
|
5740
6137
|
},
|
|
5741
6138
|
[env]
|
|
5742
6139
|
);
|
|
5743
|
-
|
|
5744
|
-
|
|
5745
|
-
|
|
5746
|
-
|
|
5747
|
-
|
|
5748
|
-
|
|
5749
|
-
|
|
5750
|
-
|
|
5751
|
-
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
|
|
5755
|
-
|
|
5756
|
-
|
|
5757
|
-
};
|
|
5758
|
-
return env?.requests?.post(
|
|
5759
|
-
`${"/call" /* CALL_PATH */}`,
|
|
5760
|
-
body,
|
|
5761
|
-
{
|
|
5762
|
-
headers: {
|
|
5763
|
-
"Content-Type": "application/json",
|
|
5764
|
-
...xNode ? { "X-Node": xNode } : {}
|
|
5765
|
-
}
|
|
5766
|
-
},
|
|
5767
|
-
service
|
|
5768
|
-
);
|
|
5769
|
-
},
|
|
5770
|
-
[env]
|
|
5771
|
-
);
|
|
5772
|
-
const getCurrentUser = useCallback9(
|
|
5773
|
-
async ({
|
|
5774
|
-
service,
|
|
5775
|
-
xNode,
|
|
5776
|
-
oauthUid,
|
|
5777
|
-
extraHeaders
|
|
5778
|
-
}) => {
|
|
5779
|
-
return env?.requests?.get(
|
|
5780
|
-
`${"/public/user/info" /* PUBLIC_USER_INFO */}/${oauthUid}`,
|
|
5781
|
-
{
|
|
5782
|
-
headers: extraHeaders ? {
|
|
5783
|
-
...extraHeaders,
|
|
5784
|
-
"Content-Type": "application/json",
|
|
5785
|
-
...xNode ? { "X-Node": xNode } : {}
|
|
5786
|
-
} : {
|
|
5787
|
-
"Content-Type": "application/json",
|
|
5788
|
-
...xNode ? { "X-Node": xNode } : {}
|
|
5789
|
-
}
|
|
5790
|
-
},
|
|
5791
|
-
service
|
|
5792
|
-
);
|
|
5793
|
-
},
|
|
5794
|
-
[env]
|
|
5795
|
-
);
|
|
5796
|
-
const getCountry = useCallback9(
|
|
5797
|
-
async ({
|
|
5798
|
-
service,
|
|
5799
|
-
xNode,
|
|
5800
|
-
ids,
|
|
5801
|
-
kwargs
|
|
5802
|
-
}) => {
|
|
5803
|
-
const body = {
|
|
5804
|
-
model: "res.country" /* COUNTRY */,
|
|
5805
|
-
ids,
|
|
5806
|
-
method: "get_data_select" /* GET_DATA_SELECT */,
|
|
5807
|
-
kwargs
|
|
5808
|
-
};
|
|
5809
|
-
return env?.requests?.post(
|
|
5810
|
-
"/call" /* CALL_PATH */,
|
|
5811
|
-
body,
|
|
5812
|
-
{
|
|
5813
|
-
headers: {
|
|
5814
|
-
"Content-Type": "application/json",
|
|
5815
|
-
...xNode ? { "X-Node": xNode } : {}
|
|
5816
|
-
}
|
|
5817
|
-
},
|
|
5818
|
-
service
|
|
5819
|
-
);
|
|
5820
|
-
},
|
|
5821
|
-
[env]
|
|
5822
|
-
);
|
|
5823
|
-
const getCity = useCallback9(
|
|
5824
|
-
async ({
|
|
5825
|
-
service,
|
|
5826
|
-
xNode,
|
|
5827
|
-
ids,
|
|
5828
|
-
kwargs
|
|
5829
|
-
}) => {
|
|
5830
|
-
const body = {
|
|
5831
|
-
model: "res.country.state" /* COUNTRY_STATE */,
|
|
5832
|
-
ids,
|
|
5833
|
-
method: "get_data_select" /* GET_DATA_SELECT */,
|
|
5834
|
-
kwargs
|
|
5835
|
-
};
|
|
5836
|
-
return env?.requests?.post(
|
|
5837
|
-
"/call" /* CALL_PATH */,
|
|
5838
|
-
body,
|
|
5839
|
-
{
|
|
5840
|
-
headers: {
|
|
5841
|
-
"Content-Type": "application/json",
|
|
5842
|
-
...xNode ? { "X-Node": xNode } : {}
|
|
5843
|
-
}
|
|
5844
|
-
},
|
|
5845
|
-
service
|
|
5846
|
-
);
|
|
5847
|
-
},
|
|
5848
|
-
[env]
|
|
5849
|
-
);
|
|
5850
|
-
const getWard = useCallback9(
|
|
5851
|
-
async ({
|
|
5852
|
-
service,
|
|
6140
|
+
return {
|
|
6141
|
+
updateClosedSession
|
|
6142
|
+
};
|
|
6143
|
+
};
|
|
6144
|
+
|
|
6145
|
+
// src/services/pos-service/update-entity.ts
|
|
6146
|
+
import { useCallback as useCallback38 } from "react";
|
|
6147
|
+
var updateEntityService = (env) => {
|
|
6148
|
+
const updateEntity = useCallback38(
|
|
6149
|
+
({
|
|
6150
|
+
model,
|
|
6151
|
+
domain,
|
|
6152
|
+
values,
|
|
6153
|
+
isCreateEndpoint = true,
|
|
5853
6154
|
xNode,
|
|
5854
|
-
|
|
6155
|
+
service
|
|
5855
6156
|
}) => {
|
|
5856
|
-
const
|
|
5857
|
-
model
|
|
5858
|
-
|
|
5859
|
-
|
|
6157
|
+
const jsonData = {
|
|
6158
|
+
model,
|
|
6159
|
+
domain,
|
|
6160
|
+
values
|
|
5860
6161
|
};
|
|
5861
|
-
return env?.requests
|
|
5862
|
-
"/call" /* CALL_PATH */,
|
|
5863
|
-
|
|
6162
|
+
return env?.requests.post(
|
|
6163
|
+
isCreateEndpoint ? "/create_update" /* CREATE_UPDATE */ : "/call" /* CALL_PATH */,
|
|
6164
|
+
jsonData,
|
|
5864
6165
|
{
|
|
5865
6166
|
headers: {
|
|
5866
6167
|
"Content-Type": "application/json",
|
|
@@ -5872,22 +6173,28 @@ function useViewService() {
|
|
|
5872
6173
|
},
|
|
5873
6174
|
[env]
|
|
5874
6175
|
);
|
|
5875
|
-
|
|
5876
|
-
|
|
5877
|
-
|
|
6176
|
+
return {
|
|
6177
|
+
updateEntity
|
|
6178
|
+
};
|
|
6179
|
+
};
|
|
6180
|
+
|
|
6181
|
+
// src/services/pos-service/update-order-status.ts
|
|
6182
|
+
import { useCallback as useCallback39 } from "react";
|
|
6183
|
+
var updateOrderStatusService = (env) => {
|
|
6184
|
+
const updateOrderStatus = useCallback39(
|
|
6185
|
+
({
|
|
6186
|
+
orderId,
|
|
6187
|
+
state,
|
|
5878
6188
|
xNode,
|
|
5879
|
-
|
|
5880
|
-
withContext
|
|
6189
|
+
service
|
|
5881
6190
|
}) => {
|
|
5882
|
-
const
|
|
5883
|
-
|
|
5884
|
-
|
|
5885
|
-
kwargs,
|
|
5886
|
-
with_context: withContext
|
|
6191
|
+
const jsonData = {
|
|
6192
|
+
order_id: orderId,
|
|
6193
|
+
state
|
|
5887
6194
|
};
|
|
5888
|
-
return env?.requests
|
|
5889
|
-
"/
|
|
5890
|
-
|
|
6195
|
+
return env?.requests.put(
|
|
6196
|
+
"/pos-order/status" /* POS_ORDER_STATUS */,
|
|
6197
|
+
jsonData,
|
|
5891
6198
|
{
|
|
5892
6199
|
headers: {
|
|
5893
6200
|
"Content-Type": "application/json",
|
|
@@ -5900,113 +6207,51 @@ function useViewService() {
|
|
|
5900
6207
|
[env]
|
|
5901
6208
|
);
|
|
5902
6209
|
return {
|
|
5903
|
-
|
|
5904
|
-
getMenu,
|
|
5905
|
-
getActionDetail,
|
|
5906
|
-
getResequence,
|
|
5907
|
-
getSelectionItem,
|
|
5908
|
-
loadMessages,
|
|
5909
|
-
getVersion,
|
|
5910
|
-
grantAccess,
|
|
5911
|
-
removeTotpSetUp,
|
|
5912
|
-
requestSetupTotp,
|
|
5913
|
-
settingsWebRead2fa,
|
|
5914
|
-
signInSSO,
|
|
5915
|
-
verify2FA,
|
|
5916
|
-
get2FAMethods,
|
|
5917
|
-
verifyTotp,
|
|
5918
|
-
getASession,
|
|
5919
|
-
updateClosedSession,
|
|
5920
|
-
manageSession,
|
|
5921
|
-
handleClosingSession,
|
|
5922
|
-
createSession,
|
|
5923
|
-
getPOS,
|
|
5924
|
-
createEntity,
|
|
5925
|
-
getList,
|
|
5926
|
-
updateEntity,
|
|
5927
|
-
deleteEntity,
|
|
5928
|
-
loadDataPosSession,
|
|
5929
|
-
manageOnChange,
|
|
5930
|
-
getOrderLine,
|
|
5931
|
-
getProductImage,
|
|
5932
|
-
addEntity,
|
|
5933
|
-
checkPayment,
|
|
5934
|
-
handleCloseSession,
|
|
5935
|
-
handleClosingDetailSession,
|
|
5936
|
-
createPosConfig,
|
|
5937
|
-
searchJournal,
|
|
5938
|
-
getPreparationDisplayData,
|
|
5939
|
-
changeOrderPreparaionState,
|
|
5940
|
-
updateOrderStatus,
|
|
5941
|
-
processOrder,
|
|
5942
|
-
generatePaymentQRInfo,
|
|
5943
|
-
savePinCode,
|
|
5944
|
-
getPinCode,
|
|
5945
|
-
getNotifications,
|
|
5946
|
-
createEInvoice,
|
|
5947
|
-
getCurrentUser,
|
|
5948
|
-
getCountry,
|
|
5949
|
-
getCity,
|
|
5950
|
-
getWard,
|
|
5951
|
-
getPartnerTitle
|
|
6210
|
+
updateOrderStatus
|
|
5952
6211
|
};
|
|
5953
|
-
}
|
|
6212
|
+
};
|
|
5954
6213
|
|
|
5955
|
-
// src/services/
|
|
5956
|
-
|
|
5957
|
-
|
|
6214
|
+
// src/services/pos-service/index.ts
|
|
6215
|
+
var serviceFactories = [
|
|
6216
|
+
addEntityService,
|
|
6217
|
+
getASessionService,
|
|
6218
|
+
changOrderPreparationStateService,
|
|
6219
|
+
checkPaymentService,
|
|
6220
|
+
createEInvoiceService,
|
|
6221
|
+
createEntityService,
|
|
6222
|
+
createPosConfigService,
|
|
6223
|
+
createSessionService,
|
|
6224
|
+
deleteEntityService,
|
|
6225
|
+
generatePaymentQrInfoService,
|
|
6226
|
+
getCurrentUserService,
|
|
6227
|
+
getListService,
|
|
6228
|
+
getOrderLineService,
|
|
6229
|
+
getPinCodeService,
|
|
6230
|
+
getPosService,
|
|
6231
|
+
getPreparationDisplayDataService,
|
|
6232
|
+
getProductImageService,
|
|
6233
|
+
handleCloseSessionService,
|
|
6234
|
+
handleClosingDetailSessionService,
|
|
6235
|
+
handleClosingSessionService,
|
|
6236
|
+
loadDataPosSessionService,
|
|
6237
|
+
manageOnchangeService,
|
|
6238
|
+
manageSessionService,
|
|
6239
|
+
processOrderService,
|
|
6240
|
+
savePinCodeService,
|
|
6241
|
+
searchJournalService,
|
|
6242
|
+
updateClosedSessionService,
|
|
6243
|
+
updateEntityService,
|
|
6244
|
+
updateOrderStatusService
|
|
6245
|
+
];
|
|
6246
|
+
var usePosService = () => {
|
|
5958
6247
|
const { env } = useEnv();
|
|
5959
|
-
const
|
|
5960
|
-
|
|
5961
|
-
|
|
5962
|
-
|
|
5963
|
-
|
|
5964
|
-
|
|
5965
|
-
|
|
5966
|
-
"/read_group" /* READ_GROUP */,
|
|
5967
|
-
body,
|
|
5968
|
-
{
|
|
5969
|
-
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
5970
|
-
},
|
|
5971
|
-
service
|
|
5972
|
-
);
|
|
5973
|
-
},
|
|
5974
|
-
[env]
|
|
5975
|
-
);
|
|
5976
|
-
const getDataChart = useCallback10(
|
|
5977
|
-
async ({
|
|
5978
|
-
service,
|
|
5979
|
-
xNode,
|
|
5980
|
-
body,
|
|
5981
|
-
path,
|
|
5982
|
-
method = "POST"
|
|
5983
|
-
}) => {
|
|
5984
|
-
const headers = {
|
|
5985
|
-
"Content-Type": "application/json",
|
|
5986
|
-
"X-Node": xNode
|
|
5987
|
-
};
|
|
5988
|
-
if (method === "GET") {
|
|
5989
|
-
return env.requests.get(
|
|
5990
|
-
path,
|
|
5991
|
-
{
|
|
5992
|
-
headers
|
|
5993
|
-
},
|
|
5994
|
-
service
|
|
5995
|
-
);
|
|
5996
|
-
}
|
|
5997
|
-
return env.requests.post(
|
|
5998
|
-
path,
|
|
5999
|
-
body,
|
|
6000
|
-
{
|
|
6001
|
-
headers
|
|
6002
|
-
},
|
|
6003
|
-
service
|
|
6004
|
-
);
|
|
6005
|
-
},
|
|
6006
|
-
[env]
|
|
6007
|
-
);
|
|
6008
|
-
return { readGroup, getDataChart };
|
|
6009
|
-
}
|
|
6248
|
+
const service = {};
|
|
6249
|
+
for (const factory of serviceFactories) {
|
|
6250
|
+
const instance = factory(env);
|
|
6251
|
+
Object.assign(service, instance);
|
|
6252
|
+
}
|
|
6253
|
+
return service;
|
|
6254
|
+
};
|
|
6010
6255
|
|
|
6011
6256
|
// src/provider/version-gate-provider.tsx
|
|
6012
6257
|
import { Fragment, jsx as jsx4 } from "react/jsx-runtime";
|
|
@@ -6045,7 +6290,7 @@ var VersionGate = ({ children }) => {
|
|
|
6045
6290
|
};
|
|
6046
6291
|
|
|
6047
6292
|
// src/provider/env-provider.tsx
|
|
6048
|
-
import { createContext, useContext, useState as useState4, useCallback as
|
|
6293
|
+
import { createContext, useContext, useState as useState4, useCallback as useCallback40 } from "react";
|
|
6049
6294
|
|
|
6050
6295
|
// src/configs/axios-client.ts
|
|
6051
6296
|
import axios from "axios";
|
|
@@ -6408,7 +6653,7 @@ function EnvProvider({
|
|
|
6408
6653
|
localStorageUtils: localStorageUtil,
|
|
6409
6654
|
sessionStorageUtils: sessionStorageUtil
|
|
6410
6655
|
});
|
|
6411
|
-
const setupEnv =
|
|
6656
|
+
const setupEnv = useCallback40(
|
|
6412
6657
|
(envConfig) => {
|
|
6413
6658
|
const updatedEnv = {
|
|
6414
6659
|
...env,
|
|
@@ -6422,31 +6667,31 @@ function EnvProvider({
|
|
|
6422
6667
|
},
|
|
6423
6668
|
[env, localStorageUtil, sessionStorageUtil]
|
|
6424
6669
|
);
|
|
6425
|
-
const setUid2 =
|
|
6670
|
+
const setUid2 = useCallback40((uid) => {
|
|
6426
6671
|
setEnvState((prev) => ({
|
|
6427
6672
|
...prev,
|
|
6428
6673
|
context: { ...prev.context, uid }
|
|
6429
6674
|
}));
|
|
6430
6675
|
}, []);
|
|
6431
|
-
const setLang2 =
|
|
6676
|
+
const setLang2 = useCallback40((lang) => {
|
|
6432
6677
|
setEnvState((prev) => ({
|
|
6433
6678
|
...prev,
|
|
6434
6679
|
context: { ...prev.context, lang }
|
|
6435
6680
|
}));
|
|
6436
6681
|
}, []);
|
|
6437
|
-
const setAllowCompanies2 =
|
|
6682
|
+
const setAllowCompanies2 = useCallback40((allowed_company_ids) => {
|
|
6438
6683
|
setEnvState((prev) => ({
|
|
6439
6684
|
...prev,
|
|
6440
6685
|
context: { ...prev.context, allowed_company_ids }
|
|
6441
6686
|
}));
|
|
6442
6687
|
}, []);
|
|
6443
|
-
const setCompanies2 =
|
|
6688
|
+
const setCompanies2 = useCallback40((companies) => {
|
|
6444
6689
|
setEnvState((prev) => ({
|
|
6445
6690
|
...prev,
|
|
6446
6691
|
companies
|
|
6447
6692
|
}));
|
|
6448
6693
|
}, []);
|
|
6449
|
-
const setDefaultCompany2 =
|
|
6694
|
+
const setDefaultCompany2 = useCallback40(
|
|
6450
6695
|
(defaultCompany) => {
|
|
6451
6696
|
setEnvState((prev) => ({
|
|
6452
6697
|
...prev,
|
|
@@ -6455,19 +6700,19 @@ function EnvProvider({
|
|
|
6455
6700
|
},
|
|
6456
6701
|
[]
|
|
6457
6702
|
);
|
|
6458
|
-
const setUserInfo =
|
|
6703
|
+
const setUserInfo = useCallback40((user) => {
|
|
6459
6704
|
setEnvState((prev) => ({
|
|
6460
6705
|
...prev,
|
|
6461
6706
|
user
|
|
6462
6707
|
}));
|
|
6463
6708
|
}, []);
|
|
6464
|
-
const setConfig2 =
|
|
6709
|
+
const setConfig2 = useCallback40((config) => {
|
|
6465
6710
|
setEnvState((prev) => ({
|
|
6466
6711
|
...prev,
|
|
6467
6712
|
config
|
|
6468
6713
|
}));
|
|
6469
6714
|
}, []);
|
|
6470
|
-
const setEnvFile2 =
|
|
6715
|
+
const setEnvFile2 = useCallback40((envFile) => {
|
|
6471
6716
|
setEnvState((prev) => ({
|
|
6472
6717
|
...prev,
|
|
6473
6718
|
envFile
|
|
@@ -7373,9 +7618,9 @@ var BaseModel = class {
|
|
|
7373
7618
|
};
|
|
7374
7619
|
|
|
7375
7620
|
// src/hooks/model/use-model.ts
|
|
7376
|
-
import { useCallback as
|
|
7621
|
+
import { useCallback as useCallback41 } from "react";
|
|
7377
7622
|
var useModel = () => {
|
|
7378
|
-
const initModel =
|
|
7623
|
+
const initModel = useCallback41((modelData) => {
|
|
7379
7624
|
switch (modelData?.name) {
|
|
7380
7625
|
default:
|
|
7381
7626
|
return new BaseModel(modelData);
|
|
@@ -8011,679 +8256,27 @@ var useVerifyTotp = () => {
|
|
|
8011
8256
|
};
|
|
8012
8257
|
var use_verify_totp_default = useVerifyTotp;
|
|
8013
8258
|
|
|
8014
|
-
// src/hooks/view/use-
|
|
8259
|
+
// src/hooks/view/use-gen-serial-number.ts
|
|
8015
8260
|
import { useMutation as useMutation51 } from "@tanstack/react-query";
|
|
8016
|
-
var
|
|
8017
|
-
const {
|
|
8261
|
+
var useGenSerialNumber = () => {
|
|
8262
|
+
const { generateSerialNumber } = useActionService();
|
|
8018
8263
|
return useMutation51({
|
|
8019
8264
|
mutationFn: ({
|
|
8020
|
-
|
|
8021
|
-
|
|
8022
|
-
domain,
|
|
8265
|
+
kwargs,
|
|
8266
|
+
context,
|
|
8023
8267
|
service,
|
|
8024
8268
|
xNode
|
|
8025
8269
|
}) => {
|
|
8026
|
-
return
|
|
8027
|
-
|
|
8028
|
-
|
|
8029
|
-
domain,
|
|
8270
|
+
return generateSerialNumber({
|
|
8271
|
+
kwargs,
|
|
8272
|
+
context,
|
|
8030
8273
|
service,
|
|
8031
8274
|
xNode
|
|
8032
8275
|
});
|
|
8033
8276
|
}
|
|
8034
8277
|
});
|
|
8035
8278
|
};
|
|
8036
|
-
var
|
|
8037
|
-
|
|
8038
|
-
// src/hooks/view/use-update-closed-session.ts
|
|
8039
|
-
import { useMutation as useMutation52 } from "@tanstack/react-query";
|
|
8040
|
-
var useUpdateClosedSession = () => {
|
|
8041
|
-
const { updateClosedSession } = useViewService();
|
|
8042
|
-
return useMutation52({
|
|
8043
|
-
mutationFn: ({
|
|
8044
|
-
model,
|
|
8045
|
-
domain,
|
|
8046
|
-
values,
|
|
8047
|
-
service,
|
|
8048
|
-
xNode
|
|
8049
|
-
}) => {
|
|
8050
|
-
return updateClosedSession({
|
|
8051
|
-
model,
|
|
8052
|
-
domain,
|
|
8053
|
-
values,
|
|
8054
|
-
service,
|
|
8055
|
-
xNode
|
|
8056
|
-
});
|
|
8057
|
-
}
|
|
8058
|
-
});
|
|
8059
|
-
};
|
|
8060
|
-
var use_update_closed_session_default = useUpdateClosedSession;
|
|
8061
|
-
|
|
8062
|
-
// src/hooks/view/use-manage-session.ts
|
|
8063
|
-
import { useMutation as useMutation53 } from "@tanstack/react-query";
|
|
8064
|
-
var useManageSession = () => {
|
|
8065
|
-
const { manageSession } = useViewService();
|
|
8066
|
-
return useMutation53({
|
|
8067
|
-
mutationFn: ({
|
|
8068
|
-
model,
|
|
8069
|
-
ids,
|
|
8070
|
-
args,
|
|
8071
|
-
kwargs,
|
|
8072
|
-
service,
|
|
8073
|
-
xNode,
|
|
8074
|
-
method
|
|
8075
|
-
}) => {
|
|
8076
|
-
return manageSession({
|
|
8077
|
-
model,
|
|
8078
|
-
method,
|
|
8079
|
-
ids,
|
|
8080
|
-
args,
|
|
8081
|
-
kwargs,
|
|
8082
|
-
service,
|
|
8083
|
-
xNode
|
|
8084
|
-
});
|
|
8085
|
-
}
|
|
8086
|
-
});
|
|
8087
|
-
};
|
|
8088
|
-
var use_manage_session_default = useManageSession;
|
|
8089
|
-
|
|
8090
|
-
// src/hooks/view/use-handle-closing-session.ts
|
|
8091
|
-
import { useMutation as useMutation54 } from "@tanstack/react-query";
|
|
8092
|
-
var useHandleClosingSession = () => {
|
|
8093
|
-
const { handleClosingSession } = useViewService();
|
|
8094
|
-
return useMutation54({
|
|
8095
|
-
mutationFn: ({
|
|
8096
|
-
model,
|
|
8097
|
-
method,
|
|
8098
|
-
ids,
|
|
8099
|
-
kwargs,
|
|
8100
|
-
xNode,
|
|
8101
|
-
service
|
|
8102
|
-
}) => {
|
|
8103
|
-
return handleClosingSession({
|
|
8104
|
-
model,
|
|
8105
|
-
method,
|
|
8106
|
-
ids,
|
|
8107
|
-
kwargs,
|
|
8108
|
-
service,
|
|
8109
|
-
xNode
|
|
8110
|
-
});
|
|
8111
|
-
}
|
|
8112
|
-
});
|
|
8113
|
-
};
|
|
8114
|
-
var use_handle_closing_session_default = useHandleClosingSession;
|
|
8115
|
-
|
|
8116
|
-
// src/hooks/view/use-create-session.ts
|
|
8117
|
-
import { useMutation as useMutation55 } from "@tanstack/react-query";
|
|
8118
|
-
var useCreateSession = () => {
|
|
8119
|
-
const { createSession } = useViewService();
|
|
8120
|
-
return useMutation55({
|
|
8121
|
-
mutationFn: ({
|
|
8122
|
-
model,
|
|
8123
|
-
configId,
|
|
8124
|
-
service,
|
|
8125
|
-
xNode
|
|
8126
|
-
}) => {
|
|
8127
|
-
return createSession({
|
|
8128
|
-
model,
|
|
8129
|
-
configId,
|
|
8130
|
-
service,
|
|
8131
|
-
xNode
|
|
8132
|
-
});
|
|
8133
|
-
}
|
|
8134
|
-
});
|
|
8135
|
-
};
|
|
8136
|
-
var use_create_session_default = useCreateSession;
|
|
8137
|
-
|
|
8138
|
-
// src/hooks/view/use-get-pos.ts
|
|
8139
|
-
import { useMutation as useMutation56 } from "@tanstack/react-query";
|
|
8140
|
-
var useGetPos = () => {
|
|
8141
|
-
const { getPOS } = useViewService();
|
|
8142
|
-
return useMutation56({
|
|
8143
|
-
mutationFn: ({
|
|
8144
|
-
model,
|
|
8145
|
-
args,
|
|
8146
|
-
domain,
|
|
8147
|
-
service,
|
|
8148
|
-
xNode
|
|
8149
|
-
}) => {
|
|
8150
|
-
return getPOS({
|
|
8151
|
-
model,
|
|
8152
|
-
args,
|
|
8153
|
-
domain,
|
|
8154
|
-
service,
|
|
8155
|
-
xNode
|
|
8156
|
-
});
|
|
8157
|
-
}
|
|
8158
|
-
});
|
|
8159
|
-
};
|
|
8160
|
-
var use_get_pos_default = useGetPos;
|
|
8161
|
-
|
|
8162
|
-
// src/hooks/view/use-create-entity.ts
|
|
8163
|
-
import { useMutation as useMutation57 } from "@tanstack/react-query";
|
|
8164
|
-
var useCreateEntity = () => {
|
|
8165
|
-
const { createEntity } = useViewService();
|
|
8166
|
-
return useMutation57({
|
|
8167
|
-
mutationFn: ({
|
|
8168
|
-
model,
|
|
8169
|
-
args,
|
|
8170
|
-
xNode,
|
|
8171
|
-
service
|
|
8172
|
-
}) => {
|
|
8173
|
-
return createEntity({
|
|
8174
|
-
model,
|
|
8175
|
-
args,
|
|
8176
|
-
xNode,
|
|
8177
|
-
service
|
|
8178
|
-
});
|
|
8179
|
-
}
|
|
8180
|
-
});
|
|
8181
|
-
};
|
|
8182
|
-
var use_create_entity_default = useCreateEntity;
|
|
8183
|
-
|
|
8184
|
-
// src/hooks/view/use-get-list.ts
|
|
8185
|
-
import { useMutation as useMutation58 } from "@tanstack/react-query";
|
|
8186
|
-
var useGetList = () => {
|
|
8187
|
-
const { getList } = useViewService();
|
|
8188
|
-
return useMutation58({
|
|
8189
|
-
mutationFn: ({
|
|
8190
|
-
model,
|
|
8191
|
-
domain,
|
|
8192
|
-
xNode,
|
|
8193
|
-
service,
|
|
8194
|
-
specification,
|
|
8195
|
-
offset,
|
|
8196
|
-
limit
|
|
8197
|
-
}) => {
|
|
8198
|
-
return getList({
|
|
8199
|
-
model,
|
|
8200
|
-
domain,
|
|
8201
|
-
service,
|
|
8202
|
-
xNode,
|
|
8203
|
-
specification,
|
|
8204
|
-
offset,
|
|
8205
|
-
limit
|
|
8206
|
-
});
|
|
8207
|
-
}
|
|
8208
|
-
});
|
|
8209
|
-
};
|
|
8210
|
-
var use_get_list_default = useGetList;
|
|
8211
|
-
|
|
8212
|
-
// src/hooks/view/use-update-entity.ts
|
|
8213
|
-
import { useMutation as useMutation59 } from "@tanstack/react-query";
|
|
8214
|
-
var useUpdateEntity = () => {
|
|
8215
|
-
const { updateEntity } = useViewService();
|
|
8216
|
-
return useMutation59({
|
|
8217
|
-
mutationFn: ({
|
|
8218
|
-
model,
|
|
8219
|
-
domain,
|
|
8220
|
-
values,
|
|
8221
|
-
xNode,
|
|
8222
|
-
service
|
|
8223
|
-
}) => {
|
|
8224
|
-
return updateEntity({
|
|
8225
|
-
model,
|
|
8226
|
-
domain,
|
|
8227
|
-
values,
|
|
8228
|
-
xNode,
|
|
8229
|
-
service
|
|
8230
|
-
});
|
|
8231
|
-
}
|
|
8232
|
-
});
|
|
8233
|
-
};
|
|
8234
|
-
var use_update_entity_default = useUpdateEntity;
|
|
8235
|
-
|
|
8236
|
-
// src/hooks/view/use-delete-entity.ts
|
|
8237
|
-
import { useMutation as useMutation60 } from "@tanstack/react-query";
|
|
8238
|
-
var useDeleteEntity = () => {
|
|
8239
|
-
const { deleteEntity } = useViewService();
|
|
8240
|
-
return useMutation60({
|
|
8241
|
-
mutationFn: ({
|
|
8242
|
-
model,
|
|
8243
|
-
ids,
|
|
8244
|
-
xNode,
|
|
8245
|
-
service,
|
|
8246
|
-
method
|
|
8247
|
-
}) => {
|
|
8248
|
-
return deleteEntity({
|
|
8249
|
-
model,
|
|
8250
|
-
ids,
|
|
8251
|
-
xNode,
|
|
8252
|
-
service,
|
|
8253
|
-
method
|
|
8254
|
-
});
|
|
8255
|
-
}
|
|
8256
|
-
});
|
|
8257
|
-
};
|
|
8258
|
-
var use_delete_entity_default = useDeleteEntity;
|
|
8259
|
-
|
|
8260
|
-
// src/hooks/view/use-load-data-pos-session.ts
|
|
8261
|
-
import { useMutation as useMutation61 } from "@tanstack/react-query";
|
|
8262
|
-
var useLoadDataPosSession = () => {
|
|
8263
|
-
const { loadDataPosSession } = useViewService();
|
|
8264
|
-
return useMutation61({
|
|
8265
|
-
mutationFn: ({
|
|
8266
|
-
model,
|
|
8267
|
-
ids,
|
|
8268
|
-
xNode,
|
|
8269
|
-
service,
|
|
8270
|
-
withContext,
|
|
8271
|
-
modelsToLoad,
|
|
8272
|
-
searchParams
|
|
8273
|
-
}) => {
|
|
8274
|
-
return loadDataPosSession({
|
|
8275
|
-
model,
|
|
8276
|
-
ids,
|
|
8277
|
-
xNode,
|
|
8278
|
-
service,
|
|
8279
|
-
withContext,
|
|
8280
|
-
modelsToLoad,
|
|
8281
|
-
searchParams
|
|
8282
|
-
});
|
|
8283
|
-
}
|
|
8284
|
-
});
|
|
8285
|
-
};
|
|
8286
|
-
var use_load_data_pos_session_default = useLoadDataPosSession;
|
|
8287
|
-
|
|
8288
|
-
// src/hooks/view/use-manage-on-change.ts
|
|
8289
|
-
import { useMutation as useMutation62 } from "@tanstack/react-query";
|
|
8290
|
-
var useManageOnChange = () => {
|
|
8291
|
-
const { manageOnChange } = useViewService();
|
|
8292
|
-
return useMutation62({
|
|
8293
|
-
mutationFn: ({
|
|
8294
|
-
model,
|
|
8295
|
-
ids,
|
|
8296
|
-
args,
|
|
8297
|
-
service,
|
|
8298
|
-
xNode
|
|
8299
|
-
}) => {
|
|
8300
|
-
return manageOnChange({
|
|
8301
|
-
model,
|
|
8302
|
-
ids,
|
|
8303
|
-
args,
|
|
8304
|
-
service,
|
|
8305
|
-
xNode
|
|
8306
|
-
});
|
|
8307
|
-
}
|
|
8308
|
-
});
|
|
8309
|
-
};
|
|
8310
|
-
var use_manage_on_change_default = useManageOnChange;
|
|
8311
|
-
|
|
8312
|
-
// src/hooks/view/use-gen-serial-number.ts
|
|
8313
|
-
import { useMutation as useMutation63 } from "@tanstack/react-query";
|
|
8314
|
-
var useGenSerialNumber = () => {
|
|
8315
|
-
const { generateSerialNumber } = useActionService();
|
|
8316
|
-
return useMutation63({
|
|
8317
|
-
mutationFn: ({
|
|
8318
|
-
kwargs,
|
|
8319
|
-
context,
|
|
8320
|
-
service,
|
|
8321
|
-
xNode
|
|
8322
|
-
}) => {
|
|
8323
|
-
return generateSerialNumber({
|
|
8324
|
-
kwargs,
|
|
8325
|
-
context,
|
|
8326
|
-
service,
|
|
8327
|
-
xNode
|
|
8328
|
-
});
|
|
8329
|
-
}
|
|
8330
|
-
});
|
|
8331
|
-
};
|
|
8332
|
-
var use_gen_serial_number_default = useGenSerialNumber;
|
|
8333
|
-
|
|
8334
|
-
// src/hooks/view/use-get-order-line.ts
|
|
8335
|
-
import { useMutation as useMutation64 } from "@tanstack/react-query";
|
|
8336
|
-
var useGetOrderLine = () => {
|
|
8337
|
-
const { getOrderLine } = useViewService();
|
|
8338
|
-
return useMutation64({
|
|
8339
|
-
mutationFn: ({
|
|
8340
|
-
model,
|
|
8341
|
-
ids,
|
|
8342
|
-
specification,
|
|
8343
|
-
xNode,
|
|
8344
|
-
service
|
|
8345
|
-
}) => {
|
|
8346
|
-
return getOrderLine({
|
|
8347
|
-
model,
|
|
8348
|
-
ids,
|
|
8349
|
-
specification,
|
|
8350
|
-
xNode,
|
|
8351
|
-
service
|
|
8352
|
-
});
|
|
8353
|
-
}
|
|
8354
|
-
});
|
|
8355
|
-
};
|
|
8356
|
-
var use_get_order_line_default = useGetOrderLine;
|
|
8357
|
-
|
|
8358
|
-
// src/hooks/view/use-get-product-image.ts
|
|
8359
|
-
import { useMutation as useMutation65 } from "@tanstack/react-query";
|
|
8360
|
-
var useGetProductImage = () => {
|
|
8361
|
-
const { getProductImage } = useViewService();
|
|
8362
|
-
return useMutation65({
|
|
8363
|
-
mutationFn: ({
|
|
8364
|
-
model,
|
|
8365
|
-
fields,
|
|
8366
|
-
limit,
|
|
8367
|
-
offset,
|
|
8368
|
-
domain,
|
|
8369
|
-
xNode,
|
|
8370
|
-
service,
|
|
8371
|
-
searchParams
|
|
8372
|
-
}) => {
|
|
8373
|
-
return getProductImage({
|
|
8374
|
-
model,
|
|
8375
|
-
fields,
|
|
8376
|
-
limit,
|
|
8377
|
-
offset,
|
|
8378
|
-
domain,
|
|
8379
|
-
xNode,
|
|
8380
|
-
service,
|
|
8381
|
-
searchParams
|
|
8382
|
-
});
|
|
8383
|
-
}
|
|
8384
|
-
});
|
|
8385
|
-
};
|
|
8386
|
-
var use_get_product_image_default = useGetProductImage;
|
|
8387
|
-
|
|
8388
|
-
// src/hooks/view/use-add-entity.ts
|
|
8389
|
-
import { useMutation as useMutation66 } from "@tanstack/react-query";
|
|
8390
|
-
var useAddEntity = () => {
|
|
8391
|
-
const { addEntity } = useViewService();
|
|
8392
|
-
return useMutation66({
|
|
8393
|
-
mutationFn: ({
|
|
8394
|
-
model,
|
|
8395
|
-
values,
|
|
8396
|
-
xNode,
|
|
8397
|
-
service,
|
|
8398
|
-
isCreateEndpoint = false
|
|
8399
|
-
}) => {
|
|
8400
|
-
return addEntity({
|
|
8401
|
-
model,
|
|
8402
|
-
values,
|
|
8403
|
-
xNode,
|
|
8404
|
-
service,
|
|
8405
|
-
isCreateEndpoint
|
|
8406
|
-
});
|
|
8407
|
-
}
|
|
8408
|
-
});
|
|
8409
|
-
};
|
|
8410
|
-
var use_add_entity_default = useAddEntity;
|
|
8411
|
-
|
|
8412
|
-
// src/hooks/view/use-check-payment.ts
|
|
8413
|
-
import { useMutation as useMutation67 } from "@tanstack/react-query";
|
|
8414
|
-
var useCheckPayment = () => {
|
|
8415
|
-
const { checkPayment } = useViewService();
|
|
8416
|
-
return useMutation67({
|
|
8417
|
-
mutationFn: ({
|
|
8418
|
-
model,
|
|
8419
|
-
ids,
|
|
8420
|
-
withContext,
|
|
8421
|
-
xNode,
|
|
8422
|
-
service
|
|
8423
|
-
}) => {
|
|
8424
|
-
return checkPayment({
|
|
8425
|
-
model,
|
|
8426
|
-
ids,
|
|
8427
|
-
withContext,
|
|
8428
|
-
xNode,
|
|
8429
|
-
service
|
|
8430
|
-
});
|
|
8431
|
-
}
|
|
8432
|
-
});
|
|
8433
|
-
};
|
|
8434
|
-
var use_check_payment_default = useCheckPayment;
|
|
8435
|
-
|
|
8436
|
-
// src/hooks/view/use-handle-close-session.ts
|
|
8437
|
-
import { useMutation as useMutation68 } from "@tanstack/react-query";
|
|
8438
|
-
var useHandleCloseSession = () => {
|
|
8439
|
-
const { handleCloseSession } = useViewService();
|
|
8440
|
-
return useMutation68({
|
|
8441
|
-
mutationFn: ({
|
|
8442
|
-
model,
|
|
8443
|
-
ids,
|
|
8444
|
-
xNode,
|
|
8445
|
-
service,
|
|
8446
|
-
method
|
|
8447
|
-
}) => {
|
|
8448
|
-
return handleCloseSession({
|
|
8449
|
-
model,
|
|
8450
|
-
ids,
|
|
8451
|
-
xNode,
|
|
8452
|
-
service,
|
|
8453
|
-
method
|
|
8454
|
-
});
|
|
8455
|
-
}
|
|
8456
|
-
});
|
|
8457
|
-
};
|
|
8458
|
-
var use_handle_close_session_default = useHandleCloseSession;
|
|
8459
|
-
|
|
8460
|
-
// src/hooks/view/use-handle-closing-detail-session.ts
|
|
8461
|
-
import { useMutation as useMutation69 } from "@tanstack/react-query";
|
|
8462
|
-
var useHandleClosingDetailSession = () => {
|
|
8463
|
-
const { handleClosingDetailSession } = useViewService();
|
|
8464
|
-
return useMutation69({
|
|
8465
|
-
mutationFn: ({
|
|
8466
|
-
model,
|
|
8467
|
-
ids,
|
|
8468
|
-
method,
|
|
8469
|
-
xNode,
|
|
8470
|
-
service,
|
|
8471
|
-
kwargs
|
|
8472
|
-
}) => {
|
|
8473
|
-
return handleClosingDetailSession({
|
|
8474
|
-
model,
|
|
8475
|
-
ids,
|
|
8476
|
-
method,
|
|
8477
|
-
xNode,
|
|
8478
|
-
service,
|
|
8479
|
-
kwargs
|
|
8480
|
-
});
|
|
8481
|
-
}
|
|
8482
|
-
});
|
|
8483
|
-
};
|
|
8484
|
-
var use_handle_closing_detail_session_default = useHandleClosingDetailSession;
|
|
8485
|
-
|
|
8486
|
-
// src/hooks/view/use-create-pos-config.ts
|
|
8487
|
-
import { useMutation as useMutation70 } from "@tanstack/react-query";
|
|
8488
|
-
var useCreatePosConfig = () => {
|
|
8489
|
-
const { createPosConfig } = useViewService();
|
|
8490
|
-
return useMutation70({
|
|
8491
|
-
mutationFn: ({
|
|
8492
|
-
model,
|
|
8493
|
-
name,
|
|
8494
|
-
modulePosRestaurant,
|
|
8495
|
-
xNode,
|
|
8496
|
-
service
|
|
8497
|
-
}) => {
|
|
8498
|
-
return createPosConfig({
|
|
8499
|
-
model,
|
|
8500
|
-
name,
|
|
8501
|
-
modulePosRestaurant,
|
|
8502
|
-
xNode,
|
|
8503
|
-
service
|
|
8504
|
-
});
|
|
8505
|
-
}
|
|
8506
|
-
});
|
|
8507
|
-
};
|
|
8508
|
-
var use_create_pos_config_default = useCreatePosConfig;
|
|
8509
|
-
|
|
8510
|
-
// src/hooks/view/use-search-journal.ts
|
|
8511
|
-
import { useMutation as useMutation71 } from "@tanstack/react-query";
|
|
8512
|
-
var useSearchJournal = () => {
|
|
8513
|
-
const { searchJournal } = useViewService();
|
|
8514
|
-
return useMutation71({
|
|
8515
|
-
mutationFn: ({
|
|
8516
|
-
model,
|
|
8517
|
-
method,
|
|
8518
|
-
args,
|
|
8519
|
-
kwargs,
|
|
8520
|
-
xNode,
|
|
8521
|
-
service
|
|
8522
|
-
}) => {
|
|
8523
|
-
return searchJournal({
|
|
8524
|
-
model,
|
|
8525
|
-
method,
|
|
8526
|
-
args,
|
|
8527
|
-
kwargs,
|
|
8528
|
-
xNode,
|
|
8529
|
-
service
|
|
8530
|
-
});
|
|
8531
|
-
}
|
|
8532
|
-
});
|
|
8533
|
-
};
|
|
8534
|
-
var use_search_journal_default = useSearchJournal;
|
|
8535
|
-
|
|
8536
|
-
// src/hooks/view/useGetPreparaionDisplayData.ts
|
|
8537
|
-
import { useMutation as useMutation72 } from "@tanstack/react-query";
|
|
8538
|
-
var useGetPreparationDisplayData = () => {
|
|
8539
|
-
const { getPreparationDisplayData } = useViewService();
|
|
8540
|
-
return useMutation72({
|
|
8541
|
-
mutationFn: ({
|
|
8542
|
-
ids,
|
|
8543
|
-
service,
|
|
8544
|
-
xNode,
|
|
8545
|
-
withContext
|
|
8546
|
-
}) => {
|
|
8547
|
-
return getPreparationDisplayData({
|
|
8548
|
-
ids,
|
|
8549
|
-
service,
|
|
8550
|
-
xNode,
|
|
8551
|
-
withContext
|
|
8552
|
-
});
|
|
8553
|
-
}
|
|
8554
|
-
});
|
|
8555
|
-
};
|
|
8556
|
-
var useGetPreparaionDisplayData_default = useGetPreparationDisplayData;
|
|
8557
|
-
|
|
8558
|
-
// src/hooks/view/useChangeOrderPreparaionState.ts
|
|
8559
|
-
import { useMutation as useMutation73 } from "@tanstack/react-query";
|
|
8560
|
-
var useChangeOrderPreparationState = () => {
|
|
8561
|
-
const { changeOrderPreparaionState } = useViewService();
|
|
8562
|
-
return useMutation73({
|
|
8563
|
-
mutationFn: ({
|
|
8564
|
-
orderId,
|
|
8565
|
-
stageId,
|
|
8566
|
-
preparationDisplayId,
|
|
8567
|
-
service,
|
|
8568
|
-
xNode
|
|
8569
|
-
}) => {
|
|
8570
|
-
return changeOrderPreparaionState({
|
|
8571
|
-
orderId,
|
|
8572
|
-
stageId,
|
|
8573
|
-
preparationDisplayId,
|
|
8574
|
-
service,
|
|
8575
|
-
xNode
|
|
8576
|
-
});
|
|
8577
|
-
}
|
|
8578
|
-
});
|
|
8579
|
-
};
|
|
8580
|
-
var useChangeOrderPreparaionState_default = useChangeOrderPreparationState;
|
|
8581
|
-
|
|
8582
|
-
// src/hooks/view/use-update-order-status.ts
|
|
8583
|
-
import { useMutation as useMutation74 } from "@tanstack/react-query";
|
|
8584
|
-
var useUpdateOrderStatus = () => {
|
|
8585
|
-
const { updateOrderStatus } = useViewService();
|
|
8586
|
-
return useMutation74({
|
|
8587
|
-
mutationFn: ({
|
|
8588
|
-
orderId,
|
|
8589
|
-
state,
|
|
8590
|
-
service,
|
|
8591
|
-
xNode
|
|
8592
|
-
}) => {
|
|
8593
|
-
return updateOrderStatus({
|
|
8594
|
-
orderId,
|
|
8595
|
-
state,
|
|
8596
|
-
service,
|
|
8597
|
-
xNode
|
|
8598
|
-
});
|
|
8599
|
-
}
|
|
8600
|
-
});
|
|
8601
|
-
};
|
|
8602
|
-
var use_update_order_status_default = useUpdateOrderStatus;
|
|
8603
|
-
|
|
8604
|
-
// src/hooks/view/use-process-order.ts
|
|
8605
|
-
import { useMutation as useMutation75 } from "@tanstack/react-query";
|
|
8606
|
-
var useProcessOrder = () => {
|
|
8607
|
-
const { processOrder } = useViewService();
|
|
8608
|
-
return useMutation75({
|
|
8609
|
-
mutationFn: ({
|
|
8610
|
-
orderId,
|
|
8611
|
-
xNode,
|
|
8612
|
-
service
|
|
8613
|
-
}) => processOrder({
|
|
8614
|
-
orderId,
|
|
8615
|
-
xNode,
|
|
8616
|
-
service
|
|
8617
|
-
})
|
|
8618
|
-
});
|
|
8619
|
-
};
|
|
8620
|
-
var use_process_order_default = useProcessOrder;
|
|
8621
|
-
|
|
8622
|
-
// src/hooks/view/use-generate-payment-qr-info.ts
|
|
8623
|
-
import { useMutation as useMutation76 } from "@tanstack/react-query";
|
|
8624
|
-
var useGeneratePaymentQrInfo = () => {
|
|
8625
|
-
const { generatePaymentQRInfo } = useViewService();
|
|
8626
|
-
return useMutation76({
|
|
8627
|
-
mutationFn: ({
|
|
8628
|
-
orderId,
|
|
8629
|
-
amount,
|
|
8630
|
-
posSessionId,
|
|
8631
|
-
xNode,
|
|
8632
|
-
service
|
|
8633
|
-
}) => {
|
|
8634
|
-
return generatePaymentQRInfo({
|
|
8635
|
-
orderId,
|
|
8636
|
-
amount,
|
|
8637
|
-
posSessionId,
|
|
8638
|
-
xNode,
|
|
8639
|
-
service
|
|
8640
|
-
});
|
|
8641
|
-
}
|
|
8642
|
-
});
|
|
8643
|
-
};
|
|
8644
|
-
var use_generate_payment_qr_info_default = useGeneratePaymentQrInfo;
|
|
8645
|
-
|
|
8646
|
-
// src/hooks/view/use-save-pin-code.ts
|
|
8647
|
-
import { useMutation as useMutation77 } from "@tanstack/react-query";
|
|
8648
|
-
var useSavePinCode = () => {
|
|
8649
|
-
const { savePinCode } = useViewService();
|
|
8650
|
-
return useMutation77({
|
|
8651
|
-
mutationFn: ({
|
|
8652
|
-
serialNumber,
|
|
8653
|
-
pinCode,
|
|
8654
|
-
xNode,
|
|
8655
|
-
service
|
|
8656
|
-
}) => {
|
|
8657
|
-
return savePinCode({
|
|
8658
|
-
serialNumber,
|
|
8659
|
-
pinCode,
|
|
8660
|
-
xNode,
|
|
8661
|
-
service
|
|
8662
|
-
});
|
|
8663
|
-
}
|
|
8664
|
-
});
|
|
8665
|
-
};
|
|
8666
|
-
var use_save_pin_code_default = useSavePinCode;
|
|
8667
|
-
|
|
8668
|
-
// src/hooks/view/use-get-pin-code.ts
|
|
8669
|
-
import { useMutation as useMutation78 } from "@tanstack/react-query";
|
|
8670
|
-
var useGetPinCode = () => {
|
|
8671
|
-
const { getPinCode } = useViewService();
|
|
8672
|
-
return useMutation78({
|
|
8673
|
-
mutationFn: ({
|
|
8674
|
-
serialNumber,
|
|
8675
|
-
xNode,
|
|
8676
|
-
service
|
|
8677
|
-
}) => {
|
|
8678
|
-
return getPinCode({
|
|
8679
|
-
serialNumber,
|
|
8680
|
-
xNode,
|
|
8681
|
-
service
|
|
8682
|
-
});
|
|
8683
|
-
}
|
|
8684
|
-
});
|
|
8685
|
-
};
|
|
8686
|
-
var use_get_pin_code_default = useGetPinCode;
|
|
8279
|
+
var use_gen_serial_number_default = useGenSerialNumber;
|
|
8687
8280
|
|
|
8688
8281
|
// src/hooks/view/use-get-notifications.ts
|
|
8689
8282
|
import { useQuery as useQuery23 } from "@tanstack/react-query";
|
|
@@ -8707,10 +8300,10 @@ var useGetNotifications = ({
|
|
|
8707
8300
|
var use_get_notifications_default = useGetNotifications;
|
|
8708
8301
|
|
|
8709
8302
|
// src/hooks/view/use-get-version.ts
|
|
8710
|
-
import { useMutation as
|
|
8303
|
+
import { useMutation as useMutation52 } from "@tanstack/react-query";
|
|
8711
8304
|
var useGetVersion = () => {
|
|
8712
8305
|
const { getVersion } = useViewService();
|
|
8713
|
-
return
|
|
8306
|
+
return useMutation52({
|
|
8714
8307
|
mutationFn: () => {
|
|
8715
8308
|
return getVersion();
|
|
8716
8309
|
}
|
|
@@ -8718,52 +8311,11 @@ var useGetVersion = () => {
|
|
|
8718
8311
|
};
|
|
8719
8312
|
var use_get_version_default = useGetVersion;
|
|
8720
8313
|
|
|
8721
|
-
// src/hooks/view/use-create-e-invoice.ts
|
|
8722
|
-
import { useMutation as useMutation80 } from "@tanstack/react-query";
|
|
8723
|
-
var useCreateEInvoice = () => {
|
|
8724
|
-
const { createEInvoice } = useViewService();
|
|
8725
|
-
return useMutation80({
|
|
8726
|
-
mutationFn: ({
|
|
8727
|
-
service,
|
|
8728
|
-
xNode,
|
|
8729
|
-
kwargs,
|
|
8730
|
-
ids,
|
|
8731
|
-
withContext
|
|
8732
|
-
}) => {
|
|
8733
|
-
return createEInvoice({
|
|
8734
|
-
kwargs,
|
|
8735
|
-
ids,
|
|
8736
|
-
xNode,
|
|
8737
|
-
service,
|
|
8738
|
-
withContext
|
|
8739
|
-
});
|
|
8740
|
-
}
|
|
8741
|
-
});
|
|
8742
|
-
};
|
|
8743
|
-
var use_create_e_invoice_default = useCreateEInvoice;
|
|
8744
|
-
|
|
8745
|
-
// src/hooks/view/use-get-current-user.ts
|
|
8746
|
-
import { useMutation as useMutation81 } from "@tanstack/react-query";
|
|
8747
|
-
var useGetCurrentUser = () => {
|
|
8748
|
-
const { getCurrentUser } = useViewService();
|
|
8749
|
-
return useMutation81({
|
|
8750
|
-
mutationFn: ({
|
|
8751
|
-
service,
|
|
8752
|
-
xNode,
|
|
8753
|
-
oauthUid,
|
|
8754
|
-
extraHeaders
|
|
8755
|
-
}) => {
|
|
8756
|
-
return getCurrentUser({ service, xNode, oauthUid, extraHeaders });
|
|
8757
|
-
}
|
|
8758
|
-
});
|
|
8759
|
-
};
|
|
8760
|
-
var use_get_current_user_default = useGetCurrentUser;
|
|
8761
|
-
|
|
8762
8314
|
// src/hooks/view/use-get-ward.ts
|
|
8763
|
-
import { useMutation as
|
|
8315
|
+
import { useMutation as useMutation53 } from "@tanstack/react-query";
|
|
8764
8316
|
var useGetWard = () => {
|
|
8765
8317
|
const { getWard } = useViewService();
|
|
8766
|
-
return
|
|
8318
|
+
return useMutation53({
|
|
8767
8319
|
mutationFn: ({
|
|
8768
8320
|
service,
|
|
8769
8321
|
xNode,
|
|
@@ -8780,10 +8332,10 @@ var useGetWard = () => {
|
|
|
8780
8332
|
var use_get_ward_default = useGetWard;
|
|
8781
8333
|
|
|
8782
8334
|
// src/hooks/view/use-get-city.ts
|
|
8783
|
-
import { useMutation as
|
|
8335
|
+
import { useMutation as useMutation54 } from "@tanstack/react-query";
|
|
8784
8336
|
var useGetCity = () => {
|
|
8785
8337
|
const { getCity } = useViewService();
|
|
8786
|
-
return
|
|
8338
|
+
return useMutation54({
|
|
8787
8339
|
mutationFn: ({
|
|
8788
8340
|
service,
|
|
8789
8341
|
xNode,
|
|
@@ -8802,10 +8354,10 @@ var useGetCity = () => {
|
|
|
8802
8354
|
var use_get_city_default = useGetCity;
|
|
8803
8355
|
|
|
8804
8356
|
// src/hooks/view/use-get-country.ts
|
|
8805
|
-
import { useMutation as
|
|
8357
|
+
import { useMutation as useMutation55 } from "@tanstack/react-query";
|
|
8806
8358
|
var useGetCountry = () => {
|
|
8807
8359
|
const { getCountry } = useViewService();
|
|
8808
|
-
return
|
|
8360
|
+
return useMutation55({
|
|
8809
8361
|
mutationFn: ({
|
|
8810
8362
|
service,
|
|
8811
8363
|
xNode,
|
|
@@ -8824,10 +8376,10 @@ var useGetCountry = () => {
|
|
|
8824
8376
|
var use_get_country_default = useGetCountry;
|
|
8825
8377
|
|
|
8826
8378
|
// src/hooks/view/use-get-partner-title.ts
|
|
8827
|
-
import { useMutation as
|
|
8379
|
+
import { useMutation as useMutation56 } from "@tanstack/react-query";
|
|
8828
8380
|
var useGetPartnerTitle = () => {
|
|
8829
8381
|
const { getPartnerTitle } = useViewService();
|
|
8830
|
-
return
|
|
8382
|
+
return useMutation56({
|
|
8831
8383
|
mutationFn: ({
|
|
8832
8384
|
service,
|
|
8833
8385
|
xNode,
|
|
@@ -8881,6 +8433,296 @@ var useGetDataChart = (services, xNode, body, enabled, path, method, queryKey) =
|
|
|
8881
8433
|
};
|
|
8882
8434
|
var use_get_data_chart_default = useGetDataChart;
|
|
8883
8435
|
|
|
8436
|
+
// src/hooks/pos/use-add-entity.ts
|
|
8437
|
+
import { useMutation as useMutation57 } from "@tanstack/react-query";
|
|
8438
|
+
var useAddEntity = () => {
|
|
8439
|
+
const { addEntity } = usePosService();
|
|
8440
|
+
return useMutation57({
|
|
8441
|
+
mutationFn: addEntity
|
|
8442
|
+
});
|
|
8443
|
+
};
|
|
8444
|
+
var use_add_entity_default = useAddEntity;
|
|
8445
|
+
|
|
8446
|
+
// src/hooks/pos/use-get-a-session.ts
|
|
8447
|
+
import { useMutation as useMutation58 } from "@tanstack/react-query";
|
|
8448
|
+
var useGetASession = () => {
|
|
8449
|
+
const pos = usePosService();
|
|
8450
|
+
return useMutation58({
|
|
8451
|
+
mutationFn: pos.getASession
|
|
8452
|
+
});
|
|
8453
|
+
};
|
|
8454
|
+
var use_get_a_session_default = useGetASession;
|
|
8455
|
+
|
|
8456
|
+
// src/hooks/pos/use-change-order-preparation-state.ts
|
|
8457
|
+
import { useMutation as useMutation59 } from "@tanstack/react-query";
|
|
8458
|
+
var useChangeOrderPreparationState = () => {
|
|
8459
|
+
const pos = usePosService();
|
|
8460
|
+
return useMutation59({
|
|
8461
|
+
mutationFn: pos.changeOrderPreparationState
|
|
8462
|
+
});
|
|
8463
|
+
};
|
|
8464
|
+
var use_change_order_preparation_state_default = useChangeOrderPreparationState;
|
|
8465
|
+
|
|
8466
|
+
// src/hooks/pos/use-check-payment.ts
|
|
8467
|
+
import { useMutation as useMutation60 } from "@tanstack/react-query";
|
|
8468
|
+
var useCheckPayment = () => {
|
|
8469
|
+
const pos = usePosService();
|
|
8470
|
+
return useMutation60({
|
|
8471
|
+
mutationFn: pos.checkPayment
|
|
8472
|
+
});
|
|
8473
|
+
};
|
|
8474
|
+
var use_check_payment_default = useCheckPayment;
|
|
8475
|
+
|
|
8476
|
+
// src/hooks/pos/use-create-e-invoice.ts
|
|
8477
|
+
import { useMutation as useMutation61 } from "@tanstack/react-query";
|
|
8478
|
+
var useCreateEInvoice = () => {
|
|
8479
|
+
const pos = usePosService();
|
|
8480
|
+
return useMutation61({
|
|
8481
|
+
mutationFn: pos.createEInvoice
|
|
8482
|
+
});
|
|
8483
|
+
};
|
|
8484
|
+
var use_create_e_invoice_default = useCreateEInvoice;
|
|
8485
|
+
|
|
8486
|
+
// src/hooks/pos/use-create-entity.ts
|
|
8487
|
+
import { useMutation as useMutation62 } from "@tanstack/react-query";
|
|
8488
|
+
var useCreateEntity = () => {
|
|
8489
|
+
const pos = usePosService();
|
|
8490
|
+
return useMutation62({
|
|
8491
|
+
mutationFn: pos.createEntity
|
|
8492
|
+
});
|
|
8493
|
+
};
|
|
8494
|
+
var use_create_entity_default = useCreateEntity;
|
|
8495
|
+
|
|
8496
|
+
// src/hooks/pos/use-create-pos-config.ts
|
|
8497
|
+
import { useMutation as useMutation63 } from "@tanstack/react-query";
|
|
8498
|
+
var useCreatePosConfig = () => {
|
|
8499
|
+
const pos = usePosService();
|
|
8500
|
+
return useMutation63({
|
|
8501
|
+
mutationFn: pos.createPosConfig
|
|
8502
|
+
});
|
|
8503
|
+
};
|
|
8504
|
+
var use_create_pos_config_default = useCreatePosConfig;
|
|
8505
|
+
|
|
8506
|
+
// src/hooks/pos/use-create-session.ts
|
|
8507
|
+
import { useMutation as useMutation64 } from "@tanstack/react-query";
|
|
8508
|
+
var useCreateSession = () => {
|
|
8509
|
+
const pos = usePosService();
|
|
8510
|
+
return useMutation64({
|
|
8511
|
+
mutationFn: pos.createSession
|
|
8512
|
+
});
|
|
8513
|
+
};
|
|
8514
|
+
var use_create_session_default = useCreateSession;
|
|
8515
|
+
|
|
8516
|
+
// src/hooks/pos/use-delete-entity.ts
|
|
8517
|
+
import { useMutation as useMutation65 } from "@tanstack/react-query";
|
|
8518
|
+
var useDeleteEntity = () => {
|
|
8519
|
+
const pos = usePosService();
|
|
8520
|
+
return useMutation65({
|
|
8521
|
+
mutationFn: pos.deleteEntity
|
|
8522
|
+
});
|
|
8523
|
+
};
|
|
8524
|
+
var use_delete_entity_default = useDeleteEntity;
|
|
8525
|
+
|
|
8526
|
+
// src/hooks/pos/use-generate-payment-qr-info.ts
|
|
8527
|
+
import { useMutation as useMutation66 } from "@tanstack/react-query";
|
|
8528
|
+
var useGeneratePaymentQrInfo = () => {
|
|
8529
|
+
const pos = usePosService();
|
|
8530
|
+
return useMutation66({
|
|
8531
|
+
mutationFn: pos.generatePaymentQRInfo
|
|
8532
|
+
});
|
|
8533
|
+
};
|
|
8534
|
+
var use_generate_payment_qr_info_default = useGeneratePaymentQrInfo;
|
|
8535
|
+
|
|
8536
|
+
// src/hooks/pos/use-get-current-user.ts
|
|
8537
|
+
import { useMutation as useMutation67 } from "@tanstack/react-query";
|
|
8538
|
+
var useGetCurrentUser = () => {
|
|
8539
|
+
const pos = usePosService();
|
|
8540
|
+
return useMutation67({
|
|
8541
|
+
mutationFn: pos.getCurrentUser
|
|
8542
|
+
});
|
|
8543
|
+
};
|
|
8544
|
+
var use_get_current_user_default = useGetCurrentUser;
|
|
8545
|
+
|
|
8546
|
+
// src/hooks/pos/use-get-list.ts
|
|
8547
|
+
import { useMutation as useMutation68 } from "@tanstack/react-query";
|
|
8548
|
+
var useGetList = () => {
|
|
8549
|
+
const pos = usePosService();
|
|
8550
|
+
return useMutation68({
|
|
8551
|
+
mutationFn: pos.getList
|
|
8552
|
+
});
|
|
8553
|
+
};
|
|
8554
|
+
var use_get_list_default = useGetList;
|
|
8555
|
+
|
|
8556
|
+
// src/hooks/pos/use-get-order-line.ts
|
|
8557
|
+
import { useMutation as useMutation69 } from "@tanstack/react-query";
|
|
8558
|
+
var useGetOrderLine = () => {
|
|
8559
|
+
const pos = usePosService();
|
|
8560
|
+
return useMutation69({
|
|
8561
|
+
mutationFn: pos.getOrderLine
|
|
8562
|
+
});
|
|
8563
|
+
};
|
|
8564
|
+
var use_get_order_line_default = useGetOrderLine;
|
|
8565
|
+
|
|
8566
|
+
// src/hooks/pos/use-get-pin-code.ts
|
|
8567
|
+
import { useMutation as useMutation70 } from "@tanstack/react-query";
|
|
8568
|
+
var useGetPinCode = () => {
|
|
8569
|
+
const pos = usePosService();
|
|
8570
|
+
return useMutation70({
|
|
8571
|
+
mutationFn: pos.getPinCode
|
|
8572
|
+
});
|
|
8573
|
+
};
|
|
8574
|
+
var use_get_pin_code_default = useGetPinCode;
|
|
8575
|
+
|
|
8576
|
+
// src/hooks/pos/use-get-pos.ts
|
|
8577
|
+
import { useMutation as useMutation71 } from "@tanstack/react-query";
|
|
8578
|
+
var useGetPos = () => {
|
|
8579
|
+
const pos = usePosService();
|
|
8580
|
+
return useMutation71({
|
|
8581
|
+
mutationFn: pos.getPOS
|
|
8582
|
+
});
|
|
8583
|
+
};
|
|
8584
|
+
var use_get_pos_default = useGetPos;
|
|
8585
|
+
|
|
8586
|
+
// src/hooks/pos/use-get-preparation-display-data.ts
|
|
8587
|
+
import { useMutation as useMutation72 } from "@tanstack/react-query";
|
|
8588
|
+
var useGetPreparationDisplayData = () => {
|
|
8589
|
+
const pos = usePosService();
|
|
8590
|
+
return useMutation72({
|
|
8591
|
+
mutationFn: pos.getPreparationDisplayData
|
|
8592
|
+
});
|
|
8593
|
+
};
|
|
8594
|
+
var use_get_preparation_display_data_default = useGetPreparationDisplayData;
|
|
8595
|
+
|
|
8596
|
+
// src/hooks/pos/use-get-product-image.ts
|
|
8597
|
+
import { useMutation as useMutation73 } from "@tanstack/react-query";
|
|
8598
|
+
var useGetProductImage = () => {
|
|
8599
|
+
const pos = usePosService();
|
|
8600
|
+
return useMutation73({
|
|
8601
|
+
mutationFn: pos.getProductImage
|
|
8602
|
+
});
|
|
8603
|
+
};
|
|
8604
|
+
var use_get_product_image_default = useGetProductImage;
|
|
8605
|
+
|
|
8606
|
+
// src/hooks/pos/use-handle-close-session.ts
|
|
8607
|
+
import { useMutation as useMutation74 } from "@tanstack/react-query";
|
|
8608
|
+
var useHandleCloseSession = () => {
|
|
8609
|
+
const pos = usePosService();
|
|
8610
|
+
return useMutation74({
|
|
8611
|
+
mutationFn: pos.handleCloseSession
|
|
8612
|
+
});
|
|
8613
|
+
};
|
|
8614
|
+
var use_handle_close_session_default = useHandleCloseSession;
|
|
8615
|
+
|
|
8616
|
+
// src/hooks/pos/use-handle-closing-detail-session.ts
|
|
8617
|
+
import { useMutation as useMutation75 } from "@tanstack/react-query";
|
|
8618
|
+
var useHandleClosingDetailSession = () => {
|
|
8619
|
+
const pos = usePosService();
|
|
8620
|
+
return useMutation75({
|
|
8621
|
+
mutationFn: pos.handleClosingDetailSession
|
|
8622
|
+
});
|
|
8623
|
+
};
|
|
8624
|
+
var use_handle_closing_detail_session_default = useHandleClosingDetailSession;
|
|
8625
|
+
|
|
8626
|
+
// src/hooks/pos/use-handle-closing-session.ts
|
|
8627
|
+
import { useMutation as useMutation76 } from "@tanstack/react-query";
|
|
8628
|
+
var useHandleClosingSession = () => {
|
|
8629
|
+
const pos = usePosService();
|
|
8630
|
+
return useMutation76({
|
|
8631
|
+
mutationFn: pos.handleClosingSession
|
|
8632
|
+
});
|
|
8633
|
+
};
|
|
8634
|
+
var use_handle_closing_session_default = useHandleClosingSession;
|
|
8635
|
+
|
|
8636
|
+
// src/hooks/pos/use-load-data-pos-session.ts
|
|
8637
|
+
import { useMutation as useMutation77 } from "@tanstack/react-query";
|
|
8638
|
+
var useLoadDataPosSession = () => {
|
|
8639
|
+
const pos = usePosService();
|
|
8640
|
+
return useMutation77({
|
|
8641
|
+
mutationFn: pos.loadDataPosSession
|
|
8642
|
+
});
|
|
8643
|
+
};
|
|
8644
|
+
var use_load_data_pos_session_default = useLoadDataPosSession;
|
|
8645
|
+
|
|
8646
|
+
// src/hooks/pos/use-manage-onchange.ts
|
|
8647
|
+
import { useMutation as useMutation78 } from "@tanstack/react-query";
|
|
8648
|
+
var useManageOnChange = () => {
|
|
8649
|
+
const pos = usePosService();
|
|
8650
|
+
return useMutation78({
|
|
8651
|
+
mutationFn: pos.manageOnChange
|
|
8652
|
+
});
|
|
8653
|
+
};
|
|
8654
|
+
var use_manage_onchange_default = useManageOnChange;
|
|
8655
|
+
|
|
8656
|
+
// src/hooks/pos/use-manage-session.ts
|
|
8657
|
+
import { useMutation as useMutation79 } from "@tanstack/react-query";
|
|
8658
|
+
var useManageSession = () => {
|
|
8659
|
+
const pos = usePosService();
|
|
8660
|
+
return useMutation79({
|
|
8661
|
+
mutationFn: pos.manageSession
|
|
8662
|
+
});
|
|
8663
|
+
};
|
|
8664
|
+
var use_manage_session_default = useManageSession;
|
|
8665
|
+
|
|
8666
|
+
// src/hooks/pos/use-process-order.ts
|
|
8667
|
+
import { useMutation as useMutation80 } from "@tanstack/react-query";
|
|
8668
|
+
var useProcessOrder = () => {
|
|
8669
|
+
const pos = usePosService();
|
|
8670
|
+
return useMutation80({
|
|
8671
|
+
mutationFn: pos.processOrder
|
|
8672
|
+
});
|
|
8673
|
+
};
|
|
8674
|
+
var use_process_order_default = useProcessOrder;
|
|
8675
|
+
|
|
8676
|
+
// src/hooks/pos/use-save-pin-code.ts
|
|
8677
|
+
import { useMutation as useMutation81 } from "@tanstack/react-query";
|
|
8678
|
+
var useSavePinCode = () => {
|
|
8679
|
+
const pos = usePosService();
|
|
8680
|
+
return useMutation81({
|
|
8681
|
+
mutationFn: pos.savePinCode
|
|
8682
|
+
});
|
|
8683
|
+
};
|
|
8684
|
+
var use_save_pin_code_default = useSavePinCode;
|
|
8685
|
+
|
|
8686
|
+
// src/hooks/pos/use-search-journal.ts
|
|
8687
|
+
import { useMutation as useMutation82 } from "@tanstack/react-query";
|
|
8688
|
+
var useSearchJournal = () => {
|
|
8689
|
+
const pos = usePosService();
|
|
8690
|
+
return useMutation82({
|
|
8691
|
+
mutationFn: pos.searchJournal
|
|
8692
|
+
});
|
|
8693
|
+
};
|
|
8694
|
+
var use_search_journal_default = useSearchJournal;
|
|
8695
|
+
|
|
8696
|
+
// src/hooks/pos/use-update-closed-session.ts
|
|
8697
|
+
import { useMutation as useMutation83 } from "@tanstack/react-query";
|
|
8698
|
+
var useUpdateClosedSession = () => {
|
|
8699
|
+
const pos = usePosService();
|
|
8700
|
+
return useMutation83({
|
|
8701
|
+
mutationFn: pos.updateClosedSession
|
|
8702
|
+
});
|
|
8703
|
+
};
|
|
8704
|
+
var use_update_closed_session_default = useUpdateClosedSession;
|
|
8705
|
+
|
|
8706
|
+
// src/hooks/pos/use-update-entity.ts
|
|
8707
|
+
import { useMutation as useMutation84 } from "@tanstack/react-query";
|
|
8708
|
+
var useUpdateEntity = () => {
|
|
8709
|
+
const pos = usePosService();
|
|
8710
|
+
return useMutation84({
|
|
8711
|
+
mutationFn: pos.updateEntity
|
|
8712
|
+
});
|
|
8713
|
+
};
|
|
8714
|
+
var use_update_entity_default = useUpdateEntity;
|
|
8715
|
+
|
|
8716
|
+
// src/hooks/pos/use-update-order-status.ts
|
|
8717
|
+
import { useMutation as useMutation85 } from "@tanstack/react-query";
|
|
8718
|
+
var useUpdateOrderStatus = () => {
|
|
8719
|
+
const pos = usePosService();
|
|
8720
|
+
return useMutation85({
|
|
8721
|
+
mutationFn: pos.updateOrderStatus
|
|
8722
|
+
});
|
|
8723
|
+
};
|
|
8724
|
+
var use_update_order_status_default = useUpdateOrderStatus;
|
|
8725
|
+
|
|
8884
8726
|
// src/provider/service-provider.tsx
|
|
8885
8727
|
import { jsx as jsx6 } from "react/jsx-runtime";
|
|
8886
8728
|
var ServiceContext = createContext2(null);
|
|
@@ -8968,7 +8810,7 @@ var ServiceProvider = ({
|
|
|
8968
8810
|
useUpdateClosedSession: use_update_closed_session_default,
|
|
8969
8811
|
useUpdateEntity: use_update_entity_default,
|
|
8970
8812
|
useLoadDataPosSession: use_load_data_pos_session_default,
|
|
8971
|
-
useManageOnChange:
|
|
8813
|
+
useManageOnChange: use_manage_onchange_default,
|
|
8972
8814
|
useGenSerialNumber: use_gen_serial_number_default,
|
|
8973
8815
|
useGetOrderLine: use_get_order_line_default,
|
|
8974
8816
|
useGetProductImage: use_get_product_image_default,
|
|
@@ -8980,8 +8822,8 @@ var ServiceProvider = ({
|
|
|
8980
8822
|
useSearchJournal: use_search_journal_default,
|
|
8981
8823
|
useGetTenantMapping: use_get_tenant_mapping_default,
|
|
8982
8824
|
useGetToken: use_get_token_default,
|
|
8983
|
-
useGetPreparationDisplayData:
|
|
8984
|
-
|
|
8825
|
+
useGetPreparationDisplayData: use_get_preparation_display_data_default,
|
|
8826
|
+
useChangeOrderPreparationState: use_change_order_preparation_state_default,
|
|
8985
8827
|
useUpdateOrderStatus: use_update_order_status_default,
|
|
8986
8828
|
useGetThreadData: use_get_thread_data_default,
|
|
8987
8829
|
useGetThreadMessages: use_get_thread_messages_default,
|