Updates to logging and v1.0.3 release.
This commit is contained in:
@@ -9,6 +9,7 @@ using Newtonsoft;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using BodyshopPartner.Models;
|
||||
using ToastNotifications.Messages;
|
||||
|
||||
namespace BodyshopPartner.Utils
|
||||
{
|
||||
@@ -33,9 +34,31 @@ namespace BodyshopPartner.Utils
|
||||
|
||||
logger.Trace("Starting HTTP server...");
|
||||
hlog = HttpLogger;
|
||||
hlog("Starting HTTP server...");
|
||||
|
||||
//TODO As a part of the installer, add netsh http add urlacl url=http://+:1337/ user="Everyone
|
||||
HttpServer.ListenAsync(1337, System.Threading.CancellationToken.None, Route.OnHttpRequestAsync).Wait();
|
||||
try
|
||||
{
|
||||
HttpServer.ListenAsync(1337, System.Threading.CancellationToken.None, Route.OnHttpRequestAsync).Wait();
|
||||
hlog("ImEX Online connection server started...");
|
||||
}
|
||||
catch (Exception Ex)
|
||||
{
|
||||
logger.Fatal("Unable to start HTTP server. " + Ex.ToString());
|
||||
App.Current.Dispatcher.Invoke(() =>
|
||||
{
|
||||
string msg = "Unable to connect to ImEX Online Web App. Please ensure your firewall allows the connection.";
|
||||
hlog("ImEX Online connection server could not start. Please restart the partner to try again.");
|
||||
Utils.Notifications.notifier.ShowError(msg);
|
||||
bool AddedException = Utils.SquirrelAwareHelper.AddHttpExcetion();
|
||||
|
||||
//Growler.AddNotification(new Notification()
|
||||
//{
|
||||
// Title = Properties.Resources.Msg_NewJobUploaded,
|
||||
// Subtitle = item.Job?.ownr_fn?.Value + " " + item.Job?.ownr_ln?.Value + " | " + item.Job?.clm_no?.Value,
|
||||
// //Message = item.Job?.vehicle?.data?.v_model_yr?.Value + " " + item.Job?.vehicle?.data?.v_make_desc?.Value + " " + item.Job?.vehicle?.data?.v_model_desc?.Value
|
||||
//});
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
private static void HandleQbPost(System.Net.HttpListenerRequest req, System.Net.HttpListenerResponse res)
|
||||
|
||||
Reference in New Issue
Block a user