public Task <AsyncTaskResult> HandleAsync(GoodsUnpublishedEvent evnt) { return(TryUpdateRecordAsync(connection => { return connection.UpdateAsync(new { IsPublished = 0, Version = evnt.Version, EventSequence = evnt.Sequence }, new { Id = evnt.AggregateRootId, //Version = evnt.Version - 1 }, ConfigSettings.GoodsTable); })); }
private void Handle(GoodsUnpublishedEvent evnt) { _isPublished = false; }