Index: openacs-4/packages/xotcl-request-monitor/www/active-communities.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xotcl-request-monitor/www/active-communities.tcl,v diff -u -N -r1.2.2.1 -r1.2.2.2 --- openacs-4/packages/xotcl-request-monitor/www/active-communities.tcl 10 Sep 2015 08:10:45 -0000 1.2.2.1 +++ openacs-4/packages/xotcl-request-monitor/www/active-communities.tcl 26 Apr 2016 07:25:29 -0000 1.2.2.2 @@ -7,14 +7,14 @@ } -query { {orderby:optional "count,desc"} } -properties { - title:onevalue - context:onevalue + title:onevalue + context:onevalue } set title "Active Communities" set context [list "Active Communities"] -TableWidget t1 \ +TableWidget create t1 \ -columns { AnchorField community -label Community -orderby community Field count -label Count -orderby count @@ -25,9 +25,19 @@ foreach {community_id users} [throttle users active_communities] { if {$community_id eq ""} continue + + if {[info commands ::dotlrn_community::get_community_name] ne ""} { + set community_name [::dotlrn_community::get_community_name $community_id] + } else { + set community_name "" + } + if {$community_name eq ""} { + set community_name [::xo::db::sql::apm_package name -package_id $community_id] + } + t1 add \ - -community [dotlrn_community::get_community_name $community_id] \ - -community.href [export_vars -base users-in-community {community_id}] \ + -community $community_name \ + -community.href [export_vars -base users-in-community {community_id community_name}] \ -count [llength [lsort -unique [eval concat $users]]] } set t1 [t1 asHTML]