@fctc/interface-logic 2.9.1 → 2.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/hooks.d.mts +6 -0
- package/dist/hooks.d.ts +6 -0
- package/dist/hooks.js +55 -20
- package/dist/hooks.mjs +55 -20
- package/dist/provider.js +55 -20
- package/dist/provider.mjs +55 -20
- package/dist/services.d.mts +9 -3
- package/dist/services.d.ts +9 -3
- package/dist/services.js +35 -14
- package/dist/services.mjs +35 -14
- package/package.json +1 -1
package/dist/hooks.d.mts
CHANGED
|
@@ -81,10 +81,14 @@ declare const useParsePreview: () => _tanstack_react_query.UseMutationResult<any
|
|
|
81
81
|
selectedSheet: any;
|
|
82
82
|
isHeader: boolean;
|
|
83
83
|
context: any;
|
|
84
|
+
service?: string;
|
|
85
|
+
xNode?: string;
|
|
84
86
|
}, unknown>;
|
|
85
87
|
|
|
86
88
|
declare const useUploadFileExcel: () => _tanstack_react_query.UseMutationResult<any, Error, {
|
|
87
89
|
formData: any;
|
|
90
|
+
service?: string;
|
|
91
|
+
xNode?: string;
|
|
88
92
|
}, unknown>;
|
|
89
93
|
|
|
90
94
|
declare const useUploadIdFile: () => _tanstack_react_query.UseMutationResult<any, Error, {
|
|
@@ -98,6 +102,8 @@ declare const useExecuteImport: () => _tanstack_react_query.UseMutationResult<an
|
|
|
98
102
|
options: any;
|
|
99
103
|
dryrun: any;
|
|
100
104
|
context: any;
|
|
105
|
+
service?: string;
|
|
106
|
+
xNode?: string;
|
|
101
107
|
}, unknown>;
|
|
102
108
|
|
|
103
109
|
declare const useChangeStatus: () => _tanstack_react_query.UseMutationResult<any, Error, {
|
package/dist/hooks.d.ts
CHANGED
|
@@ -81,10 +81,14 @@ declare const useParsePreview: () => _tanstack_react_query.UseMutationResult<any
|
|
|
81
81
|
selectedSheet: any;
|
|
82
82
|
isHeader: boolean;
|
|
83
83
|
context: any;
|
|
84
|
+
service?: string;
|
|
85
|
+
xNode?: string;
|
|
84
86
|
}, unknown>;
|
|
85
87
|
|
|
86
88
|
declare const useUploadFileExcel: () => _tanstack_react_query.UseMutationResult<any, Error, {
|
|
87
89
|
formData: any;
|
|
90
|
+
service?: string;
|
|
91
|
+
xNode?: string;
|
|
88
92
|
}, unknown>;
|
|
89
93
|
|
|
90
94
|
declare const useUploadIdFile: () => _tanstack_react_query.UseMutationResult<any, Error, {
|
|
@@ -98,6 +102,8 @@ declare const useExecuteImport: () => _tanstack_react_query.UseMutationResult<an
|
|
|
98
102
|
options: any;
|
|
99
103
|
dryrun: any;
|
|
100
104
|
context: any;
|
|
105
|
+
service?: string;
|
|
106
|
+
xNode?: string;
|
|
101
107
|
}, unknown>;
|
|
102
108
|
|
|
103
109
|
declare const useChangeStatus: () => _tanstack_react_query.UseMutationResult<any, Error, {
|
package/dist/hooks.js
CHANGED
|
@@ -3429,8 +3429,19 @@ var import_react9 = require("react");
|
|
|
3429
3429
|
function useExcelService() {
|
|
3430
3430
|
const { env } = useEnv();
|
|
3431
3431
|
const uploadFileExcel = (0, import_react9.useCallback)(
|
|
3432
|
-
async ({
|
|
3433
|
-
|
|
3432
|
+
async ({
|
|
3433
|
+
formData,
|
|
3434
|
+
service,
|
|
3435
|
+
xNode
|
|
3436
|
+
}) => {
|
|
3437
|
+
return env.requests.post(
|
|
3438
|
+
"/upload/file" /* UPLOAD_FILE_EXCEL_PATH */,
|
|
3439
|
+
formData,
|
|
3440
|
+
{
|
|
3441
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3442
|
+
},
|
|
3443
|
+
service
|
|
3444
|
+
);
|
|
3434
3445
|
},
|
|
3435
3446
|
[env]
|
|
3436
3447
|
);
|
|
@@ -3449,7 +3460,9 @@ function useExcelService() {
|
|
|
3449
3460
|
id,
|
|
3450
3461
|
selectedSheet,
|
|
3451
3462
|
isHeader,
|
|
3452
|
-
context
|
|
3463
|
+
context,
|
|
3464
|
+
service,
|
|
3465
|
+
xNode
|
|
3453
3466
|
}) => {
|
|
3454
3467
|
const jsonData = {
|
|
3455
3468
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3480,11 +3493,14 @@ function useExcelService() {
|
|
|
3480
3493
|
},
|
|
3481
3494
|
with_context: context
|
|
3482
3495
|
};
|
|
3483
|
-
return env.requests.post(
|
|
3484
|
-
|
|
3485
|
-
|
|
3486
|
-
|
|
3487
|
-
|
|
3496
|
+
return env.requests.post(
|
|
3497
|
+
"/call" /* CALL_PATH */,
|
|
3498
|
+
jsonData,
|
|
3499
|
+
{
|
|
3500
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3501
|
+
},
|
|
3502
|
+
service
|
|
3503
|
+
);
|
|
3488
3504
|
},
|
|
3489
3505
|
[env]
|
|
3490
3506
|
);
|
|
@@ -3495,7 +3511,9 @@ function useExcelService() {
|
|
|
3495
3511
|
idFile,
|
|
3496
3512
|
options,
|
|
3497
3513
|
dryrun,
|
|
3498
|
-
context
|
|
3514
|
+
context,
|
|
3515
|
+
service,
|
|
3516
|
+
xNode
|
|
3499
3517
|
}) => {
|
|
3500
3518
|
const jsonData = {
|
|
3501
3519
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3509,11 +3527,14 @@ function useExcelService() {
|
|
|
3509
3527
|
},
|
|
3510
3528
|
with_context: context
|
|
3511
3529
|
};
|
|
3512
|
-
return env.requests.post(
|
|
3513
|
-
|
|
3514
|
-
|
|
3515
|
-
|
|
3516
|
-
|
|
3530
|
+
return env.requests.post(
|
|
3531
|
+
"/call" /* CALL_PATH */,
|
|
3532
|
+
jsonData,
|
|
3533
|
+
{
|
|
3534
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3535
|
+
},
|
|
3536
|
+
service
|
|
3537
|
+
);
|
|
3517
3538
|
},
|
|
3518
3539
|
[env]
|
|
3519
3540
|
);
|
|
@@ -5475,12 +5496,16 @@ var useParsePreview = () => {
|
|
|
5475
5496
|
id,
|
|
5476
5497
|
selectedSheet,
|
|
5477
5498
|
isHeader,
|
|
5478
|
-
context
|
|
5499
|
+
context,
|
|
5500
|
+
service,
|
|
5501
|
+
xNode
|
|
5479
5502
|
}) => parsePreview({
|
|
5480
5503
|
id,
|
|
5481
5504
|
selectedSheet,
|
|
5482
5505
|
isHeader,
|
|
5483
|
-
context
|
|
5506
|
+
context,
|
|
5507
|
+
service,
|
|
5508
|
+
xNode
|
|
5484
5509
|
})
|
|
5485
5510
|
});
|
|
5486
5511
|
};
|
|
@@ -5491,8 +5516,14 @@ var import_react_query22 = require("@tanstack/react-query");
|
|
|
5491
5516
|
var useUploadFileExcel = () => {
|
|
5492
5517
|
const { uploadFileExcel } = useExcelService();
|
|
5493
5518
|
return (0, import_react_query22.useMutation)({
|
|
5494
|
-
mutationFn: ({
|
|
5495
|
-
formData
|
|
5519
|
+
mutationFn: ({
|
|
5520
|
+
formData,
|
|
5521
|
+
service,
|
|
5522
|
+
xNode
|
|
5523
|
+
}) => uploadFileExcel({
|
|
5524
|
+
formData,
|
|
5525
|
+
service,
|
|
5526
|
+
xNode
|
|
5496
5527
|
})
|
|
5497
5528
|
});
|
|
5498
5529
|
};
|
|
@@ -5521,14 +5552,18 @@ var useExecuteImport = () => {
|
|
|
5521
5552
|
idFile,
|
|
5522
5553
|
options,
|
|
5523
5554
|
dryrun,
|
|
5524
|
-
context
|
|
5555
|
+
context,
|
|
5556
|
+
service,
|
|
5557
|
+
xNode
|
|
5525
5558
|
}) => executeImport({
|
|
5526
5559
|
fields,
|
|
5527
5560
|
columns,
|
|
5528
5561
|
idFile,
|
|
5529
5562
|
options,
|
|
5530
5563
|
dryrun,
|
|
5531
|
-
context
|
|
5564
|
+
context,
|
|
5565
|
+
service,
|
|
5566
|
+
xNode
|
|
5532
5567
|
})
|
|
5533
5568
|
});
|
|
5534
5569
|
};
|
package/dist/hooks.mjs
CHANGED
|
@@ -3308,8 +3308,19 @@ import { useCallback as useCallback5 } from "react";
|
|
|
3308
3308
|
function useExcelService() {
|
|
3309
3309
|
const { env } = useEnv();
|
|
3310
3310
|
const uploadFileExcel = useCallback5(
|
|
3311
|
-
async ({
|
|
3312
|
-
|
|
3311
|
+
async ({
|
|
3312
|
+
formData,
|
|
3313
|
+
service,
|
|
3314
|
+
xNode
|
|
3315
|
+
}) => {
|
|
3316
|
+
return env.requests.post(
|
|
3317
|
+
"/upload/file" /* UPLOAD_FILE_EXCEL_PATH */,
|
|
3318
|
+
formData,
|
|
3319
|
+
{
|
|
3320
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3321
|
+
},
|
|
3322
|
+
service
|
|
3323
|
+
);
|
|
3313
3324
|
},
|
|
3314
3325
|
[env]
|
|
3315
3326
|
);
|
|
@@ -3328,7 +3339,9 @@ function useExcelService() {
|
|
|
3328
3339
|
id,
|
|
3329
3340
|
selectedSheet,
|
|
3330
3341
|
isHeader,
|
|
3331
|
-
context
|
|
3342
|
+
context,
|
|
3343
|
+
service,
|
|
3344
|
+
xNode
|
|
3332
3345
|
}) => {
|
|
3333
3346
|
const jsonData = {
|
|
3334
3347
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3359,11 +3372,14 @@ function useExcelService() {
|
|
|
3359
3372
|
},
|
|
3360
3373
|
with_context: context
|
|
3361
3374
|
};
|
|
3362
|
-
return env.requests.post(
|
|
3363
|
-
|
|
3364
|
-
|
|
3365
|
-
|
|
3366
|
-
|
|
3375
|
+
return env.requests.post(
|
|
3376
|
+
"/call" /* CALL_PATH */,
|
|
3377
|
+
jsonData,
|
|
3378
|
+
{
|
|
3379
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3380
|
+
},
|
|
3381
|
+
service
|
|
3382
|
+
);
|
|
3367
3383
|
},
|
|
3368
3384
|
[env]
|
|
3369
3385
|
);
|
|
@@ -3374,7 +3390,9 @@ function useExcelService() {
|
|
|
3374
3390
|
idFile,
|
|
3375
3391
|
options,
|
|
3376
3392
|
dryrun,
|
|
3377
|
-
context
|
|
3393
|
+
context,
|
|
3394
|
+
service,
|
|
3395
|
+
xNode
|
|
3378
3396
|
}) => {
|
|
3379
3397
|
const jsonData = {
|
|
3380
3398
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3388,11 +3406,14 @@ function useExcelService() {
|
|
|
3388
3406
|
},
|
|
3389
3407
|
with_context: context
|
|
3390
3408
|
};
|
|
3391
|
-
return env.requests.post(
|
|
3392
|
-
|
|
3393
|
-
|
|
3394
|
-
|
|
3395
|
-
|
|
3409
|
+
return env.requests.post(
|
|
3410
|
+
"/call" /* CALL_PATH */,
|
|
3411
|
+
jsonData,
|
|
3412
|
+
{
|
|
3413
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3414
|
+
},
|
|
3415
|
+
service
|
|
3416
|
+
);
|
|
3396
3417
|
},
|
|
3397
3418
|
[env]
|
|
3398
3419
|
);
|
|
@@ -5354,12 +5375,16 @@ var useParsePreview = () => {
|
|
|
5354
5375
|
id,
|
|
5355
5376
|
selectedSheet,
|
|
5356
5377
|
isHeader,
|
|
5357
|
-
context
|
|
5378
|
+
context,
|
|
5379
|
+
service,
|
|
5380
|
+
xNode
|
|
5358
5381
|
}) => parsePreview({
|
|
5359
5382
|
id,
|
|
5360
5383
|
selectedSheet,
|
|
5361
5384
|
isHeader,
|
|
5362
|
-
context
|
|
5385
|
+
context,
|
|
5386
|
+
service,
|
|
5387
|
+
xNode
|
|
5363
5388
|
})
|
|
5364
5389
|
});
|
|
5365
5390
|
};
|
|
@@ -5370,8 +5395,14 @@ import { useMutation as useMutation18 } from "@tanstack/react-query";
|
|
|
5370
5395
|
var useUploadFileExcel = () => {
|
|
5371
5396
|
const { uploadFileExcel } = useExcelService();
|
|
5372
5397
|
return useMutation18({
|
|
5373
|
-
mutationFn: ({
|
|
5374
|
-
formData
|
|
5398
|
+
mutationFn: ({
|
|
5399
|
+
formData,
|
|
5400
|
+
service,
|
|
5401
|
+
xNode
|
|
5402
|
+
}) => uploadFileExcel({
|
|
5403
|
+
formData,
|
|
5404
|
+
service,
|
|
5405
|
+
xNode
|
|
5375
5406
|
})
|
|
5376
5407
|
});
|
|
5377
5408
|
};
|
|
@@ -5400,14 +5431,18 @@ var useExecuteImport = () => {
|
|
|
5400
5431
|
idFile,
|
|
5401
5432
|
options,
|
|
5402
5433
|
dryrun,
|
|
5403
|
-
context
|
|
5434
|
+
context,
|
|
5435
|
+
service,
|
|
5436
|
+
xNode
|
|
5404
5437
|
}) => executeImport({
|
|
5405
5438
|
fields,
|
|
5406
5439
|
columns,
|
|
5407
5440
|
idFile,
|
|
5408
5441
|
options,
|
|
5409
5442
|
dryrun,
|
|
5410
|
-
context
|
|
5443
|
+
context,
|
|
5444
|
+
service,
|
|
5445
|
+
xNode
|
|
5411
5446
|
})
|
|
5412
5447
|
});
|
|
5413
5448
|
};
|
package/dist/provider.js
CHANGED
|
@@ -3360,8 +3360,19 @@ var import_react5 = require("react");
|
|
|
3360
3360
|
function useExcelService() {
|
|
3361
3361
|
const { env } = useEnv();
|
|
3362
3362
|
const uploadFileExcel = (0, import_react5.useCallback)(
|
|
3363
|
-
async ({
|
|
3364
|
-
|
|
3363
|
+
async ({
|
|
3364
|
+
formData,
|
|
3365
|
+
service,
|
|
3366
|
+
xNode
|
|
3367
|
+
}) => {
|
|
3368
|
+
return env.requests.post(
|
|
3369
|
+
"/upload/file" /* UPLOAD_FILE_EXCEL_PATH */,
|
|
3370
|
+
formData,
|
|
3371
|
+
{
|
|
3372
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3373
|
+
},
|
|
3374
|
+
service
|
|
3375
|
+
);
|
|
3365
3376
|
},
|
|
3366
3377
|
[env]
|
|
3367
3378
|
);
|
|
@@ -3380,7 +3391,9 @@ function useExcelService() {
|
|
|
3380
3391
|
id,
|
|
3381
3392
|
selectedSheet,
|
|
3382
3393
|
isHeader,
|
|
3383
|
-
context
|
|
3394
|
+
context,
|
|
3395
|
+
service,
|
|
3396
|
+
xNode
|
|
3384
3397
|
}) => {
|
|
3385
3398
|
const jsonData = {
|
|
3386
3399
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3411,11 +3424,14 @@ function useExcelService() {
|
|
|
3411
3424
|
},
|
|
3412
3425
|
with_context: context
|
|
3413
3426
|
};
|
|
3414
|
-
return env.requests.post(
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3427
|
+
return env.requests.post(
|
|
3428
|
+
"/call" /* CALL_PATH */,
|
|
3429
|
+
jsonData,
|
|
3430
|
+
{
|
|
3431
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3432
|
+
},
|
|
3433
|
+
service
|
|
3434
|
+
);
|
|
3419
3435
|
},
|
|
3420
3436
|
[env]
|
|
3421
3437
|
);
|
|
@@ -3426,7 +3442,9 @@ function useExcelService() {
|
|
|
3426
3442
|
idFile,
|
|
3427
3443
|
options,
|
|
3428
3444
|
dryrun,
|
|
3429
|
-
context
|
|
3445
|
+
context,
|
|
3446
|
+
service,
|
|
3447
|
+
xNode
|
|
3430
3448
|
}) => {
|
|
3431
3449
|
const jsonData = {
|
|
3432
3450
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3440,11 +3458,14 @@ function useExcelService() {
|
|
|
3440
3458
|
},
|
|
3441
3459
|
with_context: context
|
|
3442
3460
|
};
|
|
3443
|
-
return env.requests.post(
|
|
3444
|
-
|
|
3445
|
-
|
|
3446
|
-
|
|
3447
|
-
|
|
3461
|
+
return env.requests.post(
|
|
3462
|
+
"/call" /* CALL_PATH */,
|
|
3463
|
+
jsonData,
|
|
3464
|
+
{
|
|
3465
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3466
|
+
},
|
|
3467
|
+
service
|
|
3468
|
+
);
|
|
3448
3469
|
},
|
|
3449
3470
|
[env]
|
|
3450
3471
|
);
|
|
@@ -5824,12 +5845,16 @@ var useParsePreview = () => {
|
|
|
5824
5845
|
id,
|
|
5825
5846
|
selectedSheet,
|
|
5826
5847
|
isHeader,
|
|
5827
|
-
context
|
|
5848
|
+
context,
|
|
5849
|
+
service,
|
|
5850
|
+
xNode
|
|
5828
5851
|
}) => parsePreview({
|
|
5829
5852
|
id,
|
|
5830
5853
|
selectedSheet,
|
|
5831
5854
|
isHeader,
|
|
5832
|
-
context
|
|
5855
|
+
context,
|
|
5856
|
+
service,
|
|
5857
|
+
xNode
|
|
5833
5858
|
})
|
|
5834
5859
|
});
|
|
5835
5860
|
};
|
|
@@ -5840,8 +5865,14 @@ var import_react_query22 = require("@tanstack/react-query");
|
|
|
5840
5865
|
var useUploadFileExcel = () => {
|
|
5841
5866
|
const { uploadFileExcel } = useExcelService();
|
|
5842
5867
|
return (0, import_react_query22.useMutation)({
|
|
5843
|
-
mutationFn: ({
|
|
5844
|
-
formData
|
|
5868
|
+
mutationFn: ({
|
|
5869
|
+
formData,
|
|
5870
|
+
service,
|
|
5871
|
+
xNode
|
|
5872
|
+
}) => uploadFileExcel({
|
|
5873
|
+
formData,
|
|
5874
|
+
service,
|
|
5875
|
+
xNode
|
|
5845
5876
|
})
|
|
5846
5877
|
});
|
|
5847
5878
|
};
|
|
@@ -5870,14 +5901,18 @@ var useExecuteImport = () => {
|
|
|
5870
5901
|
idFile,
|
|
5871
5902
|
options,
|
|
5872
5903
|
dryrun,
|
|
5873
|
-
context
|
|
5904
|
+
context,
|
|
5905
|
+
service,
|
|
5906
|
+
xNode
|
|
5874
5907
|
}) => executeImport({
|
|
5875
5908
|
fields,
|
|
5876
5909
|
columns,
|
|
5877
5910
|
idFile,
|
|
5878
5911
|
options,
|
|
5879
5912
|
dryrun,
|
|
5880
|
-
context
|
|
5913
|
+
context,
|
|
5914
|
+
service,
|
|
5915
|
+
xNode
|
|
5881
5916
|
})
|
|
5882
5917
|
});
|
|
5883
5918
|
};
|
package/dist/provider.mjs
CHANGED
|
@@ -3317,8 +3317,19 @@ import { useCallback as useCallback4 } from "react";
|
|
|
3317
3317
|
function useExcelService() {
|
|
3318
3318
|
const { env } = useEnv();
|
|
3319
3319
|
const uploadFileExcel = useCallback4(
|
|
3320
|
-
async ({
|
|
3321
|
-
|
|
3320
|
+
async ({
|
|
3321
|
+
formData,
|
|
3322
|
+
service,
|
|
3323
|
+
xNode
|
|
3324
|
+
}) => {
|
|
3325
|
+
return env.requests.post(
|
|
3326
|
+
"/upload/file" /* UPLOAD_FILE_EXCEL_PATH */,
|
|
3327
|
+
formData,
|
|
3328
|
+
{
|
|
3329
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3330
|
+
},
|
|
3331
|
+
service
|
|
3332
|
+
);
|
|
3322
3333
|
},
|
|
3323
3334
|
[env]
|
|
3324
3335
|
);
|
|
@@ -3337,7 +3348,9 @@ function useExcelService() {
|
|
|
3337
3348
|
id,
|
|
3338
3349
|
selectedSheet,
|
|
3339
3350
|
isHeader,
|
|
3340
|
-
context
|
|
3351
|
+
context,
|
|
3352
|
+
service,
|
|
3353
|
+
xNode
|
|
3341
3354
|
}) => {
|
|
3342
3355
|
const jsonData = {
|
|
3343
3356
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3368,11 +3381,14 @@ function useExcelService() {
|
|
|
3368
3381
|
},
|
|
3369
3382
|
with_context: context
|
|
3370
3383
|
};
|
|
3371
|
-
return env.requests.post(
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3384
|
+
return env.requests.post(
|
|
3385
|
+
"/call" /* CALL_PATH */,
|
|
3386
|
+
jsonData,
|
|
3387
|
+
{
|
|
3388
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3389
|
+
},
|
|
3390
|
+
service
|
|
3391
|
+
);
|
|
3376
3392
|
},
|
|
3377
3393
|
[env]
|
|
3378
3394
|
);
|
|
@@ -3383,7 +3399,9 @@ function useExcelService() {
|
|
|
3383
3399
|
idFile,
|
|
3384
3400
|
options,
|
|
3385
3401
|
dryrun,
|
|
3386
|
-
context
|
|
3402
|
+
context,
|
|
3403
|
+
service,
|
|
3404
|
+
xNode
|
|
3387
3405
|
}) => {
|
|
3388
3406
|
const jsonData = {
|
|
3389
3407
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3397,11 +3415,14 @@ function useExcelService() {
|
|
|
3397
3415
|
},
|
|
3398
3416
|
with_context: context
|
|
3399
3417
|
};
|
|
3400
|
-
return env.requests.post(
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3418
|
+
return env.requests.post(
|
|
3419
|
+
"/call" /* CALL_PATH */,
|
|
3420
|
+
jsonData,
|
|
3421
|
+
{
|
|
3422
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3423
|
+
},
|
|
3424
|
+
service
|
|
3425
|
+
);
|
|
3405
3426
|
},
|
|
3406
3427
|
[env]
|
|
3407
3428
|
);
|
|
@@ -5781,12 +5802,16 @@ var useParsePreview = () => {
|
|
|
5781
5802
|
id,
|
|
5782
5803
|
selectedSheet,
|
|
5783
5804
|
isHeader,
|
|
5784
|
-
context
|
|
5805
|
+
context,
|
|
5806
|
+
service,
|
|
5807
|
+
xNode
|
|
5785
5808
|
}) => parsePreview({
|
|
5786
5809
|
id,
|
|
5787
5810
|
selectedSheet,
|
|
5788
5811
|
isHeader,
|
|
5789
|
-
context
|
|
5812
|
+
context,
|
|
5813
|
+
service,
|
|
5814
|
+
xNode
|
|
5790
5815
|
})
|
|
5791
5816
|
});
|
|
5792
5817
|
};
|
|
@@ -5797,8 +5822,14 @@ import { useMutation as useMutation18 } from "@tanstack/react-query";
|
|
|
5797
5822
|
var useUploadFileExcel = () => {
|
|
5798
5823
|
const { uploadFileExcel } = useExcelService();
|
|
5799
5824
|
return useMutation18({
|
|
5800
|
-
mutationFn: ({
|
|
5801
|
-
formData
|
|
5825
|
+
mutationFn: ({
|
|
5826
|
+
formData,
|
|
5827
|
+
service,
|
|
5828
|
+
xNode
|
|
5829
|
+
}) => uploadFileExcel({
|
|
5830
|
+
formData,
|
|
5831
|
+
service,
|
|
5832
|
+
xNode
|
|
5802
5833
|
})
|
|
5803
5834
|
});
|
|
5804
5835
|
};
|
|
@@ -5827,14 +5858,18 @@ var useExecuteImport = () => {
|
|
|
5827
5858
|
idFile,
|
|
5828
5859
|
options,
|
|
5829
5860
|
dryrun,
|
|
5830
|
-
context
|
|
5861
|
+
context,
|
|
5862
|
+
service,
|
|
5863
|
+
xNode
|
|
5831
5864
|
}) => executeImport({
|
|
5832
5865
|
fields,
|
|
5833
5866
|
columns,
|
|
5834
5867
|
idFile,
|
|
5835
5868
|
options,
|
|
5836
5869
|
dryrun,
|
|
5837
|
-
context
|
|
5870
|
+
context,
|
|
5871
|
+
service,
|
|
5872
|
+
xNode
|
|
5838
5873
|
})
|
|
5839
5874
|
});
|
|
5840
5875
|
};
|
package/dist/services.d.mts
CHANGED
|
@@ -84,25 +84,31 @@ declare function useCompanyService(): {
|
|
|
84
84
|
};
|
|
85
85
|
|
|
86
86
|
declare function useExcelService(): {
|
|
87
|
-
uploadFileExcel: ({ formData }: {
|
|
87
|
+
uploadFileExcel: ({ formData, service, xNode, }: {
|
|
88
88
|
formData: any;
|
|
89
|
+
service?: string;
|
|
90
|
+
xNode?: string;
|
|
89
91
|
}) => Promise<any>;
|
|
90
92
|
uploadIdFile: ({ formData }: {
|
|
91
93
|
formData: any;
|
|
92
94
|
}) => Promise<any>;
|
|
93
|
-
parsePreview: ({ id, selectedSheet, isHeader, context, }: {
|
|
95
|
+
parsePreview: ({ id, selectedSheet, isHeader, context, service, xNode, }: {
|
|
94
96
|
id: any;
|
|
95
97
|
selectedSheet: any;
|
|
96
98
|
isHeader: boolean;
|
|
97
99
|
context: any;
|
|
100
|
+
service?: string;
|
|
101
|
+
xNode?: string;
|
|
98
102
|
}) => Promise<any>;
|
|
99
|
-
executeImport: ({ columns, fields, idFile, options, dryrun, context, }: {
|
|
103
|
+
executeImport: ({ columns, fields, idFile, options, dryrun, context, service, xNode, }: {
|
|
100
104
|
columns: any;
|
|
101
105
|
fields: any;
|
|
102
106
|
idFile: any;
|
|
103
107
|
options: any;
|
|
104
108
|
dryrun: any;
|
|
105
109
|
context: any;
|
|
110
|
+
service?: string;
|
|
111
|
+
xNode?: string;
|
|
106
112
|
}) => Promise<any>;
|
|
107
113
|
getFileExcel: ({ model }: {
|
|
108
114
|
model: string;
|
package/dist/services.d.ts
CHANGED
|
@@ -84,25 +84,31 @@ declare function useCompanyService(): {
|
|
|
84
84
|
};
|
|
85
85
|
|
|
86
86
|
declare function useExcelService(): {
|
|
87
|
-
uploadFileExcel: ({ formData }: {
|
|
87
|
+
uploadFileExcel: ({ formData, service, xNode, }: {
|
|
88
88
|
formData: any;
|
|
89
|
+
service?: string;
|
|
90
|
+
xNode?: string;
|
|
89
91
|
}) => Promise<any>;
|
|
90
92
|
uploadIdFile: ({ formData }: {
|
|
91
93
|
formData: any;
|
|
92
94
|
}) => Promise<any>;
|
|
93
|
-
parsePreview: ({ id, selectedSheet, isHeader, context, }: {
|
|
95
|
+
parsePreview: ({ id, selectedSheet, isHeader, context, service, xNode, }: {
|
|
94
96
|
id: any;
|
|
95
97
|
selectedSheet: any;
|
|
96
98
|
isHeader: boolean;
|
|
97
99
|
context: any;
|
|
100
|
+
service?: string;
|
|
101
|
+
xNode?: string;
|
|
98
102
|
}) => Promise<any>;
|
|
99
|
-
executeImport: ({ columns, fields, idFile, options, dryrun, context, }: {
|
|
103
|
+
executeImport: ({ columns, fields, idFile, options, dryrun, context, service, xNode, }: {
|
|
100
104
|
columns: any;
|
|
101
105
|
fields: any;
|
|
102
106
|
idFile: any;
|
|
103
107
|
options: any;
|
|
104
108
|
dryrun: any;
|
|
105
109
|
context: any;
|
|
110
|
+
service?: string;
|
|
111
|
+
xNode?: string;
|
|
106
112
|
}) => Promise<any>;
|
|
107
113
|
getFileExcel: ({ model }: {
|
|
108
114
|
model: string;
|
package/dist/services.js
CHANGED
|
@@ -3581,8 +3581,19 @@ var import_react9 = require("react");
|
|
|
3581
3581
|
function useExcelService() {
|
|
3582
3582
|
const { env } = useEnv();
|
|
3583
3583
|
const uploadFileExcel = (0, import_react9.useCallback)(
|
|
3584
|
-
async ({
|
|
3585
|
-
|
|
3584
|
+
async ({
|
|
3585
|
+
formData,
|
|
3586
|
+
service,
|
|
3587
|
+
xNode
|
|
3588
|
+
}) => {
|
|
3589
|
+
return env.requests.post(
|
|
3590
|
+
"/upload/file" /* UPLOAD_FILE_EXCEL_PATH */,
|
|
3591
|
+
formData,
|
|
3592
|
+
{
|
|
3593
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3594
|
+
},
|
|
3595
|
+
service
|
|
3596
|
+
);
|
|
3586
3597
|
},
|
|
3587
3598
|
[env]
|
|
3588
3599
|
);
|
|
@@ -3601,7 +3612,9 @@ function useExcelService() {
|
|
|
3601
3612
|
id,
|
|
3602
3613
|
selectedSheet,
|
|
3603
3614
|
isHeader,
|
|
3604
|
-
context
|
|
3615
|
+
context,
|
|
3616
|
+
service,
|
|
3617
|
+
xNode
|
|
3605
3618
|
}) => {
|
|
3606
3619
|
const jsonData = {
|
|
3607
3620
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3632,11 +3645,14 @@ function useExcelService() {
|
|
|
3632
3645
|
},
|
|
3633
3646
|
with_context: context
|
|
3634
3647
|
};
|
|
3635
|
-
return env.requests.post(
|
|
3636
|
-
|
|
3637
|
-
|
|
3638
|
-
|
|
3639
|
-
|
|
3648
|
+
return env.requests.post(
|
|
3649
|
+
"/call" /* CALL_PATH */,
|
|
3650
|
+
jsonData,
|
|
3651
|
+
{
|
|
3652
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3653
|
+
},
|
|
3654
|
+
service
|
|
3655
|
+
);
|
|
3640
3656
|
},
|
|
3641
3657
|
[env]
|
|
3642
3658
|
);
|
|
@@ -3647,7 +3663,9 @@ function useExcelService() {
|
|
|
3647
3663
|
idFile,
|
|
3648
3664
|
options,
|
|
3649
3665
|
dryrun,
|
|
3650
|
-
context
|
|
3666
|
+
context,
|
|
3667
|
+
service,
|
|
3668
|
+
xNode
|
|
3651
3669
|
}) => {
|
|
3652
3670
|
const jsonData = {
|
|
3653
3671
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3661,11 +3679,14 @@ function useExcelService() {
|
|
|
3661
3679
|
},
|
|
3662
3680
|
with_context: context
|
|
3663
3681
|
};
|
|
3664
|
-
return env.requests.post(
|
|
3665
|
-
|
|
3666
|
-
|
|
3667
|
-
|
|
3668
|
-
|
|
3682
|
+
return env.requests.post(
|
|
3683
|
+
"/call" /* CALL_PATH */,
|
|
3684
|
+
jsonData,
|
|
3685
|
+
{
|
|
3686
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3687
|
+
},
|
|
3688
|
+
service
|
|
3689
|
+
);
|
|
3669
3690
|
},
|
|
3670
3691
|
[env]
|
|
3671
3692
|
);
|
package/dist/services.mjs
CHANGED
|
@@ -3537,8 +3537,19 @@ import { useCallback as useCallback5 } from "react";
|
|
|
3537
3537
|
function useExcelService() {
|
|
3538
3538
|
const { env } = useEnv();
|
|
3539
3539
|
const uploadFileExcel = useCallback5(
|
|
3540
|
-
async ({
|
|
3541
|
-
|
|
3540
|
+
async ({
|
|
3541
|
+
formData,
|
|
3542
|
+
service,
|
|
3543
|
+
xNode
|
|
3544
|
+
}) => {
|
|
3545
|
+
return env.requests.post(
|
|
3546
|
+
"/upload/file" /* UPLOAD_FILE_EXCEL_PATH */,
|
|
3547
|
+
formData,
|
|
3548
|
+
{
|
|
3549
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3550
|
+
},
|
|
3551
|
+
service
|
|
3552
|
+
);
|
|
3542
3553
|
},
|
|
3543
3554
|
[env]
|
|
3544
3555
|
);
|
|
@@ -3557,7 +3568,9 @@ function useExcelService() {
|
|
|
3557
3568
|
id,
|
|
3558
3569
|
selectedSheet,
|
|
3559
3570
|
isHeader,
|
|
3560
|
-
context
|
|
3571
|
+
context,
|
|
3572
|
+
service,
|
|
3573
|
+
xNode
|
|
3561
3574
|
}) => {
|
|
3562
3575
|
const jsonData = {
|
|
3563
3576
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3588,11 +3601,14 @@ function useExcelService() {
|
|
|
3588
3601
|
},
|
|
3589
3602
|
with_context: context
|
|
3590
3603
|
};
|
|
3591
|
-
return env.requests.post(
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
|
|
3604
|
+
return env.requests.post(
|
|
3605
|
+
"/call" /* CALL_PATH */,
|
|
3606
|
+
jsonData,
|
|
3607
|
+
{
|
|
3608
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3609
|
+
},
|
|
3610
|
+
service
|
|
3611
|
+
);
|
|
3596
3612
|
},
|
|
3597
3613
|
[env]
|
|
3598
3614
|
);
|
|
@@ -3603,7 +3619,9 @@ function useExcelService() {
|
|
|
3603
3619
|
idFile,
|
|
3604
3620
|
options,
|
|
3605
3621
|
dryrun,
|
|
3606
|
-
context
|
|
3622
|
+
context,
|
|
3623
|
+
service,
|
|
3624
|
+
xNode
|
|
3607
3625
|
}) => {
|
|
3608
3626
|
const jsonData = {
|
|
3609
3627
|
model: "base_import.import" /* BASE_IMPORT */,
|
|
@@ -3617,11 +3635,14 @@ function useExcelService() {
|
|
|
3617
3635
|
},
|
|
3618
3636
|
with_context: context
|
|
3619
3637
|
};
|
|
3620
|
-
return env.requests.post(
|
|
3621
|
-
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3638
|
+
return env.requests.post(
|
|
3639
|
+
"/call" /* CALL_PATH */,
|
|
3640
|
+
jsonData,
|
|
3641
|
+
{
|
|
3642
|
+
headers: { "Content-Type": "application/json", "X-Node": xNode }
|
|
3643
|
+
},
|
|
3644
|
+
service
|
|
3645
|
+
);
|
|
3625
3646
|
},
|
|
3626
3647
|
[env]
|
|
3627
3648
|
);
|