Index: openacs-4/packages/survey/catalog/survey.en_US.ISO-8859-1.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/survey/catalog/survey.en_US.ISO-8859-1.xml,v diff -u -r1.10.2.1 -r1.10.2.2 --- openacs-4/packages/survey/catalog/survey.en_US.ISO-8859-1.xml 4 May 2004 13:42:37 -0000 1.10.2.1 +++ openacs-4/packages/survey/catalog/survey.en_US.ISO-8859-1.xml 1 Sep 2004 19:09:29 -0000 1.10.2.2 @@ -73,19 +73,16 @@ - Removes all questions and responses A database error occured while trying to swap your questions. Here's the error: - Already Responsed: %n_responses users% + Already Responsed: %n_responses% users View these users. <%community_url%/survey/admin/respondents?response_type=responded> Spam these users. <%community_url%/survey/admin/send-mail?survey_id=%survey_id%&to=responded> - Already Responsed: %n_responses users% - -View these users. <%community_url%/survey/admin/respondents?response_type=responded> - -Spam these users. <%community_url%/survey/admin/send-mail?survey_id=%survey_id%&to=responded> - + Already Responsed: %n_responses% users + View these users + Email these users Answers to %survey_name% - Awaiting a response: %n_awaiting users% + Awaiting a response: %n_awaiting% users View these users. <%community_url%/survey/admin/respondents?response_type=not_responded> @@ -169,16 +166,9 @@ Survey %section_id% does not exist Survey %survey_id% does not exist Survey %survey_id% does not exist - Survey: %survey_name% -Respondent: %user_name% - -Here is what %user_name% %comm_url% -had to say in response to %survey_name%: - Survey: %survey_name% -Respondent: %user_name% - -Here is what %user_name% <%comm_url%> -had to say in response to %survey_name%: + Survey: %survey_name% + Respondent: %user_name% + Here is what %user_name% had to say in response to %survey_name%: The Above Description is The response to %question_text% must be an integer. Your answer was %response_value%. The response to %question_text% must be a number. Your answer was %response_value%. Index: openacs-4/packages/survey/tcl/survey-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/survey/tcl/survey-procs.tcl,v diff -u -r1.5 -r1.5.2.1 --- openacs-4/packages/survey/tcl/survey-procs.tcl 22 Dec 2003 21:16:02 -0000 1.5 +++ openacs-4/packages/survey/tcl/survey-procs.tcl 1 Sep 2004 19:09:29 -0000 1.5.2.1 @@ -261,12 +261,14 @@ } if $html_p { - append return_string "# $sort_order: $question_text -
" + append return_string "# $sort_order: $question_text

" + append return_string "[ad_enhanced_text_to_html "$clob_answer $number_answer $varchar_answer $date_answer"]" } else { - append return_string "# $sort_order: $question_text: " + append return_string "$sort_order: " + append return_string [ad_html_to_text $question_text] + append return_string "\n\n" + append return_string "[ad_html_to_text [ad_enhanced_text_to_html "$clob_answer $number_answer $varchar_answer $date_answer"]]" } - append return_string [util_show_plain_text "$clob_answer $number_answer $varchar_answer $date_answer"] if {![empty_string_p $attachment_answer]} { set package_id [ad_conn package_id] @@ -422,42 +424,54 @@ db_1row get_response_info {} set notif_text "" + set notif_html "" + if {$dotlrn_installed_p} { append notif_text "\nGroup: $community_name" + append notif_html "Group: $community_name
" + } set comm_url "[ad_parameter -package_id [ad_acs_kernel_id] SystemURL][acs_community_member_url -user_id $responding_user_id]" - append notif_text "\n[_ survey.lt_Survey_survey_nameRes_1]\n" + append notif_text "\n[_ survey.lt_Survey_survey_name]" + append notif_text "\n[_ survey.lt_Survey_survey_Res]\n" + append notif_text "\n[_ survey.lt_Survey_survey_notif_intro]\n" + + append notif_html "[_ survey.lt_Survey_survey_name]
" + append notif_html "[_ survey.lt_Survey_survey_Res]
" + append notif_html "[_ survey.lt_Survey_survey_notif_intro]

" + + if {$edit_p} { append notif_text "\n[_ survey.Edited] " + append notif_html "
[_ survey.Edited]  " } - append notif_text "[_ survey.lt_Response_on_response_]\n" + append notif_text "[_ survey.lt_Response_on_response_]\n\n" + append notif_html "[_ survey.lt_Response_on_response_] :

" + append notif_text [survey_answer_summary_display $response_id 0] + append notif_html [survey_answer_summary_display $response_id 1] # add summary info for sloanspace if {$dotlrn_installed_p} { - set n_responses [db_string n_responses {}] - if {$n_responses > 0} { - append notif_text " -----\n[_ survey.lt_Already_Responsed_n_r_1]\n" - } - set n_members [db_string n_members {}] - set n_awaiting [expr {$n_members - $n_responses}] - - append notif_text "\n[_ survey.lt_Awaiting_a_response_n]\n" - db_foreach get_questions {} { - append notif_text "$sort_order. $question_text - [_ survey.View_responses_1] <$community_url/survey/view-text-responses?question_id=$question_id>\n" + # only doing the summary for HTML version because + # all the links make the text version a mess + append notif_html "$sort_order. $question_text - [_ survey.View_responses_1]
" } } + append notif_html "

" + notification::new \ -type_id [notification::type::get_type_id \ -short_name survey_response_notif] \ -object_id $survey_id \ -response_id $survey_id \ -notif_subject $subject \ - -notif_text $notif_text + -notif_text $notif_text \ + -notif_html $notif_html }