From d1f79e91e977dde064006da55af0f01674a7225d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Krch?= Date: Fri, 13 Sep 2024 14:56:11 +0200 Subject: [PATCH] upgrade of XbyK API to v29.4.3 --- .../Mappers/ContentItemMapper.cs | 11 +++++++---- .../Migration.Toolkit.Source.csproj | 4 ++-- Migration.Toolkit.CLI/Migration.Toolkit.CLI.csproj | 2 +- .../Migration.Toolkit.Common.csproj | 4 ++-- .../Migration.Toolkit.Core.K11.csproj | 2 +- .../Migration.Toolkit.Core.KX12.csproj | 2 +- .../Migration.Toolkit.Core.KX13.csproj | 4 ++-- .../Migration.Toolkit.KXP.Api.csproj | 4 ++-- .../Migration.Toolkit.KXP.Extensions.csproj | 4 ++-- .../Migration.Toolkit.Tests.csproj | 2 +- 10 files changed, 21 insertions(+), 18 deletions(-) diff --git a/KVA/Migration.Toolkit.Source/Mappers/ContentItemMapper.cs b/KVA/Migration.Toolkit.Source/Mappers/ContentItemMapper.cs index 9ffd9f86..4d5d6604 100644 --- a/KVA/Migration.Toolkit.Source/Mappers/ContentItemMapper.cs +++ b/KVA/Migration.Toolkit.Source/Mappers/ContentItemMapper.cs @@ -700,9 +700,10 @@ private async Task ConvertToAsset(Dictionary target, ICmsTree c { if (configuration.MigrateMediaToMediaLibrary) { - if (entityIdentityFacade.Translate(sourceMediaFile) is { } mf && mediaFileFacade.GetMediaFile(mf.Identity) is { } mfi) + if (entityIdentityFacade.Translate(sourceMediaFile) is { } mf && mediaFileFacade.GetMediaFile(mf.Identity) is { } x) { - mfis = [mfi]; + mfis = [new AssetRelatedItem { Identifier = x.FileGUID, Dimensions = new AssetDimensions { Height = x.FileImageHeight, Width = x.FileImageWidth }, Name = x.FileName, Size = x.FileSize }]; + hasMigratedAsset = true; } } else @@ -1013,8 +1014,10 @@ private void WalkProperties(int siteId, JObject properties, List(); foreach (var asi in items) { - var attachment = modelFacade.SelectWhere("AttachmentSiteID = @siteId AND AttachmentGUID = @attachmentGUID", new SqlParameter("attachmentSiteID", siteId), - new SqlParameter("attachmentGUID", asi.FileGuid)) + var attachment = modelFacade.SelectWhere("AttachmentSiteID = @attachmentSiteId AND AttachmentGUID = @attachmentGUID", + new SqlParameter("attachmentSiteID", siteId), + new SqlParameter("attachmentGUID", asi.FileGuid) + ) .FirstOrDefault(); if (attachment != null) { diff --git a/KVA/Migration.Toolkit.Source/Migration.Toolkit.Source.csproj b/KVA/Migration.Toolkit.Source/Migration.Toolkit.Source.csproj index 131c0818..411464d1 100644 --- a/KVA/Migration.Toolkit.Source/Migration.Toolkit.Source.csproj +++ b/KVA/Migration.Toolkit.Source/Migration.Toolkit.Source.csproj @@ -13,8 +13,8 @@ - - + + diff --git a/Migration.Toolkit.CLI/Migration.Toolkit.CLI.csproj b/Migration.Toolkit.CLI/Migration.Toolkit.CLI.csproj index a098002f..996dd088 100644 --- a/Migration.Toolkit.CLI/Migration.Toolkit.CLI.csproj +++ b/Migration.Toolkit.CLI/Migration.Toolkit.CLI.csproj @@ -18,7 +18,7 @@ - + diff --git a/Migration.Toolkit.Common/Migration.Toolkit.Common.csproj b/Migration.Toolkit.Common/Migration.Toolkit.Common.csproj index ee48a656..c9fc607b 100644 --- a/Migration.Toolkit.Common/Migration.Toolkit.Common.csproj +++ b/Migration.Toolkit.Common/Migration.Toolkit.Common.csproj @@ -16,8 +16,8 @@ - - + + diff --git a/Migration.Toolkit.Core.K11/Migration.Toolkit.Core.K11.csproj b/Migration.Toolkit.Core.K11/Migration.Toolkit.Core.K11.csproj index 67f09feb..4b46f4e6 100644 --- a/Migration.Toolkit.Core.K11/Migration.Toolkit.Core.K11.csproj +++ b/Migration.Toolkit.Core.K11/Migration.Toolkit.Core.K11.csproj @@ -8,7 +8,7 @@ - + diff --git a/Migration.Toolkit.Core.KX12/Migration.Toolkit.Core.KX12.csproj b/Migration.Toolkit.Core.KX12/Migration.Toolkit.Core.KX12.csproj index 14dd9573..db3feadb 100644 --- a/Migration.Toolkit.Core.KX12/Migration.Toolkit.Core.KX12.csproj +++ b/Migration.Toolkit.Core.KX12/Migration.Toolkit.Core.KX12.csproj @@ -8,7 +8,7 @@ - + diff --git a/Migration.Toolkit.Core.KX13/Migration.Toolkit.Core.KX13.csproj b/Migration.Toolkit.Core.KX13/Migration.Toolkit.Core.KX13.csproj index af9b0455..6d272033 100644 --- a/Migration.Toolkit.Core.KX13/Migration.Toolkit.Core.KX13.csproj +++ b/Migration.Toolkit.Core.KX13/Migration.Toolkit.Core.KX13.csproj @@ -12,8 +12,8 @@ - - + + diff --git a/Migration.Toolkit.KXP.Api/Migration.Toolkit.KXP.Api.csproj b/Migration.Toolkit.KXP.Api/Migration.Toolkit.KXP.Api.csproj index d5ce7236..45105b6a 100644 --- a/Migration.Toolkit.KXP.Api/Migration.Toolkit.KXP.Api.csproj +++ b/Migration.Toolkit.KXP.Api/Migration.Toolkit.KXP.Api.csproj @@ -10,8 +10,8 @@ - - + + diff --git a/Migration.Toolkit.KXP.Extensions/Migration.Toolkit.KXP.Extensions.csproj b/Migration.Toolkit.KXP.Extensions/Migration.Toolkit.KXP.Extensions.csproj index beea6162..7a16aa8d 100644 --- a/Migration.Toolkit.KXP.Extensions/Migration.Toolkit.KXP.Extensions.csproj +++ b/Migration.Toolkit.KXP.Extensions/Migration.Toolkit.KXP.Extensions.csproj @@ -7,8 +7,8 @@ - - + + diff --git a/Migration.Toolkit.Tests/Migration.Toolkit.Tests.csproj b/Migration.Toolkit.Tests/Migration.Toolkit.Tests.csproj index d0d41fc9..224f290d 100644 --- a/Migration.Toolkit.Tests/Migration.Toolkit.Tests.csproj +++ b/Migration.Toolkit.Tests/Migration.Toolkit.Tests.csproj @@ -5,7 +5,7 @@ - + runtime; build; native; contentfiles; analyzers; buildtransitive