Leaf Input and Submit

This commit is contained in:
2016-12-06 11:53:30 -05:00
parent a3b8b7a881
commit 6fd7e46f5d
74 changed files with 56144 additions and 1291 deletions
+11 -2
View File
@@ -20,7 +20,7 @@ namespace LeafWeb.WebCms.Services.PiscalQueue
{
DataService = dataService;
PiscalService = piscalService;
Logger = LogManager.GetLogger(GetType().Name);
Logger = LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
_retryPolicy =
Policy
@@ -60,7 +60,16 @@ namespace LeafWeb.WebCms.Services.PiscalQueue
ex.Message);
}
}
protected void PiscalWarningHandler(string warningMessage, LeafInput leafInput)
{
Logger.Warn(warningMessage);
// send admin an email
BackgroundJobEnqueueRetry<EmailNotificationService>(
email => email.SendAdministratorMessage($"LeafWeb: PiscalQueue {GetType().Name} Warning", warningMessage));
}
public void Dispose()
{
DataService.Dispose();