change review search style and help content.

This commit is contained in:
wlx 2013-04-10 04:08:10 +00:00
parent de7c362b25
commit a793284936
6 changed files with 32 additions and 29 deletions

View File

@ -527,7 +527,7 @@ class ReviewController extends Zend_Controller_Action
} }
if (!empty($key)) { if (!empty($key)) {
$search=new Search($key); $search=new SimpleSearch($key);
$where=$search->sql_expr(array("m.title","m.description")); $where=$search->sql_expr(array("m.title","m.description"));
$page=@(int)$this->_request->getParam('page'); $page=@(int)$this->_request->getParam('page');
if (empty($page)) $page=1; if (empty($page)) $page=1;
@ -547,7 +547,8 @@ class ReviewController extends Zend_Controller_Action
function helpAction() function helpAction()
{ {
$this->view->pageID = "review-help"; $archives=new Archive($this->db);
$this->view->item=$archives->getOneArchive('元数据评审说明','help');
} }

View File

@ -16,11 +16,8 @@ $this->breadcrumb()->setSeparator(' > ');
<div class="span9"> <div class="span9">
<div id='help'> <div id='help'>
<h1>为什么要进行数据评审?</h1> <?= $this->item['body']; ?>
<p></p> </div>
<h1>如何进行数据评审?</h1>
<p></p>
</div>
</div> </div>
</div> </div>

View File

@ -1,7 +1,6 @@
<?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->review);
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->breadcrumb('<a href="/">首页</a>'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('元数据评审'); $this->breadcrumb('元数据评审');

View File

@ -14,7 +14,7 @@ $this->headLink()->appendStylesheet('/css/mdreview.css');
<?= $this->partial('review/navi.phtml'); ?> <?= $this->partial('review/navi.phtml'); ?>
</div> </div>
<div class="span9"> <div class="span9">
<div id='mdlist'> <ul class='media-list'>
<?php if (!empty($this->metadata)) : ?> <?php if (!empty($this->metadata)) : ?>
<?php echo $this->page->getNavigation(); ?> <?php echo $this->page->getNavigation(); ?>
<hr /> <hr />
@ -22,8 +22,8 @@ $this->headLink()->appendStylesheet('/css/mdreview.css');
$thumburl='/gndata/'.sprintf('%05d',floor(($md['gid']+0.1)/100)*100).'-'.sprintf('%05d',ceil(($md['gid']+0.1)/100)*100-1)."/".$md['gid']; $thumburl='/gndata/'.sprintf('%05d',floor(($md['gid']+0.1)/100)*100).'-'.sprintf('%05d',ceil(($md['gid']+0.1)/100)*100-1)."/".$md['gid'];
$thumburl.='/public/'.str_replace('_s.','.',$md['filename']); $thumburl.='/public/'.str_replace('_s.','.',$md['filename']);
?> ?>
<div class="media" style="border-bottom:1px dashed #ccc;"> <li class="media">
<a class="pull-left" href="#"> <a class="pull-left" href="/data/<?php echo $md['uuid'];?>">
<img class="media-object pull-left" src="/service/thumb/id/<?php echo $md['id'];?>"> <img class="media-object pull-left" src="/service/thumb/id/<?php echo $md['id'];?>">
</a> </a>
<div class="media-body"> <div class="media-body">
@ -36,9 +36,10 @@ $this->headLink()->appendStylesheet('/css/mdreview.css');
<?php endif; ?> <?php endif; ?>
<p><?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?></p> <p><?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?></p>
</div> </div>
</div> </li>
<hr />
<?php endforeach; ?> <?php endforeach; ?>
<hr class="clear"/>
<?php echo $this->page->getNavigation(); <?php echo $this->page->getNavigation();
else : else :
?> ?>
@ -46,7 +47,7 @@ $this->headLink()->appendStylesheet('/css/mdreview.css');
<p>当前没有对应元数据。</p> <p>当前没有对应元数据。</p>
</div> </div>
<?php endif; ?> <?php endif; ?>
</div> </ul>
</div> </div>
</div> </div>

View File

@ -8,6 +8,9 @@
<li id="Nav-review-help"><a href="/review/help"><i class="icon-chevron-right"></i>元数据评审说明</a></li> <li id="Nav-review-help"><a href="/review/help"><i class="icon-chevron-right"></i>元数据评审说明</a></li>
</ul> </ul>
</div> </div>
<form class="form-search" id="search" enctype="application/x-www-form-urlencoded" action="/review/search" method="post"> <form method="post" action="/review/search" id="search" class="form-search">
<input class="keyword" type="text" name="q" id="q" value="<?php echo (empty($this->key))?'':$this->key; ?>" placeholder="搜索标题和摘要"> <div class="input-append">
<input class="span2" id="q" name="q" type="text" value="<?php echo (empty($this->key))?'':$this->key; ?>" placeholder="搜索标题和摘要">
<button type="submit" class="btn">搜索</button>
</div>
</form> </form>

View File

@ -10,11 +10,12 @@ $this->breadcrumb('快速搜索');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb()->setSeparator(' > ');
$this->headScript()->appendFile('/js/pubfunc.js'); $this->headScript()->appendFile('/js/pubfunc.js');
?> ?>
<div id='sidebar'> <div class="row">
<div id='leftnavi'> <div class="span3">
<?= $this->partial('review/navi.phtml',array('key'=>$this->key)); ?> <?= $this->partial('review/navi.phtml',array('key'=>$this->key)); ?>
</div> </div>
</div> <div class="span9">
<?php if (!empty($this->metadata)) : ?> <?php if (!empty($this->metadata)) : ?>
<div id='mdlist'> <div id='mdlist'>
<?php echo $this->page->getNavigation(); ?> <?php echo $this->page->getNavigation(); ?>
@ -45,3 +46,4 @@ else :
</div> </div>
<?php endif; ?> <?php endif; ?>
</div> </div>
</div>