2023-09-20 11:52:30 +10:00
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
|
using Microsoft.Extensions.Logging;
|
|
|
|
|
|
using PARR.DAL.Context;
|
|
|
|
|
|
using PARR.DAL.Models;
|
|
|
|
|
|
using PARR.DAL.Services.Abstracts;
|
|
|
|
|
|
using PARR.DAL.Services.Interfaces;
|
|
|
|
|
|
|
|
|
|
|
|
namespace PARR.DAL.Services.Implementations
|
|
|
|
|
|
{
|
2023-09-20 14:48:58 +10:00
|
|
|
|
|
|
|
|
|
|
internal class WorkService : BaseService<Work>, IWorkService
|
2023-09-20 11:52:30 +10:00
|
|
|
|
{
|
|
|
|
|
|
private readonly DataContext dataContext;
|
2023-09-20 14:48:58 +10:00
|
|
|
|
private readonly ILogger<WorkService> logger;
|
2023-09-20 11:52:30 +10:00
|
|
|
|
|
2023-09-20 14:48:58 +10:00
|
|
|
|
public WorkService(DataContext dataContext, ILogger<WorkService> logger) : base(logger)
|
2023-09-20 11:52:30 +10:00
|
|
|
|
{
|
|
|
|
|
|
this.dataContext = dataContext;
|
|
|
|
|
|
this.logger = logger;
|
|
|
|
|
|
}
|
2023-09-20 14:48:58 +10:00
|
|
|
|
protected override DbSet<Work> EntitySet => dataContext.Works;
|
2023-09-20 11:52:30 +10:00
|
|
|
|
|
|
|
|
|
|
protected override DataContext EntitiContext => dataContext;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|