private void SaveUserData() { List <UserOAuthenticationModel> users = new List <UserOAuthenticationModel>(); UserOAuthenticationModel userOAuthenticationModel = new UserOAuthenticationModel(); userOAuthenticationModel.IsAdmin = true; userOAuthenticationModel.UserName = "******"; userOAuthenticationModel.Password = "******"; userOAuthenticationModel.UserID = 1; users.Add(userOAuthenticationModel); // userOAuthenticationModel = new UserOAuthenticationModel(); //userOAuthenticationModel.IsAdmin = false; //userOAuthenticationModel.UserName = "******"; //userOAuthenticationModel.Password = "******"; //userOAuthenticationModel.UserID = 2; //users.Add(userOAuthenticationModel); foreach (var data in users) { _authenticationDB.SaveUserData(data); } }
private void SavetStudentData() { if (_saveAndUpdatestudentDetails != null) { _studentDB.SaveStudentData(_saveAndUpdatestudentDetails); UserOAuthenticationModel userOAuthentication = new UserOAuthenticationModel { IsAdmin = false, StudentID = _saveAndUpdatestudentDetails.StudentID, UserName = "******" + _saveAndUpdatestudentDetails.StudentID, Password = "******" }; _authenticationDB.SaveUserData(userOAuthentication); } }