From 3d6edb5d704cae4e61600f536f1b04d5799e4be7 Mon Sep 17 00:00:00 2001 From: Michael Bromley Date: Tue, 21 Nov 2023 17:37:19 +0100 Subject: [PATCH] fix(core): Fix i18n custom fields in Promotion & PaymentMethod --- packages/core/src/entity/register-custom-entity-fields.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/core/src/entity/register-custom-entity-fields.ts b/packages/core/src/entity/register-custom-entity-fields.ts index 6a869eb0f9..6d7b357d76 100644 --- a/packages/core/src/entity/register-custom-entity-fields.ts +++ b/packages/core/src/entity/register-custom-entity-fields.ts @@ -35,6 +35,7 @@ import { CustomOrderFields, CustomOrderLineFields, CustomPaymentMethodFields, + CustomPaymentMethodFieldsTranslation, CustomProductFields, CustomProductFieldsTranslation, CustomProductOptionFields, @@ -44,6 +45,7 @@ import { CustomProductVariantFields, CustomProductVariantFieldsTranslation, CustomPromotionFields, + CustomPromotionFieldsTranslation, CustomRegionFields, CustomRegionFieldsTranslation, CustomSellerFields, @@ -274,6 +276,7 @@ export function registerCustomEntityFields(config: VendureConfig) { registerCustomFieldsForEntity(config, 'Order', CustomOrderFields); registerCustomFieldsForEntity(config, 'OrderLine', CustomOrderLineFields); registerCustomFieldsForEntity(config, 'PaymentMethod', CustomPaymentMethodFields); + registerCustomFieldsForEntity(config, 'PaymentMethod', CustomPaymentMethodFieldsTranslation, true); registerCustomFieldsForEntity(config, 'Product', CustomProductFields); registerCustomFieldsForEntity(config, 'Product', CustomProductFieldsTranslation, true); registerCustomFieldsForEntity(config, 'ProductOption', CustomProductOptionFields); @@ -288,6 +291,7 @@ export function registerCustomEntityFields(config: VendureConfig) { registerCustomFieldsForEntity(config, 'ProductVariant', CustomProductVariantFields); registerCustomFieldsForEntity(config, 'ProductVariant', CustomProductVariantFieldsTranslation, true); registerCustomFieldsForEntity(config, 'Promotion', CustomPromotionFields); + registerCustomFieldsForEntity(config, 'Promotion', CustomPromotionFieldsTranslation, true); registerCustomFieldsForEntity(config, 'TaxCategory', CustomTaxCategoryFields); registerCustomFieldsForEntity(config, 'TaxRate', CustomTaxRateFields); registerCustomFieldsForEntity(config, 'User', CustomUserFields);