toJson method
Implementation
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = <String, dynamic>{};
data['id'] = id;
data['createdAt'] = createdAt;
if (campaign != null) {
data['campaign'] = campaign!.toJson();
}
if (customer != null) {
data['customer'] = customer!.toJson();
}
if (integration != null) {
data['integration'] = integration!.toJson();
}
if (order != null) {
data['order'] = order!.toJson();
}
if (product != null) {
data['product'] = product!.toJson();
}
if (stock != null) {
data['stock'] = stock!.toJson();
}
if (subStore != null) {
data['subStore'] = subStore!.toJson();
}
return data;
}