MDL-38065 gradebook: Fix issue with hidden categories breaking rowspan.

Hidden subcategories break the rowspan in the gradebook; this fix corrects
the calculation of the rowspan.
submodules