16
Views
5
Comments
Solved
Editable Table Default Delete Button Always Removes Row From UI Element

Hi, I have an editable table and I have disabled the "Delete Confirmation" property because the default browser confirmation is not visually pleasing.

I have set the Editable Table's "On Row Delete" property to a "Screen Action" that toggles a modal (custom delete confirmation modal) however, I have found that the Editable Table's default delete button still "deletes" a row from the editable table. This "delete" is only visual, it does not delete from the actual database, the row is returned upon page refresh.

How can I stop the Editable Table's delete button from visually removing a row and set it to only toggle my delete confirmation modal, which would then delete the row in the widget and database?

Rank: #68
Solution

Hi Justin,


I don't think you can change this behavior of editable table widget. I would do it with a list / table and take advantage of ListAppend and ListRemove actions to add and remove rows from the list / table.


Kind regards,

João



Rank: #41917

Hi Joao,

Thanks for your help. It seems to be impossible as of now. I have decided to live with the behavior of the editable table. I have added an ajax refresh function to my algorithm so that the table is refreshed when the user clicks "delete cancel" so that it appears that the row was not deleted.

I was hoping that someone knew a javascript function / extended property to use to change the editable table's behavior.

mvp_badge
MVP
Rank: #75

Hi Justin,

I had just tried an implementation using JavaScript + workaround for the mentioned use-case. I would highly suggest and prefer João solution to be considered as the final implementation for this use-case. Purpose for the post is to just share what I have tired :)

See this sample app | EditableTableTask

Refer the attached .oml file (See the footer placeholder for JS code)


Kind regards,

Benjith Sam

TWALabEditableTableTask.oml

Rank: #41917

Hi Benjith,

This is great!!! Thanks for your help.

mvp_badge
MVP
Rank: #75

You're welcome, Justin.

Glad to help you :)


Kind regards,

Benjith Sam