fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [7082] Merge 7079:7081 from trunk


From: Sigurd Nes
Subject: [Fmsystem-commits] [7082] Merge 7079:7081 from trunk
Date: Tue, 08 Mar 2011 10:33:58 +0000

Revision: 7082
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=7082
Author:   sigurdne
Date:     2011-03-08 10:33:58 +0000 (Tue, 08 Mar 2011)
Log Message:
-----------
Merge 7079:7081 from trunk

Modified Paths:
--------------
    branches/Version-1_0-branch/booking/inc/class.uibooking.inc.php
    branches/Version-1_0-branch/booking/setup/phpgw_no.lang
    branches/Version-1_0-branch/bookingfrontend/inc/class.uibooking.inc.php
    branches/Version-1_0-branch/bookingfrontend/inc/class.uibuilding.inc.php
    branches/Version-1_0-branch/bookingfrontend/setup/phpgw_no.lang
    branches/Version-1_0-branch/property/templates/base/wo_hour.xsl

Property Changed:
----------------
    branches/Version-1_0-branch/


Property changes on: branches/Version-1_0-branch
___________________________________________________________________
Modified: svn:mergeinfo
   - 
/trunk:6439-6441,6443,6445-6447,6449-6464,6466-6468,6470-6474,6476-6477,6479-6480,6483-6488,6490-6491,6493-6494,6496-6501,6503-6504,6506,6508,6510-6511,6513,6515-6516,6518,6520-6524,6526-6528,6533-6534,6536-6541,6543-6565,6567,6569,6571-6576,6578,6580-6586,6588-6596,6598-6600,6602-6604,6606-6607,6609-6611,6613-6625,6629-6639,6641-6643,6645-6646,6648,6650-6654,6656-6659,6661-6663,6665-6666,6668-6669,6672-6673,6675,6677-6678,6680,6682-6686,6688-6717,6719,6721-6722,6724-6728,6730,6732-6734,6736-6739,6741,6743,6745-6746,6748-6756,6758-6762,6764,6766-6788,6790,6792-6798,6800-6814,6816-6819,6821-6822,6824-6826,6828-6837,6839,6841,6843-6849,6851,6853-6869,6871-6874,6876-6877,6879,6881,6883,6885-6886,6888-6893,6895-6897,6899-6901,6903,6905-6907,6909,6911-6929,6931-6936,6938-6947,6949,6951,6953,6955-6956,6958-6959,6961-6968,6970-6971,6973-6974,6976-6978,6980,6982-7017,7019-7025,7027-7035,7037-7039,7041-7045,7047-7055,7057,7059-7065,7067-7069,7071,7073,7075-7076,7078
   + 
/trunk:6439-6441,6443,6445-6447,6449-6464,6466-6468,6470-6474,6476-6477,6479-6480,6483-6488,6490-6491,6493-6494,6496-6501,6503-6504,6506,6508,6510-6511,6513,6515-6516,6518,6520-6524,6526-6528,6533-6534,6536-6541,6543-6565,6567,6569,6571-6576,6578,6580-6586,6588-6596,6598-6600,6602-6604,6606-6607,6609-6611,6613-6625,6629-6639,6641-6643,6645-6646,6648,6650-6654,6656-6659,6661-6663,6665-6666,6668-6669,6672-6673,6675,6677-6678,6680,6682-6686,6688-6717,6719,6721-6722,6724-6728,6730,6732-6734,6736-6739,6741,6743,6745-6746,6748-6756,6758-6762,6764,6766-6788,6790,6792-6798,6800-6814,6816-6819,6821-6822,6824-6826,6828-6837,6839,6841,6843-6849,6851,6853-6869,6871-6874,6876-6877,6879,6881,6883,6885-6886,6888-6893,6895-6897,6899-6901,6903,6905-6907,6909,6911-6929,6931-6936,6938-6947,6949,6951,6953,6955-6956,6958-6959,6961-6968,6970-6971,6973-6974,6976-6978,6980,6982-7017,7019-7025,7027-7035,7037-7039,7041-7045,7047-7055,7057,7059-7065,7067-7069,7071,7073,7075-7076,7078,7080-7081

