diff --git a/application/default/controllers/DataController.php b/application/default/controllers/DataController.php index 4c65c784..6d7907f2 100755 --- a/application/default/controllers/DataController.php +++ b/application/default/controllers/DataController.php @@ -104,7 +104,7 @@ class DataController extends Zend_Controller_Action $select->from('normalmetadata','*')->joinLeft('mdstat','normalmetadata.uuid=mdstat.uuid', ['viewed','downloaded'])->where('datatype=0')->order('title')->limitPage($page,$limit); $this->view->metadata = $this->db->fetchAll($select); - view::addTextPaginator($select, $this); + view::addPaginator($select, $this); } function offlinelistAction() { @@ -118,7 +118,7 @@ class DataController extends Zend_Controller_Action $select=$this->db->select(); $select->from('normalmetadata','*')->joinLeft('mdstat','normalmetadata.uuid=mdstat.uuid', ['viewed','downloaded'])->where('datatype=1')->order('title')->limitPage($page,$limit); - view::addTextPaginator($select, $this); + view::addPaginator($select, $this); } //展示最近20条离线神情记录情况 function offlineappAction() @@ -205,7 +205,7 @@ class DataController extends Zend_Controller_Action $select=$this->db->select(); $select->from('metadata','*')->joinLeft('mdstat','metadata.uuid=mdstat.uuid', ['viewed','downloaded'])->order('id desc')->limitPage($page,$limit); - view::addTextPaginator($select, $this); + view::addPaginator($select, $this); } function tagAction() @@ -246,7 +246,7 @@ class DataController extends Zend_Controller_Action //$state=$db->query($sql); $this->view->metadata=$this->db->fetchAll($select); // $this->view->page=new Pagination($sum,$page,$limit); - view::addTextPaginator($select, $this); + view::addPaginator($select, $this); } } /* @@ -306,7 +306,7 @@ class DataController extends Zend_Controller_Action ->limitPage($page,$limit); if (!empty($keyword)) $select->join('keyword','keyword.id=normalmetadata.id')->where('keyword.keyword=?',$keyword); - view::addTextPaginator($select, $this); + view::addPaginator($select, $this); //$this->view->showtools=($sum>$page)?true:false; @@ -344,7 +344,7 @@ class DataController extends Zend_Controller_Action ->where('c.code=?',$code) ->order('m.title') ->limitPage($page,$this->limit); - view::addTextPaginator($select, $this); + view::addPaginator($select, $this); } else { //提供全部分类列表 } @@ -1989,7 +1989,7 @@ where ds.uuid=? )) ) a ) p on r.id=p.refid order by p.place"; $select->from('normalmetadata as m','m.*') ->order('m.title desc')->limitPage($page,9); - view::addTextPaginator($select, $this); + view::addPaginator($select, $this); } /* @@ -2168,7 +2168,7 @@ where ds.uuid=? )) ) a ) p on r.id=p.refid order by p.place"; $sth->execute(array($name)); $rows = $sth->fetchAll(); - view::addTextPaginator($rows, $this); + view::addPaginator($rows, $this); } else { //提供全部分类列表 } @@ -2261,7 +2261,7 @@ where ds.uuid=? )) ) a ) p on r.id=p.refid order by p.place"; $sth->execute(array($id)); $rows = $sth->fetchAll(); - view::addTextPaginator($rows, $this); + view::addPaginator($rows, $this); } 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.status=1 and a.uuid in (select uuid from normalmetadata) group by u.id,u.username,u.realname"; @@ -2269,7 +2269,7 @@ where ds.uuid=? )) ) a ) p on r.id=p.refid order by p.place"; $sth->execute(); $rows = $sth->fetchAll(); - view::addTextPaginator($rows, $this); + view::addPaginator($rows, $this); } } else if ($ac=='unverified' || empty($ac)) { //未认证的数据作者 @@ -2283,14 +2283,14 @@ where ds.uuid=? )) ) a ) p on r.id=p.refid order by p.place"; $sth = $this->db->prepare($sql); $sth->execute(array($id)); $rows = $sth->fetchAll(); - view::addTextPaginator($rows, $this); + view::addPaginator($rows, $this); } else { //列出所有作者 $sql="select distinct responsible.individual as username,responsible.id from responsible left join role on role.resid=responsible.id where role.role in ('pointOfContact','resourceProvider','owner')"; $sth = $this->db->prepare($sql); $sth->execute(); $rows = $sth->fetchAll(); - view::addTextPaginator($rows, $this); + view::addPaginator($rows, $this); } } } diff --git a/application/default/views/scripts/pagination_param.phtml b/application/default/views/scripts/pagination_param.phtml index 7714073a..fe139b0b 100644 --- a/application/default/views/scripts/pagination_param.phtml +++ b/application/default/views/scripts/pagination_param.phtml @@ -1,7 +1,6 @@ -pageCount): ?> - - \ No newline at end of file + + diff --git a/application/default/views/scripts/pagination_text.phtml b/application/default/views/scripts/pagination_text.phtml index 2fa426e8..a442d1a0 100644 --- a/application/default/views/scripts/pagination_text.phtml +++ b/application/default/views/scripts/pagination_text.phtml @@ -27,5 +27,4 @@ 返回顶部 - - \ No newline at end of file + \ No newline at end of file