EasyUI Forum
May 16, 2024, 09:02:55 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: edit row at edatagrid  (Read 10174 times)
jaimi
Full Member
***
Posts: 119


View Profile
« on: September 09, 2012, 02:19:17 AM »

I created a toolbar with several buttons like this:

<a href="#" class="easyui-linkbutton" iconCls="icon-add" plain="true"
onclick="javascript:$(\'#dag_project\').edatagrid(\'addRow\')">zuf&uuml;gen</a>
<a href="#" class="easyui-linkbutton" iconCls="icon-edit" plain="true"
onclick="javascript:$(\'#dag_project\').edatagrid(\'editRow\')">&auml;ndern</a>

The Update (edit) button does not work. I can only edit a row by double clicking on the row within the edatagrid.
What/where I have to modify?
Logged
stworthy
Administrator
Hero Member
*****
Posts: 3581


View Profile Email
« Reply #1 on: September 09, 2012, 03:18:25 AM »

When calling the 'editRow' to edit a row, the 'index' parameter must be passed to indicate what row will be edited. For example, running the code below will begin editing the third row(the row index start with 0).

$('#dag_project').edatagrid('editRow', 2);
Logged
jaimi
Full Member
***
Posts: 119


View Profile
« Reply #2 on: September 10, 2012, 03:07:10 AM »

Thanks, I found where to set it.
Logged
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!