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.57, 1.


From: Bettina Gille <address@hidden>
Subject: [Phpgroupware-cvs] CVS: projects/inc class.boprojects.inc.php, 1.57, 1.58 class.soprojects.inc.php, 1.45, 1.46 class.uiprojects.inc.php, 1.69, 1.70 hook_home.inc.php, 1.1, 1.2
Date: Fri, 19 Sep 2003 16:51:03 -0400

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

Modified Files:
        class.boprojects.inc.php class.soprojects.inc.php 
        class.uiprojects.inc.php hook_home.inc.php 
Log Message:
finished hook home

Index: class.boprojects.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/projects/inc/class.boprojects.inc.php,v
retrieving revision 1.57
retrieving revision 1.58
diff -C2 -r1.57 -r1.58
*** class.boprojects.inc.php    15 Sep 2003 23:20:20 -0000      1.57
--- class.boprojects.inc.php    19 Sep 2003 20:51:01 -0000      1.58
***************
*** 744,749 ****
                        if (is_array($error))
                        {
!                               //return $error;
!                               _debug_array($error);
                        }
                }
--- 744,749 ----
                        if (is_array($error))
                        {
!                               return $error;
!                               //_debug_array($error);
                        }
                }

Index: class.soprojects.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/projects/inc/class.soprojects.inc.php,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** class.soprojects.inc.php    12 Sep 2003 00:07:11 -0000      1.45
--- class.soprojects.inc.php    19 Sep 2003 20:51:01 -0000      1.46
***************
*** 165,168 ****
--- 165,172 ----
                                $filtermethod = ' coordinator=' . 
$this->account;
                        }
+                       elseif ($filter == 'public')
+                       {
+                               $filtermethod = " access != 'private' ";
+                       }
                        else
                        {

Index: class.uiprojects.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/projects/inc/class.uiprojects.inc.php,v
retrieving revision 1.69
retrieving revision 1.70
diff -C2 -r1.69 -r1.70
*** class.uiprojects.inc.php    16 Sep 2003 00:50:22 -0000      1.69
--- class.uiprojects.inc.php    19 Sep 2003 20:51:01 -0000      1.70
***************
*** 439,443 ****
                        }
  
!                       $this->set_app_langs();
  
                        $this->t = 
CreateObject('phpgwapi.Template',$GLOBALS['phpgw']->common->get_tpl_dir('projects'));
--- 439,453 ----
                        }
  
!                       $menuaction     = get_var('menuaction',Array('GET'));
!                       if ($menuaction)
!                       {
!                               $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang('projects') . ': ' . ($pro_main?lang('list jobs'):lang('list projects'));
!                               $GLOBALS['phpgw']->common->phpgw_header();
!                               echo parse_navbar();
!                       }
!                       else
!                       {
!                               $this->bo->cats->app_name = 'projects';
!                       }
  
                        $this->t = 
CreateObject('phpgwapi.Template',$GLOBALS['phpgw']->common->get_tpl_dir('projects'));
***************
*** 445,448 ****
--- 455,461 ----
                        
$this->t->set_block('projects_list_t','projects_list','list');
  
+                       
$this->t->set_var('th_bg',$GLOBALS['phpgw_info']['theme']['th_bg']);
+ 
+ 
                        if (!$action)
                        {
***************
*** 457,465 ****
                        );
  
!                       if (! $this->status)
!                       {
!                               $this->status = 'active';
!                       }
  
                        $pro = $this->bo->list_projects($action,$pro_main);
  
--- 470,477 ----
                        );
  
!                       $this->status = 'active';
  
+                       $this->bo->filter = 'public';
+                       //$this->bo->limit = False;
                        $pro = $this->bo->list_projects($action,$pro_main);
  
