Notice

The forum is in read only mode.

Support Forum

Welcome! Support Forums have been reactivated
Welcome the Technical Support section. Help us in assisting you by providing us with a concise and descriptive elaboration of your issues. Be specific and if possible, provide us with a step-by-step instruction in replicating your problem.

Reordering Groups

9 years 7 months ago
  • Eric's Avatar
    Topic Author
  • Eric
  • Offline
  • Fresh Boarder
  • Posts: 21
  • Thank you received: 1
Licenses:
JomSocial Expired

I am building a site which only has 9 total groups split into three categories. I have disabled group creation so the we maintain that pure set of only 9 groups for which users can start discussions. We have modified the category menu to reveal all the cats and the subgroups within it but the ordering seems to be based on creation order. Is there any built in method to sort or is best to
1) delete and start over in sequence
or 2) change table order in database
We also have this issue in the backend where we assign the users to groups. the ordering is not in any specific order.

9 years 7 months ago
Licenses:

Hi, Eric.

Group categories are sorted alphabetically.
Groups are sorted by creation time - most recent on top.
I think that best way to reorder them will be to change group creation date in database, in table _community_groups
I tested this solution and it works.

You mean order of assigned members?


- Instead of saying: 'it's not working', explain the problem in detail.
- Screenshots with the URL visible in them and the problem marked are more than welcome.
- Tell us how to replicate the problem, we can't fix it if we can't find it.
- Make sure that your site/server meets JomSocial System Requirements
- Make sure to setup JomSocial Cron Job
- Always provide us with access details to the backend and ftp. We need it to debug problems.
- If you have a similar problem, but a solution you found isn't working, open a new thread instead of 'merging' with an existing one.

- Use the "Thank You" feature on any post that helped you
The following user(s) said Thank You: Eric
9 years 7 months ago
  • Dimas Tekad Santosa's Avatar
  • Dimas Tekad Santosa
  • Visitor
  • Thank you received: 0
Licenses:

Hi Eric,

Both steps are fine, just please make sure if you will do #2 you dont touch the group id.

thank you

9 years 7 months ago
  • Eric's Avatar
    Topic Author
  • Eric
  • Offline
  • Fresh Boarder
  • Posts: 21
  • Thank you received: 1
Licenses:
JomSocial Expired

I think this will fix my issues. Going to work on it now.......Thank you! Will be sure not to touch the group IDS

9 years 7 months ago
  • Eric's Avatar
    Topic Author
  • Eric
  • Offline
  • Fresh Boarder
  • Posts: 21
  • Thank you received: 1
Licenses:
JomSocial Expired

I followed your date sequence and it all worked.
I also realized what was controlling the order of the assignment. It is sorting the groups for assignment by "group owner".
So we need to make one admin/user own all and it will sort correctly.

<option value="8">ELW Sustainability & Dissemination </option>
<option selected="true" value="9">PDCP Discovery</option>
<option selected="true" value="2">ELW Discovery</option>
<option selected="true" value="3">EADS Sustainability & Dissemination</option>
<option value="6">EADS Discovery</option>
<option value="5">EADS Application</option>
<option value="7">ELW Application</option>
<option value="10">PDCP Application</option>
<option value="11">PDCP Sustainability & Dissemination</option>

9 years 7 months ago
  • Eric's Avatar
    Topic Author
  • Eric
  • Offline
  • Fresh Boarder
  • Posts: 21
  • Thank you received: 1
Licenses:
JomSocial Expired

Backend assignment of groups to user seems to be unaffceted by user or creation date.
Do you know what this code uses to render the list? Its not cached that I can see.

<select id="groupid" multiple="true" name="groupid[]">
<option selected="true" value="8">ELW Sustainability & Dissemination </option>
<option selected="true" value="9">PDCP Discovery</option>
<option selected="true" value="2">ELW Discovery</option>
<option selected="true" value="3">EADS Sustainability & Dissemination</option>
<option selected="true" value="6">EADS Discovery</option>
<option selected="true" value="5">EADS Application</option>
<option selected="true" value="7">ELW Application</option>
<option selected="true" value="10">PDCP Application</option>
<option selected="true" value="11">PDCP Sustainability & Dissemination</option>
</select>

Attachments:
9 years 7 months ago
  • Dimas Tekad Santosa's Avatar
  • Dimas Tekad Santosa
  • Visitor
  • Thank you received: 0
Licenses:

Hi Eric,

This is the quick fix, open this file administrator/components/com_community/models/groups.php, find this code :

$query	= "SELECT * FROM " . $db->quoteName( '#__community_groups');

replace to :
$query	= "SELECT * FROM " . $db->quoteName( '#__community_groups'). " ORDER BY ".$db->quoteName('created')." DESC";

not tested yet but i hope it will help.

thank you

Moderators: Piotr Garasiński
Powered by Kunena Forum

Join 180,000 websites creating Amazing communities

JomSocial is the most complete, easy-to-use addon that turns Joomla CMS into a
full -fledged, social networking site

TRY NOW BUY NOW