工具调整,显示优化

This commit is contained in:
wlx 2011-10-26 06:19:08 +00:00
parent e84987b3a7
commit fab6e1e085
10 changed files with 44 additions and 31 deletions

View File

@ -16,10 +16,12 @@ $this->headScript()->appendFile('http://maps.google.cn/maps?file=api&v=2&key='.$
<div id='tools'> <div id='tools'>
<?= $this->partial('data/tools.phtml'); ?> <?= $this->partial('data/tools.phtml'); ?>
</div> </div>
<?php if (!empty($this->metadata)) : ?> <?php if (!empty($this->metadata)) :
<?php echo $this->page->getNavigation(); echo $this->page->getNavigation();?>
foreach($this->metadata as $md) : ?>
<hr /> <hr />
<?php
foreach($this->metadata as $md) : ?>
<div class="mditem"> <div class="mditem">
<div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div> <div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div>
<h2><a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a> <h2><a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a>
@ -27,20 +29,19 @@ foreach($this->metadata as $md) : ?>
<span><?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?></span> <span><?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?></span>
</div> </div>
<?php endforeach; ?> <?php endforeach; ?>
<hr />
<?php echo $this->page->getNavigation();?> <?php echo $this->page->getNavigation();?>
<?php else: ?> <?php else: ?>
<script src="/js/dragzoom.js" type="text/javascript"></script> <script src="/js/dragzoom.js" type="text/javascript"></script>
<div id="map"></div> <div id="map"></div>
<div id="spatial"> <div id="spatial">
<form id="search" enctype="application/x-www-form-urlencoded" action="/data/advancesearch" method="post"> <form id="search" enctype="application/x-www-form-urlencoded" action="/data/advancesearch" method="post">
<!--<fieldset><legend>时间范围</legend><ul> <fieldset><legend>时间范围</legend><ul>
<li><span>开始时间:</span> <li><span>开始时间:</span>
<input name="start" type="text" id="start" /> <input name="start" type="text" id="start" />
</li> </li>
<li><span>结束时间:</span> <li><span>结束时间:</span>
<input name="end" type="text" id="end" />&nbsp; <input name="end" type="text" id="end" />&nbsp;
</li></ul></fieldset>--> </li></ul></fieldset>
<fieldset><legend>空间范围</legend><ul> <fieldset><legend>空间范围</legend><ul>
<li><span>东:</span>&nbsp; <li><span>东:</span>&nbsp;

View File

@ -13,16 +13,13 @@ $this->breadcrumb()->setSeparator(' > ');
<?= $this->partial('data/tools.phtml'); ?> <?= $this->partial('data/tools.phtml'); ?>
</div> </div>
<?php echo $this->page->getNavigation(); ?> <?php echo $this->page->getNavigation(); ?>
<?php foreach($this->metadata as $md) : ?>
<hr /> <hr />
<?php foreach($this->metadata as $md) : ?>
<div class="mditem"> <div class="mditem">
<div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div> <div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div>
<h2><a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a> <h2><a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a>
<a href="/data/xml/id/<?php echo $md['id'];?>" title="XML模式查看"><img src="/images/xml.gif" /></a>
<a href="/data/map/id/<?php echo $md['id']; ?>" title="查看数据空间范围"><img src="/images/map.gif" /></a>
</h2> </h2>
<div class="summary"><?php echo str_replace(array("\r\n", "\n", "\r"),'<br />',mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']));?></div> <div class="summary"><?php echo str_replace(array("\r\n", "\n", "\r"),'<br />',mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']));?></div>
</div> </div>
<?php endforeach; ?> <?php endforeach; ?>
<hr />
<?php echo $this->page->getNavigation(); ?> <?php echo $this->page->getNavigation(); ?>

View File

