* Calendar: dayview allow edit popup for task pane by clicking on icon/status icon of particular infolog line. Backport of N.Grays implementation

This commit is contained in:
Klaus Leithoff 2010-12-14 15:32:52 +00:00
parent 613602337e
commit 03efa78a8e
2 changed files with 13 additions and 3 deletions

View File

@ -716,11 +716,18 @@ function open_edit(series)
$icons .= ($icons?' ':'').$GLOBALS['egw']->html->image($app,$name,lang($name),'border="0" width="15" height="15"');
}
$class = $class == 'row_on' ? 'row_off' : 'row_on';
if($todo['edit']) {
list($width, $height) = explode('x', $todo['edit']['size']);
unset($todo['edit']['size']);
$edit_icon_href = html::a_href( $icons, $todo['edit'],'',' target="_blank" onclick="window.open(this.href,this.target,\'dependent=yes,width='.$width.',height='.$height.',scrollbars=yes,status=yes\'); return false;"');
$edit_href = html::a_href( $todo['title'], $todo['edit'],'',' target="_blank" onclick="window.open(this.href,this.target,\'dependent=yes,width=750,height=590,scrollbars=yes,status=yes\'); return false;"');
}
$icon_href = html::a_href($icons,$todo['view']);
$href = html::a_href($todo['title'], $todo['view']);
$content .= " <tr class=\"$class\">\n <td valign=\"top\" width=\"15%\" nowrap>".
($this->bo->printer_friendly?$icons:$GLOBALS['egw']->html->a_href($icons,$todo['view'])).
($this->bo->printer_friendly?$icons:($edit_icon_href ? $edit_icon_href : $icon_href)).
"</td>\n <td>".($this->printer_friendly?$todo['title']:
$GLOBALS['egw']->html->a_href($todo['title'],$todo['view']))."</td>\n </tr>\n";
$href)."</td>\n </tr>\n";
/**
* ToDo: add delete and closing action
*/

View File

@ -1226,6 +1226,8 @@ class infolog_bo
$title = ($do_events?common::formattime($start->format('H'),$start->format('i')).' ':'').
$info['info_subject'];
$view = egw_link::view('infolog',$info['info_id']);
$edit = egw_link::edit('infolog',$info['info_id'], $size);
$edit['size'] = $size;
$content=array();
foreach ($icons = array(
$info['info_type'] => 'infolog',
@ -1242,6 +1244,7 @@ class infolog_bo
'endtime' => ($info['info_enddate'] ? $info['info_enddate'] : $info['info_startdate']),
'title' => $title,
'view' => $view,
'edit' => $edit,
'icons' => $icons,
'content' => $content
);