@voyant-travel/finance 0.167.0 → 0.168.0
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/README.md +23 -9
- package/dist/action-ledger-drift.d.ts.map +1 -0
- package/dist/booking-lifecycle.d.ts.map +1 -0
- package/dist/booking-schedule/subscriber-runtime.d.ts.map +1 -0
- package/dist/booking-tax.d.ts +31 -19
- package/dist/booking-tax.d.ts.map +1 -0
- package/dist/booking-tax.js +48 -15
- package/dist/card-payment.d.ts.map +1 -0
- package/dist/checkout-routes.d.ts +294 -294
- package/dist/checkout-routes.d.ts.map +1 -0
- package/dist/checkout-service-plan.d.ts +2 -2
- package/dist/checkout-service-plan.d.ts.map +1 -0
- package/dist/checkout-service.d.ts.map +1 -0
- package/dist/checkout-validation.d.ts.map +1 -0
- package/dist/document-download.d.ts.map +1 -0
- package/dist/fx-money.d.ts.map +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +3 -3
- package/dist/invoice-fx.d.ts.map +1 -0
- package/dist/invoice-number-errors.d.ts.map +1 -0
- package/dist/linkables.d.ts.map +1 -0
- package/dist/markets-ref.d.ts.map +1 -0
- package/dist/mcp-runtime.d.ts.map +1 -0
- package/dist/order-payment-sessions.d.ts.map +1 -0
- package/dist/payment-adapter-events.d.ts +3 -3
- package/dist/payment-link.d.ts.map +1 -0
- package/dist/payment-policy-cascade.d.ts.map +1 -0
- package/dist/payment-policy.d.ts.map +1 -0
- package/dist/payment-schedule/routes.d.ts +2 -2
- package/dist/payment-schedule/routes.d.ts.map +1 -0
- package/dist/route-runtime.d.ts.map +1 -0
- package/dist/routes-action-ledger.d.ts +25 -25
- package/dist/routes-action-ledger.d.ts.map +1 -0
- package/dist/routes-booking-billing.d.ts +95 -95
- package/dist/routes-booking-billing.d.ts.map +1 -0
- package/dist/routes-booking-create.d.ts.map +1 -0
- package/dist/routes-booking-reads.d.ts +13 -13
- package/dist/routes-booking-reads.d.ts.map +1 -0
- package/dist/routes-documents.d.ts +11 -11
- package/dist/routes-documents.d.ts.map +1 -0
- package/dist/routes-invoice-core.d.ts +87 -87
- package/dist/routes-invoice-core.d.ts.map +1 -0
- package/dist/routes-invoice-documents.d.ts +16 -16
- package/dist/routes-invoice-documents.d.ts.map +1 -0
- package/dist/routes-invoice-issue.d.ts.map +1 -0
- package/dist/routes-invoice-schemas.d.ts +20 -20
- package/dist/routes-invoice-schemas.d.ts.map +1 -0
- package/dist/routes-payment-processing.d.ts +152 -152
- package/dist/routes-payment-processing.d.ts.map +1 -0
- package/dist/routes-payment-schemas.d.ts +17 -17
- package/dist/routes-payment-schemas.d.ts.map +1 -0
- package/dist/routes-payments.d.ts +64 -64
- package/dist/routes-payments.d.ts.map +1 -0
- package/dist/routes-public-accountant.d.ts +19 -19
- package/dist/routes-public.d.ts +102 -102
- package/dist/routes-public.d.ts.map +1 -0
- package/dist/routes-reference-data.d.ts +33 -33
- package/dist/routes-reference-data.d.ts.map +1 -0
- package/dist/routes-reports.d.ts +11 -11
- package/dist/routes-reports.d.ts.map +1 -0
- package/dist/routes-runtime.d.ts +1 -1
- package/dist/routes-runtime.d.ts.map +1 -0
- package/dist/routes-settlement.d.ts +12 -12
- package/dist/routes-settlement.d.ts.map +1 -0
- package/dist/routes-shared.d.ts.map +1 -0
- package/dist/routes-supplier-invoices.d.ts +75 -75
- package/dist/routes-supplier-invoices.d.ts.map +1 -0
- package/dist/routes-travel-credits.d.ts +4 -4
- package/dist/routes-vouchers.d.ts +401 -0
- package/dist/routes-vouchers.d.ts.map +1 -0
- package/dist/routes-vouchers.js +176 -0
- package/dist/routes.d.ts +477 -477
- package/dist/routes.d.ts.map +1 -0
- package/dist/runtime-contributor.d.ts.map +1 -0
- package/dist/runtime-port.d.ts +20 -24
- package/dist/runtime-port.d.ts.map +1 -0
- package/dist/runtime-port.js +10 -11
- package/dist/runtime.d.ts.map +1 -0
- package/dist/schema/booking-billing.d.ts +5 -5
- package/dist/schema/booking-billing.d.ts.map +1 -0
- package/dist/schema/enums.d.ts.map +1 -0
- package/dist/schema/invoice-documents.d.ts +1 -1
- package/dist/schema/invoice-documents.d.ts.map +1 -0
- package/dist/schema/payment-instruments.d.ts +1 -1
- package/dist/schema/payment-instruments.d.ts.map +1 -0
- package/dist/schema/payment-processing.d.ts +3 -3
- package/dist/schema/payment-processing.d.ts.map +1 -0
- package/dist/schema/payment-sessions.d.ts +3 -3
- package/dist/schema/payment-sessions.d.ts.map +1 -0
- package/dist/schema/receivables.d.ts +3 -3
- package/dist/schema/receivables.d.ts.map +1 -0
- package/dist/schema/relations.d.ts.map +1 -0
- package/dist/schema/supplier-invoices.d.ts +5 -5
- package/dist/schema/supplier-invoices.d.ts.map +1 -0
- package/dist/schema/tax.d.ts +1 -1
- package/dist/schema/tax.d.ts.map +1 -0
- package/dist/schema/vouchers.d.ts +444 -0
- package/dist/schema/vouchers.d.ts.map +1 -0
- package/dist/schema/vouchers.js +64 -0
- package/dist/schema.d.ts.map +1 -0
- package/dist/service-accountant-shares.d.ts.map +1 -0
- package/dist/service-action-ledger-accounting.d.ts.map +1 -0
- package/dist/service-action-ledger-booking-payments.d.ts.map +1 -0
- package/dist/service-action-ledger-bookings.d.ts.map +1 -0
- package/dist/service-action-ledger-payment-authorizations.d.ts.map +1 -0
- package/dist/service-action-ledger-payment-sessions.d.ts.map +1 -0
- package/dist/service-action-ledger-supplier-invoices.d.ts.map +1 -0
- package/dist/service-action-ledger-supplier-payments.d.ts.map +1 -0
- package/dist/service-action-ledger.d.ts.map +1 -0
- package/dist/service-aggregates.d.ts.map +1 -0
- package/dist/service-booking-billing.d.ts +111 -111
- package/dist/service-booking-billing.d.ts.map +1 -0
- package/dist/service-booking-create.d.ts +11 -11
- package/dist/service-booking-create.d.ts.map +1 -0
- package/dist/service-booking-guarantees.d.ts +34 -34
- package/dist/service-booking-guarantees.d.ts.map +1 -0
- package/dist/service-booking-item-billing.d.ts +21 -21
- package/dist/service-booking-item-billing.d.ts.map +1 -0
- package/dist/service-booking-payment-schedules.d.ts +56 -56
- package/dist/service-booking-payment-schedules.d.ts.map +1 -0
- package/dist/service-bookings-dual-create.d.ts +22 -22
- package/dist/service-bookings-dual-create.d.ts.map +1 -0
- package/dist/service-boundary-sql.d.ts.map +1 -0
- package/dist/service-cost-categories.d.ts.map +1 -0
- package/dist/service-documents.d.ts.map +1 -0
- package/dist/service-invoice-artifacts.d.ts +24 -24
- package/dist/service-invoice-artifacts.d.ts.map +1 -0
- package/dist/service-invoice-core.d.ts +28 -28
- package/dist/service-invoice-core.d.ts.map +1 -0
- package/dist/service-invoice-credit-notes.d.ts +10 -10
- package/dist/service-invoice-credit-notes.d.ts.map +1 -0
- package/dist/service-invoice-from-booking.d.ts +19 -19
- package/dist/service-invoice-from-booking.d.ts.map +1 -0
- package/dist/service-invoice-line-items.d.ts +10 -10
- package/dist/service-invoice-line-items.d.ts.map +1 -0
- package/dist/service-invoice-numbering.d.ts +28 -28
- package/dist/service-invoice-numbering.d.ts.map +1 -0
- package/dist/service-invoice-payments.d.ts +20 -20
- package/dist/service-invoice-payments.d.ts.map +1 -0
- package/dist/service-invoices.d.ts +87 -87
- package/dist/service-invoices.d.ts.map +1 -0
- package/dist/service-issue.d.ts +38 -38
- package/dist/service-issue.d.ts.map +1 -0
- package/dist/service-payment-authorizations.d.ts +26 -26
- package/dist/service-payment-authorizations.d.ts.map +1 -0
- package/dist/service-payment-instruments.d.ts +10 -10
- package/dist/service-payment-instruments.d.ts.map +1 -0
- package/dist/service-payment-processing.d.ts +77 -77
- package/dist/service-payment-processing.d.ts.map +1 -0
- package/dist/service-payment-session-completion.d.ts +3 -3
- package/dist/service-payment-session-completion.d.ts.map +1 -0
- package/dist/service-payment-sessions.d.ts +38 -38
- package/dist/service-payment-sessions.d.ts.map +1 -0
- package/dist/service-profitability.d.ts.map +1 -0
- package/dist/service-public.d.ts +16 -16
- package/dist/service-public.d.ts.map +1 -0
- package/dist/service-reference-data.d.ts +23 -23
- package/dist/service-reference-data.d.ts.map +1 -0
- package/dist/service-rendition-wait.d.ts +1 -1
- package/dist/service-rendition-wait.d.ts.map +1 -0
- package/dist/service-reports.d.ts.map +1 -0
- package/dist/service-settlement.d.ts.map +1 -0
- package/dist/service-shared.d.ts +4 -4
- package/dist/service-shared.d.ts.map +1 -0
- package/dist/service-supplier-invoices.d.ts +20 -20
- package/dist/service-supplier-invoices.d.ts.map +1 -0
- package/dist/service-supplier-payments.d.ts +16 -16
- package/dist/service-supplier-payments.d.ts.map +1 -0
- package/dist/service-travel-credits.d.ts +10 -10
- package/dist/service-vouchers-migration.d.ts +51 -0
- package/dist/service-vouchers-migration.d.ts.map +1 -0
- package/dist/service-vouchers-migration.js +154 -0
- package/dist/service-vouchers.d.ts +157 -0
- package/dist/service-vouchers.d.ts.map +1 -0
- package/dist/service-vouchers.js +191 -0
- package/dist/service.d.ts +376 -376
- package/dist/service.d.ts.map +1 -0
- package/dist/stale-booking-holds-runtime.d.ts.map +1 -0
- package/dist/tools.d.ts +21 -21
- package/dist/tools.d.ts.map +1 -0
- package/dist/validation-billing.d.ts.map +1 -0
- package/dist/validation-payments.d.ts.map +1 -0
- package/dist/validation-public.d.ts.map +1 -0
- package/dist/validation-shared.d.ts.map +1 -0
- package/dist/validation-vouchers.d.ts +2 -0
- package/dist/validation-vouchers.d.ts.map +1 -0
- package/dist/validation-vouchers.js +1 -0
- package/dist/validation.d.ts.map +1 -0
- package/dist/voyant.d.ts +2 -1
- package/dist/voyant.d.ts.map +1 -0
- package/dist/voyant.js +43 -7
- package/openapi/admin/booking-tax-preview.json +33 -0
- package/openapi/admin/{booking-tax.json → booking-tax-settings.json} +7 -32
- package/package.json +205 -170
- package/LICENSE +0 -201
|
@@ -125,7 +125,7 @@ export declare const financeInvoicePaymentService: {
|
|
|
125
125
|
tableName: "payments";
|
|
126
126
|
dataType: "string";
|
|
127
127
|
columnType: "PgEnumColumn";
|
|
128
|
-
data: "
|
|
128
|
+
data: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
129
129
|
driverParam: string;
|
|
130
130
|
notNull: true;
|
|
131
131
|
hasDefault: false;
|
|
@@ -193,7 +193,7 @@ export declare const financeInvoicePaymentService: {
|
|
|
193
193
|
tableName: "payments";
|
|
194
194
|
dataType: "string";
|
|
195
195
|
columnType: "PgEnumColumn";
|
|
196
|
-
data: "pending" | "
|
|
196
|
+
data: "pending" | "failed" | "completed" | "refunded";
|
|
197
197
|
driverParam: string;
|
|
198
198
|
notNull: true;
|
|
199
199
|
hasDefault: true;
|
|
@@ -298,11 +298,11 @@ export declare const financeInvoicePaymentService: {
|
|
|
298
298
|
baseCurrency: string | null;
|
|
299
299
|
baseAmountCents: number | null;
|
|
300
300
|
fxRateSetId: string | null;
|
|
301
|
-
paymentMethod: "
|
|
301
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
302
302
|
paymentInstrumentId: string | null;
|
|
303
303
|
paymentAuthorizationId: string | null;
|
|
304
304
|
paymentCaptureId: string | null;
|
|
305
|
-
status: "pending" | "
|
|
305
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
306
306
|
referenceNumber: string | null;
|
|
307
307
|
paymentDate: string;
|
|
308
308
|
notes: string | null;
|
|
@@ -433,7 +433,7 @@ export declare const financeInvoicePaymentService: {
|
|
|
433
433
|
tableName: "payments";
|
|
434
434
|
dataType: "string";
|
|
435
435
|
columnType: "PgEnumColumn";
|
|
436
|
-
data: "
|
|
436
|
+
data: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
437
437
|
driverParam: string;
|
|
438
438
|
notNull: true;
|
|
439
439
|
hasDefault: false;
|
|
@@ -501,7 +501,7 @@ export declare const financeInvoicePaymentService: {
|
|
|
501
501
|
tableName: "payments";
|
|
502
502
|
dataType: "string";
|
|
503
503
|
columnType: "PgEnumColumn";
|
|
504
|
-
data: "pending" | "
|
|
504
|
+
data: "pending" | "failed" | "completed" | "refunded";
|
|
505
505
|
driverParam: string;
|
|
506
506
|
notNull: true;
|
|
507
507
|
hasDefault: true;
|
|
@@ -614,22 +614,22 @@ export declare const financeInvoicePaymentService: {
|
|
|
614
614
|
getPaymentById(db: PostgresJsDatabase, id: string): Promise<UnifiedPaymentRow | null>;
|
|
615
615
|
createPayment(db: PostgresJsDatabase, invoiceId: string, data: CreatePaymentInput, runtime?: FinanceServiceRuntime): Promise<{
|
|
616
616
|
id: string;
|
|
617
|
-
status: "pending" | "completed" | "failed" | "refunded";
|
|
618
|
-
notes: string | null;
|
|
619
|
-
createdAt: Date;
|
|
620
|
-
updatedAt: Date;
|
|
621
617
|
currency: string;
|
|
622
|
-
|
|
623
|
-
fxRateSetId: string | null;
|
|
624
|
-
invoiceId: string;
|
|
618
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
625
619
|
amountCents: number;
|
|
626
|
-
|
|
627
|
-
|
|
620
|
+
notes: string | null;
|
|
621
|
+
invoiceId: string;
|
|
628
622
|
paymentInstrumentId: string | null;
|
|
629
623
|
paymentAuthorizationId: string | null;
|
|
630
624
|
paymentCaptureId: string | null;
|
|
631
|
-
|
|
625
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
632
626
|
paymentDate: string;
|
|
627
|
+
referenceNumber: string | null;
|
|
628
|
+
createdAt: Date;
|
|
629
|
+
baseCurrency: string | null;
|
|
630
|
+
baseAmountCents: number | null;
|
|
631
|
+
fxRateSetId: string | null;
|
|
632
|
+
updatedAt: Date;
|
|
633
633
|
} | null>;
|
|
634
634
|
updatePayment(db: PostgresJsDatabase, id: string, data: UpdatePaymentInput, runtime?: FinanceServiceRuntime): Promise<{
|
|
635
635
|
id: string;
|
|
@@ -639,11 +639,11 @@ export declare const financeInvoicePaymentService: {
|
|
|
639
639
|
baseCurrency: string | null;
|
|
640
640
|
baseAmountCents: number | null;
|
|
641
641
|
fxRateSetId: string | null;
|
|
642
|
-
paymentMethod: "
|
|
642
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
643
643
|
paymentInstrumentId: string | null;
|
|
644
644
|
paymentAuthorizationId: string | null;
|
|
645
645
|
paymentCaptureId: string | null;
|
|
646
|
-
status: "pending" | "
|
|
646
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
647
647
|
referenceNumber: string | null;
|
|
648
648
|
paymentDate: string;
|
|
649
649
|
notes: string | null;
|
|
@@ -658,11 +658,11 @@ export declare const financeInvoicePaymentService: {
|
|
|
658
658
|
baseCurrency: string | null;
|
|
659
659
|
baseAmountCents: number | null;
|
|
660
660
|
fxRateSetId: string | null;
|
|
661
|
-
paymentMethod: "
|
|
661
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
662
662
|
paymentInstrumentId: string | null;
|
|
663
663
|
paymentAuthorizationId: string | null;
|
|
664
664
|
paymentCaptureId: string | null;
|
|
665
|
-
status: "pending" | "
|
|
665
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
666
666
|
referenceNumber: string | null;
|
|
667
667
|
paymentDate: string;
|
|
668
668
|
notes: string | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"service-invoice-payments.d.ts","sourceRoot":"","sources":["../src/service-invoice-payments.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EAErB,gBAAgB,EAChB,kBAAkB,EAElB,iBAAiB,EACjB,kBAAkB,EACnB,MAAM,qBAAqB,CAAA;AAoD5B,eAAO,MAAM,4BAA4B;qBACtB,kBAAkB,aAAa,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAQ5B,kBAAkB,SAAS,gBAAgB;cAS5C,iBAAiB,EAAE;;;;;IAuJ5C;;;;;OAKG;uBACsB,kBAAkB,MAAM,MAAM,GAAG,OAAO,CAAC,iBAAiB,GAAG,IAAI,CAAC;sBA4ErF,kBAAkB,aACX,MAAM,QACX,kBAAkB,YACf,qBAAqB;;;;;;;;;;;;;;;;;;;sBA4I1B,kBAAkB,MAClB,MAAM,QACJ,kBAAkB,YACf,qBAAqB;;;;;;;;;;;;;;;;;;;sBA0FR,kBAAkB,MAAM,MAAM,YAAW,qBAAqB;;;;;;;;;;;;;;;;;;;CAmCvF,CAAA"}
|
|
@@ -475,18 +475,18 @@ export declare const financeInvoiceService: {
|
|
|
475
475
|
} | null>;
|
|
476
476
|
createCreditNote(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreateCreditNoteInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
477
477
|
id: string;
|
|
478
|
+
currency: string;
|
|
478
479
|
status: "draft" | "issued" | "applied";
|
|
480
|
+
amountCents: number;
|
|
479
481
|
notes: string | null;
|
|
482
|
+
invoiceId: string;
|
|
480
483
|
createdAt: Date;
|
|
481
|
-
updatedAt: Date;
|
|
482
|
-
currency: string;
|
|
483
484
|
baseCurrency: string | null;
|
|
484
|
-
fxRateSetId: string | null;
|
|
485
|
-
invoiceId: string;
|
|
486
|
-
amountCents: number;
|
|
487
485
|
baseAmountCents: number | null;
|
|
488
|
-
|
|
486
|
+
fxRateSetId: string | null;
|
|
489
487
|
reason: string;
|
|
488
|
+
creditNoteNumber: string;
|
|
489
|
+
updatedAt: Date;
|
|
490
490
|
} | null | undefined>;
|
|
491
491
|
updateCreditNote(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, creditNoteId: string, data: import("./service-shared.js").UpdateCreditNoteInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
492
492
|
id: string;
|
|
@@ -789,12 +789,12 @@ export declare const financeInvoiceService: {
|
|
|
789
789
|
}>, "where" | "orderBy">;
|
|
790
790
|
createCreditNoteLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, creditNoteId: string, data: import("./service-shared.js").CreateCreditNoteLineItemInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
791
791
|
id: string;
|
|
792
|
+
description: string;
|
|
793
|
+
sortOrder: number;
|
|
792
794
|
createdAt: Date;
|
|
793
795
|
totalCents: number;
|
|
794
|
-
description: string;
|
|
795
796
|
quantity: number;
|
|
796
797
|
unitPriceCents: number;
|
|
797
|
-
sortOrder: number;
|
|
798
798
|
creditNoteId: string;
|
|
799
799
|
} | null>;
|
|
800
800
|
listNotes(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string): Omit<import("drizzle-orm/pg-core").PgSelectBase<"finance_notes", {
|
|
@@ -978,10 +978,10 @@ export declare const financeInvoiceService: {
|
|
|
978
978
|
}>, "where" | "orderBy">;
|
|
979
979
|
createNote(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, userId: string, data: import("./service-shared.js").CreateFinanceNoteInput): Promise<{
|
|
980
980
|
id: string;
|
|
981
|
-
|
|
981
|
+
content: string;
|
|
982
982
|
invoiceId: string;
|
|
983
|
+
createdAt: Date;
|
|
983
984
|
authorId: string;
|
|
984
|
-
content: string;
|
|
985
985
|
} | null | undefined>;
|
|
986
986
|
listPayments(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string): Omit<import("drizzle-orm/pg-core").PgSelectBase<"payments", {
|
|
987
987
|
id: import("drizzle-orm/pg-core").PgColumn<{
|
|
@@ -1108,7 +1108,7 @@ export declare const financeInvoiceService: {
|
|
|
1108
1108
|
tableName: "payments";
|
|
1109
1109
|
dataType: "string";
|
|
1110
1110
|
columnType: "PgEnumColumn";
|
|
1111
|
-
data: "
|
|
1111
|
+
data: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
1112
1112
|
driverParam: string;
|
|
1113
1113
|
notNull: true;
|
|
1114
1114
|
hasDefault: false;
|
|
@@ -1176,7 +1176,7 @@ export declare const financeInvoiceService: {
|
|
|
1176
1176
|
tableName: "payments";
|
|
1177
1177
|
dataType: "string";
|
|
1178
1178
|
columnType: "PgEnumColumn";
|
|
1179
|
-
data: "pending" | "
|
|
1179
|
+
data: "pending" | "failed" | "completed" | "refunded";
|
|
1180
1180
|
driverParam: string;
|
|
1181
1181
|
notNull: true;
|
|
1182
1182
|
hasDefault: true;
|
|
@@ -1281,11 +1281,11 @@ export declare const financeInvoiceService: {
|
|
|
1281
1281
|
baseCurrency: string | null;
|
|
1282
1282
|
baseAmountCents: number | null;
|
|
1283
1283
|
fxRateSetId: string | null;
|
|
1284
|
-
paymentMethod: "
|
|
1284
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
1285
1285
|
paymentInstrumentId: string | null;
|
|
1286
1286
|
paymentAuthorizationId: string | null;
|
|
1287
1287
|
paymentCaptureId: string | null;
|
|
1288
|
-
status: "pending" | "
|
|
1288
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
1289
1289
|
referenceNumber: string | null;
|
|
1290
1290
|
paymentDate: string;
|
|
1291
1291
|
notes: string | null;
|
|
@@ -1416,7 +1416,7 @@ export declare const financeInvoiceService: {
|
|
|
1416
1416
|
tableName: "payments";
|
|
1417
1417
|
dataType: "string";
|
|
1418
1418
|
columnType: "PgEnumColumn";
|
|
1419
|
-
data: "
|
|
1419
|
+
data: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
1420
1420
|
driverParam: string;
|
|
1421
1421
|
notNull: true;
|
|
1422
1422
|
hasDefault: false;
|
|
@@ -1484,7 +1484,7 @@ export declare const financeInvoiceService: {
|
|
|
1484
1484
|
tableName: "payments";
|
|
1485
1485
|
dataType: "string";
|
|
1486
1486
|
columnType: "PgEnumColumn";
|
|
1487
|
-
data: "pending" | "
|
|
1487
|
+
data: "pending" | "failed" | "completed" | "refunded";
|
|
1488
1488
|
driverParam: string;
|
|
1489
1489
|
notNull: true;
|
|
1490
1490
|
hasDefault: true;
|
|
@@ -1591,22 +1591,22 @@ export declare const financeInvoiceService: {
|
|
|
1591
1591
|
getPaymentById(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string): Promise<import("./service-shared.js").UnifiedPaymentRow | null>;
|
|
1592
1592
|
createPayment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreatePaymentInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
1593
1593
|
id: string;
|
|
1594
|
-
status: "pending" | "completed" | "failed" | "refunded";
|
|
1595
|
-
notes: string | null;
|
|
1596
|
-
createdAt: Date;
|
|
1597
|
-
updatedAt: Date;
|
|
1598
1594
|
currency: string;
|
|
1599
|
-
|
|
1600
|
-
fxRateSetId: string | null;
|
|
1601
|
-
invoiceId: string;
|
|
1595
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
1602
1596
|
amountCents: number;
|
|
1603
|
-
|
|
1604
|
-
|
|
1597
|
+
notes: string | null;
|
|
1598
|
+
invoiceId: string;
|
|
1605
1599
|
paymentInstrumentId: string | null;
|
|
1606
1600
|
paymentAuthorizationId: string | null;
|
|
1607
1601
|
paymentCaptureId: string | null;
|
|
1608
|
-
|
|
1602
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
1609
1603
|
paymentDate: string;
|
|
1604
|
+
referenceNumber: string | null;
|
|
1605
|
+
createdAt: Date;
|
|
1606
|
+
baseCurrency: string | null;
|
|
1607
|
+
baseAmountCents: number | null;
|
|
1608
|
+
fxRateSetId: string | null;
|
|
1609
|
+
updatedAt: Date;
|
|
1610
1610
|
} | null>;
|
|
1611
1611
|
updatePayment(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string, data: import("./service-shared.js").UpdatePaymentInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
1612
1612
|
id: string;
|
|
@@ -1616,11 +1616,11 @@ export declare const financeInvoiceService: {
|
|
|
1616
1616
|
baseCurrency: string | null;
|
|
1617
1617
|
baseAmountCents: number | null;
|
|
1618
1618
|
fxRateSetId: string | null;
|
|
1619
|
-
paymentMethod: "
|
|
1619
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
1620
1620
|
paymentInstrumentId: string | null;
|
|
1621
1621
|
paymentAuthorizationId: string | null;
|
|
1622
1622
|
paymentCaptureId: string | null;
|
|
1623
|
-
status: "pending" | "
|
|
1623
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
1624
1624
|
referenceNumber: string | null;
|
|
1625
1625
|
paymentDate: string;
|
|
1626
1626
|
notes: string | null;
|
|
@@ -1635,11 +1635,11 @@ export declare const financeInvoiceService: {
|
|
|
1635
1635
|
baseCurrency: string | null;
|
|
1636
1636
|
baseAmountCents: number | null;
|
|
1637
1637
|
fxRateSetId: string | null;
|
|
1638
|
-
paymentMethod: "
|
|
1638
|
+
paymentMethod: "other" | "credit_card" | "debit_card" | "cash" | "wallet" | "direct_bill" | "travel_credit" | "bank_transfer" | "cheque";
|
|
1639
1639
|
paymentInstrumentId: string | null;
|
|
1640
1640
|
paymentAuthorizationId: string | null;
|
|
1641
1641
|
paymentCaptureId: string | null;
|
|
1642
|
-
status: "pending" | "
|
|
1642
|
+
status: "pending" | "failed" | "completed" | "refunded";
|
|
1643
1643
|
referenceNumber: string | null;
|
|
1644
1644
|
paymentDate: string;
|
|
1645
1645
|
notes: string | null;
|
|
@@ -2037,16 +2037,16 @@ export declare const financeInvoiceService: {
|
|
|
2037
2037
|
}>, "where" | "orderBy">;
|
|
2038
2038
|
createInvoiceLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, invoiceId: string, data: import("./service-shared.js").CreateInvoiceLineItemInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
2039
2039
|
id: string;
|
|
2040
|
-
|
|
2041
|
-
totalCents: number;
|
|
2040
|
+
description: string;
|
|
2042
2041
|
invoiceId: string;
|
|
2043
|
-
bookingItemId: string | null;
|
|
2044
2042
|
bookingPaymentScheduleId: string | null;
|
|
2045
|
-
|
|
2043
|
+
bookingItemId: string | null;
|
|
2044
|
+
sortOrder: number;
|
|
2045
|
+
createdAt: Date;
|
|
2046
|
+
totalCents: number;
|
|
2046
2047
|
quantity: number;
|
|
2047
2048
|
unitPriceCents: number;
|
|
2048
2049
|
taxRate: number | null;
|
|
2049
|
-
sortOrder: number;
|
|
2050
2050
|
} | null>;
|
|
2051
2051
|
updateInvoiceLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, lineId: string, data: import("./service-shared.js").UpdateInvoiceLineItemInput, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
2052
2052
|
id: string;
|
|
@@ -2063,53 +2063,53 @@ export declare const financeInvoiceService: {
|
|
|
2063
2063
|
} | null>;
|
|
2064
2064
|
deleteInvoiceLineItem(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, lineId: string, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
2065
2065
|
id: string;
|
|
2066
|
-
|
|
2067
|
-
totalCents: number;
|
|
2066
|
+
description: string;
|
|
2068
2067
|
invoiceId: string;
|
|
2069
|
-
bookingItemId: string | null;
|
|
2070
2068
|
bookingPaymentScheduleId: string | null;
|
|
2071
|
-
|
|
2069
|
+
bookingItemId: string | null;
|
|
2070
|
+
sortOrder: number;
|
|
2071
|
+
createdAt: Date;
|
|
2072
|
+
totalCents: number;
|
|
2072
2073
|
quantity: number;
|
|
2073
2074
|
unitPriceCents: number;
|
|
2074
2075
|
taxRate: number | null;
|
|
2075
|
-
sortOrder: number;
|
|
2076
2076
|
} | null>;
|
|
2077
2077
|
createInvoiceFromBooking(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateInvoiceFromBookingInput, bookingData: import("./service-shared.js").InvoiceFromBookingData, runtime?: import("./service-shared.js").FinanceServiceRuntime): Promise<{
|
|
2078
2078
|
id: string;
|
|
2079
|
+
currency: string;
|
|
2080
|
+
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
2081
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2082
|
+
notes: string | null;
|
|
2083
|
+
bookingId: string;
|
|
2079
2084
|
personId: string | null;
|
|
2080
2085
|
organizationId: string | null;
|
|
2081
|
-
|
|
2082
|
-
|
|
2086
|
+
voidedAt: Date | null;
|
|
2087
|
+
dueDate: string;
|
|
2083
2088
|
createdAt: Date;
|
|
2084
|
-
updatedAt: Date;
|
|
2085
|
-
invoiceNumber: string;
|
|
2086
|
-
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
2087
|
-
convertedFromInvoiceId: string | null;
|
|
2088
|
-
seriesId: string | null;
|
|
2089
|
-
sequence: number | null;
|
|
2090
|
-
templateId: string | null;
|
|
2091
|
-
taxRegimeId: string | null;
|
|
2092
|
-
language: string | null;
|
|
2093
|
-
bookingId: string;
|
|
2094
|
-
currency: string;
|
|
2095
2089
|
baseCurrency: string | null;
|
|
2096
2090
|
fxRateSetId: string | null;
|
|
2091
|
+
invoiceNumber: string;
|
|
2092
|
+
totalCents: number;
|
|
2093
|
+
paidCents: number;
|
|
2094
|
+
balanceDueCents: number;
|
|
2095
|
+
issueDate: string;
|
|
2097
2096
|
subtotalCents: number;
|
|
2098
2097
|
baseSubtotalCents: number | null;
|
|
2099
2098
|
taxCents: number;
|
|
2100
2099
|
baseTaxCents: number | null;
|
|
2101
|
-
totalCents: number;
|
|
2102
2100
|
baseTotalCents: number | null;
|
|
2103
|
-
paidCents: number;
|
|
2104
2101
|
basePaidCents: number | null;
|
|
2105
|
-
balanceDueCents: number;
|
|
2106
2102
|
baseBalanceDueCents: number | null;
|
|
2107
2103
|
commissionPercent: number | null;
|
|
2108
2104
|
commissionAmountCents: number | null;
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2105
|
+
seriesId: string | null;
|
|
2106
|
+
convertedFromInvoiceId: string | null;
|
|
2107
|
+
language: string | null;
|
|
2108
|
+
templateId: string | null;
|
|
2109
|
+
taxRegimeId: string | null;
|
|
2110
|
+
sequence: number | null;
|
|
2112
2111
|
voidReason: string | null;
|
|
2112
|
+
updatedAt: Date;
|
|
2113
2113
|
} | null>;
|
|
2114
2114
|
listInvoices(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, query: import("./service-shared.js").InvoiceListQuery): Promise<{
|
|
2115
2115
|
data: {
|
|
@@ -2126,7 +2126,7 @@ export declare const financeInvoiceService: {
|
|
|
2126
2126
|
bookingId: string;
|
|
2127
2127
|
personId: string | null;
|
|
2128
2128
|
organizationId: string | null;
|
|
2129
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2129
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2130
2130
|
currency: string;
|
|
2131
2131
|
baseCurrency: string | null;
|
|
2132
2132
|
fxRateSetId: string | null;
|
|
@@ -2156,40 +2156,40 @@ export declare const financeInvoiceService: {
|
|
|
2156
2156
|
}>;
|
|
2157
2157
|
createInvoice(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, data: import("./service-shared.js").CreateInvoiceInput): Promise<{
|
|
2158
2158
|
id: string;
|
|
2159
|
+
currency: string;
|
|
2160
|
+
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
2161
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2162
|
+
notes: string | null;
|
|
2163
|
+
bookingId: string;
|
|
2159
2164
|
personId: string | null;
|
|
2160
2165
|
organizationId: string | null;
|
|
2161
|
-
|
|
2162
|
-
|
|
2166
|
+
voidedAt: Date | null;
|
|
2167
|
+
dueDate: string;
|
|
2163
2168
|
createdAt: Date;
|
|
2164
|
-
updatedAt: Date;
|
|
2165
|
-
invoiceNumber: string;
|
|
2166
|
-
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
2167
|
-
convertedFromInvoiceId: string | null;
|
|
2168
|
-
seriesId: string | null;
|
|
2169
|
-
sequence: number | null;
|
|
2170
|
-
templateId: string | null;
|
|
2171
|
-
taxRegimeId: string | null;
|
|
2172
|
-
language: string | null;
|
|
2173
|
-
bookingId: string;
|
|
2174
|
-
currency: string;
|
|
2175
2169
|
baseCurrency: string | null;
|
|
2176
2170
|
fxRateSetId: string | null;
|
|
2171
|
+
invoiceNumber: string;
|
|
2172
|
+
totalCents: number;
|
|
2173
|
+
paidCents: number;
|
|
2174
|
+
balanceDueCents: number;
|
|
2175
|
+
issueDate: string;
|
|
2177
2176
|
subtotalCents: number;
|
|
2178
2177
|
baseSubtotalCents: number | null;
|
|
2179
2178
|
taxCents: number;
|
|
2180
2179
|
baseTaxCents: number | null;
|
|
2181
|
-
totalCents: number;
|
|
2182
2180
|
baseTotalCents: number | null;
|
|
2183
|
-
paidCents: number;
|
|
2184
2181
|
basePaidCents: number | null;
|
|
2185
|
-
balanceDueCents: number;
|
|
2186
2182
|
baseBalanceDueCents: number | null;
|
|
2187
2183
|
commissionPercent: number | null;
|
|
2188
2184
|
commissionAmountCents: number | null;
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2185
|
+
seriesId: string | null;
|
|
2186
|
+
convertedFromInvoiceId: string | null;
|
|
2187
|
+
language: string | null;
|
|
2188
|
+
templateId: string | null;
|
|
2189
|
+
taxRegimeId: string | null;
|
|
2190
|
+
sequence: number | null;
|
|
2192
2191
|
voidReason: string | null;
|
|
2192
|
+
updatedAt: Date;
|
|
2193
2193
|
} | undefined>;
|
|
2194
2194
|
getInvoiceById(db: import("drizzle-orm/postgres-js").PostgresJsDatabase, id: string): Promise<{
|
|
2195
2195
|
convertedToInvoiceId: string | null;
|
|
@@ -2206,7 +2206,7 @@ export declare const financeInvoiceService: {
|
|
|
2206
2206
|
bookingId: string;
|
|
2207
2207
|
personId: string | null;
|
|
2208
2208
|
organizationId: string | null;
|
|
2209
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2209
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2210
2210
|
currency: string;
|
|
2211
2211
|
baseCurrency: string | null;
|
|
2212
2212
|
fxRateSetId: string | null;
|
|
@@ -2243,7 +2243,7 @@ export declare const financeInvoiceService: {
|
|
|
2243
2243
|
bookingId: string;
|
|
2244
2244
|
personId: string | null;
|
|
2245
2245
|
organizationId: string | null;
|
|
2246
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2246
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2247
2247
|
currency: string;
|
|
2248
2248
|
baseCurrency: string | null;
|
|
2249
2249
|
fxRateSetId: string | null;
|
|
@@ -2292,7 +2292,7 @@ export declare const financeInvoiceService: {
|
|
|
2292
2292
|
bookingId: string;
|
|
2293
2293
|
personId: string | null;
|
|
2294
2294
|
organizationId: string | null;
|
|
2295
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2295
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2296
2296
|
currency: string;
|
|
2297
2297
|
baseCurrency: string | null;
|
|
2298
2298
|
fxRateSetId: string | null;
|
|
@@ -2331,7 +2331,7 @@ export declare const financeInvoiceService: {
|
|
|
2331
2331
|
bookingId: string;
|
|
2332
2332
|
personId: string | null;
|
|
2333
2333
|
organizationId: string | null;
|
|
2334
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2334
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2335
2335
|
currency: string;
|
|
2336
2336
|
baseCurrency: string | null;
|
|
2337
2337
|
fxRateSetId: string | null;
|
|
@@ -2370,7 +2370,7 @@ export declare const financeInvoiceService: {
|
|
|
2370
2370
|
bookingId: string;
|
|
2371
2371
|
personId: string | null;
|
|
2372
2372
|
organizationId: string | null;
|
|
2373
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2373
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2374
2374
|
currency: string;
|
|
2375
2375
|
baseCurrency: string | null;
|
|
2376
2376
|
fxRateSetId: string | null;
|
|
@@ -2409,7 +2409,7 @@ export declare const financeInvoiceService: {
|
|
|
2409
2409
|
bookingId: string;
|
|
2410
2410
|
personId: string | null;
|
|
2411
2411
|
organizationId: string | null;
|
|
2412
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2412
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2413
2413
|
currency: string;
|
|
2414
2414
|
baseCurrency: string | null;
|
|
2415
2415
|
fxRateSetId: string | null;
|
|
@@ -2448,7 +2448,7 @@ export declare const financeInvoiceService: {
|
|
|
2448
2448
|
bookingId: string;
|
|
2449
2449
|
personId: string | null;
|
|
2450
2450
|
organizationId: string | null;
|
|
2451
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2451
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2452
2452
|
currency: string;
|
|
2453
2453
|
baseCurrency: string | null;
|
|
2454
2454
|
fxRateSetId: string | null;
|
|
@@ -2487,7 +2487,7 @@ export declare const financeInvoiceService: {
|
|
|
2487
2487
|
bookingId: string;
|
|
2488
2488
|
personId: string | null;
|
|
2489
2489
|
organizationId: string | null;
|
|
2490
|
-
status: "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue"
|
|
2490
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
2491
2491
|
currency: string;
|
|
2492
2492
|
baseCurrency: string | null;
|
|
2493
2493
|
fxRateSetId: string | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"service-invoices.d.ts","sourceRoot":"","sources":["../src/service-invoices.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAMjC,CAAA"}
|
package/dist/service-issue.d.ts
CHANGED
|
@@ -108,40 +108,40 @@ export declare function issueInvoiceFromBookingCommand(db: PostgresJsDatabase, i
|
|
|
108
108
|
*/
|
|
109
109
|
export declare function issueInvoiceFromBooking(db: PostgresJsDatabase, input: CreateInvoiceFromBookingInput, bookingData: InvoiceFromBookingData, runtime?: InvoiceIssueRuntime): Promise<{
|
|
110
110
|
id: string;
|
|
111
|
+
currency: string;
|
|
112
|
+
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
113
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
114
|
+
notes: string | null;
|
|
115
|
+
bookingId: string;
|
|
111
116
|
personId: string | null;
|
|
112
117
|
organizationId: string | null;
|
|
113
|
-
|
|
114
|
-
|
|
118
|
+
voidedAt: Date | null;
|
|
119
|
+
dueDate: string;
|
|
115
120
|
createdAt: Date;
|
|
116
|
-
updatedAt: Date;
|
|
117
|
-
invoiceNumber: string;
|
|
118
|
-
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
119
|
-
convertedFromInvoiceId: string | null;
|
|
120
|
-
seriesId: string | null;
|
|
121
|
-
sequence: number | null;
|
|
122
|
-
templateId: string | null;
|
|
123
|
-
taxRegimeId: string | null;
|
|
124
|
-
language: string | null;
|
|
125
|
-
bookingId: string;
|
|
126
|
-
currency: string;
|
|
127
121
|
baseCurrency: string | null;
|
|
128
122
|
fxRateSetId: string | null;
|
|
123
|
+
invoiceNumber: string;
|
|
124
|
+
totalCents: number;
|
|
125
|
+
paidCents: number;
|
|
126
|
+
balanceDueCents: number;
|
|
127
|
+
issueDate: string;
|
|
129
128
|
subtotalCents: number;
|
|
130
129
|
baseSubtotalCents: number | null;
|
|
131
130
|
taxCents: number;
|
|
132
131
|
baseTaxCents: number | null;
|
|
133
|
-
totalCents: number;
|
|
134
132
|
baseTotalCents: number | null;
|
|
135
|
-
paidCents: number;
|
|
136
133
|
basePaidCents: number | null;
|
|
137
|
-
balanceDueCents: number;
|
|
138
134
|
baseBalanceDueCents: number | null;
|
|
139
135
|
commissionPercent: number | null;
|
|
140
136
|
commissionAmountCents: number | null;
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
137
|
+
seriesId: string | null;
|
|
138
|
+
convertedFromInvoiceId: string | null;
|
|
139
|
+
language: string | null;
|
|
140
|
+
templateId: string | null;
|
|
141
|
+
taxRegimeId: string | null;
|
|
142
|
+
sequence: number | null;
|
|
144
143
|
voidReason: string | null;
|
|
144
|
+
updatedAt: Date;
|
|
145
145
|
} | null>;
|
|
146
146
|
/**
|
|
147
147
|
* Create + emit a proforma from a booking. Same shape as
|
|
@@ -151,40 +151,40 @@ export declare function issueInvoiceFromBooking(db: PostgresJsDatabase, input: C
|
|
|
151
151
|
*/
|
|
152
152
|
export declare function issueProformaFromBooking(db: PostgresJsDatabase, input: CreateInvoiceFromBookingInput, bookingData: InvoiceFromBookingData, runtime?: InvoiceIssueRuntime): Promise<{
|
|
153
153
|
id: string;
|
|
154
|
+
currency: string;
|
|
155
|
+
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
156
|
+
status: "void" | "draft" | "pending_external_allocation" | "issued" | "partially_paid" | "paid" | "overdue";
|
|
157
|
+
notes: string | null;
|
|
158
|
+
bookingId: string;
|
|
154
159
|
personId: string | null;
|
|
155
160
|
organizationId: string | null;
|
|
156
|
-
|
|
157
|
-
|
|
161
|
+
voidedAt: Date | null;
|
|
162
|
+
dueDate: string;
|
|
158
163
|
createdAt: Date;
|
|
159
|
-
updatedAt: Date;
|
|
160
|
-
invoiceNumber: string;
|
|
161
|
-
invoiceType: "invoice" | "proforma" | "credit_note";
|
|
162
|
-
convertedFromInvoiceId: string | null;
|
|
163
|
-
seriesId: string | null;
|
|
164
|
-
sequence: number | null;
|
|
165
|
-
templateId: string | null;
|
|
166
|
-
taxRegimeId: string | null;
|
|
167
|
-
language: string | null;
|
|
168
|
-
bookingId: string;
|
|
169
|
-
currency: string;
|
|
170
164
|
baseCurrency: string | null;
|
|
171
165
|
fxRateSetId: string | null;
|
|
166
|
+
invoiceNumber: string;
|
|
167
|
+
totalCents: number;
|
|
168
|
+
paidCents: number;
|
|
169
|
+
balanceDueCents: number;
|
|
170
|
+
issueDate: string;
|
|
172
171
|
subtotalCents: number;
|
|
173
172
|
baseSubtotalCents: number | null;
|
|
174
173
|
taxCents: number;
|
|
175
174
|
baseTaxCents: number | null;
|
|
176
|
-
totalCents: number;
|
|
177
175
|
baseTotalCents: number | null;
|
|
178
|
-
paidCents: number;
|
|
179
176
|
basePaidCents: number | null;
|
|
180
|
-
balanceDueCents: number;
|
|
181
177
|
baseBalanceDueCents: number | null;
|
|
182
178
|
commissionPercent: number | null;
|
|
183
179
|
commissionAmountCents: number | null;
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
180
|
+
seriesId: string | null;
|
|
181
|
+
convertedFromInvoiceId: string | null;
|
|
182
|
+
language: string | null;
|
|
183
|
+
templateId: string | null;
|
|
184
|
+
taxRegimeId: string | null;
|
|
185
|
+
sequence: number | null;
|
|
187
186
|
voidReason: string | null;
|
|
187
|
+
updatedAt: Date;
|
|
188
188
|
} | null>;
|
|
189
189
|
export declare function buildInvoiceIssuedEvent(db: PostgresJsDatabase, invoice: typeof invoices.$inferSelect, runtime?: InvoiceIssueRuntime): Promise<InvoiceIssuedEvent>;
|
|
190
190
|
/**
|