the filter of an attribute

Author Message

Jacks JNK

Monday 08 September 2008 1:25:35 am

Hi,
I have a problem with the poster attributes of my class. I have two attributes in my class, one of the client side and the other side of the administrator. The principle and the following:
The customer will posted a message in the first attribute and the administrator will respond after a defined time. It must then display real-time the last 10 questions posed by the customers and display the last ten answers posted by the administrator, so that the two class attributes are not change at the same date. It must show results in order of publication, how do I seek a filter of a field of class regardless of the other.

I use the following fetch for displaying last 10 replies:

{def $derniere_r=fetch( content, list,hash(parent_node_id,2,depth,2,limit,10,
					class_filter_type,'include',
					class_filter_array,array('faq'),
					'attribute_filter_array', 
		 			'main_node_only', true(),
				        'sort_by',array('modified',false())) )}

							 			
{foreach $derniere_r as $dr}		

	{if $dr.data_map.reponse.has_content}
	                   	 			
{attribute_view_gui attribute=$dr.data_map.question}							
				
 {/if}
{/foreach}
{undef $derniere_r}

But it does not work perfectly because whenever another question is asked a response to remove from the list

Skype : jacks_ngala

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

Main resources:

Total runtime1.1244 sec
Peak memory usage4,096.0000 KB
Database Queries46

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0069 589.1484152.6250
Module start 'layout' 0.00690.0044 741.773439.4453
Module start 'content' 0.01141.1114 781.2188468.1250
Module end 'content' 1.12280.0016 1,249.34388.1641
Script end 1.1244  1,257.5078 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00380.3341160.0002
Check MTime0.00150.1348160.0001
Mysql Total
Database connection0.00060.055110.0006
Mysqli_queries1.079596.0103460.0235
Looping result0.00050.0430440.0000
Template Total1.083896.420.5419
Template load0.00190.172920.0010
Template processing1.081996.218720.5409
Template load and register function0.00020.014510.0002
states
state_id_array0.00190.164710.0019
state_identifier_array0.00190.165620.0009
Override
Cache load0.00160.1380100.0002
Sytem overhead
Fetch class attribute can translate value0.00070.066210.0007
Fetch class attribute name0.00130.117420.0007
XML
Image XML parsing0.00220.192010.0022
class_abstraction
Instantiating content class attribute0.00000.000620.0000
General
dbfile0.00310.2784160.0002
String conversion0.00000.001240.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
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
2content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 8
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs