What about creating your own session object, that overloads the delete to setting a deleted property to true?
But I agree, this feature would be really nice. On Thu, Feb 5, 2009 at 11:21 AM, Bart Reyserhove <[email protected]>wrote: > Hi group, > In our application most of the entities are not really deleted. We put a > deleted property on "true". > Before deleting something checks need to happen to verify whether it is > allowed to delete the entity. This can become a complex thing when entities > are referenced a lot from other places in the domain model. It is also > pretty dangerous because if you forget something in the check there will be > no delete database constraint kicking in because nothing is really deleted. > > It would be really cool if this could be solved in some generic way based > on the information NHibernate has on the associations. Does anyone have an > idea whether this can be done and how I would best approach this? > > Thanks, > > Bart > > > > -- Robin Nadeau, B.Eng. Software Developer --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "nhusers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~----------~----~----~----~------~----~------~--~---