@ -23,9 +23,9 @@ $this->breadcrumb()->setSeparator(' > ');
<?php endforeach; ?> <?php endforeach; ?>
</ul></fieldset> </ul></fieldset>
</div> </div>
<div id='metacontent'>
<?php if (count($this->paginator)): ?> <?php if (count($this->paginator)): ?>
<div id='metacontent'>
<hr />
<?php <?php
$i=0; $i=0;
foreach ($this->paginator as $item): foreach ($this->paginator as $item):
@ -44,8 +44,6 @@ foreach ($this->paginator as $item):
</div>'; </div>';
endforeach; endforeach;
?> ?>
<?php endif; ?>
<?= $this->paginator; ?>
</div> </div>
<?= $this->paginator; ?>
<?php endif; ?>

View File

@ -13,7 +13,7 @@ $this->breadcrumb()->setSeparator(' > ');
<h3> <h3>
<?php echo $this->searchform; ?> <?php echo $this->searchform; ?>
<a href="/data/advancesearch">高级搜索</a></h3> <a href="/data/advancesearch">高级搜索</a></h3>
<h3><a href="/water">黑河综合遥感联合试验</a> <a href="/data/datasetcd">特色数据集光盘</a> </h3> <h3><a href="/heihe/">数字黑河</a> <a href="/water">黑河综合遥感联合试验</a> <a href="/data/datasetcd">特色数据集光盘</a> </h3>
<h3> 分类浏览</h3> <h3> 分类浏览</h3>
<div id='category'> <div id='category'>

View File

@ -11,8 +11,8 @@
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb()->setSeparator(' > ');
$this->headScript()->appendFile('/js/OpenLayers.js'); $this->headScript()->appendFile('/js/OpenLayers.js');
$this->headLink()->appendStylesheet('/js/theme/default/style.css'); $this->headLink()->appendStylesheet('/js/theme/default/style.css');
$this->headScript()->appendFile('http://maps.google.cn/maps?file=api&v=2&key='.$this->config->google->maps->api);
?> ?>
<script src='http://maps.google.com/maps?file=api&amp;v=2&amp;key=ABQIAAAACD-MqkkoOm60o_dvwdcKVhRBSKpgcP88GYi6r2Of16IkMX_4YhSBQsywCi4J2_fh4nBuWmK7gyRjLg'></script>
<div id='tools'> <div id='tools'>
<?= $this->partial('data/tools.phtml'); ?> <?= $this->partial('data/tools.phtml'); ?>
</div> </div>

View File

@ -12,9 +12,9 @@ $this->breadcrumb('快速搜索');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb()->setSeparator(' > ');
?> ?>
<div id='tools'> <div id='tools'>
<?= $this->partial('data/tools.phtml'); ?> <?= $this->partial('data/tools.phtml',array('key'=>$this->key)); ?>
</div> </div>
<?php echo $this->form; ?>
<?php if (!empty($this->metadata)) : ?> <?php if (!empty($this->metadata)) : ?>
<?php echo $this->page->getNavigation(); <?php echo $this->page->getNavigation();
foreach($this->metadata as $md) : ?> foreach($this->metadata as $md) : ?>

View File

@ -34,10 +34,9 @@ $this->breadcrumb()->setSeparator(' > ');
<?php if (!empty($this->metadata)) : ?> <?php if (!empty($this->metadata)) : ?>
<div id='metacontent'> <div id='metacontent'>
<h1>当前浏览数据集序列:<?php echo $this->codename; ?></h1> <h1>当前浏览数据集序列:<?php echo $this->codename; ?></h1>
<?php if ($this->showtools) echo $this->form; ?>
<?php echo $this->page->getNavigation(); ?> <?php echo $this->page->getNavigation(); ?>
<?php foreach($this->metadata as $md) : ?>
<hr /> <hr />
<?php foreach($this->metadata as $md) : ?>
<div class="mditem"> <div class="mditem">
<div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div> <div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div>
<h2><a href="/data/<?php echo $md['uuid']; ?>"><?php echo $this->escape($md['title']);?></a> <h2><a href="/data/<?php echo $md['uuid']; ?>"><?php echo $this->escape($md['title']);?></a>

View File

@ -17,15 +17,16 @@ $this->breadcrumb()->setSeparator(' > ');
<div id='metacontent'> <div id='metacontent'>
<h1>当前浏览:<?php echo $this->codename; ?></h1> <h1>当前浏览:<?php echo $this->codename; ?></h1>
<?php echo $this->page->getNavigation(); ?> <?php echo $this->page->getNavigation(); ?>
<?php foreach($this->metadata as $md) : ?>
<hr /> <hr />
<div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div> <?php foreach($this->metadata as $md) : ?>
<div class="mditem"> <div class="mditem">
<div class="thumb"><img src="/data/thumb/id/<?php echo $md['id'];?>" /></div>
<h2><a href="/data/<?php echo $md['uuid']; ?>"><?php echo $this->escape($md['title']);?></a> <h2><a href="/data/<?php echo $md['uuid']; ?>"><?php echo $this->escape($md['title']);?></a>
</h2> </h2>
<span><?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?></span> <span><?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?></span>
</div> </div>
<?php echo $this->page->getNavigation(); ?>
<?php endforeach; ?> <?php endforeach; ?>
</div> </div>
<?php else : ?> <?php else : ?>

View File

@ -8,7 +8,7 @@ $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>'); $this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
$this->breadcrumb('<a href="/data/timeline">时空导航</a>'); $this->breadcrumb('<a href="/data/timeline">时空导航</a>');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb()->setSeparator(' > ');
$this->headScript()->appendFile('http://maps.google.com/maps?file=api&v=2&key=ABQIAAAACD-MqkkoOm60o_dvwdcKVhRBSKpgcP88GYi6r2Of16IkMX_4YhSBQsywCi4J2_fh4nBuWmK7gyRjLg'); $this->headScript()->appendFile('http://maps.google.cn/maps?file=api&v=2&key='.$this->config->google->maps->api);
$this->headScript()->appendFile('/js/timeline_var.js'); $this->headScript()->appendFile('/js/timeline_var.js');
$this->headScript()->appendFile('/js/timeline_js/timeline-api.js'); $this->headScript()->appendFile('/js/timeline_js/timeline-api.js');
$this->headScript()->appendFile('/js/timemap/timemap.js'); $this->headScript()->appendFile('/js/timemap/timemap.js');

View File

@ -1,11 +1,28 @@
<ul> <ul>
<li><a href="/data/tag">数据集关键词浏览</a></li> <li><a href="/data/tag">关键词浏览</a></li>
<li><a href="/data/series">数据集序列浏览</a></li> <li><a href="/data/series">序列浏览</a></li>
<li><a href="/data/category">数据集分类浏览</a></li> <li><a href="/data/category">分类浏览</a></li>
<li><a href="/data/timeline">时间轴浏览</a></li> <li><a href="/data/timeline">时间轴浏览</a></li>
<li><a href="/data/map">空间浏览</a></li> <li><a href="/data/map">空间浏览</a></li>
<li><a href="/data/timemap">时空浏览</a></li> <li><a href="/data/timemap">时空浏览</a></li>
<li><a href="/data/browse">浏览所有元数据</a></li> <li><a href="/data/browse">全部浏览</a></li>
<li><a href="/data/search">快速搜索</a></li>
<li><a href="/data/advancesearch">高级搜索</a></li> <li><a href="/data/advancesearch">高级搜索</a></li>
<form id="search" enctype="application/x-www-form-urlencoded" action="/data/search" method="post">
<li>
<input type="text" name="q" id="q" value="<?php echo (empty($this->key))?'回车搜索标题和摘要':$this->key; ?>" onfocus="myfocus(this);" onblur="myblur(this);">
<input type="hidden" name="submit" value="submit">
</form>
<script>
function myfocus(element) {
if (element.value == '回车搜索标题和摘要') {
element.value = '';
}
}
function myblur(element) {
if (element.value == '') {
element.value = '回车搜索标题和摘要';
}
}
</script>
</li>
</ul> </ul>