mirror of
https://github.com/moodle/moodle.git
synced 2025-04-14 04:52:36 +02:00
MDL-66552 core: move and rename relativedatestimediffformat string
AMOS BEGIN MOV [relativedatestimediffformat,moodle],[dateintervaldayshoursmins,langconfig] AMOS END
This commit is contained in:
parent
310d6901f9
commit
b9679e69ec
@ -24,6 +24,7 @@
|
||||
|
||||
$string['alphabet'] = 'A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z';
|
||||
$string['backupnameformat'] = '%Y%m%d-%H%M';
|
||||
$string['dateintervaldayshoursmins'] = '%ad %hh %im'; // See https://www.php.net/manual/en/dateinterval.format.php for format.
|
||||
$string['decsep'] = '.';
|
||||
$string['firstdayofweek'] = '1';
|
||||
$string['iso6391'] = 'en';
|
||||
|
@ -1639,7 +1639,6 @@ $string['rejectdots'] = 'Reject...';
|
||||
$string['relativedatesmode'] = 'Relative dates mode';
|
||||
$string['relativedatesmode_help'] = 'Display course or activity dates relative to the user\'s start date in the course.<br />The user\'s course start date will be their enrolment start date, unless they are enrolled before the course begins in which case their start date will be the course start date.<br/><strong>WARNING: This is an experimental feature and not all activities may support it. Once the course has been created, this course setting can no longer be changed.</strong>';
|
||||
$string['relativedatesmode_warning'] = '<strong>Warning:</strong> Relative dates mode cannot be changed once the course has been created.';
|
||||
$string['relativedatestimediffformat'] = '%ad %hh %im';
|
||||
$string['reload'] = 'Reload';
|
||||
$string['remoteappuser'] = 'Remote {$a} User';
|
||||
$string['remove'] = 'Remove';
|
||||
|
@ -2393,7 +2393,7 @@ function get_time_interval_string(int $time1, int $time2, string $format = ''):
|
||||
$dtdate2 = new DateTime();
|
||||
$dtdate2->setTimeStamp($time2);
|
||||
$interval = $dtdate2->diff($dtdate);
|
||||
$format = empty($format) ? get_string('relativedatestimediffformat', 'moodle') : $format;
|
||||
$format = empty($format) ? get_string('dateintervaldayshoursmins', 'langconfig') : $format;
|
||||
return $interval->format($format);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user