Please test Collapsed Topics for Moodle 2.3

Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Number of replies: 38
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi,

I have a 'beta' version of Collapsed Topics for Moodle 2.3 (build of 12th June 2012) available from https://github.com/gjb2048/moodle-format_topcoll/tree/MOODLE_23 - there is a 'zip' option to get the bundle.  I would appreciate that if you have a 2.3 test site that you give it a go and let me know of any issues.  Incorporated is a new 'days' structure and a fix for open / close all when there are hidden sections (which needs to be applied to previous versions too).

Thanks,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

Thank you for the beta version of Collapsed Topics for Moodle 2.3. I installed your course format, set the course layout to "Show one section per page" and and selected "Collapsed Topics format" with current topic at the top, no cookies, and no toggle word, toggle section x and section number.

These are the first three sections of the main page.

Main course page

This is the view of section 1. (see below)

Section one only

This is the main course page in editing off mode. (see below)

Main course page in editing off mode

This is section one in editing off mode. (see below)

section one only in editing off mode

"Show one section per page" may not be compatible with Collapsed Topics format as all activities and resources disappear as well as "Add an activity or resource" when only one section is selected.

Another observation: Is it possible to change once mind regarding the cookies? When asked the first time, I choose "Deny cookies." Later I didn't see where I could allow cookies. I used "reset" and later "default" in the settings at the top right, but the cookie option no longer appeared.

I don't want to discourage you at all as I really appreciate your effort to make "Collapsed Topics Format" available in Moodle 2.3.

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

Thank you so much for testing, I have updated some files and fixed the single section page.  There is a new version to download, simply replace the files.  There are no database changes.

With the Cookie thing, I do understand and currently the only way to get the dialog back for a given user is though a database edit.  However I hope to be able to elminate cookies soon for the functionality they serve and hence solve the issue in a lateral way.

There are still some issues with things not showing that I want to try and iron out.

Constructive comments lead to encouragement, disruptive commends lead to discouragement સ્મીત

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

You are fast. I installed your revised version of Collapsed Topics. When edit mode is on, I see open/close/toggle all and the content of the sections in the main course page.

Collapsed topics -open, close, toggle all visible

In edit mode off, the open/close/toggle are no longer visible and all sections are closed on the main course page. (see below)

Collapsed topics -open, close, toggle all not visible

The markers/borders for the current topic are only visible in edit mode. I assume that your course format inherited this feature from the topics format, which doesn't indicate the current topic either. I posted this observation in the "Testing and QA" forum.

I like to see how you prepare Collapsed Topics for the upcoming release of Moodle 2.3.

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

Thank you સ્મીત.  Currently as it stands with the 'one section per page' functionality I intend to leave as is as out of editing mode there is only the section name that links to the page making the toggles obsolite.  However, in editing mode the content of the sections are there so I decided to put in the toggles.  With the 'multiple sections per page' functionality everything is as before.

I hope to finalise when 2.3 is stable as you say about the markers / borders as I do inherit default functionality from '/course/format/renderer.php'.

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

Thank you for your reply and explanation regarding the main course page and how it is used. I slowly grasp the difference between "Show one section per page" and "Show all sections on one page" and how this affects the main course page.

Here are two more observations regarding "Add an activity or resource." When I am on the main course page with Collapsed Topics and "Show one section per page" selected, the top "Add an activity or resource" link is not responding (in general section).

When I click on a topic and only one section on a page is visible, both "Add an activity or resource" links at the right do not respond.

http://. . ./moodle/course/view.php?id=2&section=2&editingenabled=1# (link is responding)

http://. . ./moodle/course/view.php?id=2# (linkis not responding)

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

Thanks સ્મીત - should be now fixed - I'd left off an '.' in 'renderer.php' on one line.  Now cookie reloading of toggles not working, something has changed, need to think about how to fix it.

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Jared Chapman - દ્વારા

Gareth,

I love this module! Thank you for making it.

I get a javascript error when reloading the page: reloadToggels() in cookie function - [Object, object]

Though it seems to be working fine

In reply to Jared Chapman

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Jared,

No worries.  The Javascript is actually a left over 'alert()' test statement as the code is in 'beta' testing still - will not be in release version.

There are still a few things to do.

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Jared Chapman - દ્વારા

