merge heihedata branch from r4217 to r4220

This commit is contained in:
wlx 2014-02-21 09:14:14 +00:00
parent ab930d5ef5
commit e5e8f4b9d1
8 changed files with 11 additions and 8 deletions

View File

@ -1167,7 +1167,10 @@ class HeiheController extends DataController
} }
} else { } else {
//提供全部分类列表 //提供全部分类列表
$sql="select f.id,f.title,f.fund_id,f.fund_type,f.ts_created,count(m.id) as datacount,sum(md.filesize) as filesize from fund f left join mdfund m on f.id=m.fid left join metadata md on m.uuid=md.uuid left join heiheproject hp on f.fund_id=hp.code where hp.id is not null and m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') group by f.id,f.title,f.fund_id,f.fund_type,f.ts_created order by f.ts_created desc"; $sql="select f.id,f.title,f.fund_id,f.fund_type,f.ts_created,count(m.id) as datacount,sum(md.filesize) as filesize
from fund f left join mdfund m on f.id=m.fid left join metadata md on m.uuid=md.uuid left join heiheproject hp on f.fund_id=hp.code
where hp.id is not null and m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe')
group by f.id,f.title,f.fund_id,f.fund_type,f.ts_created order by f.fund_id asc";
$sth = $this->db->prepare($sql); $sth = $this->db->prepare($sql);
$sth->execute(); $sth->execute();
$rows = $sth->fetchAll(); $rows = $sth->fetchAll();

View File

@ -155,7 +155,7 @@ if ($md->title_en) echo '<br />'.$this->escape($md->title_en);?>
<?php if(!empty($this->fund)) : ?> <?php if(!empty($this->fund)) : ?>
<ul> <ul>
<?php foreach($this->fund as $k=>$v) : ?> <?php foreach($this->fund as $k=>$v) : ?>
<li><?= $v['fund_type'] ?><?= $v['title'] ?>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li> <li><?= $v['fund_type'] ?><a href="/data/fund/id/<?= $v['id'] ?>"><?= $v['title'] ?></a>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li>
<?php endforeach; ?> <?php endforeach; ?>
</ul> </ul>
<?php elseif(!empty($md->suppinfo)) : ?> <?php elseif(!empty($md->suppinfo)) : ?>

View File

@ -1,6 +1,6 @@
<hr> <hr>
<footer> <footer>
<p style="text-align:center;font-size:12px;">© 寒区旱区科学数据中心 2006-2013 | <a href="/about/contact" ><i class="icon-envelope"></i>联系我们</a> | <a href="/about/terms">使用条款和免责申明</a> <p style="text-align:center;font-size:12px;">© 寒区旱区科学数据中心 2006-2014 | <a href="/about/contact" ><i class="icon-envelope"></i>联系我们</a> | <a href="/about/terms">使用条款和免责申明</a>
| <a href="http://www.miibeian.gov.cn" target="_blank">陇ICP备05000491号</a></p> | <a href="http://www.miibeian.gov.cn" target="_blank">陇ICP备05000491号</a></p>
</footer> </footer>
<?php if(!empty($this->pageID)) {?> <?php if(!empty($this->pageID)) {?>

View File

@ -155,7 +155,7 @@ if ($md->title_en) echo '<br />'.$this->escape($md->title_en);?>
<?php if(!empty($this->fund)) : ?> <?php if(!empty($this->fund)) : ?>
<ul> <ul>
<?php foreach($this->fund as $k=>$v) : ?> <?php foreach($this->fund as $k=>$v) : ?>
<li><?= $v['fund_type'] ?><?= $v['title'] ?>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li> <li><?= $v['fund_type'] ?><a href="/data/fund/id/<?= $v['id'] ?>"><?= $v['title'] ?></a>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li>
<?php endforeach; ?> <?php endforeach; ?>
</ul> </ul>
<?php elseif(!empty($md->suppinfo)) : ?> <?php elseif(!empty($md->suppinfo)) : ?>

View File

@ -156,7 +156,7 @@ if ($md->title_en) echo '<br />'.$this->escape($md->title_en);?>
<?php if(!empty($this->fund)) : ?> <?php if(!empty($this->fund)) : ?>
<ul> <ul>
<?php foreach($this->fund as $k=>$v) : ?> <?php foreach($this->fund as $k=>$v) : ?>
<li><?= $v['fund_type'] ?><?= $v['title'] ?>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li> <li><?= $v['fund_type'] ?><a href="/data/fund/id/<?= $v['id'] ?>"><?= $v['title'] ?></a>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li>
<?php endforeach; ?> <?php endforeach; ?>
</ul> </ul>
<?php elseif(!empty($md->suppinfo)) : ?> <?php elseif(!empty($md->suppinfo)) : ?>

View File

@ -158,7 +158,7 @@ if ($md->title_en) echo '<br />'.$this->escape($md->title_en);?>
<?php if(!empty($this->fund)) : ?> <?php if(!empty($this->fund)) : ?>
<ul> <ul>
<?php foreach($this->fund as $k=>$v) : ?> <?php foreach($this->fund as $k=>$v) : ?>
<li><?= $v['fund_type'] ?><?= $v['title'] ?>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li> <li><?= $v['fund_type'] ?><a href="/heihe/fund/id/<?= $v['id'] ?>"><?= $v['title'] ?></a>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li>
<?php endforeach; ?> <?php endforeach; ?>
</ul> </ul>
<?php elseif(!empty($md->suppinfo)) : ?> <?php elseif(!empty($md->suppinfo)) : ?>

View File

@ -163,7 +163,7 @@ if ($md->title_en) echo '<br />'.$this->escape($md->title_en);?>
<?php if(!empty($this->fund)) : ?> <?php if(!empty($this->fund)) : ?>
<ul> <ul>
<?php foreach($this->fund as $k=>$v) : ?> <?php foreach($this->fund as $k=>$v) : ?>
<li><?= $v['fund_type'] ?><?= $v['title'] ?>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li> <li><?= $v['fund_type'] ?><a href="/data/fund/id/<?= $v['id'] ?>"><?= $v['title'] ?></a>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li>
<?php endforeach; ?> <?php endforeach; ?>
</ul> </ul>
<?php elseif(!empty($md->suppinfo)) : ?> <?php elseif(!empty($md->suppinfo)) : ?>

View File

@ -137,7 +137,7 @@ h3.gs_rt{font-size:110%;}
<?php if(!empty($this->fund)) : ?> <?php if(!empty($this->fund)) : ?>
<ul> <ul>
<?php foreach($this->fund as $k=>$v) : ?> <?php foreach($this->fund as $k=>$v) : ?>
<li><?= $v['fund_type'] ?><?= $v['title'] ?>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li> <li><?= $v['fund_type'] ?><a href="/data/fund/id/<?= $v['id'] ?>"><?= $v['title'] ?></a>(项目编号:<?= $v['fund_id']?>) [<?= $v['fund_type_en'] ?>(No. <?= $v['fund_id']?>)]</li>
<?php endforeach; ?> <?php endforeach; ?>
</ul> </ul>
<?php elseif(!empty($md->suppinfo)) : ?> <?php elseif(!empty($md->suppinfo)) : ?>