Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
<Company>Umbraco HQ</Company>
<Authors>Umbraco</Authors>
<Copyright>Copyright © Umbraco $([System.DateTime]::Today.ToString('yyyy'))</Copyright>
Expand Down Expand Up @@ -32,8 +32,8 @@

<!-- Package validation -->
<PropertyGroup>
<EnablePackageValidation>true</EnablePackageValidation>
<PackageValidationBaselineVersion>16.0.0</PackageValidationBaselineVersion>
<EnablePackageValidation>false</EnablePackageValidation>
<PackageValidationBaselineVersion>17.0.0</PackageValidationBaselineVersion>
<EnableStrictModeForCompatibleFrameworksInPackage>true</EnableStrictModeForCompatibleFrameworksInPackage>
<EnableStrictModeForCompatibleTfms>true</EnableStrictModeForCompatibleTfms>
</PropertyGroup>
Expand Down
10 changes: 5 additions & 5 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
<CentralPackageTransitivePinningEnabled>true</CentralPackageTransitivePinningEnabled>
</PropertyGroup>
Expand All @@ -16,10 +16,10 @@
<PackageVersion Include="FluentValidation" Version="11.9.0" />
<PackageVersion Include="Microsoft.AspNet.WebApi.Client" Version="[6.0.0, 7.0)" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageVersion Include="Umbraco.Cms" Version="[16.0.0, 16.999.999)" />
<PackageVersion Include="Umbraco.Cms.Web.Website" Version="[16.0.0, 16.999.999)" />
<PackageVersion Include="Umbraco.Cms.Web.BackOffice" Version="[16.0.0, 16.999.999)" />
<PackageVersion Include="Umbraco.Commerce" Version="[16.0.0, 16.999.999)" />
<PackageVersion Include="Umbraco.Cms" Version="[17.0.0-rc1, 17.999.999)" />
<PackageVersion Include="Umbraco.Cms.Web.Website" Version="[17.0.0-rc1, 17.999.999)" />
<PackageVersion Include="Umbraco.Cms.Web.BackOffice" Version="[17.0.0-rc1, 17.999.999)" />
<PackageVersion Include="Umbraco.Commerce" Version="[17.0.0-rc1, 17.999.999)" />
<PackageVersion Include="coverlet.collector" Version="6.0.0" />
<PackageVersion Include="xunit" Version="2.6.6" />
<PackageVersion Include="xunit.runner.visualstudio" Version="2.5.6" />
Expand Down
2 changes: 1 addition & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ parameters:
default: false

variables:
nodeVersion: 18.x
nodeVersion: 22.x
solution: Umbraco.Commerce.ProductFeeds.sln
buildConfiguration: Release
DOTNET_NOLOGO: true
Expand Down
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "9.0.100",
"version": "10.0.100-rc.2.25502.107",
"rollForward": "latestFeature"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<Title>Umbraco Commerce Product Feeds Client</Title>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
<Description>Contains frontend code of the project</Description>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
Expand Down
1 change: 1 addition & 0 deletions src/Umbraco.Commerce.ProductFeeds.Client/frontend/.npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@umbraco-commerce:registry=https://www.myget.org/F/umbraconightly/npm/
3,181 changes: 1,827 additions & 1,354 deletions src/Umbraco.Commerce.ProductFeeds.Client/frontend/package-lock.json

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions src/Umbraco.Commerce.ProductFeeds.Client/frontend/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "umbraco-commerce-product-feeds",
"version": "16.0.0",
"version": "17.0.0-rc1",
"description": "A product feeds generator for Umbraco Commerce",
"main": "./src/index.ts",
"type": "module",
Expand All @@ -12,27 +12,27 @@
"gen-api": "openapi-ts"
},
"devDependencies": {
"@eslint/js": "^9.28.0",
"@hey-api/openapi-ts": "^0.69.2",
"@eslint/js": "^9.39.0",
"@hey-api/openapi-ts": "^0.85.2",
"@types/eslint__js": "^9.14.0",
"autoprefixer": "^10.4.21",
"copyfiles": "^2.4.1",
"eslint": "^9.28.0",
"globals": "^16.2.0",
"postcss": "^8.5.4",
"tailwindcss": "^4.1.8",
"ts-loader": "^9.5.2",
"typescript": "^5.8.3",
"typescript-eslint": "^8.33.0",
"vite": "^6.3.5",
"eslint": "^9.39.0",
"globals": "^16.5.0",
"postcss": "^8.5.6",
"tailwindcss": "^4.1.16",
"ts-loader": "^9.5.4",
"typescript": "^5.9.3",
"typescript-eslint": "^8.46.2",
"vite": "^6.4.1",
"vite-tsconfig-paths": "^5.1.4"
},
"author": "",
"license": "ISC",
"dependencies": {
"@hey-api/client-axios": "^0.8.0",
"@umbraco-cms/backoffice": "^16.0.0",
"@umbraco-commerce/backoffice": "^16.0.0",
"nanoid": "^5.1.5"
"@hey-api/client-axios": "^0.9.1",
"@umbraco-cms/backoffice": "^17.0.0-rc.1",
"@umbraco-commerce/backoffice": "17.0.0-rc1",
"nanoid": "^5.1.6"
}
}
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
using Umbraco.Commerce.ProductFeeds.Core.Features.FeedSettings.Application;

