what is the best approach to report on some spaces with specific label and match a number of label

  • 1
  • Question
  • Updated 2 years ago
Hello,
I'm using this actual report to find any pages that has a specific label and match a minimum number of labels.

This works fine. However this report works for a specific space where the report reside.

Now I need to report on about 7 spaces for the same rules.
What would be the best approach ?

Here is the code
<code>
<ac:structured-macro ac:macro-id="e0382b8a-5fac-4680-8c80-57b844865d71" ac:name="report-table" ac:schema-version="1">
        <ac:rich-text-body>
          <ac:structured-macro ac:macro-id="5b935fe5-de5f-4be0-b04a-12d4cce8bf19" ac:name="content-reporter" ac:schema-version="1">
            <ac:parameter ac:name="types">page</ac:parameter>
            <ac:parameter ac:name="scope">Type d'article &gt; descendents</ac:parameter>
            <ac:parameter ac:name="labels">+kb-page</ac:parameter>
            <ac:rich-text-body>
              <p> </p>
              <ac:structured-macro ac:macro-id="bffde88d-ee0b-4b28-a428-daecd440c77c" ac:name="number-filter" ac:schema-version="1">
                <ac:parameter ac:name="belowValue">6</ac:parameter>
                <ac:parameter ac:name="">content:labels&gt;collection:size</ac:parameter>
              </ac:structured-macro>
            </ac:rich-text-body>
          </ac:structured-macro>
          <ac:structured-macro ac:macro-id="822e1db3-20f5-4b4d-8649-1d1234bd4e96" ac:name="report-column" ac:schema-version="1">
            <ac:parameter ac:name="title">Titre de la page</ac:parameter>
            <ac:rich-text-body>
              <p>
                <ac:structured-macro ac:macro-id="29674ba7-f7ef-4ae0-be97-bd2595029923" ac:name="report-info" ac:schema-version="1">
                  <ac:parameter ac:name="link">true</ac:parameter>
                  <ac:parameter ac:name="">content:title</ac:parameter>
                </ac:structured-macro>
              </p>
            </ac:rich-text-body>
          </ac:structured-macro>
          <ac:structured-macro ac:macro-id="a649fd0e-3ce2-4bd9-90d5-b976737c0809" ac:name="report-empty" ac:schema-version="1">
            <ac:rich-text-body>
              <p>
                <em>Bravo, toutes les pages sont taguées...</em>
              </p>
            </ac:rich-text-body>
          </ac:structured-macro>
        </ac:rich-text-body>
      </ac:structured-macro>
</code>

Thanks for any help.

Michael
Photo of michael regelin

michael regelin

  • 346 Posts
  • 2 Reply Likes
  • unsure

Posted 2 years ago

  • 1
Photo of Nurhana Ziana Bt. Hanafi

Nurhana Ziana Bt. Hanafi, Employee

  • 3500 Posts
  • 269 Reply Likes
Hello Michael,

Is the report should check anywhere on the spaces, or only on certain hierarchy?

Thanks&Regards,
Ziana
Photo of michael regelin

michael regelin

  • 346 Posts
  • 2 Reply Likes
Hi Ziana,

Like the template does, only from a descendent and all its chidren and grand children:

<code>
  <ac:parameter ac:name="scope">Type d'article &gt; descendents</ac:parameter>
</code>

Thanks,
Michael