Update GetPagedResultsByQuery to return id of the node the audit item relates to instead of table PK

This was fixed previously in v7 - see https://github.com/umbraco/Umbraco-CMS/pull/3759

(cherry picked from commit 53c52abde5)
This commit is contained in:
Marc Goodson
2019-08-02 21:34:22 +01:00
committed by Sebastiaan Janssen
parent 65b2d08997
commit cec4376d19

View File

@@ -174,7 +174,7 @@ namespace Umbraco.Core.Persistence.Repositories.Implement
totalRecords = page.TotalItems;
var items = page.Items.Select(
dto => new AuditItem(dto.Id, Enum<AuditType>.ParseOrNull(dto.Header) ?? AuditType.Custom, dto.UserId ?? Constants.Security.UnknownUserId, dto.EntityType, dto.Comment, dto.Parameters)).ToList();
dto => new AuditItem(dto.NodeId, Enum<AuditType>.ParseOrNull(dto.Header) ?? AuditType.Custom, dto.UserId ?? Constants.Security.UnknownUserId, dto.EntityType, dto.Comment, dto.Parameters)).ToList();
// map the DateStamp
for (var i = 0; i < items.Count; i++)