copyWith method
Implementation
BonusModel copyWith({
int? id,
num? amount,
int? orderCount,
DateTime? activeFrom,
DateTime? activeTill,
DateTime? createdAt,
}) =>
BonusModel(
id: id ?? this.id,
amount: amount ?? this.amount,
orderCount: orderCount ?? this.orderCount,
activeFrom: activeFrom ?? this.activeFrom,
activeTill: activeTill ?? this.activeTill,
createdAt: createdAt ?? this.createdAt,
);