community-info.tcl

Does not contain a contract.

Location:
/packages/acs-subsite/www/admin/system/community-info.tcl

Related Files

[ hide source ] | [ make this the default ]

File Contents

proc get_details { object } {
    set html "<table>"
    set x 1
    foreach var [$object info vars] { 
        if { $x == 1 } { set css_class "list-even"set x 0; } elseset css_class "list-odd"set x 1; }
        append html "<tr class=\\'$css_class\\'><td><b>$var</b></td><td>[$object set $var]</td></tr>" 
    }
    append html "</table>"
    return $html
}

multirow create obj_info class obj name key details id

foreach class [list lr_community lr_class lr_class_instance lr_department lr_club] {
    foreach object [$class info instances] {
        multirow append obj_info $class $object [$object pretty_name] [$object fq_community_key] [get_details $object] [$object community_id]
    }
}

#         details {
#             label "Details"
#                display_template {<img onclick="return overlib('@obj_info.details;noquote@', STICKY, CAPTION, 'Details', CENTER);" onmouseout="nd();" src="/media/images/details.gif" title="show details" class="infoimage"> \[ <a href='object-refresh?id=@obj_info.id@'>Flush</a> \]}
#         }

list::create \
    -name "obj_info" \
    -multirow "obj_info" \
    -no_data "Keine aktiven Objekte vorhanden" \
    -key obj \
    -row_pretty_plural "Objekte" \
    -elements {
        class {
            label "Klasse"
        }
        obj {
            label "Objekt"
        }
        name {
            label "Name"
        }
        key {
            label "Schlüssel"
        }
    } 

ad_return_template