1+ <!-- index.html -->
2+ <!doctype html>
3+
4+ < html ng-app ="myApp ">
5+ < head >
6+ < style >
7+ .sortable : after {
8+ font : 14 px/1 FontAwesome;
9+ content : "\f0dc" ;
10+ }
11+
12+ .sortable .sort-ascent : after {
13+ content : '\f0de' ;
14+ vertical-align : bottom;
15+ }
16+
17+ .sortable .sort-descent : after {
18+ content : "\f0dd" ;
19+ vertical-align : top;
20+ }
21+ </ style >
22+ < link rel ="stylesheet " href ="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css "> <!-- load bootstrap -->
23+ </ head >
24+ < body ng-controller ="myAppController ">
25+ < div class ="container ">
26+ < div class ="row ">
27+ < div class ="col-md-6 ">
28+ < div class ="form-group ">
29+ < label class ="control-label "> Filter by Name</ label >
30+ < input type ="text " class ="form-control order-search-box "
31+ placeholder ="Search By name "
32+ ng-change ="gridActions.filter() "
33+ ng-model ="name "
34+ filter-by ="name "
35+ filter-type ="text ">
36+ </ div >
37+ </ div >
38+ </ div >
39+ < div grid-data grid-options ="gridOptions " grid-actions ="gridActions " server-pagination ="true ">
40+ < table class ="table table-bordered ">
41+ < thead >
42+ < tr >
43+ < th sortable ="name " class ="sortable "> Name</ th >
44+ < th sortable ="surname " class ="sortable "> Surname</ th >
45+ </ tr >
46+ </ thead >
47+ < tbody >
48+ < tr grid-item >
49+ < td > {{item.name}}</ td >
50+ < td > {{item.surname}}</ td >
51+ </ tr >
52+ </ tbody >
53+ </ table >
54+ < div grid-pagination max-size ="5 " boundary-links ="true "
55+ ng-if ="paginationOptions.totalItems > paginationOptions.itemsPerPage "
56+ total-items ="paginationOptions.totalItems "
57+ ng-model ="paginationOptions.currentPage "
58+ ng-change ="reloadGrid() "
59+ items-per-page ="paginationOptions.itemsPerPage ">
60+ </ div >
61+ < div class ="row ">
62+ < div class ="col-md-6 ">
63+ < div class ="form-group items-per-page ">
64+ < label for ="itemsOnPageSelect1 "> Items per page:</ label >
65+ < select id ="itemsOnPageSelect1 " class ="form-control input-sm " ng-init ="paginationOptions.itemsPerPage = '10' " ng-model ="paginationOptions.itemsPerPage " ng-change ="reloadGrid() ">
66+ < option > 5</ option >
67+ < option > 10</ option >
68+ < option > 50</ option >
69+ < option > 75</ option >
70+ </ select >
71+ </ div >
72+ </ div >
73+ </ div >
74+ </ div >
75+ </ div >
76+ </ body >
77+
78+ < script src ="//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js "> </ script > <!-- load jquery -->
79+ < script src ="//ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js "> </ script > <!-- load angular -->
80+ < script src ="https://angular-ui.github.io/bootstrap/ui-bootstrap-tpls-0.14.3.js "> </ script >
81+ < script src ="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js "> </ script >
82+ < script src ="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular-animate.min.js "> </ script >
83+ < script src ="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular-aria.min.js "> </ script >
84+ < script src ="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular-messages.min.js "> </ script >
85+ < script src ="../../dist/pagination.js "> </ script >
86+ < script src ="../../dist/dataGrid.js "> </ script >
87+ < script src ="js/serverPaginationApp.js "> </ script >
88+ </ html >
0 commit comments