Sha256: 2f87e68b0bbebd01cbc1fd7dd0983638a0aefc33f2df0fe44317e9542f71885e
Contents?: true
Size: 706 Bytes
Versions: 10
Compression:
Stored size: 706 Bytes
Contents
//= require jquery.xdan.datetimepicker.full $(function() { setupDateTimePicker(document); $(document).on('has_many_add:after', '.has_many_container', function(event, fieldset) { return setupDateTimePicker(fieldset); }); function setupDateTimePicker(container) { var defaults, entries; defaults = { formatDate: 'y-m-d', format: 'Y-m-d H:i', allowBlank: true, defaultSelect: false, validateOnBlur: false }; entries = $(container).find('input.date-time-picker'); return entries.each(function(index, entry) { var options = $(entry).data('picker-options'); return $(entry).datetimepicker($.extend(defaults, options)); }); } });
Version data entries
10 entries across 10 versions & 1 rubygems