Index: openacs-4/packages/acs-subsite/www/admin/themes/index.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/www/admin/themes/index.tcl,v
diff -u -r1.3 -r1.4
--- openacs-4/packages/acs-subsite/www/admin/themes/index.tcl 11 Aug 2017 12:54:40 -0000 1.3
+++ openacs-4/packages/acs-subsite/www/admin/themes/index.tcl 3 Sep 2024 15:37:34 -0000 1.4
@@ -23,13 +23,13 @@
sub_class narrow
display_template {
-
+
}
link_url_eval {[export_vars -base view { {theme $key} }]}
link_html { title "#acs-subsite.Edit_this_theme#" }
}
-
+
key {
label "[_ acs-subsite.Key]"
}
@@ -45,16 +45,15 @@
label "[_ acs-subsite.Active_theme]"
display_template {
-
+
-
+
}
+ html { align center }
}
modified_p {
label "[_ acs-subsite.Modified_theme]"
@@ -71,18 +70,18 @@
-
+
Save new
}
+ html { align center }
}
delete {
sub_class narrow
display_template {
-
+
}
link_url_eval {[export_vars -base delete { {theme $key} }]}
@@ -93,8 +92,7 @@
set subsite_id [ad_conn subsite_id]
set currentThemeKey [parameter::get -parameter ThemeKey -package_id $subsite_id]
-set package_keys '[join [subsite::package_keys] ',']'
-
+set package_keys [subsite::package_keys]
db_multirow -extend {active_p modified_p delete_p usage_count} themes select_themes {} {
set active_p [expr {$currentThemeKey eq $key}]
set modified_p [expr {$active_p && [subsite::get_theme_subsites \
@@ -105,7 +103,7 @@
select count(*)
from apm_parameters p, apm_parameter_values v
where p.parameter_name = 'ThemeKey'
- and p.package_key in ($package_keys)
+ and p.package_key in ([ns_dbquotelist $package_keys])
and p.parameter_id = v.parameter_id
and v.attr_value = :key
}]]