mirror of
https://github.com/sphildreth/roadie
synced 2024-11-27 06:30:21 +00:00
31 lines
No EOL
978 B
C#
31 lines
No EOL
978 B
C#
using Mapster;
|
|
using Microsoft.AspNet.OData;
|
|
using Microsoft.Extensions.Configuration;
|
|
using Microsoft.Extensions.Logging;
|
|
using Roadie.Library.Caching;
|
|
using Roadie.Library.Configuration;
|
|
using Roadie.Library.Data;
|
|
|
|
namespace Roadie.Api.Controllers
|
|
{
|
|
public abstract class EntityControllerBase : ODataController
|
|
{
|
|
protected readonly ICacheManager _cacheManager;
|
|
protected readonly IConfiguration _configuration;
|
|
protected readonly IRoadieSettings _roadieSettings;
|
|
|
|
protected ILogger _logger;
|
|
|
|
protected IRoadieSettings RoadieSettings => this._roadieSettings;
|
|
|
|
public EntityControllerBase(ICacheManager cacheManager, IConfiguration configuration)
|
|
{
|
|
this._cacheManager = cacheManager;
|
|
this._configuration = configuration;
|
|
|
|
this._roadieSettings = new RoadieSettings();
|
|
this._configuration.GetSection("RoadieSettings").Bind(this._roadieSettings);
|
|
|
|
}
|
|
}
|
|
} |