[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [15910] booking: change to alternative datetimepicker
From: |
sigurdne |
Subject: |
[Fmsystem-commits] [15910] booking: change to alternative datetimepicker |
Date: |
Fri, 28 Oct 2016 12:32:19 +0000 (UTC) |
Revision: 15910
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=15910
Author: sigurdne
Date: 2016-10-28 12:32:18 +0000 (Fri, 28 Oct 2016)
Log Message:
-----------
booking: change to alternative datetimepicker
Modified Paths:
--------------
trunk/booking/inc/class.uiallocation.inc.php
trunk/booking/inc/class.uiapplication.inc.php
trunk/booking/inc/class.uibooking.inc.php
trunk/booking/inc/class.uicommon.inc.php
trunk/booking/inc/class.uicompleted_reservation.inc.php
trunk/booking/inc/class.uicompleted_reservation_export.inc.php
trunk/booking/inc/class.uievent.inc.php
trunk/booking/inc/class.uireports.inc.php
trunk/booking/inc/class.uiseason.inc.php
trunk/bookingfrontend/inc/class.uiallocation.inc.php
trunk/bookingfrontend/inc/class.uibooking.inc.php
trunk/bookingfrontend/inc/class.uievent.inc.php
trunk/bookingfrontend/templates/base/application_new.xsl
Modified: trunk/booking/inc/class.uiallocation.inc.php
===================================================================
--- trunk/booking/inc/class.uiallocation.inc.php 2016-10-28 12:31:15 UTC
(rev 15909)
+++ trunk/booking/inc/class.uiallocation.inc.php 2016-10-28 12:32:18 UTC
(rev 15910)
@@ -438,8 +438,8 @@
$allocation['cancel_link'] =
self::link(array('menuaction' => 'booking.uiallocation.index'));
array_set_default($allocation, 'cost', '0');
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'time');
- $GLOBALS['phpgw']->jqcal->add_listener('field_to',
'time');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_from',
'time');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_to',
'time');
$tabs = array();
$tabs['generic'] = array('label' => lang('Allocation
New'), 'link' => '#allocation_new');
@@ -567,8 +567,8 @@
'date', 'security', 'file'));
$cost_history = $this->bo->so->get_ordered_costs($id);
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('field_to',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_from',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_to',
'datetime');
self::render_template_xsl('allocation_edit',
array('allocation' => $allocation,
'cost_history' => $cost_history));
@@ -691,7 +691,7 @@
$active_tab = 'generic';
$allocation['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
if ($step < 2)
{
Modified: trunk/booking/inc/class.uiapplication.inc.php
===================================================================
--- trunk/booking/inc/class.uiapplication.inc.php 2016-10-28 12:31:15 UTC
(rev 15909)
+++ trunk/booking/inc/class.uiapplication.inc.php 2016-10-28 12:32:18 UTC
(rev 15910)
@@ -31,6 +31,9 @@
public function __construct()
{
parent::__construct();
+
+ phpgwapi_jquery::load_widget('autocomplete');
+
$this->set_module();
// Analizar esta linea
self::process_booking_unauthorized_exceptions();
$this->bo = CreateObject('booking.boapplication');
@@ -789,8 +792,10 @@
$date['to_'] = pretty_timestamp($date['to_']);
}
- $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
+// $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
+// $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('start_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('end_date',
'datetime');
if ($GLOBALS['phpgw_info']['flags']['currentapp'] !=
'bookingfrontend')
{
@@ -895,8 +900,8 @@
$application['audience_json'] =
json_encode(array_map('intval', $application['audience']));
//test
- $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('start_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('end_date',
'datetime');
//
self::render_template('application_edit', array('application' => $application,
'activities' => $activities, 'agegroups' => $agegroups, 'audience' =>
$audience));
if ($GLOBALS['phpgw_info']['flags']['currentapp'] !=
'bookingfrontend')
Modified: trunk/booking/inc/class.uibooking.inc.php
===================================================================
--- trunk/booking/inc/class.uibooking.inc.php 2016-10-28 12:31:15 UTC (rev
15909)
+++ trunk/booking/inc/class.uibooking.inc.php 2016-10-28 12:32:18 UTC (rev
15910)
@@ -640,9 +640,9 @@
$tabs['generic'] = array('label' => lang('Booking
New'), 'link' => '#booking_new');
$active_tab = 'generic';
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
- $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('start_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('end_date',
'datetime');
$booking['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
$booking['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location',
@@ -789,8 +789,8 @@
$cost_history = $this->bo->so->get_ordered_costs($id);
$booking['audience_json'] =
json_encode(array_map('intval', $booking['audience']));
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('field_to',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_from',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_to',
'datetime');
$booking['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
$booking['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location',
@@ -947,7 +947,7 @@
$active_tab = 'generic';
$booking['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
if ($step < 2)
{
Modified: trunk/booking/inc/class.uicommon.inc.php
===================================================================
--- trunk/booking/inc/class.uicommon.inc.php 2016-10-28 12:31:15 UTC (rev
15909)
+++ trunk/booking/inc/class.uicommon.inc.php 2016-10-28 12:32:18 UTC (rev
15910)
@@ -707,7 +707,7 @@
}
}
- public function adddatetimepicker( $type = 'datetime' )
+ public function adddatetimepicker_old( $type = 'datetime' )
{
phpgwapi_jquery::load_widget('datepicker');
if ($GLOBALS['phpgw_info']['flags']['currentapp'] ==
'bookingfrontend')
@@ -800,11 +800,11 @@
$('#add-date-link').click(function(){
var add = $(this);
var html = '';
-
+
this.counter =
$('.date-container').length - 1;
if (!this.counter) { this.counter = 0; }
-
+
{$html}
add.parent().parent().children('#dates-container').append(html);
@@ -836,4 +836,138 @@
JS;
$GLOBALS['phpgw']->js->add_code('', $js);
}
+
+ public function adddatetimepicker( $type = 'datetime' )
+ {
+ phpgwapi_jquery::load_widget('datetimepicker');
+
+ $dateformat = str_ireplace(array('y'), array('Y'),
$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']);
+
+ switch($type)
+ {
+ case 'datetime':
+ $_type = 'datetime';
+ $dateformat .= " H:i";
+ break;
+ case 'time':
+ $_type = 'time';
+ $dateformat = "H:i";
+ break;
+ default:
+ $_type = 'date';
+ }
+
+ $img_cal = $GLOBALS['phpgw']->common->image('phpgwapi',
'cal');
+
+ $userlang = 'en';
+ if (
isset($GLOBALS['phpgw_info']['user']['preferences']['common']['lang']) )
+ {
+ $userlang =
$GLOBALS['phpgw_info']['user']['preferences']['common']['lang'];
+ }
+
+ $lang_select_date = lang('select date');
+ $lang_from = lang('from');
+ $lang_to = lang('to');
+ $lang_remove = lang('remove date');
+
+ if ($GLOBALS['phpgw_info']['flags']['currentapp'] ==
'bookingfrontend')
+ {
+ $html = 'var html = "<div
class=\'date-container\'>"+
+ "<a class=\'close-btn btnclose\'
href=\'javascript:void(0);\'>' . $lang_remove . '</a>"+
+ "<dt><label
for=\'new_start_date_"+this.counter+"\'>' . $lang_from . '</label></dt>"+
+ "<dd><input class=\'new_datepicker time\'
name=\'from_[]\' id=\'new_start_date_"+this.counter+"\' type=\'text\'>"+
+ "</input></dd>"+
+ "<dt><label for=\'new_end_date_"+this.counter+"\'
>' . $lang_to . '</label></dt>"+
+ "<dd><input class=\'new_datepicker time\'
name=\'to_[]\' id=\'new_end_date_"+this.counter+"\' type=\'text\'>"+
+ "</input></dd>"+
+ "</div>"';
+ }
+ else
+ {
+ $html = 'var html = "<div
class=\'date-container\'>"+
+ "<a class=\'close-btn
btnclose\' href=\'javascript:void(0);\'>-</a>"+
+ "<div
class=\'pure-control-group\'>"+
+ "<label
for=\'new_start_date_"+this.counter+"\'><h4>' . $lang_from . '</h4></label>"+
+ "<input
class=\'new_datepicker time pure-input-2-3\' name=\'from_[]\'
id=\'new_start_date_"+this.counter+"\' type=\'text\'>"+
+ "</input>"+
+ "</div>"+
+ "<div
class=\'pure-control-group\'>"+
+ "<label
for=\'new_end_date_"+this.counter+"\' ><h4>' . $lang_to . '</h4></label>"+
+ "<input
class=\'new_datepicker time pure-input-2-3\' name=\'to_[]\'
id=\'new_end_date_"+this.counter+"\' type=\'text\'>"+
+ "</input>"+
+ "</div>"+
+ "</div>"';
+ }
+
+// echo $html;
+// exit();
+
+ $datepicker = $_type == 'time' ? false : true;
+ $timepicker = $_type == 'date' ? false : true;
+
+ $js = <<<JS
+
+ $(function() {
+
+ var logic = function( currentDateTime ){
+ console.log(currentDateTime);
+
+ };
+
+ $.each($('.newaddedpicker'), function(i, v)
+ {
+ var id = v.id;
+ v.classList.remove('newaddedpicker');
+
+ $( "#"+id ).datetimepicker({
+ format: '{$dateformat}',
+ datepicker:{$datepicker},
+ timepicker: {$timepicker},
+ step: 15,
+ weeks: true,
+ dayOfWeekStart:1,
+ minDate:0,
+// onChangeDateTime:logic
+ });
+ });
+
+ $('#add-date-link').click(function(){
+ var add = $(this);
+ var html = '';
+
+ this.counter =
$('.date-container').length - 1;
+
+ if (!this.counter) { this.counter = 0; }
+
+ {$html}
+
+
add.parent().parent().children('#dates-container').append(html);
+
+ $( ".new_datepicker" ).datetimepicker(
+ {
+ format: '{$dateformat}',
+ datepicker:{$datepicker},
+ timepicker: {$timepicker},
+ step: 15,
+ weeks: true,
+ dayOfWeekStart:1,
+ minDate:0,
+ onChangeDateTime:logic
+ });
+ this.counter++;
+ });
+ });
+
+ $(document).on("click",".btnclose",function(){
+ var the = $(this);
+ RemoveDate(the);
+ });
+
+ RemoveDate = function(the){
+ the.parent().remove();
+ }
+
+JS;
+ $GLOBALS['phpgw']->js->add_code('', $js);
+ }
}
\ No newline at end of file
Modified: trunk/booking/inc/class.uicompleted_reservation.inc.php
===================================================================
--- trunk/booking/inc/class.uicompleted_reservation.inc.php 2016-10-28
12:31:15 UTC (rev 15909)
+++ trunk/booking/inc/class.uicompleted_reservation.inc.php 2016-10-28
12:32:18 UTC (rev 15910)
@@ -124,7 +124,7 @@
return $this->export();
}
- $GLOBALS['phpgw']->jqcal->add_listener('filter_to');
+ $GLOBALS['phpgw']->jqcal2->add_listener('filter_to');
phpgwapi_jquery::load_widget('datepicker');
self::add_javascript('booking', 'booking',
'completed_reservation.js');
Modified: trunk/booking/inc/class.uicompleted_reservation_export.inc.php
===================================================================
--- trunk/booking/inc/class.uicompleted_reservation_export.inc.php
2016-10-28 12:31:15 UTC (rev 15909)
+++ trunk/booking/inc/class.uicompleted_reservation_export.inc.php
2016-10-28 12:32:18 UTC (rev 15910)
@@ -99,7 +99,7 @@
$this->generate_files();
}
- $GLOBALS['phpgw']->jqcal->add_listener('filter_to');
+ $GLOBALS['phpgw']->jqcal2->add_listener('filter_to');
phpgwapi_jquery::load_widget('datepicker');
self::add_javascript('booking', 'booking',
'completed_reservation_export.js');
Modified: trunk/booking/inc/class.uievent.inc.php
===================================================================
--- trunk/booking/inc/class.uievent.inc.php 2016-10-28 12:31:15 UTC (rev
15909)
+++ trunk/booking/inc/class.uievent.inc.php 2016-10-28 12:32:18 UTC (rev
15910)
@@ -581,8 +581,8 @@
$date['to_'] = pretty_timestamp($date['to_']);
}
- $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('start_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('end_date',
'datetime');
$tabs = array();
$tabs['generic'] = array('label' => lang('Event New'),
'link' => '#event_new');
@@ -990,8 +990,8 @@
$event['from_'] = pretty_timestamp($event['from_']);
$event['to_'] = pretty_timestamp($event['to_']);
- $GLOBALS['phpgw']->jqcal->add_listener('from_',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('to_',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('from_',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('to_',
'datetime');
phpgwapi_jquery::load_widget('datepicker');
Modified: trunk/booking/inc/class.uireports.inc.php
===================================================================
--- trunk/booking/inc/class.uireports.inc.php 2016-10-28 12:31:15 UTC (rev
15909)
+++ trunk/booking/inc/class.uireports.inc.php 2016-10-28 12:32:18 UTC (rev
15910)
@@ -167,8 +167,8 @@
$entry['selected'] = $entry['id'] ==
$report['variable_vertical'] ? 1 : 0;
}
- $GLOBALS['phpgw']->jqcal->add_listener('start_date');
- $GLOBALS['phpgw']->jqcal->add_listener('end_date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('start_date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('end_date');
$tabs = array();
$tabs['generic'] = array('label' => lang('Report New'),
'link' => '#report_new');
@@ -600,8 +600,8 @@
phpgwapi_cache::message_set($errors, 'error');
- $GLOBALS['phpgw']->jqcal->add_listener('from', 'date');
- $GLOBALS['phpgw']->jqcal->add_listener('to', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('from', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('to', 'date');
$tabs = array();
$tabs['generic'] = array('label' => lang('Report
Participants'), 'link' => '#report_part');
@@ -668,8 +668,8 @@
phpgwapi_cache::message_set($errors, 'error');
//$this->flash_form_errors($errors);
- $GLOBALS['phpgw']->jqcal->add_listener('from', 'date');
- $GLOBALS['phpgw']->jqcal->add_listener('to', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('from', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('to', 'date');
$tabs = array();
$tabs['generic'] = array('label' => lang('Report
FreeTime'), 'link' => '#report_freetime');
Modified: trunk/booking/inc/class.uiseason.inc.php
===================================================================
--- trunk/booking/inc/class.uiseason.inc.php 2016-10-28 12:31:15 UTC (rev
15909)
+++ trunk/booking/inc/class.uiseason.inc.php 2016-10-28 12:32:18 UTC (rev
15910)
@@ -191,8 +191,8 @@
$season['resources_json'] =
json_encode(array_map('intval', $season['resources']));
$season['cancel_link'] = self::link(array('menuaction'
=> 'booking.uiseason.index'));
- $GLOBALS['phpgw']->jqcal->add_listener('from_', 'date');
- $GLOBALS['phpgw']->jqcal->add_listener('to_', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('from_',
'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('to_', 'date');
$tabs = array();
$tabs['generic'] = array('label' => lang('Season New'),
'link' => '#season_new');
@@ -244,8 +244,8 @@
$season['cancel_link'] = self::link(array('menuaction'
=> 'booking.uiseason.show',
'id' => $season['id']));
- $GLOBALS['phpgw']->jqcal->add_listener('from_', 'date');
- $GLOBALS['phpgw']->jqcal->add_listener('to_', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('from_',
'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('to_', 'date');
$tabs = array();
$tabs['generic'] = array('label' => lang('Season
Edit'), 'link' => '#season_new');
@@ -349,8 +349,8 @@
$boundary['to_'] = "{$to_arr[0]}:{$to_arr[1]}";
}
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'time');
- $GLOBALS['phpgw']->jqcal->add_listener('field_to',
'time');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_from',
'time');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_to',
'time');
self::render_template('season_boundaries',
array('boundary' => $boundary, 'boundaries' => $boundaries,
'season' => $season));
@@ -541,8 +541,8 @@
$to = pretty_timestamp($season['to_']);
$interval = 1;
- $GLOBALS['phpgw']->jqcal->add_listener('from_', 'date');
- $GLOBALS['phpgw']->jqcal->add_listener('to_', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('from_',
'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('to_', 'date');
if ($_SERVER['REQUEST_METHOD'] == 'POST')
{
@@ -580,8 +580,8 @@
$this->flash_form_errors($errors);
- /* $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'date');
- $GLOBALS['phpgw']->jqcal->add_listener('field_to',
'date');
+ /*
$GLOBALS['phpgw']->jqcal2->add_listener('field_from', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_to',
'date');
$tabs = array();
$tabs['generic'] = array('label' => lang('Season'),
'link' => '#season_generate');
Modified: trunk/bookingfrontend/inc/class.uiallocation.inc.php
===================================================================
--- trunk/bookingfrontend/inc/class.uiallocation.inc.php 2016-10-28
12:31:15 UTC (rev 15909)
+++ trunk/bookingfrontend/inc/class.uiallocation.inc.php 2016-10-28
12:32:18 UTC (rev 15910)
@@ -125,7 +125,7 @@
$allocation['from_'] =
pretty_timestamp($allocation['from_']);
$allocation['to_'] =
pretty_timestamp($allocation['to_']);
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
self::rich_text_editor('field-message');
self::render_template_xsl('allocation_cancel',
array('allocation' => $allocation));
@@ -322,7 +322,7 @@
$allocation['from_'] =
pretty_timestamp($allocation['from_']);
$allocation['to_'] =
pretty_timestamp($allocation['to_']);
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
if ($step < 2)
{
Modified: trunk/bookingfrontend/inc/class.uibooking.inc.php
===================================================================
--- trunk/bookingfrontend/inc/class.uibooking.inc.php 2016-10-28 12:31:15 UTC
(rev 15909)
+++ trunk/bookingfrontend/inc/class.uibooking.inc.php 2016-10-28 12:32:18 UTC
(rev 15910)
@@ -270,9 +270,9 @@
$res_names[] = array('id' => $res['id'], 'name'
=> $res['name']);
}
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'time');
- $GLOBALS['phpgw']->jqcal->add_listener('field_to',
'time');
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_from',
'time');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_to',
'time');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
$booking['from_'] = pretty_timestamp($booking['from_']);
$booking['to_'] = pretty_timestamp($booking['to_']);
@@ -517,10 +517,10 @@
'active' => 1)));
$groups = $groups['results'];
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('field_to',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_from',
'datetime');
+ $GLOBALS['phpgw']->jqcal2->add_listener('field_to',
'datetime');
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
$booking['from_'] = pretty_timestamp($booking['from_']);
$booking['to_'] = pretty_timestamp($booking['to_']);
@@ -853,7 +853,7 @@
$booking['from_'] =
pretty_timestamp($booking['from_']);
$booking['to_'] =
pretty_timestamp($booking['to_']);
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
$booking['resources_json'] =
json_encode(array_map('intval', $booking['resources']));
$this->flash_form_errors($errors);
@@ -1111,7 +1111,7 @@
$booking['booking_link'] =
self::link(array('menuaction' => 'bookingfrontend.uibooking.show',
'id' => $booking['id']));
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+
$GLOBALS['phpgw']->jqcal2->add_listener('field_repeat_until', 'date');
if ($step < 2)
{
Modified: trunk/bookingfrontend/inc/class.uievent.inc.php
===================================================================
--- trunk/bookingfrontend/inc/class.uievent.inc.php 2016-10-28 12:31:15 UTC
(rev 15909)
+++ trunk/bookingfrontend/inc/class.uievent.inc.php 2016-10-28 12:32:18 UTC
(rev 15910)
@@ -166,8 +166,8 @@
$event['from_2'] = date("H:i",
phpgwapi_datetime::date_to_timestamp($event['from_']));
$event['to_2'] = date("H:i",
phpgwapi_datetime::date_to_timestamp($event['to_']));
- $GLOBALS['phpgw']->jqcal->add_listener('from_', 'time');
- $GLOBALS['phpgw']->jqcal->add_listener('to_', 'time');
+ $GLOBALS['phpgw']->jqcal2->add_listener('from_',
'time');
+ $GLOBALS['phpgw']->jqcal2->add_listener('to_', 'time');
phpgwapi_jquery::load_widget('datepicker');
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
Modified: trunk/bookingfrontend/templates/base/application_new.xsl
===================================================================
--- trunk/bookingfrontend/templates/base/application_new.xsl 2016-10-28
12:31:15 UTC (rev 15909)
+++ trunk/bookingfrontend/templates/base/application_new.xsl 2016-10-28
12:32:18 UTC (rev 15910)
@@ -301,6 +301,7 @@
</input>
</dd>
</div>
+
<!--div id="dtBox"></div-->
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [15910] booking: change to alternative datetimepicker,
sigurdne <=