This commit is contained in:
@@ -509,76 +509,17 @@ todo:2 many biz objects are not using new PUT methodology
|
||||
########################################################################################################################
|
||||
|
||||
|
||||
CURRENTLY DOING: workorder* touches and fixups
|
||||
|
||||
Add back end rules as necessary for quotes
|
||||
|
||||
expose source PM in workorder data list so that can filter by that PM number and then mass delete if fucked up the generator
|
||||
OR EQUIVALENT, there *MUST* be a way to mass delete a PM gone wrong resulting in many wo
|
||||
Non copyable fields should not surface in PM??
|
||||
Like scheduser dates and loan dates and etc
|
||||
comment out, don't delete, might be useful later
|
||||
Need event log for generation and unique event so users can quickly see what the fuck is happenign without resorting to the server log
|
||||
CURRENTLY DOING:
|
||||
|
||||
Clean up notification for PM's and Quotes as they are filled with service wo shit
|
||||
Add NEW notifications related to errors and stop generating below
|
||||
Pore over quote and PM and look for workorder remnants, particularly biz actions and rules
|
||||
Error on generation should send a OPS notification?
|
||||
Or perhaps a notification to the service manager or ...??
|
||||
maybe someone subscribes to PM generation error notification??
|
||||
ding ding ding!
|
||||
Error on generation, should it set the PM inactive?
|
||||
Yes if it can notify the user and it doesn't fail for trivial reasons
|
||||
But, if it doesn't save a wo then it shouldn't matter if it reprocesses again, though it's wasting time if it does, on the other hand the user might fix something and expect it to go
|
||||
From v7:
|
||||
catch (Exception exx)
|
||||
{
|
||||
dest.Delete();
|
||||
dest.Save();
|
||||
//crack the exception
|
||||
while (exx.InnerException != null)
|
||||
exx = exx.InnerException;
|
||||
|
||||
Memo mwarn = Memo.NewItem();
|
||||
mwarn.ToID = User.AdministratorID;
|
||||
|
||||
//case 3826
|
||||
if (User.CurrentUserType == UserTypes.Utility)
|
||||
{
|
||||
//Utility accounts should not be sending memos, it fucks up downstream
|
||||
//trying to view the memo, also it's confusing
|
||||
mwarn.FromID = User.AdministratorID;
|
||||
}
|
||||
else
|
||||
{
|
||||
mwarn.FromID = User.CurrentThreadUserID;
|
||||
}
|
||||
|
||||
|
||||
mwarn.Subject = "SYSTEM WARNING: Preventive Maintenance WO PROBLEM";
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.AppendLine("This is an automated message sent on behalf of the current user from the \"NewServiceWorkorderFromPM\" module.");
|
||||
sb.AppendLine("This message concerns Preventive Maintenance workorder number " + source.WorkorderPreventiveMaintenance.PreventiveMaintenanceNumber.ToString());
|
||||
sb.AppendLine("The Preventive Maintenance workorder had an error when trying to save it during generation of a service workorder.");
|
||||
sb.AppendLine("This kind of problem could result in loop which generates a very large number of identical service workorders.");
|
||||
sb.AppendLine("In order to prevent this the operation has been stopped and this message generated so you can fix the problem with the source PM workorder.");
|
||||
sb.AppendLine("See below for details and examine the PM workorder for problems or contact support@ayanova.com for help with the information in this message.");
|
||||
sb.AppendLine("Here are the details of the error preventing save:");
|
||||
sb.AppendLine("=================================");
|
||||
sb.AppendLine("Exception saving source PM:");
|
||||
sb.AppendLine(exx.Message);
|
||||
sb.AppendLine("=================================");
|
||||
string sSourceErr = source.GetBrokenRulesString();
|
||||
if (!string.IsNullOrWhiteSpace(sSourceErr))
|
||||
{
|
||||
sb.AppendLine("Broken business rules on PM object:");
|
||||
sb.AppendLine(sSourceErr);
|
||||
sb.AppendLine("==============================");
|
||||
}
|
||||
mwarn.Message = sb.ToString();
|
||||
mwarn.Save();
|
||||
throw new System.ApplicationException("Workorder->NewServiceWorkorderFromPM: Error during service workorder generation. Memo with details sent to Administrator account.");
|
||||
|
||||
Notification when pm reaches stop generating date??
|
||||
Test generate threshold and etc
|
||||
Test with insufficient inventory on generation and add code to generate request automatically
|
||||
Add new event log event for generation and log it in standard event log
|
||||
Add new notification when pm reaches stop generating date??
|
||||
Add new notification when PM generation fails
|
||||
|
||||
test help links
|
||||
Child->grandchild data lists for quotes and pm's like workorders
|
||||
@@ -600,15 +541,14 @@ PM TODO:
|
||||
fix and add their own special ones
|
||||
|
||||
PM TESTING
|
||||
Test generate threshold and etc
|
||||
Test with insufficient inventory on generation
|
||||
|
||||
Test with crazy values and add sanity rules to prevent
|
||||
|
||||
|
||||
|
||||
todo MISC:
|
||||
new workorder state set by default from global settings?? (and on generate from pm or quote)
|
||||
generate new wo then go back goes to zero id new but then is stuck with error can't go back further due to broken rule
|
||||
CLIENT generate new wo then go back goes to zero id new but then is stuck with error can't go back further due to broken rule
|
||||
shouldn't it skip this one like the others do??
|
||||
shouldn't it not prompt if it's a not filled in new wo anyway??
|
||||
during Save of workorder it should not be available for entry as it can take some time to process and user could fuck off in the middle of it
|
||||
@@ -624,6 +564,13 @@ todo MISC:
|
||||
can a user even subscribe to any of these? Should they?
|
||||
|
||||
|
||||
|
||||
|
||||
============================
|
||||
|
||||
|
||||
|
||||
|
||||
EACH OBJECT DEV CYCLE:
|
||||
FIRST
|
||||
Check cases, make sure not changing the object fundamentally, many v7 objects are going to change for cases (particularly inventory related)
|
||||
|
||||
Reference in New Issue
Block a user