toJson method

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

Implementation

@override
Map<String, dynamic> toJson() {
  var json = super.toJson();
  if (tenantId != null) {
    json['tenantId'] = tenantId!.toJson();
  }
  if (customerId != null) {
    json['customerId'] = customerId!.toJson();
  }
  json['title'] = title;
  if (image != null) {
    json['image'] = image;
  }
  json['assignedCustomers'] =
      assignedCustomers.map((e) => e.toJson()).toList();
  if (mobileHide != null) {
    json['mobileHide'] = mobileHide;
  }
  if (mobileOrder != null) {
    json['mobileOrder'] = mobileOrder;
  }
  return json;
}