Tasks 184281, 184799, 184800, 184801 and 184802
Align .editorconfig files Move Controller logic to DMO classes GlobalVars.AppSettings = Models.AppSettings.GetFromConfigurationManager(); Question EditorConfig Project level editorconfig Format White Spaces AppSetting when EnvironmentVariable not set Corrective Actions Tests Schedule Actions Tests DMO Tests Controller Tests Get ready to use VSCode IDE
This commit is contained in:
@ -1,37 +1,36 @@
|
||||
using Fab2ApprovalSystem.DMO;
|
||||
using Fab2ApprovalSystem.Misc;
|
||||
using Fab2ApprovalSystem.Models;
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using Fab2ApprovalSystem.DMO;
|
||||
using Fab2ApprovalSystem.Misc;
|
||||
|
||||
namespace Fab2ApprovalSystem.Controllers
|
||||
{
|
||||
[Authorize]
|
||||
[SessionExpireFilter]
|
||||
public class ManagerController : Controller
|
||||
{
|
||||
UserAccountDMO userDMO = new UserAccountDMO();
|
||||
AdminDMO adminDMO = new AdminDMO();
|
||||
TrainingDMO trainingDMO = new TrainingDMO();
|
||||
LotDispositionDMO ldDMO = new LotDispositionDMO();
|
||||
namespace Fab2ApprovalSystem.Controllers;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public ActionResult Index()
|
||||
{
|
||||
[Authorize]
|
||||
[SessionExpireFilter]
|
||||
public class ManagerController : Controller {
|
||||
|
||||
if ((bool)Session[GlobalVars.IS_MANAGER])
|
||||
{
|
||||
var model = userDMO.GetAllUsers();
|
||||
ViewBag.AllActiveUsers = userDMO.GetAllActiveUsers();
|
||||
return View(model);
|
||||
}
|
||||
else
|
||||
return Content("Not Autthorized");
|
||||
}
|
||||
UserAccountDMO userDMO = new UserAccountDMO();
|
||||
AdminDMO adminDMO = new AdminDMO();
|
||||
TrainingDMO trainingDMO = new TrainingDMO();
|
||||
LotDispositionDMO ldDMO;
|
||||
private readonly AppSettings _AppSettings;
|
||||
|
||||
public ManagerController(AppSettings appSettings) {
|
||||
_AppSettings = appSettings;
|
||||
ldDMO = new LotDispositionDMO(appSettings);
|
||||
}
|
||||
}
|
||||
|
||||
public ActionResult Index() {
|
||||
if ((bool)Session[GlobalVars.IS_MANAGER]) {
|
||||
var model = userDMO.GetAllUsers();
|
||||
ViewBag.AllActiveUsers = userDMO.GetAllActiveUsers();
|
||||
return View(model);
|
||||
} else
|
||||
return Content("Not Autthorized");
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user