import 'package:intl/intl.dart';

class CustomerActivity {
  late int activityId;
  late int customerId;
  late String type;
  late DateTime? dateAdd;
  bool? skipped;

  CustomerActivity.fromJson(Map json) {
    activityId = json['activityId'];
    customerId = json['custoemrId'];
    type = json['type'];
    skipped = json['skipped'];
    dateAdd = DateTime.parse(json['dateAdd']);
  }

  Map<String, dynamic> toJson() => {
        'activityId': activityId,
        'customerId': customerId,
        'type': type,
        'skipped': skipped,
        "dateAdd": DateFormat('yyyy-MM-dd HH:mm:ss').format(dateAdd!),
      };

  @override
  String toString() {
    return toJson().toString();
  }
}