Closed
Description
Hi,
I was trying add some data while registering user, but it doesn't work with DateTime object because DateTime does't has toJson method. And we have to send different format to parse than just DateTime in String.
I paste my solution below to save password to unsavedChanges and use existing method toJson from your library.
Instead of current code
final Map<String, dynamic> bodyData = _getObjectData();
bodyData[keyVarPassword] = password;
...
final String body = json.encode(bodyData);
I use this
_unsavedChanges[keyVarPassword] = password;
...
final String body = json.encode(toJson(forApiRQ: true));
With this body we can create parse user with all data.
Let me know if it's clear. If not I will come back with more info.
Metadata
Metadata
Assignees
Labels
No labels