class paymentListByModeResponse {
  String? error;
  List<OrderList>? orderList;
  String? message;

  paymentListByModeResponse({this.error, this.orderList, this.message});

  paymentListByModeResponse.fromJson(Map<String, dynamic> json) {
    error = json['error'];
    if (json['order_list'] != null) {
      orderList = <OrderList>[];
      json['order_list'].forEach((v) {
        orderList!.add(new OrderList.fromJson(v));
      });
    }
    message = json['message'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['error'] = this.error;
    if (this.orderList != null) {
      data['order_list'] = this.orderList!.map((v) => v.toJson()).toList();
    }
    data['message'] = this.message;
    return data;
  }
}

class OrderList {
  String? attachment;
  String? paymentId;
  String? orderNumber;
  String? status;
  String? ename;
  String? aname;
  String? approvalEmployee;
  String? paymentType;
  String? refId;
  String? refType;
  String? refNo;
  String? approvalStatus;
  String? paymentDate;
  String? approvalEmpId;
  String? adjustedAmount;
  String? description;
  String? amount;
  String? datetime;

  OrderList(
      {this.attachment,
        this.paymentId,
        this.orderNumber,
        this.status,
        this.ename,
        this.aname,
        this.approvalEmployee,
        this.paymentType,
        this.refId,
        this.refType,
        this.refNo,
        this.approvalStatus,
        this.paymentDate,
        this.approvalEmpId,
        this.adjustedAmount,
        this.description,
        this.amount,
        this.datetime});

  OrderList.fromJson(Map<String, dynamic> json) {
    attachment = json['attachment'];
    paymentId = json['payment_id'];
    orderNumber = json['order_number'];
    status = json['status'];
    ename = json['ename'];
    aname = json['aname'];
    approvalEmployee = json['approval_employee'];
    paymentType = json['payment_type'];
    refId = json['ref_id'];
    refType = json['ref_type'];
    refNo = json['ref_no'];
    approvalStatus = json['approval_status'];
    paymentDate = json['payment_date'];
    approvalEmpId = json['approval_emp_id'];
    adjustedAmount = json['adjusted_amount'];
    description = json['description'];
    amount = json['amount'];
    datetime = json['datetime'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['attachment'] = this.attachment;
    data['payment_id'] = this.paymentId;
    data['order_number'] = this.orderNumber;
    data['status'] = this.status;
    data['ename'] = this.ename;
    data['aname'] = this.aname;
    data['approval_employee'] = this.approvalEmployee;
    data['payment_type'] = this.paymentType;
    data['ref_id'] = this.refId;
    data['ref_type'] = this.refType;
    data['ref_no'] = this.refNo;
    data['approval_status'] = this.approvalStatus;
    data['payment_date'] = this.paymentDate;
    data['approval_emp_id'] = this.approvalEmpId;
    data['adjusted_amount'] = this.adjustedAmount;
    data['description'] = this.description;
    data['amount'] = this.amount;
    data['datetime'] = this.datetime;
    return data;
  }
}
