toJson method
Implementation
@override
Map<String, Object?> toJson() => {
'type': type.toJson(),
'profile': profile.toJson(),
'schedule': schedule.toJson(),
'activation': activation.toJson(),
'priority': priority,
if (coupon != null) 'coupon': coupon!.toJson(),
if (discount != null) 'discount': discount!.toJson(),
if (customData != null) 'custom_data': customData!.toJson(),
};