实现页面重新布局,采用图导航,引入大图点击功能

This commit is contained in:
wlx 2011-10-28 02:32:39 +00:00
parent 1106adf166
commit fad74ea631
6 changed files with 279 additions and 504 deletions

View File

@ -29,239 +29,71 @@ class ReviewController extends Zend_Controller_Action
} }
function myreviewAction(){ function myreviewAction(){
$auth = Zend_Auth::getInstance();
$keyword = $this->_request->getParam('q'); if($auth->hasIdentity())
$search = $this->_request->getParam('search'); {
$user = $auth->getIdentity();
try{ $uid = $user->id;
$auth = Zend_Auth::getInstance(); }else{
if($auth->hasIdentity()) $this->_redirect('/account/login/?href=/review/myreview');
{ }
$user = $auth->getIdentity(); $page=@(int)$this->_request->getParam('page');
$uid = $user->id; if (empty($page)) $page=1;
} $offset=$this->limit*($page-1);
else $row=$this->db->fetchAll("select count(s.*) from mdstatus s left join normalmetadata m on s.uuid=m.uuid where m.uuid in (select uuid from mdexpertreview er where er.id=$uid union select uuid from mdreview r where r.userid=$uid)");
{ $sum=$row[0]['count'];
$this->_redirect('/account/login/?href=/review/myreview'); $sql="select m.uuid,m.title,m.id,m.description,s.status,s.ts_accepted,s.ts_finished,g.id as gid,t.filename from mdstatus s left join normalmetadata m on s.uuid=m.uuid left join geonetworkmetadata g on g.uuid=m.uuid left join thumbnail t on t.id=m.id where m.uuid in (select uuid from mdexpertreview er where er.id=$uid union select uuid from mdreview r where r.userid=$uid) order by s.ts_created desc,m.title limit ? offset ?";
} $this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
$this->view->page=new Pagination($sum,$page,$this->limit);
$sql = "select md.title,md.uuid,md.id,md.description,s.status from metadata md left join mdstatus s on md.uuid=s.uuid foreach($this->view->metadata as $k=>$v)
where md.uuid in (select uuid from mdexpertreview er where er.id=$uid {
union select uuid from mdreview r where r.userid=$uid)"; $this->view->metadata[$k]['statustext']=$this->rewritestatus($v['status']);
}
if(!empty($keyword) && !empty($search))
{
if (preg_match("/[<|>|#|$|%|^|*|(|)|{|}|'|\"|;|:]/i",$keyword) || !is_numeric($search))
{
$this->messenger->addMessage('您的输入的搜索条件包含非法请求,请不要输入特殊符号');
$this->_redirect('/review/myreview');
}//非法请求过滤
$this->view->keyword = $keyword;
$sql.= " and md.title like '%$keyword%' ";
// e.g. (... or md.author like '%keyword%')
}
$rs = $this->db->query($sql);
$rows = $rs->fetchAll();
foreach($rows as $k=>$v)
{
$rows[$k]['status']=$this->rewritestatus($v['status']);
}
$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;
}catch(Exception $e){
$this->messenger->addMessage('查询失败,请稍后重试 :(');
$this->_redirect('/review/myreview');
}
}//我参审的 }//我参审的
function draftAction(){ function draftAction(){
$page=@(int)$this->_request->getParam('page');
$keyword = $this->_request->getParam('q'); if (empty($page)) $page=1;
$search = $this->_request->getParam('search'); $offset=$this->limit*($page-1);
$row=$this->db->fetchAll("select count(s.*) from mdstatus s left join metadata m on s.uuid=m.uuid where s.status in (0)");
try{ $sum=$row[0]['count'];
$sql="select m.uuid,m.title,m.id,m.description,s.status,s.ts_created,g.id as gid,t.filename from mdstatus s left join metadata m on s.uuid=m.uuid left join geonetworkmetadata g on g.uuid=m.uuid left join thumbnail t on t.id=m.id where s.status in (0) order by s.ts_created desc,m.title limit ? offset ?";
$wheresql = array(); $this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
$wheresql[]=" ms.status=0 "; $this->view->page=new Pagination($sum,$page,$this->limit);
if(!empty($keyword) && !empty($search))
{
if (preg_match("/[<|>|#|$|%|^|*|(|)|{|}|'|\"|;|:]/i",$keyword) || !is_numeric($search))
{
$this->messenger->addMessage('您的输入的搜索条件包含非法请求,请不要输入特殊符号');
$this->_redirect('/review/draft');
}//非法请求过滤
$this->view->keyword = $keyword;
$wheresql[] = " md.title like '%$keyword%' ";
}
$wheresql = join(' and ',$wheresql);
$sql = "select ms.uuid,ms.status,ms.ts_created,md.title,md.author from mdstatus ms
left join metadata md on md.uuid=ms.uuid
where $wheresql";
$rs = $this->db->query($sql);
$rows = $rs->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;
}catch(Exception $e){
$this->messenger->addMessage('查询失败,请稍后重试 :(');
$this->_redirect('/review/draft');
}
}//最新收稿 }//最新收稿
function acceptAction(){ function acceptAction(){
$page=@(int)$this->_request->getParam('page');
$keyword = $this->_request->getParam('q'); if (empty($page)) $page=1;
$search = $this->_request->getParam('search'); $offset=$this->limit*($page-1);
$row=$this->db->fetchAll("select count(s.*) from mdstatus s left join normalmetadata m on s.uuid=m.uuid where s.status in (1)");
try{ $sum=$row[0]['count'];
$sql="select m.uuid,m.title,m.id,m.description,s.status,s.ts_accepted,g.id as gid,t.filename from mdstatus s left join normalmetadata m on s.uuid=m.uuid left join geonetworkmetadata g on g.uuid=m.uuid left join thumbnail t on t.id=m.id where s.status in (1) order by s.ts_created desc,m.title limit ? offset ?";
$wheresql = array(); $this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
$wheresql[]=" ms.status=1 "; $this->view->page=new Pagination($sum,$page,$this->limit);
if(!empty($keyword) && !empty($search))
{
if (preg_match("/[<|>|#|$|%|^|*|(|)|{|}|'|\"|;|:]/i",$keyword) || !is_numeric($search))
{
$this->messenger->addMessage('您的输入的搜索条件包含非法请求,请不要输入特殊符号');
$this->_redirect('/review/draft');
}//非法请求过滤
$this->view->keyword = $keyword;
$wheresql[] = " md.title like '%$keyword%' ";
}
$wheresql = join(' and ',$wheresql);
$sql = "select ms.uuid,ms.status,ms.ts_created,md.title,md.author from mdstatus ms
left join metadata md on md.uuid=ms.uuid
where $wheresql";
$rs = $this->db->query($sql);
$rows = $rs->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;
}catch(Exception $e){
$this->messenger->addMessage('查询失败,请稍后重试 :(');
$this->_redirect('/review/draft');
}
}//最新收稿 }//最新收稿
function inreviewAction(){ function inreviewAction(){
$page=@(int)$this->_request->getParam('page');
$keyword = $this->_request->getParam('q'); if (empty($page)) $page=1;
$search = $this->_request->getParam('search'); $offset=$this->limit*($page-1);
$row=$this->db->fetchAll("select count(s.*) from mdstatus s left join normalmetadata m on s.uuid=m.uuid where s.status in (2,3,4)");
try{ $sum=$row[0]['count'];
$sql="select m.uuid,m.title,m.id,m.description,s.status,s.ts_accepted,g.id as gid,t.filename from mdstatus s left join normalmetadata m on s.uuid=m.uuid left join geonetworkmetadata g on g.uuid=m.uuid left join thumbnail t on t.id=m.id where s.status in (2,3,4) order by s.ts_created desc,m.title limit ? offset ?";
$wheresql = array(); $this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
$wheresql[]=" ms.status in (2,3,4) "; $this->view->page=new Pagination($sum,$page,$this->limit);
if(!empty($keyword) && !empty($search))
{
if (preg_match("/[<|>|#|$|%|^|*|(|)|{|}|'|\"|;|:]/i",$keyword) || !is_numeric($search))
{
$this->messenger->addMessage('您的输入的搜索条件包含非法请求,请不要输入特殊符号');
$this->_redirect('/review/inreview');
}//非法请求过滤
$this->view->keyword = $keyword;
$wheresql[] = " md.title like '%$keyword%' ";
}
$wheresql = join(' and ',$wheresql);
$sql = "select ms.uuid,ms.status,ms.ts_created,md.title,md.author from mdstatus ms
left join metadata md on md.uuid=ms.uuid
where $wheresql";
$rs = $this->db->query($sql);
$rows = $rs->fetchAll();
foreach($rows as $k=>$v)
{
$rows[$k]['status']=$this->rewritestatus($v['status']);
}
$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;
}catch(Exception $e){
$this->messenger->addMessage('查询失败,请稍后重试 :(');
$this->_redirect('/review/inreview');
}
}//在审阶段的元数据 }//在审阶段的元数据
function reviewedAction(){ function reviewedAction(){
$page=@(int)$this->_request->getParam('page');
$keyword = $this->_request->getParam('q'); if (empty($page)) $page=1;
$search = $this->_request->getParam('search'); $offset=$this->limit*($page-1);
$row=$this->db->fetchAll("select count(s.*) from mdstatus s left join normalmetadata m on s.uuid=m.uuid where s.status in (5)");
try{ $sum=$row[0]['count'];
$sql="select m.uuid,m.title,m.id,m.description,s.status,s.ts_finished,g.id as gid,t.filename from mdstatus s left join normalmetadata m on s.uuid=m.uuid left join geonetworkmetadata g on g.uuid=m.uuid left join thumbnail t on t.id=m.id where s.status in (5) order by s.ts_created desc,m.title limit ? offset ?";
$wheresql = array(); $this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
$wheresql[]=" ms.status=5 "; $this->view->page=new Pagination($sum,$page,$this->limit);
if(!empty($keyword) && !empty($search))
{
if (preg_match("/[<|>|#|$|%|^|*|(|)|{|}|'|\"|;|:]/i",$keyword) || !is_numeric($search))
{
$this->messenger->addMessage('您的输入的搜索条件包含非法请求,请不要输入特殊符号');
$this->_redirect('/review/reviewed');
}//非法请求过滤
$this->view->keyword = $keyword;
$wheresql[] = " md.title like '%$keyword%' ";
}
$wheresql = join(' and ',$wheresql);
$sql = "select ms.uuid,ms.status,ms.ts_created,ts_finished,md.title,md.author from mdstatus ms
left join metadata md on md.uuid=ms.uuid
where $wheresql";
$rs = $this->db->query($sql);
$rows = $rs->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;
}catch(Exception $e){
$this->messenger->addMessage('查询失败,请稍后重试 :(');
$this->_redirect('/review/reviewed');
}
}//已完成评审的元数据 }//已完成评审的元数据

View File

@ -1,57 +1,47 @@
<?php <?php
$config = Zend_Registry::get('config'); $this->headTitle($this->config->title->site);
$this->headTitle($config->title->site); $this->headTitle($this->config->title->review);
$this->headTitle($config->title->mdreview); $this->headTitle('接收元数据');
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/mdreview.css'); $this->headLink()->appendStylesheet('/css/mdreview.css');
$this->breadcrumb('<a href="/">首页</a>'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/review">元数据评审</a>'); $this->breadcrumb('<a href="/review">'.$this->config->title->review.'</a>');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb('接收元数据');
$this->breadcrumb()->setSeparator(' > ');
$this->headScript()->appendFile('/js/pubfunc.js');
?> ?>
<div id='rightPanel'> <div id='sidebar'>
<div id='leftnavi'>
<?php if ($this->msg or $this->messages) :?> <?= $this->partial('review/navi.phtml'); ?>
<div class="box box-info"> </div>
<?php if ($this->msg) : ?> </div>
<?php echo $this->msg; ?> <?php if (!empty($this->metadata)) : ?>
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?> <div id='mdlist'>
<?php echo $msg; ?> <?php echo $this->page->getNavigation(); ?>
<?php endforeach;endif; ?> <hr />
<script language="javascript"> <?php foreach($this->metadata as $md) :
setTimeout("document.getElementsByClassName('box-info').remove(0)",5000); $thumburl='/gndata/'.sprintf('%05d',floor(($md['gid']+0.1)/100)*100).'-'.sprintf('%05d',ceil(($md['gid']+0.1)/100)*100-1)."/".$md['gid'];
</script> $thumburl.='/public/'.str_replace('_s.','.',$md['filename']);
</div> ?>
<?php endif; ?> <div class="thumbmd">
<div class="thumbtitle">
<h3>最新收稿的元数据:</h3> <a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']); ?> </a>【接收时间:<?php echo date('Y-m-d',strtotime($md['ts_accepted'])); ?>
<?php if ($md['status']!=5) : ?>
<form action="/review/draft" method="GET"> <a href="/review/review/uuid/<?php echo $md['uuid'];?>"><img src="/images/review.png" alt="查看评审页" title="进行数据评审"></a>
<input class="q" type="text" id="q" name="q" value="<?php echo $this->keyword;?>" /> <?php endif; ?>
<input type="hidden" name="search" value="1" /> </div>
<input type="submit" class="btn" value="搜索" /></form>
<img class="thumbimg" src="/service/thumb/id/<?php echo $md['id'];?>" alt="<?php echo $this->escape($md['title']);?>" title="<?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?>"
<table class="stylized"> onclick="fnCreate('<?php echo $thumburl; ?>')" />
<thead>
<tr> </div>
<th>元数据标题</th> <?php endforeach; ?>
<th>操作</th> </div>
</tr> <hr class="clear"/>
</thead> <?php echo $this->page->getNavigation();
<tbody> else :
<?php ?>
if (count($this->paginator)): <div>
$autoindex=0; <p>当前没有对应元数据。</p>
foreach ($this->paginator as $item): </div>
$autoindex++;?> <?php endif; ?>
<tr class="<?php if($autoindex%2 == 0) echo 'even'; else echo 'odd'; ?>">
<td> <img src="/images/westdc_20w.gif" /> <a href="<?php echo $item['uuid'];?>"><?php echo $item['title'];?></a></td>
<td>
<a href="/review/review/uuid/<?php echo $item['uuid'];?>">评审</a> <a href="/data/<?php echo $item['uuid'];?>">查看</a>
</td>
</tr>
<?php endforeach; endif; ?>
</tbody>
</table>
<div class="pagenavi"><?= $this->paginator; ?></div>
</div>

View File

@ -1,57 +1,44 @@
<?php <?php
$config = Zend_Registry::get('config'); $this->headTitle($this->config->title->site);
$this->headTitle($config->title->site); $this->headTitle($this->config->title->review);
$this->headTitle($config->title->mdreview); $this->headTitle('投稿元数据');
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/mdreview.css'); $this->headLink()->appendStylesheet('/css/mdreview.css');
$this->breadcrumb('<a href="/">首页</a>'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/review">元数据评审</a>'); $this->breadcrumb('<a href="/review">'.$this->config->title->review.'</a>');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb('投稿元数据');
$this->breadcrumb()->setSeparator(' > ');
$this->headScript()->appendFile('/js/pubfunc.js');
?> ?>
<div id='rightPanel'> <div id='sidebar'>
<div id='leftnavi'>
<?php if ($this->msg or $this->messages) :?> <?= $this->partial('review/navi.phtml'); ?>
<div class="box box-info"> </div>
<?php if ($this->msg) : ?> </div>
<?php echo $this->msg; ?> <?php if (!empty($this->metadata)) : ?>
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?> <div id='mdlist'>
<?php echo $msg; ?> <?php echo $this->page->getNavigation(); ?>
<?php endforeach;endif; ?> <hr />
<script language="javascript"> <?php foreach($this->metadata as $md) :
setTimeout("document.getElementsByClassName('box-info').remove(0)",5000); $thumburl='/gndata/'.sprintf('%05d',floor(($md['gid']+0.1)/100)*100).'-'.sprintf('%05d',ceil(($md['gid']+0.1)/100)*100-1)."/".$md['gid'];
</script> $thumburl.='/public/'.str_replace('_s.','.',$md['filename']);
</div> ?>
<?php endif; ?> <div class="thumbmd">
<div class="thumbtitle">
<h3>最新收稿的元数据:</h3> <?php echo $this->escape($md['title']); ?>【投稿时间:<?php echo date('Y-m-d',strtotime($md['ts_created'])); ?>
</div>
<form action="/review/draft" method="GET">
<input class="q" type="text" id="q" name="q" value="<?php echo $this->keyword;?>" /> <img class="thumbimg" src="/service/thumb/id/<?php echo $md['id'];?>" alt="<?php echo $this->escape($md['title']);?>" title="<?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?>"
<input type="hidden" name="search" value="1" /> onclick="fnCreate('<?php echo $thumburl; ?>')" />
<input type="submit" class="btn" value="搜索" /></form>
</div>
<table class="stylized"> <?php endforeach; ?>
<thead> </div>
<tr> <hr class="clear"/>
<th>元数据标题</th> <?php echo $this->page->getNavigation();
<th>收稿时间</th> else :
</tr> ?>
</thead> <div>
<tbody> <p>当前没有对应元数据。</p>
<?php </div>
if (count($this->paginator)): <?php endif; ?>
$autoindex=0;
foreach ($this->paginator as $item):
$autoindex++;?>
<tr class="<?php if($autoindex%2 == 0) echo 'even'; else echo 'odd'; ?>">
<td> <img src="/images/westdc_20w.gif" /> <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_created']));?>
</td>
</tr>
<?php endforeach; endif; ?>
</tbody>
</table>
<div class="pagenavi"><?= $this->paginator; ?></div>
</div>

View File

@ -1,59 +1,47 @@
<?php <?php
$config = Zend_Registry::get('config'); $this->headTitle($this->config->title->site);
$this->headTitle($config->title->site); $this->headTitle($this->config->title->review);
$this->headTitle($config->title->mdreview); $this->headTitle('在审元数据');
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/mdreview.css'); $this->headLink()->appendStylesheet('/css/mdreview.css');
$this->breadcrumb('<a href="/">首页</a>'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/review">元数据评审</a>'); $this->breadcrumb('<a href="/review">'.$this->config->title->review.'</a>');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb('在审元数据');
$this->breadcrumb()->setSeparator(' > ');
$this->headScript()->appendFile('/js/pubfunc.js');
?> ?>
<div id='rightPanel'> <div id='sidebar'>
<div id='leftnavi'>
<?php if ($this->msg or $this->messages) :?> <?= $this->partial('review/navi.phtml'); ?>
<div class="box box-info"> </div>
<?php if ($this->msg) : ?> </div>
<?php echo $this->msg; ?> <?php if (!empty($this->metadata)) : ?>
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?> <div id='mdlist'>
<?php echo $msg; ?> <?php echo $this->page->getNavigation(); ?>
<?php endforeach;endif; ?> <hr />
<script language="javascript"> <?php foreach($this->metadata as $md) :
setTimeout("document.getElementsByClassName('box-info').remove(0)",5000); $thumburl='/gndata/'.sprintf('%05d',floor(($md['gid']+0.1)/100)*100).'-'.sprintf('%05d',ceil(($md['gid']+0.1)/100)*100-1)."/".$md['gid'];
</script> $thumburl.='/public/'.str_replace('_s.','.',$md['filename']);
</div> ?>
<?php endif; ?> <div class="thumbmd">
<div class="thumbtitle">
<h3>目前在审的元数据:</h3> <a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']); ?> </a> 【接收时间:<?php echo date('Y-m-d',strtotime($md['ts_accepted'])); ?>
<?php if ($md['status']!=5) : ?>
<form action="/review/inreview" method="GET"> <a href="/review/review/uuid/<?php echo $md['uuid'];?>"><img src="/images/review.png" alt="查看评审页" title="进行数据评审"></a>
<input class="q" type="text" id="q" name="q" value="<?php echo $this->keyword;?>" /> <?php endif; ?>
<input type="hidden" name="search" value="1" /> </div>
<input type="submit" class="btn" value="搜索" /></form>
<img class="thumbimg" src="/service/thumb/id/<?php echo $md['id'];?>" alt="<?php echo $this->escape($md['title']);?>" title="<?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?>"
<table class="stylized"> onclick="fnCreate('<?php echo $thumburl; ?>')" />
<thead>
<tr> </div>
<th>元数据标题</th> <?php endforeach; ?>
<th>收稿时间</th> </div>
<th>状态</th> <hr class="clear"/>
</tr> <?php echo $this->page->getNavigation();
</thead> else :
<tbody id="datas"> ?>
<?php <div>
if (count($this->paginator)): <p>当前没有对应元数据。</p>
foreach ($this->paginator as $item): </div>
?> <?php endif; ?>
<tr>
<td> <img src="/images/westdc_20w.gif" /> <a href="/review/review/uuid/<?php echo $item['uuid'];?>"><?php echo $item['title'];?></a></td>
<td>
<?php echo date("Y-m-d",strtotime($item['ts_created']));?>
</td>
<td>
<?php echo $item['status'];?>
</td>
</tr>
<?php endforeach; endif; ?>
</tbody>
</table>
<div class="pagenavi"><?= $this->paginator; ?></div>
</div>

View File

@ -1,61 +1,50 @@
<?php <?php
$this->headTitle($this->config->title->site); $this->headTitle($this->config->title->site);
$this->headTitle($this->config->title->mdreview); $this->headTitle($this->config->title->review);
$this->headTitle()->setSeparator(' - '); $this->headTitle('我参审的元数据');
$this->headLink()->appendStylesheet('/css/mdreview.css'); $this->headTitle()->setSeparator(' - ');
$this->headScript()->appendFile('/js/jquery-1.6.4.min.js'); $this->headLink()->appendStylesheet('/css/mdreview.css');
$this->headScript()->appendFile('/js/jquery.masonry.min.js'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/">首页</a>'); $this->breadcrumb('<a href="/review">'.$this->config->title->review.'</a>');
$this->breadcrumb('<a href="/review">元数据评审</a>'); $this->breadcrumb('我参审的元数据');
$this->breadcrumb('我参审的元数据'); $this->breadcrumb()->setSeparator(' > ');
$this->breadcrumb()->setSeparator(' > '); $this->headScript()->appendFile('/js/pubfunc.js');
?> ?>
<div id='myreview'> <div id='sidebar'>
<div id='leftnavi'>
<?php if ($this->msg or $this->messages) :?> <?= $this->partial('review/navi.phtml'); ?>
<div class="box box-info"> </div>
<?php if ($this->msg) : ?> </div>
<?php echo $this->msg; ?> <?php if (!empty($this->metadata)) : ?>
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?> <div id='mdlist'>
<?php echo $msg; ?> <?php echo $this->page->getNavigation(); ?>
<?php endforeach;endif; ?> <hr />
<script language="javascript"> <?php foreach($this->metadata as $md) :
setTimeout("document.getElementsByClassName('box-info').remove(0)",5000); $thumburl='/gndata/'.sprintf('%05d',floor(($md['gid']+0.1)/100)*100).'-'.sprintf('%05d',ceil(($md['gid']+0.1)/100)*100-1)."/".$md['gid'];
</script> $thumburl.='/public/'.str_replace('_s.','.',$md['filename']);
</div> ?>
<?php endif; ?> <div class="thumbmd">
<div class="thumbtitle">
<h3>我参审的元数据:</h3> <a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']); ?> </a>【状态:<?php echo $md['statustext']; ?>
<?php if ($md['status']!=5) : ?>
<form action="/review/myreview" method="GET"> <a href="/review/review/uuid/<?php echo $md['uuid'];?>"><img src="/images/review.png" alt="查看评审页" title="进行数据评审"></a>
<input class="q" type="text" id="q" name="q" value="<?php echo $this->keyword;?>" /> <?php else : ?>
<input type="hidden" name="search" value="1" /> 【接收时间:<?php echo date('Y-m-d',strtotime($md['ts_accepted'])); ?>
<input type="submit" class="btn" value="搜索" /></form> 审结时间:<?php echo date('Y-m-d',strtotime($md['ts_finished'])); ?>
<?php endif; ?>
<div class="wapper"> </div>
<?php if (count($this->paginator)): ?>
<ul id="container" style="width:100%"> <img class="thumbimg" src="/service/thumb/id/<?php echo $md['id'];?>" alt="<?php echo $this->escape($md['title']);?>" title="<?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?>"
<?php foreach ($this->paginator as $item): ?> onclick="fnCreate('<?php echo $thumburl; ?>')" />
<li class="items">
<img class="thumb" src="/service/thumb/id/<?php echo $item['id'];?>" width="180" /> </div>
<a href="/data/<?php echo $item['uuid'];?>"><?php echo $item['title'];?></a> <?php endforeach; ?>
<br />状态:<?php echo $item['status'];?> </div>
<br /><a href="/review/review/uuid/<?php echo $item['uuid'];?>"><img src="/images/review.png" alt="查看评审页" title="进行数据评审"></a> <hr class="clear"/>
</li> <?php echo $this->page->getNavigation();
<?php endforeach;?> else :
</ul> ?>
<?php endif; ?> <div>
</div> <p>当前没有对应元数据。</p>
<div class="pagenavi"><?= $this->paginator; ?></div> </div>
<?php endif; ?>
</div>
<script>
var $tumblelog = $('#container');
$tumblelog.imagesLoaded(function(){
$tumblelog.masonry({
itemSelector: '.items',
columnWidth: 240
});
});
$(".items").mouseover(function(){$(this).addClass("hover")}).mouseout(function(){$(this).removeClass("hover")})
</script>

View File

@ -1,58 +1,47 @@
<?php <?php
$this->headTitle($this->config->title->site); $this->headTitle($this->config->title->site);
$this->headTitle($this->config->title->review); $this->headTitle($this->config->title->review);
$this->headTitle()->setSeparator(' - '); $this->headTitle('审结元数据');
$this->headLink()->appendStylesheet('/css/mdreview.css'); $this->headTitle()->setSeparator(' - ');
$this->breadcrumb('<a href="/">首页</a>'); $this->headLink()->appendStylesheet('/css/mdreview.css');
$this->breadcrumb('<a href="/review">元数据评审</a>'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb('<a href="/review">'.$this->config->title->review.'</a>');
$this->breadcrumb('审结元数据');
$this->breadcrumb()->setSeparator(' > ');
$this->headScript()->appendFile('/js/pubfunc.js');
?> ?>
<div id='rightPanel'> <div id='sidebar'>
<div id='leftnavi'>
<?php if ($this->msg or $this->messages) :?> <?= $this->partial('review/navi.phtml'); ?>
<div class="box box-info"> </div>
<?php if ($this->msg) : ?> </div>
<?php echo $this->msg; ?> <?php if (!empty($this->metadata)) : ?>
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?> <div id='mdlist'>
<?php echo $msg; ?> <?php echo $this->page->getNavigation(); ?>
<?php endforeach;endif; ?> <hr />
<script language="javascript"> <?php foreach($this->metadata as $md) :
setTimeout("document.getElementsByClassName('box-info').remove(0)",5000); $thumburl='/gndata/'.sprintf('%05d',floor(($md['gid']+0.1)/100)*100).'-'.sprintf('%05d',ceil(($md['gid']+0.1)/100)*100-1)."/".$md['gid'];
</script> $thumburl.='/public/'.str_replace('_s.','.',$md['filename']);
</div> ?>
<?php endif; ?> <div class="thumbmd">
<div class="thumbtitle">
<h3>已经通过审核的元数据:</h3> <a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']); ?> </a>【接收时间:<?php echo date('Y-m-d',strtotime($md['ts_finished'])); ?>
<?php if ($md['status']!=5) : ?>
<form action="/review/reviewed" method="GET"> <a href="/review/review/uuid/<?php echo $md['uuid'];?>"><img src="/images/review.png" alt="查看评审页" title="进行数据评审"></a>
<input class="q" type="text" id="q" name="q" value="<?php echo $this->keyword;?>" /> <?php endif; ?>
<input type="hidden" name="search" value="1" /> </div>
<input type="submit" class="btn" value="搜索" /></form>
<img class="thumbimg" src="/service/thumb/id/<?php echo $md['id'];?>" alt="<?php echo $this->escape($md['title']);?>" title="<?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?>"
<table class="stylized"> onclick="fnCreate('<?php echo $thumburl; ?>')" />
<thead>
<tr> </div>
<th>元数据标题</th> <?php endforeach; ?>
<th>评审结束时间</th> </div>
<th>操作</th> <hr class="clear"/>
</tr> <?php echo $this->page->getNavigation();
</thead> else :
<tbody> ?>
<?php <div>
if (count($this->paginator)): <p>当前没有对应元数据。</p>
$autoindex=0; </div>
foreach ($this->paginator as $item): <?php endif; ?>
$autoindex++;?>
<tr class="<?php if($autoindex%2 == 0) echo 'even'; else echo 'odd'; ?>">
<td> <img src="/images/westdc_20w.gif" /> <a href="/data/<?php echo $item['uuid'];?>"><?php echo $item['title'];?></a></td>
<td>
<?php echo date("Y-m-d",strtotime($item['ts_finished']));?>
</td>
<td><a href="/review/review/uuid/<?php echo $item['uuid'];?>">查看评审页</a></td>
</tr>
<?php endforeach; endif; ?>
</tbody>
</table>
<div class="pagenavi"><?= $this->paginator; ?></div>
</div>