namespace Umbraco.Commerce.ProductFeeds.Core.Features.FeedGenerators.Application
{
public interface IProductFeedGeneratorFactory
{
[Obsolete("Will be removed in v17. Use the overload that takes feedGeneratorId.")]
IProductFeedGeneratorService GetGenerator(ProductFeedType feedType)
=> GetGenerator(feedType);

// TODO - v17: remove the default implementation
IProductFeedGeneratorService GetGenerator(Guid feedGeneratorId)
=> throw new NotImplementedException("This method should be implemented in the concrete factory class.");
IProductFeedGeneratorService GetGenerator(Guid feedGeneratorId);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,20 @@ public interface IProductFeedGeneratorService
/// <summary>
/// Returns the feed generator id. Must be unique among the feed generator services.
/// </summary>
public Guid Id => throw new NotImplementedException(); // TODO - v17: remove the default implementation.
public Guid Id { get; }

/// <summary>
/// Returns a user friendly name of the value extractor.
/// </summary>
public string DisplayName => throw new NotImplementedException(); // TODO - v17: remove the default implementation.
public string DisplayName { get; }

/// <summary>
/// Returns the feed format that this generator can generate.
/// </summary>
public FeedFormat Format { get => FeedFormat.Unknown; } // TODO - v17: remove the default implementation.
public FeedFormat Format { get; }

[Obsolete("Will be removed in v17. Use GenerateXmlFeedAsync or GenerateJsonFeedAsync instead.")]
Task<XmlDocument> GenerateFeedAsync(ProductFeedSettingReadModel feedSetting) => GenerateXmlFeedAsync(feedSetting);
Task<XmlDocument> GenerateXmlFeedAsync(ProductFeedSettingReadModel feedSetting);

Task<XmlDocument> GenerateXmlFeedAsync(ProductFeedSettingReadModel feedSetting) => throw new NotImplementedException("XML feed generation is not implemented.");

Task<JsonDocument> GenerateJsonFeedAsync(ProductFeedSettingReadModel feedSetting) => throw new NotImplementedException("JSON feed generation is not implemented.");
Task<JsonDocument> GenerateJsonFeedAsync(ProductFeedSettingReadModel feedSetting);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,6 @@ protected FeedGeneratorServiceBase(
protected ISingleValuePropertyExtractorFactory SingleValuePropertyExtractorFactory { get; }
protected IMultipleValuePropertyExtractorFactory MultipleValuePropertyExtractorFactory { get; }

[Obsolete("Will be removed in v17. Use GenerateXmlFeedAsync or GenerateJsonFeedAsync instead.")]
public virtual Task<XmlDocument> GenerateFeedAsync(ProductFeedSettingReadModel feedSetting) => GenerateXmlFeedAsync(feedSetting);

public virtual Task<XmlDocument> GenerateXmlFeedAsync(ProductFeedSettingReadModel feedSetting) => throw new NotImplementedException("XML feed generation is not implemented.");

public virtual Task<JsonDocument> GenerateJsonFeedAsync(ProductFeedSettingReadModel feedSetting) => throw new NotImplementedException("JSON feed generation is not implemented.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ namespace Umbraco.Commerce.ProductFeeds.Core.Features.FeedGenerators.Implementat
/// <summary>
/// This is the feed generator that follows Google Merchant Center's standard.
/// </summary>
public class GoogleMerchantCenterFeedService : FeedGeneratorServiceBase // TODO - v17: Make internal
internal class GoogleMerchantCenterFeedService : FeedGeneratorServiceBase
{
private const string GoogleXmlNamespaceUri = "http://base.google.com/ns/1.0";

Expand Down Expand Up @@ -55,9 +55,6 @@ public GoogleMerchantCenterFeedService(
_commerceApi = commerceApi;
}

[Obsolete("Will be removed in v17. Use GenerateXmlFeedAsync or GenerateJsonFeedAsync instead.")]
public override Task<XmlDocument> GenerateFeedAsync(ProductFeedSettingReadModel feedSetting) => GenerateXmlFeedAsync(feedSetting);

/// <summary>
/// Generate the product feed following the inputted settings.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,11 @@
using Microsoft.Extensions.DependencyInjection;
using Umbraco.Commerce.ProductFeeds.Core.Features.FeedGenerators.Application;
using Umbraco.Commerce.ProductFeeds.Core.Features.FeedSettings.Application;

namespace Umbraco.Commerce.ProductFeeds.Core.Features.FeedGenerators.Implementations
{
// TODO - v17: make internal
public class ProductFeedGeneratorFactory : IProductFeedGeneratorFactory
internal class ProductFeedGeneratorFactory : IProductFeedGeneratorFactory
{
private readonly FeedGeneratorCollection _feedGenerators;

[Obsolete("Will be removed in v17. Use the constructor that takes FeedGeneratorCollection instead.")]
public ProductFeedGeneratorFactory(IServiceProvider serviceProvider)
: this(serviceProvider.GetService<FeedGeneratorCollection>())
{
}

public ProductFeedGeneratorFactory(FeedGeneratorCollection feedGenerators)
{
_feedGenerators = feedGenerators;
Expand All @@ -26,9 +17,5 @@ public IProductFeedGeneratorService GetGenerator(Guid feedGeneratorId)
?? throw new InvalidOperationException($"Feed generator not found. id: {feedGeneratorId}");
return feedGenerator;
}

[Obsolete("Will be removed in v17. Use feedGeneratorId instead.")]
public IProductFeedGeneratorService GetGenerator(ProductFeedType feedType)
=> GetGenerator(new Guid("101AE565-038F-443E-A29E-4FE0C7146C4A")); // Use the Google Merchant Center Feed ID as default
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
using Umbraco.Commerce.Extensions;

namespace Umbraco.Commerce.ProductFeeds.Core.Features.FeedSettings.Application
{
public class ProductFeedSettingReadModel
Expand All @@ -10,12 +8,6 @@ public class ProductFeedSettingReadModel

public required string FeedName { get; set; }

[Obsolete("Will be removed in 17.")]
public ProductFeedType FeedType { get; set; }

[Obsolete("Will be removed in 17.")]
public string FeedTypeName => FeedType.GetDescription();

public required string FeedDescription { get; set; }

public required Guid StoreId { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,6 @@ public class ProductFeedSettingWriteModel

public required string FeedName { get; set; }

[Obsolete("Will be removed in v17. Migrate to Feed Generator Id.")]
public ProductFeedType? FeedType { get; set; }

public required string FeedDescription { get; set; }

public required Guid StoreId { get; set; }
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ public class UmbracoCommerceProductFeedSetting
{
public Guid Id { get; set; } = Guid.NewGuid();

[Obsolete("Will be removed in v17. Migrate to Feed Generator Id.")]
public string? FeedType { get; set; }

public Guid FeedGeneratorId { get; set; }

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ public InfrastructureMappingProfile()
.ForMember(dest => dest.ProductDocumentTypeIds, opt => opt.MapFrom((src, dest) => string.Join(';', src.ProductDocumentTypeIds)));

CreateMap<UmbracoCommerceProductFeedSetting, ProductFeedSettingReadModel>()
.ForMember(dest => dest.FeedType, opt => opt.MapFrom((src, dest) => Enum.Parse<ProductFeedType>(src.FeedType ?? ProductFeedType.GoogleMerchantCenter.ToString()))) // TODO - v17: Remove
.ForMember(dest => dest.PropertyNameMappings, opt => opt.MapFrom((src, dest) => JsonSerializer.Deserialize<ICollection<PropertyAndNodeMapItem>>(src.ProductPropertyNameMappings)))
.ForMember(dest => dest.ProductChildVariantTypeIds, opt => opt.MapFrom((src, dest) => !string.IsNullOrEmpty(src.ProductChildVariantTypeIds) ? src.ProductChildVariantTypeIds?.Split(';') : []))
.ForMember(dest => dest.ProductDocumentTypeIds, opt => opt.MapFrom((src, dest) => !string.IsNullOrEmpty(src.ProductDocumentTypeIds) ? src.ProductDocumentTypeIds.Split(';') : []));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,7 @@ public ProductFeedSettingsService(
from umbracoCommerceProductFeedSetting
where( @0 IS NULL OR feedRelativePath = @0)
AND (@1 IS NULL OR id = @1)",
findSettingParams.FeedRelativePath,
findSettingParams.Id)
[findSettingParams.FeedRelativePath, findSettingParams.Id])
.ConfigureAwait(false);
scope.Complete();

Expand All @@ -70,7 +69,7 @@ public async Task<List<ProductFeedSettingReadModel>> GetListAsync(Guid storeId)
@"
select *
from umbracoCommerceProductFeedSetting
where storeId = @0", storeId)
where storeId = @0", [storeId])
.ConfigureAwait(false);
scope.Complete();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<Title>Umbraco Commerce Product Feeds Startup</Title>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Description>Contains code which run when app starts and method to register the plugin to your site</Description>
<Nullable>enable</Nullable>
Expand Down
Loading
Loading