Index: openacs-4/packages/bm-portlet/www/bm-portlet.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/bm-portlet/www/bm-portlet.adp,v diff -u -r1.3 -r1.3.6.1 --- openacs-4/packages/bm-portlet/www/bm-portlet.adp 29 Oct 2002 18:02:48 -0000 1.3 +++ openacs-4/packages/bm-portlet/www/bm-portlet.adp 21 Jun 2004 19:55:37 -0000 1.3.6.1 @@ -20,5 +20,5 @@ Index: openacs-4/packages/dotlrn/catalog/dotlrn.en_US.ISO-8859-1.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/catalog/dotlrn.en_US.ISO-8859-1.xml,v diff -u -r1.33.2.6.4.1 -r1.33.2.6.4.2 --- openacs-4/packages/dotlrn/catalog/dotlrn.en_US.ISO-8859-1.xml 4 May 2004 13:42:22 -0000 1.33.2.6.4.1 +++ openacs-4/packages/dotlrn/catalog/dotlrn.en_US.ISO-8859-1.xml 21 Jun 2004 19:55:38 -0000 1.33.2.6.4.2 @@ -65,6 +65,7 @@ Bulk uploading in progress. cannot be removed Change Locale + Choose the members of %community_name% to receive this message: Classes Class Classes @@ -97,6 +98,7 @@ Community Type Community Types Community's Name + Compose Bulk Message Configure Element Used in title on page for configuring a portal element, i.e. a portal application mini window. @@ -209,6 +211,7 @@ Header Logo Alt Text Header Logo Item ID Help + HTML ID: ID Professor @@ -388,7 +391,9 @@ Memberships Memberships: Message + Message Type Field must have one of the following values: + You must specify at least one recipient for your message My Communities N/A Name @@ -444,6 +449,7 @@ Name Personal home page: Personal Options + Plain Text Portal Templates Portrait: Portrait @@ -492,6 +498,7 @@ seconds. Send Date Send Email + Send to everyone in the group Shared Files silver Site-wide Admin? Index: openacs-4/packages/dotlrn/www/members.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/members.adp,v diff -u -r1.20 -r1.20.6.1 --- openacs-4/packages/dotlrn/www/members.adp 15 Jun 2003 01:24:00 -0000 1.20 +++ openacs-4/packages/dotlrn/www/members.adp 21 Jun 2004 19:55:37 -0000 1.20.6.1 @@ -26,6 +26,6 @@ Index: openacs-4/packages/dotlrn/www/spam-oracle.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/Attic/spam-oracle.xql,v diff -u -r1.2 -r1.2.6.1 --- openacs-4/packages/dotlrn/www/spam-oracle.xql 29 May 2003 18:05:01 -0000 1.2 +++ openacs-4/packages/dotlrn/www/spam-oracle.xql 21 Jun 2004 19:55:37 -0000 1.2.6.1 @@ -46,6 +46,7 @@ membership_rels.rel_id and membership_rels.member_state = 'approved') + $extra_where_clause Index: openacs-4/packages/dotlrn/www/spam-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/Attic/spam-postgresql.xql,v diff -u -r1.2 -r1.2.6.1 --- openacs-4/packages/dotlrn/www/spam-postgresql.xql 29 May 2003 18:05:01 -0000 1.2 +++ openacs-4/packages/dotlrn/www/spam-postgresql.xql 21 Jun 2004 19:55:37 -0000 1.2.6.1 @@ -58,6 +58,7 @@ membership_rels.rel_id and membership_rels.member_state = 'approved') + $extra_where_clause Fisheye: Tag 1.1 refers to a dead (removed) revision in file `openacs-4/packages/dotlrn/www/spam-recipients.adp'. Fisheye: No comparison available. Pass `N' to diff? Fisheye: Tag 1.1 refers to a dead (removed) revision in file `openacs-4/packages/dotlrn/www/spam-recipients.tcl'. Fisheye: No comparison available. Pass `N' to diff? Fisheye: Tag 1.1 refers to a dead (removed) revision in file `openacs-4/packages/dotlrn/www/spam-recipients.xql'. Fisheye: No comparison available. Pass `N' to diff? Index: openacs-4/packages/dotlrn/www/spam.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/spam.tcl,v diff -u -r1.21.6.1 -r1.21.6.2 --- openacs-4/packages/dotlrn/www/spam.tcl 17 Jun 2004 15:05:24 -0000 1.21.6.1 +++ openacs-4/packages/dotlrn/www/spam.tcl 21 Jun 2004 19:55:37 -0000 1.21.6.2 @@ -19,9 +19,23 @@ @creation-date Jan 19, 2002 @version $Id$ } -query { + {recipients:integer,multiple ""} + {recipients_str ""} {community_id ""} {rel_type "dotlrn_member_rel"} {referer "control-panel"} + {spam_all 0} +} -validate { + recipients_specified { + if { ![info exists recipients_str] && ![info exists recipients] } { + ad_complain "[_ dotlrn.Must_specify_recipients]" + } + } + recipients_split { + if { [info exists recipients_str] && ![info exists recipients] } { + set recipients [split $recipients_str] + } + } } -properties { context_bar:onevalue portal_id:onevalue @@ -60,6 +74,7 @@ -label [_ dotlrn.From] \ -datatype text \ -widget hidden \ + -html {size 60} \ -value $sender_email element create spam_message rel_type \ @@ -82,10 +97,10 @@ -html {rows 10 cols 80 wrap soft} element create spam_message message_type \ - -label "Message Type" \ + -label "[_ dotlrn.Message_Type]" \ -datatype text \ -widget select \ - -options {{"Plain text" "text"} {HTML "html"}} \ + -options {{"[_ dotlrn.Plain_Text]" "text"} {"[_ dotlrn.HTML]" "html"}} \ -value "text" element create spam_message send_date \ @@ -101,16 +116,34 @@ -widget hidden \ -value $referer +element create spam_message recipients_str \ + -label Recipients \ + -datatype text \ + -widget hidden \ + -value $recipients + +element create spam_message spam_all \ + -label spam \ + -datatype text \ + -widget hidden \ + -value $spam_all + if {[ns_queryexists "form:confirm"]} { form get_values spam_message \ - community_id from rel_type subject message message_type send_date referer + community_id from rel_type subject message message_type send_date referer recipients_str spam_all set segment_id [db_string select_rel_segment_id {}] set community_name [dotlrn_community::get_community_name $community_id] set community_url "[ad_parameter -package_id [ad_acs_kernel_id] SystemURL][dotlrn_community::get_community_url $community_id]" + set recipients_str [join [split $recipients_str] ,] set safe_community_name [db_quote $community_name] + if { $spam_all } { + set extra_where_clause "" + } else { + set extra_where_clause "and parties.party_id in ($recipients_str)" + } set query [db_map sender_info] ns_log notice "query: $query" Index: openacs-4/packages/dotlrn-portlet/www/dotlrn-members-portlet.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-portlet/www/dotlrn-members-portlet.adp,v diff -u -r1.13.2.1.4.1 -r1.13.2.1.4.2 --- openacs-4/packages/dotlrn-portlet/www/dotlrn-members-portlet.adp 13 May 2004 15:10:41 -0000 1.13.2.1.4.1 +++ openacs-4/packages/dotlrn-portlet/www/dotlrn-members-portlet.adp 21 Jun 2004 19:55:38 -0000 1.13.2.1.4.2 @@ -60,7 +60,7 @@