$ ->
  if ($('#vehicletrace-search-page').length > 0)

    $("select").selectpicker({ title: '...' })

    $("#search-vehicletrace-button").click ->
      data = $("#search-vehicletrace-form").serialize()
      $.fn.yiiGridView.update('vehicle-trace-grid', {
        data: data
      })
      false


    $('#search-time-start').timepicker
      minuteStep: 10,
      template: 'modal',
      appendWidgetTo: 'body',
      showSeconds: false,
      showMeridian: false,
      defaultTime: false

    $('#search-time-end').timepicker
      minuteStep: 10,
      template: 'modal',
      appendWidgetTo: 'body',
      showSeconds: false,
      showMeridian: false,
      defaultTime: false
