fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [8331] property: notifier


From: Sigurd Nes
Subject: [Fmsystem-commits] [8331] property: notifier
Date: Thu, 15 Dec 2011 14:13:05 +0000

Revision: 8331
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=8331
Author:   sigurdne
Date:     2011-12-15 14:13:04 +0000 (Thu, 15 Dec 2011)
Log Message:
-----------
property: notifier

Modified Paths:
--------------
    trunk/property/inc/class.boproject.inc.php
    trunk/property/inc/class.notify.inc.php
    trunk/property/inc/class.uilookup.inc.php
    trunk/property/inc/class.uiproject.inc.php
    trunk/property/js/yahoo/lookup.vendor.index.js
    trunk/property/js/yahoo/notify.js
    trunk/property/setup/phpgw_no.lang
    trunk/property/templates/base/project.xsl

Modified: trunk/property/inc/class.boproject.inc.php
===================================================================
--- trunk/property/inc/class.boproject.inc.php  2011-12-15 13:47:16 UTC (rev 
8330)
+++ trunk/property/inc/class.boproject.inc.php  2011-12-15 14:13:04 UTC (rev 
8331)
@@ -675,6 +675,9 @@
                                case 'ON':
                                        $type = lang('Owner notified');
                                        break;
+                               case 'MS':
+                                       $type = lang('Sent by sms');
+                                       break;
                                default:
                                        break;
                                }

Modified: trunk/property/inc/class.notify.inc.php
===================================================================
--- trunk/property/inc/class.notify.inc.php     2011-12-15 13:47:16 UTC (rev 
8330)
+++ trunk/property/inc/class.notify.inc.php     2011-12-15 14:13:04 UTC (rev 
8331)
@@ -99,7 +99,7 @@
                                        'location_id'                   => 
$location_id,
                                        'location_item_id'              => 
$location_item_id,
                                        'contact_id'                    => 
$this->_db->f('contact_id'),
-                                       'is_active'                             
=> $this->_db->f('is_active') ? $lang_yes : $lang_no,
+                                       'is_active'                             
=> $this->_db->f('is_active'),
                                        'notification_method'   => 
$this->_db->f('notification_method',true),
                                        'user_id'                               
=> $this->_db->f('user_id'),
                                        'entry_date'                    => 
$GLOBALS['phpgw']->common->show_date($this->_db->f('entry_date'),$dateformat),
@@ -112,7 +112,8 @@
                        {
                                $comms = 
execMethod('addressbook.boaddressbook.get_comm_contact_data',$entry['contact_id']);
                                $entry['email'] = 
$comms[$entry['contact_id']]['work email'];
-                               $entry['sms'] = 
$comms[$entry['contact_id']]['mobile (cell) phone'];                            
+                               $entry['sms'] = 
$comms[$entry['contact_id']]['mobile (cell) phone'];
+                               $entry['is_active_text'] = $entry['is_active'] 
? $lang_yes : $lang_no;
                        }
 //_debug_array($values);
                        return $values;
@@ -163,7 +164,7 @@
                                                                                
                        array('key' => 
'email','label'=>lang('email'),'sortable'=>false,'resizeable'=>true),
                                                                                
                        array('key' => 
'sms','label'=>'SMS','sortable'=>false,'resizeable'=>true),
                                                                                
                        array('key' => 
'notification_method','label'=>lang('method'),'sortable'=>true,'resizeable'=>true),
-                                                                               
                        array('key' => 
'is_active','label'=>lang('active'),'sortable'=>true,'resizeable'=>true),
+                                                                               
                        array('key' => 
'is_active_text','label'=>lang('active'),'sortable'=>true,'resizeable'=>true),
                                                                                
                        array('key' => 
'entry_date','label'=>lang('entry_date'),'sortable'=>true,'resizeable'=>true),
                                                                                
                        array('key' => 'select','label'=> lang('select'), 
'sortable'=>false,'resizeable'=>false,'formatter'=>'myFormatterCheck_notify','width'=>30)
                                                                                
                        ))

Modified: trunk/property/inc/class.uilookup.inc.php
===================================================================
--- trunk/property/inc/class.uilookup.inc.php   2011-12-15 13:47:16 UTC (rev 
8330)
+++ trunk/property/inc/class.uilookup.inc.php   2011-12-15 14:13:04 UTC (rev 
8331)
@@ -200,7 +200,7 @@
                                                                        'name' 
