|
|
|
|
@ -184,6 +184,26 @@ int main()
|
|
|
|
|
string created_at = res->getString("created_at");
|
|
|
|
|
string category = res->getString("category");
|
|
|
|
|
string instrument = res->getString("instrument");
|
|
|
|
|
|
|
|
|
|
crow::json::wvalue songs;
|
|
|
|
|
int song_id = res->getInt("song_id");
|
|
|
|
|
string song_title = res->getString("title");
|
|
|
|
|
|
|
|
|
|
songs[0] = {
|
|
|
|
|
{"id", song_id},
|
|
|
|
|
{"title", song_title}
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
//crow::json::wvalue currentSong;
|
|
|
|
|
//currentSong["id"] = res->getInt("song_id");
|
|
|
|
|
//currentSong["title"] = res->getString("title");
|
|
|
|
|
|
|
|
|
|
//crow::json::wvalue currentSong = {
|
|
|
|
|
//{"id", res->getInt("song_id")},
|
|
|
|
|
//{"title", res->getString("title")}
|
|
|
|
|
//};
|
|
|
|
|
//songs.push_back(std::move(currentSong));
|
|
|
|
|
|
|
|
|
|
entries[i] = {
|
|
|
|
|
{"id", id},
|
|
|
|
|
{"description", description},
|
|
|
|
|
@ -191,7 +211,8 @@ int main()
|
|
|
|
|
{"comments", comments},
|
|
|
|
|
{"created_at", created_at},
|
|
|
|
|
{"category", category},
|
|
|
|
|
{"instrument", instrument}
|
|
|
|
|
{"instrument", instrument},
|
|
|
|
|
{"songs", songs}
|
|
|
|
|
};
|
|
|
|
|
i++;
|
|
|
|
|
}
|
|
|
|
|
|