Page Properties Report macro fails to display columns with special characters in the Page Properties Macro

XMLWordPrintable

    • 1

      Summary

      Given the right conditions for the Page Properties Macro, the Page Properties Report macro fails to display columns that contain special characters such as: ã, õ (not sure how many characters are affected).

      Environment

      • Tested on Confluence 7.7.4: it is affected.
      • Tested on Confluence 7.3.5: it is not affected.

      Steps to Reproduce

      1. Create a page with the Page Properties macro and a simple table. Use a special character in one of the heading cells:
         
      2. Create a page with the two Page Properties Report macro for comparison. The first one configured with an empty Columns to show field, so it displays all the columns.

        The second one indicates the two columns in the Columns to show field.:
         
      3. The content is properly displayed:
      4. Now edit the page with the Page Properties macro. Add a new line to the à cell. You can delete it later, but it's important that this step is performed.
      5. The Page Properties Report macro will stop working. The content from the column à stoped working:

      Why this happened?

      When the new line was added to the heading cell named Ã, the heading was wrapped with <p> and </p> in the Storage Format:

      Before
      <tr>
      <th>&Atilde;</th>
      <th>B</th></tr>
      <tr>
      <td>C</td>
      <td>D</td></tr>
      
      After
      <tr>
      <th>
      <p>&Atilde;</p>
      <p><br /></p></th>
      <th>B</th></tr>
      <tr>
      <td>C</td>
      <td>D</td></tr>
      

      The <p> </p> block of code remains even if the new line is deleted.

      Based on the test, to trigger the bug, the heading cells containing the <p> </p> block also need to have a special character.

      The bug can also be reproduced if a cell content that contained that <p> </p> block and the special character before was copied to a heading cell or if the the cell containing the <p> </p> block and the special character was converted into a heading cell.

      Workaround

      Using a plugin such as Confluence Source Editor, the user can access the Storage Format for the affected page, locate the heading cells and manually remove the <p> </p> block.

      Eventually the <strong> </strong> block can be found together the <p> </p> block. Consider removing it too.

      Appendix

      Storage Format for the page containing the Page Properties Report macro:

      <p>All columns</p>
      <p><ac:structured-macro ac:name="detailssummary" ac:schema-version="2" ac:macro-id="65f961c4-e5f3-4b43-8733-e390cdbfa3b9"><ac:parameter ac:name="cql">label = &quot;test&quot; and space = currentSpace()</ac:parameter></ac:structured-macro></p>
      <p>Specifying columns &Atilde; and B to show</p>
      <p><ac:structured-macro ac:name="detailssummary" ac:schema-version="2" ac:macro-id="5faa7e77-71dd-4c3b-ab2f-9ca84f8569fe"><ac:parameter ac:name="headings">&Atilde;,B</ac:parameter><ac:parameter ac:name="cql">label = &quot;test&quot; and space = currentSpace()</ac:parameter></ac:structured-macro></p>
      

      Storage Format for the unaffected page containing the Page Properties macro:

      <p class="auto-cursor-target"><br /></p><ac:structured-macro ac:name="details" ac:schema-version="1" ac:macro-id="0f833fce-e0ac-4d33-8ba9-714d195209c2"><ac:rich-text-body>
      <p class="auto-cursor-target"><br /></p>
      <table><colgroup> <col /> <col /> </colgroup>
      <tbody>
      <tr>
      <th>&Atilde;</th>
      <th>B</th></tr>
      <tr>
      <td>C</td>
      <td>D</td></tr></tbody></table>
      <p class="auto-cursor-target"><br /></p></ac:rich-text-body></ac:structured-macro>
      <p class="auto-cursor-target"><br /></p>
      

      Storage Format for the affected page containing the Page Properties macro:

      <p class="auto-cursor-target"><br /></p><ac:structured-macro ac:name="details" ac:schema-version="1" ac:macro-id="0f833fce-e0ac-4d33-8ba9-714d195209c2"><ac:rich-text-body>
      <p class="auto-cursor-target"><br /></p>
      <table><colgroup> <col /> <col /> </colgroup>
      <tbody>
      <tr>
      <th>
      <p>&Atilde;</p>
      <p><br /></p></th>
      <th>B</th></tr>
      <tr>
      <td>C</td>
      <td>D</td></tr></tbody></table>
      <p class="auto-cursor-target"><br /></p></ac:rich-text-body></ac:structured-macro>
      <p class="auto-cursor-target"><br /></p>
      

        1. Columns to show.png
          Columns to show.png
          26 kB
        2. Editing the macro.png
          Editing the macro.png
          34 kB
        3. Macro is working.png
          Macro is working.png
          32 kB
        4. Page Properties Report.png
          Page Properties Report.png
          59 kB
        5. Page Properties Report not working.png
          Page Properties Report not working.png
          66 kB
        6. Page Properties Report working.png
          Page Properties Report working.png
          68 kB

            Assignee:
            Unassigned
            Reporter:
            Felipe Thozeski (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            11 Start watching this issue

              Created:
              Updated:
              Resolved: