fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [14797] formatting


From: Sigurd Nes
Subject: [Fmsystem-commits] [14797] formatting
Date: Wed, 02 Mar 2016 11:28:58 +0000

Revision: 14797
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=14797
Author:   sigurdne
Date:     2016-03-02 11:28:56 +0000 (Wed, 02 Mar 2016)
Log Message:
-----------
formatting

Modified Paths:
--------------
    trunk/property/inc/class.uiwo_hour.inc.php
    trunk/property/templates/base/wo_hour.xsl

Modified: trunk/property/inc/class.uiwo_hour.inc.php
===================================================================
--- trunk/property/inc/class.uiwo_hour.inc.php  2016-03-02 09:05:42 UTC (rev 
14796)
+++ trunk/property/inc/class.uiwo_hour.inc.php  2016-03-02 11:28:56 UTC (rev 
14797)
@@ -1242,7 +1242,7 @@
                                (
                                'formatted_gab_id' => $formatted_gab_id,
                                'org_name' => 
isset($this->config->config_data['org_name']) ? 
"{$this->config->config_data['org_name']}::" : '',
-                               'location_data' => $location_data,
+                               'location_data_local' => $location_data,
                                'lang_workorder' => lang('Workorder ID'),
                                'workorder_id' => $workorder_id,
                                'lang_reminder' => $lang_reminder,

Modified: trunk/property/templates/base/wo_hour.xsl
===================================================================
--- trunk/property/templates/base/wo_hour.xsl   2016-03-02 09:05:42 UTC (rev 
14796)
+++ trunk/property/templates/base/wo_hour.xsl   2016-03-02 11:28:56 UTC (rev 
14797)
@@ -450,9 +450,6 @@
                        <hr noshade="noshade" width="100%" align="center" 
size="1"/>
                </div>
                <xsl:apply-templates select="email_data"/>
-               <div class="pure-control-group">
-                       <hr noshade="noshade" width="100%" align="center" 
size="1"/>
-               </div>
                <xsl:choose>
                        <xsl:when test="files!=''">
                                <div class="pure-control-group">
@@ -484,9 +481,6 @@
                                        </label>
                                </xsl:when>
                                <xsl:otherwise>
-                                       <label>
-                                               <xsl:value-of 
select="lang_history"/>
-                                       </label>
                                        <div>
                                                <xsl:for-each 
select="//datatable_def">
                                                        <xsl:if test="container 
= 'datatable-container_1'">
@@ -573,7 +567,7 @@
 </xsl:template>
 
 <!-- New template-->
-<xsl:template match="email_data">
+<!--xsl:template match="email_data">
 
        <div class="pure-control-group">
                <label>
@@ -838,8 +832,304 @@
                        </div>
                </xsl:when>
        </xsl:choose>
+</xsl:template-->
+
+<!-- New template-->
+<xsl:template match="email_data">
+       <font size="-1">
+               <table align="left">
+                       <tr>
+                               <td width="100%">
+                                       <table width="100%" cellpadding="2" 
cellspacing="2" align="left">
+                                               <tr>
+                                                       <td class="th_text" 
align="left">
+                                                               <xsl:value-of 
select="lang_date"/>
+                                                       </td>
+                                                       <td align="left" 
colspan="2">
+                                                               <xsl:value-of 
select="date"/>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td class="th_text" 
align="left">
+                                                               <xsl:value-of 
select="lang_workorder"/>
+                                                       </td>
+                                                       <td align="left" 
colspan="2">
+                                                               <xsl:value-of 
select="workorder_id"/>
+                                                               <xsl:choose>
+                                                                       
<xsl:when test="lang_reminder !=''">
+                                                                               
<xsl:text> - </xsl:text>
+                                                                               
<b>
+                                                                               
        <xsl:value-of select="lang_reminder"/>
+                                                                               
</b>
+                                                                       
</xsl:when>
+                                                               </xsl:choose>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td class="th_text" 
align="left">
+                                                               <xsl:value-of 
select="lang_to"/>
+                                                       </td>
+                                                       <td align="left" 
colspan="2">
+                                                               <xsl:value-of 
select="to_name"/>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td class="th_text" 
align="left" valign="top">
+                                                               <xsl:value-of 
select="lang_from"/>
+                                                       </td>
+                                                       <td align="left" 
colspan="2">
+                                                               <xsl:value-of 
select="from_name"/>
+                                                               <br/>
+                                                               <xsl:choose>
+                                                                       
<xsl:when test="ressursnr !=''">
+                                                                               
<xsl:text>RessursNr: </xsl:text>
+                                                                               
<xsl:value-of select="ressursnr"/>
+                                                                               
<br/>
+                                                                       
</xsl:when>
+                                                               </xsl:choose>
+                                                               <xsl:value-of 
select="org_name"/>
+                                                               <xsl:value-of 
select="lang_district"/>
+                                                               <xsl:text> 
</xsl:text>
+                                                               <xsl:value-of 
select="district"/>
+                                                               <br/>
+                                                               <xsl:text> [ 
</xsl:text>
+                                                               <xsl:value-of 
select="from_phone"/>
+                                                               <xsl:text> ] 
</xsl:text>
+                                                               <xsl:value-of 
select="from_email"/>
+                                                       </td>
+                                               </tr>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="contact_data/value_contact_name">
+                                                               
<xsl:call-template name="contact_form"/>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                               <xsl:call-template 
name="location_view_local"/>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="formatted_gab_id !=''">
+                                                               <tr>
+                                                                       <td 
class="th_text" align="left">
+                                                                               
Gnr/Bnr/Feste/Seksjon
+                                                                       </td>
+                                                                       <td 
align="left" colspan="2">
+                                                                               
<xsl:value-of select="formatted_gab_id"/>
+                                                                       </td>
+                                                               </tr>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="contact_phone !=''">
+                                                               <tr>
+                                                                       <td 
class="th_text" align="left">
+                                                                               
<xsl:value-of select="lang_contact_phone"/>
+                                                                       </td>
+                                                                       <td 
align="left" colspan="2">
+                                                                               
<xsl:value-of select="contact_phone"/>
+                                                                       </td>
+                                                               </tr>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                               <tr>
+                                                       <td class="th_text" 
align="left">
+                                                               <xsl:value-of 
select="lang_title"/>
+                                                       </td>
+                                                       <td align="left" 
colspan="2">
+                                                               <xsl:value-of 
select="title"/>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td class="th_text" 
align="left" valign="top">
+                                                               <xsl:value-of 
select="lang_descr"/>
+                                                       </td>
+                                                       <td align="left" 
colspan="2">
+                                                               <table 
border="1" width="100%" bordercolor="#000000" cellspacing="0" cellpadding="0">
+                                                                       <tr>
+                                                                               
<td width="100%">
+                                                                               
        <xsl:value-of select="descr"/>
+                                                                               
</td>
+                                                                       </tr>
+                                                               </table>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td class="th_text" 
align="left">
+                                                               <xsl:value-of 
select="lang_budget_account"/>
+                                                       </td>
+                                                       <td align="left">
+                                                               <xsl:value-of 
select="budget_account"/>
+                                                       </td>
+                                                       <td align="left">
+                                                               <xsl:value-of 
select="lang_cost_tax"/>
+                                                       </td>
+                                               </tr>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="sum_calculation!=''">
+                                                               <tr>
+                                                                       <td 
class="th_text" align="left">
+                                                                               
<xsl:value-of select="lang_sum_calculation"/>
+                                                                       </td>
+                                                                       <td 
align="left">
+                                                                               
<xsl:value-of select="sum_calculation"/>
+                                                                       </td>
+                                                               </tr>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                               <tr>
+                                                       <td class="th_text" 
align="left">
+                                                               <xsl:value-of 
select="lang_start_date"/>
+                                                       </td>
+                                                       <td align="left">
+                                                               <xsl:value-of 
select="start_date"/>
+                                                       </td>
+                                                       <td align="left">
+                                                               <xsl:value-of 
select="lang_materials"/>
+                                                       </td>
+                                               </tr>
+                                               <tr>
+                                                       <td class="th_text" 
align="left">
+                                                               <xsl:value-of 
select="lang_end_date"/>
+                                                       </td>
+                                                       <td align="left">
+                                                               <xsl:value-of 
select="end_date"/>
+                                                       </td>
+                                                       <td align="left">
+                                                               <xsl:value-of 
select="lang_work"/>
+                                                       </td>
+                                               </tr>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="branch_list/selected">
+                                                               <tr>
+                                                                       <td 
class="th_text" align="left" valign="top">
+                                                                               
<xsl:value-of select="lang_branch"/>
+                                                                       </td>
+                                                                       <td 
align="left">
+                                                                               
<xsl:for-each select="branch_list[selected='selected']">
+                                                                               
        <xsl:value-of select="name"/>
+                                                                               
        <xsl:if test="position() != last()">, </xsl:if>
+                                                                               
</xsl:for-each>
+                                                                               
<xsl:choose>
+                                                                               
        <xsl:when test="other_branch!=''">
+                                                                               
                <xsl:text>, </xsl:text>
+                                                                               
                <xsl:value-of select="other_branch"/>
+                                                                               
        </xsl:when>
+                                                                               
</xsl:choose>
+                                                                       </td>
+                                                               </tr>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="key_responsible_list/selected">
+                                                               <tr>
+                                                                       <td 
class="th_text" align="left">
+                                                                               
<xsl:value-of select="lang_key_responsible"/>
+                                                                       </td>
+                                                                       <td 
align="left">
+                                                                               
<xsl:for-each select="key_responsible_list">
+                                                                               
        <xsl:choose>
+                                                                               
                <xsl:when test="selected">
+                                                                               
                        <xsl:value-of select="name"/>
+                                                                               
                </xsl:when>
+                                                                               
        </xsl:choose>
+                                                                               
</xsl:for-each>
+                                                                       </td>
+                                                               </tr>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                               <xsl:if 
test="key_fetch_list/selected">
+                                                       <tr>
+                                                               <td 
class="th_text" align="left">
+                                                                       
<xsl:value-of select="lang_key_fetch"/>
+                                                               </td>
+                                                               <xsl:for-each 
select="key_fetch_list">
+                                                                       
<xsl:choose>
+                                                                               
<xsl:when test="selected">
+                                                                               
        <td align="left">
+                                                                               
                <xsl:value-of select="name"/>
+                                                                               
        </td>
+                                                                               
</xsl:when>
+                                                                       
</xsl:choose>
+                                                               </xsl:for-each>
+                                                       </tr>
+                                               </xsl:if>
+                                               <xsl:if 
test="key_deliver_list/selected">
+                                                       <tr>
+                                                               <td 
class="th_text" align="left">
+                                                                       
<xsl:value-of select="lang_key_deliver"/>
+                                                               </td>
+                                                               <xsl:for-each 
select="key_deliver_list">
+                                                                       
<xsl:choose>
+                                                                               
<xsl:when test="selected">
+                                                                               
        <td align="left">
+                                                                               
                <xsl:value-of select="name"/>
+                                                                               
        </td>
+                                                                               
</xsl:when>
+                                                                       
</xsl:choose>
+                                                               </xsl:for-each>
+                                                       </tr>
+                                               </xsl:if>
+                                       </table>
+                               </td>
+                       </tr>
+                       <xsl:choose>
+                               <xsl:when test="values_view_order!=''">
+                                       <tr>
+                                               <td colspand="3">
+                                                       <xsl:choose>
+                                                               <xsl:when 
test="use_yui_table='1'">
+                                                                               
<xsl:for-each select="//datatable_def">
+                                                                               
        <xsl:if test="container = 'datatable-container_0'">
+                                                                               
                <xsl:call-template name="table_setup">
+                                                                               
                        <xsl:with-param name="container" select ='container'/>
+                                                                               
                        <xsl:with-param name="requestUrl" select ='requestUrl' 
/>
+                                                                               
                        <xsl:with-param name="ColumnDefs" select ='ColumnDefs' 
/>
+                                                                               
                        <xsl:with-param name="tabletools" select ='tabletools' 
/>
+                                                                               
                        <xsl:with-param name="data" select ='data' />
+                                                                               
                        <xsl:with-param name="config" select ='config' />
+                                                                               
                </xsl:call-template>
+                                                                               
        </xsl:if>
+                                                                               
</xsl:for-each>
+                                                               </xsl:when>
+                                                               <xsl:otherwise>
+                                                                       <table 
width="100%" cellpadding="2" cellspacing="2" align="left" border="1">
+                                                                               
<xsl:apply-templates select="table_header_view_order"/>
+                                                                               
<xsl:apply-templates select="values_view_order"/>
+                                                                       </table>
+                                                               </xsl:otherwise>
+                                                       </xsl:choose>
+                                               </td>
+                                       </tr>
+                               </xsl:when>
+                       </xsl:choose>
+                       <xsl:choose>
+                               <xsl:when test="sms_data!=''">
+                                       <xsl:apply-templates select="sms_data"/>
+                               </xsl:when>
+                       </xsl:choose>
+                       <xsl:choose>
+                               <xsl:when test="order_footer_header!=''">
+                                       <tr>
+                                               <td>
+                                                       <br/>
+                                                       <h4>
+                                                               <xsl:value-of 
select="order_footer_header"/>
+                                                       </h4>
+                                               </td>
+                                       </tr>
+                               </xsl:when>
+                       </xsl:choose>
+                       <xsl:choose>
+                               <xsl:when test="order_footer!=''">
+                                       <tr>
+                                               <td>
+                                                       <xsl:value-of 
select="order_footer"/>
+                                               </td>
+                                       </tr>
+                               </xsl:when>
+                       </xsl:choose>
+               </table>
+       </font>
 </xsl:template>
 
+
 <!-- New template-->
 <xsl:template match="table_header_view_order">
        <xsl:variable name="sort_activity_num">
@@ -853,25 +1143,25 @@
        </xsl:variable>
        <thead>
                <tr class="th">
-                       <td class="th_text" width="5%" align="right">
+                       <td class="th_text" width="5%" align="center">
                                <xsl:value-of select="php:function('lang', 
'post')"/>
                        </td>
