[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] projects/inc/class.uistatistics.inc.php, 1.53
From: |
nomail |
Subject: |
[Phpgroupware-cvs] projects/inc/class.uistatistics.inc.php, 1.53 |
Date: |
Wed, 2 Jun 2004 18:27:56 +0200 |
Update of /projects/inc
Modified Files:
Branch:
class.uistatistics.inc.php
date: 2004/06/02 16:27:56; author: ceb; state: Exp; lines: +25 -6
Log Message:
update
=====================================================================
Index: projects/inc/class.uistatistics.inc.php
diff -u projects/inc/class.uistatistics.inc.php:1.52
projects/inc/class.uistatistics.inc.php:1.53
--- projects/inc/class.uistatistics.inc.php:1.52 Tue Jun 1 15:34:56 2004
+++ projects/inc/class.uistatistics.inc.php Wed Jun 2 16:27:56 2004
@@ -737,12 +737,15 @@
$gantt_popup =
get_var('gantt_popup',array('POST','GET'));
$action =
get_var('action',array('POST','GET'));
$parent =
get_var('parent',array('POST','GET'));
-
+ $expandtree =
get_var('expandtree',array('POST','GET'));
$screen_width =
get_var('screen_width',array('POST','GET'));
$screen_height =
get_var('screen_height',array('POST','GET'));
//echo 'WIDTH=' . $screen_width;
//echo 'HEIGHT=' . $screen_height;
+ //echo 'parent=' . $parent;
+ //echo 'start=' . $start;
+ //echo 'end=' . $end;
if (! $project_id)
{
@@ -753,6 +756,15 @@
$project_array = explode(',',$project_id);
}
+ if($parent > 0)
+ {
+
$this->bostatistics->save_gantt_data($parent,$expandtree);
+ }
+
+ $parent_array = $this->bostatistics->read_gantt_data();
+
+ //_debug_array($parent_array);
+
$GLOBALS['phpgw_info']['flags']['app_header'] =
lang('projects') . ': ' . lang('gantt chart') . $this->admin_header_info();
$jscal = CreateObject('phpgwapi.jscalendar'); //
before phpgw_header() !!!
@@ -796,6 +808,7 @@
{
$start_val = $start;
}
+
if(is_array($edate))
{
$end_array =
$jscal->input2date($edate['str']);
@@ -809,6 +822,9 @@
$start =
$start_val?$start_val:mktime(12,0,0,date('m'),date('d'),date('Y'));
$end =
$end_val?$end_val:mktime(12,0,0,date('m'),date('d')+30,date('Y'));
+ $GLOBALS['phpgw']->template->set_var('start',$start);
+ $GLOBALS['phpgw']->template->set_var('end',$end);
+
$GLOBALS['phpgw']->template->set_var('sdate_select',$jscal->input('sdate[str]',$start));
$GLOBALS['phpgw']->template->set_var('edate_select',$jscal->input('edate[str]',$end));
@@ -826,7 +842,7 @@
//_debug_array($project_array);
$gantt_data =
$this->bostatistics->show_graph(array('project_array' => $project_array,'sdate'
=> $start, 'edate' => $end,'width' => $screen_width,
-
'height' => $screen_height,'gantt_popup' =>
$gantt_popup,'parent' => $parent));
+
'height' => $screen_height,'gantt_popup' =>
$gantt_popup,'parent_array' => $parent_array));
$GLOBALS['phpgw']->template->set_var('lang_close_window',lang('close window'));
$GLOBALS['phpgw']->template->set_var('lang_show_gantt_in_new_window',lang('show
gantt chart in new window'));
@@ -835,11 +851,14 @@
//_debug_array($gantt_data);
- foreach($gantt_data['map'] as $map)
+ for($i=(count($gantt_data['img_map'])-1);$i>=0;--$i)
{
-
$GLOBALS['phpgw']->template->set_var('coords',$map['map']);
+
$GLOBALS['phpgw']->template->set_var('coords',implode(',',$gantt_data['img_map'][$i]['img_map']));
- $link_data['parent'] = $map['project_id'];
+ $link_data['start'] = $start;
+ $link_data['end'] = $end;
+ $link_data['parent'] =
$gantt_data['img_map'][$i]['project_id'];
+ $link_data['expandtree'] =
(in_array($gantt_data['img_map'][$i]['project_id'],$parent_array)?'del':'add');
$GLOBALS['phpgw']->template->set_var('gantt_url',$GLOBALS['phpgw']->link('/index.php',$link_data));
$GLOBALS['phpgw']->template->fp('list','map',True);
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] projects/inc/class.uistatistics.inc.php, 1.53,
nomail <=