Skip to content

Instantly share code, notes, and snippets.

@maecha
Created April 3, 2018 07:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maecha/a8d9110f3c3b7d501d82afc73005cdfd to your computer and use it in GitHub Desktop.
Save maecha/a8d9110f3c3b7d501d82afc73005cdfd to your computer and use it in GitHub Desktop.
How to use TimePicker in AdminLTE ver2 (with Bootstrap 3.3.6)
:
:
//= require admin-lte/plugins/timepicker/bootstrap-timepicker.min
$(document).ready ->
$('#hogeTimePicker').timepicker({
showMeridian: false,
defaultTime: false,
minuteStep: 1,
maxHours: 24
});
= form_for @hoge, url: hoges_path do |f|
= f.text_field :time,
id: 'hogeTimePicker',
class: 'form-control timepicker',
placeholder: '7:00'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment