Javascript JQGrid-弹出框ok时的td标题更改
我在Javascript JQGrid-弹出框ok时的td标题更改,javascript,jquery,jqgrid,Javascript,Jquery,Jqgrid,我在jqgrid中有可编辑的行。双击文本框,将打开一个弹出框,其中包含文本区域 单击弹出窗口的OK,我需要将textarea值返回到jqgrid行单元格,在该单元格中调用双击 单元格的值位于td的title属性内 我试图使用rowid更改title属性,但jqgrid单元格未反映我的新值 tr='#'+top_id; $(tr).find('td[aria-describedby="Remarks"]').attr('title','txtremark.value'); 它还显示了开发人员工具
jqgrid
中有可编辑的行。双击文本框
,将打开一个弹出框,其中包含文本区域
单击弹出窗口的OK
,我需要将textarea
值返回到jqgrid
行单元格,在该单元格中调用双击
单元格的值位于td
的title
属性内
我试图使用rowid
更改title属性,但jqgrid
单元格未反映我的新值
tr='#'+top_id;
$(tr).find('td[aria-describedby="Remarks"]').attr('title','txtremark.value');
它还显示了开发人员工具中更改的值,即inspect元素。但单元格值不变
我试图在ok上重新加载网格,单击事件,然后,onloadcomplete
网格事件再次设置title
属性。但问题依然存在。
请引导我
I got an answer of this.. On jqgrid's ondblClickRow event I set a title attribute to popup textbox as below.
txtremark.value = $(tr).find('td[aria-describedy="Remarks"]').attr('title');
Then, on Ok button click event i reload jqgrid,
and after that on LoadComplete event again I set attribute of title and also set html of title like,
loadcomplete : function(){
tr ="#" + rowid;
$(tr).find('td[aria-describedy="Remarks"]').attr('title',txtremark.value);
$(tr).find('td[aria-describedy="Remarks"]').html(txtremark.value);
$("divremarks").dialog('close');
});
Its compulsory to set html of td other wise next time you got undefined in popup window.