Invoice class

Invoice class

Annotations
  • @freezed

Constructors

Invoice({@Default('') String id, @Default('') @JsonKey(name: 'user_id') String createdById, @Default('') @JsonKey(name: 'assigned_user_id') String assignedToId, @Default(0) @JsonKey(name: 'created_at') int createdAt, @Default(0) @JsonKey(name: 'updated_at') int updatedAt, @Default(0) @JsonKey(name: 'archived_at') int archivedAt, @Default(false) @JsonKey(name: 'is_deleted') bool isDeleted, @Default('') @JsonKey(name: 'custom_value1') String customValue1, @Default('') @JsonKey(name: 'custom_value2') String customValue2, @Default('') @JsonKey(name: 'custom_value3') String customValue3, @Default('') @JsonKey(name: 'custom_value4') String customValue4, @Default('') @JsonKey(name: 'client_id') String clientId, @Default(<InvoiceLineItem>[]) @JsonKey(name: 'line_items') List<InvoiceLineItem> lineItems, @Default(<InvoiceInvitation>[]) List<InvoiceInvitation> invitations, @Default(0) double amount, @Default(0) double balance, @Default('') @JsonKey(name: 'status_id') String statusId, @Default('') @JsonKey(name: 'design_id') String designId, @Default('') String number, @Default(0) double discount, @Default('') @JsonKey(name: 'po_number') String poNumber, @Default('') String date, @Default('') @JsonKey(name: 'last_sent_date') String lastSentDate, @Default('') @JsonKey(name: 'next_send_date') String nextSendDate, @Default('') @JsonKey(name: 'due_date') String dueDate, @Default('') String terms, @Default('') @JsonKey(name: 'public_notes') String publicNotes, @Default('') @JsonKey(name: 'private_notes') String privateNotes, @Default(false) @JsonKey(name: 'uses_inclusive_taxes') bool usesInclusiveTaxes, @Default('') @JsonKey(name: 'tax_name1') String taxName1, @Default(0) @JsonKey(name: 'tax_rate1') double taxRate1, @Default('') @JsonKey(name: 'tax_name2') String taxName2, @Default(0) @JsonKey(name: 'tax_rate2') double taxRate2, @Default('') @JsonKey(name: 'tax_name3') String taxName3, @Default(0) @JsonKey(name: 'tax_rate3') double taxRate3, @Default(0) @JsonKey(name: 'total_taxes') double totalTaxes, @Default(false) @JsonKey(name: 'is_amount_discount') bool isAmountDiscount, @Default('') String footer, @Default(0) double partial, @Default('') @JsonKey(name: 'partial_due_date') String partialDueDate, @Default(false) @JsonKey(name: 'has_tasks') bool hasTasks, @Default(false) @JsonKey(name: 'has_expenses') bool hasExpenses, @Default(0) @JsonKey(name: 'custom_surcharge1') double customSurcharge1, @Default(0) @JsonKey(name: 'custom_surcharge2') double customSurcharge2, @Default(0) @JsonKey(name: 'custom_surcharge3') double customSurcharge3, @Default(0) @JsonKey(name: 'custom_surcharge4') double customSurcharge4, @Default(false) @JsonKey(name: 'custom_surcharge_tax1') bool customSurchargeTax1, @Default(false) @JsonKey(name: 'custom_surcharge_tax2') bool customSurchargeTax2, @Default(false) @JsonKey(name: 'custom_surcharge_tax3') bool customSurchargeTax3, @Default(false) @JsonKey(name: 'custom_surcharge_tax4') bool customSurchargeTax4, @Default(<Document>[]) List<Document> documents, @Default('') @JsonKey(name: 'vendor_id') String vendorId})
Invoice factory constructor
const
factory
Invoice.forClient(Client client, {required List<Product> products})
Create an invoice for a client
factory
Invoice.fromJson(Map<String, dynamic> json)
Create an Invoice from JSON
factory

Properties

amount double
no setterinherited
archivedAt int
no setterinherited
assignedToId String
no setterinherited
balance double
no setterinherited
clientId String
no setterinherited
copyWith → $InvoiceCopyWith<Invoice>
no setterinherited
createdAt int
no setterinherited
createdById String
no setterinherited
customSurcharge1 double
no setterinherited
customSurcharge2 double
no setterinherited
customSurcharge3 double
no setterinherited
customSurcharge4 double
no setterinherited
customSurchargeTax1 bool
no setterinherited
customSurchargeTax2 bool
no setterinherited
customSurchargeTax3 bool
no setterinherited
customSurchargeTax4 bool
no setterinherited
customValue1 String
no setterinherited
customValue2 String
no setterinherited
customValue3 String
no setterinherited
customValue4 String
no setterinherited
date String
no setterinherited
designId String
no setterinherited
discount double
no setterinherited
documents List<Document>
no setterinherited
dueDate String
no setterinherited
no setterinherited
hasExpenses bool
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
hasTasks bool
no setterinherited
id String
no setterinherited
invitations List<InvoiceInvitation>
no setterinherited
isAmountDiscount bool
no setterinherited
isDeleted bool
no setterinherited
isPaid bool
Determine if the invoice is paid
no setter
key String
Get the default invitation key
no setter
lastSentDate String
no setterinherited
lineItems List<InvoiceLineItem>
no setterinherited
nextSendDate String
no setterinherited
number String
no setterinherited
partial double
no setterinherited
partialDueDate String
no setterinherited
pdfUrl String
Get the default invitation PDF URL
no setter
poNumber String
no setterinherited
privateNotes String
no setterinherited
publicNotes String
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
statusId String
no setterinherited
taxName1 String
no setterinherited
taxName2 String
no setterinherited
taxName3 String
no setterinherited
taxRate1 double
no setterinherited
taxRate2 double
no setterinherited
taxRate3 double
no setterinherited
terms String
no setterinherited
totalTaxes double
no setterinherited
updatedAt int
no setterinherited
url String
Get the default invitation URL
no setter
usesInclusiveTaxes bool
no setterinherited
vendorId String
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited