toJSON method
Implementation
Map<String, dynamic> toJSON() {
AppConfig.logger.t("Profile toJSON");
return <String, dynamic> {
'id': id,
'name': name,
'position': jsonEncode(position),
'address': address,
'phoneNumber': phoneNumber,
'photoUrl': photoUrl,
'coverImgUrl': coverImgUrl,
'aboutMe': aboutMe,
'mainFeature': mainFeature,
'lastSpotifySync': lastSpotifySync,
'reviewStars': reviewStars,
'isActive': isActive,
'type': type.name,
'usageReason': usageReason.name,
'lastReview': lastReview?.toJSON() ?? Review().toJSON(),
'bannedGenres': bannedGenres,
'itemmates': itemmates,
'eventmates': eventmates,
'following': following,
'followers': followers,
'unfollowing': unfollowing,
'blockTo': blockTo,
'blockedBy': blockedBy,
'posts': posts,
'blogEntries': blogEntries,
'comments': comments,
'hiddenPosts': hiddenPosts,
'hiddenComments': hiddenComments,
'reports': reports,
'bands': bands,
'events': events,
'reviews': reviews,
'favoriteItems': favoriteItems,
// 'appMediaItems': appMediaItems,
'chamberPresets': chamberPresets,
'watchingEvents': watchingEvents,
'goingEvents': goingEvents,
'playingEvents': playingEvents,
'requests': requests,
'sentRequests': sentRequests,
'invitationRequests': invitationRequests,
'showInDirectory': showInDirectory,
'verificationLevel': verificationLevel.name,
'lastNameUpdate': lastNameUpdate,
};
}