diff --git a/LoggingClient/LoggingClient/Model/LogModel.cs b/LoggingClient/LoggingClient/Model/LogModel.cs index d8b30a2..f2e67ed 100644 --- a/LoggingClient/LoggingClient/Model/LogModel.cs +++ b/LoggingClient/LoggingClient/Model/LogModel.cs @@ -14,11 +14,11 @@ namespace LoggingClient.Model public string pod { get; set; } public string location { get; set; } public string hostname { get; set; } - public string severity { get; set; } + public int severity { get; set; } public DateTime timestamp { get; set; } public string message { get; set; } - public LogModel(int id, string pod, string location, string hostname, string severity, DateTime timestamp, string message) + public LogModel(int id, string pod, string location, string hostname, int severity, DateTime timestamp, string message) { this.id = id; this.pod = pod; diff --git a/LoggingClient/LoggingClient/ViewModel/LogViewModel.cs b/LoggingClient/LoggingClient/ViewModel/LogViewModel.cs index dfe3321..fefa987 100644 --- a/LoggingClient/LoggingClient/ViewModel/LogViewModel.cs +++ b/LoggingClient/LoggingClient/ViewModel/LogViewModel.cs @@ -150,7 +150,7 @@ namespace LoggingClient.ViewModel reader.GetString("pod"), reader.GetString("location"), reader.GetString("hostname"), - reader.GetString("severity"), + reader.GetInt32("severity"), reader.GetDateTime("timestamp"), reader.GetString("message") )); @@ -160,7 +160,7 @@ namespace LoggingClient.ViewModel } catch (Exception ex) { - MessageBox.Show("Error occurred: " + ex.Message); + //MessageBox.Show("Error occurred: " + ex.Message); } }