How to prevent row selection within 1.10 ?

How to prevent row selection within 1.10 ?

VyacheslavVyacheslav Posts: 70Questions: 27Answers: 0

As I dont't have a fnPreRowSelect in Select ext anymore, I'd like to know how to prevent select/deselect events if I click on certain td (namely td.details-control) in ajax-based datatable?

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 61,431Questions: 1Answers: 10,048 Site admin

    Currently you would listen for the select event and check to see if the selected row shouldn't have been selected. If that is the case it would then immediately be deselected (row().deselect()).

    There is no direct analogue of fnPreRowSelect in the Select extension.

    Allan

  • VyacheslavVyacheslav Posts: 70Questions: 27Answers: 0
    edited December 2015

    It's a pity you have eliminated such useful callback as fnPreRowSelect !!!
    All master-detail datatables are based on select/deselect mechanism.
    I don't want to deselect a row (and once again to refresh detail-datatable) I want to prevent a selection ....

    Is there any hope of getting fnPreRowSelect back?

  • allanallan Posts: 61,431Questions: 1Answers: 10,048 Site admin
    Answer ✓

    I'm probably going to add a preSelect event which is cancellable (i.e. return false to prevent the selection). Not entirely sure when I'll get a chance to make that change, but hopefully not too far away.

    Allan

  • VyacheslavVyacheslav Posts: 70Questions: 27Answers: 0

    Great! ... and thanks again Allan!

This discussion has been closed.