Moodle
  1. Moodle
  2. MDL-23488

Database activity set available from and to dates option doesn't work.

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.9.9, 2.0
    • Fix Version/s: 1.9.11
    • Labels:
      None
    • Environment:
      LAMP (Ubuntu 8.10)
    • Database:
      MySQL
    • Affected Branches:
      MOODLE_19_STABLE, MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE
    • Rank:
      1342

      Description

      Database activity set available from and to dates option doesn't work.

      1. mod_data_view_php.patch
        3 kB
        Nadav Kavalerchik
      2. mod_data_view_php.patch
        1 kB
        Nadav Kavalerchik
      1. database_available.png
        231 kB
      2. student-view-when-closed.jpg
        32 kB

        Issue Links

          Activity

          Hide
          Andrew Davis added a comment -

          Fix committed

          Show
          Andrew Davis added a comment - Fix committed
          Hide
          Teresa Gibbison added a comment -

          Can we have a more user-friendly error message when a closed Database is viewed by a student. See screenshot for 'fatal-looking' error that will most likely cause confusion and panic! Also the 'Continue' button returns to the site homepage rather than the course homepage.

          Show
          Teresa Gibbison added a comment - Can we have a more user-friendly error message when a closed Database is viewed by a student. See screenshot for 'fatal-looking' error that will most likely cause confusion and panic! Also the 'Continue' button returns to the site homepage rather than the course homepage.
          Hide
          Teresa Gibbison added a comment -

          reopening for more use friendly error message and handling.

          Show
          Teresa Gibbison added a comment - reopening for more use friendly error message and handling.
          Hide
          Andrew Davis added a comment - - edited

          Those messages are a little frightening looking. I've replaced them with less aggressive notifications. Do you think the continue button is necessary or is the navigation bar and block on the left adequate?

          Show
          Andrew Davis added a comment - - edited Those messages are a little frightening looking. I've replaced them with less aggressive notifications. Do you think the continue button is necessary or is the navigation bar and block on the left adequate?
          Hide
          Anthony Borrow added a comment -

          Any reason we cannot back port the fix for MDL-23488 to 1.9? I'm linking these as I believe the commit for MDL-23488 follows the logic that is needed to fix this issue. Peace - Anthony

          Show
          Anthony Borrow added a comment - Any reason we cannot back port the fix for MDL-23488 to 1.9? I'm linking these as I believe the commit for MDL-23488 follows the logic that is needed to fix this issue. Peace - Anthony
          Hide
          Anthony Borrow added a comment -

          Re-opening issue so we can backport to 1.9. Peace - Anthony

          Show
          Anthony Borrow added a comment - Re-opening issue so we can backport to 1.9. Peace - Anthony
          Hide
          Anthony Borrow added a comment -

          Adding 1.9 as affected branch. Peace - Anthony

          Show
          Anthony Borrow added a comment - Adding 1.9 as affected branch. Peace - Anthony
          Hide
          Anthony Borrow added a comment -

          Just making a note to myself to check how availability is handled when conditional activities is enabled. Do we then have duplicate methods of doing the same thing in 2.0? Peace - Anthony

          Show
          Anthony Borrow added a comment - Just making a note to myself to check how availability is handled when conditional activities is enabled. Do we then have duplicate methods of doing the same thing in 2.0? Peace - Anthony
          Hide
          Anthony Borrow added a comment -

          Andrew - I've attached a screen shot showing the duplication in 2.0 on the form for when the database is available. I think we may want to revert your patch. Eventually we could clean up those fields and remove them from the mdl_data table (namely the timeavailablefrom and timeavailableto fields and just use the conditional activity. This might require a little finessing of the upgrade code. Regardless, I think the conditional activity code should take precedence. I just want to make sure we do not have competing code conditions where one is set to show it as available and the other not. Peace - Anthony

          Show
          Anthony Borrow added a comment - Andrew - I've attached a screen shot showing the duplication in 2.0 on the form for when the database is available. I think we may want to revert your patch. Eventually we could clean up those fields and remove them from the mdl_data table (namely the timeavailablefrom and timeavailableto fields and just use the conditional activity. This might require a little finessing of the upgrade code. Regardless, I think the conditional activity code should take precedence. I just want to make sure we do not have competing code conditions where one is set to show it as available and the other not. Peace - Anthony
          Hide
          Andrew Davis added a comment - - edited

          Hi Anthony. Note that I didnt add the UI elements. I just made them work so reverting my patches won't remove the set of available from/to UI elements. I've raised this in dev chat to see what we should do. I suspect you are correct in saying we should remove the availability settings from the data table.

          update: I've raised MDL-24180 to deal with the duplicate available from/to elements in all the activities.

          Show
          Andrew Davis added a comment - - edited Hi Anthony. Note that I didnt add the UI elements. I just made them work so reverting my patches won't remove the set of available from/to UI elements. I've raised this in dev chat to see what we should do. I suspect you are correct in saying we should remove the availability settings from the data table. update: I've raised MDL-24180 to deal with the duplicate available from/to elements in all the activities.
          Hide
          Andrew Davis added a comment -

          I've backported the fix to 1.9 We'll figure out how to handle the duplication of available from/to in the other issue. Thankyou for your feedback and help

          Show
          Andrew Davis added a comment - I've backported the fix to 1.9 We'll figure out how to handle the duplication of available from/to in the other issue. Thankyou for your feedback and help
          Hide
          Nadav Kavalerchik added a comment -

          Another suggestion for a patch, to this issue.

          Which does not show the Teacher's instruction if the activity is not open,yet.
          and that shows a Notice and not an Error message.

          Show
          Nadav Kavalerchik added a comment - Another suggestion for a patch, to this issue. Which does not show the Teacher's instruction if the activity is not open,yet. and that shows a Notice and not an Error message.
          Hide
          Nadav Kavalerchik added a comment -

          updated patch, including dateviewfrom / dateviewto considerations

          Show
          Nadav Kavalerchik added a comment - updated patch, including dateviewfrom / dateviewto considerations
          Hide
          Dennis Meyer added a comment -

          still open for 1.9.12

          Show
          Dennis Meyer added a comment - still open for 1.9.12
          Hide
          Anthony Borrow added a comment -

          Dennis - Thanks for the feedback. Could you indicate what precisely is failing so that we can determine whether this issues needs to be re-opened for 1.9? Then I can work at replicating the issue and verifying that it is still a problem. I was going to recommend trying the steps listed in MDLQA-171 as a way of testing this. The more details you can provide the better. Peace - Anthony

          Show
          Anthony Borrow added a comment - Dennis - Thanks for the feedback. Could you indicate what precisely is failing so that we can determine whether this issues needs to be re-opened for 1.9? Then I can work at replicating the issue and verifying that it is still a problem. I was going to recommend trying the steps listed in MDLQA-171 as a way of testing this. The more details you can provide the better. Peace - Anthony
          Hide
          Dennis Meyer added a comment -

          i'm so sorry!!! it was my fault - everything works fine... i just missunderstood something... thanx for your reply. cheers schorsch

          Show
          Dennis Meyer added a comment - i'm so sorry!!! it was my fault - everything works fine... i just missunderstood something... thanx for your reply. cheers schorsch
          Hide
          Nadav Kavalerchik added a comment -

          I confirm it too. (still exists in Moodle 1.9.12)

          Even with my patch, students can find a way to navigate into a deeper page inside the activity
          Although they are blocked at the entrance to the activity.

          My patch and the entire issue needs to get a better code review from someone that has a better
          understanding of the Database activity.

          Show
          Nadav Kavalerchik added a comment - I confirm it too. (still exists in Moodle 1.9.12) Even with my patch, students can find a way to navigate into a deeper page inside the activity Although they are blocked at the entrance to the activity. My patch and the entire issue needs to get a better code review from someone that has a better understanding of the Database activity.
          Hide
          Andrew Davis added a comment -

          Hi. Just a note on our process. Once an issue is closed open a new one if you do encounter any problems with the fix. Re-opening issues makes things.... complicated

          Show
          Andrew Davis added a comment - Hi. Just a note on our process. Once an issue is closed open a new one if you do encounter any problems with the fix. Re-opening issues makes things.... complicated
          Hide
          Anthony Borrow added a comment -

          @Dennis - No worries at all - it is good to hear that you have things working as that is the most important thing.
          @Andrew - Thanks for the clarification on opening a new issue.
          @Nadav - It sounds like we are getting some conflicting reports. Would you mind creating a new issue and attach your patch there so that we can look at what still may be happening in 1.9? Please provide steps to reproduce the problem and let me know the issue number and I'll make sure to watch it and take a look at it. I have some familiarity with the database activity module.
          Peace - Anthony

          Show
          Anthony Borrow added a comment - @Dennis - No worries at all - it is good to hear that you have things working as that is the most important thing. @Andrew - Thanks for the clarification on opening a new issue. @Nadav - It sounds like we are getting some conflicting reports. Would you mind creating a new issue and attach your patch there so that we can look at what still may be happening in 1.9? Please provide steps to reproduce the problem and let me know the issue number and I'll make sure to watch it and take a look at it. I have some familiarity with the database activity module. Peace - Anthony

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: