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

Applying a custom DDL Display Templates breaks the Add Record button.

    Details

      Description

      Last commit: ac83fb8e7ab20d3a4b2042aef54765bd1fc46c35

      Applying a custom Display template in a DDL Display portlet makes it so that the "Add" button only maximizes the portlet, showing the Display Template. It should display the default form template so the user can add a record.

      All steps were completed by a signed in administrative user. Feel free to skip the first set of steps. They simply show the working behavior, using the default display template. The second set of steps are what cause the bug to appear.

      Steps to reproduce correct/expected behavior:

      1. Create a new data definition (test-definition) with a Radio field.
      2. Create a data list that uses the new definition (test-list)
      3. Add a Dynamic Dispaly portlet to web/guest/home.
      4. Select the new list for display.
      5. Click "Add a new test-definition"
      Expected Result: Access the default form template to fill out and submit a new DDL record.
      Actual Result: Same as expected.

      Steps to reproduce unexpected/buggy behavior:

      1. Create a new data definition (test-definition) with a Radio field (leave all configuration options as the defaults).
      2. Create a data list that uses the new definition (test-list)
      3. Add a Dynamic Dispaly portlet to web/guest/home.
      4. Select the new list for display.
      5. Click Add Display Template.

      <#assign records = ddlDisplayTemplateHelper.getRecords(reserved_record_set_id)>

      <#if records?has_content>
      <#list records as cur_record>
      This option was selected: <em>${ddlDisplayTemplateHelper.renderRecordFieldValue(cur_record.getDDMFormFieldValues("Radioe705")?first, locale)}</em>
      </#list>
      </#if>

      6. Click "Add a new test-definition"
      Expected Result: Access the default form template to fill out and submit a new DDL record.
      Actual Result: The DDL Display portlet maximizes and no form is accesssible. See screenshot.

        Attachments

        1. Fixed.PNG
          Fixed.PNG
          54 kB
        2. maximized-portlet.png
          maximized-portlet.png
          22 kB
        3. Reproduced.PNG
          Reproduced.PNG
          36 kB

          Activity

            People

            • Assignee:
              harry.chai Harry Chai
              Reporter:
              russell.bohl Russell Bohl
              Participants of an Issue:
              Recent user:
              Esther Sanz
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                4 years, 33 weeks ago

                Packages

                Version Package
                7.0.0 Alpha 4