Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-41248

translation not possible for: Days left x of y

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.5.1, 2.5.2, 2.6
    • Fix Version/s: 2.5.5, 2.6.2, 2.7
    • Component/s: Course completion
    • Labels:
    • Testing Instructions:
      Hide

      1. Turn on completion tracking in a course.
      2. In the 'Course completion' settings, set an 'Enrolment duration' rule.
      3. Add the 'Course completion status' block to the course.
      4. Make sure the "Enrolment duration 0 of 10" message is correct.
      5. review the code to verify it is using get_string, not a hard-coded string.

      Show
      1. Turn on completion tracking in a course. 2. In the 'Course completion' settings, set an 'Enrolment duration' rule. 3. Add the 'Course completion status' block to the course. 4. Make sure the "Enrolment duration 0 of 10" message is correct. 5. review the code to verify it is using get_string, not a hard-coded string.
    • Affected Branches:
      MOODLE_25_STABLE, MOODLE_26_STABLE
    • Fixed Branches:
      MOODLE_25_STABLE, MOODLE_26_STABLE, MOODLE_27_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      There is no translation possible for
      the word "of" because is hardcoded in the code
      moodle / completion / criteria / completion_criteria_duration.php
      line 193:
      return ($daysleft > 0 ? $daysleft : 0).' of '

      needs to be some thing like:

      return ($daysleft > 0 ? $daysleft : 0).get_string('of', 'completion').$enrolperiod;

      and add in moodle /lang / en / completion.php
      $string['of'] = 'of';

        Attachments

          Activity

            People

            Assignee:
            timhunt Tim Hunt
            Reporter:
            mrmuehle Guido Hornig
            Peer reviewer:
            Guido Hornig
            Integrator:
            Dan Poltawski
            Tester:
            Dan Poltawski
            Participants:
            Component watchers:
            Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              10/Mar/14