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

Custom profile field 'Text input' type default maximum length value incorrect for proper toggling as a custom identity field

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 3.10.9
    • General, User management
    • None
    • MOODLE_310_STABLE

      I wouldn't consider this so much a bug as an oversight post MDL-45242, but when you add a 'Text input' type custom user profile field via 'Site Administration >> Users >> Accounts >> User profile fields', the default value for the 'Maximum length' value is 2048 characters. As of 25/02/22, this is observable in the 3.11.5 https://sandbox.moodledemo.net/ site. 

      Unless this value is set to 255 characters, it will not show up as a valid custom identity field under Site Adminsitration >> Users >> Permissions >> User policies >> Show user identity (showuseridentity).

      This isn't a documented requirement for end-users. The discussion between Leon Stringer and Tim Hunt on this tracker here https://tracker.moodle.org/browse/MDL-45242 indicate that this is the maximum value that can be supported for this kind of field.

      My recommendation would be to either implement a tooltip indicating this requirement to users when creating this kind of custom profile field or the default value needs to be changed to 255.  

      STEPS TO REPLICATE: 

      1. With any 3.11 versioned site, go to 'Site Administration >> Users >> Accounts >> User profile fields' and create a 'Text input' type custom user profile field
      2. Give it a shortname and a name. Leave all defaults and observe the default populated value for the Maximum length setting is 2048 characters.
      3. In a new tab, go to 'Site Adminsitration >> Users >> Permissions >> User policies >> Show user identity (showuseridentity)' and observe this newly created custom field is not visible and selectable.
      4. Go back to the user profile field page and edit your custom field, changing the Maximum length value to 255 characters and save
      5. Return to the user policies tab, refresh and observe the custom field is now showing and selectable

            Unassigned Unassigned
            Alexander Williams Alex Williams
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.