Hi Tom, Option 1) use AjaxCallListener#precondition to check whether the JS event target is <select> and return false in that case Option 2) add click listener on the dropdown and suppress event bubbleing
Martin Grigorov Wicket Training and Consulting https://twitter.com/mtgrigorov On Wed, Feb 17, 2016 at 3:16 PM, Tom Götz <[email protected]> wrote: > > Hi there, > > I have a DataTable where rows are clickable and open a detail page when > clicked. No problem so far. > > But: in one column I have a (Bootstrap) dropdown which won’t open any more > because the row’s click handler is too greedy and the dropdown won’t > receive the click event. > > I added the row’s click behavior like that in my DataTable impl: > > protected Item<T> newRowItem(String id, int index, IModel<T> model) { > Item<T> item = super(newRowItem(id, index, model); > item.add(new AjaxEventBehavior(„click“) { > @Override > protected void onEvent(AjaxRequestTarget target) { > // ... > } > } > } > > Anything I can do about that? > > Cheers, > Tom > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
