This commit is contained in:
@@ -9,22 +9,22 @@ using AyaNova.Models;
|
||||
namespace AyaNova.Biz
|
||||
{
|
||||
|
||||
//Prime the database with initial, minimum required data to boot and do things (manager account, translations)
|
||||
//Prime the database with initial, minimum required data to boot and do things (SuperUser account, translations)
|
||||
public static class PrimeData
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Prime the database with manager account
|
||||
/// Prime the database with SuperUser account
|
||||
/// </summary>
|
||||
public static async Task PrimeManagerAccount(AyContext ct)
|
||||
public static async Task PrimeSuperUserAccount(AyContext ct)
|
||||
{
|
||||
//get a db and logger
|
||||
//ILogger log = AyaNova.Util.ApplicationLogging.CreateLogger("PrimeData");
|
||||
User u = new User();
|
||||
u.Active = true;
|
||||
u.Name = "AyaNova Administrator";
|
||||
u.Name = "AyaNova SuperUser";
|
||||
u.Salt = Hasher.GenerateSalt();
|
||||
u.Login = "manager";
|
||||
u.Login = "superuser";
|
||||
u.Password = Hasher.hash(u.Salt, "l3tm3in");
|
||||
u.Roles = AuthorizationRoles.All;//AuthorizationRoles.BizAdminFull | AuthorizationRoles.OpsAdminFull | AuthorizationRoles.DispatchFull | AuthorizationRoles.InventoryFull;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user