R31356-1 Work Order- Set Due Date

Code 31356-1
Entity Production.ShopFloor.WorkOrders Entity
Name SetDueDate
Attribute DueDate
Layer Front-End
Events AttributeChanged(DocumentDate)
Priority Normal
Modify YES
Applicable Legislations ALL // no condition needed
Action if (DocumentDateNewValue != null) { if (DocumentDateOldValue == null OR DueDate == DocumentDateOldValue)

DueDate = DocumentDate; else if (DueDate != null AND DocumentDate > DueDate)

DueDate = DueDate.Add(DocumentDateNewValue - DocumentDateOldValue); }
Description When Document Date is changed, Due Date should be recalculated. If it has been equal to Document Date or empty, then Due Date should be changed to Document Date. If there has been a value for Due Date, it should be changed with the same difference as the Document Date has changed compared to its previous value.
Message
Version Introduced: 21

Updated: -
Revocable YES

* For more information about the Business Rules Documentation Template and a short explanation of each column, see topic System Business Rules.