Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
3.0
-
MOODLE_30_STABLE
-
MOODLE_30_STABLE
-
wip-
MDL-51888-master -
Description
Basically a follow on from MDL-40836 because we wanted it landed
- The behat tests need making more robust/not gonna break in 2016
And I <seedate> see "2015" in the ".activity.resource .resourcelinkdetails" "css_element"
- I think that we should shorten the date string and check with marycooch and tsala for advice about the wording (I wasn't sure about the word 'on' in 'Uploaded on Friday, 23 October 2015, 6:07 am'). This was my shortened date string, maybe we just want the date and not the time:
diff --git a/mod/resource/locallib.php b/mod/resource/locallib.php
index e705f95..8e939b7 100644
--- a/mod/resource/locallib.php
+++ b/mod/resource/locallib.php
@@ -326,9 +326,9 @@ function resource_get_optional_details($resource, $cm) {
$modifieddate = $mainfile->get_timemodified();
if ($modifieddate > $uploaddate) {
- $date = get_string('modifieddate', 'mod_resource', userdate($modifieddate));
+ $date = get_string('modifieddate', 'mod_resource', userdate($modifieddate, get_string('strftimedatetimeshort', 'langconfig')));
} else {
- $date = get_string('uploadeddate', 'mod_resource', userdate($uploaddate));
+ $date = get_string('uploadeddate', 'mod_resource', userdate($uploaddate, get_string('strftimedatetimeshort', 'langconfig')));
}
$langstring .= 'date';
$infodisplayed += 1;
- Marina's localisation/caching fix might need new issue for backporting creating.