toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  return {
    'user': user.value.toJson(),
    'sessionTOKEN': sessionTOKEN.value,
    'language': language.value,
    'widgetPosts': widgetPosts?.map((post) => post.toJson()).toList(),
    'widgetStoriescard':
        widgetStoriescard?.map((story) => story.toJson()).toList(),
    'lastsharingpost': lastsharingpost?.map((post) => post.toJson()).toList(),
    'gallery': gallery?.map((media) => media.toJson()).toList(),
    'xpcard': xpcard?.map((card) => card.toJson()).toList(),
    'popcard': popcard?.map((card) => card.toJson()).toList(),
    'chatList': chatList?.map((chat) => chat.toJson()).toList(),
    'newchatList': newchatList?.map((chat) => chat.toJson()).toList(),
    'newsList': newsList?.map((news) => news.toJson()).toList(),
    'searchList': searchList?.map((user) => user.toJson()).toList(),
    'notificationList': notificationList
        ?.map((notifications) => notifications.toJson())
        .toList(),
    'lastviewusersList':
        lastviewusersList?.map((user) => user.toJson()).toList(),
    'lastviewgroupsList':
        lastviewgroupsList?.map((group) => group.toJson()).toList(),
    'lastviewschoolsList':
        lastviewschoolsList?.map((school) => school.toJson()).toList(),
    'lastviewstationsList':
        lastviewstationsList?.map((station) => station.toJson()).toList(),
    'chatNotificationCount': chatNotificationCount.value,
    'surveyNotificationCount': surveyNotificationCount.value,
    'eventsNotificationCount': eventsNotificationCount.value,
    'downloadableCount': downloadableCount.value,
    'friendRequestCount': friendRequestCount.value,
    'groupInviteCount': groupInviteCount.value,
    'favoriteteams': favoriteteams?.map((team) => team.toJson()).toList(),
    'favTeam': favTeam,
    'favteamRequest': favteamRequest,
  };
}