db-settings.tcl
- Location:
- /packages/acs-subsite/www/admin/system/db-settings.tcl
- Author:
- Guenter Ernst guenter.ernst@wu-wien.ac.at
- Created:
- 14.09.2007
Related Files
- packages/acs-subsite/www/admin/system/db-settings.tcl
- packages/acs-subsite/www/admin/system/db-settings.adp
[ hide source ] | [ make this the default ]
File Contents
ad_page_contract { @author Guenter Ernst guenter.ernst@wu-wien.ac.at @creation-date 14.09.2007 } # set cols_sql "select # att.attname # from pg_attribute att inner join pg_class tab on att.attrelid = tab.relfilenode and tab.relname = 'pg_settings' # where att.attnum > 0 # order by att.attnum" # # # set columns [db_list get_cols $cols_sql] # # set order_by [list] # # foreach column $columns { # lappend order_by $column [list label "$column" orderby $column] # } # # if {([info exists orderby] && $orderby ne "") && [lsearch $columns [lindex [split $orderby ","] 0]] == -1} { # unset orderby # } # ###################################################### ###### Create the list template ###################################################### # create list elements set columns [list category name setting unit short_desc extra_desc context vartype source min_val max_val] set elements [list] foreach element $columns { lappend elements $element [list label "$element" sub_class "narrow" html {style "border-right:1px solid #A0BDEB;"} ] } list::create \ -name "pg_settings" \ -multirow "pg_settings" \ -no_data "Keine Daten vorhanden" \ -pass_properties {t c return_url} \ -page_flush_p t \ -elements $elements # ###################################################### # ###### Create the sql query string (for the data) # ###################################################### # set sql_str "select * from pg_settings order by category, name" db_multirow pg_settings get_data $sql_str ad_return_template