public int Insert(string Username, string Password, Account.RoleType Role) { string query = "INSERT Account (Username, Password, Role) OUTPUT INSERTED.ID VALUES ( @username , @password , @role )"; object result = DataProvider.GetInstance.ExecuteScalar(query, new object[] { Username, Password, (int)Role }); return(Convert.ToInt32(result)); }
public int Insert(string Username, string Password, Account.RoleType Role) { return(AccountDAO.Instance.Insert(Username, Password, Role)); }