diff --git a/application/admin/controllers/ReviewController.php b/application/admin/controllers/ReviewController.php index 3304881d..6f64d2ef 100644 --- a/application/admin/controllers/ReviewController.php +++ b/application/admin/controllers/ReviewController.php @@ -811,12 +811,41 @@ class Admin_ReviewController extends Zend_Controller_Action $q = $this->_request->getParam('q'); $search = $this->_request->getParam('search'); - if($ac=='view' && !empty($uuid)) + if($ac=='view' && !empty($id)) { - $redirect = "/admin/review/comments"; + $redirect = "/admin/review/comments/ac/view/id/$id"; + + if(!is_numeric($id)) + { + $this->messenger->addMessage('参数不正确,请按正确的步骤进行访问'); + $this->_redirect($redirect); + } + + $sql = "select r.id,r.mdcomment,r.datacomment,r.editorcomment,u.realname,md.title,att.filename,r.ts_created,ratt.attachid as attid from mdreview r + left join metadata md on md.uuid=r.uuid + left join users u on u.id=r.userid + left join mdreviewattach ratt on ratt.reviewid=r.id + left join attachments att on att.id=ratt.attachid + where r.id='$id' + "; + + $rs = $this->db->query($sql); + + $row = $rs->fetch(); + + if(!empty($row['attid'])) + { + $row['attid'] = '下载'; + } + else + { + $row['attid'] = '无附件'; + } - $this->_helper->viewRenderer(''); + $this->view->info = $row; + + $this->_helper->viewRenderer('commentsview'); }//查看单个元数据的评审 diff --git a/application/admin/views/scripts/review/commentslist.phtml b/application/admin/views/scripts/review/commentslist.phtml index cb8e0b61..313f776a 100644 --- a/application/admin/views/scripts/review/commentslist.phtml +++ b/application/admin/views/scripts/review/commentslist.phtml @@ -47,7 +47,7 @@ if($item['is_expert']==false)echo "否";else echo "是"; ?>