修正主子表情况下,子表点击删除按钮,但不点击确认删除,保存之后仍会删除

https://gitee.com/thinkgem/jeesite4/issues/IRDVT
This commit is contained in:
thinkgem
2019-01-24 21:07:08 +08:00
parent 038e89316a
commit 727c2fcf3c
2 changed files with 2 additions and 2 deletions

View File

@@ -140,7 +140,7 @@ if (table.tplCategory != 'query'){
if (val == 'new'){
actions.push('<a href="#" onclick="js.confirm(\'\${text("你确认要删除这条数据吗?")}\', function(){$(\'#${@StringUtils.uncap(child.className)}DataGrid\').dataGrid(\'delRowData\',\''+obj.rowId+'\')});return false;"><i class="fa fa-trash-o"></i></a>&nbsp;');
}else{
actions.push('<a href="#" onclick="js.confirm(\'\${text("你确认要删除这条数据吗?")}\', function(){$(\'#${@StringUtils.uncap(child.className)}DataGrid\').dataGrid(\'setRowData\',\''+obj.rowId+'\',null,{display:\'none\'})});$(\'#'+obj.rowId+'_status\').val(\''+Global.STATUS_DELETE+'\');return false;"><i class="fa fa-trash-o"></i></a>&nbsp;');
actions.push('<a href="#" onclick="js.confirm(\'\${text("你确认要删除这条数据吗?")}\', function(){$(\'#${@StringUtils.uncap(child.className)}DataGrid\').dataGrid(\'setRowData\',\''+obj.rowId+'\',null,{display:\'none\'});$(\'#'+obj.rowId+'_status\').val(\''+Global.STATUS_DELETE+'\');});return false;"><i class="fa fa-trash-o"></i></a>&nbsp;');
}
return actions.join('');
}, editoptions: {defaultValue: 'new'}}