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

Social forum needs to be created using event observers

    XMLWordPrintable

Details

    • MOODLE_403_STABLE
    • MOODLE_404_STABLE
    • MDL-78940-main
    • Hide

      Test: Social forum is creating when adding a new course.

      You'll need to check the database records on the forum table for this test.

      1. Using your preferred database client, view the records of forum table (mdl_forum).
      2. Log in as admin, go to "Site home" and click "Add a new course".
      3. Fill the form, select "Social format" under "Course format"  section and click "Save and return" button.
      4. Query the forum table and verify that there's a new record for "Social Forum" for the course created.
      5. Access the course you have created.
      6. Verify that there's no new record on the forum table.
      7. Create another course using the same social format but this time click "Save and display" button.
      8. Query the forum table and verify that there's a new record for "Social Forum" for the course created.
      Show
      Test: Social forum is creating when adding a new course. You'll need to check the database records on the forum table for this test. Using your preferred database client, view the records of forum table (mdl_forum). Log in as admin, go to "Site home" and click "Add a new course". Fill the form, select "Social format" under "Course format"   section and click "Save and return" button. Query the forum table and verify that there's a new record for "Social Forum" for the course created. Access the course you have created. Verify that there's no new record on the forum table. Create another course using the same social format but this time click "Save and display" button. Query the forum table and verify that there's a new record for "Social Forum" for the course created.

    Description

      Moodle's social course format features a "Social forum" that directly links to a forum activity, bypassing access to the course homepage. However, an issue arises when attempting to utilize this "Social forum" within data generators.

      Specifically, the problem can be outlined as follows:

      And the following "courses" exist:
            | fullname | shortname | category | format |
            | Course 1 | C1 | 0 | social |
      And the following "mod_forum > discussions" exist:
            | user      | forum        | name         | 
            | teacher1 | Social forum | Forum Post 1 |
      

      The problem happens because the forum is not created when the course is created. Moodle creates the activity only when the user access it for the first time.

      Attachments

        Issue Links

          Activity

            People

              lameze Simey Lameze
              lameze Simey Lameze
              Angelia Dela Cruz Angelia Dela Cruz
              Huong Nguyen Huong Nguyen
              Kim Jared Lucas Kim Jared Lucas
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

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

                  Clockify

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