From 1f706e39b824421d603884e06b88120ec4ac6711 Mon Sep 17 00:00:00 2001 From: Li Jianxuan Date: Tue, 18 Oct 2011 08:15:32 +0000 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=BA=86=E5=B7=B2=E9=80=9A?= =?UTF-8?q?=E8=BF=87=E8=AF=84=E5=AE=A1=E7=9A=84=E9=80=BB=E8=BE=91=E5=88=A4?= =?UTF-8?q?=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/default/controllers/ReviewController.php | 12 ++++++++++-- .../default/views/scripts/review/review.phtml | 5 +++++ .../default/views/scripts/review/reviewed.phtml | 2 +- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/application/default/controllers/ReviewController.php b/application/default/controllers/ReviewController.php index 5732e2bc..e523670e 100644 --- a/application/default/controllers/ReviewController.php +++ b/application/default/controllers/ReviewController.php @@ -313,8 +313,10 @@ class ReviewController extends Zend_Controller_Action function reviewAction() { $uuid = $this->_request->getParam('uuid'); - $sql=$this->db->quoteInto("select m.id,m.uuid,m.title,m.description,m.title_en from metadata m where m.uuid=?",$uuid); - $this->view->metadata=$this->db->fetchRow($sql); + $sql=$this->db->quoteInto("select m.id,m.uuid,m.title,m.description,m.title_en,r.status from metadata m + left join mdstatus r on r.uuid=m.uuid + where m.uuid=?",$uuid); + $this->view->metadata = $md = $this->db->fetchRow($sql); $auth = Zend_Auth::getInstance(); if($auth->hasIdentity()) { @@ -337,6 +339,12 @@ class ReviewController extends Zend_Controller_Action $redirectlink='/review/review/uuid/'.$uuid.'/'; + if($md['status']==5) + { + $this->messenger->addMessage('该数据已经通过评审,不能再发表评审意见,如需提交问题,请联系数据管理员'); + $this->_redirect($redirectlink); + } + $auth = Zend_Auth::getInstance(); if($auth->hasIdentity()) { diff --git a/application/default/views/scripts/review/review.phtml b/application/default/views/scripts/review/review.phtml index e8f17827..c2e5bee1 100755 --- a/application/default/views/scripts/review/review.phtml +++ b/application/default/views/scripts/review/review.phtml @@ -35,6 +35,10 @@ { if(empty($this->pms)) { + if($md['status']==5) + { + echo "该数据已经通过评审"; + }else{ ?> 我要发布评审意见 paginator as $item): $autoindex++;?> - +