fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [11180] controller: add component to control group


From: Sigurd Nes
Subject: [Fmsystem-commits] [11180] controller: add component to control group
Date: Mon, 17 Jun 2013 08:29:52 +0000

Revision: 11180
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=11180
Author:   sigurdne
Date:     2013-06-17 08:29:50 +0000 (Mon, 17 Jun 2013)
Log Message:
-----------
controller: add component to control group

Modified Paths:
--------------
    trunk/controller/inc/class.socontrol.inc.php
    trunk/controller/inc/class.uicalendar.inc.php
    
trunk/controller/templates/base/calendar/view_calendar_month_for_locations.xsl
    
trunk/controller/templates/base/calendar/view_calendar_year_for_locations.xsl
    trunk/controller/templates/base/css/base.css

Modified: trunk/controller/inc/class.socontrol.inc.php
===================================================================
--- trunk/controller/inc/class.socontrol.inc.php        2013-06-16 17:34:23 UTC 
(rev 11179)
+++ trunk/controller/inc/class.socontrol.inc.php        2013-06-17 08:29:50 UTC 
(rev 11180)
@@ -654,12 +654,22 @@
 
                                $location_array = 
execMethod('property.bolocation.read_single', array('location_code' => 
$location_code));
 
+                               $location_arr = explode('-', $location_code);
+                               $loc_name_arr = array();
+                               $i = 1;
+                               foreach ($location_arr as $_part)
+                               {
+                                       $loc_name_arr[] = 
$location_array["loc{$i}_name"];
+                                       $i++;
+                               }
+
                                $controls_array[] = array
                                (
-                                       "id"                    => $control_id, 
-                                       "title"                 => $title, 
-                                       "location_code" => $location_code, 
-                                       "loc1_name"             => 
$location_array["loc1_name"]
+                                       'id'                    => $control_id, 
+                                       'title'                 => $title, 
+                                       'location_code' => $location_code, 
+                                       'loc1_name'             => 
$location_array['loc1_name'],
+                                       'loc_name'              => implode(', 
', $loc_name_arr)
                                );
                        }
 

Modified: trunk/controller/inc/class.uicalendar.inc.php
===================================================================
--- trunk/controller/inc/class.uicalendar.inc.php       2013-06-16 17:34:23 UTC 
(rev 11179)
+++ trunk/controller/inc/class.uicalendar.inc.php       2013-06-17 08:29:50 UTC 
(rev 11180)
@@ -445,9 +445,9 @@
                {
                        static $_location_name = array();
 
-                       $control_id = phpgw::get_var('control_id');
+                       $control_id = phpgw::get_var('control_id', 'int');
                        $control = $this->so_control->get_single($control_id);
-                       $year = phpgw::get_var('year');
+                       $year = phpgw::get_var('year', 'int');
 
                        if (is_numeric($control_id) & $control_id > 0)
                        {
@@ -574,13 +574,13 @@
                        $heading_array = year_calendar::get_heading_array();
 
                        $data = array
-                               (
-                               'my_locations' => $my_locations,
-                               'control' => $control->toArray(),
-                               'heading_array' => $heading_array,
-                               'locations_with_calendar_array' => 
$locations_with_calendar_array,
-                               'components_with_calendar_array' => 
$components_with_calendar_array,
-                               'current_year' => $year,
+                       (
+                               'my_locations'                                  
        => $my_locations,
+                               'control'                                       
                => $control->toArray(),
+                               'heading_array'                                 
        => $heading_array,
+                               'locations_with_calendar_array'         => 
$locations_with_calendar_array,
+                               'components_with_calendar_array'        => 
$components_with_calendar_array,
+                               'current_year'                                  
        => $year,
                        );
 
                        
self::render_template_xsl(array('calendar/view_calendar_year_for_locations', 
'calendar/check_list_status_manager',

Modified: 
trunk/controller/templates/base/calendar/view_calendar_month_for_locations.xsl
===================================================================
--- 
trunk/controller/templates/base/calendar/view_calendar_month_for_locations.xsl  
    2013-06-16 17:34:23 UTC (rev 11179)
+++ 
trunk/controller/templates/base/calendar/view_calendar_month_for_locations.xsl  
    2013-06-17 08:29:50 UTC (rev 11180)
@@ -71,7 +71,7 @@
                                                        <xsl:value-of 
select="location/location_code"/>
                                                </td>
                                                <td class="location-name">
-                                                       <xsl:value-of 
select="location/loc1_name"/>
+                                                       <xsl:value-of 
select="location/loc_name"/>
                                                </td>
 
                                                <xsl:for-each 
select="calendar_array">

Modified: 
trunk/controller/templates/base/calendar/view_calendar_year_for_locations.xsl
===================================================================
--- 
trunk/controller/templates/base/calendar/view_calendar_year_for_locations.xsl   
    2013-06-16 17:34:23 UTC (rev 11179)
+++ 
trunk/controller/templates/base/calendar/view_calendar_year_for_locations.xsl   
    2013-06-17 08:29:50 UTC (rev 11180)
@@ -70,7 +70,7 @@
                                                        <xsl:value-of 
select="location/location_code"/>
                                                </td>
                                                <td class="location-name">
-                                                       <xsl:value-of 
select="location/loc1_name"/>
+                                                       <xsl:value-of 
select="location/loc_name"/>
                                                </td>
                                                        
                                                <xsl:for-each 
select="calendar_array">

Modified: trunk/controller/templates/base/css/base.css
===================================================================
--- trunk/controller/templates/base/css/base.css        2013-06-16 17:34:23 UTC 
(rev 11179)
+++ trunk/controller/templates/base/css/base.css        2013-06-17 08:29:50 UTC 
(rev 11180)
@@ -1339,6 +1339,7 @@
 #calendar .location-name, #calendar .component-type {
   width: 150px;
   text-align: left;
+  white-space: nowrap;
 }
 
 #calendar .frequency {




reply via email to

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