Index: openacs-4/packages/dotlrn-ecommerce/www/application-approve.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-ecommerce/www/application-approve.tcl,v
diff -u -r1.14 -r1.15
--- openacs-4/packages/dotlrn-ecommerce/www/application-approve.tcl	6 Sep 2005 04:25:43 -0000	1.14
+++ openacs-4/packages/dotlrn-ecommerce/www/application-approve.tcl	21 Sep 2005 00:33:57 -0000	1.15
@@ -33,7 +33,7 @@
     prereq {
 	set new_member_state "request approved"
 	set old_member_state "request approval"
-	set email_type "prereq approved"
+	set email_type "prereq approval"
     }
     payment {
 	set new_member_state "payment received"
@@ -102,7 +102,7 @@
             } \
             -on_request {
 		set reason [lindex [lindex [callback dotlrn::default_member_email -community_id $community_id -to_user $user_id -type "prereq approval"] 0] 2]
-		set var_list [lindex [callback dotlrn::member_email_var_list -community_id $community_id -to_user $user_id -type $type] 0]
+		array set vars [lindex [callback dotlrn::member_email_var_list -community_id $community_id -to_user $user_id -type $type] 0]
 	    set email_vars [lang::message::get_embedded_vars $reason]
 	    foreach var [concat $email_vars] {
 		if {![info exists vars($var)]} {
Index: openacs-4/packages/dotlrn-ecommerce/www/application-reject.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-ecommerce/www/application-reject.tcl,v
diff -u -r1.15 -r1.16
--- openacs-4/packages/dotlrn-ecommerce/www/application-reject.tcl	7 Sep 2005 08:30:38 -0000	1.15
+++ openacs-4/packages/dotlrn-ecommerce/www/application-reject.tcl	21 Sep 2005 00:33:57 -0000	1.16
@@ -94,6 +94,7 @@
             {user_id:text(hidden)}
             {community_id:text(hidden)}
             {type:text(hidden)}
+	    {subject:text {html {size 60}}}
             {reason:text(textarea),optional {label "[_ dotlrn-ecommerce.Reason]"} {html {rows 10 cols 60}}}
 	}
 
@@ -113,10 +114,12 @@
 	-form {
         } \
         -on_request {
-	    set reason [lindex [lindex [callback dotlrn::default_member_email -community_id $community_id -to_user $user_id -type "prereq reject"] 0] 2]
-	    set var_list [lindex [callback dotlrn::member_email_var_list -community_id $community_id -to_user $user_id -type $type] 0]
+	    set reason_email [lindex [callback dotlrn::default_member_email -community_id $community_id -to_user $user_id -type "prereq reject"] 0]
+	    set reason [lindex $reason_email 2]
+	    set subject [lindex $reason_email 1]
+	    array set vars [lindex [callback dotlrn::member_email_var_list -community_id $community_id -to_user $user_id -type $type] 0]
 	    set email_vars [lang::message::get_embedded_vars $reason]
-	    foreach var [concat $email_vars] {
+	    foreach var $email_vars {
 		if {![info exists vars($var)]} {
 		    set vars($var) ""
 		}