fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [17034] Stable: Merge 17027:17033 from trunk


From: sigurdne
Subject: [Fmsystem-commits] [17034] Stable: Merge 17027:17033 from trunk
Date: Mon, 4 Sep 2017 09:57:33 -0400 (EDT)

Revision: 17034
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=17034
Author:   sigurdne
Date:     2017-09-04 09:57:33 -0400 (Mon, 04 Sep 2017)
Log Message:
-----------
Stable: Merge 17027:17033 from trunk

Modified Paths:
--------------
    branches/Version-2_0-branch/booking/inc/schedule.php
    branches/Version-2_0-branch/booking/setup/phpgw_no.lang
    branches/Version-2_0-branch/felamimail/inc/class.ajax_contacts.inc.php
    branches/Version-2_0-branch/phpgwapi/inc/class.data_cleaner.inc.php
    branches/Version-2_0-branch/property/inc/class.bocommon.inc.php
    branches/Version-2_0-branch/property/inc/class.botts.inc.php
    branches/Version-2_0-branch/property/inc/class.sotts.inc.php
    branches/Version-2_0-branch/property/inc/class.uitts.inc.php
    branches/Version-2_0-branch/property/inc/hook_settings.inc.php
    branches/Version-2_0-branch/property/setup/phpgw_no.lang
    branches/Version-2_0-branch/property/setup/setup.inc.php
    branches/Version-2_0-branch/property/setup/tables_current.inc.php
    branches/Version-2_0-branch/property/setup/tables_update.inc.php
    branches/Version-2_0-branch/property/templates/base/tts.xsl

Property Changed:
----------------
    branches/Version-2_0-branch/
    branches/Version-2_0-branch/booking/

Index: branches/Version-2_0-branch
===================================================================
--- branches/Version-2_0-branch 2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch 2017-09-04 13:57:33 UTC (rev 17034)

Property changes on: branches/Version-2_0-branch
___________________________________________________________________
Modified: svn:mergeinfo
## -1,4 +1,4 ##
 /branches/dev-syncromind:13653
 /branches/dev-syncromind-2:14933-16846
 /branches/stavangerkommune:12743-12875,12986
-/trunk:14721-14732,14734-14735,14737,14739,14741,14743-14744,14746-14749,14751,14753,14755-14757,14759,14761-14764,14766-14768,14770-14783,14785-14792,14794-14813,14815-14816,14818,14820-14822,14824-14825,14827-14829,14831-14834,14836,14838,14840-14842,14844-14845,14847,14849-14866,14868-14869,14871,14873-14875,14877-14878,14880-14884,14886-14896,14898,14900-14902,14904,14906-14909,14911-14915,14917-14919,14921-14922,14924-14978,14980-15258,15260-15261,15263-15264,15266-15285,15287-15288,15290-15291,15293,15295,15297,15299-15305,15307-15310,15312-15335,15337-15352,15354,15356,15358,15360-15541,15543-15566,15568-15569,15571,15573-15581,15583,15585-15617,15619,15621-15630,15632-15635,15637-15639,15641-15643,15645,15647-15665,15667-15668,15670-15671,15673-15693,15695-15712,15714-15764,15766-15767,15769-15787,15789-15802,15804-15811,15813-15814,15816-15818,15820-15849,15851-15887,15889-15900,15902-16046,16048-16051,16053,16055,16057-16063,16065-16071,16073-16077,16079-16081,16083-16099,16101-16130,16132-16140,16142,16144-16212,16214-16219,16221,16223-16224,16226,16228-16229,16231,16233,16235,16237,16239-16240,16242,16244-16246,16248,16250-16251,16253-16255,16257-16259,16261,16263,16265,16267,16269-16276,16278,16280-16283,16285,16287-16288,16290,16292-16295,16297-16305,16307-16314,16316-16318,16320-16322,16324,16326-16330,16332,16334,16336,16338-16339,16341-16342,16344,16346,16348,16350,16352-16353,16355-16358,16360,16362,16364-16369,16371,16373,16375-16378,16380,16382-16383,16385,16387,16389,16391,16393-16395,16397,16399-16402,16404,16406,16408,16410-16415,16417,16419-16420,16422-16425,16427,16429-16440,16442,16444,16446,16448-16449,16451,16453,16455-16463,16465-16472,16474-16475,16477-16484,16486,16488,16490-16497,16499,16501-16503,16505-16512,16514-16517,16519,16521,16523,16525,16527-16532,16534,16536-16541,16543,16545-16554,16556,16558-16565,16567-16575,16577-16584,16586-16588,16590,16592-16593,16595-16596,16598,16600-16601,16603-16608,16610-16614,16616-16618,16620-16621,16623-16624,16626,16628,16630,16632-16638,16640,16642,16644,16646-16651,16653-16663,16665,16667,16669,16671,16673,16675,16677,16679-16680,16682,16684,16686,16688-16692,16694-16695,16697-16699,16701,16703,16705-16706,16708,16710,16712,16714,16716-16718,16720-16728,16730-16732,16734-16739,16741,16743-16746,16748-16750,16752-16755,16757,16759-16761,16763,16765,16767,16769-16774,16776,16778-16783,16785-16788,16790,16792,16794,16796-16802,16804-16807,16809,16811-16817,16819,16821-16825,16827-16831,16833,16835-16836,16838,16840-16844,16846-16847,16849,16851,16853-16854,16856-16859,16861,16863-16865,16867,16869-16871,16873,16875-16876,16878,16880-16881,16883,16885,16887-16888,16890,16892,16894-16900,16902,16904,16906,16908-16909,16911-16916,16918-16919,16921,16923,16925,16927,16929-16930,16932,16934,16936-16937,16939-16942,16944,16946,16948,16950,16952-16953,16955-16959,16961,16963,16965-16970,16972,16974-16977,16979-16982,16984,16986,16988-16999,17001,17003,17005-17018,17020-17023,17025-17026
\ No newline at end of property
+/trunk:14721-14732,14734-14735,14737,14739,14741,14743-14744,14746-14749,14751,14753,14755-14757,14759,14761-14764,14766-14768,14770-14783,14785-14792,14794-14813,14815-14816,14818,14820-14822,14824-14825,14827-14829,14831-14834,14836,14838,14840-14842,14844-14845,14847,14849-14866,14868-14869,14871,14873-14875,14877-14878,14880-14884,14886-14896,14898,14900-14902,14904,14906-14909,14911-14915,14917-14919,14921-14922,14924-14978,14980-15258,15260-15261,15263-15264,15266-15285,15287-15288,15290-15291,15293,15295,15297,15299-15305,15307-15310,15312-15335,15337-15352,15354,15356,15358,15360-15541,15543-15566,15568-15569,15571,15573-15581,15583,15585-15617,15619,15621-15630,15632-15635,15637-15639,15641-15643,15645,15647-15665,15667-15668,15670-15671,15673-15693,15695-15712,15714-15764,15766-15767,15769-15787,15789-15802,15804-15811,15813-15814,15816-15818,15820-15849,15851-15887,15889-15900,15902-16046,16048-16051,16053,16055,16057-16063,16065-16071,16073-16077,16079-16081,16083-16099,16101-16130,16132-16140,16142,16144-16212,16214-16219,16221,16223-16224,16226,16228-16229,16231,16233,16235,16237,16239-16240,16242,16244-16246,16248,16250-16251,16253-16255,16257-16259,16261,16263,16265,16267,16269-16276,16278,16280-16283,16285,16287-16288,16290,16292-16295,16297-16305,16307-16314,16316-16318,16320-16322,16324,16326-16330,16332,16334,16336,16338-16339,16341-16342,16344,16346,16348,16350,16352-16353,16355-16358,16360,16362,16364-16369,16371,16373,16375-16378,16380,16382-16383,16385,16387,16389,16391,16393-16395,16397,16399-16402,16404,16406,16408,16410-16415,16417,16419-16420,16422-16425,16427,16429-16440,16442,16444,16446,16448-16449,16451,16453,16455-16463,16465-16472,16474-16475,16477-16484,16486,16488,16490-16497,16499,16501-16503,16505-16512,16514-16517,16519,16521,16523,16525,16527-16532,16534,16536-16541,16543,16545-16554,16556,16558-16565,16567-16575,16577-16584,16586-16588,16590,16592-16593,16595-16596,16598,16600-16601,16603-16608,16610-16614,16616-16618,16620-16621,16623-16624,16626,16628,16630,16632-16638,16640,16642,16644,16646-16651,16653-16663,16665,16667,16669,16671,16673,16675,16677,16679-16680,16682,16684,16686,16688-16692,16694-16695,16697-16699,16701,16703,16705-16706,16708,16710,16712,16714,16716-16718,16720-16728,16730-16732,16734-16739,16741,16743-16746,16748-16750,16752-16755,16757,16759-16761,16763,16765,16767,16769-16774,16776,16778-16783,16785-16788,16790,16792,16794,16796-16802,16804-16807,16809,16811-16817,16819,16821-16825,16827-16831,16833,16835-16836,16838,16840-16844,16846-16847,16849,16851,16853-16854,16856-16859,16861,16863-16865,16867,16869-16871,16873,16875-16876,16878,16880-16881,16883,16885,16887-16888,16890,16892,16894-16900,16902,16904,16906,16908-16909,16911-16916,16918-16919,16921,16923,16925,16927,16929-16930,16932,16934,16936-16937,16939-16942,16944,16946,16948,16950,16952-16953,16955-16959,16961,16963,16965-16970,16972,16974-16977,16979-16982,16984,16986,16988-16999,17001,17003,17005-17018,17020-17023,17025-17026,17028-17033
\ No newline at end of property
Index: branches/Version-2_0-branch/booking
===================================================================
--- branches/Version-2_0-branch/booking 2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/booking 2017-09-04 13:57:33 UTC (rev 17034)

