diff --git a/Tests/Tests.csproj b/Tests/Tests.csproj
index 5ac530b..8f090f7 100755
--- a/Tests/Tests.csproj
+++ b/Tests/Tests.csproj
@@ -49,11 +49,11 @@
True
- ..\packages\NLog.4.4.3\lib\net40\NLog.dll
+ ..\packages\NLog.4.4.12\lib\net40\NLog.dll
True
-
- ..\packages\NUnit.3.6.1\lib\net40\nunit.framework.dll
+
+ ..\packages\NUnit.3.8.1\lib\net40\nunit.framework.dll
True
diff --git a/Tests/packages.config b/Tests/packages.config
index 6ce6096..3ba2bfb 100755
--- a/Tests/packages.config
+++ b/Tests/packages.config
@@ -2,7 +2,7 @@
-
-
-
+
+
+
\ No newline at end of file
diff --git a/www/postreport.php b/www/postreport.php
index 4ec082c..75595fb 100644
--- a/www/postreport.php
+++ b/www/postreport.php
@@ -1,53 +1,52 @@
isSMTP();
-$mail->SMTPAuth = true;
-$mail->Host = 'nephrowiki.de';
-$mail->Username = 'zaareloaded@nephrowiki.de';
-$mail->Password = 'ooZ1eiJa';
-// $mail->SMTPSecure = 'tls';
-$mail->Port = 25;
+function sendMail() {
+ $to = 'dk@doktorkraus.de';
+ $headers = "From: \"zaaReloaded\" ";
+ $reportId = $_POST['report_id'];
+ $info = print_r( $_POST, true ); // this will be a string, not an array!
+ $body = <<From = 'zaareloaded@nephrowiki.de';
-$mail->FromName = 'zaaReloaded';
-$mail->addAddress('dk@doktorkraus.de');
-$mail->Subject = "[zaaReloaded] Exception $reportId";
+-----
-if ( $_POST['ccUser'] ) {
- $validMail = filter_var( $_POST['usersMail'], FILTER_VALIDATE_EMAIL );
- $validUser = filter_var( $_POST['usersName'], FILTER_SANITIZE_STRING );
- if ( $validUser ) {
- $validUser = "\"$validUser\" "; // space character deliberately placed
- };
- if ( $validMail ) {
- $mail->addCC($validMail, $validUser);
- };
-};
+Benutzerkommentar:
-$info = print_r( $_POST, true );
-
-$mail->Body = <<send())
-{
- // Must return the report ID to indicate success
- echo($reportId);
+ if ( $_POST['ccUser'] ) {
+ $validMail = filter_var( $_POST['usersMail'], FILTER_VALIDATE_EMAIL );
+ $validUser = filter_var( $_POST['usersName'], FILTER_SANITIZE_STRING );
+ if ( $validUser ) {
+ $validUser = "\"$validUser\" "; // space character deliberately placed
+ };
+ if ( $validMail ) {
+ $headers .= "\r\nCc: $validUser<$validMail>";
+ };
+ };
+ mail($to, "Exception report [$reportId]", $body, $headers);
}
-else
-{
- echo($mail->ErrorInfo);
+
+// =============================================================
+// Begin main script
+// =============================================================
+
+if (!isset($_POST['report_id'])) {
+ http_response_code(400);
+ exit;
}
+
+sendMail();
+// Return the report ID and the issue URL to signal all is well.
+$reportId = $_POST['report_id'];
+$load = "{\"ReportId\": \"$reportId\", \"IssueUrl\": \"https://www.doktorkraus.de/zaareloaded\"}";
+error_log( __FILE__ . ": Load = $load" );
+header('Content-Type: application/json');
+echo $load;
diff --git a/zaaReloaded2/ExceptionHandler/ExceptionViewModel.cs b/zaaReloaded2/ExceptionHandler/ExceptionViewModel.cs
index c58c365..c3a8668 100755
--- a/zaaReloaded2/ExceptionHandler/ExceptionViewModel.cs
+++ b/zaaReloaded2/ExceptionHandler/ExceptionViewModel.cs
@@ -83,7 +83,7 @@ namespace zaaReloaded2.ExceptionHandler
protected override string DevPath()
{
- return @"x:\Code\zaaReloaded2\zaaReloaded2\";
+ return @"x:\\Code\\zaaReloaded2\\zaaReloaded2\\";
}
protected override Bovender.UserSettings.UserSettingsBase UserSettings
diff --git a/zaaReloaded2/ExceptionHandler/SubmissionCompletedAction.cs b/zaaReloaded2/ExceptionHandler/SubmissionCompletedAction.cs
index 57ab932..e6696bc 100755
--- a/zaaReloaded2/ExceptionHandler/SubmissionCompletedAction.cs
+++ b/zaaReloaded2/ExceptionHandler/SubmissionCompletedAction.cs
@@ -34,12 +34,12 @@ namespace zaaReloaded2.ExceptionHandler
{
protected override Window CreateSuccessWindow()
{
- return Content.InjectInto();
+ return new SubmissionSuccessView();
}
protected override Window CreateFailureWindow()
{
- return Content.InjectInto();
+ return new SubmissionFailureView();
}
protected override Window CreateCancelledWindow()
diff --git a/zaaReloaded2/ExceptionHandler/SubmissionFailureView.xaml b/zaaReloaded2/ExceptionHandler/SubmissionFailureView.xaml
index 14679f4..95eb934 100755
--- a/zaaReloaded2/ExceptionHandler/SubmissionFailureView.xaml
+++ b/zaaReloaded2/ExceptionHandler/SubmissionFailureView.xaml
@@ -21,14 +21,14 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:l="clr-namespace:zaaReloaded2"
- SizeToContent="WidthAndHeight"
+ SizeToContent="Height" Width="540"
Title="Fehlerbericht versenden"
>
-
-
+
×
@@ -36,11 +36,13 @@
-
-
+
+
-
+
\ No newline at end of file
diff --git a/zaaReloaded2/ExceptionHandler/SubmissionProcessAction.cs b/zaaReloaded2/ExceptionHandler/SubmissionProcessAction.cs
index bd1e021..3d150d9 100755
--- a/zaaReloaded2/ExceptionHandler/SubmissionProcessAction.cs
+++ b/zaaReloaded2/ExceptionHandler/SubmissionProcessAction.cs
@@ -28,7 +28,7 @@ namespace zaaReloaded2.ExceptionHandler
{
protected override System.Windows.Window CreateView()
{
- return Content.InjectInto();
+ return new SubmissionProcessView();
}
}
}
diff --git a/zaaReloaded2/ExceptionHandler/SubmissionSuccessView.xaml b/zaaReloaded2/ExceptionHandler/SubmissionSuccessView.xaml
index f9a7465..3710869 100755
--- a/zaaReloaded2/ExceptionHandler/SubmissionSuccessView.xaml
+++ b/zaaReloaded2/ExceptionHandler/SubmissionSuccessView.xaml
@@ -21,14 +21,15 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:l="clr-namespace:zaaReloaded2"
- SizeToContent="WidthAndHeight"
+ SizeToContent="Height" Width="400"
Title="Fehlerbericht versenden"
>
-
-
+
✔
@@ -36,10 +37,10 @@
-
+
-
+
diff --git a/zaaReloaded2/packages.config b/zaaReloaded2/packages.config
index 981621f..9d45393 100755
--- a/zaaReloaded2/packages.config
+++ b/zaaReloaded2/packages.config
@@ -21,6 +21,6 @@
-
+
\ No newline at end of file
diff --git a/zaaReloaded2/zaaReloaded2.csproj b/zaaReloaded2/zaaReloaded2.csproj
index 26438d8..7ad0e63 100755
--- a/zaaReloaded2/zaaReloaded2.csproj
+++ b/zaaReloaded2/zaaReloaded2.csproj
@@ -140,7 +140,7 @@
- ..\packages\NLog.4.4.3\lib\net40\NLog.dll
+ ..\packages\NLog.4.4.12\lib\net40\NLog.dll
True
@@ -235,6 +235,7 @@
+