This commit is contained in:
@@ -25,6 +25,7 @@ namespace AyaNova.Biz
|
||||
{
|
||||
ct = dbcontext;
|
||||
UserId = currentUserId;
|
||||
UserLocaleId = userLocaleId;
|
||||
CurrentUserRoles = userRoles;
|
||||
BizType = AyaType.User;
|
||||
SeedOrImportRelaxedRulesMode = false;//default
|
||||
|
||||
@@ -507,8 +507,12 @@ namespace AyaNova.Util
|
||||
|
||||
|
||||
|
||||
public static void GenSeedUser(ILogger log, int count, AuthorizationRoles roles, UserType userType, decimal timeZoneOffset, bool active = true, string login = null, string password = null, long localeId = 0)
|
||||
public static void GenSeedUser(ILogger log, int count, AuthorizationRoles roles, UserType userType, decimal timeZoneOffset,
|
||||
bool active = true, string login = null, string password = null, long localeId = 0)
|
||||
{
|
||||
if (localeId == 0)
|
||||
localeId = ServerBootConfig.AYANOVA_DEFAULT_LANGUAGE_ID;
|
||||
|
||||
using (var cct = ServiceProviderProvider.DBContext)
|
||||
{
|
||||
UserBiz Biz = UserBiz.GetBizInternal(cct);
|
||||
@@ -538,7 +542,7 @@ namespace AyaNova.Util
|
||||
else
|
||||
u.Password = u.Login;
|
||||
u.Roles = roles;
|
||||
u.LocaleId = localeId == 0 ? ServerBootConfig.AYANOVA_DEFAULT_LANGUAGE_ID : localeId;
|
||||
u.LocaleId = localeId;
|
||||
u.UserType = userType;
|
||||
u.EmployeeNumber = "A-" + (454 + SeededUserCount).ToString() + "-Y";
|
||||
u.Notes = Fake.Lorem.Sentence();//Fake.Lorem.Paragraph(2);
|
||||
|
||||
Reference in New Issue
Block a user