phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] CVS: projects/inc class.boprojects.inc.php, 1.53, 1.


From: Bettina Gille <address@hidden>
Subject: [Phpgroupware-cvs] CVS: projects/inc class.boprojects.inc.php, 1.53, 1.54 class.soprojects.inc.php, 1.44, 1.45 class.uiprojects.inc.php, 1.66, 1.67
Date: Thu, 11 Sep 2003 20:07:15 -0400

Update of /cvsroot/phpgroupware/projects/inc
In directory subversions:/tmp/cvs-serv31106/inc

Modified Files:
        class.boprojects.inc.php class.soprojects.inc.php 
        class.uiprojects.inc.php 
Log Message:
worked on dependencies

Index: class.boprojects.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/projects/inc/class.boprojects.inc.php,v
retrieving revision 1.53
retrieving revision 1.54
diff -C2 -r1.53 -r1.54
*** class.boprojects.inc.php    11 Sep 2003 02:47:56 -0000      1.53
--- class.boprojects.inc.php    12 Sep 2003 00:07:11 -0000      1.54
***************
*** 522,526 ****
                                'status'                        => 
$pro['status'],
                                'owner'                         => 
$pro['owner'],
!                               'processor'                     => 
$pro['processor']
                        );
  
--- 522,527 ----
                                'status'                        => 
$pro['status'],
                                'owner'                         => 
$pro['owner'],
!                               'processor'                     => 
$pro['processor'],
!                               'previous'                      => 
$pro['previous']
                        );
  
***************
*** 683,687 ****
                        if ($action == 'mains')
                        {
!                               if ((!$values['budget'] || $values['budget'] == 
0) && $values['pcosts'])
                                {
                                        $error[] = lang('please specify the 
budget');
--- 684,688 ----
                        if ($action == 'mains')
                        {
!                               if ((!$values['budget'] || $values['budget'] == 
0) && $values['pcosts'] > 0)
                                {
                                        $error[] = lang('please specify the 
budget');
***************
*** 744,748 ****
                        if (is_array($error))
                        {
!                               return $error;
                        }
                }
--- 745,750 ----
                        if (is_array($error))
                        {
!                               //return $error;
!                               _debug_array($error);
                        }
                }
***************
*** 839,843 ****
                        }
  
!                       //_debug_array($values);
  
                        if (intval($values['project_id']) > 0)
--- 841,848 ----
                        }
  
!                       if (!$values['previous'] && $values['parent'])
!                       {
!                               $values['previous'] = 
$this->return_value('previous',$values['parent']);
!                       }
  
                        if (intval($values['project_id']) > 0)

Index: class.soprojects.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/projects/inc/class.soprojects.inc.php,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -r1.44 -r1.45
*** class.soprojects.inc.php    11 Sep 2003 02:47:56 -0000      1.44
--- class.soprojects.inc.php    12 Sep 2003 00:07:11 -0000      1.45
***************
*** 92,96 ****
                                        'pcosts'                => 
$this->db->f('pcosts'),
                                        'main'                  => 
$this->db->f('main'),
!                                       'level'                 => 
$this->db->f('level')
                                );
                        }
--- 92,97 ----
                                        'pcosts'                => 
$this->db->f('pcosts'),
                                        'main'                  => 
$this->db->f('main'),
!                                       'level'                 => 
$this->db->f('level'),
!                                       'previous'              => 
$this->db->f('previous')
                                );
                        }
