修复专家拒绝功能
This commit is contained in:
parent
5432058cdf
commit
814cee43bc
|
@ -535,7 +535,8 @@ class ReviewController extends Zend_Controller_Action
|
|||
|
||||
}// downattAction 下载附件
|
||||
|
||||
function denyinviteAction(){
|
||||
function denyinviteAction()
|
||||
{
|
||||
|
||||
$id = $this->_request->getParam('id');
|
||||
$uuid = $this->_request->getParam('uuid');
|
||||
|
@ -553,31 +554,12 @@ class ReviewController extends Zend_Controller_Action
|
|||
|
||||
if($id==$userid)
|
||||
{
|
||||
|
||||
try{
|
||||
$sql = "select md.title,r.status,rp.status as expint from mdreview r
|
||||
left join metadata md on md.uuid=r.uuid
|
||||
left join mdexpertreview rp on rp.id=md.id
|
||||
where r.id='$id' and r.uuid='$uuid'
|
||||
";
|
||||
|
||||
$rs = $this->db->query($sql);
|
||||
$rows = $rs->fetchAll();
|
||||
|
||||
if(empty($rows['expint']))
|
||||
{
|
||||
$this->view->message = "您无权限进行此操作";
|
||||
}else
|
||||
{
|
||||
if($rows['status']>=3 || $rows['expint']>=0)
|
||||
{
|
||||
$this->view->message = "该元数据的当前状态不能被拒绝对其的评审";
|
||||
}else{
|
||||
$sql = "update mdexpertreview set status=-1 where id='$id' and uuid='$uuid'";
|
||||
if($this->db->exec($sql))
|
||||
$this->view->message = "您已经拒绝该元数据的评审邀请";
|
||||
}
|
||||
}
|
||||
else
|
||||
$this->view->message = "您无权限进行此操作";
|
||||
}catch(Exception $e){
|
||||
$this->view->message = $e->getMessage();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue