This commit is contained in:
@@ -17,6 +17,8 @@ namespace AyaNova.Util
|
||||
{
|
||||
public int SeededUserCount = 0;
|
||||
public Faker Fake;
|
||||
//### FAKER BIG LIST OF ALL SOURCE DATA HERE:
|
||||
//https://github.com/bchavez/Bogus/blob/master/Source/Bogus/data/en.locale.json
|
||||
|
||||
public Seeder()
|
||||
{
|
||||
@@ -533,6 +535,7 @@ namespace AyaNova.Util
|
||||
|
||||
public HashSet<string> HashUserNames = new HashSet<string>();
|
||||
public HashSet<string> HashCompanyNames = new HashSet<string>();
|
||||
public HashSet<string> HashProjectNames = new HashSet<string>();
|
||||
|
||||
|
||||
private string[] TagSet = new[] { "red", "orange", "yellow", "green", "blue", "indigo", "violet", "brown", "black", "white", "silver", "gold", "fuchsia", "jade", "mauve", "purple", "quince", "xanthic", "zebra", "zone0", "zone1", "zone2", "zone3", "zone4", "zone5", "zone6", "zone7", "zone8", "zone9" };
|
||||
@@ -1103,7 +1106,11 @@ namespace AyaNova.Util
|
||||
for (int x = 0; x < count; x++)
|
||||
{
|
||||
Project o = new Project();
|
||||
o.Name = $"{Fake.Random.AlphaNumeric(8)}{x + 1}";
|
||||
do
|
||||
{
|
||||
var color = Fake.Commerce.Color();
|
||||
o.Name = $"{char.ToUpper(color[0]) + color.Substring(1)} {Fake.Address.StreetSuffix()}";
|
||||
} while (!HashProjectNames.Add(o.Name));
|
||||
o.AccountNumber = Fake.Finance.Account();
|
||||
o.Active = true;
|
||||
o.Notes = Fake.Lorem.Sentence();
|
||||
|
||||
Reference in New Issue
Block a user