What's the right place for sort algorithm? Model? View? Controller?

#5
[eluser]rogierb[/eluser]
Sorting should be done in the model. There are two different approaches I use when dealing with sorting.
1: parse the order_by as a variable to you model
2: create different order_by's in you model and use one of them depending on a var you parse to the model.

I prever the last approach.


Messages In This Thread
What's the right place for sort algorithm? Model? View? Controller? - by El Forum - 08-13-2009, 07:52 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.