diff --git a/application/default/controllers/DataController.php b/application/default/controllers/DataController.php index fbf4e877..b4f19921 100755 --- a/application/default/controllers/DataController.php +++ b/application/default/controllers/DataController.php @@ -2325,5 +2325,22 @@ order by m.title"; } } + public function mapAction() + { + $uuid = $this->_request->getParam('uuid'); + $sql="select d.*,m.title,m.description from datamap d left join normalmetadata m on d.uuid=m.uuid where d.status=1"; + if (!empty($uuid) && \Helpers\Uuid::test($uuid) !== false) + { + $sql.=" and d.uuid='$uuid'"; + $sth = $this->db->prepare($sql); + $rs = $sth->execute(); + $this->view->map = $sth->fetch(); + } else { + $sth = $this->db->prepare($sql); + $rs = $sth->execute(); + view::addPaginator($sth->fetchAll(),$this,10); + $this->_helper->viewRenderer('map-list'); + } + } } diff --git a/application/default/views/scripts/data/index.phtml b/application/default/views/scripts/data/index.phtml index a2b9bb3d..33001e17 100755 --- a/application/default/views/scripts/data/index.phtml +++ b/application/default/views/scripts/data/index.phtml @@ -24,6 +24,7 @@ $this->headTitle()->setSeparator(' - '); 在线数据清单 离线数据清单 可视化数据 +在线地图数据