forked from joaool/MotherGithub
-
Notifications
You must be signed in to change notification settings - Fork 0
/
test_datatables2.html
186 lines (171 loc) · 6.1 KB
/
test_datatables2.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
<!--
* http://download.dojotoolkit.org/release-1.2.3/dojo-release-1.2.3/dojox/form/tests/test_BusyButton.html
* http://www.sitepen.com/blog/2008/10/17/dojo-building-blocks-of-the-web/
*
* <!DOCTYPE html>
-->
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<!--
<meta http-equiv="X-UA-Compatible" content="IE=8" />
<script type="text/javascript" src="Dojo Toolkit/dojo-release-1.7.1/dojo/dojo.js" djconfig="parseOnLoad: true, isDebug: true" >
</script>
<link href="Dojo Toolkit/dojo-release-1.7.1/dijit/themes/claro/claro.css" rel="stylesheet">
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
-->
<!-- -->
<!-- -->
<title>Test datatables v2.0</title>
<script>
dojoConfig= {
has: {
"dojo-firebug": true
},
parseOnLoad: false,
debugAtAllCosts: true,
foo: "bar",
async: true
};
</script>
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script src="//datatables.net/download/build/nightly/jquery.dataTables.js"></script>
<script type="text/javascript" charset="utf-8" src="../Data Tables_Editor/media/js/dataTables.editor.js" ></script>
<script type="text/javascript" language="javascript" src="../ColReorder-1.1.0/js/dataTables.colReorder.js"></script>
<script src="//cdn.datatables.net/plug-ins/505bef35b56/integration/bootstrap/3/dataTables.bootstrap.js"></script>
<script type="text/javascript" src="../dojo1.9.2/dojo/dojo.js"></script>
<!--<script type="text/javascript"
src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>-->
<!--
<script type="text/javascript"
src="../Jcrop/js/jquery.min.js"></script>
<script src="//datatables.net/download/build/nightly/jquery.dataTables.js"></script>
<script src="../DataTables 1.10.0-beta.2/media/js/jquery.dataTables.js"></script>
-->
<!--<script src="Mother/jquery-1.8.1.min.js"></script> -->
<!--<script src="Mother/bootstrap.js"></script>-->
<link rel="stylesheet" type="text/css" href="../bootstrap-3.1.1-dist/css/bootstrap.css">
<link rel="stylesheet" href="../Jcrop/demos/demo_files/main.css" type="text/css" />
<link href="../dojo1.9.2/dijit/themes/claro/claro.css" rel="stylesheet">
<link href="../DataTables 1.10.0-beta.2/media/css/jquery.dataTables.css" rel="stylesheet" type="text/css" />
<!--- For Mother Builder -->
<link rel="stylesheet" type="text/css" href="Mother/MotherBuilder.css" />
<style type="text/css">
div.container {
min-width: 980px;
margin: 0 auto;
}
div.dataTables_length label {
width: 460px;
float: left;
text-align: left;
}
div.dataTables_length select {
width: 75px;
}
div.dataTables_filter label {
float: right;
width: 460px;
}
div.dataTables_info {
padding-top: 8px;
}
div.dataTables_paginate {
float: right;
margin: 0;
}
table {
margin: 1em 0;
clear: both;
}
</style>
<script>
oDbg=null;//so that we can use "this" inside this html with embedded script
// define.amd.jQuery = true;
require([
"dojo/query",
"dojo/dom",
"dojo/dom-construct",
"dijit/registry",
"Mother/areasFactory.js",
"Mother/textbox.js",
"Mother/numberbox.js",
"Mother/container.js",
],
function(query,dom,domConstruct,registry,canvas,textbox,numberbox,container){
var j={};
console.log("Inicio");
console.log("--------------------------------------- container done.... -----------------------------------------------");
// $(document).ready( function () {
$('#example').dataTable( {
"ajax": "../DataTables 1.10.0-beta.2/examples/ajax/data/objects.txt",
"columns": [//this does the match between the source array of json and client side array od jason
{ "data": "name" },
{ "data": "position" },
{ "data": "office" },
{ "data": "extn" },
{ "data": "start_date" },
{ "data": "salary" },
],
"lengthMenu": [[10, 25, 50, -1], [11,26, 50, "All"]],
//sDom (with the R) is necessary for column reorder
"sDom":'Rlfrtip',//"<'row'<'span8'Rl><'span8'f>r>t<'row'<'span8'i><'span8'p>>",//'Rlfrtip' '<"top"fipl>rt<"bottom"ipl>'
"oColReorder": {
"aiOrder": [0,1,2,3,4,5,6]//[ 5, 0 ] //[ 5,4, 3, 2, 1, 0 ]
},
"oLanguage": {
"sLengthMenu": "_MENU_ records perpage",
"sZeroRecords": "Vazio!",
"sInfo": "FrameLink shows _START_ until _END_ out of _TOTAL_ entries",
"sInfoEmpty": "No existing records",
"sInfoFiltered": "(total of _MAX_ records)",
'sSearch' : "Search your Framelink customer base"
}
} );
// var table = $('#example').DataTable({
// "sScrollY": "300px", //the high of the scrolling area
// "bPaginate": false,
// "sDom":"<'row'<'span8'Rl><'span8'f>r>t<'row'<'span8'i><'span8'p>>",//'Rlfrtip' '<"top"fipl>rt<"bottom"ipl>' https://datatables.net/usage/options#sDom
// //i - Information =>Showing 1 to 57 of 57 entries
// //f - filtering input =>Search
// "oColReorder": {
// "aiOrder": [ 5, 0 ] //[ 5,4, 3, 2, 1, 0 ]
// },
// "oLanguage": {
// "sLengthMenu": "_MENU_ entradas por página",
// "sZeroRecords": "Vazio!",
// "sInfo": "Exibindo de _START_ até _END_. Total de: _TOTAL_ entradas",
// "sInfoEmpty": "Nenhuma entrada",
// "sInfoFiltered": "(total de _MAX_ entradas)",
// 'sSearch' : "Busca"
// }
// });
console.log(document.title+"...... END..");
}//closing of main function
);//closing of require function
</script>
</head>
<body class="claro Mother">
<p id="target">
<b style="display:block; padding: .5em 1em;">
FrameLink using a JQuery grid.
</b>
</p>
<div class="container">
<!--
<table id="example" class="display" width="100%">
-->
<table id="example" class="table table-striped table-bordered" cellspacing="0" width="100%">
<thead>
<tr>
<th>Name</th>
<th>Position</th>
<th>Office</th>
<th>Age</th>
<th>Start date</th>
<th>Salary</th>
</tr>
</thead>
</table>
</div>
</body>
</html>