--- loncom/interface/lonfeedback.pm 2001/12/19 17:17:46 1.19 +++ loncom/interface/lonfeedback.pm 2001/12/27 18:37:32 1.20 @@ -1,7 +1,7 @@ # The LearningOnline Network # Feedback # -# $Id: lonfeedback.pm,v 1.19 2001/12/19 17:17:46 albertel Exp $ +# $Id: lonfeedback.pm,v 1.20 2001/12/27 18:37:32 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -39,7 +39,7 @@ # 2/13 Guy Albertelli # 7/25 Gerd Kortemeyer # 7/26 Guy Albertelli -# 7/26,8/10,10/1,11/5,11/6 Gerd Kortemeyer +# 7/26,8/10,10/1,11/5,11/6,12/27 Gerd Kortemeyer package Apache::lonfeedback; @@ -195,14 +195,15 @@ sub screen_header { '
'. 'Question/Comment/Feedback about course policy'; } + if ($ENV{'request.course.id'}) { + if (&Apache::lonnet::allowed('pch',$ENV{'request.course.id'})) { $options.='
'. 'Contribution to course discussion of resource'; - } - if ($ENV{'request.course.id'}) { $options.='
'. 'Anonymous contribution to course discussion of resource'. ' (name only visible to course faculty)'; + } } return $options; } @@ -309,6 +310,8 @@ sub send_msg { sub adddiscuss { my ($symb,$email,$anon)=@_; my $status=''; + if (&Apache::lonnet::allowed('pch',$ENV{'request.course.id'})) { + my %contrib=('message' => $email, 'sendername' => $ENV{'user.name'}, 'senderdomain' => $ENV{'user.domain'}); @@ -329,6 +332,9 @@ sub adddiscuss { $newrecord{'subnumber'}=$record{'subnumber'}+1; $status.=' '.&Apache::lonnet::cstore(\%newrecord,'_discussion'); } + } else { + $status.='Failed.'; + } return $status.'
'; }