From c4699925e505f2820eec4a2a4552203dad2a3720 Mon Sep 17 00:00:00 2001 From: lunix01 <646696730@qq.com> Date: Tue, 20 Sep 2016 11:39:19 +0800 Subject: [PATCH 1/3] Update tm.pagination.js MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 上一页下一页不请求数据 --- src/pagination/tm.pagination.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/pagination/tm.pagination.js b/src/pagination/tm.pagination.js index 2eb84c4..14d43ee 100755 --- a/src/pagination/tm.pagination.js +++ b/src/pagination/tm.pagination.js @@ -170,6 +170,10 @@ angular.module('tm.pagination', []).directive('tmPagination',[function(){ if(conf.currentPage > 1){ conf.currentPage -= 1; } + getPagination(); + if(conf.onChange) { + conf.onChange(); + } }; // nextPage @@ -177,6 +181,10 @@ angular.module('tm.pagination', []).directive('tmPagination',[function(){ if(conf.currentPage < conf.numberOfPages){ conf.currentPage += 1; } + getPagination(); + if(conf.onChange) { + conf.onChange(); + } }; // 变更当前页 From da6ec9f18f990b73ac8b040dfb25035bd8245484 Mon Sep 17 00:00:00 2001 From: yfor <377900058@qq.com> Date: Sat, 4 Mar 2017 14:17:16 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E6=A0=B7=E5=BC=8F=E9=80=82=E9=85=8Damazeui?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 样式适配amazeui --- src/pagination/tm.pagination.js | 34 +++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/src/pagination/tm.pagination.js b/src/pagination/tm.pagination.js index 14d43ee..b6b7869 100755 --- a/src/pagination/tm.pagination.js +++ b/src/pagination/tm.pagination.js @@ -5,22 +5,24 @@ angular.module('tm.pagination', []).directive('tmPagination',[function(){ return { restrict: 'EA', - template: '
' + - '' + - '
' + - '每页' + - '/共{{ conf.totalItems }}条 ' + - '跳转至' + - '
' + - '
暂无数据
' + - '
', + template: '
' + + '' + + /** + '
' + + '每页' + + '/共{{ conf.totalItems }}条 ' + + '跳转至' + + '
' + + **/ + '
暂无数据
' + + '
', replace: true, scope: { conf: '=' From 5f8aeaa2404a5c3e1db9fa145ba41ea933818f15 Mon Sep 17 00:00:00 2001 From: King Date: Mon, 28 May 2018 15:34:51 +0800 Subject: [PATCH 3/3] Update tm.pagination.js MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 当perPageOptions不使用时,应为 conf.perPageOptions = defaultPerPageOptions; --- src/pagination/tm.pagination.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pagination/tm.pagination.js b/src/pagination/tm.pagination.js index 14d43ee..812a65d 100755 --- a/src/pagination/tm.pagination.js +++ b/src/pagination/tm.pagination.js @@ -58,7 +58,7 @@ angular.module('tm.pagination', []).directive('tmPagination',[function(){ // 分页选项可调整每页显示的条数 if(!conf.perPageOptions){ - conf.perPageOptions = defaultPagesLength; + conf.perPageOptions = defaultPerPageOptions; } // pageList数组