***************
*** 477,482 ****
                        if ($action == 'mains')
                        {
!                               $action_list= '<form method="POST" action="' . 
$GLOBALS['phpgw']->link('/index.php',$link_data) . '" name="form">' . "\n"
!                                                       . '<select 
name="cat_id" onChange="this.form.submit();"><option value="none">' . 
lang('Select category') . '</option>' . "\n"
                                                        . 
$this->bo->cats->formatted_list('select','all',$this->cat_id,True) . 
'</select>';
                                $this->t->set_var('lang_action',lang('Jobs'));
--- 489,493 ----
                        if ($action == 'mains')
                        {
!                               $action_list= '<select name="cat_id" 
onChange="this.form.submit();"><option value="none">' . lang('Select category') 
. '</option>' . "\n"
                                                        . 
$this->bo->cats->formatted_list('select','all',$this->cat_id,True) . 
'</select>';
                                $this->t->set_var('lang_action',lang('Jobs'));
***************
*** 484,489 ****
                        else
                        {
!                               $action_list= '<form method="POST" action="' . 
$GLOBALS['phpgw']->link('/index.php',$link_data) .'" name="form">' . "\n"
!                                                       . '<select 
name="pro_main" onChange="this.form.submit();"><option value="">' . 
lang('Select main project') . '</option>' . "\n"
                                                        . 
$this->bo->select_project_list(array('status' => $status, 'selected' => 
$pro_main)) . '</select>';
                                $this->t->set_var('lang_action',lang('Work 
hours'));
--- 495,499 ----
                        else
                        {
!                               $action_list= '<select name="pro_main" 
onChange="this.form.submit();"><option value="">' . lang('Select main project') 
. '</option>' . "\n"
                                                        . 
$this->bo->select_project_list(array('status' => $status, 'selected' => 
$pro_main)) . '</select>';
                                $this->t->set_var('lang_action',lang('Work 
hours'));
***************
*** 491,499 ****
  
                        $this->t->set_var('action_list',$action_list);
!                       
$this->t->set_var('filter_action',$GLOBALS['phpgw']->link('/index.php',$link_data));
!                       
$this->t->set_var('filter_list',$this->nextmatchs->new_filter($this->filter));
!                       
$this->t->set_var('search_action',$GLOBALS['phpgw']->link('/index.php',$link_data));
                        
$this->t->set_var('search_list',$this->nextmatchs->search(array('query' => 
$this->query)));
-                       
$this->t->set_var('status_action',$GLOBALS['phpgw']->link('/index.php',$link_data));
                        
$this->t->set_var('status_list',$this->status_format($this->status));
  
--- 501,506 ----
  
                        $this->t->set_var('action_list',$action_list);
!                       
$this->t->set_var('action_url',$GLOBALS['phpgw']->link('/index.php',$link_data));
                        
$this->t->set_var('search_list',$this->nextmatchs->search(array('query' => 
$this->query)));
                        
$this->t->set_var('status_list',$this->status_format($this->status));
  
***************
*** 541,557 ****
  
                                $link_data['project_id'] = 
$pro[$i]['project_id'];
! 
!                               if 
($this->bo->check_perms($this->grants[$pro[$i]['coordinator']],PHPGW_ACL_EDIT) 
|| $pro[$i]['coordinator'] == $this->account)
!                               {
!                                       $link_data['menuaction'] = 
'projects.uiprojects.edit_project';
!                                       
$this->t->set_var('edit',$GLOBALS['phpgw']->link('/index.php',$link_data));
!                                       
$this->t->set_var('lang_edit_entry',lang('Edit'));
!                               }
!                               else
!                               {
!                                       $this->t->set_var('edit','');
!                                       
$this->t->set_var('lang_edit_entry','&nbsp;');
!                               }
! 
                                $link_data['menuaction'] = 
'projects.uiprojects.view_project';
                                
$this->t->set_var('view',$GLOBALS['phpgw']->link('/index.php',$link_data));
--- 548,552 ----
  
                                $link_data['project_id'] = 
$pro[$i]['project_id'];
!                               $link_data['public_view'] = True;
                                $link_data['menuaction'] = 
'projects.uiprojects.view_project';
                                
$this->t->set_var('view',$GLOBALS['phpgw']->link('/index.php',$link_data));
***************
*** 560,572 ****
                                if ($action == 'mains')
                                {
!                                       
$this->t->set_var('action_entry',$GLOBALS['phpgw']->link('/index.php','menuaction=projects.uiprojects.list_projects&pro_main='
                                                                                
. $pro[$i]['project_id'] . '&action=subs'));
!                                       
$this->t->set_var('lang_action_entry',lang('Jobs'));
                                }
                                else
                                {
!                                       $link_data['menuaction'] = 
'projects.uiprojecthours.list_hours';
!                                       
$this->t->set_var('action_entry',$GLOBALS['phpgw']->link('/index.php',$link_data));
 
!                                       
$this->t->set_var('lang_action_entry',lang('Work hours'));
                                }
  
--- 555,566 ----
                                if ($action == 'mains')
                                {
!                                       
$this->t->set_var('jobs',$GLOBALS['phpgw']->link('/index.php','menuaction=projects.uiprojects.list_projects_home&pro_main='
                                                                                
. $pro[$i]['project_id'] . '&action=subs'));
!                                       
$this->t->set_var('lang_jobs_entry',lang('Jobs'));
                                }
                                else
                                {
!                                       $this->t->set_var('action_entry',''); 
!                                       
$this->t->set_var('lang_action_entry','');
                                }
  
***************
*** 577,581 ****
  
                        $this->save_sessiondata($action);
!                       return $this->t->fp('out','projects_list_t',True);
                }
  
--- 571,586 ----
  
                        $this->save_sessiondata($action);
! 
!                       $menuaction     = get_var('menuaction',Array('GET'));
!                       if ($menuaction)
!                       {
!                               list($app,$class,$method) = 
explode('.',$menuaction);
!                               $var['app_tpl'] = $method;
!                               $this->t->pfp('out','projects_list_t',True);
!                       }
!                       else
!                       {
!                               return 
$this->t->fp('out','projects_list_t',True);
!                       }
                }
  
***************
*** 979,996 ****
                function view_project()
                {
!                       $action         = get_var('action',array('GET'));
!                       $pro_main       = get_var('pro_main',array('GET'));
!                       $project_id     = get_var('project_id',array('GET'));
! 
!                       $link_data = array
!                       (
!                               'menuaction'    => 
'projects.uiprojects.list_projects',
!                               'pro_main'              => $pro_main,
!                               'action'                => $action,
!                               'project_id'    => $project_id
!                       );
  
                        $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang('projects') . ': ' . ($pro_main?lang('view job'):lang('view project'));
!                       $this->display_app_header();
  
                        $GLOBALS['phpgw']->template->set_file(array('view' => 
'view.tpl'));
--- 984,1006 ----
                function view_project()
                {
!                       $action                 = $_GET['action'];
!                       $pro_main               = $_GET['pro_main'];
!                       $project_id             = $_GET['project_id'];
!                       $public_view    = $_GET['public_view'];
  
                        $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang('projects') . ': ' . ($pro_main?lang('view job'):lang('view project'));
! 
!                       if (isset($public_view))
!                       {
!                               $menuaction = 
'projects.uiprojects.list_projects_home';
!                               $GLOBALS['phpgw']->common->phpgw_header();
!                               echo parse_navbar();
!                               $this->set_app_langs();
!                       }
!                       else
!                       {
!                               $menuaction = 
'projects.uiprojects.list_projects';
!                               $this->display_app_header();
!                       }
  
                        $GLOBALS['phpgw']->template->set_file(array('view' => 
'view.tpl'));

Index: hook_home.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/projects/inc/hook_home.inc.php,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** hook_home.inc.php   16 Sep 2003 00:50:22 -0000      1.1
--- hook_home.inc.php   19 Sep 2003 20:51:01 -0000      1.2
***************
*** 23,29 ****
  
                $pro = CreateObject('projects.uiprojects');
- 
-               
//$GLOBALS['phpgw']->template->set_root($GLOBALS['phpgw']->common->get_tpl_dir('projects'));
- 
                $extra_data = 
'<td>'."\n".$pro->list_projects_home().'</td>'."\n";
  
--- 23,26 ----





reply via email to

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