--- loncom/interface/statistics/lonproblemstatistics.pm 2011/12/21 21:25:51 1.120
+++ loncom/interface/statistics/lonproblemstatistics.pm 2018/03/07 13:32:56 1.122.2.4
@@ -1,6 +1,6 @@
# The LearningOnline Network with CAPA
#
-# $Id: lonproblemstatistics.pm,v 1.120 2011/12/21 21:25:51 www Exp $
+# $Id: lonproblemstatistics.pm,v 1.122.2.4 2018/03/07 13:32:56 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -52,7 +52,6 @@ package Apache::lonproblemstatistics;
use strict;
use Apache::lonnet;
use Apache::loncommon();
-use Apache::lonquickgrades();
use Apache::lonhtmlcommon;
use Apache::loncoursedata;
use Apache::lonstatistics;
@@ -74,6 +73,14 @@ my %SeqStat; # keys are symbs, values
## header for plots created with Graph.pm, both of which more than likely do
## not support localization.
##
+## Additional Notes:
+## Localization can be done and is done before passing the phrases
+## to the output.
+## This might conflict with special characters, e.g. German Umlaute or
+## chinese characters. Do not use such characters in this case.
+## If this failed, consider that the sequence and folder names
+## are also passed to the output and would fail the same way.
+##
#
#
##
@@ -85,7 +92,7 @@ my %SeqStat; # keys are symbs, values
## title yes any scalar This is what the user sees to identify
## the field. Passed through &mt().
## long_title yes any scalar Used as graph heading and in excel
-## output. NOT translated
+## output. Passed through &mt().
## align no (left|right|center) HTML cell contents alignment
## color yes html color HTML cell background color
## used to visually group statistics
@@ -175,7 +182,7 @@ my @Fields = (
format => '%d',
sortable => 'yes',
graphable => 'yes',
- long_title => 'Minumum Number of Tries',
+ long_title => 'Minimum Number of Tries',
selectable => 'yes',
defaultselected => 'yes',
},
@@ -275,7 +282,7 @@ my @Fields = (
sortable => 'yes',
graphable => 'yes',
long_title => 'Degree of Difficulty'.
- '[ 1 - ((#YES+#yes) / Tries) ]',
+ ' ~[ 1 - ((#YES+#yes) / Tries) ~]',
selectable => 'yes',
defaultselected => 'yes',
},
@@ -431,7 +438,7 @@ my @SeqFields = (
format => '%4.2f',
sortable => 'no',
graphable => 'no',
- long_title => 'Minumum Sequence Score',
+ long_title => 'Minimum Sequence Score',
selectable => 'yes',
defaultselected => 'no',
},
@@ -486,7 +493,7 @@ my @SeqFields = (
format => '%4.2f',
sortable => 'no',
graphable => 'no',
- long_title => 'Minumum Number of Correct Problems',
+ long_title => 'Minimum Number of Correct Problems',
selectable => 'yes',
defaultselected => 'no',
},
@@ -579,14 +586,14 @@ sub parse_field_selection {
sub field_selection_input {
my $Str = '\n";
}
@@ -611,7 +618,6 @@ sub CreateInterface {
&parse_field_selection();
#
my $Str = '';
- $Str .= '
".&mt('Compiled on [_1]',
- &Apache::lonlocal::locallocaltime(time))."
";
+ $Str .= "
".&mt('Compiled on [_1]',
+ &Apache::lonlocal::locallocaltime(time))."
";
return $Str;
}
@@ -897,7 +898,7 @@ sub statistics_html_table_data {
foreach my $field (@Fields) {
next if ($options =~ /no $field->{'name'}/);
next if ($field->{'selected'} ne 'yes');
- $row .= '
{'color'}.'"';
if (exists($field->{'align'})) {
$row .= ' align="'.$field->{'align'}.'"';
}
@@ -925,14 +926,16 @@ sub statistics_table_header {
next if ($options =~ /no $field->{'name'}/);
next if ($field->{'selected'} ne 'yes');
$header_row .= '
';
+ my $Str .= &Apache::loncommon::start_data_table_header_row();
foreach my $field (@SeqFields) {
# next if ($field->{'selected'} ne 'yes');
$Str .= '