Closed paulocoutinhox closed 4 years ago
This is the current class for Song that i modify for use:
class Song { static final Columns=["id","artist", "title", "album", "albumId", "duration", "uri", "albumArt","count","isFav","timestamp"]; int id; String artist; String title; String album; int albumId; int duration; String uri; String albumArt; int count; int timestamp; int isFav; Song(this.id, this.artist, this.title, this.album, this.albumId, this.duration, this.uri, this.albumArt); Song.fromMap(Map m) { id = m["id"]; artist = m["artist"]; title = m["title"]; album = m["album"]; albumId = m["albumId"]; duration = m["duration"]; uri = m["uri"]; albumArt = m["albumArt"]; } Map<String, dynamic> toMap() { Map params = <String, dynamic>{ "id": id, "artist": artist, "title": title, "album": album, "albumId": albumId, "duration": duration, "uri": uri, "albumArt": albumArt, "count": count, "timestamp": timestamp, "isFav": isFav, }; return params; } }
The project uses almost same class.
This is the current class for Song that i modify for use: