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

Creating fields with space at the end break the Add entry template

XMLWordPrintable

    • MOODLE_402_STABLE, MOODLE_403_STABLE, MOODLE_404_STABLE
    • MOODLE_402_STABLE, MOODLE_403_STABLE
    • MDL-80765-403
    • MDL-80765-main
    • Hide
      1. Log in as a teacher and go to any course.
      2. Create a new Database activity D1
      3. Use journal preset 
      4. Create a field (short text) called Additional Field
      5. Enter the field name with a space at the end (Additional Field_)
      6. Save it
      7. Edit it again (you will see that at creation the space has been removed)
      8. Enter the field name and add a space at the end (Additional Field_)
      9. Save
      10. Edit it again
      11. Ensure the space has been removed
      12. Go to the template 
      13. Reset all Templates
      14. Check that the entry template [[Additional Field]] has no space at the end
      Show
      Log in as a teacher and go to any course. Create a new Database activity D1 Use journal preset  Create a field (short text) called Additional Field Enter the field name with a space at the end (Additional Field_) Save it Edit it again ( you will see that at creation the space has been removed) Enter the field name and add a space at the end (Additional Field_) Save Edit it again Ensure the space has been removed Go to the template  Reset all Templates Check that the entry template [ [Additional Field] ] has no space at the end
    • 1
    • HQ 2024 Sprint I1.2 Moppies

      If a field name XXX has a space at the end of its name, it is trimmed but the database template for the Add entry is [XXX ] instead of [XXX]

      So the the add entry does not display the form element correctly.

       

            laurent.david@moodle.com Laurent David
            laurent.david@moodle.com Laurent David
            Carlos Escobedo Carlos Escobedo
            Ferran Recio Ferran Recio
            Ron Carl Alfon Yu Ron Carl Alfon Yu
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours, 36 minutes
                2h 36m

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