This commit is contained in:
2
.vscode/launch.json
vendored
2
.vscode/launch.json
vendored
@@ -53,7 +53,7 @@
|
||||
"AYANOVA_FOLDER_USER_FILES": "c:\\temp\\RavenTestData\\userfiles",
|
||||
"AYANOVA_FOLDER_BACKUP_FILES": "c:\\temp\\RavenTestData\\backupfiles",
|
||||
"AYANOVA_FOLDER_TEMPORARY_SERVER_FILES": "c:\\temp\\RavenTestData\\tempfiles",
|
||||
"AYANOVA_SERVER_TEST_MODE": "false",
|
||||
"AYANOVA_SERVER_TEST_MODE": "true",
|
||||
"AYANOVA_SERVER_TEST_MODE_SEEDLEVEL": "small",
|
||||
"AYANOVA_SERVER_TEST_MODE_TZ_OFFSET": "-7",
|
||||
"AYANOVA_BACKUP_PG_DUMP_PATH": "C:\\data\\code\\postgres_13\\bin\\"
|
||||
|
||||
@@ -60,38 +60,7 @@ namespace AyaNova.Biz
|
||||
}
|
||||
}
|
||||
|
||||
// ////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// //DUPLICATE
|
||||
// //
|
||||
// internal async Task<Customer> DuplicateAsync(long id)
|
||||
// {
|
||||
// Customer dbObject = await GetAsync(id, false);
|
||||
// if (dbObject == null)
|
||||
// {
|
||||
// AddError(ApiErrorCode.NOT_FOUND, "id");
|
||||
// return null;
|
||||
// }
|
||||
// Customer newObject = new Customer();
|
||||
// CopyObject.Copy(dbObject, newObject, "Wiki");
|
||||
// string newUniqueName = string.Empty;
|
||||
// bool NotUnique = true;
|
||||
// long l = 1;
|
||||
// do
|
||||
// {
|
||||
// newUniqueName = Util.StringUtil.UniqueNameBuilder(dbObject.Name, l++, 255);
|
||||
// NotUnique = await ct.Customer.AnyAsync(m => m.Name == newUniqueName);
|
||||
// } while (NotUnique);
|
||||
// newObject.Name = newUniqueName;
|
||||
// newObject.Id = 0;
|
||||
// newObject.Concurrency = 0;
|
||||
// await ct.Customer.AddAsync(newObject);
|
||||
// await ct.SaveChangesAsync();
|
||||
// await EventLogProcessor.LogEventToDatabaseAsync(new Event(UserId, newObject.Id, BizType, AyaEvent.Created), ct);
|
||||
// await SearchIndexAsync(newObject, true);
|
||||
// await TagBiz.ProcessUpdateTagsInRepositoryAsync(ct, newObject.Tags, null);
|
||||
// await HandlePotentialNotificationEvent(AyaEvent.Created, newObject);
|
||||
// return newObject;
|
||||
// }
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//GET
|
||||
|
||||
@@ -97,7 +97,7 @@ namespace AyaNova.Biz
|
||||
|
||||
Translation l = new Translation();
|
||||
l.Name = translationCode;
|
||||
|
||||
l.BaseLanguage=translationCode;
|
||||
l.Stock = true;
|
||||
l.CjkIndex = false;
|
||||
|
||||
|
||||
@@ -174,7 +174,7 @@ namespace AyaNova.Biz
|
||||
NotUnique = await ct.Translation.AnyAsync(z => z.Name == newUniqueName);
|
||||
} while (NotUnique);
|
||||
newObject.Name = newUniqueName;
|
||||
|
||||
newObject.BaseLanguage=dbObject.BaseLanguage;
|
||||
newObject.Stock = false;
|
||||
newObject.CjkIndex = false;
|
||||
foreach (TranslationItem i in dbObject.TranslationItems)
|
||||
|
||||
@@ -29,6 +29,8 @@ namespace AyaNova.Models
|
||||
|
||||
[Required]
|
||||
public string Name { get; set; }
|
||||
[Required]
|
||||
public string BaseLanguage { get; set; }
|
||||
public bool? Stock { get; set; }
|
||||
public bool CjkIndex { get; set; }
|
||||
|
||||
|
||||
@@ -22,17 +22,16 @@ namespace AyaNova.Util
|
||||
//!!!!WARNING: BE SURE TO UPDATE THE DbUtil::EmptyBizDataFromDatabaseForSeedingOrImportingAsync WHEN NEW TABLES ADDED!!!!
|
||||
private const int DESIRED_SCHEMA_LEVEL = 1;
|
||||
|
||||
internal const long EXPECTED_COLUMN_COUNT = 1262;
|
||||
internal const long EXPECTED_COLUMN_COUNT = 1263;
|
||||
internal const long EXPECTED_INDEX_COUNT = 144;
|
||||
internal const long EXPECTED_CHECK_CONSTRAINTS = 513;
|
||||
internal const long EXPECTED_CHECK_CONSTRAINTS = 514;
|
||||
internal const long EXPECTED_FOREIGN_KEY_CONSTRAINTS = 192;
|
||||
internal const long EXPECTED_VIEWS = 9;
|
||||
internal const long EXPECTED_ROUTINES = 2;
|
||||
|
||||
//!!!!WARNING: BE SURE TO UPDATE THE DbUtil::EmptyBizDataFromDatabaseForSeedingOrImportingAsync WHEN NEW TABLES ADDED!!!!
|
||||
|
||||
///////////////////////////////////////////////////////////////// C1262:I144:CC513:FC192:V9:R2
|
||||
|
||||
///////////////////////////////////////////////////////////////// C1263:I144:CC514:FC192:V9:R2
|
||||
|
||||
|
||||
/*
|
||||
@@ -466,7 +465,7 @@ $BODY$ LANGUAGE PLPGSQL STABLE");
|
||||
|
||||
|
||||
//create translation TEXT tables
|
||||
await ExecQueryAsync("CREATE TABLE atranslation (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL UNIQUE, stock BOOL, cjkindex BOOL default false)");
|
||||
await ExecQueryAsync("CREATE TABLE atranslation (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL UNIQUE, baselanguage TEXT NOT NULL, stock BOOL, cjkindex BOOL default false)");
|
||||
await ExecQueryAsync("CREATE TABLE atranslationitem (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, translationid BIGINT NOT NULL REFERENCES atranslation (id), key TEXT NOT NULL, display TEXT NOT NULL)");
|
||||
|
||||
|
||||
|
||||
@@ -227,7 +227,7 @@ namespace AyaNova.Util
|
||||
//Generate owner and lead tech
|
||||
await SeedUserAsync(log, 1, AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Inventory | AuthorizationRoles.OpsAdmin, UserType.Service);
|
||||
//Generate one office person / secretary
|
||||
await SeedUserAsync(log, 1, AuthorizationRoles.Service | AuthorizationRoles.Inventory | AuthorizationRoles.Accounting, UserType.NotService);
|
||||
await SeedUserAsync(log, 1, AuthorizationRoles.Service | AuthorizationRoles.Inventory | AuthorizationRoles.Accounting, UserType.NotService);
|
||||
await SeedVendorAsync(log, 10);
|
||||
await SeedUnitModelAsync(log, 10);
|
||||
await SeedCustomerAsync(log, 25);
|
||||
@@ -1644,7 +1644,19 @@ namespace AyaNova.Util
|
||||
gbiz.TaxPartPurchaseId = TCGoods;
|
||||
gbiz.TaxPartSaleId = TCGoods;
|
||||
gbiz.TaxRateSaleId = TCServices;
|
||||
gbiz.CustomerAllowCSR = true;
|
||||
gbiz.CustomerAllowNotifyCSRAccepted = true;
|
||||
gbiz.CustomerAllowNotifyCSRRejected = true;
|
||||
gbiz.CustomerAllowNotifyServiceImminent = true;
|
||||
gbiz.CustomerAllowNotifyWOCompleted = true;
|
||||
gbiz.CustomerAllowNotifyWOCreated = true;
|
||||
gbiz.CustomerAllowUserSettings = true;
|
||||
gbiz.CustomerAllowViewWO = false;
|
||||
gbiz.CustomerAllowWOWiki = false;
|
||||
|
||||
await biz.PutAsync(gbiz);
|
||||
ServerGlobalBizSettings.Initialize(gbiz, null);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1768,7 +1780,7 @@ namespace AyaNova.Util
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public HashSet<string> HashCompanyNames = new HashSet<string>();
|
||||
|
||||
private int TotalSeededCustomers = 0;
|
||||
|
||||
Reference in New Issue
Block a user