This commit is contained in:
astankovmi committed 2026-06-09 02:22:49 +03:00
1 parent c2c0c8d1ad
commit cb931df1b8
53 files changed
+15487 -38

No files matched your search

+14
View File
@@ -1,5 +1,6 @@
using Microsoft.AspNetCore.Http.HttpResults;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Strela.Models;
using Strela.Services;
@@ -66,4 +67,17 @@ public class DeviceController : ControllerBase
return Created();
}
}
//========================= DELETE ====================================//
[HttpDelete("DelType")]
public IActionResult DelType(int id)
{
using (var db = new SQLiteService())
{
var deldev = db.DeviceTypes.Where(u => u.Id == id).FirstOrDefault();
db.DeviceTypes.Remove(deldev);
db.SaveChanges();
return Ok();
}
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.