-                       <td class="th_text" width="15%" align="left">
+                       <td class="th_text" width="15%" align="center">
                                <xsl:value-of select="php:function('lang', 
'Code')"/>
                        </td>
-                       <td class="th_text" width="40%" align="left">
+                       <td class="th_text" width="40%" align="center">
                                <xsl:value-of select="php:function('lang', 
'descr')"/>
                        </td>
-                       <td class="th_text" width="4%" align="left">
+                       <td class="th_text" width="4%" align="center">
                                <xsl:value-of select="php:function('lang', 
'Unit')"/>
                        </td>
-                       <td class="th_text" width="2%" align="right">
+                       <td class="th_text" width="2%" align="center">
                                <xsl:value-of select="php:function('lang', 
'Quantity')"/>
                        </td>
-                       <td class="th_text" width="5%" align="right">
+                       <td nowrap="true" class="th_text" width="5%" 
align="center">
                                <xsl:value-of select="php:function('lang', 
'Bill per unit')"/>
                        </td>
-                       <td class="th_text" width="15%" align="right">
+                       <td class="th_text" width="15%" align="center">
                                <xsl:value-of select="php:function('lang', 
'cost')"/>
                        </td>
                </tr>
@@ -2436,9 +2726,46 @@
                </xsl:otherwise>
        </xsl:choose>
 </xsl:template>
