microsoft / AL

Home of the Dynamics 365 Business Central AL Language extension for Visual Studio Code. Used to track issues regarding the latest version of the AL compiler and developer tools available in the Visual Studio Code Marketplace or as part of the AL Developer Preview builds for Dynamics 365 Business Central.
MIT License
719 stars 242 forks source link

Page Customization breaks translations for Page Extension #7688

Closed andersws closed 3 months ago

andersws commented 3 months ago

1. Describe the bug When i create a page customazation on top of a page extension, the translation file gets messed up. Meaning that all tooltips, captions etc. from the original page extension now is treated as fields on the page customization in the translation file.

2. To Reproduce

  1. Enable TranslationFile feature in app.json "features": ["TranslationFile"]

  2. Create a standard page extension:

    pageextension 50020 "AUZ Item Card" extends "Item Card"
    {
    layout
    {
        addafter("No.")
        {
            field(AUZNo2; Rec."No. 2")
            {
                ApplicationArea = All;
                ToolTip = 'Specifies the tooltip.';
            }
        }
    }
    }

Build to see expected behavior.

  1. Create a page customization for the page.
    pagecustomization "AUZ Item Card" customizes "Item Card"
    {
    layout
    {
        modify(AUZNo2)
        {
            Visible = false;
        }
    }
    }

3. Expected behavior

<trans-unit id="PageExtension 1717001217 - Control 3934353231 - Property 1295455071" size-unit="char" translate="yes" xml:space="preserve" al-object-target="Page 1434786627">
   <source>Specifies the tooltip.</source>
   <note from="Developer" annotates="general" priority="2"></note>
   <note from="Xliff Generator" annotates="general" priority="3">PageExtension AUZ Item Card - Control AUZNo2 - Property ToolTip</note>
</trans-unit>

4. Actual behavior

<trans-unit id="PageCustomization 1717001217 - Control 3934353231 - Property 1295455071" size-unit="char" translate="yes" xml:space="preserve" al-object-target="Page 1434786627">
   <source>Specifies the tooltip.</source>
   <note from="Developer" annotates="general" priority="2"></note>
   <note from="Xliff Generator" annotates="general" priority="3">PageExtension AUZ Item Card - Control AUZNo2 - Property ToolTip</note>
</trans-unit>

5. Versions:

NicolaiEsbensen commented 3 months ago

We have the same issue, also present in the preview version of AL (14.x).

LightValley commented 3 months ago

We have the same problem and are forces to downgrade the AL extension to version 12.x. This is stopping us from developing to the new BC24 at the moment.

qutreson commented 3 months ago

Thanks for reporting this issue. We have already prepared a fix for it which will be part of BC 24 and of the next release of the preview version of the AL extension.