***************
*** 319,328 ****
  
                        $this->db->query('INSERT into phpgw_p_projects 
(owner,access,category,entry_date,start_date,end_date,coordinator,customer,status,'
!                                                       . 
'descr,title,budget,num,parent,time_planned,date_created,processor,investment_nr,pcosts,main,level)
 VALUES (' . $this->account
                                                        . ",'" . 
$values['access'] . "'," . intval($values['cat']) . ',' . time() . ',' . 
intval($values['sdate']) . ','
                                                        . 
intval($values['edate']) . ',' . intval($values['coordinator']) . ',' . 
intval($values['customer']) . ",'" . $values['status']
                                                        . "','" . 
$values['descr'] . "','" . $values['title'] . "'," . $values['budget'] . ",'" . 
$values['number'] . "',"
                                                        . 
intval($values['parent']) . ',' . intval($values['ptime']) . ',' . time() . ',' 
. $this->account . ",'" . $values['investment_nr']
!                                                       . "'," . 
$values['pcosts'] . ',' . intval($values['main']) . ',' . 
intval($values['level']) . ')',__LINE__,__FILE__);
  
                        $p_id = $this->db->get_last_insert_id($table,'id');
--- 320,329 ----
  
                        $this->db->query('INSERT into phpgw_p_projects 
(owner,access,category,entry_date,start_date,end_date,coordinator,customer,status,'
!                                                       . 
'descr,title,budget,num,parent,time_planned,date_created,processor,investment_nr,pcosts,main,level,previous)
 VALUES (' . $this->account
                                                        . ",'" . 
$values['access'] . "'," . intval($values['cat']) . ',' . time() . ',' . 
intval($values['sdate']) . ','
                                                        . 
intval($values['edate']) . ',' . intval($values['coordinator']) . ',' . 
intval($values['customer']) . ",'" . $values['status']
                                                        . "','" . 
$values['descr'] . "','" . $values['title'] . "'," . $values['budget'] . ",'" . 
$values['number'] . "',"
                                                        . 
intval($values['parent']) . ',' . intval($values['ptime']) . ',' . time() . ',' 
. $this->account . ",'" . $values['investment_nr']
!                                                       . "'," . 
$values['pcosts'] . ',' . intval($values['main']) . ',' . 
intval($values['level']) . ',' . intval($values['previous']) . 
')',__LINE__,__FILE__);
  
                        $p_id = $this->db->get_last_insert_id($table,'id');
***************
*** 483,487 ****
                                                        . $values['number'] . 
"', time_planned=" . intval($values['ptime']) . ', processor=' . $this->account 
. ", investment_nr='"
                                                        . 
$values['investment_nr'] . "', pcosts=" . $values['pcosts'] . ', parent=' . 
$values['parent']
!                                                       . ', level=' . 
intval($values['level']) . ' where id=' . 
$values['project_id'],__LINE__,__FILE__);
  
                        $this->db->query('SELECT max(month) FROM phpgw_p_pcosts 
where project_id=' . $values['project_id'],__LINE__,__FILE__);
--- 484,488 ----
                                                        . $values['number'] . 
"', time_planned=" . intval($values['ptime']) . ', processor=' . $this->account 
. ", investment_nr='"
                                                        . 
$values['investment_nr'] . "', pcosts=" . $values['pcosts'] . ', parent=' . 
$values['parent']
!                                                       . ', level=' . 
intval($values['level']) . ', previous=' . intval($values['previous']) . ' 
where id=' . $values['project_id'],__LINE__,__FILE__);
  
                        $this->db->query('SELECT max(month) FROM phpgw_p_pcosts 
where project_id=' . $values['project_id'],__LINE__,__FILE__);
***************
*** 746,755 ****
                                switch ($action)
                                {
!                                       case 'pro':             $column = 
'num,title'; break;
!                                       case 'edate':   $column = 'end_date'; 
break;
!                                       case 'sdate':   $column = 'start_date'; 
break;
!                                       case 'ptime':   $column = 
'time_planned'; break;
!                                       case 'invest':  $column = 
'investment_nr'; break;
!                                       case 'budget':  $column = 'budget'; 
break;
                                }
  
--- 747,757 ----
                                switch ($action)
                                {
!                                       case 'pro':                     $column 
= 'num,title'; break;
!                                       case 'edate':           $column = 
'end_date'; break;
!                                       case 'sdate':           $column = 
'start_date'; break;
!                                       case 'ptime':           $column = 
'time_planned'; break;
!                                       case 'invest':          $column = 
'investment_nr'; break;
!                                       case 'budget':          $column = 
'budget'; break;
!                                       case 'previous':        $column = 
'previous'; break;
                                }
  

Index: class.uiprojects.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/projects/inc/class.uiprojects.inc.php,v
retrieving revision 1.66
retrieving revision 1.67
diff -C2 -r1.66 -r1.67
*** class.uiprojects.inc.php    11 Sep 2003 02:47:56 -0000      1.66
--- class.uiprojects.inc.php    12 Sep 2003 00:07:11 -0000      1.67
***************
*** 448,458 ****
                function employee_format($data)
                {
-                       $selected       = 
(isset($data['selected'])?$data['selected']:'');
                        $type           = ($data['type']?$data['type']:'list');
                        $project_id     = 
($data['project_id']?$data['project_id']:0);
  
                        if (!is_array($selected))
                        {
!                               $selected = explode(',',$selected);
                        }
  
--- 448,458 ----
                function employee_format($data)
                {
                        $type           = ($data['type']?$data['type']:'list');
                        $project_id     = 
($data['project_id']?$data['project_id']:0);
  
+                       $selected = $this->bo->get_acl_for_project($project_id);
                        if (!is_array($selected))
                        {
!                               $selected = array();
                        }
  
***************
*** 463,472 ****
                                        break;
                                case 'field':
!                                       $employees = 
$this->bo->selected_employees($project_id);
!                                       $selected = 
$this->bo->get_acl_for_project($project_id);
                                        break;
                        }
  
                        //_debug_array($employees);
                        while (is_array($employees) && list($null,$account) = 
each($employees))
                        {
--- 463,472 ----
                                        break;
                                case 'field':
!                                       $employees      = 
$this->bo->selected_employees($project_id);
                                        break;
                        }
  
                        //_debug_array($employees);
+                       //_debug_array($selected);
                        while (is_array($employees) && list($null,$account) = 
each($employees))
                        {
***************
*** 797,801 ****
                                                
$GLOBALS['phpgw']->template->fp('clisthandle','clist',True);
  
!                                       
$GLOBALS['phpgw']->template->set_var('employee_list',$this->employee_format(array('selected'
 => $values['employees'],'project_id' => $project_id)));
                                                
$GLOBALS['phpgw']->template->set_var('efieldhandle','');
                                                
$GLOBALS['phpgw']->template->fp('elisthandle','elist',True);
--- 797,801 ----
                                                
$GLOBALS['phpgw']->template->fp('clisthandle','clist',True);
  
!                                       
$GLOBALS['phpgw']->template->set_var('employee_list',$this->employee_format(array('project_id'
 => $project_id)));
                                                
$GLOBALS['phpgw']->template->set_var('efieldhandle','');
                                                
$GLOBALS['phpgw']->template->fp('elisthandle','elist',True);





reply via email to

[Prev in Thread] Current Thread [Next in Thread]