cat:count
items that specify the number of leafs per category; these values are used instead of computing them by HIERARCHY itself
cat:count
items that specify the number of topics per category; these values are used instead of computing them by HIERARCHY itself
%STARTINCLUDE%[ %HIERARCHY{ web="%web{default="%BASEWEB%"}%" top="%root{default="TopCategory"}%" depth="%depth{default="2"}%" exclude="%root{default="TopCategory"}%%IF{"defined exclude" then="|%exclude%"}%" hidenull="%hidenull{default="off"}%"%IF{"defined nrleafs" then="nrleafs=\"%nrleafs%\"" }%%IF{"defined nrtopics" then="nrtopics=\"%nrtopics%\"" }%%IF{"defined search" then="hideclosed=\"on\"" }% open="%root{default="TopCategory"}%%IF{"defined open" then=", %open%" }%%IF{"defined search" then="$percntCATINFO{ web=\"%IF{"defined web" then="%web%" else="%BASEWEB%"}%\" include=\".*%search%.*\" matchcase=\"off\" matchattr=\"title\" header=\", \" format=\"$topic\" separator=\", \" }$percnt" }%" separator=",$n" format="$indent{ $indent \"text\": \"%DBCALL{ "%WEB%.%TOPIC%" section="%format{default="browser"}%" depth="%depth{default="2"}%" fieldname="%fieldname%" }%\", $indent \"expanded\": $isexpanded, $indent \"hasChildren\": $subcats, $indent \"id\": \"$name\", $indent \"children\": [$children] $indent}" }% ]%STOPINCLUDE%
%STARTSECTION{"browser"}%<a href='$url' title='$percntENCODE{\"$summary\" type=\"entity\"}$percnt'><img src='$icon' alt='$percntENCODE{\"$title\" type=\"entity\"}$percnt' />$percntENCODE{\"$title\" type=\"quote\"}$percnt</a>$percntIF{ \"'$cyclic' = '1'\" then=\" <span class='foswikiAlert'>C</span>\"}$percnt$percntIF{ \"'$count' != '0'\" then=\" ($count)\" }$percnt%ENDSECTION{"browser"}%
%STARTSECTION{"plain"}%<a href='$url' title='$percntENCODE{\"$summary\" type=\"entity\"}$percnt'><noautolink>$percntENCODE{\"$title\" type=\"quote\"}$percnt</noautolink></a>%ENDSECTION{"plain"}%
%STARTSECTION{"sidebar"}%<a class='clsCategoryLink' style='background-image:url($icon);' href='$url' title='$percntENCODE{\"$summary\" type=\"entity\"}$percnt'><noautolink>$percntENCODE{\"$title\" type=\"quote\"}$percnt</noautolink></a>%ENDSECTION{"sidebar"}%
%STARTSECTION{"editor"}%<a href='#' class='$name clsCategory {depth:$depth}' title='$percntENCODE{\"$summary\" type=\"entity\"}$percnt' value='$name'><img src='$icon' alt='$percntENCODE{\"$title\" type=\"entity\"}$percnt' /><noautolink>$percntENCODE{\"$title\" type=\"quote\"}$percnt</noautolink></a>%ENDSECTION{"editor"}%
%STARTSECTION{"leafselect"}%$percntIF{\"$leafs>0 and $depth <= %depth%\" then=\"<img src='$icon' alt='$percntENCODE{\"$title\" type=\"entity\"}$percnt' /><noautolink>$percntENCODE{\"$title\" type=\"quote\"}$percnt</noautolink>\" else=\"<a href='#' title='$percntENCODE{\"$summary\" type=\"entity\"}$percnt' value='$name' class='$name clsCategory {depth:$depth}'><img src='$icon' alt='$percntENCODE{\"$title\" type=\"entity\"}$percnt' /><noautolink>$percntENCODE{\"$title\" type=\"quote\"}$percnt</noautolink></a>\" }%%ENDSECTION{"leafselect"}%
%STARTSECTION{"solrfacet"}%<a href='#' class='$name clsCategory solrFacetValue {depth:$depth}' title='$percntENCODE{\"$summary\" type=\"entity\"}$percnt' value='category:$name'><img src='$icon' alt='$percntENCODE{\"$title\" type=\"entity\"}$percnt' /><noautolink>$percntENCODE{\"$title\" type=\"quote\"}$percnt</noautolink></a> $percntIF{\"$count>0\" then=\"($count)\"}$percnt%ENDSECTION{"solrfacet"}%
%STARTSECTION{"solrfacet_nocounts"}%<a href='#' class='$name clsCategory solrFacetValue {depth:$depth}' title='$percntENCODE{\"$summary\" type=\"entity\"}$percnt' value='category:$name'><img src='$icon' alt='$percntENCODE{\"$title\" type=\"entity\"}$percnt' /><noautolink>$percntENCODE{\"$title\" type=\"quote\"}$percnt</noautolink></a>%ENDSECTION{"solrfacet_nocounts"}%
%STARTSECTION{"test1"}% %DBCALL{"%TOPIC%" format="plain"}% %ENDSECTION{"test1"}%
%STARTSECTION{"test2"}% %DBCALL{"%TOPIC%" format="browser"}% %ENDSECTION{"test2"}%
%STARTSECTION{"test3"}% %DBCALL{"%TOPIC%" format="editor" exclude="TestCategory5"}% %ENDSECTION{"test3"}%
[ { "text": "' alt='TestCategory12' />TestCategory12", "expanded": false, "hasChildren": 0, "id": "TestCategory12", "children": [] }, { "text": "
' alt='TestCategory4' />TestCategory4", "expanded": false, "hasChildren": 0, "id": "TestCategory4", "children": [] } ]
[ ]
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY, to the extent permitted by law; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.