Feature Requests

Please do NOT use this section of the forum to request help if Joomdle does not work for you in some particular way. Your post will be deleted.

My Courses / Group by Category - Order does not match Moodle

  • Kyle Benedetti
  • Topic Author
  • Offline
  • New Member
  • New Member
More
12 years 9 months ago #1 by Kyle Benedetti
I recently started using the "Group by Category" option for my My Courses page found under "Basic Options" when I create the menu link.

It displays the course categories and lists the categories by group which is awesome and exactly what I want. However I cannot for the life of me figure out how it is organizing the categories.

They do not match the order from moodle, they are not alphabetical, they are not ordered by course start date and they are not ordered by when the course was created.

Is there a way to have it match the order in Moodle?

I have attached three images:

1) The Moodle view of the categories, you can see Spring is above Fall.
2) The Moodle My Courses page where The Writings (Spring) is above The Pentateuch (Fall)
3) The Joomdle My Courses page with Category Grouping where Fall is some how above Spring.

Thanks in advance,

Kyle
Attachments:

Please Log in or Create an account to join the conversation.

  • Kyle Benedetti
  • Topic Author
  • Offline
  • New Member
  • New Member
More
12 years 9 months ago #2 by Kyle Benedetti
Ok after more trial and error I have figured out that the order is based on the order that the Categories are created. However they put the newest created categories at the bottom.

So if it is possible to have it mirror the way Moodle organizes them would be best, if not simply reversing the order of how they currently display and having the oldest Categories at the bottom would also work. Does anyone know how I could do that?

Thanks for all the work you guys do, Joomdle is great!

Kyle

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago #3 by Antonio Durán
Hi, thanks for the info and suggestions. I will move this topic to Feature Requests, for a possible inclusion in a future release. I guess best option is to have it configurable.

As for changing it now yourself: you would need to change the web service function in Moodle, to return the items in different order.

Please Log in or Create an account to join the conversation.

  • Kyle Benedetti
  • Topic Author
  • Offline
  • New Member
  • New Member
More
12 years 9 months ago #4 by Kyle Benedetti
Thanks for pointing me in the right direction. If I figure anything out I will post it in case anyone else would like this feature.

Thanks!

Kyle

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago #5 by Antonio Durán
Hi.

Don't know if you already solved it, bu just in case: having it sorted by category sortorder is more complicated, as it would need a rewrite of how the courses are retrieved (current used Moodle API call does not permit it).

Having them sorted by id, but reversed, is easy: edit moodle/auth/joomdle/auth.php, function my_courses().
Change:
Code:
$c = enrol_get_users_courses ($user->id, true, NULL, 'category, sortorder ASC');
By:
Code:
$c = enrol_get_users_courses ($user->id, true, NULL, 'category DESC, sortorder ASC');

Please Log in or Create an account to join the conversation.

  • Kyle Benedetti
  • Topic Author
  • Offline
  • New Member
  • New Member
More
12 years 9 months ago #6 by Kyle Benedetti
Thanks a million for posting this! I got distracted and hadn't looked into it yet.

Joomdle is amazing!

Kyle

Please Log in or Create an account to join the conversation.

More
11 years 2 months ago #7 by Graham Paull
This was a great tip, I managed to get my Categories in order.

Could I ask, is it possible to have the Courses within the categories ordered by shortname ?

Currently in my Moodle installation, I have My Home set with the Course Overview block in use, I have modified this to sort courses by Shortname ascending, could this be done in Joomdle ?

Thanks, Graham

Please Log in or Create an account to join the conversation.

More
11 years 2 months ago #8 by Antonio Durán
I guess you can just change the same code, to use shortname instead of sortorder.

Please Log in or Create an account to join the conversation.

More
4 years 9 months ago #9 by Justin
Has this been added as a feature yet, or would I need to change the coding as suggested by you

Please Log in or Create an account to join the conversation.

More
4 years 9 months ago #10 by Antonio Durán
I am sorry, but we didn't add anything related to this... I think I totally forgot about it :(
We'll try to take a look for next release.

Please Log in or Create an account to join the conversation.