增加了取消元数据评审的功能
This commit is contained in:
parent
74d38052e0
commit
e27d19b37e
|
@ -20,13 +20,29 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
function acceptAction()
|
||||
{
|
||||
$search = $this->_request->getParam('search');
|
||||
$cancel = $this->_request->getParam('cancel');
|
||||
|
||||
if($cancel>0)
|
||||
{
|
||||
$sql = "update mdstatus set status='-1' where id='$cancel'";
|
||||
try{
|
||||
if($this->db->exec($sql)>0)
|
||||
{
|
||||
$this->messenger->addMessage('操作成功:已取消该数据的评审');
|
||||
$this->_redirect("/admin/review/accept");
|
||||
}
|
||||
}
|
||||
catch(Exception $e){
|
||||
$this->messenger->addMessage('操作失败:'.$e->getMessage());
|
||||
$this->_redirect("/admin/review/accept");
|
||||
}
|
||||
}
|
||||
if($search)
|
||||
{
|
||||
$keyword = $this->_request->getParam('keyword');
|
||||
if(!empty($keyword))
|
||||
{
|
||||
$sql = "select md.title,u.username,u.realname from mdstatus m
|
||||
$sql = "select m.id,md.title,u.username,u.realname from mdstatus m
|
||||
left join metadata md on md.uuid=m.uuid
|
||||
left join users u on u.id=m.userid
|
||||
where m.status=1
|
||||
|
@ -42,10 +58,10 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
}
|
||||
}//搜索
|
||||
else
|
||||
{
|
||||
$sql = "select md.title,u.username,u.realname from mdstatus m
|
||||
$sql = "select m.id,md.title,u.username,u.realname from mdstatus m
|
||||
left join metadata md on md.uuid=m.uuid
|
||||
left join users u on u.id=m.userid
|
||||
where m.status=1";
|
||||
|
@ -123,7 +139,7 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
$this->view->keyword = $keyword;
|
||||
}
|
||||
|
||||
$sql = "select md.title,u.username,u.realname,m.status from mdstatus m
|
||||
$sql = "select m.id,md.title,u.username,u.realname,m.status from mdstatus m
|
||||
left join metadata md on md.uuid=m.uuid
|
||||
left join users u on u.id=m.userid
|
||||
where u.id='$userid' $searchjoin";
|
||||
|
@ -137,10 +153,7 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
|
||||
|
||||
|
||||
}
|
||||
}//我管理的元数据
|
||||
|
||||
function expertsAction()
|
||||
{
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
<td><?= $item['title']?></td>
|
||||
<td><?php echo $item['realname'].'['.$item['username'].']'; ?></td>
|
||||
<td>
|
||||
<a href='/admin/review/experts/del/<?php echo $item['mid'];?>' onclick="return confirm('是否确定取消评审')">取消评审</a>
|
||||
<a href='/admin/review/accept/cancel/<?php echo $item['id'];?>' onclick="return confirm('是否确定取消评审')">取消评审</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
<?php endif; ?>
|
||||
|
||||
<div id="rightPanel">
|
||||
<div class="right_title">我负责的元数据评审</div>
|
||||
|
||||
<div class="search">
|
||||
<form action="" method="get">
|
||||
|
@ -58,7 +59,7 @@
|
|||
if($item['status'] == 5) echo "已发布";
|
||||
?></td>
|
||||
<td>
|
||||
<a href='/admin/review/experts/del/<?php echo $item['mid'];?>' onclick="return confirm('是否确定取消评审')">取消评审</a>
|
||||
<a href='/admin/review/accept/cancel/<?php echo $item['id'];?>' onclick="return confirm('是否确定取消评审')">取消评审</a>
|
||||
|
||||
|
||||
</td>
|
||||
|
|
Loading…
Reference in New Issue