Skip to content

Commit

Permalink
Merge branch 'MDL-41248' of git://github.com/timhunt/moodle
Browse files Browse the repository at this point in the history
  • Loading branch information
danpoltawski committed Mar 5, 2014
2 parents 23d142e + 8d3debf commit 3be87d8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions completion/criteria/completion_criteria_duration.php
Expand Up @@ -165,7 +165,7 @@ public function get_title() {
* @return string * @return string
*/ */
public function get_title_detailed() { public function get_title_detailed() {
return ceil($this->enrolperiod / (60 * 60 * 24)) . ' days'; return get_string('xdays', 'completion', ceil($this->enrolperiod / (60 * 60 * 24)));
} }


/** /**
Expand All @@ -190,7 +190,8 @@ public function get_status($completion) {


$daysleft = ceil($timeleft / (60 * 60 * 24)); $daysleft = ceil($timeleft / (60 * 60 * 24));


return ($daysleft > 0 ? $daysleft : 0).' of '.$enrolperiod; return get_string('daysoftotal', 'completion', array(
'days' => $daysleft > 0 ? $daysleft : 0, 'total' => $enrolperiod));
} }


/** /**
Expand Down
1 change: 1 addition & 0 deletions lang/en/completion.php
Expand Up @@ -111,6 +111,7 @@
$string['csvdownload'] = 'Download in spreadsheet format (UTF-8 .csv)'; $string['csvdownload'] = 'Download in spreadsheet format (UTF-8 .csv)';
$string['datepassed'] = 'Date passed'; $string['datepassed'] = 'Date passed';
$string['days'] = 'Days'; $string['days'] = 'Days';
$string['daysoftotal'] = '{$a->days} of {$a->total}';
$string['deletecompletiondata'] = 'Delete completion data'; $string['deletecompletiondata'] = 'Delete completion data';
$string['dependencies'] = 'Dependencies'; $string['dependencies'] = 'Dependencies';
$string['dependenciescompleted'] = 'Completion of other courses'; $string['dependenciescompleted'] = 'Completion of other courses';
Expand Down

0 comments on commit 3be87d8

Please sign in to comment.