Hi Manfred, Hi Martin,

Unfortunately this part does not rely on the integration but on kendo-ui
itself, so I'm afraid we have to hack a bit :(

Changing the href attribute should be done when data are loaded, the idea
is to identify buttons with a special css class and update the href on
databound event.
Something like that:

private CommandButton btnEdit = new CommandButton("_edit",
Model.of("Edit")) {

    private static final long serialVersionUID = 1L;

    @Override
    public String getCSSClass()
    {
        return "link-to-change";
    }
};


class MyDataTable {

protected void onInitialize()
{
    super.onInitialize();

    this.add(new DataBoundBehavior() {

        private static final long serialVersionUID = 1L;

        @Override
        protected String getDataBoundCallback()
        {
            return "function (e) { "
                    + "    jQuery('.link-to-change').each("
                    + "        function(index, item) { "
                    + "            jQuery(item).attr('href',
'javascript:;'); "
                    + "        }"
                    + "    )"
                    + "}";
        }
    });
}
}

There should be a way to have a generic Behavior, like
NoHashSymbolOnButtonsDataBoundBehavior (yes, I'm pretty imaginative tonight)
Please open en issue on github :)

Best regards,
Sebastien.

Reply via email to