toJson method
Implementation
Map<String, dynamic> toJson() {
final json = <String, dynamic>{};
json[r'id'] = this.id;
json[r'name'] = this.name;
json[r'slug'] = this.slug;
if (this.description != null) {
json[r'description'] = this.description;
} else {
json[r'description'] = null;
}
if (this.logoUrl != null) {
json[r'logoUrl'] = this.logoUrl;
} else {
json[r'logoUrl'] = null;
}
json[r'role'] = this.role;
if (this.memberCount != null) {
json[r'memberCount'] = this.memberCount;
} else {
json[r'memberCount'] = null;
}
if (this.workspaceCount != null) {
json[r'workspaceCount'] = this.workspaceCount;
} else {
json[r'workspaceCount'] = null;
}
json[r'workspaces'] = this.workspaces;
json[r'createdAt'] = this.createdAt.toUtc().toIso8601String();
json[r'updatedAt'] = this.updatedAt.toUtc().toIso8601String();
return json;
}