@inceptionbg/main 1.0.21 → 1.0.22

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.
Files changed (2) hide show
  1. package/dist/index.d.ts +863 -7
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { ISimpleObjectWithCode, ISimpleObject } from '@inceptionbg/iui';
1
+ import { ISimpleObject, ISelectData, ISimpleObjectWithCode } from '@inceptionbg/iui';
2
2
  import { IconDefinition } from '@fortawesome/fontawesome-svg-core';
3
3
  import * as react from 'react';
4
4
  import { FC, ReactNode, Dispatch, SetStateAction, ReactElement } from 'react';
@@ -79,6 +79,838 @@ interface IUserPreferences {
79
79
  }
80
80
  type IGuideType = 'invoice';
81
81
 
82
+ interface IFileSignatory {
83
+ uuid?: string;
84
+ firstName?: string;
85
+ lastName?: string;
86
+ email?: string;
87
+ phoneNumber?: string;
88
+ personalIdentityNumber?: string;
89
+ signatureAppearance?: {
90
+ pageNumber?: string;
91
+ x?: string;
92
+ y?: string;
93
+ width?: string | number;
94
+ height?: string | number;
95
+ };
96
+ }
97
+
98
+ interface IDocumentFile {
99
+ uuid?: string;
100
+ name?: string;
101
+ signedFile?: IFile;
102
+ storedFile?: IFile;
103
+ createdBy?: IUser;
104
+ deleted?: boolean;
105
+ downloaded?: boolean;
106
+ previousVersion?: ISimpleObject;
107
+ externalSource?: boolean;
108
+ orderNumber?: string | number;
109
+ requiredSignature?: boolean;
110
+ confidentialDocument?: boolean;
111
+ signatories?: IFileSignatory[];
112
+ fileType?: IFileType;
113
+ locked?: boolean;
114
+ }
115
+ interface IFile {
116
+ uuid?: string;
117
+ originalFileName?: string;
118
+ downloadUrl?: string;
119
+ lengthInBytes?: number;
120
+ uploadedAt?: string;
121
+ fileUuid?: string;
122
+ storage?: {
123
+ url?: string;
124
+ };
125
+ }
126
+ interface IFileType {
127
+ uuid?: string;
128
+ name?: string;
129
+ organization?: IOrganization;
130
+ requireSignature?: boolean;
131
+ }
132
+
133
+ interface IIndexDataCodebook {
134
+ uuid: string;
135
+ name: string;
136
+ description: string;
137
+ active?: boolean;
138
+ organization?: {
139
+ uuid: string;
140
+ };
141
+ }
142
+ interface IIndexDataCodebookItem {
143
+ code: string;
144
+ name: string;
145
+ uuid: string;
146
+ active: boolean;
147
+ }
148
+
149
+ interface IIndexData {
150
+ uuid?: string;
151
+ name?: string;
152
+ fieldType?: IndexDataFieldType;
153
+ fieldTypeObj?: ISelectData;
154
+ codebook?: Partial<IIndexDataCodebook>;
155
+ codebookObj?: ISelectData;
156
+ documentType?: IDocumentType;
157
+ deletionTime?: string;
158
+ required?: boolean;
159
+ readonly?: boolean;
160
+ organization?: IOrganization;
161
+ minLength?: number;
162
+ maxLength?: number;
163
+ indexOrder?: number;
164
+ code?: string;
165
+ }
166
+ interface IIndex {
167
+ uuid?: string;
168
+ value?: string;
169
+ name?: string;
170
+ position?: IIndexDataPosition;
171
+ indexData?: IIndexData;
172
+ indexOrder?: string;
173
+ defaultCodebookItem?: Partial<IIndexDataCodebookItem>;
174
+ }
175
+ declare const IndexDataFieldTypes: readonly ["TEXT", "DATE", "CODEBOOK", "NUMERIC", "DECIMAL", "LONG_TEXT"];
176
+ type IndexDataFieldType = (typeof IndexDataFieldTypes)[number];
177
+ declare const IndexDataPositions: readonly ["COST_CENTER", "CONTRACT", "CASE", "DOCUMENT", "LEGAL_ENTITY"];
178
+ type IIndexDataPosition = (typeof IndexDataPositions)[number];
179
+ interface IIndicesIndex {
180
+ uuid?: string;
181
+ indexDataPosition?: IIndex;
182
+ value?: string;
183
+ codebookItem?: {
184
+ uuid: string;
185
+ };
186
+ }
187
+
188
+ interface IJob {
189
+ uuid?: string;
190
+ name?: string;
191
+ code?: string;
192
+ organization?: IOrganization;
193
+ }
194
+
195
+ interface IEmployee {
196
+ uuid: string;
197
+ firstName?: string;
198
+ lastName?: string;
199
+ personalIdentityNumber?: string;
200
+ evidenceNumber?: string;
201
+ email?: string;
202
+ user?: IUser;
203
+ emailNotifications?: boolean;
204
+ deleted?: boolean;
205
+ job?: IJob;
206
+ orun?: IOrganizationalUnit;
207
+ representation?: string;
208
+ costCenter?: ISimpleObjectWithCode;
209
+ }
210
+
211
+ interface IApproval {
212
+ uuid?: string;
213
+ name?: string;
214
+ description?: string;
215
+ active?: boolean;
216
+ returnResponseToSef?: boolean;
217
+ orun?: IOrganizationalUnitUpdate;
218
+ organization?: IOrganization;
219
+ automaticallyStart?: IApproval;
220
+ automaticallyStartApprovals?: IApproval[];
221
+ automaticallyStartApprovalsData?: ISelectData[];
222
+ generateDocumentApprovalReport?: boolean;
223
+ startApprovalByConditionsOnApprovalEnd?: boolean;
224
+ issueDateChange?: boolean;
225
+ }
226
+ declare const Constraints: readonly ["TAX_ALLOCATION_NOT_EMPTY", "TAX_ALLOCATION_BALANCE", "COST_CENTER_EXPENSES_NOT_EMPTY", "ACCOUNTS_NOT_EMPTY", "ACCOUNTS_BALANCE", "ORGANIZATIONAL_UNIT_NOT_EMPTY", "PAYMENT_NOT_EMPTY", "SUGGESTED_PAYMENT_ORDER_NOT_EMPTY", "INDEX_DATA", "ACCOUNTS_SUM_LESS_THAN_INVOICE_TOTAL_PRICE", "VAT_EVIDENCE_TYPE_NOT_EMPTY", "PAYMENT_PLANNED_DATE_NOT_EMPTY"];
227
+ type IConstraint = (typeof Constraints)[number];
228
+ interface IApprovalStep {
229
+ uuid: string;
230
+ name?: string;
231
+ description?: string;
232
+ deadline?: number;
233
+ requiredVotes?: number;
234
+ ordinalNumber?: number;
235
+ approval?: IApproval;
236
+ employees?: IEmployee[];
237
+ step?: IApprovalStep;
238
+ conditionedStep?: IApprovalStep;
239
+ job?: IJob;
240
+ activationTime?: string;
241
+ documentHold?: boolean;
242
+ costCenter?: ISimpleObjectWithCode;
243
+ group?: IPhaseGroup;
244
+ lastStep?: boolean;
245
+ constraints?: IConstraint[];
246
+ indexDataConstraints?: IIndexData[];
247
+ }
248
+ interface ILatestApprovalProcess {
249
+ uuid?: string;
250
+ createdAt?: string;
251
+ status?: string;
252
+ latestStep?: IDocumentApprovalStep;
253
+ }
254
+ type ApprovalStatus = 'APPROVED' | 'DECLINED';
255
+ interface IDocumentApproval {
256
+ uuid?: string;
257
+ document?: IDocumentAny;
258
+ approval?: IApproval;
259
+ steps?: IDocumentApprovalStep[];
260
+ status?: ApprovalStatus;
261
+ directlyProcessCompletionUser?: IUser;
262
+ }
263
+ interface IDocumentApprovalStep {
264
+ uuid?: string;
265
+ activationTime?: string;
266
+ deadline?: string;
267
+ requiredVotes?: number;
268
+ positiveVotes?: number;
269
+ stepStatus?: ApprovalStatus;
270
+ step?: IApprovalStep;
271
+ votes?: IDocumentApprovalVote[];
272
+ documentApproval?: IDocumentApproval;
273
+ notReadyToVoteReason?: 'COST_EXPENSE_ALLOCATION' | 'INVOICE_TAX_ALLOCATION' | 'INVOICE_ACCOUNT' | 'INDEX_DATA';
274
+ customName?: string;
275
+ additionalAddingTime?: string;
276
+ }
277
+ interface IDocumentApprovalVote {
278
+ uuid: string;
279
+ document: IDocumentAny;
280
+ step: IDocumentApprovalStep;
281
+ employee: IEmployee;
282
+ vote?: ApprovalStatus;
283
+ voteTime?: string;
284
+ votedFiles?: ISimpleObject[];
285
+ note?: string;
286
+ returnedStep?: boolean;
287
+ adHocVote?: boolean;
288
+ }
289
+ interface IPhaseGroup {
290
+ uuid?: string;
291
+ name?: string;
292
+ organization?: IOrganization;
293
+ items?: {
294
+ invoices: IInvoice[];
295
+ isOpen: boolean;
296
+ };
297
+ internalCode?: 'PIO_RECEIPT_AND_SCANNING_DOCUMENT' | 'PIO_DETERMINING_LEGAL_BASIS_AND_COMPLETING_DOCUMENTATION' | 'PIO_DOCUMENTATION_CORRECTNESS_CHECK' | 'PIO_SUPPLIER_OBLIGATION_RECORDING' | 'PIO_PAYMENT_APPROVAL' | 'PIO_PAYMENT_READY' | 'PIO_PAYMENT_DONE' | 'PIO_DOCUMENTATION_VERIFICATION';
298
+ }
299
+
300
+ interface IShipment extends IDocument {
301
+ conversationView?: {
302
+ uuid: string;
303
+ };
304
+ receiver?: IPartner;
305
+ issuer?: IPartner;
306
+ receiverOrganization?: {
307
+ uuid: string;
308
+ };
309
+ shipmentUnregisteredReceiver?: {
310
+ firstName?: string;
311
+ lastName?: string;
312
+ email: string;
313
+ inboxUrl?: string;
314
+ personalIdentityNumber?: string;
315
+ phoneNumber?: string;
316
+ };
317
+ messageSubject?: string;
318
+ messageBody?: string;
319
+ generateManualShipmentFiles?: boolean;
320
+ internalReceiver?: IEmployee;
321
+ }
322
+
323
+ interface IDocumentSend {
324
+ uuid?: string;
325
+ contactPerson?: IContactPerson;
326
+ createdAt?: string;
327
+ body?: string;
328
+ latestStatus?: ISendStatus;
329
+ requireConsent?: boolean;
330
+ consentDeadlineTime?: string;
331
+ requireDeliveryReceipt?: boolean;
332
+ requireFileSignature?: boolean;
333
+ requireDownloadBeforeConsent?: boolean;
334
+ qualifiedDelivery?: boolean;
335
+ accessHash?: string;
336
+ receiverName?: string;
337
+ email?: string;
338
+ document?: IShipment;
339
+ createdBy?: IUser;
340
+ organization?: IOrganization;
341
+ files?: IDocumentFile[];
342
+ description?: string;
343
+ sendFinal?: boolean;
344
+ relatedDocuments?: IDocumentAny[];
345
+ totalPrice?: number;
346
+ discount?: number;
347
+ deletionTime?: string;
348
+ sefComment?: string;
349
+ inBehalfOf?: {
350
+ email: string;
351
+ };
352
+ }
353
+ declare const SendStatuses: readonly ["QUEUED", "SENDING", "NOT_REGISTERED_ON_SEF", "ERROR", "SENT", "SEEN", "DOWNLOADED", "APPROVED", "REJECTED", "UNRESOLVED", "MISTAKE", "CANCELLED", "STORNO", "RENOTIFIED"];
354
+ type ISendStatus = (typeof SendStatuses)[number];
355
+
356
+ interface IProduct {
357
+ uuid: string;
358
+ code?: string;
359
+ name?: string;
360
+ priceWithoutVat?: number | string;
361
+ vatPercentage?: number;
362
+ serialNumber?: string;
363
+ manufacturer?: string;
364
+ taxCategory?: string;
365
+ barcode?: string;
366
+ taxExemptionNote?: ITaxExemptionNote;
367
+ unitOfMeasure?: ISimpleObject;
368
+ bankingService?: boolean;
369
+ }
370
+
371
+ interface IVatIndicator {
372
+ uuid: string;
373
+ code: string;
374
+ name: string;
375
+ vatPercentage: number;
376
+ calculateVatAmount?: boolean;
377
+ internalVatCalculation?: boolean;
378
+ organization?: IOrganization;
379
+ }
380
+
381
+ interface ITaxAllocation {
382
+ uuid: string;
383
+ vatIndicator: IVatIndicator;
384
+ lowerVatTaxBase?: number;
385
+ higherVatTaxBase?: number;
386
+ lowerVatTaxAmount?: number;
387
+ higherVatTaxAmount?: number;
388
+ totalAmountWithoutVat?: number;
389
+ totalVatAmount?: number;
390
+ totalAmountWithVat?: number;
391
+ taxExcemptionAmount?: number;
392
+ nonVatPayerAmount?: number;
393
+ participateInPdfReport?: boolean;
394
+ orderNumber?: string;
395
+ }
396
+ interface ITaxRecapitulation {
397
+ priceWithoutVat: number;
398
+ priceWithVat: number;
399
+ vatAmount: number;
400
+ vatPercentage: number;
401
+ }
402
+
403
+ interface IAccount {
404
+ uuid?: string;
405
+ name?: string;
406
+ code?: string;
407
+ deleted?: boolean;
408
+ organization?: IOrganization;
409
+ }
410
+
411
+ interface IPayment {
412
+ uuid?: string;
413
+ amountWithoutVat?: number | string;
414
+ description?: string;
415
+ invoice?: IDocument;
416
+ paymentAmount?: number | string;
417
+ paymentDate?: string;
418
+ vatAmount?: number | string;
419
+ vatPercentage?: number | string;
420
+ organization?: IOrganization;
421
+ orderNumber?: string;
422
+ account?: IAccount;
423
+ }
424
+
425
+ interface IContractNew {
426
+ uuid?: string;
427
+ contractor?: IPartner;
428
+ contractors?: IPartner[];
429
+ partnerContractNumber?: string;
430
+ type?: ContractType;
431
+ contractNumber?: string;
432
+ conclusionDate?: string;
433
+ expirationDate?: string;
434
+ periodFrom?: string;
435
+ periodTo?: string;
436
+ subject?: string;
437
+ note?: string;
438
+ active?: boolean;
439
+ organization?: IOrganization;
440
+ manager?: IEmployee;
441
+ amountWithVat?: number;
442
+ amountWithoutVat?: number;
443
+ warningAmountWithVat?: number;
444
+ warningAmountWithoutVat?: number;
445
+ currency?: ICurrency;
446
+ exchangeRate?: number;
447
+ warningDate?: string;
448
+ deactivationDate?: string;
449
+ deactivationNote?: string;
450
+ utilization?: IContractUtilization;
451
+ paymentUtilization?: IContractUtilization;
452
+ frameworkAgreementUtilization?: IContractUtilization;
453
+ bestPaidBefore?: number;
454
+ deliveryTime?: number;
455
+ complaintDeadline?: number;
456
+ warrantyPeriod?: number;
457
+ discount?: number;
458
+ account?: IAccount;
459
+ organizationalUnit?: IOrganizationalUnitUpdate;
460
+ amountWarningPercentage?: number;
461
+ foreignAmountWithVat?: number;
462
+ foreignAmountWithoutVat?: number;
463
+ warningForeignAmountWithVat?: number;
464
+ warningForeignAmountWithoutVat?: number;
465
+ lastAnnex?: IAnnex;
466
+ annexes?: IAnnex[];
467
+ frameworkAgreement?: IContract;
468
+ group?: 'CONTRACT' | 'FRAMEWORK_AGREEMENT';
469
+ estimatedValueWithVat?: number;
470
+ estimatedValueWithoutVat?: number;
471
+ jointOffer?: boolean;
472
+ subContractor?: boolean;
473
+ procurementCaseType?: IProcurementCaseType;
474
+ publicProcurementLaw?: boolean;
475
+ publicProcurementLawObj?: ISimpleObject;
476
+ procurementLawReferenceNUmber?: string;
477
+ procurementLawReason?: string;
478
+ reservedAmountWithoutVat?: string;
479
+ reservedAmountWithVat?: string;
480
+ foreignExchange?: boolean;
481
+ procurementOrdinalNumber?: string;
482
+ providingServicesDeadline?: ServiceCostCenter;
483
+ providingServicesCostCenter?: ISimpleObjectWithCode;
484
+ commissionMembers?: IEmployee[];
485
+ contractType?: IContractType;
486
+ contractIndices?: IIndicesIndex[];
487
+ indicesData?: IIndicesIndex[];
488
+ }
489
+ interface IContract extends IContractNew {
490
+ uuid: string;
491
+ }
492
+ type ContractFieldOption = 'EXPIRATION_DATE' | 'SUBJECT' | 'BEST_PAID_BEFORE' | 'DELIVERY_TIME' | 'COMPLAINT_DEADLINE' | 'WARRANTY_PERIOD' | 'AMOUNT_WITH_VAT' | 'AMOUNT_WITHOUT_VAT' | 'DISCOUNT' | 'CONTRACTOR';
493
+ declare const ContractTypes: readonly ["INCOME", "OUTCOME"];
494
+ type ContractType = (typeof ContractTypes)[number];
495
+ interface IAnnex {
496
+ uuid?: string;
497
+ annexNumber: string;
498
+ changes: IAnnexChange[];
499
+ contract: IContract;
500
+ date: string;
501
+ partnerAnnexNumber: string;
502
+ }
503
+ interface IAnnexChange {
504
+ field?: ContractFieldOption;
505
+ newValue?: string | number;
506
+ oldValue?: string | number;
507
+ representation?: string;
508
+ }
509
+ interface IContractUtilization {
510
+ utilizationWithVat?: number;
511
+ utilizationWithoutVat?: number;
512
+ remainingAmountWithVat?: number;
513
+ remainingAmountWithoutVat?: number;
514
+ utilizationPercentage?: number;
515
+ }
516
+ interface IContractUtilization {
517
+ uuid: string;
518
+ contractNumber: string;
519
+ amountWithVat?: number;
520
+ amountWithoutVat?: number;
521
+ contractorName: string;
522
+ contractUtilizationThisYear: IContractUtilizationByYear;
523
+ contractUtilizationLastYear: IContractUtilizationByYear;
524
+ }
525
+ interface IContractUtilizationByYear {
526
+ utilizationWithVat?: number;
527
+ utilizationWithoutVat?: number;
528
+ year: number;
529
+ }
530
+ interface IProcurementCaseType {
531
+ uuid?: string;
532
+ name?: string;
533
+ organization?: IOrganization;
534
+ }
535
+ declare const ServiceCostCenters: readonly ["SUCCESSIVELY", "COMPLETELY"];
536
+ type ServiceCostCenter = (typeof ServiceCostCenters)[number];
537
+ interface IContractType {
538
+ uuid?: string;
539
+ name?: string;
540
+ organization?: IOrganization;
541
+ }
542
+
543
+ interface ICase {
544
+ uuid: string;
545
+ number: string;
546
+ thirdPartyOrganization?: IOrganization;
547
+ deletable?: boolean;
548
+ name?: string;
549
+ caseType?: IDocumentType;
550
+ organization?: IOrganization;
551
+ caseIndices?: IDocumentIndex[];
552
+ indicesData?: IDocumentIndex[];
553
+ latestStatus?: {
554
+ uuid: string;
555
+ name: string;
556
+ order: number;
557
+ };
558
+ createdAt?: string;
559
+ evidenceNumber?: string;
560
+ assigned?: IEmployee;
561
+ notSeenShipments?: boolean;
562
+ seen?: boolean;
563
+ }
564
+
565
+ interface IExpenseAllocation {
566
+ uuid: string;
567
+ document: {
568
+ uuid: string;
569
+ };
570
+ costCenter: {
571
+ uuid: string;
572
+ code: string;
573
+ name: string;
574
+ };
575
+ expenseAmount: string;
576
+ orderNumber?: string;
577
+ note?: string;
578
+ account?: IAccount;
579
+ costCenterExpenseAllocationIndexes?: ICostCenterExpenseAllocationIndex[];
580
+ }
581
+ interface ICostCenterExpenseAllocationIndex {
582
+ uuid?: string;
583
+ indexDataPosition?: IIndex;
584
+ value?: string;
585
+ codebookItem?: {
586
+ uuid: string;
587
+ code?: string;
588
+ name?: string;
589
+ active?: boolean;
590
+ };
591
+ }
592
+
593
+ interface IInvoice extends IDocument {
594
+ name?: string;
595
+ trafficDate?: string;
596
+ bestPaidBefore?: string;
597
+ plannedPaymentDate?: string;
598
+ orun?: IOrganizationalUnitUpdate;
599
+ description?: string;
600
+ issuer?: IPartner;
601
+ receiver?: IPartner;
602
+ contract?: IContract;
603
+ annex?: IAnnex;
604
+ contractNumberText?: string;
605
+ contractRepresentation?: string;
606
+ issueDate?: string;
607
+ copyItemsFrom?: IDocument;
608
+ totalPriceWithoutVat?: number;
609
+ totalPriceWithVat?: number;
610
+ roundingAmount?: number | string;
611
+ sefStatus?: ISendStatus;
612
+ sefStatusComment?: string;
613
+ advancePaymentSum?: {
614
+ totalPriceWithVat?: number;
615
+ totalPriceWithoutVat?: number;
616
+ latestSefSend?: IDocumentSend;
617
+ generateInvoicePdf?: boolean;
618
+ creditNoteInvoices?: ICreditNoteInvoice[];
619
+ periodFrom?: string;
620
+ periodTo?: string;
621
+ purchaseOrderReference?: string;
622
+ frameworkAgreementNumber?: string;
623
+ objectCode?: string;
624
+ internalRoutingNumber?: string;
625
+ tenderReference?: string;
626
+ contractNumberSef?: string;
627
+ invoiceTaxCategories?: IInvoiceTaxCategory[];
628
+ referenceCreditNumber?: string;
629
+ referenceDebitNumber?: string;
630
+ taxLiabilityDate?: TaxLiabilityDate;
631
+ issuerBankAccount?: Partial<IBankAccount>;
632
+ receiverBankAccount?: Partial<IBankAccount>;
633
+ purposePayment?: string;
634
+ sourceOfFinance?: Partial<ISimpleObjectWithCode>;
635
+ paymentCode?: Partial<ISimpleObjectWithCode>;
636
+ approvalStepGroup?: {
637
+ name: string;
638
+ uuid: string;
639
+ };
640
+ sefApprovalUser?: IUser;
641
+ sefApprovalTime?: string;
642
+ payments?: IPayment[];
643
+ frameworkAgreement?: IContract;
644
+ sendToCir?: ISendToCir;
645
+ sefStatusChangeTime?: string;
646
+ usedInFactoring?: boolean;
647
+ numberNonSTaxCategories?: number;
648
+ currency?: ICurrency;
649
+ exchangeRate?: string;
650
+ costCenterExpenseAllocations?: IExpenseAllocation[];
651
+ taxAllocations?: ITaxAllocation[];
652
+ taxRecapitulationItems?: ITaxRecapitulation[];
653
+ items?: IInvoiceItem[];
654
+ contractDate?: string;
655
+ sefVerificationDeadlineTime?: string;
656
+ sefVerificationDeadlineTimeExpired?: boolean;
657
+ };
658
+ foreignCurrency?: boolean;
659
+ forceNoteSefSend?: boolean;
660
+ evidenceDate?: string;
661
+ registerOrdinalNumber?: number;
662
+ documentIndices?: IDocumentIndex[];
663
+ latestApprovalProcess?: ILatestApprovalProcess;
664
+ latestApprovalStatus?: LatestApprovalStatus;
665
+ latestSend?: IDocumentSend;
666
+ hold?: {
667
+ user: IUser;
668
+ startTime: string;
669
+ endTime?: string;
670
+ };
671
+ evidenceNumber?: string;
672
+ documentWatch?: boolean;
673
+ cases?: ICase[];
674
+ }
675
+ declare const TaxCategoriesFull: readonly ["S", ...string[]];
676
+ type ITaxCategory = (typeof TaxCategoriesFull)[number];
677
+ interface IInvoiceItemNew {
678
+ uuid?: string;
679
+ name?: string;
680
+ unitOfMeasure?: ISimpleObject;
681
+ quantity?: number | string;
682
+ vatPercentage?: VatPercentage;
683
+ product?: IProduct;
684
+ orderNumber?: string | number;
685
+ taxCategory?: ITaxCategory;
686
+ allowancePercentage?: number | string;
687
+ allowanceAmount?: number | string;
688
+ unitPriceWithoutVat?: number | string;
689
+ totalPriceWithoutVat?: number;
690
+ totalPriceWithVat?: number | string;
691
+ allowanceAmountInCurrency?: number | string;
692
+ unitPriceWithoutVatInCurrency?: number | string;
693
+ totalPriceWithoutVatInCurrency?: number;
694
+ totalPriceWithVatInCurrency?: number | string;
695
+ }
696
+ interface IInvoiceItem extends IInvoiceItemNew {
697
+ uuid: string;
698
+ name: string;
699
+ unitOfMeasure?: ISimpleObject;
700
+ quantity: number;
701
+ unitPriceWithoutVat: number | string;
702
+ totalPriceWithoutVat: number;
703
+ totalPriceWithVat: number | string;
704
+ vatPercentage: VatPercentage;
705
+ product?: IProduct;
706
+ taxCategory: ITaxCategory;
707
+ allowancePercentage?: number | string;
708
+ allowanceAmount?: number | string;
709
+ }
710
+ declare const VatPercentages: readonly [20, 10, 8, 0];
711
+ type VatPercentage = (typeof VatPercentages)[number];
712
+ interface ITaxExemptionNote {
713
+ uuid?: string;
714
+ name?: string;
715
+ code?: string;
716
+ taxCategory?: string;
717
+ decisionNumberRequired?: boolean;
718
+ }
719
+ interface IInvoiceTaxCategoryNew {
720
+ uuid?: string;
721
+ taxCategory?: ITaxCategory;
722
+ taxExemptionNote?: ITaxExemptionNote;
723
+ decisionNumber?: string;
724
+ }
725
+ interface IInvoiceTaxCategory extends IInvoiceTaxCategoryNew {
726
+ uuid: string;
727
+ taxCategory: ITaxCategory;
728
+ }
729
+ declare const TaxLiabilityDates: readonly ["TRAFFIC_DATE", "PAYMENT_DATE", "ISSUE_DATE"];
730
+ type TaxLiabilityDate = (typeof TaxLiabilityDates)[number];
731
+
732
+ interface IEmailDocumentSaved {
733
+ uuid?: string;
734
+ document?: IDocument;
735
+ emailAccount?: IEmailCredential;
736
+ electronicReturnReceiptTime?: string;
737
+ documentFiles?: IDocumentFile[];
738
+ }
739
+ interface IEmailCredential {
740
+ uuid?: string;
741
+ username?: string;
742
+ password?: string;
743
+ imapHost?: string;
744
+ imapPort?: number;
745
+ organization?: IOrganization;
746
+ usersWithAccess?: IUser[];
747
+ createdBy?: IUser;
748
+ }
749
+
750
+ interface IOfficeDocument extends IDocument {
751
+ documentSource?: IEmailDocumentSaved;
752
+ documentSourceType?: IDocumentSourceType;
753
+ emailDocument?: IEmailDocumentSaved;
754
+ caseNumber?: string;
755
+ canCreateSubOrdinalNumber?: boolean;
756
+ evidenceDate?: string;
757
+ registerOrdinalNumber?: number;
758
+ documentIndices?: IDocumentIndex[];
759
+ latestApprovalProcess?: ILatestApprovalProcess;
760
+ latestApprovalStatus?: LatestApprovalStatus;
761
+ latestSend?: IDocumentSend;
762
+ hold?: {
763
+ user: IUser;
764
+ startTime: string;
765
+ endTime?: string;
766
+ };
767
+ evidenceNumber?: string;
768
+ documentWatch?: boolean;
769
+ cases?: ICase[];
770
+ }
771
+
772
+ interface IDocument {
773
+ uuid: string;
774
+ documentNumber?: string;
775
+ documentType?: IDocumentType;
776
+ files?: IDocumentFile[];
777
+ date?: string;
778
+ note?: string;
779
+ createdAt?: string;
780
+ createdBy?: IUser;
781
+ concluded?: boolean;
782
+ organization?: {
783
+ uuid: string;
784
+ };
785
+ }
786
+ interface IDocumentAny extends Partial<IInvoice>, Partial<IShipment>, Partial<IOfficeDocument> {
787
+ }
788
+ type IDocumentCategory = 'DOCUMENT' | 'INVOICE' | 'ARCHIVE' | 'SHIPMENT';
789
+ interface IDocumentSearch {
790
+ documentNumber?: string;
791
+ category?: IDocumentCategory;
792
+ documentTypeUuid?: string;
793
+ dateTo?: string;
794
+ dateFrom?: string;
795
+ createdFrom?: string;
796
+ createdTo?: string;
797
+ bestPaidBeforeFrom?: string;
798
+ bestPaidBeforeTo?: string;
799
+ trafficDateFrom?: string;
800
+ trafficDateTo?: string;
801
+ evidenceDateFrom?: string;
802
+ evidenceDateTo?: string;
803
+ paymentDateFrom?: string;
804
+ paymentDateTo?: string;
805
+ issueDateFrom?: string;
806
+ issueDateTo?: string;
807
+ nameLike?: string;
808
+ issuerUuid?: string;
809
+ receiverUuid?: string;
810
+ issuerOrReceiverUuid?: string;
811
+ contractUuid?: string;
812
+ documentNumberLike?: string;
813
+ excludeDocumentUuid?: string;
814
+ invoice?: boolean;
815
+ income?: boolean;
816
+ archived?: boolean;
817
+ documentApprovalStatus?: string;
818
+ sefSendStatus?: ISendStatus;
819
+ receiver?: ISimpleObject;
820
+ issuer?: ISimpleObject;
821
+ documentType?: ISimpleObject;
822
+ sort?: string;
823
+ plannedPaymentDateTo?: string;
824
+ plannedPaymentDateFrom?: string;
825
+ latestDocumentSendStatus?: ISendStatus;
826
+ documentSent?: boolean;
827
+ onHold?: boolean;
828
+ onHoldByUserUuid?: string;
829
+ sefDeadlineDaysFrom?: string;
830
+ sefDeadlineDaysTo?: string;
831
+ approvalProcessEndTimeFrom?: string;
832
+ approvalProcessEndTimeTo?: string;
833
+ documentYearMonth?: string;
834
+ orunUuids?: string[];
835
+ oruns?: IOrganizationalUnit[];
836
+ approvals?: ISimpleObject[];
837
+ approvalUuids?: string[];
838
+ internalReceiverNotBlank?: boolean;
839
+ approvalStepGroupUuid?: string;
840
+ contractNumber?: string;
841
+ contractNumberSef?: string;
842
+ costCenters?: ISimpleObjectWithCode;
843
+ costCentersUuid?: string;
844
+ sefStatus?: ISendStatus;
845
+ sefStatuses?: ISendStatus[];
846
+ excludeSefStatuses?: ISendStatus[];
847
+ sefStatusCommentLike?: string;
848
+ signal?: any;
849
+ pioInternalCodeBookReportCustomFilter?: boolean;
850
+ sefInvoice?: boolean;
851
+ sefInvoiceType?: ISefInvoiceType;
852
+ register?: ISimpleObject;
853
+ registerUuid?: string;
854
+ internalRoutingNumberLike?: string;
855
+ year?: number;
856
+ factoring?: boolean;
857
+ taxCategory?: ITaxCategory;
858
+ currency?: ISimpleObject;
859
+ currencyUuid?: string;
860
+ domesticCurrency?: boolean;
861
+ foreignCurrency?: boolean;
862
+ totalPriceWithVatInCurrency?: number;
863
+ createdDateFrom?: string;
864
+ createdDateTo?: string;
865
+ vatPercentage?: string;
866
+ }
867
+ declare const SefVatEvidenceTypes: readonly ["INVOICE", "CREDIT_NOTE", "DEBIT_NOTE", "PREPAYMENT_INVOICE", "INTERNAL_ACCOUNT_FOR_TURNOVER_OF_FOREIGNER", "OTHER_INTERNAL_STATEMENT"];
868
+ type SefVatEvidenceType = (typeof SefVatEvidenceTypes)[number];
869
+ interface IDocumentType {
870
+ uuid?: string;
871
+ name?: string;
872
+ printName?: string;
873
+ invoice?: boolean;
874
+ income?: boolean;
875
+ fields?: DocumentField[];
876
+ organization?: IOrganization;
877
+ participateInContractRealization?: boolean;
878
+ participateInContractPaymentRealization?: boolean;
879
+ sort?: number;
880
+ sefInvoiceType?: ISefInvoiceType;
881
+ shipment?: boolean;
882
+ category?: 'DOCUMENT' | 'CASE';
883
+ internalCode?: string;
884
+ caseNumberRequired?: boolean;
885
+ retentionPeriod?: string;
886
+ code?: string;
887
+ sefVatEvidenceType?: SefVatEvidenceType;
888
+ }
889
+ type ISefInvoiceType = 'COMMERCIAL_INVOICE' | 'CREDIT_NOTE' | 'DEBIT_NOTE' | 'PREPAYMENT_INVOICE';
890
+ declare const SendToCirValues: readonly ["YES", "NO"];
891
+ type ISendToCir = (typeof SendToCirValues)[number];
892
+ interface ICreditNoteInvoice {
893
+ uuid?: string;
894
+ creditNote?: IDocument;
895
+ invoice?: IDocument;
896
+ invoiceNumber?: string;
897
+ invoiceIssueDate?: string;
898
+ }
899
+ declare const LatestApprovalStatuses: readonly ["IN_PROGRESS", "DECLINED", "APPROVED", "NOT_STARTED"];
900
+ type LatestApprovalStatus = (typeof LatestApprovalStatuses)[number];
901
+ type IDocumentSourceType = 'EMAIL' | 'INTERNAL_SEND' | 'MANUAL_INPUT';
902
+ interface IDocumentIndex {
903
+ uuid?: string;
904
+ index?: IIndexData;
905
+ indexDataPosition?: IIndex;
906
+ value?: string;
907
+ codebookItem?: {
908
+ uuid: string;
909
+ };
910
+ }
911
+ declare const DocumentFields: readonly ["TRAFFIC_DATE", "BEST_PAID_BEFORE", "CONTRACT", "DOCUMENT_NUMBER", "NOTE", "ORUN", "INVOICE_ITEM_CODE", "INVOICE_ITEM_UNIT_OF_MEASURE", "INVOICE_ITEM_QUANTITY", "INVOICE_ITEM_UNIT_PRICE_WITHOUT_VAT", "INVOICE_ITEM_TOTAL_PRICE_WITHOUT_VAT", "INVOICE_ITEM_TOTAL_PRICE_WITH_VAT", "INVOICE_ITEM_VAT_PERCENTAGE", "TOTAL_PRICES", "PLANNED_PAYMENT_DATE", "ALLOWANCE_PERCENTAGE", "ALLOWANCE"];
912
+ type DocumentField = (typeof DocumentFields)[number];
913
+
82
914
  interface IPartner {
83
915
  uuid: string;
84
916
  name: string;
@@ -99,8 +931,7 @@ interface IPartner {
99
931
  email?: string;
100
932
  website?: string;
101
933
  phoneNumber?: string;
102
- group?: IGroup;
103
- groups?: IGroup[];
934
+ groups?: IPartnerGroup[];
104
935
  organization?: IOrganization;
105
936
  updateMissingData?: boolean;
106
937
  personalIdentificationNumber?: string;
@@ -115,6 +946,8 @@ interface IPartner {
115
946
  checkAuthorizedPersonsOnApr?: boolean;
116
947
  internalSend?: boolean;
117
948
  sefSend?: boolean;
949
+ legalEntityIndices?: IDocumentIndex[];
950
+ legal_entityIndices?: IDocumentIndex[];
118
951
  }
119
952
  interface IPartnersSearch {
120
953
  name?: string;
@@ -147,6 +980,11 @@ interface IBankAccountSearch {
147
980
  accountNumberLike?: string;
148
981
  main?: boolean;
149
982
  }
983
+ interface ICurrency {
984
+ uuid: string;
985
+ code: string;
986
+ name: string;
987
+ }
150
988
  interface INote {
151
989
  uuid: string;
152
990
  subject: string;
@@ -154,6 +992,9 @@ interface INote {
154
992
  date?: string;
155
993
  createdBy?: IUser;
156
994
  }
995
+ interface INoteSearch {
996
+ note?: string;
997
+ }
157
998
  interface IContactPerson {
158
999
  uuid: string;
159
1000
  representation: string;
@@ -173,11 +1014,13 @@ interface IContactPerson {
173
1014
  phoneNumber?: string;
174
1015
  factoringRepresentative?: boolean;
175
1016
  }
176
- interface IGroup {
1017
+ interface IPartnerGroup {
177
1018
  uuid: string;
178
1019
  name: string;
179
1020
  organization?: IOrganization;
180
1021
  }
1022
+ type PartnerGroupType = 'BANK';
1023
+ type IPartnerType = 'legalEntity' | 'physicalPerson' | 'foreignPartner';
181
1024
 
182
1025
  interface IOrganization {
183
1026
  uuid: string;
@@ -199,7 +1042,6 @@ interface IOrganization {
199
1042
  email?: string;
200
1043
  website?: string;
201
1044
  phoneNumber?: string;
202
- group?: any;
203
1045
  contactPerson?: IContactPerson;
204
1046
  physicalPerson?: boolean;
205
1047
  personalIdentificationNumber?: string;
@@ -271,18 +1113,32 @@ interface IResellerContract {
271
1113
  pdfDownloadUrl?: string;
272
1114
  freeTrail?: boolean;
273
1115
  }
1116
+ interface IOrganizationalUnit {
1117
+ uuid: string;
1118
+ name: string;
1119
+ code: string;
1120
+ type: IOrganizationalUnitType;
1121
+ parent?: string;
1122
+ primaryForInvoiceReceive?: boolean;
1123
+ }
274
1124
  interface IOrganizationalUnitUpdate {
275
1125
  uuid?: string;
276
1126
  name?: string;
277
1127
  code?: string;
278
1128
  jbkjs?: string;
279
- type?: ISimpleObject;
1129
+ type?: IOrganizationalUnitType;
280
1130
  organization?: {
281
1131
  uuid: string;
282
1132
  };
283
1133
  parent?: {
284
1134
  uuid: string;
285
1135
  };
1136
+ primaryForInvoiceReceive?: boolean;
1137
+ }
1138
+ interface IOrganizationalUnitType {
1139
+ uuid: string;
1140
+ name: string;
1141
+ internalCode: 'SECTOR';
286
1142
  }
287
1143
 
288
1144
  interface IUserPrivileges {
@@ -523,4 +1379,4 @@ interface Props {
523
1379
  }
524
1380
  declare const Sidebar: FC<Props>;
525
1381
 
526
- export { AxiosTokenHandler, ErrorContext, Header, IBankAccount, IBankAccountSearch, IContactPerson, ICountry, IMunicipality, INote, IOrganization, IOrganizationFetchOption, IOrganizationPrivileges, IOrganizationSearch, IPartner, IPartnersSearch, IPlace, ISidebarItem, IToken, IUser, IUserPreferences, IUserPrivileges, LoginPage, NoAccessInfo, NoMatchPage, NotificationsContext, NotificationsProvider, OrganizationStatus, OrganizationStatuses, SelectOrgPage, Sidebar, UserFetchOption, UserOrgContext, UserOrgProvider };
1382
+ export { AxiosTokenHandler, ErrorContext, Header, IBankAccount, IBankAccountSearch, IBusinessActivity, IContactPerson, ICountry, ICurrency, IDocument, IDocumentAny, IDocumentSearch, IInvoice, IInvoiceItem, IMunicipality, INote, INoteSearch, IOrganization, IOrganizationFetchOption, IOrganizationPrivileges, IOrganizationSearch, IPartner, IPartnerGroup, IPartnerType, IPartnersSearch, IPlace, ISidebarItem, IToken, IUser, IUserPreferences, IUserPrivileges, LoginPage, NoAccessInfo, NoMatchPage, NotificationsContext, NotificationsProvider, OrganizationStatus, OrganizationStatuses, PartnerGroupType, SelectOrgPage, Sidebar, UserFetchOption, UserOrgContext, UserOrgProvider };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inceptionbg/main",
3
- "version": "1.0.21",
3
+ "version": "1.0.22",
4
4
  "description": "Main app wrapper for Inception ecosystem",
5
5
  "type": "module",
6
6
  "files": [