Index: openacs-4/packages/ecommerce/www/admin/customer-service/spam-log.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/www/admin/customer-service/spam-log.tcl,v diff -u -r1.1 -r1.2 --- openacs-4/packages/ecommerce/www/admin/customer-service/spam-log.tcl 20 Apr 2001 20:51:14 -0000 1.1 +++ openacs-4/packages/ecommerce/www/admin/customer-service/spam-log.tcl 29 Jan 2002 00:11:46 -0000 1.2 @@ -8,19 +8,12 @@ @cvs-id spam-log.tcl,v 3.0.12.6 2000/09/22 01:34:54 kevin Exp @author ported by Jerry Asher (jerry@theashergroup.com) } { - use_date_range_p:optional start_date:array,date end_date:array,date } ad_require_permission [ad_conn package_id] admin -if { $use_date_range_p == "t" } { - set start_date $start_date(date) - set end_date $end_date(date) -} - - proc spam_to_summary { mailing_list_category_id mailing_list_subcategory_id mailing_list_subsubcategory_id user_class_id product_id full_last_visit_start_date full_last_visit_end_date } { if { ![empty_string_p $mailing_list_category_id] } { return "Members of the [ec_full_categorization_display $mailing_list_category_id $mailing_list_subcategory_id $mailing_list_subsubcategory_id] mailing list." @@ -34,23 +27,18 @@ if { ![empty_string_p $full_last_visit_start_date] } { return "Users whose last visit to the site was between [ec_formatted_full_date $full_last_visit_start_date] and [ec_formatted_full_date $full_last_visit_end_date]." } + return "All users" } - - append doc_body "[ad_admin_header "Spam Log"]

Spam Log

[ad_admin_context_bar [list "../index" "Ecommerce([ec_system_name])"] [list "index" "Customer Service Administration"] [list "spam" "Spam Users"] "Spam Log"]
" -ec_report_get_start_date_and_end_date - -set date_part_of_query "(spam_date >= to_date('$start_date 00:00:00','YYYY-MM-DD HH24:MI:SS') and spam_date <= to_date('$end_date 23:59:59','YYYY-MM-DD HH24:MI:SS'))" -set user_date_range_p "t" append doc_body "
-[ec_report_date_range_widget $start_date $end_date] +[ec_report_date_range_widget $start_date(date) $end_date(date)] [export_form_vars use_date_range_p] @@ -60,12 +48,13 @@ DateToText " -set sql "select spam_text, mailing_list_category_id, mailing_list_subcategory_id, mailing_list_subsubcategory_id, user_class_id, product_id, to_char(last_visit_start_date,'YYYY-MM-DD HH24:MI:SS') as full_last_visit_start_date, to_char(last_visit_end_date,'YYYY-MM-DD HH24:MI:SS') as full_last_visit_end_date, to_char(spam_date,'YYYY-MM-DD HH24:MI:SS') as full_spam_date from ec_spam_log where $date_part_of_query order by spam_date desc" +set start $start_date(date) +set end $end_date(date) set rows_to_return "" -db_foreach get_spam_people $sql { +db_foreach get_spam_people "select spam_text, mailing_list_category_id, mailing_list_subcategory_id, mailing_list_subsubcategory_id, user_class_id, product_id, to_char(last_visit_start_date,'YYYY-MM-DD HH24:MI:SS') as full_last_visit_start_date, to_char(last_visit_end_date,'YYYY-MM-DD HH24:MI:SS') as full_last_visit_end_date, to_char(spam_date,'YYYY-MM-DD HH24:MI:SS') as full_spam_date from ec_spam_log where (spam_date >= to_date('$start 00:00:00','YYYY-MM-DD HH24:MI:SS') and spam_date <= to_date('$end 23:59:59','YYYY-MM-DD HH24:MI:SS')) order by spam_date desc" { - append rows_to_return "[ec_formatted_full_date $full_spam_date][spam_to_summary_sub $mailing_list_category_id $mailing_list_subcategory_id $mailing_list_subsubcategory_id $user_class_id $product_id $full_last_visit_start_date $full_last_visit_end_date][ec_display_as_html $spam_text]" + append rows_to_return "[ec_formatted_full_date $full_spam_date][spam_to_summary $mailing_list_category_id $mailing_list_subcategory_id $mailing_list_subsubcategory_id $user_class_id $product_id $full_last_visit_start_date $full_last_visit_end_date][ec_display_as_html $spam_text]" } append doc_body "$rows_to_return