Property changes on: branches/Version-2_0-branch/booking
___________________________________________________________________
Modified: svn:mergeinfo
## -1,3 +1,3 ##
 /branches/dev-syncromind-2/booking:14933-16846
 /branches/stavangerkommune/booking:9468-12740,12743-12875,12986
-/trunk/booking:14721-14732,14824-14825,14827-14829,14831-14834,14836,14838,14840-14842,14844-14845,14871,14886-14896,14900-14902,14917-14919,14924-14978,14980-15258,15266-15285,15287-15288,15297,15299-15305,15307-15310,15312-15335,15337-15352,15354,15360-15541,15543-15566,15568-15569,15585-15617,15621-15630,15637-15639,15641-15643,15645,15647-15665,15667-15668,15695-15712,15714-15764,15820-15849,15889-15900,15902-16046,16055,16101-16130,16144-16212,16297-16305,16307-16314,16393-16395,16490-16497,16514-16517,16534,16567-16575,16577-16584,16586-16588,16590,16592-16593,16595-16596,16598,16616-16618,16730,16734-16739,16748-16750,16769-16774,16785-16788,16796-16802,16835-16836,16846-16847,16883,16885,16908-16909,16939-16942,16944,16946,16948,17020-17023
\ No newline at end of property
+/trunk/booking:14721-14732,14824-14825,14827-14829,14831-14834,14836,14838,14840-14842,14844-14845,14871,14886-14896,14900-14902,14917-14919,14924-14978,14980-15258,15266-15285,15287-15288,15297,15299-15305,15307-15310,15312-15335,15337-15352,15354,15360-15541,15543-15566,15568-15569,15585-15617,15621-15630,15637-15639,15641-15643,15645,15647-15665,15667-15668,15695-15712,15714-15764,15820-15849,15889-15900,15902-16046,16055,16101-16130,16144-16212,16297-16305,16307-16314,16393-16395,16490-16497,16514-16517,16534,16567-16575,16577-16584,16586-16588,16590,16592-16593,16595-16596,16598,16616-16618,16730,16734-16739,16748-16750,16769-16774,16785-16788,16796-16802,16835-16836,16846-16847,16883,16885,16908-16909,16939-16942,16944,16946,16948,17020-17023,17028-17033
\ No newline at end of property
Modified: branches/Version-2_0-branch/booking/inc/schedule.php
===================================================================
--- branches/Version-2_0-branch/booking/inc/schedule.php        2017-09-04 
13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/booking/inc/schedule.php        2017-09-04 
13:57:33 UTC (rev 17034)
@@ -59,7 +59,24 @@
                        // Bookings found
                        else
                        {
-                               $next = 
array_filter(array_merge(array_map('get_from', $bookings), array_map('get_to', 
$bookings)), create_function('$a', "return \$a > '$t';"));
+                               /**
+                                * create_function will be deprecated from PHP 
7.2
+                                */
+//                             $next = 
array_filter(array_merge(array_map('get_from', $bookings), array_map('get_to', 
$bookings)), create_function('$a', "return \$a > '$t';"));
+                               $next = array();
+                               $next_candidates = 
array_merge(array_map('get_from', $bookings), array_map('get_to', $bookings));
+
+                               if($next_candidates)
+                               {
+                                       foreach ($next_candidates as 
$next_candidate)
+                                       {
+                                               if($next_candidate > $t)
+                                               {
+                                                       $next[] = 
$next_candidate;
+                                               }
+                                       }
+                               }
+
                                if (!$next)
                                {
                                        break;

Modified: branches/Version-2_0-branch/booking/setup/phpgw_no.lang
===================================================================
--- branches/Version-2_0-branch/booking/setup/phpgw_no.lang     2017-09-04 
13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/booking/setup/phpgw_no.lang     2017-09-04 
13:57:33 UTC (rev 17034)
@@ -707,4 +707,5 @@
 start date     booking no      Start dato
 toggle show inactive   booking no      Veklse på å vise inaktive
 season edit    booking no      Endre sesong
-season show    booking no      Vis sesong
\ No newline at end of file
+season show    booking no      Vis sesong
+application edit       booking no      Rediger søknad
\ No newline at end of file

Modified: branches/Version-2_0-branch/felamimail/inc/class.ajax_contacts.inc.php
===================================================================
--- branches/Version-2_0-branch/felamimail/inc/class.ajax_contacts.inc.php      
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/felamimail/inc/class.ajax_contacts.inc.php      
2017-09-04 13:57:33 UTC (rev 17034)
@@ -1,35 +1,48 @@
 <?php
-       
/***************************************************************************\
-       * eGroupWare - FeLaMiMail                                               
    *
-       * http://www.linux-at-work.de                                           
    *
-       * http://www.phpgw.de                                                   
    *
-       * http://www.egroupware.org                                             
    *
-       * Written by : Lars Kneschke address@hidden                   *
-       * -------------------------------------------------                     
    *
-       * This program is free software; you can redistribute it and/or modify 
it   *
-       * under the terms of the GNU General Public License as published by the 
    *
-       * Free Software Foundation; either version 2 of the License, or (at 
your    *
-       * option) any later version.                                            
    *
-       
\***************************************************************************/
+       /*       * 
*************************************************************************\
+        * eGroupWare - FeLaMiMail                                              
     *
+        * http://www.linux-at-work.de                                          
     *
+        * http://www.phpgw.de                                                  
     *
+        * http://www.egroupware.org                                            
     *
+        * Written by : Lars Kneschke address@hidden                   *
+        * -------------------------------------------------                    
     *
+        * This program is free software; you can redistribute it and/or modify 
it   *
+        * under the terms of the GNU General Public License as published by 
the     *
+        * Free Software Foundation; either version 2 of the License, or (at 
your    *
+        * option) any later version.                                           
     *
+         
\************************************************************************** */
 
        /* $Id$ */
 
        phpgw::import_class('phpgwapi.sql_criteria');
-       class ajax_contacts {
-               function __construct() {
+
+       class ajax_contacts
+       {
+
+               function __construct()
+               {
                        $GLOBALS['phpgw']->session->commit_session();
-                       $this->charset  = 'utf-8';
+                       $this->charset = 'utf-8';
                        $this->translation = 
createObject('felamimail.translation');
                }
-               
-               function searchAddress($_searchString) {
-                       if 
(method_exists($GLOBALS['phpgw']->contacts,'search')) {
+
+               function searchAddress( $_searchString )
+               {
+
+                       function compare( $a, $b )
+                       {
+                               return strcasecmp($a["n_fn"],$b["n_fn"]);
+                       }
+
+                       if (method_exists($GLOBALS['phpgw']->contacts, 
'search'))
+                       {
                                // 1.3+
                                $contacts = 
$GLOBALS['phpgw']->contacts->search(array(
-                                       'n_fn'       => $_searchString,
-                                       'email'      => $_searchString,
+                                       'n_fn' => $_searchString,
+                                       'email' => $_searchString,
                                        'email_home' => $_searchString,
-                               
),array('n_fn','email','email_home'),'n_fn','','%',false,'OR',array(0,20));
+                                       ), array('n_fn', 'email', 
'email_home'), 'n_fn', '', '%', false, 'OR', array(
+                                       0, 20));
 
                                // additionally search the accounts, if the 
contact storage is not the account storage
                                if 
($GLOBALS['phpgw_info']['server']['account_repository'] == 'ldap' &&
@@ -36,71 +49,82 @@
                                        
$GLOBALS['phpgw_info']['server']['contact_repository'] == 'sql')
                                {
                                        $accounts = 
$GLOBALS['phpgw']->contacts->search(array(
-                                               'n_fn'       => $_searchString,
-                                               'email'      => $_searchString,
+                                               'n_fn' => $_searchString,
+                                               'email' => $_searchString,
                                                'email_home' => $_searchString,
-                                       
),array('n_fn','email','email_home'),'n_fn','','%',false,'OR',array(0,20),array('owner'
 => 0));
-                                       
+                                               ), array('n_fn', 'email', 
'email_home'), 'n_fn', '', '%', false, 'OR', array(
+                                               0, 20), array('owner' => 0));
+
                                        if ($contacts && $accounts)
                                        {
-                                               $contacts = 
array_merge($contacts,$accounts);
-                                               
usort($contacts,create_function('$a,$b','return 
strcasecmp($a["n_fn"],$b["n_fn"]);'));
+                                               $contacts = 
array_merge($contacts, $accounts);
+                                               usort($contacts, 'compare');
                                        }
-                                       elseif($accounts)
+                                       elseif ($accounts)
                                        {
-                                               $contacts =& $accounts;
+                                               $contacts = & $accounts;
                                        }
                                        unset($accounts);
                                }
-                       } else {
+                       }
+                       else
+                       {
                                // < 1.3
 
                                $d = CreateObject('phpgwapi.contacts');
-                               $fields = array ('per_first_name', 
'per_last_name', 'email', 'email_home');
+                               $fields = array('per_first_name', 
'per_last_name', 'email', 'email_home');
                                $criteria_search[] = 
phpgwapi_sql_criteria::token_begin('per_first_name', $_searchString);
                                $criteria_search[] = 
phpgwapi_sql_criteria::token_begin('per_last_name', $_searchString);
-                               $criteria_search[] = 
phpgwapi_sql_criteria::token_has('email', $_searchString); 
+                               $criteria_search[] = 
phpgwapi_sql_criteria::token_has('email', $_searchString);
                                $criteria[] = 
phpgwapi_sql_criteria::_append_or($criteria_search);
-                               $criteria[] = $d->criteria_for_index((int) 
$GLOBALS['phpgw_info']['user']['account_id']);
+                               $criteria[] = 
$d->criteria_for_index((int)$GLOBALS['phpgw_info']['user']['account_id']);
                                $criteria_token = 
phpgwapi_sql_criteria::_append_and($criteria);
 //FIXME        : the sql_builder/sql_criteria has issues.
                                $contacts = $d->get_persons($fields, 0, 0, 
'per_last_name', 'ASC', '', $criteria_token);
                        }
 
-                       $response =& new xajaxResponse();
+                       $response = & new xajaxResponse();
 
-                       if(is_array($contacts)) {
-                               $innerHTML      = '';
-                               $jsArray        = array();
-                               $i              = 0;
-                               
-                               foreach($contacts as $contact) {
-                                       
foreach(array($contact['email'],$contact['email_home']) as $email) {
+                       if (is_array($contacts))
+                       {
+                               $innerHTML = '';
+                               $jsArray = array();
+                               $i = 0;
+
+                               foreach ($contacts as $contact)
+                               {
+                                       foreach (array($contact['email'], 
$contact['email_home']) as $email)
+                                       {
                                                // avoid wrong addresses, if an 
rfc822 encoded address is in addressbook
-                                               $email = 
preg_replace("/(^.*<)(address@hidden)(.*)/",'$2',$email);
-                                               if(!empty($email) && 
!isset($jsArray[$email])) {
+                                               $email = 
preg_replace("/(^.*<)(address@hidden)(.*)/", '$2', $email);
+                                               if (!empty($email) && 
!isset($jsArray[$email]))
+                                               {
                                                        $i++;
-                                                       $str = 
$this->translation->convert(trim($contact['n_fn'] ? $contact['n_fn'] : 
$contact['fn']) .' <'. trim($email) .'>', $this->charset, 'utf-8');
+                                                       $str = 
$this->translation->convert(trim($contact['n_fn'] ? $contact['n_fn'] : 
$contact['fn']) . ' <' . trim($email) . '>', $this->charset, 'utf-8');
                                                        #$innerHTML .= '<div 
class="inactiveResultRow" onclick="selectSuggestion('. $i .')">'.
-                                                       $innerHTML .= '<div 
class="inactiveResultRow" onmousedown="keypressed(13,1)" 
onmouseover="selectSuggestion('.($i-1).')">'.
-                                                               
htmlentities($str, ENT_QUOTES, 'utf-8') .'</div>';
-                                                       $jsArray[$email] = 
addslashes(trim($contact['n_fn'] ? $contact['n_fn'] : $contact['fn']) .' <'. 
trim($email) .'>');
+                                                       $innerHTML .= '<div 
class="inactiveResultRow" onmousedown="keypressed(13,1)" 
onmouseover="selectSuggestion(' . ($i - 1) . ')">' .
+                                                               
htmlentities($str, ENT_QUOTES, 'utf-8') . '</div>';
+                                                       $jsArray[$email] = 
addslashes(trim($contact['n_fn'] ? $contact['n_fn'] : $contact['fn']) . ' <' . 
trim($email) . '>');
                                                }
-                                               if ($i > 10) break;     // we 
check for # of results here, as we might have empty email addresses
+                                               if ($i > 10)
+                                                       break; // we check for 
# of results here, as we might have empty email addresses
                                        }
                                }
 
-                               if($jsArray) {
+                               if ($jsArray)
+                               {
                                        $response->addAssign('resultBox', 
'innerHTML', $innerHTML);
-                                       $response->addScript('results = new 
Array("'.implode('","',$jsArray).'");');
+                                       $response->addScript('results = new 
Array("' . implode('","', $jsArray) . '");');
                                        
$response->addScript('displayResultBox();');
                                }
                                //$response->addScript("getResults();");
                                //$response->addScript("selectSuggestion(-1);");
-                       } else {
+                       }
+                       else
+                       {
                                $response->addAssign('resultBox', 'className', 
'resultBoxHidden');
                        }
 
                        return $response->getXML();
                }
-       }
+       }
\ No newline at end of file

Modified: branches/Version-2_0-branch/phpgwapi/inc/class.data_cleaner.inc.php
===================================================================
--- branches/Version-2_0-branch/phpgwapi/inc/class.data_cleaner.inc.php 
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/phpgwapi/inc/class.data_cleaner.inc.php 
2017-09-04 13:57:33 UTC (rev 17034)
@@ -251,11 +251,21 @@
                        //XXX external references begin with http(s) isnt'it ? 
what should I do if it's not external ?? like href="/tata"
                        // Just try to save a <a href="titi.org"> my site </a>
                        // you get a <a href="/phpgw/redirect.php?go=titi.org"> 
my site </a>
-                       // Save a second time and you will get :
-                       // <a 
href="/phpgw/redirect.php?go=/phpgw/redirect.php?go=titi.org"> my site </a>
-                       // ....
                        $data = 
preg_replace_callback('/href\s*=\s*([\\\]?["\']?)((?(1)[^\1]*?|[^\s]+))(?(1)\1|)/i',
-                               create_function('$m', 'return \'href="\' . 
(strlen($m[2]) && $m[2]{0} == \'#\' ? $m[2] : 
$GLOBALS[\'phpgw\']->safe_redirect(urldecode($m[2]))) . \'"\';'),
+//                             create_function('$m', 'return \'href="\' . 
(strlen($m[2]) && $m[2]{0} == \'#\' ? $m[2] : 
$GLOBALS[\'phpgw\']->safe_redirect(urldecode($m[2]))) . \'"\';'),
+                               function ($m)
+                               {
+                                       if(preg_match('/redirect.php\?go=/i', 
$m[2]))
+                                       {
+                                               $url = $m[2];
+                                       }
+                                       else
+                                       {
+                                               $url = strlen($m[2]) && 
$m[2]{0} == '#' ? $m[2] : $GLOBALS['phpgw']->safe_redirect(urldecode($m[2]));
+                                       }
+                                       $ret = 'href="'. $url .'"';
+                                       return $ret;
+                               },
                                $data);
                }
                return $data;

Modified: branches/Version-2_0-branch/property/inc/class.bocommon.inc.php
===================================================================
--- branches/Version-2_0-branch/property/inc/class.bocommon.inc.php     
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/inc/class.bocommon.inc.php     
2017-09-04 13:57:33 UTC (rev 17034)
@@ -628,6 +628,14 @@
                                $contact['value_contact_tel'] = 
$contact_data[0]['tel_work'];
 
                                unset($contacts);
+
+                               if(!$contact['value_contact_email'])
+                               {
+                                       $user_id = 
createObject('property.soresponsible')->get_contact_user_id( 
$data['contact_id'] );
+                                       $prefs                                  
= $this->create_preferences('property', $user_id);
+                                       $contact['value_contact_email']         
= $prefs['email'];
+                                       $contact['value_contact_tel']   = 
$prefs['cellphone'];
+                               }
                        }
 
                        $contact['field'] = $field;

Modified: branches/Version-2_0-branch/property/inc/class.botts.inc.php
===================================================================
--- branches/Version-2_0-branch/property/inc/class.botts.inc.php        
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/inc/class.botts.inc.php        
2017-09-04 13:57:33 UTC (rev 17034)
@@ -704,7 +704,8 @@
                                        $ticket['delay'] = 
round(($ticket['finnish_date2'] - $ticket['finnish_date']) / (24 * 3600));
                                        $ticket['finnish_date'] = 
$ticket['finnish_date2'];
                                }
-                               $ticket['finnish_date'] = 
(isset($ticket['finnish_date']) && $ticket['finnish_date'] ? 
$GLOBALS['phpgw']->common->show_date($ticket['finnish_date'], 
$this->dateformat) : '');
+                               $ticket['finnish_date'] = 
!empty($ticket['finnish_date']) ? 
$GLOBALS['phpgw']->common->show_date($ticket['finnish_date'], 
$this->dateformat) : '';
+                               $ticket['order_deadline'] = 
!empty($ticket['order_deadline'])  ? 
$GLOBALS['phpgw']->common->show_date($ticket['order_deadline'], 
$this->dateformat) : '';
 
                                /*
                                  if ($ticket['status'] == 'X')
@@ -782,6 +783,10 @@
                        {
                                $ticket['finnish_date'] = 
$GLOBALS['phpgw']->common->show_date($ticket['finnish_date'], 
$this->dateformat);
                        }
+                       if ($ticket['order_deadline'])
+                       {
+                               $ticket['order_deadline'] = 
$GLOBALS['phpgw']->common->show_date($ticket['order_deadline'], 
$this->dateformat);
+                       }
 
                        if ($ticket['location_code'])
                        {

Modified: branches/Version-2_0-branch/property/inc/class.sotts.inc.php
===================================================================
--- branches/Version-2_0-branch/property/inc/class.sotts.inc.php        
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/inc/class.sotts.inc.php        
2017-09-04 13:57:33 UTC (rev 17034)
@@ -589,6 +589,7 @@
                                'unspsc_code' => 'fm_tts_tickets.unspsc_code',
                                'b_account_id' => 'fm_tts_tickets.b_account_id',
                                'continuous' => 'fm_tts_tickets.continuous',
+                               'order_deadline' => 
'fm_tts_tickets.order_deadline',
                        );
 
                        $custom_cols = $this->custom->find('property', 
'.ticket', 0, '', 'ASC', 'attrib_sort', true, true);
@@ -783,6 +784,7 @@
                                                'unspsc_code' => 
$this->db->f('unspsc_code'),
                                                'b_account_id' => 
$this->db->f('b_account_id'),
                                                'continuous' => 
$this->db->f('continuous'),
+                                               'order_deadline' => 
$this->db->f('order_deadline'),
                                        );
 
                                        foreach ($custom_cols as $custom_col)
@@ -871,6 +873,7 @@
                                $ticket['contact_id'] = 
$this->db->f('contact_id');
                                $ticket['order_id'] = $this->db->f('order_id');
                                $ticket['continuous'] = 
$this->db->f('continuous');
+                               $ticket['order_deadline'] = 
$this->db->f('order_deadline');
                                $ticket['vendor_id'] = 
$this->db->f('vendor_id');
                                $ticket['contract_id'] = 
$this->db->f('contract_id',true);
                                $ticket['service_id'] = 
$this->db->f('service_id',true);
@@ -1740,6 +1743,11 @@
                                $value_set['tax_code'] = $ticket['tax_code'];
                                $value_set['continuous'] = 
$ticket['continuous'];
 
+                               if(!empty($ticket['order_deadline']))
+                               {
+                                       $value_set['order_deadline'] = 
phpgwapi_datetime::date_to_timestamp($ticket['order_deadline']);
+                               }
+
                                if(isset($ticket['vendor_email']) && 
is_array($ticket['vendor_email']))
                                {
                                        $vendor_email = array();

Modified: branches/Version-2_0-branch/property/inc/class.uitts.inc.php
===================================================================
--- branches/Version-2_0-branch/property/inc/class.uitts.inc.php        
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/inc/class.uitts.inc.php        
2017-09-04 13:57:33 UTC (rev 17034)
@@ -1622,7 +1622,6 @@
                                
$GLOBALS['phpgw']->jqcal->add_listener('values_finnish_date');
                        }
 
-
                        $membership = 
$GLOBALS['phpgw']->accounts->membership($this->account);
                        $my_groups = array();
                        foreach ($membership as $group_id => $group)
@@ -2183,6 +2182,7 @@
 
                        if ($access_order)
                        {
+                               
$GLOBALS['phpgw']->jqcal->add_listener('order_deadline');
 
                                $b_account_data = 
$this->bocommon->initiate_ui_budget_account_lookup(array
                                        (
@@ -3018,6 +3018,7 @@
                                'value_origin' => $ticket['origin'],
                                'value_target' => $ticket['target'],
                                'value_finnish_date' => $ticket['finnish_date'],
+                               'value_order_deadline' => 
$ticket['order_deadline'],
                                'link_entity' => $link_entity,
                                'msgbox_data' => 
$GLOBALS['phpgw']->common->msgbox($msgbox_data),
                                'location_data2' => $location_data,
@@ -3317,8 +3318,10 @@
 
                        $data = array
                                (
-                               array('col1' => 
"{$this->bo->config->config_data['org_name']}\n\nOrg.nr: 
{$this->bo->config->config_data['org_unit_id']}",
-                                       'col2' => lang('Order'), 'col3' => 
lang('order id') . "\n\n{$ticket['order_id']}")
+                               array(
+                                       'col1' => 
"{$this->bo->config->config_data['org_name']}\n\nOrg.nr: 
{$this->bo->config->config_data['org_unit_id']}",
+                                       'col2' => lang('Order'),
+                                       'col3' => lang('order id') . 
"\n\n{$ticket['order_id']}")
                        );
 
                        $pdf->ezTable($data, array('col1' => '', 'col2' => '', 
'col3' => ''), '', array(
@@ -3384,6 +3387,11 @@
                                array('col1' => $from, 'col2' => 
$invoice_address)
                        );
 
+                       if($ticket['order_deadline'])
+                       {
+                               $data[] = array('col1' => lang('deadline'), 
'col2' =>"<b>{$ticket['order_deadline']}</b>");
+                       }
+
                        $pdf->ezTable($data, array('col1' => '', 'col2' => ''), 
'', array('showHeadings' => 0,
                                'shaded' => 0, 'xPos' => 0,
                                'xOrientation' => 'right', 'width' => 500, 
'gridlines' => EZ_GRIDLINE_ALL,
@@ -3421,15 +3429,77 @@
 
                        $pdf->ezText($ticket['order_descr'], 14);
                        $pdf->ezSetDy(-20);
-                       $pdf->selectFont(PHPGW_API_INC . 
'/pdf/fonts/Helvetica-Bold.afm');
-                       $pdf->ezText('Kontakt på bygget:', 14);
-                       $pdf->selectFont(PHPGW_API_INC . 
'/pdf/fonts/Helvetica.afm');
-                       $pdf->ezText($contact_name, 14);
-                       $pdf->ezText($contact_email, 14);
-                       $pdf->ezText($contact_phone, 14);
-                       $pdf->ezSetDy(-20);
-                       $pdf->ezText("Av hensyn til våre ansatte og leietakere 
ber vi om at kontakt på bygget blir kontaktet minst 1 dag i forkant av 
oppdrag.", 14);
 
+                       $order_contact_block_template = 
$GLOBALS['phpgw_info']['user']['preferences']['property']['order_contact_block_1'];
+
+                       if 
(!empty($this->bo->config->config_data['contact_at_location']))
+                       {
+                               $contact_at_location = 
$this->bo->config->config_data['contact_at_location'];
+
+                               $_responsible = 
execMethod('property.boresponsible.get_responsible', array('location'=> 
explode('-', $ticket['location_code']),
+                                       'cat_id' => $ticket['cat_id']));
+
+                               if($_responsible)
+                               {
+                                       $prefs                                  
= $this->bocommon->create_preferences('property', $_responsible);
+                                       $_responsible_name              = 
$GLOBALS['phpgw']->accounts->get($_responsible)->__toString();
+                                       $_responsible_email             = 
$prefs['email'];
+                                       $_responsible_cellphone = 
$prefs['cellphone'];
+                                       if($contact_email)
+                                       {
+                                               $contact_name2 = 
$_responsible_name;
+                                               $contact_email2 = 
$_responsible_email;
+                                               $contact_phone2 = 
$_responsible_cellphone;
+                                               $order_contact_block_template = 
$GLOBALS['phpgw_info']['user']['preferences']['property']['order_contact_block_2'];
+                                       }
+                                       else
+                                       {
+                                               $contact_name = 
$_responsible_name;
+                                               $contact_email = 
$_responsible_email;
+                                               $contact_phone = 
$_responsible_cellphone;
+                                       }
+                               }
+                       }
+
+                       $contact_block = str_replace(array
+                               (
+                               '__user_name__',
+                               '__user_phone__',
+                               '__user_email__',
+                               '__contact_name__',
+                               '__contact_email__',
+                               '__contact_phone__',
+                               '__contact_name2__',
+                               '__contact_email2__',
+                               '__contact_phone2__',
+                               '__order_id__',
+                               '[b]',
+                               '[/b]'
+                                       ), array
+                               (
+                               $user_name,
+                               $user_phone,
+                               $user_email,
+                               $contact_name,
+                               $contact_email,
+                               $contact_phone,
+                               $contact_name2,
+                               $contact_email2,
+                               $contact_phone2,
+                               $order_id,
+                               '<b>',
+                               '</b>'
+                                       ), $order_contact_block_template);
+
+//                     $pdf->selectFont(PHPGW_API_INC . 
'/pdf/fonts/Helvetica-Bold.afm');
+//                     $pdf->ezText('Kontakt på bygget:', 14);
+//                     $pdf->selectFont(PHPGW_API_INC . 
'/pdf/fonts/Helvetica.afm');
+//                     $pdf->ezText($contact_name, 14);
+//                     $pdf->ezText($contact_email, 14);
+//                     $pdf->ezText($contact_phone, 14);
+//                     $pdf->ezSetDy(-20);
+                       $pdf->ezText($contact_block, 14);
+
                        $location_exceptions = 
createObject('property.solocation')->get_location_exception($ticket['location_code'],
 $alert_vendor = true);
 
                        if($location_exceptions)
@@ -3551,6 +3621,9 @@
                        $contact_name = '';
                        $contact_email = '';
                        $contact_phone = '';
+                       $contact_name2  = '';
+                       $contact_email2 = '';
+                       $contact_phone3 = '';
 
                        if (isset($this->bo->config->config_data['org_name']))
                        {
@@ -3611,6 +3684,7 @@
                        $user_phone = 
$GLOBALS['phpgw_info']['user']['preferences']['property']['cellphone'];
                        $user_email = 
$GLOBALS['phpgw_info']['user']['preferences']['property']['email'];
                        $order_email_template = 
$GLOBALS['phpgw_info']['user']['preferences']['property']['order_email_template'];
+                       $order_contact_block_template = 
$GLOBALS['phpgw_info']['user']['preferences']['property']['order_contact_block_1'];
 
                        if 
(!empty($this->bo->config->config_data['contact_at_location']))
                        {
@@ -3625,11 +3699,88 @@
                                        $_responsible_name              = 
$GLOBALS['phpgw']->accounts->get($_responsible)->__toString();
                                        $_responsible_email             = 
$prefs['email'];
                                        $_responsible_cellphone = 
$prefs['cellphone'];
+                                       if($contact_email  && 
($contact_data['value_contact_email'] != $_responsible_email))
+                                       {
+                                               $contact_name2 = 
$_responsible_name;
+                                               $contact_email2 = "<a 
href='mailto:{$_responsible_email}'>{$_responsible_email}</a>";
+                                               $contact_phone2 = 
$_responsible_cellphone;
+                                               $order_contact_block_template = 
$GLOBALS['phpgw_info']['user']['preferences']['property']['order_contact_block_2'];
+                                       }
+                                       else
+                                       {
+                                               $contact_name = 
$_responsible_name;
+                                               $contact_email = "<a 
href='mailto:{$_responsible_email}'>{$_responsible_email}</a>";
+                                               $contact_phone = 
$_responsible_cellphone;
+                                       }
                                }
                        }
 
-                       $body = nl2br(str_replace(array
+                       $contact_block = nl2br(str_replace(array
                                (
+                               '__user_name__',
+                               '__user_phone__',
+                               '__user_email__',
+                               '__contact_name__',
+                               '__contact_email__',
+                               '__contact_phone__',
+                               '__contact_name2__',
+                               '__contact_email2__',
+                               '__contact_phone2__',
+                               '__order_id__',
+                               '[b]',
+                               '[/b]'
+                                       ), array
+                               (
+                               $user_name,
+                               $user_phone,
+                               $user_email,
+                               $contact_name,
+                               $contact_email,
+                               $contact_phone,
+                               $contact_name2,
+                               $contact_email2,
+                               $contact_phone2,
+                               $order_id,
+                               '<b>',
+                               '</b>'
+                                       ), $order_contact_block_template));
+
+
+                       $dateformat = 
$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat'];
+                       $date = $GLOBALS['phpgw']->common->show_date(time(), 
$dateformat);
+
+
+                       $body = "<table><tr>";
+                       $body .= "<td valign='top'>{$organisation}<br/>Org.nr: 
{$this->bo->config->config_data['org_unit_id']}</td>";
+                       $body .= "<td valign='top'>" .  lang('order id') . 
"<br/><b>{$ticket['order_id']}</b></td>";
+                       $body .= "<tr>";
+                       $body .= "<td valign='top'>" .  lang('vendor') . 
"<br/>" . $this->_get_vendor_name($ticket['vendor_id']) . "</td>";
+                       $body .= "<td>" .  lang('delivery address') . 
"<br/>{$location}</td>";
+                       $body .= "</tr>";
+                       $body .= "<tr>";
+                       $body .= "<td valign='top'>";
+                       $body .=  lang('date') . ":{$date}<br/>";
+                       $body .=  lang('dimb') . ": {$ticket['ecodimb']}<br/>";
+                       $body .=  lang('from') . ": 
{$user_name}<br/>{$user_phone}<br/>{$user_email}<br/>";
+                       $body .= "</td>";
+
+                       $body .= "<td valign='top'>" .  lang('invoice address') 
. "<br/>{$this->bo->config->config_data['invoice_address']}</td>";
+
+                       if($ticket['order_deadline'])
+                       {
+                               $body .= "<tr><td>";
+                               $body .=  lang('deadline');
+                               $body .= "</td>";
+                               $body .= "<td>";
+                               $body .=  "<b>{$ticket['order_deadline']}</b>";
+                               $body .= "</td></tr>";
+                       }
+
+                       $body .= "</tr></table><br/>";
+
+
+                       $body .= nl2br(str_replace(array
+                               (
                                '__vendor_name__',
                                '__organisation__',
                                '__user_name__',
@@ -3638,6 +3789,7 @@
                                '__ressursnr__',
                                '__location__',
                                '__order_description__',
+                               '__contact_block__',
                                '__contact_name__',
                                '__contact_email__',
                                '__contact_phone__',
@@ -3654,6 +3806,7 @@
                                $ressursnr,
                                $location,
                                $order_description,
+                               $contact_block,
                                $contact_name,
                                $contact_email,
                                $contact_phone,
@@ -3679,13 +3832,87 @@
                        }
 
 
-                       $html = "<html><head><meta http-equiv=\"Content-Type\" 
content=\"text/html; charset=utf-8\"><title>{$subject}</title></head>";
+                       $html = "<html><head><meta http-equiv=\"Content-Type\" 
content=\"text/html; charset=utf-8\"><title>{$subject}</title>";
+                       $html .= '      <style>
 
+                       table, th, td {
+                               border: 1px solid black;
+                               border-collapse: collapse;
+                       }
+               html {
+               font-family: arial;
+               }
+               @page {
+               size: A4;
+               }
+
+               @media print {
+               li {page-break-inside: avoid;}
+               h1, h2, h3, h4, h5 {
+               page-break-after: avoid;
+               }
+
+               table, figure {
+               page-break-inside: avoid;
+               }
+               }
+
+
+               @page:left{
+               @bottom-left {
+               content: "Page " counter(page) " of " counter(pages);
+               }
+               }
+               @media print
+               {
+               .btn
+               {
+               display: none !important;
+               }
+               }
+
+               .btn{
+               background: none repeat scroll 0 0 #2647A0;
+               color: #FFFFFF;
+               display: inline-block;
+               margin-right: 5px;
+               padding: 5px 10px;
+               text-decoration: none;
+               border: 1px solid #173073;
+               cursor: pointer;
+               }
+
+               ul{
+               list-style: none outside none;
+               }
+
+               li{
+               list-style: none outside none;
+               }
+
+               li.list_item ol li{
+               list-style: decimal;
+               }
+
+               ul.groups li {
+               padding: 3px 0;
+               }
+
+               ul.groups li.odd{
+               background: none repeat scroll 0 0 #DBE7F5;
+               }
+
+               ul.groups h3 {
+               font-size: 18px;
+               margin: 0 0 5px;
+               }
+
+       </style></head>';
                        $body .='</br>';
                        $body .='</br>';
                        $body .= '<a href ="' . 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'property.uitts.view',
                                        'id' => $id), false, true) . '">' . 
lang('Ticket') . ' #' . $id . '</a>';
-                       $html .= "<body>{$body}</body></html>";
+                       $html .= "<body><div style='width: 
800px;'>{$body}</div></body></html>";
 
 
                        if ($preview)

Modified: branches/Version-2_0-branch/property/inc/hook_settings.inc.php
===================================================================
--- branches/Version-2_0-branch/property/inc/hook_settings.inc.php      
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/inc/hook_settings.inc.php      
2017-09-04 13:57:33 UTC (rev 17034)
@@ -343,12 +343,8 @@
        $default .= "\n" . '[b]Beskrivelse av oppdraget:[/b]';
        $default .= "\n" . '__order_description__';
        $default .= "\n";
-       $default .= "\n" . '[b]Kontakt på bygget:[/b]';
+       $default .= "\n" . '__contact_block__';
        $default .= "\n";
-       $default .= "\n" . '__contact_name__';
-       $default .= "\n" . '__contact_email__';
-       $default .= "\n" . '__contact_phone__';
-       $default .= "\n";
        $default .= "\n" . '[b]Faktura må merkes med ordrenummer: __order_id__ 
og ressursnr.: __ressursnr__[/b]';
        $default .= "\n";
        $default .= "\n" . 'Med hilsen';
@@ -358,3 +354,26 @@
        $default .= "\n" . '__organisation__';
 
        create_text_area('order email', 'order_email_template', 10, 60, '', 
$default);
+
+
+       $default_block_1 = '';
+       $default_block_1 .= "\n" . '[b]Kontakt på bygget:[/b]';
+       $default_block_1 .= "\n" . 'Av hensyn til våre ansatte og leietakere 
ber vi om at kontakt på bygget blir kontaktet minst 1 dag i forkant av 
oppdrag:';
+       $default_block_1 .= "\n" . '__contact_name__';
+       $default_block_1 .= "\n" . '__contact_email__';
+       $default_block_1 .= "\n" . '__contact_phone__';
+
+       create_text_area('contact block 1', 'order_contact_block_1', 10, 60, 
'', $default_block_1);
+
+
+       $default_block_2 = '';
+       $default_block_2 .= "\n" . '[b]Kontakt på bygget:[/b]';
+       $default_block_2 .= "\n" . 'Av hensyn til våre ansatte og leietakere 
ber vi om at Vedlikeholdsteknikere';
+       $default_block_2 .= "\n" . '__contact_name__: __contact_email__ / 
__contact_phone__, ';
+       $default_block_2 .= "\n" . 'alternativt Driftskooordinator';
+       $default_block_2 .= "\n" . '__contact_name2__: __contact_email2__ / 
__contact_phone2__';
+       $default_block_2 .= "\n" . 'blir kontaktet minst 1 dag i forkant av 
oppdrag';
+
+
+
+       create_text_area('contact block 2', 'order_contact_block_2', 10, 60, 
'', $default_block_2);

Modified: branches/Version-2_0-branch/property/setup/phpgw_no.lang
===================================================================
--- branches/Version-2_0-branch/property/setup/phpgw_no.lang    2017-09-04 
13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/setup/phpgw_no.lang    2017-09-04 
13:57:33 UTC (rev 17034)
@@ -2235,4 +2235,5 @@
 reference      property        no      Referanse
 alert vendor   property        no      Varsle leverandør
 important information  property        no      Viktig informasjon
-category content       property        no      Tekster for kategori
\ No newline at end of file
+category content       property        no      Tekster for kategori
+order deadline property        no      Frist for utførelse
\ No newline at end of file

Modified: branches/Version-2_0-branch/property/setup/setup.inc.php
===================================================================
--- branches/Version-2_0-branch/property/setup/setup.inc.php    2017-09-04 
13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/setup/setup.inc.php    2017-09-04 
13:57:33 UTC (rev 17034)
@@ -11,7 +11,7 @@
         * @version $Id$
        */
        $setup_info['property']['name']                 = 'property';
-       $setup_info['property']['version']              = '0.9.17.718';
+       $setup_info['property']['version']              = '0.9.17.719';
        $setup_info['property']['app_order']    = 8;
        $setup_info['property']['enable']               = 1;
        $setup_info['property']['app_group']    = 'office';

Modified: branches/Version-2_0-branch/property/setup/tables_current.inc.php
===================================================================
--- branches/Version-2_0-branch/property/setup/tables_current.inc.php   
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/setup/tables_current.inc.php   
2017-09-04 13:57:33 UTC (rev 17034)
@@ -1149,8 +1149,8 @@
                                'contact_email' => array('type' => 'varchar', 
'precision' => '64', 'nullable' => True),
                                'tenant_id' => array('type' => 'int', 
'precision' => '4', 'nullable' => True),
                                'entry_date' => array('type' => 'int', 
'precision' => '4', 'nullable' => True),
-                               'finnish_date' => array('type' => 'int', 
'precision' => '4', 'nullable' => True),
-                               'finnish_date2' => array('type' => 'int', 
'precision' => '4', 'nullable' => True),
+                               'finnish_date' => array('type' => 'int', 
'precision' => 8, 'nullable' => True),
+                               'finnish_date2' => array('type' => 'int', 
'precision' => 8, 'nullable' => True),
                                'contact_id' => array('type' => 'int', 
'precision' => 4, 'nullable' => True),
                                'order_id' => array('type' => 'int', 
'precision' => 8, 'nullable' => True),
                                'ordered_by' => array('type' => 'int', 
'precision' => 4, 'nullable' => True),
@@ -1180,6 +1180,7 @@
                                'file_attachments' => array('type' => 
'varchar', 'precision' => 255, 'nullable' => True),
                                'delivery_address' => array('type' => 'text', 
'nullable' => True),
                                'continuous' => array('type' => 'int', 
'precision' => 2, 'nullable' => True),
+                               'order_deadline' => array('type' => 'int', 
'precision' => 8, 'nullable' => True),
                        ),
                        'pk' => array('id'),
                        'ix' => array(),

Modified: branches/Version-2_0-branch/property/setup/tables_update.inc.php
===================================================================
--- branches/Version-2_0-branch/property/setup/tables_update.inc.php    
2017-09-04 13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/setup/tables_update.inc.php    
2017-09-04 13:57:33 UTC (rev 17034)
@@ -9787,3 +9787,23 @@
                        return $GLOBALS['setup_info']['property']['currentver'];
                }
        }
+
+       /**
+       * Update property version from 0.9.17.718 to 0.9.17.719
+       *
+       */
+       $test[] = '0.9.17.718';
+
+       function property_upgrade0_9_17_718()
+       {
+               $GLOBALS['phpgw_setup']->oProc->m_odb->transaction_begin();
+
+               $GLOBALS['phpgw_setup']->oProc->AddColumn('fm_tts_tickets', 
'order_deadline', array(
+                       'type' => 'int', 'precision' => 8, 'nullable' => true));
+
+               if($GLOBALS['phpgw_setup']->oProc->m_odb->transaction_commit())
+               {
+                       $GLOBALS['setup_info']['property']['currentver'] = 
'0.9.17.719';
+                       return $GLOBALS['setup_info']['property']['currentver'];
+               }
+       }
\ No newline at end of file

Modified: branches/Version-2_0-branch/property/templates/base/tts.xsl
===================================================================
--- branches/Version-2_0-branch/property/templates/base/tts.xsl 2017-09-04 
13:55:38 UTC (rev 17033)
+++ branches/Version-2_0-branch/property/templates/base/tts.xsl 2017-09-04 
13:57:33 UTC (rev 17034)
@@ -983,7 +983,18 @@
                                                                                
        <xsl:value-of select="value_order_descr"/>
                                                                                
</textarea>
                                                                        </div>
+                                                                       <div 
class="pure-control-group">
+                                                                               
<label>
+                                                                               
        <xsl:value-of select="php:function('lang', 'deadline')"/>
+                                                                               
</label>
 
+                                                                               
<input type="text" id="order_deadline" name="values[order_deadline]" size="10" 
value="{value_order_deadline}" readonly="readonly">
+                                                                               
        <xsl:attribute name="title">
+                                                                               
                <xsl:value-of select="php:function('lang', 'order deadline')"/>
+                                                                               
        </xsl:attribute>
+                                                                               
</input>
+                                                                       </div>
+
                                                                        <div 
class="pure-control-group">
                                                                                
<label>
                                                                                
        <xsl:value-of select="php:function('lang', 'cost estimate')"/>




reply via email to

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