When a grid row in Ligerui-js is modified, why is the Save event not executed? (Resolved)
(1)
(2) The following code is written above the grid
function Itemclick1 (item) {var editingrow = Grid.geteditingrow (); Switch (item.text) {case "add": if (Editingrow = = null) {GRID.ADDEDITR ow (); } else {Lg.tip (' please submit or Cancel first '); } break; Case "Modified": var selected = grid.getselected (); if (Editingrow = = null) {BeginEdit ()} else {Lg.tip ("Please submit or cancel the repair first Change "); } break; Case "Save": if (editingrow! = null) {alert ("Save 11"); Grid.endedit (Editingrow); } else {Lg.tip (' not currently in edit State '); } break; Case "Cancel": if (editingrow! = null) {Grid.canceledit (editingrow); } else {Lg.tip (' not in edit state now! '); } break; Case "Delete": $.ligerdialog.confirm (' OK delete? ', function (confirm) {if (confirm) F_delete (grid, 1); }); Break Case "action button": break; }}//load toolbar var toolbarOptions1 = {items: [{text: ' Add ', Click:itemclick1, IMG: ".. /lib/icons/silkicons/add.png "}, {line:true}, {text: ' Modify ', Click:itemclick1, img:". ./lib/icons/miniicons/page_edit.gif "}, {line:true}, {text: ' Save ', Click:itemclick1, img:". /lib/icons/silkicons/page_save.png "}, {line:true}, {text: ' Cancel ', Click:itemclick1, IMG: ". /lib/icons/silkicons/cancel.png "}, {line:true}, {text: ' delete ', Click:itemclick1, img:". /lib/Icons/miniicons/page_delete.gif "}]};
(3You must write the code, otherwise you cannot enter (add, modify) Save method
Toolbar event function Toolbarbtnitemclick (item) {var editingrow = Grid.geteditingrow (); Switch (item.id) {case "add"://top.f_addtab (NULL, ' Add role info ', ' membermanage/roledetail.aspx ') ); if (Editingrow = = null) {Addnewrow (); } else {Lg.tip (' please submit or cancel the modification first '); } break; Case "View": var selected = grid.getselected (); if (!selected) {lg.tip (' Please select line! '); return} break; Case "Modify": var selected = grid.getselected (); if (!selected) {lg.tip (' Please select line! '); return}//top.f_addtab (null, ' Modify role information ', ' membermanage/roledetail.aspx?i D= ' + selected. Roleid); if (Editingrow = = null) {BeginEdit (); } else {Lg.tip (' please submit or cancel the modification first '); } Break Case "Delete": jQuery.ligerDialog.confirm (' OK delete? ', function (confirm) {if (Confirm ) F_delete (); }); Break Case "Save": if (editingrow! = null) {Grid.endedit (editingrow); } else {Lg.tip (' not in edit state now! '); } break; Case "Cancel": if (editingrow! = null) {Grid.canceledit (editingrow); } else {Lg.tip (' not in edit state now! '); } break; } }