修复table systeminfo not found错误
This commit is contained in:
parent
47b43d4013
commit
71b617e754
@ -200,12 +200,13 @@ namespace Inotify.Data
|
|||||||
{
|
{
|
||||||
|
|
||||||
var codeVersion = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version;
|
var codeVersion = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version;
|
||||||
var migrationBuilder = new MigrationBuilder(MigrationName, DBase);
|
|
||||||
var versionProvider = new DatabaseCurrentVersionProvider(DBase);
|
var versionProvider = new DatabaseCurrentVersionProvider(DBase);
|
||||||
|
|
||||||
if (!m_migrator.TableExists<SystemInfo>())
|
if (!m_migrator.TableExists<SystemInfo>())
|
||||||
{
|
{
|
||||||
|
var migrationBuilder = new MigrationBuilder(MigrationName, DBase);
|
||||||
migrationBuilder.Append(new Version(codeVersion.ToString()), new LatestMigration());
|
migrationBuilder.Append(new Version(codeVersion.ToString()), new LatestMigration());
|
||||||
|
migrationBuilder.Execute();
|
||||||
versionProvider.SetMigrationVersion(MigrationName, new Version(codeVersion.ToString()));
|
versionProvider.SetMigrationVersion(MigrationName, new Version(codeVersion.ToString()));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -6,8 +6,8 @@
|
|||||||
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
|
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
|
||||||
<StartupObject>Inotify.Program</StartupObject>
|
<StartupObject>Inotify.Program</StartupObject>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<AssemblyVersion>2.1.0.0</AssemblyVersion>
|
<AssemblyVersion>2.2.0.0</AssemblyVersion>
|
||||||
<FileVersion>2.1.0.0</FileVersion>
|
<FileVersion>2.2.0.0</FileVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
|
||||||
|
Loading…
Reference in New Issue
Block a user