Index: openacs-4/packages/static-portlet/www/static-portlet.adp
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/static-portlet/www/static-portlet.adp,v
diff -u -r1.13 -r1.14
--- openacs-4/packages/static-portlet/www/static-portlet.adp 22 May 2018 17:30:02 -0000 1.13
+++ openacs-4/packages/static-portlet/www/static-portlet.adp 4 Jul 2018 16:11:47 -0000 1.14
@@ -19,10 +19,10 @@
%>
-
-@content;noquote@
+
+ @content;noquote@
+
-
#new-portal.when_portlet_shaded#
Index: openacs-4/packages/static-portlet/www/static-portlet.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/static-portlet/www/static-portlet.tcl,v
diff -u -r1.12 -r1.13
--- openacs-4/packages/static-portlet/www/static-portlet.tcl 29 Jun 2018 17:27:19 -0000 1.12
+++ openacs-4/packages/static-portlet/www/static-portlet.tcl 4 Jul 2018 16:11:47 -0000 1.13
@@ -24,26 +24,30 @@
array set config $cf
-# one piece of content only per portlet
-set content_id $config(content_id)
-
set success_p 0
-set success_p [db_0or1row select_content {
- select body, pretty_name, format
- from static_portal_content
- where content_id = :content_id
-}]
+if {!$config(shaded_p)} {
+ # one piece of content only per portlet
+ set content_id $config(content_id)
+
+ set success_p [db_0or1row select_content {
+ select body, pretty_name, format
+ from static_portal_content
+ where content_id = :content_id
+ }]
-# The pretty_name can be a message catalog key
-set class_instances_pretty_name [_ dotlrn.class_instances_pretty_name]
-set pretty_name [lang::util::localize $pretty_name]
+ if {$success_p} {
+ # The pretty_name can be a message catalog key
+ set class_instances_pretty_name [_ dotlrn.class_instances_pretty_name]
+ set pretty_name [lang::util::localize $pretty_name]
+
+ set content_w [template::util::richtext::create $body $format]
+ set content [template::util::richtext::get_property html_value $content_w]
+ }
+}
-set content_w [template::util::richtext::create $body $format]
-set content [template::util::richtext::get_property html_value $content_w]
-
# Local variables:
# mode: tcl
# tcl-indent-level: 4