增加同步WATER单条元数据功能
This commit is contained in:
parent
f808077500
commit
93a4728005
|
@ -56,13 +56,20 @@ class Admin_DataController extends Zend_Controller_Action
|
|||
$this->db->query("update metadata set source=? where uuid=?",array($gmd->source,$gmd->uuid));
|
||||
}
|
||||
$this->view->msg='成功同步黑河遥感综合实验元数据!';
|
||||
} elseif (!empty($uuid)) {
|
||||
} elseif (!empty($uuid) && isset($_POST['submit'])) {
|
||||
//同步单条元数据
|
||||
$sql=$this->db->quoteInto("select data from geonetworkmetadata where uuid=?",$uuid);
|
||||
if ($rs=$this->db->fetchRow($sql)) {
|
||||
$this->import($rs->data);
|
||||
$this->view->msg='成功同步元数据:'.$uuid;
|
||||
} else $this->view->msg='不存在此元数据:'.$uuid;
|
||||
} elseif (!empty($uuid) && isset($_POST['watersubmit'])) {
|
||||
//同步单条元数据
|
||||
$sql=$this->db->quoteInto("select data from watergn where uuid=?",$uuid);
|
||||
if ($rs=$this->db->fetchRow($sql)) {
|
||||
$this->import($rs->data);
|
||||
$this->view->msg='成功同步元数据:'.$uuid;
|
||||
} else $this->view->msg='不存在此元数据:'.$uuid;
|
||||
} elseif ($list=='water') {
|
||||
$sql="select uuid,title from metadata where uuid not in (select uuid from watergn where schemaid='iso19115') and uuid not in (select uuid from geonetworkmetadata where schemaid='iso19115')";
|
||||
$this->view->metadata=$this->db->query($sql);
|
||||
|
|
|
@ -34,7 +34,8 @@
|
|||
<p><a href="/admin/data/sync/adminuser/geonetwork">同步管理员帐号到GEONETWORK</a></p>
|
||||
<form method="POST">
|
||||
<p>指定元数据UUID: <input type="text" name="uuid"></p>
|
||||
<input type="submit" value="同步此元数据" />
|
||||
<button type="submit" name="submit">同步此元数据</button>
|
||||
<button type="submit" name="watersubmit">同步WATER数据</button>
|
||||
</form>
|
||||
<?php if ($this->metadata) : ?>
|
||||
<ul>
|
||||
|
|
Loading…
Reference in New Issue