class RegisterRequest {
  String email = "";
  String password = "";
  String username = "";
  String phone = "";
  String name = "";
  String userRole = "";
  String channelCode = "";
  String porOrgacode = "";
  bool isOtpRequired = false;

  RegisterRequest.empty()
      : this.email = "",
        this.password = "",
        this.username = "",
        this.phone = "",
        this.name = "",
        this.userRole = "",
        this.channelCode = "",
        this.porOrgacode = "",
        this.isOtpRequired = false;

  RegisterRequest({
    this.email = "",
    this.password = "",
    this.username = "",
    this.phone = "",
    this.name = "",
    this.userRole = "",
    this.channelCode = "",
    this.porOrgacode = "",
    this.isOtpRequired = false,
  });

  Map<String, dynamic> toMap() {
    return {
      'email': email,
      'password': password,
      'username': username,
      'phone': phone,
      'name': name,
      'userRole': userRole,
      'channelCode': channelCode,
      'porOrgacode': porOrgacode,
      'isOtpRequired': isOtpRequired,
    };
  }

  factory RegisterRequest.fromMap(Map<String, dynamic> map) {
    return RegisterRequest(
      email: map['email'],
      password: map['password'],
      username: map['username'],
      phone: map['phone'],
      name: map['name'],
      userRole: map['userRole'],
      channelCode: map['channelCode'],
      porOrgacode: map['porOrgacode'],
      isOtpRequired: map['isOtpRequired'],
    );
  }

  @override
  String toString() {
    return 'RegisterRequest{email: $email, password: $password, username: $username, phone: $phone, name: $name, userRole: $userRole, channelCode: $channelCode, porOrgacode: $porOrgacode, isOtpRequired: $isOtpRequired}';
  }


}