Modified: branches/Version-1_0-branch/booking/inc/class.uibooking.inc.php
===================================================================
--- branches/Version-1_0-branch/booking/inc/class.uibooking.inc.php     
2011-03-08 10:31:37 UTC (rev 7081)
+++ branches/Version-1_0-branch/booking/inc/class.uibooking.inc.php     
2011-03-08 10:33:58 UTC (rev 7082)
@@ -185,8 +185,9 @@
                        $allocation_id = phpgw::get_var('allocation_id', 'int', 
'GET');
                        $booking['building_id'] = phpgw::get_var('building_id', 
'int', 'GET');
                        $booking['resources'] = phpgw::get_var('resources', 
'int', 'GET');
-                       $booking['from_'] = phpgw::get_var('from_', 'str', 
'GET');
-                       $booking['to_'] = phpgw::get_var('to_', 'str', 'GET');
+            #The string replace is a workaround for a problem at Bergen 
Kommune 
+            $booking['from_'] = str_replace('%3A',':',phpgw::get_var('from_', 
'str', 'GET'));
+            $booking['to_'] = str_replace('%3A',':',phpgw::get_var('to_', 
'str', 'GET'));
                        $time_from = split(" ",phpgw::get_var('from_', 'str', 
'GET'));
                        $time_to =      split(" ",phpgw::get_var('to_', 'str', 
'GET'));
                        $step = phpgw::get_var('step', 'str', 'POST');
@@ -194,7 +195,7 @@
                        $invalid_dates = array();
                        $valid_dates = array();
 
-                       if($allocation_id)
+                       if(isset($allocation_id))
                        {
                                $allocation = 
$this->allocation_bo->read_single($allocation_id);
                                $season = 
$this->season_bo->read_single($allocation['season_id']);
@@ -205,25 +206,15 @@
                                array_set_default($booking, 'resources', 
array(get_var('resource', int, 'GET')));
                                $booking['organization_id'] = 
$allocation['organization_id'];
                                $booking['organization_name'] = 
$allocation['organization_name'];
-                       }
-
-            //start Debug code for testing problem on production server. to be 
removed ASAP!
-            if (phpgw::get_var('DEBUG', 'str', 'GET') == 'yes') {
-                echo "<pre>\n";
-                echo mb_detect_encoding(phpgw::get_var('from_', 'str', 'GET'), 
"auto");echo "\n";
-                print_r($allocation_id);echo "\n";
-                print_r($booking['from_']);echo "\n";
-                print_r($booking['to_']);echo "\n";
-                print_r($time_from);echo "\n";
-                print_r($time_to);echo "\n";
-                print_r($booking);echo "\n";
-                exit;
+                       } else {
+                               $season = 
$this->season_bo->read_single($_POST['season_id']);
             }
