/// <summary> /// Gets the user password of user. /// </summary> /// <param name="users">The users.</param> /// <returns>Dictionary<System.String, System.String>.</returns> public Dictionary <string, string> GetUserPasswordOfUser(UserSecrets users) { Dictionary <string, string> valuePairs = new Dictionary <string, string>(); foreach (var employee in users.employees) { valuePairs.Add(employee.UserID, employee.Password); } return(valuePairs); }
/// <summary> /// Gets the customer secret. /// </summary> /// <param name="users">The users.</param> /// <returns>Dictionary<System.String, EmployeeSecrets>.</returns> public Dictionary <string, EmployeeSecrets> GetCustomerSecret(UserSecrets users) { Dictionary <string, EmployeeSecrets> valuePairs = new Dictionary <string, EmployeeSecrets>(); foreach (EmployeeSecrets employee in users.employees) { valuePairs.Add(employee.UserID, employee); } return(valuePairs); }
/// <summary> /// Initializes a new instance of the <see cref="AuthenticateUser"/> class. /// </summary> public AuthenticateUser() { UserSecrets = CustomerSecrets.Count == 0 ? SharedMethods.LoadDataModel <UserSecrets>(XMLFilePath) : UserSecrets; CustomerSecrets = GetCustomerSecret(UserSecrets); }