delete confirmed row
delete confirmed row
![alex9134](https://secure.gravatar.com/avatar/e7d2d28d0f9c5c8c901fa2e33cdafcec/?default=https%3A%2F%2Fvanillicon.com%2Fe7d2d28d0f9c5c8c901fa2e33cdafcec_200.png&rating=g&size=120)
i need to select a row to delete.the actual delete row depends on the user confirming removal of alertid which resides in column 2 of the tabe. how do I do that? i tried using table.row() functions but i think that functionality depends on installing editor functions. Am I correct?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
No it does not. Your delete button on the data table just needs to execute a confirmation dialog. If the use confirms, use the table.row() stuff to delete.
After the delete, you need to redraw the table for the row to disappear.
Yep, as @bindrid said, it's not dependent on Editor. Just use
row().remove()
to remove,Cheers,
Colin
do you have examples of confirm delete?
Sorry, no. That's the vanilla JS part - so you could google that.
You will have to research how to do a modal for the client side foundation you are using (jQuery UI, Bootstrap, or what ever).
or you can fall back to the built-in confirm dialog.