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

New course format setting to enable/disable course indentation in Weeks and Topics

XMLWordPrintable

    • MOODLE_402_STABLE
    • MOODLE_402_STABLE
    • MDL-76991-master
    • Hide

      Main feature covered by behats.

      Test for both Topics and Weeks format courses.

      UI changes - Manual testing

      1. As admin create a new site.
      2. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing. 
      3. Confirm the 'Use indentation' setting value is Yes by default.
      4. Create a course using the format you are testing with at least 2 activities.
      5. Open action menu for first activity and Move Right.
      6. Confirm the first activity has a bigger margin on the left and has no border anymore.
      7. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing 
      8. Disable 'Use indentation' setting and Save changes.
      9. Go to the course.
      10. Confirm the first activity has a border and the same left margin as the rest of the activities.

      Upgrading from 3.11 - Manual testing

      1. Create a new 3.11 instance.
      2. Upgrade to this patch.
      3. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing 
      4. Confirm the 'Use indentation' setting value is Yes.

      Upgrading from 4.0 - Manual testing

      1. Create a new 4.0 instance.
      2. Upgrade to this patch.
      3. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing 
      4. Confirm the 'Use indentation' setting value is No.

      Web services for mobile

      1. As an admin create a course using the format you are testing (remember the COURSE_ID)
      2. Enable "Enable web services for mobile devices": Site administration ► General ► Advanced features
      3. Create a Token for any user on the site
        Click on Site administration ► Web services ► Manage tokens
      4. Next, you can do a CURL REST call simulating a WS client with the user token.
      5. You need to replace the $wstoken and the MOODLE_URL of your moodle instance

        curl 'MOODLE_URL/webservice/rest/server.php?moodlewsrestformat=json' --data 'wsfunction=core_course_get_courses_by_field&field=id&value=COURSE_ID&wstoken=$wstoken' | python -m json.tool

      1. Confirm that you see an entry for the "indentation" setting with the correct value (1 if enabled, 0/empty otherwise)
      Show
      Main feature covered by behats. Test for both Topics and Weeks format courses. UI changes - Manual testing As admin create a new site. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing.  Confirm the 'Use indentation' setting value is Yes by default. Create a course using the format you are testing with at least 2 activities. Open action menu for first activity and Move Right. Confirm the first activity has a bigger margin on the left and has no border anymore. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing  Disable 'Use indentation' setting and Save changes. Go to the course. Confirm the first activity has a border and the same left margin as the rest of the activities. Upgrading from 3.11 - Manual testing Create a new 3.11 instance. Upgrade to this patch. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing  Confirm the 'Use indentation' setting value is Yes. Upgrading from 4.0 - Manual testing Create a new 4.0 instance. Upgrade to this patch. Go to Site administration > Plugins > Course format > Topics format or Weeks format depending on the format you are testing  Confirm the 'Use indentation' setting value is No. Web services for mobile As an admin create a course using the format you are testing (remember the COURSE_ID) Enable "Enable web services for mobile devices": Site administration ► General ► Advanced features Create a Token for any user on the site Click on Site administration ► Web services ► Manage tokens Next, you can do a CURL REST call simulating a WS client with the user token. You need to replace the $wstoken and the MOODLE_URL of your moodle instance curl 'MOODLE_URL/webservice/rest/server.php?moodlewsrestformat=json' --data 'wsfunction=core_course_get_courses_by_field&field=id&value=COURSE_ID&wstoken=$wstoken' | python -m json.tool Confirm that you see an entry for the " indentation " setting with the correct value (1 if enabled, 0/empty otherwise)
    • 1
    • HQ 2023 Sprint i1.1 Moppies

      As an admin
      I want to decide whether the teacher could use course indentation or not
      so we don't need to redesign current existing courses

      • A new setting will be available at site level for admins.
        • Whenever the setting is enabled, the teacher will have Move right/Move left options to indent elements on their courses, and the value 'indent' of the 'course_modules' table would have an impact on the look&feel of the course.
        • Whenever the setting is disabled, the teacher won't have Move right/Move left options to indent elements on their courses, and the value 'indent' of the 'course_modules' table won't have any impact on the look&feel of the course.
      • The default value of the setting will be:
        • True/Enable for new sites.
        • True/Enable for sites migrating from 3.11 or earlier versions.
        • False/Disable for sites migrating from 4.0 and 4.1 versions.

      Note: A backporting request would be raised once this issue is integrated,  so we should try to implement the patch following the rules to be backportable. More information about backporting request: https://moodledev.io/general/development/policies/backporting

       

        1. image-2023-03-08-12-42-55-740.png
          image-2023-03-08-12-42-55-740.png
          47 kB
        2. image-2023-03-08-12-43-54-905.png
          image-2023-03-08-12-43-54-905.png
          47 kB
        3. image-2023-03-08-12-44-22-319.png
          image-2023-03-08-12-44-22-319.png
          48 kB
        4. plugin setting.gif
          plugin setting.gif
          1.06 MB
        5. topics course.gif
          topics course.gif
          1.18 MB
        6. upgrading from 311.gif
          upgrading from 311.gif
          1.32 MB
        7. upgrading from 400.gif
          upgrading from 400.gif
          763 kB
        8. webservice.png
          webservice.png
          188 kB
        9. weekly course.gif
          weekly course.gif
          1.33 MB

            amaia Amaia Anabitarte
            amaia Amaia Anabitarte
            Carlos Escobedo Carlos Escobedo
            Jun Pataleta Jun Pataleta
            Ron Carl Alfon Yu Ron Carl Alfon Yu
            Votes:
            1 Vote for this issue
            Watchers:
            14 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 day, 2 hours, 57 minutes
                1d 2h 57m

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