create missing client classes for further dev. and create missing fields for given db expectations
This commit is contained in:
parent
059c976091
commit
aff4a22de1
|
@ -74,6 +74,10 @@
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
</ApplicationDefinition>
|
</ApplicationDefinition>
|
||||||
|
<Compile Include="ServiceClasses\Exam.cs" />
|
||||||
|
<Compile Include="ServiceClasses\Origin.cs" />
|
||||||
|
<Compile Include="ServiceClasses\Origin_Exam.cs" />
|
||||||
|
<Compile Include="ServiceClasses\Result.cs" />
|
||||||
<Page Include="MainWindow.xaml">
|
<Page Include="MainWindow.xaml">
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
|
@ -87,7 +91,7 @@
|
||||||
<DesignTime>True</DesignTime>
|
<DesignTime>True</DesignTime>
|
||||||
<DependentUpon>Reference.svcmap</DependentUpon>
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="Doctor.cs" />
|
<Compile Include="ServiceClasses\Doctor.cs" />
|
||||||
<Compile Include="Global.cs" />
|
<Compile Include="Global.cs" />
|
||||||
<Compile Include="MainWindow.xaml.cs">
|
<Compile Include="MainWindow.xaml.cs">
|
||||||
<DependentUpon>MainWindow.xaml</DependentUpon>
|
<DependentUpon>MainWindow.xaml</DependentUpon>
|
||||||
|
@ -95,7 +99,7 @@
|
||||||
</Compile>
|
</Compile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Compile Include="Patient.cs" />
|
<Compile Include="ServiceClasses\Patient.cs" />
|
||||||
<Compile Include="Properties\AssemblyInfo.cs">
|
<Compile Include="Properties\AssemblyInfo.cs">
|
||||||
<SubType>Code</SubType>
|
<SubType>Code</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
@ -173,7 +177,6 @@
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Folder Include="ViewModel\" />
|
<Folder Include="ViewModel\" />
|
||||||
<Folder Include="View\" />
|
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
</Project>
|
</Project>
|
|
@ -158,63 +158,105 @@
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung1Ort" Margin="1" Grid.Column="5" Grid.Row="3" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung1Essen" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="3" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Ort" Margin="2,0,0,0" />
|
<TextBlock Text="Essen 1" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung2Restaurant" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="4" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung1Strasse" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="4" VerticalContentAlignment="Center">
|
||||||
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="Strasse 1" Margin="2,0,0,0" />
|
||||||
|
</StackPanel>
|
||||||
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
|
</xctk:WatermarkTextBox>
|
||||||
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung1Ort" Margin="1" Grid.Column="5" Grid.Row="4" VerticalContentAlignment="Center">
|
||||||
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="Ort 1" Margin="2,0,0,0" />
|
||||||
|
</StackPanel>
|
||||||
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
|
</xctk:WatermarkTextBox>
|
||||||
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung2Restaurant" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="5" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Restaurant 2" Margin="2,0,0,0" />
|
<TextBlock Text="Restaurant 2" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung2Ort" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="4" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung2Essen" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="5" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Ort" Margin="2,0,0,0" />
|
<TextBlock Text="Essen 2" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung3Restaurant" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="5" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung2Strasse" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="6" VerticalContentAlignment="Center">
|
||||||
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="Strasse 2" Margin="2,0,0,0" />
|
||||||
|
</StackPanel>
|
||||||
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
|
</xctk:WatermarkTextBox>
|
||||||
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung2Ort" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="6" VerticalContentAlignment="Center">
|
||||||
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="Ort 2" Margin="2,0,0,0" />
|
||||||
|
</StackPanel>
|
||||||
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
|
</xctk:WatermarkTextBox>
|
||||||
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung3Restaurant" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="7" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Restaurant 3" Margin="2,0,0,0" />
|
<TextBlock Text="Restaurant 3" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung3Ort" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="5" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung3Essen" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="7" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Ort" Margin="2,0,0,0" />
|
<TextBlock Text="Essen 3" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung4Restaurant" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="6" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung3Strasse" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="8" VerticalContentAlignment="Center">
|
||||||
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="Strasse 3" Margin="2,0,0,0" />
|
||||||
|
</StackPanel>
|
||||||
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
|
</xctk:WatermarkTextBox>
|
||||||
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung3Ort" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="8" VerticalContentAlignment="Center">
|
||||||
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="Ort 3" Margin="2,0,0,0" />
|
||||||
|
</StackPanel>
|
||||||
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
|
</xctk:WatermarkTextBox>
|
||||||
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung4Restaurant" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="9" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Restaurant 4" Margin="2,0,0,0" />
|
<TextBlock Text="Restaurant 4" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung4Ort" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="6" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung4Essen" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="9" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Ort" Margin="2,0,0,0" />
|
<TextBlock Text="Essen 4" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung5Restaurant" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="7" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung4Strasse" Margin="1" Padding="3,1" Grid.Column="4" Grid.Row="10" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Restaurant 5" Margin="2,0,0,0" />
|
<TextBlock Text="Strasse 4" Margin="2,0,0,0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</xctk:WatermarkTextBox.Watermark>
|
</xctk:WatermarkTextBox.Watermark>
|
||||||
</xctk:WatermarkTextBox>
|
</xctk:WatermarkTextBox>
|
||||||
<xctk:WatermarkTextBox x:Name="TextboxNahrung5Ort" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="7" VerticalContentAlignment="Center">
|
<xctk:WatermarkTextBox x:Name="TextboxNahrung4Ort" Margin="1" Padding="3,1" Grid.Column="5" Grid.Row="10" VerticalContentAlignment="Center">
|
||||||
<xctk:WatermarkTextBox.Watermark>
|
<xctk:WatermarkTextBox.Watermark>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock Text="Ort" Margin="2,0,0,0" />
|
<TextBlock Text="Ort" Margin="2,0,0,0" />
|
||||||
|
|
|
@ -27,7 +27,7 @@ namespace Client
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
// loading of dropdowns
|
// loading of dropdowns
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ButtonClose_Click(object sender, RoutedEventArgs e)
|
private void ButtonClose_Click(object sender, RoutedEventArgs e)
|
||||||
|
@ -52,31 +52,13 @@ namespace Client
|
||||||
TextboxPatientRegion.Text,
|
TextboxPatientRegion.Text,
|
||||||
TextboxPatientGeburtstag.Text
|
TextboxPatientGeburtstag.Text
|
||||||
);
|
);
|
||||||
newDoctor.CreateDoctor();
|
Result newResult = new Result(TextboxBakterienstamm.Text);
|
||||||
newPatient.CreatePatient();
|
//Origin newOrigin = new Origin();
|
||||||
|
|
||||||
|
Exam newExam = new Exam(newDoctor.CreateDoctor(),
|
||||||
String Bakterienstamm = TextboxBakterienstamm.Text;
|
newPatient.CreatePatient(),
|
||||||
String Nahrung1Restaurant = TextboxNahrung1Restaurant.Text;
|
newResult.CreateResult()
|
||||||
String Nahrung2Restaurant = TextboxNahrung2Restaurant.Text;
|
);
|
||||||
String Nahrung3Restaurant = TextboxNahrung3Restaurant.Text;
|
|
||||||
String Nahrung4Restaurant = TextboxNahrung4Restaurant.Text;
|
|
||||||
String Nahrung5Restaurant = TextboxNahrung5Restaurant.Text;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//try {
|
|
||||||
// Global.GlobalInstance.Service.WritePatient(p);
|
|
||||||
// //servize.WritePatient(p);
|
|
||||||
//} catch (Exception) {
|
|
||||||
// if (p.PatientId == 0) {
|
|
||||||
// LabelRueckmeldungsfeld.Content = "fehler id = 0, beim schreiben von Patient!";
|
|
||||||
// } else {
|
|
||||||
// LabelRueckmeldungsfeld.Content = "fehler id != 0, beim schreiben von Patient!";
|
|
||||||
// }
|
|
||||||
//}
|
|
||||||
//LabelRueckmeldungsfeld.Content = "erfolgreich Patient gespeichert";
|
|
||||||
//TextboxPatientName.Clear();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -86,30 +68,48 @@ namespace Client
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//private void TextChanged(object sender, KeyboardFocusChangedEventArgs e)
|
|
||||||
//{
|
|
||||||
// if (((TextBox)sender).Text.Length == 0)
|
|
||||||
// ((TextBox)sender).Text = ((TextBox)sender).Text.ToString();
|
|
||||||
//}
|
|
||||||
|
|
||||||
//private void TextInputs(object sender, EventArgs e)
|
|
||||||
//{
|
|
||||||
// if ((((TextBox)sender).Text) == (((TextBox)sender).Text))
|
|
||||||
// ((TextBox)sender).Text = string.Empty;
|
|
||||||
// ((TextBox)sender).SelectionStart = 1;
|
|
||||||
//}
|
|
||||||
|
|
||||||
//private void TextboxArztName_LostFocus(object sender, KeyboardFocusChangedEventArgs e) => TextChanged(sender, e);
|
|
||||||
|
|
||||||
//private void TextboxArztName_MouseDown(object sender, MouseButtonEventArgs e)
|
// aufbewahren für die integration von Id's in die FK Tabellenspalten:
|
||||||
//{
|
//try {
|
||||||
// TextInputs(sender, e);
|
// Global.GlobalInstance.Service.WritePatient(p);
|
||||||
// //TextboxArztName.Text = string.Empty;
|
// //servize.WritePatient(p);
|
||||||
//}
|
//} catch (Exception) {
|
||||||
//private void TextboxArztName_PreviewTextInput(object sender, TextCompositionEventArgs e)
|
// if (p.PatientId == 0) {
|
||||||
//{
|
// LabelRueckmeldungsfeld.Content = "fehler id = 0, beim schreiben von Patient!";
|
||||||
// TextInputs(sender, e);
|
// } else {
|
||||||
//}
|
// LabelRueckmeldungsfeld.Content = "fehler id != 0, beim schreiben von Patient!";
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//LabelRueckmeldungsfeld.Content = "erfolgreich Patient gespeichert";
|
||||||
|
//TextboxPatientName.Clear();
|
||||||
|
|
||||||
|
|
||||||
|
//private void TextChanged(object sender, KeyboardFocusChangedEventArgs e)
|
||||||
|
//{
|
||||||
|
// if (((TextBox)sender).Text.Length == 0)
|
||||||
|
// ((TextBox)sender).Text = ((TextBox)sender).Text.ToString();
|
||||||
|
//}
|
||||||
|
|
||||||
|
//private void TextInputs(object sender, EventArgs e)
|
||||||
|
//{
|
||||||
|
// if ((((TextBox)sender).Text) == (((TextBox)sender).Text))
|
||||||
|
// ((TextBox)sender).Text = string.Empty;
|
||||||
|
// ((TextBox)sender).SelectionStart = 1;
|
||||||
|
//}
|
||||||
|
|
||||||
|
//private void TextboxArztName_LostFocus(object sender, KeyboardFocusChangedEventArgs e) => TextChanged(sender, e);
|
||||||
|
|
||||||
|
//private void TextboxArztName_MouseDown(object sender, MouseButtonEventArgs e)
|
||||||
|
//{
|
||||||
|
// TextInputs(sender, e);
|
||||||
|
// //TextboxArztName.Text = string.Empty;
|
||||||
|
//}
|
||||||
|
//private void TextboxArztName_PreviewTextInput(object sender, TextCompositionEventArgs e)
|
||||||
|
//{
|
||||||
|
// TextInputs(sender, e);
|
||||||
|
//}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,11 +16,6 @@ namespace Client
|
||||||
public string Region { get; set; }
|
public string Region { get; set; }
|
||||||
public string DocType { get; set; }
|
public string DocType { get; set; }
|
||||||
|
|
||||||
public Doctor()
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// this is my doctor construcor
|
/// this is my doctor construcor
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -34,7 +29,8 @@ namespace Client
|
||||||
string plz,
|
string plz,
|
||||||
string ort,
|
string ort,
|
||||||
string region,
|
string region,
|
||||||
string doctype )
|
string doctype
|
||||||
|
)
|
||||||
{
|
{
|
||||||
FirstName = firstName;
|
FirstName = firstName;
|
||||||
LastName = lastName;
|
LastName = lastName;
|
||||||
|
@ -48,7 +44,7 @@ namespace Client
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This writes the doctor back to the service into the db
|
/// This writes the doctor back to the service into the db
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void CreateDoctor()
|
public int CreateDoctor()
|
||||||
{
|
{
|
||||||
// write doctor to wcf interface
|
// write doctor to wcf interface
|
||||||
EHEC_Service.Doctor mydoctor = new EHEC_Service.Doctor
|
EHEC_Service.Doctor mydoctor = new EHEC_Service.Doctor
|
||||||
|
@ -59,6 +55,7 @@ namespace Client
|
||||||
DoctorOrigin = DocType
|
DoctorOrigin = DocType
|
||||||
};
|
};
|
||||||
Global.GlobalInstance.Service.WriteDoctor(mydoctor);
|
Global.GlobalInstance.Service.WriteDoctor(mydoctor);
|
||||||
|
return mydoctor.DoctorId;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
|
@ -0,0 +1,35 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Client
|
||||||
|
{
|
||||||
|
public class Exam
|
||||||
|
{
|
||||||
|
public int DocID { get; set; }
|
||||||
|
public int PatientID { get; set; }
|
||||||
|
public int ResultID { get; set; }
|
||||||
|
public Exam(int docId,
|
||||||
|
int patientId,
|
||||||
|
int resultId
|
||||||
|
)
|
||||||
|
{
|
||||||
|
DocID = docId;
|
||||||
|
PatientID = patientId;
|
||||||
|
ResultID = resultId;
|
||||||
|
}
|
||||||
|
public int CreateExam()
|
||||||
|
{
|
||||||
|
EHEC_Service.Exam myExam = new EHEC_Service.Exam
|
||||||
|
{
|
||||||
|
DoctorId = DocID,
|
||||||
|
PatientId = PatientID,
|
||||||
|
Result_ResultId = ResultID
|
||||||
|
};
|
||||||
|
Global.GlobalInstance.Service.WriteExam(myExam);
|
||||||
|
return myExam.ExamId;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,43 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Client
|
||||||
|
{
|
||||||
|
public class Origin
|
||||||
|
{
|
||||||
|
public string RestaurantName { get; set; }
|
||||||
|
public string Foodtype { get; set; }
|
||||||
|
public string Street { get; set; }
|
||||||
|
public int Plz { get; set; }
|
||||||
|
public string City { get; set; }
|
||||||
|
public Origin(string restName,
|
||||||
|
string foodtype,
|
||||||
|
string street,
|
||||||
|
int plz,
|
||||||
|
string city
|
||||||
|
)
|
||||||
|
{
|
||||||
|
RestaurantName = restName;
|
||||||
|
Foodtype = foodtype;
|
||||||
|
Street = street;
|
||||||
|
Plz = plz;
|
||||||
|
City = city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int CreateOrigin()
|
||||||
|
{
|
||||||
|
EHEC_Service.Origin myorigin = new EHEC_Service.Origin
|
||||||
|
{
|
||||||
|
Name = RestaurantName,
|
||||||
|
Food = Foodtype,
|
||||||
|
Street = Street,
|
||||||
|
City = City,
|
||||||
|
};
|
||||||
|
Global.GlobalInstance.Service.WriteOrigin(myorigin);
|
||||||
|
return myorigin.OriginId;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,31 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Client.ServiceClasses
|
||||||
|
{
|
||||||
|
public class Origin_Exam
|
||||||
|
{
|
||||||
|
public int OriginOriginId;
|
||||||
|
public int ExamExamId;
|
||||||
|
public Origin_Exam(int originOriginId,
|
||||||
|
int examExamId
|
||||||
|
)
|
||||||
|
{
|
||||||
|
OriginOriginId = originOriginId;
|
||||||
|
ExamExamId = examExamId;
|
||||||
|
}
|
||||||
|
public int CreateOrigin_Exam()
|
||||||
|
{
|
||||||
|
EHEC_Service.Origin_Exam myorigin_Exam = new EHEC_Service.Origin_Exam
|
||||||
|
{
|
||||||
|
OriginOriginId = OriginOriginId,
|
||||||
|
ExamExamId = ExamExamId
|
||||||
|
};
|
||||||
|
//Global.GlobalInstance.Service.W
|
||||||
|
return myorigin_Exam.Origin_ExamId;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -6,7 +6,7 @@ using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace Client
|
namespace Client
|
||||||
{
|
{
|
||||||
class Patient
|
public class Patient
|
||||||
{
|
{
|
||||||
public string FirstName { get; set; }
|
public string FirstName { get; set; }
|
||||||
public string LastName { get; set; }
|
public string LastName { get; set; }
|
||||||
|
@ -34,7 +34,7 @@ namespace Client
|
||||||
BirthDate = birthDate;
|
BirthDate = birthDate;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CreatePatient()
|
public int CreatePatient()
|
||||||
{
|
{
|
||||||
EHEC_Service.Patient mypatient = new EHEC_Service.Patient
|
EHEC_Service.Patient mypatient = new EHEC_Service.Patient
|
||||||
{
|
{
|
||||||
|
@ -46,6 +46,7 @@ namespace Client
|
||||||
BirthDate = Convert.ToDateTime(BirthDate)
|
BirthDate = Convert.ToDateTime(BirthDate)
|
||||||
};
|
};
|
||||||
Global.GlobalInstance.Service.WritePatient(mypatient);
|
Global.GlobalInstance.Service.WritePatient(mypatient);
|
||||||
|
return mypatient.PatientId;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -0,0 +1,27 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Client
|
||||||
|
{
|
||||||
|
public class Result
|
||||||
|
{
|
||||||
|
public string ResultName { get; set; }
|
||||||
|
|
||||||
|
public Result(string resultName)
|
||||||
|
{
|
||||||
|
ResultName = resultName;
|
||||||
|
}
|
||||||
|
public int CreateResult()
|
||||||
|
{
|
||||||
|
EHEC_Service.Result myResult = new EHEC_Service.Result
|
||||||
|
{
|
||||||
|
Name = ResultName
|
||||||
|
};
|
||||||
|
Global.GlobalInstance.Service.WriteResult(myResult);
|
||||||
|
return myResult.ResultId;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue