toPutJson method
Converts the body data model to a JSON object for a PUT request.
This method should be implemented by subclasses to convert their specific data to a JSON object. It should only include properties that need to be sent in a PUT request.
Implementation
@override
Map<String, dynamic>? toPutJson() {
Map<String, dynamic> data = <String, dynamic>{};
data['email'] = email;
data['password'] = password;
data['name'] = name;
data['surname'] = surname;
data['phoneNumber'] = phoneNumber;
data['birthday'] = birthday;
data['gender'] = gender.toString().split('.').last;
data['companyName'] = companyName;
data['taxOffice'] = taxOffice;
data['taxNumber'] = taxNumber;
return data;
}