先上效果图吧:
查询列表:
添加modal:
修改modal和添加modal采用同一个,区别是在修改的时候对modal进行赋值,后端保存时采用hibernate saveOrupdate:
js代码:
function operateFormatter(value, row, index) //row 获取这行的值 ,index 获取索引值 { return [ '<a class="edit" href="javascript:void(0)" title="edit">'