Ejemplo n.º 1
0
 public static void UpdateSystemAccount(this SystemAccount currentSystemAccount,
                                        string name, string logonName, string address, string notes, string hashedPassword,
                                        EnumSystemAccountType accountType)
 {
     currentSystemAccount.Name           = name;
     currentSystemAccount.LogonName      = logonName;
     currentSystemAccount.Address        = address;
     currentSystemAccount.Notes          = notes;
     currentSystemAccount.HashedPassword = hashedPassword;
     currentSystemAccount.AccountType    = accountType.ToString();
 }
Ejemplo n.º 2
0
 public static string GenerateSystemAccountID(EnumSystemAccountType accountType)
 {
     return(string.Format("{0}-{1}", accountType.ToString(), GenerateIDCode()));
 }
Ejemplo n.º 3
0
        public static SystemAccount CreateSystemAccount(string name,
                                                        string logonName, string address, string notes, string hashedPassword, EnumSystemAccountType accountType)
        {
            SystemAccount newSystemAccount = new SystemAccount();

            newSystemAccount.GUID           = IDGenerator.GenerateSystemAccountID(accountType);
            newSystemAccount.Name           = name;
            newSystemAccount.LogonName      = logonName;
            newSystemAccount.Address        = address;
            newSystemAccount.Notes          = notes;
            newSystemAccount.HashedPassword = hashedPassword;
            newSystemAccount.AccountType    = accountType.ToString();

            return(newSystemAccount);
        }