(will not work when used as multiple selector)

Author Message

Fabricio Guerrero

Monday 23 January 2006 6:14:55 am

Hi,

(will not work when used as multiple selector)

I've seen that comment all over the forum and documentation section but my problem :( is that i indeed have a Class with a multiple selector and an important part is for me to fetch and filter on that field.

To give a bit more detail we're creating a site based on articles and these articles can have various categories. As an user you can be able to view articles by categories. The fetch works if that Article only belongs to one category but if the article has various categories(multiple selector working here) the fetch just wont return the article...

I've tested various ways of filtering(like, in) but none seem to work. Here's the simple fetch:

{let
filter_cat=fetch( 'content', 'tree', hash( 'parent_node_id', 77,
class_filter_type, "include", class_filter_array, array(25),
attribute_filter, array( array( 'article_issue/category', '=', $selected ) ),
...

Thank you in advance for all help given...

Fabricio

http://www.solobromasychistes.com <<Joomla Site :P
http://www.recipesforhealthyfood.com/ <<Drupal Site :P
http://www.ezforge.com/ <<future ezCommunity, Articles, forums and more...

Fabricio Guerrero

Tuesday 24 January 2006 9:49:08 am

Hi,

Trying to bump this up... I've done a work around for this.. My need was or is to be able to Filter Multiple Selection Attributes.

Since all over this site it specifically indicates that the "attribute_filter" cann't filter these type of Attributes I rewrote the fetch using the 'search' 'text' feature... this way i can perform a text search in the Multiple Selection Attribute and get the Articles assigned to either one or multiple categories...

example fetch:

{def $search=fetch( 'content', 'search',
hash( 'text', 'value_looking_for_here',
'class_id', 25,
'class_attribute_id', multiple_selection_attribute_id_here,
'offset',$view_parameters.offset,
'limit', $numberOfObjects,
'sort_by', array( 'published', false() )
))}
{set search_result=$search['SearchResult']}
{set search_count=$search['SearchCount']}

...here start looping...

Does anybody have any other ways to filter a Multiple SelectionAttribute?

Regards,
Fabricio

http://www.solobromasychistes.com <<Joomla Site :P
http://www.recipesforhealthyfood.com/ <<Drupal Site :P
http://www.ezforge.com/ <<future ezCommunity, Articles, forums and more...

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 20 2025 20:57:57
Script start
Timing: Jan 20 2025 20:57:57
Module start 'layout'
Timing: Jan 20 2025 20:57:57
Module start 'content'
Timing: Jan 20 2025 20:57:57
Module end 'content'
Timing: Jan 20 2025 20:57:57
Script end

Main resources:

Total runtime0.0157 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0048 588.0469151.2266
Module start 'layout' 0.00480.0030 739.273436.6797
Module start 'content' 0.00780.0062 775.953190.1875
Module end 'content' 0.01400.0017 866.140633.9922
Script end 0.0156  900.1328 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002616.5274140.0002
Check MTime0.00127.3967140.0001
Mysql Total
Database connection0.00064.060810.0006
Mysqli_queries0.002918.357130.0010
Looping result0.00000.101810.0000
Template Total0.00138.010.0013
Template load0.00106.477210.0010
Template processing0.00021.454410.0002
Override
Cache load0.00074.468110.0007
General
dbfile0.001610.378480.0002
String conversion0.00000.063840.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs