Moodle
  1. Moodle
  2. MDL-31193

Security keys page: 'valid until' information is not matching the user language

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2.1, 2.2.9, 2.3.6, 2.4.3, 2.5
    • Fix Version/s: 2.3.7, 2.4.4
    • Component/s: Web Services
    • Labels:
    • Testing Instructions:
      Hide

      To do this test you'll need to create a token with a valid until date for a manager.

      Go to Admin > Plugins > Web service > Manage token
      Check that a token with a "Valid until" date has the correct date displayed in the correct user language.

      Connect as Manager
      Go to Edit profile > My security keys
      Check that a token with a "Valid until" date has the correct date displayed in the correct user language.

      Show
      To do this test you'll need to create a token with a valid until date for a manager. Go to Admin > Plugins > Web service > Manage token Check that a token with a "Valid until" date has the correct date displayed in the correct user language. Connect as Manager Go to Edit profile > My security keys Check that a token with a "Valid until" date has the correct date displayed in the correct user language.
    • Affected Branches:
      MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_24_STABLE, MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE, MOODLE_24_STABLE
    • Pull 2.4 Branch:
    • Pull Master Branch:
      MDL-31193-master
    • Rank:
      37635

      Description

      webservice/renderer.php: user_webservice_tokens_box()

      Fix the following TODO:

      if (!empty($token->validuntil)) {
          $validuntil = date("F j, Y"); //TODO: language support (look for moodle function)
      }
      

      To see the 'valid until' information on your security keys page: you need to be a non admin user who has a token. The admin need to have set you up as an authorised user, and to have also set you up a 'valid until'.

        Issue Links

          Activity

          Hide
          Dan Poltawski added a comment -

          heh, we weren't even using the date at all before?!

          Show
          Dan Poltawski added a comment - heh, we weren't even using the date at all before?!
          Hide
          Dan Poltawski added a comment -

          Hi Jerome,

          Looks OK to me - only thing is that you could avoid the core_ prefix in the lange strings and just use langconfig (I think thats more conventional in moodle atm).

          cheers,
          dan

          Show
          Dan Poltawski added a comment - Hi Jerome, Looks OK to me - only thing is that you could avoid the core_ prefix in the lange strings and just use langconfig (I think thats more conventional in moodle atm). cheers, dan
          Hide
          Jérôme Mouneyrac added a comment -

          Done

          Show
          Jérôme Mouneyrac added a comment - Done
          Hide
          Damyon Wiese added a comment -

          wrong date in the wrong language!

          Show
          Damyon Wiese added a comment - wrong date in the wrong language!
          Hide
          Damyon Wiese added a comment -

          Thanks Jerome,

          This is not a security issue so has not been applied to 22.

          Integrated to 23, 24 and master.

          Show
          Damyon Wiese added a comment - Thanks Jerome, This is not a security issue so has not been applied to 22. Integrated to 23, 24 and master.
          Hide
          Andrew Davis added a comment -

          After some initial confusion this appears to be working. Passing.

          Show
          Andrew Davis added a comment - After some initial confusion this appears to be working. Passing.
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Did you think this day was not going to arrive ever?

          Your patience has been rewarded, yay, sent upstream, thanks!

          Closing...ciao

          Show
          Eloy Lafuente (stronk7) added a comment - Did you think this day was not going to arrive ever? Your patience has been rewarded, yay, sent upstream, thanks! Closing...ciao

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: