修复了数据版本删除时提示错误的bug

This commit is contained in:
Li Jianxuan 2012-06-12 01:49:51 +00:00
parent 33a8c86f49
commit f806355673
2 changed files with 5 additions and 5 deletions

View File

@ -1740,11 +1740,11 @@ class Admin_DataController extends Zend_Controller_Action
if($ex) if($ex)
{ {
$data = array("deleted"=>$id,"error"=>$this->alertbox('ok','删除成功')); $data = array("deleted"=>$id, "error"=>"删除成功");
$this->jsonexit($data); $this->jsonexit($data);
return true; return true;
}else{ }else{
$data = array("error"=>$this->alertbox('error','删除失败,请确认权限后重试')); $data = array("error"=>'删除失败,请确认权限后重试');
$this->jsonexit($data); $this->jsonexit($data);
return true; return true;
} }
@ -1752,7 +1752,7 @@ class Admin_DataController extends Zend_Controller_Action
$msg = "删除失败,请确认权限后重试"; $msg = "删除失败,请确认权限后重试";
if($this->debug>0) if($this->debug>0)
{$msg .= $e->getMessage();} {$msg .= $e->getMessage();}
$data = array("error"=>$this->alertbox('error',$msg)); $data = array("error"=>$msg);
$this->jsonexit($data); $this->jsonexit($data);
return true; return true;
} }

View File

@ -77,12 +77,12 @@ function action(ac,id){
{$('#changelog').val('');$('#commit_submit').attr('onclick','');} {$('#changelog').val('');$('#commit_submit').attr('onclick','');}
} }
else{ else{
$.colorbox({'innerWidth':'50%','html':'<img src="/images/alert_big_warning.png" /><h4>出现错误,请稍候再试</h4>'}); $.colorbox({'innerWidth':'50%','html':'<h4>出现错误,请稍候再试</h4>'});
} }
}, },
'timeout': 30000, 'timeout': 30000,
'error': function(){ 'error': function(){
$.colorbox({'innerWidth':'50%','html':'<img src="/images/alert_big_error.png" /><h4>处理中出现错误,请刷新页面后重试</h4>'}); $.colorbox({'innerWidth':'50%','html':'<h4>处理中出现错误,请刷新页面后重试</h4>'});
} }
}); });
} }