This commit is contained in:
@@ -1449,10 +1449,10 @@ namespace AyaNova.Biz
|
||||
if (haveTotal == false)
|
||||
{
|
||||
GrandTotal = await WorkorderGrandTotalAsync(oProposed.WorkOrderId, ct);
|
||||
haveTotal = true;
|
||||
|
||||
//Note: not a time delayed notification, however user could be flipping states quickly triggering multiple notifications that are in queue temporarily
|
||||
//so this will prevent that
|
||||
//Always clear any old ones for this object as they are all irrelevant the moment changed:
|
||||
//so this will prevent that:
|
||||
await NotifyEventHelper.ClearPriorEventsForObject(ct, AyaType.WorkOrder, oProposed.WorkOrderId, NotifyEventType.WorkorderTotalExceedsThreshold);
|
||||
}
|
||||
//Ok, we're here because there is a subscriber who is active and tags match so only check left is total against decvalue
|
||||
|
||||
@@ -170,6 +170,11 @@ namespace AyaNova.Biz
|
||||
if (ne.EventType == NotifyEventType.CustomerServiceImminent)
|
||||
TranslationKeysToFetch.Add("NotifyEventCustomerServiceImminentMessage");
|
||||
|
||||
if (ne.DecValue != 0)
|
||||
{
|
||||
TranslationKeysToFetch.Add("Total");
|
||||
}
|
||||
|
||||
//get translations
|
||||
var transid = await ct.UserOptions.AsNoTracking().Where(x => x.UserId == ne.UserId).Select(x => x.TranslationId).FirstOrDefaultAsync();
|
||||
var LT = await TranslationBiz.GetSubsetStaticAsync(TranslationKeysToFetch, transid);
|
||||
@@ -196,9 +201,9 @@ namespace AyaNova.Biz
|
||||
|
||||
|
||||
//DecValue (only for TheAndy for now workorder exceedsthreshold so not putting a lot of localization effort in; in app will localize properly)
|
||||
string DecDisplay= "";
|
||||
if(ne.DecValue!=0)
|
||||
DecDisplay=$"({ne.DecValue.ToString("N2", System.Globalization.CultureInfo.InvariantCulture)})\n";
|
||||
string DecDisplay = "";
|
||||
if (ne.DecValue != 0)
|
||||
DecDisplay = $"({LT["Total"]}: {ne.DecValue.ToString("N2", System.Globalization.CultureInfo.InvariantCulture)})\n";
|
||||
|
||||
string subject = "";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user