phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] tts/viewticket_details.php, 1.42.2.6.4.5


From: nomail
Subject: [Phpgroupware-cvs] tts/viewticket_details.php, 1.42.2.6.4.5
Date: Thu, 12 Aug 2004 11:04:24 +0200

Update of /tts
Modified Files:
        Branch: Version-0_9_16-branch
          viewticket_details.php

date: 2004/08/12 09:04:24;  author: lpiepho;  state: Exp;  lines: +23 -7

Log Message:
bugfix in mailing, updated account-selectbox
=====================================================================
Index: tts/viewticket_details.php
diff -u tts/viewticket_details.php:1.42.2.6.4.4 
tts/viewticket_details.php:1.42.2.6.4.5
--- tts/viewticket_details.php:1.42.2.6.4.4     Tue Apr 20 12:52:17 2004
+++ tts/viewticket_details.php  Thu Aug 12 09:04:24 2004
@@ -147,18 +147,34 @@
                $GLOBALS['phpgw']->template->set_var('optionvalue','0');
                $GLOBALS['phpgw']->template->set_var('optionselected','');
                
$GLOBALS['phpgw']->template->parse('options_assignedto','options_select',true);
+               
                while(list($key,$entry) = each($account_list))
                {
-                       $tag = '';
-                       if($entry['account_id'] == $ticket['assignedto'])
+                       
$GLOBALS['phpgw']->accounts->get_account_name($entry['account_id'],$lid,$fname,$lname);
+                       if(!$fname && !$lname)
+                               continue;
+                       $employees_list[$entry['account_id']] = 
$GLOBALS['phpgw']->common->display_fullname($lid,$fname,$lname);
+                       
+                       if(count($employees_list))
+                               {
+                                       asort($employees_list);
+                                       reset($employees_list);
+                               }
+               }
+               
+               while (list($account_id,$account_name) = each($employees_list))
+               {
+                       $selected = '';
+                       if ($account_id == $ticket['assignedto'])
                        {
-                               $tag = 'selected';
+                               $selected = 'selected';
                        }
-                       $GLOBALS['phpgw']->template->set_var('optionname', 
$entry['account_lid']);
-                       $GLOBALS['phpgw']->template->set_var('optionvalue', 
$entry['account_id']);
-                       $GLOBALS['phpgw']->template->set_var('optionselected', 
$tag);
+                       $GLOBALS['phpgw']->template->set_var('optionname', 
$account_name);
+                       $GLOBALS['phpgw']->template->set_var('optionvalue', 
$account_id);
+                       $GLOBALS['phpgw']->template->set_var('optionselected', 
$selected);
                        
$GLOBALS['phpgw']->template->parse('options_assignedto','options_select',True);
                }
+               
 
                // Figure out when it was opened and last closed
                $history_array = 
$GLOBALS['phpgw']->historylog->return_array(array(),array('X','O'),'','',$ticket_id);




reply via email to

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