activeadmin-plugins / active_admin_scoped_collection_actions

:muscle: Plugin for ActiveAdmin. Provides batch Update and Delete for scoped_collection (Filters + Scope) across all pages.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

support for active_admin_datetimepicker

Fivell opened this issue · comments

The easiest way is to handle opened event and replace default datepicker. Example

$(document).ready ->
  $('body').on 'mass_update_modal_dialog:after_open', (e, form) ->
    $(form).find('input.datepicker').removeClass('datepicker').addClass('date-time-picker')
    setupDateTimePicker form

@workgena , why replace? What if there are several inputs one with date and another with date time .
I mean maybe it is possible to handle it there https://github.com/workgena/active_admin_scoped_collection_actions/blob/master/vendor/assets/javascripts/lib/dialog_mass_fields_update.js.coffee#L4

Close it for now.
Feel free to open it again, if current solution wouldn't work for you.