-            //end
+
                        if($_SERVER['REQUEST_METHOD'] == 'POST')
                        {
                                $today = getdate();
                                $booking = extract_values($_POST, 
$this->fields);
+                
                                if(strlen($_POST['from_']) < 6) 
                                {
                                        $date_from = array($time_from[0], 
$_POST['from_']);
@@ -256,7 +247,7 @@
 #                                              $errors['booking'] = lang('Can 
not create a booking in the past');
 #                                      }
 #                              } 
-                               if (!$allocation_id &&  $_POST['outseason'] == 
'on')
+                               if (!$booking['season_id'] &&  
$_POST['outseason'] == 'on')
                                {
                                        $errors['booking'] = lang('This booking 
is not connected to a season');
                                }       
@@ -338,22 +329,6 @@
                        {
                                $res_names[] = array('id' => $res['id'],'name' 
=> $res['name']);
                        }
-
-            //start Debug code for testing problem on production server. to be 
removed ASAP!
-            if (phpgw::get_var('DEBUG', 'str', 'GET') == 'end') {
-                echo "<pre>\n";
-                echo "encoding: ";echo 
mb_detect_encoding(phpgw::get_var('from_', 'str', 'GET'), "auto");echo "\n";
-                echo "encoding array: ";echo 
mb_detect_encoding($booking['from_'], "auto");echo "\n";
-                echo "allocation_id: ";print_r($allocation_id);echo "\n";
-                echo "booking from: ";print_r($booking['from_']);echo "\n";
-                echo "booking to: ";print_r($booking['to_']);echo "\n";
-                echo "time from: ";print_r($time_from);echo "\n";
-                echo "time to:";print_r($time_to);echo "\n";
-                echo "booking:\n";print_r($booking);echo "\n";
-                exit;
-            }
-            //end
-
                        if ($step < 2) 
                        {
                                self::render_template('booking_new', 
array('booking' => $booking, 

Modified: branches/Version-1_0-branch/booking/setup/phpgw_no.lang
===================================================================
--- branches/Version-1_0-branch/booking/setup/phpgw_no.lang     2011-03-08 
10:31:37 UTC (rev 7081)
+++ branches/Version-1_0-branch/booking/setup/phpgw_no.lang     2011-03-08 
10:33:58 UTC (rev 7082)
@@ -439,7 +439,7 @@
 Event created, Overlaps with existing booking, Remember to send a notification 
booking no      Arrangement opprettet. Overlapper en eksisterende booking. Husk 
å sende varsel
 Print as PDF   booking no      Skriv ut som PDF
 Pending        booking no      UNDER BEHANDLING
-This booking is not connected to a season      booking no      Denne bookingen 
er ikke koblet mote en sesong
+This booking is not connected to a season      booking no      Denne bookingen 
er ikke koblet mot en sesong
 Message from Bergen county - AktivBy   booking no      Melding fra Bergen 
kommune - AktivBy
 Organization shortname booking no      Kortnavn
 Group shortname        booking no      Kortnavn

Modified: 
branches/Version-1_0-branch/bookingfrontend/inc/class.uibooking.inc.php
===================================================================
--- branches/Version-1_0-branch/bookingfrontend/inc/class.uibooking.inc.php     
2011-03-08 10:31:37 UTC (rev 7081)
+++ branches/Version-1_0-branch/bookingfrontend/inc/class.uibooking.inc.php     
2011-03-08 10:33:58 UTC (rev 7082)
@@ -75,9 +75,9 @@
                        $booking = array();
                        $booking['building_id'] = phpgw::get_var('building_id', 
'int', 'GET');
                        $allocation_id = phpgw::get_var('allocation_id', 'int', 
'GET');
-                       $booking['from_'] = phpgw::get_var('from_', 'str', 
'GET');
-                       $booking['to_'] = phpgw::get_var('to_', 'str', 'GET');
-
+            #The string replace is a workaround for a problem at Bergen 
Kommune 
+            $booking['from_'] = str_replace('%3A',':',phpgw::get_var('from_', 
'str', 'GET'));
+            $booking['to_'] = str_replace('%3A',':',phpgw::get_var('to_', 
'str', 'GET'));
                        $time_from = split(" ",phpgw::get_var('from_', 'str', 
'GET'));
                        $time_to =      split(" ",phpgw::get_var('to_', 'str', 
'GET'));
 
@@ -95,21 +95,9 @@
                                $booking['building_id'] = $building['id'];
                                $booking['building_name'] = $building['name'];
                                array_set_default($booking, 'resources', 
array(get_var('resource', int, 'GET')));
-                       }
-            //start Debug code for testing problem on production server. to be 
removed ASAP!
-            if (phpgw::get_var('DEBUG', 'str', 'GET') == 'start') {
-                echo "<pre>\n";
-                echo "encoding get: ";echo 
mb_detect_encoding(phpgw::get_var('from_', 'str', 'GET'), "auto");echo "\n";
-                echo "encoding array: ";echo 
mb_detect_encoding($booking['from_'], "auto");echo "\n";
-                echo "allocation_id: ";print_r($allocation_id);echo "\n";
-                echo "booking from: ";print_r($booking['from_']);echo "\n";
-                echo "booking to: ";print_r($booking['to_']);echo "\n";
-                echo "time from: ";print_r($time_from);echo "\n";
-                echo "time to:";print_r($time_to);echo "\n";
-                echo "booking:\n";print_r($booking);echo "\n";
-                exit;
+                       } else {
+                               $season = 
$this->season_bo->read_single($_POST['season_id']);
             }
-            //end
                        if($_SERVER['REQUEST_METHOD'] == 'POST')
                        {
                                $today = getdate();
@@ -149,7 +137,7 @@
 #                                              $errors['booking'] = lang('Can 
not create a booking in the past');
 #                                      }
 #                              } 
-                               if (!$allocation_id &&  $_POST['outseason'] == 
'on')
+                               if (!$season_id &&  $_POST['outseason'] == 'on')
                                {
                                        $errors['booking'] = lang('This booking 
is not connected to a season');
                                }       
@@ -231,21 +219,6 @@
                        {
                                $res_names[] = array('id' => $res['id'],'name' 
=> $res['name']);
                        }
-            //start Debug code for testing problem on production server. to be 
removed ASAP!
-            if (phpgw::get_var('DEBUG', 'str', 'GET') == 'end') {
-                echo "<pre>\n";
-                echo "encoding: ";echo 
mb_detect_encoding(phpgw::get_var('from_', 'str', 'GET'), "auto");echo "\n";
-                echo "encoding array: ";echo 
mb_detect_encoding($booking['from_'], "auto");echo "\n";
-                echo "allocation_id: ";print_r($allocation_id);echo "\n";
-                echo "booking from: ";print_r($booking['from_']);echo "\n";
-                echo "booking to: ";print_r($booking['to_']);echo "\n";
-                echo "time from: ";print_r($time_from);echo "\n";
-                echo "time to:";print_r($time_to);echo "\n";
-                echo "booking:\n";print_r($booking);echo "\n";
-                exit;
-            }
-            //end
-
                        if ($step < 2) 
                        {
                                self::render_template('booking_new', 
array('booking' => $booking, 

Modified: 
branches/Version-1_0-branch/bookingfrontend/inc/class.uibuilding.inc.php
===================================================================
--- branches/Version-1_0-branch/bookingfrontend/inc/class.uibuilding.inc.php    
2011-03-08 10:31:37 UTC (rev 7081)
+++ branches/Version-1_0-branch/bookingfrontend/inc/class.uibuilding.inc.php    
2011-03-08 10:33:58 UTC (rev 7082)
@@ -51,7 +51,6 @@
                        {
                                $building['homepage'] = 
'http://'.$building['homepage'];
                        }
-//                     echo "<pre>";print_r($building);exit;
                        self::render_template('building', array("building" => 
$building));
                }
                

Modified: branches/Version-1_0-branch/bookingfrontend/setup/phpgw_no.lang
===================================================================
--- branches/Version-1_0-branch/bookingfrontend/setup/phpgw_no.lang     
2011-03-08 10:31:37 UTC (rev 7081)
+++ branches/Version-1_0-branch/bookingfrontend/setup/phpgw_no.lang     
2011-03-08 10:33:58 UTC (rev 7082)
@@ -299,7 +299,7 @@
 The booking uses resources not in the containing allocation    bookingfrontend 
no      Bookingen bruker ressurser som ikke finnes i gitt tildeling
 CONFIRMED      bookingfrontend no      BEKREFTET
 Pending        bookingfrontend no      Under behandling
-This booking is not connected to a season      bookingfrontend no      Denne 
bookingen er ikke koblet mote en sesong
+This booking is not connected to a season      bookingfrontend no      Denne 
bookingen er ikke koblet mot en sesong
 The user has accepted the document under point 8.      bookingfrontend no      
Brukeren har akseptert dokumentene under punkt 8.
 Organization shortname bookingfrontend no      Kortnavn
 Group shortname        bookingfrontend no      Kortnavn

Modified: branches/Version-1_0-branch/property/templates/base/wo_hour.xsl
===================================================================
--- branches/Version-1_0-branch/property/templates/base/wo_hour.xsl     
2011-03-08 10:31:37 UTC (rev 7081)
+++ branches/Version-1_0-branch/property/templates/base/wo_hour.xsl     
2011-03-08 10:33:58 UTC (rev 7082)
@@ -380,6 +380,11 @@
                                                                                
<td>
                                                                                
</td>
                                                                        </tr>
+                                                                       
<xsl:choose>
+                                                                               
<xsl:when test="table_send !=''">
+                                                                               
        <tr><td><xsl:apply-templates select="table_send"/></td></tr>
+                                                                               
</xsl:when>
+                                                                       
</xsl:choose>
 
                                                                        
<xsl:choose>
                                                                                
<xsl:when test="email_list !=''">




reply via email to

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