mirror of
https://gitlab.com/Hukuta47/cartrix.git
synced 2026-12-05 12:30:55 +00:00
Подлатал API и Web
This commit is contained in:
1 parent
ae561f8311
commit
34868984fb
26 files changed
+435
-104
No files matched your search
@@ -0,0 +1,22 @@
|
||||
using CartriX.Api.Interfaces;
|
||||
using CartriX.Shared.Classes;
|
||||
using CartriX.Shared.Models;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.EntityFrameworkCore.Migrations.Operations;
|
||||
|
||||
namespace CartriX.Api.Services
|
||||
{
|
||||
public class LocationService : ILocationService
|
||||
{
|
||||
private readonly AppDbContext _context;
|
||||
public LocationService(AppDbContext context)
|
||||
{
|
||||
_context = context;
|
||||
}
|
||||
public async Task<List<Location>> GetAll()
|
||||
{
|
||||
var query = await _context.Locations.Include(l => l.printers).ToListAsync();
|
||||
return query;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user