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

edit numercial options are not tested correctly before setting the defaults when editing a question with no answer

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0
    • Fix Version/s: 2.0.1
    • Component/s: Questions
    • Labels:
      None
    • Affected Branches:
      MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE

      Description

      When there is no answer in a question using the numerical options (numerical, calculated ...) the function get_question_options(&$question) return without setting default values for numerical options.

      When editing the question, the code setting the default_values
      if (isset($question->options)){
      $default_values['unitgradingtypes'] = 1 ;

      should be replaced by
      if (isset($question->options->unitgradingtypes)){
      $default_values['unitgradingtypes'] = 1 ;
      and so on...

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            ppichet Pierre Pichet added a comment -

            CVS on HEAD and setting a new MOODLE 20 test site before merging (before GIT...)

            Show
            ppichet Pierre Pichet added a comment - CVS on HEAD and setting a new MOODLE 20 test site before merging (before GIT...)
            Hide
            ppichet Pierre Pichet added a comment -

            I just understand the 2,0 is not a branch. So merging with 2,0 will have to wait...
            So setting it as resolved (and tested OK on HEAd and on my local 2,0 )

            Show
            ppichet Pierre Pichet added a comment - I just understand the 2,0 is not a branch. So merging with 2,0 will have to wait... So setting it as resolved (and tested OK on HEAd and on my local 2,0 )

              People

              • Assignee:
                ppichet Pierre Pichet
                Reporter:
                ppichet Pierre Pichet
                Tester:
                Nobody
                Participants:
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  25/Dec/10