This commit is contained in:
@@ -168,7 +168,7 @@ namespace AyaNova.Util
|
||||
|
||||
//Add user table
|
||||
await ExecQueryAsync("CREATE TABLE auser (id BIGSERIAL PRIMARY KEY, active bool not null, name varchar(255) not null unique, " +
|
||||
"login text not null, password text not null, salt text not null, roles integer not null, translationid bigint not null REFERENCES atranslation (id), " +
|
||||
"login text not null, password text not null, salt text not null, roles integer not null, " +
|
||||
"dlkey text, dlkeyexpire timestamp, usertype integer not null, employeenumber varchar(255), notes text, customerid bigint, " +
|
||||
"headofficeid bigint, subvendorid bigint, customfields text, tags varchar(255) ARRAY)");
|
||||
|
||||
@@ -177,7 +177,7 @@ namespace AyaNova.Util
|
||||
|
||||
//Add user options table
|
||||
await ExecQueryAsync("CREATE TABLE auseroptions (id BIGSERIAL PRIMARY KEY, " +
|
||||
"userid bigint not null, languageoverride text, timezoneoverride text, currencyname text, hour12 bool not null, emailaddress text, uicolor varchar(12) not null default '#000000')");
|
||||
"userid bigint not null, translationid bigint not null REFERENCES atranslation (id), languageoverride text, timezoneoverride text, currencyname text, hour12 bool not null, emailaddress text, uicolor varchar(12) not null default '#000000')");
|
||||
|
||||
|
||||
//Prime the db with the default MANAGER account
|
||||
|
||||
@@ -582,7 +582,7 @@ namespace AyaNova.Util
|
||||
else
|
||||
u.Password = u.Login;
|
||||
u.Roles = roles;
|
||||
u.TranslationId = translationId;
|
||||
|
||||
u.UserType = userType;
|
||||
u.EmployeeNumber = "A-" + (454 + SeededUserCount).ToString() + "-Y";
|
||||
u.Notes = Fake.Lorem.Sentence();//Fake.Lorem.Paragraph(2);
|
||||
@@ -590,10 +590,11 @@ namespace AyaNova.Util
|
||||
u.Tags = RandomTags(Fake);
|
||||
//Children and relations
|
||||
u.UserOptions = new UserOptions();
|
||||
u.UserOptions.TranslationId = translationId;
|
||||
u.UserOptions.EmailAddress = p.Email.Replace("gmail.com", "helloayanova.com").Replace("hotmail.com", "helloayanova.com").Replace("yahoo.com", "helloayanova.com");
|
||||
u.UserOptions.Hour12 = true;
|
||||
u.UserOptions.CurrencyName = "USD";
|
||||
u.UserOptions.UiColor= Fake.Internet.Color();
|
||||
u.UserOptions.UiColor = Fake.Internet.Color();
|
||||
|
||||
|
||||
|
||||
@@ -625,7 +626,7 @@ namespace AyaNova.Util
|
||||
// WidgetBiz biz = WidgetBiz.GetBiz(ServiceProviderProvider.DBContext);
|
||||
|
||||
var f = new Bogus.Faker();
|
||||
|
||||
|
||||
|
||||
//RANDOM ROLES
|
||||
Array values = Enum.GetValues(typeof(UserType));
|
||||
|
||||
Reference in New Issue
Block a user