cuny-academic-commons / commons-in-a-box

Commons In A Box - A suite of community and collaboration tools for WordPress, designed especially for academic communities
http://commonsinabox.org
72 stars 14 forks source link

OpenLab: Wrong count on "Academic Units" admin page #407

Closed r-a-y closed 2 years ago

r-a-y commented 2 years ago

Reported here: https://cboxopenlab.org/groups/help-forum/forum/topic/buddypress-profile-types-categories-show-zero-counts-and-disallow-parent-chil/

Screenshot: Image

The counts listed under the "Academic Units" admin page do not update when a member or group is updated with a specific Academic Unit.

The issue is Academic Units are added as post types, but when a member or group is categorized with an Academic Unit, this uses separate taxonomies: https://github.com/cuny-academic-commons/cbox-openlab-core/blob/2fa4ef1a1c1857b0badd8f3ba3cd002c658493ff/includes/academic-units.php#L48-L63

If we wanted to display the counts, we would probably need two separate Count columns for members and groups respectively and to calculate those counts ourselves.

boonebgorges commented 2 years ago

I think that for now I'll just hide the Parent and Count columns.