public void Create(DoorDto config) { var entity = config.MapTo <DoorEntity>(); entity.DoorUUID = Guid.NewGuid().ToString("N"); entity.CreateTime = DateTime.Now; entity.SyncStatus = false; entity.SyncVersion = 0; entity.Deleted = false; _doorRepository.Insert(entity); Synchronization(entity); }
public static DoorEntity ToEntity(this DoorDto model, DoorEntity destination) { return(model.MapTo(destination)); }
public static DoorEntity ToEntity(this DoorDto model) { return(model.MapTo <DoorDto, DoorEntity>()); }