toMap method

  1. @override
Map<String, dynamic> toMap()
override

Implementation

@override
Map<String, dynamic> toMap() {
  return {
    'id': id,
    'firmIdAndBoutiqueId': firmIdAndBoutiqueId,
    'items': items.map((x) => x.toMap()).toList(),
    'taxe': taxe.toMap(),
    'promo': promo,
    'discountAmount': discountAmount,
    'comment': comment,
    'received': received,
    'date': date.toIso8601String(),
    'paymentType': paymentType.toString(),
    'ticketType': ticketType.toString(),
    'contactId': contactId,
    'contactFirstName': contactFirstName,
    'contactLastName': contactLastName,
    'contactPhone': contactPhone,
    'contactMail': contactMail,
    'status': status,
    'statusUpdateDate': statusUpdateDate?.toIso8601String(),
    'creationDate': creationDate.toIso8601String(),
  };
}