managing the order of memberships

Does anyone know how D7 manages the order of memberships?

Can someone please help me out and tell me how to order my memberships?

This is what im talking about.

membership screen shot

Quote · 6 May 2010

Looks like the price is in a different database table - the results are sorted by id.

You could change the query where the membership types are read to include an inner join between tables by the Id fields - this should then allow you to sort by the price.

/DM

Dolphin - Ajax Masturbation
Quote · 6 May 2010

Bump anyone know?

I looked into it and its not the order entered in, Its not the sql order,Its not ordered by price or name.

DM got back to me saying he looked into it and he couldnt find the order either with the time he had available to look so does anyone else know or can someone give me a simple code to order it pretty please?

Quote · 7 May 2010

Does anyone know how D7 manages the order of memberships?

Can someone please help me out and tell me how to order my memberships?

This is what im talking about.

membership screen shot

Hello you need open the - modules/boonex/membership/classes/BxMbpDb.php

find this query :

$sSql = "SELECT
`tl`.`ID` AS `mem_id`,
`tl`.`Name` AS `mem_name`,
`tl`.`Icon` AS `mem_icon`,
`tl`.`Description` AS `mem_description` " . $sSelectClause . "
FROM `sys_acl_levels` AS `tl` " . $sJoinClause . "
WHERE 1" . $sWhereClause;

and replce with you needed order criteria . For example :

$sSql = "SELECT
`tl`.`ID` AS `mem_id`,
`tl`.`Name` AS `mem_name`,
`tl`.`Icon` AS `mem_icon`,
`tl`.`Description` AS `mem_description` " . $sSelectClause . "
FROM `sys_acl_levels` AS `tl` " . $sJoinClause . "
WHERE 1" . $sWhereClause . ' ORDER BY `mem_name`';

PS: If possible do not write me personally, please try to ask on the forum first
Quote · 7 May 2010

Thank you so much it worked! :)

Quote · 8 May 2010
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.