class TankerTripsModel {

  String tanker_name = '';
  String address = '';
  String dbId = '';
  String driver_name = '';
  String status = '';
  String building_name = '';
  String water_source_location = '';
  String deliveredDate = '';

  /// ADD THESE
  String dateOfOrder = '';
  String time = '';
  String supplierName = '';
  String amount_paid = '';
  String amount_due = '';

  TankerTripsModel();

  factory TankerTripsModel.fromJson(
      Map<String, dynamic> json){

    TankerTripsModel rtvm =
    TankerTripsModel();

    rtvm.tanker_name =
        json['tankerName'] ?? '';

    rtvm.dbId =
        json['_id'] ?? '';

    /// FIX (you used wrong key)
    rtvm.address =
        json['address'] ?? '';

    rtvm.driver_name =
        json['delivery_agent'] ?? '';

    rtvm.status =
        json['orderStatus'] ?? '';

    rtvm.building_name =
        json['buildingName'] ?? '';

    rtvm.water_source_location =
        json['water_source_location'] ?? '';

    rtvm.deliveredDate =
        json['deliveredDate'] ?? '';

    /// ADD THESE
    rtvm.dateOfOrder =
        json['dateOfOrder'] ?? '';

    rtvm.time =
        json['time'] ?? '';

    rtvm.supplierName =
        json['supplierName'] ?? '';

    rtvm.amount_paid =
        json['amount_paid'] ?? '';

    rtvm.amount_due =
        json['amount_due'] ?? '';

    return rtvm;

  }

  Map<String, dynamic> toJson() => {

    "tankerName": tanker_name,

  };

}