+<!-- New template-->
+<xsl:template match="sms_data">
+       <tr>
+               <td>
+                       <br/>
+                       <xsl:value-of select="heading"/>
+               </td>
+       </tr>
+       <tr>
+               <td class="th_text">
+                       <xsl:value-of select="message"/>
+               </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>
+       <tr>
+               <td class="th_text">
+                       <xsl:value-of select="lang_example"/>
+                       <xsl:text>: </xsl:text>
+                       <xsl:value-of select="example"/>
+               </td>
+       </tr>
+       <tr>
+               <td>
+                       <img src="{encoded_text}"/>
+               </td>
+       </tr>
 
+</xsl:template>
+
 <!-- New template-->
-<xsl:template match="sms_data">
+<!--xsl:template match="sms_data">
        <div class="pure-control-group">
                <label>
                        <xsl:text> </xsl:text>
@@ -2468,7 +2795,7 @@
                        </div>
                </div>
        </div>
-</xsl:template>
+</xsl:template-->
 
 <!-- New template-->
 <xsl:template match="options">
@@ -2531,3 +2858,48 @@
        </form>
 
 </xsl:template>
+
+<!-- $Id$ -->
+<xsl:template name="location_view_local">
+       <xsl:apply-templates select="location_data_local"/>
+</xsl:template>
+
+<!-- New template-->
+<xsl:template match="location_data_local">
+       <xsl:for-each select="location">
+               <tr>
+                       <xsl:choose>
+                               <xsl:when test="value !=''">
+                                       <td>
+                                               <xsl:value-of select="name"/>
+                                       </td>
+                                       <td>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="input_type !='hidden'">
+                                                               <xsl:choose>
+                                                                       
<xsl:when test="query_link !=''">
+                                                                               
<xsl:variable name="query_link" select="query_link"/>
+                                                                               
<a href="{$query_link}" class="th_text">
+                                                                               
        <xsl:value-of select="value"/>
+                                                                               
</a>
+                                                                       
</xsl:when>
+                                                                       
<xsl:otherwise>
+                                                                               
<xsl:value-of select="value"/>
+                                                                       
</xsl:otherwise>
+                                                               </xsl:choose>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                               <xsl:for-each select="extra">
+                                                       <xsl:choose>
+                                                               <xsl:when 
test="input_type !='hidden'">
+                                                                       
<xsl:text> </xsl:text>
+                                                                       
<xsl:value-of select="value"/>
+                                                               </xsl:when>
+                                                       </xsl:choose>
+                                               </xsl:for-each>
+                                       </td>
+                               </xsl:when>
+                       </xsl:choose>
+               </tr>
+       </xsl:for-each>
+</xsl:template>




reply via email to

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