-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Soft Delete enhancements #139
Comments
Can you provide more details please. I have a few doubts.
Is this correct? |
public interface IStateful
{
EntityState State { get; set; }
} |
So, we will have the 3 of them? ( this means that if I choose to use |
As I suggested, just |
Maybe on version 1.2 @hikalkan ? |
I am moving this to v1.2. However its subject to change (we may have more prioritized issues). |
Thinking on both design and business wide; should On both cases, if the entity is audited; all audition will be deleted also but I think it should be logged in somewhere that the |
I have been writing code to purge old records from the database that are marked as deleted. I used the Example.. using (_dataFilter.Disable<ISoftDelete>())
{
// this
await _bookRepository.DeleteAsync(x => x.IsDeleted);
// or this - which could implicitly disable ISoftDelete too?
await _bookRepository.HardDeleteAsync(x => x.IsDeleted);
// or even add an extra property like hardDelete
await _bookRepository.DeleteAsync(x => x.IsDeleted, hardDelete: true);
} |
Even we can consider to add an enum to all entities (like Active, InActive, Deleted) or define this enum property for SoftDelete
The text was updated successfully, but these errors were encountered: