[turba] Sorting browse view

Darci Antônio Tartari dtartari@portoriogrande.com.br
Fri, 9 Aug 2002 08:22:58 -0300


I had a similar problem to order turba list by name then someone wrote the
solution below in the list.  I think you can adapt to your case changing 'name'
variable (my case) to address variable (You will have to find that variable name
because I do not know).

Change these files: (You have to adapt the $sot_criteria to order by address
variable)
=======================
turba/lib/Source.php, line 179
=======================
change:
function search($search_criteria, $sort_criteria = 'lastname', $match =
null)
to:
function search($search_criteria, $sort_criteria = 'name', $match = null)

=======================
turba/lib/List.php
=======================
change:
function sort($sort = 'lastname', $low = null, $high = null)
to:
function sort($sort = 'name', $low = null, $high = null)

=======================
turba/lib/api.php
=======================
change:
$res = $driver->search($criteria, 'lastname', TURBA_SEARCH_OR);
to:
$res = $driver->search($criteria, 'name', TURBA_SEARCH_OR);
"


---------------
Darci Tartari
http://www.portoriogrande.com.br


Citando brendan.smith@uk.zurich.com:

> The default turba 'browse' view orders the names or entries in the order
> they are in the database (it appears).  There doesn't appear to be a prefs
> setting for ordering it by name.  Can anyone point me to where the actual
> query is constructed so that we can I can have a bit of a look at it, with
> a view to adding an 'order by object_name' or some such?
> 
> Regards,
> 
> Brendan
> 
> 
> 
> ___________________________________________________________________________
> 
> The information contained in this message is confidential and may be 
> legally privileged. If you are not the intended recipient, please do not 
> read, copy or otherwise use it and do not disclose it to anyone else. 
> Please notify the sender of the delivery error and then delete the 
> message from your system. 
> 
> Any views or opinions expressed in this email are those of the author only.
> 
> Communications will be monitored regularly to improve our service and for
> security and regulatory purposes.
> 
> Thank you for your assistance.
> 
> ___________________________________________________________________________
> 
> 
> -- 
> Turba mailing list
> Frequently Asked Questions: http://horde.org/faq/
> To unsubscribe, mail: turba-unsubscribe@lists.horde.org
> 
> 



-----------------------------------------
Enviado pelo Correio da SUPRG utilizando
IMP 3.1  http://horde.org/imp/