phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] CVS: property/inc header.inc.php,1.11,1.12 class.fm_w


From: Sigurd Nes <address@hidden>
Subject: [Phpgroupware-cvs] CVS: property/inc header.inc.php,1.11,1.12 class.fm_wrkorder.inc.php,1.6,1.7
Date: Fri, 20 Sep 2002 13:05:38 -0400

Update of /cvsroot/phpgroupware/property/inc
In directory subversions:/tmp/cvs-serv25623/inc

Modified Files:
        header.inc.php class.fm_wrkorder.inc.php 
Log Message:
no message

Index: header.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/property/inc/header.inc.php,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -r1.11 -r1.12
*** header.inc.php      18 Sep 2002 19:54:14 -0000      1.11
--- header.inc.php      20 Sep 2002 17:05:35 -0000      1.12
***************
*** 30,35 ****
        
$admin_workorder=$admins[$module_order['workorder']]['workorder']['admin'];
        $admin_activity=$admins[$module_order['activity']]['activity']['admin'];
  
! //    echo 'admin_activity: '.$admin_activity .'<BR>';
  //    print_r($admins);
  
--- 30,36 ----
        
$admin_workorder=$admins[$module_order['workorder']]['workorder']['admin'];
        $admin_activity=$admins[$module_order['activity']]['activity']['admin'];
+       $admin_invoice=$admins[$module_order['invoice']]['invoice']['admin'];
  
! //    echo 'admin_invoice: '.$admin_invoice .'<BR>';
  //    print_r($admins);
  
***************
*** 149,152 ****
--- 150,163 ----
                $t->set_var('tr_color2',$phpgw_info['theme']['row_off']);
                $admin_info = lang('Invoice');
+               if ($admin_invoice)
+               {
+                       
$t->set_var('sub_invoice_property_value',$phpgw->link('/property/list_property_value.php','sub=p_invoice'));
+                       
$t->set_var('sublang_invoice_property_value',lang('Property value'));
+               }
+               else
+               {
+                       $t->set_var('sublang_invoice_property_value','');
+               }
+ 
        }
        else

Index: class.fm_wrkorder.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/property/inc/class.fm_wrkorder.inc.php,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** class.fm_wrkorder.inc.php   18 Sep 2002 19:54:14 -0000      1.6
--- class.fm_wrkorder.inc.php   20 Sep 2002 17:05:35 -0000      1.7
***************
*** 22,26 ****
                        $this->total_records    = $this->db->num_rows();
                        $this->grants                   = 
$GLOBALS['phpgw']->acl->get_grants('fm_wrkorder');
!                       $this->fm_wrkorder              = 
$this->read_wrkorders($start, $limit, $query_location, $filter, $sort, $order, 
$status, $cat_id, $coordinator_id,$query_vendor,$query_location,$project_id);
  
                }
--- 22,26 ----
                        $this->total_records    = $this->db->num_rows();
                        $this->grants                   = 
$GLOBALS['phpgw']->acl->get_grants('fm_wrkorder');
!                       $this->fm_wrkorder              = 
$this->read_wrkorders($start, $limit, $query_location, $filter, $sort, $order, 
$status, $cat_id, 
$coordinator_id,$query_vendor,$query_location,$project_id,$location_code);
  
                }
***************
*** 31,35 ****
                }
  
!               function read_wrkorders( $start, $limit = True, $query_location 
= '', $filter = '', $sort = '', $order = '', $status = 'active', $cat_id, 
$coordinator_id = '',$query_vendor='',$query_location='',$project_id='')
                {
                        if 
($GLOBALS['phpgw_info']['server']['db_type']=='pgsql')
--- 31,35 ----
                }
  
!               function read_wrkorders( $start, $limit = True, $query_location 
= '', $filter = '', $sort = '', $order = '', $status = 'active', $cat_id, 
$coordinator_id = 
'',$query_vendor='',$query_location='',$project_id='',$location_code='')
                {
                        if 
($GLOBALS['phpgw_info']['server']['db_type']=='pgsql')
***************
*** 44,47 ****
--- 44,48 ----
  //                    global $GLOBALS['phpgw'], $GLOBALS['phpgw_info'];
  
+ 
                        if ($status == 'Avsluttet')
                        {
***************
*** 53,56 ****
--- 54,66 ----
                        }
  
+                       $where_1 = 'and';
+ 
+                       if ($location_code)
+                       {
+                               $statussort='';
+                               $query_location=$location_code;
+                               $where_1 = 'where';
+                       }
+ 
                        if (!$sort)
                        {
***************
*** 122,131 ****
                        if ($query_location)
                        {
!                               $querymethod = " AND (p.title like 
'%$query_location%' OR num like '%$query_location%' OR location_code like 
'%$query_location%' OR org_name like '%$query_location%') ";
                        }
  
                        if ($query_vendor)
                        {
!                               $querymethod .= " AND (p.title like 
'%$query_vendor%' OR num like '%$query_vendor%' OR org_name like 
'%$query_vendor%') ";
                        }
  
