Beispiel #1
0
        public IActionResult AddSong(string id, string title, string playlistId)
        {
            var data    = new Db().GetData().FirstOrDefault(s => s.JukeBoxId == playlistId);
            var spotify = new Spotify();

            spotify.AddSong(id, data);
            ViewBag.Message = $"Success, '{title}' added";
            return(View("Search", new SearchModel()
            {
                Songs = new List <Song>(), PlaylistId = playlistId
            }));
        }