Best Way to Set Up Complex Sorting?

Author Message

Alex Jones

Thursday 12 February 2004 8:12:09 am

Howdy all, I need some advice, which I hope someone can give. :)

The Challenge:
I need to provide the user (anonymous, not admin) the ability to sort the results of a search and/or fetch with the following possibilities:
<b>View</b> (Category)
- Fixed Blade
- Folding
- Other
<b>Sort By</b>
- Item Number (Low to High) - Text Field
- Item Number (High to Low) - Text Field
- Price (Low to High) - Price
- Price (High to Low) - Price
- Maker Name (Low to High) - Text Field
- Maker Name (High to Low) - Text Field

So, the user may choose to view all Folding Knives, sorted by Price (Low to High) or perhaps view all Fixed Blade Knives starting with the highest Item Number and progressing to the lowest Item Number. I would like to set it up as a couple of drop downs with an "Apply" button, though if I can set up all of the possible combinations as individual links, that would work just as well. Ideally I can provide this capability to the standard pages that use fetch, as well as search results.

So, how should I do this?

Thanks!

Alex

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>

Bruce Morrison

Thursday 12 February 2004 2:41:29 pm

Not an eZ Publish solution but this may be of help
http://www.activeui.net/

Cheers
Bruce

My Blog: http://www.stuffandcontent.com/
Follow me on twitter: http://twitter.com/brucemorrison
Consolidated eZ Publish Feed : http://friendfeed.com/rooms/ez-publish

Alex Jones

Friday 13 February 2004 7:26:54 am

Thanks Bruce. That looks like a neat tool, but it doesn't quite fit my needs. As there could be hundreds of items to display I don't want to incur the load of pulling them all into a single page for display. Rather I would like to have eZ publish fetch the items and use its sorting capabilities to display them in the user-defined order and, should there be more than X amount of items include the google navigator template.

I appreciate the pointer though, that may very well come in handy for a different site that I need to revise!

Alex

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 23:12:35
Script start
Timing: Jan 18 2025 23:12:35
Module start 'layout'
Timing: Jan 18 2025 23:12:35
Module start 'content'
Timing: Jan 18 2025 23:12:36
Module end 'content'
Timing: Jan 18 2025 23:12:36
Script end

Main resources:

Total runtime1.4475 sec
Peak memory usage4,096.0000 KB
Database Queries57

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0075 588.0156152.6250
Module start 'layout' 0.00750.0059 740.640639.4453
Module start 'content' 0.01341.4326 780.0859544.9531
Module end 'content' 1.44600.0015 1,325.039112.1563
Script end 1.4474  1,337.1953 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00360.2497160.0002
Check MTime0.00130.0894160.0001
Mysql Total
Database connection0.00100.065810.0010
Mysqli_queries1.388595.9232570.0244
Looping result0.00070.0472550.0000
Template Total1.396796.520.6984
Template load0.00200.139820.0010
Template processing1.394796.353420.6973
Template load and register function0.00010.006910.0001
states
state_id_array0.00200.135110.0020
state_identifier_array0.00230.157620.0011
Override
Cache load0.00170.1192330.0001
Sytem overhead
Fetch class attribute can translate value0.00090.060020.0004
Fetch class attribute name0.00120.080050.0002
XML
Image XML parsing0.00110.075220.0005
class_abstraction
Instantiating content class attribute0.00000.000960.0000
General
dbfile0.00150.1063220.0001
String conversion0.00000.000940.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
5content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
3content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 16
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs