phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] property incclass.uiwo_hour.inc.php setup/phpgw...


From: Sigurd Nes
Subject: [Phpgroupware-cvs] property incclass.uiwo_hour.inc.php setup/phpgw...
Date: Tue, 20 Jun 2006 10:54:17 +0000

CVSROOT:        /sources/phpgroupware
Module name:    property
Changes by:     Sigurd Nes <sigurdne>   06/06/20 10:54:17

Modified files:
        inc            : class.uiwo_hour.inc.php 
        setup          : phpgw_en.lang phpgw_no.lang 
        templates/base : config.tpl wo_hour.xsl 

Log message:
        workorder status by sms

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.uiwo_hour.inc.php?cvsroot=phpgroupware&r1=1.23&r2=1.24
http://cvs.savannah.gnu.org/viewcvs/property/setup/phpgw_en.lang?cvsroot=phpgroupware&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/property/setup/phpgw_no.lang?cvsroot=phpgroupware&r1=1.9&r2=1.10
http://cvs.savannah.gnu.org/viewcvs/property/templates/base/config.tpl?cvsroot=phpgroupware&r1=1.4&r2=1.5
http://cvs.savannah.gnu.org/viewcvs/property/templates/base/wo_hour.xsl?cvsroot=phpgroupware&r1=1.6&r2=1.7

Patches:
Index: inc/class.uiwo_hour.inc.php
===================================================================
RCS file: /sources/phpgroupware/property/inc/class.uiwo_hour.inc.php,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -b -r1.23 -r1.24
--- inc/class.uiwo_hour.inc.php 17 Jun 2006 08:45:56 -0000      1.23
+++ inc/class.uiwo_hour.inc.php 20 Jun 2006 10:54:17 -0000      1.24
@@ -8,7 +8,7 @@
        * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
        * @package property
        * @subpackage project
-       * @version $Id: class.uiwo_hour.inc.php,v 1.23 2006/06/17 08:45:56 
sigurdne Exp $
+       * @version $Id: class.uiwo_hour.inc.php,v 1.24 2006/06/20 10:54:17 
sigurdne Exp $
        */
 
        /**
@@ -684,6 +684,22 @@
                        $from_name      =       
$GLOBALS['phpgw_info']['user']['fullname'];
                        $from_email     =       
$GLOBALS['phpgw_info']['user']['preferences'][$this->currentapp]['email'];
 
+                       if($this->config->config_data['wo_status_sms'])
+                       {               
+                               $config_sms     = CreateObject('sms.soconfig');
+                               if(is_object($config_sms))
+                               {
+                                       $config_sms->read_repository();
+                                       $sms_data['heading'] = lang('Send the 
following SMS-message to %1 to update status for this 
order:',$config_sms->config_data['common']['gateway_number']);
+                                       $sms_data['message'] = 'status ' . 
$workorder_id . ' [' . lang('status code') .']';
+                                       $sms_data['status_code'][0]['name'] = 
'1 => ' . lang('closed');
+                                       $sms_data['status_code'][1]['name'] = 
'2 => ' . lang('No access');
+                                       $sms_data['status_code_text'] = 
lang('status code');
+                       //              _debug_array($sms_data);
+                       
+                               }
+                       }
+                       
                        $email_data = array
                        (
                                'location_data'                                 
=>      $location_data,
@@ -719,7 +735,7 @@
                                'budget_account'                                
=>      $workorder['b_account_id'],
 
                                'lang_sum_calculation'                  =>      
lang('Sum of calculation'),
-                               'sum_calculation'                               
=>      $common_data['table_sum'][0]['value_total_sum'],
+                               'sum_calculation'                               
=>$common_data['table_sum'][0]['value_total_sum'],
 
                                'lang_contact_phone'                    => 
lang('Contact phone'),
                                'contact_phone'                                 
=> $project['contact_phone'],
@@ -746,7 +762,8 @@
                                'lang_work'                                     
        =>      lang('work:____________'),
 
                                'table_header_view_order'               => 
$table_header,
-                               'values_view_order'                             
=> $values_hour
+                               'values_view_order'                             
=> $values_hour,
+                               'sms_data'                                      
=> $sms_data
                        );
 
 

Index: setup/phpgw_en.lang
===================================================================
RCS file: /sources/phpgroupware/property/setup/phpgw_en.lang,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -b -r1.5 -r1.6
--- setup/phpgw_en.lang 14 Mar 2006 12:52:05 -0000      1.5
+++ setup/phpgw_en.lang 20 Jun 2006 10:54:17 -0000      1.6
@@ -928,6 +928,7 @@
 New values     property        en      New values
 Next run       property        en      Next run
 no     property        en      no
+No access      property        en      No access
 No account     property        en      No account
 No additional notes    property        en      No additional notes
 No branch      property        en      No branch
@@ -1365,6 +1366,7 @@
 select year    property        en      select year
 Send e-mail    property        en      Send e-mail
 Send Order     property        en      Send Order
+Send the following SMS-message to %1 to update status for this order:  
property        en      Send the following SMS-message to %1 to update status 
for this order:
 Send this order by email       property        en      Send this order by email
 Sendt by email to      property        en      Sendt by email to
 Serious        property        en      Serious
@@ -1410,6 +1412,7 @@
 status has been added  property        en      status has been added
 Status has been edited property        en      Status has been edited
 Status has NOT been saved      property        en      Status has NOT been 
saved
+status code    property        en      Status code
 status ID      property        en      status ID
 statustext     property        en      Statustext
 statustext not entered!        property        en      Statustext not entered!

Index: setup/phpgw_no.lang
===================================================================
RCS file: /sources/phpgroupware/property/setup/phpgw_no.lang,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- setup/phpgw_no.lang 5 Apr 2006 13:10:10 -0000       1.9
+++ setup/phpgw_no.lang 20 Jun 2006 10:54:17 -0000      1.10
@@ -898,6 +898,7 @@
 New values     property        no      Nye verdier
 Next run       property        no      Neste kjøring
 no     property        no      Nei
+No access      property        no      Ingen tilgang
 No account     property        no      Ingen konto
 No additional notes    property        no      Ingen tilleggskommentarer
 No branch      property        no      fag ikke valgt
@@ -1321,6 +1322,7 @@
 Send e-mail    property        no      Send epost
 Send Order     property        no      send ordre
 Sendt by email to      property        no      send med e-post til
+Send the following SMS-message to %1 to update status for this order:  
property        no      Send følgende SMS-melding til %1 for å oppdatere 
status for denne ordren:
 Send this order by email       property        no      send denne ordren med 
e-post
 Send Workorder property        no      Send ordre
 Serious        property        no      Kraftig
@@ -1363,6 +1365,7 @@
 start this entity      property        no      Start denne entiteten
 Start this entity from property        no      Start denne entiteten fra 
prosjekt
 Status property        no      Status
+status code    property        no      Statuskode
 Status changed property        no      Status er endret
 Status for the entity category property        no      Status for 
entitets-kategorien
 status has been added  property        no      Status er lagt til

Index: templates/base/config.tpl
===================================================================
RCS file: /sources/phpgroupware/property/templates/base/config.tpl,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -b -r1.4 -r1.5
--- templates/base/config.tpl   22 Sep 2005 13:47:43 -0000      1.4
+++ templates/base/config.tpl   20 Jun 2006 10:54:17 -0000      1.5
@@ -153,6 +153,15 @@
      <input name="newsettings[tenant_claim_notify_mails]" 
value="{value_tenant_claim_notify_mails}" size="40">
     </td>
    </tr>
+   <tr class="row_off">
+    <td>{lang_Receive_workorder_status_by_SMS}.</td>
+    <td>
+     <select name="newsettings[wo_status_sms]">
+      <option value="" {selected_wo_status_sms_}>NO</option>
+      <option value="1" {selected_wo_status_sms_1}>YES</option>
+     </select>
+    </td>
+   </tr>
 
 <!--
 groupnotification

Index: templates/base/wo_hour.xsl
===================================================================
RCS file: /sources/phpgroupware/property/templates/base/wo_hour.xsl,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- templates/base/wo_hour.xsl  10 Mar 2006 09:20:39 -0000      1.6
+++ templates/base/wo_hour.xsl  20 Jun 2006 10:54:17 -0000      1.7
@@ -1,4 +1,4 @@
-<!-- $Id: wo_hour.xsl,v 1.6 2006/03/10 09:20:39 sigurdne Exp $ -->
+<!-- $Id: wo_hour.xsl,v 1.7 2006/06/20 10:54:17 sigurdne Exp $ -->
 
        <xsl:template name="app_data">
                <xsl:choose>
@@ -648,6 +648,11 @@
                </xsl:choose>
                </table>
                </font>
+               <xsl:choose>
+                       <xsl:when test="sms_data!=''">          
+                               <xsl:apply-templates select="sms_data"/>
+                       </xsl:when>
+               </xsl:choose>
        </xsl:template>
 
        <xsl:template match="table_header_view_order">
@@ -2166,3 +2171,29 @@
                </xsl:choose>
        </xsl:template>
        
+       <xsl:template match="sms_data">
+               <tr>
+                       <td>
+                               <xsl:value-of select="heading"/>
+                       </td>
+               </tr>
+               <tr>
+                       <td class="th_text">
+                               <xsl:text>" </xsl:text>
+                               <xsl:value-of select="message"/>
+                               <xsl:text> "</xsl:text>
+                       </td>
+               </tr>
+               <tr>
+                       <td>
+                               <xsl:value-of select="status_code_text"/>
+                               <xsl:text>: </xsl:text>
+                               <xsl:for-each select="status_code" >
+                                       <xsl:value-of select="name"/>
+                                       <xsl:if test="position() != last()">, 
</xsl:if>
+                               </xsl:for-each>
+                       </td>
+               </tr>
+       </xsl:template>
+
+       




reply via email to

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