Could you tell me which file the alert is in so I could comment it out? It slows me down each time I need to refresh the page to see how stuff is looking,

Thanks!

In reply to Jared Chapman

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers
In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Jared Chapman - દ્વારા

Sorry, I've commented out this line

 

  // alert('reloadToggles() in cookie function - ' + daYUI);

 

and emptied my cache, but it still alerts. Any suggestions? Maybe a moodle "refresh" I need to do?

In reply to Jared Chapman

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Use the Moodle 'purge' option under Adminstration -> Developer area I think.

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

I continued testing Collapsed Topics format with Moodle 2.3 (beta) on a test site. When I set the course layout to "Show one section per page" and and selected "Collapsed Topics format" with current topic at the top, I can see the text of the section summary on the main course page.

When I click on any topic so that only one topic is visible, I no longer see the section summary, only the section name (e.g., topic 1). I checked this behavior also with Standard theme selected. Did you observe something similar or is this just on my installation?

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

Thanks for spotting that, it was indeed a bug with my code that I have now just rectified.

I have also removed the cookie functionality in favour of Tim Hunt's AJAX user preference code.  This means that the state of the toggles is now in the 'user_preferences' table in the database for a per user per course basis.  Even though it is stated in the Moodle Tracker for Tim's code (http://tracker.moodle.org/browse/MDL-17084) that the values are sessional, they appear to be persistent.  Therefore I have added code to remove my values upon course deletion.  They are removed by core code when a user is deleted.  I would assume they are backed up when users are.  But not sure what would happen in the scenario where a user is restored with preferences for a course that no longer exists.

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

Thank you for your fast reply. Now it looks good.

with kind regards,

Hartmut

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Collapsed Topics for Moodle 2.3 is now at 'release candidate' stage - please install the same as the beta as stated above સ્મીત

If you had it installed before you may have to drop the 'topcoll_cookie_cnsnt' table from your database manually as for some reason the database manager call in my upgrade.php is not working and I don't know why.

Feedback appreciated, cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Kyle Smith - દ્વારા

Hi There,

I upgraded my moodle to 2.3 today and installed to the latest RC of coll topics.

First i got an error saying the db already existed - so i removed the table from the db.  Then it installed, however, it only created the format_topcoll_settings table.  Now when i go to access a topic which util CollTopics i get the following message: 'Coding error detected, it must be fixed by a programmer: Unknown method called against plugin_renderer_base :: cookie_consent'

Can you post the sql queiry so that i can add the required tables? - i presume this is the issue?

In reply to Kyle Smith

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Kyle,

I got the same error message regarding the cookie consent. When I commented out line 336 in renderer.php in course -> format -> topcoll, I no longer received the error message.

Before:

335        // Collapsed Topics settings and cookie consent.
336        echo $this->cookie_consent($course);
337        echo $this->settings($course);

After:

335        // Collapsed Topics settings and cookie consent.
336        // echo $this->cookie_consent($course);
337        echo $this->settings($course);

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Kyle and Hartmut,

Thank you so much સ્મીત - I missed that one!  There is something to be said for Kent Beck's Extreme Programming that requires somebody looking over your shoulder to check on what you are doing.

I've hopefully fixed things and have updated the code on GitHub.  To clean things up a bit, please follow uninstallation step 4 in the readme before updating with 'Notifications'.  Plus you will need the stable version of 2.3 that came out on the 25th June.

Thanks,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Kyle Smith - દ્વારા

working much better now, thankyou સ્મીત

Is it possible to reset all my courses to the styling in config.php? - tis a pain to do this manually for each and every course!

Also wondering if it is possible to have the description show under the dropdown like it used too rather then pre-expanded? 

Thanks for all your help.

In reply to Kyle Smith

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Kyle,

No worries સ્મીત

It is possible to have the section summary show under the section name within the toggle.  As this is a complete rewrite I sort of started from scratch!

I'll look into an option for reset all courses to the default in config.php but will make this option available to admins only as could be dangerous for a teacher to reset for a course they technically might not have control over.

Cheers,

Gareth

In reply to Kyle Smith

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Kyle,

I've implemented the reset all for both layouts and colours - please see the readme.  Please update your code.  I have incremented the version even though there are no changes to the db.  I'm working on the summary as the code changes are in 'renderer.php' which also has a few experimental mods at the moment for multi-column support.

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi,

I have done an update that fixes the summary as Kyle above requested and additionally added in multi-column support as indicated by the attached image.  This has been in my mind for ages and it appears to be easy to do with unordered lists, so a back port to the table based method in 2.2 and below might not be possible.

To install you will need to follow step 4 of the uninstallation instructions if you have previously installed a test version for 2.3 before.

Please be aware that this code is not for production sites as still testing.  It requires the Moodle 2.3 released on the 25th June.

Cheers,

Gareth

Attachment ct_2c.png
In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

What a great idea to implement columns into this course format. Just excellent!

When I tested the latest code, setting columns doesn't stick on my Moodle 2.3 installation. So I changed the default to 2 columns in tcconfig.php and selected two or more columns in the settings block at the top right. Then, the main course layout shows two columns, but displays all topics in the left column. The right column is empty. When I go back to settings, the drop down menu for columns shows "one column."

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

Thanks સ્મીત

Have you...

To keep things clean for what will be a fresh install for all I have decided to remove the update code in update.php, so if you have previously installed a beta version please kindly follow step 4 of the 'Uninstallation Instructions' above after updating your code but before clicking on 'Notifications' to 'upgrade'.

as in the readme.txt??

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

Success! After completely uninstalling and reinstalling Collapsed Topics format, it looks great. Sorry for my previous post. I should have carefully read and followed the uninstallation instruction. Thanks for a great course format. Now I will test it in MyMobile theme.

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

No worries, I've actually done a belt and braces on the Readme as somebody else had the same issue.

I should point out that the MyMobile theme will definitely not work!  Please see http://tracker.moodle.org/browse/MDL-33115 - I've worked out the 2.2 changes but because of the AJAX changes causing a re-write for 2.3 I've yet to work out with John the changes.  If you can figure them - please tell me :D

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Hartmut Scherer - દ્વારા

Hi Gareth,

I highly appreciate your effort and time that you invested in Collapsed Topics format. Regarding the use of the MyMobile theme with your course format, I will wait for your update.

With kind regards,

Hartmut

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

Thank you સ્મીત

I think I have all the changes I need to make at my end for the MyMobile theme so intend to release CT soon anyway with a small caveat about MyMobile.  I'm hoping that John will be able to assist me soon.

Cheers,

Gareth

In reply to Hartmut Scherer

Re: Please test Collapsed Topics for Moodle 2.3

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Hartmut,

I have done an update to work with the MyMobile theme.  It's not quite the same as the previous versions as it uses my icons - but it does work - I've done all the changes at my end - just going to see what happens at the core end.

Also as you would expect, no multi-columns in MyMobile - but the number of columns can be set and used - it's just if the theme is MyMobile it ignores the setting.

Also done a few performace tweeks and language specific stuff.

Cheers,

Gareth

In reply to Gareth J Barnard

Collapsed Topics for Moodle 2.3 - CVS

Larry Elchuck - દ્વારા

Thanks for your work on this feature, Gareth.  Will you be making a CVS version available as well?

In reply to Larry Elchuck

Re: Collapsed Topics for Moodle 2.3 - CVS

Gareth J Barnard - દ્વારા
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Dear Larry,

Thanks and no as CVS died ages ago.  However I will be putting it as a download on the plugins database -> http://moodle.org/plugins/view.php?plugin=format_topcoll as soon as I'm happy with it સ્મીત.

Cheers,

Gareth

In reply to Gareth J Barnard

Re: Collapsed Topics for Moodle 2.3 - CVS

Larry Elchuck - દ્વારા

Thanks for the response Gareth

I am still performing weekly updates to my sites using CVS and plan to do so for the forseeable future (as long as the Moodle core is producing such updates).  Guess I'll need to keep a eye on developments of this add-on separately and do manual updates


cheers

L

In reply to Gareth J Barnard

Re: Please test Collapsed Topics for Moodle 2.3

Larry Elchuck - દ્વારા

Hi Gareth

 

I just replaced a previous 2.3 version of topcoll with gjb2048-moodle-format_topcoll-V2.3.7-0-gf472746 and I have the images imposed over the text.  Is it just me?

 

larry

Attachment Voila_Capture1103.png