public BolumController(IDBUsersService dBUsersService, IBolumService bolumService, IAltDepartmanService altDepartmanService, IDepartmanService departmanService, IDBUsersDepartmanService dBUsersDepartmanService, IDBUsersSirketService dBUsersSirketService, IDBUsersPanelsService dBUsersPanelsService, IDBUsersBolumService dBUsersBolum) { //user = CurrentSession.User; //if (user == null) //{ // user = new DBUsers(); //} _bolumService = bolumService; _dBUsersService = dBUsersService; _altDepartmanService = altDepartmanService; _departmanService = departmanService; _dBUsersPanelsService = dBUsersPanelsService; _dBUsersDepartmanService = dBUsersDepartmanService; _dBUsersSirketService = dBUsersSirketService; _dBUsersBolum = dBUsersBolum; dbDepartmanList = new List <int>(); dbPanelList = new List <int>(); dbSirketList = new List <int>(); foreach (var dbUserDepartmanNo in _dBUsersDepartmanService.GetAllDBUsersDepartman(x => x.Kullanici_Adi == user.Kullanici_Adi).Select(a => a.Departman_No)) { dbDepartmanList.Add((int)dbUserDepartmanNo); } foreach (var dbUserPanelNo in _dBUsersPanelsService.GetAllDBUsersPanels(x => x.Kullanici_Adi == user.Kullanici_Adi).Select(a => a.Panel_No)) { dbPanelList.Add((int)dbUserPanelNo); } foreach (var dbUserSirketNo in _dBUsersSirketService.GetAllDBUsersSirket(x => x.Kullanici_Adi == user.Kullanici_Adi).Select(a => a.Sirket_No)) { dbSirketList.Add((int)dbUserSirketNo); } permissionUser = _dBUsersService.GetAllDBUsers().Find(x => x.Kullanici_Adi == user.Kullanici_Adi); }
public OperatorDepartmanController(IDepartmanService departmanService, IDBUsersDepartmanService dBUsersDepartman, IAltDepartmanService altDepartmanService, IDBUsersAltDepartmanService dBUsersAltDepartmanService, IBolumService bolumService, IDBUsersBolumService dBUsersBolumService) { _departmanService = departmanService; _dBUsersDepartman = dBUsersDepartman; _altDepartmanService = altDepartmanService; _dBUsersAltDepartmanService = dBUsersAltDepartmanService; _bolumService = bolumService; _dBUsersBolumService = dBUsersBolumService; }