"
} else {
ns_log Debug "NOTIF-BATCHED: NO content to send!"
}
@@ -113,7 +120,33 @@
# append content to built-up content
ns_log Debug "NOTIF-BATCHED: appending one notif!"
- append batched_content "[_ notifications.SUBJECT] [ns_set get $notif notif_subject]\n[ns_set get $notif notif_text]\n\n\n=====================\n\n\n"
+ #Lets see what we have:
+ set notif_text [ns_set get $notif notif_text]
+ set notif_html [ns_set get $notif notif_html]
+
+ if {[empty_string_p $notif_text]} {
+ set notif_text [ad_html_text_convert -from html -to text $no
+tif_html]
+ }
+
+ if {[empty_string_p $notif_html]} {
+ set notif_html [ad_html_text_convert -from text -to html $no
+tif_text]
+ } else {
+ set html_content_p 1
+ }
+
+ append summary_text "[ns_set get $notif notif_subject]\n"
+ append summary_html "- [ns_set get $notif notif_subject]
"
+
+ append batched_content_text "[_ notifications.SUBJECT] [ns_set get $notif notif_s
+ubject]\n[ns_set get $notif notif_text]\n=====================\n"
+ append batched_content_html "[_ notifications.SUBJECT] [ns_set get $notif notif_subject]\n $notif_html
"
+ lappend list_of_notification_ids [ns_set get $notif notification
+_id]
+
lappend list_of_notification_ids [ns_set get $notif notification_id]
# Set the vars
@@ -132,7 +165,8 @@
-to_user_id [ns_set get $notif user_id] \
-notification_type_id [ns_set get $notif type_id] \
-subject [ns_set get $notif notif_subject] \
- -content [ns_set get $notif notif_text] \
+ -content_text [ns_set get $notif notif_text] \
+ -content_html [ns_set get $notif notif_html] \
-reply_object_id [ns_set get $notif response_id] \
-delivery_method_id [ns_set get $notif delivery_method_id]