fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [10903] Deleted function view_cases_for_check_list


From: Torstein
Subject: [Fmsystem-commits] [10903] Deleted function view_cases_for_check_list
Date: Sun, 17 Feb 2013 18:17:30 +0000

Revision: 10903
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=10903
Author:   vator
Date:     2013-02-17 18:17:30 +0000 (Sun, 17 Feb 2013)
Log Message:
-----------
Deleted function view_cases_for_check_list

Modified Paths:
--------------
    trunk/controller/inc/class.uicase.inc.php
    trunk/controller/js/controller/ajax.js
    trunk/controller/js/controller/case.js
    trunk/controller/templates/base/calendar/select_buildings_on_property.xsl
    trunk/controller/templates/base/calendar/select_my_locations.xsl
    trunk/controller/templates/base/calendar/view_calendar_month.xsl
    
trunk/controller/templates/base/check_list/fragments/select_buildings_on_property.xsl

Modified: trunk/controller/inc/class.uicase.inc.php
===================================================================
--- trunk/controller/inc/class.uicase.inc.php   2013-02-17 17:12:49 UTC (rev 
10902)
+++ trunk/controller/inc/class.uicase.inc.php   2013-02-17 18:17:30 UTC (rev 
10903)
@@ -616,6 +616,7 @@
     function view_open_cases()
                {
                        $check_list_id = phpgw::get_var('check_list_id');
+      $location_code = phpgw::get_var('location_code');
                        
                        $check_list = 
$this->so_check_list->get_single($check_list_id);
                        $control = 
$this->so_control->get_single($check_list->get_control_id());                   
     

Modified: trunk/controller/js/controller/ajax.js
===================================================================
--- trunk/controller/js/controller/ajax.js      2013-02-17 17:12:49 UTC (rev 
10902)
+++ trunk/controller/js/controller/ajax.js      2013-02-17 18:17:30 UTC (rev 
10903)
@@ -550,7 +550,7 @@
        });
 
        
