private bool checkAdminInDB(AdminViewModel context) { DTOAdmin model = new DTOAdmin { Login = context.Login, Password = context.Password, PersonalKey = context.PersonalKey }; return(adminSevice.GetAdmin(model)); }
//If we have this acount on server flag will be true, if not - false public bool GetAdmin(DTOAdmin context) { Admin model = new Admin { Login = context.Login, Password = context.Password, PersonalKey = context.PersonalKey }; bool flag = uowAdmin.AdminRepository.GetAdmin(model); return(flag); }