toDocument method

  1. @override
Map<String, Object?> toDocument()
override

Implementation

@override
Map<String, Object?> toDocument() {
  Map<String, Object?> theDocument = HashMap();
  if (amount != null) {
    theDocument["amount"] = amount;
  } else {
    theDocument["amount"] = null;
  }
  if (appId != null) {
    theDocument["appId"] = appId;
  } else {
    theDocument["appId"] = null;
  }
  if (productId != null) {
    theDocument["productId"] = productId;
  } else {
    theDocument["productId"] = null;
  }
  return theDocument;
}