AutoMapper / AutoMapper.Collection

AutoMapper support for updating existing collections by equivalency
MIT License
245 stars 59 forks source link

Feature: Persistence methods return mapped objects #119

Closed milkyware closed 2 years ago

milkyware commented 5 years ago

Hi,

Currently the persistence operations are voids meaning that, particularly for inserts, its difficult to see what the mapped object is as the creation in the dbset is all done for you and don't even know what the created Id is. If the InsertOrUpdate method returned it would make presenting what the final inserted/updated object looked like.

Thanks

TylerCarlson1 commented 5 years ago

You would have to call SaveChanges first before the ID would be generated.

I think it would make a EF proxy object and be updated after save changes if you were to return it.

A PR is always welcome.