=> 'search',
                                                                        'value' 
   => lang('search'),
                                                                        'type' 
=> 'button',
-                                                                       
'tab_index' => 3
+                                                                       
'tab_index' => 2
                                                                ),
                                                                array
                                                                ( // TEXT IMPUT
@@ -210,8 +210,15 @@
                                                                        'type' 
=> 'text',
                                                                        'size'  
  => 28,
                                                                        
'onkeypress' => 'return pulsar(event)',
-                                                                       
'tab_index' => 2
-                                                               )
+                                                                       
'tab_index' => 3
+                                                               ),
+                                       /*                      array
+                                                               (
+                                                                       'type'  
=> 'button',
+                                                                       'id'    
=> 'btn_new',
+                                                                       'value' 
=> lang('add'),
+                                                                       
'tab_index' => 4
+                                                               ),*/
                                                        ),
                                                        'hidden_value' => array
                                                        (
@@ -272,6 +279,16 @@
                                $datatable['headers']['header'][$i]['sortable'] 
                = $uicols['sortable'][$i];
                                
$datatable['headers']['header'][$i]['sort_field']       = 
$uicols['sort_field'][$i];
                        }
+                       $datatable['rowactions']['action'][] = array
+                               (
+                                       'my_name'               => 'add',
+                                       'text'                  => lang('add'),
+                                       'action'                => 
$GLOBALS['phpgw']->link('/index.php',array
+                                       (
+                                               'menuaction'    => 
'addressbook.uiaddressbook.edit_person',
+                                               'noframe'               => true
+                                       ))
+                               );
 
                        if($column)
                        {

Modified: trunk/property/inc/class.uiproject.inc.php
===================================================================
--- trunk/property/inc/class.uiproject.inc.php  2011-12-15 13:47:16 UTC (rev 
8330)
+++ trunk/property/inc/class.uiproject.inc.php  2011-12-15 14:13:04 UTC (rev 
8331)
@@ -928,7 +928,7 @@
 
                function edit()
                {
-                       $id = phpgw::get_var('id', 'int');
+                       $id = (int)phpgw::get_var('id', 'int');
 
                        if(!$this->acl_add && !$this->acl_edit)
                        {
@@ -945,6 +945,8 @@
                        $values['contact_id']           = 
phpgw::get_var('contact', 'int', 'POST');
                        $auto_create                            = false;
 
+                       $location_id    = 
$GLOBALS['phpgw']->locations->get_id('property', $this->acl_location);
+
                        $datatable = array();
 
                        /*$datatable['config']['base_java_url'] = 
"menuaction:'property.uiproject.edit',"
@@ -1229,6 +1231,8 @@
                                                        }
                                                }
 
+                                               $toarray = array();
+                                               $toarray_sms = array();
                                                if 
(isset($receipt['notice_owner']) && is_array($receipt['notice_owner']) )
                                                {
                                                        
if($this->account!=$values['coordinator']
@@ -1237,36 +1241,71 @@
                                                        )
                                                        {
                                                                
$prefs_coordinator = 
$this->bocommon->create_preferences('property',$values['coordinator']);
-                                                               $to = 
$prefs_coordinator['email'];
+                                                               $to[] = 
$prefs_coordinator['email'];
+                                                       }
+                                               }
+                                               
+                                               $notify_list = 
execMethod('property.notify.read', array
+                                                               (
+                                                                       
'location_id'           => $location_id,
+                                                                       
'location_item_id'      => $id
+                                                               )
+                                                       );
+                                               
+                                               $subject=lang('project %1 has 
been edited',$id);
+                                               $sms_text = "{$subject}. 
\r\n{$GLOBALS['phpgw_info']['user']['fullname']} 
\r\n{$GLOBALS['phpgw_info']['user']['preferences']['property']['email']}";
+                                               $sms    = 
CreateObject('sms.sms');
 
-                                                               
$from_name=$GLOBALS['phpgw_info']['user']['fullname'];
-                                                               
$from_email=$GLOBALS['phpgw_info']['user']['preferences']['property']['email'];
+                                               foreach($notify_list as $entry)
+                                               {
+                                                       if($entry['is_active'] 
&& $entry['notification_method'] == 'email' && $entry['email'])
+                                                       {
+                                                               $toarray[] = 
"{$entry['first_name']} {$entry['last_name']}<{$entry['email']}>";
+                                                       }
+                                                       else 
if($entry['is_active'] && $entry['notification_method'] == 'sms' && 
$entry['sms'])
+                                                       {
+                                                               
$sms->websend2pv($this->account,$entry['sms'],$sms_text);
+                                                               $toarray_sms[] 
= "{$entry['first_name']} {$entry['last_name']}({$entry['sms']})";
+                                                               
$receipt['message'][]=array('msg'=>lang('%1 is 
notified',"{$entry['first_name']} {$entry['last_name']}"));
+                                                       }
+                                               }
+                                               unset($entry);
 
-                                                               $body = '<a 
href ="http://' . $GLOBALS['phpgw_info']['server']['hostname'] . 
$GLOBALS['phpgw']->link('/index.php',array('menuaction'=> 
'property.uiproject.edit', 'id'=> $id)).'">' . lang('project %1 has been 
edited',$id) .'</a>' . "\n";
-                                                               
foreach($receipt['notice_owner'] as $notice)
-                                                               {
-                                                                       $body 
.= $notice . "\n";
-                                                               }
+                                               if($toarray_sms)
+                                               {
+                                                       
$historylog->add('MS',$id,implode(',',$toarray_sms));                           
                
+                                               }
+                                               
+                                               if ($toarray)
+                                               {
+                                                       $to = 
implode(';',$toarray);
+                                                       
$from_name=$GLOBALS['phpgw_info']['user']['fullname'];
+                                                       
$from_email=$GLOBALS['phpgw_info']['user']['preferences']['property']['email'];
 
-                                                               $body .= 
lang('Altered by') . ': ' . $from_name . "\n";
-                                                               $body .= 
lang('remark') . ': ' . $values['remark'] . "\n";
+                                                       $body = '<a href 
="http://' . $GLOBALS['phpgw_info']['server']['hostname'] . 
$GLOBALS['phpgw']->link('/index.php',array('menuaction'=> 
'property.uiproject.edit', 'id'=> $id)).'">' . lang('project %1 has been 
edited',$id) .'</a>' . "\n";
+                                                       
foreach($receipt['notice_owner'] as $notice)
+                                                       {
+                                                               $body .= 
$notice . "\n";
+                                                       }
 
-                                                               $body = 
nl2br($body);
+                                                       $body .= lang('Altered 
by') . ': ' . $from_name . "\n";
+                                                       $body .= lang('remark') 
. ': ' . $values['remark'] . "\n";
 
-                                                               $returncode = 
$GLOBALS['phpgw']->send->msg('email',$to,$subject=lang('project %1 has been 
edited',$id),$body, false,false,false, $from_email, $from_name, 'html');
+                                                       $body = nl2br($body);
 
-                                                               if 
(!$returncode)       // not nice, but better than failing silently
-                                                               {
-                                                                       
$receipt['error'][]=array('msg'=>"uiproject::edit: sending message to '$to' 
subject='$subject' failed !!!");
-                                                                       
$receipt['error'][]=array('msg'=> $GLOBALS['phpgw']->send->err['desc']);
-                                                                       
$bypass_error=true;
-                                                               }
-                                                               else
-                                                               {
-                                                                       
$historylog->add('ON', $id, lang('%1 is notified',$to));
-                                                                       
$receipt['message'][]=array('msg'=>lang('%1 is notified',$to));
-                                                               }
+                                                       $returncode = 
$GLOBALS['phpgw']->send->msg('email',$to,$subject,$body, false,false,false, 
$from_email, $from_name, 'html');
+
+                                                       if (!$returncode)       
// not nice, but better than failing silently
+                                                       {
+                                                               
$receipt['error'][]=array('msg'=>"uiproject::edit: sending message to '$to' 
subject='$subject' failed !!!");
+                                                               
$receipt['error'][]=array('msg'=> $GLOBALS['phpgw']->send->err['desc']);
+                                                               
$bypass_error=true;
                                                        }
+                                                       else
+                                                       {
+                                                               
$historylog->add('ON', $id, lang('%1 is notified',$to));
+                                                               
$receipt['message'][]=array('msg'=>lang('%1 is notified',$to));
+                                                       }
                                                }
                                        }
                                }
@@ -1656,8 +1695,7 @@
                        $content_notify = array();
 
                        $notify                         = 
CreateObject('property.notify');
-                       
-                       $location_id    = 
$GLOBALS['phpgw']->locations->get_id('property', $this->acl_location);
+
                        $notify_info = $notify->get_yui_table_def(array
                                                                (
                                                                        
'location_id'           => $location_id,
@@ -1693,7 +1731,7 @@
                                        'datatable'                             
                        => $datavalues,
                                        'myColumnDefs'                          
                => $myColumnDefs,
                                        'myButtons'                             
                        => $myButtons,
-                                       'tabs'                                  
                        => self::_generate_tabs($tabs,array('coordination' => 
$suppresscoordination)),
+                                       'tabs'                                  
                        => self::_generate_tabs($tabs),
                                        'msgbox_data'                           
                => $GLOBALS['phpgw']->common->msgbox($msgbox_data),
                                        'value_origin'                          
                => isset($values['origin']) ? $values['origin'] : '',
                                        'value_origin_type'                     
                => isset($origin)?$origin:'',

Modified: trunk/property/js/yahoo/lookup.vendor.index.js
===================================================================
--- trunk/property/js/yahoo/lookup.vendor.index.js      2011-12-15 13:47:16 UTC 
(rev 8330)
+++ trunk/property/js/yahoo/lookup.vendor.index.js      2011-12-15 14:13:04 UTC 
(rev 8331)
@@ -5,7 +5,7 @@
        {
        }
 
-       var toolTips = [{}]
+       var toolTips = new Array();
 
        //define SelectButton
        var oMenuButton_0;
@@ -14,9 +14,10 @@
        ]
 
        // define buttons
-       var oNormalButton_0;
+       var oNormalButton_0,oNormalButton_1;
        var normalButtons = [
-       {order:0, name:'btn_search', funct:"onSearchClick"}
+       {order:0, name:'btn_search', funct:"onSearchClick"},
+       {order:1, name:'btn_new', funct:"onNewClick"}
        ]
 
        // define Text buttons

Modified: trunk/property/js/yahoo/notify.js
===================================================================
--- trunk/property/js/yahoo/notify.js   2011-12-15 13:47:16 UTC (rev 8330)
+++ trunk/property/js/yahoo/notify.js   2011-12-15 14:13:04 UTC (rev 8331)
@@ -2,7 +2,6 @@
 var notify_contact = 0;
 
 var Button_0_0, Button_0_1, Button_0_2;
-//var tableYUI;
 
 
/********************************************************************************/
        this.cleanValuesHiddenActionsButtons=function()
@@ -18,7 +17,7 @@
 /* This one is added dynamically from php-class 
property_notify::get_yui_table_def()
        YAHOO.widget.DataTable.formatLink_notify = function(elCell, oRecord, 
oColumn, oData)
        {
-               elCell.innerHTML = "<a 
href="+datatable[0][0]["edit_action"]+"&ab_id="+oData+">" + oData + "</a>";
+
        };
 */
 
@@ -68,6 +67,11 @@
 
        this.notify_contact_lookup = function()
        {
+               if(!base_java_url['location_item_id'])
+               {
+                       alert('Posten må lagres før kontakter kan tilordnes');
+                       return;
+               }       
                var oArgs = 
{menuaction:'property.uilookup.addressbook',column:'notify_contact'};
                var strURL = phpGWLink('index.php', oArgs);
                
Window1=window.open(strURL,"Search","left=50,top=100,width=800,height=700,toolbar=no,scrollbars=yes,resizable=yes");
@@ -76,17 +80,6 @@
 /* This one is added dynamically from php-class 
property_notify::get_yui_table_def()
        this.refresh_notify_contact=function()
        {
-               if(document.getElementById('notify_contact').value)
-               {
-                       base_java_url['contact_id'] = 
document.getElementById('notify_contact').value;
-               }
-
-               if(document.getElementById('notify_contact').value != 
notify_contact)
-               {
-                       base_java_url['action'] = 'refresh_notify_contact';
-                       execute_async(myDataTable_3);
-                       notify_contact = 
document.getElementById('notify_contact').value;
-               }
        }
 */
        this.onDOMAttrModified = function(e)

Modified: trunk/property/setup/phpgw_no.lang
===================================================================
--- trunk/property/setup/phpgw_no.lang  2011-12-15 13:47:16 UTC (rev 8330)
+++ trunk/property/setup/phpgw_no.lang  2011-12-15 14:13:04 UTC (rev 8331)
@@ -363,6 +363,7 @@
 planning value property        no      Beløp planlagt disponering
 planning serie property        no      Planlagt disponering
 check to delete        property        no      Merk for å slette
+check all      common  no      Merk alle
 contact        property        no      Kontakt
 contact email  property        no      Epost
 contact phone  property        no      kontakt telefon

Modified: trunk/property/templates/base/project.xsl
===================================================================
--- trunk/property/templates/base/project.xsl   2011-12-15 13:47:16 UTC (rev 
8330)
+++ trunk/property/templates/base/project.xsl   2011-12-15 14:13:04 UTC (rev 
8331)
@@ -95,11 +95,9 @@
                        <xsl:variable name="add_action"><xsl:value-of 
select="add_action"/></xsl:variable>
                        <xsl:variable name="lang_add"><xsl:value-of 
select="lang_add"/></xsl:variable>
                        <form method="post" action="{$add_action}">
-                               <input type="submit" name="add" 
value="{$lang_add}" onMouseout="window.status='';return true;">
-                                       <xsl:attribute name="onMouseover">
-                                               
<xsl:text>window.status='</xsl:text>
+                               <input type="submit" name="add" 
value="{$lang_add}">
+                                       <xsl:attribute name="title">
                                                <xsl:value-of 
select="lang_add_statustext"/>
-                                               <xsl:text>'; return 
true;</xsl:text>
                                        </xsl:attribute>
                                </input>
                        </form>
@@ -115,7 +113,7 @@
                        <xsl:value-of select="lookup_functions"/>
                        function add_workorder()
                        {
-                       document.add_workorder_form.submit();
+                               document.add_workorder_form.submit();
                        }
                </script>
 
@@ -130,7 +128,7 @@
                                </xsl:when>
                        </xsl:choose>
                        <xsl:choose>
-                               <xsl:when test="value_project_id!=''">
+                               <xsl:when test="value_project_id > 0">
                                        <td valign="top">
                                                <xsl:variable 
name="lang_add_workorder"><xsl:value-of 
select="lang_add_workorder"/></xsl:variable>
                                                <input type="button" 
name="add_workorder" value="{$lang_add_workorder}" onClick="add_workorder()">
@@ -150,7 +148,7 @@
                                        <div id="general">
                                                <table cellpadding="2" 
cellspacing="2" width="80%" align="center">
                                                        <xsl:choose>
-                                                               <xsl:when 
test="value_project_id!=''">
+                                                               <xsl:when 
test="value_project_id > 0">
                                                                        <tr>
                                                                                
<td title="{lang_copy_project_statustext}">
                                                                                
        <xsl:value-of select="lang_copy_project"/>
@@ -194,7 +192,6 @@
                                                                                
                                        <td class="th_text"  align="left" >
                                                                                
                                                <a href="{link}"  
title="{statustext}"><xsl:value-of select="id"/></a>
                                                                                
                                                <xsl:text> </xsl:text>
-
                                                                                
                                                <xsl:choose>
                                                                                
                                                        <xsl:when 
test="$origin_location ='.project.request'">
                                                                                
                                                                <input 
type="checkbox" name="values[delete_request][]" value="{id}"  
onMouseout="window.status='';return true;">
@@ -242,11 +239,9 @@
                                                                <td>
                                                                        <input 
type="hidden" name="values[origin]" value="{value_origin_type}"></input>
                                                                        <input 
type="hidden" name="values[origin_id]" value="{value_origin_id}"></input>
-                                                                       <input 
type="text" name="values[name]" value="{value_name}" 
onMouseout="window.status='';return true;">
-                                                                               
<xsl:attribute name="onMouseover">
-                                                                               
        <xsl:text>window.status='</xsl:text>
+                                                                       <input 
type="text" name="values[name]" value="{value_name}">
+                                                                               
<xsl:attribute name="title">
                                                                                
        <xsl:value-of select="lang_name_statustext"/>
-                                                                               
        <xsl:text>'; return true;</xsl:text>
                                                                                
</xsl:attribute>
                                                                        </input>
                                                                </td>
@@ -256,11 +251,9 @@
                                                                        
<xsl:value-of select="lang_descr"/>
                                                                </td>
                                                                <td>
-                                                                       
<textarea cols="60" rows="6" name="values[descr]" 
onMouseout="window.status='';return true;">
-                                                                               
<xsl:attribute name="onMouseover">
-                                                                               
        <xsl:text>window.status='</xsl:text>
+                                                                       
<textarea cols="60" rows="6" name="values[descr]">
+                                                                               
<xsl:attribute name="title">
                                                                                
        <xsl:value-of select="lang_descr_statustext"/>
-                                                                               
        <xsl:text>'; return true;</xsl:text>
                                                                                
</xsl:attribute>
                                                                                
<xsl:value-of select="value_descr"/>
                                                                        
</textarea>
@@ -292,7 +285,7 @@
                                                                </td>
                                                        </tr>
                                                        <xsl:choose>
-                                                               <xsl:when 
test="value_project_id!=''">
+                                                               <xsl:when 
test="value_project_id > 0">
                                                                        <tr>
                                                                                
<td>
                                                                                
        <xsl:value-of select="lang_confirm_status"/>
@@ -309,23 +302,6 @@
                                                                        </tr>
                                                                </xsl:when>
                                                        </xsl:choose>
-                                                       <!-- script>
-               var property_js = <xsl:value-of select="property_js" />
-               var datatable = new Array();
-
-               <xsl:for-each select="datatable">
-                       datatable[<xsl:value-of select="name"/>] = [
-                       {
-                               values                  :       <xsl:value-of 
select="values"/>,
-                               total_records   :       <xsl:value-of 
select="total_records"/>,
-                               is_paginator    :       <xsl:value-of 
select="is_paginator"/>,
-                               edit_action             :       <xsl:value-of 
select="edit_action"/>,
-                               footer                  :       <xsl:value-of 
select="footer"/>
-                       }
-                       ]
-               <xsl:value-of select="phpgw:conditional(not(position() = 
last()), ',', '')"/>
-               </xsl:for-each>
-       </script-->
                <xsl:choose>
                        <xsl:when test="need_approval='1'">
                                <tr>
@@ -362,11 +338,9 @@
                                <xsl:value-of select="lang_remark"/>
                        </td>
                        <td>
-                               <textarea cols="60" rows="6" 
name="values[remark]" onMouseout="window.status='';return true;">
-                                       <xsl:attribute name="onMouseover">
-                                               
<xsl:text>window.status='</xsl:text>
+                               <textarea cols="60" rows="6" 
name="values[remark]">
+                                       <xsl:attribute name="title">
                                                <xsl:value-of 
select="lang_remark_statustext"/>
-                                               <xsl:text>'; return 
true;</xsl:text>
                                        </xsl:attribute>
                                        <xsl:value-of select="value_remark"/>
                                </textarea>
@@ -416,11 +390,9 @@
                                <xsl:value-of select="lang_start_date"/>
                        </td>
                        <td>
-                               <input type="text" id="values_start_date" 
name="values[start_date]" size="10" value="{value_start_date}" 
readonly="readonly" onMouseout="window.status='';return true;" >
-                                       <xsl:attribute name="onMouseover">
-                                               
<xsl:text>window.status='</xsl:text>
+                               <input type="text" id="values_start_date" 
name="values[start_date]" size="10" value="{value_start_date}" 
readonly="readonly">
+                                       <xsl:attribute name="title">
                                                <xsl:value-of 
select="lang_start_date_statustext"/>
-                                               <xsl:text>'; return 
true;</xsl:text>
                                        </xsl:attribute>
                                </input>
                                <img id="values_start_date-trigger" 
src="{img_cal}" alt="{lang_datetitle}" title="{lang_datetitle}" 
style="cursor:pointer; cursor:hand;" />
@@ -431,11 +403,9 @@
                                <xsl:value-of select="lang_end_date"/>
                        </td>
                        <td>
-                               <input type="text" id="values_end_date" 
name="values[end_date]" size="10" value="{value_end_date}" readonly="readonly" 
onMouseout="window.status='';return true;" >
-                                       <xsl:attribute name="onMouseover">
-                                               
<xsl:text>window.status='</xsl:text>
+                               <input type="text" id="values_end_date" 
name="values[end_date]" size="10" value="{value_end_date}" readonly="readonly">
+                                       <xsl:attribute name="title">
                                                <xsl:value-of 
select="lang_end_date_statustext"/>
-                                               <xsl:text>'; return 
true;</xsl:text>
                                        </xsl:attribute>
                                </input>
                                <img id="values_end_date-trigger" 
src="{img_cal}" alt="{lang_datetitle}" title="{lang_datetitle}" 
style="cursor:pointer; cursor:hand;" />
@@ -461,11 +431,9 @@
                                <xsl:value-of select="lang_budget"/>
                        </td>
                        <td>
-                               <input type="text" name="values[budget]" 
value="{value_budget}" onMouseout="window.status='';return true;">
-                                       <xsl:attribute name="onMouseover">
-                                               
<xsl:text>window.status='</xsl:text>
+                               <input type="text" name="values[budget]" 
value="{value_budget}">
+                                       <xsl:attribute name="title">
                                                <xsl:value-of 
select="lang_budget_statustext"/>
-                                               <xsl:text>'; return 
true;</xsl:text>
                                        </xsl:attribute>
                                </input>
                                <xsl:text> </xsl:text> [ <xsl:value-of 
select="currency"/> ]
@@ -476,11 +444,9 @@
                                <xsl:value-of select="lang_reserve"/>
                        </td>
                        <td>
-                               <input type="text" name="values[reserve]" 
value="{value_reserve}" onMouseout="window.status='';return true;">
-                                       <xsl:attribute name="onMouseover">
-                                               
<xsl:text>window.status='</xsl:text>
+                               <input type="text" name="values[reserve]" 
value="{value_reserve}">
+                                       <xsl:attribute name="title">
                                                <xsl:value-of 
select="lang_reserve_statustext"/>
-                                               <xsl:text>'; return 
true;</xsl:text>
                                        </xsl:attribute>
                                </input>
                                <xsl:text> </xsl:text> [ <xsl:value-of 
select="currency"/> ]
@@ -593,14 +559,8 @@
                                                        myButtons[<xsl:value-of 
select="name"/>] = <xsl:value-of select="values"/>
                                                </xsl:for-each>
                                        </script>
-</div>
-
-<xsl:choose>
-       <xsl:when test="suppresscoordination =''">
-
+               </div>
                <div id="coordination">
-               <script type="text/javascript">
-               </script>
                <xsl:variable name="lang_contact_statustext"><xsl:value-of 
select="php:function('lang', 'click this link to select')" /></xsl:variable>
                        <table cellpadding="2" cellspacing="2" width="80%" 
align="center">
                                <tr>
@@ -622,79 +582,74 @@
                                        <td >
                                                <div id="paging_3"> </div>
                                                <div 
id="datatable-container_3"></div>
+                                               <div 
id="datatable-buttons_3"></div>
                                        </td>
                                </tr>
+                               <xsl:choose>
+                                       <xsl:when test="suppresscoordination 
=''">
                                                <tr>
-                                                       <td class="center" 
align="center" colspan="10">
-                                                               <div 
id="datatable-buttons_3"></div>
+                                                       <td valign="top">
+                                                               <xsl:value-of 
select="lang_branch"/>
                                                        </td>
+                                                       <td>
+                                                               <xsl:variable 
name="lang_branch_statustext"><xsl:value-of 
select="lang_branch_statustext"/></xsl:variable>
+                                                               <select 
name="values[branch][]" class="forms" multiple="multiple" 
title="{$lang_branch_statustext}">
+                                                                       
<xsl:apply-templates select="branch_list"/>
+                                                               </select>
+                                                       </td>
                                                </tr>
-                               <tr>
-                                       <td valign="top">
-                                               <xsl:value-of 
select="lang_branch"/>
-                                       </td>
-                                       <td>
-                                               <xsl:variable 
name="lang_branch_statustext"><xsl:value-of 
select="lang_branch_statustext"/></xsl:variable>
-                                               <select name="values[branch][]" 
class="forms" multiple="multiple" 
onMouseover="window.status='{$lang_branch_statustext}'; return true;" 
onMouseout="window.status='';return true;">
-                                                       <xsl:apply-templates 
select="branch_list"/>
-                                               </select>
-                                       </td>
-                               </tr>
-                               <tr>
-                                       <td valign="top">
-                                               <xsl:value-of 
select="lang_other_branch"/>
-                                       </td>
-                                       <td>
-                                               <input type="text" 
name="values[other_branch]" value="{value_other_branch}" 
onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_other_branch_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </td>
-                               </tr>
-                               <tr>
-                                       <td>
-                                               <xsl:value-of 
select="lang_key_fetch"/>
-                                       </td>
-                                       <td>
-                                               <xsl:variable 
name="lang_key_fetch_statustext"><xsl:value-of 
select="lang_key_fetch_statustext"/></xsl:variable>
-                                               <select 
name="values[key_fetch]" class="forms" 
onMouseover="window.status='{$lang_key_fetch_statustext}'; return true;" 
onMouseout="window.status='';return true;">
-                                                       <option 
value=""><xsl:value-of select="lang_no_key_fetch"/></option>
-                                                       <xsl:apply-templates 
select="key_fetch_list"/>
-                                               </select>
-                                       </td>
-                               </tr>
-                               <tr>
-                                       <td>
-                                               <xsl:value-of 
select="lang_key_deliver"/>
-                                       </td>
-                                       <td>
-                                               <xsl:variable 
name="lang_key_deliver_statustext"><xsl:value-of 
select="lang_key_deliver_statustext"/></xsl:variable>
-                                               <select 
name="values[key_deliver]" class="forms" 
onMouseover="window.status='{$lang_key_deliver_statustext}'; return true;" 
onMouseout="window.status='';return true;">
-                                                       <option 
value=""><xsl:value-of select="lang_no_key_deliver"/></option>
-                                                       <xsl:apply-templates 
select="key_deliver_list"/>
-                                               </select>
-                                       </td>
-                               </tr>
-                               <tr>
-                                       <td>
-                                               <xsl:value-of 
select="lang_key_responsible"/>
-                                       </td>
-                                       <td>
-                                               <xsl:variable 
name="lang_key_responsible_statustext"><xsl:value-of 
select="lang_key_responsible_statustext"/></xsl:variable>
-                                               <select 
name="values[key_responsible]" class="forms" 
onMouseover="window.status='{$lang_key_responsible_statustext}'; return true;" 
onMouseout="window.status='';return true;">
-                                                       <option 
value=""><xsl:value-of select="lang_no_key_responsible"/></option>
-                                                       <xsl:apply-templates 
select="key_responsible_list"/>
-                                               </select>
-                                       </td>
-                               </tr>
+                                               <tr>
+                                                       <td valign="top">
+                                                               <xsl:value-of 
select="lang_other_branch"/>
+                                                       </td>
+                                                       <td>
+                                                               <input 
type="text" name="values[other_branch]" value="{value_other_branch}">
+                                                                       
<xsl:attribute name="title">
+                                                                               
<xsl:value-of select="lang_other_branch_statustext"/>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td>
+                                                               <xsl:value-of 
select="lang_key_fetch"/>
+                                                       </td>
+                                                       <td>
+                                                               <xsl:variable 
name="lang_key_fetch_statustext"><xsl:value-of 
select="lang_key_fetch_statustext"/></xsl:variable>
+                                                               <select 
name="values[key_fetch]" class="forms" title="{$lang_key_fetch_statustext}">
+                                                                       <option 
value=""><xsl:value-of select="lang_no_key_fetch"/></option>
+                                                                       
<xsl:apply-templates select="key_fetch_list"/>
+                                                               </select>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td>
+                                                               <xsl:value-of 
select="lang_key_deliver"/>
+                                                       </td>
+                                                       <td>
+                                                               <xsl:variable 
name="lang_key_deliver_statustext"><xsl:value-of 
select="lang_key_deliver_statustext"/></xsl:variable>
+                                                               <select 
name="values[key_deliver]" class="forms" 
onMouseover="window.status='{$lang_key_deliver_statustext}'; return true;" 
onMouseout="window.status='';return true;">
+                                                                       <option 
value=""><xsl:value-of select="lang_no_key_deliver"/></option>
+                                                                               
<xsl:apply-templates select="key_deliver_list"/>
+                                                                       
</select>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td>
+                                                               <xsl:value-of 
select="lang_key_responsible"/>
+                                                       </td>
+                                                       <td>
+                                                               <xsl:variable 
name="lang_key_responsible_statustext"><xsl:value-of 
select="lang_key_responsible_statustext"/></xsl:variable>
+                                                               <select 
name="values[key_responsible]" class="forms" 
onMouseover="window.status='{$lang_key_responsible_statustext}'; return true;" 
onMouseout="window.status='';return true;">
+                                                                       <option 
value=""><xsl:value-of select="lang_no_key_responsible"/></option>
+                                                                       
<xsl:apply-templates select="key_responsible_list"/>
+                                                               </select>
+                                                       </td>
+                                               </tr>
+                                       </xsl:when>
+                               </xsl:choose>
                        </table>
                </div>
-       </xsl:when>
-</xsl:choose>
-
 <div id="history">
        <!-- <hr noshade="noshade" width="100%" align="center" size="1"/>
                table cellpadding="2" cellspacing="2" width="80%" 
align="center">




reply via email to

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