cherrypick durchgeführt
This commit is contained in:
@@ -1,13 +1,15 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<configuration>
|
<configuration>
|
||||||
<configSections>
|
<configSections>
|
||||||
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<section name="SanSystem.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
|
<section name="SanSystem.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
|
||||||
</sectionGroup>
|
</sectionGroup>
|
||||||
</configSections>
|
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
|
||||||
<startup>
|
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
|
||||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
</configSections>
|
||||||
</startup>
|
<startup>
|
||||||
|
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||||
|
</startup>
|
||||||
<runtime>
|
<runtime>
|
||||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
@@ -63,4 +65,16 @@
|
|||||||
</setting>
|
</setting>
|
||||||
</SanSystem.Properties.Settings>
|
</SanSystem.Properties.Settings>
|
||||||
</userSettings>
|
</userSettings>
|
||||||
|
<entityFramework>
|
||||||
|
<providers>
|
||||||
|
<provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" />
|
||||||
|
<provider invariantName="System.Data.SQLite.EF6" type="System.Data.SQLite.EF6.SQLiteProviderServices, System.Data.SQLite.EF6" />
|
||||||
|
</providers>
|
||||||
|
</entityFramework>
|
||||||
|
<system.data>
|
||||||
|
<DbProviderFactories>
|
||||||
|
<remove invariant="System.Data.SQLite.EF6" />
|
||||||
|
<add name="SQLite Data Provider (Entity Framework 6)" invariant="System.Data.SQLite.EF6" description=".NET Framework Data Provider for SQLite (Entity Framework 6)" type="System.Data.SQLite.EF6.SQLiteProviderFactory, System.Data.SQLite.EF6" />
|
||||||
|
<remove invariant="System.Data.SQLite" /><add name="SQLite Data Provider" invariant="System.Data.SQLite" description=".NET Framework Data Provider for SQLite" type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite" /></DbProviderFactories>
|
||||||
|
</system.data>
|
||||||
</configuration>
|
</configuration>
|
||||||
@@ -68,6 +68,8 @@ namespace Database
|
|||||||
//UpdateDatabase.GenerateNewBeziehungen();
|
//UpdateDatabase.GenerateNewBeziehungen();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
UpdateDatabase.CreateSQLiteDB();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,10 @@
|
|||||||
using KlassenBIB;
|
using FastMember;
|
||||||
|
using KlassenBIB;
|
||||||
using SanShared;
|
using SanShared;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Data;
|
||||||
|
using System.Data.SQLite;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
@@ -32,6 +35,61 @@ namespace Database
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void CreateSQLiteDB()
|
||||||
|
{
|
||||||
|
var source = Datenbank.Instance.TeufelDB;
|
||||||
|
|
||||||
|
|
||||||
|
// Auftraggber Datatable
|
||||||
|
DataTable dtauftraggeber = new DataTable();
|
||||||
|
|
||||||
|
// Verbindung zur SQLite herstellen
|
||||||
|
|
||||||
|
SQLiteConnection Connection = new SQLiteConnection("Data Source=datenbank.db;Version=3;");
|
||||||
|
|
||||||
|
|
||||||
|
SQLiteCommand Command = new SQLiteCommand("SELECT * FROM Auftraggeber", Connection);
|
||||||
|
SQLiteDataAdapter auftraggeberDA = new SQLiteDataAdapter();
|
||||||
|
//auftraggeberDA.SelectCommand = Command;
|
||||||
|
SQLiteCommandBuilder cmd = new SQLiteCommandBuilder(auftraggeberDA);
|
||||||
|
|
||||||
|
auftraggeberDA.SelectCommand = Command;
|
||||||
|
auftraggeberDA.InsertCommand = cmd.GetInsertCommand();
|
||||||
|
|
||||||
|
Connection.Open();
|
||||||
|
|
||||||
|
auftraggeberDA.Fill(dtauftraggeber);
|
||||||
|
|
||||||
|
DataTable srcdtAuftraggeber = new DataTable();
|
||||||
|
using (var reader = ObjectReader.Create(source.Auftraggeber, "Name", "Strasse", "Ort", "Ansprechpartner"))
|
||||||
|
{
|
||||||
|
srcdtAuftraggeber.Load(reader);
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach (DataRow s in srcdtAuftraggeber.Rows)
|
||||||
|
{
|
||||||
|
DataRow dr = dtauftraggeber.NewRow();
|
||||||
|
//dr.BeginEdit();
|
||||||
|
dr["Name"] = s["Name"];
|
||||||
|
dr["Strasse"] = s["Strasse"];
|
||||||
|
dr["Ort"] = s["Ort"];
|
||||||
|
dr["Ansprechpartner"] = s["Ansprechpartner"];
|
||||||
|
//dr.EndEdit();
|
||||||
|
|
||||||
|
dtauftraggeber.Rows.Add(dr);
|
||||||
|
|
||||||
|
}
|
||||||
|
// dtauftraggeber.AcceptChanges();
|
||||||
|
// auftraggeberDA.Update(dtauftraggeber);
|
||||||
|
|
||||||
|
DataTable dtimprägnierberichte = new DataTable();
|
||||||
|
using (var reader = ObjectReader.Create(source.Imprägnierungen))
|
||||||
|
{
|
||||||
|
dtimprägnierberichte.Load(reader);
|
||||||
|
}
|
||||||
|
|
||||||
|
Connection.Close();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public static void MakeNewDatabaseSystem()
|
public static void MakeNewDatabaseSystem()
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="..\packages\EntityFramework.6.4.4\build\EntityFramework.props" Condition="Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.props')" />
|
||||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
@@ -37,9 +38,18 @@
|
|||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Reference Include="EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\EntityFramework.6.4.4\lib\net45\EntityFramework.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="EntityFramework.SqlServer, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\EntityFramework.6.4.4\lib\net45\EntityFramework.SqlServer.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
<Reference Include="EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<Reference Include="EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
<EmbedInteropTypes>True</EmbedInteropTypes>
|
<EmbedInteropTypes>True</EmbedInteropTypes>
|
||||||
</Reference>
|
</Reference>
|
||||||
|
<Reference Include="FastMember, Version=1.5.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\FastMember.1.5.0\lib\net461\FastMember.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
<Reference Include="FluentFTP, Version=37.0.2.0, Culture=neutral, PublicKeyToken=f4af092b1d8df44f, processorArchitecture=MSIL">
|
<Reference Include="FluentFTP, Version=37.0.2.0, Culture=neutral, PublicKeyToken=f4af092b1d8df44f, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\FluentFTP.37.0.2\lib\net45\FluentFTP.dll</HintPath>
|
<HintPath>..\packages\FluentFTP.37.0.2\lib\net45\FluentFTP.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
@@ -110,7 +120,17 @@
|
|||||||
<HintPath>..\packages\Syncfusion.Tools.Windows.19.4.0.56\lib\net46\Syncfusion.Tools.Windows.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Tools.Windows.19.4.0.56\lib\net46\Syncfusion.Tools.Windows.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.ComponentModel.DataAnnotations" />
|
||||||
<Reference Include="System.Core" />
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Data.SQLite, Version=1.0.115.5, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.115.5\lib\net46\System.Data.SQLite.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System.Data.SQLite.EF6, Version=1.0.115.5, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\System.Data.SQLite.EF6.1.0.115.5\lib\net46\System.Data.SQLite.EF6.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System.Data.SQLite.Linq, Version=1.0.115.5, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\System.Data.SQLite.Linq.1.0.115.5\lib\net46\System.Data.SQLite.Linq.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
<Reference Include="System.Design" />
|
<Reference Include="System.Design" />
|
||||||
<Reference Include="System.Web" />
|
<Reference Include="System.Web" />
|
||||||
<Reference Include="System.Xaml" />
|
<Reference Include="System.Xaml" />
|
||||||
@@ -471,6 +491,9 @@
|
|||||||
<EmbeddedResource Include="UCWeitereFotos.resx">
|
<EmbeddedResource Include="UCWeitereFotos.resx">
|
||||||
<DependentUpon>UCWeitereFotos.cs</DependentUpon>
|
<DependentUpon>UCWeitereFotos.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
<None Include="datenbank.db">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
<None Include="documents\JUME\KalibrierungAuflistung.docx">
|
<None Include="documents\JUME\KalibrierungAuflistung.docx">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</None>
|
</None>
|
||||||
@@ -615,4 +638,14 @@
|
|||||||
<PostBuildEvent>
|
<PostBuildEvent>
|
||||||
</PostBuildEvent>
|
</PostBuildEvent>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||||
|
<PropertyGroup>
|
||||||
|
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
||||||
|
</PropertyGroup>
|
||||||
|
<Error Condition="!Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\EntityFramework.6.4.4\build\EntityFramework.props'))" />
|
||||||
|
<Error Condition="!Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\EntityFramework.6.4.4\build\EntityFramework.targets'))" />
|
||||||
|
<Error Condition="!Exists('..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.115.5\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.115.5\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets'))" />
|
||||||
|
</Target>
|
||||||
|
<Import Project="..\packages\EntityFramework.6.4.4\build\EntityFramework.targets" Condition="Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.targets')" />
|
||||||
|
<Import Project="..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.115.5\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets" Condition="Exists('..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.115.5\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets')" />
|
||||||
</Project>
|
</Project>
|
||||||
BIN
SanSystem/datenbank.db
Normal file
BIN
SanSystem/datenbank.db
Normal file
Binary file not shown.
@@ -1,7 +1,10 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
|
<package id="EntityFramework" version="6.4.4" targetFramework="net472" />
|
||||||
|
<package id="FastMember" version="1.5.0" targetFramework="net472" />
|
||||||
<package id="FluentFTP" version="37.0.2" targetFramework="net472" />
|
<package id="FluentFTP" version="37.0.2" targetFramework="net472" />
|
||||||
<package id="Newtonsoft.Json" version="13.0.1" targetFramework="net472" />
|
<package id="Newtonsoft.Json" version="13.0.1" targetFramework="net472" />
|
||||||
|
<package id="Stub.System.Data.SQLite.Core.NetFramework" version="1.0.115.5" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Chart.Base" version="19.4.0.56" targetFramework="net472" />
|
<package id="Syncfusion.Chart.Base" version="19.4.0.56" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Chart.Windows" version="19.4.0.56" targetFramework="net472" />
|
<package id="Syncfusion.Chart.Windows" version="19.4.0.56" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Compression.Base" version="19.4.0.56" targetFramework="net472" />
|
<package id="Syncfusion.Compression.Base" version="19.4.0.56" targetFramework="net472" />
|
||||||
@@ -23,4 +26,8 @@
|
|||||||
<package id="Syncfusion.SpellChecker.Base" version="19.4.0.56" targetFramework="net472" />
|
<package id="Syncfusion.SpellChecker.Base" version="19.4.0.56" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Tools.Base" version="19.4.0.56" targetFramework="net472" />
|
<package id="Syncfusion.Tools.Base" version="19.4.0.56" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Tools.Windows" version="19.4.0.56" targetFramework="net472" />
|
<package id="Syncfusion.Tools.Windows" version="19.4.0.56" targetFramework="net472" />
|
||||||
|
<package id="System.Data.SQLite" version="1.0.115.5" targetFramework="net472" />
|
||||||
|
<package id="System.Data.SQLite.Core" version="1.0.115.5" targetFramework="net472" />
|
||||||
|
<package id="System.Data.SQLite.EF6" version="1.0.115.5" targetFramework="net472" />
|
||||||
|
<package id="System.Data.SQLite.Linq" version="1.0.115.5" targetFramework="net472" />
|
||||||
</packages>
|
</packages>
|
||||||
Reference in New Issue
Block a user