/* Options: Date: 2026-04-01 02:33:19 Version: 10.05 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://api.bokamera.se //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: PreviewSummarizedInvoice.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; abstract class ICompany { String? CompanyId; } enum EAccountingInvoiceSendTypes { None, AutoInvoiceElectronic, AutoInvoicePrint, AutoInvoiceB2C, } class PreviewCustomerGroup implements IConvertible { String CustomerId = ""; String CustomerName = ""; String? Email; int BookingCount = 0; List BookingIds = []; bool MissingInvoiceAddress; bool MissingEmail; PreviewCustomerGroup({this.CustomerId,this.CustomerName,this.Email,this.BookingCount,this.BookingIds,this.MissingInvoiceAddress,this.MissingEmail}); PreviewCustomerGroup.fromJson(Map json) { fromMap(json); } fromMap(Map json) { CustomerId = json['CustomerId']; CustomerName = json['CustomerName']; Email = json['Email']; BookingCount = json['BookingCount']; BookingIds = JsonConverters.fromJson(json['BookingIds'],'List',context!); MissingInvoiceAddress = json['MissingInvoiceAddress']; MissingEmail = json['MissingEmail']; return this; } Map toJson() => { 'CustomerId': CustomerId, 'CustomerName': CustomerName, 'Email': Email, 'BookingCount': BookingCount, 'BookingIds': JsonConverters.toJson(BookingIds,'List',context!), 'MissingInvoiceAddress': MissingInvoiceAddress, 'MissingEmail': MissingEmail }; getTypeName() => "PreviewCustomerGroup"; TypeContext? context = _ctx; } class PreviewSummarizedInvoiceResponse implements IConvertible { int TotalCustomers = 0; int TotalBookings = 0; List Customers = []; ResponseStatus ResponseStatus; PreviewSummarizedInvoiceResponse({this.TotalCustomers,this.TotalBookings,this.Customers,this.ResponseStatus}); PreviewSummarizedInvoiceResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { TotalCustomers = json['TotalCustomers']; TotalBookings = json['TotalBookings']; Customers = JsonConverters.fromJson(json['Customers'],'List',context!); ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!); return this; } Map toJson() => { 'TotalCustomers': TotalCustomers, 'TotalBookings': TotalBookings, 'Customers': JsonConverters.toJson(Customers,'List',context!), 'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!) }; getTypeName() => "PreviewSummarizedInvoiceResponse"; TypeContext? context = _ctx; } // @Route("/eaccounting/summarizedinvoice/preview", "GET") // @ValidateRequest(Validator="IsAuthenticated") class PreviewSummarizedInvoice implements IReturn, ICompany, IConvertible, IGet { /** * The company id, if empty will use the company id for the user you are logged in with. */ // @ApiMember(Description="The company id, if empty will use the company id for the user you are logged in with.") String? CompanyId; /** * Start date for the booking range to include. */ // @ApiMember(Description="Start date for the booking range to include.", IsRequired=true) DateTime DateFrom = DateTime(0); /** * End date for the booking range to include. */ // @ApiMember(Description="End date for the booking range to include.", IsRequired=true) DateTime DateTo = DateTime(0); /** * Optional customer id filter. */ // @ApiMember(Description="Optional customer id filter.") String? CustomerId; /** * Optional service/event id filter. */ // @ApiMember(Description="Optional service/event id filter.") int? ServiceId; /** * Optional list of booking status ids to include. If empty, all statuses are included. */ // @ApiMember(Description="Optional list of booking status ids to include. If empty, all statuses are included.") List? BookingStatusIds; /** * Send type for invoices. 0 = None, 1 = AutoInvoiceElectronic, 2 = AutoInvoicePrint, 3 = AutoInvoiceB2C. Used to validate customer addresses for postal delivery. */ // @ApiMember(Description="Send type for invoices. 0 = None, 1 = AutoInvoiceElectronic, 2 = AutoInvoicePrint, 3 = AutoInvoiceB2C. Used to validate customer addresses for postal delivery.") EAccountingInvoiceSendTypes? SendType; PreviewSummarizedInvoice({this.CompanyId,this.DateFrom,this.DateTo,this.CustomerId,this.ServiceId,this.BookingStatusIds,this.SendType}); PreviewSummarizedInvoice.fromJson(Map json) { fromMap(json); } fromMap(Map json) { CompanyId = json['CompanyId']; DateFrom = JsonConverters.fromJson(json['DateFrom'],'DateTime',context!); DateTo = JsonConverters.fromJson(json['DateTo'],'DateTime',context!); CustomerId = json['CustomerId']; ServiceId = json['ServiceId']; BookingStatusIds = JsonConverters.fromJson(json['BookingStatusIds'],'List',context!); SendType = JsonConverters.fromJson(json['SendType'],'EAccountingInvoiceSendTypes',context!); return this; } Map toJson() => { 'CompanyId': CompanyId, 'DateFrom': JsonConverters.toJson(DateFrom,'DateTime',context!), 'DateTo': JsonConverters.toJson(DateTo,'DateTime',context!), 'CustomerId': CustomerId, 'ServiceId': ServiceId, 'BookingStatusIds': JsonConverters.toJson(BookingStatusIds,'List',context!), 'SendType': JsonConverters.toJson(SendType,'EAccountingInvoiceSendTypes',context!) }; createResponse() => PreviewSummarizedInvoiceResponse(); getResponseTypeName() => "PreviewSummarizedInvoiceResponse"; getTypeName() => "PreviewSummarizedInvoice"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'api.bokamera.se', types: { 'ICompany': TypeInfo(TypeOf.Interface), 'EAccountingInvoiceSendTypes': TypeInfo(TypeOf.Enum, enumValues:EAccountingInvoiceSendTypes.values), 'PreviewCustomerGroup': TypeInfo(TypeOf.Class, create:() => PreviewCustomerGroup()), 'PreviewSummarizedInvoiceResponse': TypeInfo(TypeOf.Class, create:() => PreviewSummarizedInvoiceResponse()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'PreviewSummarizedInvoice': TypeInfo(TypeOf.Class, create:() => PreviewSummarizedInvoice()), });