Index: openacs-4/packages/acs-admin/www/index.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/index.tcl,v diff -u -r1.17 -r1.17.2.1 --- openacs-4/packages/acs-admin/www/index.tcl 7 Aug 2017 23:47:45 -0000 1.17 +++ openacs-4/packages/acs-admin/www/index.tcl 3 May 2020 16:46:05 -0000 1.17.2.1 @@ -6,61 +6,61 @@ } set page_title [ad_conn instance_name] -set package_keys '[join [subsite::package_keys] ',']' +set package_ids [subsite::package_keys] set subsite_number [db_string count_subsites [subst { select count(p.package_id) from apm_packages p, site_nodes s - where package_key in ($package_keys) + where package_key in ([ns_dbquotelist $package_ids]) and s.object_id = p.package_id }]] db_multirow -extend { admin_url global_param_url } packages installed_packages {} { set package_type [db_string get_package_type { - select package_type from apm_package_types + select package_type from apm_package_types where package_key = :package_key }] if { - [apm_package_installed_p $package_key] + [apm_package_installed_p $package_key] && $package_type ne "apm_service" - && [file exists "[acs_package_root_dir $package_key]/www/sitewide-admin/"] + && [file exists "[acs_package_root_dir $package_key]/www/sitewide-admin/"] } { set admin_url "package/$package_key/" } else { set admin_url "" } if { ![db_0or1row global_params_exist {}] - || $global_params == 0 + || $global_params == 0 } { - set global_param_url "" + set global_param_url "" } else { - set return_url [ad_conn url] + set return_url [ad_conn url] set global_param_url [export_vars -base /shared/parameters {package_key return_url {scope global}}] } if { $admin_url eq "" && $global_param_url eq "" } { continue } -} +} template::list::create \ -name packages \ -multirow packages \ -elements { pretty_name { label "Package" - html {align left} + html {align left} } admin_url { label "Site-Wide Administration" link_html { title "Site-wide Administration" } link_url_col admin_url display_template {#acs-admin.Administration#} - html {align left} + html {align left} } global_param_url { label "Global Parameters" link_html {title "Manage Global Parameters" } link_url_col global_param_url display_template {#acs-admin.Parameters#} - html {align left} + html {align left} } } @@ -70,4 +70,3 @@ # tcl-indent-level: 4 # indent-tabs-mode: nil # End: -