This commit is contained in:
2023-01-02 23:48:18 +00:00
parent 86deb51481
commit 239a3c7c0c
2 changed files with 48 additions and 62 deletions

View File

@@ -89,6 +89,8 @@ namespace Sockeye.Api.Controllers
ret.Add(new KeyValuePair<string, string>(StringUtil.TrimTypeName(typeof(SockEvent).ToString()), "Event log object change types"));
ret.Add(new KeyValuePair<string, string>(StringUtil.TrimTypeName(typeof(SockDaysOfWeek).ToString()), "Days of the week"));
ret.Add(new KeyValuePair<string, string>(StringUtil.TrimTypeName(typeof(TrialRequestStatus).ToString()), "Trial license request status"));
ret.Add(new KeyValuePair<string, string>(StringUtil.TrimTypeName(typeof(ProductGroup).ToString()), "Product group"));
return Ok(ApiOkResponse.Response(ret));
}
@@ -573,6 +575,18 @@ namespace Sockeye.Api.Controllers
ReturnList.Add(new NameIdItem() { Name = LT["TrialRequestStatusApproved"], Id = (long)TrialRequestStatus.Approved });
ReturnList.Add(new NameIdItem() { Name = LT["TrialRequestStatusRejected"], Id = (long)TrialRequestStatus.Rejected });
}
else if (keyNameInLowerCase == StringUtil.TrimTypeName(typeof(ProductGroup).ToString()).ToLowerInvariant())
{
TranslationKeysToFetch.Add("ProductGroupMisc");
TranslationKeysToFetch.Add("ProductGroupAyaNova7");
TranslationKeysToFetch.Add("ProductGroupRavenPerpetual");
TranslationKeysToFetch.Add("ProductGroupRavenSubscription");
var LT = await TranslationBiz.GetSubsetStaticAsync(TranslationKeysToFetch, translationId);
ReturnList.Add(new NameIdItem() { Name = LT["ProductGroupMisc"], Id = (long)ProductGroup.Misc });
ReturnList.Add(new NameIdItem() { Name = LT["ProductGroupAyaNova7"], Id = (long)ProductGroup.AyaNova7 });
ReturnList.Add(new NameIdItem() { Name = LT["ProductGroupRavenPerpetual"], Id = (long)ProductGroup.RavenPerpetual });
ReturnList.Add(new NameIdItem() { Name = LT["ProductGroupRavenSubscription"], Id = (long)ProductGroup.RavenSubscription });
}

View File

