jqGrid-单击行删除altclass和悬停 [英] jqGrid - clicking on row removes altclass and hoverrows

查看:138
本文介绍了jqGrid-单击行删除altclass和悬停的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们使用设置了altclasshoverrows:true的jqGrid.当您单击一行时,将不再应用altclass类,并且悬停效果也不再对单击的行起作用.您如何阻止这种情况的发生?

We use jqGrid with altclass set and with hoverrows:true. When you click on a row, the altclass class is no longer applied and the hover effect no longer works on the clicked row. How can you stop this from happening?

推荐答案

您可以将自定义代码添加到onSelectRow事件中,以防止单击时突出显示该行.例如:

You could add custom code to the onSelectRow event to prevent the row from being highlighted when clicked. For example:

onSelectRow: function(id){
    jQuery(myGrid).resetSelection();
} 

这篇关于jqGrid-单击行删除altclass和悬停的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