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

Backup/Restore of custom user field conditions doesn't work on different sites.

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      1. Log in as an admin
      2. Create a user profile field with the following details:
        • Type = menu
        • Name = colour
        • Values = Red, Green, Blue, Yellow, Orange, Pink, Purple, Magenta, Cyan, Turquoise, Brown
      3. Restore the backup attached to this issue as a new course.
      4. Check that the forum in there has a condition on the colour profile field (not equal to Undecided I think)
      5. Check that there is no condition for a profile field called gender.
      Show
      Log in as an admin Create a user profile field with the following details: Type = menu Name = colour Values = Red, Green, Blue, Yellow, Orange, Pink, Purple, Magenta, Cyan, Turquoise, Brown Restore the backup attached to this issue as a new course. Check that the forum in there has a condition on the colour profile field (not equal to Undecided I think) Check that there is no condition for a profile field called gender.
    • Affected Branches:
      MOODLE_24_STABLE
    • Fixed Branches:
      MOODLE_24_STABLE
    • Pull Master Branch:
      wip-MDL-34220-m24

      Description

      There is a bug within the backup and restore of user field conditions for modules and sections.
      Presently when backing up a user field condition if its a custom field the id of the field is recorded and then upon restore we check that a custom field with the same id is checked for existence.
      The problem is that id doesn't identify the custom field, theres nothing to say that custom field 5 is the same on sites a and b.
      Really we should be recording something more meaningfull, like name, and then searching for and mapping that upon restore.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              samhemelryk Sam Hemelryk
              Reporter:
              samhemelryk Sam Hemelryk
              Integrator:
              Dan Poltawski Dan Poltawski
              Tester:
              Rossiani Wijaya Rossiani Wijaya
              Participants:
              Component watchers:
              Sam Marshall, Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Sara Arjona (@sarjona)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                3/Dec/12