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

Workshop submission deadlines do not appear on calendar

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0, 2.1.5, 2.2.2
    • Fix Version/s: 2.1.6, 2.2.3
    • Component/s: Workshop
    • Labels:
    • Database:
      Any
    • Testing Instructions:
      Hide

      Testing difficulty: EASY

      1. Create a new workshop instance with the access control deadlines set (open for submission, submission deadline, open for assessment and assessment deadline)
      2. TEST: Make sure that the calendar events were created in course calendar for all the deadlines
      3. Update the workshop setting. Disable some deadline and change the date/time of an other
      4. TEST: Make sure that the events in the calendar were updated respectively

      Note: there is no dates validation in the form yet (so the used can define dates in wrong logical order, phases may overlap etc). This will be addressed in a separate issue.

      Show
      Testing difficulty: EASY 1. Create a new workshop instance with the access control deadlines set (open for submission, submission deadline, open for assessment and assessment deadline) 2. TEST: Make sure that the calendar events were created in course calendar for all the deadlines 3. Update the workshop setting. Disable some deadline and change the date/time of an other 4. TEST: Make sure that the events in the calendar were updated respectively Note: there is no dates validation in the form yet (so the used can define dates in wrong logical order, phases may overlap etc). This will be addressed in a separate issue.
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE, MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-25660-workshop-calendar

      Description

      The submissions deadlines for workshop does not appear on the calendar (nor do the other deadlines such as assessment). This is a significant issue for students who use the calendar to plan when to submit their work.

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            mudrd8mz David Mudrak added a comment - - edited

            Submitting for integration. The patchset introduces three commits. The first one adds support for registering calendar events on workshop instance add/update. The second one fixes all workshop calendar events currently registered in the database, including the old 1.x ones that are likely to be outdated or even corrupted. The third commits adds support for removing calendar events on the workshop instance deletion.

            Show
            mudrd8mz David Mudrak added a comment - - edited Submitting for integration. The patchset introduces three commits. The first one adds support for registering calendar events on workshop instance add/update. The second one fixes all workshop calendar events currently registered in the database, including the old 1.x ones that are likely to be outdated or even corrupted. The third commits adds support for removing calendar events on the workshop instance deletion.
            Hide
            poltawski Dan Poltawski added a comment -

            Hi David,

            The upgrade steps do not look safe here. If you use library functions in upgrade steps then you will run the risk of upgrade dependencies causing the upgrade to break. For example if someone changes calendar_event::load to use a field which has not yet been introduced or indeed workshop_calendar_update() gets changed in the future.

            The upgrade steps should use specific upgrade functions defined in db/upgradelib.php which do not have dependencies on the library functions and are set in time.

            So i'm reopening this i'm afraid.

            Show
            poltawski Dan Poltawski added a comment - Hi David, The upgrade steps do not look safe here. If you use library functions in upgrade steps then you will run the risk of upgrade dependencies causing the upgrade to break. For example if someone changes calendar_event::load to use a field which has not yet been introduced or indeed workshop_calendar_update() gets changed in the future. The upgrade steps should use specific upgrade functions defined in db/upgradelib.php which do not have dependencies on the library functions and are set in time. So i'm reopening this i'm afraid.
            Hide
            mudrd8mz David Mudrak added a comment -

            Hi Dan.

            Thanks for the review and the comment. However, I disagree in this case. As explained in the commit message, all workshop calendar events must be deleted and recreated again during the upgrade. And there is no other way to do it but via the standard calendar API. Surely those who refactor that API would also check for all usage of it to make sure the change does not break anything. So I really can't see how I could perform this step without the dependency on the calendar API. It's like we did not allow $DB because it adds dependency on the database API. Or am I missing something?

            Show
            mudrd8mz David Mudrak added a comment - Hi Dan. Thanks for the review and the comment. However, I disagree in this case. As explained in the commit message, all workshop calendar events must be deleted and recreated again during the upgrade. And there is no other way to do it but via the standard calendar API. Surely those who refactor that API would also check for all usage of it to make sure the change does not break anything. So I really can't see how I could perform this step without the dependency on the calendar API. It's like we did not allow $DB because it adds dependency on the database API. Or am I missing something?
            Hide
            poltawski Dan Poltawski added a comment -

            Putting this back into integration, as we have discussed at length that in fact this approach is OK to depend on 'higher level apis' and its davids call on the workshop api

            http://moodle.org/local/chatlogs/index.php?conversationid=9995

            Show
            poltawski Dan Poltawski added a comment - Putting this back into integration, as we have discussed at length that in fact this approach is OK to depend on 'higher level apis' and its davids call on the workshop api http://moodle.org/local/chatlogs/index.php?conversationid=9995
            Hide
            poltawski Dan Poltawski added a comment -

            Thanks David, i've integrated this now

            Show
            poltawski Dan Poltawski added a comment - Thanks David, i've integrated this now
            Hide
            phalacee Jason Fowler added a comment -

            Works fine in all versions

            Show
            phalacee Jason Fowler added a comment - Works fine in all versions
            Hide
            poltawski Dan Poltawski added a comment -

            Bonza mate!

            Your changes have made it into the Moodle release! Its time to celebrate! Put a shrimp on the barbie and grab a stubby.

            Hooroo

            Show
            poltawski Dan Poltawski added a comment - Bonza mate! Your changes have made it into the Moodle release! Its time to celebrate! Put a shrimp on the barbie and grab a stubby. Hooroo
            Hide
            vrrandall Vernellia Randall added a comment -

            Thanks David.

            Show
            vrrandall Vernellia Randall added a comment - Thanks David.
            Hide
            tsala Helen Foster added a comment -

            Thanks David for this improvement which is now mentioned in the docs: http://docs.moodle.org/23/en/Workshop_settings#Access_control

            Show
            tsala Helen Foster added a comment - Thanks David for this improvement which is now mentioned in the docs: http://docs.moodle.org/23/en/Workshop_settings#Access_control

              People

              • Votes:
                6 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  14/May/12