Restrict selectable hours for DateTime field in Editor

Restrict selectable hours for DateTime field in Editor

epoch1epoch1 Posts: 17Questions: 8Answers: 1
edited March 2017 in Editor

Hi,

I've decided to re-write my question as I managed to fix my inital problem - it's amazing what happens when you read the documentation properly!

Can anyone tell me if it's possible to restrict the selectbale hours via the dateTime field time picker please?

Something like:

editor = new $.fn.dataTable.Editor( {
...

                    enabledHours: [8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20],
...

Thanks.

This question has an accepted answers - jump to answer

Answers

  • epoch1epoch1 Posts: 17Questions: 8Answers: 1

    Sorry, I've just noticed that these may be two different components? datetime/datetimepicker. If so how can acheive what I'm trying to do with minDate and enabledHours?

  • allanallan Posts: 63,516Questions: 1Answers: 10,472 Site admin
    Answer ✓

    I'm afraid that there is currently no option to restrict the hows that can be selected in Editor. To be honest, I think this is the first time I've come across such a request - but its a good one. I'll look at adding that into Editor.

    Thanks for the suggestion!

    Allan

  • epoch1epoch1 Posts: 17Questions: 8Answers: 1

    Thanks Allan,

    No problem, I can get by without that feature for now.

This discussion has been closed.