diff --git a/KlassenBIB/Auftraggeber.cs b/KlassenBIB/Auftraggeber.cs
index d1886a8..e06e88d 100644
--- a/KlassenBIB/Auftraggeber.cs
+++ b/KlassenBIB/Auftraggeber.cs
@@ -1,4 +1,5 @@
-using System;
+using SanShared;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@@ -9,7 +10,7 @@ namespace KlassenBIB
///
///
///
- public class Auftraggeber
+ public class Auftraggeber :IAuftraggeber
{
///
///
diff --git a/KlassenBIB/InlinerSanierung.cs b/KlassenBIB/InlinerSanierung.cs
index 6f82e82..9a95c62 100644
--- a/KlassenBIB/InlinerSanierung.cs
+++ b/KlassenBIB/InlinerSanierung.cs
@@ -56,9 +56,9 @@ namespace KlassenBIB
///
///
///
+ /// Projekt
///
-
- public Hashtable MakeProtokoll(string destinationPath)
+ public Hashtable MakeProtokoll(string destinationPath, IProjekt projekt)
{
Hashtable grunddaten = new Hashtable()
{
@@ -101,14 +101,14 @@ namespace KlassenBIB
};
double LaengeGesamt = this.Inspektionsobjekt.Haltungslaenge + this.Inspektionsobjekt.Schachtlaenge;
-
- grunddaten["AG_Vorname"] = "";
+
+ grunddaten["AG_Vorname"] = projekt.Auftraggeber.Name;
grunddaten["KLP_Nummer"] = "";
grunddaten["KLP_Datum"] = DateTime.Now.ToShortDateString();
- grunddaten["AG_Ort"] = "";
- grunddaten["AG_Strasse"] = "";
- grunddaten["AG_Ansprechpartner"] = "";
+ grunddaten["AG_Ort"] = projekt.Auftraggeber.Ort;
+ grunddaten["AG_Strasse"] = projekt.Auftraggeber.Strasse;
+ grunddaten["AG_Ansprechpartner"] = projekt.Auftraggeber.Ansprechpartner;
grunddaten["BM_Ort"] = Inspektionsobjekt.OrtName;
grunddaten["BM_Strasse"] = Inspektionsobjekt.StrasseName;
grunddaten["BM_Schacht_von"] = Inspektionsobjekt.VonPunkt;
diff --git a/KlassenBIB/Projekt.cs b/KlassenBIB/Projekt.cs
index 3736576..3e06119 100644
--- a/KlassenBIB/Projekt.cs
+++ b/KlassenBIB/Projekt.cs
@@ -1,4 +1,5 @@
-using System;
+using SanShared;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@@ -12,7 +13,7 @@ namespace KlassenBIB
///
///
[ContentProperty("Objekte")]
- public class Projekt
+ public class Projekt :IProjekt
{
///
///
@@ -25,7 +26,7 @@ namespace KlassenBIB
///
///
///
- public Auftraggeber Auftraggeber { get; set; }
+ public IAuftraggeber Auftraggeber { get; set; }
///
///
///
diff --git a/SanShared/IAuftraggeber.cs b/SanShared/IAuftraggeber.cs
new file mode 100644
index 0000000..2c91104
--- /dev/null
+++ b/SanShared/IAuftraggeber.cs
@@ -0,0 +1,25 @@
+namespace SanShared
+{
+ ///
+ ///
+ ///
+ public interface IAuftraggeber
+ {
+ ///
+ ///
+ ///
+ string Name { get; set; }
+ ///
+ ///
+ ///
+ string Strasse { get; set; }
+ ///
+ ///
+ ///
+ string Ort { get; set; }
+ ///
+ ///
+ ///
+ string Ansprechpartner { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/SanShared/IMakeProtokol.cs b/SanShared/IMakeProtokol.cs
index f423bdf..37deeec 100644
--- a/SanShared/IMakeProtokol.cs
+++ b/SanShared/IMakeProtokol.cs
@@ -16,7 +16,8 @@ namespace SanShared
///
///
///
+ /// Projekt
///
- Hashtable MakeProtokoll(string destinationPath);
+ Hashtable MakeProtokoll(string destinationPath, IProjekt projekt);
}
}
diff --git a/SanShared/IProjekt.cs b/SanShared/IProjekt.cs
new file mode 100644
index 0000000..b6a676b
--- /dev/null
+++ b/SanShared/IProjekt.cs
@@ -0,0 +1,13 @@
+namespace SanShared
+{
+ ///
+ ///
+ ///
+ public interface IProjekt
+ {
+ ///
+ ///
+ ///
+ IAuftraggeber Auftraggeber { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/SanShared/SanShared.csproj b/SanShared/SanShared.csproj
index f394d1b..a790043 100644
--- a/SanShared/SanShared.csproj
+++ b/SanShared/SanShared.csproj
@@ -43,8 +43,10 @@
+
+
diff --git a/SanSystem/FrmAuftraggeberEdit.cs b/SanSystem/FrmAuftraggeberEdit.cs
index 83d535a..a3372b1 100644
--- a/SanSystem/FrmAuftraggeberEdit.cs
+++ b/SanSystem/FrmAuftraggeberEdit.cs
@@ -1,4 +1,5 @@
using KlassenBIB;
+using SanShared;
using System;
using System.Collections.Generic;
using System.ComponentModel;
@@ -19,7 +20,7 @@ namespace SanSystem
///
///
///
- public FrmAuftraggeberEdit(Auftraggeber auftraggeber)
+ public FrmAuftraggeberEdit(IAuftraggeber auftraggeber)
{
InitializeComponent();
txt_name.DataBindings.Add("Text", auftraggeber, "Name");
diff --git a/SanSystem/MassenStatistik.cs b/SanSystem/MassenStatistik.cs
index 78b8720..76a1d0c 100644
--- a/SanSystem/MassenStatistik.cs
+++ b/SanSystem/MassenStatistik.cs
@@ -32,7 +32,7 @@ namespace SanSystem
void BuildBericht(List list)
{
- Hashtable grundDaten = MakeProtokoll("");
+ Hashtable grundDaten = MakeProtokoll("",null);
DataTable inliner = getMassenTableInliner();
@@ -95,7 +95,7 @@ namespace SanSystem
frmOptions.ShowDialog();
}
- public Hashtable MakeProtokoll(string destinationPath)
+ public Hashtable MakeProtokoll(string destinationPath, IProjekt projekt)
{
Hashtable grundDaten = new Hashtable()
{
diff --git a/SanSystem/UCInliner.cs b/SanSystem/UCInliner.cs
index f91d405..4728792 100644
--- a/SanSystem/UCInliner.cs
+++ b/SanSystem/UCInliner.cs
@@ -307,7 +307,7 @@ namespace SanSystem
{
MessageBox.Show("Warnung, es wurden keine Daten von der Anlage geladen, Grafik konnte nicht erstellt werden");
}
- Hashtable hashtable = inliner.MakeProtokoll(destinationPath);
+ Hashtable hashtable = inliner.MakeProtokoll(destinationPath,Database.Datenbank.Instance.loadedProjekt);
DirectoryInfo directory = Directory.GetParent(destinationPath);
string speicherpfad = directory.FullName;
BerichtGen.FrmOptions options = new BerichtGen.FrmOptions("JUME", "liner_einbau.docx", speicherpfad,inliner.Inspektionsobjekt.Objektbezeichnung, hashtable, new List());
diff --git a/SanSystem/documents/JUME/liner_einbau.docx b/SanSystem/documents/JUME/liner_einbau.docx
index ab56059..7761f42 100644
Binary files a/SanSystem/documents/JUME/liner_einbau.docx and b/SanSystem/documents/JUME/liner_einbau.docx differ