Merge 20b4cbf1f2 into 80f63c7263
This commit is contained in:
commit
163bfe7eae
2 changed files with 12 additions and 3 deletions
|
|
@ -1,10 +1,19 @@
|
||||||
$(function () {
|
$(function () {
|
||||||
$("#registration-arrival-datepicker, #registration-departure-datepicker").datetimepicker({
|
$("#registration-arrival-datepicker").datetimepicker({
|
||||||
pickTime: true,
|
pickTime: true,
|
||||||
useCurrent: false,
|
useCurrent: false,
|
||||||
minuteStepping: 15,
|
minuteStepping: 15,
|
||||||
sideBySide: true,
|
sideBySide: true,
|
||||||
format: "YYYY-MM-DD HH:mm"
|
format: "YYYY-MM-DD HH:mm",
|
||||||
|
defaultDate : $("#registration-arrival-datepicker").attr('start_date')
|
||||||
|
});
|
||||||
|
$("#registration-departure-datepicker").datetimepicker({
|
||||||
|
pickTime: true,
|
||||||
|
useCurrent: false,
|
||||||
|
minuteStepping: 15,
|
||||||
|
sideBySide: true,
|
||||||
|
format: "YYYY-MM-DD HH:mm",
|
||||||
|
defaultDate : $("#registration-arrival-datepicker").attr('end_date')
|
||||||
});
|
});
|
||||||
|
|
||||||
$("#registration-arrival-datepicker").on("dp.change",function (e) {
|
$("#registration-arrival-datepicker").on("dp.change",function (e) {
|
||||||
|
|
|
||||||
|
|
@ -4,5 +4,5 @@
|
||||||
=f.inputs 'Pre-registration required for the following:' do
|
=f.inputs 'Pre-registration required for the following:' do
|
||||||
= f.input :events, as: :check_boxes, label: false, collection: @conference.program.events.workshops
|
= f.input :events, as: :check_boxes, label: false, collection: @conference.program.events.workshops
|
||||||
= f.inputs 'Your Travel Info' do
|
= f.inputs 'Your Travel Info' do
|
||||||
= f.input :arrival, as: :string, label: 'Your arrival time', input_html: { value: (f.object.arrival.to_formatted_s(:db_without_seconds) unless f.object.arrival.nil?), id: 'registration-arrival-datepicker', readonly: 'readonly' }
|
= f.input :arrival, as: :string, label: 'Your arrival time', input_html: { value: (f.object.arrival.to_formatted_s(:db_without_seconds) unless f.object.arrival.nil?), id: 'registration-arrival-datepicker',start_date: @conference.start_date,end_date: @conference.end_date, readonly: 'readonly' }
|
||||||
= f.input :departure, as: :string, label: 'Your departure time', input_html: { value: (f.object.departure.to_formatted_s(:db_without_seconds) unless f.object.departure.nil?), id: 'registration-departure-datepicker', readonly: 'readonly' }
|
= f.input :departure, as: :string, label: 'Your departure time', input_html: { value: (f.object.departure.to_formatted_s(:db_without_seconds) unless f.object.departure.nil?), id: 'registration-departure-datepicker', readonly: 'readonly' }
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue