This commit is contained in:
2
.vscode/launch.json
vendored
2
.vscode/launch.json
vendored
@@ -51,7 +51,7 @@
|
||||
"AYANOVA_USE_URLS": "http://*:7575;",
|
||||
"AYANOVA_FOLDER_USER_FILES": "c:\\temp\\RavenTestData\\userfiles",
|
||||
"AYANOVA_FOLDER_BACKUP_FILES": "c:\\temp\\RavenTestData\\backupfiles",
|
||||
"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\\PostgreSQLPortable_12.0\\App\\PgSQL\\bin\\"
|
||||
|
||||
@@ -68,6 +68,8 @@ namespace AyaNova.Models
|
||||
public virtual DbSet<WorkOrderTemplateItem> WorkOrderTemplateItem { get; set; }
|
||||
|
||||
|
||||
public virtual DbSet<Logo> Logo { get; set; }
|
||||
|
||||
//Note: had to add this constructor to work with the code in startup.cs that gets the connection string from the appsettings.json file
|
||||
//and commented out the above on configuring
|
||||
public AyContext(DbContextOptions<AyContext> options) : base(options)
|
||||
|
||||
21
server/AyaNova/models/Logo.cs
Normal file
21
server/AyaNova/models/Logo.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using AyaNova.Biz;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace AyaNova.Models
|
||||
{
|
||||
|
||||
public class Logo
|
||||
{
|
||||
public long Id { get; set; }
|
||||
public byte[] Large { get; set; }
|
||||
public byte[] Medium { get; set; }
|
||||
public byte[] Small { get; set; }
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -20,9 +20,9 @@ namespace AyaNova.Util
|
||||
/////////// CHANGE THIS ON NEW SCHEMA UPDATE ////////////////////
|
||||
|
||||
//!!!!WARNING: BE SURE TO UPDATE THE DbUtil::EmptyBizDataFromDatabaseForSeedingOrImporting WHEN NEW TABLES ADDED!!!!
|
||||
private const int DESIRED_SCHEMA_LEVEL = 12;
|
||||
private const int DESIRED_SCHEMA_LEVEL = 13;
|
||||
|
||||
internal const long EXPECTED_COLUMN_COUNT = 383;
|
||||
internal const long EXPECTED_COLUMN_COUNT = 387;
|
||||
internal const long EXPECTED_INDEX_COUNT = 139;
|
||||
|
||||
//!!!!WARNING: BE SURE TO UPDATE THE DbUtil::EmptyBizDataFromDatabaseForSeedingOrImporting WHEN NEW TABLES ADDED!!!!
|
||||
@@ -705,6 +705,19 @@ $BODY$;
|
||||
await SetSchemaLevelAsync(++currentSchema);
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////
|
||||
// LOGO table
|
||||
if (currentSchema < 13)
|
||||
{
|
||||
LogUpdateMessage(log);
|
||||
|
||||
await ExecQueryAsync("CREATE TABLE alogo (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, " +
|
||||
"large bytea, medium bytea, small bytea)");
|
||||
|
||||
await SetSchemaLevelAsync(++currentSchema);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user