-       $(".selectLocation").change(function () {
+       $(".select-location").change(function () {
                 var location_code = $(this).val();
                 var thisForm = $(this).parents("form");
 

Modified: trunk/controller/js/controller/case.js
===================================================================
--- trunk/controller/js/controller/case.js      2013-02-17 17:12:49 UTC (rev 
10902)
+++ trunk/controller/js/controller/case.js      2013-02-17 18:17:30 UTC (rev 
10903)
@@ -9,7 +9,7 @@
                var type = $(thisForm).find("input[name='type']").val();
                var requestUrl = $(thisForm).attr("action");
     
-    var location_code = $("#choose_building_on_property  
option:selected").val();
+    var location_code = $("#choose-building-on-property  
option:selected").val();
     
     $(thisForm).find("input[name=location_code]").val(location_code);
     
@@ -254,6 +254,33 @@
 
                return false;
        });     
+  
+  $("#choose-building-on-property.view-cases").change(function () {
+                var location_code = $(this).val();
+                var thisForm = $(this).parents("form");
+
+                var period_type = 
$(thisForm).find("input[name='period_type']").val();
+                var year = $(thisForm).find("input[name='year']").val();
+                var month = $(thisForm).find("input[name='month']").val();
+                
+                if(location_code != "" & period_type == 'view_month')
+                {
+                        var oArgs = 
{menuaction:'controller.uicalendar.view_calendar_for_month'};
+                        var baseUrl = phpGWLink('index.php', oArgs, false);
+                        var requestUrl = baseUrl + "&location_code=" + 
location_code + "&year=" + year + "&month=" + month;
+                        
+                        window.location.href = requestUrl;
+                }
+                else if(location_code != "" & period_type == 'view_year')
+                {
+                        var oArgs = 
{menuaction:'controller.uicalendar.view_calendar_for_year'};
+                        var baseUrl = phpGWLink('index.php', oArgs, false);
+                        var requestUrl = baseUrl +  "&location_code=" + 
location_code + "&year=" + year;
+                        
+                        window.location.href = requestUrl;
+                }
+    });
+  
 });
 
 function validate_form( formObj )

Modified: 
trunk/controller/templates/base/calendar/select_buildings_on_property.xsl
===================================================================
--- trunk/controller/templates/base/calendar/select_buildings_on_property.xsl   
2013-02-17 17:12:49 UTC (rev 10902)
+++ trunk/controller/templates/base/calendar/select_buildings_on_property.xsl   
2013-02-17 18:17:30 UTC (rev 10903)
@@ -1,6 +1,5 @@
 <!-- $Id: view_calendar_month.xsl 9200 2012-04-21 20:05:34Z vator $ -->
 <xsl:template name="select_buildings_on_property">
-
   <form action="#">
     <input type="hidden" name="period_type" value="view_year" />
     <input type="hidden" name="year">
@@ -9,7 +8,7 @@
       </xsl:attribute>
     </input>
                
-    <select id="choose_building_on_property" class="selectLocation">
+    <select id="choose-building-on-property" class="select-location">
       <option value="">Velg bygg</option>
       <xsl:for-each select="buildings_on_property">
         <option>
@@ -24,5 +23,4 @@
       </xsl:for-each>
     </select>                                  
   </form>
-                               
 </xsl:template>

Modified: trunk/controller/templates/base/calendar/select_my_locations.xsl
===================================================================
--- trunk/controller/templates/base/calendar/select_my_locations.xsl    
2013-02-17 17:12:49 UTC (rev 10902)
+++ trunk/controller/templates/base/calendar/select_my_locations.xsl    
2013-02-17 18:17:30 UTC (rev 10903)
@@ -9,7 +9,7 @@
       </xsl:attribute>
     </input>
                                
-    <select id="choose_my_location" class="selectLocation">
+    <select id="choose-my-location" class="select-location">
       <option>Velg bygg</option>
       <xsl:for-each select="my_locations">
         <option>

Modified: trunk/controller/templates/base/calendar/view_calendar_month.xsl
===================================================================
--- trunk/controller/templates/base/calendar/view_calendar_month.xsl    
2013-02-17 17:12:49 UTC (rev 10902)
+++ trunk/controller/templates/base/calendar/view_calendar_month.xsl    
2013-02-17 18:17:30 UTC (rev 10903)
@@ -127,7 +127,7 @@
                                                        </xsl:attribute>
                                                </input>
 
-                                               <select id="choose_my_location" 
class="selectLocation">
+                                               <select id="choose-my-location" 
class="select-location">
                                                        <option>Velg 
bygg</option>
                                                        <xsl:for-each 
select="my_locations">
                                                                <xsl:choose>

Modified: 
trunk/controller/templates/base/check_list/fragments/select_buildings_on_property.xsl
===================================================================
--- 
trunk/controller/templates/base/check_list/fragments/select_buildings_on_property.xsl
       2013-02-17 17:12:49 UTC (rev 10902)
+++ 
trunk/controller/templates/base/check_list/fragments/select_buildings_on_property.xsl
       2013-02-17 18:17:30 UTC (rev 10903)
@@ -1,7 +1,11 @@
 <!-- $Id: view_calendar_month.xsl 9200 2012-04-21 20:05:34Z vator $ -->
 <xsl:template name="select_buildings_on_property">
                
-      <select id="choose_building_on_property" class="selectLocation">
+  <form action="#">
+    <input type="hidden" name="location_code" value="" />
+       
+    <select id="choose-building-on-property" class="view-cases">
+      <option value="">Velg bygg</option>
       <xsl:for-each select="buildings_on_property">
         <option>
           <xsl:if test="id = //building_location_code">
@@ -14,6 +18,5 @@
         </option>
       </xsl:for-each>
     </select>                                  
-                
-                                                       
+  </form>
 </xsl:template>




reply via email to

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