diff --git a/application/admin/controllers/ReviewController.php b/application/admin/controllers/ReviewController.php index 51ec6650..e4433728 100644 --- a/application/admin/controllers/ReviewController.php +++ b/application/admin/controllers/ReviewController.php @@ -14,9 +14,59 @@ class Admin_ReviewController extends Zend_Controller_Action } function indexAction() { - + $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 + order by m.id desc limit 10 "; + $re = $this->db->query($sql); + $queue = $re->fetchAll(); + + foreach ($queue as $k=>$v) + { + $queue[$k]['status']=$this->rewiterstatus($v['status']); + } + + $this->view->queue = $queue; + + + $auth = Zend_Auth::getInstance(); + if($auth->hasIdentity()) + { + $user = $auth->getIdentity(); + $userid = $user->id; + } + + $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'"; + + $re = $this->db->query($sql); + $rows = $re->fetchAll(); + + $this->view->my = $rows; + + }//indexAction + function rewiterstatus($status){ + if($status==-1) + {return "取消评审";} + else if($status==0) + {return "初始状态";} + else if($status==1) + {return "接受元数据评审";} + else if($status==2) + {return "开始邀请专家";} + else if($status==3) + {return "专家接受邀请";} + else if($status==4) + {return "专家反馈";} + else if($status==5) + {return "已发布";} + else + {return "";} + } /** *changestatus diff --git a/application/admin/views/scripts/review/index.phtml b/application/admin/views/scripts/review/index.phtml index 87e13c18..d41c9863 100644 --- a/application/admin/views/scripts/review/index.phtml +++ b/application/admin/views/scripts/review/index.phtml @@ -24,6 +24,47 @@ +
+ + 最近十条元数据 + + + + + + + queue)): ?> + + queue as $item): ?> + + > + + + + + + +
元数据标题管理员状态
+
+ 我管理的最近十条元数据 + + + + + + queue)): ?> + + queue as $item): ?> + + > + + + + + +
元数据标题状态
+ +
\ No newline at end of file