MHL3060 / bentux

Automatically exported from code.google.com/p/bentux
0 stars 0 forks source link

sorting alphabetically #74

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
It is easier in a user experience if we have the drop down menu sorted 
alphabetically.

included:
- drop down menu on the product page.
- pop up page for product. 
- admin: brandname, manufacturer, subcat

I can work on this, just need to know see some examples for sorting shouldnt be 
too complicated i believe

Original issue reported on code.google.com by lhkh...@gmail.com on 10 Sep 2010 at 3:43

GoogleCodeExporter commented 9 years ago
for the product page, 
you can done it in productlistController

take a look Criterial interface.

do a search of Hibernate Criteria 

Original comment by benli3...@gmail.com on 10 Sep 2010 at 4:05

GoogleCodeExporter commented 9 years ago
hi, i found more info for this

List cats = sess.createCriteria(Cat.class)
    .add( Restrictions.like("name", "F%")
    .addOrder( Order.asc("name") )
    .addOrder( Order.desc("age") )
    .setMaxResults(50)
    .list();

not sure how to apply it to the controller tho

Original comment by lhkh...@gmail.com on 19 Oct 2010 at 3:57

GoogleCodeExporter commented 9 years ago
Don't worry about that.

I will do it.

Original comment by benli3...@gmail.com on 19 Oct 2010 at 4:34

GoogleCodeExporter commented 9 years ago
which server should I upload?

Original comment by benli3...@gmail.com on 20 Oct 2010 at 3:03

GoogleCodeExporter commented 9 years ago
I haven't seen the change on the drop down menu but the boxes are sorted now 
which is nice too.

Original comment by lhkh...@gmail.com on 20 Oct 2010 at 4:06