Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-116076

Add a configuration option to allow disabling the ability to execute freemarker code for new Widget Templates in a System

    Details

      Description

      Intro/Context:

      Liferay provides site administrators the ability to create custom Widget Templates (aka Application Display Templates or ADTs for short), to customize the UI of specific widgets. However in some contexts it's not desired to enable this possibility since it provides too much power and possibilities of impacting the system through bad template code. For sensitive systems, it might be preferable to disable Widget Templates and reduce the customizability in exchange for higher system safety.

      The goal of this story is to provide a configuration option, which allows System Administrators to disable the execution of freemarker for newly created Widget Templates (ADT) for the whole system (all of its virtual instances). When freemarker is disabled for Widget Templates (ADT) then it should not be possible to have freemarker code working for newly created Widget template.

      -

      Given the system administrator has disabled Template creation in "System settings" > "Enable Data Mapping"

      -

      When a user is trying to create a widget template from Product Menu "Design" > "Widget Template"

      Then the "+" button to add a Widget Template should be hidden

      -

      When a widget template is already created (before disabling)

      Then the user should be able to save changes to the widget template but not for newly created ones

       

      Test Scenarios

      Test Scenarios Test Strategy Kind of test Is it covered by FrontEnd ? (JS-Unit) Is it covered by BackEnd ? (unit or integration) Could it be covered by POSHI?
      The New button should be hidden when disable template creation in Dynamic Data Mapping Critical Manual No No Yes
      The user is able to save changes in existing template when disable template creation in Dynamic Data Mapping Critical Manual No No Yes
      The creation of template is not allowed when disable template creation in Dynamic Data Mapping High Manual No Yes Yes

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              manoel.cyreno Manoel Cyreno
              Reporter:
              jorge.ferrer Jorge Ferrer
              Engineering Assignee:
              SE Support
              Recent user:
              Kiyoshi Lee
              Participants of an Issue:
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Packages

                  Version Package
                  Master