mrege from heihedata branch from r3662 to r3703
This commit is contained in:
commit
9790931463
|
@ -2443,9 +2443,9 @@ class Admin_DataController extends Zend_Controller_Action
|
|||
));
|
||||
$mail->setBodyText($mailtp->getBody());
|
||||
$mail->setSubject($mailtp->getSubject());
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/data/doc/review/1/uuid/'.$uuid);
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/doc/uuid/'.$row['uuid']);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.doc');
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$uuid);
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$row['uuid']);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.pdf');
|
||||
if($this->debug==0)
|
||||
{
|
||||
|
|
|
@ -388,7 +388,7 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||
$mail->addTo($expinfo['email']);
|
||||
$mail->setSubject($mailtp->getSubject());
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/data/doc/review/1/uuid/'.$uuid);
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/doc/uuid/'.$uuid);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $md['title'].'.doc');
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$uuid);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $md['title'].'.pdf');
|
||||
|
@ -428,7 +428,7 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||
$mail->addTo($row['email']);
|
||||
$mail->setSubject($mailtp->getSubject());
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/doc/review/1/uuid/'.$uuid);
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/doc/uuid/'.$uuid);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.doc');
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$uuid);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.pdf');
|
||||
|
@ -638,61 +638,35 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
*/
|
||||
function postAction(){
|
||||
|
||||
include_once('helper/view.php');
|
||||
include_once('data/Review.php');
|
||||
|
||||
$id = $this->_request->getParam('id');
|
||||
$emails = $this->_request->getParam('emails');
|
||||
|
||||
include_once('helper/view.php');
|
||||
$auth = Zend_Auth::getInstance();
|
||||
if($auth->hasIdentity())
|
||||
|
||||
$review = new Review($this->db);
|
||||
$reviewListener = new reviewListener();
|
||||
@$review->events()->attachAggregate($reviewListener);
|
||||
|
||||
if(is_numeric($id))
|
||||
{
|
||||
$user = $auth->getIdentity();
|
||||
$userid = $user->id;
|
||||
|
||||
$sql = "select id from mdstatus where id='$id' and userid='$userid'";
|
||||
$rs = $this->db->query($sql);
|
||||
$row = $rs->fetch();
|
||||
|
||||
if(!empty($row['id']))
|
||||
$id = (int)$id;
|
||||
if($review->checkAdmin($id) !== true)
|
||||
{
|
||||
|
||||
if($this->changestatus($id,5))
|
||||
{
|
||||
//发布正式版本
|
||||
$sql = "UPDATE mdversion SET changelog=?,userid=? WHERE id in (select id from mdversion where uuid in (select uuid from mdstatus where id=?) order by ts_created desc limit 1)";
|
||||
$this->db->query($sql,array('发布第一个正式版本 version 1.0',$userid,$id));
|
||||
//删除所有的中间版本
|
||||
$sql="delete from mdversion where changelog is null and uuid in (select uuid from mdstatus where id=?)";
|
||||
$this->db->query($sql,array($id));
|
||||
//email message
|
||||
$mail=new WestdcMailer($this->view->config->smtp);
|
||||
$sql="select m.uuid,m.title from metadata m left join mdstatus s on m.uuid=s.uuid where s.id='$id'";
|
||||
$rs=$this->db->query($sql);
|
||||
$res=$rs->fetch();
|
||||
$mailtp=new EmailText($this->db,'metadata-publish',array('uuid'=>$res['uuid'],'title'=>$res['title']));
|
||||
$mail->setBodyText($mailtp->getBody());
|
||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||
$mail->addTo($emails);
|
||||
$mail->setSubject($mailtp->getSubject());
|
||||
$mail->send();
|
||||
|
||||
view::Post($this,array("content"=>'操作成功:该元数据成功发布','url'=>"/admin/review/myreview"));
|
||||
return true;
|
||||
}else{
|
||||
view::Post($this,array("content"=>'操作失败','url'=>"/admin/review/myreview"));
|
||||
return true;
|
||||
}
|
||||
|
||||
}else{
|
||||
view::Post($this,array("content"=>'您没有权限操作其他管理员管理的元数据评审','url'=>"/admin/review/myreview"));
|
||||
return true;
|
||||
}
|
||||
|
||||
}else
|
||||
{
|
||||
view::Post($this,array("content"=>'权限读取失败','url'=>"/admin/review/myreview"));
|
||||
return true;
|
||||
}
|
||||
|
||||
$s = $review->post($id,$emails);
|
||||
if($s)
|
||||
{
|
||||
view::Post($this,"发布成功",-1);
|
||||
return true;
|
||||
}else{
|
||||
view::Post($this,"发布失败",-1);
|
||||
return true;
|
||||
}
|
||||
}//发布元数据
|
||||
|
||||
/*
|
||||
|
@ -740,9 +714,9 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
if($update>0 || is_array($update))
|
||||
{
|
||||
$ids = '';
|
||||
if(is_array($update))
|
||||
{
|
||||
$ids = implode(',',$update);
|
||||
if(is_array($update))
|
||||
{
|
||||
$ids = implode(',',$update);
|
||||
} else $ids=$update;
|
||||
|
||||
if($this->changestatus($ids,1))
|
||||
|
@ -764,14 +738,14 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
$sql="select distinct u.email,m.title,m.uuid from mdstatus s left join metadata m on s.uuid=m.uuid
|
||||
left join mdauthor a on s.uuid=a.uuid left join users u on a.userid=u.id where s.id=? order by u.email";
|
||||
$rs=$this->db->query($sql,array($ids));
|
||||
$rows=$rs->fetchAll($rs);
|
||||
$rows=$rs->fetchAll();
|
||||
if ($rows)
|
||||
{
|
||||
//有数据作者
|
||||
$mail=array();
|
||||
$email=array();
|
||||
foreach ($rows as $row)
|
||||
{
|
||||
$mail[]=$row['email'];
|
||||
$email[]=$row['email'];
|
||||
}
|
||||
$title=$rows[0]['title'];
|
||||
$uuid=$rows[0]['uuid'];
|
||||
|
@ -779,12 +753,12 @@ class Admin_ReviewController extends Zend_Controller_Action
|
|||
$mail=new WestdcMailer($this->view->config->smtp);
|
||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||
$mailtp=new EmailText($this->db,"review-new-accept",array(
|
||||
'uuid' => $iso->uuid,
|
||||
'title'=> $iso->resTitle
|
||||
'uuid' => $uuid,
|
||||
'title'=> $title
|
||||
));
|
||||
$mail->setBodyText($mailtp->getBody());
|
||||
$mail->setSubject($mailtp->getSubject());
|
||||
$mail->addTo($mail);
|
||||
$mail->addTo($email);
|
||||
$mail->addCC($this->view->config->service->email);
|
||||
$mail->send();
|
||||
}
|
||||
|
|
|
@ -7,7 +7,7 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
$this->view->config = Zend_Registry::get('config');
|
||||
$this->messenger=$this->_helper->getHelper('FlashMessenger');
|
||||
$this->view->messages = $this->messenger->getMessages();
|
||||
$this->_helper->layout->setLayout('administry');//新UI
|
||||
$this->_helper->layout->setLayout('administry');//新UI
|
||||
$this->view->theme = new Theme();
|
||||
}
|
||||
|
||||
|
@ -333,24 +333,102 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
}
|
||||
}//end
|
||||
|
||||
}//getmessageAction() 获取站内消息
|
||||
|
||||
//ftp测试
|
||||
function ftptestAction()
|
||||
{
|
||||
}
|
||||
|
||||
function recoveryAction()
|
||||
{
|
||||
$pages=20;
|
||||
$ac=$this->_request->getParam('ac');
|
||||
if ($ac=='' || $ac=='online')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
(select floor(sum(filesize)/1024/1024*100)/100 from datafile where dsid=ds.id) as filesize,
|
||||
(select count(id) from datafile where dsid=ds.id) as filecount from metadata m
|
||||
}//getmessageAction() 获取站内消息
|
||||
|
||||
//ftp测试
|
||||
function ftptestAction()
|
||||
{
|
||||
}
|
||||
|
||||
//区域管理
|
||||
function regionsAction()
|
||||
{
|
||||
include_once("data/Regions.php");
|
||||
include_once("helper/view.php");
|
||||
|
||||
$region = new Region($this->db);
|
||||
|
||||
$ac = $this->_getParam('ac');
|
||||
$id = $this->_getParam("id");
|
||||
|
||||
$RegionListener = new RegionListener();
|
||||
@$region->events()->attachAggregate($RegionListener);
|
||||
|
||||
if(empty($ac) || $ac == "index")
|
||||
{
|
||||
$filter = array();
|
||||
|
||||
$q = $this->_getParam('keyword');
|
||||
if(!empty($q))
|
||||
{
|
||||
$filter['q'] = $q;
|
||||
$this->view->keyword = $q;
|
||||
}
|
||||
|
||||
$data = $region->fetchRegion('all',$filter);
|
||||
view::addPaginator($data,$this,NULL,15);
|
||||
}
|
||||
|
||||
if($ac == "add" || $ac == "edit")
|
||||
{
|
||||
$this->_helper->viewRenderer('regions-add');
|
||||
$submit = $this->_getParam('submit');
|
||||
if(!empty($submit))
|
||||
{
|
||||
$this->view->data = $data = $this->_getParam("data");
|
||||
$s = $region->addRegion($data,$id);
|
||||
if($s === true)
|
||||
{
|
||||
$msg = "添加成功";
|
||||
if(!empty($id))
|
||||
$msg = "编辑成功";
|
||||
|
||||
view::Post($this,$msg,"/admin/sys/regions");
|
||||
return true;
|
||||
}else{
|
||||
if(is_string($s))
|
||||
{
|
||||
$this->view->error = view::Error($s);
|
||||
return true;
|
||||
}else{
|
||||
$this->view->error = view::Error("操作失败请重试");
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(!empty($id))
|
||||
{
|
||||
$this->view->data = $region->get($id);
|
||||
}
|
||||
}
|
||||
}//添加
|
||||
|
||||
if($ac == "del")
|
||||
{
|
||||
$langid = $this->_getParam('langid');
|
||||
if(!empty($id) && !empty($langid))
|
||||
{
|
||||
$region->del($id,$langid);
|
||||
}else{
|
||||
$region->del($id);
|
||||
}
|
||||
view::Post($this,"删除成功",-1);
|
||||
}//删除
|
||||
|
||||
}//区域管理
|
||||
|
||||
function recoveryAction()
|
||||
{
|
||||
$pages=20;
|
||||
$ac=$this->_request->getParam('ac');
|
||||
if ($ac=='' || $ac=='online')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(t.filesize/1024/1024*100)/100 as filesize,
|
||||
t.filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t on ds.id=t.dsid
|
||||
where s.status>4 and m.datatype=0 and ds.host='ftp1.westgis.ac.cn'
|
||||
ORDER BY m.id DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
|
@ -362,16 +440,18 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='heihe')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
(select floor(sum(filesize)/1024/1024*100)/100 from datafile where dsid=ds.id) as filesize,
|
||||
(select count(id) from datafile where dsid=ds.id) as filecount from metadata m
|
||||
$this->view->paginator=$paginator;
|
||||
$ac='online';
|
||||
} else if ($ac=='heihe')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(t.filesize/1024/1024*100)/100 as filesize,
|
||||
t.filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join source on datasource.sourceid=source.id
|
||||
left join (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t on ds.id=t.dsid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join source on datasource.sourceid=source.id
|
||||
where s.status>4 and m.datatype=1 and ds.host='ftp1.westgis.ac.cn' and source.code='heihe'
|
||||
ORDER BY m.id DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
|
@ -383,19 +463,18 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='water')
|
||||
{
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='water')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(sum(datafile.filesize)/1024/1024*100)/100 as filesize,
|
||||
count(datafile.id) as filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
floor(t.filesize/1024/1024*100)/100 as filesize,
|
||||
t.filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join datafile on ds.id=datafile.dsid
|
||||
left join (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t on ds.id=t.dsid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join source on datasource.sourceid=source.id
|
||||
where s.status>4 and m.datatype=1 and ds.host='ftp1.westgis.ac.cn' and source.code='water'
|
||||
group by m.title,m.uuid,ds.host,ds.path
|
||||
where s.status>4 and m.datatype=1 and ds.host='ftp1.westgis.ac.cn' and source.code='water'
|
||||
ORDER BY m.title DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
|
@ -406,19 +485,18 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='heihe1')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(sum(datafile.filesize)/1024/1024*100)/100 as filesize,
|
||||
count(datafile.id) as filecount from metadata m
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='heihe1')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(t.filesize/1024/1024*100)/100 as filesize,
|
||||
t.filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join datafile on ds.id=datafile.dsid
|
||||
left join source on datasource.sourceid=source.id
|
||||
where s.status in (2,3,4) and ds.host='ftp1.westgis.ac.cn' and source.code='heihe'
|
||||
group by m.title,m.uuid,ds.host,ds.path
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t on ds.id=t.dsid
|
||||
left join source on datasource.sourceid=source.id
|
||||
where s.status in (2,3,4) and ds.host='ftp1.westgis.ac.cn' and source.code='heihe'
|
||||
ORDER BY m.title DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
|
@ -429,16 +507,17 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='hiwater')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
(select floor(sum(filesize)/1024/1024*100)/100 from datafile where dsid=ds.id) as filesize,
|
||||
(select count(id) from datafile where dsid=ds.id) as filecount from metadata m
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='hiwater')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(t.filesize/1024/1024*100)/100 as filesize,
|
||||
t.filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join source on datasource.sourceid=source.id
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t on ds.id=t.dsid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join source on datasource.sourceid=source.id
|
||||
where ds.host='ftp1.westgis.ac.cn' and source.code='hiwater'
|
||||
ORDER BY m.title DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
|
@ -450,14 +529,15 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}else if ($ac=='westee')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
(select floor(sum(filesize)/1024/1024*100)/100 from datafile where dsid=ds.id) as filesize,
|
||||
(select count(id) from datafile where dsid=ds.id) as filecount from metadata m
|
||||
$this->view->paginator=$paginator;
|
||||
}else if ($ac=='westee')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(t.filesize/1024/1024*100)/100 as filesize,
|
||||
t.filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t on ds.id=t.dsid
|
||||
where ds.host='ftp1.westgis.ac.cn' and m.uuid in (select uuid from westeemd)
|
||||
ORDER BY m.title DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
|
@ -469,29 +549,99 @@ class Admin_SysController extends Zend_Controller_Action
|
|||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}else if ($ac=='other')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
(select floor(sum(filesize)/1024/1024*100)/100 from datafile where dsid=ds.id) as filesize,
|
||||
(select count(id) from datafile where dsid=ds.id) as filecount from metadata m
|
||||
$this->view->paginator=$paginator;
|
||||
}else if ($ac=='other')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(t.filesize/1024/1024*100)/100 as filesize,
|
||||
t.filecount from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t on ds.id=t.dsid
|
||||
where ds.host='ftp1.westgis.ac.cn' and m.uuid not in (select uuid from datasource) and m.uuid not in (select uuid from westeemd)
|
||||
ORDER BY m.title DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
$this->view->activeID="btn-".$ac;
|
||||
}
|
||||
|
||||
function problemAction()
|
||||
{
|
||||
$pages=20;
|
||||
$ac=$this->_request->getParam('ac');
|
||||
if ($ac=='' || $ac=='ref')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,m.citation,g.id as gid from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
left join geonetworkmetadata g on g.uuid=m.uuid
|
||||
where s.status>4 and m.citation like '%??%'
|
||||
ORDER BY m.id DESC";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
$this->view->activeID="btn-".$ac;
|
||||
}
|
||||
|
||||
$this->_helper->viewRenderer('problem-ref');
|
||||
$ac='ref';
|
||||
} else if ($ac=='file')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,m.filesize,ds.host,ds.path from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
where s.status>4 and ds.id not in (select distinct dsid from datafile)
|
||||
group by m.title,m.uuid,ds.host,ds.path,m.filesize
|
||||
ORDER BY m.title DESC;";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else if ($ac=='tiny')
|
||||
{
|
||||
$sql = "SELECT m.title,m.uuid,ds.host,ds.path,
|
||||
floor(sum(datafile.filesize)/1024/1024*100)/100 as filesize,
|
||||
count(datafile.id) as filecount
|
||||
from metadata m
|
||||
LEFT JOIN mdstatus s ON m.uuid=s.uuid
|
||||
LEFT JOIN dataset ds ON m.uuid=ds.uuid
|
||||
left join datasource on datasource.uuid=m.uuid
|
||||
left join datafile on ds.id=datafile.dsid
|
||||
left join source on datasource.sourceid=source.id
|
||||
where s.status>4 and ds.id in (select t.dsid from (select dsid,count(id) as filecount,sum(filesize) as filesize from datafile group by dsid) as t
|
||||
where t.filesize<1024*5)
|
||||
group by m.title,m.uuid,ds.host,ds.path
|
||||
ORDER BY m.title DESC;";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage($pages);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
$this->view->activeID="btn-".$ac;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -62,10 +62,10 @@ $(document).ready(function(){
|
|||
});
|
||||
</script>
|
||||
<div class="row-fluid">
|
||||
<div class="span3">
|
||||
<div class="span2">
|
||||
<?= $this->partial('news/left.phtml'); ?>
|
||||
</div>
|
||||
<div class="span9">
|
||||
<div class="span10">
|
||||
<h2>新闻发布</h2>
|
||||
<hr />
|
||||
<form name="form" id="archivesadd" method="post" action="#" class="form-horizontal">
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle('后台管理');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||
$this->headScript()->appendFile('/js/jquery.colorbox-min.js');
|
||||
$this->headLink()->appendStylesheet('/css/author.css');
|
||||
|
@ -33,7 +32,7 @@ $('#divFooter').css('position','absolute');
|
|||
</div>
|
||||
<?php endif; ?>
|
||||
<div>
|
||||
<select>
|
||||
<select id="navigation">
|
||||
<option>按栏目查看</option>
|
||||
<?php
|
||||
if(count($this->types))
|
||||
|
@ -42,11 +41,11 @@ $('#divFooter').css('position','absolute');
|
|||
{
|
||||
if(!empty($v[$this->deepField])) {$haed = str_repeat('-',$v[$this->deepField]);}
|
||||
if($this->type == $v['id'])
|
||||
echo '<option onclick="self.location=\'/admin/news/newslist/type/'.$v['id'].'\'" selected="selected">'
|
||||
echo '<option value="/admin/news/newslist/type/'.$v['id'].'" selected="selected">'
|
||||
.$haed
|
||||
.$v['title'].'</option>';
|
||||
else
|
||||
echo '<option onclick="self.location=\'/admin/news/newslist/type/'.$v['id'].'\'">'.$haed.$v['title'].'</option>';
|
||||
echo '<option value="/admin/news/newslist/type/'.$v['id'].'">'.$haed.$v['title'].'</option>';
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
@ -122,9 +121,12 @@ $(document).ready(function(){
|
|||
$('.title').bind('click', function() {
|
||||
$.colorbox({'innerWidth':'50%','html':$(this).next('.listingDetails').children('.pad').html()});
|
||||
});
|
||||
$("#navigation").change(function()
|
||||
{
|
||||
window.location.href = $(this).val();
|
||||
});
|
||||
});
|
||||
function showpad(id){
|
||||
$('#titlebtn'+id).click();
|
||||
}
|
||||
|
||||
</script>
|
|
@ -35,6 +35,7 @@ table thead tr th {background:#EBF2F6;color:#444;}
|
|||
<table class="table table-bordered table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width:13px;"><input type="checkbox" class="select_rows" data-tbody="list" /></th>
|
||||
<th width='500'>元数据标题</th>
|
||||
<th width='80'>状态</th>
|
||||
<th>接收时间</th>
|
||||
|
@ -46,6 +47,7 @@ table thead tr th {background:#EBF2F6;color:#444;}
|
|||
<tbody id="list">
|
||||
<?php foreach ($this->paginator as $item): ?>
|
||||
<tr>
|
||||
<td><input type="checkbox" class="select_item" value="<?= $item['id']?>" /></td>
|
||||
<td><?= $item['title']?> [
|
||||
<a href="/service/geonetwork?url=metadata.edit?id=<?= $item['gid'] ?>" target="_blank">编辑</a> |
|
||||
<a href="javascript:void(0);" rel="<?= $item['uuid']?>" class="version">版本</a>
|
||||
|
@ -76,15 +78,81 @@ table thead tr th {background:#EBF2F6;color:#444;}
|
|||
</tbody>
|
||||
<?php endif; ?>
|
||||
</table>
|
||||
<div><a class="btn btn-primary post">发布</a></div>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
var sfadmin = {
|
||||
def_data_tag : 'tbody',
|
||||
def_select_input : '.select_item',
|
||||
init: function() {
|
||||
$('.select_rows').click(function () {
|
||||
var tableid = $(this).data(sfadmin.def_data_tag);
|
||||
$('#'+tableid).find(sfadmin.def_select_input).attr('checked', this.checked);
|
||||
});
|
||||
sfadmin.ajax.error();
|
||||
},
|
||||
getSelected : function(tableid){
|
||||
if(tableid == "")
|
||||
{
|
||||
dom = $(sfadmin.def_select_input + ':checked');
|
||||
}else{
|
||||
dom = $(sfadmin.def_select_input + ':checked', '#'+tableid);
|
||||
}
|
||||
datas = new Array();
|
||||
dom.each(function(index, element) {
|
||||
datas.push($(this).val());
|
||||
});
|
||||
return datas;
|
||||
},
|
||||
ajax : {
|
||||
error : function(){
|
||||
$(document).ajaxError(function(event, request, settings) {
|
||||
sfadmin.Alert("请求中发生错误");
|
||||
})
|
||||
}
|
||||
},
|
||||
Alert : function(content){
|
||||
$.colorbox({width:'50%',html:'<div class="ajax_error"><div class="text"><h2>'+content+'</h2></div></div>'});
|
||||
}
|
||||
}
|
||||
|
||||
$(document).ready(function(e) {
|
||||
$('.version').click(function(){
|
||||
$(this).getversion({'id':$(this).attr('rel')});
|
||||
});
|
||||
sfadmin.init();
|
||||
$('.post').click(function(e) {
|
||||
ids = getids();
|
||||
if(!ids)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
url = "/admin/review/post/" + '?' +ids;
|
||||
self.location=url
|
||||
});
|
||||
});
|
||||
function getids(){
|
||||
id = sfadmin.getSelected('list');
|
||||
if(id.length == '')
|
||||
{
|
||||
alert('请选择要操作的项目');
|
||||
return false;
|
||||
}
|
||||
|
||||
url_data = new Array();
|
||||
|
||||
for(i in id)
|
||||
{
|
||||
url_data.push('id[]='+id[i]);
|
||||
}
|
||||
|
||||
data = url_data.join("&");
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
(function( $ ){
|
||||
|
||||
$.fn.getversion = function( options ) {
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
<ul>
|
||||
<li class="title">系统管理</li>
|
||||
<li><a href="/admin/sys/emailtext">邮件模板管理</a></li>
|
||||
<li><a href="/admin/sys/seekspace">文献平台同步</a></li>
|
||||
<li><a href="/admin/sys/message">管理消息</a></li>
|
||||
<li><a href="/admin/sys/ftptest">数据FTP测试</a></li>
|
||||
<li><a href="/admin/sys/recovery">数据恢复进展</a></li>
|
||||
<!--<li><a href="/admin/sys/seekspace">文献平台同步</a></li>-->
|
||||
<li><a href="/admin/sys/message">管理消息</a></li>
|
||||
<li><a href="/admin/sys/ftptest">数据FTP测试</a></li>
|
||||
<li><a href="/admin/sys/recovery">数据恢复进展</a></li>
|
||||
<li><a href="/admin/sys/problem">问题数据检查</a></li>
|
||||
<li><a href="/admin/sys/regions">GN地点管理</a></li>
|
||||
</ul>
|
|
@ -0,0 +1,45 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle('后台管理');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
<div id="leftPanel">
|
||||
<?= $this->partial('sys/left.phtml'); ?>
|
||||
</div>
|
||||
|
||||
<div id="rightPanel">
|
||||
<a id="btn-ref" class="btn" href="/admin/sys/problem/ac/ref">数据引用方式错误</a>
|
||||
<a id="btn-file" class="btn" href="/admin/sys/problem/ac/file">缺少文件列表</a>
|
||||
<a id="btn-tiny" class="btn" href="/admin/sys/problem/ac/tiny">数据实体大小不匹配</a>
|
||||
|
||||
<table><thead><tr>
|
||||
<th>数据标题</th>
|
||||
<th>引用</th>
|
||||
<th>操作</th>
|
||||
</tr></thead><tbody>
|
||||
<?php
|
||||
if (count($this->paginator)):
|
||||
$autoindex=0;
|
||||
foreach ($this->paginator as $item):
|
||||
$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 $item['citation'];?></td>
|
||||
<td><a href="/service/geonetwork?url=metadata.edit?id=<?= $item['gid']; ?>" target="_blank">编辑</a></td>
|
||||
</tr>
|
||||
<?php endforeach; endif; ?>
|
||||
</tbody></table>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
</div>
|
||||
<?php if(!empty($this->activeID)) : ?>
|
||||
<script>$('#<?= $this->activeID?>').addClass("btn-primary");</script>
|
||||
<?php endif; ?>
|
||||
<script>
|
||||
$(".iframe").colorbox({iframe:true, width:"50%", height:"50%"});
|
||||
$(".inline").colorbox({inline:true, width:"50%"});
|
||||
function Alert(html){
|
||||
$.colorbox({'innerWidth':'50%','html':'<h4 style="font-size:16px;font-weight:bold;">'+html+'</h4>'});
|
||||
}
|
||||
</script>
|
|
@ -0,0 +1,50 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle('后台管理');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
<div id="leftPanel">
|
||||
<?= $this->partial('sys/left.phtml'); ?>
|
||||
</div>
|
||||
|
||||
<div id="rightPanel">
|
||||
<a id="btn-ref" class="btn" href="/admin/sys/problem/ac/ref">数据引用方式错误</a>
|
||||
<a id="btn-file" class="btn" href="/admin/sys/problem/ac/file">缺少文件列表</a>
|
||||
<a id="btn-tiny" class="btn" href="/admin/sys/problem/ac/tiny">数据实体过小</a>
|
||||
<table><thead><tr>
|
||||
<th>数据标题</th>
|
||||
<th>UUID</th>
|
||||
<th>FTP主机</th>
|
||||
<th>路径</th>
|
||||
<th>大小</th>
|
||||
<th>操作</th>
|
||||
</tr></thead><tbody>
|
||||
<?php
|
||||
if (count($this->paginator)):
|
||||
$autoindex=0;
|
||||
foreach ($this->paginator as $item):
|
||||
$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 $item['uuid'];?></td>
|
||||
<td><?php echo $item['host'];?></td>
|
||||
<td><?php echo $item['path'];?></td>
|
||||
<td><?php echo $item['filesize'];?></td>
|
||||
<td><a href="/admin/data/dataset/ac/getdataset/uuid/<?php echo $item['uuid'];?>" class="iframe">数据路径</a></td>
|
||||
</tr>
|
||||
<?php endforeach; endif; ?>
|
||||
</tbody></table>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
</div>
|
||||
<?php if(!empty($this->activeID)) : ?>
|
||||
<script>$('#<?= $this->activeID?>').addClass("btn-primary");</script>
|
||||
<?php endif; ?>
|
||||
<script>
|
||||
$(".iframe").colorbox({iframe:true, width:"50%", height:"50%"});
|
||||
$(".inline").colorbox({inline:true, width:"50%"});
|
||||
function Alert(html){
|
||||
$.colorbox({'innerWidth':'50%','html':'<h4 style="font-size:16px;font-weight:bold;">'+html+'</h4>'});
|
||||
}
|
||||
</script>
|
|
@ -0,0 +1,117 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle('后台管理');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||
$this->breadcrumb('元数据评审');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<style>
|
||||
table thead tr th {background:#EBF2F6;color:#444;}
|
||||
.high{background:#444;color:#FFF;}
|
||||
</style>
|
||||
<div class="row-fluid">
|
||||
<div class="span2">
|
||||
<?= $this->partial('sys/left.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
|
||||
<div>
|
||||
<ul class="nav nav-tabs">
|
||||
<li><a href="/admin/sys/regions">浏览所有</a></li>
|
||||
<li class="active"><a href="/admin/sys/regions">添加</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<?php if (!empty($this->error)) :?>
|
||||
<?= $this->error ;?>
|
||||
<?php endif; ?>
|
||||
|
||||
<form method="post" action="" class="form-horizontal">
|
||||
<div class="control-group">
|
||||
<label class="control-label" for="east">东</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="east" name="data[east]" value="<?= isset($this->data['east']) ? $this->data['east']:"" ?>" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label" for="west">西</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="west" name="data[west]" value="<?= isset($this->data['west']) ? $this->data['west']:"" ?>" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label" for="south">南</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="south" name="data[south]" value="<?= isset($this->data['south']) ? $this->data['south']:"" ?>" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label" for="north">北</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="north" name="data[north]" value="<?= isset($this->data['north']) ? $this->data['north']:"" ?>" />
|
||||
</div>
|
||||
</div>
|
||||
<?php if(!isset($this->data['info'])) { ?>
|
||||
<div class="control-group langid-label">
|
||||
<label class="control-label" for="north">语言-名称</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="north" name="data[info][1][langid]" value="" placeholder="语言id" />
|
||||
<input type="text" id="north" name="data[info][1][label]" value="" placeholder="区域名称"/>
|
||||
</div>
|
||||
</div>
|
||||
<?php }else{ ?>
|
||||
<?php foreach($this->data['info'] as $k=>$v) { ?>
|
||||
<div class="control-group langid-label">
|
||||
<label class="control-label" for="north">语言-名称</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="north" name="data[info][<?= $k ?>][langid]" value="<?= $v['langid'] ?>" placeholder="语言id" />
|
||||
<input type="text" id="north" name="data[info][<?= $k ?>][label]" value="<?= $v['label'] ?>" placeholder="区域名称"/>
|
||||
<a href="javascript:void(0);" onclick="RmInput(this)"> -删除</a>
|
||||
</div>
|
||||
</div>
|
||||
<?php } } ?>
|
||||
<div class="control-group">
|
||||
<label class="control-label" for="north"></label>
|
||||
<div class="controls">
|
||||
<a href="javascript:void(0);" onclick="addInput()">+ 再添加一条</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<div class="controls">
|
||||
<input type="hidden" name="submit" value="1" />
|
||||
<?php if(!empty($this->id)) { ?>
|
||||
<input type="hidden" name="id" value=" <?=$this->id?> " />
|
||||
<?php } ?>
|
||||
<button type="submit" class="btn btn-primary">提交</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div><!-- span9 -->
|
||||
</div>
|
||||
<script>
|
||||
function addInput()
|
||||
{
|
||||
$('.langid-label').last().after(makeLabel());
|
||||
}
|
||||
|
||||
function makeLabel(){
|
||||
var now_index = $('.langid-label').length;
|
||||
var index = now_index + 1;
|
||||
html = '<div class="control-group langid-label">'
|
||||
+' <label class="control-label" for="north">语言-名称</label>'
|
||||
+' <div class="controls">'
|
||||
+' <input type="text" id="north" name="data[info]['+index+'][langid]" value="" placeholder="语言id" />'
|
||||
+' <input type="text" id="north" name="data[info]['+index+'][label]" value="" placeholder="区域名称"/>'
|
||||
+' <a href="javascript:void(0);" onclick="RmInput(this)"> -删除</a>'
|
||||
+' </div>'
|
||||
+'</div>';
|
||||
return html;
|
||||
}
|
||||
function RmInput(e){
|
||||
$e = $(e);
|
||||
$e.parent('div').parent('div').remove();
|
||||
}
|
||||
</script>
|
|
@ -0,0 +1,70 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle('后台管理');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||
$this->breadcrumb('元数据评审');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<style>
|
||||
table thead tr th {background:#EBF2F6;color:#444;}
|
||||
.high{background:#444;color:#FFF;}
|
||||
</style>
|
||||
<div class="row-fluid">
|
||||
<div class="span2">
|
||||
<?= $this->partial('sys/left.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
|
||||
<div>
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a href="/admin/sys/regions">浏览所有</a></li>
|
||||
<li><a href="/admin/sys/regions/ac/add">添加</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<form action="" method="get" class="search input-append">
|
||||
<input type="hidden" name="search" value='1' />
|
||||
<input type="text" name="keyword" class="q" value="<?php echo $this->keyword; ?>" />
|
||||
<button type="submit" class="btn">搜索</button>
|
||||
</form>
|
||||
|
||||
<?php if (!empty($this->error)) :?>
|
||||
<?= $this->error ;?>
|
||||
<?php endif; ?>
|
||||
|
||||
<table class="table table-bordered table-hover"><thead>
|
||||
<tr>
|
||||
<th width="50">语言</th>
|
||||
<th>名称</th>
|
||||
<th>东</th>
|
||||
<th>南</th>
|
||||
<th>西</th>
|
||||
<th>北</th>
|
||||
<th>操作</th>
|
||||
</tr></thead>
|
||||
<?php if (count($this->paginator)): ?>
|
||||
<tbody id="list">
|
||||
<?php foreach ($this->paginator as $item): ?>
|
||||
<tr>
|
||||
<td><?= $item['langid']?></td>
|
||||
<td><?= $item['label']?></td>
|
||||
<td><?= $item['east']?></td>
|
||||
<td><?= $item['south']; ?></td>
|
||||
<td><?= $item['west'];?></td>
|
||||
<td><?= $item['north'];?></td>
|
||||
<td>
|
||||
名称[
|
||||
<a href="/admin/sys/regions/ac/del/id/<?=$item['id'];?>/langid/<?= $item['langid'] ?>">删除</a>]
|
||||
范围[<a href="/admin/sys/regions/ac/del/id/<?=$item['id'];?>">删除</a>
|
||||
<a href="/admin/sys/regions/ac/edit/id/<?=$item['id'];?>">修改</a>]
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
<?php endif; ?>
|
||||
</table>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
</div><!-- span9 -->
|
||||
</div>
|
|
@ -709,22 +709,24 @@ class AuthorController extends Zend_Controller_Action
|
|||
*/
|
||||
function applyAction()
|
||||
{
|
||||
$ac = $this->_request->getParam('ac');
|
||||
$ac = $this->_request->getParam('ac');
|
||||
include_once('helper/view.php');
|
||||
$this->view->id=view::User('id');
|
||||
|
||||
if($ac == "mydata")
|
||||
{
|
||||
$this->_helper->layout->disableLayout();
|
||||
$this->_helper->viewRenderer->setNoRender();
|
||||
|
||||
include_once('helper/view.php');
|
||||
$email = view::User('email');
|
||||
$realname=view::User('realname');
|
||||
$realname=view::User('realname');
|
||||
|
||||
|
||||
$sql = "SELECT distinct m.uuid,m.title,m.description,a.status,a.userid FROM normalmetadata m
|
||||
LEFT JOIN mdauthor a ON m.uuid=a.uuid
|
||||
LEFT JOIN role r ON r.uuid=m.uuid
|
||||
LEFT JOIN responsible re ON r.resid = re.id
|
||||
WHERE re.email LIKE '%$email%' or re.realname='$realname'";
|
||||
WHERE r.role in ('originator','resourceProvider','pointOfContact','owner') and (re.email LIKE '%$email%' or re.individual='$realname')";
|
||||
|
||||
$rs = $this->db->query($sql);
|
||||
$this->jsonexit($rs->fetchAll());
|
||||
|
@ -2094,9 +2096,9 @@ class AuthorController extends Zend_Controller_Action
|
|||
));
|
||||
$mail->setBodyText($mailtp->getBody());
|
||||
$mail->setSubject($mailtp->getSubject());
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/data/doc/review/1/uuid/'.$uuid);
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/doc/uuid/'.$row['uuid']);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.doc');
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$uuid);
|
||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$row['uuid']);
|
||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.pdf');
|
||||
if($this->debug==0)
|
||||
{
|
||||
|
|
|
@ -8,12 +8,15 @@ class HeiheController extends DataController
|
|||
parent::preDispatch();
|
||||
$this->debug = 1;
|
||||
$this->view->pageID = "heihe-".$this->_request->getActionName();
|
||||
$this->view->nav[] = array('link'=>"/heihe",'title'=>'黑河计划数据管理中心');
|
||||
}
|
||||
|
||||
function indexAction()
|
||||
{
|
||||
$sql="select m.uuid,m.title,m.id,m.description from normalmetadata m left join thumbnail t on m.id=t.id where m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and length(t.data)>2 order by random() limit 3";
|
||||
$this->view->meatdata=$this->db->fetchAll($sql);
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河流域数据简介','about');
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -65,121 +68,136 @@ class HeiheController extends DataController
|
|||
|
||||
function baseAction()
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
$state=$this->db->query("select count(*) from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='冰川' or keyword='沙漠' or keyword='地貌' or keyword='植被' or keyword='草场' or keyword='沙漠化' or keyword='基础地理' or keyword='遥感影像' or keyword='水文地质' or keyword='社会经济' or keyword='人口' or keyword='SWAT' or keyword='NPP' or keyword='WRF' or keyword='辐射' or keyword='NEP'))");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='冰川' or keyword='沙漠' or keyword='地貌' or keyword='植被' or keyword='草场' or keyword='沙漠化' or keyword='基础地理' or keyword='遥感影像' or keyword='水文地质' or keyword='社会经济' or keyword='人口' or keyword='SWAT' or keyword='NPP' or keyword='WRF' or keyword='辐射' or keyword='NEP')) order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
$this->getmd(array('冰川','沙漠','地貌','植被','草场','沙漠化','基础地理','遥感影像','水文地质','社会经济','人口','SWAT','NPP','WRF','辐射','NEP'));
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-基础数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/base",'title'=>'基础数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function geobaseAction()
|
||||
{
|
||||
$this->getmd('基础地理');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-基础地理数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/geobase",'title'=>'基础地理数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function coreAction()
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
$state=$this->db->query("select count(*) from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='DEM' or keyword='土地利用' or keyword='土壤' or keyword='气象' or keyword='水文观测' or keyword='灌溉' or keyword='试验'))");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='DEM' or keyword='土地利用' or keyword='土壤' or keyword='气象' or keyword='水文观测' or keyword='灌溉' or keyword='试验')) order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
$this->getmd(array('DEM','土地利用','土壤','气象','水文观测','灌溉','试验'));
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-核心数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/core",'title'=>'核心数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function demAction()
|
||||
{
|
||||
$this->getmd('DEM');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-DEM','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/dem",'title'=>'DEM');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function rsAction()
|
||||
{
|
||||
$this->getmd('遥感影像');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-遥感影像','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/rs",'title'=>'遥感影像');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function waterAction()
|
||||
{
|
||||
$this->getmd('水文地质');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-水文水资源数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/water",'title'=>'水文水资源数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function modelAction()
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
$state=$this->db->query("select count(*) from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='WRF' or keyword='NPP' or keyword='SWAT' or keyword='NEP' or keyword='辐射'))");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='WRF' or keyword='NPP' or keyword='SWAT' or keyword='NEP' or keyword='辐射')) order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
$this->getmd(array('WRF','NPP','SWAT','NEP','辐射'));
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-模型数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/model",'title'=>'模型数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function economicAction()
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
$state=$this->db->query("select count(*) from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='人口' or keyword='社会经济'))");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='人口' or keyword='社会经济')) order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
$this->getmd(array('人口','社会经济'));
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-社会经济数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/economic",'title'=>'社会经济数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function landsurfaceAction()
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
$state=$this->db->query("select count(*) from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='冰川' or keyword='沙漠' or keyword='地貌' or keyword='植被' or keyword='草场' or keyword='沙漠化'))");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='theme' and (keyword='冰川' or keyword='沙漠' or keyword='地貌' or keyword='植被' or keyword='草场' or keyword='沙漠化')) order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
$this->getmd(array('冰川','沙漠','地貌','植被','草场','沙漠化'));
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-陆地表层数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/landsurface",'title'=>'陆地表层数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function landuseAction()
|
||||
{
|
||||
$this->getmd('土地利用','theme');
|
||||
$this->getmd('土地利用');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-土地利用数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/landuse",'title'=>'土地利用数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function soilAction()
|
||||
{
|
||||
$this->getmd('土壤','theme');
|
||||
$this->getmd('土壤');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-土壤数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/soil",'title'=>'土壤数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function meteoAction()
|
||||
{
|
||||
$this->getmd('气象','theme');
|
||||
$this->getmd('气象');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-气象观测数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/meteo",'title'=>'气象观测数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function hydroAction()
|
||||
{
|
||||
$this->getmd('水文观测','theme');
|
||||
$this->getmd('水文观测');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-水文观测数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/hydro",'title'=>'水文观测数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
function irragationAction()
|
||||
{
|
||||
$this->getmd('灌溉','theme');
|
||||
$this->getmd('灌溉');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-灌溉数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/irragation",'title'=>'灌溉数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function obsAction()
|
||||
{
|
||||
$this->getmd('试验','theme');
|
||||
$this->getmd('试验');
|
||||
$archive = new Archive($this->db);
|
||||
$this->view->info = $archive->getOneArchive('黑河计划-观测试验数据','about');
|
||||
$this->view->nav[] = array('link'=>"/heihe/obs",'title'=>'观测试验数据');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
function listAction()
|
||||
|
@ -188,34 +206,30 @@ class HeiheController extends DataController
|
|||
$this->view->metadata=$this->db->fetchAll($sql);
|
||||
}
|
||||
|
||||
function tagAction()
|
||||
{
|
||||
$key = $this->_request->getParam('key');
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
if (!empty($key)) {
|
||||
$this->view->codename=$key;
|
||||
$sql=$this->db->quoteInto('select count(id) from keyword where keyword=?',$key);
|
||||
$state=$this->db->query($sql);
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
$sql="select uuid,title,id,description from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keyword='".$key."') order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
} else {
|
||||
$state=$this->db->query("select keyword.keyword,count(*) from keyword left join normalmetadata m on keyword.id=m.id where keyword.keytype='place' 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 keyword.keyword order by count desc");
|
||||
$k1=$state->fetchAll();
|
||||
$state=$this->db->query("select k.keyword,count(k.keyword) from keyword k left join normalmetadata m on k.id=m.id where k.keytype='theme' 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 k.keyword order by k.keyword");
|
||||
$k2=$state->fetchAll();
|
||||
$state=$this->db->query("select k.keyword,count(k.keyword) from keyword k left join normalmetadata m on k.id=m.id where k.keytype='discipline' 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 k.keyword order by k.keyword");
|
||||
$k3=$state->fetchAll();
|
||||
$state=$this->db->query("select k.keyword,count(k.keyword) from keyword k left join normalmetadata m on k.id=m.id where k.keytype='stratum' 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 k.keyword order by k.keyword");
|
||||
$k4=$state->fetchAll();
|
||||
$state=$this->db->query("select keyword.keyword,count(*) from keyword left join normalmetadata m on keyword.id=m.id where keyword.keytype='temporal' 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 keyword.keyword order by keyword.keyword");
|
||||
$k5=$state->fetchAll();
|
||||
$this->view->keywords=array('place'=>$k1,'theme'=>$k2,'discipline'=>$k3,'stratum'=>$k4,'temporal'=>$k5);
|
||||
}
|
||||
function tagAction()
|
||||
{
|
||||
$key = $this->_request->getParam('key');
|
||||
$keytype = $this->_request->getParam('keytype');
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
if (!empty($key)) {
|
||||
$this->view->codename=$key;
|
||||
$sql=$this->db->quoteInto("select count(k.id) from keyword k left join normalmetadata m on k.id=m.id where m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and k.keyword=?",$key);
|
||||
$state=$this->db->query($sql);
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
$sql="select uuid,title,id,description from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keyword='".$key."') order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
} else {
|
||||
$sql="select k.keyword,count(*),k.keytype from keyword k left join normalmetadata m on k.id=m.id where length(k.keyword)>0 and m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') ";
|
||||
if (!empty($keytype) && ($keytype=='place' || $keytype=='theme' || $keytype=='discipline'||$keytype=='temporal')) $sql.=" and k.keytype='".$keytype."'";
|
||||
$sql.=' group by k.keyword,k.keytype order by k.keytype,k.keyword,count desc';
|
||||
$state=$this->db->query($sql);
|
||||
$this->view->keytype=$keytype;
|
||||
$this->view->keywords=$state->fetchAll();
|
||||
}
|
||||
}
|
||||
|
||||
function searchAction()
|
||||
|
@ -296,19 +310,63 @@ class HeiheController extends DataController
|
|||
}
|
||||
}
|
||||
|
||||
private function getmd($keyword,$type='theme')
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
$state=$this->db->query("select count(m.*) from normalmetadata m left join datasource d on m.uuid=d.uuid left join source s on d.sourceid=s.id where s.code='heihe' and m.id in (select id from keyword where keytype='".$type."' and keyword='".$keyword."')");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
//@todo: add order with title
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='".$type."' and keyword='".$keyword."') order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
private function getmd($keyword,$type='theme')
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
if (!is_array($keyword))
|
||||
{
|
||||
$keyword=array($keyword);
|
||||
}
|
||||
$key="(";
|
||||
foreach($keyword as $k)
|
||||
{
|
||||
$key.="'".$k."',";
|
||||
}
|
||||
$key=substr($key,0,-1);
|
||||
$key.=")";
|
||||
$keyword=$key;
|
||||
|
||||
$state=$this->db->query("select count(m.*) from normalmetadata m left join datasource d on m.uuid=d.uuid left join source s on d.sourceid=s.id where s.code='heihe' and m.id in (select id from keyword where keytype='".$type."' and keyword in ".$keyword.")");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
//@todo: add order with title
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keytype='".$type."' and keyword in ".$keyword.") order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
}
|
||||
|
||||
//获取多项条件并列关系的数据并必须满足limited条件
|
||||
//$keyword:字符串或字符串数组
|
||||
//$limited:限制字符串
|
||||
private function getmdlimited($keyword,$limited)
|
||||
{
|
||||
$page=(int)$this->_request->getParam('page');
|
||||
if (empty($page)) $page=1;
|
||||
$offset=$this->limit*($page-1);
|
||||
if (!is_array($keyword))
|
||||
{
|
||||
$keyword=array($keyword);
|
||||
}
|
||||
$key="(";
|
||||
foreach($keyword as $k)
|
||||
{
|
||||
$key.="'".$k."',";
|
||||
}
|
||||
$key=substr($key,0,-1);
|
||||
$key.=")";
|
||||
$keyword=$key;
|
||||
|
||||
$state=$this->db->query("select count(m.*) from normalmetadata m left join datasource d on m.uuid=d.uuid left join source s on d.sourceid=s.id where s.code='heihe' and m.id in (select id from keyword where keyword='".$limited."') and m.id in (select id from keyword where keyword in ".$keyword.")");
|
||||
$row=$state->fetchAll();
|
||||
$sum=$row[0]['count'];
|
||||
//@todo: add order with title
|
||||
$sql="select uuid,title from normalmetadata where uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and id in (select id from keyword where keyword='".$limited."') and id in (select id from keyword where keyword in ".$keyword.") order by timebegin,title limit ? offset ?";
|
||||
$this->view->metadata=$this->db->fetchAll($sql,array($this->limit,$offset));
|
||||
$this->view->page=new Pagination($sum,$page,$this->limit);
|
||||
$this->view->offset=$offset+1;
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -334,13 +392,7 @@ class HeiheController extends DataController
|
|||
$this->view->isadmin=false;
|
||||
if ($user->usertype=='administrator') $this->view->isadmin=true;
|
||||
}
|
||||
|
||||
if(empty($ac) || $ac == "index")
|
||||
{
|
||||
$this->_helper->viewRenderer('submit-index');
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
//新建元数据
|
||||
if($ac == "newdata")
|
||||
{
|
||||
|
@ -409,10 +461,10 @@ class HeiheController extends DataController
|
|||
}//newdata
|
||||
|
||||
//未提交数据
|
||||
if($ac == "unsubmit")
|
||||
if($ac == "unsubmit" || $ac=="")
|
||||
{
|
||||
$do = $this->_getParam('do');
|
||||
|
||||
|
||||
//未提交的数据列表
|
||||
if(empty($do) || $do=="index")
|
||||
{
|
||||
|
@ -737,6 +789,7 @@ class HeiheController extends DataController
|
|||
if(empty($ac) || $ac == "index" || $ac == 'my')
|
||||
{
|
||||
$this->_helper->viewRenderer('project-index');
|
||||
$this->view->tabID='projects-index';
|
||||
|
||||
//Search Link
|
||||
$this->view->searchLink = "/heihe/projects/ac/index/";
|
||||
|
@ -752,15 +805,20 @@ class HeiheController extends DataController
|
|||
$this->view->error = "输入的搜索条件有误,只允许输入汉字、数字、字母";
|
||||
return true;
|
||||
}
|
||||
$wheresql[] = " (title LIKE '%$q%' OR
|
||||
code LIKE '%$q%' OR
|
||||
name LIKE '%$q%')";
|
||||
$wheresql[] = " (p.title LIKE '%$q%' OR
|
||||
p.code LIKE '%$q%' OR
|
||||
p.name LIKE '%$q%')";
|
||||
$this->view->searchKeyword = $q;
|
||||
}
|
||||
|
||||
if($ac == "my")
|
||||
{
|
||||
$wheresql[] = " email='$user_email' ";
|
||||
//防止通过其它方式访问,先判断是否是登录用户,如果不是,抛出消息后强制用户退出
|
||||
$auth = Zend_Auth::getInstance();
|
||||
if(!$auth->hasIdentity())
|
||||
$this->_redirect('/account/login?href=/heihe/projects/ac/my');
|
||||
$wheresql[] = " p.email='$user_email' ";
|
||||
$this->view->tabID='projects-my';
|
||||
}
|
||||
|
||||
if(count($wheresql)>0)
|
||||
|
@ -775,8 +833,8 @@ class HeiheController extends DataController
|
|||
$wheresql = " WHERE ".$wheresql;
|
||||
}
|
||||
|
||||
$sql = "SELECT * FROM heiheproject $wheresql
|
||||
ORDER BY id DESC";
|
||||
$sql = "SELECT p.*,f.id as fid FROM heiheproject p left join fund f on p.code=f.fund_id $wheresql
|
||||
ORDER BY p.id asc";
|
||||
$sth = $this->db->query($sql);
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
|
@ -792,8 +850,8 @@ class HeiheController extends DataController
|
|||
if($ac == "submitting")
|
||||
{
|
||||
$this->_helper->viewRenderer('project-index');
|
||||
|
||||
$sql = "SELECT * FROM heiheproject WHERE status=1";
|
||||
$this->view->tabID='projects-submitting';
|
||||
$sql = "SELECT p.*,f.id as fid FROM heiheproject p left join fund f on p.code=f.fund_id WHERE p.status=1";
|
||||
$sth = $this->db->query($sql);
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
|
@ -808,8 +866,8 @@ class HeiheController extends DataController
|
|||
if($ac == "unsubmit")
|
||||
{
|
||||
$this->_helper->viewRenderer('project-index');
|
||||
|
||||
$sql = "SELECT * FROM heiheproject WHERE status=0";
|
||||
$this->view->tabID='projects-unsubmit';
|
||||
$sql = "SELECT p.*,f.id as fid FROM heiheproject p left join fund f on p.code=f.fund_id WHERE p.status=0";
|
||||
$sth = $this->db->query($sql);
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
|
@ -824,8 +882,8 @@ class HeiheController extends DataController
|
|||
if($ac == "submit")
|
||||
{
|
||||
$this->_helper->viewRenderer('project-index');
|
||||
|
||||
$sql = "SELECT * FROM heiheproject WHERE status>0";
|
||||
$this->view->tabID='projects-submit';
|
||||
$sql = "SELECT p.*,f.id as fid FROM heiheproject p left join fund f on p.code=f.fund_id WHERE p.status>0";
|
||||
$sth = $this->db->query($sql);
|
||||
$rows = $sth->fetchAll();
|
||||
|
||||
|
@ -1018,5 +1076,166 @@ class HeiheController extends DataController
|
|||
$sth=$this->wdb->prepare($sql);
|
||||
$sth->execute(array($author,$uuid));
|
||||
}
|
||||
//基于数据作者的浏览(包括认证后的数据作者以及未认证的数据作者)
|
||||
function authorAction()
|
||||
{
|
||||
$ac = $this->_request->getParam('ac');
|
||||
$id = (int)$this->_request->getParam('id');
|
||||
if ($ac=='verified') {
|
||||
//已经认证过的数据作者
|
||||
$this->view->tabID='author-verified';
|
||||
$this->view->ac='verified';
|
||||
if ($id) {
|
||||
//列出作者的数据
|
||||
$sql="select username,realname from users where id=?";
|
||||
$this->view->author=$this->db->fetchRow($sql,array($id));
|
||||
$sql="select m.* from normalmetadata m left join mdauthor a on a.uuid=m.uuid where m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and a.userid=?";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute(array($id));
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(10);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else {
|
||||
//已经认证过的数据作者
|
||||
$sql="select u.username,u.realname,u.id,count(u.id) as count from mdauthor a left join users u on a.userid=u.id where a.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and a.status=1 and a.uuid in (select uuid from normalmetadata) group by u.id,u.username,u.realname";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(50);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
} else if ($ac=='unverified' || empty($ac)) {
|
||||
//未认证的数据作者
|
||||
$this->view->tabID='author-unverified';
|
||||
$this->view->ac='unverified';
|
||||
if ($id) {
|
||||
//列出数据
|
||||
$sql="select individual as username from responsible where id=?";
|
||||
$this->view->author=$this->db->fetchRow($sql,array($id));
|
||||
$sql="select distinct m.* from normalmetadata m left join role r on m.uuid=r.uuid left join responsible s on r.resid=s.id where r.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and r.role in ('pointOfContact','resourceProvider','owner') and s.id=?";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute(array($id));
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(10);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else {
|
||||
//列出所有作者
|
||||
$sql="select distinct responsible.individual as username,responsible.id from responsible left join role on role.resid=responsible.id where role.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and role.role in ('pointOfContact','resourceProvider','owner')";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(50);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function fundAction()
|
||||
{
|
||||
$id = (int)$this->_request->getParam('id');
|
||||
if (!empty($id)) {
|
||||
$sql="select * from fund where id=?";
|
||||
$this->view->fund=$this->db->fetchRow($sql,array($id));
|
||||
if ($this->view->fund) {
|
||||
$sql="select distinct m.* from normalmetadata m left join mdfund mf on m.uuid=mf.uuid where m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and mf.fid=?";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute(array($id));
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(10);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
} 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";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(10);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
$this->_helper->viewRenderer('fund-list');
|
||||
}
|
||||
}
|
||||
|
||||
function orgAction()
|
||||
{
|
||||
$page = $this->_request->getParam('page');
|
||||
$name = $this->_request->getParam('name');
|
||||
$state=$this->db->query("select distinct responsible.organisation from responsible left join role on role.resid=responsible.id where role.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and role.role in ('pointOfContact','resourceProvider','owner')");
|
||||
$this->view->organisation=$state->fetchAll();
|
||||
if (!empty($name)) {
|
||||
$this->view->codename=$name;
|
||||
$sql="select distinct m.* from normalmetadata m left join role r on m.uuid=r.uuid left join responsible s on r.resid=s.id where m.uuid in (select d.uuid from datasource d left join source s on d.sourceid=s.id where s.code='heihe') and r.role in ('pointOfContact','resourceProvider','owner') and s.organisation=?";
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute(array($name));
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(10);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
} else {
|
||||
//提供全部分类列表
|
||||
}
|
||||
}
|
||||
|
||||
//实现基于DOI信息的浏览
|
||||
function doiAction()
|
||||
{
|
||||
$ac = $this->_request->getParam('ac');
|
||||
if ($ac=='unready') {
|
||||
//列出没有DOI的数据
|
||||
$sql="select m.* from normalmetadata m where length(m.doi)<3 and m.uuid not in (select uuid from datadoi) and m.uuid in (select ds.uuid from datasource ds left join source s on ds.sourceid=s.id where s.code='heihe') order by m.ts_created desc";
|
||||
$this->view->tabID='doi-unready';
|
||||
} else if ($ac=='prepare') {
|
||||
//列出有DOI但还未进行提交申请的数据
|
||||
$sql="select m.* from normalmetadata m where length(m.doi)>3 and m.uuid not in (select uuid from datadoi) and m.uuid in (select ds.uuid from datasource ds left join source s on ds.sourceid=s.id where s.code='heihe') order by m.ts_created desc";
|
||||
$this->view->tabID='doi-prepare';
|
||||
} else if ($ac=='unsubmit') {
|
||||
//列出有DOI并计划提交申请的数据
|
||||
$sql="select m.*,d.doi as datadoi,date(d.ts_created) as ts_created from normalmetadata m left join datadoi d on m.uuid=d.uuid where length(m.doi)>3 and d.ts_created is not null and d.ts_submitted is null and m.uuid in (select ds.uuid from datasource ds left join source s on ds.sourceid=s.id where s.code='heihe') order by d.ts_created desc";
|
||||
$this->view->tabID='doi-unsubmit';
|
||||
} else if ($ac=='submit') {
|
||||
//列出有DOI并计划提交申请的数据
|
||||
$sql="select m.*,d.doi as datadoi,date(d.ts_submitted) as ts_submitted from normalmetadata m left join datadoi d on m.uuid=d.uuid where length(m.doi)>3 and d.ts_submitted is not null and d.ts_published is null and m.uuid in (select ds.uuid from datasource ds left join source s on ds.sourceid=s.id where s.code='heihe') order by d.ts_submitted desc,d.ts_created desc";
|
||||
$this->view->tabID='doi-submit';
|
||||
} else if ($ac=='publish' || empty($ac)) {
|
||||
//默认:列出最新发布的DOI数据
|
||||
$sql="select m.*,d.doi as datadoi,date(d.ts_submitted) as ts_submitted,date(d.ts_published) as ts_published from normalmetadata m left join datadoi d on m.uuid=d.uuid where length(m.doi)>3 and d.ts_published is not null and m.uuid in (select ds.uuid from datasource ds left join source s on ds.sourceid=s.id where s.code='heihe') order by d.ts_published desc,d.ts_submitted desc,d.ts_created desc";
|
||||
$this->view->tabID='doi-publish';
|
||||
}
|
||||
$sth = $this->db->prepare($sql);
|
||||
$sth->execute();
|
||||
$rows = $sth->fetchAll();
|
||||
$paginator = Zend_Paginator::factory($rows);
|
||||
$paginator->setCurrentPageNumber($this->_getParam('page'));
|
||||
$paginator->setItemCountPerPage(10);
|
||||
$paginator->setView($this->view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$this->view->paginator=$paginator;
|
||||
}
|
||||
}
|
|
@ -241,7 +241,7 @@ class HiwaterController extends DataController
|
|||
}
|
||||
function bnulaiAction()
|
||||
{
|
||||
$this->getmd(array('','LAI'));
|
||||
$this->getmdlimited('LAI','生态水文无线传感器网络');
|
||||
$this->_helper->viewRenderer('base');
|
||||
}
|
||||
|
||||
|
|
|
@ -7,6 +7,7 @@ class SearchController extends Zend_Controller_Action
|
|||
$this->view->config = Zend_Registry::get('config');
|
||||
$this->messenger=$this->_helper->getHelper('FlashMessenger');
|
||||
$this->view->messages = $this->messenger->getMessages();
|
||||
$this->view->theme = new Theme();
|
||||
$this->view->nav = array(
|
||||
array('link'=>'/','title'=>'<i class="icon-home"></i>'),
|
||||
array('link'=>'/data','title'=>$this->view->config->title->data),
|
||||
|
@ -38,5 +39,15 @@ class SearchController extends Zend_Controller_Action
|
|||
$this->_helper->viewRenderer->setNoRender();
|
||||
header("Content-Type: application/json; charset=utf-8");
|
||||
echo $search->suggest($q);
|
||||
}
|
||||
}
|
||||
function advanceAction()
|
||||
{
|
||||
$this->view->east=$this->getParam('east');
|
||||
$this->view->west=$this->getParam('west');
|
||||
$this->view->south=$this->getParam('south');
|
||||
$this->view->north=$this->getParam('north');
|
||||
$this->view->begin=$this->getParam('begin');
|
||||
$this->view->end=$this->getParam('end');
|
||||
$this->view->q=$this->getParam('q');
|
||||
}
|
||||
}
|
||||
|
|
|
@ -373,10 +373,8 @@ class ServiceController extends Zend_Controller_Action
|
|||
error_reporting(1);
|
||||
if (!empty($uuid))
|
||||
{
|
||||
$sql="select x.data,m.title,m.citation,m.suppinfo,m.doi,m.filesize,m.fileformat,m.south,m.east,m.west,m.north,m.timebegin,m.timeend,m.title_en,m.uuid,m.description,g.id,m.projection,t.filetype,
|
||||
cc.name as category, cc.name_zh as category_zh
|
||||
$sql="select g.data,m.title,m.citation,m.suppinfo,m.doi,m.filesize,m.fileformat,m.south,m.east,m.west,m.north,date(m.timebegin) as timebegin,date(m.timeend) as timeend,m.title_en,m.uuid,m.description,g.id,m.projection,t.filetype
|
||||
from metadata m left join xml x on m.id=x.id left join thumbnail t on x.id=t.id
|
||||
left join category c on c.id=m.id left join categorycode cc on c.code=cc.code
|
||||
left join geonetworkmetadata g on g.uuid=m.uuid where m.uuid=".$this->db->quote($uuid);
|
||||
$row=$this->db->fetchRow($sql);
|
||||
$sql="select r.* from reference r left join mdref m on m.refid=r.id where m.uuid=?";
|
||||
|
@ -387,7 +385,14 @@ class ServiceController extends Zend_Controller_Action
|
|||
{
|
||||
$reference.=($k+1).'. '.str_replace(array("\r\n", "\n", "\r"),'',$refer['reference'])."\r\n";
|
||||
}
|
||||
$row['reference']=$reference;
|
||||
$row['reference']=$reference;
|
||||
$sql="select cc.name as category, cc.name_zh from metadata m left join category c on m.id=c.id left join categorycode cc on c.code=cc.code where m.uuid=".$this->db->quote($uuid);
|
||||
$cat=$this->db->fetchAll($sql);
|
||||
$row['category_zh']='';
|
||||
foreach($cat as $category)
|
||||
{
|
||||
$row['category_zh'].=$category['name_zh'].' ';
|
||||
}
|
||||
$sql="select u.uselimit from mdlimit ml left join metadata m on ml.uuid=m.uuid left join uselimit u on ml.lid=u.id where m.uuid=?";
|
||||
$sql=$this->db->quoteInto($sql,$uuid);
|
||||
$limits=$this->db->fetchAll($sql);
|
||||
|
@ -454,14 +459,13 @@ class ServiceController extends Zend_Controller_Action
|
|||
$this->_helper->layout->disableLayout();
|
||||
$this->_helper->viewRenderer->setNoRender();
|
||||
$uuid=$this->_request->getParam('uuid');
|
||||
$review=$this->_request->getParam('review');
|
||||
$review=$this->_request->getParam('review');
|
||||
$ac=$this->_request->getParam('ac');
|
||||
//error_reporting(1);
|
||||
if (!empty($uuid))
|
||||
{
|
||||
$sql="select x.data,m.title,m.citation,m.suppinfo,m.doi,m.filesize,m.fileformat,m.south,m.east,m.west,m.north,m.timebegin,m.timeend,m.title_en,m.uuid,m.description,g.id,m.projection,t.filetype,
|
||||
cc.name as category, cc.name_zh as category_zh
|
||||
from xml x left join metadata m on m.id=x.id left join thumbnail t on x.id=t.id
|
||||
left join category c on c.id=m.id left join categorycode cc on c.code=cc.code
|
||||
$sql="select g.data,m.title,m.citation,m.suppinfo,m.doi,m.filesize,m.fileformat,m.ts_created,m.south,m.east,m.west,m.north,date(m.timebegin) as timebegin,date(m.timeend) as timeend,m.title_en,m.uuid,m.description,g.id,m.projection,t.filetype
|
||||
from metadata m left join thumbnail t on m.id=t.id
|
||||
left join geonetworkmetadata g on g.uuid=m.uuid where m.uuid=".$this->db->quote($uuid);
|
||||
$row=$this->db->fetchRow($sql);
|
||||
$sql="select r.* from reference r left join mdref m on m.refid=r.id where m.uuid=?";
|
||||
|
@ -472,7 +476,14 @@ class ServiceController extends Zend_Controller_Action
|
|||
{
|
||||
$reference.=($k+1).'. '.str_replace(array("\r\n", "\n", "\r"),'',$refer['reference'])."\r\n";
|
||||
}
|
||||
$row['reference']=$reference;
|
||||
$row['reference']=$reference;
|
||||
$sql="select cc.name as category, cc.name_zh from metadata m left join category c on m.id=c.id left join categorycode cc on c.code=cc.code where m.uuid=".$this->db->quote($uuid);
|
||||
$cat=$this->db->fetchAll($sql);
|
||||
$row['category_zh']='';
|
||||
foreach($cat as $category)
|
||||
{
|
||||
$row['category_zh'].=$category['name_zh'].' ';
|
||||
}
|
||||
$sql="select u.uselimit from mdlimit ml left join metadata m on ml.uuid=m.uuid left join uselimit u on ml.lid=u.id where m.uuid=?";
|
||||
$sql=$this->db->quoteInto($sql,$uuid);
|
||||
$limits=$this->db->fetchAll($sql);
|
||||
|
@ -491,8 +502,10 @@ class ServiceController extends Zend_Controller_Action
|
|||
{
|
||||
$resource.=($k+1).". ".$r['name'].' '.$r['linkage']."\n";
|
||||
}
|
||||
$row['resources']=$resource;
|
||||
$sql="select r.role,s.* from role r left join responsible s on r.resid=s.id left join metadata m on m.uuid=r.uuid where m.uuid=? order by r.role,r.id";
|
||||
$row['resources']=$resource;
|
||||
$sql="select r.role,s.* from role r left join responsible s on r.resid=s.id left join metadata m on m.uuid=r.uuid where m.uuid=? order by r.role,r.id";
|
||||
if ($ac=='simple')
|
||||
$sql="select r.role,s.* from role r left join responsible s on r.resid=s.id left join metadata m on m.uuid=r.uuid where r.role in ('resourceProvider','owner','pointOfContact') and m.uuid=? order by r.role,r.id";
|
||||
$sql=$this->db->quoteInto($sql,$uuid);
|
||||
$contact=$this->db->fetchAll($sql);
|
||||
$contacts="";
|
||||
|
@ -561,22 +574,25 @@ class ServiceController extends Zend_Controller_Action
|
|||
|
||||
require_once('odtphp/library/odf.php');
|
||||
$config["PATH_TO_TMP"]="/tmp/zip";
|
||||
$config["ZIP_PROXY"]="ZipArchive";
|
||||
$odf=new Odf("../data/metadata-template.odt",$config);
|
||||
$config["ZIP_PROXY"]="ZipArchive";
|
||||
if ($ac=='simple')
|
||||
$odf=new Odf("../data/metadata-template-simple.odt",$config);
|
||||
else
|
||||
$odf=new Odf("../data/metadata-template.odt",$config);
|
||||
$odf->setVars('title',$row['title'],true,'utf-8');
|
||||
@$odf->setVars('title_en',$row['title_en'],true,'utf-8');
|
||||
$odf->setVars('uuid',$row['uuid'],true,'utf-8');
|
||||
$odf->setVars('datetime',date('Y-m-d'));
|
||||
@$odf->setVars('uuid',$row['uuid'],true,'utf-8');
|
||||
$odf->setVars('datetime',date('Y-m-d',strtotime($row['ts_created'])));
|
||||
$odf->setVars('abstract',$row['description'],true,'utf-8');
|
||||
@$odf->setVars('theme_keyword',$row['keyword']['theme'],true,'utf-8');
|
||||
@$odf->setVars('place_keyword',$row['keyword']['place'],true,'utf-8');
|
||||
@$odf->setVars('temporal_keyword',empty($row['keyword']['temporal'])?'':$row['keyword']['temporal'],true,'utf-8');
|
||||
@$odf->setVars('discipline_keyword',$row['keyword']['discipline'],true,'utf-8');
|
||||
@$odf->setVars('stratum_keyword',$row['keyword']['stratum'],true,'utf-8');
|
||||
|
||||
@$odf->setVars('category',$row['category'].' '.$row['category_zh'],true,'utf-8');
|
||||
@$odf->setVars('rfdenom',$row['rfdenom'],true,'utf-8');
|
||||
@$odf->setVars('resolution',$row['resolution'],true,'utf-8');
|
||||
@$odf->setVars('projection',$row['projection'],true,'utf-8');
|
||||
|
||||
|
||||
|
||||
@$odf->setVars('filesize',$row['filesize'],true,'utf-8');
|
||||
@$odf->setVars('fileformat',$row['fileformat'],true,'utf-8');
|
||||
@$odf->setVars('timebegin',$row['timebegin'],true,'utf-8');
|
||||
|
@ -584,16 +600,27 @@ class ServiceController extends Zend_Controller_Action
|
|||
@$odf->setVars('citation',$row['citation'],true,'utf-8');
|
||||
@$odf->setVars('reference',$row['reference'],true,'utf-8');
|
||||
@$odf->setVars('doi',$row['doi'],true,'utf-8');
|
||||
@$odf->setVars('suppinfo',$row['suppinfo'],true,'utf-8');
|
||||
@$odf->setVars('uselimits',$row['uselimits'],true,'utf-8');
|
||||
@$odf->setVars('resources',$row['resources'],true,'utf-8');
|
||||
@$odf->setVars('contacts',$row['contacts'],true,'utf-8');
|
||||
|
||||
@$odf->setVars('north',$row['north'],true,'utf-8');
|
||||
@$odf->setVars('south',$row['south'],true,'utf-8');
|
||||
@$odf->setVars('west',$row['west'],true,'utf-8');
|
||||
@$odf->setVars('east',$row['east'],true,'utf-8');
|
||||
$odf->setImage('bigthumb', 'http://westdc.westgis.ac.cn/service/bigthumb/uuid/'.$row['uuid']);
|
||||
$odf->setImage('thumb', 'http://westdc.westgis.ac.cn/service/thumb/uuid/'.$row['uuid']);
|
||||
@$odf->setVars('east',$row['east'],true,'utf-8');
|
||||
if (!$ac=='simple')
|
||||
{
|
||||
@$odf->setImage('bigthumb', 'http://westdc.westgis.ac.cn/service/bigthumb/uuid/'.$row['uuid']);
|
||||
@$odf->setImage('thumb', 'http://westdc.westgis.ac.cn/service/thumb/uuid/'.$row['uuid']);
|
||||
@$odf->setVars('projection',$row['projection'],true,'utf-8');
|
||||
@$odf->setVars('resolution',$row['resolution'],true,'utf-8');
|
||||
@$odf->setVars('rfdenom',$row['rfdenom'],true,'utf-8');
|
||||
@$odf->setVars('stratum_keyword',$row['keyword']['stratum'],true,'utf-8');
|
||||
@$odf->setVars('uselimits',$row['uselimits'],true,'utf-8');
|
||||
@$odf->setVars('resources',$row['resources'],true,'utf-8');
|
||||
@$odf->setVars('suppinfo',$row['suppinfo'],true,'utf-8');
|
||||
@$odf->setVars('contacts',$row['contacts'],true,'utf-8');
|
||||
} else {
|
||||
@$odf->setImage('qrcode', 'http://westdc.westgis.ac.cn/service/qrcode/uuid/'.$row['uuid']);
|
||||
}
|
||||
|
||||
$odf->exportAsAttachedFile($row['title'].'.odt');
|
||||
}
|
||||
|
||||
|
@ -1190,7 +1217,7 @@ class ServiceController extends Zend_Controller_Action
|
|||
$pageSize = 10;//每页容量
|
||||
|
||||
$sql = "select md.title,md.uuid from mdref mr
|
||||
left join metadata md on md.uuid=mr.uuid
|
||||
right join normalmetadata md on md.uuid=mr.uuid
|
||||
where mr.refid=$id";
|
||||
$pagnation="";
|
||||
if(isset($page))
|
||||
|
@ -1502,6 +1529,20 @@ class ServiceController extends Zend_Controller_Action
|
|||
|
||||
$this->getResponse()->setHeader('Content-Type', 'application/json')->appendBody(json_encode($data,JSON_NUMERIC_CHECK));
|
||||
return true;
|
||||
}
|
||||
|
||||
function qrcodeAction()
|
||||
{
|
||||
$this->_helper->layout->disableLayout();
|
||||
$this->_helper->viewRenderer->setNoRender();
|
||||
$uuid = $this->getRequest()->getParam('uuid');
|
||||
$code_params = array('text' => 'http://westdc.westgis.ac.cn/data/'.$uuid,
|
||||
'backgroundColor' => '#FFFFFF',
|
||||
'foreColor' => '#000000',
|
||||
'padding' => 4, //array(10,5,10,5),
|
||||
'moduleSize' => 2);
|
||||
$renderer_params = array('imageType' => 'png');
|
||||
Zend_Matrixcode::render('qrcode', $code_params, 'image', $renderer_params);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -77,8 +77,8 @@ function datareceive(data){
|
|||
var result = new Array();
|
||||
for(i=0;i<data.length;i++)
|
||||
{
|
||||
if(data[i].status==1) var ct='<img src="/images/list_links.gif" />您是此元数据的作者';
|
||||
else if (data[i].status==0) var ct='<img src="/images/list_extensions.gif" />您已经申请成为该元数据作者,请前往 <a href="/author/accept">我的数据</a> 查看<span id="data_'+data[i].uuid+'"></span>';
|
||||
if(data[i].status==1 && data[i].userid==<?php echo $this->id; ?>) var ct='<img src="/images/list_links.gif" />您是此元数据的作者';
|
||||
else if (data[i].status==0 && data[i].userid==<?php echo $this->id; ?>) var ct='<img src="/images/list_extensions.gif" />您已经申请成为该元数据作者,请前往 <a href="/author/accept">我的数据</a> 查看<span id="data_'+data[i].uuid+'"></span>';
|
||||
else var ct='<a href="javascript:;" onclick="apply(\'' +data[i].uuid+ '\')"><img src="/images/list_keys.gif" />申请成为此数据的作者</a><span id="data_'+data[i].uuid+'"></span>';
|
||||
result.push('<li class="well"><h4><a href="/data/'+data[i].uuid+'" target="_blank" class="title">'+data[i].title+'</a></h4><p>'+data[i].description+'</p><p>'+ct+'</p></li>');
|
||||
}
|
||||
|
|
|
@ -36,11 +36,11 @@ foreach($this->metadata as $md) : ?>
|
|||
<div class="row">
|
||||
<div class="span8" id="map_canvas" style="height:500px;"></div>
|
||||
<div class="span4">
|
||||
<form id="search" enctype="application/x-www-form-urlencoded" action="/data/advancesearch" method="post">
|
||||
<form id="search" enctype="application/x-www-form-urlencoded" action="/search" method="get">
|
||||
<fieldset><legend>时间范围</legend>
|
||||
<label>
|
||||
开始时间
|
||||
<input name="start" type="text" id="start" />
|
||||
<input name="begin" type="text" id="begin" />
|
||||
</label>
|
||||
<label>
|
||||
结束时间
|
||||
|
@ -49,13 +49,13 @@ foreach($this->metadata as $md) : ?>
|
|||
</fieldset>
|
||||
<fieldset><legend>空间范围(按住shift键,在地图上拉框)</legend>
|
||||
<label>东
|
||||
<input name="e" id="e" type="text" /></label>
|
||||
<input name="east" id="east" type="text" /></label>
|
||||
<label>南
|
||||
<input name="s" id="s" type="text" /></label>
|
||||
<input name="south" id="south" type="text" /></label>
|
||||
<label>西
|
||||
<input name="w" id="w" type="text" /></label>
|
||||
<input name="west" id="west" type="text" /></label>
|
||||
<label>北
|
||||
<input name="n" id="n" type="text" /></label>
|
||||
<input name="north" id="north" type="text" /></label>
|
||||
</fieldset>
|
||||
<label>关键词
|
||||
<input name="q" id="q" type="text" /></label>
|
||||
|
@ -69,7 +69,7 @@ $(function() {
|
|||
//Google map (不启用预先加载)
|
||||
google.maps.event.addDomListener(window, 'load', initialize);
|
||||
//jquery ui datepicker
|
||||
$("#start").datepicker({dateFormat:"yy-mm-dd"});
|
||||
$("#begin").datepicker({dateFormat:"yy-mm-dd"});
|
||||
$("#end").datepicker({dateFormat:"yy-mm-dd"});
|
||||
});
|
||||
// Google Map Part
|
||||
|
@ -77,7 +77,7 @@ var map = null;
|
|||
var mapElementID = "map_canvas";
|
||||
var bounds = null;
|
||||
var rectangle = null;
|
||||
var input = {east:'#e',west:'#w',north:'#n',south:'#s'};
|
||||
var input = {east:'#east',west:'#west',north:'#north',south:'#south'};
|
||||
|
||||
function initialize() {
|
||||
//加载地图
|
||||
|
@ -196,7 +196,7 @@ function Alert(content){
|
|||
}
|
||||
|
||||
function dosubmit() {
|
||||
theForm.action="/data/advancesearch";
|
||||
theForm.action="/search";
|
||||
}
|
||||
</script>
|
||||
<div id="help">
|
||||
|
|
|
@ -26,7 +26,7 @@ $this->headTitle()->setSeparator(' - ');
|
|||
<input type="text" value="" id="q" name="q" class="span2 search-query" placeholder="全文搜索">
|
||||
<button type="submit" class="btn"><i class="icon-search"></i>搜索</button>
|
||||
</div>
|
||||
<a class="btn" href="/data/advancesearch"><i class="icon-search"></i>高级搜索</a>
|
||||
<a class="btn" href="/search/advance"><i class="icon-search"></i>高级搜索</a>
|
||||
<a class="btn" href="/data/browse"><i class="icon-reorder"></i>数据列表浏览</a>
|
||||
<a class="btn" href="/data/onlinelist"><i class="icon-th"></i>在线数据清单</a>
|
||||
<a class="btn" href="/data/offlinelist"><i class="icon-th"></i>离线数据清单</a>
|
||||
|
|
|
@ -0,0 +1,71 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle('数据作者浏览');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->nav[] = array('link'=>"/heihe/author",'title'=>'作者浏览');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class='row'>
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<ul class="nav nav-tabs">
|
||||
<li id="Nav-author-unverified"><a href="/heihe/author">未认证的数据作者<?php if ($this->author && $this->ac=='unverified') echo ':'.$this->author['username']; ?></a></li>
|
||||
<li id="Nav-author-verified"><a href="/heihe/author/ac/verified">已认证的数据作者<?php if ($this->author && $this->ac=='verified') echo ':'.$this->author['username'].'['.$this->author['realname'].']'; ?></a></li>
|
||||
</ul>
|
||||
<?php if ($this->author) : ?>
|
||||
<?php if (!empty($this->paginator)) : ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php foreach($this->paginator as $md) : ?>
|
||||
<div class="media well well-small">
|
||||
<a class="pull-left colorbox" href="/service/bigthumb/uuid/<?php echo $md['uuid']; ?>">
|
||||
<img class="media-object" src="/service/thumb/id/<?php echo $md['id'];?>">
|
||||
</a>
|
||||
<div class="media-body">
|
||||
<h4 class="media-heading"><a href="/heihe/view/uuid/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a></h4>
|
||||
<?php if (@$md['datadoi']) : ?>
|
||||
<h4 class="media-heading">DOI:<?php echo $md['datadoi'];?>
|
||||
<?php if (@$md['ts_submitted']) : ?> <span class="label label-info">申请日期:<?php echo $md['ts_submitted'];?></span>
|
||||
<?php else: if (@$md['ts_created']) : ?> <span class="label label-info">创建日期:<?php echo $md['ts_created'];?></span> <?php endif; ?>
|
||||
<?php endif; ?>
|
||||
<?php if (@$md['ts_published']) : ?> <span class="label label-success">发布日期:<?php echo $md['ts_published'];?></span><?php endif; ?>
|
||||
</h4>
|
||||
<?php else: if (@$md['doi']): ?>
|
||||
<h4 class="media-heading">DOI:<?php echo $md['doi']; ?></h4>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php endif; ?>
|
||||
<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; ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php endif; ?>
|
||||
<?php else : ?>
|
||||
<?php if (!empty($this->paginator)) : ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<ul class="row">
|
||||
<?php foreach($this->paginator as $author) : ?>
|
||||
<li class="span3"><a href="/heihe/author/ac/<?php echo $this->ac; ?>/id/<?php echo $author['id']; ?>">
|
||||
<?php
|
||||
echo $author['username'];
|
||||
if ($this->ac=='verified') echo '['.$author['realname'].', 共'.$author['count'].'条]';
|
||||
?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" charset="utf-8">
|
||||
$(document).ready(function(){
|
||||
$(".colorbox").colorbox({rel:"colorbox",photo:"true",transition:"fade"});
|
||||
$(".colorbox").colorbox({photo:"true"});
|
||||
});
|
||||
$('#Nav-<?php echo $this->tabID; ?>').addClass("active");
|
||||
</script>
|
|
@ -3,25 +3,15 @@ $this->headTitle($this->config->title->site);
|
|||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('基础数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span3">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span9">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div class="span10">
|
||||
<div id="intro">
|
||||
<p>
|
||||
基础数据指为流域生态-水文研究提供各种自然、生态、水文、社会经济等本底信息的数据,同时还包括了主要的几次科学试验数据、模型数据集等。
|
||||
</p>
|
||||
<p>
|
||||
基础数据主要包括了流域基础地理数据、流域各种专题数据、水文水资源数据、流域科学试验数据、航空遥感和卫星遥感数据、模型数据、社会经济数据等。
|
||||
</p>
|
||||
<?php if(!empty($this->info['body'])) echo $this->info['body'];?>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
|
|
|
@ -8,14 +8,15 @@ $this->breadcrumb('<a href="/">首页</a>');
|
|||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('浏览');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->nav[] = array('link'=>"/browse",'title'=>'整体浏览');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<hr />
|
||||
<div class="mdlist">
|
||||
|
|
|
@ -1,33 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('核心数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>流域核心数据指流域生态-水文模型、陆面过程模型、社会经济模型以及其他各类模型所需要的关键性的驱动和参数数据集以及验证、发展和改进模型所需的关键观测数据。</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,34 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('DEM数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>DEM是数字高程模型的英文简称(Digital Elevation Model),DEM是地貌形态信息的离散表示,这些信息包含流域网格单元的坡度、坡向以及单元格之间的关系等,是开展流域研究的重要原始资料。</p>
|
||||
<p>数据包括黑河全流域范围各种不同分辨率的数字高程模型(DEM)(栅格大小为30m、90m、1000m和30sec)。</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -8,29 +8,16 @@ $this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
|||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('数据文档');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
$this->nav[] = array('link'=>"/heihe/document",'title'=>'数据文档');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div class="span10">
|
||||
<div id="intro">
|
||||
<h3>黑河数据清单:</h3>
|
||||
<ol>
|
||||
<li>数据清单详版2011:年雁云, 吴立宗,李新,冉有华,盖春梅,胡晓利,李红星. 2011. 黑河流域数据清单. 中国科学院寒区旱区环境与工程研究所, 兰州. 246 pp</li>
|
||||
<li>数据清单简版2011</li>
|
||||
</ol>
|
||||
<h3>数字黑河总结文献:</h3>
|
||||
<ol>
|
||||
<li>李新, 程国栋, 吴立宗. 数字黑河的思考与实践1:为流域科学服务的数字流域. 地球科学进展, 2010, 25(3): 297-305.
|
||||
</li>
|
||||
<li>李新, 吴立宗, 马明国, 盖迎春, 冉有华, 王亮绪, 南卓铜. 数字黑河的思考与实践2:数据集成. 地球科学进展, 2010, 25(3): 306-316. </li>
|
||||
<li>Li X, Nan ZT, Cheng GD, Ding YJ, Wu LZ, Wang LX, Wang J, Ran YH, Li HX, Pan XD, Zhu ZM. Toward an improved data stewardship and service for environmental and ecological science data in west China. International Journal of Digital Earth, 2011, 4(4): 347-359. DOI: 10.1080/17538947.2011.558123. </li>
|
||||
</ol>
|
||||
</div>
|
||||
<hr />
|
||||
<h3>数据相关文献</h3>
|
||||
<?php if ($this->refs) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
|
|
|
@ -0,0 +1,60 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle('DOI浏览');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->nav[] = array('link'=>"/heihe/doi",'title'=>'DOI浏览');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<ul class="nav nav-tabs">
|
||||
<li id="Nav-doi-publish"><a href="/heihe/doi">已发布DOI的数据</a></li>
|
||||
<li id="Nav-doi-submit"><a href="/heihe/doi/ac/submit">已提交DOI申请的数据</a></li>
|
||||
<li id="Nav-doi-unsubmit"><a href="/heihe/doi/ac/unsubmit">未提交DOI申请的数据</a></li>
|
||||
<li id="Nav-doi-prepare"><a href="/heihe/doi/ac/prepare">准备申请DOI的数据</a></li>
|
||||
<li id="Nav-doi-unready"><a href="/heihe/doi/ac/unready">无DOI的数据</a></li>
|
||||
</ul>
|
||||
|
||||
<?php if (!empty($this->paginator)) : ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php foreach($this->paginator as $md) : ?>
|
||||
<div class="media well well-small">
|
||||
<a class="pull-left colorbox" href="/service/bigthumb/uuid/<?php echo $md['uuid']; ?>">
|
||||
<img class="media-object" src="/service/thumb/id/<?php echo $md['id'];?>">
|
||||
</a>
|
||||
<div class="media-body">
|
||||
<h4 class="media-heading"><a href="/heihe/view/uuid/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a></h4>
|
||||
<?php if (@$md['datadoi']) : ?>
|
||||
<h4 class="media-heading">DOI:<?php echo $md['datadoi'];?>
|
||||
<?php if (@$md['ts_submitted']) : ?> <span class="label label-info">申请日期:<?php echo $md['ts_submitted'];?></span>
|
||||
<?php else: if (@$md['ts_created']) : ?> <span class="label label-info">创建日期:<?php echo $md['ts_created'];?></span> <?php endif; ?>
|
||||
<?php endif; ?>
|
||||
<?php if (@$md['ts_published']) : ?> <span class="label label-success">发布日期:<?php echo $md['ts_published'];?></span><?php endif; ?>
|
||||
</h4>
|
||||
<?php else: if (@$md['doi']): ?>
|
||||
<h4 class="media-heading">DOI:<?php echo $md['doi']; ?></h4>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php endif; ?>
|
||||
<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; ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php else : ?>
|
||||
暂无对应信息。
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" charset="utf-8">
|
||||
$(document).ready(function(){
|
||||
$(".colorbox").colorbox({rel:"colorbox",photo:"true",transition:"fade"});
|
||||
$(".colorbox").colorbox({photo:"true"});
|
||||
$('#Nav-<?php echo $this->tabID; ?>').addClass("active");
|
||||
});
|
||||
</script>
|
|
@ -1,35 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('社会经济数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>
|
||||
各类社会经济数据。
|
||||
</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,26 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle('支持项目');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->nav[] = array('link'=>"/fund",'title'=>'项目浏览');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class='row'>
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<?php if (!empty($this->paginator)) : ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php foreach($this->paginator as $md) : ?>
|
||||
<div class="well">
|
||||
<h4><a href="/heihe/fund/id/<?php echo $md['id'];?>"><?php echo $this->escape($md['title']);?></a></h4>
|
||||
编号:<?php echo $md['fund_id']; ?> | 类型:<?php echo $md['fund_type']; ?> | 提供数据集:<?php echo $md['datacount']; ?>条,<?php echo $md['filesize']>5000?(round($md['filesize']/1024,2)).'GB':$md['filesize'].'MB'; ?></div>
|
||||
<?php endforeach; ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php else : ?>
|
||||
暂无对应信息。
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,43 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle('支持项目');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->nav[] = array('link'=>"/fund",'title'=>'项目浏览');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class='row'>
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div class="well">
|
||||
<h4><a href="/hiwater/fund/id/<?php echo $this->fund['id'];?>"><?php echo $this->escape($this->fund['title']);?></a></h4>
|
||||
编号:<?php echo $this->fund['fund_id']; ?> | 类型:<?php echo $this->fund['fund_type']; ?>
|
||||
</div>
|
||||
<?php if (!empty($this->paginator)) : ?>
|
||||
<hr />
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php foreach($this->paginator as $md) : ?>
|
||||
<div class="media well well-small">
|
||||
<a class="pull-left colorbox" href="/service/bigthumb/uuid/<?php echo $md['uuid']; ?>">
|
||||
<img class="media-object" src="/service/thumb/id/<?php echo $md['id'];?>">
|
||||
</a>
|
||||
<div class="media-body">
|
||||
<h4 class="media-heading"><a href="/heihe/view/uuid/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a></h4>
|
||||
<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; ?>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php else : ?>
|
||||
暂无对应信息。
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<script type="text/javascript" charset="utf-8">
|
||||
$(document).ready(function(){
|
||||
$(".colorbox").colorbox({rel:"colorbox",photo:"true",transition:"fade"});
|
||||
$(".colorbox").colorbox({photo:"true"});
|
||||
});
|
||||
</script>
|
|
@ -1,32 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('基础地理数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class='span10'>
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,39 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('水文观测数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>
|
||||
黑河流域的基本水文观测站点共计30个,其中包括了水文站18个,雨量站12个。
|
||||
按照水文站点实际控制黑河流域的状况,我们收集了黑河流域范围10个核心水文站的水文数据,
|
||||
其中主要包括了位于黑河上游东、西支的祁连站、扎马什克站,黑河干流的莺落峡站、高崖站、正义峡站,
|
||||
位于黑河第二大支流-梨园河的肃南站、梨园堡站(控制主要灌区),其他支流上的李桥站、冰沟站等,
|
||||
以及黑河下游的额济纳旗站。
|
||||
</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -7,20 +7,16 @@ $this->breadcrumb('<a href="/">首页</a>');
|
|||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb($this->config->title->heihe);
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div class="span10">
|
||||
<div id="intro">
|
||||
<h1>黑河流域数据简介</h1>
|
||||
<p>
|
||||
黑河流域是我国第二大内陆河流域,从流域上游到下游,以水为纽带形成了“冰雪/冻土-森林-草原-河流-湖泊-绿洲-沙漠-戈壁”的多元自然景观,流域内寒区和干旱区并存,山区冰冻圈和极端干旱的河流尾闾地区形成了鲜明对比。与此同时,黑河开发历史悠久,人类活动显著地影响了流域的水文环境,2000多年来,这一地区的农业开发,屯田垦殖,多种文化的碰撞交流、此消彼长,无不与水深刻地联系在一起。自然和人文过程交汇在一起,使黑河流域成为开展流域综合研究的一个十分理想的试验流域。
|
||||
无论从黑河流域独特的自然地理环境,还是从几千年的人类活动影响,黑河流域都是我国内陆河研究的重要基地。目前,大量科学研究与实验积累下来的丰富和宝贵的资料,为流域生态水文研究奠定了很好的科学数据基础。
|
||||
</p>
|
||||
<p>黑河流域各种类型的空间数据,其空间坐标系统主要包括了以下三个类型:WGS84坐标系,ALBERS坐标系,高斯坐标系。其中WGS84坐标系采用原点是地球质心,椭球体为WGS84椭球体,主要考虑到许多来自GPS野外定位测量的数据和国际组织机构发布的空间数据使用这一坐标系;ALBERS坐标系采用Krasovsky椭球体,两根标准纬线分别为北纬25度和北纬47度,中央经线采用东经105度,该坐标系主要在小比例尺而且要求保持等面积特性的数据情况下使用,如小于1:100万比例尺的数据,同时该投影与我国小比例尺专题图的投影是吻合的,有助于和这些数据的配准;高斯坐标系采用Krasovsky椭球体,中央经线采用东经99度,假东取500Km,该坐标系适用于大于等于50万比例尺的各类空间数据。</p>
|
||||
<h2>黑河流域数据简介</h2>
|
||||
<?php if(!empty($this->info['body'])) echo $this->info['body'];?>
|
||||
</div>
|
||||
<div id="heihe_ad">
|
||||
<h2>已整理数据展示</h2>
|
||||
|
|
|
@ -1,39 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('水文观测数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>
|
||||
黑河流域中游的水资源模拟主要是针对地表径流、地下水以及地表水与地下水相互转换等内容来开展,
|
||||
而对绿洲灌溉系统的水资源利用工作相对较少,这主要是因为没有绿洲灌溉系统的详细信息。如果能够获得渠系灌溉和机井灌溉的用水量信息,
|
||||
就可以更为完整地模拟整个黑河流域中游的水资源利用特征,为优化水资源利用提供参考依据。
|
||||
这些数据为中游地区水文水资源模型建模工作提供了数据支撑,也为政府部门特别是水务部门的灌溉管理提供了重要的数据支持,为电子水务提供了可能性。
|
||||
</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,33 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('陆地表层数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>陆地表层数据包括冰川、沙漠、草场、植被、地貌等数据。</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,33 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('土地利用数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>1:10万土地利用数据是在中国科学院“八五”重大应用项目《全国资源环境遥感宏观调查与动态研究》组织了中国科学院所属19个研究所的遥感科技队伍,以卫星遥感为手段,在三年内基于Landsat MSS,TM和ETM遥感数据建立了中国1:10万土地利用影像和矢量数据库。</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,35 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('气象观测数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>
|
||||
黑河流域及其周边地区的气象常规观测站点共21个。观测要素包括日平均气压、最高气压、最低气压、平均气温、最高气温、最低气温、平均相对湿度、最小相对湿度、平均风速、最大风速及风向、极大风速及风向、日照时数、降水量。
|
||||
</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,35 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('模型数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>
|
||||
包括大气驱动数据、辐射数据、SWAT模型数据等。
|
||||
</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,6 +1,6 @@
|
|||
<ul class="nav nav-pills nav-stacked">
|
||||
<li id="Nav-heihe-index"><a href="/heihe/">黑河流域数据简介</a></li>
|
||||
<li id="Nav-heihe-core"><a href="/heihe/core">核心数据</a>
|
||||
<!--<li id="Nav-heihe-core"><a href="/heihe/core">核心数据</a>
|
||||
<ul class="nav nav-list heihe-subnav">
|
||||
<li id="Nav-heihe-dem"><i class="icon-chevron-right"></i><a href="/heihe/dem">DEM数据</a></li>
|
||||
<li id="Nav-heihe-landuse"><i class="icon-chevron-right"></i><a href="/heihe/landuse">土地利用数据</a></li>
|
||||
|
@ -20,17 +20,21 @@
|
|||
<li id="Nav-heihe-model"><i class="icon-chevron-right"></i><a href="/heihe/model">模型数据</a></li>
|
||||
<li id="Nav-heihe-economic"><i class="icon-chevron-right"></i><a href="/heihe/economic">社会经济数据</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</li> -->
|
||||
</ul>
|
||||
<ul class="nav nav-pills nav-stacked">
|
||||
<li id="Nav-heihe-document"><a href="/heihe/document">黑河文档</a></li>
|
||||
<!-- <li id="Nav-heihe-list"><a href="/heihe/list">数据列表</a></li> -->
|
||||
<li id="Nav-heihe-browse"><a href="/heihe/browse">整体浏览</a></li>
|
||||
<!-- <li id="Nav-heihe-list"><a href="/heihe/list">数据列表</a></li> -->
|
||||
<li id="Nav-heihe-fund"><a href="/heihe/fund"><i class="icon-arrow-right pull-right"></i>项目浏览</a></li>
|
||||
<li id="Nav-heihe-browse"><a href="/heihe/browse"><i class="icon-arrow-right pull-right"></i>整体浏览</a></li>
|
||||
<!-- <li id="Nav-heihe-category"><a href="/heihe/category">ISO19115分类</a></li> -->
|
||||
<li id="Nav-heihe-thumb"><a href="/heihe/thumb">缩略图浏览</a></li>
|
||||
<li id="Nav-heihe-tag"><a href="/heihe/tag">关键词导航</a></li>
|
||||
<li id="Nav-heihe-timeline"><a href="/heihe/timeline">时间轴导航</a></li>
|
||||
<li id="Nav-heihe-timemap"><a href="/heihe/timemap">时空联合导航</a></li>
|
||||
<li id="Nav-heihe-thumb"><a href="/heihe/thumb"><i class="icon-arrow-right pull-right"></i>缩略图浏览</a></li>
|
||||
<li id="Nav-heihe-tag"><a href="/heihe/tag"><i class="icon-arrow-right pull-right"></i>关键词导航</a></li>
|
||||
<li id="Nav-heihe-timeline"><a href="/heihe/timeline"><i class="icon-arrow-right pull-right"></i>时间轴导航</a></li>
|
||||
<li id="Nav-heihe-timemap"><a href="/heihe/timemap"><i class="icon-arrow-right pull-right"></i>时空联合导航</a></li>
|
||||
<li id="Nav-heihe-document"><a href="/heihe/document"><i class="icon-arrow-right pull-right"></i>黑河文献文档</a></li>
|
||||
<li id="Nav-heihe-author"><a href="/heihe/author"><i class="icon-arrow-right pull-right"></i>作者浏览</a></li>
|
||||
<li id="Nav-heihe-org"><a href="/heihe/org"><i class="icon-arrow-right pull-right"></i>单位浏览</a></li>
|
||||
<li id="Nav-heihe-doi"><a href="/heihe/doi"><i class="icon-arrow-right pull-right"></i>DOI浏览</a></li>
|
||||
<!-- <li>WebGIS地图浏览</li>
|
||||
<li>黑河计划数据汇交</li>
|
||||
<li>数据使用协议</li> -->
|
||||
|
|
|
@ -1,45 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('观测试验数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<ol>
|
||||
<li><a href="/water">黑河综合遥感联合试验</a></li>
|
||||
<p>
|
||||
“黑河综合遥感联合试验” (WATER试验)的总体目标是:开展航空卫星遥感与地面观测同步试验,为发展流域科学积累基础数据;发展能够融合多源遥感观测的流域尺度陆面数据同化系统,为实现卫星遥感对流域的动态监测提供方法和范例。
|
||||
</p>
|
||||
<p>
|
||||
主要研究内容包括:(1)上游寒区水文试验;(2)森林水文试验;(3)中游干旱区水文试验;(4)模拟平台和数据平台;(5)综合集成研究。
|
||||
“黑河综合遥感联合试验”分为试验准备期、预试验期、加强试验和持续观测期4个阶段。其中,预试验在2007年7~12月展开。加强试验在2008年3月~9月间分阶段展开,共计120天,由28个单位280多名科研人员、研究生和工程技术人员参加。2009年底完成了持续观测试验。
|
||||
</p>
|
||||
<p>
|
||||
试验使用了5类传感器(L, K和Ka波段微波辐射计、激光雷达、高光谱成像仪、红外广角双模式成像仪和多光谱CCD相机)完成了25个有效架次的航空遥感试验。在地面建立了包括12个加强自动气象站、5个涡动相关通量站、2个大孔径闪烁仪以及大量业务气象站和水文站在内加密的地面气象水文和通量观测网,使用了车载降雨雷达、地基微波辐射计、地基散射计、地基激光雷达、探地雷达等地面设备和大量自动观测仪器,获取了丰富的积雪、地表冻融、森林结构、蒸散发、土壤水分、反照率/反射率、地表温度、生物物理参数和生物化学参数。
|
||||
</p>
|
||||
</ol>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="2">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,50 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle('分单位浏览');
|
||||
if (!empty($this->codename)) $this->headTitle($this->codename);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->nav[] = array('link'=>"/heihe/org",'title'=>'分单位浏览');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
|
||||
|
||||
|
||||
<?php if (!empty($this->paginator)) : ?>
|
||||
<h3>当前浏览:<?php echo $this->codename; ?></h3>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<ul id="datalist">
|
||||
<?php foreach($this->paginator as $md) : ?>
|
||||
<div class="media well well-small">
|
||||
<a class="pull-left colorbox" href="/service/bigthumb/uuid/<?php echo $md['uuid']; ?>">
|
||||
<img class="media-object" src="/service/thumb/id/<?php echo $md['id'];?>" data-src="holder.js/128x128">
|
||||
</a>
|
||||
<div class="media-body">
|
||||
<h4 class="media-heading"><a href="/heihe/view/uuid/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a></h4>
|
||||
<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; ?>
|
||||
</ul>
|
||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||
<?php else : ?>
|
||||
<div class="row-fluid">
|
||||
<ul class="nav nav-pills">
|
||||
<?php foreach($this->organisation as $cg) : ?>
|
||||
<li><a href='/heihe/org/name/<?php echo $cg['organisation']; ?>'><?php print($cg['organisation']); ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ul></div>
|
||||
<?php endif; ?>
|
||||
</div></div>
|
||||
<script type="text/javascript" charset="utf-8">
|
||||
$(document).ready(function(){
|
||||
$(".colorbox").colorbox({rel:"colorbox",photo:"true",transition:"fade"});
|
||||
$(".colorbox").colorbox({photo:"true"});
|
||||
});
|
||||
</script>
|
|
@ -9,24 +9,25 @@ $this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
|||
$this->breadcrumb('数据汇交计划');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
$this->nav[] = array('link'=>"/heihe/projects",'title'=>'数据汇交计划');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<?php if(!empty($this->error)) {?>
|
||||
<div id="intro"><?php echo $this->error;?></div>
|
||||
<?php } else{ ?>
|
||||
<div style="overflow:hidden;">
|
||||
<div>
|
||||
<ul class="nav nav-pills">
|
||||
<li><a class="text-shadow" href="/heihe/projects/">所有项目</a></li>
|
||||
<li><a class="text-shadow" href="/heihe/projects/ac/my">我负责的</a></li>
|
||||
<li><a class="text-shadow" href="/heihe/projects/ac/submit">已提交</a></li>
|
||||
<li><a class="text-shadow" href="/heihe/projects/ac/submitting">专家未审核</a></li>
|
||||
<li><a class="text-shadow" href="/heihe/projects/ac/unsubmit">未提交</a></li>
|
||||
<ul class="nav nav-tabs">
|
||||
<li id="Nav-projects-index"><a class="text-shadow" href="/heihe/projects/">所有项目</a></li>
|
||||
<li id="Nav-projects-my"><a class="text-shadow" href="/heihe/projects/ac/my">我负责的</a></li>
|
||||
<li id="Nav-projects-submit"><a class="text-shadow" href="/heihe/projects/ac/submit">已提交</a></li>
|
||||
<li id="Nav-projects-submitting"><a class="text-shadow" href="/heihe/projects/ac/submitting">专家未审核</a></li>
|
||||
<li id="Nav-projects-unsubmit"><a class="text-shadow" href="/heihe/projects/ac/unsubmit">未提交</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<?php if(!empty($this->searchLink)){ ?>
|
||||
|
@ -51,7 +52,7 @@ $this->theme->AppendPlus($this,'colorbox');
|
|||
$autoindex++;
|
||||
?>
|
||||
<li class="well well-small">
|
||||
<p><span class="title"><?= $autoindex ?>.<?php echo $item['title'];?></span></p>
|
||||
<p><span class="title"><?= $autoindex ?>.<?php echo $item['title'];?></span> <a href="/heihe/fund/id/<?php echo $item['fid'];?>">数据产出</a></p>
|
||||
<p>
|
||||
编号:<?= $item['code'];?> |
|
||||
负责人:<?= $item['name'];?> |
|
||||
|
@ -83,5 +84,6 @@ $this->theme->AppendPlus($this,'colorbox');
|
|||
<script type="text/javascript" charset="utf-8">
|
||||
$(document).ready(function(){
|
||||
$(".iframe").colorbox({iframe:true, width:"80%", height:"80%"});
|
||||
$('#Nav-<?php echo $this->tabID; ?>').addClass("active");
|
||||
});
|
||||
</script>
|
||||
|
|
|
@ -1,32 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('遥感数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -11,13 +11,14 @@ $this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
|||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('快速搜索');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->nav[] = array('link'=>"/heihe/search",'title'=>'快速搜索');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class='row'>
|
||||
<div class='span2'>
|
||||
<?= $this->partial('heihe/navi.phtml',array('key'=>$this->key)); ?>
|
||||
</div>
|
||||
<div class='span10'>
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<?php if (!empty($this->metadata)) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<hr />
|
||||
|
|
|
@ -1,35 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('土壤数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>
|
||||
黑河流域已有的土壤数据主要包括了陆面过程模型和水文模型所需要的土壤质地数据,同时也提供了国内资源环境科学研究常用的土壤类型数据。
|
||||
</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,38 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('新建元数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<?php if(!empty($this->error)) {?>
|
||||
<div id="intro"><?php echo $this->error;?></div>
|
||||
<?php }else{?>
|
||||
<div>
|
||||
<ul class="nav nav-pills">
|
||||
<li class="active"><a href="/heihe/submit/">汇交计划首页</a></li>
|
||||
<li><a href="/heihe/submit/ac/newdata">根据模板创建元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/newdata/do/add">根据已有数据创建元数据</a></li>
|
||||
<li><a class="iframe" href="/service/geonetwork?url=metadata.xmlinsert.form">导入元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/unsubmit">未提交元数据</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" charset="utf-8">
|
||||
$(document).ready(function(){
|
||||
$(".iframe").colorbox({iframe:true, width:"80%", height:"80%"});
|
||||
});
|
||||
</script>
|
|
@ -9,23 +9,23 @@ $this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
|||
$this->breadcrumb('新建元数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
$this->nav[] = array('link'=>"/heihe/submit",'title'=>'数据汇交');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<?php if(!empty($this->error)) {?>
|
||||
<div id="intro"><?php echo $this->error;?></div>
|
||||
<?php }else{?>
|
||||
<div>
|
||||
<ul class="nav nav-pills">
|
||||
<li><a href="/heihe/submit/">汇交计划首页</a></li>
|
||||
<ul class="nav nav-tabs">
|
||||
<li><a href="/heihe/submit/ac/unsubmit">未提交元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/newdata">根据模板创建元数据</a></li>
|
||||
<li class="active"><a href="/heihe/submit/ac/newdata/do/add">根据已有数据创建元数据</a></li>
|
||||
<li><a class="iframe" href="/service/geonetwork?url=metadata.xmlinsert.form">导入元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/unsubmit">未提交元数据</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="datalist">
|
||||
|
|
|
@ -8,24 +8,24 @@ $this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
|||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('新建元数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
$this->nav[] = array('link'=>"/heihe/submit",'title'=>'数据汇交');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<?php if(!empty($this->error)) {?>
|
||||
<div id="intro"><?php echo $this->error;?></div>
|
||||
<?php }else{?>
|
||||
<div>
|
||||
<ul class="nav nav-pills">
|
||||
<li><a href="/heihe/submit/">汇交计划首页</a></li>
|
||||
<ul class="nav nav-tabs">
|
||||
<li><a href="/heihe/submit/ac/unsubmit">未提交元数据</a></li>
|
||||
<li class="active"><a href="/heihe/submit/ac/newdata">根据模板创建元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/newdata/do/add">根据已有数据创建元数据</a></li>
|
||||
<li><a class="iframe" href="/service/geonetwork?url=metadata.xmlinsert.form">导入元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/unsubmit">未提交元数据</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div>
|
||||
|
|
|
@ -8,21 +8,21 @@ $this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
|||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('数据列表');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
$this->nav[] = array('link'=>"/heihe/submit",'title'=>'数据汇交');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div>
|
||||
<ul class="nav nav-pills">
|
||||
<li><a href="/heihe/submit/">汇交计划首页</a></li>
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a href="/heihe/submit/ac/unsubmit">未提交元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/newdata">根据模板创建元数据</a></li>
|
||||
<li><a href="/heihe/submit/ac/newdata/do/add">根据已有数据创建元数据</a></li>
|
||||
<li><a class="iframe" href="/service/geonetwork?url=metadata.xmlinsert.form">导入元数据</a></li>
|
||||
<li class="active"><a href="/heihe/submit/ac/unsubmit">未提交元数据</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<?php if(!empty($this->error)) {?>
|
||||
|
|
|
@ -4,18 +4,14 @@ $this->headTitle($this->config->title->data);
|
|||
if (!empty($this->codename)) $this->headTitle($this->codename);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('关键词导航'.(($this->codename)?':'.$this->codename:''));
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->nav[] = array('link'=>"/heihe/tag",'title'=>'关键词浏览');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml'); ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div class="span10">
|
||||
<?php if (!empty($this->metadata)) : ?>
|
||||
<div id='mdlist'>
|
||||
<h1>关键词:<?php echo $this->codename; ?> 【<a href="/heihe/tag/">全部关键词</a>】</h1>
|
||||
|
@ -33,22 +29,27 @@ $this->breadcrumb()->setSeparator(' > ');
|
|||
</div>
|
||||
<?php else : ?>
|
||||
|
||||
<div id='links'>
|
||||
<div>
|
||||
<?php
|
||||
$keytypezh=array('place'=>'地点关键词','theme'=>'主题关键词','discipline'=>'学科关键词','stratum'=>'地层关键词','temporal'=>'时间关键词');
|
||||
foreach($this->keywords as $type=>$kcg) :
|
||||
if (is_array($kcg) && count($kcg)>0 ) :
|
||||
?>
|
||||
<fieldset><legend><?php echo $keytypezh[$type]; ?></legend>
|
||||
<ul>
|
||||
<?php foreach($kcg as $cg) : ?>
|
||||
<li><a href='/heihe/tag/key/<?php echo urlencode($cg['keyword']); ?>'><?php echo $cg['keyword']; ?></a><span class="note">(<?php echo $cg['count']; ?>)</span></li>
|
||||
<?php endforeach; ?>
|
||||
|
||||
</ul>
|
||||
</fieldset>
|
||||
<?php endif;endforeach; ?>
|
||||
</div>
|
||||
$type='';
|
||||
foreach($this->keywords as $cg) :
|
||||
if ($type!=$cg['keytype']) :
|
||||
if ($type!='') : ?>
|
||||
</ul>
|
||||
<?php endif;
|
||||
$type=$cg['keytype'];
|
||||
?>
|
||||
<h4><a href="/heihe/tag/keytype/<?php echo $type; ?>"><?php echo $keytypezh[$type]; ?></a>
|
||||
<?php if ($this->keytype) : ?><a class="pull-right" href="/heihe/tag"><i class="icon-tags"></i>全部关键词</a> <?php endif; ?></h4>
|
||||
<ul class="inline">
|
||||
<li><a href='/heihe/tag/key/<?php echo urlencode($cg['keyword']); ?>'><i class="icon-tag"></i><?php echo $cg['keyword']; ?></a><span class="note">(<?php echo $cg['count']; ?>)</span></li>
|
||||
<?php else : ?>
|
||||
<li><a href='/heihe/tag/key/<?php echo urlencode($cg['keyword']); ?>'><i class="icon-tag"></i><?php echo $cg['keyword']; ?></a><span class="note">(<?php echo $cg['count']; ?>)</span></li>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset></div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle('全部浏览');
|
||||
$this->headTitle('缩略图浏览');
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
|
@ -11,13 +11,14 @@ $this->breadcrumb('缩略图浏览');
|
|||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
$this->theme->AppendPlus($this,'masonry');
|
||||
?>
|
||||
$this->nav[] = array('link'=>"/thumb",'title'=>'缩略图浏览');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<hr />
|
||||
<div>
|
||||
|
|
|
@ -12,13 +12,14 @@ $this->breadcrumb()->setSeparator(' > ');
|
|||
$this->headScript()->appendFile('/js/timeline_var.js');
|
||||
$this->headScript()->appendFile('/js/timeline_js/timeline-api.js');
|
||||
$this->headScript()->appendFile('/js/heihetime.js');
|
||||
?>
|
||||
$this->nav[] = array('link'=>"/heihe/timeline",'title'=>'时间轴导航');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div class="span10">
|
||||
<div id="tl" class="timeline-default" style="height:600px;"> </div>
|
||||
</div>
|
||||
</div>
|
|
@ -15,7 +15,9 @@ $this->headScript()->appendFile('/js/timeline_var.js');
|
|||
$this->headScript()->appendFile('/js/timeline_js/timeline-api.js');
|
||||
$this->headScript()->appendFile('/js/timemap.2.0.1/lib/mxn/mxn.js?(googlev3)');
|
||||
$this->headScript()->appendFile('/js/timemap.2.0.1/timemap.pack.js');
|
||||
$this->nav[] = array('link'=>"/heihe/timemap",'title'=>'时空联合导航');
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<style>
|
||||
img{max-width:none}
|
||||
</style>
|
||||
|
@ -23,8 +25,7 @@ img{max-width:none}
|
|||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div class="span10">
|
||||
<div id="timemap">
|
||||
<div id="map" style="height:500px;width:40%;float:right;"></div>
|
||||
<div id="timeline" style="height:500px;border-right:1px solid #abc;"></div>
|
||||
|
|
|
@ -11,7 +11,8 @@
|
|||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->theme->AppendPlus($this,'google_map_v3');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
?>
|
||||
<?= $this->render('breadcrumbs.phtml') ?>
|
||||
<style>
|
||||
h3.gs_rt{font-size:110%;}
|
||||
</style>
|
||||
|
@ -21,7 +22,6 @@ h3.gs_rt{font-size:110%;}
|
|||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<h3><?php echo $this->escape($md->title);
|
||||
if ($md->title_en) echo '<br />'.$this->escape($md->title_en);?>
|
||||
</h3>
|
||||
|
|
|
@ -1,39 +0,0 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/water.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('<a href="/heihe/">'.$this->config->title->heihe.'</a>');
|
||||
$this->breadcrumb('水文水资源数据');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="span2">
|
||||
<?= $this->partial('heihe/navi.phtml'); ?>
|
||||
</div>
|
||||
<div class="span10">
|
||||
<div><?= $this->breadcrumb() ?> </div>
|
||||
<div id="intro">
|
||||
<p>
|
||||
黑河流域的基本水文观测站点共计30个,其中包括了水文站18个,雨量站12个。
|
||||
按照水文站点实际控制黑河流域的状况,我们收集了黑河流域范围10个核心水文站的水文数据,
|
||||
其中主要包括了位于黑河上游东、西支的祁连站、扎马什克站,黑河干流的莺落峡站、高崖站、正义峡站,
|
||||
位于黑河第二大支流-梨园河的肃南站、梨园堡站(控制主要灌区),其他支流上的李桥站、冰沟站等,
|
||||
以及黑河下游的额济纳旗站。
|
||||
</p>
|
||||
</div>
|
||||
<hr />
|
||||
<?php if ($this->metadata) : ?>
|
||||
<?php echo $this->page->getNavigation(); ?>
|
||||
<div id="mdlist">
|
||||
<ol start="<?php echo $this->offset; ?>">
|
||||
<?php foreach($this->metadata as $md) : ?>
|
||||
<li><a href="/heihe/view/uuid/<?php echo $md['uuid']; ?>"><?php echo $md['title']; ?></a></li>
|
||||
<?php endforeach; ?>
|
||||
</ol>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,212 @@
|
|||
<?php
|
||||
$this->headTitle($this->config->title->site);
|
||||
$this->headTitle($this->config->title->data);
|
||||
$this->headTitle('高级搜索');
|
||||
if (!empty($this->codename)) $this->headTitle($this->codename);
|
||||
$this->headTitle()->setSeparator(' - ');
|
||||
$this->headLink()->appendStylesheet('/css/metadata.css');
|
||||
$this->breadcrumb('<a href="/">首页</a>');
|
||||
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
|
||||
$this->breadcrumb('高级搜索');
|
||||
$this->breadcrumb()->setSeparator(' > ');
|
||||
$this->theme->AppendPlus($this,'google_map_v3');
|
||||
$this->theme->AppendPlus($this,'google_map_keydragzone');
|
||||
$this->theme->AppendPlus($this,'jquery_ui');
|
||||
$this->theme->AppendPlus($this,'colorbox');
|
||||
?>
|
||||
<div>
|
||||
<?= $this->partial('data/tools.phtml'); ?>
|
||||
</div>
|
||||
<?php if (!empty($this->metadata)) :
|
||||
echo $this->page->getNavigation();?>
|
||||
<hr />
|
||||
|
||||
<?php
|
||||
foreach($this->metadata as $md) : ?>
|
||||
<div class="mditem">
|
||||
<div class="thumb"><img src="/service/thumb/id/<?php echo $md['id'];?>" /></div>
|
||||
<h2><a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a>
|
||||
</h2>
|
||||
<span><?php echo mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']);?></span>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
<?php echo $this->page->getNavigation();?>
|
||||
<?php else: ?>
|
||||
|
||||
<div class="row">
|
||||
<div class="span8" id="map_canvas" style="height:500px;"></div>
|
||||
<div class="span4">
|
||||
<form id="search" enctype="application/x-www-form-urlencoded" action="/search" method="get">
|
||||
<fieldset><legend>时间范围</legend>
|
||||
<label>
|
||||
开始时间
|
||||
<input name="begin" type="text" id="begin" value="<?php echo $this->begin; ?>"/>
|
||||
</label>
|
||||
<label>
|
||||
结束时间
|
||||
<input name="end" type="text" id="end" value="<?php echo $this->end; ?>" />
|
||||
</label>
|
||||
</fieldset>
|
||||
<fieldset><legend>空间范围(按住shift键,在地图上拉框)</legend>
|
||||
<label>东
|
||||
<input name="east" id="east" type="text" value="<?php echo $this->east; ?>"/></label>
|
||||
<label>南
|
||||
<input name="south" id="south" type="text" value="<?php echo $this->south; ?>" /></label>
|
||||
<label>西
|
||||
<input name="west" id="west" type="text" value="<?php echo $this->west; ?>" /></label>
|
||||
<label>北
|
||||
<input name="north" id="north" type="text" value="<?php echo $this->north; ?>" /></label>
|
||||
</fieldset>
|
||||
<label>关键词
|
||||
<input name="q" id="q" type="text" value="<?php echo $this->q; ?>"/></label>
|
||||
<button id="search" class="btn btn-large btn-block btn-primary" type="submit" value="" onclick="dosubmit()" ><i class="icon-search"></i>搜索</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
//Google map (不启用预先加载)
|
||||
google.maps.event.addDomListener(window, 'load', initialize);
|
||||
//jquery ui datepicker
|
||||
$("#begin").datepicker({dateFormat:"yy-mm-dd"});
|
||||
$("#end").datepicker({dateFormat:"yy-mm-dd"});
|
||||
});
|
||||
// Google Map Part
|
||||
var map = null;
|
||||
var mapElementID = "map_canvas";
|
||||
var bounds = null;
|
||||
var rectangle = null;
|
||||
var input = {east:'#east',west:'#west',north:'#north',south:'#south'};
|
||||
|
||||
function initialize() {
|
||||
//加载地图
|
||||
var myLatlng = new google.maps.LatLng(35.656456,105.819946);
|
||||
var myOptions = {
|
||||
zoom: 3,
|
||||
center: myLatlng,
|
||||
mapTypeId: google.maps.MapTypeId.ROADMAP
|
||||
}
|
||||
map = new google.maps.Map(document.getElementById(mapElementID), myOptions);
|
||||
|
||||
//Keydragzone
|
||||
map.enableKeyDragZoom({
|
||||
key: "shift",
|
||||
boxStyle: {
|
||||
border: "1px dashed black",
|
||||
backgroundColor: "transparent",
|
||||
opacity: 1.0
|
||||
},
|
||||
veilStyle: {
|
||||
backgroundColor: "white",
|
||||
opacity: 0.35,
|
||||
cursor: "crosshair"
|
||||
}
|
||||
});
|
||||
|
||||
var dz = map.getDragZoomObject();
|
||||
google.maps.event.addListener(dz, 'dragstart', function (latlng) {
|
||||
RemoveRectangle();
|
||||
//console.dir(latlng);
|
||||
});
|
||||
google.maps.event.addListener(dz, 'dragend', function (latlng) {
|
||||
console.log(latlng);
|
||||
MapValueChange(latlng.fa.d,latlng.$.d,latlng.fa.b,latlng.$.b);
|
||||
setRectangle(latlng.fa.d,latlng.fa.b,latlng.$.b,latlng.$.d);
|
||||
//console.dir(latlng);
|
||||
});
|
||||
|
||||
InputValueChange();
|
||||
|
||||
}
|
||||
|
||||
function setRectangle(east,west,south,north){
|
||||
|
||||
bounds = new google.maps.LatLngBounds(
|
||||
new google.maps.LatLng(south,west),
|
||||
new google.maps.LatLng(north,east)
|
||||
);
|
||||
|
||||
rectangle = new google.maps.Rectangle({
|
||||
bounds: bounds,
|
||||
editable: true
|
||||
});
|
||||
|
||||
rectangle.setMap(map);
|
||||
|
||||
google.maps.event.addListener(rectangle, 'bounds_changed', function () {
|
||||
var latlng = rectangle.getBounds();
|
||||
MapValueChange(latlng.fa.d,latlng.Z.d,latlng.fa.b,latlng.Z.b);
|
||||
//console.dir(latlng);
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
function RemoveRectangle(){
|
||||
if(rectangle != null)
|
||||
{
|
||||
rectangle.setMap(null);
|
||||
rectangle = null;
|
||||
}
|
||||
}
|
||||
|
||||
function MapValueChange(east,north,west,south){
|
||||
$(input.east).val(east);
|
||||
$(input.north).val(north);
|
||||
$(input.west).val(west);
|
||||
$(input.south).val(south);
|
||||
}
|
||||
|
||||
function InputValueChange(){
|
||||
if(MapInputValueCheck() == true)
|
||||
{
|
||||
if(rectangle == null)
|
||||
{
|
||||
setRectangle($(input.east).val(),$(input.west).val(),$(input.south).val(),$(input.north).val());
|
||||
}else{
|
||||
var reSetBounds = new google.maps.LatLngBounds(
|
||||
new google.maps.LatLng($(input.south).val(),$(input.west).val()),
|
||||
new google.maps.LatLng($(input.north).val(),$(input.east).val())
|
||||
);
|
||||
rectangle.setBounds(reSetBounds);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function MapInputValueCheck()
|
||||
{
|
||||
if($(input.east).val() != "" && $(input.west).val() != "" && $(input.north).val() != "" && $(input.south).val() != "")
|
||||
{
|
||||
return true;
|
||||
}else{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
$(input.east).bind('blur',InputValueChange);
|
||||
$(input.west).bind('blur',InputValueChange);
|
||||
$(input.north).bind('blur',InputValueChange);
|
||||
$(input.south).bind('blur',InputValueChange);
|
||||
|
||||
// Google map Part --End
|
||||
|
||||
|
||||
function Alert(content){
|
||||
$.colorbox({innerWidth:'40%',html:'<div style="line-height:30px;font-size:16px;">'+ content +'</div>'});
|
||||
}
|
||||
|
||||
function dosubmit() {
|
||||
theForm.action="/search";
|
||||
}
|
||||
</script>
|
||||
<div id="help">
|
||||
<fieldset><legend>搜索说明</legend><ul><li>关键词:您可以使用一个关键词,比如“沙漠”,也可以使用多个关键词,中间用空格分开。</li>
|
||||
<li>空间范围:这是以度为单位的十进制数字。比如,东经125度30分,可以输入为125.5。您也可以通过下面的在线地图工具直接在图上拉框选择一个范围,空间坐标会自动转换到文本框中。</li>
|
||||
<li>时间范围:指数据的时间范围,从开始时间到结束时间。开始时间与结束时间可以为空,若仅填写开始时间,则含义为选择大于开始时间的数据。若仅填写结束时间,则含义为选择小于结束时间的数据。时间格式为YYYY-MM-DD。</li>
|
||||
<li>还不清楚?您可以到<a href="http://forum.westgis.ac.cn/viewforum.php?f=30">论坛</a>提问。</li>
|
||||
</ul></fieldset>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<?php endif; ?>
|
|
@ -1,5 +1,5 @@
|
|||
<?php
|
||||
$__ = array('q', 'm', 'f', 's', 'p', 'ie', 'oe', 'syn', 'xml');
|
||||
$__ = array('q', 'm', 'f', 's', 'p', 'ie', 'oe', 'syn', 'xml','east','west','south','north','begin','end');
|
||||
foreach ($__ as $_)
|
||||
$$_ = isset($_GET[$_]) ? $_GET[$_] : '';
|
||||
// input encoding
|
||||
|
@ -46,12 +46,19 @@ $this->nav[] = array('link'=>"/search",'title'=>'全文搜索');
|
|||
<!-- search form -->
|
||||
<form id="q-form" class="form-search form-inline" method="get">
|
||||
<div id="q-input" class="input-append">
|
||||
<input class="span4 search-query text" type="text" name="q" title="输入任意关键词皆可搜索" value="<?php echo htmlspecialchars($q); ?>" />
|
||||
<input class="span4 search-query text" type="text" name="q" placeholder="输入任意关键词皆可搜索" value="<?php echo htmlspecialchars($q); ?>" />
|
||||
<button type="submit" class="btn">Search</button>
|
||||
</div>
|
||||
<input type="radio" name="f" value="title" <?php if (!empty($f_title)) echo $f_title; ?> />标题
|
||||
<input type="radio" name="f" value="_all" <?php if (!empty($f__all)) echo $f__all; ?> />全文
|
||||
<input type="checkbox" name="m" value="yes" <?php echo $m_check; ?> />模糊搜索
|
||||
<input type="hidden" name="east" value="<?php echo $east; ?>" />
|
||||
<input type="hidden" name="west" value="<?php echo $west; ?>" />
|
||||
<input type="hidden" name="south" value="<?php echo $south; ?>" />
|
||||
<input type="hidden" name="north" value="<?php echo $north; ?>" />
|
||||
<input type="hidden" name="begin" value="<?php echo $begin; ?>" />
|
||||
<input type="hidden" name="end" value="<?php echo $end; ?>" />
|
||||
<button type="button" class="btn" id="advance">高级搜索</button>
|
||||
<!-- <li><input type="checkbox" name="syn" value="yes" <?php echo $syn_check; ?> />同义词</li>
|
||||
<li>
|
||||
按
|
||||
|
@ -62,6 +69,17 @@ $this->nav[] = array('link'=>"/search",'title'=>'全文搜索');
|
|||
排序
|
||||
</li>-->
|
||||
</form>
|
||||
<?php
|
||||
if ($begin || $end || $east)
|
||||
{
|
||||
echo '<div class="well well-small">';
|
||||
if ($begin || $end) echo '<span class="text-success">时间范围</span>';
|
||||
if ($begin) echo '开始:'.$begin;
|
||||
if ($end) echo '结束:'.$end;
|
||||
if ($east) echo '<span class="text-success">空间范围</span> 东:'.$east.' 西:'.$west.' 南:'.$south.' 北:'.$north;
|
||||
echo '</div>';
|
||||
}
|
||||
?>
|
||||
|
||||
<!-- hot search -->
|
||||
<?php if (count($this->hot) > 0): ?>
|
||||
|
@ -76,7 +94,6 @@ $this->nav[] = array('link'=>"/search",'title'=>'全文搜索');
|
|||
<?php endif; ?>
|
||||
|
||||
<!-- begin search result -->
|
||||
<?php if (!empty($q)): ?>
|
||||
|
||||
<!-- neck bar -->
|
||||
<div id="res-neck">
|
||||
|
@ -165,7 +182,6 @@ $this->nav[] = array('link'=>"/search",'title'=>'全文搜索');
|
|||
<?php endif; ?>
|
||||
|
||||
<!-- end search result -->
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div><!-- outer -->
|
||||
|
||||
|
@ -196,11 +212,16 @@ $(function(){
|
|||
// submit check
|
||||
$('#q-form').submit(function(){
|
||||
var $input = $('#q-input .text');
|
||||
if ($input.val() == $input.attr('title')) {
|
||||
/*if ($input.val() == $input.attr('title')) {
|
||||
alert('请先输入关键词');
|
||||
$input.focus();
|
||||
return false;
|
||||
}
|
||||
}*/
|
||||
});
|
||||
//advance search
|
||||
$('#advance').click(function(){
|
||||
$('#q-form').attr('action','/search/advance');
|
||||
$('#q-form').submit();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
|
|
@ -53,7 +53,7 @@ class Pureftp
|
|||
$sql="insert into pureftp (userid,passwd,homedir) values('".$user->username."','".$user->password."','".'/home/ftp/'.$user->username."')";
|
||||
$this->db->query($sql);
|
||||
//create user home dir
|
||||
mkdir('/home/ftp/'.$user->username);
|
||||
//mkdir('/home/ftp/'.$user->username);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -118,7 +118,7 @@ try
|
|||
// just show hot query
|
||||
$this->hot = $this->search->getHotQuery();
|
||||
}
|
||||
else
|
||||
|
||||
{
|
||||
// fuzzy search
|
||||
$this->search->setFuzzy($m === 'yes');
|
||||
|
|
|
@ -0,0 +1,249 @@
|
|||
<?php
|
||||
class Region
|
||||
{
|
||||
private $db; //传入PDO对象.
|
||||
private $gdb; //geonetwork database
|
||||
protected $events = NULL; //事件
|
||||
|
||||
public $tbl_regions = "regions";
|
||||
public $tbl_regionsdes = "regionsdes";
|
||||
|
||||
function __construct($db)
|
||||
{
|
||||
$this->db = $db;
|
||||
$this->config = Zend_Registry::get('config');
|
||||
$this->geonetwork();
|
||||
}
|
||||
|
||||
private function geonetwork(){
|
||||
$db = Zend_Db::factory($this->config->geonetwork);
|
||||
Zend_Db_Table::setDefaultAdapter($db);
|
||||
$this->gdb = $db;
|
||||
}
|
||||
|
||||
public function events(Zend_EventManager_EventCollection $events = NULL)
|
||||
{
|
||||
if ($events !== NULL) {
|
||||
$this->events = $events;
|
||||
} elseif ($this->events === NULL) {
|
||||
$this->events = new Zend_EventManager_EventManager(__CLASS__);
|
||||
}
|
||||
return $this->events;
|
||||
}
|
||||
|
||||
public function fetchRegion($type = NULL,$filter = NULL)
|
||||
{
|
||||
if(empty($type))
|
||||
{
|
||||
$sql = "SELECT * FROM ".$this->tbl_regions." ORDER BY id ASC";
|
||||
}else{
|
||||
$wheresql = array();
|
||||
|
||||
if(!empty($filter))
|
||||
{
|
||||
if(isset($filter['q']))
|
||||
{
|
||||
$wheresql[] = " rs.label LIKE '%".$filter['q']."%'";
|
||||
}
|
||||
}
|
||||
|
||||
$where=" where rs.langid='cn' ";
|
||||
if(count($wheresql)<1)
|
||||
$where .= "";
|
||||
else
|
||||
$where .= " and ".join(" AND ",$wheresql);
|
||||
|
||||
$sql = "SELECT rs.*,r.* FROM ".$this->tbl_regions." r
|
||||
LEFT JOIN ".$this->tbl_regionsdes." rs ON r.id=rs.iddes
|
||||
$where
|
||||
ORDER BY r.id desc";
|
||||
}
|
||||
$rs = $this->gdb->query($sql);
|
||||
return $rs->fetchAll();
|
||||
}//列表
|
||||
|
||||
public function get($id)
|
||||
{
|
||||
$sql = "SELECT * FROM ".$this->tbl_regions." WHERE id=$id";
|
||||
|
||||
$rs = $this->gdb->query($sql);
|
||||
$data = $rs->fetch();
|
||||
|
||||
$sql = "SELECT * FROM ".$this->tbl_regionsdes. " WHERE iddes=$id";
|
||||
$rs = $this->gdb->query($sql);
|
||||
$data['info'] = $rs->fetchAll();
|
||||
|
||||
return $data;
|
||||
}//获取单个
|
||||
|
||||
public function del($id,$langid = NULL)
|
||||
{
|
||||
if(empty($langid))
|
||||
{
|
||||
$this->gdb->exec("DELETE FROM ".$this->tbl_regionsdes." WHERE iddes=$id");
|
||||
$this->gdb->exec("DELETE FROM ".$this->tbl_regions." WHERE id=$id");
|
||||
return true;
|
||||
}else{
|
||||
return $this->gdb->exec("DELETE FROM ".$this->tbl_regionsdes." WHERE iddes=$id AND langid='$langid'");
|
||||
}
|
||||
|
||||
}//shanchui
|
||||
|
||||
public function addRegion($data,$id = '')
|
||||
{
|
||||
$results = $this->events()->trigger('addRegion.pre', $this, compact('data'));
|
||||
$data = $results->bottom();
|
||||
if(is_string($data))
|
||||
return $data;
|
||||
|
||||
$results = $this->events()->trigger('addRegion.check', $this, compact('data','id'));
|
||||
$data = $results->bottom();
|
||||
if(is_string($data))
|
||||
return $data;
|
||||
|
||||
include_once("helper/dbh.php");
|
||||
$dbh = new dbh($this->gdb);
|
||||
|
||||
$cache_data = $data;
|
||||
unset($data['info']);
|
||||
|
||||
if(empty($id))
|
||||
{
|
||||
$id = $dbh->insert($this->tbl_regions,$data,true);
|
||||
if($id > 0)
|
||||
{
|
||||
$s = true;
|
||||
}
|
||||
}else{
|
||||
$s = $dbh->update($this->tbl_regions,$data,"id=$id");
|
||||
}
|
||||
|
||||
$results = $this->events()->trigger('addRegion.post', $this, compact('cache_data','id'));
|
||||
|
||||
if($s)
|
||||
{
|
||||
return true;
|
||||
}else{
|
||||
return "添加失败,请重试";
|
||||
}
|
||||
}//增加
|
||||
}
|
||||
|
||||
class RegionListener implements Zend_EventManager_ListenerAggregate
|
||||
{
|
||||
private $db; //传入PDO对象.
|
||||
private $gdb; //geonetwork database
|
||||
private $id_start = 5000;
|
||||
private $id_end = 9999;
|
||||
|
||||
public $tbl_regions = "regions";
|
||||
public $tbl_regionsdes = "regionsdes";
|
||||
|
||||
function __construct($db = NULL)
|
||||
{
|
||||
if(empty($db))
|
||||
{
|
||||
$this->db = Zend_Registry::get('db');
|
||||
}else{
|
||||
$this->db = $db;
|
||||
}
|
||||
$this->config = Zend_Registry::get('config');
|
||||
$this->geonetwork();
|
||||
}
|
||||
|
||||
private function geonetwork(){
|
||||
$db = Zend_Db::factory($this->config->geonetwork);
|
||||
Zend_Db_Table::setDefaultAdapter($db);
|
||||
$this->gdb = $db;
|
||||
}
|
||||
|
||||
public function attach(Zend_EventManager_EventCollection $events)
|
||||
{
|
||||
$events->attach('addRegion.pre', array($this, 'scanField'), 100);
|
||||
$events->attach('addRegion.check', array($this, 'checkParam'), 80);
|
||||
$events->attach('addRegion.post', array($this, 'process'), 50);
|
||||
}
|
||||
|
||||
public function detach(Zend_EventManager_EventCollection $events)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
//扫描字段
|
||||
function scanField($e){
|
||||
|
||||
$data = $e->getParam('data');
|
||||
|
||||
if(!is_array($data))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
$data['east'] = (float)$data['east'];
|
||||
$data['west'] = (float)$data['west'];
|
||||
$data['south'] = (float)$data['south'];
|
||||
$data['north'] = (float)$data['north'];
|
||||
|
||||
if(empty($data['east']) || empty($data['west']) || empty($data['south']) || empty($data['north']))
|
||||
{
|
||||
return "请填写四至范围";
|
||||
}
|
||||
|
||||
foreach($data['info'] as $k=>$v)
|
||||
{
|
||||
if(empty($v['langid']) && empty($v['label']))
|
||||
{
|
||||
unset($data['info'][$k]);
|
||||
}
|
||||
}
|
||||
|
||||
return $data;
|
||||
}//scanField
|
||||
|
||||
//检查参数
|
||||
function checkParam($e){
|
||||
$data = $e->getParam('data');
|
||||
$id = $e->getParam('id');
|
||||
|
||||
if(empty($id))
|
||||
{
|
||||
|
||||
$sql = "SELECT * FROM ".$this->tbl_regions."
|
||||
WHERE north=".$data['north']." AND south=".$data['south']." AND west=".$data['west']." AND east=".$data['east'];
|
||||
|
||||
$rs = $this->gdb->query($sql);
|
||||
$row = $rs->fetch();
|
||||
if(!empty($row['id']))
|
||||
{
|
||||
return "此范围已存在";
|
||||
}
|
||||
|
||||
|
||||
$sql = "select max(id) as c FROM ".$this->tbl_regions." WHERE id>=".$this->id_start." AND id<".$this->id_end;
|
||||
$rs = $this->gdb->query($sql);
|
||||
$row = $rs->fetch();
|
||||
|
||||
if(empty($row['c']))
|
||||
{
|
||||
$data['id'] = $this->id_start;
|
||||
}else{
|
||||
$data['id'] = $row['c'] + 1;
|
||||
}
|
||||
}
|
||||
|
||||
return $data;
|
||||
|
||||
}//checkParam
|
||||
|
||||
function process($e)
|
||||
{
|
||||
$data = $e->getParam('cache_data');
|
||||
$id = $e->getParam('id');
|
||||
|
||||
$this->gdb->exec("DELETE FROM ".$this->tbl_regionsdes." WHERE iddes=$id");
|
||||
foreach($data['info'] as $k=>$v)
|
||||
{
|
||||
$this->gdb->insert($this->tbl_regionsdes,array('iddes'=>$id,'langid'=>$v['langid'],'label'=>$v['label']));
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,54 @@
|
|||
<?php
|
||||
class RegionListener implements Zend_EventManager_ListenerAggregate
|
||||
{
|
||||
private $db; //传入PDO对象.
|
||||
function __construct($db = NULL)
|
||||
{
|
||||
if(empty($db))
|
||||
{
|
||||
$this->db = Zend_Registry::get('db');
|
||||
}else{
|
||||
$this->db = $db;
|
||||
}
|
||||
|
||||
//spl_autoload_unregister(array('Zend_Loader_Autoloader','autoload'));
|
||||
}
|
||||
|
||||
public function attach(Zend_EventManager_EventCollection $events)
|
||||
{
|
||||
$events->attach('addRegion.pre', array($this, 'scanField'), 100);
|
||||
}
|
||||
|
||||
public function detach(Zend_EventManager_EventCollection $events)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
//扫描字段
|
||||
function scanField($e){
|
||||
|
||||
$data = $e->getParam('data');
|
||||
|
||||
if(!is_array($data))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
//对特殊字段进行特别处理
|
||||
$data['title'] = $this->replaceHtml($data['title']);
|
||||
$data['description'] = $this->replaceHtml($data['description']);
|
||||
$data['keywords'] = $this->replaceHtml($data['keywords']);
|
||||
|
||||
if(!empty($data['pagename']))
|
||||
{
|
||||
if(!preg_match("/^[a-zA-Z][a-zA-Z0-9_]{4,25}$/",$data['pagename']))
|
||||
{
|
||||
return "自定义文件名只能由小写字母、数字、下划线组成,并且长度在5到25个字符之间";
|
||||
}
|
||||
}
|
||||
|
||||
$data['aaaa'] = "aaa";
|
||||
|
||||
return $data;
|
||||
}//scanField
|
||||
}
|
|
@ -2,7 +2,7 @@
|
|||
class Review extends Zend_Controller_Plugin_Abstract
|
||||
{
|
||||
private $db; //传入PDO对象.
|
||||
private $auth = NULL; //Zend_Auth 对象
|
||||
protected $events = NULL; //事件
|
||||
|
||||
//使用到的公共变量
|
||||
public $tbl_reviewexp = "mdexpertreview";
|
||||
|
@ -14,6 +14,16 @@ class Review extends Zend_Controller_Plugin_Abstract
|
|||
$this->db = $db;
|
||||
}
|
||||
|
||||
public function events(Zend_EventManager_EventCollection $events = NULL)
|
||||
{
|
||||
if ($events !== NULL) {
|
||||
$this->events = $events;
|
||||
} elseif ($this->events === NULL) {
|
||||
$this->events = new Zend_EventManager_EventManager(__CLASS__);
|
||||
}
|
||||
return $this->events;
|
||||
}
|
||||
|
||||
//接受或者拒绝评审
|
||||
function invite($id,$uuid,$uid,$status)
|
||||
{
|
||||
|
@ -89,4 +99,169 @@ class Review extends Zend_Controller_Plugin_Abstract
|
|||
|
||||
return $rows;
|
||||
}
|
||||
|
||||
//发布
|
||||
function post($id,$emails)
|
||||
{
|
||||
if(is_numeric($id))
|
||||
{
|
||||
$cid = (int)$id;
|
||||
}
|
||||
|
||||
if(is_array($id))
|
||||
{
|
||||
$cid = join(",",$id);
|
||||
}
|
||||
|
||||
include_once("helper/view.php");
|
||||
$userid = (int)view::User('id');
|
||||
|
||||
if($this->changestatus($cid,5))
|
||||
{
|
||||
$results = $this->events()->trigger('post.post', $this, compact('emails','id','userid'));
|
||||
return $results->bottom();
|
||||
}else{
|
||||
return false;
|
||||
}
|
||||
|
||||
}//发布
|
||||
|
||||
//检查管理员
|
||||
function checkAdmin($id,$userid = 0)
|
||||
{
|
||||
$id = (int)$id;
|
||||
if(empty($userid))
|
||||
{
|
||||
include_once("helper/view.php");
|
||||
$userid = (int)view::User('id');
|
||||
}
|
||||
$sql = "select id from mdstatus where id=$id and userid=$userid";
|
||||
$rs = $this->db->query($sql);
|
||||
$row = $rs->fetch();
|
||||
|
||||
if(empty($row['id']))
|
||||
{
|
||||
return false;
|
||||
}else{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* changestatus() 更改mdstatus中的status字段
|
||||
*
|
||||
* @param int $id //要更改状态的mdstatus记录的ID
|
||||
* @param int $status //状态
|
||||
*
|
||||
* return bool
|
||||
*/
|
||||
function changestatus($id,$status){
|
||||
$stvalues = array(
|
||||
-1, //取消评审
|
||||
0, //初始状态
|
||||
1, //接受元数据评审,进入评审阶段
|
||||
2, //开始邀请专家,送审阶段
|
||||
3, //专家接受邀请,在审阶段
|
||||
4, //专家反馈,在审
|
||||
5, //评审结束,发布
|
||||
6,7
|
||||
);
|
||||
if(empty($id) || !isset($status) || !in_array($status,$stvalues))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
if($status==1)
|
||||
{$sql = "update mdstatus set status='$status',ts_accepted='now()' where id in ($id)"; }
|
||||
else if($status==5)
|
||||
{$sql = "update mdstatus set status='$status',ts_finished='now()' where id in ($id)";}
|
||||
else
|
||||
{$sql = "update mdstatus set status='$status' where id in ($id)";}
|
||||
try{
|
||||
if($this->db->exec($sql)>0)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
catch(Exception $e)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}//changestatus 更改状态
|
||||
}
|
||||
|
||||
class ReviewListener implements Zend_EventManager_ListenerAggregate
|
||||
{
|
||||
private $db; //传入PDO对象.
|
||||
|
||||
function __construct($db = NULL)
|
||||
{
|
||||
if(empty($db))
|
||||
{
|
||||
$this->db = Zend_Registry::get('db');
|
||||
}else{
|
||||
$this->db = $db;
|
||||
}
|
||||
$this->config = Zend_Registry::get('config');
|
||||
}
|
||||
|
||||
public function attach(Zend_EventManager_EventCollection $events)
|
||||
{
|
||||
$events->attach('post.post', array($this, 'posted'), 100);
|
||||
}
|
||||
|
||||
public function detach(Zend_EventManager_EventCollection $events)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public function posted($e)
|
||||
{
|
||||
$id = $e->getParam('id');
|
||||
$emails = $e->getParam('emails');
|
||||
$userid = $e->getParam('userid');
|
||||
|
||||
if(is_numeric($id))
|
||||
{
|
||||
//发布正式版本
|
||||
$sql = "UPDATE mdversion SET changelog=?,userid=? WHERE id in (select id from mdversion where uuid in (select uuid from mdstatus where id=?) order by ts_created desc limit 1)";
|
||||
$this->db->query($sql,array('发布第一个正式版本 version 1.0',$userid,$id));
|
||||
//删除所有的中间版本
|
||||
$sql="delete from mdversion where changelog is null and uuid in (select uuid from mdstatus where id=?)";
|
||||
$this->db->query($sql,array($id));
|
||||
//email message
|
||||
if(isset($emails) &&is_array($emails) && count($emails)>0)
|
||||
{
|
||||
$mail=new WestdcMailer($this->view->config->smtp);
|
||||
$sql="select m.uuid,m.title from metadata m left join mdstatus s on m.uuid=s.uuid where s.id='$id'";
|
||||
$rs=$this->db->query($sql);
|
||||
$res=$rs->fetch();
|
||||
$mailtp=new EmailText($this->db,'metadata-publish',array('uuid'=>$res['uuid'],'title'=>$res['title']));
|
||||
$mail->setBodyText($mailtp->getBody());
|
||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||
$mail->addTo($emails);
|
||||
$mail->setSubject($mailtp->getSubject());
|
||||
$mail->send();
|
||||
}
|
||||
}
|
||||
|
||||
if(is_array($id))
|
||||
{
|
||||
foreach($id as $v)
|
||||
{
|
||||
//发布正式版本
|
||||
$sql = "UPDATE mdversion SET changelog=?,userid=? WHERE id in (select id from mdversion where uuid in (select uuid from mdstatus where id=?) order by ts_created desc limit 1)";
|
||||
$this->db->query($sql,array('发布第一个正式版本 version 1.0',$userid,$v));
|
||||
//删除所有的中间版本
|
||||
$sql="delete from mdversion where changelog is null and uuid in (select uuid from mdstatus where id=?)";
|
||||
$this->db->query($sql,array($v));
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -9,16 +9,24 @@ class view extends Zend_Controller_Plugin_Abstract
|
|||
$this->db = $db;
|
||||
}
|
||||
|
||||
static function addPaginator($data,$ctl,Zend_Controller_Request_Abstract $request)
|
||||
static function addPaginator($data,$ctl,Zend_Controller_Request_Abstract $request = NULL,$limit = 10)
|
||||
{
|
||||
$page = $request->getParam('page');
|
||||
if(empty($request))
|
||||
{
|
||||
$request = $ctl->getRequest();
|
||||
$page = $request->getParam('page');
|
||||
$view = $ctl->view;
|
||||
}else{
|
||||
$page = $request->getParam('page');
|
||||
$view = $ctl;
|
||||
}
|
||||
|
||||
$paginator = Zend_Paginator::factory($data);
|
||||
$paginator->setCurrentPageNumber($page);
|
||||
$paginator->setItemCountPerPage(12);
|
||||
$paginator->setView($ctl);
|
||||
$paginator->setItemCountPerPage($limit);
|
||||
$paginator->setView($view);
|
||||
Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagination_param.phtml');
|
||||
$ctl->paginator = $paginator;
|
||||
$view->paginator = $paginator;
|
||||
}
|
||||
|
||||
static function Msg($type,$content,$url=''){
|
||||
|
@ -30,7 +38,7 @@ class view extends Zend_Controller_Plugin_Abstract
|
|||
{
|
||||
if($url == -1){
|
||||
$html.= '<script language="javascript">setTimeout("window.history.back(-1);",3000);</script>'."\r\n";
|
||||
}elseif($url == 0){
|
||||
}elseif($url == 0){
|
||||
|
||||
}else{
|
||||
$html.= '<script language="javascript">setTimeout("self.location=\''.$url.'\'",3000);</script>'."\r\n";
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
<xsl:param name="projection" select="defaultstring"/>
|
||||
<xsl:param name="reference" select="defaultstring"/>
|
||||
<xsl:template match="/">
|
||||
<img aligh="center" class="figure">
|
||||
<xsl:attribute name="src">http://westdc.westgis.ac.cn/images/westdc-banner.jpg</xsl:attribute>
|
||||
<img>
|
||||
<xsl:attribute name="src">http://westdc.westgis.ac.cn/images/westdc-logo-1.png</xsl:attribute>
|
||||
</img>
|
||||
<div id="uuid" style="color:red"><u>
|
||||
<xsl:variable name="uuid" select="//Metadata/mdFileID"/>
|
||||
|
|
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue