mirror of
https://github.com/claunia/marechai.git
synced 2025-12-16 19:14:25 +00:00
20 lines
581 B
C#
20 lines
581 B
C#
|
|
using System.Threading.Tasks;
|
||
|
|
using Marechai.Database.Models;
|
||
|
|
using Microsoft.Extensions.Localization;
|
||
|
|
|
||
|
|
namespace Marechai.Services
|
||
|
|
{
|
||
|
|
public class MachinesService
|
||
|
|
{
|
||
|
|
readonly MarechaiContext _context;
|
||
|
|
readonly IStringLocalizer<MachinesService> _l;
|
||
|
|
|
||
|
|
public MachinesService(MarechaiContext context, IStringLocalizer<MachinesService> localizer)
|
||
|
|
{
|
||
|
|
_context = context;
|
||
|
|
_l = localizer;
|
||
|
|
}
|
||
|
|
|
||
|
|
public async Task<Machine> GetMachine(int id) => await _context.Machines.FindAsync(id);
|
||
|
|
}
|
||
|
|
}
|