public AuthorizationService(IPasswordGenerator passwordGenerator, MySQLUserRepository mySQLUserRepository) { this.passwordGenerator = passwordGenerator ?? throw new ArgumentNullException(nameof(passwordGenerator)); this.mySQLUserRepository = mySQLUserRepository ?? throw new ArgumentNullException(nameof(mySQLUserRepository)); }
public UsersDialog() { this.Build(); usersModel = new UsersModel(); usersModel.UsersUpdated += UsersModel_UsersUpdated; mySQLUserRepository = new MySQLUserRepository(new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService()); ConfigureDlg(); }
public AuthorizationService(IPasswordGenerator passwordGenerator, MySQLUserRepository mySQLUserRepository, IEmailParametersProvider emailParametersProvider) { _passwordGenerator = passwordGenerator ?? throw new ArgumentNullException(nameof(passwordGenerator)); _mySQLUserRepository = mySQLUserRepository ?? throw new ArgumentNullException(nameof(mySQLUserRepository)); _emailParametersProvider = emailParametersProvider ?? throw new ArgumentNullException(nameof(emailParametersProvider)); }
public UsersDialog(IInteractiveService interactiveService) { this.interactiveService = interactiveService ?? throw new ArgumentNullException(nameof(interactiveService)); this.Build(); usersModel = new UsersModel(); usersModel.UsersUpdated += UsersModel_UsersUpdated; mySQLUserRepository = new MySQLUserRepository(new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService()); ConfigureDlg(); }
public UserDialog() { this.Build(); mySQLUserRepository = new MySQLUserRepository(new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService()); User = new UserBase(); ConfigureDlg(); }
public UserDialog(int userId, IInteractiveService interactiveService) { this.interactiveService = interactiveService ?? throw new ArgumentNullException(nameof(interactiveService)); this.Build(); mySQLUserRepository = new MySQLUserRepository(new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService()); User = mySQLUserRepository.GetUser(userId); ConfigureDlg(); }
public EmployeeDlg(int id) { this.Build(); logger.Info("Загрузка информации о сотруднике..."); UoWGeneric = UnitOfWorkFactory.CreateForRoot <Employee>(id); mySQLUserRepository = new MySQLUserRepository(new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService()); this.authorizationService = new AuthorizationService( new PasswordGenerator(), new MySQLUserRepository( new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService())); ConfigureDlg(); }
public EmployeeDlg() { this.Build(); UoWGeneric = UnitOfWorkFactory.CreateWithNewRoot <Employee>(); mySQLUserRepository = new MySQLUserRepository(new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService()); this.authorizationService = new AuthorizationService( new PasswordGenerator(), new MySQLUserRepository( new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService())); TabName = "Новый сотрудник"; ConfigureDlg(); }
public EmployeeDlg(IUnitOfWorkGeneric <Employee> uow) { this.Build(); UoWGeneric = uow; if (!ServicesConfig.CommonServices.CurrentPermissionService.ValidatePresetPermission("can_change_trainee_to_driver")) { hiddenCategory.Add(EmployeeCategory.driver); hiddenCategory.Add(EmployeeCategory.forwarder); } mySQLUserRepository = new MySQLUserRepository(new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService()); this.authorizationService = new AuthorizationService( new PasswordGenerator(), new MySQLUserRepository( new MySQLProvider(new GtkRunOperationService(), new GtkQuestionDialogsInteractive()), new GtkInteractiveService())); ConfigureDlg(); }