ปรับปรุงกระบวนการตรวจจับการ login
This commit is contained in:
@@ -16,30 +16,35 @@ namespace TodoAPI2.Controllers
|
||||
{
|
||||
private ILogger<eva_evaluation_achievementController> _logger;
|
||||
private Ieva_evaluation_achievementService _repository;
|
||||
private IConfiguration Configuration { get; set; }
|
||||
|
||||
private Iexternal_employeeService emp;
|
||||
private IConfiguration Configuration { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Default constructure for dependency injection
|
||||
/// </summary>
|
||||
/// <param name="repository"></param>
|
||||
/// <param name="configuration"></param>
|
||||
/// <param name="configuration"></param>
|
||||
/// <param name="logger"></param>
|
||||
public eva_evaluation_achievementViewController(ILogger<eva_evaluation_achievementController> logger, Ieva_evaluation_achievementService repository, IConfiguration configuration)
|
||||
/// <param name="inemp"></param>
|
||||
public eva_evaluation_achievementViewController(ILogger<eva_evaluation_achievementController> logger, Iexternal_employeeService inemp, Ieva_evaluation_achievementService repository, IConfiguration configuration)
|
||||
{
|
||||
_logger = logger;
|
||||
_repository = repository;
|
||||
Configuration = configuration;
|
||||
emp = inemp;
|
||||
}
|
||||
|
||||
public IActionResult eva_evaluation_achievement()
|
||||
{
|
||||
if (!MyHelper.checkAuth(Configuration, HttpContext)) return Unauthorized(); // Or UnauthorizedView
|
||||
MyHelper.get_login(HttpContext, emp, Response);
|
||||
if (!MyHelper.checkAuth(Configuration, HttpContext)) return Unauthorized(); // Or UnauthorizedView
|
||||
return View();
|
||||
}
|
||||
|
||||
public IActionResult eva_evaluation_achievement_d()
|
||||
{
|
||||
if (!MyHelper.checkAuth(Configuration, HttpContext)) return Unauthorized(); // Or UnauthorizedView
|
||||
MyHelper.get_login(HttpContext, emp, Response);
|
||||
if (!MyHelper.checkAuth(Configuration, HttpContext)) return Unauthorized(); // Or UnauthorizedView
|
||||
return View();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user