EasyUI Forum
November 06, 2025, 01:20:59 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: cannot get editor in datagrid  (Read 9926 times)
Opan Mustopah
Full Member
***
Posts: 164


Indonesia


View Profile Email
« on: December 13, 2014, 12:14:36 AM »

hello again,

now i have a problem with get the editor on datagrid. when datagrid row  is empty, the result when i try to get the editor for specific field always null. here my code:
Code:
onBeforeEdit: function(rowIndex, rowData){
rowData.editing = true;
updateActions(rowIndex, $list_data);
loadLinkbutton(this);
state.op = "edit";
var editor = $(this).datagrid('getEditor',{index:rowIndex,field:'shipper_address_det'});
console.log(editor);  // ==> this value always null;
console.log(rowIndex);
//alert('op');

},


i already read the document. but i think i do what exactly document said. where is the problem in my code?

thanks for helping

Logged

-- Bajak Otak --
*** Sorry for my bad english :3 ***
--JeasyUI version 1.4--
jarry
Administrator
Hero Member
*****
Posts: 2300


View Profile Email
« Reply #1 on: December 13, 2014, 12:55:50 AM »

You can not get any editors in the 'onBeforeEdit' event since the row does not go into edit mode.
Logged
Opan Mustopah
Full Member
***
Posts: 164


Indonesia


View Profile Email
« Reply #2 on: December 13, 2014, 01:06:36 AM »

yeah my false, i should use onBeginEdit event, so editor was created and then i can get the editor Cheesy

thanks jarry
Logged

-- Bajak Otak --
*** Sorry for my bad english :3 ***
--JeasyUI version 1.4--
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!