@nomalism-com/types 0.39.75 → 0.40.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/index.cjs +184 -70
- package/dist/index.js +184 -70
- package/dist/main.d.ts +9 -1
- package/dist/modules/document/NPF/interface.d.ts +17 -0
- package/dist/modules/document/NPF/route.schema.d.ts +2 -0
- package/dist/modules/document/NRCL/interface.d.ts +26 -0
- package/dist/modules/document/NRCL/route.schema.d.ts +2 -0
- package/dist/modules/supply/currentAccount/interface.d.ts +157 -0
- package/dist/modules/supply/currentAccount/route.schema.d.ts +10 -0
- package/dist/modules/supply/documentHeader/interfaces.d.ts +0 -27
- package/dist/modules/supply/documentHeader/route.schema.d.ts +0 -1
- package/dist/modules/supply/documentLine/route.schema.d.ts +2 -2
- package/dist/modules/supply/payment/interface.d.ts +2 -108
- package/dist/modules/supply/payment/route.schema.d.ts +0 -6
- package/dist/modules/supply/paymentBatch/interface.d.ts +57 -0
- package/dist/modules/supply/paymentBatch/route.schema.d.ts +4 -0
- package/dist/shared/entities/stock.d.ts +1 -1
- package/dist/shared/interface.d.ts +6 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -30,6 +30,8 @@ __export(main_exports, {
|
|
|
30
30
|
CommissionerRoutes: () => route_schema_exports6,
|
|
31
31
|
Country: () => interface_exports6,
|
|
32
32
|
CountryRoutes: () => route_schema_exports7,
|
|
33
|
+
CurrentAccount: () => interface_exports63,
|
|
34
|
+
CurrentAccountRoutes: () => route_schema_exports112,
|
|
33
35
|
Dashboard: () => interface_exports54,
|
|
34
36
|
DashboardRoutes: () => route_schema_exports101,
|
|
35
37
|
DeliveryMethods: () => interfaces_exports3,
|
|
@@ -88,6 +90,10 @@ __export(main_exports, {
|
|
|
88
90
|
MaturityDatesRoutes: () => route_schema_exports28,
|
|
89
91
|
Multimedia: () => interfaces_exports19,
|
|
90
92
|
MultimediaRoutes: () => route_schema_exports29,
|
|
93
|
+
NPF: () => interface_exports61,
|
|
94
|
+
NPFRoutes: () => route_schema_exports110,
|
|
95
|
+
NRCL: () => interface_exports62,
|
|
96
|
+
NRCLRoutes: () => route_schema_exports111,
|
|
91
97
|
Npc: () => interfaces_exports27,
|
|
92
98
|
NpcRoutes: () => route_schema_exports64,
|
|
93
99
|
Observation: () => interfaces_exports20,
|
|
@@ -100,6 +106,8 @@ __export(main_exports, {
|
|
|
100
106
|
Password: () => interfaces_exports22,
|
|
101
107
|
PasswordRoutes: () => route_schema_exports32,
|
|
102
108
|
Payment: () => interface_exports15,
|
|
109
|
+
PaymentBatch: () => interface_exports64,
|
|
110
|
+
PaymentBatchRoutes: () => route_schema_exports113,
|
|
103
111
|
PaymentMethods: () => interfaces_exports23,
|
|
104
112
|
PaymentMethodsRoutes: () => route_schema_exports34,
|
|
105
113
|
PaymentRoutes: () => route_schema_exports33,
|
|
@@ -1349,7 +1357,6 @@ __export(route_schema_exports9, {
|
|
|
1349
1357
|
documentPdfQuery: () => documentPdfQuery,
|
|
1350
1358
|
findByTypeQuery: () => findByTypeQuery,
|
|
1351
1359
|
findQuery: () => findQuery6,
|
|
1352
|
-
regularizarMultiplosBody: () => regularizarMultiplosBody,
|
|
1353
1360
|
sendClientNotificationBody: () => sendClientNotificationBody,
|
|
1354
1361
|
transferClientOwnershipBody: () => transferClientOwnershipBody,
|
|
1355
1362
|
updateBody: () => updateBody8,
|
|
@@ -1630,22 +1637,6 @@ var documentPdfQuery = joi10.object().keys(documentPdfQueryKeys).messages(messag
|
|
|
1630
1637
|
var documentLineQuery = joi10.object().keys({
|
|
1631
1638
|
closed: joi10.boolean().default(false).optional()
|
|
1632
1639
|
}).messages(messages);
|
|
1633
|
-
var multipleDocumentsBodyKeys = {
|
|
1634
|
-
owner_id: joi10.string().uuid().required(),
|
|
1635
|
-
document_header_id: joi10.string().uuid().required(),
|
|
1636
|
-
type: joi10.string().valid("credit", "debit").required(),
|
|
1637
|
-
value: joi10.number().positive().required()
|
|
1638
|
-
};
|
|
1639
|
-
var multiplePaymentsBodyKeys = {
|
|
1640
|
-
value: joi10.number().positive().required(),
|
|
1641
|
-
payment_method_id: joi10.string().uuid().required(),
|
|
1642
|
-
payment_method: joi10.string().required()
|
|
1643
|
-
};
|
|
1644
|
-
var regularizarMultiplosBodyKeys = {
|
|
1645
|
-
documents: joi10.array().items(multipleDocumentsBodyKeys).required(),
|
|
1646
|
-
payments: joi10.array().items(multiplePaymentsBodyKeys).optional()
|
|
1647
|
-
};
|
|
1648
|
-
var regularizarMultiplosBody = joi10.object().keys(regularizarMultiplosBodyKeys).messages(messages);
|
|
1649
1640
|
|
|
1650
1641
|
// src/modules/supply/documentHeaderHistory/interfaces.ts
|
|
1651
1642
|
var interfaces_exports6 = {};
|
|
@@ -2534,8 +2525,6 @@ var resetBody = joi33.object().keys(resetBodyKeys).messages(messages);
|
|
|
2534
2525
|
// src/modules/supply/payment/interface.ts
|
|
2535
2526
|
var interface_exports15 = {};
|
|
2536
2527
|
__export(interface_exports15, {
|
|
2537
|
-
IExportCurrentAccountOutputEnum: () => IExportCurrentAccountOutputEnum,
|
|
2538
|
-
IExportCurrentAccountOutputOptions: () => IExportCurrentAccountOutputOptions,
|
|
2539
2528
|
LowerName: () => LowerName27,
|
|
2540
2529
|
Route: () => Route28,
|
|
2541
2530
|
UpperName: () => UpperName27
|
|
@@ -2543,24 +2532,14 @@ __export(interface_exports15, {
|
|
|
2543
2532
|
var Route28 = "payment";
|
|
2544
2533
|
var UpperName27 = "Payment";
|
|
2545
2534
|
var LowerName27 = UpperName27[0].toLowerCase() + UpperName27.substring(1);
|
|
2546
|
-
var IExportCurrentAccountOutputEnum = {
|
|
2547
|
-
csv: "csv",
|
|
2548
|
-
pdf: "pdf"
|
|
2549
|
-
};
|
|
2550
|
-
var IExportCurrentAccountOutputOptions = Object.keys(IExportCurrentAccountOutputEnum);
|
|
2551
2535
|
|
|
2552
2536
|
// src/modules/supply/payment/route.schema.ts
|
|
2553
2537
|
var route_schema_exports33 = {};
|
|
2554
2538
|
__export(route_schema_exports33, {
|
|
2555
|
-
exportCurrentAccountBetweenDatesQuery: () => exportCurrentAccountBetweenDatesQuery,
|
|
2556
|
-
exportPaymentsBody: () => exportPaymentsBody,
|
|
2557
|
-
findCurrentAccountWithPaginationQuery: () => findCurrentAccountWithPaginationQuery,
|
|
2558
|
-
findPaymentsNotExportedQuery: () => findPaymentsNotExportedQuery,
|
|
2559
2539
|
findQuery: () => findQuery10,
|
|
2560
2540
|
findSettledMaterialEntranceBuDateParams: () => findSettledMaterialEntranceBuDateParams,
|
|
2561
2541
|
findSettledMaterialEntranceQuery: () => findSettledMaterialEntranceQuery,
|
|
2562
|
-
findWithPaginationQuery: () => findWithPaginationQuery9
|
|
2563
|
-
providerPaymentBody: () => providerPaymentBody
|
|
2542
|
+
findWithPaginationQuery: () => findWithPaginationQuery9
|
|
2564
2543
|
});
|
|
2565
2544
|
import joi34 from "joi";
|
|
2566
2545
|
var findQueryKeys10 = {};
|
|
@@ -2575,50 +2554,10 @@ var findSettledMaterialEntranceQueryKeys = {
|
|
|
2575
2554
|
client_id: joi34.string().uuid().allow(null).required()
|
|
2576
2555
|
};
|
|
2577
2556
|
var findSettledMaterialEntranceQuery = joi34.object().keys(findSettledMaterialEntranceQueryKeys).messages(messages);
|
|
2578
|
-
var providerPaymentDocumentKeys = {
|
|
2579
|
-
document_header_id: joi34.string().uuid().required(),
|
|
2580
|
-
value: joi34.number().required(),
|
|
2581
|
-
discount_value: joi34.number().optional().allow(0, "", null).when("value", {
|
|
2582
|
-
is: joi34.number().positive(),
|
|
2583
|
-
then: joi34.number().max(joi34.ref("value")),
|
|
2584
|
-
otherwise: joi34.number().min(joi34.ref("value"))
|
|
2585
|
-
})
|
|
2586
|
-
};
|
|
2587
|
-
var providerPaymentDocument = joi34.object().keys(providerPaymentDocumentKeys).required();
|
|
2588
|
-
var providerPaymentBodyKeys = {
|
|
2589
|
-
provider_id: joi34.string().uuid().required(),
|
|
2590
|
-
client_id: joi34.string().uuid().allow(null).optional(),
|
|
2591
|
-
documents: joi34.array().items(providerPaymentDocument).required(),
|
|
2592
|
-
total: joi34.number().positive().allow(0).required()
|
|
2593
|
-
};
|
|
2594
|
-
var providerPaymentBody = joi34.array().items(joi34.object().keys(providerPaymentBodyKeys)).messages(messages);
|
|
2595
|
-
var exportPaymentsBodyKeys = {
|
|
2596
|
-
value: joi34.number().positive().required(),
|
|
2597
|
-
provider: joi34.string().required(),
|
|
2598
|
-
npf_ids: joi34.array().items(joi34.string().uuid().required()).optional()
|
|
2599
|
-
};
|
|
2600
|
-
var exportPaymentsBody = joi34.array().items(joi34.object().keys(exportPaymentsBodyKeys)).messages(messages);
|
|
2601
|
-
var exportCurrentAccountBetweenDatesQueryKeys = {
|
|
2602
|
-
owner_id: joi34.string().required(),
|
|
2603
|
-
output: joi34.string().valid(...IExportCurrentAccountOutputOptions).required(),
|
|
2604
|
-
start_date: joi34.string().optional(),
|
|
2605
|
-
end_date: joi34.string().optional(),
|
|
2606
|
-
token: joi34.string().required()
|
|
2607
|
-
};
|
|
2608
|
-
var exportCurrentAccountBetweenDatesQuery = joi34.object().keys(exportCurrentAccountBetweenDatesQueryKeys).messages(messages);
|
|
2609
2557
|
var findSettledMaterialEntranceBuDateParamsKeys = {
|
|
2610
2558
|
due_date: joi34.string().optional()
|
|
2611
2559
|
};
|
|
2612
2560
|
var findSettledMaterialEntranceBuDateParams = joi34.object().keys(findSettledMaterialEntranceBuDateParamsKeys).messages(messages);
|
|
2613
|
-
var findPaymentsNotExportedQuery = joi34.object().keys({
|
|
2614
|
-
whiteList: joi34.array().items(joi34.string().uuid().required()).optional()
|
|
2615
|
-
}).messages(messages);
|
|
2616
|
-
var findCurrentAccountWithPaginationQueryKeys = {
|
|
2617
|
-
owner_id: joi34.string().uuid().required(),
|
|
2618
|
-
per_page: joi34.number().integer().positive().default(10).optional(),
|
|
2619
|
-
current_page: joi34.number().integer().positive().default(1).optional()
|
|
2620
|
-
};
|
|
2621
|
-
var findCurrentAccountWithPaginationQuery = joi34.object().keys(findCurrentAccountWithPaginationQueryKeys).messages(messages);
|
|
2622
2561
|
|
|
2623
2562
|
// src/modules/user/paymentMethods/interfaces.ts
|
|
2624
2563
|
var interfaces_exports23 = {};
|
|
@@ -5790,6 +5729,181 @@ var editPreviewChatMessageRequestBody = {
|
|
|
5790
5729
|
};
|
|
5791
5730
|
var editPreviewChatMessageRequest = joi110.object().keys(editPreviewChatMessageRequestBody).messages(messages);
|
|
5792
5731
|
|
|
5732
|
+
// src/modules/document/NPF/interface.ts
|
|
5733
|
+
var interface_exports61 = {};
|
|
5734
|
+
__export(interface_exports61, {
|
|
5735
|
+
Route: () => Route105
|
|
5736
|
+
});
|
|
5737
|
+
var Route105 = "npf";
|
|
5738
|
+
|
|
5739
|
+
// src/modules/document/NPF/route.schema.ts
|
|
5740
|
+
var route_schema_exports110 = {};
|
|
5741
|
+
__export(route_schema_exports110, {
|
|
5742
|
+
providerPaymentBody: () => providerPaymentBody
|
|
5743
|
+
});
|
|
5744
|
+
import joi111 from "joi";
|
|
5745
|
+
var providerPaymentDocumentKeys = {
|
|
5746
|
+
document_header_id: joi111.string().uuid().required(),
|
|
5747
|
+
value: joi111.number().required(),
|
|
5748
|
+
discount_value: joi111.number().optional().allow(0, "", null).when("value", {
|
|
5749
|
+
is: joi111.number().positive(),
|
|
5750
|
+
then: joi111.number().max(joi111.ref("value")),
|
|
5751
|
+
otherwise: joi111.number().min(joi111.ref("value"))
|
|
5752
|
+
})
|
|
5753
|
+
};
|
|
5754
|
+
var providerPaymentDocument = joi111.object().keys(providerPaymentDocumentKeys).required();
|
|
5755
|
+
var providerPaymentBodyKeys = {
|
|
5756
|
+
provider_id: joi111.string().uuid().required(),
|
|
5757
|
+
client_id: joi111.string().uuid().allow(null).optional(),
|
|
5758
|
+
documents: joi111.array().items(providerPaymentDocument).required(),
|
|
5759
|
+
total: joi111.number().positive().allow(0).required()
|
|
5760
|
+
};
|
|
5761
|
+
var providerPaymentBody = joi111.array().items(joi111.object().keys(providerPaymentBodyKeys)).messages(messages);
|
|
5762
|
+
|
|
5763
|
+
// src/modules/document/NRCL/interface.ts
|
|
5764
|
+
var interface_exports62 = {};
|
|
5765
|
+
__export(interface_exports62, {
|
|
5766
|
+
LowerName: () => LowerName104,
|
|
5767
|
+
Route: () => Route106,
|
|
5768
|
+
UpperName: () => UpperName104
|
|
5769
|
+
});
|
|
5770
|
+
var Route106 = "documentHeader";
|
|
5771
|
+
var UpperName104 = "DocumentHeader";
|
|
5772
|
+
var LowerName104 = UpperName104[0].toLowerCase() + UpperName104.substring(1);
|
|
5773
|
+
|
|
5774
|
+
// src/modules/document/NRCL/route.schema.ts
|
|
5775
|
+
var route_schema_exports111 = {};
|
|
5776
|
+
__export(route_schema_exports111, {
|
|
5777
|
+
regularizarMultiplosBody: () => regularizarMultiplosBody
|
|
5778
|
+
});
|
|
5779
|
+
import joi112 from "joi";
|
|
5780
|
+
var multipleDocumentsBodyKeys = {
|
|
5781
|
+
owner_id: joi112.string().uuid().required(),
|
|
5782
|
+
document_header_id: joi112.string().uuid().required(),
|
|
5783
|
+
type: joi112.string().valid("credit", "debit").required(),
|
|
5784
|
+
value: joi112.number().positive().required()
|
|
5785
|
+
};
|
|
5786
|
+
var multiplePaymentsBodyKeys = {
|
|
5787
|
+
value: joi112.number().positive().required(),
|
|
5788
|
+
payment_method_id: joi112.string().uuid().required(),
|
|
5789
|
+
payment_method: joi112.string().required()
|
|
5790
|
+
};
|
|
5791
|
+
var regularizarMultiplosBodyKeys = {
|
|
5792
|
+
documents: joi112.array().items(multipleDocumentsBodyKeys).required(),
|
|
5793
|
+
payments: joi112.array().items(multiplePaymentsBodyKeys).optional()
|
|
5794
|
+
};
|
|
5795
|
+
var regularizarMultiplosBody = joi112.object().keys(regularizarMultiplosBodyKeys).messages(messages);
|
|
5796
|
+
|
|
5797
|
+
// src/modules/supply/currentAccount/interface.ts
|
|
5798
|
+
var interface_exports63 = {};
|
|
5799
|
+
__export(interface_exports63, {
|
|
5800
|
+
IExportCurrentAccountOutputEnum: () => IExportCurrentAccountOutputEnum,
|
|
5801
|
+
IExportCurrentAccountOutputOptions: () => IExportCurrentAccountOutputOptions,
|
|
5802
|
+
LowerName: () => LowerName105,
|
|
5803
|
+
Route: () => Route107,
|
|
5804
|
+
UpperName: () => UpperName105
|
|
5805
|
+
});
|
|
5806
|
+
var Route107 = "payment";
|
|
5807
|
+
var UpperName105 = "Payment";
|
|
5808
|
+
var LowerName105 = UpperName105[0].toLowerCase() + UpperName105.substring(1);
|
|
5809
|
+
var IExportCurrentAccountOutputEnum = {
|
|
5810
|
+
csv: "csv",
|
|
5811
|
+
pdf: "pdf"
|
|
5812
|
+
};
|
|
5813
|
+
var IExportCurrentAccountOutputOptions = Object.keys(IExportCurrentAccountOutputEnum);
|
|
5814
|
+
|
|
5815
|
+
// src/modules/supply/currentAccount/route.schema.ts
|
|
5816
|
+
var route_schema_exports112 = {};
|
|
5817
|
+
__export(route_schema_exports112, {
|
|
5818
|
+
exportCurrentAccountBetweenDatesQuery: () => exportCurrentAccountBetweenDatesQuery,
|
|
5819
|
+
exportPaymentsBody: () => exportPaymentsBody,
|
|
5820
|
+
findPaymentsNotExportedQuery: () => findPaymentsNotExportedQuery,
|
|
5821
|
+
findQuery: () => findQuery34,
|
|
5822
|
+
findSettledMaterialEntranceBuDateParams: () => findSettledMaterialEntranceBuDateParams2,
|
|
5823
|
+
findSettledMaterialEntranceQuery: () => findSettledMaterialEntranceQuery2,
|
|
5824
|
+
findWithPaginationQuery: () => findWithPaginationQuery28,
|
|
5825
|
+
providerPaymentBody: () => providerPaymentBody2
|
|
5826
|
+
});
|
|
5827
|
+
import joi113 from "joi";
|
|
5828
|
+
var findQueryKeys32 = {};
|
|
5829
|
+
var findQuery34 = joi113.object().keys(findQueryKeys32).messages(messages);
|
|
5830
|
+
var findWithPaginationQueryKeys29 = {
|
|
5831
|
+
per_page: joi113.number().integer().positive().default(10).optional(),
|
|
5832
|
+
current_page: joi113.number().integer().positive().default(1).optional()
|
|
5833
|
+
};
|
|
5834
|
+
var findWithPaginationQuery28 = joi113.object().keys(findWithPaginationQueryKeys29).messages(messages);
|
|
5835
|
+
var findSettledMaterialEntranceQueryKeys2 = {
|
|
5836
|
+
provider_id: joi113.string().uuid().required(),
|
|
5837
|
+
client_id: joi113.string().uuid().allow(null).required()
|
|
5838
|
+
};
|
|
5839
|
+
var findSettledMaterialEntranceQuery2 = joi113.object().keys(findSettledMaterialEntranceQueryKeys2).messages(messages);
|
|
5840
|
+
var providerPaymentDocumentKeys2 = {
|
|
5841
|
+
document_header_id: joi113.string().uuid().required(),
|
|
5842
|
+
value: joi113.number().required(),
|
|
5843
|
+
discount_value: joi113.number().optional().allow(0, "", null).when("value", {
|
|
5844
|
+
is: joi113.number().positive(),
|
|
5845
|
+
then: joi113.number().max(joi113.ref("value")),
|
|
5846
|
+
otherwise: joi113.number().min(joi113.ref("value"))
|
|
5847
|
+
})
|
|
5848
|
+
};
|
|
5849
|
+
var providerPaymentDocument2 = joi113.object().keys(providerPaymentDocumentKeys2).required();
|
|
5850
|
+
var providerPaymentBodyKeys2 = {
|
|
5851
|
+
provider_id: joi113.string().uuid().required(),
|
|
5852
|
+
client_id: joi113.string().uuid().allow(null).optional(),
|
|
5853
|
+
documents: joi113.array().items(providerPaymentDocument2).required(),
|
|
5854
|
+
total: joi113.number().positive().allow(0).required()
|
|
5855
|
+
};
|
|
5856
|
+
var providerPaymentBody2 = joi113.array().items(joi113.object().keys(providerPaymentBodyKeys2)).messages(messages);
|
|
5857
|
+
var exportPaymentsBodyKeys = {
|
|
5858
|
+
value: joi113.number().positive().required(),
|
|
5859
|
+
provider: joi113.string().required(),
|
|
5860
|
+
npf_ids: joi113.array().items(joi113.string().uuid().required()).optional()
|
|
5861
|
+
};
|
|
5862
|
+
var exportPaymentsBody = joi113.array().items(joi113.object().keys(exportPaymentsBodyKeys)).messages(messages);
|
|
5863
|
+
var exportCurrentAccountBetweenDatesQueryKeys = {
|
|
5864
|
+
owner_id: joi113.string().required(),
|
|
5865
|
+
output: joi113.string().valid(...IExportCurrentAccountOutputOptions).required(),
|
|
5866
|
+
start_date: joi113.string().optional(),
|
|
5867
|
+
end_date: joi113.string().optional(),
|
|
5868
|
+
token: joi113.string().required()
|
|
5869
|
+
};
|
|
5870
|
+
var exportCurrentAccountBetweenDatesQuery = joi113.object().keys(exportCurrentAccountBetweenDatesQueryKeys).messages(messages);
|
|
5871
|
+
var findSettledMaterialEntranceBuDateParamsKeys2 = {
|
|
5872
|
+
due_date: joi113.string().optional()
|
|
5873
|
+
};
|
|
5874
|
+
var findSettledMaterialEntranceBuDateParams2 = joi113.object().keys(findSettledMaterialEntranceBuDateParamsKeys2).messages(messages);
|
|
5875
|
+
var findPaymentsNotExportedQuery = joi113.object().keys({
|
|
5876
|
+
whiteList: joi113.array().items(joi113.string().uuid().required()).optional()
|
|
5877
|
+
}).messages(messages);
|
|
5878
|
+
|
|
5879
|
+
// src/modules/supply/paymentBatch/interface.ts
|
|
5880
|
+
var interface_exports64 = {};
|
|
5881
|
+
__export(interface_exports64, {
|
|
5882
|
+
LowerName: () => LowerName106,
|
|
5883
|
+
Route: () => Route108,
|
|
5884
|
+
UpperName: () => UpperName106
|
|
5885
|
+
});
|
|
5886
|
+
var Route108 = "payment";
|
|
5887
|
+
var UpperName106 = "Payment";
|
|
5888
|
+
var LowerName106 = UpperName106[0].toLowerCase() + UpperName106.substring(1);
|
|
5889
|
+
|
|
5890
|
+
// src/modules/supply/paymentBatch/route.schema.ts
|
|
5891
|
+
var route_schema_exports113 = {};
|
|
5892
|
+
__export(route_schema_exports113, {
|
|
5893
|
+
exportPaymentsBody: () => exportPaymentsBody2,
|
|
5894
|
+
findPaymentsNotExportedQuery: () => findPaymentsNotExportedQuery2
|
|
5895
|
+
});
|
|
5896
|
+
import joi114 from "joi";
|
|
5897
|
+
var exportPaymentsBodyKeys2 = {
|
|
5898
|
+
value: joi114.number().positive().required(),
|
|
5899
|
+
provider: joi114.string().required(),
|
|
5900
|
+
npf_ids: joi114.array().items(joi114.string().uuid().required()).optional()
|
|
5901
|
+
};
|
|
5902
|
+
var exportPaymentsBody2 = joi114.array().items(joi114.object().keys(exportPaymentsBodyKeys2)).messages(messages);
|
|
5903
|
+
var findPaymentsNotExportedQuery2 = joi114.object().keys({
|
|
5904
|
+
whiteList: joi114.array().items(joi114.string().uuid().required()).optional()
|
|
5905
|
+
}).messages(messages);
|
|
5906
|
+
|
|
5793
5907
|
// src/index.ts
|
|
5794
5908
|
var index_default = main_exports;
|
|
5795
5909
|
export {
|
package/dist/index.js
CHANGED
|
@@ -30,6 +30,8 @@ __export(main_exports, {
|
|
|
30
30
|
CommissionerRoutes: () => route_schema_exports6,
|
|
31
31
|
Country: () => interface_exports6,
|
|
32
32
|
CountryRoutes: () => route_schema_exports7,
|
|
33
|
+
CurrentAccount: () => interface_exports63,
|
|
34
|
+
CurrentAccountRoutes: () => route_schema_exports112,
|
|
33
35
|
Dashboard: () => interface_exports54,
|
|
34
36
|
DashboardRoutes: () => route_schema_exports101,
|
|
35
37
|
DeliveryMethods: () => interfaces_exports3,
|
|
@@ -88,6 +90,10 @@ __export(main_exports, {
|
|
|
88
90
|
MaturityDatesRoutes: () => route_schema_exports28,
|
|
89
91
|
Multimedia: () => interfaces_exports19,
|
|
90
92
|
MultimediaRoutes: () => route_schema_exports29,
|
|
93
|
+
NPF: () => interface_exports61,
|
|
94
|
+
NPFRoutes: () => route_schema_exports110,
|
|
95
|
+
NRCL: () => interface_exports62,
|
|
96
|
+
NRCLRoutes: () => route_schema_exports111,
|
|
91
97
|
Npc: () => interfaces_exports27,
|
|
92
98
|
NpcRoutes: () => route_schema_exports64,
|
|
93
99
|
Observation: () => interfaces_exports20,
|
|
@@ -100,6 +106,8 @@ __export(main_exports, {
|
|
|
100
106
|
Password: () => interfaces_exports22,
|
|
101
107
|
PasswordRoutes: () => route_schema_exports32,
|
|
102
108
|
Payment: () => interface_exports15,
|
|
109
|
+
PaymentBatch: () => interface_exports64,
|
|
110
|
+
PaymentBatchRoutes: () => route_schema_exports113,
|
|
103
111
|
PaymentMethods: () => interfaces_exports23,
|
|
104
112
|
PaymentMethodsRoutes: () => route_schema_exports34,
|
|
105
113
|
PaymentRoutes: () => route_schema_exports33,
|
|
@@ -1349,7 +1357,6 @@ __export(route_schema_exports9, {
|
|
|
1349
1357
|
documentPdfQuery: () => documentPdfQuery,
|
|
1350
1358
|
findByTypeQuery: () => findByTypeQuery,
|
|
1351
1359
|
findQuery: () => findQuery6,
|
|
1352
|
-
regularizarMultiplosBody: () => regularizarMultiplosBody,
|
|
1353
1360
|
sendClientNotificationBody: () => sendClientNotificationBody,
|
|
1354
1361
|
transferClientOwnershipBody: () => transferClientOwnershipBody,
|
|
1355
1362
|
updateBody: () => updateBody8,
|
|
@@ -1630,22 +1637,6 @@ var documentPdfQuery = joi10.object().keys(documentPdfQueryKeys).messages(messag
|
|
|
1630
1637
|
var documentLineQuery = joi10.object().keys({
|
|
1631
1638
|
closed: joi10.boolean().default(false).optional()
|
|
1632
1639
|
}).messages(messages);
|
|
1633
|
-
var multipleDocumentsBodyKeys = {
|
|
1634
|
-
owner_id: joi10.string().uuid().required(),
|
|
1635
|
-
document_header_id: joi10.string().uuid().required(),
|
|
1636
|
-
type: joi10.string().valid("credit", "debit").required(),
|
|
1637
|
-
value: joi10.number().positive().required()
|
|
1638
|
-
};
|
|
1639
|
-
var multiplePaymentsBodyKeys = {
|
|
1640
|
-
value: joi10.number().positive().required(),
|
|
1641
|
-
payment_method_id: joi10.string().uuid().required(),
|
|
1642
|
-
payment_method: joi10.string().required()
|
|
1643
|
-
};
|
|
1644
|
-
var regularizarMultiplosBodyKeys = {
|
|
1645
|
-
documents: joi10.array().items(multipleDocumentsBodyKeys).required(),
|
|
1646
|
-
payments: joi10.array().items(multiplePaymentsBodyKeys).optional()
|
|
1647
|
-
};
|
|
1648
|
-
var regularizarMultiplosBody = joi10.object().keys(regularizarMultiplosBodyKeys).messages(messages);
|
|
1649
1640
|
|
|
1650
1641
|
// src/modules/supply/documentHeaderHistory/interfaces.ts
|
|
1651
1642
|
var interfaces_exports6 = {};
|
|
@@ -2534,8 +2525,6 @@ var resetBody = joi33.object().keys(resetBodyKeys).messages(messages);
|
|
|
2534
2525
|
// src/modules/supply/payment/interface.ts
|
|
2535
2526
|
var interface_exports15 = {};
|
|
2536
2527
|
__export(interface_exports15, {
|
|
2537
|
-
IExportCurrentAccountOutputEnum: () => IExportCurrentAccountOutputEnum,
|
|
2538
|
-
IExportCurrentAccountOutputOptions: () => IExportCurrentAccountOutputOptions,
|
|
2539
2528
|
LowerName: () => LowerName27,
|
|
2540
2529
|
Route: () => Route28,
|
|
2541
2530
|
UpperName: () => UpperName27
|
|
@@ -2543,24 +2532,14 @@ __export(interface_exports15, {
|
|
|
2543
2532
|
var Route28 = "payment";
|
|
2544
2533
|
var UpperName27 = "Payment";
|
|
2545
2534
|
var LowerName27 = UpperName27[0].toLowerCase() + UpperName27.substring(1);
|
|
2546
|
-
var IExportCurrentAccountOutputEnum = {
|
|
2547
|
-
csv: "csv",
|
|
2548
|
-
pdf: "pdf"
|
|
2549
|
-
};
|
|
2550
|
-
var IExportCurrentAccountOutputOptions = Object.keys(IExportCurrentAccountOutputEnum);
|
|
2551
2535
|
|
|
2552
2536
|
// src/modules/supply/payment/route.schema.ts
|
|
2553
2537
|
var route_schema_exports33 = {};
|
|
2554
2538
|
__export(route_schema_exports33, {
|
|
2555
|
-
exportCurrentAccountBetweenDatesQuery: () => exportCurrentAccountBetweenDatesQuery,
|
|
2556
|
-
exportPaymentsBody: () => exportPaymentsBody,
|
|
2557
|
-
findCurrentAccountWithPaginationQuery: () => findCurrentAccountWithPaginationQuery,
|
|
2558
|
-
findPaymentsNotExportedQuery: () => findPaymentsNotExportedQuery,
|
|
2559
2539
|
findQuery: () => findQuery10,
|
|
2560
2540
|
findSettledMaterialEntranceBuDateParams: () => findSettledMaterialEntranceBuDateParams,
|
|
2561
2541
|
findSettledMaterialEntranceQuery: () => findSettledMaterialEntranceQuery,
|
|
2562
|
-
findWithPaginationQuery: () => findWithPaginationQuery9
|
|
2563
|
-
providerPaymentBody: () => providerPaymentBody
|
|
2542
|
+
findWithPaginationQuery: () => findWithPaginationQuery9
|
|
2564
2543
|
});
|
|
2565
2544
|
import joi34 from "joi";
|
|
2566
2545
|
var findQueryKeys10 = {};
|
|
@@ -2575,50 +2554,10 @@ var findSettledMaterialEntranceQueryKeys = {
|
|
|
2575
2554
|
client_id: joi34.string().uuid().allow(null).required()
|
|
2576
2555
|
};
|
|
2577
2556
|
var findSettledMaterialEntranceQuery = joi34.object().keys(findSettledMaterialEntranceQueryKeys).messages(messages);
|
|
2578
|
-
var providerPaymentDocumentKeys = {
|
|
2579
|
-
document_header_id: joi34.string().uuid().required(),
|
|
2580
|
-
value: joi34.number().required(),
|
|
2581
|
-
discount_value: joi34.number().optional().allow(0, "", null).when("value", {
|
|
2582
|
-
is: joi34.number().positive(),
|
|
2583
|
-
then: joi34.number().max(joi34.ref("value")),
|
|
2584
|
-
otherwise: joi34.number().min(joi34.ref("value"))
|
|
2585
|
-
})
|
|
2586
|
-
};
|
|
2587
|
-
var providerPaymentDocument = joi34.object().keys(providerPaymentDocumentKeys).required();
|
|
2588
|
-
var providerPaymentBodyKeys = {
|
|
2589
|
-
provider_id: joi34.string().uuid().required(),
|
|
2590
|
-
client_id: joi34.string().uuid().allow(null).optional(),
|
|
2591
|
-
documents: joi34.array().items(providerPaymentDocument).required(),
|
|
2592
|
-
total: joi34.number().positive().allow(0).required()
|
|
2593
|
-
};
|
|
2594
|
-
var providerPaymentBody = joi34.array().items(joi34.object().keys(providerPaymentBodyKeys)).messages(messages);
|
|
2595
|
-
var exportPaymentsBodyKeys = {
|
|
2596
|
-
value: joi34.number().positive().required(),
|
|
2597
|
-
provider: joi34.string().required(),
|
|
2598
|
-
npf_ids: joi34.array().items(joi34.string().uuid().required()).optional()
|
|
2599
|
-
};
|
|
2600
|
-
var exportPaymentsBody = joi34.array().items(joi34.object().keys(exportPaymentsBodyKeys)).messages(messages);
|
|
2601
|
-
var exportCurrentAccountBetweenDatesQueryKeys = {
|
|
2602
|
-
owner_id: joi34.string().required(),
|
|
2603
|
-
output: joi34.string().valid(...IExportCurrentAccountOutputOptions).required(),
|
|
2604
|
-
start_date: joi34.string().optional(),
|
|
2605
|
-
end_date: joi34.string().optional(),
|
|
2606
|
-
token: joi34.string().required()
|
|
2607
|
-
};
|
|
2608
|
-
var exportCurrentAccountBetweenDatesQuery = joi34.object().keys(exportCurrentAccountBetweenDatesQueryKeys).messages(messages);
|
|
2609
2557
|
var findSettledMaterialEntranceBuDateParamsKeys = {
|
|
2610
2558
|
due_date: joi34.string().optional()
|
|
2611
2559
|
};
|
|
2612
2560
|
var findSettledMaterialEntranceBuDateParams = joi34.object().keys(findSettledMaterialEntranceBuDateParamsKeys).messages(messages);
|
|
2613
|
-
var findPaymentsNotExportedQuery = joi34.object().keys({
|
|
2614
|
-
whiteList: joi34.array().items(joi34.string().uuid().required()).optional()
|
|
2615
|
-
}).messages(messages);
|
|
2616
|
-
var findCurrentAccountWithPaginationQueryKeys = {
|
|
2617
|
-
owner_id: joi34.string().uuid().required(),
|
|
2618
|
-
per_page: joi34.number().integer().positive().default(10).optional(),
|
|
2619
|
-
current_page: joi34.number().integer().positive().default(1).optional()
|
|
2620
|
-
};
|
|
2621
|
-
var findCurrentAccountWithPaginationQuery = joi34.object().keys(findCurrentAccountWithPaginationQueryKeys).messages(messages);
|
|
2622
2561
|
|
|
2623
2562
|
// src/modules/user/paymentMethods/interfaces.ts
|
|
2624
2563
|
var interfaces_exports23 = {};
|
|
@@ -5790,6 +5729,181 @@ var editPreviewChatMessageRequestBody = {
|
|
|
5790
5729
|
};
|
|
5791
5730
|
var editPreviewChatMessageRequest = joi110.object().keys(editPreviewChatMessageRequestBody).messages(messages);
|
|
5792
5731
|
|
|
5732
|
+
// src/modules/document/NPF/interface.ts
|
|
5733
|
+
var interface_exports61 = {};
|
|
5734
|
+
__export(interface_exports61, {
|
|
5735
|
+
Route: () => Route105
|
|
5736
|
+
});
|
|
5737
|
+
var Route105 = "npf";
|
|
5738
|
+
|
|
5739
|
+
// src/modules/document/NPF/route.schema.ts
|
|
5740
|
+
var route_schema_exports110 = {};
|
|
5741
|
+
__export(route_schema_exports110, {
|
|
5742
|
+
providerPaymentBody: () => providerPaymentBody
|
|
5743
|
+
});
|
|
5744
|
+
import joi111 from "joi";
|
|
5745
|
+
var providerPaymentDocumentKeys = {
|
|
5746
|
+
document_header_id: joi111.string().uuid().required(),
|
|
5747
|
+
value: joi111.number().required(),
|
|
5748
|
+
discount_value: joi111.number().optional().allow(0, "", null).when("value", {
|
|
5749
|
+
is: joi111.number().positive(),
|
|
5750
|
+
then: joi111.number().max(joi111.ref("value")),
|
|
5751
|
+
otherwise: joi111.number().min(joi111.ref("value"))
|
|
5752
|
+
})
|
|
5753
|
+
};
|
|
5754
|
+
var providerPaymentDocument = joi111.object().keys(providerPaymentDocumentKeys).required();
|
|
5755
|
+
var providerPaymentBodyKeys = {
|
|
5756
|
+
provider_id: joi111.string().uuid().required(),
|
|
5757
|
+
client_id: joi111.string().uuid().allow(null).optional(),
|
|
5758
|
+
documents: joi111.array().items(providerPaymentDocument).required(),
|
|
5759
|
+
total: joi111.number().positive().allow(0).required()
|
|
5760
|
+
};
|
|
5761
|
+
var providerPaymentBody = joi111.array().items(joi111.object().keys(providerPaymentBodyKeys)).messages(messages);
|
|
5762
|
+
|
|
5763
|
+
// src/modules/document/NRCL/interface.ts
|
|
5764
|
+
var interface_exports62 = {};
|
|
5765
|
+
__export(interface_exports62, {
|
|
5766
|
+
LowerName: () => LowerName104,
|
|
5767
|
+
Route: () => Route106,
|
|
5768
|
+
UpperName: () => UpperName104
|
|
5769
|
+
});
|
|
5770
|
+
var Route106 = "documentHeader";
|
|
5771
|
+
var UpperName104 = "DocumentHeader";
|
|
5772
|
+
var LowerName104 = UpperName104[0].toLowerCase() + UpperName104.substring(1);
|
|
5773
|
+
|
|
5774
|
+
// src/modules/document/NRCL/route.schema.ts
|
|
5775
|
+
var route_schema_exports111 = {};
|
|
5776
|
+
__export(route_schema_exports111, {
|
|
5777
|
+
regularizarMultiplosBody: () => regularizarMultiplosBody
|
|
5778
|
+
});
|
|
5779
|
+
import joi112 from "joi";
|
|
5780
|
+
var multipleDocumentsBodyKeys = {
|
|
5781
|
+
owner_id: joi112.string().uuid().required(),
|
|
5782
|
+
document_header_id: joi112.string().uuid().required(),
|
|
5783
|
+
type: joi112.string().valid("credit", "debit").required(),
|
|
5784
|
+
value: joi112.number().positive().required()
|
|
5785
|
+
};
|
|
5786
|
+
var multiplePaymentsBodyKeys = {
|
|
5787
|
+
value: joi112.number().positive().required(),
|
|
5788
|
+
payment_method_id: joi112.string().uuid().required(),
|
|
5789
|
+
payment_method: joi112.string().required()
|
|
5790
|
+
};
|
|
5791
|
+
var regularizarMultiplosBodyKeys = {
|
|
5792
|
+
documents: joi112.array().items(multipleDocumentsBodyKeys).required(),
|
|
5793
|
+
payments: joi112.array().items(multiplePaymentsBodyKeys).optional()
|
|
5794
|
+
};
|
|
5795
|
+
var regularizarMultiplosBody = joi112.object().keys(regularizarMultiplosBodyKeys).messages(messages);
|
|
5796
|
+
|
|
5797
|
+
// src/modules/supply/currentAccount/interface.ts
|
|
5798
|
+
var interface_exports63 = {};
|
|
5799
|
+
__export(interface_exports63, {
|
|
5800
|
+
IExportCurrentAccountOutputEnum: () => IExportCurrentAccountOutputEnum,
|
|
5801
|
+
IExportCurrentAccountOutputOptions: () => IExportCurrentAccountOutputOptions,
|
|
5802
|
+
LowerName: () => LowerName105,
|
|
5803
|
+
Route: () => Route107,
|
|
5804
|
+
UpperName: () => UpperName105
|
|
5805
|
+
});
|
|
5806
|
+
var Route107 = "payment";
|
|
5807
|
+
var UpperName105 = "Payment";
|
|
5808
|
+
var LowerName105 = UpperName105[0].toLowerCase() + UpperName105.substring(1);
|
|
5809
|
+
var IExportCurrentAccountOutputEnum = {
|
|
5810
|
+
csv: "csv",
|
|
5811
|
+
pdf: "pdf"
|
|
5812
|
+
};
|
|
5813
|
+
var IExportCurrentAccountOutputOptions = Object.keys(IExportCurrentAccountOutputEnum);
|
|
5814
|
+
|
|
5815
|
+
// src/modules/supply/currentAccount/route.schema.ts
|
|
5816
|
+
var route_schema_exports112 = {};
|
|
5817
|
+
__export(route_schema_exports112, {
|
|
5818
|
+
exportCurrentAccountBetweenDatesQuery: () => exportCurrentAccountBetweenDatesQuery,
|
|
5819
|
+
exportPaymentsBody: () => exportPaymentsBody,
|
|
5820
|
+
findPaymentsNotExportedQuery: () => findPaymentsNotExportedQuery,
|
|
5821
|
+
findQuery: () => findQuery34,
|
|
5822
|
+
findSettledMaterialEntranceBuDateParams: () => findSettledMaterialEntranceBuDateParams2,
|
|
5823
|
+
findSettledMaterialEntranceQuery: () => findSettledMaterialEntranceQuery2,
|
|
5824
|
+
findWithPaginationQuery: () => findWithPaginationQuery28,
|
|
5825
|
+
providerPaymentBody: () => providerPaymentBody2
|
|
5826
|
+
});
|
|
5827
|
+
import joi113 from "joi";
|
|
5828
|
+
var findQueryKeys32 = {};
|
|
5829
|
+
var findQuery34 = joi113.object().keys(findQueryKeys32).messages(messages);
|
|
5830
|
+
var findWithPaginationQueryKeys29 = {
|
|
5831
|
+
per_page: joi113.number().integer().positive().default(10).optional(),
|
|
5832
|
+
current_page: joi113.number().integer().positive().default(1).optional()
|
|
5833
|
+
};
|
|
5834
|
+
var findWithPaginationQuery28 = joi113.object().keys(findWithPaginationQueryKeys29).messages(messages);
|
|
5835
|
+
var findSettledMaterialEntranceQueryKeys2 = {
|
|
5836
|
+
provider_id: joi113.string().uuid().required(),
|
|
5837
|
+
client_id: joi113.string().uuid().allow(null).required()
|
|
5838
|
+
};
|
|
5839
|
+
var findSettledMaterialEntranceQuery2 = joi113.object().keys(findSettledMaterialEntranceQueryKeys2).messages(messages);
|
|
5840
|
+
var providerPaymentDocumentKeys2 = {
|
|
5841
|
+
document_header_id: joi113.string().uuid().required(),
|
|
5842
|
+
value: joi113.number().required(),
|
|
5843
|
+
discount_value: joi113.number().optional().allow(0, "", null).when("value", {
|
|
5844
|
+
is: joi113.number().positive(),
|
|
5845
|
+
then: joi113.number().max(joi113.ref("value")),
|
|
5846
|
+
otherwise: joi113.number().min(joi113.ref("value"))
|
|
5847
|
+
})
|
|
5848
|
+
};
|
|
5849
|
+
var providerPaymentDocument2 = joi113.object().keys(providerPaymentDocumentKeys2).required();
|
|
5850
|
+
var providerPaymentBodyKeys2 = {
|
|
5851
|
+
provider_id: joi113.string().uuid().required(),
|
|
5852
|
+
client_id: joi113.string().uuid().allow(null).optional(),
|
|
5853
|
+
documents: joi113.array().items(providerPaymentDocument2).required(),
|
|
5854
|
+
total: joi113.number().positive().allow(0).required()
|
|
5855
|
+
};
|
|
5856
|
+
var providerPaymentBody2 = joi113.array().items(joi113.object().keys(providerPaymentBodyKeys2)).messages(messages);
|
|
5857
|
+
var exportPaymentsBodyKeys = {
|
|
5858
|
+
value: joi113.number().positive().required(),
|
|
5859
|
+
provider: joi113.string().required(),
|
|
5860
|
+
npf_ids: joi113.array().items(joi113.string().uuid().required()).optional()
|
|
5861
|
+
};
|
|
5862
|
+
var exportPaymentsBody = joi113.array().items(joi113.object().keys(exportPaymentsBodyKeys)).messages(messages);
|
|
5863
|
+
var exportCurrentAccountBetweenDatesQueryKeys = {
|
|
5864
|
+
owner_id: joi113.string().required(),
|
|
5865
|
+
output: joi113.string().valid(...IExportCurrentAccountOutputOptions).required(),
|
|
5866
|
+
start_date: joi113.string().optional(),
|
|
5867
|
+
end_date: joi113.string().optional(),
|
|
5868
|
+
token: joi113.string().required()
|
|
5869
|
+
};
|
|
5870
|
+
var exportCurrentAccountBetweenDatesQuery = joi113.object().keys(exportCurrentAccountBetweenDatesQueryKeys).messages(messages);
|
|
5871
|
+
var findSettledMaterialEntranceBuDateParamsKeys2 = {
|
|
5872
|
+
due_date: joi113.string().optional()
|
|
5873
|
+
};
|
|
5874
|
+
var findSettledMaterialEntranceBuDateParams2 = joi113.object().keys(findSettledMaterialEntranceBuDateParamsKeys2).messages(messages);
|
|
5875
|
+
var findPaymentsNotExportedQuery = joi113.object().keys({
|
|
5876
|
+
whiteList: joi113.array().items(joi113.string().uuid().required()).optional()
|
|
5877
|
+
}).messages(messages);
|
|
5878
|
+
|
|
5879
|
+
// src/modules/supply/paymentBatch/interface.ts
|
|
5880
|
+
var interface_exports64 = {};
|
|
5881
|
+
__export(interface_exports64, {
|
|
5882
|
+
LowerName: () => LowerName106,
|
|
5883
|
+
Route: () => Route108,
|
|
5884
|
+
UpperName: () => UpperName106
|
|
5885
|
+
});
|
|
5886
|
+
var Route108 = "payment";
|
|
5887
|
+
var UpperName106 = "Payment";
|
|
5888
|
+
var LowerName106 = UpperName106[0].toLowerCase() + UpperName106.substring(1);
|
|
5889
|
+
|
|
5890
|
+
// src/modules/supply/paymentBatch/route.schema.ts
|
|
5891
|
+
var route_schema_exports113 = {};
|
|
5892
|
+
__export(route_schema_exports113, {
|
|
5893
|
+
exportPaymentsBody: () => exportPaymentsBody2,
|
|
5894
|
+
findPaymentsNotExportedQuery: () => findPaymentsNotExportedQuery2
|
|
5895
|
+
});
|
|
5896
|
+
import joi114 from "joi";
|
|
5897
|
+
var exportPaymentsBodyKeys2 = {
|
|
5898
|
+
value: joi114.number().positive().required(),
|
|
5899
|
+
provider: joi114.string().required(),
|
|
5900
|
+
npf_ids: joi114.array().items(joi114.string().uuid().required()).optional()
|
|
5901
|
+
};
|
|
5902
|
+
var exportPaymentsBody2 = joi114.array().items(joi114.object().keys(exportPaymentsBodyKeys2)).messages(messages);
|
|
5903
|
+
var findPaymentsNotExportedQuery2 = joi114.object().keys({
|
|
5904
|
+
whiteList: joi114.array().items(joi114.string().uuid().required()).optional()
|
|
5905
|
+
}).messages(messages);
|
|
5906
|
+
|
|
5793
5907
|
// src/index.ts
|
|
5794
5908
|
var index_default = main_exports;
|
|
5795
5909
|
export {
|
package/dist/main.d.ts
CHANGED
|
@@ -228,4 +228,12 @@ import * as Tag from './modules/stock/tag/interface';
|
|
|
228
228
|
import * as TagRoutes from './modules/stock/tag/route.schema';
|
|
229
229
|
import * as Gmails from './modules/stock/gmails/interface';
|
|
230
230
|
import * as GmailsRoutes from './modules/stock/gmails/route.schema';
|
|
231
|
-
|
|
231
|
+
import * as NPF from './modules/document/NPF/interface';
|
|
232
|
+
import * as NPFRoutes from './modules/document/NPF/route.schema';
|
|
233
|
+
import * as NRCL from './modules/document/NRCL/interface';
|
|
234
|
+
import * as NRCLRoutes from './modules/document/NRCL/route.schema';
|
|
235
|
+
import * as CurrentAccount from './modules/supply/currentAccount/interface';
|
|
236
|
+
import * as CurrentAccountRoutes from './modules/supply/currentAccount/route.schema';
|
|
237
|
+
import * as PaymentBatch from './modules/supply/paymentBatch/interface';
|
|
238
|
+
import * as PaymentBatchRoutes from './modules/supply/paymentBatch/route.schema';
|
|
239
|
+
export { shared, viewErrors, stockErrors, userErrors, documentManagementErrors, integrationErrors, ZipCode, ZipCodeRoutes, BankData, BankDataRoutes, Client, ClientRoutes, ClientType, ClientTypeRoutes, Chat, ChatRoutes, Commissioner, CommissionerRoutes, Country, CountryRoutes, DeliveryMethods, DeliveryMethodsRoutes, DocumentHeader, DocumentHeaderRoutes, DocumentHeaderHistory, BillOfLading, BillOfLadingRoutes, ProductionOrder, ProductionOrderRoutes, Proforma, ProformaRoutes, PropostaFornecedor, PropostaFornecedorRoutes, ProviderCreditNoteFromReturn, ProviderCreditNoteFromReturnRoutes, ProviderFinancialCreditNote, ProviderFinancialCreditNoteRoutes, ProviderServiceInvoice, ProviderServiceInvoiceRoutes, DocumentLine, DocumentLineRoutes, DocumentLineAssoc, DocumentLineAssocRoutes, DocumentSet, DocumentSetRoutes, DocumentType, DocumentTypeRoutes, ExternalDocumentType, ExternalDocumentHeader, ExternalDocumentHeaderRoutes, Favorites, FavoritesRoutes, File, FileRoutes, GroupPermissions, GroupPermissionsRoutes, GoogleSheets, GoogleSheetsRoutes, Language, LanguageRoutes, Location, LocationRoutes, MaturityDates, MaturityDatesRoutes, Multimedia, MultimediaRoutes, OrderManagement, Observation, ObservationRoutes, ObservationType, ObservationTypeRoutes, Password, PasswordRoutes, Payment, PaymentRoutes, PaymentMethods, PaymentMethodsRoutes, Permissions, PermissionsRoutes, ProductImage, ProductImageRoutes, Promotion, PromotionRoutes, PromotionAssoc, PromotionAssocRoutes, Providers, ProvidersRoutes, ProviderType, ProviderTypeRoutes, PurchaseConditions, PurchaseConditionsRoutes, ReasonForExemption, ReasonForExemptionRoutes, RefreshToken, RefreshTokenRoutes, SegmentsArea, SegmentsAreaRoutes, Sessions, SessionsRoutes, Shippings, ShippingsRoutes, StoreOperator, StoreOperatorRoutes, Swift, SwiftRoutes, TypeOfLocation, TypeOfLocationRoutes, UnitOfMeasure, UnitOfMeasureRoutes, UserPermissions, UserPermissionsRoutes, UserPositions, UserPositionsRoutes, Users, UsersRoutes, UserTokens, UserTokensRoutes, VatValidation, VatValidationRoutes, VatTax, VatTaxRoutes, VatTaxZone, VatTaxZoneRoutes, Vehicles, VehiclesRoutes, Workflow, WorkflowRoutes, StockMovement, StockMovementRoutes, Tenant, TenantRoutes, PreSale, PreSaleRoutes, PreSaleProduct, PreSaleProductRoutes, Npc, NpcRoutes, Printer, PrinterRoutes, SchedulePrintJob, SchedulePrintJobRoutes, QueryList, QueryListRoutes, QueryParameter, QueryParameterRoutes, ReturnReason, ReturnReasonRoutes, PropostaSheets, PropostaSheetsRoutes, Schedule, ScheduleRoutes, GoogleFilePermission, GoogleFilePermissionRoutes, Settings, SettingsRoutes, Tickets, TicketsRoutes, Channel, ChannelRoutes, TicketsLanguage, TicketsLanguageRoutes, CLT, CLTRoutes, StartDocumentHeaderLastUpdate, Persona, PersonaRoutes, ProjectInfo, ProjectInfoRoutes, EmailVerification, EmailVerificationRoutes, EmailLog, EmailLogRoutes, Purchase, PurchaseRoutes, Order, OrderRoutes, MaterialEntrance, MaterialEntranceRoutes, Transformado, TransformadoRoutes, Quebra, QuebraRoutes, UpfrontReturn, UpfrontReturnRoutes, SavedEmPicking, SavedEmPickingRoutes, EmailTemplate, EmailTemplateRoutes, EmailTemplateAttachment, EmailTemplateAttachmentRoutes, Inventario, InventarioRoutes, ReturnToProvider, ReturnToProviderRoutes, Prison, PrisonRoutes, DocumentLineNote, DocumentLineNoteRoutes, SavedProviderProposal, SavedProviderProposalRoutes, ProductGoogleSheets, ProductGoogleSheetsRoutes, Task, TaskRoutes, TaskMessage, TaskMessageRoutes, RecurrentTasks, TaskRead, TaskReadRoutes, Theme, ThemeRoutes, Dashboard, DashboardRoutes, ChatRapidMessage, ChatRapidMessageRoutes, SideMenu, SideMenuRoutes, AdminPanel, ErrorLog, ErrorLogRoutes, DocumentLineRm, DocumentLineRmRoutes, DocumentLineMt, DocumentLineMtRoutes, ChatSubscriber, ChatSubscriberRoutes, Tag, TagRoutes, Gmails, GmailsRoutes, NPF, NPFRoutes, NRCL, NRCLRoutes, CurrentAccount, CurrentAccountRoutes, PaymentBatch, PaymentBatchRoutes, };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as IShared from '../../../shared/interface';
|
|
2
|
+
export declare const Route = "npf";
|
|
3
|
+
export interface IProviderPaymentDocument {
|
|
4
|
+
document_header_id: string;
|
|
5
|
+
value: number;
|
|
6
|
+
discount_value?: number | null;
|
|
7
|
+
}
|
|
8
|
+
export interface IProviderPaymentRequest {
|
|
9
|
+
provider_id: string;
|
|
10
|
+
client_id: string | null;
|
|
11
|
+
documents: IProviderPaymentDocument[];
|
|
12
|
+
total: number;
|
|
13
|
+
}
|
|
14
|
+
export interface IRepository {
|
|
15
|
+
createProvidersPayments(params: IProviderPaymentRequest[]): Promise<string[]>;
|
|
16
|
+
}
|
|
17
|
+
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import * as IShared from '../../../shared/interface';
|
|
2
|
+
import { DocumentHeader } from '../../../shared/entities/stock';
|
|
3
|
+
export type Entity = Omit<DocumentHeader, 'external_data'>;
|
|
4
|
+
export declare const Route = "documentHeader";
|
|
5
|
+
export declare const UpperName = "DocumentHeader";
|
|
6
|
+
export declare const LowerName: string;
|
|
7
|
+
export interface IMultipleRegularizationPayments {
|
|
8
|
+
value: number;
|
|
9
|
+
payment_method_id: string;
|
|
10
|
+
payment_method: string;
|
|
11
|
+
}
|
|
12
|
+
export type IMultipleRegularizationPaymentsType = 'credit' | 'debit';
|
|
13
|
+
export interface IMultipleRegularizationDocuments {
|
|
14
|
+
owner_id: string;
|
|
15
|
+
document_header_id: string;
|
|
16
|
+
type: IMultipleRegularizationPaymentsType;
|
|
17
|
+
value: number;
|
|
18
|
+
}
|
|
19
|
+
export interface IMultipleRegularizations {
|
|
20
|
+
documents: IMultipleRegularizationDocuments[];
|
|
21
|
+
payments?: IMultipleRegularizationPayments[];
|
|
22
|
+
}
|
|
23
|
+
export interface IRepository {
|
|
24
|
+
regularizarMultiplosDocumentos(data: IMultipleRegularizations): Promise<void>;
|
|
25
|
+
}
|
|
26
|
+
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
import * as IShared from '../../../shared/interface';
|
|
2
|
+
import { Payment, DocumentHeader } from '../../../shared/entities/stock';
|
|
3
|
+
import * as IObservation from '../../integration/observation/interfaces';
|
|
4
|
+
import { type ICreateFromHeaderRequest } from '../documentHeader/interfaces';
|
|
5
|
+
export type Entity = Payment;
|
|
6
|
+
export declare const Route = "payment";
|
|
7
|
+
export declare const UpperName = "Payment";
|
|
8
|
+
export declare const LowerName: string;
|
|
9
|
+
type IEntityExtended = Entity;
|
|
10
|
+
export type IFindByIdResponse = Omit<IEntityExtended, ''>;
|
|
11
|
+
export type IFindByOwnerIdResponse = Omit<IEntityExtended, ''>;
|
|
12
|
+
export type IFindRequest = Record<string, unknown>;
|
|
13
|
+
export type IFindResponse = Omit<IEntityExtended, ''>;
|
|
14
|
+
export interface IFindPaginatedRequest extends IFindRequest, IShared.IPaginationRequest {
|
|
15
|
+
}
|
|
16
|
+
export type IFindWithPaginationResponse = IShared.IPaginationResponse<Omit<IEntityExtended, ''>>;
|
|
17
|
+
export interface ICreateForThisDocumentHeaderRequest {
|
|
18
|
+
date: Date;
|
|
19
|
+
debit: number;
|
|
20
|
+
credit: number;
|
|
21
|
+
payment_method_id?: string | null;
|
|
22
|
+
payment_method?: string | null;
|
|
23
|
+
notes: string | null;
|
|
24
|
+
}
|
|
25
|
+
export interface ICreateRequest extends ICreateForThisDocumentHeaderRequest {
|
|
26
|
+
document_header_id: string;
|
|
27
|
+
}
|
|
28
|
+
export interface ICurrentAccountNotes {
|
|
29
|
+
date: string;
|
|
30
|
+
credit: number | null;
|
|
31
|
+
debit: number | null;
|
|
32
|
+
iban: string | null;
|
|
33
|
+
payment_batch_id: string | null;
|
|
34
|
+
payment_method: string | null;
|
|
35
|
+
notes: string | null;
|
|
36
|
+
owner_name: string;
|
|
37
|
+
created_at: string;
|
|
38
|
+
created_by: string;
|
|
39
|
+
updated_at: string;
|
|
40
|
+
updated_by: string;
|
|
41
|
+
}
|
|
42
|
+
export interface IFindCurrentAccountByOwnerIdResponse {
|
|
43
|
+
payment_date: string;
|
|
44
|
+
emission_date: string;
|
|
45
|
+
document_description: string;
|
|
46
|
+
document_name: string;
|
|
47
|
+
debit: number;
|
|
48
|
+
credit: number;
|
|
49
|
+
notes: ICurrentAccountNotes[];
|
|
50
|
+
por_regularizar: number;
|
|
51
|
+
balance: number;
|
|
52
|
+
href?: string | null;
|
|
53
|
+
}
|
|
54
|
+
export interface IUnpaidPurchasesRequest {
|
|
55
|
+
provider_id: string;
|
|
56
|
+
client_id: string | null;
|
|
57
|
+
}
|
|
58
|
+
export interface IUnpaidByDatePurchasesRequest {
|
|
59
|
+
due_date: Date;
|
|
60
|
+
}
|
|
61
|
+
export type IPaymentOrigin = 'CC Fornecedor' | 'CC Cliente' | 'CC Fornecedor (Descontinuado)' | 'CC Cliente (Descontinuado)';
|
|
62
|
+
export interface IUnpaidPurchasesResponse extends Pick<Entity, 'date' | 'debit' | 'credit'> {
|
|
63
|
+
document_header: Pick<DocumentHeader, 'emission_date' | 'pdf_link' | 'id'>;
|
|
64
|
+
origin: IPaymentOrigin;
|
|
65
|
+
document_type_code: string | null;
|
|
66
|
+
document_name: string;
|
|
67
|
+
user?: {
|
|
68
|
+
user_name: string;
|
|
69
|
+
provider_id: string;
|
|
70
|
+
client_id?: string | null;
|
|
71
|
+
};
|
|
72
|
+
maturity_days: number;
|
|
73
|
+
observations: IObservation.IFindByOwnerResponse[];
|
|
74
|
+
}
|
|
75
|
+
export interface IProviderPaymentDocument {
|
|
76
|
+
document_header_id: string;
|
|
77
|
+
value: number;
|
|
78
|
+
discount_value?: number | null;
|
|
79
|
+
}
|
|
80
|
+
export interface IProviderPaymentRequest {
|
|
81
|
+
provider_id: string;
|
|
82
|
+
client_id: string | null;
|
|
83
|
+
documents: IProviderPaymentDocument[];
|
|
84
|
+
total: number;
|
|
85
|
+
}
|
|
86
|
+
export interface IPaymentsNotExportedRequest {
|
|
87
|
+
whiteList?: string[];
|
|
88
|
+
}
|
|
89
|
+
export interface IPaymentsNotExportedResponse {
|
|
90
|
+
iban: string;
|
|
91
|
+
payment_ids: string[];
|
|
92
|
+
npf_dh: {
|
|
93
|
+
id: string;
|
|
94
|
+
name: string;
|
|
95
|
+
pdf_link: string | null;
|
|
96
|
+
total: number;
|
|
97
|
+
}[];
|
|
98
|
+
provider: string;
|
|
99
|
+
value: number;
|
|
100
|
+
}
|
|
101
|
+
export interface IExportPaymentsRequest {
|
|
102
|
+
provider: string;
|
|
103
|
+
value: number;
|
|
104
|
+
npf_ids?: string[];
|
|
105
|
+
}
|
|
106
|
+
export type IBatchType = 'national' | 'international' | 'null';
|
|
107
|
+
export interface IPaymentsBatchNpfDh {
|
|
108
|
+
id: string;
|
|
109
|
+
name: string;
|
|
110
|
+
sent: string | null;
|
|
111
|
+
owner_id: string;
|
|
112
|
+
owner_number: number;
|
|
113
|
+
owner_name: string;
|
|
114
|
+
external_document_header_id: string | null;
|
|
115
|
+
pdf_link: string | null;
|
|
116
|
+
total: number;
|
|
117
|
+
}
|
|
118
|
+
export interface IPaymentsBatchResponse {
|
|
119
|
+
batch_id: string;
|
|
120
|
+
batch_value: number;
|
|
121
|
+
batch_type: IBatchType | null;
|
|
122
|
+
multimedia_id: string | null;
|
|
123
|
+
times_downloaded: number;
|
|
124
|
+
npf_dh: IPaymentsBatchNpfDh[];
|
|
125
|
+
updated_at: Date;
|
|
126
|
+
updated_by: string;
|
|
127
|
+
created_at: Date;
|
|
128
|
+
}
|
|
129
|
+
export declare const IExportCurrentAccountOutputEnum: {
|
|
130
|
+
csv: 'csv';
|
|
131
|
+
pdf: 'pdf';
|
|
132
|
+
};
|
|
133
|
+
export type IExportCurrentAccountOutput = (typeof IExportCurrentAccountOutputEnum)[keyof typeof IExportCurrentAccountOutputEnum];
|
|
134
|
+
export declare const IExportCurrentAccountOutputOptions: string[];
|
|
135
|
+
export interface IExportCurrentAccountRequest {
|
|
136
|
+
token: string;
|
|
137
|
+
owner_id: string;
|
|
138
|
+
output: IExportCurrentAccountOutput;
|
|
139
|
+
start_date: Date | null;
|
|
140
|
+
end_date: Date | null;
|
|
141
|
+
}
|
|
142
|
+
export interface IUnpaidDocumentResponse {
|
|
143
|
+
id: string;
|
|
144
|
+
name: string;
|
|
145
|
+
group: string;
|
|
146
|
+
total: number;
|
|
147
|
+
params: ICreateFromHeaderRequest;
|
|
148
|
+
}
|
|
149
|
+
export interface IRepository {
|
|
150
|
+
findCurrentAccountByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IFindCurrentAccountByOwnerIdResponse[]>;
|
|
151
|
+
findBalanceByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<number>;
|
|
152
|
+
exportCurrentAccount(params: IExportCurrentAccountRequest): Promise<IFindCurrentAccountByOwnerIdResponse[]>;
|
|
153
|
+
findClientUnpaidCredit(params: IShared.IFindByOwnerIdRequest): Promise<IUnpaidDocumentResponse[]>;
|
|
154
|
+
findClientUnpaidDebit(params: IShared.IFindByOwnerIdRequest): Promise<IUnpaidDocumentResponse[]>;
|
|
155
|
+
}
|
|
156
|
+
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
157
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import joi from 'joi';
|
|
2
|
+
import { IPaymentsNotExportedRequest } from './interface';
|
|
3
|
+
export declare const findQuery: joi.ObjectSchema<any>;
|
|
4
|
+
export declare const findWithPaginationQuery: joi.ObjectSchema<any>;
|
|
5
|
+
export declare const findSettledMaterialEntranceQuery: joi.ObjectSchema<any>;
|
|
6
|
+
export declare const providerPaymentBody: joi.ArraySchema<any[]>;
|
|
7
|
+
export declare const exportPaymentsBody: joi.ArraySchema<any[]>;
|
|
8
|
+
export declare const exportCurrentAccountBetweenDatesQuery: joi.ObjectSchema<any>;
|
|
9
|
+
export declare const findSettledMaterialEntranceBuDateParams: joi.ObjectSchema<any>;
|
|
10
|
+
export declare const findPaymentsNotExportedQuery: joi.ObjectSchema<IPaymentsNotExportedRequest>;
|
|
@@ -195,13 +195,6 @@ export interface IGetActionsResponse {
|
|
|
195
195
|
document_number: string;
|
|
196
196
|
}[];
|
|
197
197
|
}
|
|
198
|
-
export interface IUnpaidDocumentResponse {
|
|
199
|
-
id: string;
|
|
200
|
-
name: string;
|
|
201
|
-
group: string;
|
|
202
|
-
total: number;
|
|
203
|
-
params: ICreateFromHeaderRequest;
|
|
204
|
-
}
|
|
205
198
|
export interface ITransferOwnershipRequest {
|
|
206
199
|
document_header_id: string;
|
|
207
200
|
client_id: string;
|
|
@@ -306,31 +299,12 @@ export interface IFindRmOpenDocuments {
|
|
|
306
299
|
designation: string;
|
|
307
300
|
}[];
|
|
308
301
|
}
|
|
309
|
-
export interface IMultipleRegularizationPayments {
|
|
310
|
-
value: number;
|
|
311
|
-
payment_method_id: string;
|
|
312
|
-
payment_method: string;
|
|
313
|
-
}
|
|
314
|
-
export type IMultipleRegularizationPaymentsType = 'credit' | 'debit';
|
|
315
|
-
export interface IMultipleRegularizationDocuments {
|
|
316
|
-
owner_id: string;
|
|
317
|
-
document_header_id: string;
|
|
318
|
-
type: IMultipleRegularizationPaymentsType;
|
|
319
|
-
value: number;
|
|
320
|
-
}
|
|
321
|
-
export interface IMultipleRegularizations {
|
|
322
|
-
documents: IMultipleRegularizationDocuments[];
|
|
323
|
-
payments?: IMultipleRegularizationPayments[];
|
|
324
|
-
}
|
|
325
302
|
export interface IRepository {
|
|
326
303
|
findOne(selector: IShared.IFindByIdRequest): Promise<IFindOneBase | null>;
|
|
327
304
|
findStartVirtual(selector: IShared.IFindByIdRequest): Promise<IStartDocumentHeaderVirtuals | null>;
|
|
328
305
|
findByType(params: IFindByTypeRequest): Promise<IFindByTypeResponse[]>;
|
|
329
306
|
findByBasicSearch(data: IBasicSearchRequest): Promise<IShared.IPaginationResponse<IBasicSearchResponse>>;
|
|
330
307
|
find(params: IFindRequest): Promise<IFindResponse[]>;
|
|
331
|
-
findUnpaidCommissions(params: IShared.IFindByOwnerIdRequest): Promise<IUnpaidDocumentResponse[]>;
|
|
332
|
-
findClientUnpaidCredit(params: IShared.IFindByOwnerIdRequest): Promise<IUnpaidDocumentResponse[]>;
|
|
333
|
-
findClientUnpaidDebit(params: IShared.IFindByOwnerIdRequest): Promise<IUnpaidDocumentResponse[]>;
|
|
334
308
|
getActions(selector: IShared.IFindByIdRequest): Promise<IGetActionsResponse[]>;
|
|
335
309
|
create(data: ICreateRequest): Promise<ICreateResponse>;
|
|
336
310
|
createFromHeader(data: ICreateFromHeaderRequest): Promise<void>;
|
|
@@ -345,6 +319,5 @@ export interface IRepository {
|
|
|
345
319
|
documentList(selector: IShared.IFindByIdRequest, params: IDocumentListRequest): Promise<IDocumentListResponse[]>;
|
|
346
320
|
findStartDocumentHeaderSiblings(params: IShared.IFindByIdRequest): Promise<IFindStartDocumentHeaderSiblingsResponse>;
|
|
347
321
|
findRmOpenDocuments(): Promise<IFindRmOpenDocuments[]>;
|
|
348
|
-
regularizarMultiplosDocumentos(data: IMultipleRegularizations): Promise<void>;
|
|
349
322
|
}
|
|
350
323
|
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
@@ -12,4 +12,3 @@ export declare const sendClientNotificationBody: joi.ObjectSchema<any>;
|
|
|
12
12
|
export declare const findByTypeQuery: joi.ObjectSchema<any>;
|
|
13
13
|
export declare const documentPdfQuery: joi.ObjectSchema<any>;
|
|
14
14
|
export declare const documentLineQuery: joi.ObjectSchema<IShared.IRouteRequest<IDocumentListRequest>>;
|
|
15
|
-
export declare const regularizarMultiplosBody: joi.ObjectSchema<any>;
|
|
@@ -3,7 +3,7 @@ export declare const createBody: joi.ArraySchema<any[]>;
|
|
|
3
3
|
export declare const updateBody: joi.ObjectSchema<any>;
|
|
4
4
|
export declare const updateDataBody: joi.ObjectSchema<any>;
|
|
5
5
|
export declare const updateManyBody: joi.ObjectSchema<any>;
|
|
6
|
-
export declare const updateIndexesBody: joi.ArraySchema<
|
|
7
|
-
export declare const deleteBody: joi.ArraySchema<
|
|
6
|
+
export declare const updateIndexesBody: joi.ArraySchema<string[]>;
|
|
7
|
+
export declare const deleteBody: joi.ArraySchema<string[]>;
|
|
8
8
|
export declare const printLabelParams: joi.ObjectSchema<any>;
|
|
9
9
|
export declare const printLabelQuery: joi.ObjectSchema<any>;
|
|
@@ -6,7 +6,7 @@ export type Entity = Payment;
|
|
|
6
6
|
export declare const Route = "payment";
|
|
7
7
|
export declare const UpperName = "Payment";
|
|
8
8
|
export declare const LowerName: string;
|
|
9
|
-
type IEntityExtended = Entity;
|
|
9
|
+
export type IEntityExtended = Entity;
|
|
10
10
|
export type IFindByIdResponse = Omit<IEntityExtended, ''>;
|
|
11
11
|
export type IFindByOwnerIdResponse = Omit<IEntityExtended, ''>;
|
|
12
12
|
export type IFindRequest = Record<string, unknown>;
|
|
@@ -25,32 +25,6 @@ export interface ICreateForThisDocumentHeaderRequest {
|
|
|
25
25
|
export interface ICreateRequest extends ICreateForThisDocumentHeaderRequest {
|
|
26
26
|
document_header_id: string;
|
|
27
27
|
}
|
|
28
|
-
export interface ICurrentAccountNotes {
|
|
29
|
-
date: string;
|
|
30
|
-
credit: number | null;
|
|
31
|
-
debit: number | null;
|
|
32
|
-
iban: string | null;
|
|
33
|
-
payment_batch_id: string | null;
|
|
34
|
-
payment_method: string | null;
|
|
35
|
-
notes: string | null;
|
|
36
|
-
owner_name: string;
|
|
37
|
-
created_at: string;
|
|
38
|
-
created_by: string;
|
|
39
|
-
updated_at: string;
|
|
40
|
-
updated_by: string;
|
|
41
|
-
}
|
|
42
|
-
export interface IFindCurrentAccountByOwnerIdResponse {
|
|
43
|
-
payment_date: string;
|
|
44
|
-
emission_date: string;
|
|
45
|
-
document_description: string;
|
|
46
|
-
document_name: string;
|
|
47
|
-
debit: number;
|
|
48
|
-
credit: number;
|
|
49
|
-
notes: ICurrentAccountNotes[];
|
|
50
|
-
por_regularizar: number;
|
|
51
|
-
balance: number;
|
|
52
|
-
href?: string | null;
|
|
53
|
-
}
|
|
54
28
|
export interface IUnpaidPurchasesRequest {
|
|
55
29
|
provider_id: string;
|
|
56
30
|
client_id: string | null;
|
|
@@ -72,93 +46,13 @@ export interface IUnpaidPurchasesResponse extends Pick<Entity, 'date' | 'debit'
|
|
|
72
46
|
maturity_days: number;
|
|
73
47
|
observations: IObservation.IFindByOwnerResponse[];
|
|
74
48
|
}
|
|
75
|
-
export interface IProviderPaymentDocument {
|
|
76
|
-
document_header_id: string;
|
|
77
|
-
value: number;
|
|
78
|
-
discount_value?: number | null;
|
|
79
|
-
}
|
|
80
|
-
export interface IProviderPaymentRequest {
|
|
81
|
-
provider_id: string;
|
|
82
|
-
client_id: string | null;
|
|
83
|
-
documents: IProviderPaymentDocument[];
|
|
84
|
-
total: number;
|
|
85
|
-
}
|
|
86
|
-
export interface IPaymentsNotExportedRequest {
|
|
87
|
-
whiteList?: string[];
|
|
88
|
-
}
|
|
89
|
-
export interface IPaymentsNotExportedResponse {
|
|
90
|
-
iban: string;
|
|
91
|
-
payment_ids: string[];
|
|
92
|
-
npf_dh: {
|
|
93
|
-
id: string;
|
|
94
|
-
name: string;
|
|
95
|
-
pdf_link: string | null;
|
|
96
|
-
total: number;
|
|
97
|
-
}[];
|
|
98
|
-
provider: string;
|
|
99
|
-
value: number;
|
|
100
|
-
}
|
|
101
|
-
export interface IExportPaymentsRequest {
|
|
102
|
-
provider: string;
|
|
103
|
-
value: number;
|
|
104
|
-
npf_ids?: string[];
|
|
105
|
-
}
|
|
106
|
-
export type IBatchType = 'national' | 'international' | 'null';
|
|
107
|
-
export interface IPaymentsBatchNpfDh {
|
|
108
|
-
id: string;
|
|
109
|
-
name: string;
|
|
110
|
-
sent: string | null;
|
|
111
|
-
owner_id: string;
|
|
112
|
-
owner_number: number;
|
|
113
|
-
owner_name: string;
|
|
114
|
-
external_document_header_id: string | null;
|
|
115
|
-
pdf_link: string | null;
|
|
116
|
-
total: number;
|
|
117
|
-
}
|
|
118
|
-
export interface IPaymentsBatchResponse {
|
|
119
|
-
batch_id: string;
|
|
120
|
-
batch_value: number;
|
|
121
|
-
batch_type: IBatchType | null;
|
|
122
|
-
multimedia_id: string | null;
|
|
123
|
-
times_downloaded: number;
|
|
124
|
-
npf_dh: IPaymentsBatchNpfDh[];
|
|
125
|
-
updated_at: Date;
|
|
126
|
-
updated_by: string;
|
|
127
|
-
created_at: Date;
|
|
128
|
-
}
|
|
129
|
-
export declare const IExportCurrentAccountOutputEnum: {
|
|
130
|
-
csv: 'csv';
|
|
131
|
-
pdf: 'pdf';
|
|
132
|
-
};
|
|
133
|
-
export type IExportCurrentAccountOutput = (typeof IExportCurrentAccountOutputEnum)[keyof typeof IExportCurrentAccountOutputEnum];
|
|
134
|
-
export declare const IExportCurrentAccountOutputOptions: string[];
|
|
135
|
-
export interface IExportCurrentAccountRequest {
|
|
136
|
-
token: string;
|
|
137
|
-
owner_id: string;
|
|
138
|
-
output: IExportCurrentAccountOutput;
|
|
139
|
-
start_date: Date | null;
|
|
140
|
-
end_date: Date | null;
|
|
141
|
-
}
|
|
142
|
-
export interface IFindCurrentAccountPaginatedRequest extends IShared.IFindByOwnerIdRequest, IShared.IPaginationRequest {
|
|
143
|
-
}
|
|
144
49
|
export interface IRepository {
|
|
145
50
|
findById(selector: IShared.IFindByIdRequest): Promise<IFindByIdResponse | null>;
|
|
146
51
|
findByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IFindByOwnerIdResponse[]>;
|
|
147
52
|
find(selector: IFindRequest): Promise<IFindResponse[]>;
|
|
148
53
|
findPaginated(selector: IFindPaginatedRequest): Promise<IFindWithPaginationResponse>;
|
|
149
|
-
findPaymentsNotExported(params: IPaymentsNotExportedRequest): Promise<IPaymentsNotExportedResponse[]>;
|
|
150
|
-
findPaymentBatches(): Promise<IPaymentsBatchResponse[]>;
|
|
151
|
-
deleteBatch(data: IShared.IFindByIdRequest): Promise<void>;
|
|
152
|
-
findCurrentAccountByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IFindCurrentAccountByOwnerIdResponse[]>;
|
|
153
|
-
findBalanceByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<number>;
|
|
154
54
|
findSettledMaterialEntrance(params: IUnpaidPurchasesRequest): Promise<IUnpaidPurchasesResponse[]>;
|
|
155
|
-
findSettledMaterialEntranceProviders(): Promise<IUser.IFindProvidersWithClientIdResponse[]>;
|
|
156
55
|
findSettledMaterialEntranceByDate(params: IUnpaidByDatePurchasesRequest): Promise<IUnpaidPurchasesResponse[]>;
|
|
157
|
-
|
|
158
|
-
exportPayments(params: IExportPaymentsRequest[]): Promise<void>;
|
|
159
|
-
updateDownloadedBatchNumber(id: IShared.IFindByIdRequest): Promise<void>;
|
|
160
|
-
exportCurrentAccount(params: IExportCurrentAccountRequest): Promise<IFindCurrentAccountByOwnerIdResponse[]>;
|
|
161
|
-
findCurrentAccountPaginated(params: IFindCurrentAccountPaginatedRequest): Promise<IShared.IPaginationResponse<IFindCurrentAccountByOwnerIdResponse>>;
|
|
56
|
+
findSettledMaterialEntranceProviders(): Promise<IUser.IFindProvidersWithClientIdResponse[]>;
|
|
162
57
|
}
|
|
163
58
|
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
164
|
-
export {};
|
|
@@ -1,11 +1,5 @@
|
|
|
1
1
|
import joi from 'joi';
|
|
2
|
-
import { IPaymentsNotExportedRequest } from './interface';
|
|
3
2
|
export declare const findQuery: joi.ObjectSchema<any>;
|
|
4
3
|
export declare const findWithPaginationQuery: joi.ObjectSchema<any>;
|
|
5
4
|
export declare const findSettledMaterialEntranceQuery: joi.ObjectSchema<any>;
|
|
6
|
-
export declare const providerPaymentBody: joi.ArraySchema<any[]>;
|
|
7
|
-
export declare const exportPaymentsBody: joi.ArraySchema<any[]>;
|
|
8
|
-
export declare const exportCurrentAccountBetweenDatesQuery: joi.ObjectSchema<any>;
|
|
9
5
|
export declare const findSettledMaterialEntranceBuDateParams: joi.ObjectSchema<any>;
|
|
10
|
-
export declare const findPaymentsNotExportedQuery: joi.ObjectSchema<IPaymentsNotExportedRequest>;
|
|
11
|
-
export declare const findCurrentAccountWithPaginationQuery: joi.ObjectSchema<any>;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import * as IShared from '../../../shared/interface';
|
|
2
|
+
import { Payment } from '../../../shared/entities/stock';
|
|
3
|
+
export type Entity = Payment;
|
|
4
|
+
export declare const Route = "payment";
|
|
5
|
+
export declare const UpperName = "Payment";
|
|
6
|
+
export declare const LowerName: string;
|
|
7
|
+
export interface IPaymentsNotExportedRequest {
|
|
8
|
+
whiteList?: string[];
|
|
9
|
+
}
|
|
10
|
+
export interface IPaymentsNotExportedResponse {
|
|
11
|
+
iban: string;
|
|
12
|
+
payment_ids: string[];
|
|
13
|
+
npf_dh: {
|
|
14
|
+
id: string;
|
|
15
|
+
name: string;
|
|
16
|
+
pdf_link: string | null;
|
|
17
|
+
total: number;
|
|
18
|
+
}[];
|
|
19
|
+
provider: string;
|
|
20
|
+
value: number;
|
|
21
|
+
}
|
|
22
|
+
export interface IExportPaymentsRequest {
|
|
23
|
+
provider: string;
|
|
24
|
+
value: number;
|
|
25
|
+
npf_ids?: string[];
|
|
26
|
+
}
|
|
27
|
+
export type IBatchType = 'national' | 'international' | 'null';
|
|
28
|
+
export interface IPaymentsBatchNpfDh {
|
|
29
|
+
id: string;
|
|
30
|
+
name: string;
|
|
31
|
+
sent: string | null;
|
|
32
|
+
owner_id: string;
|
|
33
|
+
owner_number: number;
|
|
34
|
+
owner_name: string;
|
|
35
|
+
external_document_header_id: string | null;
|
|
36
|
+
pdf_link: string | null;
|
|
37
|
+
total: number;
|
|
38
|
+
}
|
|
39
|
+
export interface IPaymentsBatchResponse {
|
|
40
|
+
batch_id: string;
|
|
41
|
+
batch_value: number;
|
|
42
|
+
batch_type: IBatchType | null;
|
|
43
|
+
multimedia_id: string | null;
|
|
44
|
+
times_downloaded: number;
|
|
45
|
+
npf_dh: IPaymentsBatchNpfDh[];
|
|
46
|
+
updated_at: Date;
|
|
47
|
+
updated_by: string;
|
|
48
|
+
created_at: Date;
|
|
49
|
+
}
|
|
50
|
+
export interface IRepository {
|
|
51
|
+
findPending(params: IPaymentsNotExportedRequest): Promise<IPaymentsNotExportedResponse[]>;
|
|
52
|
+
create(params: IExportPaymentsRequest[]): Promise<void>;
|
|
53
|
+
findCreated(): Promise<IPaymentsBatchResponse[]>;
|
|
54
|
+
updateDownloadNumber(id: IShared.IFindByIdRequest): Promise<void>;
|
|
55
|
+
deleteOne(data: IShared.IFindByIdRequest): Promise<void>;
|
|
56
|
+
}
|
|
57
|
+
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IConflict } from '../../modules/document/propostaSheets/interface';
|
|
2
2
|
import { IDocumentTypeUserType, IDocumentTypeCodeType } from '../../modules/supply/documentType/interfaces';
|
|
3
|
-
import { IBatchType } from '../../modules/supply/
|
|
3
|
+
import { IBatchType } from '../../modules/supply/paymentBatch/interface';
|
|
4
4
|
import { IProductType } from '../../modules/stock/productGoogleSheets/interface';
|
|
5
5
|
import { IImageType } from '../../modules/stock/productImage/interface';
|
|
6
6
|
import { ITagType } from '../../modules/stock/tag/interface';
|
|
@@ -111,7 +111,12 @@ export declare const findByOwnerIdQueryKeys: IRouteRequest<IFindByOwnerIdRequest
|
|
|
111
111
|
export declare const findByOwnerIdQuery: joi.ObjectSchema<any>;
|
|
112
112
|
export declare const idParam: joi.ObjectSchema<any>;
|
|
113
113
|
export declare const idNumberParam: joi.ObjectSchema<any>;
|
|
114
|
-
export declare const findMinifiedReponse: joi.ArraySchema<
|
|
114
|
+
export declare const findMinifiedReponse: joi.ArraySchema<{
|
|
115
|
+
name: unknown;
|
|
116
|
+
id: unknown;
|
|
117
|
+
group: unknown;
|
|
118
|
+
multimedia_id: unknown;
|
|
119
|
+
}[]>;
|
|
115
120
|
export declare const joiValidateStamps: IRouteResponseWithoutStamps<WithTimestampsOriginID>;
|
|
116
121
|
export declare const IUserSendEmailDocumentTemplateEnum: {
|
|
117
122
|
generic: 'generic';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nomalism-com/types",
|
|
3
3
|
"description": "A nomalism package with all necessary types and validations for developing APIs",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.40.2",
|
|
5
5
|
"author": "Nomalism <it.nomalism@gmail.com> (https://nomalism.com/)",
|
|
6
6
|
"license": "UNLICENSED",
|
|
7
7
|
"type": "module",
|