//
 // Summary:
 //     Get an entity from database.
 // Return:
 //     The entity will be deleted in database.
 protected virtual TEntity GetDeleteEntity(IRpstBase <TEntity> repository, TCommand command)
 {
     return(repository.GetById(command.Model));
 }
Exemple #2
0
 //
 // Summary:
 //     Get an entity from database.
 // Return:
 //     The entity will be modified and updated to database.
 protected virtual async Task <TEntity> GetOldEntityAsync(IRpstBase <TEntity> repository, TCommand command)
 {
     return(repository.GetById(command.Model.Id));
 }