This commit is contained in:
2021-07-09 20:25:50 +00:00
parent 95a51b2a4a
commit a676f3d9ac
3 changed files with 11 additions and 11 deletions

2
.vscode/launch.json vendored
View File

@@ -53,7 +53,7 @@
"AYANOVA_FOLDER_USER_FILES": "c:\\temp\\RavenTestData\\userfiles", "AYANOVA_FOLDER_USER_FILES": "c:\\temp\\RavenTestData\\userfiles",
"AYANOVA_FOLDER_BACKUP_FILES": "c:\\temp\\RavenTestData\\backupfiles", "AYANOVA_FOLDER_BACKUP_FILES": "c:\\temp\\RavenTestData\\backupfiles",
"AYANOVA_FOLDER_TEMPORARY_SERVER_FILES": "c:\\temp\\RavenTestData\\tempfiles", "AYANOVA_FOLDER_TEMPORARY_SERVER_FILES": "c:\\temp\\RavenTestData\\tempfiles",
"AYANOVA_SERVER_TEST_MODE": "true", "AYANOVA_SERVER_TEST_MODE": "false",
"AYANOVA_SERVER_TEST_MODE_SEEDLEVEL": "large", "AYANOVA_SERVER_TEST_MODE_SEEDLEVEL": "large",
"AYANOVA_SERVER_TEST_MODE_TZ_OFFSET": "-7", "AYANOVA_SERVER_TEST_MODE_TZ_OFFSET": "-7",
"AYANOVA_BACKUP_PG_DUMP_PATH": "C:\\data\\code\\postgres_13\\bin\\" "AYANOVA_BACKUP_PG_DUMP_PATH": "C:\\data\\code\\postgres_13\\bin\\"

View File

@@ -86,7 +86,7 @@ namespace AyaNova.DataList
FieldKey = "Project", FieldKey = "Project",
TKey = "Project", TKey = "Project",
UiFieldDataType = (int)UiFieldDataType.Text, UiFieldDataType = (int)UiFieldDataType.Text,
AType = (int)AyaType.User, AType = (int)AyaType.Project,
SqlIdColumnName = "aproject.id", SqlIdColumnName = "aproject.id",
SqlValueColumnName = "aproject.name" SqlValueColumnName = "aproject.name"
}); });

View File

@@ -232,7 +232,7 @@ namespace AyaNova.Util
await SeedCustomerAsync(log, 25); await SeedCustomerAsync(log, 25);
await SeedHeadOfficeAsync(log, 10); await SeedHeadOfficeAsync(log, 10);
await SeedVendorAsync(log, 10); await SeedVendorAsync(log, 10);
await SeedProjectAsync(log, 10); await SeedProjectAsync(log, 3);
await SeedServiceRateAsync(log, 5); await SeedServiceRateAsync(log, 5);
await SeedTravelRateAsync(log, 3); await SeedTravelRateAsync(log, 3);
await SeedUnitModelAsync(log, 10); await SeedUnitModelAsync(log, 10);
@@ -243,7 +243,7 @@ namespace AyaNova.Util
await SeedPartAsync(log, 20, 100); await SeedPartAsync(log, 20, 100);
await SeedPartAssemblyAsync(log, 5); await SeedPartAssemblyAsync(log, 5);
await SeedPurchaseOrderAsync(log, 20); await SeedPurchaseOrderAsync(log, 20);
await SeedWorkOrderAsync(log, 10); await SeedWorkOrderAsync(log, 25);
//PERF //PERF
watch.Stop(); watch.Stop();
@@ -287,7 +287,7 @@ namespace AyaNova.Util
await SeedCustomerAsync(log, 500); await SeedCustomerAsync(log, 500);
await SeedHeadOfficeAsync(log, 20); await SeedHeadOfficeAsync(log, 20);
await SeedVendorAsync(log, 50); await SeedVendorAsync(log, 50);
await SeedProjectAsync(log, 50); await SeedProjectAsync(log, 5);
await SeedServiceRateAsync(log, 10); await SeedServiceRateAsync(log, 10);
await SeedTravelRateAsync(log, 5); await SeedTravelRateAsync(log, 5);
await SeedUnitModelAsync(log, 20); await SeedUnitModelAsync(log, 20);
@@ -298,7 +298,7 @@ namespace AyaNova.Util
await SeedPartAsync(log, 100, 300); await SeedPartAsync(log, 100, 300);
await SeedPartAssemblyAsync(log, 5); await SeedPartAssemblyAsync(log, 5);
await SeedPurchaseOrderAsync(log, 30); await SeedPurchaseOrderAsync(log, 30);
await SeedWorkOrderAsync(log, 30); await SeedWorkOrderAsync(log, 75);
//PERF //PERF
watch.Stop(); watch.Stop();
@@ -352,7 +352,7 @@ namespace AyaNova.Util
await SeedCustomerAsync(log, 1000); await SeedCustomerAsync(log, 1000);
await SeedHeadOfficeAsync(log, 40); await SeedHeadOfficeAsync(log, 40);
await SeedVendorAsync(log, 100); await SeedVendorAsync(log, 100);
await SeedProjectAsync(log, 100); await SeedProjectAsync(log, 10);
await SeedServiceRateAsync(log, 20); await SeedServiceRateAsync(log, 20);
await SeedTravelRateAsync(log, 10); await SeedTravelRateAsync(log, 10);
await SeedUnitModelAsync(log, 40); await SeedUnitModelAsync(log, 40);
@@ -363,7 +363,7 @@ namespace AyaNova.Util
await SeedPartAsync(log, 200, 600); await SeedPartAsync(log, 200, 600);
await SeedPartAssemblyAsync(log, 5); await SeedPartAssemblyAsync(log, 5);
await SeedPurchaseOrderAsync(log, 50); await SeedPurchaseOrderAsync(log, 50);
await SeedWorkOrderAsync(log, 60); await SeedWorkOrderAsync(log, 150);
//PERF //PERF
watch.Stop(); watch.Stop();
@@ -418,7 +418,7 @@ namespace AyaNova.Util
await SeedCustomerAsync(log, 10000); await SeedCustomerAsync(log, 10000);
await SeedHeadOfficeAsync(log, 200); await SeedHeadOfficeAsync(log, 200);
await SeedVendorAsync(log, 500); await SeedVendorAsync(log, 500);
await SeedProjectAsync(log, 500); await SeedProjectAsync(log, 20);
await SeedServiceRateAsync(log, 100); await SeedServiceRateAsync(log, 100);
await SeedTravelRateAsync(log, 50); await SeedTravelRateAsync(log, 50);
await SeedUnitModelAsync(log, 200); await SeedUnitModelAsync(log, 200);
@@ -2515,7 +2515,7 @@ namespace AyaNova.Util
WorkOrder o = new WorkOrder(); WorkOrder o = new WorkOrder();
o.Notes = Fake.Lorem.Sentence(); o.Notes = Fake.Lorem.Sentence();
o.Tags = RandomTags(); o.Tags = RandomTags();
if (Fake.Random.Number(1, 3) == 2) if (Fake.Random.Bool())//50% have projects
o.ProjectId = Fake.Random.Long(1, TotalSeededProjects); o.ProjectId = Fake.Random.Long(1, TotalSeededProjects);
var tempDate = Fake.Date.Between(seedStartWindow, seedEndWindow); var tempDate = Fake.Date.Between(seedStartWindow, seedEndWindow);
var tempHour = Fake.Random.Int(9, 17);//9am to 5 pm (except some times may be in different dst state so this will be out by an hour for example depending on time of year and time zone in question) var tempHour = Fake.Random.Int(9, 17);//9am to 5 pm (except some times may be in different dst state so this will be out by an hour for example depending on time of year and time zone in question)
@@ -2562,7 +2562,7 @@ namespace AyaNova.Util
o.InternalReferenceNumber = "irf-" + Fake.Finance.Account(4); o.InternalReferenceNumber = "irf-" + Fake.Finance.Account(4);
o.ServiceDate = woDate; o.ServiceDate = woDate;
int woItemCount = Fake.Random.Int(2, 10); int woItemCount = Fake.Random.Int(1, 4);
for (int y = 0; y < woItemCount; y++) for (int y = 0; y < woItemCount; y++)
{ {
var woItem = new WorkOrderItem() var woItem = new WorkOrderItem()