phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] property/class.botts.php, 1.1.1.12


From: nomail
Subject: [Phpgroupware-cvs] property/class.botts.php, 1.1.1.12
Date: Mon, 10 May 2004 15:18:14 +0200

Update of /property
Modified Files:
        Branch: 
          class.botts.php

date: 2004/05/10 13:18:14;  author: sigurdne;  state: Exp;  lines: +43 -0

Log Message:
no message
=====================================================================
Index: property/class.botts.php
diff -u property/class.botts.php:1.1.1.11 property/class.botts.php:1.1.1.12
--- property/class.botts.php:1.1.1.11   Sun May  9 18:03:35 2004
+++ property/class.botts.php    Mon May 10 13:18:14 2004
@@ -558,6 +558,30 @@
 
                        $ticket = $this->so->read_single($id);
 
+                       if($ticket['location_code'])
+                       {
+
+                               $solocation             = 
CreateObject($this->currentapp.'_solocation');
+                               $soadmin_location       = 
CreateObject($this->currentapp.'_soadmin_location');
+                               $location_data          = 
$solocation->read_single($ticket['location_code']);
+
+                               
$type_id=count(explode('-',$ticket['location_code']));
+                               $fm_location_cols = 
$soadmin_location->read_attrib(array('type_id'=>$type_id,'lookup_type'=>$type_id));
+                               $i=0;
+                               if (isset($fm_location_cols) AND 
is_array($fm_location_cols))
+                               {
+                                       foreach($fm_location_cols as 
$location_entry)
+                                       {
+                                               
if($location_entry['lookup_form'])
+                                               {
+                                                       
$address_element[$i]['text']=$location_entry['input_text'];
+                                                       
$address_element[$i]['value']=$location_data[$location_entry['column_name']];
+                                               }
+                                               $i++;
+                                       }
+                               }
+                       }
+
                        $history_values = 
$this->historylog->return_array(array(),array('O'),'history_timestamp','DESC',$id);
                        $timestampopened = 
$this->bocommon->show_date($history_values[0]['datetime'],$this->dateformat);
 
@@ -629,6 +653,25 @@
 //                     $body .= lang('Subject').': '. $ticket['subject'] ."\n";
                        $body .= lang('Location').': '. 
$ticket['location_code'] ."\n";
                        $body .= lang('Address').': '. $ticket['address'] ."\n";
+                       if (isset($address_element) AND 
is_array($address_element))
+                       {
+                               foreach($address_element as $address_entry)
+                               {
+                                       $body .= $address_entry['text'].': '. 
$address_entry['value'] ."\n";
+                               }
+                       }
+
+                       if($ticket['tenant_id'])
+                       {
+                               
$tenant_data=$this->bocommon->read_single_tenant($ticket['tenant_id']);
+                               $body .= lang('Tenant').': '. 
$tenant_data['first_name'] . ' ' .$tenant_data['last_name'] ."\n";
+
+                               if($tenant_data['contact_phone'])
+                               {
+                                       $body .= lang('Contact phone').': '. 
$tenant_data['contact_phone'] ."\n";
+
+                               }
+                       }
                        $body .= lang('Assigned To').': 
'.$GLOBALS['phpgw']->accounts->id2name($ticket['assignedto'])."\n";
                        $body .= lang('Priority').': '.$ticket['priority']."\n";
                        if($group_name)




reply via email to

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