...moved into its own thread. My bad.
Is there an official best practice for managing a parent entity's deleted status?
So if I have an Order entity that has a collection of orderLineItem entities, I can let users delete line items by clicking delete. The app uses the RemovedEntitiesTracker to hold them temporarily while we confirm delete or whatever.
But what about deleting the Order? I want to work with an Order entity in my UI, mark it for deletion and then actually clobber the database rows in my DAL. To do that, I need a way to temporarily mark it for deletion.
I'm not talking about storing isDeleted in the database, just in the business logic while we figure out if that is really what the user wants to do .
I know I can add an isDeleted flag to the template, but is there a better, officially recommended way to do this? isDirty and isNew are really useful. I was surprised to find that there is no corresponding isDeleted and that omission makes me wonder if I'm the one missing something.