增加了查看已通关评审的元数据的功能
This commit is contained in:
parent
472915b538
commit
05ce28cd24
|
@ -308,9 +308,9 @@ class Admin_ReviewController extends Zend_Controller_Action
|
||||||
$mail->setBodyText($mailtp->getBody());
|
$mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mail->addTo($expinfo['email']);
|
$mail->addTo($expinfo['email']);
|
||||||
$mail->setSubject($mailtp->getSubject());
|
$mail->setSubject($mailtp->getSubject());
|
||||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/data/doc/uuid/'.$uuid);
|
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/data/doc/uuid/'.$uuid);
|
||||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $md['title'].'.doc');
|
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $md['title'].'.doc');
|
||||||
if($mail->send())
|
if($mail->send())
|
||||||
{
|
{
|
||||||
$this->messenger->addMessage('成功邀请专家:'.$expinfo['realname']);
|
$this->messenger->addMessage('成功邀请专家:'.$expinfo['realname']);
|
||||||
|
@ -544,7 +544,7 @@ class Admin_ReviewController extends Zend_Controller_Action
|
||||||
$this->_redirect("/admin/review/canceled");
|
$this->_redirect("/admin/review/canceled");
|
||||||
}
|
}
|
||||||
|
|
||||||
}//开始评审
|
}//取消评审
|
||||||
|
|
||||||
$searchjoin = "";
|
$searchjoin = "";
|
||||||
if(!empty($search) && !empty($keyword))
|
if(!empty($search) && !empty($keyword))
|
||||||
|
@ -570,6 +570,35 @@ class Admin_ReviewController extends Zend_Controller_Action
|
||||||
|
|
||||||
}//被取消评审的元数据
|
}//被取消评审的元数据
|
||||||
|
|
||||||
|
function reviewedAction(){
|
||||||
|
|
||||||
|
$search=$this->_request->getParam('search');
|
||||||
|
$keyword = $this->_request->getParam('keyword');
|
||||||
|
|
||||||
|
$searchjoin = "";
|
||||||
|
if(!empty($search) && !empty($keyword))
|
||||||
|
{
|
||||||
|
$searchjoin = " and md.title like '%$keyword%'";
|
||||||
|
$this->view->keyword = $keyword;
|
||||||
|
}
|
||||||
|
|
||||||
|
$sql = "select m.id,md.title,md.uuid,u.username,u.realname,m.status,m.ts_finished from mdstatus m
|
||||||
|
left join metadata md on md.uuid=m.uuid
|
||||||
|
left join users u on u.id=m.userid
|
||||||
|
where status=5 $searchjoin";
|
||||||
|
|
||||||
|
$re = $this->db->query($sql);
|
||||||
|
$rows = $re->fetchAll();
|
||||||
|
|
||||||
|
$paginator = Zend_Paginator::factory($rows);
|
||||||
|
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||||
|
$paginator->setItemCountPerPage($this->view->config->page->max);
|
||||||
|
$paginator->setView($this->view);
|
||||||
|
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||||
|
$this->view->paginator=$paginator;
|
||||||
|
|
||||||
|
}//已结束评审
|
||||||
|
|
||||||
function expertsAction()
|
function expertsAction()
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -640,7 +669,7 @@ class Admin_ReviewController extends Zend_Controller_Action
|
||||||
|
|
||||||
if($this->db->insert('users',$data))
|
if($this->db->insert('users',$data))
|
||||||
{
|
{
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
$mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mailtp=new EmailText($this->db,'expert-register',array('user'=>$username,'password'=>$password));
|
$mailtp=new EmailText($this->db,'expert-register',array('user'=>$username,'password'=>$password));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
$mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
<li><a href="/admin/review/accept">待审元数据</a></li>
|
<li><a href="/admin/review/accept">待审元数据</a></li>
|
||||||
<li><a href="/admin/review/inreview">在审元数据</a></li>
|
<li><a href="/admin/review/inreview">在审元数据</a></li>
|
||||||
<li><a href="/admin/review/myreview">我负责的元数据</a></li>
|
<li><a href="/admin/review/myreview">我负责的元数据</a></li>
|
||||||
|
<li><a href="/admin/review/reviewed">通过评审的元数据</a></li>
|
||||||
<li><a href="/admin/review/experts">专家库</a></li>
|
<li><a href="/admin/review/experts">专家库</a></li>
|
||||||
<li><a href="/admin/review/canceled">已取消评审的元数据</a></li>
|
<li><a href="/admin/review/canceled">已取消评审的元数据</a></li>
|
||||||
</ul>
|
</ul>
|
|
@ -0,0 +1,51 @@
|
||||||
|
<?php
|
||||||
|
$this->headTitle($this->config->title->site);
|
||||||
|
$this->headTitle('后台管理');
|
||||||
|
$this->headTitle()->setSeparator(' - ');
|
||||||
|
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||||
|
$this->breadcrumb('<a href="/">首页</a>');
|
||||||
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||||
|
$this->breadcrumb('元数据评审');
|
||||||
|
$this->breadcrumb()->setSeparator(' > ');
|
||||||
|
?>
|
||||||
|
<div id="leftPanel">
|
||||||
|
<?= $this->partial('review/left.phtml'); ?>
|
||||||
|
</div>
|
||||||
|
<div id="rightPanel">
|
||||||
|
<?php if ($this->msg or $this->messages) :?>
|
||||||
|
<div id="message">
|
||||||
|
<?php if ($this->msg) : ?>
|
||||||
|
<p><?php echo $this->msg; ?></p>
|
||||||
|
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?>
|
||||||
|
<p><?php echo $msg; ?></p>
|
||||||
|
<?php endforeach;endif; ?>
|
||||||
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
|
<div class="search">
|
||||||
|
<form action="" method="get">
|
||||||
|
<input type="hidden" name="search" value='1' />
|
||||||
|
<input type="hidden" name="id" value='<?php echo $this->id;?>' />
|
||||||
|
<ul>
|
||||||
|
<li><label>搜索关键字</label><input type="text" name="keyword" value="<?php echo $this->keyword; ?>" /></li>
|
||||||
|
<li><input type="submit" class="searchbtn" value="搜索" /></li>
|
||||||
|
</ul>
|
||||||
|
</form>
|
||||||
|
</div><!-- search DIV -->
|
||||||
|
<table><thead>
|
||||||
|
<tr>
|
||||||
|
<td width='600'>标题</td>
|
||||||
|
<td width='120'>结束时间</td>
|
||||||
|
</tr></thead>
|
||||||
|
<?php if (count($this->paginator)): ?>
|
||||||
|
<?php $autoindex=0;?>
|
||||||
|
<?php foreach ($this->paginator as $item): ?>
|
||||||
|
<?php $autoindex++;?>
|
||||||
|
<tr class="<?php if($autoindex%2 == 0) echo 'even'; else echo 'odd'; ?>">
|
||||||
|
<td><a href="/data/<?php echo $item['uuid'];?>"><?php echo $item['title']; ?></a></td>
|
||||||
|
<td><?php echo date("Y-m-d H:i",strtotime($item['ts_finished']));?></td>
|
||||||
|
</tr>
|
||||||
|
<?php endforeach; ?>
|
||||||
|
<?php endif; ?>
|
||||||
|
</table>
|
||||||
|
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||||
|
</div>
|
Loading…
Reference in New Issue