Vicente Olivan
|
Saturday 15 December 2007 6:17:20 am
I related events calendar to multicalendar, by default, displays each calendar on a table.
I´m trying show all events calendar in a single table, and can display events by category (tags), node, start date and end date.
My problem is how to develop drop-down boxes to do this.
Any suggestions to get started? Thanks a lot
|
Vicente Olivan
|
Monday 21 January 2008 2:04:26 am
I´m trying customize multicalendar template, but not shows items
{foreach $node.data_map.calendars.content.relation_list as $relation}
{def $related_node = fetch( 'content', 'node', hash( 'node_id', $relation.node_id ) )
$related_node_children = fetch( 'content', 'list', hash( 'parent_node_id', $related_node.node_id,
'limit', '5',
'class_filter_type', 'include',
'class_filter_array', array( 'event' ),
'sort_by', array( 'attribute', true(), 'event/from_time' ) ) )}
How can I change foreach control structure for elements to be displayed in a single table? Thanks a lot
|
Vicente Olivan
|
Tuesday 22 January 2008 4:03:26 am
Hi André <b>Original code</b>
{foreach $node.data_map.calendars.content.relation_list as $relation}
{def $related_node = fetch( 'content', 'node', hash( 'node_id', $relation.node_id ) )
$related_node_children = fetch( 'content', 'list', hash( 'parent_node_id', $related_node.node_id,
'limit', '5',
'class_filter_type', 'include',
'class_filter_array', array( 'event' ),
'sort_by', array( 'attribute', true(), 'event/from_time' ) ) )}
<h2><a href="{$related_node.url_alias|ezurl(no)}">{$related_node.name}</a></h2>
<table class="list" border="0" cellspacing="0" cellpadding="0">
<tr>
...
</tr>
{foreach $related_node_children as $child sequence array( 'bglight', 'bgdark' ) as $style}
<tr class="{$style}">
...
</tr>
{/foreach}
</table>
{undef}
{/foreach}
<b>Customized test code</b>
{def $show_calendars_events=fetch( 'content', 'list',
hash( 'parent_node_id', array( '174', '175', '176' ),
'class_filter_type', 'include',
'class_filter_array', array( 'folder', 'event', ),
'sort_by', array( 'attribute', true(), 'event/from_time' ) ) )}
<table class="list" border="0" cellspacing="0" cellpadding="0">
....
{foreach $show_calendars_events as $child sequence array( 'bglight', 'bgdark' ) as $style}
....
{/foreach}
</table>
{undef $show_calendars_events}
It´s works, but when somebody related others calenars not show (it´s normal) Can you help me? Thank you
|
Vicente Olivan
|
Friday 28 November 2008 4:50:45 am
Hi Max,
{def $show_events_calendars=fetch( 'content', 'list', hash( 'parent_node_id', array( 'yournode1', 'yournode2', 'yournode3' ),
'limit', '10',
'class_filter_type', 'include',
'class_filter_array', array( 'folder', 'event' ),
'sort_by', array( 'attribute', true(), 'event/from_time' )
) )}
<table class="list" border="0" cellspacing="0" cellpadding="0" summary="multicalendar">
<tr>
<th>{'Event'|i18n( 'design/ezwebin/full/multicalendar' )}</th>
<th>{'Start date'|i18n( 'design/ezwebin/full/multicalendar' )}</th>
<th>{'Category'|i18n( 'design/ezwebin/full/multicalendar' )}</th>
<th>{'Place'|i18n( 'design/ezwebin/full/multicalendar' )}</th>
</tr>
{foreach $show_events_calendars as $child sequence array( 'bglight', 'bgdark' ) as $style}
<tr class="{$style}">
<td><a href="{$child.url_alias|ezurl(no)}">{$child.name|wash()}</a></td>
<td>{attribute_view_gui attribute=$child.data_map.from_time}</td>
<td>{attribute_view_gui attribute=$child.data_map.category}</td>
<td>{attribute_view_gui attribute=$child.data_map.place}</td>
</tr>
{/foreach}
</table>
{undef $show_events_calendars}
Grettings
|