Model and migration changes

This commit is contained in:
kdeng00
2024-06-20 17:12:10 -04:00
parent 5c913869b4
commit f3eccfd46e
32 changed files with 111 additions and 123 deletions
+3 -3
View File
@@ -61,11 +61,11 @@ public class SongController : BaseController
{
var context = new SongContext(_connectionString);
var song = context.RetrieveRecord(new Song{ SongID = id });
var song = context.RetrieveRecord(new Song{ Id = id });
Console.WriteLine("Here");
if (song.SongID != 0)
if (song.Id != 0)
return Ok(song);
else
return NotFound();
@@ -74,7 +74,7 @@ public class SongController : BaseController
[HttpPut("{id}")]
public IActionResult UpdateSong(int id, [FromBody] Song song)
{
song.SongID = id;
song.Id = id;
Console.WriteLine("Retrieving filepath of song");
_logger.LogInformation("Retrieving filepath of song");