--- 132,141 ----
                        if ($query_location)
                        {
!                               $querymethod = " $where_1 (p.title like 
'%$query_location%' OR num like '%$query_location%' OR location_code like 
'%$query_location%' OR org_name like '%$query_location%') ";
                        }
  
                        if ($query_vendor)
                        {
!                               $querymethod .= " $where_1 (p.title like 
'%$query_vendor%' OR num like '%$query_vendor%' OR org_name like 
'%$query_vendor%') ";
                        }
  
***************
*** 136,146 ****
                                {
  
!                                       $sql = "SELECT 
p.id,p.num,p.access,p.category,p.entry_date,p.start_date,p.end_date,p.coordinator,org_name
 as vendor,p.status, "
                                                . "p.descr,p.title,p.budget, 
p.account_id as budget_account, 
p.objekt_id,p.property_name,p.bygg_id,p.building_name,p.seksjons_id,p.etasje,p.leie_id,p.street,a.account_lid,a.account_firstname,a.account_lastname
 FROM "
!                                               . " fm_wo_wrkorders AS p $join 
phpgw_addressbook ON p.vendor = phpgw_addressbook.id $join phpgw_accounts AS a 
on a.account_id=p.coordinator $statussort and project_id='$project_id' ";
                                }
                                else
                                {
!                                       $sql = "SELECT 
p.id,p.num,p.access,p.category,p.entry_date,p.start_date,p.end_date,p.coordinator,org_name
 as vendor,p.status, "
                                        . "p.descr,p.title,p.budget, 
p.account_id as budget_account, 
p.objekt_id,p.property_name,p.bygg_id,p.building_name,p.seksjons_id,p.etasje,p.leie_id,p.street,a.account_lid,a.account_firstname,a.account_lastname
 FROM "
                                        . " fm_wo_wrkorders AS p $join 
phpgw_addressbook ON p.vendor = phpgw_addressbook.id $join phpgw_accounts AS a 
on a.account_id=p.coordinator $statussort $querymethod AND $filtermethod ";
--- 146,156 ----
                                {
  
!                                       $sql = "SELECT 
location_code,p.id,p.num,p.access,p.category,p.entry_date,p.start_date,p.end_date,p.coordinator,org_name
 as vendor,p.status, "
                                                . "p.descr,p.title,p.budget, 
p.account_id as budget_account, 
p.objekt_id,p.property_name,p.bygg_id,p.building_name,p.seksjons_id,p.etasje,p.leie_id,p.street,a.account_lid,a.account_firstname,a.account_lastname
 FROM "
!                                               . " fm_wo_wrkorders AS p $join 
phpgw_addressbook ON p.vendor = phpgw_addressbook.id $join phpgw_accounts AS a 
on a.account_id=p.coordinator $statussort $where_1 project_id='$project_id' ";
                                }
                                else
                                {
!                                       $sql = "SELECT 
location_code,p.id,p.num,p.access,p.category,p.entry_date,p.start_date,p.end_date,p.coordinator,org_name
 as vendor,p.status, "
                                        . "p.descr,p.title,p.budget, 
p.account_id as budget_account, 
p.objekt_id,p.property_name,p.bygg_id,p.building_name,p.seksjons_id,p.etasje,p.leie_id,p.street,a.account_lid,a.account_firstname,a.account_lastname
 FROM "
                                        . " fm_wo_wrkorders AS p $join 
phpgw_addressbook ON p.vendor = phpgw_addressbook.id $join phpgw_accounts AS a 
on a.account_id=p.coordinator $statussort $querymethod AND $filtermethod ";
***************
*** 165,168 ****
--- 175,179 ----
                                while ($this->db->next_record())
                                {
+                                       $fm_wrkorder[$i]['location_code']       
                = $this->db->f('location_code');
                                        $fm_wrkorder[$i]['id']                  
= $this->db->f('id');
                                        $fm_wrkorder[$i]['number']              
= $this->db->f('num');
***************
*** 186,189 ****
--- 197,201 ----
                                        $fm_wrkorder[$i]['bygg_id']             
= $this->db->f('bygg_id');
                                        $fm_wrkorder[$i]['building_name']       
= $this->db->f('building_name');
+                                       $fm_wrkorder[$i]['seksjons_id']         
= $this->db->f('seksjons_id');
                                        $fm_wrkorder[$i]['etasje']              
= $this->db->f('etasje');
                                        $fm_wrkorder[$i]['leie_id']             
= $this->db->f('leie_id');





reply via email to

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