PrepareInvoice (Opus Funktion)
Beschreibung¶
Erstellt eine Rechnung und bereitet dies vor. Prepares and generates invoices for a list of person products. Returns the IDs of all total invoice records created. When PreviewMode=1, writes are directed to the preview tables and the generated PreviewKey is written back to the PreviewKey reference argument.
Argumente¶
Name | Typ | Beschreibung |
|---|---|---|
PersonProductList | [integer] | Array aus PersonProductIDs, für welche die Rechnung erstellt werden soll |
InvoiceData | Rechnungsdatum | |
PaymentDate | Zahlungsdatum | |
BookingDate | Buchungsdatum | |
CompanyID | ID des Unternehmens | |
LocationID | ID des Standortes | |
GlobalID | (optional) SSF_BillingGlobalsID. Wenn nicht angegeben, dann wird diese aus CompanyID und LocationID ermittelt. | |
MakeInstalments | (optional) 0 = (default) keine Ratenaufteilungen machen 1 = Rechnung in Raten aufteilen, wenn konfiguriert | |
TransitoryAccounts | (optional) 0 = (default) keine trasitorischen Konten verwenden 1 = Transitorische Konten verwenden | |
AutomaticBookingDate | (optional) 0 = Buchungsdatum nicht den Bezugszeiträumen anpassen 1 = (default) Buchungsdatum den Bezugszeiträumen anpassen | |
MakeSplits | (optional) 0 = (default) keine Rechnungssplits machen 1 = Rechnung in Splits aufteilen, wenn konfiguriert | |
CombineBillingAddress | 1 = combine items with the same billing address into one invoice; defaults to 0 | |
CombineInvoices | 1 = combine all items into as few invoices as possible; defaults to 1 | |
PreviewMode | 1 = run as preview simulation without modifying original data; defaults to 0 | |
PreviewKey | [ref, output] receives the preview key generated for this simulation run when PreviewMode=1 |
Rückgabewert [integer]¶
Invoice IDs der erstellten Rechnungen. list of total invoice IDs created by the preparation runBeispiel
Li_Invoices := PrepareInvoice(Li_PersonProductIDArray, GetCurrentDateTime(), GetCurrentDateTime()+30, GetCurrentDateTime(), Ai_CompanyID, Ai_SeminarCenterID); |
|---|