How to double-click a row in Datagrid to call a microflow or jump to another page, and pass in the data of the current row?

1
How to double-click a row in Datagrid to call a microflow or jump to another page, and pass in the data of the current row?
asked
3 answers
5

You need to create a button with the realted action and mark the button then as “default button”. Then the action of the button will be used on double-clicking a line in the grid.

answered
1

For anybody who searches for a solution when using Data grid 2 you can use the doubleclick trigger widget (https://marketplace.mendix.com/link/component/117887). If you only use the widget by itself, the double-click action will only be applied to the text itself. So it does not work with clicking on the row, you will have to click right on the text.

I have solved it by adding custom CSS to make the doubleclick-widget fill out the whole cell. For this you have to set the padding of the parent element of doubleclick widget to 0. Then you have to set the desired padding on the doubleclick widget and make it fill out the whole cell.

In my case it looked like this:

.custom-table-class {

    .td.align-column-left {
        padding: 0;

        .widget-doubleclick-clickable {
            padding: 15px 14px 15px;
            height: 100%;
            width: 100%;
        }

    }

}

Since it gets rid of the padding of all the cells, you have to manually adjust the padding for other cells again, which do no have the doubleclick widget.

 

Hope it helps!

 

answered
0

just set “is default button” to yes, if you want to set that particular button as “double click” action.

answered