Class ::xowiki::includelet::most-frequent-visitors

::xowiki::includelet::most-frequent-visitors[i] create ... \
           [ -parameter_declaration (default " {-max_entries:integer "15"} ") ] \
           [ -title (default "#xowiki.most_frequent_visitors#") ]

List the most frequent visitors.
Defined in /var/www/openacs.org/packages/xowiki/tcl/includelet-procs.tcl

Class Relations

  • class: ::xowiki::IncludeletClass[i]
  • superclass: ::xowiki::Includelet[i]
::xowiki::IncludeletClass create ::xowiki::includelet::most-frequent-visitors \
     -superclass ::xowiki::Includelet

Methods (to be applied on instances)

  • parameter_declaration (setter)

  • render (scripted)

    :get_parameters
    ::xo::Page requireCSS "/resources/acs-templating/lists.css"
    
    [:tableWidget] create t1 -volatile  -columns {
          Field create user  -label [_ xowiki.includelet-visitors] -html { align right }
          Field create count -label [_ xowiki.includelets-visits] -html { align right }
        }
    ::xo::dc foreach most-frequent-visistors  [::xo::dc select  -vars "sum(count) as sum, user_id"   -from "xowiki_last_visited"   -where "package_id = :package_id"   -groupby "user_id"  -orderby "sum desc"  -limit $max_entries] {
               t1 add  -user [::xo::get_user_name $user_id]  -count $sum
             }
    return [t1 asHTML]
  • title (setter)