@@ -20,7 +20,7 @@ namespace Sockeye.Util
/////////// CHANGE THIS ON NEW SCHEMA UPDATE ////////////////////
//!!!!WARNING: BE SURE TO UPDATE THE DbUtil::EmptyBizDataFromDatabaseForSeedingOrImportingAsync WHEN NEW TABLES ADDED!!!!
private const int DESIRED_SCHEMA_LEVEL = 16;
private const int DESIRED_SCHEMA_LEVEL = 17;
internal const long EXPECTED_COLUMN_COUNT = 502;
internal const long EXPECTED_INDEX_COUNT = 74;
@@ -1255,69 +1255,41 @@ $BODY$ LANGUAGE PLPGSQL STABLE");
}
/*
[KEY
//////////////////////////////////////////////////
//
// case 4173
//
if (currentSchema < 17)
{
"AyaNovaLicenseKey": {
"SchemaVersion": "7",
"Id": "1670002683",
"Created": "2022-12-02T09:38:03.5126283-08:00",
"Sub": "true",
"RegisteredTo": "CompCare Compressed Air Ltd",
"EmailAddress": "m.knowles@compcare-air.co.uk",
"FetchCode": "slAERKGVtq",
"Source": "5246494432",
"InstallableUntil": "2023-12-02T09:38:03.5125736-08:00",
"TotalScheduleableUsers": "10",
"Expires": "2023-12-02T00:00:00",
"RequestedTrial": "False",
"Plugins": {
"Plugin": [
{
"Item": "ExportToXls",
"SubscriptionExpires": "2023-12-02T00:00:00"
},
{
"Item": "RI - Responsive Interface",
"SubscriptionExpires": "2023-12-02T00:00:00"
}
]
}
}
LogUpdateMessage(log);
//english translations
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupMisc', 'Misc.' FROM atranslation t where t.baselanguage = 'en'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupAyaNova7', 'V7' FROM atranslation t where t.baselanguage = 'en'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenPerpetual', 'Raven perpetual' FROM atranslation t where t.baselanguage = 'en'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenSubscription', 'Raven subscription' FROM atranslation t where t.baselanguage = 'en'");
//spanish translations
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupMisc', 'Misc.' FROM atranslation t where t.baselanguage = 'es'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupAyaNova7', 'V7' FROM atranslation t where t.baselanguage = 'es'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenPerpetual', 'Raven perpetual' FROM atranslation t where t.baselanguage = 'es'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenSubscription', 'Raven subscription' FROM atranslation t where t.baselanguage = 'es'");
//french translations
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupMisc', 'Misc.' FROM atranslation t where t.baselanguage = 'fr'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupAyaNova7', 'V7' FROM atranslation t where t.baselanguage = 'fr'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenPerpetual', 'Raven perpetual' FROM atranslation t where t.baselanguage = 'fr'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenSubscription', 'Raven subscription' FROM atranslation t where t.baselanguage = 'fr'");
//german translations
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupMisc', 'Misc.' FROM atranslation t where t.baselanguage = 'de'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupAyaNova7', 'V7' FROM atranslation t where t.baselanguage = 'de'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenPerpetual', 'Raven perpetual' FROM atranslation t where t.baselanguage = 'de'");
await ExecQueryAsync("INSERT INTO atranslationitem(translationid,key,display) SELECT t.id, 'ProductGroupRavenSubscription', 'Raven subscription' FROM atranslation t where t.baselanguage = 'de'");
currentSchema = 17;
await SetSchemaLevelAsync(currentSchema);
}
KEY]
[SIGNATURE
c6duLfqPW0Cp7vnQ+6CON3rAUWtL8dVpUhoxb6SBXgin6FsYErYLGY5VNkOWGBrsZ04/VXqqkayCBmZuKS6TwD8ki636bZU0VlGituuSdnR3oUcXyNWubc8FXIo8pmZtigTw904uXnVdhSImV0rhNt9EHyprBqgFVq5j0QMePsJmu9tucqwSxVEcWOWAE7j6735AVQua3pyqVtT+j/qSzPSgaxojBG2OHlS/8qMFaKxVQVJ7uFyU5rzQ2CA2CDfusyTit3Bii7Xewm5AhMjxRCbLOp16wWbz5iIC3XZ37hR0+klN6NYvkipVLsL6f2Knf0TFUnt6oF0FwL3M7aSl+w==
SIGNATURE]
[KEY
{
"Key": {
"LicenseFormat": "8",
"Id": "1669501889",
"RegisteredTo": "Vicom Australia",
"DBID": "mZaliiy+/TsHF9rcMpIGWO20Q5FhPD1ZdnWO2cMKMW8=",
"Perpetual": true,
"LicenseExpiration": "5555-01-01T00:00:00",
"MaintenanceExpiration": "2023-11-25T00:00:00",
"Features": [
{
"Name": "ActiveInternalUsers",
"Count": 3
}
]
}
}
KEY]
[SIGNATURE
O4kbtlVvQnHusjYXw3ppdhfkuPV7J7tHys33OYkcSl/KXgIqMhNMwU8TfTt5zsYElMLT0UKPmCoUlBIFmbayHx46xT17qHGm0j4C7HH1FmEefxOrNPtOa7k2AJ4fJvZESZGAIVboOHA2EAATV8WIyTOXAtG2JhHWIN/NVjMK0SlFs+0wkdsmx+8BQ9oZvz19w3I9bnt6kBwIogMTV4NBHk0637TmgGiNMZAXP8g4n/FaMQEXjVXGK05iLMf0jz4HohLSFvx1tpbg65pQ8lJtrdSgiFAvl09WgkpKpFakXuO/xP6HcnkzLIFitB8VCiOzj81YtQ81jldUiig2QYf+IQ==
SIGNATURE]
*/