javascript jqgrid 是编辑模式下的行
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/5078948/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
jqgrid is row in edit mode
提问by user590586
Is there a way to know if a row inside the jqgrid is in edit mode?
有没有办法知道 jqgrid 中的一行是否处于编辑模式?
Thank's In Advance.
提前致谢。
回答by Oleg
If you speak about rows in inline editing mode than you can vertify whether row (<tr>element) has attribute editable="1". The attribute will be set ba jqGrid for all rows which are in the editing mode. So the code could be
如果您在内联编辑模式下谈论行,则可以验证行(<tr>元素)是否具有属性editable="1"。该属性将为所有处于编辑模式的行设置为 ba jqGrid。所以代码可以是
if ($("tr#"+rowid).attr("editable") === "1") {
// the row having id=rowid is in editing mode
}
or
或者
$($("#list").jqGrid("getInd",rowid,true)).attr("editable") === "1") {
// the row having id=rowid is in editing mode
}

