class PostUpload { String title; String thumbnail; String aspect; String campaignID; String path; PostUpload({ this.title, this.aspect, this.campaignID, this.path, this.thumbnail, }); PostUpload.fromJson(Map json) : title = json['title'], aspect = json['aspect'], campaignID = json['campaignID'], path = json['path'], thumbnail = json['thumbnail']; Map toJson() { final Map data = Map(); data['title'] = this.title; data['aspect'] = this.aspect; data['campaignID'] = this.campaignID; data['path'] = this.path; data['thumbnail'] = this.thumbnail; return data; } @override String toString() { return '{"title": "$title","aspect": "$aspect", "campaignID": "$campaignID","path": "$path",' + '"thumbnail": "$thumbnail"}'; } }