more the seperate parts of how an event is displayd in day/week or month view to give the templare set designer more freedom

This commit is contained in:
Pim Snel 2004-01-08 12:33:20 +00:00
parent 618960e067
commit bfd0ac1316
2 changed files with 28 additions and 7 deletions

View File

@ -2704,15 +2704,31 @@
{
$time = '';
}
$text = '';
$texttitle = $texttime = $textdesc = $textlocation = $textstatus = '';
if(!$is_private)
{
$text .= $this->bo->display_status($event['users_status']);
//$text .= $this->bo->display_status($event['users_status']);
// split text for better display by templates, also see $texttime $texttitle $textdesc $textlocation
$textstatus=$this->bo->display_status($event['users_status']);
}
/*
$text = '<nobr>&nbsp;'.$time.'&nbsp;</nobr> '.$this->bo->get_short_field($event,$is_private,'title').$text.
(!$is_private && $event['description'] ? ': <I>'.$this->bo->get_short_field($event,$is_private,'description').'</I>':'').
(!$is_private && $event['description'] ? ': <i>'.$this->bo->get_short_field($event,$is_private,'description').'</i>':'').
$GLOBALS['phpgw']->browser->br;
*/
$texttime=$time;
$texttitle=$this->bo->get_short_field($event,$is_private,'title');
$textdesc=(!$is_private && $event['description'] ? $this->bo->get_short_field($event,$is_private,'description'):'');
// added $textlocation but this must be activated in the actual pict_link.tpl file of the used template set
$textlocation=$this->bo->get_short_field($event,$is_private,'location');
if ($viewable)
{
@ -2806,10 +2822,15 @@
);
$this->output_template_array($this->link_tpl,'picture','pict',$var);
}
if ($text)
if ($texttitle)
{
$var = Array(
'text' => $text
// 'text' => $text,
'time'=> $texttime,
'title'=> $texttitle,
'users_status'=>$textstatus,
'desc'=> $textdesc,
'location'=> $textlocation
);
$this->output_template_array($this->link_tpl,'picture','link_text',$var);
}

View File

@ -6,10 +6,10 @@
<a href="{link_link}" onMouseOver="window.status='{lang_view}'; return true;" onMouseOut="window.status=''; return true;">
<!-- END link_open -->
<!-- BEGIN pict -->
<img src="{pic_image}" width="{width}" height="{height}" title="{title}" border="0">
<img src="{pic_image}" width="{width}" height="{height}" title="{title}" border="0" />
<!-- END pict -->
<!-- BEGIN link_text -->
{text}
<nobr>&nbsp;{time}&nbsp;</nobr> {title}&nbsp;{users_status}: <i>{desc}</i><!--({location})-->
<!-- END link_text -->
<!-- BEGIN link_close -->
</a>